diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000000000..d48424df7e633 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,14 @@ +# Set default behaviour, in case users don't have core.autocrlf set. +* text=auto + +# Declare files that will always have CRLF line endings on checkout. +*.sln eol=crlf +*.dsp eol=crlf +*.dsw eol=crlf +*.vcproj eol=crlf + +# Denote all files that are truly binary and should not be modified. +*.png binary +*.jpg binary +*.pdf binary +*.root binary diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000000000..5370672afa6e0 --- /dev/null +++ b/.gitignore @@ -0,0 +1,460 @@ +# Compiled Object files +*.slo +*.lo +*.o + +# Compiled Dynamic libraries +*.so +*.dylib +*.dll + +# Compiled Static libraries +*.lai +*.la +*.a + +# Dictionary source files +G__*.c +G__*.cxx +G__*.h +etc/allDict.cxx +etc/allDict.h +rootcint_*.cxx +rootcint_*.h + +# Other Stuff +*.d + +# / +/bin +/lib +/include +/config.status +/config.log +/work.pc +/work.pcl +/.def +/build-arch-stamp +/build-indep-stamp +/build-arch-cint-stamp +/configure-stamp +/debian +/log +/semantic.cache +/.gdb_history +/buildtools +/roottest +/*.mk + +# cint/cint +cint/cint/inc/configcint.h +cint/cint/include/iosenum.h +cint/cint/include/sys/types.h +cint/cint/include/systypes.h +cint/cint/lib/posix/mktypes +cint/cint/lib/posix/mktypes.dSYM +cint/cint/main/cint_tmp +cint/cint/src/loadfile_tmp.cxx + +# /README/ +/README/ChangeLog + +# /build/misc/ +/build/misc/root-help.el + +# /config/ +/config/Makefile.config +/config/Makefile.comp + +# /core/lzma/src/ +/core/lzma/src/xz-5.0.3 + +# /core/metautils/src/ +/core/metautils/src/stlLoader_set.cc +/core/metautils/src/stlLoader_map2.cc +/core/metautils/src/stlLoader_multimap2.cc +/core/metautils/src/stlLoader_list.cc +/core/metautils/src/stlLoader_multimap.cc +/core/metautils/src/stlLoader_vector.cc +/core/metautils/src/stlLoader_deque.cc +/core/metautils/src/stlLoader_multiset.cc +/core/metautils/src/stlLoader_map.cc +/core/metautils/src/stlLoader_valarray.cc +/core/metautils/src/stlLoader_complex.cc + +# /core/pcre/src/ +/core/pcre/src/pcre-7.8 + +# /core/utils/src/ +/core/utils/src/rootcint_tmp +/core/utils/src/rootcint_tmp.exp +/core/utils/src/rootcint_tmp.lib +/core/utils/src/rootcint_tmp.pdb +/core/utils/src/rootcint_tmp.cxx +/core/utils/src/rootcint_tmp.exe +/core/utils/src/rootcling_tmp +/core/utils/src/rootcling_tmp.cxx +/core/utils/src/RStl_tmp.cxx +/core/utils/src/RConversionRuleParser_tmp.cxx + +# /docbook/primer/ +/docbook/primer/primer.tex +/docbook/primer/primer.html +/docbook/primer/primer.pdf +/docbook/primer/primer.epub + +# /docbook/users-guide/ +/docbook/users-guide/ROOTUsersGuide.html +/docbook/users-guide/ROOTUsersGuide.pdf + +# /etc/ +/etc/system.rootrc +/etc/system.rootmap +/etc/system.rootauthrc +/etc/system.rootdaemonrc +/etc/root.mimes +/etc/gitinfo.txt +/etc/cling +/etc/allDict.cxx.pch +/etc/allDict.cxx.h + +# /etc/daemons/ +/etc/daemons/rootd.rc.d +/etc/daemons/rootd.xinetd +/etc/daemons/proofd.rc.d +/etc/daemons/proofd.xinetd +/etc/daemons/olbd.rc.d +/etc/daemons/xrootd.rc.d + +# /etc/proof/ +/etc/proof/proof.conf +/etc/proof/xpd.cf +/etc/proof/motd + +# /etc/proof/proofbench/ +/etc/proof/proofbench/ProofBenchCPUSel.par +/etc/proof/proofbench/ProofBenchDataSel.par + +# /graf2d/asimage/src/libAfterImage/ +/graf2d/asimage/src/libAfterImage/config.h +/graf2d/asimage/src/libAfterImage/Makefile +/graf2d/asimage/src/libAfterImage/config.status +/graf2d/asimage/src/libAfterImage/afterimage-libs +/graf2d/asimage/src/libAfterImage/afterimage-config +/graf2d/asimage/src/libAfterImage/config.log +/graf2d/asimage/src/libAfterImage/libAfterImage.a + +# /graf2d/freetype/src/ +/graf2d/freetype/src/freetype-2.3.12 + +# /graf2d/qt/src/ +/graf2d/qt/src/moc_*.cxx + +# /graf2d/win32gdk/gdk/src/gdk/ +/graf2d/win32gdk/gdk/src/gdk/gdk-1.3.exp +/graf2d/win32gdk/gdk/src/gdk/gdk-1.3.lib + +# /graf2d/win32gdk/gdk/src/gdk/win32/ +/graf2d/win32gdk/gdk/src/gdk/win32/gdk-win32.lib +/graf2d/win32gdk/gdk/src/gdk/win32/gdk.res + +# /gui/fitpanel/test/ +/gui/fitpanel/test/outputUnitTesting.txt +/gui/fitpanel/test/UnitTesting + +# /gui/qtgsi/src/ +/gui/qtgsi/src/moc_* + +# /interpreter/cling/lib/UserInterface/ +/interpreter/cling/lib/UserInterface/textinput + +# /interpreter/llvm/ +/interpreter/llvm/obj +/interpreter/llvm/inst + +# /interpreter/llvm/src/utils/lit/lit/ +/interpreter/llvm/src/utils/lit/lit/*.pyc + +# /interpreter/llvm/src/utils/llvm-build/llvmbuild/ +/interpreter/llvm/src/utils/llvm-build/llvmbuild/util.pyc +/interpreter/llvm/src/utils/llvm-build/llvmbuild/componentinfo.pyc +/interpreter/llvm/src/utils/llvm-build/llvmbuild/__init__.pyc +/interpreter/llvm/src/utils/llvm-build/llvmbuild/configutil.pyc +/interpreter/llvm/src/utils/llvm-build/llvmbuild/main.pyc + +# /macros/ +/macros/html.C + +# /main/src/ +/main/src/roots.sh +/main/src/proofserv.sh + +# /math/genetic/test/ +/math/genetic/test/testGAMinimizer +/math/genetic/test/GAMinTutorial +/math/genetic/test/timeGA + +# /math/genvector/test/ +/math/genvector/test/*.log +/math/genvector/test/rotationApplication +/math/genvector/test/vectorOperation +/math/genvector/test/testVectorIO +/math/genvector/test/testGenVector +/math/genvector/test/TrackDict.h +/math/genvector/test/coordinates4D +/math/genvector/test/stress2D +/math/genvector/test/testBoost +/math/genvector/test/testIterator +/math/genvector/test/coordinates3D +/math/genvector/test/TrackDict.cxx +/math/genvector/test/stress3D + +# /math/mathcore/test/ +/math/mathcore/test/stressTMath +/math/mathcore/test/testIntegration +/math/mathcore/test/testSortOrder +/math/mathcore/test/testIntegrationMultiDim +/math/mathcore/test/binarySearchTime +/math/mathcore/test/stressTF1 +/math/mathcore/test/stdsort +/math/mathcore/test/testSpecFuncBeta +/math/mathcore/test/testSpecFuncErf +/math/mathcore/test/testSpecFuncGamma +/math/mathcore/test/testBinarySearch +/math/mathcore/test/testRootFinder +/math/mathcore/test/testSpecFuncBetaI +/math/mathcore/test/testTMath +/math/mathcore/test/*.build.log + +# /math/mathcore/test/fit/ +/math/mathcore/test/fit/testFit +/math/mathcore/test/fit/testMinim +/math/mathcore/test/fit/testFitPerf +/math/mathcore/test/fit/testRooFit +/math/mathcore/test/fit/SparseDataComparer +/math/mathcore/test/fit/SparseFit3 +/math/mathcore/test/fit/SparseFit4 + +# /math/mathmore/src/ +/math/mathmore/src/gsl-1.5 + +# /math/mathmore/test/ +/math/mathmore/test/testRandom.out +/math/mathmore/test/testIntegrationMultiDim +/math/mathmore/test/testInterpolation +/math/mathmore/test/testFunctor +/math/mathmore/test/testChebyshev +/math/mathmore/test/testIntegration +/math/mathmore/test/simanTSP +/math/mathmore/test/testRandom +/math/mathmore/test/testMinimization1D +/math/mathmore/test/testPermute +/math/mathmore/test/testSpecFunc +/math/mathmore/test/testRandomDist +/math/mathmore/test/testRootFinder +/math/mathmore/test/testDerivation +/math/mathmore/test/testStatFunc + +# /math/minuit2/src/ +/math/minuit2/src/Minuit-1_7_6 + +# /math/minuit2/test/ +/math/minuit2/test/testMinimize +/math/minuit2/test/testUserFunc +/math/minuit2/test/testGraph +/math/minuit2/test/testNewMinimizer + +# /math/minuit2/test/MnSim/ +/math/minuit2/test/MnSim/test_Minuit2_ReneTest +/math/minuit2/test/MnSim/test_Minuit2_DemoGaussSim +/math/minuit2/test/MnSim/test_Minuit2_PaulTest2 +/math/minuit2/test/MnSim/test_Minuit2_PaulTest3 +/math/minuit2/test/MnSim/test_Minuit2_PaulTest4 +/math/minuit2/test/MnSim/test_Minuit2_DemoFumili +/math/minuit2/test/MnSim/test_Minuit2_PaulTest + +# /math/minuit2/test/MnTutorial/ +/math/minuit2/test/MnTutorial/test_Minuit2_Quad1F +/math/minuit2/test/MnTutorial/test_Minuit2_Quad4F +/math/minuit2/test/MnTutorial/test_Minuit2_Quad8F +/math/minuit2/test/MnTutorial/test_Minuit2_Quad12F + +# /math/smatrix/test/ +/math/smatrix/test/*.log +/math/smatrix/test/testKalman +/math/smatrix/test/testOperations +/math/smatrix/test/testSMatrix +/math/smatrix/test/testIO +/math/smatrix/test/stressKalman +/math/smatrix/test/stressOperations +/math/smatrix/test/TrackDict.h +/math/smatrix/test/TrackDict.cxx + +# /math/unuran/src/ +/math/unuran/src/unuran-*-root + +# /math/unuran/test/ +/math/unuran/test/unuranSimple +/math/unuran/test/unuranDiscrete +/math/unuran/test/unuranHist +/math/unuran/test/unuranMulti2D +/math/unuran/test/unuranMultiDim +/math/unuran/test/unuranDistr +/math/unuran/test/*.build.log + +# /misc/rootql/ +/misc/rootql/build + +# /misc/rootsl/ +/misc/rootsl/build + +# /net/globusauth/src/ +/net/globusauth/src/globus_gsi_credential.c + +# /proof/proofbench/src/ +/proof/proofbench/src/ProofBenchCPUSel.par +/proof/proofbench/src/ProofBenchDataSel.par + +# /roofit/ +/roofit/inc +/roofit/src + +# /test/ +/test/linearIO.root +/test/tmpHist.root +/test/dt*.root +/test/Event*.root +/test/Event +/test/Event.exe +/test/EventDict.h +/test/EventDict.cxx +/test/EventMTDict.h +/test/EventMTDict.cxx +/test/event.par +/test/sqlitetest +/test/testdb.sqlite +/test/stress +/test/stress.exe +/test/stressEntryList +/test/stressEntryList.exe +/test/stressFit +/test/stressFit.exe +/test/stressGeometry +/test/stressGeometry.exe +/test/stressGraphics +/test/stressGraphics.exe +/test/stressGUI +/test/stressGUI.exe +/test/stressGUI.ref +/test/stressHepix +/test/stressHepix.exe +/test/stressHepix.log +/test/stressLinear +/test/stressLinear.exe +/test/stressMathCore +/test/stressMathCore.exe +/test/stressMathMore +/test/stressMathMore.exe +/test/stressProof +/test/stressProof.exe +/test/stressRooFit +/test/stressRooFit.exe +/test/stressShapes +/test/stressShapes.exe +/test/stressSpectrum +/test/stressSpectrum.exe +/test/stressTMVA +/test/stressTMVA.exe +/test/stressVector +/test/stressVector.exe +/test/stressIterators +/test/stressIterators.exe +/test/stressInterpreter +/test/stressInterpreter.exe +/test/stressHistogram +/test/stressHistogram.exe +/test/stressRooStats +/test/stressHistoFit +/test/AclockDict.cxx +/test/AclockDict.h +/test/HelloDict.cxx +/test/HelloDict.h +/test/QpRandomDriver +/test/TBenchDict.cxx +/test/TBenchDict.h +/test/TetrisDict.cxx +/test/TetrisDict.h +/test/bench +/test/bench.exe +/test/ctorture +/test/ctorture.exe +/test/guitest +/test/guitest.exe +/test/guiviewer +/test/guiviewer.exe +/test/guiviewerDict.cxx +/test/guiviewerDict.h +/test/hsimple +/test/hsimple.exe +/test/hworld +/test/hworld.exe +/test/minexam +/test/minexam.exe +/test/tcollbm +/test/tcollbm.exe +/test/tcollex +/test/tcollex.exe +/test/testbits +/test/testbits.exe +/test/tstring +/test/tstring.exe +/test/vlazy +/test/vlazy.exe +/test/vmatrix +/test/vmatrix.exe +/test/vvector +/test/vvector.exe +/test/threads +/test/threads.exe +/test/TrackMathCoreDict.* + +# /test/ProofBench/ +/test/ProofBench/build_trees.C +/test/ProofBench/event.par + +# /test/RootIDE/ +/test/RootIDE/RIDE +/test/RootIDE/RIDEDict.cxx +/test/RootIDE/RIDEDict.h + +# /test/RootShower/ +/test/RootShower/RootShower +/test/RootShower/RootShowerDict.cxx +/test/RootShower/RootShowerDict.h + +# /test/ios/ +/test/ios/RootBrowser/RootBrowser.xcodeproj/xcuserdata +/test/ios/RootBrowser/RootBrowser.xcodeproj/project.xcworkspace +/test/ios/Tutorials/Tutorials.xcodeproj/xcuserdata +/test/ios/Tutorials/Tutorials.xcodeproj/project.xcworkspace + +# /tutorials/ +/tutorials/hsimple.root +/tutorials/na49.root +/tutorials/fillrandom.root + +# /tutorials/graphs/ +/tutorials/graphs/gtime.root + +# /tutorials/io/ +/tutorials/io/exclusive.root +/tutorials/io/hsimple.root +/tutorials/io/mergeSelective.Chsimple.root +/tutorials/io/original.root +/tutorials/io/skipped.root + +# /tutorials/tree/ +/tutorials/tree/hvector.root +/tutorials/tree/cernstaff.root +/tutorials/tree/staff.root +/tutorials/tree/basic.root diff --git a/CMakeLists.txt b/CMakeLists.txt index 3d506f3154532..d81cb5be9944d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,5 +1,5 @@ #---Check if cmake has the required version----------------------------------------------------- -cmake_minimum_required(VERSION 2.6 FATAL_ERROR) +cmake_minimum_required(VERSION 2.8 FATAL_ERROR) cmake_policy(SET CMP0005 NEW) #---Set name of the project to "ROOT". Has to be done after check of cmake version-------------- project(ROOT) @@ -28,6 +28,7 @@ set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/modules) set_property(GLOBAL PROPERTY USE_FOLDERS ON) #---Load some basic macros which are needed later for the confiuration and build---------------- +include(RootBuildOptions) include(RootNewMacros) include(CheckCompiler) include(MacroEnsureVersion) @@ -37,8 +38,6 @@ include(MacroEnsureVersion) #---Check if the user wants to build the project in the source directory------------------------ ROOT_CHECK_OUT_OF_SOURCE_BUILD() -#---Here we declare the required build options-------------------------------------------------- -include(RootBuildOptions) #---Here we look for installed software and switch on and of the different build options-------- include(SearchInstalledSoftware) ROOT_SHOW_OPTIONS() @@ -60,9 +59,7 @@ add_subdirectory (proof) add_subdirectory (html) add_subdirectory (montecarlo) add_subdirectory (geom) -if(x11) - add_subdirectory (rootx) -endif() +add_subdirectory (rootx) add_subdirectory (misc) add_subdirectory (main) add_subdirectory (bindings) @@ -79,23 +76,22 @@ include(PostInstalledSoftware) #---Configure and install various files neded later and for clients ----------------------------- include(RootConfiguration) -#install(EXPORT ${CMAKE_PROJECT_NAME}Exports DESTINATION cmake/modules) - #---Installation of project-wise artifacts------------------------------------------------------- if(NOT CMAKE_SOURCE_DIR STREQUAL CMAKE_INSTALL_PREFIX) - install(FILES LICENSE DESTINATION .) - install(DIRECTORY README/ DESTINATION README PATTERN ".svn" EXCLUDE) - install(DIRECTORY etc/ DESTINATION etc USE_SOURCE_PERMISSIONS + install(FILES LICENSE DESTINATION ${CMAKE_INSTALL_DOCDIR}) + install(DIRECTORY README/ DESTINATION ${CMAKE_INSTALL_DOCDIR} PATTERN ".svn" EXCLUDE) + install(DIRECTORY etc/ DESTINATION ${CMAKE_INSTALL_ETCDIR} USE_SOURCE_PERMISSIONS PATTERN ".svn" EXCLUDE REGEX system.rootrc EXCLUDE REGEX root.mimes EXCLUDE) - install(DIRECTORY fonts/ DESTINATION fonts PATTERN ".svn" EXCLUDE) - install(DIRECTORY icons/ DESTINATION icons PATTERN ".svn" EXCLUDE) - install(DIRECTORY macros/ DESTINATION macros PATTERN ".svn" EXCLUDE) - install(DIRECTORY man/ DESTINATION man PATTERN ".svn" EXCLUDE) - install(DIRECTORY test/ DESTINATION test COMPONENT tests PATTERN ".svn" EXCLUDE) - install(DIRECTORY tutorials/ DESTINATION tutorials COMPONENT tests PATTERN ".svn" EXCLUDE) - install(DIRECTORY cmake/modules DESTINATION cmake PATTERN ".svn" EXCLUDE) + install(DIRECTORY fonts/ DESTINATION ${CMAKE_INSTALL_FONTDIR} PATTERN ".svn" EXCLUDE) + install(DIRECTORY icons/ DESTINATION ${CMAKE_INSTALL_ICONDIR} PATTERN ".svn" EXCLUDE) + install(DIRECTORY macros/ DESTINATION ${CMAKE_INSTALL_MACRODIR} PATTERN ".svn" EXCLUDE) + install(DIRECTORY man/ DESTINATION ${CMAKE_INSTALL_MANDIR} PATTERN ".svn" EXCLUDE) + install(DIRECTORY test/ DESTINATION ${CMAKE_INSTALL_TESTDIR} COMPONENT tests PATTERN ".svn" EXCLUDE) + install(DIRECTORY tutorials/ DESTINATION ${CMAKE_INSTALL_TUTDIR} COMPONENT tests PATTERN ".svn" EXCLUDE) + install(DIRECTORY cmake/modules DESTINATION ${CMAKE_INSTALL_CMAKEDIR} PATTERN ".svn" EXCLUDE) + install(FILES build/misc/root.m4 DESTINATION ${CMAKE_INSTALL_ACLOCALDIR}) endif() #---Configure Testing using CTest---------------------------------------------------------------- diff --git a/LICENSE b/LICENSE index 8add30ad590a6..068e1e8e9d9b3 100644 --- a/LICENSE +++ b/LICENSE @@ -1,5 +1,4 @@ GNU LESSER GENERAL PUBLIC LICENSE - Version 2.1, February 1999 Copyright (C) 1991, 1999 Free Software Foundation, Inc. 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA @@ -483,16 +482,12 @@ convey the exclusion of warranty; and each file should have at least the MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. - You should have received a copy of the GNU Lesser General Public + You to should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA Also add information on how to contact you by electronic and paper mail. -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the library, if -necessary. Here is a sample; alter the names: - Yoyodyne, Inc., hereby disclaims all copyright interest in the library `Frob' (a library for tweaking knobs) written by James Random Hacker. diff --git a/Makefile b/Makefile index 4bc395fc3f66e..69e69ca5d2adb 100644 --- a/Makefile +++ b/Makefile @@ -19,6 +19,13 @@ ORDER_ := $(shell test $(MAKE_VERSION_MAJOR) -gt 3 || \ include config/Makefile.config +##### Prevent propagation of user flags to autoconf ##### +##### configure in bundled autotools projects since we ##### +##### are trying to set all compiler flags ourself and ##### +##### including them could lead to e.g. conflicting 32/64 ##### +##### bit build options. +CONFIG_SITE = + ##### Include compiler overrides specified via ./configure ##### ##### However, if we are building packages or cleaning, we ##### ##### don't include this file since it may screw up things ##### @@ -73,7 +80,7 @@ MODULES = build cint/cint core/metautils core/pcre core/clib core/utils \ core/textinput core/base core/cont core/meta core/thread \ io/io math/mathcore net/net core/zip core/lzma math/matrix \ core/newdelete hist/hist tree/tree graf2d/freetype \ - graf2d/graf graf2d/gpad graf3d/g3d \ + graf2d/mathtext graf2d/graf graf2d/gpad graf3d/g3d \ gui/gui math/minuit hist/histpainter tree/treeplayer \ gui/ged tree/treeviewer math/physics graf2d/postscript \ core/rint html montecarlo/eg \ @@ -110,6 +117,7 @@ ifeq ($(BUILDCOCOA),yes) MODULES += graf2d/quartz MODULES += graf2d/cocoa MODULES += core/macosx +MODULES += rootx SYSTEML += $(MACOSXL) SYSTEMO += $(MACOSXO) SYSTEMDO += $(MACOSXDO) @@ -136,6 +144,9 @@ endif ifeq ($(BUILDPGSQL),yes) MODULES += sql/pgsql endif +ifeq ($(BUILDSQLITE),yes) +MODULES += sql/sqlite +endif ifeq ($(BUILDSAPDB),yes) MODULES += sql/sapdb endif @@ -151,6 +162,9 @@ endif ifeq ($(BUILDDCAP),yes) MODULES += io/dcache endif +ifeq ($(BUILDDAVIX),yes) +MODULES += net/davix +endif ifeq ($(BUILDGFAL),yes) MODULES += io/gfal endif @@ -257,16 +271,13 @@ MODULES += misc/minicern hist/hbook endif ifeq ($(HASXRD),yes) MODULES += net/netx +ifeq ($(BUILDNETXNG),yes) +MODULES += net/netxng +endif ifeq ($(BUILDALIEN),yes) MODULES += net/alien endif endif -ifeq ($(BUILDCLARENS),yes) -MODULES += proof/clarens -endif -ifeq ($(BUILDPEAC),yes) -MODULES += proof/peac -endif ifneq ($(ARCH),win32) MODULES += net/rpdutils net/rootd proof/proofd proof/pq2 proof/proofbench endif @@ -289,12 +300,12 @@ ifneq ($(findstring $(MAKECMDGOALS),distclean maintainer-clean),) MODULES += core/unix core/winnt graf2d/x11 graf2d/x11ttf \ graf3d/gl graf3d/ftgl graf3d/glew io/rfio io/castor \ montecarlo/pythia6 montecarlo/pythia8 misc/table \ - sql/mysql sql/pgsql sql/sapdb net/srputils graf3d/x3d \ + sql/mysql sql/pgsql sql/sqlite sql/sapdb net/srputils \ rootx net/rootd io/dcache io/chirp hist/hbook graf2d/asimage \ net/ldap net/krb5auth net/rpdutils net/globusauth \ bindings/pyroot bindings/ruby io/gfal misc/minicern \ - graf2d/qt gui/qtroot gui/qtgsi net/netx net/alien \ - proof/proofd proof/proofx proof/clarens proof/peac proof/pq2 \ + graf2d/qt gui/qtroot gui/qtgsi net/netx net/netxng net/alien \ + proof/proofd proof/proofx proof/pq2 graf3d/x3d net/davix \ sql/oracle io/xmlparser math/mathmore cint/reflex cint/cintex \ tmva math/genetic io/hdfs graf2d/fitsio roofit/roofitcore \ roofit/roofit roofit/roostats roofit/histfactory \ @@ -438,6 +449,8 @@ F77LDFLAGS := $(LDFLAGS) endif ifeq ($(GCC_MAJOR),3) +NOUNDEF := -Wl,--no-undefined +LDFLAGS := $(filter-out $(NOUNDEF),$(LDFLAGS)) ifneq ($(GCC_MINOR),0) ifeq ($(F77),g77) LIBFRTBEGIN := $(shell $(F77) -print-file-name=libfrtbegin.a) @@ -452,12 +465,12 @@ F77LIBS := $(LIBFRTBEGIN) $(F77LIBS) endif endif -##### Store SVN revision number ##### +##### Store Git SHA1 of this version ##### ifeq ($(findstring $(MAKECMDGOALS),clean distclean maintainer-clean dist),) ifeq ($(findstring clean-,$(MAKECMDGOALS)),) -ifeq ($(shell which svn 2>&1 | sed -ne "s@.*/svn@svn@p"),svn) -SVNREV := $(shell bash $(ROOT_SRCDIR)/build/unix/svninfo.sh $(ROOT_SRCDIR)) +ifeq ($(shell which git 2>&1 | sed -ne "s@.*/git@git@p"),git) +GITREV := $(shell bash $(ROOT_SRCDIR)/build/unix/gitinfo.sh $(ROOT_SRCDIR)) endif endif endif @@ -645,7 +658,7 @@ $(1)/%.o: $(ROOT_SRCDIR)/$(1)/%.c $(1)/%.o: $(ROOT_SRCDIR)/$(1)/%.mm $$(MAKEDIR) $$(MAKEDEP) -R -f$$(@:.o=.d) -Y -w 1000 -- $$(CXXFLAGS) -D__cplusplus -- $$< - $$(CXX) $$(OPT) $$(CXXFLAGS) -ObjC++ -std=c++11 $$(CXXOUT)$$@ -c $$< + $$(CXX) $$(OPT) $$(CXXFLAGS) -ObjC++ $$(CXXOUT)$$@ -c $$< $(1)/%.o: $(ROOT_SRCDIR)/$(1)/%.f $$(MAKEDIR) @@ -676,7 +689,7 @@ $(foreach module,$(MODULESGENERIC),$(eval $(call SRCTOOBJ_template,$(module)))) %.o: %.mm $(MAKEDEP) -R -f$*.d -Y -w 1000 -- $(CXXFLAGS) -D__cplusplus -- $< - $(CXX) $(OPT) $(CXXFLAGS) -ObjC++ -std=c++11 $(CXXOUT)$@ -c $< + $(CXX) $(OPT) $(CXXFLAGS) -ObjC++ $(CXXOUT)$@ -c $< %.o: %.f ifeq ($(F77),f2c) @@ -693,7 +706,7 @@ endif ##### TARGETS ##### .PHONY: all fast config rootcint rootlibs rootexecs dist distsrc \ - clean distclean maintainer-clean compiledata \ + clean distclean distclean-xrootd maintainer-clean compiledata \ version html changelog install uninstall showbuild \ releasenotes staticlib static map debian redhat skip postbin \ showit help runtimedirs plugins-ios @@ -907,7 +920,7 @@ redhat-tar: @vers=`sed 's|\(.*\)/\(.*\)|\1.\2|' < build/version_number` && \ rm -f root_v$$vers.source.tar.gz && \ (cd ../ && tar \ - --exclude=\\.svn \ + --exclude=\\.git \ --exclude=root/debian \ --exclude=root/bin \ --exclude=root/lib \ @@ -1050,7 +1063,7 @@ endif @rm -f $(CINTDIR)/lib/posix/a.out $(CINTDIR)/lib/posix/mktypes @rm -f README/ChangeLog build/dummy.d @rm -rf README/ReleaseNotes - @rm -f etc/svninfo.txt + @rm -f etc/gitinfo.txt @(find . -path '*/daemons' -prune -o -name *.d -exec rm -rf {} \; >/dev/null 2>&1;true) @(find . -name *.o -exec rm -rf {} \; >/dev/null 2>&1;true) -@([ -d test ] && (cd test && $(MAKE) distclean); true) @@ -1065,6 +1078,11 @@ maintainer-clean:: distclean build/misc/root-help.el build-arch-stamp build-indep-stamp \ configure-stamp build-arch-cint-stamp config.status config.log +distclean-xrootd: + make distclean-netx + make distclean-proofx + make distclean-proofd + version: $(CINTTMP) @$(MAKEVERSION) @@ -1088,7 +1106,9 @@ changelog: releasenotes: @$(MAKERELNOTES) -html: $(ROOTEXE) changelog releasenotes +ifeq ($(BUILDX11),yes) +ifeq ($(BUILDASIMAGE),yes) +html: rootexecs postbin changelog releasenotes ifneq ($(USECONFIG),FALSE) @if [ "x`which root.exe`" != "x$(DESTDIR)$(BINDIR)/root.exe" ] \ || [ "`which root.exe`" -ot "bin/root.exe" ]; then \ @@ -1099,6 +1119,14 @@ ifneq ($(USECONFIG),FALSE) endif @$(MAKELOGHTML) @$(MAKEHTML) +else +html: + @echo "Error: Generating the html doc requires to enable the asimage component when running configure." && exit 1 +endif +else +html: + @echo "Error: Generating the html doc requires to enable the X11 component when running configure." && exit 1 +endif # Use DESTDIR to set a sandbox prior to calling "make install", e.g.: # ./configure --prefix=/usr/ @@ -1146,8 +1174,6 @@ install: all $(INSTALLDATA) cint/cint/include $(DESTDIR)$(CINTINCDIR)/cint; \ $(INSTALLDATA) cint/cint/lib $(DESTDIR)$(CINTINCDIR)/cint; \ $(INSTALLDATA) cint/cint/stl $(DESTDIR)$(CINTINCDIR)/cint; \ - find $(DESTDIR)$(CINTINCDIR) -name CVS -exec rm -rf {} \; >/dev/null 2>&1; \ - find $(DESTDIR)$(CINTINCDIR) -name .svn -exec rm -rf {} \; >/dev/null 2>&1; \ echo "Installing icons in $(DESTDIR)$(ICONPATH)"; \ $(INSTALLDIR) $(DESTDIR)$(ICONPATH); \ $(INSTALLDATA) icons/*.xpm $(DESTDIR)$(ICONPATH); \ @@ -1156,40 +1182,26 @@ install: all echo "Installing fonts in $(DESTDIR)$(TTFFONTDIR)"; \ $(INSTALLDIR) $(DESTDIR)$(TTFFONTDIR); \ $(INSTALLDATA) fonts/* $(DESTDIR)$(TTFFONTDIR); \ - find $(DESTDIR)$(TTFFONTDIR) -name CVS -exec rm -rf {} \; >/dev/null 2>&1; \ - find $(DESTDIR)$(TTFFONTDIR) -name .svn -exec rm -rf {} \; >/dev/null 2>&1; \ echo "Installing misc docs in $(DESTDIR)$(DOCDIR)"; \ $(INSTALLDIR) $(DESTDIR)$(DOCDIR); \ $(INSTALLDATA) LICENSE $(DESTDIR)$(DOCDIR); \ $(INSTALLDATA) README/* $(DESTDIR)$(DOCDIR); \ - find $(DESTDIR)$(DOCDIR) -name CVS -exec rm -rf {} \; >/dev/null 2>&1; \ - find $(DESTDIR)$(DOCDIR) -name .svn -exec rm -rf {} \; >/dev/null 2>&1; \ echo "Installing tutorials in $(DESTDIR)$(TUTDIR)"; \ $(INSTALLDIR) $(DESTDIR)$(TUTDIR); \ $(INSTALLDATA) tutorials/* $(DESTDIR)$(TUTDIR); \ - find $(DESTDIR)$(TUTDIR) -name CVS -exec rm -rf {} \; >/dev/null 2>&1; \ - find $(DESTDIR)$(TUTDIR) -name .svn -exec rm -rf {} \; >/dev/null 2>&1; \ echo "Installing tests in $(DESTDIR)$(TESTDIR)"; \ $(INSTALLDIR) $(DESTDIR)$(TESTDIR); \ $(INSTALLDATA) test/* $(DESTDIR)$(TESTDIR); \ - find $(DESTDIR)$(TESTDIR) -name CVS -exec rm -rf {} \; >/dev/null 2>&1; \ - find $(DESTDIR)$(TESTDIR) -name .svn -exec rm -rf {} \; >/dev/null 2>&1; \ echo "Installing macros in $(DESTDIR)$(MACRODIR)"; \ $(INSTALLDIR) $(DESTDIR)$(MACRODIR); \ $(INSTALLDATA) macros/* $(DESTDIR)$(MACRODIR); \ - find $(DESTDIR)$(MACRODIR) -name CVS -exec rm -rf {} \; >/dev/null 2>&1; \ - find $(DESTDIR)$(MACRODIR) -name .svn -exec rm -rf {} \; >/dev/null 2>&1; \ echo "Installing man(1) pages in $(DESTDIR)$(MANDIR)"; \ $(INSTALLDIR) $(DESTDIR)$(MANDIR); \ $(INSTALLDATA) man/man1/* $(DESTDIR)$(MANDIR); \ - find $(DESTDIR)$(MANDIR) -name CVS -exec rm -rf {} \; >/dev/null 2>&1; \ - find $(DESTDIR)$(MANDIR) -name .svn -exec rm -rf {} \; >/dev/null 2>&1; \ echo "Installing config files in $(DESTDIR)$(ETCDIR)"; \ rm -f $(DESTDIR)$(ETCDIR)/system.rootmap; \ $(INSTALLDIR) $(DESTDIR)$(ETCDIR); \ $(INSTALLDATA) etc/* $(DESTDIR)$(ETCDIR); \ - find $(DESTDIR)$(ETCDIR) -name CVS -exec rm -rf {} \; >/dev/null 2>&1; \ - find $(DESTDIR)$(ETCDIR) -name .svn -exec rm -rf {} \; >/dev/null 2>&1; \ echo "Installing Autoconf macro in $(DESTDIR)$(ACLOCALDIR)"; \ $(INSTALLDIR) $(DESTDIR)$(ACLOCALDIR); \ $(INSTALLDATA) $(ROOT_SRCDIR)/build/misc/root.m4 $(DESTDIR)$(ACLOCALDIR); \ @@ -1198,8 +1210,6 @@ install: all $(INSTALLDATA) build/misc/root-help.el $(DESTDIR)$(ELISPDIR); \ echo "Installing GDML conversion scripts in $(DESTDIR)$(LIBDIR)"; \ $(INSTALLDATA) $(ROOT_SRCDIR)/geom/gdml/*.py $(DESTDIR)$(LIBDIR); \ - find $(DESTDIR)$(DATADIR) -name CVS -exec rm -rf {} \; >/dev/null 2>&1; \ - find $(DESTDIR)$(DATADIR) -name .svn -exec rm -rf {} \; >/dev/null 2>&1; \ fi uninstall: @@ -1216,13 +1226,18 @@ uninstall: rm -f $(DESTDIR)$(BINDIR)/`basename $(MAKECINT)`; \ rm -f $(DESTDIR)$(BINDIR)/`basename $(ROOTCINTEXE)`; \ rm -f $(DESTDIR)$(BINDIR)/`basename $(RMKDEP)`; \ + rm -f $(DESTDIR)$(BINDIR)/`basename $(RLIBMAP)`; \ if [ "x$(BINDEXP)" != "x" ] ; then \ rm -f $(DESTDIR)$(BINDIR)/`basename $(BINDEXP)`; \ fi; \ rm -f $(DESTDIR)$(BINDIR)/root-config; \ rm -f $(DESTDIR)$(BINDIR)/memprobe; \ - rm -f $(DESTDIR)$(BINDIR)/thisroot.sh; \ - rm -f $(DESTDIR)$(BINDIR)/thisroot.csh; \ + rm -f $(DESTDIR)$(BINDIR)/thisroot.*; \ + rm -f $(DESTDIR)$(BINDIR)/setxrd.*; \ + rm -f $(DESTDIR)$(BINDIR)/genreflex; \ + rm -f $(DESTDIR)$(BINDIR)/genreflex-rootcint; \ + rm -f $(DESTDIR)$(BINDIR)/hist2workspace; \ + rm -f $(DESTDIR)$(BINDIR)/prepareHistFactory; \ for i in $(ALLEXECS) ; do \ rm -f $(DESTDIR)$(BINDIR)/`basename $$i`; \ done; \ @@ -1233,18 +1248,23 @@ uninstall: for lib in $(ALLLIBS) $(CINTLIB) $(ALLMAPS); do \ rm -f $(DESTDIR)$(LIBDIR)/`basename $$lib`* ; \ done; \ - if test "x$(RFLX_GRFLXPY)" != "x"; then \ - rm -f $(DESTDIR)$(LIBDIR)/$(RFLX_GRFLXPY); \ - fi; \ - if test "x$(RFLX_GRFLXPYC)" != "x"; then \ - rm -f $(DESTDIR)$(LIBDIR)/$(RFLX_GRFLXPYC); \ - fi; \ + for lib in lib/*.a lib/*.py lib/*.py*; do \ + rm -f $(DESTDIR)$(LIBDIR)/`basename $$lib`* ; \ + done; \ + rm -f $(DESTDIR)$(LIBDIR)/writer.py ; \ + rm -f $(DESTDIR)$(LIBDIR)/ROOTwriter.py ; \ + for lib in $(RFLX_GRFLXPY); do \ + rm -f $(DESTDIR)$(LIBDIR)/$${lib#lib/}; \ + done; \ + for lib in $(RFLX_GRFLXPYC); do \ + rm -f $(DESTDIR)$(LIBDIR)/$${lib#lib/}; \ + done; \ if test "x$(RFLX_GRFLXPY)$(RFLX_GRFLXPYC)" != "x"; then \ - dir=$(RFLX_GRFLXDD:lib/=); \ + dir=$(subst lib/,,$(RFLX_GRFLXDD)); \ while test "x$${dir}" != "x" && \ test -d $(DESTDIR)$(LIBDIR)/$${dir} && \ - test "x`ls $(DESTDIR)$(INCDIR)/$${dir}`" = "x"; do \ - rm -rf $(DESTDIR)$(INCDIR)/$${dir}; \ + test "x`ls $(DESTDIR)$(LIBDIR)/$${dir}`" = "x"; do \ + rm -rf $(DESTDIR)$(LIBDIR)/$${dir}; \ dir=$(dirname $${dir}); \ done; \ fi; \ @@ -1252,9 +1272,12 @@ uninstall: test "x`ls $(DESTDIR)$(LIBDIR)`" = "x"; then \ rm -rf $(DESTDIR)$(LIBDIR); \ fi ; \ + for i in include/Math/*.icc ; do \ + rm -f $(DESTDIR)$(INCDIR)/Math/`basename $$i`; \ + done ; \ for subdir in \ . \ - Math/GenVector Math \ + Math/GenVector Math Fit \ Reflex/internal Reflex/Builder Reflex \ Cintex GL TMVA Minuit2; do \ if test -d include/$${subdir}; then \ @@ -1269,17 +1292,20 @@ uninstall: done; \ rm -f $(DESTDIR)$(INCDIR)/rmain.cxx; \ rm -rf $(DESTDIR)$(CINTINCDIR); \ - for i in icons/*.xpm ; do \ - rm -fr $(DESTDIR)$(ICONPATH)/`basename $$i`; \ - done; \ - for i in icons/*.png ; do \ + for i in icons/*.xpm icons/*.png icons/*.gif ; do \ rm -fr $(DESTDIR)$(ICONPATH)/`basename $$i`; \ done; \ if test -d $(DESTDIR)$(ICONPATH) && \ test "x`ls $(DESTDIR)$(ICONPATH)`" = "x" ; then \ rm -rf $(DESTDIR)$(ICONPATH); \ fi ; \ - rm -rf $(DESTDIR)$(TTFFONTDIR); \ + for i in fonts/LICENSE fonts/*.ttf fonts/*.otf ; do \ + rm -fr $(DESTDIR)$(TTFFONTDIR)/`basename $$i`; \ + done; \ + if test -d $(DESTDIR)$(TTFFONTDIR) && \ + test "x`ls $(DESTDIR)$(TTFFONTDIR)`" = "x" ; then \ + rm -rf $(DESTDIR)$(TTFFONTDIR); \ + fi ; \ rm -rf $(DESTDIR)$(TUTDIR); \ rm -rf $(DESTDIR)$(TESTDIR); \ rm -rf $(DESTDIR)$(DOCDIR); \ @@ -1298,6 +1324,16 @@ uninstall: test "x`ls $(DESTDIR)$(ETCDIR)`" = "x" ; then \ rm -rf $(DESTDIR)$(ETCDIR); \ fi ; \ + rm -f $(DESTDIR)$(ELISPDIR)/root-help.el; \ + if test -d $(DESTDIR)$(ELISPDIR) && \ + test "x`ls $(DESTDIR)$(ELISPDIR)`" = "x" ; then \ + rm -rf $(DESTDIR)$(ELISPDIR); \ + fi ; \ + rm -f $(DESTDIR)$(ACLOCALDIR)/root.m4; \ + if test -d $(DESTDIR)$(ACLOCALDIR) && \ + test "x`ls $(DESTDIR)$(ACLOCALDIR)`" = "x" ; then \ + rm -rf $(DESTDIR)$(ACLOCALDIR); \ + fi ; \ for i in build/misc/* ; do \ rm -rf $(DESTDIR)$(DATADIR)/`basename $$i`; \ done; \ @@ -1312,7 +1348,6 @@ ifneq ($(ROOT_OBJDIR),$(ROOT_SRCDIR)) runtimedirs: @echo "Rsync'ing $(ROOT_SRCDIR)/etc..."; \ $(RSYNC) \ - --exclude '.svn' \ --exclude root.mimes \ --exclude system.rootauthrc \ --exclude system.rootdaemonrc \ @@ -1321,17 +1356,15 @@ runtimedirs: --exclude proofd.xinetd \ --exclude rootd.rc.d \ --exclude rootd.xinetd \ - --exclude svninfo.txt \ + --exclude gitinfo.txt \ $(ROOT_SRCDIR)/etc . ; \ echo "Rsync'ing $(ROOT_SRCDIR)/macros..."; \ $(RSYNC) \ - --exclude '.svn' \ --exclude html.C \ $(ROOT_SRCDIR)/macros . ; \ for d in icons fonts README tutorials test man; do \ echo "Rsync'ing $(ROOT_SRCDIR)/$$d..."; \ $(RSYNC) \ - --exclude '.svn' \ --exclude '*.o' \ --exclude '*.so' \ --exclude '*.lib' \ @@ -1342,7 +1375,7 @@ endif showbuild: @echo "ROOTSYS = $(ROOTSYS)" - @echo "SVNREV = $(SVNREV)" + @echo "GITREV = $(GITREV)" @echo "PLATFORM = $(PLATFORM)" @echo "OPT = $(OPT)" @echo "" @@ -1391,6 +1424,7 @@ showbuild: @echo "OSTHREADLIB = $(OSTHREADLIB)" @echo "SHIFTLIB = $(SHIFTLIB)" @echo "DCAPLIB = $(DCAPLIB)" + @echo "DAVIXLIB = $(DAVIXLIB)" @echo "GFALLIB = $(GFALLIB)" @echo "MYSQLINCDIR = $(MYSQLINCDIR)" @echo "ORACLEINCDIR = $(ORACLEINCDIR)" @@ -1408,6 +1442,7 @@ showbuild: @echo "GVIZLIB = $(GVIZLIB)" @echo "GVIZINCDIR = $(GVIZINCDIR)" @echo "SAPDBINCDIR = $(SAPDBINCDIR)" + @echo "SQLITEINCDIR = $(SQLITEINCDIR)" @echo "SRPLIBDIR = $(SRPLIBDIR)" @echo "SRPINCDIR = $(SRPINCDIR)" @echo "SRPUTILLIB = $(SRPUTILLIB)" diff --git a/README/CREDITS b/README/CREDITS index 26054cc6e36cb..4feaeed537b5e 100644 --- a/README/CREDITS +++ b/README/CREDITS @@ -275,6 +275,10 @@ N: John Frankland E: frankland@ganil.fr D: TString contributions +N: Oliver Freyermuth +E: o.f@cern.ch +D: SQLite plugin + N: Keisuke Fujii E: fujiik@jlcuxf.kek.jp D: port to MacOS X @@ -369,6 +373,11 @@ N: Marc Hemberger E: hemberg@clri6a.gsi.de D: contributions to the thread classes, SapDB interface +N: Fabio Hernandez +E: fabio@in2p3.fr +D: TS3WebFile with improved Amazon S3 and Huawei support +D: Extend TS3WebFile to also support Google Storage + N: Andreas Hoecker E: Andreas.Hoecker@cern.ch D: author of the TMVA package @@ -723,10 +732,11 @@ D: improvements in TTreePlayer::DrawSelect() N: Manuel Schiller E: schiller@physi.uni-heidelberg.de D: contribution on the Cholesly decomposition in SMatrix +D: contributions in RooFit N: Gregory Schoot E: Gregory.Schott@cern.ch -D: Contributions in RooStats +D: contributions in RooStats N: Jason Seely E: seely@mit.edu @@ -843,3 +853,7 @@ D: contributed to Reflex N: Andreas Zoglauer E: zog@mpe.mpg.de D: contributed to TStyle::CreateGradientColorTable() + +N: Yue Shi Lai +E: ylai@mit.edu +D: TMathText class diff --git a/README/INSTALL b/README/INSTALL index 12c1f33ee6899..35367cd420d07 100644 --- a/README/INSTALL +++ b/README/INSTALL @@ -213,7 +213,7 @@ packages do: %_topdir /redhat - Then you should make the appropiate directories: + Then you should make the appropriate directories: mkdir /redhat mkdir /redhat/SOURCES @@ -688,7 +688,7 @@ libraries from: or you can download the source from the same directory. The original sources can be found via Lunds FTP server. -More information is avaliable from: +More information is available from: http://www.thep.lu.se/~torbjorn/Pythia.html @@ -717,7 +717,7 @@ directory of the ROOT source tree. ------------------------- To build rootd and proofd with support for AFS authentication, you first have to install AFS client libraries system. There are a few AFS -distributions avaliable. +distributions available. * OpenAFS IBMs OpenSource AFS distribution - see diff --git a/README/README.ALIEN b/README/README.ALIEN index 231c5f3d3dfce..015c1fed0637f 100644 --- a/README/README.ALIEN +++ b/README/README.ALIEN @@ -15,7 +15,7 @@ a) // connecting to an API service TGrid::Connect("alien://pcapiserv01.cern.ch:9000","aliprod); // connecting to an API service which is defined already by the - environement variables: + environment variables: export alien_API_HOST=... export alien_API_PORT=... export alien_API_USER=... diff --git a/bindings/pyroot/CMakeLists.txt b/bindings/pyroot/CMakeLists.txt index 6f9df1f54041b..4e1e0106f7294 100644 --- a/bindings/pyroot/CMakeLists.txt +++ b/bindings/pyroot/CMakeLists.txt @@ -9,14 +9,20 @@ ROOT_GENERATE_DICTIONARY(G__PyROOT *.h LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(PyROOT LINKDEF LinkDef.h) ROOT_LINKER_LIBRARY(PyROOT *.cxx G__PyROOT.cxx LIBRARIES RIO Net Hist Graf Graf3d Gpad Tree Matrix Thread ${Reflexlib} ${PYTHON_LIBRARIES}) +if(WIN32) + set_target_properties(PyROOT PROPERTIES SUFFIX ".pyd") +endif() if(MACOSX_MINOR EQUAL 5) ROOT_EXECUTABLE(python64 python64.c LIBRARIES ${PYTHON_LIBRARIES}) endif() #---Install python modules-------------------------------------------------- -install(FILES ROOT.py DESTINATION ${runtimedir}) -install(CODE "execute_process(COMMAND python -m py_compile ${CMAKE_INSTALL_PREFIX}/${runtimedir}/ROOT.py )") -install(CODE "execute_process(COMMAND python -O -m py_compile ${CMAKE_INSTALL_PREFIX}/${runtimedir}/ROOT.py )") +file(GLOB pyfiles RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.py) +foreach(pyfile ${pyfiles}) + install(FILES ${pyfile} DESTINATION ${runtimedir}) + install(CODE "execute_process(COMMAND python -m py_compile \$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${runtimedir}/${pyfile} )") + install(CODE "execute_process(COMMAND python -O -m py_compile \$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${runtimedir}/${pyfile} )") +endforeach() #---Install headers---------------------------------------------------------- ROOT_INSTALL_HEADERS() diff --git a/bindings/pyroot/ROOT.py b/bindings/pyroot/ROOT.py index 49e300a71be3f..ff6feaee90b16 100755 --- a/bindings/pyroot/ROOT.py +++ b/bindings/pyroot/ROOT.py @@ -2,7 +2,7 @@ # @(#)root/pyroot:$Id$ # Author: Wim Lavrijsen (WLavrijsen@lbl.gov) # Created: 02/20/03 -# Last: 11/10/10 +# Last: 02/06/13 """PyROOT user module. @@ -15,7 +15,7 @@ """ -__version__ = '6.1.0' +__version__ = '6.2.0' __author__ = 'Wim Lavrijsen (WLavrijsen@lbl.gov)' @@ -34,7 +34,7 @@ try: import rlcompleter, readline - class FileNameCompleter( rlcompleter.Completer ): + class RootNameCompleter( rlcompleter.Completer ): def file_matches( self, text ): matches = [] path, name = os.path.split( text ) @@ -52,13 +52,31 @@ def file_matches( self, text ): return matches + def root_global_matches( self, text, prefix = '' ): + gClassTable = _root.GetRootGlobal( 'gClassTable' ) + all = [ gClassTable.At(i) for i in xrange(gClassTable.Classes()) ] + all += [ g.GetName() for g in _root.gROOT.GetListOfGlobals() ] + matches = filter( lambda x: x[:len(text)] == text, all ) + return [prefix + x for x in matches] + def global_matches( self, text ): matches = rlcompleter.Completer.global_matches( self, text ) - if not matches: - matches = [] - return matches + self.file_matches( text ) + if not matches: matches = [] + matches += self.file_matches( text ) + return matches - readline.set_completer( FileNameCompleter().complete ) + def attr_matches( self, text ): + matches = rlcompleter.Completer.attr_matches( self, text ) + if not matches: matches = [] + b = text.find('.') + try: + if 0 <= b and self.namespace[text[:b]].__name__ == 'ROOT': + matches += self.root_global_matches( text[b+1:], text[:b+1] ) + except AttributeError: # not all objects have a __name__ + pass + return matches + + readline.set_completer( RootNameCompleter().complete ) readline.set_completer_delims( readline.get_completer_delims().replace( os.sep , '' ) ) @@ -207,9 +225,8 @@ class std( object ): for name in stlclasses: locals()[ name ] = Template( "std::%s" % name ) - string = _root.MakeRootClass( 'string' ) - _root.std = std +sys.modules['ROOT.std'] = std ### special cases for gPad, gVirtualX (are C++ macro's) ------------------------- @@ -229,6 +246,12 @@ def __len__( self ): return 1 return 0 + def __repr__( self ): + return repr( self.func() ) + + def __str__( self ): + return str( self.func() ) + _root.gPad = _ExpandMacroFunction( "TVirtualPad", "Pad" ) _root.gVirtualX = _ExpandMacroFunction( "TVirtualX", "Instance" ) _root.gDirectory = _ExpandMacroFunction( "TDirectory", "CurrentDirectory" ) @@ -291,7 +314,7 @@ def _excepthook( exctype, value, traceb ): value.msg == "can't assign to function call": sys.stdout.write( """Are you trying to assign a value to a reference return, for example to the result of a call to "double& SMatrix<>::operator()(int,int)"? If so, then -please use operator[] instead, as in e.g. "mymatrix[i,j] = somevalue". +please use operator[] instead, as in e.g. "mymatrix[i][j] = somevalue". """ ) # normal exception processing @@ -402,7 +425,7 @@ def __setattr2( self, name, value ): # "running" getattr return super( self.__class__, self ).__setattr__( name, value ) def __getattr1( self, name ): # "start-up" getattr - # special case, to allow "from ROOT import gROOT" w/o starting GUI thread + # special case, to allow "from ROOT import gROOT" w/o sending GUI events if name == '__path__': raise AttributeError( name ) @@ -416,6 +439,11 @@ def __getattr1( self, name ): # "start-up" getattr def __getattr2( self, name ): # "running" getattr # handle "from ROOT import *" ... can be called multiple times if name == '__all__': + if '__IPYTHON__' in __builtins__: + import warnings + warnings.warn( '"from ROOT import *" is not supported under IPython' ) + # continue anyway, just in case it works ... + caller = sys.modules[ sys._getframe( 1 ).f_globals[ '__name__' ] ] # we may be calling in from __getattr1, verify and if so, go one frame up @@ -482,10 +510,13 @@ def __finalSetup( self ): if hasargv and PyConfig.IgnoreCommandLineOptions: sys.argv = argv + # now add 'string' to std so as to not confuse with module string + std.string = _root.MakeRootClass( 'string' ) + # must be called after gApplication creation: if '__IPYTHON__' in __builtins__: # IPython's FakeModule hack otherwise prevents usage of python from CINT - _root.gROOT.ProcessLine( 'TPython::Exec( "" )' ) + _root.gROOT.ProcessLine( 'TPython::Exec( "" );' ) sys.modules[ '__main__' ].__builtins__ = __builtins__ # custom logon file (must be after creation of ROOT globals) @@ -510,24 +541,31 @@ def __finalSetup( self ): appc.ExecuteFile( rootlogon ) del rootlogon, logons - # root thread, if needed, to prevent GUIs from starving, as needed + # use either the input hook or thread to send events to GUIs if self.PyConfig.StartGuiThread and \ not ( self.keeppolling or _root.gROOT.IsBatch() ): - import threading - self.__dict__[ 'keeppolling' ] = 1 - self.__dict__[ 'PyGUIThread' ] = \ - threading.Thread( None, _processRootEvents, None, ( self, ) ) - - def _finishSchedule( ROOT = self ): + if self.PyConfig.StartGuiThread == 'inputhook' or\ + _root.gSystem.InheritsFrom( 'TMacOSXSystem' ): + # new, PyOS_InputHook based mechanism + if PyConfig.GUIThreadScheduleOnce: + for guicall in PyConfig.GUIThreadScheduleOnce: + guicall() + PyConfig.GUIThreadScheduleOnce = [] + _root.InstallGUIEventInputHook() + else: + # original, threading based approach import threading + self.__dict__[ 'keeppolling' ] = 1 + self.__dict__[ 'PyGUIThread' ] = \ + threading.Thread( None, _processRootEvents, None, ( self, ) ) + + self.PyGUIThread.setDaemon( 1 ) + self.PyGUIThread.start() + if threading.currentThread() != self.PyGUIThread: while self.PyConfig.GUIThreadScheduleOnce: self.PyGUIThread.join( 0.1 ) - self.PyGUIThread.finishSchedule = _finishSchedule - self.PyGUIThread.setDaemon( 1 ) - self.PyGUIThread.start() - # store already available ROOT objects to prevent spurious lookups for name in self.module.__pseudo__all__ + _memPolicyAPI + _sigPolicyAPI: self.__dict__[ name ] = getattr( _root, name ) @@ -554,7 +592,13 @@ def cleanup(): facade = sys.modules[ __name__ ] - # prevent spurious lookups into ROOT libraries + # reset gRootModule on the C++ side to prevent fruther lookups + _root._ResetRootModule() + + # shutdown GUI thread, as appropriate (always save to call) + _root.RemoveGUIEventInputHook() + + # prevent further spurious lookups into ROOT libraries del facade.__class__.__getattr__ del facade.__class__.__setattr__ diff --git a/bindings/pyroot/cppyy.py b/bindings/pyroot/cppyy.py new file mode 100644 index 0000000000000..fe6082e365dcc --- /dev/null +++ b/bindings/pyroot/cppyy.py @@ -0,0 +1,180 @@ +""" PyCintex compatibility module. + This module allows transferring away from PyCintex from ROOT v5 to v6. + It provides both the original PyCintex.py (most code here is copied over + from PyCintex.py) as well as the newer cppyy (from PyPy) APIs. In ROOT6, + these codes are consolidated. +""" + +import sys, string + +### PyPy has 'cppyy' builtin (if enabled, that is) +if 'cppyy' in sys.builtin_module_names: + _builtin_cppyy = True + + import imp + sys.modules[ __name__ ] = \ + imp.load_module( 'cppyy', *(None, 'cppyy', ('', '', imp.C_BUILTIN) ) ) + del imp + + _thismodule = sys.modules[ __name__ ] + _backend = _thismodule.gbl + + # custom behavior that is not yet part of PyPy's cppyy + def _MakeRootClass( self, name ): + return getattr( self, name ) + type(_backend).MakeRootClass = _MakeRootClass + + def _LookupRootEntity( self, name ): + return getattr( self, name ) + type(_backend).LookupRootEntity = _LookupRootEntity + + class _Double(float): pass + type(_backend).Double = _Double + + def _AddressOf( self, obj ): + import array + return array.array('L', [_thismodule.addressof( obj )] ) + type(_backend).AddressOf = _AddressOf + + del _AddressOf, _Double, _LookupRootEntity, _MakeRootClass + +else: + _builtin_cppyy = False + + # load PyROOT C++ extension module, special case for linux and Sun + needsGlobal = ( 0 <= string.find( sys.platform, 'linux' ) ) or\ + ( 0 <= string.find( sys.platform, 'sunos' ) ) + if needsGlobal: + # change dl flags to load dictionaries from pre-linked .so's + dlflags = sys.getdlopenflags() + sys.setdlopenflags( 0x100 | 0x2 ) # RTLD_GLOBAL | RTLD_NOW + + import libPyROOT as _backend + + # reset dl flags if needed + if needsGlobal: + sys.setdlopenflags( dlflags ) + del needsGlobal + +# PyCintex tests rely on this, but they should not: +sys.modules[ __name__ ].libPyROOT = _backend + +if not _builtin_cppyy: + _backend.SetMemoryPolicy( _backend.kMemoryStrict ) +_backend.MakeRootClass( 'PyROOT::TPyROOTApplication' ).InitCINTMessageCallback() + +#--- Enable Autoloading ignoring possible error for the time being +try: _backend.gInterpreter.EnableAutoLoading() +except: pass + + +### template support ------------------------------------------------------------ +if not _builtin_cppyy: + class Template: + def __init__( self, name ): + self.__name__ = name + + def __call__( self, *args ): + newargs = [ self.__name__[ 0 <= self.__name__.find( 'std::' ) and 5 or 0:] ] + for arg in args: + if type(arg) == str: + arg = ','.join( map( lambda x: x.strip(), arg.split(',') ) ) + newargs.append( arg ) + result = _backend.MakeRootTemplateClass( *newargs ) + + # special case pythonization (builtin_map is not available from the C-API) + if hasattr( result, 'push_back' ): + def iadd( self, ll ): + [ self.push_back(x) for x in ll ] + return self + + result.__iadd__ = iadd + + return result + + _backend.Template = Template + + +#--- LoadDictionary function and aliases ----------------------------- +def loadDictionary(name) : + # prepend "lib" + if sys.platform != 'win32' and name[:3] != 'lib' : + name = 'lib' + name + sc = _backend.gSystem.Load(name) + if sc == -1 : raise RuntimeError("Error Loading dictionary") +loadDict = loadDictionary + +#--- Load Cintex module and enable conversions Reflex->CINT----------- +# TSystem::Load() already knows that cintex depends on reflex. +# _backend.gSystem.Load('libReflex') +_backend.gSystem.Load( 'libCintex' ) + +Cintex = _backend.MakeRootClass( 'Cintex' ) +Cintex.SetDebug(0) +Cintex.Enable() + +#--- Other functions needed ------------------------------------------- +if not _builtin_cppyy: + class _stdmeta( type ): + def __getattr__( cls, attr ): # for non-templated classes in std + klass = _backend.MakeRootClass( attr, cls ) + setattr( cls, attr, klass ) + return klass + + class _global_cpp: + class std( object ): + __metaclass__ = _stdmeta + + stlclasses = ( 'complex', 'pair', \ + 'deque', 'list', 'queue', 'stack', 'vector', 'map', 'multimap', 'set', 'multiset' ) + + for name in stlclasses: + locals()[ name ] = Template( 'std::%s' % name ) + + _backend.gROOT.ProcessLine( "#include " ) + string = _backend.MakeRootClass( 'string' ) + + _backend.SetRootLazyLookup( _global_cpp.__dict__ ) +else: + _global_cpp = _backend + +def Namespace( name ) : + if name == '' : return _global_cpp + else : return _backend.LookupRootEntity( name ) +makeNamespace = Namespace + +def makeClass( name ) : + return _backend.MakeRootClass( name ) + +def addressOf( obj ) : + return _backend.AddressOf( obj )[0] + +def getAllClasses() : + TClassTable = makeClass( 'TClassTable' ) + TClassTable.Init() + classes = [] + while True : + c = TClassTable.Next() + if c : classes.append( c ) + else : break + return classes + +#--- Global namespace and global objects ------------------------------- +gbl = _global_cpp +NULL = 0 # _backend.GetRootGlobal returns a descriptor, which needs a class +class double(float): pass +class short(int): pass +class long_int(int): pass +class unsigned_short(int): pass +class unsigned_int(int): pass +class unsigned_long(long): pass + +#--- Copy over locally defined names ------------------------------------ +if _builtin_cppyy: + for name in dir(): + if name[0] != '_': setattr( _thismodule, name, eval(name) ) + + +#--- For test purposes -------------------------------------------------- +if __name__ == '__main__' : + loadDict( 'test_CintexDict' ) diff --git a/bindings/pyroot/inc/TPython.h b/bindings/pyroot/inc/TPython.h index e74522161ab71..500962ff57126 100644 --- a/bindings/pyroot/inc/TPython.h +++ b/bindings/pyroot/inc/TPython.h @@ -50,11 +50,16 @@ class TPython { static Bool_t ObjectProxy_Check( PyObject* pyobject ); static Bool_t ObjectProxy_CheckExact( PyObject* pyobject ); +// type verifiers for MethodProxy + static Bool_t MethodProxy_Check( PyObject* pyobject ); + static Bool_t MethodProxy_CheckExact( PyObject* pyobject ); + // object proxy to void* conversion static void* ObjectProxy_AsVoidPtr( PyObject* pyobject ); // void* to object proxy conversion, returns a new reference - static PyObject* ObjectProxy_FromVoidPtr( void* addr, const char* classname ); + static PyObject* ObjectProxy_FromVoidPtr( + void* addr, const char* classname, Bool_t python_owns = kFALSE ); virtual ~TPython() { } ClassDef(TPython,0) //Access to the python interpreter diff --git a/bindings/pyroot/src/Adapters.cxx b/bindings/pyroot/src/Adapters.cxx index 6f235ba99bd37..6a327b224f95a 100644 --- a/bindings/pyroot/src/Adapters.cxx +++ b/bindings/pyroot/src/Adapters.cxx @@ -4,6 +4,7 @@ #include "Utility.h" // ROOT +#include "TInterpreter.h" #include "TBaseClass.h" #include "TClass.h" #include "TClassEdit.h" @@ -236,16 +237,21 @@ PyROOT::TScopeAdapter::TScopeAdapter( const TMemberAdapter& mb ) : } //____________________________________________________________________________ -PyROOT::TScopeAdapter PyROOT::TScopeAdapter::ByName( const std::string & name, Bool_t quiet ) +PyROOT::TScopeAdapter PyROOT::TScopeAdapter::ByName( const std::string& name, Bool_t quiet ) { // lookup a scope (class) by name Int_t oldEIL = gErrorIgnoreLevel; if ( quiet ) gErrorIgnoreLevel = 3000; - TClass* klass = TClass::GetClass( name.c_str() ); + TClassRef klass( name.c_str() ); + if (klass.GetClass() && klass->GetListOfAllPublicMethods()->GetSize() == 0) { + // sometimes I/O interferes, leading to zero methods: reload from CINT + ClassInfo_t* cl = gInterpreter->ClassInfo_Factory( name.c_str() ); + if ( cl ) gInterpreter->SetClassInfo( klass, kTRUE ); + } gErrorIgnoreLevel = oldEIL; - return klass; + return klass.GetClass(); } //____________________________________________________________________________ diff --git a/bindings/pyroot/src/ClassMethodHolder.cxx b/bindings/pyroot/src/ClassMethodHolder.cxx index cdb4171784736..23b141ed2bd3b 100644 --- a/bindings/pyroot/src/ClassMethodHolder.cxx +++ b/bindings/pyroot/src/ClassMethodHolder.cxx @@ -18,7 +18,7 @@ PyROOT::TClassMethodHolder< T, M >::TClassMethodHolder( const T& klass, const M& //- public members -------------------------------------------------------------- template< class T, class M > PyObject* PyROOT::TClassMethodHolder< T, M >::operator()( - ObjectProxy*, PyObject* args, PyObject* kwds, Long_t user ) + ObjectProxy*, PyObject* args, PyObject* kwds, Long_t user, Bool_t release_gil ) { // preliminary check in case keywords are accidently used (they are ignored otherwise) if ( kwds != 0 && PyDict_Size( kwds ) ) { @@ -35,7 +35,7 @@ PyObject* PyROOT::TClassMethodHolder< T, M >::operator()( return 0; // important: 0, not Py_None // execute function - return this->Execute( 0 ); + return this->Execute( 0, release_gil ); } //____________________________________________________________________________ diff --git a/bindings/pyroot/src/ClassMethodHolder.h b/bindings/pyroot/src/ClassMethodHolder.h index 32a14338c6407..f26ef0326a271 100644 --- a/bindings/pyroot/src/ClassMethodHolder.h +++ b/bindings/pyroot/src/ClassMethodHolder.h @@ -27,7 +27,8 @@ namespace PyROOT { virtual PyCallable* Clone() { return new TClassMethodHolder( *this ); } - virtual PyObject* operator()( ObjectProxy*, PyObject* args, PyObject* kwds, Long_t = 0 ); + virtual PyObject* operator()( ObjectProxy*, PyObject* args, PyObject* kwds, + Long_t user = 0, Bool_t release_gil = kFALSE ); }; } // namespace PyROOT diff --git a/bindings/pyroot/src/ConstructorHolder.cxx b/bindings/pyroot/src/ConstructorHolder.cxx index 6b74fb877b2d6..a58d6516f38d9 100644 --- a/bindings/pyroot/src/ConstructorHolder.cxx +++ b/bindings/pyroot/src/ConstructorHolder.cxx @@ -72,7 +72,7 @@ namespace PyROOT { #ifdef PYROOT_USE_REFLEX template<> PyObject* TConstructorHolder< ROOT::Reflex::Scope, ROOT::Reflex::Member >::operator()( - ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t user ) + ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t user, Bool_t release_gil ) { // preliminary check in case keywords are accidently used (they are ignored otherwise) if ( kwds != 0 && PyDict_Size( kwds ) ) { @@ -95,7 +95,7 @@ PyObject* TConstructorHolder< ROOT::Reflex::Scope, ROOT::Reflex::Member >::opera } // perform the call, and set address if successful - Long_t address = (Long_t)this->Execute( 0 ); + Long_t address = (Long_t)this->Execute( 0, release_gil ); if ( address != 0 ) { Py_INCREF( self ); @@ -123,7 +123,7 @@ PyObject* TConstructorHolder< ROOT::Reflex::Scope, ROOT::Reflex::Member >::opera template< class T, class M > PyObject* PyROOT::TConstructorHolder< T, M >::operator()( - ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t user ) + ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t user, Bool_t release_gil ) { // preliminary check in case keywords are accidently used (they are ignored otherwise) if ( kwds != 0 && PyDict_Size( kwds ) ) { @@ -155,7 +155,7 @@ PyObject* PyROOT::TConstructorHolder< T, M >::operator()( TClass* klass = (TClass*)this->GetClass().Id(); // perform the call (fails for loaded macro's) - Long_t address = (Long_t)this->Execute( klass ); + Long_t address = (Long_t)this->Execute( klass, release_gil ); if ( ! address && ( ! PyErr_Occurred() /* exception thrown */ ) ) { // the ctor call fails for interpreted classes, can deal with limited info, or // otherwise only deal with default ctor diff --git a/bindings/pyroot/src/ConstructorHolder.h b/bindings/pyroot/src/ConstructorHolder.h index a2a1eabd7e32e..430c0a143da93 100644 --- a/bindings/pyroot/src/ConstructorHolder.h +++ b/bindings/pyroot/src/ConstructorHolder.h @@ -33,7 +33,8 @@ namespace PyROOT { virtual PyCallable* Clone() { return new TConstructorHolder( *this ); } public: - virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t = 0 ); + virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject* kwds, + Long_t user = 0, Bool_t release_gil = kFALSE ); protected: virtual Bool_t InitExecutor_( TExecutor*& ); diff --git a/bindings/pyroot/src/Converters.cxx b/bindings/pyroot/src/Converters.cxx index 58d35fe67a9d1..326f1046ecb7e 100644 --- a/bindings/pyroot/src/Converters.cxx +++ b/bindings/pyroot/src/Converters.cxx @@ -174,7 +174,7 @@ Bool_t PyROOT::TLongRefConverter::SetArg( return kTRUE; #else para.fLong = 0; func = 0; - return kFALSE; // there no longer is a PyIntObject in p3 + return (Bool_t)func; // there no longer is a PyIntObject in p3 #endif } @@ -571,6 +571,15 @@ Bool_t PyROOT::TNonConstCStringConverter::SetArg( return CArraySetArg( pyobject, para, func, 'c', sizeof(char) ); } +//____________________________________________________________________________ +PyObject* PyROOT::TNonConstCStringConverter::FromMemory( void* address ) +{ +// assume this is a buffer access if the size is known; otherwise assume string + if ( fMaxSize != UINT_MAX ) + return PyROOT_PyUnicode_FromStringAndSize( *(char**)address, fMaxSize ); + return this->TCStringConverter::FromMemory( address ); +} + //____________________________________________________________________________ Bool_t PyROOT::TNonConstUCStringConverter::SetArg( PyObject* pyobject, TParameter_t& para, G__CallFunc* func, Long_t ) @@ -747,8 +756,8 @@ Bool_t PyROOT::TLongLongArrayConverter::SetArg( //- converters for special cases ---------------------------------------------- #define PYROOT_IMPLEMENT_STRING_AS_PRIMITIVE_CONVERTER( name, type, F1, F2 ) \ -PyROOT::T##name##Converter::T##name##Converter() : \ - TRootObjectConverter( TClass::GetClass( #type ) ) {} \ +PyROOT::T##name##Converter::T##name##Converter( Bool_t keepControl ) : \ + TRootObjectConverter( TClass::GetClass( #type ), keepControl ) {} \ \ Bool_t PyROOT::T##name##Converter::SetArg( \ PyObject* pyobject, TParameter_t& para, G__CallFunc* func, Long_t user )\ @@ -868,9 +877,15 @@ Bool_t PyROOT::TRootObjectConverter::ToMemory( PyObject* value, void* address ) if ( ! KeepControl() && Utility::gMemoryPolicy != Utility::kStrict ) ((ObjectProxy*)value)->Release(); - // TODO: fix this, as this is sooo wrong ... - memcpy( (void*)address, ((ObjectProxy*)value)->GetObject(), fClass->Size() ); - return kTRUE; + // call assignment operator through a temporarily wrapped object proxy + PyObject* pyobj = BindRootObjectNoCast( address, fClass.GetClass() ); + ((ObjectProxy*)pyobj)->Release(); // TODO: might be recycled (?) + PyObject* result = PyObject_CallMethod( pyobj, (char*)"__assign__", (char*)"O", value ); + Py_DECREF( pyobj ); + if ( result ) { + Py_DECREF( result ); + return kTRUE; + } } return kFALSE; @@ -1074,9 +1089,9 @@ PyROOT::TConverter* PyROOT::CreateConverter( const std::string& fullType, Long_t } else if ( ti.Property() & G__BIT_ISENUM ) { // special case (CINT): represent enums as unsigned integers - if ( cpd == "&" ) - h = gConvFactories.find( "long&" ); - else + if ( cpd == "&" ) { + h = isConst ? gConvFactories.find( "const long&" ) : gConvFactories.find( "long&" ); + } else h = gConvFactories.find( "UInt_t" ); } @@ -1203,7 +1218,7 @@ namespace { NFp_t( "const char*", &CreateCStringConverter ), NFp_t( "char*", &CreateNonConstCStringConverter ), NFp_t( "TString", &CreateTStringConverter ), - NFp_t( "TString&", &CreateTStringConverter ), + NFp_t( "const TString&", &CreateTStringConverter ), NFp_t( "std::string", &CreateSTLStringConverter ), NFp_t( "string", &CreateSTLStringConverter ), NFp_t( "const std::string&", &CreateSTLStringConverter ), diff --git a/bindings/pyroot/src/Converters.h b/bindings/pyroot/src/Converters.h index da2cd6e5855d1..7b16d464d1324 100644 --- a/bindings/pyroot/src/Converters.h +++ b/bindings/pyroot/src/Converters.h @@ -121,7 +121,7 @@ namespace PyROOT { virtual PyObject* FromMemory( void* address ); virtual Bool_t ToMemory( PyObject* value, void* address ); - private: + protected: std::string fBuffer; UInt_t fMaxSize; }; @@ -132,11 +132,12 @@ namespace PyROOT { public: virtual Bool_t SetArg( PyObject*, TParameter_t&, G__CallFunc* = 0, Long_t = 0 ); + virtual PyObject* FromMemory( void* address ); }; - class TNonConstUCStringConverter : public TCStringConverter { + class TNonConstUCStringConverter : public TNonConstCStringConverter { public: - TNonConstUCStringConverter( UInt_t maxSize = UINT_MAX ) : TCStringConverter( maxSize ) {} + TNonConstUCStringConverter( UInt_t maxSize = UINT_MAX ) : TNonConstCStringConverter( maxSize ) {} public: virtual Bool_t SetArg( PyObject*, TParameter_t&, G__CallFunc* = 0, Long_t = 0 ); @@ -226,7 +227,7 @@ namespace PyROOT { #define PYROOT_DECLARE_STRING_CONVERTER( name, strtype ) \ class T##name##Converter : public TRootObjectConverter { \ public: \ - T##name##Converter(); \ + T##name##Converter( Bool_t keepControl = kTRUE ); \ public: \ virtual Bool_t SetArg( PyObject*, TParameter_t&, G__CallFunc* = 0, Long_t = 0 );\ virtual PyObject* FromMemory( void* address ); \ diff --git a/bindings/pyroot/src/Executors.cxx b/bindings/pyroot/src/Executors.cxx index 0dbae7486857c..6e03e64e824e3 100644 --- a/bindings/pyroot/src/Executors.cxx +++ b/bindings/pyroot/src/Executors.cxx @@ -28,61 +28,113 @@ PyROOT::ExecFactories_t PyROOT::gExecFactories; +//- helpers ------------------------------------------------------------------- +static inline +void PRCallFuncExec( G__CallFunc* func, void* self, Bool_t release_gil ) { + if ( release_gil ) { + Py_BEGIN_ALLOW_THREADS + func->Exec( self ); + Py_END_ALLOW_THREADS + } else + func->ExecInt( self ); +} + +static inline +Long_t PRCallFuncExecInt( G__CallFunc* func, void* self, Bool_t release_gil ) { + Long_t result; + if ( release_gil ) { + Py_BEGIN_ALLOW_THREADS + result = (Long_t)func->ExecInt( self ); + Py_END_ALLOW_THREADS + } else + result = (Long_t)func->ExecInt( self ); + return result; +} + +static inline +Double_t PRCallFuncExecDouble( G__CallFunc* func, void* self, Bool_t release_gil ) { + Double_t result; + if ( release_gil ) { + Py_BEGIN_ALLOW_THREADS + result = (Double_t)func->ExecDouble( self ); + Py_END_ALLOW_THREADS + } else + result = (Double_t)func->ExecDouble( self ); + return result; +} + + //- executors for built-ins --------------------------------------------------- -PyObject* PyROOT::TBoolExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TBoolExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python bool return value - PyObject* result = (Bool_t)func->ExecInt( self ) ? Py_True : Py_False; + PyObject* result = + (Bool_t)PRCallFuncExecInt( func, self, release_gil ) ? Py_True : Py_False; Py_INCREF( result ); return result; } -PyObject* PyROOT::TLongExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TLongExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python long return value - return PyLong_FromLong( (Long_t)func->ExecInt( self ) ); + return PyLong_FromLong( (Long_t)PRCallFuncExecInt( func, self, release_gil ) ); } //____________________________________________________________________________ -PyObject* PyROOT::TCharExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TCharExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python string return value - return PyROOT_PyUnicode_FromFormat( "%c", (Int_t)func->ExecInt( self ) ); + return PyROOT_PyUnicode_FromFormat( "%c", (Int_t)PRCallFuncExecInt( func, self, release_gil ) ); } //____________________________________________________________________________ -PyObject* PyROOT::TIntExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TIntExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python int return value - return PyInt_FromLong( (Long_t)func->ExecInt( self ) ); + return PyInt_FromLong( (Long_t)PRCallFuncExecInt( func, self, release_gil ) ); } //____________________________________________________________________________ -PyObject* PyROOT::TULongExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TULongExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python unsigned long return value - return PyLong_FromUnsignedLong( (ULong_t)func->ExecInt( self ) ); + return PyLong_FromUnsignedLong( (ULong_t)PRCallFuncExecInt( func, self, release_gil ) ); } //____________________________________________________________________________ -PyObject* PyROOT::TLongLongExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TLongLongExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python long long return value - return PyLong_FromLongLong( (Long64_t)G__Longlong( func->Execute( self ) ) ); + Long64_t result; + if ( release_gil ) { + Py_BEGIN_ALLOW_THREADS + result = (Long64_t)G__Longlong( func->Execute( self ) ); + Py_END_ALLOW_THREADS + } else + result = (Long64_t)G__Longlong( func->Execute( self ) ); + return PyLong_FromLongLong( result ); } //____________________________________________________________________________ -PyObject* PyROOT::TULongLongExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TULongLongExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python unsigned long long return value - return PyLong_FromUnsignedLongLong( (ULong64_t)G__ULonglong( func->Execute( self ) ) ); + ULong64_t result; + if ( release_gil ) { + Py_BEGIN_ALLOW_THREADS + result = (ULong64_t)G__ULonglong( func->Execute( self ) ); + Py_END_ALLOW_THREADS + } else + result = (ULong64_t)G__ULonglong( func->Execute( self ) ); + + return PyLong_FromUnsignedLongLong( result ); } //____________________________________________________________________________ -PyObject* PyROOT::TDoubleExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TDoubleExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python float return value - return PyFloat_FromDouble( (Double_t)func->ExecDouble( self ) ); + return PyFloat_FromDouble( (Double_t)PRCallFuncExecDouble( func, self, release_gil ) ); } //____________________________________________________________________________ @@ -101,10 +153,10 @@ Bool_t PyROOT::TRefExecutor::SetAssignable( PyObject* pyobject ) //____________________________________________________________________________ #define PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( name, type, stype, F1, F2, CF ) \ -PyObject* PyROOT::T##name##RefExecutor::Execute( G__CallFunc* func, void* self )\ +PyObject* PyROOT::T##name##RefExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) \ { \ if ( ! fAssignable ) \ - return F1( (stype)func->CF( self ) ); \ + return F1( (stype)CF( func, self, release_gil ) ); \ else { \ const G__value& result = func->Execute( self ); \ *((type*)result.ref) = (type)F2( fAssignable ); \ @@ -115,24 +167,24 @@ PyObject* PyROOT::T##name##RefExecutor::Execute( G__CallFunc* func, void* self ) } \ } -PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( Short, Short_t, Long_t, PyInt_FromLong, PyLong_AsLong, ExecInt ) -PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( UShort, UShort_t, ULong_t, PyInt_FromLong, PyLongOrInt_AsULong, ExecInt ) -PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( Int, Int_t, Long_t, PyInt_FromLong, PyLong_AsLong, ExecInt ) -PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( UInt, UInt_t, ULong_t, PyLong_FromUnsignedLong, PyLongOrInt_AsULong, ExecInt ) -PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( Long, Long_t, Long_t, PyLong_FromLong, PyLong_AsLong, ExecInt ) -PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( ULong, ULong_t, ULong_t, PyLong_FromUnsignedLong, PyLongOrInt_AsULong, ExecInt ) -PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( Float, Float_t, Double_t, PyFloat_FromDouble, PyFloat_AsDouble, ExecDouble ) -PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( Double, Double_t, Double_t, PyFloat_FromDouble, PyFloat_AsDouble, ExecDouble ) +PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( Short, Short_t, Long_t, PyInt_FromLong, PyLong_AsLong, PRCallFuncExecInt ) +PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( UShort, UShort_t, ULong_t, PyInt_FromLong, PyLongOrInt_AsULong, PRCallFuncExecInt ) +PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( Int, Int_t, Long_t, PyInt_FromLong, PyLong_AsLong, PRCallFuncExecInt ) +PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( UInt, UInt_t, ULong_t, PyLong_FromUnsignedLong, PyLongOrInt_AsULong, PRCallFuncExecInt ) +PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( Long, Long_t, Long_t, PyLong_FromLong, PyLong_AsLong, PRCallFuncExecInt ) +PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( ULong, ULong_t, ULong_t, PyLong_FromUnsignedLong, PyLongOrInt_AsULong, PRCallFuncExecInt ) +PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( Float, Float_t, Double_t, PyFloat_FromDouble, PyFloat_AsDouble, PRCallFuncExecDouble ) +PYROOT_IMPLEMENT_BASIC_REFEXECUTOR( Double, Double_t, Double_t, PyFloat_FromDouble, PyFloat_AsDouble, PRCallFuncExecDouble ) //____________________________________________________________________________ -PyObject* PyROOT::TSTLStringRefExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TSTLStringRefExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , return python string return value if ( ! fAssignable ) { - std::string* result = (std::string*)func->ExecInt( self ); + std::string* result = (std::string*)PRCallFuncExecInt( func, self, release_gil ); return PyROOT_PyUnicode_FromStringAndSize( result->c_str(), result->size() ); } else { - std::string* result = (std::string*)func->ExecInt( self ); + std::string* result = (std::string*)PRCallFuncExecInt( func, self, release_gil ); *result = std::string( PyROOT_PyUnicode_AsString( fAssignable ), PyROOT_PyUnicode_GET_SIZE( fAssignable ) ); @@ -145,19 +197,19 @@ PyObject* PyROOT::TSTLStringRefExecutor::Execute( G__CallFunc* func, void* self } //____________________________________________________________________________ -PyObject* PyROOT::TVoidExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TVoidExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , return None - func->Exec( self ); + PRCallFuncExec( func, self, release_gil ); Py_INCREF( Py_None ); return Py_None; } //____________________________________________________________________________ -PyObject* PyROOT::TCStringExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TCStringExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python string return value - char* result = (char*)func->ExecInt( self ); + char* result = (char*)PRCallFuncExecInt( func, self, release_gil ); if ( ! result ) { Py_INCREF( PyStrings::gEmptyString ); return PyStrings::gEmptyString; @@ -168,17 +220,17 @@ PyObject* PyROOT::TCStringExecutor::Execute( G__CallFunc* func, void* self ) //- pointer/array executors --------------------------------------------------- -PyObject* PyROOT::TVoidArrayExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TVoidArrayExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python long return value - return BufFac_t::Instance()->PyBuffer_FromMemory( (Long_t*)func->ExecInt( self ), 1 ); + return BufFac_t::Instance()->PyBuffer_FromMemory( (Long_t*)PRCallFuncExecInt( func, self, release_gil ), 1 ); } //____________________________________________________________________________ #define PYROOT_IMPLEMENT_ARRAY_EXECUTOR( name, type ) \ -PyObject* PyROOT::T##name##ArrayExecutor::Execute( G__CallFunc* func, void* self )\ +PyObject* PyROOT::T##name##ArrayExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) \ { \ - return BufFac_t::Instance()->PyBuffer_FromMemory( (type*)func->ExecInt( self ) );\ + return BufFac_t::Instance()->PyBuffer_FromMemory( (type*)PRCallFuncExecInt( func, self, release_gil ) ); \ } PYROOT_IMPLEMENT_ARRAY_EXECUTOR( Bool, Bool_t ) @@ -193,10 +245,10 @@ PYROOT_IMPLEMENT_ARRAY_EXECUTOR( Double, Double_t ) //- special cases ------------------------------------------------------------ -PyObject* PyROOT::TSTLStringExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TSTLStringExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python string return value - std::string* result = (std::string*)func->ExecInt( self ); + std::string* result = (std::string*)PRCallFuncExecInt( func, self, release_gil ); if ( ! result ) { Py_INCREF( PyStrings::gEmptyString ); return PyStrings::gEmptyString; @@ -213,24 +265,24 @@ PyObject* PyROOT::TSTLStringExecutor::Execute( G__CallFunc* func, void* self ) } //____________________________________________________________________________ -PyObject* PyROOT::TTGlobalExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TTGlobalExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python ROOT object return value - return BindRootGlobal( (TGlobal*)func->ExecInt( self ) ); + return BindRootGlobal( (TGlobal*)PRCallFuncExecInt( func, self, release_gil ) ); } //____________________________________________________________________________ -PyObject* PyROOT::TRootObjectExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TRootObjectExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , construct python ROOT object return value - return BindRootObject( (void*)func->ExecInt( self ), fClass ); + return BindRootObject( (void*)PRCallFuncExecInt( func, self, release_gil ), fClass ); } //____________________________________________________________________________ -PyObject* PyROOT::TRootObjectByValueExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TRootObjectByValueExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execution will bring a temporary in existence - void* result = (void*)func->ExecInt( self ); + void* result = (void*)PRCallFuncExecInt( func, self, release_gil ); if ( ! result ) { if ( ! PyErr_Occurred() ) // callee may have set a python error itself PyErr_SetString( PyExc_ValueError, "NULL result where temporary expected" ); @@ -251,10 +303,10 @@ PyObject* PyROOT::TRootObjectByValueExecutor::Execute( G__CallFunc* func, void* } //____________________________________________________________________________ -PyObject* PyROOT::TRootObjectRefExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TRootObjectRefExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // executor binds the result to the left-hand side, overwriting if an old object - PyObject* result = BindRootObject( (void*)func->ExecInt( self ), fClass ); + PyObject* result = BindRootObject( (void*)PRCallFuncExecInt( func, self, release_gil ), fClass ); if ( ! result || ! fAssignable ) return result; else { @@ -277,17 +329,17 @@ PyObject* PyROOT::TRootObjectRefExecutor::Execute( G__CallFunc* func, void* self } //____________________________________________________________________________ -PyObject* PyROOT::TConstructorExecutor::Execute( G__CallFunc* func, void* klass ) +PyObject* PyROOT::TConstructorExecutor::Execute( G__CallFunc* func, void* klass, Bool_t release_gil ) { // package return address in PyObject* for caller to handle appropriately - return (PyObject*)func->ExecInt( klass ); + return (PyObject*)PRCallFuncExecInt( func, klass, release_gil ); } //____________________________________________________________________________ -PyObject* PyROOT::TPyObjectExecutor::Execute( G__CallFunc* func, void* self ) +PyObject* PyROOT::TPyObjectExecutor::Execute( G__CallFunc* func, void* self, Bool_t release_gil ) { // execute with argument , return python object - return (PyObject*)func->ExecInt( self ); + return (PyObject*)PRCallFuncExecInt( func, self, release_gil ); } diff --git a/bindings/pyroot/src/Executors.h b/bindings/pyroot/src/Executors.h index 8543597ad417f..d7318eeed90c8 100644 --- a/bindings/pyroot/src/Executors.h +++ b/bindings/pyroot/src/Executors.h @@ -29,13 +29,13 @@ namespace PyROOT { class TExecutor { public: virtual ~TExecutor() {} - virtual PyObject* Execute( G__CallFunc*, void* ) = 0; + virtual PyObject* Execute( G__CallFunc*, void*, Bool_t release_gil ) = 0; }; #define PYROOT_DECLARE_BASIC_EXECUTOR( name ) \ class T##name##Executor : public TExecutor { \ public: \ - virtual PyObject* Execute( G__CallFunc*, void* ); \ + virtual PyObject* Execute( G__CallFunc*, void*, Bool_t release_gil ); \ } // executors for built-ins @@ -69,7 +69,7 @@ namespace PyROOT { class TRootObjectExecutor : public TExecutor { public: TRootObjectExecutor( const TClassRef& klass ) : fClass( klass ) {} - virtual PyObject* Execute( G__CallFunc*, void* ); + virtual PyObject* Execute( G__CallFunc*, void*, Bool_t release_gil ); protected: TClassRef fClass; @@ -78,7 +78,7 @@ namespace PyROOT { class TRootObjectByValueExecutor : public TRootObjectExecutor { public: TRootObjectByValueExecutor( const TClassRef& klass ) : TRootObjectExecutor ( klass ) {} - virtual PyObject* Execute( G__CallFunc*, void* ); + virtual PyObject* Execute( G__CallFunc*, void*, Bool_t release_gil ); }; PYROOT_DECLARE_BASIC_EXECUTOR( Constructor ); @@ -98,7 +98,7 @@ namespace PyROOT { #define PYROOT_DECLARE_BASIC_REFEXECUTOR( name ) \ class T##name##RefExecutor : public TRefExecutor { \ public: \ - virtual PyObject* Execute( G__CallFunc*, void* ); \ + virtual PyObject* Execute( G__CallFunc*, void*, Bool_t release_gil ); \ } PYROOT_DECLARE_BASIC_REFEXECUTOR( Short ); @@ -115,7 +115,7 @@ namespace PyROOT { class TRootObjectRefExecutor : public TRefExecutor { public: TRootObjectRefExecutor( const TClassRef& klass ) : fClass( klass ) {} - virtual PyObject* Execute( G__CallFunc*, void* ); + virtual PyObject* Execute( G__CallFunc*, void*, Bool_t release_gil ); protected: TClassRef fClass; diff --git a/bindings/pyroot/src/FunctionHolder.cxx b/bindings/pyroot/src/FunctionHolder.cxx index 2ba07b43a106c..6f840e44fd209 100644 --- a/bindings/pyroot/src/FunctionHolder.cxx +++ b/bindings/pyroot/src/FunctionHolder.cxx @@ -76,7 +76,7 @@ PyObject* PyROOT::TFunctionHolder< T, M >::FilterArgs( //____________________________________________________________________________ template< class T, class M > PyObject* PyROOT::TFunctionHolder< T, M >::operator()( - ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t user ) + ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t user, Bool_t release_gil ) { // preliminary check in case keywords are accidently used (they are ignored otherwise) if ( kwds != 0 && PyDict_Size( kwds ) ) { @@ -100,7 +100,7 @@ PyObject* PyROOT::TFunctionHolder< T, M >::operator()( return 0; // important: 0, not Py_None // execute function - return this->Execute( 0 ); + return this->Execute( 0, release_gil ); } //____________________________________________________________________________ diff --git a/bindings/pyroot/src/FunctionHolder.h b/bindings/pyroot/src/FunctionHolder.h index b9b33d928f027..229391ecb47e1 100644 --- a/bindings/pyroot/src/FunctionHolder.h +++ b/bindings/pyroot/src/FunctionHolder.h @@ -27,7 +27,8 @@ namespace PyROOT { virtual PyCallable* Clone() { return new TFunctionHolder( *this ); } virtual PyObject* FilterArgs( ObjectProxy*& self, PyObject* args, PyObject* kwds ); - virtual PyObject* operator()( ObjectProxy*, PyObject* args, PyObject* kwds, Long_t = 0 ); + virtual PyObject* operator()( ObjectProxy*, PyObject* args, PyObject* kwds, + Long_t user = 0, Bool_t release_gil = kFALSE ); }; } // namespace PyROOT diff --git a/bindings/pyroot/src/MemoryRegulator.cxx b/bindings/pyroot/src/MemoryRegulator.cxx index 0e94dfe63c01d..2d46bfbe6cb24 100644 --- a/bindings/pyroot/src/MemoryRegulator.cxx +++ b/bindings/pyroot/src/MemoryRegulator.cxx @@ -224,7 +224,7 @@ Bool_t PyROOT::TMemoryRegulator::UnregisterObject( TObject* object ) } //____________________________________________________________________________ -PyObject* PyROOT::TMemoryRegulator::RetrieveObject( TObject* object ) +PyObject* PyROOT::TMemoryRegulator::RetrieveObject( TObject* object, TClass* klass ) { // lookup , return old proxy if tracked if ( ! object ) @@ -234,6 +234,10 @@ PyObject* PyROOT::TMemoryRegulator::RetrieveObject( TObject* object ) if ( ppo != fgObjectTable->end() ) { PyObject* pyobj = PyWeakref_GetObject( ppo->second ); Py_XINCREF( pyobj ); + if ( pyobj && ((ObjectProxy*)pyobj)->ObjectIsA() != klass ) { + Py_DECREF( pyobj ); + return 0; + } return pyobj; } diff --git a/bindings/pyroot/src/MemoryRegulator.h b/bindings/pyroot/src/MemoryRegulator.h index 119b3602fdd61..d9814301ae0c6 100644 --- a/bindings/pyroot/src/MemoryRegulator.h +++ b/bindings/pyroot/src/MemoryRegulator.h @@ -36,7 +36,7 @@ namespace PyROOT { static Bool_t UnregisterObject( TObject* object ); // new reference to python object corresponding to object, or 0 on failure - static PyObject* RetrieveObject( TObject* object ); + static PyObject* RetrieveObject( TObject* object, TClass* klass ); // callback when weak refs to managed objects are destroyed static PyObject* ObjectEraseCallback( PyObject*, PyObject* pyref ); diff --git a/bindings/pyroot/src/MethodHolder.cxx b/bindings/pyroot/src/MethodHolder.cxx index b34cd78e16f8d..04ad8798f88cc 100644 --- a/bindings/pyroot/src/MethodHolder.cxx +++ b/bindings/pyroot/src/MethodHolder.cxx @@ -83,7 +83,7 @@ inline void PyROOT::TMethodHolder< T, M >::Destroy_() const //____________________________________________________________________________ template< class T, class M > -inline PyObject* PyROOT::TMethodHolder< T, M >::CallFast( void* self ) +inline PyObject* PyROOT::TMethodHolder< T, M >::CallFast( void* self, Bool_t release_gil ) { // Helper code to prevent some duplication; this is called from CallSafe() as well // as directly from TMethodHolder::Execute in fast mode. @@ -91,7 +91,7 @@ inline PyObject* PyROOT::TMethodHolder< T, M >::CallFast( void* self ) PyObject* result = 0; try { // C++ try block - result = fExecutor->Execute( fMethodCall, (void*)((Long_t)self + fOffset) ); + result = fExecutor->Execute( fMethodCall, (void*)((Long_t)self + fOffset), release_gil ); } catch ( TPyException& ) { result = (PyObject*)TPyExceptionMagic; } catch ( std::exception& e ) { @@ -107,7 +107,7 @@ inline PyObject* PyROOT::TMethodHolder< T, M >::CallFast( void* self ) //____________________________________________________________________________ template< class T, class M > -inline PyObject* PyROOT::TMethodHolder< T, M >::CallSafe( void* self ) +inline PyObject* PyROOT::TMethodHolder< T, M >::CallSafe( void* self, Bool_t release_gil ) { // Helper code to prevent some code duplication; this code embeds a ROOT "try/catch" // block that saves the stack for restoration in case of an otherwise fatal signal. @@ -115,7 +115,7 @@ inline PyObject* PyROOT::TMethodHolder< T, M >::CallSafe( void* self ) PyObject* result = 0; TRY { // ROOT "try block" - result = CallFast( self ); + result = CallFast( self, release_gil ); } CATCH( excode ) { PyErr_SetString( PyExc_SystemError, "problem in C++; program state has been reset" ); result = 0; @@ -589,7 +589,7 @@ namespace PyROOT { #ifdef PYROOT_USE_REFLEX template<> -PyObject* TMethodHolder< ROOT::Reflex::Scope, ROOT::Reflex::Member >::Execute( void* self ) +PyObject* TMethodHolder< ROOT::Reflex::Scope, ROOT::Reflex::Member >::Execute( void* self, Bool_t release_gil ) { // my first Reflex call ... this is all pretty wrong, but hey, it's a proto-prototype :) @@ -621,7 +621,7 @@ PyObject* TMethodHolder< ROOT::Reflex::Scope, ROOT::Reflex::Member >::Execute( v } // namespace PyROOT template< class T, class M > -PyObject* PyROOT::TMethodHolder< T, M >::Execute( void* self ) +PyObject* PyROOT::TMethodHolder< T, M >::Execute( void* self, Bool_t release_gil ) { // call the interface method R__LOCKGUARD2( gCINTMutex ); @@ -631,10 +631,10 @@ PyObject* PyROOT::TMethodHolder< T, M >::Execute( void* self ) if ( Utility::gSignalPolicy == Utility::kFast ) { // bypasses ROOT try block (i.e. segfaults will abort) - result = CallFast( self ); + result = CallFast( self, release_gil ); } else { // at the cost of ~10% performance, don't abort the interpreter on any signal - result = CallSafe( self ); + result = CallSafe( self, release_gil ); } if ( result && result != (PyObject*)TPyExceptionMagic @@ -654,7 +654,7 @@ PyObject* PyROOT::TMethodHolder< T, M >::Execute( void* self ) //____________________________________________________________________________ template< class T, class M > PyObject* PyROOT::TMethodHolder< T, M >::operator()( - ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t user ) + ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t user, Bool_t release_gil ) { // preliminary check in case keywords are accidently used (they are ignored otherwise) if ( kwds != 0 && PyDict_Size( kwds ) ) { @@ -697,7 +697,7 @@ PyObject* PyROOT::TMethodHolder< T, M >::operator()( } // actual call; recycle self instead of returning new object for same address objects - ObjectProxy* pyobj = (ObjectProxy*)Execute( object ); + ObjectProxy* pyobj = (ObjectProxy*)Execute( object, release_gil ); if ( pyobj != (ObjectProxy*)TPyExceptionMagic && ObjectProxy_Check( pyobj ) && pyobj->GetObject() == object && diff --git a/bindings/pyroot/src/MethodHolder.h b/bindings/pyroot/src/MethodHolder.h index acbf9d4117fb7..653ac1a556353 100644 --- a/bindings/pyroot/src/MethodHolder.h +++ b/bindings/pyroot/src/MethodHolder.h @@ -62,12 +62,13 @@ namespace PyROOT { virtual PyCallable* Clone() { return new TMethodHolder( *this ); } public: - virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t = 0 ); + virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject* kwds, + Long_t user = 0, Bool_t release_gil = kFALSE ); virtual Bool_t Initialize(); virtual PyObject* FilterArgs( ObjectProxy*& self, PyObject* args, PyObject* kwds ); virtual Bool_t SetMethodArgs( PyObject* args, Long_t user ); - virtual PyObject* Execute( void* self ); + virtual PyObject* Execute( void* self, Bool_t release_gil = kFALSE ); protected: const M& GetMethod() { return fMethod; } @@ -81,8 +82,8 @@ namespace PyROOT { void Copy_( const TMethodHolder& ); void Destroy_() const; - PyObject* CallFast( void* ); - PyObject* CallSafe( void* ); + PyObject* CallFast( void*, Bool_t release_gil ); + PyObject* CallSafe( void*, Bool_t release_gil ); Bool_t InitCallFunc_(); diff --git a/bindings/pyroot/src/MethodProxy.cxx b/bindings/pyroot/src/MethodProxy.cxx index e93a7b083a9c7..e14ee7644d079 100644 --- a/bindings/pyroot/src/MethodProxy.cxx +++ b/bindings/pyroot/src/MethodProxy.cxx @@ -95,7 +95,7 @@ namespace { } // if this new object falls inside self, make sure its lifetime is proper - if ( pymeth->fSelf && ObjectProxy_Check( result ) ) { + if ( ObjectProxy_Check( pymeth->fSelf ) && ObjectProxy_Check( result ) ) { Long_t ptrdiff = (Long_t)((ObjectProxy*)result)->GetObject() - (Long_t)pymeth->fSelf->GetObject(); if ( 0 <= ptrdiff && ptrdiff < (Long_t)pymeth->fSelf->ObjectIsA()->Size() ) { if ( PyObject_SetAttr( result, PyStrings::gLifeLine, (PyObject*)pymeth->fSelf ) == -1 ) @@ -290,7 +290,7 @@ namespace { #else // not important for functioning of most code, so not implemented for p3 for now (TODO) pymeth = 0; - Py_INCREF( Py_None ); + if ( pymeth || !pymeth) Py_INCREF( Py_None ); return Py_None; #endif } @@ -478,14 +478,8 @@ namespace { // simple case if ( nMethods == 1 ) { - PyObject* result = 0; - if ( pymeth->fMethodInfo->fFlags & MethodProxy::MethodInfo_t::kReleaseGIL ){ - Py_BEGIN_ALLOW_THREADS - result = (*methods[0])( pymeth->fSelf, args, kwds, user ); - Py_END_ALLOW_THREADS - } else - result = (*methods[0])( pymeth->fSelf, args, kwds, user ); - + PyObject* result = (*methods[0])( pymeth->fSelf, args, kwds, user, + (pymeth->fMethodInfo->fFlags & MethodProxy::MethodInfo_t::kReleaseGIL) ); return HandleReturn( pymeth, result ); } diff --git a/bindings/pyroot/src/ObjectProxy.cxx b/bindings/pyroot/src/ObjectProxy.cxx index 5cfa339d83bb2..e595ca48dce77 100644 --- a/bindings/pyroot/src/ObjectProxy.cxx +++ b/bindings/pyroot/src/ObjectProxy.cxx @@ -21,6 +21,7 @@ void PyROOT::op_dealloc_nofree( ObjectProxy* pyobj ) { if ( pyobj->fObject && ( pyobj->fFlags & ObjectProxy::kIsOwner ) ) { pyobj->ObjectIsA()->Destructor( pyobj->fObject ); } + pyobj->fObject = NULL; } diff --git a/bindings/pyroot/src/PyBufferFactory.cxx b/bindings/pyroot/src/PyBufferFactory.cxx index fc90a172617fe..5dddf753eeb47 100644 --- a/bindings/pyroot/src/PyBufferFactory.cxx +++ b/bindings/pyroot/src/PyBufferFactory.cxx @@ -10,7 +10,11 @@ #if PY_VERSION_HEX >= 0x03000000 static PyObject* PyBuffer_FromReadWriteMemory( void* ptr, int size ) { - Py_buffer bufinfo = { ptr, NULL, size, 1, 0, 1, NULL, NULL, NULL, NULL, { 0, 0 }, NULL }; + Py_buffer bufinfo = { ptr, NULL, size, 1, 0, 1, NULL, NULL, NULL, NULL, +#if PY_VERSION_HEX < 0x03030000 + { 0, 0 }, +#endif + NULL }; return PyMemoryView_FromBuffer( &bufinfo ); } #endif diff --git a/bindings/pyroot/src/PyCallable.h b/bindings/pyroot/src/PyCallable.h index 9a7838ea7ced7..46dfbcf39177e 100644 --- a/bindings/pyroot/src/PyCallable.h +++ b/bindings/pyroot/src/PyCallable.h @@ -33,8 +33,8 @@ namespace PyROOT { virtual PyCallable* Clone() = 0; public: - virtual PyObject* operator()( - ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t user = 0 ) = 0; + virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject* kwds, + Long_t user = 0, Bool_t release_gil = kFALSE ) = 0; }; } // namespace PyROOT diff --git a/bindings/pyroot/src/PyROOT.h b/bindings/pyroot/src/PyROOT.h index 5364f55822ec3..fefe4cef455f9 100644 --- a/bindings/pyroot/src/PyROOT.h +++ b/bindings/pyroot/src/PyROOT.h @@ -32,12 +32,21 @@ #undef _XOPEN_SOURCE #endif -#endif +#endif // linux #include "Python.h" #include "Rtypes.h" +// for 3.3 support +#if PY_VERSION_HEX < 0x03030000 + typedef PyDictEntry* (*dict_lookup_func) ( PyDictObject*, PyObject*, Long_t ); +#else + struct PyDictKeyEntry; + typedef PyDictKeyEntry* (*dict_lookup_func) ( PyDictObject*, PyObject*, Py_hash_t, PyObject*** ); +#define PyDictEntry PyDictKeyEntry +#endif + // for 3.0 support (backwards compatibility, really) #if PY_VERSION_HEX < 0x03000000 #define PyBytes_Check PyString_Check diff --git a/bindings/pyroot/src/PyStrings.cxx b/bindings/pyroot/src/PyStrings.cxx index 63ce341b7b50b..bd263071ba7c9 100644 --- a/bindings/pyroot/src/PyStrings.cxx +++ b/bindings/pyroot/src/PyStrings.cxx @@ -38,6 +38,8 @@ PyObject* PyROOT::PyStrings::gEnd = 0; PyObject* PyROOT::PyStrings::gFirst = 0; PyObject* PyROOT::PyStrings::gSecond = 0; PyObject* PyROOT::PyStrings::gSize = 0; +PyObject* PyROOT::PyStrings::gGetSize = 0; +PyObject* PyROOT::PyStrings::ggetSize = 0; PyObject* PyROOT::PyStrings::gTemplate = 0; PyObject* PyROOT::PyStrings::gVectorAt = 0; @@ -90,6 +92,8 @@ Bool_t PyROOT::CreatePyStrings() { PYROOT_INITIALIZE_STRING( gFirst, first ); PYROOT_INITIALIZE_STRING( gSecond, second ); PYROOT_INITIALIZE_STRING( gSize, size ); + PYROOT_INITIALIZE_STRING( gGetSize, GetSize ); + PYROOT_INITIALIZE_STRING( ggetSize, getSize ); PYROOT_INITIALIZE_STRING( gTemplate, Template ); PYROOT_INITIALIZE_STRING( gVectorAt, _vector__at ); @@ -138,6 +142,8 @@ PyObject* PyROOT::DestroyPyStrings() { Py_DECREF( PyStrings::gFirst ); PyStrings::gFirst = 0; Py_DECREF( PyStrings::gSecond ); PyStrings::gSecond = 0; Py_DECREF( PyStrings::gSize ); PyStrings::gSize = 0; + Py_DECREF( PyStrings::gGetSize ); PyStrings::gGetSize = 0; + Py_DECREF( PyStrings::ggetSize ); PyStrings::ggetSize = 0; Py_DECREF( PyStrings::gTemplate ); PyStrings::gTemplate = 0; Py_DECREF( PyStrings::gVectorAt ); PyStrings::gVectorAt = 0; diff --git a/bindings/pyroot/src/PyStrings.h b/bindings/pyroot/src/PyStrings.h index c009ab3d4147c..0aa40ddd48c55 100644 --- a/bindings/pyroot/src/PyStrings.h +++ b/bindings/pyroot/src/PyStrings.h @@ -45,6 +45,8 @@ namespace PyROOT { R__EXTERN PyObject* gFirst; R__EXTERN PyObject* gSecond; R__EXTERN PyObject* gSize; + R__EXTERN PyObject* gGetSize; + R__EXTERN PyObject* ggetSize; R__EXTERN PyObject* gTemplate; R__EXTERN PyObject* gVectorAt; diff --git a/bindings/pyroot/src/Pythonize.cxx b/bindings/pyroot/src/Pythonize.cxx index 648fd6a97a0e4..23a31a0975e4f 100644 --- a/bindings/pyroot/src/Pythonize.cxx +++ b/bindings/pyroot/src/Pythonize.cxx @@ -829,6 +829,44 @@ namespace { return CallSelfIndex( self, (PyObject*)index, "_vector__at" ); } + PyObject* VectorBoolSetItem( ObjectProxy* self, PyObject* args ) + { + // std::vector is a special-case in C++, and its return type depends on + // the compiler: treat it special here as well + int bval = 0; PyObject* idx = 0; + if ( ! PyArg_ParseTuple( args, const_cast< char* >( "Oi:__setitem__" ), &idx, &bval ) ) + return 0; + + if ( ! self->GetObject() ) { + PyErr_SetString( PyExc_TypeError, "unsubscriptable object" ); + return 0; + } + + PyObject* pyindex = PyStyleIndex( (PyObject*)self, idx ); + if ( ! pyindex ) + return 0; + int index = (int)PyLong_AsLong( pyindex ); + Py_DECREF( pyindex ); + + std::string clName = self->ObjectIsA()->GetName(); + std::string::size_type pos = clName.find( "vector, but %s given", + self->ObjectIsA()->GetName() ); + return 0; + } + + // get hold of the actual std::vector (no cast, as vector is never a base) + std::vector* vb = (std::vector*)self->GetObject(); + + // finally, set the value + (*vb)[ index ] = (bool)bval; + + Py_INCREF( Py_None ); + return Py_None; + } + //- map behavior as primitives ------------------------------------------------ PyObject* MapContains( PyObject* self, PyObject* obj ) { @@ -1281,7 +1319,8 @@ namespace PyROOT { // workaround for Intel icc on Linux public: virtual PyCallable* Clone() { return new TTreeBranch( *this ); } - virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t ) + virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject* kwds, + Long_t, Bool_t /* release_gil */ ) { // acceptable signatures: // ( const char*, void*, const char*, Int_t = 32000 ) @@ -1405,7 +1444,8 @@ namespace PyROOT { // workaround for Intel icc on Linux virtual PyCallable* Clone() { return new TTreeSetBranchAddress( *this ); } - virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject* kwds, Long_t ) + virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject* kwds, + Long_t, Bool_t /* release_gil */ ) { // acceptable signature: // ( const char*, void* ) @@ -1635,7 +1675,8 @@ namespace { virtual PyCallable* Clone() { return new TF1InitWithPyFunc( *this ); } - virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject*, Long_t ) + virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject*, + Long_t, Bool_t /* release_gil */ ) { // expected signature: ( char* name, pyfunc, double xmin, double xmax, int npar = 0 ) int argc = PyTuple_GET_SIZE( args ); @@ -1753,7 +1794,8 @@ namespace { virtual PyCallable* Clone() { return new TMinuitSetFCN( *this ); } - virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject*, Long_t ) + virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject*, + Long_t, Bool_t /* release_gil */ ) { // expected signature: ( pyfunc ) int argc = PyTuple_GET_SIZE( args ); @@ -1811,7 +1853,8 @@ namespace { virtual PyCallable* Clone() { return new TMinuitFitterSetFCN( *this ); } - virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject*, Long_t ) + virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject*, + Long_t, Bool_t release_gil ) { // expected signature: ( pyfunc ) int argc = PyTuple_GET_SIZE( args ); @@ -1822,7 +1865,7 @@ namespace { return 0; // reported as an overload failure } - return TMinuitSetFCN::operator()( self, args, 0, 0 ); + return TMinuitSetFCN::operator()( self, args, 0, 0, release_gil ); } }; @@ -1880,7 +1923,8 @@ namespace { virtual PyCallable* Clone() { return new TFitterFitFCN( *this ); } - virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject*, Long_t ) + virtual PyObject* operator()( ObjectProxy* self, PyObject* args, PyObject*, + Long_t, Bool_t /* release_gil */ ) { // expected signature: ( self, pyfunc, int npar = 0, const double* params = 0, unsigned int dataSize = 0, bool chi2fit = false ) int argc = PyTuple_GET_SIZE( args ); @@ -1924,6 +1968,25 @@ namespace { }; +//- TFile::Get ----------------------------------------------------------------- + PyObject* TFileGetAttr( PyObject* self, PyObject* attr ) + { + // Pythonization of TFile::Get that raises AttributeError on failure. + PyObject* result = CallPyObjMethod( self, "Get", attr ); + if ( !result ) + return result; + + if ( !PyObject_IsTrue( result ) ) { + PyObject* astr = PyObject_Str( attr ); + PyErr_Format( PyExc_AttributeError, "TFile object has no attribute \'%s\'", + PyROOT_PyUnicode_AsString( astr ) ); + Py_DECREF( astr ); + Py_DECREF( result ); + return 0; + } + return result; + } + //- simplistic len() functions ------------------------------------------------- PyObject* ReturnThree( ObjectProxy*, PyObject* ) { return PyInt_FromLong( 3 ); @@ -1957,6 +2020,13 @@ Bool_t PyROOT::Pythonize( PyObject* pyclass, const std::string& name ) if ( HasAttrDirect( pyclass, PyStrings::gSize ) ) Utility::AddToClass( pyclass, "__len__", "size" ); +// like-wise, some typical container sizings + if ( HasAttrDirect( pyclass, PyStrings::gGetSize ) ) + Utility::AddToClass( pyclass, "__len__", "GetSize" ); + + if ( HasAttrDirect( pyclass, PyStrings::ggetSize ) ) + Utility::AddToClass( pyclass, "__len__", "getSize" ); + if ( HasAttrDirect( pyclass, PyStrings::gBegin ) && HasAttrDirect( pyclass, PyStrings::gEnd ) ) { // some classes may not have dicts for their iterators, making begin/end useless PyObject* pyfullname = PyObject_GetAttr( pyclass, PyStrings::gName ); @@ -2038,7 +2108,6 @@ Bool_t PyROOT::Pythonize( PyObject* pyclass, const std::string& name ) Utility::AddToClass( pyclass, "count", (PyCFunction) TCollectionCount, METH_O ); - Utility::AddToClass( pyclass, "__len__", "GetSize" ); ((PyTypeObject*)pyclass)->tp_iter = (getiterfunc)TCollectionIter; Utility::AddToClass( pyclass, "__iter__", (PyCFunction)TCollectionIter, METH_NOARGS ); @@ -2089,6 +2158,12 @@ Bool_t PyROOT::Pythonize( PyObject* pyclass, const std::string& name ) if ( HasAttrDirect( pyclass, PyStrings::gVectorAt ) ) Utility::AddToClass( pyclass, "__getitem__", (PyCFunction) VectorGetItem, METH_O ); + // std::vector is a special case in C++ + std::string::size_type pos = name.find( "vector +//- from Python's dictobject.c ------------------------------------------------- +#if PY_VERSION_HEX >= 0x03030000 + typedef struct PyDictKeyEntry { + /* Cached hash code of me_key. */ + Py_hash_t me_hash; + PyObject *me_key; + PyObject *me_value; /* This field is only meaningful for combined tables */ + } PyDictEntry; + + typedef struct _dictkeysobject { + Py_ssize_t dk_refcnt; + Py_ssize_t dk_size; + dict_lookup_func dk_lookup; + Py_ssize_t dk_usable; + PyDictKeyEntry dk_entries[1]; + } PyDictKeysObject; + +#define PYROOT_GET_DICT_LOOKUP( mp )\ + ((dict_lookup_func&)mp->ma_keys->dk_lookup) + +#else + +#define PYROOT_GET_DICT_LOOKUP( mp )\ + ((dict_lookup_func&)mp->ma_lookup) + +#endif + //- data ----------------------------------------------------------------------- PyObject* gRootModule = 0; - //- private helpers ------------------------------------------------------------ namespace { using namespace PyROOT; +//____________________________________________________________________________ + PyObject* RootModuleResetCallback( PyObject*, PyObject* ) + { + gRootModule = 0; // reference was borrowed + Py_INCREF( Py_None ); + return Py_None; + } + //____________________________________________________________________________ PyObject* LookupRootEntity( PyObject* pyname, PyObject* args ) { @@ -49,6 +83,12 @@ namespace { else if ( ! ( args && PyArg_ParseTuple( args, const_cast< char* >( "s" ), &cname ) ) ) return 0; + // we may have been destroyed if this code is called during shutdown + if ( !gRootModule ) { + PyErr_Format( PyExc_AttributeError, "%s", cname ); + return 0; + } + std::string name = cname; // block search for privates @@ -83,10 +123,32 @@ namespace { } //____________________________________________________________________________ +#if PY_VERSION_HEX >= 0x03030000 + inline PyDictKeyEntry* OrgDictLookup( + PyDictObject* mp, PyObject* key, Py_hash_t hash, PyObject*** value_addr ) + { + return (*gDictLookupOrg)( mp, key, hash, value_addr ); + } + +#define PYROOT_ORGDICT_LOOKUP( mp, key, hash, value_addr )\ + OrgDictLookup( mp, key, hash, value_addr ) + + PyDictKeyEntry* RootLookDictString( + PyDictObject* mp, PyObject* key, Py_hash_t hash, PyObject*** value_addr ) +#else + inline PyDictEntry* OrgDictLookup( PyDictObject* mp, PyObject* key, Long_t hash ) + { + return (*gDictLookupOrg)( mp, key, hash ); + } + +#define PYROOT_ORGDICT_LOOKUP( mp, key, hash, value_addr )\ + OrgDictLookup( mp, key, hash ) + PyDictEntry* RootLookDictString( PyDictObject* mp, PyObject* key, Long_t hash ) +#endif { // first search dictionary itself - PyDictEntry* ep = (*gDictLookupOrg)( mp, key, hash ); + PyDictEntry* ep = PYROOT_ORGDICT_LOOKUP( mp, key, hash, value_addr ); if ( ! ep || ep->me_value != 0 || gDictLookupActive ) return ep; @@ -111,14 +173,14 @@ namespace { ep->me_value = Py_TYPE(val)->tp_descr_get( val, NULL, NULL ); } else { // add reference to ROOT entity in the given dictionary - ((DictLookup_t&)mp->ma_lookup) = gDictLookupOrg; // prevent recursion + PYROOT_GET_DICT_LOOKUP( mp ) = gDictLookupOrg; // prevent recursion if ( PyDict_SetItem( (PyObject*)mp, key, val ) == 0 ) { - ep = (*gDictLookupOrg)( mp, key, hash ); + ep = PYROOT_ORGDICT_LOOKUP( mp, key, hash, value_addr ); } else { ep->me_key = 0; ep->me_value = 0; } - ((DictLookup_t&)mp->ma_lookup) = RootLookDictString; // restore + PYROOT_GET_DICT_LOOKUP( mp ) = RootLookDictString; // restore } // done with val @@ -142,7 +204,7 @@ namespace { if ( ! PyArg_ParseTuple( args, const_cast< char* >( "O!" ), &PyDict_Type, &dict ) ) return 0; - ((DictLookup_t&)dict->ma_lookup) = RootLookDictString; + PYROOT_GET_DICT_LOOKUP( dict ) = RootLookDictString; Py_INCREF( Py_None ); return Py_None; @@ -330,6 +392,14 @@ namespace { const char* clname = PyBytes_AS_STRING(pyname); + // make sure that ROOT.py is loaded and fully initialized by accessing on it + PyObject* mod = PyImport_ImportModule( (char*)"ROOT" ); + if ( mod ) { + PyObject* dummy = PyObject_GetAttrString( mod, (char*)"kRed" ); + Py_XDECREF( dummy ); + Py_DECREF( mod ); + } + // TBuffer and its derived classes can't write themselves, but can be created // directly from the buffer, so handle them in a special case void* newObj = 0; @@ -425,6 +495,8 @@ static PyMethodDef gPyROOTMethods[] = { METH_VARARGS, (char*) "PyROOT internal function" }, { (char*) "_DestroyPyStrings", (PyCFunction)PyROOT::DestroyPyStrings, METH_NOARGS, (char*) "PyROOT internal function" }, + { (char*) "_ResetRootModule", (PyCFunction)RootModuleResetCallback, + METH_NOARGS, (char*) "PyROOT internal function" }, { (char*) "AddressOf", (PyCFunction)AddressOf, METH_VARARGS, (char*) "Retrieve address of held object in a buffer" }, { (char*) "AsCObject", (PyCFunction)AsCObject, @@ -441,6 +513,10 @@ static PyMethodDef gPyROOTMethods[] = { METH_VARARGS, (char*) "Trap signals in safe mode to prevent interpreter abort" }, { (char*) "SetOwnership", (PyCFunction)SetOwnership, METH_VARARGS, (char*) "Modify held C++ object ownership" }, + { (char*) "InstallGUIEventInputHook", (PyCFunction)PyROOT::Utility::InstallGUIEventInputHook, + METH_NOARGS, (char*) "Install input hook to sent GUI events" }, + { (char*) "RemoveGUIEventInputHook", (PyCFunction)PyROOT::Utility::RemoveGUIEventInputHook, + METH_NOARGS, (char*) "Remove input hook to sent GUI events" }, #ifdef PYROOT_USE_REFLEX { (char*) "EnableReflex", (PyCFunction)PyROOT::TRflxCallback::Enable, METH_NOARGS, (char*) "Enable PyReflex notification of new types from Reflex" }, @@ -500,7 +576,11 @@ extern "C" void initlibPyROOT() // prepare for lazyness PyObject* dict = PyDict_New(); - gDictLookupOrg = (DictLookup_t)((PyDictObject*)dict)->ma_lookup; +#if PY_VERSION_HEX >= 0x03030000 + gDictLookupOrg = (dict_lookup_func)((PyDictObject*)dict)->ma_keys->dk_lookup; +#else + gDictLookupOrg = (dict_lookup_func)((PyDictObject*)dict)->ma_lookup; +#endif Py_DECREF( dict ); // setup PyROOT diff --git a/bindings/pyroot/src/RootWrapper.cxx b/bindings/pyroot/src/RootWrapper.cxx index 47eb3c5afb06c..36648003ba091 100644 --- a/bindings/pyroot/src/RootWrapper.cxx +++ b/bindings/pyroot/src/RootWrapper.cxx @@ -645,6 +645,22 @@ PyObject* PyROOT::MakeRootClassFromString( const std::string& fullname, PyObject if ( pyclass ) // store a ref from ROOT TClass to new python class gPyClasses[ klass.Id() ] = PyWeakref_NewRef( pyclass, NULL ); + if ( klass.IsNamespace() && klass.Name() != "ROOT" ) { + // add to sys.modules to allow importing from this module + std::string pyfullname = lookup; + std::string::size_type pos = pyfullname.find( "::" ); + while ( pos != std::string::npos ) { + pyfullname = pyfullname.replace( pos, 2, "." ); + pos = pyfullname.find( "::", pos ); + } + PyObject* modules = PySys_GetObject( const_cast("modules") ); + if ( modules && PyDict_Check( modules) ) { + + PyDict_SetItemString( modules, + const_cast(("ROOT."+pyfullname).c_str()), pyclass ); + } + } + // all done return pyclass; } @@ -778,6 +794,9 @@ PyObject* PyROOT::BindRootObject( void* address, TClass* klass, Bool_t isRef ) return 0; } +// get actual class for recycling checking and/or downcasting + TClass* clActual = isRef ? 0 : klass->GetActualClass( address ); + // obtain pointer to TObject base class (if possible) for memory mgmt; this is // done before downcasting, as upcasting from the current class may be easier and // downcasting is unnecessary if the python side object gets recycled by the @@ -787,18 +806,15 @@ PyObject* PyROOT::BindRootObject( void* address, TClass* klass, Bool_t isRef ) object = (TObject*)((Long_t)address - GetObjectOffset( klass, TObject::Class(), address, false ) ); // use the old reference if the object already exists - PyObject* oldPyObject = TMemoryRegulator::RetrieveObject( object ); + PyObject* oldPyObject = TMemoryRegulator::RetrieveObject( object, clActual ? clActual : klass ); if ( oldPyObject ) return oldPyObject; } // upgrade to real class for object returns - if ( ! isRef ) { - TClass* clActual = klass->GetActualClass( address ); - if ( clActual ) { - address = (void*)((Long_t)address - GetObjectOffset( klass, clActual, address ) ); - klass = clActual; - } + if ( clActual ) { + address = (void*)((Long_t)address - GetObjectOffset( klass, clActual, address ) ); + klass = clActual; } // actual binding diff --git a/bindings/pyroot/src/TPySelector.cxx b/bindings/pyroot/src/TPySelector.cxx index cdf390e796170..7b651b32f464d 100644 --- a/bindings/pyroot/src/TPySelector.cxx +++ b/bindings/pyroot/src/TPySelector.cxx @@ -72,7 +72,16 @@ void TPySelector::SetupPySelf() if ( fPySelf && fPySelf != Py_None ) return; // already created ... - TString impst = TString::Format( "import %s", GetOption() ); +// split option as needed for the module part and the (optional) user part + std::string opt = GetOption(); + std::string::size_type pos = opt.find( '#' ); + std::string module = opt.substr( 0, pos ); + std::string user = (pos == std::string::npos) ? "" : opt.substr( pos+1, std::string::npos ); + + TString impst = TString::Format( "import %s", module.c_str() ); + +// reset user option + SetOption( user.c_str() ); // use TPython to ensure that the interpreter is initialized if ( ! TPython::Exec( (const char*)impst ) ) { @@ -86,7 +95,7 @@ void TPySelector::SetupPySelf() const_cast< char* >( "TPySelector" ) ); // get handle to the module - PyObject* pymod = PyImport_AddModule( const_cast< char* >( GetOption() ) ); + PyObject* pymod = PyImport_AddModule( const_cast< char* >( module.c_str() ) ); // get the module dictionary to loop over PyObject* dict = PyModule_GetDict( pymod ); diff --git a/bindings/pyroot/src/TPython.cxx b/bindings/pyroot/src/TPython.cxx index deced7b4ebfad..b163ee8b89c69 100644 --- a/bindings/pyroot/src/TPython.cxx +++ b/bindings/pyroot/src/TPython.cxx @@ -6,6 +6,7 @@ #include "PyStrings.h" #include "TPython.h" #include "ObjectProxy.h" +#include "MethodProxy.h" #include "RootWrapper.h" #include "TPyClassGenerator.h" @@ -410,6 +411,33 @@ Bool_t TPython::ObjectProxy_CheckExact( PyObject* pyobject ) return PyROOT::ObjectProxy_CheckExact( pyobject ); } +//____________________________________________________________________________ +Bool_t TPython::MethodProxy_Check( PyObject* pyobject ) +{ +// Test whether the type of the given pyobject is of MethodProxy type or any +// derived type. + +// setup + if ( ! Initialize() ) + return kFALSE; + +// detailed walk through inheritance hierarchy + return PyROOT::MethodProxy_Check( pyobject ); +} + +//____________________________________________________________________________ +Bool_t TPython::MethodProxy_CheckExact( PyObject* pyobject ) +{ +// Test whether the type of the given pyobject is MethodProxy type. + +// setup + if ( ! Initialize() ) + return kFALSE; + +// direct pointer comparison of type member + return PyROOT::MethodProxy_CheckExact( pyobject ); +} + //____________________________________________________________________________ void* TPython::ObjectProxy_AsVoidPtr( PyObject* pyobject ) { @@ -428,7 +456,8 @@ void* TPython::ObjectProxy_AsVoidPtr( PyObject* pyobject ) } //____________________________________________________________________________ -PyObject* TPython::ObjectProxy_FromVoidPtr( void* addr, const char* classname ) +PyObject* TPython::ObjectProxy_FromVoidPtr( + void* addr, const char* classname, Bool_t python_owns ) { // Bind the addr to a python object of class defined by classname. @@ -437,5 +466,11 @@ PyObject* TPython::ObjectProxy_FromVoidPtr( void* addr, const char* classname ) return 0; // perform cast (the call will check TClass and addr, and set python errors) - return PyROOT::BindRootObjectNoCast( addr, TClass::GetClass( classname ), kFALSE ); + PyObject* pyobject = PyROOT::BindRootObjectNoCast( addr, TClass::GetClass( classname ), kFALSE ); + +// give ownership, for ref-counting, to the python side, if so requested + if ( python_owns && PyROOT::ObjectProxy_Check( pyobject ) ) + ((PyROOT::ObjectProxy*)pyobject)->HoldOn(); + + return pyobject; } diff --git a/bindings/pyroot/src/Utility.cxx b/bindings/pyroot/src/Utility.cxx index 342062343fe81..0f6169ea08229 100644 --- a/bindings/pyroot/src/Utility.cxx +++ b/bindings/pyroot/src/Utility.cxx @@ -15,6 +15,7 @@ // ROOT #include "TROOT.h" +#include "TSystem.h" #include "TObject.h" #include "TClassEdit.h" #include "TClassRef.h" @@ -36,7 +37,7 @@ //- data _____________________________________________________________________ -PyROOT::DictLookup_t PyROOT::gDictLookupOrg = 0; +dict_lookup_func PyROOT::gDictLookupOrg = 0; Bool_t PyROOT::gDictLookupActive = kFALSE; PyROOT::Utility::EMemoryPolicy PyROOT::Utility::gMemoryPolicy = PyROOT::Utility::kHeuristics; @@ -886,3 +887,46 @@ PyObject* PyROOT::Utility::PyErr_Occurred_WithGIL() return e; } + +//____________________________________________________________________________ +namespace { + + static int (*sOldInputHook)() = NULL; + static PyThreadState* sInputHookEventThreadState = NULL; + + static int EventInputHook() + { + // This method is supposed to be called from CPython's command line and + // drives the GUI. + PyEval_RestoreThread( sInputHookEventThreadState ); + gSystem->ProcessEvents(); + PyEval_SaveThread(); + + if ( sOldInputHook ) return sOldInputHook(); + return 0; + } + +} // unnamed namespace + +PyObject* PyROOT::Utility::InstallGUIEventInputHook() +{ +// Install the method hook for sending events to the GUI + if ( PyOS_InputHook && PyOS_InputHook != &EventInputHook ) + sOldInputHook = PyOS_InputHook; + + sInputHookEventThreadState = PyThreadState_Get(); + + PyOS_InputHook = (int (*)())&EventInputHook; + Py_INCREF( Py_None ); + return Py_None; +} + +PyObject* PyROOT::Utility::RemoveGUIEventInputHook() +{ +// Remove event hook, if it was installed + PyOS_InputHook = sOldInputHook; + sInputHookEventThreadState = NULL; + + Py_INCREF( Py_None ); + return Py_None; +} diff --git a/bindings/pyroot/src/Utility.h b/bindings/pyroot/src/Utility.h index ec1567020598a..b307fc580ca1f 100644 --- a/bindings/pyroot/src/Utility.h +++ b/bindings/pyroot/src/Utility.h @@ -21,8 +21,7 @@ namespace PyROOT { class PyCallable; - typedef PyDictEntry* (*DictLookup_t) ( PyDictObject*, PyObject*, Long_t ); - R__EXTERN DictLookup_t gDictLookupOrg; + R__EXTERN dict_lookup_func gDictLookupOrg; R__EXTERN Bool_t gDictLookupActive; // general place holder for function parameters @@ -126,6 +125,10 @@ namespace PyROOT { // for threading: save call to PyErr_Occurred() PyObject* PyErr_Occurred_WithGIL(); + // for GUI driving; install/remove event callback + PyObject* InstallGUIEventInputHook(); + PyObject* RemoveGUIEventInputHook(); + } // namespace Utility } // namespace PyROOT diff --git a/bindings/ruby/src/drr.cxx b/bindings/ruby/src/drr.cxx index 8102e194e3e81..a460833c0d946 100644 --- a/bindings/ruby/src/drr.cxx +++ b/bindings/ruby/src/drr.cxx @@ -163,36 +163,6 @@ VALUE rr_seqcollection_new (TSeqCollection *sc) return arr; } -void * rr_parse_void (VALUE o) -{ - VALUE *i; - - switch (TYPE(o)) - { - case T_STRING: - return (void *) RSTRING_PTR(o); - case T_FLOAT: - return (void *) &RFLOAT_VALUE(o); - case T_FIXNUM: - /* FIXME: Memory leak until I find the correct way. Until - * then please use integers in TTrees with care. --elathan - */ - i = (VALUE*) malloc (sizeof(VALUE)); - *i = (int) (o>>1); - return (void *) i; - case T_OBJECT: - RRGRAB(o, void *, res); - return res; - default: - VALUE tmp = CLASS_OF(o); - rb_fatal ("Failed convertion of %d to void *.\n", - StringValuePtr(tmp)); - break; - } - - return (void *) NULL; -} - VALUE rr_bool (Bool_t q) { VALUE res = Qnil; @@ -650,7 +620,7 @@ VALUE drrAbstractClass; static VALUE drr_as(VALUE self, VALUE klass) { /* Pseudo C++ casting. */ - VALUE v; + VALUE v = 0; /* Check if there is a ROOT dict. available. */ TClass *c = TClass::GetClass(StringValuePtr(klass)); diff --git a/bindings/ruby/src/rrcommon.h b/bindings/ruby/src/rrcommon.h index b85e9ad5f6cec..baa6135e600ba 100644 --- a/bindings/ruby/src/rrcommon.h +++ b/bindings/ruby/src/rrcommon.h @@ -97,8 +97,6 @@ VALUE rr_arrayf_new (const TArrayF *a); VALUE rr_arrayd_new (const TArrayD *a); VALUE rr_seqcollection_new (TSeqCollection *sc); -void * rr_parse_void (VALUE o); - /* mod convertions */ void rr_tattfill_conv(void **ptr, VALUE klass); void rr_tattline_conv(void **ptr, VALUE klass); diff --git a/build/package/common/root-plugin-sql-sqlite.control b/build/package/common/root-plugin-sql-sqlite.control new file mode 100644 index 0000000000000..61a23644547b0 --- /dev/null +++ b/build/package/common/root-plugin-sql-sqlite.control @@ -0,0 +1,15 @@ +Package: root-plugin-sql-sqlite +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Provides: root-db-client +Description: SQLite client plugin for ROOT + The ROOT system provides a set of OO frameworks with all the + functionality needed to handle and analyze large amounts of data + efficiently. + . + This package contains the SQLite plug-in for ROOT. This plugin + provides a thin client (interface) to SQLite database files. Using this + client, one can obtain information from a SQLite database into the + ROOT environment. + + diff --git a/build/package/debian/README.Debian b/build/package/debian/README.Debian index bc814ec44166f..2a7e7c859a164 100644 --- a/build/package/debian/README.Debian +++ b/build/package/debian/README.Debian @@ -153,7 +153,7 @@ will happily answer questions in that forum. [1] http://root.cern.ch [2] http://root.cern.ch/root/htmldoc/ClassIndex.html [3] http://root.cern.ch/root/UsersGuide.html -[4] mailto:roottalk@root.cern.ch +[4] mailto:roottalk@cern.ch [5] http://root.cern.ch/root/AboutRootTalk.html @@ -466,7 +466,7 @@ If you didn't get the packages from the official repositories, please do not use the regular Debian bug tracking system. Instead, please send bug reports to the Debian GNU/Linux package maintainer and possibly also the ROOT mailing list -. +. Experimental Packages: ====================== diff --git a/build/package/debian/copyright b/build/package/debian/copyright index 075d7bd3f4a99..92b99f2e4cf09 100644 --- a/build/package/debian/copyright +++ b/build/package/debian/copyright @@ -260,7 +260,7 @@ copyright statements. These are reproduced below. except where otherwise noted in this file. cint/stl/bstring.h - Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) Same license as the rest of the cint directory. diff --git a/build/package/debian/root-system-doc.doc-base b/build/package/debian/root-system-doc.doc-base index be6417d1ce114..54bb6fd97fcb9 100644 --- a/build/package/debian/root-system-doc.doc-base +++ b/build/package/debian/root-system-doc.doc-base @@ -1,6 +1,6 @@ Document: root-system Title: ROOT Reference Manual -Author: ROOT Team +Author: ROOT Team Abstract: Reference manual of all ROOT classes. The ROOT system provides a set of OO frameworks with all the functionality needed to handle and analyse large amounts of data in a diff --git a/build/package/msi/Language_en-us.wxl b/build/package/msi/Language_en-us.wxl index 4c26168122671..e99d50309148f 100755 --- a/build/package/msi/Language_en-us.wxl +++ b/build/package/msi/Language_en-us.wxl @@ -1,587 +1,587 @@ - - - [ProductName] Setup - OK - Cancel - &Look in: - WixUI_Bmp_Up - Up one level - WixUI_Bmp_New - Create a new folder - &Folder name: - WixUI_Bmp_Banner - Browse to the destination folder - {\WixUI_Font_Title}Change destination folder - - [ProductName] Setup - &No - &Yes - Are you sure you want to cancel [ProductName] installation? - WixUI_Ico_Info - Information icon - - [ProductName] Setup - Tree of selections - B&rowse... - Re&set - Disk &Usage - < &Back - &Next > - Cancel - WixUI_Bmp_Banner - Click the icons in the tree below to change the way features will be installed. - Select the way you want features to be installed. - {\WixUI_Font_Title}Custom Setup - Neque porro quisquam est qui dolorem ipsum quia dolor sit amet - Neque porro quisquam est qui dolorem ipsum quia dolor sit amet - Neque porro quisquam est qui dolorem ipsum quia dolor sit amet - Location: - - [ProductName] Setup - OK - WixUI_Bmp_Banner - Highlighted volumes do not have enough disk space available for selected features. You can either remove some files from the highlighted volumes, install fewer features, or select different destination drives. - The disk space required for the installation of the selected features. - {\WixUI_Font_Title}Disk Space Requirements - {120}{70}{70}{70}{70} - - [ProductName] Setup - Information text - &Yes - Cancel - Cancel - WixUI_Ico_Info - Information icon - &Ignore - &No - OK - &Retry - - [ProductName] Setup - &Finish - Cancel - WixUI_Bmp_Dialog - &Back - Click the Finish button to exit the Setup Wizard. - {\WixUI_Font_Bigger}Completing the [ProductName] Setup Wizard - - [ProductName] Setup - &Finish - Cancel - WixUI_Bmp_Dialog - < &Back - {\WixUI_Font_Bigger}[ProductName] Setup Wizard ended prematurely - [ProductName] Setup Wizard ended prematurely because of an error. Your system has not been modified. To install this program at a later time, run Setup Wizard again. - Click the Finish button to exit the Setup Wizard. - - [ProductName] Setup - &Retry - &Ignore - E&xit - WixUI_Bmp_Banner - The following applications are using files that need to be updated by this setup. Close these applications and then click &Retry to continue the installation or Cancel to exit it. - Some files that need to be updated are currently in use. - {\WixUI_Font_Title}Files in Use - - [ProductName] Setup - I &accept the terms in the License Agreement - < &Back - &Next > - Cancel - WixUI_Bmp_Banner - - Please read the following license agreement carefully - {\WixUI_Font_Title}End-User License Agreement - - [ProductName] Setup - &Modify - Modify Installation - Re&pair - Repair Installation - &Remove - Remove Installation - < &Back - &Next > - Cancel - WixUI_Bmp_Banner - Select the operation you wish to perform. - {\WixUI_Font_Title}Modify, repair, or remove installation - Lets you change the way features are installed. - [ProductName] has no independently selectable features. - Removes [ProductName] from your computer. - Repairs errors in the most recent installation by fixing missing and corrupt files, shortcuts, and registry entries. - - [ProductName] Setup - &Next > - Cancel - WixUI_Bmp_Dialog - < &Back - The Setup Wizard allows you to change the way [ProductName] features are installed on your computer or to remove it from your computer. Click Next to continue or Cancel to exit the Setup Wizard. - {\WixUI_Font_Bigger}Welcome to the [ProductName] Setup Wizard - - [ProductName] Setup - OK - WixUI_Bmp_Banner - The highlighted volumes do not have enough disk space available for the currently selected features. You can remove some files from the highlighted volumes, install fewer features, or select a different destination drive. - Disk space required for the installation exceeds available disk space. - {\WixUI_Font_Title}Out of Disk Space - {120}{70}{70}{70}{70} - - [ProductName] Setup - &No - &Yes - WixUI_Bmp_Banner - The highlighted volumes do not have enough disk space available for the currently selected features. You can remove some files from the highlighted volumes, install fewer features, or select a different destination drive. - Disk space required for the installation exceeds available disk space. - {\WixUI_Font_Title}Out of Disk Space - {120}{70}{70}{70}{70} - Alternatively, you may choose to disable the installer's rollback functionality. Disabling rollback prevents the installer from restoring your computer's original state should the installation be interrupted in any way. Click Yes if you wish to take the risk of disabling rollback. - - [ProductName] Setup - Cancel - WixUI_Bmp_Dialog - Please wait while the Setup Wizard prepares to guide you through the installation. - {\WixUI_Font_Bigger}Welcome to the [ProductName] Setup Wizard - < &Back - &Next > - - [ProductName] Setup - Cancel - WixUI_Bmp_Banner - < &Back - &Next > - Please wait while the Setup Wizard installs [ProductName]. - {\WixUI_Font_Title}Installing [ProductName] - Please wait while the Setup Wizard changes [ProductName]. - {\WixUI_Font_Title}Changing [ProductName] - Please wait while the Setup Wizard repairs [ProductName]. - {\WixUI_Font_Title}Repairing [ProductName] - Please wait while the Setup Wizard removes [ProductName]. - {\WixUI_Font_Title}Removing [ProductName] - Progress done - Status: - - [ProductName] Setup - &Install - Cancel - WixUI_Bmp_Dialog - &Back - The Setup Wizard will complete the installation of [ProductName] on your computer. Click Install to continue or Cancel to exit the Setup Wizard. - {\WixUI_Font_Bigger}Resuming the [ProductName] Setup Wizard - - [ProductName] Setup - &Typical - Typical Installation - C&ustom - Custom Installation - C&omplete - Complete Installation - < &Back - &Next > - Cancel - WixUI_Bmp_Banner - {\WixUI_Font_Title}Choose Setup Type - Choose the setup type that best suits your needs - Installs the most common program features. Recommended for most users. - Allows users to choose which program features will be installed and where they will be installed. Recommended for advanced users. - All program features will be installed. Requires the most disk space. - - [ProductName] Setup - &Finish - Cancel - WixUI_Bmp_Dialog - &Back - {\WixUI_Font_Bigger}[ProductName] Setup Wizard was interrupted - [ProductName] setup was interrupted. Your system has not been modified. To install this program at a later time, please run the installation again. - Click the Finish button to exit the Setup Wizard. - - [ProductName] Setup - &Install - Cancel - WixUI_Bmp_Banner - &Back - Click Install to begin the installation. If you want to review or change any of your installation settings, click Back. Click Cancel to exit the wizard. - The Setup Wizard is ready to begin - {\WixUI_Font_Title}Ready to Install - - [ProductName] Setup - &Back - &Remove - Cancel - WixUI_Bmp_Banner - Click Remove to remove [ProductName] from your computer. If you want to review or change any of your installation settings, click Back. Click Cancel to exit the wizard. - You have chosen to remove the program from your computer. - {\WixUI_Font_Title}Remove [ProductName] - - [ProductName] Setup - Re&pair - Cancel - WixUI_Bmp_Banner - &Back - Click Repair to repair the installation of [ProductName]. If you want to review or change any of your installation settings, click Back. Click Cancel to exit the wizard. - The Setup Wizard is ready to begin the repair of [ProductName]. - {\WixUI_Font_Title}Repair [ProductName] - - [ProductName] Setup - &Return - Please wait while the installer finishes determining your disk space requirements. - WixUI_Ico_Exclam - Exclamation icon - - [ProductName] Setup - &Next > - Cancel - WixUI_Bmp_Dialog - < &Back - The Setup Wizard will install [ProductName] on your computer. Click Next to continue or Cancel to exit the Setup Wizard. - {\WixUI_Font_Bigger}Welcome to the [ProductName] Setup Wizard - - [ProductName] Setup - WixUI_Bmp_Dialog - I &accept the terms in the License Agreement - &Back - &Install - Cancel - {\WixUI_Font_Title}Please read the [ProductName] License Agreement - - - Validating install - Copying new files - File: [1], Directory: [9], Size: [6] - Copying network install files - File: [1], Directory: [9], Size: [6] - Computing space requirements - Computing space requirements - Computing space requirements - Creating shortcuts - Shortcut: [1] - Publishing Qualified Components - Component ID: [1], Qualifier: [2] - Publishing Product Features - Feature: [1] - Publishing product information - Registering Class servers - Class Id: [1] - Registering extension servers - Extension: [1] - Registering MIME info - MIME Content Type: [1], Extension: [2] - Registering program identifiers - ProgId: [1] - Allocating registry space - Free space: [1] - Searching for installed applications - Property: [1], Signature: [2] - Binding executables - File: [1] - Searching for qualifying products - Creating folders - Folder: [1] - Deleting services - Service: [1] - Creating duplicate files - File: [1], Directory: [9], Size: [6] - Searching for related applications - Found application: [1] - Installing ODBC components - Installing new services - Service: [2] - Evaluating launch conditions - Migrating feature states from related applications - Application: [1] - Moving files - File: [1], Directory: [9], Size: [6] - Patching files - File: [1], Directory: [2], Size: [3] - Updating component registration - Registering COM+ Applications and Components - AppId: [1]{{, AppType: [2], Users: [3], RSN: [4]}} - Registering fonts - Font: [1] - Registering product - [1] - Registering type libraries - LibID: [1] - Registering user - [1] - Removing duplicated files - File: [1], Directory: [9] - Updating environment strings - Name: [1], Value: [2], Action [3] - Removing applications - Application: [1], Command line: [2] - Removing files - File: [1], Directory: [9] - Removing folders - Folder: [1] - Removing INI files entries - File: [1], Section: [2], Key: [3], Value: [4] - Removing ODBC components - Removing system registry values - Key: [1], Name: [2] - Removing shortcuts - Shortcut: [1] - Searching for qualifying products - Registering modules - File: [1], Folder: [2] - Unregistering modules - File: [1], Folder: [2] - Initializing ODBC directories - Starting services - Service: [1] - Stopping services - Service: [1] - Unpublishing Qualified Components - Component ID: [1], Qualifier: [2] - Unpublishing Product Features - Feature: [1] - Unregister Class servers - Class Id: [1] - Unregistering COM+ Applications and Components - AppId: [1]{{, AppType: [2]}} - Unregistering extension servers - Extension: [1] - Unregistering fonts - Font: [1] - Unregistering MIME info - MIME Content Type: [1], Extension: [2] - Unregistering program identifiers - ProgId: [1] - Unregistering type libraries - LibID: [1] - Updating environment strings - Name: [1], Value: [2], Action [3] - Writing INI files values - File: [1], Section: [2], Key: [3], Value: [4] - Writing system registry values - Key: [1], Name: [2], Value: [3] - Advertising application - Generating script operations for action: - [1] - Installing system catalog - File: [1], Dependencies: [2] - Publishing assembly information - Application Context:[1], Assembly Name:[2] - Unpublishing assembly information - Application Context:[1], Assembly Name:[2] - Rolling back action: - [1] - Removing backup files - File: [1] - Removing moved files - File: [1], Directory: [9] - Unpublishing product information - - {{Fatal error: }} - {{Error [1]. }} - Warning [1]. - Info [1]. - The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is [1]. {{The arguments are: [2], [3], [4]}} - {{Disk full: }} - Action [Time]: [1]. [2] - [ProductName] - {[2]}{, [3]}{, [4]} - Message type: [1], Argument: [2] - === Logging started: [Date] [Time] === - === Logging stopped: [Date] [Time] === - Action start [Time]: [1]. - Action ended [Time]: [1]. Return value [2]. - Time remaining: {[1] minutes }{[2] seconds} - Out of memory. Shut down other applications before retrying. - Installer is no longer responding. - Installer stopped prematurely. - Please wait while Windows configures [ProductName] - Gathering required information... - Removing older versions of this application... - Preparing to remove older versions of this application... - {[ProductName] }Setup completed successfully. - {[ProductName] }Setup failed. - Error reading from file: [2]. {{ System error [3].}} Verify that the file exists and that you can access it. - Cannot create the file '[2]'. A directory with this name already exists. Cancel the install and try installing to a different location. - Please insert the disk: [2] - The installer has insufficient privileges to access this directory: [2]. The installation cannot continue. Log on as administrator or contact your system administrator. - Error writing to file: [2]. Verify that you have access to that directory. - Error reading from file [2]. {{ System error [3].}} Verify that the file exists and that you can access it. - Another application has exclusive access to the file '[2]'. Please shut down all other applications, then click Retry. - There is not enough disk space to install this file: [2]. Free some disk space and click Retry, or click Cancel to exit. - Source file not found: [2]. Verify that the file exists and that you can access it. - Error reading from file: [3]. {{ System error [2].}} Verify that the file exists and that you can access it. - Error writing to file: [3]. {{ System error [2].}} Verify that you have access to that directory. - Source file not found{{(cabinet)}}: [2]. Verify that the file exists and that you can access it. - Cannot create the directory '[2]'. A file with this name already exists. Please rename or remove the file and click Retry, or click Cancel to exit. - The volume [2] is currently unavailable. Please select another. - The specified path '[2]' is unavailable. - Unable to write to the specified folder: [2]. - A network error occurred while attempting to read from the file: [2] - An error occurred while attempting to create the directory: [2] - A network error occurred while attempting to create the directory: [2] - A network error occurred while attempting to open the source file cabinet: [2] - The specified path is too long: [2] - The Installer has insufficient privileges to modify this file: [2]. - A portion of the folder path '[2]' is invalid. It is either empty or exceeds the length allowed by the system. - The folder path '[2]' contains words that are not valid in folder paths. - The folder path '[2]' contains an invalid character. - '[2]' is not a valid short file name. - Error getting file security: [3] GetLastError: [2] - Invalid Drive: [2] - Error applying patch to file [2]. It has probably been updated by other means, and can no longer be modified by this patch. For more information contact your patch vendor. {{System Error: [3]}} - A file that is required cannot be installed because the cabinet file [2] is not digitally signed. This may indicate that the cabinet file is corrupt. - A file that is required cannot be installed because the cabinet file [2] has an invalid digital signature. This may indicate that the cabinet file is corrupt.{{ Error [3] was returned by WinVerifyTrust.}} - Failed to correctly copy [2] file: CRC error. - Failed to correctly move [2] file: CRC error. - Failed to correctly patch [2] file: CRC error. - The file '[2]' cannot be installed because the file cannot be found in cabinet file '[3]'. This could indicate a network error, an error reading from the CD-ROM, or a problem with this package. - The cabinet file '[2]' required for this installation is corrupt and cannot be used. This could indicate a network error, an error reading from the CD-ROM, or a problem with this package. - There was an error creating a temporary file that is needed to complete this installation.{{ Folder: [3]. System error code: [2]}} - Could not create key: [2]. {{ System error [3].}} Verify that you have sufficient access to that key, or contact your support personnel. - Could not open key: [2]. {{ System error [3].}} Verify that you have sufficient access to that key, or contact your support personnel. - Could not delete value [2] from key [3]. {{ System error [4].}} Verify that you have sufficient access to that key, or contact your support personnel. - Could not delete key [2]. {{ System error [3].}} Verify that you have sufficient access to that key, or contact your support personnel. - Could not read value [2] from key [3]. {{ System error [4].}} Verify that you have sufficient access to that key, or contact your support personnel. - Could not write value [2] to key [3]. {{ System error [4].}} Verify that you have sufficient access to that key, or contact your support personnel. - Could not get value names for key [2]. {{ System error [3].}} Verify that you have sufficient access to that key, or contact your support personnel. - Could not get sub key names for key [2]. {{ System error [3].}} Verify that you have sufficient access to that key, or contact your support personnel. - Could not read security information for key [2]. {{ System error [3].}} Verify that you have sufficient access to that key, or contact your support personnel. - Could not increase the available registry space. [2] KB of free registry space is required for the installation of this application. - Another installation is in progress. You must complete that installation before continuing this one. - Error accessing secured data. Please make sure the Windows Installer is configured properly and try the install again. - User '[2]' has previously initiated an install for product '[3]'. That user will need to run that install again before they can use that product. Your current install will now continue. - User '[2]' has previously initiated an install for product '[3]'. That user will need to run that install again before they can use that product. - Out of disk space -- Volume: '[2]'; required space: [3] KB; available space: [4] KB. Free some disk space and retry. - Are you sure you want to cancel? - The file [2][3] is being held in use{ by the following process: Name: [4], Id: [5], Window Title: '[6]'}. Close that application and retry. - The product '[2]' is already installed, preventing the installation of this product. The two products are incompatible. - There is not enough disk space on the volume '[2]' to continue the install with recovery enabled. [3] KB are required, but only [4] KB are available. Click Ignore to continue the install without saving recovery information, click Retry to check for available space again, or click Cancel to quit the installation. - Could not access network location [2]. - The following applications should be closed before continuing the install: - Could not find any previously installed compliant products on the machine for installing this product. - An error occurred while applying security settings. [2] is not a valid user or group. This could be a problem with the package, or a problem connecting to a domain controller on the network. Check your network connection and click Retry, or Cancel to end the install. {{Unable to locate the user's SID, system error [3]}} - The key [2] is not valid. Verify that you entered the correct key. - The installer must restart your system before configuration of [2] can continue. Click Yes to restart now or No if you plan to manually restart later. - You must restart your system for the configuration changes made to [2] to take effect. Click Yes to restart now or No if you plan to manually restart later. - An installation for [2] is currently suspended. You must undo the changes made by that installation to continue. Do you want to undo those changes? - A previous installation for this product is in progress. You must undo the changes made by that installation to continue. Do you want to undo those changes? - An installation package for the product [2] cannot be found. Try the installation again using a valid copy of the installation package '[3]'. - Installation completed successfully. - Installation failed. - Product: [2] -- [3] - You may either restore your computer to its previous state or continue the install later. Would you like to restore? - An error occurred while writing installation information to disk. Check to make sure enough disk space is available, and click Retry, or Cancel to end the install. - One or more of the files required to restore your computer to its previous state could not be found. Restoration will not be possible. - [2] cannot install one of its required products. Contact your technical support group. {{System Error: [3].}} - The older version of [2] cannot be removed. Contact your technical support group. {{System Error [3].}} - Installed [2] - Configured [2] - Removed [2] - File [2] was rejected by digital signature policy. - The Windows Installer Service could not be accessed. This can occur if you are running Windows in safe mode, or if the Windows Installer is not correctly installed. Contact your support personnel for assistance. - There is a problem with this Windows Installer package. A script required for this install to complete could not be run. Contact your support personnel or package vendor. {{Custom action [2] script error [3], [4]: [5] Line [6], Column [7], [8] }} - There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. {{Action: [2], location: [3], command: [4] }} - There is a problem with this Windows Installer package. A program run as part of the setup did not finish as expected. Contact your support personnel or package vendor. {{Action [2], location: [3], command: [4] }} - There is a problem with this Windows Installer package. A DLL required for this install to complete could not be run. Contact your support personnel or package vendor. {{Action [2], entry: [3], library: [4] }} - Removal completed successfully. - Removal failed. - Advertisement completed successfully. - Advertisement failed. - Configuration completed successfully. - Configuration failed. - You must be an Administrator to remove this application. To remove this application, you can log on as an Administrator, or contact your technical support group for assistance. - The source installation package for the product [2] is out of sync with the client package. Try the installation again using a valid copy of the installation package '[3]'. - In order to complete the installation of [2], you must restart the computer. Other users are currently logged on to this computer, and restarting may cause them to lose their work. Do you want to restart now? - The path [2] is not valid. Please specify a valid path. - Out of memory. Shut down other applications before retrying. - There is no disk in drive [2]. Please insert one and click Retry, or click Cancel to go back to the previously selected volume. - There is no disk in drive [2]. Please insert one and click Retry, or click Cancel to return to the browse dialog and select a different volume. - The folder [2] does not exist. Please enter a path to an existing folder. - You have insufficient privileges to read this folder. - A valid destination folder for the install could not be determined. - Error attempting to read from the source install database: [2]. - Scheduling reboot operation: Renaming file [2] to [3]. Must reboot to complete operation. - Scheduling reboot operation: Deleting file [2]. Must reboot to complete operation. - Module [2] failed to register. HRESULT [3]. Contact your support personnel. - Module [2] failed to unregister. HRESULT [3]. Contact your support personnel. - Failed to cache package [2]. Error: [3]. Contact your support personnel. - Could not register font [2]. Verify that you have sufficient permissions to install fonts, and that the system supports this font. - Could not unregister font [2]. Verify that you that you have sufficient permissions to remove fonts. - Could not create Shortcut [2]. Verify that the destination folder exists and that you can access it. - Could not remove Shortcut [2]. Verify that the shortcut file exists and that you can access it. - Could not register type library for file [2]. Contact your support personnel. - Could not unregister type library for file [2]. Contact your support personnel. - Could not update the ini file [2][3]. Verify that the file exists and that you can access it. - Could not schedule file [2] to replace file [3] on reboot. Verify that you have write permissions to file [3]. - Error removing ODBC driver manager, ODBC error [2]: [3]. Contact your support personnel. - Error installing ODBC driver manager, ODBC error [2]: [3]. Contact your support personnel. - Error removing ODBC driver: [4], ODBC error [2]: [3]. Verify that you have sufficient privileges to remove ODBC drivers. - Error installing ODBC driver: [4], ODBC error [2]: [3]. Verify that the file [4] exists and that you can access it. - Error configuring ODBC data source: [4], ODBC error [2]: [3]. Verify that the file [4] exists and that you can access it. - Service '[2]' ([3]) failed to start. Verify that you have sufficient privileges to start system services. - Service '[2]' ([3]) could not be stopped. Verify that you have sufficient privileges to stop system services. - Service '[2]' ([3]) could not be deleted. Verify that you have sufficient privileges to remove system services. - Service '[2]' ([3]) could not be installed. Verify that you have sufficient privileges to install system services. - Could not update environment variable '[2]'. Verify that you have sufficient privileges to modify environment variables. - You do not have sufficient privileges to complete this installation for all users of the machine. Log on as administrator and then retry this installation. - Could not set file security for file '[3]'. Error: [2]. Verify that you have sufficient privileges to modify the security permissions for this file. - Component Services (COM+ 1.0) are not installed on this computer. This installation requires Component Services in order to complete successfully. Component Services are available on Windows 2000. - Error registering COM+ Application. Contact your support personnel for more information. - Error unregistering COM+ Application. Contact your support personnel for more information. - The description for service '[2]' ([3]) could not be changed. - The Windows Installer service cannot update the system file [2] because the file is protected by Windows. You may need to update your operating system for this program to work correctly. {{Package version: [3], OS Protected version: [4]}} - The Windows Installer service cannot update the protected Windows file [2]. {{Package version: [3], OS Protected version: [4], SFP Error: [5]}} - The Windows Installer service cannot update one or more protected Windows files. {{SFP Error: [2]. List of protected files:\r\n[3]}} - User installations are disabled via policy on the machine. - An error occurred during the installation of assembly '[6]'. Please refer to Help and Support for more information. HRESULT: [3]. {{assembly interface: [4], function: [5], component: [2]}} - An error occurred during the installation of assembly '[6]'. The assembly is not strongly named or is not signed with the minimal key length. HRESULT: [3]. {{assembly interface: [4], function: [5], component: [2]}} - An error occurred during the installation of assembly '[6]'. The signature or catalog could not be verified or is not valid. HRESULT: [3]. {{assembly interface: [4], function: [5], component: [2]}} - An error occurred during the installation of assembly '[6]'. One or more modules of the assembly could not be found. HRESULT: [3]. {{assembly interface: [4], function: [5], component: [2]}} - - bytes - GB - KB - MB - Entire feature will be unavailable - Feature will be installed when required - Entire feature will be installed to run from CD - Entire feature will be installed on local hard drive - Entire feature will be installed to run from network - Will be installed to run from CD - Will be installed on local hard drive - Will be installed to run from network - Gathering required information... - This feature will remain uninstalled - This feature will be set to be installed when required - This feature will be installed to run from CD - This feature will be installed on the local hard drive - This feature will be installed to run from the network - This feature will become unavailable - Will be installed when required - This feature will be available to run from CD - This feature will be installed on your local hard drive - This feature will be available to run from the network - This feature will be uninstalled completely, you won't be able to run it from CD - This feature will change from run from CD state to set to be installed when required - This feature will remain to be run from CD - This feature will change from run from CD state to be installed on the local hard drive - This feature frees up [1] on your hard drive. - This feature requires [1] on your hard drive. - Compiling cost for this feature... - This feature will be completely removed - This feature will be removed from your local hard drive, but will be set to be installed when required - This feature will be removed from your local hard drive, but will be still available to run from CD - This feature will remain on you local hard drive - This feature will be removed from your local hard drive, but will be still available to run from the network - This feature will be uninstalled completely, you won't be able to run it from the network - This feature will change from run from network state to set to be installed when required - This feature will change from run from network state to be installed on the local hard drive - This feature will remain to be run from the network - This feature frees up [1] on your hard drive. It has [2] of [3] subfeatures selected. The subfeatures free up [4] on your hard drive. - This feature frees up [1] on your hard drive. It has [2] of [3] subfeatures selected. The subfeatures require [4] on your hard drive. - This feature requires [1] on your hard drive. It has [2] of [3] subfeatures selected. The subfeatures free up [4] on your hard drive. - This feature requires [1] on your hard drive. It has [2] of [3] subfeatures selected. The subfeatures require [4] on your hard drive. - Time remaining: {[1] minutes }{[2] seconds} - Available - Difference - Required - Disk Size - Volume - + + + [ProductName] Setup + OK + Cancel + &Look in: + WixUI_Bmp_Up + Up one level + WixUI_Bmp_New + Create a new folder + &Folder name: + WixUI_Bmp_Banner + Browse to the destination folder + {\WixUI_Font_Title}Change destination folder + + [ProductName] Setup + &No + &Yes + Are you sure you want to cancel [ProductName] installation? + WixUI_Ico_Info + Information icon + + [ProductName] Setup + Tree of selections + B&rowse... + Re&set + Disk &Usage + < &Back + &Next > + Cancel + WixUI_Bmp_Banner + Click the icons in the tree below to change the way features will be installed. + Select the way you want features to be installed. + {\WixUI_Font_Title}Custom Setup + Neque porro quisquam est qui dolorem ipsum quia dolor sit amet + Neque porro quisquam est qui dolorem ipsum quia dolor sit amet + Neque porro quisquam est qui dolorem ipsum quia dolor sit amet + Location: + + [ProductName] Setup + OK + WixUI_Bmp_Banner + Highlighted volumes do not have enough disk space available for selected features. You can either remove some files from the highlighted volumes, install fewer features, or select different destination drives. + The disk space required for the installation of the selected features. + {\WixUI_Font_Title}Disk Space Requirements + {120}{70}{70}{70}{70} + + [ProductName] Setup + Information text + &Yes + Cancel + Cancel + WixUI_Ico_Info + Information icon + &Ignore + &No + OK + &Retry + + [ProductName] Setup + &Finish + Cancel + WixUI_Bmp_Dialog + &Back + Click the Finish button to exit the Setup Wizard. + {\WixUI_Font_Bigger}Completing the [ProductName] Setup Wizard + + [ProductName] Setup + &Finish + Cancel + WixUI_Bmp_Dialog + < &Back + {\WixUI_Font_Bigger}[ProductName] Setup Wizard ended prematurely + [ProductName] Setup Wizard ended prematurely because of an error. Your system has not been modified. To install this program at a later time, run Setup Wizard again. + Click the Finish button to exit the Setup Wizard. + + [ProductName] Setup + &Retry + &Ignore + E&xit + WixUI_Bmp_Banner + The following applications are using files that need to be updated by this setup. Close these applications and then click &Retry to continue the installation or Cancel to exit it. + Some files that need to be updated are currently in use. + {\WixUI_Font_Title}Files in Use + + [ProductName] Setup + I &accept the terms in the License Agreement + < &Back + &Next > + Cancel + WixUI_Bmp_Banner + + Please read the following license agreement carefully + {\WixUI_Font_Title}End-User License Agreement + + [ProductName] Setup + &Modify + Modify Installation + Re&pair + Repair Installation + &Remove + Remove Installation + < &Back + &Next > + Cancel + WixUI_Bmp_Banner + Select the operation you wish to perform. + {\WixUI_Font_Title}Modify, repair, or remove installation + Lets you change the way features are installed. + [ProductName] has no independently selectable features. + Removes [ProductName] from your computer. + Repairs errors in the most recent installation by fixing missing and corrupt files, shortcuts, and registry entries. + + [ProductName] Setup + &Next > + Cancel + WixUI_Bmp_Dialog + < &Back + The Setup Wizard allows you to change the way [ProductName] features are installed on your computer or to remove it from your computer. Click Next to continue or Cancel to exit the Setup Wizard. + {\WixUI_Font_Bigger}Welcome to the [ProductName] Setup Wizard + + [ProductName] Setup + OK + WixUI_Bmp_Banner + The highlighted volumes do not have enough disk space available for the currently selected features. You can remove some files from the highlighted volumes, install fewer features, or select a different destination drive. + Disk space required for the installation exceeds available disk space. + {\WixUI_Font_Title}Out of Disk Space + {120}{70}{70}{70}{70} + + [ProductName] Setup + &No + &Yes + WixUI_Bmp_Banner + The highlighted volumes do not have enough disk space available for the currently selected features. You can remove some files from the highlighted volumes, install fewer features, or select a different destination drive. + Disk space required for the installation exceeds available disk space. + {\WixUI_Font_Title}Out of Disk Space + {120}{70}{70}{70}{70} + Alternatively, you may choose to disable the installer's rollback functionality. Disabling rollback prevents the installer from restoring your computer's original state should the installation be interrupted in any way. Click Yes if you wish to take the risk of disabling rollback. + + [ProductName] Setup + Cancel + WixUI_Bmp_Dialog + Please wait while the Setup Wizard prepares to guide you through the installation. + {\WixUI_Font_Bigger}Welcome to the [ProductName] Setup Wizard + < &Back + &Next > + + [ProductName] Setup + Cancel + WixUI_Bmp_Banner + < &Back + &Next > + Please wait while the Setup Wizard installs [ProductName]. + {\WixUI_Font_Title}Installing [ProductName] + Please wait while the Setup Wizard changes [ProductName]. + {\WixUI_Font_Title}Changing [ProductName] + Please wait while the Setup Wizard repairs [ProductName]. + {\WixUI_Font_Title}Repairing [ProductName] + Please wait while the Setup Wizard removes [ProductName]. + {\WixUI_Font_Title}Removing [ProductName] + Progress done + Status: + + [ProductName] Setup + &Install + Cancel + WixUI_Bmp_Dialog + &Back + The Setup Wizard will complete the installation of [ProductName] on your computer. Click Install to continue or Cancel to exit the Setup Wizard. + {\WixUI_Font_Bigger}Resuming the [ProductName] Setup Wizard + + [ProductName] Setup + &Typical + Typical Installation + C&ustom + Custom Installation + C&omplete + Complete Installation + < &Back + &Next > + Cancel + WixUI_Bmp_Banner + {\WixUI_Font_Title}Choose Setup Type + Choose the setup type that best suits your needs + Installs the most common program features. Recommended for most users. + Allows users to choose which program features will be installed and where they will be installed. Recommended for advanced users. + All program features will be installed. Requires the most disk space. + + [ProductName] Setup + &Finish + Cancel + WixUI_Bmp_Dialog + &Back + {\WixUI_Font_Bigger}[ProductName] Setup Wizard was interrupted + [ProductName] setup was interrupted. Your system has not been modified. To install this program at a later time, please run the installation again. + Click the Finish button to exit the Setup Wizard. + + [ProductName] Setup + &Install + Cancel + WixUI_Bmp_Banner + &Back + Click Install to begin the installation. If you want to review or change any of your installation settings, click Back. Click Cancel to exit the wizard. + The Setup Wizard is ready to begin + {\WixUI_Font_Title}Ready to Install + + [ProductName] Setup + &Back + &Remove + Cancel + WixUI_Bmp_Banner + Click Remove to remove [ProductName] from your computer. If you want to review or change any of your installation settings, click Back. Click Cancel to exit the wizard. + You have chosen to remove the program from your computer. + {\WixUI_Font_Title}Remove [ProductName] + + [ProductName] Setup + Re&pair + Cancel + WixUI_Bmp_Banner + &Back + Click Repair to repair the installation of [ProductName]. If you want to review or change any of your installation settings, click Back. Click Cancel to exit the wizard. + The Setup Wizard is ready to begin the repair of [ProductName]. + {\WixUI_Font_Title}Repair [ProductName] + + [ProductName] Setup + &Return + Please wait while the installer finishes determining your disk space requirements. + WixUI_Ico_Exclam + Exclamation icon + + [ProductName] Setup + &Next > + Cancel + WixUI_Bmp_Dialog + < &Back + The Setup Wizard will install [ProductName] on your computer. Click Next to continue or Cancel to exit the Setup Wizard. + {\WixUI_Font_Bigger}Welcome to the [ProductName] Setup Wizard + + [ProductName] Setup + WixUI_Bmp_Dialog + I &accept the terms in the License Agreement + &Back + &Install + Cancel + {\WixUI_Font_Title}Please read the [ProductName] License Agreement + + + Validating install + Copying new files + File: [1], Directory: [9], Size: [6] + Copying network install files + File: [1], Directory: [9], Size: [6] + Computing space requirements + Computing space requirements + Computing space requirements + Creating shortcuts + Shortcut: [1] + Publishing Qualified Components + Component ID: [1], Qualifier: [2] + Publishing Product Features + Feature: [1] + Publishing product information + Registering Class servers + Class Id: [1] + Registering extension servers + Extension: [1] + Registering MIME info + MIME Content Type: [1], Extension: [2] + Registering program identifiers + ProgId: [1] + Allocating registry space + Free space: [1] + Searching for installed applications + Property: [1], Signature: [2] + Binding executables + File: [1] + Searching for qualifying products + Creating folders + Folder: [1] + Deleting services + Service: [1] + Creating duplicate files + File: [1], Directory: [9], Size: [6] + Searching for related applications + Found application: [1] + Installing ODBC components + Installing new services + Service: [2] + Evaluating launch conditions + Migrating feature states from related applications + Application: [1] + Moving files + File: [1], Directory: [9], Size: [6] + Patching files + File: [1], Directory: [2], Size: [3] + Updating component registration + Registering COM+ Applications and Components + AppId: [1]{{, AppType: [2], Users: [3], RSN: [4]}} + Registering fonts + Font: [1] + Registering product + [1] + Registering type libraries + LibID: [1] + Registering user + [1] + Removing duplicated files + File: [1], Directory: [9] + Updating environment strings + Name: [1], Value: [2], Action [3] + Removing applications + Application: [1], Command line: [2] + Removing files + File: [1], Directory: [9] + Removing folders + Folder: [1] + Removing INI files entries + File: [1], Section: [2], Key: [3], Value: [4] + Removing ODBC components + Removing system registry values + Key: [1], Name: [2] + Removing shortcuts + Shortcut: [1] + Searching for qualifying products + Registering modules + File: [1], Folder: [2] + Unregistering modules + File: [1], Folder: [2] + Initializing ODBC directories + Starting services + Service: [1] + Stopping services + Service: [1] + Unpublishing Qualified Components + Component ID: [1], Qualifier: [2] + Unpublishing Product Features + Feature: [1] + Unregister Class servers + Class Id: [1] + Unregistering COM+ Applications and Components + AppId: [1]{{, AppType: [2]}} + Unregistering extension servers + Extension: [1] + Unregistering fonts + Font: [1] + Unregistering MIME info + MIME Content Type: [1], Extension: [2] + Unregistering program identifiers + ProgId: [1] + Unregistering type libraries + LibID: [1] + Updating environment strings + Name: [1], Value: [2], Action [3] + Writing INI files values + File: [1], Section: [2], Key: [3], Value: [4] + Writing system registry values + Key: [1], Name: [2], Value: [3] + Advertising application + Generating script operations for action: + [1] + Installing system catalog + File: [1], Dependencies: [2] + Publishing assembly information + Application Context:[1], Assembly Name:[2] + Unpublishing assembly information + Application Context:[1], Assembly Name:[2] + Rolling back action: + [1] + Removing backup files + File: [1] + Removing moved files + File: [1], Directory: [9] + Unpublishing product information + + {{Fatal error: }} + {{Error [1]. }} + Warning [1]. + Info [1]. + The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is [1]. {{The arguments are: [2], [3], [4]}} + {{Disk full: }} + Action [Time]: [1]. [2] + [ProductName] + {[2]}{, [3]}{, [4]} + Message type: [1], Argument: [2] + === Logging started: [Date] [Time] === + === Logging stopped: [Date] [Time] === + Action start [Time]: [1]. + Action ended [Time]: [1]. Return value [2]. + Time remaining: {[1] minutes }{[2] seconds} + Out of memory. Shut down other applications before retrying. + Installer is no longer responding. + Installer stopped prematurely. + Please wait while Windows configures [ProductName] + Gathering required information... + Removing older versions of this application... + Preparing to remove older versions of this application... + {[ProductName] }Setup completed successfully. + {[ProductName] }Setup failed. + Error reading from file: [2]. {{ System error [3].}} Verify that the file exists and that you can access it. + Cannot create the file '[2]'. A directory with this name already exists. Cancel the install and try installing to a different location. + Please insert the disk: [2] + The installer has insufficient privileges to access this directory: [2]. The installation cannot continue. Log on as administrator or contact your system administrator. + Error writing to file: [2]. Verify that you have access to that directory. + Error reading from file [2]. {{ System error [3].}} Verify that the file exists and that you can access it. + Another application has exclusive access to the file '[2]'. Please shut down all other applications, then click Retry. + There is not enough disk space to install this file: [2]. Free some disk space and click Retry, or click Cancel to exit. + Source file not found: [2]. Verify that the file exists and that you can access it. + Error reading from file: [3]. {{ System error [2].}} Verify that the file exists and that you can access it. + Error writing to file: [3]. {{ System error [2].}} Verify that you have access to that directory. + Source file not found{{(cabinet)}}: [2]. Verify that the file exists and that you can access it. + Cannot create the directory '[2]'. A file with this name already exists. Please rename or remove the file and click Retry, or click Cancel to exit. + The volume [2] is currently unavailable. Please select another. + The specified path '[2]' is unavailable. + Unable to write to the specified folder: [2]. + A network error occurred while attempting to read from the file: [2] + An error occurred while attempting to create the directory: [2] + A network error occurred while attempting to create the directory: [2] + A network error occurred while attempting to open the source file cabinet: [2] + The specified path is too long: [2] + The Installer has insufficient privileges to modify this file: [2]. + A portion of the folder path '[2]' is invalid. It is either empty or exceeds the length allowed by the system. + The folder path '[2]' contains words that are not valid in folder paths. + The folder path '[2]' contains an invalid character. + '[2]' is not a valid short file name. + Error getting file security: [3] GetLastError: [2] + Invalid Drive: [2] + Error applying patch to file [2]. It has probably been updated by other means, and can no longer be modified by this patch. For more information contact your patch vendor. {{System Error: [3]}} + A file that is required cannot be installed because the cabinet file [2] is not digitally signed. This may indicate that the cabinet file is corrupt. + A file that is required cannot be installed because the cabinet file [2] has an invalid digital signature. This may indicate that the cabinet file is corrupt.{{ Error [3] was returned by WinVerifyTrust.}} + Failed to correctly copy [2] file: CRC error. + Failed to correctly move [2] file: CRC error. + Failed to correctly patch [2] file: CRC error. + The file '[2]' cannot be installed because the file cannot be found in cabinet file '[3]'. This could indicate a network error, an error reading from the CD-ROM, or a problem with this package. + The cabinet file '[2]' required for this installation is corrupt and cannot be used. This could indicate a network error, an error reading from the CD-ROM, or a problem with this package. + There was an error creating a temporary file that is needed to complete this installation.{{ Folder: [3]. System error code: [2]}} + Could not create key: [2]. {{ System error [3].}} Verify that you have sufficient access to that key, or contact your support personnel. + Could not open key: [2]. {{ System error [3].}} Verify that you have sufficient access to that key, or contact your support personnel. + Could not delete value [2] from key [3]. {{ System error [4].}} Verify that you have sufficient access to that key, or contact your support personnel. + Could not delete key [2]. {{ System error [3].}} Verify that you have sufficient access to that key, or contact your support personnel. + Could not read value [2] from key [3]. {{ System error [4].}} Verify that you have sufficient access to that key, or contact your support personnel. + Could not write value [2] to key [3]. {{ System error [4].}} Verify that you have sufficient access to that key, or contact your support personnel. + Could not get value names for key [2]. {{ System error [3].}} Verify that you have sufficient access to that key, or contact your support personnel. + Could not get sub key names for key [2]. {{ System error [3].}} Verify that you have sufficient access to that key, or contact your support personnel. + Could not read security information for key [2]. {{ System error [3].}} Verify that you have sufficient access to that key, or contact your support personnel. + Could not increase the available registry space. [2] KB of free registry space is required for the installation of this application. + Another installation is in progress. You must complete that installation before continuing this one. + Error accessing secured data. Please make sure the Windows Installer is configured properly and try the install again. + User '[2]' has previously initiated an install for product '[3]'. That user will need to run that install again before they can use that product. Your current install will now continue. + User '[2]' has previously initiated an install for product '[3]'. That user will need to run that install again before they can use that product. + Out of disk space -- Volume: '[2]'; required space: [3] KB; available space: [4] KB. Free some disk space and retry. + Are you sure you want to cancel? + The file [2][3] is being held in use{ by the following process: Name: [4], Id: [5], Window Title: '[6]'}. Close that application and retry. + The product '[2]' is already installed, preventing the installation of this product. The two products are incompatible. + There is not enough disk space on the volume '[2]' to continue the install with recovery enabled. [3] KB are required, but only [4] KB are available. Click Ignore to continue the install without saving recovery information, click Retry to check for available space again, or click Cancel to quit the installation. + Could not access network location [2]. + The following applications should be closed before continuing the install: + Could not find any previously installed compliant products on the machine for installing this product. + An error occurred while applying security settings. [2] is not a valid user or group. This could be a problem with the package, or a problem connecting to a domain controller on the network. Check your network connection and click Retry, or Cancel to end the install. {{Unable to locate the user's SID, system error [3]}} + The key [2] is not valid. Verify that you entered the correct key. + The installer must restart your system before configuration of [2] can continue. Click Yes to restart now or No if you plan to manually restart later. + You must restart your system for the configuration changes made to [2] to take effect. Click Yes to restart now or No if you plan to manually restart later. + An installation for [2] is currently suspended. You must undo the changes made by that installation to continue. Do you want to undo those changes? + A previous installation for this product is in progress. You must undo the changes made by that installation to continue. Do you want to undo those changes? + An installation package for the product [2] cannot be found. Try the installation again using a valid copy of the installation package '[3]'. + Installation completed successfully. + Installation failed. + Product: [2] -- [3] + You may either restore your computer to its previous state or continue the install later. Would you like to restore? + An error occurred while writing installation information to disk. Check to make sure enough disk space is available, and click Retry, or Cancel to end the install. + One or more of the files required to restore your computer to its previous state could not be found. Restoration will not be possible. + [2] cannot install one of its required products. Contact your technical support group. {{System Error: [3].}} + The older version of [2] cannot be removed. Contact your technical support group. {{System Error [3].}} + Installed [2] + Configured [2] + Removed [2] + File [2] was rejected by digital signature policy. + The Windows Installer Service could not be accessed. This can occur if you are running Windows in safe mode, or if the Windows Installer is not correctly installed. Contact your support personnel for assistance. + There is a problem with this Windows Installer package. A script required for this install to complete could not be run. Contact your support personnel or package vendor. {{Custom action [2] script error [3], [4]: [5] Line [6], Column [7], [8] }} + There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. {{Action: [2], location: [3], command: [4] }} + There is a problem with this Windows Installer package. A program run as part of the setup did not finish as expected. Contact your support personnel or package vendor. {{Action [2], location: [3], command: [4] }} + There is a problem with this Windows Installer package. A DLL required for this install to complete could not be run. Contact your support personnel or package vendor. {{Action [2], entry: [3], library: [4] }} + Removal completed successfully. + Removal failed. + Advertisement completed successfully. + Advertisement failed. + Configuration completed successfully. + Configuration failed. + You must be an Administrator to remove this application. To remove this application, you can log on as an Administrator, or contact your technical support group for assistance. + The source installation package for the product [2] is out of sync with the client package. Try the installation again using a valid copy of the installation package '[3]'. + In order to complete the installation of [2], you must restart the computer. Other users are currently logged on to this computer, and restarting may cause them to lose their work. Do you want to restart now? + The path [2] is not valid. Please specify a valid path. + Out of memory. Shut down other applications before retrying. + There is no disk in drive [2]. Please insert one and click Retry, or click Cancel to go back to the previously selected volume. + There is no disk in drive [2]. Please insert one and click Retry, or click Cancel to return to the browse dialog and select a different volume. + The folder [2] does not exist. Please enter a path to an existing folder. + You have insufficient privileges to read this folder. + A valid destination folder for the install could not be determined. + Error attempting to read from the source install database: [2]. + Scheduling reboot operation: Renaming file [2] to [3]. Must reboot to complete operation. + Scheduling reboot operation: Deleting file [2]. Must reboot to complete operation. + Module [2] failed to register. HRESULT [3]. Contact your support personnel. + Module [2] failed to unregister. HRESULT [3]. Contact your support personnel. + Failed to cache package [2]. Error: [3]. Contact your support personnel. + Could not register font [2]. Verify that you have sufficient permissions to install fonts, and that the system supports this font. + Could not unregister font [2]. Verify that you that you have sufficient permissions to remove fonts. + Could not create Shortcut [2]. Verify that the destination folder exists and that you can access it. + Could not remove Shortcut [2]. Verify that the shortcut file exists and that you can access it. + Could not register type library for file [2]. Contact your support personnel. + Could not unregister type library for file [2]. Contact your support personnel. + Could not update the ini file [2][3]. Verify that the file exists and that you can access it. + Could not schedule file [2] to replace file [3] on reboot. Verify that you have write permissions to file [3]. + Error removing ODBC driver manager, ODBC error [2]: [3]. Contact your support personnel. + Error installing ODBC driver manager, ODBC error [2]: [3]. Contact your support personnel. + Error removing ODBC driver: [4], ODBC error [2]: [3]. Verify that you have sufficient privileges to remove ODBC drivers. + Error installing ODBC driver: [4], ODBC error [2]: [3]. Verify that the file [4] exists and that you can access it. + Error configuring ODBC data source: [4], ODBC error [2]: [3]. Verify that the file [4] exists and that you can access it. + Service '[2]' ([3]) failed to start. Verify that you have sufficient privileges to start system services. + Service '[2]' ([3]) could not be stopped. Verify that you have sufficient privileges to stop system services. + Service '[2]' ([3]) could not be deleted. Verify that you have sufficient privileges to remove system services. + Service '[2]' ([3]) could not be installed. Verify that you have sufficient privileges to install system services. + Could not update environment variable '[2]'. Verify that you have sufficient privileges to modify environment variables. + You do not have sufficient privileges to complete this installation for all users of the machine. Log on as administrator and then retry this installation. + Could not set file security for file '[3]'. Error: [2]. Verify that you have sufficient privileges to modify the security permissions for this file. + Component Services (COM+ 1.0) are not installed on this computer. This installation requires Component Services in order to complete successfully. Component Services are available on Windows 2000. + Error registering COM+ Application. Contact your support personnel for more information. + Error unregistering COM+ Application. Contact your support personnel for more information. + The description for service '[2]' ([3]) could not be changed. + The Windows Installer service cannot update the system file [2] because the file is protected by Windows. You may need to update your operating system for this program to work correctly. {{Package version: [3], OS Protected version: [4]}} + The Windows Installer service cannot update the protected Windows file [2]. {{Package version: [3], OS Protected version: [4], SFP Error: [5]}} + The Windows Installer service cannot update one or more protected Windows files. {{SFP Error: [2]. List of protected files:\r\n[3]}} + User installations are disabled via policy on the machine. + An error occurred during the installation of assembly '[6]'. Please refer to Help and Support for more information. HRESULT: [3]. {{assembly interface: [4], function: [5], component: [2]}} + An error occurred during the installation of assembly '[6]'. The assembly is not strongly named or is not signed with the minimal key length. HRESULT: [3]. {{assembly interface: [4], function: [5], component: [2]}} + An error occurred during the installation of assembly '[6]'. The signature or catalog could not be verified or is not valid. HRESULT: [3]. {{assembly interface: [4], function: [5], component: [2]}} + An error occurred during the installation of assembly '[6]'. One or more modules of the assembly could not be found. HRESULT: [3]. {{assembly interface: [4], function: [5], component: [2]}} + + bytes + GB + KB + MB + Entire feature will be unavailable + Feature will be installed when required + Entire feature will be installed to run from CD + Entire feature will be installed on local hard drive + Entire feature will be installed to run from network + Will be installed to run from CD + Will be installed on local hard drive + Will be installed to run from network + Gathering required information... + This feature will remain uninstalled + This feature will be set to be installed when required + This feature will be installed to run from CD + This feature will be installed on the local hard drive + This feature will be installed to run from the network + This feature will become unavailable + Will be installed when required + This feature will be available to run from CD + This feature will be installed on your local hard drive + This feature will be available to run from the network + This feature will be uninstalled completely, you won't be able to run it from CD + This feature will change from run from CD state to set to be installed when required + This feature will remain to be run from CD + This feature will change from run from CD state to be installed on the local hard drive + This feature frees up [1] on your hard drive. + This feature requires [1] on your hard drive. + Compiling cost for this feature... + This feature will be completely removed + This feature will be removed from your local hard drive, but will be set to be installed when required + This feature will be removed from your local hard drive, but will be still available to run from CD + This feature will remain on you local hard drive + This feature will be removed from your local hard drive, but will be still available to run from the network + This feature will be uninstalled completely, you won't be able to run it from the network + This feature will change from run from network state to set to be installed when required + This feature will change from run from network state to be installed on the local hard drive + This feature will remain to be run from the network + This feature frees up [1] on your hard drive. It has [2] of [3] subfeatures selected. The subfeatures free up [4] on your hard drive. + This feature frees up [1] on your hard drive. It has [2] of [3] subfeatures selected. The subfeatures require [4] on your hard drive. + This feature requires [1] on your hard drive. It has [2] of [3] subfeatures selected. The subfeatures free up [4] on your hard drive. + This feature requires [1] on your hard drive. It has [2] of [3] subfeatures selected. The subfeatures require [4] on your hard drive. + Time remaining: {[1] minutes }{[2] seconds} + Available + Difference + Required + Disk Size + Volume + \ No newline at end of file diff --git a/build/rmkdepend/main.c b/build/rmkdepend/main.c index aba51304d5f08..f70de5f9a84e9 100644 --- a/build/rmkdepend/main.c +++ b/build/rmkdepend/main.c @@ -60,7 +60,7 @@ extern int fchmod(int, int); # endif # elif defined(__CYGWIN__) extern int fchmod(int, mode_t); -#else +# elif !defined(__GLIBC__) || __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 16) extern int fchmod(int, int); # endif #endif diff --git a/build/unix/compiledata.sh b/build/unix/compiledata.sh index c2a54768f1d62..593efb2256d54 100755 --- a/build/unix/compiledata.sh +++ b/build/unix/compiledata.sh @@ -47,8 +47,8 @@ else EXPLLINKLIBS="\$DepLibs" fi -if [ "$ARCH" = "macosx" ] || [ "$ARCH" = "macosxxlc" ] || \ - [ "$ARCH" = "macosx64" ] || [ "$ARCH" = "macosxicc" ]; then +if [ "$ARCH" = "macosx" ] || [ "$ARCH" = "macosx64" ] || \ + [ "$ARCH" = "macosxicc" ]; then macosx_minor=`sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2` SOEXT="so" if [ $macosx_minor -ge 5 ]; then @@ -74,22 +74,33 @@ fi CXXFLAGS=`echo $CXXFLAGS | sed 's/-Iinclude //' ` # Determine the compiler version -COMPILERVERS="$CXX" -if [ "$CXX" = "g++" ] || [ "$CXX" = "icc" ]; then +BXX="`basename $CXX`" +COMPILERVERS="$BXX" +case $BXX in +g++*) cxxTemp=`$CXX -dumpversion` - cxxMajor=`echo $cxxTemp 2>&1 | cut -d'.' -f1` - cxxMinor=`echo $cxxTemp 2>&1 | cut -d'.' -f2` - cxxPatch=`echo $cxxTemp 2>&1 | cut -d'.' -f3` - if [ "$CXX" = "g++" ] ; then - COMPILERVERS="gcc" - fi - if [ "$cxxMajor" != "x" ] ; then - COMPILERVERS="$COMPILERVERS$cxxMajor" - if [ "$cxxMinor" != "x" ] ; then - COMPILERVERS="$COMPILERVERS$cxxMinor" - if [ "$cxxPatch" != "x" ] ; then - COMPILERVERS="$COMPILERVERS$cxxPatch" - fi + COMPILERVERS="gcc" + ;; +icc) + cxxTemp=`$CXX -dumpversion` + ;; +clang++*) + cxxTemp=`$CXX --version | grep version | \ + sed 's/.*\(version .*\)/\1/; s/.*based on \(LLVM .*\)svn)/\1/' | \ + cut -d ' ' -f 2` + COMPILERVERS="clang" + ;; +esac + +cxxMajor=`echo $cxxTemp 2>&1 | cut -d'.' -f1` +cxxMinor=`echo $cxxTemp 2>&1 | cut -d'.' -f2` +cxxPatch=`echo $cxxTemp 2>&1 | cut -d'.' -f3` +if [ "$cxxMajor" != "x" ] ; then + COMPILERVERS="$COMPILERVERS$cxxMajor" + if [ "$cxxMinor" != "x" ] ; then + COMPILERVERS="$COMPILERVERS$cxxMinor" + if [ "$cxxPatch" != "x" ] ; then + COMPILERVERS="$COMPILERVERS$cxxPatch" fi fi fi @@ -98,16 +109,17 @@ rm -f __compiledata echo "/* This is file is automatically generated */" > __compiledata echo "#define BUILD_ARCH \"$ARCH\"" >> __compiledata -echo "#define BUILD_NODE \""`uname -a`"\" " >> __compiledata -echo "#define COMPILER \""`type -path $CXX`"\" " >> __compiledata +echo "#define BUILD_NODE \""`uname -a`"\"" >> __compiledata +echo "#define CXX \"$BXX\"" >> __compiledata +echo "#define COMPILER \""`type -path $CXX`"\"" >> __compiledata echo "#define COMPILERVERS \"$COMPILERVERS\"" >> __compiledata if [ "$CUSTOMSHARED" = "" ]; then - echo "#define MAKESHAREDLIB \"cd \$BuildDir ; $CXX -c \$Opt $CXXFLAGS \$IncludePath \$SourceFiles ; $CXX \$ObjectFiles $SOFLAGS $LDFLAGS $EXPLLINKLIBS -o \$SharedLib\"" >> __compiledata + echo "#define MAKESHAREDLIB \"cd \$BuildDir ; $BXX -c \$Opt $CXXFLAGS \$IncludePath \$SourceFiles ; $BXX \$ObjectFiles $SOFLAGS $LDFLAGS $EXPLLINKLIBS -o \$SharedLib\"" >> __compiledata else echo "#define MAKESHAREDLIB \"$CUSTOMSHARED\"" >> __compiledata fi if [ "$CUSTOMEXE" = "" ]; then - echo "#define MAKEEXE \"cd \$BuildDir ; $CXX -c $OPT $CXXFLAGS \$IncludePath \$SourceFiles; $CXX \$ObjectFiles $LDFLAGS -o \$ExeName \$LinkedLibs $SYSLIBS\"" >> __compiledata + echo "#define MAKEEXE \"cd \$BuildDir ; $BXX -c $OPT $CXXFLAGS \$IncludePath \$SourceFiles; $BXX \$ObjectFiles $LDFLAGS -o \$ExeName \$LinkedLibs $SYSLIBS\"" >> __compiledata else echo "#define MAKEEXE \"$CUSTOMEXE\"" >> __compiledata fi @@ -116,8 +128,8 @@ echo "#define CXXDEBUG \"$CXXDEBUG\"" >> __compiledata echo "#define ROOTBUILD \"$ROOTBUILD\"" >> __compiledata echo "#define LINKEDLIBS \"-L$LIBDIR $ROOTLIBS $RINTLIBS \"" >> __compiledata echo "#define INCLUDEPATH \"-I$INCDIR\"" >> __compiledata -echo "#define OBJEXT \"o\" " >> __compiledata -echo "#define SOEXT \"$SOEXT\" " >> __compiledata +echo "#define OBJEXT \"o\"" >> __compiledata +echo "#define SOEXT \"$SOEXT\"" >> __compiledata ( if [ -r $COMPILEDATA ]; then diff --git a/build/unix/distfilelist.sh b/build/unix/distfilelist.sh index 1f8ea594e3e10..3afab90a01ed0 100755 --- a/build/unix/distfilelist.sh +++ b/build/unix/distfilelist.sh @@ -21,6 +21,7 @@ fi mv -f tutorials/gallery.root tutorials/gallery.root- mv -f tutorials/mlp/mlpHiggs.root tutorials/mlp/mlpHiggs.root- mv -f tutorials/quadp/stock.root tutorials/quadp/stock.root- +mv -f tutorials/proof/ntprndm.root tutorials/proof/ntprndm.root- find tutorials -name "*.root" -exec rm -rf {} \; >/dev/null 2>&1;true find tutorials -name "*.ps" -exec rm -rf {} \; >/dev/null 2>&1;true find tutorials -path tutorials/doc -prune -o -name "*.gif" -exec rm -rf {} \; >/dev/null 2>&1;true @@ -33,6 +34,7 @@ find tutorials -name "work.pcl" -exec rm -rf {} \; >/dev/null 2>&1;true mv -f tutorials/gallery.root- tutorials/gallery.root mv -f tutorials/mlp/mlpHiggs.root- tutorials/mlp/mlpHiggs.root mv -f tutorials/quadp/stock.root- tutorials/quadp/stock.root +mv -f tutorials/proof/ntprndm.root- tutorials/proof/ntprndm.root # mixture of files, wildcards, and directories WILDCARDS="LICENSE README bin \ @@ -78,6 +80,7 @@ echo `echo ${FILES} | tr ' ' '\n' | sed \ -e 's,^.*.cvsignore$,,' \ -e 's,^.*/CVS/.*$,,' \ -e 's,^.*/.svn/.*$,,' \ + -e 's,^.*/.git/.*$,,' \ -e 's,^.*/.*.dSYM/.*$,,' \ -e 's,^cint/.*/G__c_.*$',, \ -e 's,^cint/.*/G__cpp_.*$',, \ diff --git a/build/unix/git2cl.pl b/build/unix/git2cl.pl new file mode 100755 index 0000000000000..c3e8b44ad9f40 --- /dev/null +++ b/build/unix/git2cl.pl @@ -0,0 +1,413 @@ +#!/usr/bin/perl + +# Copyright (C) 2007, 2008 Simon Josefsson +# Copyright (C) 2007 Luis Mondesi +# * calls git directly. To use it just: +# cd ~/Project/my_git_repo; git2cl > ChangeLog +# * implements strptime() +# * fixes bugs in $comment parsing +# - copy input before we remove leading spaces +# - skip "merge branch" statements as they don't +# have information about files (i.e. we never +# go into $state 2) +# - behaves like a pipe/filter if input is given from the CLI +# else it calls git log by itself +# +# The functions mywrap, last_line_len, wrap_log_entry are derived from +# the cvs2cl tool, see : +# Copyright (C) 2001,2002,2003,2004 Martyn J. Pearce +# Copyright (C) 1999 Karl Fogel +# +# git2cl is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# git2cl is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with git2cl; see the file COPYING. If not, write to the Free +# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +# 02110-1301 USA. + +=head1 NAME + +git2cl - tool to convert git logs to GNU ChangeLog + +=head1 SYNOPSIS + +git2cl > ChangeLog + +If you don't want git2cl to invoke git log internally, you can use it +as a pipe. +It needs a git log generated with --pretty --numstat and --summary. +You can use it as follows: + + git log --pretty --numstat --summary | git2cl > ChangeLog + +=head1 DESCRIPTION + +This is a quick'n'dirty tool to convert git logs to GNU ChangeLog +format. + +The tool invokes `git log` internally unless you pipe a log to it. +Thus, typically you would use it as follows: + +=head1 SEE ALSO + +Output format specification: + + +=head1 AUTHORS + +git2cl is developed by Simon Josefsson + and Luis Mondesi + +=cut + +use strict; +use POSIX qw(strftime); +use Text::Wrap qw(wrap); +use FileHandle; + +use constant EMPTY_LOG_MESSAGE => '*** empty log message ***'; + +# this is a helper hash for stptime. +# Assumes you are calling 'git log ...' with LC_ALL=C +my %month = ( + 'Jan'=>0, + 'Feb'=>1, + 'Mar'=>2, + 'Apr'=>3, + 'May'=>4, + 'Jun'=>5, + 'Jul'=>6, + 'Aug'=>7, + 'Sep'=>8, + 'Oct'=>9, + 'Nov'=>10, + 'Dec'=>11, +); + +my $fh = new FileHandle; + +sub key_ready +{ + my ($rin, $nfd); + vec($rin, fileno(STDIN), 1) = 1; + return $nfd = select($rin, undef, undef, 0); +} + +sub strptime { + my $str = shift; + return undef if not defined $str; + + # we are parsing this format + # Fri Oct 26 00:42:56 2007 -0400 + # to these fields + # sec, min, hour, mday, mon, year, wday = -1, yday = -1, isdst = -1 + # Luis Mondesi + my @date; + if ($str =~ /([[:alpha:]]{3})\s+([[:alpha:]]{3})\s+([[:digit:]]{1,2})\s+([[:digit:]]{1,2}):([[:digit:]]{1,2}):([[:digit:]]{1,2})\s+([[:digit:]]{4})/){ + push(@date,$6,$5,$4,$3,$month{$2},($7 - 1900),-1,-1,-1); + } else { + die ("Cannot parse date '$str'\n'"); + } + return @date; +} + +sub mywrap { + my ($indent1, $indent2, @text) = @_; + # If incoming text looks preformatted, don't get clever + my $text = Text::Wrap::wrap($indent1, $indent2, @text); + if ( grep /^\s+/m, @text ) { + return $text; + } + my @lines = split /\n/, $text; + $indent2 =~ s!^((?: {8})+)!"\t" x (length($1)/8)!e; + $lines[0] =~ s/^$indent1\s+/$indent1/; + s/^$indent2\s+/$indent2/ + for @lines[1..$#lines]; + my $newtext = join "\n", @lines; + $newtext .= "\n" + if substr($text, -1) eq "\n"; + return $newtext; +} + +sub last_line_len { + my $files_list = shift; + my @lines = split (/\n/, $files_list); + my $last_line = pop (@lines); + return length ($last_line); +} + +# A custom wrap function, sensitive to some common constructs used in +# log entries. +sub wrap_log_entry { + my $text = shift; # The text to wrap. + my $left_pad_str = shift; # String to pad with on the left. + + # These do NOT take left_pad_str into account: + my $length_remaining = shift; # Amount left on current line. + my $max_line_length = shift; # Amount left for a blank line. + + my $wrapped_text = ''; # The accumulating wrapped entry. + my $user_indent = ''; # Inherited user_indent from prev line. + + my $first_time = 1; # First iteration of the loop? + my $suppress_line_start_match = 0; # Set to disable line start checks. + + my @lines = split (/\n/, $text); + while (@lines) # Don't use `foreach' here, it won't work. + { + my $this_line = shift (@lines); + chomp $this_line; + + if ($this_line =~ /^(\s+)/) { + $user_indent = $1; + } + else { + $user_indent = ''; + } + + # If it matches any of the line-start regexps, print a newline now... + if ($suppress_line_start_match) + { + $suppress_line_start_match = 0; + } + elsif (($this_line =~ /^(\s*)\*\s+[a-zA-Z0-9]/) + || ($this_line =~ /^(\s*)\* [a-zA-Z0-9_\.\/\+-]+/) + || ($this_line =~ /^(\s*)\([a-zA-Z0-9_\.\/\+-]+(\)|,\s*)/) + || ($this_line =~ /^(\s+)(\S+)/) + || ($this_line =~ /^(\s*)- +/) + || ($this_line =~ /^()\s*$/) + || ($this_line =~ /^(\s*)\*\) +/) + || ($this_line =~ /^(\s*)[a-zA-Z0-9](\)|\.|\:) +/)) + { + $length_remaining = $max_line_length - (length ($user_indent)); + } + + # Now that any user_indent has been preserved, strip off leading + # whitespace, so up-folding has no ugly side-effects. + $this_line =~ s/^\s*//; + + # Accumulate the line, and adjust parameters for next line. + my $this_len = length ($this_line); + if ($this_len == 0) + { + # Blank lines should cancel any user_indent level. + $user_indent = ''; + $length_remaining = $max_line_length; + } + elsif ($this_len >= $length_remaining) # Line too long, try breaking it. + { + # Walk backwards from the end. At first acceptable spot, break + # a new line. + my $idx = $length_remaining - 1; + if ($idx < 0) { $idx = 0 }; + while ($idx > 0) + { + if (substr ($this_line, $idx, 1) =~ /\s/) + { + my $line_now = substr ($this_line, 0, $idx); + my $next_line = substr ($this_line, $idx); + $this_line = $line_now; + + # Clean whitespace off the end. + chomp $this_line; + + # The current line is ready to be printed. + $this_line .= "\n${left_pad_str}"; + + # Make sure the next line is allowed full room. + $length_remaining = $max_line_length - (length ($user_indent)); + + # Strip next_line, but then preserve any user_indent. + $next_line =~ s/^\s*//; + + # Sneak a peek at the user_indent of the upcoming line, so + # $next_line (which will now precede it) can inherit that + # indent level. Otherwise, use whatever user_indent level + # we currently have, which might be none. + my $next_next_line = shift (@lines); + if ((defined ($next_next_line)) && ($next_next_line =~ /^(\s+)/)) { + $next_line = $1 . $next_line if (defined ($1)); + # $length_remaining = $max_line_length - (length ($1)); + $next_next_line =~ s/^\s*//; + } + else { + $next_line = $user_indent . $next_line; + } + if (defined ($next_next_line)) { + unshift (@lines, $next_next_line); + } + unshift (@lines, $next_line); + + # Our new next line might, coincidentally, begin with one of + # the line-start regexps, so we temporarily turn off + # sensitivity to that until we're past the line. + $suppress_line_start_match = 1; + + last; + } + else + { + $idx--; + } + } + + if ($idx == 0) + { + # We bottomed out because the line is longer than the + # available space. But that could be because the space is + # small, or because the line is longer than even the maximum + # possible space. Handle both cases below. + + if ($length_remaining == ($max_line_length - (length ($user_indent)))) + { + # The line is simply too long -- there is no hope of ever + # breaking it nicely, so just insert it verbatim, with + # appropriate padding. + $this_line = "\n${left_pad_str}${this_line}"; + } + else + { + # Can't break it here, but may be able to on the next round... + unshift (@lines, $this_line); + $length_remaining = $max_line_length - (length ($user_indent)); + $this_line = "\n${left_pad_str}"; + } + } + } + else # $this_len < $length_remaining, so tack on what we can. + { + # Leave a note for the next iteration. + $length_remaining = $length_remaining - $this_len; + + if ($this_line =~ /\.$/) + { + $this_line .= " "; + $length_remaining -= 2; + } + else # not a sentence end + { + $this_line .= " "; + $length_remaining -= 1; + } + } + + # Unconditionally indicate that loop has run at least once. + $first_time = 0; + + $wrapped_text .= "${user_indent}${this_line}"; + } + + # One last bit of padding. + $wrapped_text .= "\n"; + + return $wrapped_text; +} + +# main + +my @date; +my $author; +my @files; +my $comment; + +my $state; # 0-header 1-comment 2-files +my $done = 0; + +$state = 0; + +# if reading from STDIN, we assume that we are +# getting git log as input +if (key_ready()) +{ + + #my $dummyfh; # don't care about writing + #($fh,$dummyfh) = FileHandle::pipe; + $fh->fdopen(*STDIN, 'r'); +} +else +{ + $fh->open("LC_ALL=C git log --pretty --numstat --summary|") + or die("Cannot execute git log...$!\n"); +} + +while (my $_l = <$fh>) { + #print STDERR "debug ($state, " . (@date ? (strftime "%Y-%m-%d", @date) : "") . "): `$_'\n"; + if ($state == 0) { + if ($_l =~ m,^Author: (.*),) { + $author = $1; + } + if ($_l =~ m,^Date: (.*),) { + @date = strptime($1); + } + $state = 1 if ($_l =~ m,^$, and $author and (@date+0>0)); + } elsif ($state == 1) { + # * modifying our input text is a bad choice + # let's make a copy of it first, then we remove spaces + # * if we meet a "merge branch" statement, we need to start + # over and find a real entry + # Luis Mondesi + my $_s = $_l; + $_s =~ s/^ //g; + if ($_s =~ m/^Merge branch/) + { + @date = (); + $author = ""; + $state=0; + next; + } + if ($_s =~ m/^git-svn-id:/) + { + next; + } + $comment = $comment . $_s; + $state = 2 if ($_l =~ m,^$,); + } elsif ($state == 2) { + if ($_l =~ m,^([0-9]+)\t([0-9]+)\t(.*)$,) { + push @files, $3; + } + $done = 1 if ($_l =~ m,^$,); + } + + if ($done) { + print (strftime "%Y-%m-%d $author\n\n", @date); + + my $files = join (", ", @files); + $files = mywrap ("\t", "\t", "* $files"), ": "; + + if (index($comment, EMPTY_LOG_MESSAGE) > -1 ) { + $comment = "[no log message]\n"; + } + + my $files_last_line_len = 0; + $files_last_line_len = last_line_len($files) + 1; + my $msg = wrap_log_entry($comment, "\t", 69-$files_last_line_len, 69); + + $msg =~ s/[ \t]+\n/\n/g; + + print "$files: $msg\n"; + + @date = (); + $author = ""; + @files = (); + $comment = ""; + + $state = 0; + $done = 0; + } +} + +if (@date + 0) +{ + print (strftime "%Y-%m-%d $author\n\n", @date); + my $msg = wrap_log_entry($comment, "\t", 69, 69); + $msg =~ s/[ \t]+\n/\n/g; + print "\t* $msg\n"; +} diff --git a/build/unix/gitinfo.sh b/build/unix/gitinfo.sh new file mode 100755 index 0000000000000..b68093622eb07 --- /dev/null +++ b/build/unix/gitinfo.sh @@ -0,0 +1,30 @@ +#!/usr/bin/env bash + +# Store info about in which git branch, what SHA1 and at what date/time +# we executed make. + +dir= +dotgit=".git" +git=git +if [ $# = 1 ]; then + if [ -x /bin/cygpath ]; then + dir=`cygpath -u $1` + git=/usr/bin/git + else + dir=$1 + fi + dotgit="$dir/.git" +fi + +# if we don't see the .git directory, just return +if test ! -d $dotgit; then + exit 0; +fi + +OUT=etc/gitinfo.txt + +git --git-dir=$dotgit describe --all > $OUT +git --git-dir=$dotgit describe --always >> $OUT +date "+%b %d %Y, %H:%M:%S" >> $OUT + +exit 0 diff --git a/build/unix/installDavix.sh b/build/unix/installDavix.sh new file mode 100755 index 0000000000000..99bec49bbf1d0 --- /dev/null +++ b/build/unix/installDavix.sh @@ -0,0 +1,381 @@ +#!/bin/bash + +# +# Script to install a given version of Davix +# created from the xrootd similar script +# +# Syntax: +# ./installDavix.sh [] [-h|--help] [-d|--debug] [-o|--optimized] +# [-v |--version=] +# [-t |--tarball=] +# [-b |--builddir=] +# [--dvxopts=""] +# [--vers-subdir[=]] [--no-vers-subdir] +# [-j |--jobs=] +# [-k|--keep] [--bzip2] +# +# See printhelp for a description of the options. +# + +printhelp() +{ + echo " " + echo " Script to install a given version of Davix" + echo " " + echo " Syntax:" + echo " ./installDavix.sh [] [-h|--help] [-d|--debug] [-o|--optimized]" + echo " [-v |--version=]" + echo " [-t |--tarball=]" + echo " [-b |--builddir=]" + echo " [--dvxopts=\"\"]" + echo " [-j |--jobs=]" + echo " [--vers-subdir[=]] [--no-vers-subdir]" + echo " [-k|--keep] [--bzip2]" + echo " " + echo " where" + echo " : the directory where the bin, lib, include/davix, share and" + echo " man directories will appear (see also --vers-subdir)" + echo " The default is ." + echo " -b , --builddir=" + echo " directory where to build; default /tmp/davix-" + echo " -d,--debug build in debug mode (no optimization)" + echo " -h, --help print this help screen" + echo " -o,--optimized build in optimized mode without any debug symbol" + echo " -t , --tarball=" + echo " full local path to source tarball" + echo " -v , --version=" + echo " version in the form x.j.w[-hash-or-tag] ;" + echo " current default 0.2.7-3" + echo " --dvxopts=" + echo " additional configuration options to davix" + echo " (see davix web site)" + echo " --no-vers-subdir install in instead of /davix-" + echo " (or /, see --vers-subdir" + echo " --vers-subdir[=]" + echo " install in / instead of" + echo " /davix- or . Has priority" + echo " over --no-vers-subdir. Default =davix-." + echo " This option is on by default." + echo " -j , --jobs=" + echo " number of build jobs to run simultaneously when bulding;" + echo " default is + 1." + echo " -k, --keep" + echo " keep the build directory" + echo " --bzip2" + echo " use bzip2 to manage the tarball (when extension is .b2z)" + echo " " + echo " When relevant, the script uses 'wget' ('curl' on MacOS X) to retrieve" + echo " the tarball" +} + +cleanbuilddir() +{ + if test ! "x$KEEP" = "xyes"; then + if test ! "x$BUILDDIR" = "x" && test -d $BUILDDIR ; then + rm -rf $BUILDDIR + fi + fi +} + +DBGOPT="-DCMAKE_BUILD_TYPE=RelWithDebInfo" +TGTDIR="." +VERS="" +TARBALL="" +BUILDDIR="" +XRDOPTS="" +VSUBDIR="davix-" +MAKEMJ="" +KEEP="" +UNZIP="gunzip" +TUNZIP="xzf" + +# +# Parse long options first +other_args= +short_opts= +is_short="no" +for i in $@ ; do + opt="" + case $i in + --*) opt=`echo "$i" | sed 's/--//'` ;; + -*) if test "x$short_opts" = "x" ; then + short_opts="$i" ; + else + short_opts="$short_opts $i" ; + fi; is_short="yes" ;; + *) if test "x$is_short" = "xyes" ; then + if test "x$short_opts" = "x" ; then + short_opts="$i" ; + else + short_opts="$short_opts $i" ; + fi; + is_short="no" + else + if test "x$other_args" = "x" ; then + other_args="$i"; + else + other_args="$other_args $i"; + fi; + fi; + esac + if test ! "x$opt" = "x" ; then + case "$opt" in + *=*) oarg=`echo "$opt" | sed 's/[-_a-zA-Z0-9]*=//'`;; + *) oarg= ;; + esac ; + case $opt in + builddir=*) BUILDDIR="$oarg" ;; + debug) DBGOPT="-DCMAKE_BUILD_TYPE=Debug" ;; + help) printhelp ; exit ;; + jobs) MAKEMJ="-j$OPTARG" ;; + no-vers-subdir) VSUBDIR="" ;; + optimized) DBGOPT="-DCMAKE_BUILD_TYPE=Release" ;; + tarball=*) TARBALL="$oarg" ;; + version=*) VERS="$oarg" ;; + vers-subdir) VSUBDIR="davix-" ;; + vers-subdir=*) VSUBDIR="$oarg" ;; + xrdopts=*) XRDOPTS="$oarg" ;; + keep) KEEP="yes" ;; + bzip2) UNZIP="bunzip2" ; TUNZIP="xjf" ;; + esac + fi +done + +if test ! "x$short_opts" = "x" ; then + while getopts b:j:t:v:dhok i $short_opts ; do + case $i in + b) BUILDDIR="$OPTARG" ;; + d) DBGOPT="-DCMAKE_BUILD_TYPE=Debug" ;; + h) printhelp ; exit ;; + j) MAKEMJ="-j$OPTARG" ;; + o) DBGOPT="-DCMAKE_BUILD_TYPE=Release" ;; + t) TARBALL="$OPTARG" ;; + v) VERS="$OPTARG" ;; + k) KEEP="yes" ;; + \?) printhelp; exit 1 ;; + esac + if test ! "x$OPTARG" = "x" ; then + noa= + for a in $other_args ; do + if test ! "x$OPTARG" = "x$a" ; then + if test "x$noa" = "x" ; then + noa="$a" + else + noa="$noa $a" + fi + fi + done + other_args=$noa + fi + done +fi + +# Fill empty fields with any non-prefixed argument +if test ! "x$other_args" = "x" ; then + TGTDIR="$other_args" +fi + +XMK=make + +WRKDIR=$PWD + +if test "x$TGTDIR" = "x" ; then + echo " Install dir undefined!" + printhelp + exit 1 +else + tgtd="$TGTDIR" + TGTDIR=`(cd $tgtd && pwd)` + if [ "$?" -ne "0" ]; then + echo "Install dir $tgtd does not exist, please create it first." + exit 1 + fi +fi + +if test "x$VERS" = "x" ; then + VERS="0.2.7" +fi +echo "Version: $VERS" + +if test ! "x$VSUBDIR" = "x" ; then + TGTDIR="$TGTDIR/$VSUBDIR$VERS" +fi +echo "Installing in: $TGTDIR" + +retrieve="yes" +if test ! "x$TARBALL" = "x" && test -f $TARBALL ; then + retrieve="no" + TGTBALL=$TARBALL +fi +if test "x$retrieve" = "xyes" ; then + if test "x$TARBALL" = "x" ; then + TARBALL="http://grid-deployment.web.cern.ch/grid-deployment/dms/lcgutil/tar/davix/davix-$VERS.tar.gz" + TGTBALL="davix-$VERS.tar.gz" + else + TGTBALL=`basename $TARBALL` + fi +fi +if test "x$retrieve" = "xyes" ; then + echo "Retrieving source from tarball $TARBALL" +else + echo "Building tarball $TARBALL" +fi + +# Build dir +if test "x$BUILDDIR" = "x"; then + BUILDDIR="/tmp/davix-$VERS-$RANDOM" +fi +if test ! -d $BUILDDIR ; then + mkdir -p $BUILDDIR + if test ! -d $BUILDDIR ; then + echo "Could not create build dir $BUILDDIR, exiting..." + exit 1 + fi +else + # Builddir already exists, exit + echo "Build dir $BUILDDIR already exists, exiting..." + exit 1 +fi +echo "Build dir: $BUILDDIR" + +cd $BUILDDIR + +# Retrieving source +ARCH=`uname -s` +if test "x$retrieve" = "xyes" ; then + if test "x$ARCH" = "xDarwin" ; then + curl $TARBALL -o $TGTBALL + else + wget $TARBALL -O $TGTBALL + fi + if test ! -f $TGTBALL ; then + echo "Tarball retrieval failed!" + cd $WRKDIR + cleanbuilddir + exit 1 + fi +fi + +# Untar tarball +if test "x$ARCH" = "xSunOS" ; then + XMK="gmake" + $UNZIP -c $TGTBALL > "$TGTBALL.tar" + tar xf "$TGTBALL.tar" + rm -f "$TGTBALL.tar" +else + tar $TUNZIP $TGTBALL +fi +if test ! -d davix-$VERS ; then + echo "Could not find source sub-directory davix-$VERS" + cd $WRKDIR + cleanbuilddir + exit 1 +fi +cd davix-$VERS + +# CMake or old {make,configure} ? +if test -f CMakeLists.txt ; then + + # CMake: check if there + XCMK=`which cmake 2> /dev/null` + echo "XCMK = '$XCMK'" + if test "x$XCMK" = "x" || test ! -f $XCMK ; then + echo " " + echo "To build davix cmake is required: " + echo "you can get it from http://cmake.org/cmake/resources/software.html" + echo "or from the software manager of your system" + echo " " + cd $WRKDIR + cleanbuilddir + exit 1 + fi + + # Check that we can build this version + #if test ! -r VERSION_INFO ; then + # echo "VERSION_INFO file not found: this davix version is probably too old and cannot be built by this script" + # cd $WRKDIR + # cleanbuilddir + # exit 1 + #fi + + # Create build directory + mkdir build + cd build + + # Configure + $XCMK -DCMAKE_INSTALL_PREFIX=$TGTDIR $DBGOPT $XRDOPTS .. + + # Get the '-j' setting if not specified + if test "x$MAKEMJ" = "x" ; then + MJ=`grep -c bogomips /proc/cpuinfo 2> /dev/null` + [ "$?" != 0 ] && MJ=`sysctl hw.ncpu | cut -b10 2> /dev/null` + let MJ++ + MAKEMJ="-j$MJ" + fi + + # Build + $XMK $MAKEMJ + if [ "$?" != "0" ] ; then + echo "Problems running $XMK $MAKEMJ ..." + cd $WRKDIR + cleanbuilddir + exit "$?" + fi + + # Install + $XMK install + if [ "$?" != "0" ] ; then + echo "Problems running $XMK install ..." + cd $WRKDIR + cleanbuilddir + exit "$?" + fi + +else + + # Old {configure,make} + + # Check that we can build this version + if test ! -r configure.classic ; then + echo "configure.classic file not found: this davix version cannot be built by this script" + cd $WRKDIR + cleanbuilddir + exit 1 + fi + + # Configure options + if test "x$DBGOPT" = "xRelease" ; then + DBGOPT="" + else + DBGOPT="--build=debug" + fi + CFGOPT="--disable-krb4 --no-arch-subdirs --disable-mon --enable-krb5" + + # Configure + ./configure.classic --prefix=$TGTDIR $DBGOPT $CFGOPT $XRDOPTS + if [ "$?" != "0" ] ; then + echo "Problems running configure.classic ..." + cd $WRKDIR + cleanbuilddir + exit "$?" + fi + + # Make + $XMK + if [ "$?" != "0" ] ; then + echo "Problems running $XMK ..." + cd $WRKDIR + cleanbuilddir + exit "$?" + fi + + # Install + $XMK install + +fi + +# Go back where we started +cd $WRKDIR +cleanbuilddir + +exit diff --git a/build/unix/installXrootd.sh b/build/unix/installXrootd.sh index 7096024fadd0b..ef0316b5e5741 100755 --- a/build/unix/installXrootd.sh +++ b/build/unix/installXrootd.sh @@ -44,7 +44,7 @@ printhelp() echo " full local path to source tarball" echo " -v , --version=" echo " version in the form x.j.w[-hash-or-tag] ;" - echo " current default 3.2.0" + echo " current default 3.2.7" echo " --xrdopts=" echo " additional configuration options to xrootd" echo " (see xrootd web site)" @@ -192,7 +192,7 @@ else fi if test "x$VERS" = "x" ; then - VERS="3.2.0" + VERS="3.2.7" fi echo "Version: $VERS" diff --git a/build/unix/makechangelog.sh b/build/unix/makechangelog.sh index 602e9fb371f54..0dc647b0de4bf 100755 --- a/build/unix/makechangelog.sh +++ b/build/unix/makechangelog.sh @@ -1,14 +1,12 @@ #! /bin/sh -SVN2CL=build/unix/svn2cl.sh +GIT2CL=build/unix/git2cl.pl echo "" -echo "Generating README/ChangeLog from SVN logs..." +echo "Generating README/ChangeLog from Git logs..." echo "" -# Generate ChangeLog from version v5-12-00 till now -#$SVN2CL -i -f README/ChangeLog -r HEAD:15807 -# Generate ChangeLof from version v5-27-01 till now -$SVN2CL -i -f README/ChangeLog -r HEAD:31884 +# Generate ChangeLog from version v5-33-01 till now +LC_ALL=C git log --pretty --numstat --summary 82607481af2c5a2ece9a0d343fe795b00f3940d8..HEAD | $GIT2CL > README/ChangeLog exit 0 diff --git a/build/unix/makecintdll.sh b/build/unix/makecintdll.sh index 53f13456ed408..2bf83e4af3c72 100755 --- a/build/unix/makecintdll.sh +++ b/build/unix/makecintdll.sh @@ -20,7 +20,8 @@ if [ $PLATFORM != "clean" ]; then OPT=$1 ; shift CINTCXXFLAGS=$1 ; shift CINTCFLAGS=$1 ; shift - LDFLAGS=$1 ; shift + LDFLAGS=$1 ; shift + LIBS=$1 ; shift SOFLAGS=$1 ; shift SOEXT=$1 ; shift COMPILER=$1 ; shift @@ -121,7 +122,7 @@ execute "$CINT -K -w1 -z$DLLNAME -n$DLLSOURCE -D__MAKECINT__ \ execute "$COMP $OPT $COMPFLAGS -I. $CXXOUT$DLLOBJECT -I$DLLDIR \ -c $DLLSOURCE" $MAKELIB $PLATFORM $LD "$LDFLAGS" "$SOFLAGS" $DLLNAME.$SOEXT \ - $CINTDIRI/$DLLNAME.$SOEXT "$DLLOBJECT" + $CINTDIRI/$DLLNAME.$SOEXT "$DLLOBJECT" "$LIBS" rename $CINTDIRI/$DLLNAME rm -f $DLLSOURCE $DLLOBJECT $DLLHEADER diff --git a/build/unix/makedist.sh b/build/unix/makedist.sh index f5e33d92e13ff..1eeb20cf0c1a6 100755 --- a/build/unix/makedist.sh +++ b/build/unix/makedist.sh @@ -10,6 +10,8 @@ TYPE=`bin/root-config --arch` if [ "x`bin/root-config --platform`" = "xmacosx" ]; then TYPE=$TYPE-`sw_vers -productVersion | cut -d . -f1 -f2` TYPE=$TYPE-`uname -p` + # /usr/bin/tar on OSX is BSDTAR which is for our purposes GNU tar compatible + TAR=/usr/bin/tar fi if [ "x`bin/root-config --platform`" = "xsolaris" ]; then TYPE=$TYPE-`uname -r` @@ -60,7 +62,8 @@ else TARFILE=${TARFILE}".gz" TARCMD="${TAR} zcvf ${TARFILE} -T ${TARFILE}.filelist" else - TARCMD="tar cvf ${TARFILE}" + # use r to append to archive which is needed when using xargs + TARCMD="tar rvf ${TARFILE}" DOGZIP="y" fi fi @@ -77,7 +80,7 @@ rm -f ${TARFILE} if [ "x${TAR}" != "x" ] || [ "x$MSI" = "x1" ]; then $TARCMD || exit 1 else - $TARCMD `cat ${TARFILE}.filelist` || exit 1 + (cat ${TARFILE}.filelist | xargs $TARCMD) || exit 1 fi rm ${TARFILE}.filelist diff --git a/build/unix/makedistsrc.sh b/build/unix/makedistsrc.sh index 5199e82112f93..494c8a68fda74 100755 --- a/build/unix/makedistsrc.sh +++ b/build/unix/makedistsrc.sh @@ -1,35 +1,23 @@ #! /bin/sh -EXPDIR=$HOME/root_export_$$ CURVERS=`cat build/version_number | sed -e "s/^/v/" -e "s/\./-/" -e "s/\//-/"` ROOTVERS=`cat build/version_number | sed -e 's/\//\./'` -URL=`svn info | awk '/URL:/ { print $2 }' | sed 's/https/http/'` -MACHINE=`uname` -OSREL=`uname -r` TYPE=source TARFILE=root_v$ROOTVERS.$TYPE.tar -rm -rf $EXPDIR -mkdir $EXPDIR -cd $EXPDIR +# generate etc/gitinfo.txt +build/unix/gitinfo.sh -#svn co http://root.cern.ch/svn/root/tags/$CURVERS root -svn co $URL root +#git archive -v -o ../$TARFILE --prefix=root/ master +git archive -v -o ../$TARFILE --prefix=root/ $CURVERS -# generate etc/svninfo.txt -cd root -build/unix/svninfo.sh +mkdir -p etc/root/etc +cp etc/gitinfo.txt etc/root/etc/ +cd etc +tar -r -vf ../../$TARFILE root/etc/gitinfo.txt +cd .. +rm -rf etc/root cd .. - -# remove .svn directories containing extra copy of the code -find root -depth -name .svn -exec rm -rf {} \; - -tar cvf $TARFILE root gzip $TARFILE -mv $TARFILE.gz $HOME - -cd -rm -rf $EXPDIR - exit 0 diff --git a/build/unix/makehtml.sh b/build/unix/makehtml.sh index 273f90632babe..ba37cbe7f4569 100755 --- a/build/unix/makehtml.sh +++ b/build/unix/makehtml.sh @@ -1,8 +1,7 @@ #! /bin/sh -ROOT=bin/root.exe - dir=`pwd` +ROOT=$dir/bin/root cd tutorials # we need tutorials/hsimple.root if [ ! -f hsimple.root ]; then @@ -19,6 +18,8 @@ echo "" echo "Generating doc in directory htmldoc/..." echo "" +# To generate the full documentation, we do need to +# use the graphics engine, so do not use '-b'. $ROOT -l < \(.*\)/\1/;/^[^/]/s,^,$dir/,"` -done -dir=`dirname "$prog"` -dir=`cd "$dir" && pwd` -#dir=/etc/svn2cl -XSL="$dir/svn2${OUTSTYLE}.xsl" - -# check if the authors file is formatted as a legacy -# colon separated file -if [ -n "$AUTHORSFILE" ] && \ - egrep '^(#.*|[a-zA-Z0-9].*:)' "$AUTHORSFILE" > /dev/null 2>/dev/null -then - # create a temporary file - tmpfile=`mktemp -t svn2cl.XXXXXX 2> /dev/null || tempfile -s .svn2cl 2> /dev/null || echo "$AUTHORSFILE.$$.xml"` - arg=`echo "$tmpfile" | sed "s/'/'\"'\"'/g"` - TMPFILES="$TMPFILES '$arg'" - # generate an authors.xml file on the fly - echo '' > "$tmpfile" - sed -n 's/&/\&/g;s//\>/g;s|^\([a-zA-Z0-9][^:]*\):\(.*\)$| \2|p' \ - < "$AUTHORSFILE" >> "$tmpfile" - echo '' >> "$tmpfile" - AUTHORSFILE="$tmpfile" -fi - -# find the absolute path of the authors file -# (otherwise xsltproc will find the file relative to svn2cl.xsl) -pwd=`pwd` -AUTHORSFILE=`echo "$AUTHORSFILE" | sed "/^[^/]/s|^|$pwd/|"` - -# if no filename was specified, make one up -if [ -z "$CHANGELOG" ] -then - CHANGELOG="ChangeLog" - if [ "$OUTSTYLE" != "cl" ] - then - CHANGELOG="$CHANGELOG.$OUTSTYLE" - fi -fi - -# try to determin a prefix to strip from all paths -if [ "$STRIPPREFIX" = "AUTOMATICALLY-DETERMINED" ] -then - STRIPPREFIX=`LANG=C eval "$SVNINFOCMD" 2> /dev/null | $AWK '/^URL:/{url=$2} /^Repository Root:/{root=$3} END{if(root){print substr(url,length(root)+2)}else{n=split(url,u,"/");print u[n]}}'` - STRIPPREFIX=`echo "$STRIPPREFIX" | sed 's/%20/ /g'` -fi - -# redirect stdout to the changelog file if needed -if [ "x$CHANGELOG" != "x-" ] -then - exec > "$CHANGELOG" -fi - -# actually run the command we need -eval "$SVNLOGCMD" | \ - xsltproc --stringparam strip-prefix "$STRIPPREFIX" \ - --stringparam linelen "$LINELEN" \ - --stringparam groupbyday "$GROUPBYDAY" \ - --stringparam separate-daylogs "$SEPARATEDAYLOGS" \ - --stringparam include-rev "$INCLUDEREV" \ - --stringparam include-actions "$ACTIONS" \ - --stringparam breakbeforemsg "$BREAKBEFOREMSG" \ - --stringparam reparagraph "$REPARAGRAPH" \ - --stringparam authorsfile "$AUTHORSFILE" \ - --stringparam title "$TITLE" \ - --stringparam revision-link "$REVISION_LINK" \ - --stringparam ignore-message-starting "$IGNORE_MESSAGE_STARTING" \ - --nowrite \ - --nomkdir \ - --nonet \ - "$XSL" - - -# clean up temporary files -[ -n "$TMPFILES" ] && eval "rm -f $TMPFILES" - -# we're done (the previous command could return false) -exit 0 diff --git a/build/unix/svn2cl.xsl b/build/unix/svn2cl.xsl deleted file mode 100644 index 3d9db020039df..0000000000000 --- a/build/unix/svn2cl.xsl +++ /dev/null @@ -1,494 +0,0 @@ - - - - - -]> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - &space;&space; - - - - - - - - - - - - - - - - - &space;&space; - - - - - - - - - - - - - - [r - - ]&space; - - - - - - - - - - - - - - - - - - - - - - - *&space; - - - - - - - - - - - - - - - - - - - - - - &space; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ,&space; - - - - - - - - - - - - - - - - - - ,&space; - - - - - - - - - - - - - - - - [DEL] - - - [CPY] - - - [ADD] - - - - - - - - - - - - - - - - - - - - - - - . - - - - - - - - - - - - - - - - - - - &space;&space; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - &space;&space; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/build/unix/svninfo.sh b/build/unix/svninfo.sh deleted file mode 100755 index d259f0ea200f6..0000000000000 --- a/build/unix/svninfo.sh +++ /dev/null @@ -1,46 +0,0 @@ -#!/usr/bin/env bash - -# Store info about which svn branch, what revision and at what date/time -# we executed make. - -dir= -dotsvn=".svn" -svn=svn -if [ $# = 1 ]; then - if [ -x /bin/cygpath ]; then - dir=`cygpath -u $1` - svn=/usr/bin/svn - else - dir=$1 - fi - dotsvn="$dir/.svn" -fi - -# if we don't see the .svn directory, just return -if test ! -d $dotsvn; then - exit 0; -fi - -OUT=etc/svninfo.txt - -INFO=`$svn info $dir | awk '/Last Changed Rev:/ { print $4 } /URL:/ { print $2 }'` - -HTTP="http://root.cern.ch/svn/root/" -HTTPS="https://root.cern.ch/svn/root/" - -for i in $INFO; do - if test ${i:0:4} = "http"; then - if test ${i:0:5} = "https"; then - echo ${i#${HTTPS}} > $OUT - else - echo ${i#${HTTP}} > $OUT - fi - else - echo $i >> $OUT - echo $i - fi -done - -date "+%b %d %Y, %H:%M:%S" >> $OUT - -exit 0 diff --git a/build/version.cxx b/build/version.cxx index fa73765e3855d..7563f5aa7bbd1 100644 --- a/build/version.cxx +++ b/build/version.cxx @@ -7,7 +7,7 @@ int main(int argc, char *argv[]) // Author: Fons Rademakers 11/10/99 const char *in = "build/version_number"; - const char *inr = "etc/svninfo.txt"; + const char *inr = "etc/gitinfo.txt"; FILE *fp = fopen(in, "r"); if (!fp) { @@ -21,13 +21,13 @@ int main(int argc, char *argv[]) fp = fopen(inr, "r"); if (!fp) { - printf("%s: can not open input file %s\n", argv[0], in); + printf("%s: can not open input file %s\n", argv[0], inr); exit(1); } char branch[2048]; fgets(branch, sizeof(branch), fp); if (branch[strlen(branch)-1] == '\n') branch[strlen(branch)-1] = 0; - char revs[32]; + char revs[42]; fgets(revs, sizeof(revs), fp); if (revs[strlen(revs)-1] == '\n') revs[strlen(revs)-1] = 0; fclose(fp); @@ -53,16 +53,16 @@ int main(int argc, char *argv[]) fprintf(fp, " *\n"); fprintf(fp, "*/\n\n"); - int xx, yy, zz, rev; + int xx, yy, zz; sscanf(vers, "%d.%d/%d", &xx, &yy, &zz); int vers_code = (xx << 16) + (yy << 8) + zz; - sscanf(revs, "%d", &rev); fprintf(fp, "#define ROOT_RELEASE \"%s\"\n", vers); fprintf(fp, "#define ROOT_RELEASE_DATE \"%s\"\n", __DATE__); fprintf(fp, "#define ROOT_RELEASE_TIME \"%s\"\n", __TIME__); - fprintf(fp, "#define ROOT_SVN_REVISION %d\n", rev); - fprintf(fp, "#define ROOT_SVN_BRANCH \"%s\"\n", branch); + fprintf(fp, "#define ROOT_SVN_REVISION 49361\n"); + fprintf(fp, "#define ROOT_GIT_COMMIT \"%s\"\n", revs); + fprintf(fp, "#define ROOT_GIT_BRANCH \"%s\"\n", branch); fprintf(fp, "#define ROOT_VERSION_CODE %d\n", vers_code); fprintf(fp, "#define ROOT_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c))\n"); fprintf(fp, "\n#endif\n"); diff --git a/build/version_number b/build/version_number index 2f82b208e276b..5f8507a3248c4 100644 --- a/build/version_number +++ b/build/version_number @@ -1 +1 @@ -5.34/00-rc1 +5.34/13 diff --git a/build/win/makeresource.sh b/build/win/makeresource.sh index 099ab3ebab0b0..9163d71c6e862 100755 --- a/build/win/makeresource.sh +++ b/build/win/makeresource.sh @@ -29,11 +29,11 @@ else RCFILEICON= fi -# Use svninfo.txt: more precise than the info in Rversion.h -SVNBRANCH=`cat etc/svninfo.txt|head -n1` -SVNREV=`cat etc/svninfo.txt|head -n2|tail -n1` -SVNDATE="`cat etc/svninfo.txt|tail -n1`" -SVNYEARCOMMA=`echo $SVNDATE|cut -d' ' -f3` +# Use gitinfo.txt: more precise than the info in Rversion.h +GITBRANCH=`cat etc/gitinfo.txt|head -n1` +GITREV=`cat etc/gitinfo.txt|head -n2|tail -n1` +GITDATE="`cat etc/gitinfo.txt|tail -n1`" +GITYEARCOMMA=`echo $GITDATE|cut -d' ' -f3` # Can't do that inside the .rc file: FILEVERSION doesn't evaluate a>>b VERSION=`grep "ROOT_RELEASE " include/RVersion.h | sed 's,^.*"\([^"]*\)".*$,\1,' | sed 's,[^[:digit:]], ,g'` @@ -43,9 +43,9 @@ VER3=`echo $VERSION| cut -d ' ' -f 3| sed 's,^0,,'` # 0: tag, 1: trunk, 2: branch VERBRANCHFLAG=1 -if [ "x${SVNBRANCH/tag/}" != "x${SVNBRANCH}" ]; then +if [ "x${GITBRANCH/tag/}" != "x${GITBRANCH}" ]; then VERBRANCHFLAG=0 -elif [ "x${SVNBRANCH/branch/}" != "x${SVNBRANCH}" ]; then +elif [ "x${GITBRANCH/branch/}" != "x${GITBRANCH}" ]; then VERBRANCHFLAG=2 fi @@ -66,7 +66,7 @@ LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL ${RCFILEICON} #endif -#define ROOT_VERSION_STR ROOT_RELEASE " (r${SVNREV}@${SVNBRANCH}, ${SVNDATE})\0" +#define ROOT_VERSION_STR ROOT_RELEASE " (${GITREV}@${GITBRANCH}, ${GITDATE})\0" #if (${VERBRANCHFLAG} != 0) # define ROOT_IS_PRERELEASE VS_FF_PRERELEASE @@ -105,7 +105,7 @@ BEGIN VALUE "FileDescription", "ROOT ${RCFILETITLE} ${FILESTEM}\0" VALUE "FileVersion", ROOT_VERSION_STR VALUE "InternalName", "${FILESTEM}\0" - VALUE "LegalCopyright", "Copyright (C) 1995-${SVNYEARCOMMA} Rene Brun and Fons Rademakers.\0" + VALUE "LegalCopyright", "Copyright (C) 1995-${GITYEARCOMMA} Rene Brun and Fons Rademakers.\0" VALUE "OriginalFilename","${FILENAME}\0" VALUE "ProductName", "ROOT\0" VALUE "ProductVersion", ROOT_VERSION_STR diff --git a/build/win/sehmap.h b/build/win/sehmap.h new file mode 100644 index 0000000000000..033ff95a3f4fd --- /dev/null +++ b/build/win/sehmap.h @@ -0,0 +1,22 @@ +/* + + SEHMAP.H - Map old-style structured exception handling to correct names. + + The mapping of structured exception handling statements from {try, except, + finally, leave} to their proper names (prefaced by "__") has been removed + from win32.mak. This header is provided solely for compatibility with + source code that used the older convention. + +*/ + + +#ifndef __cplusplus +#undef try +#undef except +#undef finally +#undef leave +#define try __try +#define except __except +#define finally __finally +#define leave __leave +#endif diff --git a/build/win/w32pragma.h b/build/win/w32pragma.h index d72bef2675630..e2d2ebfff93b2 100644 --- a/build/win/w32pragma.h +++ b/build/win/w32pragma.h @@ -65,7 +65,7 @@ #define CRTAPI1 _cdecl #define CRTAPI2 _cdecl #define _X86_ 1 -// #define _DLL - used to be explicitely defined, +// #define _DLL - used to be explicitly defined, // but it's implicitely defined via /MD(d) #define G__REDIRECTIO 1 #define G__SHAREDLIB 1 diff --git a/cint/FAQ.txt b/cint/FAQ.txt index 006a078c16b3d..0ae3a482553f3 100644 --- a/cint/FAQ.txt +++ b/cint/FAQ.txt @@ -45,7 +45,7 @@ CINT C++ interpreter Frequently Asked Questions ############################################################################ # Is there CINT related news group or mailing list? - cint@root.cern.ch is the mailng list for CINT. Send request to + root-cint@cern.ch is the mailng list for CINT. Send request to 'Majordomo@pcroot.cern.ch' containing following line for subscription. subscribe cint [preferred mail address] @@ -53,10 +53,10 @@ CINT C++ interpreter Frequently Asked Questions Archive for CINT mailing list can be accessed as follows. http://root.cern.ch/root/cinttalk/AboutCint.html - roottalk@pcroot.cern.ch is the mailing list for ROOT/CINT framework. This + roottalk@cern.ch is the mailing list for ROOT/CINT framework. This mailing list is mixture of ROOT and CINT. - rootdev@pcroot.cern.ch is a mailing list distributed for ROOT/CINT + rootdev@cern.ch is a mailing list distributed for ROOT/CINT developpers. root-bugs@pcroot.cern.ch is an entry for ROOT/CINT bug reporting system. diff --git a/cint/README.txt b/cint/README.txt index 1ed999aeef0eb..1d786bdea280a 100644 --- a/cint/README.txt +++ b/cint/README.txt @@ -6,7 +6,7 @@ cint 5.18.00 (CINT is pronounced "C-int") Author Masaharu Goto Copyright(c) 1995~2010 Masaharu Goto (gotom@hanno.jp) - Mailing list cint@root.cern.ch + Mailing list root-cint@cern.ch Note: Search 'Installation' for installation instruction. @@ -102,7 +102,7 @@ Getting the latest package ================================================= see http://root.cern.ch/twiki/bin/view/ROOT/CINT CINT mailing list ========================================================== - cint@root.cern.ch + root-cint@cern.ch Send request to 'Majordomo@pcroot.cern.ch' containing following line for subscription. @@ -209,7 +209,7 @@ The Author =============================================================== Masaharu Goto Please contact the author for bugs and requests by sending an e-mail to - cint@root.cern.ch. You can also send message to 'rootdev@root.cern.ch' - or 'roottalk@root.cern.ch' for generic questions. + root-cint@cern.ch. You can also send message to 'rootdev@cern.ch' + or 'roottalk@cern.ch' for generic questions. Bugs are tend to be fixed very quickly. (Normally 1-2 days.) diff --git a/cint/RELNOTE.txt b/cint/RELNOTE.txt index 5101dc9e10a58..16ef8ecdfe969 100644 --- a/cint/RELNOTE.txt +++ b/cint/RELNOTE.txt @@ -3,7 +3,7 @@ RELNOTE.txt cint 5.16.29/6.1.29 release note - CINT mailing list - Cint mailing list 'cint@root.cern.ch' is started. Send request to + Cint mailing list 'root-cint@cern.ch' is started. Send request to 'Majordomo@pcroot.cern.ch' containing following line for subscription. subscribe cint [preferred mail address] diff --git a/cint/ROOT/CMakeLists.txt b/cint/ROOT/CMakeLists.txt index fc4acf791b319..2519c6fc4c060 100644 --- a/cint/ROOT/CMakeLists.txt +++ b/cint/ROOT/CMakeLists.txt @@ -139,9 +139,9 @@ foreach(_name ${CINTSTLDLLNAMES}) add_Library(${_name}Dict SHARED ${Dictionary}.cxx ) set_Target_properties(${_name}Dict PROPERTIES PREFIX ${libprefix} SUFFIX ${libsuffix} FOLDER Dictionaries) - install(TARGETS ${_name}Dict RUNTIME DESTINATION bin - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib) + install(TARGETS ${_name}Dict RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}) if(explicitlink) target_link_libraries(${_name}Dict Cint Core) @@ -160,7 +160,7 @@ foreach(_name ${CINTSTLDLLNAMES}) if(explicitlink) target_link_libraries(${_name} Cint) endif() - install(TARGETS ${_name} DESTINATION cint/cint/stl) + install(TARGETS ${_name} DESTINATION ${CMAKE_INSTALL_CINTINCDIR}/cint/stl) endforeach() @@ -185,7 +185,7 @@ foreach(_name ${CINTINCDLLNAMES}) if(explicitlink) target_link_libraries(${_name} Cint ${CMAKE_M_LIBS}) endif() - install(TARGETS ${_name} DESTINATION cint/cint/include) + install(TARGETS ${_name} DESTINATION ${CMAKE_INSTALL_CINTINCDIR}/cint/include) elseif(_name MATCHES ipc) add_custom_command(OUTPUT ${OutFileName} @@ -203,7 +203,7 @@ foreach(_name ${CINTINCDLLNAMES}) if(explicitlink) target_link_libraries(${_name} Cint) endif() - install(TARGETS ${_name} DESTINATION cint/cint/include) + install(TARGETS ${_name} DESTINATION ${CMAKE_INSTALL_CINTINCDIR}/cint/include) elseif(_name MATCHES posix) @@ -243,6 +243,6 @@ foreach(_name ${CINTINCDLLNAMES}) if(explicitlink) target_link_libraries(${_name} Cint) endif() - install(TARGETS ${_name} DESTINATION cint/cint/include) + install(TARGETS ${_name} DESTINATION ${CMAKE_INSTALL_CINTINCDIR}/cint/include) endif() endforeach() diff --git a/cint/ROOT/cintdlls.mk b/cint/ROOT/cintdlls.mk index 0b777aa056e7d..0b3d690180bb5 100644 --- a/cint/ROOT/cintdlls.mk +++ b/cint/ROOT/cintdlls.mk @@ -134,7 +134,7 @@ $(CINTDLLDIRDLLSTL)/G__cpp_pair.cxx: $(CINTDLLDIRL)/dll_stl/pr.h $(CINTCPPDEP) $(CINTDLLDIRL)/G__cpp_stdcxxfunc.cxx: $(CINTDLLDIRL)/stdstrct/stdcxxfunc.h $(CINTCPPDEP) $(CINTDLLDIRL)/G__c_stdfunc.c: $(CINTDLLDIRL)/stdstrct/stdfunc.h $(CINTCPPDEP) $(CINTDLLDIRL)/G__c_posix.c: $(CINTDLLDIRL)/posix/exten.h $(CINTCPPDEP) -$(CINTDLLDIRL)/G__c_ipc.c: $(CINTDLLDIRL)/ipc/ipcif.h $(CINTCPPDEP) +$(CINTDLLDIRL)/G__c_ipc.c: $(CINTDLLDIRL)/ipc/ipcif.h $(CINTCPPDEP) ##### all cintdlls end on .dll ifneq ($(SOEXT),dll) @@ -221,7 +221,25 @@ ifeq ($(subst $(MACOSX_MINOR),,1234),1234) $(CINTDLLDIRL)/G__c_posix.c: MACOSX_UNIX03 = -D__DARWIN_UNIX03 endif -$(CINTDLLDIRL)/G__c_%.o: CFLAGS := $(filter-out -Iinclude,$(CINTDLLCFLAGS)) -I. -DG__SYSTYPES_H +ifneq (,$(GCC_MAJOR)) +# gcc +ifeq (,$(findstring $(GCC_MAJOR),1 2 3)) +ifneq ($(GCC_MAJOR),4) +# GCC 5 and up +CINTDLLCDEPR := -Wno-deprecated-declarations +else +ifeq (,$(findstring $(GCC_MINOR),0 1 2 3 4 5 6)) +# GCC 4.7 and up +CINTDLLCDEPR := -Wno-deprecated-declarations +endif +endif +endif +endif +ifeq ($(MACOSX_TMPNAM_DEPRECATED),yes) +CINTDLLCDEPR := -Wno-deprecated-declarations +endif + +$(CINTDLLDIRL)/G__c_%.o: CFLAGS := $(filter-out -Iinclude,$(CINTDLLCFLAGS)) -I. -DG__SYSTYPES_H $(CINTDLLCDEPR) ##### posix special treatment $(CINTDLLDIRL)/posix/exten.o: $(CINTDLLDIRL)/posix/exten.c diff --git a/cint/build/Cint.mk b/cint/build/Cint.mk index c41fbe684ba4c..5f024921c7267 100644 --- a/cint/build/Cint.mk +++ b/cint/build/Cint.mk @@ -3,7 +3,7 @@ # ############################################################## # -# Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) +# Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) # # For the licensing terms see the file COPYING # diff --git a/cint/build/Makefile b/cint/build/Makefile index 4d1213c83eead..a966223028323 100644 --- a/cint/build/Makefile +++ b/cint/build/Makefile @@ -5,7 +5,7 @@ # ############################################################## # -# Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) +# Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) # # For the licensing terms see the file COPYING # diff --git a/cint/build/libCint.mk b/cint/build/libCint.mk index 85646a352fd6d..f3ccbbd1c6c6e 100644 --- a/cint/build/libCint.mk +++ b/cint/build/libCint.mk @@ -4,7 +4,7 @@ ############################################################################ ############################################################################ # -# Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) +# Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) # # For the licensing terms see the file COPYING # diff --git a/cint/build/libReflex.mk b/cint/build/libReflex.mk index d853de7cf92e5..d0db67c7b29f8 100644 --- a/cint/build/libReflex.mk +++ b/cint/build/libReflex.mk @@ -4,7 +4,7 @@ ############################################################################ ############################################################################ # -# Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) +# Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) # # For the licensing terms see the file COPYING # diff --git a/cint/cint/CMakeLists.txt b/cint/cint/CMakeLists.txt index 1c18100352568..38787d1fa097b 100644 --- a/cint/cint/CMakeLists.txt +++ b/cint/cint/CMakeLists.txt @@ -28,7 +28,9 @@ elseif(ROOT_PLATFORM STREQUAL macosx) list(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/libstrm.cxx ) elseif(ROOT_PLATFORM STREQUAL win32) list(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/config/winnt.cxx) - if(VC_MAJOR EQUAL 16) + if(VC_MAJOR EQUAL 17) + list(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/vc11strm.cxx) + elseif(VC_MAJOR EQUAL 16) list(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/vc10strm.cxx) elseif(VC_MAJOR EQUAL 13 AND VC_MINOR EQUAL 10) list(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/vc7strm.cxx) @@ -37,7 +39,6 @@ elseif(ROOT_PLATFORM STREQUAL win32) else() list(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/iccstrm.cxx) endif() - #---TODO the rest of the cases.... endif() #---Add/remove sourcefiles depending on the platform--------------------------------------------------- @@ -89,7 +90,7 @@ add_custom_target(IOSENUM_H COMMAND cmake -E copy ${CMAKE_CURRENT_BINARY_DIR}/iosenum.h ${HEADER_OUTPUT_PATH}/iosenum.h DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/iosenum.h ) -install(FILES ${HEADER_OUTPUT_PATH}/iosenum.h DESTINATION cint/cint/include) +install(FILES ${HEADER_OUTPUT_PATH}/iosenum.h DESTINATION ${CMAKE_INSTALL_CINTINCDIR}/cint/include) set_target_properties(IOSENUM_H PROPERTIES FOLDER Builtins) #---special compile settings------------------------------------------------------------------------------ @@ -129,29 +130,32 @@ add_definitions(-DG__HAVE_CONFIG -DG__NOMAKEINFO -DG__CINTBODY) # TODO: Check if this works on all platforms add_library(Cint_static STATIC ${CINT_SRCS}) add_dependencies(Cint_static IOSENUM_H) +if(WIN32) + set_target_properties(Cint_static PROPERTIES STATIC_LIBRARY_FLAGS -ignore:4221) +endif() #---Create the shared Cint library-------------------------------------------------------------------------- ROOT_LINKER_LIBRARY(Cint loadfile.cxx LIBRARIES Cint_static ${CMAKE_THREAD_LIBS_INIT} ${CMAKE_DL_LIBS}) #---Create the cint cint executable------------------------------------------------------------------------- -ROOT_EXECUTABLE(cint.exe ${CMAKE_CURRENT_SOURCE_DIR}/main/cppmain.cxx LIBRARIES Cint) +ROOT_EXECUTABLE(cint.exe ${CMAKE_CURRENT_SOURCE_DIR}/main/cppmain.cxx LIBRARIES Cint NOINSTALL) #---Create the temporary cint_tmp executable---------------------------------------------------------------- ROOT_EXECUTABLE(cint_tmp ${CMAKE_CURRENT_SOURCE_DIR}/main/cppmain.cxx - ${CMAKE_CURRENT_BINARY_DIR}/loadfile_tmp.cxx LIBRARIES Cint_static ${CMAKE_THREAD_LIBS_INIT} ${CMAKE_DL_LIBS}) + ${CMAKE_CURRENT_BINARY_DIR}/loadfile_tmp.cxx LIBRARIES Cint_static ${CMAKE_THREAD_LIBS_INIT} ${CMAKE_DL_LIBS} NOINSTALL) #---Trick to avoid building all dictionaties when CINT is changed------------------------------------------- add_custom_target(CINTTARGET DEPENDS cint_tmp) #---Create the makecint executable-------------------------------------------------------------------------- -ROOT_EXECUTABLE(makecint ${CMAKE_SOURCE_DIR}/cint/tool/makecint.cxx LIBRARIES ${CMAKE_THREAD_LIBS_INIT}) +ROOT_EXECUTABLE(makecint ${CMAKE_SOURCE_DIR}/cint/tool/makecint.cxx LIBRARIES ${CMAKE_THREAD_LIBS_INIT} NOINSTALL) #---Installation-------------------------------------------------------------------------------------------- ROOT_INSTALL_HEADERS() if(NOT CMAKE_SOURCE_DIR STREQUAL CMAKE_INSTALL_PREFIX) - install(DIRECTORY lib DESTINATION cint/cint PATTERN ".dll" EXCLUDE PATTERN ".svn" EXCLUDE) - install(DIRECTORY include DESTINATION cint/cint PATTERN ".dll" EXCLUDE PATTERN ".svn" EXCLUDE) - install(DIRECTORY stl DESTINATION cint/cint PATTERN ".dll" EXCLUDE PATTERN ".svn" EXCLUDE) + install(DIRECTORY lib DESTINATION ${CMAKE_INSTALL_CINTINCDIR}/cint PATTERN ".dll" EXCLUDE PATTERN ".svn" EXCLUDE) + install(DIRECTORY include DESTINATION ${CMAKE_INSTALL_CINTINCDIR}/cint PATTERN ".dll" EXCLUDE PATTERN ".svn" EXCLUDE) + install(DIRECTORY stl DESTINATION ${CMAKE_INSTALL_CINTINCDIR}/cint PATTERN ".dll" EXCLUDE PATTERN ".svn" EXCLUDE) endif() diff --git a/cint/cint/Module.mk b/cint/cint/Module.mk index b01d24f2362b9..32f9e6bcda45e 100644 --- a/cint/cint/Module.mk +++ b/cint/cint/Module.mk @@ -119,18 +119,22 @@ CINTS2 += $(MODDIRSD)/fakestrm.cxx endif ifeq ($(PLATFORM),win32) CINTS2 += $(MODDIRS)/config/winnt.cxx -ifeq ($(VC_MAJOR),16) - CINTS2 += $(MODDIRSD)/vc10strm.cxx +ifeq ($(VC_MAJOR),17) + CINTS2 += $(MODDIRSD)/vc11strm.cxx else - ifeq ($(VC_MAJOR).$(VC_MINOR),13.10) - CINTS2 += $(MODDIRSD)/vc7strm.cxx - else - ifeq ($(find $(VC_MAJOR),13 12 11 10 9 8 7 6 5 4 3 2 1),) - CINTS2 += $(MODDIRSD)/vc7strm.cxx + ifeq ($(VC_MAJOR),16) + CINTS2 += $(MODDIRSD)/vc10strm.cxx else - CINTS2 += $(MODDIRSD)/iccstrm.cxx + ifeq ($(VC_MAJOR).$(VC_MINOR),13.10) + CINTS2 += $(MODDIRSD)/vc7strm.cxx + else + ifeq ($(find $(VC_MAJOR),13 12 11 10 9 8 7 6 5 4 3 2 1),) + CINTS2 += $(MODDIRSD)/vc7strm.cxx + else + CINTS2 += $(MODDIRSD)/iccstrm.cxx + endif + endif endif - endif endif endif ifeq ($(CXXCMD),icc) @@ -153,17 +157,13 @@ ifeq ($(GCC_MAJOR),4) CINTS2 := $(filter-out $(MODDIRSD)/libstrm.%,$(CINTS2)) CINTS2 += $(MODDIRSD)/gcc4strm.cxx endif -ifeq ($(CLANG_MAJOR),2) -CINTS2 := $(filter-out $(MODDIRSD)/libstrm.%,$(CINTS2)) -CINTS2 += $(MODDIRSD)/gcc4strm.cxx -endif -ifeq ($(CLANG_MAJOR),3) +ifneq ($(CLANG_MAJOR),) CINTS2 := $(filter-out $(MODDIRSD)/libstrm.%,$(CINTS2)) CINTS2 += $(MODDIRSD)/gcc4strm.cxx endif -ifeq ($(CLANG_MAJOR),4) -CINTS2 := $(filter-out $(MODDIRSD)/libstrm.%,$(CINTS2)) -CINTS2 += $(MODDIRSD)/gcc4strm.cxx +ifeq ($(LIBCXX),yes) +CINTS2 := $(filter-out $(MODDIRSD)/gcc4strm.%,$(CINTS2)) +CINTS2 += $(MODDIRSD)/libcxxstrm.cxx endif ifeq ($(CXXCMD),xlC) ifeq ($(PLATFORM),macosx) @@ -196,13 +196,7 @@ MAKECINT := bin/makecint$(EXEEXT) ##### iosenum.h ##### IOSENUM := $(call stripsrc,$(MODDIR)/include/iosenum.h) IOSENUMC := $(CINTDIRIOSEN)/iosenum.cxx -ifeq ($(CLANG_MAJOR),4) -IOSENUMA := $(CINTDIRIOSEN)/iosenum.$(ARCH)3 -else -ifeq ($(CLANG_MAJOR),3) -IOSENUMA := $(CINTDIRIOSEN)/iosenum.$(ARCH)3 -else -ifeq ($(CLANG_MAJOR),2) +ifneq ($(CLANG_MAJOR),) IOSENUMA := $(CINTDIRIOSEN)/iosenum.$(ARCH)3 else ifeq ($(GCC_MAJOR),4) @@ -215,11 +209,9 @@ IOSENUMA := $(CINTDIRIOSEN)/iosenum.$(ARCH) endif endif endif -endif -endif # used in the main Makefile -ALLHDRS += $(CINTHT) +ALLHDRS += $(CINTHT) $(CINTINCLUDES) CINTSIZEFLAGS := ifneq ($(CINTMAXSTRUCT),) @@ -273,12 +265,15 @@ include/%.h: $(CINTDIRI)/%.h ifneq ($(ROOT_OBJDIR),$(ROOT_SRCDIR)) $(CINTDIRL): + $(MAKEDIR) @$(RSYNC) --exclude '.svn' --exclude '*.o' --exclude '*.d' --exclude 'rootcint_*' --exclude 'G__cpp_*' --exclude 'G__c_*' --exclude 'mktypes' --exclude '*.dSYM' $(CINTDIR)/lib $(dir $@) @touch $(CINTDIRL) -$(CINTDIRDLLS): +$(CINTDIRDLLS): $(CINTDIRL) + $(MAKEDIR) @$(RSYNC) --exclude '.svn' --exclude '*.o' --exclude '*.d' --exclude '*.dll' --exclude 'systypes.h' --exclude 'types.h' $(CINTDIR)/include $(dir $@) @touch $(CINTDIRDLLS) -$(CINTDIRSTL): +$(CINTDIRSTL): $(CINTDIRL) + $(MAKEDIR) @$(RSYNC) --exclude '.svn' --exclude '*.o' --exclude '*.d' --exclude '*.dll' $(CINTDIR)/stl $(dir $@) @touch $(CINTDIRSTL) endif @@ -301,15 +296,17 @@ $(MAKECINT): $(MAKECINTO) $(IOSENUM): $(MAKEDIR) @(if [ ! -r $(IOSENUMA) ]; then \ - echo "Missing $(IOSENUMA), run: make $IOSENUMA)"; \ - else \ - cp $(IOSENUMA) $@; \ - fi) + echo "Missing $(IOSENUMA), run: make $(IOSENUMA)"; \ + $(MAKE) $(IOSENUMA); \ + fi; \ + cp $(IOSENUMA) $@) $(IOSENUMA): $(CINTTMP) @(if [ ! -r $@ ]; then \ echo "Making $@..."; \ - $(CINTTMP) $(CINTTMPINC) -Iinclude $(IOSENUMC) > /dev/null; \ + $(CINTTMP) $(CINTTMPINC) \ + -I$(ROOT_SRCDIR)/cint/cint/inc -Iinclude \ + $(IOSENUMC) > /dev/null; \ mv iosenum.h $@; \ else \ touch $@; \ @@ -355,6 +352,10 @@ $(call stripsrc,$(CINTDIRS)/loadfile_tmp.o): $(CINTCONF) $(ORDER_) $(CINTINCLUDE $(call stripsrc,$(CINTDIRS)/loadfile_tmp.o): CINTCXXFLAGS += -UR__HAVE_CONFIG -DROOTBUILD $(call stripsrc,$(CINTDIRS)/loadfile_tmp.o) $(CINTO): OPT := $(filter-out -Wshadow,$(OPT)) $(call stripsrc,$(CINTDIRS)/loadfile_tmp.o) $(CINTO): CXXFLAGS:=$(filter-out -Wshadow,$(CXXFLAGS)) +ifeq ($(MACOSX_TMPNAM_DEPRECATED),yes) +$(call stripsrc,$(CINTDIRS)/loadfile_tmp.o) $(CINTO): CINTCXXFLAGS += -Wno-deprecated-declarations +$(call stripsrc,$(CINTDIRS)/loadfile_tmp.o) $(CINTO): CINTCFLAGS += -Wno-deprecated-declarations +endif $(call stripsrc,$(CINTDIRSD)/stdstrct.o): CINTCXXFLAGS += -I$(CINTDIRL)/stdstrct diff --git a/cint/cint/PlatformDependentSettings.cmake b/cint/cint/PlatformDependentSettings.cmake index 7628b2f892f45..148c95152add7 100644 --- a/cint/cint/PlatformDependentSettings.cmake +++ b/cint/cint/PlatformDependentSettings.cmake @@ -81,20 +81,18 @@ if(ROOT_PLATFORM MATCHES "vms") LIST(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/fakestrm.cxx) endif(ROOT_PLATFORM MATCHES "vms") -if (CMAKE_C_COMPILER MATCHES "icc") - LIST(REMOVE_ITEM CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/libstrm.cxx ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/longif.cxx) - #TODO check compiler version - If(ICC_GE_9 GREATER 8) - If(ICC_GE_101 GREATER 100) - LIST(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/gcc4strm.cxx) - Else(ICC_GE_101 GREATER 100) - LIST(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/gcc3strm.cxx) - EndIf(ICC_GE_101 GREATER 100) - Else(ICC_GE_9 GREATER 8) - LIST(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/iccstrm.cxx) - EndIf(ICC_GE_9 GREATER 8) - #LIST(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/longif3.cxx) -endif (CMAKE_C_COMPILER MATCHES "icc") +if(CMAKE_CXX_COMPILER_ID MATCHES Intel) + list(REMOVE_ITEM CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/libstrm.cxx ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/longif.cxx) + if(ICC_MAJOR GREATER 8) + if(ICC_MAJOR GREATER 10) + list(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/gcc4strm.cxx) + else() + list(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/gcc3strm.cxx) + endif() + else() + list(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/iccstrm.cxx) + endif() +endif() IF(${GCC_MAJOR} EQUAL 3) LIST(REMOVE_ITEM CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/libstrm.cxx ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/longif.cxx) @@ -116,6 +114,12 @@ IF(${CLANG_MAJOR} EQUAL 3) LIST(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/gcc4strm.cxx) ENDIF() +IF(libcxx) + LIST(REMOVE_ITEM CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/gcc4strm.cxx ) + LIST(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/libcxxstrm.cxx) +ENDIF() + + if (CMAKE_C_COMPILER MATCHES "xlC") LIST(REMOVE_ITEM CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/libstrm.cxx ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/longif.cxx) LIST(APPEND CINT_CXX_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/longif3.cxx ${CMAKE_CURRENT_SOURCE_DIR}/src/dict/gcc3strm.cxx) diff --git a/cint/cint/inc/G__ci.h b/cint/cint/inc/G__ci.h index b0434129dcf0d..37269152b5e0a 100644 --- a/cint/cint/inc/G__ci.h +++ b/cint/cint/inc/G__ci.h @@ -7,7 +7,7 @@ * Description: * C/C++ interpreter header file ************************************************************************ - * Copyright(c) 1995~2007 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2007 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -963,7 +963,7 @@ typedef struct { long ref; #endif #if defined(G__PRIVATE_GVALUE) && !defined(_WIN32) -private: + /*private:*/ #if defined(G__alt_private) && defined(ROOT_RVersion) #define private public #endif diff --git a/cint/cint/inc/G__ci_fproto.h b/cint/cint/inc/G__ci_fproto.h index 2319104d28b39..cd30f5fe00ee5 100644 --- a/cint/cint/inc/G__ci_fproto.h +++ b/cint/cint/inc/G__ci_fproto.h @@ -7,7 +7,7 @@ * Description: * C/C++ interpreter header file for API function prototypes ************************************************************************ - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/inc/cintdictversion.h b/cint/cint/inc/cintdictversion.h index 631bfdbdc4212..8870ea60bedab 100644 --- a/cint/cint/inc/cintdictversion.h +++ b/cint/cint/inc/cintdictversion.h @@ -6,7 +6,7 @@ * Description: * definition of the dictionary API version ************************************************************************ - * Copyright(c) 1995~2008 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2008 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/Common.h b/cint/cint/include/Common.h index 8f8ad3fa7641f..1b10821176daf 100644 --- a/cint/cint/include/Common.h +++ b/cint/cint/include/Common.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/GL/gl.h b/cint/cint/include/GL/gl.h index f1a25d2925bc6..2ffa41b0a7684 100644 --- a/cint/cint/include/GL/gl.h +++ b/cint/cint/include/GL/gl.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/GL/glu.h b/cint/cint/include/GL/glu.h index 6787ec5bc8744..105b86e59d34c 100644 --- a/cint/cint/include/GL/glu.h +++ b/cint/cint/include/GL/glu.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/GL/glut.h b/cint/cint/include/GL/glut.h index f98fa0330d7f5..ab907fd993b14 100644 --- a/cint/cint/include/GL/glut.h +++ b/cint/cint/include/GL/glut.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/GL/xmesa.h b/cint/cint/include/GL/xmesa.h index 6787ec5bc8744..105b86e59d34c 100644 --- a/cint/cint/include/GL/xmesa.h +++ b/cint/cint/include/GL/xmesa.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/RegE.C b/cint/cint/include/RegE.C index 15f35bca33a27..eacd53c7399b1 100644 --- a/cint/cint/include/RegE.C +++ b/cint/cint/include/RegE.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/RegE.cxx b/cint/cint/include/RegE.cxx index 15f35bca33a27..eacd53c7399b1 100644 --- a/cint/cint/include/RegE.cxx +++ b/cint/cint/include/RegE.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/RegE.h b/cint/cint/include/RegE.h index 235db416d1711..05d853665ef36 100644 --- a/cint/cint/include/RegE.h +++ b/cint/cint/include/RegE.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/X11/Xlib.h b/cint/cint/include/X11/Xlib.h index d9c631c24e01d..2d29d866ea2e3 100644 --- a/cint/cint/include/X11/Xlib.h +++ b/cint/cint/include/X11/Xlib.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/X11/Xutil.h b/cint/cint/include/X11/Xutil.h index 1e6e75009e7a3..b51c2581c3b10 100644 --- a/cint/cint/include/X11/Xutil.h +++ b/cint/cint/include/X11/Xutil.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/X11/keysym.h b/cint/cint/include/X11/keysym.h index 9b595698f727b..61b7c2ef6f217 100644 --- a/cint/cint/include/X11/keysym.h +++ b/cint/cint/include/X11/keysym.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/X11/xos.h b/cint/cint/include/X11/xos.h index 1e6e75009e7a3..b51c2581c3b10 100644 --- a/cint/cint/include/X11/xos.h +++ b/cint/cint/include/X11/xos.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/_complex b/cint/cint/include/_complex index 1e56ee2538565..231a4b97fbe51 100644 --- a/cint/cint/include/_complex +++ b/cint/cint/include/_complex @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/_complex.h b/cint/cint/include/_complex.h index 0f7f2345fc8f9..86e64ebfd817a 100644 --- a/cint/cint/include/_complex.h +++ b/cint/cint/include/_complex.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/_exception b/cint/cint/include/_exception index 7c679cc98f171..d4064a056b3ce 100644 --- a/cint/cint/include/_exception +++ b/cint/cint/include/_exception @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/_exception.h b/cint/cint/include/_exception.h index 21df4754fe5ec..622a985094d17 100644 --- a/cint/cint/include/_exception.h +++ b/cint/cint/include/_exception.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/_iostream b/cint/cint/include/_iostream index 9b921b3d53328..74e5e9ea54f69 100644 --- a/cint/cint/include/_iostream +++ b/cint/cint/include/_iostream @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/_stdexcept b/cint/cint/include/_stdexcept index 5cd85943d3da9..ada4f162e5d3f 100644 --- a/cint/cint/include/_stdexcept +++ b/cint/cint/include/_stdexcept @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/_stdexcept.h b/cint/cint/include/_stdexcept.h index bf1d8c7862a3c..e975b4fd03d5b 100644 --- a/cint/cint/include/_stdexcept.h +++ b/cint/cint/include/_stdexcept.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/api.h b/cint/cint/include/api.h index e4f9964a178e8..c0413d8e391a2 100644 --- a/cint/cint/include/api.h +++ b/cint/cint/include/api.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/array.c b/cint/cint/include/array.c index eb4ffa13025d3..1c141c1ca2e56 100644 --- a/cint/cint/include/array.c +++ b/cint/cint/include/array.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/array.h b/cint/cint/include/array.h index c96dc739c7035..8ddda5c97c438 100644 --- a/cint/cint/include/array.h +++ b/cint/cint/include/array.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/arrayiostream.h b/cint/cint/include/arrayiostream.h index fd8e5b87f72b9..2363b83791cb9 100644 --- a/cint/cint/include/arrayiostream.h +++ b/cint/cint/include/arrayiostream.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/assert.h b/cint/cint/include/assert.h index 68feb1e4f8a73..07f577dd5ec26 100644 --- a/cint/cint/include/assert.h +++ b/cint/cint/include/assert.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/bool b/cint/cint/include/bool index a5844699bfc1a..2d525741b5c2b 100644 --- a/cint/cint/include/bool +++ b/cint/cint/include/bool @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/bool.h b/cint/cint/include/bool.h index 18946e6c03085..525566f33e28a 100644 --- a/cint/cint/include/bool.h +++ b/cint/cint/include/bool.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/boolean.h b/cint/cint/include/boolean.h index b5ee92a3bf6d8..46eea4a95bff9 100644 --- a/cint/cint/include/boolean.h +++ b/cint/cint/include/boolean.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/carray.c b/cint/cint/include/carray.c index b337745881310..81289ad54d6bc 100644 --- a/cint/cint/include/carray.c +++ b/cint/cint/include/carray.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/carray.h b/cint/cint/include/carray.h index 13bd73fdb736c..ae591ec83ddf2 100644 --- a/cint/cint/include/carray.h +++ b/cint/cint/include/carray.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/cassert b/cint/cint/include/cassert index 2f05dd8005fed..8a69a0c56907b 100644 --- a/cint/cint/include/cassert +++ b/cint/cint/include/cassert @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/cctype b/cint/cint/include/cctype index a19e25e0a5940..cf7e8f342080c 100644 --- a/cint/cint/include/cctype +++ b/cint/cint/include/cctype @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/cerrno b/cint/cint/include/cerrno index 95a523befc1f7..b0fd52f5bfb62 100644 --- a/cint/cint/include/cerrno +++ b/cint/cint/include/cerrno @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/cfloat b/cint/cint/include/cfloat index ac5591192c0b9..ec8bbe5c4abaf 100644 --- a/cint/cint/include/cfloat +++ b/cint/cint/include/cfloat @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/ciso646 b/cint/cint/include/ciso646 index a21b62350e2f8..ab2b9d4f750b7 100644 --- a/cint/cint/include/ciso646 +++ b/cint/cint/include/ciso646 @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/climits b/cint/cint/include/climits index 68b3f5ff5b3aa..6a51e10fa184c 100644 --- a/cint/cint/include/climits +++ b/cint/cint/include/climits @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/clocale b/cint/cint/include/clocale index 670da50a9c62b..b53f61b2994ca 100644 --- a/cint/cint/include/clocale +++ b/cint/cint/include/clocale @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/cmath b/cint/cint/include/cmath index 76ef07e786820..acd8582a7bd93 100644 --- a/cint/cint/include/cmath +++ b/cint/cint/include/cmath @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/complex b/cint/cint/include/complex index 6b5a75cc92708..1e4737fd3da12 100644 --- a/cint/cint/include/complex +++ b/cint/cint/include/complex @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/complex.h b/cint/cint/include/complex.h index 09d3daa440c4f..168a3a7db5aab 100644 --- a/cint/cint/include/complex.h +++ b/cint/cint/include/complex.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/constants.h b/cint/cint/include/constants.h index 4ea31bdcb5871..d431c997d4ff4 100644 --- a/cint/cint/include/constants.h +++ b/cint/cint/include/constants.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/csetjmp b/cint/cint/include/csetjmp index 97772764a6706..4593904526dfd 100644 --- a/cint/cint/include/csetjmp +++ b/cint/cint/include/csetjmp @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/csignal b/cint/cint/include/csignal index c21d951c3f0d7..7b601a5465703 100644 --- a/cint/cint/include/csignal +++ b/cint/cint/include/csignal @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/cstdarg b/cint/cint/include/cstdarg index 76d2d140a10ad..13b61380aa027 100644 --- a/cint/cint/include/cstdarg +++ b/cint/cint/include/cstdarg @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/cstddef b/cint/cint/include/cstddef index 7b3544536aed7..3fa633335ff1a 100644 --- a/cint/cint/include/cstddef +++ b/cint/cint/include/cstddef @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/cstdio b/cint/cint/include/cstdio index c5fbf35a7c106..448bc41889f03 100644 --- a/cint/cint/include/cstdio +++ b/cint/cint/include/cstdio @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/cstdlib b/cint/cint/include/cstdlib index 0cac915da323a..c28185e7daeff 100644 --- a/cint/cint/include/cstdlib +++ b/cint/cint/include/cstdlib @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/cstring b/cint/cint/include/cstring index 37cf9395a5c31..98abed128c056 100644 --- a/cint/cint/include/cstring +++ b/cint/cint/include/cstring @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/ctime b/cint/cint/include/ctime index 7c218a8abe5f0..11b01f9427679 100644 --- a/cint/cint/include/ctime +++ b/cint/cint/include/ctime @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/ctype.h b/cint/cint/include/ctype.h index 507e68cc38a62..7a3de27cdacb1 100644 --- a/cint/cint/include/ctype.h +++ b/cint/cint/include/ctype.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/cwchar b/cint/cint/include/cwchar index e0ab002a93183..545359bd14855 100644 --- a/cint/cint/include/cwchar +++ b/cint/cint/include/cwchar @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/cwctype b/cint/cint/include/cwctype index 7fb23fbbde24e..e96564e991e50 100644 --- a/cint/cint/include/cwctype +++ b/cint/cint/include/cwctype @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/darray.cxx b/cint/cint/include/darray.cxx index 9006cadc19dd5..26d5a9bf88eef 100644 --- a/cint/cint/include/darray.cxx +++ b/cint/cint/include/darray.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/darray.h b/cint/cint/include/darray.h index 4ce85d6267cc3..05701726ad614 100644 --- a/cint/cint/include/darray.h +++ b/cint/cint/include/darray.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/ertti.h b/cint/cint/include/ertti.h index 431632311d82a..b42bef2a1287e 100644 --- a/cint/cint/include/ertti.h +++ b/cint/cint/include/ertti.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/exception b/cint/cint/include/exception index 0dcbcc2c45482..ec994514d98f3 100644 --- a/cint/cint/include/exception +++ b/cint/cint/include/exception @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/exception.h b/cint/cint/include/exception.h index c03842a5d6e6c..759f5cd269736 100644 --- a/cint/cint/include/exception.h +++ b/cint/cint/include/exception.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/fcntl.h b/cint/cint/include/fcntl.h index 3552797ed3a25..094104ddfa03e 100644 --- a/cint/cint/include/fcntl.h +++ b/cint/cint/include/fcntl.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/fft.c b/cint/cint/include/fft.c index 97897aaa1a70b..5ddf38b5029e3 100644 --- a/cint/cint/include/fft.c +++ b/cint/cint/include/fft.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/fft.h b/cint/cint/include/fft.h index 8f0a5c1046981..540955eed4a95 100644 --- a/cint/cint/include/fft.h +++ b/cint/cint/include/fft.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/fstream b/cint/cint/include/fstream index 14250acb93360..83662902456f4 100644 --- a/cint/cint/include/fstream +++ b/cint/cint/include/fstream @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/fstream.h b/cint/cint/include/fstream.h index 90a552e64f616..47077c5dc3cc3 100644 --- a/cint/cint/include/fstream.h +++ b/cint/cint/include/fstream.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/graphbuf.h b/cint/cint/include/graphbuf.h index b1b6e4fa1ac62..63f638ca7fd22 100644 --- a/cint/cint/include/graphbuf.h +++ b/cint/cint/include/graphbuf.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -391,7 +391,7 @@ graphbuf& graphbuf::operator >>(ISLOG log) return(*this); } -// reset ouput pointer +// reset output pointer graphbuf& graphbuf::operator >>(char *s) { pout=0; diff --git a/cint/cint/include/iomanip b/cint/cint/include/iomanip index c2513a6c2516a..5e0ebbe1ff021 100644 --- a/cint/cint/include/iomanip +++ b/cint/cint/include/iomanip @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/iomanip.h b/cint/cint/include/iomanip.h index 7218eb3f688f9..35e33ebf4a7b0 100644 --- a/cint/cint/include/iomanip.h +++ b/cint/cint/include/iomanip.h @@ -8,7 +8,7 @@ * CINT IOMANIP header file ************************************************************************ * Author Masaharu Goto - * Copyright(c) 1995~1999 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~1999 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/iosenum.cxx b/cint/cint/include/iosenum.cxx index 8601dfa74f25c..cc3419849f460 100644 --- a/cint/cint/include/iosenum.cxx +++ b/cint/cint/include/iosenum.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/iosfwd b/cint/cint/include/iosfwd index 3e2bd22903c81..0a2b3669d3f2d 100644 --- a/cint/cint/include/iosfwd +++ b/cint/cint/include/iosfwd @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/iosfwd.h b/cint/cint/include/iosfwd.h index 2c2a558f3f562..b914687bbc0e0 100644 --- a/cint/cint/include/iosfwd.h +++ b/cint/cint/include/iosfwd.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/iostream b/cint/cint/include/iostream index 55649e91a6f69..3a7676f4e03e5 100644 --- a/cint/cint/include/iostream +++ b/cint/cint/include/iostream @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/istream b/cint/cint/include/istream index 1aac826b5696d..d523d3be9f112 100644 --- a/cint/cint/include/istream +++ b/cint/cint/include/istream @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/limits b/cint/cint/include/limits index 29347a0735b44..fff0f8a7dacc6 100644 --- a/cint/cint/include/limits +++ b/cint/cint/include/limits @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/locale b/cint/cint/include/locale index 87020c411c8dd..27013a7e3c225 100644 --- a/cint/cint/include/locale +++ b/cint/cint/include/locale @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/lsm.c b/cint/cint/include/lsm.c index 0e278e273d8c2..6a950d0061e60 100644 --- a/cint/cint/include/lsm.c +++ b/cint/cint/include/lsm.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/lsm.h b/cint/cint/include/lsm.h index cb4c98ac53f2c..d61d7a122c758 100644 --- a/cint/cint/include/lsm.h +++ b/cint/cint/include/lsm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/makearc b/cint/cint/include/makearc index 48cefea8cb4dd..af663944e19d0 100644 --- a/cint/cint/include/makearc +++ b/cint/cint/include/makearc @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/makearcg b/cint/cint/include/makearcg index f7f14e4ad431a..1e3cc2b75709b 100644 --- a/cint/cint/include/makearcg +++ b/cint/cint/include/makearcg @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/makearcsun b/cint/cint/include/makearcsun index b8fe28663c25d..07e571bdba8f1 100644 --- a/cint/cint/include/makearcsun +++ b/cint/cint/include/makearcsun @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/makefile b/cint/cint/include/makefile index a6c5df96770f3..9460b0e0a8175 100644 --- a/cint/cint/include/makefile +++ b/cint/cint/include/makefile @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/makehpib b/cint/cint/include/makehpib index 8238636bed908..568a5fd0419d3 100755 --- a/cint/cint/include/makehpib +++ b/cint/cint/include/makehpib @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/makeit.c b/cint/cint/include/makeit.c index 761502a41ee15..2381904fc1d1b 100644 --- a/cint/cint/include/makeit.c +++ b/cint/cint/include/makeit.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/makemat b/cint/cint/include/makemat index d3db573af2648..4192b646a844a 100644 --- a/cint/cint/include/makemat +++ b/cint/cint/include/makemat @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/matrix.cxx b/cint/cint/include/matrix.cxx index 010fbd32969a5..b4efe5ff0f8ab 100644 --- a/cint/cint/include/matrix.cxx +++ b/cint/cint/include/matrix.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/matrix.h b/cint/cint/include/matrix.h index 9c1ecbb85d819..3176150931fb2 100644 --- a/cint/cint/include/matrix.h +++ b/cint/cint/include/matrix.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/matrixstream.h b/cint/cint/include/matrixstream.h index 74db70f548dce..2ea7f430e4476 100644 --- a/cint/cint/include/matrixstream.h +++ b/cint/cint/include/matrixstream.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/mkincld.c b/cint/cint/include/mkincld.c index c125039ad403d..ba44c63da4e85 100644 --- a/cint/cint/include/mkincld.c +++ b/cint/cint/include/mkincld.c @@ -8,7 +8,7 @@ * Create standard include files at cint installation ************************************************************************ * Author Masaharu Goto - * Copyright(c) 1995~1999 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~1999 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/new b/cint/cint/include/new index c2aa2537114a2..d6d40bb094815 100644 --- a/cint/cint/include/new +++ b/cint/cint/include/new @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/new.h b/cint/cint/include/new.h index b324d2017e65f..6e7bb8ece074c 100644 --- a/cint/cint/include/new.h +++ b/cint/cint/include/new.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/ostream b/cint/cint/include/ostream index 1aac826b5696d..d523d3be9f112 100644 --- a/cint/cint/include/ostream +++ b/cint/cint/include/ostream @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/platform.h b/cint/cint/include/platform.h index c1297b56263d5..e0e2765718910 100644 --- a/cint/cint/include/platform.h +++ b/cint/cint/include/platform.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/pthread.h b/cint/cint/include/pthread.h index cc05da8d94104..0af9d888ffd96 100644 --- a/cint/cint/include/pthread.h +++ b/cint/cint/include/pthread.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/readfile.h b/cint/cint/include/readfile.h index 63bff83a6e20e..f166df349aaa6 100644 --- a/cint/cint/include/readfile.h +++ b/cint/cint/include/readfile.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/regex.h b/cint/cint/include/regex.h index d8da80b093f90..300329565d9a7 100644 --- a/cint/cint/include/regex.h +++ b/cint/cint/include/regex.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/regexp.h b/cint/cint/include/regexp.h index ff3bd4abb4642..4db3157ea6957 100644 --- a/cint/cint/include/regexp.h +++ b/cint/cint/include/regexp.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/setjmp.h b/cint/cint/include/setjmp.h index 4f9b2d1b84ad1..0f8a91a1395c6 100644 --- a/cint/cint/include/setjmp.h +++ b/cint/cint/include/setjmp.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/socket.h b/cint/cint/include/socket.h index 2d6e7677daae2..fb0458306bb7d 100644 --- a/cint/cint/include/socket.h +++ b/cint/cint/include/socket.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/spice.h b/cint/cint/include/spice.h index 222250d2355e3..f56c56a939b9a 100644 --- a/cint/cint/include/spice.h +++ b/cint/cint/include/spice.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/sstream b/cint/cint/include/sstream index 9e5909f7d2e34..6533017b6b401 100644 --- a/cint/cint/include/sstream +++ b/cint/cint/include/sstream @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/statistics.c b/cint/cint/include/statistics.c index 2a1aa6abc1434..4cfd29ab98968 100644 --- a/cint/cint/include/statistics.c +++ b/cint/cint/include/statistics.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/statistics.h b/cint/cint/include/statistics.h index dbadb46abc363..69665b8a663e1 100644 --- a/cint/cint/include/statistics.h +++ b/cint/cint/include/statistics.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/stdarg.h b/cint/cint/include/stdarg.h index e9d65e34e8a30..4bb8f3df5ed4a 100644 --- a/cint/cint/include/stdarg.h +++ b/cint/cint/include/stdarg.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/stdexcept b/cint/cint/include/stdexcept index 9046437d8cbf7..14fc1e53b8703 100644 --- a/cint/cint/include/stdexcept +++ b/cint/cint/include/stdexcept @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/stdiostream.h b/cint/cint/include/stdiostream.h index 2a311425a9e10..fb8a41420e86e 100644 --- a/cint/cint/include/stdiostream.h +++ b/cint/cint/include/stdiostream.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/stream.h b/cint/cint/include/stream.h index 4cbb3035a8584..a6f7435108d0b 100644 --- a/cint/cint/include/stream.h +++ b/cint/cint/include/stream.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/streambuf b/cint/cint/include/streambuf index a4d1e3638a89e..7f373619fdac1 100644 --- a/cint/cint/include/streambuf +++ b/cint/cint/include/streambuf @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/string.h b/cint/cint/include/string.h index 55dfd97c87609..712bf0cb19ab7 100644 --- a/cint/cint/include/string.h +++ b/cint/cint/include/string.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/striostream.h b/cint/cint/include/striostream.h index 2a311425a9e10..fb8a41420e86e 100644 --- a/cint/cint/include/striostream.h +++ b/cint/cint/include/striostream.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/strstream b/cint/cint/include/strstream index 2d8cced3cb8d4..dba61ebd734cb 100644 --- a/cint/cint/include/strstream +++ b/cint/cint/include/strstream @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/strstream.h b/cint/cint/include/strstream.h index 8f48edb96ab08..9f023099bb456 100644 --- a/cint/cint/include/strstream.h +++ b/cint/cint/include/strstream.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/sys/cdefs.h b/cint/cint/include/sys/cdefs.h index 2cc9776cbd3b7..6ce8d6057869c 100644 --- a/cint/cint/include/sys/cdefs.h +++ b/cint/cint/include/sys/cdefs.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/sys/file.h b/cint/cint/include/sys/file.h index e85f50911f168..b398ed83d4c52 100644 --- a/cint/cint/include/sys/file.h +++ b/cint/cint/include/sys/file.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/sys/ipc.h b/cint/cint/include/sys/ipc.h index 9bb3fb75cb1f0..1bc45306f4541 100644 --- a/cint/cint/include/sys/ipc.h +++ b/cint/cint/include/sys/ipc.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/sys/msg.h b/cint/cint/include/sys/msg.h index 06701fafe59d4..797f050b38818 100644 --- a/cint/cint/include/sys/msg.h +++ b/cint/cint/include/sys/msg.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/sys/sem.h b/cint/cint/include/sys/sem.h index b49063099d622..2f37d999a5baf 100644 --- a/cint/cint/include/sys/sem.h +++ b/cint/cint/include/sys/sem.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/sys/shm.h b/cint/cint/include/sys/shm.h index b49063099d622..2f37d999a5baf 100644 --- a/cint/cint/include/sys/shm.h +++ b/cint/cint/include/sys/shm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/sys/stat.h b/cint/cint/include/sys/stat.h index a85db6592be4f..dc8c1252e2057 100644 --- a/cint/cint/include/sys/stat.h +++ b/cint/cint/include/sys/stat.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/termios.h b/cint/cint/include/termios.h index b8e32b2fb1755..81da5803b297a 100644 --- a/cint/cint/include/termios.h +++ b/cint/cint/include/termios.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/timespec.h b/cint/cint/include/timespec.h index 88de9d0327d7b..a85aa669cef17 100644 --- a/cint/cint/include/timespec.h +++ b/cint/cint/include/timespec.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/typeinfo b/cint/cint/include/typeinfo index 92682cbe4d9e7..c1821be3b03f6 100644 --- a/cint/cint/include/typeinfo +++ b/cint/cint/include/typeinfo @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/typeinfo.h b/cint/cint/include/typeinfo.h index ba8968a87931c..cb4217f9a778d 100644 --- a/cint/cint/include/typeinfo.h +++ b/cint/cint/include/typeinfo.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/unistd.h b/cint/cint/include/unistd.h index 4d1366ef59f6e..079f03569281f 100644 --- a/cint/cint/include/unistd.h +++ b/cint/cint/include/unistd.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/windows.h b/cint/cint/include/windows.h index cb1b9b7e7de4e..e1c2b5e64c1fc 100644 --- a/cint/cint/include/windows.h +++ b/cint/cint/include/windows.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/winsock.h b/cint/cint/include/winsock.h index 444eb9aee285e..d37b5b70f86b3 100644 --- a/cint/cint/include/winsock.h +++ b/cint/cint/include/winsock.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/xgraph.c b/cint/cint/include/xgraph.c index 9ae04bf2b2244..cf8c7a2ddef36 100644 --- a/cint/cint/include/xgraph.c +++ b/cint/cint/include/xgraph.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/include/xygraphbuf.h b/cint/cint/include/xygraphbuf.h index 4ed1471c03fc9..8adbcb5167fcb 100644 --- a/cint/cint/include/xygraphbuf.h +++ b/cint/cint/include/xygraphbuf.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/WildCard/AppInit.c b/cint/cint/lib/WildCard/AppInit.c index 3cc373b9a00b7..fee3564b6ba61 100644 --- a/cint/cint/lib/WildCard/AppInit.c +++ b/cint/cint/lib/WildCard/AppInit.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/WildCard/TkInit.c b/cint/cint/lib/WildCard/TkInit.c index 0e88f4d7a4483..67a84a714a8b1 100644 --- a/cint/cint/lib/WildCard/TkInit.c +++ b/cint/cint/lib/WildCard/TkInit.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/WildCard/test.c b/cint/cint/lib/WildCard/test.c index c32b6d2dcf1b1..b9c10e7d594c5 100644 --- a/cint/cint/lib/WildCard/test.c +++ b/cint/cint/lib/WildCard/test.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/WildCard/tktest.c b/cint/cint/lib/WildCard/tktest.c index 7199140566a51..ce9413d740e83 100644 --- a/cint/cint/lib/WildCard/tktest.c +++ b/cint/cint/lib/WildCard/tktest.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/WildCard/tktest1.c b/cint/cint/lib/WildCard/tktest1.c index f8c873b28383e..396579a5352b3 100644 --- a/cint/cint/lib/WildCard/tktest1.c +++ b/cint/cint/lib/WildCard/tktest1.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/WildCard/tktest2.c b/cint/cint/lib/WildCard/tktest2.c index 3c8fb2a7274f2..879272af257ef 100644 --- a/cint/cint/lib/WildCard/tktest2.c +++ b/cint/cint/lib/WildCard/tktest2.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/accstrm/linkdef.h b/cint/cint/lib/accstrm/linkdef.h index 59a3e3bb430b5..fdfa89851d075 100644 --- a/cint/cint/lib/accstrm/linkdef.h +++ b/cint/cint/lib/accstrm/linkdef.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/alphastrm/linkdef.h b/cint/cint/lib/alphastrm/linkdef.h index 9ff0dace338c0..074ed48996084 100644 --- a/cint/cint/lib/alphastrm/linkdef.h +++ b/cint/cint/lib/alphastrm/linkdef.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/cbstream/linkdef.h b/cint/cint/lib/cbstream/linkdef.h index 55c7e4bc075be..c5477ad0be75f 100644 --- a/cint/cint/lib/cbstream/linkdef.h +++ b/cint/cint/lib/cbstream/linkdef.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/cinteh.h b/cint/cint/lib/dll_stl/cinteh.h index 720e3859e66a8..526e2f87617f3 100644 --- a/cint/cint/lib/dll_stl/cinteh.h +++ b/cint/cint/lib/dll_stl/cinteh.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/clim.h b/cint/cint/lib/dll_stl/clim.h index 4ee3101fad1a0..0f96d0b7ba523 100644 --- a/cint/cint/lib/dll_stl/clim.h +++ b/cint/cint/lib/dll_stl/clim.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/cmplx.h b/cint/cint/lib/dll_stl/cmplx.h index b9712c8cf961f..6d82ce1525569 100644 --- a/cint/cint/lib/dll_stl/cmplx.h +++ b/cint/cint/lib/dll_stl/cmplx.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/dqu.h b/cint/cint/lib/dll_stl/dqu.h index 1ca104f9561dd..398e3941a12f6 100644 --- a/cint/cint/lib/dll_stl/dqu.h +++ b/cint/cint/lib/dll_stl/dqu.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/iter.h b/cint/cint/lib/dll_stl/iter.h index 7ef93d37b3e55..56225801b100b 100644 --- a/cint/cint/lib/dll_stl/iter.h +++ b/cint/cint/lib/dll_stl/iter.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/lst.h b/cint/cint/lib/dll_stl/lst.h index b4b79308f56ca..a742a37bff063 100644 --- a/cint/cint/lib/dll_stl/lst.h +++ b/cint/cint/lib/dll_stl/lst.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -31,7 +31,29 @@ using namespace std; #pragma link C++ class list; #if defined(G__STRING_DLL) || defined(G__ROOT) #pragma link C++ class list; +#pragma link C++ operators list::iterator; #endif +#pragma link C++ operators list::iterator; +#pragma link C++ operators list::iterator; +#pragma link C++ operators list::iterator; +#pragma link C++ operators list::iterator; +#pragma link C++ operators list::iterator; +#pragma link C++ operators list::iterator; + +#pragma link C++ operators list::const_iterator; +#pragma link C++ operators list::const_iterator; +#pragma link C++ operators list::const_iterator; +#pragma link C++ operators list::const_iterator; +#pragma link C++ operators list::const_iterator; +#pragma link C++ operators list::const_iterator; + +#pragma link C++ operators list::reverse_iterator; +#pragma link C++ operators list::reverse_iterator; +#pragma link C++ operators list::reverse_iterator; +#pragma link C++ operators list::reverse_iterator; +#pragma link C++ operators list::reverse_iterator; +#pragma link C++ operators list::reverse_iterator; + #endif diff --git a/cint/cint/lib/dll_stl/mp.h b/cint/cint/lib/dll_stl/mp.h index 0a1353734b0e2..ad3a33319ab7b 100644 --- a/cint/cint/lib/dll_stl/mp.h +++ b/cint/cint/lib/dll_stl/mp.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -45,6 +45,51 @@ using namespace std; #pragma link C++ class map; #pragma link C++ class map; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; + +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; + +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; + +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; + +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; + +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; + #pragma link off function pair::operator=; #pragma link off function pair::operator=; #pragma link off function pair::operator=; @@ -68,6 +113,27 @@ using namespace std; #pragma link C++ class map; #pragma link C++ class map; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; + +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; + +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; + #if defined(G__STRING_DLL) || defined(G__ROOT) #pragma link C++ class map; #pragma link C++ class map; @@ -75,6 +141,28 @@ using namespace std; #pragma link C++ class map; #pragma link C++ class map; //#pragma link C++ class map; + +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +#pragma link C++ operators map::iterator; +//#pragma link C++ operators map::iterator; + +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +#pragma link C++ operators map::const_iterator; +//#pragma link C++ operators map::const_iterator; + +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +#pragma link C++ operators map::reverse_iterator; +//#pragma link C++ operators map::reverse_iterator; + #if defined(G__GNUC) && (G__GNUC>=3) #pragma link off class pair; #pragma link off class pair; diff --git a/cint/cint/lib/dll_stl/multmp.h b/cint/cint/lib/dll_stl/multmp.h index e1537e2773d8f..f7862df1f6a42 100644 --- a/cint/cint/lib/dll_stl/multmp.h +++ b/cint/cint/lib/dll_stl/multmp.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -39,6 +39,42 @@ using namespace std; #pragma link C++ class multimap; #pragma link C++ class multimap; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; + +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; + +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; + +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; + +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; + +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; + #pragma link off function pair::operator=; #pragma link off function pair::operator=; #pragma link off function pair::operator=; @@ -58,12 +94,49 @@ using namespace std; #pragma link C++ class multimap; #pragma link C++ class multimap; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; + +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; + +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; + #if defined(G__STRING_DLL) || defined(G__ROOT) #pragma link C++ class multimap; #pragma link C++ class multimap; #pragma link C++ class multimap; #pragma link C++ class multimap; //#pragma link C++ class multimap; + +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; +#pragma link C++ operators multimap::iterator; +//#pragma link C++ operators multimap::iterator; + +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; +#pragma link C++ operators multimap::const_iterator; +//#pragma link C++ operators multimap::const_iterator; + +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; +#pragma link C++ operators multimap::reverse_iterator; +//#pragma link C++ operators multimap::reverse_iterator; + #pragma link off function pair::operator=; #pragma link off function pair::operator=; #pragma link off function pair::operator=; diff --git a/cint/cint/lib/dll_stl/multst.h b/cint/cint/lib/dll_stl/multst.h index 4b8824056f79a..5b6b530049c3d 100644 --- a/cint/cint/lib/dll_stl/multst.h +++ b/cint/cint/lib/dll_stl/multst.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -34,8 +34,30 @@ using namespace std; #pragma link C++ class multiset; #if defined(G__STRING_DLL) || defined(G__ROOT) #pragma link C++ class multiset; +#pragma link C++ operators multiset::iterator; #endif +#pragma link C++ operators multiset::iterator; +#pragma link C++ operators multiset::iterator; +#pragma link C++ operators multiset::iterator; +#pragma link C++ operators multiset::iterator; +#pragma link C++ operators multiset::iterator; +#pragma link C++ operators multiset::iterator; + +#pragma link C++ operators multiset::const_iterator; +#pragma link C++ operators multiset::const_iterator; +#pragma link C++ operators multiset::const_iterator; +#pragma link C++ operators multiset::const_iterator; +#pragma link C++ operators multiset::const_iterator; +#pragma link C++ operators multiset::const_iterator; + +#pragma link C++ operators multiset::reverse_iterator; +#pragma link C++ operators multiset::reverse_iterator; +#pragma link C++ operators multiset::reverse_iterator; +#pragma link C++ operators multiset::reverse_iterator; +#pragma link C++ operators multiset::reverse_iterator; +#pragma link C++ operators multiset::reverse_iterator; + #endif diff --git a/cint/cint/lib/dll_stl/pr.h b/cint/cint/lib/dll_stl/pr.h index 879f9fb7f21b6..11d84102dd765 100644 --- a/cint/cint/lib/dll_stl/pr.h +++ b/cint/cint/lib/dll_stl/pr.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/que.h b/cint/cint/lib/dll_stl/que.h index b9ea990ed1f0e..fc961d929268b 100644 --- a/cint/cint/lib/dll_stl/que.h +++ b/cint/cint/lib/dll_stl/que.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/se.h b/cint/cint/lib/dll_stl/se.h index be46fefbc58cf..6e258256780a6 100644 --- a/cint/cint/lib/dll_stl/se.h +++ b/cint/cint/lib/dll_stl/se.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/st.h b/cint/cint/lib/dll_stl/st.h index af508e4ce9753..ba8dacc7ed423 100644 --- a/cint/cint/lib/dll_stl/st.h +++ b/cint/cint/lib/dll_stl/st.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -30,8 +30,30 @@ using namespace std; #pragma link C++ class set; #if defined(G__STRING_DLL) || defined(G__ROOT) #pragma link C++ class set; +#pragma link C++ operators set::iterator; #endif +#pragma link C++ operators set::iterator; +#pragma link C++ operators set::iterator; +#pragma link C++ operators set::iterator; +#pragma link C++ operators set::iterator; +#pragma link C++ operators set::iterator; +#pragma link C++ operators set::iterator; + +#pragma link C++ operators set::const_iterator; +#pragma link C++ operators set::const_iterator; +#pragma link C++ operators set::const_iterator; +#pragma link C++ operators set::const_iterator; +#pragma link C++ operators set::const_iterator; +#pragma link C++ operators set::const_iterator; + +#pragma link C++ operators set::reverse_iterator; +#pragma link C++ operators set::reverse_iterator; +#pragma link C++ operators set::reverse_iterator; +#pragma link C++ operators set::reverse_iterator; +#pragma link C++ operators set::reverse_iterator; +#pragma link C++ operators set::reverse_iterator; + #endif diff --git a/cint/cint/lib/dll_stl/stk.h b/cint/cint/lib/dll_stl/stk.h index 13565c4780973..9ac54e9512375 100644 --- a/cint/cint/lib/dll_stl/stk.h +++ b/cint/cint/lib/dll_stl/stk.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/str.h b/cint/cint/lib/dll_stl/str.h index 4f645f81626b4..28ed9e48726ff 100644 --- a/cint/cint/lib/dll_stl/str.h +++ b/cint/cint/lib/dll_stl/str.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/suncc5_deque.h b/cint/cint/lib/dll_stl/suncc5_deque.h index 9657270fa6828..ab4f169a047ad 100644 --- a/cint/cint/lib/dll_stl/suncc5_deque.h +++ b/cint/cint/lib/dll_stl/suncc5_deque.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/suncc5_string.h b/cint/cint/lib/dll_stl/suncc5_string.h index bc13473cc4e50..43a6a9380fdd6 100644 --- a/cint/cint/lib/dll_stl/suncc5_string.h +++ b/cint/cint/lib/dll_stl/suncc5_string.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/vary.h b/cint/cint/lib/dll_stl/vary.h index 4441b0dfc9bde..705872aa71255 100644 --- a/cint/cint/lib/dll_stl/vary.h +++ b/cint/cint/lib/dll_stl/vary.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/vec.h b/cint/cint/lib/dll_stl/vec.h index 825e141c53dc4..a333db70165bc 100644 --- a/cint/cint/lib/dll_stl/vec.h +++ b/cint/cint/lib/dll_stl/vec.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/dll_stl/vecbool.h b/cint/cint/lib/dll_stl/vecbool.h index 1d2cc8e8d430a..f74c3370003d7 100644 --- a/cint/cint/lib/dll_stl/vecbool.h +++ b/cint/cint/lib/dll_stl/vecbool.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/gcc3strm/linkdef.h b/cint/cint/lib/gcc3strm/linkdef.h index 9ff0dace338c0..074ed48996084 100644 --- a/cint/cint/lib/gcc3strm/linkdef.h +++ b/cint/cint/lib/gcc3strm/linkdef.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/gcc4strm/fstrm.h b/cint/cint/lib/gcc4strm/fstrm.h index 3c1c43e633bec..16a4723ab9ad2 100644 --- a/cint/cint/lib/gcc4strm/fstrm.h +++ b/cint/cint/lib/gcc4strm/fstrm.h @@ -7,7 +7,7 @@ * Description: * Stub file for making iostream library ************************************************************************ - * Copyright(c) 2007 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 2007 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/gcc4strm/linkdef.h b/cint/cint/lib/gcc4strm/linkdef.h index 870645814feb3..cb1f7f34a230e 100644 --- a/cint/cint/lib/gcc4strm/linkdef.h +++ b/cint/cint/lib/gcc4strm/linkdef.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 2007 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 2007 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/gl/GL.h b/cint/cint/lib/gl/GL.h index 6354aaf19b2fb..4648335766cc5 100644 --- a/cint/cint/lib/gl/GL.h +++ b/cint/cint/lib/gl/GL.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/gl/TOP.h b/cint/cint/lib/gl/TOP.h index 1da20cf8ff999..f1f68ba4c3712 100644 --- a/cint/cint/lib/gl/TOP.h +++ b/cint/cint/lib/gl/TOP.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/gl/cintGL.h b/cint/cint/lib/gl/cintGL.h index e54a3004f89f7..e0d3c8c28ac66 100644 --- a/cint/cint/lib/gl/cintGL.h +++ b/cint/cint/lib/gl/cintGL.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/iccstrm/linkdef.h b/cint/cint/lib/iccstrm/linkdef.h index 9ff0dace338c0..074ed48996084 100644 --- a/cint/cint/lib/iccstrm/linkdef.h +++ b/cint/cint/lib/iccstrm/linkdef.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/libcxxstrm/Makefile b/cint/cint/lib/libcxxstrm/Makefile new file mode 100644 index 0000000000000..008a0d1485f5a --- /dev/null +++ b/cint/cint/lib/libcxxstrm/Makefile @@ -0,0 +1,28 @@ +# +# lib/libcxxstrm/Makefile +# +CP = cp +MV = mv + +CINTSYSDIR = ../.. + +SRCCPPIFC = $(CINTSYSDIR)/src/dict/libcxxstrm.cxx +SRCCPPIFH = $(CINTSYSDIR)/src/dict/libcxxstrm.h +CPPIFC = libcxxstrm.cxx +CPPIFH = libcxxstrm.h + +CPPHEADER = iostrm.h fstrm.h sstrm.h linkdef.h + +# stdiostr.h \ + + +$(SRCCPPIFC) : $(CPPIFC) +# cint ../snstream/length.cxx 255 $(CPPIFC) $(CPPIFH) + $(MV) $(CPPIFC) $(SRCCPPIFC) + $(MV) $(CPPIFH) $(SRCCPPIFH) + + +$(CPPIFC) : $(CPPHEADER) + cint -Z0 -n$(CPPIFC) -NG__stream $(DLLSPEC) -D__MAKECINT__ -DG__MAKECINT -c-1 $(IPATH) $(MACRO) $(CPPHEADER) + +# cint -Z0 -n$(CPPIFC) -NG__stream $(DLLSPEC) -D__MAKECINT__ -DG__MAKECINT -M0x10 -c-1 $(IPATH) $(MACRO) $(CPPHEADER) diff --git a/cint/cint/lib/libcxxstrm/README.txt b/cint/cint/lib/libcxxstrm/README.txt new file mode 100644 index 0000000000000..ea04d0090a3e3 --- /dev/null +++ b/cint/cint/lib/libcxxstrm/README.txt @@ -0,0 +1,15 @@ +lib/libcxxstrm/README + + lib/libcxxstrm directory exists for creating iostream library linkage file +src/libcxxstrm.cxx and src/libcxxstrm.h for clang++ compiler with libc++. +These files contain interface methods for iostream library. You can create +those by doing 'make' under this directory. Usually nobody but only author +should do this. User doesn't need to recognize this. + Files in this directory are originally copied from lib/gcc4strm/* and +modified for libcxxstrm. + + cbstream.cpp is based on template based stream library. + + Creating src/libcxxstrm.cxx + + 1) Just do 'make' in this directory. diff --git a/cint/cint/lib/libcxxstrm/fstrm.h b/cint/cint/lib/libcxxstrm/fstrm.h new file mode 100644 index 0000000000000..c4b60e66810b6 --- /dev/null +++ b/cint/cint/lib/libcxxstrm/fstrm.h @@ -0,0 +1,161 @@ +/* /% C++ %/ */ +/*********************************************************************** + * cint (C/C++ interpreter) + ************************************************************************ + * header file fstrm.h + ************************************************************************ + * Description: + * Stub file for making iostream library + ************************************************************************ + * Copyright(c) 2007 Masaharu Goto (root-cint@cern.ch) + * + * For the licensing terms see the file COPYING + * + ************************************************************************/ + +#ifndef G__FSTREAM_H +#define G__FSTREAM_H + +#ifndef __CINT__ + +#include +using namespace std; + +#else // __CINT__ + +#include "iostrm.h" + +template +class basic_filebuf : public basic_streambuf { + private: + typedef basic_ios ios_type; +#ifndef __CINT__ + typedef traits::state_type state_t; +#endif + public: + typedef traits traits_type; + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + basic_filebuf(); +#if !(G__GNUC>=3) + basic_filebuf(int fd); +#endif + virtual ~basic_filebuf(); + bool is_open() const; +#if !(G__GNUC>=3) + basic_filebuf * + open(const char *s, ios_base::openmode, long protection = 0666 ); +#else + basic_filebuf * open(const char *s, ios_base::openmode); +#endif +#if !(G__GNUC>=3) + basic_filebuf *open(int fd); +#endif + basic_filebuf *close(); + protected: + virtual int showmanyc(); + virtual int_type overflow(int_type c = traits::eof()); + virtual int_type pbackfail(int_type c = traits::eof()); + virtual int_type underflow(); + virtual basic_streambuf* setbuf(char_type *s,streamsize n); + virtual pos_type seekoff(off_type off,ios_base::seekdir way + ,ios_base::openmode which = + ios_base::in | ios_base::out); + virtual pos_type seekpos(pos_type sp + ,ios_base::openmode which = + ios_base::in | ios_base::out); + virtual int sync(); + virtual streamsize xsputn(const char_type *s, streamsize n); +#if (G__GNUC>=3) + private: + basic_filebuf& operator=(const basic_filebuf& x); +#endif +}; + +template +class basic_ifstream : public basic_istream { + public: + typedef basic_ios ios_type; + typedef traits traits_type; + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + public: + basic_ifstream(); +#if !(G__GNUC>=3) + basic_ifstream(const char *s,ios_base::openmode mode = ios_base::in + ,long protection = 0666 ); + basic_ifstream(int fd); + basic_ifstream(int fd, char_type *buf, int len); +#else + basic_ifstream(const char *s,ios_base::openmode mode = ios_base::in); +#endif + virtual ~basic_ifstream(); + basic_filebuf *rdbuf() const; + bool is_open(); +#if !(G__GNUC>=3) + void open(const char *s, ios_base::openmode mode = ios_base::in + ,long protection = 0666 ); +#else + void open(const char *s, ios_base::openmode mode = ios_base::in); +#endif + void close(); +}; + +template +class basic_ofstream : public basic_ostream { + public: + typedef basic_ios ios_type; + typedef traits traits_type; + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + public: + basic_ofstream(); +#if !(G__GNUC>=3) + basic_ofstream(const char *s, ios_base::openmode mode=ios_base::out + ,long protection = 0666 ); + basic_ofstream(int fd); + basic_ofstream(int fd, char_type *buf, int len); +#else + basic_ofstream(const char *s, ios_base::openmode mode=ios_base::out); +#endif + virtual ~basic_ofstream(); + basic_filebuf *rdbuf() const; + bool is_open(); +#if !(G__GNUC>=3) + void open(const char *s,ios_base::openmode mode=ios_base::out + ,long protection = 0666 ); +#else + void open(const char *s,ios_base::openmode mode=ios_base::out); +#endif + void close(); + }; + +template +class basic_fstream : public basic_iostream { + public: + basic_fstream(); + basic_fstream(const char *s,ios_base::openmode mode); + basic_filebuf *rdbuf() const; + bool is_open(); + void open(const char *s,ios_base::openmode mode); + void close(); +}; + +typedef basic_filebuf > filebuf; +//typedef basic_filebuf > wfilebuf; +typedef basic_ifstream > ifstream; +//typedef basic_ifstream > wifstream; +typedef basic_ofstream > ofstream; +//typedef basic_ofstream > wofstream; +typedef basic_fstream > fstream; +//typedef basic_fstream > wfstream; + + +#endif // __CINT__ +#endif // G__FSTREAM_H diff --git a/cint/cint/lib/libcxxstrm/iostrm.h b/cint/cint/lib/libcxxstrm/iostrm.h new file mode 100644 index 0000000000000..1349e94be57d6 --- /dev/null +++ b/cint/cint/lib/libcxxstrm/iostrm.h @@ -0,0 +1,686 @@ +/* /% C++ %/ */ +/*********************************************************************** + * cint (C/C++ interpreter) + ************************************************************************ + * header file iostrm.h + ************************************************************************ + * Description: + * Stub file for making iostream library for g++ 4.00 + ************************************************************************ + * Copyright(c) 2007 Masaharu Goto + * + * For the licensing terms see the file COPYING + * + ************************************************************************/ + +#ifndef G__IOSTREAM_H +#define G__IOSTREAM_H + +#define G__TMPLTIOS + +#define G__OSTREAMBODY +//#define G__OSTREAMMEMBERSTUB +#define G__OSTREAMGLOBALSTUB + +#ifndef __CINT__ + +#include +using namespace std; + +//inline ostream& operator<< (ostream& ost,unsigned char c) +// {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,short c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,unsigned short c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,int c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,unsigned int c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,long c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,unsigned long c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,float c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,double c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,long double c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,bool c) + {return(ost.operator<<(c));} +inline ostream& operator<< ( ostream& ost, void* p) + {return(ost.operator<<(p));} + +//inline istream& operator>> ( istream& ist, unsigned char& p) +// {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, short& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, unsigned short& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, int & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, unsigned int& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, long & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, unsigned long& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, float & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, double & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, bool& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, long double & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, void*& p) + {return(ist.operator>>(p));} + +#ifndef G__OLDIMPLEMENTATION1635 +#include +/******************************************************************** + * static variables for iostream redirection + ********************************************************************/ +static streambuf *G__store_cout; +static streambuf *G__store_cerr; +static streambuf *G__store_cin; +static ofstream *G__redirected_cout; +static ofstream *G__redirected_cerr; +static ifstream *G__redirected_cin; +/******************************************************************** + * G__redirectcout + ********************************************************************/ +extern "C" void G__unredirectcout() { + if(G__store_cout) { + cout.rdbuf(G__store_cout); + G__store_cout = 0; + } + if(G__redirected_cout) { + delete G__redirected_cout; + G__redirected_cout = 0; + } +} +/******************************************************************** + * G__redirectcout + ********************************************************************/ +extern "C" void G__redirectcout(const char* filename) { + G__unredirectcout(); + G__redirected_cout = new ofstream(filename,ios_base::app); + G__store_cout = cout.rdbuf(G__redirected_cout->rdbuf()) ; +} +/******************************************************************** + * G__redirectcerr + ********************************************************************/ +extern "C" void G__unredirectcerr() { + if(G__store_cerr) { + cerr.rdbuf(G__store_cerr); + G__store_cerr = 0; + } + if(G__redirected_cerr) { + delete G__redirected_cerr; + G__redirected_cerr = 0; + } +} +/******************************************************************** + * G__redirectcerr + ********************************************************************/ +extern "C" void G__redirectcerr(const char* filename) { + G__unredirectcerr(); + G__redirected_cerr = new ofstream(filename,ios_base::app); + G__store_cerr = cerr.rdbuf(G__redirected_cerr->rdbuf()) ; +} +/******************************************************************** + * G__redirectcin + ********************************************************************/ +extern "C" void G__unredirectcin() { + if(G__store_cin) { + cin.rdbuf(G__store_cin); + G__store_cin = 0; + } + if(G__redirected_cin) { + delete G__redirected_cin; + G__redirected_cin = 0; + } +} +/******************************************************************** + * G__redirectcin + ********************************************************************/ +extern "C" void G__redirectcin(const char* filename) { + G__unredirectcin(); + G__redirected_cin = new ifstream(filename,ios_base::in); + G__store_cin = cin.rdbuf(G__redirected_cin->rdbuf()) ; +} +#endif /* 1635 */ + +#else // __CINT__ + +//#include + +/******************************************************************** +* streampos +*********************************************************************/ +extern "C" { + typedef struct { + private: + int __fill[6]; + } mbstate_t; +} + +#ifdef G__THIS_DOES_NOT_WORK_WITH_CYGWIN_GCC3 +class wstreampos { }; +#endif +class streamoff { }; + + +typedef long long streampos ; +typedef long long streamoff ; + +typedef long long SZ_T; +typedef SZ_T streamsize; + +template +class fpos { + public: + fpos(); + fpos(const fpos&); + fpos(long long); + operator streamoff() const; + fpos operator+(streamoff a) const; + fpos operator-(streamoff a) const; + streamoff operator-(const fpos& a) const; + fpos& operator+=(streamoff a); + fpos& operator-=(streamoff a); + _StateT state() const; + void state(_StateT a); + //bool operator==(const fpos& a); + //bool operator!=(const fpos& a); + //FIXME: operator+= and operator-= are missing + //bool operator>(const fpos& a); + //friend bool operator<(const fpos& a,const fpos& b); + //friend bool operator>(const fpos& a,const fpos& b); + //friend bool operator<=(const fpos& a,const fpos& b); + //friend bool operator<=(const fpos& a,const fpos& b); +}; + +template +inline bool operator==(const fpos<_StateT>& l, const fpos<_StateT>& r); + +template +inline bool operator!=(const fpos<_StateT>& l, const fpos<_StateT>& r); + +typedef fpos streampos; + +/******************************************************************** +* macro G__MANIP_SUPPORT must be defined to enable true manipulator +*********************************************************************/ +#define G__MANIP_SUPPORT + +class ios_base { + public: + typedef int iostate; + enum io_state { + goodbit = 0x00, + badbit = 0x01, + eofbit = 0x02, + failbit = 0x04 + }; + typedef int openmode; + enum open_mode { + app = 0x01, + binary = 0x02, + in = 0x04, + out = 0x08, + trunc = 0x10, + ate = 0x20 + }; + typedef int seekdir; + enum seek_dir { + beg = 0x0, + cur = 0x1, + end = 0x2 + }; + typedef int fmtflags; + enum fmt_flags { + boolalpha = 0x0001, + dec = 0x0002, + fixed = 0x0004, + hex = 0x0008, + internal = 0x0010, + left = 0x0020, + oct = 0x0040, + right = 0x0080, + scientific = 0x0100, + showbase = 0x0200, + showpoint = 0x0400, + showpos = 0x0800, + skipws = 0x1000, + unitbuf = 0x2000, + uppercase = 0x4000, + adjustfield = left | right | internal, + basefield = dec | oct | hex, + floatfield = scientific | fixed + }; + enum event { + erase_event = 0x0001, + imbue_event = 0x0002, + copyfmt_event = 0x0004 + }; + typedef void (*event_callback) (event, ios_base&, int index); + void register_callback( event_callback fn, int index); +#ifdef G__SUNCC5 + enum EmptyCtor {emptyctor}; +#endif + class Init { + public: +#if !(G__GNUC>=3) + static int getinit_cnt_(); +#endif + Init(); +#ifdef __MAKECINT__ + private: +#endif + ~Init(); + }; + inline fmtflags flags() const; + inline fmtflags flags(fmtflags fmtfl); + inline fmtflags setf(fmtflags fmtfl); + inline fmtflags setf(fmtflags fmtfl, fmtflags mask); + inline void unsetf(fmtflags mask); +#if !(G__GNUC>=3) + ios_base& copyfmt(const ios_base& rhs); +#endif + inline streamsize precision() const; + inline streamsize precision(streamsize prec); + inline streamsize width() const; + inline streamsize width(streamsize wide); + static int xalloc(); + long& iword(int index); + void*& pword(int index); + //locale imbue(const locale& loc); + //locale getloc() const ; +#if !(G__GNUC>=3) + bool is_synch() ; +#endif +#ifdef G__SUNCC5 + static bool sync_with_stdio(bool sync = true); +#else + bool sync_with_stdio(bool sync = true); +#endif +#ifdef G__SUNCC5 + virtual ~ios_base(); +#endif + protected: + ios_base(); +#ifndef G__SUNCC5 + ~ios_base(); +#endif +#if (G__GNUC>=3) + private: + ios_base(const ios_base& x); + ios_base& operator=(const ios_base& x); +#endif +}; + +template +class basic_ios : public ios_base { + public: +#if !(G__GNUC>=3) + typedef basic_ios ios_type; + typedef basic_streambuf streambuf_type; + typedef basic_ostream ostream_type; +#endif + typedef traits::char_type char_type; + typedef traits traits_type; + typedef traits::int_type int_type; + typedef traits::off_type off_type; + typedef traits::pos_type pos_type; + explicit basic_ios(basic_streambuf *sb_arg); + virtual ~basic_ios(); + char_type fill() const; + char_type fill(char_type ch); + inline void exceptions(iostate excpt); + inline iostate exceptions() const; + inline void clear(iostate state = goodbit); + inline void setstate(iostate state); + inline iostate rdstate() const; + //inline operator void*() const; + inline bool operator! () const; + inline bool good() const; + inline bool eof() const; + inline bool fail() const; + inline bool bad() const; +#if !(G__GNUC>=3) + ios_type& copyfmt(const ios_type& rhs); +#else + basic_ios& copyfmt(const basic_ios& rhs); +#endif + inline basic_ostream *tie() const; + basic_ostream *tie(basic_ostream *tie_arg); + inline basic_streambuf *rdbuf() const; + basic_streambuf *rdbuf( basic_streambuf *sb); + //locale imbue(const locale& loc); + inline char narrow(charT, char) const; + inline charT widen(char) const; + protected: + basic_ios(); + void init(basic_streambuf *sb); + private: +// #ifdef G__SUNCC5 + basic_ios(const basic_ios& ); // not defined + basic_ios& operator=(const basic_ios&); // not defined +// #endif +}; + +template +class basic_streambuf { + public: + typedef charT char_type; + typedef traits traits_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + virtual ~basic_streambuf(); + //locale pubimbue( const locale& loc); + //locale getloc() const; + inline basic_streambuf * + pubsetbuf(char_type *s, streamsize n); + inline pos_type pubseekoff(off_type off, ios_base::seekdir way, + ios_base::openmode which = + ios_base::in | ios_base::out); + inline pos_type pubseekpos(pos_type sp, ios_base::openmode which = + ios_base::in | ios_base::out); + inline int pubsync( ); +#if !(G__GNUC>=3) + inline ios_base::openmode which_open_mode(); +#endif + inline streamsize in_avail(); + inline int_type snextc(); + inline int_type sbumpc(); + inline int_type sgetc(); + inline streamsize sgetn(char_type *s, streamsize n); + inline int_type sputbackc(char_type c); + inline int_type sungetc(); + inline int_type sputc(char_type c); + inline streamsize sputn(const char_type *s, streamsize n); + protected: + basic_streambuf(); +#if (G__GNUC>=3) + private: + basic_streambuf(const basic_streambuf& x); + basic_streambuf& operator=(const basic_streambuf& x); +#endif +}; + +template +class basic_istream : virtual public basic_ios { + public: + typedef basic_istream __istream_type; + typedef basic_ios __ios_type; + typedef basic_streambuf __streambuf_type; + typedef traits traits_type; + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + explicit basic_istream(basic_streambuf *sb); + virtual ~basic_istream(); + class sentry { + public: + inline sentry(basic_istream& stream,bool noskipws = 0); +#ifdef __MAKECINT__ + private: + ~sentry() {} + sentry(const sentry&); // = delete; + sentry& operator=(const sentry&); // = delete; + public: +#else + ~sentry() {} +#endif + operator bool () { return ok_; } + }; + //__istream_type& operator>>(__istream_type& (*pf)(__istream_type&)); + //__istream_type& operator>>(ios_base& (*pf)(ios_base&)); + //__istream_type& operator>>(__ios_type& (*pf)(__ios_type&)); +#ifndef __CINT__ + basic_istream& operator>>(bool& n); + basic_istream& operator>>(short& n); + basic_istream& operator>>(unsigned short& n); + basic_istream& operator>>(int& n); + basic_istream& operator>>(unsigned int& n); + basic_istream& operator>>(long& n); + basic_istream& operator>>(unsigned long& n); + basic_istream& operator>>(float& f); + basic_istream& operator>>(double& f); + basic_istream& operator>>(long double& f); +#if !(G__GNUC>=3) + basic_istream& operator>>(basic_streambuf *sb); +#endif + basic_istream& operator>>(void*& p); +#endif +#if !(G__GNUC>=3) + basic_istream& operator>>(basic_streambuf& sb); +#endif + int_type get(); + basic_istream& get(char_type *s, streamsize n, char_type delim); + basic_istream& get(char_type *s, streamsize n); + basic_istream& get(char_type& c); + basic_istream& get(basic_streambuf& sb, char_type delim); + basic_istream& get(basic_streambuf& sb); + basic_istream& getline(char_type *s, streamsize n, char_type delim); + basic_istream& getline(char_type *s, streamsize n); + basic_istream& ignore(streamsize n , int_type delim ); + basic_istream& ignore(streamsize n =1 ); + //__istream_type& ignore(streamsize n = 1, int_type delim = traits::eof()); + basic_istream& read(char_type *s, streamsize n); + streamsize readsome(char_type *s, streamsize n); + int peek(); + pos_type tellg(); + basic_istream& seekg(pos_type pos); + int sync(); +//#ifndef __CINT__ + basic_istream& seekg(off_type, ios_base::seekdir); +//#endif + basic_istream& putback(char_type c); + basic_istream& unget(); + streamsize gcount() const; + protected: + basic_istream( ); +}; + +template +class basic_ostream : virtual public basic_ios { + public: + typedef basic_ostream __ostream_type; + typedef basic_ios __ios_type; + typedef traits traits_type; + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + explicit basic_ostream(basic_streambuf *sb); + virtual ~basic_ostream(); + class sentry { + public: + inline explicit sentry(basic_ostream& stream); +#ifdef __MAKECINT__ + private: + ~sentry() {} + public: +#else + ~sentry() ; +#endif + operator bool () ; + private: +//#ifdef G__SUNCC5 + sentry(const sentry&); // not defined + sentry& operator=(const sentry&); // not defined +//#endif + }; + //__ostream_type& operator<<(__ostream_type& (*pf)(__ostream_type&)); + //__ostream_type& operator<<(ios_base& (*pf)(ios_base&)); + //__ostream_type& operator<<(__ios_type& (*pf)(__ios_type&)); +#ifndef __CINT__ + basic_ostream& operator<<(short n); + basic_ostream& operator<<(unsigned short n); + basic_ostream& operator<<(int n); + basic_ostream& operator<<(unsigned int n); + basic_ostream& operator<<(long n); + basic_ostream& operator<<(unsigned long n); + basic_ostream& operator<<(float f); + basic_ostream& operator<<(double f); + basic_ostream& operator<<(long double f); + basic_ostream& operator<<(bool n); + basic_ostream& operator<<(basic_streambuf *sb); + basic_ostream& operator<<(void *p); +#endif + //__ostream_type& operator<<(basic_streambuf& sb); + basic_ostream& put(char_type c); + basic_ostream& write(const char_type *s, streamsize n); + basic_ostream& flush(); + basic_ostream& seekp(pos_type pos); + basic_ostream& seekp(off_type , ios_base::seekdir ); + pos_type tellp(); + protected: + basic_ostream(); +}; + + +template +class basic_iostream + : public basic_istream,public basic_ostream +{ +public: + explicit basic_iostream(basic_streambuf *sb); + virtual ~basic_iostream(); + +protected: + explicit basic_iostream(); +}; + + +typedef int INT_T; + +template +struct char_traits { + typedef charT char_type; + typedef INT_T int_type; + typedef mbstate_t state_type; + typedef fpos pos_type; + typedef wstreamoff off_type; + static void assign (char_type& c1, const char_type& c2) ; + static char_type to_char_type(const int_type& c); + static int_type to_int_type(const char_type& c); + static bool eq(const char_type& c1,const char_type& c2); + static bool lt (const char_type& c1, const char_type& c2) ; + static int compare (const char_type* s1, const char_type* s2, size_t n); + static bool eq_int_type(const int_type& c1,const int_type& c2); + static int_type eof(); + static int_type not_eof(const int_type& c); + static size_t length(const char_type *s); + static const char_type* find (const char_type* s,int n,const char_type& a); + static char_type *copy(char_type *dst,const char_type *src, size_t n); + static char_type* move (char_type* s1, const char_type* s2, size_t n); + static char_type* assign (char_type* s, size_t n, const char_type a); +}; + +struct char_traits { + typedef char char_type; + typedef int int_type; + +#ifdef __CINT__ + typedef streamoff off_type; + typedef streampos pos_type; + typedef mbstate_t state_type; +#endif + static void assign (char_type& c1, const char_type& c2) ; + static char_type to_char_type(const int_type& c); + static int_type to_int_type(const char_type& c); + static bool eq(const char_type& c1,const char_type& c2); + static bool lt (const char_type& c1, const char_type& c2) ; + static int compare (const char_type* s1, const char_type* s2, size_t n); + static const char_type* find (const char_type* s,int n,const char_type& a); + static bool eq_int_type(const int_type& c1,const int_type& c2); + static int_type eof(); + static int_type not_eof(const int_type& c); + static size_t length(const char_type *s); + static char_type *copy(char_type *dst,const char_type *src, size_t n); + static char_type * move (char_type* s1, const char_type* s2, size_t n); + static char_type* assign (char_type* s, size_t n, const char_type a); +}; + +//typedef basic_istream > istream; +typedef basic_istream > istream; +//typedef basic_ostream ostream; +typedef basic_ostream > ostream; + +typedef basic_streambuf > streambuf; + +extern istream cin ; +extern ostream cout ; +extern ostream cerr ; +extern ostream clog ; + +#ifndef G__OLDIMPLEMENTATION1938 +ios_base& dec(ios_base&) ; +ios_base& hex(ios_base&) ; +ios_base& oct(ios_base&) ; +ios_base& fixed(ios_base&); +ios_base& scientific(ios_base&); +ios_base& right(ios_base&); +ios_base& left(ios_base&); +ios_base& internal(ios_base&); +ios_base& nouppercase(ios_base&); +ios_base& uppercase(ios_base&); +ios_base& noskipws(ios_base&); +ios_base& skipws(ios_base&); +ios_base& noshowpos(ios_base&); +ios_base& showpos(ios_base&); +ios_base& noshowpoint(ios_base&); +ios_base& showpoint(ios_base&); +ios_base& noshowbase(ios_base&); +ios_base& showbase(ios_base&); +ios_base& noboolalpha(ios_base&); +ios_base& boolalpha(ios_base&); +#endif + +istream& ws(istream&) ; + +ostream& endl(ostream& i) ; +ostream& ends(ostream& i) ; +ostream& flush(ostream&) ; + +ostream& operator<< ( ostream&, char ); +ostream& operator<< ( ostream&, char* ); +ostream& operator<< ( ostream&, void* ); +ostream& operator<< ( ostream&, unsigned char ); +ostream& operator<< ( ostream&, short ); +ostream& operator<< ( ostream&, unsigned short ); +ostream& operator<< ( ostream&, int ); +ostream& operator<< ( ostream&, unsigned int ); +ostream& operator<< ( ostream&, long ); +ostream& operator<< ( ostream&, unsigned long); +ostream& operator<< ( ostream&, float ); +ostream& operator<< ( ostream&, double ); +//ostream& operator<< ( ostream&, long double ); +ostream& operator<< ( ostream&, bool ); +//ostream& operator<< (ostream&,const streampos&); + +istream& operator>> ( istream&, char& ); +istream& operator>> ( istream&, unsigned char& ); +istream& operator>> ( istream&, short& ); +istream& operator>> ( istream&, unsigned short& ); +istream& operator>> ( istream&, int& ); +istream& operator>> ( istream&, unsigned int& ); +istream& operator>> ( istream&, long& ); +istream& operator>> ( istream&, unsigned long& ); +istream& operator>> ( istream&, float& ); +istream& operator>> ( istream&, double& ); +//istream& operator>> ( istream&, long double& ); +istream& operator>> ( istream&, bool& ); +istream& operator>> ( istream&, char* ); +istream& operator>> ( istream&, void*& ); + +#endif // __CINT__ + +#endif // G__IOSTREAM_H diff --git a/cint/cint/lib/libcxxstrm/iostrm.h.org b/cint/cint/lib/libcxxstrm/iostrm.h.org new file mode 100644 index 0000000000000..b10dafddb5563 --- /dev/null +++ b/cint/cint/lib/libcxxstrm/iostrm.h.org @@ -0,0 +1,684 @@ +/* /% C++ %/ */ +/*********************************************************************** + * cint (C/C++ interpreter) + ************************************************************************ + * header file iostrm.h + ************************************************************************ + * Description: + * Stub file for making iostream library for g++ 4.00 + ************************************************************************ + * Copyright(c) 2007 Masaharu Goto + * + * For the licensing terms see the file COPYING + * + ************************************************************************/ + +#ifndef G__IOSTREAM_H +#define G__IOSTREAM_H + +#define G__TMPLTIOS + +#define G__OSTREAMBODY +//#define G__OSTREAMMEMBERSTUB +#define G__OSTREAMGLOBALSTUB + +#ifndef __CINT__ + +#include +using namespace std; + +//inline ostream& operator<< (ostream& ost,unsigned char c) +// {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,short c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,unsigned short c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,int c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,unsigned int c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,long c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,unsigned long c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,float c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,double c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,long double c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,bool c) + {return(ost.operator<<(c));} +inline ostream& operator<< ( ostream& ost, void* p) + {return(ost.operator<<(p));} + +//inline istream& operator>> ( istream& ist, unsigned char& p) +// {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, short& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, unsigned short& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, int & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, unsigned int& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, long & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, unsigned long& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, float & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, double & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, bool& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, long double & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, void*& p) + {return(ist.operator>>(p));} + +#ifndef G__OLDIMPLEMENTATION1635 +#include +/******************************************************************** + * static variables for iostream redirection + ********************************************************************/ +static ostream::__streambuf_type *G__store_cout; +static ostream::__streambuf_type *G__store_cerr; +static istream::__streambuf_type *G__store_cin; +static ofstream *G__redirected_cout; +static ofstream *G__redirected_cerr; +static ifstream *G__redirected_cin; +/******************************************************************** + * G__redirectcout + ********************************************************************/ +extern "C" void G__unredirectcout() { + if(G__store_cout) { + cout.rdbuf(G__store_cout); + G__store_cout = 0; + } + if(G__redirected_cout) { + delete G__redirected_cout; + G__redirected_cout = 0; + } +} +/******************************************************************** + * G__redirectcout + ********************************************************************/ +extern "C" void G__redirectcout(const char* filename) { + G__unredirectcout(); + G__redirected_cout = new ofstream(filename,ios_base::app); + G__store_cout = cout.rdbuf(G__redirected_cout->rdbuf()) ; +} +/******************************************************************** + * G__redirectcerr + ********************************************************************/ +extern "C" void G__unredirectcerr() { + if(G__store_cerr) { + cerr.rdbuf(G__store_cerr); + G__store_cerr = 0; + } + if(G__redirected_cerr) { + delete G__redirected_cerr; + G__redirected_cerr = 0; + } +} +/******************************************************************** + * G__redirectcerr + ********************************************************************/ +extern "C" void G__redirectcerr(const char* filename) { + G__unredirectcerr(); + G__redirected_cerr = new ofstream(filename,ios_base::app); + G__store_cerr = cerr.rdbuf(G__redirected_cerr->rdbuf()) ; +} +/******************************************************************** + * G__redirectcin + ********************************************************************/ +extern "C" void G__unredirectcin() { + if(G__store_cin) { + cin.rdbuf(G__store_cin); + G__store_cin = 0; + } + if(G__redirected_cin) { + delete G__redirected_cin; + G__redirected_cin = 0; + } +} +/******************************************************************** + * G__redirectcin + ********************************************************************/ +extern "C" void G__redirectcin(const char* filename) { + G__unredirectcin(); + G__redirected_cin = new ifstream(filename,ios_base::in); + G__store_cin = cin.rdbuf(G__redirected_cin->rdbuf()) ; +} +#endif /* 1635 */ + +#else // __CINT__ + +#include + +/******************************************************************** +* streampos +*********************************************************************/ +extern "C" { + typedef struct { + private: + int __fill[6]; + } mbstate_t; +} + +#ifdef G__THIS_DOES_NOT_WORK_WITH_CYGWIN_GCC3 +class wstreampos { }; +#endif +class streamoff { }; + + +typedef long long streampos ; +typedef long long streamoff ; + +typedef long long SZ_T; +typedef SZ_T streamsize; + +template +class fpos { + public: + fpos(); + fpos(const fpos&); + fpos(long long); + operator streamoff() const; + fpos operator+(streamoff a) const; + fpos operator-(streamoff a) const; + streamoff operator-(const fpos& a) const; + fpos& operator+=(streamoff a); + fpos& operator-=(streamoff a); + _StateT state() const; + void state(_StateT a); + //bool operator==(const fpos& a); + //bool operator!=(const fpos& a); + //FIXME: operator+= and operator-= are missing + //bool operator>(const fpos& a); + //friend bool operator<(const fpos& a,const fpos& b); + //friend bool operator>(const fpos& a,const fpos& b); + //friend bool operator<=(const fpos& a,const fpos& b); + //friend bool operator<=(const fpos& a,const fpos& b); +}; + +template +inline bool operator==(const fpos<_StateT>& l, const fpos<_StateT>& r); + +template +inline bool operator!=(const fpos<_StateT>& l, const fpos<_StateT>& r); + +typedef fpos streampos; + +/******************************************************************** +* macro G__MANIP_SUPPORT must be defined to enable true manipulator +*********************************************************************/ +#define G__MANIP_SUPPORT + +class ios_base { + public: + typedef int iostate; + enum io_state { + goodbit = 0x00, + badbit = 0x01, + eofbit = 0x02, + failbit = 0x04 + }; + typedef int openmode; + enum open_mode { + app = 0x01, + binary = 0x02, + in = 0x04, + out = 0x08, + trunc = 0x10, + ate = 0x20 + }; + typedef int seekdir; + enum seek_dir { + beg = 0x0, + cur = 0x1, + end = 0x2 + }; + typedef int fmtflags; + enum fmt_flags { + boolalpha = 0x0001, + dec = 0x0002, + fixed = 0x0004, + hex = 0x0008, + internal = 0x0010, + left = 0x0020, + oct = 0x0040, + right = 0x0080, + scientific = 0x0100, + showbase = 0x0200, + showpoint = 0x0400, + showpos = 0x0800, + skipws = 0x1000, + unitbuf = 0x2000, + uppercase = 0x4000, + adjustfield = left | right | internal, + basefield = dec | oct | hex, + floatfield = scientific | fixed + }; + enum event { + erase_event = 0x0001, + imbue_event = 0x0002, + copyfmt_event = 0x0004 + }; + typedef void (*event_callback) (event, ios_base&, int index); + void register_callback( event_callback fn, int index); +#ifdef G__SUNCC5 + enum EmptyCtor {emptyctor}; +#endif + class Init { + public: +#if !(G__GNUC>=3) + static int getinit_cnt_(); +#endif + Init(); +#ifdef __MAKECINT__ + private: +#endif + ~Init(); + }; + inline fmtflags flags() const; + inline fmtflags flags(fmtflags fmtfl); + inline fmtflags setf(fmtflags fmtfl); + inline fmtflags setf(fmtflags fmtfl, fmtflags mask); + inline void unsetf(fmtflags mask); +#if !(G__GNUC>=3) + ios_base& copyfmt(const ios_base& rhs); +#endif + inline streamsize precision() const; + inline streamsize precision(streamsize prec); + inline streamsize width() const; + inline streamsize width(streamsize wide); + static int xalloc(); + long& iword(int index); + void*& pword(int index); + //locale imbue(const locale& loc); + //locale getloc() const ; +#if !(G__GNUC>=3) + bool is_synch() ; +#endif +#ifdef G__SUNCC5 + static bool sync_with_stdio(bool sync = true); +#else + bool sync_with_stdio(bool sync = true); +#endif +#ifdef G__SUNCC5 + virtual ~ios_base(); +#endif + protected: + ios_base(); +#ifndef G__SUNCC5 + ~ios_base(); +#endif +#if (G__GNUC>=3) + private: + ios_base(const ios_base& x); + ios_base& operator=(const ios_base& x); +#endif +}; + +template +class basic_ios : public ios_base { + public: +#if !(G__GNUC>=3) + typedef basic_ios ios_type; + typedef basic_streambuf streambuf_type; + typedef basic_ostream ostream_type; +#endif + typedef traits::char_type char_type; + typedef traits traits_type; + typedef traits::int_type int_type; + typedef traits::off_type off_type; + typedef traits::pos_type pos_type; + explicit basic_ios(basic_streambuf *sb_arg); + virtual ~basic_ios(); + char_type fill() const; + char_type fill(char_type ch); + inline void exceptions(iostate excpt); + inline iostate exceptions() const; + inline void clear(iostate state = goodbit); + inline void setstate(iostate state); + inline iostate rdstate() const; + inline operator void*() const; + inline bool operator! () const; + inline bool good() const; + inline bool eof() const; + inline bool fail() const; + inline bool bad() const; +#if !(G__GNUC>=3) + ios_type& copyfmt(const ios_type& rhs); +#else + basic_ios& copyfmt(const basic_ios& rhs); +#endif + inline basic_ostream *tie() const; + basic_ostream *tie(basic_ostream *tie_arg); + inline basic_streambuf *rdbuf() const; + basic_streambuf *rdbuf( basic_streambuf *sb); + //locale imbue(const locale& loc); + inline char narrow(charT, char) const; + inline charT widen(char) const; + protected: + basic_ios(); + void init(basic_streambuf *sb); + private: +// #ifdef G__SUNCC5 + basic_ios(const basic_ios& ); // not defined + basic_ios& operator=(const basic_ios&); // not defined +// #endif +}; + +template +class basic_streambuf { + public: + typedef charT char_type; + typedef traits traits_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + virtual ~basic_streambuf(); + //locale pubimbue( const locale& loc); + //locale getloc() const; + inline basic_streambuf * + pubsetbuf(char_type *s, streamsize n); + inline pos_type pubseekoff(off_type off, ios_base::seekdir way, + ios_base::openmode which = + ios_base::in | ios_base::out); + inline pos_type pubseekpos(pos_type sp, ios_base::openmode which = + ios_base::in | ios_base::out); + inline int pubsync( ); +#if !(G__GNUC>=3) + inline ios_base::openmode which_open_mode(); +#endif + inline streamsize in_avail(); + inline int_type snextc(); + inline int_type sbumpc(); + inline int_type sgetc(); + inline streamsize sgetn(char_type *s, streamsize n); + inline int_type sputbackc(char_type c); + inline int_type sungetc(); + inline int_type sputc(char_type c); + inline streamsize sputn(const char_type *s, streamsize n); + protected: + basic_streambuf(); +#if (G__GNUC>=3) + private: + basic_streambuf(const basic_streambuf& x); + basic_streambuf& operator=(const basic_streambuf& x); +#endif +}; + +template +class basic_istream : virtual public basic_ios { + public: + typedef basic_istream __istream_type; + typedef basic_ios __ios_type; + typedef basic_streambuf __streambuf_type; + typedef traits traits_type; + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + explicit basic_istream(basic_streambuf *sb); + virtual ~basic_istream(); + class sentry { + public: + inline sentry(basic_istream& stream,bool noskipws = 0); +#ifdef __MAKECINT__ + private: + ~sentry() {} + public: +#else + ~sentry() {} +#endif + operator bool () { return ok_; } + }; + //__istream_type& operator>>(__istream_type& (*pf)(__istream_type&)); + //__istream_type& operator>>(ios_base& (*pf)(ios_base&)); + //__istream_type& operator>>(__ios_type& (*pf)(__ios_type&)); +#ifndef __CINT__ + __istream_type& operator>>(bool& n); + __istream_type& operator>>(short& n); + __istream_type& operator>>(unsigned short& n); + __istream_type& operator>>(int& n); + __istream_type& operator>>(unsigned int& n); + __istream_type& operator>>(long& n); + __istream_type& operator>>(unsigned long& n); + __istream_type& operator>>(float& f); + __istream_type& operator>>(double& f); + __istream_type& operator>>(long double& f); +#if !(G__GNUC>=3) + __istream_type& operator>>(__streambuf_type *sb); +#endif + __istream_type& operator>>(void*& p); +#endif +#if !(G__GNUC>=3) + __istream_type& operator>>(__streambuf_type& sb); +#endif + int_type get(); + __istream_type& get(char_type *s, streamsize n, char_type delim); + __istream_type& get(char_type *s, streamsize n); + __istream_type& get(char_type& c); + __istream_type& get(__streambuf_type& sb, char_type delim); + __istream_type& get(__streambuf_type& sb); + __istream_type& getline(char_type *s, streamsize n, char_type delim); + __istream_type& getline(char_type *s, streamsize n); + __istream_type& ignore(streamsize n , int_type delim ); + __istream_type& ignore(streamsize n =1 ); + //__istream_type& ignore(streamsize n = 1, int_type delim = traits::eof()); + __istream_type& read(char_type *s, streamsize n); + streamsize readsome(char_type *s, streamsize n); + int peek(); + pos_type tellg(); + __istream_type& seekg(pos_type pos); + int sync(); +//#ifndef __CINT__ + __istream_type& seekg(off_type, ios_base::seekdir); +//#endif + __istream_type& putback(char_type c); + __istream_type& unget(); + streamsize gcount() const; + protected: + basic_istream( ); +}; + +template +class basic_ostream : virtual public basic_ios { + public: + typedef basic_ostream __ostream_type; + typedef basic_ios __ios_type; + typedef traits traits_type; + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + explicit basic_ostream(basic_streambuf *sb); + virtual ~basic_ostream(); + class sentry { + public: + inline explicit sentry(basic_ostream& stream); +#ifdef __MAKECINT__ + private: + ~sentry() {} + public: +#else + ~sentry() ; +#endif + operator bool () ; + private: +//#ifdef G__SUNCC5 + sentry(const sentry&); // not defined + sentry& operator=(const sentry&); // not defined +//#endif + }; + //__ostream_type& operator<<(__ostream_type& (*pf)(__ostream_type&)); + //__ostream_type& operator<<(ios_base& (*pf)(ios_base&)); + //__ostream_type& operator<<(__ios_type& (*pf)(__ios_type&)); +#ifndef __CINT__ + __ostream_type& operator<<(short n); + __ostream_type& operator<<(unsigned short n); + __ostream_type& operator<<(int n); + __ostream_type& operator<<(unsigned int n); + __ostream_type& operator<<(long n); + __ostream_type& operator<<(unsigned long n); + __ostream_type& operator<<(float f); + __ostream_type& operator<<(double f); + __ostream_type& operator<<(long double f); + __ostream_type& operator<<(bool n); + __ostream_type& operator<<(basic_streambuf *sb); + __ostream_type& operator<<(void *p); +#endif + //__ostream_type& operator<<(basic_streambuf& sb); + __ostream_type& put(char_type c); + __ostream_type& write(const char_type *s, streamsize n); + __ostream_type& flush(); + __ostream_type& seekp(pos_type pos); + __ostream_type& seekp(off_type , ios_base::seekdir ); + pos_type tellp(); + protected: + basic_ostream(); +}; + + +template +class basic_iostream + : public basic_istream,public basic_ostream +{ +public: + explicit basic_iostream(basic_streambuf *sb); + virtual ~basic_iostream(); + +protected: + explicit basic_iostream(); +}; + + +typedef int INT_T; + +template +struct char_traits { + typedef charT char_type; + typedef INT_T int_type; + typedef mbstate_t state_type; + typedef fpos pos_type; + typedef wstreamoff off_type; + static void assign (char_type& c1, const char_type& c2) ; + static char_type to_char_type(const int_type& c); + static int_type to_int_type(const char_type& c); + static bool eq(const char_type& c1,const char_type& c2); + static bool lt (const char_type& c1, const char_type& c2) ; + static int compare (const char_type* s1, const char_type* s2, size_t n); + static bool eq_int_type(const int_type& c1,const int_type& c2); + static int_type eof(); + static int_type not_eof(const int_type& c); + static size_t length(const char_type *s); + static const char_type* find (const char_type* s,int n,const char_type& a); + static char_type *copy(char_type *dst,const char_type *src, size_t n); + static char_type* move (char_type* s1, const char_type* s2, size_t n); + static char_type* assign (char_type* s, size_t n, const char_type a); +}; + +struct char_traits { + typedef char char_type; + typedef int int_type; + +#ifdef __CINT__ + typedef streamoff off_type; + typedef streampos pos_type; + typedef mbstate_t state_type; +#endif + static void assign (char_type& c1, const char_type& c2) ; + static char_type to_char_type(const int_type& c); + static int_type to_int_type(const char_type& c); + static bool eq(const char_type& c1,const char_type& c2); + static bool lt (const char_type& c1, const char_type& c2) ; + static int compare (const char_type* s1, const char_type* s2, size_t n); + static const char_type* find (const char_type* s,int n,const char_type& a); + static bool eq_int_type(const int_type& c1,const int_type& c2); + static int_type eof(); + static int_type not_eof(const int_type& c); + static size_t length(const char_type *s); + static char_type *copy(char_type *dst,const char_type *src, size_t n); + static char_type * move (char_type* s1, const char_type* s2, size_t n); + static char_type* assign (char_type* s, size_t n, const char_type a); +}; + +//typedef basic_istream > istream; +typedef basic_istream > istream; +//typedef basic_ostream ostream; +typedef basic_ostream > ostream; + +typedef basic_streambuf > streambuf; + +extern istream cin ; +extern ostream cout ; +extern ostream cerr ; +extern ostream clog ; + +#ifndef G__OLDIMPLEMENTATION1938 +ios_base& dec(ios_base&) ; +ios_base& hex(ios_base&) ; +ios_base& oct(ios_base&) ; +ios_base& fixed(ios_base&); +ios_base& scientific(ios_base&); +ios_base& right(ios_base&); +ios_base& left(ios_base&); +ios_base& internal(ios_base&); +ios_base& nouppercase(ios_base&); +ios_base& uppercase(ios_base&); +ios_base& noskipws(ios_base&); +ios_base& skipws(ios_base&); +ios_base& noshowpos(ios_base&); +ios_base& showpos(ios_base&); +ios_base& noshowpoint(ios_base&); +ios_base& showpoint(ios_base&); +ios_base& noshowbase(ios_base&); +ios_base& showbase(ios_base&); +ios_base& noboolalpha(ios_base&); +ios_base& boolalpha(ios_base&); +#endif + +istream& ws(istream&) ; + +ostream& endl(ostream& i) ; +ostream& ends(ostream& i) ; +ostream& flush(ostream&) ; + +ostream& operator<< ( ostream&, char ); +ostream& operator<< ( ostream&, char* ); +ostream& operator<< ( ostream&, void* ); +ostream& operator<< ( ostream&, unsigned char ); +ostream& operator<< ( ostream&, short ); +ostream& operator<< ( ostream&, unsigned short ); +ostream& operator<< ( ostream&, int ); +ostream& operator<< ( ostream&, unsigned int ); +ostream& operator<< ( ostream&, long ); +ostream& operator<< ( ostream&, unsigned long); +ostream& operator<< ( ostream&, float ); +ostream& operator<< ( ostream&, double ); +//ostream& operator<< ( ostream&, long double ); +ostream& operator<< ( ostream&, bool ); +//ostream& operator<< (ostream&,const streampos&); + +istream& operator>> ( istream&, char& ); +istream& operator>> ( istream&, unsigned char& ); +istream& operator>> ( istream&, short& ); +istream& operator>> ( istream&, unsigned short& ); +istream& operator>> ( istream&, int& ); +istream& operator>> ( istream&, unsigned int& ); +istream& operator>> ( istream&, long& ); +istream& operator>> ( istream&, unsigned long& ); +istream& operator>> ( istream&, float& ); +istream& operator>> ( istream&, double& ); +//istream& operator>> ( istream&, long double& ); +istream& operator>> ( istream&, bool& ); +istream& operator>> ( istream&, char* ); +istream& operator>> ( istream&, void*& ); + +#endif // __CINT__ + +#endif // G__IOSTREAM_H diff --git a/cint/cint/lib/libcxxstrm/linkdef.h b/cint/cint/lib/libcxxstrm/linkdef.h new file mode 100644 index 0000000000000..cb1f7f34a230e --- /dev/null +++ b/cint/cint/lib/libcxxstrm/linkdef.h @@ -0,0 +1,15 @@ +/* -*- C++ -*- */ +/************************************************************************* + * Copyright(c) 2007 Masaharu Goto (root-cint@cern.ch) + * + * For the licensing terms see the file COPYING + * + ************************************************************************/ + +#ifdef __MAKECINT__ + +#pragma link off class allocator; +#pragma link off class allocator; +#pragma link MACRO function char_traits::assign(char_type*,size_t,const char_type); + +#endif diff --git a/cint/cint/lib/libcxxstrm/sstrm.h b/cint/cint/lib/libcxxstrm/sstrm.h new file mode 100644 index 0000000000000..45c86e6306e4d --- /dev/null +++ b/cint/cint/lib/libcxxstrm/sstrm.h @@ -0,0 +1,210 @@ +/* /% C++ %/ */ +/*********************************************************************** + * cint (C/C++ interpreter) + ************************************************************************ + * header file sstrm.h + ************************************************************************ + * Description: + * Stub file for making iostream library + ************************************************************************ + * Copyright(c) 2007 Masaharu Goto + * + * For the licensing terms see the file COPYING + * + ************************************************************************/ + +#ifndef G__SSTREAM_H +#define G__SSTREAM_H + +#ifndef __CINT__ + +#include +using namespace std; + +#else // __CINT__ + +#if !(G__GNUC>=3) +#error This header must be processed with a Cint compiled with gcc3.x +#endif + +#include +//#include +class allocator; +class allocator; +#include "iostrm.h" + +template +class basic_stringbuf : public basic_streambuf +{ + public: + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + typedef traits traits_type; + + typedef basic_ios ios_type; +#ifdef __CINT__ + typedef string string_type; +#else + typedef basic_string string_type; +#endif + + explicit basic_stringbuf(ios_base::openmode which = + ios_base::in | ios_base::out ); + + explicit basic_stringbuf(const string_type& str, + ios_base::openmode which = + ios_base::in | ios_base::out ); + + virtual ~basic_stringbuf(); + + string_type str() const; + void str(const string_type& str_arg); + + protected: + + virtual int_type overflow(int_type c = traits::eof()); + virtual int_type pbackfail(int_type c = traits::eof()); + virtual int_type underflow(); + virtual pos_type seekoff(off_type off, ios_base::seekdir way, + ios_base::openmode which = + ios_base::in | ios_base::out); + + virtual pos_type seekpos(pos_type sp, + ios_base::openmode which = + ios_base::in | ios_base::out); + + virtual basic_streambuf* setbuf(char_type* s, streamsize n); + virtual streamsize xsputn(const char_type *s, streamsize n); +#if (G__GNUC>=3) + private: + basic_stringbuf& operator=(const basic_stringbuf& x); +#endif +}; + + +template +class basic_istringstream : public basic_istream +{ + public: + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + typedef traits traits_type; + + typedef basic_stringbuf sb_type; + typedef basic_ios ios_type; +#ifdef __CINT__ + typedef string string_type; +#else + typedef basic_string string_type; +#endif + + explicit basic_istringstream(ios_base::openmode which = ios_base::in); + explicit basic_istringstream(const string_type& str, + ios_base::openmode which = ios_base::in); +#ifdef __CINT__ + explicit basic_istringstream(const char *str, + ios_base::openmode which = ios_base::in); +#endif + + virtual ~basic_istringstream(); + + basic_stringbuf *rdbuf() const; + string_type str() const; + + void str(const string_type& str); +}; + + +template +class basic_ostringstream : public basic_ostream +{ + public: + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + typedef traits traits_type; + + typedef basic_stringbuf sb_type; + typedef basic_ios ios_type; +#ifdef __CINT__ + typedef string string_type; +#else + typedef basic_string string_type; +#endif + + explicit basic_ostringstream(ios_base::openmode which = ios_base::out); + explicit basic_ostringstream(const string_type& str, + ios_base::openmode which = ios_base::out); + + virtual ~basic_ostringstream(); + basic_stringbuf *rdbuf() const; + + string_type str() const; + void str(const string_type& str); +}; + + +template +class basic_stringstream : public basic_iostream +{ + public: + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + typedef traits traits_type; + + typedef basic_stringbuf sb_type; + typedef basic_ios ios_type; +#ifdef __CINT__ + typedef string string_type; +#else + typedef basic_string string_type; +#endif + + explicit basic_stringstream(ios_base::openmode which = ios_base::out | + ios_base::in); + + explicit basic_stringstream(const string_type& str, + ios_base::openmode which = + ios_base::out | ios_base::in); + + virtual ~basic_stringstream(); + basic_stringbuf *rdbuf() const; + string_type str() const; + void str(const string_type& str); +}; + + +//typedef basic_stringbuf stringbuf; +typedef basic_stringbuf,allocator > stringbuf; + +//typedef basic_stringbuf wstringbuf; +//typedef basic_stringbuf,allocator > wstringbuf; + +//typedef basic_istringstream istringstream; +typedef basic_istringstream,allocator > istringstream; + +//typedef basic_istringstream wistringstream; +//typedef basic_istringstream,allocator > wistringstream; + +//typedef basic_ostringstream ostringstream; +typedef basic_ostringstream,allocator > ostringstream; + +//typedef basic_ostringstream wostringstream; +//typedef basic_ostringstream,allocator > wostringstream; + +//typedef basic_stringstream stringstream; +typedef basic_stringstream,allocator > stringstream; + +//typedef basic_stringstream wstringstream; +//typedef basic_stringstream, allocator > wstringstream; + +#endif // __CINT__ + +#endif // G__SSTREAM_H diff --git a/cint/cint/lib/posix/exten.c b/cint/cint/lib/posix/exten.c index e14a10e26d8a9..3e4a2b670feed 100644 --- a/cint/cint/lib/posix/exten.c +++ b/cint/cint/lib/posix/exten.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/posix/exten.h b/cint/cint/lib/posix/exten.h index 16877603393a7..09aaa0d9ed544 100644 --- a/cint/cint/lib/posix/exten.h +++ b/cint/cint/lib/posix/exten.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/posix/winposix.c b/cint/cint/lib/posix/winposix.c index d0002f46e8b70..7fab24f29f4f7 100644 --- a/cint/cint/lib/posix/winposix.c +++ b/cint/cint/lib/posix/winposix.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/posix/winposix.h b/cint/cint/lib/posix/winposix.h index 11c8fee0b213d..2d903b40319d7 100644 --- a/cint/cint/lib/posix/winposix.h +++ b/cint/cint/lib/posix/winposix.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/algorithm b/cint/cint/lib/prec_stl/algorithm index 23c44e8caf106..73239dcbaf612 100644 --- a/cint/cint/lib/prec_stl/algorithm +++ b/cint/cint/lib/prec_stl/algorithm @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/bitset b/cint/cint/lib/prec_stl/bitset index 602809ee77758..c17605152b2f3 100644 --- a/cint/cint/lib/prec_stl/bitset +++ b/cint/cint/lib/prec_stl/bitset @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/climits b/cint/cint/lib/prec_stl/climits index 57809404644c7..5059a54a962b7 100644 --- a/cint/cint/lib/prec_stl/climits +++ b/cint/cint/lib/prec_stl/climits @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/complex b/cint/cint/lib/prec_stl/complex index 5e679b70f5ee9..55283846c0c42 100644 --- a/cint/cint/lib/prec_stl/complex +++ b/cint/cint/lib/prec_stl/complex @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/deque b/cint/cint/lib/prec_stl/deque index 5483658bbd49a..a80f42cc8928c 100644 --- a/cint/cint/lib/prec_stl/deque +++ b/cint/cint/lib/prec_stl/deque @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/exception b/cint/cint/lib/prec_stl/exception index b0eb43c0dc527..6657bbd4bfa90 100644 --- a/cint/cint/lib/prec_stl/exception +++ b/cint/cint/lib/prec_stl/exception @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/functional b/cint/cint/lib/prec_stl/functional index a78b1592d181e..460428000c776 100644 --- a/cint/cint/lib/prec_stl/functional +++ b/cint/cint/lib/prec_stl/functional @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/iterator b/cint/cint/lib/prec_stl/iterator index 7cb177882eedb..e3f9a6f046d8c 100644 --- a/cint/cint/lib/prec_stl/iterator +++ b/cint/cint/lib/prec_stl/iterator @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/limits b/cint/cint/lib/prec_stl/limits index df5812f6ca53d..351400d70e280 100644 --- a/cint/cint/lib/prec_stl/limits +++ b/cint/cint/lib/prec_stl/limits @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/list b/cint/cint/lib/prec_stl/list index b0be98044950e..a5fbbe86e3b48 100644 --- a/cint/cint/lib/prec_stl/list +++ b/cint/cint/lib/prec_stl/list @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -96,8 +96,10 @@ class list { iterator operator++(int a); iterator& operator--(); iterator operator--(int a); +#ifndef G__APPLE_LIBCXX bool operator==(const iterator& x) ; -#ifndef G__HPUX +#endif +#if !defined(G__HPUX) && !defined(G__APPLE_LIBCXX) bool operator!=(const iterator& x) ; #endif #if defined(G__VISUAL) && (G__MSC_VER>=1600) @@ -105,6 +107,10 @@ class list { void* _Ptr; #endif }; +#ifdef G__APPLE_LIBCXX + friend bool operator==(const list::iterator& x,const list::iterator& y)const; + friend bool operator!=(const list::iterator& x,const list::iterator& y)const; +#endif #ifdef G__HPUX friend bool operator!=(const list::iterator& x,const list::iterator& y)const; #endif diff --git a/cint/cint/lib/prec_stl/map b/cint/cint/lib/prec_stl/map index 2781d657dc8b2..49e1f74f048dd 100644 --- a/cint/cint/lib/prec_stl/map +++ b/cint/cint/lib/prec_stl/map @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -116,14 +116,16 @@ class map { iterator& operator--(); iterator operator--(int a); #if defined (G__VISUAL) || (defined(G__GNUC_VER) && G__GNUC_VER>=3004) || defined(G__INTEL_COMPILER) +#if !defined(G__APPLE_LIBCXX) bool operator==(const iterator& x) ; bool operator!=(const iterator& x) ; #endif +#endif #ifdef G__HPUX bool operator==(const iterator& x) ; #endif }; -#if defined(G__GNUC) && !defined(G__KCC) && !defined(G__INTEL_COMPILER) && !(G__GNUC_VER>=3004) +#if (defined(G__GNUC) && !defined(G__KCC) && !defined(G__INTEL_COMPILER) && !(G__GNUC_VER>=3004)) || defined(G__APPLE_LIBCXX) friend bool operator==(const map::iterator& x ,const map::iterator& y) const; friend bool operator!=(const map::iterator& x ,const map::iterator& y) const; #endif diff --git a/cint/cint/lib/prec_stl/memory b/cint/cint/lib/prec_stl/memory index f8240eb8269f9..90f7f196866a2 100644 --- a/cint/cint/lib/prec_stl/memory +++ b/cint/cint/lib/prec_stl/memory @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/multimap b/cint/cint/lib/prec_stl/multimap index 0fdd7d419e44e..4b442dd874a81 100644 --- a/cint/cint/lib/prec_stl/multimap +++ b/cint/cint/lib/prec_stl/multimap @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -113,14 +113,16 @@ class multimap { iterator& operator--(); iterator operator--(int a); #if defined (G__VISUAL) || (defined(G__GNUC) && G__GNUC_VER>=3004) +#if !defined(G__APPLE_LIBCXX) bool operator==(const iterator& x) ; bool operator!=(const iterator& x) ; #endif +#endif #ifdef G__HPUX bool operator==(const iterator& x) ; #endif }; -#if defined(G__GNUC) && !defined (G__KCC) && !defined(G__INTEL_COMPILER) && !(G__GNUC_VER>=3004) +#if (defined(G__GNUC) && !defined (G__KCC) && !defined(G__INTEL_COMPILER) && !(G__GNUC_VER>=3004)) || defined(G__APPLE_LIBCXX) friend bool operator==(const multimap::iterator& x ,const multimap::iterator& y) const; friend bool operator!=(const multimap::iterator& x ,const multimap::iterator& y) const; #endif diff --git a/cint/cint/lib/prec_stl/multiset b/cint/cint/lib/prec_stl/multiset index 2156ff8a70e8f..250b507ded406 100644 --- a/cint/cint/lib/prec_stl/multiset +++ b/cint/cint/lib/prec_stl/multiset @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -106,14 +106,16 @@ class multiset { iterator& operator--(); iterator operator--(int a); #if defined (G__VISUAL) || (defined(G__GNUC) && G__GNUC_VER>=3004) +#if !defined(G__APPLE_LIBCXX) bool operator==(const iterator& x) ; bool operator!=(const iterator& x) ; #endif +#endif #ifdef G__HPUX bool operator==(const iterator& x) ; #endif }; -#if (defined(G__GNUC) && !defined (G__KCC) && !defined(G__INTEL_COMPILER)) && !(G__GNUC_VER>=3004) +#if ((defined(G__GNUC) && !defined (G__KCC) && !defined(G__INTEL_COMPILER)) && !(G__GNUC_VER>=3004)) || defined(G__APPLE_LIBCXX) friend bool operator==(const multiset::iterator& x ,const multiset::iterator& y) const; friend bool operator!=(const multiset::iterator& x ,const multiset::iterator& y) const; #endif diff --git a/cint/cint/lib/prec_stl/numeric b/cint/cint/lib/prec_stl/numeric index ef709b093cf11..f5c4013210603 100644 --- a/cint/cint/lib/prec_stl/numeric +++ b/cint/cint/lib/prec_stl/numeric @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/queue b/cint/cint/lib/prec_stl/queue index e3621e1efc0e5..004bdf358ccb7 100644 --- a/cint/cint/lib/prec_stl/queue +++ b/cint/cint/lib/prec_stl/queue @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/set b/cint/cint/lib/prec_stl/set index 9095857dacc4e..c1e7948befa0d 100644 --- a/cint/cint/lib/prec_stl/set +++ b/cint/cint/lib/prec_stl/set @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -106,14 +106,16 @@ class set { iterator& operator--(); iterator operator--(int a); #if defined (G__VISUAL) || (defined(G__GNUC) && G__GNUC_VER>=3004) +#if !defined(G__APPLE_LIBCXX) bool operator==(const iterator& x) ; bool operator!=(const iterator& x) ; #endif +#endif #ifdef G__HPUX bool operator==(const iterator& x) ; #endif }; -#if defined(G__GNUC) && !defined(G__KCC) && !defined(G__INTEL_COMPILER) && !(G__GNUC_VER>=3004) +#if (defined(G__GNUC) && !defined(G__KCC) && !defined(G__INTEL_COMPILER) && !(G__GNUC_VER>=3004)) || defined(G__APPLE_LIBCXX) friend bool operator==(const set::iterator& x ,const set::iterator& y) const; friend bool operator!=(const set::iterator& x ,const set::iterator& y) const; #endif diff --git a/cint/cint/lib/prec_stl/stack b/cint/cint/lib/prec_stl/stack index 4ec53475c99a6..7bb4576b1dc1f 100644 --- a/cint/cint/lib/prec_stl/stack +++ b/cint/cint/lib/prec_stl/stack @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/stdexcept b/cint/cint/lib/prec_stl/stdexcept index 27f5f9670a6fd..b3092247a6665 100644 --- a/cint/cint/lib/prec_stl/stdexcept +++ b/cint/cint/lib/prec_stl/stdexcept @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/string b/cint/cint/lib/prec_stl/string index 6198956519b3a..21bf0ec0d54f5 100644 --- a/cint/cint/lib/prec_stl/string +++ b/cint/cint/lib/prec_stl/string @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/utility b/cint/cint/lib/prec_stl/utility index b140b4ff89d9f..797adcad5b9f4 100644 --- a/cint/cint/lib/prec_stl/utility +++ b/cint/cint/lib/prec_stl/utility @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/valarray b/cint/cint/lib/prec_stl/valarray index dc3be565c35d4..d360bbb86b617 100644 --- a/cint/cint/lib/prec_stl/valarray +++ b/cint/cint/lib/prec_stl/valarray @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/prec_stl/vector b/cint/cint/lib/prec_stl/vector index de16e3ba4377d..820a28e8e7fe2 100644 --- a/cint/cint/lib/prec_stl/vector +++ b/cint/cint/lib/prec_stl/vector @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -210,6 +210,57 @@ class vector { typedef std::reverse_iterator reverse_iterator; typedef std::reverse_iterator const_reverse_iterator; +#elif (defined(G__APPLE_LIBCXX)) + +#define G__VECTOR_HAS_CLASS_ITERATOR + + class iterator { + public: + typedef vector::pointer pointer; + typedef vector::const_pointer const_pointer; + typedef vector::reference reference; + typedef vector::const_reference const_reference; + typedef vector::size_type size_type; + typedef vector::difference_type difference_type; + + iterator(); + //explicit iterator(const pointer& __i) ; + // Allow iterator to const_iterator conversion + template inline iterator(const iterator& __i); + + // Forward iterator requirements + reference operator*() const ; + pointer operator->() const ; + iterator& operator++(); + iterator operator++(int) ; + + // Bidirectional iterator requirements + iterator& operator--() ; + iterator operator--(int) ; + + // Random access iterator requirements + reference operator[](const difference_type& __n) const; + iterator& operator+=(const difference_type& __n); + iterator operator+(const difference_type& __n) const; + iterator& operator-=(const difference_type& __n); + iterator operator-(const difference_type& __n) const; + const pointer& base() const ; +#ifndef G__OLDIMPLEMENTATION2165 + iterator operator=(const iterator& x) ; +#endif + }; + + friend bool operator==(const vector::iterator& x,const vector::iterator& y)const; + friend bool operator!=(const vector::iterator& x,const vector::iterator& y)const; + friend bool operator<(const vector::iterator& x,const vector::iterator& y)const; + friend bool operator>(const vector::iterator& x,const vector::iterator& y)const; + friend bool operator<=(const vector::iterator& x,const vector::iterator& y)const; + friend bool operator>=(const vector::iterator& x,const vector::iterator& y)const; + friend vector::iterator::difference_type operator-(const vector::iterator& x,const vector::iterator& y)const; + friend vector::iterator operator+(const vector::iterator::difference_type x,const vector::iterator& y)const; + + typedef const iterator const_iterator; + #elif (!defined(G__INTEL_COMPILER) && (G__GNUC_VER>3001)) #define G__VECTOR_HAS_CLASS_ITERATOR @@ -740,11 +791,18 @@ template > class vector { class reference { //friend class vector; reference(); + reference(const reference&); +#ifdef G__APPLE_LIBCXX + reference& operator=(const bool x); + reference& operator=(const reference& x); +#endif public: ~reference(); operator bool() const; +#ifndef G__APPLE_LIBCXX reference& operator=(const bool x); reference& operator=(const reference& x); +#endif void flip(); // flips the bit }; // construct/copy/destroy: diff --git a/cint/cint/lib/pthread/setuphp b/cint/cint/lib/pthread/setuphp index 5ca34cd48f342..51a68e8de7c15 100644 --- a/cint/cint/lib/pthread/setuphp +++ b/cint/cint/lib/pthread/setuphp @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/pthread/thread.h b/cint/cint/lib/pthread/thread.h index b146ceba2db0c..5ae780cd61dda 100644 --- a/cint/cint/lib/pthread/thread.h +++ b/cint/cint/lib/pthread/thread.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/qt/qcompactstyle.h b/cint/cint/lib/qt/qcompactstyle.h index b89f549f29eab..8574a5d16ff6a 100644 --- a/cint/cint/lib/qt/qcompactstyle.h +++ b/cint/cint/lib/qt/qcompactstyle.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/qt/qconfig.h b/cint/cint/lib/qt/qconfig.h index 5dfe4eb898e23..b95252e9227b1 100644 --- a/cint/cint/lib/qt/qconfig.h +++ b/cint/cint/lib/qt/qconfig.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/qt/qmodules.h b/cint/cint/lib/qt/qmodules.h index afe07601fc663..a749b803efdc9 100644 --- a/cint/cint/lib/qt/qmodules.h +++ b/cint/cint/lib/qt/qmodules.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/qt/qplatformdefs.h b/cint/cint/lib/qt/qplatformdefs.h index afe07601fc663..a749b803efdc9 100644 --- a/cint/cint/lib/qt/qplatformdefs.h +++ b/cint/cint/lib/qt/qplatformdefs.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/qt/qtcint.h b/cint/cint/lib/qt/qtcint.h index 2d537daad7664..901f9808d858a 100644 --- a/cint/cint/lib/qt/qtcint.h +++ b/cint/cint/lib/qt/qtcint.h @@ -1,5 +1,5 @@ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/qt/qtdummy.h b/cint/cint/lib/qt/qtdummy.h index a5d87f1e39d0e..00071d251376f 100644 --- a/cint/cint/lib/qt/qtdummy.h +++ b/cint/cint/lib/qt/qtdummy.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/qt/qtfunctions.h b/cint/cint/lib/qt/qtfunctions.h index f2775a7f22979..f17764829e889 100644 --- a/cint/cint/lib/qt/qtfunctions.h +++ b/cint/cint/lib/qt/qtfunctions.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/qt/qtglobals.h b/cint/cint/lib/qt/qtglobals.h index d8df6352bb76e..16b0343209095 100644 --- a/cint/cint/lib/qt/qtglobals.h +++ b/cint/cint/lib/qt/qtglobals.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/qt/qtstatic.cxx b/cint/cint/lib/qt/qtstatic.cxx index 2e8cf456b1b44..7946ec39854fa 100644 --- a/cint/cint/lib/qt/qtstatic.cxx +++ b/cint/cint/lib/qt/qtstatic.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/socket/cintsock.c b/cint/cint/lib/socket/cintsock.c index 0e090d439213e..d622bea553921 100644 --- a/cint/cint/lib/socket/cintsock.c +++ b/cint/cint/lib/socket/cintsock.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/socket/cintsock.h b/cint/cint/lib/socket/cintsock.h index 4afd86a5feb92..4f27f2cc32eba 100644 --- a/cint/cint/lib/socket/cintsock.h +++ b/cint/cint/lib/socket/cintsock.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/socket/mksockh.c b/cint/cint/lib/socket/mksockh.c index 73732aea3b974..1292fb40715e1 100644 --- a/cint/cint/lib/socket/mksockh.c +++ b/cint/cint/lib/socket/mksockh.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/stlport4strm/fstrm.h b/cint/cint/lib/stlport4strm/fstrm.h index 3c1c43e633bec..16a4723ab9ad2 100644 --- a/cint/cint/lib/stlport4strm/fstrm.h +++ b/cint/cint/lib/stlport4strm/fstrm.h @@ -7,7 +7,7 @@ * Description: * Stub file for making iostream library ************************************************************************ - * Copyright(c) 2007 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 2007 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/stlport4strm/length.cxx b/cint/cint/lib/stlport4strm/length.cxx index 8c609e7a2aa43..77d8956b429c1 100644 --- a/cint/cint/lib/stlport4strm/length.cxx +++ b/cint/cint/lib/stlport4strm/length.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/stlport4strm/linkdef.h b/cint/cint/lib/stlport4strm/linkdef.h index 870645814feb3..cb1f7f34a230e 100644 --- a/cint/cint/lib/stlport4strm/linkdef.h +++ b/cint/cint/lib/stlport4strm/linkdef.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 2007 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 2007 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/sunstrm/length.cxx b/cint/cint/lib/sunstrm/length.cxx index 8c609e7a2aa43..77d8956b429c1 100644 --- a/cint/cint/lib/sunstrm/length.cxx +++ b/cint/cint/lib/sunstrm/length.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/sunstrm/linkdef.h b/cint/cint/lib/sunstrm/linkdef.h index 9ff0dace338c0..074ed48996084 100644 --- a/cint/cint/lib/sunstrm/linkdef.h +++ b/cint/cint/lib/sunstrm/linkdef.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/vc10strm/linkdef.h b/cint/cint/lib/vc10strm/linkdef.h index 9ff0dace338c0..074ed48996084 100644 --- a/cint/cint/lib/vc10strm/linkdef.h +++ b/cint/cint/lib/vc10strm/linkdef.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/vc11strm/G__stream.def b/cint/cint/lib/vc11strm/G__stream.def new file mode 100644 index 0000000000000..73904425dc1ac --- /dev/null +++ b/cint/cint/lib/vc11strm/G__stream.def @@ -0,0 +1,22 @@ +NAME "" WINDOWAPI + +VERSION 1.0 + +HEAPSIZE 1048576,4096 + +EXPORTS + G__cpp_dllrevG__stream @1 + G__set_cpp_environmentG__stream @2 + G__cpp_setup_tagtableG__stream @3 + G__cpp_setup_inheritanceG__stream @4 + G__cpp_setup_typetableG__stream @5 + G__cpp_setup_memvarG__stream @6 + G__cpp_setup_memfuncG__stream @7 + G__cpp_setup_globalG__stream @8 + G__cpp_setup_funcG__stream @9 + G__cpp_setupG__stream @10 + cin @11 + cout @12 + cerr @13 + clog @14 + diff --git a/cint/cint/lib/vc11strm/Makefile b/cint/cint/lib/vc11strm/Makefile new file mode 100644 index 0000000000000..31ed805666b59 --- /dev/null +++ b/cint/cint/lib/vc11strm/Makefile @@ -0,0 +1,30 @@ +# +# lib/snstream/Makefile +# +#CP = copy +#MV = move +CP = cp +MV = mv + +CINTSYSDIR = ../.. + +SRCCPPIFC = $(CINTSYSDIR)/src/vc7strm.cxx +SRCCPPIFH = $(CINTSYSDIR)/src/vc7strm.h +CPPIFC = vc7strm.cxx +CPPIFH = vc7strm.h + +CPPHEADER = iostrm.h fstrm.h sstrm.h linkdef.h + +# stdiostr.h \ + + +$(SRCCPPIFC) : $(CPPIFC) + cint ../snstream/length.cxx 255 $(CPPIFC) $(CPPIFH) +# $(MV) $(CPPIFC) $(SRCCPPIFC) +# $(MV) $(CPPIFH) $(SRCCPPIFH) + + +$(CPPIFC) : $(CPPHEADER) + cint -Z0 -n$(CPPIFC) -NG__stream $(DLLSPEC) -D__MAKECINT__ -DG__MAKECINT -c-1 $(IPATH) $(MACRO) $(CPPHEADER) + +# cint -Z0 -n$(CPPIFC) -NG__stream $(DLLSPEC) -D__MAKECINT__ -DG__MAKECINT -M0x10 -c-1 $(IPATH) $(MACRO) $(CPPHEADER) diff --git a/cint/cint/lib/vc11strm/README.txt b/cint/cint/lib/vc11strm/README.txt new file mode 100644 index 0000000000000..10d8ebb223319 --- /dev/null +++ b/cint/cint/lib/vc11strm/README.txt @@ -0,0 +1,33 @@ +lib/iccstrm/README + +lib/iccstrm directory exists for creating iostream library linkage file +src/iccstrm.cxx and src/iccstrm.h for Intel icc (IA-32) and ecc (IA-64) +compilers. These files contain interface methods for iostream library. +You can create those by doing 'make' under this directory. Usually nobody +but only author should do this. User doesn't need to recognize this. +Files in this directory are originally copied from lib/gcc3strm/* and +modified for iccstrm. + + cbstream.cpp is based on template based stream library. + + Creating src/iccstrm.cxx + + 1) Just do 'make' in this directory. + I think we can forget all below because of new new/delete scheme. + + ................................................................... + + 1) Edit src/newlink.c + Start a text editor, look for '#define G__N_EXPLICITDESTRUCTOR'. Please + comment this line out. + + 2) Create special 'cint' + Go back to $CINTSYSDIR and do make to create special 'cint'. You may need + to specify src/fakestrm.cxx in src/Makefile. + + 3) Come to src/snstream directory and do make to create src/snstrm.cxx. + + 4) Edit src/newlink.c + Edit src/newlink.c and restore '#define G__N_EXPLICITDESTRUCTOR' macro. + + 5) Go back to $CINTSYSDIR and do make to create updated cint. diff --git a/cint/cint/lib/vc11strm/cint_process_file.ps1 b/cint/cint/lib/vc11strm/cint_process_file.ps1 new file mode 100644 index 0000000000000..6bd196e38dad1 --- /dev/null +++ b/cint/cint/lib/vc11strm/cint_process_file.ps1 @@ -0,0 +1,41 @@ +# +# Run CINT (from a given directory, hardcoded) and put the output into a text +# file. Run this guy repeatedly until you can compile cint again! +# +# This proceedure is taken from: +# +# http://root.cern.ch/gitweb?p=root.git;a=blob;f=cint/cint/lib/stream/README;h=d4be99ae32ff4d9e7859470a0f6a837549743590;hb=292cc26d3ef32452f60e3db36a7860ba6b64632c +# + +# Where CINT was built with fakestrm - note this in DebugFake!! So make sure to make a copy. + +$cintbin = "C:\Users\Gordon\Documents\Code\root\vc11\bin\DebugFake" + +# +# We want includes and other things to come from the same directory as where we are sitting. So figure out +# what directory we are running in! To avoid space issues, we just set the current directory to be +# that location and run cint from there. +# +# Warning: I think $MyInvocation is only available at the top level (you'll have to use Get-variable if you wrap this). +# + +$scriptDir = Split-Path $MyInvocation.MyCommand.Path +Set-Location $scriptDir + +# +# We can just run CINT here because the dll's is needs are sitting in the same directory. +# + +$logfile = "cint-log.txt" +if (test-path $logfile) { + rm $logfile +} + +$includes = "iostrm.h", "fstrm.h", "sstrm.h", "linkdef.h" + +#& "$($cintbin)\cint.exe" -? +& "$($cintbin)\cint.exe" -Z0 -n vc11strm.cxx -NG__stream -D__MAKECINT__ -D_WIN32 -c-1 -I . -I ..\..\include $includes 2>&1 | add-content -path $logfile + +if (test-path vc11strm.cxx) { + cp vc11strm.* ..\..\src\dict +} diff --git a/cint/cint/lib/vc11strm/fstrm.h b/cint/cint/lib/vc11strm/fstrm.h new file mode 100644 index 0000000000000..e9dc58e7d7222 --- /dev/null +++ b/cint/cint/lib/vc11strm/fstrm.h @@ -0,0 +1,123 @@ +/* /% C++ %/ */ +/*********************************************************************** + * cint (C/C++ interpreter) + ************************************************************************ + * header file fstrm.h + ************************************************************************ + * Description: + * Stub file for making iostream library + ************************************************************************ + * Copyright(c) 1999 Masaharu Goto (MXJ02154@niftyserve.or.jp) + * + * For the licensing terms see the file COPYING + * + ************************************************************************/ + +#ifndef G__FSTREAM_H +#define G__FSTREAM_H + +#ifndef __CINT__ + +#include +using namespace std; + +#else // __CINT__ + +#include "iostrm.h" + +template +class basic_filebuf : public basic_streambuf { + private: + typedef basic_ios ios_type; +#ifndef __CINT__ + typedef traits::state_type state_t; +#endif + public: + typedef traits traits_type; + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + basic_filebuf(); + virtual ~basic_filebuf(); + bool is_open() const; + basic_filebuf * open(const char *s, ios_base::openmode); + basic_filebuf *close(); + protected: + virtual int showmanyc(); + virtual int_type overflow(int_type c = traits::eof()); + virtual int_type pbackfail(int_type c = traits::eof()); + virtual int_type underflow(); + virtual basic_streambuf* setbuf(char_type *s,streamsize n); + virtual pos_type seekoff(off_type off,ios_base::seekdir way + ,ios_base::openmode which = + ios_base::in | ios_base::out); + virtual pos_type seekpos(pos_type sp + ,ios_base::openmode which = + ios_base::in | ios_base::out); + virtual int sync(); + virtual streamsize xsputn(const char_type *s, streamsize n); + private: + basic_filebuf& operator=(const basic_filebuf& x); +}; + +template +class basic_ifstream : public basic_istream { + public: + typedef basic_ios ios_type; + typedef traits traits_type; + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + public: + basic_ifstream(); + basic_ifstream(const char *s,ios_base::openmode mode = ios_base::in); + virtual ~basic_ifstream(); + basic_filebuf *rdbuf() const; + bool is_open(); + void open(const char *s, ios_base::openmode mode = ios_base::in); + void close(); +}; + +template +class basic_ofstream : public basic_ostream { + public: + typedef basic_ios ios_type; + typedef traits traits_type; + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + public: + basic_ofstream(); + basic_ofstream(const char *s, ios_base::openmode mode=ios_base::out); + virtual ~basic_ofstream(); + basic_filebuf *rdbuf() const; + bool is_open(); + void open(const char *s,ios_base::openmode mode=ios_base::out); + void close(); + }; + +template +class basic_fstream : public basic_iostream { + public: + basic_fstream(); + basic_fstream(const char *s,ios_base::openmode mode); + basic_filebuf *rdbuf() const; + bool is_open(); + void open(const char *s,ios_base::openmode mode); + void close(); +}; + +typedef basic_filebuf > filebuf; +//typedef basic_filebuf > wfilebuf; +typedef basic_ifstream > ifstream; +//typedef basic_ifstream > wifstream; +typedef basic_ofstream > ofstream; +//typedef basic_ofstream > wofstream; +typedef basic_fstream > fstream; +//typedef basic_fstream > wfstream; + +#endif // __CINT__ +#endif // G__FSTREAM_H diff --git a/cint/cint/lib/vc11strm/iostrm.h b/cint/cint/lib/vc11strm/iostrm.h new file mode 100644 index 0000000000000..8e8ee57c83fa9 --- /dev/null +++ b/cint/cint/lib/vc11strm/iostrm.h @@ -0,0 +1,619 @@ +/* /% C++ %/ */ +/*********************************************************************** + * cint (C/C++ interpreter) + ************************************************************************ + * header file iostrm.h + ************************************************************************ + * Description: + * Stub file for making iostream library for ICC (Intel compiler) + ************************************************************************ + * Copyright(c) 2001-2002 Masaharu Goto (MXJ02154@niftyserve.or.jp) + * + * For the licensing terms see the file COPYING + * + ************************************************************************/ + +#ifndef G__IOSTREAM_H +#define G__IOSTREAM_H + +#define G__TMPLTIOS + +#define G__OSTREAMBODY +//#define G__OSTREAMMEMBERSTUB +#define G__OSTREAMGLOBALSTUB + +#ifndef __CINT__ + +#include +using namespace std; + +//inline ostream& operator<< (ostream& ost,unsigned char c) +// {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,short c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,unsigned short c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,int c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,unsigned int c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,long c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,unsigned long c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,float c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,double c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,long double c) + {return(ost.operator<<(c));} +inline ostream& operator<< (ostream& ost,bool c) + {return(ost.operator<<(c));} +#if 0 +inline ostream& operator<< ( ostream& ost, void* p) + {return(ost.operator<<(p));} +#endif + +#if 0 +//inline istream& operator>> ( istream& ist, unsigned char& p) +// {return(ist.operator>>(p));} + +inline istream& operator>> ( istream& ist, short& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, unsigned short& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, int & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, unsigned int& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, long & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, unsigned long& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, float & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, double & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, bool& p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, long double & p) + {return(ist.operator>>(p));} +inline istream& operator>> ( istream& ist, void*& p) + {return(ist.operator>>(p));} +#endif + +#ifndef G__OLDIMPLEMENTATION1635 +#include +/******************************************************************** + * static variables for iostream redirection + ********************************************************************/ +static ostream::_Mysb *G__store_cout; +static ostream::_Mysb *G__store_cerr; +static istream::_Mysb *G__store_cin; +static ofstream *G__redirected_cout; +static ofstream *G__redirected_cerr; +static ifstream *G__redirected_cin; +/******************************************************************** + * G__redirectcout + ********************************************************************/ +extern "C" void G__unredirectcout() { + if(G__store_cout) { + cout.rdbuf(G__store_cout); + G__store_cout = 0; + } + if(G__redirected_cout) { + delete G__redirected_cout; + G__redirected_cout = 0; + } +} +/******************************************************************** + * G__redirectcout + ********************************************************************/ +extern "C" void G__redirectcout(const char* filename) { + G__unredirectcout(); + G__redirected_cout = new ofstream(filename,ios_base::app); + G__store_cout = cout.rdbuf(G__redirected_cout->rdbuf()) ; +} +/******************************************************************** + * G__redirectcerr + ********************************************************************/ +extern "C" void G__unredirectcerr() { + if(G__store_cerr) { + cerr.rdbuf(G__store_cerr); + G__store_cerr = 0; + } + if(G__redirected_cerr) { + delete G__redirected_cerr; + G__redirected_cerr = 0; + } +} +/******************************************************************** + * G__redirectcerr + ********************************************************************/ +extern "C" void G__redirectcerr(const char* filename) { + G__unredirectcerr(); + G__redirected_cerr = new ofstream(filename,ios_base::app); + G__store_cerr = cerr.rdbuf(G__redirected_cerr->rdbuf()) ; +} +/******************************************************************** + * G__redirectcin + ********************************************************************/ +extern "C" void G__unredirectcin() { + if(G__store_cin) { + cin.rdbuf(G__store_cin); + G__store_cin = 0; + } + if(G__redirected_cin) { + delete G__redirected_cin; + G__redirected_cin = 0; + } +} +/******************************************************************** + * G__redirectcin + ********************************************************************/ +extern "C" void G__redirectcin(const char* filename) { + G__unredirectcin(); + G__redirected_cin = new ifstream(filename,ios_base::in); + G__store_cin = cin.rdbuf(G__redirected_cin->rdbuf()) ; +} +#endif /* 1635 */ + +#else // __CINT__ + +#include + +/******************************************************************** +* macro G__MANIP_SUPPORT must be defined to enable true manipulator +*********************************************************************/ +#define G__MANIP_SUPPORT + +extern "C" { + typedef struct { + private: + int __fill[6]; + } mbstate_t; +} +typedef long streampos ; +typedef long streamoff ; + +typedef long SZ_T; +typedef SZ_T streamsize; + +class ios_base { + public: + typedef int iostate; + enum io_state { + goodbit = 0x00, + badbit = 0x01, + eofbit = 0x02, + failbit = 0x04 + }; + typedef int openmode; + enum open_mode { + app = 0x01, + binary = 0x02, + in = 0x04, + out = 0x08, + trunc = 0x10, + ate = 0x20 + }; + typedef int seekdir; + enum seek_dir { + beg = 0x0, + cur = 0x1, + end = 0x2 + }; + typedef int fmtflags; + enum fmt_flags { + boolalpha = 0x0001, + dec = 0x0002, + fixed = 0x0004, + hex = 0x0008, + internal = 0x0010, + left = 0x0020, + oct = 0x0040, + right = 0x0080, + scientific = 0x0100, + showbase = 0x0200, + showpoint = 0x0400, + showpos = 0x0800, + skipws = 0x1000, + unitbuf = 0x2000, + uppercase = 0x4000, + adjustfield = left | right | internal, + basefield = dec | oct | hex, + floatfield = scientific | fixed + }; + enum event { + erase_event = 0x0001, + imbue_event = 0x0002, + copyfmt_event = 0x0004 + }; + typedef void (*event_callback) (event, ios_base&, int index); + void register_callback( event_callback fn, int index); + class Init { + public: + Init(); +#ifdef __MAKECINT__ + private: +#endif + ~Init(); + }; + inline fmtflags flags() const; + inline fmtflags flags(fmtflags fmtfl); + inline fmtflags setf(fmtflags fmtfl); + inline fmtflags setf(fmtflags fmtfl, fmtflags mask); + inline void unsetf(fmtflags mask); + inline streamsize precision() const; + inline streamsize precision(streamsize prec); + inline streamsize width() const; + inline streamsize width(streamsize wide); + static int xalloc(); + long& iword(int index); + void*& pword(int index); + //locale imbue(const locale& loc); + //locale getloc() const ; + static bool sync_with_stdio(bool sync = true); + virtual ~ios_base(); + protected: + ios_base(); + ios_base& operator=(const ios_base& x); +private: + ios_base(const ios_base&); // Not implemented +}; + +template +class basic_ios : public ios_base { + public: + typedef traits::char_type char_type; + typedef traits traits_type; + typedef traits::int_type int_type; + typedef traits::off_type off_type; + typedef traits::pos_type pos_type; + explicit basic_ios(basic_streambuf *sb_arg); + virtual ~basic_ios(); + char_type fill() const; + char_type fill(char_type ch); + inline void exceptions(iostate excpt); + inline iostate exceptions() const; + inline void clear(iostate state = goodbit); + inline void setstate(iostate state); + inline iostate rdstate() const; + inline operator void*() const; + inline bool operator! () const; + inline bool good() const; + inline bool eof() const; + inline bool fail() const; + inline bool bad() const; + basic_ios& copyfmt(const basic_ios& rhs); + inline basic_ostream *tie() const; + basic_ostream *tie(basic_ostream *tie_arg); + inline basic_streambuf *rdbuf() const; + basic_streambuf *rdbuf( basic_streambuf *sb); + //locale imbue(const locale& loc); + inline char narrow(charT, char) const; + inline charT widen(char) const; + protected: + basic_ios(); + void init(basic_streambuf *sb); + private: +// #ifdef G__SUNCC5 + basic_ios(const basic_ios& ); // not defined + basic_ios& operator=(const basic_ios&); // not defined +// #endif +}; + +template +class basic_streambuf { + basic_streambuf(const basic_streambuf&); + basic_streambuf& operator=(const basic_streambuf&); + public: + typedef charT char_type; + typedef traits traits_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + virtual ~basic_streambuf(); + //locale pubimbue( const locale& loc); + //locale getloc() const; + inline basic_streambuf * + pubsetbuf(char_type *s, streamsize n); + inline pos_type pubseekoff(off_type off, ios_base::seekdir way, + ios_base::openmode which = + ios_base::in | ios_base::out); + inline pos_type pubseekpos(pos_type sp, ios_base::openmode which = + ios_base::in | ios_base::out); + inline int pubsync( ); + inline streamsize in_avail(); + inline int_type snextc(); + inline int_type sbumpc(); + inline int_type sgetc(); + inline streamsize sgetn(char_type *s, streamsize n); + inline int_type sputbackc(char_type c); + inline int_type sungetc(); + inline int_type sputc(char_type c); + inline streamsize sputn(const char_type *s, streamsize n); + protected: + basic_streambuf(); + private: + basic_streambuf& operator=(const basic_streambuf& x); +}; + +// MSVC10 uses this to produce a "convertible-to-bool", +//struct _Bool_type { operator bool(); }; + +template +class basic_istream : virtual public basic_ios { + public: + typedef basic_istream _Myt; + typedef basic_ios _Myios; + typedef basic_streambuf _Mysb; + typedef traits traits_type; + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + explicit basic_istream(basic_streambuf *sb); + virtual ~basic_istream(); + class sentry { + sentry(const sentry&); // not defined + sentry& operator=(const sentry&); // not defined + public: + inline explicit sentry(basic_istream& stream,bool noskipws = 0); + //operator _Bool_type () { return ok_; } + }; + //_Myt& operator>>(_Myt& (*pf)(_Myt&)); + //_Myt& operator>>(ios_base& (*pf)(ios_base&)); + //_Myt& operator>>(_Myios& (*pf)(_Myios&)); +#ifndef __CINT__ + _Myt& operator>>(bool& n); + _Myt& operator>>(short& n); + _Myt& operator>>(unsigned short& n); + _Myt& operator>>(int& n); + _Myt& operator>>(unsigned int& n); + _Myt& operator>>(long& n); + _Myt& operator>>(unsigned long& n); + _Myt& operator>>(float& f); + _Myt& operator>>(double& f); + _Myt& operator>>(long double& f); + _Myt& operator>>(void*& p); +#endif + int_type get(); + _Myt& get(char_type *s, streamsize n, char_type delim); + _Myt& get(char_type *s, streamsize n); + _Myt& get(char_type& c); + _Myt& get(_Mysb& sb, char_type delim); + _Myt& get(_Mysb& sb); + _Myt& getline(char_type *s, streamsize n, char_type delim); + _Myt& getline(char_type *s, streamsize n); + _Myt& ignore(streamsize n , int_type delim ); + _Myt& ignore(streamsize n =1 ); + //_Myt& ignore(streamsize n = 1, int_type delim = traits::eof()); + _Myt& read(char_type *s, streamsize n); + streamsize readsome(char_type *s, streamsize n); + int peek(); + pos_type tellg(); + _Myt& seekg(pos_type pos); + int sync(); + //#ifndef __CINT__ + _Myt& seekg(off_type, ios_base::seekdir); + //#endif + _Myt& putback(char_type c); + _Myt& unget(); + streamsize gcount() const; + protected: + basic_istream( ); +}; + +template +class basic_ostream : virtual public basic_ios { + public: + typedef basic_ostream _Myt; + typedef basic_ios _Myios; + typedef traits traits_type; + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + explicit basic_ostream(basic_streambuf *sb); + virtual ~basic_ostream(); + class sentry { + public: + inline explicit sentry(basic_ostream& stream); +#ifdef __MAKECINT__ + private: + ~sentry() {} + public: +#else + ~sentry() ; +#endif + //operator _Bool_type () { return ok_; } + private: + sentry(const sentry&); // not defined + sentry& operator=(const sentry&); // not defined + }; + //_Myt& operator<<(_Myt& (*pf)(_Myt&)); + //_Myt& operator<<(ios_base& (*pf)(ios_base&)); + //_Myt& operator<<(_Myios& (*pf)(_Myios&)); +#ifndef __CINT__ + _Myt& operator<<(short n); + _Myt& operator<<(unsigned short n); + _Myt& operator<<(int n); + _Myt& operator<<(unsigned int n); + _Myt& operator<<(long n); + _Myt& operator<<(unsigned long n); + _Myt& operator<<(float f); + _Myt& operator<<(double f); + _Myt& operator<<(long double f); + _Myt& operator<<(bool n); + _Myt& operator<<(basic_streambuf *sb); + _Myt& operator<<(void *p); +#endif + //_Myt& operator<<(basic_streambuf& sb); + _Myt& put(char_type c); + _Myt& write(const char_type *s, streamsize n); + _Myt& flush(); + _Myt& seekp(pos_type pos); + _Myt& seekp(off_type , ios_base::seekdir ); + pos_type tellp(); + protected: + basic_ostream(); +}; + + +template +class basic_iostream + : public basic_istream,public basic_ostream +{ +public: + explicit basic_iostream(basic_streambuf *sb); + virtual ~basic_iostream(); + +protected: + explicit basic_iostream(); +}; + + +typedef int INT_T; + +template +struct char_traits { + typedef charT char_type; + typedef INT_T int_type; +#ifdef __CINT__ + typedef mbstate_t state_type; + typedef fpos pos_type; + typedef wstreamoff off_type; +#endif + static void assign (char_type& c1, const char_type& c2) ; + static char_type to_char_type(const int_type& c); + static int_type to_int_type(const char_type& c); + static bool eq(const char_type& c1,const char_type& c2); + static bool lt (const char_type& c1, const char_type& c2) ; + static int compare (const char_type* s1, const char_type* s2, size_t n); + static bool eq_int_type(const int_type& c1,const int_type& c2); + static int_type eof(); + static int_type not_eof(const int_type& c); + static size_t length(const char_type *s); + static const char_type* find (const char_type* s,int n,const char_type& a); + static char_type *copy(char_type *dst,const char_type *src, size_t n); + static char_type* move (char_type* s1, const char_type* s2, size_t n); + static char_type* assign (char_type* s, size_t n, const char_type a); +}; + +struct char_traits { + typedef char char_type; + typedef int int_type; + +#ifdef __CINT__ + typedef streamoff off_type; + typedef streampos pos_type; + typedef mbstate_t state_type; +#endif + static void assign (char_type& c1, const char_type& c2) ; + static char_type to_char_type(const int_type& c); + static int_type to_int_type(const char_type& c); + static bool eq(const char_type& c1,const char_type& c2); + static bool lt (const char_type& c1, const char_type& c2) ; + static int compare (const char_type* s1, const char_type* s2, size_t n); + static const char_type* find (const char_type* s,int n,const char_type& a); + static bool eq_int_type(const int_type& c1,const int_type& c2); + static int_type eof(); + static int_type not_eof(const int_type& c); + static size_t length(const char_type *s); + static char_type *copy(char_type *dst,const char_type *src, size_t n); + static char_type * move (char_type* s1, const char_type* s2, size_t n); + static char_type* assign (char_type* s, size_t n, const char_type a); +}; + +//typedef basic_istream > istream; +typedef basic_istream > istream; +//typedef basic_ostream ostream; +typedef basic_ostream > ostream; + +extern istream cin ; +extern ostream cout ; +extern ostream cerr ; +extern ostream clog ; + +#ifndef G__OLDIMPLEMENTATION1938 +ios_base& dec(ios_base&) ; +ios_base& hex(ios_base&) ; +ios_base& oct(ios_base&) ; +ios_base& fixed(ios_base&); +ios_base& scientific(ios_base&); +ios_base& right(ios_base&); +ios_base& left(ios_base&); +ios_base& internal(ios_base&); +ios_base& nouppercase(ios_base&); +ios_base& uppercase(ios_base&); +ios_base& noskipws(ios_base&); +ios_base& skipws(ios_base&); +ios_base& noshowpos(ios_base&); +ios_base& showpos(ios_base&); +ios_base& noshowpoint(ios_base&); +ios_base& showpoint(ios_base&); +ios_base& noshowbase(ios_base&); +ios_base& showbase(ios_base&); +ios_base& noboolalpha(ios_base&); +ios_base& boolalpha(ios_base&); +#endif + +istream& ws(istream&) ; + +ostream& endl(ostream& i) ; +ostream& ends(ostream& i) ; +ostream& flush(ostream&) ; + +ostream& operator<< ( ostream&, char ); +ostream& operator<< ( ostream&, char* ); +ostream& operator<< ( ostream&, void* ); +ostream& operator<< ( ostream&, unsigned char ); +ostream& operator<< ( ostream&, short ); +ostream& operator<< ( ostream&, unsigned short ); +ostream& operator<< ( ostream&, int ); +ostream& operator<< ( ostream&, unsigned int ); +ostream& operator<< ( ostream&, long ); +ostream& operator<< ( ostream&, unsigned long); +ostream& operator<< ( ostream&, float ); +ostream& operator<< ( ostream&, double ); +//ostream& operator<< ( ostream&, long double ); +ostream& operator<< ( ostream&, bool ); +// not needed, ostream& operator<< (ostream&,const streampos&); + +istream& operator>> ( istream&, char& ); +istream& operator>> ( istream&, unsigned char& ); +istream& operator>> ( istream&, short& ); +istream& operator>> ( istream&, unsigned short& ); +istream& operator>> ( istream&, int& ); +istream& operator>> ( istream&, unsigned int& ); +istream& operator>> ( istream&, long& ); +istream& operator>> ( istream&, unsigned long& ); +istream& operator>> ( istream&, float& ); +istream& operator>> ( istream&, double& ); +//istream& operator>> ( istream&, long double& ); +istream& operator>> ( istream&, bool& ); +istream& operator>> ( istream&, char* ); +istream& operator>> ( istream&, void*& ); + +#endif // __CINT__ + +#ifndef __CINT__ +namespace std { +template inline + basic_istream<_Elem, _Traits>& +#ifndef __QNX__ + __cdecl +#endif + operator>>(basic_istream<_Elem, _Traits>& _Istr, T& _Ch) + { // extract a signed char + return (_Istr >> _Ch); + } +} + +#endif + + +#endif // G__IOSTREAM_H diff --git a/cint/cint/lib/vc11strm/linkdef.h b/cint/cint/lib/vc11strm/linkdef.h new file mode 100644 index 0000000000000..efdee6a56a77d --- /dev/null +++ b/cint/cint/lib/vc11strm/linkdef.h @@ -0,0 +1,16 @@ +/* -*- C++ -*- */ +/************************************************************************* + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) + * + * For the licensing terms see the file COPYING + * + ************************************************************************/ + +#ifdef __MAKECINT__ + +#pragma link off class allocator; +#pragma link off class allocator; +#pragma link off class basic_string,allocator >; +#pragma link MACRO function char_traits::assign(char_type*,size_t,const char_type); +#pragma link C++ nestedtypedef; +#endif diff --git a/cint/cint/lib/vc11strm/sstrm.h b/cint/cint/lib/vc11strm/sstrm.h new file mode 100644 index 0000000000000..1d73fd2067513 --- /dev/null +++ b/cint/cint/lib/vc11strm/sstrm.h @@ -0,0 +1,214 @@ +/* /% C++ %/ */ +/*********************************************************************** + * cint (C/C++ interpreter) + ************************************************************************ + * header file sstrm.h + ************************************************************************ + * Description: + * Stub file for making iostream library + ************************************************************************ + * Copyright(c) 1999 Masaharu Goto (MXJ02154@niftyserve.or.jp) + * + * For the licensing terms see the file COPYING + * + ************************************************************************/ + +#ifndef G__SSTREAM_H +#define G__SSTREAM_H + +#ifndef __CINT__ + +#include +using namespace std; + +#else // __CINT__ + +#include +//#include +class allocator; +class allocator; +#include "iostrm.h" +using namespace std; + +namespace std { +template +class basic_string; +} + +template +class basic_stringbuf : public basic_streambuf +{ + public: + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + typedef traits traits_type; + + typedef basic_ios ios_type; +#ifdef __CINT__ + //typedef string _Mystr; + typedef basic_string _Mystr; +#else + typedef basic_string _Mystr; +#endif + + explicit basic_stringbuf(ios_base::openmode which = + ios_base::in | ios_base::out ); + + explicit basic_stringbuf(const _Mystr& str, + ios_base::openmode which = + ios_base::in | ios_base::out ); + + virtual ~basic_stringbuf(); + + _Mystr str() const; + void str(const _Mystr& str_arg); + + protected: + + virtual int_type overflow(int_type c = traits::eof()); + virtual int_type pbackfail(int_type c = traits::eof()); + virtual int_type underflow(); + virtual pos_type seekoff(off_type off, ios_base::seekdir way, + ios_base::openmode which = + ios_base::in | ios_base::out); + + virtual pos_type seekpos(pos_type sp, + ios_base::openmode which = + ios_base::in | ios_base::out); + + virtual basic_streambuf* setbuf(char_type* s, streamsize n); + virtual streamsize xsputn(const char_type *s, streamsize n); + private: + basic_stringbuf& operator=(const basic_stringbuf& x); +}; + + +template +class basic_istringstream : public basic_istream +{ + public: + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + typedef traits traits_type; + + typedef basic_stringbuf sb_type; + typedef basic_ios ios_type; +#ifdef __CINT__ + typedef basic_string _Mystr; + //typedef string _Mystr; +#else + typedef basic_string _Mystr; +#endif + + explicit basic_istringstream(ios_base::openmode which = ios_base::in); + explicit basic_istringstream(const _Mystr& str, + ios_base::openmode which = ios_base::in); +#ifdef __CINT__ + explicit basic_istringstream(const char *str, + ios_base::openmode which = ios_base::in); +#endif + + virtual ~basic_istringstream(); + + basic_stringbuf *rdbuf() const; + _Mystr str() const; + + void str(const _Mystr& str); +}; + + +template +class basic_ostringstream : public basic_ostream +{ + public: + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + typedef traits traits_type; + + typedef basic_stringbuf sb_type; + typedef basic_ios ios_type; +#ifdef __CINT__ + //typedef string _Mystr; + typedef basic_string _Mystr; +#else + typedef basic_string _Mystr; +#endif + + explicit basic_ostringstream(ios_base::openmode which = ios_base::out); + explicit basic_ostringstream(const _Mystr& str, + ios_base::openmode which = ios_base::out); + + virtual ~basic_ostringstream(); + basic_stringbuf *rdbuf() const; + + _Mystr str() const; + void str(const _Mystr& str); +}; + + +template +class basic_stringstream : public basic_iostream +{ + public: + typedef charT char_type; + typedef traits::int_type int_type; + typedef traits::pos_type pos_type; + typedef traits::off_type off_type; + typedef traits traits_type; + + typedef basic_stringbuf sb_type; + typedef basic_ios ios_type; +#ifdef __CINT__ + typedef basic_string _Mystr; + //typedef string _Mystr; +#else + typedef basic_string _Mystr; +#endif + + explicit basic_stringstream(ios_base::openmode which = ios_base::out | + ios_base::in); + + explicit basic_stringstream(const _Mystr& str, + ios_base::openmode which = + ios_base::out | ios_base::in); + + virtual ~basic_stringstream(); + basic_stringbuf *rdbuf() const; + _Mystr str() const; + void str(const _Mystr& str); +}; + + +//typedef basic_stringbuf stringbuf; +typedef basic_stringbuf,allocator > stringbuf; + +//typedef basic_stringbuf wstringbuf; +//typedef basic_stringbuf,allocator > wstringbuf; + +//typedef basic_istringstream istringstream; +typedef basic_istringstream,allocator > istringstream; + +//typedef basic_istringstream wistringstream; +//typedef basic_istringstream,allocator > wistringstream; + +//typedef basic_ostringstream ostringstream; +typedef basic_ostringstream,allocator > ostringstream; + +//typedef basic_ostringstream wostringstream; +//typedef basic_ostringstream,allocator > wostringstream; + +//typedef basic_stringstream stringstream; +typedef basic_stringstream,allocator > stringstream; + +//typedef basic_stringstream wstringstream; +//typedef basic_stringstream, allocator > wstringstream; + +#endif // __CINT__ + +#endif // G__SSTREAM_H diff --git a/cint/cint/lib/vc11strm/vc11strm.cxx b/cint/cint/lib/vc11strm/vc11strm.cxx new file mode 100644 index 0000000000000..5fb24df59570a --- /dev/null +++ b/cint/cint/lib/vc11strm/vc11strm.cxx @@ -0,0 +1,4293 @@ +/******************************************************** +* vc11strm.cxx +* CAUTION: DON'T CHANGE THIS FILE. THIS FILE IS AUTOMATICALLY GENERATED +* FROM HEADER FILES LISTED IN G__setup_cpp_environmentXXX(). +* CHANGE THOSE HEADER FILES AND REGENERATE THIS FILE. +********************************************************/ +#include "vc11strm.h" //newlink 3678 + +#ifdef G__MEMTEST +#undef malloc +#undef free +#endif + +extern "C" void G__cpp_reset_tagtableG__stream(); + +extern "C" void G__set_cpp_environmentG__stream() { + G__add_ipath("."); + G__add_ipath("..\\..\\include"); + G__add_compiledheader("iostrm.h"); + G__add_compiledheader("fstrm.h"); + G__add_compiledheader("sstrm.h"); + G__cpp_reset_tagtableG__stream(); +} +#include +extern "C" int G__cpp_dllrevG__stream() { return(30051515); } + +/********************************************************* +* Member function Interface Method +*********************************************************/ + +/* mbstate_t */ +// automatic default constructor +static int G__G__stream_1_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + mbstate_t *p; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new mbstate_t[n]; + } else { + p = new((void*) gvp) mbstate_t[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new mbstate_t; + } else { + p = new((void*) gvp) mbstate_t; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_mbstate_t)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic copy constructor +static int G__G__stream_1_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) + +{ + mbstate_t* p; + void* tmp = (void*) G__int(libp->para[0]); + p = new mbstate_t(*(mbstate_t*) tmp); + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_mbstate_t)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef mbstate_t G__Tmbstate_t; +static int G__G__stream_1_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (mbstate_t*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((mbstate_t*) (soff+(sizeof(mbstate_t)*i)))->~G__Tmbstate_t(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (mbstate_t*) soff; + } else { + G__setgvp((long) G__PVOID); + ((mbstate_t*) (soff))->~G__Tmbstate_t(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic assignment operator +static int G__G__stream_1_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + mbstate_t* dest = (mbstate_t*) G__getstructoffset(); + *dest = *(mbstate_t*) libp->para[0].ref; + const mbstate_t& obj = *dest; + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* ios_base */ +static int G__G__stream_2_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((ios_base*) G__getstructoffset())->register_callback((ios_base::event_callback) G__int(libp->para[0]), (int) G__int(libp->para[1])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((const ios_base*) G__getstructoffset())->flags()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((ios_base*) G__getstructoffset())->flags((ios_base::fmtflags) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((ios_base*) G__getstructoffset())->setf((ios_base::fmtflags) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((ios_base*) G__getstructoffset())->setf((ios_base::fmtflags) G__int(libp->para[0]), (ios_base::fmtflags) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((ios_base*) G__getstructoffset())->unsetf((ios_base::fmtflags) G__int(libp->para[0])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((const ios_base*) G__getstructoffset())->precision()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((ios_base*) G__getstructoffset())->precision((streamsize) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((const ios_base*) G__getstructoffset())->width()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((ios_base*) G__getstructoffset())->width((streamsize) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ios_base::xalloc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const long& obj = ((ios_base*) G__getstructoffset())->iword((int) G__int(libp->para[0])); + result7->ref = (long) (&obj); + G__letint(result7, 'l', (long)obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + void*& obj = ((ios_base*) G__getstructoffset())->pword((int) G__int(libp->para[0])); + result7->ref = (long) (&obj); + G__letint(result7, 'Y', (long)obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 1: + G__letint(result7, 103, (long) ios_base::sync_with_stdio((bool) G__int(libp->para[0]))); + break; + case 0: + G__letint(result7, 103, (long) ios_base::sync_with_stdio()); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef ios_base G__Tios_base; +static int G__G__stream_2_0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (ios_base*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((ios_base*) (soff+(sizeof(ios_base)*i)))->~G__Tios_base(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (ios_base*) soff; + } else { + G__setgvp((long) G__PVOID); + ((ios_base*) (soff))->~G__Tios_base(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* ios_base::Init */ +static int G__G__stream_8_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ios_base::Init* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + p = 0; + G__genericerror("Error: Array construction with private/protected destructor is illegal"); + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new ios_base::Init; + } else { + p = new((void*) gvp) ios_base::Init; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic copy constructor +static int G__G__stream_8_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) + +{ + ios_base::Init* p; + void* tmp = (void*) G__int(libp->para[0]); + p = new ios_base::Init(*(ios_base::Init*) tmp); + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic assignment operator +static int G__G__stream_8_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ios_base::Init* dest = (ios_base::Init*) G__getstructoffset(); + const ios_base::Init& obj = *dest; + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* char_traits */ +static int G__G__stream_9_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char_traits::assign(*(char_traits::char_type*) G__Charref(&libp->para[0]), *(char_traits::char_type*) G__Charref(&libp->para[1])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) char_traits::to_char_type(*(char_traits::int_type*) G__Intref(&libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) char_traits::to_int_type(*(char_traits::char_type*) G__Charref(&libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) char_traits::eq(*(char_traits::char_type*) G__Charref(&libp->para[0]), *(char_traits::char_type*) G__Charref(&libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) char_traits::lt(*(char_traits::char_type*) G__Charref(&libp->para[0]), *(char_traits::char_type*) G__Charref(&libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) char_traits::compare((const char_traits::char_type*) G__int(libp->para[0]), (const char_traits::char_type*) G__int(libp->para[1]) +, (size_t) G__int(libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 67, (long) char_traits::find((const char_traits::char_type*) G__int(libp->para[0]), (int) G__int(libp->para[1]) +, *(char_traits::char_type*) G__Charref(&libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) char_traits::eq_int_type(*(char_traits::int_type*) G__Intref(&libp->para[0]), *(char_traits::int_type*) G__Intref(&libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) char_traits::eof()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) char_traits::not_eof(*(char_traits::int_type*) G__Intref(&libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 104, (long) char_traits::length((const char_traits::char_type*) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 67, (long) char_traits::copy((char_traits::char_type*) G__int(libp->para[0]), (const char_traits::char_type*) G__int(libp->para[1]) +, (size_t) G__int(libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 67, (long) char_traits::move((char_traits::char_type*) G__int(libp->para[0]), (const char_traits::char_type*) G__int(libp->para[1]) +, (size_t) G__int(libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 67, (long) char_traits::assign((char_traits::char_type*) G__int(libp->para[0]), (size_t) G__int(libp->para[1]) +, (const char_traits::char_type) G__int(libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic default constructor +static int G__G__stream_9_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char_traits *p; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new char_traits[n]; + } else { + p = new((void*) gvp) char_traits[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new char_traits; + } else { + p = new((void*) gvp) char_traits; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic copy constructor +static int G__G__stream_9_0_16(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) + +{ + char_traits* p; + void* tmp = (void*) G__int(libp->para[0]); + p = new char_traits(*(char_traits*) tmp); + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef char_traits G__Tchar_traitslEchargR; +static int G__G__stream_9_0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (char_traits*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((char_traits*) (soff+(sizeof(char_traits)*i)))->~G__Tchar_traitslEchargR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (char_traits*) soff; + } else { + G__setgvp((long) G__PVOID); + ((char_traits*) (soff))->~G__Tchar_traitslEchargR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic assignment operator +static int G__G__stream_9_0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char_traits* dest = (char_traits*) G__getstructoffset(); + const char_traits& obj = *dest; + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_istream > */ +static int G__G__stream_10_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istream >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istream >((basic_streambuf >*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_istream >((basic_streambuf >*) G__int(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_istream >*) G__getstructoffset())->get()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->get((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1]) +, (basic_istream >::char_type) G__int(libp->para[2])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->get((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->get(*(basic_istream >::char_type*) G__Charref(&libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->get(*(basic_istream >::_Mysb*) libp->para[0].ref, (basic_istream >::char_type) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->get(*(basic_istream >::_Mysb*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->getline((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1]) +, (basic_istream >::char_type) G__int(libp->para[2])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->getline((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->ignore((streamsize) G__int(libp->para[0]), (basic_istream >::int_type) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 1: + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->ignore((streamsize) G__int(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + break; + case 0: + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->ignore(); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->read((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((basic_istream >*) G__getstructoffset())->readsome((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_istream >*) G__getstructoffset())->peek()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((basic_istream >*) G__getstructoffset())->tellg()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_16(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->seekg((basic_istream >::pos_type) G__int(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_istream >*) G__getstructoffset())->sync()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->seekg((basic_istream >::off_type) G__int(libp->para[0]), (ios_base::seekdir) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_19(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->putback((basic_istream >::char_type) G__int(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_20(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->unget(); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_21(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((const basic_istream >*) G__getstructoffset())->gcount()); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_istream > G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_10_0_23(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_istream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_istream >*) (soff+(sizeof(basic_istream >)*i)))->~G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_istream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_istream >*) (soff))->~G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ios > */ +static int G__G__stream_11_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ios >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ios >((basic_streambuf >*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ios >((basic_streambuf >*) G__int(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) ((const basic_ios >*) G__getstructoffset())->fill()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) ((basic_ios >*) G__getstructoffset())->fill((basic_ios >::char_type) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ios >*) G__getstructoffset())->exceptions((ios_base::iostate) G__int(libp->para[0])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((const basic_ios >*) G__getstructoffset())->exceptions()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 1: + ((basic_ios >*) G__getstructoffset())->clear((ios_base::iostate) G__int(libp->para[0])); + G__setnull(result7); + break; + case 0: + ((basic_ios >*) G__getstructoffset())->clear(); + G__setnull(result7); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ios >*) G__getstructoffset())->setstate((ios_base::iostate) G__int(libp->para[0])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((const basic_ios >*) G__getstructoffset())->rdstate()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 89, (long) ((const basic_ios >*) G__getstructoffset())->operator void*()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->operator!()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->good()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->eof()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->fail()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->bad()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ios >& obj = ((basic_ios >*) G__getstructoffset())->copyfmt(*(basic_ios >*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_16(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ios >*) G__getstructoffset())->tie()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_ios >*) G__getstructoffset())->tie((basic_ostream >*) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ios >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_19(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_ios >*) G__getstructoffset())->rdbuf((basic_streambuf >*) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_20(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) ((const basic_ios >*) G__getstructoffset())->narrow((char) G__int(libp->para[0]), (char) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_21(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) ((const basic_ios >*) G__getstructoffset())->widen((char) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ios > G__Tbasic_ioslEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_11_0_26(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ios >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ios >*) (soff+(sizeof(basic_ios >)*i)))->~G__Tbasic_ioslEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ios >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ios >*) (soff))->~G__Tbasic_ioslEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_streambuf > */ +static int G__G__stream_12_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_streambuf >*) G__getstructoffset())->pubsetbuf((basic_streambuf >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 3: + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->pubseekoff((basic_streambuf >::off_type) G__int(libp->para[0]), (ios_base::seekdir) G__int(libp->para[1]) +, (ios_base::openmode) G__int(libp->para[2]))); + break; + case 2: + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->pubseekoff((basic_streambuf >::off_type) G__int(libp->para[0]), (ios_base::seekdir) G__int(libp->para[1]))); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 2: + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->pubseekpos((basic_streambuf >::pos_type) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1]))); + break; + case 1: + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->pubseekpos((basic_streambuf >::pos_type) G__int(libp->para[0]))); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->pubsync()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->in_avail()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->snextc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sbumpc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sgetc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->sgetn((basic_streambuf >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sputbackc((basic_streambuf >::char_type) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sungetc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sputc((basic_streambuf >::char_type) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->sputn((const basic_streambuf >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_streambuf > G__Tbasic_streambuflEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_12_0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_streambuf >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_streambuf >*) (soff+(sizeof(basic_streambuf >)*i)))->~G__Tbasic_streambuflEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_streambuf >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_streambuf >*) (soff))->~G__Tbasic_streambuflEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ostream > */ +static int G__G__stream_13_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ostream >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostream >((basic_streambuf >*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ostream >((basic_streambuf >*) G__int(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >::_Myt& obj = ((basic_ostream >*) G__getstructoffset())->put((basic_ostream >::char_type) G__int(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >::_Myt& obj = ((basic_ostream >*) G__getstructoffset())->write((const basic_ostream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >::_Myt& obj = ((basic_ostream >*) G__getstructoffset())->flush(); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >::_Myt& obj = ((basic_ostream >*) G__getstructoffset())->seekp((basic_ostream >::pos_type) G__int(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >::_Myt& obj = ((basic_ostream >*) G__getstructoffset())->seekp((basic_ostream >::off_type) G__int(libp->para[0]), (ios_base::seekdir) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((basic_ostream >*) G__getstructoffset())->tellp()); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ostream > G__Tbasic_ostreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_13_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ostream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ostream >*) (soff+(sizeof(basic_ostream >)*i)))->~G__Tbasic_ostreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ostream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ostream >*) (soff))->~G__Tbasic_ostreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ostream >::sentry */ +static int G__G__stream_14_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ostream >::sentry* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostream >::sentry(*(basic_ostream >*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_ostream >::sentry(*(basic_ostream >*) libp->para[0].ref); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_istream >::sentry */ +static int G__G__stream_15_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istream >::sentry* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istream >::sentry(*(basic_istream >*) libp->para[0].ref, (bool) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_istream >::sentry(*(basic_istream >*) libp->para[0].ref, (bool) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istream >::sentry(*(basic_istream >*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_istream >::sentry(*(basic_istream >*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_istream >::sentry G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +static int G__G__stream_15_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_istream >::sentry*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_istream >::sentry*) (soff+(sizeof(basic_istream >::sentry)*i)))->~G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_istream >::sentry*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_istream >::sentry*) (soff))->~G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_filebuf > */ +static int G__G__stream_16_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_filebuf >* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_filebuf >[n]; + } else { + p = new((void*) gvp) basic_filebuf >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_filebuf >; + } else { + p = new((void*) gvp) basic_filebuf >; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_16_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_filebuf >*) G__getstructoffset())->is_open()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_16_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_filebuf >*) G__getstructoffset())->open((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_16_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_filebuf >*) G__getstructoffset())->close()); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_filebuf > G__Tbasic_filebuflEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_16_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_filebuf >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_filebuf >*) (soff+(sizeof(basic_filebuf >)*i)))->~G__Tbasic_filebuflEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_filebuf >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_filebuf >*) (soff))->~G__Tbasic_filebuflEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ifstream > */ +static int G__G__stream_17_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ifstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ifstream >[n]; + } else { + p = new((void*) gvp) basic_ifstream >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ifstream >; + } else { + p = new((void*) gvp) basic_ifstream >; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_17_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ifstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ifstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_ifstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ifstream >((const char*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ifstream >((const char*) G__int(libp->para[0])); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_17_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ifstream >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_17_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((basic_ifstream >*) G__getstructoffset())->is_open()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_17_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 2: + ((basic_ifstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + G__setnull(result7); + break; + case 1: + ((basic_ifstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0])); + G__setnull(result7); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_17_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ifstream >*) G__getstructoffset())->close(); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ifstream > G__Tbasic_ifstreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_17_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ifstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ifstream >*) (soff+(sizeof(basic_ifstream >)*i)))->~G__Tbasic_ifstreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ifstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ifstream >*) (soff))->~G__Tbasic_ifstreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ofstream > */ +static int G__G__stream_18_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ofstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ofstream >[n]; + } else { + p = new((void*) gvp) basic_ofstream >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ofstream >; + } else { + p = new((void*) gvp) basic_ofstream >; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ofstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ofstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_ofstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ofstream >((const char*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ofstream >((const char*) G__int(libp->para[0])); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ofstream >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((basic_ofstream >*) G__getstructoffset())->is_open()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 2: + ((basic_ofstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + G__setnull(result7); + break; + case 1: + ((basic_ofstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0])); + G__setnull(result7); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ofstream >*) G__getstructoffset())->close(); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ofstream > G__Tbasic_ofstreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_18_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ofstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ofstream >*) (soff+(sizeof(basic_ofstream >)*i)))->~G__Tbasic_ofstreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ofstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ofstream >*) (soff))->~G__Tbasic_ofstreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_fstream > */ +static int G__G__stream_19_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_fstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_fstream >[n]; + } else { + p = new((void*) gvp) basic_fstream >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_fstream >; + } else { + p = new((void*) gvp) basic_fstream >; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_fstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_fstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_fstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_fstream >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((basic_fstream >*) G__getstructoffset())->is_open()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_fstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_fstream >*) G__getstructoffset())->close(); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_fstream > G__Tbasic_fstreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_19_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_fstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_fstream >*) (soff+(sizeof(basic_fstream >)*i)))->~G__Tbasic_fstreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_fstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_fstream >*) (soff))->~G__Tbasic_fstreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_iostream > */ +static int G__G__stream_20_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_iostream >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_iostream >((basic_streambuf >*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_iostream >((basic_streambuf >*) G__int(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_iostream > G__Tbasic_iostreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_20_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_iostream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_iostream >*) (soff+(sizeof(basic_iostream >)*i)))->~G__Tbasic_iostreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_iostream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_iostream >*) (soff))->~G__Tbasic_iostreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_stringbuf,allocator > */ +static int G__G__stream_23_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_stringbuf,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >((ios_base::openmode) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_stringbuf,allocator >((ios_base::openmode) G__int(libp->para[0])); + } + break; + case 0: + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >[n]; + } else { + p = new((void*) gvp) basic_stringbuf,allocator >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >; + } else { + p = new((void*) gvp) basic_stringbuf,allocator >; + } + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_23_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_stringbuf,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >(*(basic_stringbuf,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_stringbuf,allocator >(*(basic_stringbuf,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >(*(basic_stringbuf,allocator >::_Mystr*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_stringbuf,allocator >(*(basic_stringbuf,allocator >::_Mystr*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_23_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_stringbuf,allocator >::_Mystr* pobj; + const basic_stringbuf,allocator >::_Mystr xobj = ((const basic_stringbuf,allocator >*) G__getstructoffset())->str(); + pobj = new basic_stringbuf,allocator >::_Mystr(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_23_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_stringbuf,allocator >*) G__getstructoffset())->str(*(basic_stringbuf,allocator >::_Mystr*) libp->para[0].ref); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_stringbuf,allocator > G__Tbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +static int G__G__stream_23_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_stringbuf,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_stringbuf,allocator >*) (soff+(sizeof(basic_stringbuf,allocator >)*i)))->~G__Tbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_stringbuf,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_stringbuf,allocator >*) (soff))->~G__Tbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_istringstream,allocator > */ +static int G__G__stream_25_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_istringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } + break; + case 0: + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >[n]; + } else { + p = new((void*) gvp) basic_istringstream,allocator >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >; + } else { + p = new((void*) gvp) basic_istringstream,allocator >; + } + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_25_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >(*(basic_istringstream,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_istringstream,allocator >(*(basic_istringstream,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >(*(basic_istringstream,allocator >::_Mystr*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_istringstream,allocator >(*(basic_istringstream,allocator >::_Mystr*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_25_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_istringstream,allocator >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >((const char*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_istringstream,allocator >((const char*) G__int(libp->para[0])); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_25_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_istringstream,allocator >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_25_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istringstream,allocator >::_Mystr* pobj; + const basic_istringstream,allocator >::_Mystr xobj = ((const basic_istringstream,allocator >*) G__getstructoffset())->str(); + pobj = new basic_istringstream,allocator >::_Mystr(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_25_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_istringstream,allocator >*) G__getstructoffset())->str(*(basic_istringstream,allocator >::_Mystr*) libp->para[0].ref); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_istringstream,allocator > G__Tbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +static int G__G__stream_25_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_istringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_istringstream,allocator >*) (soff+(sizeof(basic_istringstream,allocator >)*i)))->~G__Tbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_istringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_istringstream,allocator >*) (soff))->~G__Tbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ostringstream,allocator > */ +static int G__G__stream_26_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ostringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ostringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } + break; + case 0: + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >[n]; + } else { + p = new((void*) gvp) basic_ostringstream,allocator >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >; + } else { + p = new((void*) gvp) basic_ostringstream,allocator >; + } + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_26_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ostringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >(*(basic_ostringstream,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_ostringstream,allocator >(*(basic_ostringstream,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >(*(basic_ostringstream,allocator >::_Mystr*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_ostringstream,allocator >(*(basic_ostringstream,allocator >::_Mystr*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_26_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ostringstream,allocator >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_26_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostringstream,allocator >::_Mystr* pobj; + const basic_ostringstream,allocator >::_Mystr xobj = ((const basic_ostringstream,allocator >*) G__getstructoffset())->str(); + pobj = new basic_ostringstream,allocator >::_Mystr(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_26_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ostringstream,allocator >*) G__getstructoffset())->str(*(basic_ostringstream,allocator >::_Mystr*) libp->para[0].ref); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ostringstream,allocator > G__Tbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +static int G__G__stream_26_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ostringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ostringstream,allocator >*) (soff+(sizeof(basic_ostringstream,allocator >)*i)))->~G__Tbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ostringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ostringstream,allocator >*) (soff))->~G__Tbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_stringstream,allocator > */ +static int G__G__stream_27_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_stringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_stringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } + break; + case 0: + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >[n]; + } else { + p = new((void*) gvp) basic_stringstream,allocator >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >; + } else { + p = new((void*) gvp) basic_stringstream,allocator >; + } + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_27_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_stringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >(*(basic_stringstream,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_stringstream,allocator >(*(basic_stringstream,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >(*(basic_stringstream,allocator >::_Mystr*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_stringstream,allocator >(*(basic_stringstream,allocator >::_Mystr*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_27_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_stringstream,allocator >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_27_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_stringstream,allocator >::_Mystr* pobj; + const basic_stringstream,allocator >::_Mystr xobj = ((const basic_stringstream,allocator >*) G__getstructoffset())->str(); + pobj = new basic_stringstream,allocator >::_Mystr(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_27_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_stringstream,allocator >*) G__getstructoffset())->str(*(basic_stringstream,allocator >::_Mystr*) libp->para[0].ref); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_stringstream,allocator > G__Tbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +static int G__G__stream_27_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_stringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_stringstream,allocator >*) (soff+(sizeof(basic_stringstream,allocator >)*i)))->~G__Tbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_stringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_stringstream,allocator >*) (soff))->~G__Tbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* Setting up global function */ +static int G__G__stream__0_0(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = dec(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = hex(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = oct(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = fixed(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = scientific(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = right(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = left(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = internal(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = nouppercase(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = uppercase(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noskipws(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = skipws(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noshowpos(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = showpos(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noshowpoint(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = showpoint(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_16(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noshowbase(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = showbase(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noboolalpha(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_19(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = boolalpha(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_20(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = ws(*(istream*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_21(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = endl(*(ostream*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_22(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = ends(*(ostream*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_23(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = flush(*(ostream*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_24(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (char) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_25(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (char*) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_26(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (void*) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_27(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (unsigned char) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_28(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (short) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_29(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (unsigned short) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_30(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (int) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_31(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (unsigned int) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_32(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (long) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_33(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (unsigned long) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_34(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (float) G__double(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_35(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (double) G__double(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_36(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (bool) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_37(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(char*) G__Charref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_38(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(unsigned char*) G__UCharref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_39(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(short*) G__Shortref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_40(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(unsigned short*) G__UShortref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_41(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(int*) G__Intref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_42(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(unsigned int*) G__UIntref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_43(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(long*) G__Longref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_44(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(unsigned long*) G__ULongref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_45(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(float*) G__Floatref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_46(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(double*) G__Doubleref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_47(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(bool*) G__Boolref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_48(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, (char*) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_49(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, libp->para[1].ref ? *(void**) libp->para[1].ref : *(void**) (void*) (&G__Mlong(libp->para[1]))); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + + +/********************************************************* +* Member function Stub +*********************************************************/ + +/* mbstate_t */ + +/* ios_base */ + +/* ios_base::Init */ + +/* char_traits */ + +/* basic_istream > */ + +/* basic_ios > */ + +/* basic_streambuf > */ + +/* basic_ostream > */ + +/* basic_ostream >::sentry */ + +/* basic_istream >::sentry */ + +/* basic_filebuf > */ + +/* basic_ifstream > */ + +/* basic_ofstream > */ + +/* basic_fstream > */ + +/* basic_iostream > */ + +/* basic_stringbuf,allocator > */ + +/* basic_istringstream,allocator > */ + +/* basic_ostringstream,allocator > */ + +/* basic_stringstream,allocator > */ + +/********************************************************* +* Global function Stub +*********************************************************/ + +/********************************************************* +* Get size of pointer to member function +*********************************************************/ +class G__Sizep2memfuncG__stream { + public: + G__Sizep2memfuncG__stream(): p(&G__Sizep2memfuncG__stream::sizep2memfunc) {} + size_t sizep2memfunc() { return(sizeof(p)); } + private: + size_t (G__Sizep2memfuncG__stream::*p)(); +}; + +size_t G__get_sizep2memfuncG__stream() +{ + G__Sizep2memfuncG__stream a; + G__setsizep2memfunc((int)a.sizep2memfunc()); + return((size_t)a.sizep2memfunc()); +} + + +/********************************************************* +* virtual base class offset calculation interface +*********************************************************/ + + /* Setting up class inheritance */ +static long G__2vbo_basic_istreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_0(long pobject) { + basic_istream > *G__Lderived=(basic_istream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_istreamlEcharcOchar_traitslEchargRsPgR_ios_base_1(long pobject) { + basic_istream > *G__Lderived=(basic_istream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_0(long pobject) { + basic_ostream > *G__Lderived=(basic_ostream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ostreamlEcharcOchar_traitslEchargRsPgR_ios_base_1(long pobject) { + basic_ostream > *G__Lderived=(basic_ostream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ifstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_ifstream > *G__Lderived=(basic_ifstream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ifstreamlEcharcOchar_traitslEchargRsPgR_ios_base_2(long pobject) { + basic_ifstream > *G__Lderived=(basic_ifstream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ofstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_ofstream > *G__Lderived=(basic_ofstream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ofstreamlEcharcOchar_traitslEchargRsPgR_ios_base_2(long pobject) { + basic_ofstream > *G__Lderived=(basic_ofstream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_2(long pobject) { + basic_fstream > *G__Lderived=(basic_fstream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_ios_base_3(long pobject) { + basic_fstream > *G__Lderived=(basic_fstream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_5(long pobject) { + basic_fstream > *G__Lderived=(basic_fstream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_ios_base_6(long pobject) { + basic_fstream > *G__Lderived=(basic_fstream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_iostream > *G__Lderived=(basic_iostream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_ios_base_2(long pobject) { + basic_iostream > *G__Lderived=(basic_iostream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_4(long pobject) { + basic_iostream > *G__Lderived=(basic_iostream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_ios_base_5(long pobject) { + basic_iostream > *G__Lderived=(basic_iostream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_istringstream,allocator > *G__Lderived=(basic_istringstream,allocator >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_2(long pobject) { + basic_istringstream,allocator > *G__Lderived=(basic_istringstream,allocator >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_ostringstream,allocator > *G__Lderived=(basic_ostringstream,allocator >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_2(long pobject) { + basic_ostringstream,allocator > *G__Lderived=(basic_ostringstream,allocator >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_2(long pobject) { + basic_stringstream,allocator > *G__Lderived=(basic_stringstream,allocator >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_3(long pobject) { + basic_stringstream,allocator > *G__Lderived=(basic_stringstream,allocator >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_5(long pobject) { + basic_stringstream,allocator > *G__Lderived=(basic_stringstream,allocator >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_6(long pobject) { + basic_stringstream,allocator > *G__Lderived=(basic_stringstream,allocator >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + + +/********************************************************* +* Inheritance information setup/ +*********************************************************/ +extern "C" void G__cpp_setup_inheritanceG__stream() { + + /* Setting up class inheritance */ + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR))) { + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_istreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_0,1,3); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_istreamlEcharcOchar_traitslEchargRsPgR_ios_base_1,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR))) { + basic_ios > *G__Lderived; + G__Lderived=(basic_ios >*)0x1000; + { + ios_base *G__Lpbase=(ios_base*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__Lpbase-(long)G__Lderived,1,1); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR))) { + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_ostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_0,1,3); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_ostreamlEcharcOchar_traitslEchargRsPgR_ios_base_1,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR))) { + basic_filebuf > *G__Lderived; + G__Lderived=(basic_filebuf >*)0x1000; + { + basic_streambuf > *G__Lpbase=(basic_streambuf >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR))) { + basic_ifstream > *G__Lderived; + G__Lderived=(basic_ifstream >*)0x1000; + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_ifstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_ifstreamlEcharcOchar_traitslEchargRsPgR_ios_base_2,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR))) { + basic_ofstream > *G__Lderived; + G__Lderived=(basic_ofstream >*)0x1000; + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_ofstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_ofstreamlEcharcOchar_traitslEchargRsPgR_ios_base_2,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR))) { + basic_fstream > *G__Lderived; + G__Lderived=(basic_fstream >*)0x1000; + { + basic_iostream > *G__Lpbase=(basic_iostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,0); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_2,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_ios_base_3,1,6); + } + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,0); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_5,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_ios_base_6,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR))) { + basic_iostream > *G__Lderived; + G__Lderived=(basic_iostream >*)0x1000; + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_ios_base_2,1,6); + } + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_4,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_ios_base_5,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR))) { + basic_stringbuf,allocator > *G__Lderived; + G__Lderived=(basic_stringbuf,allocator >*)0x1000; + { + basic_streambuf > *G__Lpbase=(basic_streambuf >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR))) { + basic_istringstream,allocator > *G__Lderived; + G__Lderived=(basic_istringstream,allocator >*)0x1000; + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_2,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR))) { + basic_ostringstream,allocator > *G__Lderived; + G__Lderived=(basic_ostringstream,allocator >*)0x1000; + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_2,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR))) { + basic_stringstream,allocator > *G__Lderived; + G__Lderived=(basic_stringstream,allocator >*)0x1000; + { + basic_iostream > *G__Lpbase=(basic_iostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,0); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_2,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_3,1,6); + } + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,0); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_5,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_6,1,6); + } + } +} + +/********************************************************* +* typedef information setup/ +*********************************************************/ +extern "C" void G__cpp_setup_typetableG__stream() { + + /* Setting up typedef entry */ + G__search_typename2("FILE",101,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("mbstate_t",117,G__get_linked_tagnum(&G__G__streamLN_mbstate_t),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("streampos",108,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("streamoff",108,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("SZ_T",108,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("streamsize",108,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("iostate",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,NULL,0); + G__search_typename2("openmode",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,NULL,0); + G__search_typename2("seekdir",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,NULL,0); + G__search_typename2("fmtflags",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,NULL,0); + G__search_typename2("event_callback",89,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,"void (*event_callback) (event, ios_base&, int index);",0); + G__search_typename2("INT_T",105,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("state_type",117,G__get_linked_tagnum(&G__G__streamLN_mbstate_t),0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("basic_streambuf >",117,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Myt",117,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Myios",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Myt",117,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Myios",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Mysb",117,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("istream",117,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("ostream",117,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("filebuf",117,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ifstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ofstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("fstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Mystr",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("stringbuf",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("sb_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Mystr",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("istringstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("sb_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Mystr",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ostringstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("sb_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Mystr",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("stringstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); +} + +/********************************************************* +* Data Member information setup/ +*********************************************************/ + + /* Setting up class,struct,union tag member variable */ + + /* mbstate_t */ +static void G__setup_memvarmbstate_t(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_mbstate_t)); + { mbstate_t *p; p=(mbstate_t*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* ios_base */ +static void G__setup_memvarios_base(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_ios_base)); + { ios_base *p; p=(ios_base*)0x1000; if (p) { } + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLio_state),-1,-2,1,G__FastAllocString(2048).Format("goodbit=%lldLL",(long long)ios_base::goodbit).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLio_state),-1,-2,1,G__FastAllocString(2048).Format("badbit=%lldLL",(long long)ios_base::badbit).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLio_state),-1,-2,1,G__FastAllocString(2048).Format("eofbit=%lldLL",(long long)ios_base::eofbit).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLio_state),-1,-2,1,G__FastAllocString(2048).Format("failbit=%lldLL",(long long)ios_base::failbit).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("app=%lldLL",(long long)ios_base::app).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("binary=%lldLL",(long long)ios_base::binary).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("in=%lldLL",(long long)ios_base::in).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("out=%lldLL",(long long)ios_base::out).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("trunc=%lldLL",(long long)ios_base::trunc).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("ate=%lldLL",(long long)ios_base::ate).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLseek_dir),-1,-2,1,G__FastAllocString(2048).Format("beg=%lldLL",(long long)ios_base::beg).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLseek_dir),-1,-2,1,G__FastAllocString(2048).Format("cur=%lldLL",(long long)ios_base::cur).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLseek_dir),-1,-2,1,G__FastAllocString(2048).Format("end=%lldLL",(long long)ios_base::end).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("boolalpha=%lldLL",(long long)ios_base::boolalpha).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("dec=%lldLL",(long long)ios_base::dec).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("fixed=%lldLL",(long long)ios_base::fixed).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("hex=%lldLL",(long long)ios_base::hex).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("internal=%lldLL",(long long)ios_base::internal).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("left=%lldLL",(long long)ios_base::left).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("oct=%lldLL",(long long)ios_base::oct).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("right=%lldLL",(long long)ios_base::right).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("scientific=%lldLL",(long long)ios_base::scientific).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("showbase=%lldLL",(long long)ios_base::showbase).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("showpoint=%lldLL",(long long)ios_base::showpoint).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("showpos=%lldLL",(long long)ios_base::showpos).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("skipws=%lldLL",(long long)ios_base::skipws).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("unitbuf=%lldLL",(long long)ios_base::unitbuf).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("uppercase=%lldLL",(long long)ios_base::uppercase).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("adjustfield=%lldLL",(long long)ios_base::adjustfield).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("basefield=%lldLL",(long long)ios_base::basefield).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("floatfield=%lldLL",(long long)ios_base::floatfield).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLevent),-1,-2,1,G__FastAllocString(2048).Format("erase_event=%lldLL",(long long)ios_base::erase_event).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLevent),-1,-2,1,G__FastAllocString(2048).Format("imbue_event=%lldLL",(long long)ios_base::imbue_event).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLevent),-1,-2,1,G__FastAllocString(2048).Format("copyfmt_event=%lldLL",(long long)ios_base::copyfmt_event).data(),0,(char*)NULL); + } + G__tag_memvar_reset(); +} + + + /* ios_base::Init */ +static void G__setup_memvarios_basecLcLInit(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit)); + { ios_base::Init *p; p=(ios_base::Init*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* char_traits */ +static void G__setup_memvarchar_traitslEchargR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + { char_traits *p; p=(char_traits*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_istream > */ +static void G__setup_memvarbasic_istreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + { basic_istream > *p; p=(basic_istream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ios > */ +static void G__setup_memvarbasic_ioslEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + { basic_ios > *p; p=(basic_ios >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_streambuf > */ +static void G__setup_memvarbasic_streambuflEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + { basic_streambuf > *p; p=(basic_streambuf >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ostream > */ +static void G__setup_memvarbasic_ostreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + { basic_ostream > *p; p=(basic_ostream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ostream >::sentry */ +static void G__setup_memvarbasic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + { basic_ostream >::sentry *p; p=(basic_ostream >::sentry*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_istream >::sentry */ +static void G__setup_memvarbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + { basic_istream >::sentry *p; p=(basic_istream >::sentry*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_filebuf > */ +static void G__setup_memvarbasic_filebuflEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + { basic_filebuf > *p; p=(basic_filebuf >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ifstream > */ +static void G__setup_memvarbasic_ifstreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + { basic_ifstream > *p; p=(basic_ifstream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ofstream > */ +static void G__setup_memvarbasic_ofstreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + { basic_ofstream > *p; p=(basic_ofstream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_fstream > */ +static void G__setup_memvarbasic_fstreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR)); + { basic_fstream > *p; p=(basic_fstream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_iostream > */ +static void G__setup_memvarbasic_iostreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR)); + { basic_iostream > *p; p=(basic_iostream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_stringbuf,allocator > */ +static void G__setup_memvarbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + { basic_stringbuf,allocator > *p; p=(basic_stringbuf,allocator >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_istringstream,allocator > */ +static void G__setup_memvarbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + { basic_istringstream,allocator > *p; p=(basic_istringstream,allocator >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ostringstream,allocator > */ +static void G__setup_memvarbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + { basic_ostringstream,allocator > *p; p=(basic_ostringstream,allocator >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_stringstream,allocator > */ +static void G__setup_memvarbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + { basic_stringstream,allocator > *p; p=(basic_stringstream,allocator >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + +extern "C" void G__cpp_setup_memvarG__stream() { +} +/*********************************************************** +************************************************************ +************************************************************ +************************************************************ +************************************************************ +************************************************************ +************************************************************ +***********************************************************/ + +/********************************************************* +* Member function information setup for each class +*********************************************************/ +static void G__setup_memfuncmbstate_t(void) { + /* mbstate_t */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_mbstate_t)); + // automatic default constructor + G__memfunc_setup("mbstate_t", 963, G__G__stream_1_0_1, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_mbstate_t), -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic copy constructor + G__memfunc_setup("mbstate_t", 963, G__G__stream_1_0_2, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_mbstate_t), -1, 0, 1, 1, 1, 0, "u 'mbstate_t' - 11 - -", (char*) NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~mbstate_t", 1089, G__G__stream_1_0_3, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic assignment operator + G__memfunc_setup("operator=", 937, G__G__stream_1_0_4, (int) ('u'), G__get_linked_tagnum(&G__G__streamLN_mbstate_t), -1, 1, 1, 1, 1, 0, "u 'mbstate_t' - 11 - -", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncios_base(void) { + /* ios_base */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__memfunc_setup("register_callback",1777,G__G__stream_2_0_1, 121, -1, -1, 0, 2, 1, 1, 0, +"Y - 'ios_base::event_callback' 0 - fn i - - 0 - index", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("flags",525,G__G__stream_2_0_2, 105, -1, G__defined_typename("ios_base::fmtflags"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("flags",525,G__G__stream_2_0_3, 105, -1, G__defined_typename("ios_base::fmtflags"), 0, 1, 1, 1, 0, "i - 'ios_base::fmtflags' 0 - fmtfl", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("setf",434,G__G__stream_2_0_4, 105, -1, G__defined_typename("ios_base::fmtflags"), 0, 1, 1, 1, 0, "i - 'ios_base::fmtflags' 0 - fmtfl", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("setf",434,G__G__stream_2_0_5, 105, -1, G__defined_typename("ios_base::fmtflags"), 0, 2, 1, 1, 0, +"i - 'ios_base::fmtflags' 0 - fmtfl i - 'ios_base::fmtflags' 0 - mask", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("unsetf",661,G__G__stream_2_0_6, 121, -1, -1, 0, 1, 1, 1, 0, "i - 'ios_base::fmtflags' 0 - mask", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("precision",972,G__G__stream_2_0_7, 108, -1, G__defined_typename("streamsize"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("precision",972,G__G__stream_2_0_8, 108, -1, G__defined_typename("streamsize"), 0, 1, 1, 1, 0, "l - 'streamsize' 0 - prec", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("width",544,G__G__stream_2_0_9, 108, -1, G__defined_typename("streamsize"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("width",544,G__G__stream_2_0_10, 108, -1, G__defined_typename("streamsize"), 0, 1, 1, 1, 0, "l - 'streamsize' 0 - wide", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("xalloc",643,G__G__stream_2_0_11, 105, -1, -1, 0, 0, 3, 1, 0, "", (char*)NULL, (void*) G__func2void( (int (*)())(&ios_base::xalloc) ), 0); + G__memfunc_setup("iword",549,G__G__stream_2_0_12, 108, -1, -1, 1, 1, 1, 1, 0, "i - - 0 - index", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pword",556,G__G__stream_2_0_13, 89, -1, -1, 1, 1, 1, 1, 0, "i - - 0 - index", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sync_with_stdio",1626,G__G__stream_2_0_14, 103, -1, -1, 0, 1, 3, 1, 0, "g - - 0 'true' sync", (char*)NULL, (void*) G__func2void( (bool (*)(bool))(&ios_base::sync_with_stdio) ), 0); + G__memfunc_setup("ios_base",837,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 2, 0, "u 'ios_base' - 11 - x", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("ios_base",837,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 0, 1, 1, 4, 0, "u 'ios_base' - 11 - -", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~ios_base", 963, G__G__stream_2_0_18, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncios_basecLcLInit(void) { + /* ios_base::Init */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit)); + G__memfunc_setup("Init",404,G__G__stream_8_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic copy constructor + G__memfunc_setup("Init", 404, G__G__stream_8_0_2, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit), -1, 0, 1, 1, 1, 0, "u 'ios_base::Init' - 11 - -", (char*) NULL, (void*) NULL, 0); + // automatic assignment operator + G__memfunc_setup("operator=", 937, G__G__stream_8_0_3, (int) ('u'), G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit), -1, 1, 1, 1, 1, 0, "u 'ios_base::Init' - 11 - -", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncchar_traitslEchargR(void) { + /* char_traits */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__memfunc_setup("assign",645,G__G__stream_9_0_1, 121, -1, -1, 0, 2, 3, 1, 0, +"c - 'char_traits::char_type' 1 - c1 c - 'char_traits::char_type' 11 - c2", (char*)NULL, (void*) G__func2void( (void (*)(char_traits::char_type&, const char_traits::char_type&))(&char_traits::assign) ), 0); + G__memfunc_setup("to_char_type",1281,G__G__stream_9_0_2, 99, -1, G__defined_typename("char_traits::char_type"), 0, 1, 3, 1, 0, "i - 'char_traits::int_type' 11 - c", (char*)NULL, (void*) G__func2void( (char_traits::char_type (*)(const char_traits::int_type&))(&char_traits::to_char_type) ), 0); + G__memfunc_setup("to_int_type",1198,G__G__stream_9_0_3, 105, -1, G__defined_typename("char_traits::int_type"), 0, 1, 3, 1, 0, "c - 'char_traits::char_type' 11 - c", (char*)NULL, (void*) G__func2void( (char_traits::int_type (*)(const char_traits::char_type&))(&char_traits::to_int_type) ), 0); + G__memfunc_setup("eq",214,G__G__stream_9_0_4, 103, -1, -1, 0, 2, 3, 1, 0, +"c - 'char_traits::char_type' 11 - c1 c - 'char_traits::char_type' 11 - c2", (char*)NULL, (void*) G__func2void( (bool (*)(const char_traits::char_type&, const char_traits::char_type&))(&char_traits::eq) ), 0); + G__memfunc_setup("lt",224,G__G__stream_9_0_5, 103, -1, -1, 0, 2, 3, 1, 0, +"c - 'char_traits::char_type' 11 - c1 c - 'char_traits::char_type' 11 - c2", (char*)NULL, (void*) G__func2void( (bool (*)(const char_traits::char_type&, const char_traits::char_type&))(&char_traits::lt) ), 0); + G__memfunc_setup("compare",743,G__G__stream_9_0_6, 105, -1, -1, 0, 3, 3, 1, 0, +"C - 'char_traits::char_type' 10 - s1 C - 'char_traits::char_type' 10 - s2 " +"h - 'size_t' 0 - n", (char*)NULL, (void*) G__func2void( (int (*)(const char_traits::char_type*, const char_traits::char_type*, size_t))(&char_traits::compare) ), 0); + G__memfunc_setup("find",417,G__G__stream_9_0_7, 67, -1, G__defined_typename("char_traits::char_type"), 0, 3, 3, 1, 1, +"C - 'char_traits::char_type' 10 - s i - - 0 - n " +"c - 'char_traits::char_type' 11 - a", (char*)NULL, (void*) G__func2void( (const char_traits::char_type* (*)(const char_traits::char_type*, int, const char_traits::char_type&))(&char_traits::find) ), 0); + G__memfunc_setup("eq_int_type",1185,G__G__stream_9_0_8, 103, -1, -1, 0, 2, 3, 1, 0, +"i - 'char_traits::int_type' 11 - c1 i - 'char_traits::int_type' 11 - c2", (char*)NULL, (void*) G__func2void( (bool (*)(const char_traits::int_type&, const char_traits::int_type&))(&char_traits::eq_int_type) ), 0); + G__memfunc_setup("eof",314,G__G__stream_9_0_9, 105, -1, G__defined_typename("char_traits::int_type"), 0, 0, 3, 1, 0, "", (char*)NULL, (void*) G__func2void( (char_traits::int_type (*)())(&char_traits::eof) ), 0); + G__memfunc_setup("not_eof",746,G__G__stream_9_0_10, 105, -1, G__defined_typename("char_traits::int_type"), 0, 1, 3, 1, 0, "i - 'char_traits::int_type' 11 - c", (char*)NULL, (void*) G__func2void( (char_traits::int_type (*)(const char_traits::int_type&))(&char_traits::not_eof) ), 0); + G__memfunc_setup("length",642,G__G__stream_9_0_11, 104, -1, G__defined_typename("size_t"), 0, 1, 3, 1, 0, "C - 'char_traits::char_type' 10 - s", (char*)NULL, (void*) G__func2void( (size_t (*)(const char_traits::char_type*))(&char_traits::length) ), 0); + G__memfunc_setup("copy",443,G__G__stream_9_0_12, 67, -1, G__defined_typename("char_traits::char_type"), 0, 3, 3, 1, 0, +"C - 'char_traits::char_type' 0 - dst C - 'char_traits::char_type' 10 - src " +"h - 'size_t' 0 - n", (char*)NULL, (void*) G__func2void( (char_traits::char_type* (*)(char_traits::char_type*, const char_traits::char_type*, size_t))(&char_traits::copy) ), 0); + G__memfunc_setup("move",439,G__G__stream_9_0_13, 67, -1, G__defined_typename("char_traits::char_type"), 0, 3, 3, 1, 0, +"C - 'char_traits::char_type' 0 - s1 C - 'char_traits::char_type' 10 - s2 " +"h - 'size_t' 0 - n", (char*)NULL, (void*) G__func2void( (char_traits::char_type* (*)(char_traits::char_type*, const char_traits::char_type*, size_t))(&char_traits::move) ), 0); + G__memfunc_setup("assign",645,G__G__stream_9_0_14, 67, -1, G__defined_typename("char_traits::char_type"), 0, 3, 3, 1, 0, +"C - 'char_traits::char_type' 0 - s h - 'size_t' 0 - n " +"c - 'char_traits::char_type' 10 - a", (char*)NULL, (void*) NULL, 0); + // automatic default constructor + G__memfunc_setup("char_traits", 1708, G__G__stream_9_0_15, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR), -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic copy constructor + G__memfunc_setup("char_traits", 1708, G__G__stream_9_0_16, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR), -1, 0, 1, 1, 1, 0, "u 'char_traits' - 11 - -", (char*) NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~char_traits", 1834, G__G__stream_9_0_17, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic assignment operator + G__memfunc_setup("operator=", 937, G__G__stream_9_0_18, (int) ('u'), G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR), -1, 1, 1, 1, 1, 0, "u 'char_traits' - 11 - -", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_istreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_istream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_istream >",3686,G__G__stream_10_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 5, 1, 0, "U 'basic_streambuf >' - 0 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_10_0_2, 105, -1, G__defined_typename("basic_istream >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_10_0_3, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 3, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s l - 'streamsize' 0 - n " +"c - 'basic_istream >::char_type' 0 - delim", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_10_0_4, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 2, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_10_0_5, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 1, 1, 1, 0, "c - 'basic_istream >::char_type' 1 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_10_0_6, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 2, 1, 1, 0, +"u 'basic_streambuf >' 'basic_istream >::_Mysb' 1 - sb c - 'basic_istream >::char_type' 0 - delim", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_10_0_7, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 1, 1, 1, 0, "u 'basic_streambuf >' 'basic_istream >::_Mysb' 1 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("getline",744,G__G__stream_10_0_8, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 3, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s l - 'streamsize' 0 - n " +"c - 'basic_istream >::char_type' 0 - delim", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("getline",744,G__G__stream_10_0_9, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 2, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("ignore",644,G__G__stream_10_0_10, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 2, 1, 1, 0, +"l - 'streamsize' 0 - n i - 'basic_istream >::int_type' 0 - delim", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("ignore",644,G__G__stream_10_0_11, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 1, 1, 1, 0, "l - 'streamsize' 0 '1' n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("read",412,G__G__stream_10_0_12, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 2, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("readsome",848,G__G__stream_10_0_13, 108, -1, G__defined_typename("streamsize"), 0, 2, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("peek",421,G__G__stream_10_0_14, 105, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("tellg",536,G__G__stream_10_0_15, 108, -1, G__defined_typename("basic_istream >::pos_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("seekg",527,G__G__stream_10_0_16, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 1, 1, 1, 0, "l - 'basic_istream >::pos_type' 0 - pos", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sync",445,G__G__stream_10_0_17, 105, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("seekg",527,G__G__stream_10_0_18, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 2, 1, 1, 0, +"l - 'basic_istream >::off_type' 0 - - i - 'ios_base::seekdir' 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("putback",746,G__G__stream_10_0_19, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 1, 1, 1, 0, "c - 'basic_istream >::char_type' 0 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("unget",547,G__G__stream_10_0_20, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("gcount",656,G__G__stream_10_0_21, 108, -1, G__defined_typename("streamsize"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_istream >",3686,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_istream >", 3812, G__G__stream_10_0_23, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ioslEcharcOchar_traitslEchargRsPgR(void) { + /* basic_ios > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_ios >",3260,G__G__stream_11_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 5, 1, 0, "U 'basic_streambuf >' - 0 - sb_arg", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("fill",423,G__G__stream_11_0_2, 99, -1, G__defined_typename("basic_ios >::char_type"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("fill",423,G__G__stream_11_0_3, 99, -1, G__defined_typename("basic_ios >::char_type"), 0, 1, 1, 1, 0, "c - 'basic_ios >::char_type' 0 - ch", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("exceptions",1090,G__G__stream_11_0_4, 121, -1, -1, 0, 1, 1, 1, 0, "i - 'ios_base::iostate' 0 - excpt", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("exceptions",1090,G__G__stream_11_0_5, 105, -1, G__defined_typename("ios_base::iostate"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("clear",519,G__G__stream_11_0_6, 121, -1, -1, 0, 1, 1, 1, 0, "i - 'ios_base::iostate' 0 'goodbit' state", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("setstate",877,G__G__stream_11_0_7, 121, -1, -1, 0, 1, 1, 1, 0, "i - 'ios_base::iostate' 0 - state", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdstate",759,G__G__stream_11_0_8, 105, -1, G__defined_typename("ios_base::iostate"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator void*",1384,G__G__stream_11_0_9, 89, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator!",909,G__G__stream_11_0_10, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("good",425,G__G__stream_11_0_11, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("eof",314,G__G__stream_11_0_12, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("fail",412,G__G__stream_11_0_13, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("bad",295,G__G__stream_11_0_14, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("copyfmt",770,G__G__stream_11_0_15, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 1, 0, "u 'basic_ios >' - 11 - rhs", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("tie",322,G__G__stream_11_0_16, 85, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("tie",322,G__G__stream_11_0_17, 85, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 1, 1, 0, "U 'basic_ostream >' - 0 - tie_arg", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_11_0_18, 85, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_11_0_19, 85, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 1, 1, 0, "U 'basic_streambuf >' - 0 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("narrow",665,G__G__stream_11_0_20, 99, -1, -1, 0, 2, 1, 1, 8, +"c - - 0 - - c - - 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("widen",535,G__G__stream_11_0_21, 99, -1, -1, 0, 1, 1, 1, 8, "c - - 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ios >",3260,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ios >",3260,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 1, 4, 0, "u 'basic_ios >' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 4, 0, "u 'basic_ios >' - 11 - -", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ios >", 3386, G__G__stream_11_0_26, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_streambuflEcharcOchar_traitslEchargRsPgR(void) { + /* basic_streambuf > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_streambuf >",3898,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 1, 4, 0, "u 'basic_streambuf >' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 4, 0, "u 'basic_streambuf >' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pubsetbuf",976,G__G__stream_12_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_streambuf >::basic_streambuf >"), 0, 2, 1, 1, 0, +"C - 'basic_streambuf >::char_type' 0 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pubseekoff",1066,G__G__stream_12_0_4, 108, -1, G__defined_typename("basic_streambuf >::pos_type"), 0, 3, 1, 1, 0, +"l - 'basic_streambuf >::off_type' 0 - off i - 'ios_base::seekdir' 0 - way " +"i - 'ios_base::openmode' 0 'ios_base::in|ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pubseekpos",1089,G__G__stream_12_0_5, 108, -1, G__defined_typename("basic_streambuf >::pos_type"), 0, 2, 1, 1, 0, +"l - 'basic_streambuf >::pos_type' 0 - sp i - 'ios_base::openmode' 0 'ios_base::in|ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pubsync",772,G__G__stream_12_0_6, 105, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("in_avail",835,G__G__stream_12_0_7, 108, -1, G__defined_typename("streamsize"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("snextc",661,G__G__stream_12_0_8, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sbumpc",650,G__G__stream_12_0_9, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sgetc",534,G__G__stream_12_0_10, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sgetn",545,G__G__stream_12_0_11, 108, -1, G__defined_typename("streamsize"), 0, 2, 1, 1, 0, +"C - 'basic_streambuf >::char_type' 0 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sputbackc",960,G__G__stream_12_0_12, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 1, 1, 1, 0, "c - 'basic_streambuf >::char_type' 0 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sungetc",761,G__G__stream_12_0_13, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sputc",559,G__G__stream_12_0_14, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 1, 1, 1, 0, "c - 'basic_streambuf >::char_type' 0 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sputn",570,G__G__stream_12_0_15, 108, -1, G__defined_typename("streamsize"), 0, 2, 1, 1, 0, +"C - 'basic_streambuf >::char_type' 10 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_streambuf >",3898,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_streambuf >", 4024, G__G__stream_12_0_17, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ostreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_ostream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_ostream >",3692,G__G__stream_13_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 5, 1, 0, "U 'basic_streambuf >' - 0 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("put",345,G__G__stream_13_0_2, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_ostream >::_Myt"), 1, 1, 1, 1, 0, "c - 'basic_ostream >::char_type' 0 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("write",555,G__G__stream_13_0_3, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_ostream >::_Myt"), 1, 2, 1, 1, 0, +"C - 'basic_ostream >::char_type' 10 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("flush",546,G__G__stream_13_0_4, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_ostream >::_Myt"), 1, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("seekp",536,G__G__stream_13_0_5, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_ostream >::_Myt"), 1, 1, 1, 1, 0, "l - 'basic_ostream >::pos_type' 0 - pos", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("seekp",536,G__G__stream_13_0_6, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_ostream >::_Myt"), 1, 2, 1, 1, 0, +"l - 'basic_ostream >::off_type' 0 - - i - 'ios_base::seekdir' 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("tellp",545,G__G__stream_13_0_7, 108, -1, G__defined_typename("basic_ostream >::pos_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ostream >",3692,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ostream >", 3818, G__G__stream_13_0_9, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(void) { + /* basic_ostream >::sentry */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + G__memfunc_setup("sentry",677,G__G__stream_14_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 0, 1, 5, 1, 0, "u 'basic_ostream >' - 1 - stream", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sentry",677,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 0, 1, 1, 4, 0, "u 'basic_ostream >::sentry' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 1, 1, 1, 4, 0, "u 'basic_ostream >::sentry' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(void) { + /* basic_istream >::sentry */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + G__memfunc_setup("sentry",677,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 0, 1, 1, 4, 0, "u 'basic_istream >::sentry' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 1, 1, 1, 4, 0, "u 'basic_istream >::sentry' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sentry",677,G__G__stream_15_0_3, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 0, 2, 5, 1, 0, +"u 'basic_istream >' - 1 - stream g - - 0 '0' noskipws", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~sentry", 803, G__G__stream_15_0_4, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_filebuflEcharcOchar_traitslEchargRsPgR(void) { + /* basic_filebuf > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_filebuf >",3662,G__G__stream_16_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("is_open",749,G__G__stream_16_0_2, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("open",434,G__G__stream_16_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("close",534,G__G__stream_16_0_4, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 4, 0, "u 'basic_filebuf >' - 11 - x", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_filebuf >", 3788, G__G__stream_16_0_15, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ifstreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_ifstream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_ifstream >",3788,G__G__stream_17_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ifstream >",3788,G__G__stream_17_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 'ios_base::in' mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_17_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("is_open",749,G__G__stream_17_0_4, 103, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("open",434,G__G__stream_17_0_5, 121, -1, -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 'ios_base::in' mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("close",534,G__G__stream_17_0_6, 121, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ifstream >", 3914, G__G__stream_17_0_7, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ofstreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_ofstream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_ofstream >",3794,G__G__stream_18_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ofstream >",3794,G__G__stream_18_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 'ios_base::out' mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_18_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("is_open",749,G__G__stream_18_0_4, 103, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("open",434,G__G__stream_18_0_5, 121, -1, -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 'ios_base::out' mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("close",534,G__G__stream_18_0_6, 121, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ofstream >", 3920, G__G__stream_18_0_7, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_fstreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_fstream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_fstream >",3683,G__G__stream_19_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_fstream >",3683,G__G__stream_19_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 - mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_19_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("is_open",749,G__G__stream_19_0_4, 103, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("open",434,G__G__stream_19_0_5, 121, -1, -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 - mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("close",534,G__G__stream_19_0_6, 121, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_fstream >", 3809, G__G__stream_19_0_7, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_iostreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_iostream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_iostream >",3797,G__G__stream_20_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 5, 1, 0, "U 'basic_streambuf >' - 0 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_iostream >",3797,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 5, 2, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_iostream >", 3923, G__G__stream_20_0_3, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + /* basic_stringbuf,allocator > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__memfunc_setup("basic_stringbuf,allocator >",5450,G__G__stream_23_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 1, 5, 1, 0, "i - 'ios_base::openmode' 0 'ios_base::in|ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_stringbuf,allocator >",5450,G__G__stream_23_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"u 'basic_string,allocator >' 'basic_stringbuf,allocator >::_Mystr' 11 - str i - 'ios_base::openmode' 0 'ios_base::in|ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_23_0_3, 117, G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), G__defined_typename("basic_stringbuf,allocator >::_Mystr"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_23_0_4, 121, -1, -1, 0, 1, 1, 1, 0, "u 'basic_string,allocator >' 'basic_stringbuf,allocator >::_Mystr' 11 - str_arg", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 1, 1, 1, 4, 0, "u 'basic_stringbuf,allocator >' - 11 - x", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_stringbuf,allocator >", 5576, G__G__stream_23_0_13, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + /* basic_istringstream,allocator > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__memfunc_setup("basic_istringstream,allocator >",5890,G__G__stream_25_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 1, 5, 1, 0, "i - 'ios_base::openmode' 0 'ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_istringstream,allocator >",5890,G__G__stream_25_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"u 'basic_string,allocator >' 'basic_istringstream,allocator >::_Mystr' 11 - str i - 'ios_base::openmode' 0 'ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_istringstream,allocator >",5890,G__G__stream_25_0_3, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"C - - 10 - str i - 'ios_base::openmode' 0 'ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_25_0_4, 85, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_25_0_5, 117, G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), G__defined_typename("basic_istringstream,allocator >::_Mystr"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_25_0_6, 121, -1, -1, 0, 1, 1, 1, 0, "u 'basic_string,allocator >' 'basic_istringstream,allocator >::_Mystr' 11 - str", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_istringstream,allocator >", 6016, G__G__stream_25_0_7, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + /* basic_ostringstream,allocator > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__memfunc_setup("basic_ostringstream,allocator >",5896,G__G__stream_26_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 1, 5, 1, 0, "i - 'ios_base::openmode' 0 'ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ostringstream,allocator >",5896,G__G__stream_26_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"u 'basic_string,allocator >' 'basic_ostringstream,allocator >::_Mystr' 11 - str i - 'ios_base::openmode' 0 'ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_26_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_26_0_4, 117, G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), G__defined_typename("basic_ostringstream,allocator >::_Mystr"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_26_0_5, 121, -1, -1, 0, 1, 1, 1, 0, "u 'basic_string,allocator >' 'basic_ostringstream,allocator >::_Mystr' 11 - str", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ostringstream,allocator >", 6022, G__G__stream_26_0_6, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + /* basic_stringstream,allocator > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__memfunc_setup("basic_stringstream,allocator >",5785,G__G__stream_27_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 1, 5, 1, 0, "i - 'ios_base::openmode' 0 'ios_base::out|ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_stringstream,allocator >",5785,G__G__stream_27_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"u 'basic_string,allocator >' 'basic_stringstream,allocator >::_Mystr' 11 - str i - 'ios_base::openmode' 0 'ios_base::out|ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_27_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_27_0_4, 117, G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), G__defined_typename("basic_stringstream,allocator >::_Mystr"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_27_0_5, 121, -1, -1, 0, 1, 1, 1, 0, "u 'basic_string,allocator >' 'basic_stringstream,allocator >::_Mystr' 11 - str", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_stringstream,allocator >", 5911, G__G__stream_27_0_6, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + + +/********************************************************* +* Member function information setup +*********************************************************/ +extern "C" void G__cpp_setup_memfuncG__stream() { +} + +/********************************************************* +* Global variable information setup for each class +*********************************************************/ +static void G__cpp_setup_global0() { + + /* Setting up global variables */ + G__resetplocal(); + + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"_MSC_VER=1700",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__IOSTREAM_H=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__TMPLTIOS=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__OSTREAMBODY=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__OSTREAMGLOBALSTUB=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__STDIO_H=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"_IOFBF=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"_IOLBF=1",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"_IONBF=2",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"BUFSIZ=8192",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"FILENAME_MAX=4096",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"L_tmpnam=20",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"TMP_MAX=238328",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"SEEK_CUR=1",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"SEEK_END=2",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"SEEK_SET=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__MANIP_SUPPORT=0",1,(char*)NULL); + G__memvar_setup((void*)(&cin),117,0,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),G__defined_typename("istream"),-1,1,"cin=",0,(char*)NULL); + G__memvar_setup((void*)(&cout),117,0,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__defined_typename("ostream"),-1,1,"cout=",0,(char*)NULL); + G__memvar_setup((void*)(&cerr),117,0,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__defined_typename("ostream"),-1,1,"cerr=",0,(char*)NULL); + G__memvar_setup((void*)(&clog),117,0,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__defined_typename("ostream"),-1,1,"clog=",0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__FSTREAM_H=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__SSTREAM_H=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__STRING_H=0",1,(char*)NULL); + + G__resetglobalenv(); +} +extern "C" void G__cpp_setup_globalG__stream() { + G__cpp_setup_global0(); +} + +/********************************************************* +* Global function information setup for each class +*********************************************************/ +static void G__cpp_setup_func0() { + G__lastifuncposition(); + + G__memfunc_setup("dec", 300, G__G__stream__0_0, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("hex", 325, G__G__stream__0_1, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("oct", 326, G__G__stream__0_2, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("fixed", 528, G__G__stream__0_3, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("scientific", 1057, G__G__stream__0_4, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("right", 542, G__G__stream__0_5, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("left", 427, G__G__stream__0_6, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("internal", 861, G__G__stream__0_7, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("nouppercase", 1189, G__G__stream__0_8, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("uppercase", 968, G__G__stream__0_9, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noskipws", 894, G__G__stream__0_10, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("skipws", 673, G__G__stream__0_11, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noshowpos", 1008, G__G__stream__0_12, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("showpos", 787, G__G__stream__0_13, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noshowpoint", 1224, G__G__stream__0_14, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("showpoint", 1003, G__G__stream__0_15, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noshowbase", 1081, G__G__stream__0_16, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("showbase", 860, G__G__stream__0_17, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noboolalpha", 1167, G__G__stream__0_18, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("boolalpha", 946, G__G__stream__0_19, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("ws", 234, G__G__stream__0_20, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 1, 1, 1, 0, "u 'basic_istream >' 'istream' 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("endl", 419, G__G__stream__0_21, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 1, 1, 1, 0, "u 'basic_ostream >' 'ostream' 1 - i", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("ends", 426, G__G__stream__0_22, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 1, 1, 1, 0, "u 'basic_ostream >' 'ostream' 1 - i", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("flush", 546, G__G__stream__0_23, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 1, 1, 1, 0, "u 'basic_ostream >' 'ostream' 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_24, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - c - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_25, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - C - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_26, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - Y - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_27, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - b - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_28, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - s - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_29, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - r - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_30, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - i - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_31, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - h - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_32, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - l - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_33, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - k - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_34, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - f - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_35, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - d - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_36, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - g - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_37, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - c - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_38, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - b - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_39, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - s - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_40, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - r - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_41, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - i - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_42, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - h - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_43, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - l - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_44, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - k - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_45, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - f - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_46, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - d - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_47, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - g - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_48, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - C - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_49, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - Y - - 1 - -", (char*) NULL +, (void*) NULL, 0); + + G__resetifuncposition(); +} + +extern "C" void G__cpp_setup_funcG__stream() { + G__cpp_setup_func0(); +} + +/********************************************************* +* Class,struct,union,enum tag information setup +*********************************************************/ +/* Setup class/struct taginfo */ +G__linked_taginfo G__G__streamLN_mbstate_t = { "mbstate_t" , 115 , -1 }; +G__linked_taginfo G__G__streamLN_ios_base = { "ios_base" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLio_state = { "ios_base::io_state" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLopen_mode = { "ios_base::open_mode" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLseek_dir = { "ios_base::seek_dir" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLfmt_flags = { "ios_base::fmt_flags" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLevent = { "ios_base::event" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLInit = { "ios_base::Init" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_char_traitslEchargR = { "char_traits" , 115 , -1 }; +G__linked_taginfo G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR = { "basic_istream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR = { "basic_ios >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR = { "basic_streambuf >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR = { "basic_ostream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry = { "basic_ostream >::sentry" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry = { "basic_istream >::sentry" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR = { "basic_filebuf >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR = { "basic_ifstream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR = { "basic_ofstream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR = { "basic_fstream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR = { "basic_iostream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_stringbuf,allocator >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_string,allocator >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_istringstream,allocator >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_ostringstream,allocator >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_stringstream,allocator >" , 99 , -1 }; + +/* Reset class/struct taginfo */ +extern "C" void G__cpp_reset_tagtableG__stream() { + G__G__streamLN_mbstate_t.tagnum = -1 ; + G__G__streamLN_ios_base.tagnum = -1 ; + G__G__streamLN_ios_basecLcLio_state.tagnum = -1 ; + G__G__streamLN_ios_basecLcLopen_mode.tagnum = -1 ; + G__G__streamLN_ios_basecLcLseek_dir.tagnum = -1 ; + G__G__streamLN_ios_basecLcLfmt_flags.tagnum = -1 ; + G__G__streamLN_ios_basecLcLevent.tagnum = -1 ; + G__G__streamLN_ios_basecLcLInit.tagnum = -1 ; + G__G__streamLN_char_traitslEchargR.tagnum = -1 ; + G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry.tagnum = -1 ; + G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry.tagnum = -1 ; + G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; +} + + +extern "C" void G__cpp_setup_tagtableG__stream() { + + /* Setting up class,struct,union tag entry */ + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_mbstate_t),sizeof(mbstate_t),-1,0,(char*)NULL,G__setup_memvarmbstate_t,G__setup_memfuncmbstate_t); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_base),sizeof(ios_base),-1,3840,(char*)NULL,G__setup_memvarios_base,G__setup_memfuncios_base); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLio_state),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLopen_mode),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLseek_dir),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLfmt_flags),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLevent),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLInit),sizeof(ios_base::Init),-1,1280,(char*)NULL,G__setup_memvarios_basecLcLInit,G__setup_memfuncios_basecLcLInit); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_char_traitslEchargR),sizeof(char_traits),-1,0,(char*)NULL,G__setup_memvarchar_traitslEchargR,G__setup_memfuncchar_traitslEchargR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_istream >),-1,34048,(char*)NULL,G__setup_memvarbasic_istreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_istreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),sizeof(basic_ios >),-1,36608,(char*)NULL,G__setup_memvarbasic_ioslEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_ioslEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),sizeof(basic_streambuf >),-1,3840,(char*)NULL,G__setup_memvarbasic_streambuflEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_streambuflEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_ostream >),-1,34048,(char*)NULL,G__setup_memvarbasic_ostreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_ostreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry),sizeof(basic_ostream >::sentry),-1,36352,(char*)NULL,G__setup_memvarbasic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry,G__setup_memfuncbasic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry),sizeof(basic_istream >::sentry),-1,35328,(char*)NULL,G__setup_memvarbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry,G__setup_memfuncbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR),sizeof(basic_filebuf >),-1,3328,(char*)NULL,G__setup_memvarbasic_filebuflEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_filebuflEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_ifstream >),-1,34048,(char*)NULL,G__setup_memvarbasic_ifstreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_ifstreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_ofstream >),-1,34048,(char*)NULL,G__setup_memvarbasic_ofstreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_ofstreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_fstream >),-1,33024,(char*)NULL,G__setup_memvarbasic_fstreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_fstreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_iostream >),-1,34048,(char*)NULL,G__setup_memvarbasic_iostreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_iostreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),sizeof(basic_stringbuf,allocator >),-1,36096,(char*)NULL,G__setup_memvarbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR,G__setup_memfuncbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); + G__get_linked_tagnum_fwd(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),sizeof(basic_istringstream,allocator >),-1,34048,(char*)NULL,G__setup_memvarbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR,G__setup_memfuncbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),sizeof(basic_ostringstream,allocator >),-1,34048,(char*)NULL,G__setup_memvarbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR,G__setup_memfuncbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),sizeof(basic_stringstream,allocator >),-1,34048,(char*)NULL,G__setup_memvarbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR,G__setup_memfuncbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); +} +extern "C" void G__cpp_setupG__stream(void) { + G__check_setup_version(30051515,"G__cpp_setupG__stream()"); + G__set_cpp_environmentG__stream(); + G__cpp_setup_tagtableG__stream(); + + G__cpp_setup_inheritanceG__stream(); + + G__cpp_setup_typetableG__stream(); + + G__cpp_setup_memvarG__stream(); + + G__cpp_setup_memfuncG__stream(); + G__cpp_setup_globalG__stream(); + G__cpp_setup_funcG__stream(); + + if(0==G__getsizep2memfunc()) G__get_sizep2memfuncG__stream(); + return; +} +class G__cpp_setup_initG__stream { + public: + G__cpp_setup_initG__stream() { G__add_setup_func("G__stream",(G__incsetup)(&G__cpp_setupG__stream)); G__call_setup_funcs(); } + ~G__cpp_setup_initG__stream() { G__remove_setup_func("G__stream"); } +}; +G__cpp_setup_initG__stream G__cpp_setup_initializerG__stream; + diff --git a/cint/cint/lib/vc11strm/vc11strm.h b/cint/cint/lib/vc11strm/vc11strm.h new file mode 100644 index 0000000000000..34815817335a1 --- /dev/null +++ b/cint/cint/lib/vc11strm/vc11strm.h @@ -0,0 +1,83 @@ +/******************************************************************** +* vc11strm.h +* CAUTION: DON'T CHANGE THIS FILE. THIS FILE IS AUTOMATICALLY GENERATED +* FROM HEADER FILES LISTED IN G__setup_cpp_environmentXXX(). +* CHANGE THOSE HEADER FILES AND REGENERATE THIS FILE. +********************************************************************/ +#ifdef __CINT__ +#error vc11strm.h/C is only for compilation. Abort cint. +#endif +#include +#include +#include +#include +#include +#define G__ANSIHEADER +#define G__DICTIONARY +#define G__PRIVATE_GVALUE +#include "G__ci.h" +#include "FastAllocString.h" +extern "C" { +extern G__DLLEXPORT int G__cpp_dllrevG__stream(); +extern G__DLLEXPORT void G__set_cpp_environmentG__stream(); +extern G__DLLEXPORT void G__cpp_setup_tagtableG__stream(); +extern G__DLLEXPORT void G__cpp_setup_inheritanceG__stream(); +extern G__DLLEXPORT void G__cpp_setup_typetableG__stream(); +extern G__DLLEXPORT void G__cpp_setup_memvarG__stream(); +extern G__DLLEXPORT void G__cpp_setup_globalG__stream(); +extern G__DLLEXPORT void G__cpp_setup_memfuncG__stream(); +extern G__DLLEXPORT void G__cpp_setup_funcG__stream(); +extern G__DLLEXPORT void G__cpp_setupG__stream(); +} + + +#include "iostrm.h" +#include "fstrm.h" +#include "sstrm.h" + +#ifndef G__MEMFUNCBODY +#endif + +extern G__linked_taginfo G__G__streamLN_mbstate_t; +extern G__linked_taginfo G__G__streamLN_ios_base; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLio_state; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLopen_mode; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLseek_dir; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLfmt_flags; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLevent; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLInit; +extern G__linked_taginfo G__G__streamLN_char_traitslEchargR; +extern G__linked_taginfo G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +extern G__linked_taginfo G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +extern G__linked_taginfo G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; + +/* STUB derived class for protected member access */ +typedef char_traits G__char_traitslEchargR; +typedef basic_istream > G__basic_istreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_ios > G__basic_ioslEcharcOchar_traitslEchargRsPgR; +typedef basic_streambuf > G__basic_streambuflEcharcOchar_traitslEchargRsPgR; +typedef basic_ostream > G__basic_ostreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_ostream >::sentry G__basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +typedef basic_istream >::sentry G__basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +typedef basic_filebuf > G__basic_filebuflEcharcOchar_traitslEchargRsPgR; +typedef basic_ifstream > G__basic_ifstreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_ofstream > G__basic_ofstreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_fstream > G__basic_fstreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_iostream > G__basic_iostreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_stringbuf,allocator > G__basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +typedef basic_istringstream,allocator > G__basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +typedef basic_ostringstream,allocator > G__basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +typedef basic_stringstream,allocator > G__basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; diff --git a/cint/cint/lib/vc7strm/linkdef.h b/cint/cint/lib/vc7strm/linkdef.h index 9ff0dace338c0..074ed48996084 100644 --- a/cint/cint/lib/vc7strm/linkdef.h +++ b/cint/cint/lib/vc7strm/linkdef.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/win32api/cintwin.h b/cint/cint/lib/win32api/cintwin.h index 445c149e234ce..826bad75aed50 100644 --- a/cint/cint/lib/win32api/cintwin.h +++ b/cint/cint/lib/win32api/cintwin.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/wintcldl83/cintlib.c b/cint/cint/lib/wintcldl83/cintlib.c index f398b1d610385..e3085dc92359c 100644 --- a/cint/cint/lib/wintcldl83/cintlib.c +++ b/cint/cint/lib/wintcldl83/cintlib.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/wintcldl83/test.c b/cint/cint/lib/wintcldl83/test.c index 014abf5ba7784..dcd80224b061f 100644 --- a/cint/cint/lib/wintcldl83/test.c +++ b/cint/cint/lib/wintcldl83/test.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/wintcldl83/wildc/wildc.dsp b/cint/cint/lib/wintcldl83/wildc/wildc.dsp index 4a78579b702c1..b7fd5cd84dab1 100644 --- a/cint/cint/lib/wintcldl83/wildc/wildc.dsp +++ b/cint/cint/lib/wintcldl83/wildc/wildc.dsp @@ -1,127 +1,127 @@ -# Microsoft Developer Studio Project File - Name="wildc" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102 - -CFG=wildc - Win32 Release -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "wildc.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "wildc.mak" CFG="wildc - Win32 Release" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "wildc - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") -!MESSAGE "wildc - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -MTL=midl.exe -RSC=rc.exe - -!IF "$(CFG)" == "wildc - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir ".\Release" -# PROP BASE Intermediate_Dir ".\Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir ".\Release" -# PROP Intermediate_Dir ".\Release" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /c -# ADD CPP /nologo /MT /w /W0 /GX /O2 /X /I "\cint" /I "\cint\src" /I "\cint\lib\vcstream" /I "\Program Files\tcl\include" /I "\cint\lib\stdstrct" /I "\Program Files\Microsoft Visual Studio\Vc98\include" /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "G__WILDC" /D "G__WIN32" /D "G__VISUAL" /D "G__SHAREDLIB" /D "G__REDIRECTIO" /D "G__SPECIALSTDIO" /YX /FD /c -# ADD BASE MTL /nologo /D "NDEBUG" /win32 -# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x411 /d "NDEBUG" -# ADD RSC /l 0x411 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /subsystem:windows /dll /machine:I386 -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /subsystem:windows /dll /machine:I386 - -!ELSEIF "$(CFG)" == "wildc - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir ".\Debug" -# PROP BASE Intermediate_Dir ".\Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir ".\Debug" -# PROP Intermediate_Dir ".\Debug" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /c -# ADD CPP /nologo /MTd /w /W0 /Gm /GX /ZI /Od /I "\cint" /I "\cint\src" /I "\cint\lib\vcstream" /I "\Program Files\tcl\include" /I "\cint\lib\stdstrct" /I "\Program Files\Microsoft Visual Studio\Vc98\include" /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "G__WILDC" /D "G__WIN32" /D "G__VISUAL" /D "G__SHAREDLIB" /D "G__REDIRECTIO" /D "G__SPECIALSTDIO" /YX /FD /c -# ADD BASE MTL /nologo /D "_DEBUG" /win32 -# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x411 /d "_DEBUG" -# ADD RSC /l 0x411 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /subsystem:windows /dll /debug /machine:I386 -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /subsystem:windows /dll /debug /machine:I386 - -!ENDIF - -# Begin Target - -# Name "wildc - Win32 Release" -# Name "wildc - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat;for;f90" -# Begin Source File - -SOURCE=..\cintlib.c -# End Source File -# Begin Source File - -SOURCE=..\wildc.def -# End Source File -# Begin Source File - -SOURCE=..\wildcIF.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl;fi;fd" -# End Group -# Begin Group "Resource Files" - -# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;cnt;rtf;gif;jpg;jpeg;jpe" -# End Group -# Begin Source File - -SOURCE=..\..\..\Libcint.lib -# End Source File -# Begin Source File - -SOURCE="..\..\..\..\Program Files\Tcl\lib\tk83.lib" -# End Source File -# Begin Source File - -SOURCE="..\..\..\..\Program Files\Tcl\lib\tcl83.lib" -# End Source File -# End Target -# End Project +# Microsoft Developer Studio Project File - Name="wildc" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102 + +CFG=wildc - Win32 Release +!MESSAGE This is not a valid makefile. To build this project using NMAKE, +!MESSAGE use the Export Makefile command and run +!MESSAGE +!MESSAGE NMAKE /f "wildc.mak". +!MESSAGE +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "wildc.mak" CFG="wildc - Win32 Release" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "wildc - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") +!MESSAGE "wildc - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName "" +# PROP Scc_LocalPath "" +CPP=cl.exe +MTL=midl.exe +RSC=rc.exe + +!IF "$(CFG)" == "wildc - Win32 Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir ".\Release" +# PROP BASE Intermediate_Dir ".\Release" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir ".\Release" +# PROP Intermediate_Dir ".\Release" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /c +# ADD CPP /nologo /MT /w /W0 /GX /O2 /X /I "\cint" /I "\cint\src" /I "\cint\lib\vcstream" /I "\Program Files\tcl\include" /I "\cint\lib\stdstrct" /I "\Program Files\Microsoft Visual Studio\Vc98\include" /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "G__WILDC" /D "G__WIN32" /D "G__VISUAL" /D "G__SHAREDLIB" /D "G__REDIRECTIO" /D "G__SPECIALSTDIO" /YX /FD /c +# ADD BASE MTL /nologo /D "NDEBUG" /win32 +# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x411 /d "NDEBUG" +# ADD RSC /l 0x411 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /subsystem:windows /dll /machine:I386 +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /subsystem:windows /dll /machine:I386 + +!ELSEIF "$(CFG)" == "wildc - Win32 Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir ".\Debug" +# PROP BASE Intermediate_Dir ".\Debug" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir ".\Debug" +# PROP Intermediate_Dir ".\Debug" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /c +# ADD CPP /nologo /MTd /w /W0 /Gm /GX /ZI /Od /I "\cint" /I "\cint\src" /I "\cint\lib\vcstream" /I "\Program Files\tcl\include" /I "\cint\lib\stdstrct" /I "\Program Files\Microsoft Visual Studio\Vc98\include" /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "G__WILDC" /D "G__WIN32" /D "G__VISUAL" /D "G__SHAREDLIB" /D "G__REDIRECTIO" /D "G__SPECIALSTDIO" /YX /FD /c +# ADD BASE MTL /nologo /D "_DEBUG" /win32 +# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x411 /d "_DEBUG" +# ADD RSC /l 0x411 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /subsystem:windows /dll /debug /machine:I386 +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /subsystem:windows /dll /debug /machine:I386 + +!ENDIF + +# Begin Target + +# Name "wildc - Win32 Release" +# Name "wildc - Win32 Debug" +# Begin Group "Source Files" + +# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat;for;f90" +# Begin Source File + +SOURCE=..\cintlib.c +# End Source File +# Begin Source File + +SOURCE=..\wildc.def +# End Source File +# Begin Source File + +SOURCE=..\wildcIF.c +# End Source File +# End Group +# Begin Group "Header Files" + +# PROP Default_Filter "h;hpp;hxx;hm;inl;fi;fd" +# End Group +# Begin Group "Resource Files" + +# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;cnt;rtf;gif;jpg;jpeg;jpe" +# End Group +# Begin Source File + +SOURCE=..\..\..\Libcint.lib +# End Source File +# Begin Source File + +SOURCE="..\..\..\..\Program Files\Tcl\lib\tk83.lib" +# End Source File +# Begin Source File + +SOURCE="..\..\..\..\Program Files\Tcl\lib\tcl83.lib" +# End Source File +# End Target +# End Project diff --git a/cint/cint/lib/wintcldl83/wildc/wildc.dsw b/cint/cint/lib/wintcldl83/wildc/wildc.dsw index 5190ff4553b1c..6179dd5a529ce 100644 --- a/cint/cint/lib/wintcldl83/wildc/wildc.dsw +++ b/cint/cint/lib/wintcldl83/wildc/wildc.dsw @@ -1,29 +1,29 @@ -Microsoft Developer Studio Workspace File, Format Version 6.00 -# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! - -############################################################################### - -Project: "wildc"=.\wildc.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Global: - -Package=<5> -{{{ -}}} - -Package=<3> -{{{ -}}} - -############################################################################### - +Microsoft Developer Studio Workspace File, Format Version 6.00 +# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! + +############################################################################### + +Project: "wildc"=.\wildc.dsp - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ +}}} + +############################################################################### + +Global: + +Package=<5> +{{{ +}}} + +Package=<3> +{{{ +}}} + +############################################################################### + diff --git a/cint/cint/lib/xlib/TOP.h b/cint/cint/lib/xlib/TOP.h index bed0f6c284f59..f40d509223317 100644 --- a/cint/cint/lib/xlib/TOP.h +++ b/cint/cint/lib/xlib/TOP.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/xlib/XLIB.h b/cint/cint/lib/xlib/XLIB.h index a38f0376850d3..1d35ae2e31008 100644 --- a/cint/cint/lib/xlib/XLIB.h +++ b/cint/cint/lib/xlib/XLIB.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/xlib/x11const.h b/cint/cint/lib/xlib/x11const.h index cab380363d8be..ce5f7a1c99386 100644 --- a/cint/cint/lib/xlib/x11const.h +++ b/cint/cint/lib/xlib/x11const.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/lib/xlib/x11mfunc.h b/cint/cint/lib/xlib/x11mfunc.h index d1c134a814202..5994e9bb4c391 100644 --- a/cint/cint/lib/xlib/x11mfunc.h +++ b/cint/cint/lib/xlib/x11mfunc.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/main/G__main.c b/cint/cint/main/G__main.c index 4bfb921715a95..ffbbeff4f8389 100644 --- a/cint/cint/main/G__main.c +++ b/cint/cint/main/G__main.c @@ -7,7 +7,7 @@ * Description: * C version main function ************************************************************************ - * Copyright(c) 1995~1999 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~1999 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/main/G__setup.c b/cint/cint/main/G__setup.c index 585f739fa0dcf..665e68c05271e 100644 --- a/cint/cint/main/G__setup.c +++ b/cint/cint/main/G__setup.c @@ -7,7 +7,7 @@ * Description: * Archived precompiled library initialization routine ************************************************************************ - * Copyright(c) 1995~1999 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~1999 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/main/cppmain.cxx b/cint/cint/main/cppmain.cxx index ad60e4b653d68..14ae751b8b63f 100644 --- a/cint/cint/main/cppmain.cxx +++ b/cint/cint/main/cppmain.cxx @@ -7,7 +7,7 @@ * Description: * C++ version main function ************************************************************************ - * Copyright(c) 1995~1999 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~1999 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/Api.cxx b/cint/cint/src/Api.cxx index 2743f5ac6481b..6918870f5fe95 100644 --- a/cint/cint/src/Api.cxx +++ b/cint/cint/src/Api.cxx @@ -7,7 +7,7 @@ * Description: * Extended Run Time Type Identification API ************************************************************************ - * Copyright(c) 1995~2004 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2004 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -542,7 +542,7 @@ extern "C" const char* G__saveconststring(const char* s) extern "C" void G__initcxx() { -#if defined(__HP_aCC)||defined(__SUNPRO_CC)||defined(__BCPLUSPLUS__)||defined(__KCC)||defined(__INTEL_COMPILER) +#if defined(__HP_aCC)||defined(__SUNPRO_CC)||defined(__BCPLUSPLUS__)||defined(__KCC)||defined(__INTEL_COMPILER)||defined(_LIBCPP_ABI_VERSION) G__FastAllocString temp(G__ONELINE); #endif #ifdef __HP_aCC /* HP aCC C++ compiler */ @@ -562,6 +562,9 @@ extern "C" void G__initcxx() #endif #if defined(__INTEL_COMPILER) && (__INTEL_COMPILER<810) /* icc and ecc C++ compilers */ temp.Format("G__INTEL_COMPILER=%ld",(long)__INTEL_COMPILER); G__add_macro(temp); +#endif +#if defined(_LIBCPP_ABI_VERSION) + temp.Format("G__APPLE_LIBCXX=%ld",(long)_LIBCPP_ABI_VERSION); G__add_macro(temp); #endif /* #ifdef __cplusplus diff --git a/cint/cint/src/BaseCls.cxx b/cint/cint/src/BaseCls.cxx index 4d4b4c98836cb..63de1189648c4 100644 --- a/cint/cint/src/BaseCls.cxx +++ b/cint/cint/src/BaseCls.cxx @@ -8,7 +8,7 @@ * Extended Run Time Type Identification API ************************************************************************ * Author Masaharu Goto - * Copyright(c) 1995~1999 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~1999 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/CallFunc.cxx b/cint/cint/src/CallFunc.cxx index f7fb52c92cdf8..702d3505207f4 100644 --- a/cint/cint/src/CallFunc.cxx +++ b/cint/cint/src/CallFunc.cxx @@ -401,7 +401,7 @@ void Cint::G__CallFunc::SetFunc(G__ClassInfo* cls /////////////////////////////////////////////////////////////////////////// G__value Cint::G__CallFunc::Execute(void *pobject) { - int ret; + int ret = 0; long store_struct_offset; G__LockCriticalSection(); // Set object address diff --git a/cint/cint/src/HISTORY b/cint/cint/src/HISTORY index d8fd1e7fee63e..c18c0c5ba3798 100644 --- a/cint/cint/src/HISTORY +++ b/cint/cint/src/HISTORY @@ -3645,7 +3645,7 @@ *-1619, a[N][M]; *a; t767.cxx , deleted in expr.c, left in var.c * 1620, power operator '**' disabled, t767.cxx * - , platform/freebsd* renamed -* - , cint mailing list 'cint@root.cern.ch' started +* - , cint mailing list 'root-cint@cern.ch' started * 1621, char* a[] = {"abc"}; bug fix t768.h, dirty solution * * 5.15.26, Jan 7 2002 diff --git a/cint/cint/src/Shadow.cxx b/cint/cint/src/Shadow.cxx index 9aedd3d49a9c8..909b77c42babf 100644 --- a/cint/cint/src/Shadow.cxx +++ b/cint/cint/src/Shadow.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/auxu.cxx b/cint/cint/src/auxu.cxx index 81b66202e8e98..2448ed53171e5 100644 --- a/cint/cint/src/auxu.cxx +++ b/cint/cint/src/auxu.cxx @@ -118,7 +118,7 @@ int G__readline(FILE* fp, char* line, char* argbuf, int* argn, char* arg[]) } else { line[0] = '\0'; - argbuf = '\0'; + argbuf[0] = '\0'; *argn = 0; arg[0] = line; } diff --git a/cint/cint/src/bc_exec_asm.h b/cint/cint/src/bc_exec_asm.h index 2d12b65f399b6..742586bf44651 100644 --- a/cint/cint/src/bc_exec_asm.h +++ b/cint/cint/src/bc_exec_asm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/bc_linkdef.h b/cint/cint/src/bc_linkdef.h index 4d5ccfe7bdc08..e659e9bff58ed 100644 --- a/cint/cint/src/bc_linkdef.h +++ b/cint/cint/src/bc_linkdef.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/bc_parse.cxx b/cint/cint/src/bc_parse.cxx index dc64b35b032ba..dc8874362ceed 100644 --- a/cint/cint/src/bc_parse.cxx +++ b/cint/cint/src/bc_parse.cxx @@ -309,7 +309,7 @@ int G__blockscope::compile_core(int openBrace) { // expression, 2nd level //////////////////////////////////////////////////////////////////////////// /*********************************************************************** - * G__blockscope::compile_expresion() + * G__blockscope::compile_expression() * func(args); -> expr * type(args); -> expr * (expr); -> expr diff --git a/cint/cint/src/bc_reader.h b/cint/cint/src/bc_reader.h index 0c969dc704840..1052753dd2cdd 100644 --- a/cint/cint/src/bc_reader.h +++ b/cint/cint/src/bc_reader.h @@ -80,7 +80,6 @@ class G__sstream { char *m_str; unsigned long m_pos; unsigned long m_store_pos; - int m_linenum; int m_c; public: void Init(G__input_file& /* ifile */) { } diff --git a/cint/cint/src/common.h b/cint/cint/src/common.h index 59cfe8b19f4b5..35e94b3eb909a 100644 --- a/cint/cint/src/common.h +++ b/cint/cint/src/common.h @@ -1287,14 +1287,8 @@ class NameMap { void Insert(const char* name, int idx) { fMap[name].insert(idx); } - void Remove(const char* name, int idx) { - NameMap_t::iterator iMap = fMap.find(name); - if (iMap != fMap.end()) { - iMap->second.erase(idx); - if (iMap->second.empty()) - fMap.erase(iMap); - } - } + void Remove(const char* name, int idx, char **namepool); + Range Find(const char* name) { NameMap_t::const_iterator iMap = fMap.find(name); if (iMap != fMap.end() && !iMap->second.empty()) diff --git a/cint/cint/src/dict/accstrm.cxx b/cint/cint/src/dict/accstrm.cxx index ada596810aea9..ae55a664f60ac 100644 --- a/cint/cint/src/dict/accstrm.cxx +++ b/cint/cint/src/dict/accstrm.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/accstrm.h b/cint/cint/src/dict/accstrm.h index be784ca40ce18..d8e1173c1fd1a 100644 --- a/cint/cint/src/dict/accstrm.h +++ b/cint/cint/src/dict/accstrm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/allstrm.cxx b/cint/cint/src/dict/allstrm.cxx index cbeb657c34cfc..c08d9d519a74b 100644 --- a/cint/cint/src/dict/allstrm.cxx +++ b/cint/cint/src/dict/allstrm.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/alphastrm.cxx b/cint/cint/src/dict/alphastrm.cxx index 38dfb261000fd..052ccb82f7c20 100644 --- a/cint/cint/src/dict/alphastrm.cxx +++ b/cint/cint/src/dict/alphastrm.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/alphastrm.h b/cint/cint/src/dict/alphastrm.h index 2e8d9604a64f3..4a5ecb566e679 100644 --- a/cint/cint/src/dict/alphastrm.h +++ b/cint/cint/src/dict/alphastrm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/bcstrm.cxx b/cint/cint/src/dict/bcstrm.cxx index bdbb42a8165bf..562c417cb7683 100644 --- a/cint/cint/src/dict/bcstrm.cxx +++ b/cint/cint/src/dict/bcstrm.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/bcstrm.h b/cint/cint/src/dict/bcstrm.h index b10f76ac2cea6..f503e61a30992 100644 --- a/cint/cint/src/dict/bcstrm.h +++ b/cint/cint/src/dict/bcstrm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/cbstrm.cpp b/cint/cint/src/dict/cbstrm.cpp index 0261e44aaa6eb..b653d9046d803 100644 --- a/cint/cint/src/dict/cbstrm.cpp +++ b/cint/cint/src/dict/cbstrm.cpp @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/cbstrm.h b/cint/cint/src/dict/cbstrm.h index 1fafe72c770d6..0f192671e5b21 100644 --- a/cint/cint/src/dict/cbstrm.h +++ b/cint/cint/src/dict/cbstrm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/dmyinit.cxx b/cint/cint/src/dict/dmyinit.cxx index 4504ddbde483e..f2e59aea7d42c 100644 --- a/cint/cint/src/dict/dmyinit.cxx +++ b/cint/cint/src/dict/dmyinit.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/dmystrct.cxx b/cint/cint/src/dict/dmystrct.cxx index dc4d6054edb13..39da445938040 100644 --- a/cint/cint/src/dict/dmystrct.cxx +++ b/cint/cint/src/dict/dmystrct.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/gcc3strm.cxx b/cint/cint/src/dict/gcc3strm.cxx index c9086aa53966b..529a18d71a9c7 100644 --- a/cint/cint/src/dict/gcc3strm.cxx +++ b/cint/cint/src/dict/gcc3strm.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/gcc3strm.h b/cint/cint/src/dict/gcc3strm.h index 25647e702ae1c..2d49bb3cf0daf 100644 --- a/cint/cint/src/dict/gcc3strm.h +++ b/cint/cint/src/dict/gcc3strm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/iccstrm.cxx b/cint/cint/src/dict/iccstrm.cxx index a6f30d2f49e63..fc883230bdc47 100644 --- a/cint/cint/src/dict/iccstrm.cxx +++ b/cint/cint/src/dict/iccstrm.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/iccstrm.h b/cint/cint/src/dict/iccstrm.h index e88838b6a1d4a..ad1a8cddd283d 100644 --- a/cint/cint/src/dict/iccstrm.h +++ b/cint/cint/src/dict/iccstrm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/libcxxstrm.cxx b/cint/cint/src/dict/libcxxstrm.cxx new file mode 100644 index 0000000000000..cd27dcf09c623 --- /dev/null +++ b/cint/cint/src/dict/libcxxstrm.cxx @@ -0,0 +1,4543 @@ +/******************************************************** +* libcxxstrm.cxx +* CAUTION: DON'T CHANGE THIS FILE. THIS FILE IS AUTOMATICALLY GENERATED +* FROM HEADER FILES LISTED IN G__setup_cpp_environmentXXX(). +* CHANGE THOSE HEADER FILES AND REGENERATE THIS FILE. +********************************************************/ +#include "libcxxstrm.h" //newlink 3678 + +#ifdef G__MEMTEST +#undef malloc +#undef free +#endif + +#if defined(__GNUC__) && __GNUC__ >= 4 && ((__GNUC_MINOR__ == 2 && __GNUC_PATCHLEVEL__ >= 1) || (__GNUC_MINOR__ >= 3)) +#pragma GCC diagnostic ignored "-Wstrict-aliasing" +#endif + +extern "C" void G__cpp_reset_tagtableG__stream(); + +extern "C" void G__set_cpp_environmentG__stream() { + G__add_compiledheader("iostrm.h"); + G__add_compiledheader("fstrm.h"); + G__add_compiledheader("sstrm.h"); + G__cpp_reset_tagtableG__stream(); +} +#include +extern "C" int G__cpp_dllrevG__stream() { return(30051515); } + +/********************************************************* +* Member function Interface Method +*********************************************************/ + +/* mbstate_t */ +// automatic default constructor +static int G__G__stream_1_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + mbstate_t *p; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new mbstate_t[n]; + } else { + p = new((void*) gvp) mbstate_t[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new mbstate_t; + } else { + p = new((void*) gvp) mbstate_t; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_mbstate_t)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic copy constructor +static int G__G__stream_1_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) + +{ + mbstate_t* p; + void* tmp = (void*) G__int(libp->para[0]); + p = new mbstate_t(*(mbstate_t*) tmp); + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_mbstate_t)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef mbstate_t G__Tmbstate_t; +static int G__G__stream_1_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (mbstate_t*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((mbstate_t*) (soff+(sizeof(mbstate_t)*i)))->~G__Tmbstate_t(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (mbstate_t*) soff; + } else { + G__setgvp((long) G__PVOID); + ((mbstate_t*) (soff))->~G__Tmbstate_t(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic assignment operator +static int G__G__stream_1_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + mbstate_t* dest = (mbstate_t*) G__getstructoffset(); + *dest = *(mbstate_t*) libp->para[0].ref; + const mbstate_t& obj = *dest; + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* streamoff */ +// automatic default constructor +static int G__G__stream_2_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + streamoff *p; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new streamoff[n]; + } else { + p = new((void*) gvp) streamoff[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new streamoff; + } else { + p = new((void*) gvp) streamoff; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_streamoff)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic copy constructor +static int G__G__stream_2_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) + +{ + streamoff* p; + void* tmp = (void*) G__int(libp->para[0]); + p = new streamoff(*(streamoff*) tmp); + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_streamoff)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef streamoff G__Tstreamoff; +static int G__G__stream_2_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (streamoff*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((streamoff*) (soff+(sizeof(streamoff)*i)))->~G__Tstreamoff(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (streamoff*) soff; + } else { + G__setgvp((long) G__PVOID); + ((streamoff*) (soff))->~G__Tstreamoff(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic assignment operator +static int G__G__stream_2_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + streamoff* dest = (streamoff*) G__getstructoffset(); + const streamoff& obj = *dest; + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* fpos */ +static int G__G__stream_3_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + fpos* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new fpos[n]; + } else { + p = new((void*) gvp) fpos[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new fpos; + } else { + p = new((void*) gvp) fpos; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_3_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + fpos* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new fpos(*(fpos*) libp->para[0].ref); + } else { + p = new((void*) gvp) fpos(*(fpos*) libp->para[0].ref); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_3_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + fpos* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new fpos((long long) G__Longlong(libp->para[0])); + } else { + p = new((void*) gvp) fpos((long long) G__Longlong(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_3_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((const fpos*) G__getstructoffset())->operator streamoff()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_3_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const fpos* pobj; + const fpos xobj = ((const fpos*) G__getstructoffset())->operator+((streamoff) G__Longlong(libp->para[0])); + pobj = new fpos(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_3_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const fpos* pobj; + const fpos xobj = ((const fpos*) G__getstructoffset())->operator-((streamoff) G__Longlong(libp->para[0])); + pobj = new fpos(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_3_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((const fpos*) G__getstructoffset())->operator-(*(fpos*) libp->para[0].ref)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_3_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const fpos& obj = ((fpos*) G__getstructoffset())->operator+=((streamoff) G__Longlong(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_3_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const fpos& obj = ((fpos*) G__getstructoffset())->operator-=((streamoff) G__Longlong(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_3_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const mbstate_t* pobj; + const mbstate_t xobj = ((const fpos*) G__getstructoffset())->state(); + pobj = new mbstate_t(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_3_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((fpos*) G__getstructoffset())->state(*((mbstate_t*) G__int(libp->para[0]))); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef fpos G__TfposlEmbstate_tgR; +static int G__G__stream_3_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (fpos*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((fpos*) (soff+(sizeof(fpos)*i)))->~G__TfposlEmbstate_tgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (fpos*) soff; + } else { + G__setgvp((long) G__PVOID); + ((fpos*) (soff))->~G__TfposlEmbstate_tgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic assignment operator +static int G__G__stream_3_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + fpos* dest = (fpos*) G__getstructoffset(); + const fpos& obj = *dest; + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* ios_base */ +static int G__G__stream_4_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((ios_base*) G__getstructoffset())->register_callback((ios_base::event_callback) G__int(libp->para[0]), (int) G__int(libp->para[1])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((const ios_base*) G__getstructoffset())->flags()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((ios_base*) G__getstructoffset())->flags((ios_base::fmtflags) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((ios_base*) G__getstructoffset())->setf((ios_base::fmtflags) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((ios_base*) G__getstructoffset())->setf((ios_base::fmtflags) G__int(libp->para[0]), (ios_base::fmtflags) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((ios_base*) G__getstructoffset())->unsetf((ios_base::fmtflags) G__int(libp->para[0])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((const ios_base*) G__getstructoffset())->precision()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((ios_base*) G__getstructoffset())->precision((streamsize) G__Longlong(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((const ios_base*) G__getstructoffset())->width()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((ios_base*) G__getstructoffset())->width((streamsize) G__Longlong(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ios_base::xalloc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const long& obj = ((ios_base*) G__getstructoffset())->iword((int) G__int(libp->para[0])); + result7->ref = (long) (&obj); + G__letint(result7, 'l', (long)obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + void*& obj = ((ios_base*) G__getstructoffset())->pword((int) G__int(libp->para[0])); + result7->ref = (long) (&obj); + G__letint(result7, 'Y', (long)obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_4_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 1: + G__letint(result7, 103, (long) ((ios_base*) G__getstructoffset())->sync_with_stdio((bool) G__int(libp->para[0]))); + break; + case 0: + G__letint(result7, 103, (long) ((ios_base*) G__getstructoffset())->sync_with_stdio()); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + + +/* ios_base::Init */ +static int G__G__stream_10_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ios_base::Init* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + p = 0; + G__genericerror("Error: Array construction with private/protected destructor is illegal"); + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new ios_base::Init; + } else { + p = new((void*) gvp) ios_base::Init; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic copy constructor +static int G__G__stream_10_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) + +{ + ios_base::Init* p; + void* tmp = (void*) G__int(libp->para[0]); + p = new ios_base::Init(*(ios_base::Init*) tmp); + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic assignment operator +static int G__G__stream_10_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ios_base::Init* dest = (ios_base::Init*) G__getstructoffset(); + const ios_base::Init& obj = *dest; + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* char_traits */ +static int G__G__stream_11_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char_traits::assign(*(char_traits::char_type*) G__Charref(&libp->para[0]), *(char_traits::char_type*) G__Charref(&libp->para[1])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) char_traits::to_char_type(*(char_traits::int_type*) G__Intref(&libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) char_traits::to_int_type(*(char_traits::char_type*) G__Charref(&libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) char_traits::eq(*(char_traits::char_type*) G__Charref(&libp->para[0]), *(char_traits::char_type*) G__Charref(&libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) char_traits::lt(*(char_traits::char_type*) G__Charref(&libp->para[0]), *(char_traits::char_type*) G__Charref(&libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) char_traits::compare((const char_traits::char_type*) G__int(libp->para[0]), (const char_traits::char_type*) G__int(libp->para[1]) +, (size_t) G__int(libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 67, (long) char_traits::find((const char_traits::char_type*) G__int(libp->para[0]), (int) G__int(libp->para[1]) +, *(char_traits::char_type*) G__Charref(&libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) char_traits::eq_int_type(*(char_traits::int_type*) G__Intref(&libp->para[0]), *(char_traits::int_type*) G__Intref(&libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) char_traits::eof()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) char_traits::not_eof(*(char_traits::int_type*) G__Intref(&libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 107, (long) char_traits::length((const char_traits::char_type*) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 67, (long) char_traits::copy((char_traits::char_type*) G__int(libp->para[0]), (const char_traits::char_type*) G__int(libp->para[1]) +, (size_t) G__int(libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 67, (long) char_traits::move((char_traits::char_type*) G__int(libp->para[0]), (const char_traits::char_type*) G__int(libp->para[1]) +, (size_t) G__int(libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 67, (long) char_traits::assign((char_traits::char_type*) G__int(libp->para[0]), (size_t) G__int(libp->para[1]) +, (const char_traits::char_type) G__int(libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic default constructor +static int G__G__stream_11_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char_traits *p; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new char_traits[n]; + } else { + p = new((void*) gvp) char_traits[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new char_traits; + } else { + p = new((void*) gvp) char_traits; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic copy constructor +static int G__G__stream_11_0_16(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) + +{ + char_traits* p; + void* tmp = (void*) G__int(libp->para[0]); + p = new char_traits(*(char_traits*) tmp); + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef char_traits G__Tchar_traitslEchargR; +static int G__G__stream_11_0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (char_traits*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((char_traits*) (soff+(sizeof(char_traits)*i)))->~G__Tchar_traitslEchargR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (char_traits*) soff; + } else { + G__setgvp((long) G__PVOID); + ((char_traits*) (soff))->~G__Tchar_traitslEchargR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic assignment operator +static int G__G__stream_11_0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char_traits* dest = (char_traits*) G__getstructoffset(); + const char_traits& obj = *dest; + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_istream > */ +static int G__G__stream_12_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istream >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istream >((basic_streambuf >*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_istream >((basic_streambuf >*) G__int(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_istream >*) G__getstructoffset())->get()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->get((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__Longlong(libp->para[1]) +, (basic_istream >::char_type) G__int(libp->para[2])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->get((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__Longlong(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->get(*(basic_istream >::char_type*) G__Charref(&libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->get(*(basic_streambuf >*) libp->para[0].ref, (basic_istream >::char_type) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->get(*(basic_streambuf >*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->getline((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__Longlong(libp->para[1]) +, (basic_istream >::char_type) G__int(libp->para[2])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->getline((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__Longlong(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->ignore((streamsize) G__Longlong(libp->para[0]), (basic_istream >::int_type) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 1: + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->ignore((streamsize) G__Longlong(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + break; + case 0: + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->ignore(); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->read((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__Longlong(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((basic_istream >*) G__getstructoffset())->readsome((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__Longlong(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_istream >*) G__getstructoffset())->peek()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((basic_istream >*) G__getstructoffset())->tellg()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_16(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->seekg((basic_istream >::pos_type) G__Longlong(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_istream >*) G__getstructoffset())->sync()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->seekg((basic_istream >::off_type) G__Longlong(libp->para[0]), (ios_base::seekdir) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_19(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->putback((basic_istream >::char_type) G__int(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_20(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >& obj = ((basic_istream >*) G__getstructoffset())->unget(); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_21(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((const basic_istream >*) G__getstructoffset())->gcount()); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_istream > G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_12_0_23(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_istream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_istream >*) (soff+(sizeof(basic_istream >)*i)))->~G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_istream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_istream >*) (soff))->~G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ios > */ +static int G__G__stream_13_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ios >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ios >((basic_streambuf >*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ios >((basic_streambuf >*) G__int(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) ((const basic_ios >*) G__getstructoffset())->fill()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) ((basic_ios >*) G__getstructoffset())->fill((basic_ios >::char_type) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ios >*) G__getstructoffset())->exceptions((ios_base::iostate) G__int(libp->para[0])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((const basic_ios >*) G__getstructoffset())->exceptions()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 1: + ((basic_ios >*) G__getstructoffset())->clear((ios_base::iostate) G__int(libp->para[0])); + G__setnull(result7); + break; + case 0: + ((basic_ios >*) G__getstructoffset())->clear(); + G__setnull(result7); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ios >*) G__getstructoffset())->setstate((ios_base::iostate) G__int(libp->para[0])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((const basic_ios >*) G__getstructoffset())->rdstate()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->operator!()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->good()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->eof()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->fail()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->bad()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ios >& obj = ((basic_ios >*) G__getstructoffset())->copyfmt(*(basic_ios >*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ios >*) G__getstructoffset())->tie()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_16(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_ios >*) G__getstructoffset())->tie((basic_ostream >*) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ios >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_ios >*) G__getstructoffset())->rdbuf((basic_streambuf >*) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_19(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) ((const basic_ios >*) G__getstructoffset())->narrow((char) G__int(libp->para[0]), (char) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_20(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) ((const basic_ios >*) G__getstructoffset())->widen((char) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ios > G__Tbasic_ioslEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_13_0_25(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ios >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ios >*) (soff+(sizeof(basic_ios >)*i)))->~G__Tbasic_ioslEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ios >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ios >*) (soff))->~G__Tbasic_ioslEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_streambuf > */ +static int G__G__stream_14_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_streambuf >*) G__getstructoffset())->pubsetbuf((basic_streambuf >::char_type*) G__int(libp->para[0]), (streamsize) G__Longlong(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_14_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 3: + G__letLonglong(result7, 110, (G__int64) ((basic_streambuf >*) G__getstructoffset())->pubseekoff((basic_streambuf >::off_type) G__Longlong(libp->para[0]), (ios_base::seekdir) G__int(libp->para[1]) +, (ios_base::openmode) G__int(libp->para[2]))); + break; + case 2: + G__letLonglong(result7, 110, (G__int64) ((basic_streambuf >*) G__getstructoffset())->pubseekoff((basic_streambuf >::off_type) G__Longlong(libp->para[0]), (ios_base::seekdir) G__int(libp->para[1]))); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_14_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 2: + G__letLonglong(result7, 110, (G__int64) ((basic_streambuf >*) G__getstructoffset())->pubseekpos((basic_streambuf >::pos_type) G__Longlong(libp->para[0]), (ios_base::openmode) G__int(libp->para[1]))); + break; + case 1: + G__letLonglong(result7, 110, (G__int64) ((basic_streambuf >*) G__getstructoffset())->pubseekpos((basic_streambuf >::pos_type) G__Longlong(libp->para[0]))); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_14_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->pubsync()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_14_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((basic_streambuf >*) G__getstructoffset())->in_avail()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_14_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->snextc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_14_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sbumpc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_14_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sgetc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_14_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((basic_streambuf >*) G__getstructoffset())->sgetn((basic_streambuf >::char_type*) G__int(libp->para[0]), (streamsize) G__Longlong(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_14_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sputbackc((basic_streambuf >::char_type) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_14_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sungetc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_14_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sputc((basic_streambuf >::char_type) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_14_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((basic_streambuf >*) G__getstructoffset())->sputn((const basic_streambuf >::char_type*) G__int(libp->para[0]), (streamsize) G__Longlong(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_streambuf > G__Tbasic_streambuflEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_14_0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_streambuf >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_streambuf >*) (soff+(sizeof(basic_streambuf >)*i)))->~G__Tbasic_streambuflEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_streambuf >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_streambuf >*) (soff))->~G__Tbasic_streambuflEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ostream > */ +static int G__G__stream_15_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ostream >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostream >((basic_streambuf >*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ostream >((basic_streambuf >*) G__int(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_15_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >& obj = ((basic_ostream >*) G__getstructoffset())->put((basic_ostream >::char_type) G__int(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_15_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >& obj = ((basic_ostream >*) G__getstructoffset())->write((const basic_ostream >::char_type*) G__int(libp->para[0]), (streamsize) G__Longlong(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_15_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >& obj = ((basic_ostream >*) G__getstructoffset())->flush(); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_15_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >& obj = ((basic_ostream >*) G__getstructoffset())->seekp((basic_ostream >::pos_type) G__Longlong(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_15_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >& obj = ((basic_ostream >*) G__getstructoffset())->seekp((basic_ostream >::off_type) G__Longlong(libp->para[0]), (ios_base::seekdir) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_15_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letLonglong(result7, 110, (G__int64) ((basic_ostream >*) G__getstructoffset())->tellp()); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ostream > G__Tbasic_ostreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_15_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ostream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ostream >*) (soff+(sizeof(basic_ostream >)*i)))->~G__Tbasic_ostreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ostream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ostream >*) (soff))->~G__Tbasic_ostreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ostream >::sentry */ +static int G__G__stream_16_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ostream >::sentry* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostream >::sentry(*(basic_ostream >*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_ostream >::sentry(*(basic_ostream >*) libp->para[0].ref); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_16_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((basic_ostream >::sentry*) G__getstructoffset())->operator bool()); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_istream >::sentry */ +static int G__G__stream_17_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istream >::sentry* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istream >::sentry(*(basic_istream >*) libp->para[0].ref, (bool) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_istream >::sentry(*(basic_istream >*) libp->para[0].ref, (bool) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istream >::sentry(*(basic_istream >*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_istream >::sentry(*(basic_istream >*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_17_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((basic_istream >::sentry*) G__getstructoffset())->operator bool()); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_filebuf > */ +static int G__G__stream_18_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_filebuf >* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_filebuf >[n]; + } else { + p = new((void*) gvp) basic_filebuf >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_filebuf >; + } else { + p = new((void*) gvp) basic_filebuf >; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_filebuf >*) G__getstructoffset())->is_open()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_filebuf >*) G__getstructoffset())->open((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_filebuf >*) G__getstructoffset())->close()); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_filebuf > G__Tbasic_filebuflEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_18_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_filebuf >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_filebuf >*) (soff+(sizeof(basic_filebuf >)*i)))->~G__Tbasic_filebuflEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_filebuf >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_filebuf >*) (soff))->~G__Tbasic_filebuflEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ifstream > */ +static int G__G__stream_19_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ifstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ifstream >[n]; + } else { + p = new((void*) gvp) basic_ifstream >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ifstream >; + } else { + p = new((void*) gvp) basic_ifstream >; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ifstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ifstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_ifstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ifstream >((const char*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ifstream >((const char*) G__int(libp->para[0])); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ifstream >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((basic_ifstream >*) G__getstructoffset())->is_open()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 2: + ((basic_ifstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + G__setnull(result7); + break; + case 1: + ((basic_ifstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0])); + G__setnull(result7); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ifstream >*) G__getstructoffset())->close(); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ifstream > G__Tbasic_ifstreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_19_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ifstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ifstream >*) (soff+(sizeof(basic_ifstream >)*i)))->~G__Tbasic_ifstreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ifstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ifstream >*) (soff))->~G__Tbasic_ifstreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ofstream > */ +static int G__G__stream_20_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ofstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ofstream >[n]; + } else { + p = new((void*) gvp) basic_ofstream >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ofstream >; + } else { + p = new((void*) gvp) basic_ofstream >; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_20_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ofstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ofstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_ofstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ofstream >((const char*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ofstream >((const char*) G__int(libp->para[0])); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_20_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ofstream >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_20_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((basic_ofstream >*) G__getstructoffset())->is_open()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_20_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 2: + ((basic_ofstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + G__setnull(result7); + break; + case 1: + ((basic_ofstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0])); + G__setnull(result7); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_20_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ofstream >*) G__getstructoffset())->close(); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ofstream > G__Tbasic_ofstreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_20_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ofstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ofstream >*) (soff+(sizeof(basic_ofstream >)*i)))->~G__Tbasic_ofstreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ofstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ofstream >*) (soff))->~G__Tbasic_ofstreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_fstream > */ +static int G__G__stream_21_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_fstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_fstream >[n]; + } else { + p = new((void*) gvp) basic_fstream >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_fstream >; + } else { + p = new((void*) gvp) basic_fstream >; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_21_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_fstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_fstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_fstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_21_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_fstream >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_21_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((basic_fstream >*) G__getstructoffset())->is_open()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_21_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_fstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_21_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_fstream >*) G__getstructoffset())->close(); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_fstream > G__Tbasic_fstreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_21_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_fstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_fstream >*) (soff+(sizeof(basic_fstream >)*i)))->~G__Tbasic_fstreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_fstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_fstream >*) (soff))->~G__Tbasic_fstreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_iostream > */ +static int G__G__stream_22_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_iostream >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_iostream >((basic_streambuf >*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_iostream >((basic_streambuf >*) G__int(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_iostream > G__Tbasic_iostreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_22_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_iostream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_iostream >*) (soff+(sizeof(basic_iostream >)*i)))->~G__Tbasic_iostreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_iostream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_iostream >*) (soff))->~G__Tbasic_iostreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_stringbuf,allocator > */ +static int G__G__stream_41_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_stringbuf,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >((ios_base::openmode) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_stringbuf,allocator >((ios_base::openmode) G__int(libp->para[0])); + } + break; + case 0: + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >[n]; + } else { + p = new((void*) gvp) basic_stringbuf,allocator >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >; + } else { + p = new((void*) gvp) basic_stringbuf,allocator >; + } + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_41_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_stringbuf,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >(*(basic_stringbuf,allocator >::string_type*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_stringbuf,allocator >(*(basic_stringbuf,allocator >::string_type*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >(*(basic_stringbuf,allocator >::string_type*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_stringbuf,allocator >(*(basic_stringbuf,allocator >::string_type*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_41_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_stringbuf,allocator >::string_type* pobj; + const basic_stringbuf,allocator >::string_type xobj = ((const basic_stringbuf,allocator >*) G__getstructoffset())->str(); + pobj = new basic_stringbuf,allocator >::string_type(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_41_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_stringbuf,allocator >*) G__getstructoffset())->str(*(basic_stringbuf,allocator >::string_type*) libp->para[0].ref); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_stringbuf,allocator > G__Tbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +static int G__G__stream_41_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_stringbuf,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_stringbuf,allocator >*) (soff+(sizeof(basic_stringbuf,allocator >)*i)))->~G__Tbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_stringbuf,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_stringbuf,allocator >*) (soff))->~G__Tbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_istringstream,allocator > */ +static int G__G__stream_42_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_istringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } + break; + case 0: + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >[n]; + } else { + p = new((void*) gvp) basic_istringstream,allocator >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >; + } else { + p = new((void*) gvp) basic_istringstream,allocator >; + } + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_42_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >(*(basic_istringstream,allocator >::string_type*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_istringstream,allocator >(*(basic_istringstream,allocator >::string_type*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >(*(basic_istringstream,allocator >::string_type*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_istringstream,allocator >(*(basic_istringstream,allocator >::string_type*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_42_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_istringstream,allocator >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >((const char*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_istringstream,allocator >((const char*) G__int(libp->para[0])); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_42_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_istringstream,allocator >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_42_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istringstream,allocator >::string_type* pobj; + const basic_istringstream,allocator >::string_type xobj = ((const basic_istringstream,allocator >*) G__getstructoffset())->str(); + pobj = new basic_istringstream,allocator >::string_type(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_42_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_istringstream,allocator >*) G__getstructoffset())->str(*(basic_istringstream,allocator >::string_type*) libp->para[0].ref); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_istringstream,allocator > G__Tbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +static int G__G__stream_42_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_istringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_istringstream,allocator >*) (soff+(sizeof(basic_istringstream,allocator >)*i)))->~G__Tbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_istringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_istringstream,allocator >*) (soff))->~G__Tbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ostringstream,allocator > */ +static int G__G__stream_43_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ostringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ostringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } + break; + case 0: + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >[n]; + } else { + p = new((void*) gvp) basic_ostringstream,allocator >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >; + } else { + p = new((void*) gvp) basic_ostringstream,allocator >; + } + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_43_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ostringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >(*(basic_ostringstream,allocator >::string_type*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_ostringstream,allocator >(*(basic_ostringstream,allocator >::string_type*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >(*(basic_ostringstream,allocator >::string_type*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_ostringstream,allocator >(*(basic_ostringstream,allocator >::string_type*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_43_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ostringstream,allocator >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_43_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostringstream,allocator >::string_type* pobj; + const basic_ostringstream,allocator >::string_type xobj = ((const basic_ostringstream,allocator >*) G__getstructoffset())->str(); + pobj = new basic_ostringstream,allocator >::string_type(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_43_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ostringstream,allocator >*) G__getstructoffset())->str(*(basic_ostringstream,allocator >::string_type*) libp->para[0].ref); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ostringstream,allocator > G__Tbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +static int G__G__stream_43_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ostringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ostringstream,allocator >*) (soff+(sizeof(basic_ostringstream,allocator >)*i)))->~G__Tbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ostringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ostringstream,allocator >*) (soff))->~G__Tbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_stringstream,allocator > */ +static int G__G__stream_44_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_stringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_stringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } + break; + case 0: + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >[n]; + } else { + p = new((void*) gvp) basic_stringstream,allocator >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >; + } else { + p = new((void*) gvp) basic_stringstream,allocator >; + } + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_44_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_stringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >(*(basic_stringstream,allocator >::string_type*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_stringstream,allocator >(*(basic_stringstream,allocator >::string_type*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >(*(basic_stringstream,allocator >::string_type*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_stringstream,allocator >(*(basic_stringstream,allocator >::string_type*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_44_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_stringstream,allocator >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_44_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_stringstream,allocator >::string_type* pobj; + const basic_stringstream,allocator >::string_type xobj = ((const basic_stringstream,allocator >*) G__getstructoffset())->str(); + pobj = new basic_stringstream,allocator >::string_type(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_44_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_stringstream,allocator >*) G__getstructoffset())->str(*(basic_stringstream,allocator >::string_type*) libp->para[0].ref); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_stringstream,allocator > G__Tbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +static int G__G__stream_44_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_stringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_stringstream,allocator >*) (soff+(sizeof(basic_stringstream,allocator >)*i)))->~G__Tbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_stringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_stringstream,allocator >*) (soff))->~G__Tbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* Setting up global function */ +static int G__G__stream__0_0(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = dec(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = hex(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = oct(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = fixed(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = scientific(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = right(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = left(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = internal(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = nouppercase(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = uppercase(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noskipws(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = skipws(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noshowpos(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = showpos(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noshowpoint(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = showpoint(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_16(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noshowbase(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = showbase(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noboolalpha(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_19(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = boolalpha(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_20(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = ws(*(istream*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_21(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = endl(*(ostream*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_22(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = ends(*(ostream*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_23(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = flush(*(ostream*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_24(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (char) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_25(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (char*) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_26(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (void*) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_27(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (unsigned char) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_28(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (short) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_29(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (unsigned short) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_30(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, *(int*) G__Intref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_31(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (unsigned int) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_32(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (long) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_33(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (unsigned long) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_34(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (float) G__double(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_35(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (double) G__double(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_36(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (bool) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_37(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(char*) G__Charref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_38(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(unsigned char*) G__UCharref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_39(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(short*) G__Shortref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_40(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(unsigned short*) G__UShortref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_41(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(int*) G__Intref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_42(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(unsigned int*) G__UIntref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_43(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(long*) G__Longref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_44(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(unsigned long*) G__ULongref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_45(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(float*) G__Floatref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_46(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(double*) G__Doubleref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_47(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(bool*) G__Boolref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_48(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, (char*) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_49(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, libp->para[1].ref ? *(void**) libp->para[1].ref : *(void**) (void*) (&G__Mlong(libp->para[1]))); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + + +/********************************************************* +* Member function Stub +*********************************************************/ + +/* mbstate_t */ + +/* streamoff */ + +/* fpos */ + +/* ios_base */ + +/* ios_base::Init */ + +/* char_traits */ + +/* basic_istream > */ + +/* basic_ios > */ + +/* basic_streambuf > */ + +/* basic_ostream > */ + +/* basic_ostream >::sentry */ + +/* basic_istream >::sentry */ + +/* basic_filebuf > */ + +/* basic_ifstream > */ + +/* basic_ofstream > */ + +/* basic_fstream > */ + +/* basic_iostream > */ + +/* basic_stringbuf,allocator > */ + +/* basic_istringstream,allocator > */ + +/* basic_ostringstream,allocator > */ + +/* basic_stringstream,allocator > */ + +/********************************************************* +* Global function Stub +*********************************************************/ + +/********************************************************* +* Get size of pointer to member function +*********************************************************/ +class G__Sizep2memfuncG__stream { + public: + G__Sizep2memfuncG__stream(): p(&G__Sizep2memfuncG__stream::sizep2memfunc) {} + size_t sizep2memfunc() { return(sizeof(p)); } + private: + size_t (G__Sizep2memfuncG__stream::*p)(); +}; + +size_t G__get_sizep2memfuncG__stream() +{ + G__Sizep2memfuncG__stream a; + G__setsizep2memfunc((int)a.sizep2memfunc()); + return((size_t)a.sizep2memfunc()); +} + + +/********************************************************* +* virtual base class offset calculation interface +*********************************************************/ + + /* Setting up class inheritance */ +static long G__2vbo_basic_istreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_0(long pobject) { + basic_istream > *G__Lderived=(basic_istream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_istreamlEcharcOchar_traitslEchargRsPgR_ios_base_1(long pobject) { + basic_istream > *G__Lderived=(basic_istream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_0(long pobject) { + basic_ostream > *G__Lderived=(basic_ostream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ostreamlEcharcOchar_traitslEchargRsPgR_ios_base_1(long pobject) { + basic_ostream > *G__Lderived=(basic_ostream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ifstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_ifstream > *G__Lderived=(basic_ifstream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ifstreamlEcharcOchar_traitslEchargRsPgR_ios_base_2(long pobject) { + basic_ifstream > *G__Lderived=(basic_ifstream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ofstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_ofstream > *G__Lderived=(basic_ofstream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ofstreamlEcharcOchar_traitslEchargRsPgR_ios_base_2(long pobject) { + basic_ofstream > *G__Lderived=(basic_ofstream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_2(long pobject) { + basic_fstream > *G__Lderived=(basic_fstream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_ios_base_3(long pobject) { + basic_fstream > *G__Lderived=(basic_fstream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_5(long pobject) { + basic_fstream > *G__Lderived=(basic_fstream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_ios_base_6(long pobject) { + basic_fstream > *G__Lderived=(basic_fstream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_iostream > *G__Lderived=(basic_iostream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_ios_base_2(long pobject) { + basic_iostream > *G__Lderived=(basic_iostream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_4(long pobject) { + basic_iostream > *G__Lderived=(basic_iostream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_ios_base_5(long pobject) { + basic_iostream > *G__Lderived=(basic_iostream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_istringstream,allocator > *G__Lderived=(basic_istringstream,allocator >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_2(long pobject) { + basic_istringstream,allocator > *G__Lderived=(basic_istringstream,allocator >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_ostringstream,allocator > *G__Lderived=(basic_ostringstream,allocator >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_2(long pobject) { + basic_ostringstream,allocator > *G__Lderived=(basic_ostringstream,allocator >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_2(long pobject) { + basic_stringstream,allocator > *G__Lderived=(basic_stringstream,allocator >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_3(long pobject) { + basic_stringstream,allocator > *G__Lderived=(basic_stringstream,allocator >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_5(long pobject) { + basic_stringstream,allocator > *G__Lderived=(basic_stringstream,allocator >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_6(long pobject) { + basic_stringstream,allocator > *G__Lderived=(basic_stringstream,allocator >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + + +/********************************************************* +* Inheritance information setup/ +*********************************************************/ +extern "C" void G__cpp_setup_inheritanceG__stream() { + + /* Setting up class inheritance */ + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR))) { + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_istreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_0,1,3); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_istreamlEcharcOchar_traitslEchargRsPgR_ios_base_1,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR))) { + basic_ios > *G__Lderived; + G__Lderived=(basic_ios >*)0x1000; + { + ios_base *G__Lpbase=(ios_base*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__Lpbase-(long)G__Lderived,1,1); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR))) { + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_ostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_0,1,3); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_ostreamlEcharcOchar_traitslEchargRsPgR_ios_base_1,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR))) { + basic_filebuf > *G__Lderived; + G__Lderived=(basic_filebuf >*)0x1000; + { + basic_streambuf > *G__Lpbase=(basic_streambuf >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR))) { + basic_ifstream > *G__Lderived; + G__Lderived=(basic_ifstream >*)0x1000; + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_ifstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_ifstreamlEcharcOchar_traitslEchargRsPgR_ios_base_2,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR))) { + basic_ofstream > *G__Lderived; + G__Lderived=(basic_ofstream >*)0x1000; + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_ofstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_ofstreamlEcharcOchar_traitslEchargRsPgR_ios_base_2,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR))) { + basic_fstream > *G__Lderived; + G__Lderived=(basic_fstream >*)0x1000; + { + basic_iostream > *G__Lpbase=(basic_iostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,0); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_2,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_ios_base_3,1,6); + } + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,0); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_5,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_ios_base_6,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR))) { + basic_iostream > *G__Lderived; + G__Lderived=(basic_iostream >*)0x1000; + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_ios_base_2,1,6); + } + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_4,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_ios_base_5,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR))) { + basic_stringbuf,allocator > *G__Lderived; + G__Lderived=(basic_stringbuf,allocator >*)0x1000; + { + basic_streambuf > *G__Lpbase=(basic_streambuf >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR))) { + basic_istringstream,allocator > *G__Lderived; + G__Lderived=(basic_istringstream,allocator >*)0x1000; + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_2,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR))) { + basic_ostringstream,allocator > *G__Lderived; + G__Lderived=(basic_ostringstream,allocator >*)0x1000; + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_2,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR))) { + basic_stringstream,allocator > *G__Lderived; + G__Lderived=(basic_stringstream,allocator >*)0x1000; + { + basic_iostream > *G__Lpbase=(basic_iostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,0); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_2,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_3,1,6); + } + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,0); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_5,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_6,1,6); + } + } +} + +/********************************************************* +* typedef information setup/ +*********************************************************/ +extern "C" void G__cpp_setup_typetableG__stream() { + + /* Setting up typedef entry */ + G__search_typename2("mbstate_t",117,G__get_linked_tagnum(&G__G__streamLN_mbstate_t),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("streampos",110,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("streamoff",110,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("SZ_T",110,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("streamsize",110,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("iostate",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,NULL,0); + G__search_typename2("openmode",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,NULL,0); + G__search_typename2("seekdir",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,NULL,0); + G__search_typename2("fmtflags",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,NULL,0); + G__search_typename2("event_callback",89,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,"void (*event_callback) (event, ios_base&, int index);",0); + G__search_typename2("INT_T",105,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("state_type",117,G__get_linked_tagnum(&G__G__streamLN_mbstate_t),0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("basic_streambuf >",117,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("__ostream_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("__ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("__istream_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("__ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("__streambuf_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("istream",117,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("ostream",117,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("streambuf",117,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("filebuf",117,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ifstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ofstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("fstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("string_type",117,G__get_linked_tagnum(&G__G__streamLN_string),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("stringbuf",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("sb_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("string_type",117,G__get_linked_tagnum(&G__G__streamLN_string),0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("istringstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("sb_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("string_type",117,G__get_linked_tagnum(&G__G__streamLN_string),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ostringstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",110,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("sb_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("string_type",117,G__get_linked_tagnum(&G__G__streamLN_string),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("stringstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); +} + +/********************************************************* +* Data Member information setup/ +*********************************************************/ + + /* Setting up class,struct,union tag member variable */ + + /* mbstate_t */ +static void G__setup_memvarmbstate_t(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_mbstate_t)); + { mbstate_t *p; p=(mbstate_t*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* streamoff */ +static void G__setup_memvarstreamoff(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_streamoff)); + { streamoff *p; p=(streamoff*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* fpos */ +static void G__setup_memvarfposlEmbstate_tgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR)); + { fpos *p; p=(fpos*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* ios_base */ +static void G__setup_memvarios_base(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_ios_base)); + { ios_base *p; p=(ios_base*)0x1000; if (p) { } + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLio_state),-1,-2,1,G__FastAllocString(2048).Format("goodbit=%lldLL",(long long)ios_base::goodbit).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLio_state),-1,-2,1,G__FastAllocString(2048).Format("badbit=%lldLL",(long long)ios_base::badbit).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLio_state),-1,-2,1,G__FastAllocString(2048).Format("eofbit=%lldLL",(long long)ios_base::eofbit).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLio_state),-1,-2,1,G__FastAllocString(2048).Format("failbit=%lldLL",(long long)ios_base::failbit).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("app=%lldLL",(long long)ios_base::app).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("binary=%lldLL",(long long)ios_base::binary).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("in=%lldLL",(long long)ios_base::in).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("out=%lldLL",(long long)ios_base::out).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("trunc=%lldLL",(long long)ios_base::trunc).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("ate=%lldLL",(long long)ios_base::ate).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLseek_dir),-1,-2,1,G__FastAllocString(2048).Format("beg=%lldLL",(long long)ios_base::beg).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLseek_dir),-1,-2,1,G__FastAllocString(2048).Format("cur=%lldLL",(long long)ios_base::cur).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLseek_dir),-1,-2,1,G__FastAllocString(2048).Format("end=%lldLL",(long long)ios_base::end).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("boolalpha=%lldLL",(long long)ios_base::boolalpha).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("dec=%lldLL",(long long)ios_base::dec).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("fixed=%lldLL",(long long)ios_base::fixed).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("hex=%lldLL",(long long)ios_base::hex).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("internal=%lldLL",(long long)ios_base::internal).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("left=%lldLL",(long long)ios_base::left).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("oct=%lldLL",(long long)ios_base::oct).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("right=%lldLL",(long long)ios_base::right).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("scientific=%lldLL",(long long)ios_base::scientific).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("showbase=%lldLL",(long long)ios_base::showbase).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("showpoint=%lldLL",(long long)ios_base::showpoint).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("showpos=%lldLL",(long long)ios_base::showpos).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("skipws=%lldLL",(long long)ios_base::skipws).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("unitbuf=%lldLL",(long long)ios_base::unitbuf).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("uppercase=%lldLL",(long long)ios_base::uppercase).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("adjustfield=%lldLL",(long long)ios_base::adjustfield).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("basefield=%lldLL",(long long)ios_base::basefield).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("floatfield=%lldLL",(long long)ios_base::floatfield).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLevent),-1,-2,1,G__FastAllocString(2048).Format("erase_event=%lldLL",(long long)ios_base::erase_event).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLevent),-1,-2,1,G__FastAllocString(2048).Format("imbue_event=%lldLL",(long long)ios_base::imbue_event).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLevent),-1,-2,1,G__FastAllocString(2048).Format("copyfmt_event=%lldLL",(long long)ios_base::copyfmt_event).data(),0,(char*)NULL); + } + G__tag_memvar_reset(); +} + + + /* ios_base::Init */ +static void G__setup_memvarios_basecLcLInit(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit)); + { ios_base::Init *p; p=(ios_base::Init*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* char_traits */ +static void G__setup_memvarchar_traitslEchargR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + { char_traits *p; p=(char_traits*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_istream > */ +static void G__setup_memvarbasic_istreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + { basic_istream > *p; p=(basic_istream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ios > */ +static void G__setup_memvarbasic_ioslEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + { basic_ios > *p; p=(basic_ios >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_streambuf > */ +static void G__setup_memvarbasic_streambuflEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + { basic_streambuf > *p; p=(basic_streambuf >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ostream > */ +static void G__setup_memvarbasic_ostreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + { basic_ostream > *p; p=(basic_ostream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ostream >::sentry */ +static void G__setup_memvarbasic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + { basic_ostream >::sentry *p; p=(basic_ostream >::sentry*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_istream >::sentry */ +static void G__setup_memvarbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + { basic_istream >::sentry *p; p=(basic_istream >::sentry*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_filebuf > */ +static void G__setup_memvarbasic_filebuflEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + { basic_filebuf > *p; p=(basic_filebuf >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ifstream > */ +static void G__setup_memvarbasic_ifstreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + { basic_ifstream > *p; p=(basic_ifstream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ofstream > */ +static void G__setup_memvarbasic_ofstreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + { basic_ofstream > *p; p=(basic_ofstream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_fstream > */ +static void G__setup_memvarbasic_fstreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR)); + { basic_fstream > *p; p=(basic_fstream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_iostream > */ +static void G__setup_memvarbasic_iostreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR)); + { basic_iostream > *p; p=(basic_iostream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_stringbuf,allocator > */ +static void G__setup_memvarbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + { basic_stringbuf,allocator > *p; p=(basic_stringbuf,allocator >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_istringstream,allocator > */ +static void G__setup_memvarbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + { basic_istringstream,allocator > *p; p=(basic_istringstream,allocator >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ostringstream,allocator > */ +static void G__setup_memvarbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + { basic_ostringstream,allocator > *p; p=(basic_ostringstream,allocator >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_stringstream,allocator > */ +static void G__setup_memvarbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + { basic_stringstream,allocator > *p; p=(basic_stringstream,allocator >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + +extern "C" void G__cpp_setup_memvarG__stream() { +} +/*********************************************************** +************************************************************ +************************************************************ +************************************************************ +************************************************************ +************************************************************ +************************************************************ +***********************************************************/ + +/********************************************************* +* Member function information setup for each class +*********************************************************/ +static void G__setup_memfuncmbstate_t(void) { + /* mbstate_t */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_mbstate_t)); + // automatic default constructor + G__memfunc_setup("mbstate_t", 963, G__G__stream_1_0_1, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_mbstate_t), -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic copy constructor + G__memfunc_setup("mbstate_t", 963, G__G__stream_1_0_2, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_mbstate_t), -1, 0, 1, 1, 1, 0, "u 'mbstate_t' - 11 - -", (char*) NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~mbstate_t", 1089, G__G__stream_1_0_3, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic assignment operator + G__memfunc_setup("operator=", 937, G__G__stream_1_0_4, (int) ('u'), G__get_linked_tagnum(&G__G__streamLN_mbstate_t), -1, 1, 1, 1, 1, 0, "u 'mbstate_t' - 11 - -", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncstreamoff(void) { + /* streamoff */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_streamoff)); + // automatic default constructor + G__memfunc_setup("streamoff", 967, G__G__stream_2_0_1, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_streamoff), -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic copy constructor + G__memfunc_setup("streamoff", 967, G__G__stream_2_0_2, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_streamoff), -1, 0, 1, 1, 1, 0, "u 'streamoff' - 11 - -", (char*) NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~streamoff", 1093, G__G__stream_2_0_3, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic assignment operator + G__memfunc_setup("operator=", 937, G__G__stream_2_0_4, (int) ('u'), G__get_linked_tagnum(&G__G__streamLN_streamoff), -1, 1, 1, 1, 1, 0, "u 'streamoff' - 11 - -", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncfposlEmbstate_tgR(void) { + /* fpos */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR)); + G__memfunc_setup("fpos",1525,G__G__stream_3_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("fpos",1525,G__G__stream_3_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR), -1, 0, 1, 1, 1, 0, "u 'fpos' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("fpos",1525,G__G__stream_3_0_3, 105, G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR), -1, 0, 1, 1, 1, 0, "n - - 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator streamoff",1875,G__G__stream_3_0_4, 110, -1, G__defined_typename("streamoff"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator+",919,G__G__stream_3_0_5, 117, G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR), -1, 0, 1, 1, 1, 8, "n - 'streamoff' 0 - a", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator-",921,G__G__stream_3_0_6, 117, G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR), -1, 0, 1, 1, 1, 8, "n - 'streamoff' 0 - a", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator-",921,G__G__stream_3_0_7, 110, -1, G__defined_typename("streamoff"), 0, 1, 1, 1, 8, "u 'fpos' - 11 - a", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator+=",980,G__G__stream_3_0_8, 117, G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR), -1, 1, 1, 1, 1, 0, "n - 'streamoff' 0 - a", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator-=",982,G__G__stream_3_0_9, 117, G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR), -1, 1, 1, 1, 1, 0, "n - 'streamoff' 0 - a", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("state",545,G__G__stream_3_0_10, 117, G__get_linked_tagnum(&G__G__streamLN_mbstate_t), G__defined_typename("mbstate_t"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("state",545,G__G__stream_3_0_11, 121, -1, -1, 0, 1, 1, 1, 0, "u 'mbstate_t' 'mbstate_t' 0 - a", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~fpos", 1651, G__G__stream_3_0_12, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic assignment operator + G__memfunc_setup("operator=", 937, G__G__stream_3_0_13, (int) ('u'), G__get_linked_tagnum(&G__G__streamLN_fposlEmbstate_tgR), -1, 1, 1, 1, 1, 0, "u 'fpos' - 11 - -", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncios_base(void) { + /* ios_base */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__memfunc_setup("register_callback",1777,G__G__stream_4_0_1, 121, -1, -1, 0, 2, 1, 1, 0, +"Y - 'ios_base::event_callback' 0 - fn i - - 0 - index", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("flags",525,G__G__stream_4_0_2, 105, -1, G__defined_typename("ios_base::fmtflags"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("flags",525,G__G__stream_4_0_3, 105, -1, G__defined_typename("ios_base::fmtflags"), 0, 1, 1, 1, 0, "i - 'ios_base::fmtflags' 0 - fmtfl", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("setf",434,G__G__stream_4_0_4, 105, -1, G__defined_typename("ios_base::fmtflags"), 0, 1, 1, 1, 0, "i - 'ios_base::fmtflags' 0 - fmtfl", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("setf",434,G__G__stream_4_0_5, 105, -1, G__defined_typename("ios_base::fmtflags"), 0, 2, 1, 1, 0, +"i - 'ios_base::fmtflags' 0 - fmtfl i - 'ios_base::fmtflags' 0 - mask", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("unsetf",661,G__G__stream_4_0_6, 121, -1, -1, 0, 1, 1, 1, 0, "i - 'ios_base::fmtflags' 0 - mask", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("precision",972,G__G__stream_4_0_7, 110, -1, G__defined_typename("streamsize"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("precision",972,G__G__stream_4_0_8, 110, -1, G__defined_typename("streamsize"), 0, 1, 1, 1, 0, "n - 'streamsize' 0 - prec", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("width",544,G__G__stream_4_0_9, 110, -1, G__defined_typename("streamsize"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("width",544,G__G__stream_4_0_10, 110, -1, G__defined_typename("streamsize"), 0, 1, 1, 1, 0, "n - 'streamsize' 0 - wide", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("xalloc",643,G__G__stream_4_0_11, 105, -1, -1, 0, 0, 3, 1, 0, "", (char*)NULL, (void*) G__func2void( (int (*)())(&ios_base::xalloc) ), 0); + G__memfunc_setup("iword",549,G__G__stream_4_0_12, 108, -1, -1, 1, 1, 1, 1, 0, "i - - 0 - index", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pword",556,G__G__stream_4_0_13, 89, -1, -1, 1, 1, 1, 1, 0, "i - - 0 - index", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sync_with_stdio",1626,G__G__stream_4_0_14, 103, -1, -1, 0, 1, 1, 1, 0, "g - - 0 'true' sync", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("ios_base",837,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("ios_base",837,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 0, 1, 1, 4, 0, "u 'ios_base' - 11 - x", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 4, 0, "u 'ios_base' - 11 - x", (char*)NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncios_basecLcLInit(void) { + /* ios_base::Init */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit)); + G__memfunc_setup("Init",404,G__G__stream_10_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic copy constructor + G__memfunc_setup("Init", 404, G__G__stream_10_0_2, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit), -1, 0, 1, 1, 1, 0, "u 'ios_base::Init' - 11 - -", (char*) NULL, (void*) NULL, 0); + // automatic assignment operator + G__memfunc_setup("operator=", 937, G__G__stream_10_0_3, (int) ('u'), G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit), -1, 1, 1, 1, 1, 0, "u 'ios_base::Init' - 11 - -", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncchar_traitslEchargR(void) { + /* char_traits */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__memfunc_setup("assign",645,G__G__stream_11_0_1, 121, -1, -1, 0, 2, 3, 1, 0, +"c - 'char_traits::char_type' 1 - c1 c - 'char_traits::char_type' 11 - c2", (char*)NULL, (void*) G__func2void( (void (*)(char_traits::char_type&, const char_traits::char_type&))(&char_traits::assign) ), 0); + G__memfunc_setup("to_char_type",1281,G__G__stream_11_0_2, 99, -1, G__defined_typename("char_traits::char_type"), 0, 1, 3, 1, 0, "i - 'char_traits::int_type' 11 - c", (char*)NULL, (void*) G__func2void( (char_traits::char_type (*)(const char_traits::int_type&))(&char_traits::to_char_type) ), 0); + G__memfunc_setup("to_int_type",1198,G__G__stream_11_0_3, 105, -1, G__defined_typename("char_traits::int_type"), 0, 1, 3, 1, 0, "c - 'char_traits::char_type' 11 - c", (char*)NULL, (void*) G__func2void( (char_traits::int_type (*)(const char_traits::char_type&))(&char_traits::to_int_type) ), 0); + G__memfunc_setup("eq",214,G__G__stream_11_0_4, 103, -1, -1, 0, 2, 3, 1, 0, +"c - 'char_traits::char_type' 11 - c1 c - 'char_traits::char_type' 11 - c2", (char*)NULL, (void*) G__func2void( (bool (*)(const char_traits::char_type&, const char_traits::char_type&))(&char_traits::eq) ), 0); + G__memfunc_setup("lt",224,G__G__stream_11_0_5, 103, -1, -1, 0, 2, 3, 1, 0, +"c - 'char_traits::char_type' 11 - c1 c - 'char_traits::char_type' 11 - c2", (char*)NULL, (void*) G__func2void( (bool (*)(const char_traits::char_type&, const char_traits::char_type&))(&char_traits::lt) ), 0); + G__memfunc_setup("compare",743,G__G__stream_11_0_6, 105, -1, -1, 0, 3, 3, 1, 0, +"C - 'char_traits::char_type' 10 - s1 C - 'char_traits::char_type' 10 - s2 " +"k - 'size_t' 0 - n", (char*)NULL, (void*) G__func2void( (int (*)(const char_traits::char_type*, const char_traits::char_type*, size_t))(&char_traits::compare) ), 0); + G__memfunc_setup("find",417,G__G__stream_11_0_7, 67, -1, G__defined_typename("char_traits::char_type"), 0, 3, 3, 1, 1, +"C - 'char_traits::char_type' 10 - s i - - 0 - n " +"c - 'char_traits::char_type' 11 - a", (char*)NULL, (void*) G__func2void( (const char_traits::char_type* (*)(const char_traits::char_type*, int, const char_traits::char_type&))(&char_traits::find) ), 0); + G__memfunc_setup("eq_int_type",1185,G__G__stream_11_0_8, 103, -1, -1, 0, 2, 3, 1, 0, +"i - 'char_traits::int_type' 11 - c1 i - 'char_traits::int_type' 11 - c2", (char*)NULL, (void*) G__func2void( (bool (*)(const char_traits::int_type&, const char_traits::int_type&))(&char_traits::eq_int_type) ), 0); + G__memfunc_setup("eof",314,G__G__stream_11_0_9, 105, -1, G__defined_typename("char_traits::int_type"), 0, 0, 3, 1, 0, "", (char*)NULL, (void*) G__func2void( (char_traits::int_type (*)())(&char_traits::eof) ), 0); + G__memfunc_setup("not_eof",746,G__G__stream_11_0_10, 105, -1, G__defined_typename("char_traits::int_type"), 0, 1, 3, 1, 0, "i - 'char_traits::int_type' 11 - c", (char*)NULL, (void*) G__func2void( (char_traits::int_type (*)(const char_traits::int_type&))(&char_traits::not_eof) ), 0); + G__memfunc_setup("length",642,G__G__stream_11_0_11, 107, -1, G__defined_typename("size_t"), 0, 1, 3, 1, 0, "C - 'char_traits::char_type' 10 - s", (char*)NULL, (void*) G__func2void( (size_t (*)(const char_traits::char_type*))(&char_traits::length) ), 0); + G__memfunc_setup("copy",443,G__G__stream_11_0_12, 67, -1, G__defined_typename("char_traits::char_type"), 0, 3, 3, 1, 0, +"C - 'char_traits::char_type' 0 - dst C - 'char_traits::char_type' 10 - src " +"k - 'size_t' 0 - n", (char*)NULL, (void*) G__func2void( (char_traits::char_type* (*)(char_traits::char_type*, const char_traits::char_type*, size_t))(&char_traits::copy) ), 0); + G__memfunc_setup("move",439,G__G__stream_11_0_13, 67, -1, G__defined_typename("char_traits::char_type"), 0, 3, 3, 1, 0, +"C - 'char_traits::char_type' 0 - s1 C - 'char_traits::char_type' 10 - s2 " +"k - 'size_t' 0 - n", (char*)NULL, (void*) G__func2void( (char_traits::char_type* (*)(char_traits::char_type*, const char_traits::char_type*, size_t))(&char_traits::move) ), 0); + G__memfunc_setup("assign",645,G__G__stream_11_0_14, 67, -1, G__defined_typename("char_traits::char_type"), 0, 3, 3, 1, 0, +"C - 'char_traits::char_type' 0 - s k - 'size_t' 0 - n " +"c - 'char_traits::char_type' 10 - a", (char*)NULL, (void*) NULL, 0); + // automatic default constructor + G__memfunc_setup("char_traits", 1708, G__G__stream_11_0_15, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR), -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic copy constructor + G__memfunc_setup("char_traits", 1708, G__G__stream_11_0_16, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR), -1, 0, 1, 1, 1, 0, "u 'char_traits' - 11 - -", (char*) NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~char_traits", 1834, G__G__stream_11_0_17, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic assignment operator + G__memfunc_setup("operator=", 937, G__G__stream_11_0_18, (int) ('u'), G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR), -1, 1, 1, 1, 1, 0, "u 'char_traits' - 11 - -", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_istreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_istream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_istream >",3686,G__G__stream_12_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 5, 1, 0, "U 'basic_streambuf >' - 0 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_12_0_2, 105, -1, G__defined_typename("basic_istream >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_12_0_3, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 3, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s n - 'streamsize' 0 - n " +"c - 'basic_istream >::char_type' 0 - delim", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_12_0_4, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 2, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s n - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_12_0_5, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 1, 0, "c - 'basic_istream >::char_type' 1 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_12_0_6, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 2, 1, 1, 0, +"u 'basic_streambuf >' - 1 - sb c - 'basic_istream >::char_type' 0 - delim", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_12_0_7, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 1, 0, "u 'basic_streambuf >' - 1 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("getline",744,G__G__stream_12_0_8, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 3, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s n - 'streamsize' 0 - n " +"c - 'basic_istream >::char_type' 0 - delim", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("getline",744,G__G__stream_12_0_9, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 2, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s n - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("ignore",644,G__G__stream_12_0_10, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 2, 1, 1, 0, +"n - 'streamsize' 0 - n i - 'basic_istream >::int_type' 0 - delim", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("ignore",644,G__G__stream_12_0_11, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 1, 0, "n - 'streamsize' 0 '1' n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("read",412,G__G__stream_12_0_12, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 2, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s n - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("readsome",848,G__G__stream_12_0_13, 110, -1, G__defined_typename("streamsize"), 0, 2, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s n - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("peek",421,G__G__stream_12_0_14, 105, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("tellg",536,G__G__stream_12_0_15, 110, -1, G__defined_typename("basic_istream >::pos_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("seekg",527,G__G__stream_12_0_16, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 1, 0, "n - 'basic_istream >::pos_type' 0 - pos", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sync",445,G__G__stream_12_0_17, 105, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("seekg",527,G__G__stream_12_0_18, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 2, 1, 1, 0, +"n - 'basic_istream >::off_type' 0 - - i - 'ios_base::seekdir' 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("putback",746,G__G__stream_12_0_19, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 1, 0, "c - 'basic_istream >::char_type' 0 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("unget",547,G__G__stream_12_0_20, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("gcount",656,G__G__stream_12_0_21, 110, -1, G__defined_typename("streamsize"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_istream >",3686,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_istream >", 3812, G__G__stream_12_0_23, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ioslEcharcOchar_traitslEchargRsPgR(void) { + /* basic_ios > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_ios >",3260,G__G__stream_13_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 5, 1, 0, "U 'basic_streambuf >' - 0 - sb_arg", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("fill",423,G__G__stream_13_0_2, 99, -1, G__defined_typename("basic_ios >::char_type"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("fill",423,G__G__stream_13_0_3, 99, -1, G__defined_typename("basic_ios >::char_type"), 0, 1, 1, 1, 0, "c - 'basic_ios >::char_type' 0 - ch", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("exceptions",1090,G__G__stream_13_0_4, 121, -1, -1, 0, 1, 1, 1, 0, "i - 'ios_base::iostate' 0 - excpt", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("exceptions",1090,G__G__stream_13_0_5, 105, -1, G__defined_typename("ios_base::iostate"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("clear",519,G__G__stream_13_0_6, 121, -1, -1, 0, 1, 1, 1, 0, "i - 'ios_base::iostate' 0 'goodbit' state", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("setstate",877,G__G__stream_13_0_7, 121, -1, -1, 0, 1, 1, 1, 0, "i - 'ios_base::iostate' 0 - state", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdstate",759,G__G__stream_13_0_8, 105, -1, G__defined_typename("ios_base::iostate"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator!",909,G__G__stream_13_0_9, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("good",425,G__G__stream_13_0_10, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("eof",314,G__G__stream_13_0_11, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("fail",412,G__G__stream_13_0_12, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("bad",295,G__G__stream_13_0_13, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("copyfmt",770,G__G__stream_13_0_14, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 1, 0, "u 'basic_ios >' - 11 - rhs", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("tie",322,G__G__stream_13_0_15, 85, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("tie",322,G__G__stream_13_0_16, 85, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 1, 1, 0, "U 'basic_ostream >' - 0 - tie_arg", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_13_0_17, 85, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_13_0_18, 85, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 1, 1, 0, "U 'basic_streambuf >' - 0 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("narrow",665,G__G__stream_13_0_19, 99, -1, -1, 0, 2, 1, 1, 8, +"c - - 0 - - c - - 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("widen",535,G__G__stream_13_0_20, 99, -1, -1, 0, 1, 1, 1, 8, "c - - 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ios >",3260,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ios >",3260,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 1, 4, 0, "u 'basic_ios >' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 4, 0, "u 'basic_ios >' - 11 - -", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ios >", 3386, G__G__stream_13_0_25, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_streambuflEcharcOchar_traitslEchargRsPgR(void) { + /* basic_streambuf > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("pubsetbuf",976,G__G__stream_14_0_1, 85, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_streambuf >::basic_streambuf >"), 0, 2, 1, 1, 0, +"C - 'basic_streambuf >::char_type' 0 - s n - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pubseekoff",1066,G__G__stream_14_0_2, 110, -1, G__defined_typename("basic_streambuf >::pos_type"), 0, 3, 1, 1, 0, +"n - 'basic_streambuf >::off_type' 0 - off i - 'ios_base::seekdir' 0 - way " +"i - 'ios_base::openmode' 0 'ios_base::in|ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pubseekpos",1089,G__G__stream_14_0_3, 110, -1, G__defined_typename("basic_streambuf >::pos_type"), 0, 2, 1, 1, 0, +"n - 'basic_streambuf >::pos_type' 0 - sp i - 'ios_base::openmode' 0 'ios_base::in|ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pubsync",772,G__G__stream_14_0_4, 105, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("in_avail",835,G__G__stream_14_0_5, 110, -1, G__defined_typename("streamsize"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("snextc",661,G__G__stream_14_0_6, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sbumpc",650,G__G__stream_14_0_7, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sgetc",534,G__G__stream_14_0_8, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sgetn",545,G__G__stream_14_0_9, 110, -1, G__defined_typename("streamsize"), 0, 2, 1, 1, 0, +"C - 'basic_streambuf >::char_type' 0 - s n - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sputbackc",960,G__G__stream_14_0_10, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 1, 1, 1, 0, "c - 'basic_streambuf >::char_type' 0 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sungetc",761,G__G__stream_14_0_11, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sputc",559,G__G__stream_14_0_12, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 1, 1, 1, 0, "c - 'basic_streambuf >::char_type' 0 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sputn",570,G__G__stream_14_0_13, 110, -1, G__defined_typename("streamsize"), 0, 2, 1, 1, 0, +"C - 'basic_streambuf >::char_type' 10 - s n - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_streambuf >",3898,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_streambuf >",3898,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 1, 4, 0, "u 'basic_streambuf >' - 11 - x", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 4, 0, "u 'basic_streambuf >' - 11 - x", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_streambuf >", 4024, G__G__stream_14_0_17, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ostreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_ostream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_ostream >",3692,G__G__stream_15_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 5, 1, 0, "U 'basic_streambuf >' - 0 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("put",345,G__G__stream_15_0_2, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 1, 0, "c - 'basic_ostream >::char_type' 0 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("write",555,G__G__stream_15_0_3, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 2, 1, 1, 0, +"C - 'basic_ostream >::char_type' 10 - s n - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("flush",546,G__G__stream_15_0_4, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("seekp",536,G__G__stream_15_0_5, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 1, 0, "n - 'basic_ostream >::pos_type' 0 - pos", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("seekp",536,G__G__stream_15_0_6, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 1, 2, 1, 1, 0, +"n - 'basic_ostream >::off_type' 0 - - i - 'ios_base::seekdir' 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("tellp",545,G__G__stream_15_0_7, 110, -1, G__defined_typename("basic_ostream >::pos_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ostream >",3692,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ostream >", 3818, G__G__stream_15_0_9, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(void) { + /* basic_ostream >::sentry */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + G__memfunc_setup("sentry",677,G__G__stream_16_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 0, 1, 5, 1, 0, "u 'basic_ostream >' - 1 - stream", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator bool",1336,G__G__stream_16_0_2, 103, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sentry",677,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 0, 1, 1, 4, 0, "u 'basic_ostream >::sentry' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 1, 1, 1, 4, 0, "u 'basic_ostream >::sentry' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(void) { + /* basic_istream >::sentry */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + G__memfunc_setup("sentry",677,G__G__stream_17_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 0, 2, 1, 1, 0, +"u 'basic_istream >' - 1 - stream g - - 0 '0' noskipws", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sentry",677,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 0, 1, 1, 4, 0, "u 'basic_istream >::sentry' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 1, 1, 1, 4, 0, "u 'basic_istream >::sentry' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator bool",1336,G__G__stream_17_0_4, 103, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_filebuflEcharcOchar_traitslEchargRsPgR(void) { + /* basic_filebuf > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_filebuf >",3662,G__G__stream_18_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("is_open",749,G__G__stream_18_0_2, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("open",434,G__G__stream_18_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("close",534,G__G__stream_18_0_4, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 4, 0, "u 'basic_filebuf >' - 11 - x", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_filebuf >", 3788, G__G__stream_18_0_15, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ifstreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_ifstream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_ifstream >",3788,G__G__stream_19_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ifstream >",3788,G__G__stream_19_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 'ios_base::in' mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_19_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("is_open",749,G__G__stream_19_0_4, 103, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("open",434,G__G__stream_19_0_5, 121, -1, -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 'ios_base::in' mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("close",534,G__G__stream_19_0_6, 121, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ifstream >", 3914, G__G__stream_19_0_7, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ofstreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_ofstream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_ofstream >",3794,G__G__stream_20_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ofstream >",3794,G__G__stream_20_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 'ios_base::out' mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_20_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("is_open",749,G__G__stream_20_0_4, 103, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("open",434,G__G__stream_20_0_5, 121, -1, -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 'ios_base::out' mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("close",534,G__G__stream_20_0_6, 121, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ofstream >", 3920, G__G__stream_20_0_7, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_fstreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_fstream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_fstream >",3683,G__G__stream_21_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_fstream >",3683,G__G__stream_21_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 - mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_21_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("is_open",749,G__G__stream_21_0_4, 103, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("open",434,G__G__stream_21_0_5, 121, -1, -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 - mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("close",534,G__G__stream_21_0_6, 121, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_fstream >", 3809, G__G__stream_21_0_7, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_iostreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_iostream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_iostream >",3797,G__G__stream_22_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 5, 1, 0, "U 'basic_streambuf >' - 0 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_iostream >",3797,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 5, 2, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_iostream >", 3923, G__G__stream_22_0_3, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + /* basic_stringbuf,allocator > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__memfunc_setup("basic_stringbuf,allocator >",5450,G__G__stream_41_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 1, 5, 1, 0, "i - 'ios_base::openmode' 0 'ios_base::in|ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_stringbuf,allocator >",5450,G__G__stream_41_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"u 'string' 'basic_stringbuf,allocator >::string_type' 11 - str i - 'ios_base::openmode' 0 'ios_base::in|ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_41_0_3, 117, G__get_linked_tagnum(&G__G__streamLN_string), G__defined_typename("basic_stringbuf,allocator >::string_type"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_41_0_4, 121, -1, -1, 0, 1, 1, 1, 0, "u 'string' 'basic_stringbuf,allocator >::string_type' 11 - str_arg", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 1, 1, 1, 4, 0, "u 'basic_stringbuf,allocator >' - 11 - x", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_stringbuf,allocator >", 5576, G__G__stream_41_0_13, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + /* basic_istringstream,allocator > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__memfunc_setup("basic_istringstream,allocator >",5890,G__G__stream_42_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 1, 5, 1, 0, "i - 'ios_base::openmode' 0 'ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_istringstream,allocator >",5890,G__G__stream_42_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"u 'string' 'basic_istringstream,allocator >::string_type' 11 - str i - 'ios_base::openmode' 0 'ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_istringstream,allocator >",5890,G__G__stream_42_0_3, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"C - - 10 - str i - 'ios_base::openmode' 0 'ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_42_0_4, 85, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_42_0_5, 117, G__get_linked_tagnum(&G__G__streamLN_string), G__defined_typename("basic_istringstream,allocator >::string_type"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_42_0_6, 121, -1, -1, 0, 1, 1, 1, 0, "u 'string' 'basic_istringstream,allocator >::string_type' 11 - str", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_istringstream,allocator >", 6016, G__G__stream_42_0_7, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + /* basic_ostringstream,allocator > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__memfunc_setup("basic_ostringstream,allocator >",5896,G__G__stream_43_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 1, 5, 1, 0, "i - 'ios_base::openmode' 0 'ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ostringstream,allocator >",5896,G__G__stream_43_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"u 'string' 'basic_ostringstream,allocator >::string_type' 11 - str i - 'ios_base::openmode' 0 'ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_43_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_43_0_4, 117, G__get_linked_tagnum(&G__G__streamLN_string), G__defined_typename("basic_ostringstream,allocator >::string_type"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_43_0_5, 121, -1, -1, 0, 1, 1, 1, 0, "u 'string' 'basic_ostringstream,allocator >::string_type' 11 - str", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ostringstream,allocator >", 6022, G__G__stream_43_0_6, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + /* basic_stringstream,allocator > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__memfunc_setup("basic_stringstream,allocator >",5785,G__G__stream_44_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 1, 5, 1, 0, "i - 'ios_base::openmode' 0 'ios_base::out|ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_stringstream,allocator >",5785,G__G__stream_44_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"u 'string' 'basic_stringstream,allocator >::string_type' 11 - str i - 'ios_base::openmode' 0 'ios_base::out|ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_44_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_44_0_4, 117, G__get_linked_tagnum(&G__G__streamLN_string), G__defined_typename("basic_stringstream,allocator >::string_type"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_44_0_5, 121, -1, -1, 0, 1, 1, 1, 0, "u 'string' 'basic_stringstream,allocator >::string_type' 11 - str", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_stringstream,allocator >", 5911, G__G__stream_44_0_6, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + + +/********************************************************* +* Member function information setup +*********************************************************/ +extern "C" void G__cpp_setup_memfuncG__stream() { +} + +/********************************************************* +* Global variable information setup for each class +*********************************************************/ +static void G__cpp_setup_global0() { + + /* Setting up global variables */ + G__resetplocal(); + + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"__GNUC__=4",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"__GNUC_MINOR__=2",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__IOSTREAM_H=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__TMPLTIOS=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__OSTREAMBODY=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__OSTREAMGLOBALSTUB=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__MANIP_SUPPORT=0",1,(char*)NULL); + G__memvar_setup((void*)(&cin),117,0,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),G__defined_typename("istream"),-1,1,"cin=",0,(char*)NULL); + G__memvar_setup((void*)(&cout),117,0,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__defined_typename("ostream"),-1,1,"cout=",0,(char*)NULL); + G__memvar_setup((void*)(&cerr),117,0,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__defined_typename("ostream"),-1,1,"cerr=",0,(char*)NULL); + G__memvar_setup((void*)(&clog),117,0,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__defined_typename("ostream"),-1,1,"clog=",0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__FSTREAM_H=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__SSTREAM_H=0",1,(char*)NULL); + + G__resetglobalenv(); +} +extern "C" void G__cpp_setup_globalG__stream() { + G__cpp_setup_global0(); +} + +/********************************************************* +* Global function information setup for each class +*********************************************************/ +static void G__cpp_setup_func0() { + G__lastifuncposition(); + + G__memfunc_setup("dec", 300, G__G__stream__0_0, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("hex", 325, G__G__stream__0_1, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("oct", 326, G__G__stream__0_2, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("fixed", 528, G__G__stream__0_3, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("scientific", 1057, G__G__stream__0_4, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("right", 542, G__G__stream__0_5, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("left", 427, G__G__stream__0_6, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("internal", 861, G__G__stream__0_7, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("nouppercase", 1189, G__G__stream__0_8, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("uppercase", 968, G__G__stream__0_9, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noskipws", 894, G__G__stream__0_10, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("skipws", 673, G__G__stream__0_11, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noshowpos", 1008, G__G__stream__0_12, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("showpos", 787, G__G__stream__0_13, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noshowpoint", 1224, G__G__stream__0_14, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("showpoint", 1003, G__G__stream__0_15, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noshowbase", 1081, G__G__stream__0_16, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("showbase", 860, G__G__stream__0_17, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noboolalpha", 1167, G__G__stream__0_18, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("boolalpha", 946, G__G__stream__0_19, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("ws", 234, G__G__stream__0_20, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 1, 1, 1, 0, "u 'basic_istream >' 'istream' 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("endl", 419, G__G__stream__0_21, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 1, 1, 1, 0, "u 'basic_ostream >' 'ostream' 1 - i", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("ends", 426, G__G__stream__0_22, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 1, 1, 1, 0, "u 'basic_ostream >' 'ostream' 1 - i", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("flush", 546, G__G__stream__0_23, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 1, 1, 1, 0, "u 'basic_ostream >' 'ostream' 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_24, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - c - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_25, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - C - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_26, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - Y - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_27, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - b - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_28, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - s - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_29, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - r - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_30, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - ostr i - - 1 - i", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_31, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - h - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_32, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - l - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_33, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - k - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_34, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - f - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_35, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - d - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_36, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - g - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_37, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - c - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_38, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - b - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_39, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - s - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_40, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - r - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_41, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - istr i - - 1 - f", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_42, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - h - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_43, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - l - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_44, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - k - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_45, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - f - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_46, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - d - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_47, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - g - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_48, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - C - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_49, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - Y - - 1 - -", (char*) NULL +, (void*) NULL, 0); +} + +static void G__cpp_setup_func1() { + + G__resetifuncposition(); +} + +extern "C" void G__cpp_setup_funcG__stream() { + G__cpp_setup_func0(); + G__cpp_setup_func1(); +} + +/********************************************************* +* Class,struct,union,enum tag information setup +*********************************************************/ +/* Setup class/struct taginfo */ +G__linked_taginfo G__G__streamLN_mbstate_t = { "mbstate_t" , 115 , -1 }; +G__linked_taginfo G__G__streamLN_streamoff = { "streamoff" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_fposlEmbstate_tgR = { "fpos" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_ios_base = { "ios_base" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLio_state = { "ios_base::io_state" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLopen_mode = { "ios_base::open_mode" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLseek_dir = { "ios_base::seek_dir" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLfmt_flags = { "ios_base::fmt_flags" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLevent = { "ios_base::event" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLInit = { "ios_base::Init" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_char_traitslEchargR = { "char_traits" , 115 , -1 }; +G__linked_taginfo G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR = { "basic_istream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR = { "basic_ios >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR = { "basic_streambuf >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR = { "basic_ostream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry = { "basic_ostream >::sentry" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry = { "basic_istream >::sentry" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR = { "basic_filebuf >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR = { "basic_ifstream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR = { "basic_ofstream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR = { "basic_fstream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR = { "basic_iostream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_string = { "string" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_stringbuf,allocator >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_istringstream,allocator >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_ostringstream,allocator >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_stringstream,allocator >" , 99 , -1 }; + +/* Reset class/struct taginfo */ +extern "C" void G__cpp_reset_tagtableG__stream() { + G__G__streamLN_mbstate_t.tagnum = -1 ; + G__G__streamLN_streamoff.tagnum = -1 ; + G__G__streamLN_fposlEmbstate_tgR.tagnum = -1 ; + G__G__streamLN_ios_base.tagnum = -1 ; + G__G__streamLN_ios_basecLcLio_state.tagnum = -1 ; + G__G__streamLN_ios_basecLcLopen_mode.tagnum = -1 ; + G__G__streamLN_ios_basecLcLseek_dir.tagnum = -1 ; + G__G__streamLN_ios_basecLcLfmt_flags.tagnum = -1 ; + G__G__streamLN_ios_basecLcLevent.tagnum = -1 ; + G__G__streamLN_ios_basecLcLInit.tagnum = -1 ; + G__G__streamLN_char_traitslEchargR.tagnum = -1 ; + G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry.tagnum = -1 ; + G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry.tagnum = -1 ; + G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_string.tagnum = -1 ; + G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; +} + + +extern "C" void G__cpp_setup_tagtableG__stream() { + + /* Setting up class,struct,union tag entry */ + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_mbstate_t),sizeof(mbstate_t),-1,0,(char*)NULL,G__setup_memvarmbstate_t,G__setup_memfuncmbstate_t); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_streamoff),sizeof(streamoff),-1,0,(char*)NULL,G__setup_memvarstreamoff,G__setup_memfuncstreamoff); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_fposlEmbstate_tgR),sizeof(fpos),-1,33536,(char*)NULL,G__setup_memvarfposlEmbstate_tgR,G__setup_memfuncfposlEmbstate_tgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_base),sizeof(ios_base),-1,3840,(char*)NULL,G__setup_memvarios_base,G__setup_memfuncios_base); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLio_state),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLopen_mode),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLseek_dir),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLfmt_flags),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLevent),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLInit),sizeof(ios_base::Init),-1,1280,(char*)NULL,G__setup_memvarios_basecLcLInit,G__setup_memfuncios_basecLcLInit); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_char_traitslEchargR),sizeof(char_traits),-1,0,(char*)NULL,G__setup_memvarchar_traitslEchargR,G__setup_memfuncchar_traitslEchargR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_istream >),-1,34048,(char*)NULL,G__setup_memvarbasic_istreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_istreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),sizeof(basic_ios >),-1,36608,(char*)NULL,G__setup_memvarbasic_ioslEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_ioslEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),sizeof(basic_streambuf >),-1,3840,(char*)NULL,G__setup_memvarbasic_streambuflEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_streambuflEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_ostream >),-1,34048,(char*)NULL,G__setup_memvarbasic_ostreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_ostreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry),sizeof(basic_ostream >::sentry),-1,36352,(char*)NULL,G__setup_memvarbasic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry,G__setup_memfuncbasic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry),sizeof(basic_istream >::sentry),-1,36352,(char*)NULL,G__setup_memvarbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry,G__setup_memfuncbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR),sizeof(basic_filebuf >),-1,3328,(char*)NULL,G__setup_memvarbasic_filebuflEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_filebuflEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_ifstream >),-1,34048,(char*)NULL,G__setup_memvarbasic_ifstreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_ifstreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_ofstream >),-1,34048,(char*)NULL,G__setup_memvarbasic_ofstreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_ofstreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_fstream >),-1,33024,(char*)NULL,G__setup_memvarbasic_fstreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_fstreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_iostream >),-1,34048,(char*)NULL,G__setup_memvarbasic_iostreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_iostreamlEcharcOchar_traitslEchargRsPgR); + G__get_linked_tagnum_fwd(&G__G__streamLN_string); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),sizeof(basic_stringbuf,allocator >),-1,36096,(char*)NULL,G__setup_memvarbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR,G__setup_memfuncbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),sizeof(basic_istringstream,allocator >),-1,34048,(char*)NULL,G__setup_memvarbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR,G__setup_memfuncbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),sizeof(basic_ostringstream,allocator >),-1,34048,(char*)NULL,G__setup_memvarbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR,G__setup_memfuncbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),sizeof(basic_stringstream,allocator >),-1,34048,(char*)NULL,G__setup_memvarbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR,G__setup_memfuncbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); +} +extern "C" void G__cpp_setupG__stream(void) { + G__check_setup_version(30051515,"G__cpp_setupG__stream()"); + G__set_cpp_environmentG__stream(); + G__cpp_setup_tagtableG__stream(); + + G__cpp_setup_inheritanceG__stream(); + + G__cpp_setup_typetableG__stream(); + + G__cpp_setup_memvarG__stream(); + + G__cpp_setup_memfuncG__stream(); + G__cpp_setup_globalG__stream(); + G__cpp_setup_funcG__stream(); + + if(0==G__getsizep2memfunc()) G__get_sizep2memfuncG__stream(); + return; +} diff --git a/cint/cint/src/dict/libcxxstrm.h b/cint/cint/src/dict/libcxxstrm.h new file mode 100644 index 0000000000000..69504cb18b9b0 --- /dev/null +++ b/cint/cint/src/dict/libcxxstrm.h @@ -0,0 +1,84 @@ +/******************************************************************** +* libcxxstrm.h +* CAUTION: DON'T CHANGE THIS FILE. THIS FILE IS AUTOMATICALLY GENERATED +* FROM HEADER FILES LISTED IN G__setup_cpp_environmentXXX(). +* CHANGE THOSE HEADER FILES AND REGENERATE THIS FILE. +********************************************************************/ +#ifdef __CINT__ +#error libcxxstrm.h/C is only for compilation. Abort cint. +#endif +#include +#include +#include +#include +#include +#define G__ANSIHEADER +#define G__DICTIONARY +#define G__PRIVATE_GVALUE +#include "G__ci.h" +#include "FastAllocString.h" +extern "C" { +extern void G__cpp_setup_tagtableG__stream(); +extern void G__cpp_setup_inheritanceG__stream(); +extern void G__cpp_setup_typetableG__stream(); +extern void G__cpp_setup_memvarG__stream(); +extern void G__cpp_setup_globalG__stream(); +extern void G__cpp_setup_memfuncG__stream(); +extern void G__cpp_setup_funcG__stream(); +extern void G__set_cpp_environmentG__stream(); +} + + +#include "iostrm.h" +#include "fstrm.h" +#include "sstrm.h" + +#ifndef G__MEMFUNCBODY +#endif + +extern G__linked_taginfo G__G__streamLN_mbstate_t; +extern G__linked_taginfo G__G__streamLN_streamoff; +extern G__linked_taginfo G__G__streamLN_fposlEmbstate_tgR; +extern G__linked_taginfo G__G__streamLN_ios_base; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLio_state; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLopen_mode; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLseek_dir; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLfmt_flags; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLevent; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLInit; +extern G__linked_taginfo G__G__streamLN_char_traitslEchargR; +extern G__linked_taginfo G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +extern G__linked_taginfo G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +extern G__linked_taginfo G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_string; +extern G__linked_taginfo G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; + +/* STUB derived class for protected member access */ +typedef fpos G__fposlEmbstate_tgR; +typedef char_traits G__char_traitslEchargR; +typedef basic_istream > G__basic_istreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_ios > G__basic_ioslEcharcOchar_traitslEchargRsPgR; +typedef basic_streambuf > G__basic_streambuflEcharcOchar_traitslEchargRsPgR; +typedef basic_ostream > G__basic_ostreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_ostream >::sentry G__basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +typedef basic_istream >::sentry G__basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +typedef basic_filebuf > G__basic_filebuflEcharcOchar_traitslEchargRsPgR; +typedef basic_ifstream > G__basic_ifstreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_ofstream > G__basic_ofstreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_fstream > G__basic_fstreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_iostream > G__basic_iostreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_stringbuf,allocator > G__basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +typedef basic_istringstream,allocator > G__basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +typedef basic_ostringstream,allocator > G__basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +typedef basic_stringstream,allocator > G__basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; diff --git a/cint/cint/src/dict/libstrm.cxx b/cint/cint/src/dict/libstrm.cxx index 5ee324d433256..0e0a06a9c32ec 100644 --- a/cint/cint/src/dict/libstrm.cxx +++ b/cint/cint/src/dict/libstrm.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/libstrm.h b/cint/cint/src/dict/libstrm.h index 32f4d040e5460..94fab34373978 100644 --- a/cint/cint/src/dict/libstrm.h +++ b/cint/cint/src/dict/libstrm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/stdstrct.cxx b/cint/cint/src/dict/stdstrct.cxx index 602c9635c5e39..cbfcc62ccd292 100644 --- a/cint/cint/src/dict/stdstrct.cxx +++ b/cint/cint/src/dict/stdstrct.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/stdstrct.h b/cint/cint/src/dict/stdstrct.h index 17a575c9b1edf..d59d0848c5f4e 100644 --- a/cint/cint/src/dict/stdstrct.h +++ b/cint/cint/src/dict/stdstrct.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/sun5strm.cxx b/cint/cint/src/dict/sun5strm.cxx index baa22b408d5ba..a773cb21b8cac 100644 --- a/cint/cint/src/dict/sun5strm.cxx +++ b/cint/cint/src/dict/sun5strm.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/sunstrm.cxx b/cint/cint/src/dict/sunstrm.cxx index fc0964f2b4f7f..4ee91a89d907e 100644 --- a/cint/cint/src/dict/sunstrm.cxx +++ b/cint/cint/src/dict/sunstrm.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/sunstrm.h b/cint/cint/src/dict/sunstrm.h index 82bdc28352541..61d9b2486b102 100644 --- a/cint/cint/src/dict/sunstrm.h +++ b/cint/cint/src/dict/sunstrm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/vc11strm.cxx b/cint/cint/src/dict/vc11strm.cxx new file mode 100644 index 0000000000000..a3e3eca2729f1 --- /dev/null +++ b/cint/cint/src/dict/vc11strm.cxx @@ -0,0 +1,4288 @@ +/******************************************************** +* vc11strm.cxx +* CAUTION: DON'T CHANGE THIS FILE. THIS FILE IS AUTOMATICALLY GENERATED +* FROM HEADER FILES LISTED IN G__setup_cpp_environmentXXX(). +* CHANGE THOSE HEADER FILES AND REGENERATE THIS FILE. +********************************************************/ +#include "vc11strm.h" //newlink 3678 + +#ifdef G__MEMTEST +#undef malloc +#undef free +#endif + +extern "C" void G__cpp_reset_tagtableG__stream(); + +extern "C" void G__set_cpp_environmentG__stream() { + G__add_ipath("."); + G__add_ipath("..\\..\\include"); + G__add_compiledheader("iostrm.h"); + G__add_compiledheader("fstrm.h"); + G__add_compiledheader("sstrm.h"); + G__cpp_reset_tagtableG__stream(); +} +#include +extern "C" int G__cpp_dllrevG__stream() { return(30051515); } + +/********************************************************* +* Member function Interface Method +*********************************************************/ + +/* mbstate_t */ +// automatic default constructor +static int G__G__stream_1_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + mbstate_t *p; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new mbstate_t[n]; + } else { + p = new((void*) gvp) mbstate_t[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new mbstate_t; + } else { + p = new((void*) gvp) mbstate_t; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_mbstate_t)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic copy constructor +static int G__G__stream_1_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) + +{ + mbstate_t* p; + void* tmp = (void*) G__int(libp->para[0]); + p = new mbstate_t(*(mbstate_t*) tmp); + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_mbstate_t)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef mbstate_t G__Tmbstate_t; +static int G__G__stream_1_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (mbstate_t*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((mbstate_t*) (soff+(sizeof(mbstate_t)*i)))->~G__Tmbstate_t(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (mbstate_t*) soff; + } else { + G__setgvp((long) G__PVOID); + ((mbstate_t*) (soff))->~G__Tmbstate_t(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic assignment operator +static int G__G__stream_1_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + mbstate_t* dest = (mbstate_t*) G__getstructoffset(); + *dest = *(mbstate_t*) libp->para[0].ref; + const mbstate_t& obj = *dest; + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* ios_base */ +static int G__G__stream_2_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((ios_base*) G__getstructoffset())->register_callback((ios_base::event_callback) G__int(libp->para[0]), (int) G__int(libp->para[1])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((const ios_base*) G__getstructoffset())->flags()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((ios_base*) G__getstructoffset())->flags((ios_base::fmtflags) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((ios_base*) G__getstructoffset())->setf((ios_base::fmtflags) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((ios_base*) G__getstructoffset())->setf((ios_base::fmtflags) G__int(libp->para[0]), (ios_base::fmtflags) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((ios_base*) G__getstructoffset())->unsetf((ios_base::fmtflags) G__int(libp->para[0])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((const ios_base*) G__getstructoffset())->precision()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((ios_base*) G__getstructoffset())->precision((streamsize) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((const ios_base*) G__getstructoffset())->width()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((ios_base*) G__getstructoffset())->width((streamsize) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ios_base::xalloc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const long& obj = ((ios_base*) G__getstructoffset())->iword((int) G__int(libp->para[0])); + result7->ref = (long) (&obj); + G__letint(result7, 'l', (long)obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + void*& obj = ((ios_base*) G__getstructoffset())->pword((int) G__int(libp->para[0])); + result7->ref = (long) (&obj); + G__letint(result7, 'Y', (long)obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_2_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 1: + G__letint(result7, 103, (long) ios_base::sync_with_stdio((bool) G__int(libp->para[0]))); + break; + case 0: + G__letint(result7, 103, (long) ios_base::sync_with_stdio()); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef ios_base G__Tios_base; +static int G__G__stream_2_0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (ios_base*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((ios_base*) (soff+(sizeof(ios_base)*i)))->~G__Tios_base(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (ios_base*) soff; + } else { + G__setgvp((long) G__PVOID); + ((ios_base*) (soff))->~G__Tios_base(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* ios_base::Init */ +static int G__G__stream_8_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ios_base::Init* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + p = 0; + G__genericerror("Error: Array construction with private/protected destructor is illegal"); + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new ios_base::Init; + } else { + p = new((void*) gvp) ios_base::Init; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic copy constructor +static int G__G__stream_8_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) + +{ + ios_base::Init* p; + void* tmp = (void*) G__int(libp->para[0]); + p = new ios_base::Init(*(ios_base::Init*) tmp); + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic assignment operator +static int G__G__stream_8_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ios_base::Init* dest = (ios_base::Init*) G__getstructoffset(); + const ios_base::Init& obj = *dest; + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* char_traits */ +static int G__G__stream_9_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char_traits::assign(*(char_traits::char_type*) G__Charref(&libp->para[0]), *(char_traits::char_type*) G__Charref(&libp->para[1])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) char_traits::to_char_type(*(char_traits::int_type*) G__Intref(&libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) char_traits::to_int_type(*(char_traits::char_type*) G__Charref(&libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) char_traits::eq(*(char_traits::char_type*) G__Charref(&libp->para[0]), *(char_traits::char_type*) G__Charref(&libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) char_traits::lt(*(char_traits::char_type*) G__Charref(&libp->para[0]), *(char_traits::char_type*) G__Charref(&libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) char_traits::compare((const char_traits::char_type*) G__int(libp->para[0]), (const char_traits::char_type*) G__int(libp->para[1]) +, (size_t) G__int(libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 67, (long) char_traits::find((const char_traits::char_type*) G__int(libp->para[0]), (int) G__int(libp->para[1]) +, *(char_traits::char_type*) G__Charref(&libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) char_traits::eq_int_type(*(char_traits::int_type*) G__Intref(&libp->para[0]), *(char_traits::int_type*) G__Intref(&libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) char_traits::eof()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) char_traits::not_eof(*(char_traits::int_type*) G__Intref(&libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 104, (long) char_traits::length((const char_traits::char_type*) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 67, (long) char_traits::copy((char_traits::char_type*) G__int(libp->para[0]), (const char_traits::char_type*) G__int(libp->para[1]) +, (size_t) G__int(libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 67, (long) char_traits::move((char_traits::char_type*) G__int(libp->para[0]), (const char_traits::char_type*) G__int(libp->para[1]) +, (size_t) G__int(libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_9_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 67, (long) char_traits::assign((char_traits::char_type*) G__int(libp->para[0]), (size_t) G__int(libp->para[1]) +, (const char_traits::char_type) G__int(libp->para[2]))); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic default constructor +static int G__G__stream_9_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char_traits *p; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new char_traits[n]; + } else { + p = new((void*) gvp) char_traits[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new char_traits; + } else { + p = new((void*) gvp) char_traits; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic copy constructor +static int G__G__stream_9_0_16(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) + +{ + char_traits* p; + void* tmp = (void*) G__int(libp->para[0]); + p = new char_traits(*(char_traits*) tmp); + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef char_traits G__Tchar_traitslEchargR; +static int G__G__stream_9_0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (char_traits*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((char_traits*) (soff+(sizeof(char_traits)*i)))->~G__Tchar_traitslEchargR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (char_traits*) soff; + } else { + G__setgvp((long) G__PVOID); + ((char_traits*) (soff))->~G__Tchar_traitslEchargR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic assignment operator +static int G__G__stream_9_0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char_traits* dest = (char_traits*) G__getstructoffset(); + const char_traits& obj = *dest; + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_istream > */ +static int G__G__stream_10_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istream >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istream >((basic_streambuf >*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_istream >((basic_streambuf >*) G__int(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_istream >*) G__getstructoffset())->get()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->get((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1]) +, (basic_istream >::char_type) G__int(libp->para[2])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->get((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->get(*(basic_istream >::char_type*) G__Charref(&libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->get(*(basic_istream >::_Mysb*) libp->para[0].ref, (basic_istream >::char_type) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->get(*(basic_istream >::_Mysb*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->getline((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1]) +, (basic_istream >::char_type) G__int(libp->para[2])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->getline((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->ignore((streamsize) G__int(libp->para[0]), (basic_istream >::int_type) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 1: + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->ignore((streamsize) G__int(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + break; + case 0: + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->ignore(); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->read((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((basic_istream >*) G__getstructoffset())->readsome((basic_istream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_istream >*) G__getstructoffset())->peek()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((basic_istream >*) G__getstructoffset())->tellg()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_16(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->seekg((basic_istream >::pos_type) G__int(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_istream >*) G__getstructoffset())->sync()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->seekg((basic_istream >::off_type) G__int(libp->para[0]), (ios_base::seekdir) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_19(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->putback((basic_istream >::char_type) G__int(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_20(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istream >::_Myt& obj = ((basic_istream >*) G__getstructoffset())->unget(); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_10_0_21(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((const basic_istream >*) G__getstructoffset())->gcount()); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_istream > G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_10_0_23(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_istream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_istream >*) (soff+(sizeof(basic_istream >)*i)))->~G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_istream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_istream >*) (soff))->~G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ios > */ +static int G__G__stream_11_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ios >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ios >((basic_streambuf >*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ios >((basic_streambuf >*) G__int(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) ((const basic_ios >*) G__getstructoffset())->fill()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) ((basic_ios >*) G__getstructoffset())->fill((basic_ios >::char_type) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ios >*) G__getstructoffset())->exceptions((ios_base::iostate) G__int(libp->para[0])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((const basic_ios >*) G__getstructoffset())->exceptions()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 1: + ((basic_ios >*) G__getstructoffset())->clear((ios_base::iostate) G__int(libp->para[0])); + G__setnull(result7); + break; + case 0: + ((basic_ios >*) G__getstructoffset())->clear(); + G__setnull(result7); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ios >*) G__getstructoffset())->setstate((ios_base::iostate) G__int(libp->para[0])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((const basic_ios >*) G__getstructoffset())->rdstate()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 89, (long) ((const basic_ios >*) G__getstructoffset())->operator void*()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->operator!()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->good()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->eof()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->fail()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_ios >*) G__getstructoffset())->bad()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ios >& obj = ((basic_ios >*) G__getstructoffset())->copyfmt(*(basic_ios >*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_16(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ios >*) G__getstructoffset())->tie()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_ios >*) G__getstructoffset())->tie((basic_ostream >*) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ios >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_19(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_ios >*) G__getstructoffset())->rdbuf((basic_streambuf >*) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_20(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) ((const basic_ios >*) G__getstructoffset())->narrow((char) G__int(libp->para[0]), (char) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_11_0_21(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 99, (long) ((const basic_ios >*) G__getstructoffset())->widen((char) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ios > G__Tbasic_ioslEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_11_0_26(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ios >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ios >*) (soff+(sizeof(basic_ios >)*i)))->~G__Tbasic_ioslEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ios >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ios >*) (soff))->~G__Tbasic_ioslEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_streambuf > */ +static int G__G__stream_12_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_streambuf >*) G__getstructoffset())->pubsetbuf((basic_streambuf >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 3: + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->pubseekoff((basic_streambuf >::off_type) G__int(libp->para[0]), (ios_base::seekdir) G__int(libp->para[1]) +, (ios_base::openmode) G__int(libp->para[2]))); + break; + case 2: + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->pubseekoff((basic_streambuf >::off_type) G__int(libp->para[0]), (ios_base::seekdir) G__int(libp->para[1]))); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 2: + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->pubseekpos((basic_streambuf >::pos_type) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1]))); + break; + case 1: + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->pubseekpos((basic_streambuf >::pos_type) G__int(libp->para[0]))); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->pubsync()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->in_avail()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->snextc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sbumpc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sgetc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->sgetn((basic_streambuf >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sputbackc((basic_streambuf >::char_type) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sungetc()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 105, (long) ((basic_streambuf >*) G__getstructoffset())->sputc((basic_streambuf >::char_type) G__int(libp->para[0]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_12_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((basic_streambuf >*) G__getstructoffset())->sputn((const basic_streambuf >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_streambuf > G__Tbasic_streambuflEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_12_0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_streambuf >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_streambuf >*) (soff+(sizeof(basic_streambuf >)*i)))->~G__Tbasic_streambuflEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_streambuf >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_streambuf >*) (soff))->~G__Tbasic_streambuflEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ostream > */ +static int G__G__stream_13_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ostream >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostream >((basic_streambuf >*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ostream >((basic_streambuf >*) G__int(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >::_Myt& obj = ((basic_ostream >*) G__getstructoffset())->put((basic_ostream >::char_type) G__int(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >::_Myt& obj = ((basic_ostream >*) G__getstructoffset())->write((const basic_ostream >::char_type*) G__int(libp->para[0]), (streamsize) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >::_Myt& obj = ((basic_ostream >*) G__getstructoffset())->flush(); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >::_Myt& obj = ((basic_ostream >*) G__getstructoffset())->seekp((basic_ostream >::pos_type) G__int(libp->para[0])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostream >::_Myt& obj = ((basic_ostream >*) G__getstructoffset())->seekp((basic_ostream >::off_type) G__int(libp->para[0]), (ios_base::seekdir) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_13_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 108, (long) ((basic_ostream >*) G__getstructoffset())->tellp()); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ostream > G__Tbasic_ostreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_13_0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ostream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ostream >*) (soff+(sizeof(basic_ostream >)*i)))->~G__Tbasic_ostreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ostream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ostream >*) (soff))->~G__Tbasic_ostreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ostream >::sentry */ +static int G__G__stream_14_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ostream >::sentry* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostream >::sentry(*(basic_ostream >*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_ostream >::sentry(*(basic_ostream >*) libp->para[0].ref); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_istream >::sentry */ +static int G__G__stream_15_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istream >::sentry* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istream >::sentry(*(basic_istream >*) libp->para[0].ref, (bool) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_istream >::sentry(*(basic_istream >*) libp->para[0].ref, (bool) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istream >::sentry(*(basic_istream >*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_istream >::sentry(*(basic_istream >*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_istream >::sentry G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +static int G__G__stream_15_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_istream >::sentry*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_istream >::sentry*) (soff+(sizeof(basic_istream >::sentry)*i)))->~G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_istream >::sentry*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_istream >::sentry*) (soff))->~G__Tbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_filebuf > */ +static int G__G__stream_16_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_filebuf >* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_filebuf >[n]; + } else { + p = new((void*) gvp) basic_filebuf >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_filebuf >; + } else { + p = new((void*) gvp) basic_filebuf >; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_16_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((const basic_filebuf >*) G__getstructoffset())->is_open()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_16_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_filebuf >*) G__getstructoffset())->open((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1]))); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_16_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((basic_filebuf >*) G__getstructoffset())->close()); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_filebuf > G__Tbasic_filebuflEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_16_0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_filebuf >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_filebuf >*) (soff+(sizeof(basic_filebuf >)*i)))->~G__Tbasic_filebuflEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_filebuf >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_filebuf >*) (soff))->~G__Tbasic_filebuflEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ifstream > */ +static int G__G__stream_17_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ifstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ifstream >[n]; + } else { + p = new((void*) gvp) basic_ifstream >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ifstream >; + } else { + p = new((void*) gvp) basic_ifstream >; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_17_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ifstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ifstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_ifstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ifstream >((const char*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ifstream >((const char*) G__int(libp->para[0])); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_17_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ifstream >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_17_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((basic_ifstream >*) G__getstructoffset())->is_open()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_17_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 2: + ((basic_ifstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + G__setnull(result7); + break; + case 1: + ((basic_ifstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0])); + G__setnull(result7); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_17_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ifstream >*) G__getstructoffset())->close(); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ifstream > G__Tbasic_ifstreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_17_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ifstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ifstream >*) (soff+(sizeof(basic_ifstream >)*i)))->~G__Tbasic_ifstreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ifstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ifstream >*) (soff))->~G__Tbasic_ifstreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ofstream > */ +static int G__G__stream_18_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ofstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ofstream >[n]; + } else { + p = new((void*) gvp) basic_ofstream >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ofstream >; + } else { + p = new((void*) gvp) basic_ofstream >; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ofstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ofstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_ofstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ofstream >((const char*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ofstream >((const char*) G__int(libp->para[0])); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ofstream >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((basic_ofstream >*) G__getstructoffset())->is_open()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + switch (libp->paran) { + case 2: + ((basic_ofstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + G__setnull(result7); + break; + case 1: + ((basic_ofstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0])); + G__setnull(result7); + break; + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_18_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ofstream >*) G__getstructoffset())->close(); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ofstream > G__Tbasic_ofstreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_18_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ofstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ofstream >*) (soff+(sizeof(basic_ofstream >)*i)))->~G__Tbasic_ofstreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ofstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ofstream >*) (soff))->~G__Tbasic_ofstreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_fstream > */ +static int G__G__stream_19_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_fstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_fstream >[n]; + } else { + p = new((void*) gvp) basic_fstream >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_fstream >; + } else { + p = new((void*) gvp) basic_fstream >; + } + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_fstream >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_fstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_fstream >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_fstream >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 103, (long) ((basic_fstream >*) G__getstructoffset())->is_open()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_fstream >*) G__getstructoffset())->open((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_19_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_fstream >*) G__getstructoffset())->close(); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_fstream > G__Tbasic_fstreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_19_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_fstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_fstream >*) (soff+(sizeof(basic_fstream >)*i)))->~G__Tbasic_fstreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_fstream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_fstream >*) (soff))->~G__Tbasic_fstreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_iostream > */ +static int G__G__stream_20_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_iostream >* p = NULL; + char* gvp = (char*) G__getgvp(); + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_iostream >((basic_streambuf >*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_iostream >((basic_streambuf >*) G__int(libp->para[0])); + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_iostream > G__Tbasic_iostreamlEcharcOchar_traitslEchargRsPgR; +static int G__G__stream_20_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_iostream >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_iostream >*) (soff+(sizeof(basic_iostream >)*i)))->~G__Tbasic_iostreamlEcharcOchar_traitslEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_iostream >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_iostream >*) (soff))->~G__Tbasic_iostreamlEcharcOchar_traitslEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_stringbuf,allocator > */ +static int G__G__stream_23_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_stringbuf,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >((ios_base::openmode) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_stringbuf,allocator >((ios_base::openmode) G__int(libp->para[0])); + } + break; + case 0: + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >[n]; + } else { + p = new((void*) gvp) basic_stringbuf,allocator >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >; + } else { + p = new((void*) gvp) basic_stringbuf,allocator >; + } + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_23_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_stringbuf,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >(*(basic_stringbuf,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_stringbuf,allocator >(*(basic_stringbuf,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringbuf,allocator >(*(basic_stringbuf,allocator >::_Mystr*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_stringbuf,allocator >(*(basic_stringbuf,allocator >::_Mystr*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_23_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_stringbuf,allocator >::_Mystr* pobj; + const basic_stringbuf,allocator >::_Mystr xobj = ((const basic_stringbuf,allocator >*) G__getstructoffset())->str(); + pobj = new basic_stringbuf,allocator >::_Mystr(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_23_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_stringbuf,allocator >*) G__getstructoffset())->str(*(basic_stringbuf,allocator >::_Mystr*) libp->para[0].ref); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_stringbuf,allocator > G__Tbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +static int G__G__stream_23_0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_stringbuf,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_stringbuf,allocator >*) (soff+(sizeof(basic_stringbuf,allocator >)*i)))->~G__Tbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_stringbuf,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_stringbuf,allocator >*) (soff))->~G__Tbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_istringstream,allocator > */ +static int G__G__stream_25_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_istringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } + break; + case 0: + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >[n]; + } else { + p = new((void*) gvp) basic_istringstream,allocator >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >; + } else { + p = new((void*) gvp) basic_istringstream,allocator >; + } + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_25_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >(*(basic_istringstream,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_istringstream,allocator >(*(basic_istringstream,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >(*(basic_istringstream,allocator >::_Mystr*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_istringstream,allocator >(*(basic_istringstream,allocator >::_Mystr*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_25_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_istringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_istringstream,allocator >((const char*) G__int(libp->para[0]), (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_istringstream,allocator >((const char*) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_istringstream,allocator >((const char*) G__int(libp->para[0])); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_25_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_istringstream,allocator >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_25_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_istringstream,allocator >::_Mystr* pobj; + const basic_istringstream,allocator >::_Mystr xobj = ((const basic_istringstream,allocator >*) G__getstructoffset())->str(); + pobj = new basic_istringstream,allocator >::_Mystr(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_25_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_istringstream,allocator >*) G__getstructoffset())->str(*(basic_istringstream,allocator >::_Mystr*) libp->para[0].ref); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_istringstream,allocator > G__Tbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +static int G__G__stream_25_0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_istringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_istringstream,allocator >*) (soff+(sizeof(basic_istringstream,allocator >)*i)))->~G__Tbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_istringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_istringstream,allocator >*) (soff))->~G__Tbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_ostringstream,allocator > */ +static int G__G__stream_26_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ostringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_ostringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } + break; + case 0: + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >[n]; + } else { + p = new((void*) gvp) basic_ostringstream,allocator >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >; + } else { + p = new((void*) gvp) basic_ostringstream,allocator >; + } + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_26_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_ostringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >(*(basic_ostringstream,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_ostringstream,allocator >(*(basic_ostringstream,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_ostringstream,allocator >(*(basic_ostringstream,allocator >::_Mystr*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_ostringstream,allocator >(*(basic_ostringstream,allocator >::_Mystr*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_26_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_ostringstream,allocator >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_26_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_ostringstream,allocator >::_Mystr* pobj; + const basic_ostringstream,allocator >::_Mystr xobj = ((const basic_ostringstream,allocator >*) G__getstructoffset())->str(); + pobj = new basic_ostringstream,allocator >::_Mystr(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_26_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_ostringstream,allocator >*) G__getstructoffset())->str(*(basic_ostringstream,allocator >::_Mystr*) libp->para[0].ref); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_ostringstream,allocator > G__Tbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +static int G__G__stream_26_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_ostringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_ostringstream,allocator >*) (soff+(sizeof(basic_ostringstream,allocator >)*i)))->~G__Tbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_ostringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_ostringstream,allocator >*) (soff))->~G__Tbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* basic_stringstream,allocator > */ +static int G__G__stream_27_0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_stringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } else { + p = new((void*) gvp) basic_stringstream,allocator >((ios_base::openmode) G__int(libp->para[0])); + } + break; + case 0: + int n = G__getaryconstruct(); + if (n) { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >[n]; + } else { + p = new((void*) gvp) basic_stringstream,allocator >[n]; + } + } else { + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >; + } else { + p = new((void*) gvp) basic_stringstream,allocator >; + } + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_27_0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + basic_stringstream,allocator >* p = NULL; + char* gvp = (char*) G__getgvp(); + switch (libp->paran) { + case 2: + //m: 2 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >(*(basic_stringstream,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } else { + p = new((void*) gvp) basic_stringstream,allocator >(*(basic_stringstream,allocator >::_Mystr*) libp->para[0].ref, (ios_base::openmode) G__int(libp->para[1])); + } + break; + case 1: + //m: 1 + if ((gvp == (char*)G__PVOID) || (gvp == 0)) { + p = new basic_stringstream,allocator >(*(basic_stringstream,allocator >::_Mystr*) libp->para[0].ref); + } else { + p = new((void*) gvp) basic_stringstream,allocator >(*(basic_stringstream,allocator >::_Mystr*) libp->para[0].ref); + } + break; + } + result7->obj.i = (long) p; + result7->ref = (long) p; + G__set_tagnum(result7,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_27_0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + G__letint(result7, 85, (long) ((const basic_stringstream,allocator >*) G__getstructoffset())->rdbuf()); + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_27_0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const basic_stringstream,allocator >::_Mystr* pobj; + const basic_stringstream,allocator >::_Mystr xobj = ((const basic_stringstream,allocator >*) G__getstructoffset())->str(); + pobj = new basic_stringstream,allocator >::_Mystr(xobj); + result7->obj.i = (long) ((void*) pobj); + result7->ref = result7->obj.i; + G__store_tempobject(*result7); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream_27_0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + ((basic_stringstream,allocator >*) G__getstructoffset())->str(*(basic_stringstream,allocator >::_Mystr*) libp->para[0].ref); + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + +// automatic destructor +typedef basic_stringstream,allocator > G__Tbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +static int G__G__stream_27_0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + char* gvp = (char*) G__getgvp(); + long soff = G__getstructoffset(); + int n = G__getaryconstruct(); + // + //has_a_delete: 0 + //has_own_delete1arg: 0 + //has_own_delete2arg: 0 + // + if (!soff) { + return(1); + } + if (n) { + if (gvp == (char*)G__PVOID) { + delete[] (basic_stringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + for (int i = n - 1; i >= 0; --i) { + ((basic_stringstream,allocator >*) (soff+(sizeof(basic_stringstream,allocator >)*i)))->~G__Tbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + } + G__setgvp((long)gvp); + } + } else { + if (gvp == (char*)G__PVOID) { + delete (basic_stringstream,allocator >*) soff; + } else { + G__setgvp((long) G__PVOID); + ((basic_stringstream,allocator >*) (soff))->~G__Tbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(); + G__setgvp((long)gvp); + } + } + G__setnull(result7); + return(1 || funcname || hash || result7 || libp) ; +} + + +/* Setting up global function */ +static int G__G__stream__0_0(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = dec(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_1(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = hex(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_2(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = oct(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_3(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = fixed(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_4(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = scientific(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_5(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = right(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_6(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = left(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_7(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = internal(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_8(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = nouppercase(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_9(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = uppercase(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_10(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noskipws(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_11(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = skipws(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_12(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noshowpos(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_13(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = showpos(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_14(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noshowpoint(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_15(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = showpoint(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_16(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noshowbase(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_17(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = showbase(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_18(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = noboolalpha(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_19(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ios_base& obj = boolalpha(*(ios_base*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_20(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = ws(*(istream*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_21(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = endl(*(ostream*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_22(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = ends(*(ostream*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_23(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = flush(*(ostream*) libp->para[0].ref); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_24(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (char) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_25(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (char*) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_26(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (void*) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_27(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (unsigned char) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_28(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (short) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_29(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (unsigned short) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_30(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (int) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_31(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (unsigned int) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_32(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (long) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_33(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (unsigned long) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_34(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (float) G__double(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_35(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (double) G__double(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_36(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const ostream& obj = operator<<(*(ostream*) libp->para[0].ref, (bool) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_37(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(char*) G__Charref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_38(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(unsigned char*) G__UCharref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_39(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(short*) G__Shortref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_40(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(unsigned short*) G__UShortref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_41(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(int*) G__Intref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_42(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(unsigned int*) G__UIntref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_43(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(long*) G__Longref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_44(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(unsigned long*) G__ULongref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_45(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(float*) G__Floatref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_46(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(double*) G__Doubleref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_47(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, *(bool*) G__Boolref(&libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_48(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, (char*) G__int(libp->para[1])); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + +static int G__G__stream__0_49(G__value* result7, G__CONST char* funcname, struct G__param* libp, int hash) +{ + { + const istream& obj = operator>>(*(istream*) libp->para[0].ref, libp->para[1].ref ? *(void**) libp->para[1].ref : *(void**) (void*) (&G__Mlong(libp->para[1]))); + result7->ref = (long) (&obj); + result7->obj.i = (long) (&obj); + } + return(1 || funcname || hash || result7 || libp) ; +} + + +/********************************************************* +* Member function Stub +*********************************************************/ + +/* mbstate_t */ + +/* ios_base */ + +/* ios_base::Init */ + +/* char_traits */ + +/* basic_istream > */ + +/* basic_ios > */ + +/* basic_streambuf > */ + +/* basic_ostream > */ + +/* basic_ostream >::sentry */ + +/* basic_istream >::sentry */ + +/* basic_filebuf > */ + +/* basic_ifstream > */ + +/* basic_ofstream > */ + +/* basic_fstream > */ + +/* basic_iostream > */ + +/* basic_stringbuf,allocator > */ + +/* basic_istringstream,allocator > */ + +/* basic_ostringstream,allocator > */ + +/* basic_stringstream,allocator > */ + +/********************************************************* +* Global function Stub +*********************************************************/ + +/********************************************************* +* Get size of pointer to member function +*********************************************************/ +class G__Sizep2memfuncG__stream { + public: + G__Sizep2memfuncG__stream(): p(&G__Sizep2memfuncG__stream::sizep2memfunc) {} + size_t sizep2memfunc() { return(sizeof(p)); } + private: + size_t (G__Sizep2memfuncG__stream::*p)(); +}; + +size_t G__get_sizep2memfuncG__stream() +{ + G__Sizep2memfuncG__stream a; + G__setsizep2memfunc((int)a.sizep2memfunc()); + return((size_t)a.sizep2memfunc()); +} + + +/********************************************************* +* virtual base class offset calculation interface +*********************************************************/ + + /* Setting up class inheritance */ +static long G__2vbo_basic_istreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_0(long pobject) { + basic_istream > *G__Lderived=(basic_istream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_istreamlEcharcOchar_traitslEchargRsPgR_ios_base_1(long pobject) { + basic_istream > *G__Lderived=(basic_istream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_0(long pobject) { + basic_ostream > *G__Lderived=(basic_ostream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ostreamlEcharcOchar_traitslEchargRsPgR_ios_base_1(long pobject) { + basic_ostream > *G__Lderived=(basic_ostream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ifstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_ifstream > *G__Lderived=(basic_ifstream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ifstreamlEcharcOchar_traitslEchargRsPgR_ios_base_2(long pobject) { + basic_ifstream > *G__Lderived=(basic_ifstream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ofstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_ofstream > *G__Lderived=(basic_ofstream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ofstreamlEcharcOchar_traitslEchargRsPgR_ios_base_2(long pobject) { + basic_ofstream > *G__Lderived=(basic_ofstream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_2(long pobject) { + basic_fstream > *G__Lderived=(basic_fstream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_ios_base_3(long pobject) { + basic_fstream > *G__Lderived=(basic_fstream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_5(long pobject) { + basic_fstream > *G__Lderived=(basic_fstream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_ios_base_6(long pobject) { + basic_fstream > *G__Lderived=(basic_fstream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_iostream > *G__Lderived=(basic_iostream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_ios_base_2(long pobject) { + basic_iostream > *G__Lderived=(basic_iostream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_4(long pobject) { + basic_iostream > *G__Lderived=(basic_iostream >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_ios_base_5(long pobject) { + basic_iostream > *G__Lderived=(basic_iostream >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_istringstream,allocator > *G__Lderived=(basic_istringstream,allocator >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_2(long pobject) { + basic_istringstream,allocator > *G__Lderived=(basic_istringstream,allocator >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1(long pobject) { + basic_ostringstream,allocator > *G__Lderived=(basic_ostringstream,allocator >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_2(long pobject) { + basic_ostringstream,allocator > *G__Lderived=(basic_ostringstream,allocator >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_2(long pobject) { + basic_stringstream,allocator > *G__Lderived=(basic_stringstream,allocator >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_3(long pobject) { + basic_stringstream,allocator > *G__Lderived=(basic_stringstream,allocator >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_5(long pobject) { + basic_stringstream,allocator > *G__Lderived=(basic_stringstream,allocator >*)pobject; + basic_ios > *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + +static long G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_6(long pobject) { + basic_stringstream,allocator > *G__Lderived=(basic_stringstream,allocator >*)pobject; + ios_base *G__Lbase=G__Lderived; + return((long)G__Lbase-(long)G__Lderived); +} + + +/********************************************************* +* Inheritance information setup/ +*********************************************************/ +extern "C" void G__cpp_setup_inheritanceG__stream() { + + /* Setting up class inheritance */ + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR))) { + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_istreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_0,1,3); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_istreamlEcharcOchar_traitslEchargRsPgR_ios_base_1,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR))) { + basic_ios > *G__Lderived; + G__Lderived=(basic_ios >*)0x1000; + { + ios_base *G__Lpbase=(ios_base*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__Lpbase-(long)G__Lderived,1,1); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR))) { + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_ostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_0,1,3); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_ostreamlEcharcOchar_traitslEchargRsPgR_ios_base_1,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR))) { + basic_filebuf > *G__Lderived; + G__Lderived=(basic_filebuf >*)0x1000; + { + basic_streambuf > *G__Lpbase=(basic_streambuf >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR))) { + basic_ifstream > *G__Lderived; + G__Lderived=(basic_ifstream >*)0x1000; + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_ifstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_ifstreamlEcharcOchar_traitslEchargRsPgR_ios_base_2,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR))) { + basic_ofstream > *G__Lderived; + G__Lderived=(basic_ofstream >*)0x1000; + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_ofstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_ofstreamlEcharcOchar_traitslEchargRsPgR_ios_base_2,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR))) { + basic_fstream > *G__Lderived; + G__Lderived=(basic_fstream >*)0x1000; + { + basic_iostream > *G__Lpbase=(basic_iostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,0); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_2,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_ios_base_3,1,6); + } + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,0); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_5,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_fstreamlEcharcOchar_traitslEchargRsPgR_ios_base_6,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR))) { + basic_iostream > *G__Lderived; + G__Lderived=(basic_iostream >*)0x1000; + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_ios_base_2,1,6); + } + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_4,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_iostreamlEcharcOchar_traitslEchargRsPgR_ios_base_5,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR))) { + basic_stringbuf,allocator > *G__Lderived; + G__Lderived=(basic_stringbuf,allocator >*)0x1000; + { + basic_streambuf > *G__Lpbase=(basic_streambuf >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR))) { + basic_istringstream,allocator > *G__Lderived; + G__Lderived=(basic_istringstream,allocator >*)0x1000; + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_2,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR))) { + basic_ostringstream,allocator > *G__Lderived; + G__Lderived=(basic_ostringstream,allocator >*)0x1000; + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_1,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_2,1,6); + } + } + if(0==G__getnumbaseclass(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR))) { + basic_stringstream,allocator > *G__Lderived; + G__Lderived=(basic_stringstream,allocator >*)0x1000; + { + basic_iostream > *G__Lpbase=(basic_iostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,1); + } + { + basic_istream > *G__Lpbase=(basic_istream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,0); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_2,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_3,1,6); + } + { + basic_ostream > *G__Lpbase=(basic_ostream >*)G__Lderived; + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),(long)G__Lpbase-(long)G__Lderived,1,0); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),(long)G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_basic_ioslEcharcOchar_traitslEchargRsPgR_5,1,2); + } + { + G__inheritance_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),G__get_linked_tagnum(&G__G__streamLN_ios_base),(long)G__2vbo_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR_ios_base_6,1,6); + } + } +} + +/********************************************************* +* typedef information setup/ +*********************************************************/ +extern "C" void G__cpp_setup_typetableG__stream() { + + /* Setting up typedef entry */ + G__search_typename2("FILE",101,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("mbstate_t",117,G__get_linked_tagnum(&G__G__streamLN_mbstate_t),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("streampos",108,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("streamoff",108,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("SZ_T",108,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("streamsize",108,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("iostate",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,NULL,0); + G__search_typename2("openmode",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,NULL,0); + G__search_typename2("seekdir",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,NULL,0); + G__search_typename2("fmtflags",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,NULL,0); + G__search_typename2("event_callback",89,-1,0,G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__setnewtype(-1,"void (*event_callback) (event, ios_base&, int index);",0); + G__search_typename2("INT_T",105,-1,0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("state_type",117,G__get_linked_tagnum(&G__G__streamLN_mbstate_t),0,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("basic_streambuf >",117,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Myt",117,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Myios",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Myt",117,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Myios",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Mysb",117,G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("istream",117,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("ostream",117,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("filebuf",117,G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ifstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ofstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("fstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Mystr",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("stringbuf",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("sb_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Mystr",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("istringstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("sb_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Mystr",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ostringstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); + G__search_typename2("char_type",99,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("int_type",105,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("pos_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("off_type",108,-1,0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("traits_type",117,G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("sb_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("ios_type",117,G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("_Mystr",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__setnewtype(-1,NULL,0); + G__search_typename2("stringstream",117,G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),0,-1); + G__setnewtype(-1,NULL,0); +} + +/********************************************************* +* Data Member information setup/ +*********************************************************/ + + /* Setting up class,struct,union tag member variable */ + + /* mbstate_t */ +static void G__setup_memvarmbstate_t(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_mbstate_t)); + { mbstate_t *p; p=(mbstate_t*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* ios_base */ +static void G__setup_memvarios_base(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_ios_base)); + { ios_base *p; p=(ios_base*)0x1000; if (p) { } + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLio_state),-1,-2,1,G__FastAllocString(2048).Format("goodbit=%lldLL",(long long)ios_base::goodbit).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLio_state),-1,-2,1,G__FastAllocString(2048).Format("badbit=%lldLL",(long long)ios_base::badbit).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLio_state),-1,-2,1,G__FastAllocString(2048).Format("eofbit=%lldLL",(long long)ios_base::eofbit).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLio_state),-1,-2,1,G__FastAllocString(2048).Format("failbit=%lldLL",(long long)ios_base::failbit).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("app=%lldLL",(long long)ios_base::app).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("binary=%lldLL",(long long)ios_base::binary).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("in=%lldLL",(long long)ios_base::in).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("out=%lldLL",(long long)ios_base::out).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("trunc=%lldLL",(long long)ios_base::trunc).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLopen_mode),-1,-2,1,G__FastAllocString(2048).Format("ate=%lldLL",(long long)ios_base::ate).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLseek_dir),-1,-2,1,G__FastAllocString(2048).Format("beg=%lldLL",(long long)ios_base::beg).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLseek_dir),-1,-2,1,G__FastAllocString(2048).Format("cur=%lldLL",(long long)ios_base::cur).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLseek_dir),-1,-2,1,G__FastAllocString(2048).Format("end=%lldLL",(long long)ios_base::end).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("boolalpha=%lldLL",(long long)ios_base::boolalpha).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("dec=%lldLL",(long long)ios_base::dec).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("fixed=%lldLL",(long long)ios_base::fixed).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("hex=%lldLL",(long long)ios_base::hex).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("internal=%lldLL",(long long)ios_base::internal).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("left=%lldLL",(long long)ios_base::left).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("oct=%lldLL",(long long)ios_base::oct).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("right=%lldLL",(long long)ios_base::right).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("scientific=%lldLL",(long long)ios_base::scientific).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("showbase=%lldLL",(long long)ios_base::showbase).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("showpoint=%lldLL",(long long)ios_base::showpoint).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("showpos=%lldLL",(long long)ios_base::showpos).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("skipws=%lldLL",(long long)ios_base::skipws).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("unitbuf=%lldLL",(long long)ios_base::unitbuf).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("uppercase=%lldLL",(long long)ios_base::uppercase).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("adjustfield=%lldLL",(long long)ios_base::adjustfield).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("basefield=%lldLL",(long long)ios_base::basefield).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLfmt_flags),-1,-2,1,G__FastAllocString(2048).Format("floatfield=%lldLL",(long long)ios_base::floatfield).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLevent),-1,-2,1,G__FastAllocString(2048).Format("erase_event=%lldLL",(long long)ios_base::erase_event).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLevent),-1,-2,1,G__FastAllocString(2048).Format("imbue_event=%lldLL",(long long)ios_base::imbue_event).data(),0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,105,0,1,G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLevent),-1,-2,1,G__FastAllocString(2048).Format("copyfmt_event=%lldLL",(long long)ios_base::copyfmt_event).data(),0,(char*)NULL); + } + G__tag_memvar_reset(); +} + + + /* ios_base::Init */ +static void G__setup_memvarios_basecLcLInit(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit)); + { ios_base::Init *p; p=(ios_base::Init*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* char_traits */ +static void G__setup_memvarchar_traitslEchargR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + { char_traits *p; p=(char_traits*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_istream > */ +static void G__setup_memvarbasic_istreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + { basic_istream > *p; p=(basic_istream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ios > */ +static void G__setup_memvarbasic_ioslEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + { basic_ios > *p; p=(basic_ios >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_streambuf > */ +static void G__setup_memvarbasic_streambuflEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + { basic_streambuf > *p; p=(basic_streambuf >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ostream > */ +static void G__setup_memvarbasic_ostreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + { basic_ostream > *p; p=(basic_ostream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ostream >::sentry */ +static void G__setup_memvarbasic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + { basic_ostream >::sentry *p; p=(basic_ostream >::sentry*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_istream >::sentry */ +static void G__setup_memvarbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + { basic_istream >::sentry *p; p=(basic_istream >::sentry*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_filebuf > */ +static void G__setup_memvarbasic_filebuflEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + { basic_filebuf > *p; p=(basic_filebuf >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ifstream > */ +static void G__setup_memvarbasic_ifstreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + { basic_ifstream > *p; p=(basic_ifstream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ofstream > */ +static void G__setup_memvarbasic_ofstreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + { basic_ofstream > *p; p=(basic_ofstream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_fstream > */ +static void G__setup_memvarbasic_fstreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR)); + { basic_fstream > *p; p=(basic_fstream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_iostream > */ +static void G__setup_memvarbasic_iostreamlEcharcOchar_traitslEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR)); + { basic_iostream > *p; p=(basic_iostream >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_stringbuf,allocator > */ +static void G__setup_memvarbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + { basic_stringbuf,allocator > *p; p=(basic_stringbuf,allocator >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_istringstream,allocator > */ +static void G__setup_memvarbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + { basic_istringstream,allocator > *p; p=(basic_istringstream,allocator >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_ostringstream,allocator > */ +static void G__setup_memvarbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + { basic_ostringstream,allocator > *p; p=(basic_ostringstream,allocator >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + + + /* basic_stringstream,allocator > */ +static void G__setup_memvarbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + G__tag_memvar_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + { basic_stringstream,allocator > *p; p=(basic_stringstream,allocator >*)0x1000; if (p) { } + } + G__tag_memvar_reset(); +} + +extern "C" void G__cpp_setup_memvarG__stream() { +} +/*********************************************************** +************************************************************ +************************************************************ +************************************************************ +************************************************************ +************************************************************ +************************************************************ +***********************************************************/ + +/********************************************************* +* Member function information setup for each class +*********************************************************/ +static void G__setup_memfuncmbstate_t(void) { + /* mbstate_t */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_mbstate_t)); + // automatic default constructor + G__memfunc_setup("mbstate_t", 963, G__G__stream_1_0_1, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_mbstate_t), -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic copy constructor + G__memfunc_setup("mbstate_t", 963, G__G__stream_1_0_2, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_mbstate_t), -1, 0, 1, 1, 1, 0, "u 'mbstate_t' - 11 - -", (char*) NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~mbstate_t", 1089, G__G__stream_1_0_3, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic assignment operator + G__memfunc_setup("operator=", 937, G__G__stream_1_0_4, (int) ('u'), G__get_linked_tagnum(&G__G__streamLN_mbstate_t), -1, 1, 1, 1, 1, 0, "u 'mbstate_t' - 11 - -", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncios_base(void) { + /* ios_base */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_ios_base)); + G__memfunc_setup("register_callback",1777,G__G__stream_2_0_1, 121, -1, -1, 0, 2, 1, 1, 0, +"Y - 'ios_base::event_callback' 0 - fn i - - 0 - index", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("flags",525,G__G__stream_2_0_2, 105, -1, G__defined_typename("ios_base::fmtflags"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("flags",525,G__G__stream_2_0_3, 105, -1, G__defined_typename("ios_base::fmtflags"), 0, 1, 1, 1, 0, "i - 'ios_base::fmtflags' 0 - fmtfl", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("setf",434,G__G__stream_2_0_4, 105, -1, G__defined_typename("ios_base::fmtflags"), 0, 1, 1, 1, 0, "i - 'ios_base::fmtflags' 0 - fmtfl", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("setf",434,G__G__stream_2_0_5, 105, -1, G__defined_typename("ios_base::fmtflags"), 0, 2, 1, 1, 0, +"i - 'ios_base::fmtflags' 0 - fmtfl i - 'ios_base::fmtflags' 0 - mask", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("unsetf",661,G__G__stream_2_0_6, 121, -1, -1, 0, 1, 1, 1, 0, "i - 'ios_base::fmtflags' 0 - mask", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("precision",972,G__G__stream_2_0_7, 108, -1, G__defined_typename("streamsize"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("precision",972,G__G__stream_2_0_8, 108, -1, G__defined_typename("streamsize"), 0, 1, 1, 1, 0, "l - 'streamsize' 0 - prec", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("width",544,G__G__stream_2_0_9, 108, -1, G__defined_typename("streamsize"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("width",544,G__G__stream_2_0_10, 108, -1, G__defined_typename("streamsize"), 0, 1, 1, 1, 0, "l - 'streamsize' 0 - wide", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("xalloc",643,G__G__stream_2_0_11, 105, -1, -1, 0, 0, 3, 1, 0, "", (char*)NULL, (void*) G__func2void( (int (*)())(&ios_base::xalloc) ), 0); + G__memfunc_setup("iword",549,G__G__stream_2_0_12, 108, -1, -1, 1, 1, 1, 1, 0, "i - - 0 - index", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pword",556,G__G__stream_2_0_13, 89, -1, -1, 1, 1, 1, 1, 0, "i - - 0 - index", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sync_with_stdio",1626,G__G__stream_2_0_14, 103, -1, -1, 0, 1, 3, 1, 0, "g - - 0 'true' sync", (char*)NULL, (void*) G__func2void( (bool (*)(bool))(&ios_base::sync_with_stdio) ), 0); + G__memfunc_setup("ios_base",837,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 2, 0, "u 'ios_base' - 11 - x", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("ios_base",837,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 0, 1, 1, 4, 0, "u 'ios_base' - 11 - -", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~ios_base", 963, G__G__stream_2_0_18, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncios_basecLcLInit(void) { + /* ios_base::Init */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit)); + G__memfunc_setup("Init",404,G__G__stream_8_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic copy constructor + G__memfunc_setup("Init", 404, G__G__stream_8_0_2, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit), -1, 0, 1, 1, 1, 0, "u 'ios_base::Init' - 11 - -", (char*) NULL, (void*) NULL, 0); + // automatic assignment operator + G__memfunc_setup("operator=", 937, G__G__stream_8_0_3, (int) ('u'), G__get_linked_tagnum(&G__G__streamLN_ios_basecLcLInit), -1, 1, 1, 1, 1, 0, "u 'ios_base::Init' - 11 - -", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncchar_traitslEchargR(void) { + /* char_traits */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR)); + G__memfunc_setup("assign",645,G__G__stream_9_0_1, 121, -1, -1, 0, 2, 3, 1, 0, +"c - 'char_traits::char_type' 1 - c1 c - 'char_traits::char_type' 11 - c2", (char*)NULL, (void*) G__func2void( (void (*)(char_traits::char_type&, const char_traits::char_type&))(&char_traits::assign) ), 0); + G__memfunc_setup("to_char_type",1281,G__G__stream_9_0_2, 99, -1, G__defined_typename("char_traits::char_type"), 0, 1, 3, 1, 0, "i - 'char_traits::int_type' 11 - c", (char*)NULL, (void*) G__func2void( (char_traits::char_type (*)(const char_traits::int_type&))(&char_traits::to_char_type) ), 0); + G__memfunc_setup("to_int_type",1198,G__G__stream_9_0_3, 105, -1, G__defined_typename("char_traits::int_type"), 0, 1, 3, 1, 0, "c - 'char_traits::char_type' 11 - c", (char*)NULL, (void*) G__func2void( (char_traits::int_type (*)(const char_traits::char_type&))(&char_traits::to_int_type) ), 0); + G__memfunc_setup("eq",214,G__G__stream_9_0_4, 103, -1, -1, 0, 2, 3, 1, 0, +"c - 'char_traits::char_type' 11 - c1 c - 'char_traits::char_type' 11 - c2", (char*)NULL, (void*) G__func2void( (bool (*)(const char_traits::char_type&, const char_traits::char_type&))(&char_traits::eq) ), 0); + G__memfunc_setup("lt",224,G__G__stream_9_0_5, 103, -1, -1, 0, 2, 3, 1, 0, +"c - 'char_traits::char_type' 11 - c1 c - 'char_traits::char_type' 11 - c2", (char*)NULL, (void*) G__func2void( (bool (*)(const char_traits::char_type&, const char_traits::char_type&))(&char_traits::lt) ), 0); + G__memfunc_setup("compare",743,G__G__stream_9_0_6, 105, -1, -1, 0, 3, 3, 1, 0, +"C - 'char_traits::char_type' 10 - s1 C - 'char_traits::char_type' 10 - s2 " +"h - 'size_t' 0 - n", (char*)NULL, (void*) G__func2void( (int (*)(const char_traits::char_type*, const char_traits::char_type*, size_t))(&char_traits::compare) ), 0); + G__memfunc_setup("find",417,G__G__stream_9_0_7, 67, -1, G__defined_typename("char_traits::char_type"), 0, 3, 3, 1, 1, +"C - 'char_traits::char_type' 10 - s i - - 0 - n " +"c - 'char_traits::char_type' 11 - a", (char*)NULL, (void*) G__func2void( (const char_traits::char_type* (*)(const char_traits::char_type*, int, const char_traits::char_type&))(&char_traits::find) ), 0); + G__memfunc_setup("eq_int_type",1185,G__G__stream_9_0_8, 103, -1, -1, 0, 2, 3, 1, 0, +"i - 'char_traits::int_type' 11 - c1 i - 'char_traits::int_type' 11 - c2", (char*)NULL, (void*) G__func2void( (bool (*)(const char_traits::int_type&, const char_traits::int_type&))(&char_traits::eq_int_type) ), 0); + G__memfunc_setup("eof",314,G__G__stream_9_0_9, 105, -1, G__defined_typename("char_traits::int_type"), 0, 0, 3, 1, 0, "", (char*)NULL, (void*) G__func2void( (char_traits::int_type (*)())(&char_traits::eof) ), 0); + G__memfunc_setup("not_eof",746,G__G__stream_9_0_10, 105, -1, G__defined_typename("char_traits::int_type"), 0, 1, 3, 1, 0, "i - 'char_traits::int_type' 11 - c", (char*)NULL, (void*) G__func2void( (char_traits::int_type (*)(const char_traits::int_type&))(&char_traits::not_eof) ), 0); + G__memfunc_setup("length",642,G__G__stream_9_0_11, 104, -1, G__defined_typename("size_t"), 0, 1, 3, 1, 0, "C - 'char_traits::char_type' 10 - s", (char*)NULL, (void*) G__func2void( (size_t (*)(const char_traits::char_type*))(&char_traits::length) ), 0); + G__memfunc_setup("copy",443,G__G__stream_9_0_12, 67, -1, G__defined_typename("char_traits::char_type"), 0, 3, 3, 1, 0, +"C - 'char_traits::char_type' 0 - dst C - 'char_traits::char_type' 10 - src " +"h - 'size_t' 0 - n", (char*)NULL, (void*) G__func2void( (char_traits::char_type* (*)(char_traits::char_type*, const char_traits::char_type*, size_t))(&char_traits::copy) ), 0); + G__memfunc_setup("move",439,G__G__stream_9_0_13, 67, -1, G__defined_typename("char_traits::char_type"), 0, 3, 3, 1, 0, +"C - 'char_traits::char_type' 0 - s1 C - 'char_traits::char_type' 10 - s2 " +"h - 'size_t' 0 - n", (char*)NULL, (void*) G__func2void( (char_traits::char_type* (*)(char_traits::char_type*, const char_traits::char_type*, size_t))(&char_traits::move) ), 0); + G__memfunc_setup("assign",645,G__G__stream_9_0_14, 67, -1, G__defined_typename("char_traits::char_type"), 0, 3, 3, 1, 0, +"C - 'char_traits::char_type' 0 - s h - 'size_t' 0 - n " +"c - 'char_traits::char_type' 10 - a", (char*)NULL, (void*) NULL, 0); + // automatic default constructor + G__memfunc_setup("char_traits", 1708, G__G__stream_9_0_15, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR), -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic copy constructor + G__memfunc_setup("char_traits", 1708, G__G__stream_9_0_16, (int) ('i'), G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR), -1, 0, 1, 1, 1, 0, "u 'char_traits' - 11 - -", (char*) NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~char_traits", 1834, G__G__stream_9_0_17, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + // automatic assignment operator + G__memfunc_setup("operator=", 937, G__G__stream_9_0_18, (int) ('u'), G__get_linked_tagnum(&G__G__streamLN_char_traitslEchargR), -1, 1, 1, 1, 1, 0, "u 'char_traits' - 11 - -", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_istreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_istream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_istream >",3686,G__G__stream_10_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 5, 1, 0, "U 'basic_streambuf >' - 0 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_10_0_2, 105, -1, G__defined_typename("basic_istream >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_10_0_3, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 3, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s l - 'streamsize' 0 - n " +"c - 'basic_istream >::char_type' 0 - delim", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_10_0_4, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 2, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_10_0_5, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 1, 1, 1, 0, "c - 'basic_istream >::char_type' 1 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_10_0_6, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 2, 1, 1, 0, +"u 'basic_streambuf >' 'basic_istream >::_Mysb' 1 - sb c - 'basic_istream >::char_type' 0 - delim", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("get",320,G__G__stream_10_0_7, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 1, 1, 1, 0, "u 'basic_streambuf >' 'basic_istream >::_Mysb' 1 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("getline",744,G__G__stream_10_0_8, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 3, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s l - 'streamsize' 0 - n " +"c - 'basic_istream >::char_type' 0 - delim", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("getline",744,G__G__stream_10_0_9, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 2, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("ignore",644,G__G__stream_10_0_10, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 2, 1, 1, 0, +"l - 'streamsize' 0 - n i - 'basic_istream >::int_type' 0 - delim", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("ignore",644,G__G__stream_10_0_11, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 1, 1, 1, 0, "l - 'streamsize' 0 '1' n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("read",412,G__G__stream_10_0_12, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 2, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("readsome",848,G__G__stream_10_0_13, 108, -1, G__defined_typename("streamsize"), 0, 2, 1, 1, 0, +"C - 'basic_istream >::char_type' 0 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("peek",421,G__G__stream_10_0_14, 105, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("tellg",536,G__G__stream_10_0_15, 108, -1, G__defined_typename("basic_istream >::pos_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("seekg",527,G__G__stream_10_0_16, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 1, 1, 1, 0, "l - 'basic_istream >::pos_type' 0 - pos", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sync",445,G__G__stream_10_0_17, 105, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("seekg",527,G__G__stream_10_0_18, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 2, 1, 1, 0, +"l - 'basic_istream >::off_type' 0 - - i - 'ios_base::seekdir' 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("putback",746,G__G__stream_10_0_19, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 1, 1, 1, 0, "c - 'basic_istream >::char_type' 0 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("unget",547,G__G__stream_10_0_20, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_istream >::_Myt"), 1, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("gcount",656,G__G__stream_10_0_21, 108, -1, G__defined_typename("streamsize"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_istream >",3686,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_istream >", 3812, G__G__stream_10_0_23, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ioslEcharcOchar_traitslEchargRsPgR(void) { + /* basic_ios > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_ios >",3260,G__G__stream_11_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 5, 1, 0, "U 'basic_streambuf >' - 0 - sb_arg", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("fill",423,G__G__stream_11_0_2, 99, -1, G__defined_typename("basic_ios >::char_type"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("fill",423,G__G__stream_11_0_3, 99, -1, G__defined_typename("basic_ios >::char_type"), 0, 1, 1, 1, 0, "c - 'basic_ios >::char_type' 0 - ch", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("exceptions",1090,G__G__stream_11_0_4, 121, -1, -1, 0, 1, 1, 1, 0, "i - 'ios_base::iostate' 0 - excpt", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("exceptions",1090,G__G__stream_11_0_5, 105, -1, G__defined_typename("ios_base::iostate"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("clear",519,G__G__stream_11_0_6, 121, -1, -1, 0, 1, 1, 1, 0, "i - 'ios_base::iostate' 0 'goodbit' state", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("setstate",877,G__G__stream_11_0_7, 121, -1, -1, 0, 1, 1, 1, 0, "i - 'ios_base::iostate' 0 - state", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdstate",759,G__G__stream_11_0_8, 105, -1, G__defined_typename("ios_base::iostate"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator void*",1384,G__G__stream_11_0_9, 89, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator!",909,G__G__stream_11_0_10, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("good",425,G__G__stream_11_0_11, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("eof",314,G__G__stream_11_0_12, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("fail",412,G__G__stream_11_0_13, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("bad",295,G__G__stream_11_0_14, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("copyfmt",770,G__G__stream_11_0_15, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 1, 0, "u 'basic_ios >' - 11 - rhs", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("tie",322,G__G__stream_11_0_16, 85, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("tie",322,G__G__stream_11_0_17, 85, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 1, 1, 0, "U 'basic_ostream >' - 0 - tie_arg", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_11_0_18, 85, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_11_0_19, 85, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 1, 1, 0, "U 'basic_streambuf >' - 0 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("narrow",665,G__G__stream_11_0_20, 99, -1, -1, 0, 2, 1, 1, 8, +"c - - 0 - - c - - 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("widen",535,G__G__stream_11_0_21, 99, -1, -1, 0, 1, 1, 1, 8, "c - - 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ios >",3260,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ios >",3260,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 1, 4, 0, "u 'basic_ios >' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 4, 0, "u 'basic_ios >' - 11 - -", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ios >", 3386, G__G__stream_11_0_26, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_streambuflEcharcOchar_traitslEchargRsPgR(void) { + /* basic_streambuf > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_streambuf >",3898,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 1, 4, 0, "u 'basic_streambuf >' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 4, 0, "u 'basic_streambuf >' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pubsetbuf",976,G__G__stream_12_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_streambuf >::basic_streambuf >"), 0, 2, 1, 1, 0, +"C - 'basic_streambuf >::char_type' 0 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pubseekoff",1066,G__G__stream_12_0_4, 108, -1, G__defined_typename("basic_streambuf >::pos_type"), 0, 3, 1, 1, 0, +"l - 'basic_streambuf >::off_type' 0 - off i - 'ios_base::seekdir' 0 - way " +"i - 'ios_base::openmode' 0 'ios_base::in|ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pubseekpos",1089,G__G__stream_12_0_5, 108, -1, G__defined_typename("basic_streambuf >::pos_type"), 0, 2, 1, 1, 0, +"l - 'basic_streambuf >::pos_type' 0 - sp i - 'ios_base::openmode' 0 'ios_base::in|ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("pubsync",772,G__G__stream_12_0_6, 105, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("in_avail",835,G__G__stream_12_0_7, 108, -1, G__defined_typename("streamsize"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("snextc",661,G__G__stream_12_0_8, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sbumpc",650,G__G__stream_12_0_9, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sgetc",534,G__G__stream_12_0_10, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sgetn",545,G__G__stream_12_0_11, 108, -1, G__defined_typename("streamsize"), 0, 2, 1, 1, 0, +"C - 'basic_streambuf >::char_type' 0 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sputbackc",960,G__G__stream_12_0_12, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 1, 1, 1, 0, "c - 'basic_streambuf >::char_type' 0 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sungetc",761,G__G__stream_12_0_13, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sputc",559,G__G__stream_12_0_14, 105, -1, G__defined_typename("basic_streambuf >::int_type"), 0, 1, 1, 1, 0, "c - 'basic_streambuf >::char_type' 0 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sputn",570,G__G__stream_12_0_15, 108, -1, G__defined_typename("streamsize"), 0, 2, 1, 1, 0, +"C - 'basic_streambuf >::char_type' 10 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_streambuf >",3898,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_streambuf >", 4024, G__G__stream_12_0_17, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ostreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_ostream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_ostream >",3692,G__G__stream_13_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 5, 1, 0, "U 'basic_streambuf >' - 0 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("put",345,G__G__stream_13_0_2, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_ostream >::_Myt"), 1, 1, 1, 1, 0, "c - 'basic_ostream >::char_type' 0 - c", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("write",555,G__G__stream_13_0_3, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_ostream >::_Myt"), 1, 2, 1, 1, 0, +"C - 'basic_ostream >::char_type' 10 - s l - 'streamsize' 0 - n", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("flush",546,G__G__stream_13_0_4, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_ostream >::_Myt"), 1, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("seekp",536,G__G__stream_13_0_5, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_ostream >::_Myt"), 1, 1, 1, 1, 0, "l - 'basic_ostream >::pos_type' 0 - pos", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("seekp",536,G__G__stream_13_0_6, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("basic_ostream >::_Myt"), 1, 2, 1, 1, 0, +"l - 'basic_ostream >::off_type' 0 - - i - 'ios_base::seekdir' 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("tellp",545,G__G__stream_13_0_7, 108, -1, G__defined_typename("basic_ostream >::pos_type"), 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ostream >",3692,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 2, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ostream >", 3818, G__G__stream_13_0_9, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(void) { + /* basic_ostream >::sentry */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + G__memfunc_setup("sentry",677,G__G__stream_14_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 0, 1, 5, 1, 0, "u 'basic_ostream >' - 1 - stream", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sentry",677,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 0, 1, 1, 4, 0, "u 'basic_ostream >::sentry' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 1, 1, 1, 4, 0, "u 'basic_ostream >::sentry' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry(void) { + /* basic_istream >::sentry */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry)); + G__memfunc_setup("sentry",677,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 0, 1, 1, 4, 0, "u 'basic_istream >::sentry' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 1, 1, 1, 4, 0, "u 'basic_istream >::sentry' - 11 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("sentry",677,G__G__stream_15_0_3, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry), -1, 0, 2, 5, 1, 0, +"u 'basic_istream >' - 1 - stream g - - 0 '0' noskipws", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~sentry", 803, G__G__stream_15_0_4, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_filebuflEcharcOchar_traitslEchargRsPgR(void) { + /* basic_filebuf > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_filebuf >",3662,G__G__stream_16_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("is_open",749,G__G__stream_16_0_2, 103, -1, -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("open",434,G__G__stream_16_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 - -", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("close",534,G__G__stream_16_0_4, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 1, 1, 1, 4, 0, "u 'basic_filebuf >' - 11 - x", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_filebuf >", 3788, G__G__stream_16_0_15, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ifstreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_ifstream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_ifstream >",3788,G__G__stream_17_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ifstream >",3788,G__G__stream_17_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 'ios_base::in' mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_17_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("is_open",749,G__G__stream_17_0_4, 103, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("open",434,G__G__stream_17_0_5, 121, -1, -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 'ios_base::in' mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("close",534,G__G__stream_17_0_6, 121, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ifstream >", 3914, G__G__stream_17_0_7, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ofstreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_ofstream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_ofstream >",3794,G__G__stream_18_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ofstream >",3794,G__G__stream_18_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 'ios_base::out' mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_18_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("is_open",749,G__G__stream_18_0_4, 103, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("open",434,G__G__stream_18_0_5, 121, -1, -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 'ios_base::out' mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("close",534,G__G__stream_18_0_6, 121, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ofstream >", 3920, G__G__stream_18_0_7, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_fstreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_fstream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_fstream >",3683,G__G__stream_19_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_fstream >",3683,G__G__stream_19_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 - mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_19_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("is_open",749,G__G__stream_19_0_4, 103, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("open",434,G__G__stream_19_0_5, 121, -1, -1, 0, 2, 1, 1, 0, +"C - - 10 - s i - 'ios_base::openmode' 0 - mode", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("close",534,G__G__stream_19_0_6, 121, -1, -1, 0, 0, 1, 1, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_fstream >", 3809, G__G__stream_19_0_7, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 0); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_iostreamlEcharcOchar_traitslEchargRsPgR(void) { + /* basic_iostream > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR)); + G__memfunc_setup("basic_iostream >",3797,G__G__stream_20_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 1, 5, 1, 0, "U 'basic_streambuf >' - 0 - sb", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_iostream >",3797,(G__InterfaceMethod) NULL, 105, G__get_linked_tagnum(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR), -1, 0, 0, 5, 2, 0, "", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_iostream >", 3923, G__G__stream_20_0_3, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + /* basic_stringbuf,allocator > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__memfunc_setup("basic_stringbuf,allocator >",5450,G__G__stream_23_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 1, 5, 1, 0, "i - 'ios_base::openmode' 0 'ios_base::in|ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_stringbuf,allocator >",5450,G__G__stream_23_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"u 'basic_string,allocator >' 'basic_stringbuf,allocator >::_Mystr' 11 - str i - 'ios_base::openmode' 0 'ios_base::in|ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_23_0_3, 117, G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), G__defined_typename("basic_stringbuf,allocator >::_Mystr"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_23_0_4, 121, -1, -1, 0, 1, 1, 1, 0, "u 'basic_string,allocator >' 'basic_stringbuf,allocator >::_Mystr' 11 - str_arg", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("operator=",937,(G__InterfaceMethod) NULL, 117, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 1, 1, 1, 4, 0, "u 'basic_stringbuf,allocator >' - 11 - x", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_stringbuf,allocator >", 5576, G__G__stream_23_0_13, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + /* basic_istringstream,allocator > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__memfunc_setup("basic_istringstream,allocator >",5890,G__G__stream_25_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 1, 5, 1, 0, "i - 'ios_base::openmode' 0 'ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_istringstream,allocator >",5890,G__G__stream_25_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"u 'basic_string,allocator >' 'basic_istringstream,allocator >::_Mystr' 11 - str i - 'ios_base::openmode' 0 'ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_istringstream,allocator >",5890,G__G__stream_25_0_3, 105, G__get_linked_tagnum(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"C - - 10 - str i - 'ios_base::openmode' 0 'ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_25_0_4, 85, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_25_0_5, 117, G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), G__defined_typename("basic_istringstream,allocator >::_Mystr"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_25_0_6, 121, -1, -1, 0, 1, 1, 1, 0, "u 'basic_string,allocator >' 'basic_istringstream,allocator >::_Mystr' 11 - str", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_istringstream,allocator >", 6016, G__G__stream_25_0_7, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + /* basic_ostringstream,allocator > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__memfunc_setup("basic_ostringstream,allocator >",5896,G__G__stream_26_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 1, 5, 1, 0, "i - 'ios_base::openmode' 0 'ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_ostringstream,allocator >",5896,G__G__stream_26_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"u 'basic_string,allocator >' 'basic_ostringstream,allocator >::_Mystr' 11 - str i - 'ios_base::openmode' 0 'ios_base::out' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_26_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_26_0_4, 117, G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), G__defined_typename("basic_ostringstream,allocator >::_Mystr"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_26_0_5, 121, -1, -1, 0, 1, 1, 1, 0, "u 'basic_string,allocator >' 'basic_ostringstream,allocator >::_Mystr' 11 - str", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_ostringstream,allocator >", 6022, G__G__stream_26_0_6, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + +static void G__setup_memfuncbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR(void) { + /* basic_stringstream,allocator > */ + G__tag_memfunc_setup(G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR)); + G__memfunc_setup("basic_stringstream,allocator >",5785,G__G__stream_27_0_1, 105, G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 1, 5, 1, 0, "i - 'ios_base::openmode' 0 'ios_base::out|ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("basic_stringstream,allocator >",5785,G__G__stream_27_0_2, 105, G__get_linked_tagnum(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 2, 5, 1, 0, +"u 'basic_string,allocator >' 'basic_stringstream,allocator >::_Mystr' 11 - str i - 'ios_base::openmode' 0 'ios_base::out|ios_base::in' which", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("rdbuf",531,G__G__stream_27_0_3, 85, G__get_linked_tagnum(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), -1, 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_27_0_4, 117, G__get_linked_tagnum(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR), G__defined_typename("basic_stringstream,allocator >::_Mystr"), 0, 0, 1, 1, 8, "", (char*)NULL, (void*) NULL, 0); + G__memfunc_setup("str",345,G__G__stream_27_0_5, 121, -1, -1, 0, 1, 1, 1, 0, "u 'basic_string,allocator >' 'basic_stringstream,allocator >::_Mystr' 11 - str", (char*)NULL, (void*) NULL, 0); + // automatic destructor + G__memfunc_setup("~basic_stringstream,allocator >", 5911, G__G__stream_27_0_6, (int) ('y'), -1, -1, 0, 0, 1, 1, 0, "", (char*) NULL, (void*) NULL, 1); + G__tag_memfunc_reset(); +} + + +/********************************************************* +* Member function information setup +*********************************************************/ +extern "C" void G__cpp_setup_memfuncG__stream() { +} + +/********************************************************* +* Global variable information setup for each class +*********************************************************/ +static void G__cpp_setup_global0() { + + /* Setting up global variables */ + G__resetplocal(); + + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"_MSC_VER=1700",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__IOSTREAM_H=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__TMPLTIOS=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__OSTREAMBODY=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__OSTREAMGLOBALSTUB=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__STDIO_H=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"_IOFBF=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"_IOLBF=1",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"_IONBF=2",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"BUFSIZ=8192",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"FILENAME_MAX=4096",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"L_tmpnam=20",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"TMP_MAX=238328",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"SEEK_CUR=1",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"SEEK_END=2",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"SEEK_SET=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__MANIP_SUPPORT=0",1,(char*)NULL); + G__memvar_setup((void*)(&cin),117,0,0,G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),G__defined_typename("istream"),-1,1,"cin=",0,(char*)NULL); + G__memvar_setup((void*)(&cout),117,0,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__defined_typename("ostream"),-1,1,"cout=",0,(char*)NULL); + G__memvar_setup((void*)(&cerr),117,0,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__defined_typename("ostream"),-1,1,"cerr=",0,(char*)NULL); + G__memvar_setup((void*)(&clog),117,0,0,G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),G__defined_typename("ostream"),-1,1,"clog=",0,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__FSTREAM_H=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__SSTREAM_H=0",1,(char*)NULL); + G__memvar_setup((void*)G__PVOID,112,0,0,-1,-1,-1,1,"G__STRING_H=0",1,(char*)NULL); + + G__resetglobalenv(); +} +extern "C" void G__cpp_setup_globalG__stream() { + G__cpp_setup_global0(); +} + +/********************************************************* +* Global function information setup for each class +*********************************************************/ +static void G__cpp_setup_func0() { + G__lastifuncposition(); + + G__memfunc_setup("dec", 300, G__G__stream__0_0, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("hex", 325, G__G__stream__0_1, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("oct", 326, G__G__stream__0_2, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("fixed", 528, G__G__stream__0_3, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("scientific", 1057, G__G__stream__0_4, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("right", 542, G__G__stream__0_5, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("left", 427, G__G__stream__0_6, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("internal", 861, G__G__stream__0_7, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("nouppercase", 1189, G__G__stream__0_8, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("uppercase", 968, G__G__stream__0_9, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noskipws", 894, G__G__stream__0_10, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("skipws", 673, G__G__stream__0_11, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noshowpos", 1008, G__G__stream__0_12, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("showpos", 787, G__G__stream__0_13, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noshowpoint", 1224, G__G__stream__0_14, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("showpoint", 1003, G__G__stream__0_15, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noshowbase", 1081, G__G__stream__0_16, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("showbase", 860, G__G__stream__0_17, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("noboolalpha", 1167, G__G__stream__0_18, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("boolalpha", 946, G__G__stream__0_19, 117, G__get_linked_tagnum(&G__G__streamLN_ios_base), -1, 1, 1, 1, 1, 0, "u 'ios_base' - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("ws", 234, G__G__stream__0_20, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 1, 1, 1, 0, "u 'basic_istream >' 'istream' 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("endl", 419, G__G__stream__0_21, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 1, 1, 1, 0, "u 'basic_ostream >' 'ostream' 1 - i", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("ends", 426, G__G__stream__0_22, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 1, 1, 1, 0, "u 'basic_ostream >' 'ostream' 1 - i", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("flush", 546, G__G__stream__0_23, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 1, 1, 1, 0, "u 'basic_ostream >' 'ostream' 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_24, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - c - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_25, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - C - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_26, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - Y - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_27, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - b - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_28, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - s - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_29, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - r - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_30, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - i - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_31, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - h - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_32, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - l - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_33, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - k - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_34, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - f - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_35, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - d - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator<<", 996, G__G__stream__0_36, 117, G__get_linked_tagnum(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("ostream"), 1, 2, 1, 1, 0, +"u 'basic_ostream >' 'ostream' 1 - - g - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_37, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - c - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_38, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - b - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_39, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - s - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_40, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - r - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_41, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - i - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_42, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - h - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_43, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - l - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_44, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - k - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_45, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - f - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_46, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - d - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_47, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - g - - 1 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_48, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - C - - 0 - -", (char*) NULL +, (void*) NULL, 0); + G__memfunc_setup("operator>>", 1000, G__G__stream__0_49, 117, G__get_linked_tagnum(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR), G__defined_typename("istream"), 1, 2, 1, 1, 0, +"u 'basic_istream >' 'istream' 1 - - Y - - 1 - -", (char*) NULL +, (void*) NULL, 0); + + G__resetifuncposition(); +} + +extern "C" void G__cpp_setup_funcG__stream() { + G__cpp_setup_func0(); +} + +/********************************************************* +* Class,struct,union,enum tag information setup +*********************************************************/ +/* Setup class/struct taginfo */ +G__linked_taginfo G__G__streamLN_mbstate_t = { "mbstate_t" , 115 , -1 }; +G__linked_taginfo G__G__streamLN_ios_base = { "ios_base" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLio_state = { "ios_base::io_state" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLopen_mode = { "ios_base::open_mode" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLseek_dir = { "ios_base::seek_dir" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLfmt_flags = { "ios_base::fmt_flags" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLevent = { "ios_base::event" , 101 , -1 }; +G__linked_taginfo G__G__streamLN_ios_basecLcLInit = { "ios_base::Init" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_char_traitslEchargR = { "char_traits" , 115 , -1 }; +G__linked_taginfo G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR = { "basic_istream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR = { "basic_ios >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR = { "basic_streambuf >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR = { "basic_ostream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry = { "basic_ostream >::sentry" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry = { "basic_istream >::sentry" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR = { "basic_filebuf >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR = { "basic_ifstream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR = { "basic_ofstream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR = { "basic_fstream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR = { "basic_iostream >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_stringbuf,allocator >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_string,allocator >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_istringstream,allocator >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_ostringstream,allocator >" , 99 , -1 }; +G__linked_taginfo G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR = { "basic_stringstream,allocator >" , 99 , -1 }; + +/* Reset class/struct taginfo */ +extern "C" void G__cpp_reset_tagtableG__stream() { + G__G__streamLN_mbstate_t.tagnum = -1 ; + G__G__streamLN_ios_base.tagnum = -1 ; + G__G__streamLN_ios_basecLcLio_state.tagnum = -1 ; + G__G__streamLN_ios_basecLcLopen_mode.tagnum = -1 ; + G__G__streamLN_ios_basecLcLseek_dir.tagnum = -1 ; + G__G__streamLN_ios_basecLcLfmt_flags.tagnum = -1 ; + G__G__streamLN_ios_basecLcLevent.tagnum = -1 ; + G__G__streamLN_ios_basecLcLInit.tagnum = -1 ; + G__G__streamLN_char_traitslEchargR.tagnum = -1 ; + G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry.tagnum = -1 ; + G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry.tagnum = -1 ; + G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; + G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR.tagnum = -1 ; +} + + +extern "C" void G__cpp_setup_tagtableG__stream() { + + /* Setting up class,struct,union tag entry */ + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_mbstate_t),sizeof(mbstate_t),-1,0,(char*)NULL,G__setup_memvarmbstate_t,G__setup_memfuncmbstate_t); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_base),sizeof(ios_base),-1,3840,(char*)NULL,G__setup_memvarios_base,G__setup_memfuncios_base); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLio_state),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLopen_mode),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLseek_dir),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLfmt_flags),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLevent),sizeof(int),-1,0,(char*)NULL,NULL,NULL); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_ios_basecLcLInit),sizeof(ios_base::Init),-1,1280,(char*)NULL,G__setup_memvarios_basecLcLInit,G__setup_memfuncios_basecLcLInit); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_char_traitslEchargR),sizeof(char_traits),-1,0,(char*)NULL,G__setup_memvarchar_traitslEchargR,G__setup_memfuncchar_traitslEchargR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_istream >),-1,34048,(char*)NULL,G__setup_memvarbasic_istreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_istreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR),sizeof(basic_ios >),-1,36608,(char*)NULL,G__setup_memvarbasic_ioslEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_ioslEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR),sizeof(basic_streambuf >),-1,3840,(char*)NULL,G__setup_memvarbasic_streambuflEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_streambuflEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_ostream >),-1,34048,(char*)NULL,G__setup_memvarbasic_ostreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_ostreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry),sizeof(basic_ostream >::sentry),-1,36352,(char*)NULL,G__setup_memvarbasic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry,G__setup_memfuncbasic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry),sizeof(basic_istream >::sentry),-1,35328,(char*)NULL,G__setup_memvarbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry,G__setup_memfuncbasic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR),sizeof(basic_filebuf >),-1,3328,(char*)NULL,G__setup_memvarbasic_filebuflEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_filebuflEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_ifstream >),-1,34048,(char*)NULL,G__setup_memvarbasic_ifstreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_ifstreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_ofstream >),-1,34048,(char*)NULL,G__setup_memvarbasic_ofstreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_ofstreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_fstream >),-1,33024,(char*)NULL,G__setup_memvarbasic_fstreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_fstreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR),sizeof(basic_iostream >),-1,34048,(char*)NULL,G__setup_memvarbasic_iostreamlEcharcOchar_traitslEchargRsPgR,G__setup_memfuncbasic_iostreamlEcharcOchar_traitslEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),sizeof(basic_stringbuf,allocator >),-1,36096,(char*)NULL,G__setup_memvarbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR,G__setup_memfuncbasic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); + G__get_linked_tagnum_fwd(&G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),sizeof(basic_istringstream,allocator >),-1,34048,(char*)NULL,G__setup_memvarbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR,G__setup_memfuncbasic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),sizeof(basic_ostringstream,allocator >),-1,34048,(char*)NULL,G__setup_memvarbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR,G__setup_memfuncbasic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); + G__tagtable_setup(G__get_linked_tagnum_fwd(&G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR),sizeof(basic_stringstream,allocator >),-1,34048,(char*)NULL,G__setup_memvarbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR,G__setup_memfuncbasic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR); +} +extern "C" void G__cpp_setupG__stream(void) { + G__check_setup_version(30051515,"G__cpp_setupG__stream()"); + G__set_cpp_environmentG__stream(); + G__cpp_setup_tagtableG__stream(); + + G__cpp_setup_inheritanceG__stream(); + + G__cpp_setup_typetableG__stream(); + + G__cpp_setup_memvarG__stream(); + + G__cpp_setup_memfuncG__stream(); + G__cpp_setup_globalG__stream(); + G__cpp_setup_funcG__stream(); + + if(0==G__getsizep2memfunc()) G__get_sizep2memfuncG__stream(); + return; +} + + diff --git a/cint/cint/src/dict/vc11strm.h b/cint/cint/src/dict/vc11strm.h new file mode 100644 index 0000000000000..34815817335a1 --- /dev/null +++ b/cint/cint/src/dict/vc11strm.h @@ -0,0 +1,83 @@ +/******************************************************************** +* vc11strm.h +* CAUTION: DON'T CHANGE THIS FILE. THIS FILE IS AUTOMATICALLY GENERATED +* FROM HEADER FILES LISTED IN G__setup_cpp_environmentXXX(). +* CHANGE THOSE HEADER FILES AND REGENERATE THIS FILE. +********************************************************************/ +#ifdef __CINT__ +#error vc11strm.h/C is only for compilation. Abort cint. +#endif +#include +#include +#include +#include +#include +#define G__ANSIHEADER +#define G__DICTIONARY +#define G__PRIVATE_GVALUE +#include "G__ci.h" +#include "FastAllocString.h" +extern "C" { +extern G__DLLEXPORT int G__cpp_dllrevG__stream(); +extern G__DLLEXPORT void G__set_cpp_environmentG__stream(); +extern G__DLLEXPORT void G__cpp_setup_tagtableG__stream(); +extern G__DLLEXPORT void G__cpp_setup_inheritanceG__stream(); +extern G__DLLEXPORT void G__cpp_setup_typetableG__stream(); +extern G__DLLEXPORT void G__cpp_setup_memvarG__stream(); +extern G__DLLEXPORT void G__cpp_setup_globalG__stream(); +extern G__DLLEXPORT void G__cpp_setup_memfuncG__stream(); +extern G__DLLEXPORT void G__cpp_setup_funcG__stream(); +extern G__DLLEXPORT void G__cpp_setupG__stream(); +} + + +#include "iostrm.h" +#include "fstrm.h" +#include "sstrm.h" + +#ifndef G__MEMFUNCBODY +#endif + +extern G__linked_taginfo G__G__streamLN_mbstate_t; +extern G__linked_taginfo G__G__streamLN_ios_base; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLio_state; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLopen_mode; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLseek_dir; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLfmt_flags; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLevent; +extern G__linked_taginfo G__G__streamLN_ios_basecLcLInit; +extern G__linked_taginfo G__G__streamLN_char_traitslEchargR; +extern G__linked_taginfo G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ioslEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_streambuflEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +extern G__linked_taginfo G__G__streamLN_basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +extern G__linked_taginfo G__G__streamLN_basic_filebuflEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ifstreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ofstreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_fstreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_iostreamlEcharcOchar_traitslEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_stringlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +extern G__linked_taginfo G__G__streamLN_basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; + +/* STUB derived class for protected member access */ +typedef char_traits G__char_traitslEchargR; +typedef basic_istream > G__basic_istreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_ios > G__basic_ioslEcharcOchar_traitslEchargRsPgR; +typedef basic_streambuf > G__basic_streambuflEcharcOchar_traitslEchargRsPgR; +typedef basic_ostream > G__basic_ostreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_ostream >::sentry G__basic_ostreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +typedef basic_istream >::sentry G__basic_istreamlEcharcOchar_traitslEchargRsPgRcLcLsentry; +typedef basic_filebuf > G__basic_filebuflEcharcOchar_traitslEchargRsPgR; +typedef basic_ifstream > G__basic_ifstreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_ofstream > G__basic_ofstreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_fstream > G__basic_fstreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_iostream > G__basic_iostreamlEcharcOchar_traitslEchargRsPgR; +typedef basic_stringbuf,allocator > G__basic_stringbuflEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +typedef basic_istringstream,allocator > G__basic_istringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +typedef basic_ostringstream,allocator > G__basic_ostringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; +typedef basic_stringstream,allocator > G__basic_stringstreamlEcharcOchar_traitslEchargRcOallocatorlEchargRsPgR; diff --git a/cint/cint/src/dict/vc7strm.cxx b/cint/cint/src/dict/vc7strm.cxx index 93f47119768cc..8f3f0924f99bd 100644 --- a/cint/cint/src/dict/vc7strm.cxx +++ b/cint/cint/src/dict/vc7strm.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/vc7strm.h b/cint/cint/src/dict/vc7strm.h index 54658d5d0fded..43dcfcc1d402c 100644 --- a/cint/cint/src/dict/vc7strm.h +++ b/cint/cint/src/dict/vc7strm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/vcstrm.cxx b/cint/cint/src/dict/vcstrm.cxx index 2b9e1a2af5377..e614cdfc86c6f 100644 --- a/cint/cint/src/dict/vcstrm.cxx +++ b/cint/cint/src/dict/vcstrm.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/vcstrm.h b/cint/cint/src/dict/vcstrm.h index 3da17b59a45cc..5e415d656d6fc 100644 --- a/cint/cint/src/dict/vcstrm.h +++ b/cint/cint/src/dict/vcstrm.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/vcstrmold.cxx b/cint/cint/src/dict/vcstrmold.cxx index 5f76b38a84e9f..1676658436271 100644 --- a/cint/cint/src/dict/vcstrmold.cxx +++ b/cint/cint/src/dict/vcstrmold.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/dict/vcstrmold.h b/cint/cint/src/dict/vcstrmold.h index 77f8338933d47..e0b83bde5eb7c 100644 --- a/cint/cint/src/dict/vcstrmold.h +++ b/cint/cint/src/dict/vcstrmold.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/fproto.h b/cint/cint/src/fproto.h index b98394d024f83..cd86993413ae4 100644 --- a/cint/cint/src/fproto.h +++ b/cint/cint/src/fproto.h @@ -264,8 +264,12 @@ int G__preprocessor(char *outname,const char *inname,int cppflag,const char *mac int G__difffile(char *file1,char *file2); int G__copyfile(FILE *to,FILE *from); +#ifdef __cplusplus struct stat; -int G__statfilename(const char *filename, struct stat* buf); +} // extern "C" +int G__statfilename(const char *filename, struct stat* buf, G__FastAllocString* fullPath); +extern "C" { +#endif int G__matchfilename(int i1,const char* filename); int G__cleardictfile(int flag); diff --git a/cint/cint/src/fread.cxx b/cint/cint/src/fread.cxx index 7a68155355ab9..c935ea573a702 100644 --- a/cint/cint/src/fread.cxx +++ b/cint/cint/src/fread.cxx @@ -424,10 +424,17 @@ static int G__fgetstream_newtemplate_internal(G__FastAllocString& string, bool next_double_quote = double_quote; switch (c) { - case ' ': - case '\f': case '\n': case '\r': + if (i && (single_quote == 0) && (double_quote == 0) && '\\' == string[i-1]) { + // This is a line continuation, we just ignore it. + --i; + ignoreflag = true; + breakflag = false; // Undo a possible marker match. + break; + } + case ' ': + case '\f': case '\t': commentflag = false; if (!single_quote && !double_quote) { @@ -491,6 +498,11 @@ static int G__fgetstream_newtemplate_internal(G__FastAllocString& string, if (!ignoreflag) { string.Set(i++, c); c = G__fgetc() ; + if ( (c=='\n' || c=='\r') && (single_quote == 0) && (double_quote == 0)) { + // This is a line continuation, we just ignore both the \ and \n. + --i; + ignoreflag = true; + } } break; @@ -656,10 +668,17 @@ int G__fgetstream_template(G__FastAllocString& string, size_t offset, const char } switch (c) { - case ' ': - case '\f': case '\n': case '\r': + if (i && (single_quote == 0) && (double_quote == 0) && '\\' == string[i-1]) { + // This is a line continuation, we just ignore it. + --i; + ignoreflag = 1; + flag = 0; // Undo a possible marker match. + break; + } + case ' ': + case '\f': case '\t': commentflag = 0; if ((single_quote == 0) && (double_quote == 0)) { @@ -729,7 +748,12 @@ int G__fgetstream_template(G__FastAllocString& string, size_t offset, const char case '\\': if (ignoreflag == 0) { string.Set(i++, c); - c = G__fgetc() ; + c = G__fgetc(); + if ( (c=='\n' || c=='\r') && (single_quote == 0) && (double_quote == 0)) { + // This is a line continuation, we just ignore both the \ and \n. + --i; + ignoreflag = 1; + } } break; @@ -904,10 +928,17 @@ int G__getstream_template(const char* source, int* isrc,G__FastAllocString& str } } break; - case ' ': - case '\f': case '\n': case '\r': + if (i && (single_quote == 0) && (double_quote == 0) && '\\' == string[i-1]) { + // This is a line continuation, we just ignore it. + --i; + ignoreflag = 1; + flag = 0; // Undo a possible marker match. + break; + } + case ' ': + case '\f': case '\t': if ((single_quote == 0) && (double_quote == 0)) { string.Set(i, 0); @@ -1711,6 +1742,11 @@ int G__fdumpstream(G__FastAllocString& string, size_t offset, const char *endmar if (ignoreflag == 0) { string.Set(i++, c); c = G__fgetc() ; + if ( (c=='\n' || c=='\r') && (single_quote == 0) && (double_quote == 0)) { + // This is a line continuation, we just ignore both the \ and \n. + --i; + ignoreflag = 1; + } } break; @@ -1881,6 +1917,11 @@ int G__fgetstream(G__FastAllocString& string, size_t offset, const char *endmark if (!ignoreflag) { string.Set(i++, c); c = G__fgetc(); + if ( (c=='\n' || c=='\r') && (single_quote == 0) && (double_quote == 0)) { + // This is a line continuation, we just ignore both the \ and \n. + --i; + ignoreflag = 1; + } } break; case '/': @@ -2054,9 +2095,16 @@ int G__fgetstream_spaces(G__FastAllocString& string, size_t offset, const char * } } switch (c) { - case '\f': case '\n': case '\r': + if (i && (single_quote == 0) && (double_quote == 0) && '\\' == string[i-1]) { + // This is a line continuation, we just ignore it. + --i; + ignoreflag = 1; + flag = 0; // Undo a possible marker match. + break; + } + case '\f': case '\t': case ' ': commentflag = 0; @@ -2094,6 +2142,11 @@ int G__fgetstream_spaces(G__FastAllocString& string, size_t offset, const char * if (!ignoreflag) { string.Set(i++, c); c = G__fgetc(); + if ( (c=='\n' || c=='\r') && (single_quote == 0) && (double_quote == 0)) { + // This is a line continuation, we just ignore both the \ and \n. + --i; + ignoreflag = 1; + } } break; case '/': @@ -2249,6 +2302,11 @@ int G__getstream(const char* source, int* isrc, char* string, const char* endmar if (!ignoreflag) { string[i++] = c; c = source[(*isrc)++]; + if ( (c=='\n' || c=='\r') && (single_quote == 0) && (double_quote == 0)) { + // This is a line continuation, we just ignore both the \ and \n. + --i; + ignoreflag = 1; + } } break; case '/': diff --git a/cint/cint/src/func.cxx b/cint/cint/src/func.cxx index 51a4324dbd312..3cdd1e6bab88f 100644 --- a/cint/cint/src/func.cxx +++ b/cint/cint/src/func.cxx @@ -3645,7 +3645,7 @@ int G__special_func(G__value* result7, char* funcname, G__param* libp, int hash) G__letint(result7, 'u', (long)G__typeid(libp->parameter[0])); } result7->ref = result7->obj.i; - result7->tagnum = *(int*)(result7->ref); + if (result7->ref) result7->tagnum = *(int*)(result7->ref); return 1; } #endif // G__TYPEINFO diff --git a/cint/cint/src/header.h b/cint/cint/src/header.h index 3e1044f05695b..e3945c020e624 100644 --- a/cint/cint/src/header.h +++ b/cint/cint/src/header.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/ifunc.cxx b/cint/cint/src/ifunc.cxx index eae380287c94e..d0e4081f4ca5d 100644 --- a/cint/cint/src/ifunc.cxx +++ b/cint/cint/src/ifunc.cxx @@ -1041,7 +1041,7 @@ void G__make_ifunctable(G__FastAllocString &funcheader) * If ANSI style header, rewind file position to * func(int a ,double b ) ANSI * ^ - * and check type of paramaters and store it into G__ifunc + * and check type of parameters and store it into G__ifunc ****************************************************************/ if (G__p_ifunc->ansi[func_now]) { // -- ANSI style function header @@ -6562,7 +6562,7 @@ int G__interpret_func(G__value* result7, const char* funcname, G__param* libp, i } } else { - // -- We do not have an argument for the paramater. + // -- We do not have an argument for the parameter. if ((ipara < p_ifunc->para_nu[ifn]) && p_ifunc->param[ifn][ipara]->pdefault) { // -- We have a default value for the parameter, use it. if (p_ifunc->param[ifn][ipara]->pdefault->type == G__DEFAULT_FUNCCALL) { diff --git a/cint/cint/src/init.cxx b/cint/cint/src/init.cxx index 5533f95da539f..81150d08949ef 100644 --- a/cint/cint/src/init.cxx +++ b/cint/cint/src/init.cxx @@ -139,6 +139,10 @@ int G__call_setup_funcs() // Call G__RegisterLibrary() again, after it got called already // in G__init_setup_funcs(), because G__scratchall might have been // called in between. + + // Register libCint itself. + G__RegisterLibrary( (void (*)()) G__call_setup_funcs); + // Do a separate loop so we don't re-load because of A->B->A // dependencies introduced by autoloading during dictionary // initialization @@ -2189,6 +2193,16 @@ void G__platformMacro() #ifdef __GLIBC_MINOR__ /* GNU C library minor version */ G__DEFINE_MACRO(__GLIBC_MINOR__); #endif +#ifdef __clang__ /* Clang C++ compiler, note it also defines still GNUC */ + G__DEFINE_MACRO(__clang__); +#endif +#ifdef _LIBCPP_ABI_VERSION /* libc++ C++ std lib */ + if (G__globalcomp == G__NOLINK) { + G__snprintf(temp, sizeof(temp), "G__LIBCPP=%ld", (long)_LIBCPP_ABI_VERSION); + G__add_macro(temp); + } + G__DEFINE_MACRO(_LIBCPP_ABI_VERSION); +#endif #ifdef __HP_aCC /* HP aCC C++ compiler */ if (G__globalcomp == G__NOLINK) { G__snprintf(temp, sizeof(temp), "G__HP_aCC=%ld", (long)__HP_aCC); @@ -2504,7 +2518,7 @@ const char *G__cint_version() int G__cintrevision(FILE* fp) { fprintf(fp, "\n"); - fprintf(fp, "cint : C/C++ interpreter (mailing list 'cint@root.cern.ch')\n"); + fprintf(fp, "cint : C/C++ interpreter (mailing list 'root-cint@cern.ch')\n"); fprintf(fp, " Copyright(c) : 1995~2010 Masaharu Goto (gotom@hanno.jp)\n"); fprintf(fp, " revision : %s by M.Goto\n\n", G__cint_version()); diff --git a/cint/cint/src/loadfile.cxx b/cint/cint/src/loadfile.cxx index 331c0acb826c5..dd1285f679d68 100644 --- a/cint/cint/src/loadfile.cxx +++ b/cint/cint/src/loadfile.cxx @@ -45,6 +45,7 @@ #ifdef __APPLE__ #include +#include #endif #define G__OLDIMPLEMENTATION1849 @@ -1178,15 +1179,18 @@ int G__loadfile_tmpfile(FILE *fp) G__UnlockCriticalSection(); return(fentry+2); } +} // extern "C" // ***************************************************************** // * G__statfilename(filename) // * // * Use the same search algorithm as G__loadfile to do a 'stat' on the file +// * If fullPath != 0, strdup the full path as found (must be deleted by caller). // * // ***************************************************************** -int G__statfilename(const char *filenamein, struct stat *statBuf) +int G__statfilename(const char *filenamein, struct stat *statBuf, + G__FastAllocString* fullPath /*= 0*/) { G__FastAllocString filename(filenamein); G__FastAllocString workname(G__ONELINE); @@ -1271,7 +1275,10 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) res = stat( workname, statBuf ); - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } } /********************************************** * try ./filename @@ -1279,7 +1286,10 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) if(G__USERHEADER==G__kindofheader) { workname.Format("%s%s",filename(),addpost[i2]); res = stat( workname, statBuf ); - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } } else { // Do we need that or not? // G__kindofheader = G__USERHEADER; @@ -1294,7 +1304,10 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) res = stat( workname, statBuf ); ipath = ipath->next; } - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } G__getcintsysdir(); @@ -1305,7 +1318,10 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) workname.Format("%s%s%s%sstl%s%s%s",G__cintsysdir,G__psep,G__CFG_COREVERSION ,G__psep,G__psep,filename(),addpost[i2]); res = stat( workname, statBuf ); - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } } /********************************************** @@ -1316,7 +1332,10 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) workname.Format("%s%s%s%slib%s%s%s",G__cintsysdir,G__psep,G__CFG_COREVERSION ,G__psep,G__psep,filename(),addpost[i2]); res = stat( workname, statBuf ); - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } } #ifdef G__EDU_VERSION @@ -1327,7 +1346,10 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) workname.Format("include%s%s%s" ,G__psep,filename(),addpost[i2]); res = stat( workname, statBuf ); - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } } /********************************************** * try stl @@ -1337,7 +1359,10 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) workname.Format("stl%s%s%s" ,G__psep,filename(),addpost[i2]); res = stat( workname, statBuf ); - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } } #endif /* G__EDU_VERSION */ @@ -1348,7 +1373,10 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) if('\0'!=G__cintsysdir[0]) { workname.Format("/msdev/include/%s%s",filename(),addpost[i2]); res = stat( workname, statBuf ); - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } } #endif /* G__VISUAL */ @@ -1359,7 +1387,10 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) if('\0'!=G__cintsysdir[0]) { workname.Format("/sc/include/%s%s",filename(),addpost[i2]); res = stat( workname, statBuf ); - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } } #endif // G__SYMANTEC @@ -1370,7 +1401,10 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) if('\0'!=G__cintsysdir[0]) { workname.Format("/usr/include/%s%s",filename(),addpost[i2]); res = stat( workname, statBuf ); - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } } #endif @@ -1381,7 +1415,10 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) if('\0'!=G__cintsysdir[0]) { workname.Format("/usr/include/g++/%s%s",filename(),addpost[i2]); res = stat( workname, statBuf ); - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } } #endif /* __GNUC__ */ @@ -1393,7 +1430,10 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) if('\0'!=G__cintsysdir[0]) { workname.Format("/usr/include/CC/%s%s",filename(),addpost[i2]); res = stat( workname, statBuf ); - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } } #endif @@ -1405,13 +1445,18 @@ int G__statfilename(const char *filenamein, struct stat *statBuf) workname.Format("/usr/include/codelibs/%s%s" ,filename(),addpost[i2]); res = stat( workname, statBuf ); - if (res==0) return res; + if (res==0) { + if (fullPath) fullPath->Swap(workname); + return res; + } } #endif } return -1; } +extern "C" { + /****************************************************************** * G__loadfile(filename) * diff --git a/cint/cint/src/newlink.cxx b/cint/cint/src/newlink.cxx index a12692acaaed5..baa6e77c943ea 100644 --- a/cint/cint/src/newlink.cxx +++ b/cint/cint/src/newlink.cxx @@ -2063,7 +2063,7 @@ int G__stub_method_calling(G__value *result7, G__param *libp, // 27-04-07 // The actual version of Cint has a limitation with - // the array constructor: it cant receive paramaters (or at least, + // the array constructor: it cant receive parameters (or at least, // it ignores them). Here I will try to pass the parameters of // the constructors for every object (to handle something like // string *str = new string[10]("strriiiinnnggg") ). @@ -4876,7 +4876,7 @@ void G__write_dummy_param(FILE *fp, G__paramfunc *formal_param) break; default: - fprintf(fp, " Unkown: %c", formal_param->type); + fprintf(fp, " Unknown: %c", formal_param->type); G__fprinterr(G__serr,"Type %c not known yet (methodcall)\n", para_type); } @@ -4979,7 +4979,7 @@ void G__write_dummy_param(FILE *fp, G__paramfunc *formal_param) break; default: - fprintf(fp, " Unkown: %c", formal_param->type); + fprintf(fp, " Unknown: %c", formal_param->type); G__fprinterr(G__serr,"Type %c not known yet (G__write_dummy_param)\n",formal_param->type); } fprintf(fp,"*"); @@ -5123,7 +5123,7 @@ void G__cppif_dummyobj(FILE *fp, struct G__ifunc_table_internal *ifunc, int i,in * * 25-07-07 * - * Create the deafult cons, dests, etc as ifunc entries before writing + * Create the default cons, dests, etc as ifunc entries before writing * them to the file **************************************************************************/ void G__make_default_ifunc(G__ifunc_table_internal *ifunc_copy) @@ -12784,11 +12784,12 @@ void G__specify_link(int link_stub) buf[buflen-1]='\0'; } } + G__FastAllocString fullPath(G__ONELINE); if ( 0==tagflag && - 0 == G__statfilename( buf, & statBufItem ) ) { + 0 == G__statfilename( buf, & statBufItem, &fullPath ) ) { #ifdef G__WIN32 - _fullpath( fullItem, buf, _MAX_PATH ); + _fullpath( fullItem, fullPath, _MAX_PATH ); #endif for(ifile=0;ifileobj.ld=G__Longdouble(*bufm2)+G__Longdouble(*bufm1); bufm2->type='q'; } - else if('n'==bufm2->type || 'n'==bufm1->type) { - bufm2->obj.ll=G__Longlong(*bufm2)+G__Longlong(*bufm1); - bufm2->type='n'; - } - else if('m'==bufm2->type || 'm'==bufm1->type) { - bufm2->obj.ull=G__ULonglong(*bufm2)+G__ULonglong(*bufm1); - bufm2->type='m'; - } else if(G__isdoubleM(bufm2)) { if(G__isdoubleM(bufm1)) { @@ -1559,6 +1551,14 @@ void G__OP2_plus(G__value *bufm1,G__value *bufm2) bufm2->type = 'd'; bufm2->tagnum = bufm2->typenum = -1; } + else if('n'==bufm2->type || 'n'==bufm1->type) { + bufm2->obj.ll=G__Longlong(*bufm2)+G__Longlong(*bufm1); + bufm2->type='n'; + } + else if('m'==bufm2->type || 'm'==bufm1->type) { + bufm2->obj.ull=G__ULonglong(*bufm2)+G__ULonglong(*bufm1); + bufm2->type='m'; + } else if(isupper(bufm2->type)) { bufm2->obj.i = bufm2->obj.i + bufm1->obj.i*G__sizeof(bufm2); } @@ -1595,14 +1595,6 @@ void G__OP2_minus(G__value *bufm1,G__value *bufm2) bufm2->obj.ld=G__Longdouble(*bufm2)-G__Longdouble(*bufm1); bufm2->type='q'; } - else if('n'==bufm2->type || 'n'==bufm1->type) { - bufm2->obj.ll=G__Longlong(*bufm2)-G__Longlong(*bufm1); - bufm2->type='n'; - } - else if('m'==bufm2->type || 'm'==bufm1->type) { - bufm2->obj.ull=G__ULonglong(*bufm2)-G__ULonglong(*bufm1); - bufm2->type='m'; - } else if(G__isdoubleM(bufm2)) { if(G__isdoubleM(bufm1)) { @@ -1619,6 +1611,14 @@ void G__OP2_minus(G__value *bufm1,G__value *bufm2) bufm2->type = 'd'; bufm2->tagnum = bufm2->typenum = -1; } + else if('n'==bufm2->type || 'n'==bufm1->type) { + bufm2->obj.ll=G__Longlong(*bufm2)-G__Longlong(*bufm1); + bufm2->type='n'; + } + else if('m'==bufm2->type || 'm'==bufm1->type) { + bufm2->obj.ull=G__ULonglong(*bufm2)-G__ULonglong(*bufm1); + bufm2->type='m'; + } else if(isupper(bufm2->type)) { if(isupper(bufm1->type)) { bufm2->obj.i=(bufm2->obj.i-bufm1->obj.i)/G__sizeof(bufm2); @@ -1661,14 +1661,6 @@ void G__OP2_multiply(G__value *bufm1,G__value *bufm2) bufm2->obj.ld=G__Longdouble(*bufm2)*G__Longdouble(*bufm1); bufm2->type='q'; } - else if('n'==bufm2->type || 'n'==bufm1->type) { - bufm2->obj.ll=G__Longlong(*bufm2)*G__Longlong(*bufm1); - bufm2->type='n'; - } - else if('m'==bufm2->type || 'm'==bufm1->type) { - bufm2->obj.ull=G__ULonglong(*bufm2)*G__ULonglong(*bufm1); - bufm2->type='m'; - } else if(G__isdoubleM(bufm2)) { if(G__isdoubleM(bufm1)) { @@ -1683,6 +1675,14 @@ void G__OP2_multiply(G__value *bufm1,G__value *bufm2) bufm2->obj.d = G__convertT(bufm2) * bufm1->obj.d; bufm2->type = 'd'; } + else if('n'==bufm2->type || 'n'==bufm1->type) { + bufm2->obj.ll=G__Longlong(*bufm2)*G__Longlong(*bufm1); + bufm2->type='n'; + } + else if('m'==bufm2->type || 'm'==bufm1->type) { + bufm2->obj.ull=G__ULonglong(*bufm2)*G__ULonglong(*bufm1); + bufm2->type='m'; + } else if(G__isunsignedM(bufm1)) { if(G__isunsignedM(bufm2)) bufm2->obj.ulo = G__convertT(bufm2) * G__convertT(bufm1); @@ -1749,14 +1749,6 @@ void G__OP2_divide(G__value *bufm1,G__value *bufm2) bufm2->obj.ld=G__Longdouble(*bufm2)/G__Longdouble(*bufm1); bufm2->type='q'; } - else if('n'==bufm2->type || 'n'==bufm1->type) { - bufm2->obj.ll=G__Longlong(*bufm2)/G__Longlong(*bufm1); - bufm2->type='n'; - } - else if('m'==bufm2->type || 'm'==bufm1->type) { - bufm2->obj.ull=G__ULonglong(*bufm2)/G__ULonglong(*bufm1); - bufm2->type='m'; - } else if(G__isdoubleM(bufm2)) { if(G__isdoubleM(bufm1)) { @@ -1791,6 +1783,14 @@ void G__OP2_divide(G__value *bufm1,G__value *bufm2) bufm2->obj.d = G__convertT(bufm2) / bufm1->obj.d; bufm2->type = 'd'; } + else if('n'==bufm2->type || 'n'==bufm1->type) { + bufm2->obj.ll=G__Longlong(*bufm2)/G__Longlong(*bufm1); + bufm2->type='n'; + } + else if('m'==bufm2->type || 'm'==bufm1->type) { + bufm2->obj.ull=G__ULonglong(*bufm2)/G__ULonglong(*bufm1); + bufm2->type='m'; + } else if(G__isunsignedM(bufm1)) { #ifdef G__TUNEUP_W_SECURITY if(0==bufm1->obj.i) { diff --git a/cint/cint/src/random.cxx b/cint/cint/src/random.cxx index 72162697b2d72..ec3ab4fe49485 100644 --- a/cint/cint/src/random.cxx +++ b/cint/cint/src/random.cxx @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/rflx_gendict.cxx b/cint/cint/src/rflx_gendict.cxx index af01df53fcaa9..bf89b3f331449 100644 --- a/cint/cint/src/rflx_gendict.cxx +++ b/cint/cint/src/rflx_gendict.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/rflx_gendict.h b/cint/cint/src/rflx_gendict.h index 26dfbbb24a37f..5f6f1258795df 100644 --- a/cint/cint/src/rflx_gendict.h +++ b/cint/cint/src/rflx_gendict.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/rflx_gensrc.cxx b/cint/cint/src/rflx_gensrc.cxx index 7330f5c3676f3..9629a3145c2cb 100644 --- a/cint/cint/src/rflx_gensrc.cxx +++ b/cint/cint/src/rflx_gensrc.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/rflx_gensrc.h b/cint/cint/src/rflx_gensrc.h index 39700954658d6..8c5ebf24327b6 100644 --- a/cint/cint/src/rflx_gensrc.h +++ b/cint/cint/src/rflx_gensrc.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/rflx_tools.cxx b/cint/cint/src/rflx_tools.cxx index e3342f208be8a..405e65bb9a4af 100644 --- a/cint/cint/src/rflx_tools.cxx +++ b/cint/cint/src/rflx_tools.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/rflx_tools.h b/cint/cint/src/rflx_tools.h index b2ff15bc0103c..45f1d320a9e30 100644 --- a/cint/cint/src/rflx_tools.h +++ b/cint/cint/src/rflx_tools.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/src/scrupto.cxx b/cint/cint/src/scrupto.cxx index 381c7bdd65054..c73111418a02e 100644 --- a/cint/cint/src/scrupto.cxx +++ b/cint/cint/src/scrupto.cxx @@ -176,7 +176,7 @@ static void G__close_inputfiles_upto(G__dictposition* pos) int hash = G__struct.hash[itag]; char* libname = G__struct.libname[itag]; int parent_tagnum = G__struct.parent_tagnum[itag]; - G__struct.namerange->Remove(G__struct.name[itag], itag); + G__struct.namerange->Remove(G__struct.name[itag], itag, G__struct.name); G__struct.name[itag] = 0; // autoload entry - must not delete it, just set it to 0 G__struct.libname[itag] = 0; // same here int alltag = G__struct.alltag; @@ -383,7 +383,7 @@ static int G__free_typedef_upto(int typenum) for (--G__newtype.alltype; G__newtype.alltype >= typenum; --G__newtype.alltype) { // -- Free a typedef definition. // Free the typedef name. - G__newtype.namerange->Remove(G__newtype.name[G__newtype.alltype], G__newtype.alltype); + G__newtype.namerange->Remove(G__newtype.name[G__newtype.alltype], G__newtype.alltype, G__newtype.name); free((void*) G__newtype.name[G__newtype.alltype]); G__newtype.name[G__newtype.alltype] = 0; // @@ -545,7 +545,7 @@ static int G__free_struct_upto(int tagnum) G__struct.incsetup_memfunc[G__struct.alltag] = 0; } // freeing tagname - G__struct.namerange->Remove(G__struct.name[G__struct.alltag], G__struct.alltag); + G__struct.namerange->Remove(G__struct.name[G__struct.alltag], G__struct.alltag, G__struct.name); free((void*) G__struct.name[G__struct.alltag]); G__struct.name[G__struct.alltag] = 0; } diff --git a/cint/cint/src/sizeof.cxx b/cint/cint/src/sizeof.cxx index 2401e8322ba5d..3d99855d432e4 100644 --- a/cint/cint/src/sizeof.cxx +++ b/cint/cint/src/sizeof.cxx @@ -404,7 +404,7 @@ long *G__typeid(const char *typenamein) * Get type_info tagname ***********************************************************************/ tag_type_info = G__defined_tagname("type_info",1); - if(-1==tag_type_info) { + if(-1==tag_type_info || G__struct.size[tag_type_info] == 0) { G__genericerror("Error: class type_info not defined. must be included"); return((long*)NULL); } diff --git a/cint/cint/src/struct.cxx b/cint/cint/src/struct.cxx index 8e7e5dc25e3f5..ba66b12cd6692 100644 --- a/cint/cint/src/struct.cxx +++ b/cint/cint/src/struct.cxx @@ -47,6 +47,28 @@ int G__defined_tagname(const char* tagname, int noerror); int G__search_tagname(const char* tagname, int type); + void NameMap::Remove(const char* name, int idx, char **name_pool) { + NameMap_t::iterator iMap = fMap.find(name); + if (iMap != fMap.end()) { + iMap->second.erase(idx); + + if (iMap->second.empty()) { + fMap.erase(iMap); + } else { + NameMap::Range r2(iMap->second); + + // We need to reinsert it with a different index + std::set tmpSet = iMap->second; + fMap.erase(iMap); + const char *new_name = name_pool[*(tmpSet.begin())]; + fMap[new_name] = tmpSet; + // if (strcmp(new_name,name)!=0) { + // fprintf(stderr,"problem %s is not %s\n",name,new_name); + // } + } + } +} + //______________________________________________________________________________ char* G__savestring(char** pbuf, char* name) { @@ -521,7 +543,7 @@ int G__class_autoloading(int* ptagnum) std::string origName(G__struct.name[tagnum]); std::string fullName(G__fulltagname(tagnum,0)); if (G__struct.name[tagnum][0]) { - G__struct.namerange->Remove(G__struct.name[tagnum], tagnum); + G__struct.namerange->Remove(G__struct.name[tagnum], tagnum, G__struct.name); G__struct.name[tagnum][0] = '@'; } int found_tagnum = G__defined_tagname(fullName.c_str(),3); @@ -538,7 +560,7 @@ int G__class_autoloading(int* ptagnum) // to the real type (aka mytemp vs mytemp or the // stl containers with or without their (default) allocators. char *old = G__struct.name[tagnum]; - G__struct.namerange->Remove(old, tagnum); + G__struct.namerange->Remove(old, tagnum, G__struct.name); G__struct.name[tagnum] = (char*)malloc(strlen(old)+50); strcpy(G__struct.name[tagnum],"@@ ex autload entry @@"); // Okay, we allocated enough space @@ -1447,7 +1469,7 @@ void G__set_class_autoloading_table(char* classname, char* libname) } G__struct.libname[tagnum] = 0; } else if (G__struct.name[tagnum][0]) { - G__struct.namerange->Remove(G__struct.name[tagnum], tagnum); + G__struct.namerange->Remove(G__struct.name[tagnum], tagnum, G__struct.name); G__struct.name[tagnum][0] = '@'; } G__enable_autoloading = store_enable_autoloading; diff --git a/cint/cint/src/tmplt.cxx b/cint/cint/src/tmplt.cxx index 5c7b5252e4243..1fcd026d8e4f9 100644 --- a/cint/cint/src/tmplt.cxx +++ b/cint/cint/src/tmplt.cxx @@ -2523,7 +2523,7 @@ int G__instantiate_templateclass(const char *tagnamein, int noerror) char *p2 = strchr(G__struct.name[tagnum],'<'); if(p1 && p2 && (p1-tagname)==(p2-G__struct.name[tagnum]) && 0==strncmp(tagname,G__struct.name[tagnum],p1-tagname)) { - G__struct.namerange->Remove(G__struct.name[tagnum], tagnum); + G__struct.namerange->Remove(G__struct.name[tagnum], tagnum, G__struct.name); free((void*)G__struct.name[tagnum]); G__struct.name[tagnum] = (char*)malloc(strlen(tagname)+1); strcpy(G__struct.name[tagnum],tagname); // Okay we allocated enough space diff --git a/cint/cint/src/typedef.cxx b/cint/cint/src/typedef.cxx index 6653c6d57d4be..d2735511a3e32 100644 --- a/cint/cint/src/typedef.cxx +++ b/cint/cint/src/typedef.cxx @@ -1248,6 +1248,8 @@ int G__defined_typename_noerror(const char* type_name, int noerror) if (G__newtype.namerange) { NameMap::Range nameRange = G__newtype.namerange->Find(temp); if (nameRange) { + if (nameRange.Last() > G__newtype.alltype) + fprintf(stderr,"G__defined_typename_noerror %s, max=%d still have a set range of %d to %d\n",temp.data(),G__newtype.alltype,nameRange.First(),nameRange.Last()); for (i = nameRange.First(); i <= nameRange.Last(); ++i) { if ((len == G__newtype.hash[i]) && !strcmp(G__newtype.name[i], temp)) { thisflag = 0; @@ -1401,10 +1403,21 @@ int G__search_typename(const char* typenamein, int typein, int tagnum, int refty if (flag == 0 && typein) { // If we already have a type/class of the same name that is registered in G__struct as forward declared and/or autoload, // let's invalidate this entry. - int alias = G__defined_tagname(type_name,4); + + int store_def_tagnum = G__def_tagnum; + int store_tagdefining = G__tagdefining; + int store_tmplt_def_tagnum = G__tmplt_def_tagnum; + G__def_tagnum = G__static_parent_tagnum; + G__tagdefining = G__static_parent_tagnum; + G__tmplt_def_tagnum = G__static_parent_tagnum; + int alias = G__defined_tagname(type_name,4 | 0x1000); // We are looking for an exact match + G__def_tagnum = store_def_tagnum; + G__tagdefining = store_tagdefining; + G__tmplt_def_tagnum = store_tmplt_def_tagnum; + if (alias != -1 && G__struct.type[alias] == 'a') { char *old = G__struct.name[alias]; - G__struct.namerange->Remove(old, alias); + G__struct.namerange->Remove(old, alias,G__struct.name); G__struct.name[alias] = (char*)malloc(strlen(old)+60); strcpy(G__struct.name[alias],"@@ ex autload entry remove by typedef declaration @@"); // Okay, we allocated enough space diff --git a/cint/cint/src/var.cxx b/cint/cint/src/var.cxx index f6589f10b0b39..d961e5bbd2662 100644 --- a/cint/cint/src/var.cxx +++ b/cint/cint/src/var.cxx @@ -2848,6 +2848,9 @@ int G__fundamental_conversion_operator(int type, int tagnum, int typenum, int re // // Note: Bytecode compilation is alive after conversion operator is used. // + if (presult->tagnum == -1) { + return 0; + } G__FastAllocString tmp(G__ONELINE); G__value conv_result; int conv_done = 0; @@ -3062,7 +3065,7 @@ inline void G__alloc_var_ref(int SIZE, CONVFUNC f, const char* item, G__var_arra /* Namespace member variable. */ (var->statictype[ig15] == G__LOCALSTATIC) || /* Namespace member variable. */ - (G__struct.type[G__def_tagnum] == 'n') + (G__def_tagnum != -1 && G__struct.type[G__def_tagnum] == 'n') ) && /* Initialize const, static, and enumerator variables before running. */ (!G__static_alloc || G__prerun) && @@ -3170,7 +3173,7 @@ inline void G__alloc_var_ref(int SIZE, CONVFUNC f, const char* item, G__var_arra /* Namespace member. */ (var->statictype[ig15] == G__LOCALSTATIC) || /* Namespace member variable. */ - (G__struct.type[G__def_tagnum] == 'n') + (G__def_tagnum != -1 && G__struct.type[G__def_tagnum] == 'n') ) && /* Initialize const and static variables before running. */ (!G__static_alloc || G__prerun) && @@ -5955,7 +5958,7 @@ G__value G__getvariable(char* item, int* known, G__var_array* varglobal, G__var_ G__letint(&result, var->type[ig15], finalval); return result; } - if (G__decl && G__getarraydim && !G__struct_offset && (var->p[ig15] < 100)) { + if (G__decl && G__getarraydim && !G__struct_offset && ((unsigned long)var->p[ig15] < 100)) { // prevent segv in following example. A bit tricky. // void f(const int n) { int a[n]; } G__abortbytecode(); diff --git a/cint/cint/stl/G__postprocess.h b/cint/cint/stl/G__postprocess.h index c398efd31b8ec..92bffd85542e4 100644 --- a/cint/cint/stl/G__postprocess.h +++ b/cint/cint/stl/G__postprocess.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/README.txt b/cint/cint/stl/README.txt index 0f700ada1de72..b669c6751d6d0 100644 --- a/cint/cint/stl/README.txt +++ b/cint/cint/stl/README.txt @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_algorithm b/cint/cint/stl/_algorithm index d856bfbf0153b..1bbcb3dd1576d 100644 --- a/cint/cint/stl/_algorithm +++ b/cint/cint/stl/_algorithm @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_autocontainer b/cint/cint/stl/_autocontainer index d21c5f506513b..1ea467eb3ae83 100644 --- a/cint/cint/stl/_autocontainer +++ b/cint/cint/stl/_autocontainer @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_bitset b/cint/cint/stl/_bitset index 3453a3a4d9a05..78331698ded37 100644 --- a/cint/cint/stl/_bitset +++ b/cint/cint/stl/_bitset @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_climits b/cint/cint/stl/_climits index ff778efe3a3b7..1467549b3d11a 100755 --- a/cint/cint/stl/_climits +++ b/cint/cint/stl/_climits @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_climits.h b/cint/cint/stl/_climits.h index e54a8e37970c7..c38781e141ae4 100644 --- a/cint/cint/stl/_climits.h +++ b/cint/cint/stl/_climits.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_deque b/cint/cint/stl/_deque index 1fbadca54bce3..3ba099cf086ee 100644 --- a/cint/cint/stl/_deque +++ b/cint/cint/stl/_deque @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_deque.h b/cint/cint/stl/_deque.h index 533d7691b0cd7..cd333d11ada05 100644 --- a/cint/cint/stl/_deque.h +++ b/cint/cint/stl/_deque.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_functional b/cint/cint/stl/_functional index e281a6872f3cc..0ec06fede7fdb 100644 --- a/cint/cint/stl/_functional +++ b/cint/cint/stl/_functional @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_iterator b/cint/cint/stl/_iterator index 87aec62140275..3ebf6da893e92 100644 --- a/cint/cint/stl/_iterator +++ b/cint/cint/stl/_iterator @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_iterator.h b/cint/cint/stl/_iterator.h index 04a38263183ad..7cf9c2cadb0c3 100644 --- a/cint/cint/stl/_iterator.h +++ b/cint/cint/stl/_iterator.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_list b/cint/cint/stl/_list index dcc017727e5a3..7c4965fd89b92 100644 --- a/cint/cint/stl/_list +++ b/cint/cint/stl/_list @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_list.h b/cint/cint/stl/_list.h index c6ebb7fa0b831..4f68833e8a625 100644 --- a/cint/cint/stl/_list.h +++ b/cint/cint/stl/_list.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_map b/cint/cint/stl/_map index 9f41a60ffe498..08ea402aea059 100644 --- a/cint/cint/stl/_map +++ b/cint/cint/stl/_map @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_map.h b/cint/cint/stl/_map.h index 8247f506d1002..3246ba5637af5 100644 --- a/cint/cint/stl/_map.h +++ b/cint/cint/stl/_map.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_memory b/cint/cint/stl/_memory index ca3980497c902..13c893db703d4 100644 --- a/cint/cint/stl/_memory +++ b/cint/cint/stl/_memory @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_memory.h b/cint/cint/stl/_memory.h index 35db9e21e16df..a0532916d520c 100644 --- a/cint/cint/stl/_memory.h +++ b/cint/cint/stl/_memory.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_multimap b/cint/cint/stl/_multimap index a7e24d1553219..64a0e979e20ee 100644 --- a/cint/cint/stl/_multimap +++ b/cint/cint/stl/_multimap @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_multimap.h b/cint/cint/stl/_multimap.h index 094a0e3fc4266..02ca7e74dd2fa 100644 --- a/cint/cint/stl/_multimap.h +++ b/cint/cint/stl/_multimap.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_multiset b/cint/cint/stl/_multiset index 901ddcfaaa846..a0227802723f0 100644 --- a/cint/cint/stl/_multiset +++ b/cint/cint/stl/_multiset @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_multiset.h b/cint/cint/stl/_multiset.h index ba0a97a420b4c..85ac4fd4772a5 100644 --- a/cint/cint/stl/_multiset.h +++ b/cint/cint/stl/_multiset.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_pair.h b/cint/cint/stl/_pair.h index 41986ec4ab567..ee6d901428864 100644 --- a/cint/cint/stl/_pair.h +++ b/cint/cint/stl/_pair.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_set b/cint/cint/stl/_set index 4093df4c7c0fb..cf42ae4a5f8f5 100644 --- a/cint/cint/stl/_set +++ b/cint/cint/stl/_set @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_set.h b/cint/cint/stl/_set.h index fa754fc216c34..42ffc197e1910 100644 --- a/cint/cint/stl/_set.h +++ b/cint/cint/stl/_set.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_stack b/cint/cint/stl/_stack index fb6d118a0b596..ac29a91c7cd27 100644 --- a/cint/cint/stl/_stack +++ b/cint/cint/stl/_stack @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_stack.h b/cint/cint/stl/_stack.h index 8ff20c92b454e..30adf0de31a8b 100644 --- a/cint/cint/stl/_stack.h +++ b/cint/cint/stl/_stack.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_string b/cint/cint/stl/_string index d15505b5f0c47..1dc1b3f75666d 100644 --- a/cint/cint/stl/_string +++ b/cint/cint/stl/_string @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_utility b/cint/cint/stl/_utility index a5e67ac54d554..6563a1a417f53 100644 --- a/cint/cint/stl/_utility +++ b/cint/cint/stl/_utility @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_utility.h b/cint/cint/stl/_utility.h index 0d4d60b2ff751..3e69985e64350 100644 --- a/cint/cint/stl/_utility.h +++ b/cint/cint/stl/_utility.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_vector b/cint/cint/stl/_vector index 49657f5e0d72f..84424511285c6 100644 --- a/cint/cint/stl/_vector +++ b/cint/cint/stl/_vector @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/_vector.h b/cint/cint/stl/_vector.h index 2a93eeb9ac247..3089a5e587821 100644 --- a/cint/cint/stl/_vector.h +++ b/cint/cint/stl/_vector.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/algo.h b/cint/cint/stl/algo.h index cc7326f69359c..bed7c528789ba 100644 --- a/cint/cint/stl/algo.h +++ b/cint/cint/stl/algo.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/algobase.h b/cint/cint/stl/algobase.h index 12fb51b4c2d07..9b7f95e010762 100644 --- a/cint/cint/stl/algobase.h +++ b/cint/cint/stl/algobase.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/algorithm b/cint/cint/stl/algorithm index 90c2c0076c22b..f0f4ce6808c42 100644 --- a/cint/cint/stl/algorithm +++ b/cint/cint/stl/algorithm @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/bitset b/cint/cint/stl/bitset index 00098b996f5a9..70def55cbea42 100644 --- a/cint/cint/stl/bitset +++ b/cint/cint/stl/bitset @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/bool b/cint/cint/stl/bool index e8583b06b3197..6e387342b67e2 100644 --- a/cint/cint/stl/bool +++ b/cint/cint/stl/bool @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/bstring.h b/cint/cint/stl/bstring.h index a8ef0a7e5da94..f5969bccee0f0 100644 --- a/cint/cint/stl/bstring.h +++ b/cint/cint/stl/bstring.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/bvector.h b/cint/cint/stl/bvector.h index e21a11812f358..cd4e9b61ec648 100644 --- a/cint/cint/stl/bvector.h +++ b/cint/cint/stl/bvector.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/defalloc.h b/cint/cint/stl/defalloc.h index 05985f98c2fdc..1ea8498c5ba92 100644 --- a/cint/cint/stl/defalloc.h +++ b/cint/cint/stl/defalloc.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/deque b/cint/cint/stl/deque index 79ec2a82099d9..5c4d299c40b5f 100644 --- a/cint/cint/stl/deque +++ b/cint/cint/stl/deque @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/deque.h b/cint/cint/stl/deque.h index f95f6646fa381..c03ec3bf32b18 100644 --- a/cint/cint/stl/deque.h +++ b/cint/cint/stl/deque.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/faralloc.h b/cint/cint/stl/faralloc.h index abc61a81e3efb..aadffd4d75752 100644 --- a/cint/cint/stl/faralloc.h +++ b/cint/cint/stl/faralloc.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/fdeque.h b/cint/cint/stl/fdeque.h index 8c64887113083..0b6c4b7263ca2 100644 --- a/cint/cint/stl/fdeque.h +++ b/cint/cint/stl/fdeque.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/flist.h b/cint/cint/stl/flist.h index 71d5fe92b3b80..52654780dfea2 100644 --- a/cint/cint/stl/flist.h +++ b/cint/cint/stl/flist.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/fmap.h b/cint/cint/stl/fmap.h index 8739a24b34a43..62323e6cf8741 100644 --- a/cint/cint/stl/fmap.h +++ b/cint/cint/stl/fmap.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/fmultmap.h b/cint/cint/stl/fmultmap.h index 20c3dcc29f46e..86da0b260858f 100644 --- a/cint/cint/stl/fmultmap.h +++ b/cint/cint/stl/fmultmap.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/fmultset.h b/cint/cint/stl/fmultset.h index 6af3bf89856b4..785e3d4a83627 100644 --- a/cint/cint/stl/fmultset.h +++ b/cint/cint/stl/fmultset.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/fset.h b/cint/cint/stl/fset.h index 7128c82aa8e02..8638a87f2b4da 100644 --- a/cint/cint/stl/fset.h +++ b/cint/cint/stl/fset.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/function.h b/cint/cint/stl/function.h index 103c937690387..e947ec3d9c8d4 100644 --- a/cint/cint/stl/function.h +++ b/cint/cint/stl/function.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/functional b/cint/cint/stl/functional index ad04e4eca6fe1..5a6bf44d9e8c7 100644 --- a/cint/cint/stl/functional +++ b/cint/cint/stl/functional @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/hdeque.h b/cint/cint/stl/hdeque.h index 05ec2a32e393a..27c76c4db9c81 100644 --- a/cint/cint/stl/hdeque.h +++ b/cint/cint/stl/hdeque.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/heap.h b/cint/cint/stl/heap.h index 040c842427341..5218af20b3876 100644 --- a/cint/cint/stl/heap.h +++ b/cint/cint/stl/heap.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/hlist.h b/cint/cint/stl/hlist.h index 787cb3a7d68c5..2ae3848c7a925 100644 --- a/cint/cint/stl/hlist.h +++ b/cint/cint/stl/hlist.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/hmap.h b/cint/cint/stl/hmap.h index 490040fc2da20..aced06b703e88 100644 --- a/cint/cint/stl/hmap.h +++ b/cint/cint/stl/hmap.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/hmultmap.h b/cint/cint/stl/hmultmap.h index 75b90907433df..95261606b7521 100644 --- a/cint/cint/stl/hmultmap.h +++ b/cint/cint/stl/hmultmap.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/hmultset.h b/cint/cint/stl/hmultset.h index 90cf8e69fae22..23f72d316678c 100644 --- a/cint/cint/stl/hmultset.h +++ b/cint/cint/stl/hmultset.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/hset.h b/cint/cint/stl/hset.h index 47189c370aa94..5308c6c31f41b 100644 --- a/cint/cint/stl/hset.h +++ b/cint/cint/stl/hset.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/hugalloc.h b/cint/cint/stl/hugalloc.h index 8bf2c9e654551..14dc8127f8dfd 100644 --- a/cint/cint/stl/hugalloc.h +++ b/cint/cint/stl/hugalloc.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/hvector.h b/cint/cint/stl/hvector.h index 13862fbf46243..c69fd07574e86 100644 --- a/cint/cint/stl/hvector.h +++ b/cint/cint/stl/hvector.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/iterator b/cint/cint/stl/iterator index 5ad5d440f03fa..268cdf04b31d5 100644 --- a/cint/cint/stl/iterator +++ b/cint/cint/stl/iterator @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/iterator.h b/cint/cint/stl/iterator.h index 45f1da0f1468c..25849f3a21a14 100644 --- a/cint/cint/stl/iterator.h +++ b/cint/cint/stl/iterator.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/lbvector.h b/cint/cint/stl/lbvector.h index 434a53d0ce480..4fb074a4b86b4 100644 --- a/cint/cint/stl/lbvector.h +++ b/cint/cint/stl/lbvector.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/ldeque.h b/cint/cint/stl/ldeque.h index 81fddd7904fa9..8b61a04211eaa 100644 --- a/cint/cint/stl/ldeque.h +++ b/cint/cint/stl/ldeque.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/limits b/cint/cint/stl/limits index 821de166ac2de..020a39fb204b2 100644 --- a/cint/cint/stl/limits +++ b/cint/cint/stl/limits @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/list b/cint/cint/stl/list index 72a1bf10aa2d1..7d6cbcb8b0fab 100644 --- a/cint/cint/stl/list +++ b/cint/cint/stl/list @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/list.h b/cint/cint/stl/list.h index 79f64f56b6888..f4a6e3422cfc9 100644 --- a/cint/cint/stl/list.h +++ b/cint/cint/stl/list.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/llist.h b/cint/cint/stl/llist.h index 734de2ca4a882..fd415c976f458 100644 --- a/cint/cint/stl/llist.h +++ b/cint/cint/stl/llist.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/lmap.h b/cint/cint/stl/lmap.h index f0ab343bde585..a108d16f92e78 100644 --- a/cint/cint/stl/lmap.h +++ b/cint/cint/stl/lmap.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/lmultmap.h b/cint/cint/stl/lmultmap.h index 832f3c3b4ffc1..fab1d49e770d9 100644 --- a/cint/cint/stl/lmultmap.h +++ b/cint/cint/stl/lmultmap.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/lmultset.h b/cint/cint/stl/lmultset.h index 36fdbcab854d1..4f5c8da61e404 100644 --- a/cint/cint/stl/lmultset.h +++ b/cint/cint/stl/lmultset.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/lngalloc.h b/cint/cint/stl/lngalloc.h index 499fe94161e5c..40d90113818a7 100644 --- a/cint/cint/stl/lngalloc.h +++ b/cint/cint/stl/lngalloc.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/lset.h b/cint/cint/stl/lset.h index c2e24a73b3e90..4df9498a8e5b4 100644 --- a/cint/cint/stl/lset.h +++ b/cint/cint/stl/lset.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/map b/cint/cint/stl/map index 4103902f55610..61c2c5b938ec4 100644 --- a/cint/cint/stl/map +++ b/cint/cint/stl/map @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/map.h b/cint/cint/stl/map.h index dfce0e58d2ece..cfa73acca8762 100644 --- a/cint/cint/stl/map.h +++ b/cint/cint/stl/map.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/memory b/cint/cint/stl/memory index 71f17a16e5270..ea779641078c7 100644 --- a/cint/cint/stl/memory +++ b/cint/cint/stl/memory @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/multimap b/cint/cint/stl/multimap index 92c4dfbd77e8c..26955dabd34ae 100644 --- a/cint/cint/stl/multimap +++ b/cint/cint/stl/multimap @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/multimap.h b/cint/cint/stl/multimap.h index c2c4d2cb0639a..bffa1504dff71 100644 --- a/cint/cint/stl/multimap.h +++ b/cint/cint/stl/multimap.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/multiset b/cint/cint/stl/multiset index 68e6ea47c977f..002cbce9d053e 100644 --- a/cint/cint/stl/multiset +++ b/cint/cint/stl/multiset @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/multiset.h b/cint/cint/stl/multiset.h index c3ee9cf91296d..287a74c2baf2f 100644 --- a/cint/cint/stl/multiset.h +++ b/cint/cint/stl/multiset.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/neralloc.h b/cint/cint/stl/neralloc.h index 3097ba8a0ce74..9a0eb87a1e797 100644 --- a/cint/cint/stl/neralloc.h +++ b/cint/cint/stl/neralloc.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/nmap.h b/cint/cint/stl/nmap.h index c0951432f9497..d51dcb1abf50c 100644 --- a/cint/cint/stl/nmap.h +++ b/cint/cint/stl/nmap.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/nmultmap.h b/cint/cint/stl/nmultmap.h index de352cf2f8020..2a2e7fa089700 100644 --- a/cint/cint/stl/nmultmap.h +++ b/cint/cint/stl/nmultmap.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/nmultset.h b/cint/cint/stl/nmultset.h index 2427ba3bbafd2..59db703f15734 100644 --- a/cint/cint/stl/nmultset.h +++ b/cint/cint/stl/nmultset.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/nset.h b/cint/cint/stl/nset.h index 53b8d5f4f7aff..671c6576cf30a 100644 --- a/cint/cint/stl/nset.h +++ b/cint/cint/stl/nset.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/numeric b/cint/cint/stl/numeric index c89191bd8659c..ef0771de601b5 100644 --- a/cint/cint/stl/numeric +++ b/cint/cint/stl/numeric @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/pair b/cint/cint/stl/pair index aac8d70cd0e92..c47c9ac1fa44a 100644 --- a/cint/cint/stl/pair +++ b/cint/cint/stl/pair @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/pair.h b/cint/cint/stl/pair.h index 45046d6a5b21a..758610419c520 100644 --- a/cint/cint/stl/pair.h +++ b/cint/cint/stl/pair.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/projectn.h b/cint/cint/stl/projectn.h index 50e677f99820a..d04f2e553b920 100644 --- a/cint/cint/stl/projectn.h +++ b/cint/cint/stl/projectn.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/queue b/cint/cint/stl/queue index a67ba975b6309..496a8d4de9c89 100644 --- a/cint/cint/stl/queue +++ b/cint/cint/stl/queue @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/random.cpp b/cint/cint/stl/random.cpp index 0bb19592b6971..317b7a2f5b810 100644 --- a/cint/cint/stl/random.cpp +++ b/cint/cint/stl/random.cpp @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/set b/cint/cint/stl/set index 7f12d76bd7c43..1f132ec7e35af 100644 --- a/cint/cint/stl/set +++ b/cint/cint/stl/set @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/set.h b/cint/cint/stl/set.h index c4fbde4c9c1c8..5f3025fd60ecf 100644 --- a/cint/cint/stl/set.h +++ b/cint/cint/stl/set.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/stack b/cint/cint/stl/stack index 684e48f37ac9e..b48756a4562b7 100644 --- a/cint/cint/stl/stack +++ b/cint/cint/stl/stack @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/stack.h b/cint/cint/stl/stack.h index 3472b0b057a84..25379da04bd3d 100644 --- a/cint/cint/stl/stack.h +++ b/cint/cint/stl/stack.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/string b/cint/cint/stl/string index 4745157450f6c..f33b57f10f635 100644 --- a/cint/cint/stl/string +++ b/cint/cint/stl/string @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/tempbuf.cpp b/cint/cint/stl/tempbuf.cpp index bf72ce503fd3d..709997fd10bdd 100644 --- a/cint/cint/stl/tempbuf.cpp +++ b/cint/cint/stl/tempbuf.cpp @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/tempbuf.h b/cint/cint/stl/tempbuf.h index a314749802c32..690f11e1bb751 100644 --- a/cint/cint/stl/tempbuf.h +++ b/cint/cint/stl/tempbuf.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/teststl b/cint/cint/stl/teststl index ec5ce774e89a7..8d8c7acf66531 100644 --- a/cint/cint/stl/teststl +++ b/cint/cint/stl/teststl @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/teststl.c b/cint/cint/stl/teststl.c index 4f97bb5b562a4..4bc147f2294ce 100644 --- a/cint/cint/stl/teststl.c +++ b/cint/cint/stl/teststl.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/tree.h b/cint/cint/stl/tree.h index e7a52e148bc5c..b27d08e8ca134 100644 --- a/cint/cint/stl/tree.h +++ b/cint/cint/stl/tree.h @@ -2,7 +2,7 @@ /************************************************************************ * - * Copyright(c) 1995~2006 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2006 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/utility b/cint/cint/stl/utility index f9704c6d36405..a37ba4abac501 100644 --- a/cint/cint/stl/utility +++ b/cint/cint/stl/utility @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/utility.h b/cint/cint/stl/utility.h index fc25f27005dd9..f29676f39eded 100644 --- a/cint/cint/stl/utility.h +++ b/cint/cint/stl/utility.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/valarray b/cint/cint/stl/valarray index 5155632b9aea3..891906fe28872 100644 --- a/cint/cint/stl/valarray +++ b/cint/cint/stl/valarray @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/vector b/cint/cint/stl/vector index 050cd0fc3cd89..e65c2dc344bfa 100644 --- a/cint/cint/stl/vector +++ b/cint/cint/stl/vector @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cint/stl/vector.h b/cint/cint/stl/vector.h index f49be08e6fa2e..19c20c532d914 100644 --- a/cint/cint/stl/vector.h +++ b/cint/cint/stl/vector.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/cintex/CMakeLists.txt b/cint/cintex/CMakeLists.txt index 0ec6483bbd73f..b81d661950636 100644 --- a/cint/cintex/CMakeLists.txt +++ b/cint/cintex/CMakeLists.txt @@ -11,8 +11,8 @@ ROOT_GENERATE_ROOTMAP(Cintex LINKDEF LinkDef.h DEPENDENCIES Reflex) #---Install python modules-------------------------------------------------- install(FILES python/PyCintex.py DESTINATION ${runtimedir}) -install(CODE "execute_process(COMMAND python -m py_compile ${CMAKE_INSTALL_PREFIX}/${runtimedir}/PyCintex.py )") -install(CODE "execute_process(COMMAND python -O -m py_compile ${CMAKE_INSTALL_PREFIX}/${runtimedir}/PyCintex.py )") +install(CODE "execute_process(COMMAND python -m py_compile \$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${runtimedir}/PyCintex.py )") +install(CODE "execute_process(COMMAND python -O -m py_compile \$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${runtimedir}/PyCintex.py )") #---install headers---------------------------------------------------------- ROOT_INSTALL_HEADERS() diff --git a/cint/cintex/python/PyCintex.py b/cint/cintex/python/PyCintex.py index 6b736d5042908..a925115fd23bb 100644 --- a/cint/cintex/python/PyCintex.py +++ b/cint/cintex/python/PyCintex.py @@ -45,7 +45,14 @@ def __init__( self, name ): self.__name__ = name def __call__( self, *args ): name = self.__name__[ 0 <= self.__name__.find( 'std::' ) and 5 or 0:] - return libPyROOT.MakeRootTemplateClass( name, *args ) + result = libPyROOT.MakeRootTemplateClass( name, *args ) + # special case pythonization (builtin_map is not available from the C-API) + if hasattr( result, 'push_back' ): + def iadd( self, ll ): + [ self.push_back(x) for x in ll ] + return self + result.__iadd__ = iadd + return result sys.modules[ 'libPyROOT' ].Template = Template diff --git a/cint/cintex/src/CINTTypedefBuilder.cxx b/cint/cintex/src/CINTTypedefBuilder.cxx index cb03474b026af..8f6ba762fc7cf 100644 --- a/cint/cintex/src/CINTTypedefBuilder.cxx +++ b/cint/cintex/src/CINTTypedefBuilder.cxx @@ -39,6 +39,8 @@ namespace ROOT { static std::set exclusionList; if (!init) { exclusionList.insert("stringstream"); + exclusionList.insert("Double32_t"); + exclusionList.insert("Float16_t"); init = true; } if ( exclusionList.find(nam) != exclusionList.end() ) { diff --git a/cint/cintex/src/Cintex.cxx b/cint/cintex/src/Cintex.cxx index 52ea93d0542f7..92f59d20760fe 100644 --- a/cint/cintex/src/Cintex.cxx +++ b/cint/cintex/src/Cintex.cxx @@ -37,9 +37,11 @@ namespace { Cintex_dict_t() { //--Reflex class builder //NamespaceBuilder( "ROOT::Cintex" ); - Type t_void = TypeBuilder("void"); - Type t_int = TypeBuilder("int"); - Type t_bool = TypeBuilder("bool"); + Type t_void = TypeBuilder(Literal("void")); + Type t_int = TypeBuilder(Literal("int")); + Type t_bool = TypeBuilder(Literal("bool")); + Type t_double = TypeBuilder(Literal("double")); + Type t_double32 = TypedefTypeBuilder(Literal("Double32_t"), t_double); ClassBuilderT< Cintex >("Cintex", PUBLIC) .AddFunctionMember(FunctionTypeBuilder(t_void), "Enable", Enable, 0, 0, PUBLIC | STATIC) .AddFunctionMember(FunctionTypeBuilder(t_void, t_int), "SetDebug", SetDebug, 0, 0, PUBLIC | STATIC) diff --git a/cint/cintex/src/ROOTClassEnhancer.cxx b/cint/cintex/src/ROOTClassEnhancer.cxx index 5f2a67910d8fc..08b91fa407076 100644 --- a/cint/cintex/src/ROOTClassEnhancer.cxx +++ b/cint/cintex/src/ROOTClassEnhancer.cxx @@ -15,6 +15,7 @@ #include "Cintex/Cintex.h" #include "TROOT.h" #include "TClass.h" +#include "TClassAttributeMap.h" #include "TClassEdit.h" #include "TClassTable.h" #include "TClassStreamer.h" @@ -33,6 +34,7 @@ #include #include +#include #if ROOT_VERSION_CODE >= ROOT_VERSION(5,1,1) #include "TVirtualIsAProxy.h" @@ -394,6 +396,7 @@ namespace ROOT { namespace Cintex { TClass* ROOTClassEnhancerInfo::Default_CreateClass( Type typ, ROOT::TGenericClassInfo* info) { // Create root class. + TClass* root_class = 0; std::string Name = typ.Name(SCOPED); int kind = TClassEdit::IsSTLCont(Name.c_str()); @@ -442,7 +445,13 @@ namespace ROOT { namespace Cintex { m->destruct_func, m->feed_func, m->collect_func, - m->create_env); + m->create_env, + m->fCreateIterators, + m->fCopyIterator, + m->fNext, + m->fDeleteSingleIterator, + m->fDeleteTwoIterators + ); root_class->SetCollectionProxy(cpinfo); root_class->SetBit(TClass::kIsForeign); @@ -455,6 +464,26 @@ namespace ROOT { namespace Cintex { root_class->SetBit(TClass::kIsForeign); } } + // Add the class properties. + PropertyList properties = typ.Properties(); + if (properties) { + size_t noProperties = properties.KeySize(); + // Add the properties to the map, if any. + if (noProperties > 0) { + //Create the attribute map. + root_class->CreateAttributeMap(); + TClassAttributeMap* attrMap = root_class->GetAttributeMap(); + for (size_t i = 1; i < noProperties; ++i) { + // Check if the property is exists and is valid. + if (properties.HasProperty(i)) { + // Get the String value of the property. + std::string stringValue = properties.PropertyAsString(i); + // Add the property to the map. + attrMap->AddProperty(properties.KeyAt(i).c_str(), stringValue.c_str()); + } + } + } + } // end of class has properties } return root_class; } diff --git a/cint/cintex/test/dict/CintexTest.h b/cint/cintex/test/dict/CintexTest.h index d02464e5e248d..012bd7a3a5ffc 100644 --- a/cint/cintex/test/dict/CintexTest.h +++ b/cint/cintex/test/dict/CintexTest.h @@ -181,8 +181,8 @@ class Calling { MyClass& retByReference() { return m_object; } MyClass*& retByRefPointer() { return m_ptr; } void* retByVoidPointer() { return &m_object; } - UnknownType* retUnkownTypePointer() { return (UnknownType*)0x12345678; } - UnknownType& retUnkownTypeReference() { return *(UnknownType*)0x12345678; } + UnknownType* retUnknownTypePointer() { return (UnknownType*)0x12345678; } + UnknownType& retUnknownTypeReference() { return *(UnknownType*)0x12345678; } std::string retStrByValue() { return std::string("value");} std::string& retStrByRef() { static std::string s("reference");return s;} const std::string& retStrByConstRef() { static std::string s("const reference");return s;} diff --git a/cint/cintex/test/test_Cintex.C b/cint/cintex/test/test_Cintex.C index 2f0fef8031106..fe4a21a5a3487 100644 --- a/cint/cintex/test/test_Cintex.C +++ b/cint/cintex/test/test_Cintex.C @@ -101,9 +101,9 @@ bool test_ReturnModes() { bool test_UnknownTypes() { A::B::C::Calling calling; //---Returning unknown types - void* rp = calling.retUnkownTypePointer(); + void* rp = calling.retUnknownTypePointer(); failUnless( rp ); - void* rr = (void*)&(calling.retUnkownTypeReference()); + void* rr = (void*)&(calling.retUnknownTypeReference()); failUnless( rr ); //---Passing unknown types failUnlessEqual( calling.setByUnknownTypePointer(rp), 0x12345678); diff --git a/cint/cintex/test/test_PyCintex_basics.py b/cint/cintex/test/test_PyCintex_basics.py index bb51c4d214e87..5eb89e2954c72 100644 --- a/cint/cintex/test/test_PyCintex_basics.py +++ b/cint/cintex/test/test_PyCintex_basics.py @@ -101,9 +101,9 @@ def test03ReturnModes(self): def test04UnknownTypes(self) : calling = self.A.B.C.Calling() #---Returning unknown types - rp = calling.retUnkownTypePointer() + rp = calling.retUnknownTypePointer() self.failUnless( rp ) - rr = calling.retUnkownTypeReference() + rr = calling.retUnknownTypeReference() self.failUnless( rr ) #---Passing unknown types self.failUnlessEqual( calling.setByUnknownTypePointer(rp), 0x12345678) diff --git a/cint/cling/test/CMakeLists.txt b/cint/cling/test/CMakeLists.txt index 470f94aafe7f4..47b01b6f240da 100644 --- a/cint/cling/test/CMakeLists.txt +++ b/cint/cling/test/CMakeLists.txt @@ -1,95 +1,95 @@ -set(CLING_TEST_DIRECTORIES - "ErrorRecovery" - "Extensions" - "LibraryCall" - "Prompt" - "Recursion" - "SourceCall") - -set(LLVM_SOURCE_DIR "${LLVM_MAIN_SRC_DIR}") -set(LLVM_BINARY_DIR "${LLVM_BINARY_DIR}") -set(LLVM_BUILD_MODE "%(build_mode)s") -set(LLVM_TOOLS_DIR "${LLVM_TOOLS_BINARY_DIR}/%(build_config)s") -set(LLVM_LIBS_DIR "${LLVM_BINARY_DIR}/lib/%(build_config)s") -set(CLING_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/..") -set(CLING_BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/..") -if(BUILD_SHARED_LIBS) - set(ENABLE_SHARED 1) -else() - set(ENABLE_SHARED 0) -endif(BUILD_SHARED_LIBS) - -configure_file( - ${CMAKE_CURRENT_SOURCE_DIR}/lit.site.cfg.in - ${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg) - -#configure_file( -# ${CMAKE_CURRENT_SOURCE_DIR}/Unit/lit.site.cfg.in -# ${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg -# @ONLY) - -include(FindPythonInterp) -if(PYTHONINTERP_FOUND) - if( LLVM_MAIN_SRC_DIR ) - set(LIT "${LLVM_SOURCE_DIR}/utils/lit/lit.py") - else() - set(LIT "${PATH_TO_LLVM_BUILD}/bin/${CMAKE_CFG_INTDIR}/llvm-lit") - # Installed LLVM does not contain ${CMAKE_CFG_INTDIR} in paths. - if( NOT EXISTS ${LIT} ) - set(LIT "${PATH_TO_LLVM_BUILD}/bin/llvm-lit") - endif() - endif() - - if( PATH_TO_LLVM_BUILD ) - set(CLING_TEST_EXTRA_ARGS "--path=${CLING_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}") - endif() - - option(CLING_TEST_USE_VG "Run Cling tests under Valgrind" OFF) - if(CLING_TEST_USE_VG) - set(CLING_TEST_EXTRA_ARGS ${CLING_TEST_EXTRA_ARGS} "--vg") - endif () - - set(LIT_ARGS "${CLING_TEST_EXTRA_ARGS} ${LLVM_LIT_ARGS}") - separate_arguments(LIT_ARGS) - - add_custom_target(cling-test.deps) - set_target_properties(cling-test.deps PROPERTIES FOLDER "Cling tests") - - add_custom_target(cling-test - COMMAND ${PYTHON_EXECUTABLE} - ${LIT} - --param claig_site_config=${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg - --param cling_unit_site_config=${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg - --param build_config=${CMAKE_CFG_INTDIR} - --param build_mode=${RUNTIME_BUILD_MODE} - ${LIT_ARGS} - ${CMAKE_CURRENT_BINARY_DIR} - COMMENT "Running Cling regression tests") - -# if( NOT CLING_BUILT_STANDALONE ) -# add_custom_target(check-all -# COMMAND ${PYTHON_EXECUTABLE} -# ${LIT} -# --param build_config=${CMAKE_CFG_INTDIR} -# --param build_mode=${RUNTIME_BUILD_MODE} -# ${LIT_ARGS} -# ${LLVM_BINARY_DIR}/test -# ${CMAKE_CURRENT_BINARY_DIR} -# COMMENT "Running Cling and LLVM regression tests") -# add_dependencies(check-all cling-test.deps) -# if ( LLVM_INCLUDE_TESTS ) -# add_dependencies(cling-test.deps ClangUnitTests) -# add_dependencies(check-all check.deps) -# endif ( LLVM_INCLUDE_TESTS ) -# add_dependencies(cling-test.deps -# llvm-dis llc opt -# FileCheck count not -# ) -# endif() - - add_dependencies(cling-test cling-test.deps) - add_dependencies(cling-test.deps - cling cling-headers c-index-test diagtool arcmt-test c-arcmt-test - ) - -endif() +set(CLING_TEST_DIRECTORIES + "ErrorRecovery" + "Extensions" + "LibraryCall" + "Prompt" + "Recursion" + "SourceCall") + +set(LLVM_SOURCE_DIR "${LLVM_MAIN_SRC_DIR}") +set(LLVM_BINARY_DIR "${LLVM_BINARY_DIR}") +set(LLVM_BUILD_MODE "%(build_mode)s") +set(LLVM_TOOLS_DIR "${LLVM_TOOLS_BINARY_DIR}/%(build_config)s") +set(LLVM_LIBS_DIR "${LLVM_BINARY_DIR}/lib/%(build_config)s") +set(CLING_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/..") +set(CLING_BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/..") +if(BUILD_SHARED_LIBS) + set(ENABLE_SHARED 1) +else() + set(ENABLE_SHARED 0) +endif(BUILD_SHARED_LIBS) + +configure_file( + ${CMAKE_CURRENT_SOURCE_DIR}/lit.site.cfg.in + ${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg) + +#configure_file( +# ${CMAKE_CURRENT_SOURCE_DIR}/Unit/lit.site.cfg.in +# ${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg +# @ONLY) + +include(FindPythonInterp) +if(PYTHONINTERP_FOUND) + if( LLVM_MAIN_SRC_DIR ) + set(LIT "${LLVM_SOURCE_DIR}/utils/lit/lit.py") + else() + set(LIT "${PATH_TO_LLVM_BUILD}/bin/${CMAKE_CFG_INTDIR}/llvm-lit") + # Installed LLVM does not contain ${CMAKE_CFG_INTDIR} in paths. + if( NOT EXISTS ${LIT} ) + set(LIT "${PATH_TO_LLVM_BUILD}/bin/llvm-lit") + endif() + endif() + + if( PATH_TO_LLVM_BUILD ) + set(CLING_TEST_EXTRA_ARGS "--path=${CLING_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}") + endif() + + option(CLING_TEST_USE_VG "Run Cling tests under Valgrind" OFF) + if(CLING_TEST_USE_VG) + set(CLING_TEST_EXTRA_ARGS ${CLING_TEST_EXTRA_ARGS} "--vg") + endif () + + set(LIT_ARGS "${CLING_TEST_EXTRA_ARGS} ${LLVM_LIT_ARGS}") + separate_arguments(LIT_ARGS) + + add_custom_target(cling-test.deps) + set_target_properties(cling-test.deps PROPERTIES FOLDER "Cling tests") + + add_custom_target(cling-test + COMMAND ${PYTHON_EXECUTABLE} + ${LIT} + --param claig_site_config=${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg + --param cling_unit_site_config=${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg + --param build_config=${CMAKE_CFG_INTDIR} + --param build_mode=${RUNTIME_BUILD_MODE} + ${LIT_ARGS} + ${CMAKE_CURRENT_BINARY_DIR} + COMMENT "Running Cling regression tests") + +# if( NOT CLING_BUILT_STANDALONE ) +# add_custom_target(check-all +# COMMAND ${PYTHON_EXECUTABLE} +# ${LIT} +# --param build_config=${CMAKE_CFG_INTDIR} +# --param build_mode=${RUNTIME_BUILD_MODE} +# ${LIT_ARGS} +# ${LLVM_BINARY_DIR}/test +# ${CMAKE_CURRENT_BINARY_DIR} +# COMMENT "Running Cling and LLVM regression tests") +# add_dependencies(check-all cling-test.deps) +# if ( LLVM_INCLUDE_TESTS ) +# add_dependencies(cling-test.deps ClangUnitTests) +# add_dependencies(check-all check.deps) +# endif ( LLVM_INCLUDE_TESTS ) +# add_dependencies(cling-test.deps +# llvm-dis llc opt +# FileCheck count not +# ) +# endif() + + add_dependencies(cling-test cling-test.deps) + add_dependencies(cling-test.deps + cling cling-headers c-index-test diagtool arcmt-test c-arcmt-test + ) + +endif() diff --git a/cint/cling/www/contact.html b/cint/cling/www/contact.html index 13330d2947f96..e61ea6bb8e183 100644 --- a/cint/cling/www/contact.html +++ b/cint/cling/www/contact.html @@ -1,109 +1,109 @@ - - - - - Cling Website - Get Involved - - - - - - - - - -
- - -
- -
- -

Get Involved

-

Where are we

-

You can find us at: rootdev [at] root.cern.ch

-

File a bug

-

If there is something wrong please check our bug database here and submit the bug description if it doesn't exist

-

Open tasks

-

We have lots of ideas how to make cling better, but we don't have enough time for realizing them all. Here are tasks that are on our todo lists since a while, but we still cannot manage to get them done. They are not difficult to implement and excellent for getting to know cling. If you find something interesting, please go ahead and get your hands dirty!

-
    The list is prioritized in descending order: -
  • Windows support - By design cling needs __cxa_atexit and __dso_handle to be present. In Linux for example they are defined in libc. However, Windows doesn't fully support Itanium C++ ABI and there is no definition for it.
  • -
  • Extending and improving the multiline input mode - The multiline mode has to figure out automatically whether the user's input is still incomplete. For example "if (a < 0) {" is not fully completed input. Cling should'n try to process the line but to be smart enough to understand that it should wait for continuation. Currently cling switches multiline mode only when there is trailing "{". It has to be extended to detect trailing +, unbalanced '," and so on.
  • -
  • Implementing auto completion - Clang has good interface for autocompletion which proposes possible completion options considering the current input.
  • -
  • Implementing error recovery verifier - One of the most important parts in cling is the error recovery. The error recovery takes care of reverting clang's internal structures on error in the user input. For instance, user types int i; error_here;. int i should be reverted and the entire input should be invalidated. This is very complex because many implicit template instantiations could be triggered and so on. The idea of the future verifier is to serialize the AST with all the lookup structures (probably in pch or pcm), trigger an error causing a lot of things to happen in clang internally and serialize the new AST. The comparison with the old one must return perfect match.
  • -
  • Enabling clang's static analyzer - coming soon
  • -
  • Enabling ObjectiveC/ObjectiveC++ support - coming soon
  • -
-
-
- -
- - + + + + + Cling Website - Get Involved + + + + + + + + + +
+ + +
+ +
+ +

Get Involved

+

Where are we

+

You can find us at: rootdev [at] root.cern.ch

+

File a bug

+

If there is something wrong please check our bug database here and submit the bug description if it doesn't exist

+

Open tasks

+

We have lots of ideas how to make cling better, but we don't have enough time for realizing them all. Here are tasks that are on our todo lists since a while, but we still cannot manage to get them done. They are not difficult to implement and excellent for getting to know cling. If you find something interesting, please go ahead and get your hands dirty!

+
    The list is prioritized in descending order: +
  • Windows support - By design cling needs __cxa_atexit and __dso_handle to be present. In Linux for example they are defined in libc. However, Windows doesn't fully support Itanium C++ ABI and there is no definition for it.
  • +
  • Extending and improving the multiline input mode - The multiline mode has to figure out automatically whether the user's input is still incomplete. For example "if (a < 0) {" is not fully completed input. Cling should'n try to process the line but to be smart enough to understand that it should wait for continuation. Currently cling switches multiline mode only when there is trailing "{". It has to be extended to detect trailing +, unbalanced '," and so on.
  • +
  • Implementing auto completion - Clang has good interface for autocompletion which proposes possible completion options considering the current input.
  • +
  • Implementing error recovery verifier - One of the most important parts in cling is the error recovery. The error recovery takes care of reverting clang's internal structures on error in the user input. For instance, user types int i; error_here;. int i should be reverted and the entire input should be invalidated. This is very complex because many implicit template instantiations could be triggered and so on. The idea of the future verifier is to serialize the AST with all the lookup structures (probably in pch or pcm), trigger an error causing a lot of things to happen in clang internally and serialize the new AST. The comparison with the old one must return perfect match.
  • +
  • Enabling clang's static analyzer - coming soon
  • +
  • Enabling ObjectiveC/ObjectiveC++ support - coming soon
  • +
+
+
+ +
+ + diff --git a/cint/cling/www/docs.html b/cint/cling/www/docs.html index df7b10e485b31..6f4b3f9192b17 100644 --- a/cint/cling/www/docs.html +++ b/cint/cling/www/docs.html @@ -1,111 +1,111 @@ - - - - - Cling Website - - - - - - - - - -
- - -
- - -
- -
- - + + + + + Cling Website + + + + + + + + + +
+ + +
+ + +
+ +
+ + diff --git a/cint/cling/www/docs/internal/doxygen.html b/cint/cling/www/docs/internal/doxygen.html index ce4f53c756acf..5cd38a6f85559 100644 --- a/cint/cling/www/docs/internal/doxygen.html +++ b/cint/cling/www/docs/internal/doxygen.html @@ -1,107 +1,107 @@ - - - - - Cling Documentation - Doxygen - - - - - - - - - - -
- - -
- -
- -

Doxygen

-

- Doxygen is a software documentation generator system for multiple programming languages. It can generate documentation in different formats (such as HTML, Latex, RTF, PostScript). The documentation tool is useful for the developers, because the documentation is inlined in the source code, which makes it easy to keep in sync with the new revisions of the project. It walks up the source files and even there is no documentation provided it can generate description in terms of UML diagrams - particularly useful when dealing with large codebases. -

-

- Cling has online doxygen documentation that could be found here -

-

- If you want to be able to browse offline the doxygen documentation you can build your own with: -

cd CLING_BUILD_DIR/docs/
-make regendoc
-

-
-
- -
- - + + + + + Cling Documentation - Doxygen + + + + + + + + + + +
+ + +
+ +
+ +

Doxygen

+

+ Doxygen is a software documentation generator system for multiple programming languages. It can generate documentation in different formats (such as HTML, Latex, RTF, PostScript). The documentation tool is useful for the developers, because the documentation is inlined in the source code, which makes it easy to keep in sync with the new revisions of the project. It walks up the source files and even there is no documentation provided it can generate description in terms of UML diagrams - particularly useful when dealing with large codebases. +

+

+ Cling has online doxygen documentation that could be found here +

+

+ If you want to be able to browse offline the doxygen documentation you can build your own with: +

cd CLING_BUILD_DIR/docs/
+make regendoc
+

+
+
+ +
+ + diff --git a/cint/cling/www/docs/internal/extensions.html b/cint/cling/www/docs/internal/extensions.html index da0d62ced9f9d..bfbcd9d205f47 100644 --- a/cint/cling/www/docs/internal/extensions.html +++ b/cint/cling/www/docs/internal/extensions.html @@ -1,108 +1,108 @@ - - - - - Cling Documentation - Extensions - - - - - - - - - - -
- - -
- -
- -

Extensions

-

- Cling has several additional features. The main reason for their implementation is to improve the interactivity of the prompt. We call them language extensions. -

-
    For instance, language extensions are: -
  • Execution of statements and expressions on the fly - From user's point of view it would make much sense if functions could be called by typing the function name at the prompt. This is true for other handy operations like creation of objects. However, the operations that do it are classified as statements and expressions, entered on the global scope. Statements and expressions on the global scope are not allowed by the C/C++/ObjC/ObjC++ grammar. Cling's prompt allows entering statements and expression on the global scope as transforming them into proper language constructs.
  • -
  • Easy print out of the execution results - The way of signaling that the user wants to see the result of the entered and executed code is done by omitting the semicolon in the end. The standard doesn't allow statements (except those that change the control flow - such as if, for, while) without semicolon (;) in the end. However, this appears to be really simple and useful language extension that improves the user-cling interplay. Imagine if you had to write printf every time that you want to see the result of a function call.
  • -
-
- See Also: -
- - -
-
- -
- - + + + + + Cling Documentation - Extensions + + + + + + + + + + +
+ + +
+ +
+ +

Extensions

+

+ Cling has several additional features. The main reason for their implementation is to improve the interactivity of the prompt. We call them language extensions. +

+
    For instance, language extensions are: +
  • Execution of statements and expressions on the fly - From user's point of view it would make much sense if functions could be called by typing the function name at the prompt. This is true for other handy operations like creation of objects. However, the operations that do it are classified as statements and expressions, entered on the global scope. Statements and expressions on the global scope are not allowed by the C/C++/ObjC/ObjC++ grammar. Cling's prompt allows entering statements and expression on the global scope as transforming them into proper language constructs.
  • +
  • Easy print out of the execution results - The way of signaling that the user wants to see the result of the entered and executed code is done by omitting the semicolon in the end. The standard doesn't allow statements (except those that change the control flow - such as if, for, while) without semicolon (;) in the end. However, this appears to be really simple and useful language extension that improves the user-cling interplay. Imagine if you had to write printf every time that you want to see the result of a function call.
  • +
+
+ See Also: +
+ + +
+
+ +
+ + diff --git a/cint/cling/www/download.html b/cint/cling/www/download.html index 6f16cb006b34d..caba143f7ffe0 100644 --- a/cint/cling/www/download.html +++ b/cint/cling/www/download.html @@ -1,186 +1,186 @@ - - - - - Cling Download - - - - - - - - -
- - -
- -
- -

Download & Build Instructions

-

This page is shows how to download and build the project cling as a standalone C++ interpreter in few steps

-
If you want to download and build cling within ROOT please follow the tutorial here
-

Build

-

Unix systems

- - -
    -
  1. - Checkout LLVM: -
    svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm/src
    -
  2. -
  3. - Checkout Clang: -
    cd llvm/src/tools/
    -svn co http://llvm.org/svn/llvm-project/cfe/trunk clang
    -
  4. -
  5. - Checkout Cling (next to clang): -
    svn co http://root.cern.ch/svn/root/branches/dev/cling cling
    -
  6. -
  7. - Allow Cling to hook into LLVM's build system: -
    cat tools/cling/patches/*.diff | patch -p0
    -
    -
  8. -
  9. - Configure in your build folder (preferably out of the source code). For example: -
    cd ../../obj
    -../src/configure --prefix=Where\to\be\installed\
    -
    -
  10. -
  11. - Now compile and install: -
    make && make install
    -
  12. -
- -

The executables could be found in your installation folder. -

- -

Using Visual Studio

-
    Prerequisites -
  • Subversion client - http://subversion.tigris.org/getting.html
  • -
  • cmake - http://www.cmake.org/cmake/resources/software.html
  • -
  • Python - http://www.python.org/download/
  • -
  • GnuWin32 Tools - http://getgnuwin32.sourceforge.net/
  • -
  • Visual Studio - VS Express should work as well
  • -
-
    -
  1. - Checkout LLVM -
    svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm/src/
    -
  2. -
  3. - Checkout Clang -
    cd llvm\src\tools\
    -svn co http://llvm.org/svn/llvm-project/cfe/trunk clang
    -
  4. -
  5. - Checkout Cling (next to Clang) -
    -svn co http://root.cern.ch/svn/root/branches/dev/cling cling
    -
  6. -
  7. - Allow Cling to hook into LLVM's build system: apply the two patches located in the cling\patches folder. -
  8. -
  9. - Open up cmake and enter the path to the 'src' folder in the 'Where is the source code' field and the path to the 'build' folder in the 'Where to build the binaries' field (mkdir llvm\obj - next to src). -
  10. -
  11. - Click the Configure button and in the newly popped up window choose Visual Studio version that you have, then click Finish. -
  12. -
  13. - After the configuring completes many red entries should appear in the Cmake window. You may want to change CMAKE_INSTALL_PREFIX to 'inst' (next to next to src and obj, otherwise the default is Program Files). Click Generate.
    Note: You may have to do it twice (on 2.8.5) in case after clicking Generate the box is still red. -
  14. -
  15. - Navigate to your 'build' folder and open LLVM.sln using Visual Studio and build it. -
  16. -
  17. - Navigate to CMakePredefined project in Visual Studio and right click INSTALL. Choose Project Only -> Build only INSTALL. -
  18. -
-

The executables could be found in your CMAKE_INSTALL_PREFIX/bin/ -

-

More information about cmake in LLVM and Clang could be found here and here. -

-
-
- -
- - + + + + + Cling Download + + + + + + + + +
+ + +
+ +
+ +

Download & Build Instructions

+

This page is shows how to download and build the project cling as a standalone C++ interpreter in few steps

+
If you want to download and build cling within ROOT please follow the tutorial here
+

Build

+

Unix systems

+ + +
    +
  1. + Checkout LLVM: +
    svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm/src
    +
  2. +
  3. + Checkout Clang: +
    cd llvm/src/tools/
    +svn co http://llvm.org/svn/llvm-project/cfe/trunk clang
    +
  4. +
  5. + Checkout Cling (next to clang): +
    svn co http://root.cern.ch/svn/root/branches/dev/cling cling
    +
  6. +
  7. + Allow Cling to hook into LLVM's build system: +
    cat tools/cling/patches/*.diff | patch -p0
    +
    +
  8. +
  9. + Configure in your build folder (preferably out of the source code). For example: +
    cd ../../obj
    +../src/configure --prefix=Where\to\be\installed\
    +
    +
  10. +
  11. + Now compile and install: +
    make && make install
    +
  12. +
+ +

The executables could be found in your installation folder. +

+ +

Using Visual Studio

+
    Prerequisites +
  • Subversion client - http://subversion.tigris.org/getting.html
  • +
  • cmake - http://www.cmake.org/cmake/resources/software.html
  • +
  • Python - http://www.python.org/download/
  • +
  • GnuWin32 Tools - http://getgnuwin32.sourceforge.net/
  • +
  • Visual Studio - VS Express should work as well
  • +
+
    +
  1. + Checkout LLVM +
    svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm/src/
    +
  2. +
  3. + Checkout Clang +
    cd llvm\src\tools\
    +svn co http://llvm.org/svn/llvm-project/cfe/trunk clang
    +
  4. +
  5. + Checkout Cling (next to Clang) +
    +svn co http://root.cern.ch/svn/root/branches/dev/cling cling
    +
  6. +
  7. + Allow Cling to hook into LLVM's build system: apply the two patches located in the cling\patches folder. +
  8. +
  9. + Open up cmake and enter the path to the 'src' folder in the 'Where is the source code' field and the path to the 'build' folder in the 'Where to build the binaries' field (mkdir llvm\obj - next to src). +
  10. +
  11. + Click the Configure button and in the newly popped up window choose Visual Studio version that you have, then click Finish. +
  12. +
  13. + After the configuring completes many red entries should appear in the Cmake window. You may want to change CMAKE_INSTALL_PREFIX to 'inst' (next to next to src and obj, otherwise the default is Program Files). Click Generate.
    Note: You may have to do it twice (on 2.8.5) in case after clicking Generate the box is still red. +
  14. +
  15. + Navigate to your 'build' folder and open LLVM.sln using Visual Studio and build it. +
  16. +
  17. + Navigate to CMakePredefined project in Visual Studio and right click INSTALL. Choose Project Only -> Build only INSTALL. +
  18. +
+

The executables could be found in your CMAKE_INSTALL_PREFIX/bin/ +

+

More information about cmake in LLVM and Clang could be found here and here. +

+
+
+ +
+ + diff --git a/cint/cling/www/index.html b/cint/cling/www/index.html index 8182b9e03f951..22ee709a1734c 100644 --- a/cint/cling/www/index.html +++ b/cint/cling/www/index.html @@ -1,164 +1,164 @@ - - - - - Cling Website - - - - - - - - - -
- - -
- -
- -

Cling

-

- Welcome to our interactive C++ interpreter, built on the top of LLVM and Clang libraries. Its advantages over the standard interpreters are that it has command line prompt and uses just-in-time (JIT) compiler for compilation. An interactive prompt is usually referred to as a read eval print loop or repl. Many of the developers (e.g. Mono in their project called CSharpRepl) of such kind of software applications name them interactive compilers. -

-

- One of Cling's main goals is to provide contemporary, high-performance alternative of the current C++ interpreter in the ROOT project - CINT. The backward-compatibility with CINT is major priority during the development. -

-

How to use it

-

You can start typing not only C++ top level declaratons but statements, too.

-
**** Welcome to the cling prototype! ****
-* Type C code and press enter to run it *
-* Type .q, exit or ctrl+D to quit       *
-*****************************************
-[cling]$
-

- Statements and expressions could take more than one input line. The interactive prompt changes from "[cling]$" to "[cling]$ ?". -

-
[cling]$ #include "math.h"
-[cling]$ #include "stdio.h"
-[cling]$ for (unsigned i = 0; i < 5; ++i) {
-[cling]$ ?   printf("%f\n", sin(i));
-[cling]$ ?   }
-0.000000
-0.841471
-0.909297
-0.141120
--0.756802
-

Grammar

-

Cling is able to parse everything that clang can. Current clang status can be found here. At the moment, there are use cases only for C++ that's why cling is best in working with C++. Clang has support of C, objC, objC++ and we are looking forward to having more use-cases and extend our tool in that direction.

-
    Cling has internal commands, which can change its behavior at runtime. Those commands usually start with dot (.): -
  • .I <path> - Adds an include path;
  • -
  • .x <filename> - #include-s the filename; and calls function called filename();
  • -
  • .L <libname> - Loads libname or #include-s the libname if libname is file;
  • -
  • .@ - Cancels the multiline input;
  • -
  • .printAST - (DEBUG ONLY) Turns on the printing of the compiler's abstract syntax tree (AST);
  • -
  • .dynamicExtensions - Turns on cling's dynamic extensions. This in turn enables the dynamic lookup and the late resolving of the identifier. With that option cling tries to heal the compile-time failed lookups at runtime;
  • -
- -

Details

-

Command line

-

- The interactive prompt supports an emacs-like command line editor, just like bash terminal, which makes it easy to integrate and use. Cling uses TextInput and doesn't depend on ncurses. -

-

- Autocompletion should be coming soon! -

-

#Include Declarations

-

- Cling allows #include-s to be not only before the declarations. The includes could be mixed with other declarations. For example: -

[cling]$ #include "math.h"
-[cling]$ sin(1)
-(double const) 8.414710e-01
-[cling]$ #include "stdio.h"
-[cling]$ printf("%f\n", sin(1));
-0.841471
-

-

- More statements could be combined using semicolon (;). This doesn't stay when the command is #include - The following example is invalid:

[cling]$ #include "math.h"; sin(1)
-

-

- The same rules are applicable for the other preprocessor directives (commands starting with # - such as #define) -

-

Variable Declarations

-

- Cling allows statements to be entered onto the global scope. In order to be compiled and executed by the compiler these statements need to be wrapped into functions, which body contains the statement and afterwards to run the function. The semantics of the statements that declare variables is that variables should be accessed by other statements. If the statement that declare variable is wrapped into function the variables won't be accessible from outside anymore. In this case variables are extracted onto the global scope. -

-

TODO: There should be dedicated entry for that in the docs

-

Builtins

- Cling starts with very few builtins loaded. Users could extend the available builtins via extending the RuntimeUniverse.h, which is loaded at cling's startup. -
-
- -
- - + + + + + Cling Website + + + + + + + + + +
+ + +
+ +
+ +

Cling

+

+ Welcome to our interactive C++ interpreter, built on the top of LLVM and Clang libraries. Its advantages over the standard interpreters are that it has command line prompt and uses just-in-time (JIT) compiler for compilation. An interactive prompt is usually referred to as a read eval print loop or repl. Many of the developers (e.g. Mono in their project called CSharpRepl) of such kind of software applications name them interactive compilers. +

+

+ One of Cling's main goals is to provide contemporary, high-performance alternative of the current C++ interpreter in the ROOT project - CINT. The backward-compatibility with CINT is major priority during the development. +

+

How to use it

+

You can start typing not only C++ top level declaratons but statements, too.

+
**** Welcome to the cling prototype! ****
+* Type C code and press enter to run it *
+* Type .q, exit or ctrl+D to quit       *
+*****************************************
+[cling]$
+

+ Statements and expressions could take more than one input line. The interactive prompt changes from "[cling]$" to "[cling]$ ?". +

+
[cling]$ #include "math.h"
+[cling]$ #include "stdio.h"
+[cling]$ for (unsigned i = 0; i < 5; ++i) {
+[cling]$ ?   printf("%f\n", sin(i));
+[cling]$ ?   }
+0.000000
+0.841471
+0.909297
+0.141120
+-0.756802
+

Grammar

+

Cling is able to parse everything that clang can. Current clang status can be found here. At the moment, there are use cases only for C++ that's why cling is best in working with C++. Clang has support of C, objC, objC++ and we are looking forward to having more use-cases and extend our tool in that direction.

+
    Cling has internal commands, which can change its behavior at runtime. Those commands usually start with dot (.): +
  • .I <path> - Adds an include path;
  • +
  • .x <filename> - #include-s the filename; and calls function called filename();
  • +
  • .L <libname> - Loads libname or #include-s the libname if libname is file;
  • +
  • .@ - Cancels the multiline input;
  • +
  • .printAST - (DEBUG ONLY) Turns on the printing of the compiler's abstract syntax tree (AST);
  • +
  • .dynamicExtensions - Turns on cling's dynamic extensions. This in turn enables the dynamic lookup and the late resolving of the identifier. With that option cling tries to heal the compile-time failed lookups at runtime;
  • +
+ +

Details

+

Command line

+

+ The interactive prompt supports an emacs-like command line editor, just like bash terminal, which makes it easy to integrate and use. Cling uses TextInput and doesn't depend on ncurses. +

+

+ Autocompletion should be coming soon! +

+

#Include Declarations

+

+ Cling allows #include-s to be not only before the declarations. The includes could be mixed with other declarations. For example: +

[cling]$ #include "math.h"
+[cling]$ sin(1)
+(double const) 8.414710e-01
+[cling]$ #include "stdio.h"
+[cling]$ printf("%f\n", sin(1));
+0.841471
+

+

+ More statements could be combined using semicolon (;). This doesn't stay when the command is #include + The following example is invalid:

[cling]$ #include "math.h"; sin(1)
+

+

+ The same rules are applicable for the other preprocessor directives (commands starting with # - such as #define) +

+

Variable Declarations

+

+ Cling allows statements to be entered onto the global scope. In order to be compiled and executed by the compiler these statements need to be wrapped into functions, which body contains the statement and afterwards to run the function. The semantics of the statements that declare variables is that variables should be accessed by other statements. If the statement that declare variable is wrapped into function the variables won't be accessible from outside anymore. In this case variables are extracted onto the global scope. +

+

TODO: There should be dedicated entry for that in the docs

+

Builtins

+ Cling starts with very few builtins loaded. Users could extend the available builtins via extending the RuntimeUniverse.h, which is loaded at cling's startup. +
+
+ +
+ + diff --git a/cint/cling/www/news.html b/cint/cling/www/news.html index 4a9421583b139..fe56ed95aacae 100644 --- a/cint/cling/www/news.html +++ b/cint/cling/www/news.html @@ -1,103 +1,103 @@ - - - - - Cling Website - - - - - - - - - -
- - -
- -
- -

Cling Goes Public

-
July 25th, 2011
-

- Cling is a completely new development, based on the opensource projects clang and LLVM. Cling is a new generation interpreter implemented as an interactive compiler interface of clang. The developer team has carefully designed the project, taking in mind the lessons that they had learn from CINT. -

- Read more >> -
-
-

New Website Launched

-
July 1st, 2011
-

- Welcome to our website! -
- The website contains vast information of the cling interactive compiler interface project. Information could be found at here as well. -

- Read more >> -
-
-
- -
- - + + + + + Cling Website + + + + + + + + + +
+ + +
+ +
+ +

Cling Goes Public

+
July 25th, 2011
+

+ Cling is a completely new development, based on the opensource projects clang and LLVM. Cling is a new generation interpreter implemented as an interactive compiler interface of clang. The developer team has carefully designed the project, taking in mind the lessons that they had learn from CINT. +

+ Read more >> +
+
+

New Website Launched

+
July 1st, 2011
+

+ Welcome to our website! +
+ The website contains vast information of the cling interactive compiler interface project. Information could be found at here as well. +

+ Read more >> +
+
+
+ +
+ + diff --git a/cint/cling/www/news/ClingAnnouncement.html b/cint/cling/www/news/ClingAnnouncement.html index 18713f133ba76..af109e367169f 100644 --- a/cint/cling/www/news/ClingAnnouncement.html +++ b/cint/cling/www/news/ClingAnnouncement.html @@ -1,102 +1,102 @@ - - - - - Cling Website - - - - - - - - - -
- - -
- -
- -

Cling Goes Public

-
July 25th, 2011
-

- Cling is a completely new development, based on the opensource projects clang and LLVM. Cling is a new generation interpreter implemented as an interactive compiler interface of clang. The developer team has carefully designed the project, taking in mind the lessons that they had learn from CINT. -

-

- Cling has been developed as prototype since quite a while. We have got more manpower and we managed to improve the prototype a lot. We have gotten to stage where the project could be useful. -

-

- Since cling heavily depends on clang and LLVM we feel responsible to offer the project to the community. On July the 25-th 2011 we have announced the stable status we have and kindly asked the community for feedback. It became clear there are many people interested in it. Some of the them even asked for the status of objC/objC++! -

-

- The overall good mark is a good motivation to keep walking in that direction. We follow our milestones and we are getting there! -

- << Back - -
-
- -
- - + + + + + Cling Website + + + + + + + + + +
+ + +
+ +
+ +

Cling Goes Public

+
July 25th, 2011
+

+ Cling is a completely new development, based on the opensource projects clang and LLVM. Cling is a new generation interpreter implemented as an interactive compiler interface of clang. The developer team has carefully designed the project, taking in mind the lessons that they had learn from CINT. +

+

+ Cling has been developed as prototype since quite a while. We have got more manpower and we managed to improve the prototype a lot. We have gotten to stage where the project could be useful. +

+

+ Since cling heavily depends on clang and LLVM we feel responsible to offer the project to the community. On July the 25-th 2011 we have announced the stable status we have and kindly asked the community for feedback. It became clear there are many people interested in it. Some of the them even asked for the status of objC/objC++! +

+

+ The overall good mark is a good motivation to keep walking in that direction. We follow our milestones and we are getting there! +

+ << Back + +
+
+ +
+ + diff --git a/cint/cling/www/news/NewWebsiteLaunched.html b/cint/cling/www/news/NewWebsiteLaunched.html index 228b0c1cd7253..5b8dc35c7b6e9 100644 --- a/cint/cling/www/news/NewWebsiteLaunched.html +++ b/cint/cling/www/news/NewWebsiteLaunched.html @@ -1,103 +1,103 @@ - - - - - Cling Website - - - - - - - - - -
- - -
- -
- -

New Website Launched

-
July 1st, 2011
-

- Welcome to our website! -
- The website contains vast information of the cling interactive compiler interface project. Information could be found at here as well. -

-

- Advantages of the current website are: -

    -
  • Hosted on the svn - enables version control of the website corresponding to the version of the project itself. Track of the modifications and authors could be kept.
  • -
  • Could be browsed offline (just open cling_src_folder that was checked out and open www/index.html)
  • -
  • Pure DHTML/CSS - easy to port and maintain
  • -
-

- << Back - -
-
- -
- - + + + + + Cling Website + + + + + + + + + +
+ + +
+ +
+ +

New Website Launched

+
July 1st, 2011
+

+ Welcome to our website! +
+ The website contains vast information of the cling interactive compiler interface project. Information could be found at here as well. +

+

+ Advantages of the current website are: +

    +
  • Hosted on the svn - enables version control of the website corresponding to the version of the project itself. Track of the modifications and authors could be kept.
  • +
  • Could be browsed offline (just open cling_src_folder that was checked out and open www/index.html)
  • +
  • Pure DHTML/CSS - easy to port and maintain
  • +
+

+ << Back + +
+
+ +
+ + diff --git a/cint/cling/www/style/style.css b/cint/cling/www/style/style.css index d0442d7ed3c16..19fe6975f0ce3 100644 --- a/cint/cling/www/style/style.css +++ b/cint/cling/www/style/style.css @@ -1,395 +1,395 @@ -html { - height: 100%; -} - -* { - margin: 0; - padding: 0; -} - -body { - font: normal .90em 'trebuchet ms', arial, sans-serif; - background: #F4F4EE; - color: #5D5D5D; -} - -p { - padding: 0 0 2em 0; - line-height: 1.7em; -} - -img { - border: 0; -} - -h1, h2, h3, h4, h5, h6 { - font: normal 200% 'century gothic', arial, sans-serif; - color: #43423F; - margin: 1em 0 1em 0; -} - -h2 { - font: normal 185% 'century gothic', arial, sans-serif; - color: #B60000; -} - -h3 { - font: normal 155% 'century gothic', arial, sans-serif; -} - -h4, h5, h6 { - margin: 0; - padding: 0 0 5px 0; - font: normal 120% arial, sans-serif; - color: #B60000; -} - -h5, h6 { - font: italic 95% arial, sans-serif; - color: #888; -} - -h6 { - color: #362C20; -} - -hr { - margin-top: 1em; - margin-bottom: 1em; - border: none; - border-top: 1px dashed #D9D5CF; -} - -.info, .see_also { - background-color: #FFFFAA; - font-size: 120%; - font-variant: small-caps; - padding-bottom: 1em; - padding-top: 1em; - text-align: center; -} - -.see_also { - background-color: transparent; - font-weight: bold; - text-align: left; -} - -.see_also_item { - padding-left: 2em; -} - -.clear { - clear: both; -} - -a, a:hover { - outline: none; - text-decoration: underline; - color: #A4AA04; -} - -a:hover { - text-decoration: none; - color: #5D5D5D; -} - -a.readmore { - float: right; -} - -.left { - float: left; - width: auto; - margin-right: 10px; -} - -.right { - float: right; - width: auto; - margin-left: 10px; -} - -.center { - display: block; - text-align: center; - margin: 20px auto; -} - -blockquote { - margin: 20px 0; - padding: 10px 20px 0 20px; - border: 1px solid #E5E5DB; - background: #FFF; -} - -ul { - margin: 2px 0 22px 17px; -} - -ul li { - list-style-type: circle; - margin: 0 0 6px 0; - padding: 0 0 4px 5px; -} - -ol { - margin: 8px 0 22px 20px; -} - -ol li { - margin: 0 0 11px 0; -} - -#website { - padding-bottom: 20px; -} - -#header { - background: #3A332D; /*url(menu_bg.jpg) no-repeat right 0;*/ - height: 180px; -} - -#logo { - min-width: 860px; - max-width: 1024px; - position: relative; - height: 140px; - background: url(logo.png) no-repeat transparent; - margin: auto; - padding: 0 0 0 4em; -} - -#logo #logo_text { - position: absolute; - top: 10px; - left: 0; -} - -#logo h1, #logo h2 { - font: normal 300% 'century gothic', arial, sans-serif; - border-bottom: 0; - text-transform: none; - margin: 0 0 0 9px; -} - -#logo_text h1, #logo_text h1 a, #logo_text h1 a:hover { - padding: 22px 0 0 0; - color: #FFF; - letter-spacing: 0.1em; - text-decoration: none; -} - -#logo_text h1 a .logo_colour { - color: #ECEF01; -} - -#logo_text h2 { - font-size: 120%; - padding: 4px 0 0 0; - color: #A8AA94; -} - -#mainmenubar { - min-width: 860px; - max-width: 1024px; - height: 40px; - margin: auto; - padding: 0 0 0 4em; -} - -#breadcrumb { - min-width: 860px; - max-width: 1024px; - margin: 0 auto; - min-height: 3em; - line-height: 3em; - text-align: right; - vertical-align: middle; - padding: 0 0em 0em 4em; -} - -#content { - min-width: 860px; - max-width: 1024px; - overflow: hidden; - padding: 0 1em 3em 3em; - margin: 0 auto; - background: #FFF; - border-radius: 20px; -moz-border-radius: 20px; - border: 1px solid #ECECE0; -} - -.sidebar { - float: right; - width: 20%; - padding: 15px; - margin-top: 1em; - background-color: #EDEFF4; /*D8DFEA*/ - -moz-border-radius: 20px; border-radius: 20px; -} -.sidebar ul { - width: 178px; - padding: 4px 0 0 0; - margin: 4px 0 30px 0; -} - -.sidebar li { - list-style: none; - padding: 0 0 7px 0; -} - -.sidebar li a, .sidebar li a:hover { - padding: 0 0 0 35px; - display: block; - background: transparent url(link.png) no-repeat left center; -} - -.sidebar li a.selected { - color: #444; - text-decoration: none; -} - -#main { - float: left; - width: 75%; - text-align: left; - padding: 0; -} - -#main ul { - margin: 2px 0 22px 0px; -} - -#main ul li { - list-style-type: none; - background: url(bullet.png) no-repeat; - margin: 0.5em 0 0 0; - padding: 0 0 0 25px; - line-height: 1.5em; -} - -#footer { - font: normal 90% arial, sans-serif; - height: 28px; - margin-top: 20px; - padding: 20px 0 5px 0; - margin: 0 auto; - text-align: center; - background: transparent; - color: #333; - text-transform: uppercase; - letter-spacing: 0.1em; -} - -#footer a, #footer a:hover { - color: #888; - text-decoration: none; -} - -#footer a:hover { - color: #333; -} - -#modified { - padding: 2em 0 1em 0; - text-transform: none; - text-align: center; - letter-spacing: normal; -} - -.search { - color: #5D5D5D; - border: 1px solid #BBB; - width: 134px; - padding: 4px; - font: 100% arial, sans-serif; -} - -.form_settings { - margin: 15px 0 0 0; -} - -.form_settings p { - padding: 0 0 4px 0; -} - -.form_settings span { - float: left; - width: 200px; - text-align: left; -} - -.form_settings input, .form_settings textarea { - padding: 5px; - width: 299px; - font: 100% arial; - border: 1px solid #E5E5DB; - background: #FFF; - color: #47433F; -} - -.form_settings .submit { - font: 100% arial; - border: 1px solid; - width: 99px; - margin: 0 0 0 212px; - height: 33px; - padding: 2px 0 3px 0; - cursor: pointer; - background: #3B3B3B; - color: #FFF; -} - -.form_settings textarea, .form_settings select { - font: 100% arial; - width: 299px; -} - -.form_settings select { - width: 310px; -} - -.form_settings .checkbox { - margin: 4px 0; - padding: 0; - width: 14px; - border: 0; - background: none; -} - -.separator { - width: 100%; - height: 0; - border-top: 1px solid #D9D5CF; - border-bottom: 1px solid #FFF; - margin: 0 0 20px 0; -} - -table { - margin: 10px 0 30px 0; - width: 100%; - border-spacing: 0; -} - -table tr th, table tr td { - background: #3B3B3B; - color: #FFF; - padding: 7px 4px; - text-align: left; -} - -table tr td { - background: #F4F4EE; - color: #47433F; - border-top: 1px solid #FFF; -} - -pre, .code { - border: 1px solid #DDDDDD; - border-width: 1px 1px 1px 5px; - margin: 1em; - padding: 5px; - background: none repeat scroll 0 0 #F8F8F8; - font: 0.95em "Consolas","DejaVu Sans Mono",monospace; -} +html { + height: 100%; +} + +* { + margin: 0; + padding: 0; +} + +body { + font: normal .90em 'trebuchet ms', arial, sans-serif; + background: #F4F4EE; + color: #5D5D5D; +} + +p { + padding: 0 0 2em 0; + line-height: 1.7em; +} + +img { + border: 0; +} + +h1, h2, h3, h4, h5, h6 { + font: normal 200% 'century gothic', arial, sans-serif; + color: #43423F; + margin: 1em 0 1em 0; +} + +h2 { + font: normal 185% 'century gothic', arial, sans-serif; + color: #B60000; +} + +h3 { + font: normal 155% 'century gothic', arial, sans-serif; +} + +h4, h5, h6 { + margin: 0; + padding: 0 0 5px 0; + font: normal 120% arial, sans-serif; + color: #B60000; +} + +h5, h6 { + font: italic 95% arial, sans-serif; + color: #888; +} + +h6 { + color: #362C20; +} + +hr { + margin-top: 1em; + margin-bottom: 1em; + border: none; + border-top: 1px dashed #D9D5CF; +} + +.info, .see_also { + background-color: #FFFFAA; + font-size: 120%; + font-variant: small-caps; + padding-bottom: 1em; + padding-top: 1em; + text-align: center; +} + +.see_also { + background-color: transparent; + font-weight: bold; + text-align: left; +} + +.see_also_item { + padding-left: 2em; +} + +.clear { + clear: both; +} + +a, a:hover { + outline: none; + text-decoration: underline; + color: #A4AA04; +} + +a:hover { + text-decoration: none; + color: #5D5D5D; +} + +a.readmore { + float: right; +} + +.left { + float: left; + width: auto; + margin-right: 10px; +} + +.right { + float: right; + width: auto; + margin-left: 10px; +} + +.center { + display: block; + text-align: center; + margin: 20px auto; +} + +blockquote { + margin: 20px 0; + padding: 10px 20px 0 20px; + border: 1px solid #E5E5DB; + background: #FFF; +} + +ul { + margin: 2px 0 22px 17px; +} + +ul li { + list-style-type: circle; + margin: 0 0 6px 0; + padding: 0 0 4px 5px; +} + +ol { + margin: 8px 0 22px 20px; +} + +ol li { + margin: 0 0 11px 0; +} + +#website { + padding-bottom: 20px; +} + +#header { + background: #3A332D; /*url(menu_bg.jpg) no-repeat right 0;*/ + height: 180px; +} + +#logo { + min-width: 860px; + max-width: 1024px; + position: relative; + height: 140px; + background: url(logo.png) no-repeat transparent; + margin: auto; + padding: 0 0 0 4em; +} + +#logo #logo_text { + position: absolute; + top: 10px; + left: 0; +} + +#logo h1, #logo h2 { + font: normal 300% 'century gothic', arial, sans-serif; + border-bottom: 0; + text-transform: none; + margin: 0 0 0 9px; +} + +#logo_text h1, #logo_text h1 a, #logo_text h1 a:hover { + padding: 22px 0 0 0; + color: #FFF; + letter-spacing: 0.1em; + text-decoration: none; +} + +#logo_text h1 a .logo_colour { + color: #ECEF01; +} + +#logo_text h2 { + font-size: 120%; + padding: 4px 0 0 0; + color: #A8AA94; +} + +#mainmenubar { + min-width: 860px; + max-width: 1024px; + height: 40px; + margin: auto; + padding: 0 0 0 4em; +} + +#breadcrumb { + min-width: 860px; + max-width: 1024px; + margin: 0 auto; + min-height: 3em; + line-height: 3em; + text-align: right; + vertical-align: middle; + padding: 0 0em 0em 4em; +} + +#content { + min-width: 860px; + max-width: 1024px; + overflow: hidden; + padding: 0 1em 3em 3em; + margin: 0 auto; + background: #FFF; + border-radius: 20px; -moz-border-radius: 20px; + border: 1px solid #ECECE0; +} + +.sidebar { + float: right; + width: 20%; + padding: 15px; + margin-top: 1em; + background-color: #EDEFF4; /*D8DFEA*/ + -moz-border-radius: 20px; border-radius: 20px; +} +.sidebar ul { + width: 178px; + padding: 4px 0 0 0; + margin: 4px 0 30px 0; +} + +.sidebar li { + list-style: none; + padding: 0 0 7px 0; +} + +.sidebar li a, .sidebar li a:hover { + padding: 0 0 0 35px; + display: block; + background: transparent url(link.png) no-repeat left center; +} + +.sidebar li a.selected { + color: #444; + text-decoration: none; +} + +#main { + float: left; + width: 75%; + text-align: left; + padding: 0; +} + +#main ul { + margin: 2px 0 22px 0px; +} + +#main ul li { + list-style-type: none; + background: url(bullet.png) no-repeat; + margin: 0.5em 0 0 0; + padding: 0 0 0 25px; + line-height: 1.5em; +} + +#footer { + font: normal 90% arial, sans-serif; + height: 28px; + margin-top: 20px; + padding: 20px 0 5px 0; + margin: 0 auto; + text-align: center; + background: transparent; + color: #333; + text-transform: uppercase; + letter-spacing: 0.1em; +} + +#footer a, #footer a:hover { + color: #888; + text-decoration: none; +} + +#footer a:hover { + color: #333; +} + +#modified { + padding: 2em 0 1em 0; + text-transform: none; + text-align: center; + letter-spacing: normal; +} + +.search { + color: #5D5D5D; + border: 1px solid #BBB; + width: 134px; + padding: 4px; + font: 100% arial, sans-serif; +} + +.form_settings { + margin: 15px 0 0 0; +} + +.form_settings p { + padding: 0 0 4px 0; +} + +.form_settings span { + float: left; + width: 200px; + text-align: left; +} + +.form_settings input, .form_settings textarea { + padding: 5px; + width: 299px; + font: 100% arial; + border: 1px solid #E5E5DB; + background: #FFF; + color: #47433F; +} + +.form_settings .submit { + font: 100% arial; + border: 1px solid; + width: 99px; + margin: 0 0 0 212px; + height: 33px; + padding: 2px 0 3px 0; + cursor: pointer; + background: #3B3B3B; + color: #FFF; +} + +.form_settings textarea, .form_settings select { + font: 100% arial; + width: 299px; +} + +.form_settings select { + width: 310px; +} + +.form_settings .checkbox { + margin: 4px 0; + padding: 0; + width: 14px; + border: 0; + background: none; +} + +.separator { + width: 100%; + height: 0; + border-top: 1px solid #D9D5CF; + border-bottom: 1px solid #FFF; + margin: 0 0 20px 0; +} + +table { + margin: 10px 0 30px 0; + width: 100%; + border-spacing: 0; +} + +table tr th, table tr td { + background: #3B3B3B; + color: #FFF; + padding: 7px 4px; + text-align: left; +} + +table tr td { + background: #F4F4EE; + color: #47433F; + border-top: 1px solid #FFF; +} + +pre, .code { + border: 1px solid #DDDDDD; + border-width: 1px 1px 1px 5px; + margin: 1em; + padding: 5px; + background: none repeat scroll 0 0 #F8F8F8; + font: 0.95em "Consolas","DejaVu Sans Mono",monospace; +} diff --git a/cint/configure b/cint/configure index 949b00ce84e55..55f6d35bb88fa 100755 --- a/cint/configure +++ b/cint/configure @@ -1,7 +1,7 @@ #!/bin/sh ############################################################## # -# Copyright(c) 1995~2008 Masaharu Goto (cint@pcroot.cern.ch) +# Copyright(c) 1995~2008 Masaharu Goto (root-cint@cern.ch) # # For the licensing terms see the file COPYING # @@ -421,7 +421,7 @@ function guess_arch { # *) # echo "Attempts at guessing your architecture failed." # echo "Please specify the architecture as the first argument." -# echo "Do '$0 --help' for a list of avaliable architectures." +# echo "Do '$0 --help' for a list of available architectures." # exit 1 # ;; esac @@ -701,7 +701,7 @@ HAVE_CONFIG=1 EXPORTS=(${EXPORTS[*]} HAVE_CONFIG) # now set the default values of the installation directories, if -# they were not set explicitely by the user +# they were not set explicitly by the user if [ "x$WITHPREFIX" = "x1" ]; then # prefix based build diff --git a/cint/demo/Win32App/TestApp/StdAfx.cpp b/cint/demo/Win32App/TestApp/StdAfx.cpp index 66c1ebb99eeda..d3812dcdce0e8 100644 --- a/cint/demo/Win32App/TestApp/StdAfx.cpp +++ b/cint/demo/Win32App/TestApp/StdAfx.cpp @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/TestApp/StdAfx.h b/cint/demo/Win32App/TestApp/StdAfx.h index 1a81dc7086889..81bf3016be737 100644 --- a/cint/demo/Win32App/TestApp/StdAfx.h +++ b/cint/demo/Win32App/TestApp/StdAfx.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/TestApp/TestApp.cpp b/cint/demo/Win32App/TestApp/TestApp.cpp index 312f9158486ad..a07573a1cea84 100644 --- a/cint/demo/Win32App/TestApp/TestApp.cpp +++ b/cint/demo/Win32App/TestApp/TestApp.cpp @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/TestApp/TestApp.dsp b/cint/demo/Win32App/TestApp/TestApp.dsp index 7cb171b8146ac..a46796d255477 100644 --- a/cint/demo/Win32App/TestApp/TestApp.dsp +++ b/cint/demo/Win32App/TestApp/TestApp.dsp @@ -1,142 +1,142 @@ -# Microsoft Developer Studio Project File - Name="TestApp" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Application" 0x0101 - -CFG=TestApp - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "TestApp.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "TestApp.mak" CFG="TestApp - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "TestApp - Win32 Release" (based on "Win32 (x86) Application") -!MESSAGE "TestApp - Win32 Debug" (based on "Win32 (x86) Application") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -MTL=midl.exe -RSC=rc.exe - -!IF "$(CFG)" == "TestApp - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "Release" -# PROP Intermediate_Dir "Release" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /c -# ADD CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /c -# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x411 /d "NDEBUG" -# ADD RSC /l 0x411 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 - -!ELSEIF "$(CFG)" == "TestApp - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "Debug" -# PROP Intermediate_Dir "Debug" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /GZ /c -# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "c:\cint" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /GZ /c -# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x411 /d "_DEBUG" -# ADD RSC /l 0x411 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept - -!ENDIF - -# Begin Target - -# Name "TestApp - Win32 Release" -# Name "TestApp - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\StdAfx.cpp -# ADD CPP /Yc"stdafx.h" -# End Source File -# Begin Source File - -SOURCE=.\TestApp.cpp -# End Source File -# Begin Source File - -SOURCE=.\TestApp.rc -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# Begin Source File - -SOURCE=.\resource.h -# End Source File -# Begin Source File - -SOURCE=.\StdAfx.h -# End Source File -# Begin Source File - -SOURCE=.\TestApp.h -# End Source File -# End Group -# Begin Group "Resource Files" - -# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" -# Begin Source File - -SOURCE=.\small.ico -# End Source File -# Begin Source File - -SOURCE=.\TestApp.ico -# End Source File -# End Group -# Begin Source File - -SOURCE=.\ReadMe.txt -# End Source File -# Begin Source File - -SOURCE=..\..\..\libcint.lib -# End Source File -# End Target -# End Project +# Microsoft Developer Studio Project File - Name="TestApp" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Application" 0x0101 + +CFG=TestApp - Win32 Debug +!MESSAGE This is not a valid makefile. To build this project using NMAKE, +!MESSAGE use the Export Makefile command and run +!MESSAGE +!MESSAGE NMAKE /f "TestApp.mak". +!MESSAGE +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "TestApp.mak" CFG="TestApp - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "TestApp - Win32 Release" (based on "Win32 (x86) Application") +!MESSAGE "TestApp - Win32 Debug" (based on "Win32 (x86) Application") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName "" +# PROP Scc_LocalPath "" +CPP=cl.exe +MTL=midl.exe +RSC=rc.exe + +!IF "$(CFG)" == "TestApp - Win32 Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "Release" +# PROP BASE Intermediate_Dir "Release" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "Release" +# PROP Intermediate_Dir "Release" +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /c +# ADD CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /c +# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x411 /d "NDEBUG" +# ADD RSC /l 0x411 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 + +!ELSEIF "$(CFG)" == "TestApp - Win32 Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "Debug" +# PROP BASE Intermediate_Dir "Debug" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "Debug" +# PROP Intermediate_Dir "Debug" +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /GZ /c +# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "c:\cint" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /GZ /c +# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x411 /d "_DEBUG" +# ADD RSC /l 0x411 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept + +!ENDIF + +# Begin Target + +# Name "TestApp - Win32 Release" +# Name "TestApp - Win32 Debug" +# Begin Group "Source Files" + +# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" +# Begin Source File + +SOURCE=.\StdAfx.cpp +# ADD CPP /Yc"stdafx.h" +# End Source File +# Begin Source File + +SOURCE=.\TestApp.cpp +# End Source File +# Begin Source File + +SOURCE=.\TestApp.rc +# End Source File +# End Group +# Begin Group "Header Files" + +# PROP Default_Filter "h;hpp;hxx;hm;inl" +# Begin Source File + +SOURCE=.\resource.h +# End Source File +# Begin Source File + +SOURCE=.\StdAfx.h +# End Source File +# Begin Source File + +SOURCE=.\TestApp.h +# End Source File +# End Group +# Begin Group "Resource Files" + +# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" +# Begin Source File + +SOURCE=.\small.ico +# End Source File +# Begin Source File + +SOURCE=.\TestApp.ico +# End Source File +# End Group +# Begin Source File + +SOURCE=.\ReadMe.txt +# End Source File +# Begin Source File + +SOURCE=..\..\..\libcint.lib +# End Source File +# End Target +# End Project diff --git a/cint/demo/Win32App/TestApp/TestApp.dsw b/cint/demo/Win32App/TestApp/TestApp.dsw index 9f4cc6357b3e6..87e8dccbc9733 100644 --- a/cint/demo/Win32App/TestApp/TestApp.dsw +++ b/cint/demo/Win32App/TestApp/TestApp.dsw @@ -1,29 +1,29 @@ -Microsoft Developer Studio Workspace File, Format Version 6.00 -# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! - -############################################################################### - -Project: "TestApp"=.\TestApp.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Global: - -Package=<5> -{{{ -}}} - -Package=<3> -{{{ -}}} - -############################################################################### - +Microsoft Developer Studio Workspace File, Format Version 6.00 +# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! + +############################################################################### + +Project: "TestApp"=.\TestApp.dsp - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ +}}} + +############################################################################### + +Global: + +Package=<5> +{{{ +}}} + +Package=<3> +{{{ +}}} + +############################################################################### + diff --git a/cint/demo/Win32App/TestApp/TestApp.h b/cint/demo/Win32App/TestApp/TestApp.h index 1e16423d42439..52d1d20bbacda 100644 --- a/cint/demo/Win32App/TestApp/TestApp.h +++ b/cint/demo/Win32App/TestApp/TestApp.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/TestApp/resource.h b/cint/demo/Win32App/TestApp/resource.h index d855a7ddef156..fd31a20adfdce 100644 --- a/cint/demo/Win32App/TestApp/resource.h +++ b/cint/demo/Win32App/TestApp/resource.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/TestApp/script.cxx b/cint/demo/Win32App/TestApp/script.cxx index 3b56c7a861909..8e6e484d01fe8 100644 --- a/cint/demo/Win32App/TestApp/script.cxx +++ b/cint/demo/Win32App/TestApp/script.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/graph01/CompiledLib.c b/cint/demo/Win32App/graph01/CompiledLib.c index 1c78e2a7dc129..152798e42dd6a 100644 --- a/cint/demo/Win32App/graph01/CompiledLib.c +++ b/cint/demo/Win32App/graph01/CompiledLib.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/graph01/CompiledLib.h b/cint/demo/Win32App/graph01/CompiledLib.h index 61c1d9ee2c36c..25c1f78859373 100644 --- a/cint/demo/Win32App/graph01/CompiledLib.h +++ b/cint/demo/Win32App/graph01/CompiledLib.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/graph01/Script.c b/cint/demo/Win32App/graph01/Script.c index 4897623509fd2..fec5bd880cc8a 100644 --- a/cint/demo/Win32App/graph01/Script.c +++ b/cint/demo/Win32App/graph01/Script.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/graph01/StdAfx.h b/cint/demo/Win32App/graph01/StdAfx.h index ee92277e9388a..baa4158578694 100644 --- a/cint/demo/Win32App/graph01/StdAfx.h +++ b/cint/demo/Win32App/graph01/StdAfx.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/graph01/WinMain.c b/cint/demo/Win32App/graph01/WinMain.c index f3e823c1c26c8..751e9d63ba7a5 100644 --- a/cint/demo/Win32App/graph01/WinMain.c +++ b/cint/demo/Win32App/graph01/WinMain.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/graph01/WndProc.c b/cint/demo/Win32App/graph01/WndProc.c index cc8dc818cb89f..b53e922540c54 100644 --- a/cint/demo/Win32App/graph01/WndProc.c +++ b/cint/demo/Win32App/graph01/WndProc.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/graph01/WndProc.h b/cint/demo/Win32App/graph01/WndProc.h index 8b0270a85f2bd..2010de15e0c3b 100644 --- a/cint/demo/Win32App/graph01/WndProc.h +++ b/cint/demo/Win32App/graph01/WndProc.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/Win32App/graph01/chapter24.dsp b/cint/demo/Win32App/graph01/chapter24.dsp index 4c554ef78c693..36e6add9679be 100644 --- a/cint/demo/Win32App/graph01/chapter24.dsp +++ b/cint/demo/Win32App/graph01/chapter24.dsp @@ -1,118 +1,118 @@ -# Microsoft Developer Studio Project File - Name="chapter24" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Application" 0x0101 - -CFG=chapter24 - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "chapter24.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "chapter24.mak" CFG="chapter24 - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "chapter24 - Win32 Release" (based on "Win32 (x86) Application") -!MESSAGE "chapter24 - Win32 Debug" (based on "Win32 (x86) Application") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -MTL=midl.exe -RSC=rc.exe - -!IF "$(CFG)" == "chapter24 - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "Release" -# PROP Intermediate_Dir "Release" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c -# ADD CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c -# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x411 /d "NDEBUG" -# ADD RSC /l 0x411 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 - -!ELSEIF "$(CFG)" == "chapter24 - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "Debug" -# PROP Intermediate_Dir "Debug" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c -# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "\cint" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c -# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x411 /d "_DEBUG" -# ADD RSC /l 0x411 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept -# ADD LINK32 comctl32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept - -!ENDIF - -# Begin Target - -# Name "chapter24 - Win32 Release" -# Name "chapter24 - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\CompiledLib.c -# End Source File -# Begin Source File - -SOURCE=.\G__clink.c -# End Source File -# Begin Source File - -SOURCE=.\WinMain.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# End Group -# Begin Group "Resource Files" - -# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" -# End Group -# Begin Source File - -SOURCE=\cint\libcint.lib -# End Source File -# End Target -# End Project +# Microsoft Developer Studio Project File - Name="chapter24" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Application" 0x0101 + +CFG=chapter24 - Win32 Debug +!MESSAGE This is not a valid makefile. To build this project using NMAKE, +!MESSAGE use the Export Makefile command and run +!MESSAGE +!MESSAGE NMAKE /f "chapter24.mak". +!MESSAGE +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "chapter24.mak" CFG="chapter24 - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "chapter24 - Win32 Release" (based on "Win32 (x86) Application") +!MESSAGE "chapter24 - Win32 Debug" (based on "Win32 (x86) Application") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName "" +# PROP Scc_LocalPath "" +CPP=cl.exe +MTL=midl.exe +RSC=rc.exe + +!IF "$(CFG)" == "chapter24 - Win32 Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "Release" +# PROP BASE Intermediate_Dir "Release" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "Release" +# PROP Intermediate_Dir "Release" +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c +# ADD CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c +# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x411 /d "NDEBUG" +# ADD RSC /l 0x411 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 + +!ELSEIF "$(CFG)" == "chapter24 - Win32 Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "Debug" +# PROP BASE Intermediate_Dir "Debug" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "Debug" +# PROP Intermediate_Dir "Debug" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c +# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "\cint" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c +# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x411 /d "_DEBUG" +# ADD RSC /l 0x411 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept +# ADD LINK32 comctl32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept + +!ENDIF + +# Begin Target + +# Name "chapter24 - Win32 Release" +# Name "chapter24 - Win32 Debug" +# Begin Group "Source Files" + +# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" +# Begin Source File + +SOURCE=.\CompiledLib.c +# End Source File +# Begin Source File + +SOURCE=.\G__clink.c +# End Source File +# Begin Source File + +SOURCE=.\WinMain.c +# End Source File +# End Group +# Begin Group "Header Files" + +# PROP Default_Filter "h;hpp;hxx;hm;inl" +# End Group +# Begin Group "Resource Files" + +# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" +# End Group +# Begin Source File + +SOURCE=\cint\libcint.lib +# End Source File +# End Target +# End Project diff --git a/cint/demo/Win32App/graph01/chapter24.dsw b/cint/demo/Win32App/graph01/chapter24.dsw index 478a36c554d91..6d6cb01f55375 100644 --- a/cint/demo/Win32App/graph01/chapter24.dsw +++ b/cint/demo/Win32App/graph01/chapter24.dsw @@ -1,29 +1,29 @@ -Microsoft Developer Studio Workspace File, Format Version 6.00 -# �x��: ����ܰ���߰� ̧�� ��ҏW�܂��͍폜���Ȃ��ł�������! - -############################################################################### - -Project: "chapter24"=".\chapter24.dsp" - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Global: - -Package=<5> -{{{ -}}} - -Package=<3> -{{{ -}}} - -############################################################################### - +Microsoft Developer Studio Workspace File, Format Version 6.00 +# �x��: ����ܰ���߰� ̧�� ��ҏW�܂��͍폜���Ȃ��ł�������! + +############################################################################### + +Project: "chapter24"=".\chapter24.dsp" - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ +}}} + +############################################################################### + +Global: + +Package=<5> +{{{ +}}} + +Package=<3> +{{{ +}}} + +############################################################################### + diff --git a/cint/demo/Win32App/graph01/graph01.dsp b/cint/demo/Win32App/graph01/graph01.dsp index ebd1108087f88..eba053e6d8425 100644 --- a/cint/demo/Win32App/graph01/graph01.dsp +++ b/cint/demo/Win32App/graph01/graph01.dsp @@ -1,153 +1,153 @@ -# Microsoft Developer Studio Project File - Name="graph01" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Application" 0x0101 - -CFG=graph01 - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "graph01.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "graph01.mak" CFG="graph01 - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "graph01 - Win32 Release" (based on "Win32 (x86) Application") -!MESSAGE "graph01 - Win32 Debug" (based on "Win32 (x86) Application") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -MTL=midl.exe -RSC=rc.exe - -!IF "$(CFG)" == "graph01 - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "Release" -# PROP Intermediate_Dir "Release" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c -# ADD CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c -# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x411 /d "NDEBUG" -# ADD RSC /l 0x411 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 - -!ELSEIF "$(CFG)" == "graph01 - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "Debug" -# PROP Intermediate_Dir "Debug" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c -# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "\cint" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c -# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x411 /d "_DEBUG" -# ADD RSC /l 0x411 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept - -!ENDIF - -# Begin Target - -# Name "graph01 - Win32 Release" -# Name "graph01 - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\CompiledLib.c -# End Source File -# Begin Source File - -SOURCE=.\G__clink.c -# End Source File -# Begin Source File - -SOURCE=.\Resource.rc -# End Source File -# Begin Source File - -SOURCE=.\WinMain.c -# End Source File -# Begin Source File - -SOURCE=.\WndProc.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# Begin Source File - -SOURCE=.\G__ci.h -# End Source File -# Begin Source File - -SOURCE=.\G__clink.h -# End Source File -# Begin Source File - -SOURCE=.\resource.h -# End Source File -# Begin Source File - -SOURCE=.\StdAfx.h -# End Source File -# Begin Source File - -SOURCE=.\WndProc.h -# End Source File -# End Group -# Begin Group "Resource Files" - -# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" -# Begin Source File - -SOURCE=.\app.ico -# End Source File -# Begin Source File - -SOURCE=.\small.ico -# End Source File -# End Group -# Begin Source File - -SOURCE=C:\cint\libcint.lib -# End Source File -# End Target -# End Project +# Microsoft Developer Studio Project File - Name="graph01" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Application" 0x0101 + +CFG=graph01 - Win32 Debug +!MESSAGE This is not a valid makefile. To build this project using NMAKE, +!MESSAGE use the Export Makefile command and run +!MESSAGE +!MESSAGE NMAKE /f "graph01.mak". +!MESSAGE +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "graph01.mak" CFG="graph01 - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "graph01 - Win32 Release" (based on "Win32 (x86) Application") +!MESSAGE "graph01 - Win32 Debug" (based on "Win32 (x86) Application") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName "" +# PROP Scc_LocalPath "" +CPP=cl.exe +MTL=midl.exe +RSC=rc.exe + +!IF "$(CFG)" == "graph01 - Win32 Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "Release" +# PROP BASE Intermediate_Dir "Release" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "Release" +# PROP Intermediate_Dir "Release" +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c +# ADD CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c +# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x411 /d "NDEBUG" +# ADD RSC /l 0x411 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 + +!ELSEIF "$(CFG)" == "graph01 - Win32 Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "Debug" +# PROP BASE Intermediate_Dir "Debug" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "Debug" +# PROP Intermediate_Dir "Debug" +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c +# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "\cint" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c +# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x411 /d "_DEBUG" +# ADD RSC /l 0x411 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept + +!ENDIF + +# Begin Target + +# Name "graph01 - Win32 Release" +# Name "graph01 - Win32 Debug" +# Begin Group "Source Files" + +# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" +# Begin Source File + +SOURCE=.\CompiledLib.c +# End Source File +# Begin Source File + +SOURCE=.\G__clink.c +# End Source File +# Begin Source File + +SOURCE=.\Resource.rc +# End Source File +# Begin Source File + +SOURCE=.\WinMain.c +# End Source File +# Begin Source File + +SOURCE=.\WndProc.c +# End Source File +# End Group +# Begin Group "Header Files" + +# PROP Default_Filter "h;hpp;hxx;hm;inl" +# Begin Source File + +SOURCE=.\G__ci.h +# End Source File +# Begin Source File + +SOURCE=.\G__clink.h +# End Source File +# Begin Source File + +SOURCE=.\resource.h +# End Source File +# Begin Source File + +SOURCE=.\StdAfx.h +# End Source File +# Begin Source File + +SOURCE=.\WndProc.h +# End Source File +# End Group +# Begin Group "Resource Files" + +# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" +# Begin Source File + +SOURCE=.\app.ico +# End Source File +# Begin Source File + +SOURCE=.\small.ico +# End Source File +# End Group +# Begin Source File + +SOURCE=C:\cint\libcint.lib +# End Source File +# End Target +# End Project diff --git a/cint/demo/Win32App/graph01/graph01.dsw b/cint/demo/Win32App/graph01/graph01.dsw index c963fbf0d9f3a..38c12ca5b1903 100644 --- a/cint/demo/Win32App/graph01/graph01.dsw +++ b/cint/demo/Win32App/graph01/graph01.dsw @@ -1,29 +1,29 @@ -Microsoft Developer Studio Workspace File, Format Version 6.00 -# �x��: ����ܰ���߰� ̧�� ��ҏW�܂��͍폜���Ȃ��ł�������! - -############################################################################### - -Project: "graph01"=".\graph01.dsp" - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Global: - -Package=<5> -{{{ -}}} - -Package=<3> -{{{ -}}} - -############################################################################### - +Microsoft Developer Studio Workspace File, Format Version 6.00 +# �x��: ����ܰ���߰� ̧�� ��ҏW�܂��͍폜���Ȃ��ł�������! + +############################################################################### + +Project: "graph01"=".\graph01.dsp" - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ +}}} + +############################################################################### + +Global: + +Package=<5> +{{{ +}}} + +Package=<3> +{{{ +}}} + +############################################################################### + diff --git a/cint/demo/Win32App/graph01/resource.h b/cint/demo/Win32App/graph01/resource.h index 29d4ccae19873..b2660bc1f6222 100644 --- a/cint/demo/Win32App/graph01/resource.h +++ b/cint/demo/Win32App/graph01/resource.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/debug/debug.c b/cint/demo/debug/debug.c index 2b608e18946df..7ce2f7b9fbf4f 100644 --- a/cint/demo/debug/debug.c +++ b/cint/demo/debug/debug.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/debug/debug2.com b/cint/demo/debug/debug2.com index 287e94f7eaf55..8c72971c92e1a 100644 --- a/cint/demo/debug/debug2.com +++ b/cint/demo/debug/debug2.com @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/debug/debug2.cxx b/cint/demo/debug/debug2.cxx index f7930d7d1c567..c743ac014b587 100644 --- a/cint/demo/debug/debug2.cxx +++ b/cint/demo/debug/debug2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/errpipe/errpipe.cxx b/cint/demo/errpipe/errpipe.cxx index c2c22c0be42f1..3faf296177f73 100644 --- a/cint/demo/errpipe/errpipe.cxx +++ b/cint/demo/errpipe/errpipe.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/errpipe/errpipe.h b/cint/demo/errpipe/errpipe.h index a91c82d0b8171..d570bc11e532f 100644 --- a/cint/demo/errpipe/errpipe.h +++ b/cint/demo/errpipe/errpipe.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/exception/ehdemo.cxx b/cint/demo/exception/ehdemo.cxx index fc660964b2a97..ccb6424cef194 100644 --- a/cint/demo/exception/ehdemo.cxx +++ b/cint/demo/exception/ehdemo.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/exception/ehdemo.h b/cint/demo/exception/ehdemo.h index 020dd3a1a73ab..352a511350731 100644 --- a/cint/demo/exception/ehdemo.h +++ b/cint/demo/exception/ehdemo.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/gl/display0.h b/cint/demo/gl/display0.h index e9467adbf5c3c..54b6b964903ab 100644 --- a/cint/demo/gl/display0.h +++ b/cint/demo/gl/display0.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/gl/display1.h b/cint/demo/gl/display1.h index fa20cf68f86c6..e08aff543a13f 100644 --- a/cint/demo/gl/display1.h +++ b/cint/demo/gl/display1.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/gl/display2.h b/cint/demo/gl/display2.h index 44a8645f4fd32..40815c20b9efa 100644 --- a/cint/demo/gl/display2.h +++ b/cint/demo/gl/display2.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/gl/make0 b/cint/demo/gl/make0 index a1c3ffe445182..05112495aeb0a 100644 --- a/cint/demo/gl/make0 +++ b/cint/demo/gl/make0 @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/gl/test0.c b/cint/demo/gl/test0.c index 710b58429223d..28b126df0c279 100644 --- a/cint/demo/gl/test0.c +++ b/cint/demo/gl/test0.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/gl/test1.c b/cint/demo/gl/test1.c index 68d5d531dadc0..26fb93e2a7d89 100644 --- a/cint/demo/gl/test1.c +++ b/cint/demo/gl/test1.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/gl/test2.c b/cint/demo/gl/test2.c index 0ae582e61bb58..08a1ba9227e7a 100644 --- a/cint/demo/gl/test2.c +++ b/cint/demo/gl/test2.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/graphs/FFT.c b/cint/demo/graphs/FFT.c index 78ab8ba0862e9..4db14b3eda903 100644 --- a/cint/demo/graphs/FFT.c +++ b/cint/demo/graphs/FFT.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/graphs/dft.c b/cint/demo/graphs/dft.c index cb03fbe97f8b2..3dfb6915e62c3 100644 --- a/cint/demo/graphs/dft.c +++ b/cint/demo/graphs/dft.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/graphs/eular.c b/cint/demo/graphs/eular.c index be739d214f2eb..27acf8495c363 100644 --- a/cint/demo/graphs/eular.c +++ b/cint/demo/graphs/eular.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/graphs/fir.c b/cint/demo/graphs/fir.c index adc321309809d..caa25dbc18a60 100644 --- a/cint/demo/graphs/fir.c +++ b/cint/demo/graphs/fir.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/graphs/fir2.c b/cint/demo/graphs/fir2.c index f128df641c27f..e3eaec1aa221f 100644 --- a/cint/demo/graphs/fir2.c +++ b/cint/demo/graphs/fir2.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/graphs/jitter.c b/cint/demo/graphs/jitter.c index 9a4f61e2bfefa..f182a5a51ff59 100644 --- a/cint/demo/graphs/jitter.c +++ b/cint/demo/graphs/jitter.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/graphs/modulation.c b/cint/demo/graphs/modulation.c index a43561c7ce71b..d2d27e4070ef1 100644 --- a/cint/demo/graphs/modulation.c +++ b/cint/demo/graphs/modulation.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/graphs/sin.c b/cint/demo/graphs/sin.c index dbb3218263295..56364800f2d9d 100644 --- a/cint/demo/graphs/sin.c +++ b/cint/demo/graphs/sin.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/graphs/sin123.c b/cint/demo/graphs/sin123.c index 44f88cc1d0b3a..af8aceec35741 100644 --- a/cint/demo/graphs/sin123.c +++ b/cint/demo/graphs/sin123.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/graphs/skineffect.c b/cint/demo/graphs/skineffect.c index 069d680fb0128..3bdae93f413f3 100644 --- a/cint/demo/graphs/skineffect.c +++ b/cint/demo/graphs/skineffect.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/graphs/stripline.c b/cint/demo/graphs/stripline.c index 964ae408d78cb..c93ea441a317f 100644 --- a/cint/demo/graphs/stripline.c +++ b/cint/demo/graphs/stripline.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/intprt_cint/CINT b/cint/demo/intprt_cint/CINT index be85fa46058f0..81e3731e19460 100644 --- a/cint/demo/intprt_cint/CINT +++ b/cint/demo/intprt_cint/CINT @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/intprt_cint/cint.sh b/cint/demo/intprt_cint/cint.sh index 2ed3cb134e037..0cc0a6157a9c6 100755 --- a/cint/demo/intprt_cint/cint.sh +++ b/cint/demo/intprt_cint/cint.sh @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/intprt_cint/simple.c b/cint/demo/intprt_cint/simple.c index ba744cd689252..6abda7af59bc9 100644 --- a/cint/demo/intprt_cint/simple.c +++ b/cint/demo/intprt_cint/simple.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/intprt_cint/simple.cxx b/cint/demo/intprt_cint/simple.cxx index 435eef4dd3f26..decac0c541de2 100644 --- a/cint/demo/intprt_cint/simple.cxx +++ b/cint/demo/intprt_cint/simple.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/intprt_cint/testmain.c b/cint/demo/intprt_cint/testmain.c index 041782bc8d573..4baf23cb6d651 100644 --- a/cint/demo/intprt_cint/testmain.c +++ b/cint/demo/intprt_cint/testmain.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/ipc/common.cxx b/cint/demo/ipc/common.cxx index 65dc60767d643..cff49dbec8442 100644 --- a/cint/demo/ipc/common.cxx +++ b/cint/demo/ipc/common.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/ipc/proc1.cxx b/cint/demo/ipc/proc1.cxx index 26fa975ef896c..a393a607d97ed 100644 --- a/cint/demo/ipc/proc1.cxx +++ b/cint/demo/ipc/proc1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/ipc/proc2.cxx b/cint/demo/ipc/proc2.cxx index d17b61b8e311f..fe2881f120be8 100644 --- a/cint/demo/ipc/proc2.cxx +++ b/cint/demo/ipc/proc2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Array/Array.C b/cint/demo/makecint/Array/Array.C index 69e2790199741..eba0aa5c7f6c6 100644 --- a/cint/demo/makecint/Array/Array.C +++ b/cint/demo/makecint/Array/Array.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Array/Array.h b/cint/demo/makecint/Array/Array.h index f3f15f0474e76..0e8da4b94df1a 100644 --- a/cint/demo/makecint/Array/Array.h +++ b/cint/demo/makecint/Array/Array.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Array/Fundament.C b/cint/demo/makecint/Array/Fundament.C index 04f3f4393f0a3..b3312247962fd 100644 --- a/cint/demo/makecint/Array/Fundament.C +++ b/cint/demo/makecint/Array/Fundament.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Array/Fundament.h b/cint/demo/makecint/Array/Fundament.h index 13da1cb64e11c..33eb697716494 100644 --- a/cint/demo/makecint/Array/Fundament.h +++ b/cint/demo/makecint/Array/Fundament.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Array/inherit.C b/cint/demo/makecint/Array/inherit.C index 8f10b5a952941..75a24b6b8f523 100644 --- a/cint/demo/makecint/Array/inherit.C +++ b/cint/demo/makecint/Array/inherit.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Array/loopcompile.c b/cint/demo/makecint/Array/loopcompile.c index 66854fbbf8183..e53c2f7d8fa14 100644 --- a/cint/demo/makecint/Array/loopcompile.c +++ b/cint/demo/makecint/Array/loopcompile.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Array/loopcompile0.c b/cint/demo/makecint/Array/loopcompile0.c index c94cb8b55f534..9fd7de9d80fc7 100644 --- a/cint/demo/makecint/Array/loopcompile0.c +++ b/cint/demo/makecint/Array/loopcompile0.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Array/loopcompile1.c b/cint/demo/makecint/Array/loopcompile1.c index b1125ae5ccf78..6d3421a203e10 100644 --- a/cint/demo/makecint/Array/loopcompile1.c +++ b/cint/demo/makecint/Array/loopcompile1.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Array/test.C b/cint/demo/makecint/Array/test.C index 19228a1229457..e30aa02773acd 100644 --- a/cint/demo/makecint/Array/test.C +++ b/cint/demo/makecint/Array/test.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Complex/Complex.C b/cint/demo/makecint/Complex/Complex.C index 1f06fee7b6e09..7ac81d47027e1 100644 --- a/cint/demo/makecint/Complex/Complex.C +++ b/cint/demo/makecint/Complex/Complex.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Complex/Complex.h b/cint/demo/makecint/Complex/Complex.h index 2af75c888742e..705299feac405 100644 --- a/cint/demo/makecint/Complex/Complex.h +++ b/cint/demo/makecint/Complex/Complex.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Complex/temp.C b/cint/demo/makecint/Complex/temp.C index e33b5421df355..9bd0af083930e 100644 --- a/cint/demo/makecint/Complex/temp.C +++ b/cint/demo/makecint/Complex/temp.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Complex/test.C b/cint/demo/makecint/Complex/test.C index 43d2baf969a4b..44b5808627cc1 100644 --- a/cint/demo/makecint/Complex/test.C +++ b/cint/demo/makecint/Complex/test.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/DArray/DArray.C b/cint/demo/makecint/DArray/DArray.C index ead859376c9ed..94b0a95860d80 100644 --- a/cint/demo/makecint/DArray/DArray.C +++ b/cint/demo/makecint/DArray/DArray.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/DArray/DArray.h b/cint/demo/makecint/DArray/DArray.h index f478e1227776a..c793916b7c8cd 100644 --- a/cint/demo/makecint/DArray/DArray.h +++ b/cint/demo/makecint/DArray/DArray.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/DArray/test.C b/cint/demo/makecint/DArray/test.C index 79f15dcc96006..27b45612c5f09 100644 --- a/cint/demo/makecint/DArray/test.C +++ b/cint/demo/makecint/DArray/test.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/KRcc/Complex.c b/cint/demo/makecint/KRcc/Complex.c index 734ce718db633..a254297c25bef 100644 --- a/cint/demo/makecint/KRcc/Complex.c +++ b/cint/demo/makecint/KRcc/Complex.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/KRcc/Complex.h b/cint/demo/makecint/KRcc/Complex.h index 8e723b5073852..687334f69f230 100644 --- a/cint/demo/makecint/KRcc/Complex.h +++ b/cint/demo/makecint/KRcc/Complex.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/KRcc/stub.c b/cint/demo/makecint/KRcc/stub.c index 1cc825cec3e35..f656588e451d1 100644 --- a/cint/demo/makecint/KRcc/stub.c +++ b/cint/demo/makecint/KRcc/stub.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/KRcc/stub.h b/cint/demo/makecint/KRcc/stub.h index 850bc15e5fcb6..3c02939b21d3e 100644 --- a/cint/demo/makecint/KRcc/stub.h +++ b/cint/demo/makecint/KRcc/stub.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/KRcc/test.c b/cint/demo/makecint/KRcc/test.c index 6022577f80500..88d4a7e632b99 100644 --- a/cint/demo/makecint/KRcc/test.c +++ b/cint/demo/makecint/KRcc/test.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/ReadFile/Common.h b/cint/demo/makecint/ReadFile/Common.h index 8f8ad3fa7641f..1b10821176daf 100644 --- a/cint/demo/makecint/ReadFile/Common.h +++ b/cint/demo/makecint/ReadFile/Common.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/ReadFile/ReadFile.C b/cint/demo/makecint/ReadFile/ReadFile.C index 8ed7ed4bccf2b..e08e5c544f454 100644 --- a/cint/demo/makecint/ReadFile/ReadFile.C +++ b/cint/demo/makecint/ReadFile/ReadFile.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/ReadFile/ReadFile.h b/cint/demo/makecint/ReadFile/ReadFile.h index 595f2e26a791b..1f4a74d96f9c7 100644 --- a/cint/demo/makecint/ReadFile/ReadFile.h +++ b/cint/demo/makecint/ReadFile/ReadFile.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/ReadFile/test.C b/cint/demo/makecint/ReadFile/test.C index 814903c07569a..754a349c52a95 100644 --- a/cint/demo/makecint/ReadFile/test.C +++ b/cint/demo/makecint/ReadFile/test.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Stub/Src.C b/cint/demo/makecint/Stub/Src.C index 0c27ac9b8924b..9a1228ab04730 100644 --- a/cint/demo/makecint/Stub/Src.C +++ b/cint/demo/makecint/Stub/Src.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Stub/Src.h b/cint/demo/makecint/Stub/Src.h index 33a50bda332bd..8576c65aa5b7f 100644 --- a/cint/demo/makecint/Stub/Src.h +++ b/cint/demo/makecint/Stub/Src.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Stub/Stub.C b/cint/demo/makecint/Stub/Stub.C index 6fecef08edf7f..1313f9d4037ed 100644 --- a/cint/demo/makecint/Stub/Stub.C +++ b/cint/demo/makecint/Stub/Stub.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Stub/Stub.h b/cint/demo/makecint/Stub/Stub.h index b1496d05c1798..a583a9a70d419 100644 --- a/cint/demo/makecint/Stub/Stub.h +++ b/cint/demo/makecint/Stub/Stub.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Stub2/compiled.cxx b/cint/demo/makecint/Stub2/compiled.cxx index c808ff8eed983..1c32791e71697 100644 --- a/cint/demo/makecint/Stub2/compiled.cxx +++ b/cint/demo/makecint/Stub2/compiled.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Stub2/compiled.h b/cint/demo/makecint/Stub2/compiled.h index e47af80468901..067dcbad4fb3e 100644 --- a/cint/demo/makecint/Stub2/compiled.h +++ b/cint/demo/makecint/Stub2/compiled.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Stub2/dmy.h b/cint/demo/makecint/Stub2/dmy.h index eca74735143de..2cf8aa1af61de 100644 --- a/cint/demo/makecint/Stub2/dmy.h +++ b/cint/demo/makecint/Stub2/dmy.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Stub2/main.cxx b/cint/demo/makecint/Stub2/main.cxx index 112af2bb764ea..1e8a6dca4d21d 100644 --- a/cint/demo/makecint/Stub2/main.cxx +++ b/cint/demo/makecint/Stub2/main.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/Stub2/stub.h b/cint/demo/makecint/Stub2/stub.h index edbb040b26862..258fb67575976 100644 --- a/cint/demo/makecint/Stub2/stub.h +++ b/cint/demo/makecint/Stub2/stub.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/UserMain/UserMain.cxx b/cint/demo/makecint/UserMain/UserMain.cxx index 13df278fa84f2..6d25d35cc74f8 100644 --- a/cint/demo/makecint/UserMain/UserMain.cxx +++ b/cint/demo/makecint/UserMain/UserMain.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/UserMain/UserMain.h b/cint/demo/makecint/UserMain/UserMain.h index b8d2bcdc7e885..d925c4a8addf2 100644 --- a/cint/demo/makecint/UserMain/UserMain.h +++ b/cint/demo/makecint/UserMain/UserMain.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/UserMain/script.cxx b/cint/demo/makecint/UserMain/script.cxx index 95bad44cdbc83..bb078af7c2df5 100644 --- a/cint/demo/makecint/UserMain/script.cxx +++ b/cint/demo/makecint/UserMain/script.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/exception/eh.cxx b/cint/demo/makecint/exception/eh.cxx index d1fc6f2c28f46..009e1f6c33320 100644 --- a/cint/demo/makecint/exception/eh.cxx +++ b/cint/demo/makecint/exception/eh.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/exception/eh.h b/cint/demo/makecint/exception/eh.h index 723838370ecdf..2f62b37eb4207 100644 --- a/cint/demo/makecint/exception/eh.h +++ b/cint/demo/makecint/exception/eh.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/p2f/p2f.C b/cint/demo/makecint/p2f/p2f.C index 441ac08c4eabb..078a546cbcf06 100644 --- a/cint/demo/makecint/p2f/p2f.C +++ b/cint/demo/makecint/p2f/p2f.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/p2f/p2f.h b/cint/demo/makecint/p2f/p2f.h index ad924ce0d7317..e9151e86eb0b7 100644 --- a/cint/demo/makecint/p2f/p2f.h +++ b/cint/demo/makecint/p2f/p2f.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/p2f/test.C b/cint/demo/makecint/p2f/test.C index 42228d6e07af8..98ea470b6bb33 100644 --- a/cint/demo/makecint/p2f/test.C +++ b/cint/demo/makecint/p2f/test.C @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/stl/sample.h b/cint/demo/makecint/stl/sample.h index 6b217be0b979c..94eafad94e744 100644 --- a/cint/demo/makecint/stl/sample.h +++ b/cint/demo/makecint/stl/sample.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/makecint/stl/test.cxx b/cint/demo/makecint/stl/test.cxx index c71871e774119..8691ca9a55c83 100644 --- a/cint/demo/makecint/stl/test.cxx +++ b/cint/demo/makecint/stl/test.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/mthread/fork.cxx b/cint/demo/mthread/fork.cxx index 7c21a77fd17e1..59c420290e14d 100644 --- a/cint/demo/mthread/fork.cxx +++ b/cint/demo/mthread/fork.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/mthread/mtlib.h b/cint/demo/mthread/mtlib.h index ffc5bc42a751d..fa94346f34058 100644 --- a/cint/demo/mthread/mtlib.h +++ b/cint/demo/mthread/mtlib.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/mthread/mtmain.cxx b/cint/demo/mthread/mtmain.cxx index bcf1ffd08e987..6d5d0e8a39761 100644 --- a/cint/demo/mthread/mtmain.cxx +++ b/cint/demo/mthread/mtmain.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/mthread/ptlib.h b/cint/demo/mthread/ptlib.h index 8d27d053ced03..6449bc17854cd 100644 --- a/cint/demo/mthread/ptlib.h +++ b/cint/demo/mthread/ptlib.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/mthread/ptmain.cxx b/cint/demo/mthread/ptmain.cxx index ebbae693feccf..bb84c81603ded 100644 --- a/cint/demo/mthread/ptmain.cxx +++ b/cint/demo/mthread/ptmain.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/multilibcint/main.cxx b/cint/demo/multilibcint/main.cxx index bb29565158832..a3a1bb77e787c 100644 --- a/cint/demo/multilibcint/main.cxx +++ b/cint/demo/multilibcint/main.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/multilibcint/mt.c b/cint/demo/multilibcint/mt.c index 54a36e1ec9356..a05e2d665bedc 100644 --- a/cint/demo/multilibcint/mt.c +++ b/cint/demo/multilibcint/mt.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/multilibcint/mt.h b/cint/demo/multilibcint/mt.h index 22c76a5df0491..229b53aced23e 100644 --- a/cint/demo/multilibcint/mt.h +++ b/cint/demo/multilibcint/mt.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/multilibcint/test1.cxx b/cint/demo/multilibcint/test1.cxx index dfab17a158dc3..ea0eb86225845 100644 --- a/cint/demo/multilibcint/test1.cxx +++ b/cint/demo/multilibcint/test1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/multilibcint/test2.cxx b/cint/demo/multilibcint/test2.cxx index bb8a37cbd9af0..5b167fa7ae207 100644 --- a/cint/demo/multilibcint/test2.cxx +++ b/cint/demo/multilibcint/test2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/perlawk/parseplot.c b/cint/demo/perlawk/parseplot.c index 8d631c83cb170..d7bd48c3379b2 100644 --- a/cint/demo/perlawk/parseplot.c +++ b/cint/demo/perlawk/parseplot.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/posix/readdir.cxx b/cint/demo/posix/readdir.cxx index d5184a40a9c1e..90a2a7da5545b 100644 --- a/cint/demo/posix/readdir.cxx +++ b/cint/demo/posix/readdir.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/cannon.cpp b/cint/demo/qt/cannon.cpp index 6948d760f7db2..ebe4925ca8efd 100644 --- a/cint/demo/qt/cannon.cpp +++ b/cint/demo/qt/cannon.cpp @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/cannon.h b/cint/demo/qt/cannon.h index ce6160f4cc7d8..d4b07edb29cfb 100644 --- a/cint/demo/qt/cannon.h +++ b/cint/demo/qt/cannon.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/lcdrange.cpp b/cint/demo/qt/lcdrange.cpp index 8191052368385..8531cf01ac67e 100644 --- a/cint/demo/qt/lcdrange.cpp +++ b/cint/demo/qt/lcdrange.cpp @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/lcdrange.h b/cint/demo/qt/lcdrange.h index 68e03e9611be1..e9f808c5251aa 100644 --- a/cint/demo/qt/lcdrange.h +++ b/cint/demo/qt/lcdrange.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/moc_cannon.cpp b/cint/demo/qt/moc_cannon.cpp index 60441167562f2..2769e91b76a7a 100644 --- a/cint/demo/qt/moc_cannon.cpp +++ b/cint/demo/qt/moc_cannon.cpp @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/qcompactstyle.h b/cint/demo/qt/qcompactstyle.h index b89f549f29eab..8574a5d16ff6a 100644 --- a/cint/demo/qt/qcompactstyle.h +++ b/cint/demo/qt/qcompactstyle.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/qtstatic.cxx b/cint/demo/qt/qtstatic.cxx index 2e8cf456b1b44..7946ec39854fa 100644 --- a/cint/demo/qt/qtstatic.cxx +++ b/cint/demo/qt/qtstatic.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/test0.cxx b/cint/demo/qt/test0.cxx index 5c4ad6086b5ac..07cbe8a3956f0 100644 --- a/cint/demo/qt/test0.cxx +++ b/cint/demo/qt/test0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/test1.cxx b/cint/demo/qt/test1.cxx index 2eb5f9e4bf029..f736b9b14f7cd 100644 --- a/cint/demo/qt/test1.cxx +++ b/cint/demo/qt/test1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/test2.cxx b/cint/demo/qt/test2.cxx index 446e90799b4d9..534c083bf8ce1 100644 --- a/cint/demo/qt/test2.cxx +++ b/cint/demo/qt/test2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/test3.cxx b/cint/demo/qt/test3.cxx index 381e651338ad2..81353f8aed7b4 100644 --- a/cint/demo/qt/test3.cxx +++ b/cint/demo/qt/test3.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/test4.cxx b/cint/demo/qt/test4.cxx index 83d99013bb0f1..d03544088f53f 100644 --- a/cint/demo/qt/test4.cxx +++ b/cint/demo/qt/test4.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/test5.cxx b/cint/demo/qt/test5.cxx index abce82e6a0060..964778389d225 100644 --- a/cint/demo/qt/test5.cxx +++ b/cint/demo/qt/test5.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/test6.cxx b/cint/demo/qt/test6.cxx index e4512b3f110c8..ff92e5c0bacd2 100644 --- a/cint/demo/qt/test6.cxx +++ b/cint/demo/qt/test6.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/test7.cxx b/cint/demo/qt/test7.cxx index 545b3172d6ea4..25fb7ca69d490 100644 --- a/cint/demo/qt/test7.cxx +++ b/cint/demo/qt/test7.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/test7.h b/cint/demo/qt/test7.h index 73edd1af475d4..2234cd87475b9 100644 --- a/cint/demo/qt/test7.h +++ b/cint/demo/qt/test7.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/test8.cxx b/cint/demo/qt/test8.cxx index c00505834be3a..5ac94c184d0fa 100644 --- a/cint/demo/qt/test8.cxx +++ b/cint/demo/qt/test8.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/test8.h b/cint/demo/qt/test8.h index f133fe94b239d..43402a859d048 100644 --- a/cint/demo/qt/test8.h +++ b/cint/demo/qt/test8.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/qt/test9.cxx b/cint/demo/qt/test9.cxx index c0b15fcc74318..97ae4c7d5855a 100644 --- a/cint/demo/qt/test9.cxx +++ b/cint/demo/qt/test9.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/HelloWorld.c b/cint/demo/simple/HelloWorld.c index 98e4d9ae5aa0c..832758741af3d 100644 --- a/cint/demo/simple/HelloWorld.c +++ b/cint/demo/simple/HelloWorld.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/HelloWorld.cxx b/cint/demo/simple/HelloWorld.cxx index 22cf54e6dc110..b1113c37d6e65 100644 --- a/cint/demo/simple/HelloWorld.cxx +++ b/cint/demo/simple/HelloWorld.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/NativeCalc.c b/cint/demo/simple/NativeCalc.c index 495029e947450..b003e263199b8 100644 --- a/cint/demo/simple/NativeCalc.c +++ b/cint/demo/simple/NativeCalc.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/access0.c b/cint/demo/simple/access0.c index 3ff9ff0d376ec..25d3d9ecd06c4 100644 --- a/cint/demo/simple/access0.c +++ b/cint/demo/simple/access0.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/array.c b/cint/demo/simple/array.c index 8264b007fa073..c697e860bdbc7 100644 --- a/cint/demo/simple/array.c +++ b/cint/demo/simple/array.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/csum.c b/cint/demo/simple/csum.c index 187b7d3317474..759ec18dfa598 100644 --- a/cint/demo/simple/csum.c +++ b/cint/demo/simple/csum.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/inherit1.c b/cint/demo/simple/inherit1.c index 7a9c3ba08c63a..4bc023ab6bccb 100644 --- a/cint/demo/simple/inherit1.c +++ b/cint/demo/simple/inherit1.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/init.c b/cint/demo/simple/init.c index a0ae3c8b2333f..089790142170f 100644 --- a/cint/demo/simple/init.c +++ b/cint/demo/simple/init.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/oprovld.c b/cint/demo/simple/oprovld.c index d7f2ac961fe91..bca8573a81488 100644 --- a/cint/demo/simple/oprovld.c +++ b/cint/demo/simple/oprovld.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/oprovld0.c b/cint/demo/simple/oprovld0.c index df16845414265..b98ea56203a84 100644 --- a/cint/demo/simple/oprovld0.c +++ b/cint/demo/simple/oprovld0.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/scope0.c b/cint/demo/simple/scope0.c index c5a2f49aa0e7d..e5a0064cdb5be 100644 --- a/cint/demo/simple/scope0.c +++ b/cint/demo/simple/scope0.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/staticmem0.c b/cint/demo/simple/staticmem0.c index 645c254639cbb..f75eefb799d8c 100644 --- a/cint/demo/simple/staticmem0.c +++ b/cint/demo/simple/staticmem0.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/template0.c b/cint/demo/simple/template0.c index 2e76f1fa528ab..5b041fcae0944 100644 --- a/cint/demo/simple/template0.c +++ b/cint/demo/simple/template0.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/template2.c b/cint/demo/simple/template2.c index 12a2dc89d83b0..c0464015e9be4 100644 --- a/cint/demo/simple/template2.c +++ b/cint/demo/simple/template2.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/text2tex.c b/cint/demo/simple/text2tex.c index 18302f49daeb0..b2d9448113dcf 100644 --- a/cint/demo/simple/text2tex.c +++ b/cint/demo/simple/text2tex.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/simple/virtualfunc1.c b/cint/demo/simple/virtualfunc1.c index 8fbed23cc5171..5db9c8c767d5e 100644 --- a/cint/demo/simple/virtualfunc1.c +++ b/cint/demo/simple/virtualfunc1.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/README.txt b/cint/demo/stl/README.txt index d146626e43ca3..0b14aead8bc44 100644 --- a/cint/demo/stl/README.txt +++ b/cint/demo/stl/README.txt @@ -29,7 +29,7 @@ language may come out. Shall I invent a new technology on C++ based STL or will it end-up nonsense. 1998 Jan 10 - Masharu Goto cint@pcroot.cern.ch , gotom@jpn.hp.com + Masharu Goto root-cint@cern.ch , gotom@jpn.hp.com 2001/Sep/29 gcc-3.00 is supported from cint5.15.14. However, there are many problems diff --git a/cint/demo/stl/array2.cxx b/cint/demo/stl/array2.cxx index 9bbc26188b1a9..07be6420f524f 100644 --- a/cint/demo/stl/array2.cxx +++ b/cint/demo/stl/array2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/array4.cxx b/cint/demo/stl/array4.cxx index a0dbddaf3d433..a135615ad2404 100644 --- a/cint/demo/stl/array4.cxx +++ b/cint/demo/stl/array4.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/deque0.cxx b/cint/demo/stl/deque0.cxx index 644aace78ff6d..68481624d73b1 100644 --- a/cint/demo/stl/deque0.cxx +++ b/cint/demo/stl/deque0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/deque1.cxx b/cint/demo/stl/deque1.cxx index 9c354cef655c3..27f32e6ada806 100644 --- a/cint/demo/stl/deque1.cxx +++ b/cint/demo/stl/deque1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/deque1i.cxx b/cint/demo/stl/deque1i.cxx index 6644e2abef815..8826faeb5d8de 100644 --- a/cint/demo/stl/deque1i.cxx +++ b/cint/demo/stl/deque1i.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/list0.cxx b/cint/demo/stl/list0.cxx index 31f84e04d674f..15a9f57511e88 100644 --- a/cint/demo/stl/list0.cxx +++ b/cint/demo/stl/list0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/list1.cxx b/cint/demo/stl/list1.cxx index 055b5eea38caf..34caa5e3114d6 100644 --- a/cint/demo/stl/list1.cxx +++ b/cint/demo/stl/list1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/list2.cxx b/cint/demo/stl/list2.cxx index 2f990c688fc2c..9151fe7cc6c12 100644 --- a/cint/demo/stl/list2.cxx +++ b/cint/demo/stl/list2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/list3.cxx b/cint/demo/stl/list3.cxx index 64631b6991a92..838e924be8094 100644 --- a/cint/demo/stl/list3.cxx +++ b/cint/demo/stl/list3.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/list4.cxx b/cint/demo/stl/list4.cxx index 7602b9ad7a96c..38777134a3095 100644 --- a/cint/demo/stl/list4.cxx +++ b/cint/demo/stl/list4.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/map0.cxx b/cint/demo/stl/map0.cxx index cf9084ce9738e..0ef4a98a4fbec 100644 --- a/cint/demo/stl/map0.cxx +++ b/cint/demo/stl/map0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/stl0.cxx b/cint/demo/stl/stl0.cxx index efb3d765114e8..f6da1283e15ae 100644 --- a/cint/demo/stl/stl0.cxx +++ b/cint/demo/stl/stl0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/stl1.cxx b/cint/demo/stl/stl1.cxx index 8ba1b3136a502..a91449d50a712 100644 --- a/cint/demo/stl/stl1.cxx +++ b/cint/demo/stl/stl1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/stl2.cxx b/cint/demo/stl/stl2.cxx index 9bbc26188b1a9..07be6420f524f 100644 --- a/cint/demo/stl/stl2.cxx +++ b/cint/demo/stl/stl2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/stl3.cxx b/cint/demo/stl/stl3.cxx index 86f4ce54c20b4..959079dd3f7d9 100644 --- a/cint/demo/stl/stl3.cxx +++ b/cint/demo/stl/stl3.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/stl3x.cxx b/cint/demo/stl/stl3x.cxx index d4df455829daa..9d94b68c3cc5c 100644 --- a/cint/demo/stl/stl3x.cxx +++ b/cint/demo/stl/stl3x.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/stl4.cxx b/cint/demo/stl/stl4.cxx index 9864b5874891d..97936fb5fe591 100644 --- a/cint/demo/stl/stl4.cxx +++ b/cint/demo/stl/stl4.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/stl5.cxx b/cint/demo/stl/stl5.cxx index 6368d105c0912..e586d5408ec9a 100644 --- a/cint/demo/stl/stl5.cxx +++ b/cint/demo/stl/stl5.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/string0.cxx b/cint/demo/stl/string0.cxx index 06685490106ab..fac731fc8485a 100644 --- a/cint/demo/stl/string0.cxx +++ b/cint/demo/stl/string0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/vec0.cxx b/cint/demo/stl/vec0.cxx index 8ba1b3136a502..a91449d50a712 100644 --- a/cint/demo/stl/vec0.cxx +++ b/cint/demo/stl/vec0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/vec1.cxx b/cint/demo/stl/vec1.cxx index efb3d765114e8..f6da1283e15ae 100644 --- a/cint/demo/stl/vec1.cxx +++ b/cint/demo/stl/vec1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/vec1s.cxx b/cint/demo/stl/vec1s.cxx index d186035ad14e3..95ce630a45b26 100644 --- a/cint/demo/stl/vec1s.cxx +++ b/cint/demo/stl/vec1s.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/vec1u.cxx b/cint/demo/stl/vec1u.cxx index 274fe59f3637d..a2be138036647 100644 --- a/cint/demo/stl/vec1u.cxx +++ b/cint/demo/stl/vec1u.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/vec2.cxx b/cint/demo/stl/vec2.cxx index 86f4ce54c20b4..959079dd3f7d9 100644 --- a/cint/demo/stl/vec2.cxx +++ b/cint/demo/stl/vec2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/vec3.cxx b/cint/demo/stl/vec3.cxx index 75b5bb5bab04f..a3bb3728892e8 100644 --- a/cint/demo/stl/vec3.cxx +++ b/cint/demo/stl/vec3.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/vec3t.cxx b/cint/demo/stl/vec3t.cxx index 898eb4684aee3..bd62d36967006 100644 --- a/cint/demo/stl/vec3t.cxx +++ b/cint/demo/stl/vec3t.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/stl/vec4.cxx b/cint/demo/stl/vec4.cxx index b8fb81d72860e..ec2d2a1831564 100644 --- a/cint/demo/stl/vec4.cxx +++ b/cint/demo/stl/vec4.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/tcpip/client.cxx b/cint/demo/tcpip/client.cxx index 370fcf17ffc72..260885314982a 100644 --- a/cint/demo/tcpip/client.cxx +++ b/cint/demo/tcpip/client.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/tcpip/server.cxx b/cint/demo/tcpip/server.cxx index c30c0c31b48a0..2663b38312d48 100644 --- a/cint/demo/tcpip/server.cxx +++ b/cint/demo/tcpip/server.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/demo/xlib/test.c b/cint/demo/xlib/test.c index 323bdef24d69a..26947f29aaf7c 100644 --- a/cint/demo/xlib/test.c +++ b/cint/demo/xlib/test.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/doc/bytecode.txt b/cint/doc/bytecode.txt index 9605caef2318b..410e7ef5ca4e8 100644 --- a/cint/doc/bytecode.txt +++ b/cint/doc/bytecode.txt @@ -14,7 +14,7 @@ choose level of bytecode optimization by '-O[n]' command line option or O4 : + function called within a loop is bytecode compiled O5 : All interpreted functions will be bytecode compiled when called -Default is O4. You need to consult cint@pcroot.cern.ch when using O5. +Default is O4. You need to consult root-cint@cern.ch when using O5. There is another level O10 , but this can be only used with special care. (Not recommended, only experimental) diff --git a/cint/doc/cint.txt b/cint/doc/cint.txt index f9df832ffb298..5ee96d5ff1030 100644 --- a/cint/doc/cint.txt +++ b/cint/doc/cint.txt @@ -242,7 +242,7 @@ SEE ALSO AUTHOR - Masaharu Goto (cint@pcroot.cern.ch) + Masaharu Goto (root-cint@cern.ch) Copyright (c) 1995~2000 Masaharu Goto diff --git a/cint/doc/cintapi.txt b/cint/doc/cintapi.txt index 57e85e4d19ef6..c2861f3e5e2d0 100644 --- a/cint/doc/cintapi.txt +++ b/cint/doc/cintapi.txt @@ -266,7 +266,7 @@ Undeclared symbol BUGS - Report bugs and requirements to cint@pcroot.cern.ch. Bugs + Report bugs and requirements to root-cint@cern.ch. Bugs tend to be fixed very quickly. Any kind of comments or messages will be appreciated. @@ -275,7 +275,7 @@ SEE ALSO AUTHOR - Masaharu Goto (cint@pcroot.cern.ch) + Masaharu Goto (root-cint@cern.ch) Copyright (c) 1995~1999 Masaharu Goto diff --git a/cint/doc/ifdef.txt b/cint/doc/ifdef.txt index c7c331ab43725..12398eb72d7cd 100644 --- a/cint/doc/ifdef.txt +++ b/cint/doc/ifdef.txt @@ -198,5 +198,5 @@ COMMENT AUTHOR - Masaharu Goto (cint@pcroot.cern.ch) + Masaharu Goto (root-cint@cern.ch) Copyright (c) 1994~2001 Masaharu Goto diff --git a/cint/doc/limitati.txt b/cint/doc/limitati.txt index 8588d0f160dae..2e25e6ad5a97c 100644 --- a/cint/doc/limitati.txt +++ b/cint/doc/limitati.txt @@ -709,7 +709,7 @@ Limitation of CINT because the 'MyNtuple' inside the function call is not properly parsed. # BUGS - Report bugs and requirements to cint@pcroot.cern.ch. Bugs tend to + Report bugs and requirements to root-cint@cern.ch. Bugs tend to be fixed very quickly. Any kind of comments or messages will be appreciated. # SEE ALSO @@ -717,5 +717,5 @@ Limitation of CINT # AUTHOR - Masaharu Goto (cint@pcroot.cern.ch) + Masaharu Goto (root-cint@cern.ch) Copyright (c) 1995~2002 Masaharu Goto diff --git a/cint/doc/makecint.txt b/cint/doc/makecint.txt index 842988dea782d..1ef3b1aaa1eb5 100644 --- a/cint/doc/makecint.txt +++ b/cint/doc/makecint.txt @@ -17,7 +17,7 @@ DESCRIPTION (This sounds smooth, however, I recommend to start from very simple example. Linking non-trivial library won't be - easy. Contact cint@pcroot.cern.ch if you need help.) + easy. Contact root-cint@cern.ch if you need help.) @@ -849,7 +849,7 @@ OPTIONS BUGS - Report bugs and requirements to: cint@pcroot.cern.ch. Bugs + Report bugs and requirements to: root-cint@cern.ch. Bugs tend actually to be fixed if they can be isolated, so it is in your interest to report them in such a way that they can be easily reproduced. If will be helpful if you send @@ -862,6 +862,6 @@ SEE ALSO AUTHOR - Masaharu Goto (cint@pcroot.cern.ch) + Masaharu Goto (root-cint@cern.ch) Copyright (c) 1995~2000 Masaharu Goto diff --git a/cint/doc/ref.txt b/cint/doc/ref.txt index 96fb34f633dc2..1791b47de3144 100644 --- a/cint/doc/ref.txt +++ b/cint/doc/ref.txt @@ -2,7 +2,7 @@ doc/ref.txt Reference manual for cint/makecint. - Masaharu Goto (cint@pcroot.cern.ch) + Masaharu Goto (root-cint@cern.ch) Copyright (c) 1995~2004 Masaharu Goto This document explains cint/makecint features and functionalities @@ -1926,7 +1926,7 @@ G__calc() G__value G__calc(const char* expression) // precompiled library environment G__calc() API evaluates C/C++ expression and returns its' value. -In interpreter enviroment, type of the return value is automatically +In interpreter environment, type of the return value is automatically converted to suitable type without explicit type casting. In precompiled library environment, it returns G__value object which can be converted to long or double type object by G__double() or G__int() @@ -2571,7 +2571,7 @@ G__exec_text() G__value G__exec_text(const char* unmamedmacro); // from precompiled code G__exec_text() API evaluates C/C++ statements and returns its' value. -In interpreter enviroment, type of the return value is automatically +In interpreter environment, type of the return value is automatically converted to suitable type without explicit type casting. In compiled code , it returns G__value object which can be converted to long or double type object by G__double() or G__int() API. diff --git a/cint/iosenum/iosenum.linuxarm3 b/cint/iosenum/iosenum.linuxarm3 new file mode 100644 index 0000000000000..0465c64c8348d --- /dev/null +++ b/cint/iosenum/iosenum.linuxarm3 @@ -0,0 +1,38 @@ +/* include/platform/iosenum.h + * This file contains platform dependent ios enum value. + * Run 'cint iosenum.cxx' to create this file. It is done + * only once at installation. */ +#pragma ifndef G__TMPLTIOS +#pragma else +static ios_base::fmtflags ios_base::boolalpha=1; +static ios_base::fmtflags ios_base::dec=2; +static ios_base::fmtflags ios_base::fixed=4; +static ios_base::fmtflags ios_base::hex=8; +static ios_base::fmtflags ios_base::internal=16; +static ios_base::fmtflags ios_base::left=32; +static ios_base::fmtflags ios_base::oct=64; +static ios_base::fmtflags ios_base::right=128; +static ios_base::fmtflags ios_base::scientific=256; +static ios_base::fmtflags ios_base::showbase=512; +static ios_base::fmtflags ios_base::showpoint=1024; +static ios_base::fmtflags ios_base::showpos=2048; +static ios_base::fmtflags ios_base::skipws=4096; +static ios_base::fmtflags ios_base::unitbuf=8192; +static ios_base::fmtflags ios_base::uppercase=16384; +static ios_base::fmtflags ios_base::adjustfield=176; +static ios_base::fmtflags ios_base::basefield=74; +static ios_base::fmtflags ios_base::floatfield=260; +static ios_base::fmtflags ios_base::badbit=1; +static ios_base::fmtflags ios_base::eofbit=2; +static ios_base::fmtflags ios_base::failbit=4; +static ios_base::fmtflags ios_base::goodbit=0; +static ios_base::fmtflags ios_base::app=1; +static ios_base::fmtflags ios_base::ate=2; +static ios_base::fmtflags ios_base::binary=4; +static ios_base::fmtflags ios_base::in=8; +static ios_base::fmtflags ios_base::out=16; +static ios_base::fmtflags ios_base::trunc=32; +static ios_base::fmtflags ios_base::beg=0; +static ios_base::fmtflags ios_base::cur=1; +static ios_base::fmtflags ios_base::end=2; +#pragma endif diff --git a/cint/iosenum/iosenum.linuxx8664k1omicc b/cint/iosenum/iosenum.linuxx8664k1omicc new file mode 100644 index 0000000000000..ee97bc7feb0d4 --- /dev/null +++ b/cint/iosenum/iosenum.linuxx8664k1omicc @@ -0,0 +1,69 @@ +/* include/platform/iosenum.h + * This file contains platform dependent ios enum value. + * Run 'cint iosenum.cxx' to create this file. It is done + * only once at installation. */ +#pragma ifndef G__TMPLTIOS +static int ios::goodbit=0; +static int ios::eofbit=2; +static int ios::failbit=4; +static int ios::badbit=1; +static int ios::in=8; +static int ios::out=16; +static int ios::ate=2; +static int ios::app=1; +static int ios::trunc=32; +static int ios::binary=4; +static int ios::beg=0; +static int ios::cur=1; +static int ios::end=2; +static int ios::boolalpha=1; +static int ios::adjustfield=176; +static int ios::basefield=74; +static int ios::floatfield=260; +static int ios::skipws=4096; +static int ios::left=32; +static int ios::right=128; +static int ios::internal=16; +static int ios::dec=2; +static int ios::oct=64; +static int ios::hex=8; +static int ios::showbase=512; +static int ios::showpoint=1024; +static int ios::uppercase=16384; +static int ios::showpos=2048; +static int ios::scientific=256; +static int ios::fixed=4; +static int ios::unitbuf=8192; +#pragma else +static ios_base::fmtflags ios_base::boolalpha=1; +static ios_base::fmtflags ios_base::dec=2; +static ios_base::fmtflags ios_base::fixed=4; +static ios_base::fmtflags ios_base::hex=8; +static ios_base::fmtflags ios_base::internal=16; +static ios_base::fmtflags ios_base::left=32; +static ios_base::fmtflags ios_base::oct=64; +static ios_base::fmtflags ios_base::right=128; +static ios_base::fmtflags ios_base::scientific=256; +static ios_base::fmtflags ios_base::showbase=512; +static ios_base::fmtflags ios_base::showpoint=1024; +static ios_base::fmtflags ios_base::showpos=2048; +static ios_base::fmtflags ios_base::skipws=4096; +static ios_base::fmtflags ios_base::unitbuf=8192; +static ios_base::fmtflags ios_base::uppercase=16384; +static ios_base::fmtflags ios_base::adjustfield=176; +static ios_base::fmtflags ios_base::basefield=74; +static ios_base::fmtflags ios_base::floatfield=260; +static ios_base::fmtflags ios_base::badbit=1; +static ios_base::fmtflags ios_base::eofbit=2; +static ios_base::fmtflags ios_base::failbit=4; +static ios_base::fmtflags ios_base::goodbit=0; +static ios_base::fmtflags ios_base::app=1; +static ios_base::fmtflags ios_base::ate=2; +static ios_base::fmtflags ios_base::binary=4; +static ios_base::fmtflags ios_base::in=8; +static ios_base::fmtflags ios_base::out=16; +static ios_base::fmtflags ios_base::trunc=32; +static ios_base::fmtflags ios_base::beg=0; +static ios_base::fmtflags ios_base::cur=1; +static ios_base::fmtflags ios_base::end=2; +#pragma endif diff --git a/cint/reflex/CMakeLists.txt b/cint/reflex/CMakeLists.txt index 647e4878dbb33..0cda3a0af070b 100644 --- a/cint/reflex/CMakeLists.txt +++ b/cint/reflex/CMakeLists.txt @@ -20,14 +20,17 @@ if(CMAKE_PROJECT_NAME STREQUAL ROOT) #---Reflex library--------------------------------------------------------- ROOT_LINKER_LIBRARY(Reflex *.cxx LIBRARIES ${CMAKE_DL_LIBS}) #---genreflex files-------------------------------------------------------- - install(CODE "file(WRITE ${CMAKE_INSTALL_PREFIX}/lib/python/genreflex/gccxmlpath.py \"gccxmlpath = '${GCCXML_EXECUTABLE}'\n\")") - install(DIRECTORY python/genreflex DESTINATION lib/python FILES_MATCHING PATTERN "*.py" PATTERN ".svn" EXCLUDE) - install(CODE "execute_process(COMMAND python -m compileall ${CMAKE_INSTALL_PREFIX}/lib/python/genreflex)") + install(CODE "file(WRITE \$ENV{DESTDIR}${CMAKE_INSTALL_FULL_LIBDIR}/python/genreflex/gccxmlpath.py \"gccxmlpath = '${GCCXML_EXECUTABLE}'\n\")") + install(DIRECTORY python/genreflex DESTINATION ${CMAKE_INSTALL_LIBDIR}/python FILES_MATCHING PATTERN "*.py" PATTERN ".svn" EXCLUDE) + install(CODE "execute_process(COMMAND python -m compileall \$ENV{DESTDIR}${CMAKE_INSTALL_FULL_LIBDIR}/python/genreflex)") #---genmap executable------------------------------------------------------ ROOT_EXECUTABLE(genmap genmap/genmap.cxx LIBRARIES Reflex ${CMAKE_DL_LIBS}) #---install headers-------------------------------------------------------- - ROOT_INSTALL_HEADERS() - + #ROOT_INSTALL_HEADERS() + install(DIRECTORY inc/Reflex/ DESTINATION ${CMAKE_INSTALL_INCDIR}/Reflex + PATTERN ".svn" EXCLUDE + PATTERN "Makefile.am" EXCLUDE + REGEX "LinkDef" EXCLUDE ) else() PROJECT(Reflex) CMAKE_MINIMUM_REQUIRED(VERSION 2.6.0 FATAL_ERROR) diff --git a/cint/reflex/doc/ChangeLog.reflex b/cint/reflex/doc/ChangeLog.reflex index 932959e6b3b6d..0fa65a450d0f7 100644 --- a/cint/reflex/doc/ChangeLog.reflex +++ b/cint/reflex/doc/ChangeLog.reflex @@ -348,7 +348,7 @@ type -> TypeInfo * stl_hash.h: removed namespace define for icc compilers 2005-06-17 Pere - * CollectionProxy.h: commited changes from Markus + * CollectionProxy.h: committed changes from Markus 2005-06-10 Pere * TypeBuilder.cpp(.h) added EnumTypeBuilder() function diff --git a/cint/reflex/inc/Reflex/Builder/CollectionProxy.h b/cint/reflex/inc/Reflex/Builder/CollectionProxy.h index e82cbef07fb5c..373ee3ed8b0be 100644 --- a/cint/reflex/inc/Reflex/Builder/CollectionProxy.h +++ b/cint/reflex/inc/Reflex/Builder/CollectionProxy.h @@ -13,6 +13,9 @@ #define Reflex_CollectionProxy 1 1 #include +#include +#include +#include // Macro indicating the version of the Collection Proxy interface followed // by this Reflex build, this must match the version number of @@ -21,332 +24,519 @@ #define REFLEX_COLLECTIONPROXY_VERSION 3 // Forward declarations + +class TVirtualCollectionProxy; + namespace std { -template class deque; -template class vector; -template class list; -template class queue; -template class stack; -template class set; -template class multiset; -template class map; -template class multimap; -template class allocator; + template class deque; + //template class vector; + template class list; + template class queue; + template class stack; + template class set; + template class multiset; + //template class map; + template class multimap; + //template class allocator; } // Hash map forward declarations #if defined(__GNUC__) namespace __gnu_cxx { // GNU GCC -template class hash_set; -template class hash_multiset; -template class hash_map; -template class hash_multimap; + template class hash_set; + template class hash_multiset; + template class hash_map; + template class hash_multimap; } #elif defined(_WIN32) namespace stdext { // Visual C++ -template class hash_set; -template class hash_multiset; -template class hash_map; -template class hash_multimap; + template class hash_set; + template class hash_multiset; + template class hash_map; + template class hash_multimap; } #endif namespace Reflex { #ifndef __CINT__ -struct EnvironBase { + struct EnvironBase { EnvironBase(): fIdx(0), - fSize(0), - fObject(0), - fStart(0), - fTemp(0), - fDeleteTemp(false), - fRefSize(1), - fSpace(0) { + fSize(0), + fObject(0), + fStart(0), + fTemp(0), + fDeleteTemp(false), + fRefSize(1), + fSpace(0) { // fprintf("Running default constructor on %p\n",this); } - virtual ~EnvironBase() {} - - size_t fIdx; - size_t fSize; - void* fObject; - void* fStart; - void* fTemp; - bool fDeleteTemp; - int fRefSize; - size_t fSpace; -}; -template struct Environ: public EnvironBase { - typedef T Iter_t; - Iter_t fIterator; - T& - iter() { return fIterator; } - - static void* - Create() { - return new Environ(); - } + virtual ~EnvironBase() {} + size_t fIdx; + size_t fSize; + void* fObject; + void* fStart; + void* fTemp; + bool fDeleteTemp; + int fRefSize; + size_t fSpace; + }; -}; + template struct Environ: public EnvironBase { + typedef T Iter_t; + Iter_t fIterator; + T& + iter() { return fIterator; } + + static void* + Create() { + return new Environ(); + } + }; #else -struct EnvironBase; -template struct Environ; + struct EnvironBase; + template struct Environ; #endif -template struct Address { - static void* - address(T ref) { - return (void*)& ref; - } - - -}; - -template struct CollType + template struct Address { + static void* + address(T ref) { + return (void*)& ref; + } + }; + + // Same value as TVirtualCollectionProxy. + static const unsigned int fgIteratorArenaSize = 16; // greater than sizeof(void*) + sizeof(UInt_t) + + /** @class template TCollectionProxyInfo::IteratorValue + * + * Small helper to encapsulate whether to return the value + * pointed to by the iterator or its address. + * + **/ + + template struct IteratorValue { + static void* get(typename Cont_t::iterator &iter) { + return (void*)&(*iter); + } + }; + + template struct IteratorValue { + static void* get(typename Cont_t::iterator &iter) { + return (void*)(*iter); + } + }; + + template <> struct IteratorValue,bool> { + static void* get(std::vector::iterator & /* iter */) { + return 0; + } + }; + + /** @class template TCollectionProxyInfo::Iterators + * + * Small helper to implement the function to create,access and destroy + * iterators. + * + **/ + + template + struct Iterators { + typedef Cont_t *PCont_t; + typedef typename Cont_t::iterator iterator; + + static void create(void *coll, void **begin_arena, void **end_arena, TVirtualCollectionProxy *) { + PCont_t c = PCont_t(coll); + new (*begin_arena) iterator(c->begin()); + new (*end_arena) iterator(c->end()); + } + static void* copy(void *dest_arena, const void *source_ptr) { + iterator *source = (iterator *)(source_ptr); + new (dest_arena) iterator(*source); + return dest_arena; + } + static void* next(void *iter_loc, const void *end_loc) { + iterator *end = (iterator *)(end_loc); + iterator *iter = (iterator *)(iter_loc); + if (*iter != *end) { + void *result = IteratorValue::get(*iter); + ++(*iter); + return result; + } + return 0; + } + static void destruct1(void *iter_ptr) { + iterator *start = (iterator *)(iter_ptr); + start->~iterator(); + } + static void destruct2(void *begin_ptr, void *end_ptr) { + iterator *start = (iterator *)(begin_ptr); + iterator *end = (iterator *)(end_ptr); + start->~iterator(); + end->~iterator(); + } + }; + + // For Vector we take an extra short cut to avoid derefencing + // the iterator all the time and redefine the 'address' of the + // iterator as the iterator itself. This requires special handling + // in the looper (see TStreamerInfoAction) but is much faster. + template struct Iterators, false> { + typedef std::vector Cont_t; + typedef Cont_t *PCont_t; + typedef typename Cont_t::iterator iterator; + + static void create(void *coll, void **begin_arena, void **end_arena, TVirtualCollectionProxy *) { + PCont_t c = PCont_t(coll); + if (c->empty()) { + *begin_arena = 0; + *end_arena = 0; + return; + } + *begin_arena = &(*c->begin()); +#ifdef R__VISUAL_CPLUSPLUS + *end_arena = &(*(c->end()-1)) + 1; // On windows we can not dererence the end iterator at all. +#else + // coverity[past_the_end] Safe on other platforms + *end_arena = &(*c->end()); +#endif + } + static void* copy(void *dest, const void *source) { + *(void**)dest = *(void**)source; + return dest; + } + static void* next(void * /* iter_loc */, const void * /* end_loc */) { + // Should not be used. + assert(0 && "Intentionally not implemented, do not use."); + return 0; + } + static void destruct1(void * /* iter_ptr */) { + // Nothing to do + } + static void destruct2(void * /* begin_ptr */, void * /* end_ptr */) { + // Nothing to do + } + }; + + template <> struct Iterators, false> { + typedef std::vector Cont_t; + typedef Cont_t *PCont_t; + typedef Cont_t::iterator iterator; + + static void create(void *coll, void **begin_arena, void **end_arena, TVirtualCollectionProxy *) { + PCont_t c = PCont_t(coll); + new (*begin_arena) iterator(c->begin()); + new (*end_arena) iterator(c->end()); + } + static void* copy(void *dest_arena, const void *source_ptr) { + iterator *source = (iterator *)(source_ptr); + new (dest_arena) iterator(*source); + return dest_arena; + } + static void* next(void *iter_loc, const void *end_loc) { + iterator *end = (iterator *)(end_loc); + iterator *iter = (iterator *)(iter_loc); + if (*iter != *end) { + void *result = IteratorValue::get(*iter); + ++(*iter); + return result; + } + return 0; + } + static void destruct1(void *iter_ptr) { + iterator *start = (iterator *)(iter_ptr); + start->~iterator(); + } + static void destruct2(void *begin_ptr, void *end_ptr) { + iterator *start = (iterator *)(begin_ptr); + iterator *end = (iterator *)(end_ptr); + start->~iterator(); + end->~iterator(); + } + }; + + template struct Iterators { + typedef Cont_t *PCont_t; + typedef typename Cont_t::iterator iterator; + + static void create(void *coll, void **begin_arena, void **end_arena, TVirtualCollectionProxy *) { + PCont_t c = PCont_t(coll); + *begin_arena = new iterator(c->begin()); + *end_arena = new iterator(c->end()); + } + static void* copy(void * /*dest_arena*/, const void *source_ptr) { + iterator *source = (iterator *)(source_ptr); + void *iter = new iterator(*source); + return iter; + } + static void* next(void *iter_loc, const void *end_loc) { + iterator *end = (iterator *)(end_loc); + iterator *iter = (iterator *)(iter_loc); + if (*iter != *end) { + void *result = IteratorValue::get(*iter); + ++(*iter); + return result; + } + return 0; + } + static void destruct1(void *begin_ptr) { + iterator *start = (iterator *)(begin_ptr); + delete start; + } + static void destruct2(void *begin_ptr, void *end_ptr) { + iterator *start = (iterator *)(begin_ptr); + iterator *end = (iterator *)(end_ptr); + delete start; + delete end; + } + }; + + template struct CollType #ifdef _KCC // KAI compiler - : public Address + : public Address #else - : public Address + : public Address #endif -{ + { #ifdef _KCC // KAI compiler - typedef Address Address_t; + typedef Address Address_t; #else - typedef Address Address_t; + typedef Address Address_t; #endif - typedef T Cont_t; - typedef typename T::iterator Iter_t; - typedef typename T::value_type Value_t; - typedef Reflex::Environ Env_t; - typedef Env_t* PEnv_t; - typedef Cont_t* PCont_t; - typedef Value_t* PValue_t; - - static inline PCont_t - object(void* ptr) { - return PCont_t(PEnv_t(ptr)->fObject); - } - - - static void* - size(void* env) { - PEnv_t e = PEnv_t(env); - e->fSize = PCont_t(e->fObject)->size(); - return &e->fSize; - } - - - static void* - clear(void* env) { - object(env)->clear(); - return 0; - } - - - static void* - first(void* env) { - PEnv_t e = PEnv_t(env); - PCont_t c = PCont_t(e->fObject); - // Assume iterators do not need destruction - e->fIterator = c->begin(); - e->fSize = c->size(); - - if (0 == e->fSize) { return e->fStart = 0; } + typedef T Cont_t; + typedef typename T::iterator Iter_t; + typedef typename T::value_type Value_t; + typedef Reflex::Environ Env_t; + typedef Env_t* PEnv_t; + typedef Cont_t* PCont_t; + typedef Value_t* PValue_t; + + static inline PCont_t + object(void* ptr) { + return PCont_t(PEnv_t(ptr)->fObject); + } + + + static void* + size(void* env) { + PEnv_t e = PEnv_t(env); + e->fSize = PCont_t(e->fObject)->size(); + return &e->fSize; + } + + + static void* + clear(void* env) { + object(env)->clear(); + return 0; + } + + + static void* + first(void* env) { + PEnv_t e = PEnv_t(env); + PCont_t c = PCont_t(e->fObject); + // Assume iterators do not need destruction + e->fIterator = c->begin(); + e->fSize = c->size(); + + if (0 == e->fSize) { return e->fStart = 0; } #ifdef _KCC // KAI compiler - typename T::value_type& ref = *(e->iter()); + typename T::value_type& ref = *(e->iter()); #else - typename T::const_reference ref = *(e->iter()); + typename T::const_reference ref = *(e->iter()); #endif - return e->fStart = Address_t::address(ref); - } + return e->fStart = Address_t::address(ref); + } - static void* - next(void* env) { - PEnv_t e = PEnv_t(env); - PCont_t c = PCont_t(e->fObject); + static void* + next(void* env) { + PEnv_t e = PEnv_t(env); + PCont_t c = PCont_t(e->fObject); - for ( ; e->fIdx > 0 && e->iter() != c->end(); ++(e->iter()), --e->fIdx) {} + for ( ; e->fIdx > 0 && e->iter() != c->end(); ++(e->iter()), --e->fIdx) {} - // TODO: Need to find something for going backwards.... - if (e->iter() == c->end()) { return 0; } + // TODO: Need to find something for going backwards.... + if (e->iter() == c->end()) { return 0; } #ifdef _KCC // KAI compiler - typename T::value_type& ref = *(e->iter()); + typename T::value_type& ref = *(e->iter()); #else - typename T::const_reference ref = *(e->iter()); + typename T::const_reference ref = *(e->iter()); #endif - return Address_t::address(ref); - } - - - static void* - construct(void* what, size_t size) { - PValue_t m = PValue_t(what); - - for (size_t i = 0; i < size; ++i, ++m) { - ::new (m) Value_t(); + return Address_t::address(ref); + } + + + static void* + construct(void* what, size_t size) { + PValue_t m = PValue_t(what); + + for (size_t i = 0; i < size; ++i, ++m) { + ::new (m) Value_t(); + } + return 0; + } + + + static void* + collect(void* coll, void *array) { + PCont_t c = PCont_t(coll); + PValue_t m = PValue_t(array); + + for (Iter_t i = c->begin(); i != c->end(); ++i, ++m) { + ::new (m) Value_t(*i); + } + return 0; + } + + + static void + destruct(void* what, size_t size) { + PValue_t m = PValue_t(what); + + for (size_t i = 0; i < size; ++i, ++m) { + m->~Value_t(); + } + } + + static const bool fgLargeIterator = sizeof(typename Cont_t::iterator) > fgIteratorArenaSize; + typedef Iterators Iterators_t; + + }; + + /** @class TCollectionProxy::Map TCollectionProxy.h TCollectionProxy.h + * + * Small helper to encapsulate all necessary data accesses for + * containers like vector, list, deque + * + * @author M.Frank + * @version 1.0 + * @date 10/10/2004 + */ + template struct Pushback: public CollType { + typedef T Cont_t; + typedef typename T::iterator Iter_t; + typedef typename T::value_type Value_t; + typedef Environ Env_t; + typedef Env_t* PEnv_t; + typedef Cont_t* PCont_t; + typedef Value_t* PValue_t; + static void resize(void* obj, size_t n) { + PCont_t c = PCont_t(obj); + c->resize(n); } - return 0; - } - - static void* - collect(void* env) { - PEnv_t e = PEnv_t(env); - PCont_t c = PCont_t(e->fObject); - PValue_t m = PValue_t(e->fStart); + static void* + feed(void*from,void *to,size_t size) { + PValue_t m = PValue_t(from); + PCont_t c = PCont_t(to); - for (Iter_t i = c->begin(); i != c->end(); ++i, ++m) { - ::new (m) Value_t(*i); + for (size_t i = 0; i < size; ++i, ++m) { + c->push_back(*m); + } + return 0; } - return 0; - } - static void - destruct(void* what, size_t size) { - PValue_t m = PValue_t(what); - - for (size_t i = 0; i < size; ++i, ++m) { - m->~Value_t(); + static int + value_offset() { + return 0; } - } -}; - -/** @class TCollectionProxy::Map TCollectionProxy.h TCollectionProxy.h - * - * Small helper to encapsulate all necessary data accesses for - * containers like vector, list, deque - * - * @author M.Frank - * @version 1.0 - * @date 10/10/2004 - */ -template struct Pushback: public CollType { - typedef T Cont_t; - typedef typename T::iterator Iter_t; - typedef typename T::value_type Value_t; - typedef Environ Env_t; - typedef Env_t* PEnv_t; - typedef Cont_t* PCont_t; - typedef Value_t* PValue_t; - static void resize(void* obj, size_t n) { - PCont_t c = PCont_t(obj); - c->resize(n); - } - - static void* - feed(void*from,void *to,size_t size) { - PValue_t m = PValue_t(from); - PCont_t c = PCont_t(to); - - for (size_t i = 0; i < size; ++i, ++m) { - c->push_back(*m); + }; + + /** @class TCollectionProxy::Map TCollectionProxy.h TCollectionProxy.h + * + * Small helper to encapsulate all necessary data accesses for + * containers like set, multiset etc. + * + * @author M.Frank + * @version 1.0 + * @date 10/10/2004 + */ + template struct Insert: public CollType { + typedef T Cont_t; + typedef typename T::iterator Iter_t; + typedef typename T::value_type Value_t; + typedef Environ Env_t; + typedef Env_t* PEnv_t; + typedef Cont_t* PCont_t; + typedef Value_t* PValue_t; + + static void* + feed(void*from,void*to,size_t size) { + PValue_t m = PValue_t(from); + PCont_t c = PCont_t(to); + + for (size_t i = 0; i < size; ++i, ++m) { + c->insert(*m); + } + return 0; } - return 0; - } - static int - value_offset() { - return 0; - } + static void resize(void* /* obj */, size_t) { } -}; - -/** @class TCollectionProxy::Map TCollectionProxy.h TCollectionProxy.h - * - * Small helper to encapsulate all necessary data accesses for - * containers like set, multiset etc. - * - * @author M.Frank - * @version 1.0 - * @date 10/10/2004 - */ -template struct Insert: public CollType { - typedef T Cont_t; - typedef typename T::iterator Iter_t; - typedef typename T::value_type Value_t; - typedef Environ Env_t; - typedef Env_t* PEnv_t; - typedef Cont_t* PCont_t; - typedef Value_t* PValue_t; - - static void* - feed(void*from,void*to,size_t size) { - PValue_t m = PValue_t(from); - PCont_t c = PCont_t(to); - - for (size_t i = 0; i < size; ++i, ++m) { - c->insert(*m); + static int + value_offset() { + return 0; } - return 0; - } - - - static void resize(void* /* obj */, size_t) { } - - static int - value_offset() { - return 0; - } - -}; - -/** @class TCollectionProxy::Map TCollectionProxy.h TCollectionProxy.h - * - * Small helper to encapsulate all necessary data accesses for - * containers like Set, multiset etc. - * - * @author M.Frank - * @version 1.0 - * @date 10/10/2004 - */ -template struct MapInsert: public CollType { - typedef T Cont_t; - typedef typename T::iterator Iter_t; - typedef typename T::value_type Value_t; - typedef Environ Env_t; - typedef Env_t* PEnv_t; - typedef Cont_t* PCont_t; - typedef Value_t* PValue_t; - - static void* - feed(void*from,void *to,size_t size) { - PValue_t m = PValue_t(from); - PCont_t c = PCont_t(to); - - for (size_t i = 0; i < size; ++i, ++m) { - c->insert(*m); + }; + + /** @class TCollectionProxy::Map TCollectionProxy.h TCollectionProxy.h + * + * Small helper to encapsulate all necessary data accesses for + * containers like Set, multiset etc. + * + * @author M.Frank + * @version 1.0 + * @date 10/10/2004 + */ + template struct MapInsert: public CollType { + typedef T Cont_t; + typedef typename T::iterator Iter_t; + typedef typename T::value_type Value_t; + typedef Environ Env_t; + typedef Env_t* PEnv_t; + typedef Cont_t* PCont_t; + typedef Value_t* PValue_t; + + static void* + feed(void*from,void *to,size_t size) { + PValue_t m = PValue_t(from); + PCont_t c = PCont_t(to); + + for (size_t i = 0; i < size; ++i, ++m) { + c->insert(*m); + } + return 0; } - return 0; - } - static void resize(void* /* obj */, size_t) { - } + static void resize(void* /* obj */, size_t) { + } - static int - value_offset() { - return ((char*) &((PValue_t(0x1000))->second)) - ((char*) PValue_t(0x1000)); - } + static int + value_offset() { + return ((char*) &((PValue_t(0x1000))->second)) - ((char*) PValue_t(0x1000)); + } -}; + }; #ifndef __CINT__ -// Need specialization for boolean references due to stupid STL vector -template <> inline void* Reflex::Address >::const_reference ->::address(std::vector >::const_reference) { - return 0; -} + // Need specialization for boolean references due to stupid STL vector + template <> inline void* Reflex::Address >::const_reference + >::address(std::vector >::const_reference) { + return 0; + } #endif @@ -355,389 +545,470 @@ template <> inline void* Reflex::Address #include namespace Reflex { -/** @class CollFuncTable - * - * Table containing pointers to concrete functions to manipulate - * Collections in a generic way - * - * @author M.Frank - */ -struct RFLX_API CollFuncTable { - size_t iter_size; - size_t value_diff; - int value_offset; - void* (*size_func)(void*); - void (*resize_func)(void*,size_t); - void* (*clear_func)(void*); - void* (*first_func)(void*); - void* (*next_func)(void*); - void* (*construct_func)(void*,size_t); - void (*destruct_func)(void*,size_t); - void* (*feed_func)(void*,void*,size_t); - void* (*collect_func)(void*); - void* (*create_env)(); -}; - -template struct CFTGenerator { - static CollFuncTable* - Generate() { - typedef typename T::Value_t Value_t; - typedef std::pair Pair_t; - Pair_t* ptr = (Pair_t*) 0x1000; - CollFuncTable* p = new CollFuncTable(); - p->iter_size = sizeof(typename T::Iter_t); - p->value_diff = ((char*) &ptr->second) - ((char*) &ptr->first); - p->value_offset = T::value_offset(); - p->size_func = T::size; - p->first_func = T::first; - p->next_func = T::next; - p->clear_func = T::clear; - p->resize_func = T::resize; - p->collect_func = T::collect; - p->construct_func = T::construct; - p->destruct_func = T::destruct; - p->feed_func = T::feed; - p->create_env = T::Env_t::Create; - return p; - } // Generate - - -}; -struct CFTNullGenerator { - static void* - Void_func(void*) { - return 0; - } + /** @class CollFuncTable + * + * Table containing pointers to concrete functions to manipulate + * Collections in a generic way + * + * @author M.Frank + */ + struct RFLX_API CollFuncTable { + size_t iter_size; + size_t value_diff; + int value_offset; + void* (*size_func)(void*); + void (*resize_func)(void*,size_t); + void* (*clear_func)(void*); + void* (*first_func)(void*); + void* (*next_func)(void*); + void* (*construct_func)(void*,size_t); + void (*destruct_func)(void*,size_t); + void* (*feed_func)(void*,void*,size_t); + void* (*collect_func)(void*,void*); + void* (*create_env)(); + + // Set of function of direct iteration of the collections. + void (*fCreateIterators)(void *collection, void **begin_arena, void **end_arena, TVirtualCollectionProxy *proxy); + // begin_arena and end_arena should contain the location of memory arena of size fgIteratorSize. + // If the collection iterator are of that size or less, the iterators will be constructed in place in those location (new with placement) + // Otherwise the iterators will be allocated via a regular new and their address returned by modifying the value of begin_arena and end_arena. + + void* (*fCopyIterator)(void *dest, const void *source); + // Copy the iterator source, into dest. dest should contain should contain the location of memory arena of size fgIteratorSize. + // If the collection iterator are of that size or less, the iterator will be constructed in place in this location (new with placement) + // Otherwise the iterator will be allocated via a regular new and its address returned by modifying the value of dest. + + void* (*fNext)(void *iter, const void *end); + // iter and end should be pointer to respectively an iterator to be incremented and the result of colleciton.end() + // 'Next' will increment the iterator 'iter' and return 0 if the iterator reached the end. + // If the end is not reached, 'Next' will return the address of the content unless the collection contains pointers in + // which case 'Next' will return the value of the pointer. + + void (*fDeleteSingleIterator)(void *iter); + void (*fDeleteTwoIterators)(void *begin, void *end); + // If the sizeof iterator is greater than fgIteratorArenaSize, call delete on the addresses, + // Otherwise just call the iterator's destructor. + }; + + template struct CFTGenerator { + static CollFuncTable* + Generate() { + typedef typename T::Value_t Value_t; + typedef std::pair Pair_t; + Pair_t* ptr = (Pair_t*) 0x1000; + CollFuncTable* p = new CollFuncTable(); + p->iter_size = sizeof(typename T::Iter_t); + p->value_diff = ((char*) &ptr->second) - ((char*) &ptr->first); + p->value_offset = T::value_offset(); + p->size_func = T::size; + p->first_func = T::first; + p->next_func = T::next; + p->clear_func = T::clear; + p->resize_func = T::resize; + p->collect_func = T::collect; + p->construct_func = T::construct; + p->destruct_func = T::destruct; + p->feed_func = T::feed; + p->create_env = T::Env_t::Create; + + p->fCreateIterators = T::Iterators_t::create; + p->fCopyIterator = T::Iterators_t::copy; + p->fNext = T::Iterators_t::next; + p->fDeleteSingleIterator = T::Iterators_t::destruct1; + p->fDeleteTwoIterators = T::Iterators_t::destruct2; + return p; + } // Generate + + + }; + struct CFTNullGenerator { + static void* + Void_func(void*) { + return 0; + } - static void* - Void_func0() { return 0; } - - static void - Void_func2b(void*,size_t) { ; } - - static void* - Void_func2(void*,size_t) { return 0; } - - static void* - Void_func3(void*,void*,size_t) { return 0; } - - static CollFuncTable* - Generate() { - CollFuncTable* p = new CollFuncTable(); - p->iter_size = 4; - p->value_diff = 0; - p->value_offset = 0; - p->size_func = Void_func; - p->first_func = Void_func; - p->next_func = Void_func; - p->clear_func = Void_func; - p->resize_func = Void_func2b; - p->collect_func = Void_func; - p->construct_func = Void_func2; - p->destruct_func = Void_func2b; - p->feed_func = Void_func3; - p->create_env = Void_func0; - return p; - } // Generate - - -}; -// General proxy (dummy) -template struct Proxy {}; - -// Specialization for std::vector -template struct Proxy > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + static void* + Void_func0() { return 0; } + + static void + Void_func2b(void*,size_t) { ; } + + static void* + Void_func2c(void*,void*) { return 0; } + + static void* + Void_func2(void*,size_t) { return 0; } + + static void* + Void_func3(void*,void*,size_t) { return 0; } + + static CollFuncTable* + Generate() { + CollFuncTable* p = new CollFuncTable(); + p->iter_size = 4; + p->value_diff = 0; + p->value_offset = 0; + p->size_func = Void_func; + p->first_func = Void_func; + p->next_func = Void_func; + p->clear_func = Void_func; + p->resize_func = Void_func2b; + p->collect_func = Void_func2c; + p->construct_func = Void_func2; + p->destruct_func = Void_func2b; + p->feed_func = Void_func3; + p->create_env = Void_func0; + + p->fCreateIterators = 0; + p->fCopyIterator = 0; + p->fNext = 0; + p->fDeleteSingleIterator = 0; + p->fDeleteTwoIterators = 0; + + return p; + } // Generate + + + }; + // General proxy (dummy) + template struct Proxy {}; + + // Specialization for std::vector + template struct Proxy > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for std::list -template struct Proxy > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + }; + // Specialization for std::list + template struct Proxy > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for std::deque -template struct Proxy > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + }; + // Specialization for std::deque + template struct Proxy > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for std::set -template struct Proxy > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + }; + // Specialization for std::set + template struct Proxy > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for std::multiset -template struct Proxy > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + }; + // Specialization for std::multiset + template struct Proxy > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for std::map -template struct Proxy > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + }; + // Specialization for std::map + template struct Proxy > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for std::multimap -template struct Proxy > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + }; + // Specialization for std::multimap + template struct Proxy > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for std::queue -- not implemented -template struct Proxy > { - static CollFuncTable* - Generate() { return CFTNullGenerator::Generate(); } + }; + // Specialization for std::queue -- not implemented + template struct Proxy > { + static CollFuncTable* + Generate() { return CFTNullGenerator::Generate(); } -}; -// Specialization for std::stack -- not implemented -template struct Proxy > { - static CollFuncTable* - Generate() { return CFTNullGenerator::Generate(); } + }; + // Specialization for std::stack -- not implemented + template struct Proxy > { + static CollFuncTable* + Generate() { return CFTNullGenerator::Generate(); } -}; + }; #if defined(__GNUC__) -// Specialization for __gnu_cxx::hash_set -template struct Proxy<__gnu_cxx::hash_set > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + // Specialization for __gnu_cxx::hash_set + template struct Proxy<__gnu_cxx::hash_set > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for __gnu_cxx::hash_multiset -template struct Proxy<__gnu_cxx::hash_multiset > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + }; + // Specialization for __gnu_cxx::hash_multiset + template struct Proxy<__gnu_cxx::hash_multiset > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for __gnu_cxx::hash_map -template struct Proxy<__gnu_cxx::hash_map > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + }; + // Specialization for __gnu_cxx::hash_map + template struct Proxy<__gnu_cxx::hash_map > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for __gnu_cxx::hash_multimap -template struct Proxy<__gnu_cxx::hash_multimap > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + }; + // Specialization for __gnu_cxx::hash_multimap + template struct Proxy<__gnu_cxx::hash_multimap > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; + }; #elif defined(_WIN32) -// Specialization for stdext::hash_multiset -template struct Proxy > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + // Specialization for stdext::hash_multiset + template struct Proxy > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for stdext::hash_set -template struct Proxy > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + }; + // Specialization for stdext::hash_set + template struct Proxy > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for stdext::hash_map -template struct Proxy > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + }; + // Specialization for stdext::hash_map + template struct Proxy > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; -// Specialization for stdext::hash_multimap -template struct Proxy > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + }; + // Specialization for stdext::hash_multimap + template struct Proxy > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; + }; #endif -// Specialization for std::bitset -template struct StdBitSetHelper {}; + // Specialization for std::bitset + template struct StdBitSetHelper {}; #ifndef __CINT__ -template struct CollType > : public Address { - typedef Bitset_t Cont_t; - typedef std::pair Iter_t; - typedef bool Value_t; - typedef Environ Env_t; - typedef Env_t* PEnv_t; - typedef Cont_t* PCont_t; - typedef Value_t* PValue_t; - - virtual ~CollType() {} - - static inline PCont_t - object(void* ptr) { - return PCont_t(PEnv_t(ptr)->fObject); - } - - - static void* - size(void* env) { - PEnv_t e = PEnv_t(env); - e->fSize = PCont_t(e->fObject)->size(); - return &e->fSize; - } - - - static void* - clear(void* env) { - object(env)->reset(); - return 0; - } - + template struct CollType > : public Address { + typedef Bitset_t Cont_t; + typedef std::pair Iter_t; + typedef bool Value_t; + typedef Environ Env_t; + typedef Env_t* PEnv_t; + typedef Cont_t* PCont_t; + typedef Value_t* PValue_t; + + virtual ~CollType() {} + + static inline PCont_t + object(void* ptr) { + return PCont_t(PEnv_t(ptr)->fObject); + } - static void* - first(void* env) { - PEnv_t e = PEnv_t(env); - PCont_t c = PCont_t(e->fObject); - e->fIterator.first = 0; - e->fIterator.second = c->size() > 0 ? c->test(e->fIterator.first) : false; // Iterator actually hold the value. - e->fSize = c->size(); - return 0; - } + static void* + size(void* env) { + PEnv_t e = PEnv_t(env); + e->fSize = PCont_t(e->fObject)->size(); + return &e->fSize; + } - static void* - next(void* env) { - PEnv_t e = PEnv_t(env); - PCont_t c = PCont_t(e->fObject); - for ( ; e->fIdx > 0 && e->fIterator.first != c->size(); ++(e->fIterator.first), --e->fIdx) {} - e->fIterator.second = (e->fIterator.first != c->size()) ? c->test(e->fIterator.first) : false; - return 0; - } + static void* + clear(void* env) { + object(env)->reset(); + return 0; + } - static void* - construct(void*,size_t) { - // Nothing to construct. - return 0; - } + static void* + first(void* env) { + PEnv_t e = PEnv_t(env); + PCont_t c = PCont_t(e->fObject); + e->fIterator.first = 0; + e->fIterator.second = c->size() > 0 ? c->test(e->fIterator.first) : false; // Iterator actually hold the value. + e->fSize = c->size(); + return 0; + } - static void* - collect(void* env) { - PEnv_t e = PEnv_t(env); - PCont_t c = PCont_t(e->fObject); - PValue_t m = PValue_t(e->fStart); // 'start' is a buffer outside the container. + static void* + next(void* env) { + PEnv_t e = PEnv_t(env); + PCont_t c = PCont_t(e->fObject); - for (size_t i = 0; i != c->size(); ++i, ++m) { - *m = c->test(i); + for ( ; e->fIdx > 0 && e->fIterator.first != c->size(); ++(e->fIterator.first), --e->fIdx) {} + e->fIterator.second = (e->fIterator.first != c->size()) ? c->test(e->fIterator.first) : false; + return 0; } - return 0; - } - static void - destruct(void*,size_t) { - // Nothing to destruct. - } - + static void* + construct(void*,size_t) { + // Nothing to construct. + return 0; + } -}; -template -struct Pushback > : public CollType > { - typedef Bitset_t Cont_t; - typedef bool Iter_t; - typedef bool Value_t; - typedef Environ Env_t; - typedef Env_t* PEnv_t; - typedef Cont_t* PCont_t; - typedef Value_t* PValue_t; + static void* + collect(void* coll, void *array) { + PCont_t c = PCont_t(coll); + PValue_t m = PValue_t(array); // 'start' is a buffer outside the container. - static void resize(void* /*obj*/, size_t) { } + for (size_t i = 0; i != c->size(); ++i, ++m) { + *m = c->test(i); + } + return 0; + } - static void* - feed(void* env) { - PEnv_t e = PEnv_t(env); - PCont_t c = PCont_t(e->fObject); - PValue_t m = PValue_t(e->fStart); // Here start is actually a 'buffer' outside the container. + static void + destruct(void*,size_t) { + // Nothing to destruct. + } - for (size_t i = 0; i < e->fSize; ++i, ++m) { - c->set(i, *m); + struct Iterators { + typedef Cont_t *PCont_t; + union PtrSize_t { size_t fIndex; void *fAddress; }; + typedef std::pair iterator; + // In the end iterator we store the bitset pointer + // and do not use the 'second' part of the pair. + // In the other iterator we store the index + // and the value. + + static void create(void *coll, void **begin_arena, void **end_arena, TVirtualCollectionProxy *) { + iterator *begin = new (*begin_arena) iterator; + begin->first.fIndex = 0; + begin->second = false; + iterator *end = new (*end_arena) iterator; + end->first.fAddress = coll; + end->second = false; + } + static void* copy(void *dest_arena, const void *source_ptr) { + const iterator *source = (const iterator *)(source_ptr); + new (dest_arena) iterator(*source); + return dest_arena; + } + static void* next(void *iter_loc, const void *end_loc) { + const iterator *end = (const iterator *)(end_loc); + PCont_t c = (PCont_t)end->first.fAddress; + iterator *iter = (iterator *)(iter_loc); + if (iter->first.fIndex != c->size()) { + iter->second = c->test(iter->first.fIndex); + ++(iter->first.fIndex); + } + return &(iter->second); + } + static void destruct1(void *iter_ptr) { + iterator *start = (iterator *)(iter_ptr); + start->~iterator(); + } + static void destruct2(void *begin_ptr, void *end_ptr) { + iterator *start = (iterator *)(begin_ptr); + iterator *end = (iterator *)(end_ptr); + start->~iterator(); + end->~iterator(); + } + }; + typedef Iterators Iterators_t; + + }; + + template + struct Pushback > : public CollType > { + typedef Bitset_t Cont_t; + typedef bool Iter_t; + typedef bool Value_t; + typedef Environ Env_t; + typedef Env_t* PEnv_t; + typedef Cont_t* PCont_t; + typedef Value_t* PValue_t; + + static void resize(void* /*obj*/, size_t) { } + + + static void* + feed(void* env) { + PEnv_t e = PEnv_t(env); + PCont_t c = PCont_t(e->fObject); + PValue_t m = PValue_t(e->fStart); // Here start is actually a 'buffer' outside the container. + + for (size_t i = 0; i < e->fSize; ++i, ++m) { + c->set(i, *m); + } + return 0; } - return 0; - } - static void* - feed(void* from, void* to, size_t size) { - PValue_t m = PValue_t(from); - PCont_t c = PCont_t(to); + static void* + feed(void* from, void* to, size_t size) { + PValue_t m = PValue_t(from); + PCont_t c = PCont_t(to); - for (size_t i = 0; i < size; ++i, ++m) { - c->set(i, *m); + for (size_t i = 0; i < size; ++i, ++m) { + c->set(i, *m); + } + return 0; } - return 0; - } - static int - value_offset() { - return 0; - } + static int + value_offset() { + return 0; + } -}; + }; #endif -template struct Proxy > { - static CollFuncTable* - Generate() { - return CFTGenerator > >::Generate(); - } + template struct Proxy > { + static CollFuncTable* + Generate() { + return CFTGenerator > >::Generate(); + } -}; + }; } #endif // Reflex_CollectionProxy diff --git a/cint/reflex/inc/Reflex/Tools.h b/cint/reflex/inc/Reflex/Tools.h index 31976f91657c8..49a3af2fd4228 100644 --- a/cint/reflex/inc/Reflex/Tools.h +++ b/cint/reflex/inc/Reflex/Tools.h @@ -64,8 +64,8 @@ RFLX_API std::string Demangle(const std::type_info& ti); /** - * StringSplit will return a vector of splitted strings - * @param splitValues returns the vector with splitted strings + * StringSplit will return a vector of split strings + * @param splitValues returns the vector with split strings * @param str the input string * @param delim the delimiter on which to split */ diff --git a/cint/reflex/python/CMakeLists.txt b/cint/reflex/python/CMakeLists.txt index b1faf57ac42e9..97cd2062e6e86 100644 --- a/cint/reflex/python/CMakeLists.txt +++ b/cint/reflex/python/CMakeLists.txt @@ -67,10 +67,10 @@ ENDIF (WIN32) ##################### install #################### INSTALL(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/genreflex - DESTINATION ${LIB_INSTALL_DIR}/python + DESTINATION ${CMAKE_INSTALL_LIBDIR}/python FILES_MATCHING PATTERN "*.py" PATTERN "gccxmlpath.py" EXCLUDE) INSTALL(PROGRAMS ${_genreflex_filename} - DESTINATION ${BIN_INSTALL_DIR}) + DESTINATION ${CMAKE_INSTALL_BINDIR}) diff --git a/cint/reflex/python/genreflex/gendict.py b/cint/reflex/python/genreflex/gendict.py index 7c0b02cad7d20..f64ce1f15b8b6 100644 --- a/cint/reflex/python/genreflex/gendict.py +++ b/cint/reflex/python/genreflex/gendict.py @@ -319,7 +319,7 @@ def resolveTypedefName( self, name ) : f = name.find(tdname) if f != -1 : g = f + len(tdname) - if (f == 0 or name[f-1] in notname) and (g == len(tdname) or name[g] in notname) : + if (f == 0 or name[f-1] in notname) and (g == len(name) or name[g] in notname) : defname = self.genTypeName(td['type']) if defname[len(defname)-1] == '>' : defname += ' ' name = self.resolveTypedefName(name.replace(tdname, defname, 1)) @@ -957,7 +957,14 @@ def processIOAutoVariables( self, className, mappedName, source, target, memType #--------------------------------------------------------------------------- for member in source: if member[0] == '': continue - sc += ' ' + member[0] + ' &' + member[1] + ';\n' + if member[0][-1] == ']': + t = memTypes[0] + arraydim = t[t.find('['):] + arraytype = t[:t.find('[')] + sc += ' typedef %s onfile_%s_t%s;\n' % (arraytype,member[1],arraydim) + sc += ' onfile_%s_t &%s\n' % (member[1],member[1]) + else: + sc += ' ' + member[0] + ' &' + member[1] + ';\n' #--------------------------------------------------------------------------- # Generate the constructor @@ -1016,7 +1023,15 @@ def processIOAutoVariables( self, className, mappedName, source, target, memType # Write the target members #----------------------------------------------------------------------------- for member in target: - sc += ' %s &%s = *(%s*)(target + OffsetOf(__shadow__::%s, %s));\n' % (memTypes[member], member, memTypes[member], mappedName, member) + if member == "": continue + if memTypes[member][-1] == ']': + t = memTypes[member] + arraydim = t[t.find('['):] + arraytype = t[:t.find('[')] + sc += ' typedef %s %s_t%s;\n' % (arraytype,member,arraydim) + sc += ' %s_t &%s = *(%s_t*)(target + OffsetOf(__shadow__::%s, %s));\n' % (member, member, member, mappedName, member) + else: + sc += ' %s &%s = *(%s*)(target + OffsetOf(__shadow__::%s, %s));\n' % (memTypes[member], member, memTypes[member], mappedName, member) return sc + '\n' #--------------------------------------------------------------------------------- def processIoReadFunctions( self, cl, clt, rules, memTypes ): @@ -1029,7 +1044,9 @@ def processIoReadFunctions( self, cl, clt, rules, memTypes ): #-------------------------------------------------------------------------- # Process the data members #-------------------------------------------------------------------------- - sourceMembers = [member.strip() for member in rule['attrs']['source'].split(';')] + sourceMembers = [] + if rule['attrs'].has_key('source'): + sourceMembers = [member.strip() for member in rule['attrs']['source'].split(';')] sourceMembersSpl = [] for member in sourceMembers: type = '' @@ -1043,7 +1060,9 @@ def processIoReadFunctions( self, cl, clt, rules, memTypes ): elem = spl[len(spl)-1] sourceMembersSpl.append( (type, elem) ) - targetMembers = [member.strip() for member in rule['attrs']['target'].split(';')] + targetMembers = [] + if rule['attrs'].has_key('target'): + targetMembers = [member.strip() for member in rule['attrs']['target'].split(';')] #-------------------------------------------------------------------------- # Print things out @@ -1051,6 +1070,8 @@ def processIoReadFunctions( self, cl, clt, rules, memTypes ): sc += 'void %s( char *target, TVirtualObject *oldObj )\n' % (funcname,) sc += '{\n' sc += self.processIOAutoVariables( cl, clt, sourceMembersSpl, targetMembers, memTypes ) + # Avoid compiler warnings in case the old variables are not used: + sc += ' if( oldObj ) {}\n' #to avoid compiler warnings about unused variables only declare newObj if user actually uses it if -1 != rule['code'].find('newObj'): sc += ' %s* newObj = (%s*)target;\n' % (cl, cl) @@ -1093,6 +1114,7 @@ def createTypeMap( self, memIds ): def removeBrokenIoRules( self, cl, rules, members ): for rule in rules: if rule['attrs'].has_key( 'target' ): + if rule['attrs']['target'] == "": continue targets = [target.strip() for target in rule['attrs']['target'].split(';')] ok = True for t in targets: @@ -1464,7 +1486,7 @@ def genClassShadow(self, attrs, inner = 0 ) : c += indent + '};\n' return c #---------------------------------------------------------------------------------- - def genTypedefBuild(self, attrs, childs) : + def genTypedefBuild(self, attrs, children) : if self.no_membertypedefs : return '' # access selection doesn't work with gccxml0.6 - typedefs don't have it if self.interpreter and 'access' in attrs : return '' @@ -1472,11 +1494,11 @@ def genTypedefBuild(self, attrs, childs) : s += ' .AddTypedef(%s, Reflex::Literal("%s::%s"))' % ( self.genTypeID(attrs['type']), self.genTypeName(attrs['context']), attrs['name']) return s #---------------------------------------------------------------------------------- - def genEnumerationBuild(self, attrs, childs): + def genEnumerationBuild(self, attrs, children): s = '' name = self.genTypeName(attrs['id']) values = '' - for child in childs : values += child['name'] + '=' + child['init'] +';' + for child in children : values += child['name'] + '=' + child['init'] +';' values = values[:-1] mod = self.genModifier(attrs, None) if self.isUnnamedType(name) : @@ -1818,7 +1840,7 @@ def countColonsForOffset(self, name) : else : pass return cnt #---------------------------------------------------------------------------------- - def genFieldBuild(self, attrs, childs): + def genFieldBuild(self, attrs, children): type = self.genTypeName(attrs['type'], enum=False, const=False) cl = self.genTypeName(attrs['context'],colon=True) cls = self.genTypeName(attrs['context']) @@ -1860,7 +1882,7 @@ def genFieldBuild(self, attrs, childs): c += '\n .AddProperty(Reflex::Literal("%s"),Reflex::Literal("%s"))' % (pname, pval) return c #---------------------------------------------------------------------------------- - def genVariableBuild(self, attrs, childs): + def genVariableBuild(self, attrs, children): if 'access' in attrs and attrs['access'] in ('private','protected') : return '' type = self.genTypeName(attrs['type'], enum=False, const=False) cl = self.genTypeName(attrs['context'],colon=True) @@ -2150,7 +2172,7 @@ def genConstructorDef(self, attrs, args): body += '}\n' return head + body #---------------------------------------------------------------------------------- - def genDestructorDef(self, attrs, childs): + def genDestructorDef(self, attrs, children): cl = self.genTypeName(attrs['context']) static = '' dtorscope = '' @@ -2164,7 +2186,7 @@ def genDestructorDef(self, attrs, childs): # unnamed; can't call. return dtorimpl + ' // unnamed, cannot call destructor\n}' #---------------------------------------------------------------------------------- - def genDestructorBuild(self, attrs, childs): + def genDestructorBuild(self, attrs, children): if self.isUnnamedType(self.xref[attrs['context']]['attrs'].get('demangled')) or \ self.checkAccessibleType(self.xref[attrs['context']]) : return '' mod = self.genModifier(attrs,None) @@ -2326,12 +2348,16 @@ def checkOperators(self,cid): if opname == 'new []': if len(sems) == 1 and self.genTypeName(sems[0]['type']) in ('size_t',): opnewa = 1 if len(sems) == 2 and self.genTypeName(sems[0]['type']) in ('size_t',) and self.genTypeName(sems[1]['type']) in ('void*',): plopnewa = 1 - newc = '' - newa = '' + newc,newa = '','' if opnewc and not plopnewc: newc = '_np' elif not opnewc and plopnewc : newc = '_p' if opnewa and not plopnewa: newa = '_np' elif not opnewa and plopnewa : newa = '_p' + # go to base classes eventually + if (newc,newa) == ('','') : + for b in self.getBases(cid): + newc,newa = self.checkOperators(b['type']) + if (newc,newa) != ('','') : break return (newc, newa) #----Constructor/Destructor stuff-------------------------------------------------------- def genGetNewDelFunctionsDecl( self, attrs, args ) : diff --git a/cint/reflex/python/genreflex/genheader.py b/cint/reflex/python/genreflex/genheader.py index 47ea2ff4e82b9..f52af614a7a3a 100644 --- a/cint/reflex/python/genreflex/genheader.py +++ b/cint/reflex/python/genreflex/genheader.py @@ -25,68 +25,68 @@ def genName(id) : return genName(attrs[u'type'])+'&' elif elem == 'FunctionType' : s = genName(attrs[u'returns']) + '(*)(' - childs = xref[id][2] - for a in childs : + children = xref[id][2] + for a in children : s += genArgument(a) - if a != childs[-1] : s += ', ' + if a != children[-1] : s += ', ' s += ')' return s elif elem == 'ArrayType' : return genName(attrs[u'type'])+'['+attrs[u'max']+']' else : return attrs[u'name'] -def genField(attrs, childs): +def genField(attrs, children): return '%s %s;' % (genName(attrs[u'type']), attrs[u'name'] ) -def genVariable(attrs, childs): +def genVariable(attrs, children): return 'static %s %s;' % (genName(attrs[u'type']), attrs[u'name'] ) def genArgument(attrs): if u'name' in attrs : return '%s %s' % (genName(attrs[u'type']), attrs[u'name'] ) else : return '%s ' % (genName(attrs[u'type'])) -def genMethod(attrs, childs): +def genMethod(attrs, children): s = '' if u'virtual' in attrs : s += 'virtual ' if u'static' in attrs : s += 'static ' s += '%s %s(' % (genName(attrs[u'returns']), attrs[u'name']) - for a in childs : + for a in children : s += genArgument(a) - if a != childs[-1] : s += ', ' + if a != children[-1] : s += ', ' s += ')' if u'const' in attrs : s += ' const' if u'pure_virtual' in attrs : s += ' = 0' s += ';' return s -def genConstructor(attrs, childs): +def genConstructor(attrs, children): s = '%s(' % (attrs[u'name']) - for a in childs : + for a in children : s += genArgument(a) - if a != childs[-1] : s += ', ' + if a != children[-1] : s += ', ' s += ');' return s -def genOperatorMethod(attrs, childs): +def genOperatorMethod(attrs, children): s = '%s operator %s(' % ( genName(attrs[u'returns']), attrs[u'name']) - for a in childs : + for a in children : s += genArgument(a) - if a != childs[-1] : s += ', ' + if a != children[-1] : s += ', ' s += ')' if u'const' in attrs : s += ' const' s += ';' return s -def genDestructor(attrs, childs): +def genDestructor(attrs, children): return '~%s();' % (attrs[u'name']) -def genConverter(attrs, childs): +def genConverter(attrs, children): return 'operator %s();' % (attrs[u'returns']) def genEnumValue(attrs): return '%s = %s' % (attrs[u'name'], attrs[u'init']) -def genEnumeration(attrs, childs): +def genEnumeration(attrs, children): s = 'enum %s { ' % (attrs[u'name']) - for a in childs : + for a in children : s += genEnumValue(a) - if a != childs[-1] : s += ', ' + if a != children[-1] : s += ', ' s += '};' return s -def genClass(attrs, childs ): +def genClass(attrs, children ): s = 'class %s ' % (attrs[u'name']) if u'bases' in attrs : bases = string.split(attrs[u'bases']) @@ -109,7 +109,7 @@ def genClass(attrs, childs ): print 'Function '+funcname+' not found' s += '};' return s -def genTypedef(attrs, childs): +def genTypedef(attrs, children): return 'typedef %s %s;' % ( genName(attrs[u'type']), attrs[u'name'] ) def start_element(name, attrs): diff --git a/cint/reflex/python/genreflex/genreflex.py b/cint/reflex/python/genreflex/genreflex.py index 634f4de5f5985..3634c420b72b6 100644 --- a/cint/reflex/python/genreflex/genreflex.py +++ b/cint/reflex/python/genreflex/genreflex.py @@ -7,6 +7,7 @@ # This software is provided "as is" without express or implied warranty. import sys, os, gendict, selclass, gencapa, genrootmap, string, getopt, subprocess +import re class genreflex: #---------------------------------------------------------------------------------- @@ -124,10 +125,11 @@ def parse_args(self, argv = sys.argv) : break #----Process options-------------------------------- try: - opts, args = getopt.getopt(options, 'ho:s:c:I:U:D:PC', \ + opts, args = getopt.getopt(options, 'ho:s:c:I:U:D:PCl:m:', \ ['help','debug=', 'output=','selection_file=','pool','dataonly','interpreteronly','deep','gccxmlpath=', 'capabilities=','rootmap=','rootmap-lib=','comments','iocomments','no_membertypedefs', - 'fail_on_warnings', 'quiet', 'gccxmlopt=', 'reflex', 'split=','no_templatetypedefs','gccxmlpost=']) + 'fail_on_warnings', 'quiet', 'gccxmlopt=', 'reflex', 'split=','no_templatetypedefs','gccxmlpost=', + 'library=']) except getopt.GetoptError, e: print "--->> genreflex: ERROR:",e self.usage(2) @@ -255,7 +257,7 @@ def check_files_dirs(self): #---------------------------------------------------------------------------------- def genGccxmlInfo(self): s = '' - p = subprocess.Popen('"' + self.gccxml + '" --print', shell=True, + p = subprocess.Popen('"' + self.gccxml + '" ' + self.gccxmlopt + ' --print', shell=True, bufsize=-1, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE, @@ -286,7 +288,7 @@ def genGccxmlInfo(self): bcomp = os.path.basename(compiler) vopt = '' if bcomp in ('msvc7','msvc71','msvc8') : return s - elif bcomp in ('gcc','g++','c++') : vopt = '--version' + elif bcomp in ('gcc','g++','c++') or re.match(r'lcg-g\+\+', bcomp): vopt = '--version' elif bcomp in ('cl.exe','cl') : vopt = '' # there is no option to print only the version with cl else : print '--->> genreflex: WARNING: While trying to retrieve compiler version, found unknown compiler %s' % compiler diff --git a/cint/reflex/python/genreflex/selclass.py b/cint/reflex/python/genreflex/selclass.py index c5a411484b569..a562b76363205 100644 --- a/cint/reflex/python/genreflex/selclass.py +++ b/cint/reflex/python/genreflex/selclass.py @@ -233,10 +233,11 @@ def isRuleValid(self, rule): #------------------------------------------------------------------------------ # Check if we have other parameters specified correctly #------------------------------------------------------------------------------ - for k in ['target', 'source' ]: - if not attrs.has_key(k): - print warning, '- Required attribute is missing:', k - return False + # source and target are optional paramater. + # for k in ['target', 'source' ]: + # if not attrs.has_key(k): + # print warning, '- Required attribute is missing:', k + # return False if attrs.has_key( 'embed' ): if attrs['embed'] != 'true' and attrs['embed'] != 'false': diff --git a/cint/reflex/src/Class.cxx b/cint/reflex/src/Class.cxx index fc682215079d0..4155c0b759861 100644 --- a/cint/reflex/src/Class.cxx +++ b/cint/reflex/src/Class.cxx @@ -36,6 +36,9 @@ #if defined(__APPLE__) && defined(MAC_OS_X_VERSION_10_7) namespace __cxxabiv1 { +#ifdef _LIBCPP_ABI_VERSION +class __class_type_info; +#endif extern "C" void* __dynamic_cast(const void* __src_ptr, // Starting object. const __class_type_info* __src_type, // Static type of object. diff --git a/cint/reflex/src/stl_hash.h b/cint/reflex/src/stl_hash.h index 4d459ca980c95..783f0b755eab0 100644 --- a/cint/reflex/src/stl_hash.h +++ b/cint/reflex/src/stl_hash.h @@ -12,7 +12,13 @@ #ifndef __GNU_CXX_HASH_H #define __GNU_CXX_HASH_H -#if defined(__GNUC__) +#if defined(_LIBCPP_ABI_VERSION) +// using libc++ +# include +# define hash_map unordered_map +# define hash_multimap unordered_multimap +# define __gnu_cxx std +#elif defined(__GNUC__) # if defined(__INTEL_COMPILER) && (__INTEL_COMPILER <= 800) # define __gnu_cxx std # endif @@ -124,10 +130,10 @@ template <> class hash_compare { */ } // namespace __gnu_cxx -#endif // __ICC, __ECC, _WIN32 +#endif // _WIN32 -#if defined(__GNUC__) +#if defined(__GNUC__) && !defined(_LIBCPP_ABI_VERSION) namespace __gnu_cxx { template <> struct hash { size_t @@ -140,7 +146,6 @@ template <> struct hash { } }; - template <> struct hash { size_t operator ()(const std::string* __s) const { @@ -150,8 +155,6 @@ template <> struct hash { return __stl_hash_string(__s->c_str()); # endif } - - }; } @@ -163,8 +166,6 @@ template <> struct equal_to : const char* const& _Right) const { return strcmp(_Left, _Right) == 0; } - - }; template <> struct equal_to : @@ -174,8 +175,6 @@ template <> struct equal_to : const char** const& _Right) const { return strcmp(*_Left, *_Right) == 0; } - - }; template <> struct equal_to : @@ -185,13 +184,59 @@ template <> struct equal_to : const std::string* const& _Right) const { return * _Left == * _Right; } +}; + +} // namespace std + +#endif // __GNUC__ + + +#if defined(_LIBCPP_ABI_VERSION) +#include +namespace std { + +template <> struct hash { + size_t + operator ()(const char** const& __s) const { + return __do_string_hash(*__s, *__s + strlen(*__s)); + } +}; + +template <> struct hash { + size_t + operator ()(const std::string* const& __s) const { + return __do_string_hash(__s->c_str(), __s->c_str() + strlen(__s->c_str())); + } +}; +template <> struct equal_to { + bool + operator ()(const char* const& _Left, + const char* const& _Right) const { + return strcmp(_Left, _Right) == 0; + } +}; +template <> struct equal_to { + bool + operator ()(const char** const& _Left, + const char** const& _Right) const { + return strcmp(*_Left, *_Right) == 0; + } +}; + +template <> struct equal_to { + bool + operator ()(const std::string* const& _Left, + const std::string* const& _Right) const { + return * _Left == * _Right; + } }; } // namespace std -#endif // __GNUC__ +#endif // _LIBCPP_ABI_VERSION + #if defined(__INTEL_COMPILER) && (__INTEL_COMPILER <= 800) diff --git a/cint/test/Complex.cxx b/cint/test/Complex.cxx index 42c14f635ac16..36f8ada087504 100644 --- a/cint/test/Complex.cxx +++ b/cint/test/Complex.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/Complex.h b/cint/test/Complex.h index cf2e605e66096..96703f261be29 100644 --- a/cint/test/Complex.h +++ b/cint/test/Complex.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/IPair.cpp b/cint/test/IPair.cpp index 50228ff2985d9..62ea310837efd 100644 --- a/cint/test/IPair.cpp +++ b/cint/test/IPair.cpp @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/IPair.h b/cint/test/IPair.h index 13cee94cc73c5..8bb740cc4cefe 100644 --- a/cint/test/IPair.h +++ b/cint/test/IPair.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/MyAlgo0.h b/cint/test/MyAlgo0.h index eaaa2cafaa76a..ad2e097826303 100644 --- a/cint/test/MyAlgo0.h +++ b/cint/test/MyAlgo0.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/MyString.cxx b/cint/test/MyString.cxx index f12d42d9df263..f7c5dab44821e 100644 --- a/cint/test/MyString.cxx +++ b/cint/test/MyString.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/MyString.h b/cint/test/MyString.h index d1061123da147..8d07edcad38be 100644 --- a/cint/test/MyString.h +++ b/cint/test/MyString.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/Test0.cxx b/cint/test/Test0.cxx index 9cac3755a2bfc..e44050e4c5a48 100644 --- a/cint/test/Test0.cxx +++ b/cint/test/Test0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/Test1.cxx b/cint/test/Test1.cxx index d307ed042fa63..1ab1126ebc907 100644 --- a/cint/test/Test1.cxx +++ b/cint/test/Test1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/VArray.cxx b/cint/test/VArray.cxx index 805167b52f2a9..b5a497d49b3b2 100644 --- a/cint/test/VArray.cxx +++ b/cint/test/VArray.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/VArray.h b/cint/test/VArray.h index db0ba741beb9a..d6544719c938b 100644 --- a/cint/test/VArray.h +++ b/cint/test/VArray.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/VCompany.cxx b/cint/test/VCompany.cxx index 1b18bae274f8c..0be28645cf5b1 100644 --- a/cint/test/VCompany.cxx +++ b/cint/test/VCompany.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/VCompany.h b/cint/test/VCompany.h index 61a023feec467..d8b6fbfb593d6 100644 --- a/cint/test/VCompany.h +++ b/cint/test/VCompany.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/VObject.cxx b/cint/test/VObject.cxx index c9c4971a27746..20c4a0eae88ef 100644 --- a/cint/test/VObject.cxx +++ b/cint/test/VObject.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/VObject.h b/cint/test/VObject.h index f95dd2acd505d..6d9369d487e49 100644 --- a/cint/test/VObject.h +++ b/cint/test/VObject.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/VPerson.cxx b/cint/test/VPerson.cxx index 3ba7049ee7d12..581e8bb7765df 100644 --- a/cint/test/VPerson.cxx +++ b/cint/test/VPerson.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/VPerson.h b/cint/test/VPerson.h index 5779a7501cb1e..f04c46b916d81 100644 --- a/cint/test/VPerson.h +++ b/cint/test/VPerson.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/VPersonTest.cxx b/cint/test/VPersonTest.cxx index 2abf597f22c4e..40291aa262398 100644 --- a/cint/test/VPersonTest.cxx +++ b/cint/test/VPersonTest.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/VString.cxx b/cint/test/VString.cxx index b9cf3cf835f20..96c244040c103 100644 --- a/cint/test/VString.cxx +++ b/cint/test/VString.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/VString.h b/cint/test/VString.h index b1aa55d3dfd0c..39b8f91260992 100644 --- a/cint/test/VString.h +++ b/cint/test/VString.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/VType.h b/cint/test/VType.h index a55072445a7b3..3a0675acf7a53 100644 --- a/cint/test/VType.h +++ b/cint/test/VType.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/access0.cxx b/cint/test/access0.cxx index 2521ea625d90a..b833367b471ad 100644 --- a/cint/test/access0.cxx +++ b/cint/test/access0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/anonunion.cxx b/cint/test/anonunion.cxx index 4e764617ac34e..67e932562117b 100644 --- a/cint/test/anonunion.cxx +++ b/cint/test/anonunion.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/aoki0.cxx b/cint/test/aoki0.cxx index 5c742c78a199b..81e3081a9df2b 100644 --- a/cint/test/aoki0.cxx +++ b/cint/test/aoki0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/aryinit0.cxx b/cint/test/aryinit0.cxx index c1afd7a4bd8df..220d33cac429f 100644 --- a/cint/test/aryinit0.cxx +++ b/cint/test/aryinit0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/aryinit1.cxx b/cint/test/aryinit1.cxx index 7c2900249983d..c113860aba2a1 100644 --- a/cint/test/aryinit1.cxx +++ b/cint/test/aryinit1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/autocc.cxx b/cint/test/autocc.cxx index 68c613044ab38..3e33c2a161961 100644 --- a/cint/test/autocc.cxx +++ b/cint/test/autocc.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/baseconv0.cxx b/cint/test/baseconv0.cxx index 9d757bbd5afdb..ba08ca9aafca1 100644 --- a/cint/test/baseconv0.cxx +++ b/cint/test/baseconv0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/bitfield.cxx b/cint/test/bitfield.cxx index e9d807474f01a..244f0c9b30cde 100644 --- a/cint/test/bitfield.cxx +++ b/cint/test/bitfield.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/borg1.cxx b/cint/test/borg1.cxx index d1c54b72e58db..7a01e9378fcd4 100644 --- a/cint/test/borg1.cxx +++ b/cint/test/borg1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/borg2.cxx b/cint/test/borg2.cxx index 3c189780aaa02..6f9827d19ef18 100644 --- a/cint/test/borg2.cxx +++ b/cint/test/borg2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/bruce1.cxx b/cint/test/bruce1.cxx index 13b422c998ea8..61cede39ae9ea 100644 --- a/cint/test/bruce1.cxx +++ b/cint/test/bruce1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/btmplt.cxx b/cint/test/btmplt.cxx index 61ee383106934..f242b716b9e50 100644 --- a/cint/test/btmplt.cxx +++ b/cint/test/btmplt.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/complex1.cxx b/cint/test/complex1.cxx index 084d564c8ea3f..36ce510ee21b4 100644 --- a/cint/test/complex1.cxx +++ b/cint/test/complex1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/complex1.h b/cint/test/complex1.h index bbb44b23427e7..74113bf6a406d 100644 --- a/cint/test/complex1.h +++ b/cint/test/complex1.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/const.cxx b/cint/test/const.cxx index fccc6e2d64ac6..d601dfc4579a6 100644 --- a/cint/test/const.cxx +++ b/cint/test/const.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/constary.cxx b/cint/test/constary.cxx index 719ecd35a4fd5..1497750f86e8f 100644 --- a/cint/test/constary.cxx +++ b/cint/test/constary.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/convopr0.cxx b/cint/test/convopr0.cxx index 7f52d010ac6f6..357ba6c0e8840 100644 --- a/cint/test/convopr0.cxx +++ b/cint/test/convopr0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/cout1.cxx b/cint/test/cout1.cxx index 7d091c8b0f69f..7284fc394272a 100644 --- a/cint/test/cout1.cxx +++ b/cint/test/cout1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/cpp0.cxx b/cint/test/cpp0.cxx index e1224e7873193..87646b8c3cfcc 100644 --- a/cint/test/cpp0.cxx +++ b/cint/test/cpp0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/cpp1.cxx b/cint/test/cpp1.cxx index 9ada8745c24f2..262d1de3e771e 100644 --- a/cint/test/cpp1.cxx +++ b/cint/test/cpp1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/cpp2.cxx b/cint/test/cpp2.cxx index 5d637e8485fad..b9bc1da571dc3 100644 --- a/cint/test/cpp2.cxx +++ b/cint/test/cpp2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/cpp3.cxx b/cint/test/cpp3.cxx index c83ae5c70853e..18d571f9c8c14 100644 --- a/cint/test/cpp3.cxx +++ b/cint/test/cpp3.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/cpp4.cxx b/cint/test/cpp4.cxx index aac09be9914a0..9a48637d73fcf 100644 --- a/cint/test/cpp4.cxx +++ b/cint/test/cpp4.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/cpp5.cxx b/cint/test/cpp5.cxx index 91deaec1788bf..325cebea43e41 100644 --- a/cint/test/cpp5.cxx +++ b/cint/test/cpp5.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/cpp6.cxx b/cint/test/cpp6.cxx index 8b170ca267f90..abe01f0e61b36 100644 --- a/cint/test/cpp6.cxx +++ b/cint/test/cpp6.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/cpp8.cxx b/cint/test/cpp8.cxx index 79fe710d25509..af81648761d3f 100644 --- a/cint/test/cpp8.cxx +++ b/cint/test/cpp8.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/delete0.cxx b/cint/test/delete0.cxx index c26bec60dad1a..e4a27499dc579 100644 --- a/cint/test/delete0.cxx +++ b/cint/test/delete0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/eh1.cxx b/cint/test/eh1.cxx index 0cea6303dbfde..c1088095de4e3 100644 --- a/cint/test/eh1.cxx +++ b/cint/test/eh1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/enumscope.cxx b/cint/test/enumscope.cxx index a97a307ab3de9..2ef4976b3436e 100644 --- a/cint/test/enumscope.cxx +++ b/cint/test/enumscope.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/explicitdtor.cxx b/cint/test/explicitdtor.cxx index d1cbcf668a68b..a1c96f1485498 100644 --- a/cint/test/explicitdtor.cxx +++ b/cint/test/explicitdtor.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/fons3.cxx b/cint/test/fons3.cxx index 2d0ab1396b987..97661349257ab 100644 --- a/cint/test/fons3.cxx +++ b/cint/test/fons3.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/friend0.cxx b/cint/test/friend0.cxx index f9891f6910971..c5f60014cf879 100644 --- a/cint/test/friend0.cxx +++ b/cint/test/friend0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/funcmacro.cxx b/cint/test/funcmacro.cxx index 8cf1a2c726307..7a4274d4393e3 100644 --- a/cint/test/funcmacro.cxx +++ b/cint/test/funcmacro.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/fwdtmplt.cxx b/cint/test/fwdtmplt.cxx index 589fdc448cc40..7e0ec182acfc4 100644 --- a/cint/test/fwdtmplt.cxx +++ b/cint/test/fwdtmplt.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/idxscope0.cxx b/cint/test/idxscope0.cxx index d52f1a3058d21..8cc046ad2d209 100644 --- a/cint/test/idxscope0.cxx +++ b/cint/test/idxscope0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/ifs.cxx b/cint/test/ifs.cxx index 5ca8130266ad3..12b02439ff2c7 100644 --- a/cint/test/ifs.cxx +++ b/cint/test/ifs.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/include.cxx b/cint/test/include.cxx index 95030d6bf00db..f3186eea92185 100644 --- a/cint/test/include.cxx +++ b/cint/test/include.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/inherit0.cxx b/cint/test/inherit0.cxx index a2c1658f52dfc..f5f9cf43817e1 100644 --- a/cint/test/inherit0.cxx +++ b/cint/test/inherit0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/inherit1.cxx b/cint/test/inherit1.cxx index 03cbd484507d3..d947b2e842f42 100644 --- a/cint/test/inherit1.cxx +++ b/cint/test/inherit1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/inherit2.cxx b/cint/test/inherit2.cxx index e67b55a8fa6e5..b637199de5a0f 100644 --- a/cint/test/inherit2.cxx +++ b/cint/test/inherit2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/init1.cxx b/cint/test/init1.cxx index 2556e20709786..66a7be561196c 100644 --- a/cint/test/init1.cxx +++ b/cint/test/init1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/init2.cxx b/cint/test/init2.cxx index de06201a32639..87889987ce2e6 100644 --- a/cint/test/init2.cxx +++ b/cint/test/init2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/longlong.cxx b/cint/test/longlong.cxx index 9301dc038af22..1c866435e33da 100644 --- a/cint/test/longlong.cxx +++ b/cint/test/longlong.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/loopcompile1.cxx b/cint/test/loopcompile1.cxx index df7c117b29d75..f9b259ae74dcf 100644 --- a/cint/test/loopcompile1.cxx +++ b/cint/test/loopcompile1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/loopcompile2.cxx b/cint/test/loopcompile2.cxx index ae9b7808ae3ed..7eeb3bb9140a3 100644 --- a/cint/test/loopcompile2.cxx +++ b/cint/test/loopcompile2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/loopcompile3.cxx b/cint/test/loopcompile3.cxx index 4e739ab26c212..5c776da6f72f5 100644 --- a/cint/test/loopcompile3.cxx +++ b/cint/test/loopcompile3.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/loopcompile4.cxx b/cint/test/loopcompile4.cxx index c19aa63dbe619..68772850ae773 100644 --- a/cint/test/loopcompile4.cxx +++ b/cint/test/loopcompile4.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/loopcompile5.cxx b/cint/test/loopcompile5.cxx index 4f93ff70f7a9a..5f0674e0af519 100644 --- a/cint/test/loopcompile5.cxx +++ b/cint/test/loopcompile5.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/maincmplx.cxx b/cint/test/maincmplx.cxx index 3adf64ede55fa..45bd803b914a9 100644 --- a/cint/test/maincmplx.cxx +++ b/cint/test/maincmplx.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/maptest.cxx b/cint/test/maptest.cxx index ae6a2f093538a..98cca38a916ed 100644 --- a/cint/test/maptest.cxx +++ b/cint/test/maptest.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/maptest.h b/cint/test/maptest.h index 9423d114e4a1c..9ea7019ecd7e8 100644 --- a/cint/test/maptest.h +++ b/cint/test/maptest.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/mfstatic.cxx b/cint/test/mfstatic.cxx index 42f05710c0d5a..08f14ed08da87 100644 --- a/cint/test/mfstatic.cxx +++ b/cint/test/mfstatic.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/minexam.cxx b/cint/test/minexam.cxx index d8a22e2844d28..f70ef6da9019e 100644 --- a/cint/test/minexam.cxx +++ b/cint/test/minexam.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/minherit0.cxx b/cint/test/minherit0.cxx index 045ce3a62a633..ab87d9faad523 100644 --- a/cint/test/minherit0.cxx +++ b/cint/test/minherit0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/mkcmain.cxx b/cint/test/mkcmain.cxx index ca9701850d324..3197abf298101 100644 --- a/cint/test/mkcmain.cxx +++ b/cint/test/mkcmain.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/new0.cxx b/cint/test/new0.cxx index 80b64351987e4..90017b8ca620c 100644 --- a/cint/test/new0.cxx +++ b/cint/test/new0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/nick3.cxx b/cint/test/nick3.cxx index 3c3a889137938..c6f0fe63829e0 100644 --- a/cint/test/nick3.cxx +++ b/cint/test/nick3.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/nick4.cxx b/cint/test/nick4.cxx index c05d5175f8168..ffbaf09236309 100644 --- a/cint/test/nick4.cxx +++ b/cint/test/nick4.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/nstmplt1.cxx b/cint/test/nstmplt1.cxx index ea06cad9e8099..dd622a9b633e5 100644 --- a/cint/test/nstmplt1.cxx +++ b/cint/test/nstmplt1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/oprovld0.cxx b/cint/test/oprovld0.cxx index bc0bdc22f62f5..78a6c9bbd20d1 100644 --- a/cint/test/oprovld0.cxx +++ b/cint/test/oprovld0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/oprovld2.cxx b/cint/test/oprovld2.cxx index 8067ddefb7297..8a3a32f5b13e3 100644 --- a/cint/test/oprovld2.cxx +++ b/cint/test/oprovld2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/ostream.cxx b/cint/test/ostream.cxx index 78de8e2259816..56f91b463b526 100644 --- a/cint/test/ostream.cxx +++ b/cint/test/ostream.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/pb19.cxx b/cint/test/pb19.cxx index 85697e8f1415f..aad4a56b597a9 100644 --- a/cint/test/pb19.cxx +++ b/cint/test/pb19.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/refassign.cxx b/cint/test/refassign.cxx index ce54e5b2f2e35..2e940b6a4c1a5 100644 --- a/cint/test/refassign.cxx +++ b/cint/test/refassign.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/scope0.cxx b/cint/test/scope0.cxx index 68823d33141d0..b11757877cd83 100644 --- a/cint/test/scope0.cxx +++ b/cint/test/scope0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/setw0.cxx b/cint/test/setw0.cxx index f943d74fec0db..8ad241219ee75 100644 --- a/cint/test/setw0.cxx +++ b/cint/test/setw0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/simple20.cxx b/cint/test/simple20.cxx index 2d05d020a163a..dfd0a1f3ad1a7 100755 --- a/cint/test/simple20.cxx +++ b/cint/test/simple20.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/simple21.cxx b/cint/test/simple21.cxx index 1c408ba353a97..574f67b7645de 100755 --- a/cint/test/simple21.cxx +++ b/cint/test/simple21.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/staticary.cxx b/cint/test/staticary.cxx index ca1ab4cc27032..55d03f11c736a 100644 --- a/cint/test/staticary.cxx +++ b/cint/test/staticary.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/staticmem0.cxx b/cint/test/staticmem0.cxx index 6e11eacf064ea..bed9ab56bba64 100644 --- a/cint/test/staticmem0.cxx +++ b/cint/test/staticmem0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/staticmem1.cxx b/cint/test/staticmem1.cxx index 1a3cd050e110d..b688c3757822a 100644 --- a/cint/test/staticmem1.cxx +++ b/cint/test/staticmem1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1002.cxx b/cint/test/t1002.cxx index 8daaa6b7e605c..af2644847aa7b 100644 --- a/cint/test/t1002.cxx +++ b/cint/test/t1002.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1002.h b/cint/test/t1002.h index 79c26444ef953..5f8f2118ddf25 100644 --- a/cint/test/t1002.h +++ b/cint/test/t1002.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1004.cxx b/cint/test/t1004.cxx index 4389375c48774..18e61096e8e30 100644 --- a/cint/test/t1004.cxx +++ b/cint/test/t1004.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1011.cxx b/cint/test/t1011.cxx index 9e6d1c4ecd297..f6e2c4e4ee4ad 100644 --- a/cint/test/t1011.cxx +++ b/cint/test/t1011.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1011.h b/cint/test/t1011.h index af221b9bdd840..ef9b185b5b227 100644 --- a/cint/test/t1011.h +++ b/cint/test/t1011.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1015.cxx b/cint/test/t1015.cxx index 038485e63795c..dee8cc3c8e6d3 100644 --- a/cint/test/t1015.cxx +++ b/cint/test/t1015.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1016.cxx b/cint/test/t1016.cxx index e5b8a75981381..be97660f5fc3e 100644 --- a/cint/test/t1016.cxx +++ b/cint/test/t1016.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1016.h b/cint/test/t1016.h index 634a1e6e2f8a6..9f0e47b453271 100644 --- a/cint/test/t1016.h +++ b/cint/test/t1016.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1023.cxx b/cint/test/t1023.cxx index 624bdbb138360..7e6241aeda31a 100644 --- a/cint/test/t1023.cxx +++ b/cint/test/t1023.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1024.cxx b/cint/test/t1024.cxx index 8fd9c904fe4a8..d5d73c3a7cf37 100644 --- a/cint/test/t1024.cxx +++ b/cint/test/t1024.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1024.h b/cint/test/t1024.h index 7693674cf4a4e..184624de91a46 100644 --- a/cint/test/t1024.h +++ b/cint/test/t1024.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1025.cxx b/cint/test/t1025.cxx index 6f6a54627a66f..5a77e0a5cd41c 100644 --- a/cint/test/t1025.cxx +++ b/cint/test/t1025.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1025.h b/cint/test/t1025.h index 85255fade86a5..1b9984846e6b1 100644 --- a/cint/test/t1025.h +++ b/cint/test/t1025.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1026.cxx b/cint/test/t1026.cxx index cb6e1765a81df..efd1a546d21f6 100644 --- a/cint/test/t1026.cxx +++ b/cint/test/t1026.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1026.h b/cint/test/t1026.h index 867669dadeebd..4c5fc4e558755 100644 --- a/cint/test/t1026.h +++ b/cint/test/t1026.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1027.cxx b/cint/test/t1027.cxx index 2f538908f24fc..2472eeb4a8232 100644 --- a/cint/test/t1027.cxx +++ b/cint/test/t1027.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1027.h b/cint/test/t1027.h index e204457ac3381..b45ffdf0b1d78 100644 --- a/cint/test/t1027.h +++ b/cint/test/t1027.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1030.cxx b/cint/test/t1030.cxx index 8f823f1241075..af251713ce5c0 100644 --- a/cint/test/t1030.cxx +++ b/cint/test/t1030.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1030.h b/cint/test/t1030.h index 496dc142c120a..b0d66884df79f 100644 --- a/cint/test/t1030.h +++ b/cint/test/t1030.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1031.cxx b/cint/test/t1031.cxx index eabc07462c441..4ac5bbba84069 100644 --- a/cint/test/t1031.cxx +++ b/cint/test/t1031.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1031.h b/cint/test/t1031.h index 16c1020874b30..e79fe40496ed9 100644 --- a/cint/test/t1031.h +++ b/cint/test/t1031.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1032.cxx b/cint/test/t1032.cxx index 569f29a2aa168..851d9fb60f863 100644 --- a/cint/test/t1032.cxx +++ b/cint/test/t1032.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1033.cxx b/cint/test/t1033.cxx index 396868c9aa0d7..1acb522477765 100644 --- a/cint/test/t1033.cxx +++ b/cint/test/t1033.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1034.cxx b/cint/test/t1034.cxx index ba332f8dcd5f7..c80575a6c74ee 100644 --- a/cint/test/t1034.cxx +++ b/cint/test/t1034.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1035.cxx b/cint/test/t1035.cxx index 23d36432d6179..5751d350b84f9 100644 --- a/cint/test/t1035.cxx +++ b/cint/test/t1035.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1035.h b/cint/test/t1035.h index 8ff7c0f47c5c8..05be80c4ab203 100644 --- a/cint/test/t1035.h +++ b/cint/test/t1035.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1036.cxx b/cint/test/t1036.cxx index 86af16aa5b216..b0408e17b3863 100644 --- a/cint/test/t1036.cxx +++ b/cint/test/t1036.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1040.cxx b/cint/test/t1040.cxx index cff6cb7f85001..3f120a50223dc 100644 --- a/cint/test/t1040.cxx +++ b/cint/test/t1040.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1040.h b/cint/test/t1040.h index 3c39673979ca7..0a2413226fd88 100644 --- a/cint/test/t1040.h +++ b/cint/test/t1040.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1042.cxx b/cint/test/t1042.cxx index 4cb63254d5aaf..da6493d3ff171 100644 --- a/cint/test/t1042.cxx +++ b/cint/test/t1042.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1046.cxx b/cint/test/t1046.cxx index 94e1e390876f7..82ad6b39336ec 100644 --- a/cint/test/t1046.cxx +++ b/cint/test/t1046.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1046.h b/cint/test/t1046.h index 6877368ca5542..1620d04be8b73 100644 --- a/cint/test/t1046.h +++ b/cint/test/t1046.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1047.cxx b/cint/test/t1047.cxx index ffddce692ac1c..b9477e7f2e87f 100644 --- a/cint/test/t1047.cxx +++ b/cint/test/t1047.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1047.h b/cint/test/t1047.h index df5601053c4f4..b5f4ffd69f792 100644 --- a/cint/test/t1047.h +++ b/cint/test/t1047.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1048.cxx b/cint/test/t1048.cxx index 63021ea0fd0ab..35bb1ab663440 100644 --- a/cint/test/t1048.cxx +++ b/cint/test/t1048.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1048.h b/cint/test/t1048.h index 17afcc2aa3440..9faf1ff2e84c2 100644 --- a/cint/test/t1048.h +++ b/cint/test/t1048.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1049.cxx b/cint/test/t1049.cxx index 35f8a513f0bf3..3d1714b2751f0 100644 --- a/cint/test/t1049.cxx +++ b/cint/test/t1049.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1054.cxx b/cint/test/t1054.cxx index 64f87af8b0ef1..594adbe2849b7 100644 --- a/cint/test/t1054.cxx +++ b/cint/test/t1054.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1055.cxx b/cint/test/t1055.cxx index a620e84217f59..6bb4887198310 100644 --- a/cint/test/t1055.cxx +++ b/cint/test/t1055.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1061.cxx b/cint/test/t1061.cxx index 31846283c40da..38a19f85392be 100644 --- a/cint/test/t1061.cxx +++ b/cint/test/t1061.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1061.h b/cint/test/t1061.h index df5b228d5d871..11c47d2861e82 100644 --- a/cint/test/t1061.h +++ b/cint/test/t1061.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1062.cxx b/cint/test/t1062.cxx index 1b792d9b5a690..c2a61b4ce4ee9 100644 --- a/cint/test/t1062.cxx +++ b/cint/test/t1062.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1062.h b/cint/test/t1062.h index cae917d6c7a55..aa5e291126ccf 100644 --- a/cint/test/t1062.h +++ b/cint/test/t1062.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1067.cxx b/cint/test/t1067.cxx index a3f681336e311..c27e51251b99e 100644 --- a/cint/test/t1067.cxx +++ b/cint/test/t1067.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1067.h b/cint/test/t1067.h index 6957c65db914e..eeee70c677fd0 100644 --- a/cint/test/t1067.h +++ b/cint/test/t1067.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1068.cxx b/cint/test/t1068.cxx index 3ce620f808747..50e091f8b1fab 100644 --- a/cint/test/t1068.cxx +++ b/cint/test/t1068.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1068.h b/cint/test/t1068.h index 76cb91b3b4c98..bbba917676a96 100644 --- a/cint/test/t1068.h +++ b/cint/test/t1068.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1079.cxx b/cint/test/t1079.cxx index f7eda46bdbf3a..2e9bc3e227510 100644 --- a/cint/test/t1079.cxx +++ b/cint/test/t1079.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1079.h b/cint/test/t1079.h index 585730655fc41..ca4c6d4d5bcee 100644 --- a/cint/test/t1079.h +++ b/cint/test/t1079.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1084.cxx b/cint/test/t1084.cxx index e3a1afd99e303..ef176180f664e 100644 --- a/cint/test/t1084.cxx +++ b/cint/test/t1084.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1085.cxx b/cint/test/t1085.cxx index 4db26b5b66c0e..99ebb76ec1afb 100644 --- a/cint/test/t1085.cxx +++ b/cint/test/t1085.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1086.cxx b/cint/test/t1086.cxx index 8df3cd293d971..49e556e10367b 100644 --- a/cint/test/t1086.cxx +++ b/cint/test/t1086.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1088.cxx b/cint/test/t1088.cxx index e141c3d2d590d..3f604e326116b 100644 --- a/cint/test/t1088.cxx +++ b/cint/test/t1088.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1094.cxx b/cint/test/t1094.cxx index 58f342504a34b..1fe6e0e68f776 100644 --- a/cint/test/t1094.cxx +++ b/cint/test/t1094.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1101.cxx b/cint/test/t1101.cxx index 57f6301ecf9a3..322fb5c4775cd 100644 --- a/cint/test/t1101.cxx +++ b/cint/test/t1101.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1115.cxx b/cint/test/t1115.cxx index 6f20e3f60626a..08efe39e2b47c 100644 --- a/cint/test/t1115.cxx +++ b/cint/test/t1115.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1115.h b/cint/test/t1115.h index fe46bcde53410..4eadcf0f7c4ad 100644 --- a/cint/test/t1115.h +++ b/cint/test/t1115.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1124.cxx b/cint/test/t1124.cxx index 276106fbed851..1f12cee9d58ca 100644 --- a/cint/test/t1124.cxx +++ b/cint/test/t1124.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1125.cxx b/cint/test/t1125.cxx index b68e728049379..a498957bd4f43 100644 --- a/cint/test/t1125.cxx +++ b/cint/test/t1125.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1126.cxx b/cint/test/t1126.cxx index 7969637596c47..5017013106882 100644 --- a/cint/test/t1126.cxx +++ b/cint/test/t1126.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1127.cxx b/cint/test/t1127.cxx index aa79477231e26..90ee3a032fa9f 100644 --- a/cint/test/t1127.cxx +++ b/cint/test/t1127.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1127.h b/cint/test/t1127.h index fd259e4007cf5..ad19be36b0f23 100644 --- a/cint/test/t1127.h +++ b/cint/test/t1127.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1128.cxx b/cint/test/t1128.cxx index 6af3895131910..4790f28b5e5f7 100644 --- a/cint/test/t1128.cxx +++ b/cint/test/t1128.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1129.cxx b/cint/test/t1129.cxx index e4b8ef725410b..96aeb1e2df330 100644 --- a/cint/test/t1129.cxx +++ b/cint/test/t1129.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1134.cxx b/cint/test/t1134.cxx index 4b70c4a0ae698..53f0a43761ebb 100644 --- a/cint/test/t1134.cxx +++ b/cint/test/t1134.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1136.cxx b/cint/test/t1136.cxx index 0f474258ba24b..3951f51d8bcc6 100644 --- a/cint/test/t1136.cxx +++ b/cint/test/t1136.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1140.cxx b/cint/test/t1140.cxx index 996290f9e649a..0d2ad8d2b45fd 100644 --- a/cint/test/t1140.cxx +++ b/cint/test/t1140.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1143.cxx b/cint/test/t1143.cxx index b5fc4c1a58e47..00f6670f0168e 100644 --- a/cint/test/t1143.cxx +++ b/cint/test/t1143.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1144.cxx b/cint/test/t1144.cxx index a3f63dda46af4..3b77575f201d6 100644 --- a/cint/test/t1144.cxx +++ b/cint/test/t1144.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1148.cxx b/cint/test/t1148.cxx index cd3e1cf713549..2e2ee3133b41d 100644 --- a/cint/test/t1148.cxx +++ b/cint/test/t1148.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1157.cxx b/cint/test/t1157.cxx index f9ca546754704..53805da5576e1 100644 --- a/cint/test/t1157.cxx +++ b/cint/test/t1157.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1158.cxx b/cint/test/t1158.cxx index 6263ad17f3d22..4fee060d4a188 100644 --- a/cint/test/t1158.cxx +++ b/cint/test/t1158.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1160.cxx b/cint/test/t1160.cxx index dc02386d71291..3dd9a5344e32d 100644 --- a/cint/test/t1160.cxx +++ b/cint/test/t1160.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1164.cxx b/cint/test/t1164.cxx index e891ef51826fa..ca1f438a0fdde 100644 --- a/cint/test/t1164.cxx +++ b/cint/test/t1164.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1165.cxx b/cint/test/t1165.cxx index cf9976be9f6c3..e86850946cf42 100644 --- a/cint/test/t1165.cxx +++ b/cint/test/t1165.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1178.cxx b/cint/test/t1178.cxx index f95ec34b7c255..0caeb62e1d656 100644 --- a/cint/test/t1178.cxx +++ b/cint/test/t1178.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1178.h b/cint/test/t1178.h index 467feb05ef924..5296eae704645 100644 --- a/cint/test/t1178.h +++ b/cint/test/t1178.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1187.cxx b/cint/test/t1187.cxx index 87825d8f651ad..f318b9d786bdc 100644 --- a/cint/test/t1187.cxx +++ b/cint/test/t1187.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1187.h b/cint/test/t1187.h index 1fd47920774cd..30b26da5964c6 100644 --- a/cint/test/t1187.h +++ b/cint/test/t1187.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1192.cxx b/cint/test/t1192.cxx index 72c62e3a64d92..902861a62ac87 100644 --- a/cint/test/t1192.cxx +++ b/cint/test/t1192.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1193.cxx b/cint/test/t1193.cxx index eb1967c221878..a2d6792b16f07 100644 --- a/cint/test/t1193.cxx +++ b/cint/test/t1193.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1193.h b/cint/test/t1193.h index 15c12cf04893c..7e7956105facd 100644 --- a/cint/test/t1193.h +++ b/cint/test/t1193.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1200.h b/cint/test/t1200.h index b89f549f29eab..8574a5d16ff6a 100644 --- a/cint/test/t1200.h +++ b/cint/test/t1200.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1203.cxx b/cint/test/t1203.cxx index 06eed177f9e86..5f49e630a20a6 100644 --- a/cint/test/t1203.cxx +++ b/cint/test/t1203.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1205.cxx b/cint/test/t1205.cxx index 92baea6193bcc..9d6adf631264d 100644 --- a/cint/test/t1205.cxx +++ b/cint/test/t1205.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1205.h b/cint/test/t1205.h index 3727bc47b8ce1..b0a194f07f322 100644 --- a/cint/test/t1205.h +++ b/cint/test/t1205.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1213.cxx b/cint/test/t1213.cxx index db4237f11b7d6..438cce55913ea 100644 --- a/cint/test/t1213.cxx +++ b/cint/test/t1213.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1214.cxx b/cint/test/t1214.cxx index 4fee825e3f752..220a6b451971d 100644 --- a/cint/test/t1214.cxx +++ b/cint/test/t1214.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1215.cxx b/cint/test/t1215.cxx index 476006e2e115a..8af8dd69b5cf1 100644 --- a/cint/test/t1215.cxx +++ b/cint/test/t1215.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1215.h b/cint/test/t1215.h index 585d76cc5f2c0..3d004113dc33c 100644 --- a/cint/test/t1215.h +++ b/cint/test/t1215.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1221.cxx b/cint/test/t1221.cxx index b1c2e8c258862..e1f94688de307 100644 --- a/cint/test/t1221.cxx +++ b/cint/test/t1221.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1222.cxx b/cint/test/t1222.cxx index 91a900c71fce3..e3a87064a4cf7 100644 --- a/cint/test/t1222.cxx +++ b/cint/test/t1222.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1223.cxx b/cint/test/t1223.cxx index 94b20f45ab116..fcab21d79a5ed 100644 --- a/cint/test/t1223.cxx +++ b/cint/test/t1223.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1224.cxx b/cint/test/t1224.cxx index c06cb64da5c69..5dc1b017086df 100644 --- a/cint/test/t1224.cxx +++ b/cint/test/t1224.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1228.cxx b/cint/test/t1228.cxx index 2fc008858c255..2168ea0ce8bcf 100644 --- a/cint/test/t1228.cxx +++ b/cint/test/t1228.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1247.cxx b/cint/test/t1247.cxx index b8c16bef44444..6557571ce0908 100644 --- a/cint/test/t1247.cxx +++ b/cint/test/t1247.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1247.h b/cint/test/t1247.h index a5f1cc9353a3e..2cf8a3f32bc47 100644 --- a/cint/test/t1247.h +++ b/cint/test/t1247.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1247a.h b/cint/test/t1247a.h index d49f2e9988dd1..4bce27f3c0a04 100644 --- a/cint/test/t1247a.h +++ b/cint/test/t1247a.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1276.cxx b/cint/test/t1276.cxx index 7a70140f0d857..06e3588584326 100755 --- a/cint/test/t1276.cxx +++ b/cint/test/t1276.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1276.h b/cint/test/t1276.h index bc65c30adfb4e..3cb406271f4ad 100755 --- a/cint/test/t1276.h +++ b/cint/test/t1276.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1277.cxx b/cint/test/t1277.cxx index 5cf401c755072..e4c2159c915d1 100644 --- a/cint/test/t1277.cxx +++ b/cint/test/t1277.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1277.h b/cint/test/t1277.h index ada3886996c34..ccc627414c27b 100644 --- a/cint/test/t1277.h +++ b/cint/test/t1277.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1278.cxx b/cint/test/t1278.cxx index 4f3e2f8536a32..b28c5a0d27a2a 100644 --- a/cint/test/t1278.cxx +++ b/cint/test/t1278.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1279.cxx b/cint/test/t1279.cxx index de3d601197b9d..869e996545f52 100644 --- a/cint/test/t1279.cxx +++ b/cint/test/t1279.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1280.cxx b/cint/test/t1280.cxx index 413280a92e4ca..1154b0438159b 100755 --- a/cint/test/t1280.cxx +++ b/cint/test/t1280.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t1281.cxx b/cint/test/t1281.cxx index 52c6e885c5f5d..5804f56b7610f 100644 --- a/cint/test/t1281.cxx +++ b/cint/test/t1281.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t215.cxx b/cint/test/t215.cxx index 1bbf3c890b71c..17bb278b8e76a 100644 --- a/cint/test/t215.cxx +++ b/cint/test/t215.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t358.cxx b/cint/test/t358.cxx index a6d2af7960143..3733bcfe4a7be 100644 --- a/cint/test/t358.cxx +++ b/cint/test/t358.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t488.cxx b/cint/test/t488.cxx index 6f834da95e95f..fa2137e605297 100644 --- a/cint/test/t488.cxx +++ b/cint/test/t488.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t516.cxx b/cint/test/t516.cxx index 10d5198b75879..2172b3819bd8c 100644 --- a/cint/test/t516.cxx +++ b/cint/test/t516.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t516.h b/cint/test/t516.h index 0d69fd25aa3c2..36f61a1bed821 100644 --- a/cint/test/t516.h +++ b/cint/test/t516.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t603.cxx b/cint/test/t603.cxx index 4a40c7899ad72..8be63031bd466 100644 --- a/cint/test/t603.cxx +++ b/cint/test/t603.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t627.cxx b/cint/test/t627.cxx index 8312979eb9324..a3608d2afdc41 100644 --- a/cint/test/t627.cxx +++ b/cint/test/t627.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t627.h b/cint/test/t627.h index 0b93110c73945..731a5d9fe0b47 100644 --- a/cint/test/t627.h +++ b/cint/test/t627.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t630.cxx b/cint/test/t630.cxx index dbad8599c09a4..95b945a9a58c4 100644 --- a/cint/test/t630.cxx +++ b/cint/test/t630.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t633.cxx b/cint/test/t633.cxx index 22350f405763a..c8aa2f75f41c5 100644 --- a/cint/test/t633.cxx +++ b/cint/test/t633.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t633.h b/cint/test/t633.h index 07b3ee7c23b60..4a1d4b72a6fb3 100644 --- a/cint/test/t633.h +++ b/cint/test/t633.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t634.cxx b/cint/test/t634.cxx index d6791cfbc77aa..83782b69bfe53 100644 --- a/cint/test/t634.cxx +++ b/cint/test/t634.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t648.cxx b/cint/test/t648.cxx index ffe4c270be9cd..3764b451c5a16 100644 --- a/cint/test/t648.cxx +++ b/cint/test/t648.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t674.cxx b/cint/test/t674.cxx index 24129315c61f1..9658c0d9f9d1c 100644 --- a/cint/test/t674.cxx +++ b/cint/test/t674.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t674.h b/cint/test/t674.h index 0c1f22e4522dd..946b0592b8a40 100644 --- a/cint/test/t674.h +++ b/cint/test/t674.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t676.cxx b/cint/test/t676.cxx index 24210f38f13c9..7e3b5a643850d 100644 --- a/cint/test/t676.cxx +++ b/cint/test/t676.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t694.cxx b/cint/test/t694.cxx index 60e0fb2b97a28..ac6ee2810b1ce 100644 --- a/cint/test/t694.cxx +++ b/cint/test/t694.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t694.h b/cint/test/t694.h index 532d39f630473..57668ebe29aed 100644 --- a/cint/test/t694.h +++ b/cint/test/t694.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t695.cxx b/cint/test/t695.cxx index d27f137f8395c..5bf57f74eb55d 100644 --- a/cint/test/t695.cxx +++ b/cint/test/t695.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t705.cxx b/cint/test/t705.cxx index 944454cc2e419..b96041bb3dcda 100644 --- a/cint/test/t705.cxx +++ b/cint/test/t705.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t705.h b/cint/test/t705.h index 132993dd5c647..a3088db420ce5 100644 --- a/cint/test/t705.h +++ b/cint/test/t705.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t714.cxx b/cint/test/t714.cxx index d62924403ff64..a8300ea0d48cd 100644 --- a/cint/test/t714.cxx +++ b/cint/test/t714.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t733.cxx b/cint/test/t733.cxx index 111817f85e715..fbecc16e5acc0 100644 --- a/cint/test/t733.cxx +++ b/cint/test/t733.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t733.h b/cint/test/t733.h index 30922b1eb06e1..e081924f51bc3 100644 --- a/cint/test/t733.h +++ b/cint/test/t733.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t749.cxx b/cint/test/t749.cxx index 366166c18236e..51d7b0f0a11a9 100644 --- a/cint/test/t749.cxx +++ b/cint/test/t749.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t751.cxx b/cint/test/t751.cxx index 9a986d95e1fcf..a50c496b58918 100644 --- a/cint/test/t751.cxx +++ b/cint/test/t751.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t764.cxx b/cint/test/t764.cxx index 94a6748de4cee..7b0e94ee09559 100644 --- a/cint/test/t764.cxx +++ b/cint/test/t764.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t767.cxx b/cint/test/t767.cxx index 2a3d13afccf60..24ac8b1d625b8 100644 --- a/cint/test/t767.cxx +++ b/cint/test/t767.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t776.cxx b/cint/test/t776.cxx index 56dfbb17278a5..472c1500fbfd7 100644 --- a/cint/test/t776.cxx +++ b/cint/test/t776.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t777.cxx b/cint/test/t777.cxx index 91398b99e9283..c56199a57dbf7 100644 --- a/cint/test/t777.cxx +++ b/cint/test/t777.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t784.cxx b/cint/test/t784.cxx index 49dc0e479ca55..7d96b82a93ead 100644 --- a/cint/test/t784.cxx +++ b/cint/test/t784.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t825.cxx b/cint/test/t825.cxx index ff7708a27b92b..4da99da25a18b 100644 --- a/cint/test/t825.cxx +++ b/cint/test/t825.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t910.cxx b/cint/test/t910.cxx index bf9b3baef2fb2..09a3cd14b6aab 100644 --- a/cint/test/t910.cxx +++ b/cint/test/t910.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t916.cxx b/cint/test/t916.cxx index d123bb551e35a..91895a3c2c6af 100644 --- a/cint/test/t916.cxx +++ b/cint/test/t916.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t927.cxx b/cint/test/t927.cxx index acedd20301fbf..a350d5389c305 100644 --- a/cint/test/t927.cxx +++ b/cint/test/t927.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t927.h b/cint/test/t927.h index cfce362b7f705..194a91d98951a 100644 --- a/cint/test/t927.h +++ b/cint/test/t927.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t928.cxx b/cint/test/t928.cxx index bb1f72f0cf7ab..5116b88fd97f5 100644 --- a/cint/test/t928.cxx +++ b/cint/test/t928.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t928.h b/cint/test/t928.h index 4263fa18a8474..fd851450e495e 100644 --- a/cint/test/t928.h +++ b/cint/test/t928.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t928a.h b/cint/test/t928a.h index 7298782bf287c..904db3c410b9d 100644 --- a/cint/test/t928a.h +++ b/cint/test/t928a.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t928b.h b/cint/test/t928b.h index 13363a4e5db9e..973b419236908 100644 --- a/cint/test/t928b.h +++ b/cint/test/t928b.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t930.cxx b/cint/test/t930.cxx index d9ac100f219f7..79eed2d801302 100644 --- a/cint/test/t930.cxx +++ b/cint/test/t930.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t938.cxx b/cint/test/t938.cxx index 64c02b2037a3d..aadefd112e254 100644 --- a/cint/test/t938.cxx +++ b/cint/test/t938.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -42,7 +42,7 @@ int main() { There are 2 problems. To see the second problem I commented out the line defining 'cont' after the first .L. -cint : C/C++ interpreter (mailing list 'cint@root.cern.ch') +cint : C/C++ interpreter (mailing list 'root-cint@cern.ch') Copyright(c) : 1995~2002 Masaharu Goto revision : 5.15.61, Oct 6 2002 by M.Goto diff --git a/cint/test/t958.cxx b/cint/test/t958.cxx index 1573ee74bdfce..6438e4cea8373 100644 --- a/cint/test/t958.cxx +++ b/cint/test/t958.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t958.h b/cint/test/t958.h index c557ad6eee836..fa7d49f1d6a5f 100644 --- a/cint/test/t958.h +++ b/cint/test/t958.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t959.cxx b/cint/test/t959.cxx index d30dde55a587b..e0cc2810fcb1c 100644 --- a/cint/test/t959.cxx +++ b/cint/test/t959.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t961.cxx b/cint/test/t961.cxx index de8db6a6e6779..d48d402daa27c 100644 --- a/cint/test/t961.cxx +++ b/cint/test/t961.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t961.h b/cint/test/t961.h index ab3ef619c3f98..9d0defd5b015b 100644 --- a/cint/test/t961.h +++ b/cint/test/t961.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t963.cxx b/cint/test/t963.cxx index 84683f64abcc4..f488c6ac027a4 100644 --- a/cint/test/t963.cxx +++ b/cint/test/t963.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t963.h b/cint/test/t963.h index 8096c67b26844..4c3ea2a36e518 100644 --- a/cint/test/t963.h +++ b/cint/test/t963.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t966.cxx b/cint/test/t966.cxx index 55cf1a1756e35..17a63c06cc9ec 100644 --- a/cint/test/t966.cxx +++ b/cint/test/t966.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t966.h b/cint/test/t966.h index aaa77e0bbbc25..74ffc2a098890 100644 --- a/cint/test/t966.h +++ b/cint/test/t966.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t968.cxx b/cint/test/t968.cxx index 4b6095a8c4711..4427420b1b839 100644 --- a/cint/test/t968.cxx +++ b/cint/test/t968.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t968.h b/cint/test/t968.h index 8565f79c726f9..2459c6dfbf738 100644 --- a/cint/test/t968.h +++ b/cint/test/t968.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t970.cxx b/cint/test/t970.cxx index 25cc7100fc246..5fed91e457cf1 100644 --- a/cint/test/t970.cxx +++ b/cint/test/t970.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t970.h b/cint/test/t970.h index 880bb9a1fdc44..b0f9b7a77a218 100644 --- a/cint/test/t970.h +++ b/cint/test/t970.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t972.cxx b/cint/test/t972.cxx index e8ff78a6f0901..9399e9a619746 100644 --- a/cint/test/t972.cxx +++ b/cint/test/t972.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t972a.h b/cint/test/t972a.h index c051c4386e861..4a17e527fcc12 100644 --- a/cint/test/t972a.h +++ b/cint/test/t972a.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t972b.h b/cint/test/t972b.h index 789a8cce8fabb..86bd9a225c9dd 100644 --- a/cint/test/t972b.h +++ b/cint/test/t972b.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t976.cxx b/cint/test/t976.cxx index 6515005cab832..5319a8d15c5cf 100644 --- a/cint/test/t976.cxx +++ b/cint/test/t976.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t976.h b/cint/test/t976.h index 737ac51b73579..5303390c4fe18 100644 --- a/cint/test/t976.h +++ b/cint/test/t976.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t977.cxx b/cint/test/t977.cxx index 92a78f2ab1f8d..1b8dc6aaecbf2 100644 --- a/cint/test/t977.cxx +++ b/cint/test/t977.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t977.h b/cint/test/t977.h index 86ebdcc02c8a9..677c6f4ecf37d 100644 --- a/cint/test/t977.h +++ b/cint/test/t977.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t980.cxx b/cint/test/t980.cxx index ac49572d378af..16dd16732191c 100644 --- a/cint/test/t980.cxx +++ b/cint/test/t980.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t980.h b/cint/test/t980.h index 5ab323a2dbc42..2f055713b2664 100644 --- a/cint/test/t980.h +++ b/cint/test/t980.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t986.cxx b/cint/test/t986.cxx index d90c177e9df42..5ea3efbe8efc3 100644 --- a/cint/test/t986.cxx +++ b/cint/test/t986.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t987.cxx b/cint/test/t987.cxx index 8cd80484aeca9..472956e6c6a6c 100644 --- a/cint/test/t987.cxx +++ b/cint/test/t987.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t987.h b/cint/test/t987.h index 629aa5529be4a..4992191317cc2 100644 --- a/cint/test/t987.h +++ b/cint/test/t987.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t991.cxx b/cint/test/t991.cxx index 2df7112f29331..b363a249cdd7b 100644 --- a/cint/test/t991.cxx +++ b/cint/test/t991.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t991.h b/cint/test/t991.h index ff6b53b2cf845..1eff49874b2cc 100644 --- a/cint/test/t991.h +++ b/cint/test/t991.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t991a.h b/cint/test/t991a.h index beea68aaca8a5..1057e74ddd8c8 100644 --- a/cint/test/t991a.h +++ b/cint/test/t991a.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t991b.h b/cint/test/t991b.h index da6ae253c17cc..db57f7b25d783 100644 --- a/cint/test/t991b.h +++ b/cint/test/t991b.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t991c.h b/cint/test/t991c.h index 4d2650d9427f5..f56990c7ff30f 100644 --- a/cint/test/t991c.h +++ b/cint/test/t991c.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t992.cxx b/cint/test/t992.cxx index e1078d41486ad..a12b9459949aa 100644 --- a/cint/test/t992.cxx +++ b/cint/test/t992.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t992.h b/cint/test/t992.h index 3f33ad225a4d2..2572cbd9c5db0 100644 --- a/cint/test/t992.h +++ b/cint/test/t992.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t993.c b/cint/test/t993.c index 852371b4e883b..5f5b64d969df2 100644 --- a/cint/test/t993.c +++ b/cint/test/t993.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t993.h b/cint/test/t993.h index ca59f2602bee8..2c0c1a1be9201 100644 --- a/cint/test/t993.h +++ b/cint/test/t993.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t995.cxx b/cint/test/t995.cxx index 4f9d8181ec591..9d8203f949106 100644 --- a/cint/test/t995.cxx +++ b/cint/test/t995.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t995.h b/cint/test/t995.h index 740a73d4dde29..82c3e6096f332 100644 --- a/cint/test/t995.h +++ b/cint/test/t995.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t996.cxx b/cint/test/t996.cxx index f440d9f270d59..87984c4b620e3 100644 --- a/cint/test/t996.cxx +++ b/cint/test/t996.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t996.h b/cint/test/t996.h index acfd3133ff8d6..291fd603bdbe7 100644 --- a/cint/test/t996.h +++ b/cint/test/t996.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/t998.cxx b/cint/test/t998.cxx index 53592ef6694fa..87eb32bbd6ad1 100644 --- a/cint/test/t998.cxx +++ b/cint/test/t998.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/telea0.cxx b/cint/test/telea0.cxx index 6eac47d75e6c0..054e106844a19 100644 --- a/cint/test/telea0.cxx +++ b/cint/test/telea0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/telea1.cxx b/cint/test/telea1.cxx index 2953be84237ab..62779338af81a 100644 --- a/cint/test/telea1.cxx +++ b/cint/test/telea1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/telea2.cxx b/cint/test/telea2.cxx index e300261cb3fff..f893d8ef20838 100644 --- a/cint/test/telea2.cxx +++ b/cint/test/telea2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/telea3.cxx b/cint/test/telea3.cxx index 589a8fef59832..0b388e8bb89fa 100644 --- a/cint/test/telea3.cxx +++ b/cint/test/telea3.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/telea5.cxx b/cint/test/telea5.cxx index 936b3e1fc1150..8d1ab481f54d0 100644 --- a/cint/test/telea5.cxx +++ b/cint/test/telea5.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/telea6.cxx b/cint/test/telea6.cxx index f9fd196a0f03d..ea0b803b3cb67 100644 --- a/cint/test/telea6.cxx +++ b/cint/test/telea6.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/telea7.cxx b/cint/test/telea7.cxx index 961d69c7691a1..a6ef95aa0df77 100644 --- a/cint/test/telea7.cxx +++ b/cint/test/telea7.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/telea8.cxx b/cint/test/telea8.cxx index 4e2818aba5bf7..e4c7a7d302526 100644 --- a/cint/test/telea8.cxx +++ b/cint/test/telea8.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/temp.cxx b/cint/test/temp.cxx index 0becc8dcf09ef..e5805f338db8a 100644 --- a/cint/test/temp.cxx +++ b/cint/test/temp.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/template.cxx b/cint/test/template.cxx index cabb45e1a93bb..9319434b7da4e 100644 --- a/cint/test/template.cxx +++ b/cint/test/template.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/template.h b/cint/test/template.h index 989c11785e417..e35990910fef3 100644 --- a/cint/test/template.h +++ b/cint/test/template.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/template0.cxx b/cint/test/template0.cxx index c16fc6db9cf42..b4f7345361aa5 100644 --- a/cint/test/template0.cxx +++ b/cint/test/template0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/template1.cxx b/cint/test/template1.cxx index b88ca1581fcda..dc0f9ae4ca4a8 100644 --- a/cint/test/template1.cxx +++ b/cint/test/template1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/template2.cxx b/cint/test/template2.cxx index 4e0a5fda8c3cf..07e8f5e632988 100644 --- a/cint/test/template2.cxx +++ b/cint/test/template2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/template3.cxx b/cint/test/template3.cxx index 873a8d73a9bef..5bcea7c6bd85f 100644 --- a/cint/test/template3.cxx +++ b/cint/test/template3.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/template4.cxx b/cint/test/template4.cxx index 5af7370ff13ac..d52033774e1f8 100644 --- a/cint/test/template4.cxx +++ b/cint/test/template4.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/template5.cxx b/cint/test/template5.cxx index 1f1243c1c39b8..e60e8446bfea3 100644 --- a/cint/test/template5.cxx +++ b/cint/test/template5.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/template6.cxx b/cint/test/template6.cxx index 30e8a91df66e0..8b095818ea4d2 100644 --- a/cint/test/template6.cxx +++ b/cint/test/template6.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/test.vcproj b/cint/test/test.vcproj index 90fd9c9a5b7ae..d44719155fa34 100644 --- a/cint/test/test.vcproj +++ b/cint/test/test.vcproj @@ -1,1584 +1,1584 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/cint/test/vbase.cxx b/cint/test/vbase.cxx index 1b7cd4eca3f05..218a2502f052c 100644 --- a/cint/test/vbase.cxx +++ b/cint/test/vbase.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/vbase.h b/cint/test/vbase.h index cd817347ed337..813b7c2ae1ee6 100644 --- a/cint/test/vbase.h +++ b/cint/test/vbase.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/vbase1.cxx b/cint/test/vbase1.cxx index c416013447771..fe139fea190c9 100644 --- a/cint/test/vbase1.cxx +++ b/cint/test/vbase1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/vbase1.h b/cint/test/vbase1.h index 107190c0950c7..6e965eb6b84f4 100644 --- a/cint/test/vbase1.h +++ b/cint/test/vbase1.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/vec3d.cxx b/cint/test/vec3d.cxx index 1987fb42e8084..625d6a5b13dd2 100644 --- a/cint/test/vec3d.cxx +++ b/cint/test/vec3d.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/vec3d.h b/cint/test/vec3d.h index 62e527fcd60a2..b9b28400328ac 100644 --- a/cint/test/vec3d.h +++ b/cint/test/vec3d.h @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/virtualfunc0.cxx b/cint/test/virtualfunc0.cxx index 8fc2f090ee1aa..7594b6615d317 100644 --- a/cint/test/virtualfunc0.cxx +++ b/cint/test/virtualfunc0.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/virtualfunc1.cxx b/cint/test/virtualfunc1.cxx index 739cdb605611f..049e30695016f 100644 --- a/cint/test/virtualfunc1.cxx +++ b/cint/test/virtualfunc1.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/test/virtualfunc2.cxx b/cint/test/virtualfunc2.cxx index a2553c2461ad8..f0cfb978311e4 100644 --- a/cint/test/virtualfunc2.cxx +++ b/cint/test/virtualfunc2.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/tool/chmod.cxx b/cint/tool/chmod.cxx index ef724d5bbaffc..e03a847d7a1c4 100644 --- a/cint/tool/chmod.cxx +++ b/cint/tool/chmod.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/tool/ifdef/get.c b/cint/tool/ifdef/get.c index ecbdaae7b2f6a..09dbfde1b1f2a 100644 --- a/cint/tool/ifdef/get.c +++ b/cint/tool/ifdef/get.c @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/tool/ifdef/ifdef.cxx b/cint/tool/ifdef/ifdef.cxx index 68a10ef8e0c14..7e2914086965c 100644 --- a/cint/tool/ifdef/ifdef.cxx +++ b/cint/tool/ifdef/ifdef.cxx @@ -1,6 +1,6 @@ /* -*- C++ -*- */ /************************************************************************* - * Copyright(c) 1995~2005 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2005 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * diff --git a/cint/tool/makecint.cxx b/cint/tool/makecint.cxx index 27fb8be72725d..5881fde8af832 100644 --- a/cint/tool/makecint.cxx +++ b/cint/tool/makecint.cxx @@ -8,7 +8,7 @@ * This tool creates Makefile for encapsurating arbitrary C/C++ object * into Cint as Dynamic Link Library or archived library ************************************************************************ - * Copyright(c) 1995~2010 Masaharu Goto (cint@pcroot.cern.ch) + * Copyright(c) 1995~2010 Masaharu Goto (root-cint@cern.ch) * * For the licensing terms see the file COPYING * @@ -143,7 +143,7 @@ void G__printtitle() #else printf("# makecint : interpreter-compiler for cint (UNIX version)\n"); #endif - printf("# Copyright(c) 1995~2010 Masaharu Goto. Mailing list: cint@pcroot.cern.ch\n"); + printf("# Copyright(c) 1995~2010 Masaharu Goto. Mailing list: root-cint@cern.ch\n"); printf("##########################################################################\n"); } diff --git a/cint/tool/rmkdepend/main.c b/cint/tool/rmkdepend/main.c index 9251382060b6e..e28f48a18cfc2 100644 --- a/cint/tool/rmkdepend/main.c +++ b/cint/tool/rmkdepend/main.c @@ -58,7 +58,7 @@ in this Software without prior written authorization from the X Consortium. #if !defined(MAC_OS_X_VERSION_10_4) extern int fchmod(); #endif -#else +#elif !defined(__GLIBC__) || __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 16) extern int fchmod(); #endif #endif diff --git a/cmake/modules/CMakeCPackOptions.cmake.in b/cmake/modules/CMakeCPackOptions.cmake.in index a1907c3206d10..3d0ec4d8d3e7a 100644 --- a/cmake/modules/CMakeCPackOptions.cmake.in +++ b/cmake/modules/CMakeCPackOptions.cmake.in @@ -11,7 +11,7 @@ if(CPACK_GENERATOR MATCHES "NSIS") set(CPACK_NSIS_DISPLAY_NAME "${CPACK_PACKAGE_INSTALL_DIRECTORY}") set(CPACK_NSIS_HELP_LINK "http:\\\\root.cern.ch") set(CPACK_NSIS_URL_INFO_ABOUT "http:\\\\root.cern.ch\\drupal\\content\\about") - set(CPACK_NSIS_CONTACT "roottalk@root.cern.ch") + set(CPACK_NSIS_CONTACT "roottalk@cern.ch") set(CPACK_NSIS_MODIFY_PATH ON) # Register .root file type set(CPACK_NSIS_EXTRA_INSTALL_COMMANDS " diff --git a/cmake/modules/CheckCXXCompilerFlag.cmake b/cmake/modules/CheckCXXCompilerFlag.cmake new file mode 100644 index 0000000000000..3618b71390e8a --- /dev/null +++ b/cmake/modules/CheckCXXCompilerFlag.cmake @@ -0,0 +1,48 @@ +# - Check whether the CXX compiler supports a given flag. +# CHECK_CXX_COMPILER_FLAG( ) +# - the compiler flag +# - variable to store the result +# This internally calls the check_cxx_source_compiles macro. See help +# for CheckCXXSourceCompiles for a listing of variables that can +# modify the build. + +#============================================================================= +# Copyright 2006-2010 Kitware, Inc. +# Copyright 2006 Alexander Neundorf +# Copyright 2011 Matthias Kretz +# +# Distributed under the OSI-approved BSD License (the "License"); +# see accompanying file Copyright.txt for details. +# +# This software is distributed WITHOUT ANY WARRANTY; without even the +# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +# See the License for more information. +#============================================================================= +# (To distribute this file outside of CMake, substitute the full +# License text for the above reference.) + +INCLUDE(CheckCXXSourceCompiles) + +MACRO (CHECK_CXX_COMPILER_FLAG _FLAG _RESULT) + SET(SAFE_CMAKE_REQUIRED_DEFINITIONS "${CMAKE_REQUIRED_DEFINITIONS}") + SET(CMAKE_REQUIRED_DEFINITIONS "${_FLAG}") + CHECK_CXX_SOURCE_COMPILES("int main() { return 0;}" ${_RESULT} + # Some compilers do not fail with a bad flag + FAIL_REGEX "command line option .* is valid for .* but not for C\\\\+\\\\+" # GNU + FAIL_REGEX "unrecognized .*option" # GNU + FAIL_REGEX "unknown .*option" # Clang + FAIL_REGEX "invalid value" # Clang + FAIL_REGEX "ignoring unknown option" # MSVC + FAIL_REGEX "warning D9002" # MSVC, any lang + FAIL_REGEX "option.*not supported" # Intel + FAIL_REGEX "invalid argument .*option" # Intel + FAIL_REGEX "ignoring option .*argument required" # Intel + FAIL_REGEX "[Uu]nknown option" # HP + FAIL_REGEX "[Ww]arning: [Oo]ption" # SunPro + FAIL_REGEX "command option .* is not recognized" # XL + FAIL_REGEX "not supported in this configuration; ignored" # AIX + FAIL_REGEX "File with unknown suffix passed to linker" # PGI + FAIL_REGEX "WARNING: unknown flag:" # Open64 + ) + SET (CMAKE_REQUIRED_DEFINITIONS "${SAFE_CMAKE_REQUIRED_DEFINITIONS}") +ENDMACRO (CHECK_CXX_COMPILER_FLAG) diff --git a/cmake/modules/CheckCompiler.cmake b/cmake/modules/CheckCompiler.cmake index 64c10fb585369..e04a2cd69f5eb 100644 --- a/cmake/modules/CheckCompiler.cmake +++ b/cmake/modules/CheckCompiler.cmake @@ -2,8 +2,8 @@ # CheckCompiler.cmake #--------------------------------------------------------------------------------------------------- -#---Enable FORTRAN (unfortunatelly is not nowt possible in all cases)------------------------------- -if(NOT WIN32 AND NOT CMAKE_GENERATOR STREQUAL Xcode) +#---Enable FORTRAN (unfortunatelly is not not possible in all cases)------------------------------- +if(fortran AND NOT WIN32 AND NOT CMAKE_GENERATOR STREQUAL Xcode AND NOT CMAKE_GENERATOR STREQUAL Ninja) #--Work-around for CMake issue 0009220 if(DEFINED CMAKE_Fortran_COMPILER AND CMAKE_Fortran_COMPILER MATCHES "^$") set(CMAKE_Fortran_COMPILER CMAKE_Fortran_COMPILER-NOTFOUND) @@ -25,9 +25,19 @@ endif() #---Obtain the major and minor version of the GNU compiler------------------------------------------- if (CMAKE_COMPILER_IS_GNUCXX) exec_program(${CMAKE_C_COMPILER} ARGS "-dumpversion" OUTPUT_VARIABLE _gcc_version_info) - string(REGEX REPLACE "^([0-9]+)\\.[0-9]+\\.[0-9]" "\\1" GCC_MAJOR "${_gcc_version_info}") - string(REGEX REPLACE "^[0-9]+\\.([0-9]+)\\.[0-9]" "\\1" GCC_MINOR "${_gcc_version_info}") - string(REGEX REPLACE "^[0-9]+\\.[0-9]+\\.([0-9])" "\\1" GCC_PATCH "${_gcc_version_info}") + string(REGEX REPLACE "^([0-9]+).*$" "\\1" GCC_MAJOR ${_gcc_version_info}) + string(REGEX REPLACE "^[0-9]+\\.([0-9]+).*$" "\\1" GCC_MINOR ${_gcc_version_info}) + string(REGEX REPLACE "^[0-9]+\\.[0-9]+\\.([0-9]+).*$" "\\1" GCC_PATCH ${_gcc_version_info}) + + if(GCC_PATCH MATCHES "\\.+") + set(GCC_PATCH "") + endif() + if(GCC_MINOR MATCHES "\\.+") + set(GCC_MINOR "") + endif() + if(GCC_MAJOR MATCHES "\\.+") + set(GCC_MAJOR "") + endif() message(STATUS "Found GCC. Major version ${GCC_MAJOR}, minor version ${GCC_MINOR}") set(COMPILER_VERSION gcc${GCC_MAJOR}${GCC_MINOR}${GCC_PATCH}) else() @@ -41,6 +51,16 @@ if(NOT CMAKE_BUILD_TYPE) endif() message(STATUS "CMAKE_BUILD_TYPE: ${CMAKE_BUILD_TYPE}") +#---Check for c++11 option------------------------------------------------------------ +if(c++11) + include(CheckCXXCompilerFlag) + CHECK_CXX_COMPILER_FLAG("-std=c++11" HAS_CXX11) + if(NOT HAS_CXX11) + message(STATUS "Current compiler does not suppport -std=c++11 option. Switching OFF c++11 option") + set(c++11 OFF CACHE BOOL "" FORCE) + endif() +endif() + #---Need to locate thead libraries and options to set properly some compilation flags---------------- find_package(Threads) @@ -53,6 +73,14 @@ elseif(WIN32) include(SetupWindows) endif() +if(c++11) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -Wno-deprecated-declaration") +endif() +if(gnuinstall) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DR__HAVE_CONFIG") +endif() + + #---Print the final compiler flags-------------------------------------------------------------------- message(STATUS "ROOT Platform: ${ROOT_PLATFORM}") message(STATUS "ROOT Architecture: ${ROOT_ARCHITECTURE}") diff --git a/cmake/modules/FindAlien.cmake b/cmake/modules/FindAlien.cmake index 1d79d77475d72..949b0e4bb6a85 100644 --- a/cmake/modules/FindAlien.cmake +++ b/cmake/modules/FindAlien.cmake @@ -12,7 +12,7 @@ if(ALIEN_LIBRARY AND ALIEN_INCLUDE_DIR) endif() find_path(ALIEN_INCLUDE_DIR gapiUI.h - ${ALIEN_DIR}/include + ${ALIEN_DIR}/include $ENV{ALIEN_DIR}/include /usr/local/include /opt/alien/api/include /opt/monalisa/include @@ -21,7 +21,7 @@ find_path(ALIEN_INCLUDE_DIR gapiUI.h ) find_library(ALIEN_LIBRARY NAMES gapiUI PATHS - ${ALIEN_DIR}/lib + ${ALIEN_DIR}/lib $ENV{ALIEN_DIR}/lib /usr/local/lib /opt/alien/api/lib /opt/monalisa/lib diff --git a/cmake/modules/FindCastor.cmake b/cmake/modules/FindCastor.cmake index 8c218f2ecdffc..3cb3ee9d858ff 100644 --- a/cmake/modules/FindCastor.cmake +++ b/cmake/modules/FindCastor.cmake @@ -14,7 +14,7 @@ if(CASTOR_INCLUDE_DIR) endif() find_path(CASTOR_INCLUDE_DIR NAMES rfio_api.h PATHS - $ENV{CASTOR_DIR}/include + $ENV{CASTOR_DIR}/include ${CASTOR_DIR}/include /cern/pro/include /cern/new/include /cern/old/include @@ -31,7 +31,7 @@ if(CASTOR_INCLUDE_DIR) string(REGEX REPLACE "BASEVERSION[ ]*[\"][ ]*([^ \"]+)" "\\1" CASTOR_VERSION ${cont}) endif() -set(locations $ENV{CASTOR_DIR}/lib /cern/pro/lib /cern/new/lib /cern/old/lib +set(locations $ENV{CASTOR_DIR}/lib ${CASTOR_DIR}/lib /cern/pro/lib /cern/new/lib /cern/old/lib /opt/shift/lib /usr/local/shift/lib /usr/lib/shift /usr/local/lib/shift /usr/lib64 /usr/lib /usr/local/lib) diff --git a/cmake/modules/FindDCAP.cmake b/cmake/modules/FindDCAP.cmake new file mode 100644 index 0000000000000..6cb26c6e3f030 --- /dev/null +++ b/cmake/modules/FindDCAP.cmake @@ -0,0 +1,21 @@ +# - Locate dCache library +# Defines: +# +# DCAP_FOUND +# DCAP_INCLUDE_DIR +# DCAP_INCLUDE_DIRS (not cached) +# DCAP_LIBRARIES + +find_path(DCAP_INCLUDE_DIR NAMES dcap.h HINTS ${DCAP_DIR}/include $ENV{DCAP_DIR}/inlcude) +find_library(DCAP_LIBRARY NAMES dcap HINTS ${DCAP_DIR}/lib $ENV{DCAP_DIR}/lib) + +set(DCAP_INCLUDE_DIRS ${DCAP_INCLUDE_DIR}) +set(DCAP_LIBRARIES ${DCAP_LIBRARY}) + + +# handle the QUIETLY and REQUIRED arguments and set DCAP_FOUND to TRUE if +# all listed variables are TRUE +INCLUDE(FindPackageHandleStandardArgs) +FIND_PACKAGE_HANDLE_STANDARD_ARGS(DCAP DEFAULT_MSG DCAP_INCLUDE_DIR DCAP_LIBRARY) + +mark_as_advanced(DCAP_FOUND DCAP_INCLUDE_DIR DCAP_LIBRARY) diff --git a/cmake/modules/FindFTGL.cmake b/cmake/modules/FindFTGL.cmake index 9c9c932021333..eaaaef99034a5 100644 --- a/cmake/modules/FindFTGL.cmake +++ b/cmake/modules/FindFTGL.cmake @@ -1,2 +1,22 @@ -#TODO: create find script for FTGL. in the moment we will use the builtin -# version \ No newline at end of file +# - Locate FTGL library +# Defines: +# +# FTGL_FOUND +# FTGL_INCLUDE_DIR +# FTGL_LIBRARY +# FTGL_INCLUDE_DIRS (not cached) +# FTGL_LIBRARIES (not cached) + +find_path(FTGL_INCLUDE_DIR FTGL/ftgl.h + HINTS $ENV{FTGL_ROOT_DIR}/include ${FTGL_ROOT_DIR}/include) + +find_library(FTGL_LIBRARY NAMES ftgl + HINTS $ENV{FTGL_ROOT_DIR}/lib ${FTGL_ROOT_DIR}/lib) + +set(FTGL_INCLUDE_DIRS ${FTGL_INCLUDE_DIR}) +set(FTGL_LIBRARIES ${FTGL_LIBRARY}) + +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(FTGL DEFAULT_MSG FTGL_INCLUDE_DIR FTGL_LIBRARY) +mark_as_advanced(FTGL_FOUND FTGL_INCLUDE_DIR FTGL_LIBRARY) + diff --git a/cmake/modules/FindGFAL.cmake b/cmake/modules/FindGFAL.cmake new file mode 100644 index 0000000000000..153cf04d35c72 --- /dev/null +++ b/cmake/modules/FindGFAL.cmake @@ -0,0 +1,20 @@ +# - Locate GFAL library +# Defines: +# +# GFAL_FOUND +# GFAL_INCLUDE_DIR +# GFAL_INCLUDE_DIRS (not cached) +# GFAL_LIBRARIES + +find_path(GFAL_INCLUDE_DIR NAMES gfal_api.h HINTS ${GFAL_DIR}/include $ENV{GFAL_DIR}/inlcude) +find_library(GFAL_LIBRARIES NAMES gfal HINTS ${GFAL_DIR}/lib $ENV{GFAL_DIR}/lib) +find_path(SRM_IFCE_INCLUDE_DIR gfal_srm_ifce_types.h HINTS ${SRM_IFCE_DIR}/include $ENV{SRM_IFCE_DIR}/include) + +set(GFAL_INCLUDE_DIRS ${GFAL_INCLUDE_DIR} ${SRM_IFCE_INCLUDE_DIR}) + +# handle the QUIETLY and REQUIRED arguments and set GFAL_FOUND to TRUE if +# all listed variables are TRUE +INCLUDE(FindPackageHandleStandardArgs) +FIND_PACKAGE_HANDLE_STANDARD_ARGS(GFAL DEFAULT_MSG GFAL_INCLUDE_DIR SRM_IFCE_INCLUDE_DIR GFAL_LIBRARIES) + +mark_as_advanced(GFAL_FOUND GFAL_INCLUDE_DIR GFAL_LIBRARIES SRM_IFCE_INCLUDE_DIR) diff --git a/cmake/modules/FindGSL.cmake b/cmake/modules/FindGSL.cmake index 2e8f881f5b06f..c7d51863d549c 100644 --- a/cmake/modules/FindGSL.cmake +++ b/cmake/modules/FindGSL.cmake @@ -25,14 +25,14 @@ if( WIN32 AND NOT CYGWIN AND NOT MSYS ) # look for headers find_path( GSL_INCLUDE_DIR NAMES gsl/gsl_cdf.h gsl/gsl_randist.h - PATHS $ENV{GSL_DIR}/include + PATHS $ENV{GSL_DIR}/include ${GSL_DIR}/include ) if( GSL_INCLUDE_DIR ) # look for gsl library find_library( GSL_LIBRARY NAMES gsl - PATHS $ENV{GSL_DIR}/lib - ) + PATHS $ENV{GSL_DIR}/lib ${GSL_DIR}/lib + ) if( GSL_LIBRARY ) set( GSL_INCLUDE_DIRS ${GSL_INCLUDE_DIR} ) get_filename_component( GSL_LIBRARY_DIRS ${GSL_LIBRARY} PATH ) @@ -41,15 +41,15 @@ if( WIN32 AND NOT CYGWIN AND NOT MSYS ) # look for gsl cblas library find_library( GSL_CBLAS_LIBRARY - NAMES gslcblas - PATHS $ENV{GSL_DIR}/lib + NAMES gslcblas + PATHS $ENV{GSL_DIR}/lib ${GSL_DIR}/lib ) if( GSL_CBLAS_LIBRARY ) set( GSL_CBLAS_FOUND ON ) endif( GSL_CBLAS_LIBRARY ) set( GSL_LIBRARIES ${GSL_LIBRARY} ${GSL_CBLAS_LIBRARY} ) - set( GSL_CFLAGS "-DGSL_DLL") + set( GSL_CFLAGS "-DGSL_DLL") endif( GSL_INCLUDE_DIR ) mark_as_advanced( @@ -60,10 +60,10 @@ if( WIN32 AND NOT CYGWIN AND NOT MSYS ) else( WIN32 AND NOT CYGWIN AND NOT MSYS ) if( UNIX OR MSYS ) find_program( GSL_CONFIG_EXECUTABLE gsl-config - /usr/bin/ - /usr/local/bin $ENV{GSL_DIR}/bin ${GSL_DIR}/bin + /usr/bin/ + /usr/local/bin ) if( GSL_CONFIG_EXECUTABLE ) diff --git a/cmake/modules/FindGlobus.cmake b/cmake/modules/FindGlobus.cmake new file mode 100644 index 0000000000000..d9a768db82e4d --- /dev/null +++ b/cmake/modules/FindGlobus.cmake @@ -0,0 +1,42 @@ +# - Locate Globus libraries +# Defines: +# +# GLOBUS_FOUND +# GLOBUS_INCLUDE_DIR +# GLOBUS_INCLUDE_DIRS (not cached) +# GLOBUS_LIBRARIES (not cached) +# GLOBUS_xxx_LIBRARY + +find_path(GLOBUS_INCLUDE_DIR NAMES globus_common.h + HINTS ${GLOBUS_DIR}/include $ENV{GLOBUS_LOCATION}/include + /opt/globus/include + PATH_SUFFIXES gcc32 gcc32dbg gcc32pthr gcc32dbgpthr + gcc64 gcc64dbg gcc64pthr gcc64dbgpthr globus) + +if(GLOBUS_INCLUDE_DIR) + get_filename_component(flavour ${GLOBUS_INCLUDE_DIR} NAME) +endif() + +set(GLOBUS_INCLUDE_DIRS ${GLOBUS_INCLUDE_DIR}) + +set(libraries gssapi_gsi gss_assist gsi_credential common gsi_callback proxy_ssl + gsi_sysconfig openssl_error oldgaa gsi_cert_utils + openssl gsi_proxy_core callout) + +foreach( lib ${libraries}) + find_library(GLOBUS_${lib}_LIBRARY NAMES globus_${lib}_${flavour} HINTS + ${GLOBUS_DIR}/lib $ENV{GLOBUS_LOCATION}/lib) + if(GLOBUS_${lib}_LIBRARY) + set(GLOBUS_${lib}_FOUND 1) + list(APPEND GLOBUS_LIBRARIES ${GLOBUS_${lib}_LIBRARY}) + mark_as_advanced(GLOBUS_${lib}_LIBRARY) + endif() +endforeach() + + +# handle the QUIETLY and REQUIRED arguments and set GLOBUS_FOUND to TRUE if +# all listed variables are TRUE +INCLUDE(FindPackageHandleStandardArgs) +FIND_PACKAGE_HANDLE_STANDARD_ARGS(GLOBUS DEFAULT_MSG GLOBUS_INCLUDE_DIR GLOBUS_common_LIBRARY) + +mark_as_advanced(GLOBUS_FOUND GLOBUS_INCLUDE_DIR) diff --git a/cmake/modules/FindGraphviz.cmake b/cmake/modules/FindGraphviz.cmake index f8918fc8d2abf..05a1f4fba6749 100644 --- a/cmake/modules/FindGraphviz.cmake +++ b/cmake/modules/FindGraphviz.cmake @@ -10,12 +10,12 @@ if(GRAPHVIZ_INCLUDE_DIR AND GRAPHVIZ_CDT_LIBRARY AND GRAPHVIZ_GRAPH_LIBRARY AND endif() -find_path(GRAPHVIZ_INCLUDE_DIR graphviz/graph.h PATHS $ENV{GRAPHVIZ_DIR}/include) +find_path(GRAPHVIZ_INCLUDE_DIR graphviz/graph.h HINTS $ENV{GRAPHVIZ_DIR}/include ${GRAPHVIZ_DIR}/include) -find_library(GRAPHVIZ_CDT_LIBRARY NAMES cdt PATHS $ENV{GRAPHVIZ_DIR}/lib) -find_library(GRAPHVIZ_GVC_LIBRARY NAMES gvc PATHS $ENV{GRAPHVIZ_DIR}/lib) -find_library(GRAPHVIZ_GRAPH_LIBRARY NAMES graph PATHS $ENV{GRAPHVIZ_DIR}/lib) -find_library(GRAPHVIZ_PATHPLAN_LIBRARY NAMES pathplan PATHS $ENV{GRAPHVIZ_DIR}/lib) +find_library(GRAPHVIZ_CDT_LIBRARY NAMES cdt HINTS $ENV{GRAPHVIZ_DIR}/lib ${GRAPHVIZ_DIR}/lib) +find_library(GRAPHVIZ_GVC_LIBRARY NAMES gvc HINTS $ENV{GRAPHVIZ_DIR}/lib ${GRAPHVIZ_DIR}/lib) +find_library(GRAPHVIZ_GRAPH_LIBRARY NAMES graph HINTS $ENV{GRAPHVIZ_DIR}/lib ${GRAPHVIZ_DIR}/lib) +find_library(GRAPHVIZ_PATHPLAN_LIBRARY NAMES pathplan HINTS $ENV{GRAPHVIZ_DIR}/lib ${GRAPHVIZ_DIR}/lib) if(GRAPHVIZ_INCLUDE_DIR AND GRAPHVIZ_CDT_LIBRARY AND GRAPHVIZ_GVC_LIBRARY AND GRAPHVIZ_GRAPH_LIBRARY AND GRAPHVIZ_PATHPLAN_LIBRARY) set(GRAPHVIZ_FOUND 1) diff --git a/cmake/modules/FindKerberos5.cmake b/cmake/modules/FindKerberos5.cmake index 1912ff9db4612..1611228df0002 100644 --- a/cmake/modules/FindKerberos5.cmake +++ b/cmake/modules/FindKerberos5.cmake @@ -2,66 +2,40 @@ # Check for libkrb5.a # # KRB5_INCLUDE_DIR - where to find krb5.h, etc. -# KRB5_LIBRARIES - List of libraries when using .... +# KRB5_INCLUDE_DIRS (not cached) +# KRB5_LIBRARIES - List of libraries when using Kerberos5 +# KRB5_INIT - kinit command # KRB5_FOUND - True if Kerberos 5 libraries found. -set(KRB5_FOUND FALSE) -set(KBR5_LIBRARIES) - find_path(KRB5_INCLUDE_DIR NAMES krb5.h - /usr/kerberos/include - /usr/krb5/include - /usr/local/kerberos/include - /usr/include - /usr/include/kerberosV - /usr/local/include - $ENV{KRB5_DIR}/include -) + HINTS $ENV{KRB5_DIR} ${KRB5_DIR} + PATH_SUFFIXES include kerberos krb5) + +set(KRB5_INCLUDE_DIRS ${KRB5_INCLUDE_DIR}) + +find_library(KRB5_LIBRARY NAMES krb5 + HINTS $ENV{KRB5_DIR} ${KRB5_DIR} + PATH_SUFFIXES kerberos krb5) +set(KRB5_LIBRARIES ${KRB5_LIBRARY}) find_library(KRB5_MIT_LIBRARY NAMES k5crypto - /usr/kerberos/lib - /usr/krb5/lib - /usr/local/kerberos/lib - /usr/lib64 - /usr/lib - /usr/local/lib - $ENV{KRB5_DIR}/lib -) + HINTS $ENV{KRB5_DIR} ${KRB5_DIR} + PATH_SUFFIXES kerberos krb5) + if(KRB5_MIT_LIBRARY) set(KRB5_LIBRARIES ${KRB5_LIBRARIES} ${KRB5_MIT_LIBRARY}) endif() - -find_library(KRB5_LIBRARY NAMES krb5 - /usr/kerberos/lib - /usr/krb5/lib - /usr/local/kerberos/lib - /usr/lib64 - /usr/lib - /usr/local/lib - $ENV{KRB5_DIR}/lib -) -if(KRB5_LIBRARY) - set(KRB5_LIBRARIES ${KRB5_LIBRARIES} ${KRB5_LIBRARY}) -endif() + find_program(KRB5_INIT NAMES kinit - /usr/kerberos/bin - /usr/krb5/bin - /usr/local/kerberos/bin - /usr/bin - /usr/local/bin - $ENV{KRB5_DIR}/bin -) + HINTS $ENV{KRB5_DIR}/bin ${KRB5_DIR}/bin + PATH_SUFFIXES kerberos krb5) -if(KRB5_INCLUDE_DIR AND KRB5_LIBRARIES) - set(KRB5_FOUND TRUE) -endif() +include(FindPackageHandleStandardArgs) + +find_package_handle_standard_args( KRB5 DEFAULT_MSG KRB5_LIBRARY KRB5_INCLUDE_DIR ) + +mark_as_advanced( KRB5_INCLUDE_DIR KRB5_MIT_LIBRARY KRB5_LIBRARY KRB5_INIT) -mark_as_advanced( - KRB5_INCLUDE_DIR - KRB5_MIT_LIBRARY - KRB5_LIBRARY - KRB5_INIT -) diff --git a/cmake/modules/FindLdap.cmake b/cmake/modules/FindLdap.cmake new file mode 100644 index 0000000000000..33f610696b8c9 --- /dev/null +++ b/cmake/modules/FindLdap.cmake @@ -0,0 +1,24 @@ +# - Try to find the LDAP client libraries +# Once done this will define +# +# LDAP_FOUND - system has libldap +# LDAP_INCLUDE_DIR - the ldap include directory +# LDAP_LIBRARY libldap library +# LBER_LIBRARY liblber library +# LDAP_LIBRARIES - libldap + liblber (if found) library + + +find_path(LDAP_INCLUDE_DIR NAMES ldap.h HINTS ${LDAP_DIR}/include $ENV{LDAP_DIR}/include) +find_library(LDAP_LIBRARY NAMES ldap HINTS ${LDAP_DIR}/lib $ENV{LDAP_DIR}/lib) +find_library(LBER_LIBRARY NAMES lber HINTS ${LDAP_DIR}/lib $ENV{LDAP_DIR}/lib) + +set(LDAP_INCLUDE_DIRS ${LDAP_INCLUDE_DIR}) +set(LDAP_LIBRARIES ${LDAP_LIBRARY} ${LBER_LIBRARY}) + +# handle the QUIETLY and REQUIRED arguments and set LDAP_FOUND to TRUE if +# all listed variables are TRUE +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(LDAP DEFAULT_MSG LDAP_INCLUDE_DIR LDAP_LIBRARY) + +mark_as_advanced(LDAP_FOUND LDAP_INCLUDE_DIR LDAP_LIBRARY LBER_LIBRARY) + diff --git a/cmake/modules/FindMySQL.cmake b/cmake/modules/FindMySQL.cmake index 03846bb735911..65f4e131faae9 100644 --- a/cmake/modules/FindMySQL.cmake +++ b/cmake/modules/FindMySQL.cmake @@ -13,7 +13,7 @@ if(NOT WIN32) find_program(MYSQL_CONFIG_EXECUTABLE mysql_config /usr/bin/ /usr/local/bin - $ENV{MYSQL_DIR}/bin + ${MYSQL_DIR}/bin $ENV{MYSQL_DIR}/bin ) endif() @@ -22,6 +22,9 @@ if(MYSQL_CONFIG_EXECUTABLE) separate_arguments(MYSQL_CFLAGS) string( REGEX MATCH "-I[^;]+" MYSQL_INCLUDE_DIR "${MYSQL_CFLAGS}" ) string( REPLACE "-I" "" MYSQL_INCLUDE_DIR "${MYSQL_INCLUDE_DIR}") + if(NOT EXISTS ${MYSQL_INCLUDE_DIR}) + set(MYSQL_INCLUDE_DIR MYSQL_INCLUDE_DIR-NOTFOUND) + endif() string( REGEX REPLACE "-I[^;]+;" "" MYSQL_CFLAGS "${MYSQL_CFLAGS}" ) execute_process(COMMAND ${MYSQL_CONFIG_EXECUTABLE} --libs OUTPUT_VARIABLE MYSQL_LIBRARIES OUTPUT_STRIP_TRAILING_WHITESPACE) else() @@ -41,28 +44,10 @@ else() set(MYSQL_LIBRARIES ${MYSQL_LIBRARY}) endif() -if(MYSQL_INCLUDE_DIR AND MYSQL_LIBRARIES) - set(MYSQL_FOUND TRUE) - if(WIN32) - string(REPLACE mysqlclient libmysql libmysql ${MYSQL_LIBRARY}) - set(MYSQL_LIBRARIES ${libmysql} ${MYSQL_LIBRARIES}) - endif() -else() - set(MYSQL_FOUND FALSE) - set(MYSQL_LIBRARIES ) -endif() - -if(MYSQL_FOUND) - if(NOT MYSQL_FIND_QUIETLY) - message(STATUS "Found MySQL libraries: ${MYSQL_LIBRARIES}") - message(STATUS "Found MySQL includes: ${MYSQL_INCLUDE_DIR}") - endif() -else() - if(MYSQL_FIND_REQUIRED) - message(STATUS "Looked for MySQL libraries named ${MYSQL_NAMES}.") - message(FATAL_ERROR "Could NOT find MySQL library") - endif() -endif() +# handle the QUIETLY and REQUIRED arguments and set DCAP_FOUND to TRUE if +# all listed variables are TRUE +INCLUDE(FindPackageHandleStandardArgs) +find_package_handle_standard_args(MYSQL DEFAULT_MSG MYSQL_INCLUDE_DIR MYSQL_LIBRARIES) mark_as_advanced( MYSQL_CONFIG_EXECUTABLE diff --git a/cmake/modules/FindODBC.cmake b/cmake/modules/FindODBC.cmake index 296702f4450c4..d857abc44119b 100644 --- a/cmake/modules/FindODBC.cmake +++ b/cmake/modules/FindODBC.cmake @@ -32,7 +32,7 @@ else() DOC "Specify the directory containing sql.h." ) - find_library( ODBC_LIBRARY NAMES libiodbc libodbc odbc32 + find_library( ODBC_LIBRARY NAMES iodbc odbc odbc32 PATHS /usr/lib /usr/lib/odbc diff --git a/cmake/modules/FindOracle.cmake b/cmake/modules/FindOracle.cmake index fbeae90a05ee7..4c3ab4c392841 100644 --- a/cmake/modules/FindOracle.cmake +++ b/cmake/modules/FindOracle.cmake @@ -75,6 +75,8 @@ IF (NOT DEFINED ORACLE_OCI_VERSION) ${ORACLE_HOME}/bin ) IF(SQLPLUS_EXECUTABLE) + get_filename_component(bindir ${SQLPLUS_EXECUTABLE} PATH) # sqlplus executable needs its shared libraries + set(ENV{LD_LIBRARY_PATH} ${bindir}/../lib:$ENV{LD_LIBRARY_PATH}) EXECUTE_PROCESS(COMMAND ${SQLPLUS_EXECUTABLE} -version OUTPUT_VARIABLE sqlplus_out) STRING(REGEX MATCH "([0-9.]+)" sqlplus_version ${sqlplus_out}) MESSAGE(STATUS "Found sqlplus version: ${sqlplus_version}") diff --git a/cmake/modules/FindPCRE.cmake b/cmake/modules/FindPCRE.cmake index f3cb6415956e5..e7a65a6022d0f 100644 --- a/cmake/modules/FindPCRE.cmake +++ b/cmake/modules/FindPCRE.cmake @@ -15,9 +15,9 @@ find_program(PCRE_CONFIG_EXECUTABLE pcre-config) if(PCRE_CONFIG_EXECUTABLE) execute_process(COMMAND ${PCRE_CONFIG_EXECUTABLE} --version OUTPUT_VARIABLE PCRE_VERSION OUTPUT_STRIP_TRAILING_WHITESPACE) - execute_process(COMMAND ${PCRE_CONFIG_EXECUTABLE} --cflags OUTPUT_VARIABLE PCRE_CFLAGS) + execute_process(COMMAND ${PCRE_CONFIG_EXECUTABLE} --cflags OUTPUT_VARIABLE PCRE_CFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE) string( REGEX MATCHALL "-I[^;]+" PCRE_INCLUDE_DIR "${PCRE_CFLAGS}" ) - string( REPLACE "-I" "" PCRE_INCLUDE_DIR "${PCRE_INCLUDE_DIRS}") + string( REPLACE "-I" "" PCRE_INCLUDE_DIR "${PCRE_INCLUDE_DIR}") if(NOT PCRE_INCLUDE_DIR) execute_process(COMMAND ${PCRE_CONFIG_EXECUTABLE} --prefix OUTPUT_VARIABLE PCRE_PREFIX OUTPUT_STRIP_TRAILING_WHITESPACE) set(PCRE_INCLUDE_DIR ${PCRE_PREFIX}/include) diff --git a/cmake/modules/FindPythia6.cmake b/cmake/modules/FindPythia6.cmake index 7707e523a140b..8c0bcabf98897 100644 --- a/cmake/modules/FindPythia6.cmake +++ b/cmake/modules/FindPythia6.cmake @@ -1,16 +1,15 @@ -# Find the Pythia6 includes and library. -# -# This module defines -# PYTHIA6_LIBRARIES, the libraries to link against to use Pythia6 -# PYTHIA6_FOUND. If false, you cannot build anything that requires Pythia6. -# PYTHIA6_LIBRARY, where to find the libPythia6 library. +# - Locate pythia6 library +# Defines: +# +# PYTHIA6_FOUND +# PYTHIA6_INCLUDE_DIR +# PYTHIA6_INCLUDE_DIRS (not cached) +# PYTHIA6_LIBRARY +# PYTHIA6_LIBRARY_DIR (not cached) +# PYTHIA6_LIBRARIES (not cached) -set(PYTHIA6_FOUND 0) - - -find_library(PYTHIA6_LIBRARY NAMES pythia6 libPythia6 PATHS - $ENV{PYTHIA6_DIR}/lib - /cern/pro/lib +set(CMAKE_LIBRARY_PATH + /cern/pro/lib /opt/pythia /opt/pythia6 /usr/lib/pythia @@ -18,16 +17,19 @@ find_library(PYTHIA6_LIBRARY NAMES pythia6 libPythia6 PATHS /usr/lib/pythia6 /usr/local/lib/pythia6 /usr/lib - /usr/local/lib - DOC "Specify the Pythia6 library here." -) + /usr/local/lib) -if(PYTHIA6_LIBRARY) - message(STATUS "Found Pythia6 library at ${PYTHIA6_LIBRARY}") - set(PYTHIA6_FOUND 1 ) -endif() +find_library(PYTHIA6_LIBRARY NAMES pythia6 Pythia6 + HINTS $ENV{PYTHIA6_DIR}/lib ${PYTHIA6_DIR}/lib) set(PYTHIA6_LIBRARIES ${PYTHIA6_LIBRARY}) +get_filename_component(PYTHIA6_LIBRARY_DIR ${PYTHIA6_LIBRARY} PATH) + +# handle the QUIETLY and REQUIRED arguments and set PHOTOS_FOUND to TRUE if +# all listed variables are TRUE + +INCLUDE(FindPackageHandleStandardArgs) +FIND_PACKAGE_HANDLE_STANDARD_ARGS(Pythia6 DEFAULT_MSG PYTHIA6_LIBRARY) -MARK_AS_ADVANCED( PYTHIA6_FOUND PYTHIA6_LIBRARY) +mark_as_advanced(PYTHIA6_FOUND PYTHIA6_LIBRARY) diff --git a/cmake/modules/FindPythia8.cmake b/cmake/modules/FindPythia8.cmake index 9fd8562ace820..1a464cc23cc1f 100644 --- a/cmake/modules/FindPythia8.cmake +++ b/cmake/modules/FindPythia8.cmake @@ -17,7 +17,7 @@ find_path(PYTHIA8_INCLUDE_DIR Pythia.h DOC "Specify the directory containing Pythia.h." ) -find_library(PYTHIA8_LIBRARY NAMES libPythia8 PATHS +find_library(PYTHIA8_LIBRARY NAMES Pythia8 pythia8 PATHS $ENV{PYTHIA8_DIR}/lib /opt/pythia8/lib /usr/local/lib diff --git a/cmake/modules/FindROOTInternal.cmake b/cmake/modules/FindROOTInternal.cmake deleted file mode 100644 index 30b799507900e..0000000000000 --- a/cmake/modules/FindROOTInternal.cmake +++ /dev/null @@ -1,296 +0,0 @@ -macro(check_value_ok _value) - # check _value (TRUE, ENABLE, 1 -> TRUE) - # (FALSE, DISABLE, 0 -> FALSE) - set (true_allowed TRUE ENABLE 1) - set (false_allowed FALSE DISABLE 0) - string(TOUPPER ${_value} _value_upper) - set (true_value FALSE) - set (false_value FALSE) - foreach(_true ${true_allowed}) - if (${_value_upper} MATCHES ${_true}) - set(true_value TRUE) - endif (${_value_upper} MATCHES ${_true}) - endforeach(_true ${true_allowed}) - foreach(_false ${false_allowed}) - if (${_value_upper} MATCHES ${_false}) - set(false_value TRUE) - endif (${_value_upper} MATCHES ${_false}) - endforeach(_false ${false_allowed}) - if (true_value OR false_value) - if (true_value AND false_value) - MESSAGE(FATAL_ERROR "check_value_ok: Value for option is true and false. This can never happen. If this error message is plotted something is wrong with the logic of the macro.") - endif(true_value AND false_value) - else (true_value OR false_value) - MESSAGE("check_value_ok: This value for options is not known.") - MESSAGE("check_value_ok: Allowed value for TRUE are TRUE, Enable or 1") - MESSAGE(FATAL_ERROR "check_value_ok: Allowed value for FALSE are FALSE, Disable or 0") - endif (true_value OR false_value) -endmacro(check_value_ok _value) - -macro(show_root_install_options) - foreach(_actual_option ${ROOT_INSTALL_OPTIONS}) - list(FIND ROOT_INSTALL_OPTIONS ${_actual_option} position) - list(GET ROOT_INSTALL_OPTIONS ${position} __option) - list(GET ROOT_INSTALL_OPTIONS_VALUE ${position} __value) - MESSAGE("${__option}": ${__value}) - endforeach(_actual_option ${ROOT_INSTALL_OPTIONS}) -endmacro(show_root_install_options) - -macro(is_root_install_option_enabled _option) - list(FIND ROOT_INSTALL_OPTIONS ${_option} position) - list(GET ROOT_INSTALL_OPTIONS_VALUE ${position} __value) - if(__value) - set (BLA option_${_option}_is_enabled) - set(${BLA} TRUE) - else(__value) - set (BLA option_${_option}_is_enabled) - set(${BLA} FALSE) - endif(__value) -endmacro(is_root_install_option_enabled _option) - -macro(get_enabled_root_install_options) - set(installed_options_list) - foreach(_actual_option ${ROOT_INSTALL_OPTIONS}) - list(FIND ROOT_INSTALL_OPTIONS ${_actual_option} position) - list(GET ROOT_INSTALL_OPTIONS ${position} __option) - list(GET ROOT_INSTALL_OPTIONS_VALUE ${position} __value) - if(${__value} MATCHES TRUE) - set(installed_options_list "${installed_options_list} ${__option}") - endif(${__value} MATCHES TRUE) - endforeach(_actual_option ${ROOT_INSTALL_OPTIONS}) - -endmacro(get_enabled_root_install_options) - - -macro(CHANGE_ROOT_INSTALL_OPTIONS _option _value) - # get position of option from array ROOT_INSTAL_OPTIONS - list(FIND ROOT_INSTALL_OPTIONS ${_option} position) - if (position EQUAL -1) - MESSAGE(FATAL_ERROR "CHANGE_ROOT_INSTALL_OPTIONS: The option ${_option} is not known. \n Possible options are ${ROOT_INSTALL_OPTIONS}") - endif (position EQUAL -1) - - #check if the value to be set is okay - check_value_ok(${_value}) - - #Now set the value _value for option _option - if (true_value) - list(INSERT ROOT_INSTALL_OPTIONS_VALUE ${position} TRUE) - math(EXPR rel_pos ${position}+1) - list(REMOVE_AT ROOT_INSTALL_OPTIONS_VALUE ${rel_pos}) - endif (true_value) - if (false_value) - list(INSERT ROOT_INSTALL_OPTIONS_VALUE ${position} FALSE) - math(EXPR rel_pos ${position}+1) - list(REMOVE_AT ROOT_INSTALL_OPTIONS_VALUE ${rel_pos}) - endif (false_value) - - #check if after the operation the length of ROOT_INSTALL_OPTIONS and ROOT_INSTALL_OPTIONS_VALUE - #is still the same - list(LENGTH ROOT_INSTALL_OPTIONS_VALUE length_value) - list(LENGTH ROOT_INSTALL_OPTIONS length_options) - if(NOT ${length_value} EQUAL ${length_options}) - MESSAGE(FATAL_ERROR "CHANGE_ROOT_INSTALL_OPTIONS: After changing the option the length of both arrays is different (${length_value} NEQ ${length_options}). Something is wrong with this operation") - endif(NOT ${length_value} EQUAL ${length_options}) - -endmacro(CHANGE_ROOT_INSTALL_OPTIONS _option _value) - - -# define all packages to be build. By default all of them are enabled at start. -# We switch them off later on during the process of configuration. - -set (ROOT_INSTALL_OPTIONS - afs - alien - asimage - astiff - builtin_afterimage - builtin_ftgl - builtin_freetype - builtin_pcre - builtin_zlib - castor - chirp - cint7 - cintex - clarens - dcache - exceptions - explicitlink - fftw3 - gdml - gfal - g4root - glite - globus - gsl_shared - krb5 - ldap - genvector - mathmore - memstat - monalisa - mysql - odbc - opengl - oracle - pch - peac - pgsql - pythia6 - pythia8 - python - qt - qtgsi - reflex - roofit - minuit2 - ruby - rfio - rpath - sapdb - shadowpw - shared - soversion - srp - ssl - table - unuran - winrtdebug - xft - xml - xrootd -) - -set (ROOT_INSTALL_OPTIONS_VALUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE - TRUE -) - -CHANGE_ROOT_INSTALL_OPTIONS("afs" "enable") -CHANGE_ROOT_INSTALL_OPTIONS("afs" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("cint7" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("gdml" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("globus" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("explicitlink" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("pch" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("qt" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("qtgsi" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("roofit" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("minuit2" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("rpath" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("ruby" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("shadowpw" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("soversion" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("table" "disable") -list(APPEND ROOT_INSTALL_OPTIONS "thread") -list(APPEND ROOT_INSTALL_OPTIONS_VALUE "TRUE") -CHANGE_ROOT_INSTALL_OPTIONS("unuran" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("winrtdebug" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("xrootd" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("winrtdebug" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("builtin_freetype" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("builtin_ftgl" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("builtin_pcre" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("builtin_zlib" "disable") -CHANGE_ROOT_INSTALL_OPTIONS("mathmore" "disable") - -#show_root_install_options() - -#set all directories where to install parts of root -#up to now everything is installed according to the setting of -#CMAKE_INSTALL_DIR -#TODO: Make installation layout more flexible - -if(ROOT_INSTALL_DIR) - set(CMAKE_INSTALL_PREFIX ${ROOT_INSTALL_DIR}) - add_definitions(-DR__HAVE_CONFIG) -else(ROOT_INSTALL_DIR) - set(CMAKE_INSTALL_PREFIX ${ROOTSYS}) -endif(ROOT_INSTALL_DIR) - -set(ROOT_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}") -set(BIN_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/bin") -set(LIB_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/lib") -set(INCLUDE_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/include") -set(ETC_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/etc") -set(DATA_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}") -set(DOC_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}") -set(MACRO_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/macros") -set(SRC_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/src") -set(ICON_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/icons") -set(FONT_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/fonts") -set(CINT_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/cint") - -# use, i.e. don't skip the full RPATH for the build tree -SET(CMAKE_SKIP_BUILD_RPATH FALSE) - -# when building, don't use the install RPATH already -# (but later on when installing) -SET(CMAKE_BUILD_WITH_INSTALL_RPATH FALSE) - -# the RPATH to be used when installing -SET(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/lib") -#MESSAGE("RPATH: ${CMAKE_INSTALL_RPATH}") - -# add the automatically determined parts of the RPATH -# which point to directories outside the build tree to the install RPATH -SET(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) - diff --git a/cmake/modules/FindSqlite.cmake b/cmake/modules/FindSqlite.cmake new file mode 100644 index 0000000000000..c4f2e90a6749b --- /dev/null +++ b/cmake/modules/FindSqlite.cmake @@ -0,0 +1,50 @@ +# - Try to find Sqlite +# Once done this will define +# +# SQLITE_FOUND - system has Sqlite +# SQLITE_INCLUDE_DIR - the Sqlite include directory +# SQLITE_LIBRARIES - Link these to use Sqlite +# SQLITE_DEFINITIONS - Compiler switches required for using Sqlite +# Redistribution and use is allowed according to the terms of the BSD license. +# For details see the accompanying COPYING-CMAKE-SCRIPTS file. +# + + +# Copyright (c) 2008, Gilles Caulier, +# +# Redistribution and use is allowed according to the terms of the BSD license. +# For details see the accompanying COPYING-CMAKE-SCRIPTS file. + +if ( SQLITE_INCLUDE_DIR AND SQLITE_LIBRARIES ) + # in cache already + SET(Sqlite_FIND_QUIETLY TRUE) +endif ( SQLITE_INCLUDE_DIR AND SQLITE_LIBRARIES ) + +# use pkg-config to get the directories and then use these values +# in the FIND_PATH() and FIND_LIBRARY() calls +if( NOT WIN32 ) + find_package(PkgConfig) + + pkg_check_modules(PC_SQLITE QUIET sqlite3) + + set(SQLITE_DEFINITIONS ${PC_SQLITE_CFLAGS_OTHER}) +endif( NOT WIN32 ) + +find_path(SQLITE_INCLUDE_DIR NAMES sqlite3.h + PATHS + ${PC_SQLITE_INCLUDEDIR} + ${PC_SQLITE_INCLUDE_DIRS} +) + +find_library(SQLITE_LIBRARIES NAMES sqlite3 + PATHS + ${PC_SQLITE_LIBDIR} + ${PC_SQLITE_LIBRARY_DIRS} +) + +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(Sqlite DEFAULT_MSG SQLITE_INCLUDE_DIR SQLITE_LIBRARIES ) + +# show the SQLITE_INCLUDE_DIR and SQLITE_LIBRARIES variables only in the advanced view +mark_as_advanced(SQLITE_INCLUDE_DIR SQLITE_LIBRARIES ) + diff --git a/cmake/modules/FindXROOTD.cmake b/cmake/modules/FindXROOTD.cmake index 5c00247997916..b58c7eeaba8d1 100644 --- a/cmake/modules/FindXROOTD.cmake +++ b/cmake/modules/FindXROOTD.cmake @@ -4,6 +4,7 @@ # # XROOTD_FOUND - system has XROOTD # XROOTD_INCLUDE_DIR - the XROOTD include directory +# XROOTD_INCLUDE_DIRS - with additonal include directories (non cached) # XROOTD_LIBRARIES - The libraries needed to use XROOTD # XROOTD_CFLAGS - Additional compilation flags (defines) # XROOTD_OLDPACK - old-style packaging for XROOTD libraries @@ -13,105 +14,53 @@ if(XROOTD_XrdClient_LIBRARY AND XROOTD_INCLUDE_DIR) set(XROOTD_FIND_QUIETLY TRUE) endif() -find_path(XROOTD_INCLUDE_DIR - NAMES - XrdVersion.hh - PATHS - $ENV{XRDSYS}/include/xrootd - $ENV{XRDSYS}/include - /opt/xrootd/include/xrootd - /opt/xrootd/include - /usr/local/include/xrootd - /usr/local/include - /usr/include/xrootd - /usr/include +set(searchpath ${XROOTD_ROOT_DIR} $ENV{XRDSYS} /opt/xrootd) + +find_path(XROOTD_INCLUDE_DIR NAMES XrdVersion.hh + HINTS ${searchpath} + PATH_SUFFIXES include include/xrootd ) if (XROOTD_INCLUDE_DIR) - file(STRINGS ${XROOTD_INCLUDE_DIR}/XrdVersion.hh xrdvers REGEX "^#define XrdVERSION") + file(STRINGS ${XROOTD_INCLUDE_DIR}/XrdVersion.hh xrdvers REGEX "^#define XrdVERSION ") string(REGEX REPLACE "#define[ ]+XrdVERSION[ ]+" "" xrdvers ${xrdvers}) string(REGEX REPLACE "[^v\\.]+" "" xrdversdots ${xrdvers}) if (${xrdversdots} STREQUAL "v..") # Regular version string; parse it out string(REGEX MATCH "[0-9\\.]+" xrdvers ${xrdvers}) - string(REGEX MATCH "[0-9]" xrdversmajor ${xrdvers}) - string(REPLACE "${xrdversmajor}." "" xrdversminor ${xrdvers}) - string(REGEX MATCH "[0-9]" xrdversminor ${xrdversminor}) - string(REPLACE "${xrdversmajor}.${xrdversminor}." "" xrdverspatch ${xrdvers}) - string(REGEX MATCH "[0-9]+" xrdverspatch ${xrdverspatch}) + string(REGEX REPLACE "^([^.]*)\\.(.*)\\.(.*)" "\\1" xrdversmajor ${xrdvers}) + string(REGEX REPLACE "^([^.]*)\\.(.*)\\.(.*)" "\\2" xrdversminor ${xrdvers}) + string(REGEX REPLACE "^([^.]*)\\.(.*)\\.(.*)" "\\3" xrdverspatch ${xrdvers}) math(EXPR xrdversnum ${xrdversmajor}*100000000+${xrdversminor}*10000+${xrdverspatch}) else () # Old version string: we keep only the first numerics, i.e. the date string(REGEX REPLACE "[v\"]" "" xrdvers ${xrdvers}) - message(STATUS "Found Xrootd version ${xrdvers}") - string(REGEX REPLACE "[^0-9-]+" " " xrdvers ${xrdvers}) string(SUBSTRING ${xrdvers} 0 8 xrdversnum) endif () - # This we used as a compiler macro variable + if ( ${xrdversnum} EQUAL 300030000 ) + SET(XROOTD_FOUND FALSE) + message(WARNING " >>> Cannot build with XRootD version 3.3.0: please install >=3.3.1 or <= 3.2.x") + else() + SET(XROOTD_FOUND TRUE) + endif () +endif() + +if(XROOTD_FOUND) + # Set include dirs and compiler macro variable + if(NOT XROOTD_FIND_QUIETLY ) - message(STATUS "Found Xrootd version num: ${xrdvers}") + message(STATUS "Found Xrootd version num: ${xrdvers} (setting -DROOTXRDVERS=${xrdversnum})") endif() - SET(XROOTD_CFLAGS "-DROOTXRDVERS=${xrdversnum}") + set(XROOTD_CFLAGS "-DROOTXRDVERS=${xrdversnum}") - if ( ${xrdversnum} LESS 300010000 ) - SET(XROOTD_OLDPACK TRUE) + if ( ${xrdversnum} LESS 300010000 AND ${xrdversnum} LESS 20111022) + set(XROOTD_OLDPACK TRUE) + set(XROOTD_INCLUDE_DIRS ${XROOTD_ROOT_DIR}) message(STATUS "Setting OLDPACK TRUE") else() - SET(XROOTD_OLDPACK FALSE) + set(XROOTD_OLDPACK FALSE) + set(XROOTD_INCLUDE_DIRS ${XROOTD_INCLUDE_DIR} ${XROOTD_INCLUDE_DIR}/private) endif() - - # Check for additional headers - if ( ${xrdversnum} LESS 20070723 ) - # Check for additional headers in old directories - find_path(XROOTD_INCLUDE_DIR - NAMES - XrdNet/XrdNetDNS.hh - XrdOuc/XrdOucError.hh - XrdOuc/XrdOucLogger.hh - XrdOuc/XrdOucPlugin.hh - XrdOuc/XrdOucPthread.hh - XrdOuc/XrdOucSemWait.hh - XrdOuc/XrdOucTimer.hh - ${XROOTD_INCLUDE_DIR} - ) - else() - if ( ${xrdversnum} LESS 300010000 ) - # DNS stuff was under XrdNet - find_path(XROOTD_INCLUDE_DIR - NAMES - XrdNet/XrdNetDNS.hh - ${XROOTD_INCLUDE_DIR} - ) - else () - # DNS stuff is under XrdSys - find_path(XROOTD_INCLUDE_DIR - NAMES - XrdSys/XrdSysDNS.hh - ${XROOTD_INCLUDE_DIR} - ) - endif () - - if (XROOTD_INCLUDE_DIR) - # Check for additional headers in new directories - find_path(XROOTD_INCLUDE_DIR - NAMES - XrdSys/XrdSysError.hh - XrdSys/XrdSysLogger.hh - XrdSys/XrdSysPlugin.hh - XrdSys/XrdSysPthread.hh - XrdSys/XrdSysSemWait.hh - XrdSys/XrdSysTimer.hh - ${XROOTD_INCLUDE_DIR} - ) - endif() - endif() - if (XROOTD_INCLUDE_DIR) - SET(XROOTD_FOUND TRUE) - else () - SET(XROOTD_FOUND FALSE) - endif () -else() - SET(XROOTD_FOUND FALSE) endif() if(XROOTD_FOUND) @@ -121,30 +70,24 @@ if(XROOTD_FOUND) foreach(l XrdNet XrdOuc XrdSys XrdClient Xrd) find_library(XROOTD_${l}_LIBRARY NAMES ${l} - PATHS $ENV{XRDSYS}/lib - /opt/xrootd/lib - /usr/local/lib - /usr/lib) + HINTS ${searchpath} + PATH_SUFFIXES lib) list(APPEND XROOTD_LIBRARIES ${XROOTD_${l}_LIBRARY}) endforeach() if(${xrdversnum} GREATER 20100729) find_library(XROOTD_XrdNetUtil_LIBRARY NAMES XrdNetUtil - PATHS $ENV{XRDSYS}/lib - /opt/xrootd/lib - /usr/local/lib - /usr/lib) + HINTS ${searchpath} + PATH_SUFFIXES lib) list(APPEND XROOTD_LIBRARIES ${XROOTD_XrdNetUtil_LIBRARY}) endif () else() foreach(l XrdMain XrdUtils XrdClient) find_library(XROOTD_${l}_LIBRARY - NAMES ${l} - PATHS $ENV{XRDSYS}/lib - /opt/xrootd/lib - /usr/local/lib - /usr/lib) + NAMES ${l} + HINTS ${searchpath} + PATH_SUFFIXES lib) list(APPEND XROOTD_LIBRARIES ${XROOTD_${l}_LIBRARY}) endforeach() endif() @@ -152,7 +95,7 @@ if(XROOTD_FOUND) if(XROOTD_LIBRARIES) set(XROOTD_FOUND TRUE) if(NOT XROOTD_FIND_QUIETLY ) - message(STATUS " include_dir: ${XROOTD_INCLUDE_DIR}") + message(STATUS " include_dirs: ${XROOTD_INCLUDE_DIRS}") message(STATUS " libraries: ${XROOTD_LIBRARIES}") endif() else () @@ -160,7 +103,7 @@ if(XROOTD_FOUND) endif () endif() -mark_as_advanced(XROOTD_INCLUDE_DIR +mark_as_advanced(XROOTD_INCLUDE_DIR XROOTD_XrdMain_LIBRARY XROOTD_XrdUtils_LIBRARY XROOTD_XrdClient_LIBRARY diff --git a/cmake/modules/PostInstalledSoftware.cmake b/cmake/modules/PostInstalledSoftware.cmake index a2a5dbd573c53..bf551808946eb 100644 --- a/cmake/modules/PostInstalledSoftware.cmake +++ b/cmake/modules/PostInstalledSoftware.cmake @@ -4,10 +4,7 @@ if(builtin_gsl) add_dependencies(MathMore GSL) endif() ExternalProject_Get_Property(GSL install_dir) - install(DIRECTORY ${install_dir}/lib/ DESTINATION lib FILES_MATCHING PATTERN "libgsl*") - #install(FILES ${install_dir}/lib/libgslcblas.so - # ${install_dir}/lib/libgsl.so - # DESTINATION lib) + install(DIRECTORY ${install_dir}/lib/ DESTINATION ${CMAKE_INSTALL_LIBDIR} FILES_MATCHING PATTERN "libgsl*") endif() #---Post actions to use builtin CFITSIO------------------------------------------------ @@ -15,6 +12,4 @@ if(builtin_cfitsio) if(TARGET FITSIO) add_dependencies(FITSIO CFITSIO) endif() - #install(FILES ${install_dir}/lib/libcfitsio.so - # DESTINATION lib) endif() diff --git a/cmake/modules/RootBuildOptions.cmake b/cmake/modules/RootBuildOptions.cmake index c5348a7fa8f7c..89f09e17d4983 100644 --- a/cmake/modules/RootBuildOptions.cmake +++ b/cmake/modules/RootBuildOptions.cmake @@ -49,84 +49,99 @@ if(WIN32) set(x11_defvalue OFF) set(memstat_defvalue OFF) set(explicitlink_defvalue ON) + set(davix_defvalue OFF) +elseif(MACOSX) + set(x11_defvalue ON) + set(memstat_defvalue ON) + set(explicitlink_defvalue ON) + set(davix_defvalue OFF) else() set(x11_defvalue ON) set(memstat_defvalue ON) set(explicitlink_defvalue ON) + set(davix_defvalue ON) endif() -ROOT_BUILD_OPTION(afs OFF "AFS support, requires AFS libs and objects") -ROOT_BUILD_OPTION(alien ON "AliEn support, requires libgapiUI from ALICE") -ROOT_BUILD_OPTION(asimage ON "Image processing support, requires libAfterImage") +ROOT_BUILD_OPTION(afdsmgrd OFF "Dataset manager for PROOF-based analysis facilities") +ROOT_BUILD_OPTION(afs OFF "AFS support, requires AFS libs and objects") +ROOT_BUILD_OPTION(alien ON "AliEn support, requires libgapiUI from ALICE") +ROOT_BUILD_OPTION(asimage ON "Image processing support, requires libAfterImage") ROOT_BUILD_OPTION(astiff ON "Include tiff support in image processing") -ROOT_BUILD_OPTION(bonjour ON "Bonjour support, requires libdns_sd and/or Avahi") -ROOT_BUILD_OPTION(builtin_afterimage OFF "Built included libAfterImage, or use system libAfterImage") -ROOT_BUILD_OPTION(builtin_ftgl ON "Built included libFTGL, or use system libftgl") -ROOT_BUILD_OPTION(builtin_freetype OFF "Built included libfreetype, or use system libfreetype") +ROOT_BUILD_OPTION(bonjour ON "Bonjour support, requires libdns_sd and/or Avahi") +ROOT_BUILD_OPTION(builtin_afterimage ON "Built included libAfterImage, or use system libAfterImage") +ROOT_BUILD_OPTION(builtin_ftgl ON "Built included libFTGL, or use system libftgl") +ROOT_BUILD_OPTION(builtin_freetype OFF "Built included libfreetype, or use system libfreetype") ROOT_BUILD_OPTION(builtin_glew ON "Built included libGLEW, or use system libGLEW") -ROOT_BUILD_OPTION(builtin_pcre OFF "Built included libpcre, or use system libpcre") -ROOT_BUILD_OPTION(builtin_zlib OFF "Built included libz, or use system libz") -ROOT_BUILD_OPTION(builtin_lzma OFF "Built included liblzma, or use system liblzma") -ROOT_BUILD_OPTION(builtin_gsl OFF "Built the GSL library internally (downloading tarfile from the Web)") -ROOT_BUILD_OPTION(builtin_cfitsio OFF "Built the FITSIO library internally (downloading tarfile from the Web)") -ROOT_BUILD_OPTION(builtin_xrootd OFF "Built the XROOTD internally (downloading tarfile from the Web)") -ROOT_BUILD_OPTION(castor ON "CASTOR support, requires libshift from CASTOR >= 1.5.2") -ROOT_BUILD_OPTION(chirp ON "Chirp support (Condor remote I/O), requires libchirp_client") -ROOT_BUILD_OPTION(cintex ON "Build the libCintex Reflex interface library") +ROOT_BUILD_OPTION(builtin_pcre OFF "Built included libpcre, or use system libpcre") +ROOT_BUILD_OPTION(builtin_zlib OFF "Built included libz, or use system libz") +ROOT_BUILD_OPTION(builtin_lzma OFF "Built included liblzma, or use system liblzma") +ROOT_BUILD_OPTION(builtin_gsl OFF "Built the GSL library internally (downloading tarfile from the Web)") +ROOT_BUILD_OPTION(builtin_cfitsio OFF "Built the FITSIO library internally (downloading tarfile from the Web)") +ROOT_BUILD_OPTION(builtin_xrootd OFF "Built the XROOTD internally (downloading tarfile from the Web)") +ROOT_BUILD_OPTION(c++11 OFF "Build using C++11 compatible mode, requires gcc > 4.7.x or clang") +ROOT_BUILD_OPTION(libcxx OFF "Build using libc++, requires cxx11 option (MacOS X only, for the time being)") +ROOT_BUILD_OPTION(castor ON "CASTOR support, requires libshift from CASTOR >= 1.5.2") +ROOT_BUILD_OPTION(chirp ON "Chirp support (Condor remote I/O), requires libchirp_client") +ROOT_BUILD_OPTION(cintex ON "Build the libCintex Reflex interface library") ROOT_BUILD_OPTION(clarens ON "Clarens RPC support, optionally used by PROOF") -ROOT_BUILD_OPTION(cling ON "Enable new CLING C++ interpreter") -ROOT_BUILD_OPTION(cocoa OFF "Use native Cocoa/Quartz graphics backend (MacOS X only)") -ROOT_BUILD_OPTION(dcache ON "dCache support, requires libdcap from DESY") -ROOT_BUILD_OPTION(exceptions ON "Turn on compiler exception handling capability") -ROOT_BUILD_OPTION(explicitlink ${explicitlink_defvalue} "Explicitly link with all dependent libraries") -ROOT_BUILD_OPTION(fftw3 ON "Fast Fourier Transform support, requires libfftw3") -ROOT_BUILD_OPTION(fitsio ON "Read images and data from FITS files, requires cfitsio") -ROOT_BUILD_OPTION(gviz ON "Graphs visualization support, requires graphviz") -ROOT_BUILD_OPTION(gdml OFF "GDML writer and reader") -ROOT_BUILD_OPTION(genvector ON "Build the new libGenVector library" ) -ROOT_BUILD_OPTION(gfal ON "GFAL support, requires libgfal") -ROOT_BUILD_OPTION(glite ON "gLite support, requires libglite-api-wrapper v.3 from GSI (https://subversion.gsi.de/trac/dgrid/wiki)") -ROOT_BUILD_OPTION(globus OFF "Globus authentication support, requires Globus toolkit") +ROOT_BUILD_OPTION(cling OFF "Enable new CLING C++ interpreter") +ROOT_BUILD_OPTION(cocoa OFF "Use native Cocoa/Quartz graphics backend (MacOS X only)") +ROOT_BUILD_OPTION(davix ${davix_defvalue} "DavIx library for HTTP/WEBDAV access") +ROOT_BUILD_OPTION(dcache ON "dCache support, requires libdcap from DESY") +ROOT_BUILD_OPTION(exceptions ON "Turn on compiler exception handling capability") +ROOT_BUILD_OPTION(explicitlink ${explicitlink_defvalue} "Explicitly link with all dependent libraries") +ROOT_BUILD_OPTION(fftw3 ON "Fast Fourier Transform support, requires libfftw3") +ROOT_BUILD_OPTION(fitsio ON "Read images and data from FITS files, requires cfitsio") +ROOT_BUILD_OPTION(fortran ON "Enable the Fortran components of ROOT") +ROOT_BUILD_OPTION(gviz ON "Graphs visualization support, requires graphviz") +ROOT_BUILD_OPTION(gdml OFF "GDML writer and reader") +ROOT_BUILD_OPTION(genvector ON "Build the new libGenVector library") +ROOT_BUILD_OPTION(gfal ON "GFAL support, requires libgfal") +ROOT_BUILD_OPTION(glite ON "gLite support, requires libglite-api-wrapper v.3 from GSI (https://subversion.gsi.de/trac/dgrid/wiki)") +ROOT_BUILD_OPTION(globus OFF "Globus authentication support, requires Globus toolkit") ROOT_BUILD_OPTION(gsl_shared OFF "Enable linking against shared libraries for GSL (default no)") -ROOT_BUILD_OPTION(hdfs ON "HDFS support; requires libhdfs from HDFS >= 0.19.1") -ROOT_BUILD_OPTION(krb5 ON "Kerberos5 support, requires Kerberos libs") -ROOT_BUILD_OPTION(ldap ON "LDAP support, requires (Open)LDAP libs") -ROOT_BUILD_OPTION(mathmore ON "Build the new libMathMore extended math library, requires GSL (vers. >= 1.8)") -ROOT_BUILD_OPTION(memstat ${memstat_defvalue} "A memory statistics utility, helps to detect memory leaks") -ROOT_BUILD_OPTION(minuit2 OFF "Build the new libMinuit2 minimizer library") -ROOT_BUILD_OPTION(monalisa ON "Monalisa monitoring support, requires libapmoncpp") -ROOT_BUILD_OPTION(mysql ON "MySQL support, requires libmysqlclient") -ROOT_BUILD_OPTION(odbc ON "ODBC support, requires libiodbc or libodbc") -ROOT_BUILD_OPTION(opengl ON "OpenGL support, requires libGL and libGLU") -ROOT_BUILD_OPTION(oracle ON "Oracle support, requires libocci") -ROOT_BUILD_OPTION(pch ON) -ROOT_BUILD_OPTION(peac ON "PEAC, PROOF Enabled Analysis Center, requires Clarens") -ROOT_BUILD_OPTION(pgsql ON "PostgreSQL support, requires libpq") -ROOT_BUILD_OPTION(pythia6 ON "Pythia6 EG support, requires libPythia6") -ROOT_BUILD_OPTION(pythia8 ON "Pythia8 EG support, requires libPythia8") -ROOT_BUILD_OPTION(python ON "Python ROOT bindings, requires python >= 2.2") -ROOT_BUILD_OPTION(qt OFF "Qt graphics backend, requires libqt >= 4.x") -ROOT_BUILD_OPTION(qtgsi OFF "GSI's Qt integration, requires libqt >= 3") -ROOT_BUILD_OPTION(reflex ON "Build the libReflex dictionary library") -ROOT_BUILD_OPTION(roofit OFF "Build the libRooFit advanced fitting package") -ROOT_BUILD_OPTION(ruby OFF "Ruby ROOT bindings, requires ruby >= 1.8") -ROOT_BUILD_OPTION(rfio ON "RFIO support, requires libshift from CASTOR >= 1.5.2") -ROOT_BUILD_OPTION(rpath OFF "Set run-time library load path on executables and shared libraries (at installation area)") -ROOT_BUILD_OPTION(sapdb ON "MaxDB/SapDB support, requires libsqlod and libsqlrte") -ROOT_BUILD_OPTION(shadowpw ON "Shadow password support") -ROOT_BUILD_OPTION(shared ON "Use shared 3rd party libraries if possible") -ROOT_BUILD_OPTION(soversion OFF "Set version number in sonames (recommended)") -ROOT_BUILD_OPTION(srp ON "SRP support, requires SRP source tree") -ROOT_BUILD_OPTION(ssl ON "SSL encryption support, requires openssl") -ROOT_BUILD_OPTION(table OFF "Build libTable contrib library") -ROOT_BUILD_OPTION(tmva ON "Build TMVA multi variate analysis library") -ROOT_BUILD_OPTION(unuran OFF "UNURAN - package for generating non-uniform random numbers") -ROOT_BUILD_OPTION(winrtdebug OFF "Link against the Windows debug runtime library") -ROOT_BUILD_OPTION(xft ON "Xft support (X11 antialiased fonts)") +ROOT_BUILD_OPTION(hdfs ON "HDFS support; requires libhdfs from HDFS >= 0.19.1") +ROOT_BUILD_OPTION(krb5 ON "Kerberos5 support, requires Kerberos libs") +ROOT_BUILD_OPTION(ldap ON "LDAP support, requires (Open)LDAP libs") +ROOT_BUILD_OPTION(mathmore ON "Build the new libMathMore extended math library, requires GSL (vers. >= 1.8)") +ROOT_BUILD_OPTION(memstat ${memstat_defvalue} "A memory statistics utility, helps to detect memory leaks") +ROOT_BUILD_OPTION(minuit2 OFF "Build the new libMinuit2 minimizer library") +ROOT_BUILD_OPTION(monalisa ON "Monalisa monitoring support, requires libapmoncpp") +ROOT_BUILD_OPTION(mysql ON "MySQL support, requires libmysqlclient") +ROOT_BUILD_OPTION(odbc ON "ODBC support, requires libiodbc or libodbc") +ROOT_BUILD_OPTION(opengl ON "OpenGL support, requires libGL and libGLU") +ROOT_BUILD_OPTION(oracle ON "Oracle support, requires libocci") +ROOT_BUILD_OPTION(pch ON) +ROOT_BUILD_OPTION(peac ON "PEAC, PROOF Enabled Analysis Center, requires Clarens") +ROOT_BUILD_OPTION(pgsql ON "PostgreSQL support, requires libpq") +ROOT_BUILD_OPTION(pythia6 ON "Pythia6 EG support, requires libPythia6") +ROOT_BUILD_OPTION(pythia6_nolink OFF "Delayed linking of Pythia6 library") +ROOT_BUILD_OPTION(pythia8 ON "Pythia8 EG support, requires libPythia8") +ROOT_BUILD_OPTION(python ON "Python ROOT bindings, requires python >= 2.2") +ROOT_BUILD_OPTION(qt OFF "Qt graphics backend, requires libqt >= 4.x") +ROOT_BUILD_OPTION(qtgsi OFF "GSI's Qt integration, requires libqt >= 3") +ROOT_BUILD_OPTION(reflex ON "Build the libReflex dictionary library") +ROOT_BUILD_OPTION(roofit OFF "Build the libRooFit advanced fitting package") +ROOT_BUILD_OPTION(ruby OFF "Ruby ROOT bindings, requires ruby >= 1.8") +ROOT_BUILD_OPTION(rfio ON "RFIO support, requires libshift from CASTOR >= 1.5.2") +ROOT_BUILD_OPTION(rpath OFF "Set run-time library load path on executables and shared libraries (at installation area)") +ROOT_BUILD_OPTION(sapdb ON "MaxDB/SapDB support, requires libsqlod and libsqlrte") +ROOT_BUILD_OPTION(shadowpw ON "Shadow password support") +ROOT_BUILD_OPTION(shared ON "Use shared 3rd party libraries if possible") +ROOT_BUILD_OPTION(soversion OFF "Set version number in sonames (recommended)") +ROOT_BUILD_OPTION(sqlite ON "SQLite support, requires libsqlite3") +ROOT_BUILD_OPTION(srp ON "SRP support, requires SRP source tree") +ROOT_BUILD_OPTION(ssl ON "SSL encryption support, requires openssl") +ROOT_BUILD_OPTION(gnuinstall OFF "Perform installation following the GNU guidelines") +ROOT_BUILD_OPTION(table OFF "Build libTable contrib library") +ROOT_BUILD_OPTION(tmva ON "Build TMVA multi variate analysis library") +ROOT_BUILD_OPTION(unuran OFF "UNURAN - package for generating non-uniform random numbers") +ROOT_BUILD_OPTION(winrtdebug OFF "Link against the Windows debug runtime library") +ROOT_BUILD_OPTION(xft ON "Xft support (X11 antialiased fonts)") ROOT_BUILD_OPTION(xml ON "XML parser interface") ROOT_BUILD_OPTION(x11 ${x11_defvalue} "X11 support") ROOT_BUILD_OPTION(xrootd ON "Build xrootd file server and its client (if supported)") - + option(fail-on-missing "Fail the configure step if a required external package is missing" OFF) option(minimal "Do not automatically search for support libraries" OFF) option(gminimal "Do not automatically search for support libraries, but include X11" OFF) @@ -153,30 +168,24 @@ include_regular_expression("^[^.]+$|[.]h$|[.]icc$|[.]hxx$|[.]hpp$") #---Set all directories where to install parts of root up to now everything is installed ------ #---according to the setting of CMAKE_INSTALL_DIR -if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) +if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT AND NOT gnuinstall) message(STATUS "Setting default installation prefix CMAKE_INSTALL_PREFIX to ${ROOTSYS}") set(CMAKE_INSTALL_PREFIX ${ROOTSYS} CACHE PATH "Default installation of ROOT" FORCE) endif() -#if(ROOT_INSTALL_DIR) -# set(CMAKE_INSTALL_PREFIX ${ROOT_INSTALL_DIR}) -# add_definitions(-DR__HAVE_CONFIG) -#else() -# set(CMAKE_INSTALL_PREFIX ${ROOTSYS}) -#endif() - -set(ROOT_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}) -set(BIN_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/bin) -set(LIB_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/lib) -set(INCLUDE_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/include) -set(ETC_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/etc) -set(DATA_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}) -set(DOC_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}) -set(MACRO_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/macro) -set(SRC_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/src) -set(ICON_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/icons) -set(FONT_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/fonts) -set(CINT_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/cint) +#---Add defines for CINT limits----------------------------------------------------------------- +if(DEFINED CINTMAXSTRUCT) + add_definitions(-DG__MAXSTRUCT=${CINTMAXSTRUCT}) +endif() +if(DEFINED CINTMAXTYPEDEF) + add_definitions(-DG__MAXTYPEDEF=${CINTMAXTYPEDEF}) +endif() +if(DEFINED CINTLONGLINE) + add_definitions(-DG__LONGLINE=${CINTLONGLINE}) +endif() + +#---Add Installation Variables------------------------------------------------------------------ +include(RootInstallDirs) diff --git a/cmake/modules/RootConfiguration.cmake b/cmake/modules/RootConfiguration.cmake index 4127b806266b5..7b886b3f1ddcb 100644 --- a/cmake/modules/RootConfiguration.cmake +++ b/cmake/modules/RootConfiguration.cmake @@ -24,24 +24,46 @@ set(winrtdebug ${value${winrtdebug}}) set(exceptions ${value${exceptions}}) set(explicitlink ${value${explicitlink}}) -set(prefix "$(ROOTSYS)") -set(bindir "$(ROOTSYS)/bin") -set(libdir "$(ROOTSYS)/lib") -set(incdir "$(ROOTSYS)/include") -set(mandir "$(ROOTSYS)/man/man1") -set(etcdir "$(ROOTSYS)/etc") -set(plugindir ${etcdir}/plugins) -set(datadir "$(ROOTSYS)") -set(elispdir "$(ROOTSYS)/build/misc") -set(ttffontdir "$(ROOTSYS)/fonts") -set(macrodir "$(ROOTSYS)/macros") -set(srcdir "$(ROOTSYS)/src") -set(iconpath ${datadir}/icons) -set(cintincdir "$(ROOTSYS)/cint") -set(docdir "$(ROOTSYS)") -set(testdir "$(ROOTSYS)/test") -set(tutdir "$(ROOTSYS)/tutorials") -set(aclocaldir "$(ROOTSYS)/build/misc") +if(gnuinstall) + set(prefix ${CMAKE_INSTALL_PREFIX}) + set(etcdir ${CMAKE_INSTALL_FULL_ETCDIR}) + set(bindir ${CMAKE_INSTALL_FULL_BINDIR}) + set(libdir ${CMAKE_INSTALL_FULL_LIBDIR}) + set(incdir ${CMAKE_INSTALL_FULL_INCDIR}) + set(mandir ${CMAKE_INSTALL_FULL_MANDIR}) + set(plugindir ${CMAKE_INSTALL_FULL_ETCDIR}/plugins) + set(datadir ${CMAKE_INSTALL_FULL_DATADIR}) + set(elispdir ${CMAKE_INSTALL_FULL_ELISPDIR}) + set(ttffontdir ${CMAKE_INSTALL_FULL_FONTDIR}) + set(macrodir ${CMAKE_INSTALL_FULL_MACRODIR}) + set(srcdir ${CMAKE_INSTALL_FULL_SRCDIR}) + set(iconpath ${CMAKE_INSTALL_FULL_ICONDIR}) + set(cintincdir ${CMAKE_INSTALL_FULL_CINTINCDIR}) + set(docdir ${CMAKE_INSTALL_FULL_DOCDIR}) + set(testdir ${CMAKE_INSTALL_FULL_TESTDIR}) + set(tutdir ${CMAKE_INSTALL_FULL_TUTDIR}) + set(aclocaldir ${CMAKE_INSTALL_FULL_ACLOCALDIR}) +else() + set(prefix $(ROOTSYS)) + set(etcdir ${prefix}/${CMAKE_INSTALL_ETCDIR}) + set(bindir ${prefix}/${CMAKE_INSTALL_BINDIR}) + set(libdir ${prefix}/${CMAKE_INSTALL_LIBDIR}) + set(incdir ${prefix}/${CMAKE_INSTALL_INCDIR}) + set(mandir ${prefix}/${CMAKE_INSTALL_MANDIR}) + set(plugindir ${prefix}/${CMAKE_INSTALL_ETCDIR}/plugins) + set(datadir ${prefix}/${CMAKE_INSTALL_DATADIR}) + set(elispdir ${prefix}/${CMAKE_INSTALL_ELISPDIR}) + set(ttffontdir ${prefix}/${CMAKE_INSTALL_FONTDIR}) + set(macrodir ${prefix}/${CMAKE_INSTALL_MACRODIR}) + set(srcdir ${prefix}/${CMAKE_INSTALL_SRCDIR}) + set(iconpath ${prefix}/${CMAKE_INSTALL_ICONDIR}) + set(cintincdir ${prefix}/${CMAKE_INSTALL_CINTINCDIR}) + set(docdir ${prefix}/${CMAKE_INSTALL_DOCDIR}) + set(testdir ${prefix}/${CMAKE_INSTALL_TESTDIR}) + set(tutdir ${prefix}/${CMAKE_INSTALL_TUTDIR}) + set(aclocaldir ${prefix}/${CMAKE_INSTALL_ACLOCALDIR}) +endif() + set(LibSuffix ${SOEXT}) set(buildx11 ${value${x11}}) @@ -89,6 +111,11 @@ set(pgsqllibdir ${PGSQL_LIBRARY_DIR}) set(pgsqllib ${PGSQL_LIBRARY}) set(pgsqlincdir ${PGSQL_INCLUDE_DIR}) +set(buildsqlite ${value${sqlite}}) +set(sqlitelibdir ${SQLITE_LIBRARY_DIR}) +set(sqlitelib ${SQLITE_LIBRARY}) +set(sqliteincdir ${SQLITE_INCLUDE_DIR}) + set(buildsapdb ${value${sapdb}}) set(sapdblibdir ${SAPDB_LIBRARY_DIR}) set(sapdblib ${SAPDB_LIBRARY}) @@ -119,12 +146,18 @@ set(castorlib ${CASTOR_LIBRARY}) set(castorincdir ${CASTOR_INCLUDE_DIR}) set(castorcflags) + +set(builddavix ${value${davix}}) +set(davixlibdir ${DAVIX_LIBRARY_DIR}) +set(davixlib ${DAVIX_LIBRARY}) +set(davixincdir ${DAVIX_INCLUDE_DIR}) + set(builddcap ${value${dcap}}) set(dcaplibdir ${DCAP_LIBRARY_DIR}) set(dcaplib ${DCAP_LIBRARY}) set(dcapincdir ${DCAP_INCLUDE_DIR}) -set(buildftgl ${value${ftgl}}) +set(buildftgl ${value${builtin_ftgl}}) set(ftgllibdir ${FTGL_LIBRARY_DIR}) set(ftgllibs ${FTGL_LIBRARIES}) set(ftglincdir ${FTGL_INCLUDE_DIR}) @@ -325,9 +358,13 @@ set(hasxft ${has${xft}}) set(hascling ${has${cling}}) set(haslzmacompression ${has${lzma}}) set(hascocoa ${has${cocoa}}) +set(usec++11 ${has${c++11}}) +set(uselibc++ ${has${libcxx}}) + #---root-config---------------------------------------------------------------------------------------------- ROOT_SHOW_OPTIONS(features) +string(REPLACE "c++11" "cxx11" features ${features}) # change the name of the c++11 feature needed for root-config.in set(configfeatures ${features}) set(configargs ${ROOT_CONFIGARGS}) set(configoptions ${ROOT_CONFIGARGS}) @@ -346,11 +383,11 @@ set(pythonvers ${PYTHON_VERSION}) include(WriteConfigCint) WRITE_CONFIG_CINT( ${CMAKE_CURRENT_BINARY_DIR}/tmp/configcint.h) execute_process(COMMAND cmake -E copy_if_different ${CMAKE_CURRENT_BINARY_DIR}/tmp/configcint.h ${HEADER_OUTPUT_PATH}/configcint.h) -#install(FILES ${HEADER_OUTPUT_PATH}/configcint.h DESTINATION include) +#install(FILES ${HEADER_OUTPUT_PATH}/configcint.h DESTINATION ${CMAKE_INSTALL_INCDIR}) #---RConfigure.h--------------------------------------------------------------------------------------------- configure_file(${PROJECT_SOURCE_DIR}/config/RConfigure.in include/RConfigure.h) -install(FILES ${CMAKE_BINARY_DIR}/include/RConfigure.h DESTINATION include) +install(FILES ${CMAKE_BINARY_DIR}/include/RConfigure.h DESTINATION ${CMAKE_INSTALL_INCDIR}) #---Configure and install various files---------------------------------------------------------------------- execute_Process(COMMAND hostname OUTPUT_VARIABLE BuildNodeInfo OUTPUT_STRIP_TRAILING_WHITESPACE ) @@ -358,6 +395,9 @@ execute_Process(COMMAND hostname OUTPUT_VARIABLE BuildNodeInfo OUTPUT_STRIP_TRAI configure_file(${CMAKE_SOURCE_DIR}/config/rootrc.in ${CMAKE_BINARY_DIR}/etc/system.rootrc @ONLY) configure_file(${CMAKE_SOURCE_DIR}/config/RConfigOptions.in include/RConfigOptions.h) +if(ruby) + file(APPEND ${CMAKE_BINARY_DIR}/include/RConfigOptions.h "\#define R__RUBY_MAJOR ${RUBY_MAJOR_VERSION}\n\#define R__RUBY_MINOR ${RUBY_MINOR_VERSION}\n") +endif() if(WIN32) configure_file(${CMAKE_SOURCE_DIR}/cmake/scripts/compiledata.win32.in include/compiledata.h) else() @@ -380,10 +420,19 @@ set(ROOT_INCLUDE_DIR_SETUP " # ROOT configured for use from the build tree - absolute paths are used. set(ROOT_INCLUDE_DIRS ${buildtree_include_dirs}) ") +set(ROOT_LIBRARY_DIR_SETUP " +# ROOT configured for use from the build tree - absolute paths are used. +set(ROOT_LIBRARY_DIR ${CMAKE_BINARY_DIR}/lib) +") +set(ROOT_BINARY_DIR_SETUP " +# ROOT configured for use from the build tree - absolute paths are used. +set(ROOT_BINARY_DIR ${CMAKE_BINARY_DIR}/bin) +") set(ROOT_MODULE_PATH_SETUP " # ROOT configured for use CMake modules from source tree set(CMAKE_MODULE_PATH \${CMAKE_MODULE_PATH} ${CMAKE_MODULE_PATH}) ") + get_property(exported_targets GLOBAL PROPERTY ROOT_EXPORTED_TARGETS) export(TARGETS ${exported_targets} FILE ${PROJECT_BINARY_DIR}/ROOTConfig-targets.cmake) configure_file(${CMAKE_SOURCE_DIR}/cmake/scripts/ROOTConfig.cmake.in @@ -394,6 +443,14 @@ set(ROOT_INCLUDE_DIR_SETUP " # ROOT configured for the install with relative paths, so use these get_filename_component(ROOT_INCLUDE_DIRS \"\${_thisdir}/../include\" ABSOLUTE) ") +set(ROOT_LIBRARY_DIR_SETUP " +# ROOT configured for the install with relative paths, so use these +get_filename_component(ROOT_LIBRARY_DIR \"\${_thisdir}/../lib\" ABSOLUTE) +") +set(ROOT_BINARY_DIR_SETUP " +# ROOT configured for the install with relative paths, so use these +get_filename_component(ROOT_BINARY_DIR \"\${_thisdir}/../bin\" ABSOLUTE) +") set(ROOT_MODULE_PATH_SETUP " # ROOT configured for use CMake modules from installation tree set(CMAKE_MODULE_PATH \${CMAKE_MODULE_PATH} \${_thisdir}/modules) @@ -402,25 +459,30 @@ configure_file(${CMAKE_SOURCE_DIR}/cmake/scripts/ROOTConfig.cmake.in ${CMAKE_BINARY_DIR}/installtree/ROOTConfig.cmake @ONLY) install(FILES ${CMAKE_BINARY_DIR}/ROOTConfig-version.cmake ${CMAKE_BINARY_DIR}/ROOTUseFile.cmake - ${CMAKE_BINARY_DIR}/installtree/ROOTConfig.cmake DESTINATION cmake) -install(EXPORT ${CMAKE_PROJECT_NAME}Exports FILE ROOTConfig-targets.cmake DESTINATION cmake) + ${CMAKE_BINARY_DIR}/installtree/ROOTConfig.cmake DESTINATION ${CMAKE_INSTALL_CMAKEDIR}) +install(EXPORT ${CMAKE_PROJECT_NAME}Exports FILE ROOTConfig-targets.cmake DESTINATION ${CMAKE_INSTALL_CMAKEDIR}) #---Especial definitions for root-config et al.-------------------------------------------------------------- -set(prefix $ROOTSYS) -set(bindir $ROOTSYS/bin) -set(libdir $ROOTSYS/lib) -set(incdir $ROOTSYS/include) -set(etcdir $ROOTSYS/etc) -set(mandir $ROOTSYS/man/man1) +if(prefix STREQUAL "$(ROOTSYS)") + set(prefix $ROOTSYS) + set(bindir $ROOTSYS/bin) + set(libdir $ROOTSYS/lib) + set(incdir $ROOTSYS/include) + set(etcdir $ROOTSYS/etc) + set(mandir $ROOTSYS/man/man1) +endif() configure_file(${CMAKE_SOURCE_DIR}/config/root-config.in ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/root-config @ONLY) configure_file(${CMAKE_SOURCE_DIR}/config/memprobe.in ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/memprobe @ONLY) configure_file(${CMAKE_SOURCE_DIR}/config/thisroot.sh ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/thisroot.sh @ONLY) configure_file(${CMAKE_SOURCE_DIR}/config/thisroot.csh ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/thisroot.csh @ONLY) +configure_file(${CMAKE_SOURCE_DIR}/config/setxrd.csh ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/setxrd.csh COPYONLY) +configure_file(${CMAKE_SOURCE_DIR}/config/setxrd.sh ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/setxrd.sh COPYONLY) configure_file(${CMAKE_SOURCE_DIR}/config/genreflex.in ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/genreflex @ONLY) configure_file(${CMAKE_SOURCE_DIR}/config/genreflex-rootcint.in ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/genreflex-rootcint @ONLY) configure_file(${CMAKE_SOURCE_DIR}/config/proofserv.in ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/proofserv @ONLY) configure_file(${CMAKE_SOURCE_DIR}/config/roots.in ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/roots @ONLY) +configure_file(${CMAKE_SOURCE_DIR}/config/root-help.el.in root-help.el @ONLY) if(WIN32) set(thisrootbat ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/thisroot.bat) @@ -432,7 +494,9 @@ install(FILES ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/genreflex ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/memprobe ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/thisroot.sh ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/thisroot.csh - ${thisrootbat} + ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/setxrd.csh + ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/setxrd.sh + ${thisrootbat} ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/root-config ${CMAKE_SOURCE_DIR}/cmake/scripts/setenvwrap.csh ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/roots @@ -440,20 +504,17 @@ install(FILES ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/genreflex PERMISSIONS OWNER_EXECUTE OWNER_WRITE OWNER_READ GROUP_EXECUTE GROUP_READ WORLD_EXECUTE WORLD_READ - DESTINATION bin) + DESTINATION ${CMAKE_INSTALL_BINDIR}) install(FILES ${CMAKE_BINARY_DIR}/include/RConfigOptions.h ${CMAKE_BINARY_DIR}/include/compiledata.h - DESTINATION include) + DESTINATION ${CMAKE_INSTALL_INCDIR}) install(FILES ${CMAKE_BINARY_DIR}/etc/root.mimes ${CMAKE_BINARY_DIR}/etc/system.rootrc - DESTINATION etc) - -install(FILES ${CMAKE_BINARY_DIR}/config/Makefile.comp - ${CMAKE_BINARY_DIR}/config/Makefile.config - DESTINATION config) - + DESTINATION ${CMAKE_INSTALL_ETCDIR}) + +install(FILES ${CMAKE_BINARY_DIR}/root-help.el DESTINATION ${CMAKE_INSTALL_ELISPDIR}) endfunction() RootConfigure() diff --git a/cmake/modules/RootInstallDirs.cmake b/cmake/modules/RootInstallDirs.cmake new file mode 100644 index 0000000000000..cbc181acc57be --- /dev/null +++ b/cmake/modules/RootInstallDirs.cmake @@ -0,0 +1,212 @@ +# - Define GNU standard installation directories +# Provides install directory variables as defined for GNU software: +# http://www.gnu.org/prep/standards/html_node/Directory-Variables.html +# Inclusion of this module defines the following variables: +# CMAKE_INSTALL_ - destination for files of a given type +# CMAKE_INSTALL_FULL_ - corresponding absolute path +# where is one of: +# BINDIR - user executables (bin) +# LIBDIR - object code libraries (lib or lib64 or lib/ on Debian) +# INCDIR - C/C++ header files (include) +# ETCDIR - read-only single-machine data (etc) +# DATAROOTDIR - read-only architecture-independent data (share/root) +# DATADIR - read-only architecture-independent data (DATAROOTDIR) +# MANDIR - man documentation (DATAROOTDIR/man) +# MACRODIR - ROOT macros (DATAROOTDIR/macros) +# CINTINCDIR - CINT include files (LIBDIR/macros) +# ICONDIR - icons (DATAROOTDIR/icons) +# SRCDIR - sources (DATAROOTDIR/src) +# FONTDIR - fonts (DATAROOTDIR/fonts) +# DOCDIR - documentation root (DATAROOTDIR/doc/PROJECT_NAME) +# TESTDIR - tests (DOCDIR/test) +# TUTDIR - tutorials (DOCDIR/tutorials) +# ACLOCALDIR - locale-dependent data (DATAROOTDIR/aclocal) +# CMAKEDIR - cmake modules (DATAROOTDIR/cmake) +# ELISPDIR - lisp files (DATAROOTDIR/emacs/site-lisp) +# +# Each CMAKE_INSTALL_ value may be passed to the DESTINATION options of +# install() commands for the corresponding file type. If the includer does +# not define a value the above-shown default will be used and the value will +# appear in the cache for editing by the user. +# Each CMAKE_INSTALL_FULL_ value contains an absolute path constructed +# from the corresponding destination by prepending (if necessary) the value +# of CMAKE_INSTALL_PREFIX. + +#============================================================================= +# Copyright 2011 Nikita Krupen'ko +# Copyright 2011 Kitware, Inc. +# +# Distributed under the OSI-approved BSD License (the "License"); +# see accompanying file Copyright.txt for details. +# +# This software is distributed WITHOUT ANY WARRANTY; without even the +# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +# See the License for more information. +#============================================================================= +# (To distribute this file outside of CMake, substitute the full +# License text for the above reference.) + +if(NOT DEFINED CMAKE_INSTALL_BINDIR) + set(CMAKE_INSTALL_BINDIR "bin" CACHE PATH "user executables (bin)") +endif() + +if(NOT DEFINED CMAKE_INSTALL_LIBDIR) + if(gnuinstall) + set(CMAKE_INSTALL_LIBDIR "lib/root" CACHE PATH "object code libraries (lib/root)") + else() + set(CMAKE_INSTALL_LIBDIR "lib" CACHE PATH "object code libraries (lib)") + endif() +endif() + +if(NOT DEFINED CMAKE_INSTALL_CINTINCDIR) + if(gnuinstall) + set(CMAKE_INSTALL_CINTINCDIR "lib/root/cint" CACHE PATH "cint includes and libraries libraries (cint)") + else() + set(CMAKE_INSTALL_CINTINCDIR "cint" CACHE PATH "cint includes and libraries libraries (cint)") + endif() +endif() + +if(NOT DEFINED CMAKE_INSTALL_INCDIR) + if(gnuinstall) + set(CMAKE_INSTALL_INCDIR "include/root" CACHE PATH "C header files (include)") + else() + set(CMAKE_INSTALL_INCDIR "include" CACHE PATH "C header files (include)") + endif() +endif() + +if(NOT DEFINED CMAKE_INSTALL_ETCDIR) + if(gnuinstall) + set(CMAKE_INSTALL_ETCDIR "/etc/root" CACHE PATH "read-only single-machine data (etc)") + else() + set(CMAKE_INSTALL_ETCDIR "etc" CACHE PATH "read-only single-machine data (etc)") + endif() +endif() + +if(gnuinstall) + set(__dataroot__ share/root/) + set(__share__ share/) +endif() + +#----------------------------------------------------------------------------- +# Values whose defaults are relative to DATAROOTDIR. Store empty values in +# the cache and store the defaults in local variables if the cache values are +# not set explicitly. This auto-updates the defaults as DATAROOTDIR changes. + +if(NOT CMAKE_INSTALL_DATADIR) + set(CMAKE_INSTALL_DATADIR "" CACHE PATH "read-only architecture-independent data (DATAROOTDIR)") + if(gnuinstall) + set(CMAKE_INSTALL_DATADIR "${__share__}root") + else() + set(CMAKE_INSTALL_DATADIR ".") + endif() +endif() + +if(NOT CMAKE_INSTALL_MANDIR) + set(CMAKE_INSTALL_MANDIR "" CACHE PATH "man documentation (DATAROOTDIR/man)") + set(CMAKE_INSTALL_MANDIR "${__share__}man") +endif() + +if(NOT CMAKE_INSTALL_MACRODIR) + set(CMAKE_INSTALL_MACRODIR "" CACHE PATH "macros documentation (DATAROOTDIR/macros)") + set(CMAKE_INSTALL_MACRODIR "${__dataroot__}macros") +endif() + +if(NOT CMAKE_INSTALL_ICONDIR) + set(CMAKE_INSTALL_ICONDIR "" CACHE PATH "icons (DATAROOTDIR/icons)") + set(CMAKE_INSTALL_ICONDIR "${__dataroot__}icons") +endif() + +if(NOT CMAKE_INSTALL_FONTDIR) + set(CMAKE_INSTALL_FONTDIR "" CACHE PATH "fonts (DATAROOTDIR/fonts)") + set(CMAKE_INSTALL_FONTDIR "${__dataroot__}fonts") +endif() + +if(NOT CMAKE_INSTALL_SRCDIR) + set(CMAKE_INSTALL_SRCDIR "" CACHE PATH "sources (DATAROOTDIR/src)") + set(CMAKE_INSTALL_SRCDIR "${__dataroot__}src") +endif() + +if(NOT CMAKE_INSTALL_ACLOCALDIR) + set(CMAKE_INSTALL_ACLOCALDIR "" CACHE PATH "locale-dependent data (DATAROOTDIR/aclocal)") + set(CMAKE_INSTALL_ACLOCALDIR "${__share__}aclocal") +endif() + +if(NOT CMAKE_INSTALL_CMAKEDIR) + set(CMAKE_INSTALL_CMAKEDIR "" CACHE PATH "CMake modules (DATAROOTDIR/cmake)") + set(CMAKE_INSTALL_CMAKEDIR "${__dataroot__}cmake") +endif() + +if(NOT CMAKE_INSTALL_ELISPDIR) + set(CMAKE_INSTALL_ELISPDIR "" CACHE PATH "Lisp files (DATAROOTDIR/emacs/site-lisp)") + set(CMAKE_INSTALL_ELISPDIR "${__share__}emacs/site-lisp") +endif() + +if(NOT CMAKE_INSTALL_DOCDIR) + set(CMAKE_INSTALL_DOCDIR "" CACHE PATH "documentation root (DATAROOTDIR/doc/PROJECT_NAME)") + if(gnuinstall) + set(CMAKE_INSTALL_DOCDIR "${__share__}doc/root") + else() + set(CMAKE_INSTALL_DOCDIR ".") + endif() +endif() + +if(NOT CMAKE_INSTALL_TESTDIR) + set(CMAKE_INSTALL_TESTDIR "" CACHE PATH "root tests (DOCDIR/test)") + set(CMAKE_INSTALL_TESTDIR "${CMAKE_INSTALL_DOCDIR}/test") +endif() + +if(NOT CMAKE_INSTALL_TUTDIR) + set(CMAKE_INSTALL_TUTDIR "" CACHE PATH "root tutorials (DOCDIR/tutorials)") + set(CMAKE_INSTALL_TUTDIR "${CMAKE_INSTALL_DOCDIR}/tutorials") +endif() + + +#----------------------------------------------------------------------------- + +mark_as_advanced( + CMAKE_INSTALL_BINDIR + CMAKE_INSTALL_LIBDIR + CMAKE_INSTALL_INCDIR + CMAKE_INSTALL_ETCDIR + CMAKE_INSTALL_MANDIR + CMAKE_INSTALL_DATAROOTDIR + CMAKE_INSTALL_DATADIR + CMAKE_INSTALL_MACRODIR + CMAKE_INSTALL_CINTINCDIR + CMAKE_INSTALL_ICONDIR + CMAKE_INSTALL_FONTDIR + CMAKE_INSTALL_SRCDIR + CMAKE_INSTALL_DOCDIR + CMAKE_INSTALL_TESTDIR + CMAKE_INSTALL_TUTDIR + CMAKE_INSTALL_ACLOCALDIR + CMAKE_INSTALL_ELISPDIR + CMAKE_INSTALL_CMAKEDIR + ) + +# Result directories +# +foreach(dir BINDIR + LIBDIR + INCDIR + ETCDIR + MANDIR + DATAROOTDIR + DATADIR + MACRODIR + CINTINCDIR + ICONDIR + FONTDIR + SRCDIR + DOCDIR + TESTDIR + TUTDIR + ACLOCALDIR + ELISPDIR + CMAKEDIR ) + if(NOT IS_ABSOLUTE ${CMAKE_INSTALL_${dir}}) + set(CMAKE_INSTALL_FULL_${dir} "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_${dir}}") + else() + set(CMAKE_INSTALL_FULL_${dir} "${CMAKE_INSTALL_${dir}}") + endif() +endforeach() diff --git a/cmake/modules/RootNewMacros.cmake b/cmake/modules/RootNewMacros.cmake index 91035eabb1bfd..5bb62a5833a15 100644 --- a/cmake/modules/RootNewMacros.cmake +++ b/cmake/modules/RootNewMacros.cmake @@ -1,10 +1,12 @@ #--------------------------------------------------------------------------------------------------- # RootNewMacros.cmake #--------------------------------------------------------------------------------------------------- -cmake_minimum_required(VERSION 2.4.6) cmake_policy(SET CMP0003 NEW) # See "cmake --help-policy CMP0003" for more details cmake_policy(SET CMP0011 NEW) # See "cmake --help-policy CMP0011" for more details cmake_policy(SET CMP0009 NEW) # See "cmake --help-policy CMP0009" for more details +if(CMAKE_VERSION VERSION_GREATER 2.8.12) + cmake_policy(SET CMP0022 OLD) # See "cmake --help-policy CMP0022" for more details +endif() set(lib lib) set(bin bin) @@ -14,26 +16,26 @@ if(WIN32) set(libprefix lib) set(ld_library_path PATH) set(libsuffix .dll) - set(runtimedir bin) + set(runtimedir ${CMAKE_INSTALL_BINDIR}) elseif(APPLE) set(ld_library_path DYLD_LIBRARY_PATH) set(ssuffix .csh) set(scomment \#) set(libprefix lib) set(libsuffix .so) - set(runtimedir lib) + set(runtimedir ${CMAKE_INSTALL_LIBDIR}) else() set(ld_library_path LD_LIBRARY_PATH) set(ssuffix .csh) set(scomment \#) set(libprefix lib) set(libsuffix .so) - set(runtimedir lib) + set(runtimedir ${CMAKE_INSTALL_LIBDIR}) endif() if(soversion) set(ROOT_LIBRARY_PROPERTIES ${ROOT_LIBRARY_PROPERTIES} - VERSION ${ROOT_VERSION} + VERSION ${ROOT_MAJOR_VERSION}.${ROOT_MINOR_VERSION} SOVERSION ${ROOT_MAJOR_VERSION} SUFFIX ${libsuffix} PREFIX ${libprefix} ) @@ -45,9 +47,15 @@ else() endif() if(APPLE) - set(ROOT_LIBRARY_PROPERTIES ${ROOT_LIBRARY_PROPERTIES} - INSTALL_NAME_DIR "@rpath" - BUILD_WITH_INSTALL_RPATH ON) + if(gnuinstall) + set(ROOT_LIBRARY_PROPERTIES ${ROOT_LIBRARY_PROPERTIES} + INSTALL_NAME_DIR "${CMAKE_INSTALL_FULL_LIBDIR}" + BUILD_WITH_INSTALL_RPATH ON) + else() + set(ROOT_LIBRARY_PROPERTIES ${ROOT_LIBRARY_PROPERTIES} + INSTALL_NAME_DIR "@rpath" + BUILD_WITH_INSTALL_RPATH ON) + endif() endif() #---Modify the behaviour for local and non-local builds-------------------------------------------- @@ -253,7 +261,7 @@ endfunction() #--------------------------------------------------------------------------------------------------- -#---ROOT_LINKER_LIBRARY( source1 source2 ...[TYPE STATIC|SHARED] [DLLEXPORT] LIBRARIES library1 library2 ...) +#---ROOT_LINKER_LIBRARY( source1 source2 ...[TYPE STATIC|SHARED] [DLLEXPORT] LIBRARIES lib1 lib2 ... DEPENDENCIES lib3 l1b4) #--------------------------------------------------------------------------------------------------- function(ROOT_LINKER_LIBRARY library) PARSE_ARGUMENTS(ARG "TYPE;LIBRARIES;DEPENDENCIES" "DLLEXPORT;CMAKENOEXPORT" ${ARGN}) @@ -267,25 +275,26 @@ function(ROOT_LINKER_LIBRARY library) message("Target ${library} already exists. Renaming target name to ${library}_new") set(library ${library}_new) endif() - if(WIN32 AND NOT ARG_DLLEXPORT) + if(WIN32 AND ARG_TYPE STREQUAL SHARED AND NOT ARG_DLLEXPORT) #---create a list of all the object files----------------------------- if(CMAKE_GENERATOR MATCHES "Visual Studio") - foreach(src1 ${lib_srcs}) - if(NOT src1 MATCHES "[.]h$|[.]icc$|[.]hxx$|[.]hpp$") - string (REPLACE ${CMAKE_CURRENT_SOURCE_DIR} "" src2 ${src1}) - string (REPLACE ${CMAKE_CURRENT_BINARY_DIR} "" src3 ${src2}) - string (REPLACE ".." "__" src ${src3}) - get_filename_component(name ${src} NAME_WE) - set(lib_objs ${lib_objs} ${library}.dir/${CMAKE_CFG_INTDIR}/${name}.obj) - endif() - endforeach() + #foreach(src1 ${lib_srcs}) + # if(NOT src1 MATCHES "[.]h$|[.]icc$|[.]hxx$|[.]hpp$") + # string (REPLACE ${CMAKE_CURRENT_SOURCE_DIR} "" src2 ${src1}) + # string (REPLACE ${CMAKE_CURRENT_BINARY_DIR} "" src3 ${src2}) + # string (REPLACE ".." "__" src ${src3}) + # get_filename_component(name ${src} NAME_WE) + # set(lib_objs ${lib_objs} ${library}.dir/${CMAKE_CFG_INTDIR}/${name}.obj) + # endif() + #endforeach() + set(lib_objs ${lib_objs} ${library}.dir/${CMAKE_CFG_INTDIR}/*.obj) else() foreach(src1 ${lib_srcs}) if(NOT src1 MATCHES "[.]h$|[.]icc$|[.]hxx$|[.]hpp$") string (REPLACE ${CMAKE_CURRENT_SOURCE_DIR} "" src2 ${src1}) string (REPLACE ${CMAKE_CURRENT_BINARY_DIR} "" src3 ${src2}) string (REPLACE ".." "__" src ${src3}) - get_filename_component(name ${src} NAME_WE) + get_filename_component(name ${src} NAME) get_filename_component(path ${src} PATH) set(lib_objs ${lib_objs} ${CMAKE_CURRENT_BINARY_DIR}/CMakeFiles/${library}.dir/${path}/${name}.obj) endif() @@ -318,32 +327,31 @@ function(ROOT_LINKER_LIBRARY library) set_target_properties(${library} PROPERTIES LINK_INTERFACE_LIBRARIES "${ARG_DEPENDENCIES}") #----Installation details------------------------------------------------------- if(ARG_CMAKENOEXPORT) - install(TARGETS ${library} RUNTIME DESTINATION bin - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib + install(TARGETS ${library} RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT libraries) else() install(TARGETS ${library} EXPORT ${CMAKE_PROJECT_NAME}Exports - RUNTIME DESTINATION bin - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT libraries) - #install(EXPORT ${CMAKE_PROJECT_NAME}Exports DESTINATION cmake/modules) endif() - if(WIN32) + if(WIN32 AND ARG_TYPE STREQUAL SHARED) if(CMAKE_GENERATOR MATCHES "Visual Studio") install(FILES ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/Debug/lib${library}.pdb CONFIGURATIONS Debug - DESTINATION bin + DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT libraries) install(FILES ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/RelWithDebInfo/lib${library}.pdb CONFIGURATIONS RelWithDebInfo - DESTINATION bin + DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT libraries) else() install(FILES ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/lib${library}.pdb CONFIGURATIONS Debug RelWithDebInfo - DESTINATION bin + DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT libraries) endif() endif() @@ -360,9 +368,9 @@ function(ROOT_MODULE_LIBRARY library) set_target_properties(${library} PROPERTIES ${ROOT_LIBRARY_PROPERTIES}) target_link_libraries(${library} ${ARG_LIBRARIES}) #----Installation details------------------------------------------------------- - install(TARGETS ${library} RUNTIME DESTINATION bin - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib + install(TARGETS ${library} RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT libraries) endfunction() @@ -434,7 +442,7 @@ function(ROOT_GENERATE_ROOTMAP library) add_custom_target( ${libprefix}${library}.rootmap ALL DEPENDS ${outfile}) set_target_properties(${libprefix}${library}.rootmap PROPERTIES FOLDER RootMaps ) #---Install the rootmap file------------------------------------ - install(FILES ${outfile} DESTINATION lib COMPONENT libraries) + install(FILES ${outfile} DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT libraries) endfunction() #--------------------------------------------------------------------------------------------------- @@ -447,9 +455,10 @@ function(ROOT_INSTALL_HEADERS) set(dirs inc/) endif() foreach(d ${dirs}) - install(DIRECTORY ${d} DESTINATION include + install(DIRECTORY ${d} DESTINATION ${CMAKE_INSTALL_INCDIR} COMPONENT headers PATTERN ".svn" EXCLUDE + PATTERN "X11" EXCLUDE REGEX "LinkDef" EXCLUDE ) set_property(GLOBAL APPEND PROPERTY ROOT_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/${d}) endforeach() @@ -470,7 +479,7 @@ endfunction() #---ROOT_EXECUTABLE( source1 source2 ... LIBRARIES library1 library2 ...) #--------------------------------------------------------------------------------------------------- function(ROOT_EXECUTABLE executable) - PARSE_ARGUMENTS(ARG "LIBRARIES" "CMAKENOEXPORT" ${ARGN}) + PARSE_ARGUMENTS(ARG "LIBRARIES" "CMAKENOEXPORT;NOINSTALL" ${ARGN}) ROOT_GET_SOURCES(exe_srcs src ${ARG_DEFAULT_ARGS}) set(executable_name ${executable}) if(TARGET ${executable}) @@ -486,10 +495,12 @@ function(ROOT_EXECUTABLE executable) set_property(GLOBAL APPEND PROPERTY ROOT_EXPORTED_TARGETS ${executable}) set_target_properties(${executable} PROPERTIES OUTPUT_NAME ${executable_name}) #----Installation details------------------------------------------------------ - if(ARG_CMAKENOEXPORT) - install(TARGETS ${executable} RUNTIME DESTINATION ${bin} COMPONENT applications) - else() - install(TARGETS ${executable} EXPORT ${CMAKE_PROJECT_NAME}Exports RUNTIME DESTINATION ${bin} COMPONENT applications) + if(NOT ARG_NOINSTALL) + if(ARG_CMAKENOEXPORT) + install(TARGETS ${executable} RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT applications) + else() + install(TARGETS ${executable} EXPORT ${CMAKE_PROJECT_NAME}Exports RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT applications) + endif() endif() endfunction() @@ -502,7 +513,7 @@ function(REFLEX_BUILD_DICTIONARY dictionary headerfiles selectionfile ) add_library(${dictionary}Dict MODULE ${gensrcdict}) target_link_libraries(${dictionary}Dict ${ARG_LIBRARIES} ${ROOT_Reflex_LIBRARY}) #----Installation details------------------------------------------------------- - install(TARGETS ${dictionary}Dict LIBRARY DESTINATION ${lib}) + install(TARGETS ${dictionary}Dict LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}) set(mergedRootMap ${CMAKE_INSTALL_PREFIX}/${lib}/${CMAKE_PROJECT_NAME}Dict.rootmap) set(srcRootMap ${CMAKE_CURRENT_BINARY_DIR}/${rootmapname}) install(CODE "EXECUTE_PROCESS(COMMAND ${merge_rootmap_cmd} --do-merge --input-file ${srcRootMap} --merged-file ${mergedRootMap})") @@ -535,11 +546,13 @@ endfunction() #---ROOT_CHECK_OUT_OF_SOURCE_BUILD( ) #--------------------------------------------------------------------------------------------------- macro(ROOT_CHECK_OUT_OF_SOURCE_BUILD) - string(COMPARE EQUAL ${CMAKE_SOURCE_DIR} ${CMAKE_BINARY_DIR} insource) - if(insource) + get_filename_component(bindir_parent ${CMAKE_BINARY_DIR} PATH) + if(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR) file(REMOVE_RECURSE ${CMAKE_SOURCE_DIR}/Testing) file(REMOVE ${CMAKE_SOURCE_DIR}/DartConfiguration.tcl) - message(FATAL_ERROR "ROOT should be installed as an out of source build, to keep the source directory clean. Please create a extra build directory and run the command 'cmake ' in this newly created directory. You have also to delete the directory CMakeFiles and the file CMakeCache.txt in the source directory. Otherwise cmake will complain even if you run it from an out-of-source directory.") + message(FATAL_ERROR "ROOT should be built as an out of source build, to keep the source directory clean. Please create a extra build directory and run the command 'cmake ' in this newly created directory. You have also to delete the directory CMakeFiles and the file CMakeCache.txt in the source directory. Otherwise cmake will complain even if you run it from an out-of-source directory.") + elseif(IS_SYMLINK ${CMAKE_BINARY_DIR} AND CMAKE_SOURCE_DIR STREQUAL bindir_parent) + message(FATAL_ERROR "ROOT cannot be built from a sub-directory of the source tree that is a symlink. This is a current limitation of CMake. Please create a real build directory and run the command 'cmake ' in this newly created directory.") endif() endmacro() diff --git a/cmake/modules/SearchInstalledSoftware.cmake b/cmake/modules/SearchInstalledSoftware.cmake index 09354bfb45920..34f33fa11a54a 100644 --- a/cmake/modules/SearchInstalledSoftware.cmake +++ b/cmake/modules/SearchInstalledSoftware.cmake @@ -71,18 +71,20 @@ if(builtin_lzma) ExternalProject_Add( LZMA URL ${CMAKE_SOURCE_DIR}/core/lzma/src/xz-${lzma_version}-win32.tar.gz + URL_MD5 65693dc257802b6778c28ed53ecca678 PREFIX LZMA INSTALL_DIR ${CMAKE_BINARY_DIR} CONFIGURE_COMMAND "" BUILD_COMMAND "" INSTALL_COMMAND cmake -E copy lib/liblzma.dll /bin/${CMAKE_CFG_INTDIR} BUILD_IN_SOURCE 1) - install(FILES ${CMAKE_BINARY_DIR}/LZMA/src/LZMA/lib/liblzma.dll DESTINATION bin) + install(FILES ${CMAKE_BINARY_DIR}/LZMA/src/LZMA/lib/liblzma.dll DESTINATION ${CMAKE_INSTALL_BINDIR}) set(LZMA_LIBRARIES ${CMAKE_BINARY_DIR}/LZMA/src/LZMA/lib/liblzma.lib) set(LZMA_INCLUDE_DIR ${CMAKE_BINARY_DIR}/LZMA/src/LZMA/include) else() ExternalProject_Add( LZMA URL ${CMAKE_SOURCE_DIR}/core/lzma/src/xz-${lzma_version}.tar.gz + URL_MD5 858405e79590e9b05634c399497f4ba7 INSTALL_DIR ${CMAKE_BINARY_DIR} CONFIGURE_COMMAND /configure --prefix --with-pic --disable-shared BUILD_IN_SOURCE 1) @@ -171,6 +173,7 @@ if(asimage) find_Package(PNG) if(PNG_FOUND) set(ASEXTRA_LIBRARIES ${ASEXTRA_LIBRARIES} ${PNG_LIBRARIES}) + list(GET PNG_INCLUDE_DIRS 0 PNG_INCLUDE_DIR) endif() find_Package(JPEG) if(JPEG_FOUND) @@ -240,6 +243,10 @@ if(ruby) set(ruby OFF CACHE BOOL "" FORCE) message(STATUS "Ruby not found. Switching off ruby option") endif() + else() + string(REGEX REPLACE "([0-9]+).*$" "\\1" RUBY_MAJOR_VERSION "${RUBY_VERSION}") + string(REGEX REPLACE "[0-9]+\\.([0-9]+).*$" "\\1" RUBY_MINOR_VERSION "${RUBY_VERSION}") + string(REGEX REPLACE "[0-9]+\\.[0-9]+\\.([0-9]+).*$" "\\1" RUBY_PATCH_VERSION "${RUBY_VERSION}") endif() endif() @@ -260,7 +267,7 @@ endif() if(opengl) message(STATUS "Looking for OpenGL") find_package(OpenGL) - if(NOT OPENGL_FOUND) + if(NOT OPENGL_FOUND OR NOT OPENGL_GLU_FOUND) if(fail-on-missing) message(FATAL_ERROR "OpenGL package not found and opengl option required") else() @@ -426,11 +433,39 @@ if(odbc) endif() endif() +#---Check for PostgreSQL------------------------------------------------------------------- +if(pgsql) + message(STATUS "Looking for PostgreSQL") + find_package(PostgreSQL) + if(NOT POSTGRESQL_FOUND) + if(fail-on-missing) + message(FATAL_ERROR "PostgreSQL libraries not found and they are required (pgsql option enabled)") + else() + message(STATUS "PostgreSQL not found. Switching off pgsql option") + set(pgsql OFF CACHE BOOL "" FORCE) + endif() + endif() +endif() + +#---Check for SQLite------------------------------------------------------------------- +if(sqlite) + message(STATUS "Looking for SQLite") + find_package(Sqlite) + if(NOT SQLITE_FOUND) + if(fail-on-missing) + message(FATAL_ERROR "SQLite libraries not found and they are required (sqlite option enabled)") + else() + message(STATUS "SQLite not found. Switching off sqlite option") + set(sqlite OFF CACHE BOOL "" FORCE) + endif() + endif() +endif() + #---Check for Pythia6------------------------------------------------------------------- if(pythia6) message(STATUS "Looking for Pythia6") - find_package(Pythia6) - if(NOT PYTHIA6_FOUND) + find_package(Pythia6 QUIET) + if(NOT PYTHIA6_FOUND AND NOT pythia6_nolink) if(fail-on-missing) message(FATAL_ERROR "Pythia6 libraries not found and they are required (pythia6 option enabled)") else() @@ -531,7 +566,7 @@ if(xrootd) if(NOT builtin_xrootd) find_package(XROOTD) if(NOT XROOTD_FOUND) - message(STATUS "XROOTD not found. Set enviroment variable XRDSYS to point to your XROOTD installation") + message(STATUS "XROOTD not found. Set environment variable XRDSYS to point to your XROOTD installation") message(STATUS " Alternatively, you can also enable the option 'builtin_xrootd' to build XROOTD internally'") message(STATUS " For the time being switching OFF 'xrootd' option") set(xrootd OFF CACHE BOOL "" FORCE) @@ -546,14 +581,108 @@ if(xrootd) INSTALL_DIR ${CMAKE_BINARY_DIR} CMAKE_ARGS -DCMAKE_INSTALL_PREFIX:PATH= ) - set(XROOTD_INCLUDE_DIR ${CMAKE_BINARY_DIR}/include/xrootd) - set(XROOTD_LIBRARIES -L${CMAKE_BINARY_DIR}/lib64 -lXrdMain -lXrdUtils -lXrdClient) + set(XROOTD_INCLUDE_DIRS ${CMAKE_BINARY_DIR}/include/xrootd) + set(XROOTD_LIBRARIES -L${CMAKE_BINARY_DIR}/lib -lXrdMain -lXrdUtils -lXrdClient) set(XROOTD_CFLAGS "-DROOTXRDVERS=${xrootd_versionnum}") endif() endif() +#---Check for gfal------------------------------------------------------------------- +if(gfal) + find_package(GFAL) + if(NOT GFAL_FOUND) + if(fail-on-missing) + message(FATAL_ERROR "Gfal library not found and is required (gfal option enabled)") + else() + message(STATUS "GFAL library not found. Set variable GFAL_DIR to point to your gfal installation + and the variable SRM_IFCE_DIR to the srm_ifce installation") + message(STATUS "For the time being switching OFF 'gfal' option") + set(gfal OFF CACHE BOOL "" FORCE) + endif() + endif() +endif() + + +#---Check for dCache------------------------------------------------------------------- +if(dcache) + find_package(DCAP) + if(NOT DCAP_FOUND) + if(fail-on-missing) + message(FATAL_ERROR "dCap library not found and is required (dcache option enabled)") + else() + message(STATUS "dCap library not found. Set variable DCAP_DIR to point to your dCache installation") + message(STATUS "For the time being switching OFF 'dcache' option") + set(dcache OFF CACHE BOOL "" FORCE) + endif() + endif() +endif() + +#---Check for Ldap-------------------------------------------------------------------- +if(ldap) + find_package(Ldap) + if(NOT LDAP_FOUND) + if(fail-on-missing) + message(FATAL_ERROR "ldap library not found and is required (ldap option enabled)") + else() + message(STATUS "ldap library not found. Set variable LDAP_DIR to point to your ldap installation") + message(STATUS "For the time being switching OFF 'ldap' option") + set(ldap OFF CACHE BOOL "" FORCE) + endif() + endif() +endif() + +#---Check for globus-------------------------------------------------------------------- +if(globus) + find_package(Globus) + if(NOT GLOBUS_FOUND) + if(fail-on-missing) + message(FATAL_ERROR "globus libraries not found and is required ('globus' option enabled)") + else() + message(STATUS "globus libraries not found. Set environment var GLOBUS_LOCATION or varibale GLOBUS_DIR to point to your globus installation") + message(STATUS "For the time being switching OFF 'globus' option") + set(globus OFF CACHE BOOL "" FORCE) + endif() + endif() +endif() + +#---Check for ftgl if needed---------------------------------------------------------- +if(NOT builtin_ftgl) + find_package(FTGL) + if(NOT FTGL_FOUND) + if(fail-on-missing) + message(FATAL_ERROR "ftgl library not found and is required ('builtin_ftgl' is OFF). Set varible FTGL_ROOT_DIR to installation location") + else() + message(STATUS "ftgl library not found. Set variable FTGL_ROOT_DIR to point to your installation") + message(STATUS "For the time being switching ON 'builtin_ftgl' option") + set(builtin_ftgl ON CACHE BOOL "" FORCE) + endif() + endif() +endif() +if(builtin_ftgl) + set(FTGL_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/graf3d/ftgl/inc) + set(FTGL_CFLAGS -DBUILTIN_FTGL) + set(FTGL_LIBRARIES FTGL) +endif() + +#---Check for DavIx library----------------------------------------------------------- +if(davix) + set(DAVIX_VERSION 0.2.7) + message(STATUS "Downloading and building Davix version ${DAVIX_VERSION}") + ExternalProject_Add( + DAVIX + URL http://grid-deployment.web.cern.ch/grid-deployment/dms/lcgutil/tar/davix/davix-${DAVIX_VERSION}.tar.gz + INSTALL_DIR ${CMAKE_BINARY_DIR} + CMAKE_ARGS -DCMAKE_INSTALL_PREFIX= -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} -DLIB_SUFFIX= + ) + set(DAVIX_INCLUDE_DIR ${CMAKE_BINARY_DIR}/include/davix) + set(DAVIX_LIBRARY -L${CMAKE_BINARY_DIR}/lib -ldavix) + set(DAVIX_INCLUDE_DIRS ${DAVIX_INCLUDE_DIR}) + set(DAVIX_LIBRARIES ${DAVIX_LIBRARY}) +endif() + + #---Report non implemented options--------------------------------------------------- -foreach(opt afs chirp clarens cling dcache gfal glite globus hdfs lzma pch peac pgsql sapdb srp) +foreach(opt afs chirp clarens glite hdfs pch peac sapdb srp) if(${opt}) message(STATUS ">>> Option '${opt}' not implemented yet! Signal your urgency to pere.mato@cern.ch") set(${opt} OFF CACHE BOOL "" FORCE) diff --git a/cmake/modules/SetUpLinux.cmake b/cmake/modules/SetUpLinux.cmake index 8b76fbd8b69d6..92261722f7891 100644 --- a/cmake/modules/SetUpLinux.cmake +++ b/cmake/modules/SetUpLinux.cmake @@ -8,30 +8,32 @@ if(${SYSCTL_OUTPUT} MATCHES x86_64) set(BIT_ENVIRONMENT "-m64") set(SPECIAL_CINT_FLAGS "-DG__64BIT") if(CMAKE_COMPILER_IS_GNUCXX) - Message(STATUS "Found GNU compiler collection") - Set(ROOT_ARCHITECTURE linuxx8664gcc) - else(CMAKE_COMPILER_IS_GNUCXX) - if(${CMAKE_CXX_COMPILER} MATCHES "icpc") - Set(ROOT_ARCHITECTURE linuxx8664icc) - else(${CMAKE_CXX_COMPILER} MATCHES "icpc") - message(FATAL_ERROR "There is no Setup for this compiler up to now. Don't know what to do. Stop cmake at this point.") - endIf(${CMAKE_CXX_COMPILER} MATCHES "icpc") - endIf(CMAKE_COMPILER_IS_GNUCXX) -else(${SYSCTL_OUTPUT} MATCHES x86_64) + message(STATUS "Found GNU compiler collection") + set(ROOT_ARCHITECTURE linuxx8664gcc) + elseif(CMAKE_CXX_COMPILER_ID STREQUAL Clang) + message(STATUS "Found CLANG compiler") + set(ROOT_ARCHITECTURE linuxx8664gcc) + elseif(CMAKE_CXX_COMPILER_ID STREQUAL Intel) + set(ROOT_ARCHITECTURE linuxx8664icc) + else() + message(FATAL_ERROR "There is no Setup for this compiler up to now. Don't know what to do. Stop cmake at this point.") + endif() +else() message(STATUS "Found a 32bit system") set(BIT_ENVIRONMENT "-m32") set(SPECIAL_CINT_FLAGS "") if(CMAKE_COMPILER_IS_GNUCXX) message(STATUS "Found GNU compiler collection") set(ROOT_ARCHITECTURE linux) - else(CMAKE_COMPILER_IS_GNUCXX) - if(${CMAKE_CXX_COMPILER} MATCHES "icpc") - set(ROOT_ARCHITECTURE linuxicc) - else(${CMAKE_CXX_COMPILER} MATCHES "icpc") - message(FATAL_ERROR "There is no Setup for this compiler up to now. Don't know what to do. Stop cmake at this point.") - endif(${CMAKE_CXX_COMPILER} MATCHES "icpc") - endif(CMAKE_COMPILER_IS_GNUCXX) -endif(${SYSCTL_OUTPUT} MATCHES x86_64) + elseif(CMAKE_CXX_COMPILER_ID STREQUAL Clang) + message(STATUS "Found CLANG compiler") + set(ROOT_ARCHITECTURE linux) + elseif(CMAKE_CXX_COMPILER_ID STREQUAL Intel) + set(ROOT_ARCHITECTURE linuxicc) + else() + message(FATAL_ERROR "There is no Setup for this compiler up to now. Don't know what to do. Stop cmake at this point.") + endif() +endif() set(SYSLIBS "-lm -ldl ${CMAKE_THREAD_LIBS_INIT} -rdynamic") set(XLIBS "${XPMLIBDIR} ${XPMLIB} ${X11LIBDIR} -lXext -lX11") @@ -39,8 +41,8 @@ set(CILIBS "-lm -ldl -rdynamic") set(CRYPTLIBS "-lcrypt") set(CMAKE_M_LIBS -lm) -if(CMAKE_COMPILER_IS_GNUCXX) - execute_process(COMMAND ${CMAKE_C_COMPILER} -dumpversion OUTPUT_VARIABLE GCC_VERSION OUTPUT_STRIP_TRAILING_WHITESPACE) +if(CMAKE_COMPILER_IS_GNUCXX OR + CMAKE_CXX_COMPILER_ID STREQUAL Clang) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pipe ${BIT_ENVIRONMENT} -Wall -W -Woverloaded-virtual -fPIC") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -pipe ${BIT_ENVIRONMENT} -Wall -W -fPIC") @@ -74,85 +76,83 @@ if(CMAKE_COMPILER_IS_GNUCXX) set(EXEEXT "") set(SOEXT "so") -else(CMAKE_COMPILER_IS_GNUCXX) - if(${CMAKE_CXX_COMPILER} MATCHES "icpc") - - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC -wd1476") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -restrict") - - set(CMAKE_Fortran_FLAGS "${CMAKE_FORTRAN_FLAGS} -fPIC") - - set(CINT_CXX_DEFINITIONS "-DG__REGEXP -DG__UNIX -DG__SHAREDLIB -DG__OSFDLL -DG__ROOT -DG__REDIRECTIO -DG__STD_EXCEPTION ${SPECIAL_CINT_FLAGS}") - set(CINT_C_DEFINITIONS "-DG__REGEXP -DG__UNIX -DG__SHAREDLIB -DG__OSFDLL -DG__ROOT -DG__REDIRECTIO -DG__STD_EXCEPTION ${SPECIAL_CINT_FLAGS}") + +elseif(CMAKE_CXX_COMPILER_ID STREQUAL Intel) - - # Check icc compiler version and set compile flags according to the - execute_process(COMMAND ${CMAKE_CXX_COMPILER} -v - ERROR_VARIABLE _icc_version_info ERROR_STRIP_TRAILING_WHITESPACE) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC -wd1476") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -restrict") - string(REGEX REPLACE "^Version[ ]([0-9]+)\\.[0-9]+.*" "\\1" ICC_MAJOR "${_icc_version_info}") - string(REGEX REPLACE "^Version[ ][0-9]+\\.([0-9]+).*" "\\1" ICC_MINOR "${_icc_version_info}") + set(CMAKE_Fortran_FLAGS "${CMAKE_FORTRAN_FLAGS} -fPIC") - message(STATUS "Found ICC major version ${ICC_MAJOR}") - message(STATUS "Found ICC minor version ${ICC_MINOR}") - - if(ICC_MAJOR EQUAL 9) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -wd1572") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -wd1572") - set(ICC_GE_9 9) - endif(ICC_MAJOR EQUAL 9) - - if(ICC_MAJOR EQUAL 10) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -wd1572") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -wd1572") - set(ICC_GE_9 10) - if(ICC_MINOR GREATER 0) - set(ICC_GE_101 101) - endif(ICC_MINOR GREATER 0) - endif(ICC_MAJOR EQUAL 10) - - if(ICC_MAJOR EQUAL 11) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${BIT_ENVIRONMENT} -wd1572 -wd279") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${BIT_ENVIRONMENT} -wd1572 -wd279") - set(CMAKE_SHARED_LINKER_FLAGS "${BIT_ENVIRONMENT} -Wl,--no-undefined") - #set(CMAKE_C_LINK_FLAGS "${CMAKE_C_LINK_FLAGS} ${BIT_ENVIRONMENT}") - #set(CMAKE_CXX_LINK_FLAGS "${CMAKE_CXX_LINK_FLAGS} ${BIT_ENVIRONMENT}") - set(ICC_GE_9 11) - set(ICC_GE_101 110) - endif(ICC_MAJOR EQUAL 11) - - if(ICC_MAJOR EQUAL 12) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${BIT_ENVIRONMENT} -wd1572 -wd279") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${BIT_ENVIRONMENT} -wd1572 -wd279") - set(CMAKE_SHARED_LINKER_FLAGS "${BIT_ENVIRONMENT} -Wl,--no-undefined") - #set(CMAKE_C_LINK_FLAGS "${CMAKE_C_LINK_FLAGS} ${BIT_ENVIRONMENT}") - #set(CMAKE_CXX_LINK_FLAGS "${CMAKE_CXX_LINK_FLAGS} ${BIT_ENVIRONMENT}") - set(ICC_GE_9 12) - set(ICC_GE_101 120) - endif(ICC_MAJOR EQUAL 12) + set(CINT_CXX_DEFINITIONS "-DG__REGEXP -DG__UNIX -DG__SHAREDLIB -DG__OSFDLL -DG__ROOT -DG__REDIRECTIO -DG__STD_EXCEPTION ${SPECIAL_CINT_FLAGS}") + set(CINT_C_DEFINITIONS "-DG__REGEXP -DG__UNIX -DG__SHAREDLIB -DG__OSFDLL -DG__ROOT -DG__REDIRECTIO -DG__STD_EXCEPTION ${SPECIAL_CINT_FLAGS}") - - set(CMAKE_SHARED_LIBRARY_CREATE_C_FLAGS "${CMAKE_SHARED_LIBRARY_CREATE_C_FLAGS}") - set(CMAKE_SHARED_LIBRARY_CREATE_CXX_FLAGS "${CMAKE_SHARED_LIBRARY_CREATE_CXX_FLAGS}") - - - # Select flags. - set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O0 -g") - set(CMAKE_CXX_FLAGS_RELEASE "-O") - set(CMAKE_CXX_FLAGS_DEBUG "-g -O") - set(CMAKE_C_FLAGS_RELWITHDEBINFO "-O0 -g") - set(CMAKE_C_FLAGS_RELEASE "-O") - set(CMAKE_C_FLAGS_DEBUG "-g -O2") - - #Settings for cint - set(CPPPREP "${CMAKE_CXX_COMPILER} -E -C") - set(CXXOUT "-o ") - set(EXPLICITLINK "no") #TODO - - set(EXEEXT "") - set(SOEXT "so") - else(${CMAKE_CXX_COMPILER} MATCHES "icpc") - endif(${CMAKE_CXX_COMPILER} MATCHES "icpc") -endif(CMAKE_COMPILER_IS_GNUCXX) + # Check icc compiler version and set compile flags according to the + execute_process(COMMAND ${CMAKE_CXX_COMPILER} -v + ERROR_VARIABLE _icc_version_info ERROR_STRIP_TRAILING_WHITESPACE) + + string(REGEX REPLACE "(^V|^icc[ ]v|^icpc[ ]v)ersion[ ]([0-9]+)\\.[0-9]+.*" "\\2" ICC_MAJOR "${_icc_version_info}") + string(REGEX REPLACE "(^V|^icc[ ]v|^icpc[ ]v)ersion[ ][0-9]+\\.([0-9]+).*" "\\2" ICC_MINOR "${_icc_version_info}") + + message(STATUS "Found ICC major version ${ICC_MAJOR}") + message(STATUS "Found ICC minor version ${ICC_MINOR}") + + if(ICC_MAJOR EQUAL 9) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -wd1572") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -wd1572") + set(ICC_GE_9 9) + endif() + + if(ICC_MAJOR EQUAL 10) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -wd1572") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -wd1572") + set(ICC_GE_9 10) + if(ICC_MINOR GREATER 0) + set(ICC_GE_101 101) + endif() + endif() + + if(ICC_MAJOR EQUAL 11) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${BIT_ENVIRONMENT} -wd1572 -wd279") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${BIT_ENVIRONMENT} -wd1572 -wd279") + set(CMAKE_SHARED_LINKER_FLAGS "${BIT_ENVIRONMENT} -Wl,--no-undefined") + #set(CMAKE_C_LINK_FLAGS "${CMAKE_C_LINK_FLAGS} ${BIT_ENVIRONMENT}") + #set(CMAKE_CXX_LINK_FLAGS "${CMAKE_CXX_LINK_FLAGS} ${BIT_ENVIRONMENT}") + set(ICC_GE_9 11) + set(ICC_GE_101 110) + endif() + + if(ICC_MAJOR EQUAL 12) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${BIT_ENVIRONMENT} -wd1572 -wd279") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${BIT_ENVIRONMENT} -wd1572 -wd279") + set(CMAKE_SHARED_LINKER_FLAGS "${BIT_ENVIRONMENT} -Wl,--no-undefined") + #set(CMAKE_C_LINK_FLAGS "${CMAKE_C_LINK_FLAGS} ${BIT_ENVIRONMENT}") + #set(CMAKE_CXX_LINK_FLAGS "${CMAKE_CXX_LINK_FLAGS} ${BIT_ENVIRONMENT}") + set(ICC_GE_9 12) + set(ICC_GE_101 120) + endif() + + + set(CMAKE_SHARED_LIBRARY_CREATE_C_FLAGS "${CMAKE_SHARED_LIBRARY_CREATE_C_FLAGS}") + set(CMAKE_SHARED_LIBRARY_CREATE_CXX_FLAGS "${CMAKE_SHARED_LIBRARY_CREATE_CXX_FLAGS}") + + + # Select flags. + set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O0 -g") + set(CMAKE_CXX_FLAGS_RELEASE "-O") + set(CMAKE_CXX_FLAGS_DEBUG "-g -O") + set(CMAKE_C_FLAGS_RELWITHDEBINFO "-O0 -g") + set(CMAKE_C_FLAGS_RELEASE "-O") + set(CMAKE_C_FLAGS_DEBUG "-g -O2") + + #Settings for cint + set(CPPPREP "${CMAKE_CXX_COMPILER} -E -C") + set(CXXOUT "-o ") + set(EXPLICITLINK "no") #TODO + + set(EXEEXT "") + set(SOEXT "so") + +endif() diff --git a/cmake/modules/SetUpMacOS.cmake b/cmake/modules/SetUpMacOS.cmake index 190195b57b498..02f83a539782d 100644 --- a/cmake/modules/SetUpMacOS.cmake +++ b/cmake/modules/SetUpMacOS.cmake @@ -19,7 +19,18 @@ if (CMAKE_SYSTEM_NAME MATCHES Darwin) EXECUTE_PROCESS(COMMAND sw_vers "-productVersion" COMMAND cut -d . -f 2 OUTPUT_VARIABLE MACOSX_MINOR OUTPUT_STRIP_TRAILING_WHITESPACE) - + + if(MACOSX_VERSION VERSION_GREATER 10.8 AND ${CMAKE_CXX_COMPILER_ID} STREQUAL Clang) + set(libcxx ON CACHE BOOL "Build using libc++" FORCE) + endif() + + if(c++11) + set(CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS} -std=c++11) + endif() + if(libcxx) + set(CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS} -stdlib=libc++) + endif() + if(${MACOSX_MINOR} GREATER 4) #TODO: check haveconfig and rpath -> set rpath true #TODO: check Thread, define link command diff --git a/cmake/modules/SetUpWindows.cmake b/cmake/modules/SetUpWindows.cmake index d9e27d755c4de..4b5d3968528e9 100644 --- a/cmake/modules/SetUpWindows.cmake +++ b/cmake/modules/SetUpWindows.cmake @@ -15,18 +15,27 @@ set(CRYPTLIBS) #---Select compiler flags---------------------------------------------------------------- set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -Z7") set(CMAKE_CXX_FLAGS_RELEASE "-O2") -set(CMAKE_CXX_FLAGS_DEBUG "-Z7") +set(CMAKE_CXX_FLAGS_DEBUG "-Od -Z7") set(CMAKE_C_FLAGS_RELWITHDEBINFO "-O2 -Z7") set(CMAKE_C_FLAGS_RELEASE "-O2") -set(CMAKE_C_FLAGS_DEBUG "-Z7") +set(CMAKE_C_FLAGS_DEBUG "-Od -Z7") + +if(winrtdebug) + set(BLDCXXFLAGS "-MDd -GR") + set(BLDCFLAGS "-MDd") +else() + set(BLDCXXFLAGS "-MD -GR") + set(BLDCFLAGS "-MD") +endif() if(CMAKE_PROJECT_NAME STREQUAL ROOT) - set(CMAKE_CXX_FLAGS "-nologo -I${CMAKE_SOURCE_DIR}/build/win -FIw32pragma.h -FIsehmap.h -MD -GR -EHsc- -W3 -wd4244 -D_WIN32") - set(CMAKE_C_FLAGS "-nologo -I${CMAKE_SOURCE_DIR}/build/win -FIw32pragma.h -FIsehmap.h -MD -EHsc- -W3 -D_WIN32") - install(FILES ${CMAKE_SOURCE_DIR}/build/win/w32pragma.h DESTINATION include COMPONENT headers) + set(CMAKE_CXX_FLAGS "-nologo -I${CMAKE_SOURCE_DIR}/build/win -FIw32pragma.h -FIsehmap.h ${BLDCXXFLAGS} -EHsc- -W3 -wd4244 -D_WIN32") + set(CMAKE_C_FLAGS "-nologo -I${CMAKE_SOURCE_DIR}/build/win -FIw32pragma.h -FIsehmap.h ${BLDCFLAGS} -EHsc- -W3 -D_WIN32") + install(FILES ${CMAKE_SOURCE_DIR}/build/win/w32pragma.h DESTINATION ${CMAKE_INSTALL_INCDIR} COMPONENT headers) + install(FILES ${CMAKE_SOURCE_DIR}/build/win/sehmap.h DESTINATION ${CMAKE_INSTALL_INCDIR} COMPONENT headers) else() - set(CMAKE_CXX_FLAGS "-nologo -FIw32pragma.h -FIsehmap.h -MD -GR -EHsc- -W3 -wd4244 -D_WIN32") - set(CMAKE_C_FLAGS "-nologo -FIw32pragma.h -FIsehmap.h -MD -EHsc- -W3 -D_WIN32") + set(CMAKE_CXX_FLAGS "-nologo -FIw32pragma.h -FIsehmap.h ${BLDCXXFLAGS} -EHsc- -W3 -wd4244 -D_WIN32") + set(CMAKE_C_FLAGS "-nologo -FIw32pragma.h -FIsehmap.h ${BLDCFLAGS} -EHsc- -W3 -D_WIN32") endif() #---Set Linker flags---------------------------------------------------------------------- diff --git a/cmake/scripts/CMakeLists.template b/cmake/scripts/CMakeLists.template deleted file mode 100644 index 5b56c3f9c557e..0000000000000 --- a/cmake/scripts/CMakeLists.template +++ /dev/null @@ -1,69 +0,0 @@ -# Build ${libname} -# Define all header and source files which are needed -# to build the MathCore library - -Set(libname ) - -# Find all headers except the LinkDef file and copy -# them to the include subdirectory of the build directory -File(GLOB ${libname}Headers "${CMAKE_CURRENT_SOURCE_DIR}" - "${CMAKE_CURRENT_SOURCE_DIR}/inc/*.h" - ) -List(REMOVE_ITEM ${libname}Headers - "${CMAKE_CURRENT_SOURCE_DIR}" - "${CMAKE_CURRENT_SOURCE_DIR}/inc/LinkDef.h" - ) - -INSTALL_HEADERS("${libname}Headers") - -# Find all source files -File(GLOB ${libname}Source "${CMAKE_CURRENT_SOURCE_DIR}" - "${CMAKE_CURRENT_SOURCE_DIR}/src/*.cxx" - ) -List(REMOVE_ITEM ${libname}Source - "${CMAKE_CURRENT_SOURCE_DIR}" - ) - -# Define the LinkDef and the output file which are needed -# to create the dictionary. -# Definde the needed include directories and create the Dictionary -Set(LinkDef ${CMAKE_CURRENT_SOURCE_DIR}/inc/LinkDef.h) -Set(Dictionary ${CMAKE_CURRENT_BINARY_DIR}/G__${libname}.cxx) - -Set(INCLUDE_DIRS - ${CMAKE_SOURCE_DIR}/hist/hist/inc - ${CMAKE_SOURCE_DIR}/cint/cint/include - ${CMAKE_SOURCE_DIR}/cint/cint/stl - ${CMAKE_SOURCE_DIR}/cint/cint/lib -) - - -GENERATE_DICTIONARY("${${libname}Headers}" - "${LinkDef}" "${Dictionary}" - "${INCLUDE_DIRS}" "" - ) - -Set(INCLUDE_DIRECTORIES - ${CMAKE_CURRENT_SOURCE_DIR}/inc -# ${CMAKE_SOURCE_DIR}/hist/hist/inc -# ${CMAKE_SOURCE_DIR}/core/meta/inc -# ${CMAKE_SOURCE_DIR}/core/base/inc - ${ROOT_INCLUDE_DIR} - ) - -Set(DEPENDENCIES ) - -GENERATE_ROOTMAP("${LinkDef}" ${libname} ${DEPENDENCIES}) - -include_directories( ${INCLUDE_DIRECTORIES}) - -# Here all objects ar put together into one share library -Add_Library(${libname} SHARED ${${libname}Source} ${Dictionary}) -Target_Link_Libraries(${libname} ${DEPENDENCIES} ${CMAKE_THREAD_LIBS_INIT}) -Set_Target_properties(${libname} PROPERTIES ${ROOT_LIBRARY_PROPERTIES}) -Install(TARGETS ${libname} DESTINATION ${LIB_INSTALL_DIR}) - - -# Define all the header files which should be installed when -# doing a "make install" -Install(FILES ${${libname}Headers} DESTINATION ${INCLUDE_INSTALL_DIR}) diff --git a/cmake/scripts/Makefile-comp.in b/cmake/scripts/Makefile-comp.in deleted file mode 100644 index 3ca46585ba21f..0000000000000 --- a/cmake/scripts/Makefile-comp.in +++ /dev/null @@ -1,10 +0,0 @@ -# -*- mode: makefile -*- -# -# Makefile compiler definitions included by the top Makefile. -# Used to override the compilers specified in the architecture -# specific Makefiles. - -CC ="@CMAKE_C_COMPILER@" -CXX ="@CMAKE_CXX_COMPILER@" -F77 ="@CMAKE_Fortran_COMPILER@" -LD ="@CMAKE_CXX_COMPILER@" diff --git a/cmake/scripts/RConfigOptions.in b/cmake/scripts/RConfigOptions.in deleted file mode 100644 index 4598a382c4e6d..0000000000000 --- a/cmake/scripts/RConfigOptions.in +++ /dev/null @@ -1,7 +0,0 @@ -#ifndef ROOT_RConfigOptions -#define ROOT_RConfigOptions - -#define R__CONFIGUREOPTIONS "@RootConfigOptions@" -#define R__CONFIGUREFEATURES "@RootConfigFeatures@" - -#endif diff --git a/cmake/scripts/RConfigure.in b/cmake/scripts/RConfigure.in deleted file mode 100644 index ef1720561a5b2..0000000000000 --- a/cmake/scripts/RConfigure.in +++ /dev/null @@ -1,26 +0,0 @@ -#ifndef ROOT_RConfigure -#define ROOT_RConfigure - -/* Configurations file for @ROOT_ARCHITECTURE@ */ -#ifdef R__HAVE_CONFIG -#define ROOTPREFIX "@ROOT_INSTALL_DIR@" -#define ROOTBINDIR "@BIN_INSTALL_DIR@" -#define ROOTLIBDIR "@LIB_INSTALL_DIR@" -#define ROOTINCDIR "@INCLUDE_INSTALL_DIR@" -#define ROOTETCDIR "@ETC_INSTALL_DIR@" -#define ROOTDATADIR "@DATA_INSTALL_DIR@" -#define ROOTDOCDIR "@DOC_INSTALL_DIR@" -#define ROOTMACRODIR "@MACRO_INSTALL_DIR@" -#define ROOTSRCDIR "@SRC_INSTALL_DIR@" -#define ROOTICONPATH "@ICON_INSTALL_DIR@" -#define EXTRAICONPATH "@EXTRA_ICON_INSTALL_DIR@" -#define TTFFONTDIR "@FONT_INSTALL_DIR@" -#define CINTINCDIR "@CINT_INSTALL_DIR@" -#endif - -#cmakedefine R__HAS_SETRESUID /**/ -#cmakedefine R__HAS_MATHMORE /**/ -#cmakedefine R__HAS_PTHREAD /**/ -#cmakedefine R__HAS_XFT /**/ - -#endif diff --git a/cmake/scripts/ROOTConfig.cmake.in b/cmake/scripts/ROOTConfig.cmake.in index 1657d8385ab62..d94c8907c51f6 100644 --- a/cmake/scripts/ROOTConfig.cmake.in +++ b/cmake/scripts/ROOTConfig.cmake.in @@ -1,12 +1,16 @@ # ROOT CMake Configuration File for External Projects -# This file is configured by Geant4 for use by an external project +# This file is configured by ROOT for use by an external project # As this file is configured by ROOT's CMake system it SHOULD NOT BE EDITED # It defines the following variables -# ROOT_INCLUDE_DIRS - include directories for Geant4 -# ROOT_DEFINITIONS - compile definitions needed to use Geant4 +# ROOT_INCLUDE_DIRS - include directories for ROOT +# ROOT_DEFINITIONS - compile definitions needed to use ROOT # ROOT_LIBRARIES - libraries to link against # ROOT_USE_FILE - path to a CMake module which may be included to help # setup CMake variables and useful Macros +# Addional variables: +# ROOT_${lib}_LIBRARY - library full path +# ROOT_${tool}_CMD - executable full path +# ROOT_EXECUTABLE - same as ${ROOT_root_CMD} # # You may supply a version number through find_package which will be checked # against the version of this build. Standard CMake logic is used so that @@ -16,20 +20,16 @@ # VERSION_OF_THIS_BUILD >= VERSION_REQUESTED # # -# In Geant4, components can be optional subcomponents of an always available -# library. In that case there will be no Geant4_{COMPONENT}_LIBRARY variable. -# These non-library components are generally activated by compile definitions, -# and in these cases the appropriate definition will be added to the -# Geant4_DEFINITIONS component -# # If you specify components and use the REQUIRED option to find_package, then -# the module will issue a FATAL_ERROR if this build of Genat4 does not have -# the requested component(s). +# the module will issue a FATAL_ERROR if this build of ROOT does not have +# the requested component(s). Components are any optional ROOT library, which +# will be added into the ROOT_LIBRARIES variable. # # The list of options available generally corresponds to the optional extras # that ROOT can be built are also made available to the dependent project as # ROOT_{option}_FOUND # +# # =========================================================================== #---------------------------------------------------------------------------- @@ -52,10 +52,12 @@ endif() get_filename_component(_thisdir "${CMAKE_CURRENT_LIST_FILE}" PATH) #---------------------------------------------------------------------------- -# Configure the path to the Geant4 headers, using a relative path if possible. +# Configure the path to the ROOT headers, using a relative path if possible. # This is only known at CMake time, so we expand a CMake supplied variable. # @ROOT_INCLUDE_DIR_SETUP@ +@ROOT_LIBRARY_DIR_SETUP@ +@ROOT_BINARY_DIR_SETUP@ @ROOT_MODULE_PATH_SETUP@ #---------------------------------------------------------------------------- @@ -74,11 +76,36 @@ endforeach() #---------------------------------------------------------------------------- # Now set them to ROOT_LIBRARIES -set(ROOT_LIBRARIES Core Cint) +set(ROOT_LIBRARIES) +foreach(_cpt Core Cint ${ROOT_FIND_COMPONENTS}) + find_library(ROOT_${_cpt}_LIBRARY ${_cpt} HINTS ${ROOT_LIBRARY_DIR}) + if(ROOT_${_cpt}_LIBRARY) + mark_as_advanced(ROOT_${_cpt}_LIBRARY) + list(APPEND ROOT_LIBRARIES ${ROOT_${_cpt}_LIBRARY}) + list(REMOVE_ITEM ROOT_FIND_COMPONENTS ${_cpt}) + endif() +endforeach() + +#---------------------------------------------------------------------------- +# Locate the tools +set(ROOT_ALL_TOOLS genreflex genmap root rootcint) +foreach(_cpt ${ROOT_ALL_TOOLS}) + if(NOT ROOT_${_cpt}_CMD) + find_program(ROOT_${_cpt}_CMD ${_cpt} HINTS ${ROOT_BINARY_DIR}) + if(ROOT_${_cpt}_CMD) + mark_as_advanced(ROOT_${_cpt}_CMD) + list(REMOVE_ITEM ROOT_FIND_COMPONENTS ${_cpt}) + endif() + endif() +endforeach() + +#---------------------------------------------------------------------------- +set(ROOT_DEFINITIONS @cflags@) +set(ROOT_EXECUTABLE ${ROOT_root_CMD}) #---------------------------------------------------------------------------- -# Point the user to the UseGeant4.cmake file which they may wish to include -# to help them with setting up Geant4 +# Point the user to the ROOTUseFile.cmake file which they may wish to include +# to help them with setting up ROOT # set(ROOT_USE_FILE ${_thisdir}/ROOTUseFile.cmake) @@ -90,10 +117,10 @@ set(ROOT_USE_FILE ${_thisdir}/ROOTUseFile.cmake) # list(REMOVE_DUPLICATES ROOT_FIND_COMPONENTS) foreach(_remaining ${ROOT_FIND_COMPONENTS}) - if(ROOT_FIND_REQUIRED) + if(ROOT_FIND_REQUIRED_${_remaining}) message(FATAL_ERROR "ROOT component ${_remaining} not found") elseif(NOT ROOT_FIND_QUIETLY) message(WARNING " ROOT component ${_remaining} not found") endif() - unset(Geant4_FIND_REQUIRED_${_remaining}) + unset(ROOT_FIND_REQUIRED_${_remaining}) endforeach() diff --git a/cmake/scripts/configcint.h b/cmake/scripts/configcint.h deleted file mode 100644 index 172ac1984692d..0000000000000 --- a/cmake/scripts/configcint.h +++ /dev/null @@ -1,48 +0,0 @@ -/* Generated by cint/Module.mk */ -#define G__CFG_ARCH "macosx64" -#define G__CFG_IMPLIBEXT ".dylib" -#define G__CFG_LDOUT "-o " -#define G__CFG_LIBL "-l@imp@" -#define G__CFG_LIBEXT ".a" -#define G__CFG_MANGLEPATHS "echo " -#define G__CFG_PLATFORMO "" -#define G__CFG_AR "ar qcs" -#define G__CFG_COREVERSION "cint" -#define G__CFG_CC "gcc" -#define G__CFG_CFLAGS "-m64 -pipe -W -Wall -fsigned-char -fno-common -Iinclude -DG__REGEXP -DG__UNIX -DG__SHAREDLIB -DG__ROOT -DG__REDIRECTIO -DG__OSFDLL -DG__STD_EXCEPTION -DG__HAVE_CONFIG -DG__NOMAKEINFO -DG__CINTBODY -Icint/cint/inc -Icint/cint/src -Icint/cint/src/dict" -#define G__CFG_CMACROS "-DG__REGEXP -DG__UNIX -DG__SHAREDLIB -DG__ROOT -DG__REDIRECTIO -DG__OSFDLL -DG__STD_EXCEPTION -DG__HAVE_CONFIG -DG__NOMAKEINFO -DG__CINTBODY" -#define G__CFG_COMP "-c " -#define G__CFG_CPP "g++ -E -C" -#define G__CFG_COUT "-o " -#define G__CFG_COUTEXE "-o " -#define G__CFG_INCP "-I" -#define G__CFG_CXX "g++" -#define G__CFG_CXXFLAGS "-m64 -pipe -W -Wall -Woverloaded-virtual -fsigned-char -fno-common -Iinclude -DG__REGEXP -DG__UNIX -DG__SHAREDLIB -DG__ROOT -DG__REDIRECTIO -DG__OSFDLL -DG__STD_EXCEPTION -DG__HAVE_CONFIG -DG__NOMAKEINFO -DG__CINTBODY -Icint/cint/inc -Icint/cint/src -Icint/cint/src/dict" -#define G__CFG_CXXMACROS "-DG__REGEXP -DG__UNIX -DG__SHAREDLIB -DG__ROOT -DG__REDIRECTIO -DG__OSFDLL -DG__STD_EXCEPTION -DG__HAVE_CONFIG -DG__NOMAKEINFO -DG__CINTBODY" -#define G__CFG_LD "g++" -#define G__CFG_LDFLAGS "-O2 -m64 -bind_at_load" -#define G__CFG_LIBP "-L" -#define G__CFG_SOFLAGS "-O2 -dynamiclib -single_module -undefined dynamic_lookup -install_name @rpath/" -#define G__CFG_SOOUT G__CFG_LDOUT -#define G__CFG_OBJEXT ".o" -#define G__CFG_EXEEXT "" -#define G__CFG_SOEXT ".so" -#define G__CFG_DEBUG "" -#define G__CFG_DEFAULTLIBS "-lm -Wl,-rpath,@loader_path/../lib -pthread -ldl" -#define G__CFG_DEFAULTLIBS "-lm -Wl,-rpath,@loader_path/../lib -pthread -ldl" -#define G__CFG_STREAMDIR "" -#define G__CFG_EXPLLINK "no" -#define G__CFG_BUILDREADLINE "" -#define G__CFG_READLINELIBDIR "" -#define G__CFG_READLINEINCDIR "" -#define G__CFG_NEEDCURSES "" -#define G__CFG_RM "rm -f" -#define G__CFG_MV "mv -f" -#define G__CFG_INPUTMODE "root" -#define G__CFG_INPUTMODELOCK "off" -#define G__CFG_MAKEIMPLIB "" -#define G__CFG_CINTSYSDIR "/Users/uhlig/software/root" -#define G__CFG_HAVE_CONFIG "1" -#define CINTSYSDIR "/Users/uhlig/software/root" -#define G__CFG_MAKEIMPLIB "" -#define G__CFG_HAVE_CONFIG "1" diff --git a/cmake/scripts/configcint.in b/cmake/scripts/configcint.in deleted file mode 100644 index d0a33b4385ba5..0000000000000 --- a/cmake/scripts/configcint.in +++ /dev/null @@ -1,92 +0,0 @@ -# Murkily include to build cint/inc/configcint.h (aka $@) - -$(CINTCONF): config/Makefile.$(ARCH) config/Makefile.comp $(CINTCONFMK) - @-rm -f $@__ - @echo '/* Generated by cint/Module.mk */' > $@__ - @( case $(ARCH) in \ - win32) \ - if [ $(VC_MAJOR) -ge 14 ]; then \ - echo '#define G__CFG_ARCH "msvc8"' >> $@__; \ - else \ - echo '#define G__CFG_ARCH "msvc7"' >> $@__; \ - fi && \ - echo '#define G__CFG_LDOUT "-out:"' >> $@__ && \ - echo '#define G__CFG_LIBL "lib@imp@"' >> $@__ && \ - echo '#define G__CFG_LIBEXT ".lib"' >> $@__ && \ - echo '#define G__CFG_IMPLIBEXT ".lib"' >> $@__ && \ - echo '#define G__CFG_MANGLEPATHS "cygpath -m "' >> $@__ && \ - echo '#define G__CFG_PLATFORMO "v6_winnt"' >> $@__ && \ - echo '#define G__CFG_AR "lib /OUT:"' >> $@__ ;;\ - *) case $(ARCH) in \ - macosx*) \ - echo '#define G__CFG_ARCH "$(ARCH)"' >> $@__ && \ - echo '#define G__CFG_IMPLIBEXT ".dylib"' >> $@__ ;; \ - win32gcc) \ - echo '#define G__CFG_ARCH "cygwin"' >> $@__ && \ - echo '#define G__CFG_IMPLIBEXT ".a"' >> $@__ ;; \ - *) \ - echo '#define G__CFG_ARCH "$(ARCH)"' >> $@__ && \ - echo '#define G__CFG_IMPLIBEXT ".a"' >> $@__ ;; \ - esac && \ - echo '#define G__CFG_LDOUT "-o "' >> $@__ && \ - echo '#define G__CFG_LIBL "-l@imp@"' >> $@__ && \ - echo '#define G__CFG_LIBEXT ".a"' >> $@__ && \ - echo '#define G__CFG_MANGLEPATHS "echo "' >> $@__ && \ - echo '#define G__CFG_PLATFORMO ""' >> $@__ && \ - echo '#define G__CFG_AR "ar qcs"' >> $@__ ;; \ - esac && \ - echo '#define G__CFG_COREVERSION "$(patsubst cint/%/inc/,%,$(dir $@))"' >> $@__ && \ - echo '#define G__CFG_CC "$(CC)"' >> $@__ && \ - echo '#define G__CFG_CFLAGS "$(CINTCFLAGS)"' >> $@__ && \ - echo '#define G__CFG_CMACROS "$(filter -D%,$(CINTCFLAGS))"' >> $@__ && \ - echo '#define G__CFG_COMP "-c "' >> $@__ && \ - echo '#define G__CFG_CPP "$(CPPPREP)"' >> $@__ && \ - echo '#define G__CFG_COUT "$(CXXOUT)"' >> $@__ && \ - echo '#define G__CFG_COUTEXE "$(CXXOUT)"' >> $@__ && \ - echo '#define G__CFG_INCP "-I"' >> $@__ && \ - echo '#define G__CFG_CXX "$(CXX)"' >> $@__ && \ - echo '#define G__CFG_CXXFLAGS "$(CINTCXXFLAGS)"' >> $@__ && \ - echo '#define G__CFG_CXXMACROS "$(filter -D%,$(CINTCXXFLAGS))"' >> $@__ && \ - echo '#define G__CFG_LD "$(LD)"' >> $@__ && \ - echo '#define G__CFG_LDFLAGS "$(LDFLAGS)"' >> $@__ && \ - echo '#define G__CFG_LIBP "-L"' >> $@__ && \ - echo '#define G__CFG_SOFLAGS "$(SOFLAGS)"' >> $@__ && \ - echo '#define G__CFG_SOOUT G__CFG_LDOUT' >> $@__ && \ - echo '#define G__CFG_OBJEXT ".o"' >> $@__ && \ - echo '#define G__CFG_EXEEXT "$(EXEEXT)"' >> $@__ && \ - echo '#define G__CFG_SOEXT ".$(SOEXT)"' >> $@__ && \ - echo '#define G__CFG_DEBUG "$(DEBUG)"' >> $@__ && \ - echo '#define G__CFG_DEFAULTLIBS "$(SYSLIBS)"' >> $@__ && \ - echo '#define G__CFG_DEFAULTLIBS "$(SYSLIBS)"' >> $@__ && \ - echo '#define G__CFG_STREAMDIR "$(patsubst $(MODDIRS)/%strm.cxx,%,$(filter $(MODDIRS)/%strm.cxx, $(CINTS2)))"' >> $@__ && \ - echo '#define G__CFG_EXPLLINK "$(EXPLICITLINK)"' >> $@__ && \ - echo '#define G__CFG_BUILDREADLINE ""' >> $@__ && \ - echo '#define G__CFG_READLINELIBDIR ""' >> $@__ && \ - echo '#define G__CFG_READLINEINCDIR ""' >> $@__ && \ - echo '#define G__CFG_NEEDCURSES ""' >> $@__ && \ - echo '#define G__CFG_RM "rm -f"' >> $@__ && \ - echo '#define G__CFG_MV "mv -f"' >> $@__ && \ - echo '#define G__CFG_INPUTMODE "root"' >> $@__ && \ - echo '#define G__CFG_INPUTMODELOCK "off"' >> $@__ && \ - echo '#define G__CFG_MAKEIMPLIB ""' >> $@__ && \ - echo '#define G__CFG_CINTSYSDIR "$(PWD)"' >> $@__ && \ - echo '#define G__CFG_HAVE_CONFIG "1"' >> $@__ && \ - echo '#define CINTSYSDIR "$(PWD)"' >> $@__ && \ - echo '#define G__CFG_MAKEIMPLIB ""' >> $@__ && \ - echo '#define G__CFG_HAVE_CONFIG "1"' >> $@__ \ - ) - @(if [ -r $@ ]; then \ - diff $@__ $@ > /dev/null; status=$$?; \ - if [ "$$status" -ne 0 ]; then \ - echo "Running cint/configcint.mk"; \ - echo "Changing $@"; \ - mv $@__ $@; \ - else \ - rm -f $@__; \ - fi \ - else \ - echo "Running cint/configcint.mk"; \ - echo "Making $@"; \ - mv $@__ $@; \ - fi \ - ) diff --git a/cmake/scripts/configcint.mk b/cmake/scripts/configcint.mk deleted file mode 100644 index b787ae5e6bc93..0000000000000 --- a/cmake/scripts/configcint.mk +++ /dev/null @@ -1,100 +0,0 @@ -# Makefile include to build cint[7]/inc/configcint.h (aka $@) - -# Set these variables now for the current value of $(G__CFG_CONF). -# They might be changed (by cint/Module.mk or cint7/Module.mk) later -$(G__CFG_CONF): G__CFG_CXXFLAGS := $(CINTCXXFLAGS) -$(G__CFG_CONF): G__CFG_CFLAGS := $(CINTCFLAGS) -$(G__CFG_CONF): G__CFG_DIR := $(CINTDIR) -$(G__CFG_CONF): G__CFG_CONF := $(CINTCONF) -$(G__CFG_CONF): G__CFG_CONFMK := $(CINTCONFMK) - -$(G__CFG_CONF): config/Makefile.$(ARCH) config/Makefile.comp $(G__CFG_CONFMK) - @-rm -f $@__ - @echo '/* Generated by cint/Module.mk */' > $@__ - @( case $(ARCH) in \ - win32) \ - if [ $(VC_MAJOR) -ge 14 ]; then \ - echo '#define G__CFG_ARCH "msvc8"' >> $@__; \ - else \ - echo '#define G__CFG_ARCH "msvc7"' >> $@__; \ - fi && \ - echo '#define G__CFG_LDOUT "-out:"' >> $@__ && \ - echo '#define G__CFG_LIBL "lib@imp@"' >> $@__ && \ - echo '#define G__CFG_LIBEXT ".lib"' >> $@__ && \ - echo '#define G__CFG_IMPLIBEXT ".lib"' >> $@__ && \ - echo '#define G__CFG_MANGLEPATHS "cygpath -m "' >> $@__ && \ - echo '#define G__CFG_PLATFORMO "v6_winnt"' >> $@__ && \ - echo '#define G__CFG_AR "lib /OUT:"' >> $@__ ;;\ - *) case $(ARCH) in \ - macosx*) \ - echo '#define G__CFG_ARCH "$(ARCH)"' >> $@__ && \ - echo '#define G__CFG_IMPLIBEXT ".dylib"' >> $@__ ;; \ - win32gcc) \ - echo '#define G__CFG_ARCH "cygwin"' >> $@__ && \ - echo '#define G__CFG_IMPLIBEXT ".a"' >> $@__ ;; \ - *) \ - echo '#define G__CFG_ARCH "$(ARCH)"' >> $@__ && \ - echo '#define G__CFG_IMPLIBEXT ".a"' >> $@__ ;; \ - esac && \ - echo '#define G__CFG_LDOUT "-o "' >> $@__ && \ - echo '#define G__CFG_LIBL "-l@imp@"' >> $@__ && \ - echo '#define G__CFG_LIBEXT ".a"' >> $@__ && \ - echo '#define G__CFG_MANGLEPATHS "echo "' >> $@__ && \ - echo '#define G__CFG_PLATFORMO ""' >> $@__ && \ - echo '#define G__CFG_AR "ar qcs"' >> $@__ ;; \ - esac && \ - echo '#define G__CFG_COREVERSION "$(patsubst cint/%/inc/,%,$(dir $@))"' >> $@__ && \ - echo '#define G__CFG_CC "$(CC)"' >> $@__ && \ - echo '#define G__CFG_CFLAGS "$(G__CFG_CFLAGS)"' >> $@__ && \ - echo '#define G__CFG_CMACROS "$(filter -D%,$(G__CFG_CFLAGS))"' >> $@__ && \ - echo '#define G__CFG_COMP "-c "' >> $@__ && \ - echo '#define G__CFG_CPP "$(CPPPREP)"' >> $@__ && \ - echo '#define G__CFG_COUT "$(CXXOUT)"' >> $@__ && \ - echo '#define G__CFG_COUTEXE "$(CXXOUT)"' >> $@__ && \ - echo '#define G__CFG_INCP "-I"' >> $@__ && \ - echo '#define G__CFG_CXX "$(CXX)"' >> $@__ && \ - echo '#define G__CFG_CXXFLAGS "$(G__CFG_CXXFLAGS)"' >> $@__ && \ - echo '#define G__CFG_CXXMACROS "$(filter -D%,$(G__CFG_CXXFLAGS))"' >> $@__ && \ - echo '#define G__CFG_LD "$(LD)"' >> $@__ && \ - echo '#define G__CFG_LDFLAGS "$(LDFLAGS)"' >> $@__ && \ - echo '#define G__CFG_LIBP "-L"' >> $@__ && \ - echo '#define G__CFG_SOFLAGS "$(SOFLAGS)"' >> $@__ && \ - echo '#define G__CFG_SOOUT G__CFG_LDOUT' >> $@__ && \ - echo '#define G__CFG_OBJEXT ".o"' >> $@__ && \ - echo '#define G__CFG_EXEEXT "$(EXEEXT)"' >> $@__ && \ - echo '#define G__CFG_SOEXT ".$(SOEXT)"' >> $@__ && \ - echo '#define G__CFG_DEBUG "$(DEBUG)"' >> $@__ && \ - echo '#define G__CFG_DEFAULTLIBS "$(SYSLIBS)"' >> $@__ && \ - echo '#define G__CFG_DEFAULTLIBS "$(SYSLIBS)"' >> $@__ && \ - echo '#define G__CFG_STREAMDIR "$(patsubst $(MODDIRS)/%strm.cxx,%,$(filter $(MODDIRS)/%strm.cxx, $(CINTS2)))"' >> $@__ && \ - echo '#define G__CFG_EXPLLINK "$(EXPLICITLINK)"' >> $@__ && \ - echo '#define G__CFG_BUILDREADLINE ""' >> $@__ && \ - echo '#define G__CFG_READLINELIBDIR ""' >> $@__ && \ - echo '#define G__CFG_READLINEINCDIR ""' >> $@__ && \ - echo '#define G__CFG_NEEDCURSES ""' >> $@__ && \ - echo '#define G__CFG_RM "rm -f"' >> $@__ && \ - echo '#define G__CFG_MV "mv -f"' >> $@__ && \ - echo '#define G__CFG_INPUTMODE "root"' >> $@__ && \ - echo '#define G__CFG_INPUTMODELOCK "off"' >> $@__ && \ - echo '#define G__CFG_MAKEIMPLIB ""' >> $@__ && \ - echo '#define G__CFG_CINTSYSDIR "$(PWD)"' >> $@__ && \ - echo '#define G__CFG_HAVE_CONFIG "1"' >> $@__ && \ - echo '#define CINTSYSDIR "$(PWD)"' >> $@__ && \ - echo '#define G__CFG_MAKEIMPLIB ""' >> $@__ && \ - echo '#define G__CFG_HAVE_CONFIG "1"' >> $@__ \ - ) - @(if [ -r $@ ]; then \ - diff $@__ $@ > /dev/null; status=$$?; \ - if [ "$$status" -ne 0 ]; then \ - echo "Running cint/configcint.mk"; \ - echo "Changing $@"; \ - mv $@__ $@; \ - else \ - rm -f $@__; \ - fi \ - else \ - echo "Running cint/configcint.mk"; \ - echo "Making $@"; \ - mv $@__ $@; \ - fi \ - ) diff --git a/cmake/scripts/genreflex-rootcint.in b/cmake/scripts/genreflex-rootcint.in deleted file mode 100644 index b34e14b61d333..0000000000000 --- a/cmake/scripts/genreflex-rootcint.in +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh -dir=@libdir@ -python ${dir}/python/genreflex/genreflex-rootcint.py "$@" diff --git a/cmake/scripts/genreflex.final.in b/cmake/scripts/genreflex.final.in deleted file mode 100644 index c7e417e8cab74..0000000000000 --- a/cmake/scripts/genreflex.final.in +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh -dir=@CMAKE_BINARY_DIR@ -python ${dir}/python/genreflex/genreflex.py "$@" diff --git a/cmake/scripts/genreflex.in b/cmake/scripts/genreflex.in deleted file mode 100644 index c7e417e8cab74..0000000000000 --- a/cmake/scripts/genreflex.in +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh -dir=@CMAKE_BINARY_DIR@ -python ${dir}/python/genreflex/genreflex.py "$@" diff --git a/cmake/scripts/memprobe.in b/cmake/scripts/memprobe.in deleted file mode 100644 index d759a49bb0e2f..0000000000000 --- a/cmake/scripts/memprobe.in +++ /dev/null @@ -1,309 +0,0 @@ -#!@perl@ - -################################################################################ -# -# Authors : D.Bertini and M.Ivanov -# Date: 23/10/2000 -# Updated: 10/05/2001 D.Bertini, v2.0 port to gdb5.0 + glibc2.2 -# -# -# To activate the memory checker you have to set in the .rootrc file -# the resource Root.MemCheck to 1 (e.g.: Root.MemCheck: 1) and you -# have to link with libNew.so (e.g. use root-config --new --libs) or -# use rootn.exe. When all this is the case you will find at the end -# of the program execution a file "memcheck.out" in the directory -# where you started your ROOT program. Alternatively you can set -# the resource Root.MemCheckFile to the name of a file to which -# the leak information will be written. The contents of this -# "memcheck.out" file can be analyzed and transformed into printable -# text via the memprobe program (in $ROOTSYS/bin). -# -################################################################################ - -if ( ( $#ARGV < 0 )) { -Usage(); -} - -use Getopt::Std; - -getopt "h,e,m,d,f"; -#Usage("exec file is mandatory !\n") if ( !($opt_h or $opt_e) ); - -if ( $opt_h ) { Usage();} -if ( $opt_e ) { $ExeFile=$opt_e; - }else { - if (!$opt_h){ Usage("an exec file must be provided !\n");} - } -if ( $opt_m ) { $MemStatFile=$opt_m; - }else{ - $MemStatFile="memcheck.out"; - } -if ( $opt_d ) { $MemDescFile=$opt_d; - }else{ - $MemDescFile="memcheckdesc.out"; - } - -if ( $opt_f ) { $MemFiltFile=$opt_f; - }else{ - $MemFiltFile="analfilter"; - } - - -sub Usage -{ - my ($txt) = @_; - - print "MemProbe v2.0 Usage:\n"; - print "\t $0 -e exec-file [options] [files] \n "; - print "\t-e \t\t\tname of analyzed program\n"; - print "Options: \n"; - print "\t-h \t\t\tthis usage help\n"; - print "\t-m \t\tname of analyzed program output file\n"; - print "\t-d \t\tname of the stat description file\n"; - print "\t-f \t\tname of the filter file\n"; - print "\nWarning: $txt\n" if $txt; - - exit 2; -} - - -# old version -#$ExeFile = shift @ARGV; -#$MemStatFile = $#ARGV >= 0 ? shift @ARGV : "memcheck.out"; - -open (MEMSTAT, $MemStatFile) or die "-E- Could not open leaks data file $MemStatFile: $!"; - -if ($#ARGV >= 0) { - $BreakOn = shift @ARGV; - # Rest in @ARGV are program arguments -} - - -############################################################################## -# Read filter expression -############################################################################## - -open (FILTERFILE, $MemFiltFile); -@FILTER = ; -close (FILTERFILE); -for ($j = 0; $j <= $#FILTER; ++$j){ - chop $FILTER[$j]; - # print $FILTER[$j]; -} - -############################################################################## -# Find leak adresses -############################################################################## - -$n = $u = 0; -$nfull = $ufull = 0; - -while () { - # remove newline - chop $_ ; - - if (/\s*(stack:)\s*/) { - $addrfull = $'; #obtain stack info - $_ = $addrfull; - s/(st)//g; - s/(0x)/:0x/g; - @arr = split(/:/); #obtain different leak points - for ($i = 1; $i < $#arr; ++$i){ - $addr = $arr[$i]; - $u++ if not exists $Size{$addr}; - $Size{$addr} += 0; - $n++; - } - } -} -close (MEMSTAT); - - -############################################################################## -# FIND debug info for addresses - information stored -# in file leak.desc.C -############################################################################## - - -# redirect standard output to the trash -open (STDERR,">/dev/null"); - -# Redirect list of commands to a file -# using unix pipes (needed for RH.7.1 & gdb5.0) - -open (myFile,">commands"); - -# Change set listsize 2 to something else to show more lines -print myFile "set prompt\nset listsize 1\nset height 0\nset verbose off\n"; - - -if (defined($BreakOn)) { - print myFile "break $BreakOn\n"; - print myFile "run ", join(" ", @ARGV), " \n"; -} -else{ - print myFile "break main \n "; - print myFile "run ", join(" ", @ARGV), " \n"; -} - -foreach (sort keys %Size) { - print myFile "l \*$_\n "; -} - -if (defined($BreakOn)) { - print myFile "kill\n"; -} -close (myFile); - -############################################################################## -# Calling now gdb services in batch mode using -# dumped list of commands. -# ==> works with gdb-4.18 gdb-5.0 release versions -############################################################################## - - -open (PIPE, "| gdb -n -q $ExeFile < commands > $MemDescFile") -or die "-E- Cannot start gdb !!!"; -close (PIPE); - - - -############################################################################## -# ASIGN debug info to address -############################################################################## - -open (DBGinfo, $MemDescFile) or die "-E- Could not open desc file $MemDescFile: $!"; -$addr =0; -while (){ - # if (/(0x[0-9a-f]+)\s*/){ - if (/(^0x[0-9a-f]+)/){ - $addr = $1; - #print $addr; - /is in /; - # print $'; - # print "\n"; - $filename{$addr} =$'; - # print "$addr $filename{$addr}\n"; - }else{ - $line{$addr} = $_ if ! /^\s*l/; - } - for ($j = 0; $j <= $#FILTER; ++$j){ - if ( ( $line{$addr} =~ /(${FILTER[$j]})/ ) || - ( $filename{$addr} =~ /(${FILTER[$j]})/ )){ - $line{$addr} = "filtered"; -} -} - -} -close (DBGinfo); - -############################################################################## -# FIND unique leak stack sequences -############################################################################## - -open (MEMSTAT, $MemStatFile) or die "-E- Could not open leaks data file $MemStatFile: $!"; - -while () { - # remove newline - chop $_ ; - if (/\s*(stack:)\s*/) { - $addrfull = $'; #obtain stack info - $info =$`; - $info =~ s/size //; #obtain mem info for given stack sequence - $_ = $addrfull; - s/(st)//g; - s/(0x)/:0x/g; - s/ //g; - @arr = split(/:/); #obtain leak points - $addrfull ="stack"; - $FilterOut=0; - for ($i = 1; ($i <= $#arr)&&($FilterOut==0); ++$i){ - $addr = $arr[$i]; - if ( $line{$addr} =~ /filtered/) - { - $FilterOut=1; - } - if ( $filename{$addr} =~ /\)/) - { - $addrfull .= ":"; - $addrfull .= $addr; - } - } - if ($FilterOut==0){ - $_= $info; - @meminfo = split(/:/); - $ufull++ if not exists $Sizefull{$addrfull}; - $SizeTotal{$addrfull} += $meminfo[1]; - $CountTotal{$addrfull}+= $meminfo[0]; - $SizeLeak{$addrfull} += $meminfo[3]; - $CountLeak{$addrfull}+= $meminfo[2]; - $nfull++; - } - } -} - -print STDERR "total memory corrupted at point==> ($nfull) \n"; -print STDERR "unique allocations ==> ($ufull) \n"; - -close (MEMSTAT); - -############################################################################## -# PRINT output leak information to leak.info.C output file -############################################################################## - - -open (LEAKinfo,">leak.info"); -open (MULTI,">multidelete.info"); -open (MEMSTAT,">memcheck.info"); - -# sort by size of leak -sub bysize { - $SizeLeak{$b} <=> $SizeLeak{$a}; # presuming integers -} - -sub bysizetotal { - $SizeTotal{$b} <=> $SizeTotal{$a}; # presuming integers -} - -foreach (sort bysizetotal keys %SizeTotal) { - print MEMSTAT "Count: $CountTotal{$_}($CountLeak{$_}) Size: $SizeTotal{$_}($SizeLeak{$_}) \n"; - s/stack://g; - @arr = split(/:/); #obtain leak points - for ($i = 0; $i <= $#arr; ++$i){ - $addr = $arr[$i]; - print MEMSTAT "$filename{$addr}$line{$addr}"; - } - print MEMSTAT "\n\n"; -} - - -foreach (sort bysize keys %SizeLeak) { - if ($CountLeak{$_}<0){ - print MULTI "Multiple deallocation :$CountLeak{$_}\n"; - s/stack://g; - @arr = split(/:/); #obtain leak points - for ($i = 0; $i <= $#arr; ++$i){ - $addr = $arr[$i]; - print MULTI "$filename{$addr}$line{$addr}"; - } - print MULTI "\n\n"; - } - if ($SizeLeak{$_}!=0){ - print LEAKinfo "Leaked allocations: $CountLeak{$_} \t Leaked size: $SizeLeak{$_} \n"; - s/stack://g; - @arr = split(/:/); #obtain leak points - for ($i = 0; $i <= $#arr; ++$i){ - $addr = $arr[$i]; - print LEAKinfo "$filename{$addr}$line{$addr}"; - } - print LEAKinfo "\n\n"; - } -} -close(LEAKinfo); -close(MULTI); -close(MEMSTAT); - -$remove = 'rm -rf commands'; -exec $remove; -die " -E- no commands file !"; - diff --git a/cmake/scripts/root-config.in b/cmake/scripts/root-config.in deleted file mode 100644 index c3e7eb1457367..0000000000000 --- a/cmake/scripts/root-config.in +++ /dev/null @@ -1,824 +0,0 @@ -#!/bin/sh -# -*- sh-indentation: 3 -*- -# This script returns the machine dependent compile options needed -# to compile and link applications using the ROOT libraries. -# -# Author: Fons Rademakers, 06/06/99 - -progdir=`dirname $0` -runningdir=`pwd` -if echo $progdir | grep "^/" > /dev/null 2>& 1 || \ - echo $progdir | grep "^~" > /dev/null 2>& 1; then - # absolute path - fullpath=$progdir -else - # relative path - fullpath=$runningdir/$progdir -fi -ROOTSYS=`dirname $fullpath` - -arch=@ROOT_ARCHITECTURE@ -platform=@ROOT_PLATFORM@ -bindir=@BIN_INSTALL_DIR@ -libdir=@LIB_INSTALL_DIR@ -incdir=@INCLUDE_INSTALL_DIR@ -etcdir=@ETC_INSTALL_DIR@ -features="@installed_options_list@" -configargs="@ROOT_CONFIGARGS@" -altcc="@CMAKE_C_COMPILER@" -altcxx="@CMAKE_CXX_COMPILER@" -altf77="@CMAKE_Fortran_COMPILER@" -altld="@CMAKE_CXX_COMPILER@" -dicttype=@ROOT_DICTTYPE@ -zliblib=@zliblib@ - -if test "$platform" = "win32"; then - if [ "x$ROOTSYS" != "x" ]; then - unixROOTSYS=`cygpath -u $ROOTSYS` - else - unixROOTSYS=. - fi - bindir=$unixROOTSYS/bin - libdir=$unixROOTSYS/lib - incdir=$unixROOTSYS/include - etcdir=$unixROOTSYS/etc -fi - -### ROOT libraries ### - -newlib="-lNew" -rootlibs="-lCore -lCint -lRIO -lNet -lHist -lGraf -lGraf3d -lGpad -lTree \ - -lRint -lPostscript -lMatrix -lPhysics -lMathCore -lThread $zliblib" -rootglibs="-lGui" - -if test "$dicttype" = "reflex" || test "$dicttype" = "gccxml"; then - rootlibs="$rootlibs -lReflex" -fi - -if test "$platform" = "win32"; then - rootulibs="-include:_G__cpp_setupG__Net \ - -include:_G__cpp_setupG__IO \ - -include:_G__cpp_setupG__Hist \ - -include:_G__cpp_setupG__Graf \ - -include:_G__cpp_setupG__G3D \ - -include:_G__cpp_setupG__GPad \ - -include:_G__cpp_setupG__Tree \ - -include:_G__cpp_setupG__Thread \ - -include:_G__cpp_setupG__Rint \ - -include:_G__cpp_setupG__PostScript \ - -include:_G__cpp_setupG__Matrix \ - -include:_G__cpp_setupG__Physics" - rootuglibs="-include:_G__cpp_setupG__Gui1" -elif test "$platform" = "aix5"; then - rootulibs="-Wl,-u,.G__cpp_setupG__Net \ - -Wl,-u,.G__cpp_setupG__IO \ - -Wl,-u,.G__cpp_setupG__Hist \ - -Wl,-u,.G__cpp_setupG__Graf \ - -Wl,-u,.G__cpp_setupG__G3D \ - -Wl,-u,.G__cpp_setupG__GPad \ - -Wl,-u,.G__cpp_setupG__Tree \ - -Wl,-u,.G__cpp_setupG__Thread \ - -Wl,-u,.G__cpp_setupG__Rint \ - -Wl,-u,.G__cpp_setupG__PostScript \ - -Wl,-u,.G__cpp_setupG__Matrix \ - -Wl,-u,.G__cpp_setupG__Physics" - rootuglibs="-Wl,-u,.G__cpp_setupG__Gui1" -else - rootulibs="-Wl,-u,_G__cpp_setupG__Net \ - -Wl,-u,_G__cpp_setupG__IO \ - -Wl,-u,_G__cpp_setupG__Hist \ - -Wl,-u,_G__cpp_setupG__Graf \ - -Wl,-u,_G__cpp_setupG__G3D \ - -Wl,-u,_G__cpp_setupG__GPad \ - -Wl,-u,_G__cpp_setupG__Tree \ - -Wl,-u,_G__cpp_setupG__Thread \ - -Wl,-u,_G__cpp_setupG__Rint \ - -Wl,-u,_G__cpp_setupG__PostScript \ - -Wl,-u,_G__cpp_setupG__Matrix \ - -Wl,-u,_G__cpp_setupG__Physics" - rootuglibs="-Wl,-u,_G__cpp_setupG__Gui1" -fi - -### machine dependent settings ### - -case $arch in -hpux) - #HP-UX with CC - auxcflags="+a1 +Z" - auxlibs="-lm -ldld" - ;; -hpuxacc | hpuxia64acc) - # HP-UX 10.x with aCC - auxcflags= - auxlibs="-lm -ldld" - ;; -hpuxgcc) - # HP-UX 10.x with g++ - auxcflags= - auxlibs="-lm -ldld" - ;; -hurddeb) - # Debian GNU/Hurd - auxcflags= - auxlibs="-lnsl -lm -ldl -rdynamic" - ;; -aix | aix5) - # IBM AIX - auxcflags="-qnoro -qnoroconst -qmaxmem=-1" - auxlibs= - forcelibs=$rootulibs - forceglibs=$rootuglibs - ;; -aixgcc) - # IBM AIX with g++ - auxcflags="-fsigned-char" - auxlibs= - forcelibs=$rootulibs - forceglibs=$rootuglibs - ;; -solaris) - # Solaris - auxcflags= - auxlibs="-L/usr/ccs/lib -lm -lsocket -lgen -ldl -lsunmath" - ;; -solarisgcc) - # Solaris g++ 2.8.x - auxcflags= - auxlibs="-L/usr/ccs/lib -lm -lsocket -lgen -ldl" - ;; -solarisCC5) - # Solaris CC 5.0 - auxcflags= - auxlibs="-lm -ldl -lnsl -lsocket" - ;; -solariskcc) - # Solaris KCC - auxcflags= - auxlibs="-L/usr/ccs/lib -lgen -lm -ldl -lsocket -lnsl" - ;; -solarisx86) - # Solaris CC on Intel - auxcflags= - auxlibs="-L/usr/ccs/lib -lm -lsocket -lgen -ldl" - ;; -sgicc) - # SGI - auxcflags="-LANG:std" - auxlibs="-lm -ldl" - ;; -sgicc64) - # SGI - auxcflags="-64 -LANG:std" - auxlibs="-lm" - ;; -sgigcc) - # SGI 6.x with gcc - auxcflags="-fsigned-char" - auxlibs="-lgen -lstdc++ -lm -ldl" - ;; -sgin32gcc) - # SGI 6.x with gcc with n32 ABI - auxcflags="-fsigned-char" - auxlibs="-lm -ldl" - ;; -sgikcc) - # SGI with KCC - auxcflags="--signed_chars --display_error_number \ - --diag_suppress 68 --diag_suppress 191 --diag_suppress 837" - auxlibs="-lm -ldl" - ;; -alphagcc) - # Alpha/OSF with g++ - auxcflags= - auxlibs="-lg++ -lm" - ;; -alphagcc) - # Alpha/OSF with gcc - auxcflags="-mcpu=ev5 -D__osf__ -D__alpha" - auxlibs="-ltermcap -lm" - ;; -alphakcc) - # Alpha/OSF with kai compiler (not yet valid) - auxcflags="-mcpu=ev5 -D__osf__ -D__alpha" - auxlibs="-ltermcap -lm" - ;; -alphacxx6) - # Alpha/OSF with cxx6 - auxcflags="-tlocal -D__osf__ -D__alpha -D_USE_STD_IOSTREAM" - auxlibs="-lm" - ;; -alphacxx) - # Alpha/OSF with cxx5 - auxcflags="-oldcxx -D__osf__ -D__alpha" - auxlibs="-lm" - ;; -linuxrh42 | linuxrh51) - # Linux with gcc 2.7.2.x - auxcflags= - auxlibs="-lg++ -lm -ldl -rdynamic" - ;; -linux) - # Linux with gcc >= 3.x - auxcflags="-m32" - auxldflags="-m32" - auxlibs="-lm -ldl -rdynamic" - ;; -linuxmips) - # Linux on mips with gcc >= 3.x - auxcflags="-mapi=32" - auxldflags="-mapi=32" - auxlibs="-lm -ldl -rdynamic" - ;; -linuxdeb | linuxsuse6) - # Linux with gcc on Debian and SuSE - auxcflags= - auxlibs="-lm -ldl -rdynamic" - ;; -linuxdeb2ppc) - # Debian/Linux on PPC - auxcflags=-fsigned-char - auxlibs="-lnsl -lm -ldl -rdynamic" - ;; -linuxkcc) - # Linux with the KAI compiler - auxcflags="--signed_chars -D_EXTERN_INLINE=inline --diag_suppress 191" - auxlibs="-lm -ldl -rdynamic" - ;; -linuxhppa) - # Linux on hppa with the GCC compiler - auxcflags= - auxldflags= - auxlibs="-lm -ldl -rdynamic" - ;; -linuxicc) - # Linux with the Intel icc compiler - auxcflags= - auxlibs="-lm -ldl" - ;; -linuxppcgcc) - # PPC Linux with gcc - auxcflags="-fsigned-char -I/usr/X11/include" - auxlibs="-lm -ldl -rdynamic" - ;; -linuxppc64gcc) - # PPC64 (64 bit mode) Linux with gcc 3.x - auxcflags="-m64 -fsigned-char" - auxldflags="-m64" - auxlibs="-lm -ldl -rdynamic" - ;; -linuxia64gcc) - # Itanium Linux with gcc 2.x/3.x - auxcflags= - auxlibs="-lm -ldl -rdynamic" - ;; -linuxia64sgi) - # Itanium Linux with SGI compiler - auxcflags= - auxlibs="-lm -ldl" - ;; -linuxia64ecc) - # Itanium Linux with Intel ecc compiler - auxcflags= - auxlibs="-lm -ldl" - ;; -linuxx8664gcc) - # AMD Opteron and Intel EM64T (64 bit mode) Linux with gcc 3.x - auxcflags="-m64" - auxldflags="-m64" - auxlibs="-lm -ldl -rdynamic" - ;; -linuxx8664icc) - # AMD Opteron and Intel EM64T (64 bit mode) Linux with Intel icc - auxcflags= - auxlibs="-lm -ldl" - ;; -linuxalphagcc) - # Alpha Linux with gcc - auxcflags= - auxlibs="-lm -ldl -rdynamic" - ;; -linuxarm) - # ARM Linux with gcc - auxcflags="-fsigned-char" - auxlibs="-lm -ldl -rdynamic" - ;; -mklinux) - # MkLinux with libc5 - auxcflags="-fsigned-char -I/usr/X11/include -I/usr/include/g++" - auxlibs="-lg++ -lm -ldl -rdynamic" - ;; -freebsd) - # FreeBSD with libc5 - auxcflags= - auxlibs="-lm -lg++" - ;; -freebsd4) - # FreeBSD 4 with glibc - auxcflags= - auxlibs="-lm -lstdc++" - ;; -freebsd5) - # FreeBSD 5 with glibc - auxcflags= - auxlibs="-lm -lstdc++" - ;; -openbsd) - # OpenBSD with libc - auxcflags= - auxlibs="-lm -lstdc++" - ;; -macosx) - # MacOS X with gcc (GNU cc v3.1) and possible fink (fink.sf.net) - macosx_minor=`sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2` - # cannot find the one linked to libGraf if relocated after built - rootlibs="$rootlibs -lfreetype" - if [ $macosx_minor -le 3 ]; then - finkdir=`which fink 2>&1 | sed -ne "s/\/bin\/fink//p"` - auxcflags=`[ -d ${finkdir}/include ] && echo -I${finkdir}/include` - auxcflags="-Wno-long-double $auxcflags" - auxlibs="-lm `[ -d ${finkdir}/lib ] && echo -L${finkdir}/lib` -ldl" - forcelibs=$rootulibs - forceglibs=$rootuglibs - else - auxcflags= - auxlibs="-lm -ldl" - fi - ;; -macosxicc) - # MacOS X with Intel icc compiler - macosx_minor=`sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2` - # cannot find the one linked to libGraf if relocated after built - rootlibs="$rootlibs -lfreetype" - auxcflags= - auxlibs="-lm -ldl" - ;; -macosx64) - # MacOS X with gcc (GNU cc v4.x) in 64 bit mode - macosx_minor=`sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2` - # cannot find the one linked to libGraf if relocated after built - rootlibs="$rootlibs -lfreetype" - auxcflags="-m64" - auxldflags="-m64" - auxlibs="-lm -ldl" - ;; -macosxxlc) - # MacOS X with IBM xl compiler and possible fink (fink.sf.net) - macosx_minor=`sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2` - # cannot find the one linked to libGraf if relocated after built - rootlibs="$rootlibs -lfreetype" - if [ $macosx_minor -le 3 ]; then - finkdir=`which fink 2>&1 | sed -ne "s/\/bin\/fink//p"` - auxcflags=`[ -d ${finkdir}/include ] && echo -I${finkdir}/include` - auxlibs="-lm `[ -d ${finkdir}/lib ] && echo -L${finkdir}/lib` -ldl" - forcelibs=$rootulibs - forceglibs=$rootuglibs - else - auxcflags= - auxlibs="-lm -ldl" - fi - ;; -hiux) - # Hitachi HIUX - auxcflags= - auxlibs="-lm -ldld" - ;; -win32) - # Win32 - auxcflags="-MD" - if test "x@winrtdebug@" = "xTRUE"; then - auxcflags="-MDd" - fi - VC_MAJOR=`unset VS_UNICODE_OUTPUT; cl.exe 2>&1 | awk '{ if (NR==1) print $8 }' | cut -d'.' -f1` - if test "$VC_MAJOR" != "" && test $VC_MAJOR -gt 13; then - auxcflags="$auxcflags -EHs -GR" - else - auxcflags="$auxcflags -GR -GX -G5" - fi - auxlibs= - forcelibs=$rootulibs - forceglibs=$rootuglibs - ;; -win32gcc) - # Win32 with cygwin gcc - auxcflags= - auxlibs= - forcelibs=$rootulibs - forceglibs=$rootuglibs - ;; -*) - echo "root-config: \"$arch\" invalid architecture" - echo "Please report to rootdev@root.cern.ch" - exit 1 - ;; -esac - - -### compiler dependent settings ### - -case $arch in -*kcc) - ex="" - for f in $features ; do - if test "x$f" = "xthread" ; then - auxcflags="--thread_safe $auxcflags" - auxldflags="--thread_safe $auxldflags" - fi - if test "x$f" = "xexceptions" ; then - ex="yes" - fi - done - if test "x$ex" = "x" ; then - auxcflags="--no_exceptions $auxcflags" - auxldflags="--no_exceptions $auxldflags" - else - auxcflags="--exceptions $auxcflags" - auxldflags="--exceptions $auxldflags" - fi - ;; -freebsd* | openbsd* | linux*) - for f in $features ; do - if test "x$f" = "xthread" ; then - auxcflags="-pthread $auxcflags" - auxlibs="-pthread $auxlibs" - fi - if test "x$f" = "xrpath" ; then - auxlibs="-Wl,-rpath,$libdir $auxlibs" - fi - done - ;; -macosx*) - for f in $features ; do - if test "x$f" = "xthread" ; then - if [ $macosx_minor -ge 5 ]; then - auxcflags="-D_REENTRANT -pthread $auxcflags" - auxlibs="-pthread $auxlibs" - else - auxcflags="-D_REENTRANT $auxcflags" - auxlibs="-lpthread $auxlibs" - fi - fi - if test "x$f" = "xrpath" ; then - if [ $macosx_minor -ge 5 ]; then - auxlibs="-Wl,-rpath,$libdir $auxlibs" - fi - fi - done - ;; -hpuxacc | hpuxia64acc) - for f in $features ; do - if test "x$f" = "xthread" ; then - auxcflags="-mt $auxcflags" - auxlibs="-mt $auxlibs" - fi - done - ;; -win32) - ;; -*) - for f in $features ; do - if test "x$f" = "xthread" ; then - auxcflags="-D_REENTRANT $auxcflags" - auxlibs="-lpthread $auxlibs" - fi - done - ;; -esac - -### end of machine and compiler dependent settings ### -nostubs=no #TODO: Don't know what this is @no_stubs@, so set it to no -nostubstest=no #TODO: Don't know what this is @no_stubs_test@, so set it to no - - -prefix=@ROOT_INSTALL_DIR@ -if test "$platform" = "win32" && test "$prefix" != ""; then - prefix=`cygpath -u $prefix` -fi -exec_prefix=${prefix} -exec_prefix_set=no -new_set=no -libsout=no -noauxlibs=no -noauxcflags=no -noldflags=no - -usage="\ -Usage: root-config [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version]\ - [--cflags] [--auxcflags] [--ldflags] [--new] [--nonew] [--libs]\ - [--glibs] [--bindir] [--libdir] [--incdir] [--etcdir] [--noauxcflags] [--noauxlibs]\ - [--noldflags] [--has-] [--arch] [--platform] [--dicttype]\ - [--config] [--features] [--svn-revision] [--python-version]\ - [--cc] [--cxx] [--f77] [--ld ] [--nostubs] [--nostubstest] [--help]" - -if test $# -eq 0; then - echo "${usage}" 1>&2 - exit 1 -fi - -out="" - -while test $# -gt 0; do - case "$1" in - -*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;; - *) optarg= ;; - esac - - case $1 in - --arch) - ### Output the arcitecture (compiler/OS combination) - out="$out $arch" - ;; - --platform) - ### Output the platform (OS) - out="$out $platform" - ;; - --has-*) - ### Check for feature - f=`echo $1 | sed 's/--has-//'` - for c in $features ; do - if test "x$c" = "x$f" ; then - out="$out yes" - break - fi - c="" - done - if test "x$c" = "x" ; then - out="$out no" - fi - ;; - --prefix=*) - ### Set the prefix - if test "$platform" = "win32"; then - ### We need to expand the path to backslash seperated path - optarg=`cygpath -u $optarg` - fi - prefix=$optarg - bindir=${prefix}/bin - libdir=${prefix}/lib - incdir=${prefix}/include - if test $exec_prefix_set = no ; then - exec_prefix=$optarg - fi - ;; - --prefix) - ### Output the prefix - out="$out $prefix" - ;; - --exec-prefix=*) - ### Set the exec-prefix - if test "$platform" = "win32"; then - ### We need to expand the path to backslash seperated path - optarg=`cygpath -u $optarg` - fi - exec_prefix=$optarg - exec_prefix_set=yes - bindir=${exec_prefix}/bin - libdir=${exec_prefix}/lib - ;; - --exec-prefix) - ### Output the exec-prefix - out="$out $prefix" - ;; - --nonew) - ### Don't use the libNew library - new_set="no" - ;; - --new) - ### Use the libNew library - new_set="yes" - ;; - --noauxlibs) - noauxlibs="yes" - ;; - --noauxcflags) - noauxcflags="yes" - ;; - --noldflags) - noldflags="yes" - ;; - --version) - ### Output the version number. If RVersion.h can not be found, give up. - if test -r ${incdir}/RVersion.h; then - out="$out `sed -n 's,.*ROOT_RELEASE *\"\(.*\)\".*,\1,p' < ${incdir}/RVersion.h`" - else - echo "cannot read ${incdir}/RVersion.h" - exit 1 - fi - ;; - --svn-revision) - ### Output the version number. If RVersion.h can not be found, give up. - if test -r ${incdir}/RVersion.h; then - out="$out `sed -n 's,.*ROOT_SVN_REVISION *\([0-9]*\).*,\1,p' < ${incdir}/RVersion.h`" - else - echo "cannot read ${incdir}/RVersion.h" - exit 1 - fi - ;; - --python-version) - out="$out @PYTHON_VERSION@" - ;; - --cflags) - ### Output the compiler flags - if test ${incdir} != /usr/include; then - ### In case we're on a Win32 system, we need to expand the - ### path to a backslash seperated path - if test "$platform" = "win32"; then - includes=-I\'`cygpath -w ${incdir}`\' - else - includes=-I${incdir} - fi - fi - if test "x$noauxcflags" = "xyes" ; then - out="$out $includes" - else - out="$out ${auxcflags} $includes" - fi - ;; - --auxcflags) - ### Output auxiliary compiler flags - out="$out $auxcflags" - ;; - --ldflags) - ### Output linker flags - out="$out $auxldflags" - ;; - --libs) - ### Output regular ROOT libraries. If the user said --glibs --libs, - ### We've already output the libraries, so we skip this section - if test "x$libsout" = "xyes" ; then - shift - continue - fi - ### Set the flag - libsout="yes" - ### See if we need the new library - if test "x$new_set" = "xyes"; then - libs="${newlib} ${rootlibs}" - else - libs=${rootlibs} - fi - ### If we're on a win32 system, we need to change the -l prefix - ### into a .lib suffix, and expand the paths to a backslash - ### separated path. - if test "$platform" = "win32"; then - nlibs=`echo $libs | sed "s@-l\([a-zA-Z0-9]*\)@${libdir}/lib\1.lib@g"` - libs= - for i in $nlibs; do - libs="$libs '`cygpath -w $i`'" - done - else - if test "x$noldflags" = "xno" ; then - out="$out -L${libdir}" - fi - fi - if test "x$noauxlibs" = "xyes" ; then - out="$out $forcelibs $libs" - else - out="$out $forcelibs $libs ${auxlibs}" - fi - ;; - --glibs) - ### Output graphics and normal libraries - ### If the user said --libs --glibs, we don't need to add the - ### regular ROOT libraries. - glibsonly="no" - if test "x$libsout" = "xno" ; then - ### Set the flag - libsout="yes" - if test "x$new_set" = "xyes" ; then - glibs="${newlib} ${rootlibs} ${rootglibs}" - else - glibs="${rootlibs} ${rootglibs}" - fi - else - glibs="${rootglibs}" - glibsonly="yes" - fi - ### If we're on a win32 system, we need to change the -l prefix - ### into a .lib suffix, and expand the paths to a backslash - ### separated path. - if test "$platform" = "win32"; then - nlibs=`echo $glibs | sed "s@-l\([a-zA-Z0-9]*\)@${libdir}/lib\1.lib@g"` - glibs= - for i in $nlibs; do - glibs="$glibs '`cygpath -w $i`'" - done - else - if test "x$noldflags" = "xno" ; then - out="$out -L${libdir}" - fi - fi - if test "x$glibsonly" = "xyes" ; then - out="$out $forceglibs $glibs" - else - if test "x$noauxlibs" = "xyes" ; then - out="$out $forcelibs $forceglibs $glibs" - else - out="$out $forcelibs $forceglibs $glibs ${auxlibs}" - fi - fi - ;; - --auxlibs) - ### output the auxiliary libraries - out="$out $auxlibs" - ;; - --bindir) - ### output the executable directory - out="$out $bindir" - ;; - --libdir) - ### output the library directory - out="$out $libdir" - ;; - --incdir) - ### output the header directory - out="$out $incdir" - ;; - --etcdir) - ### output the etc directory - out="$out $etcdir" - ;; - --config) - ### output the configure arguments - out="$out $configargs" - ;; - --features) - ### output all supported features - out="$out$features" # no space, features starts with space - ;; - --dicttype) - ### output the dictionary type - out="$out $dicttype" - ;; - --cc) - ### output used C compiler - out="$out $altcc" - ;; - --cxx) - ### output used C++ compiler - out="$out $altcxx" - ;; - --f77) - ### output used Fortran compiler - out="$out $altf77" - ;; - --ld) - ### output used Linker - out="$out $altld" - ;; - --nostubs) - ### Output the prefix - out="$out $nostubs" - ;; - --nostubstest) - ### Output the prefix - out="$out $nostubstest" - ;; - --help) - ### Print a help message - echo "Usage: `basename $0` [options]" - echo "" - echo " --arch Print the architecture (compiler/OS)" - echo " --platform Print the platform (OS)" - echo " --prefix[=dir] Print or set prefix" - echo " --exec-prefix[=dir] Print or set execution prefix" - echo " --libs Print regular ROOT libraries" - echo " --glibs Print regular + GUI ROOT libraries" - echo " --cflags Print compiler flags and header path" - echo " --ldflags Print linker flags" - echo " --bindir Print the executable directory" - echo " --libdir Print the library directory" - echo " --incdir Print the header directory" - echo " --auxlibs Print auxiliary libraries" - echo " --auxcflags Print auxiliary compiler flags" - echo " --[no]new Turn on[off] use of libNew.so" - echo " --noauxlibs Do not print auxiliary/system libraries" - echo " --noauxcflags Do not print auxiliary compiler flags" - echo " --noldflags Do not print linker flags" - echo " --config Print arguments used for ./configure" - echo " --features Print list of all supported features" - echo " --has- Test if is compiled in" - echo " --dicttype Print dictionary generator being used" - echo " --version Print the ROOT version" - echo " --svn-revision Print the ROOT SVN revision number" - echo " --python-version Print the Python version used by ROOT" - echo " --cc Print alternative C compiler specified when ROOT was built" - echo " --cxx Print alternative C++ compiler specified when ROOT was built" - echo " --f77 Print alternative Fortran compiler specified when ROOT was built" - echo " --ld Print alternative Linker specified when ROOT was built" - echo " --nostubs Print yes if we are using the stubless calls" - echo " --nostubstest Print yes if we are using the stubless calls (in test mode)" - echo " --help Print this message" - exit 0 - ;; - *) - ### Give an error - echo "Unknown argument \"$1\"!" 1>&2 - echo "${usage}" 1>&2 - exit 1 - ;; - esac - shift -done - -### Output the stuff -echo $out diff --git a/cmake/scripts/rootrc.in b/cmake/scripts/rootrc.in deleted file mode 100644 index fc0792e7ee705..0000000000000 --- a/cmake/scripts/rootrc.in +++ /dev/null @@ -1,514 +0,0 @@ -# @(#)root/config:$Id: rootrc.in 24458 2008-06-21 11:56:48Z rdm $ -# Author: Fons Rademakers 22/09/95 - -# ROOT Environment settings are handled via the class TEnv. To see -# which values are active do: gEnv->Print(). - -# Path used by dynamic loader to find shared libraries. -# This path will be prepended to the (DY)LD_LIBRARY_PATH. -# Paths are different for Unix and Windows. The example shows the defaults -# for all ROOT applications for either Unix or Windows. -Unix.*.Root.DynamicPath: .:@LIB_INSTALL_DIR@: -WinNT.*.Root.DynamicPath: .;@bBIN_INSTALL_DIR@;$(PATH); - -# Path used to find macros. -# Paths are different for Unix and Windows. The example shows the defaults -# for all ROOT applications for either Unix or Windows. -Unix.*.Root.MacroPath: .:@MACRO_INSTALL_DIR@: -WinNT.*.Root.MacroPath: .;@MACRO_INSTALL_DIR@; - -# Path used to find plugin macros. -# Paths are different for Unix and Windows. The example shows the defaults -# for all ROOT applications for either Unix or Windows. -Unix.*.Root.PluginPath: :@ETC_INSTALL_DIR@/plugins: -WinNT.*.Root.PluginPath: ;@ETC_INSTALL_DIR@/plugins; - -# Path where to look for TrueType fonts. -Unix.*.Root.UseTTFonts: true -*.*.Root.TTFontPath: @FONT_INSTALL_DIR@ - -# Use Net* API functions. -WinNT.UseNetAPI: true - -# Use thread library (if exists). -Unix.*.Root.UseThreads: false - -# Select the compression algorithm (0=old zlib, 1=new zlib) -# Note, setting this to `0' may be a security vulnerability. -Root.ZipMode: 1 - -# Show where item is found in the specified path. -Root.ShowPath: false - -# Activate memory statistics (size and cnt is used to trap allocation of -# blocks of a certain size after cnt times). -Root.MemStat: 0 -Root.MemStat.size: -1 -Root.MemStat.cnt: -1 -Root.ObjectStat: 0 - -# Activate memory leak checker (use in conjunction with $ROOTSYS/bin/memprobe). -# Currently only works on Linux with gcc. -Root.MemCheck: 0 -Root.MemCheckFile: memcheck.out - -# Global debug mode. When >0 turns on progressively more details debugging. -Root.Debug: 0 -Root.Stacktrace: yes - -# Ignore errors lower than the ignore level. Possible values: -# Print, Info, Warning, Error, Break, SysError and Fatal. -Root.ErrorIgnoreLevel: Print - -# Settings for X11 behaviour. -X11.Sync: no -X11.FindBestVisual: yes -X11.UseXft: no -X11.XInitThread: yes - -# Settings for Win32 behavior. -Win32.UseSysPointers: no - -# Default editor. -Unix.*.Editor: vi -WinNT.*.Editor: notepad - -# Default 3d Viewer. -# By default 3-D views are shown in the pad, -# if the next line is activated, the default viewer will be OpenGL. -#Viewer3D.DefaultDrawOption: ogl - -# Default Fitter (current choices are Minuit and Fumili). -Root.Fitter: Minuit - -# Specify list of file endings which TTabCom (TAB completion) should ignore. -#TabCom.FileIgnore: .cpp:.h:.cmz - -# TCanvas specific settings. Opaque move and resize show full pad during -# the operation instead of only the outline. Especially for resize you'll -# need serious CPU power. UseScreenFactor=true means to size canvas according -# to size of screen, so a canvas still looks good on a low resolution -# laptop screen without having to change canvas size in macros. -# HighLightColor 2 = red. ShowEventStatus allows the event status bar to -# be turned on by default. AutoExec allows TExec objects to be executed -# on mouse and key events. -Canvas.MoveOpaque: false -Canvas.ResizeOpaque: false -Canvas.UseScreenFactor: true -Canvas.HighLightColor: 2 -Canvas.ShowEventStatus: false -Canvas.ShowToolBar: false -Canvas.ShowEditor: false -Canvas.AutoExec: true -Canvas.PrintDirectory . -#set the default precision when writing floating point numbers in TCanvas::SaveSource -Canvas.SavePrecision 7 - -# Printer settings. -#WinNT.*.Print.Command: AcroRd32.exe -#Unix.*.Print.Command: a2ps -P%p --landscape --columns=2 --margin=30 -rf8.0 %f -#Print.Printer: 32-rb20-hp -#Print.Directory: . -#Print.FileType: pdf - -# Default histogram binnings for TTree::Draw(). -Hist.Binning.1D.x: 100 - -Hist.Binning.2D.x: 40 -Hist.Binning.2D.y: 40 -Hist.Binning.2D.Prof: 100 - -Hist.Binning.3D.x: 20 -Hist.Binning.3D.y: 20 -Hist.Binning.3D.z: 20 -Hist.Binning.3D.Profx: 100 -Hist.Binning.3D.Profy: 100 - -# Default statistics parameters names. -Hist.Stats.Entries Entries -Hist.Stats.Mean Mean -Hist.Stats.MeanX Mean x -Hist.Stats.MeanY Mean y -Hist.Stats.RMS RMS -Hist.Stats.RMSX RMS x -Hist.Stats.RMSY RMS y -Hist.Stats.Underflow Underflow -Hist.Stats.Overflow Overflow -Hist.Stats.Integral Integral -Hist.Stats.Skewness Skewness -Hist.Stats.SkewnessX Skewness x -Hist.Stats.SkewnessY Skewness y -Hist.Stats.Kurtosis Kurtosis -Hist.Stats.KurtosisX Kurtosis x -Hist.Stats.KurtosisY Kurtosis y - -# THtml specific settings (for more see doc of THtml class). -Root.Html.SourceDir: . -Root.Html.Root: http://root.cern.ch/root/html -Root.Html.ViewCVS: http://root.cern.ch/viewcvs/trunk/%f?view=log -Root.Html.Search: http://www.google.com/search?q=%s+site%3A%u+-site%3A%u%2Fsrc%2F+-site%3A%u%2Fexamples%2F -#Root.Html.OutputDir: htmldoc/ -#Root.Html.Homepage: -#Root.Html.Header: -#Root.Html.Footer: -#Root.Html.Description: //____________________ -#Root.Html.Author: // Author: -#Root.Html.LastUpdate: // @(#) -#Root.Html.Copyright: * Copyright - -# GUI specific settings. -Gui.Backend: native -Gui.Factory: native -Gui.DefaultFont: -*-helvetica-medium-r-*-*-12-*-*-*-*-*-iso8859-1 -Gui.MenuFont: -*-helvetica-medium-r-*-*-12-*-*-*-*-*-iso8859-1 -Gui.MenuHiFont: -*-helvetica-bold-r-*-*-12-*-*-*-*-*-iso8859-1 -Gui.DocFixedFont: -*-courier-medium-r-*-*-12-*-*-*-*-*-iso8859-1 -Gui.DocPropFont: -*-helvetica-medium-r-*-*-12-*-*-*-*-*-iso8859-1 -Gui.IconFont: -*-helvetica-medium-r-*-*-10-*-*-*-*-*-iso8859-1 -Gui.StatusFont: -*-helvetica-medium-r-*-*-10-*-*-*-*-*-iso8859-1 -Gui.BackgroundColor: #c0c0c0 -Gui.ForegroundColor: black -Gui.SelectBackgroundColor: #000080 -Gui.SelectForegroundColor: white -Gui.DocumentBackgroundColor: white -Gui.DocumentForegroundColor: black -Gui.TooltipBackgroundColor: LightYellow -Gui.TooltipForegroundColor: black -Gui.IconPath: $(HOME)/icons:@ICON_INSTALL_DIR@:. -Gui.MimeTypeFile: $(HOME)/.root.mimes -# If above does not exists defaults to this: -#Gui.MimeTypeFile: @ETC_INSTALL_DIR@/root.mimes -Browser.Name: TRootBrowserLite -# Browser Options (plugins) -# F: File browser E: Text Editor H: HTML browser -# C: Canvas I: I/O redirection P: Proof G: GL viewer -Browser.Options: FECI -# Can be either small, big, list, details -Browser.IconStyle: small -# Can be either name, type, size, date -Browser.SortBy: name -Browser.GroupView: 10000 -Browser.ShowHidden: no -Browser.AutoThumbnail: yes - -# Rint (interactive ROOT executable) specific alias, logon and logoff macros. -Rint.Load: rootalias.C -Rint.Logon: rootlogon.C -Rint.Logoff: rootlogoff.C -# Record session commands, set to "-" to turn off command recording. -Rint.History: $(HOME)/.root_hist -# History file size, once HistSize is reached remove all but HistSave entries, -# set to 0 to turn off command recording. -# Can be overridden by environment variable ROOT_HIST=size[:save], -# the ":save" part is optional. -# Rint.HistSize: 500 -# Set to -1 for sensible default (80% of HistSize), set to 0 to disable history. -# Rint.HistSave: 400 -# Print a single line welcome message instead of the default verbose version -# Rint.WelcomeLite: no -# When the interactive ROOT starts, it can automatically load some frequently -# used includes. However, this introduces several overheads -# - A long list of CINT and system files will be kept open during the session -# - The initialisation takes more time (noticeable when using gdb or valgrind) -# - Memory overhead of about 5 Mbytes (1/3 of the base ROOT executable) when -# including -# You can set the variable below to 0 to disable the loading of these -# includes at startup. You can set the variable to 1 (default) to load -# only , and . You can set it to 2 to -# load in addition and . We strongly recommend setting -# the variable to 2 if your scripts include and you execute -# your scripts multiple times. -Rint.Includes: 1 - -# CINT: use wrappers for calls (larger dictionaries). -# Only checked if configured with --no-stubs-test; defaults to "use wrappers": -# Cint.EnableWrappers: 1 - -# ACLiC customization. -# ACLiC.Linkdef specifies the suffix that will be added to the script name to -# try to locate a custom linkdef file when generating the dictionary. -ACLiC.Linkdef: _linkdef -# Set a top directory for storing the libraries produced by ACLiC. -#ACLiC.BuildDir: /where/I/would/like/my/compiled/scripts -# Add additional include directives for ACLiC compilations. -#ACLiC.IncludePaths: -I/where/the/includes/are - -# PROOF related variables -# -# PROOF debug options. -# Proof.DebugLevel: 0 -# Proof.DebugMask: -1 -# -# PROOF GDB hooks -# allows a debugger to be attached early in the startup phase of proofserv -# 0 - don't wait -# 1 - master proofserv enters wait loop -# 2 - slave proofserv enters wait loop -# 3 - any proofserv enters wait loop -# -# Proof.GdbHook: 0 -# -# -# On the master enable parallel startup of workers using threads -# Proof.ParallelStartup: no -# -# Proof.StatsHist: no -# Proof.StatsTrace: no -# Proof.SlaveStatsTrace: no -# -# Proof.CondorHome: /opt/condor -# Proof.CondorConfig: /opt/condor/etc/condor_config -# -# PEAC.GmUrl: http://somewhere:8080/clarens/ -# PEAC.LmUrl: http://elsewhere:8080/clarens/ - -# Certificate and key -# Clarens.CertFile: $(HOME)/.globus/usercert.pem -# Clarens.KeyFile: $(HOME)/.globus/userkey.pem - -# Variables related to authentication to rootd and proofd. -# -# Default authentication method for rootd and proofd. -# These are supported for backward compatibility but have a very -# low priority. System defaults are generated by configure as a list -# in system.rootauthrc in $ROOTSYS/etc/ or /etc/root; the file -# $HOME/.rootauthrc can be used to override the system defaults. -# (0=UsrPwd, 1=SRP, 2=Krb5, 3=Globus,4=SSH, 5=UidGid) -Rootd.Authentication: 0 -Proofd.Authentication: 0 - -# Connection is shutdown at timeout expiration. Timeout is in seconds. -# Negotiation cannot be attempted at low level (i.e. inside -# TAuthenticate::Authenticate()) because of synchronization -# problems with the server. -# At higher level, TAuthenticate::HasTimedOut() gives information -# about timeout: 0 = no timeout; 1 = timeout, no methods left; -# 2 = timeout, still methods to be tried . -# Caller should decide about an additional attempt. -# Timeout disabled (< 0) by default. Can be changed on-the-fly -# with the static method TAuthenticate::SetTimeOut(to_value) -# -# Auth.Timeout: -1 - -# Password dialog box. -# Set to 0 if you do not want a dialog box to be popped-up -# when a password is requested. -# Default is 1. -# -# Auth.UsePasswdDialogBox: 0 - -# Set this to 1 if you want full SRP authentication in PROOF -# (Client-to-Master and Master-to-Slave). -Proofd.SendSRPPwd: 0 - -# Set this to 1 to use SSH authentication in PROOF servers -# (Master-to-Slave or Slaves-to-DataServers). This is switched -# off by default because credentials forwarding for SSH is not -# controlled by the system; however the user may have other -# ways to guarantee it, so it may want to switch it on. -ProofServ.UseSSH: 0 - -# Default login name (if not defined is taken from $(HOME)). -#UsrPwd.Login: qwerty -#SRP.Login: qwerty -#Krb5.Login: qwerty@LOCAL.DOM.AIN -#Globus.Login: cd:~/.globus cf:usercert.pem kf:userkey.pem ad:/etc/grid-security/certificates -#SSH.Login: qwerty -#UidGid.Login: qwerty - -# To be prompted for login information. -#UsrPwd.LoginPrompt: yes -#SRP.LoginPrompt: yes -#Krb5.LoginPrompt: yes -#Globus.LoginPrompt: yes -#SSH.LoginPrompt: yes -#UidGid.LoginPrompt: yes - -# To reuse established security context. -UsrPwd.ReUse: yes -SRP.ReUse: no -Krb5.ReUse: no -Globus.ReUse: yes -SSH.ReUse: yes - -# Duration validity of the sec context for UsrPwd, SRP and SSH. -# Format: : (default 24:00) -#UsrPwd.Valid: 24:00 -#SRP.Valid: 24:00 -#SSH.Valid: 24:00 - -# To control password encryption for UsrPwd authentication. -UsrPwd.Crypt: yes - -# Globus miscellanea. -# Globus Proxy duration: HH:MM (ex 12:15 for 12 hours and 15 min) -# 'default' for system default. -Globus.ProxyDuration: default -#Globus.ProxyDuration: 14 -# Number of bits for the initial key. -Globus.ProxyKeyBits: 1024 - -# Path to alternative 'ssh' (to override $PATH if ever needed). -#SSH.ExecDir: /usr/bin - -# In case of error, SSH returns 1 (or 256 = 0x100). -# To trap those errors for which one should retry, error printouts -# must be parsed; any substring found under the Env SSH.ErrorRetry -# triggers a retry condition; strings can be added here -# in the form (including double quotes): -# +SSH.ErrorRetry: "" -# This is what one usually gets if the server has reached the maximum -# number of sshd daemons (defined by MaxStartups in sshd_config); -# this is a typical case in which one should retry. -SSH.ErrorRetry: "Connection closed by remote host" -# Max number of retries for SSH in case of retry error (see above). -SSH.MaxRetry: 100 - -# Type of key to be used for RSA encryption: -# 0 = local; 1 = SSL (default if openssl available). -RSA.KeyType: 1 - -# In case of 'RSA.KeyType: 1' this specifies the number of bits to -# be used for the Blowfish key used to encrypt the exchanged information -# Default 256, minimum 128, maximum 15912. -#SSL.BFBits: 256 - -# Server authentication in TServerSocket. -# -# General: file with server access rules -#SrvAuth.DaemonRc: /etc/root/system.daemonrc -# -# UsrPwd: check of host equivalence via /etc/hosts.equiv or $HOME/.rhosts. -#SrvAuth.CheckHostsEquivalence: 1 -# -# SRP: pass file (default $HOME/.srootdpass). -#SrvAuth.SRPpassfile: $HOME/.srootdpass -# -# Globus/GSI: hostcert configuration file. -#SrvAuth.HostCert: /etc/root/hostcert.conf -# Globus/GSI: gridmap file. -#SrvAuth.GridMap: /etc/grid-security/grid-mapfile -# -# SSH: port for the sshd daemon. -#SrvAuth.SshdPort: 22 - -# Force file opening via TNetFile (TXNetFile) if a hostname is specified -# in the Url. -# By default, for local files TFile::Open() invokes directly TFile -#TFile.ForceRemote: yes - -# Control the action to be taken when opening an existing ROOT file which -# looks corrupted; by default an attempt to recover the file is made; if -# this variable is set to no the file is just flagged as zombie. -#TFile.Recover: no - -# Control the usage of asynchronous reading capabilities eventually -# supported by the underlying TFile implementation. Default is yes. -#TFile.AsyncReading: no - -# Special cases for the TUrl parser, where the special cases are parsed -# in a protocol + file part, like rfio:host:/path/file.root, -# castor:/path/file.root or /alien/path/file.root. -# In case the file namespace descriptor ends with - the namespace -# is not a part of the filename. -# Extend in private .rootrc with a +Url.Special line. -Url.Special: file: rfio: hpss: castor: gfal: dcache: -+Url.Special: /alien/- /castor/ - -# PROOF XRD client variables -# Debug level (<0 : errors, 0 : minimal, 1 : low, 2 : medium, 3 : high) [-1] -# XProof.Debug: 0 -# Socket read timeout [in secs: default 10 secs] -# XProof.ReadTimeout: 10 - -# The following env vars are handled by TXNetFile and related classes -# (module netx, libNetx.so). -# -# XNet.ConnectTimeout - maximum time to wait before server's -# response on a connect [10 s] -# XNet.RequestTimeout - maximum time to wait before considering -# a read/write failure [60 s] -# XNet.ConnectDomainAllowRE -# - sequence of TRegexp regular expressions -# separated by a |. -# A domain is granted access to for the -# first connection if it matches one of these -# regexps. Example: -# slac.stanford.edu|pd.infn.it|fe.infn.it -# XNet.ConnectDomainDenyRE -# - sequence of TRegexp regular expressions -# separated by a |. -# A domain is denied access to for the -# first connection if it matches one of these -# regexps. Example: -# slac.stanford.edu|pd.infn.it|fe.infn.it -# XNet.RedirDomainAllowRE -# - sequence of TRegexp regular expressions -# separated by a |. -# A domain is granted access to for a -# redirection if it matches one of these -# regexps. Example: -# slac.stanford.edu|pd.infn.it|fe.infn.it -# XNet.RedirDomainDenyRE -# - sequence of TRegexp regular expressions -# separated by a |. -# A domain is denied access to for a -# redirection if it matches one of these -# regexps. Example: -# slac.stanford.edu|pd.infn.it|fe.infn.it -# XNet.MaxRedirectCount - maximum number of redirections from -# server [255] -# XNet.Debug - log verbosity level -# (0=nothing, -# 1=messages of interest to the user, -# 2=messages of interest to the developers -# (includes also user messages), -# 3=dump of all sent/received data buffers -# (includes also user and developers -# messages). [0] -# XNet.ReconnectTimeout - sleep-time before going back to the -# load balancer (or rebouncing to the same -# failing host) after a read/write error -# [10 s] -# XNet.ReadAheadSize - read ahead value, in bytes, to use with the XrdClient -# internal caching scheme -# Generally not much useful together with the TFile cache, -# which will disable the readahead as soon it starts operating, -# i.e. requesting async data through XrdClient. -# Note that we cannot suppose that the TFile cache -# will start working at the beginning of the data processing. -# Setting a read ahead size > 0 will involve this phase, -# sometimes it could be an advantage, sometimes not. -# If > 0, TXNetFile will switch it on again if it sees that -# synchronous ReadBuffer requests are issued again - -XNet.ReadAheadSize: 500000 - -# XNet.ReadCacheSize - Default read cache size inside XrdClient, in bytes. -# TXNetFile/TFileReadCache automatically sets this to a -# 'correct' value when needed. -# Set a value here to override a *minimum* -# size. It is not preallocated. -# TFile/TXNetFile can anyway make it grow -# automatically when needed. - -XNet.ReadCacheSize: 10000000 - -# XNet.FirstConnectMaxCnt -# - Number of connect retries to the first host -# XNet.PrintTAG - Print a particular string the developers -# can choose to quickly recognize the -# version at run time [0] -# -# XNet.ParStreamsPerPhyConn -# - Number of additional TCP streams to use per -# each physical connection -# 0=monostream mode -# 1-15=multistream mode - -XNet.ParStreamsPerPhyConn: 0 - -# Example of custom setting for the Rint application (root.exe). -# This overrides the default specified above for a generic application. -# Color 5 is yellow. -Rint.Canvas.HighLightColor: 5 diff --git a/cmake/scripts/testsingle.cxx.in b/cmake/scripts/testsingle.cxx.in deleted file mode 100644 index dc8527eef06a4..0000000000000 --- a/cmake/scripts/testsingle.cxx.in +++ /dev/null @@ -1,1553 +0,0 @@ -#! @CMAKE_BINARY_DIR@/bin/ -/* /% C++ %/ */ -/*********************************************************************** - * cint (C/C++ interpreter) - ************************************************************************ - * C++ Script testcint.cxx - ************************************************************************ - * Description: - * Automatic test suite of cint - ************************************************************************ - * Copyright(c) 2002~2004 Masaharu Goto - * - * For the licensing terms see the file COPYING - * - ************************************************************************/ -// Usage: -// $ cint testall.cxx - -#include -#ifdef G__ROOT -#include "@CMAKE_BINARY_DIR@/include/configcint.h" -#else -#include "../inc/configcint.h" -#endif - -#ifndef G__VISUAL // ??? fprintf crashes if stdfunc.dll is loaded ??? -#include -#include -#endif - -#ifdef DEBUG2 -#ifndef DEBUG -#define DEBUG -#endif -#endif - -char* debug = 0; -bool bKeepOnGoing = false; -bool bIgnoreDiffErrors = false; -bool bHideKnownErrors = false; -#ifndef DEBUG -bool debugMode = false; -#else -bool debugMode = true; -#endif - -#include - -const char *shellSeparator = "&&"; - -#ifdef G__ROOT -// ROOT disable the autoloading of the standard header from the compiled -// dictionary (see G__autoload_stdheader) however the cint test requires it -std::string mkcintoption = " -Z1 "; -std::string cintoption = " -Z1 -I@CMAKE_BINARY_DIR@/include -I@CMAKE_BINARY_DIR@/cint/cint/include "; -#else -std::string mkcintoption = ""; -std::string cintoption = ""; -#endif // G__ROOT -std::string compileroption = ""; -std::string prefixcmd = ""; - -enum ELanguage { - kLangUnknown, - kLangC, - kLangCXX -}; - -//______________________________________________________________________________ -int clear(const char* fname) -{ - // -- Erase a file. - FILE* fp = fopen(fname, "w"); - fclose(fp); - return 0; -} - -//______________________________________________________________________________ -int exist(const char* fname) -{ - // -- Check if a file exists. - FILE* fp = fopen(fname, "r"); - if (fp) { - fclose(fp); - return 1; - } - return 0; -} - -//______________________________________________________________________________ -int rm(const char* fname) -{ - // -- Delete a file. - int stat; - do { - stat = remove(fname); - } - while (exist(fname)); - return stat; -} - -//______________________________________________________________________________ -char *cleanAndCreateDirectory(const char *tname) -{ - // Create an empty directory with the same name, without extension - // as the test. - - char com[4096]; - - char *dir = new char[strlen(tname)+1]; - strcpy(dir,tname); - char *cursor = strstr(dir,"."); - if (cursor) { - *cursor = '\0'; - }; - - char com[4096]; - - sprintf(com,"rm -rf %s",dir); - run(com); - sprintf(com,"mkdir %s",dir); - run(com); - - return dir; -} - -//______________________________________________________________________________ -void cleanDirectory(const char* dir) -{ - // Delete a test directory - char com[4096]; - sprintf(com,"rm -rf %s",dir); - run(com); -} - -//______________________________________________________________________________ -int cat(FILE* fout, const char* fname) -{ - // -- Display a file on a given output file. - FILE* fp = fopen(fname, "r"); - char b1[4096]; - while (fgets(b1, 4096, fp)) { - fprintf(fout, "%s", b1); - } - fclose(fp); - return 0; -} - -//______________________________________________________________________________ -int run(const char* com, bool show_when_debug = true) -{ - // -- Run a system command. - if (debugMode && show_when_debug) printf("%s\n", com); - - //printf("%s\n", com); - fflush(stdout); - int ret = system(com); - if (ret) { - printf("FAILED with code %d: %s\n", ret, com); - if (!bKeepOnGoing) { - exit(ret); - } - } - return ret; -} - -//______________________________________________________________________________ -int readahead(FILE* fp, const char* b, const int ahead = 10) -{ - // -- FIXME: Describe this function! - if (!fp) { - return 0; - } - int result = 0; - fpos_t p; - fgetpos(fp, &p); - char buf[4096]; - int a = 0; - for (int i = 0; i < ahead; ++i) { - char* c = fgets(buf, 4096, fp); - ++a; - if (!c) { - break; - } - if (!strcmp(b, buf)) { - result = a; - break; - } - } - fsetpos(fp, &p); - return result; -} - -//______________________________________________________________________________ -void outdiff(FILE* fp, FILE* fpi, int a, const char* b, int& l, const char* m) -{ - // -- FIXME: Describe this function! - for (int i = 0; i < a; i++) { - fprintf(fp, "%3d%s %s", l, m, b); - if (!fpi) { - break; - } - char* c = fgets((char*) b, 400, fpi); - ++l; - if (!c) { - break; - } - } -} - -//______________________________________________________________________________ -void checkdiff(FILE* fp, FILE* fp1, FILE* fp2, char* b1, const char* b2, int& l1, int& l2, const char* m1, const char* m2) -{ - // -- FIXME: Describe this function! - int a1 = readahead(fp1, b2); - int a2 = readahead(fp2, b1); - if (a1 && a2) { - if (a1 <= a2) { - outdiff(fp, fp1, a1, b1, l1, m1); - } - else { - outdiff(fp, fp2, a2, b2, l2, m2); - } - } - else if (a1) { - outdiff(fp, fp1, a1, b1, l1, m1); - } - else if (a2) { - outdiff(fp, fp2, a2, b2, l2, m2); - } - else { - fprintf(fp, "%3d%s %s", l1, m1, b1); - fprintf(fp, "%3d%s %s", l2, m2, b2); - } -} - -//______________________________________________________________________________ -int diff(const char* title, const char* f1, const char* f2, const char* out, const char* macro = "", const char* m1 = ">", const char* m2 = "<") -{ - // -- FIXME: Describe this function! - FILE* fp = fopen(out, "a"); - FILE* fp1 = fopen(f1, "r"); - FILE* fp2 = fopen(f2, "r"); - char b1[4096]; - char b2[4096]; - char* c1 = 0; - char* c2 = 0; - int l1 = 0; - int l2 = 0; - fprintf(fp, "%s %s\n", title, macro); - for (;;) { - if (fp1) { - c1 = fgets(b1, 4096, fp1); - ++l1; - } - else { - c1 = 0; - } - if (fp2) { - c2 = fgets(b2, 4096, fp2); - ++l2; - } - else { - c2 = 0; - } - if (c1 && c2) { - if (strcmp(b1, b2)) { - // -- -#ifndef G__VISUAL - checkdiff(fp, fp1, fp2, b1, b2, l1, l2, m1, m2); -#else // G__VISUAL - fprintf(fp, "%3d%s %s", l1, m1, b1); - fprintf(fp, "%3d%s %s", l2, m2, b2); -#endif // G__VISUAL - // -- - } - } - else if (c1) { - fprintf(fp, "%3d%s %s", l1, m1, b1); - } - else if (c2) { - fprintf(fp, "%3d%s %s", l2, m2, b2); - } - else { - break; - } - } - if (fp2) { - fclose(fp2); - } - if (fp1) { - fclose(fp1); - } - if (fp) { - fclose(fp); - } - return 0; -} - -//______________________________________________________________________________ -int ediff(const char* title, const char* macro, const char* dfile, const char* compiled = "compiled") -{ - // -- Call the system diff to compare 2 files (dfile and compiled). - FILE* fp = fopen(dfile, "a"); - fprintf(fp, "%s %s\n", title, macro); - fclose(fp); - char com[4096]; -#if G__VISUAL - const char* extraoption = "--strip-trailing-cr "; -#else // G__VISUAL - const char* extraoption = ""; -#endif // G__VISUAL - sprintf(com, "diff %s --old-group-format=\"%s %s:%%c'\\012'%%<\" --new-group-format=\"%s interpreted:%%c'\\012'%%>\" --unchanged-line-format=\"\" --old-line-format=\" %%3dn: %%L\" --new-line-format=\" %%3dn: %%L\" %s interpreted>> %s", extraoption, title, compiled, title, compiled, dfile); - int ret; - if (bIgnoreDiffErrors) { - // for now we want to continue despite diffs in the text - ret = system(com); - } else { - ret = run(com,false); - } - return ret; -} - -//______________________________________________________________________________ -bool check_skip(const char* sname) -{ - // -- FIXME: Describe this function! - if (debug) { - if (debug[0] == '+') { - if (debug[1] == '+') { - if (!strcmp(debug + 2, sname)) { - debug = 0; - } - return true; - } - else { - if (strcmp(debug + 1, sname)) { - return true; - } - else { - debug = 0; - } - } - } - else - if (strcmp(debug, sname)) { - return true; - } -#ifdef CONTINUE_TEST - else { - debug = 0; - } -#endif // CONTINUE_TEST - } - return false; -} - -//______________________________________________________________________________ -int buildDictionaryLibrary(ELanguage lang, const char *dir, const char* sname, const char* macro, const char* src, const char *suffix = "") -{ - // Generate the shared library with a dictionary for the test. - // Run makecint then run the generate makefile. - - char com[4096]; - - const char *hopt = lang == kLangCXX ? "H" : "h"; - - sprintf(com, "cd %s %s makecint -mk Makefile%s %s -dl test%s.dll %s -%s ../%s %s", - dir, shellSeparator, suffix, mkcintoption.c_str(), suffix, macro, hopt, sname, src); - run(com); - sprintf(com, "cd %s %s make -f Makefile%s",dir,shellSeparator,suffix); - run(com); - -} - - -//______________________________________________________________________________ -int ci(ELanguage lang, const char* sname, const char* dfile, const char* cflags = "", const char* exsname = "", const char* cintopt = "", const char *dir = ".") -{ - // -- Compare compiled and interpreted result. - if (check_skip(sname)) { - return 0; - } - printf("%s %s %s\n", sname, cflags, exsname); - char exename[4096]; - strcpy(exename, sname); - char* posExt = strrchr(exename, '.'); - if (posExt) { - strcpy(posExt, ".exe"); - } - // compile source - const char* comp = 0; - const char* flags = 0; - const char* macros = 0; - const char* ldflags = 0; - const char* link = ""; - if (lang == kLangC) { - comp = G__CFG_CC; - flags = G__CFG_CFLAGS; - ldflags = G__CFG_LDFLAGS; - macros = G__CFG_CMACROS; - } - else if (lang == kLangCXX) { - comp = G__CFG_CXX; - flags = G__CFG_CXXFLAGS; - ldflags = G__CFG_LDFLAGS; - macros = G__CFG_CXXMACROS; - } - else { - printf("ERROR in ci: language is not set!\n"); - return 0; - } -#if defined(G__WIN32) - link = "/link"; -#endif - char com[4096]; - sprintf(com, "%s -Dcompiled %s %s %s %s %s %s %s%s %s %s", comp, cflags, - compileroption.c_str(), - flags, macros, sname, exsname, G__CFG_COUTEXE, exename, link, ldflags); - //fprintf(stderr, "ci: run: %s\n", com); - run(com); - // run compiled program -#ifdef G__WIN32 - sprintf(com, ".\\%s > compiled", exename); -#else // G__WIN32 - sprintf(com, "./%s > compiled", exename); -#endif // G__WIN32 - //fprintf(stderr, "ci: run: %s\n", com); - run(com); -#ifdef DEBUG2 - //fprintf(stderr, "ci: run: %s\n", exename); - run(exename); -#endif // DEBUG2 -#ifndef DEBUG - //fprintf(stderr, "ci: rm %s\n", exename); - rm(exename); -#endif // DEBUG -#if defined(G__WIN32) || defined(G__CYGWIN) - if (posExt) { - strcpy(posExt, ".obj"); - } - rm(exename); - if (posExt) { - strcpy(posExt, ".exe.manifest"); - } - rm(exename); - if (posExt) { - strcpy(posExt, ".pdb"); - } - rm(exename); -#endif // G__WIN32 || G__CYGWIN -#ifdef G__BORLAND - if (posExt) { - strcpy(posExt, ".tds"); - } - rm(exename); -#endif - // run interpreted program - sprintf(com, "%s @CintName@ -I%s %s %s -Dinterp %s %s %s %s > interpreted", prefixcmd.c_str(), dir, cintoption.c_str(), debug ? "-DDEBUG" : "", cintopt, cflags, exsname, sname); - //fprintf(stderr, "ci: run: %s\n", com); - run(com); - int ret = ediff(sname, cflags, dfile); -#ifndef DEBUG - //fprintf(stderr, "ci: rm %s\n", "compiled"); - rm("compiled"); - //fprintf(stderr, "ci: rm %s\n", "interpreted"); - rm("interpreted"); -#endif // DEBUG - return ret; -} - -//______________________________________________________________________________ -int io(const char* sname, const char* old, const char*dfile, const char* macro = "") -{ - // -- Check output of interpreted program. - if (check_skip(sname)) { - return 0; - } - printf("%s\n", sname); - // run interpreted program - char com[4096]; - sprintf(com, "%s @CintName@ %s %s %s > interpreted", prefixcmd.c_str(), cintoption.c_str(), macro, sname); - run(com); - int ret = ediff(sname, "", dfile, old); - //diff(sname, old, "interpreted", dfile, "", "o", "i"); - rm("interpreted"); - return ret; -} - -//______________________________________________________________________________ -int mkc(ELanguage lang, const char* sname, const char* dfile, const char* macro = "", const char* src = "") -{ - // -- Check difference in output between compiled and interpreted code, with dictionary. - if (check_skip(sname)) { - return 0; - } - printf("%s\n", sname); - - char *dir = cleanAndCreateDirectory(sname); - buildDictionaryLibrary(kLangCXX, dir, sname, macro, src); - - char com[4096]; - // run interpreted program - sprintf(com, "-DHNAME=\\\"%s\\\" -DDNAME=\\\"%s/test.dll\\\"", sname,dir); - int ret = ci(lang, "mkcmain.cxx", dfile, com, "", "", dir); -#ifndef DEBUG - cleanDirectory(dir); -#endif // DEBUG - delete [] dir; - return ret; -} - -//______________________________________________________________________________ -int mkco(ELanguage lang, const char* sname, const char* hname, const char* old, const char* dfile, const char* macro = "", const char* src = "", const char* cintopt = "") -{ - // -- Check output of interpreted code, with dictionary. - if (check_skip(sname)) { - return 0; - } - printf("%s\n", sname); - char *dir = cleanAndCreateDirectory(sname); - buildDictionaryLibrary(lang, dir, hname, macro, src); - - // run interpreted program - char imacro[4096]; - sprintf(imacro, "%s -Dmakecint", macro); - int ret = io(sname, old, dfile, imacro); - -#ifndef DEBUG - cleanDirectory(dir); -#endif // DEBUG - delete [] dir; - return ret; -} - -//______________________________________________________________________________ -int mkci(ELanguage lang, const char* sname, const char* hname, const char* dfile, const char* macro = "", const char* src = "", const char* cintopt = "") -{ - // -- Check difference in output of compiled and interpreted code, with dictionary. - if (check_skip(sname)) { - return 0; - } - printf("%s\n", sname); - char *dir = cleanAndCreateDirectory(sname); - buildDictionaryLibrary(lang, dir, hname, macro, src); - - // run interpreted program - char imacro[4096]; - sprintf(imacro, "%s -Dmakecint", macro); - int ret = ci(lang, sname, dfile, imacro, "", cintopt, dir); - -#ifndef DEBUG - cleanDirectory(dir); - #endif // DEBUG - delete [] dir; - return ret; -} - -//______________________________________________________________________________ -int mkciN(ELanguage lang, const char* sname, const char* hname1, const char* dfile, const char* macro = "", const char* hname2 = "", const char* hname3 = "") -{ - // -- Check difference in output between compiled and interpreted code, with up to three dictionaries. - if (check_skip(sname)) { - return 0; - } - printf("%s\n", sname); - - char *dir = cleanAndCreateDirectory( sname ); - buildDictionaryLibrary(lang, dir, hname1, macro, "", "1"); - if (hname2[0]) buildDictionaryLibrary(lang, dir, hname2, macro, "", "2"); - if (hname3[0]) buildDictionaryLibrary(lang, dir, hname3, macro, "", "3"); - - // run interpreted program - char imacro[4096]; - sprintf(imacro, "%s -Dmakecint2", macro); - int ret = ci(lang, sname, dfile, imacro, "", "", dir); -#ifndef DEBUG - cleanDirectory( dir ); -#endif // DEBUG - delete [] dir; - return ret; -} - -//______________________________________________________________________________ -int testn(ELanguage lang, const char* hdr, int* num, const char* ext, const char* dfile, const char* macro = "") -{ - // -- Test series of files with enumerated suffix. - char sname[4096]; - int ret = 0; - int i = 0; - while (num[i] != -1) { - sprintf(sname, "%s%d%s", hdr, num[i], ext); - ret += ci(lang, sname, dfile, macro); - ++i; - } - return ret; -} - -//______________________________________________________________________________ -int main(int argc, char** argv) -{ - // Put this default first so it can be - // over-ridden - cintoption += " -O0 "; - - const char* difffile = "testdiff.txt"; - const char* filename; - - for (int i=0;i \n",argv[0]); - return 1; - } - - - if (!strcmp("-f", argv[1])) { - filename = argv[2]; - /* - filename = argv[3]; - cout<<"Long: "< \n",argv[0]); - return 1; - } - - clear(difffile); - -int ret = 0; - - if (!strcmp("simple01.cxx", filename)) { - fprintf(stderr,"Bin hier.\n"); - ret += io("simple01.cxx","simple01.ref",difffile,"-DTARGET=\\\"simple01.cxx\\\""); - } - else if (!strcmp("simple10.cxx", filename)) { - ret += ci(kLangCXX, "simple10.cxx", difffile); - } - else if (!strcmp("simple11.cxx", filename)) { - ret += ci(kLangCXX, "simple11.cxx", difffile); - ret += mkci(kLangCXX, "simple11.cxx", "simple11.cxx", difffile); - } - else if (!strcmp("simple12.cxx", filename)) { - ret += io("simple12.cxx", "simple12.ref", difffile); - } - else if (!strcmp("simple13.cxx", filename)) { - ret += io("simple13.cxx", "simple13.ref", difffile); - } - else if (!strcmp("simple14.cxx", filename)) { - ret += ci(kLangCXX, "simple14.cxx", difffile); - } - else if (!strcmp("simple15.cxx", filename)) { - ret += ci(kLangCXX, "simple15.cxx", difffile); - } - else if (!strcmp("simple16.cxx", filename)) { - ret += ci(kLangCXX, "simple16.cxx", difffile); - } - else if (!strcmp("simple17.cxx", filename)) { - ret += ci(kLangCXX, "simple17.cxx", difffile); - } - else if (!strcmp("simple18.cxx", filename)) { - ret += ci(kLangCXX, "simple18.cxx", difffile); - } - else if (!strcmp("simple19.cxx", filename)) { - ret += ci(kLangCXX, "simple19.cxx", difffile); - } - else if (!strcmp("simple20.cxx", filename)) { - ret += io("simple20.cxx", "simple20.ref", difffile); - } - else if (!strcmp("simple21.cxx", filename)) { - ret += io("simple21.cxx", "simple21.ref", difffile); - } - else if (!strcmp("simple22.cxx", filename)) { - ret += io("simple22.cxx", "simple22.ref", difffile); - } - else if (!strcmp("simple23.cxx", filename)) { - ret += io("simple23.cxx", "simple23.ref", difffile); - } - else if (!strcmp("simple24.cxx", filename)) { - ret += io("simple24.cxx", "simple24.ref", difffile); - } - else if (!strcmp("simple25.cxx", filename)) { - ret += mkci(kLangCXX,"simple25.cxx","simple25.h",difffile); - } - else if (!strcmp("cpp0.cxx", filename)) { - ret += ci(kLangCXX, "cpp0.cxx", difffile); - } - else if (!strcmp("cpp1.cxx", filename)) { - ret += ci(kLangCXX, "cpp1.cxx", difffile); - } - else if (!strcmp("cpp2.cxx", filename)) { - ret += ci(kLangCXX, "cpp2.cxx", difffile); - } - else if (!strcmp("cpp3.cxx", filename)) { - ret += ci(kLangCXX, "cpp3.cxx", difffile); - } - else if (!strcmp("cpp4.cxx", filename)) { - ret += ci(kLangCXX, "cpp4.cxx", difffile); - } - else if (!strcmp("cpp5.cxx", filename)) { - ret += ci(kLangCXX, "cpp5.cxx", difffile); - } - else if (!strcmp("cpp6.cxx", filename)) { - ret += ci(kLangCXX, "cpp6.cxx", difffile); - } - else if (!strcmp("cpp8.cxx", filename)) { - ret += ci(kLangCXX, "cpp8.cxx", difffile); - } - else if (!strcmp("bool01.cxx", filename)) { - ret += ci(kLangCXX, "bool01.cxx", difffile); - } - else if (!strcmp("switch.cxx", filename)) { - ret += ci(kLangCXX, "switch.cxx", difffile); - } - else if (!strcmp("refassign.cxx", filename)) { - ret += ci(kLangCXX, "refassign.cxx", difffile); - } - else if (!strcmp("ostream.cxx", filename)) { - // cout << pointer - ret += ci(kLangCXX, "ostream.cxx", difffile); - } - else if (!strcmp("setw0.cxx", filename)) { - ret += ci(kLangCXX, "setw0.cxx", difffile); - } - else if (!strcmp("inherit0.cxx", filename)) { - ret += ci(kLangCXX, "inherit0.cxx", difffile); - } - else if (!strcmp("inherit1.cxx", filename)) { - ret += ci(kLangCXX, "inherit1.cxx", difffile); - } - else if (!strcmp("inherit2.cxx", filename)) { - ret += ci(kLangCXX, "inherit2.cxx", difffile); - } - else if (!strcmp("virtualfunc0.cxx", filename)) { - ret += ci(kLangCXX, "virtualfunc0.cxx", difffile); - } - else if (!strcmp("virtualfunc1.cxx", filename)) { - ret += ci(kLangCXX, "virtualfunc1.cxx", difffile); - } - else if (!strcmp("virtualfunc2.cxx", filename)) { - ret += ci(kLangCXX, "virtualfunc2.cxx", difffile); - } - else if (!strcmp("oprovld0.cxx", filename)) { - ret += ci(kLangCXX, "oprovld0.cxx", difffile); - } - else if (!strcmp("oprovld2.cxx", filename)) { - ret += ci(kLangCXX, "oprovld2.cxx", difffile); - } - else if (!strcmp("constary.cxx", filename)) { - ret += ci(kLangCXX, "constary.cxx", difffile); - } - else if (!strcmp("const.cxx", filename)) { - ret += ci(kLangCXX, "const.cxx", difffile); - } - else if (!strcmp("scope0.cxx", filename)) { - ret += ci(kLangCXX, "scope0.cxx", difffile); - } - else if (!strcmp("idxscope0.cxx", filename)) { - ret += ci(kLangCXX, "idxscope0.cxx", difffile); - } - else if (!strcmp("access0.cxx", filename)) { - ret += ci(kLangCXX, "access0.cxx", difffile); - } - else if (!strcmp("staticmem0.cxx", filename)) { - ret += ci(kLangCXX, "staticmem0.cxx", difffile); - } - else if (!strcmp("staticmem1.cxx", filename)) { - ret += ci(kLangCXX, "staticmem1.cxx", difffile); - } - else if (!strcmp("staticary.cxx", filename)) { - ret += ci(kLangCXX, "staticary.cxx", difffile); - } - else if (!strcmp("static_object.cxx", filename)) { - ret += ci(kLangCXX, "static_object.cxx", difffile); - } - else if (!strcmp("static_string.cxx", filename)) { - ret += ci(kLangCXX, "static_string.cxx", difffile); - } - else if (!strcmp("static_call.cxx", filename)) { - ret += ci(kLangCXX, "static_call.cxx", difffile); - } - else if (!strcmp("minexam.cxx", filename)) { - ret += ci(kLangCXX, "minexam.cxx", difffile); - } - else if (!strcmp("btmplt.cxx", filename)) { - ret += ci(kLangCXX, "btmplt.cxx", difffile); - } - else if (!strcmp("loopcompile1.cxx", filename)) { - ret += ci(kLangCXX, "loopcompile1.cxx", difffile); - } - else if (!strcmp("loopcompile2.cxx", filename)) { - ret += ci(kLangCXX, "loopcompile2.cxx", difffile); - } - else if (!strcmp("loopcompile3.cxx", filename)) { - ret += ci(kLangCXX, "loopcompile3.cxx", difffile); - } - else if (!strcmp("loopcompile4.cxx", filename)) { - ret += ci(kLangCXX, "loopcompile4.cxx", difffile); - } - else if (!strcmp("loopcompile5.cxx", filename)) { - ret += ci(kLangCXX, "loopcompile5.cxx", difffile); - } - else if (!strcmp("mfstatic.cxx", filename)) { - ret += ci(kLangCXX, "mfstatic.cxx", difffile); - } - else if (!strcmp("new0.cxx", filename)) { - ret += ci(kLangCXX, "new0.cxx", difffile); - } - else if (!strcmp("template0.cxx", filename)) { - ret += ci(kLangCXX, "template0.cxx", difffile); - } - else if (!strcmp("template1.cxx", filename)) { - ret += ci(kLangCXX, "template1.cxx", difffile); - } - else if (!strcmp("template2.cxx", filename)) { - ret += ci(kLangCXX, "template2.cxx", difffile); - } - else if (!strcmp("template3.cxx", filename)) { - ret += io("template3.cxx", "template3.ref", difffile); - } - else if (!strcmp("template4.cxx", filename)) { - ret += ci(kLangCXX, "template4.cxx", difffile); - } - else if (!strcmp("template5.cxx", filename)) { - #if defined(G__MSC_VER)&&(G__MSC_VER<=1200) - ret += 0; - #else - ret += ci(kLangCXX, "template5.cxx", difffile); - #endif // G__MSC__VER && (G__MSC_VER <= 1200) - } - else if (!strcmp("template6.cxx", filename)) { - ret += ci(kLangCXX, "template6.cxx", difffile); - } - else if (!strcmp("minherit0.cxx", filename)) { - ret += ci(kLangCXX, "minherit0.cxx", difffile); - } - else if (!strcmp("enumscope.cxx", filename)) { - ret += ci(kLangCXX, "enumscope.cxx", difffile); - } - else if (!strcmp("baseconv0.cxx", filename)) { - ret += ci(kLangCXX, "baseconv0.cxx", difffile); - } - else if (!strcmp("friend0.cxx", filename)) { - ret += ci(kLangCXX, "friend0.cxx", difffile); - } - else if (!strcmp("anonunion.cxx", filename)) { - ret += ci(kLangCXX, "anonunion.cxx", difffile); - } - else if (!strcmp("init1.cxx", filename)) { - ret += ci(kLangCXX, "init1.cxx", difffile); - } - else if (!strcmp("init2.cxx", filename)) { - ret += ci(kLangCXX, "init2.cxx", difffile); - } - else if (!strcmp("include.cxx", filename)) { - ret += ci(kLangCXX, "include.cxx", difffile); - } - else if (!strcmp("eh1.cxx", filename)) { - ret += ci(kLangCXX, "eh1.cxx", difffile); - } - else if (!strcmp("ifs.cxx", filename)) { - ret += ci(kLangCXX, "ifs.cxx", difffile); - } - else if (!strcmp("bitfield.cxx", filename)) { - ret += ci(kLangCXX, "bitfield.cxx", difffile); - } - else if (!strcmp("cout1.cxx", filename)) { - ret += ci(kLangCXX, "cout1.cxx", difffile); - } - else if (!strcmp("longlong.cxx", filename)) { - ret += ci(kLangCXX, "longlong.cxx", difffile); - } - else if (!strcmp("explicitdtor.cxx", filename)) { - //fails due to base class dtor - ret += ci(kLangCXX, "explicitdtor.cxx", difffile); - } - else if (!strcmp("nick3.cxx", filename)) { - ret += ci(kLangCXX, "nick3.cxx", difffile); - } - else if (!strcmp("nick4.cxx", filename)) { - ret += ci(kLangCXX, "nick4.cxx", difffile); - ret += ci(kLangCXX, "nick4.cxx", difffile, "-DDEST"); - } - else if (!strcmp("telea0.cxx", filename)) { - ret += ci(kLangCXX, "telea0.cxx", difffile); - } - else if (!strcmp("telea1.cxx", filename)) { - ret += ci(kLangCXX, "telea1.cxx", difffile); - } - else if (!strcmp("telea2.cxx", filename)) { - ret += ci(kLangCXX, "telea2.cxx", difffile); - } - else if (!strcmp("telea3.cxx", filename)) { - ret += ci(kLangCXX, "telea3.cxx", difffile); - } - else if (!strcmp("telea5.cxx", filename)) { - ret += ci(kLangCXX, "telea5.cxx", difffile); - } - else if (!strcmp("telea6.cxx", filename)) { - ret += ci(kLangCXX, "telea6.cxx", difffile); - } - else if (!strcmp("telea7.cxx", filename)) { - ret += ci(kLangCXX, "telea7.cxx", difffile); - } - else if (!strcmp("fwdtmplt.cxx", filename)) { - ret += ci(kLangCXX, "fwdtmplt.cxx", difffile); - } - else if (!strcmp("VPersonTest.cxx", filename)) { - ret += ci(kLangCXX, "VPersonTest.cxx", difffile); - } - else if (!strcmp("convopr0.cxx", filename)) { - ret += ci(kLangCXX, "convopr0.cxx", difffile); - } - else if (!strcmp("nstmplt1.cxx", filename)) { - ret += ci(kLangCXX, "nstmplt1.cxx", difffile); - } - else if (!strcmp("aoki0.cxx", filename)) { - ret += ci(kLangCXX, "aoki0.cxx", difffile); - } - else if (!strcmp("borg1.cxx", filename)) { - ret += ci(kLangCXX, "borg1.cxx", difffile); - } - else if (!strcmp("borg2.cxx", filename)) { - ret += ci(kLangCXX, "borg2.cxx", difffile); - } - else if (!strcmp("bruce1.cxx", filename)) { - // This test currently fails because the char** argument is - // registered as a char *& - ret += ci(kLangCXX, "bruce1.cxx", difffile); - } - else if (!strcmp("fons3.cxx", filename)) { - ret += ci(kLangCXX, "fons3.cxx", difffile); - } - else if (!strcmp("Test0.cxx", filename)) { - ret += ci(kLangCXX, "Test0.cxx", difffile, "", "MyString.cxx"); - } - else if (!strcmp("Test1.cxx", filename)) { - ret += ci(kLangCXX, "Test1.cxx", difffile, "", "Complex.cxx MyString.cxx"); - } - else if (!strcmp("delete0.cxx", filename)) { - ret += ci(kLangCXX, "delete0.cxx", difffile); - } - else if (!strcmp("pb19.cxx", filename)) { - ret += ci(kLangCXX, "pb19.cxx", difffile); - } - else if (!strcmp("autocc.cxx", filename)) { - #ifdef AUTOCC - ret += ci(kLangCXX, "autocc.cxx", difffile); - system("rm G__*"); - #else - ret += 0; - #endif // AUTOCC - } - else if (!strcmp("maincmplx.cxx", filename)) { - ret += ci(kLangCXX, "maincmplx.cxx", difffile, "", "complex1.cxx"); - } - else if (!strcmp("funcmacro.cxx", filename)) { - ret += ci(kLangCXX, "funcmacro.cxx", difffile); - } - else if (!strcmp("template.cxx", filename)) { - ret += ci(kLangCXX, "template.cxx", difffile); - ret += mkci(kLangCXX, "template.cxx", "template.h", difffile); - } - else if (!strcmp("vase.cxx", filename)) { - ret += ci(kLangCXX, "vbase.cxx", difffile); - ret += mkci(kLangCXX, "vbase.cxx", "vbase.h", difffile); - } - else if (!strcmp("vbase1.cxx", filename)) { - ret += ci(kLangCXX, "vbase1.cxx", difffile); - ret += mkci(kLangCXX, "vbase1.cxx", "vbase1.h", difffile); - } - else if (!strcmp("t674.cxx", filename)) { - #define PROBLEM - #if defined(PROBLEM) && (!defined(G__WIN32) || defined(FORCEWIN32)) - // Problem with VC++6.0 - ret += mkci(kLangCXX, "t674.cxx", "t674.h", difffile); - #else - ret += 0; - #endif // PROBLEM && (!G__WIN32 || FORCEWIN32) - } - else if (!strcmp("t648.cxx", filename)) { - #define PROBLEM - #if defined(PROBLEM) && (!defined(G__WIN32) || defined(FORCEWIN32)) - // long long has problem with BC++5.5 - // also with VC++6.0 bug different - ret += ci(kLangCXX, "t648.cxx", difffile); - #else - ret += 0; - #endif // PROBLEM && (!G__WIN32 || FORCEWIN32) - } - else if (!strcmp("t977.cxx", filename)) { - #define PROBLEM - #if defined(PROBLEM) && (!defined(G__WIN32) || defined(FORCEWIN32)) - // VC++ problem is known - ret += mkci(kLangCXX,"t977.cxx","t977.h",difffile); - #else - ret += 0; - #endif // PROBLEM && (!G__WIN32 || FORCEWIN32) - } - else if (!strcmp("t980.cxx", filename)) { - #define PROBLEM - #if defined(PROBLEM) && (!defined(G__WIN32) || defined(FORCEWIN32)) - // problem with BC++5.5 - ret += ci(kLangCXX, "t980.cxx", difffile); - #else - ret += 0; - #endif // PROBLEM && (!G__WIN32 || FORCEWIN32) - } - else if (!strcmp("t1030.cxx", filename)) { - #define PROBLEM - #if defined(PROBLEM) && (!defined(G__WIN32) || defined(FORCEWIN32)) - #if (G__GNUC==2) - // works only with gcc2.96 - ret += mkci(kLangCXX, "t1030.cxx", "t1030.h", difffile); - ret += mkci(kLangCXX,"t1030.cxx","t1030.h",difffile,"","","-Y0"); - #else - ret += 0; - #endif // G__GNUC == 2 - #else - ret += 0; - #endif // PROBLEM && (!G__WIN32 || FORCEWIN32) - } - else if (!strcmp("t1031.cxx", filename)) { - #define PROBLEM - #if defined(PROBLEM) && (!defined(G__WIN32) || defined(FORCEWIN32)) - #if (G__GNUC==2) - // works only with gcc2.96 - ret += mkci(kLangCXX, "t1031.cxx", "t1031.h", difffile); - ret += mkci(kLangCXX,"t1031.cxx","t1031.h",difffile,"","","-Y0"); - #else - ret += 0; - #endif // G__GNUC == 2 - #else - ret += 0; - #endif // PROBLEM && (!G__WIN32 || FORCEWIN32) - } - else if (!strcmp("t215.cxx", filename)) { - ret += ci(kLangCXX, "t215.cxx", difffile); - } - else if (!strcmp("t358.cxx", filename)) { - ret += ci(kLangCXX, "t358.cxx", difffile); - } - else if (!strcmp("t488.cxx", filename)) { - ret += ci(kLangCXX, "t488.cxx", difffile); - } - else if (!strcmp("t516.cxx", filename)) { - ret += ci(kLangCXX, "t516.cxx", difffile); - } - else if (!strcmp("t603.cxx", filename)) { - ret += ci(kLangCXX, "t603.cxx", difffile); - } - else if (!strcmp("t627.cxx", filename)) { - ret += ci(kLangCXX, "t627.cxx", difffile); - ret += mkci(kLangCXX, "t627.cxx", "t627.h", difffile); - } - else if (!strcmp("t630.cxx", filename)) { - ret += ci(kLangCXX, "t630.cxx", difffile); - } - else if (!strcmp("t633.cxx", filename)) { - ret += ci(kLangCXX, "t633.cxx", difffile); - ret += mkci(kLangCXX, "t633.cxx", "t633.h", difffile); - } - else if (!strcmp("t634.cxx", filename)) { - ret += ci(kLangCXX, "t634.cxx", difffile); - } - else if (!strcmp("t674.cxx", filename)) { - ret += ci(kLangCXX, "t674.cxx", difffile, "-DINTERPRET"); - } - else if (!strcmp("t676.cxx", filename)) { - #if !defined(G__WIN32) && !defined(G__CYGWIN) && !defined(G__APPLE) - //recursive call stack too deep for Visual C++ - ret += ci(kLangCXX, "t676.cxx", difffile); - #endif // !G__WIN32 && !G__CYGWIN && !G__APPLE - } - else if (!strcmp("t694.cxx", filename)) { - ret += mkci(kLangCXX, "t694.cxx", "t694.h", difffile); - //fails due to default param - ret += ci(kLangCXX, "t694.cxx", difffile, "-DINTERPRET"); - } - else if (!strcmp("t695.cxx", filename)) { - //fails due to tmplt specialization - ret += ci(kLangCXX, "t695.cxx", difffile); - } - else if (!strcmp("t705.cxx", filename)) { - ret += mkci(kLangCXX, "t705.cxx", "t705.h", difffile); - ret += ci(kLangCXX, "t705.cxx", difffile, "-DINTERPRET"); - } - else if (!strcmp("t714.cxx", filename)) { - ret += ci(kLangCXX, "t714.cxx", difffile); - } - else if (!strcmp("t733.cxx", filename)) { - ret += io("t733.cxx", "t733.ref", difffile); - } - else if (!strcmp("t749.cxx", filename)) { - #if !defined(G__WIN32) || defined(FORCEWIN32) - //NOT WORKING: in debug mode on WINDOWS! - ret += ci(kLangCXX,"t749.cxx",difffile); - #endif // !G__WIN32 || FORCEWIN32 - } - else if (!strcmp("t751.cxx", filename)) { - ret += ci(kLangCXX, "t751.cxx", difffile); - } - else if (!strcmp("t764.cxx", filename)) { - ret += ci(kLangCXX, "t764.cxx", difffile); - } - else if (!strcmp("t767.cxx", filename)) { - ret += ci(kLangCXX, "t767.cxx", difffile); - } - else if (!strcmp("t776.cxx", filename)) { - ret += ci(kLangCXX, "t776.cxx", difffile); - } - else if (!strcmp("t777.cxx", filename)) { - ret += ci(kLangCXX, "t777.cxx", difffile); - } - else if (!strcmp("t784.cxx", filename)) { - ret += ci(kLangCXX, "t784.cxx", difffile); - } - else if (!strcmp("t825.cxx", filename)) { - ret += ci(kLangCXX, "t825.cxx", difffile); - } - else if (!strcmp("t910.cxx", filename)) { - ret += ci(kLangCXX, "t910.cxx", difffile); - } - else if (!strcmp("t916.cxx", filename)) { - ret += ci(kLangCXX, "t916.cxx", difffile); - } - else if (!strcmp("t927.cxx", filename)) { - #if !defined(G__VISUAL) || defined(FORCEWIN32) - #if G__CINTVERSION < 70000000 - ret += io("t927.cxx","t927.ref5",difffile); - #else - ret += io("t927.cxx","t927.ref",difffile); - #endif - #endif // !G__VISUAL || FORCEWIN32 - } - else if (!strcmp("t928.cxx", filename)) { - #if !defined(G__WIN32) || defined(FORCEWIN32) - ret += mkciN(kLangCXX, "t928.cxx", "t928.h", difffile, "", "t928a.h", "t928b.h"); - #endif // !G__WIN32 | FORCEWIN32 - } - else if (!strcmp("t930.cxx", filename)) { - ret += ci(kLangCXX, "t930.cxx", difffile); - } - else if (!strcmp("t938.cxx", filename)) { - ret += ci(kLangCXX, "t938.cxx", difffile); - } - else if (!strcmp("t958.cxx", filename)) { - ret += ci(kLangCXX, "t958.cxx", difffile); - } - else if (!strcmp("t959.cxx", filename)) { - ret += ci(kLangCXX, "t959.cxx", difffile); - } - else if (!strcmp("t961.cxx", filename)) { - ret += mkci(kLangCXX, "t961.cxx", "t961.h", difffile); - //mkc(kLangCXX,"t961.h",difffile); - } - else if (!strcmp("t963.cxx", filename)) { - //Borland C++5.5 has a problem - //with reverse_iterator::reference - ret += ci(kLangCXX, "t963.cxx", difffile); - } - else if (!strcmp("t966.cxx", filename)) { - #ifdef G__P2F - ret += mkci(kLangCXX, "t966.cxx", "t966.h", difffile); - #endif // G__P2F - } - else if (!strcmp("t968.cxx", filename)) { - // problem with BC++5.5 & VC++6.0 - ret += mkci(kLangCXX, "t968.cxx", "t968.h", difffile); - } - else if (!strcmp("t970.cxx", filename)) { - ret += mkci(kLangCXX, "t970.cxx", "t970.h", difffile); - } - else if (!strcmp("t972.cxx", filename)) { - ret += mkciN(kLangCXX, "t972.cxx", "t972a.h", difffile, "", "t972b.h"); - } - else if (!strcmp("t980.cxx", filename)) { - #if !defined(G__WIN32) || defined(FORCEWIN32) - ret += mkci(kLangCXX, "t980.cxx", "t980.h", difffile); - #endif // !G__WIN32 | FORCEWIN32 - } - else if (!strcmp("t986.cxx", filename)) { - #if !defined(G__WIN32) || defined(FORCEWIN32) - ret += ci(kLangCXX, "t986.cxx", difffile, "-DTEST"); - #endif // !G__WIN32 | FORCEWIN32 - } - else if (!strcmp("t987.cxx", filename)) { - ret += mkci(kLangCXX, "t987.cxx", "t987.h", difffile); - } - else if (!strcmp("t991.cxx", filename)) { - ret += mkciN(kLangCXX, "t991.cxx", "t991a.h", difffile, "", "t991b.h", "t991c.h"); - } - else if (!strcmp("t992.cxx", filename)) { - ret += mkci(kLangCXX, "t992.cxx", "t992.h", difffile); // problem gcc3.2 - } - else if (!strcmp("maptest.cxx", filename)) { - ret += mkci(kLangCXX, "maptest.cxx", "maptest.h", difffile); // problem icc - } - else if (!strcmp("t993.c", filename)) { - ret += mkci(kLangC, "t993.c", "t993.h", difffile); - } - else if (!strcmp("t995.cxx", filename)) { - ret += mkci(kLangCXX, "t995.cxx", "t995.h", difffile); - } - else if (!strcmp("t996.cxx", filename)) { - ret += mkci(kLangCXX, "t996.cxx", "t996.h", difffile); - } - else if (!strcmp("t998.cxx", filename)) { - ret += ci(kLangCXX, "t998.cxx", difffile); - } - else if (!strcmp("t1002.cxx", filename)) { - ret += mkci(kLangCXX, "t1002.cxx", "t1002.h", difffile); - } - else if (!strcmp("t1004.cxx", filename)) { - ret += ci(kLangCXX, "t1004.cxx", difffile); - } - else if (!strcmp("t1011.cxx", filename)) { - ret += ci(kLangCXX, "t1011.cxx", difffile); - ret += mkci(kLangCXX, "t1011.cxx", "t1011.h", difffile); - } - else if (!strcmp("t1015.cxx", filename)) { - ret += ci(kLangCXX, "t1015.cxx", difffile); - } - else if (!strcmp("t1016.cxx", filename)) { - ret += ci(kLangCXX, "t1016.cxx", difffile); - ret += mkci(kLangCXX, "t1016.cxx", "t1016.h", difffile); - } - else if (!strcmp("t1023.cxx", filename)) { - ret += ci(kLangCXX, "t1023.cxx", difffile); - } - else if (!strcmp("t1024.cxx", filename)) { - ret += ci(kLangCXX, "t1024.cxx", difffile); - ret += mkci(kLangCXX, "t1024.cxx", "t1024.h", difffile); - } - else if (!strcmp("t1025.cxx", filename)) { - #if !defined(G__WIN32) || defined(FORCEWIN32) - ret += mkci(kLangCXX, "t1025.cxx", "t1025.h", difffile); - #endif // !G__WIN32 | FORCEWIN32 - } - else if (!strcmp("t1026.cxx", filename)) { - ret += ci(kLangCXX, "t1026.cxx", difffile); // problem with BC++5.5 - ret += mkci(kLangCXX, "t1026.cxx", "t1026.h", difffile); - } - else if (!strcmp("t1027.cxx", filename)) { - ret += io("t1027.cxx", "t1027.ref", difffile); - //ret += ci(kLangCXX,"t1027.cxx",difffile); // problem with BC++5.5 - //ret += mkci(kLangCXX,"t1027.cxx","t1027.h",difffile); - } - else if (!strcmp("t1032.cxx", filename)) { - ret += ci(kLangCXX, "t1032.cxx", difffile); - ret += ci(kLangCXX, "t1032.cxx", difffile); - } - else if (!strcmp("t1034a.cxx", filename)) { - ret += ci(kLangCXX, "t1034a.cxx", difffile); - } - else if (!strcmp("t1034.cxx", filename)) { - #if !defined(G__WIN32) || defined(FORCEWIN32) - if (sizeof(long double)==16) { - // sizeof(long double)==16 - ret += io("t1034.cxx", "t1034.ref64", difffile); - } else if (sizeof(long)==4) { - // sizeof(long double)==12 - ret += io("t1034.cxx", "t1034.ref", difffile); - } else if (sizeof(void*)==8) { - // sizeof(long double)==16 - ret += io("t1034.cxx", "t1034.ref64", difffile); - } else { - // sizeof(long double)==12 - ret += io("t1034.cxx", "t1034.refXX", difffile); - } - #endif // !G__WIN32 | FORCEWIN32 - } - else if (!strcmp("t1035.cxx", filename)) { - ret += ci(kLangCXX, "t1035.cxx", difffile); - ret += mkci(kLangCXX, "t1035.cxx", "t1035.h", difffile); - } - else if (!strcmp("t1036.cxx", filename)) { - ret += ci(kLangCXX, "t1036.cxx", difffile); - } - else if (!strcmp("t1040.cxx", filename)) { - ret += mkci(kLangCXX, "t1040.cxx", "t1040.h", difffile); // gcc3.2 has problem - } - else if (!strcmp("t1042.cxx", filename)) { - ret += io("t1042.cxx", "t1042.ref", difffile); - } - else if (!strcmp("t1046.cxx", filename)) { - #if !defined(G__WIN32) || defined(FORCEWIN32) - ret += ci(kLangCXX,"t1046.cxx",difffile); - ret += mkci(kLangCXX,"t1046.cxx","t1046.h",difffile); - #endif // !G__WIN32 | FORCEWIN32 - } - else if (!strcmp("t1047.cxx", filename)) { - ret += ci(kLangCXX, "t1047.cxx", difffile); - ret += mkci(kLangCXX, "t1047.cxx", "t1047.h", difffile); - } - else if (!strcmp("t1048.cxx", filename)) { - ret += ci(kLangCXX, "t1048.cxx", difffile); - ret += mkci(kLangCXX, "t1048.cxx", "t1048.h", difffile, "-I.. -I../../inc -I../../src -I../../reflex/inc"); - } - else if (!strcmp("t1049.cxx", filename)) { - ret += ci(kLangCXX, "t1049.cxx", difffile); - } - else if (!strcmp("t1054.cxx", filename)) { - ret += ci(kLangCXX, "t1054.cxx", difffile); - } - else if (!strcmp("t1055.cxx", filename)) { - ret += ci(kLangCXX, "t1055.cxx", difffile); - } - else if (!strcmp("t1061.cxx", filename)) { - ret += mkci(kLangCXX, "t1061.cxx", "t1061.h", difffile); - } - else if (!strcmp("t1062.cxx", filename)) { - #if !defined(G__WIN32) || defined(FORCEWIN32) - ret += mkci(kLangCXX, "t1062.cxx", "t1062.h", difffile); - #endif // !G__WIN32 | FORCEWIN32 - } - else if (!strcmp("t1067.cxx", filename)) { - ret += ci(kLangCXX, "t1067.cxx", difffile); - ret += mkci(kLangCXX, "t1067.cxx", "t1067.h", difffile); - } - else if (!strcmp("t1068.cxx", filename)) { - ret += ci(kLangCXX, "t1068.cxx", difffile); - ret += mkci(kLangCXX, "t1068.cxx", "t1068.h", difffile); - } - else if (!strcmp("t1079.cxx", filename)) { - ret += ci(kLangCXX, "t1079.cxx", difffile); - ret += mkci(kLangCXX, "t1079.cxx", "t1079.h", difffile); - } - else if (!strcmp("t1084.cxx", filename)) { - ret += ci(kLangCXX, "t1084.cxx", difffile); - } - else if (!strcmp("t1085.cxx", filename)) { - ret += ci(kLangCXX, "t1085.cxx", difffile); - } - else if (!strcmp("t1086.cxx", filename)) { - ret += ci(kLangCXX, "t1086.cxx", difffile); - } - else if (!strcmp("t1088.cxx", filename)) { - ret += ci(kLangCXX, "t1088.cxx", difffile); - } - else if (!strcmp("t1094.cxx", filename)) { - ret += ci(kLangCXX, "t1094.cxx", difffile); - } - else if (!strcmp("t1101.cxx", filename)) { - ret += ci(kLangCXX, "t1101.cxx", difffile); - } - else if (!strcmp("t1115.cxx", filename)) { - ret += mkci(kLangCXX, "t1115.cxx", "t1115.h", difffile); - } - else if (!strcmp("t1124.cxx", filename)) { - ret += ci(kLangCXX, "t1124.cxx", difffile); - } - else if (!strcmp("t1125.cxx", filename)) { - ret += ci(kLangCXX, "t1125.cxx", difffile); - } - else if (!strcmp("t1126.cxx", filename)) { - ret += ci(kLangCXX, "t1126.cxx", difffile); - } - else if (!strcmp("t1127.cxx", filename)) { - #if !defined(G__APPLE) - // This not work on macos and on 64bit linux because of var_arg - if (sizeof(void*)<8 || (G__CINTVERSION > 70000000) ) { - ret += ci(kLangCXX, "t1127.cxx", difffile); - ret += mkci(kLangCXX, "t1127.cxx", "t1127.h", difffile); // - } - #endif // !G__APPLE - } - else if (!strcmp("t1128.cxx", filename)) { - ret += ci(kLangCXX, "t1128.cxx", difffile); // looks to me gcc3.2 has a bug - } - else if (!strcmp("t1129.cxx", filename)) { - ret += ci(kLangCXX, "t1129.cxx", difffile); // g++3.2 fails - } - else if (!strcmp("t1134.cxx", filename)) { - ret += ci(kLangCXX, "t1134.cxx", difffile); - } - else if (!strcmp("t1136.cxx", filename)) { - ret += ci(kLangCXX, "t1136.cxx", difffile); - } - else if (!strcmp("t1140.cxx", filename)) { - ret += ci(kLangCXX, "t1140.cxx", difffile); - } - else if (!strcmp("t1144.cxx", filename)) { - ret += ci(kLangCXX,"t1144.cxx",difffile); - ret += ci(kLangCXX,"t1144.cxx",difffile,"","","-Y0"); - ret += ci(kLangCXX,"t1144.cxx",difffile,"","","-Y1"); - } - else if (!strcmp("t1148.cxx", filename)) { - ret += ci(kLangCXX, "t1148.cxx", difffile); - } - else if (!strcmp("t1157.cxx", filename)) { - ret += ci(kLangCXX, "t1157.cxx", difffile); - } - else if (!strcmp("t1158.cxx", filename)) { - ret += ci(kLangCXX, "t1158.cxx", difffile); - } - else if (!strcmp("t1160.cxx", filename)) { - ret += ci(kLangCXX, "t1160.cxx", difffile); - } - else if (!strcmp("aryinit0.cxx", filename)) { - ret += ci(kLangCXX, "aryinit0.cxx", difffile); - } - else if (!strcmp("aryinit1.cxx", filename)) { - ret += ci(kLangCXX, "aryinit1.cxx", difffile); - } - else if (!strcmp("t1164.cxx", filename)) { - ret += ci(kLangCXX, "t1164.cxx", difffile); - } - else if (!strcmp("t1165.cxx", filename)) { - ret += ci(kLangCXX, "t1165.cxx", difffile); - } - else if (!strcmp("t1178.cxx", filename)) { - ret += ci(kLangCXX, "t1178.cxx", difffile); - } - else if (!strcmp("t1187.cxx", filename)) { - ret += mkci(kLangCXX, "t1187.cxx", "t1187.h", difffile); - } - else if (!strcmp("t1192.cxx", filename)) { - ret += ci(kLangCXX, "t1192.cxx", difffile); - } - else if (!strcmp("t1193.cxx", filename)) { - ret += mkci(kLangCXX, "t1193.cxx", "t1193.h", difffile); - } - else if (!strcmp("t1203.cxx", filename)) { - ret += ci(kLangCXX, "t1203.cxx", difffile); - } - else if (!strcmp("t1205.cxx", filename)) { - ret += ci(kLangCXX, "t1205.cxx", difffile); - ret += mkci(kLangCXX, "t1205.cxx", "t1205.h", difffile); - } - else if (!strcmp("t1213.cxx", filename)) { - ret += ci(kLangCXX, "t1213.cxx", difffile); - } - else if (!strcmp("t1214.cxx", filename)) { - ret += ci(kLangCXX, "t1214.cxx", difffile); - } - else if (!strcmp("t1215.cxx", filename)) { - ret += ci(kLangCXX, "t1215.cxx", difffile); - ret += mkci(kLangCXX, "t1215.cxx", "t1215.h", difffile); - } - else if (!strcmp("t1221.cxx", filename)) { - ret += ci(kLangCXX, "t1221.cxx", difffile); - } - else if (!strcmp("t1222.cxx", filename)) { - ret += ci(kLangCXX, "t1222.cxx", difffile); - } - else if (!strcmp("t1223.cxx", filename)) { - ret += ci(kLangCXX, "t1223.cxx", difffile); - } - else if (!strcmp("t1224.cxx", filename)) { - ret += ci(kLangCXX, "t1224.cxx", difffile); - } - else if (!strcmp("t1228.cxx", filename)) { - ret += io("t1228.cxx", "t1228.ref", difffile); - } - else if (!strcmp("t1247.cxx", filename)) { - ret += mkciN(kLangCXX, "t1247.cxx", "t1247.h", difffile, "", "t1247a.h"); - } - else if (!strcmp("t1276.cxx", filename)) { - ret += mkci(kLangCXX, "t1276.cxx", "t1276.h", difffile); - } - else if (!strcmp("t1277.cxx", filename)) { - // works only with gcc2.96 - ret += mkci(kLangCXX, "t1277.cxx", "t1277.h", difffile); - } - else if (!strcmp("t1278.cxx", filename)) { - ret += ci(kLangCXX, "t1278.cxx", difffile); - } - else if (!strcmp("t1279.cxx", filename)) { - ret += ci(kLangCXX, "t1279.cxx", difffile); - } - else if (!strcmp("t1280.cxx", filename)) { - ret += ci(kLangCXX, "t1280.cxx", difffile); - } - else if (!strcmp("t1281.cxx", filename)) { - ret += ci(kLangCXX, "t1281.cxx", difffile); - } - else if (!strcmp("t1282.cxx", filename)) { - ret += ci(kLangCXX, "t1282.cxx", difffile); - } - else if (!strcmp("t1283.cxx", filename)) { - ret += ci(kLangCXX, "t1283.cxx", difffile); - } - else if (!strcmp("t1284.cxx", filename)) { - ret += ci(kLangCXX, "t1284.cxx", difffile); - } - else if (!strcmp("t1286.cxx", filename)) { - #if G__CINTVERSION > 70000000 - ret += ci(kLangCXX, "t1286.cxx", difffile); - #endif - } - else if (!strcmp("postinc.cxx", filename)) { - ret += ci(kLangCXX, "postinc.cxx", difffile); - } - else if (!strcmp("selfreference.cxx", filename)) { - ret += mkci(kLangCXX, "selfreference.cxx", "selfreference.h", difffile); - } - else if (!strcmp("abstract.cxx", filename)) { - ret += ci(kLangCXX, "abstract.cxx", difffile); - } - else if (!strcmp("TExeception.cxx", filename)) { - ret += ci(kLangCXX, "TException.cxx", difffile); - } - else if (!strcmp("enums.cxx", filename)) { - ret += mkci(kLangCXX, "enums.cxx", "enums.h", difffile); - } - else if (!strcmp("classinfo.cxx", filename)) { - ret += io("classinfo.cxx", "classinfo.ref", difffile); - } - else if (!strcmp("iostream_state.cxx", filename)) { - ret += ci(kLangCXX, "iostream_state.cxx", difffile); - } - else { - fprintf(stderr,"The test %s is not supported.\n",filename); - ret += 1; - } - - if (0==ret) { - fprintf(stderr,"The test %s succeed.\n",filename); - return ret; - } else { - fprintf(stderr,"The test %s fail.\n",filename); - return ret; - } -} - -/* - * Local Variables: - * c-tab-always-indent:nil - * c-indent-level:3 - * c-continued-statement-offset:3 - * c-brace-offset:-3 - * c-brace-imaginary-offset:0 - * c-argdecl-indent:0 - * c-label-offset:-3 - * compile-command:"make -k" - * End: - */ diff --git a/cmake/scripts/thisroot.sh b/cmake/scripts/thisroot.sh deleted file mode 100755 index 7a03e9bd49fcb..0000000000000 --- a/cmake/scripts/thisroot.sh +++ /dev/null @@ -1,67 +0,0 @@ -# Source this script to set up the ROOT build that this script is part of. -# -# Conveniently an alias like this can be defined in .bashrc: -# alias thisroot=". bin/thisroot.sh" -# -# This script if for the bash like shells, see thisroot.csh for csh like shells. -# -# Author: Fons Rademakers, 18/8/2006 - -if [ "x${BASH_ARGV[0]}" = "x" ]; then - if [ ! -f bin/thisroot.sh ]; then - echo ERROR: must "cd where/root/is" before calling ". bin/thisroot.sh" for this version of bash! - ROOTSYS=; export ROOTSYS - return - fi - ROOTSYS="$PWD"; export ROOTSYS -else - # get param to "." - THIS=$(dirname ${BASH_ARGV[0]}) - ROOTSYS=$(cd ${THIS}/..;pwd); export ROOTSYS -fi - -if [ -z "${PATH}" ]; then - PATH=@bindir@; export PATH -else - PATH=@bindir@:$PATH; export PATH -fi - -if [ -z "${LD_LIBRARY_PATH}" ]; then - LD_LIBRARY_PATH=@libdir@; export LD_LIBRARY_PATH # Linux, ELF HP-UX -else - LD_LIBRARY_PATH=@libdir@:$LD_LIBRARY_PATH; export LD_LIBRARY_PATH -fi - -if [ -z "${DYLD_LIBRARY_PATH}" ]; then - DYLD_LIBRARY_PATH=@libdir@; export DYLD_LIBRARY_PATH # Mac OS X -else - DYLD_LIBRARY_PATH=@libdir@:$DYLD_LIBRARY_PATH; export DYLD_LIBRARY_PATH -fi - -if [ -z "${SHLIB_PATH}" ]; then - SHLIB_PATH=@libdir@; export SHLIB_PATH # legacy HP-UX -else - SHLIB_PATH=@libdir@:$SHLIB_PATH; export SHLIB_PATH -fi - -if [ -z "${LIBPATH}" ]; then - LIBPATH=@libdir@; export LIBPATH # AIX -else - LIBPATH=@libdir@:$LIBPATH; export LIBPATH -fi - -if [ -z "${PYTHONPATH}" ]; then - PYTHONPATH=@libdir@; export PYTHONPATH -else - PYTHONPATH=@libdir@:$PYTHONPATH; export PYTHONPATH -fi - -if [ -z "${MANPATH}" ]; then - MANPATH=`dirname @mandir@`; export MANPATH -else - MANPATH=`dirname @mandir@`:$MANPATH; export MANPATH -fi - -if [ "x`root-config --arch | grep -v win32gcc | grep -i win32`" != "x" ]; then - ROOTSYS="`cygpath -w $ROOTSYS`" -fi diff --git a/config/ARCHS b/config/ARCHS index 8e5cf9e110eae..99fd5f79c2902 100644 --- a/config/ARCHS +++ b/config/ARCHS @@ -23,6 +23,7 @@ linuxppcgcc for PPC Linux with gcc linuxppc64gcc for PPC 64 Linux with gcc >= 3 linuxx8664gcc for x86-64 Linux with gcc >= 3.x linuxx8664icc for x86-64 Linux with Intel icc >=10.x +linuxx8664k1omicc for x86-64 Intel Many Integrated Cores Linux with Intel icc >=13.x lynxos for LynxOS with gcc macosx for MacOS X >= 10.4 with gcc macosxicc for MacOS X >= 10.4 with Intel icc (Intel only) diff --git a/config/Makefile.depend b/config/Makefile.depend index c3509396e322f..63cf27d18d302 100644 --- a/config/Makefile.depend +++ b/config/Makefile.depend @@ -40,7 +40,7 @@ PROOFDRAWLIBDEPM = $(TREEPLAYERLIB) $(G3DLIB) $(GRAFLIB) $(GPADLIB) \ $(PROOFPLAYERLIB) $(HISTLIB) $(TREELIB) $(PROOFLIB) PROOFXLIBDEPM = $(NETLIB) $(PROOFLIB) $(THREADLIB) PROOFBENCHLIBDEPM = $(PROOFLIB) $(PROOFDRAWLIB) $(PROOFPLAYERLIB) \ - $(TREELIB) $(HISTLIB) $(GPADLIB) $(IOLIB) + $(TREELIB) $(GRAFLIB) $(HISTLIB) $(GPADLIB) $(IOLIB) SESSIONVIEWERLIBDEPM = $(PROOFLIB) $(GUILIB) $(HISTLIB) $(GPADLIB) \ $(GRAFLIB) $(TREELIB) $(MATHCORELIB) X3DLIBDEPM = $(G3DLIB) $(GUILIB) @@ -53,6 +53,7 @@ PHYSICSLIBDEPM = $(MATRIXLIB) $(MATHCORELIB) PYTHIA6LIBDEPM = $(EGLIB) $(GRAFLIB) $(VMCLIB) $(PHYSICSLIB) PYTHIA8LIBDEPM = $(EGLIB) $(GRAFLIB) $(VMCLIB) $(PHYSICSLIB) XMLLIBDEPM = $(IOLIB) +DAVIXLIBDEPM = $(NETLIB) $(IOLIB) $(THREADLIB) TABLELIBDEPM = $(TREELIB) $(GPADLIB) $(G3DLIB) $(GRAFLIB) $(HISTLIB) \ $(IOLIB) $(MATHCORELIB) MLPLIBDEPM = $(HISTLIB) $(MATRIXLIB) $(TREELIB) $(GRAFLIB) \ @@ -69,7 +70,7 @@ SPLOTLIBDEPM = $(MATRIXLIB) $(HISTLIB) $(TREELIB) $(TREEPLAYERLIB) \ QUADPLIBDEPM = $(MATRIXLIB) GLLIBDEPM = $(G3DLIB) $(GUILIB) $(GRAFLIB) $(HISTLIB) $(GEDLIB) \ $(MATHCORELIB) $(TREELIB) $(TREEPLAYERLIB) -COCOALIBDEPM = $(GUILIB) $(QUARTZLIB) +COCOALIBDEPM = $(GUILIB) $(QUARTZLIB) $(GRAFLIB) HBOOKLIBDEPM = $(HISTLIB) $(MATRIXLIB) $(TREELIB) $(GRAFLIB) \ $(TREEPLAYERLIB) $(IOLIB) $(MINICERNLIB) GEOMLIBDEPM = $(IOLIB) $(THREADLIB) $(MATHCORELIB) @@ -117,9 +118,11 @@ HDFSLIBDEPM = $(IOLIB) SQLLIBDEPM = $(NETLIB) $(IOLIB) ODBCLIBDEPM = $(NETLIB) $(IOLIB) NETXLIBDEPM = $(NETLIB) $(IOLIB) $(THREADLIB) +NETXNGLIBDEPM = $(NETLIB) $(IOLIB) $(THREADLIB) ORACLELIBDEPM = $(NETLIB) $(IOLIB) CASTORLIBDEPM = $(NETLIB) $(IOLIB) PGSQLLIBDEPM = $(NETLIB) $(IOLIB) +SQLITELIBDEPM = $(NETLIB) $(IOLIB) MYSQLLIBDEPM = $(NETLIB) $(IOLIB) GDMLLIBDEPM = $(GEOMLIB) $(XMLLIB) $(HISTLIB) $(IOLIB) UNURANLIBDEPM = $(HISTLIB) $(MATHCORELIB) @@ -197,6 +200,7 @@ GQTLIBDEP = $(GQTLIBDEPM) RUBYLIBDEP = $(RUBYLIBDEPM) GUIBLDLIBDEP = $(GUIBLDLIBDEPM) XMLLIBDEP = $(XMLLIBDEPM) +DAVIXLIBDEP = $(DAVIXLIBDEPM) FOAMLIBDEP = $(FOAMLIBDEPM) ALIENLIBDEP = $(ALIENLIBDEPM) ROOFITCORELIBDEP = $(ROOFITCORELIBDEPM) @@ -219,9 +223,11 @@ HDFSLIBDEP = $(HDFSLIBDEPM) SQLLIBDEP = $(SQLLIBDEPM) ODBCLIBDEP = $(ODBCLIBDEPM) NETXLIBDEP = $(NETXLIBDEPM) +NETXNGLIBDEP = $(NETXNGLIBDEPM) ORACLELIBDEP = $(ORACLELIBDEPM) CASTORLIBDEP = $(CASTORLIBDEPM) PGSQLLIBDEP = $(PGSQLLIBDEPM) +SQLITELIBDEP = $(SQLITELIBDEPM) MYSQLLIBDEP = $(MYSQLLIBDEPM) GDMLLIBDEP = $(GDMLLIBDEPM) UNURANLIBDEP = $(UNURANLIBDEPM) @@ -287,7 +293,7 @@ PROOFDRAWLIBEXTRA = lib/libTreePlayer.lib lib/libGraf3d.lib \ lib/libTree.lib lib/libProof.lib PROOFXLIBEXTRA = lib/libNet.lib lib/libProof.lib lib/libThread.lib PROOFBENCHLIBEXTRA = lib/libProof.lib lib/libProofDraw.lib \ - lib/libProofPlayer.lib lib/libTree.lib \ + lib/libProofPlayer.lib lib/libTree.lib lib/libGraf.lib \ lib/libHist.lib lib/libGpad.lib lib/libRIO.lib SESSIONVIEWERLIBEXTRA = lib/libProof.lib lib/libGui.lib lib/libHist.lib \ lib/libGpad.lib lib/libGraf.lib lib/libTree.lib \ @@ -342,6 +348,7 @@ RUBYLIBEXTRA = lib/libHist.lib lib/libMathCore.lib GUIBLDLIBEXTRA = lib/libGui.lib lib/libGraf.lib lib/libMathCore.lib GUIHTMLLIBEXTRA = lib/libGui.lib lib/libGraf.lib lib/libNet.lib XMLLIBEXTRA = lib/libRIO.lib +DAVIXLIBEXTRA = lib/libNet.lib lib/libRIO.lib lib/libThread.lib FOAMLIBEXTRA = lib/libHist.lib lib/libMathCore.lib ALIENLIBEXTRA = lib/libXMLIO.lib lib/libNetx.lib lib/libTree.lib \ lib/libProof.lib lib/libProofPlayer.lib \ @@ -384,9 +391,11 @@ HDFSLIBEXTRA = lib/libRIO.lib SQLLIBEXTRA = lib/libNet.lib lib/libRIO.lib ODBCLIBEXTRA = lib/libNet.lib lib/libRIO.lib NETXLIBEXTRA = lib/libNet.lib lib/libRIO.lib lib/libThread.lib +NETXNGLIBEXTRA = lib/libNet.lib lib/libRIO.lib lib/libThread.lib ORACLELIBEXTRA = lib/libNet.lib lib/libRIO.lib CASTORLIBEXTRA = lib/libNet.lib lib/libRIO.lib PGSQLLIBEXTRA = lib/libNet.lib lib/libRIO.lib +SQLITELIBEXTRA = lib/libNet.lib lib/libRIO.lib MYSQLLIBEXTRA = lib/libNet.lib lib/libRIO.lib GDMLLIBEXTRA = lib/libGeom.lib lib/libXMLIO.lib lib/libHist.lib \ lib/libRIO.lib @@ -441,7 +450,7 @@ PROOFDRAWLIBEXTRA = -Llib -lTreePlayer -lGraf3d -lGraf -lGpad \ -lProofPlayer -lHist -lTree -lProof PROOFXLIBEXTRA = -Llib -lNet -lProof -lThread PROOFBENCHLIBEXTRA = -Llib -lProof -lProofDraw -lProofPlayer -lTree \ - -lHist -lGpad -lRIO + -lGraf -lHist -lGpad -lRIO SESSIONVIEWERLIBEXTRA = -Llib -lProof -lGui -lHist -lGpad -lGraf -lTree \ -lMathCore CLARENSLIBEXTRA = -Llib -lMathCore @@ -458,7 +467,7 @@ TABLELIBEXTRA = -Llib -lTree -lGpad -lGraf3d -lGraf -lHist -lRIO \ -lMathCore GLLIBEXTRA = -Llib -lGpad -lGraf3d -lGui -lGraf -lHist -lGed \ -lMathCore -lTree -lTreePlayer -lRIO -COCOALIBEXTRA = -Llib -lGui -lGQuartz +COCOALIBEXTRA = -Llib -lGui -lGraf -lGQuartz HBOOKLIBEXTRA = -Llib -lHist -lMatrix -lTree -lGraf -lTreePlayer \ -lRIO -lminicern GEOMLIBEXTRA = -Llib -lRIO -lThread -lMathCore @@ -484,22 +493,23 @@ RUBYLIBEXTRA = -Llib -lHist -lMathCore GUIBLDLIBEXTRA = -Llib -lGui -lGraf -lMathCore GUIHTMLLIBEXTRA = -Llib -lGui -lGraf -lNet XMLLIBEXTRA = -Llib -lRIO +DAVIXLIBEXTRA = -Llib -lNet -lRIO -lThread FOAMLIBEXTRA = -Llib -lHist -lMathCore ALIENLIBEXTRA = -Llib -lXMLIO -lNetx -lTree -lProof -lProofPlayer \ -lNet -lRIO ROOFITCORELIBEXTRA = -Llib -lHist -lGraf -lMatrix -lTree -lMinuit -lRIO \ -lMathCore -lFoam ROOFITLIBEXTRA = -Llib -lRooFitCore -lTree -lRIO -lMatrix -lMathCore -ifeq ($(BUILDMATHMORE),yes) -ROOFITLIBEXTRA += -lMathMore -ROOSTATSLIBEXTRA += -lMathMore -HISTFACTORYLIBEXTRA += -lMathMore -endif ROOSTATSLIBEXTRA = -Llib -lRooFit -lRooFitCore -lTree -lRIO -lHist \ -lMatrix -lMathCore -lMinuit -lFoam -lGraf -lGpad HISTFACTORYLIBEXTRA = -Llib -lRooFit -lRooFitCore -lTree -lRIO -lHist \ -lMatrix -lMathCore -lMinuit -lFoam -lGraf -lGpad \ -lRooStats -lXMLParser +ifeq ($(BUILDMATHMORE),yes) +ROOFITLIBEXTRA += -lMathMore +ROOSTATSLIBEXTRA += -lMathMore +HISTFACTORYLIBEXTRA += -lMathMore +endif CINTEXLIBEXTRA = -Llib -lReflex REFLEXDICTLIBEXTRA = -Llib -lReflex RAUTHLIBEXTRA = -Llib -lNet -lRIO @@ -516,9 +526,11 @@ HDFSLIBEXTRA = -Llib -lRIO SQLLIBEXTRA = -Llib -lNet -lRIO ODBCLIBEXTRA = -Llib -lNet -lRIO NETXLIBEXTRA = -Llib -lNet -lRIO -lThread +NETXNGLIBEXTRA = -Llib -lNet -lRIO -lThread ORACLELIBEXTRA = -Llib -lNet -lRIO CASTORLIBEXTRA = -Llib -lNet -lRIO PGSQLLIBEXTRA = -Llib -lNet -lRIO +SQLITELIBEXTRA = -Llib -lNet -lRIO MYSQLLIBEXTRA = -Llib -lNet -lRIO GDMLLIBEXTRA = -Llib -lGeom -lXMLIO -lHist -lRIO UNURANLIBEXTRA = -Llib -lHist -lMathCore diff --git a/config/Makefile.in b/config/Makefile.in index 291c433a4c917..73b8a2a22d792 100644 --- a/config/Makefile.in +++ b/config/Makefile.in @@ -58,6 +58,13 @@ XPMLIB := @xpmlib@ XFTLIB := @enable_xft@ BUILDCOCOA := @buildcocoa@ +MACOSXVERS := @macosxvers@ +OSXSDK := @osxsdk@ +IOSVERS := @iosvers@ +IOSSDK := @iossdk@ + +CXX11 := @c++11@ +LIBCXX := @libc++@ EXPLICITLINK := @explicitlink@ @@ -106,6 +113,11 @@ PGSQLLIBDIR := @pgsqllibdir@ PGSQLCLILIB := @pgsqllib@ PGSQLINCDIR := $(filter-out /usr/include, @pgsqlincdir@) +BUILDSQLITE := @buildsqlite@ +SQLITELIBDIR := @sqlitelibdir@ +SQLITECLILIB := @sqlitelib@ +SQLITEINCDIR := $(filter-out /usr/include, @sqliteincdir@) + BUILDSAPDB := @buildsapdb@ SAPDBLIBDIR := @sapdblibdir@ SAPDBCLILIB := @sapdblib@ @@ -136,6 +148,11 @@ CASTORCLILIB := @castorlib@ CASTORINCDIR := $(filter-out /usr/include, @castorincdir@) CASTORCFLAGS := @castorcflags@ +BUILDDAVIX := @builddavix@ +DAVIXLIBDIR := @davixlibdir@ +DAVIXCLILIB := @davixlib@ +DAVIXINCDIR := $(filter-out /usr/include, @davixincdir@) + BUILDDCAP := @builddcap@ DCAPLIBDIR := @dcaplibdir@ DCAPLIB := @dcaplib@ @@ -161,6 +178,8 @@ BUILDGFAL := @buildgfal@ GFALLIBDIR := @gfallibdir@ GFALCLILIB := @gfallib@ GFALINCDIR := $(filter-out /usr/include, @gfalincdir@) +SRMIFCEINCDIR := $(filter-out /usr/include, @srmifceincdir@) +GLIB2INCDIR := $(filter-out /usr/include, @glib2incdir@) BUILDGLITE := @buildglite@ GLITELIBDIR := @glitelibdir@ @@ -210,7 +229,7 @@ FPYTHIA6LIB := @pythia6lib@ FPYTHIA6CPPFLAGS := @pythia6cppflags@ BUILDFPYTHIA8 := @buildpythia8@ -FPYTHIA8INCDIR := @pythia8incdir@ +FPYTHIA8INCDIR := $(filter-out /usr/include, @pythia8incdir@) FPYTHIA8LIBDIR := @pythia8libdir@ FPYTHIA8LIB := @pythia8lib@ @@ -252,6 +271,8 @@ XRDLIBDIR := @xrdlibdir@ EXTRA_XRDFLAGS := @extraxrdflags@ XRDVERSION := @xrdversion@ HASXRDUTILS := @hasxrdutils@ +XRDINCPRIVATE := @xrdincprivate@ +BUILDNETXNG := @buildnetxng@ SRPLIBDIR := @srplibdir@ SRPLIB := @srplib@ @@ -340,12 +361,6 @@ BUILDTABLE := @buildtable@ BUILDTMVA := @buildtmva@ -BUILDCLARENS := @buildclarens@ -CLARENSINC := $(filter-out -I/usr/include, @clarensincdir@) -CLARENSLIBS := @clarenslibs@ - -BUILDPEAC := @buildpeac@ - BUILDAFDSMGRD := @buildafdsmgrd@ AFDSMGRDAPMON := @afdsmgrdapmon@ diff --git a/config/Makefile.ios b/config/Makefile.ios index fca8f773c39f6..a75cd70183062 100644 --- a/config/Makefile.ios +++ b/config/Makefile.ios @@ -15,33 +15,33 @@ NOOPT = endif # iOS version -ifeq ($(IPHONEOS_DEPLOYMENT_TARGET),) -IOSVERS = 5.1 -else -IOSVERS = $(IPHONEOS_DEPLOYMENT_TARGET) -endif -XCODE_PATH := $(shell /usr/bin/xcode-select -print-path) IOS_MAJOR := $(shell echo $(IOSVERS) | cut -d . -f 1) -IOSSDK := $(XCODE_PATH)/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS$(IOSVERS).sdk # Compiler: ifeq ($(subst $(IOS_MAJOR),,1234),1234) CXX := $(shell xcrun -find clang++) CC := $(shell xcrun -find clang) +ifeq ($(CXX11),yes) +CXX11FLAGS = -std=c++11 +endif +ifeq ($(LIBCXX),yes) +CXX11FLAGS += -stdlib=libc++ +CXX11LDFLAGS = -stdlib=libc++ +endif else CXX := $(shell xcrun -find g++) CC := $(shell xcrun -find gcc) endif CXXFLAGS = -arch armv7 -pipe -Wshadow -W -Wall -Woverloaded-virtual \ - -fsigned-char -fno-common -fvisibility-inlines-hidden \ - $(EXTRA_CXXFLAGS) -isysroot $(IOSSDK) + -fsigned-char -fno-common \ + $(EXTRA_CXXFLAGS) -isysroot $(IOSSDK) $(CXX11FLAGS) CFLAGS = -arch armv7 -pipe -Wshadow -W -Wall -fsigned-char -fno-common \ $(EXTRA_CFLAGS) -isysroot $(IOSSDK) CINTCXXFLAGS = -arch armv7 -pipe -W -Wall -Woverloaded-virtual \ - -fsigned-char -fno-common -fvisibility-inlines-hidden \ + -fsigned-char -fno-common \ -DG__REGEXP -DG__UNIX -DG__SHAREDLIB \ -DG__ROOT -DG__REDIRECTIO -DG__OSFDLL \ - -DG__STD_EXCEPTION \ + -DG__STD_EXCEPTION $(CXX11FLAGS) \ $(EXTRA_CXXFLAGS) -isysroot $(IOSSDK) CINTCFLAGS = -arch armv7 -pipe -W -Wall -fsigned-char -fno-common \ -DG__REGEXP -DG__UNIX -DG__SHAREDLIB \ @@ -56,7 +56,7 @@ LD := $(shell xcrun -find clang++) else LD := $(shell xcrun -find g++) endif -LDFLAGS = $(OPT) -arch armv7 -isysroot $(IOSSDK) \ +LDFLAGS = $(CXX11LDFLAGS) $(OPT) -arch armv7 -isysroot $(IOSSDK) \ -miphoneos-version-min=$(IOSVERS) # this is set for 64 but not for 32 bit (for iOS too???) @@ -100,7 +100,4 @@ showld: showf77: @echo "$(F77)" - -showsdk: - @echo "$(IOSSDK)" endif diff --git a/config/Makefile.iossim b/config/Makefile.iossim index 3ed522dc570c8..990dc1b733013 100644 --- a/config/Makefile.iossim +++ b/config/Makefile.iossim @@ -15,33 +15,33 @@ NOOPT = endif # iOS version -ifeq ($(IPHONEOS_DEPLOYMENT_TARGET),) -IOSVERS = 5.1 -else -IOSVERS = $(IPHONEOS_DEPLOYMENT_TARGET) -endif -XCODE_PATH := $(shell /usr/bin/xcode-select -print-path) IOS_MAJOR := $(shell echo $(IOSVERS) | cut -d . -f 1) -IOSSDK := $(XCODE_PATH)/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator$(IOSVERS).sdk # Compiler: ifeq ($(subst $(IOS_MAJOR),,1234),1234) CXX := $(shell xcrun -find clang++) CC := $(shell xcrun -find clang) +ifeq ($(CXX11),yes) +CXX11FLAGS = -std=c++11 +endif +ifeq ($(LIBCXX),yes) +CXX11FLAGS += -stdlib=libc++ +CXX11LDFLAGS = -stdlib=libc++ +endif else CXX := $(shell xcrun -find g++) CC := $(shell xcrun -find gcc) endif CXXFLAGS = -arch i386 -pipe -Wshadow -W -Wall -Woverloaded-virtual \ - -fsigned-char -fno-common -fvisibility-inlines-hidden \ - $(EXTRA_CXXFLAGS) -isysroot $(IOSSDK) + -fsigned-char -fno-common \ + $(EXTRA_CXXFLAGS) -isysroot $(IOSSDK) $(CXX11FLAGS) CFLAGS = -arch i386 -pipe -Wshadow -W -Wall -fsigned-char -fno-common \ $(EXTRA_CFLAGS) -isysroot $(IOSSDK) CINTCXXFLAGS = -arch i386 -pipe -W -Wall -Woverloaded-virtual \ - -fsigned-char -fno-common -fvisibility-inlines-hidden \ + -fsigned-char -fno-common \ -DG__REGEXP -DG__UNIX -DG__SHAREDLIB \ -DG__ROOT -DG__REDIRECTIO -DG__OSFDLL \ - -DG__STD_EXCEPTION \ + -DG__STD_EXCEPTION $(CXX11FLAGS) \ $(EXTRA_CXXFLAGS) -isysroot $(IOSSDK) CINTCFLAGS = -arch i386 -pipe -W -Wall -fsigned-char -fno-common \ -DG__REGEXP -DG__UNIX -DG__SHAREDLIB \ @@ -56,7 +56,7 @@ LD := $(shell xcrun -find clang++) else LD := $(shell xcrun -find g++) endif -LDFLAGS = $(OPT) -arch i386 -isysroot $(IOSSDK) \ +LDFLAGS = $(CXX11LDFLAGS) $(OPT) -arch i386 -isysroot $(IOSSDK) \ -miphoneos-version-min=$(IOSVERS) # this is set for 64 but not for 32 bit (for iOS too???) @@ -100,7 +100,4 @@ showld: showf77: @echo "$(F77)" - -showsdk: - @echo "$(IOSSDK)" endif diff --git a/config/Makefile.linux b/config/Makefile.linux index 20544d5355c96..53b32463c955c 100644 --- a/config/Makefile.linux +++ b/config/Makefile.linux @@ -13,18 +13,18 @@ else OPT = $(OPTFLAGS) NOOPT = endif -ifeq (c++11,$(findstring c++11,$(ROOTBUILD))) -CXX11 = -std=c++11 +ifeq ($(CXX11),yes) +CXX11FLAGS = -std=c++11 -Wno-deprecated-declarations endif # Compiler: CXX = g++ CC = gcc CXXFLAGS = -pipe -m32 -Wall -W -Woverloaded-virtual \ - -fPIC $(EXTRA_CXXFLAGS) $(CXX11) + -fPIC $(EXTRA_CXXFLAGS) $(CXX11FLAGS) CFLAGS = -pipe -m32 -Wall -W -fPIC $(EXTRA_CFLAGS) CINTCXXFLAGS = -pipe -m32 -Wall -W -Woverloaded-virtual \ - -fPIC $(EXTRA_CXXFLAGS) $(CXX11) \ + -fPIC $(EXTRA_CXXFLAGS) $(CXX11FLAGS) \ -DG__REGEXP -DG__UNIX -DG__SHAREDLIB \ -DG__OSFDLL -DG__ROOT -DG__REDIRECTIO \ -DG__STD_EXCEPTION diff --git a/config/Makefile.linuxia64ecc b/config/Makefile.linuxia64ecc index b10d2f1b5b788..eaa5532749c19 100644 --- a/config/Makefile.linuxia64ecc +++ b/config/Makefile.linuxia64ecc @@ -37,7 +37,7 @@ CXXFLAGS += -wd1572 CFLAGS += -wd1572 CINTCXXFLAGS += -wd1572 CINTCFLAGS += -wd1572 -ICC_GE_9 = 9 +ICC_GE_9 = $(ICC_MAJOR) endif ifeq ($(ICC_MAJOR),10) @@ -45,19 +45,19 @@ CXXFLAGS += -wd1572 -wd873 -wd672 CFLAGS += -wd1572 CINTCXXFLAGS += -wd1572 -wd873 CINTCFLAGS += -wd1572 -ICC_GE_9 = 10 +ICC_GE_9 = $(ICC_MAJOR) ifneq ($(ICC_MINOR),0) -ICC_GE_101 = 101 +ICC_GE_101 = $(ICC_MAJOR)$(ICC_MINOR) endif endif -ifeq ($(ICC_MAJOR),11) -CXXFLAGS += -wd1572 -wd873 -wd672 -CFLAGS += -wd1572 -CINTCXXFLAGS += -wd1572 -wd873 -CINTCFLAGS += -wd1572 -ICC_GE_9 = 11 -ICC_GE_101 = 110 +ifeq ($(findstring $(ICC_MAJOR),10 9),) +CXXFLAGS += -m64 -wd1572 -wd873 -wd672 +CFLAGS += -m64 -wd1572 +CINTCXXFLAGS += -m64 -wd1572 -wd873 +CINTCFLAGS += -m64 -wd1572 +ICC_GE_9 = $(ICC_MAJOR) +ICC_GE_101 = $(ICC_MAJOR)$(ICC_MINOR) endif # Linker: diff --git a/config/Makefile.linuxicc b/config/Makefile.linuxicc index e891dc84dac0a..c60cbe5d67cb3 100644 --- a/config/Makefile.linuxicc +++ b/config/Makefile.linuxicc @@ -51,7 +51,7 @@ CXXFLAGS += -wd1572 CFLAGS += -wd1572 CINTCXXFLAGS += -wd1572 CINTCFLAGS += -wd1572 -ICC_GE_9 = 9 +ICC_GE_9 = $(ICC_MAJOR) endif ifeq ($(ICC_MAJOR),10) @@ -59,30 +59,20 @@ CXXFLAGS += -wd1572 CFLAGS += -wd1572 CINTCXXFLAGS += -wd1572 CINTCFLAGS += -wd1572 -ICC_GE_9 = 10 +ICC_GE_9 = $(ICC_MAJOR) ifneq ($(ICC_MINOR),0) -ICC_GE_101 = 101 +ICC_GE_101 = $(ICC_MAJOR)$(ICC_MINOR) endif endif -ifeq ($(ICC_MAJOR),11) -CXXFLAGS += -m32 -wd1572 -wd279 -CFLAGS += -m32 -wd1572 -wd279 -CINTCXXFLAGS += -m32 -wd1572 -wd279 -CINTCFLAGS += -m32 -wd1572 -wd279 -LDFLAGS += -m32 -ICC_GE_9 = 11 -ICC_GE_101 = 110 -endif - -ifeq ($(ICC_MAJOR),12) +ifeq ($(findstring $(ICC_MAJOR),10 9),) CXXFLAGS += -m32 -wd1572 -wd279 CFLAGS += -m32 -wd1572 -wd279 CINTCXXFLAGS += -m32 -wd1572 -wd279 CINTCFLAGS += -m32 -wd1572 -wd279 LDFLAGS += -m32 -ICC_GE_9 = 12 -ICC_GE_101 = 120 +ICC_GE_9 = $(ICC_MAJOR) +ICC_GE_101 = $(ICC_MAJOR)$(ICC_MINOR) endif # System libraries: @@ -96,7 +86,7 @@ CRYPTLIBS = -lcrypt ifeq ($(F77),ifort) F77 = ifort F77FLAGS = -fPIC -ifeq ($(ICC_MAJOR),12) +ifeq ($(findstring $(ICC_MAJOR),11 10 9),) F77LIBS := -L$(shell which ifort | sed -e 's|bin/ia32/ifort|compiler/lib|') \ -lifcore F77FLAGS += -m32 diff --git a/config/Makefile.linuxx8664gcc b/config/Makefile.linuxx8664gcc index 6601892c1a6a8..f2f483cba7bea 100644 --- a/config/Makefile.linuxx8664gcc +++ b/config/Makefile.linuxx8664gcc @@ -16,18 +16,18 @@ else OPT = $(OPTFLAGS) NOOPT = endif -ifeq (c++11,$(findstring c++11,$(ROOTBUILD))) -CXX11 = -std=c++11 +ifeq ($(CXX11),yes) +CXX11FLAGS = -std=c++11 -Wno-deprecated-declarations endif # Compiler: CXX = g++ CC = gcc CXXFLAGS = -pipe -m64 -Wshadow -Wall -W -Woverloaded-virtual \ - -fPIC $(EXTRA_CXXFLAGS) $(CXX11) + -fPIC $(EXTRA_CXXFLAGS) $(CXX11FLAGS) CFLAGS = -pipe -m64 -Wshadow -Wall -W -fPIC $(EXTRA_CFLAGS) CINTCXXFLAGS = -pipe -m64 -Wall -W -Woverloaded-virtual \ - -fPIC $(EXTRA_CXXFLAGS) $(CXX11) \ + -fPIC $(EXTRA_CXXFLAGS) $(CXX11FLAGS) \ -DG__REGEXP -DG__UNIX -DG__SHAREDLIB \ -DG__OSFDLL -DG__ROOT -DG__REDIRECTIO \ -DG__STD_EXCEPTION -DG__64BIT diff --git a/config/Makefile.linuxx8664icc b/config/Makefile.linuxx8664icc index af542cb376c62..6f375d2d7df59 100644 --- a/config/Makefile.linuxx8664icc +++ b/config/Makefile.linuxx8664icc @@ -51,7 +51,7 @@ CXXFLAGS += -wd1572 CFLAGS += -wd1572 CINTCXXFLAGS += -wd1572 CINTCFLAGS += -wd1572 -ICC_GE_9 = 9 +ICC_GE_9 = $(ICC_MAJOR) endif ifeq ($(ICC_MAJOR),10) @@ -59,30 +59,20 @@ CXXFLAGS += -wd1572 CFLAGS += -wd1572 CINTCXXFLAGS += -wd1572 CINTCFLAGS += -wd1572 -ICC_GE_9 = 10 +ICC_GE_9 = $(ICC_MAJOR) ifneq ($(ICC_MINOR),0) -ICC_GE_101 = 101 +ICC_GE_101 = $(ICC_MAJOR)$(ICC_MINOR) endif endif -ifeq ($(ICC_MAJOR),11) -CXXFLAGS += -m64 -wd1572 -wd279 -CFLAGS += -m64 -wd1572 -wd279 -CINTCXXFLAGS += -m64 -wd1572 -wd279 -CINTCFLAGS += -m64 -wd1572 -wd279 -LDFLAGS += -m64 -ICC_GE_9 = 11 -ICC_GE_101 = 110 -endif - -ifeq ($(ICC_MAJOR),12) +ifeq ($(findstring $(ICC_MAJOR),10 9),) CXXFLAGS += -m64 -wd1572 -wd279 CFLAGS += -m64 -wd1572 -wd279 CINTCXXFLAGS += -m64 -wd1572 -wd279 CINTCFLAGS += -m64 -wd1572 -wd279 LDFLAGS += -m64 -ICC_GE_9 = 12 -ICC_GE_101 = 120 +ICC_GE_9 = $(ICC_MAJOR) +ICC_GE_101 = $(ICC_MAJOR)$(ICC_MINOR) endif # System libraries: @@ -96,7 +86,7 @@ CRYPTLIBS = -lcrypt ifeq ($(F77),ifort) F77 = ifort F77FLAGS = -fPIC -ifeq ($(ICC_MAJOR),12) +ifeq ($(findstring $(ICC_MAJOR),11 10 9),) F77LIBS := -L$(shell which ifort | sed -e 's|bin/intel64/ifort|compiler/lib|') \ -lifcore F77FLAGS += -m64 diff --git a/config/Makefile.linuxx8664k1omicc b/config/Makefile.linuxx8664k1omicc new file mode 100644 index 0000000000000..44fa1e4303845 --- /dev/null +++ b/config/Makefile.linuxx8664k1omicc @@ -0,0 +1,108 @@ +# -*- mode: makefile -*- +# +# Makefile of ROOT for Linux on Intel Many Integrated Cores Architecture (Knights Corner) with icc >= v8 compiler + +PLATFORM = linux-k1om + +DEBUGFLAGS = -g +OPTFLAGS = -O +ifeq (debug,$(findstring debug,$(ROOTBUILD))) +OPT = $(DEBUGFLAGS) +NOOPT = -O0 +else +OPT = $(OPTFLAGS) +NOOPT = -O0 +endif + +# MIC flags +MICFLAGS = -mmic + +# Compiler: +CXX = icc +CC = icc +CXXFLAGS = -fPIC -wd1476 $(MICFLAGS) $(EXTRA_CXXFLAGS) -O2 -m64 -no-vec -no-fma -Wall -DWARNINGMSG +CFLAGS = -fPIC $(MICFLAGS) $(EXTRA_CFLAGS) -restrict +CINTCXXFLAGS = -fPIC $(MICFLAGS) $(EXTRA_CXXFLAGS) \ + -DG__REGEXP -DG__UNIX -DG__SHAREDLIB \ + -DG__OSFDLL -DG__ROOT -DG__REDIRECTIO \ + -DG__STD_EXCEPTION -DG__64BIT +CINTCFLAGS = -fPIC $(MICFLAGS) $(EXTRA_CFLAGS) -restrict \ + -DG__REGEXP -DG__UNIX -DG__SHAREDLIB \ + -DG__OSFDLL -DG__ROOT -DG__REDIRECTIO \ + -DG__STD_EXCEPTION -DG__64BIT + +# Linker: +LD = icpc +LDFLAGS = $(OPT) $(MICFLAGS) $(EXTRA_LDFLAGS) +SOFLAGS = -shared -Wl,-soname, +SOEXT = so + +# Compiler version: +ICC_MAJOR := $(shell $(CXX) -v 2>&1 | awk '{ if (NR==1) print $$2 }' | \ + cut -d'.' -f1) +ICC_MINOR := $(shell $(CXX) -v 2>&1 | awk '{ if (NR==1) print $$2 }' | \ + cut -d'.' -f2) +ifeq ($(ICC_MAJOR),version) +ICC_MAJOR := $(shell $(CXX) -v 2>&1 | awk '{ if (NR==1) print $$3 }' | \ + cut -d'.' -f1) +ICC_MINOR := $(shell $(CXX) -v 2>&1 | awk '{ if (NR==1) print $$3 }' | \ + cut -d'.' -f2) +endif + +ifeq ($(ICC_MAJOR),9) +CXXFLAGS += -wd1572 +CFLAGS += -wd1572 +CINTCXXFLAGS += -wd1572 +CINTCFLAGS += -wd1572 +ICC_GE_9 = $(ICC_MAJOR) +endif + +ifeq ($(ICC_MAJOR),10) +CXXFLAGS += -wd1572 +CFLAGS += -wd1572 +CINTCXXFLAGS += -wd1572 +CINTCFLAGS += -wd1572 +ICC_GE_9 = $(ICC_MAJOR) +ifneq ($(ICC_MINOR),0) +ICC_GE_101 = $(ICC_MAJOR)$(ICC_MINOR) +endif +endif + +ifeq ($(findstring $(ICC_MAJOR),10 9),) +CXXFLAGS += -m64 -wd1572 -wd279 +CFLAGS += -m64 -wd1572 -wd279 +CINTCXXFLAGS += -m64 -wd1572 -wd279 +CINTCFLAGS += -m64 -wd1572 -wd279 +LDFLAGS += -m64 +ICC_GE_9 = $(ICC_MAJOR) +ICC_GE_101 = $(ICC_MAJOR)$(ICC_MINOR) +endif + +# System libraries: +SYSLIBS = -limf -lm -ldl $(OSTHREADLIBDIR) $(OSTHREADLIB) \ + $(ALLOCLIBDIR) $(ALLOCLIB) -rdynamic +XLIBS = $(XPMLIBDIR) $(XPMLIB) $(X11LIBDIR) -lXext -lX11 +CILIBS = -limf -lm -ldl -rdynamic +CRYPTLIBS = -lcrypt + +# Fortran: +ifeq ($(F77),ifort) +F77 = ifort +F77FLAGS = -fPIC +ifeq ($(findstring $(ICC_MAJOR),11 10 9),) +F77LIBS := -L$(shell which ifort | sed -e 's|bin/intel64/ifort|compiler/lib|') \ + -lifcore +F77FLAGS += -m64 +else +ifeq ($(ICC_MAJOR),11) +F77LIBS := -L$(shell which ifort | sed -e 's|bin/intel64/ifort|lib/intel64|') \ + -lifcore +F77FLAGS += -m64 +else +F77LIBS := -L$(shell which ifort | sed -e 's|bin/ifort|lib|') \ + -lifcore +endif +endif +endif + +# Extras diff --git a/config/Makefile.macosx b/config/Makefile.macosx index 5f52d6fa5470a..543576d893da5 100644 --- a/config/Makefile.macosx +++ b/config/Makefile.macosx @@ -21,11 +21,6 @@ endif MACOSX_MINOR := $(shell sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2) MACOSX_CPU := $(shell uname -p) FINK_DIR := $(shell which fink 2>&1 | sed -ne "s/\/bin\/fink//p") -ifeq ($(MACOSX_DEPLOYMENT_TARGET),) -MACOSXVERS = 10.$(MACOSX_MINOR) -else -MACOSXVERS = $(MACOSX_DEPLOYMENT_TARGET) -endif # Compiler: # From "Apple clang version ... (based on LLVM 3.0svn)" @@ -38,8 +33,8 @@ endif ifeq ($(subst $(APPLE_CLANG),,12),12) CXX = clang++ CC = clang -ifeq (c++11,$(findstring c++11,$(ROOTBUILD))) -CXX11 = -std=c++11 +ifeq ($(CXX11),yes) +CXX11FLAGS = -std=c++11 endif else CXX = g++ @@ -47,14 +42,14 @@ CC = gcc endif CXXFLAGS = -m32 -pipe -Wshadow -W -Wall -Woverloaded-virtual \ -fsigned-char -fno-common $(EXTRA_CXXFLAGS) $(FINK_CXXFLAGS) \ - $(TARGETFLAGS) + $(TARGETFLAGS) $(CXX11FLAGS) CFLAGS = -m32 -pipe -Wshadow -W -Wall -fsigned-char -fno-common \ $(EXTRA_CFLAGS) $(FINK_CFLAGS) $(TARGETFLAGS) CINTCXXFLAGS = -m32 -pipe -W -Wall -Woverloaded-virtual \ -fsigned-char -fno-common $(EXTRA_CXXFLAGS) $(FINK_CXXFLAGS) \ -DG__REGEXP -DG__UNIX -DG__SHAREDLIB \ -DG__ROOT -DG__REDIRECTIO -DG__OSFDLL \ - -DG__STD_EXCEPTION $(TARGETFLAGS) + -DG__STD_EXCEPTION $(TARGETFLAGS) $(CXX11FLAGS) CINTCFLAGS = -m32 -pipe -W -Wall -fsigned-char -fno-common \ $(EXTRA_CFLAGS) $(FINK_CFLAGS) \ -DG__REGEXP -DG__UNIX -DG__SHAREDLIB \ @@ -153,6 +148,14 @@ MACOSX_SSL_DEPRECATED = yes endif ifeq ($(MACOSX_MINOR),8) MACOSX_SSL_DEPRECATED = yes +MACOSX_ODBC_DEPRECATED = yes +endif +ifeq ($(MACOSX_MINOR),9) +MACOSX_SSL_DEPRECATED = yes +MACOSX_ODBC_DEPRECATED = yes +MACOSX_GLU_DEPRECATED = yes +MACOSX_KRB5_DEPRECATED = yes +MACOSX_TMPNAM_DEPRECATED = yes endif ifeq ($(CONFIGURE),yes) diff --git a/config/Makefile.macosx64 b/config/Makefile.macosx64 index 5e0762e011828..e6934095001c1 100644 --- a/config/Makefile.macosx64 +++ b/config/Makefile.macosx64 @@ -21,11 +21,6 @@ endif MACOSX_MINOR := $(shell sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2) MACOSX_CPU := $(shell uname -p) FINK_DIR := $(shell which fink 2>&1 | sed -ne "s/\/bin\/fink//p") -ifeq ($(MACOSX_DEPLOYMENT_TARGET),) -MACOSXVERS = 10.$(MACOSX_MINOR) -else -MACOSXVERS = $(MACOSX_DEPLOYMENT_TARGET) -endif # Compiler: # From "Apple clang version ... (based on LLVM 3.0svn)" @@ -38,8 +33,12 @@ endif ifeq ($(subst $(APPLE_CLANG),,12),12) CXX = clang++ CC = clang -ifeq (c++11,$(findstring c++11,$(ROOTBUILD))) -CXX11 = -std=c++11 +ifeq ($(CXX11),yes) +CXX11FLAGS = -std=c++11 +endif +ifeq ($(LIBCXX),yes) +CXX11FLAGS += -stdlib=libc++ +CXX11LDFLAGS = -stdlib=libc++ endif else CXX = g++ @@ -47,14 +46,14 @@ CC = gcc endif CXXFLAGS = -m64 -pipe -Wshadow -W -Wall -Woverloaded-virtual \ -fsigned-char -fno-common $(EXTRA_CXXFLAGS) $(FINK_CXXFLAGS) \ - $(TARGETFLAGS) $(CXX11) + $(TARGETFLAGS) $(CXX11FLAGS) CFLAGS = -m64 -pipe -Wshadow -W -Wall -fsigned-char -fno-common \ $(EXTRA_CFLAGS) $(FINK_CFLAGS) $(TARGETFLAGS) CINTCXXFLAGS = -m64 -pipe -W -Wall -Woverloaded-virtual \ -fsigned-char -fno-common $(EXTRA_CXXFLAGS) $(FINK_CXXFLAGS) \ -DG__REGEXP -DG__UNIX -DG__SHAREDLIB \ -DG__ROOT -DG__REDIRECTIO -DG__OSFDLL \ - -DG__STD_EXCEPTION $(TARGETFLAGS) $(CXX11) + -DG__STD_EXCEPTION $(TARGETFLAGS) $(CXX11FLAGS) CINTCFLAGS = -m64 -pipe -W -Wall -fsigned-char -fno-common \ $(EXTRA_CFLAGS) $(FINK_CFLAGS) \ -DG__REGEXP -DG__UNIX -DG__SHAREDLIB \ @@ -69,6 +68,8 @@ else LD = g++ endif LDFLAGS = $(OPT) -m64 -mmacosx-version-min=$(MACOSXVERS) +F77LDFLAGS := $(LDFLAGS) +LDFLAGS += $(CXX11LDFLAGS) FORCELINK = yes NEEDFINK = yes @@ -138,6 +139,14 @@ MACOSX_SSL_DEPRECATED = yes endif ifeq ($(MACOSX_MINOR),8) MACOSX_SSL_DEPRECATED = yes +MACOSX_ODBC_DEPRECATED = yes +endif +ifeq ($(MACOSX_MINOR),9) +MACOSX_SSL_DEPRECATED = yes +MACOSX_ODBC_DEPRECATED = yes +MACOSX_GLU_DEPRECATED = yes +MACOSX_KRB5_DEPRECATED = yes +MACOSX_TMPNAM_DEPRECATED = yes endif ifeq ($(CONFIGURE),yes) diff --git a/config/Makefile.macosxicc b/config/Makefile.macosxicc index d5a5c113274dd..1c16e3f086019 100644 --- a/config/Makefile.macosxicc +++ b/config/Makefile.macosxicc @@ -18,11 +18,6 @@ endif MACOSX_MINOR := $(shell sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2) MACOSX_CPU := $(shell uname -p) FINK_DIR := $(shell which fink 2>&1 | sed -ne "s/\/bin\/fink//p") -ifeq ($(MACOSX_DEPLOYMENT_TARGET),) -MACOSXVERS = 10.$(MACOSX_MINOR) -else -MACOSXVERS = $(MACOSX_DEPLOYMENT_TARGET) -endif # Compiler: CXX = icc @@ -50,21 +45,12 @@ ICC_MINOR := $(shell $(CXX) -v 2>&1 | awk '{ if (NR==1) print $$3 }' | \ cut -d'.' -f2) endif -ifeq ($(ICC_MAJOR),8) -ifneq ($(ICC_MINOR),0) -CXXFLAGS += -wd1572 -CFLAGS += -wd1572 -CINTCXXFLAGS += -wd1572 -CINTCFLAGS += -wd1572 -endif -endif - ifeq ($(ICC_MAJOR),9) CXXFLAGS += -wd1572 -wd873 -wd672 CFLAGS += -wd1572 CINTCXXFLAGS += -wd1572 -wd873 CINTCFLAGS += -wd1572 -ICC_GE_9 = 9 +ICC_GE_9 = $(ICC_MAJOR) endif ifeq ($(ICC_MAJOR),10) @@ -72,28 +58,19 @@ CXXFLAGS += -wd1572 -wd873 -wd672 CFLAGS += -wd1572 CINTCXXFLAGS += -wd1572 -wd873 CINTCFLAGS += -wd1572 -ICC_GE_9 = 10 +ICC_GE_9 = $(ICC_MAJOR) ifneq ($(ICC_MINOR),0) -ICC_GE_101 = 101 +ICC_GE_101 = $(ICC_MAJOR)$(ICC_MINOR) endif endif -ifeq ($(ICC_MAJOR),11) +ifeq ($(findstring $(ICC_MAJOR),10 9),) CXXFLAGS += -wd1572 -wd873 -wd672 -wd279 CFLAGS += -wd1572 -wd279 CINTCXXFLAGS += -wd1572 -wd873 -wd279 CINTCFLAGS += -wd1572 -wd279 -ICC_GE_9 = 11 -ICC_GE_101 = 110 -endif - -ifeq ($(ICC_MAJOR),12) -CXXFLAGS += -wd1572 -wd873 -wd672 -wd279 -CFLAGS += -wd1572 -wd279 -CINTCXXFLAGS += -wd1572 -wd873 -wd279 -CINTCFLAGS += -wd1572 -wd279 -ICC_GE_9 = 12 -ICC_GE_101 = 120 +ICC_GE_9 = $(ICC_MAJOR) +ICC_GE_101 = $(ICC_MAJOR)$(ICC_MINOR) endif # Linker: @@ -117,7 +94,7 @@ SOFLAGS = -dynamiclib -single_module \ endif endif ifeq ($(subst $(MACOSX_MINOR),,1234),1234) -ifeq ($(ICC_MAJOR),11) +ifeq ($(findstring $(ICC_MAJOR),10 9),) SOEXT = so # not yet supported by icc 10.x xilibtool else @@ -134,10 +111,10 @@ XLIBS = $(XPMLIBDIR) $(XPMLIB) $(X11LIBDIR) -lXext -lX11 CILIBS = -lm $(EXTRA_LDFLAGS) -ldl # Fortran: -ifeq ($(F77),ifort) -F77 = ifort +F77ORG = ifort F77FLAGS = -fPIC -ifeq ($(ICC_MAJOR),12) +ifneq ($(F77),) +ifeq ($(findstring $(ICC_MAJOR),11 10 9),) ifneq ($(subst ia32,,$(shell which ifort)),$(shell which ifort)) F77LIBS := -L$(shell which ifort | sed -e 's|bin/ia32/ifort|compiler/lib|') \ -lifcore @@ -171,4 +148,26 @@ MACOSX_SSL_DEPRECATED = yes endif ifeq ($(MACOSX_MINOR),8) MACOSX_SSL_DEPRECATED = yes +MACOSX_ODBC_DEPRECATED = yes +endif +ifeq ($(MACOSX_MINOR),9) +MACOSX_SSL_DEPRECATED = yes +MACOSX_ODBC_DEPRECATED = yes +MACOSX_GLU_DEPRECATED = yes +MACOSX_KRB5_DEPRECATED = yes +MACOSX_TMPNAM_DEPRECATED = yes +endif + +ifeq ($(CONFIGURE),yes) +showcxx: + @echo "$(CXX)" + +showcc: + @echo "$(CC)" + +showld: + @echo "$(LD)" + +showf77: + @echo "$(F77ORG)" endif diff --git a/config/Makefile.win32 b/config/Makefile.win32 index 43a832c56a80a..2f6dd2f48aea0 100644 --- a/config/Makefile.win32 +++ b/config/Makefile.win32 @@ -35,7 +35,7 @@ else BLDF77FLAGS = -MD endif -ifneq (,$(findstring $(VC_MAJOR),14 15 16)) +ifneq (,$(findstring $(VC_MAJOR),14 15 16 17 18)) BLDCXXFLAGS+= -EHsc- -W3 -wd4244 BLDCFLAGS += -EHsc- -W3 DEBUGFLAGS = -Z7 diff --git a/config/Makefile.win32gcc b/config/Makefile.win32gcc index 02d4949c21114..eb3b215cdb8a8 100644 --- a/config/Makefile.win32gcc +++ b/config/Makefile.win32gcc @@ -31,7 +31,7 @@ CINTCFLAGS = -pipe -Wall $(EXTRA_CFLAGS) \ COMPILER = gnu # Linker: -LD = build/unix/wingcc_ld.sh +LD = $(ROOT_SRCDIR)/build/unix/wingcc_ld.sh LDFLAGS = $(OPT) -Wl,--enable-auto-import \ -Wl,--enable-runtime-pseudo-reloc \ -L/usr/X11R6/lib \ diff --git a/config/RConfigure.in b/config/RConfigure.in index 1a46b8422d633..f99a3ff973296 100644 --- a/config/RConfigure.in +++ b/config/RConfigure.in @@ -24,5 +24,7 @@ #@hasxft@ R__HAS_XFT /**/ #@hascling@ R__HAS_CLING /**/ #@hascocoa@ R__HAS_COCOA /**/ +#@usec++11@ R__USE_CXX11 /**/ +#@uselibc++@ R__USE_LIBCXX /**/ #endif diff --git a/config/genreflex.in b/config/genreflex.in index ca771beecac36..f64b0b5706db9 100644 --- a/config/genreflex.in +++ b/config/genreflex.in @@ -1,3 +1,6 @@ -#!/bin/sh -dir=@libdir@ -python ${dir}/python/genreflex/genreflex.py "$@" +#!/bin/bash +if [ "x${ROOTSYS}" = "x" ]; then + THIS=$(dirname $0) + ROOTSYS=$(cd ${THIS}/..;pwd); export ROOTSYS +fi +python ${ROOTSYS}/lib/python/genreflex/genreflex.py "$@" diff --git a/config/html.C.in b/config/html.C.in index a5706e1e226ce..75f53e65db39c 100644 --- a/config/html.C.in +++ b/config/html.C.in @@ -22,6 +22,7 @@ Bool_t enable_rfio = @enable_rfio@; Bool_t enable_sapdb = @enable_sapdb@; Bool_t enable_srp = @enable_srp@; Bool_t enable_ssl = @enable_ssl@; +Bool_t enable_sqlite = @enable_sqlite@; Bool_t enable_table = @enable_table@; Bool_t enable_thread = kTRUE; Bool_t enable_xml = @enable_xml@; @@ -94,6 +95,7 @@ void html() if (enable_ruby) gSystem->Load("libRuby"); if (enable_rfio) gSystem->Load("libRFIO"); if (enable_sapdb) gSystem->Load("libSapDB"); + if (enable_sqlite) gSystem->Load("libSQLite"); if (enable_srp) gSystem->Load("libSRPAuth"); if (enable_table) gSystem->Load("libTable"); if (enable_thread) gSystem->Load("libThread"); diff --git a/config/root-config.in b/config/root-config.in index 56183051879af..ec16877557ffd 100755 --- a/config/root-config.in +++ b/config/root-config.in @@ -313,6 +313,11 @@ linuxx8664icc) auxcflags= auxlibs="-limf -lm -ldl" ;; +linuxx8664k1omicc) + # Intel Many Integrated Cores Architecture (Knights Corner) Linux with Intel icc + auxcflags="-mmic -I/usr/include" + auxlibs="-limf -lm -ldl" + ;; linuxalphagcc) # Alpha Linux with gcc auxcflags= @@ -427,7 +432,7 @@ win32gcc) ;; *) echo "root-config: \"$arch\" invalid architecture" - echo "Please report to rootdev@root.cern.ch" + echo "Please report to rootdev@cern.ch" exit 1 ;; esac @@ -445,10 +450,14 @@ freebsd* | openbsd* | linux*) if test "x$f" = "xrpath" ; then auxlibs="-Wl,-rpath,$libdir $auxlibs" fi + if test "x$f" = "xcxx11" ; then + auxcflags="-std=c++11 -Wno-deprecated-declarations $auxcflags" + fi + if test "x$f" = "xlibcxx" ; then + auxcflags="-stdlib=libc++ $auxcflags" + auxlibs="-stdlib=libc++ $auxlibs" + fi done - if echo $configargs | grep 'c++11' > /dev/null 2>& 1 ; then - auxcflags="-std=c++11 $auxcflags" - fi ;; macosx*) for f in $features ; do @@ -466,10 +475,14 @@ macosx*) auxlibs="-Wl,-rpath,$libdir $auxlibs" fi fi + if test "x$f" = "xcxx11" ; then + auxcflags="-std=c++11 $auxcflags" + fi + if test "x$f" = "xlibcxx" ; then + auxcflags="-stdlib=libc++ $auxcflags" + auxlibs="-stdlib=libc++ $auxlibs" + fi done - if echo $configargs | grep 'c++11' > /dev/null 2>& 1 ; then - auxcflags="-std=c++11 $auxcflags" - fi ;; hpuxacc | hpuxia64acc) for f in $features ; do diff --git a/config/root-help.el.in b/config/root-help.el.in index 5d5bd2bcf53af..eab32dee12078 100644 --- a/config/root-help.el.in +++ b/config/root-help.el.in @@ -391,7 +391,7 @@ Uses \\[root-header-skel] and \\[root-source-skel]" (if (file-exists-p source-name) (error "Source file '%s' already exists - will not overwrite" source-name)) - ;; Check files are writeable + ;; Check files are writable (if (not (file-writable-p header-name)) (error "Cannot write header file '%s'" header-name)) (if (not (file-writable-p source-name)) @@ -608,7 +608,7 @@ int main(int argc, char** argv) ;;____________________________________________________________________ (defun root-insert-linkdef () - "Insert lines appropiate for a linkdef file into current buffer + "Insert lines appropriate for a linkdef file into current buffer The user will be prompted for classes to add to the linkdef file. An empty string ends the input." diff --git a/config/rootrc.in b/config/rootrc.in index 70a39e419f50e..1533383e3f314 100644 --- a/config/rootrc.in +++ b/config/rootrc.in @@ -54,7 +54,7 @@ Root.TMemStat: 0 Root.TMemStat.buffersize: 100000 Root.TMemStat.maxcalls: 5000000 #Root.TMemStat.system: gnubuiltin -Root.TMemStat.system: +Root.TMemStat.system: # Activate memory statistics (size and cnt is used to trap allocation of # blocks of a certain size after cnt times). @@ -152,26 +152,27 @@ Hist.Binning.3D.Profx: 100 Hist.Binning.3D.Profy: 100 # Default statistics parameters names. -Hist.Stats.Entries: Entries -Hist.Stats.Mean: Mean -Hist.Stats.MeanX: Mean x -Hist.Stats.MeanY: Mean y -Hist.Stats.MeanZ: Mean z -Hist.Stats.RMS: RMS -Hist.Stats.RMSX: RMS x -Hist.Stats.RMSY: RMS y -Hist.Stats.RMSZ: RMS z -Hist.Stats.Underflow: Underflow -Hist.Stats.Overflow: Overflow -Hist.Stats.Integral: Integral -Hist.Stats.Skewness: Skewness -Hist.Stats.SkewnessX: Skewness x -Hist.Stats.SkewnessY: Skewness y -Hist.Stats.SkewnessZ: Skewness z -Hist.Stats.Kurtosis: Kurtosis -Hist.Stats.KurtosisX: Kurtosis x -Hist.Stats.KurtosisY: Kurtosis y -Hist.Stats.KurtosisZ: Kurtosis z +Hist.Stats.Entries: Entries +Hist.Stats.Mean: Mean +Hist.Stats.MeanX: Mean x +Hist.Stats.MeanY: Mean y +Hist.Stats.MeanZ: Mean z +Hist.Stats.RMS: RMS +Hist.Stats.RMSX: RMS x +Hist.Stats.RMSY: RMS y +Hist.Stats.RMSZ: RMS z +Hist.Stats.Underflow: Underflow +Hist.Stats.Overflow: Overflow +Hist.Stats.Integral: Integral +Hist.Stats.IntegralBinWidth: Integral(w) +Hist.Stats.Skewness: Skewness +Hist.Stats.SkewnessX: Skewness x +Hist.Stats.SkewnessY: Skewness y +Hist.Stats.SkewnessZ: Skewness z +Hist.Stats.Kurtosis: Kurtosis +Hist.Stats.KurtosisX: Kurtosis x +Hist.Stats.KurtosisY: Kurtosis y +Hist.Stats.KurtosisZ: Kurtosis z # THtml specific settings (for more see doc of THtml class). Root.Html.SourceDir: . @@ -228,6 +229,46 @@ Browser.AutoThumbnail: yes # Start URL for the TRootBrowser embedded HTML renderer Browser.StartUrl: http://root.cern.ch/root/html/ClassIndex.html +# OpenGL options (defaults are shown) +# Default user interaction model for 3D view manipulation assumes that user +# controls the scene (rotates or moves it). Change this to 'yes' to switch +# to viewer-centric model where controls "move" the viewer (or camera). +OpenGL.EventHandler.ViewerCentricControls: no +# Following three settings are factors scaling the effect of corresponding +# user inputs. Set to negative value to invert sense of action. +OpenGL.EventHandler.ArrowKeyFactor: 1.0 +OpenGL.EventHandler.MouseDragFactor: 1.0 +OpenGL.EventHandler.MouseWheelFactor: 1.0 +# Area around mouse cursor used to detect underlying objects for selection +# and hihglight. +OpenGL.PickingRadius: 3.0 +# Additional scaling factor for point-sizes and line-widths. The default value +# "native" sets this to 2.0 when running on mac in retina mode and 1.0 +# otherwise. Any floating-point number can be set but values above 4.0 do not +# make much sense. +OpenGL.PointLineScalingFactor: "native" +# Default scaling of lines used for drawing of polygons in wireframe mode ('w'). +# This can be set for every viewer in GLViewer GUI editor. +OpenGL.WireframeLineScalingFactor: 1.0 +# Default scaling of lines used for polygon outline in outline mode ('t'). +# This can be set for every viewer in GLViewer GUI editor. +OpenGL.OutlineLineScalingFactor: 1.0 +# Save pictures using framebuffer objects which works even when GL window is +# not on screen or is covered by other windows. Image scaling is supported +# but there is no GUI support -- call corresponding TGLViewer functions. +# FBOs might not work on some machines or over ssh due to buggy GL support. +OpenGL.SavePicturesViaFBO: yes +# If saving via FBO fails, fallback to using back-buffer for image capture. +OpenGL.SavePictureFallbackToBB: yes +# Enable multi-sampling (full-scene antialisaing), if supported. +# Set to 1 to use lowest available settings or a higher integer to request +# a specific number of samples per pixel (4 (linux) or 8 (mac) is reasonable). +OpenGL.Framebuffer.Multisample: 0 + +# EVE options (defaults are shown) +# Autmoatically hide/roll up GL viewer menu-bars. +Eve.Viewer.HideMenus: 1 + # Rint (interactive ROOT executable) specific alias, logon and logoff macros. Rint.Load: rootalias.C Rint.Logon: rootlogon.C @@ -464,10 +505,18 @@ RSA.KeyType: 1 # supported by the underlying TFile implementation. Default is yes. #TFile.AsyncReading: no -# Control the usage of asynchronous prefetching capabilities irrespective +# Control the usage of asynchronous prefetching capabilities irrespective # of the TFile implementation. By default it is disabled. #TFile.AsyncPrefetching: no +# List of S3 servers known to support multi-range HTTP GET requests. +# This is the value sent back by the S3 server in the 'Server:' header +# of the HTTP response. +# Please note that Amazon S3 servers do not support this feature. +# Add one line per server type with syntax: +# +TS3WebFile.Root.MultiRangeServer: Mucura +TS3WebFile.Root.MultiRangeServer: Huawei OBS + # Special cases for the TUrl parser, where the special cases are parsed # in a protocol + file part, like rfio:host:/path/file.root, # castor:/path/file.root or /alien/path/file.root. @@ -583,7 +632,88 @@ XNet.ParStreamsPerPhyConn: 0 # wait request can be before the client declares an error. # XNet.TransactionTimeout: 28800 +# The following env vars are handled by TNetXNGFile (new xrootd client interface) +# and related classes (module netxng, libNetxNG.so). + +# Use the old xrootd client (libNetx) instead of the new (libNetxNG) + +XNet.UseOldClient: @useoldnetx@ + +# NetXNG.ConnectionWindow - A time window for the connection establishment. A +# connection failure is declared if the connection +# is not established within the time window. If a +# connection failure happens earlier then another +# connection attempt will only be made at the +# beginning of the next window. +# NetXNG.ConnectionRetry - Number of connection attempts that should be +# made (number of available connection windows) +# before declaring a permanent failure. +# NetXNG.RequestTimeout - Default value for the time after which an error +# is declared if it was impossible to get a +# response to a request. +# NetXNG.SubStreamsPerChannel - Number of streams per session. +# NetXNG.TimeoutResolution - Resolution for the timeout events. Ie. timeout +# events will be processed only every +# XRD_TIMEOUTRESOLUTION seconds. +# NetXNG.StreamErrorWindow - Time after which the permanent failure flags are +# cleared out and a new connection may be +# attempted if needed. +# NetXNG.RunForkHandler - Determines whether the fork handlers should be +# enabled, making the API fork safe. +# NetXNG.RedirectLimit - Maximum number of allowed redirections. +# NetXNG.WorkerThreads - Number of threads processing user callbacks. +# NetXNG.CPChunkSize - Size of a single data chunk handled by xrdcopy. +# NetXNG.CPParallelChunks - Maximum number of asynchronous requests being +# processed by the xrdcopy command at any given +# time. +# NetXNG.PollerPreference - A comma separated list of poller implementations +# in order of preference. The default is: +# libevent,built-in. +# NetXNG.ClientMonitor - Path to the client monitor library. +# NetXNG.ClientMonitorParam - Additional optional parameters that will be +# passed to the monitoring object on initialization. + # Example of custom setting for the Rint application (root.exe). # This overrides the default specified above for a generic application. # Color 5 is yellow. Rint.Canvas.HighLightColor: 5 + + +# Parameters that influence the behavior of TDavixFile/TDavixSystem. These +# classes give a comprehensive client side support for HTTP and WebDAV, +# with all the goodies (session caching, flexible authentication, support +# for different dialects like S3, and others) + +# Verbosity level of the external Davix library +# Davix.Debug: 0 + +# Path to the X.509 user proxy +# Davix.GSI.UserProxy: /my/path/my_proxy + +# Paths to the X.509 user certificate and key, in PEM format +# Davix.GSI.UserCert: /my/path/my_cert +# Davix.GSI.UserKey: /my/path/my_key + +# Path to the directory containing the CAs +# Davix.GSI.CAdir: /etc/grid-security/certificates + +# Enable/disable the Check on the peer's certificate +# Davix.GSI.CACheck: y + +# Sets the HTTP client in Grid mode, to talk to Grid HTTP SEs +# without having to set additional parameters +# Grid mode enable the following action: +# - Auto-detect and use the available voms proxy certificate +# - Add the standard grid security CAs as valid CAs +# - Use the grid specific extensions if needed. +# Davix.GSI.GridMode: y + +# Sets the Amazon S3 authentication parameters +# Davix.S3.SecretKey: secret +# Davix.S3.AccessKey: token + +# NOTE: The authentication of TDavixFile/TDavixSystem can be influenced +# through some well known environment variables: +# X509_USER_CERT, X509_USER_KEY, X509_USER_PROXY +# They have the usual meaning for the X509 Grid things. The gEnv vars +# have higher priority over the these envvars. diff --git a/config/roots.in b/config/roots.in index 03635fb0a047b..6ae9faec6102b 100644 --- a/config/roots.in +++ b/config/roots.in @@ -7,7 +7,7 @@ # Template for the 'roots.sh' script. # In case of problems with 'ssh' not executing the relevant rc init # script, an ad hoc version of this script can be put, for example, under -# $HOME/bin, defining explicitely $ROOTSYS, e.g. +# $HOME/bin, defining explicitly $ROOTSYS, e.g. # # ---------------------------------------------------------------------- # #!/bin/sh diff --git a/config/setxrd.sh b/config/setxrd.sh index 74e2b4b8566f6..e3ffeeb6b9c9e 100755 --- a/config/setxrd.sh +++ b/config/setxrd.sh @@ -25,34 +25,34 @@ drop_from_path() xrdset="xrdset" xrdsys=$1 -binpath="" -libpath="" +xrdbinpath="" +xrdlibpath="" manpath="" if test "x$xrdsys" = "x"; then echo "$xrdset: ERROR, you must specify the path to the xrootd installed" return 1; fi -binpath="$xrdsys/bin" -if test ! -d "$binpath" ; then - echo "$xrdset: ERROR, directory $binpath does not exist or not a directory!" +xrdbinpath="$xrdsys/bin" +if test ! -d "$xrdbinpath" ; then + echo "$xrdset: ERROR, directory $xrdbinpath does not exist or not a directory!" return 1; fi -libpath="$xrdsys/lib" -if test ! -d "$libpath" ; then - libemsg="$libpath" - libpath="$xrdsys/lib64" - if test ! -d "$libpath" ; then - echo "$xrdset: ERROR, directory $libemsg nor $libpath do not exist or not directories!" +xrdlibpath="$xrdsys/lib" +if test ! -d "$xrdlibpath" ; then + libemsg="$xrdlibpath" + xrdlibpath="$xrdsys/lib64" + if test ! -d "$xrdlibpath" ; then + echo "$xrdset: ERROR, directory $libemsg nor $xrdlibpath do not exist or not directories!" return 1; fi fi -manpath="$xrdsys/man" -if test ! -d "$manpath" ; then - manemsg="$manpath" - manpath="$xrdsys/share/man" - if test ! -d "$manpath" ; then - echo "$xrdset: WARNING, directory $manemsg and $manpath do not exist or not directories; MANPATH unchanged" - manpath="" +xrdmanpath="$xrdsys/man" +if test ! -d "$xrdmanpath" ; then + manemsg="$xrdmanpath" + xrdmanpath="$xrdsys/share/man" + if test ! -d "$xrdmanpath" ; then + echo "$xrdset: WARNING, directory $manemsg and $xrdmanpath do not exist or not directories; MANPATH unchanged" + xrdmanpath="" fi fi @@ -60,25 +60,25 @@ fi if test ! "x$XRDSYS" = "x" ; then # Trim $PATH if [ -n "${PATH}" ]; then - drop_from_path $PATH $binpath + drop_from_path $PATH $xrdbinpath PATH=$newpath fi # Trim $LD_LIBRARY_PATH if [ -n "${LD_LIBRARY_PATH}" ]; then - drop_from_path $LD_LIBRARY_PATH $libpath + drop_from_path $LD_LIBRARY_PATH $xrdlibpath LD_LIBRARY_PATH=$newpath fi # Trim $DYLD_LIBRARY_PATH if [ -n "${DYLD_LIBRARY_PATH}" ]; then - drop_from_path $DYLD_LIBRARY_PATH $libpath + drop_from_path $DYLD_LIBRARY_PATH $xrdlibpath DYLD_LIBRARY_PATH=$newpath fi # Trim $MANPATH if [ -n "${MANPATH}" ]; then - drop_from_path $MANPATH $manpath + drop_from_path $MANPATH $xrdmanpath MANPATH=$newpath fi fi @@ -96,22 +96,22 @@ fi export XRDSYS="$xrdsys" if [ -z "${PATH}" ]; then - PATH=$binpath; export PATH + PATH=$xrdbinpath; export PATH else - PATH=$binpath:$PATH; export PATH + PATH=$xrdbinpath:$PATH; export PATH fi if [ -z "${LD_LIBRARY_PATH}" ]; then - LD_LIBRARY_PATH=$libpath; export LD_LIBRARY_PATH + LD_LIBRARY_PATH=$xrdlibpath; export LD_LIBRARY_PATH else - LD_LIBRARY_PATH=$libpath:$LD_LIBRARY_PATH; export LD_LIBRARY_PATH + LD_LIBRARY_PATH=$xrdlibpath:$LD_LIBRARY_PATH; export LD_LIBRARY_PATH fi if [ -z "${DYLD_LIBRARY_PATH}" ]; then - DYLD_LIBRARY_PATH=$libpath; export DYLD_LIBRARY_PATH + DYLD_LIBRARY_PATH=$xrdlibpath; export DYLD_LIBRARY_PATH else - DYLD_LIBRARY_PATH=$libpath:$DYLD_LIBRARY_PATH; export DYLD_LIBRARY_PATH + DYLD_LIBRARY_PATH=$xrdlibpath:$DYLD_LIBRARY_PATH; export DYLD_LIBRARY_PATH fi if [ -z "${MANPATH}" ]; then - MANPATH=$manpath:${default_manpath}; export MANPATH + MANPATH=$xrdmanpath:${default_manpath}; export MANPATH else - MANPATH=$manpath:$MANPATH; export MANPATH + MANPATH=$xrdmanpath:$MANPATH; export MANPATH fi diff --git a/config/thisroot.csh b/config/thisroot.csh index 89ddaa5c8dd43..094f1b6602b09 100644 --- a/config/thisroot.csh +++ b/config/thisroot.csh @@ -8,27 +8,27 @@ # Author: Fons Rademakers, 18/8/2006 if ($?ROOTSYS) then - setenv OLD_ROOTSYS "$ROOTSYS" + set old_rootsys="$ROOTSYS" endif # $_ should be source .../thisroot.csh set ARGS=($_) if ("$ARGS" != "") then - set THIS="`dirname ${ARGS[2]}`" + set thisroot="`dirname ${ARGS[2]}`" else # But $_ might not be set if the script is source non-interactively. # In [t]csh the sourced file is inserted 'in place' inside the # outer script, so we need an external source of information # either via the current directory or an extra parameter. if ( -e thisroot.csh ) then - set THIS=${PWD} + set thisroot=${PWD} else if ( -e bin/thisroot.csh ) then - set THIS=${PWD}/bin + set thisroot=${PWD}/bin else if ( "$1" != "" ) then if ( -e ${1}/bin/thisroot.csh ) then - set THIS=${1}/bin + set thisroot=${1}/bin else if ( -e ${1}/thisroot.csh ) then - set THIS=${1} + set thisroot=${1} else echo "thisroot.csh: ${1} does not contain a ROOT installation" endif @@ -42,56 +42,56 @@ else endif endif -if ($?THIS) then +if ($?thisroot) then -setenv ROOTSYS "`(cd ${THIS}/..;pwd)`" +setenv ROOTSYS "`(cd ${thisroot}/..;pwd)`" -if ($?OLD_ROOTSYS) then - setenv PATH `echo $PATH | sed -e "s;:$OLD_ROOTSYS/bin:;:;g" \ - -e "s;:$OLD_ROOTSYS/bin;;g" \ - -e "s;$OLD_ROOTSYS/bin:;;g" \ - -e "s;$OLD_ROOTSYS/bin;;g"` +if ($?old_rootsys) then + setenv PATH `echo $PATH | sed -e "s;:$old_rootsys/bin:;:;g" \ + -e "s;:$old_rootsys/bin;;g" \ + -e "s;$old_rootsys/bin:;;g" \ + -e "s;$old_rootsys/bin;;g"` if ($?LD_LIBRARY_PATH) then setenv LD_LIBRARY_PATH `echo $LD_LIBRARY_PATH | \ - sed -e "s;:$OLD_ROOTSYS/lib:;:;g" \ - -e "s;:$OLD_ROOTSYS/lib;;g" \ - -e "s;$OLD_ROOTSYS/lib:;;g" \ - -e "s;$OLD_ROOTSYS/lib;;g"` + sed -e "s;:$old_rootsys/lib:;:;g" \ + -e "s;:$old_rootsys/lib;;g" \ + -e "s;$old_rootsys/lib:;;g" \ + -e "s;$old_rootsys/lib;;g"` endif if ($?DYLD_LIBRARY_PATH) then setenv DYLD_LIBRARY_PATH `echo $DYLD_LIBRARY_PATH | \ - sed -e "s;:$OLD_ROOTSYS/lib:;:;g" \ - -e "s;:$OLD_ROOTSYS/lib;;g" \ - -e "s;$OLD_ROOTSYS/lib:;;g" \ - -e "s;$OLD_ROOTSYS/lib;;g"` + sed -e "s;:$old_rootsys/lib:;:;g" \ + -e "s;:$old_rootsys/lib;;g" \ + -e "s;$old_rootsys/lib:;;g" \ + -e "s;$old_rootsys/lib;;g"` endif if ($?SHLIB_PATH) then setenv SHLIB_PATH `echo $SHLIB_PATH | \ - sed -e "s;:$OLD_ROOTSYS/lib:;:;g" \ - -e "s;:$OLD_ROOTSYS/lib;;g" \ - -e "s;$OLD_ROOTSYS/lib:;;g" \ - -e "s;$OLD_ROOTSYS/lib;;g"` + sed -e "s;:$old_rootsys/lib:;:;g" \ + -e "s;:$old_rootsys/lib;;g" \ + -e "s;$old_rootsys/lib:;;g" \ + -e "s;$old_rootsys/lib;;g"` endif if ($?LIBPATH) then setenv LIBPATH `echo $LIBPATH | \ - sed -e "s;:$OLD_ROOTSYS/lib:;:;g" \ - -e "s;:$OLD_ROOTSYS/lib;;g" \ - -e "s;$OLD_ROOTSYS/lib:;;g" \ - -e "s;$OLD_ROOTSYS/lib;;g"` + sed -e "s;:$old_rootsys/lib:;:;g" \ + -e "s;:$old_rootsys/lib;;g" \ + -e "s;$old_rootsys/lib:;;g" \ + -e "s;$old_rootsys/lib;;g"` endif if ($?PYTHONPATH) then setenv PYTHONPATH `echo $PYTHONPATH | \ - sed -e "s;:$OLD_ROOTSYS/lib:;:;g" \ - -e "s;:$OLD_ROOTSYS/lib;;g" \ - -e "s;$OLD_ROOTSYS/lib:;;g" \ - -e "s;$OLD_ROOTSYS/lib;;g"` + sed -e "s;:$old_rootsys/lib:;:;g" \ + -e "s;:$old_rootsys/lib;;g" \ + -e "s;$old_rootsys/lib:;;g" \ + -e "s;$old_rootsys/lib;;g"` endif if ($?MANPATH) then setenv MANPATH `echo $MANPATH | \ - sed -e "s;:$OLD_ROOTSYS/man:;:;g" \ - -e "s;:$OLD_ROOTSYS/man;;g" \ - -e "s;$OLD_ROOTSYS/man:;;g" \ - -e "s;$OLD_ROOTSYS/man;;g"` + sed -e "s;:$old_rootsys/man:;:;g" \ + -e "s;:$old_rootsys/man;;g" \ + -e "s;$old_rootsys/man:;;g" \ + -e "s;$old_rootsys/man;;g"` endif endif @@ -145,4 +145,8 @@ else setenv MANPATH `dirname @mandir@`:$default_manpath endif -endif # if ("$THIS" != "") +endif # if ("$thisroot" != "") + +set thisroot= +set old_rootsys= + diff --git a/config/thisroot.sh b/config/thisroot.sh index 066584caf23cd..a858ce1acb87a 100644 --- a/config/thisroot.sh +++ b/config/thisroot.sh @@ -25,7 +25,7 @@ drop_from_path() } if [ -n "${ROOTSYS}" ] ; then - OLD_ROOTSYS=${ROOTSYS} + old_rootsys=${ROOTSYS} fi if [ "x${BASH_ARGV[0]}" = "x" ]; then @@ -37,37 +37,37 @@ if [ "x${BASH_ARGV[0]}" = "x" ]; then ROOTSYS="$PWD"; export ROOTSYS else # get param to "." - THIS=$(dirname ${BASH_ARGV[0]}) - ROOTSYS=$(cd ${THIS}/..;pwd); export ROOTSYS + thisroot=$(dirname ${BASH_ARGV[0]}) + ROOTSYS=$(cd ${thisroot}/..;pwd); export ROOTSYS fi -if [ -n "${OLD_ROOTSYS}" ] ; then +if [ -n "${old_rootsys}" ] ; then if [ -n "${PATH}" ]; then - drop_from_path $PATH ${OLD_ROOTSYS}/bin + drop_from_path "$PATH" ${old_rootsys}/bin PATH=$newpath fi if [ -n "${LD_LIBRARY_PATH}" ]; then - drop_from_path $LD_LIBRARY_PATH ${OLD_ROOTSYS}/lib + drop_from_path $LD_LIBRARY_PATH ${old_rootsys}/lib LD_LIBRARY_PATH=$newpath fi if [ -n "${DYLD_LIBRARY_PATH}" ]; then - drop_from_path $DYLD_LIBRARY_PATH ${OLD_ROOTSYS}/lib + drop_from_path $DYLD_LIBRARY_PATH ${old_rootsys}/lib DYLD_LIBRARY_PATH=$newpath fi if [ -n "${SHLIB_PATH}" ]; then - drop_from_path $SHLIB_PATH ${OLD_ROOTSYS}/lib + drop_from_path $SHLIB_PATH ${old_rootsys}/lib SHLIB_PATH=$newpath fi if [ -n "${LIBPATH}" ]; then - drop_from_path $LIBPATH ${OLD_ROOTSYS}/lib + drop_from_path $LIBPATH ${old_rootsys}/lib LIBPATH=$newpath fi if [ -n "${PYTHONPATH}" ]; then - drop_from_path $PYTHONPATH ${OLD_ROOTSYS}/lib + drop_from_path $PYTHONPATH ${old_rootsys}/lib PYTHONPATH=$newpath fi if [ -n "${MANPATH}" ]; then - drop_from_path $MANPATH ${OLD_ROOTSYS}/man + drop_from_path $MANPATH ${old_rootsys}/man MANPATH=$newpath fi fi @@ -126,3 +126,7 @@ fi if [ "x`root-config --arch | grep -v win32gcc | grep -i win32`" != "x" ]; then ROOTSYS="`cygpath -w $ROOTSYS`" fi + +unset old_rootsys +unset thisroot + diff --git a/configure b/configure index 40ac87d890eb1..15c095fb002f8 100755 --- a/configure +++ b/configure @@ -50,12 +50,14 @@ options=" \ enable_builtin_pcre \ enable_builtin_zlib \ enable_builtin_lzma \ + enable_cxx11 \ + enable_libcxx \ enable_castor \ enable_chirp \ enable_cintex \ - enable_clarens \ enable_cling \ enable_cocoa \ + enable_davix \ enable_dcache \ enable_explicitlink \ enable_fink \ @@ -79,7 +81,6 @@ options=" \ enable_odbc \ enable_opengl \ enable_oracle \ - enable_peac \ enable_pgsql \ enable_pythia6 \ enable_pythia8 \ @@ -95,6 +96,7 @@ options=" \ enable_shadowpw \ enable_shared \ enable_soversion \ + enable_sqlite \ enable_srp \ enable_ssl \ enable_table \ @@ -138,6 +140,8 @@ for c in $options $deprecated_options; do done for c in $options ; do eval ${c}_explicit="" ; done +enable_cxx11=no +enable_libcxx=no enable_cling=no enable_cocoa=no enable_afs=no @@ -191,6 +195,7 @@ OPENGL \ MYSQL \ ORACLE \ PGSQL \ +SQLITE \ QTDIR \ SAPDB \ RFIO \ @@ -223,6 +228,7 @@ MINUIT2 \ TABLE \ XMLDIR \ ROOTDICTTYPE \ +DAVIX \ " configenvvars= for c in $envvars ; do @@ -351,7 +357,7 @@ check_libpic() { #_____________________________________________________________________ check_libcompat() { - # This function will try to find out if a library [$1] contains + # This function will try to find out if a library [$1] contains # compatible 64 bit or 32 bit code matching the selected architecture. # Currently only MacOS X supports universal libs. # The result of the check is stored in is_libcompat, 1 if true, @@ -397,6 +403,78 @@ check_libcompat() { fi } +#_____________________________________________________________________ +check_libcxxcompat() { + # This function will try to find out if a library [$1] is linked + # against a compatible C++ run-time library (either libstdc++ or libc++). + # Currently only MacOS X and Linux support libc++ and libstdc++. + # The result of the check is stored in is_libcxxcompat, 1 if true, + # 0 otherwise, which should be immediately copied, since the variable + # will be overwritten at next invocation of this function. + # To avoid this check, in case std types are not used in the public + # API of the library, set skipchecklibcxxcompat="yes". + + is_libcxxcompat=1 + ret=0 + + # Assert that we got enough arguments + if test $# -ne 1 ; then + echo "check_libcxxcompat: not 1 argument" + return 1 + fi + + # Can we skip the check in case library has no std C++ in public API + if test "x$skipchecklibcxxcompat" = "xyes"; then + skipchecklibcxxcompat="" + logmsg "check_libcxxcompat: skipping check for $1" + return + fi + + # Save arguments in logical names + chklibcxxcompat=$1 + logmsg "Checking if $chklibcxxcompat is linked against compatible C++ run-time" + + if test "x$enable_libcxx" = "xyes"; then + case $arch in + macosx*) + logmsg " otool -L $chklibcxxcompat | grep libstdc++" + if otool -L $chklibcxxcompat | grep 'libstdc++' > /dev/null 2>& 1 ; then + ret=1 + fi + ;; + linux*) + logmsg " ldd $chklibcxxcompat | grep libstdc++" + if ldd $chklibcxxcompat | grep 'libstdc++' > /dev/null 2>& 1 ; then + ret=1 + fi + ;; + esac + else + case $arch in + macosx*) + logmsg " otool -L $chklibcxxcompat | grep libc++" + if otool -L $chklibcxxcompat | grep 'libc++' > /dev/null 2>& 1 ; then + ret=1 + fi + ;; + linux*) + logmsg " ldd $chklibcxxcompat | grep libc++" + if ldd $chklibcxxcompat | grep 'libc++' > /dev/null 2>& 1 ; then + ret=1 + fi + ;; + esac + fi + + logmsg " result: $ret" + if test $ret -eq 1 ; then + is_libcxxcompat=0 + logmsg " is linked against not-compatible C++ run-time library" + else + logmsg " is linked against compatible C++ run-time library" + fi +} + #_____________________________________________________________________ check_lib64() { # This function will try to find out if a library [$1] contains 64 bit @@ -592,6 +670,12 @@ check_library() { break 4 fi fi + if test "x$checklibcxxcompat" = "xyes" ; then + check_libcxxcompat $n + if test $is_libcxxcompat -eq 0 ; then + break 4 + fi + fi found_dir=$l found_lib=$j if test "x$arch" = "xlinux"; then @@ -649,14 +733,14 @@ check_library() { if (test "x$found_lib" = "x$flib" && test "x$shared" = "xno") || \ test "x$maclib" = "xyes" ; then - found_raw_lib=${found_lib} + found_raw_lib=${found_lib} found_lib=${found_dir}/${found_lib} found_raw_dir=${found_dir} found_dir="" else found_raw_lib=${found_lib} if test ! "x$shared" = "xstaticonly" ; then - found_lib=`echo $found_lib | sed 's|^lib\(.*\)\..*|-l\1|'` + found_lib=`echo $found_lib | sed 's|^lib\(.*\)\..*|-l\1|'` fi found_raw_dir=${found_dir} if test ! "x$shared" = "xstaticonly" ; then @@ -834,6 +918,9 @@ check_link() { fi cat < conftest.mk include ${ac_srcdir}/config/Makefile.${arch} +CC = ${altcc} +CXX = ${altcxx} +LD = ${altld} conftest: conftest.c \$(CC) \$(CFLAGS) \$(LDFLAGS) \$< -o \$@ $linkdir $linklib @@ -848,6 +935,9 @@ EOF fi cat < conftest.mk include ${ac_srcdir}/config/Makefile.${arch} +CC = ${altcc} +CXX = ${altcxx} +LD = ${altld} conftest:conftest.c \$(CC) \$(CFLAGS) \$(LDFLAGS) \$< -o \$@ $linkdir $linklib @@ -872,6 +962,51 @@ EOF unset linksymbol } +#_____________________________________________________________________ +check_cxxopt() { + # This function will try to compile with a specific cxx compiler + # option [$1]. The result of the check is stored in cxxopt_result, + # 1 if true, 0 otherwise, which should be immediately copied, + # since the variable will be overwritten at next invocation + # of this function. + + # Assert that we got enough arguments + if test $# -lt 1 ; then + echo "check_cxxopt: need at least one argument" + cxxopt_result=0 + return 1 + fi + + # save arguments in logical names + cxxopt="$1"; shift + + logmsg " trying to compile with option $cxxopt" + cat < conftest.mk +include ${ac_srcdir}/config/Makefile.${arch} +CC = ${altcc} +CXX = ${altcxx} +LD = ${altld} +conftest: conftest.cxx + \$(CXX) \$(CFLAGS) $cxxopt \$(LDFLAGS) \$< -o \$@ + +conftest.cxx: + echo "int main() { return 0; }" > \$@ +EOF + + $gnumake -f conftest.mk >> $logfile 2>&1 + if test $? -eq 0 ; then + cxxopt_result=1 + logmsg " Compilation OK" + else + cxxopt_result=0 + logmsg " Failed code was" + cat conftest.mk >> $logfile + fi + rm -rf conftest.cxx conftest.mk conftest conftest.dSYM + + unset cxxopt +} + #_____________________________________________________________________ check_symbol() { # This function will try to locate a symbol [$1] in a specific @@ -1201,7 +1336,7 @@ guess_architecture() { echo "Attempts at guessing your architecture failed." echo "(triplet is $arch:$chip:$rele)" echo "Please specify the architecture as the first argument." - echo "Do '$0 --help' for a list of avaliable architectures." + echo "Do '$0 --help' for a list of available architectures." echo "Or file a bug at https://savannah.cern.ch/projects/savroot/" echo "including the full config.log and a dump of" echo " touch dummy_file.c; gcc -E -dM dummy_file.c" @@ -1407,7 +1542,7 @@ FIRST argument one of the architecures given at the end of this message. FLAG DESCRIPTION DEFAULT --aclocaldir Autoconf macro install dir(/share/aclocal) --bindir Binary installation dir (/bin) - --build Build configuration [debug, c++11, ...], + --build Build configuration [debug, ...], overrides the ROOTBUILD shell variable --cintincdir CINT interpeted headers (/cint) --datadir Data installation dir (/share/root) @@ -1446,12 +1581,14 @@ enable/disable options, prefix with either --enable- or --disable- builtin-pcre Built included libpcre, or use system libpcre builtin-zlib Built included libz, or use system libz builtin-lzma Built included liblzma, or use system liblzma + cxx11 Build using C++11 compatible mode, requires gcc > 4.7.x or clang + libcxx Build using libc++, required by clang cxx11 option (MacOS X only, for the time being) castor CASTOR support, requires libshift from CASTOR >= 1.5.2 chirp Chirp filesystem support, requires cctools >= 3.2.2 cintex Build the libCintex Reflex interface library - clarens Clarens RPC support, optionally used by PROOF cling Use cling as interpreter backend (experimental!), needs --with-llvm-config cocoa Use native Cocoa/Quartz graphics backend (MacOS X only) + davix DavIx library for HTTP/WEBDAV access dcache dCache support, requires libdcap from DESY explicitlink Explicitly link with all dependent libraries fink Use libraries from an extra MacOS X package manager (Fink, MacPorts, ...) (default: enabled) @@ -1475,10 +1612,9 @@ enable/disable options, prefix with either --enable- or --disable- odbc ODBC support, requires libiodbc or libodbc opengl OpenGL support, requires libGL and libGLU oracle Oracle support, requires libocci - peac PEAC, PROOF Enabled Analysis Center, requires Clarens pgsql PostgreSQL support, requires libpq pythia6 Pythia6 EG support, requires libPythia6 - pythia8 Pythia8 EG support, requires libPythia8 + pythia8 Pythia8 EG support, requires libPythia8 >= 8180 python Python ROOT bindings, requires python >= 2.2 qt Qt graphics backend, requires libqt >= 4.x qtgsi GSI's Qt integration, requires libqt >= 3 @@ -1491,6 +1627,7 @@ enable/disable options, prefix with either --enable- or --disable- shadowpw Shadow password support shared Use shared 3rd party libraries if possible soversion Set version number in sonames (recommended) + sqlite SQLite support, requires libsqlite3 srp SRP support, requires SRP source tree ssl SSL encryption support, requires openssl table Build libTable contrib library @@ -1528,6 +1665,8 @@ with options, prefix with --with-, enables corresponding support chirp-incdir Chirp support, location of chirp_reli.h chirp-libdir Chirp support, location of libchirp_client cppunit Cppunit testing, directory of the cppunit installation + davix-incdir DavIx support, location of davix.hpp + davix-libdir DavIx support, location of libdavix dcap-incdir dCache support, location of dcap.h dcap-libdir dCache support, location of libdcap dicttype dictionary type: "cint" (default), "reflex", or "gccxml" @@ -1543,6 +1682,8 @@ with options, prefix with --with-, enables corresponding support gviz-incdir Graphviz support, location of gvc.h gviz-libdir Graphviz support, location of libgvplugin_core gfal-incdir GFAL support, location of gfal_api.h + srm-ifce-incdir GFAL support, location of gfal_srm_ifce_types.h + glib2-incdir GFAL support, location of glib-2.0 headers gfal-libdir GFAL support, location of libgfal glew-incdir GLEW support, location of glew.h glew-libdir GLEW support, location of libGLEW @@ -1554,6 +1695,7 @@ with options, prefix with --with-, enables corresponding support globus-libdir Globus support, location of globus libraries hdfs-incdir HDFS support, location of hdfs.h hdfs-libdir HDFS support, location of libhdfs + iosvers iOS SDK version (6.1, 7.0), default will be latest SDK jni-incdir HDFS support, location of JNI headers jvm-libdir HDFS support, location of JVM library krb5 Kerberos5 support, location of Kerberos distribution @@ -1562,6 +1704,7 @@ with options, prefix with --with-, enables corresponding support ldap-incdir LDAP support, location of ldap.h ldap-libdir LDAP support, location of libldap llvm-config LLVM/clang for cling, location of llvm-config script + macosxvers OS X SDK version (10.8, 10.9), default will be latest SDK monalisa-incdir Monalisa support, location of ApMon.h monalisa-libdir Monalisa support, location of libapmoncpp mysql-incdir MySQL support, location of mysql.h @@ -1587,6 +1730,8 @@ with options, prefix with --with-, enables corresponding support sapdb-libdir SapDB support, location of libsqlod rfio-incdir RFIO support, location of rfio_api.h rfio-libdir RFIO support, location of librfio, libdpm or libshift + sqlite-incdir SQLite support, location of sqlite3.h + sqlite-libdir SQLite support, location of libsqlite3 srp Secure Remote Passwd support, location of SRP distribution srp-incdir SRP support, location header of t_server.h srp-libdir SRP support, location header of libsrp.a @@ -1633,7 +1778,7 @@ for example $0 --help | more -Report bugs to +Report bugs to EOF } @@ -1694,6 +1839,15 @@ sgicc) linuxppc64*|sgicc64) logmsg "Will ONLY check 64bit libraries" checkonlylib64="yes" ;; +linuxx8664k1om*) + logmsg "Will not check 64bit libraries" + checklinux64="no" + checklib64="no" + enable_cintex="no" + enable_reflex="no" + enable_genvector="no" + enable_tmva="no" + ;; linuxx8664*) logmsg "Will check 64bit libraries" checklinux64="yes" @@ -1707,17 +1861,43 @@ solaris64CC5) checklib64="yes" ;; macosx*) logmsg "Will check for compatible libraries" - checklibcompat="yes" ;; + checklibcompat="yes" + logmsg "Will check for compatible C++ run-time libraries" + checklibcxxcompat="yes" + if test "x$macosxvers" = "x"; then + # get most recent SDK version + macosxminor=`sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2` + macosxvers=10.$macosxminor + fi + # make available to conftest.mk scripts + export MACOSXVERS=$macosxvers + ;; ios*) logmsg "Will check iOS SDK libraries" message "Checking for iOS SDK" - iossdk=`make -s -f ${ac_srcdir}/config/Makefile.$arch CONFIGURE=yes showsdk` + if test "x$iosvers" = "x"; then + # get most recent SDK version + iosvers=`xcodebuild -showsdks | sed -n '/iphoneos/s/.*iOS //p' | sed 's/ .*//'|awk 'END{print}'` + fi + if [ `echo $iosvers | cut -d . -f 1` -ge 7 ]; then + ios7=yes + fi + xcodepath=`/usr/bin/xcode-select -print-path` + if test "x$arch" = "xios"; then + iossdk=$xcodepath/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS$iosvers.sdk + else + iossdk=$xcodepath/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator$iosvers.sdk + fi result "$iossdk" if [ ! -d $iossdk ]; then result "`basename $0`: no iOS SDK found at $iossdk" result "Run "xcode-select" to update the developer directory path" + result "or make sure the desired SDK version is installed" exit 1 fi + # make available to conftest.mk scripts + export IOSSDK=$iossdk + export IOSVERS=$iosvers enable_cintex="no" enable_reflex="no" enable_genvector="no" @@ -1762,6 +1942,12 @@ if test "x$platform" = "xmacosx" ; then if [ `sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2` -ge 6 ]; then macosx106=yes fi + if [ `sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2` -ge 8 ]; then + macosx108=yes + fi + if [ `sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2` -ge 9 ]; then + macosx109=yes + fi fi if test "x$platform" = "xlinux" ; then @@ -1775,7 +1961,7 @@ if test "x$platform" = "xlinux" ; then fi if lsb_release -d | grep -i 'mint' > /dev/null 2>& 1; then linuxdist="multiarch" - fi + fi fi debmultiarch= @@ -1802,8 +1988,8 @@ trapcmd="rm -rf Makefile.tmp RConfigure.tmp RConfigure-out.tmp \ RConfigOptions.tmp RConfigOptions-out.tmp \ Makefile-comp.tmp root-config.tmp rootrc.tmp \ rootauthrc.tmp rootdaemonrc.tmp memprobe.tmp rootd.tmp \ - proofd.tmp rootd.xinetd.tmp proofd.xinetd.tmp conftest.mk \ - conftest.c conftest conftest.dSYM" + proofd.tmp rootd.xinetd.tmp proofd.xinetd.tmp proofserv.tmp \ + roots.tmp conftest.mk conftest.c conftest conftest.dSYM" trap "$trapcmd; exit 1" 1 2 3 15 trap "$trapcmd" 0 @@ -1854,6 +2040,8 @@ if test $# -gt 0 ; then --with-cint-maxtypedef=*) cintmaxtypedef=$optarg;; --with-cint-longline=*) cintlongline=$optarg ;; --with-cppunit=*) cppunit=$optarg ;; + --with-davix-incdir=*) davixincdir=$optarg ; enable_davix="yes" ;; + --with-davix-libdir=*) davixlibdir=$optarg ; enable_davix="yes" ;; --with-dcap-incdir=*) dcapincdir=$optarg ; enable_dcache="yes" ;; --with-dcap-libdir=*) dcaplibdir=$optarg ; enable_dcache="yes" ;; --with-dicttype=*) dicttype=$optarg ;; @@ -1872,6 +2060,8 @@ if test $# -gt 0 ; then --with-gviz-libdir=*) gvizlibdir=$optarg ; enable_gviz="yes" ;; --with-gfal-incdir=*) gfalincdir=$optarg ; enable_gfal="yes" ;; --with-gfal-libdir=*) gfallibdir=$optarg ; enable_gfal="yes" ;; + --with-srm-ifce-incdir=*) srmifceincdir=$optarg;; + --with-glib2-incdir=*) glib2incdir=$optarg;; --with-glew-incdir=*) glewincdir=$optarg ; enable_builtin_glew=no;; --with-glew-libdir=*) glewlibdir=$optarg ; enable_builtin_glew=no;; --with-gsl-incdir=*) gslincdir=$optarg ; enable_gsl="yes" ;; @@ -1882,6 +2072,7 @@ if test $# -gt 0 ; then --with-gccxml=*) gccxml=$optarg ;; --with-hdfs-incdir=*) hdfsincdir=$optarg ; enable_hdfs="yes" ;; --with-hdfs-libdir=*) hdfslibdir=$optarg ; enable_hdfs="yes" ;; + --with-iosvers=*) iosvers=$optarg ;; --with-jni-incdir=*) jniincdir=$optarg ;; --with-jvm-libdir=*) jvmlibdir=$optarg ;; --with-krb5=*) krb5dir=$optarg ; enable_krb5="yes" ;; @@ -1890,6 +2081,7 @@ if test $# -gt 0 ; then --with-ldap-incdir=*) ldapincdir=$optarg ; enable_ldap="yes" ;; --with-ldap-libdir=*) ldaplibdir=$optarg ; enable_ldap="yes" ;; --with-llvm-config=*) llvmconfig=$optarg ;; # require explicit --enable-cling + --with-macosxvers=*) macosxvers=$optarg ;; --with-mysql-incdir=*) mysqlincdir=$optarg ; enable_mysql="yes" ;; --with-mysql-libdir=*) mysqllibdir=$optarg ; enable_mysql="yes" ;; --with-monalisa-incdir=*)monalisaincdir=$optarg; enable_monalisa="yes";; @@ -1916,6 +2108,8 @@ if test $# -gt 0 ; then --with-sapdb-libdir=*) sapdblibdir=$optarg ; enable_sapdb="yes" ;; --with-rfio-incdir=*) shiftincdir=$optarg ; enable_rfio="yes" ;; --with-rfio-libdir=*) shiftlibdir=$optarg ; enable_rfio="yes" ;; + --with-sqlite-incdir=*) sqliteincdir=$optarg ; enable_sqlite="yes" ;; + --with-sqlite-libdir=*) sqlitelibdir=$optarg ; enable_sqlite="yes" ;; --with-srp=*) srpdir=$optarg ; enable_srp="yes" ;; --with-srp-incdir=*) srpincdir=$optarg ; enable_srp="yes" ;; --with-srp-libdir=*) srplibdir=$optarg ; enable_srp="yes" ;; @@ -1948,7 +2142,7 @@ if test $# -gt 0 ; then # features # --enable-*) - f=`echo $1 | sed -e 's/--//' -e 's/-/_/g'` + f=`echo $1 | sed -e 's/--//' -e 's/-/_/g' -e 's/++11/xx11/'` eval prev='$'`echo ${f}` eval prev_expl='$'`echo ${f}_explicit` if test "${prev}:${prev_expl}" = "yes:"; then @@ -1977,7 +2171,7 @@ if test $# -gt 0 ; then fi ;; --disable-*) - f=`echo $1 | sed -e 's/--disable/enable/' -e 's/-/_/g'` + f=`echo $1 | sed -e 's/--disable/enable/' -e 's/-/_/g' -e 's/++11/xx11/'` eval prev='$'`echo ${f}` eval prev_expl='$'`echo ${f}_explicit` if test "${prev}:${prev_expl}" = "xno:"; then @@ -2081,35 +2275,39 @@ fi # ### echo %%% Check for Fink or MacPorts on Mac OS X # -message "Checking for Fink/MacPorts directory" -if test "x$platform" = "xmacosx" -a "x$enable_fink" = "xyes"; then - if test -d "$finkdir"; then - # User specified a directory with --with-finkdir=... - logmsg "Using user-specified Fink directory" - logmsg "$finkdir" - else - # Fink has precedence over MacPorts - logmsg "Checking Fink directory" - finkdir=`$cwhich fink 2>&1 | sed -ne "s/\/bin\/fink//p"` - logmsg "$finkdir" - - if test "x$finkdir" = "x"; then - logmsg "Checking MacPorts directory" - finkdir=`$cwhich port 2>&1 | sed -ne "s/\/bin\/port//p"` +if test "x$platform" = "xmacosx"; then + message "Checking for Fink/MacPorts directory" + if test "x$enable_fink" = "xyes"; then + if test -d "$finkdir"; then + # User specified a directory with --with-finkdir=... + logmsg "Using user-specified Fink directory" + logmsg "$finkdir" + else + # Fink has precedence over MacPorts + logmsg "Checking Fink directory" + finkdir=`$cwhich fink 2>&1 | sed -ne "s/\/bin\/fink//p"` logmsg "$finkdir" + + if test "x$finkdir" = "x"; then + logmsg "Checking MacPorts directory" + finkdir=`$cwhich port 2>&1 | sed -ne "s/\/bin\/port//p"` + logmsg "$finkdir" + fi fi + result "$finkdir" + else + logmsg "Fink/MacPorts disabled" + result "disabled" fi - result "$finkdir" else - logmsg "Fink/MacPorts disabled" - result "disabled" + enable_fink="no" fi ###################################################################### # -### echo %%% On iOS always disable X11 +### echo %%% On iOS and Intel MIC always disable X11 # -if test "x$platform" = "xios"; then +if test "x$platform" = "xios" || test "x$platform" = "xlinux-k1om"; then enable_x11="no" if test "x$host" = "x"; then savearch=$arch @@ -2118,7 +2316,7 @@ if test "x$platform" = "xios"; then arch=$savearch fi else - # cross compiling only supported for ios for the time being + # cross compiling only supported for ios and Intel MIC for the time being host= fi @@ -2251,6 +2449,59 @@ if test ! "x$host" = "x"; then arch=$archbak fi +###################################################################### +# +### echo %%% C++11 - compile using c++11 compatible option +# +# needs gcc > 4.7.x or clang +usecxx11="undef" +if test "x$enable_cxx11" = "xyes"; then + message "Checking whether c++11 mode is supported" + check_cxxopt -std=c++11 + if test $cxxopt_result -eq 0 ; then + enable_cxx11="no" + result "no" + result "`basename $0`: c++11 mode is requested but the current compiler does not support it." + exit 1 + else + usecxx11="define" + # on OS X libcxx is required for C++11 support with clang + # so turn the option on when using clang + if test "x$platform" = "xmacosx" && echo $altcxx | grep 'clang++' > /dev/null 2>&1; then + enable_libcxx="yes" + fi + result "yes" + fi +fi + +###################################################################### +# +### echo %%% libc++ - compile and link using libc++ +# +# needs gcc > 4.7.x or clang + +# OSX 10.9 only has libc++ with clang so make sure this option is turned on +if test "x$macosx109" = "xyes" && echo $altcxx | grep 'clang++' > /dev/null 2>&1; then + enable_libcxx="yes" +fi +# iOS 7.0 only has libc++ with clang so make sure this option is turned on +if test "x$ios7" = "xyes" && echo $altcxx | grep 'clang++' > /dev/null 2>&1; then + enable_libcxx="yes" +fi + +uselibcxx="undef" +if test "x$enable_libcxx" = "xyes" ; then + message "Checking whether libc++ is supported" + check_cxxopt -stdlib=libc++ + if test $cxxopt_result -eq 0 ; then + enable_libcxx="no" + result "no" + else + uselibcxx="define" + result "yes" + fi +fi + ###################################################################### # ### echo %%% Check if native MacOS X Cocoa/Quartz backend should be build @@ -2265,6 +2516,19 @@ if test "x$enable_cocoa" = "xyes"; then hascocoa="define" enable_x11="no" result "yes" + message "Checking for OSX SDK" + xcodepath=`/usr/bin/xcode-select -print-path` + osxsdk=$xcodepath/Platforms/MacOSX.platform/Developer/SDKs/MacOSX$macosxvers.sdk + result "$osxsdk" + if [ ! -d $osxsdk ]; then + result "`basename $0`: no OSX SDK found at $osxsdk" + result "Run "xcode-select" to update the developer directory path" + result "or make sure the desired SDK version is installed" + exit 1 + else + openglincdir=${osxsdk}/System/Library/Frameworks/OpenGL.framework/Headers + opengllibdir=${osxsdk}/System/Library/Frameworks/OpenGL.framework/Libraries + fi fi ###################################################################### @@ -2390,6 +2654,11 @@ if test ! "x$enable_x11" = "xno" ; then result "For consistency they should be in the same directory" exit 1 fi +else + x11libdir="" + xpmlibdir="" + xftlibdir="" + xextlibdir="" fi ###################################################################### @@ -2504,20 +2773,29 @@ if test "x$enable_builtin_freetype" = "x" || \ checking_msg "freetype-config" if `$cwhich freetype-config > /dev/null 2>&1` && test "x$host" = "x" ; then - $cwhich freetype-config - - message "Checking for libfreetype version >= 9.3.0" - ttf2_version=`freetype-config --version | \ - tr '.' ' ' | \ - awk 'BEGIN { FS = " "; } \ - { printf "%d", ($''1 * 1000 + $''2) * 1000 + $''3;}'` - # First good version is 9.3.0 - if test $ttf2_version -lt 9003000 ; then - result "no (`freetype-config --version`)" + if test "x$macosx108" = "xyes" && (file -h `$cwhich freetype-config` | grep 'xstub' > /dev/null 2>&1 || test "x$enable_cocoa" = "xyes"); then enable_builtin_freetype="yes" + if file -h `$cwhich freetype-config` | grep 'xstub' > /dev/null 2>&1 ; then + result "XQuartz not installed" + else + result "using builtin freetype" + fi else - result "ok" - enable_builtin_freetype="no" + $cwhich freetype-config + + message "Checking for libfreetype version >= 9.3.0" + ttf2_version=`freetype-config --version | \ + tr '.' ' ' | \ + awk 'BEGIN { FS = " "; } \ + { printf "%d", ($''1 * 1000 + $''2) * 1000 + $''3;}'` + # First good version is 9.3.0 + if test $ttf2_version -lt 9003000 ; then + result "no (`freetype-config --version`)" + enable_builtin_freetype="yes" + else + result "ok" + enable_builtin_freetype="no" + fi fi else enable_builtin_freetype="yes" @@ -2657,7 +2935,7 @@ if test ! "x$enable_opengl" = "xno" && test ! "x$platform" = "xwin32" ; then /usr/include/Mesa /usr/local/include/Mesa /usr/Mesa/include \ /usr/local/Mesa/include /usr/Mesa /usr/local/Mesa /opt/Mesa \ /opt/Mesa/include /opt/graphics/OpenGL/include" - check_header "GL/gl.h" "$openglincdir" $openglincdirs + check_header "GL/gl.h gl.h" "$openglincdir" $openglincdirs openglinc=$found_hdr openglincdir=$found_dir @@ -2680,6 +2958,7 @@ if test ! "x$enable_opengl" = "xno" && test ! "x$platform" = "xwin32" ; then opengllib="-dylib_file /usr/X11R6/lib/libGL.dylib:/usr/X11R6/lib/libGL.dylib -lGL" fi + skipchecklibcxxcompat="yes" check_library "libGLU libMesaGLU" "$enable_shared" \ "$keep" $opengllibdirs openglulib=$found_lib @@ -2874,7 +3153,7 @@ if test ! "x$enable_mysql" = "xno"; then mysqllib=$found_lib mysqllibdir=$found_dir - # on linux, but maybe also other systems, explicitely add libz + # on linux, but maybe also other systems, explicitly add libz # (formally only needed when linking against the static libmysqlclient.a) if test ! "x$mysqllib" = "x" ; then case $platform in @@ -2919,10 +3198,13 @@ if test ! "x$enable_oracle" = "xno"; then check_library "libocci oraocci10" "$enable_shared" "$keeplibdir" \ $ORACLE ${ORACLE:+$ORACLE/lib} $ORACLELIBDIR \ /usr/local/lib /usr/lib /usr/lib/oracle/*/client/lib - oraclelib="$oraclelib $found_lib" + if test "x$found_lib" = "x"; then + oraclelib="" + elif test ! "x$oraclelib" = "x"; then + oraclelib="$oraclelib $found_lib" + fi - # space in "x " is intentional - if test "x$oracleincdir" = "x" || test "x$oraclelib" = "x "; then + if test "x$oracleincdir" = "x" || test "x$oraclelib" = "x"; then enable_oracle="no" fi fi @@ -2963,11 +3245,53 @@ if test ! "x$enable_pgsql" = "xno"; then if test "x$pgsqlincdir" = "x" || test "x$pgsqllib" = "x"; then enable_pgsql="no" + else + if test "x$arch" = xwin32gcc; then + pgsqllib="$pgsqllib -lssl -lldap -lcrypto -lintl" + fi fi fi check_explicit "$enable_pgsql" "$enable_pgsql_explicit" \ "Explicitly required PostGreSQL dependencies not fulfilled" +###################################################################### +# +### echo %%% SQLite Support - Third party libraries +# +# (See sqlite.org) +# +# If the user has set the flags "--disable-sqlite", we don't check for +# SQLite at all. +# +if test ! "x$enable_sqlite" = "xno"; then + # Check for SQLite include and library + check_header "sqlite3.h" "$sqliteincdir" \ + $SQLITE ${SQLITE:+$SQLITE/include} \ + ${finkdir:+$finkdir/include} \ + /usr/include /usr/local/include \ + /usr/include/sqlite /usr/local/include/sqlite /usr/local/sqlite/include \ + /usr/include/sqlite3 /usr/local/include/sqlite3 /usr/local/sqlite3/include \ + /usr/sqlite /opt/sqlite /opt/sqlite3/include \ + /usr/sqlite3 /opt/sqlite3 /opt/sqlite/include + sqliteinc=$found_hdr + sqliteincdir=$found_dir + + check_library "libsqlite3" "$enable_shared" "$sqlitelibdir" \ + $SQLITE ${SQLITE:+$SQLITE/lib} \ + ${finkdir:+$finkdir/lib} \ + /usr/local/sqlite/lib /usr/local/lib \ + /usr/lib/sqlite /usr/local/lib/sqlite /usr/sqlite/lib /usr/lib \ + /usr/sqlite /usr/local/sqlite /opt/sqlite /opt/sqlite/lib + sqlitelib=$found_lib + sqlitelibdir=$found_dir + + if test "x$sqliteincdir" = "x" || test "x$sqlitelib" = "x"; then + enable_sqlite="no" + fi +fi +check_explicit "$enable_sqlite" "$enable_sqlite_explicit" \ + "Explicitly required SQLite dependencies not fulfilled" + ###################################################################### # ### echo %%% SapDB/MaxDB Support - Third party libraries @@ -3393,6 +3717,20 @@ if test ! "x$enable_gfal" = "xno"; then gfallib=$found_lib gfallibdir=$found_dir + check_header "gfal_srm_ifce_types.h" "$srmifceincdir" \ + /opt/lcg/include /opt/srm-ifce/include /usr/local/lcg/include \ + /usr/local/srm-ifce/include + srmifceinc=$found_hdr + srmifceincdir=$found_dir + + # check if we have pkg-config + glib2incdir= + if `$cwhich pkg-config > /dev/null 2>&1` ; then + if pkg-config --exists glib-2.0 ; then + glib2incdir=`pkg-config --cflags-only-I glib-2.0 | sed 's/-I//g'` + fi + fi + if test "x$gfalincdir" = "x" || test "x$gfallib" = "x"; then enable_gfal="no" fi @@ -3531,7 +3869,7 @@ if test ! "x$enable_gviz" = "xno"; then gvizlib1=$found_lib gvizlib1raw=$found_raw_lib gvizlibir=$found_dir - check_library "libgraph graph" "no" "$gvizlibdir" \ + check_library "libgraph graph libcgraph cgraph" "no" "$gvizlibdir" \ $GVIZ ${GVIZ:+$GVIZ/lib/graphviz} ${GVIZ:+$GVIZ/lib} ${GVIZ:+$GVIZ/.libs} \ ${finkdir:+$finkdir/lib} \ /usr/local/lib /usr/lib @@ -3667,11 +4005,11 @@ check_explicit "$enable_pythia6" "$enable_pythia6_explicit" \ # # (See http://root.cern.ch and Lund) # -# Check for libpythia8 +# Check for libpythia8 >= 8180 # if test ! "x$enable_pythia8" = "xno" ; then # Check for PYTHIA8 include and library - check_header "Pythia.h" "$pythia8incdir" \ + check_header "Pythia8/Pythia.h" "$pythia8incdir" \ $PYTHIA8 ${PYTHIA8:+$PYTHIA8/include} \ /opt/pythia8/include /usr/local/include /usr/include /usr/include/pythia pythia8incdir=$found_dir @@ -3728,6 +4066,40 @@ fi check_explicit "$enable_dcache" "$enable_dcache_explicit" \ "Explicitly required dCache dependencies not fulfilled" +###################################################################### +# +### echo %%% DavIx Support - Third party libraries +# +if test ! "x$enable_davix" = "xno" ; then + check_header "davix.hpp" "$davixincdir" \ + $DAVIX ${DAVIX:+$DAVIX/include/davix} \ + /usr/local/include/davix \ + /usr/include/davix + davixincdir=$found_dir + + check_library "libdavix" "$enable_shared" "$davixlibdir" \ + $DAVIX ${DAVIX:+$DAVIX/lib} ${DAVIX:+$DAVIX/lib64} \ + /usr/lib /usr/lib64 /usr/local/lib64 + davixlib=$found_lib + davixlibdir=$found_dir + + if test ! "x$davixlib" = "x" ; then + check_symbol davix_logger "$davixlib" "$davixlibdir" + if test $found_symbol -eq 0 ; then + result "### Need davix_posix_stat in libdavix" + davixlib= + davixlibdir= + davixincdir= + fi + fi + + if test "x$davixincdir" = "x" || test "x$davixlib" = "x"; then + enable_davix="no" + fi +fi +check_explicit "$enable_davix" "$enable_davix_explicit" \ + "Explicitly required DavIx dependencies not fulfilled" + ###################################################################### # ### echo %%% Chirp Support - Third party libraries @@ -4015,7 +4387,7 @@ if test ! "x$enable_asimage" = "xno" ; then fi # If we didn't find the system libAfterImage, or the user didn't ask # for a system library, then see if we have various headers needed. - if test "x$enable_builtin_afterimage" = "xyes" ; then + if test "x$enable_builtin_afterimage" = "xyes" && test ! "x$enable_cocoa" = "xyes"; then check_header "jpeglib.h" "" \ $ASIMAGE ${ASIMAGE:+$ASIMAGE/include} \ ${finkdir:+$finkdir/include} \ @@ -4148,7 +4520,8 @@ if test ! "x$enable_python" = "xno" ; then if test ! "x$mypython" = "x" && test -x "$mypython" ; then pythonvers=`python -c 'import sys; sys.stdout.write(sys.version[:3])'` pythonsysincdir=`python -c 'import sys; sys.stdout.write(sys.prefix + "/include/python" + sys.version[:3])'` - pythonsyslibdir=`python -c 'import sys; sys.stdout.write(sys.prefix + "/lib/python" + sys.version[:3])'` + #pythonsyslibdir=`python -c 'import sys; sys.stdout.write(sys.prefix + "/lib/python" + sys.version[:3])'` + pythonsyslibdir=`python -c 'import sys; sys.stdout.write(sys.prefix + "/lib")'` pythonsyslibdir2= if test "x$platform" = "xmacosx"; then pythonsyslibdir2=`python -c 'import sys; sys.stdout.write(sys.prefix)'` @@ -4209,10 +4582,14 @@ if test ! "x$enable_ruby" = "xno" ; then # Check for Ruby include and library myruby=`$cwhich ruby 2> /dev/null` if test ! "x$myruby" = "x" && test -x "$myruby" ; then - rubysysincdir=`ruby -rrbconfig -e 'puts RbConfig::CONFIG["includedir"]'` + rubysysincdir=`ruby -rrbconfig -e 'puts RbConfig::CONFIG["rubyhdrdir"]'` rubysysarchdir=`ruby -rrbconfig -e 'puts RbConfig::CONFIG["archdir"]'` rubysyslibdir=`ruby -rrbconfig -e 'puts RbConfig::CONFIG["libdir"]'` rubysysarch=`ruby -rrbconfig -e 'puts RbConfig::CONFIG["arch"]'` + + if test "x$rubysysincdir" = "xnil" ; then + rubysysincdir=`ruby -rrbconfig -e 'puts RbConfig::CONFIG["includedir"]'` + fi fi rubysysarchdir2= if test "x$platform" = "xmacosx" ; then @@ -4231,9 +4608,9 @@ if test ! "x$enable_ruby" = "xno" ; then if test "x$arch" = "xwin32" || \ test "x$enable_shared" = "xno" ; then - check_library_options="libruby-static libruby1.8-static libruby1.9-static" + check_library_options=`ruby -rrbconfig -e 'puts RbConfig::CONFIG["LIBRUBY_A"]' | sed 's|\.a.*||'` else - check_library_options="libruby libruby1.8 libruby18 libruby1.9 libruby19" + check_library_options=`ruby -rrbconfig -e 'puts RbConfig::CONFIG["LIBRUBY"]' | sed 's|\.so.*||'` fi check_library "$check_library_options" \ "$enable_shared" "$rubylibdir" \ @@ -4353,7 +4730,7 @@ if test "x$enable_xrootd" = "xyes" ; then xrdcomm="" vercomm="" extraxrdflags="" - + # Localize the version header; priority to specific inc and lib settings, # followed by global dir setting and standard paths xrdincone="" @@ -4384,13 +4761,13 @@ if test "x$enable_xrootd" = "xyes" ; then if test ! "x$found_hdr" = "x" ; then xrdinc="$found_dir/$found_hdr" # Find out which path was the good one - if test "x$xrdinc" = "x$xrdincone" ; then + if test "x$xrdinc" = "x$xrdincone" ; then xrdincdir="$found_dir" xrdlibdir="$xrdlibone" - elif test "x$xrdinc" = "x$xrdinctwoa" ; then + elif test "x$xrdinc" = "x$xrdinctwoa" ; then xrdincdir="$xrdlibtwo/include/xrootd" xrdlibdir="$xrdlibtwo/lib" - elif test "x$xrdinc" = "x$xrdinctwob" ; then + elif test "x$xrdinc" = "x$xrdinctwob" ; then xrdincdir="$xrdlibtwo/src" xrdlibdir="$xrdlibtwo/lib" else @@ -4398,10 +4775,10 @@ if test "x$enable_xrootd" = "xyes" ; then rdir=`dirname $ll` xinca="$rdir/include/xrootd/XrdVersion.hh" xincb="$rdir/include/XrdVersion.hh" - if test "x$xrdinc" = "x$xinca" ; then + if test "x$xrdinc" = "x$xinca" ; then xrdincdir="$rdir/include/xrootd" xrdlibdir="$ll" - elif test "x$xrdinc" = "x$xincb" ; then + elif test "x$xrdinc" = "x$xincb" ; then xrdincdir="$rdir/include" xrdlibdir="$ll" fi @@ -4468,9 +4845,16 @@ if test "x$enable_xrootd" = "xyes" ; then fi fi fi - echo "$xrdver" + # Protect against 3.3.0, first version with 'include/xrootd/private' + if [ $decver -eq 300030000 ] ; then + echo "Cannot build against version $xrdver (missing headers)" + enable_xrootd="no" + else + echo "$xrdver" + fi fi +xrdincprivate="no" if test "x$enable_xrootd" = "xyes" ; then extraxrdflags="-DROOTXRDVERS=$decver" @@ -4480,19 +4864,25 @@ if test "x$enable_xrootd" = "xyes" ; then # Check libraries now hasxrdutils="no" libxrdoucbjr="" + # + # Release date of version 3.1.0 containing the new lib packaging + decreftre=300000000 decrefutils=300010000 + if [ $decver -lt $decreftre ] ; then + decrefutils=20111021 + fi decrefnetut=20100729 if [ $decver -ge $decrefutils ] ; then - xrdlibs="libXrdMain libXrdUtils libXrdClient" + xrdlibs="libXrdMain libXrdUtils libXrdClient" hasxrdutils="yes" elif [ $decver -ge $decrefnetut ] ; then - xrdlibs="libXrdNet libXrdNetUtil libXrdOuc libXrdSys libXrdClient libXrd" + xrdlibs="libXrdNet libXrdNetUtil libXrdOuc libXrdSys libXrdClient libXrd" else - xrdlibs="libXrdNet libXrdOuc libXrdSys libXrdClient libXrd" + xrdlibs="libXrdNet libXrdOuc libXrdSys libXrdClient libXrd" fi tmpxrdlibdir="" xrdlibext="" - for ll in $xrdlibs ; do + for ll in $xrdlibs ; do # # Check if packaging has libXrdUtils or the old libXrdOuc, libXrdSys, ... check_library $ll "$enable_shared" "$xrdlibdir" "$xrdlibdir" @@ -4519,6 +4909,15 @@ if test "x$enable_xrootd" = "xyes" ; then extraxrdflags="$extraxrdflags -DLT_MODULE_EXT=\\\\\".$xrdlibext\\\\\"" fi + # + # Check also if 'include/private' exists: we need to signal this to the build modules + # for correct location of some headers available form the dlevel packages for version >= 3.3.x + if test "x$enable_xrootd" = "xyes"; then + if test -d "$xrdincdir/private"; then + xrdincprivate="yes" + fi + fi + # # Check if bonjour is available for code potentially using it ... if test "x$enable_xrootd" = "xyes"; then @@ -4530,6 +4929,18 @@ if test "x$enable_xrootd" = "xyes" ; then fi fi fi + + # + # Build the new client interface (libNetxNG) only for xrootd >= 3.3.5 + decrefng=300030005 + buildnetxng="no" + useoldnetx="yes" + message "Checking whether new xrootd client (libNetxNG) should be build" + if [ $decver -ge $decrefng ] ; then + buildnetxng="yes" + useoldnetx="no" + fi + result $buildnetxng fi check_explicit "$enable_xrootd" "$enable_xrootd_explicit" \ @@ -4942,7 +5353,15 @@ if test "x$enable_ssl" = "xyes" ; then # # libssl # - libssl="libssl" + if test "x$platform" = "xwin32"; then + if test "x$enable_winrtdebug" = "xyes"; then + libssl="libssl ssleay32 ssleay32MDd" + else + libssl="libssl ssleay32 ssleay32MD" + fi + else + libssl="libssl" + fi tmpssllibdir="" check_library "$libssl" "$sslshared" "$ssllibdir" \ $SSL ${SSL:+$SSL/lib} \ @@ -4967,7 +5386,16 @@ if test "x$enable_ssl" = "xyes" ; then # # libcrypto, in the same dir # - check_library "libcrypto" "$sslshared" "$tmpssllibdir" \ + if test "x$platform" = "xwin32"; then + if test "x$enable_winrtdebug" = "xyes"; then + libcrypto="libcrypto libeay32 libeay32MDd" + else + libcrypto="libcrypto libeay32 libeay32MD" + fi + else + libcrypto="libcrypto" + fi + check_library "$libcrypto" "$sslshared" "$tmpssllibdir" \ $SSL ${SSL:+$SSL/lib} \ ${finkdir:+$finkdir/lib} \ /usr/lib /opt/lib /usr/local/lib @@ -5873,81 +6301,6 @@ else fi result $enable_memstat -###################################################################### -# -### echo %%% Clarens Support - Third party libraries -# -# (See http://clarens.sourceforge.net/) -# -checking_msg "Clarens support" - -if test ! "x$enable_clarens" = "xno" ; then - - myxmlrpc=`$cwhich xmlrpc-c-config 2> /dev/null` - if test ! "x$myxmlrpc" = "x" && test -x "$myxmlrpc" ; then - clarensincdir=`xmlrpc-c-config curl-client --cflags 2> /dev/null` - if test $? -ne 0 ; then clarensincdir= ; fi - clarenslibs=`xmlrpc-c-config curl-client --ldadd 2> /dev/null` - if test $? -ne 0 ; then clarenslibs= ; fi - if test "x$clarensincdir" = "x" ; then - clarensincdir=`xmlrpc-c-config client --cflags 2> /dev/null` - if test $? -ne 0 ; then clarensincdir= ; fi - clarenslibs=`xmlrpc-c-config client --ldadd 2> /dev/null` - if test $? -ne 0 ; then clarenslibs= ; fi - fi - if test "x$clarensincdir" = "x" ; then - clarensincdir=`xmlrpc-c-config --cflags 2> /dev/null` - if test $? -ne 0 ; then clarensincdir= ; fi - clarenslibs=`xmlrpc-c-config --ldadd 2> /dev/null` - if test $? -ne 0 ; then clarenslibs= ; fi - fi - else - clarensincdir="" - clarenslibs="" - fi - if test "x$cryptolib" = "x" ; then - # depends also on libcrypto - clarensincdir="" - clarenslibs="" - fi - if test "x$clarensincdir" = "x" || test "x$clarenslibs" = "x"; then - enable_clarens="no" - fi -fi - -if test "x$enable_clarens" = "xyes" ; then - result "yes" -else - result "no" -fi -check_explicit "$enable_clarens" "$enable_clarens_explicit" \ - "Explicitly required Clarens dependencies not fulfilled" - -###################################################################### -# -### echo %%% PEAC Support - depends on Clarens -# -# (See http://www.clarens.org) -# -checking_msg "PEAC support" - -if test ! "x$enable_peac" = "xno" ; then - - if test "x$enable_clarens" = "xno"; then - enable_peac="no" - fi -fi - -if test "x$enable_peac" = "xyes" ; then - buildpeac="yes" -else - buildpeac="no" -fi - -result "$buildpeac" -check_explicit "$enable_peac" "$enable_peac_explicit" \ - "Explicitly required Peac dependencies not fulfilled" - ###################################################################### # ### echo %%% Check for afdsmgrd support @@ -5977,10 +6330,10 @@ if test "x$enable_afdsmgrd" = "xyes" ; then fi if test ! "x$afdsmgrdapmondir" = "x" ; then - afdsmgrdapmon="--with-apmon=$afdsmgrdapmondir" + afdsmgrdapmon="$afdsmgrdapmondir" afdsmgrdapmonmsg=", using ApMon at $afdsmgrdapmondir" else - afdsmgrdapmon="--disable-apmon" + afdsmgrdapmon="" afdsmgrdapmonmsg=", ApMon support disabled" fi else @@ -6077,7 +6430,6 @@ if test "x$show_pkglist" = "xyes" ; then test "x$enable_unuran" = "xyes" && pl="$pl libroot-math-unuran" test "x$enable_table" = "xyes" && pl="$pl libroot-misc-table" test "x$enable_ldap" = "xyes" && pl="$pl libroot-net-ldap" - test "x$enable_clarens" = "xyes" && pl="$pl libroot-proof-clarens" test "x$enable_roofit" = "xyes" && pl="$pl libroot-roofit" test "x$enable_asimage" = "xyes" && pl="$pl root-plugin-graf2d-asimage" test "x$enable_gdml" = "xyes" && pl="$pl root-plugin-geom-gdml" @@ -6085,6 +6437,7 @@ if test "x$show_pkglist" = "xyes" ; then test "x$enable_castor" = "xyes" && pl="$pl root-plugin-io-castor" test "x$enable_chirp" = "xyes" && pl="$pl root-plugin-io-chirp" test "x$enable_dcache" = "xyes" && pl="$pl root-plugin-io-dcache" + test "x$enable_davix" = "xyes" && pl="$pl root-plugin-io-davix" test "x$enable_gfal" = "xyes" && pl="$pl root-plugin-io-gfal" test "x$enable_hdfs" = "xyes" && pl="$pl root-plugin-io-hdfs" test "x$enable_rfio" = "xyes" && pl="$pl root-plugin-io-rfio" @@ -6099,12 +6452,12 @@ if test "x$show_pkglist" = "xyes" ; then test "x$enable_krb5" = "xyes" && pl="$pl root-plugin-net-krb5" test "x$enable_monalisa" = "xyes" && pl="$pl root-plugin-net-monalisa" test "x$enable_srp" = "xyes" && pl="$pl root-plugin-net-srp" - test "x$enable_peac" = "xyes" && pl="$pl root-plugin-proof-peac" test "x$enable_mysql" = "xyes" && pl="$pl root-plugin-sql-mysql" test "x$enable_odbc" = "xyes" && pl="$pl root-plugin-sql-odbc" test "x$enable_oracle" = "xyes" && pl="$pl root-plugin-sql-oracle" test "x$enable_pgsql" = "xyes" && pl="$pl root-plugin-sql-pgsql" test "x$enable_sapdb" = "xyes" && pl="$pl root-plugin-sql-maxdb" + test "x$enable_sqlite" = "xyes" && pl="$pl root-plugin-sql-sqlite" test "x$enable_xrootd" = "xyes" && pl="$pl root-system-xrootd root-plugin-net-netx root-plugin-net-xrootd" pl="$pl \ @@ -6289,10 +6642,10 @@ if test ! "x$macosx106" = "x"; then rm -f bin/python64 bin/ruby64 fi rm -f lib/libRXML* bin/libRXML* etc/system.rootmap \ - lib/libProofGui* bin/libProofGui* \ + etc/svninfo.txt lib/libProofGui* bin/libProofGui* \ lib/libMySQL* bin/libMySQL* lib/libGedOld* bin/libGedOld* \ lib/libSQL.* bin/libSQL.* \ - lib/libASPluginGS.* bin/g2rootold* \ + lib/libASPluginGS.* bin/g2rootold* bin/ptest main/src/ptest.* \ math/mathcore/src/G__MathCore32.* \ tmva/src/G__TMVA.* graf3d/eve/src/G__Eve.* \ xrootd/src/headers.d include/Xpm.h \ @@ -6304,6 +6657,7 @@ rm -f lib/libRXML* bin/libRXML* etc/system.rootmap \ core/thread/src/TLockFile.* proof/proofplayer/src/TFileMerger.* \ graf2d/graf/src/G__Graf1.h graf2d/graf/src/G__Graf1.cxx \ graf2d/graf/src/G__Graf2.h graf2d/graf/src/G__Graf2.cxx \ + net/net/src/TAS3File.* net/net/src/TGSFile.* net/net/src/THTTPMessage.* \ etc/daemons/olbd.rc.d etc/daemons/cmsd.rc.d etc/daemons/xrootd.rc.d \ bin/cmsd bin/xprep bin/xrd bin/xrdcp bin/xrdgsiproxy bin/xrdpwdadmin \ bin/xrdsssadmin bin/xrdstagetool bin/xrootd lib/libXrd* \ @@ -6495,16 +6849,17 @@ sed -e "s|@aclocaldir@|$aclocaldir|" \ -e "s|@cintmaxstruct@|$cintmaxstruct|" \ -e "s|@cintmaxtypedef@|$cintmaxtypedef|" \ -e "s|@cintlongline@|$cintlongline|" \ - -e "s|@clarensincdir@|$clarensincdir|" \ - -e "s|@clarenslibs@|$clarenslibs|" \ -e "s|@cintincdir@|$cintincdir|" \ -e "s|@cppunit@|$cppunit|" \ -e "s|@datadir@|$datadir|" \ + -e "s|@davixincdir@|$davixincdir|" \ -e "s|@dcapincdir@|$dcapincdir|" \ -e "s|@comerrlib@|$comerrlib|" \ -e "s|@comerrlibdir@|$comerrlibdir|" \ -e "s|@cryptolib@|$cryptolib|" \ -e "s|@cryptolibdir@|$cryptolibdir|" \ + -e "s|@davixlib@|$davixlib|" \ + -e "s|@davixlibdir@|$davixlibdir|" \ -e "s|@dcaplib@|$dcaplib|" \ -e "s|@dcaplibdir@|$dcaplibdir|" \ -e "s|@dicttype@|$dicttype|" \ @@ -6545,6 +6900,8 @@ sed -e "s|@aclocaldir@|$aclocaldir|" \ -e "s|@etcdir@|$etcdir|" \ -e "s|@explicitlink@|$enable_explicitlink|" \ -e "s|@gfalincdir@|$gfalincdir|" \ + -e "s|@srmifceincdir@|$srmifceincdir|" \ + -e "s|@glib2incdir@|$glib2incdir|" \ -e "s|@gfallib@|$gfallib|" \ -e "s|@gfallibdir@|$gfallibdir|" \ -e "s|@enable_xft@|$enable_xft|" \ @@ -6563,6 +6920,8 @@ sed -e "s|@globusincdir@|$globusincdir|" \ -e "s|@hdfsincdir@|$hdfsincdir|" \ -e "s|@hdfslib@|$hdfslib|" \ -e "s|@hdfslibdir@|$hdfslibdir|" \ + -e "s|@iossdk@|$iossdk|" \ + -e "s|@iosvers@|$iosvers|" \ -e "s|@iconpath@|$iconpath|" \ -e "s|@incdir@|$incdir|" \ -e "s|@jniincdir@|$jniincdir|g" \ @@ -6579,6 +6938,7 @@ sed -e "s|@globusincdir@|$globusincdir|" \ -e "s|@ldflags@||" \ -e "s|@libdir@|$libdir|" \ -e "s|@llvmconfig@|$llvmconfig|" \ + -e "s|@macosxvers@|$macosxvers|" \ -e "s|@macrodir@|$macrodir|" \ -e "s|@mandir@|$mandir|" \ -e "s|@mkliboption@|$mkliboption|" \ @@ -6609,9 +6969,13 @@ sed -e "s|@globusincdir@|$globusincdir|" \ -e "s|@oracleincdir@|$oracleincdir|" \ -e "s|@oraclelib@|$oraclelib|" \ -e "s|@oraclelibdir@|$oraclelibdir|" \ + -e "s|@osxsdk@|$osxsdk|" \ -e "s|@pgsqlincdir@|$pgsqlincdir|" \ -e "s|@pgsqllib@|$pgsqllib|" \ -e "s|@pgsqllibdir@|$pgsqllibdir|" \ + -e "s|@sqliteincdir@|$sqliteincdir|" \ + -e "s|@sqlitelib@|$sqlitelib|" \ + -e "s|@sqlitelibdir@|$sqlitelibdir|" \ -e "s|@pythia6lib@|$pythia6lib|" \ -e "s|@pythia6libdir@|$pythia6libdir|" \ -e "s|@pythia6cppflags@|$pythia6cppflags|" \ @@ -6675,6 +7039,7 @@ sed -e "s|@srcdir@|$ac_srcdir|" \ -e "s|@xpmlibdir@|$xpmlibdir|" \ -e "s|@xrdlibdir@|$xrdlibdir|" \ -e "s|@xrdincdir@|$xrdincdir|" \ + -e "s|@xrdincprivate@|$xrdincprivate|" \ -e "s|@xrdversion@|$decver|" \ -e "s|@hasxrdutils@|$hasxrdutils|" \ -e "s|@cfitsioincdir@|$cfitsioincdir|" \ @@ -6685,6 +7050,7 @@ sed -e "s|@srcdir@|$ac_srcdir|" \ -e "s|@buildldap@|$enable_ldap|" \ -e "s|@buildmysql@|$enable_mysql|" \ -e "s|@buildpgsql@|$enable_pgsql|" \ + -e "s|@buildsqlite@|$enable_sqlite|" \ -e "s|@buildodbc@|$enable_odbc|" \ -e "s|@buildoracle@|$enable_oracle|" \ -e "s|@buildsapdb@|$enable_sapdb|" \ @@ -6693,6 +7059,7 @@ sed -e "s|@srcdir@|$ac_srcdir|" \ -e "s|@buildrfio@|$enable_rfio|" \ -e "s|@buildcastor@|$enable_castor|" \ -e "s|@builddcap@|$enable_dcache|" \ + -e "s|@builddavix@|$enable_davix|" \ -e "s|@buildfftw3@|$enable_fftw3|" \ -e "s|@buildgviz@|$enable_gviz|" \ -e "s|@buildgfal@|$enable_gfal|" \ @@ -6710,12 +7077,13 @@ sed -e "s|@srcdir@|$ac_srcdir|" \ -e "s|@buildsrputil@|$enable_srputil|" \ -e "s|@buildkrb5@|$enable_krb5|" \ -e "s|@buildglobus@|$enable_globus|" \ - -e "s|@buildclarens@|$enable_clarens|" \ - -e "s|@buildpeac@|$buildpeac|" \ -e "s|@buildafdsmgrd@|$enable_afdsmgrd|" \ -e "s|@afdsmgrdapmon@|$afdsmgrdapmon|" \ -e "s|@buildglite@|$enable_glite|" \ -e "s|@buildcocoa@|$enable_cocoa|" \ + -e "s|@buildnetxng@|$buildnetxng|" \ + -e "s|@c++11@|$enable_cxx11|" \ + -e "s|@libc++@|$enable_libcxx|" \ < Makefile.tmp > $MAKEOUT rm -f Makefile.tmp @@ -6768,6 +7136,8 @@ sed \ -e "s|@hasxft@|$hasxft|" \ -e "s|@hascling@|$hascling|" \ -e "s|@hascocoa@|$hascocoa|" \ + -e "s|@usec++11@|$usecxx11|" \ + -e "s|@uselibc++@|$uselibcxx|" \ < RConfigure.tmp > RConfigure-out.tmp rm -f RConfigure.tmp @@ -6813,9 +7183,10 @@ rm -f RConfigOptions.tmp if test ! "x$enable_ruby" = "xno"; then echo "" >> RConfigOptions-out.tmp - ruby -rrbconfig -e 'puts RbConfig::CONFIG["ruby_version"]' | \ - sed 's/^\([0-9]\)\.\([0-9]\).*$/#define R__RUBY_MAJOR \1@#define R__RUBY_MINOR \2/' | \ - tr '@' '\n' >> RConfigOptions-out.tmp + RUBY_MAJOR=`ruby -rrbconfig -e 'puts RbConfig::CONFIG["MAJOR"]'` + RUBY_MINOR=`ruby -rrbconfig -e 'puts RbConfig::CONFIG["MINOR"]'` + echo "#define R__RUBY_MAJOR $RUBY_MAJOR" >> RConfigOptions-out.tmp + echo "#define R__RUBY_MINOR $RUBY_MINOR" >> RConfigOptions-out.tmp fi # only update $CONFIGOPTOUT when different @@ -6908,6 +7279,7 @@ sed -e "s|@libdir@|$libdir|" \ -e "s|@iconpath@|$iconpath|" \ -e "s|@hasxrd@|$hasxrd|" \ -e "s|@hasnotxrd@|$hasnotxrd|" \ + -e "s|@useoldnetx@|$useoldnetx|" \ < rootrc.tmp > $ROOTRCOUT rm -f rootrc.tmp result "done" diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt index 82575311253b5..322de03962839 100644 --- a/core/CMakeLists.txt +++ b/core/CMakeLists.txt @@ -122,7 +122,7 @@ endif() #---Add flags to compile ObjC++ foreach(src ${LibCore_SRCS}) if(${src} MATCHES "\\.mm$") - set_source_files_properties(${src} COMPILE_FLAGS "-ObjC++ -std=c++11") + set_source_files_properties(${src} COMPILE_FLAGS "-ObjC++") endif() endforeach() diff --git a/core/base/Module.mk b/core/base/Module.mk index d190c94cd0cea..7159f7d0513f8 100644 --- a/core/base/Module.mk +++ b/core/base/Module.mk @@ -57,8 +57,6 @@ BASEO := $(call stripsrc,$(BASES:.cxx=.o)) BASEDEP := $(BASEO:.o=.d) $(BASEDO:.o=.d) -BASEO := $(filter-out $(call stripsrc,$(MODDIRS)/precompile.o),$(BASEO)) - # used in the main Makefile ALLHDRS += $(patsubst $(MODDIRI)/%.h,include/%.h,$(BASEH)) @@ -101,7 +99,7 @@ $(BASEDS4): all-$(MODNAME): $(BASEO) $(BASEDO) clean-$(MODNAME): - @rm -f $(BASEO) $(BASEDO) $(BASEDIRS)/precompile.o + @rm -f $(BASEO) $(BASEDO) clean:: clean-$(MODNAME) diff --git a/core/base/doc/macros/fonts.C b/core/base/doc/macros/fonts.C index f8bd51bb23e00..cd10f57482d0c 100644 --- a/core/base/doc/macros/fonts.C +++ b/core/base/doc/macros/fonts.C @@ -9,7 +9,7 @@ TCanvas * fonts() for (int f = 12; f<=152; f+=10) { if (f!=142) drawtext(0.02,y, f,"ABCDEFGH abcdefgh 0123456789 @#$"); else drawtext(0.02,y, f,"ABCD efgh 01234 @#$"); - y- = 0.065; + y -= 0.065; } return Tf; } diff --git a/core/base/inc/Byteswap.h b/core/base/inc/Byteswap.h index a289d20b414a8..64143bfd27fa2 100644 --- a/core/base/inc/Byteswap.h +++ b/core/base/inc/Byteswap.h @@ -29,6 +29,13 @@ write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ +#if (defined(__linux) || defined(__APPLE__)) && \ + (defined(__i386__) || defined(__x86_64__)) && \ + (defined(__GNUC__) && __GNUC__ >= 2) +#ifndef R__USEASMSWAP +#define R__USEASMSWAP +#endif +#endif /* Get the machine specific, optimized definitions. */ /* The following is copied from (only from RH6.0 and above) */ @@ -37,7 +44,7 @@ #define R__bswap_constant_16(x) \ ((((x) >> 8) & 0xff) | (((x) & 0xff) << 8)) -#if defined __GNUC__ && __GNUC__ >= 2 +#if defined R__USEASMSWAP # define R__bswap_16(x) \ (__extension__ \ ({ register unsigned short int __v; \ @@ -60,7 +67,7 @@ ((((x) & 0xff000000) >> 24) | (((x) & 0x00ff0000) >> 8) | \ (((x) & 0x0000ff00) << 8) | (((x) & 0x000000ff) << 24)) -#if defined __GNUC__ && __GNUC__ >= 2 +#if defined R__USEASMSWAP /* To swap the bytes in a word the i486 processors and up provide the `bswap' opcode. On i386 we have to use three instructions. */ # if !defined __i486__ && !defined __pentium__ && !defined __pentiumpro__ && \ diff --git a/core/base/inc/LinkDef2.h b/core/base/inc/LinkDef2.h index 949aa69d4f7b6..281f6637d1022 100644 --- a/core/base/inc/LinkDef2.h +++ b/core/base/inc/LinkDef2.h @@ -132,10 +132,10 @@ #pragma link C++ class TSystem+; #pragma link C++ class TSystemFile+; #pragma link C++ class TSystemDirectory+; -#pragma linl C++ class SysInfo_t+; -#pragma linl C++ class CpuInfo_t+; -#pragma linl C++ class MemInfo_t+; -#pragma linl C++ class ProcInfo_t+; +#pragma link C++ class SysInfo_t+; +#pragma link C++ class CpuInfo_t+; +#pragma link C++ class MemInfo_t+; +#pragma link C++ class ProcInfo_t+; #pragma link C++ class TTask+; #pragma link C++ class TTime; #pragma link C++ class TTimer; diff --git a/core/base/inc/MessageTypes.h b/core/base/inc/MessageTypes.h index 5f850b954097e..5068c28199ecd 100644 --- a/core/base/inc/MessageTypes.h +++ b/core/base/inc/MessageTypes.h @@ -64,7 +64,7 @@ enum EMessageTypes { kPROOF_HOSTAUTH = 1023, //HostAuth info follows kPROOF_GETSLAVEINFO = 1024, //get worker info from master kPROOF_GETTREEHEADER = 1025, //get tree object - kPROOF_GETOUTPUTLIST = 1026, //get the output list + kPROOF_GETOUTPUTLIST = 1026, //get the output list names kPROOF_GETSTATS = 1027, //get statistics of workers kPROOF_GETPARALLEL = 1028, //get number of parallel workers kPROOF_VALIDATE_DSET = 1029, //validate a TDSet @@ -95,6 +95,8 @@ enum EMessageTypes { kPROOF_FORK = 1054, //ask the worker to clone itself kPROOF_GOASYNC = 1055, //switch to asynchronous mode kPROOF_SUBMERGER = 1056, //sub-merger based approach in finalization + kPROOF_ECHO = 1057, //object echo request from client + kPROOF_SENDOUTPUT = 1058, //control output sending //---- ROOTD message opcodes (2000 - 2099) kROOTD_USER = 2000, //user id follows diff --git a/core/base/inc/RConfig.h b/core/base/inc/RConfig.h index b797ea4bec576..560462e71df9e 100644 --- a/core/base/inc/RConfig.h +++ b/core/base/inc/RConfig.h @@ -28,6 +28,11 @@ #define R__USE_SHADOW_CLASS +/* Do not #define nullptr if the code is compiled in c++11 mode. */ +#if __cplusplus > 199711L +#define R__NULLPTR +#endif + /*---- machines --------------------------------------------------------------*/ #ifdef __hpux @@ -415,7 +420,7 @@ # if __GNUC__ >= 3 || __GNUC_MINOR__ >= 91 /* egcs 1.1.x */ # define R__ANSISTREAM /* ANSI C++ Standard Library conformant */ # endif -# if __GNUC__ >= 3 && __GNUC_MINOR__ >=0 && __GNUC_MINOR__ < 8 +# if __GNUC__ >= 3 # define R__SSTREAM /* use sstream or strstream header */ # endif # if defined(__ia64__) && __GNUC__ < 3 /* gcc 2.9x (MINOR is 9!) */ diff --git a/core/base/inc/RVersion.h b/core/base/inc/RVersion.h index 3d09cd33782cf..71e12d23d4ae0 100644 --- a/core/base/inc/RVersion.h +++ b/core/base/inc/RVersion.h @@ -14,12 +14,13 @@ * */ -#define ROOT_RELEASE "5.34/00-rc1" -#define ROOT_RELEASE_DATE "May 7 2012" -#define ROOT_RELEASE_TIME "15:01:57" -#define ROOT_SVN_REVISION 44153 -#define ROOT_SVN_BRANCH "trunk" -#define ROOT_VERSION_CODE 336384 +#define ROOT_RELEASE "5.34/13" +#define ROOT_RELEASE_DATE "Nov 30 2013" +#define ROOT_RELEASE_TIME "23:01:20" +#define ROOT_SVN_REVISION 49361 +#define ROOT_GIT_COMMIT "v5-34-12-50-g2a9389b" +#define ROOT_GIT_BRANCH "heads/v5-34-00-patches" +#define ROOT_VERSION_CODE 336397 #define ROOT_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c)) #endif diff --git a/core/base/inc/Rtypes.h b/core/base/inc/Rtypes.h index 47e0219f8d3dd..345e82a30f1ee 100644 --- a/core/base/inc/Rtypes.h +++ b/core/base/inc/Rtypes.h @@ -76,6 +76,7 @@ typedef float Float_t; //Float 4 bytes (float) typedef float Float16_t; //Float 4 bytes written with a truncated mantissa typedef double Double_t; //Double 8 bytes typedef double Double32_t; //Double 8 bytes in memory, written as a 4 bytes float +typedef long double LongDouble_t;//Long Double typedef char Text_t; //General string (char) typedef bool Bool_t; //Boolean (0=false, 1=true) (bool) typedef unsigned char Byte_t; //Byte (8 bits) (unsigned char) diff --git a/core/base/inc/RtypesImp.h b/core/base/inc/RtypesImp.h index 1841d6763f98c..df89767a0c4af 100644 --- a/core/base/inc/RtypesImp.h +++ b/core/base/inc/RtypesImp.h @@ -56,4 +56,8 @@ namespace ROOT { \ } #endif +namespace ROOT { + void RegisterModule(); +} + #endif diff --git a/core/base/inc/TAttFill.h b/core/base/inc/TAttFill.h index 6c67b1bbf0ea5..4af45e642a123 100644 --- a/core/base/inc/TAttFill.h +++ b/core/base/inc/TAttFill.h @@ -56,5 +56,14 @@ class TAttFill { inline Bool_t TAttFill::IsTransparent() const { return fFillStyle >= 4000 && fFillStyle <= 4100 ? kTRUE : kFALSE; } -#endif + enum EFillStyle {kFDotted1 = 3001, kFDotted2 = 3002, kFDotted3 = 3003, + kFHatched1 = 3004, kHatched2 = 3005, kFHatched3 = 3006, + kFHatched4 = 3007, kFWicker = 3008, kFScales = 3009, + kFBricks = 3010, kFSnowflakes = 3011, kFCircles = 3012, + kFTiles = 3013, kFMondrian = 3014, kFDiamonds = 3015, + kFWaves1 = 3016, kFDashed1 = 3017, kFDashed2 = 3018, + kFAlhambra = 3019, kFWaves2 = 3020, kFStars1 = 3021, + kFStars2 = 3022, kFPyramids = 3023, kFFrieze = 3024, + kFMetopes = 3025, kFEmpty = 0 , kFSolid = 1}; +#endif diff --git a/core/base/inc/TAttText.h b/core/base/inc/TAttText.h index 7103b1c9bce00..f2223d1aa7354 100644 --- a/core/base/inc/TAttText.h +++ b/core/base/inc/TAttText.h @@ -62,5 +62,8 @@ class TAttText { ClassDef(TAttText,1) //Text attributes }; + enum ETextAlign {kHAlignLeft=10, kHAlignCenter=20, kHAlignRight=30, + kVAlignBottom=1, kVAlignCenter=2, kVAlignTop=3}; + #endif diff --git a/core/base/inc/TBuffer.h b/core/base/inc/TBuffer.h index ff5fb6a396083..07467f78ceb7f 100644 --- a/core/base/inc/TBuffer.h +++ b/core/base/inc/TBuffer.h @@ -121,6 +121,7 @@ class TBuffer : public TObject { virtual void SkipVersion(const TClass *cl = 0) = 0; virtual Version_t ReadVersion(UInt_t *start = 0, UInt_t *bcnt = 0, const TClass *cl = 0) = 0; + virtual Version_t ReadVersionNoCheckSum(UInt_t *start = 0, UInt_t *bcnt = 0) = 0; virtual Version_t ReadVersionForMemberWise(const TClass *cl = 0) = 0; virtual UInt_t WriteVersion(const TClass *cl, Bool_t useBcnt = kFALSE) = 0; virtual UInt_t WriteVersionMemberWise(const TClass *cl, Bool_t useBcnt = kFALSE) = 0; @@ -214,6 +215,10 @@ class TBuffer : public TObject { virtual void ReadFastArray(Double_t *d, Int_t n) = 0; virtual void ReadFastArrayFloat16(Float_t *f, Int_t n, TStreamerElement *ele=0) = 0; virtual void ReadFastArrayDouble32(Double_t *d, Int_t n, TStreamerElement *ele=0) = 0; + virtual void ReadFastArrayWithFactor(Float_t *ptr, Int_t n, Double_t factor, Double_t minvalue) = 0; + virtual void ReadFastArrayWithNbits(Float_t *ptr, Int_t n, Int_t nbits) = 0; + virtual void ReadFastArrayWithFactor(Double_t *ptr, Int_t n, Double_t factor, Double_t minvalue) = 0; + virtual void ReadFastArrayWithNbits(Double_t *ptr, Int_t n, Int_t nbits) = 0; virtual void ReadFastArray(void *start , const TClass *cl, Int_t n=1, TMemberStreamer *s=0, const TClass *onFileClass=0) = 0; virtual void ReadFastArray(void **startp, const TClass *cl, Int_t n=1, Bool_t isPreAlloc=kFALSE, TMemberStreamer *s=0, const TClass *onFileClass=0) = 0; diff --git a/core/base/inc/TColor.h b/core/base/inc/TColor.h index dae28c6ece901..eccc842cc9bae 100644 --- a/core/base/inc/TColor.h +++ b/core/base/inc/TColor.h @@ -74,7 +74,7 @@ class TColor : public TNamed { static void CreateColorsCircle(Int_t offset, const char *name, UChar_t *rgb); static void CreateColorsRectangle(Int_t offset, const char *name, UChar_t *rgb); static Int_t CreateGradientColorTable(UInt_t Number, Double_t* Stops, - Double_t* Red, Double_t* Green, Double_t* Blue, UInt_t NColors); + Double_t* Red, Double_t* Green, Double_t* Blue, UInt_t NColors, Float_t alpha=1.); static Int_t GetColorPalette(Int_t i); static Int_t GetNumberOfColors(); virtual void GetRGB(Float_t &r, Float_t &g, Float_t &b) const @@ -119,10 +119,10 @@ class TColor : public TNamed { static void Pixel2RGB(ULong_t pixel, Int_t &r, Int_t &g, Int_t &b); static void Pixel2RGB(ULong_t pixel, Float_t &r, Float_t &g, Float_t &b); static const char *PixelAsHexString(ULong_t pixel); - static void SaveColor(ostream &out, Int_t ci); + static void SaveColor(std::ostream &out, Int_t ci); static Bool_t IsGrayscale(); static void SetGrayscale(Bool_t set = kTRUE); - static void SetPalette(Int_t ncolors, Int_t *colors); + static void SetPalette(Int_t ncolors, Int_t *colors,Float_t alpha=1.); ClassDef(TColor,2) //Color defined by RGB or HLS }; diff --git a/core/base/inc/TDirectory.h b/core/base/inc/TDirectory.h index 717c9e300257b..8e45657896fc5 100644 --- a/core/base/inc/TDirectory.h +++ b/core/base/inc/TDirectory.h @@ -197,7 +197,7 @@ class TDirectory : public TNamed { virtual void WriteKeys() {} static Bool_t Cd(const char *path); - static void DecodeNameCycle(const char *namecycle, char *name, Short_t &cycle); + static void DecodeNameCycle(const char *namecycle, char *name, Short_t &cycle, const size_t namesize = 0); static void EncodeNameCycle(char *buffer, const char *name, Short_t cycle); ClassDef(TDirectory,5) //Describe directory structure in memory diff --git a/core/base/inc/TFileCollection.h b/core/base/inc/TFileCollection.h index d6525838a03d0..efdf1860f25f2 100644 --- a/core/base/inc/TFileCollection.h +++ b/core/base/inc/TFileCollection.h @@ -56,6 +56,9 @@ class TFileCollection : public TNamed { TFileCollection(const TFileCollection&); // not implemented TFileCollection& operator=(const TFileCollection&); // not implemented + void PrintDetailed(TString &showOnly) const; + void FormatSize(Long64_t bytes, TString &um, Double_t &size) const; + public: enum EStatusBits { kRemoteCollection = BIT(15) // the collection is not staged diff --git a/core/base/inc/TFileInfo.h b/core/base/inc/TFileInfo.h index b5e8a2ce5e930..86b10654a84db 100644 --- a/core/base/inc/TFileInfo.h +++ b/core/base/inc/TFileInfo.h @@ -81,6 +81,8 @@ class TFileInfo : public TNamed { TUrl *NextUrl(); TUrl *GetCurrentUrl() const; TUrl *GetFirstUrl() const { return (TUrl*)fUrlList->First(); } + TUrl *GetUrlAt(Int_t i) const { return (TUrl*)fUrlList->At(i); } + Bool_t RemoveUrlAt(Int_t i); Int_t GetNUrls() const { return fUrlList->GetEntries(); } Bool_t SetCurrentUrl(const char *url); diff --git a/core/base/inc/TMacro.h b/core/base/inc/TMacro.h index 1e00e5520482d..0461c01e241c8 100644 --- a/core/base/inc/TMacro.h +++ b/core/base/inc/TMacro.h @@ -36,6 +36,8 @@ class TMacro : public TNamed { TList *fLines; //collection of lines TString fParams; //default string of macro parameters + void SaveSource(FILE *fp); + public: TMacro(); TMacro(const TMacro&); diff --git a/core/base/inc/TMathBase.h b/core/base/inc/TMathBase.h index e875e3222e2ce..380d2d16441bc 100644 --- a/core/base/inc/TMathBase.h +++ b/core/base/inc/TMathBase.h @@ -98,7 +98,7 @@ inline Bool_t TMath::Odd(Long_t a) //---- Abs --------------------------------------------------------------------- inline Short_t TMath::Abs(Short_t d) - { return (d >= 0) ? d : -d; } +{ return (d >= 0) ? d : Short_t(-d); } inline Int_t TMath::Abs(Int_t d) { return (d >= 0) ? d : -d; } @@ -118,7 +118,7 @@ inline Double_t TMath::Abs(Double_t d) //---- Sign -------------------------------------------------------------------- inline Short_t TMath::Sign(Short_t a, Short_t b) - { return (b >= 0) ? Abs(a) : -Abs(a); } +{ return (b >= 0) ? Abs(a) : Short_t(-Abs(a)); } inline Int_t TMath::Sign(Int_t a, Int_t b) { return (b >= 0) ? Abs(a) : -Abs(a); } diff --git a/core/base/inc/TObject.h b/core/base/inc/TObject.h index 01f60b068bc24..8bb1566cf2c08 100644 --- a/core/base/inc/TObject.h +++ b/core/base/inc/TObject.h @@ -209,6 +209,8 @@ class TObject { static Bool_t GetObjectStat(); static void SetObjectStat(Bool_t stat); + friend class TClonesArray; // needs to reset kNotDeleted in fBits + ClassDef(TObject,1) //Basic ROOT object }; diff --git a/core/base/inc/TPRegexp.h b/core/base/inc/TPRegexp.h index 7b11c58f114b2..93d83d6b2d5a9 100644 --- a/core/base/inc/TPRegexp.h +++ b/core/base/inc/TPRegexp.h @@ -53,6 +53,8 @@ class TPRegexp { PCREPriv_t *fPriv; UInt_t fPCREOpts; + static Bool_t fgThrowAtCompileError; + void Compile(); void Optimize(); UInt_t ParseMods(const TString &mods) const; @@ -73,6 +75,8 @@ class TPRegexp { TPRegexp(const TPRegexp &p); virtual ~TPRegexp(); + Bool_t IsValid() const; + Int_t Match(const TString &s, const TString &mods="", Int_t start=0, Int_t nMaxMatch=10, TArrayI *pos=0); TObjArray *MatchS(const TString &s, const TString &mods="", @@ -89,6 +93,9 @@ class TPRegexp { TPRegexp &operator=(const TPRegexp &p); + static Bool_t GetThrowAtCompileError(); + static void SetThrowAtCompileError(Bool_t throwp); + ClassDef(TPRegexp,0) // Perl Compatible Regular Expression Class }; diff --git a/core/base/inc/TParameter.h b/core/base/inc/TParameter.h index ab39989569249..73c3de7d0393e 100644 --- a/core/base/inc/TParameter.h +++ b/core/base/inc/TParameter.h @@ -49,26 +49,56 @@ template class TParameter : public TObject { public: - enum EStatusBits { kMultiply = BIT(16) }; // Use multiplication while merging + // Defines options / status while merging: + enum EStatusBits { kMultiply = BIT(16), // Use multiplication + kMax = BIT(17), // Take max value + kMin = BIT(18), // Take min value + kFirst = BIT(19), // Take the first value + kLast = BIT(20), // Take the last value + kIsConst = BIT(21) // Set if all values are equal + }; private: TString fName; AParamType fVal; + + void Reset() { ResetBit(kMultiply); ResetBit(kMax); ResetBit(kMin); + ResetBit(kFirst); ResetBit(kLast); } public: - TParameter() { /* leave fVal uninitialized */ } + TParameter(): fVal() { Reset(); SetBit(kIsConst); } TParameter(const char *name, const AParamType &val) - : fName(name), fVal(val) { ResetBit(kMultiply); } + : fName(name), fVal(val) { Reset(); SetBit(kIsConst);} TParameter(const char *name, const AParamType &val, char mergemode) - : fName(name), fVal(val) { SetMergeMode(mergemode); } + : fName(name), fVal(val) { SetMergeMode(mergemode); SetBit(kIsConst);} ~TParameter() { } const char *GetName() const { return fName; } const AParamType &GetVal() const { return fVal; } + Bool_t IsConst() const { return (TestBit(kIsConst) ? kTRUE : kFALSE); } void SetVal(const AParamType &val) { fVal = val; } - void SetMergeMode(char mergemode = '+') { ResetBit(kMultiply); - if (mergemode == '*') SetBit(kMultiply); } + // Merging modes: + // '+' addition ('OR' for booleans) [default] + // '*' multiplication ('AND' for booleans) + // 'M' maximum ('OR' for booleans) + // 'm' minimum ('AND' for booleans) + // 'f' first value + // 'l' last value + void SetMergeMode(char mergemode = '+') { + Reset(); + if (mergemode == '*') { + SetBit(kMultiply); + } else if (mergemode == 'M') { + SetBit(kMax); + } else if (mergemode == 'm') { + SetBit(kMin); + } else if (mergemode == 'f') { + SetBit(kFirst); + } else if (mergemode == 'l') { + SetBit(kLast); + } + } virtual ULong_t Hash() const { return fName.Hash(); } virtual Bool_t IsSortable() const { return kTRUE; } virtual Int_t Compare(const TObject *obj) const { @@ -105,10 +135,24 @@ inline Int_t TParameter::Merge(TCollection *in) { while (TObject *o = nxo()) { TParameter *c = dynamic_cast *>(o); if (c) { - if (TestBit(kMultiply)) + // Check if constant + if (fVal != c->GetVal()) ResetBit(kIsConst); + if (TestBit(kMultiply)) { + // Multiply fVal *= c->GetVal(); - else + } else if (TestBit(kMax)) { + // Take max + if (c->GetVal() > fVal) fVal = c->GetVal(); + } else if (TestBit(kMin)) { + // Take min + if (c->GetVal() < fVal) fVal = c->GetVal(); + } else if (TestBit(kLast)) { + // Take the last + fVal = c->GetVal(); + } else if (!TestBit(kFirst)) { + // Add, if not asked to take the first fVal += c->GetVal(); + } n++; } } @@ -127,10 +171,18 @@ inline Int_t TParameter::Merge(TCollection *in) while (TObject *o = nxo()) { TParameter *c = dynamic_cast *>(o); if (c) { - if (TestBit(TParameter::kMultiply)) + // Check if constant + if (fVal != (Bool_t) c->GetVal()) ResetBit(kIsConst); + if (TestBit(TParameter::kMultiply) || TestBit(kMin)) { + // And fVal &= (Bool_t) c->GetVal(); - else + } else if (TestBit(kLast)) { + // Take the last + fVal = (Bool_t) c->GetVal(); + } else if (!TestBit(kFirst) || TestBit(kMax)) { + // Or fVal |= (Bool_t) c->GetVal(); + } n++; } } diff --git a/core/base/inc/TROOT.h b/core/base/inc/TROOT.h index 6fa3b7a08184a..78d3a96a07ac7 100644 --- a/core/base/inc/TROOT.h +++ b/core/base/inc/TROOT.h @@ -79,9 +79,10 @@ friend class TCintWithCling; Int_t fVersionTime; //Time of ROOT version (ex 1152) Int_t fBuiltDate; //Date of ROOT built Int_t fBuiltTime; //Time of ROOT built - Int_t fSvnRevision; //Subversion revision number of built - TString fSvnBranch; //Subversion branch - TString fSvnDate; //Date and time when make was run + Int_t fSvnRevision; //Subversion revision number of built (dec value of Git short SHA1) + TString fGitCommit; //Git commit SHA1 of built + TString fGitBranch; //Git branch + TString fGitDate; //Date and time when make was run Int_t fTimer; //Timer flag TApplication *fApplication; //Pointer to current application TInterpreter *fInterpreter; //Command interpreter @@ -131,7 +132,7 @@ friend class TCintWithCling; TROOT(); //Only used by Dictionary void InitSystem(); //Operating System interface void InitThreads(); //Initialize threads library - void ReadSvnInfo(); //Read Subversion revision number and branch name + void ReadGitInfo(); //Read Subversion revision number and branch name void *operator new(size_t l) { return TObject::operator new(l); } public: @@ -142,6 +143,7 @@ friend class TCintWithCling; void Browse(TBrowser *b); Bool_t ClassSaved(TClass *cl); void CloseFiles(); + void EndOfProcessCleanups(); virtual TObject *FindObject(const char *name) const; virtual TObject *FindObject(const TObject *obj) const; virtual TObject *FindObjectAny(const char *name) const; @@ -168,8 +170,11 @@ friend class TCintWithCling; Int_t GetBuiltDate() const { return fBuiltDate; } Int_t GetBuiltTime() const { return fBuiltTime; } Int_t GetSvnRevision() const { return fSvnRevision; } - const char *GetSvnBranch() const { return fSvnBranch; } - const char *GetSvnDate(); + const char *GetSvnBranch() const { return fGitBranch; } + const char *GetSvnDate() { return GetGitDate(); } + const char *GetGitCommit() const { return fGitCommit; } + const char *GetGitBranch() const { return fGitBranch; } + const char *GetGitDate(); Int_t GetVersionDate() const { return fVersionDate; } Int_t GetVersionTime() const { return fVersionTime; } Int_t GetVersionInt() const { return fVersionInt; } diff --git a/core/base/inc/TRemoteObject.h b/core/base/inc/TRemoteObject.h index cd8ca7eb8249b..ee547b9c9b68c 100755 --- a/core/base/inc/TRemoteObject.h +++ b/core/base/inc/TRemoteObject.h @@ -17,7 +17,7 @@ // // // The TRemoteObject class provides protocol for browsing ROOT objects // // from a remote ROOT session. // -// It contains informations on the real remote object as: // +// It contains information on the real remote object as: // // - Object Properties (i.e. file stat if the object is a TSystemFile) // // - Object Name // // - Class Name // diff --git a/core/base/inc/TStyle.h b/core/base/inc/TStyle.h index 6392f7ca01684..1ac7b6770ee4c 100644 --- a/core/base/inc/TStyle.h +++ b/core/base/inc/TStyle.h @@ -1,4 +1,4 @@ -// @(#)root/base:$Id$ +// @(#)root/base:$Id: 5214d7dc2746ceb518366bc6c4f4068b652d5241 $ // Author: Rene Brun 12/12/94 /************************************************************************* @@ -160,7 +160,12 @@ class TStyle : public TNamed, public TAttLine, public TAttFill, public TAttMarke TStyle(const char *name, const char *title); TStyle(const TStyle &style); virtual ~TStyle(); - Int_t AxisChoice(Option_t *axis) const; + inline Int_t AxisChoice(Option_t *axis) const { + // Return axis number (1 for X, 2 for Y, 3 for Z) + UChar_t a = *axis; + a -= (a >= 'x') ? 'x' : 'X'; // toupper and a-='X'; intentional underflow + return (a > 2) ? 0 : (Int_t)(a+1); + }; virtual void Browse(TBrowser *b); static void BuildStyles(); virtual void Copy(TObject &style) const; @@ -370,8 +375,8 @@ class TStyle : public TNamed, public TAttLine, public TAttFill, public TAttMarke void SetPaintTextFormat(const char *format="g") {fPaintTextFormat = format;} void SetPaperSize(EPaperSize size); void SetPaperSize(Float_t xsize=20, Float_t ysize=26); - void SetStatColor(Int_t color=19) {fStatColor=color;} - void SetStatTextColor(Int_t color=1) {fStatTextColor=color;} + void SetStatColor(Color_t color=19) {fStatColor=color;} + void SetStatTextColor(Color_t color=1) {fStatTextColor=color;} void SetStatStyle(Style_t style=1001) {fStatStyle=style;} void SetStatBorderSize(Width_t size=2) {fStatBorderSize=size;} void SetStatFont(Style_t font=62) {fStatFont=font;} @@ -401,8 +406,8 @@ class TStyle : public TNamed, public TAttLine, public TAttFill, public TAttMarke void ToggleEditor() { fShowEditor = fShowEditor ? 0 : 1; } void ToggleToolBar() { fShowToolBar = fShowToolBar ? 0 : 1; } void SetIsReading(Bool_t reading=kTRUE); - void SetPalette(Int_t ncolors=0, Int_t *colors=0); - void SavePrimitive(ostream &out, Option_t * = ""); + void SetPalette(Int_t ncolors=0, Int_t *colors=0, Float_t alpha=1.); + void SavePrimitive(std::ostream &out, Option_t * = ""); void SaveSource(const char *filename, Option_t *option=0); ClassDef(TStyle, 14); //A collection of all graphics attributes diff --git a/core/base/inc/TUri.h b/core/base/inc/TUri.h index 9548322fc9d39..bb781d88223be 100644 --- a/core/base/inc/TUri.h +++ b/core/base/inc/TUri.h @@ -43,7 +43,7 @@ friend Bool_t operator==(const TUri &u1, const TUri &u2); // comparison operator private: // In order to represent the five basic components of an URI, - // we use 7 member variables (authority gets splitted in 3 parts) + // we use 7 member variables (authority gets split in 3 parts) // // foo://user:pass@example.com:8042/over/there?name=ferret#nose // \_/ \________________________/\_________/ \_________/ \__/ diff --git a/core/base/inc/TVirtualGL.h b/core/base/inc/TVirtualGL.h index 2ccb060ee2f01..d015bcea72c2e 100644 --- a/core/base/inc/TVirtualGL.h +++ b/core/base/inc/TVirtualGL.h @@ -128,6 +128,22 @@ class TGLManager : public TNamed { ClassDef(TGLManager, 0)// Interface for OpenGL manager }; +namespace Rgl { + +//I would prefer to use C++11's strong typed enums insted, but ... +enum EFormatOptions +{ + kNone = 0, + kDoubleBuffer = 1, + kDepth = 2, + kAccum = 4, + kStencil = 8, + kStereo = 16, + kMultiSample = 32 +}; + +} + class TGLContext; class TGLFormat; diff --git a/core/base/inc/TVirtualPS.h b/core/base/inc/TVirtualPS.h index f89d642f1a2df..a635cf83daa6b 100644 --- a/core/base/inc/TVirtualPS.h +++ b/core/base/inc/TVirtualPS.h @@ -48,7 +48,7 @@ class TVirtualPS : public TNamed, public TAttLine, public TAttFill, public TAttM Int_t fLenBuffer; //Buffer length Int_t fSizBuffer; //Buffer size Bool_t fPrinted; //True when a page must be printed - ofstream *fStream; //File stream identifier + std::ofstream *fStream; //File stream identifier char *fBuffer; //File buffer const char *fImplicitCREsc; //Escape symbol before enforced new line @@ -70,14 +70,16 @@ class TVirtualPS : public TNamed, public TAttLine, public TAttFill, public TAttM virtual void NewPage() = 0; virtual void Open(const char *filename, Int_t type=-111) = 0; virtual void Text(Double_t x, Double_t y, const char *string) = 0; + virtual void Text(Double_t x, Double_t y, const wchar_t *string) = 0; virtual void SetColor(Float_t r, Float_t g, Float_t b) = 0; virtual void PrintFast(Int_t nch, const char *string=""); virtual void PrintStr(const char *string=""); virtual void WriteInteger(Int_t i, Bool_t space=kTRUE); - virtual void WriteReal(Float_t r); + virtual void WriteReal(Float_t r, Bool_t space=kTRUE); + virtual void PrintRaw(Int_t len, const char *str); virtual void *GetStream() const { return (void*)fStream; } - virtual void SetStream(ofstream *os) { fStream = os; } + virtual void SetStream(std::ofstream *os) { fStream = os; } virtual void SetType(Int_t /*type*/ = -111) { } virtual Int_t GetType() const { return 111; } diff --git a/core/base/inc/TVirtualPad.h b/core/base/inc/TVirtualPad.h index 5c4a269b25b08..856c609fd46a5 100644 --- a/core/base/inc/TVirtualPad.h +++ b/core/base/inc/TVirtualPad.h @@ -176,7 +176,9 @@ class TVirtualPad : public TObject, public TAttLine, public TAttFill, virtual void PaintPolyMarker(Int_t n, Double_t *x, Double_t *y, Option_t *option="") = 0; virtual void PaintModified() = 0; virtual void PaintText(Double_t x, Double_t y, const char *text) = 0; + virtual void PaintText(Double_t x, Double_t y, const wchar_t *text) = 0; virtual void PaintTextNDC(Double_t u, Double_t v, const char *text) = 0; + virtual void PaintTextNDC(Double_t u, Double_t v, const wchar_t *text) = 0; virtual Double_t PixeltoX(Int_t px) = 0; virtual Double_t PixeltoY(Int_t py) = 0; virtual void Pop() = 0; diff --git a/core/base/inc/TVirtualPadPainter.h b/core/base/inc/TVirtualPadPainter.h index f701bfea94663..aa293cfa40962 100644 --- a/core/base/inc/TVirtualPadPainter.h +++ b/core/base/inc/TVirtualPadPainter.h @@ -85,7 +85,9 @@ class TVirtualPadPainter { virtual void DrawPolyMarker(Int_t n, const Float_t *x, const Float_t *y) = 0; virtual void DrawText(Double_t x, Double_t y, const char *text, ETextMode mode) = 0; + virtual void DrawText(Double_t x, Double_t y, const wchar_t *text, ETextMode mode) = 0; virtual void DrawTextNDC(Double_t u, Double_t v, const char *text, ETextMode mode) = 0; + virtual void DrawTextNDC(Double_t u, Double_t v, const wchar_t *text, ETextMode mode) = 0; //gif, jpg, png, bmp output. virtual void SaveImage(TVirtualPad *pad, const char *fileName, Int_t type) const = 0; diff --git a/core/base/inc/TVirtualX.h b/core/base/inc/TVirtualX.h index c42e43e1751d6..700da88018f7d 100644 --- a/core/base/inc/TVirtualX.h +++ b/core/base/inc/TVirtualX.h @@ -24,6 +24,9 @@ // // ////////////////////////////////////////////////////////////////////////// +#include +#include + #ifndef ROOT_TNamed #include "TNamed.h" #endif @@ -87,6 +90,15 @@ class TVirtualX : public TNamed, public TAttLine, public TAttFill, public TAttTe virtual void CopyPixmap(Int_t wid, Int_t xpos, Int_t ypos); virtual void CreateOpenGLContext(Int_t wid=0); virtual void DeleteOpenGLContext(Int_t wid=0); + + //---- OpenGL related stuff, required only with R__HAS_COCOA ---- + virtual Double_t GetOpenGLScalingFactor(); + virtual Window_t CreateOpenGLWindow(Window_t parentID, UInt_t width, UInt_t height, const std::vector > &format); + virtual Handle_t CreateOpenGLContext(Window_t windowID, Handle_t sharedContext); + virtual Bool_t MakeOpenGLContextCurrent(Handle_t ctx, Window_t windowID); + virtual Handle_t GetCurrentOpenGLContext(); + virtual void FlushOpenGLBuffer(Handle_t ctx); + virtual void DrawBox(Int_t x1, Int_t y1, Int_t x2, Int_t y2, EBoxMode mode); virtual void DrawCellArray(Int_t x1, Int_t y1, Int_t x2, Int_t y2, Int_t nx, Int_t ny, Int_t *ic); @@ -96,6 +108,8 @@ class TVirtualX : public TNamed, public TAttLine, public TAttFill, public TAttTe virtual void DrawPolyMarker(Int_t n, TPoint *xy); virtual void DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, const char *text, ETextMode mode); + virtual void DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, const wchar_t *text, + ETextMode mode); virtual UInt_t ExecCommand(TGWin32Command *code); virtual void GetCharacterUp(Float_t &chupx, Float_t &chupy); EDrawMode GetDrawMode() { return fDrawMode; } @@ -107,6 +121,7 @@ class TVirtualX : public TNamed, public TAttLine, public TAttFill, public TAttTe virtual void GetPlanes(Int_t &nplanes); virtual void GetRGB(Int_t index, Float_t &r, Float_t &g, Float_t &b); virtual void GetTextExtent(UInt_t &w, UInt_t &h, char *mess); + virtual void GetTextExtent(UInt_t &w, UInt_t &h, wchar_t *mess); virtual Int_t GetFontAscent() const; virtual Int_t GetFontDescent() const ; virtual Float_t GetTextMagnitude(); diff --git a/core/base/src/TApplication.cxx b/core/base/src/TApplication.cxx index d0d847ba5a300..95fb1e525f284 100644 --- a/core/base/src/TApplication.cxx +++ b/core/base/src/TApplication.cxx @@ -45,6 +45,8 @@ #include "TBrowser.h" #include "TUrl.h" +#include + #if defined(R__MACOSX) && (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR) #include "TGIOS.h" #endif @@ -74,6 +76,13 @@ Bool_t TIdleTimer::Notify() ClassImp(TApplication) +static void CallEndOfProcessCleanups() +{ + // Insure that the files, canvases and sockets are closed. + + gROOT->EndOfProcessCleanups(); +} + //______________________________________________________________________________ TApplication::TApplication() : fArgc(0), fArgv(0), fAppImp(0), fIsRunning(kFALSE), fReturnFromRun(kFALSE), @@ -126,6 +135,10 @@ TApplication::TApplication(const char *appClassName, Int_t *argc, char **argv, if (!gSystem) ::Fatal("TApplication::TApplication", "gSystem not initialized"); + if (!gApplication) { + // If we are the first TApplication register the atexit) + atexit(CallEndOfProcessCleanups); + } gApplication = this; gROOT->SetApplication(this); gROOT->SetName(appClassName); @@ -197,7 +210,7 @@ TApplication::~TApplication() for (int i = 0; i < fArgc; i++) if (fArgv[i]) delete [] fArgv[i]; delete [] fArgv; - SafeDelete(fAppImp); + if (fgApplications) fgApplications->Remove(this); @@ -206,6 +219,21 @@ TApplication::~TApplication() ProcessLine("TMemStat::Close()"); fUseMemstat = kFALSE; } + + // Reduce the risk of the files or sockets being closed after the + // end of 'main' (or more exactly before the library start being + // unloaded). + if (fgApplications == 0 || fgApplications->FirstLink() == 0 ) { + if (gROOT) { + gROOT->EndOfProcessCleanups(); + } else if (gInterpreter) { + gInterpreter->ResetGlobals(); + } + } + + // Now that all the canvases and files have been closed we can + // delete the implementation. + SafeDelete(fAppImp); } //______________________________________________________________________________ @@ -721,7 +749,7 @@ Long_t TApplication::ProcessRemote(const char *line, Int_t *) Printf("(as in ssh). A \"dbg\" value > 0 gives increasing verbosity."); Printf("The last argument \"script\" allows to specify an alternative script to"); Printf("be executed remotely to startup the session, \"roots\" being"); - Printf("the default. If the script is preceeded by a \"<\" the script will be"); + Printf("the default. If the script is preceded by a \"<\" the script will be"); Printf("sourced, after which \"roots\" is executed. The sourced script can be "); Printf("used to change the PATH and other variables, allowing an alternative"); Printf("\"roots\" script to be found."); @@ -945,7 +973,7 @@ Long_t TApplication::ExecuteFile(const char *file, Int_t *error, Bool_t keep) Long_t retval = 0; while (1) { - bool res = macro.getline(currentline, kBufSize); + bool res = (bool)macro.getline(currentline, kBufSize); if (macro.eof()) break; if (!res) { // Probably only read kBufSize, let's ignore the remainder of diff --git a/core/base/src/TAttMarker.cxx b/core/base/src/TAttMarker.cxx index 035afde1b1e07..f1ad2f576b9f4 100644 --- a/core/base/src/TAttMarker.cxx +++ b/core/base/src/TAttMarker.cxx @@ -85,7 +85,7 @@ accessed via a global name (third column). 27 open diamond kOpenDiamond 28 open cross kOpenCross 29 full star kFullStar - 30 open star kOpenStark + 30 open star kOpenStar 31 * 32 open triangle down 33 full diamond diff --git a/core/base/src/TAttText.cxx b/core/base/src/TAttText.cxx index 154b0a27248cf..f000fc85bee82 100644 --- a/core/base/src/TAttText.cxx +++ b/core/base/src/TAttText.cxx @@ -85,6 +85,16 @@ Begin_Macro(source) textangle.C End_Macro +Mnemonic constants are available: +
+kHAlignLeft   = 10, kHAlignCenter = 20, kHAlignRight = 30,
+kVAlignBottom = 1,  kVAlignCenter = 2,  kVAlignTop   = 3
+
+They allow to write: +
+object->SetTextAlign(kHAlignLeft+kVAlignTop);
+
+ Begin_Html

Text Color

The text color is a color index (integer) pointing in the ROOT diff --git a/core/base/src/TBenchmark.cxx b/core/base/src/TBenchmark.cxx index af1092ba2f649..e5d99f5ae6986 100644 --- a/core/base/src/TBenchmark.cxx +++ b/core/base/src/TBenchmark.cxx @@ -16,20 +16,18 @@ TBenchmark *gBenchmark = 0; ClassImp(TBenchmark) -//______________________________________________________________________________ ////////////////////////////////////////////////////////////////////////// -// -// This class is a ROOT utility to help benchmarking applications -// -// Examples of use of this class are given in the tutorials macros. +// // +// TBenchmark // +// // +// This class is a ROOT utility to help benchmarking applications // +// // ////////////////////////////////////////////////////////////////////////// - //______________________________________________________________________________ TBenchmark::TBenchmark(): TNamed() { -//*-*-*-*-*-*-*-*-*-*-*Benchmark default constructor*-*-*-*-*-*-*-*-*-*-*-*-*-* -//*-* ============================= + // Benchmark default constructor fNbench = 0; fNmax = 20; @@ -49,7 +47,8 @@ TBenchmark::TBenchmark(const TBenchmark& bm) : fCpuTime(0), fTimer(0) { - //copy constructor + // Copy constructor. + fNames = new TString[fNmax]; fRealTime = new Float_t[fNmax]; fCpuTime = new Float_t[fNmax]; @@ -66,8 +65,9 @@ TBenchmark::TBenchmark(const TBenchmark& bm) : //______________________________________________________________________________ TBenchmark& TBenchmark::operator=(const TBenchmark& bm) { - //assignment operator - if(this!=&bm) { + // Assignment operator. + + if (this!=&bm) { TNamed::operator=(bm); fNbench=bm.fNbench; fNmax=bm.fNmax; @@ -95,8 +95,7 @@ TBenchmark& TBenchmark::operator=(const TBenchmark& bm) //______________________________________________________________________________ TBenchmark::~TBenchmark() { -//*-*-*-*-*-*-*-*-*-*-*Benchmark default destructor*-*-*-*-*-*-*-*-*-*-*-*-*-* -//*-* ============================ + // Benchmark destructor. fNbench = 0; if (fNames) { delete [] fNames; fNames = 0;} @@ -108,8 +107,7 @@ TBenchmark::~TBenchmark() //______________________________________________________________________________ Int_t TBenchmark::GetBench(const char *name) const { -//*-*-*-*-*-*-*-*-*-*-*Returns index of Benchmark name*-*-*-*-*-*-*-* -//*-* =============================== + // Returns index of Benchmark name. for (Int_t i=0;i= 0) return fCpuTime[bench]; @@ -131,8 +128,7 @@ Float_t TBenchmark::GetCpuTime(const char *name) //______________________________________________________________________________ Float_t TBenchmark::GetRealTime(const char *name) { -//*-*-*-*-*-*-*-*-*-*-*Returns Realtime used by Benchmark name*-*-*-*-*-*-*-* -//*-* ======================================= + // Returns Realtime used by Benchmark name. Int_t bench = GetBench(name); if (bench >= 0) return fRealTime[bench]; @@ -142,8 +138,7 @@ Float_t TBenchmark::GetRealTime(const char *name) //______________________________________________________________________________ void TBenchmark::Print(const char *name) const { -//*-*-*-*-*-*-*-*-*-*-*Prints parameters of Benchmark name*-*-*-*-*-*-*-*-*-* -//*-* =================================== + // Prints parameters of Benchmark name. Int_t bench = GetBench(name); if (bench < 0) return; @@ -153,18 +148,15 @@ void TBenchmark::Print(const char *name) const //______________________________________________________________________________ void TBenchmark::Reset() { -//*-*-*-*-*-*-*-*-*-*-*-*-*-*Reset all Benchmarks*-*-*-*-*-*-*-*-*-*-*-*-* -//*-* ==================== + // Reset all Benchmarks fNbench = 0; - } //______________________________________________________________________________ void TBenchmark::Show(const char *name) { -//*-*-*-*-*-*-*-*-*Stops Benchmark name and Prints results*-*-*-*-*-*-*-*-*-* -//*-* ======================================= + // Stops Benchmark name and Prints results Stop(name); Print((char*)name); @@ -173,18 +165,16 @@ void TBenchmark::Show(const char *name) //______________________________________________________________________________ void TBenchmark::Start(const char *name) { -//*-*-*-*-*-*-*-*-*-*-*-*-*-*-*Starts Benchmark name*-*-*-*-*-*-*-*-*-* -//*-* ===================== -//*-* -//*-* An independent timer (see class TStopwatch) is started. -//*-* the name of the benchmark is entered into the list of benchmarks. -//*-* Benchmark can be stopped via TBenchmark::Stop -//*-* Results can be printed via TBenchmark::Print -//*-* TBenchmark::Show can be used to stop benchmark and print results. -//*-* If name is an already existing benchmark, existing parameters are reset. -//*-* A summary of all benchmarks can be seen via TBenchmark::Summary. -//*-* -//*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-**-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-* + // Starts Benchmark with the specified name. + // + // An independent timer (see class TStopwatch) is started. + // The name of the benchmark is entered into the list of benchmarks. + // Benchmark can be stopped via TBenchmark::Stop(). + // Results can be printed via TBenchmark::Print(). + // TBenchmark::Show() can be used to stop benchmark and print results. + // If name is an already existing benchmark, timing will resume. + // A summary of all benchmarks can be seen via TBenchmark::Summary(). + if (!fNames) { fNames = new TString[fNmax]; fRealTime = new Float_t[fNmax]; @@ -193,7 +183,7 @@ void TBenchmark::Start(const char *name) } Int_t bench = GetBench(name); if (bench < 0 && fNbench < fNmax ) { - // define a new benchmark to Start + // define a new benchmark to Start fNames[fNbench] = name; bench = fNbench; fNbench++; @@ -201,20 +191,18 @@ void TBenchmark::Start(const char *name) fTimer[bench].Start(); fRealTime[bench] = 0; fCpuTime[bench] = 0; - } else if (bench >=0) { - // Resume the existen benchmark + } else if (bench >= 0) { + // Resume the existing benchmark fTimer[bench].Continue(); } else - Warning("Start","too many benches"); - + Warning("Start","too many benchemarks"); } //______________________________________________________________________________ void TBenchmark::Stop(const char *name) { -//*-*-*-*-*-*-*-*-*-*-*Terminates Benchmark name*-*-*-*-*-*-*-*-*-*-*-* -//*-* ========================= + // Terminates Benchmark with specified name. Int_t bench = GetBench(name); if (bench < 0) return; @@ -222,14 +210,12 @@ void TBenchmark::Stop(const char *name) fTimer[bench].Stop(); fRealTime[bench] = fTimer[bench].RealTime(); fCpuTime[bench] = fTimer[bench].CpuTime(); - } //______________________________________________________________________________ void TBenchmark::Summary(Float_t &rt, Float_t &cp) { -//*-*-*-*-*-*-*-*-*-*-*-*-*-*Prints a summary of all benchmarks*-*-*-*-*-*-*-* -//*-* ================================== + // Prints a summary of all benchmarks. rt = 0; cp = 0; @@ -239,5 +225,4 @@ void TBenchmark::Summary(Float_t &rt, Float_t &cp) cp += fCpuTime[i]; } Printf("%-10s: Real Time = %6.2f seconds Cpu Time = %6.2f seconds","TOTAL",rt,cp); - } diff --git a/core/base/src/TBuffer.cxx b/core/base/src/TBuffer.cxx index 6da0b5b613bbc..ac8d8bde0216d 100644 --- a/core/base/src/TBuffer.cxx +++ b/core/base/src/TBuffer.cxx @@ -1,4 +1,4 @@ -// @(#)root/base:$Id$ +// @(#)root/base:$Id: 6da0b5b613bbcfaa3a5cd4074e7b2be2448dfb31 $ // Author: Fons Rademakers 04/05/96 /************************************************************************* @@ -277,6 +277,11 @@ void TBuffer::SetReadMode() { // Set buffer in read mode. + if ( (fMode&kWrite)!=0 ) { + // We had reserved space for the free block count, + // release it, + fBufSize += kExtraSpace; + } fMode = kRead; } @@ -285,6 +290,11 @@ void TBuffer::SetWriteMode() { // Set buffer in write mode. + if ( (fMode&kWrite)==0 ) { + // We had not yet reserved space for the free block count, + // reserve it now. + fBufSize -= kExtraSpace; + } fMode = kWrite; } diff --git a/core/base/src/TColor.cxx b/core/base/src/TColor.cxx index 2ed06c8860a18..63b1115ce5d45 100644 --- a/core/base/src/TColor.cxx +++ b/core/base/src/TColor.cxx @@ -26,6 +26,7 @@ Bool_t TColor::fgGrayscaleMode = kFALSE; Bool_t TColor::fgInitDone = kFALSE; TArrayI TColor::fgPalette(0); +using std::floor; //______________________________________________________________________________ /* Begin_Html @@ -207,7 +208,7 @@ Begin_Macro(source) End_Macro Begin_Html -

The function TColor::CreateGradientColorTable() automatically +

The function TColor::CreateGradientColorTable() automatically calls gStyle->SetPalette(), so there is not need to add one.

After a call to TColor::CreateGradientColorTable() it is sometimes @@ -237,13 +238,13 @@ The following macro illustrate this feature. End_Html Begin_Macro(source) ../../../tutorials/graphs/multipalette.C -End_Macro +End_Macro Begin_Html

Color transparency

-To make a graphics object transparent it is enough to set its color to a -transparent one. The color transparency is defined via its alpha component. The -alpha value varies from 0. (fully transparent) to 1. (fully +To make a graphics object transparent it is enough to set its color to a +transparent one. The color transparency is defined via its alpha component. The +alpha value varies from 0. (fully transparent) to 1. (fully opaque). To set the alpha value of an existing color it is enough to do:
    TColor *col26 = gROOT->GetColor(26);
@@ -252,13 +253,14 @@ opaque). To set the alpha value of an existing color it is enough to do:
 A new color can be created transparent the following way:
 
    Int_t ci = 1756;
-   TColor *color = new TColor(ci, 0.1, 0.2, 0.3, 0.5); // alpha = 0.5
+   TColor *color = new TColor(ci, 0.1, 0.2, 0.3, "", 0.5); // alpha = 0.5
 
An example of tranparency usage with parallel coordinates can be found -in $ROOTSYS/tutorials/tree/parallelcoordtrans.C. Right now the +in $ROOTSYS/tutorials/tree/parallelcoordtrans.C. Right now the transparency is implemented only for PDF output, SVG output, and for gif, jpg and png outputs. -*/ + +End_Html */ //______________________________________________________________________________ @@ -1385,7 +1387,7 @@ const char *TColor::PixelAsHexString(ULong_t pixel) //______________________________________________________________________________ -void TColor::SaveColor(ostream &out, Int_t ci) +void TColor::SaveColor(std::ostream &out, Int_t ci) { /* Begin_html Save a color with index > 228 as a C++ statement(s) on output stream out. @@ -1406,13 +1408,13 @@ void TColor::SaveColor(ostream &out, Int_t ci) cname.Form("#%02x%02x%02x", ri, gi, bi); if (gROOT->ClassSaved(TColor::Class())) { - out << endl; + out << std::endl; } else { - out << endl; - out << " Int_t ci; // for color index setting" << endl; + out << std::endl; + out << " Int_t ci; // for color index setting" << std::endl; } - out<<" ci = TColor::GetColor("<GetColor(highestIndex)->SetAlpha(alpha); palette[nPalette] = highestIndex; nPalette++; highestIndex++; @@ -1578,7 +1581,7 @@ Int_t TColor::CreateGradientColorTable(UInt_t Number, Double_t* Stops, //______________________________________________________________________________ -void TColor::SetPalette(Int_t ncolors, Int_t *colors) +void TColor::SetPalette(Int_t ncolors, Int_t *colors, Float_t alpha) { /* Begin_html Static function. @@ -1593,17 +1596,6 @@ void TColor::SetPalette(Int_t ncolors, Int_t *colors) if ncolors <= 0 a default palette (see below) of 50 colors is defined. The colors defined in this palette are OK for coloring pads, labels.

- if ncolors == 1 && colors == 0, then a Pretty Palette with a - Spectrum Violet->Red is created. It is recommended to use this Pretty - palette when drawing legos, surfaces or contours. -

- if ncolors > 50 and colors=0, the DeepSea palette is used. - (see TColor::CreateGradientColorTable for more details) -

- if ncolors > 0 and colors = 0, the default palette is used - with a maximum of ncolors. -

- The default palette defines:

    index 0->9   : grey colors from light to dark grey
    index 10->19 : "brown" colors
@@ -1611,9 +1603,32 @@ void TColor::SetPalette(Int_t ncolors, Int_t *colors)
    index 30->39 : "redish" colors
    index 40->49 : basic colors
    
+

+ if ncolors == 1 && colors == 0, then a Pretty Palette with a + Spectrum Violet->Red is created with 50 colors. That's the default rain bow + pallette. +

+ Other prefined palettes with 255 colors are available when colors == 0. + The following value of ncolors give access to: +

+

+   if ncolors = 51 and colors=0, a Deep Sea palette is used.
+   if ncolors = 52 and colors=0, a Grey Scale palette is used.
+   if ncolors = 53 and colors=0, a Dark Body Radiator palette is used.
+   if ncolors = 54 and colors=0, a two-color hue palette palette is used.(dark blue through neutral gray to bright yellow)
+   if ncolors = 55 and colors=0, a Rain Bow palette is used.
+   if ncolors = 56 and colors=0, an inverted Dark Body Radiator palette is used.
+   
+ (see TColor::CreateGradientColorTable for more details) +

The color numbers specified in the palette can be viewed by selecting the item "colors" in the "VIEW" menu of the canvas toolbar. The color parameters can be changed via TColor::SetRGB. +

+ Note that when drawing a 2D histogram h2 with the option "COL" or + "COLZ" or with any "CONT" options using the color map, the number of colors + used is defined by the number of contours n specified with: + h2->SetContour(n) End_html */ Int_t i; @@ -1641,24 +1656,94 @@ void TColor::SetPalette(Int_t ncolors, Int_t *colors) return; } - // set DeepSea palette - if (ncolors > 50 && colors == 0) { + // set Deep Sea palette + if (ncolors == 51 && colors == 0) { TColor::InitializeColors(); - if (ncolors == fgPalette.fN && paletteType == 3) return; + if (paletteType == 3) return; const Int_t nRGBs = 5; Double_t stops[nRGBs] = { 0.00, 0.34, 0.61, 0.84, 1.00 }; Double_t red[nRGBs] = { 0.00, 0.09, 0.18, 0.09, 0.00 }; Double_t green[nRGBs] = { 0.01, 0.02, 0.39, 0.68, 0.97 }; Double_t blue[nRGBs] = { 0.17, 0.39, 0.62, 0.79, 0.97 }; - TColor::CreateGradientColorTable(nRGBs, stops, red, green, blue, ncolors); + TColor::CreateGradientColorTable(nRGBs, stops, red, green, blue, 255, alpha); paletteType = 3; return; } + // set Grey Scale palette + if (ncolors == 52 && colors == 0) { + TColor::InitializeColors(); + if (paletteType == 4) return; + const Int_t nRGBs = 3; + Double_t stops[nRGBs] = { 0.00, 0.50, 1.00}; + Double_t red[nRGBs] = { 0.00, 0.50, 1.00}; + Double_t green[nRGBs] = { 0.00, 0.50, 1.00}; + Double_t blue[nRGBs] = { 0.00, 0.50, 1.00}; + TColor::CreateGradientColorTable(nRGBs, stops, red, green, blue, 255, alpha); + paletteType = 4; + return; + } + + // set Dark Body Radiator palette + if (ncolors == 53 && colors == 0) { + TColor::InitializeColors(); + if (paletteType == 5) return; + const Int_t nRGBs = 5; + Double_t stops[nRGBs] = { 0.00, 0.25, 0.50, 0.75, 1.00}; + Double_t red[nRGBs] = { 0.00, 0.50, 1.00, 1.00, 1.00}; + Double_t green[nRGBs] = { 0.00, 0.00, 0.55, 1.00, 1.00}; + Double_t blue[nRGBs] = { 0.00, 0.00, 0.00, 0.00, 1.00}; + TColor::CreateGradientColorTable(nRGBs, stops, red, green, blue, 255, alpha); + paletteType = 5; + return; + } + + // set two-color hue palette (dark blue through neutral gray to bright yellow) + if (ncolors == 54 && colors == 0) { + TColor::InitializeColors(); + if (paletteType == 6) return; + const Int_t nRGBs = 3; + Double_t stops[nRGBs] = { 0.00, 0.50, 1.00}; + Double_t red[nRGBs] = { 0.00, 0.50, 1.00}; + Double_t green[nRGBs] = { 0.00, 0.50, 1.00}; + Double_t blue[nRGBs] = { 0.50, 0.50, 0.00}; + TColor::CreateGradientColorTable(nRGBs, stops, red, green, blue, 255, alpha); + paletteType = 6; + return; + } + + // set Rain Bow palette + if (ncolors == 55 && colors == 0) { + TColor::InitializeColors(); + if (paletteType == 7) return; + const Int_t nRGBs = 5; + Double_t stops[nRGBs] = { 0.00, 0.34, 0.61, 0.84, 1.00 }; + Double_t red[nRGBs] = { 0.00, 0.00, 0.87, 1.00, 0.51 }; + Double_t green[nRGBs] = { 0.00, 0.81, 1.00, 0.20, 0.00 }; + Double_t blue[nRGBs] = { 0.51, 1.00, 0.12, 0.00, 0.00 }; + TColor::CreateGradientColorTable(nRGBs, stops, red, green, blue, 255, alpha); + paletteType = 7; + return; + } + + // set Inverted Dark Body Radiator palette + if (ncolors == 56 && colors == 0) { + TColor::InitializeColors(); + if (paletteType == 8) return; + const Int_t nRGBs = 5; + Double_t stops[nRGBs] = { 0.00, 0.25, 0.50, 0.75, 1.00}; + Double_t red[nRGBs] = { 1.00, 1.00, 1.00, 0.50, 0.00}; + Double_t green[nRGBs] = { 1.00, 1.00, 0.55, 0.00, 0.00}; + Double_t blue[nRGBs] = { 1.00, 0.00, 0.00, 0.00, 0.00}; + TColor::CreateGradientColorTable(nRGBs, stops, red, green, blue, 255, alpha); + paletteType = 8; + return; + } + // set user defined palette fgPalette.Set(ncolors); if (colors) for (i=0;iExecute((TObject *)0x%lx," - "(TMethod *)0x%lx,(TObjArray *)0);", + "(TMethod *)0x%lx,\"\");", (Long_t)this,(Long_t)object,(Long_t)method); //Printf("%s", cmd); gROOT->ProcessLine(cmd); @@ -171,8 +171,9 @@ void TContextMenu::Action(TClassMenuItem *menuitem) #else // It is a workaround of the "Dead lock under Windows char *cmd = Form("((TContextMenu *)0x%lx)->Execute((TObject *)0x%lx," - "(TMethod *)0x%lx,(TObjArray *)0);", - (Long_t)this,(Long_t)object,(Long_t)method); + "(TMethod *)0x%lx,(TObject*)0x%lx);", + (Long_t)this,(Long_t)object,(Long_t)method, + (Long_t)fSelectedObject); //Printf("%s", cmd); gROOT->ProcessLine(cmd); //Execute( object, method, (TObjArray *)NULL ); diff --git a/core/base/src/TDirectory.cxx b/core/base/src/TDirectory.cxx index 188a2b9772585..76a2f5c42ebbd 100644 --- a/core/base/src/TDirectory.cxx +++ b/core/base/src/TDirectory.cxx @@ -8,6 +8,7 @@ * For the licensing terms see $ROOTSYS/LICENSE. * * For the list of contributors see $ROOTSYS/README/CREDITS. * *************************************************************************/ +#include #include "Riostream.h" #include "Strlen.h" @@ -541,7 +542,7 @@ void TDirectory::Delete(const char *namecycle) TDirectory::TContext ctxt(gDirectory, this); Short_t cycle; char name[kMaxLen]; - DecodeNameCycle(namecycle, name, cycle); + DecodeNameCycle(namecycle, name, cycle, kMaxLen); Int_t deleteall = 0; Int_t deletetree = 0; @@ -683,7 +684,7 @@ TObject *TDirectory::Get(const char *namecycle) Short_t cycle; char name[kMaxLen]; - DecodeNameCycle(namecycle, name, cycle); + DecodeNameCycle(namecycle, name, cycle, kMaxLen); char *namobj = name; Int_t nch = strlen(name); for (Int_t i = nch-1; i > 0; i--) { @@ -768,7 +769,7 @@ void *TDirectory::GetObjectChecked(const char *namecycle, const TClass* expected Short_t cycle; char name[kMaxLen]; - DecodeNameCycle(namecycle, name, cycle); + DecodeNameCycle(namecycle, name, cycle, kMaxLen); char *namobj = name; Int_t nch = strlen(name); for (Int_t i = nch-1; i > 0; i--) { @@ -889,7 +890,16 @@ TDirectory *TDirectory::mkdir(const char *name, const char *title) // Returns 0 if a directory with the same name already exists. // Note that the directory name may be of the form "a/b/c" to create a hierarchy of directories. // In this case, the function returns the pointer to the "a" directory if the operation is successful. - + // + // For example the step to the steps to create first a/b/c and then a/b/d without receiving + // and errors are: + // TFile * file = new TFile("afile","RECREATE"); + // file->mkdir("a"); + // file->cd("a"); + // gDirectory->mkdir("b"); + // gDirectory->cd("b"); + // gDirectory->mkdir("d"); + // if (!name || !title || !strlen(name)) return 0; if (!strlen(title)) title = name; TDirectory *newdir = 0; @@ -898,7 +908,12 @@ TDirectory *TDirectory::mkdir(const char *name, const char *title) char *workname = new char[size+1]; strncpy(workname, name, size); workname[size] = 0; - TDirectory *tmpdir = mkdir(workname,title); + TDirectory *tmpdir; + GetObject(workname,tmpdir); + if (!tmpdir) { + tmpdir = mkdir(workname,title); + if (!tmpdir) return 0; + } delete[] workname; if (!tmpdir) return 0; if (!newdir) newdir = tmpdir; @@ -1075,27 +1090,42 @@ void TDirectory::EncodeNameCycle(char *buffer, const char *name, Short_t cycle) } //______________________________________________________________________________ -void TDirectory::DecodeNameCycle(const char *buffer, char *name, Short_t &cycle) +void TDirectory::DecodeNameCycle(const char *buffer, char *name, Short_t &cycle, + const size_t namesize) { - // Decode a namecycle "aap;2" into name "aap" and cycle "2". - - cycle = 9999; - Int_t nch = buffer ? strlen(buffer) : 0; - for (Int_t i = 0; i < nch; i++) { - if (buffer[i] != ';') - name[i] = buffer[i]; - else { - name[i] = 0; - if (i < nch-1 ) - if (buffer[i+1] == '*') { - cycle = 10000; - return; - } - sscanf(buffer+i+1, "%hd", &cycle); - return; - } + // Decode a namecycle "aap;2" into name "aap" and cycle "2". Destination + // buffer size for name (including string terminator) should be specified in + // namesize. + + size_t len = 0; + const char *ni = strchr(buffer, ';'); + + if (ni) { + // Found ';' + len = ni - buffer; + ++ni; + } else { + // No ';' found + len = strlen(buffer); + ni = &buffer[len]; + } + + if (namesize) { + if (len > namesize-1ul) len = namesize-1; // accommodate string terminator + } else { + ::Warning("TDirectory::DecodeNameCycle", + "Using unsafe version: invoke this metod by specifying the buffer size"); } - name[nch] = 0; + + strncpy(name, buffer, len); + name[len] = '\0'; + + if (*ni == '*') + cycle = 10000; + else if (isdigit(*ni)) + cycle = atoi(ni); + else + cycle = 9999; } //______________________________________________________________________________ diff --git a/core/base/src/TEnv.cxx b/core/base/src/TEnv.cxx index 492e9cd40d4bb..0daf41ec24086 100644 --- a/core/base/src/TEnv.cxx +++ b/core/base/src/TEnv.cxx @@ -38,7 +38,7 @@ // // // E.g.: // // // -// Unix.Rint.Root.DynamicPath: .:$ROOTSYS/lib:~/lib // +// Unix.Rint.Root.DynamicPath: .:$(ROOTSYS)/lib:~/lib // // myapp.Root.Debug: FALSE // // TH.Root.Debug: YES // // *.Root.MemStat: 1 // @@ -46,6 +46,9 @@ // and or may be the wildcard "*". // // A # in the first column starts comment line. // // // +// Note that the environment variables (like $ROOTSYS) need to be // +// surrounded in parentheses in order to be expanded. // +// // // For the currently defined resources (and their default values) see // // $ROOTSYS/etc/system.rootrc. // // // diff --git a/core/base/src/TFileCollection.cxx b/core/base/src/TFileCollection.cxx index 573ba5b4cd4a2..bdea16ae5ddf4 100644 --- a/core/base/src/TFileCollection.cxx +++ b/core/base/src/TFileCollection.cxx @@ -31,6 +31,7 @@ #include "TSystem.h" #include "Riostream.h" #include "TRegexp.h" +#include "TPRegexp.h" #include "TError.h" @@ -393,13 +394,23 @@ void TFileCollection::Print(Option_t *option) const // 'L' together with 'F', print all the files in the collection // in long form (uuid, md5, all URLs, all meta objects; on // many lines) + // "filter:[SsCc]" invokes PrintDetailed() which prints out dataset + // content in a formatted fashion by filtering on files + // which are (S)taged or not (s), (C)orrupted or not (c) + + TString opt(option); + TPMERegexp re("(^|;| )filter:([SsCc]+)( |;|$)", 4); + if (re.Match(option) == 4) { + TString showOnly = re[2]; + PrintDetailed(showOnly); + return; + } Printf("TFileCollection %s - %s contains: %lld files with a size of" " %lld bytes, %.1f %% staged - default tree name: '%s'", GetName(), GetTitle(), fNFiles, fTotalSize, GetStagedPercentage(), GetDefaultTreeName()); - TString opt(option); if (opt.Contains("M", TString::kIgnoreCase)) { Printf("The files contain the following trees:"); @@ -421,6 +432,114 @@ void TFileCollection::Print(Option_t *option) const } } +//______________________________________________________________________________ +void TFileCollection::PrintDetailed(TString &showOnly) const +{ + + Bool_t bS, bs, bC, bc; + bS = bs = bC = bc = kFALSE; + + if (showOnly.Index('S') >= 0) bS = kTRUE; + if (showOnly.Index('s') >= 0) bs = kTRUE; + if (showOnly.Index('C') >= 0) bC = kTRUE; + if (showOnly.Index('c') >= 0) bc = kTRUE; + + // If Ss (or Cc) omitted, show both Ss (or Cc) + if (!bc && !bC) bc = bC = kTRUE; + if (!bs && !bS) bs = bS = kTRUE; + + TIter it(fList); + TFileInfo *info; + UInt_t countAll = 0; + UInt_t countMatch = 0; + + Printf("\033[1m #. SC | Entries | Size | URL\033[m"); + + TString um; + Double_t sz; + + while ((info = dynamic_cast(it.Next()))) { + + Bool_t s = info->TestBit(TFileInfo::kStaged); + Bool_t c = info->TestBit(TFileInfo::kCorrupted); + + TUrl *url; + + countAll++; + + if ( ((s && bS) || (!s && bs)) && ((c && bC) || (!c && bc)) ) { + + TFileInfoMeta *meta = info->GetMetaData(); // gets the first one + Int_t entries = -1; + + if (meta) entries = meta->GetEntries(); + + FormatSize(info->GetSize(), um, sz); + + // First line: current URL with all information + info->ResetUrl(); + TUrl *curUrl = info->GetCurrentUrl(); + const char *curUrlStr = curUrl ? curUrl->GetUrl() : "n.a."; + Printf("\033[1m%4u.\033[m %c%c | %-7s | %6.1lf %s | %s", + ++countMatch, + (s ? 'S' : 's'), (c ? 'C' : 'c'), + ((entries > 0) ? Form("% 7d", entries) : "n.a."), + sz, um.Data(), curUrlStr); + info->NextUrl(); + + // Every other URL shown below current one + while ((url = info->NextUrl())) { + Printf(" | | | %s", url->GetUrl()); + } + info->ResetUrl(); + + } // end match filters + + } // end loop over entries + + if (countAll) { + + Printf(">> There are \033[1m%u\033[m file(s) in dataset: " + "\033[1m%u (%5.1f%%)\033[m matched your criteria (%s)", + countAll, countMatch, + 100.*(Float_t)countMatch/(Float_t)countAll, showOnly.Data()); + + FormatSize(fTotalSize, um, sz); + Printf(">> Total size : \033[1m%.1f %s\033[m", sz, um.Data()); + Printf(">> Staged (S) : \033[1m%5.1f %%\033[m", GetStagedPercentage()); + Printf(">> Corrupted (C) : \033[1m%5.1f %%\033[m", + GetCorruptedPercentage()); + + } + else { + Printf(">> No files in dataset"); + } + + const char *treeName = GetDefaultTreeName(); + Printf(">> Default tree : \033[1m%s\033[m", + (treeName ? treeName : "(no default tree)")); + +} + +//______________________________________________________________________________ +void TFileCollection::FormatSize(Long64_t bytes, TString &um, + Double_t &size) const +{ + + static const char *ums[] = { "byt", "KiB", "MiB", "GiB", "TiB" }; + Int_t maxDiv = sizeof(ums)/sizeof(const char *); + Int_t nDiv = 0; + Double_t b = bytes; + + while ((b >= 1024.) && (nDiv+1 < maxDiv)) { + b /= 1024.; + nDiv++; + } + + um = ums[nDiv]; + size = b; +} + //______________________________________________________________________________ void TFileCollection::SetAnchor(const char *anchor) { diff --git a/core/base/src/TFileInfo.cxx b/core/base/src/TFileInfo.cxx index 68356bdd89c4a..1af469e360960 100644 --- a/core/base/src/TFileInfo.cxx +++ b/core/base/src/TFileInfo.cxx @@ -36,7 +36,8 @@ TFileInfo::TFileInfo(const char *in, Long64_t size, const char *uuid, // Constructor. // Get initializations form the input string: this will set at least the - // current URL; but it may set more: see TFileInfo::ParseInput(). + // current URL; but it may set more: see TFileInfo::ParseInput(). Please note + // that MD5 sum should be provided as a string in md5ascii form. ParseInput(in); // Now also honour the input arguments: the size @@ -51,7 +52,8 @@ TFileInfo::TFileInfo(const char *in, Long64_t size, const char *uuid, // The MD5 if (md5) { SafeDelete(fMD5); - fMD5 = new TMD5((const UChar_t*)md5); + fMD5 = new TMD5(); + fMD5->SetDigest(md5); // sets digest from md5ascii representation } // The meta information if (meta) { @@ -329,6 +331,23 @@ Bool_t TFileInfo::RemoveUrl(const char *url) return kFALSE; } +//______________________________________________________________________________ +Bool_t TFileInfo::RemoveUrlAt(Int_t i) +{ + // Remove URL at given position. Returns kTRUE on success, kFALSE on error. + + TUrl *tUrl; + if ((tUrl = dynamic_cast(fUrlList->At(i))) != NULL) { + fUrlList->Remove(tUrl); + if (tUrl == fCurrentUrl) + ResetUrl(); + delete tUrl; + return kTRUE; + } + + return kFALSE; +} + //______________________________________________________________________________ Bool_t TFileInfo::SetCurrentUrl(const char *url) { diff --git a/core/base/src/TMacro.cxx b/core/base/src/TMacro.cxx index 4541edc35c063..f9167cf4ce3a0 100644 --- a/core/base/src/TMacro.cxx +++ b/core/base/src/TMacro.cxx @@ -134,7 +134,8 @@ TMacro& TMacro::operator=(const TMacro ¯o) //______________________________________________________________________________ TObjString *TMacro::AddLine(const char *text) { - // Add line with text in the list of lines of this macro. + // Add line with text in the list of lines of this macro. Returns 0 in + // case of error, otherwise the added TObjString. if (!fLines) fLines = new TList(); TObjString *obj = new TObjString(text); @@ -241,11 +242,30 @@ Long_t TMacro::Exec(const char *params, Int_t* error) // Returns the result of the macro (return value or value of the last // expression), cast to a Long_t. + // if macro has been executed, look for global function with name + // of macro and re-execute this global function, if not found then + // macro is unnamed macro, which we re-execute from file + if (gROOT->GetListOfGlobalFunctions(kTRUE)->FindObject(GetName())) { + gROOT->SetExecutingMacro(kTRUE); + TString exec = GetName(); + TString p = params; + if (p == "") p = fParams; + if (p != "") + exec += "(" + p + ")"; + else + exec += "()"; + Long_t ret = gROOT->ProcessLine(exec, error); + //enable gROOT->Reset + gROOT->SetExecutingMacro(kFALSE); + return ret; + } + //the current implementation uses a file in the current directory. //should be replaced by a direct execution from memory by CINT TString fname = GetName(); - fname += ".Cexec"; - SaveSource(fname); + fname += ".C"; + FILE *fp = gSystem->TempFileName(fname); + SaveSource(fp); //disable a possible call to gROOT->Reset from the executed script gROOT->SetExecutingMacro(kTRUE); //execute script in /tmp @@ -343,6 +363,20 @@ void TMacro::SaveSource(const char *filename) out.close(); } +//______________________________________________________________________________ +void TMacro::SaveSource(FILE *fp) +{ + // Save macro source in file pointer fp. + + if (!fLines) {fclose(fp); return;} + TIter next(fLines); + TObjString *obj; + while ((obj = (TObjString*) next())) { + fprintf(fp, "%s\n", obj->GetName()); + } + fclose(fp); +} + //______________________________________________________________________________ void TMacro::SavePrimitive(ostream &out, Option_t *option /*= ""*/) { diff --git a/core/base/src/TPRegexp.cxx b/core/base/src/TPRegexp.cxx index 90bc9e421c3b2..4a50f8f3f501c 100644 --- a/core/base/src/TPRegexp.cxx +++ b/core/base/src/TPRegexp.cxx @@ -32,6 +32,7 @@ #include #include +#include struct PCREPriv_t { pcre *fPCRE; @@ -43,6 +44,8 @@ struct PCREPriv_t { ClassImp(TPRegexp) +Bool_t TPRegexp::fgThrowAtCompileError = kFALSE; + //______________________________________________________________________________ TPRegexp::TPRegexp() { @@ -207,8 +210,15 @@ void TPRegexp::Compile() &errstr, &patIndex, 0); if (!fPriv->fPCRE) { - Error("Compile", "compilation of TPRegexp(%s) failed at: %d because %s", - fPattern.Data(), patIndex, errstr); + if (fgThrowAtCompileError) { + throw std::runtime_error + (TString::Format("TPRegexp::Compile() compilation of TPRegexp(%s) failed at: %d because %s", + fPattern.Data(), patIndex, errstr).Data()); + } else { + Error("Compile", "compilation of TPRegexp(%s) failed at: %d because %s", + fPattern.Data(), patIndex, errstr); + return; + } } if (fPriv->fPCREExtra || (fPCREOpts & kPCRE_OPTIMIZE)) @@ -346,8 +356,8 @@ TObjArray *TPRegexp::MatchS(const TString &s, const TString &mods, Int_t start, Int_t nMaxMatch) { // Returns a TObjArray of matched substrings as TObjString's. - // The TObjArray is owner of the objects. The first entry is the full - // matched pattern, followed by the subpatterns. + // The TObjArray is owner of the objects and must be deleted by the user. + // The first entry is the full matched pattern, followed by the subpatterns. // If a pattern was not matched, it will return an empty substring: // // TObjArray *subStrL = TPRegexp("(a|(z))(bc)").MatchS("abc"); @@ -472,6 +482,33 @@ Int_t TPRegexp::Substitute(TString &s, const TString &replacePattern, } +//______________________________________________________________________________ +Bool_t TPRegexp::IsValid() const +{ + // Returns true if underlying PCRE structure has been successfully + // generated via regexp compilation. + + return fPriv->fPCRE != 0; +} + +//______________________________________________________________________________ +Bool_t TPRegexp::GetThrowAtCompileError() +{ + // Get value of static flag controlling whether exception should be thrown upon an + // error during regular expression compilation by the PCRE engine. + + return fgThrowAtCompileError; +} + +//______________________________________________________________________________ +void TPRegexp::SetThrowAtCompileError(Bool_t throwp) +{ + // Set static flag controlling whether exception should be thrown upon an + // error during regular expression compilation by the PCRE engine. + + fgThrowAtCompileError = throwp; +} + ////////////////////////////////////////////////////////////////////////// // // // TString member functions, put here so the linker will include // diff --git a/core/base/src/TProcessID.cxx b/core/base/src/TProcessID.cxx index eca42858ddaf5..bd966304fe652 100644 --- a/core/base/src/TProcessID.cxx +++ b/core/base/src/TProcessID.cxx @@ -51,6 +51,7 @@ #include "TObjArray.h" #include "TExMap.h" #include "TVirtualMutex.h" +#include "TError.h" TObjArray *TProcessID::fgPIDs = 0; //pointer to the list of TProcessID TProcessID *TProcessID::fgPID = 0; //pointer to the TProcessID of the current session @@ -93,6 +94,14 @@ TProcessID *TProcessID::AddProcessID() R__LOCKGUARD2(gROOTMutex); + if (fgPIDs && fgPIDs->GetEntriesFast() >= 65534) { + if (fgPIDs->GetEntriesFast() == 65534) { + ::Warning("TProcessID::AddProcessID","Maximum number of TProcessID (65535) is almost reached (one left). TRef will stop being functional when the limit is reached."); + } else { + ::Fatal("TProcessID::AddProcessID","Maximum number of TProcessID (65535) has been reached. TRef are not longer functional."); + } + } + TProcessID *pid = new TProcessID(); if (!fgPIDs) { @@ -104,11 +113,13 @@ TProcessID *TProcessID::AddProcessID() pid->IncrementCount(); fgPIDs->Add(pid); + // if (apid == 0) for(int incr=0; incr < 65533; ++incr) fgPIDs->Add(0); // NOTE: DEBUGGING ONLY MUST BE REMOVED! char name[20]; snprintf(name,20,"ProcessID%d",apid); pid->SetName(name); + pid->SetUniqueID((UInt_t)apid); TUUID u; - apid = fgPIDs->GetEntriesFast(); + //apid = fgPIDs->GetEntriesFast(); pid->SetTitle(u.AsString()); return pid; } @@ -128,10 +139,26 @@ UInt_t TProcessID::AssignID(TObject *obj) fgPID->PutObjectWithID(obj,uid); return uid; } + if (fgNumber >= 16777215) { + // This process id is 'full', we need to use a new one. + fgPID = AddProcessID(); + fgNumber = 0; + for(Int_t i = 0; i < fgPIDs->GetLast()+1; ++i) { + TProcessID *pid = (TProcessID*)fgPIDs->At(i); + if (pid && pid->fObjects && pid->fObjects->GetEntries() == 0) { + pid->Clear(); + } + } + } fgNumber++; obj->SetBit(kIsReferenced); uid = fgNumber; - obj->SetUniqueID(uid); + // if (fgNumber<10) fgNumber = 16777213; // NOTE: DEBUGGING ONLY MUST BE REMOVED! + if ( fgPID->GetUniqueID() < 255 ) { + obj->SetUniqueID( (uid & 0xffffff) + (fgPID->GetUniqueID()<<24) ); + } else { + obj->SetUniqueID( (uid & 0xffffff) + 0xff000000 /* 255 << 24 */ ); + } fgPID->PutObjectWithID(obj,uid); return uid; } @@ -162,6 +189,17 @@ void TProcessID::Clear(Option_t *) // delete the TObjArray pointing to referenced objects // this function is called by TFile::Close("R") + if (GetUniqueID()>254 && fObjects && fgObjPIDs) { + // We might have many references registered in the map + for(Int_t i = 0; i < fObjects->GetSize(); ++i) { + TObject *obj = fObjects->UncheckedAt(i); + if (obj) { + ULong64_t hash = Void_Hash(obj); + fgObjPIDs->Remove(hash,(Long64_t)obj); + (*fObjects)[i] = 0; + } + } + } delete fObjects; fObjects = 0; } @@ -323,7 +361,13 @@ void TProcessID::RecursiveRemove(TObject *obj) if (!fObjects) return; if (!obj->TestBit(kIsReferenced)) return; UInt_t uid = obj->GetUniqueID() & 0xffffff; - if (obj == GetObjectWithID(uid)) fObjects->RemoveAt(uid); + if (obj == GetObjectWithID(uid)) { + if (fgObjPIDs) { + ULong64_t hash = Void_Hash(obj); + fgObjPIDs->Remove(hash,(Long64_t)obj); + } + (*fObjects)[uid] = 0; // Avoid recalculation of fLast (compared to ->RemoveAt(uid)) + } } diff --git a/core/base/src/TROOT.cxx b/core/base/src/TROOT.cxx index f47c1681691c8..a3135619033c7 100644 --- a/core/base/src/TROOT.cxx +++ b/core/base/src/TROOT.cxx @@ -173,6 +173,7 @@ static Int_t ITIMQQ(const char *time) sscanf(time, "%d:%d:%d", &hh, &mm, &ss); return 100*hh + mm; } + //______________________________________________________________________________ static void CleanUpROOTAtExit() { @@ -319,7 +320,7 @@ TROOT::TROOT(const char *name, const char *title, VoidFuncPtr_t *initfunc) fBuiltDate = IDATQQ(__DATE__); fBuiltTime = ITIMQQ(__TIME__); - ReadSvnInfo(); + ReadGitInfo(); fClasses = new THashTable(800,3); //fIdMap = new IdMap_t; @@ -433,7 +434,9 @@ TROOT::TROOT(const char *name, const char *title, VoidFuncPtr_t *initfunc) gGXBatch = new TVirtualX("Batch", "ROOT Interface to batch graphics"); gVirtualX = gGXBatch; -#ifdef R__WIN32 +#if defined(R__WIN32) + fBatch = kFALSE; +#elif defined(R__HAS_COCOA) fBatch = kFALSE; #else if (gSystem->Getenv("DISPLAY")) @@ -463,9 +466,9 @@ TROOT::TROOT(const char *name, const char *title, VoidFuncPtr_t *initfunc) atexit(CleanUpROOTAtExit); - fgRootInit = kTRUE; - TClass::ReadRules(); // Read the default customization rules ... + + fgRootInit = kTRUE; } //______________________________________________________________________________ @@ -508,10 +511,13 @@ TROOT::~TROOT() SafeDelete(fClosedObjects); fFunctions->Delete(); SafeDelete(fFunctions); // etc.. - fColors->Delete(); SafeDelete(fColors); - fStyles->Delete(); SafeDelete(fStyles); fGeometries->Delete(); SafeDelete(fGeometries); fBrowsers->Delete(); SafeDelete(fBrowsers); +#ifdef R__COMPLETE_MEM_TERMINATION + SafeDelete(fCanvases); +#endif + fColors->Delete(); SafeDelete(fColors); + fStyles->Delete(); SafeDelete(fStyles); #ifdef R__COMPLETE_MEM_TERMINATION if (gGuiFactory != gBatchGuiFactory) SafeDelete(gGuiFactory); @@ -725,8 +731,32 @@ void TROOT::CloseFiles() if (fMappedFiles && fMappedFiles->First()) { R__ListSlowClose(static_cast(fMappedFiles)); } + } +//______________________________________________________________________________ +void TROOT::EndOfProcessCleanups() +{ + // Execute the cleanups necessary at the end of the process, in particular + // those that must be executed before the library start being unloaded. + + CloseFiles(); + + if (gInterpreter) { + gInterpreter->ResetGlobals(); + } + + // Now a set of simpler things to delete. See the same ordering in + // TROOT::~TROOT + fFunctions->Delete(); + fGeometries->Delete(); + fBrowsers->Delete(); + fCanvases->Delete(); + fColors->Delete(); + fStyles->Delete(); +} + + //______________________________________________________________________________ TObject *TROOT::FindObject(const TObject *) const { @@ -1736,23 +1766,26 @@ Long_t TROOT::ProcessLineFast(const char *line, Int_t *error) } //______________________________________________________________________________ -void TROOT::ReadSvnInfo() +void TROOT::ReadGitInfo() { - // Read Subversion revision information and branch name from the - // etc/svnrev.txt file. + // Read Git commit information and branch name from the + // etc/gitinfo.txt file. fSvnRevision = 0; #ifdef ROOT_SVN_REVISION fSvnRevision = ROOT_SVN_REVISION; #endif -#ifdef ROOT_SVN_BRANCH - fSvnBranch = ROOT_SVN_BRANCH; +#ifdef ROOT_GIT_COMMIT + fGitCommit = ROOT_GIT_COMMIT; +#endif +#ifdef ROOT_GIT_BRANCH + fGitBranch = ROOT_GIT_BRANCH; #endif - TString svninfo = "svninfo.txt"; + TString gitinfo = "gitinfo.txt"; char *filename = 0; #ifdef ROOTETCDIR - filename = gSystem->ConcatFileName(ROOTETCDIR, svninfo); + filename = gSystem->ConcatFileName(ROOTETCDIR, gitinfo); #else TString etc = gRootDir; #ifdef WIN32 @@ -1761,10 +1794,10 @@ void TROOT::ReadSvnInfo() etc += "/etc"; #endif #if defined(R__MACOSX) && (TARGET_OS_IPHONE || TARGET_IPHONE_SIMULATOR) - // on iOS etc does not exist and svninfo resides in $ROOTSYS + // on iOS etc does not exist and gitinfo resides in $ROOTSYS etc = gRootDir; #endif - filename = gSystem->ConcatFileName(etc, svninfo); + filename = gSystem->ConcatFileName(etc, gitinfo); #endif FILE *fp = fopen(filename, "r"); @@ -1772,29 +1805,27 @@ void TROOT::ReadSvnInfo() TString s; // read branch name s.Gets(fp); - fSvnBranch = s; - // read revision number + fGitBranch = s; + // read commit SHA1 s.Gets(fp); - Int_t r = s.Atoi(); - if (r > 0) - fSvnRevision = r; + fGitCommit = s; // read date/time make was run s.Gets(fp); - fSvnDate = s; + fGitDate = s; fclose(fp); } delete [] filename; } //______________________________________________________________________________ -const char *TROOT::GetSvnDate() +const char *TROOT::GetGitDate() { // Return date/time make was run. - if (fSvnDate == "") { + if (fGitDate == "") { Int_t iday,imonth,iyear, ihour, imin; static const char *months[] = { "Jan", "Feb", "Mar", "Apr", "May", "Jun", - "Jul", "Aug", "Sep", "Oct", "Nov", "De" }; + "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" }; Int_t idate = gROOT->GetBuiltDate(); Int_t itime = gROOT->GetBuiltTime(); iday = idate%100; @@ -1802,9 +1833,9 @@ const char *TROOT::GetSvnDate() iyear = idate/10000; ihour = itime/100; imin = itime%100; - fSvnDate.Form("%s %02d %4d, %02d:%02d:00", months[imonth-1], iday, iyear, ihour, imin); + fGitDate.Form("%s %02d %4d, %02d:%02d:00", months[imonth-1], iday, iyear, ihour, imin); } - return fSvnDate; + return fGitDate; } //______________________________________________________________________________ @@ -1822,6 +1853,77 @@ void TROOT::RefreshBrowsers() b->SetRefreshFlag(kTRUE); } + +//______________________________________________________________________________ +namespace ROOT { + static void CallCloseFiles() + { + // Insure that the files, canvases and sockets are closed. + + if (gROOT) gROOT->CloseFiles(); + } + + void RegisterModule() + { + // Register for each loaded dictionary (and thus for each + // library), that we need to Close the ROOT files as soon as + // this library might start being unloaded after main. + // + // By calling atexit here (rather than directly from within the + // library) we make sure that this is not called if the library + // is 'only' dlclosed. + + // On Ubuntu the linker strips the unused libraries. Eventhough + // stressHistogram is explicitly linked against libNet, it is + // not retained and thus is loaded only as needed in the middle + // part of the execution. Concretely this also means that it is + // loaded *after* the construction of the TApplication object + // and thus after the registration (atexit) of the + // EndOfProcessCleanups routine. Consequently, after the end of + // main, libNet is unloaded before EndOfProcessCleanups is + // called. When EndOfProcessCleanups is executed it indirectly + // needs the TClass for TSocket and its search will use + // resources that have already been unloaded (technically the + // function static in TUnixSystem's DynamicPath and the + // dictionary from libNet). + + // Similarly, the ordering (before this commit) was broken in + // the following case: + + // TApplication creation (EndOfProcessCleanups registration) + // load UserLibrary + // create TFile + // Append UserObject to TFile + + // and after the end of main the order of execution was + + // unload UserLibrary + // call EndOfProcessCleanups + // Write the TFile + // attempt to write the user object. + // .... + + // where what we need is to have the files closen/written before + // the unloading of the library. + + // To solve the problem we now register an atexit function for + // every dictionary thus making sure there is at least one + // executed before the first library tear down after main. + + // If atexit is called directly within a library's code, the + // function will called *either* when the library is 'dlclose'd + // or after then end of main (whichever comes first). We do + // *not* want the files to be closed whenever a library is + // unloaded via dlclose. To avoid this, we add the function + // (CallCloseFiles) from the dictionary indirectly (via + // ROOT::RegisterModule). In this case the function will only + // only be called either when libCore is 'dlclose'd or right + // after the end of main. + + atexit(CallCloseFiles); + } +} + //______________________________________________________________________________ void TROOT::RemoveClass(TClass *oldcl) { diff --git a/core/base/src/TRef.cxx b/core/base/src/TRef.cxx index 96407cea255ba..4ff17a96cf547 100644 --- a/core/base/src/TRef.cxx +++ b/core/base/src/TRef.cxx @@ -60,10 +60,13 @@ // in addition to the TObject part of TRef (fBits,fUniqueID). // When the TRef is read, its pointer fPID is set to the value // stored in the TObjArray of TFile::fProcessIDs (fProcessIDs[pidf]). +// The pidf is stored as a UShort_t limiting a file to 65535 distinct +// ProcessID objects. // The pidf is stored in the bits 24->31 of the fUniqueID of the TRef. -// This implies that the number of TRefs in one process should not -// exceed 2**23 = 8388608 and that the number of processes (different jobs) -// writing TRefs to one file should be less than 256. +// This implies that the number of TRefs in a single ProcessID should not +// exceed 2**24 = 16777216. For pidf greater than 254, the value 0xff is +// stored in those bits and we use the table TProcessID::fgObjPIDs which +// links the referenced object's address to its ProcessID. // See section "ObjectNumber" below for a recipee to minimize the object count. // If the objectnumber exceeds this limit, it could be the sign that: // -The object count is never reset (see below) @@ -253,11 +256,10 @@ void TRef::operator=(TObject *obj) } else { if (obj->TestBit(kIsReferenced)) { uid = obj->GetUniqueID(); - fPID = TProcessID::GetProcessWithUID(uid,obj); } else { - fPID = TProcessID::GetSessionProcessID(); uid = TProcessID::AssignID(obj); } + fPID = TProcessID::GetProcessWithUID(uid,obj); ResetBit(kHasUUID); } } diff --git a/core/base/src/TRemoteObject.cxx b/core/base/src/TRemoteObject.cxx index 786eea9fb4f01..114da50e0dae5 100755 --- a/core/base/src/TRemoteObject.cxx +++ b/core/base/src/TRemoteObject.cxx @@ -15,7 +15,7 @@ // // // The TRemoteObject class provides protocol for browsing ROOT objects // // from a remote ROOT session. // -// It contains informations on the real remote object as: // +// It contains information on the real remote object as: // // - Object Properties (i.e. file stat if the object is a TSystemFile) // // - Object Name // // - Class Name // diff --git a/core/base/src/TStorage.cxx b/core/base/src/TStorage.cxx index fface3a184cc4..4ea50e5179773 100644 --- a/core/base/src/TStorage.cxx +++ b/core/base/src/TStorage.cxx @@ -177,11 +177,15 @@ void TStorage::Dealloc(void *ptr) //______________________________________________________________________________ void *TStorage::ReAlloc(void *ovp, size_t size) { - // Reallocate (i.e. resize) block of memory. + // Reallocate (i.e. resize) block of memory. Don't use if size is larger + // than old size, use ReAlloc(void *, size_t, size_t) instead. // Needs to be protected by global mutex R__LOCKGUARD(gGlobalMutex); + ::Obsolete("ReAlloc(void*,size_t)", "v5-34-00", "v6-02-00"); + ::Info("ReAlloc(void*,size_t)", "please use ReAlloc(void*,size_t,size_t)"); + if (fgReAllocHook && fgHasCustomNewDelete && !TROOT::MemCheck()) return (*fgReAllocHook)(ovp, size); diff --git a/core/base/src/TString.cxx b/core/base/src/TString.cxx index b1010e2d95317..61bbe76814bb2 100644 --- a/core/base/src/TString.cxx +++ b/core/base/src/TString.cxx @@ -1939,7 +1939,7 @@ Bool_t TString::IsInBaseN(Int_t base) const // string contains other characters. if (base < 2 || base > 36) { - Error("TString::IsInBaseN", "base %d is not supported. Suppported bases are {2,3,...,36}.", base); + Error("TString::IsInBaseN", "base %d is not supported. Supported bases are {2,3,...,36}.", base); return kFALSE; } if (Length() == 0) { @@ -2072,7 +2072,7 @@ TString TString::Itoa(Int_t value, Int_t base) std::string buf; // check that the base if valid if (base < 2 || base > 36) { - Error("TString::Itoa", "base %d is not supported. Suppported bases are {2,3,...,36}.",base) ; + Error("TString::Itoa", "base %d is not supported. Supported bases are {2,3,...,36}.",base) ; return (TString("!")); } buf.reserve(35); // Pre-allocate enough space (35=kMaxDigits) @@ -2099,7 +2099,7 @@ TString TString::UItoa(UInt_t value, Int_t base) std::string buf; // check that the base if valid if (base < 2 || base > 36) { - Error("TString::UItoa", "base %d is not supported. Suppported bases are {2,3,...,36}.",base); + Error("TString::UItoa", "base %d is not supported. Supported bases are {2,3,...,36}.",base); return (TString("!")); } buf.reserve(35); // Pre-allocate enough space (35=kMaxDigits) @@ -2124,7 +2124,7 @@ TString TString::LLtoa(Long64_t value, Int_t base) std::string buf; // check that the base if valid if (base < 2 || base > 36) { - Error("TString::LLtoa", "base %d is not supported. Suppported bases are {2,3,...,36}.",base); + Error("TString::LLtoa", "base %d is not supported. Supported bases are {2,3,...,36}.",base); return (TString("!")); } buf.reserve(35); // Pre-allocate enough space (35=kMaxDigits) @@ -2151,7 +2151,7 @@ TString TString::ULLtoa(ULong64_t value, Int_t base) std::string buf; // check that the base if valid if (base < 2 || base > 36) { - Error("TString::ULLtoa", "base %d is not supported. Suppported bases are {2,3,...,36}.",base); + Error("TString::ULLtoa", "base %d is not supported. Supported bases are {2,3,...,36}.",base); return (TString("!")); } buf.reserve(35); // Pre-allocate enough space (35=kMaxDigits) diff --git a/core/base/src/TStyle.cxx b/core/base/src/TStyle.cxx index 07c0ff4f70f15..e43d0c075e03a 100644 --- a/core/base/src/TStyle.cxx +++ b/core/base/src/TStyle.cxx @@ -696,19 +696,6 @@ void TStyle::Reset(Option_t *opt) } -//______________________________________________________________________________ -Int_t TStyle::AxisChoice( Option_t *axis) const -{ - // Return axis number. - - char achoice = toupper(axis[0]); - if (achoice == 'X') return 1; - if (achoice == 'Y') return 2; - if (achoice == 'Z') return 3; - return 0; -} - - //______________________________________________________________________________ Int_t TStyle::GetNdivisions( Option_t *axis) const { @@ -1263,6 +1250,7 @@ void TStyle::SetOptStat(Int_t mode) // s = 1; skewness printed // s = 2; skewness and skewness error printed // i = 1; integral of bins printed + // i = 2; integral of bins with option "width" printed // o = 1; number of overflows printed // u = 1; number of underflows printed // r = 1; rms printed @@ -1305,6 +1293,7 @@ void TStyle::SetOptStat(Option_t *stat) // s : skewness printed // S : skewness and skewness error printed // i : integral of bins printed + // I : integral of bins with option "width" printed // o : number of overflows printed // u : number of underflows printed // r : rms printed @@ -1331,6 +1320,7 @@ void TStyle::SetOptStat(Option_t *stat) if (opt.Contains("u")) mode+=10000; if (opt.Contains("o")) mode+=100000; if (opt.Contains("i")) mode+=1000000; + if (opt.Contains("I")) mode+=2000000; if (opt.Contains("s")) mode+=10000000; if (opt.Contains("S")) mode+=20000000; if (opt.Contains("k")) mode+=100000000; @@ -1473,11 +1463,11 @@ void TStyle::SetTitleSize(Float_t size, Option_t *axis) //______________________________________________________________________________ -void TStyle::SetPalette(Int_t ncolors, Int_t *colors) +void TStyle::SetPalette(Int_t ncolors, Int_t *colors, Float_t alpha) { // See TColor::SetPalette. - TColor::SetPalette(ncolors,colors); + TColor::SetPalette(ncolors,colors,alpha); } @@ -1535,8 +1525,8 @@ void TStyle::SaveSource(const char *filename, Option_t *option) sname[i] = 0; // Tries to open the file. - ofstream out; - out.open(ff.Data(), ios::out); + std::ofstream out; + out.open(ff.Data(), std::ios::out); if (!out.good()) { delete [] sname; Error("SaveSource", "cannot open file: %s", ff.Data()); @@ -1545,28 +1535,28 @@ void TStyle::SaveSource(const char *filename, Option_t *option) // Writes macro header, date/time stamp as string, and the used Root version TDatime t; - out <<"// Mainframe macro generated from application: " << gApplication->Argv(0) << endl; - out <<"// By ROOT version " << gROOT->GetVersion() << " on " << t.AsSQLString() << endl; - out << endl; + out <<"// Mainframe macro generated from application: " << gApplication->Argv(0) << std::endl; + out <<"// By ROOT version " << gROOT->GetVersion() << " on " << t.AsSQLString() << std::endl; + out << std::endl; char quote = '"'; // Writes include. - out << "#if !defined( __CINT__) || defined (__MAKECINT__)" << endl << endl; - out << "#ifndef ROOT_TStyle" << endl; - out << "#include " << quote << "TStyle.h" << quote << endl; - out << "#endif" << endl; - out << endl << "#endif" << endl; + out << "#if !defined( __CINT__) || defined (__MAKECINT__)" << std::endl << std::endl; + out << "#ifndef ROOT_TStyle" << std::endl; + out << "#include " << quote << "TStyle.h" << quote << std::endl; + out << "#endif" << std::endl; + out << std::endl << "#endif" << std::endl; // Writes the macro entry point equal to the fname - out << endl; - out << "void " << sname << "()" << endl; - out << "{" << endl; + out << std::endl; + out << "void " << sname << "()" << std::endl; + out << "{" << std::endl; delete [] sname; TStyle::SavePrimitive(out, option); - out << "}" << endl; + out << "}" << std::endl; out.close(); printf(" C++ macro file %s has been generated\n", gSystem->BaseName(ff)); @@ -1574,217 +1564,217 @@ void TStyle::SaveSource(const char *filename, Option_t *option) //______________________________________________________________________________ -void TStyle::SavePrimitive(ostream &out, Option_t * /*= ""*/) +void TStyle::SavePrimitive(std::ostream &out, Option_t * /*= ""*/) { // Save a main frame widget as a C++ statement(s) on output stream out. char quote = '"'; - out << " // Add the saved style to the current ROOT session." << endl; - out << endl; - out<<" "<<"delete gROOT->GetStyle("<GetStyle("<SetNdivisions(" <SetNdivisions(" <SetNdivisions(" <SetAxisColor(" <SetAxisColor(" <SetAxisColor(" <SetLabelColor(" <SetLabelColor(" <SetLabelColor(" <SetLabelFont(" <SetLabelFont(" <SetLabelFont(" <SetLabelOffset("<SetLabelOffset("<SetLabelOffset("<SetLabelSize(" <SetLabelSize(" <SetLabelSize(" <SetTickLength(" <SetTickLength(" <SetTickLength(" <SetTitleOffset("<SetTitleOffset("<SetTitleOffset("<SetTitleSize(" <SetTitleSize(" <SetTitleSize(" <SetTitleColor(" <SetTitleColor(" <SetTitleColor(" <SetTitleFont(" <SetTitleFont(" <SetTitleFont(" <SetBarWidth(" <SetBarOffset(" <SetDrawBorder(" <SetOptLogx(" <SetOptLogy(" <SetOptLogz(" <SetOptDate(" <SetOptStat(" <SetOptTitle(kTRUE);" << endl; - else out << " tmpStyle->SetOptTitle(kFALSE);" << endl; - out<<" "<<"tmpStyle->SetOptFit(" <SetNumberContours(" <SetNdivisions(" <SetNdivisions(" <SetNdivisions(" <SetAxisColor(" <SetAxisColor(" <SetAxisColor(" <SetLabelColor(" <SetLabelColor(" <SetLabelColor(" <SetLabelFont(" <SetLabelFont(" <SetLabelFont(" <SetLabelOffset("<SetLabelOffset("<SetLabelOffset("<SetLabelSize(" <SetLabelSize(" <SetLabelSize(" <SetTickLength(" <SetTickLength(" <SetTickLength(" <SetTitleOffset("<SetTitleOffset("<SetTitleOffset("<SetTitleSize(" <SetTitleSize(" <SetTitleSize(" <SetTitleColor(" <SetTitleColor(" <SetTitleColor(" <SetTitleFont(" <SetTitleFont(" <SetTitleFont(" <SetBarWidth(" <SetBarOffset(" <SetDrawBorder(" <SetOptLogx(" <SetOptLogy(" <SetOptLogz(" <SetOptDate(" <SetOptStat(" <SetOptTitle(kTRUE);" << std::endl; + else out << " tmpStyle->SetOptTitle(kFALSE);" << std::endl; + out<<" "<<"tmpStyle->SetOptFit(" <SetNumberContours(" <GetAttDate()->SetTextFont(" <GetTextFont() <<");"<GetAttDate()->SetTextSize(" <GetTextSize() <<");"<GetAttDate()->SetTextAngle("<GetTextAngle()<<");"<GetAttDate()->SetTextAlign("<GetTextAlign()<<");"<GetAttDate()->SetTextColor("<GetTextColor()<<");"<SetDateX(" <SetDateY(" <SetEndErrorSize(" <SetErrorX(" <SetFuncColor(" <SetFuncStyle(" <SetFuncWidth(" <SetGridColor(" <SetGridStyle(" <SetGridWidth(" <SetLegendBorderSize("<SetLegendFillColor(" <SetLegendFont(" <SetHatchesLineWidth("<SetHatchesSpacing(" <SetFrameFillColor(" <SetFrameLineColor(" <SetFrameFillStyle(" <SetFrameLineStyle(" <SetFrameLineWidth(" <SetFrameBorderSize(" <SetFrameBorderMode(" <SetHistFillColor(" <SetHistLineColor(" <SetHistFillStyle(" <SetHistLineStyle(" <SetHistLineWidth(" <SetHistMinimumZero(kTRUE);" <SetHistMinimumZero(kFALSE);"<SetCanvasPreferGL(kTRUE);" <SetCanvasPreferGL(kFALSE);"<SetCanvasColor(" <SetCanvasBorderSize("<SetCanvasBorderMode("<SetCanvasDefH(" <SetCanvasDefW(" <SetCanvasDefX(" <SetCanvasDefY(" <SetPadColor(" <SetPadBorderSize(" <SetPadBorderMode(" <SetPadBottomMargin(" <SetPadTopMargin(" <SetPadLeftMargin(" <SetPadRightMargin(" <SetPadGridX(kTRUE);" <SetPadGridX(kFALSE);"<SetPadGridY(kTRUE);" <SetPadGridY(kFALSE);"<SetPadTickX(" <SetPadTickY(" <GetAttDate()->SetTextFont(" <GetTextFont() <<");"<GetAttDate()->SetTextSize(" <GetTextSize() <<");"<GetAttDate()->SetTextAngle("<GetTextAngle()<<");"<GetAttDate()->SetTextAlign("<GetTextAlign()<<");"<GetAttDate()->SetTextColor("<GetTextColor()<<");"<SetDateX(" <SetDateY(" <SetEndErrorSize(" <SetErrorX(" <SetFuncColor(" <SetFuncStyle(" <SetFuncWidth(" <SetGridColor(" <SetGridStyle(" <SetGridWidth(" <SetLegendBorderSize("<SetLegendFillColor(" <SetLegendFont(" <SetHatchesLineWidth("<SetHatchesSpacing(" <SetFrameFillColor(" <SetFrameLineColor(" <SetFrameFillStyle(" <SetFrameLineStyle(" <SetFrameLineWidth(" <SetFrameBorderSize(" <SetFrameBorderMode(" <SetHistFillColor(" <SetHistLineColor(" <SetHistFillStyle(" <SetHistLineStyle(" <SetHistLineWidth(" <SetHistMinimumZero(kTRUE);" <SetHistMinimumZero(kFALSE);"<SetCanvasPreferGL(kTRUE);" <SetCanvasPreferGL(kFALSE);"<SetCanvasColor(" <SetCanvasBorderSize("<SetCanvasBorderMode("<SetCanvasDefH(" <SetCanvasDefW(" <SetCanvasDefX(" <SetCanvasDefY(" <SetPadColor(" <SetPadBorderSize(" <SetPadBorderMode(" <SetPadBottomMargin(" <SetPadTopMargin(" <SetPadLeftMargin(" <SetPadRightMargin(" <SetPadGridX(kTRUE);" <SetPadGridX(kFALSE);"<SetPadGridY(kTRUE);" <SetPadGridY(kFALSE);"<SetPadTickX(" <SetPadTickY(" <SetPaperSize(" <SetScreenFactor(" <SetStatColor(" <SetStatTextColor(" <SetStatBorderSize(" <SetStatFont(" <SetStatFontSize(" <SetStatStyle(" <SetScreenFactor(" <SetStatColor(" <SetStatTextColor(" <SetStatBorderSize(" <SetStatFont(" <SetStatFontSize(" <SetStatStyle(" <SetStatFormat(" <SetStatX(" <SetStatY(" <SetStatW(" <SetStatH(" <SetStripDecimals(kTRUE);" <SetStripDecimals(kFALSE);"<SetTitleAlign(" <SetTitleFillColor(" <SetTitleTextColor(" <SetTitleBorderSize("<SetTitleFont(" <SetTitleFontSize(" <SetTitleStyle(" <SetTitleX(" <SetTitleY(" <SetTitleW(" <SetTitleH(" <SetLegoInnerR(" <SetStatX(" <SetStatY(" <SetStatW(" <SetStatH(" <SetStripDecimals(kTRUE);" <SetStripDecimals(kFALSE);"<SetTitleAlign(" <SetTitleFillColor(" <SetTitleTextColor(" <SetTitleBorderSize("<SetTitleFont(" <SetTitleFontSize(" <SetTitleStyle(" <SetTitleX(" <SetTitleY(" <SetTitleW(" <SetTitleH(" <SetLegoInnerR(" <SetPalette(" << GetNumberOfColors() - << ", fPaletteColor);" << endl; - out<SetLineStyleString(i, fLineStyleArrayTmp[i]);"<SetLineStyleString(i, fLineStyleArrayTmp[i]);"<SetHeaderPS(" <SetTitlePS(" <SetFitFormat(" <SetPaintTextFormat("<SetLineScalePS(" <SetColorModelPS(" <SetTimeOffset(%9.0f);", GetTimeOffset()) <SetLineScalePS(" <SetColorModelPS(" <SetTimeOffset(%9.0f);", GetTimeOffset()) <SetLineColor(" <SetLineStyle(" <SetLineWidth(" <SetLineColor(" <SetLineStyle(" <SetLineWidth(" <SetFillColor(" <SetFillStyle(" <SetFillColor(" <SetFillStyle(" <SetMarkerColor(" <SetMarkerSize(" <SetMarkerStyle(" <SetMarkerColor(" <SetMarkerSize(" <SetMarkerStyle(" <SetTextAlign(" <SetTextAngle(" <SetTextColor(" <SetTextFont(" <SetTextSize(" <SetTextAlign(" <SetTextAngle(" <SetTextColor(" <SetTextFont(" <SetTextSize(" <buf' is a strict comparison to allows '/topdir' to return '/' while ( r>buf && *(r)=='/') { --r; } + // If all was cut away, we encountered a rel. path like 'subdir/' + // and ended up at '.'. + if (r==buf && *(r)!='/') { + return "."; + } // And finally terminate the string to drop off the filename *(r+1) = '\0'; @@ -3181,7 +3186,7 @@ int TSystem::CompileMacro(const char *filename, Option_t *opt, ::Warning("ACLiC","Could not create the directory: %s", build_loc.Data()); } else { - ::Warning("ACLiC","%s is not writeable!", + ::Warning("ACLiC","%s is not writable!", build_loc.Data()); } if (emergency_loc == build_dir ) { diff --git a/core/base/src/TTimeStamp.cxx b/core/base/src/TTimeStamp.cxx index c56d29cbdc3e7..5a07b2fa419c7 100644 --- a/core/base/src/TTimeStamp.cxx +++ b/core/base/src/TTimeStamp.cxx @@ -411,7 +411,18 @@ Int_t TTimeStamp::GetZoneOffset() #if defined(R__WINGCC) return _timezone; #else +#if !defined(R__FBSD) && !defined(R__OBSD) return timezone; // unix has extern long int +#else + time_t tp = 0; + time(&tp); +#ifdef _REENTRANT + struct tm buf; + return -localtime_r(&tp, &buf)->tm_gmtoff; +#else + return -localtime(&tp)->tm_gmtoff; +#endif +#endif #endif #else _tzset(); diff --git a/core/base/src/TTimer.cxx b/core/base/src/TTimer.cxx index 0264d66bfe4c7..e878a351e0aaa 100644 --- a/core/base/src/TTimer.cxx +++ b/core/base/src/TTimer.cxx @@ -138,7 +138,8 @@ Bool_t TTimer::CheckTimer(const TTime &now) Bool_t TTimer::Notify() { // Notify when timer times out. The timer is always reset. To stop - // the timer call TurnOff(). + // the timer call TurnOff(). Make sure to call Reset() also in derived + // Notify() so timers will keep working repeatedly. Timeout(); // emit Timeout() signal if (fObject) fObject->HandleTimer(this); diff --git a/core/base/src/TUrl.cxx b/core/base/src/TUrl.cxx index 906804c538b5f..a94734bd8505d 100644 --- a/core/base/src/TUrl.cxx +++ b/core/base/src/TUrl.cxx @@ -126,6 +126,8 @@ void TUrl::SetUrl(const char *url, Bool_t defaultIsFile) fFile = ""; fAnchor = ""; fOptions = ""; + fFileOA = ""; + fHostFQ = ""; // if url starts with a / consider it as a file url if (url[0] == '/') @@ -334,7 +336,7 @@ void TUrl::FindFile(char *u, Bool_t stripDoubleSlash) //______________________________________________________________________________ TUrl::TUrl(const TUrl &url) : TObject(url) { - // TUrl copt ctor. + // TUrl copy ctor. fUrl = url.fUrl; fProtocol = url.fProtocol; diff --git a/core/base/src/TVirtualPS.cxx b/core/base/src/TVirtualPS.cxx index 7c19465836017..46d0b604620d5 100644 --- a/core/base/src/TVirtualPS.cxx +++ b/core/base/src/TVirtualPS.cxx @@ -15,6 +15,9 @@ // #include "Riostream.h" +#include "Byteswap.h" +#include "TError.h" +#include "TClonesArray.h" #include "TVirtualPS.h" TVirtualPS *gVirtualPS = 0; @@ -106,7 +109,7 @@ void TVirtualPS::PrintFast(Int_t len, const char *str) if (fLenBuffer > 0) nWrite = fLenBuffer; } else { if ((len + fLenBuffer) > nWrite) { - // Search for the nearest preceeding space to break a line, if there is no instruction to escape the . + // Search for the nearest preceding space to break a line, if there is no instruction to escape the . while ((nWrite >= fLenBuffer) && (str[nWrite - fLenBuffer] != ' ')) nWrite--; if (nWrite < fLenBuffer) { while ((nWrite >= 0) && (fBuffer[nWrite] != ' ')) nWrite--; @@ -177,11 +180,38 @@ void TVirtualPS::WriteInteger(Int_t n, Bool_t space ) //______________________________________________________________________________ -void TVirtualPS::WriteReal(Float_t z) +void TVirtualPS::WriteReal(Float_t z, Bool_t space) { // Write a Real number to the file char str[15]; - snprintf(str,15," %g", z); + if (space) { + snprintf(str,15," %g", z); + } else { + snprintf(str,15,"%g", z); + } PrintStr(str); } + + +//______________________________________________________________________________ +void TVirtualPS::PrintRaw(Int_t len, const char *str) +{ + // Print a raw + + fNByte += len; + if ((len + fLenBuffer) > kMaxBuffer - 1) { + fStream->write(fBuffer, fLenBuffer); + while(len > kMaxBuffer-1) { + fStream->write(str,kMaxBuffer); + len -= kMaxBuffer; + str += kMaxBuffer; + } + memcpy(fBuffer, str, len); + fLenBuffer = len; + } else { + memcpy(fBuffer + fLenBuffer, str, len); + fLenBuffer += len; + } + fPrinted = kTRUE; +} diff --git a/core/base/src/TVirtualX.cxx b/core/base/src/TVirtualX.cxx index 254aa10a47383..01d818594686b 100644 --- a/core/base/src/TVirtualX.cxx +++ b/core/base/src/TVirtualX.cxx @@ -188,6 +188,14 @@ void TVirtualX::CopyPixmap(Int_t /*wid*/, Int_t /*xpos*/, Int_t /*ypos*/) // Copies the pixmap "wid" at the position [xpos,ypos] in the current window. } +//______________________________________________________________________________ +Double_t TVirtualX::GetOpenGLScalingFactor() +{ + //On a HiDPI resolution it can be > 1., this means glViewport should use + //scaled width and height. + return 1.; +} + //______________________________________________________________________________ void TVirtualX::CreateOpenGLContext(Int_t /*wid*/) { @@ -200,6 +208,40 @@ void TVirtualX::DeleteOpenGLContext(Int_t /*wid*/) // Deletes OpenGL context for window "wid" } +//______________________________________________________________________________ +Window_t TVirtualX::CreateOpenGLWindow(Window_t /*parentID*/, UInt_t /*width*/, UInt_t /*height*/, const std::vector > &/*format*/) +{ + //Create window with special pixel format. Noop everywhere except Cocoa. + return Window_t(); +} + +//______________________________________________________________________________ +Handle_t TVirtualX::CreateOpenGLContext(Window_t /*windowID*/, Handle_t /*shareWith*/) +{ + // Creates OpenGL context for window "windowID". + return Handle_t(); +} + +//______________________________________________________________________________ +Bool_t TVirtualX::MakeOpenGLContextCurrent(Handle_t /*ctx*/, Window_t /*windowID*/) +{ + // Makes context ctx current OpenGL context. + return kFALSE; +} + +//______________________________________________________________________________ +Handle_t TVirtualX::GetCurrentOpenGLContext() +{ + // Asks OpenGL subsystem about the current OpenGL context. + return Handle_t(); +} + +//______________________________________________________________________________ +void TVirtualX::FlushOpenGLBuffer(Handle_t /*ctx*/) +{ + // Flushes OpenGL buffer. +} + //______________________________________________________________________________ void TVirtualX::DrawBox(Int_t /*x1*/, Int_t /*y1*/, Int_t /*x2*/, Int_t /*y2*/, EBoxMode /*mode*/) @@ -281,6 +323,23 @@ void TVirtualX::DrawText(Int_t /*x*/, Int_t /*y*/, Float_t /*angle*/, } +//______________________________________________________________________________ +void TVirtualX::DrawText(Int_t /*x*/, Int_t /*y*/, Float_t /*angle*/, + Float_t /*mgn*/, const wchar_t * /*text*/, + ETextMode /*mode*/) +{ + // Draws a text string using current font. + // + // x,y - text position + // angle - text angle + // mgn - magnification factor + // text - text string + // mode - drawing mode: + // mode = 0 the background is not drawn (kClear) + // mode = 1 the background is drawn (kOpaque) + +} + //______________________________________________________________________________ UInt_t TVirtualX::ExecCommand(TGWin32Command * /*code*/) { @@ -372,6 +431,17 @@ void TVirtualX::GetTextExtent(UInt_t &w, UInt_t &h, char * /*mess*/) w = h = 0; } //______________________________________________________________________________ +void TVirtualX::GetTextExtent(UInt_t &w, UInt_t &h, wchar_t * /*mess*/) +{ + // Returns the size of the specified character string "mess". + // + // w - the text width + // h - the text height + // mess - the string + + w = h = 0; +} +//______________________________________________________________________________ Int_t TVirtualX::GetFontAscent() const { // Returns the ascent of the current font (in pixels). @@ -1589,7 +1659,7 @@ void TVirtualX::DrawString(Drawable_t /*id*/, GContext_t /*gc*/, Int_t /*x*/, Int_t TVirtualX::TextWidth(FontStruct_t /*font*/, const char * /*s*/, Int_t /*len*/) { - // Return lenght of the string "s" in pixels. Size depends on font. + // Return length of the string "s" in pixels. Size depends on font. return 5; } diff --git a/core/base/src/precompile.cxx b/core/base/src/precompile.cxx deleted file mode 100644 index e69de29bb2d1d..0000000000000 diff --git a/core/clib/inc/mmalloc.h b/core/clib/inc/mmalloc.h index ab8eeb15bd404..7a1b32445f528 100644 --- a/core/clib/inc/mmalloc.h +++ b/core/clib/inc/mmalloc.h @@ -30,7 +30,6 @@ #define PARAMS(paramlist) paramlist #ifdef WIN32 - /* problem with VC++ 6.0 if extern "C". It does not like the return type */ extern struct mstats mmstats PARAMS ((PTR)); #endif @@ -67,10 +66,19 @@ extern PTR mvalloc PARAMS ((PTR, size_t)); extern int mmcheck PARAMS ((PTR, void (*) (void))); -/* Pick up the current statistics. (see FIXME elsewhere) */ -#ifndef WIN32 - extern struct mstats mmstats PARAMS ((PTR)); -#endif +/* Pick up the current statistics is no longer supported via mmstats. (see FIXME elsewhere) */ +/* This cause a problem with VC++ (warning C4190) if extern "C" and with clang: +include/mmalloc.h:73:25: warning: 'mmstats' has C-linkage specified, but returns user-defined type 'struct mstats' which is incompatible with C [-Wreturn-type-c-linkage] + This is because mstats is only (intentionally see the FIXME) declared in mmprivate.h + and C (or just VC++ and clang in extern "C" mode) requires the struct to be fully + declared before it is used (likely so that it can know whether it is a POD or not). + Since mmprivate.h first include mmalloc.h, even including expliclty mmprivate.h + we still can not get in a position where struct mstats is fully declared before + the next line is parsed ... Since the FIXME in mmprivate.h says that anyhow + the data should not be provided using this struct mstats ... we just comment + this comment it out. +*/ + // extern struct mstats mmstats PARAMS ((PTR)); #ifndef WIN32 extern PTR mmalloc_attach PARAMS ((int, PTR, int)); diff --git a/core/clib/src/Demangle.c b/core/clib/src/Demangle.c index e02cdaff6e7a5..cd7c7f02990f1 100644 --- a/core/clib/src/Demangle.c +++ b/core/clib/src/Demangle.c @@ -2370,7 +2370,7 @@ demangle_args (work, mangled, declp) { /* If we have 10 or more types we might have more than a 1 digit index so we'll have to consume the whole count here. This - will loose if the next thing is a type name preceeded by a + will loose if the next thing is a type name preceded by a count but it's impossible to demangle that case properly anyway. Eg if we already have 12 types is T12Pc "(..., type1, anyway. Eg if we already have 12 types is T12Pc "(..., type1, diff --git a/core/cont/doc/Understanding_Collections.html b/core/cont/doc/Understanding_Collections.html index c75f77438a23a..d1405fa5a5efa 100644 --- a/core/cont/doc/Understanding_Collections.html +++ b/core/cont/doc/Understanding_Collections.html @@ -2,7 +2,7 @@ Understanding Collections - + diff --git a/core/cont/inc/TBits.h b/core/cont/inc/TBits.h index cae92b286c460..26db69a8a75b1 100644 --- a/core/cont/inc/TBits.h +++ b/core/cont/inc/TBits.h @@ -136,6 +136,8 @@ class TBits : public TObject { UInt_t CountBits(UInt_t startBit=0) const ; // return number of bits set to 1 UInt_t FirstNullBit(UInt_t startBit=0) const; UInt_t FirstSetBit(UInt_t startBit=0) const; + UInt_t LastNullBit(UInt_t startBit=999999999) const; + UInt_t LastSetBit(UInt_t startBit=999999999) const; UInt_t GetNbits() const { return fNbits; } UInt_t GetNbytes() const { return fNbytes; } diff --git a/core/cont/inc/TCollectionProxyInfo.h b/core/cont/inc/TCollectionProxyInfo.h index f12f4b2735ec4..d56b7585ed0e7 100644 --- a/core/cont/inc/TCollectionProxyInfo.h +++ b/core/cont/inc/TCollectionProxyInfo.h @@ -42,9 +42,151 @@ namespace ROOT { // to create the proper Collection Proxy. // This is similar to Reflex's CollFuncTable. - public: + // Same value as TVirtualCollectionProxy. + static const UInt_t fgIteratorArenaSize = 16; // greater than sizeof(void*) + sizeof(UInt_t) + + /** @class template TCollectionProxyInfo::IteratorValue + * + * Small helper to encapsulate whether to return the value + * pointed to by the iterator or its address. + * + **/ + + template struct IteratorValue { + static void* get(typename Cont_t::iterator &iter) { + return (void*)&(*iter); + } + }; + + template struct IteratorValue { + static void* get(typename Cont_t::iterator &iter) { + return (void*)(*iter); + } + }; + + /** @class template TCollectionProxyInfo::Iterators + * + * Small helper to implement the function to create,access and destroy + * iterators. + * + **/ + + template + struct Iterators { + typedef Cont_t *PCont_t; + typedef typename Cont_t::iterator iterator; + + static void create(void *coll, void **begin_arena, void **end_arena, TVirtualCollectionProxy*) { + PCont_t c = PCont_t(coll); + new (*begin_arena) iterator(c->begin()); + new (*end_arena) iterator(c->end()); + } + static void* copy(void *dest_arena, const void *source_ptr) { + iterator *source = (iterator *)(source_ptr); + new (dest_arena) iterator(*source); + return dest_arena; + } + static void* next(void *iter_loc, const void *end_loc) { + iterator *end = (iterator *)(end_loc); + iterator *iter = (iterator *)(iter_loc); + if (*iter != *end) { + void *result = IteratorValue::get(*iter); + ++(*iter); + return result; + } + return 0; + } + static void destruct1(void *iter_ptr) { + iterator *start = (iterator *)(iter_ptr); + start->~iterator(); + } + static void destruct2(void *begin_ptr, void *end_ptr) { + iterator *start = (iterator *)(begin_ptr); + iterator *end = (iterator *)(end_ptr); + start->~iterator(); + end->~iterator(); + } + }; + + // For Vector we take an extra short cut to avoid derefencing + // the iterator all the time and redefine the 'address' of the + // iterator as the iterator itself. This requires special handling + // in the looper (see TStreamerInfoAction) but is much faster. + template struct Iterators, false> { + typedef std::vector Cont_t; + typedef Cont_t *PCont_t; + typedef typename Cont_t::iterator iterator; + + static void create(void *coll, void **begin_arena, void **end_arena, TVirtualCollectionProxy*) { + PCont_t c = PCont_t(coll); + if (c->empty()) { + *begin_arena = 0; + *end_arena = 0; + return; + } + *begin_arena = &(*c->begin()); +#ifdef R__VISUAL_CPLUSPLUS + *end_arena = &(*(c->end()-1)) + 1; // On windows we can not dererence the end iterator at all. +#else + // coverity[past_the_end] Safe on other platforms + *end_arena = &(*c->end()); +#endif + } + static void* copy(void *dest, const void *source) { + *(void**)dest = *(void**)(const_cast(source)); + return dest; + } + static void* next(void * /* iter_loc */, const void * /* end_loc */) { + // Should not be used. + R__ASSERT(0 && "Intentionally not implemented, do not use."); + return 0; + } + static void destruct1(void * /* iter_ptr */) { + // Nothing to do + } + static void destruct2(void * /* begin_ptr */, void * /* end_ptr */) { + // Nothing to do + } + }; + + template struct Iterators { + typedef Cont_t *PCont_t; + typedef typename Cont_t::iterator iterator; + + static void create(void *coll, void **begin_arena, void **end_arena, TVirtualCollectionProxy*) { + PCont_t c = PCont_t(coll); + *begin_arena = new iterator(c->begin()); + *end_arena = new iterator(c->end()); + } + static void* copy(void * /*dest_arena*/, const void *source_ptr) { + iterator *source = (iterator *)(source_ptr); + void *iter = new iterator(*source); + return iter; + } + static void* next(void *iter_loc, const void *end_loc) { + iterator *end = (iterator *)(end_loc); + iterator *iter = (iterator *)(iter_loc); + if (*iter != *end) { + void *result = IteratorValue::get(*iter); + ++(*iter); + return result; + } + return 0; + } + static void destruct1(void *begin_ptr) { + iterator *start = (iterator *)(begin_ptr); + delete start; + } + static void destruct2(void *begin_ptr, void *end_ptr) { + iterator *start = (iterator *)(begin_ptr); + iterator *end = (iterator *)(end_ptr); + delete start; + delete end; + } + }; + /** @class TCollectionProxyInfo::Environ TCollectionProxyInfo.h TCollectionProxyInfo.h * * Small helper to save proxy environment in the event of @@ -165,10 +307,9 @@ namespace ROOT { ::new(m) Value_t(); return 0; } - static void* collect(void* env) { - PEnv_t e = PEnv_t(env); - PCont_t c = PCont_t(e->fObject); - PValue_t m = PValue_t(e->fStart); + static void* collect(void *coll, void *array) { + PCont_t c = PCont_t(coll); + PValue_t m = PValue_t(array); for (Iter_t i=c->begin(); i != c->end(); ++i, ++m ) ::new(m) Value_t(*i); return 0; @@ -178,6 +319,10 @@ namespace ROOT { for (size_t i=0; i < size; ++i, ++m ) m->~Value_t(); } + + static const bool fgLargeIterator = sizeof(typename Cont_t::iterator) > fgIteratorArenaSize; + typedef Iterators Iterators_t; + }; /** @class TCollectionProxyInfo::Map TCollectionProxyInfo.h TCollectionProxyInfo.h @@ -293,21 +438,21 @@ namespace ROOT { void* (*fConstructFunc)(void*,size_t); void (*fDestructFunc)(void*,size_t); void* (*fFeedFunc)(void*,void*,size_t); - void* (*fCollectFunc)(void*); + void* (*fCollectFunc)(void*,void*); void* (*fCreateEnv)(); // Set of function of direct iteration of the collections. - void (*fGetIterators)(void *collection, void *&begin_arena, void *&end_arena); + void (*fCreateIterators)(void *collection, void **begin_arena, void **end_arena, TVirtualCollectionProxy *proxy); // begin_arena and end_arena should contain the location of memory arena of size fgIteratorSize. // If the collection iterator are of that size or less, the iterators will be constructed in place in those location (new with placement) // Otherwise the iterators will be allocated via a regular new and their address returned by modifying the value of begin_arena and end_arena. - void (*fCopyIterator)(void *&dest, const void *source); + void* (*fCopyIterator)(void *dest, const void *source); // Copy the iterator source, into dest. dest should contain should contain the location of memory arena of size fgIteratorSize. // If the collection iterator are of that size or less, the iterator will be constructed in place in this location (new with placement) // Otherwise the iterator will be allocated via a regular new and its address returned by modifying the value of dest. - void* (*fNext)(void *iter, void *end); + void* (*fNext)(void *iter, const void *end); // iter and end should be pointer to respectively an iterator to be incremented and the result of colleciton.end() // 'Next' will increment the iterator 'iter' and return 0 if the iterator reached the end. // If the end is not reached, 'Next' will return the address of the content unless the collection contains pointers in @@ -331,8 +476,13 @@ namespace ROOT { void* (*construct_func)(void*,size_t), void (*destruct_func)(void*,size_t), void* (*feed_func)(void*,void*,size_t), - void* (*collect_func)(void*), - void* (*create_env)() + void* (*collect_func)(void*,void*), + void* (*create_env)(), + void (*getIterators)(void *collection, void **begin_arena, void **end_arena, TVirtualCollectionProxy *proxy) = 0, + void* (*copyIterator)(void *dest, const void *source) = 0, + void* (*next)(void *iter, const void *end) = 0, + void (*deleteSingleIterator)(void *iter) = 0, + void (*deleteTwoIterators)(void *begin, void *end) = 0 ) : fInfo(info), fIterSize(iter_size), fValueDiff(value_diff), fValueOffset(value_offset), @@ -340,7 +490,8 @@ namespace ROOT { fFirstFunc(first_func),fNextFunc(next_func),fConstructFunc(construct_func), fDestructFunc(destruct_func),fFeedFunc(feed_func),fCollectFunc(collect_func), fCreateEnv(create_env), - fGetIterators(0),fCopyIterator(0),fNext(0),fDeleteSingleIterator(0),fDeleteTwoIterators(0) + fCreateIterators(getIterators),fCopyIterator(copyIterator),fNext(next), + fDeleteSingleIterator(deleteSingleIterator),fDeleteTwoIterators(deleteTwoIterators) { } @@ -366,7 +517,12 @@ namespace ROOT { T::destruct, T::feed, T::collect, - T::Env_t::Create); + T::Env_t::Create, + T::Iterators_t::create, + T::Iterators_t::copy, + T::Iterators_t::next, + T::Iterators_t::destruct1, + T::Iterators_t::destruct2); } template static ROOT::TCollectionProxyInfo Get(const T&) { @@ -443,10 +599,9 @@ namespace ROOT { // Nothing to construct. return 0; } - static void* collect(void* env) { - PEnv_t e = PEnv_t(env); - PCont_t c = PCont_t(e->fObject); - PValue_t m = PValue_t(e->fStart); // 'start' is a buffer outside the container. + static void* collect(void *coll, void *array) { + PCont_t c = PCont_t(coll); + PValue_t m = PValue_t(array); // 'start' is a buffer outside the container. for (Iter_t i=c->begin(); i != c->end(); ++i, ++m ) ::new(m) Value_t(*i); return 0; @@ -454,6 +609,48 @@ namespace ROOT { static void destruct(void*,size_t) { // Nothing to destruct. } + + //static const bool fgLargeIterator = sizeof(Cont_t::iterator) > fgIteratorArenaSize; + //typedef Iterators Iterators_t; + + struct Iterators { + typedef Cont_t *PCont_t; + typedef Cont_t::iterator iterator; + + static void create(void *coll, void **begin_arena, void **end_arena, TVirtualCollectionProxy*) { + PCont_t c = PCont_t(coll); + new (*begin_arena) iterator(c->begin()); + new (*end_arena) iterator(c->end()); + } + static void* copy(void *dest_arena, const void *source_ptr) { + const iterator *source = (const iterator *)(source_ptr); + new (dest_arena) iterator(*source); + return dest_arena; + } + static void* next(void *iter_loc, const void *end_loc) { + const iterator *end = (const iterator *)(end_loc); + iterator *iter = (iterator *)(iter_loc); + if (*iter != *end) { + ++(*iter); + //if (*iter != *end) { + // return IteratorValue::get(*iter); + //} + } + return 0; + } + static void destruct1(void *iter_ptr) { + iterator *start = (iterator *)(iter_ptr); + start->~iterator(); + } + static void destruct2(void *begin_ptr, void *end_ptr) { + iterator *start = (iterator *)(begin_ptr); + iterator *end = (iterator *)(end_ptr); + start->~iterator(); + end->~iterator(); + } + }; + typedef Iterators Iterators_t; + }; template <> struct TCollectionProxyInfo::Pushback > : public TCollectionProxyInfo::Type > { @@ -539,10 +736,9 @@ namespace ROOT { // Nothing to construct. return 0; } - static void* collect(void* env) { - PEnv_t e = PEnv_t(env); - PCont_t c = PCont_t(e->fObject); - PValue_t m = PValue_t(e->fStart); // 'start' is a buffer outside the container. + static void* collect(void *coll, void *array) { + PCont_t c = PCont_t(coll); + PValue_t m = PValue_t(array); // 'start' is a buffer outside the container. for (size_t i=0; i != c->size(); ++i, ++m ) *m = c->test(i); return 0; @@ -550,6 +746,54 @@ namespace ROOT { static void destruct(void*,size_t) { // Nothing to destruct. } + + //static const bool fgLargeIterator = sizeof(typename Cont_t::iterator) > fgIteratorArenaSize; + //typedef Iterators Iterators_t; + + struct Iterators { + typedef Cont_t *PCont_t; + union PtrSize_t { size_t fIndex; void *fAddress; }; + typedef std::pair iterator; + // In the end iterator we store the bitset pointer + // and do not use the 'second' part of the pair. + // In the other iterator we store the index + // and the value. + + static void create(void *coll, void **begin_arena, void **end_arena, TVirtualCollectionProxy*) { + iterator *begin = new (*begin_arena) iterator; + begin->first.fIndex = 0; + begin->second = false; + iterator *end = new (*end_arena) iterator; + end->first.fAddress = coll; + end->second = false; + } + static void* copy(void *dest_arena, const void *source_ptr) { + const iterator *source = (const iterator *)(source_ptr); + new (dest_arena) iterator(*source); + return dest_arena; + } + static void* next(void *iter_loc, const void *end_loc) { + const iterator *end = (const iterator *)(end_loc); + PCont_t c = (PCont_t)end->first.fAddress; + iterator *iter = (iterator *)(iter_loc); + if (iter->first.fIndex != c->size()) { + iter->second = c->test(iter->first.fIndex); + ++(iter->first.fIndex); + } + return &(iter->second); + } + static void destruct1(void *iter_ptr) { + iterator *start = (iterator *)(iter_ptr); + start->~iterator(); + } + static void destruct2(void *begin_ptr, void *end_ptr) { + iterator *start = (iterator *)(begin_ptr); + iterator *end = (iterator *)(end_ptr); + start->~iterator(); + end->~iterator(); + } + }; + typedef Iterators Iterators_t; }; template diff --git a/core/cont/inc/TMap.h b/core/cont/inc/TMap.h index e9d4ae5c5ab80..f5334f82d4007 100644 --- a/core/cont/inc/TMap.h +++ b/core/cont/inc/TMap.h @@ -88,6 +88,8 @@ friend class TMapIter; TPair *RemoveEntry(TObject *key); virtual void SetOwnerValue(Bool_t enable = kTRUE); virtual void SetOwnerKeyValue(Bool_t ownkeys = kTRUE, Bool_t ownvals = kTRUE); + virtual Int_t Write(const char *name=0, Int_t option=0, Int_t bufsize=0); + virtual Int_t Write(const char *name=0, Int_t option=0, Int_t bufsize=0) const; ClassDef(TMap,3) //A (key,value) map }; diff --git a/core/cont/inc/TRefArray.h b/core/cont/inc/TRefArray.h index c1d078fff5bd7..f082123ff4b3c 100644 --- a/core/cont/inc/TRefArray.h +++ b/core/cont/inc/TRefArray.h @@ -55,6 +55,7 @@ friend class TRefArrayIter; Bool_t OutOfBoundsError(const char *where, Int_t i) const; Int_t GetAbsLast() const; TObject *GetFromTable(Int_t idx) const; + Bool_t GetObjectUID(Int_t &uid, TObject *obj, const char *methodname); public: typedef TRefArrayIter Iterator_t; diff --git a/core/cont/inc/TVirtualCollectionProxy.h b/core/cont/inc/TVirtualCollectionProxy.h index b1f31dbbec658..8a495b2447ba5 100644 --- a/core/cont/inc/TVirtualCollectionProxy.h +++ b/core/cont/inc/TVirtualCollectionProxy.h @@ -1,4 +1,4 @@ -// @(#)root/cont:$Id$ +// @(#)root/cont:$Id: f761e5ab393bb556962776de666bc9dd0b6e738b $ // Author: Philippe Canal 20/08/2003 /************************************************************************* @@ -76,16 +76,16 @@ class TVirtualCollectionProxy { virtual TVirtualCollectionProxy* Generate() const = 0; // Returns an object of the actual CollectionProxy class virtual ~TVirtualCollectionProxy() {}; - virtual TClass *GetCollectionClass() { return fClass; } + virtual TClass *GetCollectionClass() const { return fClass; } // Return a pointer to the TClass representing the container - virtual Int_t GetCollectionType() = 0; + virtual Int_t GetCollectionType() const = 0; // Return the type of collection see TClassEdit::ESTLType - virtual ULong_t GetIncrement() = 0; + virtual ULong_t GetIncrement() const = 0; // Return the offset between two consecutive value_types (memory layout). - virtual Int_t GetProperties() { return fProperties; } + virtual Int_t GetProperties() const { return fProperties; } // Return miscallenous properties of the proxy see TVirtualCollectionProxy::EProperty virtual void *New() const { @@ -106,13 +106,13 @@ class TVirtualCollectionProxy { return fClass.GetClass()==0 ? 0 : fClass->NewArray(nElements, arena); } - virtual void Destructor(void *p, Bool_t dtorOnly = kFALSE) { + virtual void Destructor(void *p, Bool_t dtorOnly = kFALSE) const { // Execute the container destructor TClass* cl = fClass.GetClass(); if (cl) cl->Destructor(p, dtorOnly); } - virtual void DeleteArray(void *p, Bool_t dtorOnly = kFALSE) { + virtual void DeleteArray(void *p, Bool_t dtorOnly = kFALSE) const { // Execute the container array destructor TClass* cl = fClass.GetClass(); if (cl) cl->DeleteArray(p, dtorOnly); @@ -130,10 +130,10 @@ class TVirtualCollectionProxy { virtual Bool_t HasPointers() const = 0; // Return true if the content is of type 'pointer to' - virtual TClass *GetValueClass() = 0; + virtual TClass *GetValueClass() const = 0; // Return a pointer to the TClass representing the content. - virtual EDataType GetType() = 0; + virtual EDataType GetType() const = 0; // If the content is a simple numerical value, return its type (see TDataType) virtual void *At(UInt_t idx) = 0; @@ -159,7 +159,7 @@ class TVirtualCollectionProxy { // Set of functions to iterate easily throught the collection static const Int_t fgIteratorArenaSize = 16; // greater than sizeof(void*) + sizeof(UInt_t) - typedef void (*CreateIterators_t)(void *collection, void **begin_arena, void **end_arena); + typedef void (*CreateIterators_t)(void *collection, void **begin_arena, void **end_arena, TVirtualCollectionProxy *proxy); virtual CreateIterators_t GetFunctionCreateIterators(Bool_t read = kTRUE) = 0; // begin_arena and end_arena should contain the location of a memory arena of size fgIteratorSize. // If the collection iterator are of that size or less, the iterators will be constructed in place in those location (new with placement) @@ -169,7 +169,8 @@ class TVirtualCollectionProxy { virtual CopyIterator_t GetFunctionCopyIterator(Bool_t read = kTRUE) = 0; // Copy the iterator source, into dest. dest should contain the location of a memory arena of size fgIteratorSize. // If the collection iterator is of that size or less, the iterator will be constructed in place in this location (new with placement) - // Otherwise the iterator will be allocated via a regular new and its address returned by modifying the value of dest. + // Otherwise the iterator will be allocated via a regular new. + // The actual address of the iterator is returned in both case. typedef void* (*Next_t)(void *iter, const void *end); virtual Next_t GetFunctionNext(Bool_t read = kTRUE) = 0; diff --git a/core/cont/src/TBits.cxx b/core/cont/src/TBits.cxx index 63b9b2f228241..50cb66fd6a841 100644 --- a/core/cont/src/TBits.cxx +++ b/core/cont/src/TBits.cxx @@ -302,6 +302,45 @@ UInt_t TBits::FirstNullBit(UInt_t startBit) const return fNbits; } +//______________________________________________________________________________ +UInt_t TBits::LastNullBit(UInt_t startBit) const +{ + // Return position of first null bit (starting from position 0 and up) + + static const Int_t fbits[256] = { + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6, + 6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6, + 6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6, + 6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6, + 5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5, + 5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5, + 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4, + 3,3,3,3,3,3,3,3,2,2,2,2,1,1,0,8}; + + UInt_t i; + if (startBit>=fNbits) startBit = fNbits-1; + UInt_t startByte = startBit/8; + UInt_t ibit = startBit%8; + if (ibit<7) { + for (i=ibit+1;i>0;i--) { + if ((fAllBits[startByte] & (1<<(i-1))) == 0) return 8*startByte+i-1; + } + startByte--; + } + for(i=startByte+1; i>0; i--) { + if (fAllBits[i-1] != 255) return 8*(i-1) + fbits[fAllBits[i-1]]; + } + return fNbits; +} + //______________________________________________________________________________ UInt_t TBits::FirstSetBit(UInt_t startBit) const { @@ -347,6 +386,45 @@ UInt_t TBits::FirstSetBit(UInt_t startBit) const return fNbits; } +//______________________________________________________________________________ +UInt_t TBits::LastSetBit(UInt_t startBit) const +{ + // Return position of first non null bit (starting from position 0 and up) + + static const Int_t fbits[256] = { + 8,0,1,1,2,2,2,2,3,3,3,3,3,3,3,3, + 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4, + 5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5, + 5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5, + 6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6, + 6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6, + 6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6, + 6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7}; + + UInt_t i; + if (startBit>=fNbits) startBit = fNbits-1; + UInt_t startByte = startBit/8; + UInt_t ibit = startBit%8; + if (ibit<7) { + for (i=ibit+1;i>0;i--) { + if ((fAllBits[startByte] & (1<<(i-1))) != 0) return 8*startByte+i-1; + } + startByte--; + } + for(i=startByte+1; i>0; i--) { + if (fAllBits[i-1] != 0) return 8*(i-1) + fbits[fAllBits[i-1]]; + } + return fNbits; +} + //______________________________________________________________________________ void TBits::Output(ostream &os) const { diff --git a/core/cont/src/TClonesArray.cxx b/core/cont/src/TClonesArray.cxx index 1684b5734f203..7efeeca06925f 100644 --- a/core/cont/src/TClonesArray.cxx +++ b/core/cont/src/TClonesArray.cxx @@ -434,18 +434,28 @@ void TClonesArray::Delete(Option_t *) // memory (e.g. objects inheriting from TNamed or containing TStrings // allocate memory). If not you better use Clear() since if is faster. - Long_t dtoronly = TObject::GetDtorOnly(); - for (Int_t i = 0; i < fSize; i++) { - if (fCont[i] && fCont[i]->TestBit(kNotDeleted)) { - // Tell custom operator delete() not to delete space when - // object fCont[i] is deleted. Only destructors are called - // for this object. - TObject::SetDtorOnly(fCont[i]); - delete fCont[i]; + if ( fClass->TestBit(TClass::kIsEmulation) ) { + // In case of emulated class, we can not use the delete operator + // directly, it would use the wrong destructor. + for (Int_t i = 0; i < fSize; i++) { + if (fCont[i] && fCont[i]->TestBit(kNotDeleted)) { + fClass->Destructor(fCont[i],kTRUE); + } } + } else { + Long_t dtoronly = TObject::GetDtorOnly(); + for (Int_t i = 0; i < fSize; i++) { + if (fCont[i] && fCont[i]->TestBit(kNotDeleted)) { + // Tell custom operator delete() not to delete space when + // object fCont[i] is deleted. Only destructors are called + // for this object. + TObject::SetDtorOnly(fCont[i]); + delete fCont[i]; + } + } + // Restore the state. + TObject::SetDtorOnly((void*)dtoronly); } - // Restore the state. - TObject::SetDtorOnly((void*)dtoronly); // Protect against erroneously setting of owner bit. SetOwner(kFALSE); @@ -918,13 +928,8 @@ TObject *&TClonesArray::operator[](Int_t idx) // obj->TestBit(TObject::kNotDeleted) // will behave correctly. // TObject::kNotDeleted is one of the higher bit that is not settable via the public - // interface. - static size_t fbitsOffset = 0; - if (fbitsOffset == 0) { - fbitsOffset = TObject::Class()->GetDataMemberOffset("fBits"); - } - char *fbitsAddress = ((char*)fKeep->fCont[idx]) + fbitsOffset; - *(UInt_t*)fbitsAddress = 0; + // interface. But luckily we are its friend. + fKeep->fCont[idx]->fBits &= ~kNotDeleted; } fCont[idx] = fKeep->fCont[idx]; @@ -995,7 +1000,7 @@ void TClonesArray::AbsorbObjects(TClonesArray *tc) Expand(newSize); // move - for (Int_t i = 0; i <= tc->GetEntriesFast(); i++) { + for (Int_t i = 0; i < tc->GetEntriesFast(); ++i) { fCont[oldSize+i] = tc->fCont[i]; (*fKeep)[oldSize+i] = (*(tc->fKeep))[i]; tc->fCont[i] = 0; @@ -1012,7 +1017,7 @@ void TClonesArray::AbsorbObjects(TClonesArray *tc) //______________________________________________________________________________ void TClonesArray::AbsorbObjects(TClonesArray *tc, Int_t idx1, Int_t idx2) { - // Directly move the rang of object pointers from tc without cloning + // Directly move the range of object pointers from tc without cloning // (copying). // This TClonesArray takes over ownership of all of tc's object pointers // from idx1 to idx2. The tc array is re-arranged by return. @@ -1041,8 +1046,10 @@ void TClonesArray::AbsorbObjects(TClonesArray *tc, Int_t idx1, Int_t idx2) // move for (Int_t i = idx1; i <= idx2; i++) { - fCont[oldSize+i -idx1] = tc->fCont[i]; - (*fKeep)[oldSize+i-idx1] = (*(tc->fKeep))[i]; + Int_t newindex = oldSize+i -idx1; + fCont[newindex] = tc->fCont[i]; + ::operator delete(fKeep->fCont[newindex]); + (*fKeep)[newindex] = (*(tc->fKeep))[i]; tc->fCont[i] = 0; (*(tc->fKeep))[i] = 0; } diff --git a/core/cont/src/TCollection.cxx b/core/cont/src/TCollection.cxx index c632446f3316b..8fe4b740f4cf6 100644 --- a/core/cont/src/TCollection.cxx +++ b/core/cont/src/TCollection.cxx @@ -581,14 +581,16 @@ void TCollection::GarbageCollect(TObject *obj) { // Add to the list of things to be cleaned up. - R__LOCKGUARD2(gCollectionMutex); - if (fgGarbageCollection) { - if (!fgEmptyingGarbage) { - fgGarbageCollection->Add(obj); - } else - delete obj; - } else - delete obj; + { + R__LOCKGUARD2(gCollectionMutex); + if (fgGarbageCollection) { + if (!fgEmptyingGarbage) { + fgGarbageCollection->Add(obj); + return; + } + } + } + delete obj; } //______________________________________________________________________________ diff --git a/core/cont/src/TList.cxx b/core/cont/src/TList.cxx index 0089d2e29c372..344d61678d622 100644 --- a/core/cont/src/TList.cxx +++ b/core/cont/src/TList.cxx @@ -68,6 +68,7 @@ #include "TList.h" #include "TClass.h" +#include "TROOT.h" #include namespace std {} using namespace std; @@ -351,6 +352,16 @@ void TList::Clear(Option_t *option) return; } + // In some case, for example TParallelCoord, a list (the pad's list of + // primitives) will contain both the container and the containees + // (the TParallelCoorVar) but if the Clear is being called from + // the destructor of the container of this list, one of the first + // thing done will be the remove the container (the pad) for the + // list (of Primitives of the canvas) that was connecting it + // (indirectly) to the list of cleanups. + // So let's temporarily add the current list and remove it later. + bool needRegister = fFirst && TROOT::Initialized() && !gROOT->GetListOfCleanups()->FindObject(this); + if (needRegister) gROOT->GetListOfCleanups()->Add(this); while (fFirst) { TObjLink *tlk = fFirst; fFirst = fFirst->Next(); @@ -365,6 +376,7 @@ void TList::Clear(Option_t *option) } delete tlk; } + if (needRegister) ROOT::GetROOT()->GetListOfCleanups()->Remove(this); fFirst = fLast = fCache = 0; fSize = 0; Changed(); @@ -385,6 +397,16 @@ void TList::Delete(Option_t *option) if (slow) { + // In some case, for example TParallelCoord, a list (the pad's list of + // primitives) will contain both the container and the containees + // (the TParallelCoorVar) but if the Clear is being called from + // the destructor of the container of this list, one of the first + // thing done will be the remove the container (the pad) for the + // list (of Primitives of the canvas) that was connecting it + // (indirectly) to the list of cleanups. + // So let's temporarily add the current list and remove it later. + bool needRegister = fFirst && TROOT::Initialized() && !gROOT->GetListOfCleanups()->FindObject(this); + if (needRegister) gROOT->GetListOfCleanups()->Add(this); while (fFirst) { TObjLink *tlk = fFirst; fFirst = fFirst->Next(); @@ -397,6 +419,7 @@ void TList::Delete(Option_t *option) delete tlk; } + if (needRegister) ROOT::GetROOT()->GetListOfCleanups()->Remove(this); fFirst = fLast = fCache = 0; fSize = 0; diff --git a/core/cont/src/TMap.cxx b/core/cont/src/TMap.cxx index 6891916fac598..d17cdc1f4bfa2 100644 --- a/core/cont/src/TMap.cxx +++ b/core/cont/src/TMap.cxx @@ -405,6 +405,47 @@ void TMap::Streamer(TBuffer &b) } } +//______________________________________________________________________________ +Int_t TMap::Write(const char *name, Int_t option, Int_t bsize) const +{ + // Write all objects in this map. By default all objects in + // the collection are written individually (each object gets its + // own key). Note, this is recursive, i.e. objects in collections + // in the collection are also written individually. To write all + // objects using a single key specify a name and set option to + // TObject::kSingleKey (i.e. 1). + + if ((option & kSingleKey)) { + return TObject::Write(name, option, bsize); + } else { + option &= ~kSingleKey; + Int_t nbytes = 0; + TIter next(fTable); + TPair *a; + while ((a = (TPair*) next())) { + if (a->Key()) + nbytes += a->Key()->Write(name, option, bsize); + if (a->Value()) + nbytes += a->Value()->Write(name, option, bsize); + } + return nbytes; + } +} + +//______________________________________________________________________________ +Int_t TMap::Write(const char *name, Int_t option, Int_t bsize) +{ + // Write all objects in this map. By default all objects in + // the collection are written individually (each object gets its + // own key). Note, this is recursive, i.e. objects in collections + // in the collection are also written individually. To write all + // objects using a single key specify a name and set option to + // TObject::kSingleKey (i.e. 1). + + return ((const TMap*)this)->Write(name,option,bsize); +} + + ////////////////////////////////////////////////////////////////////////// // // // TPair // diff --git a/core/cont/src/TObjArray.cxx b/core/cont/src/TObjArray.cxx index 1a4d16495f279..0336f5970e29b 100644 --- a/core/cont/src/TObjArray.cxx +++ b/core/cont/src/TObjArray.cxx @@ -330,11 +330,23 @@ void TObjArray::Delete(Option_t *) { // Remove all objects from the array AND delete all heap based objects. - for (Int_t i = 0; i < fSize; i++) + // In some case, for example TParallelCoord, a list (the pad's list of + // primitives) will contain both the container and the containees + // (the TParallelCoorVar) but if the Clear is being called from + // the destructor of the container of this list, one of the first + // thing done will be the remove the container (the pad) for the + // list (of Primitives of the canvas) that was connecting it + // (indirectly) to the list of cleanups. + // So let's temporarily add the current list and remove it later. + bool needRegister = fSize && TROOT::Initialized() && !gROOT->GetListOfCleanups()->FindObject(this); + if (needRegister) gROOT->GetListOfCleanups()->Add(this); + for (Int_t i = 0; i < fSize; i++) { if (fCont[i] && fCont[i]->IsOnHeap()) { TCollection::GarbageCollect(fCont[i]); fCont[i] = 0; } + } + if (needRegister) ROOT::GetROOT()->GetListOfCleanups()->Remove(this); Init(fSize, fLowerBound); } diff --git a/core/cont/src/TRefArray.cxx b/core/cont/src/TRefArray.cxx index 47a8052bc296a..c24af1422972d 100644 --- a/core/cont/src/TRefArray.cxx +++ b/core/cont/src/TRefArray.cxx @@ -170,7 +170,7 @@ TRefArray::~TRefArray() } //______________________________________________________________________________ -static Bool_t R__GetUID(Int_t &uid, TObject *obj, TProcessID *pid, const char *methodname) +Bool_t TRefArray::GetObjectUID(Int_t &uid, TObject *obj, const char *methodname) { // Private/static function, check for validity of pid. @@ -179,21 +179,49 @@ static Bool_t R__GetUID(Int_t &uid, TObject *obj, TProcessID *pid, const char *m if (obj->TestBit(kHasUUID)) { valid = kFALSE; } else if (obj->TestBit(kIsReferenced)) { - valid = (pid == TProcessID::GetProcessWithUID(obj)); + valid = (fPID == TProcessID::GetProcessWithUID(obj)); if (valid) { uid = obj->GetUniqueID(); + } else { + if (GetAbsLast() < 0) { + // The container is empty, we can switch the ProcessID. + fPID = TProcessID::GetProcessWithUID(obj); + valid = kTRUE; + if (gDebug > 3) + Info(TString::Format("TRefArray::%s",methodname),"The ProcessID for the %p has been switched to %s/%s:%d.", + this,fPID->GetName(),fPID->GetTitle(),fPID->GetUniqueID()); + } } } else { - valid = (pid == TProcessID::GetSessionProcessID()); - if (valid) { - uid = TProcessID::AssignID(obj); + // If we could, we would just add the object to the + // TRefArray's ProcessID. For now, just check the + // ProcessID it would be added to, i.e the current one, + // is not full. + + if (!(TProcessID::GetObjectCount() >= 16777215)) { + valid = (fPID == TProcessID::GetSessionProcessID()); + if (valid) { + uid = TProcessID::AssignID(obj); + } + } else { + // The AssignID will create a new TProcessID. + if (GetAbsLast() < 0) { + // If we are empty, we can handle it. + uid = TProcessID::AssignID(obj); + fPID = TProcessID::GetProcessWithUID(obj); + Warning(TString::Format("TRefArray::%s",methodname),"The ProcessID for the %p has been switched to %s/%s:%d. There are too many referenced objects.", + this,fPID->GetName(),fPID->GetTitle(),fPID->GetUniqueID()); + return kTRUE; + } else { + Error(TString::Format("TRefArray::%s",methodname),"The object at %p can not be registered in the process the TRefArray points to (pid = %s/%s) because the ProcessID has too many objects and the TRefArray already contains other objecs.",obj,fPID->GetName(),fPID->GetTitle()); + return kFALSE; + } } } if (!valid) { - TString name; name.Form("TRefArray::%s",methodname); - ::Error(name, - "The object at %p is not registered in the process the TRefArray point to (pid = %s/%s)",obj,pid->GetName(),pid->GetTitle()); + ::Error(TString::Format("TRefArray::%s",methodname), + "The object at %p is not registered in the process the TRefArray points to (pid = %s/%s)",obj,fPID->GetName(),fPID->GetTitle()); } return valid; } @@ -209,7 +237,7 @@ void TRefArray::AddFirst(TObject *obj) // Check if the object can belong here Int_t uid; - if (R__GetUID(uid, obj, fPID, "AddFirst")) { + if (GetObjectUID(uid, obj, "AddFirst")) { fUIDs[0] = uid; Changed(); } @@ -284,7 +312,7 @@ void TRefArray::AddAtAndExpand(TObject *obj, Int_t idx) // Check if the object can belong here Int_t uid; - if (R__GetUID(uid, obj, fPID, "AddAtAndExpand")) { + if (GetObjectUID(uid, obj, "AddAtAndExpand")) { fUIDs[idx-fLowerBound] = uid; fLast = TMath::Max(idx-fLowerBound, GetAbsLast()); Changed(); @@ -302,7 +330,7 @@ void TRefArray::AddAt(TObject *obj, Int_t idx) // Check if the object can belong here Int_t uid; - if (R__GetUID(uid, obj, fPID, "AddAt")) { + if (GetObjectUID(uid, obj, "AddAt")) { fUIDs[idx-fLowerBound] = uid;; fLast = TMath::Max(idx-fLowerBound, GetAbsLast()); Changed(); @@ -322,7 +350,7 @@ Int_t TRefArray::AddAtFree(TObject *obj) if (!fUIDs[i]) { // Add object at position i // Check if the object can belong here Int_t uid; - if (R__GetUID(uid, obj, fPID, "AddAtFree")) { + if (GetObjectUID(uid, obj, "AddAtFree")) { fUIDs[i] = uid; fLast = TMath::Max(i, GetAbsLast()); Changed(); diff --git a/core/doc/v534/index.html b/core/doc/v534/index.html index 8747e1068ba07..adab0e216b9d6 100644 --- a/core/doc/v534/index.html +++ b/core/doc/v534/index.html @@ -31,3 +31,10 @@

TStyle

The default font set by gStyle->SetLegendFont() was ignored.

+ +

TUnixSystem

+
    +
  • Simplify Setenv coding.
  • +
  • Implement Unsetenv using the system function unsetenv. +
  • +
diff --git a/core/lzma/CMakeLists.txt b/core/lzma/CMakeLists.txt index c1e76347a8dbd..551e946bb5ca5 100644 --- a/core/lzma/CMakeLists.txt +++ b/core/lzma/CMakeLists.txt @@ -16,5 +16,5 @@ list(APPEND LibCore_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/inc) set(LibCore_SRCS ${LibCore_SRCS} PARENT_SCOPE) set(LibCore_INCLUDE_DIRS ${LibCore_INCLUDE} PARENT_SCOPE) -install(FILES ${LZMA_headers} DESTINATION include) +install(FILES ${LZMA_headers} DESTINATION ${CMAKE_INSTALL_INCDIR}) diff --git a/core/lzma/Module.mk b/core/lzma/Module.mk index 9c62a21e7105e..ddfffaecfd7be 100644 --- a/core/lzma/Module.mk +++ b/core/lzma/Module.mk @@ -128,6 +128,11 @@ else LZMACC="$$LZMACC -m64"; \ LZMA_CFLAGS="-m64"; \ fi; \ + if [ $(ARCH) = "linuxx8664k1omicc" ]; then \ + LZMACC="$$LZMACC -m64 $(MICFLAGS)"; \ + LZMA_CFLAGS="-m64 $(MICFLAGS)"; \ + LZMA_HOST="--host=x86_64-unknown-linux-gnu"; \ + fi; \ if [ $(ARCH) = "macosx" ]; then \ LZMACC="$$LZMACC -m32"; \ LZMA_CFLAGS="-m32"; \ @@ -137,12 +142,10 @@ else LZMA_CFLAGS="-m64"; \ fi; \ if [ $(ARCH) = "iossim" ]; then \ - LZMACC="$$LZMACC -arch i386"; \ LZMA_CFLAGS="-arch i386 -isysroot $(IOSSDK) -miphoneos-version-min=$(IOSVERS)"; \ LZMA_HOST="--host=i686-apple-darwin10"; \ fi; \ if [ $(ARCH) = "ios" ]; then \ - LZMACC="$$LZMACC -arch armv7"; \ LZMA_CFLAGS="-arch armv7 -isysroot $(IOSSDK) -miphoneos-version-min=$(IOSVERS)"; \ LZMA_HOST="--host=arm-apple-darwin10"; \ fi; \ diff --git a/core/macosx/Module.mk b/core/macosx/Module.mk index 791c93347c480..b1f3e0e687c18 100644 --- a/core/macosx/Module.mk +++ b/core/macosx/Module.mk @@ -3,6 +3,12 @@ # # Author: Timur Pocheptsov, 5/12/2011 +MACOSXNDEBUG := -DNDEBUG +ifeq ($(ROOTBUILD),debug) + MACOSXNDEBUG := +endif + + MODNAME := macosx MODDIR := $(ROOT_SRCDIR)/core/$(MODNAME) MODDIRS := $(MODDIR)/src @@ -53,3 +59,5 @@ distclean-$(MODNAME): clean-$(MODNAME) @rm -f $(MACOSXDEP) $(MACOSXDS) $(MACOSXDH) distclean:: distclean-$(MODNAME) + +$(MACOSXO): CXXFLAGS += $(MACOSXNDEBUG) diff --git a/core/macosx/inc/CocoaUtils.h b/core/macosx/inc/CocoaUtils.h index 2cfb60f19b656..632e17987c606 100644 --- a/core/macosx/inc/CocoaUtils.h +++ b/core/macosx/inc/CocoaUtils.h @@ -12,6 +12,8 @@ #ifndef ROOT_CocoaUtils #define ROOT_CocoaUtils +#include + #include namespace ROOT { @@ -107,6 +109,11 @@ class NSStrongReference { template class NSScopeGuard { public: + NSScopeGuard() + : fNSObject(nil) + { + } + explicit NSScopeGuard(NSObject *nsObject) : fNSObject(nsObject) { @@ -150,9 +157,13 @@ class NSScopeGuard { class AutoreleasePool { public: - AutoreleasePool(); + AutoreleasePool(bool delayCreation = false); ~AutoreleasePool(); + //Drains the previous pool (if any) + //and activates a new one. + void Reset(); + private: NSAutoreleasePool *fPool; @@ -274,6 +285,64 @@ class CFScopeGuard { CFScopeGuard &operator = (const CFScopeGuard &rhs); }; +/////////////////////////////////////////////////// +// // +// Scoped array - scope guard for array. // +// Sometimes, I can not use std::vector, // +// for example, data is allocated in TGCocoa // +// and must be later freed in Objective-C code. // +// To make the code exception-safe, I still // +// have to care about memory, which is already // +// allocated. Not to have all this explicit // +// delete [] in error handlers (it's easy // +// to forget!!!) - I have ScopedArray. // +// One good day I'll delete this and use // +// standard library. // +// // +/////////////////////////////////////////////////// + +template +class ScopedArray { +public: + explicit ScopedArray(T * p = 0) + : fData(p) + { + } + + ~ScopedArray() + { + delete [] fData; + } + + void Reset(T * p) + { + if (p != fData) + delete [] fData; + fData = p; + } + + void Release() + { + fData = 0; + } + + T &operator [] (std::ptrdiff_t index)const + { + return fData[index]; + } + + T *Get()const + { + return fData; + } + +private: + T *fData; + + ScopedArray(const ScopedArray &rhs); + ScopedArray &operator = (const ScopedArray &rhs); +}; + }//Util }//MacOSX }//ROOT diff --git a/core/macosx/inc/TMacOSXSystem.h b/core/macosx/inc/TMacOSXSystem.h index cf8e6c93be600..dbdb7dadcd547 100644 --- a/core/macosx/inc/TMacOSXSystem.h +++ b/core/macosx/inc/TMacOSXSystem.h @@ -39,15 +39,18 @@ class MacOSXSystem; } class TMacOSXSystem : public TUnixSystem { + friend class TGCocoa; public: TMacOSXSystem(); ~TMacOSXSystem(); void DispatchOneEvent(Bool_t pendingOnly); + bool CocoaInitialized() const; private: + void InitializeCocoa(); -// void WaitForGuiEvents(Long_t nextto); + bool ProcessPendingEvents(); void WaitEvents(Long_t nextto); void AddFileHandler(TFileHandler *fh); @@ -56,6 +59,7 @@ class TMacOSXSystem : public TUnixSystem { void ProcessApplicationDefinedEvent(void *event); std::auto_ptr fPimpl; //! + bool fCocoaInitialized;//! TMacOSXSystem(const TMacOSXSystem &rhs); TMacOSXSystem &operator = (const TMacOSXSystem &rhs); diff --git a/core/macosx/src/CocoaUtils.mm b/core/macosx/src/CocoaUtils.mm index 8496d59e1d386..92b6843b80c27 100644 --- a/core/macosx/src/CocoaUtils.mm +++ b/core/macosx/src/CocoaUtils.mm @@ -16,8 +16,8 @@ namespace Util { //______________________________________________________________________________ -AutoreleasePool::AutoreleasePool() - : fPool([[NSAutoreleasePool alloc] init]) +AutoreleasePool::AutoreleasePool(bool delayCreation /* = false*/) + : fPool(delayCreation ? nil : [[NSAutoreleasePool alloc] init]) { } @@ -27,6 +27,15 @@ [fPool release]; } +//______________________________________________________________________________ +void AutoreleasePool::Reset() +{ + if (fPool) + [fPool release]; + + fPool = [[NSAutoreleasePool alloc] init]; +} + }//Util }//MacOSX }//ROOT diff --git a/core/macosx/src/TMacOSXSystem.mm b/core/macosx/src/TMacOSXSystem.mm index 3edcefdc5d35e..eedd48b69c9ab 100644 --- a/core/macosx/src/TMacOSXSystem.mm +++ b/core/macosx/src/TMacOSXSystem.mm @@ -8,15 +8,13 @@ * For the licensing terms see $ROOTSYS/LICENSE. * * For the list of contributors see $ROOTSYS/README/CREDITS. * *************************************************************************/ - -#define NDEBUG #include #include #include #include -#import +#include #include "TSeqCollection.h" #include "TMacOSXSystem.h" @@ -24,6 +22,31 @@ #include "TVirtualX.h" #include "TError.h" +//The special class to perform a selector to stop a -run: method. +@interface RunStopper : NSObject +@end + +@implementation RunStopper + +//We attach this delegate only once, when trying to initialize NSApplication (by calling its -run method). +//______________________________________________________________________________ +- (void) stopRun +{ + [NSApp stop : nil]; + //This is not enough to stop, from docs: + //This method notifies the application that you want to exit the current run loop as soon as it finishes processing the current NSEvent object. + //This method does not forcibly exit the current run loop. Instead it sets a flag that the application checks only after it finishes dispatching an actual event object. + + + //I'm sending a fake event, to stop. + NSEvent* stopEvent = [NSEvent otherEventWithType: NSApplicationDefined location: NSMakePoint(0,0) modifierFlags: 0 timestamp: 0.0 + windowNumber: 0 context: nil subtype: 0 data1: 0 data2: 0]; + [NSApp postEvent : stopEvent atStart : true]; +} + +@end + + // //Stuff which I have to copy from TUnixSystem. Find a better way to organize code. //Fortunately, this does not violate ODR, but still UGLY. @@ -84,14 +107,10 @@ Int_t IsSet(Int_t n) class MacOSXSystem { public: - enum DescriptorType { - write, - read - }; - MacOSXSystem(); ~MacOSXSystem(); + void InitializeCocoa(); void AddFileHandler(TFileHandler *fh); void RemoveFileHandler(TFileHandler *fh); @@ -100,14 +119,31 @@ Int_t IsSet(Int_t n) void UnregisterFileDescriptor(CFFileDescriptorRef fd); void CloseFileDescriptors(); - std::map fFileDescriptors; - std::set fCFFileDescriptors; - const ROOT::MacOSX::Util::AutoreleasePool fPool; + enum DescriptorType { + kDTWrite, + kDTRead + }; + + //Before I had C++11 and auto, now I have ugly typedefs. + typedef std::map fd_map_type; + typedef fd_map_type::iterator fd_map_iterator; + typedef fd_map_type::const_iterator const_fd_map_iterator; + + fd_map_type fReadFds; + fd_map_type fWriteFds; + + static void RemoveFileDescriptor(fd_map_type &fdTable, int fd); + void SetFileDescriptors(const fd_map_type &fdTable, DescriptorType fdType); + + std::set fCFFileDescriptors; + + ROOT::MacOSX::Util::AutoreleasePool fPool; + bool fCocoaInitialized; static MacOSXSystem *fgInstance; }; -MacOSXSystem *MacOSXSystem::fgInstance = nullptr; +MacOSXSystem *MacOSXSystem::fgInstance = 0; extern "C" { @@ -118,7 +154,7 @@ void TMacOSXSystem_ReadCallback(CFFileDescriptorRef fdref, CFOptionFlags /*callB const int nativeFD = CFFileDescriptorGetNativeDescriptor(fdref); //We do not need this descriptor anymore. - assert(MacOSXSystem::fgInstance != nullptr && "TMacOSXSystem_ReadCallback, MacOSXSystem's singleton is null"); + assert(MacOSXSystem::fgInstance != 0 && "TMacOSXSystem_ReadCallback, MacOSXSystem's singleton is null"); MacOSXSystem::fgInstance->UnregisterFileDescriptor(fdref); CFFileDescriptorInvalidate(fdref); @@ -136,7 +172,7 @@ void TMacOSXSystem_WriteCallback(CFFileDescriptorRef fdref, CFOptionFlags /*call const int nativeFD = CFFileDescriptorGetNativeDescriptor(fdref); //We do not need this descriptor anymore. - assert(MacOSXSystem::fgInstance != nullptr && "TMacOSXSystem_WriteCallback, MacOSXSystem's singleton is null"); + assert(MacOSXSystem::fgInstance != 0 && "TMacOSXSystem_WriteCallback, MacOSXSystem's singleton is null"); MacOSXSystem::fgInstance->UnregisterFileDescriptor(fdref); CFFileDescriptorInvalidate(fdref); @@ -151,37 +187,60 @@ void TMacOSXSystem_WriteCallback(CFFileDescriptorRef fdref, CFOptionFlags /*call //______________________________________________________________________________ MacOSXSystem::MacOSXSystem() + : fPool(true), //Delay the pool creation! + fCocoaInitialized(false) { assert(fgInstance == 0 && "MacOSXSystem, fgInstance was initialized already"); - fgInstance = this; } //______________________________________________________________________________ MacOSXSystem::~MacOSXSystem() { - CloseFileDescriptors(); + if (fCocoaInitialized) + CloseFileDescriptors(); +} + +//______________________________________________________________________________ +void MacOSXSystem::InitializeCocoa() +{ + assert(fCocoaInitialized == false && "InitializeCocoa, Cocoa was initialized already"); + + [NSApplication sharedApplication]; + fPool.Reset();//TODO: test, should it be BEFORE shared application??? + fCocoaInitialized = true; } //______________________________________________________________________________ void MacOSXSystem::AddFileHandler(TFileHandler *fh) { - //Can throw std::bad_alloc. I'm not allocating any resources here, so I'm not going to catch here. + //Can throw std::bad_alloc. I'm not allocating any resources here. assert(fh != 0 && "AddFileHandler, fh parameter is null"); - assert(fFileDescriptors.find(fh->GetFd()) == fFileDescriptors.end() && "AddFileHandler, file descriptor was registered already"); + + if (fh->HasReadInterest()) + fReadFds[fh->GetFd()]++; + + //Can we have "duplex" fds? - fFileDescriptors[fh->GetFd()] = fh->HasReadInterest() ? read : write; + if (fh->HasWriteInterest()) + fWriteFds[fh->GetFd()]++; } //______________________________________________________________________________ void MacOSXSystem::RemoveFileHandler(TFileHandler *fh) { //Can not throw. + + //ROOT has obvious bugs somewhere: the same fd can be removed MORE times, + //than it was added. + assert(fh != 0 && "RemoveFileHandler, fh parameter is null"); - std::map::iterator fdIter = fFileDescriptors.find(fh->GetFd()); - assert(fdIter != fFileDescriptors.end() && "RemoveFileHandler, file handler was not found"); - fFileDescriptors.erase(fdIter); + if (fh->HasReadInterest()) + RemoveFileDescriptor(fReadFds, fh->GetFd()); + + if (fh->HasWriteInterest()) + RemoveFileDescriptor(fWriteFds, fh->GetFd()); } //______________________________________________________________________________ @@ -193,28 +252,11 @@ void TMacOSXSystem_WriteCallback(CFFileDescriptorRef fdref, CFOptionFlags /*call //return false. Return true if everything is ok. try { - for (std::map::iterator fdIter = fFileDescriptors.begin(), end = fFileDescriptors.end(); fdIter != end; ++fdIter) { - const bool read = fdIter->second == read; - CFFileDescriptorRef fdref = CFFileDescriptorCreate(kCFAllocatorDefault, fdIter->first, false, read ? TMacOSXSystem_ReadCallback : TMacOSXSystem_WriteCallback, 0); - - if (!fdref) - throw std::runtime_error("MacOSXSystem::SetFileDescriptors: CFFileDescriptorCreate failed"); - - CFFileDescriptorEnableCallBacks(fdref, read ? kCFFileDescriptorReadCallBack : kCFFileDescriptorWriteCallBack); - - CFRunLoopSourceRef runLoopSource = CFFileDescriptorCreateRunLoopSource(kCFAllocatorDefault, fdref, 0); - - if (!runLoopSource) { - CFRelease(fdref); - throw std::runtime_error("MacOSXSystem::SetFileDescriptors: CFFileDescriptorCreateRunLoopSource failed"); - } - - CFRunLoopAddSource(CFRunLoopGetMain(), runLoopSource, kCFRunLoopDefaultMode); - CFRelease(runLoopSource); - - fCFFileDescriptors.insert(fdref); - } - } catch (const std::exception &e) { + if (fReadFds.size()) + SetFileDescriptors(fReadFds, kDTRead); + if (fWriteFds.size()) + SetFileDescriptors(fWriteFds, kDTWrite); + } catch (const std::exception &) { CloseFileDescriptors(); return false; } @@ -236,6 +278,9 @@ void TMacOSXSystem_WriteCallback(CFFileDescriptorRef fdref, CFOptionFlags /*call //______________________________________________________________________________ void MacOSXSystem::CloseFileDescriptors() { + //While Core Foundation is not Cocoa, it still should not be used if we are not initializing Cocoa. + assert(fCocoaInitialized == true && "CloseFileDescriptors, Cocoa was not initialized"); + for (std::set::iterator fdIter = fCFFileDescriptors.begin(), end = fCFFileDescriptors.end(); fdIter != end; ++fdIter) { CFFileDescriptorInvalidate(*fdIter); CFRelease(*fdIter); @@ -244,100 +289,98 @@ void TMacOSXSystem_WriteCallback(CFFileDescriptorRef fdref, CFOptionFlags /*call fCFFileDescriptors.clear(); } -}//Detail -}//MacOSX -}//ROOT - -namespace Private = ROOT::MacOSX::Detail; - -ClassImp(TMacOSXSystem) - //______________________________________________________________________________ -TMacOSXSystem::TMacOSXSystem() - : fPimpl(new Private::MacOSXSystem) +void MacOSXSystem::RemoveFileDescriptor(fd_map_type &fdTable, int fd) { - [NSApplication sharedApplication]; -} + fd_map_iterator fdIter = fdTable.find(fd); -//______________________________________________________________________________ -TMacOSXSystem::~TMacOSXSystem() -{ + if (fdIter != fdTable .end()) { + assert(fdIter->second != 0 && "RemoveFD, 'dead' descriptor in a table"); + if (!(fdIter->second - 1)) + fdTable.erase(fdIter); + else + --fdIter->second; + } else { + //I had to comment warning, many thanks to ROOT for this bizarre thing. + //::Warning("RemoveFileDescriptor", "Descriptor %d was not found in a table", fd); + } } //______________________________________________________________________________ -void TMacOSXSystem::ProcessApplicationDefinedEvent(void *e) +void MacOSXSystem::SetFileDescriptors(const fd_map_type &fdTable, DescriptorType fdType) { - //Right now I have app. defined events only - //for file descriptors. This can change in a future. - NSEvent *event = (NSEvent *)e; + //While CoreFoundation is not Cocoa, it still should not be used if we are not initializing Cocoa. + assert(fCocoaInitialized == true && "SetFileDescriptors, Cocoa was not initialized"); - assert(event != nil && "AddFileActivityEvent, event parameter is nil"); - assert(event.type == NSApplicationDefined && "AddFileActivityEvent, event parameter has wrong type"); + for (const_fd_map_iterator fdIter = fdTable.begin(), end = fdTable.end(); fdIter != end; ++fdIter) { + const bool read = fdType == kDTRead; + CFFileDescriptorRef fdref = CFFileDescriptorCreate(kCFAllocatorDefault, fdIter->first, false, read ? TMacOSXSystem_ReadCallback : TMacOSXSystem_WriteCallback, 0); + + if (!fdref) + throw std::runtime_error("MacOSXSystem::SetFileDescriptors: CFFileDescriptorCreate failed"); + + CFFileDescriptorEnableCallBacks(fdref, read ? kCFFileDescriptorReadCallBack : kCFFileDescriptorWriteCallBack); - if (event.data2) { - gVirtualX->DispatchClientMessage(event.data2); - } else { - std::map::iterator fdIter = fPimpl->fFileDescriptors.find(event.data1); - assert(fdIter != fPimpl->fFileDescriptors.end() && "WaitForAllEvents, file descriptor from NSEvent not found"); - if (fdIter->second == Private::MacOSXSystem::read) - fReadready->Set(event.data1); - else - fWriteready->Set(event.data1); + CFRunLoopSourceRef runLoopSource = CFFileDescriptorCreateRunLoopSource(kCFAllocatorDefault, fdref, 0); - ++fNfd; - } -} + if (!runLoopSource) { + CFRelease(fdref); + throw std::runtime_error("MacOSXSystem::SetFileDescriptors: CFFileDescriptorCreateRunLoopSource failed"); + } -//______________________________________________________________________________ -void TMacOSXSystem::WaitEvents(Long_t nextto) -{ - //Wait for GUI/Non-GUI events. + CFRunLoopAddSource(CFRunLoopGetMain(), runLoopSource, kCFRunLoopDefaultMode); + CFRelease(runLoopSource); - if (!fPimpl->SetFileDescriptors()) { - //I consider this error as fatal. - Fatal("WaitForAllEvents", "SetFileDesciptors failed"); + fCFFileDescriptors.insert(fdref); } +} - NSDate *untilDate = nil; - if (nextto >= 0)//0 also means non-blocking call. - untilDate = [NSDate dateWithTimeIntervalSinceNow : nextto / 1000.]; - else - untilDate = [NSDate distantFuture]; - - fReadready->Zero(); - fWriteready->Zero(); - fNfd = 0; - - NSEvent *event = [NSApp nextEventMatchingMask : NSAnyEventMask untilDate : untilDate inMode : NSDefaultRunLoopMode dequeue : YES]; +}//Detail +}//MacOSX +}//ROOT - if (event.type == NSApplicationDefined) - ProcessApplicationDefinedEvent(event); - else - [NSApp sendEvent : event]; +namespace Private = ROOT::MacOSX::Detail; - while ((event = [NSApp nextEventMatchingMask : NSAnyEventMask untilDate : nil inMode : NSDefaultRunLoopMode dequeue : YES])) { - if (event.type == NSApplicationDefined) - ProcessApplicationDefinedEvent(event); - else - [NSApp sendEvent : event]; - } +ClassImp(TMacOSXSystem) - fPimpl->CloseFileDescriptors(); +//______________________________________________________________________________ +TMacOSXSystem::TMacOSXSystem() + : fPimpl(new Private::MacOSXSystem), + fCocoaInitialized(false) +{ + InitializeCocoa(); +} - gVirtualX->Update(2); - gVirtualX->Update(3); +//______________________________________________________________________________ +TMacOSXSystem::~TMacOSXSystem() +{ } //______________________________________________________________________________ void TMacOSXSystem::DispatchOneEvent(Bool_t pendingOnly) { //Here I try to emulate TUnixSystem's behavior, which is quite twisted. - //I'm not even sure, I need all this code :) + //I'm not even sure, I need all this code :) + + if (!fCocoaInitialized)//We are in a batch mode (or 'batch'). + return TUnixSystem::DispatchOneEvent(pendingOnly); + Bool_t pollOnce = pendingOnly; while (true) { const ROOT::MacOSX::Util::AutoreleasePool pool; + if (ProcessPendingEvents()) { + //If we had some events in a system queue, probably, + //now we have some events in our own event-queue. + if (gXDisplay && gXDisplay->Notify()) { + gVirtualX->Update(2); + gVirtualX->Update(3); + if (!pendingOnly) + return; + } + } + //Check for file descriptors ready for reading/writing. if (fNfd > 0 && fFileHandler && fFileHandler->GetSize() > 0) if (CheckDescriptors()) @@ -374,19 +417,115 @@ void TMacOSXSystem_WriteCallback(CFFileDescriptorRef fdref, CFOptionFlags /*call nextto = NextTimeOut(kTRUE); if (pendingOnly) { - if (fFileHandler && !fFileHandler->GetSize()) - return; + //if (fFileHandler && !fFileHandler->GetSize()) + // return; nextto = 0; pollOnce = kFALSE; } //Wait for GUI events and for something else, like read/write from stdin/stdout (?). WaitEvents(nextto); + + if (gXDisplay && gXDisplay->Notify()) { + gVirtualX->Update(2); + gVirtualX->Update(3); + if (!pendingOnly) + return; + } + if (pendingOnly) return; } } +//______________________________________________________________________________ +bool TMacOSXSystem::CocoaInitialized() const +{ + return fCocoaInitialized; +} + +//______________________________________________________________________________ +void TMacOSXSystem::InitializeCocoa() +{ + if (fCocoaInitialized) + return; + + //TODO: add error handling and results check. + + fPimpl->InitializeCocoa(); + + const ROOT::MacOSX::Util::AutoreleasePool pool; + + //[NSApplication sharedApplication];//TODO: clean-up this mess with pools and sharedApplication + //Documentation says, that +sharedApplication, initializes the app. But this is not true, + //it's still not really initialized, part of initialization is done by -run method. + + //If you call run, it never returns unless app is finished. I have to stop Cocoa's event loop + //processing, since we have our own event loop. + + const ROOT::MacOSX::Util::NSScopeGuard stopper([[RunStopper alloc] init]); + + [stopper.Get() performSelector : @selector(stopRun) withObject : nil afterDelay : 0.05];//Delay? What it should be? + [NSApp run]; + + fCocoaInitialized = true; +} + +//______________________________________________________________________________ +bool TMacOSXSystem::ProcessPendingEvents() +{ + assert(fCocoaInitialized == true && "ProcessPendingEvents, called while Cocoa was not initialized"); + + bool processed = false; + while (NSEvent *event = [NSApp nextEventMatchingMask : NSAnyEventMask untilDate : nil inMode : NSDefaultRunLoopMode dequeue : YES]) { + [NSApp sendEvent : event]; + processed = true; + } + return processed; +} + +//______________________________________________________________________________ +void TMacOSXSystem::WaitEvents(Long_t nextto) +{ + //Wait for GUI/Non-GUI events. + + assert(fCocoaInitialized == true && "WaitEvents, called while Cocoa was not initialized"); + + if (!fPimpl->SetFileDescriptors()) { + //I consider this error as fatal. + Fatal("WaitForAllEvents", "SetFileDesciptors failed"); + } + + NSDate *untilDate = nil; + if (nextto >= 0)//0 also means non-blocking call. + untilDate = [NSDate dateWithTimeIntervalSinceNow : nextto / 1000.]; + else + untilDate = [NSDate distantFuture]; + + fReadready->Zero(); + fWriteready->Zero(); + fNfd = 0; + + NSEvent *event = [NSApp nextEventMatchingMask : NSAnyEventMask untilDate : untilDate inMode : NSDefaultRunLoopMode dequeue : YES]; + + if (event.type == NSApplicationDefined) + ProcessApplicationDefinedEvent(event); + else + [NSApp sendEvent : event]; + + while ((event = [NSApp nextEventMatchingMask : NSAnyEventMask untilDate : nil inMode : NSDefaultRunLoopMode dequeue : YES])) { + if (event.type == NSApplicationDefined) + ProcessApplicationDefinedEvent(event); + else + [NSApp sendEvent : event]; + } + + fPimpl->CloseFileDescriptors(); + + gVirtualX->Update(2); + gVirtualX->Update(3); +} + //______________________________________________________________________________ void TMacOSXSystem::AddFileHandler(TFileHandler *fh) { @@ -400,3 +539,38 @@ void TMacOSXSystem_WriteCallback(CFFileDescriptorRef fdref, CFOptionFlags /*call fPimpl->RemoveFileHandler(fh); return TUnixSystem::RemoveFileHandler(fh); } + +//______________________________________________________________________________ +void TMacOSXSystem::ProcessApplicationDefinedEvent(void *e) +{ + //Right now I have app. defined events only + //for file descriptors. This can change in a future. + + assert(fCocoaInitialized == true && "ProcessApplicationDefinedEvent, called while Cocoa was not initialized"); + + NSEvent *event = (NSEvent *)e; + assert(event != nil && "ProcessApplicationDefinedEvent, event parameter is nil"); + assert(event.type == NSApplicationDefined && "ProcessApplicationDefinedEvent, event parameter has wrong type"); + + Private::MacOSXSystem::fd_map_iterator fdIter = fPimpl->fReadFds.find(event.data1); + bool descriptorFound = false; + + if (fdIter != fPimpl->fReadFds.end()) { + fReadready->Set(event.data1); + descriptorFound = true; + } + + fdIter = fPimpl->fWriteFds.find(event.data1); + if (fdIter != fPimpl->fWriteFds.end()) { + fWriteready->Set(event.data1); + descriptorFound = true; + } + + if (!descriptorFound) { + Error("ProcessApplicationDefinedEvent", "file descriptor %d was not found", int(event.data1)); + return; + } + + ++fNfd; +} + diff --git a/core/meta/CMakeLists.txt b/core/meta/CMakeLists.txt index c8e5e72dea288..fc6458acea7a8 100644 --- a/core/meta/CMakeLists.txt +++ b/core/meta/CMakeLists.txt @@ -2,10 +2,12 @@ # CMakeLists.txt file for building ROOT core/meta package ############################################################################ +ROOT_USE_PACKAGE(core/metautils) + ROOT_GLOB_SOURCES(sources ${CMAKE_CURRENT_SOURCE_DIR}/src/*.cxx) ROOT_GLOB_HEADERS(headers RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}/inc ${CMAKE_CURRENT_SOURCE_DIR}/inc/*.h) -if(BuildCling) +if(cling) add_definitions(-DR__WITH_CLING) else() list(REMOVE_ITEM headers TCintWithCling.h) diff --git a/core/meta/inc/LinkDef.h b/core/meta/inc/LinkDef.h index 2f78132ae8cd8..ef3d0b6c8e5de 100644 --- a/core/meta/inc/LinkDef.h +++ b/core/meta/inc/LinkDef.h @@ -21,6 +21,7 @@ #pragma link C++ class TClass; #pragma link C++ class TClassStreamer+; #pragma link C++ class TMemberStreamer+; +#pragma link C++ class TClassAttributeMap+; #pragma link C++ class TClassRef+; #pragma link C++ class TClassGenerator+; #pragma link C++ class TDataMember; diff --git a/core/meta/inc/TCint.h b/core/meta/inc/TCint.h index 2ba9b14fceef5..4f2f9c511a70f 100644 --- a/core/meta/inc/TCint.h +++ b/core/meta/inc/TCint.h @@ -108,6 +108,7 @@ class TCint : public TInterpreter { Long_t ProcessLineAsynch(const char *line, EErrorCode *error = 0); Long_t ProcessLineSynch(const char *line, EErrorCode *error = 0); void PrintIntro(); + Int_t SetClassSharedLibs(const char *cls, const char *libs); void SetGetline(const char*(*getlineFunc)(const char* prompt), void (*histaddFunc)(const char* line)); void Reset(); @@ -116,6 +117,7 @@ class TCint : public TInterpreter { void ResetGlobalVar(void *obj); void RewindDictionary(); Int_t DeleteGlobal(void *obj); + Int_t DeleteVariable(const char* name) ; void SaveContext(); void SaveGlobalsContext(); void UpdateListOfGlobals(); @@ -181,7 +183,7 @@ class TCint : public TInterpreter { virtual void CallFunc_Delete(void *func) const; virtual void CallFunc_Exec(CallFunc_t *func, void *address) const; virtual Long_t CallFunc_ExecInt(CallFunc_t *func, void *address) const; - virtual Long_t CallFunc_ExecInt64(CallFunc_t *func, void *address) const; + virtual Long64_t CallFunc_ExecInt64(CallFunc_t *func, void *address) const; virtual Double_t CallFunc_ExecDouble(CallFunc_t *func, void *address) const; virtual CallFunc_t *CallFunc_Factory() const; virtual CallFunc_t *CallFunc_FactoryCopy(CallFunc_t *func) const; @@ -270,6 +272,7 @@ class TCint : public TInterpreter { virtual void MethodInfo_CreateSignature(MethodInfo_t *minfo, TString &signature) const; virtual void MethodInfo_Delete(MethodInfo_t *minfo) const; virtual MethodInfo_t *MethodInfo_Factory() const; + virtual MethodInfo_t *MethodInfo_Factory(ClassInfo_t * /*clinfo*/) const; virtual MethodInfo_t *MethodInfo_FactoryCopy(MethodInfo_t *minfo) const; virtual MethodInfo_t *MethodInfo_InterfaceMethod(MethodInfo_t *minfo) const; virtual Bool_t MethodInfo_IsValid(MethodInfo_t *minfo) const; @@ -282,11 +285,13 @@ class TCint : public TInterpreter { virtual const char *MethodInfo_GetPrototype(MethodInfo_t *minfo) const; virtual const char *MethodInfo_Name(MethodInfo_t *minfo) const; virtual const char *MethodInfo_TypeName(MethodInfo_t *minfo) const; + virtual std::string MethodInfo_TypeNormalizedName(MethodInfo_t *minfo) const; virtual const char *MethodInfo_Title(MethodInfo_t *minfo) const; // G__MethodArgInfo interface virtual void MethodArgInfo_Delete(MethodArgInfo_t *marginfo) const; virtual MethodArgInfo_t *MethodArgInfo_Factory() const; + virtual MethodArgInfo_t *MethodArgInfo_Factory(MethodInfo_t *minfo) const; virtual MethodArgInfo_t *MethodArgInfo_FactoryCopy(MethodArgInfo_t *marginfo) const; virtual Bool_t MethodArgInfo_IsValid(MethodArgInfo_t *marginfo) const; virtual int MethodArgInfo_Next(MethodArgInfo_t *marginfo) const; @@ -294,7 +299,7 @@ class TCint : public TInterpreter { virtual const char *MethodArgInfo_DefaultValue(MethodArgInfo_t *marginfo) const; virtual const char *MethodArgInfo_Name(MethodArgInfo_t *marginfo) const; virtual const char *MethodArgInfo_TypeName(MethodArgInfo_t *marginfo) const; - + virtual std::string MethodArgInfo_TypeNormalizedName(MethodArgInfo_t *marginfo) const; // G__TypeInfo interface virtual void TypeInfo_Delete(TypeInfo_t *tinfo) const; @@ -316,6 +321,7 @@ class TCint : public TInterpreter { virtual TypedefInfo_t *TypedefInfo_FactoryCopy(TypedefInfo_t *tinfo) const; virtual void TypedefInfo_Init(TypedefInfo_t *tinfo, const char *funcname) const; virtual Bool_t TypedefInfo_IsValid(TypedefInfo_t *tinfo) const; + virtual int TypedefInfo_Next(TypedefInfo_t *tinfo) const; virtual Long_t TypedefInfo_Property(TypedefInfo_t *tinfo) const; virtual int TypedefInfo_Size(TypedefInfo_t *tinfo) const; virtual const char *TypedefInfo_TrueName(TypedefInfo_t *tinfo) const; diff --git a/core/meta/inc/TClass.h b/core/meta/inc/TClass.h index 0a1985c7a0be3..d57f29c30b1bc 100644 --- a/core/meta/inc/TClass.h +++ b/core/meta/inc/TClass.h @@ -39,6 +39,7 @@ class TBaseClass; class TBrowser; class TDataMember; +class TClassAttributeMap; class TClassRef; class TMethod; class TRealData; @@ -139,6 +140,7 @@ friend class ROOT::TGenericClassInfo; TClassRef *fRefStart; //!List of references to this object TVirtualRefProxy *fRefProxy; //!Pointer to reference proxy if this class represents a reference ROOT::TSchemaRuleSet *fSchemaRules; //! Schema evolution rules + TClassAttributeMap *fAttributeMap; //pointer to a class attribute map typedef void (TClass::*StreamerImpl_t)(void *obj, TBuffer &b, const TClass *onfile_class) const; mutable StreamerImpl_t fStreamerImpl;//! Pointer to the function implementing the right streaming behavior for the class represented by this object. @@ -255,6 +257,7 @@ friend class ROOT::TGenericClassInfo; TVirtualCollectionProxy *GetCollectionProxy() const; TVirtualIsAProxy *GetIsAProxy() const; Version_t GetClassVersion() const { fVersionUsed = kTRUE; return fClassVersion; } + Int_t GetClassSize() const { return Size(); } TDataMember *GetDataMember(const char *datamember) const; Long_t GetDataMemberOffset(const char *membername) const; const char *GetDeclFileName() const { return fDeclFileName; } @@ -380,6 +383,14 @@ friend class ROOT::TGenericClassInfo; void Destructor(void *obj, Bool_t dtorOnly = kFALSE); void *DynamicCast(const TClass *base, void *obj, Bool_t up = kTRUE); Bool_t IsFolder(void *obj) const; + void CreateAttributeMap(); + TClassAttributeMap *GetAttributeMap() const + { + //Get the TClassAttributeMap pointer to be able to add attribute + //pairs key-value to the TClass. + + return fAttributeMap; + } inline void Streamer(void *obj, TBuffer &b, const TClass *onfile_class = 0) const { // Inline for performance, skipping one function call. diff --git a/core/meta/inc/TClassAttributeMap.h b/core/meta/inc/TClassAttributeMap.h new file mode 100644 index 0000000000000..ad506e05d7657 --- /dev/null +++ b/core/meta/inc/TClassAttributeMap.h @@ -0,0 +1,56 @@ +// @(#)root/meta:$Id$ +// Author: Bianca-Cristina Cristescu 03/07/13 + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TClassAttributeMap +#define ROOT_TClassAttributeMap + + +////////////////////////////////////////////////////////////////////////// +// // +// TClassAttributeMap // +// // +// Dictionary of attributes of a TClass. // +// // +////////////////////////////////////////////////////////////////////////// + + +#ifndef ROOT_TObject +#include "TObject.h" +#endif +#ifndef ROOT_THashTable +#include "THashTable.h" +#endif + + +class TClassAttributeMap : public TObject +{ +public: + + TClassAttributeMap(); + virtual ~TClassAttributeMap(); + + void AddProperty(const char* key, const char* value); + Bool_t HasKey(const char* key) const; + const char *GetPropertyAsString(const char* key) const; + Int_t GetPropertySize() const { return fStringProperty.GetSize(); } + TString RemovePropertyString(const char* key); + Bool_t RemoveProperty(const char* key); + void Clear(Option_t* option = ""); + +private: + + THashTable fStringProperty; //all properties of String type + + ClassDef(TClassAttributeMap,1) // Container for name/value pairs of TClass attributes +}; + +#endif // ROOT_TClassAttributeMap + diff --git a/core/meta/inc/TClassRef.h b/core/meta/inc/TClassRef.h index edcce36c89aaa..5ce649dc22168 100644 --- a/core/meta/inc/TClassRef.h +++ b/core/meta/inc/TClassRef.h @@ -51,7 +51,7 @@ class TClassRef { TClassRef(const TClassRef&); inline TClassRef &operator=(const TClassRef &rhs) { // Inline implementation of operator= to speed the no-op case. - if (this != &rhs && fClassPtr != rhs.fClassPtr) { + if (this != &rhs && (fClassPtr == 0 || fClassPtr != rhs.fClassPtr)) { this->Assign(rhs); } return *this; diff --git a/core/meta/inc/TDictionary.h b/core/meta/inc/TDictionary.h index 632599f78ca18..49db02d460673 100644 --- a/core/meta/inc/TDictionary.h +++ b/core/meta/inc/TDictionary.h @@ -57,6 +57,10 @@ typedef void MethodArgInfo_t; typedef void TypeInfo_t; typedef void TypedefInfo_t; +#ifndef ROOT_ESTLType +#include "ESTLType.h" +#endif + enum EProperty { kIsClass = G__BIT_ISCLASS, kIsStruct = G__BIT_ISSTRUCT, @@ -95,7 +99,17 @@ class TDictionary : public TNamed { static TDictionary* GetDictionary(const type_info &typeinfo); // Type of STL container (returned by IsSTLContainer). - enum ESTLType {kNone=0, kVector=1, kList, kDeque, kMap, kMultimap, kSet, kMultiset}; + enum ESTLType { + kNone = ROOT::kNotSTL, + kVector = ROOT::kSTLvector, + kList = ROOT::kSTLlist, + kDeque = ROOT::kSTLdeque, + kMap = ROOT::kSTLmap, + kMultimap = ROOT::kSTLmultimap, + kSet = ROOT::kSTLset, + kMultiset = ROOT::kSTLmultiset, + kBitset = ROOT::kSTLbitset + }; ClassDef(TDictionary,0) //ABC defining interface to dictionary }; diff --git a/core/meta/inc/TFunction.h b/core/meta/inc/TFunction.h index 373579117c001..0c13a15fc9033 100644 --- a/core/meta/inc/TFunction.h +++ b/core/meta/inc/TFunction.h @@ -49,6 +49,7 @@ friend class TCintWithCling; virtual const char *GetPrototype() const; const char *GetSignature(); const char *GetReturnTypeName() const; + std::string GetReturnTypeNormalizedName() const; TList *GetListOfMethodArgs(); Int_t GetNargs() const; Int_t GetNargsOpt() const; diff --git a/core/meta/inc/TInterpreter.h b/core/meta/inc/TInterpreter.h index 6603488445681..7451bbf1a1322 100644 --- a/core/meta/inc/TInterpreter.h +++ b/core/meta/inc/TInterpreter.h @@ -83,6 +83,7 @@ class TInterpreter : public TNamed { virtual Long_t ProcessLine(const char *line, EErrorCode *error = 0) = 0; virtual Long_t ProcessLineSynch(const char *line, EErrorCode *error = 0) = 0; virtual void PrintIntro() = 0; + virtual Int_t SetClassSharedLibs(const char *cls, const char *libs) = 0; virtual void SetGetline(const char*(*getlineFunc)(const char* prompt), void (*histaddFunc)(const char* line)) = 0; virtual void Reset() = 0; @@ -91,6 +92,7 @@ class TInterpreter : public TNamed { virtual void ResetGlobalVar(void *obj) = 0; virtual void RewindDictionary() = 0; virtual Int_t DeleteGlobal(void *obj) = 0; + virtual Int_t DeleteVariable(const char* name) = 0; virtual void SaveContext() = 0; virtual void SaveGlobalsContext() = 0; virtual void UpdateListOfGlobals() = 0; @@ -152,7 +154,7 @@ class TInterpreter : public TNamed { virtual void CallFunc_Delete(void * /* func */) const {;} virtual void CallFunc_Exec(CallFunc_t * /* func */, void * /* address */) const {;} virtual Long_t CallFunc_ExecInt(CallFunc_t * /* func */, void * /* address */) const {return 0;} - virtual Long_t CallFunc_ExecInt64(CallFunc_t * /* func */, void * /* address */) const {return 0;} + virtual Long64_t CallFunc_ExecInt64(CallFunc_t * /* func */, void * /* address */) const {return 0;} virtual Double_t CallFunc_ExecDouble(CallFunc_t * /* func */, void * /* address */) const {return 0;} virtual CallFunc_t *CallFunc_Factory() const {return 0;} virtual CallFunc_t *CallFunc_FactoryCopy(CallFunc_t * /* func */) const {return 0;} @@ -241,6 +243,7 @@ class TInterpreter : public TNamed { virtual void MethodInfo_CreateSignature(MethodInfo_t * /* minfo */, TString & /* signature */) const {;} virtual void MethodInfo_Delete(MethodInfo_t * /* minfo */) const {;} virtual MethodInfo_t *MethodInfo_Factory() const {return 0;} + virtual MethodInfo_t *MethodInfo_Factory(ClassInfo_t * /*clinfo*/) const {return 0;} virtual MethodInfo_t *MethodInfo_FactoryCopy(MethodInfo_t * /* minfo */) const {return 0;} virtual MethodInfo_t *MethodInfo_InterfaceMethod(MethodInfo_t * /* minfo */) const {return 0;} virtual Bool_t MethodInfo_IsValid(MethodInfo_t * /* minfo */) const {return 0;} @@ -253,11 +256,13 @@ class TInterpreter : public TNamed { virtual const char *MethodInfo_GetPrototype(MethodInfo_t * /* minfo */) const {return 0;} virtual const char *MethodInfo_Name(MethodInfo_t * /* minfo */) const {return 0;} virtual const char *MethodInfo_TypeName(MethodInfo_t * /* minfo */) const {return 0;} + virtual std::string MethodInfo_TypeNormalizedName(MethodInfo_t * /* minfo */) const {return "";} virtual const char *MethodInfo_Title(MethodInfo_t * /* minfo */) const {return 0;} // G__MethodArgInfo interface virtual void MethodArgInfo_Delete(MethodArgInfo_t * /* marginfo */) const {;} virtual MethodArgInfo_t *MethodArgInfo_Factory() const {return 0;} + virtual MethodArgInfo_t *MethodArgInfo_Factory(MethodInfo_t * /*minfo*/) const {return 0;} virtual MethodArgInfo_t *MethodArgInfo_FactoryCopy(MethodArgInfo_t * /* marginfo */) const {return 0;} virtual Bool_t MethodArgInfo_IsValid(MethodArgInfo_t * /* marginfo */) const {return 0;} virtual int MethodArgInfo_Next(MethodArgInfo_t * /* marginfo */) const {return 0;} @@ -265,7 +270,7 @@ class TInterpreter : public TNamed { virtual const char *MethodArgInfo_DefaultValue(MethodArgInfo_t * /* marginfo */) const {return 0;} virtual const char *MethodArgInfo_Name(MethodArgInfo_t * /* marginfo */) const {return 0;} virtual const char *MethodArgInfo_TypeName(MethodArgInfo_t * /* marginfo */) const {return 0;} - + virtual std::string MethodArgInfo_TypeNormalizedName(MethodArgInfo_t * /* marginfo */) const {return 0;} // G__TypeInfo interface virtual void TypeInfo_Delete(TypeInfo_t * /* tinfo */) const {;} @@ -287,6 +292,7 @@ class TInterpreter : public TNamed { virtual TypedefInfo_t *TypedefInfo_FactoryCopy(TypedefInfo_t * /* tinfo */) const {return 0;} virtual void TypedefInfo_Init(TypedefInfo_t * /* tinfo */, const char * /* funcname */) const {;} virtual Bool_t TypedefInfo_IsValid(TypedefInfo_t * /* tinfo */) const {return 0;} + virtual int TypedefInfo_Next(TypedefInfo_t * /* tinfo */) const {return 0;} virtual Long_t TypedefInfo_Property(TypedefInfo_t * /* tinfo */) const {return 0;} virtual int TypedefInfo_Size(TypedefInfo_t * /* tinfo */) const {return 0;} virtual const char *TypedefInfo_TrueName(TypedefInfo_t * /* tinfo */) const {return 0;} diff --git a/core/meta/inc/TMethodArg.h b/core/meta/inc/TMethodArg.h index 0114dc963baae..70f3667e059cb 100644 --- a/core/meta/inc/TMethodArg.h +++ b/core/meta/inc/TMethodArg.h @@ -49,6 +49,7 @@ friend class TMethod; TFunction *GetMethod() const { return fMethod; } const char *GetTypeName() const; const char *GetFullTypeName() const; + std::string GetTypeNormalizedName() const; Long_t Property() const; TDataMember *GetDataMember() const; diff --git a/core/meta/inc/TStreamerElement.h b/core/meta/inc/TStreamerElement.h index e0eac11e63ad3..e3da746481053 100644 --- a/core/meta/inc/TStreamerElement.h +++ b/core/meta/inc/TStreamerElement.h @@ -1,4 +1,4 @@ -// @(#)root/meta:$Id$ +// @(#)root/meta:$Id: e0eac11e63ad37390c9467c97c5c6849c4ab7d39 $ // Author: Rene Brun 12/10/2000 /************************************************************************* @@ -25,6 +25,10 @@ #include "TNamed.h" #endif +#ifndef ROOT_ESTLType +#include "ESTLType.h" +#endif + class TMethodCall; class TClass; class TStreamerBasicType; @@ -54,12 +58,17 @@ class TStreamerElement : public TNamed { public: - enum ESTLtype { kSTL = 300 /* TVirtualStreamerInfo::kSTL */, - kSTLstring = 365 /* TVirtualStreamerInfo::kSTLstring */, - kSTLvector = 1, - kSTLlist = 2, kSTLdeque = 3, kSTLmap = 4, - kSTLset = 5, kSTLmultimap= 6, kSTLmultiset = 7, - kSTLbitset = 8 + enum ESTLtype { + kSTL = ROOT::kSTLany, + kSTLstring = ROOT::kSTLstring, + kSTLvector = ROOT::kSTLvector, + kSTLlist = ROOT::kSTLlist, + kSTLdeque = ROOT::kSTLdeque, + kSTLmap = ROOT::kSTLmap, + kSTLmultimap = ROOT::kSTLmultimap, + kSTLset = ROOT::kSTLset, + kSTLmultiset = ROOT::kSTLmultiset, + kSTLbitset = ROOT::kSTLbitset }; // TStreamerElement status bits enum { @@ -68,7 +77,8 @@ class TStreamerElement : public TNamed { kRepeat = BIT(10), kRead = BIT(11), kWrite = BIT(12), - kDoNotDelete = BIT(13) + kDoNotDelete = BIT(13), + kWholeObject = BIT(14) }; TStreamerElement(); @@ -90,6 +100,7 @@ class TStreamerElement : public TNamed { TClass* GetNewClass() const { return fNewClass; } Int_t GetType() const {return fType;} Int_t GetOffset() const {return fOffset;} + void GetSequenceType(TString &type) const; Int_t GetTObjectOffset() const { return fTObjectOffset; } const char *GetTypeName() const {return fTypeName.Data();} const char *GetTypeNameBasic() const; @@ -362,6 +373,8 @@ class TStreamerSTL : public TStreamerElement { TStreamerSTL(); TStreamerSTL(const char *name, const char *title, Int_t offset, const char *typeName, const char *trueType, Bool_t dmPointer); + TStreamerSTL(const char *name, const char *title, Int_t offset, + const char *typeName, const TVirtualCollectionProxy &proxy , Bool_t dmPointer); virtual ~TStreamerSTL(); Bool_t CannotSplit() const; Bool_t IsaPointer() const; diff --git a/core/meta/inc/TVirtualStreamerInfo.h b/core/meta/inc/TVirtualStreamerInfo.h index e187c0b986c03..569d7e667ffd6 100644 --- a/core/meta/inc/TVirtualStreamerInfo.h +++ b/core/meta/inc/TVirtualStreamerInfo.h @@ -25,6 +25,10 @@ #include "TNamed.h" #endif +#ifndef ROOT_ESTLType +#include "ESTLType.h" +#endif + class TFile; class TClass; class TObjArray; @@ -70,7 +74,8 @@ class TVirtualStreamerInfo : public TNamed { kSTLp = 71, kSkip = 100, kSkipL = 120, kSkipP = 140, kConv = 200, kConvL = 220, kConvP = 240, - kSTL = 300, kSTLstring = 365, + kSTL = ROOT::kSTLany /* 300 */, + kSTLstring = ROOT::kSTLstring /* 365 */, kStreamer = 500, kStreamLoop = 501, kCache = 600, // Cache the value in memory than is not part of the object but is accessible via a SchemaRule kArtificial = 1000, diff --git a/core/meta/src/TCint.cxx b/core/meta/src/TCint.cxx index 0dd02b2067759..691dfe2e2958b 100644 --- a/core/meta/src/TCint.cxx +++ b/core/meta/src/TCint.cxx @@ -763,6 +763,18 @@ Int_t TCint::DeleteGlobal(void *obj) return G__deleteglobal(obj); } + +//______________________________________________________________________________ +Int_t TCint::DeleteVariable(const char* buf) +{ + // Delete obj from CINT symbol table so it cannot be accessed anymore. + // Returns 1 in case of success and 0 in case object was not in table. + + R__LOCKGUARD(gCINTMutex); + + return G__deletevariable(buf) ; +} + //______________________________________________________________________________ void TCint::SaveContext() { @@ -842,18 +854,32 @@ void TCint::UpdateListOfGlobalFunctions() Bool_t needToAdd = kTRUE; // first remove if already in list TList* listFuncs = ((THashTable*)(gROOT->fGlobalFunctions))->GetListForObject(t.Name()); - if (listFuncs && (vt = (void*)t.InterfaceMethod())) { + if (listFuncs) { + vt = (void*)t.InterfaceMethod(); Long_t prop = -1; TIter iFunc(listFuncs); TFunction* f = 0; Bool_t foundStart = kFALSE; while (needToAdd && (f = (TFunction*)iFunc())) { if (strcmp(f->GetName(),t.Name())) { + // The function are sorted alphabetically, + // until we get to the first overload, we skip th test + // and then when we get to what is not an overload, + // we can quit. if (foundStart) break; - continue; + else continue; } foundStart = kTRUE; - if (vt == f->InterfaceMethod()) { + if (!vt) { + // an interpreted function. + + // Do not call TFunction::InterfaceMethod in this case + // as it might lead to a spurrious warning message: + // "Error: non class,struct,union object $bench used with . or ->" + // in case of some user function definition. + needToAdd = (f->Property() & G__BIT_ISCOMPILED) + || !( 0 == strcmp( t.GetMangledName() , f->GetMangledName()) ); + } else if (vt == f->InterfaceMethod()) { if (prop == -1) prop = t.Property(); needToAdd = !((prop & G__BIT_ISCOMPILED) @@ -1291,7 +1317,7 @@ const char *TCint::GetInterpreterTypeName(const char *name, Bool_t full) // The 'name' is known to the interpreter, this function returns // the internal version of this name (usually just resolving typedefs) // This is used in particular to synchronize between the name used - // by rootcint and by the run-time enviroment (TClass) + // by rootcint and by the run-time environment (TClass) // Return 0 if the name is not known. R__LOCKGUARD(gCINTMutex); @@ -1373,12 +1399,39 @@ void TCint::Execute(TObject *obj, TClass *cl, TMethod *method, TObjArray *params // Check number of actual parameters against of expected formal ones Int_t nparms = argList->LastIndex()+1; - Int_t argc = params ? params->LastIndex()+1:0; + Int_t argc = params ? params->GetEntries() : 0; - if (nparms != argc) { - Error("Execute","Wrong number of the parameters"); + if (argc > nparms) { + Error("Execute","Too many parameters to call %s, got %d but expected at most %d.",method->GetName(),argc,nparms); return; } + if (nparms != argc) { + // Let's see if the 'missing' argument are all defaulted. + + // if nparms==0 then either we stopped earlier either argc is also zero and we can't reach here. + assert(nparms > 0); + + TMethodArg *arg = (TMethodArg *) argList->At( 0 ); + if (arg && arg->GetDefault() && arg->GetDefault()[0]) { + // There is a default value for the first missing + // argument, so we are fine. + } else { + Int_t firstDefault = -1; + for (Int_t i = 0; i < nparms; i ++) { + arg = (TMethodArg *) argList->At( i ); + if (arg && arg->GetDefault() && arg->GetDefault()[0]) { + firstDefault = i; + break; + } + } + if (firstDefault >= 0) { + Error("Execute","Too few arguments to call %s, got only %d but expected at least %d and at most %d.",method->GetName(),argc,firstDefault,nparms); + } else { + Error("Execute","Too few arguments to call %s, got only %d but expected %d.",method->GetName(),argc,nparms); + } + return; + } + } const char *listpar = ""; TString complete(10); @@ -1776,7 +1829,7 @@ Int_t TCint::ReloadAllSharedLibraryMaps() Int_t TCint::UnloadAllSharedLibraryMaps() { // Unload the library map entries coming from all the loaded shared libraries. - // Returns 0 if succesful + // Returns 0 if successful const TString sharedLibLStr = GetSharedLibs(); const TObjArray *sharedLibL = sharedLibLStr.Tokenize(" "); @@ -1879,6 +1932,41 @@ Int_t TCint::UnloadLibraryMap(const char *library) return ret; } +//______________________________________________________________________________ +Int_t TCint::SetClassSharedLibs(const char *cls, const char *libs) +{ + // Register the autoloading information for a class. + // libs is a space separated list of libraries. + + if (!cls || !*cls) + return 0; + + G__set_class_autoloading_table((char*)cls,(char*)libs); + + TString key = TString("Library.") + cls; + // convert "::" to "@@", we used "@@" because TEnv + // considers "::" a terminator + key.ReplaceAll("::", "@@"); + // convert "-" to " ", since class names may have + // blanks and TEnv considers a blank a terminator + key.ReplaceAll(" ", "-"); + + R__LOCKGUARD(gCINTMutex); + if (!fMapfile) { + fMapfile = new TEnv(".rootmap"); + fMapfile->IgnoreDuplicates(kTRUE); + + fRootmapFiles = new TObjArray; + fRootmapFiles->SetOwner(); + + // Make sure that this information will be useable by inserting our + // autoload call back! + G__set_class_autoloading_callback(&TCint_AutoLoadCallback); + } + fMapfile->SetValue(key,libs); + return 1; +} + //______________________________________________________________________________ Int_t TCint::AutoLoad(const char *cls) { @@ -1922,9 +2010,22 @@ Int_t TCint::AutoLoad(const char *cls) lib, cls); } delete tokens; + G__set_class_autoloading(oldvalue); + } else { + G__set_class_autoloading(oldvalue); + // Try the cint only autoloading + const char *lib = G__get_class_autoloading_table((char*)cls); + if (lib && lib[0]) { + if (gROOT->LoadClass(cls, lib) == 0) { + if (gDebug > 0) + ::Info("TCint::AutoLoad", "loaded library %s for class %s", + lib, cls); + status = 1; + } else + ::Error("TCint::AutoLoad", "failure loading library %s for class %s", + lib, cls); + } } - - G__set_class_autoloading(oldvalue); return status; } @@ -2153,6 +2254,7 @@ const char* TCint::GetSharedLibs() TRegexp sovers = "\\.[0-9]+\\.*[0-9]*\\.so"; TRegexp dyvers = "\\.[0-9]+\\.*[0-9]*\\.dylib"; TString fname = filename; + Ssiz_t idx; #endif if (!needToSkip && ( @@ -2166,15 +2268,20 @@ const char* TCint::GetSharedLibs() (len>4 && (strcasecmp(end-4,".dll") == 0)) || (len>6 && (strcasecmp(end-6,".dylib") == 0)))) { #if defined(R__MACOSX) - if ((len>5 && fname.Index(sovers) == kNPOS) && - (len>8 && fname.Index(dyvers) == kNPOS)) { -#endif - if (!fSharedLibs.IsNull()) - fSharedLibs.Append(" "); - fSharedLibs.Append(filename); -#if defined(R__MACOSX) + if (len>5 && (idx = fname.Index(sovers)) != kNPOS) { + fname.Remove(idx); + fname += ".so"; + filename = fname; } -#endif + if (len>8 && (idx = fname.Index(dyvers)) != kNPOS) { + fname.Remove(idx); + fname += ".dylib"; + filename = fname; + } +#endif + if (!fSharedLibs.IsNull()) + fSharedLibs.Append(" "); + fSharedLibs.Append(filename); } cursor.Next(); @@ -2494,7 +2601,7 @@ Long_t TCint::CallFunc_ExecInt(CallFunc_t *func, void *address) const return f->ExecInt(address); } //______________________________________________________________________________ -Long_t TCint::CallFunc_ExecInt64(CallFunc_t *func, void *address) const +Long64_t TCint::CallFunc_ExecInt64(CallFunc_t *func, void *address) const { // Interface to CINT function @@ -3171,6 +3278,15 @@ MethodInfo_t *TCint::MethodInfo_Factory() const return info; } //______________________________________________________________________________ +MethodInfo_t *TCint::MethodInfo_Factory(ClassInfo_t * clinfo) const +{ + // Interface to CINT function + G__ClassInfo* clinfo1 = (G__ClassInfo*) clinfo; + if (clinfo1) + return new G__MethodInfo(*clinfo1); + return new G__MethodInfo(); +} +//______________________________________________________________________________ MethodInfo_t *TCint::MethodInfo_FactoryCopy(MethodInfo_t *minfo) const { // Interface to CINT function @@ -3245,6 +3361,14 @@ void *TCint::MethodInfo_Type(MethodInfo_t *minfo) const return info->Type(); } //______________________________________________________________________________ +std::string TCint::MethodInfo_TypeNormalizedName(MethodInfo_t* minfo) const +{ + // Interface to CINT function + + G__MethodInfo *info = (G__MethodInfo*)minfo; + return info->Type()->TrueName(); +} +//______________________________________________________________________________ const char *TCint::MethodInfo_GetMangledName(MethodInfo_t *minfo) const { // Interface to CINT function @@ -3303,6 +3427,15 @@ MethodArgInfo_t *TCint::MethodArgInfo_Factory() const return info; } //______________________________________________________________________________ +MethodArgInfo_t *TCint::MethodArgInfo_Factory(MethodInfo_t * minfo) const +{ + // Interface to CINT function + G__MethodInfo* minfo1 = (G__MethodInfo*)minfo; + if (minfo1) + return new G__MethodArgInfo(*minfo1); + return new G__MethodArgInfo(); +} +//______________________________________________________________________________ MethodArgInfo_t *TCint::MethodArgInfo_FactoryCopy(MethodArgInfo_t *marginfo) const { // Interface to CINT function @@ -3360,6 +3493,12 @@ const char *TCint::MethodArgInfo_TypeName(MethodArgInfo_t *marginfo) const return info->Type()->Name(); } +//______________________________________________________________________________ +std::string TCint::MethodArgInfo_TypeNormalizedName(MethodArgInfo_t* marginfo) const +{ + G__MethodArgInfo *info = (G__MethodArgInfo*)marginfo; + return info->Type()->TrueName(); +} //______________________________________________________________________________ // G__TypeInfo interface @@ -3496,6 +3635,14 @@ Bool_t TCint::TypedefInfo_IsValid(TypedefInfo_t *tinfo) const return info->IsValid(); } //______________________________________________________________________________ +int TCint::TypedefInfo_Next(TypedefInfo_t *tinfo) const +{ + // Interface to CINT function + + G__TypedefInfo *info = (G__TypedefInfo*)tinfo; + return info->Next(); +} +//______________________________________________________________________________ Long_t TCint::TypedefInfo_Property(TypedefInfo_t *tinfo) const { // Interface to CINT function diff --git a/core/meta/src/TCintWithCling.cxx b/core/meta/src/TCintWithCling.cxx index 76b4fc33e09c6..45eec8f5b282d 100644 --- a/core/meta/src/TCintWithCling.cxx +++ b/core/meta/src/TCintWithCling.cxx @@ -4502,7 +4502,7 @@ const char* TCintWithCling::GetInterpreterTypeName(const char* name, Bool_t full // The 'name' is known to the interpreter, this function returns // the internal version of this name (usually just resolving typedefs) // This is used in particular to synchronize between the name used - // by rootcint and by the run-time enviroment (TClass) + // by rootcint and by the run-time environment (TClass) // Return 0 if the name is not known. R__LOCKGUARD(gCINTMutex); if (!gInterpreter->CheckClassInfo(name)) { diff --git a/core/meta/src/TClass.cxx b/core/meta/src/TClass.cxx index 03f3bea3afc1c..12a9dbc07d34c 100644 --- a/core/meta/src/TClass.cxx +++ b/core/meta/src/TClass.cxx @@ -30,6 +30,7 @@ #include "TBaseClass.h" #include "TBrowser.h" #include "TBuffer.h" +#include "TClassAttributeMap.h" #include "TClassGenerator.h" #include "TClassEdit.h" #include "TClassMenuItem.h" @@ -95,7 +96,13 @@ namespace { Int_t TClass::fgClassCount; TClass::ENewType TClass::fgCallingNew = kRealNew; -static std::multimap gObjectVersionRepository; +struct ObjRepoValue { + ObjRepoValue(const TClass *what, Version_t version) : fClass(what),fVersion(version) {} + const TClass *fClass; + Version_t fVersion; +}; +typedef std::multimap RepoCont_t; +static RepoCont_t gObjectVersionRepository; static void RegisterAddressInRepository(const char * /*where*/, void *location, const TClass *what) { @@ -107,15 +114,15 @@ static void RegisterAddressInRepository(const char * /*where*/, void *location, // } else { // Warning(where, "Registering address %p again of class '%s' version %d", location, what->GetName(), version); // } - gObjectVersionRepository.insert(std::pair(location, version)); + gObjectVersionRepository.insert(RepoCont_t::value_type(location, RepoCont_t::mapped_type(what,version))); #if 0 // This code could be used to prevent an address to be registered twice. - std::pair::iterator, Bool_t> tmp = gObjectVersionRepository.insert(std::pair(location, version)); + std::pair tmp = gObjectVersionRepository.insert(RepoCont_t::value_type>(location, RepoCont_t::mapped_type(what,version))); if (!tmp.second) { Warning(where, "Reregistering an object of class '%s' version %d at address %p", what->GetName(), version, p); gObjectVersionRepository.erase(tmp.first); - tmp = gObjectVersionRepository.insert(std::pair(location, version)); + tmp = gObjectVersionRepository.insert(RepoCont_t::value_type>(location, RepoCont_t::mapped_type(what,version))); if (!tmp.second) { Warning(where, "Failed to reregister an object of class '%s' version %d at address %p", what->GetName(), version, location); } @@ -127,10 +134,10 @@ static void UnregisterAddressInRepository(const char * /*where*/, void *location { // Remove an address from the repository of address/object. - std::multimap::iterator cur = gObjectVersionRepository.find(location); + RepoCont_t::iterator cur = gObjectVersionRepository.find(location); for (; cur != gObjectVersionRepository.end();) { - std::multimap::iterator tmp = cur++; - if ((tmp->first == location) && (tmp->second == what->GetClassVersion())) { + RepoCont_t::iterator tmp = cur++; + if ((tmp->first == location) && (tmp->second.fVersion == what->GetClassVersion())) { // -- We still have an address, version match. // Info(where, "Unregistering address %p of class '%s' version %d", location, what->GetName(), what->GetClassVersion()); gObjectVersionRepository.erase(tmp); @@ -141,12 +148,27 @@ static void UnregisterAddressInRepository(const char * /*where*/, void *location } } -static void MoveAddressInRepository(const char *where, void *oldadd, void *newadd, const TClass *what) +static void MoveAddressInRepository(const char * /*where*/, void *oldadd, void *newadd, const TClass *what) { // Register in the repository that an object has moved. - UnregisterAddressInRepository(where,oldadd,what); - RegisterAddressInRepository(where,newadd,what); + // Move not only the object itself but also any base classes or sub-objects. + size_t objsize = what->Size(); + long delta = (char*)newadd - (char*)oldadd; + RepoCont_t::iterator cur = gObjectVersionRepository.find(oldadd); + for (; cur != gObjectVersionRepository.end();) { + RepoCont_t::iterator tmp = cur++; + if (oldadd <= tmp->first && tmp->first < ( ((char*)oldadd) + objsize) ) { + // The location is within the object, let's move it. + + gObjectVersionRepository.insert(RepoCont_t::value_type(((char*)tmp->first)+delta, RepoCont_t::mapped_type(tmp->second.fClass,tmp->second.fVersion))); + gObjectVersionRepository.erase(tmp); + + } else { + // -- No address, version match, we've reached the end. + break; + } + } } //______________________________________________________________________________ @@ -751,7 +773,7 @@ TClass::TClass() : TDictionary(), fStreamerInfo(0), fConversionStreamerInfo(0), fRealData(0), fBase(0), fData(0), fMethod(0), fAllPubData(0), fAllPubMethod(0), - fClassMenuList(0), + fClassMenuList(0), fDeclFileName(""), fImplFileName(""), fDeclFileLine(0), fImplFileLine(0), fInstanceCount(0), fOnHeap(0), fCheckSum(0), fCollectionProxy(0), fClassVersion(0), fClassInfo(0), @@ -762,12 +784,14 @@ TClass::TClass() : fCanSplit(-1), fProperty(0),fVersionUsed(kFALSE), fIsOffsetStreamerSet(kFALSE), fOffsetStreamer(0), fStreamerType(TClass::kDefault), fCurrentInfo(0), fRefStart(0), fRefProxy(0), - fSchemaRules(0), fStreamerImpl(&TClass::StreamerDefault) + fSchemaRules(0), fAttributeMap(0), fStreamerImpl(&TClass::StreamerDefault) + { // Default ctor. R__LOCKGUARD2(gCINTMutex); fDeclFileLine = -2; // -2 for standalone TClass (checked in dtor) + fAttributeMap = 0; } //______________________________________________________________________________ @@ -786,7 +810,7 @@ TClass::TClass(const char *name, Bool_t silent) : fCanSplit(-1), fProperty(0),fVersionUsed(kFALSE), fIsOffsetStreamerSet(kFALSE), fOffsetStreamer(0), fStreamerType(TClass::kDefault), fCurrentInfo(0), fRefStart(0), fRefProxy(0), - fSchemaRules(0), fStreamerImpl(&TClass::StreamerDefault) + fSchemaRules(0), fAttributeMap(0), fStreamerImpl(&TClass::StreamerDefault) { // Create a TClass object. This object contains the full dictionary // of a class. It has list to baseclasses, datamembers and methods. @@ -836,7 +860,7 @@ TClass::TClass(const char *name, Version_t cversion, fCanSplit(-1), fProperty(0),fVersionUsed(kFALSE), fIsOffsetStreamerSet(kFALSE), fOffsetStreamer(0), fStreamerType(TClass::kDefault), fCurrentInfo(0), fRefStart(0), fRefProxy(0), - fSchemaRules(0), fStreamerImpl(&TClass::StreamerDefault) + fSchemaRules(0), fAttributeMap(0), fStreamerImpl(&TClass::StreamerDefault) { // Create a TClass object. This object contains the full dictionary // of a class. It has list to baseclasses, datamembers and methods. @@ -865,7 +889,7 @@ TClass::TClass(const char *name, Version_t cversion, fCanSplit(-1), fProperty(0),fVersionUsed(kFALSE), fIsOffsetStreamerSet(kFALSE), fOffsetStreamer(0), fStreamerType(TClass::kDefault), fCurrentInfo(0), fRefStart(0), fRefProxy(0), - fSchemaRules(0), fStreamerImpl(&TClass::StreamerDefault) + fSchemaRules(0), fAttributeMap(0), fStreamerImpl(&TClass::StreamerDefault) { // Create a TClass object. This object contains the full dictionary // of a class. It has list to baseclasses, datamembers and methods. @@ -1073,12 +1097,19 @@ void TClass::Init(const char *name, Version_t cversion, fCollectionProxy = TVirtualStreamerInfo::Factory()->GenEmulatedProxy( GetName(), silent ); if (fCollectionProxy) { fSizeof = fCollectionProxy->Sizeof(); + + // Numeric Collections have implicit conversions: + GetSchemaRules(kTRUE); + } else if (!silent) { Warning("Init","Collection proxy for %s was not properly initialized!",GetName()); } if (fStreamer==0) { fStreamer = TVirtualStreamerInfo::Factory()->GenEmulatedClassStreamer( GetName(), silent ); } + } else if (!strncmp(GetName(),"std::pair<",10) || !strncmp(GetName(),"pair<",5) ) { + // std::pairs have implicit conversions + GetSchemaRules(kTRUE); } } @@ -1134,6 +1165,7 @@ TClass::TClass(const TClass& cl) : fRefStart(cl.fRefStart), fRefProxy(cl.fRefProxy), fSchemaRules(cl.fSchemaRules), + fAttributeMap(cl.fAttributeMap ? (TClassAttributeMap*)cl.fAttributeMap->Clone() : 0 ), fStreamerImpl(cl.fStreamerImpl) { //copy constructor @@ -1251,6 +1283,8 @@ TClass::~TClass() } delete fConversionStreamerInfo; } + + delete fAttributeMap; } //------------------------------------------------------------------------------ @@ -2069,6 +2103,16 @@ void TClass::CopyCollectionProxy(const TVirtualCollectionProxy &orig) } +//______________________________________________________________________________ +void TClass::CreateAttributeMap() +{ + //Create a TClassAttributeMap for a TClass to be able to add attribute pairs + //key-value to the TClass. + + if (!fAttributeMap) + fAttributeMap = new TClassAttributeMap; +} + //______________________________________________________________________________ void TClass::Draw(Option_t *option) { @@ -2512,8 +2556,13 @@ TClass *TClass::GetClass(const char *name, Bool_t load, Bool_t silent) load = kTRUE; if (splitname.IsSTLCont()) { - + + TClassRef clref = cl; const char * itypename = gCint->GetInterpreterTypeName(name); + // Protect again possible library loading + if (clref->IsLoaded()) { + return clref; + } if (itypename) { std::string altname( TClassEdit::ShortType(itypename, TClassEdit::kDropStlDefault) ); if (altname != name) { @@ -2544,7 +2593,10 @@ TClass *TClass::GetClass(const char *name, Bool_t load, Bool_t silent) if (objType) { const char *typdfName = objType->GetTypeName(); if (typdfName && strcmp(typdfName, name)) { - cl = TClass::GetClass(typdfName, load); + TString alternateName(typdfName); + // TClass::GetClass might get call GetTypeName and thus + // re-use the static storage use by GetTypeName! + cl = TClass::GetClass(alternateName, load); return cl; } } @@ -3023,6 +3075,7 @@ TList *TClass::GetListOfAllPublicMethods() TMethod *p; while ((pB = (TBaseClass*) nextBaseClass())) { if (!pB->GetClassPointer()) continue; + if (!(pB->Property() & kIsPublic)) continue; TIter next(pB->GetClassPointer()->GetListOfAllPublicMethods()); TList temp; while ((p = (TMethod*) next())) @@ -3060,6 +3113,7 @@ TList *TClass::GetListOfAllPublicDataMembers() TBaseClass *pB; while ((pB = (TBaseClass*) next_BaseClass())) { if (!pB->GetClassPointer()) continue; + if (!(pB->Property() & kIsPublic)) continue; fAllPubData->AddAll(pB->GetClassPointer()->GetListOfAllPublicDataMembers() ); } } @@ -3179,12 +3233,33 @@ void TClass::ResetClassInfo(Long_t tagnum) { // Make sure that the current ClassInfo is up to date. - if (fClassInfo && gCint->ClassInfo_Tagnum(fClassInfo) != tagnum) { + if (!fClassInfo || gCint->ClassInfo_Tagnum(fClassInfo) != tagnum) { + if (!fClassInfo) + fClassInfo = gInterpreter->ClassInfo_Factory(); gCint->ClassInfo_Init(fClassInfo,(Int_t)tagnum); - if (fBase) { + + // Make sure to clean out all caches. + + // Not owning lists, don't call Delete() + delete fAllPubData; fAllPubData =0; + delete fAllPubMethod; fAllPubMethod=0; + + if (fBase) fBase->Delete(); - delete fBase; fBase = 0; - } + delete fBase; fBase = 0; + + if (fData) + fData->Delete(); + delete fData; fData = 0; + + if (fMethod) + fMethod->Delete(); + delete fMethod; fMethod=0; + + if (fRealData) + fRealData->Delete(); + delete fRealData; fRealData=0; + } } @@ -4178,7 +4253,7 @@ void TClass::Destructor(void *obj, Bool_t dtorOnly) // Was this object allocated through TClass? std::multiset knownVersions; - std::multimap::iterator iter = gObjectVersionRepository.find(p); + RepoCont_t::iterator iter = gObjectVersionRepository.find(p); if (iter == gObjectVersionRepository.end()) { // No, it wasn't, skip special version handling. //Error("Destructor2", "Attempt to delete unregistered object of class '%s' at address %p!", GetName(), p); @@ -4186,9 +4261,9 @@ void TClass::Destructor(void *obj, Bool_t dtorOnly) } else { //objVer = iter->second; for (; (iter != gObjectVersionRepository.end()) && (iter->first == p); ++iter) { - Version_t ver = iter->second; + Version_t ver = iter->second.fVersion; knownVersions.insert(ver); - if (ver == fClassVersion) { + if (ver == fClassVersion && this == iter->second.fClass) { verFound = kTRUE; } } @@ -4289,16 +4364,16 @@ void TClass::DeleteArray(void *ary, Bool_t dtorOnly) // Was this array object allocated through TClass? std::multiset knownVersions; - std::multimap::iterator iter = gObjectVersionRepository.find(p); + RepoCont_t::iterator iter = gObjectVersionRepository.find(p); if (iter == gObjectVersionRepository.end()) { // No, it wasn't, we cannot know what to do. //Error("DeleteArray", "Attempt to delete unregistered array object, element type '%s', at address %p!", GetName(), p); inRepo = kFALSE; } else { for (; (iter != gObjectVersionRepository.end()) && (iter->first == p); ++iter) { - Version_t ver = iter->second; + Version_t ver = iter->second.fVersion; knownVersions.insert(ver); - if (ver == fClassVersion) { + if (ver == fClassVersion && this == iter->second.fClass ) { verFound = kTRUE; } } @@ -4939,6 +5014,8 @@ UInt_t TClass::GetCheckSum(UInt_t code) const TBaseClass *tbc=0; while((tbc=(TBaseClass*)nextBase())) { name = tbc->GetName(); + if (TClassEdit::IsSTLCont(name)) + name = TClassEdit::ShortType( name, TClassEdit::kDropStlDefault ); il = name.Length(); for (int i=0; iGetStreamerInfos(); TVirtualStreamerInfo* info = 0; - if( version > -1 && version < clSI->GetSize() ) + if( version >= -1 && version < clSI->GetSize() ) info = (TVirtualStreamerInfo*)clSI->At( version ); + if (!info && cl->GetCollectionProxy()) { + info = cl->GetStreamerInfo(); // instantiate the StreamerInfo for STL collections. + } + if( !info ) return 0; @@ -5601,4 +5682,3 @@ ROOT::DirAutoAdd_t TClass::GetDirectoryAutoAdd() const return fDirAutoAdd; } - diff --git a/core/meta/src/TClassAttributeMap.cxx b/core/meta/src/TClassAttributeMap.cxx new file mode 100644 index 0000000000000..8223589ad5950 --- /dev/null +++ b/core/meta/src/TClassAttributeMap.cxx @@ -0,0 +1,112 @@ +// @(#)root/meta:$Id:$ +// Author: Bianca-Cristina Cristescu 03/07/13 + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////// +// // +// The ROOT oject has a list of properties which are stored and // +// retrieved using TClassAttributeMap. // +// TClassAttributeMap maps the property keys of the object to their // +// values. // +// // +////////////////////////////////////////////////////////////////////////// + +#include "TClassAttributeMap.h" +#include "THashTable.h" +#include "TNamed.h" +#include "TParameter.h" + + +ClassImp(TClassAttributeMap) + +//_____________________________________________________________________________ +TClassAttributeMap::TClassAttributeMap() +{ + //Default constructor. + fStringProperty.SetOwner(kTRUE); +} + +//_____________________________________________________________________________ +TClassAttributeMap::~TClassAttributeMap() +{ + //Default destructor. +} + +//_____________________________________________________________________________ +void TClassAttributeMap::AddProperty(const char* key, const char* value) +{ + //Add a property with a String value to the TClassAttributeMap. + //Parameters: key and char* value of the property. + + //Add the property pair name - Int value to the hash table. + fStringProperty.Add(new TNamed(key, value)); +} + +//_____________________________________________________________________________ +Bool_t TClassAttributeMap::HasKey(const char* key) const +{ + + //Check whether the class has a property using the key. + + if (fStringProperty.FindObject(key)) + return true; + return false; +} + +//_____________________________________________________________________________ +const char* TClassAttributeMap::GetPropertyAsString(const char* key) const +{ + //Access the value of a String property using the key. + + //Copy object into found to avoid calling the function two times. + TObject* found = fStringProperty.FindObject(key); + if(found) + return found->GetTitle(); + else + //Show an error message if the key is not found. + Error("GetPropertyAsString" + , "Could not find property with String value for this key: %s", key); + return 0; +} + +//_____________________________________________________________________________ +TString TClassAttributeMap::RemovePropertyString(const char* key) +{ + //Remove a String property from the attribute map specified by the key. + //Returns the TString property removed or NULL if the property does not exist. + + TObject *property = fStringProperty.FindObject(key); + if (property) { + fStringProperty.Remove(property); + return property->GetTitle(); + } + return TString(0); +} + +Bool_t TClassAttributeMap::RemoveProperty(const char* key) +{ + //Remove a property from the attribute map specified by the key. + //Returns true if property exists and was removed, false if property + //does not exist. + + if (TObject *property = fStringProperty.FindObject(key)) { + fStringProperty.Remove(property); + return true; + } + return false; +} + +//_____________________________________________________________________________ +void TClassAttributeMap::Clear(Option_t* /*option = ""*/) +{ + //Deletes all the properties of the class. + + fStringProperty.Delete(); +} diff --git a/core/meta/src/TFunction.cxx b/core/meta/src/TFunction.cxx index e1a7befc633bd..c0b14c4735594 100644 --- a/core/meta/src/TFunction.cxx +++ b/core/meta/src/TFunction.cxx @@ -139,6 +139,19 @@ const char *TFunction::GetReturnTypeName() const return gCint->MethodInfo_TypeName(fInfo); } +//______________________________________________________________________________ +std::string TFunction::GetReturnTypeNormalizedName() const +{ + // Get the normalized name of the return type. A normalized name is fully + // qualified and has all typedef desugared except for the 'special' typedef + // which include Double32_t, Float16_t, [U]Long64_t and std::string. It + // also has std:: removed [This is subject to change]. + // + + if (gCint->MethodInfo_Type(fInfo) == 0) return "Unknown"; + return gCint->MethodInfo_TypeNormalizedName(fInfo); +} + //______________________________________________________________________________ Int_t TFunction::GetNargs() const { @@ -182,7 +195,7 @@ const char *TFunction::GetMangledName() const // of the function. It has to work even if the function has been // unloaded by cint (in which case fInfo is actually hold reference to // memory that is (likely) not valid anymore. So we cache the information. - // Maybe we should also cache the rest of the informations .. but this might + // Maybe we should also cache the rest of the information .. but this might // be too much duplication of information. if (fInfo) return fMangledName; diff --git a/core/meta/src/TMethodArg.cxx b/core/meta/src/TMethodArg.cxx index 27da9ffc159b9..05c7e03139612 100644 --- a/core/meta/src/TMethodArg.cxx +++ b/core/meta/src/TMethodArg.cxx @@ -75,10 +75,22 @@ const char *TMethodArg::GetTypeName() const const char *TMethodArg::GetFullTypeName() const { // Get full type description of method argument, e.g.: "class TDirectory*". - + return gCint->MethodArgInfo_TypeName(fInfo); } +//______________________________________________________________________________ +std::string TMethodArg::GetTypeNormalizedName() const +{ + // Get the normalized name of the return type. A normalized name is fully + // qualified and has all typedef desugared except for the 'special' typedef + // which include Double32_t, Float16_t, [U]Long64_t and std::string. It + // also has std:: removed [This is subject to change]. + // + + return gCint->MethodArgInfo_TypeNormalizedName(fInfo); +} + //______________________________________________________________________________ Long_t TMethodArg::Property() const { diff --git a/core/meta/src/TSchemaRule.cxx b/core/meta/src/TSchemaRule.cxx index 40393bc3e46a1..57eae6ba1e957 100644 --- a/core/meta/src/TSchemaRule.cxx +++ b/core/meta/src/TSchemaRule.cxx @@ -343,6 +343,10 @@ Bool_t TSchemaRule::TestVersion( Int_t version ) const if( !fVersionVect ) ProcessVersion( fVersion ); // At this point the version string should always be correct + if (version == -1) { + version = 1; + } + std::vector >::iterator it; for( it = fVersionVect->begin(); it != fVersionVect->end(); ++it ) { if( version >= it->first && version <= it->second ) diff --git a/core/meta/src/TSchemaRuleSet.cxx b/core/meta/src/TSchemaRuleSet.cxx index fcf002210f665..bbb99aa2c229f 100644 --- a/core/meta/src/TSchemaRuleSet.cxx +++ b/core/meta/src/TSchemaRuleSet.cxx @@ -9,6 +9,11 @@ #include "TROOT.h" #include "Riostream.h" +#include "TVirtualCollectionProxy.h" +#include "TVirtualStreamerInfo.h" +#include "TStreamerElement.h" +#include "TClassEdit.h" + ClassImp(TSchemaRule) using namespace ROOT; @@ -186,6 +191,80 @@ Bool_t TSchemaRuleSet::HasRuleWithSourceClass( const TString &source ) const if( rule->GetSourceClass() == source ) return kTRUE; } + // There was no explicit rule, let's see we have implicit rules. + if (fClass->GetCollectionProxy()) { + if (fClass->GetCollectionProxy()->GetValueClass() == 0) { + // We have a numeric collection, let see if the target is + // also a numeric collection. + TClass *src = TClass::GetClass(source); + if (src && src->GetCollectionProxy() && + src->GetCollectionProxy()->HasPointers() == fClass->GetCollectionProxy()->HasPointers()) { + TVirtualCollectionProxy *proxy = src->GetCollectionProxy(); + if (proxy->GetValueClass() == 0) { + return kTRUE; + } + } + } else { + TClass *vTargetClass = fClass->GetCollectionProxy()->GetValueClass(); + TClass *src = TClass::GetClass(source); + if (vTargetClass->GetSchemaRules()) { + if (src && src->GetCollectionProxy() && + src->GetCollectionProxy()->HasPointers() == fClass->GetCollectionProxy()->HasPointers()) { + TClass *vSourceClass = src->GetCollectionProxy()->GetValueClass(); + if (vSourceClass) { + return vTargetClass->GetSchemaRules()->HasRuleWithSourceClass( vSourceClass->GetName() ); + } + } + } + } + } else if (!strncmp(fClass->GetName(),"std::pair<",10) || !strncmp(fClass->GetName(),"pair<",5)) { + if (!strncmp(source,"std::pair<",10) || !strncmp(source,"pair<",5)) { + // std::pair can be converted into each other if both its parameter can be converted into + // each other. + TClass *src = TClass::GetClass(source); + if (!src) { + Error("HasRuleWithSourceClass","Can not find the TClass for %s when matching with %s\n",source.Data(),fClass->GetName()); + return kFALSE; + } + TVirtualStreamerInfo *sourceInfo = src->GetStreamerInfo(); + TVirtualStreamerInfo *targetInfo = fClass->GetStreamerInfo(); + if (!sourceInfo) { + Error("HasRuleWithSourceClass","Can not find the StreamerInfo for %s when matching with %s\n",source.Data(),fClass->GetName()); + return kFALSE; + } + if (!targetInfo) { + Error("HasRuleWithSourceClass","Can not find the StreamerInfo for target class %s\n",fClass->GetName()); + return kFALSE; + } + for(int i = 0 ; i<2 ; ++i) { + TStreamerElement *sourceElement = (TStreamerElement*)sourceInfo->GetElements()->At(i); + TStreamerElement *targetElement = (TStreamerElement*)sourceInfo->GetElements()->At(i); + if (sourceElement->GetClass()) { + if (!targetElement->GetClass()) { + return kFALSE; + } + if (sourceElement->GetClass() == targetElement->GetClass()) { + continue; + } + TSchemaRuleSet *rules = sourceElement->GetClass()->GetSchemaRules(); + if (!rules || !rules->HasRuleWithSourceClass( targetElement->GetClass()->GetName() ) ) { + return kFALSE; + } + } else if (targetElement->GetClass()) { + return kFALSE; + } else { + // both side are numeric element we can deal with it. + } + } + // Both side are pairs and have convertible types, let records this as a renaming rule + ROOT::TSchemaRule *ruleobj = new ROOT::TSchemaRule(); + ruleobj->SetSourceClass(source); + ruleobj->SetTargetClass(fClass->GetName()); + ruleobj->SetVersion("[1-]"); + const_cast(this)->AddRule(ruleobj); + return kTRUE; + } + } return kFALSE; } @@ -204,6 +283,26 @@ const TObjArray* TSchemaRuleSet::FindRules( const TString &source ) const if( rule->GetSourceClass() == source ) arr->Add( rule ); } + +#if 0 + // Le't's see we have implicit rules. + if (fClass->GetCollectionProxy()) { + if (fClass->GetCollectionProxy()->GetValueClass() == 0 + && (fClass->GetCollectionProxy()->GetCollectionType() == TClassEdit::kVector + || (fClass->GetCollectionProxy()->GetProperties() & TVirtualCollectionProxy::kIsEmulated))) { + // We have a numeric collection, let see if the target is + // also a numeric collection (humm just a vector for now) + TClass *src = TClass::GetClass(source); + if (src && src->GetCollectionProxy()) { + TVirtualCollectionProxy *proxy = src->GetCollectionProxy(); + if (proxy->GetValueClass() == 0) { + // ... would need to check if we already have + // the rule (or any rule?) + } + } + } + } +#endif return arr; } diff --git a/core/meta/src/TStreamerElement.cxx b/core/meta/src/TStreamerElement.cxx index cc2e1dee66177..52b8c631785a0 100644 --- a/core/meta/src/TStreamerElement.cxx +++ b/core/meta/src/TStreamerElement.cxx @@ -32,6 +32,7 @@ #include "TError.h" #include "TDataType.h" #include "TVirtualMutex.h" +#include "TVirtualCollectionProxy.h" #include #include @@ -252,7 +253,8 @@ TClass *TStreamerElement::GetClassPointer() const if (fClassObject!=(TClass*)(-1)) return fClassObject; TString className = fTypeName.Strip(TString::kTrailing, '*'); if (className.Index("const ")==0) className.Remove(0,6); - ((TStreamerElement*)this)->fClassObject = TClass::GetClass(className); + bool quiet = fType == TVirtualStreamerInfo::kArtificial; + ((TStreamerElement*)this)->fClassObject = TClass::GetClass(className,kTRUE,quiet); return fClassObject; } @@ -303,6 +305,41 @@ const char *TStreamerElement::GetFullName() const return name; } +//______________________________________________________________________________ +void TStreamerElement::GetSequenceType(TString &sequenceType) const +{ + // Fill type with the string representation of sequence + // information including 'cached','repeat','write' or + // 'nodelete'. + + sequenceType.Clear(); + Bool_t first = kTRUE; + if (TestBit(TStreamerElement::kWholeObject)) { + if (!first) sequenceType += ","; + first = kFALSE; + sequenceType += "wholeObject"; + } + if (TestBit(TStreamerElement::kCache)) { + first = kFALSE; + sequenceType += "cached"; + } + if (TestBit(TStreamerElement::kRepeat)) { + if (!first) sequenceType += ","; + first = kFALSE; + sequenceType += "repeat"; + } + if (TestBit(TStreamerElement::kDoNotDelete)) { + if (!first) sequenceType += ","; + first = kFALSE; + sequenceType += "nodelete"; + } + if (TestBit(TStreamerElement::kWrite)) { + if (!first) sequenceType += ","; + first = kFALSE; + sequenceType += "write"; + } +} + //______________________________________________________________________________ Int_t TStreamerElement::GetSize() const { @@ -373,9 +410,16 @@ void TStreamerElement::ls(Option_t *) const TString temp(GetTypeName()); if (IsaPointer() && !fTypeName.Contains("*")) temp += "*"; + + TString sequenceType; + GetSequenceType(sequenceType); + if (sequenceType.Length()) { + sequenceType.Prepend(" ("); + sequenceType += ") "; + } printf(" %-14s %-15s offset=%3d type=%2d %s%-20s\n", - temp.Data(),GetFullName(),fOffset,fType,TestBit(kCache)?"(cached) ":"", - GetTitle()); + temp.Data(),GetFullName(),fOffset,fType,sequenceType.Data(), + GetTitle()); } //______________________________________________________________________________ @@ -462,6 +506,7 @@ void TStreamerElement::Streamer(TBuffer &R__b) R__b.SetBufferOffset(R__s+R__c+sizeof(UInt_t)); ResetBit(TStreamerElement::kCache); + ResetBit(TStreamerElement::kWrite); } else { R__b.WriteClassBuffer(TStreamerElement::Class(),this); } @@ -521,7 +566,8 @@ TStreamerBase::TStreamerBase(const char *name, const char *title, Int_t offset) if (strcmp(name,"TNamed") == 0) fType = TVirtualStreamerInfo::kTNamed; fNewType = fType; fBaseClass = TClass::GetClass(GetName()); - fBaseVersion = fBaseClass->GetClassVersion(); + if (fBaseClass) fBaseVersion = fBaseClass->GetClassVersion(); + else fBaseVersion = 0; fNewBaseClass = 0; Init(); } @@ -590,7 +636,13 @@ void TStreamerBase::ls(Option_t *) const { // Print the content of the element. - printf(" %-14s %-15s offset=%3d type=%2d %s%-20s\n",GetFullName(),GetTypeName(),fOffset,fType,TestBit(kCache)?"(cached) ":"",GetTitle()); + TString sequenceType; + GetSequenceType(sequenceType); + if (sequenceType.Length()) { + sequenceType.Prepend(" ("); + sequenceType += ") "; + } + printf(" %-14s %-15s offset=%3d type=%2d %s%-20s\n",GetFullName(),GetTypeName(),fOffset,fType,sequenceType.Data(),GetTitle()); } //______________________________________________________________________________ @@ -1507,6 +1559,37 @@ TStreamerSTL::TStreamerSTL() : fSTLtype(0),fCtype(0) } +//______________________________________________________________________________ +TStreamerSTL::TStreamerSTL(const char *name, const char *title, Int_t offset, + const char *typeName, const TVirtualCollectionProxy &proxy, Bool_t dmPointer) + : TStreamerElement(name,title,offset,kSTL,typeName) +{ + // Create a TStreamerSTL object. + + fTypeName = TClassEdit::ShortType(fTypeName,TClassEdit::kDropStlDefault).c_str(); + + if (name==typeName /* intentional pointer comparison */ + || strcmp(name,typeName)==0) { + // We have a base class. + fName = fTypeName; + } + fSTLtype = proxy.GetCollectionType(); + fCtype = 0; + + if (dmPointer) fSTLtype += TVirtualStreamerInfo::kOffsetP; + + if (fSTLtype == kSTLbitset) { + // Nothing to check + } else if (proxy.GetValueClass()) { + if (proxy.HasPointers()) fCtype = TVirtualStreamerInfo::kObjectp; + else fCtype = TVirtualStreamerInfo::kObject; + } else { + fCtype = proxy.GetType(); + if (proxy.HasPointers()) fCtype += TVirtualStreamerInfo::kOffsetP; + } + if (TStreamerSTL::IsaPointer()) fType = TVirtualStreamerInfo::kSTLp; +} + //______________________________________________________________________________ TStreamerSTL::TStreamerSTL(const char *name, const char *title, Int_t offset, const char *typeName, const char *trueType, Bool_t dmPointer) @@ -1530,7 +1613,7 @@ TStreamerSTL::TStreamerSTL(const char *name, const char *title, Int_t offset, strlcpy(s,t,nch+1); char *sopen = strchr(s,'<'); if (sopen == 0) { - Fatal("TStreamerSTL","For %s, the type name (%s) is not seemingly not a template (template argument not found)", name, s); + Fatal("TStreamerSTL","For %s, the type name (%s) is seemingly not a template (template argument not found)", name, s); return; } *sopen = 0; sopen++; @@ -1700,9 +1783,15 @@ void TStreamerSTL::ls(Option_t *) const cdim.Form("[%d]",fMaxIndex[i]); name += cdim; } + TString sequenceType; + GetSequenceType(sequenceType); + if (sequenceType.Length()) { + sequenceType.Prepend(" ("); + sequenceType += ") "; + } printf(" %-14s %-15s offset=%3d type=%2d %s,stl=%d, ctype=%d, %-20s\n", - GetTypeName(),name.Data(),fOffset,fType,TestBit(kCache)?"(cached)":"", - fSTLtype,fCtype,GetTitle()); + GetTypeName(),name.Data(),fOffset,fType,sequenceType.Data(), + fSTLtype,fCtype,GetTitle()); } //______________________________________________________________________________ @@ -1715,8 +1804,8 @@ const char *TStreamerSTL::GetInclude() const else if (fSTLtype == kSTLdeque) gIncludeName.Form("<%s>","deque"); else if (fSTLtype == kSTLmap) gIncludeName.Form("<%s>","map"); else if (fSTLtype == kSTLset) gIncludeName.Form("<%s>","set"); - else if (fSTLtype == kSTLmultimap) gIncludeName.Form("<%s>","multimap"); - else if (fSTLtype == kSTLmultiset) gIncludeName.Form("<%s>","multiset"); + else if (fSTLtype == kSTLmultimap) gIncludeName.Form("<%s>","map"); + else if (fSTLtype == kSTLmultiset) gIncludeName.Form("<%s>","set"); else if (fSTLtype == kSTLbitset) gIncludeName.Form("<%s>","bitset"); return gIncludeName; } @@ -1747,6 +1836,18 @@ void TStreamerSTL::Streamer(TBuffer &R__b) R__b >> fCtype; R__b.CheckByteCount(R__s, R__c, TStreamerSTL::IsA()); } + if (fSTLtype == kSTLmultimap || fSTLtype == kSTLset) { + // For a long time those where inverted compared to the other + // definitions. When we move to version 'x', this got standardized, + // but we now need to fix it. + + if (fTypeName.BeginsWith("std::set") || fTypeName.BeginsWith("set")) { + fSTLtype = kSTLset; + } else if (fTypeName.BeginsWith("std::multimap") || fTypeName.BeginsWith("multimap")) { + fSTLtype = kSTLmultimap; + } + } + if (IsaPointer()) fType = TVirtualStreamerInfo::kSTLp; else fType = TVirtualStreamerInfo::kSTL; if (GetArrayLength() > 0) { diff --git a/proof/clarens/inc/TSAM.h b/core/metautils/inc/ESTLType.h similarity index 50% rename from proof/clarens/inc/TSAM.h rename to core/metautils/inc/ESTLType.h index ca9e5c71d988c..ef2cb1f013cff 100644 --- a/proof/clarens/inc/TSAM.h +++ b/core/metautils/inc/ESTLType.h @@ -1,51 +1,45 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 07/11/2004 +// @(#)root/metautils: +// Author: Philippe Canal November 2013 /************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * + * Copyright (C) 1995-2003, Rene Brun and Fons Rademakers. * * All rights reserved. * * * * For the licensing terms see $ROOTSYS/LICENSE. * * For the list of contributors see $ROOTSYS/README/CREDITS. * *************************************************************************/ -#ifndef ROOT_TSAM -#define ROOT_TSAM +#ifndef ROOT_ESTLType +#define ROOT_ESTLType + ////////////////////////////////////////////////////////////////////////// // // -// TSAM // +// ROOT::ESTLType // // // +// Enum describing STL collections and some std classes // +// This is used in TClassEdit, TStreamerInfo, TClassEdit // +// and TStreamerElement. // // // ////////////////////////////////////////////////////////////////////////// -#ifndef ROOT_TObject -#include "TObject.h" -#endif - -#ifndef ROOT_TClProxy -#include "TClProxy.h" -#endif - +namespace ROOT { -class TList; -class TString; -class TXmlRpc; + enum ESTLType { + kNotSTL = 0, + kSTLvector = 1, + kSTLlist = 2, + kSTLdeque = 3, + kSTLmap = 4, + kSTLmultimap = 5, + kSTLset = 6, + kSTLmultiset = 7, + kSTLbitset = 8, + kSTLany = 300 /* TVirtualStreamerInfo::kSTL */, + kSTLstring = 365 /* TVirtualStreamerInfo::kSTLstring */ + }; - -class TSAM : public TClProxy { -public: - TSAM(TXmlRpc *rpc); - virtual ~TSAM() { } - - Bool_t GetVersion(TString &version); - - Bool_t GetDatasets(TList *&datasets); - Bool_t GetDSetLocations(const Char_t *dataset, TList *&lmUrls); - Bool_t GetDSetFiles(const Char_t *dataset, const Char_t *lmUrl, TList *&files); - Bool_t GetDSetSize(const Char_t *dataset, Long64_t &size); - - ClassDef(TSAM,0); // PEAC SAM proxy -}; +} #endif + diff --git a/core/metautils/inc/TClassEdit.h b/core/metautils/inc/TClassEdit.h index bd396c0ae5aed..b575a9072acef 100644 --- a/core/metautils/inc/TClassEdit.h +++ b/core/metautils/inc/TClassEdit.h @@ -17,6 +17,10 @@ #include #include +#ifndef ROOT_ESTLType +#include "ESTLType.h" +#endif + #ifdef R__OLDHPACC namespace std { using ::string; @@ -46,15 +50,15 @@ namespace TClassEdit { }; enum ESTLType { - kNotSTL = 0, - kVector = 1, - kList = 2, - kDeque = 3, - kMap = 4, - kMultiMap = 5, - kSet = 6, - kMultiSet = 7, - kBitSet = 8, + kNotSTL = ROOT::kNotSTL, + kVector = ROOT::kSTLvector, + kList = ROOT::kSTLlist, + kDeque = ROOT::kSTLdeque, + kMap = ROOT::kSTLmap, + kMultiMap = ROOT::kSTLmultimap, + kSet = ROOT::kSTLset, + kMultiSet = ROOT::kSTLmultiset, + kBitSet = ROOT::kSTLbitset, kEnd = 9 }; diff --git a/core/metautils/src/RConversionRuleParser.cxx b/core/metautils/src/RConversionRuleParser.cxx index 536ba5ab8113c..f9becc090085d 100644 --- a/core/metautils/src/RConversionRuleParser.cxx +++ b/core/metautils/src/RConversionRuleParser.cxx @@ -12,13 +12,15 @@ namespace ROOT { + typedef std::list > SourceTypeList_t; + //-------------------------------------------------------------------------- // Allocate global variables //-------------------------------------------------------------------------- SchemaRuleClassMap_t G__ReadRules; SchemaRuleClassMap_t G__ReadRawRules; - static Bool_t ValidateRule( const std::map& rule, string &error_string ); + static Bool_t ValidateRule( const std::map& rule, std::string &error_string ); static std::string::size_type FindEndSymbol(std::string &command) { @@ -206,7 +208,7 @@ namespace ROOT } //-------------------------------------------------------------------------- - static Bool_t ValidateRule( const std::map& rule, string &error_string ) + static Bool_t ValidateRule( const std::map& rule, std::string &error_string ) { // Validate if the user specified rules are correct @@ -323,7 +325,24 @@ namespace ROOT } //----------------------------------------------------------------------- - // Check if we have an embed aparameter and if so if it has been set to + // Check the source contains proper declarations. + //----------------------------------------------------------------------- + it1 = rule.find("code"); + if (it1 != rule.end() && it1->second != "") { + SourceTypeList_t source; + TSchemaRuleProcessor::SplitDeclaration( rule.find("source")->second, source ); + SourceTypeList_t::const_iterator it; + for( it = source.begin(); it != source.end(); ++it ) { + if ( ( it->first.fType == "" && it->second != "") ) { + error_string = warning + " - type required when listing a rule's source: "; + error_string += "source=\""+ rule.find("source")->second +"\""; + return false; + } + } + } + + //----------------------------------------------------------------------- + // Check if we have an embed parameter and if so if it has been set to // the right value //----------------------------------------------------------------------- it1 = rule.find( "embed" ); @@ -413,7 +432,6 @@ namespace ROOT return true; } - typedef std::list > SourceTypeList_t; //-------------------------------------------------------------------------- static void WriteAutoVariables( const std::list& target, const SourceTypeList_t& source, @@ -812,7 +830,8 @@ namespace ROOT std::string error_string; if( !ParseRule( args, rule, error_string ) ) { std::cout << error_string << '\n'; - std::cout << "The rule has been omited!" << std::endl; + std::cout << "The following rule has been omited:" << std::endl; + std::cout << " read " << args << std::endl; return; } @@ -843,7 +862,8 @@ namespace ROOT std::string error_string; if( !ParseRule( args, rule, error_string ) ) { std::cout << error_string << '\n'; - std::cout << "The rule has been omited!" << std::endl; + std::cout << "The following rule has been omited:" << std::endl; + std::cout << " readraw " << args << std::endl; return; } diff --git a/core/metautils/src/TClassEdit.cxx b/core/metautils/src/TClassEdit.cxx index 6d5fdd9e5a387..a214d2278717f 100644 --- a/core/metautils/src/TClassEdit.cxx +++ b/core/metautils/src/TClassEdit.cxx @@ -278,7 +278,8 @@ int TClassEdit::STLArgs(int kind) // Return number of arguments for STL container before allocator static const char stln[] =// min number of container arguments - { 1, 1, 1, 1, 3, 3, 2, 2 }; + // vector, list, deque, map, multimap, set, multiset, bitset + { 1, 1, 1, 1, 3, 3, 2, 2, 1 }; return stln[kind]; } diff --git a/core/pcre/CMakeLists.txt b/core/pcre/CMakeLists.txt index b395150312ae5..1cd07f04e15b4 100644 --- a/core/pcre/CMakeLists.txt +++ b/core/pcre/CMakeLists.txt @@ -32,8 +32,8 @@ if(WIN32) COMMAND cmake -E copy_directory ${PCRE_SRCDIR}/win32 win32 COMMAND cmake -E tar xvzf ${PCRE_TARGZFILE} COMMAND cmake -E chdir win32 nmake -nologo -f Makefile.msc - CFG=${pcrebuild} - NMCXXFLAGS="-I${CMAKE_SOURCE_DIR}/build/win -FIw32pragma.h") + CFG=${pcrebuild} + NMCXXFLAGS="${BLDCXXFLAGS} -I${CMAKE_SOURCE_DIR}/build/win -FIw32pragma.h") else() set(pcreliba ${CMAKE_CURRENT_BINARY_DIR}/${PCRE_VERSION}/.libs/libpcre.a) set(pcrelib ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/libpcre.a) diff --git a/core/pcre/Module.mk b/core/pcre/Module.mk index 81e8697e9f609..73cfe5690c986 100644 --- a/core/pcre/Module.mk +++ b/core/pcre/Module.mk @@ -103,6 +103,10 @@ else if [ $(ARCH) = "linuxx8664icc" ]; then \ PCRE_CFLAGS="-m64"; \ fi; \ + if [ $(ARCH) = "linuxx8664k1omicc" ]; then \ + PCRE_CFLAGS="-m64 $(MICFLAGS)"; \ + PCRE_HOST="--host=x86_64-unknown-linux-gnu"; \ + fi; \ if [ $(ARCH) = "macosx" ]; then \ PCRE_CFLAGS="-m32"; \ fi; \ diff --git a/core/pcre/src/win32/README b/core/pcre/src/win32/README index ba286c44bf4e6..661491b7a681e 100644 --- a/core/pcre/src/win32/README +++ b/core/pcre/src/win32/README @@ -1,37 +1,37 @@ -=========================================================== -Building pcre on Windows -=========================================================== - -Usage: - nmake -f Makefile.msc CFG="libpcre - Win32 Release" -or for the debug version: - nmake -f Makefile.msc CFG="libpcre - Win32 Debug" - -When changing the version of pcre, please change the -version in these two lines in Makefile.msc: - -SRCDIR = pcre-X.X -LIBRARY = libpcre-X.X -=========================================================== - -=========================================================== -In case of problem, here is a couple of things to check: -=========================================================== - -In case of an undefined symbol, check in which file the -missing symbol is. if it is in pcre.h.in, compare the file -pcre.h in this directory (win32) and pcre.h.in the pcre -distribution to see if any definition has changed or has -been added. If it is the case, modify pcre.h and try again - -In case of unresolved external symbol, check in which -source file (from the pcre distribution) the symbol is -and make sure this file is in the list of object files -in Makefile.msc: -OBJS = "../$(SRCDIR)/pcre_chartables.obj" \ -[...] - "../$(SRCDIR)/pcreposix.obj" - -If the file is missing, just add it in the list with the -same format than the others -=========================================================== +=========================================================== +Building pcre on Windows +=========================================================== + +Usage: + nmake -f Makefile.msc CFG="libpcre - Win32 Release" +or for the debug version: + nmake -f Makefile.msc CFG="libpcre - Win32 Debug" + +When changing the version of pcre, please change the +version in these two lines in Makefile.msc: + +SRCDIR = pcre-X.X +LIBRARY = libpcre-X.X +=========================================================== + +=========================================================== +In case of problem, here is a couple of things to check: +=========================================================== + +In case of an undefined symbol, check in which file the +missing symbol is. if it is in pcre.h.in, compare the file +pcre.h in this directory (win32) and pcre.h.in the pcre +distribution to see if any definition has changed or has +been added. If it is the case, modify pcre.h and try again + +In case of unresolved external symbol, check in which +source file (from the pcre distribution) the symbol is +and make sure this file is in the list of object files +in Makefile.msc: +OBJS = "../$(SRCDIR)/pcre_chartables.obj" \ +[...] + "../$(SRCDIR)/pcreposix.obj" + +If the file is missing, just add it in the list with the +same format than the others +=========================================================== diff --git a/core/rint/inc/TTabCom.h b/core/rint/inc/TTabCom.h index da8a62d5a574b..f8ad09c1ff72e 100644 --- a/core/rint/inc/TTabCom.h +++ b/core/rint/inc/TTabCom.h @@ -232,7 +232,7 @@ class TTabCom { Bool_t fVarIsPointer; // frodo: pointer or not flag Int_t fLastIter; // frodo: iteration counter for recursive MakeClassFromVarName - ClassDef(TTabCom,0) //Perform comand line completion when hitting + ClassDef(TTabCom,0) //Perform command line completion when hitting }; R__EXTERN TTabCom *gTabCom; diff --git a/core/rint/src/TRint.cxx b/core/rint/src/TRint.cxx index b8c1947cf70d4..1b3b04cda938f 100644 --- a/core/rint/src/TRint.cxx +++ b/core/rint/src/TRint.cxx @@ -426,10 +426,6 @@ void TRint::Run(Bool_t retrn) } } ENDTRY; - // Allow end-of-file on the terminal to be noticed - // after we finish processing the command line input files. - fInputHandler->Activate(); - if (QuitOpt()) { if (retrn) return; if (error) { @@ -441,6 +437,10 @@ void TRint::Run(Bool_t retrn) Terminate(retval); } + // Allow end-of-file on the terminal to be noticed + // after we finish processing the command line input files. + fInputHandler->Activate(); + ClearInputFiles(); if (needGetlinemInit) Getlinem(kInit, GetPrompt()); @@ -486,8 +486,8 @@ void TRint::PrintLogo(Bool_t lite) Printf(" *******************************************\n"); } - Printf("ROOT %s (%s@%d, %s on %s)", root_version, gROOT->GetSvnBranch(), - gROOT->GetSvnRevision(), gROOT->GetSvnDate(), + Printf("ROOT %s (%s@%s, %s on %s)", root_version, gROOT->GetGitBranch(), + gROOT->GetGitCommit(), gROOT->GetGitDate(), gSystem->GetBuildArch()); if (!lite) diff --git a/core/rint/src/TTabCom.cxx b/core/rint/src/TTabCom.cxx index 66034cf395aae..2a01f73c65fbd 100644 --- a/core/rint/src/TTabCom.cxx +++ b/core/rint/src/TTabCom.cxx @@ -146,8 +146,6 @@ #define IfDebug(x) if(gDebug==TTabCom::kDebug) x #ifdef R__WIN32 -#undef tmpnam -#define tmpnam(a) _tempnam(a, 0) const char kDelim = ';'; #else const char kDelim = ':'; @@ -428,19 +426,18 @@ const TSeqCollection *TTabCom::GetListOfClasses() // Return the list of classes. if (!fpClasses) { // generate a text list of classes on disk - const char *tmpfilename = tmpnam(0); - if (!tmpfilename) return 0; - FILE *fout = fopen(tmpfilename, "w"); + TString outf = ".TTabCom-"; + FILE *fout = gSystem->TempFileName(outf); if (!fout) return 0; gCint->DisplayClass(fout, (char*)"", 0, 0); fclose(fout); // open the file - ifstream file1(tmpfilename); + ifstream file1(outf); if (!file1) { Error("TTabCom::GetListOfClasses", "could not open file \"%s\"", - tmpfilename); - gSystem->Unlink(tmpfilename); + outf.Data()); + gSystem->Unlink(outf); return 0; } // skip the first 2 lines (which are just header info) @@ -494,7 +491,7 @@ const TSeqCollection *TTabCom::GetListOfClasses() // done with this file file1.close(); - gSystem->Unlink(tmpfilename); + gSystem->Unlink(outf); } return fpClasses; @@ -550,8 +547,10 @@ const TSeqCollection *TTabCom::GetListOfEnvVars() // Uses "env" (Unix) or "set" (Windows) to get list of environment variables. if (!fpEnvVars) { - const char *tmpfilename = tmpnam(0); - if (!tmpfilename) return 0; + TString outf = ".TTabCom-"; + FILE *fout = gSystem->TempFileName(outf); + if (!fout) return 0; + fclose(fout); TString cmd; #ifndef WIN32 @@ -564,16 +563,16 @@ const TSeqCollection *TTabCom::GetListOfEnvVars() #else cmd = "set > "; #endif - cmd += tmpfilename; + cmd += outf; cmd += "\n"; gSystem->Exec(cmd.Data()); // open the file - ifstream file1(tmpfilename); + ifstream file1(outf); if (!file1) { Error("TTabCom::GetListOfEnvVars", "could not open file \"%s\"", - tmpfilename); - gSystem->Unlink(tmpfilename); + outf.Data()); + gSystem->Unlink(outf); return 0; } // parse, add @@ -589,7 +588,7 @@ const TSeqCollection *TTabCom::GetListOfEnvVars() } file1.close(); - gSystem->Unlink(tmpfilename); + gSystem->Unlink(outf); } return fpEnvVars; @@ -893,13 +892,15 @@ TString TTabCom::DetermineClass(const char varName[]) assert(varName != 0); IfDebug(cerr << "DetermineClass(\"" << varName << "\");" << endl); - const char *tmpfile = tmpnam(0); - if (!tmpfile) return ""; + TString outf = ".TTabCom-"; + FILE *fout = gSystem->TempFileName(outf); + if (!fout) return ""; + fclose(fout); TString cmd("gROOT->ProcessLine(\""); cmd += varName; cmd += "\"); > "; - cmd += tmpfile; + cmd += outf; cmd += "\n"; gROOT->ProcessLineSync(cmd.Data()); @@ -910,10 +911,10 @@ TString TTabCom::DetermineClass(const char varName[]) int c; // open the file - ifstream file1(tmpfile); + ifstream file1(outf); if (!file1) { Error("TTabCom::DetermineClass", "could not open file \"%s\"", - tmpfile); + outf.Data()); goto cleanup; } // first char should be '(', which we can ignore. @@ -953,7 +954,7 @@ TString TTabCom::DetermineClass(const char varName[]) cleanup: // done reading from file file1.close(); - gSystem->Unlink(tmpfile); + gSystem->Unlink(outf); return type; } @@ -1043,20 +1044,18 @@ TString TTabCom::GetSysIncludePath() // get this part of the include path from the interpreter // and stick it in a tmp file. - const char *tmpfilename = tmpnam(0); - if (!tmpfilename) return ""; - - FILE *fout = fopen(tmpfilename, "w"); + TString outf = ".TTabCom-"; + FILE *fout = gSystem->TempFileName(outf); if (!fout) return ""; gCint->DisplayIncludePath(fout); fclose(fout); // open the tmp file - ifstream file1(tmpfilename); + ifstream file1(outf); if (!file1) { // error Error("TTabCom::GetSysIncludePath", "could not open file \"%s\"", - tmpfilename); - gSystem->Unlink(tmpfilename); + outf.Data()); + gSystem->Unlink(outf); return ""; } // parse it. @@ -1075,7 +1074,7 @@ TString TTabCom::GetSysIncludePath() // done with the tmp file file1.close(); - gSystem->Unlink(tmpfilename); + gSystem->Unlink(outf); // 3) standard directories // ---------------------------------------------- @@ -1108,9 +1107,9 @@ Bool_t TTabCom::IsDirectory(const char fileName[]) /////////////////////////////////////////////////////// FileStat_t stat; - if (!gSystem->GetPathInfo(fileName, stat)) + if (!gSystem->GetPathInfo(fileName, stat)) return R_ISDIR(stat.fMode); - else + else return false; } @@ -1596,7 +1595,7 @@ TString TTabCom::DeterminePath(const TString & fileName, IfDebug(cerr << " defaultPath: " << defaultPath << endl); } else { IfDebug(cerr << " defaultPath: " << endl); - } + } IfDebug(cerr << "extendedPath: " << extendedPath << endl); IfDebug(cerr << endl); diff --git a/core/textinput/src/textinput/Editor.cpp b/core/textinput/src/textinput/Editor.cpp index 070f184e0ec80..5f1165fed16fb 100644 --- a/core/textinput/src/textinput/Editor.cpp +++ b/core/textinput/src/textinput/Editor.cpp @@ -143,6 +143,8 @@ namespace textinput { void Editor::CancelSpecialInputMode(Range& DisplayR) { + // Stop incremental history search, leaving text at the + // history line currently selected. if (fMode == kInputMode) return; fContext->GetKeyBinding()->EnableEscCmd(false); SetEditorPrompt(Text()); @@ -150,6 +152,16 @@ namespace textinput { fMode = kInputMode; } + void + Editor::CancelAndRevertSpecialInputMode(EditorRange& R) { + // Stop incremental history search, reset text to what it was + // before search started. + if (fMode == kInputMode) return; + CancelSpecialInputMode(R.fDisplay); + // Original line should be top of undo buffer. + ProcessCommand(kCmdUndo, R); + } + Editor::EProcessResult Editor::ProcessChar(char C, EditorRange& R) { if (C < 32) return kPRError; @@ -186,6 +198,14 @@ namespace textinput { Editor::EProcessResult Editor::ProcessMove(EMoveID M, EditorRange &R) { + if (fMode == kHistSearchMode) { + if (M == kMoveRight) { + // ^G, i.e. cancel hist search and revert original line. + CancelAndRevertSpecialInputMode(R); + return kPRSuccess; + } + } + ClearPasteBuf(); CancelSpecialInputMode(R.fDisplay); @@ -407,6 +427,7 @@ namespace textinput { ProcessMove(kMoveEnd, R); return kPRSuccess; case kCmdReverseSearch: + PushUndo(); fMode = kHistSearchMode; fSearch.clear(); SetReverseHistSearchPrompt(R.fDisplay); diff --git a/core/textinput/src/textinput/Editor.h b/core/textinput/src/textinput/Editor.h index a5d2ff246b196..a95b6aed18db7 100644 --- a/core/textinput/src/textinput/Editor.h +++ b/core/textinput/src/textinput/Editor.h @@ -127,6 +127,7 @@ namespace textinput { const Text& GetEditorPrompt() const { return fEditorPrompt; } void SetEditorPrompt(const Text& EP) { fEditorPrompt = EP; } void CancelSpecialInputMode(Range& DisplayR); + void CancelAndRevertSpecialInputMode(EditorRange& R); private: EProcessResult ProcessChar(char C, EditorRange& R); diff --git a/core/textinput/src/textinput/TerminalDisplay.cpp b/core/textinput/src/textinput/TerminalDisplay.cpp index 94d61d252e805..a54529ccb46c6 100644 --- a/core/textinput/src/textinput/TerminalDisplay.cpp +++ b/core/textinput/src/textinput/TerminalDisplay.cpp @@ -25,8 +25,6 @@ #include "textinput/Text.h" #include "textinput/Editor.h" -#include - namespace textinput { TerminalDisplay::~TerminalDisplay() {} @@ -215,9 +213,8 @@ namespace textinput { // Any prompt update means we'll have to re-write the text Offset = 0; Requested = (size_t) -1; - } else { - Move(IndexToPos(PromptLen + EditorPromptLen + Offset)); } + Move(IndexToPos(PromptLen + EditorPromptLen + Offset)); size_t avail = 0; if (hidden) { diff --git a/core/textinput/src/textinput/TerminalDisplay.h b/core/textinput/src/textinput/TerminalDisplay.h index 21e037a53b908..872a8166675e4 100644 --- a/core/textinput/src/textinput/TerminalDisplay.h +++ b/core/textinput/src/textinput/TerminalDisplay.h @@ -24,7 +24,7 @@ struct termios; namespace textinput { class Color; - // Base class for ouput to a terminal. + // Base class for output to a terminal. class TerminalDisplay: public Display { public: ~TerminalDisplay(); diff --git a/core/textinput/src/textinput/TerminalDisplayWin.cpp b/core/textinput/src/textinput/TerminalDisplayWin.cpp index 09accaf74ca7e..0a241f1d511cf 100644 --- a/core/textinput/src/textinput/TerminalDisplayWin.cpp +++ b/core/textinput/src/textinput/TerminalDisplayWin.cpp @@ -77,13 +77,12 @@ namespace textinput { || CSI.dwCursorPosition.Y != fWritePos.fLine + fStartLine) { fStartLine = CSI.dwCursorPosition.Y; if (CSI.dwCursorPosition.X) { - // Whooa - where are we?! Newline and cross fingers: - WriteRawString("\n", 1); - ++fStartLine; + // fStartLine may be a couple of lines higher (or more precisely + // the number of written lines higher) + fStartLine -= fWritePos.fLine; } fWritePos.fCol = 0; fWritePos.fLine = 0; - Redraw(); } } } diff --git a/core/textinput/src/textinput/TextInputContext.cpp b/core/textinput/src/textinput/TextInputContext.cpp index c557e91d1bc00..c06cbd039efac 100644 --- a/core/textinput/src/textinput/TextInputContext.cpp +++ b/core/textinput/src/textinput/TextInputContext.cpp @@ -7,7 +7,7 @@ // //===----------------------------------------------------------------------===// // -// This file defines the internal interface for TextInput's auxilliary +// This file defines the internal interface for TextInput's auxiliary // objects. // // Axel Naumann , 2011-05-12 diff --git a/core/textinput/src/textinput/TextInputContext.h b/core/textinput/src/textinput/TextInputContext.h index 8c2d31750ea63..17e5c2f2b19d8 100644 --- a/core/textinput/src/textinput/TextInputContext.h +++ b/core/textinput/src/textinput/TextInputContext.h @@ -7,7 +7,7 @@ // //===----------------------------------------------------------------------===// // -// This file defines the internal interface for TextInput's auxilliary +// This file defines the internal interface for TextInput's auxiliary // objects. // // Axel Naumann , 2011-05-12 diff --git a/core/thread/Module.mk b/core/thread/Module.mk index d2eafa8b74495..58b1866995afc 100644 --- a/core/thread/Module.mk +++ b/core/thread/Module.mk @@ -108,6 +108,7 @@ $(CINTDIRDLLS)/pthread.dll: cint/cint/lib/pthread/pthd.h $(ROOTCINTTMPDEP) $(CIN @$(MAKECINTDLL) $(PLATFORM) C pthread pthread pthd.h \ "$(CINTTMP)" "$(ROOTCINTTMP)" \ "$(MAKELIB)" "$(CXX)" "$(CC)" "$(LD)" "$(OPT)" "$(CINTCXXFLAGS)" \ - "$(CINTCFLAGS)" "$(LDFLAGS)" "$(SOFLAGS)" "$(SOEXT)" "$(COMPILER)" \ - "$(CXXOUT)" + "$(CINTCFLAGS)" "$(LDFLAGS)" "$(THREADLIBEXTRA) $(OSTHREADLIBDIR) $(OSTHREADLIB) $(CINTDLLLIBLINK)" \ + "$(SOFLAGS)" "$(SOEXT)" "$(COMPILER)" \ + "$(CXXOUT)" endif diff --git a/core/thread/src/TPosixThreadFactory.cxx b/core/thread/src/TPosixThreadFactory.cxx index c4251326a283f..153ffda8756df 100644 --- a/core/thread/src/TPosixThreadFactory.cxx +++ b/core/thread/src/TPosixThreadFactory.cxx @@ -23,7 +23,7 @@ #include "TPosixThread.h" // Force creation of TPosixThreadFactory when shared library will be loaded -// (don't explicitely create a TPosixThreadFactory). +// (don't explicitly create a TPosixThreadFactory). static TPosixThreadFactory gPosixThreadFactoryCreator; ClassImp(TPosixThreadFactory) diff --git a/core/thread/src/TThread.cxx b/core/thread/src/TThread.cxx index bc391ee57b4f5..bfb185176b4be 100644 --- a/core/thread/src/TThread.cxx +++ b/core/thread/src/TThread.cxx @@ -145,7 +145,13 @@ Int_t TJoinHelper::Join() // does not imply anything about the value of this predicate, the // predicate should be re-evaluated upon such return. - if (r == 0 && fJoined) break; + if (r == 0 || r == 1) { + // If we received the signal or timed out, let's check the value + if (fJoined) break; + } else { + // If any other error occured, there is no point in trying again + break; + } gSystem->ProcessEvents(); } @@ -240,9 +246,14 @@ TThread::TThread(Long_t id) fPriority = kNormalPriority; fThreadArg = 0; Constructor(); + + // Changing the id must be protected as it will be look at by multiple + // threads (see TThread::GetThread) + ThreadInternalLock(); fNamed = kFALSE; fId = (id ? id : SelfId()); fState = kRunningState; + ThreadInternalUnLock(); if (gDebug) Info("TThread::TThread", "TThread attached to running thread"); diff --git a/core/thread/src/TWin32ThreadFactory.cxx b/core/thread/src/TWin32ThreadFactory.cxx index 7175e7b0582d3..05a6958821531 100644 --- a/core/thread/src/TWin32ThreadFactory.cxx +++ b/core/thread/src/TWin32ThreadFactory.cxx @@ -23,7 +23,7 @@ #include "TWin32Thread.h" // Force creation of TWin32ThreadFactory when shared library will be loaded -// (don't explicitely create a TWin32ThreadFactory). +// (don't explicitly create a TWin32ThreadFactory). static TWin32ThreadFactory gWin32ThreadFactoryCreator; ClassImp(TWin32ThreadFactory) diff --git a/core/unix/inc/TUnixSystem.h b/core/unix/inc/TUnixSystem.h index 4b8ceb76f21f3..0cc6e4ae9c35e 100644 --- a/core/unix/inc/TUnixSystem.h +++ b/core/unix/inc/TUnixSystem.h @@ -78,9 +78,6 @@ class TUnixSystem : public TSystem { static void UnixDynListSymbols(const char *lib, const char *re = ""); static void UnixDynListLibs(const char *lib = ""); - static void *SearchUtmpEntry(int nentries, const char *tty); - static int ReadUtmpFile(); - public: TUnixSystem(); virtual ~TUnixSystem(); @@ -175,6 +172,7 @@ class TUnixSystem : public TSystem { //---- Environment Manipulation ----------------------------- const char *Getenv(const char *name); void Setenv(const char *name, const char *value); + void Unsetenv(const char *name); //---- System Logging --------------------------------------- void Openlog(const char *name, Int_t options, ELogFacility facility); diff --git a/core/unix/src/TUnixSystem.cxx b/core/unix/src/TUnixSystem.cxx index 0a410425ca64b..314f38bd77d43 100644 --- a/core/unix/src/TUnixSystem.cxx +++ b/core/unix/src/TUnixSystem.cxx @@ -98,6 +98,7 @@ #include #include #include +#include #include #include #include @@ -303,8 +304,75 @@ enum { // End FPE handling includes -static STRUCT_UTMP *gUtmpContents; +struct TUtmpContent { + STRUCT_UTMP *fUtmpContents; + UInt_t fEntries; // Number of entries in utmp file. + + TUtmpContent() : fUtmpContents(0), fEntries(0) {} + ~TUtmpContent() { free(fUtmpContents); } + + STRUCT_UTMP *SearchUtmpEntry(const char *tty) + { + // Look for utmp entry which is connected to terminal tty. + + STRUCT_UTMP *ue = fUtmpContents; + + UInt_t n = fEntries; + while (n--) { + if (ue->ut_name[0] && !strncmp(tty, ue->ut_line, sizeof(ue->ut_line))) + return ue; + ue++; + } + return 0; + } + + int ReadUtmpFile() + { + // Read utmp file. Returns number of entries in utmp file. + + FILE *utmp; + struct stat file_stats; + size_t n_read, size; + + fEntries = 0; + + R__LOCKGUARD2(gSystemMutex); + + utmp = fopen(UTMP_FILE, "r"); + if (!utmp) + return 0; + + if (fstat(fileno(utmp), &file_stats) == -1) { + fclose(utmp); + return 0; + } + size = file_stats.st_size; + if (size <= 0) { + fclose(utmp); + return 0; + } + + fUtmpContents = (STRUCT_UTMP *) malloc(size); + if (!fUtmpContents) { + fclose(utmp); + return 0; + } + + n_read = fread(fUtmpContents, 1, size, utmp); + if (!ferror(utmp)) { + if (fclose(utmp) != EOF && n_read == size) { + fEntries = size / sizeof(STRUCT_UTMP); + return fEntries; + } + } else + fclose(utmp); + + free(fUtmpContents); + fUtmpContents = 0; + return 0; + } +}; const char *kServerPath = "/tmp"; const char *kProtocolName = "tcp"; @@ -617,11 +685,12 @@ void TUnixSystem::SetDisplay() if (tty) { tty += 5; // remove "/dev/" - R__LOCKGUARD2(gSystemMutex); + TUtmpContent utmp; + utmp.ReadUtmpFile(); - STRUCT_UTMP *utmp_entry = (STRUCT_UTMP *)SearchUtmpEntry(ReadUtmpFile(), tty); + STRUCT_UTMP *utmp_entry = utmp.SearchUtmpEntry(tty); if (utmp_entry) { - if (utmp_entry->ut_host[0]) + if (utmp_entry->ut_host[0]) { if (strchr(utmp_entry->ut_host, ':')) { Setenv("DISPLAY", utmp_entry->ut_host); Warning("SetDisplay", "DISPLAY not set, setting it to %s", @@ -633,6 +702,7 @@ void TUnixSystem::SetDisplay() Warning("SetDisplay", "DISPLAY not set, setting it to %s", disp); } + } #ifndef UTMP_NO_ADDR else if (utmp_entry->ut_addr) { struct hostent *he; @@ -647,7 +717,6 @@ void TUnixSystem::SetDisplay() } #endif } - free(gUtmpContents); } } } @@ -1071,14 +1140,14 @@ void TUnixSystem::DispatchOneEvent(Bool_t pendingOnly) if (fReadmask->IsSet(fd)) { rc = UnixSelect(fd+1, &t, 0, 0); if (rc < 0 && rc != -2) { - SysError("DispatchOneEvent", "select: read error on %d\n", fd); + SysError("DispatchOneEvent", "select: read error on %d", fd); fReadmask->Clr(fd); } } if (fWritemask->IsSet(fd)) { rc = UnixSelect(fd+1, 0, &t, 0); if (rc < 0 && rc != -2) { - SysError("DispatchOneEvent", "select: write error on %d\n", fd); + SysError("DispatchOneEvent", "select: write error on %d", fd); fWritemask->Clr(fd); } } @@ -1265,7 +1334,7 @@ Bool_t TUnixSystem::CheckSignals(Bool_t sync) //______________________________________________________________________________ void TUnixSystem::CheckChilds() { - // Check if childs have finished. + // Check if children have finished. #if 0 //rdm int pid; @@ -1402,8 +1471,9 @@ const char *TUnixSystem::WorkingDirectory() { // Return working directory. - if (fWdpath != "") - return fWdpath.Data(); + // don't use cache as user can call chdir() directly somewhere else + //if (fWdpath != "") + // return fWdpath.Data(); R__LOCKGUARD2(gSystemMutex); @@ -1612,7 +1682,7 @@ int TUnixSystem::Link(const char *from, const char *to) //______________________________________________________________________________ int TUnixSystem::Symlink(const char *from, const char *to) { - // Create a symlink from file1 to file2. Returns 0 when succesfull, + // Create a symlink from file1 to file2. Returns 0 when successful, // -1 in case of failure. #if defined(R__AIX) @@ -1625,7 +1695,7 @@ int TUnixSystem::Symlink(const char *from, const char *to) //______________________________________________________________________________ int TUnixSystem::Unlink(const char *name) { - // Unlink, i.e. remove, a file or directory. Returns 0 when succesfull, + // Unlink, i.e. remove, a file or directory. Returns 0 when successful, // -1 in case of failure. TSystem *helper = FindHelper(name); @@ -1808,6 +1878,7 @@ char *TUnixSystem::ExpandPathName(const char *path) // environment variables in a pathname. If compatibility is not an issue // you can use on Unix directly $XXX. The user must delete returned string. // Returns the expanded pathname or 0 in case of error. + // The user must delete returned string (delete []). TString patbuf = path; if (ExpandPathName(patbuf)) @@ -2054,16 +2125,9 @@ UserGroup_t *TUnixSystem::GetGroupInfo(const char *group) //______________________________________________________________________________ void TUnixSystem::Setenv(const char *name, const char *value) { - // Set environment variable. The string passed will be owned by - // the environment and can not be reused till a "name" is set - // again. The solution below will lose the space for the string - // in that case, but if this functions is not called thousands - // of times that should not be a problem. + // Set environment variable. - char *s = new char [strlen(name)+strlen(value) + 2]; - sprintf(s, "%s=%s", name, value); - - ::putenv(s); + ::setenv(name, value, 1); } //______________________________________________________________________________ @@ -2074,6 +2138,14 @@ const char *TUnixSystem::Getenv(const char *name) return ::getenv(name); } +//______________________________________________________________________________ +void TUnixSystem::Unsetenv(const char *name) +{ + // Unset environment variable. + + ::unsetenv(name); +} + //---- Processes --------------------------------------------------------------- //______________________________________________________________________________ @@ -2116,9 +2188,8 @@ void TUnixSystem::Exit(int code, Bool_t mode) // Insures that the files and sockets are closed before any library is unloaded // and before emptying CINT. if (gROOT) { - gROOT->CloseFiles(); - } - if (gInterpreter) { + gROOT->EndOfProcessCleanups(); + } else if (gInterpreter) { gInterpreter->ResetGlobals(); } @@ -2170,10 +2241,10 @@ void TUnixSystem::StackTrace() TString gdbmess = gEnv->GetValue("Root.StacktraceMessage", ""); gdbmess = gdbmess.Strip(); - cout.flush(); + std::cout.flush(); fflush(stdout); - cerr.flush(); + std::cerr.flush(); fflush(stderr); int fd = STDERR_FILENO; @@ -2347,7 +2418,7 @@ void TUnixSystem::StackTrace() // open tmp file for demangled stack trace TString tmpf1 = "gdb-backtrace"; - ofstream file1; + std::ofstream file1; if (demangle) { FILE *f = TempFileName(tmpf1); if (f) fclose(f); @@ -2383,7 +2454,12 @@ void TUnixSystem::StackTrace() Bool_t nodebug = kTRUE; #ifdef R__MACOSX if (libaddr) { } // use libaddr +#if defined(MAC_OS_X_VERSION_10_9) + // suppress deprecation warning with option -d + snprintf(buffer, sizeof(buffer), "%s -d -p %d 0x%016lx", addr2line, GetPid(), addr); +#else snprintf(buffer, sizeof(buffer), "%s -p %d 0x%016lx", addr2line, GetPid(), addr); +#endif #else ULong_t offset = (addr >= libaddr) ? addr - libaddr : libaddr - addr; @@ -2439,7 +2515,7 @@ void TUnixSystem::StackTrace() file1.close(); snprintf(buffer, sizeof(buffer), "%s %s < %s > %s", filter, cppfiltarg, tmpf1.Data(), tmpf2.Data()); Exec(buffer); - ifstream file2(tmpf2); + std::ifstream file2(tmpf2); TString line; while (file2) { line = ""; @@ -2724,11 +2800,23 @@ Int_t TUnixSystem::RedirectOutput(const char *file, const char *mode, } xh->fStdOutTty = ""; } else { + if (close(STDOUT_FILENO) != 0) { + SysError("RedirectOutput", + "problems closing STDOUT_FILENO (%d) before 'dup2' (errno: %d)", + STDOUT_FILENO, TSystem::GetErrno()); + rc = -1; + } if (dup2(xh->fStdOutDup, STDOUT_FILENO) < 0) { SysError("RedirectOutput", "could not restore stdout (back to original redirected" " file) (errno: %d)", TSystem::GetErrno()); rc = -1; } + if (close(xh->fStdOutDup) != 0) { + SysError("RedirectOutput", + "problems closing temporary 'out' descriptor %d (errno: %d)", + TSystem::GetErrno(), xh->fStdOutDup); + rc = -1; + } } fflush(stderr); if (!(xh->fStdErrTty.IsNull())) { @@ -2738,11 +2826,23 @@ Int_t TUnixSystem::RedirectOutput(const char *file, const char *mode, } xh->fStdErrTty = ""; } else { + if (close(STDERR_FILENO) != 0) { + SysError("RedirectOutput", + "problems closing STDERR_FILENO (%d) before 'dup2' (errno: %d)", + STDERR_FILENO, TSystem::GetErrno()); + rc = -1; + } if (dup2(xh->fStdErrDup, STDERR_FILENO) < 0) { SysError("RedirectOutput", "could not restore stderr (back to original redirected" " file) (errno: %d)", TSystem::GetErrno()); rc = -1; } + if (close(xh->fStdErrDup) != 0) { + SysError("RedirectOutput", + "problems closing temporary 'err' descriptor %d (errno: %d)", + TSystem::GetErrno(), xh->fStdErrDup); + rc = -1; + } } // Reset the static instance, if using that if (xh == &loch) @@ -3289,7 +3389,7 @@ void TUnixSystem::CloseConnection(int sock, Bool_t force) //______________________________________________________________________________ int TUnixSystem::RecvBuf(int sock, void *buf, int length) { - // Receive a buffer headed by a length indicator. Lenght is the size of + // Receive a buffer headed by a length indicator. Length is the size of // the buffer. Returns the number of bytes received in buf or -1 in // case of error. @@ -4279,7 +4379,7 @@ int TUnixSystem::UnixTcpService(int port, Bool_t reuse, int backlog, // Bind socket if (port > 0) { - if (bind(sock, (struct sockaddr*) &inserver, sizeof(inserver))) { + if (::bind(sock, (struct sockaddr*) &inserver, sizeof(inserver))) { ::SysError("TUnixSystem::UnixTcpService", "bind"); close(sock); return -2; @@ -4288,7 +4388,7 @@ int TUnixSystem::UnixTcpService(int port, Bool_t reuse, int backlog, int bret; do { inserver.sin_port = htons(tryport++); - bret = bind(sock, (struct sockaddr*) &inserver, sizeof(inserver)); + bret = ::bind(sock, (struct sockaddr*) &inserver, sizeof(inserver)); } while (bret < 0 && GetErrno() == EADDRINUSE && tryport < kSOCKET_MAXPORT); if (bret < 0) { ::SysError("TUnixSystem::UnixTcpService", "bind (port scan)"); @@ -4298,7 +4398,7 @@ int TUnixSystem::UnixTcpService(int port, Bool_t reuse, int backlog, } // Start accepting connections - if (listen(sock, backlog)) { + if (::listen(sock, backlog)) { ::SysError("TUnixSystem::UnixTcpService", "listen"); close(sock); return -3; @@ -4340,7 +4440,7 @@ int TUnixSystem::UnixUdpService(int port, int backlog) // Bind socket if (port > 0) { - if (bind(sock, (struct sockaddr*) &inserver, sizeof(inserver))) { + if (::bind(sock, (struct sockaddr*) &inserver, sizeof(inserver))) { ::SysError("TUnixSystem::UnixUdpService", "bind"); close(sock); return -2; @@ -4349,7 +4449,7 @@ int TUnixSystem::UnixUdpService(int port, int backlog) int bret; do { inserver.sin_port = htons(tryport++); - bret = bind(sock, (struct sockaddr*) &inserver, sizeof(inserver)); + bret = ::bind(sock, (struct sockaddr*) &inserver, sizeof(inserver)); } while (bret < 0 && GetErrno() == EADDRINUSE && tryport < kSOCKET_MAXPORT); if (bret < 0) { ::SysError("TUnixSystem::UnixUdpService", "bind (port scan)"); @@ -4359,7 +4459,7 @@ int TUnixSystem::UnixUdpService(int port, int backlog) } // Start accepting connections - if (listen(sock, backlog)) { + if (::listen(sock, backlog)) { ::SysError("TUnixSystem::UnixUdpService", "listen"); close(sock); return -3; @@ -4378,9 +4478,12 @@ int TUnixSystem::UnixUnixService(int port, int backlog) // Assure that socket directory exists oldumask = umask(0); - ::mkdir(kServerPath, 0777); + int res = ::mkdir(kServerPath, 0777); umask(oldumask); + if (res == -1) + return -1; + // Socket path TString sockpath; sockpath.Form("%s/%d", kServerPath, port); @@ -4422,14 +4525,14 @@ int TUnixSystem::UnixUnixService(const char *sockpath, int backlog) return -1; } - if (bind(sock, (struct sockaddr*) &unserver, strlen(unserver.sun_path)+2)) { + if (::bind(sock, (struct sockaddr*) &unserver, strlen(unserver.sun_path)+2)) { ::SysError("TUnixSystem::UnixUnixService", "bind"); close(sock); return -1; } // Start accepting connections - if (listen(sock, backlog)) { + if (::listen(sock, backlog)) { ::SysError("TUnixSystem::UnixUnixService", "listen"); close(sock); return -1; @@ -4860,63 +4963,6 @@ void TUnixSystem::UnixDynUnload(const char *lib) #endif } -//______________________________________________________________________________ -int TUnixSystem::ReadUtmpFile() -{ - // Read utmp file. Returns number of entries in utmp file. - - FILE *utmp; - struct stat file_stats; - size_t n_read, size; - - R__LOCKGUARD2(gSystemMutex); - - gUtmpContents = 0; - - utmp = fopen(UTMP_FILE, "r"); - if (!utmp) - return 0; - - fstat(fileno(utmp), &file_stats); - size = file_stats.st_size; - if (size <= 0) { - fclose(utmp); - return 0; - } - - gUtmpContents = (STRUCT_UTMP *) malloc(size); - if (!gUtmpContents) { - fclose(utmp); - return 0; - } - - n_read = fread(gUtmpContents, 1, size, utmp); - if (!ferror(utmp)) { - if (fclose(utmp) != EOF && n_read == size) - return size / sizeof(STRUCT_UTMP); - } else - fclose(utmp); - - free(gUtmpContents); - gUtmpContents = 0; - return 0; -} - -//______________________________________________________________________________ -void *TUnixSystem::SearchUtmpEntry(int n, const char *tty) -{ - // Look for utmp entry which is connected to terminal tty. - - STRUCT_UTMP *ue = gUtmpContents; - - while (n--) { - if (ue->ut_name[0] && !strncmp(tty, ue->ut_line, sizeof(ue->ut_line))) - return ue; - ue++; - } - return 0; -} - //---- System, CPU and Memory info --------------------------------------------- #if defined(R__MACOSX) diff --git a/core/utils/CMakeLists.txt b/core/utils/CMakeLists.txt index e57dc746157d8..f683375e2095d 100644 --- a/core/utils/CMakeLists.txt +++ b/core/utils/CMakeLists.txt @@ -17,7 +17,10 @@ add_dependencies(rootcint IOSENUM_H) add_custom_command(OUTPUT rootcint_tmp.cxx RStl_tmp.cxx loadfile_tmp.cxx COMMAND cmake -E copy_if_different ${CMAKE_CURRENT_SOURCE_DIR}/src/rootcint.cxx rootcint_tmp.cxx COMMAND cmake -E copy_if_different ${CMAKE_CURRENT_SOURCE_DIR}/src/RStl.cxx RStl_tmp.cxx - COMMAND cmake -E copy_if_different ${CMAKE_SOURCE_DIR}/cint/cint/src/loadfile.cxx loadfile_tmp.cxx ) + COMMAND cmake -E copy_if_different ${CMAKE_SOURCE_DIR}/cint/cint/src/loadfile.cxx loadfile_tmp.cxx + DEPENDS ${CMAKE_SOURCE_DIR}/cint/cint/src/loadfile.cxx + ${CMAKE_CURRENT_SOURCE_DIR}/src/RStl.cxx + ${CMAKE_CURRENT_SOURCE_DIR}/src/rootcint.cxx) #add_definitions("-UR__HAVE_CONFIG -DROOTBUILD") set_source_files_properties(loadfile_tmp.cxx rootcint_tmp.cxx RStl_tmp.cxx PROPERTIES COMPILE_FLAGS @@ -26,7 +29,7 @@ ROOT_EXECUTABLE(rootcint_tmp rootcint_tmp.cxx RStl_tmp.cxx loadfile_tmp.cxx ${METAUTILS_CXX_SOURCES} ${CMAKE_SOURCE_DIR}/core/clib/src/strlcpy.c ${CMAKE_SOURCE_DIR}/core/clib/src/strlcat.c - LIBRARIES Cint_static ${CMAKE_DL_LIBS}) + LIBRARIES Cint_static ${CMAKE_DL_LIBS} NOINSTALL) add_dependencies(rootcint_tmp IOSENUM_H) #---Trick to avoid building all dictionaties when CINT is changed------------- diff --git a/core/utils/src/rlibmap.cxx b/core/utils/src/rlibmap.cxx index dfa9c7c3be36c..f795852ffb72e 100644 --- a/core/utils/src/rlibmap.cxx +++ b/core/utils/src/rlibmap.cxx @@ -30,6 +30,7 @@ #include #include #include +#include #ifndef WIN32 # include #else @@ -262,7 +263,7 @@ int LibMap(const string &solib, const vector &solibdeps, { // Write libmap. Returns -1 in case of error. - vector classes; + set classes; vector::const_iterator lk; for (lk = linkdefs.begin(); lk != linkdefs.end(); lk++) { @@ -312,7 +313,7 @@ int LibMap(const string &solib, const vector &solibdeps, *s = '-'; s++; } - classes.push_back(cls); + classes.insert(cls); } } } @@ -330,7 +331,7 @@ int LibMap(const string &solib, const vector &solibdeps, libbase = solib.c_str(); } - vector::const_iterator it; + set::const_iterator it; for (it = classes.begin(); it != classes.end(); it++) { fprintf(fp, "Library.%-35s %s", ((*it)+":").c_str(), libbase); diff --git a/core/utils/src/rootcint.cxx b/core/utils/src/rootcint.cxx index d01e5cd4c6934..43ff08dab1e82 100644 --- a/core/utils/src/rootcint.cxx +++ b/core/utils/src/rootcint.cxx @@ -1626,7 +1626,7 @@ int IsSTLContainer(G__DataMemberInfo &m) // Is this an STL container? const char *s = m.Type()->TrueName(); - if (!s) return kNotSTL; + if (!s) return TClassEdit::kNotSTL; string type(s); int k = TClassEdit::IsSTLCont(type.c_str(),1); @@ -1642,7 +1642,7 @@ int IsSTLContainer(G__BaseClassInfo &m) // Is this an STL container? const char *s = m.Name(); - if (!s) return kNotSTL; + if (!s) return TClassEdit::kNotSTL; string type(s); int k = TClassEdit::IsSTLCont(type.c_str(),1); @@ -3765,6 +3765,19 @@ void WriteClassCode(G__ClassInfo &cl, bool force = false) } } +//______________________________________________________________________________ +void WriteRegisterModule() +{ + (*dictSrcOut) << "// Direct notice to TROOT of the dictionary's loading.\n"; + (*dictSrcOut) << "namespace {\n"; + (*dictSrcOut) << " static struct DictInit {\n"; + (*dictSrcOut) << " DictInit() {\n"; + (*dictSrcOut) << " ROOT::RegisterModule();\n"; + (*dictSrcOut) << " }\n"; + (*dictSrcOut) << " } __TheDictionaryInitializer;\n"; + (*dictSrcOut) << "}\n\n"; +} + //______________________________________________________________________________ void GenerateLinkdef(int *argc, char **argv, int iv) { @@ -4254,6 +4267,10 @@ int main(int argc, char **argv) } else if (!strcmp(argv[ic], "-v4")) { gErrorIgnoreLevel = kInfo; // Display all information (same as -v) ic++; + } else if (!strcmp(argv[ic], "-s") || !strcmp(argv[ic], "-m")) { + // Ignore ROOT 6 arguments about creating pcm and + // their dependencies. + ic += 2; } if (ic < argc) { if (!strcmp(argv[ic], "-cint")) { @@ -4282,6 +4299,10 @@ int main(int argc, char **argv) longheadername = 1; ic++; + } else if (!strcmp(argv[ic], "-s") || !strcmp(argv[ic], "-m")) { + // Ignore ROOT 6 arguments about creating pcm and + // their dependencies. + ic += 2; } else if (!strncmp(argv[ic],libprefix,strlen(libprefix))) { gLiblistPrefix = argv[ic]+strlen(libprefix); @@ -4412,6 +4433,12 @@ int main(int argc, char **argv) ifl = 0; } + while (!strcmp(argv[ic], "-s") || !strcmp(argv[ic], "-m")) { + // Ignore ROOT 6 arguments about creating pcm and + // their dependencies. + ic += 2; + } + // If the user request use of a preprocessor we are going to bundle // all the files into one so that cint considers them one compilation // unit and so that each file that contains code guard is really @@ -5085,6 +5112,8 @@ int main(int argc, char **argv) AddConstructorType("TRootIOCtor"); AddConstructorType(""); + WriteRegisterModule(); + const char* shadowNSName="ROOT"; if (dict_type != kDictTypeCint) shadowNSName = "ROOT::Reflex"; diff --git a/core/winnt/src/TWinNTSystem.cxx b/core/winnt/src/TWinNTSystem.cxx index 1700c808b024d..72f45cd8d9075 100644 --- a/core/winnt/src/TWinNTSystem.cxx +++ b/core/winnt/src/TWinNTSystem.cxx @@ -1963,9 +1963,8 @@ Bool_t TWinNTSystem::ChangeDirectory(const char *path) // Change directory. Bool_t ret = (Bool_t) (::chdir(path) == 0); - if (fWdpath != "") { + if (fWdpath != "") fWdpath = ""; // invalidate path cache - } return ret; } @@ -2127,9 +2126,9 @@ const char *TWinNTSystem::WorkingDirectory(char driveletter) char *wdpath = 0; char drive = driveletter ? toupper( driveletter ) - 'A' + 1 : 0; - if (fWdpath != "" ) { - return fWdpath; - } + // don't use cache as user can call chdir() directly somewhere else + //if (fWdpath != "" ) + // return fWdpath; if (!(wdpath = ::_getdcwd( (int)drive, wdpath, kMAXPATHLEN))) { free(wdpath); @@ -2724,7 +2723,7 @@ int TWinNTSystem::Link(const char *from, const char *to) //______________________________________________________________________________ int TWinNTSystem::Symlink(const char *from, const char *to) { - // Create a symlink from file1 to file2. Returns 0 when succesfull, + // Create a symlink from file1 to file2. Returns 0 when successful, // -1 in case of failure. HRESULT hRes; /* Returned COM result code */ @@ -3046,7 +3045,7 @@ const char *TWinNTSystem::FindFile(const char *search, TString& infile, EAccessM //______________________________________________________________________________ Bool_t TWinNTSystem::InitUsersGroups() { - // Collect local users and groups accounts informations + // Collect local users and groups accounts information // Net* API functions allowed and OS is Windows NT/2000/XP if ((gEnv->GetValue("WinNT.UseNetAPI", 0)) && (::GetVersion() < 0x80000000)) { @@ -3796,7 +3795,7 @@ void TWinNTSystem::Exit(int code, Bool_t mode) // Insures that the files and sockets are closed before any library is unloaded // and before emptying CINT. if (gROOT) { - gROOT->CloseFiles(); + gROOT->EndOfProcessCleanups(); if (gROOT->GetListOfBrowsers()) { // GetListOfBrowsers()->Delete() creates problems when a browser is // created on the stack, calling CloseWindow() solves the problem @@ -3807,8 +3806,7 @@ void TWinNTSystem::Exit(int code, Bool_t mode) gROOT->ProcessLine(Form("((TBrowser*)0x%lx)->GetBrowserImp()->GetMainFrame()->CloseWindow();", (ULong_t)b)); } - } - if (gInterpreter) { + } else if (gInterpreter) { gInterpreter->ResetGlobals(); } gVirtualX->CloseDisplay(); @@ -4721,7 +4719,7 @@ void TWinNTSystem::CloseConnection(int socket, Bool_t force) //______________________________________________________________________________ int TWinNTSystem::RecvBuf(int sock, void *buf, int length) { - // Receive a buffer headed by a length indicator. Lenght is the size of + // Receive a buffer headed by a length indicator. Length is the size of // the buffer. Returns the number of bytes received in buf or -1 in // case of error. @@ -4770,7 +4768,7 @@ int TWinNTSystem::RecvRaw(int sock, void *buf, int length, int opt) { // Receive exactly length bytes into buffer. Use opt to receive out-of-band // data or to have a peek at what is in the buffer (see TSocket). Buffer - // must be able to store at least lenght bytes. Returns the number of + // must be able to store at least length bytes. Returns the number of // bytes received (can be 0 if other side of connection was closed) or -1 // in case of error, -2 in case of MSG_OOB and errno == EWOULDBLOCK, -3 // in case of MSG_OOB and errno == EINVAL and -4 in case of kNoBlock and diff --git a/core/winnt/src/Win32Splash.cxx b/core/winnt/src/Win32Splash.cxx index f37d06438757f..2edfd38036913 100644 --- a/core/winnt/src/Win32Splash.cxx +++ b/core/winnt/src/Win32Splash.cxx @@ -358,10 +358,10 @@ void *OpenGraphic(char *name) // get width and height of picture hr = Ipic->get_Width(&sizeInHiMetric.cx); if (!SUCCEEDED(hr)) - goto err; + return 0; Ipic->get_Height(&sizeInHiMetric.cy); if (!SUCCEEDED(hr)) - goto err; + return 0; // convert himetric to pixels sizeInPix.cx = (nPixelsPerInchX * sizeInHiMetric.cx + @@ -374,7 +374,6 @@ void *OpenGraphic(char *name) gImageInfo.Path = name; return Ipic; } -err: return 0; } diff --git a/core/zip/CMakeLists.txt b/core/zip/CMakeLists.txt index 20323d5ab79cb..0593770e0bce1 100644 --- a/core/zip/CMakeLists.txt +++ b/core/zip/CMakeLists.txt @@ -54,15 +54,15 @@ Set(ZipNewSource # or only the old compression is build if(builtin_zlib) set(ZLIB_HEADERS ${ZipNewHeaders} ${ZipOldHeaders}) - set(ZLIB_SRCS ${ZipNewSource} ${ZipOldSource}) + set(ZLIB_SRCS ${ZipNewSource} ${ZipOldSource} ${CMAKE_CURRENT_SOURCE_DIR}/src/Compression.cxx) else() set(ZLIB_HEADERS ${ZipOldHeaders}) - set(ZLIB_SRCS ${ZipOldSource}) + set(ZLIB_SRCS ${ZipOldSource} ${CMAKE_CURRENT_SOURCE_DIR}/src/Compression.cxx) endif() # Define all the header files which should be installed when # doing a "make install" -install(FILES ${ZLIB_HEADERS} DESTINATION include) +install(FILES ${ZLIB_HEADERS} DESTINATION ${CMAKE_INSTALL_INCDIR}) set_property(GLOBAL APPEND PROPERTY ROOT_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/inc) # Add all source files of this subdirectory to the source files diff --git a/core/zip/inc/zlib.h b/core/zip/inc/zlib.h index bfbba83e8ee09..1715a1504a23f 100644 --- a/core/zip/inc/zlib.h +++ b/core/zip/inc/zlib.h @@ -962,7 +962,7 @@ ZEXTERN int ZEXPORT inflateBackInit OF((z_streamp strm, int windowBits, See inflateBack() for the usage of these routines. inflateBackInit will return Z_OK on success, Z_STREAM_ERROR if any of - the paramaters are invalid, Z_MEM_ERROR if the internal state could not be + the parameters are invalid, Z_MEM_ERROR if the internal state could not be allocated, or Z_VERSION_ERROR if the version of the library does not match the version of the header file. */ diff --git a/doc/v534/index.html b/doc/v534/index.html index 4e93356010f01..b85c23e0c8433 100644 --- a/doc/v534/index.html +++ b/doc/v534/index.html @@ -8,7 +8,7 @@ -ROOT Version 5.33/01 Release Notes +ROOT Version 5.34/13 Release Notes @@ -47,7 +47,7 @@ » Release Notes
-

ROOT Version 5.33/01 Release Notes

+

ROOT Version 5.34/08 Release Notes

ROOT version 5.32/00 has been released on November 29, 2011. diff --git a/docbook/primer/Introduction.xml b/docbook/primer/Introduction.xml new file mode 100644 index 0000000000000..3318e2a1fca22 --- /dev/null +++ b/docbook/primer/Introduction.xml @@ -0,0 +1,136 @@ + + + +Motivation and Introduction + + + Welcome to data analysis! + This guide was prepared for the ROOT IRMM Tutorial adapting "A ROOT Guide for Students" + http://www-ekp.physik.uni-karlsruhe.de/~quast, + a document by D. Piparo, G. Quast and M. Zeise. + + +Comparison of measurements to theoretical models is one of the standard +tasks in experimental physics. In the most simple case, a "model" +is just a function providing predictions of measured data. Very often, +the model depends on parameters. Such a model may simply state +"the current I is proportional to the voltage +U", and the task of the experimentalist consists of +determining the resistance, R, from a set of measurements. + + +As a first step, a visualisation of the data is needed. Next, some +manipulations typically have to be applied, e.g. corrections or +parameter transformations. Quite often, these manipulations are +complex ones, and a powerful library of mathematical functions and +procedures should be provided - think for example of an integral or +peak-search or a Fourier transformation applied to an input spectrum +to obtain the actual measurement described by the model. + + +One specialty of experimental physics are the inevitable errors affecting +each measurement, and visualisation tools have to include these. +In subsequent analysis, the statistical nature of the errors must +be handled properly. + + +As the last step, measurements are compared to models, and free model +parameters need to be determined in this process. See +for an example of a function (model) fit to data points. +Several standard methods are available, and a data analysis tool should provide +easy access to more than one of them. Means to quantify the level of +agreement between measurements and model must also be available. + + +

Measured data points with error bars and fitted quadratic function. +Measured data points + + + + + +
+ + +Quite often, the data volume to be analyzed is large - think of +fine-granular measurements accumulated with the aid of computers. +A usable tool therefore must contain easy-to-use and efficient +methods for data handling. + + +In Quantum mechanics, models typically only predict the probability density +function ("pdf") of measurements depending on a number of parameters, and +the aim of the experimental analysis is to extract the parameters from the +observed distribution of frequencies at which certain values of the +measurement are observed. Measurements of this kind require means to +generate and visualize frequency distributions, so-called histograms, and +stringent statistical treatment to extract the model parameters from +purely statistical distributions. + + +Simulation of expected data is another important aspect in data analysis. +By repeated generation of "pseudo-data", which are analysed in the +same manner as intended for the real data, analysis procedures can be +validated or compared. In many cases, the distribution of the measurement +errors is not precisely known, and simulation offers the possibility +to test the effects of different assumptions. + + +
+ +Welcome to ROOT + + +A powerful software framework addressing all of the above requirements +is ROOT ROOT, an open source project +coordinated by the European Organisation for Nuclear Research, CERN in Geneva. +ROOT is very flexible and provides both a programming interface to use +in own applications and a graphical user interface for interactive data +analysis. The purpose of this document is to serve as a beginners guide +and provides extendable examples for your own use cases, based on +typical problems addressed in student labs. This guide will hopefully +lay the ground for more complex applications in your future scientific +work building on a modern, state-of the art tool for data analysis. + + + +This guide in form of a tutorial is intended to introduce you to the +ROOT package in about 30 pages. +This goal will be accomplished using concrete +examples, according to the "learning by doing" principle. Also because +of this reason, this guide cannot cover the complexity of the ROOT package. +Nevertheless, once you feel confident with the concepts presented in the +following chapters, you will be able to appreciate the ROOT Users +Guide ROOT_Users_Guide and +navigate through the Class Reference ROOT_Class_Reference +to find all the details you might be interested in. +You can even look at the code itself, since ROOT is a free, open-source +product. Use these documents in parallel to this tutorial! + + +The ROOT Data Analysis Framework itself is written in and heavily relys on +the programming language C++, and therefore some +knowledge about C and C++ is required. +Eventually, just profit from the immense +available literature about C++ if you do not have any idea +of what object oriented programming could be. + + +ROOT is available for many platforms +(Linux, Mac OS X, Windows...), +but in this guide we will implicitly assume that +you are using Linux. The first thing you need to do with ROOT is +install it, don't you? Obtaining the latest ROOT version is +straightforward. Just seek the "Pro" version on this webpage +http://root.cern.ch/drupal/content/downloading-root. +You will find precompiled versions for the different architectures, +or the ROOT source code to compile yourself. Just pick up the +flavour you need and follow the installation instructions. + + +Let's dive into ROOT! + +
+ diff --git a/docbook/primer/ROOTPrimer.xml b/docbook/primer/ROOTPrimer.xml new file mode 100644 index 0000000000000..9770500613a6b --- /dev/null +++ b/docbook/primer/ROOTPrimer.xml @@ -0,0 +1,29 @@ + + + + + ROOT Primer + + + + + + + + The ROOT Team + March 2013 + + + + + + + + + + + + + + \ No newline at end of file diff --git a/docbook/primer/ROOT_as_calculator.xml b/docbook/primer/ROOT_as_calculator.xml new file mode 100644 index 0000000000000..b656166dbdd16 --- /dev/null +++ b/docbook/primer/ROOT_as_calculator.xml @@ -0,0 +1,600 @@ + + + + +ROOT Basics + +Now that you have installed ROOT, what's this interactive shell +thing you're running? +It's like this: ROOT leads a double life. It has an interpreter for macros +(CINT cint) that you can run from the command line or run like +applications. +But it is also an interactive shell that can evaluate arbitrary statements and +expressions. +This is extremely useful for debugging, quick hacking and testing. +Let us first have a look at some very simple examples. + + +
+ROOT as calculator + +You can even use the ROOT interactive shell in lieu of a calculator! +Launch the ROOT interactive shell with the command + > root + +on your Linux box. The prompt should appear shortly: + + root [1] + +and let's dive in with the steps shown here: + +root [0] 1+1 +(const int)2 +root [1] 2*(4+2)/12. +(const double)1.00000000000000000e+00 +root [2] sqrt(3) +(const double)1.73205080756887719e+00 +root [3] 1 > 2 +(const int)0 +root [4] TMath::Pi() +(Double_t)3.14159265358979312e+00 +root [5] TMath::Erf(.2) +(Double_t)2.22702589210478447e-01 + +Not bad. You can see that ROOT offers you the possibility not only to type in +C++ statements, but also advanced mathematical functions, which live +in the TMath namespace. + + +Now let's do something more elaborated. A numerical example with the well +known geometrical series: + +root [6] double x=.5 +root [7] int N=30 +root [8] double geom_series=0 +root [9] for (int i=0;i<N;++i)geom_series+=TMath::Power(x,i) +root [10] TMath::Abs(geom_series - (1-TMath::Power(x,N-1))/(1-x)) +(Double_t)1.86264514923095703e-09 + +Here we made a step forward. We even declared variables and used a for +control structure. +Note that there are some subtle differences between CINT and the +standard C++ language. You do not need the ";" at the end of line +in interactive mode -- try the difference +e.g. using the command at line root [6]. + +
+ +
+ ROOT as Function Plotter + + +Using one of ROOT's powerful classes, here TF1 +All ROOT classes start with the letter T., +will allow us to display a function of one variable, x. Try the following: + +root [11] TF1 *f1 = new TF1("f1","sin(x)/x",0.,10.); +root [12] f1->Draw(); + +f1 is a pointer to an instance of a TF1 class, the arguments are used + in the constructor; the first one of type string is a name to be entered +in the internal ROOT memory management system, the second string type +parameter defines the function, here sin(x)/x, and the two +parameters of type double define +the range of the variable x. The Draw() method, here without any +parameters, displays the function in a window which should pop up after you +typed the above two lines. Note again differences between CINT and C++: +you could have omitted the ";" at the end of lines, CINT woud also have +accepted the "." to access the method Draw(). However, it is +best to stick to standard C++ syntax and avoid CINT-specific code, +as will become clear in a moment. + + +A slightly extended version of this example is the definition of a function +with parameters, called [0], [1] and so on in the ROOT formula +syntax. +We now need a way to assign values to these parameters; this is achieved +with the method +SetParameter(<parameter_number>,<parameter_value>) of +class TF1. Here is an example: + +root [13] TF1 *f1 = new TF1("f2","[0]*sin([1]*x)/x",0.,10.); +root [14] f1->SetParameter(0,1); +root [15] f1->SetParameter(1,1); +root [16] f1->Draw(); + +Of course, this version shows the same results as the initial one. Try +playing with the parameters and plot the function again. +The class TF1 has a large number of very useful methods, including +integration and differentiation. To make full use of this and other ROOT +classes, visit the documentation on the Internet under +http://root.cern.ch/drupal/content/reference-guide. +Formulae in ROOT are evaluated using the class TFormula, +so also look up the relevant class documentation for examples, +implemented functions and syntax. + + +You should definitely download this guide to your own system to +have it at you disposal whenever you need it. + + +To extend a little bit on the above example, consider a more complex +function you would like to define. You can also do this using standard C +or C++ code. In many cases this is the only practical way, as the +ROOT formula interpreter has clear limitations concerning complexity and +speed of evaluation. + + +Consider the example below, which calculates and displays +the interference pattern produced by light falling on a multiple slit. +Please do not type in the example below at the ROOT command line, there +is a much simpler way: +Make sure you have the file slits.C on disk, and +type root slits.C in the shell. This will start +root and make it read the "macro" slits.C, i.e. all the +lines in the file will be executed one after the other. + + + + +
Output of slits.C with parameters 0.2 and 2. + + + + + +
+ + +The example first asks for user input, +namely the ratio of slit width over slit distance, and the number +of slits. After entering this information, you should see +the graphical output as is shown in . + + +This is a more complicated example than the ones we have seen before, so +spend some time analysing it carefully, you should have understood it before +continuing. Let us go through it in detail: + + +Lines 6-19 define the necessary functions in C++ code, split into +three separate functions, as suggested by the problem considered. +The full interference pattern is given by the product of a function +depending on the ratio of the width and distance of the slits, and a +second one depending on the number of slits. More important for us +here is the definition of the interface of these functions to make them +usable for the ROOT class TF1: the first argument is the pointer +to x, the second one points to the array of parameters. + + +The main program starts in line 17 with the definition of a function +slits() of type void. +After asking for user input, a ROOT function is defined +using the C-type function given in the beginning. We can now use all +methods of the TF1 class to control the behaviour of our +function -- nice, isn't it ? + + +If you like, you can easily extend the example to also plot the interference +pattern of a single slit, using function double single, or of +a grid with narrow slits, function double nslit0, in TF1 +instances. + + +Here, we used a macro, some sort of lightweight program, that the +interpreter distributed with ROOT, CINT, is able to execute. This is a +rather extraordinary situation, since C++ is not natively an interpreted +language! There is much more to say: chapter is +indeed dedicated to macros. + + +
+ +
Controlling ROOT + +One more remark at this point: +as every command you type into ROOT is usually interpreted by CINT, an +"escape character" is needed to pass commands to ROOT directly. This +character is the dot at the beginning of a line: + +root [1] .<command> +To + + + quit root, simply type .q + obtain a list of commands, use .? + access the shell of the operating system, type + .!<OS_command>; try, e.g. .!ls or .!pwd + execute a macro, enter .x <file_name>; in the above + example, you might have used .x slits.C at the ROOT prompt + load a macro, type .L <file_name>; in the above + example, you might instead have used the command .L slits.C + followed by the function call slits();. Note that after loading a + macro all functions and procedures defined therein are available at + the ROOT prompt. + compile a macro, type .L <file_name>+; ROOT is able to + manage for you the C++ compiler behind the scenes and to produce machine + code starting from your macro. One could decide to compile a macro in + order to obtain better performance or to get nearer to the production + environment. + +
+ +
+Plotting Measurements + +To display measurements in ROOT, including errors, there exists +a powerful class TGrapErrors with different types of +constructors. In the example here, we use data from the file +ExampleData.txt in text format: + + root [0] TGraphErrors *gr=new TGraphErrors("ExampleData.txt"); +root [1] gr->Draw("AP"); + +You should see the output shown in . + + +
Visualisation of data points with errors using the class TGraphErrors. + Visualisation of data points + + + + + +
+ + +Make sure the file ExampleData.txt +is available in the directory from which you started ROOT. +Inspect this file now with your favourate editor, or use the command +less ExampleData.txt to inspect the file, you will see that the +format is very simple and easy to understand. +Lines beginning with | are ignored, very convenient to +add some comments about the type of data. The data itself consist +of lines with four real numbers each, representing the +x- and y- coordinates and their errors of each data point. + + +The argument of the method Draw("AP") is important here. It tells +the TGraphPainter class to show the axes and to plot markers +at the x and y positions of the specified data points. Note that this +simple example relies on +the default settings of ROOT, concerning the size of the canvas +holding the plot, the marker type and the line colours and thickness +used and so on. In a well-written, complete example, all this +would need to be specified explicitly in order to obtain nice and +well readable results. +A full chapter on graphs (chapter ) will explain many +more of the features of the class TGraphErrors and its relation +to other ROOT classes in much more detail. + +
+
+Histograms in ROOT + +Frequency distributions in ROOT are handled by a set of classes derived +from the histogram class TH1, in our case TH1F. +The letter F stands for "float", meaning that the data +type float is used to store the entries in one histogram bin. + +root [0] TF1 efunc("efunc","exp([0]+[1]*x)",0.,5.); +root [1] efunc.SetParameter(0,1); +root [2] efunc.SetParameter(1,-1); +root [3] TH1F* h=new TH1F("h","example histogram",100,0.,5.); +root [4] for (int i=0;i<1000;i++) {h->Fill(efunc.GetRandom());} +root [5] h->Draw(); + +The first three lines of this example define a function, an exponential +in this case, and set its parameters. In Line 4 a histogram is instantiated, +with a name, a title, a certain number of bins (100 of them, equidistant, +equally sized) in the range from 0 to 5. + + +
+ Visualisation of a histogram filled with exponentially distributed, random numbers. + Visualisation of a histogram + + + + + +
+ + +We use yet another +new feature of ROOT to fill this histogram with data, namely pseudo-random +numbers generated with the method TF1::GetRandom, which in turn +uses an instance of the ROOT class TRandom created when ROOT is +started. Data is entered in the histogram +at line 5 using the method TH1F::Fill in a loop construct. +As a result, the histogram is filled +with 1000 random numbers distributed according to the defined function. +The histogram is displayed using the method TH1F::Draw(). +You may think of this example as repeated measurements of the +life time of a quantum mechanical state, which are entered into the +histogram, thus giving a visual impression of the probability density +distribution. The plot is shown in . + + +Note that you will not obtain an identical plot when executing the +above lines, depending on how the random number generator is initialised. + + +The class TH1F does not contain a convenient input format from +plain text files. The following lines of C++ code do the job. +One number per line stored in the text file "expo.dat" is read in +via an input stream and filled in the histogram until end of file +is reached. + +root [1] TH1F* h=new TH1F("h","example histogram",100,0.,5.); +root [2] ifstream inp; double x; +root [3] inp.open("expo.dat"); +root [4] while(!(inp >> x)==0){h->Fill(x);} +root [5] h->Draw(); +root [6] inp.close(); + +Histograms and random numbers are very important tools in statistical +data analysis, and the whole Chapter will be dedicated to +this topic. + +
+
+Interactive ROOT + +Look at one of your plots again and +move the mouse across. You will notice that this is much more than a static +picture, as the mouse pointer changes its shape when touching objects +on the plot. When the mouse is over an object, +a right-click opens a pull-down menu displaying in the top line +the name of the ROOT class you are dealing with, e.g. +TCanvas for the display window itself, +TFrame for the frame of the plot, +TAxis for the axes, +TPaveText for the plot name. +Depending on which plot you are investigating, menus for the ROOT +classes TF1, TGraphErrors or TH1F will show up +when a right-click is performed on the respective graphical representations. +The menu items allow direct access to the members of the various +classes, and you can even modify them, e.g. change colour and +size of the axis ticks or labels, the function lines, marker types +and so on. Try it! + + +
+ Interactive ROOT panel for setting function parameters. + Interactive ROOT panel + + + + + +
+ + +You will probably like the following: in the output produced +by the example slits.C, right-click on the +function line and select "SetLineAttributes", then +left-click on "Set Parameters". This gives access to a panel +allowing you to interactively change the parameters of the +function, as shown in . +Change the slit width, or go from one to two and +then three or more slits, just as you like. When clicking on +"Apply", the function plot is updated to reflect the actual +value of the parameters you have set. + + + + + + + +
+ Fit Panel. + + + + + +
+
+ + + Another very useful interactive tool is the FitPanel, available + for the classes TGraphErrors and TH1F. Predefined + fit functions can be selected from a pull-down menu, + including + "gaus", "expo" and "pol0" - "pol9" + for Gaussian and exponential functions or polynomials of degree 0 to 9, + respectively. In addition, user-defined functions using the same syntax + as for functions with parameters are possible. + + + After setting the initial + parameters, a fit of the selected function to the data of a graph or + histogram can be performed and the result displayed on the plot. + The fit panel is shown in . The fit + panel has a number of control options to select the fit method, + fix or release individual paramters in the fit, to steer the level of + output printed on the console, or to extract and display + additional information like contour lines showing parameter + correlations. + As function fitting is of prime importance in any kind of data analysis, + this topic will again show up in chapter . + + +
+ +
+
+ + + +If you are satisfied with your plot, you probably want to save it. +Just close all selector boxes you opened previously and select +the menu item Save as... from the menu line of the window. It will +pop up a file selector box to allow you to choose the format, file +name and target directory to store the image. +There is one very noticeable feature here: you can store a plot as a root +macro! In this macro, you find the C++ representation of all +methods and classes involved in generating the plot. This is a +valuable source of information for your own macros, which +you will hopefully write after having worked through this +tutorial. + + +Using ROOT's interactive capabilities is useful for +a first exploration of possibilities. Other ROOT classes you +will encounter in this tutorial have such graphical +interfaces. We will not comment further on this, +just be aware of the existence of ROOT's interactive features +and use them if you find convenient. +Some trial-and-error is certainly necessary +to find your way through the huge number of menus +and parameter settings. + +
+
+ROOT Beginners' FAQ + +At this point of the guide, some basic questions could have already come +to your mind. We will try to clarify some of them with further +explanations in the following. + +
+ROOT type declarations for basic data types + +In the official ROOT documentation, you find special data +types replacing the normal ones, e.g. +Double_t, Float_t or Int_t replacing +the standard double, float or int +types. Using the ROOT types makes it easier to port code +between platforms (64/32 bit) or operating systems +(windows/Linux), as these types are mapped to +suitable ones in the ROOT header files. If you want +adaptive code of this type, use the ROOT type declarations. +However, usually you do not need such adaptive code, and +you can safely use the standard C type declarations for your +private code, as +we did and will do throughout this guide. If you intend to become a +ROOT developer, however, you better stick to the official +coding rules! + +
+
+Configure ROOT at start-up + +The behaviour of a ROOT session can be tailored with the +options in the .rootrc file. +Examples of the tunable parameters are the ones related +to the operating and window system, to the fonts to be used, +to the location of start-up files. +At start-up, ROOT looks for a .rootrc file in +the following order: + + + ./.rootrc //local directory + $HOME/.rootrc //user directory + $ROOTSYS/etc/system.rootrc //global ROOT directory + +If more than one .rootrc files are found in the search +paths above, the options are merged, with precedence local, +user, global. +The parsing and interpretation of this file is handled by the +ROOT class TEnv. +Have a look to its documentation if you need such rather advanced +features. + +The file .rootrc defines the location of two rather +important files inspected at start-up: rootalias.C +and rootlogon.C. +They can contain code that needs to be loaded and executed at ROOT +startup. rootalias.C is only loaded and best used to define +some often used functions. +rootlogon.C contains code that will be +executed at startup: this file is extremely useful for example +to pre-load a custom style for the plots created with ROOT. +This is done most easily by creating a new +TStyle object with your preferred settings, +as described in the class reference guide, and then use +the command gROOT->SetStyle("MyStyleName"); to make +this new style definition the default one. +As an example, have a look in the file rootlogon.C +coming with this tutorial. +Another relevant file is rootlogoff.C that it called when +the session is finished. + +
+ +
+ROOT command history + +Every command typed at the ROOT prompt is stored in a +file .root_hist in your home directory. ROOT +uses this file to allow for navigation in the +command history with the up-arrow and down-arrow keys. +It is also convenient to extract successful +ROOT commands with the help of a text editor for use +in your own macros. + +
+ +
+ROOT Global Pointers + +All global pointers in ROOT begin with a small "g". Some of them +were already implicitly introduced (for example in ). +The most important among them are presented in the following: + + + + gROOT: +the gROOT variable is the entry point to the ROOT system. +Technically it is an instance of the TROOT class. +Using the gROOT pointer one has access to basically every object created +in a ROOT based program. +The TROOT object is essentially a container of several lists pointing +to the main ROOT objects. + + gRandom: +the gRandom variable is a variable that points to a random number generator +instance of the type TRandom3. +Such a variable is useful to access in every point of a program +the same random number generator, in order to achieve a good quality +of the random sequence. + + gStyle: +By default ROOT creates a default style that can be accessed via the +gStyle pointer. +This class includes functions to set some of the following object attributes. + + + Canvas + Pad + Histogram axis + Lines + Fill areas + Text + Markers + Functions + Histogram Statistics and Titles + + + gSystem: +An instance of a base class defining a generic interface to +the underlying Operating System, in our case TUnixSystem. + + + +At this point you have already learnt quite a bit about +some basic features of ROOT. + + +Please move on to become an expert! + +
+
+
diff --git a/docbook/primer/bibliography.xml b/docbook/primer/bibliography.xml new file mode 100644 index 0000000000000..3c715da1aef63 --- /dev/null +++ b/docbook/primer/bibliography.xml @@ -0,0 +1,55 @@ + + +Bibliography + + +ROOT + + RenéBrun + FonsRademakers + +ROOT - An Object Oriented Data Analysis Framework + +Proceedings AIHENP'96 Workshop +Lausanne, Sep. 1996, Nucl. Inst. and Meth. in Phys. Res. A 389 (1997) 81-86. + +
+See also http://root.cern.ch. +
+
+ + +ROOT_Users_Guide +
+http://root.cern.ch/drupal/content/users-guide +
+
+ + +ROOT_Class_Reference +
+http://root.cern.ch/drupal/content/reference-guide +
+
+ + +cint +
+http://root.cern.ch/drupal/content/cint +
+
+ + +MersenneTwister +
+http://www.math.keio.ac.jp/~matumoto/emt.html +
+
+ + +Fumili +I.N.Silin: FUMILI, CERN Program Library, D510, 1983 + + +
diff --git a/docbook/primer/concludingRemarks.xml b/docbook/primer/concludingRemarks.xml new file mode 100644 index 0000000000000..a2df173baf37d --- /dev/null +++ b/docbook/primer/concludingRemarks.xml @@ -0,0 +1,36 @@ + + + +Concluding Remarks + +This is the end of our guided tour for beginners through ROOT. +There is still a lot coming to mind to be said, but by now you +are experienced enough to use the ROOT documentation, most importantly +the ROOT home page and the + +ROOT reference guide with the documentation of all ROOT classes, +or the +ROOT users guide. + + +A very useful way for you to continue exploring ROOT is to study +the examples in the sub-directory tutorials/ of any +ROOT installation. + + +There are some powerful features of ROOT which were not treated in this +document, e.g. packages named RooFit and RooStats providing an advanced +framework for model building, fitting and statistical analysis. +The ROOT class TMVA offers multi-variate analysis tools +including an artificial neural network and many other advanced tools +for classification problems. +The remarkable ability of ROOT to handle large data volumes was +already mentioned in this guide, implemented through the +class TTree. But there is still much more for you to explore! + + +End of this guide ... but hopefully not of your interaction with ROOT ! + + diff --git a/docbook/primer/figures/ROOTPanel_FitPanel.png b/docbook/primer/figures/ROOTPanel_FitPanel.png new file mode 100644 index 0000000000000..8db5440eed81d Binary files /dev/null and b/docbook/primer/figures/ROOTPanel_FitPanel.png differ diff --git a/docbook/primer/figures/ROOTPanel_SetParameters.png b/docbook/primer/figures/ROOTPanel_SetParameters.png new file mode 100644 index 0000000000000..e46e6e3372d8c Binary files /dev/null and b/docbook/primer/figures/ROOTPanel_SetParameters.png differ diff --git a/docbook/primer/figures/TF1_DoubleSlit.png b/docbook/primer/figures/TF1_DoubleSlit.png new file mode 100644 index 0000000000000..b404691d0092b Binary files /dev/null and b/docbook/primer/figures/TF1_DoubleSlit.png differ diff --git a/docbook/primer/figures/TGraphErrors_Example.png b/docbook/primer/figures/TGraphErrors_Example.png new file mode 100644 index 0000000000000..ab7ff27be5057 Binary files /dev/null and b/docbook/primer/figures/TGraphErrors_Example.png differ diff --git a/docbook/primer/figures/TH1F_Example.png b/docbook/primer/figures/TH1F_Example.png new file mode 100644 index 0000000000000..7086132ef0bee Binary files /dev/null and b/docbook/primer/figures/TH1F_Example.png differ diff --git a/docbook/primer/figures/examplefit.png b/docbook/primer/figures/examplefit.png new file mode 100644 index 0000000000000..5c6faf7d56019 Binary files /dev/null and b/docbook/primer/figures/examplefit.png differ diff --git a/docbook/primer/figures/fitted2dFunction.png b/docbook/primer/figures/fitted2dFunction.png new file mode 100644 index 0000000000000..ccda91c508a78 Binary files /dev/null and b/docbook/primer/figures/fitted2dFunction.png differ diff --git a/docbook/primer/figures/functions.png b/docbook/primer/figures/functions.png new file mode 100644 index 0000000000000..811680641b8c7 Binary files /dev/null and b/docbook/primer/figures/functions.png differ diff --git a/docbook/primer/figures/graf_with_law.png b/docbook/primer/figures/graf_with_law.png new file mode 100644 index 0000000000000..37176f63c0379 Binary files /dev/null and b/docbook/primer/figures/graf_with_law.png differ diff --git a/docbook/primer/figures/graph_with_expectation.png b/docbook/primer/figures/graph_with_expectation.png new file mode 100644 index 0000000000000..b73c80022b977 Binary files /dev/null and b/docbook/primer/figures/graph_with_expectation.png differ diff --git a/docbook/primer/figures/histo_ratio.png b/docbook/primer/figures/histo_ratio.png new file mode 100644 index 0000000000000..f5d4994859b4c Binary files /dev/null and b/docbook/primer/figures/histo_ratio.png differ diff --git a/docbook/primer/figures/histo_sum.png b/docbook/primer/figures/histo_sum.png new file mode 100644 index 0000000000000..4d12cabfea145 Binary files /dev/null and b/docbook/primer/figures/histo_sum.png differ diff --git a/docbook/primer/figures/poisson.png b/docbook/primer/figures/poisson.png new file mode 100644 index 0000000000000..05928d7cc24c6 Binary files /dev/null and b/docbook/primer/figures/poisson.png differ diff --git a/docbook/primer/figures/polar_graph.png b/docbook/primer/figures/polar_graph.png new file mode 100644 index 0000000000000..28a5cd34131c2 Binary files /dev/null and b/docbook/primer/figures/polar_graph.png differ diff --git a/docbook/primer/figures/proj_and_prof.png b/docbook/primer/figures/proj_and_prof.png new file mode 100644 index 0000000000000..74d19db0fac22 Binary files /dev/null and b/docbook/primer/figures/proj_and_prof.png differ diff --git a/docbook/primer/figures/th2f.png b/docbook/primer/figures/th2f.png new file mode 100644 index 0000000000000..5dce47dfc98bd Binary files /dev/null and b/docbook/primer/figures/th2f.png differ diff --git a/docbook/primer/filio.xml b/docbook/primer/filio.xml new file mode 100644 index 0000000000000..c73d6134fe057 --- /dev/null +++ b/docbook/primer/filio.xml @@ -0,0 +1,448 @@ + + + +File I/O and Parallel Analysis + +
+Storing ROOT Objects + +ROOT offers the possibility to write the instances of all the classes +inheriting from the class TObject (basically all classes in ROOT) +on disk, into what is referred to as +ROOT-file, a file created by the TFile class. +One says that the object is made "persistent" by storing it on disk. +When reading the file back, the object can be restored to memory. + + +We can explore this functionality with histograms and two simple macros. + + + + + +Not bad, eh? Especially for a language that does not foresees persistency +natively like C++. +The RECREATE option forces ROOT to create a new file even if +a file with the same name exists on disk. + + +Now, you may use the CINT command line to access information in the +file and draw the previously written histogram: + + +>>> root my_rootfile.root +root [0] +Attaching file my_rootfile.root as _file0... +root [1] _file0.ls() +TFile** my_rootfile.root + TFile* my_rootfile.root + KEY: TH1F my_histogram;1 My Title +root [2] my_histogram.Draw() + + + +Alternatively, you can use a simple macro to carry out the job: + + + + + +Please note that the order of opening files for write access and creating +objects determines whether the objects are stored or not. You can avoid this +behaviour by using the Write() function as shown in the previous example. + + +Although you could be tempted to access an object within a file also with the +Get function and a C++ type cast, it is advisable to always use +GetObjectChecked. + +
+ +
+N-tuples in ROOT + +
Storing simple N-tuples + +Up to now we have seen how to manipulate input read from ASCII files. +ROOT offers the possibility to do much better than that, with its own +n-tuple classes. Among the many advantages provided by these classes one +could cite + + + + Optimised disk I/O. + Possibility to store many n-tuple rows. + Write the n-tuples in ROOT files. + Interactive inspection with TBrowser. + Store not only numbers, but also objects in the columns. + + + +In this section we will discuss briefly the TNtuple class, which is +a simplified version of the TTree class. +A ROOT TNtuple object can store rows of float entries. +Let's tackle the problem according to the usual strategy commenting a +minimal example + + + + + +This data written to this example n-tuple represents, in the statistical +sense, three independent variables (Potential or Voltage, Pressure and +Temperature), and one variable (Current) which depends on the +others according to very simple laws, and an additional Gaussian +smearing. +This set of variables mimics a measurement of an electrical resistance +while varying pressure and temperature. + + +Imagine your task now consists in finding the relations +among the variables -- of course without knowing the code used to generate +them. +You will see that the possibilities of the NTuple class enable you +to perform this analysis task. Open the ROOT file (cond_data.root) +written by the macro above in an interactive section and use a +TBrowser +to interactively inspect it: + + +root[0] new TBrowser() + + +You find the columns of your n-tuple written +as leafs. Simply clicking on them you can obtain histograms +of the variables! + + +Next, try the following commands at the shell prompt and in the +interactive ROOT shell, respectively: + + +> root conductivity_experiment.root +Attaching file conductivity_experiment.root as _file0... +root [0] cond_data.Draw("Current:Potential") + + +You just produced a correlation plot with one single line of code! + + +Try to extend the syntax typing for example + + +root [1] cond_data.Draw("Current:Potential","Temperature<270") + + +What do you obtain? + + +Now try + + +root [2] cond_data.Draw("Current/Potential:Temperature") + + +It should have become clear from these examples how to navigate in such +a multi-dimensional space of variables and unveil relations between +variables using n-tuples. + +
+ +
Reading N-tuples + +For completeness, you find here a small macro to read the data back from a ROOT n-tuple + + + + + +The macro shows the easiest way of accessing the content of a n-tuple: after loading the n-tuple, its branches are +assigned to variables and GetEntry(long) automatically fills them with the content for a specific row. +By doing so, the logic for reading the n-tuple and the code to process it can be split and the source code remains clear. + +
+ +
Storing Arbitrary N-tuples + + +It is also possible to write n-tuples of arbitrary type by using ROOT's +TBranch class. This is especially important as TNtuple::Fill() +accepts only floats. The following macro creates the same n-tuple as before +but the branches are booked directly. The Fill() function then fills +the current values of the connected variables to the tree. + + + + + +The Branch() function requires a pointer to a variable and a definition +of the variable type. lists some of the +possible values. Please note that ROOT is not checking the input and mistakes +are likely to result in serious problems. This holds especially if values are +read as another type than they have been written, e.g. when storing a variable +as float and reading it as double. + + + +List of variable types that can be used to define the type of a branch in ROOT. + Variable types + + + + type + size + C++ + identifier + + + + + signed integer + 32 bit + int + I + + + + 64 bit + long + L + + + unsigned integer + 32 bit + unsigned int + i + + + + 64 bit + unsigned long + l + + + floating point + 32 bit + float + F + + + + 64 bit + double + D + + + boolean + - + bool + O + + + +
+ +
+ +
Processing N-tuples Spanning over Several Files + +Usually n-tuples or trees span over many files and it would be difficult to +add them manually. ROOT thus kindly provides a helper class in the form of +TChain. Its usage is shown in the following macro which is very similar +to the previous example. The constructor of a TChain takes the name of +the TTree (or TNuple) as an argument. The files are added with +the function Add(fileName), where one +can also use wild-cards as shown in the example. + + + + +
+ +
<emphasis> For the advanced user:</emphasis> Processing trees with a selector script + +Another very general and powerful way of processing a TChain is +provided via the method TChain::Process(). This method takes as +arguments an instance of a -- user-implemented-- class of type +TSelector, and -- optionally -- the number of entries and the first +entry to be processed. A template for the +class TSelector is provided by the method TTree::MakeSelector, +as is shown in the little macro makeSelector.C below. + + +It opens the n-tuple +conductivity_experiment.root from the example above and creates from it +the header file +MySelector.h and a template to insert your own analysis code, +MySelector.C. + + + + + +The template contains the entry points +Begin() and +SlaveBegin() called before processing of the TChain starts, +Process() called for every entry of the chain, and +SlaveTerminate() and Terminate() called after the last +entry has been processed. Typically, initialization like booking of histograms +is performed in SlaveBegin(), the analysis, i.e. the +selection of entries, calculations and filling of histograms, is done in +Process(), and final operations like plotting and storing of +results happen in SlaveTerminate() or Terminate(). + + +The entry points SlaveBegin() and SlaveTerminate() are called on +so-called slave nodes only if parallel processing via PROOF or +PROOF lite is enabled, as will be explained below. + + +A simple example of a selector class is shown in the macro MySelector.C. +The example is executed with the following sequence of commands: + + +> TChain *ch=new TChain("cond_data", "Chain for Example N-Tuple"); +> ch->Add("conductivity_experiment*.root"); +> ch->Process("MySelector.C+"); + + +As usual, the "+" appended to the name of the macro to be executed +initiates the compilation of the MySelector.C with the system compiler +in order to improve performance. + + +The code in MySelector.C, shown in the listing below, books some histograms in +SlaveBegin() and adds them to the instance fOutput, which is of the class +TList The usage of fOutput is not really needed for this simple +example, but it allows re-usage of the exact code in parallel processing with PROOF +(see next section).. The final processing in Terminate() allows to access histograms and store, +display or save them as pictures. This is shown in the example via the TList +fOutput. See the commented listing below for more details; most of the text is actually +comments generated automatically by TTree::MakeSelector. + + + +
+ +
<emphasis> For power-users:</emphasis> Multi-core processing with <code>PROOF lite</code> + +The processing of n-tuples via a selector function of type TSelector +through TChain::Process(), as described at the end of the previous +section, offers an additional advantage in particular for very large +data sets: on distributed systems or multi-core architectures, portions +of data can be processed in parallel, thus significantly reducing the execution +time. On modern computers with multi-core CPUs or hyper-threading +enabled, this allows a much faster turnaround of analyses, since all the +available CPU power is used. + + +On distributed systems, a PROOF server and worker nodes have to be set up, as +described in detail in the ROOT documentation. On a single computer with multiple +cores, PROOF lite can be used instead. Try the following little macro, +RunMySelector.C, which contains two extra lines compared to +the example above (adjust the number of workers according to the number of CPU cores): + + + + +The first command, TProof::Open(const char*) starts a local PROOF server +(if no arguments are specified, all cores will be used), and the +command ch->SetProof(); enables processing of the chain using PROOF. +Now, when issuing the command ch->Process("MySelector.C+);, the +code in MySelector.C is compiled and executed on each slave node. +The methods Begin() and Terminate() are executed on +the master only. +The list of n-tuple files is analysed, and portions of the data are assigned +to the available slave processes. Histograms booked in SlaveBegin() +exist in the processes on the slave nodes, and are filled accordingly. Upon +termination, the PROOF master collects the histograms from the slaves and +merges them. In Terminate() all merged histograms are available and +can be inspected, analysed or stored. +The histograms are handled via the instances fOutput of class +TList in each slave process, and can be retrieved from this +list after merging in Terminate. + + +To explore the power of this mechanism, generate some very large n-tuples +using the script from - you could try 10 000 000 +events (this results in a large n-tuple of +about 160 MByte in size). You could also generate a large number of +files and use wildcards to add the to the TChain. Now execute: +> root -l RunMySelector.C +and watch what happens: + + +Processing RunMySelector.C... + +++ Starting PROOF-Lite with 4 workers +++ +Opening connections to workers: OK (4 workers) +Setting up worker servers: OK (4 workers) +PROOF set to parallel mode (4 workers) + +Info in <TProofLite::SetQueryRunning>: starting query: 1 +Info in <TProofQueryResult::SetRunning>: nwrks: 4 +Info in <TUnixSystem::ACLiC>: creating shared library + ~/DivingROOT/macros/MySelector_C.so +*==* ----- Begin of Job ----- Date/Time = Wed Feb 15 23:00:04 2012 +Looking up for exact location of files: OK (4 files) +Looking up for exact location of files: OK (4 files) +Info in <TPacketizerAdaptive::TPacketizerAdaptive>: + Setting max number of workers per node to 4 +Validating files: OK (4 files) +Info in <TPacketizerAdaptive::InitStats>: + fraction of remote files 1.000000 +Info in <TCanvas::Print>: + file ResistanceDistribution.png has been created +*==* ----- End of Job ----- Date/Time = Wed Feb 15 23:00:08 2012 +Lite-0: all output objects have been merged + + +Log files of the whole processing chain are kept in the directory +~.proof for each worker node. This is very helpful for debugging or if +something goes wrong. As the method described here also works without +using PROOF, the development work on an analysis script can be done in the +standard way on a small subset of the data, and only for the full +processing one would use parallelism via PROOF. + + +It is worth to remind the reader that the speed of typical data analysis programs +limited by the I/O speed (for example the latencies implied by reading data +from a hard drive). +It is therefore expected that this limitation cannot be eliminated with the usage of +any parallel analysis toolkit. + +
+ +
Optimisation Regarding N-tuples + +ROOT automatically applies compression algorithms on n-tuples to reduce the memory +consumption. A value that is in most cases only zero will consume only small space on +your disk (but it has to be deflated on reading). Nevertheless, you should think about +the design of your n-tuples and your analyses as soon as the processing time exceeds +some minutes. + + + + Try to keep your n-tuples simple and use appropriate variable types. If your + measurement has only a limited precision, it is needless to store it with double precision. + Experimental conditions that do not change with every single measurement should be + stored in a separate tree. Although the compression can handle redundant values, the + processing time increase with every variable that has to be filled. + The function SetCacheSize(long) specifies the size of the cache for reading + a TTree object from a file. The default value is 30MB. A manual increase may help + in certain situations. Please note that the caching mechanism can cover only one + TTree object per TFile object. + You can select the branches to be covered by the caching algorithm with + AddBranchToCache and deactivate unneeded branches with SetBranchStatus. + This mechanism can result in a significant speed-up for simple operations on trees with many branches. + You can measure the performance easily with TTreePerfStats. The ROOT + documentation on this class also includes an introductory example. For example, + TTreePerfStats can show you that it is beneficial to store meta data and + payload data separately, i.e. write the meta data tree in a bulk to a file at + the end of your job instead of writing both trees interleaved. + +
+
+
\ No newline at end of file diff --git a/docbook/primer/functions_and_parameter_estimation.xml b/docbook/primer/functions_and_parameter_estimation.xml new file mode 100644 index 0000000000000..537debafa0cf4 --- /dev/null +++ b/docbook/primer/functions_and_parameter_estimation.xml @@ -0,0 +1,207 @@ + + + + +Functions and Parameter Estimation + +After going through the previous chapters, you already know how +to use analytical functions (class TF1), +and you got some insight into +the graph (TGraphErrors) and +histogram classes (TH1F) for data visualisation. +In this chapter we will add more detail to +the previous approximate explanations to face the +fundamental topic of parameter estimation by fitting +functions to data. For graphs and histograms, ROOT offers +an easy-to-use interface to perform fits - either the fit panel +of the graphical interface, or the Fit method. +The class TFitResult allows access to the detailed +results. + + + +Very often it is necessary to study the statistical properties of +analysis procedures. This is most easily achieved by applying the +analysis to many sets of simulated data (or "pseudo data"), +each representing one possible version of the true experiment. +If the simulation only deals with the final distributions +observed in data, and does not perform a full simulation +of the underlying physics and the experimental apparatus, +the name "Toy Monte Carlo" is frequently used +"Monte Carlo" simulation means that random numbers play a +role here which is as crucial as in games of pure chance +in the Casino of Monte Carlo.. +Since the true values of all parameters are known in the pseudo-data, +the differences between the parameter estimates from the analysis procedure +w.r.t. the true values can be determined, and it is also possible to +check that the analysis procedure provides correct error estimates. + + +
+Fitting Functions to Pseudo Data + +In the example below, a pseudo-data set is produced and a +model fitted to it. + + +ROOT offers various minimization algorithms to minimize a chi2 or a negative +log-likelihood function. +The default minimizer is MINUIT, a package originally implemented in the +FORTRAN programming language. +A C++ version is also available, MINUIT2, as well as Fumili Fumili +an algorithm optimized for fitting. +Genetic algorithms and a stochastic minimizer based on simulated annealing +are also available. +The minimization algorithms can be selected using the static functions of +the ROOT::Math::MinimizerOptions class. +Steering options for the minimizer, such as the convergence tolerance or +the maximum number of function calls, can also be set using the methods of +this class. +All currently implemented minimizers are documented in the reference +documentation of ROOT: have a look for example to the +ROOT::Math::Minimizer class documentation. + + +The complication level of the code below is intentionally +a little higher than in the previous examples. The graphical output +of the macro is shown in : + + + + + +Some step by step explaination is at this point necessary: + + + + Lines 1-3: A simple function to ease the make-up of lines. +Remember that the class TF1 inherits from TAttLine. + Lines 5-7 : Definition of a customised function, namely a Gaussian +(the "signal") plus a parabolic function, the "background". + Lines 10-12: Some maquillage for the Canvas. In particular we +want that the parameters of the fit appear very clearly and nicely on the plot. + Lines 20-25: Define and initialise an instance of TF1. + Lines 27-32: Define and fill a histogram. + Lines 34-40: For convenience, the same function as for the generation of +the pseudo-data is used in the fit; hence, we need to reset the function + parameters. This part of the code is very important for each fit procedure, + as it sets the initial values of the fit. + Line 43: A very simple command, well known by now: fit the function to +the histogram. + Lines 45-49: Retrieve the output from the fit. +Here, we simply print the fit result and access and print the +covariance matrix of the parameters. +Lines 58-end: Plot the pseudo-data, the fitted function and the +signal and background components at the best-fit values. + + +
Fit of pseudo data: a signal shape over a background trend. +This plot is another example of how making a plot "self-explanatory" +can help you better displaying your results. +Fit of pseudo data + + + + + +
+ +
+ +
+Toy Monte Carlo Experiments + +Let us look at a simple example of a toy experiment comparing +two methods to fit a function to a +histogram, the + + + +χ +2 + + + + + +method and a method called "binned +log-likelihood fit", both available in ROOT. + + +As a very simple yet powerful quantity to check the quality of the +fit results, we construct for each pseudo-data set the +so-called "pull", the difference of the estimated and the true +value of a parameter, normalised to the estimated error +on the parameter, + + + + + + +( + +p +estim + +- + +p +true + +) + + + + +σ +p + + + + + +. + + +If everything is OK, the distribution of the pull values is a +standard normal distribution, i.e. a Gaussian distribution +centred around zero with a standard deviation of one. + + +The macro performs a rather big number of toy experiments, +where a histogram is repeatedly filled with Gaussian distributed +numbers, representing the pseudo-data in this example. Each time, +a fit is performed according to the selected method, and the +pull is calculated and filled into a histogram. Here is the code: + + + + + +Your present knowledge of ROOT should be enough to understand all the +technicalities behind the macro. Note that +the variable pull in line 59 is different from the +definition above: instead of the parameter error on mean, +the fitted standard deviation of the distribution divided by the +square root of the number of entries, sig/sqrt(n_tot_entries), +is used. + + + + What method exhibits the better performance with the default +parameters? +What happens if you increase the number of entries per histogram +by a factor of ten? Why? + + + +The answers to these questions are well beyond the scope of this guide. +Basically all books about statistical methods provide a complete treatement +of the aforementioned topics. + +
+
diff --git a/docbook/primer/graphs.xml b/docbook/primer/graphs.xml new file mode 100644 index 0000000000000..7f9e34646338a --- /dev/null +++ b/docbook/primer/graphs.xml @@ -0,0 +1,162 @@ + + + +Graphs + +In this Chapter we will learn how to exploit some of the +functionalities that ROOT provides to display +data exploiting the class TGraphErrors, which you already got +to know previously. + + +
+Read Graph Points from File + +The fastest way in which you can fill a graph with experimental data +is to use the constructor which reads data points and their +errors from a file in ASCII (i.e. standard text) format: + +TGraphErrors(const char *filename, +const char *format="%lg %lg %lg %lg", Option_t *option=""); + +The format string can be: + + + "\%lg \%lg" read only 2 first columns into X,Y + "\%lg \%lg \%lg" read only 3 first columns into X,Y and EY + "\%lg \%lg \%lg \%lg" read only 4 first columns into X,Y,EX,EY + + +This approach has the nice feature of allowing the user to reuse the +macro for many different data sets. +Here is an example of an input file. The nice graphic result shown +is produced by the macro below, which reads two such input files and uses +different options to display the data points.\\ + + + + + + + + + + file: macro2_input.txt + + + + + + + + + + + + + + + + +In addition to the inspection of the plot, you can check the actual contents of +the graph with the TGraph::Print() method at +any time, obtaining a printout of the coordinates of data +points on screen. The macro also shows us how to print a +coloured band around a graph instead of error bars, quite +useful for example to represent the errors of a +theoretical prediction. + +
+ +
+Polar Graphs + +With ROOT you can profit from rather advanced plotting routines, like the +ones implemented in the TPolarGraph, a class to draw graphs in polar +coordinates. It is very easy to use, as you see in the example macro and the +resulting : + + + + + +A new element was added on line 4, the size of the canvas: it is sometimes +optically better to show plots in specific canvas sizes. + + +
The graph of a fan obtained with ROOT. +Graph of a fan + + + + + +
+ +
+ +
+2D Graphs + +Under specific circumstances, it might be useful to plot some quantities versus two +variables, therefore creating a bi-dimensional graph. Of course ROOT can +help you in this task, with the TGraph2DErrors class. +The following macro produces a bi-dimensional graph representing a +hypothetical measurement, fits a bi-dimensional function to it and +draws it together with its +x and y projections. Some points of the code will be explained in detail. +This time, the graph is populated with data points using random numbers, +introducing a new and very important ingredient, the ROOT TRandom3 +random number generator using the Mersenne Twister +algorithm MersenneTwister. + + + + + +Let's go through the code, step by step to understand what is going on: + + + + Line 3: This sets the palette colour code to a much nicer one than +the default. Comment this line to give it a try. + + Line 7: The instance of the random generator. You can then draw out of +this instance random numbers distributed according to different probability +density functions, like the Uniform one at lines 27-29. +See the on-line documentation to appreciate the full power of this ROOT +feature. + + Line 12: You are already familiar with the TF1 class. +This is its two-dimensional correspondent. At line 24 two random numbers distributed +according to the TF2 formula are drawn with the method +TF2::GetRandom2(double& a, double&b). + + Line 27-29: Fitting a 2-dimensional function just works like in the + one-dimensional case, i.e. initialisation of parameters and calling of the + Fit() method. + + Line 32: The Surf1 option draws the TF2 objects (but +also bi-dimensional histograms) as coloured surfaces with a wire-frame on +three-dimensional canvases. See + + Line 37-41: Here you learn how to create a canvas, partition it in +two sub-pads and access them. It is very handy to show multiple plots in +the same window or image. + + + +
A dataset fitted with a bidimensional function visualised as a colored surface. +A dataset fitted + + + + + +
+ +
+
diff --git a/docbook/primer/histograms.xml b/docbook/primer/histograms.xml new file mode 100644 index 0000000000000..286b4a7ba9f1b --- /dev/null +++ b/docbook/primer/histograms.xml @@ -0,0 +1,189 @@ + + + +Histograms + + +Histograms play a fundamental role in any type of physics analysis, not only +to visualise measurements but being a powerful form of data reduction. +ROOT offers many classes that represent histograms, all inheriting from the +TH1 class. +We will focus in this chapter on uni- and bi- dimensional +histograms whose bin-contents are represented by floating point numbers +To optimise the memory usage you might go for one byte (TH1C), +short (TH1S), integer (TH1I) or double-precision (TH1D) bin-content., +the TH1F and TH2F classes respectively. + + +
+Your First Histogram + +Let's suppose you want to measure the counts of a Geiger detector put +in proximity of a radioactive source in a given time interval. +This would give you an idea of the activity of your source. +The count distribution in this case is a Poisson distribution. +Let's see how operatively you can fill and draw a histogram with the +following example macro. + + + + + +Which gives you the following plot (): + + +
The result of a counting (pseudo) experiment. +Only bins corresponding to integer values are filled given the discrete +nature of the poissonian distribution. +Counting experiment + + + + + +
+ + +Using histograms is rather simple. The main differences with respect to +graphs that emerge from the example are: + + + +line 5: The histograms have a name and a title right from the start, no +predefined number of entries but a number of bins and a lower-upper range. +line 15: An entry is stored in the histogram through the +TH1F::Fill method. + line 19 and 22: The histogram can be drawn also normalised, ROOT +automatically takes cares of the necessary rescaling. +line 25 to 31: This small snippet shows how easy it is to access the +moments and associated errors of a histogram. + + +
+ +
+Add and Divide Histograms + +Quite a large number of operations can be carried out with histograms. +The most useful are addition and division. +In the following macro we will learn how to manage these procedures +within ROOT. + + + + + +The plots that you will obtain are shown in + + + +
The sum of two histograms and the ratio. +Sum of two histograms + + + + + + + + + + + + + + + + + + + + + + +
+ + +Some lines now need a bit of clarification: + + + + line 3: CINT, as we know, +is also able to interpret more than one function per file. +In this case the function simply sets up some parameters to conveniently +set the line of histograms. + line 20 to 22: Some contracted C++ syntax for conditional statements is +used to fill the histograms with different numbers of entries inside the loop. + line 27: This is a crucial step for the sum and ratio of histograms +to handle errors properly. +The method TH1::Sumw2 makes sure that the squares of weights are +stored inside the histogram (equivalent to the number of entries per bin if +weights of 1 are used). This information is needed to correctly calculate +the errors of each bin entry when the methods TH1::Add +and TH1::Divide are invoked. + line 33: The sum of two histograms. A weight can be assigned to the added +histogram, for example to comfortably switch to subtraction. + line 44: The division of two histograms is rather straightforward. + line 53 to 63: When you draw two quantities and their ratios, it is +much better if all the information is condensed in one single plot. These +lines provide a skeleton to perform this operation. + + +
+ +
+Two-dimensional Histograms + +Two-dimensional histograms are a very useful tool, for example to inspect +correlations between variables. You can exploit the bi-dimensional histogram +classes provided by ROOT in a very simple way. Let's see how in the following +macro: + + + + + +Two kinds of plots are provided within the code, the first one containing +three-dimensional representations () +and the second one projections and profiles () +of the bi-dimensional histogram. + + +
Different ways of representing bi-dimensional histograms. +Representing bi-dimensional histograms + + + + + +
+ +
The projections and profiles of bi-dimensional histograms. +Projections and profiles + + + + + +
+ + +When a projection is performed along the x (y) direction, for every bin along +the x (y) axis, all bin contents along the y (x) axis are summed up (upper +the plots of ). +When a profile is performed along the x (y) direction, for every bin along +the x (y) axis, the average of all the bin contents along the y (x) is +calculated together with their RMS and displayed +as a symbol with error bar (lower two plots of ). + + +Correlations between the variables are quantified by the methods +Double_t GetCovariance() +and Double_t GetCorrelationFactor(). + +
+ +
diff --git a/docbook/primer/macros/ExampleData.txt b/docbook/primer/macros/ExampleData.txt new file mode 100644 index 0000000000000..3b5e43dc5abeb --- /dev/null +++ b/docbook/primer/macros/ExampleData.txt @@ -0,0 +1,9 @@ +# fake data to demonstrate the use of TGraphErrors + +# x y ex ey + 1. 0.4 0.1 0.05 + 1.3 0.3 0.05 0.1 + 1.7 0.5 0.15 0.1 + 1.9 0.7 0.05 0.1 + 2.3 1.3 0.07 0.1 + 2.9 1.5 0.2 0.1 diff --git a/docbook/primer/macros/ExampleMacro.C b/docbook/primer/macros/ExampleMacro.C new file mode 100644 index 0000000000000..cc6a2bec0bfdf --- /dev/null +++ b/docbook/primer/macros/ExampleMacro.C @@ -0,0 +1,70 @@ +/*************************************************************************** + * -------------------------------------------------------------------------- + * Template to exercise ROOT code + * -> Plot a normalized Gaussian with mean = 5.0 and sigma = 1.5 + * and its derivative and integral in the range of 0 to 10 + * -------------------------------------------------------------------------- + * initial version: 21-Aug-2008 G. Quast + * + * modification log: + ***************************************************************************/ + +/* + * Note that this file can be either used as a compiled program + or as a ROOT macro. + * If it is used as a compiled program, additional include statements + and the definition of the main program have to be made. This is + not needed if the code is executed at the ROOT prompt. + */ + +//#ifndef __CINT__ // These include-statements are needed if the program is +#include "TFile.h" // run as a "stand-alone application", i.e. if it is not +#include "TH1F.h" // called from an interactive ROOT session. +#include "TCanvas.h" +#include "TMath.h" +// eventually, load some C libraries +#include + +void ExampleMacro(); + +//______________________________________________________________________________ +int main() +{ + ExampleMacro(); + return 0; +} +//#endif + +//______________________________________________________________________________ + +/* + * From here on, the code can also be used as a macro + * Note though, that CINT may report errors where there are none + in C++. E.g. this happens here where CINT says that f1 is + out of scope ... + + ==>> put your code here + (remember to update the name of you Macro in the + lines above if you intend to comile the code) + */ +void ExampleMacro() { + // Create a histogram, fill it with random gaussian numbers + TH1F *h = new TH1F ("h", "example histogram", 100, -5.,5.); + h->FillRandom("gaus",1000); + + // draw the histogram + h->DrawClone(); + +/* - Create a new ROOT file for output + - Note that this file may contain any kind of ROOT objects, histograms, + pictures, graphics objects etc. + - the new file is now becoming the current directory */ + TFile *f1 = new TFile("ExampleMacro.root","RECREATE","ExampleMacro"); + + // write Histogram to current directory (i.e. the file just opened) + h->Write(); + + // Close the file. + // (You may inspect your histogram in the file using the TBrowser class) + f1->Close(); +} diff --git a/docbook/primer/macros/ExampleMacro_GUI.C b/docbook/primer/macros/ExampleMacro_GUI.C new file mode 100644 index 0000000000000..eaf19bde37f01 --- /dev/null +++ b/docbook/primer/macros/ExampleMacro_GUI.C @@ -0,0 +1,55 @@ +/* + This piece of code demonstrates how a root macro is used as a standalone + application with full acces the grapical user interface (GUI) of ROOT */ + +// include ALL header files needed +#ifndef __CINT__ +#include "TROOT.h" +#include "TApplication.h" +#include "TBrowser.h" +#include "TFile.h" +#include "TH1F.h" +#include "TCanvas.h" +#include "TMath.h" +#endif +// eventually, include some additoinal C or C++ libraries +#include + +// ==>> put the code of your macro here +void ExampleMacro_GUI() { + // Create a histogram, fill it with random gaussian numbers + TH1F *h = new TH1F ("h", "example histogram", 100, -5.,5.); + h->FillRandom("gaus",1000); + + // draw the histogram + h->DrawClone(); + +/* - Create a new ROOT file for output + - Note that this file may contain any kind of ROOT objects, histograms, + pictures, graphics objects etc. + - the new file is now becoming the current directory */ + TFile *f1 = new TFile("ExampleMacro.root","RECREATE","ExampleMacro"); + + // write Histogram to current directory (i.e. the file just opened) + h->Write(); + + // Close the file. + // (You may inspect your histogram in the file using the TBrowser class) + f1->Close(); +} + +// the "dressing" code for a stand-alone ROOT application starts here +#ifndef __CINT__ +void StandaloneApplication(int argc, char** argv) { + // ==>> here the ROOT macro is called + ExampleMacro_GUI(); +} + +// This is the standard main of C++ starting a ROOT application +int main(int argc, char** argv) { + TApplication app("Root Application", &argc, argv); + StandaloneApplication(app.Argc(), app.Argv()); + app.Run(); + return 0; +} +#endif diff --git a/docbook/primer/macros/MySelector.C b/docbook/primer/macros/MySelector.C new file mode 100644 index 0000000000000..6599b599f21c9 --- /dev/null +++ b/docbook/primer/macros/MySelector.C @@ -0,0 +1,146 @@ +#define MySelector_cxx +// The class definition in MySelector.h has been generated +// automatically by the ROOT utility TTree::MakeSelector(). +// This class is derived from the ROOT class TSelector. For +// more information on the TSelectorframework see +// $ROOTSYS/README/README.SELECTOR or the ROOT User Manual. + +// The following methods are defined in this file: +// Begin(): called every time a loop on the tree starts, +// a convenient place to create your histograms. +// SlaveBegin(): called after Begin(), when on PROOF called +// only on the slave servers. +// Process(): called for each event, in this function you +// decide what to read and fill your histograms. +// SlaveTerminate: called at the end of the loop on the tree, +// when on PROOF called only on the slave +// servers. +// Terminate(): called at the end of the loop on the tree, a +// convenient place to draw/fit your histograms. +// +// To use this file, try the following session on your Tree T: +// +// Root > T->Process("MySelector.C") +// Root > T->Process("MySelector.C","some options") +// Root > T->Process("MySelector.C+") +// + +#include "MySelector.h" +#include +#include +#include + +// user defined variables may come here: +UInt_t fNumberOfEvents; TDatime tBegin, tNow; + +TH1F *h_pot,*h_cur,*h_temp,*h_pres,*h_resistance; + +void MySelector::Begin(TTree * /*tree*/) +{ + // The Begin() function is called at the start of the query. + // When running with PROOF Begin() is only called on the client. + // The tree argument is deprecated (on PROOF 0 is passed). + + TString option = GetOption(); + + // some time measurement + tBegin.Set(); printf("*==* ---------- Begin of Job ----------"); + tBegin.Print(); +} + +void MySelector::SlaveBegin(TTree * /*tree*/) +{ + // The SlaveBegin() function is called after the Begin() + // function. When running with PROOF SlaveBegin() is called on + // each slave server. The tree argument is deprecated + // (on PROOF 0 is passed). + + TString option = GetOption(); + + //book some histograms + h_pot=new TH1F("pot","potential",100,-0.5,10.5); + h_cur=new TH1F("cur","current",100,-0.1,1.5); + h_temp=new TH1F("temp","temperature",100,200.,400.); + h_pres=new TH1F("pres","pressure",100,-0.,2.); + h_resistance=new TH1F("resistance","resistance",100,5.,15.); + + // add all booked histograms to output list + // (only really needed for PROOF) + fOutput->AddAll(gDirectory->GetList()); +} + +Bool_t MySelector::Process(Long64_t entry) +{ + // The Process() function is called for each entry in the tree + // (or possibly keyed object in the case of PROOF) to be + // processed. The entry argument specifies which entry in the + // currently loaded tree is to be processed. It can be passed to + // either MySelector::GetEntry() or TBranch::GetEntry() + // to read either all or the required parts of the data. When + // processing // keyed objects with PROOF, the object is already + // loaded and is available via the fObject pointer. + // + // This function should contain the "body" of the analysis. It + // can contain simple or elaborate selection criteria, run + // algorithms on the data // of the event and typically fill + // histograms. + // + // The processing can be stopped by calling Abort(). + // + // Use fStatus to set the return value of TTree::Process(). + // + // The return value is currently not used. + +// - - - - - - - - - begin processing + GetEntry(entry); + + // count number of entries (=events) ... + ++fNumberOfEvents; + + // analsiys code comes here - fill histograms + h_pot->Fill(Potential); + h_cur->Fill(Current); + h_temp->Fill(Temperature); + h_pres->Fill(Pressure); + h_resistance->Fill(Potential/Current); + + return kTRUE; //kFALSE would abort processing +} + +void MySelector::SlaveTerminate() +{ + // The SlaveTerminate() function is called after all entries or + // objects have been processed. When running with PROOF + // SlaveTerminate() is called on each slave server. + + // some statistics at end of job + printf("\n *==* ---------- End of Slave Job ---------- "); + tNow.Set(); tNow.Print(); + printf( + "Number of Events: %i, elapsed time: %i sec, rate: %g evts/sec\n" + ,fNumberOfEvents, + tNow.Convert()-tBegin.Convert(), + float(fNumberOfEvents)/(tNow.Convert()-tBegin.Convert()) ); +} + +void MySelector::Terminate() +{ + // The Terminate() function is the last function to be called + // during a query. It always runs on the client, it can be used + // to present the results graphically or save the results to + // file. + + // finally, store all output + TFile hfile("MySelector_Result.root","RECREATE","MuonResults"); + fOutput->Write(); + + //Example to retrieve output from output list + h_resistance= + dynamic_cast(fOutput->FindObject("resistance")); + TCanvas c_result("cresult","Resistance",100,100,300,300); + h_resistance->Draw(); + c_result.SaveAs("ResistanceDistribution.png"); + + tNow.Set(); printf("*==* ---------- End of Job ---------- "); + tNow.Print(); +} diff --git a/docbook/primer/macros/MySelector.h b/docbook/primer/macros/MySelector.h new file mode 100644 index 0000000000000..6cd5d4761e4f7 --- /dev/null +++ b/docbook/primer/macros/MySelector.h @@ -0,0 +1,86 @@ +////////////////////////////////////////////////////////// +// This class has been automatically generated on +// Wed Feb 15 15:45:38 2012 by ROOT version 5.30/01 +// from TTree cond_data/Example N-Tuple +// found on file: conductivity_experiment_1.root +////////////////////////////////////////////////////////// + +#ifndef MySelector_h +#define MySelector_h + +#include +#include +#include +#include + +class MySelector : public TSelector { +public : + TTree *fChain; //!pointer to the analyzed TTree or TChain + + // Declaration of leaf types + Float_t Potential; + Float_t Current; + Float_t Temperature; + Float_t Pressure; + + // List of branches + TBranch *b_Potential; //! + TBranch *b_Current; //! + TBranch *b_Temperature; //! + TBranch *b_Pressure; //! + + MySelector(TTree * /*tree*/ =0) { } + virtual ~MySelector() { } + virtual Int_t Version() const { return 2; } + virtual void Begin(TTree *tree); + virtual void SlaveBegin(TTree *tree); + virtual void Init(TTree *tree); + virtual Bool_t Notify(); + virtual Bool_t Process(Long64_t entry); + virtual Int_t GetEntry(Long64_t entry, Int_t getall = 0) { return fChain ? fChain->GetTree()->GetEntry(entry, getall) : 0; } + virtual void SetOption(const char *option) { fOption = option; } + virtual void SetObject(TObject *obj) { fObject = obj; } + virtual void SetInputList(TList *input) { fInput = input; } + virtual TList *GetOutputList() const { return fOutput; } + virtual void SlaveTerminate(); + virtual void Terminate(); + + ClassDef(MySelector,0); +}; + +#endif + +#ifdef MySelector_cxx +void MySelector::Init(TTree *tree) +{ + // The Init() function is called when the selector needs to initialize + // a new tree or chain. Typically here the branch addresses and branch + // pointers of the tree will be set. + // It is normally not necessary to make changes to the generated + // code, but the routine can be extended by the user if needed. + // Init() will be called many times when running on PROOF + // (once per file to be processed). + + // Set branch addresses and branch pointers + if (!tree) return; + fChain = tree; + fChain->SetMakeClass(1); + + fChain->SetBranchAddress("Potential", &Potential, &b_Potential); + fChain->SetBranchAddress("Current", &Current, &b_Current); + fChain->SetBranchAddress("Temperature", &Temperature, &b_Temperature); + fChain->SetBranchAddress("Pressure", &Pressure, &b_Pressure); +} + +Bool_t MySelector::Notify() +{ + // The Notify() function is called when a new file is opened. This + // can be either for a new TTree in a TChain or when when a new TTree + // is started when using PROOF. It is normally not necessary to make changes + // to the generated code, but the routine can be extended by the + // user if needed. The return value is currently not used. + + return kTRUE; +} + +#endif // #ifdef MySelector_cxx diff --git a/docbook/primer/macros/MySelector_0.C b/docbook/primer/macros/MySelector_0.C new file mode 100644 index 0000000000000..7a26840a20ecf --- /dev/null +++ b/docbook/primer/macros/MySelector_0.C @@ -0,0 +1,89 @@ +#define MySelector_cxx +// The class definition in MySelector.h has been generated automatically +// by the ROOT utility TTree::MakeSelector(). This class is derived +// from the ROOT class TSelector. For more information on the TSelector +// framework see $ROOTSYS/README/README.SELECTOR or the ROOT User Manual. + +// The following methods are defined in this file: +// Begin(): called every time a loop on the tree starts, +// a convenient place to create your histograms. +// SlaveBegin(): called after Begin(), when on PROOF called only on the +// slave servers. +// Process(): called for each event, in this function you decide what +// to read and fill your histograms. +// SlaveTerminate: called at the end of the loop on the tree, when on PROOF +// called only on the slave servers. +// Terminate(): called at the end of the loop on the tree, +// a convenient place to draw/fit your histograms. +// +// To use this file, try the following session on your Tree T: +// +// Root > T->Process("MySelector.C") +// Root > T->Process("MySelector.C","some options") +// Root > T->Process("MySelector.C+") +// + +#include "MySelector.h" +#include +#include + + +void MySelector::Begin(TTree * /*tree*/) +{ + // The Begin() function is called at the start of the query. + // When running with PROOF Begin() is only called on the client. + // The tree argument is deprecated (on PROOF 0 is passed). + + TString option = GetOption(); + +} + +void MySelector::SlaveBegin(TTree * /*tree*/) +{ + // The SlaveBegin() function is called after the Begin() function. + // When running with PROOF SlaveBegin() is called on each slave server. + // The tree argument is deprecated (on PROOF 0 is passed). + + TString option = GetOption(); + +} + +Bool_t MySelector::Process(Long64_t entry) +{ + // The Process() function is called for each entry in the tree (or possibly + // keyed object in the case of PROOF) to be processed. The entry argument + // specifies which entry in the currently loaded tree is to be processed. + // It can be passed to either MySelector::GetEntry() or TBranch::GetEntry() + // to read either all or the required parts of the data. When processing + // keyed objects with PROOF, the object is already loaded and is available + // via the fObject pointer. + // + // This function should contain the "body" of the analysis. It can contain + // simple or elaborate selection criteria, run algorithms on the data + // of the event and typically fill histograms. + // + // The processing can be stopped by calling Abort(). + // + // Use fStatus to set the return value of TTree::Process(). + // + // The return value is currently not used. + + + return kTRUE; +} + +void MySelector::SlaveTerminate() +{ + // The SlaveTerminate() function is called after all entries or objects + // have been processed. When running with PROOF SlaveTerminate() is called + // on each slave server. + +} + +void MySelector::Terminate() +{ + // The Terminate() function is the last function to be called during + // a query. It always runs on the client, it can be used to present + // the results graphically or save the results to file. + +} diff --git a/docbook/primer/macros/RunMySelector.C b/docbook/primer/macros/RunMySelector.C new file mode 100644 index 0000000000000..f504d0ddbc4fa --- /dev/null +++ b/docbook/primer/macros/RunMySelector.C @@ -0,0 +1,7 @@ +{// set up a TChain +TChain *ch=new TChain("cond_data", "My Chain for Example N-Tuple"); + ch->Add("conductivity_experiment*.root"); +// eventually, start Proof Lite on cores +TProof::Open("workers=4"); +ch->SetProof(); +ch->Process("MySelector.C+");} diff --git a/docbook/primer/macros/macro1.C b/docbook/primer/macros/macro1.C new file mode 100644 index 0000000000000..08792ab2a4d91 --- /dev/null +++ b/docbook/primer/macros/macro1.C @@ -0,0 +1,70 @@ +// Builds a graph with errors, displays it and saves it as +// image. First, include some header files (within CINT, +// these will be ignored). + +#include "TCanvas.h" +#include "TROOT.h" +#include "TGraphErrors.h" +#include "TF1.h" +#include "TLegend.h" +#include "TArrow.h" +#include "TLatex.h" + +void macro1(){ + // The values and the errors on the Y axis + const int n_points=10; + double x_vals[n_points]= + {1,2,3,4,5,6,7,8,9,10}; + double y_vals[n_points]= + {6,12,14,20,22,24,35,45,44,53}; + double y_errs[n_points]= + {5,5,4.7,4.5,4.2,5.1,2.9,4.1,4.8,5.43}; + + // Instance of the graph + TGraphErrors graph(n_points,x_vals,y_vals,NULL,y_errs); + graph.SetTitle("Measurement XYZ;lenght [cm];Arb.Units"); + + // Make the plot estetically better + graph.SetMarkerStyle(kOpenCircle); + graph.SetMarkerColor(kBlue); + graph.SetLineColor(kBlue); + + // The canvas on which we'll draw the graph + TCanvas* mycanvas = new TCanvas(); + + // Draw the graph ! + graph.DrawClone("APE"); + + // Define a linear function + TF1 f("Linear law","[0]+x*[1]",.5,10.5); + // Let's make the funcion line nicer + f.SetLineColor(kRed); f.SetLineStyle(2); + // Fit it to the graph and draw it + graph.Fit(&f); + f.DrawClone("Same"); + + // Build and Draw a legend + TLegend leg(.1,.7,.3,.9,"Lab. Lesson 1"); + leg.SetFillColor(0); + graph.SetFillColor(0); + leg.AddEntry(&graph,"Exp. Points"); + leg.AddEntry(&f,"Th. Law"); + leg.DrawClone("Same"); + + // Draw an arrow on the canvas + TArrow arrow(8,8,6.2,23,0.02,"|>"); + arrow.SetLineWidth(2); + arrow.DrawClone(); + + // Add some text to the plot + TLatex text(8.2,7.5,"#splitline{Maximum}{Deviation}"); + text.DrawClone(); + + mycanvas->Print("graph_with_law.pdf"); +} + +#ifndef __CINT__ +int main(){ + macro1(); + } +#endif diff --git a/docbook/primer/macros/macro2.C b/docbook/primer/macros/macro2.C new file mode 100644 index 0000000000000..677d918b2d5dc --- /dev/null +++ b/docbook/primer/macros/macro2.C @@ -0,0 +1,29 @@ +// Reads the points from a file and produces a simple graph. +int macro2(){ + + TCanvas* c=new TCanvas(); + c->SetGrid(); + + TGraphErrors graph_expected("./macro2_input_expected.txt", + "%lg %lg %lg"); + graph_expected.SetTitle( + "Measurement XYZ and Expectation; + lenght [cm]; + Arb.Units"); + graph_expected.SetFillColor(kYellow); + graph_expected.DrawClone("E3AL"); // E3 draws the band + + TGraphErrors graph("./macro2_input.txt","%lg %lg %lg"); + graph.SetMarkerStyle(kCircle); + graph.SetFillColor(0); + graph.DrawClone("PESame"); + + // Draw the Legend + TLegend leg(.1,.7,.3,.9,"Lab. Lesson 2"); + leg.SetFillColor(0); + leg.AddEntry(&graph_expected,"Expected Points"); + leg.AddEntry(&graph,"Measured Points"); + leg.DrawClone("Same"); + + graph.Print(); +} diff --git a/docbook/primer/macros/macro2_input.txt b/docbook/primer/macros/macro2_input.txt new file mode 100644 index 0000000000000..f9eec8736f9a6 --- /dev/null +++ b/docbook/primer/macros/macro2_input.txt @@ -0,0 +1,13 @@ +# Measurement of Friday 26 March +# Experiment 2 Physics Lab + +1 6 5 +2 12 5 +3 14 4.7 +4 20 4.5 +5 22 4.2 +6 24 5.1 +7 35 2.9 +8 45 4.1 +9 44 4.8 +10 53 5.43 \ No newline at end of file diff --git a/docbook/primer/macros/macro2_input_expected.txt b/docbook/primer/macros/macro2_input_expected.txt new file mode 100644 index 0000000000000..a5929099432ae --- /dev/null +++ b/docbook/primer/macros/macro2_input_expected.txt @@ -0,0 +1,14 @@ +# Measurement of Friday 26 March +# Experiment 2 Physics Lab +# Expected points from theory predictions + +1 6 0.5 +2 12 1. +3 18 1.5 +4 24 2.0 +5 30 3.7 +6 36 4.9 +7 42 5.4 +8 48 6.8 +9 54 7.5 +10 60 9.7 \ No newline at end of file diff --git a/docbook/primer/macros/macro3.C b/docbook/primer/macros/macro3.C new file mode 100644 index 0000000000000..c9d20bfeccb80 --- /dev/null +++ b/docbook/primer/macros/macro3.C @@ -0,0 +1,19 @@ +// Builds a polar graph in a square Canvas. + +void macro3(){ + TCanvas* c = new TCanvas("myCanvas","myCanvas",600,600); + double rmin=0; + double rmax=TMath::Pi()*6; + const int npoints=1000; + Double_t r[npoints]; + Double_t theta[npoints]; + for (Int_t ipt = 0; ipt < npoints; ipt++) { + r[ipt] = ipt*(rmax-rmin)/npoints+rmin; + theta[ipt] = TMath::Sin(r[ipt]); + } + TGraphPolar grP1 (npoints,r,theta); + grP1.SetTitle("A Fan"); + grP1.SetLineWidth(3); + grP1.SetLineColor(2); + grP1.DrawClone("AOL"); +} diff --git a/docbook/primer/macros/macro4.C b/docbook/primer/macros/macro4.C new file mode 100644 index 0000000000000..2ab821eae8cc6 --- /dev/null +++ b/docbook/primer/macros/macro4.C @@ -0,0 +1,42 @@ +// Create, Draw and fit a TGraph2DErrors +void macro4(){ + gStyle->SetPalette(1); + const double e = 0.3; + const int nd = 500; + + TRandom3 my_random_generator; + TF2 *f2 = new TF2("f2", + "1000*(([0]*sin(x)/x)*([1]*sin(y)/y))+200", + -6,6,-6,6); + f2->SetParameters(1,1); + TGraph2DErrors *dte = new TGraph2DErrors(nd); + // Fill the 2D graph + double rnd, x, y, z, ex, ey, ez; + for (Int_t i=0; iGetRandom2(x,y); + // A random number in [-e,e] + rnd = my_random_generator.Uniform(-e,e); + z = f2->Eval(x,y)*(1+rnd); + dte->SetPoint(i,x,y,z); + ex = 0.05*my_random_generator.Uniform(); + ey = 0.05*my_random_generator.Uniform(); + ez = TMath::Abs(z*rnd); + dte->SetPointError(i,ex,ey,ez); + } + // Fit function to generated data + f2->SetParameters(0.7,1.5); // set initial values for fit + f2->SetTitle("Fitted 2D function"); + dte->Fit(f2); + // Plot the result + TCanvas *c1 = new TCanvas(); + f2->Draw("Surf1"); + dte->Draw("P0 Same"); + // Make the x and y projections + TCanvas* c_p= new TCanvas("ProjCan", + "The Projections",1000,400); + c_p->Divide(2,1); + c_p->cd(1); + dte->Project("x")->Draw(); + c_p->cd(2); + dte->Project("y")->Draw(); +} diff --git a/docbook/primer/macros/macro5.C b/docbook/primer/macros/macro5.C new file mode 100644 index 0000000000000..a4c4503407cb7 --- /dev/null +++ b/docbook/primer/macros/macro5.C @@ -0,0 +1,31 @@ +// Create, Fill and draw an Histogram which reproduces the +// counts of a scaler linked to a Geiger counter. + +void macro5(){ + TH1F* cnt_r_h=new TH1F("count_rate", + "Count Rate;N_{Counts};# occurencies", + 100, // Number of Bins + -0.5, // Lower X Boundary + 15.5); // Upper X Boundary + + const float mean_count=3.6; + TRandom3 rndgen; + // simulate the measurements + for (int imeas=0;imeas<400;imeas++) + cnt_r_h->Fill(rndgen.Poisson(mean_count)); + + TCanvas* c= new TCanvas(); + cnt_r_h->Draw(); + + TCanvas* c_norm= new TCanvas(); + cnt_r_h->DrawNormalized(); + + // Print summary + cout << "Moments of Distribution:\n" + << " - Mean = " << cnt_r_h->GetMean() << " +- " + << cnt_r_h->GetMeanError() << "\n" + << " - RMS = " << cnt_r_h->GetRMS() << " +- " + << cnt_r_h->GetRMSError() << "\n" + << " - Skewness = " << cnt_r_h->GetSkewness() << "\n" + << " - Kurtosis = " << cnt_r_h->GetKurtosis() << "\n"; +} diff --git a/docbook/primer/macros/macro6.C b/docbook/primer/macros/macro6.C new file mode 100644 index 0000000000000..0923a99695c3a --- /dev/null +++ b/docbook/primer/macros/macro6.C @@ -0,0 +1,63 @@ +// Divide and add 1D Histograms + +void format_h(TH1F* h, int linecolor){ + h->SetLineWidth(3); + h->SetLineColor(linecolor); + } + +void macro6(){ + + TH1F* sig_h=new TH1F("sig_h","Signal Histo",50,0,10); + TH1F* gaus_h1=new TH1F("gaus_h1","Gauss Histo 1",30,0,10); + TH1F* gaus_h2=new TH1F("gaus_h2","Gauss Histo 2",30,0,10); + TH1F* bkg_h=new TH1F("exp_h","Exponential Histo",50,0,10); + + // simulate the measurements + TRandom3 rndgen; + for (int imeas=0;imeas<4000;imeas++){ + exp_h->Fill(rndgen.Exp(4)); + if (imeas%4==0) gaus_h1->Fill(rndgen.Gaus(5,2)); + if (imeas%4==0) gaus_h2->Fill(rndgen.Gaus(5,2)); + if (imeas%10==0)sig_h->Fill(rndgen.Gaus(5,.5));} + + // Format Histograms + TH1F* histos[4]={sig_h,bkg_h,gaus_h1,gaus_h2}; + for (int i=0;i<4;++i){ + histos[i]->Sumw2(); // *Very* Important + format_h(histos[i],i+1); + } + + // Sum + TH1F* sum_h= new TH1F(*bkg_h); + sum_h->Add(sig_h,1.); + sum_h->SetTitle("Exponential + Gaussian"); + format_h(sum_h,kBlue); + + TCanvas* c_sum= new TCanvas(); + sum_h->Draw("hist"); + bkg_h->Draw("SameHist"); + sig_h->Draw("SameHist"); + + // Divide + TH1F* dividend=new TH1F(*gaus_h1); + dividend->Divide(gaus_h2); + + // Graphical Maquillage + dividend->SetTitle(";X axis;Gaus Histo 1 / Gaus Histo 2"); + format_h(dividend,kOrange); + gaus_h1->SetTitle(";;Gaus Histo 1 and Gaus Histo 2"); + gStyle->SetOptStat(0); + + TCanvas* c_divide= new TCanvas(); + c_divide->Divide(1,2,0,0); + c_divide->cd(1); + c_divide->GetPad(1)->SetRightMargin(.01); + gaus_h1->DrawNormalized("Hist"); + gaus_h2->DrawNormalized("HistSame"); + + c_divide->cd(2); + dividend->GetYaxis()->SetRangeUser(0,2.49); + c_divide->GetPad(2)->SetGridy(); + c_divide->GetPad(2)->SetRightMargin(.01); + dividend->Draw(); +} diff --git a/docbook/primer/macros/macro7.C b/docbook/primer/macros/macro7.C new file mode 100644 index 0000000000000..bc43df2e10b6d --- /dev/null +++ b/docbook/primer/macros/macro7.C @@ -0,0 +1,31 @@ +// Draw a Bidimensional Histogram in many ways +// together with its profiles and projections + +void macro7(){ + gStyle->SetPalette(53); + gStyle->SetOptStat(0); + gStyle->SetOptTitle(0); + + TH2F bidi_h("bidi_h","2D Histo;Guassian Vals;Exp. Vals", + 30,-5,5, // X axis + 30,0,10); // Y axis + + TRandom3 rgen; + for (int i=0;i<500000;i++) + bidi_h.Fill(rgen.Gaus(0,2),10-rgen.Exp(4),.1); + + TCanvas* c=new TCanvas("Canvas","Canvas",800,800); + c->Divide(2,2); + c->cd(1);bidi_h.DrawClone("Cont1"); + c->cd(2);bidi_h.DrawClone("Colz"); + c->cd(3);bidi_h.DrawClone("lego2"); + c->cd(4);bidi_h.DrawClone("surf3"); + + // Profiles and Projections + TCanvas* c2=new TCanvas("Canvas2","Canvas2",800,800); + c2->Divide(2,2); + c2->cd(1);bidi_h.ProjectionX()->DrawClone(); + c2->cd(2);bidi_h.ProjectionY()->DrawClone(); + c2->cd(3);bidi_h.ProfileX()->DrawClone(); + c2->cd(4);bidi_h.ProfileY()->DrawClone(); +} diff --git a/docbook/primer/macros/macro8.C b/docbook/primer/macros/macro8.C new file mode 100644 index 0000000000000..06d113f51c207 --- /dev/null +++ b/docbook/primer/macros/macro8.C @@ -0,0 +1,64 @@ +void format_line(TAttLine* line,int col,int sty){ + line->SetLineWidth(5); line->SetLineColor(col); + line->SetLineStyle(sty);} + +double the_gausppar(double* vars, double* pars){ + return pars[0]*TMath::Gaus(vars[0],pars[1],pars[2])+ + pars[3]+pars[4]*vars[0]+pars[5]*vars[0]*vars[0];} + +int macro8(){ + gStyle->SetOptTitle(0); gStyle->SetOptStat(0); + gStyle->SetOptFit(1111); gStyle->SetStatBorderSize(0); + gStyle->SetStatX(.89); gStyle->SetStatY(.89); + + TF1 parabola("parabola","[0]+[1]*x+[2]*x**2",0,20); + format_line(¶bola,kBlue,2); + + TF1 gaussian("gaussian","[0]*TMath::Gaus(x,[1],[2])",0,20); + format_line(&gaussian,kRed,2); + + TF1 gausppar("gausppar",the_gausppar,-0,20,6); + double a=15; double b=-1.2; double c=.03; + double norm=4; double mean=7; double sigma=1; + gausppar.SetParameters(norm,mean,sigma,a,b,c); + gausppar.SetParNames("Norm","Mean","Sigma","a","b","c"); + format_line(&gausppar,kBlue,1); + + TH1F histo("histo","Signal plus background;X vals;Y Vals", + 50,0,20); + histo.SetMarkerStyle(8); + + // Fake the data + for (int i=1;i<=5000;++i) histo.Fill(gausppar.GetRandom()); + + // Reset the parameters before the fit and set + // by eye a peak at 6 with an area of more or less 50 + gausppar.SetParameter(0,50); + gausppar.SetParameter(1,6); + int npar=gausppar.GetNpar(); + for (int ipar=2;iparPrint(); // print fit results + // get covariance Matrix an print it + TMatrixDSym covMatrix (frp->GetCovarianceMatrix()); + covMatrix.Print(); + + // Set the values of the gaussian and parabola + for (int ipar=0;ipar<3;ipar++){ + gaussian.SetParameter(ipar, + gausppar.GetParameter(ipar)); + parabola.SetParameter(ipar, + gausppar.GetParameter(ipar+3));} + + histo.GetYaxis()->SetRangeUser(0,250); + histo.DrawClone("PE"); + parabola.DrawClone("Same"); gaussian.DrawClone("Same"); + TLatex latex(2,220, + "#splitline{Signal Peak over}{background}"); + latex.DrawClone("Same"); +} diff --git a/docbook/primer/macros/macro9.C b/docbook/primer/macros/macro9.C new file mode 100644 index 0000000000000..444a7c64aa76a --- /dev/null +++ b/docbook/primer/macros/macro9.C @@ -0,0 +1,76 @@ +// Toy Monte Carlo example. +// Check pull distribution to compare chi2 and binned +// log-likelihood methods. + +pull( int n_toys = 10000, + int n_tot_entries = 100, + int nbins = 40, + bool do_chi2=true ){ + + TString method_prefix("Log-Likelihood "); + if (do_chi2) + method_prefix="#chi^{2} "; + + // Create histo + TH1F* h4 = new TH1F(method_prefix+"h4", + method_prefix+" Random Gauss", + nbins,-4,4); + h4->SetMarkerStyle(21); + h4->SetMarkerSize(0.8); + h4->SetMarkerColor(kRed); + + // Histogram for sigma and pull + TH1F* sigma = new TH1F(method_prefix+"sigma", + method_prefix+"sigma from gaus fit", + 50,0.5,1.5); + TH1F* pull = new TH1F(method_prefix+"pull", + method_prefix+"pull from gaus fit", + 50,-4.,4.); + + // Make nice canvases + TCanvas* c0 = new TCanvas(method_prefix+"Gauss", + method_prefix+"Gauss",0,0,320,240); + c0->SetGrid(); + + // Make nice canvases + TCanvas* c1 = new TCanvas(method_prefix+"Result", + method_prefix+"Sigma-Distribution", + 0,300,600,400); + c0->cd(); + + float sig, mean; + for (int i=0; iReset(); + // Fill histo + for ( int j = 0; jFill(gRandom->Gaus()); + // perform fit + if (do_chi2) h4->Fit("gaus","q"); // Chi2 fit + else h4->Fit("gaus","lq"); // Likelihood fit + // some control output on the way + if (!(i%100)){ + h4->Draw("ep"); + c0->Update();} + + // Get sigma from fit + TF1 *fit = h4->GetFunction("gaus"); + sig = fit->GetParameter(2); + mean= fit->GetParameter(1); + sigma->Fill(sig); + pull->Fill(mean/sig * sqrt(n_tot_entries)); + } // end of toy MC loop + // print result + c1->cd(); + pull->Draw(); +} + +void macro9(){ + int n_toys=10000; + int n_tot_entries=100; + int n_bins=40; + cout << "Performing Pull Experiment with chi2 \n"; + pull(n_toys,n_tot_entries,n_bins,true); + cout << "Performing Pull Experiment with Log Likelihood\n"; + pull(n_toys,n_tot_entries,n_bins,false); + } diff --git a/docbook/primer/macros/makeMySelector.C b/docbook/primer/macros/makeMySelector.C new file mode 100644 index 0000000000000..ede1774a6ac35 --- /dev/null +++ b/docbook/primer/macros/makeMySelector.C @@ -0,0 +1,11 @@ +{ +// create template class for Selector to run on a tree +////////////////////////////////////////////////////// +// +// open root file containing the Tree + TFile *f = TFile::Open("conductivity_experiment.root"); +// create TTree object from it + TTree *t = (TTree *) f->Get("cond_data"); +// this generates the files MySelector.h and MySelector.C + t->MakeSelector("MySelector"); + } diff --git a/docbook/primer/macros/read_from_file.C b/docbook/primer/macros/read_from_file.C new file mode 100644 index 0000000000000..ffde837ffedf6 --- /dev/null +++ b/docbook/primer/macros/read_from_file.C @@ -0,0 +1,12 @@ +void read_from_file(){ + + // Let's open the TFile + TFile* in_file= new TFile("my_rootfile.root"); + + // Get the Histogram out + TH1F* h = (TH1F*) in_file.GetObjectChecked("my_histogram", + "TH1F"); + + // Draw it + h->Draw(); +} diff --git a/docbook/primer/macros/read_ntuple_from_file.C b/docbook/primer/macros/read_ntuple_from_file.C new file mode 100644 index 0000000000000..2eb39c86bdfaa --- /dev/null +++ b/docbook/primer/macros/read_ntuple_from_file.C @@ -0,0 +1,25 @@ +// Read the previously produced N-Tuple and print on screen +// its content + +void read_ntuple_from_file(){ + + // Open a file, save the ntuple and close the file + TFile in_file("conductivity_experiment.root"); + TNtuple* my_tuple = (TNtuple*) in_file.GetObjectChecked( + "cond_data", + "TNtuple"); + float pot,cur,temp,pres; float* row_content; + + cout << "Potential\tCurrent\tTemperature\tPressure\n"; + for (int irow=0;irowGetEntries();++irow){ + my_tuple->GetEntry(irow); + row_content = my_tuple->GetArgs(); + pot = row_content[0]; + cur = row_content[1]; + temp = row_content[2]; + pres = row_content[3]; + cout << pot << "\t" << cur << "\t" << temp + << "\t" << pres << endl; + } + + } diff --git a/docbook/primer/macros/read_ntuple_with_chain.C b/docbook/primer/macros/read_ntuple_with_chain.C new file mode 100644 index 0000000000000..85ce30015a17c --- /dev/null +++ b/docbook/primer/macros/read_ntuple_with_chain.C @@ -0,0 +1,32 @@ +// Read several previously produced N-Tuples and print on screen its +// content. +// +// you can easily create some files with the following statement: +// +// for i in 0 1 2 3 4 5; \\ +// do root -l -x -b -q \\ +// "write_ntuple_to_file.cxx \\ +// (\"conductivity_experiment_${i}.root\", 100)"; \\ +// done + +void read_ntuple_with_chain(){ + // initiate a TChain with the name of the TTree to be processed + TChain in_chain("cond_data"); + in_chain.Add("conductivity_experiment*.root"); // add files, + // wildcards work + + // define variables and assign them to the corresponding branches + float pot, cur, temp, pres; + my_tuple->SetBranchAddress("Potential", &pot); + my_tuple->SetBranchAddress("Current", &cur); + my_tuple->SetBranchAddress("Temperature", &temp); + my_tuple->SetBranchAddress("Pressure", &pres); + + cout << "Potential\tCurrent\tTemperature\tPressure\n"; + for (size_t irow=0; irowSetCanvasBorderMode(0); + myStyle->SetPadBorderMode(0); + myStyle->SetPadColor(0); + myStyle->SetCanvasColor(0); + myStyle->SetTitleColor(1); + myStyle->SetStatColor(0); + + myStyle->SetLabelSize(0.03,"xyz"); // size of axis values + + // default canvas positioning + myStyle->SetCanvasDefX(900); + myStyle->SetCanvasDefY(20); + myStyle->SetCanvasDefH(550); + myStyle->SetCanvasDefW(540); + + myStyle->SetPadBottomMargin(0.1); + myStyle->SetPadTopMargin(0.1); + myStyle->SetPadLeftMargin(0.1); + myStyle->SetPadRightMargin(0.1); + myStyle->SetPadTickX(1); + myStyle->SetPadTickY(1); + myStyle->SetFrameBorderMode(0); + + // Din letter + myStyle->SetPaperSize(21, 28); + + + myStyle->SetOptStat(111111);// Show overflow and underflow as well + myStyle->SetOptFit(1011); + myStyle->SetPalette(1); + + // apply the new style + gROOT->SetStyle("MyStyle"); //uncomment to set this style + gROOT->ForceStyle(); // use this style, not the one saved in root files + + printf("\n Beginning new ROOT session with private TStyle \n"); + +} diff --git a/docbook/primer/macros/slits.C b/docbook/primer/macros/slits.C new file mode 100644 index 0000000000000..f3715f6028f28 --- /dev/null +++ b/docbook/primer/macros/slits.C @@ -0,0 +1,42 @@ +// Example drawing the interference pattern of light +// falling on a grid with n slits and ratio r of slit +// width over distance between slits. + +// function code in C +double single(double *x, double *par) { + double const pi=4*atan(1.); + return pow(sin(pi*par[0]*x[0])/(pi*par[0]*x[0]),2); +} + +double nslit0(double *x,double *par){ + double const pi=4*atan(1.); + return pow(sin(pi*par[1]*x[0])/sin(pi*x[0]),2); +} + +double nslit(double *x, double *par){ + return single(x,par) * nslit0(x,par); +} + +// This is the main program +void slits() { + float r,ns; + + // request user input + cout << "slit width / g ? "; + scanf("%f",&r); + cout << "# of slits? "; + scanf("%f",&ns); + cout <<"interference pattern for "<< ns + <<" slits, width/distance: "<SetNpx(500); + + // set parameters, as read in above + Fnslit->SetParameter(0,r); + Fnslit->SetParameter(1,ns); + + // draw the interference pattern for a grid with n slits + Fnslit->Draw(); +} diff --git a/docbook/primer/macros/write_ntuple_to_file.C b/docbook/primer/macros/write_ntuple_to_file.C new file mode 100644 index 0000000000000..ee25bb7ef56e5 --- /dev/null +++ b/docbook/primer/macros/write_ntuple_to_file.C @@ -0,0 +1,32 @@ +// Fill an n-tuple and write it to a file simulating measurement of +// conductivity of a material in different conditions of pressure +// and temperature. + +void write_ntuple_to_file(){ + + // Initialise the TNtuple + TNtuple cond_data("cond_data", + "Example N-Tuple", + "Potential:Current:Temperature:Pressure"); + + // Fill it randomly to fake the acquired data + float pot,cur,temp,pres; + for (int i=0;i<10000;++i){ + pot=gRandom->Uniform(0.,10.); // get voltage + temp=gRandom->Uniform(250.,350.); // get temperature + pres=gRandom->Uniform(0.5,1.5); // get pressure + cur=pot/(10.+0.05*(temp-300.)-0.2*(pres-1.)); // current +// add some random smearing (measurement errors) + pot*=gRandom->Gaus(1.,0.01); // 1% error on voltage + temp+=gRandom->Gaus(0.,0.3); // 0.3 abs. error on temp. + pres*=gRandom->Gaus(1.,0.02);// 1% error on pressure + cur*=gRandom->Gaus(1.,0.01); // 1% error on current +// write to ntuple + cond_data.Fill(pot,cur,temp,pres); + } + + // Open a file, save the ntuple and close the file + TFile ofile("conductivity_experiment.root","RECREATE"); + cond_data.Write(); + ofile.Close(); +} diff --git a/docbook/primer/macros/write_ntuple_to_file_advanced.C b/docbook/primer/macros/write_ntuple_to_file_advanced.C new file mode 100644 index 0000000000000..e633aed740d8f --- /dev/null +++ b/docbook/primer/macros/write_ntuple_to_file_advanced.C @@ -0,0 +1,32 @@ +// Fill an n-tuple and write it to a file simulating measurement of +// conductivity of a material in different conditions of pressure +// and temperature using branches. + +void write_ntuple_to_file_advanced( + const std::string& outputFileName="conductivity_experiment.root" + ,unsigned int numDataPoints=1000000){ + // Initialise the TNtuple + TTree cond_data("cond_data", "Example N-Tuple"); + + // define the variables and book them for the ntuple + float pot,cur,temp,pres; + cond_data.Branch("Potential", &pot, "Potential/F"); + cond_data.Branch("Current", &cur, "Current/F"); + cond_data.Branch("Temperature", &temp, "Temperature/F"); + cond_data.Branch("Pressure", &pres, "Pressure/F"); + + for (int i=0;iUniform(0.,10.)*gRandom->Gaus(1.,0.01); + temp=gRandom->Uniform(250.,350.)+gRandom->Gaus(0.,0.3); + pres=gRandom->Uniform(0.5,1.5)*gRandom->Gaus(1.,0.02); + cur=pot/(10.+0.05*(temp-300.)-0.2*(pres-1.))* + gRandom->Gaus(1.,0.01); + // write to ntuple + cond_data.Fill();} + + // Open a file, save the ntuple and close the file + TFile ofile(outputFileName.c_str(),"RECREATE"); + cond_data.Write(); + ofile.Close(); +} diff --git a/docbook/primer/macros/write_to_file.C b/docbook/primer/macros/write_to_file.C new file mode 100644 index 0000000000000..2cf3624a22fe0 --- /dev/null +++ b/docbook/primer/macros/write_to_file.C @@ -0,0 +1,17 @@ +void write_to_file(){ + + // Instance of our histogram + TH1F h("my_histogram","My Title;X;# of entries",100,-5,5); + + // Let's fill it randomly + h.FillRandom("gaus"); + + // Let's open a TFile + TFile out_file("my_rootfile.root","RECREATE"); + + // Write the histogram in the file + h.Write(); + + // Close the file + out_file.Close(); +} diff --git a/docbook/primer/primer.xpr b/docbook/primer/primer.xpr new file mode 100644 index 0000000000000..f552b423b1860 --- /dev/null +++ b/docbook/primer/primer.xpr @@ -0,0 +1,1095 @@ + + + + + + + + + scenario.associations + + + + graphs.xml + + + + ROOT Docbook PDF + + + + + XSL + + + + + + your_first_ROOT_macro.xml + + + + ROOT Docbook PDF + + + + + XSL + + + + + + ROOT_as_calculator.xml + + + + ROOT Docbook PDF + + + + + XSL + + + + + + Introduction.xml + + + + ROOT Docbook PDF + + + + + XSL + + + + + + concludingRemarks.xml + + + + ROOT Docbook PDF + + + + + XSL + + + + + + bibliography.xml + + + + ROOT Docbook PDF + + + + + XSL + + + + + + ROOTPrimer.xml + + + + ROOT Docbook PDF + + + + + XSL + + + + + + filio.xml + + + + ROOT Docbook PDF + + + + + XSL + + + + + + functions_and_parameter_estimation.xml + + + + ROOT Docbook PDF + + + + + XSL + + + + + + histograms.xml + + + + ROOT Docbook PDF + + + + + XSL + + + + + + ../../root-v5-34-00-patches/docbook/primer/ROOTPrimer.xml + + + + ROOT Docbook HTML + ROOT Docbook HTML - Chunk + ROOT Docbook PDF + + + + + XSL + XSL + XSL + + + + + + + scenarios + + + + + + + ROOT Docbook HTML + + + + + + + + + pdf + + + Apache FOP + + + + + + ${frameworks}/docbook/xsl/html/docbook_custom.xsl + + + ${currentFileURL} + + + false + + + false + + + XSL + + + true + + + true + + + ${cfd}/${cfn}.html + + + false + + + + + + false + + + false + + + false + + + false + + + false + + + true + + + + + + + + admon.graphics + + + + + + + + + + + 1 + + + false + + + + + + + admon.graphics.path + + + + + + + + + + + ${frameworks}/docbook/xsl/images/ + + + false + + + + + + + draft.mode + + + + + + + + + + + no + + + false + + + + + + + highlight.source + + + + + + + + + + + 1 + + + false + + + + + + + highlight.xslthl.config + + + + + + + + + + + ${frameworks}/docbook/xsl/highlighting/xslthl-config.xml + + + false + + + + + + + linenumbering.everyNth + + + + + + + + + + + 1 + + + false + + + + + + + linenumbering.extension + + + + + + + + + + + 1 + + + false + + + + + + + shade.verbatim + + + + + + + + + + + 1 + + + false + + + + + + + use.extensions + + + + + + + + + + + 1 + + + false + + + + + + + + + Saxon6.5.5 + + + + ${frameworks}/docbook/xsl/extensions/xslthl-2.0.1.jar + ${frameworks}/docbook/xsl/extensions/saxon65.jar + + + + + + + + + ROOT Docbook HTML - Chunk + + + + + + + + + pdf + + + Apache FOP + + + + + + ${frameworks}/docbook/xsl/html/chunk_custom.xsl + + + ${currentFileURL} + + + false + + + false + + + XSL + + + true + + + true + + + + + + true + + + ${cfdu}/chunks/index.html + + + false + + + false + + + false + + + false + + + false + + + true + + + + + + + + admon.graphics + + + + + + + + + + + 1 + + + false + + + + + + + admon.graphics.path + + + + + + + + + + + ${frameworks}/docbook/xsl/images/ + + + false + + + + + + + base.dir + + + + + + + + + + + ${cfd}/chunks/ + + + false + + + + + + + draft.mode + + + + + + + + + + + no + + + false + + + + + + + highlight.source + + + + + + + + + + + 1 + + + false + + + + + + + highlight.xslthl.config + + + + + + + + + + + ${frameworks}/docbook/xsl/highlighting/xslthl-config.xml + + + false + + + + + + + img.src.path + + + + + + + + + + + ../ + + + false + + + + + + + shade.verbatim + + + + + + + + + + + 1 + + + false + + + + + + + + + Saxon6.5.5 + + + + ${frameworks}/docbook/xsl/extensions/xslthl-2.0.1.jar + ${frameworks}/docbook/xsl/extensions/saxon65.jar + + + + + + + + + ROOT Docbook PDF + + + + + + + + + pdf + + + Apache FOP + + + + + + ${frameworks}/docbook/xsl/fo/docbook_custom.xsl + + + ${currentFileURL} + + + false + + + true + + + XSL + + + true + + + true + + + ${cfd}/${cfn}.pdf + + + false + + + + + + false + + + false + + + false + + + false + + + false + + + true + + + + + + + + admon.graphics + + + + + + + + + + + 1 + + + false + + + + + + + admon.graphics.path + + + + + + + + + + + ${frameworks}/docbook/xsl/images/ + + + false + + + + + + + draft.mode + + + + + + + + + + + no + + + false + + + + + + + fop.extensions + + + + + + + + + + + 0 + + + false + + + + + + + fop1.extensions + + + + + + + + + + + 1 + + + false + + + + + + + highlight.source + + + + + + + + + + + 1 + + + false + + + + + + + highlight.xslthl.config + + + + + + + + + + + ${frameworks}/docbook/xsl/highlighting/xslthl-config.xml + + + false + + + + + + + linenumbering.everyNth + + + + + + + + + + + 1 + + + false + + + + + + + linenumbering.extension + + + + + + + + + + + 1 + + + false + + + + + + + monospace.verbatim.font.width + + + + + + + + + + + 0.60em + + + false + + + + + + + paper.type + + + + + + + + + + + A4 + + + false + + + + + + + shade.verbatim + + + + + + + + + + + 1 + + + false + + + + + + + use.extensions + + + + + + + + + + + 1 + + + false + + + + + + + + + Saxon6.5.5 + + + + ${frameworks}/docbook/xsl/extensions/xslthl-2.0.1.jar + ${frameworks}/docbook/xsl/extensions/saxon65.jar + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/docbook/primer/titlepage.xml b/docbook/primer/titlepage.xml new file mode 100644 index 0000000000000..a97a68ae424ff --- /dev/null +++ b/docbook/primer/titlepage.xml @@ -0,0 +1,23 @@ + + + A Root Guide For Beginners +"Diving Into ROOT" + + +Abstact: + + + ROOT is a software framework for data analysis, a powerful tool to cope + with the demanding tasks typical of state of the art scientific data + analysis. + Among its prominent features are an advanced graphical user interface, + ideal for interactive analysis, an interpreter for the C++ programming + language, for rapid and efficient prototyping and a persistency mechanism + for C++ objects, used also to write every year petabytes of data recorded + by the Large Hadron Collider experiments. + This introductory guide illustrates the main features of ROOT, relevant for + the typical problems of data analysis: input and plotting of data from + measurements and fitting of analytical functions. + + + diff --git a/docbook/primer/your_first_ROOT_macro.xml b/docbook/primer/your_first_ROOT_macro.xml new file mode 100644 index 0000000000000..a3cc0c605b8f3 --- /dev/null +++ b/docbook/primer/your_first_ROOT_macro.xml @@ -0,0 +1,345 @@ + + + + ROOT Macros + + +You know how other books go on and on about programming +fundamentals and finally work up to building a complete, working program? +Let's skip all that. In this guide, we will describe macros executed +by the ROOT C++ interpreter CINT. + + +It is relatively easy to +compile a macro, either as a pre-compiled library to load into ROOT, +or as a stand-alone application, by adding some include statements +for header file or some "dressing code" to any macro. + + +
+General Remarks on ROOT macros + +If you have a number of lines which you were able to execute at the +ROOT prompt, they can be turned into a ROOT macro by giving them a +name which corresponds to the file name without extension. The general +structure for a macro stored in file MacroName.C is + +void MacroName() { + < ... + your lines of C++ code + ... > +} + +The macro is executed by typing + + > root MacroName.C + +at the system prompt, or it can be loaded into a ROOT session +and then be executed by typing + +root [0].L MacroName.C +root [1] MacroName(); + +at the ROOT prompt. +Note that more than one macro can be loaded this way, as +each macro has a unique name in the ROOT name space. +A small set of options can help making your plot nicer. + +gROOT->SetStyle("Plain"); // set plain TStyle +gStyle->SetOptStat(111111); // draw statistics on plots, + // (0) for no output +gStyle->SetOptFit(1111); // draw fit results on plot, + // (0) for no ouput +gStyle->SetPalette(53); // set color map +gStyle->SetOptTitle(0); // suppress title box + ... + +Next, you should create a canvas for graphical output, +with size, subdivisions and format suitable to your needs, +see documentation of class TCanvas: + +// create a canvas, specify position and size in pixels +TCanvas c1("c1","<Title>",0,0,400,300); +c1.Divide(2,2); //set subdivisions, called pads +c1.cd(1); //change to pad 1 of canvas c1 + +These parts of a well-written macro are pretty standard, +and you should remember to include pieces +of code like in the examples above to make sure +your output always comes out as you had intended. + + +Below, in , some more +code fragments will be shown, allowing you to use +the system compiler to compile macros for more efficient +execution, or turn macros into stand-alone +applications linked against the ROOT libraries. + +
+ +
+A more complete example + +Let us now look at a rather complete example of a typical task +in data analysis, a macro that constructs a graph with errors, +fits a (linear) model to it and saves it as an image. +To run this macro, simply type in the shell: + + > root macro1.C + +The code is built around the ROOT class +TGraphErrors, which was already introduced previously. +Have a look at it in the class reference guide, +where you will also find further examples. The macro shown below +uses additional classes, TF1 to define a function, +TCanvas to define size and properties of the window used +for our plot, and TLegend to add a nice legend. +For the moment, ignore the commented include statements +for header files, they will only become +important at the end (). + + + + + +Let's comment it in detail: + + + + Line 13: the name of the principal function (it plays the role of +the "main" function in compiled programs) in the macro file. +It has to be the same as the file name without extension. + Line 24-25: instance of the TGraphErrors class. + The constructor takes the number of points and the pointers to the + arrays of $x$~values, $y$~values, $x$~errors (in this case none, + represented by the NULL pointer) and $y$~errors. + The second line defines in one shot the title of the graph and the + titles of the two axes, separated by a ";". + Line 28-30: the first line refers to the style of the plot, set as +Plain. This is done through a manipulation of the global variable +gSystem (ROOT global variables begin always with "g"). +The following three lines are rather intuitive right? +To understand better the enumerators for +colours and styles see the reference for the TColor and +TMarker classes. + + Line 33: the canvas object that will host the drawn objects. The +"memory leak" is intentional, to make the object existing also out of the +macro1 scope. + Line 36: the method DrawClone draws a clone of the object +on the canvas. It has to be a clone, to survive after the scope +of macro1, and be displayed on screen after the end of the macro +execution. The string option "APE" stands for: + + A imposes the drawing of the Axes. + P imposes the drawing of the graphs markers. + E imposes the drawing of the graphs error bars. + + + Line 39: define a mathematical function. There are several ways to +accomplish this, but in this case the constructor accepts the name of +the function, the formula, and the function range. + Line 41: maquillage. Try to give a look to the line +styles at your disposal visiting the documentation of the TLine +class. + Line 43: fits the f function to the graph, observe +that the pointer is passed. It is more interesting to look at the output +on the screen to see the parameters values and other crucial information +that we will learn to read at the end of this guide. + Line 44: again draws the clone of the object on the canvas. The +"Same" option avoids the cancellation of the already drawn objects, in our +case, the graph. + Line 47-52: completes the plot with a legend, represented by a +TLegend instance. The constructor takes as parameters the lower left and +upper right corners coordinates with respect to the total size of the canvas, +assumed to be 1, and the legend header string. +You can add to the legend the objects, previously drawn or not drawn, through +the addEntry method. Observe how the legend is drawn at the end: looks +familiar now, right? + Line 55-57: defines an arrow with a triangle on the right hand side, + a thickness of 2 and draws it. + Line 60-61: interpret a Latex string which hast its lower left corner + located in the specified coordinate. The #splitline{}{} construct + allows to store multiple lines in the same TLatex object. + Line 63: save the canvas as image. The format is automatically +inferred from the file extension (it could have been eps, gif, ...). + + + +Let's give a look to the obtained plot in . +Beautiful outcome for such a small bunch of lines, isn't it? + + + +
Your first plot with data points, a fit of an analytical function, a legend and + some additional information in the form of graphics primitives and text. + A well formatted plot, clear for the reader is crucial to communicate the + relevance of your results to the reader. + Your first plot + + + + + +
+ +
+ +
+Summary of Visual effects +
+Colours and Graph Markers + +We have seen that to specify a colour, some identifiers like kWhite, kRed or +kBlue can be specified for markers, lines, arrows etc. +The complete summary of colours is represented by the +ROOT "colour wheel". +To know more about the full story, refer to the online documentation +of TColor. + + +ROOT provides an analogue of the colour wheel for the +graphics markers. +Select the most suited symbols for your plot among dots, triangles, crosses +or stars. An alternative set of names for the markers is available. + +
+ +
+Arrows and Lines + +The macro line 56 shows how to define an arrow and draw it. +The class representing arrows is TArrow, which inherits +from TLine. +The constructors of lines and arrows always contain the coordinates of +the endpoints. Arrows also foresee parameters to +specify their shapes. +Do not underestimate the role of lines and arrows in your plots. +Since each plot should contain a message, it is convenient to stress it with +additional graphics primitives. + +
+ +
+Text + +Also text plays a fundamental role in making the plots self-explanatory. +A possibility to add text in your plot is provided by the TLatex class. +The objects of this class are constructed with the coordinates of the +bottom-left corner of the text and a string which contains the text itself. +The real twist is that ordinary +Latex mathematical symbols +are automatically interpreted, you just need to replace the "\" +by a "#". + +
+
+ +
+Interpretation and Compilation + +As you observed, up to now we heavily exploited the capabilities of ROOT for +interpreting our code, more than compiling and then executing. This is +sufficient for a wide range of applications, but you might have already asked +yourself "how can this code be compiled ?". There are two answers. + + +
+Compile a Macro with ACLiC + +ACLiC will create for you a compiled dynamic library for your macro, without +any effort from your side, except the insertion of the appropriate header +files in lines 3--9. In this example, they are already included. This does +not harm, as they are not loaded by CINT. To generate an object libary +from the macro code, from inside the interpreter type (please note the "+"): + + root [1] .L macro1.C+ + +Once this operation is accomplished, the macro symbols will be available in +memory and you will be able to execute it simply by calling from inside the +interpreter: + + root [2] macro1() +
+ +
+Compile a Macro with the Compiler + +A plethora of excellent compilers are available, both free and commercial. +We will refer to the GCC compiler in the following. +In this case, you have to include the appropriate headers in the code and +then exploit the root-config tool for the automatic settings of all +the compiler flags. root-config is a script that comes with ROOT; +it prints all flags and libraries needed to compile code and link it with +the ROOT libraries. In order to make the code executable stand-alone, +an entry point for the operating system is needed, in C++ this is the +procedure int main();. The easiest way to turn +a ROOT macro code into a stand-alone application is to add the following +"dressing code" at the end of the macro file. This defines the +procedure main, the only purpose of which is to call your macro: + + +#ifndef __CINT__ +int main() { + ExampleMacro(); + return 0; +} +#endif + +Within ROOT, the variable __CINT__ is defined, and the +code enclosed by #ifndef __CINT__ and #endif is not executed; +on the contrary, when running the system compiler GCC, +this symbol is not defined, and the code is compiled. To create a +stand-alone program from a macro called ExampleMacro.C, +simply type + + > g++ -o ExampleMacro.exe ExampleMacro.C \ + `root-config --cflags --libs` + +and execute it by typing + +> ./ExampleMacro.exe + +This procedure will, however, not give access to the ROOT graphics, +as neither control of mouse or keyboard events nor access to the +graphics windows of ROOT is available. If you want your stand-alone +application have display graphics output and respond to mouse and +keyboard, a slightly more complex piece of code can be used. In the +example below, a macro ExampleMacro_GUI is executed by the ROOT +class TApplication. As a additional feature, this code example offers access +to parameters eventually passed to the program when started from the +command line. Here is the code fragment: + + +#ifndef __CINT__ +void StandaloneApplication(int argc, char** argv) { + // eventually, evaluate the application parameters argc, argv + // ==>> here the ROOT macro is called + ExampleMacro_GUI(); +} + // This is the standard "main" of C++ starting + // a ROOT application +int main(int argc, char** argv) { + TApplication app("Root Application", &argc, argv); + StandaloneApplication(app.Argc(), app.Argv()); + app.Run(); + return 0; +} +#endif + +Compile the code with + + > g++ -o ExampleMacro_GUI.exe \ + ExampleMacro_GUI `root-config --cflags --libs` + + +and execute the program with + +> ./ExampleMacro_GUI.exe +
+
+
diff --git a/docbook/users-guide/CINT.xml b/docbook/users-guide/CINT.xml index 4f24cfc107011..55f34588e3a73 100644 --- a/docbook/users-guide/CINT.xml +++ b/docbook/users-guide/CINT.xml @@ -620,7 +620,7 @@ gSystem->Load("mydir/mylib"); root[] .L readonly/t.C++ -Warning in <ACLiC>: /scratch/aclic/subs/./readonly is not writeable! +Warning in <ACLiC>: /scratch/aclic/subs/./readonly is not writable! Warning in <ACLiC>: Output will be written to /tmp Info in <TUnixSystem::ACLiC>: creating shared library /tmp//scratch/aclic/subs/./readonly/t_C.so diff --git a/docbook/users-guide/Cover.xml b/docbook/users-guide/Cover.xml index 9157cb70e94b4..8cf68931c4907 100644 --- a/docbook/users-guide/Cover.xml +++ b/docbook/users-guide/Cover.xml @@ -6,7 +6,7 @@ Users Guide 5.26 December, 2009 - Comments to: rootdoc@root.cern.ch + Comments to: rootdoc@cern.ch diff --git a/docbook/users-guide/Histograms.xml b/docbook/users-guide/Histograms.xml index 0bdbb52542821..cd6644da0c36a 100644 --- a/docbook/users-guide/Histograms.xml +++ b/docbook/users-guide/Histograms.xml @@ -1064,7 +1064,7 @@ TH1F* h=new TH1F("h",";;Y Axis",100,0,1); The method SetTitle has the same syntax: -h->SetTitle("Histogram title;An other X title Axis"); +h->SetTitle("Histogram title;Another X title Axis"); diff --git a/docbook/users-guide/Introduction.xml b/docbook/users-guide/Introduction.xml index e0a91426d2020..6667ac99cc1da 100644 --- a/docbook/users-guide/Introduction.xml +++ b/docbook/users-guide/Introduction.xml @@ -34,16 +34,16 @@ has been gradually replaced this mailing list since September 2003. The Ro If you have a question, it is likely that it has been asked, answered, and stored in the roottalk or RootTalk Forum archives. Please use the search engine to see if your question has already been answered before sending a mail to the roottalk list or post a topic in the Forum. You can browse the roottalk archives at: http://root.cern.ch/root/roottalk/AboutRootTalk.html. -You can send your question without subscribing to: roottalk@root.cern.ch +You can send your question without subscribing to: roottalk@cern.ch Contact Information Several authors wrote this book and you may see a "change of voice" from one chapter to the next. We felt we could accept this in order to have the expert explain what they know best. If you would like to contribute a chapter or add to a section, please contact -rootdoc@root.cern.ch. We count on you to send us suggestions on additional topics or on the topics that need more +rootdoc@cern.ch. We count on you to send us suggestions on additional topics or on the topics that need more documentation. Please send your comments, corrections, questions, and suggestions to the rootdoc list: -rootdoc@root.cern.ch +rootdoc@cern.ch We attempt to give the user insight into the many capabilities of ROOT. The book begins with the elementary functionality and progresses in complexity reaching the specialized topics at the end. The experienced user looking for special topics may find these chapters useful: see “Networking”, “Writing a Graphical User Interface”, “Threads”, and “PROOF: Parallel Processing”. diff --git a/docbook/users-guide/MathLibraries.xml b/docbook/users-guide/MathLibraries.xml index 9cf013a1129e7..95a7d79035e0f 100644 --- a/docbook/users-guide/MathLibraries.xml +++ b/docbook/users-guide/MathLibraries.xml @@ -254,7 +254,7 @@ for (int i = 0; i<N; ++i) double x = unr.Sample(); -For continous 1D distribution object via the class TUnuranContDist that can be created for example from a TF1 function providing the pdf (probability density function) . The user can optionally provide additional information via TUnuranContDist::SetDomain(min,max) like the domain() for generating numbers in a restricted region. +For continuous 1D distribution object via the class TUnuranContDist that can be created for example from a TF1 function providing the pdf (probability density function) . The user can optionally provide additional information via TUnuranContDist::SetDomain(min,max) like the domain() for generating numbers in a restricted region. //1D case: create a distribution from two TF1 object pointers pdfFunc diff --git a/docbook/users-guide/WritingGUI.xml b/docbook/users-guide/WritingGUI.xml index fb69b4da8227d..75ce437674256 100644 --- a/docbook/users-guide/WritingGUI.xml +++ b/docbook/users-guide/WritingGUI.xml @@ -127,7 +127,7 @@ MyMainFrame::MyMainFrame(const TGWindow *p,UInt_t w,UInt_t h) { fMain->MapWindow(); } void MyMainFrame::DoDraw() { - // Draws function graphics in randomly choosen interval + // Draws function graphics in randomly chosen interval TF1 *f1 = new TF1("f1","sin(x)/x",0,gRandom->Rndm()*10); f1->SetLineWidth(3); f1->Draw(); diff --git a/etc/HistFactorySchema.dtd b/etc/HistFactorySchema.dtd index 99d20ab2cbb30..452dd506701cd 100644 --- a/etc/HistFactorySchema.dtd +++ b/etc/HistFactorySchema.dtd @@ -156,5 +156,9 @@ For this element there is no sublemenents so the setting will only have local ef diff --git a/etc/cmake/FindROOT.cmake b/etc/cmake/FindROOT.cmake new file mode 100644 index 0000000000000..85d5acdaa119f --- /dev/null +++ b/etc/cmake/FindROOT.cmake @@ -0,0 +1,161 @@ +# - Finds ROOT instalation +# This module sets up ROOT information +# It defines: +# ROOT_FOUND If the ROOT is found +# ROOT_INCLUDE_DIR PATH to the include directory +# ROOT_LIBRARIES Most common libraries +# ROOT_LIBRARY_DIR PATH to the library directory + + +find_program(ROOT_CONFIG_EXECUTABLE root-config + PATHS $ENV{ROOTSYS}/bin) + +if(NOT ROOT_CONFIG_EXECUTABLE) + set(ROOT_FOUND FALSE) +else() + set(ROOT_FOUND TRUE) + + execute_process( + COMMAND ${ROOT_CONFIG_EXECUTABLE} --prefix + OUTPUT_VARIABLE ROOTSYS + OUTPUT_STRIP_TRAILING_WHITESPACE) + + execute_process( + COMMAND ${ROOT_CONFIG_EXECUTABLE} --version + OUTPUT_VARIABLE ROOT_VERSION + OUTPUT_STRIP_TRAILING_WHITESPACE) + + execute_process( + COMMAND ${ROOT_CONFIG_EXECUTABLE} --incdir + OUTPUT_VARIABLE ROOT_INCLUDE_DIR + OUTPUT_STRIP_TRAILING_WHITESPACE) + + execute_process( + COMMAND ${ROOT_CONFIG_EXECUTABLE} --libs + OUTPUT_VARIABLE ROOT_LIBRARIES + OUTPUT_STRIP_TRAILING_WHITESPACE) + + #set(ROOT_LIBRARIES ${ROOT_LIBRARIES} -lThread -lMinuit -lHtml -lVMC -lEG -lGeom -lTreePlayer -lXMLIO -lProof) + #set(ROOT_LIBRARIES ${ROOT_LIBRARIES} -lProofPlayer -lMLP -lSpectrum -lEve -lRGL -lGed -lXMLParser -lPhysics) + set(ROOT_LIBRARY_DIR ${ROOTSYS}/lib) + + # Make variables changeble to the advanced user + mark_as_advanced(ROOT_CONFIG_EXECUTABLE) + + if(NOT ROOT_FIND_QUIETLY) + message(STATUS "Found ROOT ${ROOT_VERSION} in ${ROOTSYS}") + endif() +endif() + + +include(CMakeMacroParseArguments) +find_program(ROOTCINT_EXECUTABLE rootcint PATHS $ENV{ROOTSYS}/bin) +find_program(GENREFLEX_EXECUTABLE genreflex PATHS $ENV{ROOTSYS}/bin) +find_package(GCCXML) + +#---------------------------------------------------------------------------- +# function ROOT_GENERATE_DICTIONARY( dictionary +# header1 header2 ... +# LINKDEF linkdef1 ... +# OPTIONS opt1...) +function(ROOT_GENERATE_DICTIONARY dictionary) + CMAKE_PARSE_ARGUMENTS(ARG "" "" "LINKDEF;OPTIONS" "" ${ARGN}) + #---Get the list of header files------------------------- + set(headerfiles) + foreach(fp ${ARG_UNPARSED_ARGUMENTS}) + file(GLOB files ${fp}) + if(files) + foreach(f ${files}) + if(NOT f MATCHES LinkDef) + set(headerfiles ${headerfiles} ${f}) + endif() + endforeach() + else() + set(headerfiles ${headerfiles} ${fp}) + endif() + endforeach() + #---Get the list of include directories------------------ + get_directory_property(incdirs INCLUDE_DIRECTORIES) + set(includedirs) + foreach( d ${incdirs}) + set(includedirs ${includedirs} -I${d}) + endforeach() + #---Get LinkDef.h file------------------------------------ + set(linkdefs) + foreach( f ${ARG_LINKDEF}) + if( IS_ABSOLUTE ${f}) + set(linkdefs ${linkdefs} ${f}) + else() + if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/inc/${f}) + set(linkdefs ${linkdefs} ${CMAKE_CURRENT_SOURCE_DIR}/inc/${f}) + else() + set(linkdefs ${linkdefs} ${CMAKE_CURRENT_SOURCE_DIR}/${f}) + endif() + endif() + endforeach() + #---call rootcint------------------------------------------ + add_custom_command(OUTPUT ${dictionary}.cxx ${dictionary}.h + COMMAND ${ROOTCINT_EXECUTABLE} -cint -f ${dictionary}.cxx + -c ${ARG_OPTIONS} ${includedirs} ${headerfiles} ${linkdefs} + DEPENDS ${headerfiles} ${linkdefs}) +endfunction() + +#---------------------------------------------------------------------------- +# function REFLEX_GENERATE_DICTIONARY(dictionary +# header1 header2 ... +# SELECTION selectionfile ... +# OPTIONS opt1...) +function(REFLEX_GENERATE_DICTIONARY dictionary) + CMAKE_PARSE_ARGUMENTS(ARG "" "" "SELECTION;OPTIONS" "" ${ARGN}) + #---Get the list of header files------------------------- + set(headerfiles) + foreach(fp ${ARG_UNPARSED_ARGUMENTS}) + file(GLOB files ${fp}) + if(files) + foreach(f ${files}) + set(headerfiles ${headerfiles} ${f}) + endforeach() + else() + set(headerfiles ${headerfiles} ${fp}) + endif() + endforeach() + #---Get Selection file------------------------------------ + if(IS_ABSOLUTE ${ARG_SELECTION}) + set(selectionfile ${ARG_SELECTION}) + else() + set(selectionfile ${CMAKE_CURRENT_SOURCE_DIR}/${ARG_SELECTION}) + endif() + #---Get the list of include directories------------------ + get_directory_property(incdirs INCLUDE_DIRECTORIES) + set(includedirs) + foreach( d ${incdirs}) + set(includedirs ${includedirs} -I${d}) + endforeach() + #---Get preprocessor definitions-------------------------- + get_directory_property(defs COMPILE_DEFINITIONS) + foreach( d ${defs}) + set(definitions ${definitions} -D${d}) + endforeach() + #---Nanes and others--------------------------------------- + set(gensrcdict ${dictionary}.cpp) + if(MSVC) + set(gccxmlopts "--gccxmlopt=\"--gccxml-compiler cl\"") + else() + #set(gccxmlopts "--gccxmlopt=\'--gccxml-cxxflags -m64 \'") + set(gccxmlopts) + endif() + #set(rootmapname ${dictionary}Dict.rootmap) + #set(rootmapopts --rootmap=${rootmapname} --rootmap-lib=${libprefix}${dictionary}Dict) + #---Check GCCXML and get path----------------------------- + if(GCCXML) + get_filename_component(gccxmlpath ${GCCXML} PATH) + else() + message(WARNING "GCCXML not found. Install and setup your environment to find 'gccxml' executable") + endif() + #---Actual command---------------------------------------- + add_custom_command(OUTPUT ${gensrcdict} ${rootmapname} + COMMAND ${GENREFLEX_EXECUTABLE} ${headerfiles} -o ${gensrcdict} ${gccxmlopts} ${rootmapopts} --select=${selectionfile} + --gccxmlpath=${gccxmlpath} ${ARG_OPTIONS} ${includedirs} ${definitions} + DEPENDS ${headerfiles} ${selectionfile}) +endfunction() + diff --git a/etc/html/HELP.html b/etc/html/HELP.html index ac22474cbbfcd..e1119432458b7 100755 --- a/etc/html/HELP.html +++ b/etc/html/HELP.html @@ -2,7 +2,7 @@ - + @@ -224,7 +224,7 @@

Member Function Documentation

Copyright (C) 1995-2000, Rene Brun and Fons Rademakers.

-This page has been hand crafted. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT. +This page has been hand crafted. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.

diff --git a/etc/html/footer.html b/etc/html/footer.html index b3241abc1059e..dde53b7250d67 100755 --- a/etc/html/footer.html +++ b/etc/html/footer.html @@ -3,7 +3,7 @@
diff --git a/etc/html/header.html b/etc/html/header.html index dbb47f279561a..582946a6e9156 100755 --- a/etc/html/header.html +++ b/etc/html/header.html @@ -2,7 +2,7 @@ - + diff --git a/etc/plugins/TDataSetManager/P020_TDataSetManagerAliEn.C b/etc/plugins/TDataSetManager/P020_TDataSetManagerAliEn.C new file mode 100644 index 0000000000000..f931e07f6acfa --- /dev/null +++ b/etc/plugins/TDataSetManager/P020_TDataSetManagerAliEn.C @@ -0,0 +1,5 @@ +void P020_TDataSetManagerAliEn() +{ + gPluginMgr->AddHandler("TDataSetManager", "^alien", "TDataSetManagerAliEn", "Proof", + "TDataSetManagerAliEn(const char *,const char *,const char *)"); +} diff --git a/etc/plugins/TFile/P010_TWebFile.C b/etc/plugins/TFile/P010_TWebFile.C index e443c8748a50f..662b2661736a5 100644 --- a/etc/plugins/TFile/P010_TWebFile.C +++ b/etc/plugins/TFile/P010_TWebFile.C @@ -1,5 +1,5 @@ void P010_TWebFile() { - gPluginMgr->AddHandler("TFile", "^http:", "TWebFile", + gPluginMgr->AddHandler("TFile", "^http[s]?:", "TWebFile", "Net", "TWebFile(const char*,Option_t*)"); } diff --git a/etc/plugins/TFile/P100_TXNetFile.C b/etc/plugins/TFile/P100_TXNetFile.C index 7c50b5bb3a542..59d52df7bf3cf 100644 --- a/etc/plugins/TFile/P100_TXNetFile.C +++ b/etc/plugins/TFile/P100_TXNetFile.C @@ -1,5 +1,10 @@ void P100_TXNetFile() { - gPluginMgr->AddHandler("TFile", "^root:", "TXNetFile", - "Netx", "TXNetFile(const char*,Option_t*,const char*,Int_t,Int_t,Bool_t)"); + if (!gEnv->GetValue( "XNet.UseOldClient", 0)) { + gPluginMgr->AddHandler("TFile", "^[x]?root:", "TNetXNGFile", + "NetXNG", "TNetXNGFile(const char*,Option_t*,const char*,Int_t,Int_t,Bool_t)"); + } else { + gPluginMgr->AddHandler("TFile", "^[x]?root:", "TXNetFile", + "Netx", "TXNetFile(const char*,Option_t*,const char*,Int_t,Int_t,Bool_t)"); + } } diff --git a/etc/plugins/TFile/P130_TAS3File.C b/etc/plugins/TFile/P130_TAS3File.C deleted file mode 100644 index bdee5cde30ed4..0000000000000 --- a/etc/plugins/TFile/P130_TAS3File.C +++ /dev/null @@ -1,5 +0,0 @@ -void P130_TAS3File() -{ - gPluginMgr->AddHandler("TFile", "^as3:", "TAS3File", - "Net", "TAS3File(const char*,Option_t*)"); -} diff --git a/etc/plugins/TFile/P130_TDavixFile.C b/etc/plugins/TFile/P130_TDavixFile.C new file mode 100644 index 0000000000000..cd18b52f01c38 --- /dev/null +++ b/etc/plugins/TFile/P130_TDavixFile.C @@ -0,0 +1,20 @@ +void P130_TDavixFile() +{ + TString configfeatures = gROOT->GetConfigFeatures(); + + // only if ROOT was compiled with davix enabled do we configure a handler + if ( configfeatures.Contains("davix") ) { + + gPluginMgr->AddHandler("TFile", "^http[s]?:", "TDavixFile", + "RDAVIX", "TDavixFile(const char*, Option_t *, const char *,Int_t)"); + + gPluginMgr->AddHandler("TFile", "^dav[s]?:", "TDavixFile", + "RDAVIX", "TDavixFile(const char*, Option_t *, const char *,Int_t)"); + + gPluginMgr->AddHandler("TFile", "^s3[s]?:", "TDavixFile", + "RDAVIX", "TDavixFile(const char*, Option_t *, const char *,Int_t)"); + + } else { + //Error("P130_TDavixFile","Please fix your ROOT config to be able to load libdavix.so"); + } +} diff --git a/etc/plugins/TFile/P140_TGSFile.C b/etc/plugins/TFile/P140_TGSFile.C deleted file mode 100644 index 9803c5a0476fc..0000000000000 --- a/etc/plugins/TFile/P140_TGSFile.C +++ /dev/null @@ -1,5 +0,0 @@ -void P140_TGSFile() -{ - gPluginMgr->AddHandler("TFile", "^gs:", "TGSFile", - "Net", "TGSFile(const char*,Option_t*)"); -} diff --git a/etc/plugins/TFile/P150_TS3WebFile.C b/etc/plugins/TFile/P150_TS3WebFile.C new file mode 100644 index 0000000000000..85f28d17b8bd3 --- /dev/null +++ b/etc/plugins/TFile/P150_TS3WebFile.C @@ -0,0 +1,11 @@ +void P150_TS3WebFile() +{ + gPluginMgr->AddHandler("TFile", "^[a]?s3:", "TS3WebFile", + "Net", "TS3WebFile(const char*,Option_t*)"); + gPluginMgr->AddHandler("TFile", "^s3http[s]?:", "TS3WebFile", + "Net", "TS3WebFile(const char*,Option_t*)"); + gPluginMgr->AddHandler("TFile", "^gs:", "TS3WebFile", + "Net", "TS3WebFile(const char*,Option_t*)"); + gPluginMgr->AddHandler("TFile", "^gshttp[s]?:", "TS3WebFile", + "Net", "TS3WebFile(const char*,Option_t*)"); +} diff --git a/etc/plugins/TFileStager/P010_TXNetFileStager.C b/etc/plugins/TFileStager/P010_TXNetFileStager.C index 1743e38ed938d..884ce7e1032d9 100644 --- a/etc/plugins/TFileStager/P010_TXNetFileStager.C +++ b/etc/plugins/TFileStager/P010_TXNetFileStager.C @@ -1,5 +1,10 @@ void P010_TXNetFileStager() { - gPluginMgr->AddHandler("TFileStager", "^root:", "TXNetFileStager", - "Netx", "TXNetFileStager(const char *)"); + if (!gEnv->GetValue("XNet.UseOldClient", 0)) { + gPluginMgr->AddHandler("TFileStager", "^[x]?root:", "TNetXNGFileStager", + "NetXNG", "TNetXNGFileStager(const char *)"); + } else { + gPluginMgr->AddHandler("TFileStager", "^[x]?root:", "TXNetFileStager", + "Netx", "TXNetFileStager(const char *)"); + } } diff --git a/etc/plugins/TProof/P030_TProofPEAC.C b/etc/plugins/TProof/P030_TProofPEAC.C deleted file mode 100644 index 32390c325c046..0000000000000 --- a/etc/plugins/TProof/P030_TProofPEAC.C +++ /dev/null @@ -1,5 +0,0 @@ -void P030_TProofPEAC() -{ - gPluginMgr->AddHandler("TProof", "^peac:", "TProofPEAC", - "Peac", "TProofPEAC(const char*,const char*,const char*,Int_t,const char*)"); -} diff --git a/etc/plugins/TSQLServer/P060_TSQLiteServer.C b/etc/plugins/TSQLServer/P060_TSQLiteServer.C new file mode 100644 index 0000000000000..569bcf474d347 --- /dev/null +++ b/etc/plugins/TSQLServer/P060_TSQLiteServer.C @@ -0,0 +1,5 @@ +void P060_TSQLiteServer() +{ + gPluginMgr->AddHandler("TSQLServer", "^sqlite:", "TSQLiteServer", + "SQLite", "TSQLiteServer(const char*,const char*,const char*)"); +} diff --git a/etc/plugins/TSystem/P040_TXNetSystem.C b/etc/plugins/TSystem/P040_TXNetSystem.C index 92d330be15585..5a1ccd036fed2 100644 --- a/etc/plugins/TSystem/P040_TXNetSystem.C +++ b/etc/plugins/TSystem/P040_TXNetSystem.C @@ -1,5 +1,10 @@ void P040_TXNetSystem() { - gPluginMgr->AddHandler("TSystem", "^root:", "TXNetSystem", - "Netx", "TXNetSystem(const char *,Bool_t)"); + if (!gEnv->GetValue("XNet.UseOldClient", 0)) { + gPluginMgr->AddHandler("TSystem", "^[x]?root:", "TNetXNGSystem", + "NetXNG", "TNetXNGSystem(const char *,Bool_t)"); + } else { + gPluginMgr->AddHandler("TSystem", "^[x]?root:", "TXNetSystem", + "Netx", "TXNetSystem(const char *,Bool_t)"); + } } diff --git a/etc/plugins/TSystem/P045_TDavixSystem.C b/etc/plugins/TSystem/P045_TDavixSystem.C new file mode 100644 index 0000000000000..ac7f50cd875f8 --- /dev/null +++ b/etc/plugins/TSystem/P045_TDavixSystem.C @@ -0,0 +1,20 @@ +void P045_TDavixSystem() +{ + TString configfeatures = gROOT->GetConfigFeatures(); + + // only if ROOT was compiled with davix enabled do we configure a handler + if ( configfeatures.Contains("davix") ) { + + gPluginMgr->AddHandler("TSystem", "^http[s]?:", "TDavixSystem", + "RDAVIX", "TDavixSystem()"); + + gPluginMgr->AddHandler("TSystem", "^dav[s]?:", "TDavixSystem", + "RDAVIX", "TDavixSystem()"); + + gPluginMgr->AddHandler("TSystem", "^s3[s]?:", "TDavixSystem", + "RDAVIX", "TDavixSystem()"); + + } else { + //Error("P045_TDavixSystem","Please fix your ROOT config to be able to load libdavix.so"); + } +} diff --git a/etc/plugins/TVirtualPS/P050_TTeXDump.C b/etc/plugins/TVirtualPS/P050_TTeXDump.C new file mode 100644 index 0000000000000..d46ceae0ed0f3 --- /dev/null +++ b/etc/plugins/TVirtualPS/P050_TTeXDump.C @@ -0,0 +1,5 @@ +void P050_TTeXDump() +{ + gPluginMgr->AddHandler("TVirtualPS", "tex", "TTeXDump", + "Postscript", "TTeXDump()"); +} diff --git a/etc/proof/xpd.cf.sample b/etc/proof/xpd.cf.sample index be3e530b8c368..a14f78ff081c6 100644 --- a/etc/proof/xpd.cf.sample +++ b/etc/proof/xpd.cf.sample @@ -32,7 +32,7 @@ xrootd.fslib libXrdOfs.so ### to export /tmp. ### NB: specifying any of these directives removes the default /tmp ### from the internal list; in such a case a directive needs to -### be given explicitely if /tmp needs to be exposed. +### be given explicitly if /tmp needs to be exposed. xrootd.export /tmp xrootd.export /pool/data @@ -63,7 +63,7 @@ xrd.protocol xproofd:1093 libXrdProofd.so ### ### Directives governing the behaviour of the XrdProofd plug-in. -### Except when explicitely indicated, all the following directives support +### Except when explicitly indicated, all the following directives support ### an optional 'if ' condition at the end of the line, e.g. ### xpd.rootsys /opt/root if lxb*.cern.ch ### xpd.rootsys /usr/local if lxp*.cern.ch @@ -100,7 +100,7 @@ xrd.protocol xproofd:1093 libXrdProofd.so # Format: # xpd.shutdown # where: -# is the type of action to be taken when a client completly +# is the type of action to be taken when a client completely # disconnets; the options are: # 0 remain connected # 1 terminate when idle diff --git a/etc/valgrind-root.supp b/etc/valgrind-root.supp index 273abe902c374..019624d5fa0ae 100644 --- a/etc/valgrind-root.supp +++ b/etc/valgrind-root.supp @@ -12,8 +12,8 @@ { TClass::AddClass()'s std::string Memcheck:Leak - fun:_Znwm - fun:_ZNSs4_Rep9_S_createEmmRKSaIcE + fun:_Znw? + fun:_ZNSs4_Rep9_S_createE??RKSaIcE ... fun:_ZNSsC1EPKcRKSaIcE fun:_ZN6TClass8AddClassEPS_ @@ -22,15 +22,15 @@ { TCint::CreateListOfBaseClasses(TClass*) Memcheck:Leak - fun:_Znwm - fun:_ZN8TStorage11ObjectAllocEm + fun:_Znw? + fun:_ZN8TStorage11ObjectAllocE? fun:_ZN5TCint23CreateListOfBaseClassesEP6TClass } { Memcheck:Leak - fun:_Znwm + fun:_Znw? fun:_ZN5TList7NewLinkEP7TObjectP8TObjLink fun:_ZN5TList7AddLastEP7TObject fun:_ZN5TCint23CreateListOfBaseClassesEP6TClass @@ -39,16 +39,25 @@ { TGenericClassInfo's fClass generated by ROOT::TQObjectInitBehavior::CreateClass() Memcheck:Leak - fun:_Znwm - fun:_ZN8TStorage11ObjectAllocEm - fun:_ZN7TObjectnwEm + fun:_Znw? + fun:_ZN8TStorage11ObjectAllocE? + fun:_ZN7TObjectnwE? fun:_ZNK4ROOT20TQObjectInitBehavior11CreateClassEPKcsRKSt9type_info* } +{ + TClass long name + Memcheck:Leak + fun:_Zna? + fun:_ZN7TString4InitEii + fun:_ZN7TStringC1EPKc + fun:_ZN6TClassC2EPKc* +} + { TDictionary long name Memcheck:Leak - fun:_Znam + fun:_Zna? fun:_ZN7TString4InitEii fun:_ZN7TStringC1EPKc fun:_ZN6TNamedC1EPKcS1_ @@ -58,17 +67,27 @@ { TBaseClass long name Memcheck:Leak - fun:_Znam + fun:_Zna? fun:_ZN7TString7ReplaceEiiPKci fun:_ZN7TStringaSEPKc fun:_ZN6TNamed7SetNameEPKc fun:_ZN10TBaseClassC1EPvP6TClass } +{ + TDataType long name + Memcheck:Leak + fun:_Zna? + fun:_ZN7TString7ReplaceEiiPKci + fun:_ZN7TStringaSEPKc + ... + fun:_ZN9TDataTypeC1EPv +} + { Anything allocated by TClass::Init: new[]() Memcheck:Leak - fun:_Znam + fun:_Zna? ... fun:_ZN6TClass4InitEPKcs* } @@ -76,7 +95,7 @@ { Anything allocated by TClass::Init: new() Memcheck:Leak - fun:_Znwm + fun:_Znw? ... fun:_ZN6TClass4InitEPKcs* } @@ -84,18 +103,18 @@ { TClass thread local storage Memcheck:Leak - fun:_Znwm - fun:_ZN8TStorage11ObjectAllocEm - fun:_ZN7TObjectnwEm + fun:_Znw? + fun:_ZN8TStorage11ObjectAllocE? + fun:_ZN7TObjectnwE? fun:_ZN12_GLOBAL__N_118TClassLocalStorage10GetStorageEPK6TClass } { TThread global mutex Memcheck:Leak - fun:_Znwm - fun:_ZN8TStorage11ObjectAllocEm - fun:_ZN7TObjectnwEm + fun:_Znw? + fun:_ZN8TStorage11ObjectAllocE? + fun:_ZN7TObjectnwE? fun:_ZN7TThread4InitEv fun:_ZN7TThread11ConstructorEv fun:_ZN7TThreadC1EPKcPFPvS2_ES2_NS_9EPriorityE @@ -104,7 +123,7 @@ { TClass's list of base classes (TDataMember elements) Memcheck:Leak - fun:_Znwm + fun:_Znw? fun:_ZN5TList7NewLinkEP7TObjectP8TObjLink fun:_ZN5TList7AddLastEP7TObject fun:_ZN5TList3AddEP7TObject @@ -114,56 +133,73 @@ { TClass's list of base classes (G__DataMemberInfo elements) Memcheck:Leak - fun:_Znwm + fun:_Znw? fun:_ZN5TCint23CreateListOfBaseClassesEP6TClass } { TClass's list of base classes (TList container) Memcheck:Leak - fun:_Znwm - fun:_ZN8TStorage11ObjectAllocEm - fun:_ZN7TObjectnwEm + fun:_Znw? + fun:_ZN8TStorage11ObjectAllocE? + fun:_ZN7TObjectnwE? fun:_ZN5TCint23CreateListOfBaseClassesEP6TClass } { Unloaded TClass and its fClassInfo Memcheck:Leak - fun:_Znwm + fun:_Znw? fun:_ZN5TCint12SetClassInfoEP6TClassb fun:_ZN6TClass11SetUnloadedEv } + +{ + TClass::Init calling TCint::SetClassInfo + Memcheck:Leak + fun:_Znw? + fun:_ZN5TCint12SetClassInfoEP6TClassb + fun:_ZN6TClass4InitEPKcsPKSt9type_infoP16TVirtualIsAProxyPFvPvR16TMemberInspectorES1_S1_iib +} { std::string uses in various place. Memcheck:Leak - fun:_Znwm - fun:_ZNSs4_Rep9_S_createEmmRKSaIcE - fun:_ZNSs9_M_mutateEmmm - fun:_ZNSs15_M_replace_safeEmmPKcm + fun:_Znw? + fun:_ZNSs4_Rep9_S_createE??RKSaIcE + fun:_ZNSs9_M_mutateE??? + fun:_ZNSs15_M_replace_safeE??PKc? } { Array of objects allocated in TStreamerInfo::Compile Memcheck:Leak - fun:_Znam + fun:_Zna? fun:_ZN13TStreamerInfo7CompileEv } { Strings allocated in TStreamerInfo::Compile Memcheck:Leak - fun:_Znam + fun:_Zna? fun:_ZN7TString7ReplaceEiiPKci fun:_ZN7TStringaSERK10TSubString fun:_ZN13TStreamerInfo7CompileEv } +{ + String reallocated in TStreamerInfo::Compile + Memcheck:Leak + fun:_Zna? + fun:_ZN7TString7ReplaceEiiPKci + fun:_ZN13TStreamerInfo7CompileEv + +} + { StreamerInfo virtual table mechanism Memcheck:Leak - fun:_Znam + fun:_Zna? fun:_ZN13TStreamerInfo8BuildOldEv fun:_ZNK6TClass15GetStreamerInfoEi } @@ -171,9 +207,9 @@ { StreamerInfo parts Memcheck:Leak - fun:_Znwm - fun:_ZN8TStorage11ObjectAllocEm - fun:_ZN7TObjectnwEm + fun:_Znw? + fun:_ZN8TStorage11ObjectAllocE? + fun:_ZN7TObjectnwE? fun:_ZN4ROOTL13new_TObjArrayEPv fun:_ZNK6TClass3NewENS_8ENewTypeE fun:_ZN11TBufferFile13ReadObjectAnyEPK6TClass @@ -184,8 +220,8 @@ { StreamerInfo parts Memcheck:Leak - fun:_Znam - fun:_ZN8TStorage5AllocEm + fun:_Zna? + fun:_ZN8TStorage5AllocE? fun:_ZN9TObjArray4InitEii fun:_ZN9TObjArrayC1Eii fun:_ZN4ROOTL13new_TObjArrayEPv @@ -198,14 +234,14 @@ { CollectionProxy objects Memcheck:Leak - fun:_Znwm + fun:_Znw? fun:_ZN23TCollectionProxyFactory24GenEmulatedClassStreamerEPKc } { CollectionProxy objects Memcheck:Leak - fun:_Znwm + fun:_Znw? fun:_ZNK19TGenCollectionProxy8GenerateEv fun:_ZNK6TClass18GetCollectionProxyEv } @@ -213,7 +249,7 @@ { CollectionProxy objects Memcheck:Leak - fun:_Znwm + fun:_Znw? fun:_ZNK19TGenCollectionProxy8GenerateEv fun:_ZN14TBranchElement4InitEP5TTreeP7TBranchPKcP23TVirtualCollectionProxyiii } @@ -221,7 +257,7 @@ { Part of CollectionProxy objects Memcheck:Leak - fun:_Znwm + fun:_Znw? ... fun:_ZN19TGenCollectionProxyC1ERKS_ } @@ -229,7 +265,7 @@ { Part of CollectionProxy objects Memcheck:Leak - fun:_Znam + fun:_Zna? ... fun:_ZN19TGenCollectionProxyC1ERKS_ } @@ -237,7 +273,7 @@ { TClass's list of RealData. Memcheck:Leak - fun:_Znwm + fun:_Znw? fun:_ZN5TList7NewLinkEP7TObjectP8TObjLink fun:_ZN5TList7AddLastEP7TObject fun:_ZN5TList3AddEP7TObject @@ -247,48 +283,48 @@ { TClass's RealData objects. Memcheck:Leak - fun:_Znwm - fun:_ZN8TStorage11ObjectAllocEm - fun:_ZN7TObjectnwEm + fun:_Znw? + fun:_ZN8TStorage11ObjectAllocE? + fun:_ZN7TObjectnwE? fun:_ZN6TClass21BuildEmulatedRealDataEPKclPS_ } { TClass's RealData objects. Memcheck:Leak - fun:_Znwm - fun:_ZN8TStorage11ObjectAllocEm - fun:_ZN7TObjectnwEm + fun:_Znw? + fun:_ZN8TStorage11ObjectAllocE? + fun:_ZN7TObjectnwE? fun:_ZN6TClass13BuildRealDataEPvb } { TEmulatedCollectionProxy configuration item Memcheck:Leak - fun:_Znwm + fun:_Znw? fun:_ZN24TEmulatedCollectionProxy12InitializeExEv } { ROOT's list of types objects Memcheck:Leak - fun:_Znwm - fun:_ZN8TStorage11ObjectAllocEm - fun:_ZN7TObjectnwEm + fun:_Znw? + fun:_ZN8TStorage11ObjectAllocE? + fun:_ZN7TObjectnwE? fun:_ZN5TCint17UpdateListOfTypesEv } { ROOT's list of types Memcheck:Leak - fun:_Znwm + fun:_Znw? fun:_ZN5TCint17UpdateListOfTypesEv } { ROOT's list of types internals Memcheck:Leak - fun:_Znwm + fun:_Znw? fun:_ZN5TList7NewLinkEP7TObjectP8TObjLink fun:_ZN5TList7AddLastEP7TObject fun:_ZN5TList3AddEP7TObject @@ -379,8 +415,8 @@ { CINT's NameMap part1 Memcheck:Leak - fun:_Znwm - fun:_ZN9__gnu_cxx13new_allocatorISt13_Rb_tree_nodeIiEE8allocateEmPKv + fun:_Znw? + fun:_ZN9__gnu_cxx13new_allocatorISt13_Rb_tree_nodeIiEE8allocateE?PKv fun:_ZNSt8_Rb_treeIiiSt9_IdentityIiESt4lessIiESaIiEE11_M_get_nodeEv fun:_ZNSt8_Rb_treeIiiSt9_IdentityIiESt4lessIiESaIiEE14_M_create_nodeERKi fun:_ZNSt8_Rb_treeIiiSt9_IdentityIiESt4lessIiESaIiEE10_M_insert_EPKSt18_Rb_tree_node_baseS8_RKi @@ -392,8 +428,8 @@ { CINT's NameMap part2 Memcheck:Leak - fun:_Znwm - fun:_ZN9__gnu_cxx13new_allocatorISt13_Rb_tree_nodeISt4pairIKPKcSt3setIiSt4lessIiESaIiEEEEE8allocateEmPKv + fun:_Znw? + fun:_ZN9__gnu_cxx13new_allocatorISt13_Rb_tree_nodeISt4pairIKPKcSt3setIiSt4lessIiESaIiEEEEE8allocateE?PKv fun:_ZNSt8_Rb_treeIPKcSt4pairIKS1_St3setIiSt4lessIiESaIiEEESt10_Select1stIS9_EN7NameMap15G__charptr_lessESaIS9_EE11_M_get_nodeEv fun:_ZNSt8_Rb_treeIPKcSt4pairIKS1_St3setIiSt4lessIiESaIiEEESt10_Select1stIS9_EN7NameMap15G__charptr_lessESaIS9_EE14_M_create_nodeERKS9_ fun:_ZNSt8_Rb_treeIPKcSt4pairIKS1_St3setIiSt4lessIiESaIiEEESt10_Select1stIS9_EN7NameMap15G__charptr_lessESaIS9_EE10_M_insert_EPKSt18_Rb_tree_node_baseSI_RKS9_ @@ -407,8 +443,8 @@ { CINT's NameMap part3 Memcheck:Leak - fun:_Znwm - fun:_ZN9__gnu_cxx13new_allocatorISt13_Rb_tree_nodeISt4pairIKPKcSt3setIiSt4lessIiESaIiEEEEE8allocateEmPKv + fun:_Znw? + fun:_ZN9__gnu_cxx13new_allocatorISt13_Rb_tree_nodeISt4pairIKPKcSt3setIiSt4lessIiESaIiEEEEE8allocateE?PKv fun:_ZNSt8_Rb_treeIPKcSt4pairIKS1_St3setIiSt4lessIiESaIiEEESt10_Select1stIS9_EN7NameMap15G__charptr_lessESaIS9_EE11_M_get_nodeEv fun:_ZNSt8_Rb_treeIPKcSt4pairIKS1_St3setIiSt4lessIiESaIiEEESt10_Select1stIS9_EN7NameMap15G__charptr_lessESaIS9_EE14_M_create_nodeERKS9_ fun:* @@ -453,7 +489,7 @@ { TUnixSystem::Setenv, see its doc Memcheck:Leak - fun:_Znam + fun:_Zna? fun:_ZN11TUnixSystem6SetenvEPKcS1_ } diff --git a/fonts/DroidSansFallback.ttf b/fonts/DroidSansFallback.ttf new file mode 100644 index 0000000000000..0cacabedcaeda Binary files /dev/null and b/fonts/DroidSansFallback.ttf differ diff --git a/fonts/FreeMono.otf b/fonts/FreeMono.otf new file mode 100644 index 0000000000000..76e817fe6cc57 Binary files /dev/null and b/fonts/FreeMono.otf differ diff --git a/fonts/FreeMonoBold.otf b/fonts/FreeMonoBold.otf new file mode 100644 index 0000000000000..42ca0030689b2 Binary files /dev/null and b/fonts/FreeMonoBold.otf differ diff --git a/fonts/FreeMonoBoldOblique.otf b/fonts/FreeMonoBoldOblique.otf new file mode 100644 index 0000000000000..50d731e2b7fc6 Binary files /dev/null and b/fonts/FreeMonoBoldOblique.otf differ diff --git a/fonts/FreeMonoOblique.otf b/fonts/FreeMonoOblique.otf new file mode 100644 index 0000000000000..67a1c386ba6c1 Binary files /dev/null and b/fonts/FreeMonoOblique.otf differ diff --git a/fonts/FreeSans.otf b/fonts/FreeSans.otf new file mode 100644 index 0000000000000..e37a478658ae2 Binary files /dev/null and b/fonts/FreeSans.otf differ diff --git a/fonts/FreeSansBold.otf b/fonts/FreeSansBold.otf new file mode 100644 index 0000000000000..1894ac0e8b2d8 Binary files /dev/null and b/fonts/FreeSansBold.otf differ diff --git a/fonts/FreeSansBoldOblique.otf b/fonts/FreeSansBoldOblique.otf new file mode 100644 index 0000000000000..d07f2e11ad788 Binary files /dev/null and b/fonts/FreeSansBoldOblique.otf differ diff --git a/fonts/FreeSansOblique.otf b/fonts/FreeSansOblique.otf new file mode 100644 index 0000000000000..b655c5ed1789f Binary files /dev/null and b/fonts/FreeSansOblique.otf differ diff --git a/fonts/FreeSerif.otf b/fonts/FreeSerif.otf new file mode 100644 index 0000000000000..38bde26a46b03 Binary files /dev/null and b/fonts/FreeSerif.otf differ diff --git a/fonts/FreeSerifBold.otf b/fonts/FreeSerifBold.otf new file mode 100644 index 0000000000000..84da78c1ef69a Binary files /dev/null and b/fonts/FreeSerifBold.otf differ diff --git a/fonts/FreeSerifBoldItalic.otf b/fonts/FreeSerifBoldItalic.otf new file mode 100644 index 0000000000000..5e5b5c9c333bc Binary files /dev/null and b/fonts/FreeSerifBoldItalic.otf differ diff --git a/fonts/FreeSerifItalic.otf b/fonts/FreeSerifItalic.otf new file mode 100644 index 0000000000000..10c185854ac5f Binary files /dev/null and b/fonts/FreeSerifItalic.otf differ diff --git a/fonts/STIXGeneral.otf b/fonts/STIXGeneral.otf new file mode 100644 index 0000000000000..142b93dd728d9 Binary files /dev/null and b/fonts/STIXGeneral.otf differ diff --git a/fonts/STIXGeneralBol.otf b/fonts/STIXGeneralBol.otf new file mode 100644 index 0000000000000..e1e07176c6e12 Binary files /dev/null and b/fonts/STIXGeneralBol.otf differ diff --git a/fonts/STIXGeneralBolIta.otf b/fonts/STIXGeneralBolIta.otf new file mode 100644 index 0000000000000..9ce342adcaf91 Binary files /dev/null and b/fonts/STIXGeneralBolIta.otf differ diff --git a/fonts/STIXGeneralItalic.otf b/fonts/STIXGeneralItalic.otf new file mode 100644 index 0000000000000..ecf49161edb46 Binary files /dev/null and b/fonts/STIXGeneralItalic.otf differ diff --git a/fonts/STIXSiz1Sym.otf b/fonts/STIXSiz1Sym.otf new file mode 100644 index 0000000000000..1b55399ff072b Binary files /dev/null and b/fonts/STIXSiz1Sym.otf differ diff --git a/fonts/STIXSiz1SymBol.otf b/fonts/STIXSiz1SymBol.otf new file mode 100644 index 0000000000000..fb04b20bb561a Binary files /dev/null and b/fonts/STIXSiz1SymBol.otf differ diff --git a/fonts/STIXSiz2Sym.otf b/fonts/STIXSiz2Sym.otf new file mode 100644 index 0000000000000..72c31ef187d1d Binary files /dev/null and b/fonts/STIXSiz2Sym.otf differ diff --git a/fonts/STIXSiz2SymBol.otf b/fonts/STIXSiz2SymBol.otf new file mode 100644 index 0000000000000..2b041e8be64de Binary files /dev/null and b/fonts/STIXSiz2SymBol.otf differ diff --git a/fonts/STIXSiz3Sym.otf b/fonts/STIXSiz3Sym.otf new file mode 100644 index 0000000000000..f3c8cf3657de2 Binary files /dev/null and b/fonts/STIXSiz3Sym.otf differ diff --git a/fonts/STIXSiz3SymBol.otf b/fonts/STIXSiz3SymBol.otf new file mode 100644 index 0000000000000..5aff6b3eb3bb6 Binary files /dev/null and b/fonts/STIXSiz3SymBol.otf differ diff --git a/fonts/STIXSiz4Sym.otf b/fonts/STIXSiz4Sym.otf new file mode 100644 index 0000000000000..381a071cfd8ec Binary files /dev/null and b/fonts/STIXSiz4Sym.otf differ diff --git a/fonts/STIXSiz4SymBol.otf b/fonts/STIXSiz4SymBol.otf new file mode 100644 index 0000000000000..3be7f64d9c16c Binary files /dev/null and b/fonts/STIXSiz4SymBol.otf differ diff --git a/fonts/STIXSiz5Sym.otf b/fonts/STIXSiz5Sym.otf new file mode 100644 index 0000000000000..d890c625e6f8e Binary files /dev/null and b/fonts/STIXSiz5Sym.otf differ diff --git a/geom/gdml/src/TGDMLParse.cxx b/geom/gdml/src/TGDMLParse.cxx index ad22da3176aa5..3c3a662b3feea 100644 --- a/geom/gdml/src/TGDMLParse.cxx +++ b/geom/gdml/src/TGDMLParse.cxx @@ -19,7 +19,7 @@ TGDMLParse Class -------------------------------------------------------------------- This class contains the implementation of the GDML parser associated to - all the supported GDML elements. User should never need to explicitely + all the supported GDML elements. User should never need to explicitly instaciate this class. It is internally used by the TGeoManager. Each element process has a 'Binding' to ROOT. The 'binding' is specific @@ -480,9 +480,9 @@ XMLNodePointer_t TGDMLParse::PosProcess(TXMLEngine* gdml, XMLNodePointer_t node, retunit = GetScale(lunit); - xline = TString::Format("%s*%s", xpos.Data(), retunit.Data()); - yline = TString::Format("%s*%s", ypos.Data(), retunit.Data()); - zline = TString::Format("%s*%s", zpos.Data(), retunit.Data()); + xline = TString::Format("(%s)*%s", xpos.Data(), retunit.Data()); + yline = TString::Format("(%s)*%s", ypos.Data(), retunit.Data()); + zline = TString::Format("(%s)*%s", zpos.Data(), retunit.Data()); TGeoTranslation* pos = new TGeoTranslation(Evaluate(xline), Evaluate(yline), @@ -541,9 +541,9 @@ XMLNodePointer_t TGDMLParse::RotProcess(TXMLEngine* gdml, XMLNodePointer_t node, retunit = GetScale(aunit); - xline = TString::Format("%s*%s", xpos.Data(), retunit.Data()); - yline = TString::Format("%s*%s", ypos.Data(), retunit.Data()); - zline = TString::Format("%s*%s", zpos.Data(), retunit.Data()); + xline = TString::Format("(%s)*%s", xpos.Data(), retunit.Data()); + yline = TString::Format("(%s)*%s", ypos.Data(), retunit.Data()); + zline = TString::Format("(%s)*%s", zpos.Data(), retunit.Data()); TGeoRotation* rot = new TGeoRotation(); @@ -726,7 +726,7 @@ XMLNodePointer_t TGDMLParse::EleProcess(TXMLEngine* gdml, XMLNodePointer_t node, fracmap[ref.Data()] = n; } child = gdml->GetNext(child); - } // loop on childs + } // loop on children // Create TGeoElement - note: Object(name, title) corresponds to Element(formula, name) TGeoElement *ele = new TGeoElement(NameShort(name), NameShort(name), ncompo); for (fractions f = fracmap.begin(); f != fracmap.end(); f++) { @@ -1284,8 +1284,8 @@ XMLNodePointer_t TGDMLParse::VolProcess(TXMLEngine* gdml, XMLNodePointer_t node) retunit = GetScale(lunit); numberline = TString::Format("%s", number.Data()); - widthline = TString::Format("%s*%s", width.Data(), retunit.Data()); - offsetline = TString::Format("%s*%s", offset.Data(), retunit.Data()); + widthline = TString::Format("(%s)*%s", width.Data(), retunit.Data()); + offsetline = TString::Format("(%s)*%s", offset.Data(), retunit.Data()); fVolID = fVolID + 1; Double_t xlo, xhi; @@ -1645,9 +1645,9 @@ XMLNodePointer_t TGDMLParse::Box(TXMLEngine* gdml, XMLNodePointer_t node, XMLAtt retunit = GetScale(lunit); - xline = TString::Format("%s*%s", xpos.Data(), retunit.Data()); - yline = TString::Format("%s*%s", ypos.Data(), retunit.Data()); - zline = TString::Format("%s*%s", zpos.Data(), retunit.Data()); + xline = TString::Format("(%s)*%s", xpos.Data(), retunit.Data()); + yline = TString::Format("(%s)*%s", ypos.Data(), retunit.Data()); + zline = TString::Format("(%s)*%s", zpos.Data(), retunit.Data()); TGeoBBox* box = new TGeoBBox(NameShort(name), Evaluate(xline) / 2, @@ -1718,9 +1718,9 @@ XMLNodePointer_t TGDMLParse::Ellipsoid(TXMLEngine* gdml, XMLNodePointer_t node, retunit = GetScale(lunit); - axline = TString::Format("%s*%s", ax.Data(), retunit.Data()); - byline = TString::Format("%s*%s", by.Data(), retunit.Data()); - czline = TString::Format("%s*%s", cz.Data(), retunit.Data()); + axline = TString::Format("(%s)*%s", ax.Data(), retunit.Data()); + byline = TString::Format("(%s)*%s", by.Data(), retunit.Data()); + czline = TString::Format("(%s)*%s", cz.Data(), retunit.Data()); Double_t radius = Evaluate(czline); Double_t dx = Evaluate(axline); Double_t dy = Evaluate(byline); @@ -1732,13 +1732,13 @@ XMLNodePointer_t TGDMLParse::Ellipsoid(TXMLEngine* gdml, XMLNodePointer_t node, if (zcut1 == "") { z1 = -radius; } else { - zcut1line = TString::Format("%s*%s", zcut1.Data(), retunit.Data()); + zcut1line = TString::Format("(%s)*%s", zcut1.Data(), retunit.Data()); z1 = Evaluate(zcut1line); } if (zcut2 == "") { z2 = radius; } else { - zcut2line = TString::Format("%s*%s", zcut2.Data(), retunit.Data()); + zcut2line = TString::Format("(%s)*%s", zcut2.Data(), retunit.Data()); z2 = Evaluate(zcut2line); } @@ -1815,8 +1815,8 @@ XMLNodePointer_t TGDMLParse::ElCone(TXMLEngine* gdml, XMLNodePointer_t node, XML //dxline and dyline are without units because they are as a ration dxline = TString::Format("%s", dx.Data()); dyline = TString::Format("%s", dy.Data()); - zmaxline = TString::Format("%s*%s", zmax.Data(), retunit.Data()); - zcutline = TString::Format("%s*%s", zcut.Data(), retunit.Data()); + zmaxline = TString::Format("(%s)*%s", zmax.Data(), retunit.Data()); + zcutline = TString::Format("(%s)*%s", zcut.Data(), retunit.Data()); Double_t dxratio = Evaluate(dxline); Double_t dyratio = Evaluate(dyline); @@ -1893,9 +1893,9 @@ XMLNodePointer_t TGDMLParse::Paraboloid(TXMLEngine* gdml, XMLNodePointer_t node, retunit = GetScale(lunit); - rloline = TString::Format("%s*%s", rlopos.Data(), retunit.Data()); - rhiline = TString::Format("%s*%s", rhipos.Data(), retunit.Data()); - dzline = TString::Format("%s*%s", dzpos.Data(), retunit.Data()); + rloline = TString::Format("(%s)*%s", rlopos.Data(), retunit.Data()); + rhiline = TString::Format("(%s)*%s", rhipos.Data(), retunit.Data()); + dzline = TString::Format("(%s)*%s", dzpos.Data(), retunit.Data()); TGeoParaboloid* paraboloid = new TGeoParaboloid(NameShort(name), Evaluate(rloline), Evaluate(rhiline), @@ -2011,23 +2011,23 @@ XMLNodePointer_t TGDMLParse::Arb8(TXMLEngine* gdml, XMLNodePointer_t node, XMLAt retunit = GetScale(lunit); - v1xline = TString::Format("%s*%s", v1xpos.Data(), retunit.Data()); - v1yline = TString::Format("%s*%s", v1ypos.Data(), retunit.Data()); - v2xline = TString::Format("%s*%s", v2xpos.Data(), retunit.Data()); - v2yline = TString::Format("%s*%s", v2ypos.Data(), retunit.Data()); - v3xline = TString::Format("%s*%s", v3xpos.Data(), retunit.Data()); - v3yline = TString::Format("%s*%s", v3ypos.Data(), retunit.Data()); - v4xline = TString::Format("%s*%s", v4xpos.Data(), retunit.Data()); - v4yline = TString::Format("%s*%s", v4ypos.Data(), retunit.Data()); - v5xline = TString::Format("%s*%s", v5xpos.Data(), retunit.Data()); - v5yline = TString::Format("%s*%s", v5ypos.Data(), retunit.Data()); - v6xline = TString::Format("%s*%s", v6xpos.Data(), retunit.Data()); - v6yline = TString::Format("%s*%s", v6ypos.Data(), retunit.Data()); - v7xline = TString::Format("%s*%s", v7xpos.Data(), retunit.Data()); - v7yline = TString::Format("%s*%s", v7ypos.Data(), retunit.Data()); - v8xline = TString::Format("%s*%s", v8xpos.Data(), retunit.Data()); - v8yline = TString::Format("%s*%s", v8ypos.Data(), retunit.Data()); - dzline = TString::Format("%s*%s", dzpos.Data(), retunit.Data()); + v1xline = TString::Format("(%s)*%s", v1xpos.Data(), retunit.Data()); + v1yline = TString::Format("(%s)*%s", v1ypos.Data(), retunit.Data()); + v2xline = TString::Format("(%s)*%s", v2xpos.Data(), retunit.Data()); + v2yline = TString::Format("(%s)*%s", v2ypos.Data(), retunit.Data()); + v3xline = TString::Format("(%s)*%s", v3xpos.Data(), retunit.Data()); + v3yline = TString::Format("(%s)*%s", v3ypos.Data(), retunit.Data()); + v4xline = TString::Format("(%s)*%s", v4xpos.Data(), retunit.Data()); + v4yline = TString::Format("(%s)*%s", v4ypos.Data(), retunit.Data()); + v5xline = TString::Format("(%s)*%s", v5xpos.Data(), retunit.Data()); + v5yline = TString::Format("(%s)*%s", v5ypos.Data(), retunit.Data()); + v6xline = TString::Format("(%s)*%s", v6xpos.Data(), retunit.Data()); + v6yline = TString::Format("(%s)*%s", v6ypos.Data(), retunit.Data()); + v7xline = TString::Format("(%s)*%s", v7xpos.Data(), retunit.Data()); + v7yline = TString::Format("(%s)*%s", v7ypos.Data(), retunit.Data()); + v8xline = TString::Format("(%s)*%s", v8xpos.Data(), retunit.Data()); + v8yline = TString::Format("(%s)*%s", v8ypos.Data(), retunit.Data()); + dzline = TString::Format("(%s)*%s", dzpos.Data(), retunit.Data()); TGeoArb8* arb8 = new TGeoArb8(NameShort(name), Evaluate(dzline)); @@ -2108,11 +2108,11 @@ XMLNodePointer_t TGDMLParse::Tube(TXMLEngine* gdml, XMLNodePointer_t node, XMLAt retlunit = GetScale(lunit); retaunit = GetScale(aunit); - rminline = TString::Format("%s*%s", rmin.Data(), retlunit.Data()); - rmaxline = TString::Format("%s*%s", rmax.Data(), retlunit.Data()); - zline = TString::Format("%s*%s", z.Data(), retlunit.Data()); - startphiline = TString::Format("%s*%s", startphi.Data(), retaunit.Data()); - deltaphiline = TString::Format("(%s*%s) + %s", deltaphi.Data(), retaunit.Data(), startphiline.Data()); + rminline = TString::Format("(%s)*%s", rmin.Data(), retlunit.Data()); + rmaxline = TString::Format("(%s)*%s", rmax.Data(), retlunit.Data()); + zline = TString::Format("(%s)*%s", z.Data(), retlunit.Data()); + startphiline = TString::Format("(%s)*%s", startphi.Data(), retaunit.Data()); + deltaphiline = TString::Format("((%s)*%s) + %s", deltaphi.Data(), retaunit.Data(), startphiline.Data()); TGeoTubeSeg* tube = new TGeoTubeSeg(NameShort(name), Evaluate(rminline), Evaluate(rmaxline), @@ -2211,17 +2211,17 @@ XMLNodePointer_t TGDMLParse::CutTube(TXMLEngine* gdml, XMLNodePointer_t node, XM retlunit = GetScale(lunit); retaunit = GetScale(aunit); - rminline = TString::Format("%s*%s", rmin.Data(), retlunit.Data()); - rmaxline = TString::Format("%s*%s", rmax.Data(), retlunit.Data()); - zline = TString::Format("%s*%s", z.Data(), retlunit.Data()); - startphiline = TString::Format("%s*%s", startphi.Data(), retaunit.Data()); - deltaphiline = TString::Format("(%s*%s) + %s", deltaphi.Data(), retaunit.Data(), startphiline.Data()); - lowXline = TString::Format("%s*%s", lowX.Data(), retlunit.Data()); - lowYline = TString::Format("%s*%s", lowY.Data(), retlunit.Data()); - lowZline = TString::Format("%s*%s", lowZ.Data(), retlunit.Data()); - highXline = TString::Format("%s*%s", highX.Data(), retlunit.Data()); - highYline = TString::Format("%s*%s", highY.Data(), retlunit.Data()); - highZline = TString::Format("%s*%s", highZ.Data(), retlunit.Data()); + rminline = TString::Format("(%s)*%s", rmin.Data(), retlunit.Data()); + rmaxline = TString::Format("(%s)*%s", rmax.Data(), retlunit.Data()); + zline = TString::Format("(%s)*%s", z.Data(), retlunit.Data()); + startphiline = TString::Format("(%s)*%s", startphi.Data(), retaunit.Data()); + deltaphiline = TString::Format("((%s)*%s) + %s", deltaphi.Data(), retaunit.Data(), startphiline.Data()); + lowXline = TString::Format("(%s)*%s", lowX.Data(), retlunit.Data()); + lowYline = TString::Format("(%s)*%s", lowY.Data(), retlunit.Data()); + lowZline = TString::Format("(%s)*%s", lowZ.Data(), retlunit.Data()); + highXline = TString::Format("(%s)*%s", highX.Data(), retlunit.Data()); + highYline = TString::Format("(%s)*%s", highY.Data(), retlunit.Data()); + highZline = TString::Format("(%s)*%s", highZ.Data(), retlunit.Data()); TGeoCtub* cuttube = new TGeoCtub(NameShort(name), Evaluate(rminline), @@ -2311,13 +2311,13 @@ XMLNodePointer_t TGDMLParse::Cone(TXMLEngine* gdml, XMLNodePointer_t node, XMLAt retlunit = GetScale(lunit); retaunit = GetScale(aunit); - rmin1line = TString::Format("%s*%s", rmin1.Data(), retlunit.Data()); - rmax1line = TString::Format("%s*%s", rmax1.Data(), retlunit.Data()); - rmin2line = TString::Format("%s*%s", rmin2.Data(), retlunit.Data()); - rmax2line = TString::Format("%s*%s", rmax2.Data(), retlunit.Data()); - zline = TString::Format("%s*%s", z.Data(), retlunit.Data()); - startphiline = TString::Format("%s*%s", startphi.Data(), retaunit.Data()); - deltaphiline = TString::Format("%s*%s", deltaphi.Data(), retaunit.Data()); + rmin1line = TString::Format("(%s)*%s", rmin1.Data(), retlunit.Data()); + rmax1line = TString::Format("(%s)*%s", rmax1.Data(), retlunit.Data()); + rmin2line = TString::Format("(%s)*%s", rmin2.Data(), retlunit.Data()); + rmax2line = TString::Format("(%s)*%s", rmax2.Data(), retlunit.Data()); + zline = TString::Format("(%s)*%s", z.Data(), retlunit.Data()); + startphiline = TString::Format("(%s)*%s", startphi.Data(), retaunit.Data()); + deltaphiline = TString::Format("(%s)*%s", deltaphi.Data(), retaunit.Data()); Double_t sphi = Evaluate(startphiline); Double_t ephi = sphi + Evaluate(deltaphiline); @@ -2419,17 +2419,17 @@ XMLNodePointer_t TGDMLParse::Trap(TXMLEngine* gdml, XMLNodePointer_t node, XMLAt retlunit = GetScale(lunit); retaunit = GetScale(aunit); - x1line = TString::Format("%s*%s", x1.Data(), retlunit.Data()); - x2line = TString::Format("%s*%s", x2.Data(), retlunit.Data()); - x3line = TString::Format("%s*%s", x3.Data(), retlunit.Data()); - x4line = TString::Format("%s*%s", x4.Data(), retlunit.Data()); - y1line = TString::Format("%s*%s", y1.Data(), retlunit.Data()); - y2line = TString::Format("%s*%s", y2.Data(), retlunit.Data()); - zline = TString::Format("%s*%s", z.Data(), retlunit.Data()); - philine = TString::Format("%s*%s", phi.Data(), retaunit.Data()); - thetaline = TString::Format("%s*%s", theta.Data(), retaunit.Data()); - alpha1line = TString::Format("%s*%s", alpha1.Data(), retaunit.Data()); - alpha2line = TString::Format("%s*%s", alpha2.Data(), retaunit.Data()); + x1line = TString::Format("(%s)*%s", x1.Data(), retlunit.Data()); + x2line = TString::Format("(%s)*%s", x2.Data(), retlunit.Data()); + x3line = TString::Format("(%s)*%s", x3.Data(), retlunit.Data()); + x4line = TString::Format("(%s)*%s", x4.Data(), retlunit.Data()); + y1line = TString::Format("(%s)*%s", y1.Data(), retlunit.Data()); + y2line = TString::Format("(%s)*%s", y2.Data(), retlunit.Data()); + zline = TString::Format("(%s)*%s", z.Data(), retlunit.Data()); + philine = TString::Format("(%s)*%s", phi.Data(), retaunit.Data()); + thetaline = TString::Format("(%s)*%s", theta.Data(), retaunit.Data()); + alpha1line = TString::Format("(%s)*%s", alpha1.Data(), retaunit.Data()); + alpha2line = TString::Format("(%s)*%s", alpha2.Data(), retaunit.Data()); TGeoTrap* trap = new TGeoTrap(NameShort(name), Evaluate(zline) / 2, Evaluate(thetaline), @@ -2504,11 +2504,11 @@ XMLNodePointer_t TGDMLParse::Trd(TXMLEngine* gdml, XMLNodePointer_t node, XMLAtt retlunit = GetScale(lunit); - x1line = TString::Format("%s*%s", x1.Data(), retlunit.Data()); - x2line = TString::Format("%s*%s", x2.Data(), retlunit.Data()); - y1line = TString::Format("%s*%s", y1.Data(), retlunit.Data()); - y2line = TString::Format("%s*%s", y2.Data(), retlunit.Data()); - zline = TString::Format("%s*%s", z.Data(), retlunit.Data()); + x1line = TString::Format("(%s)*%s", x1.Data(), retlunit.Data()); + x2line = TString::Format("(%s)*%s", x2.Data(), retlunit.Data()); + y1line = TString::Format("(%s)*%s", y1.Data(), retlunit.Data()); + y2line = TString::Format("(%s)*%s", y2.Data(), retlunit.Data()); + zline = TString::Format("(%s)*%s", z.Data(), retlunit.Data()); TGeoTrd2* trd = new TGeoTrd2(NameShort(name), Evaluate(x1line) / 2, @@ -2608,15 +2608,15 @@ XMLNodePointer_t TGDMLParse::Polycone(TXMLEngine* gdml, XMLNodePointer_t node, X if (tempattr == "rmin") { rmin = gdml->GetAttrValue(attr); - rminline = TString::Format("%s*%s", rmin.Data(), retlunit.Data()); + rminline = TString::Format("(%s)*%s", rmin.Data(), retlunit.Data()); table[planeno][0] = Evaluate(rminline); } else if (tempattr == "rmax") { rmax = gdml->GetAttrValue(attr); - rmaxline = TString::Format("%s*%s", rmax.Data(), retlunit.Data()); + rmaxline = TString::Format("(%s)*%s", rmax.Data(), retlunit.Data()); table[planeno][1] = Evaluate(rmaxline); } else if (tempattr == "z") { z = gdml->GetAttrValue(attr); - zline = TString::Format("%s*%s", z.Data(), retlunit.Data()); + zline = TString::Format("(%s)*%s", z.Data(), retlunit.Data()); table[planeno][2] = Evaluate(zline); } attr = gdml->GetNextAttr(attr); @@ -2629,8 +2629,8 @@ XMLNodePointer_t TGDMLParse::Polycone(TXMLEngine* gdml, XMLNodePointer_t node, X TString startphiline = ""; TString deltaphiline = ""; - startphiline = TString::Format("%s*%s", startphi.Data(), retaunit.Data()); - deltaphiline = TString::Format("%s*%s", deltaphi.Data(), retaunit.Data()); + startphiline = TString::Format("(%s)*%s", startphi.Data(), retaunit.Data()); + deltaphiline = TString::Format("(%s)*%s", deltaphi.Data(), retaunit.Data()); TGeoPcon* poly = new TGeoPcon(NameShort(name), Evaluate(startphiline), @@ -2740,15 +2740,15 @@ XMLNodePointer_t TGDMLParse::Polyhedra(TXMLEngine* gdml, XMLNodePointer_t node, if (tempattr == "rmin") { rmin = gdml->GetAttrValue(attr); - rminline = TString::Format("%s*%s", rmin.Data(), retlunit.Data()); + rminline = TString::Format("(%s)*%s", rmin.Data(), retlunit.Data()); table[planeno][0] = Evaluate(rminline); } else if (tempattr == "rmax") { rmax = gdml->GetAttrValue(attr); - rmaxline = TString::Format("%s*%s", rmax.Data(), retlunit.Data()); + rmaxline = TString::Format("(%s)*%s", rmax.Data(), retlunit.Data()); table[planeno][1] = Evaluate(rmaxline); } else if (tempattr == "z") { z = gdml->GetAttrValue(attr); - zline = TString::Format("%s*%s", z.Data(), retlunit.Data()); + zline = TString::Format("(%s)*%s", z.Data(), retlunit.Data()); table[planeno][2] = Evaluate(zline); } @@ -2763,8 +2763,8 @@ XMLNodePointer_t TGDMLParse::Polyhedra(TXMLEngine* gdml, XMLNodePointer_t node, TString deltaphiline = ""; TString numsidesline = ""; - startphiline = TString::Format("%s*%s", startphi.Data(), retaunit.Data()); - deltaphiline = TString::Format("%s*%s", deltaphi.Data(), retaunit.Data()); + startphiline = TString::Format("(%s)*%s", startphi.Data(), retaunit.Data()); + deltaphiline = TString::Format("(%s)*%s", deltaphi.Data(), retaunit.Data()); numsidesline = TString::Format("%s", numsides.Data()); TGeoPgon* polyg = new TGeoPgon(NameShort(name), @@ -2852,12 +2852,12 @@ XMLNodePointer_t TGDMLParse::Sphere(TXMLEngine* gdml, XMLNodePointer_t node, XML retlunit = GetScale(lunit); retaunit = GetScale(aunit); - rminline = TString::Format("%s*%s", rmin.Data(), retlunit.Data()); - rmaxline = TString::Format("%s*%s", rmax.Data(), retlunit.Data()); - startphiline = TString::Format("%s*%s", startphi.Data(), retaunit.Data()); - deltaphiline = TString::Format("(%s*%s) + %s", deltaphi.Data(), retaunit.Data(), startphiline.Data()); - startthetaline = TString::Format("%s*%s", starttheta.Data(), retaunit.Data()); - deltathetaline = TString::Format("(%s*%s) + %s", deltatheta.Data(), retaunit.Data(), startthetaline.Data()); + rminline = TString::Format("(%s)*%s", rmin.Data(), retlunit.Data()); + rmaxline = TString::Format("(%s)*%s", rmax.Data(), retlunit.Data()); + startphiline = TString::Format("(%s)*%s", startphi.Data(), retaunit.Data()); + deltaphiline = TString::Format("((%s)*%s) + %s", deltaphi.Data(), retaunit.Data(), startphiline.Data()); + startthetaline = TString::Format("(%s)*%s", starttheta.Data(), retaunit.Data()); + deltathetaline = TString::Format("((%s)*%s) + %s", deltatheta.Data(), retaunit.Data(), startthetaline.Data()); TGeoSphere* sphere = new TGeoSphere(NameShort(name), Evaluate(rminline), @@ -2933,11 +2933,11 @@ XMLNodePointer_t TGDMLParse::Torus(TXMLEngine* gdml, XMLNodePointer_t node, XMLA retlunit = GetScale(lunit); retaunit = GetScale(aunit); - rminline = TString::Format("%s*%s", rmin.Data(), retlunit.Data()); - rmaxline = TString::Format("%s*%s", rmax.Data(), retlunit.Data()); - rtorline = TString::Format("%s*%s", rtor.Data(), retlunit.Data()); - startphiline = TString::Format("%s*%s", startphi.Data(), retaunit.Data()); - deltaphiline = TString::Format("%s*%s", deltaphi.Data(), retaunit.Data()); + rminline = TString::Format("(%s)*%s", rmin.Data(), retlunit.Data()); + rmaxline = TString::Format("(%s)*%s", rmax.Data(), retlunit.Data()); + rtorline = TString::Format("(%s)*%s", rtor.Data(), retlunit.Data()); + startphiline = TString::Format("(%s)*%s", startphi.Data(), retaunit.Data()); + deltaphiline = TString::Format("(%s)*%s", deltaphi.Data(), retaunit.Data()); TGeoTorus* torus = new TGeoTorus(NameShort(name), Evaluate(rtorline), @@ -3011,11 +3011,11 @@ XMLNodePointer_t TGDMLParse::Hype(TXMLEngine* gdml, XMLNodePointer_t node, XMLAt retlunit = GetScale(lunit); retaunit = GetScale(aunit); - rminline = TString::Format("%s*%s", rmin.Data(), retlunit.Data()); - rmaxline = TString::Format("%s*%s", rmax.Data(), retlunit.Data()); - zline = TString::Format("%s*%s", z.Data(), retlunit.Data()); - instline = TString::Format("%s*%s", inst.Data(), retaunit.Data()); - outstline = TString::Format("%s*%s", outst.Data(), retaunit.Data()); + rminline = TString::Format("(%s)*%s", rmin.Data(), retlunit.Data()); + rmaxline = TString::Format("(%s)*%s", rmax.Data(), retlunit.Data()); + zline = TString::Format("(%s)*%s", z.Data(), retlunit.Data()); + instline = TString::Format("(%s)*%s", inst.Data(), retaunit.Data()); + outstline = TString::Format("(%s)*%s", outst.Data(), retaunit.Data()); TGeoHype* hype = new TGeoHype(NameShort(name), @@ -3095,12 +3095,12 @@ XMLNodePointer_t TGDMLParse::Para(TXMLEngine* gdml, XMLNodePointer_t node, XMLAt retlunit = GetScale(lunit); retaunit = GetScale(aunit); - xline = TString::Format("%s*%s", x.Data(), retlunit.Data()); - yline = TString::Format("%s*%s", y.Data(), retlunit.Data()); - zline = TString::Format("%s*%s", z.Data(), retlunit.Data()); - philine = TString::Format("%s*%s", phi.Data(), retaunit.Data()); - alphaline = TString::Format("%s*%s", alpha.Data(), retaunit.Data()); - thetaline = TString::Format("%s*%s", theta.Data(), retaunit.Data()); + xline = TString::Format("(%s)*%s", x.Data(), retlunit.Data()); + yline = TString::Format("(%s)*%s", y.Data(), retlunit.Data()); + zline = TString::Format("(%s)*%s", z.Data(), retlunit.Data()); + philine = TString::Format("(%s)*%s", phi.Data(), retaunit.Data()); + alphaline = TString::Format("(%s)*%s", alpha.Data(), retaunit.Data()); + thetaline = TString::Format("(%s)*%s", theta.Data(), retaunit.Data()); TGeoPara* para = new TGeoPara(NameShort(name), @@ -3206,18 +3206,18 @@ XMLNodePointer_t TGDMLParse::TwistTrap(TXMLEngine* gdml, XMLNodePointer_t node, retlunit = GetScale(lunit); retaunit = GetScale(aunit); - x1line = TString::Format("%s*%s", x1.Data(), retlunit.Data()); - x2line = TString::Format("%s*%s", x2.Data(), retlunit.Data()); - x3line = TString::Format("%s*%s", x3.Data(), retlunit.Data()); - x4line = TString::Format("%s*%s", x4.Data(), retlunit.Data()); - y1line = TString::Format("%s*%s", y1.Data(), retlunit.Data()); - y2line = TString::Format("%s*%s", y2.Data(), retlunit.Data()); - zline = TString::Format("%s*%s", z.Data(), retlunit.Data()); - philine = TString::Format("%s*%s", phi.Data(), retaunit.Data()); - thetaline = TString::Format("%s*%s", theta.Data(), retaunit.Data()); - alpha1line = TString::Format("%s*%s", alpha1.Data(), retaunit.Data()); - alpha2line = TString::Format("%s*%s", alpha2.Data(), retaunit.Data()); - twistline = TString::Format("%s*%s", twist.Data(), retaunit.Data()); + x1line = TString::Format("(%s)*%s", x1.Data(), retlunit.Data()); + x2line = TString::Format("(%s)*%s", x2.Data(), retlunit.Data()); + x3line = TString::Format("(%s)*%s", x3.Data(), retlunit.Data()); + x4line = TString::Format("(%s)*%s", x4.Data(), retlunit.Data()); + y1line = TString::Format("(%s)*%s", y1.Data(), retlunit.Data()); + y2line = TString::Format("(%s)*%s", y2.Data(), retlunit.Data()); + zline = TString::Format("(%s)*%s", z.Data(), retlunit.Data()); + philine = TString::Format("(%s)*%s", phi.Data(), retaunit.Data()); + thetaline = TString::Format("(%s)*%s", theta.Data(), retaunit.Data()); + alpha1line = TString::Format("(%s)*%s", alpha1.Data(), retaunit.Data()); + alpha2line = TString::Format("(%s)*%s", alpha2.Data(), retaunit.Data()); + twistline = TString::Format("(%s)*%s", twist.Data(), retaunit.Data()); TGeoGtra* twtrap = new TGeoGtra(NameShort(name), Evaluate(zline) / 2, @@ -3287,9 +3287,9 @@ XMLNodePointer_t TGDMLParse::ElTube(TXMLEngine* gdml, XMLNodePointer_t node, XML retunit = GetScale(lunit); - xline = TString::Format("%s*%s", xpos.Data(), retunit.Data()); - yline = TString::Format("%s*%s", ypos.Data(), retunit.Data()); - zline = TString::Format("%s*%s", zpos.Data(), retunit.Data()); + xline = TString::Format("(%s)*%s", xpos.Data(), retunit.Data()); + yline = TString::Format("(%s)*%s", ypos.Data(), retunit.Data()); + zline = TString::Format("(%s)*%s", zpos.Data(), retunit.Data()); TGeoEltu* eltu = new TGeoEltu(NameShort(name), Evaluate(xline), Evaluate(yline), @@ -3339,7 +3339,7 @@ XMLNodePointer_t TGDMLParse::Orb(TXMLEngine* gdml, XMLNodePointer_t node, XMLAtt retunit = GetScale(lunit); - rline = TString::Format("%s*%s", r.Data(), retunit.Data()); + rline = TString::Format("(%s)*%s", r.Data(), retunit.Data()); TGeoSphere* orb = new TGeoSphere(NameShort(name), 0, Evaluate(rline), 0, 180, 0, 360); @@ -3441,11 +3441,11 @@ XMLNodePointer_t TGDMLParse::Xtru(TXMLEngine* gdml, XMLNodePointer_t node, XMLAt if (tempattr == "x") { x = gdml->GetAttrValue(attr); - xline = TString::Format("%s*%s", x.Data(), retlunit.Data()); + xline = TString::Format("(%s)*%s", x.Data(), retlunit.Data()); vertx[vert] = Evaluate(xline); } else if (tempattr == "y") { y = gdml->GetAttrValue(attr); - yline = TString::Format("%s*%s", y.Data(), retlunit.Data()); + yline = TString::Format("(%s)*%s", y.Data(), retlunit.Data()); verty[vert] = Evaluate(yline); } @@ -3471,15 +3471,15 @@ XMLNodePointer_t TGDMLParse::Xtru(TXMLEngine* gdml, XMLNodePointer_t node, XMLAt section[sect][0] = Evaluate(zorder); } else if (tempattr == "zPosition") { zpos = gdml->GetAttrValue(attr); - zposline = TString::Format("%s*%s", zpos.Data(), retlunit.Data()); + zposline = TString::Format("(%s)*%s", zpos.Data(), retlunit.Data()); section[sect][1] = Evaluate(zposline); } else if (tempattr == "xOffset") { xoff = gdml->GetAttrValue(attr); - xoffline = TString::Format("%s*%s", xoff.Data(), retlunit.Data()); + xoffline = TString::Format("(%s)*%s", xoff.Data(), retlunit.Data()); section[sect][2] = Evaluate(xoffline); } else if (tempattr == "yOffset") { yoff = gdml->GetAttrValue(attr); - yoffline = TString::Format("%s*%s", yoff.Data(), retlunit.Data()); + yoffline = TString::Format("(%s)*%s", yoff.Data(), retlunit.Data()); section[sect][3] = Evaluate(yoffline); } else if (tempattr == "scalingFactor") { scale = gdml->GetAttrValue(attr); diff --git a/geom/gdml/src/TGDMLWrite.cxx b/geom/gdml/src/TGDMLWrite.cxx index 16f774dbeb324..15afb29d84118 100644 --- a/geom/gdml/src/TGDMLWrite.cxx +++ b/geom/gdml/src/TGDMLWrite.cxx @@ -99,7 +99,7 @@ // USAGE: // // gGeoManager->Export("output.gdml"); // // gGeoManager->Export("output.gdml","","vg"); //the same as previous just // -// //options are set explicitely // +// //options are set explicitly // // gGeoManager->Export("output.gdml","","vgf"); // // gGeoManager->Export("output.gdml","","gn"); // // gGeoManager->Export("output.gdml","","f"); // diff --git a/geom/geom/CMakeLists.txt b/geom/geom/CMakeLists.txt index 9765be23dfd48..038272342d7e8 100644 --- a/geom/geom/CMakeLists.txt +++ b/geom/geom/CMakeLists.txt @@ -21,7 +21,8 @@ set(headers1 TGeoAtt.h TGeoStateInfo.h TGeoBoolNode.h TGeoHelix.h TGeoParaboloid.h TGeoElement.h TGeoHalfSpace.h TGeoBuilder.h TGeoNavigator.h) set(headers2 TGeoPatternFinder.h TGeoCache.h TVirtualMagField.h - TGeoUniformMagField.h TGeoGlobalMagField.h TGeoBranchArray.h) + TGeoUniformMagField.h TGeoGlobalMagField.h TGeoBranchArray.h + TGeoExtension.h) ROOT_GENERATE_DICTIONARY(G__${libname}1 ${headers1} LINKDEF LinkDef1.h) diff --git a/geom/geom/Module.mk b/geom/geom/Module.mk index 5213ed43069e3..b3396f7bde092 100644 --- a/geom/geom/Module.mk +++ b/geom/geom/Module.mk @@ -36,10 +36,13 @@ GEOMH1 := TGeoAtt.h TGeoStateInfo.h TGeoBoolNode.h \ TGeoHelix.h TGeoParaboloid.h TGeoElement.h TGeoHalfSpace.h \ TGeoBuilder.h TGeoNavigator.h GEOMH2 := TGeoPatternFinder.h TGeoCache.h TVirtualMagField.h \ - TGeoUniformMagField.h TGeoGlobalMagField.h TGeoBranchArray.h + TGeoUniformMagField.h TGeoGlobalMagField.h TGeoBranchArray.h \ + TGeoExtension.h +GEOMH3 := TGeoRCPtr.h GEOMH1 := $(patsubst %,$(MODDIRI)/%,$(GEOMH1)) GEOMH2 := $(patsubst %,$(MODDIRI)/%,$(GEOMH2)) -GEOMH := $(GEOMH1) $(GEOMH2) +GEOMH3 := $(patsubst %,$(MODDIRI)/%,$(GEOMH3)) +GEOMH := $(GEOMH1) $(GEOMH2) $(GEOMH3) GEOMS := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx)) GEOMO := $(call stripsrc,$(GEOMS:.cxx=.o)) diff --git a/geom/geom/inc/LinkDef1.h b/geom/geom/inc/LinkDef1.h index a451c9d900705..e8800d174f1bd 100644 --- a/geom/geom/inc/LinkDef1.h +++ b/geom/geom/inc/LinkDef1.h @@ -57,7 +57,7 @@ #pragma link C++ class TGeoCone+; #pragma link C++ class TGeoConeSeg+; #pragma link C++ class TGeoParaboloid+; -#pragma link C++ class TGeoPcon+; +#pragma link C++ class TGeoPcon-; #pragma link C++ class TGeoPgon+; #pragma link C++ class TGeoArb8-; #pragma link C++ class TGeoTrap+; @@ -85,5 +85,7 @@ #pragma link C++ class TGeoBuilder; #pragma link C++ class TGeoNavigator+; #pragma link C++ class TGeoNavigatorArray; +#pragma link C++ struct std::map; +#pragma link C++ struct std::pair; #endif diff --git a/geom/geom/inc/LinkDef2.h b/geom/geom/inc/LinkDef2.h index e8886ed80edcc..6210846147567 100644 --- a/geom/geom/inc/LinkDef2.h +++ b/geom/geom/inc/LinkDef2.h @@ -34,5 +34,7 @@ #pragma link C++ class TGeoUniformMagField+; #pragma link C++ class TGeoGlobalMagField; #pragma link C++ class TGeoBranchArray+; +#pragma link C++ class TGeoExtension+; +#pragma link C++ class TGeoRCExtension+; #endif diff --git a/geom/geom/inc/TGeoArb8.h b/geom/geom/inc/TGeoArb8.h index e87deb10cee24..0ed751d711e60 100644 --- a/geom/geom/inc/TGeoArb8.h +++ b/geom/geom/inc/TGeoArb8.h @@ -68,20 +68,24 @@ class TGeoArb8 : public TGeoBBox // methods virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); void ComputeTwist(); - virtual Bool_t Contains(Double_t *point) const; - Double_t DistToPlane(Double_t *point, Double_t *dir, Int_t ipl, Bool_t in) const; - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; + Double_t DistToPlane(const Double_t *point, const Double_t *dir, Int_t ipl, Bool_t in) const; + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual Double_t GetAxisRange(Int_t iaxis, Double_t &xlo, Double_t &xhi) const; virtual void GetBoundingCylinder(Double_t *param) const; virtual Int_t GetByteCount() const {return 100;} - Double_t GetClosestEdge(Double_t *point, Double_t *vert, Int_t &isegment) const; + Double_t GetClosestEdge(const Double_t *point, Double_t *vert, Int_t &isegment) const; virtual Bool_t GetPointsOnFacet(Int_t /*index*/, Int_t /*npoints*/, Double_t * /*array*/) const; Double_t GetDz() const {return fDz;} virtual Int_t GetFittingBox(const TGeoBBox *parambox, TGeoMatrix *mat, Double_t &dx, Double_t &dy, Double_t &dz) const; @@ -90,13 +94,14 @@ class TGeoArb8 : public TGeoBBox Double_t *GetVertices() {return &fXY[0][0];} Double_t GetTwist(Int_t iseg) const; virtual Bool_t IsCylType() const {return kFALSE;} - static Bool_t IsSamePoint(Double_t *p1, Double_t *p2) {return (TMath::Abs(p1[0]-p2[0])<1.E-16 && TMath::Abs(p1[1]-p2[1])<1.E-16)?kTRUE:kFALSE;} + static Bool_t IsSamePoint(const Double_t *p1, const Double_t *p2) {return (TMath::Abs(p1[0]-p2[0])<1.E-16 && TMath::Abs(p1[1]-p2[1])<1.E-16)?kTRUE:kFALSE;} static Bool_t InsidePolygon(Double_t x, Double_t y, Double_t *pts); virtual void InspectShape() const; Bool_t IsTwisted() const {return (fTwist==0)?kFALSE:kTRUE;} - Double_t SafetyToFace(Double_t *point, Int_t iseg, Bool_t in) const; - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + Double_t SafetyToFace(const Double_t *point, Int_t iseg, Bool_t in) const; + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetPlaneVertices(Double_t zpl, Double_t *vertices) const; virtual void SetVertex(Int_t vnum, Double_t x, Double_t y); virtual void SetDimensions(Double_t *param); @@ -150,10 +155,12 @@ class TGeoTrap : public TGeoArb8 Double_t tl2, Double_t alpha2); // destructor virtual ~TGeoTrap(); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); Double_t GetTheta() const {return fTheta;} @@ -168,8 +175,9 @@ class TGeoTrap : public TGeoArb8 Double_t GetAlpha2() const {return fAlpha2;} virtual TGeoShape *GetMakeRuntimeShape(TGeoShape *mother, TGeoMatrix *mat) const; virtual void SetDimensions(Double_t *param); - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); ClassDef(TGeoTrap, 1) // G3 TRAP shape }; @@ -205,15 +213,18 @@ class TGeoGtra : public TGeoTrap Double_t tl2, Double_t alpha2); // destructor virtual ~TGeoGtra(); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoShape *GetMakeRuntimeShape(TGeoShape *mother, TGeoMatrix *mat) const; Double_t GetTwistAngle() const {return fTwistAngle;} - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; virtual void SetDimensions(Double_t *param); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); ClassDef(TGeoGtra, 1) // G3 GTRA shape }; diff --git a/geom/geom/inc/TGeoBBox.h b/geom/geom/inc/TGeoBBox.h index 4e57ed6d4a10a..ec20e532ad2c8 100644 --- a/geom/geom/inc/TGeoBBox.h +++ b/geom/geom/inc/TGeoBBox.h @@ -48,17 +48,21 @@ protected : static Bool_t AreOverlapping(const TGeoBBox *box1, const TGeoMatrix *mat1, const TGeoBBox *box2, const TGeoMatrix *mat2); virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; static Bool_t Contains(const Double_t *point, Double_t dx, Double_t dy, Double_t dz, const Double_t *origin); - virtual Bool_t CouldBeCrossed(Double_t *point, Double_t *dir) const; + virtual Bool_t CouldBeCrossed(const Double_t *point, const Double_t *dir) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; static Double_t DistFromInside(const Double_t *point,const Double_t *dir, Double_t dx, Double_t dy, Double_t dz, const Double_t *origin, Double_t stepmax=TGeoShape::Big()); - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; static Double_t DistFromOutside(const Double_t *point,const Double_t *dir, Double_t dx, Double_t dy, Double_t dz, const Double_t *origin, Double_t stepmax=TGeoShape::Big()); virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, @@ -84,8 +88,9 @@ protected : virtual Bool_t IsValidBox() const {return ((fDX<0)||(fDY<0)||(fDZ<0))?kFALSE:kTRUE;} virtual Bool_t IsNullBox() const {return ((fDX<1.E-16)&&(fDY<1.E-16)&&(fDZ<1.E-16))?kTRUE:kFALSE;} virtual TBuffer3D *MakeBuffer3D() const; - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetBoxDimensions(Double_t dx, Double_t dy, Double_t dz, Double_t *origin=0); virtual void SetDimensions(Double_t *param); void SetBoxPoints(Double_t *points) const; diff --git a/geom/geom/inc/TGeoBoolNode.h b/geom/geom/inc/TGeoBoolNode.h index ca5f1d56b8ff9..e4e40d7a99c77 100644 --- a/geom/geom/inc/TGeoBoolNode.h +++ b/geom/geom/inc/TGeoBoolNode.h @@ -74,12 +74,12 @@ enum EGeoBoolType { virtual ~TGeoBoolNode(); // methods virtual void ComputeBBox(Double_t &dx, Double_t &dy, Double_t &dz, Double_t *origin) = 0; - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) = 0; - virtual Bool_t Contains(Double_t *point) const = 0; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm) = 0; + virtual Bool_t Contains(const Double_t *point) const = 0; virtual Int_t DistanceToPrimitive(Int_t px, Int_t py) = 0; - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=0, Double_t *safe=0) const = 0; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=0, Double_t *safe=0) const = 0; virtual EGeoBoolType GetBooleanOperator() const = 0; virtual Int_t GetNpoints() = 0; @@ -87,10 +87,12 @@ enum EGeoBoolType { TGeoMatrix *GetRightMatrix() const {return fRightMat;} TGeoShape *GetLeftShape() const {return fLeft;} TGeoShape *GetRightShape() const {return fRight;} + virtual TGeoBoolNode *MakeClone() const = 0; virtual void Paint(Option_t *option); void RegisterMatrices(); - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const = 0; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + Bool_t ReplaceMatrix(TGeoMatrix *mat, TGeoMatrix *newmat); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const = 0; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void SetPoints(Double_t *points) const; virtual void SetPoints(Float_t *points) const; void SetSelected(Int_t sel); @@ -117,20 +119,21 @@ class TGeoUnion : public TGeoBoolNode virtual ~TGeoUnion(); // methods virtual void ComputeBBox(Double_t &dx, Double_t &dy, Double_t &dz, Double_t *origin); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual Bool_t Contains(const Double_t *point) const; virtual Int_t DistanceToPrimitive(Int_t px, Int_t py); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=0, Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=0, Double_t *safe=0) const; virtual EGeoBoolType GetBooleanOperator() const {return kGeoUnion;} virtual Int_t GetNpoints(); - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void Sizeof3D() const; //CS specific + virtual TGeoBoolNode *MakeClone() const; virtual void Paint(Option_t *option); ClassDef(TGeoUnion, 1) // union node @@ -155,20 +158,21 @@ class TGeoIntersection : public TGeoBoolNode virtual ~TGeoIntersection(); // methods virtual void ComputeBBox(Double_t &dx, Double_t &dy, Double_t &dz, Double_t *origin); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual Bool_t Contains(const Double_t *point) const; virtual Int_t DistanceToPrimitive(Int_t px, Int_t py); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=0, Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=0, Double_t *safe=0) const; virtual EGeoBoolType GetBooleanOperator() const {return kGeoIntersection;} virtual Int_t GetNpoints(); - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void Sizeof3D() const; //CS specific + virtual TGeoBoolNode *MakeClone() const; virtual void Paint(Option_t *option); ClassDef(TGeoIntersection, 1) // intersection node @@ -192,20 +196,21 @@ class TGeoSubtraction : public TGeoBoolNode virtual ~TGeoSubtraction(); // methods virtual void ComputeBBox(Double_t &dx, Double_t &dy, Double_t &dz, Double_t *origin); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual Bool_t Contains(const Double_t *point) const; virtual Int_t DistanceToPrimitive(Int_t px, Int_t py); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=0, Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=0, Double_t *safe=0) const; virtual EGeoBoolType GetBooleanOperator() const {return kGeoSubtraction;} virtual Int_t GetNpoints(); - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void Sizeof3D() const; //CS specific + virtual TGeoBoolNode *MakeClone() const; virtual void Paint(Option_t *option); ClassDef(TGeoSubtraction, 1) // subtraction node diff --git a/geom/geom/inc/TGeoBranchArray.h b/geom/geom/inc/TGeoBranchArray.h index 0d2ba77bcc526..6f6af4baba40d 100644 --- a/geom/geom/inc/TGeoBranchArray.h +++ b/geom/geom/inc/TGeoBranchArray.h @@ -24,6 +24,7 @@ //////////////////////////////////////////////////////////////////////////// class TGeoHMatrix; +class TGeoMatrix; class TGeoNavigator; class TGeoNode; @@ -37,7 +38,7 @@ class TGeoBranchArray : public TObject TObject *fClient; // Client object to notify public: - TGeoBranchArray() : TObject(), fLevel(0), fMaxLevel(10), fArray(NULL), fMatrix(NULL), fClient(NULL) {} + TGeoBranchArray() : TObject(), fLevel(-1), fMaxLevel(10), fArray(NULL), fMatrix(NULL), fClient(NULL) {} TGeoBranchArray(Int_t level); virtual ~TGeoBranchArray(); @@ -60,8 +61,10 @@ class TGeoBranchArray : public TObject TGeoNode *GetNode(Int_t level) const {return fArray[level];} TGeoNode *GetCurrentNode() const {return fArray[fLevel];} void GetPath(TString &path) const; + void Init(TGeoNode **branch, TGeoMatrix *global, Int_t level); void InitFromNavigator(TGeoNavigator *nav); virtual Bool_t IsSortable() const {return kTRUE;} + Bool_t IsOutside() const {return (fLevel<0)?kTRUE:kFALSE;} virtual Bool_t Notify() {return (fClient)?fClient->Notify():kFALSE;} virtual void Print(Option_t *option="") const; void SetClient(TObject *client) {fClient = client;} diff --git a/geom/geom/inc/TGeoCompositeShape.h b/geom/geom/inc/TGeoCompositeShape.h index 86db1c9db07d3..825af8a2459f0 100644 --- a/geom/geom/inc/TGeoCompositeShape.h +++ b/geom/geom/inc/TGeoCompositeShape.h @@ -51,13 +51,17 @@ private : virtual void ClearThreadData() const; virtual void CreateThreadData(Int_t nthreads); virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); TGeoBoolNode *GetBoolNode() const {return fNode;} @@ -72,8 +76,9 @@ private : void MakeNode(const char *expression); virtual Bool_t PaintComposite(Option_t *option = "") const; void RegisterYourself(); - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void SetDimensions(Double_t * /*param*/) {;} virtual void SetPoints(Double_t *points) const; virtual void SetPoints(Float_t *points) const; diff --git a/geom/geom/inc/TGeoCone.h b/geom/geom/inc/TGeoCone.h index 37829e35d6cc4..1ae7980a7a462 100644 --- a/geom/geom/inc/TGeoCone.h +++ b/geom/geom/inc/TGeoCone.h @@ -53,20 +53,24 @@ protected : virtual Double_t Capacity() const; static Double_t Capacity(Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2); virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - static void ComputeNormalS(Double_t *point, Double_t *dir, Double_t *norm, + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + static void ComputeNormalS(const Double_t *point, const Double_t *dir, Double_t *norm, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2); - virtual Bool_t Contains(Double_t *point) const; + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); - static void DistToCone(Double_t *point, Double_t *dir, Double_t dz, Double_t r1, Double_t r2, Double_t &b, Double_t &delta); - static Double_t DistFromInsideS(Double_t *point, Double_t *dir, Double_t dz, + static void DistToCone(const Double_t *point, const Double_t *dir, Double_t dz, Double_t r1, Double_t r2, Double_t &b, Double_t &delta); + static Double_t DistFromInsideS(const Double_t *point, const Double_t *dir, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - static Double_t DistFromOutsideS(Double_t *point, Double_t *dir, Double_t dz, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + static Double_t DistFromOutsideS(const Double_t *point, const Double_t *dir, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2); - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); @@ -88,10 +92,11 @@ protected : virtual void InspectShape() const; virtual Bool_t IsCylType() const {return kTRUE;} virtual TBuffer3D *MakeBuffer3D() const; - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - static Double_t SafetyS(Double_t *point, Bool_t in, Double_t dz, Double_t rmin1, Double_t rmax1, + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + static Double_t SafetyS(const Double_t *point, Bool_t in, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, Int_t skipz=0); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetConeDimensions(Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2); virtual void SetDimensions(Double_t *param); @@ -119,6 +124,16 @@ class TGeoConeSeg : public TGeoCone // data members Double_t fPhi1; // first phi limit Double_t fPhi2; // second phi limit + // Transient trigonometric data + Double_t fS1; //!sin(phi1) + Double_t fC1; //!cos(phi1) + Double_t fS2; //!sin(phi2) + Double_t fC2; //!cos(phi2) + Double_t fSm; //!sin(0.5*(phi1+phi2)) + Double_t fCm; //!cos(0.5*(phi1+phi2)) + Double_t fCdfi; //!cos(0.5*(phi1-phi2)) + + void InitTrigonometry(); public: // constructors @@ -131,26 +146,30 @@ class TGeoConeSeg : public TGeoCone // destructor virtual ~TGeoConeSeg(); // methods + virtual void AfterStreamer(); virtual Double_t Capacity() const; static Double_t Capacity(Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, Double_t phi1, Double_t phi2); virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - static void ComputeNormalS(Double_t *point, Double_t *dir, Double_t *norm, + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + static void ComputeNormalS(const Double_t *point, const Double_t *dir, Double_t *norm, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, Double_t c1, Double_t s1, Double_t c2, Double_t s2); - virtual Bool_t Contains(Double_t *point) const; - + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); - static Double_t DistToCons(Double_t *point, Double_t *dir, Double_t r1, Double_t z1, Double_t r2, Double_t z2, Double_t phi1, Double_t phi2); - static Double_t DistFromInsideS(Double_t *point, Double_t *dir, Double_t dz, Double_t rmin1, Double_t rmax1, + static Double_t DistToCons(const Double_t *point, const Double_t *dir, Double_t r1, Double_t z1, Double_t r2, Double_t z2, Double_t phi1, Double_t phi2); + static Double_t DistFromInsideS(const Double_t *point, const Double_t *dir, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, Double_t c1, Double_t s1, Double_t c2, Double_t s2, Double_t cm, Double_t sm, Double_t cdfi); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - static Double_t DistFromOutsideS(Double_t *point, Double_t *dir, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + static Double_t DistFromOutsideS(const Double_t *point, const Double_t *dir, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, Double_t c1, Double_t s1, Double_t c2, Double_t s2, Double_t cm, Double_t sm, Double_t cdfi); - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual Double_t GetAxisRange(Int_t iaxis, Double_t &xlo, Double_t &xhi) const; @@ -165,10 +184,11 @@ class TGeoConeSeg : public TGeoCone Double_t GetPhi2() const {return fPhi2;} virtual void InspectShape() const; virtual TBuffer3D *MakeBuffer3D() const; - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - static Double_t SafetyS(Double_t *point, Bool_t in, Double_t dz, Double_t rmin1, Double_t rmax1, + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + static Double_t SafetyS(const Double_t *point, Bool_t in, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, Double_t phi1, Double_t phi2, Int_t skipz=0); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetConsDimensions(Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, Double_t phi1, Double_t phi2); virtual void SetDimensions(Double_t *param); diff --git a/geom/geom/inc/TGeoElement.h b/geom/geom/inc/TGeoElement.h index d9b4afd1120c3..ea9d9358a9801 100644 --- a/geom/geom/inc/TGeoElement.h +++ b/geom/geom/inc/TGeoElement.h @@ -200,7 +200,7 @@ class TGeoElementRN : public TGeoElement void FillPopulation(TObjArray *population, Double_t precision=0.001, Double_t factor=1.); virtual void Print(Option_t *option = "") const; static TGeoElementRN *ReadElementRN(const char *record, Int_t &ndecays); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); ClassDef(TGeoElementRN, 2) // radionuclides class }; @@ -264,7 +264,7 @@ class TGeoDecayChannel : public TObject // Services virtual void Print(Option_t *opt = " ") const; static TGeoDecayChannel *ReadDecay(const char *record); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void DecayShift(Int_t &dA, Int_t &dZ, Int_t &dI) const ; ClassDef(TGeoDecayChannel,1) // Decay channel for Elements diff --git a/geom/geom/inc/TGeoEltu.h b/geom/geom/inc/TGeoEltu.h index 9f0da73400668..ad2efa8132a4b 100644 --- a/geom/geom/inc/TGeoEltu.h +++ b/geom/geom/inc/TGeoEltu.h @@ -38,13 +38,17 @@ class TGeoEltu : public TGeoTube // methods virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual Double_t GetA() const {return fRmin;} @@ -57,8 +61,9 @@ class TGeoEltu : public TGeoTube virtual Bool_t GetPointsOnSegments(Int_t /*npoints*/, Double_t * /*array*/) const {return kFALSE;} virtual void InspectShape() const; virtual Bool_t IsCylType() const {return kTRUE;} - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetEltuDimensions(Double_t a, Double_t b, Double_t dz); virtual void SetDimensions(Double_t *param); virtual void SetPoints(Double_t *points) const; diff --git a/geom/geom/inc/TGeoExtension.h b/geom/geom/inc/TGeoExtension.h new file mode 100644 index 0000000000000..e68d572d5827a --- /dev/null +++ b/geom/geom/inc/TGeoExtension.h @@ -0,0 +1,81 @@ +/************************************************************************* + * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +// Author: Andrei.Gheata@cern.ch 29/05/2013 +// Following proposal by Markus Frank + +#ifndef ROOT_TGeoExtension +#define ROOT_TGeoExtension + +#include + +#ifndef ROOT_TObject +#include "TObject.h" +#endif + +//______________________________________________________________________________ +// TGeoExtension - ABC for user objects attached to TGeoVolume or TGeoNode. +// Provides interface for getting a reference (grab) and +// releasing the extension object (release), allowing for +// derived classes to implement reference counted sharing. +// The user who should attach extensions to logical volumes +// or nodes BEFORE applying misalignment information so that +// these will be available to all copies. +//______________________________________________________________________________ + +class TGeoExtension : public TObject +{ +protected: + TGeoExtension() : TObject() {} + virtual ~TGeoExtension() {} + +public: + // Method called whenever requiring a pointer to the extension + // Equivalent to new() + virtual TGeoExtension *Grab() = 0; + // Method called always when the pointer to the extension is not needed + // Equivalent to delete() + virtual void Release() const = 0; + + ClassDef(TGeoExtension, 1) // User extension for volumes and nodes +}; + + +//______________________________________________________________________________ +// TGeoRCExtension - Reference counted extension which has a pointer to and +// owns a user defined TObject. This class can be used as +// model for a reference counted derivation from TGeoExtension. +// The user object becomes owned by the extension. +//______________________________________________________________________________ + +class TGeoRCExtension : public TGeoExtension +{ +protected: + virtual ~TGeoRCExtension() {delete fUserObject;} +public: + TGeoRCExtension() : TGeoExtension(), fRC(0), fUserObject(0) {fRC++;} + TGeoRCExtension(TObject *obj) : TGeoExtension(), fRC(0), fUserObject(obj) {fRC++;} + + TGeoExtension *Grab() {fRC++; return this;} + void Release() const {assert(fRC > 0); fRC--; if (fRC ==0) delete this;} + + void SetUserObject(TObject *obj) {fUserObject = obj;} + TObject *GetUserObject() const {return fUserObject;} + + +private: + // Copy constructor and assignment not allowed + TGeoRCExtension(const TGeoRCExtension &); // Not implemented + TGeoRCExtension &operator =(const TGeoRCExtension &); // Not implemented + mutable Int_t fRC; // Reference counter + TObject *fUserObject; // Attached user object + + ClassDef(TGeoRCExtension, 1) // Reference counted extension for volumes and nodes +}; + +#endif diff --git a/geom/geom/inc/TGeoHalfSpace.h b/geom/geom/inc/TGeoHalfSpace.h index c3f05d703d420..a615de422e20a 100644 --- a/geom/geom/inc/TGeoHalfSpace.h +++ b/geom/geom/inc/TGeoHalfSpace.h @@ -42,13 +42,17 @@ class TGeoHalfSpace : public TGeoBBox // methods virtual Double_t Capacity() const {return 0.;} virtual void ComputeBBox() {;} - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual Double_t *GetPoint() {return fP;} @@ -59,8 +63,9 @@ class TGeoHalfSpace : public TGeoBBox virtual Int_t GetNmeshVertices() const {return 0;} virtual void InspectShape() const; virtual Bool_t IsCylType() const {return kFALSE;} - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void SetDimensions(Double_t *param); virtual void SetPoints(Double_t * /*points*/) const {;} virtual void SetPoints(Float_t * /*points*/) const {;} diff --git a/geom/geom/inc/TGeoHype.h b/geom/geom/inc/TGeoHype.h index 79ee50757c527..5f3b311ddbf47 100644 --- a/geom/geom/inc/TGeoHype.h +++ b/geom/geom/inc/TGeoHype.h @@ -73,13 +73,17 @@ private : virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - Int_t DistToHype(Double_t *point, Double_t *dir, Double_t *s, Bool_t inner, Bool_t in) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + Int_t DistToHype(const Double_t *point, const Double_t *dir, Double_t *s, Bool_t inner, Bool_t in) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); @@ -100,9 +104,10 @@ private : virtual Bool_t IsCylType() const {return kTRUE;} virtual TBuffer3D *MakeBuffer3D() const; //virtual void Paint(Option_t *option); - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - Double_t SafetyToHype(Double_t *point, Bool_t inner, Bool_t in) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + Double_t SafetyToHype(const Double_t *point, Bool_t inner, Bool_t in) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetHypeDimensions(Double_t rin, Double_t stin, Double_t rout, Double_t stout, Double_t dz); virtual void SetDimensions(Double_t *param); virtual void SetPoints(Double_t *points) const; diff --git a/geom/geom/inc/TGeoManager.h b/geom/geom/inc/TGeoManager.h index c32eda5f18698..58b5080c07b8c 100644 --- a/geom/geom/inc/TGeoManager.h +++ b/geom/geom/inc/TGeoManager.h @@ -76,6 +76,7 @@ private : Bool_t fLoopVolumes; //! flag volume lists loop Bool_t fStreamVoxels; // flag to allow voxelization I/O Bool_t fIsGeomReading; //! flag set when reading geometry + Bool_t fIsGeomCleaning; //! flag to notify that the manager is being destructed Bool_t fPhiCut; // flag for phi cuts Bool_t fTimeCut; // time cut for tracks Bool_t fDrawExtra; //! flag that the list of physical nodes has to be drawn @@ -239,7 +240,7 @@ private : void DrawPath(const char *path); void PrintOverlaps() const; // *MENU* void RandomPoints(const TGeoVolume *vol, Int_t npoints=10000, Option_t *option=""); - void RandomRays(Int_t nrays=1000, Double_t startx=0, Double_t starty=0, Double_t startz=0); + void RandomRays(Int_t nrays=1000, Double_t startx=0, Double_t starty=0, Double_t startz=0, const char *target_vol=0, Bool_t check_norm=kFALSE); TGeoNode *SamplePoints(Int_t npoints, Double_t &dist, Double_t epsil=1E-5, const char *g3path=""); void SetNmeshPoints(Int_t npoints=1000); @@ -450,6 +451,7 @@ private : static TGeoManager *Import(const char *filename, const char *name="", Option_t *option=""); static Bool_t IsLocked(); Bool_t IsStreamingVoxels() const {return fStreamVoxels;} + Bool_t IsCleaning() const {return fIsGeomCleaning;} //--- list getters TObjArray *GetListOfNodes() {return fNodes;} diff --git a/geom/geom/inc/TGeoMaterial.h b/geom/geom/inc/TGeoMaterial.h index b7ca18e196642..a00827457cc36 100644 --- a/geom/geom/inc/TGeoMaterial.h +++ b/geom/geom/inc/TGeoMaterial.h @@ -33,7 +33,7 @@ // forward declarations - +class TGeoExtension; //////////////////////////////////////////////////////////////////////////// // // @@ -73,6 +73,8 @@ class TGeoMaterial : public TNamed, TObject *fShader; // shader with optical properties TObject *fCerenkov; // pointer to class with Cerenkov properties TGeoElement *fElement; // pointer to element composing the material + TGeoExtension *fUserExtension; //! Transient user-defined extension to materials + TGeoExtension *fFWExtension; //! Transient framework-defined extension to materials // methods TGeoMaterial(const TGeoMaterial&); @@ -116,11 +118,15 @@ class TGeoMaterial : public TNamed, Double_t GetPressure() const {return fPressure;} EGeoMaterialState GetState() const {return fState;} virtual Double_t GetSpecificActivity(Int_t) const {return 0.;} + TGeoExtension *GetUserExtension() const {return fUserExtension;} + TGeoExtension *GetFWExtension() const {return fFWExtension;} + TGeoExtension *GrabUserExtension() const; + TGeoExtension *GrabFWExtension() const; virtual Bool_t IsEq(const TGeoMaterial *other) const; Bool_t IsUsed() const {return TObject::TestBit(kMatUsed);} virtual Bool_t IsMixture() const {return kFALSE;} virtual void Print(const Option_t *option="") const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetA(Double_t a) {fA = a; SetRadLen(0);} void SetZ(Double_t z) {fZ = z; SetRadLen(0);} void SetDensity(Double_t density) {fDensity = density; SetRadLen(0);} @@ -132,6 +138,8 @@ class TGeoMaterial : public TNamed, void SetTemperature(Double_t temperature) {fTemperature = temperature;} void SetPressure(Double_t pressure) {fPressure = pressure;} void SetState(EGeoMaterialState state) {fState = state;} + void SetUserExtension(TGeoExtension *ext); + void SetFWExtension(TGeoExtension *ext); static Double_t ScreenFactor(Double_t z); @@ -194,7 +202,7 @@ protected : virtual Bool_t IsEq(const TGeoMaterial *other) const; virtual Bool_t IsMixture() const {return kTRUE;} virtual void Print(const Option_t *option="") const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetA(Double_t a) {fA = a;} void SetZ(Double_t z) {fZ = z;} diff --git a/geom/geom/inc/TGeoMatrix.h b/geom/geom/inc/TGeoMatrix.h index 01e50e4b166cf..513fb928f13d3 100644 --- a/geom/geom/inc/TGeoMatrix.h +++ b/geom/geom/inc/TGeoMatrix.h @@ -42,6 +42,7 @@ class TGeoMatrix : public TNamed public: enum EGeoTransfTypes { kGeoIdentity = 0, + kGeoShared = BIT(14), kGeoTranslation = BIT(17), kGeoRotation = BIT(18), kGeoScale = BIT(19), @@ -78,6 +79,7 @@ public : Bool_t IsRotation() const {return TestBit(kGeoRotation);} Bool_t IsReflection() const {return TestBit(kGeoReflection);} Bool_t IsScale() const {return TestBit(kGeoScale);} + Bool_t IsShared() const {return TestBit(kGeoShared);} Bool_t IsCombi() const {return (TestBit(kGeoTranslation) && TestBit(kGeoRotation));} Bool_t IsGeneral() const {return (TestBit(kGeoTranslation) @@ -112,6 +114,7 @@ public : virtual void SetDx(Double_t) {} virtual void SetDy(Double_t) {} virtual void SetDz(Double_t) {} + void SetShared(Bool_t flag=kTRUE) {SetBit(kGeoShared, flag);} ClassDef(TGeoMatrix, 1) // base geometrical transformation class }; @@ -154,7 +157,7 @@ public : virtual void RotateX(Double_t angle); virtual void RotateY(Double_t angle); virtual void RotateZ(Double_t angle); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void Subtract(const TGeoTranslation *other); void SetTranslation(Double_t dx, Double_t dy, Double_t dz); void SetTranslation(const TGeoMatrix &other); @@ -216,7 +219,7 @@ public : virtual void RotateX(Double_t angle); virtual void RotateY(Double_t angle); virtual void RotateZ(Double_t angle); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void ReflectX(Bool_t leftside, Bool_t rotonly=kFALSE); virtual void ReflectY(Bool_t leftside, Bool_t rotonly=kFALSE); virtual void ReflectZ(Bool_t leftside, Bool_t rotonly=kFALSE); @@ -253,6 +256,7 @@ public : TGeoScale(const char *name, Double_t sx, Double_t sy, Double_t sz); virtual ~TGeoScale(); + TGeoScale& operator=(const TGeoScale &other); virtual TGeoMatrix& Inverse() const; void SetScale(Double_t sx, Double_t sy, Double_t sz); virtual void LocalToMaster(const Double_t *local, Double_t *master) const; @@ -309,7 +313,7 @@ public : virtual void ReflectX(Bool_t leftside, Bool_t rotonly=kFALSE); virtual void ReflectY(Bool_t leftside, Bool_t rotonly=kFALSE); virtual void ReflectZ(Bool_t leftside, Bool_t rotonly=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void SetDx(Double_t dx) {SetTranslation(dx, fTranslation[1], fTranslation[2]);} virtual void SetDy(Double_t dy) {SetTranslation(fTranslation[0], dy, fTranslation[2]);} virtual void SetDz(Double_t dz) {SetTranslation(fTranslation[0], fTranslation[1], dz);} @@ -389,7 +393,7 @@ public : virtual const Double_t *GetTranslation() const {return &kNullVector[0];} virtual const Double_t *GetRotationMatrix() const {return &kIdentityMatrix[0];} virtual const Double_t *GetScale() const {return &kUnitScale[0];} - virtual void SavePrimitive(ostream &, Option_t * = "") {;} + virtual void SavePrimitive(std::ostream &, Option_t * = "") {;} ClassDef(TGeoIdentity, 1) // identity transformation class }; @@ -439,7 +443,7 @@ public : virtual void ReflectX(Bool_t leftside, Bool_t rotonly=kFALSE); virtual void ReflectY(Bool_t leftside, Bool_t rotonly=kFALSE); virtual void ReflectZ(Bool_t leftside, Bool_t rotonly=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void SetDx(Double_t dx) {fTranslation[0] = dx; SetBit(kGeoTranslation);} virtual void SetDy(Double_t dy) {fTranslation[1] = dy; SetBit(kGeoTranslation);} virtual void SetDz(Double_t dz) {fTranslation[2] = dz; SetBit(kGeoTranslation);} diff --git a/geom/geom/inc/TGeoMedium.h b/geom/geom/inc/TGeoMedium.h index 4f1080271aab5..03d54e4ee8111 100644 --- a/geom/geom/inc/TGeoMedium.h +++ b/geom/geom/inc/TGeoMedium.h @@ -52,7 +52,7 @@ class TGeoMedium : public TNamed void SetParam(Int_t i, Double_t val) {fParams[i] = val;} char *GetPointerName() const; TGeoMaterial *GetMaterial() const {return fMaterial;} - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetId(Int_t id) {fId = id;} void SetMaterial(TGeoMaterial *mat) {fMaterial = mat;} virtual void SetCerenkovProperties(TObject* cerenkov) {fMaterial->SetCerenkovProperties(cerenkov);} diff --git a/geom/geom/inc/TGeoNavigator.h b/geom/geom/inc/TGeoNavigator.h index 761a2f74baf72..6df9deff2803f 100644 --- a/geom/geom/inc/TGeoNavigator.h +++ b/geom/geom/inc/TGeoNavigator.h @@ -183,6 +183,7 @@ public : // void SetNormalChecked(Double_t norm) {fNormalChecked=norm;} void SetCldirChecked(Double_t *dir) {memcpy(fCldirChecked, dir, 3*sizeof(Double_t));} void SetLastSafetyForPoint(Double_t safe, const Double_t *point) {fLastSafety=safe; memcpy(fLastPoint,point,3*sizeof(Double_t));} + void SetLastSafetyForPoint(Double_t safe, Double_t x, Double_t y, Double_t z) {fLastSafety=safe; fLastPoint[0]=x; fLastPoint[1]=y, fLastPoint[2]=z;} //--- point/vector reference frame conversion void LocalToMaster(const Double_t *local, Double_t *master) const {fCache->LocalToMaster(local, master);} diff --git a/geom/geom/inc/TGeoNode.h b/geom/geom/inc/TGeoNode.h index 9af3d739d0ab9..7328de4ed78c2 100644 --- a/geom/geom/inc/TGeoNode.h +++ b/geom/geom/inc/TGeoNode.h @@ -39,6 +39,7 @@ class TGeoShape; class TGeoMedium; class TGeoMatrix; class TGeoHMatrix; +class TGeoExtension; //////////////////////////////////////////////////////////////////////////// // // @@ -56,6 +57,8 @@ class TGeoNode : public TNamed, Int_t fNumber; // copy number Int_t fNovlp; // number of overlaps Int_t *fOverlaps; //[fNovlp] list of indices for overlapping brothers + TGeoExtension *fUserExtension; //! Transient user-defined extension to volumes + TGeoExtension *fFWExtension; //! Transient framework-defined extension to volumes TGeoNode(const TGeoNode&); TGeoNode& operator=(const TGeoNode&); @@ -113,8 +116,8 @@ class TGeoNode : public TNamed, Bool_t MayOverlap(Int_t iother) const; virtual TGeoNode *MakeCopyNode() const {return 0;} - Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - void SaveAttributes(ostream &out); + Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + void SaveAttributes(std::ostream &out); void SetCurrentPoint(Double_t x, Double_t y, Double_t z) {fVolume->SetCurrentPoint(x,y,z);}// *MENU* void SetVolume(TGeoVolume *volume) {fVolume = volume;} void SetNumber(Int_t number) {fNumber=number;} @@ -125,6 +128,12 @@ class TGeoNode : public TNamed, void SetAllInvisible() {VisibleDaughters(kFALSE);} // *MENU* void SetMotherVolume(TGeoVolume *mother) {fMother = mother;} void SetOverlaps(Int_t *ovlp, Int_t novlp); + void SetUserExtension(TGeoExtension *ext); + void SetFWExtension(TGeoExtension *ext); + TGeoExtension *GetUserExtension() const {return fUserExtension;} + TGeoExtension *GetFWExtension() const {return fFWExtension;} + TGeoExtension *GrabUserExtension() const; + TGeoExtension *GrabFWExtension() const; virtual void MasterToLocal(const Double_t *master, Double_t *local) const; virtual void MasterToLocalVect(const Double_t *master, Double_t *local) const; @@ -202,7 +211,7 @@ class TGeoNodeOffset : public TGeoNode virtual TGeoPatternFinder *GetFinder() const {return fFinder;} virtual TGeoMatrix *GetMatrix() const {cd(); return fFinder->GetMatrix();} virtual TGeoNode *MakeCopyNode() const; - void SetFinder(const TGeoPatternFinder *finder) {fFinder = (TGeoPatternFinder*)finder;} + void SetFinder(TGeoPatternFinder *finder) {fFinder = finder;} ClassDef(TGeoNodeOffset, 1) // a geometry node with just an offset }; diff --git a/geom/geom/inc/TGeoPara.h b/geom/geom/inc/TGeoPara.h index 7a2a3501c7f96..2e9911f9b9ffb 100644 --- a/geom/geom/inc/TGeoPara.h +++ b/geom/geom/inc/TGeoPara.h @@ -53,12 +53,16 @@ protected : // methods virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual Double_t GetAxisRange(Int_t iaxis, Double_t &xlo, Double_t &xhi) const; @@ -78,8 +82,9 @@ protected : Double_t GetTyz() const {return fTyz;} virtual void InspectShape() const; virtual Bool_t IsCylType() const {return kFALSE;} - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void SetDimensions(Double_t *param); virtual void SetPoints(Double_t *points) const; virtual void SetPoints(Float_t *points) const; diff --git a/geom/geom/inc/TGeoParaboloid.h b/geom/geom/inc/TGeoParaboloid.h index ee9a2a64df588..2867ef646c670 100644 --- a/geom/geom/inc/TGeoParaboloid.h +++ b/geom/geom/inc/TGeoParaboloid.h @@ -53,14 +53,18 @@ class TGeoParaboloid : public TGeoBBox // methods virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); - Double_t DistToParaboloid(Double_t *point, Double_t *dir, Bool_t in) const; - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + Double_t DistToParaboloid(const Double_t *point, const Double_t *dir, Bool_t in) const; + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual const TBuffer3D &GetBuffer3D(Int_t reqSections, Bool_t localFrame) const; @@ -76,8 +80,9 @@ class TGeoParaboloid : public TGeoBBox virtual void InspectShape() const; virtual Bool_t IsCylType() const {return kTRUE;} virtual TBuffer3D *MakeBuffer3D() const; - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetParaboloidDimensions(Double_t rlo, Double_t rhi, Double_t dz); virtual void SetDimensions(Double_t *param); virtual void SetPoints(Double_t *points) const; diff --git a/geom/geom/inc/TGeoPatternFinder.h b/geom/geom/inc/TGeoPatternFinder.h index b214b2d490827..c771aef519489 100644 --- a/geom/geom/inc/TGeoPatternFinder.h +++ b/geom/geom/inc/TGeoPatternFinder.h @@ -41,6 +41,9 @@ class TGeoPatternFinder : public TObject ThreadData_t(); ~ThreadData_t(); + private: + ThreadData_t(const ThreadData_t&); // Not implemented + ThreadData_t& operator=(const ThreadData_t&); // Not implemented }; ThreadData_t& GetThreadData() const; void ClearThreadData() const; @@ -134,7 +137,7 @@ class TGeoPatternX : public TGeoPatternFinder virtual Bool_t IsOnBoundary(const Double_t *point) const; virtual TGeoPatternFinder *MakeCopy(Bool_t reflect=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const; ClassDef(TGeoPatternX, 1) // X division pattern @@ -167,7 +170,7 @@ class TGeoPatternY : public TGeoPatternFinder virtual Bool_t IsOnBoundary(const Double_t *point) const; virtual TGeoPatternFinder *MakeCopy(Bool_t reflect=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const; ClassDef(TGeoPatternY, 1) // Y division pattern @@ -200,7 +203,7 @@ class TGeoPatternZ : public TGeoPatternFinder virtual Bool_t IsOnBoundary(const Double_t *point) const; virtual TGeoPatternFinder *MakeCopy(Bool_t reflect=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const; ClassDef(TGeoPatternZ, 1) // Z division pattern @@ -233,7 +236,7 @@ class TGeoPatternParaX : public TGeoPatternFinder virtual Bool_t IsOnBoundary(const Double_t *point) const; virtual TGeoPatternFinder *MakeCopy(Bool_t reflect=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const; ClassDef(TGeoPatternParaX, 1) // Para X division pattern @@ -269,7 +272,7 @@ private : virtual Bool_t IsOnBoundary(const Double_t *point) const; virtual TGeoPatternFinder *MakeCopy(Bool_t reflect=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const; ClassDef(TGeoPatternParaY, 1) // Para Y division pattern @@ -306,7 +309,7 @@ private : virtual Bool_t IsOnBoundary(const Double_t *point) const; virtual TGeoPatternFinder *MakeCopy(Bool_t reflect=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const; ClassDef(TGeoPatternParaZ, 1) // Para Z division pattern @@ -345,7 +348,7 @@ private : virtual Bool_t IsOnBoundary(const Double_t *point) const; virtual TGeoPatternFinder *MakeCopy(Bool_t reflect=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const; ClassDef(TGeoPatternTrapZ, 1) // Trap od Gtra Z division pattern @@ -378,7 +381,7 @@ class TGeoPatternCylR : public TGeoPatternFinder virtual Bool_t IsOnBoundary(const Double_t *point) const; virtual TGeoPatternFinder *MakeCopy(Bool_t reflect=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const; ClassDef(TGeoPatternCylR, 1) // Cylindrical R division pattern @@ -419,7 +422,7 @@ private : virtual Bool_t IsOnBoundary(const Double_t *point) const; virtual TGeoPatternFinder *MakeCopy(Bool_t reflect=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const; ClassDef(TGeoPatternCylPhi, 1) // Cylindrical phi division pattern @@ -450,7 +453,7 @@ class TGeoPatternSphR : public TGeoPatternFinder virtual Int_t GetDivAxis() {return 1;} virtual TGeoPatternFinder *MakeCopy(Bool_t reflect=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const; ClassDef(TGeoPatternSphR, 1) // spherical R division pattern @@ -481,7 +484,7 @@ class TGeoPatternSphTheta : public TGeoPatternFinder virtual Int_t GetDivAxis() {return 2;} virtual TGeoPatternFinder *MakeCopy(Bool_t reflect=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const; ClassDef(TGeoPatternSphTheta, 1) // spherical theta division pattern @@ -512,7 +515,7 @@ class TGeoPatternSphPhi : public TGeoPatternFinder virtual Int_t GetDivAxis() {return 3;} virtual TGeoPatternFinder *MakeCopy(Bool_t reflect=kFALSE); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void UpdateMatrix(Int_t idiv, TGeoHMatrix &matrix) const; ClassDef(TGeoPatternSphPhi, 1) // Spherical phi division pattern diff --git a/geom/geom/inc/TGeoPcon.h b/geom/geom/inc/TGeoPcon.h index 868f827adb76f..b087f9d8449e3 100644 --- a/geom/geom/inc/TGeoPcon.h +++ b/geom/geom/inc/TGeoPcon.h @@ -32,12 +32,20 @@ class TGeoPcon : public TGeoBBox { protected: // data members - Int_t fNz; // number of z planes (at least two) - Double_t fPhi1; // lower phi limit - Double_t fDphi; // phi range - Double_t *fRmin; //[fNz] pointer to array of inner radii - Double_t *fRmax; //[fNz] pointer to array of outer radii - Double_t *fZ; //[fNz] pointer to array of Z planes positions + Int_t fNz; // number of z planes (at least two) + Double_t fPhi1; // lower phi limit (converted to [0,2*pi) + Double_t fDphi; // phi range + Double_t *fRmin; //[fNz] pointer to array of inner radii + Double_t *fRmax; //[fNz] pointer to array of outer radii + Double_t *fZ; //[fNz] pointer to array of Z planes positions + Bool_t fFullPhi; //! Full phi range flag + Double_t fC1; //! Cosine of phi1 + Double_t fS1; //! Sine of phi1 + Double_t fC2; //! Cosine of phi1+dphi + Double_t fS2; //! Sine of phi1+dphi + Double_t fCm; //! Cosine of (phi1+phi2)/2 + Double_t fSm; //! Sine of (phi1+phi2)/2 + Double_t fCdphi; //! Cosine of dphi // methods TGeoPcon(const TGeoPcon&); @@ -54,15 +62,18 @@ class TGeoPcon : public TGeoBBox // methods virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; virtual void DefineSection(Int_t snum, Double_t z, Double_t rmin, Double_t rmax); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - Double_t DistToSegZ(Double_t *point, Double_t *dir, Int_t &iz, Double_t c1, Double_t s1, - Double_t c2, Double_t s2, Double_t cfio, Double_t sfio, Double_t cdfi) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + Double_t DistToSegZ(const Double_t *point, const Double_t *dir, Int_t &iz) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); @@ -93,9 +104,10 @@ class TGeoPcon : public TGeoBBox Double_t &Rmin(Int_t ipl) {return fRmin[ipl];} Double_t &Rmax(Int_t ipl) {return fRmax[ipl];} Double_t &Z(Int_t ipl) {return fZ[ipl];} - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - Double_t SafetyToSegment(Double_t *point, Int_t ipl, Bool_t in=kTRUE, Double_t safmin=TGeoShape::Big()) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + Double_t SafetyToSegment(const Double_t *point, Int_t ipl, Bool_t in=kTRUE, Double_t safmin=TGeoShape::Big()) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void SetDimensions(Double_t *param); virtual void SetPoints(Double_t *points) const; virtual void SetPoints(Float_t *points) const; diff --git a/geom/geom/inc/TGeoPgon.h b/geom/geom/inc/TGeoPgon.h index d5789c4db5669..05136dc9d808f 100644 --- a/geom/geom/inc/TGeoPgon.h +++ b/geom/geom/inc/TGeoPgon.h @@ -37,15 +37,15 @@ class TGeoPgon : public TGeoPcon mutable Int_t *fIntBuffer; //![fNedges+4] temporary int buffer array mutable Double_t *fDblBuffer; //![fNedges+4] temporary double buffer array - Int_t GetPhiCrossList(Double_t *point, Double_t *dir, Int_t istart, Double_t *sphi, Int_t *iphi, Double_t stepmax=TGeoShape::Big()) const; - Bool_t IsCrossingSlice(Double_t *point, Double_t *dir, Int_t iphi, Double_t sstart, Int_t &ipl, Double_t &snext, Double_t stepmax) const; - void LocatePhi(Double_t *point, Int_t &ipsec) const; + Int_t GetPhiCrossList(const Double_t *point, const Double_t *dir, Int_t istart, Double_t *sphi, Int_t *iphi, Double_t stepmax=TGeoShape::Big()) const; + Bool_t IsCrossingSlice(const Double_t *point, const Double_t *dir, Int_t iphi, Double_t sstart, Int_t &ipl, Double_t &snext, Double_t stepmax) const; + void LocatePhi(const Double_t *point, Int_t &ipsec) const; Double_t Rpg(Double_t z, Int_t ipl, Bool_t inner, Double_t &a, Double_t &b) const; - Double_t Rproj(Double_t z,Double_t *point, Double_t *dir, Double_t cphi, Double_t sphi, Double_t &a, Double_t &b) const; - Bool_t SliceCrossing(Double_t *point, Double_t *dir, Int_t nphi, Int_t *iphi, Double_t *sphi, Double_t &snext, Double_t stepmax) const; - Bool_t SliceCrossingIn(Double_t *point, Double_t *dir, Int_t ipl, Int_t nphi, Int_t *iphi, Double_t *sphi, Double_t &snext, Double_t stepmax) const; - Bool_t SliceCrossingZ(Double_t *point, Double_t *dir, Int_t nphi, Int_t *iphi, Double_t *sphi, Double_t &snext, Double_t stepmax) const; - Bool_t SliceCrossingInZ(Double_t *point, Double_t *dir, Int_t nphi, Int_t *iphi, Double_t *sphi, Double_t &snext, Double_t stepmax) const; + Double_t Rproj(Double_t z,const Double_t *point, const Double_t *dir, Double_t cphi, Double_t sphi, Double_t &a, Double_t &b) const; + Bool_t SliceCrossing(const Double_t *point, const Double_t *dir, Int_t nphi, Int_t *iphi, Double_t *sphi, Double_t &snext, Double_t stepmax) const; + Bool_t SliceCrossingIn(const Double_t *point, const Double_t *dir, Int_t ipl, Int_t nphi, Int_t *iphi, Double_t *sphi, Double_t &snext, Double_t stepmax) const; + Bool_t SliceCrossingZ(const Double_t *point, const Double_t *dir, Int_t nphi, Int_t *iphi, Double_t *sphi, Double_t &snext, Double_t stepmax) const; + Bool_t SliceCrossingInZ(const Double_t *point, const Double_t *dir, Int_t nphi, Int_t *iphi, Double_t *sphi, Double_t &snext, Double_t stepmax) const; public: // constructors @@ -58,12 +58,16 @@ class TGeoPgon : public TGeoPcon // methods virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); @@ -78,9 +82,10 @@ class TGeoPgon : public TGeoPcon virtual Bool_t GetPointsOnSegments(Int_t npoints, Double_t *array) const {return TGeoBBox::GetPointsOnSegments(npoints,array);} virtual void InspectShape() const; virtual TBuffer3D *MakeBuffer3D() const; - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - Double_t SafetyToSegment(Double_t *point, Int_t ipl, Int_t iphi, Bool_t in, Double_t safphi, Double_t safmin=TGeoShape::Big()) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + Double_t SafetyToSegment(const Double_t *point, Int_t ipl, Int_t iphi, Bool_t in, Double_t safphi, Double_t safmin=TGeoShape::Big()) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void SetDimensions(Double_t *param); void SetNedges(Int_t ne) {if (ne>2) fNedges=ne;} virtual void SetPoints(Double_t *points) const; diff --git a/geom/geom/inc/TGeoPhysicalNode.h b/geom/geom/inc/TGeoPhysicalNode.h index 5b5dcf6d0bd99..5a3bb2794e582 100644 --- a/geom/geom/inc/TGeoPhysicalNode.h +++ b/geom/geom/inc/TGeoPhysicalNode.h @@ -68,7 +68,7 @@ class TGeoPhysicalNode : public TNamed, // destructor virtual ~TGeoPhysicalNode(); - void Align(TGeoMatrix *newmat=0, TGeoShape *newshape=0, Bool_t check=kFALSE, Double_t ovlp=0.001); + Bool_t Align(TGeoMatrix *newmat=0, TGeoShape *newshape=0, Bool_t check=kFALSE, Double_t ovlp=0.001); void cd() const; void Draw(Option_t *option=""); Int_t GetLevel() const {return fLevel;} diff --git a/geom/geom/inc/TGeoPolygon.h b/geom/geom/inc/TGeoPolygon.h index 1179d8417dbd5..1f18284859d84 100644 --- a/geom/geom/inc/TGeoPolygon.h +++ b/geom/geom/inc/TGeoPolygon.h @@ -48,7 +48,7 @@ protected : private: void ConvexCheck(); // force convexity checking Bool_t IsSegConvex(Int_t i1, Int_t i2=-1) const; - Bool_t IsRightSided(Double_t *point, Int_t ind1, Int_t ind2) const; + Bool_t IsRightSided(const Double_t *point, Int_t ind1, Int_t ind2) const; void OutscribedConvex(); public: // constructors @@ -58,16 +58,20 @@ protected : virtual ~TGeoPolygon(); // methods Double_t Area() const; - Bool_t Contains(Double_t *point) const; + Bool_t Contains(const Double_t *point) const; + virtual void Draw(Option_t *option=""); void FinishPolygon(); Int_t GetNvert() const {return fNvert;} + Int_t GetNconvex() const {return fNconvex;} Double_t *GetX() {return fX;} Double_t *GetY() {return fY;} + void GetVertices(Double_t *x, Double_t *y) const; + void GetConvexVertices(Double_t *x, Double_t *y) const; Bool_t IsClockwise() const {return !TObject::TestBit(kGeoACW);} Bool_t IsConvex() const {return TObject::TestBit(kGeoConvex);} Bool_t IsFinished() const {return TObject::TestBit(kGeoFinishPolygon);} Bool_t IsIllegalCheck() const; - Double_t Safety(Double_t *point, Int_t &isegment) const; + Double_t Safety(const Double_t *point, Int_t &isegment) const; void SetConvex(Bool_t flag=kTRUE) {TObject::SetBit(kGeoConvex,flag);} void SetXY(Double_t *x, Double_t *y); void SetNextIndex(Int_t index=-1); diff --git a/geom/geom/inc/TGeoRCPtr.h b/geom/geom/inc/TGeoRCPtr.h new file mode 100644 index 0000000000000..1450e2560e605 --- /dev/null +++ b/geom/geom/inc/TGeoRCPtr.h @@ -0,0 +1,115 @@ +/************************************************************************* + * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +// Author: Andrei.Gheata@cern.ch 29/05/2013 + +//______________________________________________________________________________ +// TGeoRCPtr - A reference counting-managed pointer for classes derived from +// TGeoExtension which can be used as C pointer. Based on +// CodeProject implementation example +//______________________________________________________________________________ + + + +/*______________________________________________________________________________ +Example: +======= +class MyExtension : public TGeoExtension { +public: + MyExtension() : TGeoExtension(), fRC(0) {printf("Created MyExtension\n");} + virtual ~MyExtension() {printf("Deleted MyExtension\n");} + + virtual TGeoExtension *Grab() const {fRC++; return (TGeoExtension*)this;} + virtual void Release() const {assert(fRC > 0); fRC--; if (fRC ==0) delete this;} + void print() const {printf("MyExtension object %p\n", this);} +private: + mutable Int_t fRC; // Reference counter + ClassDef(MyExtension,1) +}; + + +Usage: +====== + // Module 1 creates an object + TGeoRCPtr a2 = new MyExtension(); //fRC=1 + + // Module 2 grabs object + TGeoRCPtr ptr2 = a2; //fRC=2 + + // Module 2 invokes a method + ptr2->Print(); + (*ptr2).Print(); + + // Module 1 no longer needs object + a2 = 0; //RC=1 + + // Module 2 no longer needs object + ptr2 = 0; //object will be destroyed here + +Note: +===== + Event if one forgets to call ptr2 = 0, the object gets delete when the method + using ptr2 gets out of scope. +______________________________________________________________________________*/ + +template +class TGeoRCPtr +{ +public: + //Construct using a C pointer, e.g. TGeoRCPtr x = new T(); + TGeoRCPtr(T* ptr = 0) + : fPtr(ptr) + { + if(ptr != 0) ptr->Grab(); + } + + //Copy constructor + TGeoRCPtr(const TGeoRCPtr &ptr) + : fPtr(ptr.fPtr) + { + if(fPtr != 0) fPtr->Grab(); + } + + ~TGeoRCPtr() + { + if(fPtr != 0) fPtr->Release(); + } + + //Assign a pointer, e.g. x = new T(); + TGeoRCPtr &operator=(T* ptr) + { + if(ptr != 0) ptr->Grab(); + if(fPtr != 0) fPtr->Release(); + fPtr = ptr; + return (*this); + } + + //Assign another TGeoRCPtr + TGeoRCPtr &operator=(const TGeoRCPtr &ptr) + { + return (*this) = ptr.fPtr; + } + + //Retrieve actual pointer + T* Get() const + { + return fPtr; + } + + //Some overloaded operators to facilitate dealing with an TGeoRCPtr as a convetional C pointer. + //Without these operators, one can still use the less transparent Get() method to access the pointer. + T* operator->() const {return fPtr;} //x->member + T &operator*() const {return *fPtr;} //*x, (*x).member + operator T*() const {return fPtr;} //T* y = x; + operator bool() const {return fPtr != 0;} //if(x) {/*x is not NULL*/} + bool operator==(const TGeoRCPtr &ptr) {return fPtr == ptr.fPtr;} + bool operator==(const T *ptr) {return fPtr == ptr;} + +private: + T *fPtr; //Actual pointer +}; diff --git a/geom/geom/inc/TGeoScaledShape.h b/geom/geom/inc/TGeoScaledShape.h index afb477de99ba2..765df6e85a5a1 100644 --- a/geom/geom/inc/TGeoScaledShape.h +++ b/geom/geom/inc/TGeoScaledShape.h @@ -43,13 +43,17 @@ protected : // methods virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual TGeoShape *GetMakeRuntimeShape(TGeoShape *mother, TGeoMatrix *mat) const; @@ -64,8 +68,9 @@ protected : virtual Bool_t IsReflected() const; virtual TBuffer3D *MakeBuffer3D() const; static TGeoShape *MakeScaledShape(const char *name, TGeoShape *shape, TGeoScale *scale); - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetScale(TGeoScale *scale) {fScale = scale;} virtual void SetPoints(Double_t *points) const; virtual void SetPoints(Float_t *points) const; diff --git a/geom/geom/inc/TGeoShape.h b/geom/geom/inc/TGeoShape.h index 24cee7897c172..51452086f9779 100644 --- a/geom/geom/inc/TGeoShape.h +++ b/geom/geom/inc/TGeoShape.h @@ -101,18 +101,23 @@ protected : static Double_t Tolerance() {return 1.E-10;} static Double_t ComputeEpsMch(); static Double_t EpsMch(); + virtual void AfterStreamer() {}; virtual Double_t Capacity() const = 0; void CheckShape(Int_t testNo, Int_t nsamples=10000, Option_t *option=""); virtual void ComputeBBox() = 0; - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) = 0; - virtual Bool_t Contains(Double_t *point) const = 0; - virtual Bool_t CouldBeCrossed(Double_t *point, Double_t *dir) const = 0; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm) = 0; + virtual void ComputeNormal_v(const Double_t *, const Double_t *, Double_t *, Int_t) {} + virtual Bool_t Contains(const Double_t *point) const = 0; + virtual void Contains_v(const Double_t *, Bool_t *, Int_t) const {} + virtual Bool_t CouldBeCrossed(const Double_t *point, const Double_t *dir) const = 0; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py) = 0; - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const = 0; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *, const Double_t *, Double_t *, Int_t, Double_t *) const {} + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const = 0; - static Double_t DistToPhiMin(Double_t *point, Double_t *dir, Double_t s1, Double_t c1, Double_t s2, Double_t c2, + virtual void DistFromOutside_v(const Double_t *, const Double_t *, Double_t *, Int_t, Double_t *) const {} + static Double_t DistToPhiMin(const Double_t *point, const Double_t *dir, Double_t s1, Double_t c1, Double_t s2, Double_t c2, Double_t sm, Double_t cm, Bool_t in=kTRUE); virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step) = 0; @@ -134,21 +139,23 @@ protected : virtual Bool_t IsAssembly() const {return kFALSE;} virtual Bool_t IsComposite() const {return kFALSE;} virtual Bool_t IsCylType() const = 0; - static Bool_t IsCloseToPhi(Double_t epsil, Double_t *point, Double_t c1, Double_t s1, Double_t c2, Double_t s2); - static Bool_t IsCrossingSemiplane(Double_t *point, Double_t *dir, Double_t cphi, Double_t sphi, Double_t &snext, Double_t &rxy); + static Bool_t IsCloseToPhi(Double_t epsil, const Double_t *point, Double_t c1, Double_t s1, Double_t c2, Double_t s2); + static Bool_t IsCrossingSemiplane(const Double_t *point, const Double_t *dir, Double_t cphi, Double_t sphi, Double_t &snext, Double_t &rxy); static Bool_t IsSameWithinTolerance(Double_t a, Double_t b); static Bool_t IsSegCrossing(Double_t x1, Double_t y1, Double_t x2, Double_t y2,Double_t x3, Double_t y3,Double_t x4, Double_t y4); - static Bool_t IsInPhiRange(Double_t *point, Double_t phi1, Double_t phi2); + static Bool_t IsInPhiRange(const Double_t *point, Double_t phi1, Double_t phi2); virtual Bool_t IsReflected() const {return kFALSE;} Bool_t IsRunTimeShape() const {return TestShapeBit(kGeoRunTimeShape);} Bool_t IsValid() const {return !TestShapeBit(kGeoInvalidShape);} virtual Bool_t IsValidBox() const = 0; virtual void InspectShape() const = 0; virtual TBuffer3D *MakeBuffer3D() const {return 0;} - static void NormalPhi(Double_t *point, Double_t *dir, Double_t *norm, Double_t c1, Double_t s1, Double_t c2, Double_t s2); + static void NormalPhi(const Double_t *point, const Double_t *dir, Double_t *norm, Double_t c1, Double_t s1, Double_t c2, Double_t s2); virtual void Paint(Option_t *option=""); - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const = 0; - static Double_t SafetyPhi(Double_t *point, Bool_t in, Double_t phi1, Double_t phi2); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const = 0; + virtual void Safety_v(const Double_t *, const Bool_t *, Double_t *, Int_t) const {} + static Double_t SafetyPhi(const Double_t *point, Bool_t in, Double_t phi1, Double_t phi2); + static Double_t SafetySeg(Double_t r, Double_t z, Double_t r1, Double_t z1, Double_t r2, Double_t z2, Bool_t outer); virtual void SetDimensions(Double_t *param) = 0; void SetId(Int_t id) {fShapeId = id;} virtual void SetPoints(Double_t *points) const = 0; diff --git a/geom/geom/inc/TGeoShapeAssembly.h b/geom/geom/inc/TGeoShapeAssembly.h index c16965e629539..2eef13abedb97 100644 --- a/geom/geom/inc/TGeoShapeAssembly.h +++ b/geom/geom/inc/TGeoShapeAssembly.h @@ -41,13 +41,17 @@ protected : virtual ~TGeoShapeAssembly(); // methods virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual TGeoShape *GetMakeRuntimeShape(TGeoShape *mother, TGeoMatrix *mat) const; @@ -58,8 +62,9 @@ protected : virtual Bool_t IsCylType() const {return kFALSE;} void NeedsBBoxRecompute() {fBBoxOK = kFALSE;} void RecomputeBoxLast(); - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void SetPoints(Double_t *points) const; virtual void SetPoints(Float_t *points) const; virtual void SetSegsAndPols(TBuffer3D &buff) const; diff --git a/geom/geom/inc/TGeoSphere.h b/geom/geom/inc/TGeoSphere.h index 67c3fd8f17246..b5a630351dfdd 100644 --- a/geom/geom/inc/TGeoSphere.h +++ b/geom/geom/inc/TGeoSphere.h @@ -53,14 +53,18 @@ protected : // methods virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - Double_t DistToSphere(Double_t *point, Double_t *dir, Double_t rsph, Bool_t check=kTRUE, Bool_t firstcross=kTRUE) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + Double_t DistToSphere(const Double_t *point, const Double_t *dir, Double_t rsph, Bool_t check=kTRUE, Bool_t firstcross=kTRUE) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual const char *GetAxisName(Int_t iaxis) const; @@ -82,15 +86,17 @@ protected : Double_t GetPhi2() const {return fPhi2;} virtual void InspectShape() const; virtual Bool_t IsCylType() const {return kFALSE;} - Int_t IsOnBoundary(Double_t *point) const; - Bool_t IsPointInside(Double_t *point, Bool_t checkR=kTRUE, Bool_t checkTh=kTRUE, Bool_t checkPh=kTRUE) const; + Int_t IsOnBoundary(const Double_t *point) const; + Bool_t IsPointInside(const Double_t *point, Bool_t checkR=kTRUE, Bool_t checkTh=kTRUE, Bool_t checkPh=kTRUE) const; virtual TBuffer3D *MakeBuffer3D() const; - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetSphDimensions(Double_t rmin, Double_t rmax, Double_t theta1, Double_t theta2, Double_t phi1, Double_t phi2); virtual void SetNumberOfDivisions(Int_t p); virtual void SetDimensions(Double_t *param); + void SetDimensions(Double_t *param, Int_t nparam); virtual void SetPoints(Double_t *points) const; virtual void SetPoints(Float_t *points) const; virtual void SetSegsAndPols(TBuffer3D &buff) const; diff --git a/geom/geom/inc/TGeoTorus.h b/geom/geom/inc/TGeoTorus.h index 57d862c07b9b3..84dc818fcccb7 100644 --- a/geom/geom/inc/TGeoTorus.h +++ b/geom/geom/inc/TGeoTorus.h @@ -40,10 +40,10 @@ protected : public: virtual Double_t Capacity() const; - Double_t Daxis(Double_t *pt, Double_t *dir, Double_t t) const; - Double_t DDaxis(Double_t *pt, Double_t *dir, Double_t t) const; - Double_t DDDaxis(Double_t *pt, Double_t *dir, Double_t t) const; - Double_t ToBoundary(Double_t *pt, Double_t *dir, Double_t r, Bool_t in) const; + Double_t Daxis(const Double_t *pt, const Double_t *dir, Double_t t) const; + Double_t DDaxis(const Double_t *pt, const Double_t *dir, Double_t t) const; + Double_t DDDaxis(const Double_t *pt, const Double_t *dir, Double_t t) const; + Double_t ToBoundary(const Double_t *pt, const Double_t *dir, Double_t r, Bool_t in) const; Int_t SolveCubic(Double_t a, Double_t b, Double_t c, Double_t *x) const; Int_t SolveQuartic(Double_t a, Double_t b, Double_t c, Double_t d, Double_t *x) const; public: @@ -57,12 +57,16 @@ protected : // methods virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); @@ -83,8 +87,9 @@ protected : virtual void InspectShape() const; virtual Bool_t IsCylType() const {return kTRUE;} virtual TBuffer3D *MakeBuffer3D() const; - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetTorusDimensions(Double_t r, Double_t rmin, Double_t rmax, Double_t phi1, Double_t dphi); virtual void SetDimensions(Double_t *param); virtual void SetPoints(Double_t *points) const; diff --git a/geom/geom/inc/TGeoTrd1.h b/geom/geom/inc/TGeoTrd1.h index b17f3c201d000..ec8c172b0f8f9 100644 --- a/geom/geom/inc/TGeoTrd1.h +++ b/geom/geom/inc/TGeoTrd1.h @@ -48,12 +48,16 @@ class TGeoTrd1 : public TGeoBBox virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual Double_t GetAxisRange(Int_t iaxis, Double_t &xlo, Double_t &xhi) const; @@ -65,12 +69,13 @@ class TGeoTrd1 : public TGeoBBox Double_t GetDz() const {return fDz;} virtual Int_t GetFittingBox(const TGeoBBox *parambox, TGeoMatrix *mat, Double_t &dx, Double_t &dy, Double_t &dz) const; virtual TGeoShape *GetMakeRuntimeShape(TGeoShape *mother, TGeoMatrix *mat) const; - void GetVisibleCorner(Double_t *point, Double_t *vertex, Double_t *normals) const; - void GetOppositeCorner(Double_t *point, Int_t inorm, Double_t *vertex, Double_t *normals) const; + void GetVisibleCorner(const Double_t *point, Double_t *vertex, Double_t *normals) const; + void GetOppositeCorner(const Double_t *point, Int_t inorm, Double_t *vertex, Double_t *normals) const; virtual void InspectShape() const; virtual Bool_t IsCylType() const {return kFALSE;} - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void SetDimensions(Double_t *param); virtual void SetPoints(Double_t *points) const; virtual void SetPoints(Float_t *points) const; diff --git a/geom/geom/inc/TGeoTrd2.h b/geom/geom/inc/TGeoTrd2.h index f99b7f63b223f..d88cbd5172bab 100644 --- a/geom/geom/inc/TGeoTrd2.h +++ b/geom/geom/inc/TGeoTrd2.h @@ -48,13 +48,17 @@ class TGeoTrd2 : public TGeoBBox // methods virtual Double_t Capacity() const; - virtual Bool_t Contains(Double_t *point) const; + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual Double_t GetAxisRange(Int_t iaxis, Double_t &xlo, Double_t &xhi) const; @@ -67,12 +71,13 @@ class TGeoTrd2 : public TGeoBBox Double_t GetDz() const {return fDz;} virtual Int_t GetFittingBox(const TGeoBBox *parambox, TGeoMatrix *mat, Double_t &dx, Double_t &dy, Double_t &dz) const; virtual TGeoShape *GetMakeRuntimeShape(TGeoShape *mother, TGeoMatrix *mat) const; - void GetVisibleCorner(Double_t *point, Double_t *vertex, Double_t *normals) const; - void GetOppositeCorner(Double_t *point, Int_t inorm, Double_t *vertex, Double_t *normals) const; + void GetVisibleCorner(const Double_t *point, Double_t *vertex, Double_t *normals) const; + void GetOppositeCorner(const Double_t *point, Int_t inorm, Double_t *vertex, Double_t *normals) const; virtual void InspectShape() const; virtual Bool_t IsCylType() const {return kFALSE;} - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void SetDimensions(Double_t *param); virtual void SetPoints(Double_t *points) const; virtual void SetPoints(Float_t *points) const; diff --git a/geom/geom/inc/TGeoTube.h b/geom/geom/inc/TGeoTube.h index 61c5a67ef8761..c606fa1fc9013 100644 --- a/geom/geom/inc/TGeoTube.h +++ b/geom/geom/inc/TGeoTube.h @@ -47,16 +47,20 @@ protected : virtual Double_t Capacity() const; static Double_t Capacity(Double_t rmin, Double_t rmax, Double_t dz); virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - static void ComputeNormalS(Double_t *point, Double_t *dir, Double_t *norm, + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + static void ComputeNormalS(const Double_t *point, const Double_t *dir, Double_t *norm, Double_t rmin, Double_t rmax, Double_t dz); - virtual Bool_t Contains(Double_t *point) const; - static Double_t DistFromInsideS(Double_t *point, Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; + static Double_t DistFromInsideS(const Double_t *point, const Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz); + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - static Double_t DistFromOutsideS(Double_t *point, Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz); - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + static Double_t DistFromOutsideS(const Double_t *point, const Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz); + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; static void DistToTube(Double_t rsq, Double_t nsq, Double_t rdotn, Double_t radius, Double_t &b, Double_t &delta); virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, @@ -77,9 +81,10 @@ protected : virtual void InspectShape() const; virtual Bool_t IsCylType() const {return kTRUE;} virtual TBuffer3D *MakeBuffer3D() const; - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - static Double_t SafetyS(Double_t *point, Bool_t in, Double_t rmin, Double_t rmax, Double_t dz, Int_t skipz=0); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + static Double_t SafetyS(const Double_t *point, Bool_t in, Double_t rmin, Double_t rmax, Double_t dz, Int_t skipz=0); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetTubeDimensions(Double_t rmin, Double_t rmax, Double_t dz); virtual void SetDimensions(Double_t *param); virtual void SetPoints(Double_t *points) const; @@ -106,6 +111,16 @@ class TGeoTubeSeg : public TGeoTube // data members Double_t fPhi1; // first phi limit Double_t fPhi2; // second phi limit + // Transient trigonometric data + Double_t fS1; //!sin(phi1) + Double_t fC1; //!cos(phi1) + Double_t fS2; //!sin(phi2) + Double_t fC2; //!cos(phi2) + Double_t fSm; //!sin(0.5*(phi1+phi2)) + Double_t fCm; //!cos(0.5*(phi1+phi2)) + Double_t fCdfi; //!cos(0.5*(phi1-phi2)) + + void InitTrigonometry(); public: // constructors @@ -118,23 +133,28 @@ class TGeoTubeSeg : public TGeoTube // destructor virtual ~TGeoTubeSeg(); // methods + virtual void AfterStreamer(); virtual Double_t Capacity() const; static Double_t Capacity(Double_t rmin, Double_t rmax, Double_t dz, Double_t phi1, Double_t phi2); virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - static void ComputeNormalS(Double_t *point, Double_t *dir, Double_t *norm, + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + static void ComputeNormalS(const Double_t *point, const Double_t *dir, Double_t *norm, Double_t rmin, Double_t rmax, Double_t dz, Double_t c1, Double_t s1, Double_t c2, Double_t s2); - virtual Bool_t Contains(Double_t *point) const; + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); - static Double_t DistFromInsideS(Double_t *point, Double_t *dir,Double_t rmin, Double_t rmax, Double_t dz, + static Double_t DistFromInsideS(const Double_t *point, const Double_t *dir,Double_t rmin, Double_t rmax, Double_t dz, Double_t c1, Double_t s1, Double_t c2, Double_t s2, Double_t cm, Double_t sm, Double_t cdfi); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - static Double_t DistFromOutsideS(Double_t *point, Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + static Double_t DistFromOutsideS(const Double_t *point, const Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz, Double_t c1, Double_t s1, Double_t c2, Double_t s2, Double_t cm, Double_t sm, Double_t cdfi); - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual Double_t GetAxisRange(Int_t iaxis, Double_t &xlo, Double_t &xhi) const; @@ -149,10 +169,11 @@ class TGeoTubeSeg : public TGeoTube Double_t GetPhi2() const {return fPhi2;} virtual void InspectShape() const; virtual TBuffer3D *MakeBuffer3D() const; - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - static Double_t SafetyS(Double_t *point, Bool_t in, Double_t rmin, Double_t rmax, Double_t dz, + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + static Double_t SafetyS(const Double_t *point, Bool_t in, Double_t rmin, Double_t rmax, Double_t dz, Double_t phi1, Double_t phi2, Int_t skipz=0); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetTubsDimensions(Double_t rmin, Double_t rmax, Double_t dz, Double_t phi1, Double_t phi2); virtual void SetDimensions(Double_t *param); @@ -195,12 +216,16 @@ class TGeoCtub : public TGeoTubeSeg // methods virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual TGeoVolume *Divide(TGeoVolume *voldiv, const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step); virtual Double_t GetAxisRange(Int_t iaxis, Double_t &xlo, Double_t &xhi) const; @@ -214,8 +239,9 @@ class TGeoCtub : public TGeoTubeSeg const Double_t *GetNhigh() const {return &fNhigh[0];} Double_t GetZcoord(Double_t xc, Double_t yc, Double_t zc) const; virtual void InspectShape() const; - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetCtubDimensions(Double_t rmin, Double_t rmax, Double_t dz, Double_t phi1, Double_t phi2, Double_t lx, Double_t ly, Double_t lz, Double_t tx, Double_t ty, Double_t tz); diff --git a/geom/geom/inc/TGeoVolume.h b/geom/geom/inc/TGeoVolume.h index 6c7578463961c..c7091f125bdb4 100644 --- a/geom/geom/inc/TGeoVolume.h +++ b/geom/geom/inc/TGeoVolume.h @@ -49,6 +49,7 @@ class TGeoMatrix; class TGeoPatternFinder; class TGeoVoxelFinder; class TGeoManager; +class TGeoExtension; //////////////////////////////////////////////////////////////////////////// // // @@ -75,6 +76,8 @@ protected : TString fOption; //! option - if any Int_t fNumber; // volume serial number in the list of volumes Int_t fNtotal; // total number of physical nodes + TGeoExtension *fUserExtension; //! Transient user-defined extension to volumes + TGeoExtension *fFWExtension; //! Transient framework-defined extension to volumes TGeoVolume(const TGeoVolume&); TGeoVolume& operator=(const TGeoVolume&); @@ -116,7 +119,7 @@ protected : void CheckOverlaps(Double_t ovlp=0.1, Option_t *option="") const; // *MENU* void CheckShape(Int_t testNo, Int_t nsamples=10000, Option_t *option=""); // *MENU* Int_t CountNodes(Int_t nlevels=1000, Int_t option=0); - Bool_t Contains(Double_t *point) const {return fShape->Contains(point);} + Bool_t Contains(const Double_t *point) const {return fShape->Contains(point);} virtual Bool_t IsAssembly() const; virtual Bool_t IsFolder() const; Bool_t IsRunTime() const {return fShape->IsRunTimeShape();} @@ -136,6 +139,12 @@ protected : void PrintNodes() const; void PrintVoxels() const; // *MENU* void ReplayCreation(const TGeoVolume *other); + void SetUserExtension(TGeoExtension *ext); + void SetFWExtension(TGeoExtension *ext); + TGeoExtension *GetUserExtension() const {return fUserExtension;} + TGeoExtension *GetFWExtension() const {return fFWExtension;} + TGeoExtension *GrabUserExtension() const; + TGeoExtension *GrabFWExtension() const; virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py); Bool_t IsActive() const {return TGeoAtt::IsActive();} @@ -193,13 +202,13 @@ protected : TGeoVolume *MakeReflectedVolume(const char *newname="") const; Bool_t OptimizeVoxels(); // *MENU* void RandomPoints(Int_t npoints=1000000, Option_t *option=""); // *MENU* - void RandomRays(Int_t nrays=10000, Double_t startx=0, Double_t starty=0, Double_t startz=0); // *MENU* + void RandomRays(Int_t nrays=10000, Double_t startx=0, Double_t starty=0, Double_t startz=0, const char *target_vol=0, Bool_t check_norm=kFALSE); // *MENU* void Raytrace(Bool_t flag=kTRUE); // *TOGGLE* *GETTER=IsRaytracing void RegisterYourself(Option_t *option=""); void RemoveNode(TGeoNode *node); TGeoNode *ReplaceNode(TGeoNode *nodeorig, TGeoShape *newshape=0, TGeoMatrix *newpos=0, TGeoMedium *newmed=0); void SaveAs(const char *filename,Option_t *option="") const; // *MENU* - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SelectVolume(Bool_t clear = kFALSE); void SetActivity(Bool_t flag=kTRUE) {TGeoAtt::SetActivity(flag);} void SetActiveDaughters(Bool_t flag=kTRUE) {TGeoAtt::SetActiveDaughters(flag);} @@ -272,7 +281,7 @@ class TGeoVolumeMulti : public TGeoVolume virtual void AddNode(const TGeoVolume *vol, Int_t copy_no, TGeoMatrix *mat, Option_t *option=""); // most general case virtual void AddNodeOverlap(const TGeoVolume *vol, Int_t copy_no, TGeoMatrix *mat, Option_t *option=""); virtual TGeoVolume *Divide(const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step, Int_t numed=0, Option_t *option=""); - TGeoShape *GetLastShape() const {return GetVolume(fVolumes->GetEntriesFast()-1)->GetShape();} + TGeoShape *GetLastShape() const; Int_t GetNvolumes() const {return fVolumes->GetEntriesFast();} Int_t GetAxis() const {return fNdiv;} Int_t GetNdiv() const {return fNdiv;} diff --git a/geom/geom/inc/TGeoVoxelFinder.h b/geom/geom/inc/TGeoVoxelFinder.h index 32c55959c1971..8c370c01a5d01 100644 --- a/geom/geom/inc/TGeoVoxelFinder.h +++ b/geom/geom/inc/TGeoVoxelFinder.h @@ -76,7 +76,7 @@ enum EVoxelsType { Int_t *GetExtraX(Int_t islice, Bool_t left, Int_t &nextra) const; Int_t *GetExtraY(Int_t islice, Bool_t left, Int_t &nextra) const; Int_t *GetExtraZ(Int_t islice, Bool_t left, Int_t &nextra) const; - Bool_t GetIndices(Double_t *point, TGeoStateInfo &td); + Bool_t GetIndices(const Double_t *point, TGeoStateInfo &td); Int_t GetPriority(Int_t iaxis) const {return fPriority[iaxis];} Int_t GetNcandidates( TGeoStateInfo &td) const; Int_t *GetValidExtra(Int_t *list, Int_t &ncheck, TGeoStateInfo &td); @@ -101,22 +101,22 @@ public : TGeoVoxelFinder(); TGeoVoxelFinder(TGeoVolume *vol); virtual ~TGeoVoxelFinder(); - void DaughterToMother(Int_t id, Double_t *local, Double_t *master) const; + void DaughterToMother(Int_t id, const Double_t *local, Double_t *master) const; virtual Double_t Efficiency(); - virtual Int_t *GetCheckList(Double_t *point, Int_t &nelem, TGeoStateInfo &td); + virtual Int_t *GetCheckList(const Double_t *point, Int_t &nelem, TGeoStateInfo &td); Int_t *GetCheckList(Int_t &nelem, TGeoStateInfo &td) const; - virtual Int_t *GetNextCandidates(Double_t *point, Int_t &ncheck, TGeoStateInfo &td); + virtual Int_t *GetNextCandidates(const Double_t *point, Int_t &ncheck, TGeoStateInfo &td); virtual void FindOverlaps(Int_t inode) const; Bool_t IsInvalid() const {return TObject::TestBit(kGeoInvalidVoxels);} Bool_t NeedRebuild() const {return TObject::TestBit(kGeoRebuildVoxels);} Double_t *GetBoxes() const {return fBoxes;} - Bool_t IsSafeVoxel(Double_t *point, Int_t inode, Double_t minsafe) const; + Bool_t IsSafeVoxel(const Double_t *point, Int_t inode, Double_t minsafe) const; virtual void Print(Option_t *option="") const; - void PrintVoxelLimits(Double_t *point) const; + void PrintVoxelLimits(const Double_t *point) const; void SetInvalid(Bool_t flag=kTRUE) {TObject::SetBit(kGeoInvalidVoxels, flag);} void SetNeedRebuild(Bool_t flag=kTRUE) {TObject::SetBit(kGeoRebuildVoxels, flag);} - virtual Int_t *GetNextVoxel(Double_t *point, Double_t *dir, Int_t &ncheck, TGeoStateInfo &td); - virtual void SortCrossedVoxels(Double_t *point, Double_t *dir, TGeoStateInfo &td); + virtual Int_t *GetNextVoxel(const Double_t *point, const Double_t *dir, Int_t &ncheck, TGeoStateInfo &td); + virtual void SortCrossedVoxels(const Double_t *point, const Double_t *dir, TGeoStateInfo &td); virtual void Voxelize(Option_t *option=""); ClassDef(TGeoVoxelFinder, 4) // voxel finder class diff --git a/geom/geom/inc/TGeoXtru.h b/geom/geom/inc/TGeoXtru.h index e88e6688c3c84..a677cafcfe95c 100644 --- a/geom/geom/inc/TGeoXtru.h +++ b/geom/geom/inc/TGeoXtru.h @@ -64,11 +64,11 @@ class TGeoXtru : public TGeoBBox TGeoXtru& operator=(const TGeoXtru&); // methods - Double_t DistToPlane(Double_t *point, Double_t *dir, Int_t iz, Int_t ivert, Double_t stepmax, Bool_t in) const; + Double_t DistToPlane(const Double_t *point, const Double_t *dir, Int_t iz, Int_t ivert, Double_t stepmax, Bool_t in) const; void GetPlaneVertices(Int_t iz, Int_t ivert, Double_t *vert) const; void GetPlaneNormal(const Double_t *vert, Double_t *norm) const; - Bool_t IsPointInsidePlane(Double_t *point, Double_t *vert, Double_t *norm) const; - Double_t SafetyToSector(Double_t *point, Int_t iz, Double_t safmin, Bool_t in); + Bool_t IsPointInsidePlane(const Double_t *point, Double_t *vert, Double_t *norm) const; + Double_t SafetyToSector(const Double_t *point, Int_t iz, Double_t safmin, Bool_t in); void SetIz(Int_t iz); void SetSeg(Int_t iseg); @@ -82,15 +82,20 @@ class TGeoXtru : public TGeoBBox // methods virtual Double_t Capacity() const; virtual void ComputeBBox(); - virtual void ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm); - virtual Bool_t Contains(Double_t *point) const; + virtual void ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm); + virtual void ComputeNormal_v(const Double_t *points, const Double_t *dirs, Double_t *norms, Int_t vecsize); + virtual Bool_t Contains(const Double_t *point) const; + virtual void Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const; Bool_t DefinePolygon(Int_t nvert, const Double_t *xv, const Double_t *yv); virtual void DefineSection(Int_t snum, Double_t z, Double_t x0=0., Double_t y0=0., Double_t scale=1.); - virtual Double_t DistFromInside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual Double_t DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; - virtual Double_t DistFromOutside(Double_t *point, Double_t *dir, Int_t iact=1, + virtual void DistFromInside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; + virtual Double_t DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact=1, Double_t step=TGeoShape::Big(), Double_t *safe=0) const; + virtual void DistFromOutside_v(const Double_t *points, const Double_t *dirs, Double_t *dists, Int_t vecsize, Double_t *step) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); + void DrawPolygon(Option_t *option=""); virtual const TBuffer3D &GetBuffer3D(Int_t reqSections, Bool_t localFrame) const; // virtual Int_t GetByteCount() const {return 60+12*fNz;} Int_t GetNz() const {return fNz;} @@ -108,8 +113,9 @@ class TGeoXtru : public TGeoBBox virtual void InspectShape() const; virtual TBuffer3D *MakeBuffer3D() const; Double_t &Z(Int_t ipl) {return fZ[ipl];} - virtual Double_t Safety(Double_t *point, Bool_t in=kTRUE) const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual Double_t Safety(const Double_t *point, Bool_t in=kTRUE) const; + virtual void Safety_v(const Double_t *points, const Bool_t *inside, Double_t *safe, Int_t vecsize) const; + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetCurrentZ(Double_t z, Int_t iz); void SetCurrentVertices(Double_t x0, Double_t y0, Double_t scale); virtual void SetDimensions(Double_t *param); diff --git a/geom/geom/inc/TVirtualGeoPainter.h b/geom/geom/inc/TVirtualGeoPainter.h index 8ccbfb5f6e3de..ca7298f82e92f 100644 --- a/geom/geom/inc/TVirtualGeoPainter.h +++ b/geom/geom/inc/TVirtualGeoPainter.h @@ -38,6 +38,7 @@ class TH2F; class TStopwatch; class TGeoBatemanSol; class TGeoIteratorPlugin; +class TGeoPolygon; class TVirtualGeoPainter : public TObject { @@ -89,6 +90,7 @@ enum EGeoBombOption { virtual void DrawCurrentPoint(Int_t color) = 0; virtual void DrawPanel() = 0; virtual void DrawPath(const char *path) = 0; + virtual void DrawPolygon(const TGeoPolygon *poly) = 0; virtual void DrawVolume(TGeoVolume *vol, Option_t *option="") = 0; virtual void EditGeometry(Option_t *option="") = 0; virtual void EstimateCameraMove(Double_t /*tmin*/, Double_t /*tmax*/, Double_t *, Double_t * ) {;} @@ -123,7 +125,7 @@ enum EGeoBombOption { virtual void PrintOverlaps() const = 0; virtual void PaintVolume(TGeoVolume *vol, Option_t *option="", TGeoMatrix* global=0) = 0; virtual void RandomPoints(const TGeoVolume *vol, Int_t npoints, Option_t *option="") = 0; - virtual void RandomRays(Int_t nrays, Double_t startx, Double_t starty, Double_t startz) = 0; + virtual void RandomRays(Int_t nrays, Double_t startx, Double_t starty, Double_t startz, const char *target_vol, Bool_t check_norm) = 0; virtual void Raytrace(Option_t *option="") = 0; virtual TGeoNode *SamplePoints(Int_t npoints, Double_t &dist, Double_t epsil, const char* g3path) = 0; virtual void SetBombFactors(Double_t bombx=1.3, Double_t bomby=1.3, Double_t bombz=1.3, diff --git a/geom/geom/inc/TVirtualGeoTrack.h b/geom/geom/inc/TVirtualGeoTrack.h index 08ceed9e50fd1..cebc3eadde6e4 100644 --- a/geom/geom/inc/TVirtualGeoTrack.h +++ b/geom/geom/inc/TVirtualGeoTrack.h @@ -63,7 +63,7 @@ class TVirtualGeoTrack : public TObject, virtual void AddPoint(Double_t x, Double_t y, Double_t z, Double_t t) = 0; virtual TVirtualGeoTrack *FindTrackWithId(Int_t id) const; Int_t GetId() const {return fId;} - virtual Int_t GetDaughterId(Int_t index) const {return GetDaughter(index)->GetId();} + virtual Int_t GetDaughterId(Int_t index) const; TVirtualGeoTrack *GetDaughter(Int_t index) const {return (TVirtualGeoTrack*)fTracks->At(index);} TVirtualGeoTrack *GetMother() const {return fParent;} TObject *GetMotherParticle() const {return (fParent)?fParent->GetParticle():0;} diff --git a/geom/geom/src/TGeoArb8.cxx b/geom/geom/src/TGeoArb8.cxx index 7ba71a7ea70ed..223c320223836 100644 --- a/geom/geom/src/TGeoArb8.cxx +++ b/geom/geom/src/TGeoArb8.cxx @@ -339,7 +339,7 @@ Double_t TGeoArb8::GetTwist(Int_t iseg) const } //_____________________________________________________________________________ -Double_t TGeoArb8::GetClosestEdge(Double_t *point, Double_t *vert, Int_t &isegment) const +Double_t TGeoArb8::GetClosestEdge(const Double_t *point, Double_t *vert, Int_t &isegment) const { // Get index of the edge of the quadrilater represented by vert closest to point. // If [P1,P2] is the closest segment and P is the point, the function returns the fraction of the @@ -407,7 +407,7 @@ Double_t TGeoArb8::GetClosestEdge(Double_t *point, Double_t *vert, Int_t &isegme } //_____________________________________________________________________________ -void TGeoArb8::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) +void TGeoArb8::ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm) { // Compute normal to closest surface from POINT. Double_t safc; @@ -415,7 +415,7 @@ void TGeoArb8::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) Double_t ax, ay, az, bx, by, bz; Double_t fn; safc = fDz-TMath::Abs(point[2]); - if (safc0)?1:(-1); return; @@ -471,7 +471,7 @@ void TGeoArb8::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) } //_____________________________________________________________________________ -Bool_t TGeoArb8::Contains(Double_t *point) const +Bool_t TGeoArb8::Contains(const Double_t *point) const { // Test if point is inside this shape. // first check Z range @@ -490,7 +490,7 @@ Bool_t TGeoArb8::Contains(Double_t *point) const } //_____________________________________________________________________________ -Double_t TGeoArb8::DistToPlane(Double_t *point, Double_t *dir, Int_t ipl, Bool_t in) const +Double_t TGeoArb8::DistToPlane(const Double_t *point, const Double_t *dir, Int_t ipl, Bool_t in) const { // Computes distance to plane ipl : // ipl=0 : points 0,4,1,5 @@ -614,7 +614,7 @@ Double_t TGeoArb8::DistToPlane(Double_t *point, Double_t *dir, Int_t ipl, Bool_t } //_____________________________________________________________________________ -Double_t TGeoArb8::DistFromOutside(Double_t *point, Double_t *dir, Int_t /*iact*/, Double_t step, Double_t * /*safe*/) const +Double_t TGeoArb8::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t /*iact*/, Double_t step, Double_t * /*safe*/) const { // Computes distance from outside point to surface of the shape. Double_t sdist = TGeoBBox::DistFromOutside(point,dir, fDX, fDY, fDZ, fOrigin, step); @@ -641,29 +641,33 @@ Double_t TGeoArb8::DistFromOutside(Double_t *point, Double_t *dir, Int_t /*iact* } //_____________________________________________________________________________ -Double_t TGeoArb8::DistFromInside(Double_t *point, Double_t *dir, Int_t /*iact*/, Double_t /*step*/, Double_t * /*safe*/) const +Double_t TGeoArb8::DistFromInside(const Double_t *point, const Double_t *dir, Int_t /*iact*/, Double_t /*step*/, Double_t * /*safe*/) const { // Compute distance from inside point to surface of the shape. Int_t i; - Double_t dist[6]; - dist[0]=dist[1]=TGeoShape::Big(); + Double_t distz = TGeoShape::Big(); + Double_t distl = TGeoShape::Big(); + Double_t dist; + Double_t pt[3] = {0.,0.,0.}; if (dir[2]<0) { - dist[0]=(-fDz-point[2])/dir[2]; + distz=(-fDz-point[2])/dir[2]; + pt[2] = -fDz; } else { - if (dir[2]>0) dist[1]=(fDz-point[2])/dir[2]; + if (dir[2]>0) distz=(fDz-point[2])/dir[2]; + pt[2] = fDz; } for (i=0; i<4; i++) { - dist[i+2]=DistToPlane(point, dir, i, kTRUE); - } - - Double_t distmin = dist[0]; - for (i=1;i<6;i++) if (dist[i] < distmin) distmin = dist[i]; - if (distmin<0) return 0.; - if (distmin>1E10) { - Error("DistFromInside", "Big value from point=(%19.16f, %19.16f, %19.16f) dir=(%19.16f, %19.16f, %19.16f)\n", - point[0],point[1],point[2],dir[0],dir[1],dir[2]); - } - return distmin; + dist=DistToPlane(point, dir, i, kTRUE); + if (dist1.E10) return 0.; + return dist; #ifdef OLDALGORITHM //#else // compute distance to plane ipl : @@ -977,7 +981,7 @@ void TGeoArb8::InspectShape() const } //_____________________________________________________________________________ -Double_t TGeoArb8::Safety(Double_t *point, Bool_t in) const +Double_t TGeoArb8::Safety(const Double_t *point, Bool_t in) const { // Computes the closest distance from given point to this shape. Double_t safz = fDz-TMath::Abs(point[2]); @@ -1053,7 +1057,7 @@ Double_t TGeoArb8::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -Double_t TGeoArb8::SafetyToFace(Double_t *point, Int_t iseg, Bool_t in) const +Double_t TGeoArb8::SafetyToFace(const Double_t *point, Int_t iseg, Bool_t in) const { // Estimate safety to lateral plane defined by segment iseg in range [0,3] // Might be negative: plane seen only from inside. @@ -1092,29 +1096,29 @@ Double_t TGeoArb8::SafetyToFace(Double_t *point, Int_t iseg, Bool_t in) const } //_____________________________________________________________________________ -void TGeoArb8::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoArb8::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " dz = " << fDz << ";" << endl; - out << " vert[0] = " << fXY[0][0] << ";" << endl; - out << " vert[1] = " << fXY[0][1] << ";" << endl; - out << " vert[2] = " << fXY[1][0] << ";" << endl; - out << " vert[3] = " << fXY[1][1] << ";" << endl; - out << " vert[4] = " << fXY[2][0] << ";" << endl; - out << " vert[5] = " << fXY[2][1] << ";" << endl; - out << " vert[6] = " << fXY[3][0] << ";" << endl; - out << " vert[7] = " << fXY[3][1] << ";" << endl; - out << " vert[8] = " << fXY[4][0] << ";" << endl; - out << " vert[9] = " << fXY[4][1] << ";" << endl; - out << " vert[10] = " << fXY[5][0] << ";" << endl; - out << " vert[11] = " << fXY[5][1] << ";" << endl; - out << " vert[12] = " << fXY[6][0] << ";" << endl; - out << " vert[13] = " << fXY[6][1] << ";" << endl; - out << " vert[14] = " << fXY[7][0] << ";" << endl; - out << " vert[15] = " << fXY[7][1] << ";" << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoArb8(\"" << GetName() << "\", dz,vert);" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " dz = " << fDz << ";" << std::endl; + out << " vert[0] = " << fXY[0][0] << ";" << std::endl; + out << " vert[1] = " << fXY[0][1] << ";" << std::endl; + out << " vert[2] = " << fXY[1][0] << ";" << std::endl; + out << " vert[3] = " << fXY[1][1] << ";" << std::endl; + out << " vert[4] = " << fXY[2][0] << ";" << std::endl; + out << " vert[5] = " << fXY[2][1] << ";" << std::endl; + out << " vert[6] = " << fXY[3][0] << ";" << std::endl; + out << " vert[7] = " << fXY[3][1] << ";" << std::endl; + out << " vert[8] = " << fXY[4][0] << ";" << std::endl; + out << " vert[9] = " << fXY[4][1] << ";" << std::endl; + out << " vert[10] = " << fXY[5][0] << ";" << std::endl; + out << " vert[11] = " << fXY[5][1] << ";" << std::endl; + out << " vert[12] = " << fXY[6][0] << ";" << std::endl; + out << " vert[13] = " << fXY[6][1] << ";" << std::endl; + out << " vert[14] = " << fXY[7][0] << ";" << std::endl; + out << " vert[15] = " << fXY[7][1] << ";" << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoArb8(\"" << GetName() << "\", dz,vert);" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -1203,6 +1207,47 @@ void TGeoArb8::Streamer(TBuffer &R__b) } } +//_____________________________________________________________________________ +void TGeoArb8::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; i fDZ) return kFALSE; @@ -291,7 +291,8 @@ Bool_t TGeoBBox::Contains(Double_t *point) const //_____________________________________________________________________________ Bool_t TGeoBBox::Contains(const Double_t *point, Double_t dx, Double_t dy, Double_t dz, const Double_t *origin) { -// Test if point is inside this shape. +// Static method to check if point[3] is located inside a box of having dx, dy, dz +// as half-lengths. if (TMath::Abs(point[2]-origin[2]) > dz) return kFALSE; if (TMath::Abs(point[0]-origin[0]) > dx) return kFALSE; if (TMath::Abs(point[1]-origin[1]) > dy) return kFALSE; @@ -299,7 +300,7 @@ Bool_t TGeoBBox::Contains(const Double_t *point, Double_t dx, Double_t dy, Doubl } //_____________________________________________________________________________ -Double_t TGeoBBox::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoBBox::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from inside point to surface of the box. // Boundary safe algorithm. @@ -363,7 +364,7 @@ Double_t TGeoBBox::DistFromInside(const Double_t *point,const Double_t *dir, } //_____________________________________________________________________________ -Double_t TGeoBBox::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoBBox::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from outside point to surface of the box. // Boundary safe algorithm. @@ -775,7 +776,7 @@ void TGeoBBox::SetSegsAndPols(TBuffer3D &buff) const } //_____________________________________________________________________________ -Double_t TGeoBBox::Safety(Double_t *point, Bool_t in) const +Double_t TGeoBBox::Safety(const Double_t *point, Bool_t in) const { // Computes the closest distance from given point to this shape. @@ -797,23 +798,23 @@ Double_t TGeoBBox::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -void TGeoBBox::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoBBox::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " dx = " << fDX << ";" << endl; - out << " dy = " << fDY << ";" << endl; - out << " dz = " << fDZ << ";" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " dx = " << fDX << ";" << std::endl; + out << " dy = " << fDY << ";" << std::endl; + out << " dz = " << fDZ << ";" << std::endl; if (!TGeoShape::IsSameWithinTolerance(fOrigin[0],0) || !TGeoShape::IsSameWithinTolerance(fOrigin[1],0) || !TGeoShape::IsSameWithinTolerance(fOrigin[2],0)) { - out << " origin[0] = " << fOrigin[0] << ";" << endl; - out << " origin[1] = " << fOrigin[1] << ";" << endl; - out << " origin[2] = " << fOrigin[2] << ";" << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoBBox(\"" << GetName() << "\", dx,dy,dz,origin);" << endl; + out << " origin[0] = " << fOrigin[0] << ";" << std::endl; + out << " origin[1] = " << fOrigin[1] << ";" << std::endl; + out << " origin[2] = " << fOrigin[2] << ";" << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoBBox(\"" << GetName() << "\", dx,dy,dz,origin);" << std::endl; } else { - out << " TGeoShape *" << GetPointerName() << " = new TGeoBBox(\"" << GetName() << "\", dx,dy,dz);" << endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoBBox(\"" << GetName() << "\", dx,dy,dz);" << std::endl; } TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -960,3 +961,44 @@ void TGeoBBox::FillBuffer3D(TBuffer3D & buffer, Int_t reqSections, Bool_t localF buffer.SetSectionsValid(TBuffer3D::kBoundingBox); } } + +//_____________________________________________________________________________ +void TGeoBBox::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; iCreateThreadData(nthreads); + if (fRight) fRight->CreateThreadData(nthreads); TThread::UnLock(); } @@ -202,7 +205,7 @@ Bool_t TGeoBoolNode::MakeBranch(const char *expr, Bool_t left) TString sleft, sright, stransf; Int_t boolop = TGeoManager::Parse(expr, sleft, sright, stransf); if (boolop<0) { - Error("MakeBranch", "invalid expresion"); + Error("MakeBranch", "invalid expression"); return kFALSE; } TGeoShape *shape = 0; @@ -317,7 +320,32 @@ void TGeoBoolNode::RegisterMatrices() } //_____________________________________________________________________________ -void TGeoBoolNode::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +Bool_t TGeoBoolNode::ReplaceMatrix(TGeoMatrix *mat, TGeoMatrix *newmat) +{ +// Replace one of the matrices. Does not work with TGeoIdentity. Returns true +// if replacement was successful. + if (mat==gGeoIdentity || newmat==gGeoIdentity) { + Error("ReplaceMatrix", "Matrices should not be gGeoIdentity. Use default matrix constructor to repersent identities."); + return kFALSE; + } + if (!mat || !newmat) { + Error("ReplaceMatrix", "Matrices should not be null pointers."); + return kFALSE; + } + Bool_t replaced = kFALSE; + if (fLeftMat == mat) { + fLeftMat = newmat; + replaced = kTRUE; + } + if (fRightMat == mat) { + fRightMat = newmat; + replaced = kTRUE; + } + return replaced; +} + +//_____________________________________________________________________________ +void TGeoBoolNode::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". fLeft->SavePrimitive(out,option); @@ -357,8 +385,16 @@ void TGeoBoolNode::Sizeof3D() const fLeft->Sizeof3D(); fRight->Sizeof3D(); } + ClassImp(TGeoUnion) +//______________________________________________________________________________ +TGeoBoolNode *TGeoUnion::MakeClone() const +{ +// Make a clone of this. Pointers are preserved. + return new TGeoUnion(fLeft, fRight, fLeftMat, fRightMat); +} + //______________________________________________________________________________ void TGeoUnion::Paint(Option_t *option) { @@ -443,28 +479,23 @@ void TGeoUnion::ComputeBBox(Double_t &dx, Double_t &dy, Double_t &dz, Double_t * origin[1] = 0.5*(ymin+ymax); dz = 0.5*(zmax-zmin); origin[2] = 0.5*(zmin+zmax); -} +} //______________________________________________________________________________ -Bool_t TGeoUnion::Contains(Double_t *point) const +Bool_t TGeoUnion::Contains(const Double_t *point) const { // Find if a union of two shapes contains a given point Double_t local[3]; - TGeoBoolNode *node = (TGeoBoolNode*)this; fLeftMat->MasterToLocal(point, &local[0]); Bool_t inside = fLeft->Contains(&local[0]); - if (inside) { - node->SetSelected(1); - return kTRUE; - } + if (inside) return kTRUE; fRightMat->MasterToLocal(point, &local[0]); inside = fRight->Contains(&local[0]); - if (inside) node->SetSelected(2); return inside; } //_____________________________________________________________________________ -void TGeoUnion::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) +void TGeoUnion::ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm) { // Normal computation in POINT. The orientation is chosen so that DIR.dot.NORM>0. ThreadData_t& td = GetThreadData(); @@ -522,7 +553,7 @@ Int_t TGeoUnion::DistanceToPrimitive(Int_t /*px*/, Int_t /*py*/) } //______________________________________________________________________________ -Double_t TGeoUnion::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, +Double_t TGeoUnion::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Computes distance from a given point inside the shape to its boundary. @@ -548,9 +579,9 @@ Double_t TGeoUnion::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Bool_t inside2 = fRight->Contains(local); if (inside2) d2 = fRight->DistFromInside(local, rdir, 3); if (!(inside1 | inside2)) { - // May be a pathological case when the point is on the boundary + // This is a pathological case when the point is on the boundary d1 = fLeft->DistFromOutside(local1, ldir, 3); - if (d1<2.*TGeoShape::Tolerance()) { + if (d1<1.E-3) { eps = d1+TGeoShape::Tolerance(); for (i=0; i<3; i++) local1[i] += eps*ldir[i]; inside1 = kTRUE; @@ -558,7 +589,7 @@ Double_t TGeoUnion::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, d1 += eps; } else { d2 = fRight->DistFromOutside(local, rdir, 3); - if (d2<2.*TGeoShape::Tolerance()) { + if (d2<1.E-3) { eps = d2+TGeoShape::Tolerance(); for (i=0; i<3; i++) local[i] += eps*rdir[i]; inside2 = kTRUE; @@ -634,7 +665,7 @@ Double_t TGeoUnion::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, } //______________________________________________________________________________ -Double_t TGeoUnion::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, +Double_t TGeoUnion::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from a given outside point to the shape. @@ -702,7 +733,7 @@ Int_t TGeoUnion::GetNpoints() } //______________________________________________________________________________ -Double_t TGeoUnion::Safety(Double_t *point, Bool_t in) const +Double_t TGeoUnion::Safety(const Double_t *point, Bool_t in) const { // Compute safety distance for a union node; Double_t local1[3], local2[3]; @@ -721,7 +752,7 @@ Double_t TGeoUnion::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -void TGeoUnion::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGeoUnion::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". TGeoBoolNode::SavePrimitive(out,option); @@ -730,8 +761,8 @@ void TGeoUnion::SavePrimitive(ostream &out, Option_t *option /*= ""*/) out << fRight->GetPointerName() << ","; if (!fLeftMat->IsIdentity()) out << fLeftMat->GetPointerName() << ","; else out << "0,"; - if (!fRightMat->IsIdentity()) out << fRightMat->GetPointerName() << ");" << endl; - else out << "0);" << endl; + if (!fRightMat->IsIdentity()) out << fRightMat->GetPointerName() << ");" << std::endl; + else out << "0);" << std::endl; } //______________________________________________________________________________ @@ -744,6 +775,13 @@ void TGeoUnion::Sizeof3D() const ClassImp(TGeoSubtraction) +//______________________________________________________________________________ +TGeoBoolNode *TGeoSubtraction::MakeClone() const +{ +// Make a clone of this. Pointers are preserved. + return new TGeoSubtraction(fLeft, fRight, fLeftMat, fRightMat); +} + //______________________________________________________________________________ void TGeoSubtraction::Paint(Option_t *option) { @@ -821,7 +859,7 @@ void TGeoSubtraction::ComputeBBox(Double_t &dx, Double_t &dy, Double_t &dz, Doub } //_____________________________________________________________________________ -void TGeoSubtraction::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) +void TGeoSubtraction::ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm) { // Normal computation in POINT. The orientation is chosen so that DIR.dot.NORM>0. ThreadData_t& td = GetThreadData(); @@ -870,18 +908,15 @@ void TGeoSubtraction::ComputeNormal(Double_t *point, Double_t *dir, Double_t *no } //______________________________________________________________________________ -Bool_t TGeoSubtraction::Contains(Double_t *point) const +Bool_t TGeoSubtraction::Contains(const Double_t *point) const { // Find if a subtraction of two shapes contains a given point Double_t local[3]; - TGeoBoolNode *node = (TGeoBoolNode*)this; fLeftMat->MasterToLocal(point, &local[0]); Bool_t inside = fLeft->Contains(&local[0]); - if (inside) node->SetSelected(1); - else return kFALSE; + if (!inside) return kFALSE; fRightMat->MasterToLocal(point, &local[0]); inside = !fRight->Contains(&local[0]); - if (!inside) node->SetSelected(2); return inside; } @@ -893,7 +928,7 @@ Int_t TGeoSubtraction::DistanceToPrimitive(Int_t /*px*/, Int_t /*py*/) } //______________________________________________________________________________ -Double_t TGeoSubtraction::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, +Double_t TGeoSubtraction::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from a given point inside to the shape boundary. @@ -923,7 +958,7 @@ Double_t TGeoSubtraction::DistFromInside(Double_t *point, Double_t *dir, Int_t i } //______________________________________________________________________________ -Double_t TGeoSubtraction::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, +Double_t TGeoSubtraction::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from a given point outside to the shape. @@ -1015,7 +1050,7 @@ Int_t TGeoSubtraction::GetNpoints() } //______________________________________________________________________________ -Double_t TGeoSubtraction::Safety(Double_t *point, Bool_t in) const +Double_t TGeoSubtraction::Safety(const Double_t *point, Bool_t in) const { // Compute safety distance for a union node; Double_t local1[3], local2[3]; @@ -1034,7 +1069,7 @@ Double_t TGeoSubtraction::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -void TGeoSubtraction::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGeoSubtraction::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". TGeoBoolNode::SavePrimitive(out,option); @@ -1043,8 +1078,8 @@ void TGeoSubtraction::SavePrimitive(ostream &out, Option_t *option /*= ""*/) out << fRight->GetPointerName() << ","; if (!fLeftMat->IsIdentity()) out << fLeftMat->GetPointerName() << ","; else out << "0,"; - if (!fRightMat->IsIdentity()) out << fRightMat->GetPointerName() << ");" << endl; - else out << "0);" << endl; + if (!fRightMat->IsIdentity()) out << fRightMat->GetPointerName() << ");" << std::endl; + else out << "0);" << std::endl; } //______________________________________________________________________________ @@ -1056,6 +1091,13 @@ void TGeoSubtraction::Sizeof3D() const ClassImp(TGeoIntersection) +//______________________________________________________________________________ +TGeoBoolNode *TGeoIntersection::MakeClone() const +{ +// Make a clone of this. Pointers are preserved. + return new TGeoIntersection(fLeft, fRight, fLeftMat, fRightMat); +} + //______________________________________________________________________________ void TGeoIntersection::Paint(Option_t *option) { @@ -1203,7 +1245,7 @@ void TGeoIntersection::ComputeBBox(Double_t &dx, Double_t &dy, Double_t &dz, Dou } //_____________________________________________________________________________ -void TGeoIntersection::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) +void TGeoIntersection::ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm) { // Normal computation in POINT. The orientation is chosen so that DIR.dot.NORM>0. ThreadData_t& td = GetThreadData(); @@ -1252,7 +1294,7 @@ void TGeoIntersection::ComputeNormal(Double_t *point, Double_t *dir, Double_t *n } //______________________________________________________________________________ -Bool_t TGeoIntersection::Contains(Double_t *point) const +Bool_t TGeoIntersection::Contains(const Double_t *point) const { // Find if a intersection of two shapes contains a given point Double_t local[3]; @@ -1272,7 +1314,7 @@ Int_t TGeoIntersection::DistanceToPrimitive(Int_t /*px*/, Int_t /*py*/) } //______________________________________________________________________________ -Double_t TGeoIntersection::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, +Double_t TGeoIntersection::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from a given point inside to the shape boundary. @@ -1302,7 +1344,7 @@ Double_t TGeoIntersection::DistFromInside(Double_t *point, Double_t *dir, Int_t } //______________________________________________________________________________ -Double_t TGeoIntersection::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, +Double_t TGeoIntersection::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from a given point outside to the shape. @@ -1328,10 +1370,12 @@ Double_t TGeoIntersection::DistFromOutside(Double_t *point, Double_t *dir, Int_t node->SetSelected(0); Double_t snext = 0.0; if (inleft && inright) { + // It is vey likely to have a numerical issue and the point should + // be logically outside one of the shapes d1 = fLeft->DistFromInside(lpt,ldir,3); d2 = fRight->DistFromInside(rpt,rdir,3); - if (d1<2*tol) inleft = kFALSE; - if (d2<2*tol) inright = kFALSE; + if (d1<1.E-3) inleft = kFALSE; + if (d2<1.E-3) inright = kFALSE; if (inleft && inright) return snext; } @@ -1416,7 +1460,7 @@ Int_t TGeoIntersection::GetNpoints() } //______________________________________________________________________________ -Double_t TGeoIntersection::Safety(Double_t *point, Bool_t in) const +Double_t TGeoIntersection::Safety(const Double_t *point, Bool_t in) const { // Compute safety distance for a union node; Double_t local1[3], local2[3]; @@ -1435,7 +1479,7 @@ Double_t TGeoIntersection::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -void TGeoIntersection::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGeoIntersection::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". TGeoBoolNode::SavePrimitive(out,option); @@ -1444,8 +1488,8 @@ void TGeoIntersection::SavePrimitive(ostream &out, Option_t *option /*= ""*/) out << fRight->GetPointerName() << ","; if (!fLeftMat->IsIdentity()) out << fLeftMat->GetPointerName() << ","; else out << "0,"; - if (!fRightMat->IsIdentity()) out << fRightMat->GetPointerName() << ");" << endl; - else out << "0);" << endl; + if (!fRightMat->IsIdentity()) out << fRightMat->GetPointerName() << ");" << std::endl; + else out << "0);" << std::endl; } //______________________________________________________________________________ diff --git a/geom/geom/src/TGeoBranchArray.cxx b/geom/geom/src/TGeoBranchArray.cxx index a497c4a823715..3bc5cc88626e5 100644 --- a/geom/geom/src/TGeoBranchArray.cxx +++ b/geom/geom/src/TGeoBranchArray.cxx @@ -44,6 +44,7 @@ TGeoBranchArray::TGeoBranchArray(Int_t level) // Constructor. Alocates the array with a size given by level. fMaxLevel = (fLevel+1 > 10) ? fLevel+1:10; fArray = new TGeoNode*[fMaxLevel]; + fMatrix = new TGeoHMatrix(); } //______________________________________________________________________________ @@ -92,7 +93,7 @@ TGeoBranchArray& TGeoBranchArray::operator=(const TGeoBranchArray& other) fLevel = other.fLevel; if (fLevel+1) memcpy(fArray, other.fArray, (fLevel+1)*sizeof(TGeoNode*)); if (other.fMatrix) { - fMatrix = new TGeoHMatrix(); + if (!fMatrix) fMatrix = new TGeoHMatrix(); fMatrix->CopyFrom(other.fMatrix); } fClient = other.fClient; @@ -104,7 +105,7 @@ TGeoBranchArray& TGeoBranchArray::operator=(const TGeoBranchArray& other) void TGeoBranchArray::AddLevel(Int_t dindex) { // Add and extra daughter to the current path array. No validity check performed ! - if (!fLevel) { + if (fLevel<=0) { Error("AddLevel", "You must initialize from navigator or copy from another branch array first."); return; } @@ -218,6 +219,22 @@ void TGeoBranchArray::CleanMatrix() // Garbage collect the stored matrix. delete fMatrix; fMatrix = 0; } + +//______________________________________________________________________________ +void TGeoBranchArray::Init(TGeoNode **branch, TGeoMatrix *global, Int_t level) +{ +// Init the branch array from an array of nodes, the global matrix for the path and +// the level. + if (!fMatrix) fMatrix = new TGeoHMatrix(); + fMatrix->CopyFrom(global); + if (!fArray || level+1>fMaxLevel) { + delete [] fArray; + fMaxLevel = level+1; + fArray = new TGeoNode*[fMaxLevel]; + } + fLevel = level; + memcpy(fArray, branch, (fLevel+1)*sizeof(TGeoNode*)); +} //______________________________________________________________________________ void TGeoBranchArray::InitFromNavigator(TGeoNavigator *nav) @@ -228,13 +245,6 @@ void TGeoBranchArray::InitFromNavigator(TGeoNavigator *nav) Int_t level = cache->GetLevel(); if (!fMatrix) fMatrix = new TGeoHMatrix(); fMatrix->CopyFrom(cache->GetCurrentMatrix()); - if (!level) { -// TThread::Lock(); - fLevel = 0; -// TThread::UnLock(); - return; - } -// TThread::Lock(); if (!fArray || level+1>fMaxLevel) { delete [] fArray; fMaxLevel = level+1; @@ -242,7 +252,7 @@ void TGeoBranchArray::InitFromNavigator(TGeoNavigator *nav) } fLevel = level; memcpy(fArray, branch, (fLevel+1)*sizeof(TGeoNode*)); -// TThread::UnLock(); + if (nav->IsOutside()) fLevel = -1; } //______________________________________________________________________________ @@ -282,5 +292,6 @@ void TGeoBranchArray::UpdateNavigator(TGeoNavigator *nav) const { // Update the navigator to reflect the branch. nav->CdTop(); + if (fLevel<0) {nav->SetOutside(kTRUE); return;} for (Int_t i=1; iCdDown(fArray[i]); } diff --git a/geom/geom/src/TGeoCache.cxx b/geom/geom/src/TGeoCache.cxx index b249efafb7bc3..e3a8bf12ec58e 100644 --- a/geom/geom/src/TGeoCache.cxx +++ b/geom/geom/src/TGeoCache.cxx @@ -141,7 +141,8 @@ void TGeoNodeCache::BuildIdArray() void TGeoNodeCache::BuildInfoBranch() { // Bulds info branch. Navigation is possible only after this step. - if (fInfoBranch && fInfoBranch[0]) return; + if (!fInfoBranch) fInfoBranch = new TGeoStateInfo*[fGeoInfoStackSize]; + else if (fInfoBranch[0]) return; for (Int_t i=0; iComputeNormal(point,dir,norm); } //_____________________________________________________________________________ -Bool_t TGeoCompositeShape::Contains(Double_t *point) const +Bool_t TGeoCompositeShape::Contains(const Double_t *point) const { // Tests if point is inside the shape. if (fNode) return fNode->Contains(point); @@ -286,7 +286,7 @@ Int_t TGeoCompositeShape::DistancetoPrimitive(Int_t px, Int_t py) } //_____________________________________________________________________________ -Double_t TGeoCompositeShape::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, +Double_t TGeoCompositeShape::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from outside point to this composite shape. @@ -298,7 +298,7 @@ Double_t TGeoCompositeShape::DistFromOutside(Double_t *point, Double_t *dir, Int } //_____________________________________________________________________________ -Double_t TGeoCompositeShape::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, +Double_t TGeoCompositeShape::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from inside point to outside of this composite shape. @@ -453,7 +453,7 @@ void TGeoCompositeShape::RegisterYourself() } //_____________________________________________________________________________ -Double_t TGeoCompositeShape::Safety(Double_t *point, Bool_t in) const +Double_t TGeoCompositeShape::Safety(const Double_t *point, Bool_t in) const { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. @@ -462,14 +462,14 @@ Double_t TGeoCompositeShape::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -void TGeoCompositeShape::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGeoCompositeShape::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; if (fNode) fNode->SavePrimitive(out,option); - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoCompositeShape(\"" << GetName() << "\", pBoolNode);" << endl; - if (strlen(GetTitle())) out << " " << GetPointerName() << "->SetTitle(\"" << GetTitle() << "\");" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoCompositeShape(\"" << GetName() << "\", pBoolNode);" << std::endl; + if (strlen(GetTitle())) out << " " << GetPointerName() << "->SetTitle(\"" << GetTitle() << "\");" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -501,3 +501,44 @@ Int_t TGeoCompositeShape::GetNmeshVertices() const if (!fNode) return 0; return fNode->GetNpoints(); } + +//_____________________________________________________________________________ +void TGeoCompositeShape::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; i fDz) return kFALSE; @@ -252,7 +252,7 @@ Bool_t TGeoCone::Contains(Double_t *point) const } //_____________________________________________________________________________ -Double_t TGeoCone::DistFromInsideS(Double_t *point, Double_t *dir, Double_t dz, +Double_t TGeoCone::DistFromInsideS(const Double_t *point, const Double_t *dir, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2) { // Compute distance from inside point to surface of the cone (static) @@ -323,7 +323,7 @@ Double_t TGeoCone::DistFromInsideS(Double_t *point, Double_t *dir, Double_t dz, } //_____________________________________________________________________________ -Double_t TGeoCone::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoCone::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from inside point to surface of the cone // Boundary safe algorithm. @@ -338,7 +338,7 @@ Double_t TGeoCone::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Do } //_____________________________________________________________________________ -Double_t TGeoCone::DistFromOutsideS(Double_t *point, Double_t *dir, Double_t dz, +Double_t TGeoCone::DistFromOutsideS(const Double_t *point, const Double_t *dir, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2) { // Compute distance from outside point to surface of the tube @@ -468,7 +468,7 @@ Double_t TGeoCone::DistFromOutsideS(Double_t *point, Double_t *dir, Double_t dz, } //_____________________________________________________________________________ -Double_t TGeoCone::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoCone::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from outside point to surface of the tube // compute safe radius @@ -485,7 +485,7 @@ Double_t TGeoCone::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, D } //_____________________________________________________________________________ -void TGeoCone::DistToCone(Double_t *point, Double_t *dir, Double_t dz, Double_t r1, Double_t r2, +void TGeoCone::DistToCone(const Double_t *point, const Double_t *dir, Double_t dz, Double_t r1, Double_t r2, Double_t &b, Double_t &delta) { // Static method to compute distance to a conical surface with : @@ -832,92 +832,63 @@ void TGeoCone::SetSegsAndPols(TBuffer3D &buffer) const } //_____________________________________________________________________________ -Double_t TGeoCone::Safety(Double_t *point, Bool_t in) const +Double_t TGeoCone::Safety(const Double_t *point, Bool_t in) const { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. - Double_t saf[3]; -// Double_t edges[4]; -// edges[0] = edges[1] = edges[2] = edges[3] = TGeoShape::Big(); - Double_t ro1 = 0.5*(fRmin1+fRmin2); - Double_t tg1 = 0.5*(fRmin2-fRmin1)/fDz; - Double_t cr1 = 1./TMath::Sqrt(1.+tg1*tg1); - Double_t ro2 = 0.5*(fRmax1+fRmax2); - Double_t tg2 = 0.5*(fRmax2-fRmax1)/fDz; - Double_t cr2 = 1./TMath::Sqrt(1.+tg2*tg2); - + Double_t saf[4]; Double_t r=TMath::Sqrt(point[0]*point[0]+point[1]*point[1]); - Double_t rin = tg1*point[2]+ro1; - Double_t rout = tg2*point[2]+ro2; - saf[0] = fDz-TMath::Abs(point[2]); - saf[1] = (ro1>0)?((r-rin)*cr1):TGeoShape::Big(); - saf[2] = (rout-r)*cr2; - if (in) return saf[TMath::LocMin(3,saf)]; - for (Int_t i=0; i<3; i++) saf[i]=-saf[i]; - return saf[TMath::LocMax(3,saf)]; - // Compute distance to visible edges -/* - if (rfDz) edges[1] = (r-fRmin2)*(r-fRmin2) + (point[2]-fDz)*(point[2]-fDz); - if (r>rout || point[2]<-fDz) edges[2] = (r-fRmax1)*(r-fRmax1) + (point[2]+fDz)*(point[2]+fDz); - if (r>rout || point[2]>fDz) edges[3] = (r-fRmax2)*(r-fRmax2) + (point[2]-fDz)*(point[2]-fDz); - Double_t dist_edge = edges[TMath::LocMin(4,edges)]; - if (dist_edge>1.e10) dist_edge = 0; - else dist_edge = TMath::Sqrt(dist_edge); - Double_t dist_side = saf[TMath::LocMax(3,saf)]; - return TMath::Max(dist_edge,dist_side); -*/ + saf[0] = TGeoShape::SafetySeg(r,point[2], fRmin1, -fDz, fRmax1, -fDz, !in); + saf[1] = TGeoShape::SafetySeg(r,point[2], fRmax2, fDz, fRmin2, fDz, !in); + saf[2] = TGeoShape::SafetySeg(r,point[2], fRmin2, fDz, fRmin1, -fDz, !in); + saf[3] = TGeoShape::SafetySeg(r,point[2], fRmax1, -fDz, fRmax2, fDz, !in); + return saf[TMath::LocMin(4,saf)]; } //_____________________________________________________________________________ -Double_t TGeoCone::SafetyS(Double_t *point, Bool_t in, Double_t dz, Double_t rmin1, Double_t rmax1, +Double_t TGeoCone::SafetyS(const Double_t *point, Bool_t in, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, Int_t skipz) { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. - Double_t saf[3]; - Double_t ro1 = 0.5*(rmin1+rmin2); - Double_t tg1 = 0.5*(rmin2-rmin1)/dz; - Double_t cr1 = 1./TMath::Sqrt(1.+tg1*tg1); - Double_t ro2 = 0.5*(rmax1+rmax2); - Double_t tg2 = 0.5*(rmax2-rmax1)/dz; - Double_t cr2 = 1./TMath::Sqrt(1.+tg2*tg2); - + Double_t saf[4]; Double_t r=TMath::Sqrt(point[0]*point[0]+point[1]*point[1]); - Double_t rin = tg1*point[2]+ro1; - Double_t rout = tg2*point[2]+ro2; +// Double_t rin = tg1*point[2]+ro1; +// Double_t rout = tg2*point[2]+ro2; switch (skipz) { case 1: // skip lower Z plane - saf[0] = dz - point[2]; + saf[0] = TGeoShape::Big(); + saf[1] = TGeoShape::SafetySeg(r,point[2], rmax2, dz, rmin2, dz, !in); break; case 2: // skip upper Z plane - saf[0] = dz + point[2]; + saf[0] = TGeoShape::SafetySeg(r,point[2], rmin1, -dz, rmax1, -dz, !in); + saf[1] = TGeoShape::Big(); break; case 3: // skip both - saf[0] = TGeoShape::Big(); + saf[0] = saf[1] = TGeoShape::Big(); break; default: - saf[0] = dz-TMath::Abs(point[2]); + saf[0] = TGeoShape::SafetySeg(r,point[2], rmin1, -dz, rmax1, -dz, !in); + saf[1] = TGeoShape::SafetySeg(r,point[2], rmax2, dz, rmin2, dz, !in); } - saf[1] = (ro1>0)?((r-rin)*cr1):TGeoShape::Big(); - saf[2] = (rout-r)*cr2; - if (in) return saf[TMath::LocMin(3,saf)]; - for (Int_t i=0; i<3; i++) saf[i]=-saf[i]; - return saf[TMath::LocMax(3,saf)]; + // Safety to inner part + saf[2] = TGeoShape::SafetySeg(r,point[2], rmin1, -dz, rmin2, dz, in); + saf[3] = TGeoShape::SafetySeg(r,point[2], rmax1, -dz, rmax2, dz, !in); + return saf[TMath::LocMin(4,saf)]; } //_____________________________________________________________________________ -void TGeoCone::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoCone::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " dz = " << fDz << ";" << endl; - out << " rmin1 = " << fRmin1 << ";" << endl; - out << " rmax1 = " << fRmax1 << ";" << endl; - out << " rmin2 = " << fRmin2 << ";" << endl; - out << " rmax2 = " << fRmax2 << ";" << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoCone(\"" << GetName() << "\", dz,rmin1,rmax1,rmin2,rmax2);" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " dz = " << fDz << ";" << std::endl; + out << " rmin1 = " << fRmin1 << ";" << std::endl; + out << " rmax1 = " << fRmax1 << ";" << std::endl; + out << " rmin2 = " << fRmin2 << ";" << std::endl; + out << " rmax2 = " << fRmax2 << ";" << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoCone(\"" << GetName() << "\", dz,rmin1,rmax1,rmin2,rmax2);" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -1136,10 +1107,53 @@ const TBuffer3D & TGeoCone::GetBuffer3D(Int_t reqSections, Bool_t localFrame) co return buffer; } +//_____________________________________________________________________________ +void TGeoCone::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; i0)?(TMath::Abs((r-rin)*cr1)):TGeoShape::Big(); saf[2] = TMath::Abs((rout-r)*cr2); Int_t i = TMath::LocMin(3,saf); - if (((fPhi2-fPhi1)<360.) && TGeoShape::IsCloseToPhi(saf[i], point,c1,s1,c2,s2)) { - TGeoShape::NormalPhi(point,dir,norm,c1,s1,c2,s2); + if (((fPhi2-fPhi1)<360.) && TGeoShape::IsCloseToPhi(saf[i], point,fC1,fS1,fC2,fS2)) { + TGeoShape::NormalPhi(point,dir,norm,fC1,fS1,fC2,fS2); return; } if (i==0) { @@ -1309,7 +1346,7 @@ void TGeoConeSeg::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) } //_____________________________________________________________________________ -void TGeoConeSeg::ComputeNormalS(Double_t *point, Double_t *dir, Double_t *norm, +void TGeoConeSeg::ComputeNormalS(const Double_t *point, const Double_t *dir, Double_t *norm, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, Double_t c1, Double_t s1, Double_t c2, Double_t s2) { @@ -1355,7 +1392,7 @@ void TGeoConeSeg::ComputeNormalS(Double_t *point, Double_t *dir, Double_t *norm, } //_____________________________________________________________________________ -Bool_t TGeoConeSeg::Contains(Double_t *point) const +Bool_t TGeoConeSeg::Contains(const Double_t *point) const { // test if point is inside this sphere if (!TGeoCone::Contains(point)) return kFALSE; @@ -1371,7 +1408,7 @@ Bool_t TGeoConeSeg::Contains(Double_t *point) const } //_____________________________________________________________________________ -Double_t TGeoConeSeg::DistToCons(Double_t *point, Double_t *dir, Double_t r1, Double_t z1, Double_t r2, Double_t z2, Double_t phi1, Double_t phi2) +Double_t TGeoConeSeg::DistToCons(const Double_t *point, const Double_t *dir, Double_t r1, Double_t z1, Double_t r2, Double_t z2, Double_t phi1, Double_t phi2) { // Static method to compute distance to a conical surface with : // - r1, z1 - radius and Z position of lower base @@ -1445,7 +1482,7 @@ Double_t TGeoConeSeg::DistToCons(Double_t *point, Double_t *dir, Double_t r1, Do } //_____________________________________________________________________________ -Double_t TGeoConeSeg::DistFromInsideS(Double_t *point, Double_t *dir, Double_t dz, +Double_t TGeoConeSeg::DistFromInsideS(const Double_t *point, const Double_t *dir, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, Double_t c1, Double_t s1, Double_t c2, Double_t s2, Double_t cm, Double_t sm, Double_t cdfi) { @@ -1494,7 +1531,7 @@ Double_t TGeoConeSeg::DistFromInsideS(Double_t *point, Double_t *dir, Double_t d } //_____________________________________________________________________________ -Double_t TGeoConeSeg::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoConeSeg::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from inside point to surface of the tube segment if (iact<3 && safe) { @@ -1503,24 +1540,13 @@ Double_t TGeoConeSeg::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, if ((iact==1) && (*safe>step)) return TGeoShape::Big(); } if ((fPhi2-fPhi1)>=360.) return TGeoCone::DistFromInsideS(point,dir,fDz,fRmin1,fRmax1,fRmin2,fRmax2); - Double_t phi1 = fPhi1*TMath::DegToRad(); - Double_t phi2 = fPhi2*TMath::DegToRad(); - Double_t c1 = TMath::Cos(phi1); - Double_t c2 = TMath::Cos(phi2); - Double_t s1 = TMath::Sin(phi1); - Double_t s2 = TMath::Sin(phi2); - Double_t phim = 0.5*(phi1+phi2); - Double_t cm = TMath::Cos(phim); - Double_t sm = TMath::Sin(phim); - Double_t dfi = 0.5*(phi2-phi1); - Double_t cdfi = TMath::Cos(dfi); // compute distance to surface - return TGeoConeSeg::DistFromInsideS(point,dir,fDz,fRmin1,fRmax1,fRmin2,fRmax2,c1,s1,c2,s2,cm,sm,cdfi); + return TGeoConeSeg::DistFromInsideS(point,dir,fDz,fRmin1,fRmax1,fRmin2,fRmax2,fC1,fS1,fC2,fS2,fCm,fSm,fCdfi); } //_____________________________________________________________________________ -Double_t TGeoConeSeg::DistFromOutsideS(Double_t *point, Double_t *dir, Double_t dz, +Double_t TGeoConeSeg::DistFromOutsideS(const Double_t *point, const Double_t *dir, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, Double_t c1, Double_t s1, Double_t c2, Double_t s2, Double_t cm, Double_t sm, Double_t cdfi) { @@ -1794,7 +1820,7 @@ Double_t TGeoConeSeg::DistFromOutsideS(Double_t *point, Double_t *dir, Double_t } //_____________________________________________________________________________ -Double_t TGeoConeSeg::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoConeSeg::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from outside point to surface of the tube // compute safe radius @@ -1807,18 +1833,7 @@ Double_t TGeoConeSeg::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact Double_t sdist = TGeoBBox::DistFromOutside(point,dir, fDX, fDY, fDZ, fOrigin, step); if (sdist>=step) return TGeoShape::Big(); if ((fPhi2-fPhi1)>=360.) return TGeoCone::DistFromOutsideS(point,dir,fDz,fRmin1,fRmax1,fRmin2,fRmax2); - Double_t phi1 = fPhi1*TMath::DegToRad(); - Double_t phi2 = fPhi2*TMath::DegToRad(); - Double_t c1 = TMath::Cos(phi1); - Double_t c2 = TMath::Cos(phi2); - Double_t s1 = TMath::Sin(phi1); - Double_t s2 = TMath::Sin(phi2); - Double_t phim = 0.5*(phi1+phi2); - Double_t cm = TMath::Cos(phim); - Double_t sm = TMath::Sin(phim); - Double_t dfi = 0.5*(phi2-phi1); - Double_t cdfi = TMath::Cos(dfi); - return TGeoConeSeg::DistFromOutsideS(point,dir,fDz,fRmin1,fRmax1,fRmin2,fRmax2,c1,s1,c2,s2,cm,sm,cdfi); + return TGeoConeSeg::DistFromOutsideS(point,dir,fDz,fRmin1,fRmax1,fRmin2,fRmax2,fC1,fS1,fC2,fS2,fCm,fSm,fCdfi); } //_____________________________________________________________________________ @@ -2083,98 +2098,46 @@ void TGeoConeSeg::SetSegsAndPols(TBuffer3D &buffer) const } //_____________________________________________________________________________ -Double_t TGeoConeSeg::Safety(Double_t *point, Bool_t in) const +Double_t TGeoConeSeg::Safety(const Double_t *point, Bool_t in) const { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. - Double_t saf[3]; - Double_t ro1 = 0.5*(fRmin1+fRmin2); - Double_t tg1 = 0.5*(fRmin2-fRmin1)/fDz; - Double_t cr1 = 1./TMath::Sqrt(1.+tg1*tg1); - Double_t ro2 = 0.5*(fRmax1+fRmax2); - Double_t tg2 = 0.5*(fRmax2-fRmax1)/fDz; - Double_t cr2 = 1./TMath::Sqrt(1.+tg2*tg2); - - Double_t r=TMath::Sqrt(point[0]*point[0]+point[1]*point[1]); - Double_t rin = tg1*point[2]+ro1; - Double_t rout = tg2*point[2]+ro2; - Double_t safe = TGeoShape::Big(); - if (in) { - saf[0] = fDz-TMath::Abs(point[2]); - saf[1] = (r-rin)*cr1; - saf[2] = (rout-r)*cr2; - safe = saf[TMath::LocMin(3,saf)]; - } else { - saf[0] = TMath::Abs(point[2])-fDz; // positive if inside - saf[1] = (rin-r)*cr1; - saf[2] = (r-rout)*cr2; - safe = saf[TMath::LocMax(3,saf)]; - } + Double_t safe = TGeoCone::Safety(point,in); if ((fPhi2-fPhi1)>=360.) return safe; Double_t safphi = TGeoShape::SafetyPhi(point, in, fPhi1, fPhi2); - if (in) return TMath::Min(safe, safphi); + if (safe>1.E10) return safphi; return TMath::Max(safe, safphi); } //_____________________________________________________________________________ -Double_t TGeoConeSeg::SafetyS(Double_t *point, Bool_t in, Double_t dz, Double_t rmin1, Double_t rmax1, +Double_t TGeoConeSeg::SafetyS(const Double_t *point, Bool_t in, Double_t dz, Double_t rmin1, Double_t rmax1, Double_t rmin2, Double_t rmax2, Double_t phi1, Double_t phi2, Int_t skipz) { // Static method to compute the closest distance from given point to this shape. - Double_t saf[3]; - Double_t ro1 = 0.5*(rmin1+rmin2); - Double_t tg1 = 0.5*(rmin2-rmin1)/dz; - Double_t cr1 = 1./TMath::Sqrt(1.+tg1*tg1); - Double_t ro2 = 0.5*(rmax1+rmax2); - Double_t tg2 = 0.5*(rmax2-rmax1)/dz; - Double_t cr2 = 1./TMath::Sqrt(1.+tg2*tg2); - - Double_t r=TMath::Sqrt(point[0]*point[0]+point[1]*point[1]); - Double_t rin = tg1*point[2]+ro1; - Double_t rout = tg2*point[2]+ro2; - - Double_t safe = TGeoShape::Big(); - switch (skipz) { - case 1: // skip lower Z plane - saf[0] = dz - point[2]; - break; - case 2: // skip upper Z plane - saf[0] = dz + point[2]; - break; - case 3: // skip both - saf[0] = TGeoShape::Big(); - break; - default: - saf[0] = dz-TMath::Abs(point[2]); - } - saf[1] = (r-rin)*cr1; - saf[2] = (rout-r)*cr2; + Double_t safe = TGeoCone::SafetyS(point,in,dz,rmin1,rmax1,rmin2,rmax2,skipz); + if ((phi2-phi1)>=360.) return safe; Double_t safphi = TGeoShape::SafetyPhi(point,in,phi1,phi2); - if (in) { - safe = saf[TMath::LocMin(3,saf)]; - return TMath::Min(safe,safphi); - } - for (Int_t i=0; i<3; i++) saf[i]=-saf[i]; - safe = saf[TMath::LocMax(3,saf)]; - return TMath::Max(safe,safphi); + if (in) return TMath::Min(safe, safphi); + if (safe>1.E10) return safphi; + return TMath::Max(safe, safphi); } //_____________________________________________________________________________ -void TGeoConeSeg::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoConeSeg::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " dz = " << fDz << ";" << endl; - out << " rmin1 = " << fRmin1 << ";" << endl; - out << " rmax1 = " << fRmax1 << ";" << endl; - out << " rmin2 = " << fRmin2 << ";" << endl; - out << " rmax2 = " << fRmax2 << ";" << endl; - out << " phi1 = " << fPhi1 << ";" << endl; - out << " phi2 = " << fPhi2 << ";" << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoConeSeg(\"" << GetName() << "\", dz,rmin1,rmax1,rmin2,rmax2,phi1,phi2);" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " dz = " << fDz << ";" << std::endl; + out << " rmin1 = " << fRmin1 << ";" << std::endl; + out << " rmax1 = " << fRmax1 << ";" << std::endl; + out << " rmin2 = " << fRmin2 << ";" << std::endl; + out << " rmax2 = " << fRmax2 << ";" << std::endl; + out << " phi1 = " << fPhi1 << ";" << std::endl; + out << " phi2 = " << fPhi2 << ";" << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoConeSeg(\"" << GetName() << "\", dz,rmin1,rmax1,rmin2,rmax2,phi1,phi2);" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -2189,10 +2152,11 @@ void TGeoConeSeg::SetConsDimensions(Double_t dz, Double_t rmin1, Double_t rmax1, fRmin2 = rmin2; fRmax2 = rmax2; fPhi1 = phi1; - if (fPhi1<0) fPhi1+=360.; + while (fPhi1<0) fPhi1+=360.; fPhi2 = phi2; while (fPhi2<=fPhi1) fPhi2+=360.; - if (TGeoShape::IsSameWithinTolerance(fPhi1,fPhi2)) Error("SetConsDimensions", "In shape %s invalid phi1=%g, phi2=%g\n", GetName(), fPhi1, fPhi2); + if (TGeoShape::IsSameWithinTolerance(fPhi1,fPhi2)) Fatal("SetConsDimensions", "In shape %s invalid phi1=%g, phi2=%g\n", GetName(), fPhi1, fPhi2); + InitTrigonometry(); } //_____________________________________________________________________________ @@ -2404,3 +2368,44 @@ Bool_t TGeoConeSeg::GetPointsOnSegments(Int_t npoints, Double_t *array) const } return kTRUE; } + +//_____________________________________________________________________________ +void TGeoConeSeg::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; iFindIsotope(name); } @@ -505,33 +506,33 @@ TGeoElementRN *TGeoElementRN::ReadElementRN(const char *line, Int_t &ndecays) } //______________________________________________________________________________ -void TGeoElementRN::SavePrimitive(ostream &out, Option_t *option) +void TGeoElementRN::SavePrimitive(std::ostream &out, Option_t *option) { // Save primitive for RN elements. if (!strcmp(option,"h")) { // print a header if requested - out << "#====================================================================================================================================" << endl; - out << "# Name A Z ISO LEV[MeV] DM[MeV] T1/2[s] J/P ABUND[%] HTOX ITOX HTOX ITOX STAT NDCY" << endl; - out << "#====================================================================================================================================" << endl; + out << "#====================================================================================================================================" << std::endl; + out << "# Name A Z ISO LEV[MeV] DM[MeV] T1/2[s] J/P ABUND[%] HTOX ITOX HTOX ITOX STAT NDCY" << std::endl; + out << "#====================================================================================================================================" << std::endl; } - out << setw(11) << fName.Data(); - out << setw(5) << (Int_t)fA; - out << setw(5) << fZ; - out << setw(5) << fIso; - out << setw(10) << setiosflags(ios::fixed) << setprecision(5) << fLevel; - out << setw(10) << setiosflags(ios::fixed) << setprecision(5) << fDeltaM; - out << setw(10) << setiosflags(ios::scientific) << setprecision(3) << fHalfLife; - out << setw(13) << fTitle.Data(); - out << setw(10) << setiosflags(ios::fixed) << setprecision(5) << fNatAbun; - out << setw(10) << setiosflags(ios::fixed) << setprecision(5) << fTH_F; - out << setw(10) << setiosflags(ios::fixed) << setprecision(5) << fTG_F; - out << setw(10) << setiosflags(ios::fixed) << setprecision(5) << fTH_S; - out << setw(10) << setiosflags(ios::fixed) << setprecision(5) << fTG_S; - out << setw(5) << fStatus; + out << std::setw(11) << fName.Data(); + out << std::setw(5) << (Int_t)fA; + out << std::setw(5) << fZ; + out << std::setw(5) << fIso; + out << std::setw(10) << std::setiosflags(std::ios::fixed) << std::setprecision(5) << fLevel; + out << std::setw(10) << std::setiosflags(std::ios::fixed) << std::setprecision(5) << fDeltaM; + out << std::setw(10) << std::setiosflags(std::ios::scientific) << std::setprecision(3) << fHalfLife; + out << std::setw(13) << fTitle.Data(); + out << std::setw(10) << std::setiosflags(std::ios::fixed) << std::setprecision(5) << fNatAbun; + out << std::setw(10) << std::setiosflags(std::ios::fixed) << std::setprecision(5) << fTH_F; + out << std::setw(10) << std::setiosflags(std::ios::fixed) << std::setprecision(5) << fTG_F; + out << std::setw(10) << std::setiosflags(std::ios::fixed) << std::setprecision(5) << fTH_S; + out << std::setw(10) << std::setiosflags(std::ios::fixed) << std::setprecision(5) << fTG_S; + out << std::setw(5) << fStatus; Int_t ndecays = 0; if (fDecays) ndecays = fDecays->GetEntries(); - out << setw(5) << ndecays; - out << endl; + out << std::setw(5) << ndecays; + out << std::endl; if (fDecays) { TIter next(fDecays); TGeoDecayChannel *dc; @@ -638,17 +639,17 @@ TGeoDecayChannel *TGeoDecayChannel::ReadDecay(const char *line) } //______________________________________________________________________________ -void TGeoDecayChannel::SavePrimitive(ostream &out, Option_t *) +void TGeoDecayChannel::SavePrimitive(std::ostream &out, Option_t *) { // Save primitive for decays. TString decayName; DecayName(fDecay, decayName); - out << setw(50) << decayName.Data(); - out << setw(10) << fDecay; - out << setw(10) << fDiso; - out << setw(12) << setiosflags(ios::fixed) << setprecision(6) << fBranchingRatio; - out << setw(12) << setiosflags(ios::fixed) << setprecision(6) << fQvalue; - out << endl; + out << std::setw(50) << decayName.Data(); + out << std::setw(10) << fDecay; + out << std::setw(10) << fDiso; + out << std::setw(12) << std::setiosflags(std::ios::fixed) << std::setprecision(6) << fBranchingRatio; + out << std::setw(12) << std::setiosflags(std::ios::fixed) << std::setprecision(6) << fQvalue; + out << std::endl; } //______________________________________________________________________________ @@ -1094,8 +1095,8 @@ void TGeoElementTable::ExportElementsRN(const char *filename) if (!HasRNElements()) return; TString sname = filename; if (!sname.Length()) sname = "RadioNuclides.txt"; - ofstream out; - out.open(sname.Data(), ios::out); + std::ofstream out; + out.open(sname.Data(), std::ios::out); if (!out.good()) { Error("ExportElementsRN", "Cannot open file %s", sname.Data()); return; diff --git a/geom/geom/src/TGeoEltu.cxx b/geom/geom/src/TGeoEltu.cxx index a09a5da4e9e5a..802ab43baf609 100644 --- a/geom/geom/src/TGeoEltu.cxx +++ b/geom/geom/src/TGeoEltu.cxx @@ -96,7 +96,7 @@ void TGeoEltu::ComputeBBox() } //_____________________________________________________________________________ -void TGeoEltu::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) +void TGeoEltu::ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm) { // Compute normal to closest surface from POINT. Double_t a = fRmin; @@ -116,7 +116,7 @@ void TGeoEltu::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) } //_____________________________________________________________________________ -Bool_t TGeoEltu::Contains(Double_t *point) const +Bool_t TGeoEltu::Contains(const Double_t *point) const { // test if point is inside the elliptical tube if (TMath::Abs(point[2]) > fDz) return kFALSE; @@ -135,7 +135,7 @@ Int_t TGeoEltu::DistancetoPrimitive(Int_t px, Int_t py) } //_____________________________________________________________________________ -Double_t TGeoEltu::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoEltu::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from inside point to surface of the tube Double_t a2=fRmin*fRmin; @@ -206,10 +206,9 @@ Double_t TGeoEltu::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Do } //_____________________________________________________________________________ -Double_t TGeoEltu::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoEltu::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from outside point to surface of the tube and safe distance - Double_t snxt=TGeoShape::Big(); Double_t safz=TMath::Abs(point[2])-fDz; Double_t a2=fRmin*fRmin; Double_t b2=fRmax*fRmax; @@ -239,50 +238,47 @@ Double_t TGeoEltu::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, D if ((iact==1) && (step<*safe)) return TGeoShape::Big(); } // compute vector distance - if ((safz>0) && (point[2]*dir[2]>=0)) return TGeoShape::Big(); + Double_t zi, tau; + Double_t epsil = 10.*TGeoShape::Tolerance(); + if (safz > -epsil) { + // point beyond the z limit (up or down) + // Check if direction is outgoing + if (point[2]*dir[2]>0) return TGeoShape::Big(); + // Check if direction is perpendicular to Z axis + if (TGeoShape::IsSameWithinTolerance(dir[2],0)) return TGeoShape::Big(); + // select +z or -z depending on the side of the point + zi = (point[2] > 0) ? fDz : -fDz; + // Distance to zi plane position + tau = (zi-point[2])/dir[2]; + // Extrapolated coordinates at the z position of the end plane. + Double_t xz=point[0]+dir[0]*tau; + Double_t yz=point[1]+dir[1]*tau; + if ((xz*xz/a2+yz*yz/b2)<1) return tau; + } + // Check if the bounding box is crossed within the requested distance Double_t sdist = TGeoBBox::DistFromOutside(point,dir, fDX, fDY, fDZ, fOrigin, step); if (sdist>=step) return TGeoShape::Big(); - Double_t xi,yi,zi,ndotd; - if (!TGeoShape::IsSameWithinTolerance(dir[2],0)) { - Double_t u=dir[0]*dir[0]*b2+dir[1]*dir[1]*a2; - if (TGeoShape::IsSameWithinTolerance(u,0)) return TGeoShape::Big(); - Double_t v=point[0]*dir[0]*b2+point[1]*dir[1]*a2; - Double_t w=point[0]*point[0]*b2+point[1]*point[1]*a2-a2*b2; - Double_t d=v*v-u*w; - if (d<0) return TGeoShape::Big(); - Double_t dsq=TMath::Sqrt(d); - Double_t tau[2]; - tau[0]=(-v+dsq)/u; - tau[1]=(-v-dsq)/u; - for (Int_t j=0; j<2; j++) { - if (tau[j]>=0) { - zi=point[2]+tau[j]*dir[2]; - if ((TMath::Abs(zi)-fDz)<0) { - if (tau[j]<1.E-8) { - xi=point[0]+tau[j]*dir[0]; - yi=point[1]+tau[j]*dir[1]; - // Dot product of un-normalized normal with direction - ndotd = fRmax*fRmax*xi*dir[0]+fRmin*fRmin*yi*dir[1]; - if (ndotd>0) continue; - } - snxt=TMath::Min(snxt,tau[j]); - } - } - } - } - // do z - zi=TGeoShape::Big(); - if (safz>0) { - if (TGeoShape::IsSameWithinTolerance(dir[2],0)) return TGeoShape::Big(); - if (point[2]>0) zi=fDz; - if (point[2]<0) zi=-fDz; - Double_t tauz=(zi-point[2])/dir[2]; - Double_t xz=point[0]+dir[0]*tauz; - Double_t yz=point[1]+dir[1]*tauz; - if ((xz*xz/a2+yz*yz/b2)<=1) snxt=tauz; - } - return snxt; + Double_t u=dir[0]*dir[0]*b2+dir[1]*dir[1]*a2; // positive + if (TGeoShape::IsSameWithinTolerance(u,0)) return TGeoShape::Big(); + Double_t v=point[0]*dir[0]*b2+point[1]*dir[1]*a2; + Double_t w=point[0]*point[0]*b2+point[1]*point[1]*a2-a2*b2; + Double_t d=v*v-u*w; + if (d<0) return TGeoShape::Big(); + Double_t dsq=TMath::Sqrt(d); + // Biggest solution - if negative, or very close to boundary + // no crossing (just exiting, no re-entering possible) + tau = (-v+dsq)/u; + if (tau < epsil) return TGeoShape::Big(); + // only entering crossing must be considered (smallest) + tau = (-v-dsq)/u; + zi=point[2]+tau*dir[2]; + // If the crossing point is not in the Z range, there is no crossing + if ((TMath::Abs(zi)-fDz)>0) return TGeoShape::Big(); + // crossing is backwards (point inside the ellipse) in Z range + if (tau < 0) return 0.; + // Point is outside and crossing the eliptical tube in Z range + return tau; } //_____________________________________________________________________________ @@ -342,7 +338,7 @@ void TGeoEltu::InspectShape() const } //_____________________________________________________________________________ -Double_t TGeoEltu::Safety(Double_t *point, Bool_t /*in*/) const +Double_t TGeoEltu::Safety(const Double_t *point, Bool_t /*in*/) const { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. @@ -392,15 +388,15 @@ Double_t TGeoEltu::Safety(Double_t *point, Bool_t /*in*/) const } //_____________________________________________________________________________ -void TGeoEltu::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoEltu::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " a = " << fRmin << ";" << endl; - out << " b = " << fRmax << ";" << endl; - out << " dz = " << fDz << ";" << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoEltu(\"" << GetName() << "\",a,b,dz);" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " a = " << fRmin << ";" << std::endl; + out << " b = " << fRmax << ";" << std::endl; + out << " dz = " << fDz << ";" << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoEltu(\"" << GetName() << "\",a,b,dz);" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -557,3 +553,44 @@ const TBuffer3D & TGeoEltu::GetBuffer3D(Int_t reqSections, Bool_t localFrame) co return buffer; } + +//_____________________________________________________________________________ +void TGeoEltu::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; iSetUserExtension(ext); +// ext->Release(); +// // user: +// TGeoRCExtension *ext = dynamic_cast(some_TGeoVolume->GrabUserExtension()); +// // ... use extension +// ext->Release(); +// +// The extension is going to be released by the TGeoVolume holder at the destruction +// or when calling SetUserExtension(0). +// +// The following usage is not correct: +// +// some_TGeoVolume->SetUserExtension(new TGeoRCExtension()) +// +// since the producer code does not release the extension. +// One cannot call directly "delete ext" nor allocate an extension on the stack, +// since the destructor is protected. Use Release instead. diff --git a/geom/geom/src/TGeoHalfSpace.cxx b/geom/geom/src/TGeoHalfSpace.cxx index 98dcd91acd319..14bf949164d95 100644 --- a/geom/geom/src/TGeoHalfSpace.cxx +++ b/geom/geom/src/TGeoHalfSpace.cxx @@ -63,7 +63,7 @@ TGeoHalfSpace::~TGeoHalfSpace() } //_____________________________________________________________________________ -void TGeoHalfSpace::ComputeNormal(Double_t * /*point*/, Double_t *dir, Double_t *norm) +void TGeoHalfSpace::ComputeNormal(const Double_t * /*point*/, const Double_t *dir, Double_t *norm) { // Compute normal to closest surface from POINT. memcpy(norm, fN, 3*sizeof(Double_t)); @@ -75,7 +75,7 @@ void TGeoHalfSpace::ComputeNormal(Double_t * /*point*/, Double_t *dir, Double_t } //_____________________________________________________________________________ -Bool_t TGeoHalfSpace::Contains(Double_t *point) const +Bool_t TGeoHalfSpace::Contains(const Double_t *point) const { // test if point is inside the half-space Double_t r[3]; @@ -95,7 +95,7 @@ Int_t TGeoHalfSpace::DistancetoPrimitive(Int_t /*px*/, Int_t /*py*/) } //_____________________________________________________________________________ -Double_t TGeoHalfSpace::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoHalfSpace::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from inside point to the plane Double_t r[3]; @@ -118,7 +118,7 @@ Double_t TGeoHalfSpace::DistFromInside(Double_t *point, Double_t *dir, Int_t iac } //_____________________________________________________________________________ -Double_t TGeoHalfSpace::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoHalfSpace::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from inside point to the plane Double_t r[3]; @@ -168,7 +168,7 @@ void TGeoHalfSpace::InspectShape() const } //_____________________________________________________________________________ -Double_t TGeoHalfSpace::Safety(Double_t *point, Bool_t /*in*/) const +Double_t TGeoHalfSpace::Safety(const Double_t *point, Bool_t /*in*/) const { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. @@ -181,18 +181,18 @@ Double_t TGeoHalfSpace::Safety(Double_t *point, Bool_t /*in*/) const } //_____________________________________________________________________________ -void TGeoHalfSpace::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoHalfSpace::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " point[0] = " << fP[0] << ";" << endl; - out << " point[1] = " << fP[1] << ";" << endl; - out << " point[2] = " << fP[2] << ";" << endl; - out << " norm[0] = " << fN[0] << ";" << endl; - out << " norm[1] = " << fN[1] << ";" << endl; - out << " norm[2] = " << fN[2] << ";" << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoHalfSpace(\"" << GetName() << "\", point,norm);" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " point[0] = " << fP[0] << ";" << std::endl; + out << " point[1] = " << fP[1] << ";" << std::endl; + out << " point[2] = " << fP[2] << ";" << std::endl; + out << " norm[0] = " << fN[0] << ";" << std::endl; + out << " norm[1] = " << fN[1] << ";" << std::endl; + out << " norm[2] = " << fN[2] << ";" << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoHalfSpace(\"" << GetName() << "\", point,norm);" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -207,3 +207,44 @@ void TGeoHalfSpace::SetDimensions(Double_t *param) fN[1] /= nsq; fN[2] /= nsq; } + +//_____________________________________________________________________________ +void TGeoHalfSpace::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; i fDz) return kFALSE; @@ -201,7 +201,7 @@ Int_t TGeoHype::DistancetoPrimitive(Int_t px, Int_t py) } //_____________________________________________________________________________ -Double_t TGeoHype::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoHype::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from inside point to surface of the hyperboloid. if (iact<3 && safe) { @@ -240,7 +240,7 @@ Double_t TGeoHype::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Do //_____________________________________________________________________________ -Double_t TGeoHype::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoHype::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from outside point to surface of the hyperboloid. if (iact<3 && safe) { @@ -298,7 +298,7 @@ Double_t TGeoHype::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, D } //_____________________________________________________________________________ -Int_t TGeoHype::DistToHype(Double_t *point, Double_t *dir, Double_t *s, Bool_t inner, Bool_t in) const +Int_t TGeoHype::DistToHype(const Double_t *point, const Double_t *dir, Double_t *s, Bool_t inner, Bool_t in) const { // Compute distance from an arbitrary point to inner/outer surface of hyperboloid. // Returns number of positive solutions. S[2] contains the solutions. @@ -684,7 +684,7 @@ Double_t TGeoHype::ZHypeSq(Double_t r, Bool_t inner) const } //_____________________________________________________________________________ -Double_t TGeoHype::Safety(Double_t *point, Bool_t in) const +Double_t TGeoHype::Safety(const Double_t *point, Bool_t in) const { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. @@ -706,7 +706,7 @@ Double_t TGeoHype::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -Double_t TGeoHype::SafetyToHype(Double_t *point, Bool_t inner, Bool_t in) const +Double_t TGeoHype::SafetyToHype(const Double_t *point, Bool_t inner, Bool_t in) const { // Compute an underestimate of the closest distance from a point to inner or // outer infinite hyperbolas. @@ -742,17 +742,17 @@ Double_t TGeoHype::SafetyToHype(Double_t *point, Bool_t inner, Bool_t in) const } //_____________________________________________________________________________ -void TGeoHype::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoHype::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " rin = " << fRmin << ";" << endl; - out << " stin = " << fStIn << ";" << endl; - out << " rout = " << fRmax << ";" << endl; - out << " stout = " << fStOut << ";" << endl; - out << " dz = " << fDz << ";" << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoHype(\"" << GetName() << "\",rin,stin,rout,stout,dz);" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " rin = " << fRmin << ";" << std::endl; + out << " stin = " << fStIn << ";" << std::endl; + out << " rout = " << fRmax << ";" << std::endl; + out << " stout = " << fStOut << ";" << std::endl; + out << " dz = " << fDz << ";" << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoHype(\"" << GetName() << "\",rin,stin,rout,stout,dz);" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -947,3 +947,44 @@ const TBuffer3D & TGeoHype::GetBuffer3D(Int_t reqSections, Bool_t localFrame) co return buffer; } + +//_____________________________________________________________________________ +void TGeoHype::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; i + #include "Riostream.h" #include "TROOT.h" @@ -348,6 +350,7 @@ TGeoManager::TGeoManager() fDrawExtra = kFALSE; fStreamVoxels = kFALSE; fIsGeomReading = kFALSE; + fIsGeomCleaning = kFALSE; fClosed = kFALSE; fLoopVolumes = kFALSE; fBits = 0; @@ -444,6 +447,7 @@ void TGeoManager::Init() fDrawExtra = kFALSE; fStreamVoxels = kFALSE; fIsGeomReading = kFALSE; + fIsGeomCleaning = kFALSE; fClosed = kFALSE; fLoopVolumes = kFALSE; fBits = new UChar_t[50000]; // max 25000 nodes per volume @@ -522,6 +526,7 @@ TGeoManager::TGeoManager(const TGeoManager& gm) : fLoopVolumes(gm.fLoopVolumes), fStreamVoxels(gm.fStreamVoxels), fIsGeomReading(gm.fIsGeomReading), + fIsGeomCleaning(kFALSE), fPhiCut(gm.fPhiCut), fTimeCut(gm.fTimeCut), fDrawExtra(gm.fDrawExtra), @@ -601,6 +606,7 @@ TGeoManager& TGeoManager::operator=(const TGeoManager& gm) fLoopVolumes=gm.fLoopVolumes; fStreamVoxels=gm.fStreamVoxels; fIsGeomReading=gm.fIsGeomReading; + fIsGeomCleaning = kFALSE; fPhiCut=gm.fPhiCut; fTimeCut=gm.fTimeCut; fDrawExtra=gm.fDrawExtra; @@ -655,6 +661,7 @@ TGeoManager::~TGeoManager() { // Destructor if (gGeoManager != this) gGeoManager = this; + fIsGeomCleaning = kTRUE; if (gROOT->GetListOfFiles()) { //in case this function is called from TROOT destructor gROOT->GetListOfGeometries()->Remove(this); @@ -693,6 +700,7 @@ TGeoManager::~TGeoManager() delete [] fKeyPNEId; delete [] fValuePNEId; } + fIsGeomCleaning = kFALSE; gGeoIdentity = 0; gGeoManager = 0; } @@ -823,16 +831,28 @@ TGeoNavigator *TGeoManager::AddNavigator() return nav; } +TTHREAD_TLS_DECLARE(TGeoNavigator*, tnav); + //_____________________________________________________________________________ TGeoNavigator *TGeoManager::GetCurrentNavigator() const { // Returns current navigator for the calling thread. + TTHREAD_TLS_INIT(TGeoNavigator*,tnav,0); if (!fMultiThread) return fCurrentNavigator; + TGeoNavigator *nav = TTHREAD_TLS_GET(TGeoNavigator*,tnav); + if (nav) return nav; Long_t threadId = TThread::SelfId(); + + TThread::Lock(); NavigatorsMap_t::const_iterator it = fNavigators.find(threadId); - if (it == fNavigators.end()) return 0; + bool notfound = (it == fNavigators.end()); + TThread::UnLock(); + if (notfound) return 0; + TGeoNavigatorArray *array = it->second; - return array->GetCurrentNavigator(); + nav = array->GetCurrentNavigator(); + TTHREAD_TLS_SET(TGeoNavigator*,tnav,nav); + return nav; } //_____________________________________________________________________________ @@ -899,6 +919,7 @@ void TGeoManager::RemoveNavigator(const TGeoNavigator *nav) if (arr) { if ((TGeoNavigator*)arr->Remove((TObject*)nav)) { delete nav; + if (fMultiThread) TThread::UnLock(); return; } } @@ -968,10 +989,13 @@ Int_t TGeoManager::ThreadId() Int_t ttid = TTHREAD_TLS_GET(Int_t,tid); if (ttid > -1) return ttid; if (gGeoManager && !gGeoManager->IsMultiThread()) return 0; + TThread::Lock(); TGeoManager::ThreadsMapIt_t it = fgThreadId->find(TThread::SelfId()); - if (it != fgThreadId->end()) return it->second; + if (it != fgThreadId->end()) { + TThread::UnLock(); + return it->second; + } // Map needs to be updated. - TThread::Lock(); (*fgThreadId)[TThread::SelfId()] = fgNumThreads; TTHREAD_TLS_SET(Int_t,tid,fgNumThreads); fgNumThreads++; @@ -1433,6 +1457,9 @@ void TGeoManager::CloseGeometry(Option_t *option) // Create a geometry navigator if not present if (!GetCurrentNavigator()) fCurrentNavigator = AddNavigator(); nnavigators = GetListOfNavigators()->GetEntriesFast(); + TIter next(fShapes); + TGeoShape *shape; + while ((shape = (TGeoShape*)next())) shape->AfterStreamer(); Voxelize("ALL"); CountLevels(); for (Int_t i=0; iDraw(option); + if (track) track->Draw(option); } SetAnimateTracks(kFALSE); ModifiedPad(); @@ -2158,10 +2185,10 @@ void TGeoManager::OptimizeVoxels(const char *filename) Error("OptimizeVoxels","Geometry must be closed first"); return; } - ofstream out; + std::ofstream out; TString fname = filename; if (fname.IsNull()) fname = "tgeovox.C"; - out.open(fname, ios::out); + out.open(fname, std::ios::out); if (!out.good()) { Error("OptimizeVoxels", "cannot open file"); return; @@ -2170,27 +2197,27 @@ void TGeoManager::OptimizeVoxels(const char *filename) TDatime t; TString sname(fname); sname.ReplaceAll(".C", ""); - out << sname.Data()<<"()"<GetVersion()<<" : "<"<GetVersion()<<" : "<"<GetVoxels()) continue; - out<<" vol = gGeoManager->GetVolume(\""<GetName()<<"\");"<GetVolume(\""<GetName()<<"\");"<OptimizeVoxels(); if (cyltype) { - out<<" vol->SetCylVoxels();"<SetCylVoxels();"<SetCylVoxels(kFALSE);"<SetCylVoxels(kFALSE);"<GetVersion()<<" : "<"<GetVersion()<<" : "<"<GetVolume(\""<GetName()<<"\");"<ClearAttributes();"<GetGeomPainter();"<SetVisOption("<SetVisLevel("<SetExplodedView("<GetVolume(\""<GetName()<<"\");"<ClearAttributes();"<GetGeomPainter();"<SetVisOption("<SetVisLevel("<SetExplodedView("<SetBombFactors("<GetListOfVolumes());"<SetBombFactors("<GetListOfVolumes());"<SaveAttributes(out); @@ -2363,10 +2390,10 @@ void TGeoManager::SaveAttributes(const char *filename) while ((vol=(TGeoVolume*)next())) { vol->SetVisStreamed(kFALSE); } - out << " // draw top volume with new settings"<Draw();"<x3d();"<Draw();"<x3d();"<RandomRays(nrays, startx, starty, startz); + GetGeomPainter()->RandomRays(nrays, startx, starty, startz, target_vol, check_norm); } //_____________________________________________________________________________ @@ -2785,10 +2812,11 @@ TGeoVolume *TGeoManager::MakeTube(const char *name, TGeoMedium *medium, //_____________________________________________________________________________ TGeoVolume *TGeoManager::MakeTubs(const char *name, TGeoMedium *medium, Double_t rmin, Double_t rmax, Double_t dz, - Double_t phi1, Double_t phi2) + Double_t phiStart, Double_t phiEnd) { -// Make in one step a volume pointing to a tube segment shape with given medium. - return TGeoBuilder::Instance(this)->MakeTubs(name, medium, rmin, rmax, dz, phi1, phi2); + // Make in one step a volume pointing to a tube segment shape with given medium. + // The segment will be from phiStart to phiEnd, the angles are expressed in degree + return TGeoBuilder::Instance(this)->MakeTubs(name, medium, rmin, rmax, dz, phiStart, phiEnd); } //_____________________________________________________________________________ @@ -3211,9 +3239,12 @@ void TGeoManager::SetTopVolume(TGeoVolume *vol) fCurrentNavigator = AddNavigator(); return; } - Int_t nnavigators = GetListOfNavigators()->GetEntriesFast(); + Int_t nnavigators = 0; + TGeoNavigatorArray *arr = GetListOfNavigators(); + if (!arr) return; + nnavigators = arr->GetEntriesFast(); for (Int_t i=0; iAt(i); + TGeoNavigator *nav = (TGeoNavigator*)arr->At(i); nav->ResetAll(); if (fClosed) nav->GetCache()->BuildInfoBranch(); } @@ -3336,9 +3367,7 @@ void TGeoManager::CheckGeometryFull(Int_t ntracks, Double_t vx, Double_t vy, Dou //_____________________________________________________________________________ void TGeoManager::CheckGeometry(Option_t * /*option*/) { -// Instanciate a TGeoChecker object and investigates the geometry according to -// option. Not implemented yet. - // check shapes first + // Perform last checks on the geometry if (fgVerboseLevel>0) Info("CheckGeometry","Fixing runtime shapes..."); TIter next(fShapes); TIter nextv(fVolumes); @@ -3349,6 +3378,7 @@ void TGeoManager::CheckGeometry(Option_t * /*option*/) if (shape->IsRunTimeShape()) { has_runtime = kTRUE; } + if (fIsGeomReading) shape->AfterStreamer(); if (shape->TestShapeBit(TGeoShape::kGeoPcon) || shape->TestShapeBit(TGeoShape::kGeoArb8)) if (!shape->TestShapeBit(TGeoShape::kGeoClosedShape)) shape->ComputeBBox(); } @@ -3629,7 +3659,9 @@ void TGeoManager::UpdateElements() nelem = mix->GetNelements(); for (i=0; iGetElement(i); + if (!elem) continue; elem_table = fElementTable->GetElement(elem->Z()); + if (!elem_table) continue; if (elem != elem_table) { elem_table->SetDefined(elem->IsDefined()); elem_table->SetUsed(elem->IsUsed()); @@ -3639,7 +3671,9 @@ void TGeoManager::UpdateElements() } } else { elem = mat->GetElement(); + if (!elem) continue; elem_table = fElementTable->GetElement(elem->Z()); + if (!elem_table) continue; if (elem != elem_table) { elem_table->SetDefined(elem->IsDefined()); elem_table->SetUsed(elem->IsUsed()); diff --git a/geom/geom/src/TGeoMaterial.cxx b/geom/geom/src/TGeoMaterial.cxx index b5ecb0d296de4..022811cacf8fb 100644 --- a/geom/geom/src/TGeoMaterial.cxx +++ b/geom/geom/src/TGeoMaterial.cxx @@ -22,6 +22,7 @@ #include "TStyle.h" #include "TList.h" #include "TGeoManager.h" +#include "TGeoExtension.h" #include "TGeoMaterial.h" // statics and globals @@ -42,7 +43,9 @@ TGeoMaterial::TGeoMaterial() fState(kMatStateUndefined), fShader(NULL), fCerenkov(NULL), - fElement(NULL) + fElement(NULL), + fUserExtension(0), + fFWExtension(0) { // Default constructor SetUsed(kFALSE); @@ -66,7 +69,9 @@ TGeoMaterial::TGeoMaterial(const char *name) fState(kMatStateUndefined), fShader(NULL), fCerenkov(NULL), - fElement(NULL) + fElement(NULL), + fUserExtension(0), + fFWExtension(0) { // constructor fName = fName.Strip(); @@ -97,7 +102,9 @@ TGeoMaterial::TGeoMaterial(const char *name, Double_t a, Double_t z, fState(kMatStateUndefined), fShader(NULL), fCerenkov(NULL), - fElement(NULL) + fElement(NULL), + fUserExtension(0), + fFWExtension(0) { // constructor fName = fName.Strip(); @@ -115,7 +122,7 @@ TGeoMaterial::TGeoMaterial(const char *name, Double_t a, Double_t z, } if (fZ - Int_t(fZ) > 1E-3) Warning("ctor", "Material %s defined with fractional Z=%f", GetName(), fZ); - GetElement()->SetUsed(); + if (GetElement()) GetElement()->SetUsed(); gGeoManager->AddMaterial(this); } @@ -134,7 +141,9 @@ TGeoMaterial::TGeoMaterial(const char *name, Double_t a, Double_t z, Double_t rh fState(state), fShader(NULL), fCerenkov(NULL), - fElement(NULL) + fElement(NULL), + fUserExtension(0), + fFWExtension(0) { // Constructor with state, temperature and pressure. fName = fName.Strip(); @@ -146,7 +155,7 @@ TGeoMaterial::TGeoMaterial(const char *name, Double_t a, Double_t z, Double_t rh } if (fZ - Int_t(fZ) > 1E-3) Warning("ctor", "Material %s defined with fractional Z=%f", GetName(), fZ); - GetElement()->SetUsed(); + if (GetElement()) GetElement()->SetUsed(); gGeoManager->AddMaterial(this); } @@ -164,7 +173,9 @@ TGeoMaterial::TGeoMaterial(const char *name, TGeoElement *elem, Double_t rho) fState(kMatStateUndefined), fShader(NULL), fCerenkov(NULL), - fElement(elem) + fElement(elem), + fUserExtension(0), + fFWExtension(0) { // constructor fName = fName.Strip(); @@ -181,7 +192,7 @@ TGeoMaterial::TGeoMaterial(const char *name, TGeoElement *elem, Double_t rho) } if (fZ - Int_t(fZ) > 1E-3) Warning("ctor", "Material %s defined with fractional Z=%f", GetName(), fZ); - GetElement()->SetUsed(); + if (GetElement()) GetElement()->SetUsed(); gGeoManager->AddMaterial(this); } @@ -200,7 +211,10 @@ TGeoMaterial::TGeoMaterial(const TGeoMaterial& gm) : fState(gm.fState), fShader(gm.fShader), fCerenkov(gm.fCerenkov), - fElement(gm.fElement) + fElement(gm.fElement), + fUserExtension(gm.fUserExtension->Grab()), + fFWExtension(gm.fFWExtension->Grab()) + { //copy constructor } @@ -224,6 +238,8 @@ TGeoMaterial& TGeoMaterial::operator=(const TGeoMaterial& gm) fShader=gm.fShader; fCerenkov=gm.fCerenkov; fElement=gm.fElement; + fUserExtension = gm.fUserExtension->Grab(); + fFWExtension = gm.fFWExtension->Grab(); } return *this; } @@ -232,8 +248,60 @@ TGeoMaterial& TGeoMaterial::operator=(const TGeoMaterial& gm) TGeoMaterial::~TGeoMaterial() { // Destructor + if (fUserExtension) {fUserExtension->Release(); fUserExtension=0;} + if (fFWExtension) {fFWExtension->Release(); fFWExtension=0;} } +//_____________________________________________________________________________ +void TGeoMaterial::SetUserExtension(TGeoExtension *ext) +{ +// Connect user-defined extension to the material. The material "grabs" a copy, so +// the original object can be released by the producer. Release the previously +// connected extension if any. +//========================================================================== +// NOTE: This interface is intended for user extensions and is guaranteed not +// to be used by TGeo +//========================================================================== + if (fUserExtension) fUserExtension->Release(); + fUserExtension = 0; + if (ext) fUserExtension = ext->Grab(); +} + +//_____________________________________________________________________________ +void TGeoMaterial::SetFWExtension(TGeoExtension *ext) +{ +// Connect framework defined extension to the material. The material "grabs" a copy, +// so the original object can be released by the producer. Release the previously +// connected extension if any. +//========================================================================== +// NOTE: This interface is intended for the use by TGeo and the users should +// NOT connect extensions using this method +//========================================================================== + if (fFWExtension) fFWExtension->Release(); + fFWExtension = 0; + if (ext) fFWExtension = ext->Grab(); +} + +//_____________________________________________________________________________ +TGeoExtension *TGeoMaterial::GrabUserExtension() const +{ +// Get a copy of the user extension pointer. The user must call Release() on +// the copy pointer once this pointer is not needed anymore (equivalent to +// delete() after calling new()) + if (fUserExtension) return fUserExtension->Grab(); + return 0; +} + +//_____________________________________________________________________________ +TGeoExtension *TGeoMaterial::GrabFWExtension() const +{ +// Get a copy of the framework extension pointer. The user must call Release() on +// the copy pointer once this pointer is not needed anymore (equivalent to +// delete() after calling new()) + if (fFWExtension) return fFWExtension->Grab(); + return 0; +} + //_____________________________________________________________________________ char *TGeoMaterial::GetPointerName() const { @@ -276,6 +344,10 @@ void TGeoMaterial::SetRadLen(Double_t radlen, Double_t intlen) const Double_t lambda0 = 35.*g/(cm*cm); // [g/cm^2] Double_t nilinv = 0.0; TGeoElement *elem = GetElement(); + if (!elem) { + Fatal("SetRadLen", "Element not found for material %s", GetName()); + return; + } Double_t nbAtomsPerVolume = TMath::Na()*fDensity/elem->A(); nilinv += nbAtomsPerVolume*TMath::Power(elem->Neff(), 0.6666667); nilinv *= amu/lambda0; @@ -325,20 +397,20 @@ void TGeoMaterial::Print(const Option_t * /*option*/) const } //_____________________________________________________________________________ -void TGeoMaterial::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoMaterial::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TestBit(TGeoMaterial::kMatSavePrimitive)) return; char *name = GetPointerName(); - out << "// Material: " << GetName() << endl; - out << " a = " << fA << ";" << endl; - out << " z = " << fZ << ";" << endl; - out << " density = " << fDensity << ";" << endl; - out << " radl = " << fRadLen << ";" << endl; - out << " absl = " << fIntLen << ";" << endl; + out << "// Material: " << GetName() << std::endl; + out << " a = " << fA << ";" << std::endl; + out << " z = " << fZ << ";" << std::endl; + out << " density = " << fDensity << ";" << std::endl; + out << " radl = " << fRadLen << ";" << std::endl; + out << " absl = " << fIntLen << ";" << std::endl; - out << " " << name << " = new TGeoMaterial(\"" << GetName() << "\", a,z,density,radl,absl);" << endl; - out << " " << name << "->SetIndex(" << GetIndex() << ");" << endl; + out << " " << name << " = new TGeoMaterial(\"" << GetName() << "\", a,z,density,radl,absl);" << std::endl; + out << " " << name << "->SetIndex(" << GetIndex() << ");" << std::endl; SetBit(TGeoMaterial::kMatSavePrimitive); } @@ -453,6 +525,10 @@ void TGeoMaterial::FillMaterialEvolution(TObjArray *population, Double_t precisi TIter next(table->GetElementsRN()); while ((elemrn=(TGeoElementRN*)next())) elemrn->ResetRatio(); elem = GetElement(); + if (!elem) { + Fatal("FillMaterialEvolution", "Element not found for material %s", GetName()); + return; + } if (!elem->IsRadioNuclide()) { population->Add(elem); return; @@ -835,21 +911,21 @@ void TGeoMixture::Print(const Option_t * /*option*/) const } //_____________________________________________________________________________ -void TGeoMixture::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoMixture::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TestBit(TGeoMaterial::kMatSavePrimitive)) return; char *name = GetPointerName(); - out << "// Mixture: " << GetName() << endl; - out << " nel = " << fNelements << ";" << endl; - out << " density = " << fDensity << ";" << endl; - out << " " << name << " = new TGeoMixture(\"" << GetName() << "\", nel,density);" << endl; + out << "// Mixture: " << GetName() << std::endl; + out << " nel = " << fNelements << ";" << std::endl; + out << " density = " << fDensity << ";" << std::endl; + out << " " << name << " = new TGeoMixture(\"" << GetName() << "\", nel,density);" << std::endl; for (Int_t i=0; iGetName() << endl; - out << " " << name << "->DefineElement(" << i << ",a,z,w);" << endl; + out << " a = " << fAmixture[i] << "; z = "<< fZmixture[i] << "; w = " << fWeights[i] << "; // " << el->GetName() << std::endl; + out << " " << name << "->DefineElement(" << i << ",a,z,w);" << std::endl; } - out << " " << name << "->SetIndex(" << GetIndex() << ");" << endl; + out << " " << name << "->SetIndex(" << GetIndex() << ");" << std::endl; SetBit(TGeoMaterial::kMatSavePrimitive); } diff --git a/geom/geom/src/TGeoMatrix.cxx b/geom/geom/src/TGeoMatrix.cxx index a7ebc21eb970a..381e2a5afdbf5 100644 --- a/geom/geom/src/TGeoMatrix.cxx +++ b/geom/geom/src/TGeoMatrix.cxx @@ -208,7 +208,7 @@ TGeoMatrix::~TGeoMatrix() { // Destructor if (IsRegistered() && gGeoManager) { - if (gGeoManager->GetListOfVolumes()) { + if (!gGeoManager->IsCleaning()) { gGeoManager->GetListOfMatrices()->Remove(this); Warning("dtor", "Registered matrix %s was removed", GetName()); } @@ -377,7 +377,7 @@ void TGeoMatrix::LocalToMasterBomb(const Double_t *local, Double_t *master) cons } Int_t i; const Double_t *tr = GetTranslation(); - Double_t bombtr[3]; + Double_t bombtr[3] = {0.,0.,0.}; gGeoManager->BombTranslation(tr, &bombtr[0]); if (!IsRotation()) { for (i=0; i<3; i++) master[i] = bombtr[i] + local[i]; @@ -441,7 +441,7 @@ void TGeoMatrix::MasterToLocalBomb(const Double_t *master, Double_t *local) cons return; } const Double_t *tr = GetTranslation(); - Double_t bombtr[3]; + Double_t bombtr[3] = {0.,0.,0.}; Int_t i; gGeoManager->UnbombTranslation(tr, &bombtr[0]); if (!IsRotation()) { @@ -700,7 +700,7 @@ void TGeoTranslation::LocalToMasterBomb(const Double_t *local, Double_t *master) { // convert a point by multiplying its column vector (x, y, z, 1) to matrix inverse const Double_t *tr = GetTranslation(); - Double_t bombtr[3]; + Double_t bombtr[3] = {0.,0.,0.}; gGeoManager->BombTranslation(tr, &bombtr[0]); for (Int_t i=0; i<3; i++) master[i] = bombtr[i] + local[i]; @@ -727,22 +727,22 @@ void TGeoTranslation::MasterToLocalBomb(const Double_t *master, Double_t *local) { // convert a point by multiplying its column vector (x, y, z, 1) to matrix const Double_t *tr = GetTranslation(); - Double_t bombtr[3]; + Double_t bombtr[3] = {0.,0.,0.}; gGeoManager->UnbombTranslation(tr, &bombtr[0]); for (Int_t i=0; i<3; i++) local[i] = master[i]-bombtr[i]; } //_____________________________________________________________________________ -void TGeoTranslation::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoTranslation::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TestBit(kGeoSavePrimitive)) return; - out << " // Translation: " << GetName() << endl; - out << " dx = " << fTranslation[0] << ";" << endl; - out << " dy = " << fTranslation[1] << ";" << endl; - out << " dz = " << fTranslation[2] << ";" << endl; - out << " TGeoTranslation *" << GetPointerName() << " = new TGeoTranslation(\"" << GetName() << "\",dx,dy,dz);" << endl; + out << " // Translation: " << GetName() << std::endl; + out << " dx = " << fTranslation[0] << ";" << std::endl; + out << " dy = " << fTranslation[1] << ";" << std::endl; + out << " dz = " << fTranslation[2] << ";" << std::endl; + out << " TGeoTranslation *" << GetPointerName() << " = new TGeoTranslation(\"" << GetName() << "\",dx,dy,dz);" << std::endl; TObject::SetBit(kGeoSavePrimitive); } @@ -1043,17 +1043,17 @@ void TGeoRotation::ReflectZ(Bool_t leftside, Bool_t) } //_____________________________________________________________________________ -void TGeoRotation::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoRotation::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TestBit(kGeoSavePrimitive)) return; - out << " // Rotation: " << GetName() << endl; + out << " // Rotation: " << GetName() << std::endl; Double_t th1,ph1,th2,ph2,th3,ph3; GetAngles(th1,ph1,th2,ph2,th3,ph3); - out << " thx = " << th1 << "; phx = " << ph1 << ";" << endl; - out << " thy = " << th2 << "; phy = " << ph2 << ";" << endl; - out << " thz = " << th3 << "; phz = " << ph3 << ";" << endl; - out << " TGeoRotation *" << GetPointerName() << " = new TGeoRotation(\"" << GetName() << "\",thx,phx,thy,phy,thz,phz);" << endl; + out << " thx = " << th1 << "; phx = " << ph1 << ";" << std::endl; + out << " thy = " << th2 << "; phy = " << ph2 << ";" << std::endl; + out << " thz = " << th3 << "; phz = " << ph3 << ";" << std::endl; + out << " TGeoRotation *" << GetPointerName() << " = new TGeoRotation(\"" << GetName() << "\",thx,phx,thy,phy,thz,phz);" << std::endl; TObject::SetBit(kGeoSavePrimitive); } @@ -1272,6 +1272,19 @@ TGeoScale::~TGeoScale() // destructor } +//_____________________________________________________________________________ +TGeoScale &TGeoScale::operator=(const TGeoScale &other) +{ +// Assignment operator + if (&other == this) return *this; + SetBit(kGeoScale); + const Double_t *scl = other.GetScale(); + memcpy(fScale, scl, kN3); + if (fScale[0]*fScale[1]*fScale[2]<0) SetBit(kGeoReflection); + else SetBit(kGeoReflection, kFALSE); + return *this; +} + //_____________________________________________________________________________ TGeoMatrix& TGeoScale::Inverse() const { @@ -1720,21 +1733,21 @@ void TGeoCombiTrans::ReflectZ(Bool_t leftside, Bool_t rotonly) } //_____________________________________________________________________________ -void TGeoCombiTrans::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGeoCombiTrans::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TestBit(kGeoSavePrimitive)) return; - out << " // Combi transformation: " << GetName() << endl; - out << " dx = " << fTranslation[0] << ";" << endl; - out << " dy = " << fTranslation[1] << ";" << endl; - out << " dz = " << fTranslation[2] << ";" << endl; + out << " // Combi transformation: " << GetName() << std::endl; + out << " dx = " << fTranslation[0] << ";" << std::endl; + out << " dy = " << fTranslation[1] << ";" << std::endl; + out << " dz = " << fTranslation[2] << ";" << std::endl; if (fRotation && fRotation->IsRotation()) { fRotation->SavePrimitive(out,option); out << " " << GetPointerName() << " = new TGeoCombiTrans(\"" << GetName() << "\", dx,dy,dz,"; - out << fRotation->GetPointerName() << ");" << endl; + out << fRotation->GetPointerName() << ");" << std::endl; } else { - out << " " << GetPointerName() << " = new TGeoCombiTrans(\"" << GetName() << "\");" << endl; - out << " " << GetPointerName() << "->SetTranslation(dx,dy,dz);" << endl; + out << " " << GetPointerName() << " = new TGeoCombiTrans(\"" << GetName() << "\");" << std::endl; + out << " " << GetPointerName() << "->SetTranslation(dx,dy,dz);" << std::endl; } TObject::SetBit(kGeoSavePrimitive); } @@ -1888,13 +1901,13 @@ void TGeoGenTrans::Clear(Option_t *) void TGeoGenTrans::SetScale(Double_t sx, Double_t sy, Double_t sz) { // set the scale - fScale[0] = sx; - fScale[1] = sy; - fScale[2] = sz; - if (!(Normalize())) { + if (sx<1.E-5 || sy<1.E-5 || sz<1.E-5) { Error("ctor", "Invalid scale"); return; } + fScale[0] = sx; + fScale[1] = sy; + fScale[2] = sz; } //_____________________________________________________________________________ @@ -2415,23 +2428,23 @@ void TGeoHMatrix::ReflectZ(Bool_t leftside, Bool_t rotonly) } //_____________________________________________________________________________ -void TGeoHMatrix::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoHMatrix::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TestBit(kGeoSavePrimitive)) return; const Double_t *tr = fTranslation; const Double_t *rot = fRotationMatrix; - out << " // HMatrix: " << GetName() << endl; - out << " tr[0] = " << tr[0] << "; " << "tr[1] = " << tr[1] << "; " << "tr[2] = " << tr[2] << ";" << endl; - out << " rot[0] =" << rot[0] << "; " << "rot[1] = " << rot[1] << "; " << "rot[2] = " << rot[2] << ";" << endl; - out << " rot[3] =" << rot[3] << "; " << "rot[4] = " << rot[4] << "; " << "rot[5] = " << rot[5] << ";" << endl; - out << " rot[6] =" << rot[6] << "; " << "rot[7] = " << rot[7] << "; " << "rot[8] = " << rot[8] << ";" << endl; + out << " // HMatrix: " << GetName() << std::endl; + out << " tr[0] = " << tr[0] << "; " << "tr[1] = " << tr[1] << "; " << "tr[2] = " << tr[2] << ";" << std::endl; + out << " rot[0] =" << rot[0] << "; " << "rot[1] = " << rot[1] << "; " << "rot[2] = " << rot[2] << ";" << std::endl; + out << " rot[3] =" << rot[3] << "; " << "rot[4] = " << rot[4] << "; " << "rot[5] = " << rot[5] << ";" << std::endl; + out << " rot[6] =" << rot[6] << "; " << "rot[7] = " << rot[7] << "; " << "rot[8] = " << rot[8] << ";" << std::endl; char *name = GetPointerName(); - out << " TGeoHMatrix *" << name << " = new TGeoHMatrix(\"" << GetName() << "\");" << endl; - out << " " << name << "->SetTranslation(tr);" << endl; - out << " " << name << "->SetRotation(rot);" << endl; - if (IsTranslation()) out << " " << name << "->SetBit(TGeoMatrix::kGeoTranslation);" << endl; - if (IsRotation()) out << " " << name << "->SetBit(TGeoMatrix::kGeoRotation);" << endl; - if (IsReflection()) out << " " << name << "->SetBit(TGeoMatrix::kGeoReflection);" << endl; + out << " TGeoHMatrix *" << name << " = new TGeoHMatrix(\"" << GetName() << "\");" << std::endl; + out << " " << name << "->SetTranslation(tr);" << std::endl; + out << " " << name << "->SetRotation(rot);" << std::endl; + if (IsTranslation()) out << " " << name << "->SetBit(TGeoMatrix::kGeoTranslation);" << std::endl; + if (IsRotation()) out << " " << name << "->SetBit(TGeoMatrix::kGeoRotation);" << std::endl; + if (IsReflection()) out << " " << name << "->SetBit(TGeoMatrix::kGeoReflection);" << std::endl; TObject::SetBit(kGeoSavePrimitive); } diff --git a/geom/geom/src/TGeoMedium.cxx b/geom/geom/src/TGeoMedium.cxx index 75b8337cc92b7..c647686e6e981 100644 --- a/geom/geom/src/TGeoMedium.cxx +++ b/geom/geom/src/TGeoMedium.cxx @@ -122,22 +122,22 @@ char *TGeoMedium::GetPointerName() const } //_____________________________________________________________________________ -void TGeoMedium::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGeoMedium::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TestBit(TGeoMedium::kMedSavePrimitive)) return; fMaterial->SavePrimitive(out,option); - out << "// Medium: " << GetName() << endl; - out << " numed = " << fId << "; // medium number" << endl; - out << " par[0] = " << fParams[0] << "; // isvol" << endl; - out << " par[1] = " << fParams[1] << "; // ifield" << endl; - out << " par[2] = " << fParams[2] << "; // fieldm" << endl; - out << " par[3] = " << fParams[3] << "; // tmaxfd" << endl; - out << " par[4] = " << fParams[4] << "; // stemax" << endl; - out << " par[5] = " << fParams[5] << "; // deemax" << endl; - out << " par[6] = " << fParams[6] << "; // epsil" << endl; - out << " par[7] = " << fParams[7] << "; // stmin" << endl; + out << "// Medium: " << GetName() << std::endl; + out << " numed = " << fId << "; // medium number" << std::endl; + out << " par[0] = " << fParams[0] << "; // isvol" << std::endl; + out << " par[1] = " << fParams[1] << "; // ifield" << std::endl; + out << " par[2] = " << fParams[2] << "; // fieldm" << std::endl; + out << " par[3] = " << fParams[3] << "; // tmaxfd" << std::endl; + out << " par[4] = " << fParams[4] << "; // stemax" << std::endl; + out << " par[5] = " << fParams[5] << "; // deemax" << std::endl; + out << " par[6] = " << fParams[6] << "; // epsil" << std::endl; + out << " par[7] = " << fParams[7] << "; // stmin" << std::endl; - out << " " << GetPointerName() << " = new TGeoMedium(\"" << GetName() << "\", numed," << fMaterial->GetPointerName() << ", par);" << endl; + out << " " << GetPointerName() << " = new TGeoMedium(\"" << GetName() << "\", numed," << fMaterial->GetPointerName() << ", par);" << std::endl; SetBit(TGeoMedium::kMedSavePrimitive); } diff --git a/geom/geom/src/TGeoNavigator.cxx b/geom/geom/src/TGeoNavigator.cxx index cf4eaf30d962b..b26248e6685e0 100644 --- a/geom/geom/src/TGeoNavigator.cxx +++ b/geom/geom/src/TGeoNavigator.cxx @@ -288,7 +288,7 @@ Bool_t TGeoNavigator::cd(const char *path) { // Browse the tree of nodes starting from top node according to pathname. // Changes the path accordingly. - if (!strlen(path)) return kFALSE; + if (!path[0]) return kFALSE; CdTop(); TString spath = path; TGeoVolume *vol; @@ -678,7 +678,7 @@ TGeoNode *TGeoNavigator::FindNextBoundary(Double_t stepmax, const char *path, Bo fDirection[0], fDirection[1], fDirection[2]); printf(" pstep=%9.6g path=%s\n", stepmax, GetPath()); } - if (strlen(path)) { + if (path[0]) { PushPath(); if (!cd(path)) { PopPath(); @@ -868,6 +868,10 @@ TGeoNode *TGeoNavigator::FindNextBoundary(Double_t stepmax, const char *path, Bo TGeoHMatrix *matrix; while (nmany) { mothernode = GetMother(up); + if (!mothernode) { + Fatal("FindNextBoundary", "Cannot find mother node"); + return 0; + } mup = mothernode; imother = up+1; offset = kFALSE; @@ -885,6 +889,10 @@ TGeoNode *TGeoNavigator::FindNextBoundary(Double_t stepmax, const char *path, Bo } if (ovlp || nextovlp) { matrix = GetMotherMatrix(up); + if (!matrix) { + Fatal("FindNextBoundary", "Cannot find mother matrix"); + return 0; + } matrix->MasterToLocal(fPoint,dpt); matrix->MasterToLocalVect(fDirection,dvec); snext = TGeoShape::Big(); diff --git a/geom/geom/src/TGeoNode.cxx b/geom/geom/src/TGeoNode.cxx index a0e95f0306570..e794b77ab98f7 100644 --- a/geom/geom/src/TGeoNode.cxx +++ b/geom/geom/src/TGeoNode.cxx @@ -80,6 +80,7 @@ #include "TGeoNode.h" #include "TMath.h" #include "TStopwatch.h" +#include "TGeoExtension.h" // statics and globals @@ -92,8 +93,10 @@ TGeoNode::TGeoNode() fVolume = 0; fMother = 0; fNumber = 0; - fOverlaps = 0; fNovlp = 0; + fOverlaps = 0; + fUserExtension = 0; + fFWExtension = 0; } //_____________________________________________________________________________ @@ -109,8 +112,10 @@ TGeoNode::TGeoNode(const TGeoVolume *vol) fVolume->SetAdded(); fMother = 0; fNumber = 0; - fOverlaps = 0; fNovlp = 0; + fOverlaps = 0; + fUserExtension = 0; + fFWExtension = 0; } //_____________________________________________________________________________ @@ -121,7 +126,9 @@ TGeoNode::TGeoNode(const TGeoNode& gn) : fMother(gn.fMother), fNumber(gn.fNumber), fNovlp(gn.fNovlp), - fOverlaps(gn.fOverlaps) + fOverlaps(gn.fOverlaps), + fUserExtension(gn.fUserExtension->Grab()), + fFWExtension(gn.fFWExtension->Grab()) { //copy constructor } @@ -138,6 +145,8 @@ TGeoNode& TGeoNode::operator=(const TGeoNode& gn) fNumber=gn.fNumber; fNovlp=gn.fNovlp; fOverlaps=gn.fOverlaps; + fUserExtension=gn.fUserExtension->Grab(); + fFWExtension=gn.fFWExtension->Grab(); } return *this; } @@ -147,6 +156,8 @@ TGeoNode::~TGeoNode() { // Destructor if (fOverlaps) delete [] fOverlaps; + if (fUserExtension) {fUserExtension->Release(); fUserExtension=0;} + if (fFWExtension) {fFWExtension->Release(); fFWExtension=0;} } //_____________________________________________________________________________ @@ -398,7 +409,7 @@ Int_t TGeoNode::FindNode(const TGeoNode *node, Int_t level) } //_____________________________________________________________________________ -void TGeoNode::SaveAttributes(ostream &out) +void TGeoNode::SaveAttributes(std::ostream &out) { // save attributes for this node if (IsVisStreamed()) return; @@ -407,21 +418,21 @@ void TGeoNode::SaveAttributes(ostream &out) Bool_t voldef = kFALSE; if ((fVolume->IsVisTouched()) && (!fVolume->IsVisStreamed())) { fVolume->SetVisStreamed(kTRUE); - out << " vol = gGeoManager->GetVolume("<GetName()<GetVolume("<GetName()<IsVisDaughters()) - out << " vol->SetVisDaughters(kFALSE);"<SetVisDaughters(kFALSE);"<IsVisible()) { /* if (fVolume->GetLineColor() != gStyle->GetLineColor()) - out<<" vol->SetLineColor("<GetLineColor()<<");"<SetLineColor("<GetLineColor()<<");"<GetLineStyle() != gStyle->GetLineStyle()) - out<<" vol->SetLineStyle("<GetLineStyle()<<");"<SetLineStyle("<GetLineStyle()<<");"<GetLineWidth() != gStyle->GetLineWidth()) - out<<" vol->SetLineWidth("<GetLineWidth()<<");"<SetLineWidth("<GetLineWidth()<<");"<SetVisibility(kFALSE);"<SetVisibility(kFALSE);"<IsVisStreamed()) continue; if (node->IsVisTouched()) { if (!voldef) - out << " vol = gGeoManager->GetVolume("<GetName()<GetNode("<GetVolume("<GetName()<GetNode("<IsVisDaughters()) { - out<<" node->VisibleDaughters(kFALSE);"<VisibleDaughters(kFALSE);"<SetVisStreamed(kTRUE); continue; } if (!node->IsVisible()) - out<<" node->SetVisibility(kFALSE);"<SetVisibility(kFALSE);"<SaveAttributes(out); node->SetVisStreamed(kTRUE); } } +//_____________________________________________________________________________ +void TGeoNode::SetUserExtension(TGeoExtension *ext) +{ +// Connect user-defined extension to the node. The node "grabs" a copy, so +// the original object can be released by the producer. Release the previously +// connected extension if any. +//========================================================================== +// NOTE: This interface is intended for user extensions and is guaranteed not +// to be used by TGeo +//========================================================================== + if (fUserExtension) fUserExtension->Release(); + fUserExtension = 0; + if (ext) fUserExtension = ext->Grab(); +} + +//_____________________________________________________________________________ +void TGeoNode::SetFWExtension(TGeoExtension *ext) +{ +// Connect framework defined extension to the node. The node "grabs" a copy, +// so the original object can be released by the producer. Release the previously +// connected extension if any. +//========================================================================== +// NOTE: This interface is intended for the use by TGeo and the users should +// NOT connect extensions using this method +//========================================================================== + if (fFWExtension) fFWExtension->Release(); + fFWExtension = 0; + if (ext) fFWExtension = ext->Grab(); +} + +//_____________________________________________________________________________ +TGeoExtension *TGeoNode::GrabUserExtension() const +{ +// Get a copy of the user extension pointer. The user must call Release() on +// the copy pointer once this pointer is not needed anymore (equivalent to +// delete() after calling new()) + if (fUserExtension) return fUserExtension->Grab(); + return 0; +} + +//_____________________________________________________________________________ +TGeoExtension *TGeoNode::GrabFWExtension() const +{ +// Get a copy of the framework extension pointer. The user must call Release() on +// the copy pointer once this pointer is not needed anymore (equivalent to +// delete() after calling new()) + if (fFWExtension) return fFWExtension->Grab(); + return 0; +} //_____________________________________________________________________________ Bool_t TGeoNode::MayOverlap(Int_t iother) const { @@ -565,7 +625,7 @@ void TGeoNode::PrintOverlaps() const } //_____________________________________________________________________________ -Double_t TGeoNode::Safety(Double_t *point, Bool_t in) const +Double_t TGeoNode::Safety(const Double_t *point, Bool_t in) const { // computes the closest distance from given point to this shape @@ -704,6 +764,10 @@ TGeoNode *TGeoNodeMatrix::MakeCopyNode() const } // copy VC if (IsVirtual()) node->SetVirtual(); + if (IsOverlapping()) node->SetOverlapping(); // <--- ADDED + // Copy extensions + node->SetUserExtension(fUserExtension); + node->SetFWExtension(fFWExtension); return node; } @@ -792,6 +856,9 @@ TGeoNode *TGeoNodeOffset::MakeCopyNode() const if (IsVirtual()) node->SetVirtual(); // set the finder node->SetFinder(GetFinder()); + // set extensions + node->SetUserExtension(fUserExtension); + node->SetFWExtension(fFWExtension); return node; } diff --git a/geom/geom/src/TGeoPara.cxx b/geom/geom/src/TGeoPara.cxx index 8ae7cec54aa20..7b8387c5ddb80 100644 --- a/geom/geom/src/TGeoPara.cxx +++ b/geom/geom/src/TGeoPara.cxx @@ -158,7 +158,7 @@ void TGeoPara::ComputeBBox() } //_____________________________________________________________________________ -void TGeoPara::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) +void TGeoPara::ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm) { // Compute normal to closest surface from POINT. Double_t saf[3]; @@ -200,7 +200,7 @@ void TGeoPara::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) } //_____________________________________________________________________________ -Bool_t TGeoPara::Contains(Double_t *point) const +Bool_t TGeoPara::Contains(const Double_t *point) const { // test if point is inside this sphere // test Z range @@ -214,7 +214,7 @@ Bool_t TGeoPara::Contains(Double_t *point) const } //_____________________________________________________________________________ -Double_t TGeoPara::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoPara::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from inside point to surface of the para // Boundary safe algorithm. @@ -258,7 +258,7 @@ Double_t TGeoPara::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Do } //_____________________________________________________________________________ -Double_t TGeoPara::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoPara::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from inside point to surface of the para Double_t snxt=TGeoShape::Big(); @@ -527,7 +527,7 @@ void TGeoPara::InspectShape() const } //_____________________________________________________________________________ -Double_t TGeoPara::Safety(Double_t *point, Bool_t in) const +Double_t TGeoPara::Safety(const Double_t *point, Bool_t in) const { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. @@ -552,18 +552,18 @@ Double_t TGeoPara::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -void TGeoPara::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPara::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " dx = " << fX << ";" << endl; - out << " dy = " << fY << ";" << endl; - out << " dz = " << fZ << ";" << endl; - out << " alpha = " << fAlpha<< ";" << endl; - out << " theta = " << fTheta << ";" << endl; - out << " phi = " << fPhi << ";" << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoPara(\"" << GetName() << "\",dx,dy,dz,alpha,theta,phi);" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " dx = " << fX << ";" << std::endl; + out << " dy = " << fY << ";" << std::endl; + out << " dz = " << fZ << ";" << std::endl; + out << " alpha = " << fAlpha<< ";" << std::endl; + out << " theta = " << fTheta << ";" << std::endl; + out << " phi = " << fPhi << ";" << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoPara(\"" << GetName() << "\",dx,dy,dz,alpha,theta,phi);" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -627,3 +627,43 @@ void TGeoPara::Sizeof3D() const TGeoBBox::Sizeof3D(); } +//_____________________________________________________________________________ +void TGeoPara::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; ifDz) return kFALSE; @@ -167,7 +167,7 @@ Int_t TGeoParaboloid::DistancetoPrimitive(Int_t px, Int_t py) } //_____________________________________________________________________________ -Double_t TGeoParaboloid::DistToParaboloid(Double_t *point, Double_t *dir, Bool_t in) const +Double_t TGeoParaboloid::DistToParaboloid(const Double_t *point, const Double_t *dir, Bool_t in) const { // Compute distance from a point to the parabola given by: // z = a*rsq + b; rsq = x*x+y*y @@ -206,7 +206,7 @@ Double_t TGeoParaboloid::DistToParaboloid(Double_t *point, Double_t *dir, Bool_t } //_____________________________________________________________________________ -Double_t TGeoParaboloid::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoParaboloid::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from inside point to surface of the paraboloid if (iact<3 && safe) { @@ -227,7 +227,7 @@ Double_t TGeoParaboloid::DistFromInside(Double_t *point, Double_t *dir, Int_t ia } //_____________________________________________________________________________ -Double_t TGeoParaboloid::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoParaboloid::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from outside point to surface of the paraboloid and safe distance Double_t snxt = TGeoShape::Big(); @@ -397,7 +397,7 @@ void TGeoParaboloid::SetSegsAndPols(TBuffer3D &buff) const } //_____________________________________________________________________________ -Double_t TGeoParaboloid::Safety(Double_t *point, Bool_t in) const +Double_t TGeoParaboloid::Safety(const Double_t *point, Bool_t in) const { // Computes the closest distance from given point to this shape. Double_t safz = fDz-TMath::Abs(point[2]); @@ -412,11 +412,11 @@ Double_t TGeoParaboloid::Safety(Double_t *point, Bool_t in) const } Double_t dr = TMath::Sqrt(rsq)-TMath::Sqrt(r0sq); if (in) { - if (dr>0) return 0.; + if (dr>-1.E-8) return 0.; Double_t dz = TMath::Abs(point[2]-z0); safr = -dr*dz/TMath::Sqrt(dr*dr+dz*dz); } else { - if (dr<0) return safz; + if (dr<1.E-8) return safz; Double_t talf = -2.*fA*TMath::Sqrt(r0sq); Double_t salf = talf/TMath::Sqrt(1.+talf*talf); safr = TMath::Abs(dr*salf); @@ -532,15 +532,15 @@ Int_t TGeoParaboloid::GetNmeshVertices() const } //_____________________________________________________________________________ -void TGeoParaboloid::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoParaboloid::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " rlo = " << fRlo << ";" << endl; - out << " rhi = " << fRhi << ";" << endl; - out << " dz = " << fDZ << ";" << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoParaboloid(\"" << GetName() << "\", rlo,rhi,dz);" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " rlo = " << fRlo << ";" << std::endl; + out << " rhi = " << fRhi << ";" << std::endl; + out << " dz = " << fDZ << ";" << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoParaboloid(\"" << GetName() << "\", rlo,rhi,dz);" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -626,3 +626,44 @@ const TBuffer3D & TGeoParaboloid::GetBuffer3D(Int_t reqSections, Bool_t localFra return buffer; } + +//_____________________________________________________________________________ +void TGeoParaboloid::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; iRegisterYourself(); + return matrix; + } TGeoCombiTrans *combi = new TGeoCombiTrans(); + combi->RegisterYourself(); combi->ReflectZ(kTRUE); combi->ReflectZ(kFALSE); return combi; @@ -395,7 +400,7 @@ TGeoPatternFinder *TGeoPatternX::MakeCopy(Bool_t reflect) } //______________________________________________________________________________ -void TGeoPatternX::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPatternX::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". Int_t iaxis = 1; @@ -487,11 +492,16 @@ void TGeoPatternY::cd(Int_t idiv) TGeoMatrix* TGeoPatternY::CreateMatrix() const { // Return new matrix of type used by this finder. - if (!IsReflected()) return new TGeoTranslation(0.,0.,0.); + if (!IsReflected()) { + TGeoMatrix *matrix = new TGeoTranslation(0.,0.,0.); + matrix->RegisterYourself(); + return matrix; + } TGeoCombiTrans *combi = new TGeoCombiTrans(); + combi->RegisterYourself(); combi->ReflectZ(kTRUE); combi->ReflectZ(kFALSE); - return combi; + return combi; } //_____________________________________________________________________________ @@ -565,7 +575,7 @@ TGeoPatternFinder *TGeoPatternY::MakeCopy(Bool_t reflect) } //______________________________________________________________________________ -void TGeoPatternY::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPatternY::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". Int_t iaxis = 2; @@ -653,8 +663,13 @@ void TGeoPatternZ::cd(Int_t idiv) TGeoMatrix* TGeoPatternZ::CreateMatrix() const { // Return new matrix of type used by this finder. - if (!IsReflected()) return new TGeoTranslation(0.,0.,0.); + if (!IsReflected()) { + TGeoMatrix *matrix = new TGeoTranslation(0.,0.,0.); + matrix->RegisterYourself(); + return matrix; + } TGeoCombiTrans *combi = new TGeoCombiTrans(); + combi->RegisterYourself(); combi->ReflectZ(kTRUE); combi->ReflectZ(kFALSE); return combi; @@ -731,7 +746,7 @@ TGeoPatternFinder *TGeoPatternZ::MakeCopy(Bool_t reflect) } //______________________________________________________________________________ -void TGeoPatternZ::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPatternZ::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". Int_t iaxis = 3; @@ -868,7 +883,7 @@ TGeoPatternFinder *TGeoPatternParaX::MakeCopy(Bool_t reflect) } //______________________________________________________________________________ -void TGeoPatternParaX::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPatternParaX::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". Int_t iaxis = 1; @@ -879,8 +894,13 @@ void TGeoPatternParaX::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""* TGeoMatrix* TGeoPatternParaX::CreateMatrix() const { // Return new matrix of type used by this finder. - if (!IsReflected()) return new TGeoTranslation(0.,0.,0.); + if (!IsReflected()) { + TGeoMatrix *matrix = new TGeoTranslation(0.,0.,0.); + matrix->RegisterYourself(); + return matrix; + } TGeoCombiTrans *combi = new TGeoCombiTrans(); + combi->RegisterYourself(); combi->ReflectZ(kTRUE); combi->ReflectZ(kFALSE); return combi; @@ -1024,7 +1044,7 @@ TGeoPatternFinder *TGeoPatternParaY::MakeCopy(Bool_t reflect) } //______________________________________________________________________________ -void TGeoPatternParaY::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPatternParaY::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". Int_t iaxis = 2; @@ -1035,8 +1055,13 @@ void TGeoPatternParaY::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""* TGeoMatrix* TGeoPatternParaY::CreateMatrix() const { // Return new matrix of type used by this finder. - if (!IsReflected()) return new TGeoTranslation(0.,0.,0.); + if (!IsReflected()) { + TGeoMatrix *matrix = new TGeoTranslation(0.,0.,0.); + matrix->RegisterYourself(); + return matrix; + } TGeoCombiTrans *combi = new TGeoCombiTrans(); + combi->RegisterYourself(); combi->ReflectZ(kTRUE); combi->ReflectZ(kFALSE); return combi; @@ -1184,7 +1209,7 @@ TGeoPatternFinder *TGeoPatternParaZ::MakeCopy(Bool_t reflect) } //______________________________________________________________________________ -void TGeoPatternParaZ::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPatternParaZ::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". Int_t iaxis = 3; @@ -1195,8 +1220,13 @@ void TGeoPatternParaZ::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""* TGeoMatrix* TGeoPatternParaZ::CreateMatrix() const { // Return new matrix of type used by this finder. - if (!IsReflected()) return new TGeoTranslation(0.,0.,0.); + if (!IsReflected()) { + TGeoMatrix *matrix = new TGeoTranslation(0.,0.,0.); + matrix->RegisterYourself(); + return matrix; + } TGeoCombiTrans *combi = new TGeoCombiTrans(); + combi->RegisterYourself(); combi->ReflectZ(kTRUE); combi->ReflectZ(kFALSE); return combi; @@ -1353,7 +1383,7 @@ TGeoPatternFinder *TGeoPatternTrapZ::MakeCopy(Bool_t reflect) } //______________________________________________________________________________ -void TGeoPatternTrapZ::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPatternTrapZ::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". Int_t iaxis = 3; @@ -1364,8 +1394,13 @@ void TGeoPatternTrapZ::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""* TGeoMatrix* TGeoPatternTrapZ::CreateMatrix() const { // Return new matrix of type used by this finder. - if (!IsReflected()) return new TGeoTranslation(0.,0.,0.); + if (!IsReflected()) { + TGeoMatrix *matrix = new TGeoTranslation(0.,0.,0.); + matrix->RegisterYourself(); + return matrix; + } TGeoCombiTrans *combi = new TGeoCombiTrans(); + combi->RegisterYourself(); combi->ReflectZ(kTRUE); combi->ReflectZ(kFALSE); return combi; @@ -1497,7 +1532,7 @@ TGeoPatternFinder *TGeoPatternCylR::MakeCopy(Bool_t reflect) } //______________________________________________________________________________ -void TGeoPatternCylR::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPatternCylR::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". Int_t iaxis = 1; @@ -1647,7 +1682,7 @@ TGeoPatternFinder *TGeoPatternCylPhi::MakeCopy(Bool_t reflect) } //______________________________________________________________________________ -void TGeoPatternCylPhi::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPatternCylPhi::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". Int_t iaxis = 2; @@ -1676,8 +1711,13 @@ void TGeoPatternCylPhi::Streamer(TBuffer &R__b) TGeoMatrix* TGeoPatternCylPhi::CreateMatrix() const { // Return new matrix of type used by this finder. - if (!IsReflected()) return new TGeoRotation(); + if (!IsReflected()) { + TGeoRotation *matrix = new TGeoRotation(); + matrix->RegisterYourself(); + return matrix; + } TGeoRotation *rot = new TGeoRotation(); + rot->RegisterYourself(); rot->ReflectZ(kTRUE); rot->ReflectZ(kFALSE); return rot; @@ -1776,7 +1816,7 @@ TGeoPatternFinder *TGeoPatternSphR::MakeCopy(Bool_t) } //______________________________________________________________________________ -void TGeoPatternSphR::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPatternSphR::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". Int_t iaxis = 1; @@ -1880,7 +1920,7 @@ TGeoPatternFinder *TGeoPatternSphTheta::MakeCopy(Bool_t) } //______________________________________________________________________________ -void TGeoPatternSphTheta::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPatternSphTheta::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". Int_t iaxis = 2; @@ -1984,7 +2024,7 @@ TGeoPatternFinder *TGeoPatternSphPhi::MakeCopy(Bool_t) } //______________________________________________________________________________ -void TGeoPatternSphPhi::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPatternSphPhi::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". Int_t iaxis = 3; diff --git a/geom/geom/src/TGeoPcon.cxx b/geom/geom/src/TGeoPcon.cxx index 56ff4dd22b3e1..f1d330f2a102d 100644 --- a/geom/geom/src/TGeoPcon.cxx +++ b/geom/geom/src/TGeoPcon.cxx @@ -66,7 +66,15 @@ TGeoPcon::TGeoPcon() fDphi(0.), fRmin(NULL), fRmax(NULL), - fZ(NULL) + fZ(NULL), + fFullPhi(kFALSE), + fC1(0.), + fS1(0.), + fC2(0.), + fS2(0.), + fCm(0.), + fSm(0.), + fCdphi(0.) { // dummy ctor SetShapeBit(TGeoShape::kGeoPcon); @@ -80,17 +88,36 @@ TGeoPcon::TGeoPcon(Double_t phi, Double_t dphi, Int_t nz) fDphi(dphi), fRmin(NULL), fRmax(NULL), - fZ(NULL) + fZ(NULL), + fFullPhi(kFALSE), + fC1(0.), + fS1(0.), + fC2(0.), + fS2(0.), + fCm(0.), + fSm(0.), + fCdphi(0.) { // Default constructor SetShapeBit(TGeoShape::kGeoPcon); - if (fPhi1<0) fPhi1+=360.; + while (fPhi1<0) fPhi1+=360.; fRmin = new Double_t [nz]; fRmax = new Double_t [nz]; fZ = new Double_t [nz]; memset(fRmin, 0, nz*sizeof(Double_t)); memset(fRmax, 0, nz*sizeof(Double_t)); memset(fZ, 0, nz*sizeof(Double_t)); + if (TGeoShape::IsSameWithinTolerance(fDphi,360)) fFullPhi = kTRUE; + Double_t phi1 = fPhi1; + Double_t phi2 = phi1+fDphi; + Double_t phim = 0.5*(phi1+phi2); + fC1 = TMath::Cos(phi1*TMath::DegToRad()); + fS1 = TMath::Sin(phi1*TMath::DegToRad()); + fC2 = TMath::Cos(phi2*TMath::DegToRad()); + fS2 = TMath::Sin(phi2*TMath::DegToRad()); + fCm = TMath::Cos(phim*TMath::DegToRad()); + fSm = TMath::Sin(phim*TMath::DegToRad()); + fCdphi = TMath::Cos(0.5*fDphi*TMath::DegToRad()); } //_____________________________________________________________________________ @@ -101,17 +128,36 @@ TGeoPcon::TGeoPcon(const char *name, Double_t phi, Double_t dphi, Int_t nz) fDphi(dphi), fRmin(NULL), fRmax(NULL), - fZ(NULL) + fZ(NULL), + fFullPhi(kFALSE), + fC1(0.), + fS1(0.), + fC2(0.), + fS2(0.), + fCm(0.), + fSm(0.), + fCdphi(0.) { // Default constructor SetShapeBit(TGeoShape::kGeoPcon); - if (fPhi1<0) fPhi1+=360.; + while (fPhi1<0) fPhi1+=360.; fRmin = new Double_t [nz]; fRmax = new Double_t [nz]; fZ = new Double_t [nz]; memset(fRmin, 0, nz*sizeof(Double_t)); memset(fRmax, 0, nz*sizeof(Double_t)); memset(fZ, 0, nz*sizeof(Double_t)); + if (TGeoShape::IsSameWithinTolerance(fDphi,360)) fFullPhi = kTRUE; + Double_t phi1 = fPhi1; + Double_t phi2 = phi1+fDphi; + Double_t phim = 0.5*(phi1+phi2); + fC1 = TMath::Cos(phi1*TMath::DegToRad()); + fS1 = TMath::Sin(phi1*TMath::DegToRad()); + fC2 = TMath::Cos(phi2*TMath::DegToRad()); + fS2 = TMath::Sin(phi2*TMath::DegToRad()); + fCm = TMath::Cos(phim*TMath::DegToRad()); + fSm = TMath::Sin(phim*TMath::DegToRad()); + fCdphi = TMath::Cos(0.5*fDphi*TMath::DegToRad()); } //_____________________________________________________________________________ @@ -122,7 +168,15 @@ TGeoPcon::TGeoPcon(Double_t *param) fDphi(0.), fRmin(0), fRmax(0), - fZ(0) + fZ(0), + fFullPhi(kFALSE), + fC1(0.), + fS1(0.), + fC2(0.), + fS2(0.), + fCm(0.), + fSm(0.), + fCdphi(0.) { // Default constructor in GEANT3 style // param[0] = phi1 @@ -141,12 +195,20 @@ TGeoPcon::TGeoPcon(Double_t *param) //_____________________________________________________________________________ TGeoPcon::TGeoPcon(const TGeoPcon& pc) : TGeoBBox(pc), - fNz(pc.fNz), - fPhi1(pc.fPhi1), - fDphi(pc.fDphi), - fRmin(pc.fRmin), - fRmax(pc.fRmax), - fZ(pc.fZ) + fNz(0), + fPhi1(0.), + fDphi(0.), + fRmin(0), + fRmax(0), + fZ(0), + fFullPhi(kFALSE), + fC1(0.), + fS1(0.), + fC2(0.), + fS2(0.), + fCm(0.), + fSm(0.), + fCdphi(0.) { //copy constructor } @@ -157,12 +219,20 @@ TGeoPcon& TGeoPcon::operator=(const TGeoPcon& pc) //assignment operator if(this!=&pc) { TGeoBBox::operator=(pc); - fNz=pc.fNz; - fPhi1=pc.fPhi1; - fDphi=pc.fDphi; - fRmin=pc.fRmin; - fRmax=pc.fRmax; - fZ=pc.fZ; + fNz=0; + fPhi1=0.; + fDphi=0.; + fRmin=0; + fRmax=0; + fZ=0; + fFullPhi=kFALSE; + fC1=0; + fS1=0; + fC2=0; + fS2=0; + fCm=0; + fSm=0; + fCdphi=0; } return *this; } @@ -222,35 +292,33 @@ void TGeoPcon::ComputeBBox() Double_t rmin, rmax; rmin = fRmin[TMath::LocMin(fNz, fRmin)]; rmax = fRmax[TMath::LocMax(fNz, fRmax)]; - Double_t phi1 = fPhi1; - Double_t phi2 = phi1 + fDphi; Double_t xc[4]; Double_t yc[4]; - xc[0] = rmax*TMath::Cos(phi1*TMath::DegToRad()); - yc[0] = rmax*TMath::Sin(phi1*TMath::DegToRad()); - xc[1] = rmax*TMath::Cos(phi2*TMath::DegToRad()); - yc[1] = rmax*TMath::Sin(phi2*TMath::DegToRad()); - xc[2] = rmin*TMath::Cos(phi1*TMath::DegToRad()); - yc[2] = rmin*TMath::Sin(phi1*TMath::DegToRad()); - xc[3] = rmin*TMath::Cos(phi2*TMath::DegToRad()); - yc[3] = rmin*TMath::Sin(phi2*TMath::DegToRad()); + xc[0] = rmax*fC1; + yc[0] = rmax*fS1; + xc[1] = rmax*fC2; + yc[1] = rmax*fS2; + xc[2] = rmin*fC1; + yc[2] = rmin*fS1; + xc[3] = rmin*fC2; + yc[3] = rmin*fS2; Double_t xmin = xc[TMath::LocMin(4, &xc[0])]; Double_t xmax = xc[TMath::LocMax(4, &xc[0])]; Double_t ymin = yc[TMath::LocMin(4, &yc[0])]; Double_t ymax = yc[TMath::LocMax(4, &yc[0])]; - Double_t ddp = -phi1; + Double_t ddp = -fPhi1; if (ddp<0) ddp+= 360; if (ddp<=fDphi) xmax = rmax; - ddp = 90-phi1; + ddp = 90-fPhi1; if (ddp<0) ddp+= 360; if (ddp<=fDphi) ymax = rmax; - ddp = 180-phi1; + ddp = 180-fPhi1; if (ddp<0) ddp+= 360; if (ddp<=fDphi) xmin = -rmax; - ddp = 270-phi1; + ddp = 270-fPhi1; if (ddp<0) ddp+= 360; if (ddp<=fDphi) ymin = -rmax; fOrigin[0] = (xmax+xmin)/2; @@ -263,15 +331,14 @@ void TGeoPcon::ComputeBBox() } //_____________________________________________________________________________ -void TGeoPcon::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) +void TGeoPcon::ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm) { // Compute normal to closest surface from POINT. memset(norm,0,3*sizeof(Double_t)); Double_t r; Double_t ptnew[3]; Double_t dz, rmin1, rmax1, rmin2, rmax2; - Bool_t is_tube, is_seg; - Double_t phi1=0, phi2=0, c1=0, s1=0, c2=0, s2=0; + Bool_t is_tube; Int_t ipl = TMath::BinarySearch(fNz, fZ, point[2]); if (ipl==(fNz-1) || ipl<0) { // point outside Z range @@ -314,19 +381,9 @@ void TGeoPcon::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) rmin2 = fRmin[ipl+1]; rmax2 = fRmax[ipl+1]; is_tube = (TGeoShape::IsSameWithinTolerance(rmin1,rmin2) && TGeoShape::IsSameWithinTolerance(rmax1,rmax2))?kTRUE:kFALSE; - is_seg = (fDphi<360)?kTRUE:kFALSE; - if (is_seg) { - phi1 = fPhi1; - if (phi1<0) phi1+=360; - phi2 = phi1 + fDphi; - phi1 *= TMath::DegToRad(); - phi2 *= TMath::DegToRad(); - c1 = TMath::Cos(phi1); - s1 = TMath::Sin(phi1); - c2 = TMath::Cos(phi2); - s2 = TMath::Sin(phi2); - if (is_tube) TGeoTubeSeg::ComputeNormalS(ptnew,dir,norm,rmin1,rmax1,dz,c1,s1,c2,s2); - else TGeoConeSeg::ComputeNormalS(ptnew,dir,norm,dz,rmin1,rmax1,rmin2,rmax2,c1,s1,c2,s2); + if (!fFullPhi) { + if (is_tube) TGeoTubeSeg::ComputeNormalS(ptnew,dir,norm,rmin1,rmax1,dz,fC1,fS1,fC2,fS2); + else TGeoConeSeg::ComputeNormalS(ptnew,dir,norm,dz,rmin1,rmax1,rmin2,rmax2,fC1,fS1,fC2,fS2); } else { if (is_tube) TGeoTube::ComputeNormalS(ptnew,dir,norm,rmin1,rmax1,dz); else TGeoCone::ComputeNormalS(ptnew,dir,norm,dz,rmin1,rmax1,rmin2,rmax2); @@ -334,7 +391,7 @@ void TGeoPcon::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) } //_____________________________________________________________________________ -Bool_t TGeoPcon::Contains(Double_t *point) const +Bool_t TGeoPcon::Contains(const Double_t *point) const { // test if point is inside this shape // check total z range @@ -385,7 +442,7 @@ Int_t TGeoPcon::DistancetoPrimitive(Int_t px, Int_t py) } //_____________________________________________________________________________ -Double_t TGeoPcon::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoPcon::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from inside point to surface of the polycone if (iact<3 && safe) { @@ -397,7 +454,7 @@ Double_t TGeoPcon::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Do Double_t sstep = 1E-6; Double_t point_new[3]; // determine which z segment contains the point - Int_t ipl = TMath::BinarySearch(fNz, fZ, point[2]); + Int_t ipl = TMath::BinarySearch(fNz, fZ, point[2]+TMath::Sign(1.E-10,dir[2])); if (ipl<0) ipl=0; if (ipl==(fNz-1)) ipl--; Double_t dz = 0.5*(fZ[ipl+1]-fZ[ipl]); @@ -420,36 +477,23 @@ Double_t TGeoPcon::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Do if (!TGeoShape::IsSameWithinTolerance(fRmin[ipl],fRmin[ipl+1])) intub=kFALSE; else if (!TGeoShape::IsSameWithinTolerance(fRmax[ipl],fRmax[ipl+1])) intub=kFALSE; // determine phi segmentation - Bool_t inphi=kTRUE; - if (TGeoShape::IsSameWithinTolerance(fDphi,360)) inphi=kFALSE; memcpy(point_new, point, 2*sizeof(Double_t)); // new point in reference system of the current segment point_new[2] = point[2]-0.5*(fZ[ipl]+fZ[ipl+1]); - Double_t phi1 = fPhi1; - if (phi1<0) phi1+=360.; - Double_t phi2 = phi1+fDphi; - Double_t phim = 0.5*(phi1+phi2); - Double_t c1 = TMath::Cos(phi1*TMath::DegToRad()); - Double_t s1 = TMath::Sin(phi1*TMath::DegToRad()); - Double_t c2 = TMath::Cos(phi2*TMath::DegToRad()); - Double_t s2 = TMath::Sin(phi2*TMath::DegToRad()); - Double_t cm = TMath::Cos(phim*TMath::DegToRad()); - Double_t sm = TMath::Sin(phim*TMath::DegToRad()); - Double_t cdfi = TMath::Cos(0.5*fDphi*TMath::DegToRad()); if (special_case) { - if (inphi) snxt = TGeoTubeSeg::DistFromInsideS(point_new, dir, + if (!fFullPhi) snxt = TGeoTubeSeg::DistFromInsideS(point_new, dir, TMath::Min(fRmin[ipl],fRmin[ipl+1]), TMath::Max(fRmax[ipl],fRmax[ipl+1]), - dz, c1,s1,c2,s2,cm,sm,cdfi); + dz, fC1,fS1,fC2,fS2,fCm,fSm,fCdphi); else snxt = TGeoTube::DistFromInsideS(point_new, dir, TMath::Min(fRmin[ipl],fRmin[ipl+1]), TMath::Max(fRmax[ipl],fRmax[ipl+1]),dz); return snxt; } if (intub) { - if (inphi) snxt=TGeoTubeSeg::DistFromInsideS(point_new, dir, fRmin[ipl], fRmax[ipl],dz, c1,s1,c2,s2,cm,sm,cdfi); + if (!fFullPhi) snxt=TGeoTubeSeg::DistFromInsideS(point_new, dir, fRmin[ipl], fRmax[ipl],dz, fC1,fS1,fC2,fS2,fCm,fSm,fCdphi); else snxt=TGeoTube::DistFromInsideS(point_new, dir, fRmin[ipl], fRmax[ipl],dz); } else { - if (inphi) snxt=TGeoConeSeg::DistFromInsideS(point_new,dir,dz,fRmin[ipl],fRmax[ipl],fRmin[ipl+1],fRmax[ipl+1],c1,s1,c2,s2,cm,sm,cdfi); + if (!fFullPhi) snxt=TGeoConeSeg::DistFromInsideS(point_new,dir,dz,fRmin[ipl],fRmax[ipl],fRmin[ipl+1],fRmax[ipl+1],fC1,fS1,fC2,fS2,fCm,fSm,fCdphi); else snxt=TGeoCone::DistFromInsideS(point_new,dir,dz,fRmin[ipl],fRmax[ipl],fRmin[ipl+1], fRmax[ipl+1]); } @@ -461,8 +505,7 @@ Double_t TGeoPcon::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Do } //_____________________________________________________________________________ -Double_t TGeoPcon::DistToSegZ(Double_t *point, Double_t *dir, Int_t &iz, Double_t c1, Double_t s1, - Double_t c2, Double_t s2, Double_t cfio, Double_t sfio, Double_t cdfi) const +Double_t TGeoPcon::DistToSegZ(const Double_t *point, const Double_t *dir, Int_t &iz) const { // compute distance to a pcon Z slice. Segment iz must be valid Double_t zmin=fZ[iz]; @@ -472,7 +515,7 @@ Double_t TGeoPcon::DistToSegZ(Double_t *point, Double_t *dir, Int_t &iz, Double_ Int_t istep=(dir[2]>0)?1:-1; iz+=istep; if (iz<0 || iz>(fNz-2)) return TGeoShape::Big(); - return DistToSegZ(point,dir,iz,c1,s1,c2,s2,cfio,sfio,cdfi); + return DistToSegZ(point,dir,iz); } Double_t dz=0.5*(zmax-zmin); Double_t local[3]; @@ -483,14 +526,13 @@ Double_t TGeoPcon::DistToSegZ(Double_t *point, Double_t *dir, Int_t &iz, Double_ Double_t rmax1=fRmax[iz]; Double_t rmin2=fRmin[iz+1]; Double_t rmax2=fRmax[iz+1]; - Bool_t is_seg=(TGeoShape::IsSameWithinTolerance(fDphi,360))?kFALSE:kTRUE; if (TGeoShape::IsSameWithinTolerance(rmin1,rmin2) && TGeoShape::IsSameWithinTolerance(rmax1,rmax2)) { - if (!is_seg) snxt=TGeoTube::DistFromOutsideS(local, dir, rmin1, rmax1, dz); - else snxt=TGeoTubeSeg::DistFromOutsideS(local,dir,rmin1,rmax1,dz,c1,s1,c2,s2,cfio,sfio,cdfi); + if (fFullPhi) snxt=TGeoTube::DistFromOutsideS(local, dir, rmin1, rmax1, dz); + else snxt=TGeoTubeSeg::DistFromOutsideS(local,dir,rmin1,rmax1,dz,fC1,fS1,fC2,fS2,fCm,fSm,fCdphi); } else { - if (!is_seg) snxt=TGeoCone::DistFromOutsideS(local,dir,dz,rmin1, rmax1,rmin2,rmax2); - else snxt=TGeoConeSeg::DistFromOutsideS(local,dir,dz,rmin1,rmax1,rmin2,rmax2,c1,s1,c2,s2,cfio,sfio,cdfi); + if (fFullPhi) snxt=TGeoCone::DistFromOutsideS(local,dir,dz,rmin1, rmax1,rmin2,rmax2); + else snxt=TGeoConeSeg::DistFromOutsideS(local,dir,dz,rmin1,rmax1,rmin2,rmax2,fC1,fS1,fC2,fS2,fCm,fSm,fCdphi); } if (snxt<1E20) return snxt; // check next segment @@ -498,11 +540,11 @@ Double_t TGeoPcon::DistToSegZ(Double_t *point, Double_t *dir, Int_t &iz, Double_ Int_t istep=(dir[2]>0)?1:-1; iz+=istep; if (iz<0 || iz>(fNz-2)) return TGeoShape::Big(); - return DistToSegZ(point,dir,iz,c1,s1,c2,s2,cfio,sfio,cdfi); + return DistToSegZ(point,dir,iz); } //_____________________________________________________________________________ -Double_t TGeoPcon::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoPcon::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from outside point to surface of the tube if ((iact<3) && safe) { @@ -534,29 +576,13 @@ Double_t TGeoPcon::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, D } else if (ifirst>=(fNz-1)) ifirst=fNz-2; // find if point is in the phi gap Double_t phi=0; - Double_t phi1=0; - Double_t phi2=0; - Double_t c1=0., s1=0., c2=0., s2=0., cfio=0., sfio=0., cdfi=0.; - Bool_t inphi = (fDphi<360)?kTRUE:kFALSE; - if (inphi) { - phi1=fPhi1; - if (phi1<0) phi1+=360; - phi2=(phi1+fDphi)*TMath::DegToRad(); - phi1=phi1*TMath::DegToRad(); + if (!fFullPhi) { phi=TMath::ATan2(point[1], point[0]); if (phi<0) phi+=2.*TMath::Pi(); - c1=TMath::Cos(phi1); - s1=TMath::Sin(phi1); - c2=TMath::Cos(phi2); - s2=TMath::Sin(phi2); - Double_t fio=0.5*(phi1+phi2); - cfio=TMath::Cos(fio); - sfio=TMath::Sin(fio); - cdfi=TMath::Cos(0.5*(phi2-phi1)); } // compute distance to boundary - return DistToSegZ(point,dir,ifirst, c1,s1,c2,s2,cfio,sfio,cdfi); + return DistToSegZ(point,dir,ifirst); } //_____________________________________________________________________________ @@ -998,7 +1024,7 @@ void TGeoPcon::SetSegsAndPols(TBuffer3D &buff) const } //_____________________________________________________________________________ -Double_t TGeoPcon::SafetyToSegment(Double_t *point, Int_t ipl, Bool_t in, Double_t safmin) const +Double_t TGeoPcon::SafetyToSegment(const Double_t *point, Int_t ipl, Bool_t in, Double_t safmin) const { // Compute safety from POINT to segment between planes ipl, ipl+1 within safmin. @@ -1017,8 +1043,7 @@ Double_t TGeoPcon::SafetyToSegment(Double_t *point, Int_t ipl, Bool_t in, Double Double_t rmin2 = fRmin[ipl+1]; Double_t rmax2 = fRmax[ipl+1]; Bool_t is_tube = (TGeoShape::IsSameWithinTolerance(rmin1,rmin2) && TGeoShape::IsSameWithinTolerance(rmax1,rmax2))?kTRUE:kFALSE; - Bool_t is_seg = (fDphi<360)?kTRUE:kFALSE; - if (is_seg) { + if (!fFullPhi) { if (is_tube) safe = TGeoTubeSeg::SafetyS(ptnew,in,rmin1,rmax1, dz,fPhi1,fPhi1+fDphi,0); else safe = TGeoConeSeg::SafetyS(ptnew,in,dz,rmin1,rmax1,rmin2,rmax2,fPhi1,fPhi1+fDphi,0); } else { @@ -1030,7 +1055,7 @@ Double_t TGeoPcon::SafetyToSegment(Double_t *point, Int_t ipl, Bool_t in, Double } //_____________________________________________________________________________ -Double_t TGeoPcon::Safety(Double_t *point, Bool_t in) const +Double_t TGeoPcon::Safety(const Double_t *point, Bool_t in) const { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. @@ -1065,7 +1090,7 @@ Double_t TGeoPcon::Safety(Double_t *point, Bool_t in) const safmin = SafetyToSegment(point, ipl); if (safmin>1E10) { // something went wrong - point is not inside current segment - return TGeoShape::Big(); + return 0.; } if (safmin<1E-6) return TMath::Abs(safmin); // point on radius-changing plane // check increasing iplanes @@ -1119,22 +1144,22 @@ Double_t TGeoPcon::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -void TGeoPcon::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoPcon::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " phi1 = " << fPhi1 << ";" << endl; - out << " dphi = " << fDphi << ";" << endl; - out << " nz = " << fNz << ";" << endl; - out << " TGeoPcon *pcon = new TGeoPcon(\"" << GetName() << "\",phi1,dphi,nz);" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " phi1 = " << fPhi1 << ";" << std::endl; + out << " dphi = " << fDphi << ";" << std::endl; + out << " nz = " << fNz << ";" << std::endl; + out << " TGeoPcon *pcon = new TGeoPcon(\"" << GetName() << "\",phi1,dphi,nz);" << std::endl; for (Int_t i=0; iDefineSection(" << i << ", z,rmin,rmax);" << endl; + out << " z = " << fZ[i] << ";" << std::endl; + out << " rmin = " << fRmin[i] << ";" << std::endl; + out << " rmax = " << fRmax[i] << ";" << std::endl; + out << " pcon->DefineSection(" << i << ", z,rmin,rmax);" << std::endl; } - out << " TGeoShape *" << GetPointerName() << " = pcon;" << endl; + out << " TGeoShape *" << GetPointerName() << " = pcon;" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -1143,6 +1168,7 @@ void TGeoPcon::SetDimensions(Double_t *param) { // Set polycone dimensions starting from an array. fPhi1 = param[0]; + while (fPhi1<0) fPhi1 += 360.; fDphi = param[1]; fNz = (Int_t)param[2]; if (fNz<2) { @@ -1158,6 +1184,18 @@ void TGeoPcon::SetDimensions(Double_t *param) memset(fRmin, 0, fNz*sizeof(Double_t)); memset(fRmax, 0, fNz*sizeof(Double_t)); memset(fZ, 0, fNz*sizeof(Double_t)); + if (TGeoShape::IsSameWithinTolerance(fDphi,360)) fFullPhi = kTRUE; + Double_t phi1 = fPhi1; + Double_t phi2 = phi1+fDphi; + Double_t phim = 0.5*(phi1+phi2); + fC1 = TMath::Cos(phi1*TMath::DegToRad()); + fS1 = TMath::Sin(phi1*TMath::DegToRad()); + fC2 = TMath::Cos(phi2*TMath::DegToRad()); + fS2 = TMath::Sin(phi2*TMath::DegToRad()); + fCm = TMath::Cos(phim*TMath::DegToRad()); + fSm = TMath::Sin(phim*TMath::DegToRad()); + fCdphi = TMath::Cos(0.5*fDphi*TMath::DegToRad()); + for (Int_t i=0; ifNz-2) return kFALSE; @@ -986,7 +986,7 @@ Bool_t TGeoPgon::IsCrossingSlice(Double_t *point, Double_t *dir, Int_t iphi, Dou } //_____________________________________________________________________________ -Double_t TGeoPgon::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoPgon::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from outside point to surface of the polygone if (iact<3 && safe) { @@ -1544,12 +1544,12 @@ Double_t TGeoPgon::Rpg(Double_t z, Int_t ipl, Bool_t inner, Double_t &a, Double_ } //_____________________________________________________________________________ -Double_t TGeoPgon::Rproj(Double_t z, Double_t *point, Double_t *dir, Double_t cphi, Double_t sphi, Double_t &a, Double_t &b) const +Double_t TGeoPgon::Rproj(Double_t z, const Double_t *point, const Double_t *dir, Double_t cphi, Double_t sphi, Double_t &a, Double_t &b) const { // Computes projected distance at a given Z for a given ray inside a given sector // and fills coefficients: // Rproj = a + b*z - if (TMath::Abs(dir[2])<1E-8) { + if (TMath::Abs(dir[2])DefineSection(" << i << ", z,rmin,rmax);" << endl; + out << " z = " << fZ[i] << ";" << std::endl; + out << " rmin = " << fRmin[i] << ";" << std::endl; + out << " rmax = " << fRmax[i] << ";" << std::endl; + out << " pgon->DefineSection(" << i << ", z,rmin,rmax);" << std::endl; } - out << " TGeoShape *" << GetPointerName() << " = pgon;" << endl; + out << " TGeoShape *" << GetPointerName() << " = pgon;" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -1877,3 +1877,44 @@ const TBuffer3D & TGeoPgon::GetBuffer3D(Int_t reqSections, Bool_t localFrame) co return buffer; } + +//_____________________________________________________________________________ +void TGeoPgon::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; iIsOffset()) { Error("Align", "Cannot align division nodes: %s\n",node->GetName()); - return; + return kFALSE; } TGeoNode *nnode = 0; TGeoVolume *vm = GetVolume(0); @@ -168,7 +174,7 @@ void TGeoPhysicalNode::Align(TGeoMatrix *newmat, TGeoShape *newshape, Bool_t che if (id[i]<0) { Error("Align","%s cannot align node %s",GetName(), node->GetName()); delete [] id; - return; + return kFALSE; } } for (i=0; iGetVolume()->CloneVolume(); + if (!vd) { + delete [] id; + Fatal("Align", "Cannot clone volume %s", node->GetVolume()->GetName()); + return kFALSE; + } nnode = node->MakeCopyNode(); + if (!nnode) { + delete [] id; + Fatal("Align", "Cannot make copy node for %s", node->GetName()); + return kFALSE; + } // Correct pointers to mother and volume nnode->SetVolume(vd); nnode->SetMotherVolume(vm); @@ -200,14 +216,77 @@ void TGeoPhysicalNode::Align(TGeoMatrix *newmat, TGeoShape *newshape, Bool_t che vm = nnode->GetMotherVolume(); vd = nnode->GetVolume(); if (newmat) { + // Check if the old matrix for this node was shared + Bool_t shared = kFALSE; + Int_t nd = vm->GetNdaughters(); + TGeoCompositeShape *cs; + if (nnode->GetMatrix()->IsShared()) { + // Now find the node having a composite shape using this shared matrix + for (i=0; iGetNode(i); + if (node==nnode) continue; + if (node->IsOffset()) continue; + if (!node->GetVolume()->GetShape()->IsComposite()) continue; + // We found a node having a composite shape, scan for the shared matrix + cs = (TGeoCompositeShape*)node->GetVolume()->GetShape(); + if (cs->GetBoolNode()->GetRightMatrix() != nnode->GetMatrix()) continue; + // The composite uses the matrix -> replace it + TGeoCompositeShape *ncs = new TGeoCompositeShape(cs->GetName(), cs->GetBoolNode()->MakeClone()); + ncs->GetBoolNode()->ReplaceMatrix(nnode->GetMatrix(), newmat); + // We have to clone the node/volume having the composite shape + TGeoVolume *newvol = node->GetVolume()->CloneVolume(); + if (!newvol) { + Error("Align", "Cannot clone volume %s", node->GetVolume()->GetName()); + return kFALSE; + } + newvol->SetShape(ncs); + TGeoNode *newnode = node->MakeCopyNode(); + if (!newnode) { + Error("Align", "Cannot clone node %s", node->GetName()); + return kFALSE; + } + newnode->SetVolume(newvol); + newnode->SetMotherVolume(vm); + if (vm->TestBit(TGeoVolume::kVolumeImportNodes)) { + gGeoManager->GetListOfGShapes()->Add(newnode); + } + vm->GetNodes()->RemoveAt(i); + vm->GetNodes()->AddAt(newnode,i); + shared = kTRUE; + } + if (!shared) Error("Align", "The matrix replaced for %s is not actually shared", GetName()); + } else { + // The aligned node may have a composite shape containing a shared matrix + if (vd->GetShape()->IsComposite()) { + cs = (TGeoCompositeShape*)vd->GetShape(); + if (cs->GetBoolNode()->GetRightMatrix()->IsShared()) { + if (!nnode->GetMatrix()->IsIdentity()) { + Error("Align", "The composite shape having a shared matrix on the subtracted branch must be positioned using identity matrix."); + return kFALSE; + } + // We have to put the alignment matrix on top of the left branch + // of the composite shape. The node is already decoupled from logical tree. + TGeoCompositeShape *ncs = new TGeoCompositeShape(cs->GetName(), cs->GetBoolNode()->MakeClone()); + TGeoMatrix *oldmat = ncs->GetBoolNode()->GetLeftMatrix(); + TGeoHMatrix *newmat1 = new TGeoHMatrix(*newmat); + newmat1->Multiply(oldmat); + ncs->GetBoolNode()->ReplaceMatrix(oldmat, newmat1); + vd->SetShape(ncs); + // The right-side matrix pointer is preserved, so no need to update nodes. + aligned = 0; // to prevent updating its matrix + } + } + } // Register matrix and make it the active one if (!newmat->IsRegistered()) newmat->RegisterYourself(); - aligned->SetMatrix(newmat); - // Update the global matrix for the aligned node - TGeoHMatrix *global = GetMatrix(); - TGeoHMatrix *up = GetMatrix(fLevel-1); - *global = up; - global->Multiply(newmat); + if (aligned) { + aligned->SetMatrix(newmat); + // Update the global matrix for the aligned node + TGeoHMatrix *global = GetMatrix(); + TGeoHMatrix *up = GetMatrix(fLevel-1); + *global = up; + global->Multiply(newmat); + } } // Change the shape for the aligned node if (newshape) vd->SetShape(newshape); @@ -216,6 +295,7 @@ void TGeoPhysicalNode::Align(TGeoMatrix *newmat, TGeoShape *newshape, Bool_t che for (i=fLevel-1; i>0; i--) { Bool_t dassm = vd->IsAssembly(); // is daughter assembly ? vd = GetVolume(i); + if (!vd) break; Bool_t cassm = vd->IsAssembly(); // is current assembly ? if (cassm) ((TGeoShapeAssembly*)vd->GetShape())->NeedsBBoxRecompute(); if ((cassm || dassm) && vd->GetVoxels()) vd->GetVoxels()->SetNeedRebuild(); @@ -234,6 +314,7 @@ void TGeoPhysicalNode::Align(TGeoMatrix *newmat, TGeoShape *newshape, Bool_t che // Set aligned node to be checked i = fLevel; node = GetNode(i); + if (!node) return kTRUE; if (node->IsOverlapping()) { Info("Align", "The check for overlaps for node: \n%s\n cannot be performed since the node is declared possibly overlapping", GetName()); @@ -255,6 +336,7 @@ void TGeoPhysicalNode::Align(TGeoMatrix *newmat, TGeoShape *newshape, Bool_t che // Clean current matrices from cache gGeoManager->CdTop(); SetAligned(kTRUE); + return kTRUE; } //_____________________________________________________________________________ diff --git a/geom/geom/src/TGeoPolygon.cxx b/geom/geom/src/TGeoPolygon.cxx index d7920793019b6..58e8d6a7cc2cc 100644 --- a/geom/geom/src/TGeoPolygon.cxx +++ b/geom/geom/src/TGeoPolygon.cxx @@ -17,7 +17,7 @@ // TGeoXtru class for computing Contains() and Safety(). Only the pointers to // the actual lists of XY values are used - these are not owned by the class. // -// To check if a point in XY plane is contained by a polygon, this is splitted +// To check if a point in XY plane is contained by a polygon, this is split // into an outscribed convex polygon and the remaining polygons of its subtracton // from the outscribed one. A point is INSIDE if it is // contained by the outscribed polygon but NOT by the remaining ones. Since these @@ -27,7 +27,7 @@ // Pconvex-P = P1 + P2 + ... where (+) means 'union' // // *Note that P1, P2, ... do not intersect each other and they are defined -// by subsets of the list of vertices of P. They can be splitted in the same +// by subsets of the list of vertices of P. They can be split in the same // way as P* // // Therefore, if C(P) represents the Boolean : 'does P contains a given point?', @@ -45,6 +45,8 @@ #include "TGeoPolygon.h" #include "TMath.h" #include "TGeoShape.h" +#include "TGeoManager.h" +#include "TVirtualGeoPainter.h" ClassImp(TGeoPolygon) @@ -110,7 +112,7 @@ Double_t TGeoPolygon::Area() const } //_____________________________________________________________________________ -Bool_t TGeoPolygon::Contains(Double_t *point) const +Bool_t TGeoPolygon::Contains(const Double_t *point) const { // Check if a point given by X = point[0], Y = point[1] is inside the polygon. Int_t i; @@ -146,6 +148,14 @@ void TGeoPolygon::ConvexCheck() SetConvex(); } +//_____________________________________________________________________________ +void TGeoPolygon::Draw(Option_t *) +{ +// Draw the polygon. + if (!gGeoManager) return; + gGeoManager->GetGeomPainter()->DrawPolygon(this); +} + //_____________________________________________________________________________ void TGeoPolygon::FinishPolygon() { @@ -198,13 +208,31 @@ void TGeoPolygon::FinishPolygon() } //_____________________________________________________________________________ -Bool_t TGeoPolygon::IsRightSided(Double_t *point, Int_t ind1, Int_t ind2) const +void TGeoPolygon::GetVertices(Double_t *x, Double_t *y) const +{ +// Fill list of vertices into provided arrays. + memcpy(x, fX, fNvert*sizeof(Double_t)); + memcpy(y, fY, fNvert*sizeof(Double_t)); +} + +//_____________________________________________________________________________ +void TGeoPolygon::GetConvexVertices(Double_t *x, Double_t *y) const +{ +// Fill list of vertices of the convex outscribed polygon into provided arrays. + for (Int_t ic=0; icSavePrimitive(out, option); TString sname = fShape->GetPointerName(); const Double_t *sc = fScale->GetScale(); - out << " // Scale factor:" << endl; + out << " // Scale factor:" << std::endl; out << " TGeoScale *pScale = new TGeoScale(\"" << fScale->GetName() - << "\"," << sc[0] << "," << sc[1] << "," << sc[2] << ");" << endl; + << "\"," << sc[0] << "," << sc[1] << "," << sc[2] << ");" << std::endl; out << " TGeoScaledShape *" << GetPointerName() << " = new TGeoScaledShape(\"" - << GetName() << "\"," << sname << ", pScale);" << endl; + << GetName() << "\"," << sname << ", pScale);" << std::endl; } //_____________________________________________________________________________ @@ -345,3 +345,44 @@ void TGeoScaledShape::SetPoints(Float_t *points) const points[index+2] = master[2]; } } + +//_____________________________________________________________________________ +void TGeoScaledShape::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; iGetListOfShapes()->Remove(this); + if (gGeoManager && !gGeoManager->IsCleaning()) gGeoManager->GetListOfShapes()->Remove(this); } //_____________________________________________________________________________ @@ -240,7 +240,7 @@ Double_t TGeoShape::EpsMch() const char *TGeoShape::GetName() const { // Get the shape name. - if (!strlen(fName)) { + if (!fName[0]) { return ((TObject *)this)->ClassName(); } return TNamed::GetName(); @@ -256,7 +256,7 @@ Int_t TGeoShape::ShapeDistancetoPrimitive(Int_t numpoints, Int_t px, Int_t py) c } //_____________________________________________________________________________ -Bool_t TGeoShape::IsCloseToPhi(Double_t epsil, Double_t *point, Double_t c1, Double_t s1, Double_t c2, Double_t s2) +Bool_t TGeoShape::IsCloseToPhi(Double_t epsil, const Double_t *point, Double_t c1, Double_t s1, Double_t c2, Double_t s2) { // True if point is closer than epsil to one of the phi planes defined by c1,s1 or c2,s2 Double_t saf1 = TGeoShape::Big(); @@ -269,7 +269,7 @@ Bool_t TGeoShape::IsCloseToPhi(Double_t epsil, Double_t *point, Double_t c1, Dou } //_____________________________________________________________________________ -Bool_t TGeoShape::IsInPhiRange(Double_t *point, Double_t phi1, Double_t phi2) +Bool_t TGeoShape::IsInPhiRange(const Double_t *point, Double_t phi1, Double_t phi2) { // Static method to check if a point is in the phi range (phi1, phi2) [degrees] Double_t phi = TMath::ATan2(point[1], point[0]) * TMath::RadToDeg(); @@ -280,7 +280,7 @@ Bool_t TGeoShape::IsInPhiRange(Double_t *point, Double_t phi1, Double_t phi2) } //_____________________________________________________________________________ -Bool_t TGeoShape::IsCrossingSemiplane(Double_t *point, Double_t *dir, Double_t cphi, Double_t sphi, Double_t &snext, Double_t &rxy) +Bool_t TGeoShape::IsCrossingSemiplane(const Double_t *point, const Double_t *dir, Double_t cphi, Double_t sphi, Double_t &snext, Double_t &rxy) { // Compute distance from POINT to semiplane defined by PHI angle along DIR. Computes // also radius at crossing point. This might be negative in case the crossing is @@ -387,7 +387,7 @@ Bool_t TGeoShape::IsSegCrossing(Double_t x1, Double_t y1, Double_t x2, Double_t } //_____________________________________________________________________________ -Double_t TGeoShape::DistToPhiMin(Double_t *point, Double_t *dir, Double_t s1, Double_t c1, +Double_t TGeoShape::DistToPhiMin(const Double_t *point, const Double_t *dir, Double_t s1, Double_t c1, Double_t s2, Double_t c2, Double_t sm, Double_t cm, Bool_t in) { // compute distance from point (inside phi) to both phi planes. Return minimum. @@ -418,7 +418,7 @@ Double_t TGeoShape::DistToPhiMin(Double_t *point, Double_t *dir, Double_t s1, Do } //_____________________________________________________________________________ -void TGeoShape::NormalPhi(Double_t *point, Double_t *dir, Double_t *norm, Double_t c1, Double_t s1, Double_t c2, Double_t s2) +void TGeoShape::NormalPhi(const Double_t *point, const Double_t *dir, Double_t *norm, Double_t c1, Double_t s1, Double_t c2, Double_t s2) { // Static method to compute normal to phi planes. Double_t saf1 = TGeoShape::Big(); @@ -443,7 +443,7 @@ void TGeoShape::NormalPhi(Double_t *point, Double_t *dir, Double_t *norm, Double } //_____________________________________________________________________________ -Double_t TGeoShape::SafetyPhi(Double_t *point, Bool_t in, Double_t phi1, Double_t phi2) +Double_t TGeoShape::SafetyPhi(const Double_t *point, Bool_t in, Double_t phi1, Double_t phi2) { // Static method to compute safety w.r.t a phi corner defined by cosines/sines // of the angles phi1, phi2. @@ -472,6 +472,34 @@ Double_t TGeoShape::SafetyPhi(Double_t *point, Bool_t in, Double_t phi1, Double_ return safe; } +//_____________________________________________________________________________ +Double_t TGeoShape::SafetySeg(Double_t r, Double_t z, Double_t r1, Double_t z1, Double_t r2, Double_t z2, Bool_t outer) +{ +// Compute distance from point of coordinates (r,z) to segment (r1,z1):(r2,z2) + Double_t crossp = (z2-z1)*(r-r1)-(z-z1)*(r2-r1); + crossp *= (outer) ? 1. : -1.; + // Positive crossp means point on the requested side of the (1,2) segment + if (crossp < 0) { + if (((z-z1)*(z2-z)) > -1.E-10) return 0; + return TGeoShape::Big(); + } + // Compute (1,P) dot (1,2) + Double_t c1 = (z-z1)*(z2-z1)+(r-r1)*(r2-r1); + // Negative c1 means point (1) is closest + if (c1<1.E-10) return TMath::Sqrt((r-r1)*(r-r1)+(z-z1)*(z-z1)); + // Compute (2,P) dot (1,2) + Double_t c2 = (z-z2)*(z2-z1)+(r-r2)*(r2-r1); + // Positive c2 means point (2) is closest + if (c2>-1.E-10) return TMath::Sqrt((r-r2)*(r-r2)+(z-z2)*(z-z2)); + // The closest point is between (1) and (2) + c2 = (z2-z1)*(z2-z1)+(r2-r1)*(r2-r1); + // projected length factor with respect to (1,2) length + Double_t alpha = c1/c2; + Double_t rp = r1 + alpha*(r2-r1); + Double_t zp = z1 + alpha*(z2-z1); + return TMath::Sqrt((r-rp)*(r-rp)+(z-zp)*(z-zp)); +} + //_____________________________________________________________________________ void TGeoShape::SetShapeBit(UInt_t f, Bool_t set) { @@ -666,7 +694,7 @@ void TGeoShape::Draw(Option_t *option) { // Draw this shape. TVirtualGeoPainter *painter = gGeoManager->GetGeomPainter(); - if (option && strlen(option) > 0) { + if (option && option[0]) { painter->DrawShape(this, option); } else { painter->DrawShape(this, gEnv->GetValue("Viewer3D.DefaultDrawOption","")); @@ -678,7 +706,7 @@ void TGeoShape::Paint(Option_t *option) { // Paint this shape. TVirtualGeoPainter *painter = gGeoManager->GetGeomPainter(); - if (option && strlen(option) > 0) { + if (option && option[0]) { painter->PaintShape(this, option); } else { painter->PaintShape(this, gEnv->GetValue("Viewer3D.DefaultDrawOption","")); diff --git a/geom/geom/src/TGeoShapeAssembly.cxx b/geom/geom/src/TGeoShapeAssembly.cxx index 5afd0de51ef46..5e946eeb799ed 100644 --- a/geom/geom/src/TGeoShapeAssembly.cxx +++ b/geom/geom/src/TGeoShapeAssembly.cxx @@ -145,7 +145,7 @@ void TGeoShapeAssembly::RecomputeBoxLast() } //_____________________________________________________________________________ -void TGeoShapeAssembly::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) +void TGeoShapeAssembly::ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm) { // Compute normal to closest surface from POINT. Should not be called. if (!fBBoxOK) ((TGeoShapeAssembly*)this)->ComputeBBox(); @@ -167,7 +167,7 @@ void TGeoShapeAssembly::ComputeNormal(Double_t *point, Double_t *dir, Double_t * } //_____________________________________________________________________________ -Bool_t TGeoShapeAssembly::Contains(Double_t *point) const +Bool_t TGeoShapeAssembly::Contains(const Double_t *point) const { // Test if point is inside the assembly if (!fBBoxOK) ((TGeoShapeAssembly*)this)->ComputeBBox(); @@ -182,7 +182,7 @@ Bool_t TGeoShapeAssembly::Contains(Double_t *point) const // get the list of nodes passing thorough the current voxel TGeoNavigator *nav = gGeoManager->GetCurrentNavigator(); TGeoStateInfo &td = *nav->GetCache()->GetInfo(); - check_list = voxels->GetCheckList(&point[0], ncheck, td); + check_list = voxels->GetCheckList(point, ncheck, td); if (!check_list) { nav->GetCache()->ReleaseInfo(); return kFALSE; @@ -223,7 +223,7 @@ Int_t TGeoShapeAssembly::DistancetoPrimitive(Int_t /*px*/, Int_t /*py*/) } //_____________________________________________________________________________ -Double_t TGeoShapeAssembly::DistFromInside(Double_t * /*point*/, Double_t * /*dir*/, Int_t /*iact*/, Double_t /*step*/, Double_t * /*safe*/) const +Double_t TGeoShapeAssembly::DistFromInside(const Double_t * /*point*/, const Double_t * /*dir*/, Int_t /*iact*/, Double_t /*step*/, Double_t * /*safe*/) const { // Compute distance from inside point to surface of the hyperboloid. Info("DistFromInside", "Cannot compute distance from inside the assembly (but from a component)"); @@ -232,7 +232,7 @@ Double_t TGeoShapeAssembly::DistFromInside(Double_t * /*point*/, Double_t * /*di //_____________________________________________________________________________ -Double_t TGeoShapeAssembly::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoShapeAssembly::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from outside point to surface of the hyperboloid. // fVolume->SetNextNodeIndex(-1); @@ -350,7 +350,7 @@ void TGeoShapeAssembly::SetSegsAndPols(TBuffer3D & /*buff*/) const } //_____________________________________________________________________________ -Double_t TGeoShapeAssembly::Safety(Double_t *point, Bool_t in) const +Double_t TGeoShapeAssembly::Safety(const Double_t *point, Bool_t in) const { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. @@ -405,7 +405,7 @@ Double_t TGeoShapeAssembly::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -void TGeoShapeAssembly::SavePrimitive(ostream & /*out*/, Option_t * /*option*/ /*= ""*/) +void TGeoShapeAssembly::SavePrimitive(std::ostream & /*out*/, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". } @@ -433,3 +433,43 @@ void TGeoShapeAssembly::GetMeshNumbers(Int_t &nvert, Int_t &nsegs, Int_t &npols) npols = 0; } +//_____________________________________________________________________________ +void TGeoShapeAssembly::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; i 2) theta1 = param[2]; -// if (nparam > 3) theta2 = param[3]; -// if (nparam > 4) phi1 = param[4]; -// if (nparam > 5) phi2 = param[5]; + if (nparam > 2) theta1 = param[2]; + if (nparam > 3) theta2 = param[3]; + if (nparam > 4) phi1 = param[4]; + if (nparam > 5) phi2 = param[5]; SetSphDimensions(rmin, rmax, theta1, theta2, phi1, phi2); } +//_____________________________________________________________________________ +void TGeoSphere::SetDimensions(Double_t *param) +{ +// Set dimensions of the spherical segment starting from a list of parameters. +// Only takes rmin and rmax + SetDimensions(param,2); +} + //_____________________________________________________________________________ void TGeoSphere::SetNumberOfDivisions(Int_t p) { @@ -1853,3 +1865,44 @@ const TBuffer3D & TGeoSphere::GetBuffer3D(Int_t reqSections, Bool_t localFrame) return buffer; } + +//_____________________________________________________________________________ +void TGeoSphere::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; i>3)]; fXtruXc = new Double_t[maxXtruVert]; fXtruYc = new Double_t[maxXtruVert]; + fVoxSlices[0] = fVoxSlices[1] = fVoxSlices[2] = -1; + fVoxInc[0] = fVoxInc[1] = fVoxInc[2] = 0; + fVoxInvdir[0] = fVoxInvdir[1] = fVoxInvdir[2] = 0; + fVoxLimits[0] = fVoxLimits[1] = fVoxLimits[2] = 0; } //_____________________________________________________________________________ @@ -82,6 +86,10 @@ TGeoStateInfo::TGeoStateInfo(const TGeoStateInfo &other) fVoxBits1 = new UChar_t[1 + ((maxDaughters-1)>>3)]; fXtruXc = new Double_t[maxXtruVert]; fXtruYc = new Double_t[maxXtruVert]; + fVoxSlices[0] = fVoxSlices[1] = fVoxSlices[2] = -1; + fVoxInc[0] = fVoxInc[1] = fVoxInc[2] = 0; + fVoxInvdir[0] = fVoxInvdir[1] = fVoxInvdir[2] = 0; + fVoxLimits[0] = fVoxLimits[1] = fVoxLimits[2] = 0; } //_____________________________________________________________________________ @@ -99,9 +107,17 @@ TGeoStateInfo &TGeoStateInfo::operator=(const TGeoStateInfo &other) fDivCombi = other.fDivCombi; fVoxNcandidates = other.fVoxNcandidates; fVoxCurrent = other.fVoxCurrent; + fVoxCheckList = other.fVoxCheckList; + fVoxBits1 = other.fVoxBits1; fBoolSelected = other.fBoolSelected; fXtruSeg = other.fXtruSeg; fXtruIz = other.fXtruIz; + fXtruXc = other.fXtruXc; + fXtruYc = other.fXtruYc; fXtruPoly = other.fXtruPoly; + fVoxSlices[0] = fVoxSlices[1] = fVoxSlices[2] = -1; + fVoxInc[0] = fVoxInc[1] = fVoxInc[2] = 0; + fVoxInvdir[0] = fVoxInvdir[1] = fVoxInvdir[2] = 0; + fVoxLimits[0] = fVoxLimits[1] = fVoxLimits[2] = 0; return *this; } diff --git a/geom/geom/src/TGeoTorus.cxx b/geom/geom/src/TGeoTorus.cxx index 49689317957b4..591c1e9a61de7 100644 --- a/geom/geom/src/TGeoTorus.cxx +++ b/geom/geom/src/TGeoTorus.cxx @@ -146,7 +146,7 @@ void TGeoTorus::ComputeBBox() } //----------------------------------------------------------------------------- -void TGeoTorus::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) +void TGeoTorus::ComputeNormal(const Double_t *point, const Double_t *dir, Double_t *norm) { // Compute normal to closest surface from POINT. Double_t phi = TMath::ATan2(point[1],point[0]); @@ -188,7 +188,7 @@ void TGeoTorus::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) } //_____________________________________________________________________________ -Bool_t TGeoTorus::Contains(Double_t *point) const +Bool_t TGeoTorus::Contains(const Double_t *point) const { // Test if point is inside the torus. // check phi range @@ -219,7 +219,7 @@ Int_t TGeoTorus::DistancetoPrimitive(Int_t px, Int_t py) } //_____________________________________________________________________________ -Double_t TGeoTorus::Daxis(Double_t *pt, Double_t *dir, Double_t t) const +Double_t TGeoTorus::Daxis(const Double_t *pt, const Double_t *dir, Double_t t) const { // Computes distance to axis of the torus from point pt + t*dir; Double_t p[3]; @@ -229,7 +229,7 @@ Double_t TGeoTorus::Daxis(Double_t *pt, Double_t *dir, Double_t t) const } //_____________________________________________________________________________ -Double_t TGeoTorus::DDaxis(Double_t *pt, Double_t *dir, Double_t t) const +Double_t TGeoTorus::DDaxis(const Double_t *pt, const Double_t *dir, Double_t t) const { // Computes derivative w.r.t. t of the distance to axis of the torus from point pt + t*dir; Double_t p[3]; @@ -243,7 +243,7 @@ Double_t TGeoTorus::DDaxis(Double_t *pt, Double_t *dir, Double_t t) const } //_____________________________________________________________________________ -Double_t TGeoTorus::DDDaxis(Double_t *pt, Double_t *dir, Double_t t) const +Double_t TGeoTorus::DDDaxis(const Double_t *pt, const Double_t *dir, Double_t t) const { // Second derivative of distance to torus axis w.r.t t. Double_t p[3]; @@ -260,7 +260,7 @@ Double_t TGeoTorus::DDDaxis(Double_t *pt, Double_t *dir, Double_t t) const } //_____________________________________________________________________________ -Double_t TGeoTorus::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoTorus::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from inside point to surface of the torus. if (iact<3 && safe) { @@ -298,7 +298,7 @@ Double_t TGeoTorus::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, D } //_____________________________________________________________________________ -Double_t TGeoTorus::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoTorus::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from outside point to surface of the torus. if (iact<3 && safe) { @@ -686,7 +686,7 @@ void TGeoTorus::SetSegsAndPols(TBuffer3D &buff) const } //_____________________________________________________________________________ -Double_t TGeoTorus::Safety(Double_t *point, Bool_t in) const +Double_t TGeoTorus::Safety(const Double_t *point, Bool_t in) const { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. @@ -714,17 +714,17 @@ Double_t TGeoTorus::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -void TGeoTorus::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoTorus::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " r = " << fR << ";" << endl; - out << " rmin = " << fRmin << ";" << endl; - out << " rmax = " << fRmax << ";" << endl; - out << " phi1 = " << fPhi1 << ";" << endl; - out << " dphi = " << fDphi << ";" << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoTorus(\"" << GetName() << "\",r,rmin,rmax,phi1,dphi);" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " r = " << fR << ";" << std::endl; + out << " rmin = " << fRmin << ";" << std::endl; + out << " rmax = " << fRmax << ";" << std::endl; + out << " phi1 = " << fPhi1 << ";" << std::endl; + out << " dphi = " << fDphi << ";" << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoTorus(\"" << GetName() << "\",r,rmin,rmax,phi1,dphi);" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -1032,7 +1032,7 @@ Int_t TGeoTorus::SolveQuartic(Double_t a, Double_t b, Double_t c, Double_t d, Do } //_____________________________________________________________________________ -Double_t TGeoTorus::ToBoundary(Double_t *pt, Double_t *dir, Double_t r, Bool_t in) const +Double_t TGeoTorus::ToBoundary(const Double_t *pt, const Double_t *dir, Double_t r, Bool_t in) const { // Returns distance to the surface or the torus (fR,r) from a point, along // a direction. Point is close enough to the boundary so that the distance @@ -1186,3 +1186,43 @@ const TBuffer3D & TGeoTorus::GetBuffer3D(Int_t reqSections, Bool_t localFrame) c return buffer; } +//_____________________________________________________________________________ +void TGeoTorus::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; i fDz) return kFALSE; @@ -250,7 +251,7 @@ Int_t TGeoTube::DistancetoPrimitive(Int_t px, Int_t py) } //_____________________________________________________________________________ -Double_t TGeoTube::DistFromInsideS(Double_t *point, Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz) +Double_t TGeoTube::DistFromInsideS(const Double_t *point, const Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz) { // Compute distance from inside point to surface of the tube (static) // Boundary safe algorithm. @@ -296,7 +297,7 @@ Double_t TGeoTube::DistFromInsideS(Double_t *point, Double_t *dir, Double_t rmin } //_____________________________________________________________________________ -Double_t TGeoTube::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoTube::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from inside point to surface of the tube // Boundary safe algorithm. @@ -310,7 +311,7 @@ Double_t TGeoTube::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Do } //_____________________________________________________________________________ -Double_t TGeoTube::DistFromOutsideS(Double_t *point, Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz) +Double_t TGeoTube::DistFromOutsideS(const Double_t *point, const Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz) { // Static method to compute distance from outside point to a tube with given parameters // Boundary safe algorithm. @@ -397,7 +398,7 @@ Double_t TGeoTube::DistFromOutsideS(Double_t *point, Double_t *dir, Double_t rmi } //_____________________________________________________________________________ -Double_t TGeoTube::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoTube::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from outside point to surface of the tube and safe distance // Boundary safe algorithm. @@ -557,7 +558,7 @@ void TGeoTube::GetBoundingCylinder(Double_t *param) const param[1] = fRmax; // Rmax param[1] *= param[1]; param[2] = 0.; // Phi1 - param[3] = 360.; // Phi1 + param[3] = 360.; // Phi2 } //_____________________________________________________________________________ @@ -781,7 +782,7 @@ void TGeoTube::SetSegsAndPols(TBuffer3D &buffer) const } //_____________________________________________________________________________ -Double_t TGeoTube::Safety(Double_t *point, Bool_t in) const +Double_t TGeoTube::Safety(const Double_t *point, Bool_t in) const { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. @@ -820,7 +821,7 @@ Double_t TGeoTube::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -Double_t TGeoTube::SafetyS(Double_t *point, Bool_t in, Double_t rmin, Double_t rmax, Double_t dz, Int_t skipz) +Double_t TGeoTube::SafetyS(const Double_t *point, Bool_t in, Double_t rmin, Double_t rmax, Double_t dz, Int_t skipz) { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. @@ -849,15 +850,15 @@ Double_t TGeoTube::SafetyS(Double_t *point, Bool_t in, Double_t rmin, Double_t r } //_____________________________________________________________________________ -void TGeoTube::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoTube::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " rmin = " << fRmin << ";" << endl; - out << " rmax = " << fRmax << ";" << endl; - out << " dz = " << fDz << ";" << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoTube(\"" << GetName() << "\",rmin,rmax,dz);" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " rmin = " << fRmin << ";" << std::endl; + out << " rmax = " << fRmax << ";" << std::endl; + out << " dz = " << fDz << ";" << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoTube(\"" << GetName() << "\",rmin,rmax,dz);" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -1129,35 +1130,80 @@ const TBuffer3D & TGeoTube::GetBuffer3D(Int_t reqSections, Bool_t localFrame) co return buffer; } +//_____________________________________________________________________________ +void TGeoTube::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; i1E-10)?TMath::Abs(r-fRmin):TGeoShape::Big(); saf[2] = TMath::Abs(fRmax-r); Int_t i = TMath::LocMin(3,saf); - if (((fPhi2-fPhi1)<360.) && TGeoShape::IsCloseToPhi(saf[i], point,c1,s1,c2,s2)) { - TGeoShape::NormalPhi(point,dir,norm,c1,s1,c2,s2); + if (((fPhi2-fPhi1)<360.) && TGeoShape::IsCloseToPhi(saf[i], point,fC1,fS1,fC2,fS2)) { + TGeoShape::NormalPhi(point,dir,norm,fC1,fS1,fC2,fS2); return; } if (i==0) { norm[0] = norm[1] = 0.; norm[2] = TMath::Sign(1.,dir[2]); return; - } + }; norm[2] = 0; Double_t phi = TMath::ATan2(point[1], point[0]); norm[0] = TMath::Cos(phi); @@ -1278,7 +1344,7 @@ void TGeoTubeSeg::ComputeNormal(Double_t *point, Double_t *dir, Double_t *norm) } //_____________________________________________________________________________ -void TGeoTubeSeg::ComputeNormalS(Double_t *point, Double_t *dir, Double_t *norm, +void TGeoTubeSeg::ComputeNormalS(const Double_t *point, const Double_t *dir, Double_t *norm, Double_t rmin, Double_t rmax, Double_t /*dz*/, Double_t c1, Double_t s1, Double_t c2, Double_t s2) { @@ -1304,7 +1370,7 @@ void TGeoTubeSeg::ComputeNormalS(Double_t *point, Double_t *dir, Double_t *norm, } //_____________________________________________________________________________ -Bool_t TGeoTubeSeg::Contains(Double_t *point) const +Bool_t TGeoTubeSeg::Contains(const Double_t *point) const { // test if point is inside this tube segment // first check if point is inside the tube @@ -1322,7 +1388,7 @@ Int_t TGeoTubeSeg::DistancetoPrimitive(Int_t px, Int_t py) } //_____________________________________________________________________________ -Double_t TGeoTubeSeg::DistFromInsideS(Double_t *point, Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz, +Double_t TGeoTubeSeg::DistFromInsideS(const Double_t *point, const Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz, Double_t c1, Double_t s1, Double_t c2, Double_t s2, Double_t cm, Double_t sm, Double_t cdfi) { // Compute distance from inside point to surface of the tube segment (static) @@ -1370,7 +1436,7 @@ Double_t TGeoTubeSeg::DistFromInsideS(Double_t *point, Double_t *dir, Double_t r } //_____________________________________________________________________________ -Double_t TGeoTubeSeg::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoTubeSeg::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // Compute distance from inside point to surface of the tube segment // Boundary safe algorithm. @@ -1380,24 +1446,13 @@ Double_t TGeoTubeSeg::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, if ((iact==1) && (*safe>step)) return TGeoShape::Big(); } if ((fPhi2-fPhi1)>=360.) return TGeoTube::DistFromInsideS(point,dir,fRmin,fRmax,fDz); - Double_t phi1 = fPhi1*TMath::DegToRad(); - Double_t phi2 = fPhi2*TMath::DegToRad(); - Double_t c1 = TMath::Cos(phi1); - Double_t c2 = TMath::Cos(phi2); - Double_t s1 = TMath::Sin(phi1); - Double_t s2 = TMath::Sin(phi2); - Double_t phim = 0.5*(phi1+phi2); - Double_t cm = TMath::Cos(phim); - Double_t sm = TMath::Sin(phim); - Double_t dfi = 0.5*(phi2-phi1); - Double_t cdfi = TMath::Cos(dfi); // compute distance to surface - return TGeoTubeSeg::DistFromInsideS(point,dir,fRmin,fRmax,fDz,c1,s1,c2,s2,cm,sm,cdfi); + return TGeoTubeSeg::DistFromInsideS(point,dir,fRmin,fRmax,fDz,fC1,fS1,fC2,fS2,fCm,fSm,fCdfi); } //_____________________________________________________________________________ -Double_t TGeoTubeSeg::DistFromOutsideS(Double_t *point, Double_t *dir, Double_t rmin, Double_t rmax, +Double_t TGeoTubeSeg::DistFromOutsideS(const Double_t *point, const Double_t *dir, Double_t rmin, Double_t rmax, Double_t dz, Double_t c1, Double_t s1, Double_t c2, Double_t s2, Double_t cm, Double_t sm, Double_t cdfi) { @@ -1653,7 +1708,7 @@ Double_t TGeoTubeSeg::DistFromOutsideS(Double_t *point, Double_t *dir, Double_t } //_____________________________________________________________________________ -Double_t TGeoTubeSeg::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoTubeSeg::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from outside point to surface of the tube segment // fist localize point w.r.t tube @@ -1666,20 +1721,9 @@ Double_t TGeoTubeSeg::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact Double_t sdist = TGeoBBox::DistFromOutside(point,dir, fDX, fDY, fDZ, fOrigin, step); if (sdist>=step) return TGeoShape::Big(); if ((fPhi2-fPhi1)>=360.) return TGeoTube::DistFromOutsideS(point,dir,fRmin,fRmax,fDz); - Double_t phi1 = fPhi1*TMath::DegToRad(); - Double_t phi2 = fPhi2*TMath::DegToRad(); - Double_t c1 = TMath::Cos(phi1); - Double_t s1 = TMath::Sin(phi1); - Double_t c2 = TMath::Cos(phi2); - Double_t s2 = TMath::Sin(phi2); - Double_t fio = 0.5*(phi1+phi2); - Double_t cm = TMath::Cos(fio); - Double_t sm = TMath::Sin(fio); - Double_t dfi = 0.5*(phi2-phi1); - Double_t cdfi = TMath::Cos(dfi); // find distance to shape - return TGeoTubeSeg::DistFromOutsideS(point, dir, fRmin, fRmax, fDz, c1, s1, c2, s2, cm, sm, cdfi); + return TGeoTubeSeg::DistFromOutsideS(point, dir, fRmin, fRmax, fDz, fC1, fS1, fC2, fS2, fCm, fSm, fCdfi); } //_____________________________________________________________________________ @@ -1935,9 +1979,9 @@ void TGeoTubeSeg::SetSegsAndPols(TBuffer3D &buff) const } //_____________________________________________________________________________ -Double_t TGeoTubeSeg::Safety(Double_t *point, Bool_t in) const +Double_t TGeoTubeSeg::Safety(const Double_t *point, Bool_t in) const { -// computes the closest distance from given point to this shape, according +// computes the closest distance from given point InitTrigonometry();to this shape, according // to option. The matching point on the shape is stored in spoint. Double_t saf[3]; Double_t rsq = point[0]*point[0]+point[1]*point[1]; @@ -1964,7 +2008,7 @@ Double_t TGeoTubeSeg::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -Double_t TGeoTubeSeg::SafetyS(Double_t *point, Bool_t in, Double_t rmin, Double_t rmax, Double_t dz, +Double_t TGeoTubeSeg::SafetyS(const Double_t *point, Bool_t in, Double_t rmin, Double_t rmax, Double_t dz, Double_t phi1, Double_t phi2, Int_t skipz) { // Static method to compute the closest distance from given point to this shape. @@ -2001,33 +2045,35 @@ Double_t TGeoTubeSeg::SafetyS(Double_t *point, Bool_t in, Double_t rmin, Double_ } //_____________________________________________________________________________ -void TGeoTubeSeg::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoTubeSeg::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " rmin = " << fRmin << ";" << endl; - out << " rmax = " << fRmax << ";" << endl; - out << " dz = " << fDz << ";" << endl; - out << " phi1 = " << fPhi1 << ";" << endl; - out << " phi2 = " << fPhi2 << ";" << endl; - out << " TGeoShape *" << GetPointerName() << " = new TGeoTubeSeg(\"" << GetName() << "\",rmin,rmax,dz,phi1,phi2);" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " rmin = " << fRmin << ";" << std::endl; + out << " rmax = " << fRmax << ";" << std::endl; + out << " dz = " << fDz << ";" << std::endl; + out << " phi1 = " << fPhi1 << ";" << std::endl; + out << " phi2 = " << fPhi2 << ";" << std::endl; + out << " TGeoShape *" << GetPointerName() << " = new TGeoTubeSeg(\"" << GetName() << "\",rmin,rmax,dz,phi1,phi2);" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } //_____________________________________________________________________________ void TGeoTubeSeg::SetTubsDimensions(Double_t rmin, Double_t rmax, Double_t dz, - Double_t phi1, Double_t phi2) + Double_t phiStart, Double_t phiEnd) { -// Set dimensions of the tube segment. + // Set dimensions of the tube segment. + // The segment will be from phiStart to phiEnd expressed in degree. fRmin = rmin; fRmax = rmax; fDz = dz; - fPhi1 = phi1; - if (fPhi1 < 0) fPhi1+=360.; - fPhi2 = phi2; + fPhi1 = phiStart; + if (fPhi1 < 0) fPhi1 += 360.; + fPhi2 = phiEnd; while (fPhi2<=fPhi1) fPhi2+=360.; - if (TGeoShape::IsSameWithinTolerance(fPhi1,fPhi2)) Error("SetTubsDimensions", "In shape %s invalid phi1=%g, phi2=%g\n", GetName(), fPhi1, fPhi2); + if (TGeoShape::IsSameWithinTolerance(fPhi1,fPhi2)) Fatal("SetTubsDimensions", "In shape %s invalid phi1=%g, phi2=%g\n", GetName(), fPhi1, fPhi2); + InitTrigonometry(); } //_____________________________________________________________________________ @@ -2235,6 +2281,47 @@ const TBuffer3D & TGeoTubeSeg::GetBuffer3D(Int_t reqSections, Bool_t localFrame) return buffer; } +//_____________________________________________________________________________ +void TGeoTubeSeg::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; i=cdfi) return s; + cpsi=(xi*fCm+yi*fSm)/TMath::Sqrt(r2); + if (cpsi>=fCdfi) return s; } } } @@ -2578,8 +2647,8 @@ Double_t TGeoCtub::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, D r2=xi*xi+yi*yi; if (((fRmin*fRmin)<=r2) && (r2<=(fRmax*fRmax))) { if (tub) return s; - cpsi=(xi*cfio+yi*sfio)/TMath::Sqrt(r2); - if (cpsi>=cdfi) return s; + cpsi=(xi*fCm+yi*fSm)/TMath::Sqrt(r2); + if (cpsi>=fCdfi) return s; } } } @@ -2601,8 +2670,8 @@ Double_t TGeoCtub::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, D if ((-xi*fNlow[0]-yi*fNlow[1]-(zi+fDz)*fNlow[2])>0) { if ((-xi*fNhigh[0]-yi*fNhigh[1]+(fDz-zi)*fNhigh[2])>0) { if (tub) return s; - cpsi=(xi*cfio+yi*sfio)/fRmax; - if (cpsi>=cdfi) return s; + cpsi=(xi*fCm+yi*fSm)/fRmax; + if (cpsi>=fCdfi) return s; } } } @@ -2621,8 +2690,8 @@ Double_t TGeoCtub::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, D if ((-xi*fNlow[0]-yi*fNlow[1]-(zi+fDz)*fNlow[2])>0) { if ((-xi*fNhigh[0]-yi*fNhigh[1]+(fDz-zi)*fNhigh[2])>0) { if (tub) return s; - cpsi=(xi*cfio+yi*sfio)/fRmin; - if (cpsi>=cdfi) snxt=s; + cpsi=(xi*fCm+yi*fSm)/fRmin; + if (cpsi>=fCdfi) snxt=s; } } } @@ -2630,9 +2699,9 @@ Double_t TGeoCtub::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, D } // check phi planes if (tub) return snxt; - Double_t un=dir[0]*s1-dir[1]*c1; + Double_t un=dir[0]*fS1-dir[1]*fC1; if (un<-TGeoShape::Tolerance()) { - s=(point[1]*c1-point[0]*s1)/un; + s=(point[1]*fC1-point[0]*fS1)/un; if (s>=0) { xi=point[0]+s*dir[0]; yi=point[1]+s*dir[1]; @@ -2641,7 +2710,7 @@ Double_t TGeoCtub::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, D if ((-xi*fNhigh[0]-yi*fNhigh[1]+(fDz-zi)*fNhigh[2])>0) { r2=xi*xi+yi*yi; if ((fRmin*fRmin<=r2) && (r2<=fRmax*fRmax)) { - if ((yi*cfio-xi*sfio)<=0) { + if ((yi*fCm-xi*fSm)<=0) { if (sTGeoShape::Tolerance()) { - s=(point[1]*c2-point[0]*s2)/un; + s=(point[1]*fC2-point[0]*fS2)/un; if (s>=0) { xi=point[0]+s*dir[0]; yi=point[1]+s*dir[1]; @@ -2660,7 +2729,7 @@ Double_t TGeoCtub::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, D if ((-xi*fNhigh[0]-yi*fNhigh[1]+(fDz-zi)*fNhigh[2])>0) { r2=xi*xi+yi*yi; if ((fRmin*fRmin<=r2) && (r2<=fRmax*fRmax)) { - if ((yi*cfio-xi*sfio)>=0) { + if ((yi*fCm-xi*fSm)>=0) { if (sstep)) return TGeoShape::Big(); Double_t rsq = point[0]*point[0]+point[1]*point[1]; - Double_t c1=0,s1=0,c2=0,s2=0,cm=0,sm=0,phim=0; - Double_t phi1 = fPhi1*TMath::DegToRad(); - Double_t phi2 = fPhi2*TMath::DegToRad(); Bool_t tub = kFALSE; if (TMath::Abs(fPhi2-fPhi1-360.)<1E-8) tub = kTRUE; - if (!tub) { - if (phi2GetMaterial()) fMedium->GetMaterial()->SetUsed(); fFinder = 0; fVoxels = 0; + fGeoManager = gGeoManager; fField = 0; fOption = ""; - fMedium = (TGeoMedium*)med; - if (fMedium) { - if (fMedium->GetMaterial()) fMedium->GetMaterial()->SetUsed(); - } fNumber = 0; fNtotal = 0; - fGeoManager = gGeoManager; + fUserExtension = 0; + fFWExtension = 0; if (fGeoManager) fNumber = fGeoManager->AddVolume(this); TObject::ResetBit(kVolumeImportNodes); } @@ -436,7 +439,9 @@ TGeoVolume::TGeoVolume(const TGeoVolume& gv) : fField(gv.fField), fOption(gv.fOption), fNumber(gv.fNumber), - fNtotal(gv.fNtotal) + fNtotal(gv.fNtotal), + fUserExtension(gv.fUserExtension->Grab()), + fFWExtension(gv.fFWExtension->Grab()) { //copy constructor } @@ -461,6 +466,8 @@ TGeoVolume& TGeoVolume::operator=(const TGeoVolume& gv) fOption=gv.fOption; fNumber=gv.fNumber; fNtotal=gv.fNtotal; + fUserExtension = gv.fUserExtension->Grab(); + fFWExtension = gv.fFWExtension->Grab(); } return *this; } @@ -478,6 +485,8 @@ TGeoVolume::~TGeoVolume() } if (fFinder && !TObject::TestBit(kVolumeImportNodes | kVolumeClone) ) delete fFinder; if (fVoxels) delete fVoxels; + if (fUserExtension) {fUserExtension->Release(); fUserExtension=0;} + if (fFWExtension) {fFWExtension->Release(); fFWExtension=0;} } //_____________________________________________________________________________ @@ -491,7 +500,7 @@ void TGeoVolume::Browse(TBrowser *b) TString title; for (Int_t i=0; iGetVolume(); - if(!strlen(daughter->GetTitle())) { + if(daughter->GetTitle()[0]) { if (daughter->IsAssembly()) title.TString::Format("Assembly with %d daughter(s)", daughter->GetNdaughters()); else if (daughter->GetFinder()) { @@ -619,7 +628,7 @@ void TGeoVolume::CheckShapes() for (Int_t i=0; iAt(i); // check if node has name - if (!strlen(node->GetName())) printf("Daughter %i of volume %s - NO NAME!!!\n", + if (!node->GetName()[0]) printf("Daughter %i of volume %s - NO NAME!!!\n", i, GetName()); old_vol = node->GetVolume(); shape = old_vol->GetShape(); @@ -629,6 +638,10 @@ void TGeoVolume::CheckShapes() // old_vol->InspectShape(); // make a copy of the node new_node = node->MakeCopyNode(); + if (!new_node) { + Fatal("CheckShapes", "Cannot make copy node for %s", node->GetName()); + return; + } TGeoShape *new_shape = shape->GetMakeRuntimeShape(fShape, node->GetMatrix()); if (!new_shape) { Error("CheckShapes","cannot resolve runtime shape for volume %s/%s\n", @@ -795,7 +808,7 @@ TGeoVolume *TGeoVolume::Import(const char *filename, const char *name, Option_t printf("Error: TGeoVolume::Import : Cannot open file %s\n", filename); return 0; } - if (name && strlen(name) > 0) { + if (name && name[0]) { volume = (TGeoVolume*)f->Get(name); } else { TIter next(f->GetListOfKeys()); @@ -898,8 +911,8 @@ void TGeoVolume::AddNode(const TGeoVolume *vol, Int_t copy_no, TGeoMatrix *mat, node->SetMotherVolume(this); fNodes->Add(node); TString name = TString::Format("%s_%d", vol->GetName(), copy_no); - if (fNodes->FindObject(name)) - Warning("AddNode", "Volume %s : added node %s with same name", GetName(), name.Data()); +// if (fNodes->FindObject(name)) +// Warning("AddNode", "Volume %s : added node %s with same name", GetName(), name.Data()); node->SetName(name); node->SetNumber(copy_no); } @@ -1083,7 +1096,7 @@ void TGeoVolume::Draw(Option_t *option) TVirtualGeoPainter *painter = fGeoManager->GetGeomPainter(); TGeoAtt::SetVisRaytrace(kFALSE); if (!IsVisContainers()) SetVisLeaves(); - if (option && strlen(option) > 0) { + if (option && option[0] > 0) { painter->DrawVolume(this, option); } else { painter->DrawVolume(this, gEnv->GetValue("Viewer3D.DefaultDrawOption","")); @@ -1102,7 +1115,7 @@ void TGeoVolume::DrawOnly(Option_t *option) SetVisOnly(); TGeoAtt::SetVisRaytrace(kFALSE); TVirtualGeoPainter *painter = fGeoManager->GetGeomPainter(); - if (option && strlen(option) > 0) { + if (option && option[0] > 0) { painter->DrawVolume(this, option); } else { painter->DrawVolume(this, gEnv->GetValue("Viewer3D.DefaultDrawOption","")); @@ -1126,7 +1139,7 @@ void TGeoVolume::Paint(Option_t *option) TVirtualGeoPainter *painter = fGeoManager->GetGeomPainter(); painter->SetTopVolume(this); // painter->Paint(option); - if (option && strlen(option) > 0) { + if (option && option[0] > 0) { painter->Paint(option); } else { painter->Paint(gEnv->GetValue("Viewer3D.DefaultDrawOption","")); @@ -1243,14 +1256,14 @@ void TGeoVolume::RandomPoints(Int_t npoints, Option_t *option) } //_____________________________________________________________________________ -void TGeoVolume::RandomRays(Int_t nrays, Double_t startx, Double_t starty, Double_t startz) +void TGeoVolume::RandomRays(Int_t nrays, Double_t startx, Double_t starty, Double_t startz, const char *target_vol, Bool_t check_norm) { // Random raytracing method. if (gGeoManager != fGeoManager) gGeoManager = fGeoManager; TGeoVolume *old_vol = fGeoManager->GetTopVolume(); if (old_vol!=this) fGeoManager->SetTopVolume(this); else old_vol=0; - fGeoManager->RandomRays(nrays, startx, starty, startz); + fGeoManager->RandomRays(nrays, startx, starty, startz, target_vol, check_norm); if (old_vol) fGeoManager->SetTopVolume(old_vol); } @@ -1277,8 +1290,8 @@ void TGeoVolume::SaveAs(const char *filename, Option_t *option) const { // Save geometry having this as top volume as a C++ macro. if (!filename) return; - ofstream out; - out.open(filename, ios::out); + std::ofstream out; + out.open(filename, std::ios::out); if (out.bad()) { Error("SavePrimitive", "Bad file name: %s", filename); return; @@ -1288,18 +1301,68 @@ void TGeoVolume::SaveAs(const char *filename, Option_t *option) const TString fname(filename); Int_t ind = fname.Index("."); if (ind>0) fname.Remove(ind); - out << "void "<Load(\"libGeom\");" << endl; + out << "void "<Load(\"libGeom\");" << std::endl; ((TGeoVolume*)this)->SavePrimitive(out,option); - out << "}" << endl; + out << "}" << std::endl; } //______________________________________________________________________________ -void TGeoVolume::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGeoVolume::SetUserExtension(TGeoExtension *ext) +{ +// Connect user-defined extension to the volume. The volume "grabs" a copy, so +// the original object can be released by the producer. Release the previously +// connected extension if any. +//========================================================================== +// NOTE: This interface is intended for user extensions and is guaranteed not +// to be used by TGeo +//========================================================================== + if (fUserExtension) fUserExtension->Release(); + fUserExtension = 0; + if (ext) fUserExtension = ext->Grab(); +} + +//_____________________________________________________________________________ +void TGeoVolume::SetFWExtension(TGeoExtension *ext) +{ +// Connect framework defined extension to the volume. The volume "grabs" a copy, +// so the original object can be released by the producer. Release the previously +// connected extension if any. +//========================================================================== +// NOTE: This interface is intended for the use by TGeo and the users should +// NOT connect extensions using this method +//========================================================================== + if (fFWExtension) fFWExtension->Release(); + fFWExtension = 0; + if (ext) fFWExtension = ext->Grab(); +} + +//_____________________________________________________________________________ +TGeoExtension *TGeoVolume::GrabUserExtension() const +{ +// Get a copy of the user extension pointer. The user must call Release() on +// the copy pointer once this pointer is not needed anymore (equivalent to +// delete() after calling new()) + if (fUserExtension) return fUserExtension->Grab(); + return 0; +} + +//_____________________________________________________________________________ +TGeoExtension *TGeoVolume::GrabFWExtension() const +{ +// Get a copy of the framework extension pointer. The user must call Release() on +// the copy pointer once this pointer is not needed anymore (equivalent to +// delete() after calling new()) + if (fFWExtension) return fFWExtension->Grab(); + return 0; +} + +//_____________________________________________________________________________ +void TGeoVolume::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". out.precision(6); - out.setf(ios::fixed); + out.setf(std::ios::fixed); Int_t i,icopy; Int_t nd = GetNdaughters(); TGeoVolume *dvol; @@ -1309,50 +1372,50 @@ void TGeoVolume::SavePrimitive(ostream &out, Option_t *option /*= ""*/) // check if we need to save shape/volume Bool_t mustDraw = kFALSE; if (fGeoManager->GetGeomPainter()->GetTopVolume()==this) mustDraw = kTRUE; - if (!strlen(option)) { + if (!option[0]) { fGeoManager->SetAllIndex(); - out << " new TGeoManager(\"" << fGeoManager->GetName() << "\", \"" << fGeoManager->GetTitle() << "\");" << endl << endl; -// if (mustDraw) out << " Bool_t mustDraw = kTRUE;" << endl; -// else out << " Bool_t mustDraw = kFALSE;" << endl; - out << " Double_t dx,dy,dz;" << endl; - out << " Double_t dx1, dx2, dy1, dy2;" << endl; - out << " Double_t vert[20], par[20];" << endl; - out << " Double_t theta, phi, h1, bl1, tl1, alpha1, h2, bl2, tl2, alpha2;" << endl; - out << " Double_t twist;" << endl; - out << " Double_t origin[3];" << endl; - out << " Double_t rmin, rmax, rmin1, rmax1, rmin2, rmax2;" << endl; - out << " Double_t r, rlo, rhi;" << endl; - out << " Double_t phi1, phi2;" << endl; - out << " Double_t a,b;" << endl; - out << " Double_t point[3], norm[3];" << endl; - out << " Double_t rin, stin, rout, stout;" << endl; - out << " Double_t thx, phx, thy, phy, thz, phz;" << endl; - out << " Double_t alpha, theta1, theta2, phi1, phi2, dphi;" << endl; - out << " Double_t tr[3], rot[9];" << endl; - out << " Double_t z, density, radl, absl, w;" << endl; - out << " Double_t lx,ly,lz,tx,ty,tz;" << endl; - out << " Double_t xvert[50], yvert[50];" << endl; - out << " Double_t zsect,x0,y0,scale0;" << endl; - out << " Int_t nel, numed, nz, nedges, nvert;" << endl; - out << " TGeoBoolNode *pBoolNode = 0;" << endl << endl; + out << " new TGeoManager(\"" << fGeoManager->GetName() << "\", \"" << fGeoManager->GetTitle() << "\");" << std::endl << std::endl; +// if (mustDraw) out << " Bool_t mustDraw = kTRUE;" << std::endl; +// else out << " Bool_t mustDraw = kFALSE;" << std::endl; + out << " Double_t dx,dy,dz;" << std::endl; + out << " Double_t dx1, dx2, dy1, dy2;" << std::endl; + out << " Double_t vert[20], par[20];" << std::endl; + out << " Double_t theta, phi, h1, bl1, tl1, alpha1, h2, bl2, tl2, alpha2;" << std::endl; + out << " Double_t twist;" << std::endl; + out << " Double_t origin[3];" << std::endl; + out << " Double_t rmin, rmax, rmin1, rmax1, rmin2, rmax2;" << std::endl; + out << " Double_t r, rlo, rhi;" << std::endl; + out << " Double_t phi1, phi2;" << std::endl; + out << " Double_t a,b;" << std::endl; + out << " Double_t point[3], norm[3];" << std::endl; + out << " Double_t rin, stin, rout, stout;" << std::endl; + out << " Double_t thx, phx, thy, phy, thz, phz;" << std::endl; + out << " Double_t alpha, theta1, theta2, phi1, phi2, dphi;" << std::endl; + out << " Double_t tr[3], rot[9];" << std::endl; + out << " Double_t z, density, radl, absl, w;" << std::endl; + out << " Double_t lx,ly,lz,tx,ty,tz;" << std::endl; + out << " Double_t xvert[50], yvert[50];" << std::endl; + out << " Double_t zsect,x0,y0,scale0;" << std::endl; + out << " Int_t nel, numed, nz, nedges, nvert;" << std::endl; + out << " TGeoBoolNode *pBoolNode = 0;" << std::endl << std::endl; // first save materials/media - out << " // MATERIALS, MIXTURES AND TRACKING MEDIA" << endl; + out << " // MATERIALS, MIXTURES AND TRACKING MEDIA" << std::endl; SavePrimitive(out, "m"); // then, save matrices - out << endl << " // TRANSFORMATION MATRICES" << endl; + out << std::endl << " // TRANSFORMATION MATRICES" << std::endl; SavePrimitive(out, "x"); // save this volume and shape SavePrimitive(out, "s"); - out << endl << " // SET TOP VOLUME OF GEOMETRY" << endl; - out << " gGeoManager->SetTopVolume(" << GetPointerName() << ");" << endl; + out << std::endl << " // SET TOP VOLUME OF GEOMETRY" << std::endl; + out << " gGeoManager->SetTopVolume(" << GetPointerName() << ");" << std::endl; // save daughters - out << endl << " // SHAPES, VOLUMES AND GEOMETRICAL HIERARCHY" << endl; + out << std::endl << " // SHAPES, VOLUMES AND GEOMETRICAL HIERARCHY" << std::endl; SavePrimitive(out, "d"); - out << endl << " // CLOSE GEOMETRY" << endl; - out << " gGeoManager->CloseGeometry();" << endl; + out << std::endl << " // CLOSE GEOMETRY" << std::endl; + out << " gGeoManager->CloseGeometry();" << std::endl; if (mustDraw) { - if (!IsRaytracing()) out << " gGeoManager->GetTopVolume()->Draw();" << endl; - else out << " gGeoManager->GetTopVolume()->Raytrace();" << endl; + if (!IsRaytracing()) out << " gGeoManager->GetTopVolume()->Draw();" << std::endl; + else out << " gGeoManager->GetTopVolume()->Raytrace();" << std::endl; } return; } @@ -1362,19 +1425,19 @@ void TGeoVolume::SavePrimitive(ostream &out, Option_t *option /*= ""*/) if (TestAttBit(TGeoAtt::kSavePrimitiveAtt)) return; if (!IsAssembly()) { fShape->SavePrimitive(out,option); - out << " // Volume: " << GetName() << endl; - out << " " << GetPointerName() << " = new TGeoVolume(\"" << GetName() << "\"," << fShape->GetPointerName() << ", "<< fMedium->GetPointerName() << ");" << endl; + out << " // Volume: " << GetName() << std::endl; + out << " " << GetPointerName() << " = new TGeoVolume(\"" << GetName() << "\"," << fShape->GetPointerName() << ", "<< fMedium->GetPointerName() << ");" << std::endl; } else { - out << " // Assembly: " << GetName() << endl; - out << " " << GetPointerName() << " = new TGeoVolumeAssembly(\"" << GetName() << "\"" << ");" << endl; + out << " // Assembly: " << GetName() << std::endl; + out << " " << GetPointerName() << " = new TGeoVolumeAssembly(\"" << GetName() << "\"" << ");" << std::endl; } - if (fLineColor != 1) out << " " << GetPointerName() << "->SetLineColor(" << fLineColor << ");" << endl; - if (fLineWidth != 1) out << " " << GetPointerName() << "->SetLineWidth(" << fLineWidth << ");" << endl; - if (fLineStyle != 1) out << " " << GetPointerName() << "->SetLineStyle(" << fLineStyle << ");" << endl; - if (!IsVisible() && !IsAssembly()) out << " " << GetPointerName() << "->SetVisibility(kFALSE);" << endl; - if (!IsVisibleDaughters()) out << " " << GetPointerName() << "->VisibleDaughters(kFALSE);" << endl; - if (IsVisContainers()) out << " " << GetPointerName() << "->SetVisContainers(kTRUE);" << endl; - if (IsVisLeaves()) out << " " << GetPointerName() << "->SetVisLeaves(kTRUE);" << endl; + if (fLineColor != 1) out << " " << GetPointerName() << "->SetLineColor(" << fLineColor << ");" << std::endl; + if (fLineWidth != 1) out << " " << GetPointerName() << "->SetLineWidth(" << fLineWidth << ");" << std::endl; + if (fLineStyle != 1) out << " " << GetPointerName() << "->SetLineStyle(" << fLineStyle << ");" << std::endl; + if (!IsVisible() && !IsAssembly()) out << " " << GetPointerName() << "->SetVisibility(kFALSE);" << std::endl; + if (!IsVisibleDaughters()) out << " " << GetPointerName() << "->VisibleDaughters(kFALSE);" << std::endl; + if (IsVisContainers()) out << " " << GetPointerName() << "->SetVisContainers(kTRUE);" << std::endl; + if (IsVisLeaves()) out << " " << GetPointerName() << "->SetVisLeaves(kTRUE);" << std::endl; SetAttBit(TGeoAtt::kSavePrimitiveAtt); } // check if we need to save the media @@ -1416,7 +1479,7 @@ void TGeoVolume::SavePrimitive(ostream &out, Option_t *option /*= ""*/) if (fMedium != dvol->GetMedium()) { out << ", " << dvol->GetMedium()->GetId(); } - out << ");" << endl; + out << ");" << std::endl; dvol->SavePrimitive(out,"d"); return; } @@ -1431,7 +1494,7 @@ void TGeoVolume::SavePrimitive(ostream &out, Option_t *option /*= ""*/) if (dnode->IsOverlapping()) out << "Overlap"; out << "(" << dvol->GetPointerName() << ", " << icopy; if (!matrix->IsIdentity()) out << ", " << matrix->GetPointerName(); - out << ");" << endl; + out << ");" << std::endl; } // Recursive loop to daughters for (i=0; iSetOption(fOption); vol->SetNumber(fNumber); vol->SetNtotal(fNtotal); + // copy extensions + vol->SetUserExtension(fUserExtension); + vol->SetFWExtension(fFWExtension); return vol; } @@ -1612,6 +1678,10 @@ void TGeoVolume::CloneNodesAndConnect(TGeoVolume *newmother) const for (Int_t i=0; iMakeCopyNode(); + if (!node) { + Fatal("CloneNodesAndConnect", "cannot make copy node"); + return; + } node->SetMotherVolume(newmother); list->Add(node); } @@ -1652,6 +1722,9 @@ TGeoVolume *TGeoVolume::MakeCopyVolume(TGeoShape *newshape) // Error("MakeCopyVolume", "volume %s divided", GetName()); vol->SetFinder(fFinder); } + // Copy extensions + vol->SetUserExtension(fUserExtension); + vol->SetFWExtension(fFWExtension); CloneNodesAndConnect(vol); // ((TObject*)vol)->SetBit(kVolumeImportNodes); ((TObject*)vol)->SetBit(kVolumeClone); @@ -1669,13 +1742,17 @@ TGeoVolume *TGeoVolume::MakeReflectedVolume(const char *newname) const } TGeoVolume *vol = (TGeoVolume*)map.GetValue(this); if (vol) { - if (strlen(newname)) vol->SetName(newname); + if (newname && newname[0]) vol->SetName(newname); return vol; } // printf("Making reflection for volume: %s\n", GetName()); vol = CloneVolume(); + if (!vol) { + Fatal("MakeReflectedVolume", "Cannot clone volume %s\n", GetName()); + return 0; + } map.Add((TObject*)this, vol); - if (strlen(newname)) vol->SetName(newname); + if (newname && newname[0]) vol->SetName(newname); delete vol->GetNodes(); vol->SetNodes(NULL); vol->SetBit(kVolumeImportNodes, kFALSE); @@ -1725,6 +1802,10 @@ TGeoVolume *TGeoVolume::MakeReflectedVolume(const char *newname) const // Volume is divided, so we have to reflect the division. // printf(" ... divided %s\n", fFinder->ClassName()); TGeoPatternFinder *new_finder = fFinder->MakeCopy(kTRUE); + if (!new_finder) { + Fatal("MakeReflectedVolume", "Could not copy finder for volume %s", GetName()); + return 0; + } new_finder->SetVolume(vol); vol->SetFinder(new_finder); TGeoNodeOffset *nodeoff; @@ -1878,9 +1959,9 @@ Int_t TGeoVolume::GetByteCount() const { // get the total size in bytes for this volume Int_t count = 28+2+6+4+0; // TNamed+TGeoAtt+TAttLine+TAttFill+TAtt3D - count += strlen(GetName()) + strlen(GetTitle()); // name+title - count += 4+4+4+4+4; // fShape + fMedium + fFinder + fField + fNodes - count += 8 + strlen(fOption.Data()); // fOption + count += fName.Capacity() + fTitle.Capacity(); // name+title + count += 7*sizeof(char*); // fShape + fMedium + fFinder + fField + fNodes + 2 extensions + count += fOption.Capacity(); // fOption if (fShape) count += fShape->GetByteCount(); if (fFinder) count += fFinder->GetByteCount(); if (fNodes) { @@ -1954,6 +2035,10 @@ TGeoNode *TGeoVolume::ReplaceNode(TGeoNode *nodeorig, TGeoShape *newshape, TGeoM // Make a copy of the node TGeoNode *newnode = nodeorig->MakeCopyNode(); // Change the volume for the new node + if (!newnode) { + Fatal("ReplaceNode", "Cannot make copy node for %s", nodeorig->GetName()); + return 0; + } newnode->SetVolume(vol); // Replace the matrix if (newpos && !nodeorig->IsOffset()) { @@ -2058,6 +2143,7 @@ Bool_t TGeoVolume::FindMatrixOfDaughterVolume(TGeoVolume *vol) const Int_t nd = GetNdaughters(); if (!nd) return kFALSE; TGeoHMatrix *global = fGeoManager->GetHMatrix(); + if (!global) return kFALSE; TGeoNode *dnode; TGeoVolume *dvol; TGeoMatrix *local; @@ -2244,6 +2330,10 @@ void TGeoVolumeMulti::AddVolume(TGeoVolume *vol) TGeoVolume *cell; if (fDivision) { div = (TGeoVolumeMulti*)vol->Divide(fDivision->GetName(), fAxis, fNdiv, fStart, fStep, fNumed, fOption.Data()); + if (!div) { + Fatal("AddVolume", "Cannot divide volume %s", vol->GetName()); + return; + } for (Int_t i=0; iGetNvolumes(); i++) { cell = div->GetVolume(i); fDivision->AddVolume(cell); @@ -2300,7 +2390,15 @@ void TGeoVolumeMulti::AddNodeOverlap(const TGeoVolume *vol, Int_t copy_no, TGeoM // printf("--- vmulti %s : node ovlp %s added to %i components\n", GetName(), vol->GetName(), nvolumes); } - +//_____________________________________________________________________________ +TGeoShape *TGeoVolumeMulti::GetLastShape() const +{ +// Returns the last shape. + TGeoVolume *vol = GetVolume(fVolumes->GetEntriesFast()-1); + if (!vol) return 0; + return vol->GetShape(); +} + //_____________________________________________________________________________ TGeoVolume *TGeoVolumeMulti::Divide(const char *divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step, Int_t numed, const char *option) { @@ -2367,6 +2465,9 @@ TGeoVolume *TGeoVolumeMulti::MakeCopyVolume(TGeoShape *newshape) vol->SetFillStyle(GetFillStyle()); // copy field vol->SetField(fField); + // Copy extensions + vol->SetUserExtension(fUserExtension); + vol->SetFWExtension(fFWExtension); // if divided, copy division object // if (fFinder) { // Error("MakeCopyVolume", "volume %s divided", GetName()); @@ -2375,6 +2476,10 @@ TGeoVolume *TGeoVolumeMulti::MakeCopyVolume(TGeoShape *newshape) if (fDivision) { TGeoVolume *cell; TGeoVolumeMulti *div = (TGeoVolumeMulti*)vol->Divide(fDivision->GetName(), fAxis, fNdiv, fStart, fStep, fNumed, fOption.Data()); + if (!div) { + Fatal("MakeCopyVolume", "Cannot divide volume %s", vol->GetName()); + return 0; + } for (i=0; iGetNvolumes(); i++) { cell = div->GetVolume(i); fDivision->AddVolume(cell); @@ -2393,6 +2498,10 @@ TGeoVolume *TGeoVolumeMulti::MakeCopyVolume(TGeoShape *newshape) for (i=0; iMakeCopyNode(); + if (!node) { + Fatal("MakeCopyNode", "cannot make copy node for daughter %d of %s", i, GetName()); + return 0; + } node->SetMotherVolume(vol); list->Add(node); } @@ -2527,6 +2636,7 @@ void TGeoVolumeAssembly::CreateThreadData(Int_t nthreads) fThreadData[tid] = new ThreadData_t; } } + TGeoVolume::CreateThreadData(nthreads); TThread::UnLock(); } diff --git a/geom/geom/src/TGeoVoxelFinder.cxx b/geom/geom/src/TGeoVoxelFinder.cxx index 98135e24899c1..bfe088e0a8b6d 100644 --- a/geom/geom/src/TGeoVoxelFinder.cxx +++ b/geom/geom/src/TGeoVoxelFinder.cxx @@ -302,7 +302,7 @@ void TGeoVoxelFinder::BuildVoxelLimits() } //_____________________________________________________________________________ -void TGeoVoxelFinder::DaughterToMother(Int_t id, Double_t *local, Double_t *master) const +void TGeoVoxelFinder::DaughterToMother(Int_t id, const Double_t *local, Double_t *master) const { // convert a point from the local reference system of node id to reference // system of mother volume @@ -311,7 +311,7 @@ void TGeoVoxelFinder::DaughterToMother(Int_t id, Double_t *local, Double_t *mast else mat->LocalToMaster(local, master); } //_____________________________________________________________________________ -Bool_t TGeoVoxelFinder::IsSafeVoxel(Double_t *point, Int_t inode, Double_t minsafe) const +Bool_t TGeoVoxelFinder::IsSafeVoxel(const Double_t *point, Int_t inode, Double_t minsafe) const { // Computes squared distance from POINT to the voxel(s) containing node INODE. Returns 0 // if POINT inside voxel(s). @@ -430,7 +430,7 @@ void TGeoVoxelFinder::FindOverlaps(Int_t inode) const } //_____________________________________________________________________________ -Bool_t TGeoVoxelFinder::GetIndices(Double_t *point, TGeoStateInfo &td) +Bool_t TGeoVoxelFinder::GetIndices(const Double_t *point, TGeoStateInfo &td) { // Getindices for current slices on x, y, z td.fVoxSlices[0] = -2; // -2 means 'all daughters in slice' @@ -587,7 +587,7 @@ Int_t *TGeoVoxelFinder::GetValidExtra(Int_t /*n1*/, UChar_t *array1, Int_t /*n2* } //_____________________________________________________________________________ -Int_t *TGeoVoxelFinder::GetNextCandidates(Double_t *point, Int_t &ncheck, TGeoStateInfo &td) +Int_t *TGeoVoxelFinder::GetNextCandidates(const Double_t *point, Int_t &ncheck, TGeoStateInfo &td) { // Returns list of new candidates in next voxel. If NULL, nowhere to // go next. @@ -1148,7 +1148,7 @@ Int_t *TGeoVoxelFinder::GetNextCandidates(Double_t *point, Int_t &ncheck, TGeoSt } //_____________________________________________________________________________ -void TGeoVoxelFinder::SortCrossedVoxels(Double_t *point, Double_t *dir, TGeoStateInfo &td) +void TGeoVoxelFinder::SortCrossedVoxels(const Double_t *point, const Double_t *dir, TGeoStateInfo &td) { // get the list in the next voxel crossed by a ray if (NeedRebuild()) { @@ -1281,7 +1281,7 @@ void TGeoVoxelFinder::SortCrossedVoxels(Double_t *point, Double_t *dir, TGeoStat } //_____________________________________________________________________________ -Int_t *TGeoVoxelFinder::GetCheckList(Double_t *point, Int_t &nelem, TGeoStateInfo &td) +Int_t *TGeoVoxelFinder::GetCheckList(const Double_t *point, Int_t &nelem, TGeoStateInfo &td) { // get the list of daughter indices for which point is inside their bbox if (NeedRebuild()) { @@ -1439,7 +1439,7 @@ Int_t *TGeoVoxelFinder::GetVoxelCandidates(Int_t i, Int_t j, Int_t k, Int_t &nch } //_____________________________________________________________________________ -Int_t *TGeoVoxelFinder::GetNextVoxel(Double_t *point, Double_t * /*dir*/, Int_t &ncheck, TGeoStateInfo &td) +Int_t *TGeoVoxelFinder::GetNextVoxel(const Double_t *point, const Double_t * /*dir*/, Int_t &ncheck, TGeoStateInfo &td) { // get the list of new candidates for the next voxel crossed by current ray // printf("### GetNextVoxel\n"); @@ -2246,7 +2246,7 @@ void TGeoVoxelFinder::Print(Option_t *) const } //_____________________________________________________________________________ -void TGeoVoxelFinder::PrintVoxelLimits(Double_t *point) const +void TGeoVoxelFinder::PrintVoxelLimits(const Double_t *point) const { // print the voxel containing point if (NeedRebuild()) { diff --git a/geom/geom/src/TGeoXtru.cxx b/geom/geom/src/TGeoXtru.cxx index 1660476bc71b3..a9b7eb714500f 100644 --- a/geom/geom/src/TGeoXtru.cxx +++ b/geom/geom/src/TGeoXtru.cxx @@ -172,24 +172,37 @@ void TGeoXtru::SetSeg(Int_t iseg) //_____________________________________________________________________________ TGeoXtru::TGeoXtru() + :TGeoBBox(), + fNvert(0), + fNz(0), + fZcurrent(0.), + fX(0), + fY(0), + fZ(0), + fScale(0), + fX0(0), + fY0(0), + fThreadData(0), + fThreadSize(0) { // dummy ctor SetShapeBit(TGeoShape::kGeoXtru); - fNvert = 0; - fNz = 0; - fZcurrent = 0.; - fX = 0; - fY = 0; - fZ = 0; - fScale = 0; - fX0 = 0; - fY0 = 0; - fThreadSize = 0; } //_____________________________________________________________________________ TGeoXtru::TGeoXtru(Int_t nz) - :TGeoBBox(0, 0, 0) + :TGeoBBox(0, 0, 0), + fNvert(0), + fNz(nz), + fZcurrent(0.), + fX(0), + fY(0), + fZ(new Double_t[nz]), + fScale(new Double_t[nz]), + fX0(new Double_t[nz]), + fY0(new Double_t[nz]), + fThreadData(0), + fThreadSize(0) { // Default constructor SetShapeBit(TGeoShape::kGeoXtru); @@ -198,21 +211,22 @@ TGeoXtru::TGeoXtru(Int_t nz) SetShapeBit(TGeoShape::kGeoBad); return; } - fNvert = 0; - fNz = nz; - fZcurrent = 0.; - fX = 0; - fY = 0; - fZ = new Double_t[nz]; - fScale = new Double_t[nz]; - fX0 = new Double_t[nz]; - fY0 = new Double_t[nz]; - fThreadSize = 0; } //_____________________________________________________________________________ TGeoXtru::TGeoXtru(Double_t *param) - :TGeoBBox(0, 0, 0) + :TGeoBBox(0, 0, 0), + fNvert(0), + fNz(0), + fZcurrent(0.), + fX(0), + fY(0), + fZ(0), + fScale(0), + fX0(0), + fY0(0), + fThreadData(0), + fThreadSize(0) { // Default constructor in GEANT3 style // param[0] = nz // number of z planes @@ -227,31 +241,22 @@ TGeoXtru::TGeoXtru(Double_t *param) // param[4*(nz-1)+3] = yn // param[4*(nz-1)+4] = scalen SetShapeBit(TGeoShape::kGeoXtru); - fNvert = 0; - fNz = 0; - fZcurrent = 0.; - fX = 0; - fY = 0; - fZ = 0; - fScale = 0; - fX0 = 0; - fY0 = 0; - fThreadSize = 0; SetDimensions(param); } //_____________________________________________________________________________ TGeoXtru::TGeoXtru(const TGeoXtru& xt) : TGeoBBox(xt), - fNvert(xt.fNvert), - fNz(xt.fNz), - fZcurrent(xt.fZcurrent), - fX(xt.fX), - fY(xt.fY), - fZ(xt.fZ), - fScale(xt.fScale), - fX0(xt.fX0), - fY0(xt.fY0), + fNvert(0), + fNz(0), + fZcurrent(0), + fX(0), + fY(0), + fZ(0), + fScale(0), + fX0(0), + fY0(0), + fThreadData(0), fThreadSize(0) { //copy constructor @@ -263,16 +268,16 @@ TGeoXtru& TGeoXtru::operator=(const TGeoXtru& xt) //assignment operator if(this!=&xt) { TGeoBBox::operator=(xt); - fNvert=xt.fNvert; - fNz=xt.fNz; - fZcurrent=xt.fZcurrent; - fX=xt.fX; - fY=xt.fY; - fZ=xt.fZ; - fScale=xt.fScale; - fX0=xt.fX0; - fY0=xt.fY0; - ClearThreadData(); + fNvert=0; + fNz=0; + fZcurrent=0; + fX=0; + fY=0; + fZ=0; + fScale=0; + fX0=0; + fY0=0; + fThreadSize=0; } return *this; } @@ -345,7 +350,7 @@ void TGeoXtru::ComputeBBox() } //_____________________________________________________________________________ -void TGeoXtru::ComputeNormal(Double_t * /*point*/, Double_t *dir, Double_t *norm) +void TGeoXtru::ComputeNormal(const Double_t * /*point*/, const Double_t *dir, Double_t *norm) { // Compute normal to closest surface from POINT. ThreadData_t& td = GetThreadData(); @@ -366,7 +371,7 @@ void TGeoXtru::ComputeNormal(Double_t * /*point*/, Double_t *dir, Double_t *norm } //_____________________________________________________________________________ -Bool_t TGeoXtru::Contains(Double_t *point) const +Bool_t TGeoXtru::Contains(const Double_t *point) const { // test if point is inside this shape ThreadData_t& td = GetThreadData(); @@ -402,8 +407,17 @@ Int_t TGeoXtru::DistancetoPrimitive(Int_t px, Int_t py) const Int_t numPoints = fNvert*fNz; return ShapeDistancetoPrimitive(numPoints, px, py); } + //_____________________________________________________________________________ -Double_t TGeoXtru::DistToPlane(Double_t *point, Double_t *dir, Int_t iz, Int_t ivert, Double_t stepmax, Bool_t in) const +void TGeoXtru::DrawPolygon(Option_t *option) +{ +// Draw the section polygon. + ThreadData_t& td = GetThreadData(); + if (td.fPoly) td.fPoly->Draw(option); +} + +//_____________________________________________________________________________ +Double_t TGeoXtru::DistToPlane(const Double_t *point, const Double_t *dir, Int_t iz, Int_t ivert, Double_t stepmax, Bool_t in) const { // Compute distance to a Xtru lateral surface. ThreadData_t& td = GetThreadData(); @@ -433,14 +447,14 @@ Double_t TGeoXtru::DistToPlane(Double_t *point, Double_t *dir, Int_t iz, Int_t i safe = (vert[0]-point[0])*norm[0]+ (vert[1]-point[1])*norm[1]+ (vert[2]-point[2])*norm[2]; - if (safe<0) return TGeoShape::Big(); // direction outwards plane + if (safe<-1.E-8) return TGeoShape::Big(); // direction outwards plane } else { ndotd = -ndotd; if (ndotd<=0) return TGeoShape::Big(); safe = (point[0]-vert[0])*norm[0]+ (point[1]-vert[1])*norm[1]+ (point[2]-vert[2])*norm[2]; - if (safe<0) return TGeoShape::Big(); // direction outwards plane + if (safe<-1.E-8) return TGeoShape::Big(); // direction outwards plane } snext = safe/ndotd; if (snext>stepmax) return TGeoShape::Big(); @@ -453,11 +467,11 @@ Double_t TGeoXtru::DistToPlane(Double_t *point, Double_t *dir, Int_t iz, Int_t i pt[1] = point[1]+snext*dir[1]; pt[2] = point[2]+snext*dir[2]; if (!IsPointInsidePlane(pt, vert, norm)) return TGeoShape::Big(); - return snext; + return TMath::Max(snext, 0.); } //_____________________________________________________________________________ -Double_t TGeoXtru::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoXtru::DistFromInside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from inside point to surface of the polycone // locate Z segment @@ -508,6 +522,7 @@ Double_t TGeoXtru::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Do if (convex) return snext; } } + if (snext < 1.E10) return snext; return TGeoShape::Tolerance(); } @@ -552,10 +567,10 @@ Double_t TGeoXtru::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Do iznext = fNz-1; // stop } // ray may cross the lateral surfaces of section iz - xtru->SetIz(iz); for (iv=0; ivSetIz(iz); xtru->SetSeg(iv); snext = dist; if (convex) return snext; @@ -569,7 +584,7 @@ Double_t TGeoXtru::DistFromInside(Double_t *point, Double_t *dir, Int_t iact, Do } //_____________________________________________________________________________ -Double_t TGeoXtru::DistFromOutside(Double_t *point, Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const +Double_t TGeoXtru::DistFromOutside(const Double_t *point, const Double_t *dir, Int_t iact, Double_t step, Double_t *safe) const { // compute distance from outside point to surface of the tube // Warning("DistFromOutside", "not implemented"); @@ -825,7 +840,7 @@ void TGeoXtru::GetPlaneVertices(Int_t iz, Int_t ivert, Double_t *vert) const } } //_____________________________________________________________________________ -Bool_t TGeoXtru::IsPointInsidePlane(Double_t *point, Double_t *vert, Double_t *norm) const +Bool_t TGeoXtru::IsPointInsidePlane(const Double_t *point, Double_t *vert, Double_t *norm) const { // Check if the quadrilateral defined by VERT contains a coplanar POINT. Double_t v1[3], v2[3]; @@ -951,7 +966,7 @@ void TGeoXtru::SetSegsAndPols(TBuffer3D &buff) const } //_____________________________________________________________________________ -Double_t TGeoXtru::SafetyToSector(Double_t *point, Int_t iz, Double_t safmin, Bool_t in) +Double_t TGeoXtru::SafetyToSector(const Double_t *point, Int_t iz, Double_t safmin, Bool_t in) { // Compute safety to sector iz, returning also the closest segment index. ThreadData_t& td = GetThreadData(); @@ -1004,7 +1019,7 @@ Double_t TGeoXtru::SafetyToSector(Double_t *point, Int_t iz, Double_t safmin, Bo saf1 = (point[0]-vert[0])*norm[0]+(point[1]-vert[1])*norm[1]+(point[2]-vert[2])*norm[2]; if (in) saf1 = -saf1; // printf("segment %d: (%f,%f)-(%f,%f) norm=(%f,%f,%f): saf1=%f\n", iseg, vert[0],vert[1],vert[3],vert[4],norm[0],norm[1],norm[2],saf1); - if (saf1<0) continue; + if (saf1<-1.E-8) continue; safe = TMath::Max(safz, saf1); safe = TMath::Abs(safe); if (safe>safmin) continue; @@ -1016,7 +1031,7 @@ Double_t TGeoXtru::SafetyToSector(Double_t *point, Int_t iz, Double_t safmin, Bo } //_____________________________________________________________________________ -Double_t TGeoXtru::Safety(Double_t *point, Bool_t in) const +Double_t TGeoXtru::Safety(const Double_t *point, Bool_t in) const { // computes the closest distance from given point to this shape, according // to option. The matching point on the shape is stored in spoint. @@ -1062,28 +1077,28 @@ Double_t TGeoXtru::Safety(Double_t *point, Bool_t in) const } //_____________________________________________________________________________ -void TGeoXtru::SavePrimitive(ostream &out, Option_t * /*option*/ /*= ""*/) +void TGeoXtru::SavePrimitive(std::ostream &out, Option_t * /*option*/ /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". if (TObject::TestBit(kGeoSavePrimitive)) return; - out << " // Shape: " << GetName() << " type: " << ClassName() << endl; - out << " nz = " << fNz << ";" << endl; - out << " nvert = " << fNvert << ";" << endl; - out << " TGeoXtru *xtru = new TGeoXtru(nz);" << endl; - out << " xtru->SetName(\"" << GetName() << "\");" << endl; + out << " // Shape: " << GetName() << " type: " << ClassName() << std::endl; + out << " nz = " << fNz << ";" << std::endl; + out << " nvert = " << fNvert << ";" << std::endl; + out << " TGeoXtru *xtru = new TGeoXtru(nz);" << std::endl; + out << " xtru->SetName(\"" << GetName() << "\");" << std::endl; Int_t i; for (i=0; iDefinePolygon(nvert,xvert,yvert);" << endl; + out << " xtru->DefinePolygon(nvert,xvert,yvert);" << std::endl; for (i=0; iDefineSection(" << i << ",zsect,x0,y0,scale0);" << endl; + out << " zsect = " << fZ[i] << ";" << std::endl; + out << " x0 = " << fX0[i] << ";" << std::endl; + out << " y0 = " << fY0[i] << ";" << std::endl; + out << " scale0 = " << fScale[i] << ";" << std::endl; + out << " xtru->DefineSection(" << i << ",zsect,x0,y0,scale0);" << std::endl; } - out << " TGeoShape *" << GetPointerName() << " = xtru;" << endl; + out << " TGeoShape *" << GetPointerName() << " = xtru;" << std::endl; TObject::SetBit(TGeoShape::kGeoSavePrimitive); } @@ -1271,3 +1286,44 @@ const TBuffer3D & TGeoXtru::GetBuffer3D(Int_t reqSections, Bool_t localFrame) co return buffer; } + +//_____________________________________________________________________________ +void TGeoXtru::Contains_v(const Double_t *points, Bool_t *inside, Int_t vecsize) const +{ +// Check the inside status for each of the points in the array. +// Input: Array of point coordinates + vector size +// Output: Array of Booleans for the inside of each point + for (Int_t i=0; iGetId(); +} + //______________________________________________________________________________ TVirtualGeoTrack *TVirtualGeoTrack::FindTrackWithId(Int_t id) const { diff --git a/geom/geombuilder/src/TGeoVolumeEditor.cxx b/geom/geombuilder/src/TGeoVolumeEditor.cxx index f9713699fd3b1..0a86cc3801aed 100644 --- a/geom/geombuilder/src/TGeoVolumeEditor.cxx +++ b/geom/geombuilder/src/TGeoVolumeEditor.cxx @@ -16,7 +16,7 @@ ////////////////////////////////////////////////////////////////////////// /* Editor for geometry volumes and assemblies of volumes. Besides the volume name and line attributes, a TGeoVolume has the following editable categories - splitted vertically by a shutter: + split vertically by a shutter: - Properties: one can edit the shape and medium components from here. It is also possible to change the existing ones. - Daughters: the main category allowing defining, editing, removing or diff --git a/geom/geompainter/inc/TGeoChecker.h b/geom/geompainter/inc/TGeoChecker.h index 5a2e5acaf30f3..a293ac946560e 100644 --- a/geom/geompainter/inc/TGeoChecker.h +++ b/geom/geompainter/inc/TGeoChecker.h @@ -79,7 +79,7 @@ private : Double_t rmin=0., Double_t rmax=9999999, Option_t *option=""); void PrintOverlaps() const; void RandomPoints(TGeoVolume *vol, Int_t npoints, Option_t *option); - void RandomRays(Int_t nrays, Double_t startx, Double_t starty, Double_t startz); + void RandomRays(Int_t nrays, Double_t startx, Double_t starty, Double_t startz, const char *target_vol=0, Bool_t check_norm=kFALSE); TGeoOverlap *MakeCheckOverlap(const char *name, TGeoVolume *vol1, TGeoVolume *vol2, TGeoMatrix *mat1, TGeoMatrix *mat2, Bool_t isovlp, Double_t ovlp); void OpProgress(const char *opname, Long64_t current, Long64_t size, TStopwatch *watch=0, Bool_t last=kFALSE, Bool_t refresh=kFALSE); TGeoNode *SamplePoints(Int_t npoints, Double_t &dist, Double_t epsil, const char* g3path); diff --git a/geom/geompainter/inc/TGeoPainter.h b/geom/geompainter/inc/TGeoPainter.h index fc14161d72f74..e7bc4c0beebf8 100644 --- a/geom/geompainter/inc/TGeoPainter.h +++ b/geom/geompainter/inc/TGeoPainter.h @@ -39,6 +39,7 @@ class TGeoChecker; class TGeoOverlap; class TH2F; class TGeoBatemanSol; +class TGeoPolygon; class TGeoPainter : public TVirtualGeoPainter { private: @@ -107,6 +108,7 @@ class TGeoPainter : public TVirtualGeoPainter { virtual void DrawOnly(Option_t *option=""); virtual void DrawPanel(); virtual void DrawPath(const char *path); + virtual void DrawPolygon(const TGeoPolygon *poly); virtual void DrawShape(TGeoShape *shape, Option_t *option=""); virtual void DrawVolume(TGeoVolume *vol, Option_t *option=""); virtual void EditGeometry(Option_t *option=""); @@ -148,7 +150,7 @@ class TGeoPainter : public TVirtualGeoPainter { virtual void PrintOverlaps() const; void PaintPhysicalNode(TGeoPhysicalNode *node, Option_t *option=""); virtual void RandomPoints(const TGeoVolume *vol, Int_t npoints, Option_t *option=""); - virtual void RandomRays(Int_t nrays, Double_t startx, Double_t starty, Double_t startz); + virtual void RandomRays(Int_t nrays, Double_t startx, Double_t starty, Double_t startz, const char *target_vol=0, Bool_t check_norm=kFALSE); virtual void Raytrace(Option_t *option=""); virtual TGeoNode *SamplePoints(Int_t npoints, Double_t &dist, Double_t epsil, const char* g3path); virtual void SetBombFactors(Double_t bombx=1.3, Double_t bomby=1.3, Double_t bombz=1.3, Double_t bombr=1.3); diff --git a/geom/geompainter/src/TGeoChecker.cxx b/geom/geompainter/src/TGeoChecker.cxx index 3764e71751530..fa6c65d4a47fd 100644 --- a/geom/geompainter/src/TGeoChecker.cxx +++ b/geom/geompainter/src/TGeoChecker.cxx @@ -1864,12 +1864,12 @@ void TGeoChecker::ShapeNormal(TGeoShape *shape, Int_t nsamples, Option_t *) // Number of tracks shot for every point inside the shape const Int_t kNtracks = 1000; Int_t n10 = nsamples/10; - Int_t itot = 0; + Int_t itot = 0, errcnt = 0, errsame=0; Int_t i; - Double_t dist, safe; - Double_t point[3]; - Double_t dir[3]; - Double_t norm[3]; + Double_t dist, olddist, safe, dot; + Double_t point[3],newpoint[3], oldpoint[3]; + Double_t dir[3], olddir[3]; + Double_t norm[3], newnorm[3], oldnorm[3]; Double_t theta, phi, ndotd; TCanvas *errcanvas = 0; TPolyMarker3D *pm1 = 0; @@ -1884,25 +1884,37 @@ void TGeoChecker::ShapeNormal(TGeoShape *shape, Int_t nsamples, Option_t *) while (itotUniform(-dx,dx); - point[1] = gRandom->Uniform(-dy,dy); - point[2] = gRandom->Uniform(-dz,dz); + oldpoint[0] = point[0] = gRandom->Uniform(-dx,dx); + oldpoint[1] = point[1] = gRandom->Uniform(-dy,dy); + oldpoint[2] = point[2] = gRandom->Uniform(-dz,dz); inside = shape->Contains(point); } phi = 2*TMath::Pi()*gRandom->Rndm(); theta= TMath::ACos(1.-2.*gRandom->Rndm()); - dir[0]=TMath::Sin(theta)*TMath::Cos(phi); - dir[1]=TMath::Sin(theta)*TMath::Sin(phi); - dir[2]=TMath::Cos(theta); + olddir[0]=dir[0]=TMath::Sin(theta)*TMath::Cos(phi); + olddir[1]=dir[1]=TMath::Sin(theta)*TMath::Sin(phi); + olddir[2]=dir[2]=TMath::Cos(theta); + oldnorm[0] = oldnorm[1] = oldnorm[2] = 0.; + olddist = 0.; itot++; if (n10) { if ((itot%n10) == 0) printf("%i percent\n", Int_t(100*itot/nsamples)); } for (i=0; i0) break; dist = shape->DistFromInside(point,dir,3); - if (distdmax) { - printf("Error DistFromInside(%19.15f, %19.15f, %19.15f, %19.15f, %19.15f, %19.15f) =%g\n", - point[0],point[1],point[2], dir[0], dir[1], dir[2], dist); + for (Int_t j=0; j<3; j++) { + newpoint[j] = point[j] + dist*dir[j]; + } + shape->ComputeNormal(newpoint,dir,newnorm); + + dot = olddir[0]*oldnorm[0]+olddir[1]*oldnorm[1]+ olddir[2]*oldnorm[2]; + if (!shape->Contains(point) && shape->Safety(point,kFALSE)>1.E-3) { + errcnt++; + printf("Error point outside (%19.15f, %19.15f, %19.15f, %19.15f, %19.15f, %19.15f) =%g olddist=%g\n", + point[0],point[1],point[2], dir[0], dir[1], dir[2], dist, olddist); + printf(" old point: (%19.15f, %19.15f, %19.15f, %19.15f, %19.15f, %19.15f)\n", + oldpoint[0],oldpoint[1],oldpoint[2], olddir[0], olddir[1], olddir[2]); if (!errcanvas) errcanvas = new TCanvas("shape_err03", Form("Shape %s (%s)",shape->GetName(),shape->ClassName()), 1000, 800); if (!pm1) { pm1 = new TPolyMarker3D(); @@ -1911,12 +1923,40 @@ void TGeoChecker::ShapeNormal(TGeoShape *shape, Int_t nsamples, Option_t *) pm1->SetMarkerColor(kRed); } pm1->SetNextPoint(point[0],point[1],point[2]); + pm1->SetNextPoint(oldpoint[0],oldpoint[1],oldpoint[2]); break; } + if ((dist1.E-3) || dist>dmax) { + errsame++; + if (errsame>1) { + errcnt++; + printf("Error DistFromInside(%19.15f, %19.15f, %19.15f, %19.15f, %19.15f, %19.15f) =%g olddist=%g\n", + point[0],point[1],point[2], dir[0], dir[1], dir[2], dist, olddist); + printf(" new norm: (%g, %g, %g)\n", newnorm[0], newnorm[1], newnorm[2]); + printf(" old point: (%19.15f, %19.15f, %19.15f, %19.15f, %19.15f, %19.15f)\n", + oldpoint[0],oldpoint[1],oldpoint[2], olddir[0], olddir[1], olddir[2]); + printf(" old norm: (%g, %g, %g)\n", oldnorm[0], oldnorm[1], oldnorm[2]); + if (!errcanvas) errcanvas = new TCanvas("shape_err03", Form("Shape %s (%s)",shape->GetName(),shape->ClassName()), 1000, 800); + if (!pm1) { + pm1 = new TPolyMarker3D(); + pm1->SetMarkerStyle(24); + pm1->SetMarkerSize(0.4); + pm1->SetMarkerColor(kRed); + } + pm1->SetNextPoint(point[0],point[1],point[2]); + pm1->SetNextPoint(oldpoint[0],oldpoint[1],oldpoint[2]); + break; + } + } else errsame = 0; + olddist = dist; - for (Int_t j=0; j<3; j++) point[j] += dist*dir[j]; + for (Int_t j=0; j<3; j++) { + oldpoint[j] = point[j]; + point[j] += dist*dir[j]; + } safe = shape->Safety(point, kTRUE); - if (safe>1.E-6) { + if (safe>1.E-3) { + errcnt++; printf("Error safety (%19.15f, %19.15f, %19.15f) safe=%g\n", point[0],point[1],point[2], safe); if (!errcanvas) errcanvas = new TCanvas("shape_err03", Form("Shape %s (%s)",shape->GetName(),shape->ClassName()), 1000, 800); @@ -1931,6 +1971,28 @@ void TGeoChecker::ShapeNormal(TGeoShape *shape, Int_t nsamples, Option_t *) } // Compute normal shape->ComputeNormal(point,dir,norm); + if (TGeoShape::IsSameWithinTolerance(norm[0],oldnorm[0]) && + TGeoShape::IsSameWithinTolerance(norm[1],oldnorm[1]) && + TGeoShape::IsSameWithinTolerance(norm[2],oldnorm[2])) { + errcnt++; + printf("Error: same normal for: (%19.15f, %19.15f, %19.15f, %19.15f, %19.15f, %19.15f) = (%g,%g,%g)\n", + point[0],point[1],point[2], dir[0], dir[1], dir[2], norm[0], norm[1], norm[2]); + printf(" as for: (%19.15f, %19.15f, %19.15f, %19.15f, %19.15f, %19.15f)\n", + oldpoint[0],oldpoint[1],oldpoint[2], olddir[0], olddir[1], olddir[2]); + if (!errcanvas) errcanvas = new TCanvas("shape_err03", Form("Shape %s (%s)",shape->GetName(),shape->ClassName()), 1000, 800); + if (!pm1) { + pm1 = new TPolyMarker3D(); + pm1->SetMarkerStyle(24); + pm1->SetMarkerSize(0.4); + pm1->SetMarkerColor(kRed); + } + pm1->SetNextPoint(point[0],point[1],point[2]); + pm1->SetNextPoint(oldpoint[0],oldpoint[1],oldpoint[2]); + memcpy(oldnorm, norm, 3*sizeof(Double_t)); + break; + } + memcpy(oldnorm, norm, 3*sizeof(Double_t)); + memcpy(olddir, dir, 3*sizeof(Double_t)); while (1) { phi = 2*TMath::Pi()*gRandom->Rndm(); theta= TMath::ACos(1.-2.*gRandom->Rndm()); @@ -2100,16 +2162,22 @@ void TGeoChecker::RandomPoints(TGeoVolume *vol, Int_t npoints, Option_t *option) } //______________________________________________________________________________ -void TGeoChecker::RandomRays(Int_t nrays, Double_t startx, Double_t starty, Double_t startz) +void TGeoChecker::RandomRays(Int_t nrays, Double_t startx, Double_t starty, Double_t startz, const char *target_vol, Bool_t check_norm) { // Randomly shoot nrays from point (startx,starty,startz) and plot intersections // with surfaces for current top node. TObjArray *pm = new TObjArray(128); + TString starget = target_vol; TPolyLine3D *line = 0; TPolyLine3D *normline = 0; TGeoVolume *vol=fGeoManager->GetTopVolume(); // vol->VisibleDaughters(kTRUE); - + + Bool_t random = kFALSE; + if (nrays<=0) { + nrays = 100000; + random = kTRUE; + } Double_t start[3]; Double_t dir[3]; const Double_t *point = fGeoManager->GetCurrentPoint(); @@ -2122,7 +2190,11 @@ void TGeoChecker::RandomRays(Int_t nrays, Double_t startx, Double_t starty, Doub Int_t itot=0; Int_t n10=nrays/10; Double_t theta,phi, step, normlen; - const Double_t *normal; + Double_t lnorm[3] = {0.,0.,0.}; + const Double_t *normal = lnorm; + Double_t ox = ((TGeoBBox*)vol->GetShape())->GetOrigin()[0]; + Double_t oy = ((TGeoBBox*)vol->GetShape())->GetOrigin()[1]; + Double_t oz = ((TGeoBBox*)vol->GetShape())->GetOrigin()[2]; Double_t dx = ((TGeoBBox*)vol->GetShape())->GetDX(); Double_t dy = ((TGeoBBox*)vol->GetShape())->GetDY(); Double_t dz = ((TGeoBBox*)vol->GetShape())->GetDZ(); @@ -2136,9 +2208,15 @@ void TGeoChecker::RandomRays(Int_t nrays, Double_t startx, Double_t starty, Doub if (n10) { if ((itot%n10) == 0) printf("%i percent\n", Int_t(100*itot/nrays)); } - start[0] = startx; - start[1] = starty; - start[2] = startz; + if (random) { + start[0] = ox-dx+2*dx*gRandom->Rndm(); + start[1] = oy-dy+2*dy*gRandom->Rndm(); + start[2] = oz-dz+2*dz*gRandom->Rndm(); + } else { + start[0] = startx; + start[1] = starty; + start[2] = startz; + } phi = 2*TMath::Pi()*gRandom->Rndm(); theta= TMath::ACos(1.-2.*gRandom->Rndm()); dir[0]=TMath::Sin(theta)*TMath::Cos(phi); @@ -2147,11 +2225,16 @@ void TGeoChecker::RandomRays(Int_t nrays, Double_t startx, Double_t starty, Doub startnode = fGeoManager->InitTrack(start[0],start[1],start[2], dir[0],dir[1],dir[2]); line = 0; if (fGeoManager->IsOutside()) startnode=0; - vis1 = (startnode)?(startnode->IsOnScreen()):kFALSE; + vis1 = kFALSE; + if (target_vol) { + if (startnode && starget==startnode->GetVolume()->GetName()) vis1 = kTRUE; + } else { + if (startnode && startnode->IsOnScreen()) vis1 = kTRUE; + } if (vis1) { line = new TPolyLine3D(2); line->SetLineColor(startnode->GetVolume()->GetLineColor()); - line->SetPoint(ipoint++, startx, starty, startz); + line->SetPoint(ipoint++, start[0], start[1], start[2]); i++; pm->Add(line); } @@ -2160,13 +2243,18 @@ void TGeoChecker::RandomRays(Int_t nrays, Double_t startx, Double_t starty, Doub if (step5) break; - normal = fGeoManager->FindNormalFast(); - if (!normal) break; - vis2 = endnode->IsOnScreen(); + if (check_norm) { + normal = fGeoManager->FindNormalFast(); + if (!normal) break; + } + vis2 = kFALSE; + if (target_vol) { + if (starget==endnode->GetVolume()->GetName()) vis2 = kTRUE; + } else if (endnode->IsOnScreen()) vis2 = kTRUE; if (ipoint>0) { // old visible node had an entry point -> finish segment line->SetPoint(ipoint, point[0], point[1], point[2]); - if (!vis2) { + if (!vis2 && check_norm) { normline = new TPolyLine3D(2); normline->SetLineColor(kBlue); normline->SetLineWidth(1); @@ -2185,15 +2273,17 @@ void TGeoChecker::RandomRays(Int_t nrays, Double_t startx, Double_t starty, Doub line->SetLineColor(endnode->GetVolume()->GetLineColor()); line->SetPoint(ipoint++, point[0], point[1], point[2]); i++; - normline = new TPolyLine3D(2); - normline->SetLineColor(kBlue); - normline->SetLineWidth(2); - normline->SetPoint(0, point[0], point[1], point[2]); - normline->SetPoint(1, point[0]+normal[0]*normlen, - point[1]+normal[1]*normlen, - point[2]+normal[2]*normlen); + if (check_norm) { + normline = new TPolyLine3D(2); + normline->SetLineColor(kBlue); + normline->SetLineWidth(2); + normline->SetPoint(0, point[0], point[1], point[2]); + normline->SetPoint(1, point[0]+normal[0]*normlen, + point[1]+normal[1]*normlen, + point[2]+normal[2]*normlen); + } pm->Add(line); - pm->Add(normline); + if (!random) pm->Add(normline); } } } diff --git a/geom/geompainter/src/TGeoPainter.cxx b/geom/geompainter/src/TGeoPainter.cxx index 82075bb413991..a2cf9fc04ca50 100644 --- a/geom/geompainter/src/TGeoPainter.cxx +++ b/geom/geompainter/src/TGeoPainter.cxx @@ -24,6 +24,7 @@ #include "TCanvas.h" #include "TH2F.h" #include "TF1.h" +#include "TGraph.h" #include "TPluginManager.h" #include "TVirtualPadEditor.h" #include "TStopwatch.h" @@ -39,6 +40,7 @@ #include "TGeoOverlap.h" #include "TGeoChecker.h" #include "TGeoPhysicalNode.h" +#include "TGeoPolygon.h" #include "TGeoCompositeShape.h" #include "TGeoShapeAssembly.h" #include "TGeoPainter.h" @@ -139,6 +141,7 @@ void TGeoPainter::AddTrackPoint(Double_t *point, Double_t *box, Bool_t reset) for (i=0; i<3; i++) xmin[i]=xmax[i]=0; npoints++; } + npoints++; Double_t ninv = 1./Double_t(npoints); for (i=0; i<3; i++) { @@ -694,6 +697,54 @@ void TGeoPainter::DrawBatemanSol(TGeoBatemanSol *sol, Option_t *option) func->Draw(option); } +//______________________________________________________________________________ +void TGeoPainter::DrawPolygon(const TGeoPolygon *poly) +{ +// Draw a polygon in 3D. + Int_t nvert = poly->GetNvert(); + if (!nvert) { + Error("DrawPolygon", "No vertices defined"); + return; + } + Int_t nconv = poly->GetNconvex(); + Double_t *x = new Double_t[nvert+1]; + Double_t *y = new Double_t[nvert+1]; + poly->GetVertices(x,y); + x[nvert] = x[0]; + y[nvert] = y[0]; + TGraph *g1 = new TGraph(nvert+1, x,y); + g1->SetTitle(Form("Polygon with %d vertices (outscribed %d)",nvert, nconv)); + g1->SetLineColor(kRed); + g1->SetMarkerColor(kRed); + g1->SetMarkerStyle(4); + g1->SetMarkerSize(0.8); + delete [] x; + delete [] y; + Double_t *xc = 0; + Double_t *yc = 0; + TGraph *g2 = 0; + if (nconv && !poly->IsConvex()) { + xc = new Double_t[nconv+1]; + yc = new Double_t[nconv+1]; + poly->GetConvexVertices(xc,yc); + xc[nconv] = xc[0]; + yc[nconv] = yc[0]; + g2 = new TGraph(nconv+1, xc,yc); + g2->SetLineColor(kBlue); + g2->SetLineColor(kBlue); + g2->SetMarkerColor(kBlue); + g2->SetMarkerStyle(21); + g2->SetMarkerSize(0.4); + delete [] xc; + delete [] yc; + } + if (!gPad) { + gROOT->MakeDefCanvas(); + } + g1->Draw("ALP"); + if (g2) g2->Draw("LP"); +} + //______________________________________________________________________________ void TGeoPainter::DrawVolume(TGeoVolume *vol, Option_t *option) { @@ -1485,10 +1536,10 @@ void TGeoPainter::RandomPoints(const TGeoVolume *vol, Int_t npoints, Option_t *o } //______________________________________________________________________________ -void TGeoPainter::RandomRays(Int_t nrays, Double_t startx, Double_t starty, Double_t startz) +void TGeoPainter::RandomRays(Int_t nrays, Double_t startx, Double_t starty, Double_t startz, const char *target_vol, Bool_t check_norm) { // Shoot nrays in the current drawn geometry - fChecker->RandomRays(nrays, startx, starty, startz); + fChecker->RandomRays(nrays, startx, starty, startz, target_vol, check_norm); } //______________________________________________________________________________ diff --git a/graf2d/CMakeLists.txt b/graf2d/CMakeLists.txt index 1074ec24153e4..bf195dbefa67a 100644 --- a/graf2d/CMakeLists.txt +++ b/graf2d/CMakeLists.txt @@ -7,9 +7,10 @@ endif() add_subdirectory(gpad) add_subdirectory(graf) add_subdirectory(postscript) +add_subdirectory(mathtext) if(WIN32) add_subdirectory(win32gdk) -else() +elseif(x11) add_subdirectory(x11) # special CMakeLists.txt add_subdirectory(x11ttf) # special CMakeLists.txt endif() diff --git a/graf2d/asimage/BuildAfterImage.cmake b/graf2d/asimage/BuildAfterImage.cmake index 00be9c02b1d2d..e2f1ae127971d 100644 --- a/graf2d/asimage/BuildAfterImage.cmake +++ b/graf2d/asimage/BuildAfterImage.cmake @@ -19,7 +19,7 @@ if(WIN32) set(astepbld "libAfterImage - Win32 Release") endif() -add_custom_command( OUTPUT ${afterimageliba} + add_custom_command( OUTPUT ${afterimageliba} COMMAND cmake -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/src/libAfterImage libAfterImage COMMAND echo "*** Building ${afterimageliba}" COMMAND cmake -E chdir libAfterImage @@ -37,50 +37,48 @@ else() if(ROOT_ARCHITECTURE MATCHES linuxx8664icc) set(AFTER_CFLAGS "${AFTER_CFLAGS} -m64 -O") elseif(ROOT_ARCHITECTURE MATCHES linuxx8664gcc) - set(AFTER_CFLAGS "-m64 -O") + set(AFTER_CC "${AFTER_CC} -m64") set(AFTER_MMX "--enable-mmx-optimization=no") elseif(ROOT_ARCHITECTURE MATCHES linuxicc) - set(AFTER_CFLAGS "${AFTER_CFLAGS} -m32 -O") + set(AFTER_CC "${AFTER_CC} -m32") + elseif(ROOT_ARCHITECTURE MATCHES linux8664icc) + set(AFTER_CC "${AFTER_CC} -m64") elseif(ROOT_ARCHITECTURE MATCHES linuxppc64gcc) - set(AFTER_CFLAGS "-m64 -O") + set(AFTER_CC "${AFTER_CC} -m64") elseif(ROOT_ARCHITECTURE MATCHES linux) - set(AFTER_CFLAGS "-m32 -O") + set(AFTER_CC "${AFTER_CC} -m32") elseif(ROOT_ARCHITECTURE MATCHES macosx64) - set(AFTER_CFLAGS "-m64 -O") + set(AFTER_CC "${AFTER_CC} -m64") elseif(ROOT_ARCHITECTURE MATCHES macosx) - set(AFTER_CFLAGS "-m32 -O") + set(AFTER_CC "${AFTER_CC} -m32") elseif(ROOT_ARCHITECTURE MATCHES solarisCC5) set(AFTER_CFLAGS "${AFTER_CFLAGS} --erroff=E_WHITE_SPACE_IN_DIRECTIVE") + set(AFTER_MMX "--disable-mmx-optimization") elseif(ROOT_ARCHITECTURE MATCHES solaris64CC5) - set(AFTER_CC "cc") - set(AFTER_CFLAGS "${AFTER_CFLAGS} -m64 -KPIC --erroff=E_WHITE_SPACE_IN_DIRECTIVE") + set(AFTER_CC "${AFTER_CC} -m64") + set(AFTER_CFLAGS "${AFTER_CFLAGS} -KPIC --erroff=E_WHITE_SPACE_IN_DIRECTIVE") + set(AFTER_MMX "--disable-mmx-optimization") elseif(ROOT_ARCHITECTURE MATCHES sgicc64) - set(AFTER_CC "gcc") - set(AFTER_CFLAGS "-mabi=64 -O") + set(AFTER_CC "${AFTER_CC} -mabi=64") elseif(ROOT_ARCHITECTURE MATCHES hpuxia64acc) - set(AFTER_CC "cc") - set(AFTER_CFLAGS "+DD64 -Ae +W863 -O") - set(AFTER_ALT "gcc -mlp64") + set(AFTER_CC "${AFTER_CC} +DD64 -Ae +W863") endif() if(JPEG_FOUND) - set(JPEGINCLUDE "--with-jpeg-includes=-I${JPEG_INCLUDE_DIR}") + set(JPEGINCLUDE "--with-jpeg-includes=${JPEG_INCLUDE_DIR}") endif() if(PNG_FOUND) - #foreach(_dir ${PNG_INCLUDE_DIR}) - # set(PNG_INC_DIR "${PNG_INC_DIR} -I${_dir}") - #endforeach() - #set(PNGINCLUDE "--with-png-includes=${PNG_INC_DIR}") - set(PNGINCLUDE "--with-png-includes=${PNG_PNG_INCLUDE_DIR}") + set(PNGINCLUDE "--with-png-includes=${PNG_PNG_INCLUDE_DIR}") + endif() + if(cocoa) + set(JPEGINCLUDE --without-x --with-builtin-jpeg) + set(PNGINCLUDE "--with-builtin-png") endif() if(TIFF_FOUND) - set(TIFFINCLUDE "--with-tiff-includes=-I${TIFF_INCLUDE_DIR}") + set(TIFFINCLUDE "--with-tiff-includes=${TIFF_INCLUDE_DIR}") else() set(TIFFINCLUDE "--with-tiff=no") endif() - if(GIF_FOUND) - set(GIFINCLUDE "--with-gif-includes=-I${GIF_INCLUDE_DIR}") - endif() set(TTFINCLUDE "--with-ttf-includes=-I${FREETYPE_INCLUDE_DIR}") #---copy files from source directory to build directory------------------------------ @@ -89,7 +87,7 @@ else() #---configure and make -------------------------------------------------------------- add_custom_command(OUTPUT ${afterimageliba} - COMMAND GNUMAKE=make CC=${AFTER_CC} CFLAGS=${AFTER_CFLAGS} ./configure --with-ttf ${TTFINCLUDE} --with-afterbase=no --without-svg --disable-glx ${AFTER_MMX} ${AFTER_DBG} --with-builtin-ungif ${GIFINCLUDE} --with-jpeg ${JPEGINCLUDE} --with-png ${PNGINCLUDE} ${TIFFINCLUDE} > /dev/null 2>& 1 + COMMAND GNUMAKE=make CC=${AFTER_CC} CFLAGS=${AFTER_CFLAGS} ./configure --with-ttf ${TTFINCLUDE} --with-afterbase=no --without-svg --disable-glx ${AFTER_MMX} ${AFTER_DBG} --with-builtin-ungif --with-jpeg ${JPEGINCLUDE} --with-png ${PNGINCLUDE} ${TIFFINCLUDE} # > /dev/null 2>& 1 COMMAND make > /dev/null 2>& 1 WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/libAfterImage DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/libAfterImage @@ -115,4 +113,8 @@ endif() add_custom_target(AFTERIMAGE DEPENDS ${afterimagelib} ) set_target_properties(AFTERIMAGE PROPERTIES FOLDER Builtins) -install(FILES ${afterimagelib} DESTINATION lib) +if(builtin_freetype) + add_dependencies(AFTERIMAGE FREETYPE) +endif() + +install(FILES ${afterimagelib} DESTINATION ${CMAKE_INSTALL_LIBDIR}) diff --git a/graf2d/asimage/CMakeLists.txt b/graf2d/asimage/CMakeLists.txt index c4dc5db228664..ea540eaa8128e 100644 --- a/graf2d/asimage/CMakeLists.txt +++ b/graf2d/asimage/CMakeLists.txt @@ -20,7 +20,7 @@ ROOT_USE_PACKAGE(graf2d/x11) ROOT_USE_PACKAGE(gui/gui) include_directories(${CMAKE_SOURCE_DIR}/hist/hist/inc) # This is to avoid a circular dependency graf <--> hist -include_directories(${FREETYPE_INCLUDE_DIRS} ${AFTERIMAGE_INCLUDE_DIR}) +include_directories(${FREETYPE_INCLUDE_DIRS} ${AFTERIMAGE_INCLUDE_DIR} ${X11_INCLUDE_DIR}) ROOT_GENERATE_DICTIONARY(G__ASImage TASImage.h TASImagePlugin.h TASPluginGS.h LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(ASImage LINKDEF LinkDef.h DEPENDENCIES Graf MathCore) diff --git a/graf2d/asimage/Module.mk b/graf2d/asimage/Module.mk index 9f3cca1cecb80..beee7e21c144b 100644 --- a/graf2d/asimage/Module.mk +++ b/graf2d/asimage/Module.mk @@ -95,6 +95,10 @@ ALLMAPS += $(ASIMAGEMAP) $(ASIMAGEGUIMAP) # include all dependency files INCLUDEFILES += $(ASIMAGEDEP) $(ASIMAGEGUIDEP) +ifneq ($(BUILDCOCOA),yes) +ASNEEDX11LIBS = $(XLIBS) +endif + ##### local rules ##### .PHONY: all-$(MODNAME) clean-$(MODNAME) distclean-$(MODNAME) @@ -166,6 +170,10 @@ else if [ "$(ASPNGINCDIR)" != "" ]; then \ PNGINCDIR="--with-png-includes=$(ASPNGINCDIR)"; \ fi; \ + if [ "$(BUILDCOCOA)" = "yes" ]; then \ + JPEGINCDIR="--without-x --with-builtin-jpeg"; \ + PNGINCDIR="--with-builtin-png"; \ + fi; \ if [ "$(ASTIFFINCDIR)" = "--with-tiff=no" ]; then \ TIFFINCDIR="$(ASTIFFINCDIR)"; \ elif [ "$(ASTIFFINCDIR)" != "" ]; then \ @@ -213,7 +221,7 @@ $(ASIMAGELIB): $(ASIMAGEO) $(ASIMAGEDO) $(ASTEPDEP) $(FREETYPEDEP) \ "$(ASIMAGEO) $(ASIMAGEDO)" \ "$(ASIMAGELIBEXTRA) $(ASTEPLIB) \ $(FREETYPELDFLAGS) $(FREETYPELIB) \ - $(ASEXTRALIBDIR) $(ASEXTRALIB) $(XLIBS)" + $(ASEXTRALIBDIR) $(ASEXTRALIB) $(ASNEEDX11LIBS)" $(ASIMAGEDS): $(ASIMAGEH) $(ASIMAGEL) $(ROOTCINTTMPDEP) $(MAKEDIR) @@ -232,7 +240,7 @@ $(ASIMAGEGUILIB): $(ASIMAGEGUIO) $(ASIMAGEGUIDO) $(ASTEPDEP) $(FREETYPEDEP) \ "$(ASIMAGEGUIO) $(ASIMAGEGUIDO)" \ "$(ASIMAGEGUILIBEXTRA) $(ASTEPLIB) \ $(FREETYPELDFLAGS) $(FREETYPELIB) \ - $(ASEXTRALIBDIR) $(ASEXTRALIB) $(XLIBS)" + $(ASEXTRALIBDIR) $(ASEXTRALIB) $(ASNEEDX11LIBS)" $(ASIMAGEGUIDS): $(ASIMAGEGUIH) $(ASIMAGEGUIL) $(ROOTCINTTMPDEP) $(MAKEDIR) @@ -295,7 +303,7 @@ distclean:: distclean-$(MODNAME) ##### extra rules ###### $(ASIMAGEO): $(ASTEPDEP) $(FREETYPEDEP) -$(ASIMAGEO): CXXFLAGS += $(FREETYPEINC) $(ASTEPDIRI) +$(ASIMAGEO): CXXFLAGS += $(FREETYPEINC) $(ASTEPDIRI) $(X11INCDIR:%=-I%) $(ASIMAGEGUIO) $(ASIMAGEGUIDO) $(ASIMAGEDO): $(ASTEPDEP) $(ASIMAGEGUIO) $(ASIMAGEGUIDO) $(ASIMAGEDO): CXXFLAGS += $(ASTEPDIRI) diff --git a/graf2d/asimage/src/TASImage.cxx b/graf2d/asimage/src/TASImage.cxx index 32860cd62f708..30824685ee5d2 100644 --- a/graf2d/asimage/src/TASImage.cxx +++ b/graf2d/asimage/src/TASImage.cxx @@ -51,6 +51,9 @@ dimensional array of values. A palette defines the color of each value. The image can be zoomed by defining a rectangle with the mouse. The color palette can be modified with a GUI, just select StartPaletteEditor() from the context menu. +

+Several examples showing how to use this class are available in the +ROOT tutorials: $ROOTSYS/tutorials/image/ End_Html */ #include "TASImage.h" @@ -77,15 +80,20 @@ End_Html */ #include "TEnv.h" #include "TStyle.h" #include "TText.h" - +#include "RConfigure.h" #ifndef WIN32 +#ifndef R__HAS_COCOA # include +#endif #else # include "Windows4root.h" #endif extern "C" { #ifndef WIN32 +#ifdef R__HAS_COCOA +# define X_DISPLAY_MISSING 1 +#endif # include #else # include @@ -2138,18 +2146,24 @@ Bool_t TASImage::InitVisual() return kTRUE; } +#ifndef WIN32 +#ifdef R__HAS_COCOA + fgVisual = create_asvisual(0, 0, 0, 0); + fgVisual->dpy = (Display*)1; //fake (not used) +#else disp = (Display*) gVirtualX->GetDisplay(); Int_t screen = gVirtualX->GetScreen(); Int_t depth = gVirtualX->GetDepth(); Visual *vis = (Visual*) gVirtualX->GetVisual(); Colormap cmap = (Colormap) gVirtualX->GetColormap(); -#ifndef WIN32 + if (vis == 0 || cmap == 0) { fgVisual = create_asvisual(0, 0, 0, 0); } else { fgVisual = create_asvisual_for_id(disp, screen, depth, XVisualIDFromVisual(vis), cmap, 0); } +#endif #else fgVisual = create_asvisual(0, 0, 0, 0); fgVisual->dpy = (Display*)1; //fake (not used) @@ -2507,7 +2521,7 @@ void TASImage::DrawText(Int_t x, Int_t y, const char *text, Int_t size, fn.Strip(); char *tmpstr = 0; - if (fn.EndsWith(".ttf") || fn.EndsWith(".TTF")) { + if (fn.EndsWith(".pfa") || fn.EndsWith(".PFA") || fn.EndsWith(".pfb") || fn.EndsWith(".PFB") || fn.EndsWith(".ttf") || fn.EndsWith(".TTF") || fn.EndsWith(".otf") || fn.EndsWith(".OTF")) { tmpstr = gSystem->ExpandPathName(fn.Data()); fn = tmpstr; ttfont = kTRUE; @@ -2619,9 +2633,9 @@ void TASImage::Merge(const TImage *im, const char *op, Int_t x, Int_t y) // dissipate - randomly alpha-blend images // hue - hue bottom image same as top image // lighten - use highest color value from both images - // overlay - some wierd image overlaying(see GIMP) + // overlay - some weird image overlaying(see GIMP) // saturate - saturate bottom image same as top image - // screen - another wierd image overlaying(see GIMP) + // screen - another weird image overlaying(see GIMP) // sub - color substraction with saturation // tint - tinting image with image // value - value bottom image same as top image @@ -4478,6 +4492,7 @@ void TASImage::DrawDashZTLine(UInt_t x1, UInt_t y1, UInt_t x2, UInt_t y2, x0 = x; y0 = y; iDash = 0; + xend = x + q; if (q > 0) { while ((x < xend) && (y < yend)) { @@ -5725,13 +5740,12 @@ void TASImage::DrawText(TText *text, Int_t x, Int_t y) Int_t wh = gPad->XtoPixel(gPad->GetX2()); Int_t hh = gPad->YtoPixel(gPad->GetY1()); - // set text size in pixels - Int_t ttfsize; - + // set text size + Float_t ttfsize; if (wh < hh) { - ttfsize = (Int_t)(text->GetTextSize()*wh); + ttfsize = text->GetTextSize()*wh; } else { - ttfsize = (Int_t)(text->GetTextSize()*hh); + ttfsize = text->GetTextSize()*hh; } TTF::SetTextSize(ttfsize); @@ -5739,7 +5753,12 @@ void TASImage::DrawText(TText *text, Int_t x, Int_t y) TTF::SetRotationMatrix(text->GetTextAngle()); // set text - TTF::PrepareString(text->GetTitle()); + const wchar_t *wcsTitle = reinterpret_cast(text->GetWcsTitle()); + if (wcsTitle != NULL) { + TTF::PrepareString(wcsTitle); + } else { + TTF::PrepareString(text->GetTitle()); + } TTF::LayoutGlyphs(); // color @@ -6505,8 +6524,7 @@ void TASImage::Gray(Bool_t on) CARD32 *bb = imdec->buffer.blue; ASScanline result; - ASScanline *sl = prepare_scanline(fImage->width, 0, &result, fgVisual->BGR_mode); - if (sl) delete sl; + prepare_scanline(fImage->width, 0, &result, fgVisual->BGR_mode); for (i = 0; i < fImage->height; i++) { imdec->decode_image_scanline(imdec); @@ -6642,7 +6660,7 @@ void TASImage::SetPaletteEnabled(Bool_t on) //______________________________________________________________________________ -void TASImage::SavePrimitive(ostream &out, Option_t * /*= ""*/) +void TASImage::SavePrimitive(std::ostream &out, Option_t * /*= ""*/) { // Save a primitive as a C++ statement(s) on output stream "out". @@ -6672,11 +6690,11 @@ void TASImage::SavePrimitive(ostream &out, Option_t * /*= ""*/) xpm += name; xpm += ii; str.ReplaceAll("asxpm", xpm.Data()); - out << endl << str << endl << endl; + out << std::endl << str << std::endl << std::endl; out << " TImage *"; - out << name << " = TImage::Create();" << endl; - out << " " << name << "->SetImageBuffer(" << xpm << ", TImage::kXpm);" << endl; - out << " " << name << "->Draw();" << endl; + out << name << " = TImage::Create();" << std::endl; + out << " " << name << "->SetImageBuffer(" << xpm << ", TImage::kXpm);" << std::endl; + out << " " << name << "->Draw();" << std::endl; } diff --git a/graf2d/asimage/src/TASPaletteEditor.cxx b/graf2d/asimage/src/TASPaletteEditor.cxx index f1f831617ac68..0872be1c0251e 100644 --- a/graf2d/asimage/src/TASPaletteEditor.cxx +++ b/graf2d/asimage/src/TASPaletteEditor.cxx @@ -32,6 +32,11 @@ #include "TROOT.h" #include "TClass.h" #include "TMath.h" +#include "RConfigure.h" + +#ifdef R__HAS_COCOA +# define X_DISPLAY_MISSING 1 +#endif #ifdef WIN32 #include "Windows4root.h" diff --git a/graf2d/asimage/src/TASPluginGS.cxx b/graf2d/asimage/src/TASPluginGS.cxx index 1b95fcafbe9da..4e26849557e2b 100644 --- a/graf2d/asimage/src/TASPluginGS.cxx +++ b/graf2d/asimage/src/TASPluginGS.cxx @@ -18,13 +18,17 @@ #include "TASPluginGS.h" #include "TSystem.h" +#include "RConfigure.h" -#ifndef WIN32 -# include +#ifdef R__HAS_COCOA +# define X_DISPLAY_MISSING 1 # define popen_flags "r" -#else +#elif defined (WIN32) # include "Windows4root.h" # define popen_flags "rb" +#else +# include +# define popen_flags "r" #endif extern "C" { @@ -38,7 +42,6 @@ extern "C" { # include } - ClassImp(TASPluginGS) diff --git a/graf2d/asimage/src/libAfterImage/ChangeLog b/graf2d/asimage/src/libAfterImage/ChangeLog index f95130a37844f..feb43bab7b913 100644 --- a/graf2d/asimage/src/libAfterImage/ChangeLog +++ b/graf2d/asimage/src/libAfterImage/ChangeLog @@ -510,7 +510,7 @@ up wharf's support for look defined folder icon. That should also speedup repeated changes of look * adding support in Wharf for look-specific folder pixmap - so far - only works 2 times, then stops changing - wierd + only works 2 times, then stops changing - weird 2007-07-19 sasha @@ -1059,7 +1059,7 @@ 2005-04-22 sasha - * Fixed off-by-one bug in ASStorage causing wierd artefact and + * Fixed off-by-one bug in ASStorage causing weird artefact and possibly segfaults, due to occupied slots being reused improperly 2005-04-21 sasha @@ -1381,7 +1381,7 @@ * fixed segfault in asstorage when diff buffer does not gets reallocated * fixed button ungrabbing on windows withdrawing that was causing - wierd BadAccess errors in Wharf + weird BadAccess errors in Wharf 2004-09-23 sasha @@ -1527,7 +1527,7 @@ calls to storage destruction code * fixed thresholding code in asstorage needed for rectangular shape stuff - * Improved reference counting in ASStorage to accomodate to wierd + * Improved reference counting in ASStorage to accomodate to weird storage states where some blocks have no space left for reference 2004-07-30 sasha @@ -1738,7 +1738,7 @@ 2004-03-18 sasha - * Found and fixed very wierd heap corruption bug, causing segfault + * Found and fixed very weird heap corruption bug, causing segfault whenever bevelled rectang is drawn * Added builtin libungif to libAfterImage, and enabled support for it by default in configure @@ -1839,7 +1839,7 @@ 2004-01-21 sasha * fixed bug where empty locale would be specified while starting a - module causing Pager to have 255 desktops and other wierdness + module causing Pager to have 255 desktops and other weirdness 2004-01-13 sasha @@ -1917,7 +1917,7 @@ * Added ActiveDeskBevel and InActiveDeskBevel to Pager's options; Debugged bevel drawing when tbar has different bevels for focus - and unfocus states( should get rid of wierd black frame when one + and unfocus states( should get rid of weird black frame when one of the states is None) 2003-09-25 sasha @@ -2121,7 +2121,7 @@ TakeFrameShot, as the side effect of debugging root background handling. Updated feel.DEFAULT to use those * fixed bug in inheritance code where back_icon would get destroyed - even if it was inherited, thus causing wierd things to happen + even if it was inherited, thus causing weird things to happen when same style is inherited twice; Added code to mystyle_make_image to ensure that we always produce valid ASImage @@ -3383,7 +3383,7 @@ * Completed Pseudo-color support with colormap allocation and ximage handling. Added create_asimage and destroy_asimage for convinience. Added missing stuff to libAfterImage/afterbase.h to - make it completely independant. libAfterImage thus should be + make it completely independent. libAfterImage thus should be ready for release - only to write up some docs :) 2001-06-13 sasha @@ -3495,7 +3495,7 @@ it. That should allow for better library independancy - visual will go with libAfterImage while ScreenInfo will move into libAfterStep , or, possibly will split up even more. Goal is to - make libAfterImage completely independant from everything else. + make libAfterImage completely independent from everything else. 2001-05-23 allanon @@ -3646,7 +3646,7 @@ * minor quality tweaks in rations 1-2 scaling up. Started implementing ASImageDecoder for automatic tinting/tiling * IMplemented JPEG input filter for ASImage. Fixed long standing - bug in image scaling causing wierdness in scaling UP with small + bug in image scaling causing weirdness in scaling UP with small ratios. Started implemntation of XCF file reader. 2001-04-15 sasha diff --git a/graf2d/asimage/src/libAfterImage/afterbase.c b/graf2d/asimage/src/libAfterImage/afterbase.c index b9dc251f69e00..2706bbe9d72d0 100644 --- a/graf2d/asimage/src/libAfterImage/afterbase.c +++ b/graf2d/asimage/src/libAfterImage/afterbase.c @@ -88,7 +88,7 @@ asim_set_application_name (char *argv0) do { /* Save our program name - for error messages */ register int i = 1 ; /* we don't use standard strrchr since there - * seems to be some wierdness in + * seems to be some weirdness in * CYGWIN implementation of it. */ asim_ApplicationName = temp ; while( temp[i] && temp[i] != '/' ) ++i ; @@ -705,8 +705,9 @@ double asim_parse_math(const char* str, char** endptr, double size) { num = asim_parse_math(str + 1, &ptr, size); else if (*str == '$') { - for (ptr = (char*)str + 1 ; *ptr && !isspace(*ptr) && *ptr != '+' && *ptr != '-' && *ptr != '*' && *ptr != '!' && *ptr != '/' && *ptr != ')' ; ptr++); - num = asim_asxml_var_nget((char*)str + 1, ptr - (str + 1)); + for (ptr = (char*)str + 1 ; *ptr && !isspace(*ptr) && *ptr != '+' && *ptr != '-' && *ptr != '*' && *ptr != '!' && *ptr != '/' && *ptr != ')' ; ptr++) + ; + num = asim_asxml_var_nget((char*)str + 1, ptr - (str + 1)); }else num = strtod(str, &ptr); diff --git a/graf2d/asimage/src/libAfterImage/blender.c b/graf2d/asimage/src/libAfterImage/blender.c index 94718b95f8cb6..e18ec60949b03 100644 --- a/graf2d/asimage/src/libAfterImage/blender.c +++ b/graf2d/asimage/src/libAfterImage/blender.c @@ -319,9 +319,9 @@ merge_scanlines_func_desc std_merge_scanlines_func_list[] = { "dissipate", 9, dissipate_scanlines, "randomly alpha-blend images"}, { "hue", 3, hue_scanlines, "hue bottom image same as top image" }, { "lighten", 7, lighten_scanlines, "use highest color value from both images" }, - { "overlay", 7, overlay_scanlines, "some wierd image overlaying(see GIMP)" }, + { "overlay", 7, overlay_scanlines, "some weird image overlaying(see GIMP)" }, { "saturate", 8, saturate_scanlines, "saturate bottom image same as top image"}, - { "screen", 6, screen_scanlines, "another wierd image overlaying(see GIMP)" }, + { "screen", 6, screen_scanlines, "another weird image overlaying(see GIMP)" }, { "sub", 3, sub_scanlines, "color substraction with saturation" }, { "tint", 4, tint_scanlines, "tinting image with image" }, { "value", 5, value_scanlines, "value bottom image same as top image" }, diff --git a/graf2d/asimage/src/libAfterImage/blender.h b/graf2d/asimage/src/libAfterImage/blender.h index f6c80a8bb90c9..67dc3e8e5c585 100644 --- a/graf2d/asimage/src/libAfterImage/blender.h +++ b/graf2d/asimage/src/libAfterImage/blender.h @@ -197,9 +197,9 @@ void hls2rgb (CARD32 hue, CARD32 luminance, CARD32 saturation, CARD32 *red, CARD * value of top and bottom : * bottom = (bottom>top)?bottom:top; * NAME - * screen_scanlines() - some wierd merging algorithm taken from GIMP; + * screen_scanlines() - some weird merging algorithm taken from GIMP; * NAME - * overlay_scanlines() - some wierd merging algorithm taken from GIMP; + * overlay_scanlines() - some weird merging algorithm taken from GIMP; * NAME * hue_scanlines() - substitute hue of bottom scanline with hue of * top scanline; diff --git a/graf2d/asimage/src/libAfterImage/bmp.c b/graf2d/asimage/src/libAfterImage/bmp.c index 4fa85afb45ddf..69fbf47175133 100644 --- a/graf2d/asimage/src/libAfterImage/bmp.c +++ b/graf2d/asimage/src/libAfterImage/bmp.c @@ -41,7 +41,7 @@ /* from import.c : */ FILE* open_image_file( const char *path ); /* from export.c : */ -FILE* open_writeable_image_file( const char *path ); +FILE* open_writable_image_file( const char *path ); void dib_data_to_scanline( ASScanline *buf, @@ -364,7 +364,7 @@ ASImage2bmp ( ASImage *im, const char *path, ASImageExportParams *params ) FILE *outfile = NULL ; START_TIME(started); - if ((outfile = open_writeable_image_file( path )) != NULL) + if ((outfile = open_writable_image_file( path )) != NULL) { void *bmbits ; BITMAPINFO *bmi = ASImage2DBI( get_default_asvisual(), im, 0, 0, im->width, im->height, &bmbits, 0 ); diff --git a/graf2d/asimage/src/libAfterImage/configure b/graf2d/asimage/src/libAfterImage/configure index 9f66e9a327eb9..b0ec6f5726662 100755 --- a/graf2d/asimage/src/libAfterImage/configure +++ b/graf2d/asimage/src/libAfterImage/configure @@ -8608,7 +8608,9 @@ _ACEOF have_ttf=yes fi if test "$have_ttf" = yes; then + if test "x$ttf_includes" = "xno"; then AFTERIMAGE_LIBS="`freetype-config --libs` $AFTERIMAGE_LIBS" + fi fi fi; diff --git a/graf2d/asimage/src/libAfterImage/export.c b/graf2d/asimage/src/libAfterImage/export.c index c49d30f12e024..f8e7c1b6739a4 100644 --- a/graf2d/asimage/src/libAfterImage/export.c +++ b/graf2d/asimage/src/libAfterImage/export.c @@ -184,7 +184,7 @@ ASImage2file( ASImage *im, const char *dir, const char *file, /* Some helper functions : */ FILE* -open_writeable_image_file( const char *path ) +open_writable_image_file( const char *path ) { FILE *fp = NULL; if ( path ) @@ -290,7 +290,7 @@ ASImage2xpm ( ASImage *im, const char *path, ASImageExportParams *params ) params = &defaults ; } - if ((outfile = open_writeable_image_file( path )) == NULL) + if ((outfile = open_writable_image_file( path )) == NULL) return False; mapped_im = colormap_asimage( im, &cmap, params->xpm.max_colors, params->xpm.dither, params->xpm.opaque_threshold ); @@ -648,7 +648,7 @@ ASImage2png ( ASImage *im, const char *path, register ASImageExportParams *param if( im == NULL ) return False; - if ((outfile = open_writeable_image_file( path )) == NULL) + if ((outfile = open_writable_image_file( path )) == NULL) return False; res = ASImage2png_int ( im, outfile, NULL, NULL, params ); @@ -765,7 +765,7 @@ ASImage2jpeg( ASImage *im, const char *path, ASImageExportParams *params ) params = &defaults ; } - if ((outfile = open_writeable_image_file( path )) == NULL) + if ((outfile = open_writable_image_file( path )) == NULL) return False; if((imdec = start_image_decoding( NULL /* default visual */ , im, @@ -1035,7 +1035,7 @@ Bool ASImage2gif( ASImage *im, const char *path, ASImageExportParams *params ) gif = NULL; fclose (infile); infile = NULL; - outfile = open_writeable_image_file( path ); + outfile = open_writable_image_file( path ); if (outfile) gif = EGifOpenFileHandle(fileno(outfile)); @@ -1077,7 +1077,7 @@ Bool ASImage2gif( ASImage *im, const char *path, ASImageExportParams *params ) if (gif == NULL) { if (outfile == NULL) - outfile = open_writeable_image_file(path); + outfile = open_writable_image_file(path); if (outfile) if ((gif = EGifOpenFileHandle(fileno(outfile))) == NULL) diff --git a/graf2d/asimage/src/libAfterImage/libAfterImage.dsp b/graf2d/asimage/src/libAfterImage/libAfterImage.dsp index 41ede97129a8e..893542dca4472 100644 --- a/graf2d/asimage/src/libAfterImage/libAfterImage.dsp +++ b/graf2d/asimage/src/libAfterImage/libAfterImage.dsp @@ -1,589 +1,589 @@ -# Microsoft Developer Studio Project File - Name="libAfterImage" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Static Library" 0x0104 - -CFG=libAfterImage - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "libAfterImage.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "libAfterImage.mak" CFG="libAfterImage - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "libAfterImage - Win32 Release" (based on "Win32 (x86) Static Library") -!MESSAGE "libAfterImage - Win32 Debug" (based on "Win32 (x86) Static Library") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -RSC=rc.exe - -!IF "$(CFG)" == "libAfterImage - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "Release" -# PROP Intermediate_Dir "Release" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c -# ADD CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NO_DEBUG_OUTPUT" /D "NDEBUG" /D "_LIB" /YX /FD /c -# ADD BASE RSC /l 0x409 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LIB32=link.exe -lib -# ADD BASE LIB32 /nologo -# ADD LIB32 /nologo /out:"libAfterImage.lib" - -!ELSEIF "$(CFG)" == "libAfterImage - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "" -# PROP Intermediate_Dir "win32\Debug" -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c -# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /FD /GZ /c -# SUBTRACT CPP /YX -# ADD BASE RSC /l 0x409 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LIB32=link.exe -lib -# ADD BASE LIB32 /nologo -# ADD LIB32 /nologo - -!ENDIF - -# Begin Target - -# Name "libAfterImage - Win32 Release" -# Name "libAfterImage - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Group "PNG Files" - -# PROP Default_Filter "" -# Begin Source File - -SOURCE=.\libpng\png.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngerror.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngget.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngmem.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngpread.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngread.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngrio.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngrtran.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngrutil.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngset.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngtrans.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngwio.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngwrite.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngwtran.c -# End Source File -# Begin Source File - -SOURCE=.\libpng\pngwutil.c -# End Source File -# End Group -# Begin Group "JPG Files" - -# PROP Default_Filter "" -# Begin Source File - -SOURCE=.\libjpeg\jcapimin.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jcapistd.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jccoefct.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jccolor.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jcdctmgr.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jchuff.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jcinit.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jcmainct.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jcmarker.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jcmaster.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jcomapi.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jcparam.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jcphuff.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jcprepct.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jcsample.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jctrans.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdapimin.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdapistd.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdatadst.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdatasrc.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdcoefct.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdcolor.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\transupp.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jaricom.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdarith.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jcarith.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jddctmgr.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdhuff.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdinput.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdmainct.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdmarker.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdmaster.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdmerge.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdpostct.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdsample.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jdtrans.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jerror.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jfdctflt.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jfdctfst.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jfdctint.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jidctflt.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jidctfst.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jidctint.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jmemmgr.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jmemnobs.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jquant1.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jquant2.c -# End Source File -# Begin Source File - -SOURCE=.\libjpeg\jutils.c -# End Source File -# End Group -# Begin Group "ZLIB Files" - -# PROP Default_Filter "" -# Begin Source File - -SOURCE=.\zlib\adler32.c -# End Source File -# Begin Source File - -SOURCE=.\zlib\compress.c -# End Source File -# Begin Source File - -SOURCE=.\zlib\crc32.c -# End Source File -# Begin Source File - -SOURCE=.\zlib\deflate.c -# End Source File -# Begin Source File - -SOURCE=.\zlib\gzio.c -# End Source File -# Begin Source File - -SOURCE=.\zlib\infback.c -# End Source File -# Begin Source File - -SOURCE=.\zlib\inffast.c -# End Source File -# Begin Source File - -SOURCE=.\zlib\inflate.c -# End Source File -# Begin Source File - -SOURCE=.\zlib\inftrees.c -# End Source File -# Begin Source File - -SOURCE=.\zlib\trees.c -# End Source File -# Begin Source File - -SOURCE=.\zlib\uncompr.c -# End Source File -# Begin Source File - -SOURCE=.\zlib\zutil.c -# End Source File -# End Group -# Begin Group "UNGIF Files" - -# PROP Default_Filter "*.c" -# Begin Source File - -SOURCE=.\libungif\dgif_lib.c -# End Source File -# Begin Source File - -SOURCE=.\libungif\egif_lib.c -# End Source File -# Begin Source File - -SOURCE=.\libungif\gif_err.c -# End Source File -# Begin Source File - -SOURCE=.\libungif\gifalloc.c -# End Source File -# End Group -# Begin Source File - -SOURCE=.\afterbase.c -# End Source File -# Begin Source File - -SOURCE=.\ascmap.c -# End Source File -# Begin Source File - -SOURCE=.\asfont.c -# End Source File -# Begin Source File - -SOURCE=.\asimage.c -# End Source File -# Begin Source File - -SOURCE=.\asimagexml.c -# End Source File -# Begin Source File - -SOURCE=.\asstorage.c -# End Source File -# Begin Source File - -SOURCE=.\asvisual.c -# End Source File -# Begin Source File - -SOURCE=.\blender.c -# End Source File -# Begin Source File - -SOURCE=.\bmp.c -# End Source File -# Begin Source File - -SOURCE=.\char2uni.c -# End Source File -# Begin Source File - -SOURCE=.\export.c -# End Source File -# Begin Source File - -SOURCE=.\imencdec.c -# End Source File -# Begin Source File - -SOURCE=.\import.c -# End Source File -# Begin Source File - -SOURCE=.\pixmap.c -# End Source File -# Begin Source File - -SOURCE=.\transform.c -# End Source File -# Begin Source File - -SOURCE=.\ungif.c -# End Source File -# Begin Source File - -SOURCE=.\xcf.c -# End Source File -# Begin Source File - -SOURCE=.\ximage.c -# End Source File -# Begin Source File - -SOURCE=.\xpm.c -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# Begin Source File - -SOURCE=.\win32\afterbase.h -# End Source File -# Begin Source File - -SOURCE=.\afterimage.h -# End Source File -# Begin Source File - -SOURCE=.\ascmap.h -# End Source File -# Begin Source File - -SOURCE=.\asfont.h -# End Source File -# Begin Source File - -SOURCE=.\asim_afterbase.h -# End Source File -# Begin Source File - -SOURCE=.\asimage.h -# End Source File -# Begin Source File - -SOURCE=.\asimagexml.h -# End Source File -# Begin Source File - -SOURCE=.\asvisual.h -# End Source File -# Begin Source File - -SOURCE=.\blender.h -# End Source File -# Begin Source File - -SOURCE=.\bmp.h -# End Source File -# Begin Source File - -SOURCE=.\char2uni.h -# End Source File -# Begin Source File - -SOURCE=.\win32\config.h -# End Source File -# Begin Source File - -SOURCE=.\export.h -# End Source File -# Begin Source File - -SOURCE=.\imencdec.h -# End Source File -# Begin Source File - -SOURCE=.\import.h -# End Source File -# Begin Source File - -SOURCE=.\pixmap.h -# End Source File -# Begin Source File - -SOURCE=.\transform.h -# End Source File -# Begin Source File - -SOURCE=.\ungif.h -# End Source File -# Begin Source File - -SOURCE=.\xcf.h -# End Source File -# Begin Source File - -SOURCE=.\ximage.h -# End Source File -# Begin Source File - -SOURCE=.\xpm.h -# End Source File -# Begin Source File - -SOURCE=.\xwrap.h -# End Source File -# End Group -# End Target -# End Project +# Microsoft Developer Studio Project File - Name="libAfterImage" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Static Library" 0x0104 + +CFG=libAfterImage - Win32 Debug +!MESSAGE This is not a valid makefile. To build this project using NMAKE, +!MESSAGE use the Export Makefile command and run +!MESSAGE +!MESSAGE NMAKE /f "libAfterImage.mak". +!MESSAGE +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "libAfterImage.mak" CFG="libAfterImage - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "libAfterImage - Win32 Release" (based on "Win32 (x86) Static Library") +!MESSAGE "libAfterImage - Win32 Debug" (based on "Win32 (x86) Static Library") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName "" +# PROP Scc_LocalPath "" +CPP=cl.exe +RSC=rc.exe + +!IF "$(CFG)" == "libAfterImage - Win32 Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "Release" +# PROP BASE Intermediate_Dir "Release" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "Release" +# PROP Intermediate_Dir "Release" +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c +# ADD CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NO_DEBUG_OUTPUT" /D "NDEBUG" /D "_LIB" /YX /FD /c +# ADD BASE RSC /l 0x409 /d "NDEBUG" +# ADD RSC /l 0x409 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LIB32=link.exe -lib +# ADD BASE LIB32 /nologo +# ADD LIB32 /nologo /out:"libAfterImage.lib" + +!ELSEIF "$(CFG)" == "libAfterImage - Win32 Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "Debug" +# PROP BASE Intermediate_Dir "Debug" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "" +# PROP Intermediate_Dir "win32\Debug" +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c +# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /FD /GZ /c +# SUBTRACT CPP /YX +# ADD BASE RSC /l 0x409 /d "_DEBUG" +# ADD RSC /l 0x409 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LIB32=link.exe -lib +# ADD BASE LIB32 /nologo +# ADD LIB32 /nologo + +!ENDIF + +# Begin Target + +# Name "libAfterImage - Win32 Release" +# Name "libAfterImage - Win32 Debug" +# Begin Group "Source Files" + +# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" +# Begin Group "PNG Files" + +# PROP Default_Filter "" +# Begin Source File + +SOURCE=.\libpng\png.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngerror.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngget.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngmem.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngpread.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngread.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngrio.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngrtran.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngrutil.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngset.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngtrans.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngwio.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngwrite.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngwtran.c +# End Source File +# Begin Source File + +SOURCE=.\libpng\pngwutil.c +# End Source File +# End Group +# Begin Group "JPG Files" + +# PROP Default_Filter "" +# Begin Source File + +SOURCE=.\libjpeg\jcapimin.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jcapistd.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jccoefct.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jccolor.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jcdctmgr.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jchuff.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jcinit.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jcmainct.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jcmarker.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jcmaster.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jcomapi.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jcparam.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jcphuff.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jcprepct.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jcsample.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jctrans.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdapimin.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdapistd.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdatadst.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdatasrc.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdcoefct.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdcolor.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\transupp.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jaricom.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdarith.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jcarith.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jddctmgr.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdhuff.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdinput.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdmainct.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdmarker.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdmaster.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdmerge.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdpostct.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdsample.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jdtrans.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jerror.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jfdctflt.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jfdctfst.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jfdctint.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jidctflt.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jidctfst.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jidctint.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jmemmgr.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jmemnobs.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jquant1.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jquant2.c +# End Source File +# Begin Source File + +SOURCE=.\libjpeg\jutils.c +# End Source File +# End Group +# Begin Group "ZLIB Files" + +# PROP Default_Filter "" +# Begin Source File + +SOURCE=.\zlib\adler32.c +# End Source File +# Begin Source File + +SOURCE=.\zlib\compress.c +# End Source File +# Begin Source File + +SOURCE=.\zlib\crc32.c +# End Source File +# Begin Source File + +SOURCE=.\zlib\deflate.c +# End Source File +# Begin Source File + +SOURCE=.\zlib\gzio.c +# End Source File +# Begin Source File + +SOURCE=.\zlib\infback.c +# End Source File +# Begin Source File + +SOURCE=.\zlib\inffast.c +# End Source File +# Begin Source File + +SOURCE=.\zlib\inflate.c +# End Source File +# Begin Source File + +SOURCE=.\zlib\inftrees.c +# End Source File +# Begin Source File + +SOURCE=.\zlib\trees.c +# End Source File +# Begin Source File + +SOURCE=.\zlib\uncompr.c +# End Source File +# Begin Source File + +SOURCE=.\zlib\zutil.c +# End Source File +# End Group +# Begin Group "UNGIF Files" + +# PROP Default_Filter "*.c" +# Begin Source File + +SOURCE=.\libungif\dgif_lib.c +# End Source File +# Begin Source File + +SOURCE=.\libungif\egif_lib.c +# End Source File +# Begin Source File + +SOURCE=.\libungif\gif_err.c +# End Source File +# Begin Source File + +SOURCE=.\libungif\gifalloc.c +# End Source File +# End Group +# Begin Source File + +SOURCE=.\afterbase.c +# End Source File +# Begin Source File + +SOURCE=.\ascmap.c +# End Source File +# Begin Source File + +SOURCE=.\asfont.c +# End Source File +# Begin Source File + +SOURCE=.\asimage.c +# End Source File +# Begin Source File + +SOURCE=.\asimagexml.c +# End Source File +# Begin Source File + +SOURCE=.\asstorage.c +# End Source File +# Begin Source File + +SOURCE=.\asvisual.c +# End Source File +# Begin Source File + +SOURCE=.\blender.c +# End Source File +# Begin Source File + +SOURCE=.\bmp.c +# End Source File +# Begin Source File + +SOURCE=.\char2uni.c +# End Source File +# Begin Source File + +SOURCE=.\export.c +# End Source File +# Begin Source File + +SOURCE=.\imencdec.c +# End Source File +# Begin Source File + +SOURCE=.\import.c +# End Source File +# Begin Source File + +SOURCE=.\pixmap.c +# End Source File +# Begin Source File + +SOURCE=.\transform.c +# End Source File +# Begin Source File + +SOURCE=.\ungif.c +# End Source File +# Begin Source File + +SOURCE=.\xcf.c +# End Source File +# Begin Source File + +SOURCE=.\ximage.c +# End Source File +# Begin Source File + +SOURCE=.\xpm.c +# End Source File +# End Group +# Begin Group "Header Files" + +# PROP Default_Filter "h;hpp;hxx;hm;inl" +# Begin Source File + +SOURCE=.\win32\afterbase.h +# End Source File +# Begin Source File + +SOURCE=.\afterimage.h +# End Source File +# Begin Source File + +SOURCE=.\ascmap.h +# End Source File +# Begin Source File + +SOURCE=.\asfont.h +# End Source File +# Begin Source File + +SOURCE=.\asim_afterbase.h +# End Source File +# Begin Source File + +SOURCE=.\asimage.h +# End Source File +# Begin Source File + +SOURCE=.\asimagexml.h +# End Source File +# Begin Source File + +SOURCE=.\asvisual.h +# End Source File +# Begin Source File + +SOURCE=.\blender.h +# End Source File +# Begin Source File + +SOURCE=.\bmp.h +# End Source File +# Begin Source File + +SOURCE=.\char2uni.h +# End Source File +# Begin Source File + +SOURCE=.\win32\config.h +# End Source File +# Begin Source File + +SOURCE=.\export.h +# End Source File +# Begin Source File + +SOURCE=.\imencdec.h +# End Source File +# Begin Source File + +SOURCE=.\import.h +# End Source File +# Begin Source File + +SOURCE=.\pixmap.h +# End Source File +# Begin Source File + +SOURCE=.\transform.h +# End Source File +# Begin Source File + +SOURCE=.\ungif.h +# End Source File +# Begin Source File + +SOURCE=.\xcf.h +# End Source File +# Begin Source File + +SOURCE=.\ximage.h +# End Source File +# Begin Source File + +SOURCE=.\xpm.h +# End Source File +# Begin Source File + +SOURCE=.\xwrap.h +# End Source File +# End Group +# End Target +# End Project diff --git a/graf2d/asimage/src/libAfterImage/libAfterImage.dsw b/graf2d/asimage/src/libAfterImage/libAfterImage.dsw index ad859b4a9197d..6966f1d96786b 100644 --- a/graf2d/asimage/src/libAfterImage/libAfterImage.dsw +++ b/graf2d/asimage/src/libAfterImage/libAfterImage.dsw @@ -1,44 +1,44 @@ -Microsoft Developer Studio Workspace File, Format Version 6.00 -# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! - -############################################################################### - -Project: "asview"=".\win32\asview.dsp" - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name libAfterImage - End Project Dependency -}}} - -############################################################################### - -Project: "libAfterImage"=".\libAfterImage.dsp" - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ -}}} - -############################################################################### - -Global: - -Package=<5> -{{{ -}}} - -Package=<3> -{{{ -}}} - -############################################################################### - +Microsoft Developer Studio Workspace File, Format Version 6.00 +# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! + +############################################################################### + +Project: "asview"=".\win32\asview.dsp" - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ + Begin Project Dependency + Project_Dep_Name libAfterImage + End Project Dependency +}}} + +############################################################################### + +Project: "libAfterImage"=".\libAfterImage.dsp" - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ +}}} + +############################################################################### + +Global: + +Package=<5> +{{{ +}}} + +Package=<3> +{{{ +}}} + +############################################################################### + diff --git a/graf2d/asimage/src/libAfterImage/libpng/LICENSE b/graf2d/asimage/src/libAfterImage/libpng/LICENSE index 5d70f168d995a..a684fe5a8f943 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/LICENSE +++ b/graf2d/asimage/src/libAfterImage/libpng/LICENSE @@ -8,8 +8,10 @@ COPYRIGHT NOTICE, DISCLAIMER, and LICENSE: If you modify libpng you may insert additional notices immediately following this sentence. -libpng versions 1.2.6, August 15, 2004, through 1.2.23, November 6, 2007, are -Copyright (c) 2004, 2006-2007 Glenn Randers-Pehrson, and are +This code is released under the libpng license. + +libpng versions 1.2.6, August 15, 2004, through 1.2.50, July 10, 2012, are +Copyright (c) 2004, 2006-2009 Glenn Randers-Pehrson, and are distributed according to the same disclaimer and license as libpng-1.2.5 with the following individual added to the list of Contributing Authors @@ -106,4 +108,4 @@ certification mark of the Open Source Initiative. Glenn Randers-Pehrson glennrp at users.sourceforge.net -November 6, 2007 +July 10, 2012 diff --git a/graf2d/asimage/src/libAfterImage/libpng/png.c b/graf2d/asimage/src/libAfterImage/libpng/png.c index 04dea606e32d6..18d26db8da92c 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/png.c +++ b/graf2d/asimage/src/libAfterImage/libpng/png.c @@ -1,22 +1,27 @@ /* png.c - location for general purpose libpng functions * - * Last changed in libpng 1.2.21 October 4, 2007 - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * Last changed in libpng 1.2.46 [February 25, 2011] + * Copyright (c) 1998-2011 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) + * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h */ #define PNG_INTERNAL #define PNG_NO_EXTERN +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" /* Generate a compiler error if there is an old png.h in the search path. */ -typedef version_1_2_23 Your_png_h_is_not_version_1_2_23; +typedef version_1_2_50 Your_png_h_is_not_version_1_2_50; /* Version information for C files. This had better match the version - * string defined in png.h. */ + * string defined in png.h. + */ #ifdef PNG_USE_GLOBAL_ARRAYS /* png_libpng_ver was changed to a function in version 1.0.5c */ @@ -53,18 +58,18 @@ PNG_tRNS; PNG_zTXt; #ifdef PNG_READ_SUPPORTED -/* arrays to facilitate easy interlacing - use pass (0 - 6) as index */ +/* Arrays to facilitate easy interlacing - use pass (0 - 6) as index */ -/* start of interlace block */ +/* Start of interlace block */ PNG_CONST int FARDATA png_pass_start[] = {0, 4, 0, 2, 0, 1, 0}; -/* offset to next interlace block */ +/* Offset to next interlace block */ PNG_CONST int FARDATA png_pass_inc[] = {8, 8, 4, 4, 2, 2, 1}; -/* start of interlace block in the y direction */ +/* Start of interlace block in the y direction */ PNG_CONST int FARDATA png_pass_ystart[] = {0, 0, 4, 0, 2, 0, 1}; -/* offset to next interlace block in the y direction */ +/* Offset to next interlace block in the y direction */ PNG_CONST int FARDATA png_pass_yinc[] = {8, 8, 8, 4, 4, 2, 2}; /* Height of interlace block. This is not currently used - if you need @@ -73,7 +78,8 @@ PNG_CONST int FARDATA png_pass_height[] = {8, 8, 4, 4, 2, 2, 1}; */ /* Mask to determine which pixels are valid in a pass */ -PNG_CONST int FARDATA png_pass_mask[] = {0x80, 0x08, 0x88, 0x22, 0xaa, 0x55, 0xff}; +PNG_CONST int FARDATA png_pass_mask[] = + {0x80, 0x08, 0x88, 0x22, 0xaa, 0x55, 0xff}; /* Mask to determine which pixels to overwrite while displaying */ PNG_CONST int FARDATA png_pass_dsp_mask[] @@ -92,8 +98,11 @@ PNG_CONST int FARDATA png_pass_dsp_mask[] void PNGAPI png_set_sig_bytes(png_structp png_ptr, int num_bytes) { - if(png_ptr == NULL) return; - png_debug(1, "in png_set_sig_bytes\n"); + png_debug(1, "in png_set_sig_bytes"); + + if (png_ptr == NULL) + return; + if (num_bytes > 8) png_error(png_ptr, "Too many bytes for PNG signature."); @@ -144,7 +153,7 @@ png_check_sig(png_bytep sig, int num) #ifdef PNG_1_0_X voidpf PNGAPI #else -voidpf /* private */ +voidpf /* PRIVATE */ #endif png_zalloc(voidpf png_ptr, uInt items, uInt size) { @@ -153,7 +162,8 @@ png_zalloc(voidpf png_ptr, uInt items, uInt size) png_uint_32 save_flags=p->flags; png_uint_32 num_bytes; - if(png_ptr == NULL) return (NULL); + if (png_ptr == NULL) + return (NULL); if (items > PNG_UINT_32_MAX/size) { png_warning (p, "Potential overflow in png_zalloc()"); @@ -183,11 +193,11 @@ png_zalloc(voidpf png_ptr, uInt items, uInt size) return ((voidpf)ptr); } -/* function to free memory for zlib */ +/* Function to free memory for zlib */ #ifdef PNG_1_0_X void PNGAPI #else -void /* private */ +void /* PRIVATE */ #endif png_zfree(voidpf png_ptr, voidpf ptr) { @@ -240,8 +250,11 @@ png_create_info_struct(png_structp png_ptr) { png_infop info_ptr; - png_debug(1, "in png_create_info_struct\n"); - if(png_ptr == NULL) return (NULL); + png_debug(1, "in png_create_info_struct"); + + if (png_ptr == NULL) + return (NULL); + #ifdef PNG_USER_MEM_SUPPORTED info_ptr = (png_infop)png_create_struct_2(PNG_STRUCT_INFO, png_ptr->malloc_fn, png_ptr->mem_ptr); @@ -263,9 +276,12 @@ void PNGAPI png_destroy_info_struct(png_structp png_ptr, png_infopp info_ptr_ptr) { png_infop info_ptr = NULL; - if(png_ptr == NULL) return; - png_debug(1, "in png_destroy_info_struct\n"); + png_debug(1, "in png_destroy_info_struct"); + + if (png_ptr == NULL) + return; + if (info_ptr_ptr != NULL) info_ptr = *info_ptr_ptr; @@ -302,19 +318,20 @@ png_info_init_3(png_infopp ptr_ptr, png_size_t png_info_struct_size) { png_infop info_ptr = *ptr_ptr; - if(info_ptr == NULL) return; + png_debug(1, "in png_info_init_3"); - png_debug(1, "in png_info_init_3\n"); + if (info_ptr == NULL) + return; - if(png_sizeof(png_info) > png_info_struct_size) - { - png_destroy_struct(info_ptr); - info_ptr = (png_infop)png_create_struct(PNG_STRUCT_INFO); - *ptr_ptr = info_ptr; - } + if (png_sizeof(png_info) > png_info_struct_size) + { + png_destroy_struct(info_ptr); + info_ptr = (png_infop)png_create_struct(PNG_STRUCT_INFO); + *ptr_ptr = info_ptr; + } - /* set everything to 0 */ - png_memset(info_ptr, 0, png_sizeof (png_info)); + /* Set everything to 0 */ + png_memset(info_ptr, 0, png_sizeof(png_info)); } #ifdef PNG_FREE_ME_SUPPORTED @@ -322,12 +339,14 @@ void PNGAPI png_data_freer(png_structp png_ptr, png_infop info_ptr, int freer, png_uint_32 mask) { - png_debug(1, "in png_data_freer\n"); + png_debug(1, "in png_data_freer"); + if (png_ptr == NULL || info_ptr == NULL) return; - if(freer == PNG_DESTROY_WILL_FREE_DATA) + + if (freer == PNG_DESTROY_WILL_FREE_DATA) info_ptr->free_me |= mask; - else if(freer == PNG_USER_WILL_FREE_DATA) + else if (freer == PNG_USER_WILL_FREE_DATA) info_ptr->free_me &= ~mask; else png_warning(png_ptr, @@ -339,249 +358,251 @@ void PNGAPI png_free_data(png_structp png_ptr, png_infop info_ptr, png_uint_32 mask, int num) { - png_debug(1, "in png_free_data\n"); + png_debug(1, "in png_free_data"); + if (png_ptr == NULL || info_ptr == NULL) return; -#if defined(PNG_TEXT_SUPPORTED) -/* free text item num or (if num == -1) all text items */ +#ifdef PNG_TEXT_SUPPORTED + /* Free text item num or (if num == -1) all text items */ #ifdef PNG_FREE_ME_SUPPORTED -if ((mask & PNG_FREE_TEXT) & info_ptr->free_me) + if ((mask & PNG_FREE_TEXT) & info_ptr->free_me) #else -if (mask & PNG_FREE_TEXT) + if (mask & PNG_FREE_TEXT) #endif -{ - if (num != -1) { - if (info_ptr->text && info_ptr->text[num].key) - { - png_free(png_ptr, info_ptr->text[num].key); - info_ptr->text[num].key = NULL; - } - } - else - { - int i; - for (i = 0; i < info_ptr->num_text; i++) - png_free_data(png_ptr, info_ptr, PNG_FREE_TEXT, i); - png_free(png_ptr, info_ptr->text); - info_ptr->text = NULL; - info_ptr->num_text=0; + if (num != -1) + { + if (info_ptr->text && info_ptr->text[num].key) + { + png_free(png_ptr, info_ptr->text[num].key); + info_ptr->text[num].key = NULL; + } + } + else + { + int i; + for (i = 0; i < info_ptr->num_text; i++) + png_free_data(png_ptr, info_ptr, PNG_FREE_TEXT, i); + png_free(png_ptr, info_ptr->text); + info_ptr->text = NULL; + info_ptr->num_text=0; + } } -} #endif -#if defined(PNG_tRNS_SUPPORTED) -/* free any tRNS entry */ +#ifdef PNG_tRNS_SUPPORTED + /* Free any tRNS entry */ #ifdef PNG_FREE_ME_SUPPORTED -if ((mask & PNG_FREE_TRNS) & info_ptr->free_me) + if ((mask & PNG_FREE_TRNS) & info_ptr->free_me) #else -if ((mask & PNG_FREE_TRNS) && (png_ptr->flags & PNG_FLAG_FREE_TRNS)) + if ((mask & PNG_FREE_TRNS) && (png_ptr->flags & PNG_FLAG_FREE_TRNS)) #endif -{ - png_free(png_ptr, info_ptr->trans); - info_ptr->valid &= ~PNG_INFO_tRNS; + { + png_free(png_ptr, info_ptr->trans); + info_ptr->trans = NULL; + info_ptr->valid &= ~PNG_INFO_tRNS; #ifndef PNG_FREE_ME_SUPPORTED - png_ptr->flags &= ~PNG_FLAG_FREE_TRNS; + png_ptr->flags &= ~PNG_FLAG_FREE_TRNS; #endif - info_ptr->trans = NULL; -} + } #endif -#if defined(PNG_sCAL_SUPPORTED) -/* free any sCAL entry */ +#ifdef PNG_sCAL_SUPPORTED + /* Free any sCAL entry */ #ifdef PNG_FREE_ME_SUPPORTED -if ((mask & PNG_FREE_SCAL) & info_ptr->free_me) + if ((mask & PNG_FREE_SCAL) & info_ptr->free_me) #else -if (mask & PNG_FREE_SCAL) + if (mask & PNG_FREE_SCAL) #endif -{ + { #if defined(PNG_FIXED_POINT_SUPPORTED) && !defined(PNG_FLOATING_POINT_SUPPORTED) - png_free(png_ptr, info_ptr->scal_s_width); - png_free(png_ptr, info_ptr->scal_s_height); - info_ptr->scal_s_width = NULL; - info_ptr->scal_s_height = NULL; + png_free(png_ptr, info_ptr->scal_s_width); + png_free(png_ptr, info_ptr->scal_s_height); + info_ptr->scal_s_width = NULL; + info_ptr->scal_s_height = NULL; #endif - info_ptr->valid &= ~PNG_INFO_sCAL; -} + info_ptr->valid &= ~PNG_INFO_sCAL; + } #endif -#if defined(PNG_pCAL_SUPPORTED) -/* free any pCAL entry */ +#ifdef PNG_pCAL_SUPPORTED + /* Free any pCAL entry */ #ifdef PNG_FREE_ME_SUPPORTED -if ((mask & PNG_FREE_PCAL) & info_ptr->free_me) + if ((mask & PNG_FREE_PCAL) & info_ptr->free_me) #else -if (mask & PNG_FREE_PCAL) + if (mask & PNG_FREE_PCAL) #endif -{ - png_free(png_ptr, info_ptr->pcal_purpose); - png_free(png_ptr, info_ptr->pcal_units); - info_ptr->pcal_purpose = NULL; - info_ptr->pcal_units = NULL; - if (info_ptr->pcal_params != NULL) - { - int i; - for (i = 0; i < (int)info_ptr->pcal_nparams; i++) - { - png_free(png_ptr, info_ptr->pcal_params[i]); - info_ptr->pcal_params[i]=NULL; - } - png_free(png_ptr, info_ptr->pcal_params); - info_ptr->pcal_params = NULL; - } - info_ptr->valid &= ~PNG_INFO_pCAL; -} + { + png_free(png_ptr, info_ptr->pcal_purpose); + png_free(png_ptr, info_ptr->pcal_units); + info_ptr->pcal_purpose = NULL; + info_ptr->pcal_units = NULL; + if (info_ptr->pcal_params != NULL) + { + int i; + for (i = 0; i < (int)info_ptr->pcal_nparams; i++) + { + png_free(png_ptr, info_ptr->pcal_params[i]); + info_ptr->pcal_params[i] = NULL; + } + png_free(png_ptr, info_ptr->pcal_params); + info_ptr->pcal_params = NULL; + } + info_ptr->valid &= ~PNG_INFO_pCAL; + } #endif -#if defined(PNG_iCCP_SUPPORTED) -/* free any iCCP entry */ +#ifdef PNG_iCCP_SUPPORTED + /* Free any iCCP entry */ #ifdef PNG_FREE_ME_SUPPORTED -if ((mask & PNG_FREE_ICCP) & info_ptr->free_me) + if ((mask & PNG_FREE_ICCP) & info_ptr->free_me) #else -if (mask & PNG_FREE_ICCP) + if (mask & PNG_FREE_ICCP) #endif -{ - png_free(png_ptr, info_ptr->iccp_name); - png_free(png_ptr, info_ptr->iccp_profile); - info_ptr->iccp_name = NULL; - info_ptr->iccp_profile = NULL; - info_ptr->valid &= ~PNG_INFO_iCCP; -} + { + png_free(png_ptr, info_ptr->iccp_name); + png_free(png_ptr, info_ptr->iccp_profile); + info_ptr->iccp_name = NULL; + info_ptr->iccp_profile = NULL; + info_ptr->valid &= ~PNG_INFO_iCCP; + } #endif -#if defined(PNG_sPLT_SUPPORTED) -/* free a given sPLT entry, or (if num == -1) all sPLT entries */ +#ifdef PNG_sPLT_SUPPORTED + /* Free a given sPLT entry, or (if num == -1) all sPLT entries */ #ifdef PNG_FREE_ME_SUPPORTED -if ((mask & PNG_FREE_SPLT) & info_ptr->free_me) + if ((mask & PNG_FREE_SPLT) & info_ptr->free_me) #else -if (mask & PNG_FREE_SPLT) + if (mask & PNG_FREE_SPLT) #endif -{ - if (num != -1) { - if(info_ptr->splt_palettes) + if (num != -1) + { + if (info_ptr->splt_palettes) + { + png_free(png_ptr, info_ptr->splt_palettes[num].name); + png_free(png_ptr, info_ptr->splt_palettes[num].entries); + info_ptr->splt_palettes[num].name = NULL; + info_ptr->splt_palettes[num].entries = NULL; + } + } + else { - png_free(png_ptr, info_ptr->splt_palettes[num].name); - png_free(png_ptr, info_ptr->splt_palettes[num].entries); - info_ptr->splt_palettes[num].name = NULL; - info_ptr->splt_palettes[num].entries = NULL; + if (info_ptr->splt_palettes_num) + { + int i; + for (i = 0; i < (int)info_ptr->splt_palettes_num; i++) + png_free_data(png_ptr, info_ptr, PNG_FREE_SPLT, i); + + png_free(png_ptr, info_ptr->splt_palettes); + info_ptr->splt_palettes = NULL; + info_ptr->splt_palettes_num = 0; + } + info_ptr->valid &= ~PNG_INFO_sPLT; } } - else - { - if(info_ptr->splt_palettes_num) - { - int i; - for (i = 0; i < (int)info_ptr->splt_palettes_num; i++) - png_free_data(png_ptr, info_ptr, PNG_FREE_SPLT, i); +#endif - png_free(png_ptr, info_ptr->splt_palettes); - info_ptr->splt_palettes = NULL; - info_ptr->splt_palettes_num = 0; - } - info_ptr->valid &= ~PNG_INFO_sPLT; +#ifdef PNG_UNKNOWN_CHUNKS_SUPPORTED + if (png_ptr->unknown_chunk.data) + { + png_free(png_ptr, png_ptr->unknown_chunk.data); + png_ptr->unknown_chunk.data = NULL; } -} -#endif -#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) - if(png_ptr->unknown_chunk.data) - { - png_free(png_ptr, png_ptr->unknown_chunk.data); - png_ptr->unknown_chunk.data = NULL; - } #ifdef PNG_FREE_ME_SUPPORTED -if ((mask & PNG_FREE_UNKN) & info_ptr->free_me) + if ((mask & PNG_FREE_UNKN) & info_ptr->free_me) #else -if (mask & PNG_FREE_UNKN) + if (mask & PNG_FREE_UNKN) #endif -{ - if (num != -1) - { - if(info_ptr->unknown_chunks) - { - png_free(png_ptr, info_ptr->unknown_chunks[num].data); - info_ptr->unknown_chunks[num].data = NULL; - } - } - else { - int i; + if (num != -1) + { + if (info_ptr->unknown_chunks) + { + png_free(png_ptr, info_ptr->unknown_chunks[num].data); + info_ptr->unknown_chunks[num].data = NULL; + } + } + else + { + int i; - if(info_ptr->unknown_chunks_num) - { - for (i = 0; i < (int)info_ptr->unknown_chunks_num; i++) - png_free_data(png_ptr, info_ptr, PNG_FREE_UNKN, i); + if (info_ptr->unknown_chunks_num) + { + for (i = 0; i < (int)info_ptr->unknown_chunks_num; i++) + png_free_data(png_ptr, info_ptr, PNG_FREE_UNKN, i); - png_free(png_ptr, info_ptr->unknown_chunks); - info_ptr->unknown_chunks = NULL; - info_ptr->unknown_chunks_num = 0; - } + png_free(png_ptr, info_ptr->unknown_chunks); + info_ptr->unknown_chunks = NULL; + info_ptr->unknown_chunks_num = 0; + } + } } -} #endif -#if defined(PNG_hIST_SUPPORTED) -/* free any hIST entry */ +#ifdef PNG_hIST_SUPPORTED + /* Free any hIST entry */ #ifdef PNG_FREE_ME_SUPPORTED -if ((mask & PNG_FREE_HIST) & info_ptr->free_me) + if ((mask & PNG_FREE_HIST) & info_ptr->free_me) #else -if ((mask & PNG_FREE_HIST) && (png_ptr->flags & PNG_FLAG_FREE_HIST)) + if ((mask & PNG_FREE_HIST) && (png_ptr->flags & PNG_FLAG_FREE_HIST)) #endif -{ - png_free(png_ptr, info_ptr->hist); - info_ptr->hist = NULL; - info_ptr->valid &= ~PNG_INFO_hIST; + { + png_free(png_ptr, info_ptr->hist); + info_ptr->hist = NULL; + info_ptr->valid &= ~PNG_INFO_hIST; #ifndef PNG_FREE_ME_SUPPORTED - png_ptr->flags &= ~PNG_FLAG_FREE_HIST; + png_ptr->flags &= ~PNG_FLAG_FREE_HIST; #endif -} + } #endif -/* free any PLTE entry that was internally allocated */ + /* Free any PLTE entry that was internally allocated */ #ifdef PNG_FREE_ME_SUPPORTED -if ((mask & PNG_FREE_PLTE) & info_ptr->free_me) + if ((mask & PNG_FREE_PLTE) & info_ptr->free_me) #else -if ((mask & PNG_FREE_PLTE) && (png_ptr->flags & PNG_FLAG_FREE_PLTE)) + if ((mask & PNG_FREE_PLTE) && (png_ptr->flags & PNG_FLAG_FREE_PLTE)) #endif -{ - png_zfree(png_ptr, info_ptr->palette); - info_ptr->palette = NULL; - info_ptr->valid &= ~PNG_INFO_PLTE; + { + png_zfree(png_ptr, info_ptr->palette); + info_ptr->palette = NULL; + info_ptr->valid &= ~PNG_INFO_PLTE; #ifndef PNG_FREE_ME_SUPPORTED - png_ptr->flags &= ~PNG_FLAG_FREE_PLTE; + png_ptr->flags &= ~PNG_FLAG_FREE_PLTE; #endif - info_ptr->num_palette = 0; -} + info_ptr->num_palette = 0; + } -#if defined(PNG_INFO_IMAGE_SUPPORTED) -/* free any image bits attached to the info structure */ +#ifdef PNG_INFO_IMAGE_SUPPORTED + /* Free any image bits attached to the info structure */ #ifdef PNG_FREE_ME_SUPPORTED -if ((mask & PNG_FREE_ROWS) & info_ptr->free_me) + if ((mask & PNG_FREE_ROWS) & info_ptr->free_me) #else -if (mask & PNG_FREE_ROWS) + if (mask & PNG_FREE_ROWS) #endif -{ - if(info_ptr->row_pointers) - { - int row; - for (row = 0; row < (int)info_ptr->height; row++) - { - png_free(png_ptr, info_ptr->row_pointers[row]); - info_ptr->row_pointers[row]=NULL; - } - png_free(png_ptr, info_ptr->row_pointers); - info_ptr->row_pointers=NULL; - } - info_ptr->valid &= ~PNG_INFO_IDAT; -} + { + if (info_ptr->row_pointers) + { + int row; + for (row = 0; row < (int)info_ptr->height; row++) + { + png_free(png_ptr, info_ptr->row_pointers[row]); + info_ptr->row_pointers[row] = NULL; + } + png_free(png_ptr, info_ptr->row_pointers); + info_ptr->row_pointers = NULL; + } + info_ptr->valid &= ~PNG_INFO_IDAT; + } #endif #ifdef PNG_FREE_ME_SUPPORTED - if(num == -1) - info_ptr->free_me &= ~mask; + if (num == -1) + info_ptr->free_me &= ~mask; else - info_ptr->free_me &= ~(mask & ~PNG_FREE_MUL); + info_ptr->free_me &= ~(mask & ~PNG_FREE_MUL); #endif } @@ -592,16 +613,16 @@ if (mask & PNG_FREE_ROWS) void /* PRIVATE */ png_info_destroy(png_structp png_ptr, png_infop info_ptr) { - png_debug(1, "in png_info_destroy\n"); + png_debug(1, "in png_info_destroy"); png_free_data(png_ptr, info_ptr, PNG_FREE_ALL, -1); -#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) +#ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED if (png_ptr->num_chunk_list) { - png_free(png_ptr, png_ptr->chunk_list); - png_ptr->chunk_list=NULL; - png_ptr->num_chunk_list=0; + png_free(png_ptr, png_ptr->chunk_list); + png_ptr->chunk_list = NULL; + png_ptr->num_chunk_list = 0; } #endif @@ -616,12 +637,13 @@ png_info_destroy(png_structp png_ptr, png_infop info_ptr) png_voidp PNGAPI png_get_io_ptr(png_structp png_ptr) { - if(png_ptr == NULL) return (NULL); + if (png_ptr == NULL) + return (NULL); return (png_ptr->io_ptr); } #if defined(PNG_READ_SUPPORTED) || defined(PNG_WRITE_SUPPORTED) -#if !defined(PNG_NO_STDIO) +#ifdef PNG_STDIO_SUPPORTED /* Initialize the default input/output functions for the PNG file. If you * use your own read or write routines, you can call either png_set_read_fn() * or png_set_write_fn() instead of png_init_io(). If you have defined @@ -631,13 +653,16 @@ png_get_io_ptr(png_structp png_ptr) void PNGAPI png_init_io(png_structp png_ptr, png_FILE_p fp) { - png_debug(1, "in png_init_io\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_init_io"); + + if (png_ptr == NULL) + return; + png_ptr->io_ptr = (png_voidp)fp; } #endif -#if defined(PNG_TIME_RFC1123_SUPPORTED) +#ifdef PNG_TIME_RFC1123_SUPPORTED /* Convert the supplied time into an RFC 1123 string suitable for use in * a "Creation Time" or other text-based time string. */ @@ -648,28 +673,29 @@ png_convert_to_rfc1123(png_structp png_ptr, png_timep ptime) {"Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"}; - if(png_ptr == NULL) return (NULL); + if (png_ptr == NULL) + return (NULL); if (png_ptr->time_buffer == NULL) { png_ptr->time_buffer = (png_charp)png_malloc(png_ptr, (png_uint_32)(29* png_sizeof(char))); } -#if defined(_WIN32_WCE) +#ifdef _WIN32_WCE { wchar_t time_buf[29]; wsprintf(time_buf, TEXT("%d %S %d %02d:%02d:%02d +0000"), ptime->day % 32, short_months[(ptime->month - 1) % 12], ptime->year, ptime->hour % 24, ptime->minute % 60, ptime->second % 61); - WideCharToMultiByte(CP_ACP, 0, time_buf, -1, png_ptr->time_buffer, 29, - NULL, NULL); + WideCharToMultiByte(CP_ACP, 0, time_buf, -1, png_ptr->time_buffer, + 29, NULL, NULL); } #else #ifdef USE_FAR_KEYWORD { char near_time_buf[29]; - png_snprintf6(near_time_buf,29,"%d %s %d %02d:%02d:%02d +0000", + png_snprintf6(near_time_buf, 29, "%d %s %d %02d:%02d:%02d +0000", ptime->day % 32, short_months[(ptime->month - 1) % 12], ptime->year, ptime->hour % 24, ptime->minute % 60, ptime->second % 61); @@ -677,7 +703,7 @@ png_convert_to_rfc1123(png_structp png_ptr, png_timep ptime) 29*png_sizeof(char)); } #else - png_snprintf6(png_ptr->time_buffer,29,"%d %s %d %02d:%02d:%02d +0000", + png_snprintf6(png_ptr->time_buffer, 29, "%d %s %d %02d:%02d:%02d +0000", ptime->day % 32, short_months[(ptime->month - 1) % 12], ptime->year, ptime->hour % 24, ptime->minute % 60, ptime->second % 61); @@ -692,11 +718,24 @@ png_convert_to_rfc1123(png_structp png_ptr, png_timep ptime) png_charp PNGAPI png_get_copyright(png_structp png_ptr) { - png_ptr = png_ptr; /* silence compiler warning about unused png_ptr */ - return ((png_charp) "\n libpng version 1.2.23 - November 6, 2007\n\ - Copyright (c) 1998-2007 Glenn Randers-Pehrson\n\ - Copyright (c) 1996-1997 Andreas Dilger\n\ - Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.\n"); + png_ptr = png_ptr; /* Silence compiler warning about unused png_ptr */ +#ifdef PNG_STRING_COPYRIGHT + return PNG_STRING_COPYRIGHT +#else +#ifdef __STDC__ + return ((png_charp) PNG_STRING_NEWLINE \ + "libpng version 1.2.50 - July 10, 2012" PNG_STRING_NEWLINE \ + "Copyright (c) 1998-2011 Glenn Randers-Pehrson" PNG_STRING_NEWLINE \ + "Copyright (c) 1996-1997 Andreas Dilger" PNG_STRING_NEWLINE \ + "Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc." \ + PNG_STRING_NEWLINE); +#else + return ((png_charp) "libpng version 1.2.50 - July 10, 2012\ + Copyright (c) 1998-2011 Glenn Randers-Pehrson\ + Copyright (c) 1996-1997 Andreas Dilger\ + Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc."); +#endif +#endif } /* The following return the library version as a short string in the @@ -711,7 +750,7 @@ png_charp PNGAPI png_get_libpng_ver(png_structp png_ptr) { /* Version of *.c files used when building libpng */ - png_ptr = png_ptr; /* silence compiler warning about unused png_ptr */ + png_ptr = png_ptr; /* Silence compiler warning about unused png_ptr */ return ((png_charp) PNG_LIBPNG_VER_STRING); } @@ -719,7 +758,7 @@ png_charp PNGAPI png_get_header_ver(png_structp png_ptr) { /* Version of *.h files used when building libpng */ - png_ptr = png_ptr; /* silence compiler warning about unused png_ptr */ + png_ptr = png_ptr; /* Silence compiler warning about unused png_ptr */ return ((png_charp) PNG_LIBPNG_VER_STRING); } @@ -727,12 +766,16 @@ png_charp PNGAPI png_get_header_version(png_structp png_ptr) { /* Returns longer string containing both version and date */ - png_ptr = png_ptr; /* silence compiler warning about unused png_ptr */ + png_ptr = png_ptr; /* Silence compiler warning about unused png_ptr */ +#ifdef __STDC__ return ((png_charp) PNG_HEADER_VERSION_STRING #ifndef PNG_READ_SUPPORTED " (NO READ SUPPORT)" #endif - "\n"); + PNG_STRING_NEWLINE); +#else + return ((png_charp) PNG_HEADER_VERSION_STRING); +#endif } #if defined(PNG_READ_SUPPORTED) || defined(PNG_WRITE_SUPPORTED) @@ -740,15 +783,15 @@ png_get_header_version(png_structp png_ptr) int PNGAPI png_handle_as_unknown(png_structp png_ptr, png_bytep chunk_name) { - /* check chunk_name and return "keep" value if it's on the list, else 0 */ + /* Check chunk_name and return "keep" value if it's on the list, else 0 */ int i; png_bytep p; - if(png_ptr == NULL || chunk_name == NULL || png_ptr->num_chunk_list<=0) + if (png_ptr == NULL || chunk_name == NULL || png_ptr->num_chunk_list<=0) return 0; - p=png_ptr->chunk_list+png_ptr->num_chunk_list*5-5; - for (i = png_ptr->num_chunk_list; i; i--, p-=5) + p = png_ptr->chunk_list + png_ptr->num_chunk_list*5 - 5; + for (i = png_ptr->num_chunk_list; i; i--, p -= 5) if (!png_memcmp(chunk_name, p, 4)) - return ((int)*(p+4)); + return ((int)*(p + 4)); return 0; } #endif @@ -757,7 +800,8 @@ png_handle_as_unknown(png_structp png_ptr, png_bytep chunk_name) int PNGAPI png_reset_zstream(png_structp png_ptr) { - if (png_ptr == NULL) return Z_STREAM_ERROR; + if (png_ptr == NULL) + return Z_STREAM_ERROR; return (inflateReset(&png_ptr->zstream)); } #endif /* defined(PNG_READ_SUPPORTED) || defined(PNG_WRITE_SUPPORTED) */ @@ -772,12 +816,12 @@ png_access_version_number(void) #if defined(PNG_READ_SUPPORTED) && defined(PNG_ASSEMBLER_CODE_SUPPORTED) -#if !defined(PNG_1_0_X) -/* this function was added to libpng 1.2.0 */ +#ifndef PNG_1_0_X +/* This function was added to libpng 1.2.0 */ int PNGAPI png_mmx_support(void) { - /* obsolete, to be removed from libpng-1.4.0 */ + /* Obsolete, to be removed from libpng-1.4.0 */ return -1; } #endif /* PNG_1_0_X */ @@ -790,9 +834,267 @@ png_mmx_support(void) png_size_t PNGAPI png_convert_size(size_t size) { - if (size > (png_size_t)-1) - PNG_ABORT(); /* We haven't got access to png_ptr, so no png_error() */ - return ((png_size_t)size); + if (size > (png_size_t)-1) + PNG_ABORT(); /* We haven't got access to png_ptr, so no png_error() */ + return ((png_size_t)size); } #endif /* PNG_SIZE_T */ + +/* Added at libpng version 1.2.34 and 1.4.0 (moved from pngset.c) */ +#ifdef PNG_cHRM_SUPPORTED +#ifdef PNG_CHECK_cHRM_SUPPORTED + +/* + * Multiply two 32-bit numbers, V1 and V2, using 32-bit + * arithmetic, to produce a 64 bit result in the HI/LO words. + * + * A B + * x C D + * ------ + * AD || BD + * AC || CB || 0 + * + * where A and B are the high and low 16-bit words of V1, + * C and D are the 16-bit words of V2, AD is the product of + * A and D, and X || Y is (X << 16) + Y. +*/ + +void /* PRIVATE */ +png_64bit_product (long v1, long v2, unsigned long *hi_product, + unsigned long *lo_product) +{ + int a, b, c, d; + long lo, hi, x, y; + + a = (v1 >> 16) & 0xffff; + b = v1 & 0xffff; + c = (v2 >> 16) & 0xffff; + d = v2 & 0xffff; + + lo = b * d; /* BD */ + x = a * d + c * b; /* AD + CB */ + y = ((lo >> 16) & 0xffff) + x; + + lo = (lo & 0xffff) | ((y & 0xffff) << 16); + hi = (y >> 16) & 0xffff; + + hi += a * c; /* AC */ + + *hi_product = (unsigned long)hi; + *lo_product = (unsigned long)lo; +} + +int /* PRIVATE */ +png_check_cHRM_fixed(png_structp png_ptr, + png_fixed_point white_x, png_fixed_point white_y, png_fixed_point red_x, + png_fixed_point red_y, png_fixed_point green_x, png_fixed_point green_y, + png_fixed_point blue_x, png_fixed_point blue_y) +{ + int ret = 1; + unsigned long xy_hi,xy_lo,yx_hi,yx_lo; + + png_debug(1, "in function png_check_cHRM_fixed"); + + if (png_ptr == NULL) + return 0; + + if (white_x < 0 || white_y <= 0 || + red_x < 0 || red_y < 0 || + green_x < 0 || green_y < 0 || + blue_x < 0 || blue_y < 0) + { + png_warning(png_ptr, + "Ignoring attempt to set negative chromaticity value"); + ret = 0; + } + if (white_x > (png_fixed_point) PNG_UINT_31_MAX || + white_y > (png_fixed_point) PNG_UINT_31_MAX || + red_x > (png_fixed_point) PNG_UINT_31_MAX || + red_y > (png_fixed_point) PNG_UINT_31_MAX || + green_x > (png_fixed_point) PNG_UINT_31_MAX || + green_y > (png_fixed_point) PNG_UINT_31_MAX || + blue_x > (png_fixed_point) PNG_UINT_31_MAX || + blue_y > (png_fixed_point) PNG_UINT_31_MAX ) + { + png_warning(png_ptr, + "Ignoring attempt to set chromaticity value exceeding 21474.83"); + ret = 0; + } + if (white_x > 100000L - white_y) + { + png_warning(png_ptr, "Invalid cHRM white point"); + ret = 0; + } + if (red_x > 100000L - red_y) + { + png_warning(png_ptr, "Invalid cHRM red point"); + ret = 0; + } + if (green_x > 100000L - green_y) + { + png_warning(png_ptr, "Invalid cHRM green point"); + ret = 0; + } + if (blue_x > 100000L - blue_y) + { + png_warning(png_ptr, "Invalid cHRM blue point"); + ret = 0; + } + + png_64bit_product(green_x - red_x, blue_y - red_y, &xy_hi, &xy_lo); + png_64bit_product(green_y - red_y, blue_x - red_x, &yx_hi, &yx_lo); + + if (xy_hi == yx_hi && xy_lo == yx_lo) + { + png_warning(png_ptr, + "Ignoring attempt to set cHRM RGB triangle with zero area"); + ret = 0; + } + + return ret; +} +#endif /* PNG_CHECK_cHRM_SUPPORTED */ +#endif /* PNG_cHRM_SUPPORTED */ + +void /* PRIVATE */ +png_check_IHDR(png_structp png_ptr, + png_uint_32 width, png_uint_32 height, int bit_depth, + int color_type, int interlace_type, int compression_type, + int filter_type) +{ + int error = 0; + + /* Check for width and height valid values */ + if (width == 0) + { + png_warning(png_ptr, "Image width is zero in IHDR"); + error = 1; + } + + if (height == 0) + { + png_warning(png_ptr, "Image height is zero in IHDR"); + error = 1; + } + +#ifdef PNG_SET_USER_LIMITS_SUPPORTED + if (width > png_ptr->user_width_max || width > PNG_USER_WIDTH_MAX) +#else + if (width > PNG_USER_WIDTH_MAX) +#endif + { + png_warning(png_ptr, "Image width exceeds user limit in IHDR"); + error = 1; + } + +#ifdef PNG_SET_USER_LIMITS_SUPPORTED + if (height > png_ptr->user_height_max || height > PNG_USER_HEIGHT_MAX) +#else + if (height > PNG_USER_HEIGHT_MAX) +#endif + { + png_warning(png_ptr, "Image height exceeds user limit in IHDR"); + error = 1; + } + + if (width > PNG_UINT_31_MAX) + { + png_warning(png_ptr, "Invalid image width in IHDR"); + error = 1; + } + + if ( height > PNG_UINT_31_MAX) + { + png_warning(png_ptr, "Invalid image height in IHDR"); + error = 1; + } + + if ( width > (PNG_UINT_32_MAX + >> 3) /* 8-byte RGBA pixels */ + - 64 /* bigrowbuf hack */ + - 1 /* filter byte */ + - 7*8 /* rounding of width to multiple of 8 pixels */ + - 8) /* extra max_pixel_depth pad */ + png_warning(png_ptr, "Width is too large for libpng to process pixels"); + + /* Check other values */ + if (bit_depth != 1 && bit_depth != 2 && bit_depth != 4 && + bit_depth != 8 && bit_depth != 16) + { + png_warning(png_ptr, "Invalid bit depth in IHDR"); + error = 1; + } + + if (color_type < 0 || color_type == 1 || + color_type == 5 || color_type > 6) + { + png_warning(png_ptr, "Invalid color type in IHDR"); + error = 1; + } + + if (((color_type == PNG_COLOR_TYPE_PALETTE) && bit_depth > 8) || + ((color_type == PNG_COLOR_TYPE_RGB || + color_type == PNG_COLOR_TYPE_GRAY_ALPHA || + color_type == PNG_COLOR_TYPE_RGB_ALPHA) && bit_depth < 8)) + { + png_warning(png_ptr, "Invalid color type/bit depth combination in IHDR"); + error = 1; + } + + if (interlace_type >= PNG_INTERLACE_LAST) + { + png_warning(png_ptr, "Unknown interlace method in IHDR"); + error = 1; + } + + if (compression_type != PNG_COMPRESSION_TYPE_BASE) + { + png_warning(png_ptr, "Unknown compression method in IHDR"); + error = 1; + } + +#ifdef PNG_MNG_FEATURES_SUPPORTED + /* Accept filter_method 64 (intrapixel differencing) only if + * 1. Libpng was compiled with PNG_MNG_FEATURES_SUPPORTED and + * 2. Libpng did not read a PNG signature (this filter_method is only + * used in PNG datastreams that are embedded in MNG datastreams) and + * 3. The application called png_permit_mng_features with a mask that + * included PNG_FLAG_MNG_FILTER_64 and + * 4. The filter_method is 64 and + * 5. The color_type is RGB or RGBA + */ + if ((png_ptr->mode & PNG_HAVE_PNG_SIGNATURE) && + png_ptr->mng_features_permitted) + png_warning(png_ptr, "MNG features are not allowed in a PNG datastream"); + + if (filter_type != PNG_FILTER_TYPE_BASE) + { + if (!((png_ptr->mng_features_permitted & PNG_FLAG_MNG_FILTER_64) && + (filter_type == PNG_INTRAPIXEL_DIFFERENCING) && + ((png_ptr->mode & PNG_HAVE_PNG_SIGNATURE) == 0) && + (color_type == PNG_COLOR_TYPE_RGB || + color_type == PNG_COLOR_TYPE_RGB_ALPHA))) + { + png_warning(png_ptr, "Unknown filter method in IHDR"); + error = 1; + } + + if (png_ptr->mode & PNG_HAVE_PNG_SIGNATURE) + { + png_warning(png_ptr, "Invalid filter method in IHDR"); + error = 1; + } + } + +#else + if (filter_type != PNG_FILTER_TYPE_BASE) + { + png_warning(png_ptr, "Unknown filter method in IHDR"); + error = 1; + } +#endif + + if (error == 1) + png_error(png_ptr, "Invalid IHDR data"); +} #endif /* defined(PNG_READ_SUPPORTED) || defined(PNG_WRITE_SUPPORTED) */ diff --git a/graf2d/asimage/src/libAfterImage/libpng/png.h b/graf2d/asimage/src/libAfterImage/libpng/png.h index f958be6cc5493..8cb8282373490 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/png.h +++ b/graf2d/asimage/src/libAfterImage/libpng/png.h @@ -1,15 +1,16 @@ - /* png.h - header file for PNG reference library * - * libpng version 1.2.23 - November 6, 2007 - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * libpng version 1.2.50 - July 10, 2012 + * Copyright (c) 1998-2012 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) * + * This code is released under the libpng license (See LICENSE, below) + * * Authors and maintainers: * libpng versions 0.71, May 1995, through 0.88, January 1996: Guy Schalnat * libpng versions 0.89c, June 1996, through 0.96, May 1997: Andreas Dilger - * libpng versions 0.97, January 1998, through 1.2.23 - November 6, 2007: Glenn + * libpng versions 0.97, January 1998, through 1.2.50 - July 10, 2012: Glenn * See also "Contributing Authors", below. * * Note about libpng version numbers: @@ -172,6 +173,117 @@ * 1.2.23beta01-05 13 10223 12.so.0.23[.0] * 1.2.23rc01 13 10223 12.so.0.23[.0] * 1.2.23 13 10223 12.so.0.23[.0] + * 1.2.24beta01-02 13 10224 12.so.0.24[.0] + * 1.2.24rc01 13 10224 12.so.0.24[.0] + * 1.2.24 13 10224 12.so.0.24[.0] + * 1.2.25beta01-06 13 10225 12.so.0.25[.0] + * 1.2.25rc01-02 13 10225 12.so.0.25[.0] + * 1.0.31 10 10031 10.so.0.31[.0] + * 1.2.25 13 10225 12.so.0.25[.0] + * 1.2.26beta01-06 13 10226 12.so.0.26[.0] + * 1.2.26rc01 13 10226 12.so.0.26[.0] + * 1.2.26 13 10226 12.so.0.26[.0] + * 1.0.32 10 10032 10.so.0.32[.0] + * 1.2.27beta01-06 13 10227 12.so.0.27[.0] + * 1.2.27rc01 13 10227 12.so.0.27[.0] + * 1.0.33 10 10033 10.so.0.33[.0] + * 1.2.27 13 10227 12.so.0.27[.0] + * 1.0.34 10 10034 10.so.0.34[.0] + * 1.2.28 13 10228 12.so.0.28[.0] + * 1.2.29beta01-03 13 10229 12.so.0.29[.0] + * 1.2.29rc01 13 10229 12.so.0.29[.0] + * 1.0.35 10 10035 10.so.0.35[.0] + * 1.2.29 13 10229 12.so.0.29[.0] + * 1.0.37 10 10037 10.so.0.37[.0] + * 1.2.30beta01-04 13 10230 12.so.0.30[.0] + * 1.0.38rc01-08 10 10038 10.so.0.38[.0] + * 1.2.30rc01-08 13 10230 12.so.0.30[.0] + * 1.0.38 10 10038 10.so.0.38[.0] + * 1.2.30 13 10230 12.so.0.30[.0] + * 1.0.39rc01-03 10 10039 10.so.0.39[.0] + * 1.2.31rc01-03 13 10231 12.so.0.31[.0] + * 1.0.39 10 10039 10.so.0.39[.0] + * 1.2.31 13 10231 12.so.0.31[.0] + * 1.2.32beta01-02 13 10232 12.so.0.32[.0] + * 1.0.40rc01 10 10040 10.so.0.40[.0] + * 1.2.32rc01 13 10232 12.so.0.32[.0] + * 1.0.40 10 10040 10.so.0.40[.0] + * 1.2.32 13 10232 12.so.0.32[.0] + * 1.2.33beta01-02 13 10233 12.so.0.33[.0] + * 1.2.33rc01-02 13 10233 12.so.0.33[.0] + * 1.0.41rc01 10 10041 10.so.0.41[.0] + * 1.2.33 13 10233 12.so.0.33[.0] + * 1.0.41 10 10041 10.so.0.41[.0] + * 1.2.34beta01-07 13 10234 12.so.0.34[.0] + * 1.0.42rc01 10 10042 10.so.0.42[.0] + * 1.2.34rc01 13 10234 12.so.0.34[.0] + * 1.0.42 10 10042 10.so.0.42[.0] + * 1.2.34 13 10234 12.so.0.34[.0] + * 1.2.35beta01-03 13 10235 12.so.0.35[.0] + * 1.0.43rc01-02 10 10043 10.so.0.43[.0] + * 1.2.35rc01-02 13 10235 12.so.0.35[.0] + * 1.0.43 10 10043 10.so.0.43[.0] + * 1.2.35 13 10235 12.so.0.35[.0] + * 1.2.36beta01-05 13 10236 12.so.0.36[.0] + * 1.2.36rc01 13 10236 12.so.0.36[.0] + * 1.0.44 10 10044 10.so.0.44[.0] + * 1.2.36 13 10236 12.so.0.36[.0] + * 1.2.37beta01-03 13 10237 12.so.0.37[.0] + * 1.2.37rc01 13 10237 12.so.0.37[.0] + * 1.2.37 13 10237 12.so.0.37[.0] + * 1.0.45 10 10045 12.so.0.45[.0] + * 1.0.46 10 10046 10.so.0.46[.0] + * 1.2.38beta01 13 10238 12.so.0.38[.0] + * 1.2.38rc01-03 13 10238 12.so.0.38[.0] + * 1.0.47 10 10047 10.so.0.47[.0] + * 1.2.38 13 10238 12.so.0.38[.0] + * 1.2.39beta01-05 13 10239 12.so.0.39[.0] + * 1.2.39rc01 13 10239 12.so.0.39[.0] + * 1.0.48 10 10048 10.so.0.48[.0] + * 1.2.39 13 10239 12.so.0.39[.0] + * 1.2.40beta01 13 10240 12.so.0.40[.0] + * 1.2.40rc01 13 10240 12.so.0.40[.0] + * 1.0.49 10 10049 10.so.0.49[.0] + * 1.2.40 13 10240 12.so.0.40[.0] + * 1.2.41beta01-18 13 10241 12.so.0.41[.0] + * 1.0.51rc01 10 10051 10.so.0.51[.0] + * 1.2.41rc01-03 13 10241 12.so.0.41[.0] + * 1.0.51 10 10051 10.so.0.51[.0] + * 1.2.41 13 10241 12.so.0.41[.0] + * 1.2.42beta01-02 13 10242 12.so.0.42[.0] + * 1.2.42rc01-05 13 10242 12.so.0.42[.0] + * 1.0.52 10 10052 10.so.0.52[.0] + * 1.2.42 13 10242 12.so.0.42[.0] + * 1.2.43beta01-05 13 10243 12.so.0.43[.0] + * 1.0.53rc01-02 10 10053 10.so.0.53[.0] + * 1.2.43rc01-02 13 10243 12.so.0.43[.0] + * 1.0.53 10 10053 10.so.0.53[.0] + * 1.2.43 13 10243 12.so.0.43[.0] + * 1.2.44beta01-03 13 10244 12.so.0.44[.0] + * 1.2.44rc01-03 13 10244 12.so.0.44[.0] + * 1.2.44 13 10244 12.so.0.44[.0] + * 1.2.45beta01-03 13 10245 12.so.0.45[.0] + * 1.0.55rc01 10 10055 10.so.0.55[.0] + * 1.2.45rc01 13 10245 12.so.0.45[.0] + * 1.0.55 10 10055 10.so.0.55[.0] + * 1.2.45 13 10245 12.so.0.45[.0] + * 1.2.46rc01-02 13 10246 12.so.0.46[.0] + * 1.0.56 10 10056 10.so.0.56[.0] + * 1.2.46 13 10246 12.so.0.46[.0] + * 1.2.47beta01 13 10247 12.so.0.47[.0] + * 1.2.47rc01 13 10247 12.so.0.47[.0] + * 1.0.57rc01 10 10057 10.so.0.57[.0] + * 1.2.47 13 10247 12.so.0.47[.0] + * 1.0.57 10 10057 10.so.0.57[.0] + * 1.2.48beta01 13 10248 12.so.0.48[.0] + * 1.2.48rc01-02 13 10248 12.so.0.48[.0] + * 1.0.58 10 10058 10.so.0.58[.0] + * 1.2.48 13 10248 12.so.0.48[.0] + * 1.2.49rc01 13 10249 12.so.0.49[.0] + * 1.0.59 10 10059 10.so.0.59[.0] + * 1.2.49 13 10249 12.so.0.49[.0] + * 1.0.60 10 10060 10.so.0.60[.0] + * 1.2.50 13 10250 12.so.0.50[.0] * * Henceforth the source version will match the shared-library major * and minor numbers; the shared-library major version number will be @@ -181,7 +293,7 @@ * to the source version x.y.z (leading zeros in y and z). Beta versions * were given the previous public release number plus a letter, until * version 1.0.6j; from then on they were given the upcoming public - * release number plus "betaNN" or "rcN". + * release number plus "betaNN" or "rcNN". * * Binary incompatibility exists only when applications make direct access * to the info_ptr or png_ptr members through png.h, and the compiled @@ -201,8 +313,10 @@ * If you modify libpng you may insert additional notices immediately following * this sentence. * - * libpng versions 1.2.6, August 15, 2004, through 1.2.23, November 6, 2007, are - * Copyright (c) 2004, 2006-2007 Glenn Randers-Pehrson, and are + * This code is released under the libpng license. + * + * libpng versions 1.2.6, August 15, 2004, through 1.2.50, July 10, 2012, are + * Copyright (c) 2004, 2006-2011 Glenn Randers-Pehrson, and are * distributed according to the same disclaimer and license as libpng-1.2.5 * with the following individual added to the list of Contributing Authors: * @@ -313,13 +427,13 @@ * Y2K compliance in libpng: * ========================= * - * November 6, 2007 + * July 10, 2012 * * Since the PNG Development group is an ad-hoc body, we can't make * an official declaration. * * This is your unofficial assurance that libpng from version 0.71 and - * upward through 1.2.23 are Y2K compliant. It is my belief that earlier + * upward through 1.2.50 are Y2K compliant. It is my belief that earlier * versions were also Y2K compliant. * * Libpng only has three year fields. One is a 2-byte unsigned integer @@ -375,9 +489,9 @@ */ /* Version information for png.h - this should match the version in png.c */ -#define PNG_LIBPNG_VER_STRING "1.2.23" +#define PNG_LIBPNG_VER_STRING "1.2.50" #define PNG_HEADER_VERSION_STRING \ - " libpng version 1.2.23 - November 6, 2007\n" + " libpng version 1.2.50 - July 10, 2012\n" #define PNG_LIBPNG_VER_SONUM 0 #define PNG_LIBPNG_VER_DLLNUM 13 @@ -385,9 +499,10 @@ /* These should match the first 3 components of PNG_LIBPNG_VER_STRING: */ #define PNG_LIBPNG_VER_MAJOR 1 #define PNG_LIBPNG_VER_MINOR 2 -#define PNG_LIBPNG_VER_RELEASE 23 +#define PNG_LIBPNG_VER_RELEASE 50 /* This should match the numeric part of the final component of - * PNG_LIBPNG_VER_STRING, omitting any leading zero: */ + * PNG_LIBPNG_VER_STRING, omitting any leading zero: + */ #define PNG_LIBPNG_VER_BUILD 0 @@ -397,7 +512,7 @@ #define PNG_LIBPNG_BUILD_RC 3 #define PNG_LIBPNG_BUILD_STABLE 4 #define PNG_LIBPNG_BUILD_RELEASE_STATUS_MASK 7 - + /* Release-Specific Flags */ #define PNG_LIBPNG_BUILD_PATCH 8 /* Can be OR'ed with PNG_LIBPNG_BUILD_STABLE only */ @@ -412,11 +527,12 @@ * We must not include leading zeros. * Versions 0.7 through 1.0.0 were in the range 0 to 100 here (only * version 1.0.0 was mis-numbered 100 instead of 10000). From - * version 1.0.1 it's xxyyzz, where x=major, y=minor, z=release */ -#define PNG_LIBPNG_VER 10223 /* 1.2.23 */ + * version 1.0.1 it's xxyyzz, where x=major, y=minor, z=release + */ +#define PNG_LIBPNG_VER 10250 /* 1.2.50 */ #ifndef PNG_VERSION_INFO_ONLY -/* include the compression library's header */ +/* Include the compression library's header */ # ifdef _WIN32 # include "..\zlib\zlib.h" # else @@ -424,7 +540,7 @@ # endif #endif -/* include all user configurable info, including optional assembler routines */ +/* Include all user configurable info, including optional assembler routines */ #include "pngconf.h" /* @@ -432,19 +548,19 @@ /* Ref MSDN: Private as priority over Special * VS_FF_PRIVATEBUILD File *was not* built using standard release * procedures. If this value is given, the StringFileInfo block must - * contain a PrivateBuild string. + * contain a PrivateBuild string. * * VS_FF_SPECIALBUILD File *was* built by the original company using * standard release procedures but is a variation of the standard * file of the same version number. If this value is given, the - * StringFileInfo block must contain a SpecialBuild string. + * StringFileInfo block must contain a SpecialBuild string. */ -#if defined(PNG_USER_PRIVATEBUILD) +#ifdef PNG_USER_PRIVATEBUILD # define PNG_LIBPNG_BUILD_TYPE \ (PNG_LIBPNG_BUILD_BASE_TYPE | PNG_LIBPNG_BUILD_PRIVATE) #else -# if defined(PNG_LIBPNG_SPECIALBUILD) +# ifdef PNG_LIBPNG_SPECIALBUILD # define PNG_LIBPNG_BUILD_TYPE \ (PNG_LIBPNG_BUILD_BASE_TYPE | PNG_LIBPNG_BUILD_SPECIAL) # else @@ -499,14 +615,14 @@ extern "C" { #define png_write_status_ptr_NULL NULL #endif -/* variables declared in png.c - only it needs to define PNG_NO_EXTERN */ +/* Variables declared in png.c - only it needs to define PNG_NO_EXTERN */ #if !defined(PNG_NO_EXTERN) || defined(PNG_ALWAYS_EXTERN) /* Version information for C files, stored in png.c. This had better match * the version above. */ #ifdef PNG_USE_GLOBAL_ARRAYS PNG_EXPORT_VAR (PNG_CONST char) png_libpng_ver[18]; - /* need room for 99.99.99beta99z */ + /* Need room for 99.99.99beta99z */ #else #define png_libpng_ver png_get_header_ver(NULL) #endif @@ -625,7 +741,8 @@ typedef png_text FAR * FAR * png_textpp; #endif /* Supported compression types for text in PNG files (tEXt, and zTXt). - * The values of the PNG_TEXT_COMPRESSION_ defines should NOT be changed. */ + * The values of the PNG_TEXT_COMPRESSION_ defines should NOT be changed. + */ #define PNG_TEXT_COMPRESSION_NONE_WR -3 #define PNG_TEXT_COMPRESSION_zTXt_WR -2 #define PNG_TEXT_COMPRESSION_NONE -1 @@ -652,7 +769,8 @@ typedef struct png_time_struct typedef png_time FAR * png_timep; typedef png_time FAR * FAR * png_timepp; -#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) +#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) || \ + defined(PNG_HANDLE_AS_UNKNOWN_SUPPORTED) /* png_unknown_chunk is a structure to hold queued chunks for which there is * no specific support. The idea is that we can use this to queue * up private chunks for output even though the library doesn't actually @@ -714,26 +832,26 @@ typedef png_unknown_chunk FAR * FAR * png_unknown_chunkpp; */ typedef struct png_info_struct { - /* the following are necessary for every PNG file */ - png_uint_32 width; /* width of image in pixels (from IHDR) */ - png_uint_32 height; /* height of image in pixels (from IHDR) */ - png_uint_32 valid; /* valid chunk data (see PNG_INFO_ below) */ - png_uint_32 rowbytes; /* bytes needed to hold an untransformed row */ - png_colorp palette; /* array of color values (valid & PNG_INFO_PLTE) */ - png_uint_16 num_palette; /* number of color entries in "palette" (PLTE) */ - png_uint_16 num_trans; /* number of transparent palette color (tRNS) */ - png_byte bit_depth; /* 1, 2, 4, 8, or 16 bits/channel (from IHDR) */ - png_byte color_type; /* see PNG_COLOR_TYPE_ below (from IHDR) */ + /* The following are necessary for every PNG file */ + png_uint_32 width PNG_DEPSTRUCT; /* width of image in pixels (from IHDR) */ + png_uint_32 height PNG_DEPSTRUCT; /* height of image in pixels (from IHDR) */ + png_uint_32 valid PNG_DEPSTRUCT; /* valid chunk data (see PNG_INFO_ below) */ + png_uint_32 rowbytes PNG_DEPSTRUCT; /* bytes needed to hold an untransformed row */ + png_colorp palette PNG_DEPSTRUCT; /* array of color values (valid & PNG_INFO_PLTE) */ + png_uint_16 num_palette PNG_DEPSTRUCT; /* number of color entries in "palette" (PLTE) */ + png_uint_16 num_trans PNG_DEPSTRUCT; /* number of transparent palette color (tRNS) */ + png_byte bit_depth PNG_DEPSTRUCT; /* 1, 2, 4, 8, or 16 bits/channel (from IHDR) */ + png_byte color_type PNG_DEPSTRUCT; /* see PNG_COLOR_TYPE_ below (from IHDR) */ /* The following three should have been named *_method not *_type */ - png_byte compression_type; /* must be PNG_COMPRESSION_TYPE_BASE (IHDR) */ - png_byte filter_type; /* must be PNG_FILTER_TYPE_BASE (from IHDR) */ - png_byte interlace_type; /* One of PNG_INTERLACE_NONE, PNG_INTERLACE_ADAM7 */ + png_byte compression_type PNG_DEPSTRUCT; /* must be PNG_COMPRESSION_TYPE_BASE (IHDR) */ + png_byte filter_type PNG_DEPSTRUCT; /* must be PNG_FILTER_TYPE_BASE (from IHDR) */ + png_byte interlace_type PNG_DEPSTRUCT; /* One of PNG_INTERLACE_NONE, PNG_INTERLACE_ADAM7 */ /* The following is informational only on read, and not used on writes. */ - png_byte channels; /* number of data channels per pixel (1, 2, 3, 4) */ - png_byte pixel_depth; /* number of bits per pixel */ - png_byte spare_byte; /* to align the data, and for future use */ - png_byte signature[8]; /* magic bytes read by libpng from start of file */ + png_byte channels PNG_DEPSTRUCT; /* number of data channels per pixel (1, 2, 3, 4) */ + png_byte pixel_depth PNG_DEPSTRUCT; /* number of bits per pixel */ + png_byte spare_byte PNG_DEPSTRUCT; /* to align the data, and for future use */ + png_byte signature[8] PNG_DEPSTRUCT; /* magic bytes read by libpng from start of file */ /* The rest of the data is optional. If you are reading, check the * valid field to see if the information in these are valid. If you @@ -746,16 +864,16 @@ typedef struct png_info_struct * on which the image was created, normally in the range [1.0, 2.5]. * Data is valid if (valid & PNG_INFO_gAMA) is non-zero. */ - float gamma; /* gamma value of image, if (valid & PNG_INFO_gAMA) */ + float gamma PNG_DEPSTRUCT; /* gamma value of image, if (valid & PNG_INFO_gAMA) */ #endif -#if defined(PNG_sRGB_SUPPORTED) +#ifdef PNG_sRGB_SUPPORTED /* GR-P, 0.96a */ /* Data valid if (valid & PNG_INFO_sRGB) non-zero. */ - png_byte srgb_intent; /* sRGB rendering intent [0, 1, 2, or 3] */ + png_byte srgb_intent PNG_DEPSTRUCT; /* sRGB rendering intent [0, 1, 2, or 3] */ #endif -#if defined(PNG_TEXT_SUPPORTED) +#ifdef PNG_TEXT_SUPPORTED /* The tEXt, and zTXt chunks contain human-readable textual data in * uncompressed, compressed, and optionally compressed forms, respectively. * The data in "text" is an array of pointers to uncompressed, @@ -764,26 +882,26 @@ typedef struct png_info_struct * unique, and the text string may be empty. Any number of text chunks may * be in an image. */ - int num_text; /* number of comments read/to write */ - int max_text; /* current size of text array */ - png_textp text; /* array of comments read/to write */ + int num_text PNG_DEPSTRUCT; /* number of comments read/to write */ + int max_text PNG_DEPSTRUCT; /* current size of text array */ + png_textp text PNG_DEPSTRUCT; /* array of comments read/to write */ #endif /* PNG_TEXT_SUPPORTED */ -#if defined(PNG_tIME_SUPPORTED) +#ifdef PNG_tIME_SUPPORTED /* The tIME chunk holds the last time the displayed image data was * modified. See the png_time struct for the contents of this struct. */ - png_time mod_time; + png_time mod_time PNG_DEPSTRUCT; #endif -#if defined(PNG_sBIT_SUPPORTED) +#ifdef PNG_sBIT_SUPPORTED /* The sBIT chunk specifies the number of significant high-order bits * in the pixel data. Values are in the range [1, bit_depth], and are * only specified for the channels in the pixel data. The contents of * the low-order bits is not specified. Data is valid if * (valid & PNG_INFO_sBIT) is non-zero. */ - png_color_8 sig_bit; /* significant bits in color channels */ + png_color_8 sig_bit PNG_DEPSTRUCT; /* significant bits in color channels */ #endif #if defined(PNG_tRNS_SUPPORTED) || defined(PNG_READ_EXPAND_SUPPORTED) || \ @@ -797,8 +915,8 @@ defined(PNG_READ_BACKGROUND_SUPPORTED) * single color specified that should be treated as fully transparent. * Data is valid if (valid & PNG_INFO_tRNS) is non-zero. */ - png_bytep trans; /* transparent values for paletted image */ - png_color_16 trans_values; /* transparent color for non-palette image */ + png_bytep trans PNG_DEPSTRUCT; /* transparent values for paletted image */ + png_color_16 trans_values PNG_DEPSTRUCT; /* transparent color for non-palette image */ #endif #if defined(PNG_bKGD_SUPPORTED) || defined(PNG_READ_BACKGROUND_SUPPORTED) @@ -808,38 +926,38 @@ defined(PNG_READ_BACKGROUND_SUPPORTED) * in "background" are normally in the same color space/depth as the * pixel data. Data is valid if (valid & PNG_INFO_bKGD) is non-zero. */ - png_color_16 background; + png_color_16 background PNG_DEPSTRUCT; #endif -#if defined(PNG_oFFs_SUPPORTED) +#ifdef PNG_oFFs_SUPPORTED /* The oFFs chunk gives the offset in "offset_unit_type" units rightwards * and downwards from the top-left corner of the display, page, or other * application-specific co-ordinate space. See the PNG_OFFSET_ defines * below for the unit types. Valid if (valid & PNG_INFO_oFFs) non-zero. */ - png_int_32 x_offset; /* x offset on page */ - png_int_32 y_offset; /* y offset on page */ - png_byte offset_unit_type; /* offset units type */ + png_int_32 x_offset PNG_DEPSTRUCT; /* x offset on page */ + png_int_32 y_offset PNG_DEPSTRUCT; /* y offset on page */ + png_byte offset_unit_type PNG_DEPSTRUCT; /* offset units type */ #endif -#if defined(PNG_pHYs_SUPPORTED) +#ifdef PNG_pHYs_SUPPORTED /* The pHYs chunk gives the physical pixel density of the image for * display or printing in "phys_unit_type" units (see PNG_RESOLUTION_ * defines below). Data is valid if (valid & PNG_INFO_pHYs) is non-zero. */ - png_uint_32 x_pixels_per_unit; /* horizontal pixel density */ - png_uint_32 y_pixels_per_unit; /* vertical pixel density */ - png_byte phys_unit_type; /* resolution type (see PNG_RESOLUTION_ below) */ + png_uint_32 x_pixels_per_unit PNG_DEPSTRUCT; /* horizontal pixel density */ + png_uint_32 y_pixels_per_unit PNG_DEPSTRUCT; /* vertical pixel density */ + png_byte phys_unit_type PNG_DEPSTRUCT; /* resolution type (see PNG_RESOLUTION_ below) */ #endif -#if defined(PNG_hIST_SUPPORTED) +#ifdef PNG_hIST_SUPPORTED /* The hIST chunk contains the relative frequency or importance of the * various palette entries, so that a viewer can intelligently select a * reduced-color palette, if required. Data is an array of "num_palette" * values in the range [0,65535]. Data valid if (valid & PNG_INFO_hIST) * is non-zero. */ - png_uint_16p hist; + png_uint_16p hist PNG_DEPSTRUCT; #endif #ifdef PNG_cHRM_SUPPORTED @@ -850,18 +968,18 @@ defined(PNG_READ_BACKGROUND_SUPPORTED) * [0.0, 0.8]. Data valid if (valid & PNG_INFO_cHRM) non-zero. */ #ifdef PNG_FLOATING_POINT_SUPPORTED - float x_white; - float y_white; - float x_red; - float y_red; - float x_green; - float y_green; - float x_blue; - float y_blue; + float x_white PNG_DEPSTRUCT; + float y_white PNG_DEPSTRUCT; + float x_red PNG_DEPSTRUCT; + float y_red PNG_DEPSTRUCT; + float x_green PNG_DEPSTRUCT; + float y_green PNG_DEPSTRUCT; + float x_blue PNG_DEPSTRUCT; + float y_blue PNG_DEPSTRUCT; #endif #endif -#if defined(PNG_pCAL_SUPPORTED) +#ifdef PNG_pCAL_SUPPORTED /* The pCAL chunk describes a transformation between the stored pixel * values and original physical data values used to create the image. * The integer range [0, 2^bit_depth - 1] maps to the floating-point @@ -873,42 +991,43 @@ defined(PNG_READ_BACKGROUND_SUPPORTED) * implemented, and for a description of the ASCII parameter strings. * Data values are valid if (valid & PNG_INFO_pCAL) non-zero. */ - png_charp pcal_purpose; /* pCAL chunk description string */ - png_int_32 pcal_X0; /* minimum value */ - png_int_32 pcal_X1; /* maximum value */ - png_charp pcal_units; /* Latin-1 string giving physical units */ - png_charpp pcal_params; /* ASCII strings containing parameter values */ - png_byte pcal_type; /* equation type (see PNG_EQUATION_ below) */ - png_byte pcal_nparams; /* number of parameters given in pcal_params */ + png_charp pcal_purpose PNG_DEPSTRUCT; /* pCAL chunk description string */ + png_int_32 pcal_X0 PNG_DEPSTRUCT; /* minimum value */ + png_int_32 pcal_X1 PNG_DEPSTRUCT; /* maximum value */ + png_charp pcal_units PNG_DEPSTRUCT; /* Latin-1 string giving physical units */ + png_charpp pcal_params PNG_DEPSTRUCT; /* ASCII strings containing parameter values */ + png_byte pcal_type PNG_DEPSTRUCT; /* equation type (see PNG_EQUATION_ below) */ + png_byte pcal_nparams PNG_DEPSTRUCT; /* number of parameters given in pcal_params */ #endif /* New members added in libpng-1.0.6 */ #ifdef PNG_FREE_ME_SUPPORTED - png_uint_32 free_me; /* flags items libpng is responsible for freeing */ + png_uint_32 free_me PNG_DEPSTRUCT; /* flags items libpng is responsible for freeing */ #endif -#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) - /* storage for unknown chunks that the library doesn't recognize. */ - png_unknown_chunkp unknown_chunks; - png_size_t unknown_chunks_num; +#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) || \ + defined(PNG_HANDLE_AS_UNKNOWN_SUPPORTED) + /* Storage for unknown chunks that the library doesn't recognize. */ + png_unknown_chunkp unknown_chunks PNG_DEPSTRUCT; + png_size_t unknown_chunks_num PNG_DEPSTRUCT; #endif -#if defined(PNG_iCCP_SUPPORTED) +#ifdef PNG_iCCP_SUPPORTED /* iCCP chunk data. */ - png_charp iccp_name; /* profile name */ - png_charp iccp_profile; /* International Color Consortium profile data */ + png_charp iccp_name PNG_DEPSTRUCT; /* profile name */ + png_charp iccp_profile PNG_DEPSTRUCT; /* International Color Consortium profile data */ /* Note to maintainer: should be png_bytep */ - png_uint_32 iccp_proflen; /* ICC profile data length */ - png_byte iccp_compression; /* Always zero */ + png_uint_32 iccp_proflen PNG_DEPSTRUCT; /* ICC profile data length */ + png_byte iccp_compression PNG_DEPSTRUCT; /* Always zero */ #endif -#if defined(PNG_sPLT_SUPPORTED) - /* data on sPLT chunks (there may be more than one). */ - png_sPLT_tp splt_palettes; - png_uint_32 splt_palettes_num; +#ifdef PNG_sPLT_SUPPORTED + /* Data on sPLT chunks (there may be more than one). */ + png_sPLT_tp splt_palettes PNG_DEPSTRUCT; + png_uint_32 splt_palettes_num PNG_DEPSTRUCT; #endif -#if defined(PNG_sCAL_SUPPORTED) +#ifdef PNG_sCAL_SUPPORTED /* The sCAL chunk describes the actual physical dimensions of the * subject matter of the graphic. The chunk contains a unit specification * a byte value, and two ASCII strings representing floating-point @@ -916,36 +1035,36 @@ defined(PNG_READ_BACKGROUND_SUPPORTED) * in the image. This external representation is converted to double * here. Data values are valid if (valid & PNG_INFO_sCAL) is non-zero. */ - png_byte scal_unit; /* unit of physical scale */ + png_byte scal_unit PNG_DEPSTRUCT; /* unit of physical scale */ #ifdef PNG_FLOATING_POINT_SUPPORTED - double scal_pixel_width; /* width of one pixel */ - double scal_pixel_height; /* height of one pixel */ + double scal_pixel_width PNG_DEPSTRUCT; /* width of one pixel */ + double scal_pixel_height PNG_DEPSTRUCT; /* height of one pixel */ #endif #ifdef PNG_FIXED_POINT_SUPPORTED - png_charp scal_s_width; /* string containing height */ - png_charp scal_s_height; /* string containing width */ + png_charp scal_s_width PNG_DEPSTRUCT; /* string containing height */ + png_charp scal_s_height PNG_DEPSTRUCT; /* string containing width */ #endif #endif -#if defined(PNG_INFO_IMAGE_SUPPORTED) +#ifdef PNG_INFO_IMAGE_SUPPORTED /* Memory has been allocated if (valid & PNG_ALLOCATED_INFO_ROWS) non-zero */ /* Data valid if (valid & PNG_INFO_IDAT) non-zero */ - png_bytepp row_pointers; /* the image bits */ + png_bytepp row_pointers PNG_DEPSTRUCT; /* the image bits */ #endif #if defined(PNG_FIXED_POINT_SUPPORTED) && defined(PNG_gAMA_SUPPORTED) - png_fixed_point int_gamma; /* gamma of image, if (valid & PNG_INFO_gAMA) */ + png_fixed_point int_gamma PNG_DEPSTRUCT; /* gamma of image, if (valid & PNG_INFO_gAMA) */ #endif #if defined(PNG_cHRM_SUPPORTED) && defined(PNG_FIXED_POINT_SUPPORTED) - png_fixed_point int_x_white; - png_fixed_point int_y_white; - png_fixed_point int_x_red; - png_fixed_point int_y_red; - png_fixed_point int_x_green; - png_fixed_point int_y_green; - png_fixed_point int_x_blue; - png_fixed_point int_y_blue; + png_fixed_point int_x_white PNG_DEPSTRUCT; + png_fixed_point int_y_white PNG_DEPSTRUCT; + png_fixed_point int_x_red PNG_DEPSTRUCT; + png_fixed_point int_y_red PNG_DEPSTRUCT; + png_fixed_point int_x_green PNG_DEPSTRUCT; + png_fixed_point int_y_green PNG_DEPSTRUCT; + png_fixed_point int_x_blue PNG_DEPSTRUCT; + png_fixed_point int_y_blue PNG_DEPSTRUCT; #endif } png_info; @@ -1098,10 +1217,10 @@ typedef void (PNGAPI *png_user_transform_ptr) PNGARG((png_structp, png_row_infop, png_bytep)); #endif -#if defined(PNG_USER_CHUNKS_SUPPORTED) +#ifdef PNG_USER_CHUNKS_SUPPORTED typedef int (PNGAPI *png_user_chunk_ptr) PNGARG((png_structp, png_unknown_chunkp)); #endif -#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) +#ifdef PNG_UNKNOWN_CHUNKS_SUPPORTED typedef void (PNGAPI *png_unknown_chunk_ptr) PNGARG((png_structp)); #endif @@ -1118,7 +1237,12 @@ typedef void (PNGAPI *png_unknown_chunk_ptr) PNGARG((png_structp)); #define PNG_TRANSFORM_SWAP_ALPHA 0x0100 /* read and write */ #define PNG_TRANSFORM_SWAP_ENDIAN 0x0200 /* read and write */ #define PNG_TRANSFORM_INVERT_ALPHA 0x0400 /* read and write */ -#define PNG_TRANSFORM_STRIP_FILLER 0x0800 /* WRITE only */ +#define PNG_TRANSFORM_STRIP_FILLER 0x0800 /* write only, deprecated */ +/* Added to libpng-1.2.34 */ +#define PNG_TRANSFORM_STRIP_FILLER_BEFORE 0x0800 /* write only */ +#define PNG_TRANSFORM_STRIP_FILLER_AFTER 0x1000 /* write only */ +/* Added to libpng-1.2.41 */ +#define PNG_TRANSFORM_GRAY_TO_RGB 0x2000 /* read only */ /* Flags for MNG supported features */ #define PNG_FLAG_MNG_EMPTY_PLTE 0x01 @@ -1140,296 +1264,316 @@ struct png_struct_def #ifdef PNG_SETJMP_SUPPORTED jmp_buf jmpbuf; /* used in png_error */ #endif - png_error_ptr error_fn; /* function for printing errors and aborting */ - png_error_ptr warning_fn; /* function for printing warnings */ - png_voidp error_ptr; /* user supplied struct for error functions */ - png_rw_ptr write_data_fn; /* function for writing output data */ - png_rw_ptr read_data_fn; /* function for reading input data */ - png_voidp io_ptr; /* ptr to application struct for I/O functions */ + png_error_ptr error_fn PNG_DEPSTRUCT; /* function for printing errors and aborting */ + png_error_ptr warning_fn PNG_DEPSTRUCT; /* function for printing warnings */ + png_voidp error_ptr PNG_DEPSTRUCT; /* user supplied struct for error functions */ + png_rw_ptr write_data_fn PNG_DEPSTRUCT; /* function for writing output data */ + png_rw_ptr read_data_fn PNG_DEPSTRUCT; /* function for reading input data */ + png_voidp io_ptr PNG_DEPSTRUCT; /* ptr to application struct for I/O functions */ -#if defined(PNG_READ_USER_TRANSFORM_SUPPORTED) - png_user_transform_ptr read_user_transform_fn; /* user read transform */ +#ifdef PNG_READ_USER_TRANSFORM_SUPPORTED + png_user_transform_ptr read_user_transform_fn PNG_DEPSTRUCT; /* user read transform */ #endif -#if defined(PNG_WRITE_USER_TRANSFORM_SUPPORTED) - png_user_transform_ptr write_user_transform_fn; /* user write transform */ +#ifdef PNG_WRITE_USER_TRANSFORM_SUPPORTED + png_user_transform_ptr write_user_transform_fn PNG_DEPSTRUCT; /* user write transform */ #endif /* These were added in libpng-1.0.2 */ -#if defined(PNG_USER_TRANSFORM_PTR_SUPPORTED) +#ifdef PNG_USER_TRANSFORM_PTR_SUPPORTED #if defined(PNG_READ_USER_TRANSFORM_SUPPORTED) || \ defined(PNG_WRITE_USER_TRANSFORM_SUPPORTED) - png_voidp user_transform_ptr; /* user supplied struct for user transform */ - png_byte user_transform_depth; /* bit depth of user transformed pixels */ - png_byte user_transform_channels; /* channels in user transformed pixels */ -#endif -#endif - - png_uint_32 mode; /* tells us where we are in the PNG file */ - png_uint_32 flags; /* flags indicating various things to libpng */ - png_uint_32 transformations; /* which transformations to perform */ - - z_stream zstream; /* pointer to decompression structure (below) */ - png_bytep zbuf; /* buffer for zlib */ - png_size_t zbuf_size; /* size of zbuf */ - int zlib_level; /* holds zlib compression level */ - int zlib_method; /* holds zlib compression method */ - int zlib_window_bits; /* holds zlib compression window bits */ - int zlib_mem_level; /* holds zlib compression memory level */ - int zlib_strategy; /* holds zlib compression strategy */ - - png_uint_32 width; /* width of image in pixels */ - png_uint_32 height; /* height of image in pixels */ - png_uint_32 num_rows; /* number of rows in current pass */ - png_uint_32 usr_width; /* width of row at start of write */ - png_uint_32 rowbytes; /* size of row in bytes */ - png_uint_32 irowbytes; /* size of current interlaced row in bytes */ - png_uint_32 iwidth; /* width of current interlaced row in pixels */ - png_uint_32 row_number; /* current row in interlace pass */ - png_bytep prev_row; /* buffer to save previous (unfiltered) row */ - png_bytep row_buf; /* buffer to save current (unfiltered) row */ - png_bytep sub_row; /* buffer to save "sub" row when filtering */ - png_bytep up_row; /* buffer to save "up" row when filtering */ - png_bytep avg_row; /* buffer to save "avg" row when filtering */ - png_bytep paeth_row; /* buffer to save "Paeth" row when filtering */ - png_row_info row_info; /* used for transformation routines */ - - png_uint_32 idat_size; /* current IDAT size for read */ - png_uint_32 crc; /* current chunk CRC value */ - png_colorp palette; /* palette from the input file */ - png_uint_16 num_palette; /* number of color entries in palette */ - png_uint_16 num_trans; /* number of transparency values */ - png_byte chunk_name[5]; /* null-terminated name of current chunk */ - png_byte compression; /* file compression type (always 0) */ - png_byte filter; /* file filter type (always 0) */ - png_byte interlaced; /* PNG_INTERLACE_NONE, PNG_INTERLACE_ADAM7 */ - png_byte pass; /* current interlace pass (0 - 6) */ - png_byte do_filter; /* row filter flags (see PNG_FILTER_ below ) */ - png_byte color_type; /* color type of file */ - png_byte bit_depth; /* bit depth of file */ - png_byte usr_bit_depth; /* bit depth of users row */ - png_byte pixel_depth; /* number of bits per pixel */ - png_byte channels; /* number of channels in file */ - png_byte usr_channels; /* channels at start of write */ - png_byte sig_bytes; /* magic bytes read/written from start of file */ + png_voidp user_transform_ptr PNG_DEPSTRUCT; /* user supplied struct for user transform */ + png_byte user_transform_depth PNG_DEPSTRUCT; /* bit depth of user transformed pixels */ + png_byte user_transform_channels PNG_DEPSTRUCT; /* channels in user transformed pixels */ +#endif +#endif + + png_uint_32 mode PNG_DEPSTRUCT; /* tells us where we are in the PNG file */ + png_uint_32 flags PNG_DEPSTRUCT; /* flags indicating various things to libpng */ + png_uint_32 transformations PNG_DEPSTRUCT; /* which transformations to perform */ + + z_stream zstream PNG_DEPSTRUCT; /* pointer to decompression structure (below) */ + png_bytep zbuf PNG_DEPSTRUCT; /* buffer for zlib */ + png_size_t zbuf_size PNG_DEPSTRUCT; /* size of zbuf */ + int zlib_level PNG_DEPSTRUCT; /* holds zlib compression level */ + int zlib_method PNG_DEPSTRUCT; /* holds zlib compression method */ + int zlib_window_bits PNG_DEPSTRUCT; /* holds zlib compression window bits */ + int zlib_mem_level PNG_DEPSTRUCT; /* holds zlib compression memory level */ + int zlib_strategy PNG_DEPSTRUCT; /* holds zlib compression strategy */ + + png_uint_32 width PNG_DEPSTRUCT; /* width of image in pixels */ + png_uint_32 height PNG_DEPSTRUCT; /* height of image in pixels */ + png_uint_32 num_rows PNG_DEPSTRUCT; /* number of rows in current pass */ + png_uint_32 usr_width PNG_DEPSTRUCT; /* width of row at start of write */ + png_uint_32 rowbytes PNG_DEPSTRUCT; /* size of row in bytes */ +#if 0 /* Replaced with the following in libpng-1.2.43 */ + png_size_t irowbytes PNG_DEPSTRUCT; +#endif +/* Added in libpng-1.2.43 */ +#ifdef PNG_USER_LIMITS_SUPPORTED + /* Added in libpng-1.4.0: Total number of sPLT, text, and unknown + * chunks that can be stored (0 means unlimited). + */ + png_uint_32 user_chunk_cache_max PNG_DEPSTRUCT; +#endif + png_uint_32 iwidth PNG_DEPSTRUCT; /* width of current interlaced row in pixels */ + png_uint_32 row_number PNG_DEPSTRUCT; /* current row in interlace pass */ + png_bytep prev_row PNG_DEPSTRUCT; /* buffer to save previous (unfiltered) row */ + png_bytep row_buf PNG_DEPSTRUCT; /* buffer to save current (unfiltered) row */ +#ifndef PNG_NO_WRITE_FILTER + png_bytep sub_row PNG_DEPSTRUCT; /* buffer to save "sub" row when filtering */ + png_bytep up_row PNG_DEPSTRUCT; /* buffer to save "up" row when filtering */ + png_bytep avg_row PNG_DEPSTRUCT; /* buffer to save "avg" row when filtering */ + png_bytep paeth_row PNG_DEPSTRUCT; /* buffer to save "Paeth" row when filtering */ +#endif + png_row_info row_info PNG_DEPSTRUCT; /* used for transformation routines */ + + png_uint_32 idat_size PNG_DEPSTRUCT; /* current IDAT size for read */ + png_uint_32 crc PNG_DEPSTRUCT; /* current chunk CRC value */ + png_colorp palette PNG_DEPSTRUCT; /* palette from the input file */ + png_uint_16 num_palette PNG_DEPSTRUCT; /* number of color entries in palette */ + png_uint_16 num_trans PNG_DEPSTRUCT; /* number of transparency values */ + png_byte chunk_name[5] PNG_DEPSTRUCT; /* null-terminated name of current chunk */ + png_byte compression PNG_DEPSTRUCT; /* file compression type (always 0) */ + png_byte filter PNG_DEPSTRUCT; /* file filter type (always 0) */ + png_byte interlaced PNG_DEPSTRUCT; /* PNG_INTERLACE_NONE, PNG_INTERLACE_ADAM7 */ + png_byte pass PNG_DEPSTRUCT; /* current interlace pass (0 - 6) */ + png_byte do_filter PNG_DEPSTRUCT; /* row filter flags (see PNG_FILTER_ below ) */ + png_byte color_type PNG_DEPSTRUCT; /* color type of file */ + png_byte bit_depth PNG_DEPSTRUCT; /* bit depth of file */ + png_byte usr_bit_depth PNG_DEPSTRUCT; /* bit depth of users row */ + png_byte pixel_depth PNG_DEPSTRUCT; /* number of bits per pixel */ + png_byte channels PNG_DEPSTRUCT; /* number of channels in file */ + png_byte usr_channels PNG_DEPSTRUCT; /* channels at start of write */ + png_byte sig_bytes PNG_DEPSTRUCT; /* magic bytes read/written from start of file */ #if defined(PNG_READ_FILLER_SUPPORTED) || defined(PNG_WRITE_FILLER_SUPPORTED) #ifdef PNG_LEGACY_SUPPORTED - png_byte filler; /* filler byte for pixel expansion */ + png_byte filler PNG_DEPSTRUCT; /* filler byte for pixel expansion */ #else - png_uint_16 filler; /* filler bytes for pixel expansion */ + png_uint_16 filler PNG_DEPSTRUCT; /* filler bytes for pixel expansion */ #endif #endif -#if defined(PNG_bKGD_SUPPORTED) - png_byte background_gamma_type; +#ifdef PNG_bKGD_SUPPORTED + png_byte background_gamma_type PNG_DEPSTRUCT; # ifdef PNG_FLOATING_POINT_SUPPORTED - float background_gamma; + float background_gamma PNG_DEPSTRUCT; # endif - png_color_16 background; /* background color in screen gamma space */ -#if defined(PNG_READ_GAMMA_SUPPORTED) - png_color_16 background_1; /* background normalized to gamma 1.0 */ + png_color_16 background PNG_DEPSTRUCT; /* background color in screen gamma space */ +#ifdef PNG_READ_GAMMA_SUPPORTED + png_color_16 background_1 PNG_DEPSTRUCT; /* background normalized to gamma 1.0 */ #endif #endif /* PNG_bKGD_SUPPORTED */ -#if defined(PNG_WRITE_FLUSH_SUPPORTED) - png_flush_ptr output_flush_fn;/* Function for flushing output */ - png_uint_32 flush_dist; /* how many rows apart to flush, 0 - no flush */ - png_uint_32 flush_rows; /* number of rows written since last flush */ +#ifdef PNG_WRITE_FLUSH_SUPPORTED + png_flush_ptr output_flush_fn PNG_DEPSTRUCT; /* Function for flushing output */ + png_uint_32 flush_dist PNG_DEPSTRUCT; /* how many rows apart to flush, 0 - no flush */ + png_uint_32 flush_rows PNG_DEPSTRUCT; /* number of rows written since last flush */ #endif #if defined(PNG_READ_GAMMA_SUPPORTED) || defined(PNG_READ_BACKGROUND_SUPPORTED) - int gamma_shift; /* number of "insignificant" bits 16-bit gamma */ + int gamma_shift PNG_DEPSTRUCT; /* number of "insignificant" bits 16-bit gamma */ #ifdef PNG_FLOATING_POINT_SUPPORTED - float gamma; /* file gamma value */ - float screen_gamma; /* screen gamma value (display_exponent) */ + float gamma PNG_DEPSTRUCT; /* file gamma value */ + float screen_gamma PNG_DEPSTRUCT; /* screen gamma value (display_exponent) */ #endif #endif #if defined(PNG_READ_GAMMA_SUPPORTED) || defined(PNG_READ_BACKGROUND_SUPPORTED) - png_bytep gamma_table; /* gamma table for 8-bit depth files */ - png_bytep gamma_from_1; /* converts from 1.0 to screen */ - png_bytep gamma_to_1; /* converts from file to 1.0 */ - png_uint_16pp gamma_16_table; /* gamma table for 16-bit depth files */ - png_uint_16pp gamma_16_from_1; /* converts from 1.0 to screen */ - png_uint_16pp gamma_16_to_1; /* converts from file to 1.0 */ + png_bytep gamma_table PNG_DEPSTRUCT; /* gamma table for 8-bit depth files */ + png_bytep gamma_from_1 PNG_DEPSTRUCT; /* converts from 1.0 to screen */ + png_bytep gamma_to_1 PNG_DEPSTRUCT; /* converts from file to 1.0 */ + png_uint_16pp gamma_16_table PNG_DEPSTRUCT; /* gamma table for 16-bit depth files */ + png_uint_16pp gamma_16_from_1 PNG_DEPSTRUCT; /* converts from 1.0 to screen */ + png_uint_16pp gamma_16_to_1 PNG_DEPSTRUCT; /* converts from file to 1.0 */ #endif #if defined(PNG_READ_GAMMA_SUPPORTED) || defined(PNG_sBIT_SUPPORTED) - png_color_8 sig_bit; /* significant bits in each available channel */ + png_color_8 sig_bit PNG_DEPSTRUCT; /* significant bits in each available channel */ #endif #if defined(PNG_READ_SHIFT_SUPPORTED) || defined(PNG_WRITE_SHIFT_SUPPORTED) - png_color_8 shift; /* shift for significant bit tranformation */ + png_color_8 shift PNG_DEPSTRUCT; /* shift for significant bit tranformation */ #endif #if defined(PNG_tRNS_SUPPORTED) || defined(PNG_READ_BACKGROUND_SUPPORTED) \ || defined(PNG_READ_EXPAND_SUPPORTED) || defined(PNG_READ_BACKGROUND_SUPPORTED) - png_bytep trans; /* transparency values for paletted files */ - png_color_16 trans_values; /* transparency values for non-paletted files */ + png_bytep trans PNG_DEPSTRUCT; /* transparency values for paletted files */ + png_color_16 trans_values PNG_DEPSTRUCT; /* transparency values for non-paletted files */ #endif - png_read_status_ptr read_row_fn; /* called after each row is decoded */ - png_write_status_ptr write_row_fn; /* called after each row is encoded */ + png_read_status_ptr read_row_fn PNG_DEPSTRUCT; /* called after each row is decoded */ + png_write_status_ptr write_row_fn PNG_DEPSTRUCT; /* called after each row is encoded */ #ifdef PNG_PROGRESSIVE_READ_SUPPORTED - png_progressive_info_ptr info_fn; /* called after header data fully read */ - png_progressive_row_ptr row_fn; /* called after each prog. row is decoded */ - png_progressive_end_ptr end_fn; /* called after image is complete */ - png_bytep save_buffer_ptr; /* current location in save_buffer */ - png_bytep save_buffer; /* buffer for previously read data */ - png_bytep current_buffer_ptr; /* current location in current_buffer */ - png_bytep current_buffer; /* buffer for recently used data */ - png_uint_32 push_length; /* size of current input chunk */ - png_uint_32 skip_length; /* bytes to skip in input data */ - png_size_t save_buffer_size; /* amount of data now in save_buffer */ - png_size_t save_buffer_max; /* total size of save_buffer */ - png_size_t buffer_size; /* total amount of available input data */ - png_size_t current_buffer_size; /* amount of data now in current_buffer */ - int process_mode; /* what push library is currently doing */ - int cur_palette; /* current push library palette index */ - -# if defined(PNG_TEXT_SUPPORTED) - png_size_t current_text_size; /* current size of text input data */ - png_size_t current_text_left; /* how much text left to read in input */ - png_charp current_text; /* current text chunk buffer */ - png_charp current_text_ptr; /* current location in current_text */ + png_progressive_info_ptr info_fn PNG_DEPSTRUCT; /* called after header data fully read */ + png_progressive_row_ptr row_fn PNG_DEPSTRUCT; /* called after each prog. row is decoded */ + png_progressive_end_ptr end_fn PNG_DEPSTRUCT; /* called after image is complete */ + png_bytep save_buffer_ptr PNG_DEPSTRUCT; /* current location in save_buffer */ + png_bytep save_buffer PNG_DEPSTRUCT; /* buffer for previously read data */ + png_bytep current_buffer_ptr PNG_DEPSTRUCT; /* current location in current_buffer */ + png_bytep current_buffer PNG_DEPSTRUCT; /* buffer for recently used data */ + png_uint_32 push_length PNG_DEPSTRUCT; /* size of current input chunk */ + png_uint_32 skip_length PNG_DEPSTRUCT; /* bytes to skip in input data */ + png_size_t save_buffer_size PNG_DEPSTRUCT; /* amount of data now in save_buffer */ + png_size_t save_buffer_max PNG_DEPSTRUCT; /* total size of save_buffer */ + png_size_t buffer_size PNG_DEPSTRUCT; /* total amount of available input data */ + png_size_t current_buffer_size PNG_DEPSTRUCT; /* amount of data now in current_buffer */ + int process_mode PNG_DEPSTRUCT; /* what push library is currently doing */ + int cur_palette PNG_DEPSTRUCT; /* current push library palette index */ + +# ifdef PNG_TEXT_SUPPORTED + png_size_t current_text_size PNG_DEPSTRUCT; /* current size of text input data */ + png_size_t current_text_left PNG_DEPSTRUCT; /* how much text left to read in input */ + png_charp current_text PNG_DEPSTRUCT; /* current text chunk buffer */ + png_charp current_text_ptr PNG_DEPSTRUCT; /* current location in current_text */ # endif /* PNG_TEXT_SUPPORTED */ #endif /* PNG_PROGRESSIVE_READ_SUPPORTED */ #if defined(__TURBOC__) && !defined(_Windows) && !defined(__FLAT__) /* for the Borland special 64K segment handler */ - png_bytepp offset_table_ptr; - png_bytep offset_table; - png_uint_16 offset_table_number; - png_uint_16 offset_table_count; - png_uint_16 offset_table_count_free; + png_bytepp offset_table_ptr PNG_DEPSTRUCT; + png_bytep offset_table PNG_DEPSTRUCT; + png_uint_16 offset_table_number PNG_DEPSTRUCT; + png_uint_16 offset_table_count PNG_DEPSTRUCT; + png_uint_16 offset_table_count_free PNG_DEPSTRUCT; #endif -#if defined(PNG_READ_DITHER_SUPPORTED) - png_bytep palette_lookup; /* lookup table for dithering */ - png_bytep dither_index; /* index translation for palette files */ +#ifdef PNG_READ_DITHER_SUPPORTED + png_bytep palette_lookup PNG_DEPSTRUCT; /* lookup table for dithering */ + png_bytep dither_index PNG_DEPSTRUCT; /* index translation for palette files */ #endif #if defined(PNG_READ_DITHER_SUPPORTED) || defined(PNG_hIST_SUPPORTED) - png_uint_16p hist; /* histogram */ + png_uint_16p hist PNG_DEPSTRUCT; /* histogram */ #endif -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) - png_byte heuristic_method; /* heuristic for row filter selection */ - png_byte num_prev_filters; /* number of weights for previous rows */ - png_bytep prev_filters; /* filter type(s) of previous row(s) */ - png_uint_16p filter_weights; /* weight(s) for previous line(s) */ - png_uint_16p inv_filter_weights; /* 1/weight(s) for previous line(s) */ - png_uint_16p filter_costs; /* relative filter calculation cost */ - png_uint_16p inv_filter_costs; /* 1/relative filter calculation cost */ +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED + png_byte heuristic_method PNG_DEPSTRUCT; /* heuristic for row filter selection */ + png_byte num_prev_filters PNG_DEPSTRUCT; /* number of weights for previous rows */ + png_bytep prev_filters PNG_DEPSTRUCT; /* filter type(s) of previous row(s) */ + png_uint_16p filter_weights PNG_DEPSTRUCT; /* weight(s) for previous line(s) */ + png_uint_16p inv_filter_weights PNG_DEPSTRUCT; /* 1/weight(s) for previous line(s) */ + png_uint_16p filter_costs PNG_DEPSTRUCT; /* relative filter calculation cost */ + png_uint_16p inv_filter_costs PNG_DEPSTRUCT; /* 1/relative filter calculation cost */ #endif -#if defined(PNG_TIME_RFC1123_SUPPORTED) - png_charp time_buffer; /* String to hold RFC 1123 time text */ +#ifdef PNG_TIME_RFC1123_SUPPORTED + png_charp time_buffer PNG_DEPSTRUCT; /* String to hold RFC 1123 time text */ #endif /* New members added in libpng-1.0.6 */ #ifdef PNG_FREE_ME_SUPPORTED - png_uint_32 free_me; /* flags items libpng is responsible for freeing */ + png_uint_32 free_me PNG_DEPSTRUCT; /* flags items libpng is responsible for freeing */ #endif -#if defined(PNG_USER_CHUNKS_SUPPORTED) - png_voidp user_chunk_ptr; - png_user_chunk_ptr read_user_chunk_fn; /* user read chunk handler */ +#ifdef PNG_USER_CHUNKS_SUPPORTED + png_voidp user_chunk_ptr PNG_DEPSTRUCT; + png_user_chunk_ptr read_user_chunk_fn PNG_DEPSTRUCT; /* user read chunk handler */ #endif -#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) - int num_chunk_list; - png_bytep chunk_list; +#ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED + int num_chunk_list PNG_DEPSTRUCT; + png_bytep chunk_list PNG_DEPSTRUCT; #endif /* New members added in libpng-1.0.3 */ -#if defined(PNG_READ_RGB_TO_GRAY_SUPPORTED) - png_byte rgb_to_gray_status; +#ifdef PNG_READ_RGB_TO_GRAY_SUPPORTED + png_byte rgb_to_gray_status PNG_DEPSTRUCT; /* These were changed from png_byte in libpng-1.0.6 */ - png_uint_16 rgb_to_gray_red_coeff; - png_uint_16 rgb_to_gray_green_coeff; - png_uint_16 rgb_to_gray_blue_coeff; + png_uint_16 rgb_to_gray_red_coeff PNG_DEPSTRUCT; + png_uint_16 rgb_to_gray_green_coeff PNG_DEPSTRUCT; + png_uint_16 rgb_to_gray_blue_coeff PNG_DEPSTRUCT; #endif /* New member added in libpng-1.0.4 (renamed in 1.0.9) */ #if defined(PNG_MNG_FEATURES_SUPPORTED) || \ defined(PNG_READ_EMPTY_PLTE_SUPPORTED) || \ defined(PNG_WRITE_EMPTY_PLTE_SUPPORTED) -/* changed from png_byte to png_uint_32 at version 1.2.0 */ +/* Changed from png_byte to png_uint_32 at version 1.2.0 */ #ifdef PNG_1_0_X - png_byte mng_features_permitted; + png_byte mng_features_permitted PNG_DEPSTRUCT; #else - png_uint_32 mng_features_permitted; + png_uint_32 mng_features_permitted PNG_DEPSTRUCT; #endif /* PNG_1_0_X */ #endif /* New member added in libpng-1.0.7 */ #if defined(PNG_READ_GAMMA_SUPPORTED) || defined(PNG_READ_BACKGROUND_SUPPORTED) - png_fixed_point int_gamma; + png_fixed_point int_gamma PNG_DEPSTRUCT; #endif /* New member added in libpng-1.0.9, ifdef'ed out in 1.0.12, enabled in 1.2.0 */ -#if defined(PNG_MNG_FEATURES_SUPPORTED) - png_byte filter_type; +#ifdef PNG_MNG_FEATURES_SUPPORTED + png_byte filter_type PNG_DEPSTRUCT; #endif -#if defined(PNG_1_0_X) +#ifdef PNG_1_0_X /* New member added in libpng-1.0.10, ifdef'ed out in 1.2.0 */ - png_uint_32 row_buf_size; + png_uint_32 row_buf_size PNG_DEPSTRUCT; #endif /* New members added in libpng-1.2.0 */ -#if defined(PNG_ASSEMBLER_CODE_SUPPORTED) -# if !defined(PNG_1_0_X) -# if defined(PNG_MMX_CODE_SUPPORTED) - png_byte mmx_bitdepth_threshold; - png_uint_32 mmx_rowbytes_threshold; +#ifdef PNG_ASSEMBLER_CODE_SUPPORTED +# ifndef PNG_1_0_X +# ifdef PNG_MMX_CODE_SUPPORTED + png_byte mmx_bitdepth_threshold PNG_DEPSTRUCT; + png_uint_32 mmx_rowbytes_threshold PNG_DEPSTRUCT; # endif - png_uint_32 asm_flags; + png_uint_32 asm_flags PNG_DEPSTRUCT; # endif #endif /* New members added in libpng-1.0.2 but first enabled by default in 1.2.0 */ #ifdef PNG_USER_MEM_SUPPORTED - png_voidp mem_ptr; /* user supplied struct for mem functions */ - png_malloc_ptr malloc_fn; /* function for allocating memory */ - png_free_ptr free_fn; /* function for freeing memory */ + png_voidp mem_ptr PNG_DEPSTRUCT; /* user supplied struct for mem functions */ + png_malloc_ptr malloc_fn PNG_DEPSTRUCT; /* function for allocating memory */ + png_free_ptr free_fn PNG_DEPSTRUCT; /* function for freeing memory */ #endif /* New member added in libpng-1.0.13 and 1.2.0 */ - png_bytep big_row_buf; /* buffer to save current (unfiltered) row */ + png_bytep big_row_buf PNG_DEPSTRUCT; /* buffer to save current (unfiltered) row */ -#if defined(PNG_READ_DITHER_SUPPORTED) +#ifdef PNG_READ_DITHER_SUPPORTED /* The following three members were added at version 1.0.14 and 1.2.4 */ - png_bytep dither_sort; /* working sort array */ - png_bytep index_to_palette; /* where the original index currently is */ - /* in the palette */ - png_bytep palette_to_index; /* which original index points to this */ - /* palette color */ + png_bytep dither_sort PNG_DEPSTRUCT; /* working sort array */ + png_bytep index_to_palette PNG_DEPSTRUCT; /* where the original index currently is */ + /* in the palette */ + png_bytep palette_to_index PNG_DEPSTRUCT; /* which original index points to this */ + /* palette color */ #endif /* New members added in libpng-1.0.16 and 1.2.6 */ - png_byte compression_type; + png_byte compression_type PNG_DEPSTRUCT; -#ifdef PNG_SET_USER_LIMITS_SUPPORTED - png_uint_32 user_width_max; - png_uint_32 user_height_max; +#ifdef PNG_USER_LIMITS_SUPPORTED + png_uint_32 user_width_max PNG_DEPSTRUCT; + png_uint_32 user_height_max PNG_DEPSTRUCT; #endif /* New member added in libpng-1.0.25 and 1.2.17 */ -#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) - /* storage for unknown chunk that the library doesn't recognize. */ - png_unknown_chunk unknown_chunk; +#ifdef PNG_UNKNOWN_CHUNKS_SUPPORTED + /* Storage for unknown chunk that the library doesn't recognize. */ + png_unknown_chunk unknown_chunk PNG_DEPSTRUCT; #endif + +/* New members added in libpng-1.2.26 */ + png_uint_32 old_big_row_buf_size PNG_DEPSTRUCT; + png_uint_32 old_prev_row_size PNG_DEPSTRUCT; + +/* New member added in libpng-1.2.30 */ + png_charp chunkdata PNG_DEPSTRUCT; /* buffer for reading chunk data */ + + }; /* This triggers a compiler error in png.c, if png.c and png.h * do not agree upon the version number. */ -typedef png_structp version_1_2_23; +typedef png_structp version_1_2_50; typedef png_struct FAR * FAR * png_structpp; @@ -1459,17 +1603,17 @@ extern PNG_EXPORT(int,png_sig_cmp) PNGARG((png_bytep sig, png_size_t start, /* Simple signature checking function. This is the same as calling * png_check_sig(sig, n) := !png_sig_cmp(sig, 0, n). */ -extern PNG_EXPORT(int,png_check_sig) PNGARG((png_bytep sig, int num)); +extern PNG_EXPORT(int,png_check_sig) PNGARG((png_bytep sig, int num)) PNG_DEPRECATED; /* Allocate and initialize png_ptr struct for reading, and any other memory. */ extern PNG_EXPORT(png_structp,png_create_read_struct) PNGARG((png_const_charp user_png_ver, png_voidp error_ptr, - png_error_ptr error_fn, png_error_ptr warn_fn)); + png_error_ptr error_fn, png_error_ptr warn_fn)) PNG_ALLOCATED; /* Allocate and initialize png_ptr struct for writing, and any other memory */ extern PNG_EXPORT(png_structp,png_create_write_struct) PNGARG((png_const_charp user_png_ver, png_voidp error_ptr, - png_error_ptr error_fn, png_error_ptr warn_fn)); + png_error_ptr error_fn, png_error_ptr warn_fn)) PNG_ALLOCATED; #ifdef PNG_WRITE_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_compression_buffer_size) @@ -1489,11 +1633,11 @@ extern PNG_EXPORT(int,png_reset_zstream) PNGARG((png_structp png_ptr)); extern PNG_EXPORT(png_structp,png_create_read_struct_2) PNGARG((png_const_charp user_png_ver, png_voidp error_ptr, png_error_ptr error_fn, png_error_ptr warn_fn, png_voidp mem_ptr, - png_malloc_ptr malloc_fn, png_free_ptr free_fn)); + png_malloc_ptr malloc_fn, png_free_ptr free_fn)) PNG_ALLOCATED; extern PNG_EXPORT(png_structp,png_create_write_struct_2) PNGARG((png_const_charp user_png_ver, png_voidp error_ptr, png_error_ptr error_fn, png_error_ptr warn_fn, png_voidp mem_ptr, - png_malloc_ptr malloc_fn, png_free_ptr free_fn)); + png_malloc_ptr malloc_fn, png_free_ptr free_fn)) PNG_ALLOCATED; #endif /* Write a PNG chunk - size, type, (optional) data, CRC. */ @@ -1513,11 +1657,12 @@ extern PNG_EXPORT(void,png_write_chunk_end) PNGARG((png_structp png_ptr)); /* Allocate and initialize the info structure */ extern PNG_EXPORT(png_infop,png_create_info_struct) - PNGARG((png_structp png_ptr)); + PNGARG((png_structp png_ptr)) PNG_ALLOCATED; #if defined(PNG_1_0_X) || defined (PNG_1_2_X) /* Initialize the info structure (old interface - DEPRECATED) */ -extern PNG_EXPORT(void,png_info_init) PNGARG((png_infop info_ptr)); +extern PNG_EXPORT(void,png_info_init) PNGARG((png_infop info_ptr)) + PNG_DEPRECATED; #undef png_info_init #define png_info_init(info_ptr) png_info_init_3(&info_ptr,\ png_sizeof(png_info)); @@ -1532,34 +1677,31 @@ extern PNG_EXPORT(void,png_write_info_before_PLTE) PNGARG((png_structp png_ptr, extern PNG_EXPORT(void,png_write_info) PNGARG((png_structp png_ptr, png_infop info_ptr)); -#ifndef PNG_NO_SEQUENTIAL_READ_SUPPORTED -/* read the information before the actual image data. */ +#ifdef PNG_SEQUENTIAL_READ_SUPPORTED +/* Read the information before the actual image data. */ extern PNG_EXPORT(void,png_read_info) PNGARG((png_structp png_ptr, png_infop info_ptr)); #endif -#if defined(PNG_TIME_RFC1123_SUPPORTED) +#ifdef PNG_TIME_RFC1123_SUPPORTED extern PNG_EXPORT(png_charp,png_convert_to_rfc1123) PNGARG((png_structp png_ptr, png_timep ptime)); #endif -#if !defined(_WIN32_WCE) -/* "time.h" functions are not supported on WindowsCE */ -#if defined(PNG_WRITE_tIME_SUPPORTED) -/* convert from a struct tm to png_time */ +#ifdef PNG_CONVERT_tIME_SUPPORTED +/* Convert from a struct tm to png_time */ extern PNG_EXPORT(void,png_convert_from_struct_tm) PNGARG((png_timep ptime, struct tm FAR * ttime)); -/* convert from time_t to png_time. Uses gmtime() */ +/* Convert from time_t to png_time. Uses gmtime() */ extern PNG_EXPORT(void,png_convert_from_time_t) PNGARG((png_timep ptime, time_t ttime)); -#endif /* PNG_WRITE_tIME_SUPPORTED */ -#endif /* _WIN32_WCE */ +#endif /* PNG_CONVERT_tIME_SUPPORTED */ -#if defined(PNG_READ_EXPAND_SUPPORTED) +#ifdef PNG_READ_EXPAND_SUPPORTED /* Expand data to 24-bit RGB, or 8-bit grayscale, with alpha if available. */ extern PNG_EXPORT(void,png_set_expand) PNGARG((png_structp png_ptr)); -#if !defined(PNG_1_0_X) +#ifndef PNG_1_0_X extern PNG_EXPORT(void,png_set_expand_gray_1_2_4_to_8) PNGARG((png_structp png_ptr)); #endif @@ -1567,7 +1709,8 @@ extern PNG_EXPORT(void,png_set_palette_to_rgb) PNGARG((png_structp png_ptr)); extern PNG_EXPORT(void,png_set_tRNS_to_alpha) PNGARG((png_structp png_ptr)); #if defined(PNG_1_0_X) || defined (PNG_1_2_X) /* Deprecated */ -extern PNG_EXPORT(void,png_set_gray_1_2_4_to_8) PNGARG((png_structp png_ptr)); +extern PNG_EXPORT(void,png_set_gray_1_2_4_to_8) PNGARG((png_structp + png_ptr)) PNG_DEPRECATED; #endif #endif @@ -1576,12 +1719,12 @@ extern PNG_EXPORT(void,png_set_gray_1_2_4_to_8) PNGARG((png_structp png_ptr)); extern PNG_EXPORT(void,png_set_bgr) PNGARG((png_structp png_ptr)); #endif -#if defined(PNG_READ_GRAY_TO_RGB_SUPPORTED) +#ifdef PNG_READ_GRAY_TO_RGB_SUPPORTED /* Expand the grayscale to 24-bit RGB if necessary. */ extern PNG_EXPORT(void,png_set_gray_to_rgb) PNGARG((png_structp png_ptr)); #endif -#if defined(PNG_READ_RGB_TO_GRAY_SUPPORTED) +#ifdef PNG_READ_RGB_TO_GRAY_SUPPORTED /* Reduce RGB to grayscale. */ #ifdef PNG_FLOATING_POINT_SUPPORTED extern PNG_EXPORT(void,png_set_rgb_to_gray) PNGARG((png_structp png_ptr, @@ -1596,7 +1739,7 @@ extern PNG_EXPORT(png_byte,png_get_rgb_to_gray_status) PNGARG((png_structp extern PNG_EXPORT(void,png_build_grayscale_palette) PNGARG((int bit_depth, png_colorp palette)); -#if defined(PNG_READ_STRIP_ALPHA_SUPPORTED) +#ifdef PNG_READ_STRIP_ALPHA_SUPPORTED extern PNG_EXPORT(void,png_set_strip_alpha) PNGARG((png_structp png_ptr)); #endif @@ -1618,7 +1761,7 @@ extern PNG_EXPORT(void,png_set_filler) PNGARG((png_structp png_ptr, #define PNG_FILLER_BEFORE 0 #define PNG_FILLER_AFTER 1 /* Add an alpha byte to 8-bit Gray or 24-bit RGB images. */ -#if !defined(PNG_1_0_X) +#ifndef PNG_1_0_X extern PNG_EXPORT(void,png_set_add_alpha) PNGARG((png_structp png_ptr, png_uint_32 filler, int flags)); #endif @@ -1656,7 +1799,7 @@ extern PNG_EXPORT(int,png_set_interlace_handling) PNGARG((png_structp png_ptr)); extern PNG_EXPORT(void,png_set_invert_mono) PNGARG((png_structp png_ptr)); #endif -#if defined(PNG_READ_BACKGROUND_SUPPORTED) +#ifdef PNG_READ_BACKGROUND_SUPPORTED /* Handle alpha and tRNS by replacing with a background color. */ #ifdef PNG_FLOATING_POINT_SUPPORTED extern PNG_EXPORT(void,png_set_background) PNGARG((png_structp png_ptr, @@ -1669,19 +1812,19 @@ extern PNG_EXPORT(void,png_set_background) PNGARG((png_structp png_ptr, #define PNG_BACKGROUND_GAMMA_UNIQUE 3 #endif -#if defined(PNG_READ_16_TO_8_SUPPORTED) -/* strip the second byte of information from a 16-bit depth file. */ +#ifdef PNG_READ_16_TO_8_SUPPORTED +/* Strip the second byte of information from a 16-bit depth file. */ extern PNG_EXPORT(void,png_set_strip_16) PNGARG((png_structp png_ptr)); #endif -#if defined(PNG_READ_DITHER_SUPPORTED) +#ifdef PNG_READ_DITHER_SUPPORTED /* Turn on dithering, and reduce the palette to the number of colors available. */ extern PNG_EXPORT(void,png_set_dither) PNGARG((png_structp png_ptr, png_colorp palette, int num_palette, int maximum_colors, png_uint_16p histogram, int full_dither)); #endif -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED /* Handle gamma correction. Screen_gamma=(display_exponent) */ #ifdef PNG_FLOATING_POINT_SUPPORTED extern PNG_EXPORT(void,png_set_gamma) PNGARG((png_structp png_ptr, @@ -1695,85 +1838,85 @@ extern PNG_EXPORT(void,png_set_gamma) PNGARG((png_structp png_ptr, /* Permit or disallow empty PLTE (0: not permitted, 1: permitted) */ /* Deprecated and will be removed. Use png_permit_mng_features() instead. */ extern PNG_EXPORT(void,png_permit_empty_plte) PNGARG((png_structp png_ptr, - int empty_plte_permitted)); + int empty_plte_permitted)) PNG_DEPRECATED; #endif #endif -#if defined(PNG_WRITE_FLUSH_SUPPORTED) +#ifdef PNG_WRITE_FLUSH_SUPPORTED /* Set how many lines between output flushes - 0 for no flushing */ extern PNG_EXPORT(void,png_set_flush) PNGARG((png_structp png_ptr, int nrows)); /* Flush the current PNG output buffer */ extern PNG_EXPORT(void,png_write_flush) PNGARG((png_structp png_ptr)); #endif -/* optional update palette with requested transformations */ +/* Optional update palette with requested transformations */ extern PNG_EXPORT(void,png_start_read_image) PNGARG((png_structp png_ptr)); -/* optional call to update the users info structure */ +/* Optional call to update the users info structure */ extern PNG_EXPORT(void,png_read_update_info) PNGARG((png_structp png_ptr, png_infop info_ptr)); #ifndef PNG_NO_SEQUENTIAL_READ_SUPPORTED -/* read one or more rows of image data. */ +/* Read one or more rows of image data. */ extern PNG_EXPORT(void,png_read_rows) PNGARG((png_structp png_ptr, png_bytepp row, png_bytepp display_row, png_uint_32 num_rows)); #endif #ifndef PNG_NO_SEQUENTIAL_READ_SUPPORTED -/* read a row of data. */ +/* Read a row of data. */ extern PNG_EXPORT(void,png_read_row) PNGARG((png_structp png_ptr, png_bytep row, png_bytep display_row)); #endif #ifndef PNG_NO_SEQUENTIAL_READ_SUPPORTED -/* read the whole image into memory at once. */ +/* Read the whole image into memory at once. */ extern PNG_EXPORT(void,png_read_image) PNGARG((png_structp png_ptr, png_bytepp image)); #endif -/* write a row of image data */ +/* Write a row of image data */ extern PNG_EXPORT(void,png_write_row) PNGARG((png_structp png_ptr, png_bytep row)); -/* write a few rows of image data */ +/* Write a few rows of image data */ extern PNG_EXPORT(void,png_write_rows) PNGARG((png_structp png_ptr, png_bytepp row, png_uint_32 num_rows)); -/* write the image data */ +/* Write the image data */ extern PNG_EXPORT(void,png_write_image) PNGARG((png_structp png_ptr, png_bytepp image)); -/* writes the end of the PNG file. */ +/* Writes the end of the PNG file. */ extern PNG_EXPORT(void,png_write_end) PNGARG((png_structp png_ptr, png_infop info_ptr)); #ifndef PNG_NO_SEQUENTIAL_READ_SUPPORTED -/* read the end of the PNG file. */ +/* Read the end of the PNG file. */ extern PNG_EXPORT(void,png_read_end) PNGARG((png_structp png_ptr, png_infop info_ptr)); #endif -/* free any memory associated with the png_info_struct */ +/* Free any memory associated with the png_info_struct */ extern PNG_EXPORT(void,png_destroy_info_struct) PNGARG((png_structp png_ptr, png_infopp info_ptr_ptr)); -/* free any memory associated with the png_struct and the png_info_structs */ +/* Free any memory associated with the png_struct and the png_info_structs */ extern PNG_EXPORT(void,png_destroy_read_struct) PNGARG((png_structpp png_ptr_ptr, png_infopp info_ptr_ptr, png_infopp end_info_ptr_ptr)); -/* free all memory used by the read (old method - NOT DLL EXPORTED) */ +/* Free all memory used by the read (old method - NOT DLL EXPORTED) */ extern void png_read_destroy PNGARG((png_structp png_ptr, png_infop info_ptr, - png_infop end_info_ptr)); + png_infop end_info_ptr)) PNG_DEPRECATED; -/* free any memory associated with the png_struct and the png_info_structs */ +/* Free any memory associated with the png_struct and the png_info_structs */ extern PNG_EXPORT(void,png_destroy_write_struct) PNGARG((png_structpp png_ptr_ptr, png_infopp info_ptr_ptr)); -/* free any memory used in png_ptr struct (old method - NOT DLL EXPORTED) */ -extern void png_write_destroy PNGARG((png_structp png_ptr)); +/* Free any memory used in png_ptr struct (old method - NOT DLL EXPORTED) */ +extern void png_write_destroy PNGARG((png_structp png_ptr)) PNG_DEPRECATED; -/* set the libpng method of handling chunk CRC errors */ +/* Set the libpng method of handling chunk CRC errors */ extern PNG_EXPORT(void,png_set_crc_action) PNGARG((png_structp png_ptr, int crit_action, int ancil_action)); @@ -1801,7 +1944,7 @@ extern PNG_EXPORT(void,png_set_crc_action) PNGARG((png_structp png_ptr, * header file (zlib.h) for an explination of the compression functions. */ -/* set the filtering method(s) used by libpng. Currently, the only valid +/* Set the filtering method(s) used by libpng. Currently, the only valid * value for "method" is 0. */ extern PNG_EXPORT(void,png_set_filter) PNGARG((png_structp png_ptr, int method, @@ -1906,7 +2049,7 @@ extern PNG_EXPORT(void,png_set_compression_method) PNGARG((png_structp png_ptr, * more information. */ -#if !defined(PNG_NO_STDIO) +#ifdef PNG_STDIO_SUPPORTED /* Initialize the input/output for the PNG file to the default functions. */ extern PNG_EXPORT(void,png_init_io) PNGARG((png_structp png_ptr, png_FILE_p fp)); #endif @@ -1929,6 +2072,11 @@ extern PNG_EXPORT(png_voidp,png_get_error_ptr) PNGARG((png_structp png_ptr)); * If buffered output is not used, then output_flush_fn can be set to NULL. * If PNG_WRITE_FLUSH_SUPPORTED is not defined at libpng compile time * output_flush_fn will be ignored (and thus can be NULL). + * It is probably a mistake to use NULL for output_flush_fn if + * write_data_fn is not also NULL unless you have built libpng with + * PNG_WRITE_FLUSH_SUPPORTED undefined, because in this case libpng's + * default flush function, which uses the standard *FILE structure, will + * be used. */ extern PNG_EXPORT(void,png_set_write_fn) PNGARG((png_structp png_ptr, png_voidp io_ptr, png_rw_ptr write_data_fn, png_flush_ptr output_flush_fn)); @@ -1993,15 +2141,15 @@ extern PNG_EXPORT(void,png_set_progressive_read_fn) PNGARG((png_structp png_ptr, png_progressive_info_ptr info_fn, png_progressive_row_ptr row_fn, png_progressive_end_ptr end_fn)); -/* returns the user pointer associated with the push read functions */ +/* Returns the user pointer associated with the push read functions */ extern PNG_EXPORT(png_voidp,png_get_progressive_ptr) PNGARG((png_structp png_ptr)); -/* function to be called when data becomes available */ +/* Function to be called when data becomes available */ extern PNG_EXPORT(void,png_process_data) PNGARG((png_structp png_ptr, png_infop info_ptr, png_bytep buffer, png_size_t buffer_size)); -/* function that combines rows. Not very much different than the +/* Function that combines rows. Not very much different than the * png_combine_row() call. Is this even used????? */ extern PNG_EXPORT(void,png_progressive_combine_row) PNGARG((png_structp png_ptr, @@ -2009,20 +2157,20 @@ extern PNG_EXPORT(void,png_progressive_combine_row) PNGARG((png_structp png_ptr, #endif /* PNG_PROGRESSIVE_READ_SUPPORTED */ extern PNG_EXPORT(png_voidp,png_malloc) PNGARG((png_structp png_ptr, - png_uint_32 size)); + png_uint_32 size)) PNG_ALLOCATED; -#if defined(PNG_1_0_X) +#ifdef PNG_1_0_X # define png_malloc_warn png_malloc #else /* Added at libpng version 1.2.4 */ extern PNG_EXPORT(png_voidp,png_malloc_warn) PNGARG((png_structp png_ptr, - png_uint_32 size)); + png_uint_32 size)) PNG_ALLOCATED; #endif -/* frees a pointer allocated by png_malloc() */ +/* Frees a pointer allocated by png_malloc() */ extern PNG_EXPORT(void,png_free) PNGARG((png_structp png_ptr, png_voidp ptr)); -#if defined(PNG_1_0_X) +#ifdef PNG_1_0_X /* Function to allocate memory for zlib. */ extern PNG_EXPORT(voidpf,png_zalloc) PNGARG((voidpf png_ptr, uInt items, uInt size)); @@ -2036,11 +2184,12 @@ extern PNG_EXPORT(void,png_free_data) PNGARG((png_structp png_ptr, png_infop info_ptr, png_uint_32 free_me, int num)); #ifdef PNG_FREE_ME_SUPPORTED /* Reassign responsibility for freeing existing data, whether allocated - * by libpng or by the application */ + * by libpng or by the application + */ extern PNG_EXPORT(void,png_data_freer) PNGARG((png_structp png_ptr, png_infop info_ptr, int freer, png_uint_32 mask)); #endif -/* assignments for png_data_freer */ +/* Assignments for png_data_freer */ #define PNG_DESTROY_WILL_FREE_DATA 1 #define PNG_SET_WILL_FREE_DATA 1 #define PNG_USER_WILL_FREE_DATA 2 @@ -2061,16 +2210,16 @@ extern PNG_EXPORT(void,png_data_freer) PNGARG((png_structp png_ptr, #ifdef PNG_USER_MEM_SUPPORTED extern PNG_EXPORT(png_voidp,png_malloc_default) PNGARG((png_structp png_ptr, - png_uint_32 size)); + png_uint_32 size)) PNG_ALLOCATED; extern PNG_EXPORT(void,png_free_default) PNGARG((png_structp png_ptr, png_voidp ptr)); #endif extern PNG_EXPORT(png_voidp,png_memcpy_check) PNGARG((png_structp png_ptr, - png_voidp s1, png_voidp s2, png_uint_32 size)); + png_voidp s1, png_voidp s2, png_uint_32 size)) PNG_DEPRECATED; extern PNG_EXPORT(png_voidp,png_memset_check) PNGARG((png_structp png_ptr, - png_voidp s1, int value, png_uint_32 size)); + png_voidp s1, int value, png_uint_32 size)) PNG_DEPRECATED; #if defined(USE_FAR_KEYWORD) /* memory model conversion function */ extern void *png_far_to_near PNGARG((png_structp png_ptr,png_voidp ptr, @@ -2080,14 +2229,14 @@ extern void *png_far_to_near PNGARG((png_structp png_ptr,png_voidp ptr, #ifndef PNG_NO_ERROR_TEXT /* Fatal error in PNG image of libpng - can't continue */ extern PNG_EXPORT(void,png_error) PNGARG((png_structp png_ptr, - png_const_charp error_message)); + png_const_charp error_message)) PNG_NORETURN; /* The same, but the chunk name is prepended to the error string. */ extern PNG_EXPORT(void,png_chunk_error) PNGARG((png_structp png_ptr, - png_const_charp error_message)); + png_const_charp error_message)) PNG_NORETURN; #else /* Fatal error in PNG image of libpng - can't continue */ -extern PNG_EXPORT(void,png_err) PNGARG((png_structp png_ptr)); +extern PNG_EXPORT(void,png_err) PNGARG((png_structp png_ptr)) PNG_NORETURN; #endif #ifndef PNG_NO_WARNINGS @@ -2122,13 +2271,15 @@ png_infop info_ptr, png_uint_32 flag)); extern PNG_EXPORT(png_uint_32,png_get_rowbytes) PNGARG((png_structp png_ptr, png_infop info_ptr)); -#if defined(PNG_INFO_IMAGE_SUPPORTED) +#ifdef PNG_INFO_IMAGE_SUPPORTED /* Returns row_pointers, which is an array of pointers to scanlines that was -returned from png_read_png(). */ + * returned from png_read_png(). + */ extern PNG_EXPORT(png_bytepp,png_get_rows) PNGARG((png_structp png_ptr, png_infop info_ptr)); /* Set row_pointers, which is an array of pointers to scanlines for use -by png_write_png(). */ + * by png_write_png(). + */ extern PNG_EXPORT(void,png_set_rows) PNGARG((png_structp png_ptr, png_infop info_ptr, png_bytepp row_pointers)); #endif @@ -2196,17 +2347,17 @@ png_ptr, png_infop info_ptr)); extern PNG_EXPORT(png_bytep,png_get_signature) PNGARG((png_structp png_ptr, png_infop info_ptr)); -#if defined(PNG_bKGD_SUPPORTED) +#ifdef PNG_bKGD_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_bKGD) PNGARG((png_structp png_ptr, png_infop info_ptr, png_color_16p *background)); #endif -#if defined(PNG_bKGD_SUPPORTED) +#ifdef PNG_bKGD_SUPPORTED extern PNG_EXPORT(void,png_set_bKGD) PNGARG((png_structp png_ptr, png_infop info_ptr, png_color_16p background)); #endif -#if defined(PNG_cHRM_SUPPORTED) +#ifdef PNG_cHRM_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_cHRM) PNGARG((png_structp png_ptr, png_infop info_ptr, double *white_x, double *white_y, double *red_x, @@ -2222,7 +2373,7 @@ extern PNG_EXPORT(png_uint_32,png_get_cHRM_fixed) PNGARG((png_structp png_ptr, #endif #endif -#if defined(PNG_cHRM_SUPPORTED) +#ifdef PNG_cHRM_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED extern PNG_EXPORT(void,png_set_cHRM) PNGARG((png_structp png_ptr, png_infop info_ptr, double white_x, double white_y, double red_x, @@ -2237,7 +2388,7 @@ extern PNG_EXPORT(void,png_set_cHRM_fixed) PNGARG((png_structp png_ptr, #endif #endif -#if defined(PNG_gAMA_SUPPORTED) +#ifdef PNG_gAMA_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_gAMA) PNGARG((png_structp png_ptr, png_infop info_ptr, double *file_gamma)); @@ -2246,7 +2397,7 @@ extern PNG_EXPORT(png_uint_32,png_get_gAMA_fixed) PNGARG((png_structp png_ptr, png_infop info_ptr, png_fixed_point *int_file_gamma)); #endif -#if defined(PNG_gAMA_SUPPORTED) +#ifdef PNG_gAMA_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED extern PNG_EXPORT(void,png_set_gAMA) PNGARG((png_structp png_ptr, png_infop info_ptr, double file_gamma)); @@ -2255,12 +2406,12 @@ extern PNG_EXPORT(void,png_set_gAMA_fixed) PNGARG((png_structp png_ptr, png_infop info_ptr, png_fixed_point int_file_gamma)); #endif -#if defined(PNG_hIST_SUPPORTED) +#ifdef PNG_hIST_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_hIST) PNGARG((png_structp png_ptr, png_infop info_ptr, png_uint_16p *hist)); #endif -#if defined(PNG_hIST_SUPPORTED) +#ifdef PNG_hIST_SUPPORTED extern PNG_EXPORT(void,png_set_hIST) PNGARG((png_structp png_ptr, png_infop info_ptr, png_uint_16p hist)); #endif @@ -2275,36 +2426,36 @@ extern PNG_EXPORT(void,png_set_IHDR) PNGARG((png_structp png_ptr, int color_type, int interlace_method, int compression_method, int filter_method)); -#if defined(PNG_oFFs_SUPPORTED) +#ifdef PNG_oFFs_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_oFFs) PNGARG((png_structp png_ptr, png_infop info_ptr, png_int_32 *offset_x, png_int_32 *offset_y, int *unit_type)); #endif -#if defined(PNG_oFFs_SUPPORTED) +#ifdef PNG_oFFs_SUPPORTED extern PNG_EXPORT(void,png_set_oFFs) PNGARG((png_structp png_ptr, png_infop info_ptr, png_int_32 offset_x, png_int_32 offset_y, int unit_type)); #endif -#if defined(PNG_pCAL_SUPPORTED) +#ifdef PNG_pCAL_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_pCAL) PNGARG((png_structp png_ptr, png_infop info_ptr, png_charp *purpose, png_int_32 *X0, png_int_32 *X1, int *type, int *nparams, png_charp *units, png_charpp *params)); #endif -#if defined(PNG_pCAL_SUPPORTED) +#ifdef PNG_pCAL_SUPPORTED extern PNG_EXPORT(void,png_set_pCAL) PNGARG((png_structp png_ptr, png_infop info_ptr, png_charp purpose, png_int_32 X0, png_int_32 X1, int type, int nparams, png_charp units, png_charpp params)); #endif -#if defined(PNG_pHYs_SUPPORTED) +#ifdef PNG_pHYs_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_pHYs) PNGARG((png_structp png_ptr, png_infop info_ptr, png_uint_32 *res_x, png_uint_32 *res_y, int *unit_type)); #endif -#if defined(PNG_pHYs_SUPPORTED) +#ifdef PNG_pHYs_SUPPORTED extern PNG_EXPORT(void,png_set_pHYs) PNGARG((png_structp png_ptr, png_infop info_ptr, png_uint_32 res_x, png_uint_32 res_y, int unit_type)); #endif @@ -2315,53 +2466,53 @@ extern PNG_EXPORT(png_uint_32,png_get_PLTE) PNGARG((png_structp png_ptr, extern PNG_EXPORT(void,png_set_PLTE) PNGARG((png_structp png_ptr, png_infop info_ptr, png_colorp palette, int num_palette)); -#if defined(PNG_sBIT_SUPPORTED) +#ifdef PNG_sBIT_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_sBIT) PNGARG((png_structp png_ptr, png_infop info_ptr, png_color_8p *sig_bit)); #endif -#if defined(PNG_sBIT_SUPPORTED) +#ifdef PNG_sBIT_SUPPORTED extern PNG_EXPORT(void,png_set_sBIT) PNGARG((png_structp png_ptr, png_infop info_ptr, png_color_8p sig_bit)); #endif -#if defined(PNG_sRGB_SUPPORTED) +#ifdef PNG_sRGB_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_sRGB) PNGARG((png_structp png_ptr, png_infop info_ptr, int *intent)); #endif -#if defined(PNG_sRGB_SUPPORTED) +#ifdef PNG_sRGB_SUPPORTED extern PNG_EXPORT(void,png_set_sRGB) PNGARG((png_structp png_ptr, png_infop info_ptr, int intent)); extern PNG_EXPORT(void,png_set_sRGB_gAMA_and_cHRM) PNGARG((png_structp png_ptr, png_infop info_ptr, int intent)); #endif -#if defined(PNG_iCCP_SUPPORTED) +#ifdef PNG_iCCP_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_iCCP) PNGARG((png_structp png_ptr, png_infop info_ptr, png_charpp name, int *compression_type, png_charpp profile, png_uint_32 *proflen)); /* Note to maintainer: profile should be png_bytepp */ #endif -#if defined(PNG_iCCP_SUPPORTED) +#ifdef PNG_iCCP_SUPPORTED extern PNG_EXPORT(void,png_set_iCCP) PNGARG((png_structp png_ptr, png_infop info_ptr, png_charp name, int compression_type, png_charp profile, png_uint_32 proflen)); /* Note to maintainer: profile should be png_bytep */ #endif -#if defined(PNG_sPLT_SUPPORTED) +#ifdef PNG_sPLT_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_sPLT) PNGARG((png_structp png_ptr, png_infop info_ptr, png_sPLT_tpp entries)); #endif -#if defined(PNG_sPLT_SUPPORTED) +#ifdef PNG_sPLT_SUPPORTED extern PNG_EXPORT(void,png_set_sPLT) PNGARG((png_structp png_ptr, png_infop info_ptr, png_sPLT_tp entries, int nentries)); #endif -#if defined(PNG_TEXT_SUPPORTED) +#ifdef PNG_TEXT_SUPPORTED /* png_get_text also returns the number of text chunks in *num_text */ extern PNG_EXPORT(png_uint_32,png_get_text) PNGARG((png_structp png_ptr, png_infop info_ptr, png_textp *text_ptr, int *num_text)); @@ -2375,37 +2526,37 @@ extern PNG_EXPORT(png_uint_32,png_get_text) PNGARG((png_structp png_ptr, * they will never be NULL pointers. */ -#if defined(PNG_TEXT_SUPPORTED) +#ifdef PNG_TEXT_SUPPORTED extern PNG_EXPORT(void,png_set_text) PNGARG((png_structp png_ptr, png_infop info_ptr, png_textp text_ptr, int num_text)); #endif -#if defined(PNG_tIME_SUPPORTED) +#ifdef PNG_tIME_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_tIME) PNGARG((png_structp png_ptr, png_infop info_ptr, png_timep *mod_time)); #endif -#if defined(PNG_tIME_SUPPORTED) +#ifdef PNG_tIME_SUPPORTED extern PNG_EXPORT(void,png_set_tIME) PNGARG((png_structp png_ptr, png_infop info_ptr, png_timep mod_time)); #endif -#if defined(PNG_tRNS_SUPPORTED) +#ifdef PNG_tRNS_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_tRNS) PNGARG((png_structp png_ptr, png_infop info_ptr, png_bytep *trans, int *num_trans, png_color_16p *trans_values)); #endif -#if defined(PNG_tRNS_SUPPORTED) +#ifdef PNG_tRNS_SUPPORTED extern PNG_EXPORT(void,png_set_tRNS) PNGARG((png_structp png_ptr, png_infop info_ptr, png_bytep trans, int num_trans, png_color_16p trans_values)); #endif -#if defined(PNG_tRNS_SUPPORTED) +#ifdef PNG_tRNS_SUPPORTED #endif -#if defined(PNG_sCAL_SUPPORTED) +#ifdef PNG_sCAL_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED extern PNG_EXPORT(png_uint_32,png_get_sCAL) PNGARG((png_structp png_ptr, png_infop info_ptr, int *unit, double *width, double *height)); @@ -2417,7 +2568,7 @@ extern PNG_EXPORT(png_uint_32,png_get_sCAL_s) PNGARG((png_structp png_ptr, #endif #endif /* PNG_sCAL_SUPPORTED */ -#if defined(PNG_sCAL_SUPPORTED) +#ifdef PNG_sCAL_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED extern PNG_EXPORT(void,png_set_sCAL) PNGARG((png_structp png_ptr, png_infop info_ptr, int unit, double width, double height)); @@ -2429,8 +2580,8 @@ extern PNG_EXPORT(void,png_set_sCAL_s) PNGARG((png_structp png_ptr, #endif #endif /* PNG_sCAL_SUPPORTED || PNG_WRITE_sCAL_SUPPORTED */ -#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) -/* provide a list of chunks and how they are to be handled, if the built-in +#ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED +/* Provide a list of chunks and how they are to be handled, if the built-in handling or default unknown chunk handling is not desired. Any chunks not listed will be handled in the default manner. The IHDR and IEND chunks must not be listed. @@ -2441,6 +2592,10 @@ extern PNG_EXPORT(void,png_set_sCAL_s) PNGARG((png_structp png_ptr, */ extern PNG_EXPORT(void, png_set_keep_unknown_chunks) PNGARG((png_structp png_ptr, int keep, png_bytep chunk_list, int num_chunks)); +PNG_EXPORT(int,png_handle_as_unknown) PNGARG((png_structp png_ptr, png_bytep + chunk_name)); +#endif +#ifdef PNG_UNKNOWN_CHUNKS_SUPPORTED extern PNG_EXPORT(void, png_set_unknown_chunks) PNGARG((png_structp png_ptr, png_infop info_ptr, png_unknown_chunkp unknowns, int num_unknowns)); extern PNG_EXPORT(void, png_set_unknown_chunk_location) @@ -2448,18 +2603,15 @@ extern PNG_EXPORT(void, png_set_unknown_chunk_location) extern PNG_EXPORT(png_uint_32,png_get_unknown_chunks) PNGARG((png_structp png_ptr, png_infop info_ptr, png_unknown_chunkpp entries)); #endif -#ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED -PNG_EXPORT(int,png_handle_as_unknown) PNGARG((png_structp png_ptr, png_bytep - chunk_name)); -#endif /* Png_free_data() will turn off the "valid" flag for anything it frees. - If you need to turn it off for a chunk that your application has freed, - you can use png_set_invalid(png_ptr, info_ptr, PNG_INFO_CHNK); */ + * If you need to turn it off for a chunk that your application has freed, + * you can use png_set_invalid(png_ptr, info_ptr, PNG_INFO_CHNK); + */ extern PNG_EXPORT(void, png_set_invalid) PNGARG((png_structp png_ptr, png_infop info_ptr, int mask)); -#if defined(PNG_INFO_IMAGE_SUPPORTED) +#ifdef PNG_INFO_IMAGE_SUPPORTED /* The "params" pointer is currently not used and is for future expansion. */ extern PNG_EXPORT(void, png_read_png) PNGARG((png_structp png_ptr, png_infop info_ptr, @@ -2481,34 +2633,90 @@ extern PNG_EXPORT(void, png_write_png) PNGARG((png_structp png_ptr, #if !defined(PNG_DEBUG_FILE) && defined(_MSC_VER) #include #if (PNG_DEBUG > 1) -#define png_debug(l,m) _RPT0(_CRT_WARN,m) -#define png_debug1(l,m,p1) _RPT1(_CRT_WARN,m,p1) -#define png_debug2(l,m,p1,p2) _RPT2(_CRT_WARN,m,p1,p2) +#ifndef _DEBUG +# define _DEBUG +#endif +#ifndef png_debug +#define png_debug(l,m) _RPT0(_CRT_WARN,m PNG_STRING_NEWLINE) +#endif +#ifndef png_debug1 +#define png_debug1(l,m,p1) _RPT1(_CRT_WARN,m PNG_STRING_NEWLINE,p1) +#endif +#ifndef png_debug2 +#define png_debug2(l,m,p1,p2) _RPT2(_CRT_WARN,m PNG_STRING_NEWLINE,p1,p2) +#endif #endif #else /* PNG_DEBUG_FILE || !_MSC_VER */ #ifndef PNG_DEBUG_FILE #define PNG_DEBUG_FILE stderr #endif /* PNG_DEBUG_FILE */ + #if (PNG_DEBUG > 1) -#define png_debug(l,m) \ -{ \ - int num_tabs=l; \ - fprintf(PNG_DEBUG_FILE,"%s"m,(num_tabs==1 ? "\t" : \ - (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":"")))); \ -} -#define png_debug1(l,m,p1) \ -{ \ - int num_tabs=l; \ - fprintf(PNG_DEBUG_FILE,"%s"m,(num_tabs==1 ? "\t" : \ - (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))),p1); \ -} -#define png_debug2(l,m,p1,p2) \ -{ \ - int num_tabs=l; \ - fprintf(PNG_DEBUG_FILE,"%s"m,(num_tabs==1 ? "\t" : \ - (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))),p1,p2); \ -} +/* Note: ["%s"m PNG_STRING_NEWLINE] probably does not work on non-ISO + * compilers. + */ +# ifdef __STDC__ +# ifndef png_debug +# define png_debug(l,m) \ + { \ + int num_tabs=l; \ + fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ + (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":"")))); \ + } +# endif +# ifndef png_debug1 +# define png_debug1(l,m,p1) \ + { \ + int num_tabs=l; \ + fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ + (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))),p1); \ + } +# endif +# ifndef png_debug2 +# define png_debug2(l,m,p1,p2) \ + { \ + int num_tabs=l; \ + fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ + (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))),p1,p2); \ + } +# endif +# else /* __STDC __ */ +# ifndef png_debug +# define png_debug(l,m) \ + { \ + int num_tabs=l; \ + char format[256]; \ + snprintf(format,256,"%s%s%s",(num_tabs==1 ? "\t" : \ + (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))), \ + m,PNG_STRING_NEWLINE); \ + fprintf(PNG_DEBUG_FILE,format); \ + } +# endif +# ifndef png_debug1 +# define png_debug1(l,m,p1) \ + { \ + int num_tabs=l; \ + char format[256]; \ + snprintf(format,256,"%s%s%s",(num_tabs==1 ? "\t" : \ + (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))), \ + m,PNG_STRING_NEWLINE); \ + fprintf(PNG_DEBUG_FILE,format,p1); \ + } +# endif +# ifndef png_debug2 +# define png_debug2(l,m,p1,p2) \ + { \ + int num_tabs=l; \ + char format[256]; \ + snprintf(format,256,"%s%s%s",(num_tabs==1 ? "\t" : \ + (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))), \ + m,PNG_STRING_NEWLINE); \ + fprintf(PNG_DEBUG_FILE,format,p1,p2); \ + } +# endif +# endif /* __STDC __ */ #endif /* (PNG_DEBUG > 1) */ + #endif /* _MSC_VER */ #endif /* (PNG_DEBUG > 0) */ #endif /* PNG_DEBUG */ @@ -2539,8 +2747,8 @@ extern PNG_EXPORT(png_uint_32,png_permit_mng_features) PNGARG((png_structp #define PNG_HANDLE_CHUNK_ALWAYS 3 /* Added to version 1.2.0 */ -#if defined(PNG_ASSEMBLER_CODE_SUPPORTED) -#if defined(PNG_MMX_CODE_SUPPORTED) +#ifdef PNG_ASSEMBLER_CODE_SUPPORTED +#ifdef PNG_MMX_CODE_SUPPORTED #define PNG_ASM_FLAG_MMX_SUPPORT_COMPILED 0x01 /* not user-settable */ #define PNG_ASM_FLAG_MMX_SUPPORT_IN_CPU 0x02 /* not user-settable */ #define PNG_ASM_FLAG_MMX_READ_COMBINE_ROW 0x04 @@ -2568,7 +2776,7 @@ extern PNG_EXPORT(png_uint_32,png_permit_mng_features) PNGARG((png_structp #define PNG_SELECT_WRITE 2 #endif /* PNG_MMX_CODE_SUPPORTED */ -#if !defined(PNG_1_0_X) +#ifndef PNG_1_0_X /* pngget.c */ extern PNG_EXPORT(png_uint_32,png_get_mmx_flagmask) PNGARG((int flag_select, int *compilerID)); @@ -2600,20 +2808,20 @@ extern PNG_EXPORT(void,png_set_mmx_thresholds) #endif /* PNG_1_0_X */ -#if !defined(PNG_1_0_X) +#ifndef PNG_1_0_X /* png.c, pnggccrd.c, or pngvcrd.c */ extern PNG_EXPORT(int,png_mmx_support) PNGARG((void)); +#endif /* PNG_1_0_X */ #endif /* PNG_ASSEMBLER_CODE_SUPPORTED */ /* Strip the prepended error numbers ("#nnn ") from error and warning - * messages before passing them to the error or warning handler. */ + * messages before passing them to the error or warning handler. + */ #ifdef PNG_ERROR_NUMBERS_SUPPORTED extern PNG_EXPORT(void,png_set_strip_error_numbers) PNGARG((png_structp png_ptr, png_uint_32 strip_mode)); #endif -#endif /* PNG_1_0_X */ - /* Added at libpng-1.2.6 */ #ifdef PNG_SET_USER_LIMITS_SUPPORTED extern PNG_EXPORT(void,png_set_user_limits) PNGARG((png_structp @@ -2623,8 +2831,9 @@ extern PNG_EXPORT(png_uint_32,png_get_user_width_max) PNGARG((png_structp extern PNG_EXPORT(png_uint_32,png_get_user_height_max) PNGARG((png_structp png_ptr)); #endif - -/* Maintainer: Put new public prototypes here ^, in libpng.3, and project defs */ +/* Maintainer: Put new public prototypes here ^, in libpng.3, and in + * project defs + */ #ifdef PNG_READ_COMPOSITE_NODIV_SUPPORTED /* With these routines we avoid an integer divide, which will be slower on @@ -2653,7 +2862,7 @@ extern PNG_EXPORT(png_uint_32,png_get_user_height_max) PNGARG((png_structp (png_uint_32)(alpha)) + (png_uint_32)32768L); \ (composite) = (png_uint_16)((temp + (temp >> 16)) >> 16); } -#else /* standard method using integer division */ +#else /* Standard method using integer division */ # define png_composite(composite, fg, alpha, bg) \ (composite) = (png_byte)(((png_uint_16)(fg) * (png_uint_16)(alpha) + \ @@ -2675,7 +2884,7 @@ extern PNG_EXPORT(png_uint_32,png_get_user_height_max) PNGARG((png_structp * routine also assumes we are using two's complement format for negative * values, which is almost certainly true. */ -#if defined(PNG_READ_BIG_ENDIAN_SUPPORTED) +#ifdef PNG_READ_BIG_ENDIAN_SUPPORTED # define png_get_uint_32(buf) ( *((png_uint_32p) (buf))) # define png_get_uint_16(buf) ( *((png_uint_16p) (buf))) # define png_get_int_32(buf) ( *((png_int_32p) (buf))) @@ -2721,7 +2930,7 @@ extern PNG_EXPORT(void,png_save_uint_16) #define PNG_AFTER_IDAT 0x08 /* Have complete zlib datastream */ #define PNG_HAVE_IEND 0x10 -#if defined(PNG_INTERNAL) +#ifdef PNG_INTERNAL /* More modes of operation. Note that after an init, mode is set to * zero automatically when the structure is created. @@ -2736,7 +2945,7 @@ extern PNG_EXPORT(void,png_save_uint_16) #define PNG_HAVE_PNG_SIGNATURE 0x1000 #define PNG_HAVE_CHUNK_AFTER_IDAT 0x2000 /* Have another chunk after IDAT */ -/* flags for the transformations the PNG library does on the image data */ +/* Flags for the transformations the PNG library does on the image data */ #define PNG_BGR 0x0001 #define PNG_INTERLACE 0x0002 #define PNG_PACK 0x0004 @@ -2764,13 +2973,14 @@ extern PNG_EXPORT(void,png_save_uint_16) /* 0x800000L Unused */ #define PNG_ADD_ALPHA 0x1000000L /* Added to libpng-1.2.7 */ #define PNG_EXPAND_tRNS 0x2000000L /* Added to libpng-1.2.9 */ - /* 0x4000000L unused */ +#define PNG_PREMULTIPLY_ALPHA 0x4000000L /* Added to libpng-1.2.41 */ + /* by volker */ /* 0x8000000L unused */ /* 0x10000000L unused */ /* 0x20000000L unused */ /* 0x40000000L unused */ -/* flags for png_create_struct */ +/* Flags for png_create_struct */ #define PNG_STRUCT_PNG 0x0001 #define PNG_STRUCT_INFO 0x0002 @@ -2780,7 +2990,7 @@ extern PNG_EXPORT(void,png_save_uint_16) #define PNG_COST_SHIFT 3 #define PNG_COST_FACTOR (1<<(PNG_COST_SHIFT)) -/* flags for the png_ptr->flags rather than declaring a byte for each one */ +/* Flags for the png_ptr->flags rather than declaring a byte for each one */ #define PNG_FLAG_ZLIB_CUSTOM_STRATEGY 0x0001 #define PNG_FLAG_ZLIB_CUSTOM_LEVEL 0x0002 #define PNG_FLAG_ZLIB_CUSTOM_MEM_LEVEL 0x0004 @@ -2822,7 +3032,7 @@ extern PNG_EXPORT(void,png_save_uint_16) #define PNG_FLAG_CRC_MASK (PNG_FLAG_CRC_ANCILLARY_MASK | \ PNG_FLAG_CRC_CRITICAL_MASK) -/* save typing and make code easier to understand */ +/* Save typing and make code easier to understand */ #define PNG_COLOR_DIST(c1, c2) (abs((int)((c1).red) - (int)((c2).red)) + \ abs((int)((c1).green) - (int)((c2).green)) + \ @@ -2835,15 +3045,16 @@ extern PNG_EXPORT(void,png_save_uint_16) (( ((width) * ((png_uint_32)(pixel_bits))) + 7) >> 3) ) /* PNG_OUT_OF_RANGE returns true if value is outside the range - ideal-delta..ideal+delta. Each argument is evaluated twice. - "ideal" and "delta" should be constants, normally simple - integers, "value" a variable. Added to libpng-1.2.6 JB */ + * ideal-delta..ideal+delta. Each argument is evaluated twice. + * "ideal" and "delta" should be constants, normally simple + * integers, "value" a variable. Added to libpng-1.2.6 JB + */ #define PNG_OUT_OF_RANGE(value, ideal, delta) \ ( (value) < (ideal)-(delta) || (value) > (ideal)+(delta) ) -/* variables declared in png.c - only it needs to define PNG_NO_EXTERN */ +/* Variables declared in png.c - only it needs to define PNG_NO_EXTERN */ #if !defined(PNG_NO_EXTERN) || defined(PNG_ALWAYS_EXTERN) -/* place to hold the signature string for a PNG file. */ +/* Place to hold the signature string for a PNG file. */ #ifdef PNG_USE_GLOBAL_ARRAYS PNG_EXPORT_VAR (PNG_CONST png_byte FARDATA) png_sig[8]; #else @@ -2904,7 +3115,8 @@ PNG_EXPORT_VAR (png_byte FARDATA) png_zTXt[5]; /* Initialize png_ptr struct for reading, and allocate any other memory. * (old interface - DEPRECATED - use png_create_read_struct instead). */ -extern PNG_EXPORT(void,png_read_init) PNGARG((png_structp png_ptr)); +extern PNG_EXPORT(void,png_read_init) PNGARG((png_structp png_ptr)) + PNG_DEPRECATED; #undef png_read_init #define png_read_init(png_ptr) png_read_init_3(&png_ptr, \ PNG_LIBPNG_VER_STRING, png_sizeof(png_struct)); @@ -2922,7 +3134,8 @@ extern PNG_EXPORT(void,png_read_init_2) PNGARG((png_structp png_ptr, /* Initialize png_ptr struct for writing, and allocate any other memory. * (old interface - DEPRECATED - use png_create_write_struct instead). */ -extern PNG_EXPORT(void,png_write_init) PNGARG((png_structp png_ptr)); +extern PNG_EXPORT(void,png_write_init) PNGARG((png_structp png_ptr)) + PNG_DEPRECATED; #undef png_write_init #define png_write_init(png_ptr) png_write_init_3(&png_ptr, \ PNG_LIBPNG_VER_STRING, png_sizeof(png_struct)); @@ -2935,102 +3148,107 @@ extern PNG_EXPORT(void,png_write_init_2) PNGARG((png_structp png_ptr, png_info_size)); /* Allocate memory for an internal libpng struct */ -PNG_EXTERN png_voidp png_create_struct PNGARG((int type)); +PNG_EXTERN png_voidp png_create_struct PNGARG((int type)) PNG_PRIVATE; /* Free memory from internal libpng struct */ -PNG_EXTERN void png_destroy_struct PNGARG((png_voidp struct_ptr)); +PNG_EXTERN void png_destroy_struct PNGARG((png_voidp struct_ptr)) PNG_PRIVATE; PNG_EXTERN png_voidp png_create_struct_2 PNGARG((int type, png_malloc_ptr - malloc_fn, png_voidp mem_ptr)); + malloc_fn, png_voidp mem_ptr)) PNG_PRIVATE; PNG_EXTERN void png_destroy_struct_2 PNGARG((png_voidp struct_ptr, - png_free_ptr free_fn, png_voidp mem_ptr)); + png_free_ptr free_fn, png_voidp mem_ptr)) PNG_PRIVATE; /* Free any memory that info_ptr points to and reset struct. */ PNG_EXTERN void png_info_destroy PNGARG((png_structp png_ptr, - png_infop info_ptr)); + png_infop info_ptr)) PNG_PRIVATE; #ifndef PNG_1_0_X /* Function to allocate memory for zlib. */ -PNG_EXTERN voidpf png_zalloc PNGARG((voidpf png_ptr, uInt items, uInt size)); +PNG_EXTERN voidpf png_zalloc PNGARG((voidpf png_ptr, uInt items, + uInt size)) PNG_PRIVATE; /* Function to free memory for zlib */ -PNG_EXTERN void png_zfree PNGARG((voidpf png_ptr, voidpf ptr)); +PNG_EXTERN void png_zfree PNGARG((voidpf png_ptr, voidpf ptr)) PNG_PRIVATE; #ifdef PNG_SIZE_T /* Function to convert a sizeof an item to png_sizeof item */ - PNG_EXTERN png_size_t PNGAPI png_convert_size PNGARG((size_t size)); + PNG_EXTERN png_size_t PNGAPI png_convert_size PNGARG((size_t size)) + PNG_PRIVATE; #endif /* Next four functions are used internally as callbacks. PNGAPI is required - * but not PNG_EXPORT. PNGAPI added at libpng version 1.2.3. */ + * but not PNG_EXPORT. PNGAPI added at libpng version 1.2.3. + */ PNG_EXTERN void PNGAPI png_default_read_data PNGARG((png_structp png_ptr, - png_bytep data, png_size_t length)); + png_bytep data, png_size_t length)) PNG_PRIVATE; #ifdef PNG_PROGRESSIVE_READ_SUPPORTED PNG_EXTERN void PNGAPI png_push_fill_buffer PNGARG((png_structp png_ptr, - png_bytep buffer, png_size_t length)); + png_bytep buffer, png_size_t length)) PNG_PRIVATE; #endif PNG_EXTERN void PNGAPI png_default_write_data PNGARG((png_structp png_ptr, - png_bytep data, png_size_t length)); + png_bytep data, png_size_t length)) PNG_PRIVATE; -#if defined(PNG_WRITE_FLUSH_SUPPORTED) -#if !defined(PNG_NO_STDIO) -PNG_EXTERN void PNGAPI png_default_flush PNGARG((png_structp png_ptr)); +#ifdef PNG_WRITE_FLUSH_SUPPORTED +#ifdef PNG_STDIO_SUPPORTED +PNG_EXTERN void PNGAPI png_default_flush PNGARG((png_structp png_ptr)) + PNG_PRIVATE; #endif #endif #else /* PNG_1_0_X */ #ifdef PNG_PROGRESSIVE_READ_SUPPORTED PNG_EXTERN void png_push_fill_buffer PNGARG((png_structp png_ptr, - png_bytep buffer, png_size_t length)); + png_bytep buffer, png_size_t length)) PNG_PRIVATE; #endif #endif /* PNG_1_0_X */ /* Reset the CRC variable */ -PNG_EXTERN void png_reset_crc PNGARG((png_structp png_ptr)); +PNG_EXTERN void png_reset_crc PNGARG((png_structp png_ptr)) PNG_PRIVATE; /* Write the "data" buffer to whatever output you are using. */ PNG_EXTERN void png_write_data PNGARG((png_structp png_ptr, png_bytep data, - png_size_t length)); + png_size_t length)) PNG_PRIVATE; /* Read data from whatever input you are using into the "data" buffer */ PNG_EXTERN void png_read_data PNGARG((png_structp png_ptr, png_bytep data, - png_size_t length)); + png_size_t length)) PNG_PRIVATE; /* Read bytes into buf, and update png_ptr->crc */ PNG_EXTERN void png_crc_read PNGARG((png_structp png_ptr, png_bytep buf, - png_size_t length)); + png_size_t length)) PNG_PRIVATE; /* Decompress data in a chunk that uses compression */ #if defined(PNG_zTXt_SUPPORTED) || defined(PNG_iTXt_SUPPORTED) || \ defined(PNG_iCCP_SUPPORTED) || defined(PNG_sPLT_SUPPORTED) -PNG_EXTERN png_charp png_decompress_chunk PNGARG((png_structp png_ptr, - int comp_type, png_charp chunkdata, png_size_t chunklength, - png_size_t prefix_length, png_size_t *data_length)); +PNG_EXTERN void png_decompress_chunk PNGARG((png_structp png_ptr, + int comp_type, png_size_t chunklength, + png_size_t prefix_length, png_size_t *data_length)) PNG_PRIVATE; #endif /* Read "skip" bytes, read the file crc, and (optionally) verify png_ptr->crc */ -PNG_EXTERN int png_crc_finish PNGARG((png_structp png_ptr, png_uint_32 skip)); +PNG_EXTERN int png_crc_finish PNGARG((png_structp png_ptr, png_uint_32 skip) + PNG_PRIVATE); /* Read the CRC from the file and compare it to the libpng calculated CRC */ -PNG_EXTERN int png_crc_error PNGARG((png_structp png_ptr)); +PNG_EXTERN int png_crc_error PNGARG((png_structp png_ptr)) PNG_PRIVATE; /* Calculate the CRC over a section of data. Note that we are only * passing a maximum of 64K on systems that have this as a memory limit, * since this is the maximum buffer size we can specify. */ PNG_EXTERN void png_calculate_crc PNGARG((png_structp png_ptr, png_bytep ptr, - png_size_t length)); + png_size_t length)) PNG_PRIVATE; -#if defined(PNG_WRITE_FLUSH_SUPPORTED) -PNG_EXTERN void png_flush PNGARG((png_structp png_ptr)); +#ifdef PNG_WRITE_FLUSH_SUPPORTED +PNG_EXTERN void png_flush PNGARG((png_structp png_ptr)) PNG_PRIVATE; #endif -/* simple function to write the signature */ -PNG_EXTERN void png_write_sig PNGARG((png_structp png_ptr)); +/* Simple function to write the signature */ +PNG_EXTERN void png_write_sig PNGARG((png_structp png_ptr)) PNG_PRIVATE; -/* write various chunks */ +/* Write various chunks */ /* Write the IHDR chunk, and update the png_struct with the necessary * information. @@ -3038,481 +3256,498 @@ PNG_EXTERN void png_write_sig PNGARG((png_structp png_ptr)); PNG_EXTERN void png_write_IHDR PNGARG((png_structp png_ptr, png_uint_32 width, png_uint_32 height, int bit_depth, int color_type, int compression_method, int filter_method, - int interlace_method)); + int interlace_method)) PNG_PRIVATE; PNG_EXTERN void png_write_PLTE PNGARG((png_structp png_ptr, png_colorp palette, - png_uint_32 num_pal)); + png_uint_32 num_pal)) PNG_PRIVATE; PNG_EXTERN void png_write_IDAT PNGARG((png_structp png_ptr, png_bytep data, - png_size_t length)); + png_size_t length)) PNG_PRIVATE; -PNG_EXTERN void png_write_IEND PNGARG((png_structp png_ptr)); +PNG_EXTERN void png_write_IEND PNGARG((png_structp png_ptr)) PNG_PRIVATE; -#if defined(PNG_WRITE_gAMA_SUPPORTED) +#ifdef PNG_WRITE_gAMA_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED -PNG_EXTERN void png_write_gAMA PNGARG((png_structp png_ptr, double file_gamma)); +PNG_EXTERN void png_write_gAMA PNGARG((png_structp png_ptr, double file_gamma)) + PNG_PRIVATE; #endif #ifdef PNG_FIXED_POINT_SUPPORTED -PNG_EXTERN void png_write_gAMA_fixed PNGARG((png_structp png_ptr, png_fixed_point - file_gamma)); +PNG_EXTERN void png_write_gAMA_fixed PNGARG((png_structp png_ptr, + png_fixed_point file_gamma)) PNG_PRIVATE; #endif #endif -#if defined(PNG_WRITE_sBIT_SUPPORTED) +#ifdef PNG_WRITE_sBIT_SUPPORTED PNG_EXTERN void png_write_sBIT PNGARG((png_structp png_ptr, png_color_8p sbit, - int color_type)); + int color_type)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_cHRM_SUPPORTED) +#ifdef PNG_WRITE_cHRM_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED PNG_EXTERN void png_write_cHRM PNGARG((png_structp png_ptr, double white_x, double white_y, double red_x, double red_y, double green_x, double green_y, - double blue_x, double blue_y)); + double blue_x, double blue_y)) PNG_PRIVATE; #endif #ifdef PNG_FIXED_POINT_SUPPORTED PNG_EXTERN void png_write_cHRM_fixed PNGARG((png_structp png_ptr, png_fixed_point int_white_x, png_fixed_point int_white_y, png_fixed_point int_red_x, png_fixed_point int_red_y, png_fixed_point int_green_x, png_fixed_point int_green_y, png_fixed_point int_blue_x, - png_fixed_point int_blue_y)); + png_fixed_point int_blue_y)) PNG_PRIVATE; #endif #endif -#if defined(PNG_WRITE_sRGB_SUPPORTED) +#ifdef PNG_WRITE_sRGB_SUPPORTED PNG_EXTERN void png_write_sRGB PNGARG((png_structp png_ptr, - int intent)); + int intent)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_iCCP_SUPPORTED) +#ifdef PNG_WRITE_iCCP_SUPPORTED PNG_EXTERN void png_write_iCCP PNGARG((png_structp png_ptr, png_charp name, int compression_type, - png_charp profile, int proflen)); + png_charp profile, int proflen)) PNG_PRIVATE; /* Note to maintainer: profile should be png_bytep */ #endif -#if defined(PNG_WRITE_sPLT_SUPPORTED) +#ifdef PNG_WRITE_sPLT_SUPPORTED PNG_EXTERN void png_write_sPLT PNGARG((png_structp png_ptr, - png_sPLT_tp palette)); + png_sPLT_tp palette)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_tRNS_SUPPORTED) +#ifdef PNG_WRITE_tRNS_SUPPORTED PNG_EXTERN void png_write_tRNS PNGARG((png_structp png_ptr, png_bytep trans, - png_color_16p values, int number, int color_type)); + png_color_16p values, int number, int color_type)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_bKGD_SUPPORTED) +#ifdef PNG_WRITE_bKGD_SUPPORTED PNG_EXTERN void png_write_bKGD PNGARG((png_structp png_ptr, - png_color_16p values, int color_type)); + png_color_16p values, int color_type)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_hIST_SUPPORTED) +#ifdef PNG_WRITE_hIST_SUPPORTED PNG_EXTERN void png_write_hIST PNGARG((png_structp png_ptr, png_uint_16p hist, - int num_hist)); + int num_hist)) PNG_PRIVATE; #endif #if defined(PNG_WRITE_TEXT_SUPPORTED) || defined(PNG_WRITE_pCAL_SUPPORTED) || \ defined(PNG_WRITE_iCCP_SUPPORTED) || defined(PNG_WRITE_sPLT_SUPPORTED) PNG_EXTERN png_size_t png_check_keyword PNGARG((png_structp png_ptr, - png_charp key, png_charpp new_key)); + png_charp key, png_charpp new_key)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_tEXt_SUPPORTED) +#ifdef PNG_WRITE_tEXt_SUPPORTED PNG_EXTERN void png_write_tEXt PNGARG((png_structp png_ptr, png_charp key, - png_charp text, png_size_t text_len)); + png_charp text, png_size_t text_len)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_zTXt_SUPPORTED) +#ifdef PNG_WRITE_zTXt_SUPPORTED PNG_EXTERN void png_write_zTXt PNGARG((png_structp png_ptr, png_charp key, - png_charp text, png_size_t text_len, int compression)); + png_charp text, png_size_t text_len, int compression)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_iTXt_SUPPORTED) +#ifdef PNG_WRITE_iTXt_SUPPORTED PNG_EXTERN void png_write_iTXt PNGARG((png_structp png_ptr, int compression, png_charp key, png_charp lang, png_charp lang_key, - png_charp text)); + png_charp text)) PNG_PRIVATE; #endif -#if defined(PNG_TEXT_SUPPORTED) /* Added at version 1.0.14 and 1.2.4 */ +#ifdef PNG_TEXT_SUPPORTED /* Added at version 1.0.14 and 1.2.4 */ PNG_EXTERN int png_set_text_2 PNGARG((png_structp png_ptr, - png_infop info_ptr, png_textp text_ptr, int num_text)); + png_infop info_ptr, png_textp text_ptr, int num_text)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_oFFs_SUPPORTED) +#ifdef PNG_WRITE_oFFs_SUPPORTED PNG_EXTERN void png_write_oFFs PNGARG((png_structp png_ptr, - png_int_32 x_offset, png_int_32 y_offset, int unit_type)); + png_int_32 x_offset, png_int_32 y_offset, int unit_type)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_pCAL_SUPPORTED) +#ifdef PNG_WRITE_pCAL_SUPPORTED PNG_EXTERN void png_write_pCAL PNGARG((png_structp png_ptr, png_charp purpose, png_int_32 X0, png_int_32 X1, int type, int nparams, - png_charp units, png_charpp params)); + png_charp units, png_charpp params)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_pHYs_SUPPORTED) +#ifdef PNG_WRITE_pHYs_SUPPORTED PNG_EXTERN void png_write_pHYs PNGARG((png_structp png_ptr, png_uint_32 x_pixels_per_unit, png_uint_32 y_pixels_per_unit, - int unit_type)); + int unit_type)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_tIME_SUPPORTED) +#ifdef PNG_WRITE_tIME_SUPPORTED PNG_EXTERN void png_write_tIME PNGARG((png_structp png_ptr, - png_timep mod_time)); + png_timep mod_time)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_sCAL_SUPPORTED) +#ifdef PNG_WRITE_sCAL_SUPPORTED #if defined(PNG_FLOATING_POINT_SUPPORTED) && !defined(PNG_NO_STDIO) PNG_EXTERN void png_write_sCAL PNGARG((png_structp png_ptr, - int unit, double width, double height)); + int unit, double width, double height)) PNG_PRIVATE; #else #ifdef PNG_FIXED_POINT_SUPPORTED PNG_EXTERN void png_write_sCAL_s PNGARG((png_structp png_ptr, - int unit, png_charp width, png_charp height)); + int unit, png_charp width, png_charp height)) PNG_PRIVATE; #endif #endif #endif /* Called when finished processing a row of data */ -PNG_EXTERN void png_write_finish_row PNGARG((png_structp png_ptr)); +PNG_EXTERN void png_write_finish_row PNGARG((png_structp png_ptr)) PNG_PRIVATE; /* Internal use only. Called before first row of data */ -PNG_EXTERN void png_write_start_row PNGARG((png_structp png_ptr)); +PNG_EXTERN void png_write_start_row PNGARG((png_structp png_ptr)) PNG_PRIVATE; -#if defined(PNG_READ_GAMMA_SUPPORTED) -PNG_EXTERN void png_build_gamma_table PNGARG((png_structp png_ptr)); +#ifdef PNG_READ_GAMMA_SUPPORTED +PNG_EXTERN void png_build_gamma_table PNGARG((png_structp png_ptr)) PNG_PRIVATE; #endif -/* combine a row of data, dealing with alpha, etc. if requested */ +/* Combine a row of data, dealing with alpha, etc. if requested */ PNG_EXTERN void png_combine_row PNGARG((png_structp png_ptr, png_bytep row, - int mask)); + int mask)) PNG_PRIVATE; -#if defined(PNG_READ_INTERLACING_SUPPORTED) -/* expand an interlaced row */ +#ifdef PNG_READ_INTERLACING_SUPPORTED +/* Expand an interlaced row */ /* OLD pre-1.0.9 interface: PNG_EXTERN void png_do_read_interlace PNGARG((png_row_infop row_info, - png_bytep row, int pass, png_uint_32 transformations)); + png_bytep row, int pass, png_uint_32 transformations)) PNG_PRIVATE; */ -PNG_EXTERN void png_do_read_interlace PNGARG((png_structp png_ptr)); +PNG_EXTERN void png_do_read_interlace PNGARG((png_structp png_ptr)) PNG_PRIVATE; #endif /* GRR TO DO (2.0 or whenever): simplify other internal calling interfaces */ -#if defined(PNG_WRITE_INTERLACING_SUPPORTED) -/* grab pixels out of a row for an interlaced pass */ +#ifdef PNG_WRITE_INTERLACING_SUPPORTED +/* Grab pixels out of a row for an interlaced pass */ PNG_EXTERN void png_do_write_interlace PNGARG((png_row_infop row_info, - png_bytep row, int pass)); + png_bytep row, int pass)) PNG_PRIVATE; #endif -/* unfilter a row */ +/* Unfilter a row */ PNG_EXTERN void png_read_filter_row PNGARG((png_structp png_ptr, - png_row_infop row_info, png_bytep row, png_bytep prev_row, int filter)); + png_row_infop row_info, png_bytep row, png_bytep prev_row, + int filter)) PNG_PRIVATE; /* Choose the best filter to use and filter the row data */ PNG_EXTERN void png_write_find_filter PNGARG((png_structp png_ptr, - png_row_infop row_info)); + png_row_infop row_info)) PNG_PRIVATE; /* Write out the filtered row. */ PNG_EXTERN void png_write_filtered_row PNGARG((png_structp png_ptr, - png_bytep filtered_row)); -/* finish a row while reading, dealing with interlacing passes, etc. */ + png_bytep filtered_row)) PNG_PRIVATE; +/* Finish a row while reading, dealing with interlacing passes, etc. */ PNG_EXTERN void png_read_finish_row PNGARG((png_structp png_ptr)); -/* initialize the row buffers, etc. */ -PNG_EXTERN void png_read_start_row PNGARG((png_structp png_ptr)); -/* optional call to update the users info structure */ +/* Initialize the row buffers, etc. */ +PNG_EXTERN void png_read_start_row PNGARG((png_structp png_ptr)) PNG_PRIVATE; +/* Optional call to update the users info structure */ PNG_EXTERN void png_read_transform_info PNGARG((png_structp png_ptr, - png_infop info_ptr)); + png_infop info_ptr)) PNG_PRIVATE; -/* these are the functions that do the transformations */ -#if defined(PNG_READ_FILLER_SUPPORTED) +/* These are the functions that do the transformations */ +#ifdef PNG_READ_FILLER_SUPPORTED PNG_EXTERN void png_do_read_filler PNGARG((png_row_infop row_info, - png_bytep row, png_uint_32 filler, png_uint_32 flags)); + png_bytep row, png_uint_32 filler, png_uint_32 flags)) PNG_PRIVATE; #endif -#if defined(PNG_READ_SWAP_ALPHA_SUPPORTED) +#ifdef PNG_READ_SWAP_ALPHA_SUPPORTED PNG_EXTERN void png_do_read_swap_alpha PNGARG((png_row_infop row_info, - png_bytep row)); + png_bytep row)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_SWAP_ALPHA_SUPPORTED) +#ifdef PNG_WRITE_SWAP_ALPHA_SUPPORTED PNG_EXTERN void png_do_write_swap_alpha PNGARG((png_row_infop row_info, - png_bytep row)); + png_bytep row)) PNG_PRIVATE; #endif -#if defined(PNG_READ_INVERT_ALPHA_SUPPORTED) +#ifdef PNG_READ_INVERT_ALPHA_SUPPORTED PNG_EXTERN void png_do_read_invert_alpha PNGARG((png_row_infop row_info, - png_bytep row)); + png_bytep row)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_INVERT_ALPHA_SUPPORTED) +#ifdef PNG_WRITE_INVERT_ALPHA_SUPPORTED PNG_EXTERN void png_do_write_invert_alpha PNGARG((png_row_infop row_info, - png_bytep row)); + png_bytep row)) PNG_PRIVATE; #endif #if defined(PNG_WRITE_FILLER_SUPPORTED) || \ defined(PNG_READ_STRIP_ALPHA_SUPPORTED) PNG_EXTERN void png_do_strip_filler PNGARG((png_row_infop row_info, - png_bytep row, png_uint_32 flags)); + png_bytep row, png_uint_32 flags)) PNG_PRIVATE; #endif #if defined(PNG_READ_SWAP_SUPPORTED) || defined(PNG_WRITE_SWAP_SUPPORTED) -PNG_EXTERN void png_do_swap PNGARG((png_row_infop row_info, png_bytep row)); +PNG_EXTERN void png_do_swap PNGARG((png_row_infop row_info, + png_bytep row)) PNG_PRIVATE; #endif #if defined(PNG_READ_PACKSWAP_SUPPORTED) || defined(PNG_WRITE_PACKSWAP_SUPPORTED) -PNG_EXTERN void png_do_packswap PNGARG((png_row_infop row_info, png_bytep row)); +PNG_EXTERN void png_do_packswap PNGARG((png_row_infop row_info, + png_bytep row)) PNG_PRIVATE; #endif -#if defined(PNG_READ_RGB_TO_GRAY_SUPPORTED) +#ifdef PNG_READ_RGB_TO_GRAY_SUPPORTED PNG_EXTERN int png_do_rgb_to_gray PNGARG((png_structp png_ptr, png_row_infop - row_info, png_bytep row)); + row_info, png_bytep row)) PNG_PRIVATE; #endif -#if defined(PNG_READ_GRAY_TO_RGB_SUPPORTED) +#ifdef PNG_READ_GRAY_TO_RGB_SUPPORTED PNG_EXTERN void png_do_gray_to_rgb PNGARG((png_row_infop row_info, - png_bytep row)); + png_bytep row)) PNG_PRIVATE; #endif -#if defined(PNG_READ_PACK_SUPPORTED) -PNG_EXTERN void png_do_unpack PNGARG((png_row_infop row_info, png_bytep row)); +#ifdef PNG_READ_PACK_SUPPORTED +PNG_EXTERN void png_do_unpack PNGARG((png_row_infop row_info, + png_bytep row)) PNG_PRIVATE; #endif -#if defined(PNG_READ_SHIFT_SUPPORTED) +#ifdef PNG_READ_SHIFT_SUPPORTED PNG_EXTERN void png_do_unshift PNGARG((png_row_infop row_info, png_bytep row, - png_color_8p sig_bits)); + png_color_8p sig_bits)) PNG_PRIVATE; #endif #if defined(PNG_READ_INVERT_SUPPORTED) || defined(PNG_WRITE_INVERT_SUPPORTED) -PNG_EXTERN void png_do_invert PNGARG((png_row_infop row_info, png_bytep row)); +PNG_EXTERN void png_do_invert PNGARG((png_row_infop row_info, + png_bytep row)) PNG_PRIVATE; #endif -#if defined(PNG_READ_16_TO_8_SUPPORTED) -PNG_EXTERN void png_do_chop PNGARG((png_row_infop row_info, png_bytep row)); +#ifdef PNG_READ_16_TO_8_SUPPORTED +PNG_EXTERN void png_do_chop PNGARG((png_row_infop row_info, + png_bytep row)) PNG_PRIVATE; #endif -#if defined(PNG_READ_DITHER_SUPPORTED) +#ifdef PNG_READ_DITHER_SUPPORTED PNG_EXTERN void png_do_dither PNGARG((png_row_infop row_info, - png_bytep row, png_bytep palette_lookup, png_bytep dither_lookup)); + png_bytep row, png_bytep palette_lookup, + png_bytep dither_lookup)) PNG_PRIVATE; -# if defined(PNG_CORRECT_PALETTE_SUPPORTED) +# ifdef PNG_CORRECT_PALETTE_SUPPORTED PNG_EXTERN void png_correct_palette PNGARG((png_structp png_ptr, - png_colorp palette, int num_palette)); + png_colorp palette, int num_palette)) PNG_PRIVATE; # endif #endif #if defined(PNG_READ_BGR_SUPPORTED) || defined(PNG_WRITE_BGR_SUPPORTED) -PNG_EXTERN void png_do_bgr PNGARG((png_row_infop row_info, png_bytep row)); +PNG_EXTERN void png_do_bgr PNGARG((png_row_infop row_info, + png_bytep row)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_PACK_SUPPORTED) +#ifdef PNG_WRITE_PACK_SUPPORTED PNG_EXTERN void png_do_pack PNGARG((png_row_infop row_info, - png_bytep row, png_uint_32 bit_depth)); + png_bytep row, png_uint_32 bit_depth)) PNG_PRIVATE; #endif -#if defined(PNG_WRITE_SHIFT_SUPPORTED) +#ifdef PNG_WRITE_SHIFT_SUPPORTED PNG_EXTERN void png_do_shift PNGARG((png_row_infop row_info, png_bytep row, - png_color_8p bit_depth)); + png_color_8p bit_depth)) PNG_PRIVATE; #endif -#if defined(PNG_READ_BACKGROUND_SUPPORTED) -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_BACKGROUND_SUPPORTED +#ifdef PNG_READ_GAMMA_SUPPORTED PNG_EXTERN void png_do_background PNGARG((png_row_infop row_info, png_bytep row, png_color_16p trans_values, png_color_16p background, png_color_16p background_1, png_bytep gamma_table, png_bytep gamma_from_1, png_bytep gamma_to_1, png_uint_16pp gamma_16, png_uint_16pp gamma_16_from_1, - png_uint_16pp gamma_16_to_1, int gamma_shift)); + png_uint_16pp gamma_16_to_1, int gamma_shift)) PNG_PRIVATE; #else PNG_EXTERN void png_do_background PNGARG((png_row_infop row_info, png_bytep row, - png_color_16p trans_values, png_color_16p background)); + png_color_16p trans_values, png_color_16p background)) PNG_PRIVATE; #endif #endif -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED PNG_EXTERN void png_do_gamma PNGARG((png_row_infop row_info, png_bytep row, png_bytep gamma_table, png_uint_16pp gamma_16_table, - int gamma_shift)); + int gamma_shift)) PNG_PRIVATE; #endif -#if defined(PNG_READ_EXPAND_SUPPORTED) +#ifdef PNG_READ_EXPAND_SUPPORTED PNG_EXTERN void png_do_expand_palette PNGARG((png_row_infop row_info, - png_bytep row, png_colorp palette, png_bytep trans, int num_trans)); + png_bytep row, png_colorp palette, png_bytep trans, + int num_trans)) PNG_PRIVATE; PNG_EXTERN void png_do_expand PNGARG((png_row_infop row_info, - png_bytep row, png_color_16p trans_value)); + png_bytep row, png_color_16p trans_value)) PNG_PRIVATE; #endif /* The following decodes the appropriate chunks, and does error correction, * then calls the appropriate callback for the chunk if it is valid. */ -/* decode the IHDR chunk */ +/* Decode the IHDR chunk */ PNG_EXTERN void png_handle_IHDR PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; PNG_EXTERN void png_handle_PLTE PNGARG((png_structp png_ptr, png_infop info_ptr, png_uint_32 length)); PNG_EXTERN void png_handle_IEND PNGARG((png_structp png_ptr, png_infop info_ptr, png_uint_32 length)); -#if defined(PNG_READ_bKGD_SUPPORTED) +#ifdef PNG_READ_bKGD_SUPPORTED PNG_EXTERN void png_handle_bKGD PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_cHRM_SUPPORTED) +#ifdef PNG_READ_cHRM_SUPPORTED PNG_EXTERN void png_handle_cHRM PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_gAMA_SUPPORTED) +#ifdef PNG_READ_gAMA_SUPPORTED PNG_EXTERN void png_handle_gAMA PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_hIST_SUPPORTED) +#ifdef PNG_READ_hIST_SUPPORTED PNG_EXTERN void png_handle_hIST PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_iCCP_SUPPORTED) +#ifdef PNG_READ_iCCP_SUPPORTED extern void png_handle_iCCP PNGARG((png_structp png_ptr, png_infop info_ptr, png_uint_32 length)); #endif /* PNG_READ_iCCP_SUPPORTED */ -#if defined(PNG_READ_iTXt_SUPPORTED) +#ifdef PNG_READ_iTXt_SUPPORTED PNG_EXTERN void png_handle_iTXt PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_oFFs_SUPPORTED) +#ifdef PNG_READ_oFFs_SUPPORTED PNG_EXTERN void png_handle_oFFs PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_pCAL_SUPPORTED) +#ifdef PNG_READ_pCAL_SUPPORTED PNG_EXTERN void png_handle_pCAL PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_pHYs_SUPPORTED) +#ifdef PNG_READ_pHYs_SUPPORTED PNG_EXTERN void png_handle_pHYs PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_sBIT_SUPPORTED) +#ifdef PNG_READ_sBIT_SUPPORTED PNG_EXTERN void png_handle_sBIT PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_sCAL_SUPPORTED) +#ifdef PNG_READ_sCAL_SUPPORTED PNG_EXTERN void png_handle_sCAL PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_sPLT_SUPPORTED) +#ifdef PNG_READ_sPLT_SUPPORTED extern void png_handle_sPLT PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif /* PNG_READ_sPLT_SUPPORTED */ -#if defined(PNG_READ_sRGB_SUPPORTED) +#ifdef PNG_READ_sRGB_SUPPORTED PNG_EXTERN void png_handle_sRGB PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_tEXt_SUPPORTED) +#ifdef PNG_READ_tEXt_SUPPORTED PNG_EXTERN void png_handle_tEXt PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_tIME_SUPPORTED) +#ifdef PNG_READ_tIME_SUPPORTED PNG_EXTERN void png_handle_tIME PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_tRNS_SUPPORTED) +#ifdef PNG_READ_tRNS_SUPPORTED PNG_EXTERN void png_handle_tRNS PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif -#if defined(PNG_READ_zTXt_SUPPORTED) +#ifdef PNG_READ_zTXt_SUPPORTED PNG_EXTERN void png_handle_zTXt PNGARG((png_structp png_ptr, png_infop info_ptr, - png_uint_32 length)); + png_uint_32 length)) PNG_PRIVATE; #endif PNG_EXTERN void png_handle_unknown PNGARG((png_structp png_ptr, - png_infop info_ptr, png_uint_32 length)); + png_infop info_ptr, png_uint_32 length)) PNG_PRIVATE; PNG_EXTERN void png_check_chunk_name PNGARG((png_structp png_ptr, - png_bytep chunk_name)); + png_bytep chunk_name)) PNG_PRIVATE; -/* handle the transformations for reading and writing */ -PNG_EXTERN void png_do_read_transformations PNGARG((png_structp png_ptr)); -PNG_EXTERN void png_do_write_transformations PNGARG((png_structp png_ptr)); +/* Handle the transformations for reading and writing */ +PNG_EXTERN void png_do_read_transformations + PNGARG((png_structp png_ptr)) PNG_PRIVATE; +PNG_EXTERN void png_do_write_transformations + PNGARG((png_structp png_ptr)) PNG_PRIVATE; -PNG_EXTERN void png_init_read_transformations PNGARG((png_structp png_ptr)); +PNG_EXTERN void png_init_read_transformations + PNGARG((png_structp png_ptr)) PNG_PRIVATE; #ifdef PNG_PROGRESSIVE_READ_SUPPORTED PNG_EXTERN void png_push_read_chunk PNGARG((png_structp png_ptr, - png_infop info_ptr)); + png_infop info_ptr)) PNG_PRIVATE; PNG_EXTERN void png_push_read_sig PNGARG((png_structp png_ptr, - png_infop info_ptr)); -PNG_EXTERN void png_push_check_crc PNGARG((png_structp png_ptr)); + png_infop info_ptr)) PNG_PRIVATE; +PNG_EXTERN void png_push_check_crc PNGARG((png_structp png_ptr)) PNG_PRIVATE; PNG_EXTERN void png_push_crc_skip PNGARG((png_structp png_ptr, - png_uint_32 length)); -PNG_EXTERN void png_push_crc_finish PNGARG((png_structp png_ptr)); -PNG_EXTERN void png_push_save_buffer PNGARG((png_structp png_ptr)); + png_uint_32 length)) PNG_PRIVATE; +PNG_EXTERN void png_push_crc_finish PNGARG((png_structp png_ptr)) PNG_PRIVATE; +PNG_EXTERN void png_push_save_buffer PNGARG((png_structp png_ptr)) PNG_PRIVATE; PNG_EXTERN void png_push_restore_buffer PNGARG((png_structp png_ptr, - png_bytep buffer, png_size_t buffer_length)); -PNG_EXTERN void png_push_read_IDAT PNGARG((png_structp png_ptr)); + png_bytep buffer, png_size_t buffer_length)) PNG_PRIVATE; +PNG_EXTERN void png_push_read_IDAT PNGARG((png_structp png_ptr)) PNG_PRIVATE; PNG_EXTERN void png_process_IDAT_data PNGARG((png_structp png_ptr, - png_bytep buffer, png_size_t buffer_length)); -PNG_EXTERN void png_push_process_row PNGARG((png_structp png_ptr)); + png_bytep buffer, png_size_t buffer_length)) PNG_PRIVATE; +PNG_EXTERN void png_push_process_row PNGARG((png_structp png_ptr)) PNG_PRIVATE; PNG_EXTERN void png_push_handle_unknown PNGARG((png_structp png_ptr, - png_infop info_ptr, png_uint_32 length)); + png_infop info_ptr, png_uint_32 length)) PNG_PRIVATE; PNG_EXTERN void png_push_have_info PNGARG((png_structp png_ptr, - png_infop info_ptr)); + png_infop info_ptr)) PNG_PRIVATE; PNG_EXTERN void png_push_have_end PNGARG((png_structp png_ptr, - png_infop info_ptr)); -PNG_EXTERN void png_push_have_row PNGARG((png_structp png_ptr, png_bytep row)); + png_infop info_ptr)) PNG_PRIVATE; +PNG_EXTERN void png_push_have_row PNGARG((png_structp png_ptr, + png_bytep row)) PNG_PRIVATE; PNG_EXTERN void png_push_read_end PNGARG((png_structp png_ptr, - png_infop info_ptr)); + png_infop info_ptr)) PNG_PRIVATE; PNG_EXTERN void png_process_some_data PNGARG((png_structp png_ptr, - png_infop info_ptr)); -PNG_EXTERN void png_read_push_finish_row PNGARG((png_structp png_ptr)); -#if defined(PNG_READ_tEXt_SUPPORTED) + png_infop info_ptr)) PNG_PRIVATE; +PNG_EXTERN void png_read_push_finish_row + PNGARG((png_structp png_ptr)) PNG_PRIVATE; +#ifdef PNG_READ_tEXt_SUPPORTED PNG_EXTERN void png_push_handle_tEXt PNGARG((png_structp png_ptr, - png_infop info_ptr, png_uint_32 length)); + png_infop info_ptr, png_uint_32 length)) PNG_PRIVATE; PNG_EXTERN void png_push_read_tEXt PNGARG((png_structp png_ptr, - png_infop info_ptr)); + png_infop info_ptr)) PNG_PRIVATE; #endif -#if defined(PNG_READ_zTXt_SUPPORTED) +#ifdef PNG_READ_zTXt_SUPPORTED PNG_EXTERN void png_push_handle_zTXt PNGARG((png_structp png_ptr, - png_infop info_ptr, png_uint_32 length)); + png_infop info_ptr, png_uint_32 length)) PNG_PRIVATE; PNG_EXTERN void png_push_read_zTXt PNGARG((png_structp png_ptr, - png_infop info_ptr)); + png_infop info_ptr)) PNG_PRIVATE; #endif -#if defined(PNG_READ_iTXt_SUPPORTED) +#ifdef PNG_READ_iTXt_SUPPORTED PNG_EXTERN void png_push_handle_iTXt PNGARG((png_structp png_ptr, - png_infop info_ptr, png_uint_32 length)); + png_infop info_ptr, png_uint_32 length)) PNG_PRIVATE; PNG_EXTERN void png_push_read_iTXt PNGARG((png_structp png_ptr, - png_infop info_ptr)); + png_infop info_ptr)) PNG_PRIVATE; #endif #endif /* PNG_PROGRESSIVE_READ_SUPPORTED */ #ifdef PNG_MNG_FEATURES_SUPPORTED PNG_EXTERN void png_do_read_intrapixel PNGARG((png_row_infop row_info, - png_bytep row)); + png_bytep row)) PNG_PRIVATE; PNG_EXTERN void png_do_write_intrapixel PNGARG((png_row_infop row_info, - png_bytep row)); + png_bytep row)) PNG_PRIVATE; #endif -#if defined(PNG_ASSEMBLER_CODE_SUPPORTED) -#if defined(PNG_MMX_CODE_SUPPORTED) +#ifdef PNG_ASSEMBLER_CODE_SUPPORTED +#ifdef PNG_MMX_CODE_SUPPORTED /* png.c */ /* PRIVATE */ -PNG_EXTERN void png_init_mmx_flags PNGARG((png_structp png_ptr)); +PNG_EXTERN void png_init_mmx_flags PNGARG((png_structp png_ptr)) PNG_PRIVATE; #endif #endif + +/* The following six functions will be exported in libpng-1.4.0. */ #if defined(PNG_INCH_CONVERSIONS) && defined(PNG_FLOATING_POINT_SUPPORTED) PNG_EXTERN png_uint_32 png_get_pixels_per_inch PNGARG((png_structp png_ptr, png_infop info_ptr)); @@ -3529,12 +3764,43 @@ png_infop info_ptr)); PNG_EXTERN float png_get_y_offset_inches PNGARG((png_structp png_ptr, png_infop info_ptr)); -#if defined(PNG_pHYs_SUPPORTED) +#ifdef PNG_pHYs_SUPPORTED PNG_EXTERN png_uint_32 png_get_pHYs_dpi PNGARG((png_structp png_ptr, png_infop info_ptr, png_uint_32 *res_x, png_uint_32 *res_y, int *unit_type)); #endif /* PNG_pHYs_SUPPORTED */ #endif /* PNG_INCH_CONVERSIONS && PNG_FLOATING_POINT_SUPPORTED */ +/* Read the chunk header (length + type name) */ +PNG_EXTERN png_uint_32 png_read_chunk_header + PNGARG((png_structp png_ptr)) PNG_PRIVATE; + +/* Added at libpng version 1.2.34 */ +#ifdef PNG_cHRM_SUPPORTED +PNG_EXTERN int png_check_cHRM_fixed PNGARG((png_structp png_ptr, + png_fixed_point int_white_x, png_fixed_point int_white_y, + png_fixed_point int_red_x, png_fixed_point int_red_y, png_fixed_point + int_green_x, png_fixed_point int_green_y, png_fixed_point int_blue_x, + png_fixed_point int_blue_y)) PNG_PRIVATE; +#endif + +#ifdef PNG_cHRM_SUPPORTED +#ifdef PNG_CHECK_cHRM_SUPPORTED +/* Added at libpng version 1.2.34 */ +PNG_EXTERN void png_64bit_product PNGARG((long v1, long v2, + unsigned long *hi_product, unsigned long *lo_product)) PNG_PRIVATE; +#endif +#endif + +/* Added at libpng version 1.2.41 */ +PNG_EXTERN void png_check_IHDR PNGARG((png_structp png_ptr, + png_uint_32 width, png_uint_32 height, int bit_depth, + int color_type, int interlace_type, int compression_type, + int filter_type)) PNG_PRIVATE; + +/* Added at libpng version 1.2.41 */ +PNG_EXTERN png_voidp png_calloc PNGARG((png_structp png_ptr, + png_uint_32 size)); + /* Maintainer: Put new private prototypes here ^ and in libpngpf.3 */ #endif /* PNG_INTERNAL */ @@ -3544,5 +3810,5 @@ png_infop info_ptr, png_uint_32 *res_x, png_uint_32 *res_y, int *unit_type)); #endif #endif /* PNG_VERSION_INFO_ONLY */ -/* do not put anything past this line */ +/* Do not put anything past this line */ #endif /* PNG_H */ diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngconf.h b/graf2d/asimage/src/libAfterImage/libpng/pngconf.h index 28b08c4b4e03b..042a5e98f237f 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngconf.h +++ b/graf2d/asimage/src/libAfterImage/libpng/pngconf.h @@ -1,11 +1,14 @@ /* pngconf.h - machine configurable file for libpng * - * libpng version 1.2.23 - November 6, 2007 - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * libpng version 1.2.50 - July 10, 2012 + * Copyright (c) 1998-2012 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) + * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h */ /* Any machine specific code is near the front of this file, so if you @@ -19,7 +22,7 @@ #define PNG_1_2_X -/* +/* * PNG_USER_CONFIG has to be defined on the compiler command line. This * includes the resource compiler for Windows DLL configurations. */ @@ -39,7 +42,7 @@ /* * Added at libpng-1.2.8 - * + * * If you create a private DLL you need to define in "pngusr.h" the followings: * #define PNG_USER_PRIVATEBUILD @@ -50,8 +53,8 @@ * number and must match your private DLL name> * e.g. // private DLL "libpng13gx.dll" * #define PNG_USER_DLLFNAME_POSTFIX "gx" - * - * The following macros are also at your disposal if you want to complete the + * + * The following macros are also at your disposal if you want to complete the * DLL VERSIONINFO structure. * - PNG_USER_VERSIONINFO_COMMENTS * - PNG_USER_VERSIONINFO_COMPANYNAME @@ -112,8 +115,33 @@ # define PNG_WRITE_SUPPORTED #endif +/* Enabled in 1.2.41. */ +#ifdef PNG_ALLOW_BENIGN_ERRORS +# define png_benign_error png_warning +# define png_chunk_benign_error png_chunk_warning +#else +# ifndef PNG_BENIGN_ERRORS_SUPPORTED +# define png_benign_error png_error +# define png_chunk_benign_error png_chunk_error +# endif +#endif + +/* Added in libpng-1.2.41 */ +#if !defined(PNG_NO_WARNINGS) && !defined(PNG_WARNINGS_SUPPORTED) +# define PNG_WARNINGS_SUPPORTED +#endif + +#if !defined(PNG_NO_ERROR_TEXT) && !defined(PNG_ERROR_TEXT_SUPPORTED) +# define PNG_ERROR_TEXT_SUPPORTED +#endif + +#if !defined(PNG_NO_CHECK_cHRM) && !defined(PNG_CHECK_cHRM_SUPPORTED) +# define PNG_CHECK_cHRM_SUPPORTED +#endif + /* Enabled by default in 1.2.0. You can disable this if you don't need to - support PNGs that are embedded in MNG datastreams */ + * support PNGs that are embedded in MNG datastreams + */ #if !defined(PNG_1_0_X) && !defined(PNG_NO_MNG_FEATURES) # ifndef PNG_MNG_FEATURES_SUPPORTED # define PNG_MNG_FEATURES_SUPPORTED @@ -147,9 +175,9 @@ * 'Cygwin' defines/defaults: * PNG_BUILD_DLL -- (ignored) building the dll * (no define) -- (ignored) building an application, linking to the dll - * PNG_STATIC -- (ignored) building the static lib, or building an + * PNG_STATIC -- (ignored) building the static lib, or building an * application that links to the static lib. - * ALL_STATIC -- (ignored) building various static libs, or building an + * ALL_STATIC -- (ignored) building various static libs, or building an * application that links to the static libs. * Thus, * a cygwin user should define either PNG_BUILD_DLL or PNG_STATIC, and @@ -162,57 +190,57 @@ * PNG_BUILD_DLL * PNG_STATIC * (nothing) == PNG_USE_DLL - * + * * CYGWIN (2002-01-20): The preceding is now obsolete. With the advent - * of auto-import in binutils, we no longer need to worry about + * of auto-import in binutils, we no longer need to worry about * __declspec(dllexport) / __declspec(dllimport) and friends. Therefore, * we don't need to worry about PNG_STATIC or ALL_STATIC when it comes - * to __declspec() stuff. However, we DO need to worry about + * to __declspec() stuff. However, we DO need to worry about * PNG_BUILD_DLL and PNG_STATIC because those change some defaults * such as CONSOLE_IO and whether GLOBAL_ARRAYS are allowed. */ -#if defined(__CYGWIN__) -# if defined(ALL_STATIC) -# if defined(PNG_BUILD_DLL) +#ifdef __CYGWIN__ +# ifdef ALL_STATIC +# ifdef PNG_BUILD_DLL # undef PNG_BUILD_DLL # endif -# if defined(PNG_USE_DLL) +# ifdef PNG_USE_DLL # undef PNG_USE_DLL # endif -# if defined(PNG_DLL) +# ifdef PNG_DLL # undef PNG_DLL # endif -# if !defined(PNG_STATIC) +# ifndef PNG_STATIC # define PNG_STATIC # endif # else -# if defined (PNG_BUILD_DLL) -# if defined(PNG_STATIC) +# ifdef PNG_BUILD_DLL +# ifdef PNG_STATIC # undef PNG_STATIC # endif -# if defined(PNG_USE_DLL) +# ifdef PNG_USE_DLL # undef PNG_USE_DLL # endif -# if !defined(PNG_DLL) +# ifndef PNG_DLL # define PNG_DLL # endif # else -# if defined(PNG_STATIC) -# if defined(PNG_USE_DLL) +# ifdef PNG_STATIC +# ifdef PNG_USE_DLL # undef PNG_USE_DLL # endif -# if defined(PNG_DLL) +# ifdef PNG_DLL # undef PNG_DLL # endif # else -# if !defined(PNG_USE_DLL) +# ifndef PNG_USE_DLL # define PNG_USE_DLL # endif -# if !defined(PNG_DLL) +# ifndef PNG_DLL # define PNG_DLL # endif -# endif -# endif +# endif +# endif # endif #endif @@ -229,10 +257,16 @@ * #define PNG_NO_STDIO */ -#if defined(_WIN32_WCE) +#if !defined(PNG_NO_STDIO) && !defined(PNG_STDIO_SUPPORTED) +# define PNG_STDIO_SUPPORTED +#endif + +#ifdef _WIN32_WCE # include /* Console I/O functions are not supported on WindowsCE */ # define PNG_NO_CONSOLE_IO + /* abort() may not be supported on some/all Windows CE platforms */ +# define PNG_ABORT() exit(-1) # ifdef PNG_DEBUG # undef PNG_DEBUG # endif @@ -256,12 +290,16 @@ # endif # endif # else -# if !defined(_WIN32_WCE) +# ifndef _WIN32_WCE /* "stdio.h" functions are not supported on WindowsCE */ # include # endif # endif +#if !(defined PNG_NO_CONSOLE_IO) && !defined(PNG_CONSOLE_IO_SUPPORTED) +# define PNG_CONSOLE_IO_SUPPORTED +#endif + /* This macro protects us against machines that don't have function * prototypes (ie K&R style headers). If your compiler does not handle * function prototypes, define this macro and use the included ansi2knr. @@ -312,28 +350,38 @@ #ifdef PNG_SETJMP_SUPPORTED /* This is an attempt to force a single setjmp behaviour on Linux. If * the X config stuff didn't define _BSD_SOURCE we wouldn't need this. + * + * You can bypass this test if you know that your application uses exactly + * the same setjmp.h that was included when libpng was built. Only define + * PNG_SKIP_SETJMP_CHECK while building your application, prior to the + * application's '#include "png.h"'. Don't define PNG_SKIP_SETJMP_CHECK + * while building a separate libpng library for general use. */ -# ifdef __linux__ -# ifdef _BSD_SOURCE -# define PNG_SAVE_BSD_SOURCE -# undef _BSD_SOURCE -# endif -# ifdef _SETJMP_H - /* If you encounter a compiler error here, see the explanation - * near the end of INSTALL. - */ - __png.h__ already includes setjmp.h; - __dont__ include it again.; -# endif -# endif /* __linux__ */ +# ifndef PNG_SKIP_SETJMP_CHECK +# ifdef __linux__ +# ifdef _BSD_SOURCE +# define PNG_SAVE_BSD_SOURCE +# undef _BSD_SOURCE +# endif +# ifdef _SETJMP_H + /* If you encounter a compiler error here, see the explanation + * near the end of INSTALL. + */ + __pngconf.h__ in libpng already includes setjmp.h; + __dont__ include it again.; +# endif +# endif /* __linux__ */ +# endif /* PNG_SKIP_SETJMP_CHECK */ /* include setjmp.h for error handling */ # include # ifdef __linux__ # ifdef PNG_SAVE_BSD_SOURCE -# define _BSD_SOURCE +# ifndef _BSD_SOURCE +# define _BSD_SOURCE +# endif # undef PNG_SAVE_BSD_SOURCE # endif # endif /* __linux__ */ @@ -363,8 +411,8 @@ * them inside an appropriate ifdef/endif pair for portability. */ -#if defined(PNG_FLOATING_POINT_SUPPORTED) -# if defined(MACOS) +#ifdef PNG_FLOATING_POINT_SUPPORTED +# ifdef MACOS /* We need to check that hasn't already been included earlier * as it seems it doesn't agree with , yet we should really use * if possible. @@ -475,7 +523,7 @@ * iTXt support was added. iTXt support was turned off by default through * libpng-1.2.x, to support old apps that malloc the png_text structure * instead of calling png_set_text() and letting libpng malloc it. It - * was turned on by default in libpng-1.3.0. + * will be turned on by default in libpng-1.4.0. */ #if defined(PNG_1_0_X) || defined (PNG_1_2_X) @@ -509,6 +557,7 @@ # define PNG_NO_FREE_ME # define PNG_NO_READ_UNKNOWN_CHUNKS # define PNG_NO_WRITE_UNKNOWN_CHUNKS +# define PNG_NO_HANDLE_AS_UNKNOWN # define PNG_NO_READ_USER_CHUNKS # define PNG_NO_READ_iCCP # define PNG_NO_WRITE_iCCP @@ -538,7 +587,7 @@ # define PNG_FREE_ME_SUPPORTED #endif -#if defined(PNG_READ_SUPPORTED) +#ifdef PNG_READ_SUPPORTED #if !defined(PNG_READ_TRANSFORMS_NOT_SUPPORTED) && \ !defined(PNG_NO_READ_TRANSFORMS) @@ -602,11 +651,20 @@ # endif #endif /* PNG_READ_TRANSFORMS_SUPPORTED */ +/* PNG_PROGRESSIVE_READ_NOT_SUPPORTED is deprecated. */ #if !defined(PNG_NO_PROGRESSIVE_READ) && \ - !defined(PNG_PROGRESSIVE_READ_SUPPORTED) /* if you don't do progressive */ -# define PNG_PROGRESSIVE_READ_SUPPORTED /* reading. This is not talking */ -#endif /* about interlacing capability! You'll */ - /* still have interlacing unless you change the following line: */ + !defined(PNG_PROGRESSIVE_READ_NOT_SUPPORTED) /* if you don't do progressive */ +# define PNG_PROGRESSIVE_READ_SUPPORTED /* reading. This is not talking */ +#endif /* about interlacing capability! You'll */ + /* still have interlacing unless you change the following define: */ +#define PNG_READ_INTERLACING_SUPPORTED /* required for PNG-compliant decoders */ + +/* PNG_NO_SEQUENTIAL_READ_SUPPORTED is deprecated. */ +#if !defined(PNG_NO_SEQUENTIAL_READ) && \ + !defined(PNG_SEQUENTIAL_READ_SUPPORTED) && \ + !defined(PNG_NO_SEQUENTIAL_READ_SUPPORTED) +# define PNG_SEQUENTIAL_READ_SUPPORTED +#endif #define PNG_READ_INTERLACING_SUPPORTED /* required in PNG-compliant decoders */ @@ -626,7 +684,7 @@ #endif /* PNG_READ_SUPPORTED */ -#if defined(PNG_WRITE_SUPPORTED) +#ifdef PNG_WRITE_SUPPORTED # if !defined(PNG_WRITE_TRANSFORMS_NOT_SUPPORTED) && \ !defined(PNG_NO_WRITE_TRANSFORMS) @@ -658,9 +716,11 @@ # ifndef PNG_NO_WRITE_SWAP_ALPHA # define PNG_WRITE_SWAP_ALPHA_SUPPORTED # endif +#ifndef PNG_1_0_X # ifndef PNG_NO_WRITE_INVERT_ALPHA # define PNG_WRITE_INVERT_ALPHA_SUPPORTED # endif +#endif # ifndef PNG_NO_WRITE_USER_TRANSFORM # define PNG_WRITE_USER_TRANSFORM_SUPPORTED # endif @@ -729,7 +789,7 @@ # define PNG_EASY_ACCESS_SUPPORTED #endif -/* PNG_ASSEMBLER_CODE was enabled by default in version 1.2.0 +/* PNG_ASSEMBLER_CODE was enabled by default in version 1.2.0 * and removed from version 1.2.20. The following will be removed * from libpng-1.4.0 */ @@ -752,7 +812,7 @@ # endif # endif -# if defined(__APPLE__) +# ifdef __APPLE__ # if !defined(PNG_MMX_CODE_SUPPORTED) && !defined(PNG_NO_MMX_CODE) # define PNG_NO_MMX_CODE # endif @@ -771,21 +831,29 @@ #endif /* end of obsolete code to be removed from libpng-1.4.0 */ -#if !defined(PNG_1_0_X) +/* Added at libpng-1.2.0 */ +#ifndef PNG_1_0_X #if !defined(PNG_NO_USER_MEM) && !defined(PNG_USER_MEM_SUPPORTED) # define PNG_USER_MEM_SUPPORTED #endif #endif /* PNG_1_0_X */ /* Added at libpng-1.2.6 */ -#if !defined(PNG_1_0_X) -#ifndef PNG_SET_USER_LIMITS_SUPPORTED -#if !defined(PNG_NO_SET_USER_LIMITS) && !defined(PNG_SET_USER_LIMITS_SUPPORTED) -# define PNG_SET_USER_LIMITS_SUPPORTED -#endif -#endif +#ifndef PNG_1_0_X +# ifndef PNG_SET_USER_LIMITS_SUPPORTED +# ifndef PNG_NO_SET_USER_LIMITS +# define PNG_SET_USER_LIMITS_SUPPORTED +# endif +# endif #endif /* PNG_1_0_X */ +/* Added at libpng-1.0.53 and 1.2.43 */ +#ifndef PNG_USER_LIMITS_SUPPORTED +# ifndef PNG_NO_USER_LIMITS +# define PNG_USER_LIMITS_SUPPORTED +# endif +#endif + /* Added at libpng-1.0.16 and 1.2.6. To accept all valid PNGS no matter * how large, set these limits to 0x7fffffffL */ @@ -796,6 +864,33 @@ # define PNG_USER_HEIGHT_MAX 1000000L #endif +/* Added at libpng-1.2.43. To accept all valid PNGs no matter + * how large, set these two limits to 0. + */ +#ifndef PNG_USER_CHUNK_CACHE_MAX +# define PNG_USER_CHUNK_CACHE_MAX 0 +#endif + +/* Added at libpng-1.2.43 */ +#ifndef PNG_USER_CHUNK_MALLOC_MAX +# define PNG_USER_CHUNK_MALLOC_MAX 0 +#endif + +#ifndef PNG_LITERAL_SHARP +# define PNG_LITERAL_SHARP 0x23 +#endif +#ifndef PNG_LITERAL_LEFT_SQUARE_BRACKET +# define PNG_LITERAL_LEFT_SQUARE_BRACKET 0x5b +#endif +#ifndef PNG_LITERAL_RIGHT_SQUARE_BRACKET +# define PNG_LITERAL_RIGHT_SQUARE_BRACKET 0x5d +#endif + +/* Added at libpng-1.2.34 */ +#ifndef PNG_STRING_NEWLINE +#define PNG_STRING_NEWLINE "\n" +#endif + /* These are currently experimental features, define them if you want */ /* very little testing */ @@ -820,6 +915,11 @@ #define PNG_NO_POINTER_INDEXING */ +#if !defined(PNG_NO_POINTER_INDEXING) && \ + !defined(PNG_POINTER_INDEXING_SUPPORTED) +# define PNG_POINTER_INDEXING_SUPPORTED +#endif + /* These functions are turned off by default, as they will be phased out. */ /* #define PNG_USELESS_TESTS_SUPPORTED @@ -923,14 +1023,22 @@ # define PNG_READ_zTXt_SUPPORTED # define PNG_zTXt_SUPPORTED #endif +#ifndef PNG_NO_READ_OPT_PLTE +# define PNG_READ_OPT_PLTE_SUPPORTED /* only affects support of the */ +#endif /* optional PLTE chunk in RGB and RGBA images */ +#if defined(PNG_READ_iTXt_SUPPORTED) || defined(PNG_READ_tEXt_SUPPORTED) || \ + defined(PNG_READ_zTXt_SUPPORTED) +# define PNG_READ_TEXT_SUPPORTED +# define PNG_TEXT_SUPPORTED +#endif + +#endif /* PNG_READ_ANCILLARY_CHUNKS_SUPPORTED */ + #ifndef PNG_NO_READ_UNKNOWN_CHUNKS # define PNG_READ_UNKNOWN_CHUNKS_SUPPORTED # ifndef PNG_UNKNOWN_CHUNKS_SUPPORTED # define PNG_UNKNOWN_CHUNKS_SUPPORTED # endif -# ifndef PNG_NO_HANDLE_AS_UNKNOWN -# define PNG_HANDLE_AS_UNKNOWN_SUPPORTED -# endif #endif #if !defined(PNG_NO_READ_USER_CHUNKS) && \ defined(PNG_READ_UNKNOWN_CHUNKS_SUPPORTED) @@ -943,17 +1051,14 @@ # undef PNG_NO_HANDLE_AS_UNKNOWN # endif #endif -#ifndef PNG_NO_READ_OPT_PLTE -# define PNG_READ_OPT_PLTE_SUPPORTED /* only affects support of the */ -#endif /* optional PLTE chunk in RGB and RGBA images */ -#if defined(PNG_READ_iTXt_SUPPORTED) || defined(PNG_READ_tEXt_SUPPORTED) || \ - defined(PNG_READ_zTXt_SUPPORTED) -# define PNG_READ_TEXT_SUPPORTED -# define PNG_TEXT_SUPPORTED -#endif -#endif /* PNG_READ_ANCILLARY_CHUNKS_SUPPORTED */ +#ifndef PNG_NO_HANDLE_AS_UNKNOWN +# ifndef PNG_HANDLE_AS_UNKNOWN_SUPPORTED +# define PNG_HANDLE_AS_UNKNOWN_SUPPORTED +# endif +#endif +#ifdef PNG_WRITE_SUPPORTED #ifdef PNG_WRITE_ANCILLARY_CHUNKS_SUPPORTED #ifdef PNG_NO_WRITE_TEXT @@ -1065,17 +1170,6 @@ # define PNG_zTXt_SUPPORTED # endif #endif -#ifndef PNG_NO_WRITE_UNKNOWN_CHUNKS -# define PNG_WRITE_UNKNOWN_CHUNKS_SUPPORTED -# ifndef PNG_UNKNOWN_CHUNKS_SUPPORTED -# define PNG_UNKNOWN_CHUNKS_SUPPORTED -# endif -# ifndef PNG_NO_HANDLE_AS_UNKNOWN -# ifndef PNG_HANDLE_AS_UNKNOWN_SUPPORTED -# define PNG_HANDLE_AS_UNKNOWN_SUPPORTED -# endif -# endif -#endif #if defined(PNG_WRITE_iTXt_SUPPORTED) || defined(PNG_WRITE_tEXt_SUPPORTED) || \ defined(PNG_WRITE_zTXt_SUPPORTED) # define PNG_WRITE_TEXT_SUPPORTED @@ -1084,8 +1178,37 @@ # endif #endif +#ifdef PNG_WRITE_tIME_SUPPORTED +# ifndef PNG_NO_CONVERT_tIME +# ifndef _WIN32_WCE +/* The "tm" structure is not supported on WindowsCE */ +# ifndef PNG_CONVERT_tIME_SUPPORTED +# define PNG_CONVERT_tIME_SUPPORTED +# endif +# endif +# endif +#endif + #endif /* PNG_WRITE_ANCILLARY_CHUNKS_SUPPORTED */ +#if !defined(PNG_NO_WRITE_FILTER) && !defined(PNG_WRITE_FILTER_SUPPORTED) +# define PNG_WRITE_FILTER_SUPPORTED +#endif + +#ifndef PNG_NO_WRITE_UNKNOWN_CHUNKS +# define PNG_WRITE_UNKNOWN_CHUNKS_SUPPORTED +# ifndef PNG_UNKNOWN_CHUNKS_SUPPORTED +# define PNG_UNKNOWN_CHUNKS_SUPPORTED +# endif +#endif + +#ifndef PNG_NO_HANDLE_AS_UNKNOWN +# ifndef PNG_HANDLE_AS_UNKNOWN_SUPPORTED +# define PNG_HANDLE_AS_UNKNOWN_SUPPORTED +# endif +#endif +#endif /* PNG_WRITE_SUPPORTED */ + /* Turn this off to disable png_read_png() and * png_write_png() and leave the row_pointers member * out of the info structure. @@ -1094,12 +1217,10 @@ # define PNG_INFO_IMAGE_SUPPORTED #endif -/* need the time information for reading tIME chunks */ -#if defined(PNG_tIME_SUPPORTED) -# if !defined(_WIN32_WCE) +/* Need the time information for converting tIME chunks */ +#ifdef PNG_CONVERT_tIME_SUPPORTED /* "time.h" functions are not supported on WindowsCE */ # include -# endif #endif /* Some typedefs to get us started. These should be safe on most of the @@ -1121,10 +1242,10 @@ typedef unsigned char png_byte; change (I'm not sure if you will or not, so I thought I'd be safe) */ #ifdef PNG_SIZE_T typedef PNG_SIZE_T png_size_t; -# define png_sizeof(x) png_convert_size(sizeof (x)) +# define png_sizeof(x) png_convert_size(sizeof(x)) #else typedef size_t png_size_t; -# define png_sizeof(x) sizeof (x) +# define png_sizeof(x) sizeof(x) #endif /* The following is needed for medium model support. It cannot be in the @@ -1168,8 +1289,8 @@ typedef unsigned char png_byte; */ /* MSC Medium model */ -#if defined(FAR) -# if defined(M_I86MM) +#ifdef FAR +# ifdef M_I86MM # define USE_FAR_KEYWORD # define FARDATA FAR # include @@ -1202,7 +1323,7 @@ typedef char FAR * png_charp; typedef png_fixed_point FAR * png_fixed_point_p; #ifndef PNG_NO_STDIO -#if defined(_WIN32_WCE) +#ifdef _WIN32_WCE typedef HANDLE png_FILE_p; #else typedef FILE * png_FILE_p; @@ -1231,7 +1352,7 @@ typedef char FAR * FAR * FAR * png_charppp; #if defined(PNG_1_0_X) || defined(PNG_1_2_X) /* SPC - Is this stuff deprecated? */ -/* It'll be removed as of libpng-1.3.0 - GR-P */ +/* It'll be removed as of libpng-1.4.0 - GR-P */ /* libpng typedefs for types in zlib. If zlib changes * or another compression library is used, then change these. * Eliminates need to change all the source files. @@ -1266,17 +1387,17 @@ typedef z_stream FAR * png_zstreamp; * When building a static lib, default to no GLOBAL ARRAYS, but allow * command-line override */ -#if defined(__CYGWIN__) -# if !defined(PNG_STATIC) -# if defined(PNG_USE_GLOBAL_ARRAYS) +#ifdef __CYGWIN__ +# ifndef PNG_STATIC +# ifdef PNG_USE_GLOBAL_ARRAYS # undef PNG_USE_GLOBAL_ARRAYS # endif -# if !defined(PNG_USE_LOCAL_ARRAYS) +# ifndef PNG_USE_LOCAL_ARRAYS # define PNG_USE_LOCAL_ARRAYS # endif # else # if defined(PNG_USE_LOCAL_ARRAYS) || defined(PNG_NO_GLOBAL_ARRAYS) -# if defined(PNG_USE_GLOBAL_ARRAYS) +# ifdef PNG_USE_GLOBAL_ARRAYS # undef PNG_USE_GLOBAL_ARRAYS # endif # endif @@ -1299,12 +1420,12 @@ typedef z_stream FAR * png_zstreamp; # endif #endif -#if defined(__CYGWIN__) +#ifdef __CYGWIN__ # undef PNGAPI # define PNGAPI __cdecl # undef PNG_IMPEXP # define PNG_IMPEXP -#endif +#endif /* If you define PNGAPI, e.g., with compiler option "-DPNGAPI=__stdcall", * you may get warnings regarding the linkage of png_zalloc and png_zfree. @@ -1340,7 +1461,7 @@ typedef z_stream FAR * png_zstreamp; # define PNG_IMPEXP # endif -# if !defined(PNG_IMPEXP) +# ifndef PNG_IMPEXP # define PNG_EXPORT_TYPE1(type,symbol) PNG_IMPEXP type PNGAPI symbol # define PNG_EXPORT_TYPE2(type,symbol) type PNG_IMPEXP PNGAPI symbol @@ -1351,7 +1472,7 @@ typedef z_stream FAR * png_zstreamp; # define PNG_EXPORT PNG_EXPORT_TYPE1 # else # define PNG_EXPORT PNG_EXPORT_TYPE2 -# if defined(PNG_BUILD_DLL) +# ifdef PNG_BUILD_DLL # define PNG_IMPEXP __export # else # define PNG_IMPEXP /*__import */ /* doesn't exist AFAIK in @@ -1361,8 +1482,8 @@ typedef z_stream FAR * png_zstreamp; # endif # endif -# if !defined(PNG_IMPEXP) -# if defined(PNG_BUILD_DLL) +# ifndef PNG_IMPEXP +# ifdef PNG_BUILD_DLL # define PNG_IMPEXP __declspec(dllexport) # else # define PNG_IMPEXP __declspec(dllimport) @@ -1408,6 +1529,70 @@ typedef z_stream FAR * png_zstreamp; # endif #endif +#ifdef PNG_PEDANTIC_WARNINGS +# ifndef PNG_PEDANTIC_WARNINGS_SUPPORTED +# define PNG_PEDANTIC_WARNINGS_SUPPORTED +# endif +#endif + +#ifdef PNG_PEDANTIC_WARNINGS_SUPPORTED +/* Support for compiler specific function attributes. These are used + * so that where compiler support is available incorrect use of API + * functions in png.h will generate compiler warnings. Added at libpng + * version 1.2.41. + */ +# ifdef __GNUC__ +# ifndef PNG_USE_RESULT +# define PNG_USE_RESULT __attribute__((__warn_unused_result__)) +# endif +# ifndef PNG_NORETURN +# define PNG_NORETURN __attribute__((__noreturn__)) +# endif +# ifndef PNG_ALLOCATED +# define PNG_ALLOCATED __attribute__((__malloc__)) +# endif + + /* This specifically protects structure members that should only be + * accessed from within the library, therefore should be empty during + * a library build. + */ +# ifndef PNG_DEPRECATED +# define PNG_DEPRECATED __attribute__((__deprecated__)) +# endif +# ifndef PNG_DEPSTRUCT +# define PNG_DEPSTRUCT __attribute__((__deprecated__)) +# endif +# ifndef PNG_PRIVATE +# if 0 /* Doesn't work so we use deprecated instead*/ +# define PNG_PRIVATE \ + __attribute__((warning("This function is not exported by libpng."))) +# else +# define PNG_PRIVATE \ + __attribute__((__deprecated__)) +# endif +# endif /* PNG_PRIVATE */ +# endif /* __GNUC__ */ +#endif /* PNG_PEDANTIC_WARNINGS */ + +#ifndef PNG_DEPRECATED +# define PNG_DEPRECATED /* Use of this function is deprecated */ +#endif +#ifndef PNG_USE_RESULT +# define PNG_USE_RESULT /* The result of this function must be checked */ +#endif +#ifndef PNG_NORETURN +# define PNG_NORETURN /* This function does not return */ +#endif +#ifndef PNG_ALLOCATED +# define PNG_ALLOCATED /* The result of the function is new memory */ +#endif +#ifndef PNG_DEPSTRUCT +# define PNG_DEPSTRUCT /* Access to this struct member is deprecated */ +#endif +#ifndef PNG_PRIVATE +# define PNG_PRIVATE /* This is a private libpng function */ +#endif + /* User may want to use these so they are not in PNG_INTERNAL. Any library * functions that are passed far data must be model independent. */ @@ -1423,8 +1608,8 @@ typedef z_stream FAR * png_zstreamp; (LIBPNG_WAS_COMPILED_WITH__PNG_SETJMP_NOT_SUPPORTED) #endif -#if defined(USE_FAR_KEYWORD) /* memory model independent fns */ -/* use this to make far-to-near assignments */ +#ifdef USE_FAR_KEYWORD /* memory model independent fns */ +/* Use this to make far-to-near assignments */ # define CHECK 1 # define NOCHECK 0 # define CVT_PTR(ptr) (png_far_to_near(png_ptr,ptr,CHECK)) @@ -1434,7 +1619,7 @@ typedef z_stream FAR * png_zstreamp; # define png_memcmp _fmemcmp /* SJT: added */ # define png_memcpy _fmemcpy # define png_memset _fmemset -#else /* use the usual functions */ +#else /* Use the usual functions */ # define CVT_PTR(ptr) (ptr) # define CVT_PTR_NOCHECK(ptr) (ptr) # ifndef PNG_NO_SNPRINTF @@ -1452,7 +1637,8 @@ typedef z_stream FAR * png_zstreamp; * sprintf instead of snprintf exposes your application to accidental * or malevolent buffer overflows. If you don't have snprintf() * as a general rule you should provide one (you can get one from - * Portable OpenSSH). */ + * Portable OpenSSH). + */ # define png_snprintf(s1,n,fmt,x1) sprintf(s1,fmt,x1) # define png_snprintf2(s1,n,fmt,x1,x2) sprintf(s1,fmt,x1,x2) # define png_snprintf6(s1,n,fmt,x1,x2,x3,x4,x5,x6) \ diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngerror.c b/graf2d/asimage/src/libAfterImage/libpng/pngerror.c index 9f6b90dd6ae60..025d52e775ae3 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngerror.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngerror.c @@ -1,12 +1,15 @@ /* pngerror.c - stub functions for i/o and memory allocation * - * Last changed in libpng 1.2.22 [November 6, 2007] - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * Last changed in libpng 1.2.45 [July 7, 2011] + * Copyright (c) 1998-2011 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h + * * This file provides a location for all error handling. Users who * need special error handling are expected to write replacement functions * and use png_set_error_fn() to use those functions. See the instructions @@ -14,24 +17,25 @@ */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" - #if defined(PNG_READ_SUPPORTED) || defined(PNG_WRITE_SUPPORTED) + static void /* PRIVATE */ png_default_error PNGARG((png_structp png_ptr, - png_const_charp error_message)); -#ifndef PNG_NO_WARNINGS + png_const_charp error_message)) PNG_NORETURN; +#ifdef PNG_WARNINGS_SUPPORTED static void /* PRIVATE */ png_default_warning PNGARG((png_structp png_ptr, png_const_charp warning_message)); -#endif /* PNG_NO_WARNINGS */ +#endif /* PNG_WARNINGS_SUPPORTED */ /* This function is called whenever there is a fatal error. This function * should not be changed. If there is a need to handle errors differently, * you should supply a replacement error function and use png_set_error_fn() * to replace the error function at run-time. */ -#ifndef PNG_NO_ERROR_TEXT +#ifdef PNG_ERROR_TEXT_SUPPORTED void PNGAPI png_error(png_structp png_ptr, png_const_charp error_message) { @@ -42,30 +46,31 @@ png_error(png_structp png_ptr, png_const_charp error_message) if (png_ptr->flags& (PNG_FLAG_STRIP_ERROR_NUMBERS|PNG_FLAG_STRIP_ERROR_TEXT)) { - if (*error_message == '#') + if (*error_message == PNG_LITERAL_SHARP) { + /* Strip "#nnnn " from beginning of error message. */ int offset; - for (offset=1; offset<15; offset++) - if (*(error_message+offset) == ' ') + for (offset = 1; offset<15; offset++) + if (error_message[offset] == ' ') break; if (png_ptr->flags&PNG_FLAG_STRIP_ERROR_TEXT) { int i; - for (i=0; iflags&PNG_FLAG_STRIP_ERROR_TEXT) { - msg[0]='0'; - msg[1]='\0'; - error_message=msg; + msg[0] = '0'; + msg[1] = '\0'; + error_message = msg; } } } @@ -82,16 +87,21 @@ png_error(png_structp png_ptr, png_const_charp error_message) void PNGAPI png_err(png_structp png_ptr) { + /* Prior to 1.2.45 the error_fn received a NULL pointer, expressed + * erroneously as '\0', instead of the empty string "". This was + * apparently an error, introduced in libpng-1.2.20, and png_default_error + * will crash in this case. + */ if (png_ptr != NULL && png_ptr->error_fn != NULL) - (*(png_ptr->error_fn))(png_ptr, '\0'); + (*(png_ptr->error_fn))(png_ptr, ""); /* If the custom handler doesn't exist, or if it returns, use the default handler, which will not return. */ - png_default_error(png_ptr, '\0'); + png_default_error(png_ptr, ""); } -#endif /* PNG_NO_ERROR_TEXT */ +#endif /* PNG_ERROR_TEXT_SUPPORTED */ -#ifndef PNG_NO_WARNINGS +#ifdef PNG_WARNINGS_SUPPORTED /* This function is called whenever there is a non-fatal error. This function * should not be changed. If there is a need to handle warnings differently, * you should supply a replacement warning function and use @@ -108,21 +118,31 @@ png_warning(png_structp png_ptr, png_const_charp warning_message) (PNG_FLAG_STRIP_ERROR_NUMBERS|PNG_FLAG_STRIP_ERROR_TEXT)) #endif { - if (*warning_message == '#') + if (*warning_message == PNG_LITERAL_SHARP) { - for (offset=1; offset<15; offset++) - if (*(warning_message+offset) == ' ') + for (offset = 1; offset < 15; offset++) + if (warning_message[offset] == ' ') break; } } - if (png_ptr != NULL && png_ptr->warning_fn != NULL) - (*(png_ptr->warning_fn))(png_ptr, warning_message+offset); } + if (png_ptr != NULL && png_ptr->warning_fn != NULL) + (*(png_ptr->warning_fn))(png_ptr, warning_message + offset); else - png_default_warning(png_ptr, warning_message+offset); + png_default_warning(png_ptr, warning_message + offset); } -#endif /* PNG_NO_WARNINGS */ +#endif /* PNG_WARNINGS_SUPPORTED */ +#ifdef PNG_BENIGN_ERRORS_SUPPORTED +void PNGAPI +png_benign_error(png_structp png_ptr, png_const_charp error_message) +{ + if (png_ptr->flags & PNG_FLAG_BENIGN_ERRORS_WARN) + png_warning(png_ptr, error_message); + else + png_error(png_ptr, error_message); +} +#endif /* These utilities are used internally to build an error message that relates * to the current chunk. The chunk name comes from png_ptr->chunk_name, @@ -137,8 +157,7 @@ static PNG_CONST char png_digit[16] = { }; #define PNG_MAX_ERROR_TEXT 64 - -#if !defined(PNG_NO_WARNINGS) || !defined(PNG_NO_ERROR_TEXT) +#if defined(PNG_WARNINGS_SUPPORTED) || defined(PNG_ERROR_TEXT_SUPPORTED) static void /* PRIVATE */ png_format_buffer(png_structp png_ptr, png_charp buffer, png_const_charp error_message) @@ -150,10 +169,10 @@ png_format_buffer(png_structp png_ptr, png_charp buffer, png_const_charp int c = png_ptr->chunk_name[iin++]; if (isnonalpha(c)) { - buffer[iout++] = '['; + buffer[iout++] = PNG_LITERAL_LEFT_SQUARE_BRACKET; buffer[iout++] = png_digit[(c & 0xf0) >> 4]; buffer[iout++] = png_digit[c & 0x0f]; - buffer[iout++] = ']'; + buffer[iout++] = PNG_LITERAL_RIGHT_SQUARE_BRACKET; } else { @@ -167,8 +186,13 @@ png_format_buffer(png_structp png_ptr, png_charp buffer, png_const_charp { buffer[iout++] = ':'; buffer[iout++] = ' '; - png_memcpy(buffer+iout, error_message, PNG_MAX_ERROR_TEXT); - buffer[iout+PNG_MAX_ERROR_TEXT-1] = '\0'; + + iin = 0; + while (iin < PNG_MAX_ERROR_TEXT-1 && error_message[iin] != '\0') + buffer[iout++] = error_message[iin++]; + + /* iin < PNG_MAX_ERROR_TEXT, so the following is safe: */ + buffer[iout] = '\0'; } } @@ -186,9 +210,9 @@ png_chunk_error(png_structp png_ptr, png_const_charp error_message) } } #endif /* PNG_READ_SUPPORTED */ -#endif /* !defined(PNG_NO_WARNINGS) || !defined(PNG_NO_ERROR_TEXT) */ +#endif /* PNG_WARNINGS_SUPPORTED || PNG_ERROR_TEXT_SUPPORTED */ -#ifndef PNG_NO_WARNINGS +#ifdef PNG_WARNINGS_SUPPORTED void PNGAPI png_chunk_warning(png_structp png_ptr, png_const_charp warning_message) { @@ -201,8 +225,20 @@ png_chunk_warning(png_structp png_ptr, png_const_charp warning_message) png_warning(png_ptr, msg); } } -#endif /* PNG_NO_WARNINGS */ +#endif /* PNG_WARNINGS_SUPPORTED */ +#ifdef PNG_READ_SUPPORTED +#ifdef PNG_BENIGN_ERRORS_SUPPORTED +void PNGAPI +png_chunk_benign_error(png_structp png_ptr, png_const_charp error_message) +{ + if (png_ptr->flags & PNG_FLAG_BENIGN_ERRORS_WARN) + png_chunk_warning(png_ptr, error_message); + else + png_chunk_error(png_ptr, error_message); +} +#endif +#endif /* PNG_READ_SUPPORTED */ /* This is the default error handling function. Note that replacements for * this function MUST NOT RETURN, or the program will likely crash. This @@ -212,30 +248,39 @@ png_chunk_warning(png_structp png_ptr, png_const_charp warning_message) static void /* PRIVATE */ png_default_error(png_structp png_ptr, png_const_charp error_message) { -#ifndef PNG_NO_CONSOLE_IO +#ifdef PNG_CONSOLE_IO_SUPPORTED #ifdef PNG_ERROR_NUMBERS_SUPPORTED - if (*error_message == '#') + if (*error_message == PNG_LITERAL_SHARP) { + /* Strip "#nnnn " from beginning of error message. */ int offset; char error_number[16]; - for (offset=0; offset<15; offset++) + for (offset = 0; offset<15; offset++) { - error_number[offset] = *(error_message+offset+1); - if (*(error_message+offset) == ' ') + error_number[offset] = error_message[offset + 1]; + if (error_message[offset] == ' ') break; } - if((offset > 1) && (offset < 15)) + if ((offset > 1) && (offset < 15)) { - error_number[offset-1]='\0'; - fprintf(stderr, "libpng error no. %s: %s\n", error_number, - error_message+offset); + error_number[offset - 1] = '\0'; + fprintf(stderr, "libpng error no. %s: %s", + error_number, error_message + offset + 1); + fprintf(stderr, PNG_STRING_NEWLINE); } else - fprintf(stderr, "libpng error: %s, offset=%d\n", error_message,offset); + { + fprintf(stderr, "libpng error: %s, offset=%d", + error_message, offset); + fprintf(stderr, PNG_STRING_NEWLINE); + } } else #endif - fprintf(stderr, "libpng error: %s\n", error_message); + { + fprintf(stderr, "libpng error: %s", error_message); + fprintf(stderr, PNG_STRING_NEWLINE); + } #endif #ifdef PNG_SETJMP_SUPPORTED @@ -245,21 +290,21 @@ png_default_error(png_structp png_ptr, png_const_charp error_message) { jmp_buf jmpbuf; png_memcpy(jmpbuf, png_ptr->jmpbuf, png_sizeof(jmp_buf)); - longjmp(jmpbuf, 1); + longjmp(jmpbuf,1); } # else longjmp(png_ptr->jmpbuf, 1); # endif } -#else - PNG_ABORT(); #endif -#ifdef PNG_NO_CONSOLE_IO - error_message = error_message; /* make compiler happy */ + /* Here if not setjmp support or if png_ptr is null. */ + PNG_ABORT(); +#ifndef PNG_CONSOLE_IO_SUPPORTED + error_message = error_message; /* Make compiler happy */ #endif } -#ifndef PNG_NO_WARNINGS +#ifdef PNG_WARNINGS_SUPPORTED /* This function is called when there is a warning, but the library thinks * it can continue anyway. Replacement functions don't have to do anything * here if you don't want them to. In the default configuration, png_ptr is @@ -268,36 +313,44 @@ png_default_error(png_structp png_ptr, png_const_charp error_message) static void /* PRIVATE */ png_default_warning(png_structp png_ptr, png_const_charp warning_message) { -#ifndef PNG_NO_CONSOLE_IO +#ifdef PNG_CONSOLE_IO_SUPPORTED # ifdef PNG_ERROR_NUMBERS_SUPPORTED - if (*warning_message == '#') + if (*warning_message == PNG_LITERAL_SHARP) { int offset; char warning_number[16]; - for (offset=0; offset<15; offset++) + for (offset = 0; offset < 15; offset++) { - warning_number[offset]=*(warning_message+offset+1); - if (*(warning_message+offset) == ' ') + warning_number[offset] = warning_message[offset + 1]; + if (warning_message[offset] == ' ') break; } - if((offset > 1) && (offset < 15)) + if ((offset > 1) && (offset < 15)) { - warning_number[offset-1]='\0'; - fprintf(stderr, "libpng warning no. %s: %s\n", warning_number, - warning_message+offset); + warning_number[offset + 1] = '\0'; + fprintf(stderr, "libpng warning no. %s: %s", + warning_number, warning_message + offset); + fprintf(stderr, PNG_STRING_NEWLINE); } else - fprintf(stderr, "libpng warning: %s\n", warning_message); + { + fprintf(stderr, "libpng warning: %s", + warning_message); + fprintf(stderr, PNG_STRING_NEWLINE); + } } else # endif - fprintf(stderr, "libpng warning: %s\n", warning_message); + { + fprintf(stderr, "libpng warning: %s", warning_message); + fprintf(stderr, PNG_STRING_NEWLINE); + } #else - warning_message = warning_message; /* make compiler happy */ + warning_message = warning_message; /* Make compiler happy */ #endif - png_ptr = png_ptr; /* make compiler happy */ + png_ptr = png_ptr; /* Make compiler happy */ } -#endif /* PNG_NO_WARNINGS */ +#endif /* PNG_WARNINGS_SUPPORTED */ /* This function is called when the application wants to use another method * of handling errors and warnings. Note that the error function MUST NOT @@ -333,7 +386,7 @@ png_get_error_ptr(png_structp png_ptr) void PNGAPI png_set_strip_error_numbers(png_structp png_ptr, png_uint_32 strip_mode) { - if(png_ptr != NULL) + if (png_ptr != NULL) { png_ptr->flags &= ((~(PNG_FLAG_STRIP_ERROR_NUMBERS|PNG_FLAG_STRIP_ERROR_TEXT))&strip_mode); diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngget.c b/graf2d/asimage/src/libAfterImage/libpng/pngget.c index a0e90bb6a4f53..d397329a53cd0 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngget.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngget.c @@ -1,16 +1,20 @@ /* pngget.c - retrieval of values from info struct * - * Last changed in libpng 1.2.15 January 5, 2007 - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * Last changed in libpng 1.2.43 [February 25, 2010] + * Copyright (c) 1998-2010 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) + * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h + * */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" - #if defined(PNG_READ_SUPPORTED) || defined(PNG_WRITE_SUPPORTED) png_uint_32 PNGAPI @@ -18,6 +22,7 @@ png_get_valid(png_structp png_ptr, png_infop info_ptr, png_uint_32 flag) { if (png_ptr != NULL && info_ptr != NULL) return(info_ptr->valid & flag); + else return(0); } @@ -27,30 +32,31 @@ png_get_rowbytes(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) return(info_ptr->rowbytes); + else return(0); } -#if defined(PNG_INFO_IMAGE_SUPPORTED) +#ifdef PNG_INFO_IMAGE_SUPPORTED png_bytepp PNGAPI png_get_rows(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) return(info_ptr->row_pointers); + else return(0); } #endif #ifdef PNG_EASY_ACCESS_SUPPORTED -/* easy access to info, added in libpng-0.99 */ +/* Easy access to info, added in libpng-0.99 */ png_uint_32 PNGAPI png_get_image_width(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) - { return info_ptr->width; - } + return (0); } @@ -58,9 +64,8 @@ png_uint_32 PNGAPI png_get_image_height(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) - { return info_ptr->height; - } + return (0); } @@ -68,9 +73,8 @@ png_byte PNGAPI png_get_bit_depth(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) - { return info_ptr->bit_depth; - } + return (0); } @@ -78,9 +82,8 @@ png_byte PNGAPI png_get_color_type(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) - { return info_ptr->color_type; - } + return (0); } @@ -88,9 +91,8 @@ png_byte PNGAPI png_get_filter_type(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) - { return info_ptr->filter_type; - } + return (0); } @@ -98,9 +100,8 @@ png_byte PNGAPI png_get_interlace_type(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) - { return info_ptr->interlace_type; - } + return (0); } @@ -108,9 +109,8 @@ png_byte PNGAPI png_get_compression_type(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) - { return info_ptr->compression_type; - } + return (0); } @@ -118,13 +118,16 @@ png_uint_32 PNGAPI png_get_x_pixels_per_meter(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) -#if defined(PNG_pHYs_SUPPORTED) +#ifdef PNG_pHYs_SUPPORTED if (info_ptr->valid & PNG_INFO_pHYs) { - png_debug1(1, "in %s retrieval function\n", "png_get_x_pixels_per_meter"); - if(info_ptr->phys_unit_type != PNG_RESOLUTION_METER) + png_debug1(1, "in %s retrieval function", "png_get_x_pixels_per_meter"); + + if (info_ptr->phys_unit_type != PNG_RESOLUTION_METER) return (0); - else return (info_ptr->x_pixels_per_unit); + + else + return (info_ptr->x_pixels_per_unit); } #else return (0); @@ -136,13 +139,16 @@ png_uint_32 PNGAPI png_get_y_pixels_per_meter(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) -#if defined(PNG_pHYs_SUPPORTED) +#ifdef PNG_pHYs_SUPPORTED if (info_ptr->valid & PNG_INFO_pHYs) { - png_debug1(1, "in %s retrieval function\n", "png_get_y_pixels_per_meter"); - if(info_ptr->phys_unit_type != PNG_RESOLUTION_METER) + png_debug1(1, "in %s retrieval function", "png_get_y_pixels_per_meter"); + + if (info_ptr->phys_unit_type != PNG_RESOLUTION_METER) return (0); - else return (info_ptr->y_pixels_per_unit); + + else + return (info_ptr->y_pixels_per_unit); } #else return (0); @@ -154,14 +160,17 @@ png_uint_32 PNGAPI png_get_pixels_per_meter(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) -#if defined(PNG_pHYs_SUPPORTED) +#ifdef PNG_pHYs_SUPPORTED if (info_ptr->valid & PNG_INFO_pHYs) { - png_debug1(1, "in %s retrieval function\n", "png_get_pixels_per_meter"); - if(info_ptr->phys_unit_type != PNG_RESOLUTION_METER || + png_debug1(1, "in %s retrieval function", "png_get_pixels_per_meter"); + + if (info_ptr->phys_unit_type != PNG_RESOLUTION_METER || info_ptr->x_pixels_per_unit != info_ptr->y_pixels_per_unit) return (0); - else return (info_ptr->x_pixels_per_unit); + + else + return (info_ptr->x_pixels_per_unit); } #else return (0); @@ -174,18 +183,21 @@ float PNGAPI png_get_pixel_aspect_ratio(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) -#if defined(PNG_pHYs_SUPPORTED) +#ifdef PNG_pHYs_SUPPORTED + if (info_ptr->valid & PNG_INFO_pHYs) { - png_debug1(1, "in %s retrieval function\n", "png_get_aspect_ratio"); + png_debug1(1, "in %s retrieval function", "png_get_aspect_ratio"); + if (info_ptr->x_pixels_per_unit == 0) return ((float)0.0); + else return ((float)((float)info_ptr->y_pixels_per_unit /(float)info_ptr->x_pixels_per_unit)); } #else - return (0.0); + return (0.0); #endif return ((float)0.0); } @@ -195,16 +207,20 @@ png_int_32 PNGAPI png_get_x_offset_microns(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) -#if defined(PNG_oFFs_SUPPORTED) +#ifdef PNG_oFFs_SUPPORTED + if (info_ptr->valid & PNG_INFO_oFFs) { - png_debug1(1, "in %s retrieval function\n", "png_get_x_offset_microns"); - if(info_ptr->offset_unit_type != PNG_OFFSET_MICROMETER) + png_debug1(1, "in %s retrieval function", "png_get_x_offset_microns"); + + if (info_ptr->offset_unit_type != PNG_OFFSET_MICROMETER) return (0); - else return (info_ptr->x_offset); + + else + return (info_ptr->x_offset); } #else - return (0); + return (0); #endif return (0); } @@ -213,13 +229,17 @@ png_int_32 PNGAPI png_get_y_offset_microns(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) -#if defined(PNG_oFFs_SUPPORTED) + +#ifdef PNG_oFFs_SUPPORTED if (info_ptr->valid & PNG_INFO_oFFs) { - png_debug1(1, "in %s retrieval function\n", "png_get_y_offset_microns"); - if(info_ptr->offset_unit_type != PNG_OFFSET_MICROMETER) + png_debug1(1, "in %s retrieval function", "png_get_y_offset_microns"); + + if (info_ptr->offset_unit_type != PNG_OFFSET_MICROMETER) return (0); - else return (info_ptr->y_offset); + + else + return (info_ptr->y_offset); } #else return (0); @@ -231,13 +251,17 @@ png_int_32 PNGAPI png_get_x_offset_pixels(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) -#if defined(PNG_oFFs_SUPPORTED) + +#ifdef PNG_oFFs_SUPPORTED if (info_ptr->valid & PNG_INFO_oFFs) { - png_debug1(1, "in %s retrieval function\n", "png_get_x_offset_microns"); - if(info_ptr->offset_unit_type != PNG_OFFSET_PIXEL) + png_debug1(1, "in %s retrieval function", "png_get_x_offset_microns"); + + if (info_ptr->offset_unit_type != PNG_OFFSET_PIXEL) return (0); - else return (info_ptr->x_offset); + + else + return (info_ptr->x_offset); } #else return (0); @@ -249,13 +273,17 @@ png_int_32 PNGAPI png_get_y_offset_pixels(png_structp png_ptr, png_infop info_ptr) { if (png_ptr != NULL && info_ptr != NULL) -#if defined(PNG_oFFs_SUPPORTED) + +#ifdef PNG_oFFs_SUPPORTED if (info_ptr->valid & PNG_INFO_oFFs) { - png_debug1(1, "in %s retrieval function\n", "png_get_y_offset_microns"); - if(info_ptr->offset_unit_type != PNG_OFFSET_PIXEL) + png_debug1(1, "in %s retrieval function", "png_get_y_offset_microns"); + + if (info_ptr->offset_unit_type != PNG_OFFSET_PIXEL) return (0); - else return (info_ptr->y_offset); + + else + return (info_ptr->y_offset); } #else return (0); @@ -299,7 +327,7 @@ png_get_y_offset_inches(png_structp png_ptr, png_infop info_ptr) *.00003937); } -#if defined(PNG_pHYs_SUPPORTED) +#ifdef PNG_pHYs_SUPPORTED png_uint_32 PNGAPI png_get_pHYs_dpi(png_structp png_ptr, png_infop info_ptr, png_uint_32 *res_x, png_uint_32 *res_y, int *unit_type) @@ -308,7 +336,8 @@ png_get_pHYs_dpi(png_structp png_ptr, png_infop info_ptr, if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_pHYs)) { - png_debug1(1, "in %s retrieval function\n", "pHYs"); + png_debug1(1, "in %s retrieval function", "pHYs"); + if (res_x != NULL) { *res_x = info_ptr->x_pixels_per_unit; @@ -323,7 +352,7 @@ png_get_pHYs_dpi(png_structp png_ptr, png_infop info_ptr, { *unit_type = (int)info_ptr->phys_unit_type; retval |= PNG_INFO_pHYs; - if(*unit_type == 1) + if (*unit_type == 1) { if (res_x != NULL) *res_x = (png_uint_32)(*res_x * .0254 + .50); if (res_y != NULL) *res_y = (png_uint_32)(*res_y * .0254 + .50); @@ -357,7 +386,7 @@ png_get_signature(png_structp png_ptr, png_infop info_ptr) return (NULL); } -#if defined(PNG_bKGD_SUPPORTED) +#ifdef PNG_bKGD_SUPPORTED png_uint_32 PNGAPI png_get_bKGD(png_structp png_ptr, png_infop info_ptr, png_color_16p *background) @@ -365,7 +394,8 @@ png_get_bKGD(png_structp png_ptr, png_infop info_ptr, if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_bKGD) && background != NULL) { - png_debug1(1, "in %s retrieval function\n", "bKGD"); + png_debug1(1, "in %s retrieval function", "bKGD"); + *background = &(info_ptr->background); return (PNG_INFO_bKGD); } @@ -373,7 +403,7 @@ png_get_bKGD(png_structp png_ptr, png_infop info_ptr, } #endif -#if defined(PNG_cHRM_SUPPORTED) +#ifdef PNG_cHRM_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED png_uint_32 PNGAPI png_get_cHRM(png_structp png_ptr, png_infop info_ptr, @@ -382,7 +412,8 @@ png_get_cHRM(png_structp png_ptr, png_infop info_ptr, { if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_cHRM)) { - png_debug1(1, "in %s retrieval function\n", "cHRM"); + png_debug1(1, "in %s retrieval function", "cHRM"); + if (white_x != NULL) *white_x = (double)info_ptr->x_white; if (white_y != NULL) @@ -411,9 +442,10 @@ png_get_cHRM_fixed(png_structp png_ptr, png_infop info_ptr, png_fixed_point *red_y, png_fixed_point *green_x, png_fixed_point *green_y, png_fixed_point *blue_x, png_fixed_point *blue_y) { + png_debug1(1, "in %s retrieval function", "cHRM"); + if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_cHRM)) { - png_debug1(1, "in %s retrieval function\n", "cHRM"); if (white_x != NULL) *white_x = info_ptr->int_x_white; if (white_y != NULL) @@ -437,15 +469,16 @@ png_get_cHRM_fixed(png_structp png_ptr, png_infop info_ptr, #endif #endif -#if defined(PNG_gAMA_SUPPORTED) +#ifdef PNG_gAMA_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED png_uint_32 PNGAPI png_get_gAMA(png_structp png_ptr, png_infop info_ptr, double *file_gamma) { + png_debug1(1, "in %s retrieval function", "gAMA"); + if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_gAMA) && file_gamma != NULL) { - png_debug1(1, "in %s retrieval function\n", "gAMA"); *file_gamma = (double)info_ptr->gamma; return (PNG_INFO_gAMA); } @@ -457,10 +490,11 @@ png_uint_32 PNGAPI png_get_gAMA_fixed(png_structp png_ptr, png_infop info_ptr, png_fixed_point *int_file_gamma) { + png_debug1(1, "in %s retrieval function", "gAMA"); + if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_gAMA) && int_file_gamma != NULL) { - png_debug1(1, "in %s retrieval function\n", "gAMA"); *int_file_gamma = info_ptr->int_gamma; return (PNG_INFO_gAMA); } @@ -469,14 +503,15 @@ png_get_gAMA_fixed(png_structp png_ptr, png_infop info_ptr, #endif #endif -#if defined(PNG_sRGB_SUPPORTED) +#ifdef PNG_sRGB_SUPPORTED png_uint_32 PNGAPI png_get_sRGB(png_structp png_ptr, png_infop info_ptr, int *file_srgb_intent) { + png_debug1(1, "in %s retrieval function", "sRGB"); + if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_sRGB) && file_srgb_intent != NULL) { - png_debug1(1, "in %s retrieval function\n", "sRGB"); *file_srgb_intent = (int)info_ptr->srgb_intent; return (PNG_INFO_sRGB); } @@ -484,20 +519,22 @@ png_get_sRGB(png_structp png_ptr, png_infop info_ptr, int *file_srgb_intent) } #endif -#if defined(PNG_iCCP_SUPPORTED) +#ifdef PNG_iCCP_SUPPORTED png_uint_32 PNGAPI png_get_iCCP(png_structp png_ptr, png_infop info_ptr, png_charpp name, int *compression_type, png_charpp profile, png_uint_32 *proflen) { + png_debug1(1, "in %s retrieval function", "iCCP"); + if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_iCCP) && name != NULL && profile != NULL && proflen != NULL) { - png_debug1(1, "in %s retrieval function\n", "iCCP"); *name = info_ptr->iccp_name; *profile = info_ptr->iccp_profile; - /* compression_type is a dummy so the API won't have to change - if we introduce multiple compression types later. */ + /* Compression_type is a dummy so the API won't have to change + * if we introduce multiple compression types later. + */ *proflen = (int)info_ptr->iccp_proflen; *compression_type = (int)info_ptr->iccp_compression; return (PNG_INFO_iCCP); @@ -506,7 +543,7 @@ png_get_iCCP(png_structp png_ptr, png_infop info_ptr, } #endif -#if defined(PNG_sPLT_SUPPORTED) +#ifdef PNG_sPLT_SUPPORTED png_uint_32 PNGAPI png_get_sPLT(png_structp png_ptr, png_infop info_ptr, png_sPLT_tpp spalettes) @@ -520,14 +557,15 @@ png_get_sPLT(png_structp png_ptr, png_infop info_ptr, } #endif -#if defined(PNG_hIST_SUPPORTED) +#ifdef PNG_hIST_SUPPORTED png_uint_32 PNGAPI png_get_hIST(png_structp png_ptr, png_infop info_ptr, png_uint_16p *hist) { + png_debug1(1, "in %s retrieval function", "hIST"); + if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_hIST) && hist != NULL) { - png_debug1(1, "in %s retrieval function\n", "hIST"); *hist = info_ptr->hist; return (PNG_INFO_hIST); } @@ -542,54 +580,48 @@ png_get_IHDR(png_structp png_ptr, png_infop info_ptr, int *filter_type) { - if (png_ptr != NULL && info_ptr != NULL && width != NULL && height != NULL && - bit_depth != NULL && color_type != NULL) - { - png_debug1(1, "in %s retrieval function\n", "IHDR"); - *width = info_ptr->width; - *height = info_ptr->height; - *bit_depth = info_ptr->bit_depth; - if (info_ptr->bit_depth < 1 || info_ptr->bit_depth > 16) - png_error(png_ptr, "Invalid bit depth"); - *color_type = info_ptr->color_type; - if (info_ptr->color_type > 6) - png_error(png_ptr, "Invalid color type"); - if (compression_type != NULL) - *compression_type = info_ptr->compression_type; - if (filter_type != NULL) - *filter_type = info_ptr->filter_type; - if (interlace_type != NULL) - *interlace_type = info_ptr->interlace_type; - - /* check for potential overflow of rowbytes */ - if (*width == 0 || *width > PNG_UINT_31_MAX) - png_error(png_ptr, "Invalid image width"); - if (*height == 0 || *height > PNG_UINT_31_MAX) - png_error(png_ptr, "Invalid image height"); - if (info_ptr->width > (PNG_UINT_32_MAX - >> 3) /* 8-byte RGBA pixels */ - - 64 /* bigrowbuf hack */ - - 1 /* filter byte */ - - 7*8 /* rounding of width to multiple of 8 pixels */ - - 8) /* extra max_pixel_depth pad */ - { - png_warning(png_ptr, - "Width too large for libpng to process image data."); - } - return (1); - } - return (0); + png_debug1(1, "in %s retrieval function", "IHDR"); + + if (png_ptr == NULL || info_ptr == NULL || width == NULL || + height == NULL || bit_depth == NULL || color_type == NULL) + return (0); + + *width = info_ptr->width; + *height = info_ptr->height; + *bit_depth = info_ptr->bit_depth; + *color_type = info_ptr->color_type; + + if (compression_type != NULL) + *compression_type = info_ptr->compression_type; + + if (filter_type != NULL) + *filter_type = info_ptr->filter_type; + + if (interlace_type != NULL) + *interlace_type = info_ptr->interlace_type; + + /* This is redundant if we can be sure that the info_ptr values were all + * assigned in png_set_IHDR(). We do the check anyhow in case an + * application has ignored our advice not to mess with the members + * of info_ptr directly. + */ + png_check_IHDR (png_ptr, info_ptr->width, info_ptr->height, + info_ptr->bit_depth, info_ptr->color_type, info_ptr->interlace_type, + info_ptr->compression_type, info_ptr->filter_type); + + return (1); } -#if defined(PNG_oFFs_SUPPORTED) +#ifdef PNG_oFFs_SUPPORTED png_uint_32 PNGAPI png_get_oFFs(png_structp png_ptr, png_infop info_ptr, png_int_32 *offset_x, png_int_32 *offset_y, int *unit_type) { + png_debug1(1, "in %s retrieval function", "oFFs"); + if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_oFFs) && offset_x != NULL && offset_y != NULL && unit_type != NULL) { - png_debug1(1, "in %s retrieval function\n", "oFFs"); *offset_x = info_ptr->x_offset; *offset_y = info_ptr->y_offset; *unit_type = (int)info_ptr->offset_unit_type; @@ -599,17 +631,18 @@ png_get_oFFs(png_structp png_ptr, png_infop info_ptr, } #endif -#if defined(PNG_pCAL_SUPPORTED) +#ifdef PNG_pCAL_SUPPORTED png_uint_32 PNGAPI png_get_pCAL(png_structp png_ptr, png_infop info_ptr, png_charp *purpose, png_int_32 *X0, png_int_32 *X1, int *type, int *nparams, png_charp *units, png_charpp *params) { + png_debug1(1, "in %s retrieval function", "pCAL"); + if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_pCAL) - && purpose != NULL && X0 != NULL && X1 != NULL && type != NULL && - nparams != NULL && units != NULL && params != NULL) + && purpose != NULL && X0 != NULL && X1 != NULL && type != NULL && + nparams != NULL && units != NULL && params != NULL) { - png_debug1(1, "in %s retrieval function\n", "pCAL"); *purpose = info_ptr->pcal_purpose; *X0 = info_ptr->pcal_X0; *X1 = info_ptr->pcal_X1; @@ -623,14 +656,14 @@ png_get_pCAL(png_structp png_ptr, png_infop info_ptr, } #endif -#if defined(PNG_sCAL_SUPPORTED) +#ifdef PNG_sCAL_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED png_uint_32 PNGAPI png_get_sCAL(png_structp png_ptr, png_infop info_ptr, int *unit, double *width, double *height) { if (png_ptr != NULL && info_ptr != NULL && - (info_ptr->valid & PNG_INFO_sCAL)) + (info_ptr->valid & PNG_INFO_sCAL)) { *unit = info_ptr->scal_unit; *width = info_ptr->scal_pixel_width; @@ -646,7 +679,7 @@ png_get_sCAL_s(png_structp png_ptr, png_infop info_ptr, int *unit, png_charpp width, png_charpp height) { if (png_ptr != NULL && info_ptr != NULL && - (info_ptr->valid & PNG_INFO_sCAL)) + (info_ptr->valid & PNG_INFO_sCAL)) { *unit = info_ptr->scal_unit; *width = info_ptr->scal_s_width; @@ -659,27 +692,30 @@ png_get_sCAL_s(png_structp png_ptr, png_infop info_ptr, #endif #endif -#if defined(PNG_pHYs_SUPPORTED) +#ifdef PNG_pHYs_SUPPORTED png_uint_32 PNGAPI png_get_pHYs(png_structp png_ptr, png_infop info_ptr, png_uint_32 *res_x, png_uint_32 *res_y, int *unit_type) { png_uint_32 retval = 0; + png_debug1(1, "in %s retrieval function", "pHYs"); + if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_pHYs)) { - png_debug1(1, "in %s retrieval function\n", "pHYs"); if (res_x != NULL) { *res_x = info_ptr->x_pixels_per_unit; retval |= PNG_INFO_pHYs; } + if (res_y != NULL) { *res_y = info_ptr->y_pixels_per_unit; retval |= PNG_INFO_pHYs; } + if (unit_type != NULL) { *unit_type = (int)info_ptr->phys_unit_type; @@ -694,26 +730,28 @@ png_uint_32 PNGAPI png_get_PLTE(png_structp png_ptr, png_infop info_ptr, png_colorp *palette, int *num_palette) { + png_debug1(1, "in %s retrieval function", "PLTE"); + if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_PLTE) && palette != NULL) { - png_debug1(1, "in %s retrieval function\n", "PLTE"); *palette = info_ptr->palette; *num_palette = info_ptr->num_palette; - png_debug1(3, "num_palette = %d\n", *num_palette); + png_debug1(3, "num_palette = %d", *num_palette); return (PNG_INFO_PLTE); } return (0); } -#if defined(PNG_sBIT_SUPPORTED) +#ifdef PNG_sBIT_SUPPORTED png_uint_32 PNGAPI png_get_sBIT(png_structp png_ptr, png_infop info_ptr, png_color_8p *sig_bit) { + png_debug1(1, "in %s retrieval function", "sBIT"); + if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_sBIT) && sig_bit != NULL) { - png_debug1(1, "in %s retrieval function\n", "sBIT"); *sig_bit = &(info_ptr->sig_bit); return (PNG_INFO_sBIT); } @@ -721,20 +759,23 @@ png_get_sBIT(png_structp png_ptr, png_infop info_ptr, png_color_8p *sig_bit) } #endif -#if defined(PNG_TEXT_SUPPORTED) +#ifdef PNG_TEXT_SUPPORTED png_uint_32 PNGAPI png_get_text(png_structp png_ptr, png_infop info_ptr, png_textp *text_ptr, int *num_text) { if (png_ptr != NULL && info_ptr != NULL && info_ptr->num_text > 0) { - png_debug1(1, "in %s retrieval function\n", + png_debug1(1, "in %s retrieval function", (png_ptr->chunk_name[0] == '\0' ? "text" : (png_const_charp)png_ptr->chunk_name)); + if (text_ptr != NULL) *text_ptr = info_ptr->text; + if (num_text != NULL) *num_text = info_ptr->num_text; + return ((png_uint_32)info_ptr->num_text); } if (num_text != NULL) @@ -743,14 +784,15 @@ png_get_text(png_structp png_ptr, png_infop info_ptr, png_textp *text_ptr, } #endif -#if defined(PNG_tIME_SUPPORTED) +#ifdef PNG_tIME_SUPPORTED png_uint_32 PNGAPI png_get_tIME(png_structp png_ptr, png_infop info_ptr, png_timep *mod_time) { + png_debug1(1, "in %s retrieval function", "tIME"); + if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_tIME) && mod_time != NULL) { - png_debug1(1, "in %s retrieval function\n", "tIME"); *mod_time = &(info_ptr->mod_time); return (PNG_INFO_tIME); } @@ -758,7 +800,7 @@ png_get_tIME(png_structp png_ptr, png_infop info_ptr, png_timep *mod_time) } #endif -#if defined(PNG_tRNS_SUPPORTED) +#ifdef PNG_tRNS_SUPPORTED png_uint_32 PNGAPI png_get_tRNS(png_structp png_ptr, png_infop info_ptr, png_bytep *trans, int *num_trans, png_color_16p *trans_values) @@ -766,7 +808,8 @@ png_get_tRNS(png_structp png_ptr, png_infop info_ptr, png_uint_32 retval = 0; if (png_ptr != NULL && info_ptr != NULL && (info_ptr->valid & PNG_INFO_tRNS)) { - png_debug1(1, "in %s retrieval function\n", "tRNS"); + png_debug1(1, "in %s retrieval function", "tRNS"); + if (info_ptr->color_type == PNG_COLOR_TYPE_PALETTE) { if (trans != NULL) @@ -774,6 +817,7 @@ png_get_tRNS(png_structp png_ptr, png_infop info_ptr, *trans = info_ptr->trans; retval |= PNG_INFO_tRNS; } + if (trans_values != NULL) *trans_values = &(info_ptr->trans_values); } @@ -784,10 +828,11 @@ png_get_tRNS(png_structp png_ptr, png_infop info_ptr, *trans_values = &(info_ptr->trans_values); retval |= PNG_INFO_tRNS; } - if(trans != NULL) + + if (trans != NULL) *trans = NULL; } - if(num_trans != NULL) + if (num_trans != NULL) { *num_trans = info_ptr->num_trans; retval |= PNG_INFO_tRNS; @@ -797,7 +842,7 @@ png_get_tRNS(png_structp png_ptr, png_infop info_ptr, } #endif -#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) +#ifdef PNG_UNKNOWN_CHUNKS_SUPPORTED png_uint_32 PNGAPI png_get_unknown_chunks(png_structp png_ptr, png_infop info_ptr, png_unknown_chunkpp unknowns) @@ -811,7 +856,7 @@ png_get_unknown_chunks(png_structp png_ptr, png_infop info_ptr, } #endif -#if defined(PNG_READ_RGB_TO_GRAY_SUPPORTED) +#ifdef PNG_READ_RGB_TO_GRAY_SUPPORTED png_byte PNGAPI png_get_rgb_to_gray_status (png_structp png_ptr) { @@ -819,7 +864,7 @@ png_get_rgb_to_gray_status (png_structp png_ptr) } #endif -#if defined(PNG_USER_CHUNKS_SUPPORTED) +#ifdef PNG_USER_CHUNKS_SUPPORTED png_voidp PNGAPI png_get_user_chunk_ptr(png_structp png_ptr) { @@ -827,64 +872,63 @@ png_get_user_chunk_ptr(png_structp png_ptr) } #endif -#ifdef PNG_WRITE_SUPPORTED png_uint_32 PNGAPI png_get_compression_buffer_size(png_structp png_ptr) { return (png_uint_32)(png_ptr? png_ptr->zbuf_size : 0L); } -#endif #ifdef PNG_ASSEMBLER_CODE_SUPPORTED #ifndef PNG_1_0_X -/* this function was added to libpng 1.2.0 and should exist by default */ +/* This function was added to libpng 1.2.0 and should exist by default */ png_uint_32 PNGAPI png_get_asm_flags (png_structp png_ptr) { - /* obsolete, to be removed from libpng-1.4.0 */ + /* Obsolete, to be removed from libpng-1.4.0 */ return (png_ptr? 0L: 0L); } -/* this function was added to libpng 1.2.0 and should exist by default */ +/* This function was added to libpng 1.2.0 and should exist by default */ png_uint_32 PNGAPI png_get_asm_flagmask (int flag_select) { - /* obsolete, to be removed from libpng-1.4.0 */ + /* Obsolete, to be removed from libpng-1.4.0 */ flag_select=flag_select; return 0L; } /* GRR: could add this: && defined(PNG_MMX_CODE_SUPPORTED) */ -/* this function was added to libpng 1.2.0 */ +/* This function was added to libpng 1.2.0 */ png_uint_32 PNGAPI png_get_mmx_flagmask (int flag_select, int *compilerID) { - /* obsolete, to be removed from libpng-1.4.0 */ + /* Obsolete, to be removed from libpng-1.4.0 */ flag_select=flag_select; *compilerID = -1; /* unknown (i.e., no asm/MMX code compiled) */ return 0L; } -/* this function was added to libpng 1.2.0 */ +/* This function was added to libpng 1.2.0 */ png_byte PNGAPI png_get_mmx_bitdepth_threshold (png_structp png_ptr) { - /* obsolete, to be removed from libpng-1.4.0 */ + /* Obsolete, to be removed from libpng-1.4.0 */ return (png_ptr? 0: 0); } -/* this function was added to libpng 1.2.0 */ +/* This function was added to libpng 1.2.0 */ png_uint_32 PNGAPI png_get_mmx_rowbytes_threshold (png_structp png_ptr) { - /* obsolete, to be removed from libpng-1.4.0 */ + /* Obsolete, to be removed from libpng-1.4.0 */ return (png_ptr? 0L: 0L); } #endif /* ?PNG_1_0_X */ #endif /* ?PNG_ASSEMBLER_CODE_SUPPORTED */ #ifdef PNG_SET_USER_LIMITS_SUPPORTED -/* these functions were added to libpng 1.2.6 */ +/* These functions were added to libpng 1.2.6 but not enabled +* by default. They will be enabled in libpng-1.4.0 */ png_uint_32 PNGAPI png_get_user_width_max (png_structp png_ptr) { @@ -896,6 +940,5 @@ png_get_user_height_max (png_structp png_ptr) return (png_ptr? png_ptr->user_height_max : 0); } #endif /* ?PNG_SET_USER_LIMITS_SUPPORTED */ - #endif /* PNG_READ_SUPPORTED || PNG_WRITE_SUPPORTED */ diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngmem.c b/graf2d/asimage/src/libAfterImage/libpng/pngmem.c index 248060f38175a..a18719b81bbe2 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngmem.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngmem.c @@ -1,12 +1,15 @@ /* pngmem.c - stub functions for memory allocation * - * Last changed in libpng 1.2.13 November 13, 2006 - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2006 Glenn Randers-Pehrson + * Last changed in libpng 1.2.41 [February 25, 2010] + * Copyright (c) 1998-2010 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h + * * This file provides a location for all memory allocation. Users who * need special memory handling are expected to supply replacement * functions for png_malloc() and png_free(), and to use @@ -15,13 +18,13 @@ */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" - #if defined(PNG_READ_SUPPORTED) || defined(PNG_WRITE_SUPPORTED) /* Borland DOS special memory handler */ #if defined(__TURBOC__) && !defined(_Windows) && !defined(__FLAT__) -/* if you change this, be sure to change the one in png.h also */ +/* If you change this, be sure to change the one in png.h also */ /* Allocate memory for a png_struct. The malloc and memset can be replaced by a single call to calloc() if this is thought to improve performance. */ @@ -41,14 +44,14 @@ png_create_struct_2(int type, png_malloc_ptr malloc_fn, png_voidp mem_ptr) png_voidp struct_ptr; if (type == PNG_STRUCT_INFO) - size = png_sizeof(png_info); + size = png_sizeof(png_info); else if (type == PNG_STRUCT_PNG) - size = png_sizeof(png_struct); + size = png_sizeof(png_struct); else - return (png_get_copyright(NULL)); + return (png_get_copyright(NULL)); #ifdef PNG_USER_MEM_SUPPORTED - if(malloc_fn != NULL) + if (malloc_fn != NULL) { png_struct dummy_struct; png_structp png_ptr = &dummy_struct; @@ -57,7 +60,7 @@ png_create_struct_2(int type, png_malloc_ptr malloc_fn, png_voidp mem_ptr) } else #endif /* PNG_USER_MEM_SUPPORTED */ - struct_ptr = (png_voidp)farmalloc(size); + struct_ptr = (png_voidp)farmalloc(size); if (struct_ptr != NULL) png_memset(struct_ptr, 0, size); return (struct_ptr); @@ -80,7 +83,7 @@ png_destroy_struct_2(png_voidp struct_ptr, png_free_ptr free_fn, if (struct_ptr != NULL) { #ifdef PNG_USER_MEM_SUPPORTED - if(free_fn != NULL) + if (free_fn != NULL) { png_struct dummy_struct; png_structp png_ptr = &dummy_struct; @@ -112,6 +115,16 @@ png_destroy_struct_2(png_voidp struct_ptr, png_free_ptr free_fn, * result, we would be truncating potentially larger memory requests * (which should cause a fatal error) and introducing major problems. */ +png_voidp /* PRIVATE */ +png_calloc(png_structp png_ptr, png_uint_32 size) +{ + png_voidp ret; + + ret = (png_malloc(png_ptr, size)); + if (ret != NULL) + png_memset(ret,0,(png_size_t)size); + return (ret); +} png_voidp PNGAPI png_malloc(png_structp png_ptr, png_uint_32 size) @@ -122,10 +135,10 @@ png_malloc(png_structp png_ptr, png_uint_32 size) return (NULL); #ifdef PNG_USER_MEM_SUPPORTED - if(png_ptr->malloc_fn != NULL) - ret = ((png_voidp)(*(png_ptr->malloc_fn))(png_ptr, (png_size_t)size)); + if (png_ptr->malloc_fn != NULL) + ret = ((png_voidp)(*(png_ptr->malloc_fn))(png_ptr, (png_size_t)size)); else - ret = (png_malloc_default(png_ptr, size)); + ret = (png_malloc_default(png_ptr, size)); if (ret == NULL && (png_ptr->flags&PNG_FLAG_MALLOC_NULL_MEM_OK) == 0) png_error(png_ptr, "Out of memory!"); return (ret); @@ -150,12 +163,12 @@ png_malloc_default(png_structp png_ptr, png_uint_32 size) #endif if (size != (size_t)size) - ret = NULL; + ret = NULL; else if (size == (png_uint_32)65536L) { if (png_ptr->offset_table == NULL) { - /* try to see if we need to do any of this fancy stuff */ + /* Try to see if we need to do any of this fancy stuff */ ret = farmalloc(size); if (ret == NULL || ((png_size_t)ret & 0xffff)) { @@ -171,7 +184,7 @@ png_malloc_default(png_structp png_ptr, png_uint_32 size) ret = NULL; } - if(png_ptr->zlib_window_bits > 14) + if (png_ptr->zlib_window_bits > 14) num_blocks = (int)(1 << (png_ptr->zlib_window_bits - 14)); else num_blocks = 1; @@ -188,7 +201,7 @@ png_malloc_default(png_structp png_ptr, png_uint_32 size) { #ifndef PNG_USER_MEM_SUPPORTED if ((png_ptr->flags&PNG_FLAG_MALLOC_NULL_MEM_OK) == 0) - png_error(png_ptr, "Out Of Memory."); /* Note "O" and "M" */ + png_error(png_ptr, "Out Of Memory."); /* Note "O", "M" */ else png_warning(png_ptr, "Out Of Memory."); #endif @@ -210,13 +223,13 @@ png_malloc_default(png_structp png_ptr, png_uint_32 size) png_ptr->offset_table = table; png_ptr->offset_table_ptr = farmalloc(num_blocks * - png_sizeof (png_bytep)); + png_sizeof(png_bytep)); if (png_ptr->offset_table_ptr == NULL) { #ifndef PNG_USER_MEM_SUPPORTED if ((png_ptr->flags&PNG_FLAG_MALLOC_NULL_MEM_OK) == 0) - png_error(png_ptr, "Out Of memory."); /* Note "O" and "M" */ + png_error(png_ptr, "Out Of memory."); /* Note "O", "m" */ else png_warning(png_ptr, "Out Of memory."); #endif @@ -270,9 +283,10 @@ png_malloc_default(png_structp png_ptr, png_uint_32 size) return (ret); } -/* free a pointer allocated by png_malloc(). In the default - configuration, png_ptr is not used, but is passed in case it - is needed. If ptr is NULL, return without taking any action. */ +/* Free a pointer allocated by png_malloc(). In the default + * configuration, png_ptr is not used, but is passed in case it + * is needed. If ptr is NULL, return without taking any action. + */ void PNGAPI png_free(png_structp png_ptr, png_voidp ptr) { @@ -285,7 +299,8 @@ png_free(png_structp png_ptr, png_voidp ptr) (*(png_ptr->free_fn))(png_ptr, ptr); return; } - else png_free_default(png_ptr, ptr); + else + png_free_default(png_ptr, ptr); } void PNGAPI @@ -293,7 +308,8 @@ png_free_default(png_structp png_ptr, png_voidp ptr) { #endif /* PNG_USER_MEM_SUPPORTED */ - if(png_ptr == NULL) return; + if (png_ptr == NULL || ptr == NULL) + return; if (png_ptr->offset_table != NULL) { @@ -353,7 +369,7 @@ png_create_struct_2(int type, png_malloc_ptr malloc_fn, png_voidp mem_ptr) return (NULL); #ifdef PNG_USER_MEM_SUPPORTED - if(malloc_fn != NULL) + if (malloc_fn != NULL) { png_struct dummy_struct; png_structp png_ptr = &dummy_struct; @@ -369,7 +385,7 @@ png_create_struct_2(int type, png_malloc_ptr malloc_fn, png_voidp mem_ptr) struct_ptr = (png_voidp)farmalloc(size); #else # if defined(_MSC_VER) && defined(MAXSEG_64K) - struct_ptr = (png_voidp)halloc(size,1); + struct_ptr = (png_voidp)halloc(size, 1); # else struct_ptr = (png_voidp)malloc(size); # endif @@ -398,7 +414,7 @@ png_destroy_struct_2(png_voidp struct_ptr, png_free_ptr free_fn, if (struct_ptr != NULL) { #ifdef PNG_USER_MEM_SUPPORTED - if(free_fn != NULL) + if (free_fn != NULL) { png_struct dummy_struct; png_structp png_ptr = &dummy_struct; @@ -420,10 +436,22 @@ png_destroy_struct_2(png_voidp struct_ptr, png_free_ptr free_fn, } /* Allocate memory. For reasonable files, size should never exceed - 64K. However, zlib may allocate more then 64K if you don't tell - it not to. See zconf.h and png.h for more information. zlib does - need to allocate exactly 64K, so whatever you call here must - have the ability to do that. */ + * 64K. However, zlib may allocate more then 64K if you don't tell + * it not to. See zconf.h and png.h for more information. zlib does + * need to allocate exactly 64K, so whatever you call here must + * have the ability to do that. + */ + +png_voidp /* PRIVATE */ +png_calloc(png_structp png_ptr, png_uint_32 size) +{ + png_voidp ret; + + ret = (png_malloc(png_ptr, size)); + if (ret != NULL) + png_memset(ret,0,(png_size_t)size); + return (ret); +} png_voidp PNGAPI png_malloc(png_structp png_ptr, png_uint_32 size) @@ -434,10 +462,10 @@ png_malloc(png_structp png_ptr, png_uint_32 size) if (png_ptr == NULL || size == 0) return (NULL); - if(png_ptr->malloc_fn != NULL) - ret = ((png_voidp)(*(png_ptr->malloc_fn))(png_ptr, (png_size_t)size)); + if (png_ptr->malloc_fn != NULL) + ret = ((png_voidp)(*(png_ptr->malloc_fn))(png_ptr, (png_size_t)size)); else - ret = (png_malloc_default(png_ptr, size)); + ret = (png_malloc_default(png_ptr, size)); if (ret == NULL && (png_ptr->flags&PNG_FLAG_MALLOC_NULL_MEM_OK) == 0) png_error(png_ptr, "Out of Memory!"); return (ret); @@ -456,7 +484,7 @@ png_malloc_default(png_structp png_ptr, png_uint_32 size) if (size > (png_uint_32)65536L) { #ifndef PNG_USER_MEM_SUPPORTED - if(png_ptr->flags&PNG_FLAG_MALLOC_NULL_MEM_OK) == 0) + if ((png_ptr->flags&PNG_FLAG_MALLOC_NULL_MEM_OK) == 0) png_error(png_ptr, "Cannot Allocate > 64K"); else #endif @@ -464,23 +492,23 @@ png_malloc_default(png_structp png_ptr, png_uint_32 size) } #endif - /* Check for overflow */ + /* Check for overflow */ #if defined(__TURBOC__) && !defined(__FLAT__) - if (size != (unsigned long)size) - ret = NULL; - else - ret = farmalloc(size); + if (size != (unsigned long)size) + ret = NULL; + else + ret = farmalloc(size); #else # if defined(_MSC_VER) && defined(MAXSEG_64K) - if (size != (unsigned long)size) - ret = NULL; - else - ret = halloc(size, 1); + if (size != (unsigned long)size) + ret = NULL; + else + ret = halloc(size, 1); # else - if (size != (size_t)size) - ret = NULL; - else - ret = malloc((size_t)size); + if (size != (size_t)size) + ret = NULL; + else + ret = malloc((size_t)size); # endif #endif @@ -493,7 +521,8 @@ png_malloc_default(png_structp png_ptr, png_uint_32 size) } /* Free a pointer allocated by png_malloc(). If ptr is NULL, return - without taking any action. */ + * without taking any action. + */ void PNGAPI png_free(png_structp png_ptr, png_voidp ptr) { @@ -506,7 +535,8 @@ png_free(png_structp png_ptr, png_voidp ptr) (*(png_ptr->free_fn))(png_ptr, ptr); return; } - else png_free_default(png_ptr, ptr); + else + png_free_default(png_ptr, ptr); } void PNGAPI png_free_default(png_structp png_ptr, png_voidp ptr) @@ -529,7 +559,7 @@ png_free_default(png_structp png_ptr, png_voidp ptr) #endif /* Not Borland DOS special memory handler */ -#if defined(PNG_1_0_X) +#ifdef PNG_1_0_X # define png_malloc_warn png_malloc #else /* This function was added at libpng version 1.2.3. The png_malloc_warn() @@ -542,9 +572,10 @@ png_malloc_warn(png_structp png_ptr, png_uint_32 size) { png_voidp ptr; png_uint_32 save_flags; - if(png_ptr == NULL) return (NULL); + if (png_ptr == NULL) + return (NULL); - save_flags=png_ptr->flags; + save_flags = png_ptr->flags; png_ptr->flags|=PNG_FLAG_MALLOC_NULL_MEM_OK; ptr = (png_voidp)png_malloc((png_structp)png_ptr, size); png_ptr->flags=save_flags; @@ -560,7 +591,7 @@ png_memcpy_check (png_structp png_ptr, png_voidp s1, png_voidp s2, size = (png_size_t)length; if ((png_uint_32)size != length) - png_error(png_ptr,"Overflow in png_memcpy_check."); + png_error(png_ptr, "Overflow in png_memcpy_check."); return(png_memcpy (s1, s2, size)); } @@ -573,7 +604,7 @@ png_memset_check (png_structp png_ptr, png_voidp s1, int value, size = (png_size_t)length; if ((png_uint_32)size != length) - png_error(png_ptr,"Overflow in png_memset_check."); + png_error(png_ptr, "Overflow in png_memset_check."); return (png_memset (s1, value, size)); @@ -587,10 +618,11 @@ void PNGAPI png_set_mem_fn(png_structp png_ptr, png_voidp mem_ptr, png_malloc_ptr malloc_fn, png_free_ptr free_fn) { - if(png_ptr != NULL) { - png_ptr->mem_ptr = mem_ptr; - png_ptr->malloc_fn = malloc_fn; - png_ptr->free_fn = free_fn; + if (png_ptr != NULL) + { + png_ptr->mem_ptr = mem_ptr; + png_ptr->malloc_fn = malloc_fn; + png_ptr->free_fn = free_fn; } } @@ -601,7 +633,8 @@ png_set_mem_fn(png_structp png_ptr, png_voidp mem_ptr, png_malloc_ptr png_voidp PNGAPI png_get_mem_ptr(png_structp png_ptr) { - if(png_ptr == NULL) return (NULL); + if (png_ptr == NULL) + return (NULL); return ((png_voidp)png_ptr->mem_ptr); } #endif /* PNG_USER_MEM_SUPPORTED */ diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngpread.c b/graf2d/asimage/src/libAfterImage/libpng/pngpread.c index 87973ae64db4c..5af209d4d533b 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngpread.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngpread.c @@ -1,19 +1,22 @@ /* pngpread.c - read a png file in push mode * - * Last changed in libpng 1.2.22 [November 6, 2007] - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * Last changed in libpng 1.2.44 [June 26, 2010] + * Copyright (c) 1998-2010 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) + * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" - #ifdef PNG_PROGRESSIVE_READ_SUPPORTED -/* push model modes */ +/* Push model modes */ #define PNG_READ_SIG_MODE 0 #define PNG_READ_CHUNK_MODE 1 #define PNG_READ_IDAT_MODE 2 @@ -28,7 +31,9 @@ void PNGAPI png_process_data(png_structp png_ptr, png_infop info_ptr, png_bytep buffer, png_size_t buffer_size) { - if(png_ptr == NULL) return; + if (png_ptr == NULL || info_ptr == NULL) + return; + png_push_restore_buffer(png_ptr, buffer, buffer_size); while (png_ptr->buffer_size) @@ -43,7 +48,9 @@ png_process_data(png_structp png_ptr, png_infop info_ptr, void /* PRIVATE */ png_process_some_data(png_structp png_ptr, png_infop info_ptr) { - if(png_ptr == NULL) return; + if (png_ptr == NULL) + return; + switch (png_ptr->process_mode) { case PNG_READ_SIG_MODE: @@ -51,42 +58,25 @@ png_process_some_data(png_structp png_ptr, png_infop info_ptr) png_push_read_sig(png_ptr, info_ptr); break; } + case PNG_READ_CHUNK_MODE: { png_push_read_chunk(png_ptr, info_ptr); break; } + case PNG_READ_IDAT_MODE: { png_push_read_IDAT(png_ptr); break; } -#if defined(PNG_READ_tEXt_SUPPORTED) - case PNG_READ_tEXt_MODE: - { - png_push_read_tEXt(png_ptr, info_ptr); - break; - } -#endif -#if defined(PNG_READ_zTXt_SUPPORTED) - case PNG_READ_zTXt_MODE: - { - png_push_read_zTXt(png_ptr, info_ptr); - break; - } -#endif -#if defined(PNG_READ_iTXt_SUPPORTED) - case PNG_READ_iTXt_MODE: - { - png_push_read_iTXt(png_ptr, info_ptr); - break; - } -#endif + case PNG_SKIP_MODE: { png_push_crc_finish(png_ptr); break; } + default: { png_ptr->buffer_size = 0; @@ -114,7 +104,7 @@ png_push_read_sig(png_structp png_ptr, png_infop info_ptr) png_push_fill_buffer(png_ptr, &(info_ptr->signature[num_checked]), num_to_check); - png_ptr->sig_bytes = (png_byte)(png_ptr->sig_bytes+num_to_check); + png_ptr->sig_bytes = (png_byte)(png_ptr->sig_bytes + num_to_check); if (png_sig_cmp(info_ptr->signature, num_checked, num_to_check)) { @@ -141,58 +131,59 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) PNG_CONST PNG_IDAT; PNG_CONST PNG_IEND; PNG_CONST PNG_PLTE; -#if defined(PNG_READ_bKGD_SUPPORTED) +#ifdef PNG_READ_bKGD_SUPPORTED PNG_CONST PNG_bKGD; #endif -#if defined(PNG_READ_cHRM_SUPPORTED) +#ifdef PNG_READ_cHRM_SUPPORTED PNG_CONST PNG_cHRM; #endif -#if defined(PNG_READ_gAMA_SUPPORTED) +#ifdef PNG_READ_gAMA_SUPPORTED PNG_CONST PNG_gAMA; #endif -#if defined(PNG_READ_hIST_SUPPORTED) +#ifdef PNG_READ_hIST_SUPPORTED PNG_CONST PNG_hIST; #endif -#if defined(PNG_READ_iCCP_SUPPORTED) +#ifdef PNG_READ_iCCP_SUPPORTED PNG_CONST PNG_iCCP; #endif -#if defined(PNG_READ_iTXt_SUPPORTED) +#ifdef PNG_READ_iTXt_SUPPORTED PNG_CONST PNG_iTXt; #endif -#if defined(PNG_READ_oFFs_SUPPORTED) +#ifdef PNG_READ_oFFs_SUPPORTED PNG_CONST PNG_oFFs; #endif -#if defined(PNG_READ_pCAL_SUPPORTED) +#ifdef PNG_READ_pCAL_SUPPORTED PNG_CONST PNG_pCAL; #endif -#if defined(PNG_READ_pHYs_SUPPORTED) +#ifdef PNG_READ_pHYs_SUPPORTED PNG_CONST PNG_pHYs; #endif -#if defined(PNG_READ_sBIT_SUPPORTED) +#ifdef PNG_READ_sBIT_SUPPORTED PNG_CONST PNG_sBIT; #endif -#if defined(PNG_READ_sCAL_SUPPORTED) +#ifdef PNG_READ_sCAL_SUPPORTED PNG_CONST PNG_sCAL; #endif -#if defined(PNG_READ_sRGB_SUPPORTED) +#ifdef PNG_READ_sRGB_SUPPORTED PNG_CONST PNG_sRGB; #endif -#if defined(PNG_READ_sPLT_SUPPORTED) +#ifdef PNG_READ_sPLT_SUPPORTED PNG_CONST PNG_sPLT; #endif -#if defined(PNG_READ_tEXt_SUPPORTED) +#ifdef PNG_READ_tEXt_SUPPORTED PNG_CONST PNG_tEXt; #endif -#if defined(PNG_READ_tIME_SUPPORTED) +#ifdef PNG_READ_tIME_SUPPORTED PNG_CONST PNG_tIME; #endif -#if defined(PNG_READ_tRNS_SUPPORTED) +#ifdef PNG_READ_tRNS_SUPPORTED PNG_CONST PNG_tRNS; #endif -#if defined(PNG_READ_zTXt_SUPPORTED) +#ifdef PNG_READ_zTXt_SUPPORTED PNG_CONST PNG_zTXt; #endif #endif /* PNG_USE_LOCAL_ARRAYS */ + /* First we make sure we have enough data for the 4 byte chunk name * and the 4 byte chunk length before proceeding with decoding the * chunk data. To fully decode each of these chunks, we also make @@ -210,25 +201,31 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) } png_push_fill_buffer(png_ptr, chunk_length, 4); - png_ptr->push_length = png_get_uint_31(png_ptr,chunk_length); + png_ptr->push_length = png_get_uint_31(png_ptr, chunk_length); png_reset_crc(png_ptr); png_crc_read(png_ptr, png_ptr->chunk_name, 4); + png_check_chunk_name(png_ptr, png_ptr->chunk_name); png_ptr->mode |= PNG_HAVE_CHUNK_HEADER; } if (!png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) - if(png_ptr->mode & PNG_AFTER_IDAT) + if (png_ptr->mode & PNG_AFTER_IDAT) png_ptr->mode |= PNG_HAVE_CHUNK_AFTER_IDAT; if (!png_memcmp(png_ptr->chunk_name, png_IHDR, 4)) { + if (png_ptr->push_length != 13) + png_error(png_ptr, "Invalid IHDR length"); + if (png_ptr->push_length + 4 > png_ptr->buffer_size) { png_push_save_buffer(png_ptr); return; } + png_handle_IHDR(png_ptr, info_ptr, png_ptr->push_length); } + else if (!png_memcmp(png_ptr->chunk_name, png_IEND, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -236,11 +233,13 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_IEND(png_ptr, info_ptr, png_ptr->push_length); png_ptr->process_mode = PNG_READ_DONE_MODE; png_push_have_end(png_ptr, info_ptr); } + #ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED else if (png_handle_as_unknown(png_ptr, png_ptr->chunk_name)) { @@ -249,20 +248,26 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + if (!png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) png_ptr->mode |= PNG_HAVE_IDAT; + png_handle_unknown(png_ptr, info_ptr, png_ptr->push_length); + if (!png_memcmp(png_ptr->chunk_name, png_PLTE, 4)) png_ptr->mode |= PNG_HAVE_PLTE; + else if (!png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) { if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before IDAT"); + else if (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE && !(png_ptr->mode & PNG_HAVE_PLTE)) png_error(png_ptr, "Missing PLTE before IDAT"); } } + #endif else if (!png_memcmp(png_ptr->chunk_name, png_PLTE, 4)) { @@ -273,23 +278,26 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) } png_handle_PLTE(png_ptr, info_ptr, png_ptr->push_length); } + else if (!png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) { /* If we reach an IDAT chunk, this means we have read all of the * header chunks, and we can start reading the image (or if this * is called after the image has been read - we have an error). */ - if (!(png_ptr->mode & PNG_HAVE_IHDR)) - png_error(png_ptr, "Missing IHDR before IDAT"); - else if (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE && - !(png_ptr->mode & PNG_HAVE_PLTE)) - png_error(png_ptr, "Missing PLTE before IDAT"); + + if (!(png_ptr->mode & PNG_HAVE_IHDR)) + png_error(png_ptr, "Missing IHDR before IDAT"); + + else if (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE && + !(png_ptr->mode & PNG_HAVE_PLTE)) + png_error(png_ptr, "Missing PLTE before IDAT"); if (png_ptr->mode & PNG_HAVE_IDAT) { if (!(png_ptr->mode & PNG_HAVE_CHUNK_AFTER_IDAT)) - if (png_ptr->push_length == 0) - return; + if (png_ptr->push_length == 0) + return; if (png_ptr->mode & PNG_AFTER_IDAT) png_error(png_ptr, "Too many IDAT's found"); @@ -299,11 +307,14 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_ptr->mode |= PNG_HAVE_IDAT; png_ptr->process_mode = PNG_READ_IDAT_MODE; png_push_have_info(png_ptr, info_ptr); - png_ptr->zstream.avail_out = (uInt)png_ptr->irowbytes; + png_ptr->zstream.avail_out = + (uInt) PNG_ROWBYTES(png_ptr->pixel_depth, + png_ptr->iwidth) + 1; png_ptr->zstream.next_out = png_ptr->row_buf; return; } -#if defined(PNG_READ_gAMA_SUPPORTED) + +#ifdef PNG_READ_gAMA_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_gAMA, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -311,10 +322,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_gAMA(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_sBIT_SUPPORTED) +#ifdef PNG_READ_sBIT_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_sBIT, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -322,10 +335,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_sBIT(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_cHRM_SUPPORTED) +#ifdef PNG_READ_cHRM_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_cHRM, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -333,10 +348,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_cHRM(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_sRGB_SUPPORTED) +#ifdef PNG_READ_sRGB_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_sRGB, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -344,10 +361,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_sRGB(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_iCCP_SUPPORTED) +#ifdef PNG_READ_iCCP_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_iCCP, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -355,10 +374,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_iCCP(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_sPLT_SUPPORTED) +#ifdef PNG_READ_sPLT_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_sPLT, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -366,10 +387,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_sPLT(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_tRNS_SUPPORTED) +#ifdef PNG_READ_tRNS_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_tRNS, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -377,10 +400,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_tRNS(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_bKGD_SUPPORTED) +#ifdef PNG_READ_bKGD_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_bKGD, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -388,10 +413,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_bKGD(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_hIST_SUPPORTED) +#ifdef PNG_READ_hIST_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_hIST, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -399,10 +426,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_hIST(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_pHYs_SUPPORTED) +#ifdef PNG_READ_pHYs_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_pHYs, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -410,10 +439,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_pHYs(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_oFFs_SUPPORTED) +#ifdef PNG_READ_oFFs_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_oFFs, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -421,10 +452,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_oFFs(png_ptr, info_ptr, png_ptr->push_length); } #endif -#if defined(PNG_READ_pCAL_SUPPORTED) + +#ifdef PNG_READ_pCAL_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_pCAL, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -432,10 +465,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_pCAL(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_sCAL_SUPPORTED) +#ifdef PNG_READ_sCAL_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_sCAL, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -443,10 +478,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_sCAL(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_tIME_SUPPORTED) +#ifdef PNG_READ_tIME_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_tIME, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -454,10 +491,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } + png_handle_tIME(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_tEXt_SUPPORTED) +#ifdef PNG_READ_tEXt_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_tEXt, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -465,10 +504,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } - png_push_handle_tEXt(png_ptr, info_ptr, png_ptr->push_length); + + png_handle_tEXt(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_zTXt_SUPPORTED) +#ifdef PNG_READ_zTXt_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_zTXt, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -476,10 +517,12 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } - png_push_handle_zTXt(png_ptr, info_ptr, png_ptr->push_length); + + png_handle_zTXt(png_ptr, info_ptr, png_ptr->push_length); } + #endif -#if defined(PNG_READ_iTXt_SUPPORTED) +#ifdef PNG_READ_iTXt_SUPPORTED else if (!png_memcmp(png_ptr->chunk_name, png_iTXt, 4)) { if (png_ptr->push_length + 4 > png_ptr->buffer_size) @@ -487,8 +530,10 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } - png_push_handle_iTXt(png_ptr, info_ptr, png_ptr->push_length); + + png_handle_iTXt(png_ptr, info_ptr, png_ptr->push_length); } + #endif else { @@ -497,7 +542,7 @@ png_push_read_chunk(png_structp png_ptr, png_infop info_ptr) png_push_save_buffer(png_ptr); return; } - png_push_handle_unknown(png_ptr, info_ptr, png_ptr->push_length); + png_handle_unknown(png_ptr, info_ptr, png_ptr->push_length); } png_ptr->mode &= ~PNG_HAVE_CHUNK_HEADER; @@ -563,7 +608,9 @@ png_push_fill_buffer(png_structp png_ptr, png_bytep buffer, png_size_t length) { png_bytep ptr; - if(png_ptr == NULL) return; + if (png_ptr == NULL) + return; + ptr = buffer; if (png_ptr->save_buffer_size) { @@ -587,6 +634,7 @@ png_push_fill_buffer(png_structp png_ptr, png_bytep buffer, png_size_t length) if (length < png_ptr->current_buffer_size) save_size = length; + else save_size = png_ptr->current_buffer_size; @@ -604,7 +652,7 @@ png_push_save_buffer(png_structp png_ptr) { if (png_ptr->save_buffer_ptr != png_ptr->save_buffer) { - png_size_t i,istop; + png_size_t i, istop; png_bytep sp; png_bytep dp; @@ -627,10 +675,16 @@ png_push_save_buffer(png_structp png_ptr) { png_error(png_ptr, "Potential overflow of save_buffer"); } + new_max = png_ptr->save_buffer_size + png_ptr->current_buffer_size + 256; old_buffer = png_ptr->save_buffer; - png_ptr->save_buffer = (png_bytep)png_malloc(png_ptr, + png_ptr->save_buffer = (png_bytep)png_malloc_warn(png_ptr, (png_uint_32)new_max); + if (png_ptr->save_buffer == NULL) + { + png_free(png_ptr, old_buffer); + png_error(png_ptr, "Insufficient memory for save_buffer"); + } png_memcpy(png_ptr->save_buffer, old_buffer, png_ptr->save_buffer_size); png_free(png_ptr, old_buffer); png_ptr->save_buffer_max = new_max; @@ -673,7 +727,7 @@ png_push_read_IDAT(png_structp png_ptr) } png_push_fill_buffer(png_ptr, chunk_length, 4); - png_ptr->push_length = png_get_uint_31(png_ptr,chunk_length); + png_ptr->push_length = png_get_uint_31(png_ptr, chunk_length); png_reset_crc(png_ptr); png_crc_read(png_ptr, png_ptr->chunk_name, 4); png_ptr->mode |= PNG_HAVE_CHUNK_HEADER; @@ -695,16 +749,18 @@ png_push_read_IDAT(png_structp png_ptr) if (png_ptr->idat_size < (png_uint_32)png_ptr->save_buffer_size) { save_size = (png_size_t)png_ptr->idat_size; - /* check for overflow */ - if((png_uint_32)save_size != png_ptr->idat_size) + + /* Check for overflow */ + if ((png_uint_32)save_size != png_ptr->idat_size) png_error(png_ptr, "save_size overflowed in pngpread"); } else save_size = png_ptr->save_buffer_size; png_calculate_crc(png_ptr, png_ptr->save_buffer_ptr, save_size); - if (!(png_ptr->flags & PNG_FLAG_ZLIB_FINISHED)) - png_process_IDAT_data(png_ptr, png_ptr->save_buffer_ptr, save_size); + + png_process_IDAT_data(png_ptr, png_ptr->save_buffer_ptr, save_size); + png_ptr->idat_size -= save_size; png_ptr->buffer_size -= save_size; png_ptr->save_buffer_size -= save_size; @@ -717,16 +773,17 @@ png_push_read_IDAT(png_structp png_ptr) if (png_ptr->idat_size < (png_uint_32)png_ptr->current_buffer_size) { save_size = (png_size_t)png_ptr->idat_size; - /* check for overflow */ - if((png_uint_32)save_size != png_ptr->idat_size) + + /* Check for overflow */ + if ((png_uint_32)save_size != png_ptr->idat_size) png_error(png_ptr, "save_size overflowed in pngpread"); } else save_size = png_ptr->current_buffer_size; png_calculate_crc(png_ptr, png_ptr->current_buffer_ptr, save_size); - if (!(png_ptr->flags & PNG_FLAG_ZLIB_FINISHED)) - png_process_IDAT_data(png_ptr, png_ptr->current_buffer_ptr, save_size); + + png_process_IDAT_data(png_ptr, png_ptr->current_buffer_ptr, save_size); png_ptr->idat_size -= save_size; png_ptr->buffer_size -= save_size; @@ -751,57 +808,101 @@ void /* PRIVATE */ png_process_IDAT_data(png_structp png_ptr, png_bytep buffer, png_size_t buffer_length) { - int ret; - - if ((png_ptr->flags & PNG_FLAG_ZLIB_FINISHED) && buffer_length) - png_error(png_ptr, "Extra compression data"); + /* The caller checks for a non-zero buffer length. */ + if (!(buffer_length > 0) || buffer == NULL) + png_error(png_ptr, "No IDAT data (internal error)"); + /* This routine must process all the data it has been given + * before returning, calling the row callback as required to + * handle the uncompressed results. + */ png_ptr->zstream.next_in = buffer; png_ptr->zstream.avail_in = (uInt)buffer_length; - for(;;) + + /* Keep going until the decompressed data is all processed + * or the stream marked as finished. + */ + while (png_ptr->zstream.avail_in > 0 && + !(png_ptr->flags & PNG_FLAG_ZLIB_FINISHED)) { - ret = inflate(&png_ptr->zstream, Z_PARTIAL_FLUSH); - if (ret != Z_OK) + int ret; + + /* We have data for zlib, but we must check that zlib + * has somewhere to put the results. It doesn't matter + * if we don't expect any results -- it may be the input + * data is just the LZ end code. + */ + if (!(png_ptr->zstream.avail_out > 0)) { - if (ret == Z_STREAM_END) - { - if (png_ptr->zstream.avail_in) - png_error(png_ptr, "Extra compressed data"); - if (!(png_ptr->zstream.avail_out)) - { - png_push_process_row(png_ptr); - } + png_ptr->zstream.avail_out = + (uInt) PNG_ROWBYTES(png_ptr->pixel_depth, + png_ptr->iwidth) + 1; + png_ptr->zstream.next_out = png_ptr->row_buf; + } - png_ptr->mode |= PNG_AFTER_IDAT; - png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED; - break; - } - else if (ret == Z_BUF_ERROR) - break; - else - png_error(png_ptr, "Decompression Error"); + /* Using Z_SYNC_FLUSH here means that an unterminated + * LZ stream can still be handled (a stream with a missing + * end code), otherwise (Z_NO_FLUSH) a future zlib + * implementation might defer output and, therefore, + * change the current behavior. (See comments in inflate.c + * for why this doesn't happen at present with zlib 1.2.5.) + */ + ret = inflate(&png_ptr->zstream, Z_SYNC_FLUSH); + + /* Check for any failure before proceeding. */ + if (ret != Z_OK && ret != Z_STREAM_END) + { + /* Terminate the decompression. */ + png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED; + + /* This may be a truncated stream (missing or + * damaged end code). Treat that as a warning. + */ + if (png_ptr->row_number >= png_ptr->num_rows || + png_ptr->pass > 6) + png_warning(png_ptr, "Truncated compressed data in IDAT"); + else + png_error(png_ptr, "Decompression error in IDAT"); + + /* Skip the check on unprocessed input */ + return; } - if (!(png_ptr->zstream.avail_out)) + + /* Did inflate output any data? */ + if (png_ptr->zstream.next_out != png_ptr->row_buf) { - if (( -#if defined(PNG_READ_INTERLACING_SUPPORTED) - png_ptr->interlaced && png_ptr->pass > 6) || - (!png_ptr->interlaced && -#endif - png_ptr->row_number == png_ptr->num_rows)) + /* Is this unexpected data after the last row? + * If it is, artificially terminate the LZ output + * here. + */ + if (png_ptr->row_number >= png_ptr->num_rows || + png_ptr->pass > 6) { - if (png_ptr->zstream.avail_in) - png_warning(png_ptr, "Too much data in IDAT chunks"); - png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED; - break; - } - png_push_process_row(png_ptr); - png_ptr->zstream.avail_out = (uInt)png_ptr->irowbytes; - png_ptr->zstream.next_out = png_ptr->row_buf; + /* Extra data. */ + png_warning(png_ptr, "Extra compressed data in IDAT"); + png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED; + /* Do no more processing; skip the unprocessed + * input check below. + */ + return; + } + + /* Do we have a complete row? */ + if (png_ptr->zstream.avail_out == 0) + png_push_process_row(png_ptr); } - else - break; + + /* And check for the end of the stream. */ + if (ret == Z_STREAM_END) + png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED; } + + /* All the data should have been processed, if anything + * is left at this point we have bytes of IDAT data + * after the zlib end code. + */ + if (png_ptr->zstream.avail_in > 0) + png_warning(png_ptr, "Extra compression data"); } void /* PRIVATE */ @@ -817,8 +918,8 @@ png_push_process_row(png_structp png_ptr) png_ptr->row_info.width); png_read_filter_row(png_ptr, &(png_ptr->row_info), - png_ptr->row_buf + 1, png_ptr->prev_row + 1, - (int)(png_ptr->row_buf[0])); + png_ptr->row_buf + 1, png_ptr->prev_row + 1, + (int)(png_ptr->row_buf[0])); png_memcpy_check(png_ptr, png_ptr->prev_row, png_ptr->row_buf, png_ptr->rowbytes + 1); @@ -826,14 +927,14 @@ png_push_process_row(png_structp png_ptr) if (png_ptr->transformations || (png_ptr->flags&PNG_FLAG_STRIP_ALPHA)) png_do_read_transformations(png_ptr); -#if defined(PNG_READ_INTERLACING_SUPPORTED) - /* blow up interlaced rows to full size */ +#ifdef PNG_READ_INTERLACING_SUPPORTED + /* Blow up interlaced rows to full size */ if (png_ptr->interlaced && (png_ptr->transformations & PNG_INTERLACE)) { if (png_ptr->pass < 6) /* old interface (pre-1.0.9): png_do_read_interlace(&(png_ptr->row_info), - png_ptr->row_buf + 1, png_ptr->pass, png_ptr->transformations); + png_ptr->row_buf + 1, png_ptr->pass, png_ptr->transformations); */ png_do_read_interlace(png_ptr); @@ -845,9 +946,10 @@ png_push_process_row(png_structp png_ptr) for (i = 0; i < 8 && png_ptr->pass == 0; i++) { png_push_have_row(png_ptr, png_ptr->row_buf + 1); - png_read_push_finish_row(png_ptr); /* updates png_ptr->pass */ + png_read_push_finish_row(png_ptr); /* Updates png_ptr->pass */ } - if (png_ptr->pass == 2) /* pass 1 might be empty */ + + if (png_ptr->pass == 2) /* Pass 1 might be empty */ { for (i = 0; i < 4 && png_ptr->pass == 2; i++) { @@ -855,6 +957,7 @@ png_push_process_row(png_structp png_ptr) png_read_push_finish_row(png_ptr); } } + if (png_ptr->pass == 4 && png_ptr->height <= 4) { for (i = 0; i < 2 && png_ptr->pass == 4; i++) @@ -863,13 +966,16 @@ png_push_process_row(png_structp png_ptr) png_read_push_finish_row(png_ptr); } } + if (png_ptr->pass == 6 && png_ptr->height <= 4) { - png_push_have_row(png_ptr, png_bytep_NULL); + png_push_have_row(png_ptr, png_bytep_NULL); png_read_push_finish_row(png_ptr); } + break; } + case 1: { int i; @@ -878,7 +984,8 @@ png_push_process_row(png_structp png_ptr) png_push_have_row(png_ptr, png_ptr->row_buf + 1); png_read_push_finish_row(png_ptr); } - if (png_ptr->pass == 2) /* skip top 4 generated rows */ + + if (png_ptr->pass == 2) /* Skip top 4 generated rows */ { for (i = 0; i < 4 && png_ptr->pass == 2; i++) { @@ -886,22 +993,27 @@ png_push_process_row(png_structp png_ptr) png_read_push_finish_row(png_ptr); } } + break; } + case 2: { int i; + for (i = 0; i < 4 && png_ptr->pass == 2; i++) { png_push_have_row(png_ptr, png_ptr->row_buf + 1); png_read_push_finish_row(png_ptr); } + for (i = 0; i < 4 && png_ptr->pass == 2; i++) { - png_push_have_row(png_ptr, png_bytep_NULL); + png_push_have_row(png_ptr, png_bytep_NULL); png_read_push_finish_row(png_ptr); } - if (png_ptr->pass == 4) /* pass 3 might be empty */ + + if (png_ptr->pass == 4) /* Pass 3 might be empty */ { for (i = 0; i < 2 && png_ptr->pass == 4; i++) { @@ -909,17 +1021,21 @@ png_push_process_row(png_structp png_ptr) png_read_push_finish_row(png_ptr); } } + break; } + case 3: { int i; + for (i = 0; i < 4 && png_ptr->pass == 3; i++) { png_push_have_row(png_ptr, png_ptr->row_buf + 1); png_read_push_finish_row(png_ptr); } - if (png_ptr->pass == 4) /* skip top two generated rows */ + + if (png_ptr->pass == 4) /* Skip top two generated rows */ { for (i = 0; i < 2 && png_ptr->pass == 4; i++) { @@ -927,50 +1043,62 @@ png_push_process_row(png_structp png_ptr) png_read_push_finish_row(png_ptr); } } + break; } + case 4: { int i; + for (i = 0; i < 2 && png_ptr->pass == 4; i++) { png_push_have_row(png_ptr, png_ptr->row_buf + 1); png_read_push_finish_row(png_ptr); } + for (i = 0; i < 2 && png_ptr->pass == 4; i++) { - png_push_have_row(png_ptr, png_bytep_NULL); + png_push_have_row(png_ptr, png_bytep_NULL); png_read_push_finish_row(png_ptr); } - if (png_ptr->pass == 6) /* pass 5 might be empty */ + + if (png_ptr->pass == 6) /* Pass 5 might be empty */ { - png_push_have_row(png_ptr, png_bytep_NULL); + png_push_have_row(png_ptr, png_bytep_NULL); png_read_push_finish_row(png_ptr); } + break; } + case 5: { int i; + for (i = 0; i < 2 && png_ptr->pass == 5; i++) { png_push_have_row(png_ptr, png_ptr->row_buf + 1); png_read_push_finish_row(png_ptr); } - if (png_ptr->pass == 6) /* skip top generated row */ + + if (png_ptr->pass == 6) /* Skip top generated row */ { - png_push_have_row(png_ptr, png_bytep_NULL); + png_push_have_row(png_ptr, png_bytep_NULL); png_read_push_finish_row(png_ptr); } + break; } case 6: { png_push_have_row(png_ptr, png_ptr->row_buf + 1); png_read_push_finish_row(png_ptr); + if (png_ptr->pass != 6) break; - png_push_have_row(png_ptr, png_bytep_NULL); + + png_push_have_row(png_ptr, png_bytep_NULL); png_read_push_finish_row(png_ptr); } } @@ -987,18 +1115,18 @@ void /* PRIVATE */ png_read_push_finish_row(png_structp png_ptr) { #ifdef PNG_USE_LOCAL_ARRAYS - /* arrays to facilitate easy interlacing - use pass (0 - 6) as index */ + /* Arrays to facilitate easy interlacing - use pass (0 - 6) as index */ - /* start of interlace block */ + /* Start of interlace block */ PNG_CONST int FARDATA png_pass_start[] = {0, 4, 0, 2, 0, 1, 0}; - /* offset to next interlace block */ + /* Offset to next interlace block */ PNG_CONST int FARDATA png_pass_inc[] = {8, 8, 4, 4, 2, 2, 1}; - /* start of interlace block in the y direction */ + /* Start of interlace block in the y direction */ PNG_CONST int FARDATA png_pass_ystart[] = {0, 0, 4, 0, 2, 0, 1}; - /* offset to next interlace block in the y direction */ + /* Offset to next interlace block in the y direction */ PNG_CONST int FARDATA png_pass_yinc[] = {8, 8, 8, 4, 4, 2, 2}; /* Height of interlace block. This is not currently used - if you need @@ -1011,6 +1139,7 @@ png_read_push_finish_row(png_structp png_ptr) if (png_ptr->row_number < png_ptr->num_rows) return; +#ifdef PNG_READ_INTERLACING_SUPPORTED if (png_ptr->interlaced) { png_ptr->row_number = 0; @@ -1026,6 +1155,7 @@ png_read_push_finish_row(png_structp png_ptr) if (png_ptr->pass > 7) png_ptr->pass--; + if (png_ptr->pass >= 7) break; @@ -1034,9 +1164,6 @@ png_read_push_finish_row(png_structp png_ptr) png_pass_start[png_ptr->pass]) / png_pass_inc[png_ptr->pass]; - png_ptr->irowbytes = PNG_ROWBYTES(png_ptr->pixel_depth, - png_ptr->iwidth) + 1; - if (png_ptr->transformations & PNG_INTERLACE) break; @@ -1047,486 +1174,7 @@ png_read_push_finish_row(png_structp png_ptr) } while (png_ptr->iwidth == 0 || png_ptr->num_rows == 0); } -} - -#if defined(PNG_READ_tEXt_SUPPORTED) -void /* PRIVATE */ -png_push_handle_tEXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 - length) -{ - if (!(png_ptr->mode & PNG_HAVE_IHDR) || (png_ptr->mode & PNG_HAVE_IEND)) - { - png_error(png_ptr, "Out of place tEXt"); - info_ptr = info_ptr; /* to quiet some compiler warnings */ - } - -#ifdef PNG_MAX_MALLOC_64K - png_ptr->skip_length = 0; /* This may not be necessary */ - - if (length > (png_uint_32)65535L) /* Can't hold entire string in memory */ - { - png_warning(png_ptr, "tEXt chunk too large to fit in memory"); - png_ptr->skip_length = length - (png_uint_32)65535L; - length = (png_uint_32)65535L; - } -#endif - - png_ptr->current_text = (png_charp)png_malloc(png_ptr, - (png_uint_32)(length+1)); - png_ptr->current_text[length] = '\0'; - png_ptr->current_text_ptr = png_ptr->current_text; - png_ptr->current_text_size = (png_size_t)length; - png_ptr->current_text_left = (png_size_t)length; - png_ptr->process_mode = PNG_READ_tEXt_MODE; -} - -void /* PRIVATE */ -png_push_read_tEXt(png_structp png_ptr, png_infop info_ptr) -{ - if (png_ptr->buffer_size && png_ptr->current_text_left) - { - png_size_t text_size; - - if (png_ptr->buffer_size < png_ptr->current_text_left) - text_size = png_ptr->buffer_size; - else - text_size = png_ptr->current_text_left; - png_crc_read(png_ptr, (png_bytep)png_ptr->current_text_ptr, text_size); - png_ptr->current_text_left -= text_size; - png_ptr->current_text_ptr += text_size; - } - if (!(png_ptr->current_text_left)) - { - png_textp text_ptr; - png_charp text; - png_charp key; - int ret; - - if (png_ptr->buffer_size < 4) - { - png_push_save_buffer(png_ptr); - return; - } - - png_push_crc_finish(png_ptr); - -#if defined(PNG_MAX_MALLOC_64K) - if (png_ptr->skip_length) - return; -#endif - - key = png_ptr->current_text; - - for (text = key; *text; text++) - /* empty loop */ ; - - if (text < key + png_ptr->current_text_size) - text++; - - text_ptr = (png_textp)png_malloc(png_ptr, - (png_uint_32)png_sizeof(png_text)); - text_ptr->compression = PNG_TEXT_COMPRESSION_NONE; - text_ptr->key = key; -#ifdef PNG_iTXt_SUPPORTED - text_ptr->lang = NULL; - text_ptr->lang_key = NULL; -#endif - text_ptr->text = text; - - ret = png_set_text_2(png_ptr, info_ptr, text_ptr, 1); - - png_free(png_ptr, key); - png_free(png_ptr, text_ptr); - png_ptr->current_text = NULL; - - if (ret) - png_warning(png_ptr, "Insufficient memory to store text chunk."); - } -} -#endif - -#if defined(PNG_READ_zTXt_SUPPORTED) -void /* PRIVATE */ -png_push_handle_zTXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 - length) -{ - if (!(png_ptr->mode & PNG_HAVE_IHDR) || (png_ptr->mode & PNG_HAVE_IEND)) - { - png_error(png_ptr, "Out of place zTXt"); - info_ptr = info_ptr; /* to quiet some compiler warnings */ - } - -#ifdef PNG_MAX_MALLOC_64K - /* We can't handle zTXt chunks > 64K, since we don't have enough space - * to be able to store the uncompressed data. Actually, the threshold - * is probably around 32K, but it isn't as definite as 64K is. - */ - if (length > (png_uint_32)65535L) - { - png_warning(png_ptr, "zTXt chunk too large to fit in memory"); - png_push_crc_skip(png_ptr, length); - return; - } -#endif - - png_ptr->current_text = (png_charp)png_malloc(png_ptr, - (png_uint_32)(length+1)); - png_ptr->current_text[length] = '\0'; - png_ptr->current_text_ptr = png_ptr->current_text; - png_ptr->current_text_size = (png_size_t)length; - png_ptr->current_text_left = (png_size_t)length; - png_ptr->process_mode = PNG_READ_zTXt_MODE; -} - -void /* PRIVATE */ -png_push_read_zTXt(png_structp png_ptr, png_infop info_ptr) -{ - if (png_ptr->buffer_size && png_ptr->current_text_left) - { - png_size_t text_size; - - if (png_ptr->buffer_size < (png_uint_32)png_ptr->current_text_left) - text_size = png_ptr->buffer_size; - else - text_size = png_ptr->current_text_left; - png_crc_read(png_ptr, (png_bytep)png_ptr->current_text_ptr, text_size); - png_ptr->current_text_left -= text_size; - png_ptr->current_text_ptr += text_size; - } - if (!(png_ptr->current_text_left)) - { - png_textp text_ptr; - png_charp text; - png_charp key; - int ret; - png_size_t text_size, key_size; - - if (png_ptr->buffer_size < 4) - { - png_push_save_buffer(png_ptr); - return; - } - - png_push_crc_finish(png_ptr); - - key = png_ptr->current_text; - - for (text = key; *text; text++) - /* empty loop */ ; - - /* zTXt can't have zero text */ - if (text >= key + png_ptr->current_text_size) - { - png_ptr->current_text = NULL; - png_free(png_ptr, key); - return; - } - - text++; - - if (*text != PNG_TEXT_COMPRESSION_zTXt) /* check compression byte */ - { - png_ptr->current_text = NULL; - png_free(png_ptr, key); - return; - } - - text++; - - png_ptr->zstream.next_in = (png_bytep )text; - png_ptr->zstream.avail_in = (uInt)(png_ptr->current_text_size - - (text - key)); - png_ptr->zstream.next_out = png_ptr->zbuf; - png_ptr->zstream.avail_out = (uInt)png_ptr->zbuf_size; - - key_size = text - key; - text_size = 0; - text = NULL; - ret = Z_STREAM_END; - - while (png_ptr->zstream.avail_in) - { - ret = inflate(&png_ptr->zstream, Z_PARTIAL_FLUSH); - if (ret != Z_OK && ret != Z_STREAM_END) - { - inflateReset(&png_ptr->zstream); - png_ptr->zstream.avail_in = 0; - png_ptr->current_text = NULL; - png_free(png_ptr, key); - png_free(png_ptr, text); - return; - } - if (!(png_ptr->zstream.avail_out) || ret == Z_STREAM_END) - { - if (text == NULL) - { - text = (png_charp)png_malloc(png_ptr, - (png_uint_32)(png_ptr->zbuf_size - png_ptr->zstream.avail_out - + key_size + 1)); - png_memcpy(text + key_size, png_ptr->zbuf, - png_ptr->zbuf_size - png_ptr->zstream.avail_out); - png_memcpy(text, key, key_size); - text_size = key_size + png_ptr->zbuf_size - - png_ptr->zstream.avail_out; - *(text + text_size) = '\0'; - } - else - { - png_charp tmp; - - tmp = text; - text = (png_charp)png_malloc(png_ptr, text_size + - (png_uint_32)(png_ptr->zbuf_size - png_ptr->zstream.avail_out - + 1)); - png_memcpy(text, tmp, text_size); - png_free(png_ptr, tmp); - png_memcpy(text + text_size, png_ptr->zbuf, - png_ptr->zbuf_size - png_ptr->zstream.avail_out); - text_size += png_ptr->zbuf_size - png_ptr->zstream.avail_out; - *(text + text_size) = '\0'; - } - if (ret != Z_STREAM_END) - { - png_ptr->zstream.next_out = png_ptr->zbuf; - png_ptr->zstream.avail_out = (uInt)png_ptr->zbuf_size; - } - } - else - { - break; - } - - if (ret == Z_STREAM_END) - break; - } - - inflateReset(&png_ptr->zstream); - png_ptr->zstream.avail_in = 0; - - if (ret != Z_STREAM_END) - { - png_ptr->current_text = NULL; - png_free(png_ptr, key); - png_free(png_ptr, text); - return; - } - - png_ptr->current_text = NULL; - png_free(png_ptr, key); - key = text; - text += key_size; - - text_ptr = (png_textp)png_malloc(png_ptr, - (png_uint_32)png_sizeof(png_text)); - text_ptr->compression = PNG_TEXT_COMPRESSION_zTXt; - text_ptr->key = key; -#ifdef PNG_iTXt_SUPPORTED - text_ptr->lang = NULL; - text_ptr->lang_key = NULL; -#endif - text_ptr->text = text; - - ret = png_set_text_2(png_ptr, info_ptr, text_ptr, 1); - - png_free(png_ptr, key); - png_free(png_ptr, text_ptr); - - if (ret) - png_warning(png_ptr, "Insufficient memory to store text chunk."); - } -} -#endif - -#if defined(PNG_READ_iTXt_SUPPORTED) -void /* PRIVATE */ -png_push_handle_iTXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 - length) -{ - if (!(png_ptr->mode & PNG_HAVE_IHDR) || (png_ptr->mode & PNG_HAVE_IEND)) - { - png_error(png_ptr, "Out of place iTXt"); - info_ptr = info_ptr; /* to quiet some compiler warnings */ - } - -#ifdef PNG_MAX_MALLOC_64K - png_ptr->skip_length = 0; /* This may not be necessary */ - - if (length > (png_uint_32)65535L) /* Can't hold entire string in memory */ - { - png_warning(png_ptr, "iTXt chunk too large to fit in memory"); - png_ptr->skip_length = length - (png_uint_32)65535L; - length = (png_uint_32)65535L; - } -#endif - - png_ptr->current_text = (png_charp)png_malloc(png_ptr, - (png_uint_32)(length+1)); - png_ptr->current_text[length] = '\0'; - png_ptr->current_text_ptr = png_ptr->current_text; - png_ptr->current_text_size = (png_size_t)length; - png_ptr->current_text_left = (png_size_t)length; - png_ptr->process_mode = PNG_READ_iTXt_MODE; -} - -void /* PRIVATE */ -png_push_read_iTXt(png_structp png_ptr, png_infop info_ptr) -{ - - if (png_ptr->buffer_size && png_ptr->current_text_left) - { - png_size_t text_size; - - if (png_ptr->buffer_size < png_ptr->current_text_left) - text_size = png_ptr->buffer_size; - else - text_size = png_ptr->current_text_left; - png_crc_read(png_ptr, (png_bytep)png_ptr->current_text_ptr, text_size); - png_ptr->current_text_left -= text_size; - png_ptr->current_text_ptr += text_size; - } - if (!(png_ptr->current_text_left)) - { - png_textp text_ptr; - png_charp key; - int comp_flag; - png_charp lang; - png_charp lang_key; - png_charp text; - int ret; - - if (png_ptr->buffer_size < 4) - { - png_push_save_buffer(png_ptr); - return; - } - - png_push_crc_finish(png_ptr); - -#if defined(PNG_MAX_MALLOC_64K) - if (png_ptr->skip_length) - return; -#endif - - key = png_ptr->current_text; - - for (lang = key; *lang; lang++) - /* empty loop */ ; - - if (lang < key + png_ptr->current_text_size - 3) - lang++; - - comp_flag = *lang++; - lang++; /* skip comp_type, always zero */ - - for (lang_key = lang; *lang_key; lang_key++) - /* empty loop */ ; - lang_key++; /* skip NUL separator */ - - text=lang_key; - if (lang_key < key + png_ptr->current_text_size - 1) - { - for (; *text; text++) - /* empty loop */ ; - } - - if (text < key + png_ptr->current_text_size) - text++; - - text_ptr = (png_textp)png_malloc(png_ptr, - (png_uint_32)png_sizeof(png_text)); - text_ptr->compression = comp_flag + 2; - text_ptr->key = key; - text_ptr->lang = lang; - text_ptr->lang_key = lang_key; - text_ptr->text = text; - text_ptr->text_length = 0; - text_ptr->itxt_length = png_strlen(text); - - ret = png_set_text_2(png_ptr, info_ptr, text_ptr, 1); - - png_ptr->current_text = NULL; - - png_free(png_ptr, text_ptr); - if (ret) - png_warning(png_ptr, "Insufficient memory to store iTXt chunk."); - } -} -#endif - -/* This function is called when we haven't found a handler for this - * chunk. If there isn't a problem with the chunk itself (ie a bad chunk - * name or a critical chunk), the chunk is (currently) silently ignored. - */ -void /* PRIVATE */ -png_push_handle_unknown(png_structp png_ptr, png_infop info_ptr, png_uint_32 - length) -{ - png_uint_32 skip=0; - png_check_chunk_name(png_ptr, png_ptr->chunk_name); - - if (!(png_ptr->chunk_name[0] & 0x20)) - { -#if defined(PNG_READ_UNKNOWN_CHUNKS_SUPPORTED) - if(png_handle_as_unknown(png_ptr, png_ptr->chunk_name) != - PNG_HANDLE_CHUNK_ALWAYS -#if defined(PNG_READ_USER_CHUNKS_SUPPORTED) - && png_ptr->read_user_chunk_fn == NULL -#endif - ) -#endif - png_chunk_error(png_ptr, "unknown critical chunk"); - - info_ptr = info_ptr; /* to quiet some compiler warnings */ - } - -#if defined(PNG_READ_UNKNOWN_CHUNKS_SUPPORTED) - if (png_ptr->flags & PNG_FLAG_KEEP_UNKNOWN_CHUNKS) - { -#ifdef PNG_MAX_MALLOC_64K - if (length > (png_uint_32)65535L) - { - png_warning(png_ptr, "unknown chunk too large to fit in memory"); - skip = length - (png_uint_32)65535L; - length = (png_uint_32)65535L; - } -#endif - png_memcpy((png_charp)png_ptr->unknown_chunk.name, - (png_charp)png_ptr->chunk_name, - png_sizeof(png_ptr->unknown_chunk.name)); - png_ptr->unknown_chunk.name[png_sizeof(png_ptr->unknown_chunk.name)-1]='\0'; - - png_ptr->unknown_chunk.data = (png_bytep)png_malloc(png_ptr, length); - png_ptr->unknown_chunk.size = (png_size_t)length; - png_crc_read(png_ptr, (png_bytep)png_ptr->unknown_chunk.data, length); -#if defined(PNG_READ_USER_CHUNKS_SUPPORTED) - if(png_ptr->read_user_chunk_fn != NULL) - { - /* callback to user unknown chunk handler */ - int ret; - ret = (*(png_ptr->read_user_chunk_fn)) - (png_ptr, &png_ptr->unknown_chunk); - if (ret < 0) - png_chunk_error(png_ptr, "error in user chunk"); - if (ret == 0) - { - if (!(png_ptr->chunk_name[0] & 0x20)) - if(png_handle_as_unknown(png_ptr, png_ptr->chunk_name) != - PNG_HANDLE_CHUNK_ALWAYS) - png_chunk_error(png_ptr, "unknown critical chunk"); - png_set_unknown_chunks(png_ptr, info_ptr, - &png_ptr->unknown_chunk, 1); - } - } -#else - png_set_unknown_chunks(png_ptr, info_ptr, &png_ptr->unknown_chunk, 1); -#endif - png_free(png_ptr, png_ptr->unknown_chunk.data); - png_ptr->unknown_chunk.data = NULL; - } - else -#endif - skip=length; - png_push_crc_skip(png_ptr, skip); +#endif /* PNG_READ_INTERLACING_SUPPORTED */ } void /* PRIVATE */ @@ -1559,7 +1207,10 @@ png_progressive_combine_row (png_structp png_ptr, PNG_CONST int FARDATA png_pass_dsp_mask[7] = {0xff, 0x0f, 0xff, 0x33, 0xff, 0x55, 0xff}; #endif - if(png_ptr == NULL) return; + + if (png_ptr == NULL) + return; + if (new_row != NULL) /* new_row must == png_ptr->row_buf here. */ png_combine_row(png_ptr, old_row, png_pass_dsp_mask[png_ptr->pass]); } @@ -1569,7 +1220,9 @@ png_set_progressive_read_fn(png_structp png_ptr, png_voidp progressive_ptr, png_progressive_info_ptr info_fn, png_progressive_row_ptr row_fn, png_progressive_end_ptr end_fn) { - if(png_ptr == NULL) return; + if (png_ptr == NULL) + return; + png_ptr->info_fn = info_fn; png_ptr->row_fn = row_fn; png_ptr->end_fn = end_fn; @@ -1580,7 +1233,9 @@ png_set_progressive_read_fn(png_structp png_ptr, png_voidp progressive_ptr, png_voidp PNGAPI png_get_progressive_ptr(png_structp png_ptr) { - if(png_ptr == NULL) return (NULL); + if (png_ptr == NULL) + return (NULL); + return png_ptr->io_ptr; } #endif /* PNG_PROGRESSIVE_READ_SUPPORTED */ diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngread.c b/graf2d/asimage/src/libAfterImage/libpng/pngread.c index 02efb0dbbd05e..69ee464b29681 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngread.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngread.c @@ -1,20 +1,23 @@ /* pngread.c - read a PNG file * - * Last changed in libpng 1.2.20 September 7, 2007 - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * Last changed in libpng 1.2.48 [March 8, 2012] + * Copyright (c) 1998-2012 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h + * * This file contains routines that an application calls directly to * read a PNG file or stream. */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" - -#if defined(PNG_READ_SUPPORTED) +#ifdef PNG_READ_SUPPORTED /* Create a PNG structure for reading, and allocate any memory needed. */ png_structp PNGAPI @@ -27,7 +30,9 @@ png_create_read_struct(png_const_charp user_png_ver, png_voidp error_ptr, warn_fn, png_voidp_NULL, png_malloc_ptr_NULL, png_free_ptr_NULL)); } -/* Alternate create PNG structure for reading, and allocate any memory needed. */ +/* Alternate create PNG structure for reading, and allocate any memory + * needed. + */ png_structp PNGAPI png_create_read_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, png_error_ptr error_fn, png_error_ptr warn_fn, png_voidp mem_ptr, @@ -35,6 +40,9 @@ png_create_read_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, { #endif /* PNG_USER_MEM_SUPPORTED */ +#ifdef PNG_SETJMP_SUPPORTED + volatile +#endif png_structp png_ptr; #ifdef PNG_SETJMP_SUPPORTED @@ -45,7 +53,8 @@ png_create_read_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, int i; - png_debug(1, "in png_create_read_struct\n"); + png_debug(1, "in png_create_read_struct"); + #ifdef PNG_USER_MEM_SUPPORTED png_ptr = (png_structp)png_create_struct_2(PNG_STRUCT_PNG, (png_malloc_ptr)malloc_fn, (png_voidp)mem_ptr); @@ -55,10 +64,12 @@ png_create_read_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, if (png_ptr == NULL) return (NULL); - /* added at libpng-1.2.6 */ -#ifdef PNG_SET_USER_LIMITS_SUPPORTED - png_ptr->user_width_max=PNG_USER_WIDTH_MAX; - png_ptr->user_height_max=PNG_USER_HEIGHT_MAX; + /* Added at libpng-1.2.6 */ +#ifdef PNG_USER_LIMITS_SUPPORTED + png_ptr->user_width_max = PNG_USER_WIDTH_MAX; + png_ptr->user_height_max = PNG_USER_HEIGHT_MAX; + /* Added at libpng-1.2.43 and 1.4.0 */ + png_ptr->user_chunk_cache_max = PNG_USER_CHUNK_CACHE_MAX; #endif #ifdef PNG_SETJMP_SUPPORTED @@ -69,7 +80,7 @@ png_create_read_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, #endif { png_free(png_ptr, png_ptr->zbuf); - png_ptr->zbuf=NULL; + png_ptr->zbuf = NULL; #ifdef PNG_USER_MEM_SUPPORTED png_destroy_struct_2((png_voidp)png_ptr, (png_free_ptr)free_fn, (png_voidp)mem_ptr); @@ -79,9 +90,9 @@ png_create_read_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, return (NULL); } #ifdef USE_FAR_KEYWORD - png_memcpy(png_ptr->jmpbuf,jmpbuf,png_sizeof(jmp_buf)); -#endif + png_memcpy(png_ptr->jmpbuf, jmpbuf, png_sizeof(jmp_buf)); #endif +#endif /* PNG_SETJMP_SUPPORTED */ #ifdef PNG_USER_MEM_SUPPORTED png_set_mem_fn(png_ptr, mem_ptr, malloc_fn, free_fn); @@ -89,47 +100,53 @@ png_create_read_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, png_set_error_fn(png_ptr, error_ptr, error_fn, warn_fn); - i=0; - do - { - if(user_png_ver[i] != png_libpng_ver[i]) - png_ptr->flags |= PNG_FLAG_LIBRARY_MISMATCH; - } while (png_libpng_ver[i++]); - - if (png_ptr->flags & PNG_FLAG_LIBRARY_MISMATCH) + if (user_png_ver) { - /* Libpng 0.90 and later are binary incompatible with libpng 0.89, so - * we must recompile any applications that use any older library version. - * For versions after libpng 1.0, we will be compatible, so we need - * only check the first digit. - */ - if (user_png_ver == NULL || user_png_ver[0] != png_libpng_ver[0] || - (user_png_ver[0] == '1' && user_png_ver[2] != png_libpng_ver[2]) || - (user_png_ver[0] == '0' && user_png_ver[2] < '9')) - { -#if !defined(PNG_NO_STDIO) && !defined(_WIN32_WCE) - char msg[80]; - if (user_png_ver) - { - png_snprintf(msg, 80, - "Application was compiled with png.h from libpng-%.20s", - user_png_ver); - png_warning(png_ptr, msg); - } - png_snprintf(msg, 80, + i = 0; + do + { + if (user_png_ver[i] != png_libpng_ver[i]) + png_ptr->flags |= PNG_FLAG_LIBRARY_MISMATCH; + } while (png_libpng_ver[i++]); + } + else + png_ptr->flags |= PNG_FLAG_LIBRARY_MISMATCH; + + + if (png_ptr->flags & PNG_FLAG_LIBRARY_MISMATCH) + { + /* Libpng 0.90 and later are binary incompatible with libpng 0.89, so + * we must recompile any applications that use any older library version. + * For versions after libpng 1.0, we will be compatible, so we need + * only check the first digit. + */ + if (user_png_ver == NULL || user_png_ver[0] != png_libpng_ver[0] || + (user_png_ver[0] == '1' && user_png_ver[2] != png_libpng_ver[2]) || + (user_png_ver[0] == '0' && user_png_ver[2] < '9')) + { +#if defined(PNG_STDIO_SUPPORTED) && !defined(_WIN32_WCE) + char msg[80]; + if (user_png_ver) + { + png_snprintf(msg, 80, + "Application was compiled with png.h from libpng-%.20s", + user_png_ver); + png_warning(png_ptr, msg); + } + png_snprintf(msg, 80, "Application is running with png.c from libpng-%.20s", - png_libpng_ver); - png_warning(png_ptr, msg); + png_libpng_ver); + png_warning(png_ptr, msg); #endif #ifdef PNG_ERROR_NUMBERS_SUPPORTED - png_ptr->flags=0; + png_ptr->flags = 0; #endif - png_error(png_ptr, - "Incompatible libpng version in application and library"); - } + png_error(png_ptr, + "Incompatible libpng version in application and library"); + } } - /* initialize zbuf - compression buffer */ + /* Initialize zbuf - compression buffer */ png_ptr->zbuf_size = PNG_ZBUF_SIZE; png_ptr->zbuf = (png_bytep)png_malloc(png_ptr, (png_uint_32)png_ptr->zbuf_size); @@ -137,14 +154,17 @@ png_create_read_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, png_ptr->zstream.zfree = png_zfree; png_ptr->zstream.opaque = (voidpf)png_ptr; - switch (inflateInit(&png_ptr->zstream)) - { - case Z_OK: /* Do nothing */ break; - case Z_MEM_ERROR: - case Z_STREAM_ERROR: png_error(png_ptr, "zlib memory error"); break; - case Z_VERSION_ERROR: png_error(png_ptr, "zlib version error"); break; - default: png_error(png_ptr, "Unknown zlib error"); - } + switch (inflateInit(&png_ptr->zstream)) + { + case Z_OK: /* Do nothing */ break; + case Z_MEM_ERROR: + case Z_STREAM_ERROR: png_error(png_ptr, "zlib memory error"); + break; + case Z_VERSION_ERROR: png_error(png_ptr, "zlib version error"); + break; + default: png_error(png_ptr, "Unknown zlib error"); + } + png_ptr->zstream.next_out = png_ptr->zbuf; png_ptr->zstream.avail_out = (uInt)png_ptr->zbuf_size; @@ -152,25 +172,27 @@ png_create_read_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, png_set_read_fn(png_ptr, png_voidp_NULL, png_rw_ptr_NULL); #ifdef PNG_SETJMP_SUPPORTED -/* Applications that neglect to set up their own setjmp() and then encounter - a png_error() will longjmp here. Since the jmpbuf is then meaningless we - abort instead of returning. */ +/* Applications that neglect to set up their own setjmp() and then + encounter a png_error() will longjmp here. Since the jmpbuf is + then meaningless we abort instead of returning. */ #ifdef USE_FAR_KEYWORD if (setjmp(jmpbuf)) - PNG_ABORT(); - png_memcpy(png_ptr->jmpbuf,jmpbuf,png_sizeof(jmp_buf)); + PNG_ABORT(); + png_memcpy(png_ptr->jmpbuf, jmpbuf, png_sizeof(jmp_buf)); #else if (setjmp(png_ptr->jmpbuf)) - PNG_ABORT(); -#endif + PNG_ABORT(); #endif +#endif /* PNG_SETJMP_SUPPORTED */ + return (png_ptr); } #if defined(PNG_1_0_X) || defined(PNG_1_2_X) /* Initialize PNG structure for reading, and allocate any memory needed. - This interface is deprecated in favour of the png_create_read_struct(), - and it will disappear as of libpng-1.3.0. */ + * This interface is deprecated in favour of the png_create_read_struct(), + * and it will disappear as of libpng-1.3.0. + */ #undef png_read_init void PNGAPI png_read_init(png_structp png_ptr) @@ -184,13 +206,14 @@ png_read_init_2(png_structp png_ptr, png_const_charp user_png_ver, png_size_t png_struct_size, png_size_t png_info_size) { /* We only come here via pre-1.0.12-compiled applications */ - if(png_ptr == NULL) return; -#if !defined(PNG_NO_STDIO) && !defined(_WIN32_WCE) - if(png_sizeof(png_struct) > png_struct_size || + if (png_ptr == NULL) + return; +#if defined(PNG_STDIO_SUPPORTED) && !defined(_WIN32_WCE) + if (png_sizeof(png_struct) > png_struct_size || png_sizeof(png_info) > png_info_size) { char msg[80]; - png_ptr->warning_fn=NULL; + png_ptr->warning_fn = NULL; if (user_png_ver) { png_snprintf(msg, 80, @@ -204,24 +227,26 @@ png_read_init_2(png_structp png_ptr, png_const_charp user_png_ver, png_warning(png_ptr, msg); } #endif - if(png_sizeof(png_struct) > png_struct_size) - { - png_ptr->error_fn=NULL; + if (png_sizeof(png_struct) > png_struct_size) + { + png_ptr->error_fn = NULL; #ifdef PNG_ERROR_NUMBERS_SUPPORTED - png_ptr->flags=0; -#endif - png_error(png_ptr, - "The png struct allocated by the application for reading is too small."); - } - if(png_sizeof(png_info) > png_info_size) - { - png_ptr->error_fn=NULL; + png_ptr->flags = 0; +#endif + png_error(png_ptr, + "The png struct allocated by the application for reading is" + " too small."); + } + if (png_sizeof(png_info) > png_info_size) + { + png_ptr->error_fn = NULL; #ifdef PNG_ERROR_NUMBERS_SUPPORTED - png_ptr->flags=0; + png_ptr->flags = 0; #endif - png_error(png_ptr, - "The info struct allocated by application for reading is too small."); - } + png_error(png_ptr, + "The info struct allocated by application for reading is" + " too small."); + } png_read_init_3(&png_ptr, user_png_ver, png_struct_size); } #endif /* PNG_1_0_X || PNG_1_2_X */ @@ -234,57 +259,60 @@ png_read_init_3(png_structpp ptr_ptr, png_const_charp user_png_ver, jmp_buf tmp_jmp; /* to save current jump buffer */ #endif - int i=0; + int i = 0; png_structp png_ptr=*ptr_ptr; - if(png_ptr == NULL) return; + if (png_ptr == NULL) + return; do { - if(user_png_ver[i] != png_libpng_ver[i]) - { + if (user_png_ver[i] != png_libpng_ver[i]) + { #ifdef PNG_LEGACY_SUPPORTED - png_ptr->flags |= PNG_FLAG_LIBRARY_MISMATCH; + png_ptr->flags |= PNG_FLAG_LIBRARY_MISMATCH; #else - png_ptr->warning_fn=NULL; - png_warning(png_ptr, - "Application uses deprecated png_read_init() and should be recompiled."); - break; + png_ptr->warning_fn = NULL; + png_warning(png_ptr, + "Application uses deprecated png_read_init() and should be" + " recompiled."); + break; #endif - } + } } while (png_libpng_ver[i++]); - png_debug(1, "in png_read_init_3\n"); + png_debug(1, "in png_read_init_3"); #ifdef PNG_SETJMP_SUPPORTED - /* save jump buffer and error functions */ - png_memcpy(tmp_jmp, png_ptr->jmpbuf, png_sizeof (jmp_buf)); + /* Save jump buffer and error functions */ + png_memcpy(tmp_jmp, png_ptr->jmpbuf, png_sizeof(jmp_buf)); #endif - if(png_sizeof(png_struct) > png_struct_size) - { - png_destroy_struct(png_ptr); - *ptr_ptr = (png_structp)png_create_struct(PNG_STRUCT_PNG); - png_ptr = *ptr_ptr; - } + if (png_sizeof(png_struct) > png_struct_size) + { + png_destroy_struct(png_ptr); + *ptr_ptr = (png_structp)png_create_struct(PNG_STRUCT_PNG); + png_ptr = *ptr_ptr; + } - /* reset all variables to 0 */ - png_memset(png_ptr, 0, png_sizeof (png_struct)); + /* Reset all variables to 0 */ + png_memset(png_ptr, 0, png_sizeof(png_struct)); #ifdef PNG_SETJMP_SUPPORTED - /* restore jump buffer */ - png_memcpy(png_ptr->jmpbuf, tmp_jmp, png_sizeof (jmp_buf)); + /* Restore jump buffer */ + png_memcpy(png_ptr->jmpbuf, tmp_jmp, png_sizeof(jmp_buf)); #endif - /* added at libpng-1.2.6 */ + /* Added at libpng-1.2.6 */ #ifdef PNG_SET_USER_LIMITS_SUPPORTED - png_ptr->user_width_max=PNG_USER_WIDTH_MAX; - png_ptr->user_height_max=PNG_USER_HEIGHT_MAX; + png_ptr->user_width_max = PNG_USER_WIDTH_MAX; + png_ptr->user_height_max = PNG_USER_HEIGHT_MAX; #endif - /* initialize zbuf - compression buffer */ + /* Initialize zbuf - compression buffer */ png_ptr->zbuf_size = PNG_ZBUF_SIZE; + png_ptr->zstream.zalloc = png_zalloc; png_ptr->zbuf = (png_bytep)png_malloc(png_ptr, (png_uint_32)png_ptr->zbuf_size); png_ptr->zstream.zalloc = png_zalloc; @@ -293,11 +321,11 @@ png_read_init_3(png_structpp ptr_ptr, png_const_charp user_png_ver, switch (inflateInit(&png_ptr->zstream)) { - case Z_OK: /* Do nothing */ break; - case Z_MEM_ERROR: - case Z_STREAM_ERROR: png_error(png_ptr, "zlib memory"); break; - case Z_VERSION_ERROR: png_error(png_ptr, "zlib version"); break; - default: png_error(png_ptr, "Unknown zlib error"); + case Z_OK: /* Do nothing */ break; + case Z_STREAM_ERROR: png_error(png_ptr, "zlib memory error"); break; + case Z_VERSION_ERROR: png_error(png_ptr, "zlib version error"); + break; + default: png_error(png_ptr, "Unknown zlib error"); } png_ptr->zstream.next_out = png_ptr->zbuf; @@ -306,7 +334,7 @@ png_read_init_3(png_structpp ptr_ptr, png_const_charp user_png_ver, png_set_read_fn(png_ptr, png_voidp_NULL, png_rw_ptr_NULL); } -#ifndef PNG_NO_SEQUENTIAL_READ_SUPPORTED +#ifdef PNG_SEQUENTIAL_READ_SUPPORTED /* Read the information before the actual image data. This has been * changed in v0.90 to allow reading a file that already has the magic * bytes read from the stream. You can tell libpng how many bytes have @@ -318,8 +346,11 @@ png_read_init_3(png_structpp ptr_ptr, png_const_charp user_png_ver, void PNGAPI png_read_info(png_structp png_ptr, png_infop info_ptr) { - if(png_ptr == NULL) return; - png_debug(1, "in png_read_info\n"); + png_debug(1, "in png_read_info"); + + if (png_ptr == NULL || info_ptr == NULL) + return; + /* If we haven't checked all of the PNG signature bytes, do so now. */ if (png_ptr->sig_bytes < 8) { @@ -341,97 +372,88 @@ png_read_info(png_structp png_ptr, png_infop info_ptr) png_ptr->mode |= PNG_HAVE_PNG_SIGNATURE; } - for(;;) + for (;;) { #ifdef PNG_USE_LOCAL_ARRAYS PNG_CONST PNG_IHDR; PNG_CONST PNG_IDAT; PNG_CONST PNG_IEND; PNG_CONST PNG_PLTE; -#if defined(PNG_READ_bKGD_SUPPORTED) +#ifdef PNG_READ_bKGD_SUPPORTED PNG_CONST PNG_bKGD; #endif -#if defined(PNG_READ_cHRM_SUPPORTED) +#ifdef PNG_READ_cHRM_SUPPORTED PNG_CONST PNG_cHRM; #endif -#if defined(PNG_READ_gAMA_SUPPORTED) +#ifdef PNG_READ_gAMA_SUPPORTED PNG_CONST PNG_gAMA; #endif -#if defined(PNG_READ_hIST_SUPPORTED) +#ifdef PNG_READ_hIST_SUPPORTED PNG_CONST PNG_hIST; #endif -#if defined(PNG_READ_iCCP_SUPPORTED) +#ifdef PNG_READ_iCCP_SUPPORTED PNG_CONST PNG_iCCP; #endif -#if defined(PNG_READ_iTXt_SUPPORTED) +#ifdef PNG_READ_iTXt_SUPPORTED PNG_CONST PNG_iTXt; #endif -#if defined(PNG_READ_oFFs_SUPPORTED) +#ifdef PNG_READ_oFFs_SUPPORTED PNG_CONST PNG_oFFs; #endif -#if defined(PNG_READ_pCAL_SUPPORTED) +#ifdef PNG_READ_pCAL_SUPPORTED PNG_CONST PNG_pCAL; #endif -#if defined(PNG_READ_pHYs_SUPPORTED) +#ifdef PNG_READ_pHYs_SUPPORTED PNG_CONST PNG_pHYs; #endif -#if defined(PNG_READ_sBIT_SUPPORTED) +#ifdef PNG_READ_sBIT_SUPPORTED PNG_CONST PNG_sBIT; #endif -#if defined(PNG_READ_sCAL_SUPPORTED) +#ifdef PNG_READ_sCAL_SUPPORTED PNG_CONST PNG_sCAL; #endif -#if defined(PNG_READ_sPLT_SUPPORTED) +#ifdef PNG_READ_sPLT_SUPPORTED PNG_CONST PNG_sPLT; #endif -#if defined(PNG_READ_sRGB_SUPPORTED) +#ifdef PNG_READ_sRGB_SUPPORTED PNG_CONST PNG_sRGB; #endif -#if defined(PNG_READ_tEXt_SUPPORTED) +#ifdef PNG_READ_tEXt_SUPPORTED PNG_CONST PNG_tEXt; #endif -#if defined(PNG_READ_tIME_SUPPORTED) +#ifdef PNG_READ_tIME_SUPPORTED PNG_CONST PNG_tIME; #endif -#if defined(PNG_READ_tRNS_SUPPORTED) +#ifdef PNG_READ_tRNS_SUPPORTED PNG_CONST PNG_tRNS; #endif -#if defined(PNG_READ_zTXt_SUPPORTED) +#ifdef PNG_READ_zTXt_SUPPORTED PNG_CONST PNG_zTXt; #endif #endif /* PNG_USE_LOCAL_ARRAYS */ - png_byte chunk_length[4]; - png_uint_32 length; - - png_read_data(png_ptr, chunk_length, 4); - length = png_get_uint_31(png_ptr,chunk_length); - - png_reset_crc(png_ptr); - png_crc_read(png_ptr, png_ptr->chunk_name, 4); - - png_debug2(0, "Reading %s chunk, length=%lu.\n", png_ptr->chunk_name, - length); + png_uint_32 length = png_read_chunk_header(png_ptr); + PNG_CONST png_bytep chunk_name = png_ptr->chunk_name; /* This should be a binary subdivision search or a hash for * matching the chunk name rather than a linear search. */ - if (!png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) - if(png_ptr->mode & PNG_AFTER_IDAT) + if (!png_memcmp(chunk_name, png_IDAT, 4)) + if (png_ptr->mode & PNG_AFTER_IDAT) png_ptr->mode |= PNG_HAVE_CHUNK_AFTER_IDAT; - if (!png_memcmp(png_ptr->chunk_name, png_IHDR, 4)) + if (!png_memcmp(chunk_name, png_IHDR, 4)) png_handle_IHDR(png_ptr, info_ptr, length); - else if (!png_memcmp(png_ptr->chunk_name, png_IEND, 4)) + else if (!png_memcmp(chunk_name, png_IEND, 4)) png_handle_IEND(png_ptr, info_ptr, length); #ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED - else if (png_handle_as_unknown(png_ptr, png_ptr->chunk_name)) + else if (png_handle_as_unknown(png_ptr, chunk_name)) { - if (!png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) + if (!png_memcmp(chunk_name, png_IDAT, 4)) png_ptr->mode |= PNG_HAVE_IDAT; png_handle_unknown(png_ptr, info_ptr, length); - if (!png_memcmp(png_ptr->chunk_name, png_PLTE, 4)) + if (!png_memcmp(chunk_name, png_PLTE, 4)) png_ptr->mode |= PNG_HAVE_PLTE; - else if (!png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) + else if (!png_memcmp(chunk_name, png_IDAT, 4)) { if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before IDAT"); @@ -442,9 +464,9 @@ png_read_info(png_structp png_ptr, png_infop info_ptr) } } #endif - else if (!png_memcmp(png_ptr->chunk_name, png_PLTE, 4)) + else if (!png_memcmp(chunk_name, png_PLTE, 4)) png_handle_PLTE(png_ptr, info_ptr, length); - else if (!png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) + else if (!png_memcmp(chunk_name, png_IDAT, 4)) { if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before IDAT"); @@ -456,95 +478,98 @@ png_read_info(png_structp png_ptr, png_infop info_ptr) png_ptr->mode |= PNG_HAVE_IDAT; break; } -#if defined(PNG_READ_bKGD_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_bKGD, 4)) +#ifdef PNG_READ_bKGD_SUPPORTED + else if (!png_memcmp(chunk_name, png_bKGD, 4)) png_handle_bKGD(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_cHRM_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_cHRM, 4)) +#ifdef PNG_READ_cHRM_SUPPORTED + else if (!png_memcmp(chunk_name, png_cHRM, 4)) png_handle_cHRM(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_gAMA_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_gAMA, 4)) +#ifdef PNG_READ_gAMA_SUPPORTED + else if (!png_memcmp(chunk_name, png_gAMA, 4)) png_handle_gAMA(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_hIST_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_hIST, 4)) +#ifdef PNG_READ_hIST_SUPPORTED + else if (!png_memcmp(chunk_name, png_hIST, 4)) png_handle_hIST(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_oFFs_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_oFFs, 4)) +#ifdef PNG_READ_oFFs_SUPPORTED + else if (!png_memcmp(chunk_name, png_oFFs, 4)) png_handle_oFFs(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_pCAL_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_pCAL, 4)) +#ifdef PNG_READ_pCAL_SUPPORTED + else if (!png_memcmp(chunk_name, png_pCAL, 4)) png_handle_pCAL(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_sCAL_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_sCAL, 4)) +#ifdef PNG_READ_sCAL_SUPPORTED + else if (!png_memcmp(chunk_name, png_sCAL, 4)) png_handle_sCAL(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_pHYs_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_pHYs, 4)) +#ifdef PNG_READ_pHYs_SUPPORTED + else if (!png_memcmp(chunk_name, png_pHYs, 4)) png_handle_pHYs(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_sBIT_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_sBIT, 4)) +#ifdef PNG_READ_sBIT_SUPPORTED + else if (!png_memcmp(chunk_name, png_sBIT, 4)) png_handle_sBIT(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_sRGB_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_sRGB, 4)) +#ifdef PNG_READ_sRGB_SUPPORTED + else if (!png_memcmp(chunk_name, png_sRGB, 4)) png_handle_sRGB(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_iCCP_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_iCCP, 4)) +#ifdef PNG_READ_iCCP_SUPPORTED + else if (!png_memcmp(chunk_name, png_iCCP, 4)) png_handle_iCCP(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_sPLT_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_sPLT, 4)) +#ifdef PNG_READ_sPLT_SUPPORTED + else if (!png_memcmp(chunk_name, png_sPLT, 4)) png_handle_sPLT(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_tEXt_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_tEXt, 4)) +#ifdef PNG_READ_tEXt_SUPPORTED + else if (!png_memcmp(chunk_name, png_tEXt, 4)) png_handle_tEXt(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_tIME_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_tIME, 4)) +#ifdef PNG_READ_tIME_SUPPORTED + else if (!png_memcmp(chunk_name, png_tIME, 4)) png_handle_tIME(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_tRNS_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_tRNS, 4)) +#ifdef PNG_READ_tRNS_SUPPORTED + else if (!png_memcmp(chunk_name, png_tRNS, 4)) png_handle_tRNS(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_zTXt_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_zTXt, 4)) +#ifdef PNG_READ_zTXt_SUPPORTED + else if (!png_memcmp(chunk_name, png_zTXt, 4)) png_handle_zTXt(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_iTXt_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_iTXt, 4)) +#ifdef PNG_READ_iTXt_SUPPORTED + else if (!png_memcmp(chunk_name, png_iTXt, 4)) png_handle_iTXt(png_ptr, info_ptr, length); #endif else png_handle_unknown(png_ptr, info_ptr, length); } } -#endif /* PNG_NO_SEQUENTIAL_READ_SUPPORTED */ +#endif /* PNG_SEQUENTIAL_READ_SUPPORTED */ -/* optional call to update the users info_ptr structure */ +/* Optional call to update the users info_ptr structure */ void PNGAPI png_read_update_info(png_structp png_ptr, png_infop info_ptr) { - png_debug(1, "in png_read_update_info\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_read_update_info"); + + if (png_ptr == NULL) + return; if (!(png_ptr->flags & PNG_FLAG_ROW_INIT)) png_read_start_row(png_ptr); else png_warning(png_ptr, "Ignoring extra png_read_update_info() call; row buffer not reallocated"); + png_read_transform_info(png_ptr, info_ptr); } -#ifndef PNG_NO_SEQUENTIAL_READ_SUPPORTED +#ifdef PNG_SEQUENTIAL_READ_SUPPORTED /* Initialize palette, background, etc, after transformations * are set, but before any reading takes place. This allows * the user to obtain a gamma-corrected palette, for example. @@ -553,32 +578,36 @@ png_read_update_info(png_structp png_ptr, png_infop info_ptr) void PNGAPI png_start_read_image(png_structp png_ptr) { - png_debug(1, "in png_start_read_image\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_start_read_image"); + + if (png_ptr == NULL) + return; if (!(png_ptr->flags & PNG_FLAG_ROW_INIT)) png_read_start_row(png_ptr); } -#endif /* PNG_NO_SEQUENTIAL_READ_SUPPORTED */ +#endif /* PNG_SEQUENTIAL_READ_SUPPORTED */ -#ifndef PNG_NO_SEQUENTIAL_READ_SUPPORTED +#ifdef PNG_SEQUENTIAL_READ_SUPPORTED void PNGAPI png_read_row(png_structp png_ptr, png_bytep row, png_bytep dsp_row) { -#ifdef PNG_USE_LOCAL_ARRAYS PNG_CONST PNG_IDAT; PNG_CONST int png_pass_dsp_mask[7] = {0xff, 0x0f, 0xff, 0x33, 0xff, 0x55, - 0xff}; + 0xff}; PNG_CONST int png_pass_mask[7] = {0x80, 0x08, 0x88, 0x22, 0xaa, 0x55, 0xff}; -#endif int ret; - if(png_ptr == NULL) return; - png_debug2(1, "in png_read_row (row %lu, pass %d)\n", + + if (png_ptr == NULL) + return; + + png_debug2(1, "in png_read_row (row %lu, pass %d)", png_ptr->row_number, png_ptr->pass); + if (!(png_ptr->flags & PNG_FLAG_ROW_INIT)) png_read_start_row(png_ptr); if (png_ptr->row_number == 0 && png_ptr->pass == 0) { - /* check for transforms that have been set but were defined out */ + /* Check for transforms that have been set but were defined out */ #if defined(PNG_WRITE_INVERT_SUPPORTED) && !defined(PNG_READ_INVERT_SUPPORTED) if (png_ptr->transformations & PNG_INVERT_MONO) png_warning(png_ptr, "PNG_READ_INVERT_SUPPORTED is not defined."); @@ -587,7 +616,8 @@ png_read_row(png_structp png_ptr, png_bytep row, png_bytep dsp_row) if (png_ptr->transformations & PNG_FILLER) png_warning(png_ptr, "PNG_READ_FILLER_SUPPORTED is not defined."); #endif -#if defined(PNG_WRITE_PACKSWAP_SUPPORTED) && !defined(PNG_READ_PACKSWAP_SUPPORTED) +#if defined(PNG_WRITE_PACKSWAP_SUPPORTED) && \ + !defined(PNG_READ_PACKSWAP_SUPPORTED) if (png_ptr->transformations & PNG_PACKSWAP) png_warning(png_ptr, "PNG_READ_PACKSWAP_SUPPORTED is not defined."); #endif @@ -609,8 +639,8 @@ png_read_row(png_structp png_ptr, png_bytep row, png_bytep dsp_row) #endif } -#if defined(PNG_READ_INTERLACING_SUPPORTED) - /* if interlaced and we do not need a new row, combine row and return */ +#ifdef PNG_READ_INTERLACING_SUPPORTED + /* If interlaced and we do not need a new row, combine row and return */ if (png_ptr->interlaced && (png_ptr->transformations & PNG_INTERLACE)) { switch (png_ptr->pass) @@ -690,22 +720,18 @@ png_read_row(png_structp png_ptr, png_bytep row, png_bytep dsp_row) png_error(png_ptr, "Invalid attempt to read row data"); png_ptr->zstream.next_out = png_ptr->row_buf; - png_ptr->zstream.avail_out = (uInt)png_ptr->irowbytes; + png_ptr->zstream.avail_out = + (uInt)(PNG_ROWBYTES(png_ptr->pixel_depth, + png_ptr->iwidth) + 1); do { if (!(png_ptr->zstream.avail_in)) { while (!png_ptr->idat_size) { - png_byte chunk_length[4]; - png_crc_finish(png_ptr, 0); - png_read_data(png_ptr, chunk_length, 4); - png_ptr->idat_size = png_get_uint_31(png_ptr,chunk_length); - - png_reset_crc(png_ptr); - png_crc_read(png_ptr, png_ptr->chunk_name, 4); + png_ptr->idat_size = png_read_chunk_header(png_ptr); if (png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) png_error(png_ptr, "Not enough image data"); } @@ -741,7 +767,7 @@ png_read_row(png_structp png_ptr, png_bytep row, png_bytep dsp_row) png_ptr->row_info.rowbytes = PNG_ROWBYTES(png_ptr->row_info.pixel_depth, png_ptr->row_info.width); - if(png_ptr->row_buf[0]) + if (png_ptr->row_buf[0]) png_read_filter_row(png_ptr, &(png_ptr->row_info), png_ptr->row_buf + 1, png_ptr->prev_row + 1, (int)(png_ptr->row_buf[0])); @@ -749,8 +775,8 @@ png_read_row(png_structp png_ptr, png_bytep row, png_bytep dsp_row) png_memcpy_check(png_ptr, png_ptr->prev_row, png_ptr->row_buf, png_ptr->rowbytes + 1); -#if defined(PNG_MNG_FEATURES_SUPPORTED) - if((png_ptr->mng_features_permitted & PNG_FLAG_MNG_FILTER_64) && +#ifdef PNG_MNG_FEATURES_SUPPORTED + if ((png_ptr->mng_features_permitted & PNG_FLAG_MNG_FILTER_64) && (png_ptr->filter_type == PNG_INTRAPIXEL_DIFFERENCING)) { /* Intrapixel differencing */ @@ -762,16 +788,16 @@ png_read_row(png_structp png_ptr, png_bytep row, png_bytep dsp_row) if (png_ptr->transformations || (png_ptr->flags&PNG_FLAG_STRIP_ALPHA)) png_do_read_transformations(png_ptr); -#if defined(PNG_READ_INTERLACING_SUPPORTED) - /* blow up interlaced rows to full size */ +#ifdef PNG_READ_INTERLACING_SUPPORTED + /* Blow up interlaced rows to full size */ if (png_ptr->interlaced && (png_ptr->transformations & PNG_INTERLACE)) { if (png_ptr->pass < 6) -/* old interface (pre-1.0.9): - png_do_read_interlace(&(png_ptr->row_info), - png_ptr->row_buf + 1, png_ptr->pass, png_ptr->transformations); - */ + /* Old interface (pre-1.0.9): + * png_do_read_interlace(&(png_ptr->row_info), + * png_ptr->row_buf + 1, png_ptr->pass, png_ptr->transformations); + */ png_do_read_interlace(png_ptr); if (dsp_row != NULL) @@ -794,9 +820,9 @@ png_read_row(png_structp png_ptr, png_bytep row, png_bytep dsp_row) if (png_ptr->read_row_fn != NULL) (*(png_ptr->read_row_fn))(png_ptr, png_ptr->row_number, png_ptr->pass); } -#endif /* PNG_NO_SEQUENTIAL_READ_SUPPORTED */ +#endif /* PNG_SEQUENTIAL_READ_SUPPORTED */ -#ifndef PNG_NO_SEQUENTIAL_READ_SUPPORTED +#ifdef PNG_SEQUENTIAL_READ_SUPPORTED /* Read one or more rows of image data. If the image is interlaced, * and png_set_interlace_handling() has been called, the rows need to * contain the contents of the rows from the previous pass. If the @@ -829,8 +855,10 @@ png_read_rows(png_structp png_ptr, png_bytepp row, png_bytepp rp; png_bytepp dp; - png_debug(1, "in png_read_rows\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_read_rows"); + + if (png_ptr == NULL) + return; rp = row; dp = display_row; if (rp != NULL && dp != NULL) @@ -841,14 +869,14 @@ png_read_rows(png_structp png_ptr, png_bytepp row, png_read_row(png_ptr, rptr, dptr); } - else if(rp != NULL) + else if (rp != NULL) for (i = 0; i < num_rows; i++) { png_bytep rptr = *rp; png_read_row(png_ptr, rptr, png_bytep_NULL); rp++; } - else if(dp != NULL) + else if (dp != NULL) for (i = 0; i < num_rows; i++) { png_bytep dptr = *dp; @@ -856,9 +884,9 @@ png_read_rows(png_structp png_ptr, png_bytepp row, dp++; } } -#endif /* PNG_NO_SEQUENTIAL_READ_SUPPORTED */ +#endif /* PNG_SEQUENTIAL_READ_SUPPORTED */ -#ifndef PNG_NO_SEQUENTIAL_READ_SUPPORTED +#ifdef PNG_SEQUENTIAL_READ_SUPPORTED /* Read the entire image. If the image has an alpha channel or a tRNS * chunk, and you have called png_handle_alpha()[*], you will need to * initialize the image to the current image that PNG will be overlaying. @@ -874,12 +902,14 @@ png_read_rows(png_structp png_ptr, png_bytepp row, void PNGAPI png_read_image(png_structp png_ptr, png_bytepp image) { - png_uint_32 i,image_height; + png_uint_32 i, image_height; int pass, j; png_bytepp rp; - png_debug(1, "in png_read_image\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_read_image"); + + if (png_ptr == NULL) + return; #ifdef PNG_READ_INTERLACING_SUPPORTED pass = png_set_interlace_handling(png_ptr); @@ -904,9 +934,9 @@ png_read_image(png_structp png_ptr, png_bytepp image) } } } -#endif /* PNG_NO_SEQUENTIAL_READ_SUPPORTED */ +#endif /* PNG_SEQUENTIAL_READ_SUPPORTED */ -#ifndef PNG_NO_SEQUENTIAL_READ_SUPPORTED +#ifdef PNG_SEQUENTIAL_READ_SUPPORTED /* Read the end of the PNG file. Will not read past the end of the * file, will verify the end is accurate, and will read any comments * or time information at the end of the file, if info is not NULL. @@ -914,11 +944,10 @@ png_read_image(png_structp png_ptr, png_bytepp image) void PNGAPI png_read_end(png_structp png_ptr, png_infop info_ptr) { - png_byte chunk_length[4]; - png_uint_32 length; - - png_debug(1, "in png_read_end\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_read_end"); + + if (png_ptr == NULL) + return; png_crc_finish(png_ptr, 0); /* Finish off CRC from last IDAT chunk */ do @@ -928,85 +957,79 @@ png_read_end(png_structp png_ptr, png_infop info_ptr) PNG_CONST PNG_IDAT; PNG_CONST PNG_IEND; PNG_CONST PNG_PLTE; -#if defined(PNG_READ_bKGD_SUPPORTED) +#ifdef PNG_READ_bKGD_SUPPORTED PNG_CONST PNG_bKGD; #endif -#if defined(PNG_READ_cHRM_SUPPORTED) +#ifdef PNG_READ_cHRM_SUPPORTED PNG_CONST PNG_cHRM; #endif -#if defined(PNG_READ_gAMA_SUPPORTED) +#ifdef PNG_READ_gAMA_SUPPORTED PNG_CONST PNG_gAMA; #endif -#if defined(PNG_READ_hIST_SUPPORTED) +#ifdef PNG_READ_hIST_SUPPORTED PNG_CONST PNG_hIST; #endif -#if defined(PNG_READ_iCCP_SUPPORTED) +#ifdef PNG_READ_iCCP_SUPPORTED PNG_CONST PNG_iCCP; #endif -#if defined(PNG_READ_iTXt_SUPPORTED) +#ifdef PNG_READ_iTXt_SUPPORTED PNG_CONST PNG_iTXt; #endif -#if defined(PNG_READ_oFFs_SUPPORTED) +#ifdef PNG_READ_oFFs_SUPPORTED PNG_CONST PNG_oFFs; #endif -#if defined(PNG_READ_pCAL_SUPPORTED) +#ifdef PNG_READ_pCAL_SUPPORTED PNG_CONST PNG_pCAL; #endif -#if defined(PNG_READ_pHYs_SUPPORTED) +#ifdef PNG_READ_pHYs_SUPPORTED PNG_CONST PNG_pHYs; #endif -#if defined(PNG_READ_sBIT_SUPPORTED) +#ifdef PNG_READ_sBIT_SUPPORTED PNG_CONST PNG_sBIT; #endif -#if defined(PNG_READ_sCAL_SUPPORTED) +#ifdef PNG_READ_sCAL_SUPPORTED PNG_CONST PNG_sCAL; #endif -#if defined(PNG_READ_sPLT_SUPPORTED) +#ifdef PNG_READ_sPLT_SUPPORTED PNG_CONST PNG_sPLT; #endif -#if defined(PNG_READ_sRGB_SUPPORTED) +#ifdef PNG_READ_sRGB_SUPPORTED PNG_CONST PNG_sRGB; #endif -#if defined(PNG_READ_tEXt_SUPPORTED) +#ifdef PNG_READ_tEXt_SUPPORTED PNG_CONST PNG_tEXt; #endif -#if defined(PNG_READ_tIME_SUPPORTED) +#ifdef PNG_READ_tIME_SUPPORTED PNG_CONST PNG_tIME; #endif -#if defined(PNG_READ_tRNS_SUPPORTED) +#ifdef PNG_READ_tRNS_SUPPORTED PNG_CONST PNG_tRNS; #endif -#if defined(PNG_READ_zTXt_SUPPORTED) +#ifdef PNG_READ_zTXt_SUPPORTED PNG_CONST PNG_zTXt; #endif #endif /* PNG_USE_LOCAL_ARRAYS */ + png_uint_32 length = png_read_chunk_header(png_ptr); + PNG_CONST png_bytep chunk_name = png_ptr->chunk_name; - png_read_data(png_ptr, chunk_length, 4); - length = png_get_uint_31(png_ptr,chunk_length); - - png_reset_crc(png_ptr); - png_crc_read(png_ptr, png_ptr->chunk_name, 4); - - png_debug1(0, "Reading %s chunk.\n", png_ptr->chunk_name); - - if (!png_memcmp(png_ptr->chunk_name, png_IHDR, 4)) + if (!png_memcmp(chunk_name, png_IHDR, 4)) png_handle_IHDR(png_ptr, info_ptr, length); - else if (!png_memcmp(png_ptr->chunk_name, png_IEND, 4)) + else if (!png_memcmp(chunk_name, png_IEND, 4)) png_handle_IEND(png_ptr, info_ptr, length); #ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED - else if (png_handle_as_unknown(png_ptr, png_ptr->chunk_name)) + else if (png_handle_as_unknown(png_ptr, chunk_name)) { - if (!png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) + if (!png_memcmp(chunk_name, png_IDAT, 4)) { if ((length > 0) || (png_ptr->mode & PNG_HAVE_CHUNK_AFTER_IDAT)) png_error(png_ptr, "Too many IDAT's found"); } png_handle_unknown(png_ptr, info_ptr, length); - if (!png_memcmp(png_ptr->chunk_name, png_PLTE, 4)) + if (!png_memcmp(chunk_name, png_PLTE, 4)) png_ptr->mode |= PNG_HAVE_PLTE; } #endif - else if (!png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) + else if (!png_memcmp(chunk_name, png_IDAT, 4)) { /* Zero length IDATs are legal after the last IDAT has been * read, but not after other chunks have been read. @@ -1015,83 +1038,83 @@ png_read_end(png_structp png_ptr, png_infop info_ptr) png_error(png_ptr, "Too many IDAT's found"); png_crc_finish(png_ptr, length); } - else if (!png_memcmp(png_ptr->chunk_name, png_PLTE, 4)) + else if (!png_memcmp(chunk_name, png_PLTE, 4)) png_handle_PLTE(png_ptr, info_ptr, length); -#if defined(PNG_READ_bKGD_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_bKGD, 4)) +#ifdef PNG_READ_bKGD_SUPPORTED + else if (!png_memcmp(chunk_name, png_bKGD, 4)) png_handle_bKGD(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_cHRM_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_cHRM, 4)) +#ifdef PNG_READ_cHRM_SUPPORTED + else if (!png_memcmp(chunk_name, png_cHRM, 4)) png_handle_cHRM(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_gAMA_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_gAMA, 4)) +#ifdef PNG_READ_gAMA_SUPPORTED + else if (!png_memcmp(chunk_name, png_gAMA, 4)) png_handle_gAMA(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_hIST_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_hIST, 4)) +#ifdef PNG_READ_hIST_SUPPORTED + else if (!png_memcmp(chunk_name, png_hIST, 4)) png_handle_hIST(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_oFFs_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_oFFs, 4)) +#ifdef PNG_READ_oFFs_SUPPORTED + else if (!png_memcmp(chunk_name, png_oFFs, 4)) png_handle_oFFs(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_pCAL_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_pCAL, 4)) +#ifdef PNG_READ_pCAL_SUPPORTED + else if (!png_memcmp(chunk_name, png_pCAL, 4)) png_handle_pCAL(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_sCAL_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_sCAL, 4)) +#ifdef PNG_READ_sCAL_SUPPORTED + else if (!png_memcmp(chunk_name, png_sCAL, 4)) png_handle_sCAL(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_pHYs_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_pHYs, 4)) +#ifdef PNG_READ_pHYs_SUPPORTED + else if (!png_memcmp(chunk_name, png_pHYs, 4)) png_handle_pHYs(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_sBIT_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_sBIT, 4)) +#ifdef PNG_READ_sBIT_SUPPORTED + else if (!png_memcmp(chunk_name, png_sBIT, 4)) png_handle_sBIT(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_sRGB_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_sRGB, 4)) +#ifdef PNG_READ_sRGB_SUPPORTED + else if (!png_memcmp(chunk_name, png_sRGB, 4)) png_handle_sRGB(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_iCCP_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_iCCP, 4)) +#ifdef PNG_READ_iCCP_SUPPORTED + else if (!png_memcmp(chunk_name, png_iCCP, 4)) png_handle_iCCP(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_sPLT_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_sPLT, 4)) +#ifdef PNG_READ_sPLT_SUPPORTED + else if (!png_memcmp(chunk_name, png_sPLT, 4)) png_handle_sPLT(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_tEXt_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_tEXt, 4)) +#ifdef PNG_READ_tEXt_SUPPORTED + else if (!png_memcmp(chunk_name, png_tEXt, 4)) png_handle_tEXt(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_tIME_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_tIME, 4)) +#ifdef PNG_READ_tIME_SUPPORTED + else if (!png_memcmp(chunk_name, png_tIME, 4)) png_handle_tIME(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_tRNS_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_tRNS, 4)) +#ifdef PNG_READ_tRNS_SUPPORTED + else if (!png_memcmp(chunk_name, png_tRNS, 4)) png_handle_tRNS(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_zTXt_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_zTXt, 4)) +#ifdef PNG_READ_zTXt_SUPPORTED + else if (!png_memcmp(chunk_name, png_zTXt, 4)) png_handle_zTXt(png_ptr, info_ptr, length); #endif -#if defined(PNG_READ_iTXt_SUPPORTED) - else if (!png_memcmp(png_ptr->chunk_name, png_iTXt, 4)) +#ifdef PNG_READ_iTXt_SUPPORTED + else if (!png_memcmp(chunk_name, png_iTXt, 4)) png_handle_iTXt(png_ptr, info_ptr, length); #endif else png_handle_unknown(png_ptr, info_ptr, length); } while (!(png_ptr->mode & PNG_HAVE_IEND)); } -#endif /* PNG_NO_SEQUENTIAL_READ_SUPPORTED */ +#endif /* PNG_SEQUENTIAL_READ_SUPPORTED */ -/* free all memory used by the read */ +/* Free all memory used by the read */ void PNGAPI png_destroy_read_struct(png_structpp png_ptr_ptr, png_infopp info_ptr_ptr, png_infopp end_info_ptr_ptr) @@ -1099,13 +1122,21 @@ png_destroy_read_struct(png_structpp png_ptr_ptr, png_infopp info_ptr_ptr, png_structp png_ptr = NULL; png_infop info_ptr = NULL, end_info_ptr = NULL; #ifdef PNG_USER_MEM_SUPPORTED - png_free_ptr free_fn; - png_voidp mem_ptr; + png_free_ptr free_fn = NULL; + png_voidp mem_ptr = NULL; #endif - png_debug(1, "in png_destroy_read_struct\n"); + png_debug(1, "in png_destroy_read_struct"); + if (png_ptr_ptr != NULL) png_ptr = *png_ptr_ptr; + if (png_ptr == NULL) + return; + +#ifdef PNG_USER_MEM_SUPPORTED + free_fn = png_ptr->free_fn; + mem_ptr = png_ptr->mem_ptr; +#endif if (info_ptr_ptr != NULL) info_ptr = *info_ptr_ptr; @@ -1113,16 +1144,11 @@ png_destroy_read_struct(png_structpp png_ptr_ptr, png_infopp info_ptr_ptr, if (end_info_ptr_ptr != NULL) end_info_ptr = *end_info_ptr_ptr; -#ifdef PNG_USER_MEM_SUPPORTED - free_fn = png_ptr->free_fn; - mem_ptr = png_ptr->mem_ptr; -#endif - png_read_destroy(png_ptr, info_ptr, end_info_ptr); if (info_ptr != NULL) { -#if defined(PNG_TEXT_SUPPORTED) +#ifdef PNG_TEXT_SUPPORTED png_free_data(png_ptr, info_ptr, PNG_FREE_TEXT, -1); #endif @@ -1137,7 +1163,7 @@ png_destroy_read_struct(png_structpp png_ptr_ptr, png_infopp info_ptr_ptr, if (end_info_ptr != NULL) { -#if defined(PNG_READ_TEXT_SUPPORTED) +#ifdef PNG_READ_TEXT_SUPPORTED png_free_data(png_ptr, end_info_ptr, PNG_FREE_TEXT, -1); #endif #ifdef PNG_USER_MEM_SUPPORTED @@ -1161,9 +1187,10 @@ png_destroy_read_struct(png_structpp png_ptr_ptr, png_infopp info_ptr_ptr, } } -/* free all memory used by the read (old method) */ +/* Free all memory used by the read (old method) */ void /* PRIVATE */ -png_read_destroy(png_structp png_ptr, png_infop info_ptr, png_infop end_info_ptr) +png_read_destroy(png_structp png_ptr, png_infop info_ptr, + png_infop end_info_ptr) { #ifdef PNG_SETJMP_SUPPORTED jmp_buf tmp_jmp; @@ -1175,7 +1202,8 @@ png_read_destroy(png_structp png_ptr, png_infop info_ptr, png_infop end_info_ptr png_free_ptr free_fn; #endif - png_debug(1, "in png_read_destroy\n"); + png_debug(1, "in png_read_destroy"); + if (info_ptr != NULL) png_info_destroy(png_ptr, info_ptr); @@ -1185,14 +1213,15 @@ png_read_destroy(png_structp png_ptr, png_infop info_ptr, png_infop end_info_ptr png_free(png_ptr, png_ptr->zbuf); png_free(png_ptr, png_ptr->big_row_buf); png_free(png_ptr, png_ptr->prev_row); -#if defined(PNG_READ_DITHER_SUPPORTED) + png_free(png_ptr, png_ptr->chunkdata); +#ifdef PNG_READ_DITHER_SUPPORTED png_free(png_ptr, png_ptr->palette_lookup); png_free(png_ptr, png_ptr->dither_index); #endif -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED png_free(png_ptr, png_ptr->gamma_table); #endif -#if defined(PNG_READ_BACKGROUND_SUPPORTED) +#ifdef PNG_READ_BACKGROUND_SUPPORTED png_free(png_ptr, png_ptr->gamma_from_1); png_free(png_ptr, png_ptr->gamma_to_1); #endif @@ -1217,7 +1246,7 @@ png_read_destroy(png_structp png_ptr, png_infop info_ptr, png_infop end_info_ptr png_ptr->flags &= ~PNG_FLAG_FREE_TRNS; #endif #endif -#if defined(PNG_READ_hIST_SUPPORTED) +#ifdef PNG_READ_hIST_SUPPORTED #ifdef PNG_FREE_ME_SUPPORTED if (png_ptr->free_me & PNG_FREE_HIST) png_free(png_ptr, png_ptr->hist); @@ -1228,7 +1257,7 @@ png_read_destroy(png_structp png_ptr, png_infop info_ptr, png_infop end_info_ptr png_ptr->flags &= ~PNG_FLAG_FREE_HIST; #endif #endif -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (png_ptr->gamma_16_table != NULL) { int i; @@ -1239,7 +1268,7 @@ png_read_destroy(png_structp png_ptr, png_infop info_ptr, png_infop end_info_ptr } png_free(png_ptr, png_ptr->gamma_16_table); } -#if defined(PNG_READ_BACKGROUND_SUPPORTED) +#ifdef PNG_READ_BACKGROUND_SUPPORTED if (png_ptr->gamma_16_from_1 != NULL) { int i; @@ -1262,7 +1291,7 @@ png_read_destroy(png_structp png_ptr, png_infop info_ptr, png_infop end_info_ptr } #endif #endif -#if defined(PNG_TIME_RFC1123_SUPPORTED) +#ifdef PNG_TIME_RFC1123_SUPPORTED png_free(png_ptr, png_ptr->time_buffer); #endif @@ -1271,17 +1300,11 @@ png_read_destroy(png_structp png_ptr, png_infop info_ptr, png_infop end_info_ptr png_free(png_ptr, png_ptr->save_buffer); #endif -#ifdef PNG_PROGRESSIVE_READ_SUPPORTED -#ifdef PNG_TEXT_SUPPORTED - png_free(png_ptr, png_ptr->current_text); -#endif /* PNG_TEXT_SUPPORTED */ -#endif /* PNG_PROGRESSIVE_READ_SUPPORTED */ - /* Save the important info out of the png_struct, in case it is * being used again. */ #ifdef PNG_SETJMP_SUPPORTED - png_memcpy(tmp_jmp, png_ptr->jmpbuf, png_sizeof (jmp_buf)); + png_memcpy(tmp_jmp, png_ptr->jmpbuf, png_sizeof(jmp_buf)); #endif error_fn = png_ptr->error_fn; @@ -1291,7 +1314,7 @@ png_read_destroy(png_structp png_ptr, png_infop info_ptr, png_infop end_info_ptr free_fn = png_ptr->free_fn; #endif - png_memset(png_ptr, 0, png_sizeof (png_struct)); + png_memset(png_ptr, 0, png_sizeof(png_struct)); png_ptr->error_fn = error_fn; png_ptr->warning_fn = warning_fn; @@ -1301,7 +1324,7 @@ png_read_destroy(png_structp png_ptr, png_infop info_ptr, png_infop end_info_ptr #endif #ifdef PNG_SETJMP_SUPPORTED - png_memcpy(png_ptr->jmpbuf, tmp_jmp, png_sizeof (jmp_buf)); + png_memcpy(png_ptr->jmpbuf, tmp_jmp, png_sizeof(jmp_buf)); #endif } @@ -1309,13 +1332,14 @@ png_read_destroy(png_structp png_ptr, png_infop info_ptr, png_infop end_info_ptr void PNGAPI png_set_read_status_fn(png_structp png_ptr, png_read_status_ptr read_row_fn) { - if(png_ptr == NULL) return; + if (png_ptr == NULL) + return; png_ptr->read_row_fn = read_row_fn; } -#ifndef PNG_NO_SEQUENTIAL_READ_SUPPORTED -#if defined(PNG_INFO_IMAGE_SUPPORTED) +#ifdef PNG_SEQUENTIAL_READ_SUPPORTED +#ifdef PNG_INFO_IMAGE_SUPPORTED void PNGAPI png_read_png(png_structp png_ptr, png_infop info_ptr, int transforms, @@ -1323,9 +1347,10 @@ png_read_png(png_structp png_ptr, png_infop info_ptr, { int row; - if(png_ptr == NULL) return; -#if defined(PNG_READ_INVERT_ALPHA_SUPPORTED) - /* invert the alpha channel from opacity to transparency + if (png_ptr == NULL) + return; +#ifdef PNG_READ_INVERT_ALPHA_SUPPORTED + /* Invert the alpha channel from opacity to transparency */ if (transforms & PNG_TRANSFORM_INVERT_ALPHA) png_set_invert_alpha(png_ptr); @@ -1336,23 +1361,23 @@ png_read_png(png_structp png_ptr, png_infop info_ptr, */ png_read_info(png_ptr, info_ptr); if (info_ptr->height > PNG_UINT_32_MAX/png_sizeof(png_bytep)) - png_error(png_ptr,"Image is too high to process with png_read_png()"); + png_error(png_ptr, "Image is too high to process with png_read_png()"); /* -------------- image transformations start here ------------------- */ -#if defined(PNG_READ_16_TO_8_SUPPORTED) - /* tell libpng to strip 16 bit/color files down to 8 bits per color +#ifdef PNG_READ_16_TO_8_SUPPORTED + /* Tell libpng to strip 16 bit/color files down to 8 bits per color. */ if (transforms & PNG_TRANSFORM_STRIP_16) - png_set_strip_16(png_ptr); + png_set_strip_16(png_ptr); #endif -#if defined(PNG_READ_STRIP_ALPHA_SUPPORTED) +#ifdef PNG_READ_STRIP_ALPHA_SUPPORTED /* Strip alpha bytes from the input data without combining with * the background (not recommended). */ if (transforms & PNG_TRANSFORM_STRIP_ALPHA) - png_set_strip_alpha(png_ptr); + png_set_strip_alpha(png_ptr); #endif #if defined(PNG_READ_PACK_SUPPORTED) && !defined(PNG_READ_EXPAND_SUPPORTED) @@ -1360,41 +1385,41 @@ png_read_png(png_structp png_ptr, png_infop info_ptr, * byte into separate bytes (useful for paletted and grayscale images). */ if (transforms & PNG_TRANSFORM_PACKING) - png_set_packing(png_ptr); + png_set_packing(png_ptr); #endif -#if defined(PNG_READ_PACKSWAP_SUPPORTED) +#ifdef PNG_READ_PACKSWAP_SUPPORTED /* Change the order of packed pixels to least significant bit first * (not useful if you are using png_set_packing). */ if (transforms & PNG_TRANSFORM_PACKSWAP) - png_set_packswap(png_ptr); + png_set_packswap(png_ptr); #endif -#if defined(PNG_READ_EXPAND_SUPPORTED) +#ifdef PNG_READ_EXPAND_SUPPORTED /* Expand paletted colors into true RGB triplets * Expand grayscale images to full 8 bits from 1, 2, or 4 bits/pixel * Expand paletted or RGB images with transparency to full alpha * channels so the data will be available as RGBA quartets. */ if (transforms & PNG_TRANSFORM_EXPAND) - if ((png_ptr->bit_depth < 8) || - (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE) || - (png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS))) + if ((png_ptr->bit_depth < 8) || + (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE) || + (png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS))) png_set_expand(png_ptr); #endif /* We don't handle background color or gamma transformation or dithering. */ -#if defined(PNG_READ_INVERT_SUPPORTED) - /* invert monochrome files to have 0 as white and 1 as black +#ifdef PNG_READ_INVERT_SUPPORTED + /* Invert monochrome files to have 0 as white and 1 as black */ if (transforms & PNG_TRANSFORM_INVERT_MONO) - png_set_invert_mono(png_ptr); + png_set_invert_mono(png_ptr); #endif -#if defined(PNG_READ_SHIFT_SUPPORTED) +#ifdef PNG_READ_SHIFT_SUPPORTED /* If you want to shift the pixel values from the range [0,255] or * [0,65535] to the original [0,7] or [0,31], or whatever range the * colors were originally in: @@ -1409,25 +1434,41 @@ png_read_png(png_structp png_ptr, png_infop info_ptr, } #endif -#if defined(PNG_READ_BGR_SUPPORTED) - /* flip the RGB pixels to BGR (or RGBA to BGRA) +#ifdef PNG_READ_BGR_SUPPORTED + /* Flip the RGB pixels to BGR (or RGBA to BGRA) */ if (transforms & PNG_TRANSFORM_BGR) - png_set_bgr(png_ptr); + png_set_bgr(png_ptr); #endif -#if defined(PNG_READ_SWAP_ALPHA_SUPPORTED) - /* swap the RGBA or GA data to ARGB or AG (or BGRA to ABGR) +#ifdef PNG_READ_SWAP_ALPHA_SUPPORTED + /* Swap the RGBA or GA data to ARGB or AG (or BGRA to ABGR) */ if (transforms & PNG_TRANSFORM_SWAP_ALPHA) png_set_swap_alpha(png_ptr); #endif -#if defined(PNG_READ_SWAP_SUPPORTED) - /* swap bytes of 16 bit files to least significant byte first +#ifdef PNG_READ_SWAP_SUPPORTED + /* Swap bytes of 16 bit files to least significant byte first */ if (transforms & PNG_TRANSFORM_SWAP_ENDIAN) - png_set_swap(png_ptr); + png_set_swap(png_ptr); +#endif + +/* Added at libpng-1.2.41 */ +#ifdef PNG_READ_INVERT_ALPHA_SUPPORTED + /* Invert the alpha channel from opacity to transparency + */ + if (transforms & PNG_TRANSFORM_INVERT_ALPHA) + png_set_invert_alpha(png_ptr); +#endif + +/* Added at libpng-1.2.41 */ +#ifdef PNG_READ_GRAY_TO_RGB_SUPPORTED + /* Expand grayscale image to RGB + */ + if (transforms & PNG_TRANSFORM_GRAY_TO_RGB) + png_set_gray_to_rgb(png_ptr); #endif /* We don't handle adding filler bytes */ @@ -1443,30 +1484,32 @@ png_read_png(png_structp png_ptr, png_infop info_ptr, #ifdef PNG_FREE_ME_SUPPORTED png_free_data(png_ptr, info_ptr, PNG_FREE_ROWS, 0); #endif - if(info_ptr->row_pointers == NULL) + if (info_ptr->row_pointers == NULL) { info_ptr->row_pointers = (png_bytepp)png_malloc(png_ptr, info_ptr->height * png_sizeof(png_bytep)); + png_memset(info_ptr->row_pointers, 0, info_ptr->height + * png_sizeof(png_bytep)); + #ifdef PNG_FREE_ME_SUPPORTED info_ptr->free_me |= PNG_FREE_ROWS; #endif + for (row = 0; row < (int)info_ptr->height; row++) - { info_ptr->row_pointers[row] = (png_bytep)png_malloc(png_ptr, png_get_rowbytes(png_ptr, info_ptr)); - } } png_read_image(png_ptr, info_ptr->row_pointers); info_ptr->valid |= PNG_INFO_IDAT; - /* read rest of file, and get additional chunks in info_ptr - REQUIRED */ + /* Read rest of file, and get additional chunks in info_ptr - REQUIRED */ png_read_end(png_ptr, info_ptr); - transforms = transforms; /* quiet compiler warnings */ + transforms = transforms; /* Quiet compiler warnings */ params = params; } #endif /* PNG_INFO_IMAGE_SUPPORTED */ -#endif /* PNG_NO_SEQUENTIAL_READ_SUPPORTED */ +#endif /* PNG_SEQUENTIAL_READ_SUPPORTED */ #endif /* PNG_READ_SUPPORTED */ diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngrio.c b/graf2d/asimage/src/libAfterImage/libpng/pngrio.c index 7d2522f1f86e9..6978682c7f12a 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngrio.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngrio.c @@ -1,12 +1,15 @@ /* pngrio.c - functions for data input * - * Last changed in libpng 1.2.13 November 13, 2006 - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2006 Glenn Randers-Pehrson + * Last changed in libpng 1.2.43 [February 25, 2010] + * Copyright (c) 1998-2010 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h + * * This file provides a location for all input. Users who need * special handling are expected to write a function that has the same * arguments as this and performs a similar function, but that possibly @@ -16,41 +19,45 @@ */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" - -#if defined(PNG_READ_SUPPORTED) +#ifdef PNG_READ_SUPPORTED /* Read the data from whatever input you are using. The default routine - reads from a file pointer. Note that this routine sometimes gets called - with very small lengths, so you should implement some kind of simple - buffering if you are using unbuffered reads. This should never be asked - to read more then 64K on a 16 bit machine. */ + * reads from a file pointer. Note that this routine sometimes gets called + * with very small lengths, so you should implement some kind of simple + * buffering if you are using unbuffered reads. This should never be asked + * to read more then 64K on a 16 bit machine. + */ void /* PRIVATE */ png_read_data(png_structp png_ptr, png_bytep data, png_size_t length) { - png_debug1(4,"reading %d bytes\n", (int)length); + png_debug1(4, "reading %d bytes", (int)length); + if (png_ptr->read_data_fn != NULL) (*(png_ptr->read_data_fn))(png_ptr, data, length); else png_error(png_ptr, "Call to NULL read function"); } -#if !defined(PNG_NO_STDIO) +#ifdef PNG_STDIO_SUPPORTED /* This is the function that does the actual reading of data. If you are - not reading from a standard C stream, you should create a replacement - read_data function and use it at run time with png_set_read_fn(), rather - than changing the library. */ + * not reading from a standard C stream, you should create a replacement + * read_data function and use it at run time with png_set_read_fn(), rather + * than changing the library. + */ #ifndef USE_FAR_KEYWORD void PNGAPI png_default_read_data(png_structp png_ptr, png_bytep data, png_size_t length) { png_size_t check; - if(png_ptr == NULL) return; + if (png_ptr == NULL) + return; /* fread() returns 0 on error, so it is OK to store this in a png_size_t * instead of an int, which is what fread() actually returns. */ -#if defined(_WIN32_WCE) +#ifdef _WIN32_WCE if ( !ReadFile((HANDLE)(png_ptr->io_ptr), data, length, &check, NULL) ) check = 0; #else @@ -62,7 +69,7 @@ png_default_read_data(png_structp png_ptr, png_bytep data, png_size_t length) png_error(png_ptr, "Read Error"); } #else -/* this is the model-independent version. Since the standard I/O library +/* This is the model-independent version. Since the standard I/O library can't handle far buffers in the medium and small models, we have to copy the data. */ @@ -77,14 +84,16 @@ png_default_read_data(png_structp png_ptr, png_bytep data, png_size_t length) png_byte *n_data; png_FILE_p io_ptr; - if(png_ptr == NULL) return; + if (png_ptr == NULL) + return; /* Check if data really is near. If so, use usual code. */ n_data = (png_byte *)CVT_PTR_NOCHECK(data); io_ptr = (png_FILE_p)CVT_PTR(png_ptr->io_ptr); if ((png_bytep)n_data == data) { -#if defined(_WIN32_WCE) - if ( !ReadFile((HANDLE)(png_ptr->io_ptr), data, length, &check, NULL) ) +#ifdef _WIN32_WCE + if ( !ReadFile((HANDLE)(png_ptr->io_ptr), data, length, &check, + NULL) ) check = 0; #else check = fread(n_data, 1, length, io_ptr); @@ -99,14 +108,14 @@ png_default_read_data(png_structp png_ptr, png_bytep data, png_size_t length) do { read = MIN(NEAR_BUF_SIZE, remaining); -#if defined(_WIN32_WCE) +#ifdef _WIN32_WCE if ( !ReadFile((HANDLE)(io_ptr), buf, read, &err, NULL) ) err = 0; #else err = fread(buf, (png_size_t)1, read, io_ptr); #endif png_memcpy(data, buf, read); /* copy far buffer to near buffer */ - if(err != read) + if (err != read) break; else check += err; @@ -122,26 +131,30 @@ png_default_read_data(png_structp png_ptr, png_bytep data, png_size_t length) #endif /* This function allows the application to supply a new input function - for libpng if standard C streams aren't being used. - - This function takes as its arguments: - png_ptr - pointer to a png input data structure - io_ptr - pointer to user supplied structure containing info about - the input functions. May be NULL. - read_data_fn - pointer to a new input function that takes as its - arguments a pointer to a png_struct, a pointer to - a location where input data can be stored, and a 32-bit - unsigned int that is the number of bytes to be read. - To exit and output any fatal error messages the new write - function should call png_error(png_ptr, "Error msg"). */ + * for libpng if standard C streams aren't being used. + * + * This function takes as its arguments: + * png_ptr - pointer to a png input data structure + * io_ptr - pointer to user supplied structure containing info about + * the input functions. May be NULL. + * read_data_fn - pointer to a new input function that takes as its + * arguments a pointer to a png_struct, a pointer to + * a location where input data can be stored, and a 32-bit + * unsigned int that is the number of bytes to be read. + * To exit and output any fatal error messages the new write + * function should call png_error(png_ptr, "Error msg"). + * May be NULL, in which case libpng's default function will + * be used. + */ void PNGAPI png_set_read_fn(png_structp png_ptr, png_voidp io_ptr, png_rw_ptr read_data_fn) { - if(png_ptr == NULL) return; + if (png_ptr == NULL) + return; png_ptr->io_ptr = io_ptr; -#if !defined(PNG_NO_STDIO) +#ifdef PNG_STDIO_SUPPORTED if (read_data_fn != NULL) png_ptr->read_data_fn = read_data_fn; else @@ -160,7 +173,7 @@ png_set_read_fn(png_structp png_ptr, png_voidp io_ptr, "same structure. Resetting write_data_fn to NULL."); } -#if defined(PNG_WRITE_FLUSH_SUPPORTED) +#ifdef PNG_WRITE_FLUSH_SUPPORTED png_ptr->output_flush_fn = NULL; #endif } diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngrtran.c b/graf2d/asimage/src/libAfterImage/libpng/pngrtran.c index 1a428faf8a657..7f0ff92e07b98 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngrtran.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngrtran.c @@ -1,12 +1,15 @@ /* pngrtran.c - transforms the data in a row for PNG readers * - * Last changed in libpng 1.2.22 [November 6, 2007] - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * Last changed in libpng 1.2.49 [March 29, 2012] + * Copyright (c) 1998-2012 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h + * * This file contains functions optionally called by an application * in order to tell libpng how to handle data when reading a PNG. * Transformations that are used in both reading and writing are @@ -14,57 +17,71 @@ */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" - -#if defined(PNG_READ_SUPPORTED) +#ifdef PNG_READ_SUPPORTED /* Set the action on getting a CRC error for an ancillary or critical chunk. */ void PNGAPI png_set_crc_action(png_structp png_ptr, int crit_action, int ancil_action) { - png_debug(1, "in png_set_crc_action\n"); + png_debug(1, "in png_set_crc_action"); + + if (png_ptr == NULL) + return; + /* Tell libpng how we react to CRC errors in critical chunks */ - if(png_ptr == NULL) return; switch (crit_action) { - case PNG_CRC_NO_CHANGE: /* leave setting as is */ + case PNG_CRC_NO_CHANGE: /* Leave setting as is */ break; - case PNG_CRC_WARN_USE: /* warn/use data */ + + case PNG_CRC_WARN_USE: /* Warn/use data */ png_ptr->flags &= ~PNG_FLAG_CRC_CRITICAL_MASK; png_ptr->flags |= PNG_FLAG_CRC_CRITICAL_USE; break; - case PNG_CRC_QUIET_USE: /* quiet/use data */ + + case PNG_CRC_QUIET_USE: /* Quiet/use data */ png_ptr->flags &= ~PNG_FLAG_CRC_CRITICAL_MASK; png_ptr->flags |= PNG_FLAG_CRC_CRITICAL_USE | PNG_FLAG_CRC_CRITICAL_IGNORE; break; - case PNG_CRC_WARN_DISCARD: /* not a valid action for critical data */ - png_warning(png_ptr, "Can't discard critical data on CRC error."); - case PNG_CRC_ERROR_QUIT: /* error/quit */ + + case PNG_CRC_WARN_DISCARD: /* Not a valid action for critical data */ + png_warning(png_ptr, + "Can't discard critical data on CRC error."); + case PNG_CRC_ERROR_QUIT: /* Error/quit */ + case PNG_CRC_DEFAULT: default: png_ptr->flags &= ~PNG_FLAG_CRC_CRITICAL_MASK; break; } + /* Tell libpng how we react to CRC errors in ancillary chunks */ switch (ancil_action) { - case PNG_CRC_NO_CHANGE: /* leave setting as is */ + case PNG_CRC_NO_CHANGE: /* Leave setting as is */ break; - case PNG_CRC_WARN_USE: /* warn/use data */ + + case PNG_CRC_WARN_USE: /* Warn/use data */ png_ptr->flags &= ~PNG_FLAG_CRC_ANCILLARY_MASK; png_ptr->flags |= PNG_FLAG_CRC_ANCILLARY_USE; break; - case PNG_CRC_QUIET_USE: /* quiet/use data */ + + case PNG_CRC_QUIET_USE: /* Quiet/use data */ png_ptr->flags &= ~PNG_FLAG_CRC_ANCILLARY_MASK; png_ptr->flags |= PNG_FLAG_CRC_ANCILLARY_USE | PNG_FLAG_CRC_ANCILLARY_NOWARN; break; - case PNG_CRC_ERROR_QUIT: /* error/quit */ + + case PNG_CRC_ERROR_QUIT: /* Error/quit */ png_ptr->flags &= ~PNG_FLAG_CRC_ANCILLARY_MASK; png_ptr->flags |= PNG_FLAG_CRC_ANCILLARY_NOWARN; break; - case PNG_CRC_WARN_DISCARD: /* warn/discard data */ + + case PNG_CRC_WARN_DISCARD: /* Warn/discard data */ + case PNG_CRC_DEFAULT: default: png_ptr->flags &= ~PNG_FLAG_CRC_ANCILLARY_MASK; @@ -74,14 +91,16 @@ png_set_crc_action(png_structp png_ptr, int crit_action, int ancil_action) #if defined(PNG_READ_BACKGROUND_SUPPORTED) && \ defined(PNG_FLOATING_POINT_SUPPORTED) -/* handle alpha and tRNS via a background color */ +/* Handle alpha and tRNS via a background color */ void PNGAPI png_set_background(png_structp png_ptr, png_color_16p background_color, int background_gamma_code, int need_expand, double background_gamma) { - png_debug(1, "in png_set_background\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_background"); + + if (png_ptr == NULL) + return; if (background_gamma_code == PNG_BACKGROUND_GAMMA_UNKNOWN) { png_warning(png_ptr, "Application must supply a known background gamma"); @@ -97,28 +116,32 @@ png_set_background(png_structp png_ptr, } #endif -#if defined(PNG_READ_16_TO_8_SUPPORTED) -/* strip 16 bit depth files to 8 bit depth */ +#ifdef PNG_READ_16_TO_8_SUPPORTED +/* Strip 16 bit depth files to 8 bit depth */ void PNGAPI png_set_strip_16(png_structp png_ptr) { - png_debug(1, "in png_set_strip_16\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_strip_16"); + + if (png_ptr == NULL) + return; png_ptr->transformations |= PNG_16_TO_8; } #endif -#if defined(PNG_READ_STRIP_ALPHA_SUPPORTED) +#ifdef PNG_READ_STRIP_ALPHA_SUPPORTED void PNGAPI png_set_strip_alpha(png_structp png_ptr) { - png_debug(1, "in png_set_strip_alpha\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_strip_alpha"); + + if (png_ptr == NULL) + return; png_ptr->flags |= PNG_FLAG_STRIP_ALPHA; } #endif -#if defined(PNG_READ_DITHER_SUPPORTED) +#ifdef PNG_READ_DITHER_SUPPORTED /* Dither file to 8 bit. Supply a palette, the current number * of elements in the palette, the maximum number of elements * allowed, and a histogram if possible. If the current number @@ -142,8 +165,10 @@ png_set_dither(png_structp png_ptr, png_colorp palette, int num_palette, int maximum_colors, png_uint_16p histogram, int full_dither) { - png_debug(1, "in png_set_dither\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_dither"); + + if (png_ptr == NULL) + return; png_ptr->transformations |= PNG_DITHER; if (!full_dither) @@ -151,7 +176,7 @@ png_set_dither(png_structp png_ptr, png_colorp palette, int i; png_ptr->dither_index = (png_bytep)png_malloc(png_ptr, - (png_uint_32)(num_palette * png_sizeof (png_byte))); + (png_uint_32)(num_palette * png_sizeof(png_byte))); for (i = 0; i < num_palette; i++) png_ptr->dither_index[i] = (png_byte)i; } @@ -161,27 +186,29 @@ png_set_dither(png_structp png_ptr, png_colorp palette, if (histogram != NULL) { /* This is easy enough, just throw out the least used colors. - Perhaps not the best solution, but good enough. */ + * Perhaps not the best solution, but good enough. + */ int i; - /* initialize an array to sort colors */ + /* Initialize an array to sort colors */ png_ptr->dither_sort = (png_bytep)png_malloc(png_ptr, - (png_uint_32)(num_palette * png_sizeof (png_byte))); + (png_uint_32)(num_palette * png_sizeof(png_byte))); - /* initialize the dither_sort array */ + /* Initialize the dither_sort array */ for (i = 0; i < num_palette; i++) png_ptr->dither_sort[i] = (png_byte)i; /* Find the least used palette entries by starting a - bubble sort, and running it until we have sorted - out enough colors. Note that we don't care about - sorting all the colors, just finding which are - least used. */ + * bubble sort, and running it until we have sorted + * out enough colors. Note that we don't care about + * sorting all the colors, just finding which are + * least used. + */ for (i = num_palette - 1; i >= maximum_colors; i--) { - int done; /* to stop early if the list is pre-sorted */ + int done; /* To stop early if the list is pre-sorted */ int j; done = 1; @@ -202,13 +229,14 @@ png_set_dither(png_structp png_ptr, png_colorp palette, break; } - /* swap the palette around, and set up a table, if necessary */ + /* Swap the palette around, and set up a table, if necessary */ if (full_dither) { int j = num_palette; - /* put all the useful colors within the max, but don't - move the others */ + /* Put all the useful colors within the max, but don't + * move the others. + */ for (i = 0; i < maximum_colors; i++) { if ((int)png_ptr->dither_sort[i] >= maximum_colors) @@ -224,11 +252,12 @@ png_set_dither(png_structp png_ptr, png_colorp palette, { int j = num_palette; - /* move all the used colors inside the max limit, and - develop a translation table */ + /* Move all the used colors inside the max limit, and + * develop a translation table. + */ for (i = 0; i < maximum_colors; i++) { - /* only move the colors we need to */ + /* Only move the colors we need to */ if ((int)png_ptr->dither_sort[i] >= maximum_colors) { png_color tmp_color; @@ -240,20 +269,20 @@ png_set_dither(png_structp png_ptr, png_colorp palette, tmp_color = palette[j]; palette[j] = palette[i]; palette[i] = tmp_color; - /* indicate where the color went */ + /* Indicate where the color went */ png_ptr->dither_index[j] = (png_byte)i; png_ptr->dither_index[i] = (png_byte)j; } } - /* find closest color for those colors we are not using */ + /* Find closest color for those colors we are not using */ for (i = 0; i < num_palette; i++) { if ((int)png_ptr->dither_index[i] >= maximum_colors) { int min_d, k, min_k, d_index; - /* find the closest color to one we threw out */ + /* Find the closest color to one we threw out */ d_index = png_ptr->dither_index[i]; min_d = PNG_COLOR_DIST(palette[d_index], palette[0]); for (k = 1, min_k = 0; k < maximum_colors; k++) @@ -268,61 +297,58 @@ png_set_dither(png_structp png_ptr, png_colorp palette, min_k = k; } } - /* point to closest color */ + /* Point to closest color */ png_ptr->dither_index[i] = (png_byte)min_k; } } } png_free(png_ptr, png_ptr->dither_sort); - png_ptr->dither_sort=NULL; + png_ptr->dither_sort = NULL; } else { /* This is much harder to do simply (and quickly). Perhaps - we need to go through a median cut routine, but those - don't always behave themselves with only a few colors - as input. So we will just find the closest two colors, - and throw out one of them (chosen somewhat randomly). - [We don't understand this at all, so if someone wants to - work on improving it, be our guest - AED, GRP] - */ + * we need to go through a median cut routine, but those + * don't always behave themselves with only a few colors + * as input. So we will just find the closest two colors, + * and throw out one of them (chosen somewhat randomly). + * [We don't understand this at all, so if someone wants to + * work on improving it, be our guest - AED, GRP] + */ int i; int max_d; int num_new_palette; png_dsortp t; png_dsortpp hash; - t=NULL; + t = NULL; - /* initialize palette index arrays */ + /* Initialize palette index arrays */ png_ptr->index_to_palette = (png_bytep)png_malloc(png_ptr, - (png_uint_32)(num_palette * png_sizeof (png_byte))); + (png_uint_32)(num_palette * png_sizeof(png_byte))); png_ptr->palette_to_index = (png_bytep)png_malloc(png_ptr, - (png_uint_32)(num_palette * png_sizeof (png_byte))); + (png_uint_32)(num_palette * png_sizeof(png_byte))); - /* initialize the sort array */ + /* Initialize the sort array */ for (i = 0; i < num_palette; i++) { png_ptr->index_to_palette[i] = (png_byte)i; png_ptr->palette_to_index[i] = (png_byte)i; } - hash = (png_dsortpp)png_malloc(png_ptr, (png_uint_32)(769 * - png_sizeof (png_dsortp))); - for (i = 0; i < 769; i++) - hash[i] = NULL; -/* png_memset(hash, 0, 769 * png_sizeof (png_dsortp)); */ + hash = (png_dsortpp)png_calloc(png_ptr, (png_uint_32)(769 * + png_sizeof(png_dsortp))); num_new_palette = num_palette; - /* initial wild guess at how far apart the farthest pixel - pair we will be eliminating will be. Larger - numbers mean more areas will be allocated, Smaller - numbers run the risk of not saving enough data, and - having to do this all over again. - - I have not done extensive checking on this number. - */ + /* Initial wild guess at how far apart the farthest pixel + * pair we will be eliminating will be. Larger + * numbers mean more areas will be allocated, Smaller + * numbers run the risk of not saving enough data, and + * having to do this all over again. + * + * I have not done extensive checking on this number. + */ max_d = 96; while (num_new_palette > maximum_colors) @@ -406,8 +432,10 @@ png_set_dither(png_structp png_ptr, png_colorp palette, png_ptr->palette_to_index[png_ptr->index_to_palette[j]] = png_ptr->palette_to_index[num_new_palette]; - png_ptr->index_to_palette[j] = (png_byte)num_new_palette; - png_ptr->palette_to_index[num_new_palette] = (png_byte)j; + png_ptr->index_to_palette[j] = + (png_byte)num_new_palette; + png_ptr->palette_to_index[num_new_palette] = + (png_byte)j; } if (num_new_palette <= maximum_colors) break; @@ -436,8 +464,8 @@ png_set_dither(png_structp png_ptr, png_colorp palette, png_free(png_ptr, hash); png_free(png_ptr, png_ptr->palette_to_index); png_free(png_ptr, png_ptr->index_to_palette); - png_ptr->palette_to_index=NULL; - png_ptr->index_to_palette=NULL; + png_ptr->palette_to_index = NULL; + png_ptr->index_to_palette = NULL; } num_palette = maximum_colors; } @@ -458,15 +486,11 @@ png_set_dither(png_structp png_ptr, png_colorp palette, int num_blue = (1 << PNG_DITHER_BLUE_BITS); png_size_t num_entries = ((png_size_t)1 << total_bits); - png_ptr->palette_lookup = (png_bytep )png_malloc(png_ptr, - (png_uint_32)(num_entries * png_sizeof (png_byte))); - - png_memset(png_ptr->palette_lookup, 0, num_entries * - png_sizeof (png_byte)); + png_ptr->palette_lookup = (png_bytep )png_calloc(png_ptr, + (png_uint_32)(num_entries * png_sizeof(png_byte))); distance = (png_bytep)png_malloc(png_ptr, (png_uint_32)(num_entries * png_sizeof(png_byte))); - png_memset(distance, 0xff, num_entries * png_sizeof(png_byte)); for (i = 0; i < num_palette; i++) @@ -480,7 +504,8 @@ png_set_dither(png_structp png_ptr, png_colorp palette, { /* int dr = abs(ir - r); */ int dr = ((ir > r) ? ir - r : r - ir); - int index_r = (ir << (PNG_DITHER_BLUE_BITS + PNG_DITHER_GREEN_BITS)); + int index_r = (ir << (PNG_DITHER_BLUE_BITS + + PNG_DITHER_GREEN_BITS)); for (ig = 0; ig < num_green; ig++) { @@ -526,8 +551,11 @@ png_set_dither(png_structp png_ptr, png_colorp palette, void PNGAPI png_set_gamma(png_structp png_ptr, double scrn_gamma, double file_gamma) { - png_debug(1, "in png_set_gamma\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_gamma"); + + if (png_ptr == NULL) + return; + if ((fabs(scrn_gamma * file_gamma - 1.0) > PNG_GAMMA_THRESHOLD) || (png_ptr->color_type & PNG_COLOR_MASK_ALPHA) || (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE)) @@ -537,7 +565,7 @@ png_set_gamma(png_structp png_ptr, double scrn_gamma, double file_gamma) } #endif -#if defined(PNG_READ_EXPAND_SUPPORTED) +#ifdef PNG_READ_EXPAND_SUPPORTED /* Expand paletted images to RGB, expand grayscale images of * less than 8-bit depth to 8-bit depth, and expand tRNS chunks * to alpha channels. @@ -545,12 +573,13 @@ png_set_gamma(png_structp png_ptr, double scrn_gamma, double file_gamma) void PNGAPI png_set_expand(png_structp png_ptr) { - png_debug(1, "in png_set_expand\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_expand"); + + if (png_ptr == NULL) + return; + png_ptr->transformations |= (PNG_EXPAND | PNG_EXPAND_tRNS); -#ifdef PNG_WARN_UNINITIALIZED_ROW png_ptr->flags &= ~PNG_FLAG_ROW_INIT; -#endif } /* GRR 19990627: the following three functions currently are identical @@ -566,33 +595,36 @@ png_set_expand(png_structp png_ptr) * More to the point, these functions make it obvious what libpng will be * doing, whereas "expand" can (and does) mean any number of things. * - * GRP 20060307: In libpng-1.4.0, png_set_gray_1_2_4_to_8() was modified - * to expand only the sample depth but not to expand the tRNS to alpha. + * GRP 20060307: In libpng-1.2.9, png_set_gray_1_2_4_to_8() was modified + * to expand only the sample depth but not to expand the tRNS to alpha + * and its name was changed to png_set_expand_gray_1_2_4_to_8(). */ /* Expand paletted images to RGB. */ void PNGAPI png_set_palette_to_rgb(png_structp png_ptr) { - png_debug(1, "in png_set_palette_to_rgb\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_palette_to_rgb"); + + if (png_ptr == NULL) + return; + png_ptr->transformations |= (PNG_EXPAND | PNG_EXPAND_tRNS); -#ifdef PNG_WARN_UNINITIALIZED_ROW png_ptr->flags &= ~PNG_FLAG_ROW_INIT; -#endif } -#if !defined(PNG_1_0_X) +#ifndef PNG_1_0_X /* Expand grayscale images of less than 8-bit depth to 8 bits. */ void PNGAPI png_set_expand_gray_1_2_4_to_8(png_structp png_ptr) { - png_debug(1, "in png_set_expand_gray_1_2_4_to_8\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_expand_gray_1_2_4_to_8"); + + if (png_ptr == NULL) + return; + png_ptr->transformations |= PNG_EXPAND; -#ifdef PNG_WARN_UNINITIALIZED_ROW png_ptr->flags &= ~PNG_FLAG_ROW_INIT; -#endif } #endif @@ -602,8 +634,11 @@ png_set_expand_gray_1_2_4_to_8(png_structp png_ptr) void PNGAPI png_set_gray_1_2_4_to_8(png_structp png_ptr) { - png_debug(1, "in png_set_gray_1_2_4_to_8\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_gray_1_2_4_to_8"); + + if (png_ptr == NULL) + return; + png_ptr->transformations |= (PNG_EXPAND | PNG_EXPAND_tRNS); } #endif @@ -613,28 +648,26 @@ png_set_gray_1_2_4_to_8(png_structp png_ptr) void PNGAPI png_set_tRNS_to_alpha(png_structp png_ptr) { - png_debug(1, "in png_set_tRNS_to_alpha\n"); + png_debug(1, "in png_set_tRNS_to_alpha"); + png_ptr->transformations |= (PNG_EXPAND | PNG_EXPAND_tRNS); -#ifdef PNG_WARN_UNINITIALIZED_ROW png_ptr->flags &= ~PNG_FLAG_ROW_INIT; -#endif } #endif /* defined(PNG_READ_EXPAND_SUPPORTED) */ -#if defined(PNG_READ_GRAY_TO_RGB_SUPPORTED) +#ifdef PNG_READ_GRAY_TO_RGB_SUPPORTED void PNGAPI png_set_gray_to_rgb(png_structp png_ptr) { - png_debug(1, "in png_set_gray_to_rgb\n"); + png_debug(1, "in png_set_gray_to_rgb"); + png_ptr->transformations |= PNG_GRAY_TO_RGB; -#ifdef PNG_WARN_UNINITIALIZED_ROW png_ptr->flags &= ~PNG_FLAG_ROW_INIT; -#endif } #endif -#if defined(PNG_READ_RGB_TO_GRAY_SUPPORTED) -#if defined(PNG_FLOATING_POINT_SUPPORTED) +#ifdef PNG_READ_RGB_TO_GRAY_SUPPORTED +#ifdef PNG_FLOATING_POINT_SUPPORTED /* Convert a RGB image to a grayscale of the same width. This allows us, * for example, to convert a 24 bpp RGB image into an 8 bpp grayscale image. */ @@ -643,10 +676,22 @@ void PNGAPI png_set_rgb_to_gray(png_structp png_ptr, int error_action, double red, double green) { - int red_fixed = (int)((float)red*100000.0 + 0.5); - int green_fixed = (int)((float)green*100000.0 + 0.5); - if(png_ptr == NULL) return; - png_set_rgb_to_gray_fixed(png_ptr, error_action, red_fixed, green_fixed); + int red_fixed, green_fixed; + if (png_ptr == NULL) + return; + if (red > 21474.83647 || red < -21474.83648 || + green > 21474.83647 || green < -21474.83648) + { + png_warning(png_ptr, "ignoring out of range rgb_to_gray coefficients"); + red_fixed = -1; + green_fixed = -1; + } + else + { + red_fixed = (int)((float)red*100000.0 + 0.5); + green_fixed = (int)((float)green*100000.0 + 0.5); + } + png_set_rgb_to_gray_fixed(png_ptr, error_action, red_fixed, green_fixed); } #endif @@ -654,36 +699,42 @@ void PNGAPI png_set_rgb_to_gray_fixed(png_structp png_ptr, int error_action, png_fixed_point red, png_fixed_point green) { - png_debug(1, "in png_set_rgb_to_gray\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_rgb_to_gray"); + + if (png_ptr == NULL) + return; + switch(error_action) { case 1: png_ptr->transformations |= PNG_RGB_TO_GRAY; break; + case 2: png_ptr->transformations |= PNG_RGB_TO_GRAY_WARN; break; + case 3: png_ptr->transformations |= PNG_RGB_TO_GRAY_ERR; } if (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE) -#if defined(PNG_READ_EXPAND_SUPPORTED) +#ifdef PNG_READ_EXPAND_SUPPORTED png_ptr->transformations |= PNG_EXPAND; #else { - png_warning(png_ptr, "Cannot do RGB_TO_GRAY without EXPAND_SUPPORTED."); + png_warning(png_ptr, + "Cannot do RGB_TO_GRAY without EXPAND_SUPPORTED."); png_ptr->transformations &= ~PNG_RGB_TO_GRAY; } #endif { png_uint_16 red_int, green_int; - if(red < 0 || green < 0) + if (red < 0 || green < 0) { red_int = 6968; /* .212671 * 32768 + .5 */ green_int = 23434; /* .715160 * 32768 + .5 */ } - else if(red + green < 100000L) + else if (red + green < 100000L) { - red_int = (png_uint_16)(((png_uint_32)red*32768L)/100000L); - green_int = (png_uint_16)(((png_uint_32)green*32768L)/100000L); + red_int = (png_uint_16)(((png_uint_32)red*32768L)/100000L); + green_int = (png_uint_16)(((png_uint_32)green*32768L)/100000L); } else { @@ -693,26 +744,30 @@ png_set_rgb_to_gray_fixed(png_structp png_ptr, int error_action, } png_ptr->rgb_to_gray_red_coeff = red_int; png_ptr->rgb_to_gray_green_coeff = green_int; - png_ptr->rgb_to_gray_blue_coeff = (png_uint_16)(32768-red_int-green_int); + png_ptr->rgb_to_gray_blue_coeff = + (png_uint_16)(32768 - red_int - green_int); } } #endif #if defined(PNG_READ_USER_TRANSFORM_SUPPORTED) || \ - defined(PNG_WRITE_USER_TRANSFORM_SUPPORTED) || \ - defined(PNG_LEGACY_SUPPORTED) + defined(PNG_LEGACY_SUPPORTED) || \ + defined(PNG_WRITE_USER_TRANSFORM_SUPPORTED) void PNGAPI png_set_read_user_transform_fn(png_structp png_ptr, png_user_transform_ptr read_user_transform_fn) { - png_debug(1, "in png_set_read_user_transform_fn\n"); - if(png_ptr == NULL) return; -#if defined(PNG_READ_USER_TRANSFORM_SUPPORTED) + png_debug(1, "in png_set_read_user_transform_fn"); + + if (png_ptr == NULL) + return; + +#ifdef PNG_READ_USER_TRANSFORM_SUPPORTED png_ptr->transformations |= PNG_USER_TRANSFORM; png_ptr->read_user_transform_fn = read_user_transform_fn; #endif #ifdef PNG_LEGACY_SUPPORTED - if(read_user_transform_fn) + if (read_user_transform_fn) png_warning(png_ptr, "This version of libpng does not support user transforms"); #endif @@ -725,22 +780,25 @@ png_set_read_user_transform_fn(png_structp png_ptr, png_user_transform_ptr void /* PRIVATE */ png_init_read_transformations(png_structp png_ptr) { - png_debug(1, "in png_init_read_transformations\n"); -#if defined(PNG_USELESS_TESTS_SUPPORTED) - if(png_ptr != NULL) + png_debug(1, "in png_init_read_transformations"); + +#ifdef PNG_USELESS_TESTS_SUPPORTED + if (png_ptr != NULL) #endif { -#if defined(PNG_READ_BACKGROUND_SUPPORTED) || defined(PNG_READ_SHIFT_SUPPORTED) \ - || defined(PNG_READ_GAMMA_SUPPORTED) +#if defined(PNG_READ_BACKGROUND_SUPPORTED) || \ + defined(PNG_READ_SHIFT_SUPPORTED) || \ + defined(PNG_READ_GAMMA_SUPPORTED) int color_type = png_ptr->color_type; #endif #if defined(PNG_READ_EXPAND_SUPPORTED) && defined(PNG_READ_BACKGROUND_SUPPORTED) -#if defined(PNG_READ_GRAY_TO_RGB_SUPPORTED) +#ifdef PNG_READ_GRAY_TO_RGB_SUPPORTED /* Detect gray background and attempt to enable optimization - * for gray --> RGB case */ - /* Note: if PNG_BACKGROUND_EXPAND is set and color_type is either RGB or + * for gray --> RGB case + * + * Note: if PNG_BACKGROUND_EXPAND is set and color_type is either RGB or * RGB_ALPHA (in which case need_expand is superfluous anyway), the * background color might actually be gray yet not be flagged as such. * This is not a problem for the current code, which uses @@ -767,7 +825,7 @@ png_init_read_transformations(png_structp png_ptr) { if (!(color_type & PNG_COLOR_MASK_COLOR)) /* i.e., GRAY or GRAY_ALPHA */ { - /* expand background and tRNS chunks */ + /* Expand background and tRNS chunks */ switch (png_ptr->bit_depth) { case 1: @@ -781,6 +839,7 @@ png_init_read_transformations(png_structp png_ptr) = png_ptr->trans_values.blue = png_ptr->trans_values.gray; } break; + case 2: png_ptr->background.gray *= (png_uint_16)0x55; png_ptr->background.red = png_ptr->background.green @@ -792,6 +851,7 @@ png_init_read_transformations(png_structp png_ptr) = png_ptr->trans_values.blue = png_ptr->trans_values.gray; } break; + case 4: png_ptr->background.gray *= (png_uint_16)0x11; png_ptr->background.red = png_ptr->background.green @@ -803,7 +863,9 @@ png_init_read_transformations(png_structp png_ptr) = png_ptr->trans_values.blue = png_ptr->trans_values.gray; } break; + case 8: + case 16: png_ptr->background.red = png_ptr->background.green = png_ptr->background.blue = png_ptr->background.gray; @@ -819,16 +881,17 @@ png_init_read_transformations(png_structp png_ptr) png_ptr->background.blue = png_ptr->palette[png_ptr->background.index].blue; -#if defined(PNG_READ_INVERT_ALPHA_SUPPORTED) +#ifdef PNG_READ_INVERT_ALPHA_SUPPORTED if (png_ptr->transformations & PNG_INVERT_ALPHA) { -#if defined(PNG_READ_EXPAND_SUPPORTED) +#ifdef PNG_READ_EXPAND_SUPPORTED if (!(png_ptr->transformations & PNG_EXPAND_tRNS)) #endif { - /* invert the alpha channel (in tRNS) unless the pixels are - going to be expanded, in which case leave it for later */ - int i,istop; + /* Invert the alpha channel (in tRNS) unless the pixels are + * going to be expanded, in which case leave it for later + */ + int i, istop; istop=(int)png_ptr->num_trans; for (i=0; itrans[i] = (png_byte)(255 - png_ptr->trans[i]); @@ -849,12 +912,12 @@ png_init_read_transformations(png_structp png_ptr) && (fabs(png_ptr->screen_gamma * png_ptr->gamma - 1.0) < PNG_GAMMA_THRESHOLD)) { - int i,k; + int i, k; k=0; for (i=0; inum_trans; i++) { if (png_ptr->trans[i] != 0 && png_ptr->trans[i] != 0xff) - k=1; /* partial transparency is present */ + k=1; /* Partial transparency is present */ } if (k == 0) png_ptr->transformations &= ~PNG_GAMMA; @@ -864,13 +927,13 @@ png_init_read_transformations(png_structp png_ptr) png_ptr->gamma != 0.0) { png_build_gamma_table(png_ptr); -#if defined(PNG_READ_BACKGROUND_SUPPORTED) + +#ifdef PNG_READ_BACKGROUND_SUPPORTED if (png_ptr->transformations & PNG_BACKGROUND) { if (color_type == PNG_COLOR_TYPE_PALETTE) { - /* could skip if no transparency and - */ + /* Could skip if no transparency */ png_color back, back_1; png_colorp palette = png_ptr->palette; int num_palette = png_ptr->num_palette; @@ -895,10 +958,12 @@ png_init_read_transformations(png_structp png_ptr) g = (png_ptr->screen_gamma); gs = 1.0; break; + case PNG_BACKGROUND_GAMMA_FILE: g = 1.0 / (png_ptr->gamma); gs = 1.0 / (png_ptr->gamma * png_ptr->screen_gamma); break; + case PNG_BACKGROUND_GAMMA_UNIQUE: g = 1.0 / (png_ptr->background_gamma); gs = 1.0 / (png_ptr->background_gamma * @@ -920,7 +985,8 @@ png_init_read_transformations(png_structp png_ptr) back.red = (png_byte)(pow( (double)png_ptr->background.red/255, gs) * 255.0 + .5); back.green = (png_byte)(pow( - (double)png_ptr->background.green/255, gs) * 255.0 + .5); + (double)png_ptr->background.green/255, gs) * 255.0 + + .5); back.blue = (png_byte)(pow( (double)png_ptr->background.blue/255, gs) * 255.0 + .5); } @@ -964,6 +1030,14 @@ png_init_read_transformations(png_structp png_ptr) palette[i].blue = png_ptr->gamma_table[palette[i].blue]; } } + /* Prevent the transformations being done again, and make sure + * that the now spurious alpha channel is stripped - the code + * has just reduced background composition and gamma correction + * to a simple alpha channel strip. + */ + png_ptr->transformations &= ~PNG_BACKGROUND; + png_ptr->transformations &= ~PNG_GAMMA; + png_ptr->transformations |= PNG_STRIP_ALPHA; } /* if (png_ptr->background_gamma_type!=PNG_BACKGROUND_GAMMA_UNKNOWN) */ else @@ -979,10 +1053,12 @@ png_init_read_transformations(png_structp png_ptr) g = (png_ptr->screen_gamma); gs = 1.0; break; + case PNG_BACKGROUND_GAMMA_FILE: g = 1.0 / (png_ptr->gamma); gs = 1.0 / (png_ptr->gamma * png_ptr->screen_gamma); break; + case PNG_BACKGROUND_GAMMA_UNIQUE: g = 1.0 / (png_ptr->background_gamma); gs = 1.0 / (png_ptr->background_gamma * @@ -1024,7 +1100,7 @@ png_init_read_transformations(png_structp png_ptr) } } else - /* transformation does not include PNG_BACKGROUND */ + /* Transformation does not include PNG_BACKGROUND */ #endif /* PNG_READ_BACKGROUND_SUPPORTED */ if (color_type == PNG_COLOR_TYPE_PALETTE) { @@ -1038,13 +1114,16 @@ png_init_read_transformations(png_structp png_ptr) palette[i].green = png_ptr->gamma_table[palette[i].green]; palette[i].blue = png_ptr->gamma_table[palette[i].blue]; } + + /* Done the gamma correction. */ + png_ptr->transformations &= ~PNG_GAMMA; } } -#if defined(PNG_READ_BACKGROUND_SUPPORTED) +#ifdef PNG_READ_BACKGROUND_SUPPORTED else #endif #endif /* PNG_READ_GAMMA_SUPPORTED && PNG_FLOATING_POINT_SUPPORTED */ -#if defined(PNG_READ_BACKGROUND_SUPPORTED) +#ifdef PNG_READ_BACKGROUND_SUPPORTED /* No GAMMA transformation */ if ((png_ptr->transformations & PNG_BACKGROUND) && (color_type == PNG_COLOR_TYPE_PALETTE)) @@ -1075,11 +1154,16 @@ png_init_read_transformations(png_structp png_ptr) png_ptr->trans[i], back.blue); } } + + /* Handled alpha, still need to strip the channel. */ + png_ptr->transformations &= ~PNG_BACKGROUND; + png_ptr->transformations |= PNG_STRIP_ALPHA; } #endif /* PNG_READ_BACKGROUND_SUPPORTED */ -#if defined(PNG_READ_SHIFT_SUPPORTED) +#ifdef PNG_READ_SHIFT_SUPPORTED if ((png_ptr->transformations & PNG_SHIFT) && + !(png_ptr->transformations & PNG_EXPAND) && (color_type == PNG_COLOR_TYPE_PALETTE)) { png_uint_16 i; @@ -1100,12 +1184,14 @@ png_init_read_transformations(png_structp png_ptr) png_ptr->palette[i].green >>= sg; png_ptr->palette[i].blue >>= sb; } + + png_ptr->transformations &= ~PNG_SHIFT; } #endif /* PNG_READ_SHIFT_SUPPORTED */ } #if !defined(PNG_READ_GAMMA_SUPPORTED) && !defined(PNG_READ_SHIFT_SUPPORTED) \ && !defined(PNG_READ_BACKGROUND_SUPPORTED) - if(png_ptr) + if (png_ptr) return; #endif } @@ -1117,13 +1203,14 @@ png_init_read_transformations(png_structp png_ptr) void /* PRIVATE */ png_read_transform_info(png_structp png_ptr, png_infop info_ptr) { - png_debug(1, "in png_read_transform_info\n"); -#if defined(PNG_READ_EXPAND_SUPPORTED) + png_debug(1, "in png_read_transform_info"); + +#ifdef PNG_READ_EXPAND_SUPPORTED if (png_ptr->transformations & PNG_EXPAND) { if (info_ptr->color_type == PNG_COLOR_TYPE_PALETTE) { - if (png_ptr->num_trans && (png_ptr->transformations & PNG_EXPAND_tRNS)) + if (png_ptr->num_trans) info_ptr->color_type = PNG_COLOR_TYPE_RGB_ALPHA; else info_ptr->color_type = PNG_COLOR_TYPE_RGB; @@ -1136,8 +1223,6 @@ png_read_transform_info(png_structp png_ptr, png_infop info_ptr) { if (png_ptr->transformations & PNG_EXPAND_tRNS) info_ptr->color_type |= PNG_COLOR_MASK_ALPHA; - else - info_ptr->color_type |= PNG_COLOR_MASK_COLOR; } if (info_ptr->bit_depth < 8) info_ptr->bit_depth = 8; @@ -1146,7 +1231,7 @@ png_read_transform_info(png_structp png_ptr, png_infop info_ptr) } #endif -#if defined(PNG_READ_BACKGROUND_SUPPORTED) +#ifdef PNG_READ_BACKGROUND_SUPPORTED if (png_ptr->transformations & PNG_BACKGROUND) { info_ptr->color_type &= ~PNG_COLOR_MASK_ALPHA; @@ -1155,7 +1240,7 @@ png_read_transform_info(png_structp png_ptr, png_infop info_ptr) } #endif -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (png_ptr->transformations & PNG_GAMMA) { #ifdef PNG_FLOATING_POINT_SUPPORTED @@ -1167,34 +1252,34 @@ png_read_transform_info(png_structp png_ptr, png_infop info_ptr) } #endif -#if defined(PNG_READ_16_TO_8_SUPPORTED) +#ifdef PNG_READ_16_TO_8_SUPPORTED if ((png_ptr->transformations & PNG_16_TO_8) && (info_ptr->bit_depth == 16)) info_ptr->bit_depth = 8; #endif -#if defined(PNG_READ_GRAY_TO_RGB_SUPPORTED) +#ifdef PNG_READ_GRAY_TO_RGB_SUPPORTED if (png_ptr->transformations & PNG_GRAY_TO_RGB) info_ptr->color_type |= PNG_COLOR_MASK_COLOR; #endif -#if defined(PNG_READ_RGB_TO_GRAY_SUPPORTED) +#ifdef PNG_READ_RGB_TO_GRAY_SUPPORTED if (png_ptr->transformations & PNG_RGB_TO_GRAY) info_ptr->color_type &= ~PNG_COLOR_MASK_COLOR; #endif -#if defined(PNG_READ_DITHER_SUPPORTED) +#ifdef PNG_READ_DITHER_SUPPORTED if (png_ptr->transformations & PNG_DITHER) { if (((info_ptr->color_type == PNG_COLOR_TYPE_RGB) || - (info_ptr->color_type == PNG_COLOR_TYPE_RGB_ALPHA)) && - png_ptr->palette_lookup && info_ptr->bit_depth == 8) + (info_ptr->color_type == PNG_COLOR_TYPE_RGB_ALPHA)) && + png_ptr->palette_lookup && info_ptr->bit_depth == 8) { info_ptr->color_type = PNG_COLOR_TYPE_PALETTE; } } #endif -#if defined(PNG_READ_PACK_SUPPORTED) +#ifdef PNG_READ_PACK_SUPPORTED if ((png_ptr->transformations & PNG_PACK) && (info_ptr->bit_depth < 8)) info_ptr->bit_depth = 8; #endif @@ -1206,7 +1291,7 @@ png_read_transform_info(png_structp png_ptr, png_infop info_ptr) else info_ptr->channels = 1; -#if defined(PNG_READ_STRIP_ALPHA_SUPPORTED) +#ifdef PNG_READ_STRIP_ALPHA_SUPPORTED if (png_ptr->flags & PNG_FLAG_STRIP_ALPHA) info_ptr->color_type &= ~PNG_COLOR_MASK_ALPHA; #endif @@ -1214,15 +1299,15 @@ png_read_transform_info(png_structp png_ptr, png_infop info_ptr) if (info_ptr->color_type & PNG_COLOR_MASK_ALPHA) info_ptr->channels++; -#if defined(PNG_READ_FILLER_SUPPORTED) +#ifdef PNG_READ_FILLER_SUPPORTED /* STRIP_ALPHA and FILLER allowed: MASK_ALPHA bit stripped above */ if ((png_ptr->transformations & PNG_FILLER) && ((info_ptr->color_type == PNG_COLOR_TYPE_RGB) || (info_ptr->color_type == PNG_COLOR_TYPE_GRAY))) { info_ptr->channels++; - /* if adding a true alpha channel not just filler */ -#if !defined(PNG_1_0_X) + /* If adding a true alpha channel not just filler */ +#ifndef PNG_1_0_X if (png_ptr->transformations & PNG_ADD_ALPHA) info_ptr->color_type |= PNG_COLOR_MASK_ALPHA; #endif @@ -1231,11 +1316,11 @@ png_read_transform_info(png_structp png_ptr, png_infop info_ptr) #if defined(PNG_USER_TRANSFORM_PTR_SUPPORTED) && \ defined(PNG_READ_USER_TRANSFORM_SUPPORTED) - if(png_ptr->transformations & PNG_USER_TRANSFORM) + if (png_ptr->transformations & PNG_USER_TRANSFORM) { - if(info_ptr->bit_depth < png_ptr->user_transform_depth) + if (info_ptr->bit_depth < png_ptr->user_transform_depth) info_ptr->bit_depth = png_ptr->user_transform_depth; - if(info_ptr->channels < png_ptr->user_transform_channels) + if (info_ptr->channels < png_ptr->user_transform_channels) info_ptr->channels = png_ptr->user_transform_channels; } #endif @@ -1243,10 +1328,10 @@ defined(PNG_READ_USER_TRANSFORM_SUPPORTED) info_ptr->pixel_depth = (png_byte)(info_ptr->channels * info_ptr->bit_depth); - info_ptr->rowbytes = PNG_ROWBYTES(info_ptr->pixel_depth,info_ptr->width); + info_ptr->rowbytes = PNG_ROWBYTES(info_ptr->pixel_depth, info_ptr->width); -#if !defined(PNG_READ_EXPAND_SUPPORTED) - if(png_ptr) +#ifndef PNG_READ_EXPAND_SUPPORTED + if (png_ptr) return; #endif } @@ -1258,14 +1343,15 @@ defined(PNG_READ_USER_TRANSFORM_SUPPORTED) void /* PRIVATE */ png_do_read_transformations(png_structp png_ptr) { - png_debug(1, "in png_do_read_transformations\n"); + png_debug(1, "in png_do_read_transformations"); + if (png_ptr->row_buf == NULL) { -#if !defined(PNG_NO_STDIO) && !defined(_WIN32_WCE) +#if defined(PNG_STDIO_SUPPORTED) && !defined(_WIN32_WCE) char msg[50]; png_snprintf2(msg, 50, - "NULL row buffer for row %ld, pass %d", png_ptr->row_number, + "NULL row buffer for row %ld, pass %d", (long)png_ptr->row_number, png_ptr->pass); png_error(png_ptr, msg); #else @@ -1276,7 +1362,8 @@ png_do_read_transformations(png_structp png_ptr) if (!(png_ptr->flags & PNG_FLAG_ROW_INIT)) /* Application has failed to call either png_read_start_image() * or png_read_update_info() after setting transforms that expand - * pixels. This check added to libpng-1.2.19 */ + * pixels. This check added to libpng-1.2.19 + */ #if (PNG_WARN_UNINITIALIZED_ROW==1) png_error(png_ptr, "Uninitialized row"); #else @@ -1284,7 +1371,7 @@ png_do_read_transformations(png_structp png_ptr) #endif #endif -#if defined(PNG_READ_EXPAND_SUPPORTED) +#ifdef PNG_READ_EXPAND_SUPPORTED if (png_ptr->transformations & PNG_EXPAND) { if (png_ptr->row_info.color_type == PNG_COLOR_TYPE_PALETTE) @@ -1305,75 +1392,78 @@ png_do_read_transformations(png_structp png_ptr) } #endif -#if defined(PNG_READ_STRIP_ALPHA_SUPPORTED) +#ifdef PNG_READ_STRIP_ALPHA_SUPPORTED if (png_ptr->flags & PNG_FLAG_STRIP_ALPHA) png_do_strip_filler(&(png_ptr->row_info), png_ptr->row_buf + 1, PNG_FLAG_FILLER_AFTER | (png_ptr->flags & PNG_FLAG_STRIP_ALPHA)); #endif -#if defined(PNG_READ_RGB_TO_GRAY_SUPPORTED) +#ifdef PNG_READ_RGB_TO_GRAY_SUPPORTED if (png_ptr->transformations & PNG_RGB_TO_GRAY) { int rgb_error = - png_do_rgb_to_gray(png_ptr, &(png_ptr->row_info), png_ptr->row_buf + 1); - if(rgb_error) + png_do_rgb_to_gray(png_ptr, &(png_ptr->row_info), + png_ptr->row_buf + 1); + if (rgb_error) { png_ptr->rgb_to_gray_status=1; - if((png_ptr->transformations & PNG_RGB_TO_GRAY) == + if ((png_ptr->transformations & PNG_RGB_TO_GRAY) == PNG_RGB_TO_GRAY_WARN) png_warning(png_ptr, "png_do_rgb_to_gray found nongray pixel"); - if((png_ptr->transformations & PNG_RGB_TO_GRAY) == + if ((png_ptr->transformations & PNG_RGB_TO_GRAY) == PNG_RGB_TO_GRAY_ERR) png_error(png_ptr, "png_do_rgb_to_gray found nongray pixel"); } } #endif -/* -From Andreas Dilger e-mail to png-implement, 26 March 1998: - - In most cases, the "simple transparency" should be done prior to doing - gray-to-RGB, or you will have to test 3x as many bytes to check if a - pixel is transparent. You would also need to make sure that the - transparency information is upgraded to RGB. - - To summarize, the current flow is: - - Gray + simple transparency -> compare 1 or 2 gray bytes and composite - with background "in place" if transparent, - convert to RGB if necessary - - Gray + alpha -> composite with gray background and remove alpha bytes, - convert to RGB if necessary - - To support RGB backgrounds for gray images we need: - - Gray + simple transparency -> convert to RGB + simple transparency, compare - 3 or 6 bytes and composite with background - "in place" if transparent (3x compare/pixel - compared to doing composite with gray bkgrnd) - - Gray + alpha -> convert to RGB + alpha, composite with background and - remove alpha bytes (3x float operations/pixel - compared with composite on gray background) - - Greg's change will do this. The reason it wasn't done before is for - performance, as this increases the per-pixel operations. If we would check - in advance if the background was gray or RGB, and position the gray-to-RGB - transform appropriately, then it would save a lot of work/time. +/* From Andreas Dilger e-mail to png-implement, 26 March 1998: + * + * In most cases, the "simple transparency" should be done prior to doing + * gray-to-RGB, or you will have to test 3x as many bytes to check if a + * pixel is transparent. You would also need to make sure that the + * transparency information is upgraded to RGB. + * + * To summarize, the current flow is: + * - Gray + simple transparency -> compare 1 or 2 gray bytes and composite + * with background "in place" if transparent, + * convert to RGB if necessary + * - Gray + alpha -> composite with gray background and remove alpha bytes, + * convert to RGB if necessary + * + * To support RGB backgrounds for gray images we need: + * - Gray + simple transparency -> convert to RGB + simple transparency, + * compare 3 or 6 bytes and composite with + * background "in place" if transparent + * (3x compare/pixel compared to doing + * composite with gray bkgrnd) + * - Gray + alpha -> convert to RGB + alpha, composite with background and + * remove alpha bytes (3x float + * operations/pixel compared with composite + * on gray background) + * + * Greg's change will do this. The reason it wasn't done before is for + * performance, as this increases the per-pixel operations. If we would check + * in advance if the background was gray or RGB, and position the gray-to-RGB + * transform appropriately, then it would save a lot of work/time. */ -#if defined(PNG_READ_GRAY_TO_RGB_SUPPORTED) - /* if gray -> RGB, do so now only if background is non-gray; else do later - * for performance reasons */ +#ifdef PNG_READ_GRAY_TO_RGB_SUPPORTED + /* If gray -> RGB, do so now only if background is non-gray; else do later + * for performance reasons + */ if ((png_ptr->transformations & PNG_GRAY_TO_RGB) && !(png_ptr->mode & PNG_BACKGROUND_IS_GRAY)) png_do_gray_to_rgb(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_READ_BACKGROUND_SUPPORTED) +#ifdef PNG_READ_BACKGROUND_SUPPORTED if ((png_ptr->transformations & PNG_BACKGROUND) && ((png_ptr->num_trans != 0 ) || (png_ptr->color_type & PNG_COLOR_MASK_ALPHA))) png_do_background(&(png_ptr->row_info), png_ptr->row_buf + 1, &(png_ptr->trans_values), &(png_ptr->background) -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED , &(png_ptr->background_1), png_ptr->gamma_table, png_ptr->gamma_from_1, png_ptr->gamma_to_1, png_ptr->gamma_16_table, @@ -1383,106 +1473,106 @@ From Andreas Dilger e-mail to png-implement, 26 March 1998: ); #endif -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if ((png_ptr->transformations & PNG_GAMMA) && -#if defined(PNG_READ_BACKGROUND_SUPPORTED) - !((png_ptr->transformations & PNG_BACKGROUND) && - ((png_ptr->num_trans != 0) || - (png_ptr->color_type & PNG_COLOR_MASK_ALPHA))) && +#ifdef PNG_READ_BACKGROUND_SUPPORTED + !((png_ptr->transformations & PNG_BACKGROUND) && + ((png_ptr->num_trans != 0) || + (png_ptr->color_type & PNG_COLOR_MASK_ALPHA))) && #endif - (png_ptr->color_type != PNG_COLOR_TYPE_PALETTE)) + (png_ptr->color_type != PNG_COLOR_TYPE_PALETTE)) png_do_gamma(&(png_ptr->row_info), png_ptr->row_buf + 1, - png_ptr->gamma_table, png_ptr->gamma_16_table, - png_ptr->gamma_shift); + png_ptr->gamma_table, png_ptr->gamma_16_table, + png_ptr->gamma_shift); #endif -#if defined(PNG_READ_16_TO_8_SUPPORTED) +#ifdef PNG_READ_16_TO_8_SUPPORTED if (png_ptr->transformations & PNG_16_TO_8) png_do_chop(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_READ_DITHER_SUPPORTED) +#ifdef PNG_READ_DITHER_SUPPORTED if (png_ptr->transformations & PNG_DITHER) { png_do_dither((png_row_infop)&(png_ptr->row_info), png_ptr->row_buf + 1, png_ptr->palette_lookup, png_ptr->dither_index); - if(png_ptr->row_info.rowbytes == (png_uint_32)0) + if (png_ptr->row_info.rowbytes == (png_uint_32)0) png_error(png_ptr, "png_do_dither returned rowbytes=0"); } #endif -#if defined(PNG_READ_INVERT_SUPPORTED) +#ifdef PNG_READ_INVERT_SUPPORTED if (png_ptr->transformations & PNG_INVERT_MONO) png_do_invert(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_READ_SHIFT_SUPPORTED) +#ifdef PNG_READ_SHIFT_SUPPORTED if (png_ptr->transformations & PNG_SHIFT) png_do_unshift(&(png_ptr->row_info), png_ptr->row_buf + 1, &(png_ptr->shift)); #endif -#if defined(PNG_READ_PACK_SUPPORTED) +#ifdef PNG_READ_PACK_SUPPORTED if (png_ptr->transformations & PNG_PACK) png_do_unpack(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_READ_BGR_SUPPORTED) +#ifdef PNG_READ_BGR_SUPPORTED if (png_ptr->transformations & PNG_BGR) png_do_bgr(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_READ_PACKSWAP_SUPPORTED) +#ifdef PNG_READ_PACKSWAP_SUPPORTED if (png_ptr->transformations & PNG_PACKSWAP) png_do_packswap(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_READ_GRAY_TO_RGB_SUPPORTED) - /* if gray -> RGB, do so now only if we did not do so above */ +#ifdef PNG_READ_GRAY_TO_RGB_SUPPORTED + /* If gray -> RGB, do so now only if we did not do so above */ if ((png_ptr->transformations & PNG_GRAY_TO_RGB) && (png_ptr->mode & PNG_BACKGROUND_IS_GRAY)) png_do_gray_to_rgb(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_READ_FILLER_SUPPORTED) +#ifdef PNG_READ_FILLER_SUPPORTED if (png_ptr->transformations & PNG_FILLER) png_do_read_filler(&(png_ptr->row_info), png_ptr->row_buf + 1, (png_uint_32)png_ptr->filler, png_ptr->flags); #endif -#if defined(PNG_READ_INVERT_ALPHA_SUPPORTED) +#ifdef PNG_READ_INVERT_ALPHA_SUPPORTED if (png_ptr->transformations & PNG_INVERT_ALPHA) png_do_read_invert_alpha(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_READ_SWAP_ALPHA_SUPPORTED) +#ifdef PNG_READ_SWAP_ALPHA_SUPPORTED if (png_ptr->transformations & PNG_SWAP_ALPHA) png_do_read_swap_alpha(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_READ_SWAP_SUPPORTED) +#ifdef PNG_READ_SWAP_SUPPORTED if (png_ptr->transformations & PNG_SWAP_BYTES) png_do_swap(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_READ_USER_TRANSFORM_SUPPORTED) +#ifdef PNG_READ_USER_TRANSFORM_SUPPORTED if (png_ptr->transformations & PNG_USER_TRANSFORM) { - if(png_ptr->read_user_transform_fn != NULL) - (*(png_ptr->read_user_transform_fn)) /* user read transform function */ - (png_ptr, /* png_ptr */ - &(png_ptr->row_info), /* row_info: */ - /* png_uint_32 width; width of row */ - /* png_uint_32 rowbytes; number of bytes in row */ - /* png_byte color_type; color type of pixels */ - /* png_byte bit_depth; bit depth of samples */ - /* png_byte channels; number of channels (1-4) */ - /* png_byte pixel_depth; bits per pixel (depth*channels) */ - png_ptr->row_buf + 1); /* start of pixel data for row */ -#if defined(PNG_USER_TRANSFORM_PTR_SUPPORTED) - if(png_ptr->user_transform_depth) + if (png_ptr->read_user_transform_fn != NULL) + (*(png_ptr->read_user_transform_fn)) /* User read transform function */ + (png_ptr, /* png_ptr */ + &(png_ptr->row_info), /* row_info: */ + /* png_uint_32 width; width of row */ + /* png_uint_32 rowbytes; number of bytes in row */ + /* png_byte color_type; color type of pixels */ + /* png_byte bit_depth; bit depth of samples */ + /* png_byte channels; number of channels (1-4) */ + /* png_byte pixel_depth; bits per pixel (depth*channels) */ + png_ptr->row_buf + 1); /* start of pixel data for row */ +#ifdef PNG_USER_TRANSFORM_PTR_SUPPORTED + if (png_ptr->user_transform_depth) png_ptr->row_info.bit_depth = png_ptr->user_transform_depth; - if(png_ptr->user_transform_channels) + if (png_ptr->user_transform_channels) png_ptr->row_info.channels = png_ptr->user_transform_channels; #endif png_ptr->row_info.pixel_depth = (png_byte)(png_ptr->row_info.bit_depth * @@ -1494,7 +1584,7 @@ From Andreas Dilger e-mail to png-implement, 26 March 1998: } -#if defined(PNG_READ_PACK_SUPPORTED) +#ifdef PNG_READ_PACK_SUPPORTED /* Unpack pixels of 1, 2, or 4 bits per pixel into 1 byte per pixel, * without changing the actual values. Thus, if you had a row with * a bit depth of 1, you would end up with bytes that only contained @@ -1504,8 +1594,9 @@ From Andreas Dilger e-mail to png-implement, 26 March 1998: void /* PRIVATE */ png_do_unpack(png_row_infop row_info, png_bytep row) { - png_debug(1, "in png_do_unpack\n"); -#if defined(PNG_USELESS_TESTS_SUPPORTED) + png_debug(1, "in png_do_unpack"); + +#ifdef PNG_USELESS_TESTS_SUPPORTED if (row != NULL && row_info != NULL && row_info->bit_depth < 8) #else if (row_info->bit_depth < 8) @@ -1536,6 +1627,7 @@ png_do_unpack(png_row_infop row_info, png_bytep row) } break; } + case 2: { @@ -1557,6 +1649,7 @@ png_do_unpack(png_row_infop row_info, png_bytep row) } break; } + case 4: { png_bytep sp = row + (png_size_t)((row_width - 1) >> 1); @@ -1585,7 +1678,7 @@ png_do_unpack(png_row_infop row_info, png_bytep row) } #endif -#if defined(PNG_READ_SHIFT_SUPPORTED) +#ifdef PNG_READ_SHIFT_SUPPORTED /* Reverse the effects of png_do_shift. This routine merely shifts the * pixels back to their significant bits values. Thus, if you have * a row of bit depth 8, but only 5 are significant, this will shift @@ -1594,9 +1687,10 @@ png_do_unpack(png_row_infop row_info, png_bytep row) void /* PRIVATE */ png_do_unshift(png_row_infop row_info, png_bytep row, png_color_8p sig_bits) { - png_debug(1, "in png_do_unshift\n"); + png_debug(1, "in png_do_unshift"); + if ( -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && sig_bits != NULL && #endif row_info->color_type != PNG_COLOR_TYPE_PALETTE) @@ -1648,6 +1742,7 @@ png_do_unshift(png_row_infop row_info, png_bytep row, png_color_8p sig_bits) } break; } + case 4: { png_bytep bp = row; @@ -1663,6 +1758,7 @@ png_do_unshift(png_row_infop row_info, png_bytep row, png_color_8p sig_bits) } break; } + case 8: { png_bytep bp = row; @@ -1675,6 +1771,7 @@ png_do_unshift(png_row_infop row_info, png_bytep row, png_color_8p sig_bits) } break; } + case 16: { png_bytep bp = row; @@ -1695,13 +1792,14 @@ png_do_unshift(png_row_infop row_info, png_bytep row, png_color_8p sig_bits) } #endif -#if defined(PNG_READ_16_TO_8_SUPPORTED) -/* chop rows of bit depth 16 down to 8 */ +#ifdef PNG_READ_16_TO_8_SUPPORTED +/* Chop rows of bit depth 16 down to 8 */ void /* PRIVATE */ png_do_chop(png_row_infop row_info, png_bytep row) { - png_debug(1, "in png_do_chop\n"); -#if defined(PNG_USELESS_TESTS_SUPPORTED) + png_debug(1, "in png_do_chop"); + +#ifdef PNG_USELESS_TESTS_SUPPORTED if (row != NULL && row_info != NULL && row_info->bit_depth == 16) #else if (row_info->bit_depth == 16) @@ -1714,20 +1812,23 @@ png_do_chop(png_row_infop row_info, png_bytep row) for (i = 0; i> 8)) >> 8; * * Approximate calculation with shift/add instead of multiply/divide: @@ -1750,12 +1851,13 @@ png_do_chop(png_row_infop row_info, png_bytep row) } #endif -#if defined(PNG_READ_SWAP_ALPHA_SUPPORTED) +#ifdef PNG_READ_SWAP_ALPHA_SUPPORTED void /* PRIVATE */ png_do_read_swap_alpha(png_row_infop row_info, png_bytep row) { - png_debug(1, "in png_do_read_swap_alpha\n"); -#if defined(PNG_USELESS_TESTS_SUPPORTED) + png_debug(1, "in png_do_read_swap_alpha"); + +#ifdef PNG_USELESS_TESTS_SUPPORTED if (row != NULL && row_info != NULL) #endif { @@ -1842,12 +1944,13 @@ png_do_read_swap_alpha(png_row_infop row_info, png_bytep row) } #endif -#if defined(PNG_READ_INVERT_ALPHA_SUPPORTED) +#ifdef PNG_READ_INVERT_ALPHA_SUPPORTED void /* PRIVATE */ png_do_read_invert_alpha(png_row_infop row_info, png_bytep row) { - png_debug(1, "in png_do_read_invert_alpha\n"); -#if defined(PNG_USELESS_TESTS_SUPPORTED) + png_debug(1, "in png_do_read_invert_alpha"); + +#ifdef PNG_USELESS_TESTS_SUPPORTED if (row != NULL && row_info != NULL) #endif { @@ -1940,7 +2043,7 @@ png_do_read_invert_alpha(png_row_infop row_info, png_bytep row) } #endif -#if defined(PNG_READ_FILLER_SUPPORTED) +#ifdef PNG_READ_FILLER_SUPPORTED /* Add filler channel if we have RGB color */ void /* PRIVATE */ png_do_read_filler(png_row_infop row_info, png_bytep row, @@ -1952,14 +2055,15 @@ png_do_read_filler(png_row_infop row_info, png_bytep row, png_byte hi_filler = (png_byte)((filler>>8) & 0xff); png_byte lo_filler = (png_byte)(filler & 0xff); - png_debug(1, "in png_do_read_filler\n"); + png_debug(1, "in png_do_read_filler"); + if ( -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && #endif row_info->color_type == PNG_COLOR_TYPE_GRAY) { - if(row_info->bit_depth == 8) + if (row_info->bit_depth == 8) { /* This changes the data from G to GX */ if (flags & PNG_FLAG_FILLER_AFTER) @@ -1991,7 +2095,7 @@ png_do_read_filler(png_row_infop row_info, png_bytep row, row_info->rowbytes = row_width * 2; } } - else if(row_info->bit_depth == 16) + else if (row_info->bit_depth == 16) { /* This changes the data from GG to GGXX */ if (flags & PNG_FLAG_FILLER_AFTER) @@ -2031,7 +2135,7 @@ png_do_read_filler(png_row_infop row_info, png_bytep row, } /* COLOR_TYPE == GRAY */ else if (row_info->color_type == PNG_COLOR_TYPE_RGB) { - if(row_info->bit_depth == 8) + if (row_info->bit_depth == 8) { /* This changes the data from RGB to RGBX */ if (flags & PNG_FLAG_FILLER_AFTER) @@ -2067,7 +2171,7 @@ png_do_read_filler(png_row_infop row_info, png_bytep row, row_info->rowbytes = row_width * 4; } } - else if(row_info->bit_depth == 16) + else if (row_info->bit_depth == 16) { /* This changes the data from RRGGBB to RRGGBBXX */ if (flags & PNG_FLAG_FILLER_AFTER) @@ -2116,17 +2220,18 @@ png_do_read_filler(png_row_infop row_info, png_bytep row, } #endif -#if defined(PNG_READ_GRAY_TO_RGB_SUPPORTED) -/* expand grayscale files to RGB, with or without alpha */ +#ifdef PNG_READ_GRAY_TO_RGB_SUPPORTED +/* Expand grayscale files to RGB, with or without alpha */ void /* PRIVATE */ png_do_gray_to_rgb(png_row_infop row_info, png_bytep row) { png_uint_32 i; png_uint_32 row_width = row_info->width; - png_debug(1, "in png_do_gray_to_rgb\n"); + png_debug(1, "in png_do_gray_to_rgb"); + if (row_info->bit_depth >= 8 && -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && #endif !(row_info->color_type & PNG_COLOR_MASK_COLOR)) @@ -2194,16 +2299,18 @@ png_do_gray_to_rgb(png_row_infop row_info, png_bytep row) row_info->color_type |= PNG_COLOR_MASK_COLOR; row_info->pixel_depth = (png_byte)(row_info->channels * row_info->bit_depth); - row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth,row_width); + row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth, row_width); } } #endif -#if defined(PNG_READ_RGB_TO_GRAY_SUPPORTED) -/* reduce RGB files to grayscale, with or without alpha +#ifdef PNG_READ_RGB_TO_GRAY_SUPPORTED +/* Reduce RGB files to grayscale, with or without alpha * using the equation given in Poynton's ColorFAQ at - * - * Copyright (c) 1998-01-04 Charles Poynton poynton at inforamp.net + * (THIS LINK IS DEAD June 2008) + * New link: + * + * Charles Poynton poynton at poynton.com * * Y = 0.212671 * R + 0.715160 * G + 0.072169 * B * @@ -2228,9 +2335,10 @@ png_do_rgb_to_gray(png_structp png_ptr, png_row_infop row_info, png_bytep row) png_uint_32 row_width = row_info->width; int rgb_error = 0; - png_debug(1, "in png_do_rgb_to_gray\n"); + png_debug(1, "in png_do_rgb_to_gray"); + if ( -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && #endif (row_info->color_type & PNG_COLOR_MASK_COLOR)) @@ -2254,14 +2362,14 @@ png_do_rgb_to_gray(png_structp png_ptr, png_row_infop row_info, png_bytep row) png_byte red = png_ptr->gamma_to_1[*(sp++)]; png_byte green = png_ptr->gamma_to_1[*(sp++)]; png_byte blue = png_ptr->gamma_to_1[*(sp++)]; - if(red != green || red != blue) + if (red != green || red != blue) { rgb_error |= 1; *(dp++) = png_ptr->gamma_from_1[ - (rc*red+gc*green+bc*blue)>>15]; + (rc*red + gc*green + bc*blue)>>15]; } else - *(dp++) = *(sp-1); + *(dp++) = *(sp - 1); } } else @@ -2274,13 +2382,13 @@ png_do_rgb_to_gray(png_structp png_ptr, png_row_infop row_info, png_bytep row) png_byte red = *(sp++); png_byte green = *(sp++); png_byte blue = *(sp++); - if(red != green || red != blue) + if (red != green || red != blue) { rgb_error |= 1; - *(dp++) = (png_byte)((rc*red+gc*green+bc*blue)>>15); + *(dp++) = (png_byte)((rc*red + gc*green + bc*blue)>>15); } else - *(dp++) = *(sp-1); + *(dp++) = *(sp - 1); } } } @@ -2301,13 +2409,14 @@ png_do_rgb_to_gray(png_structp png_ptr, png_row_infop row_info, png_bytep row) green = (png_uint_16)(((*(sp))<<8) | *(sp+1)); sp+=2; blue = (png_uint_16)(((*(sp))<<8) | *(sp+1)); sp+=2; - if(red == green && red == blue) + if (red == green && red == blue) w = red; else { png_uint_16 red_1 = png_ptr->gamma_16_to_1[(red&0xff) >> png_ptr->gamma_shift][red>>8]; - png_uint_16 green_1 = png_ptr->gamma_16_to_1[(green&0xff) >> + png_uint_16 green_1 = + png_ptr->gamma_16_to_1[(green&0xff) >> png_ptr->gamma_shift][green>>8]; png_uint_16 blue_1 = png_ptr->gamma_16_to_1[(blue&0xff) >> png_ptr->gamma_shift][blue>>8]; @@ -2335,7 +2444,7 @@ png_do_rgb_to_gray(png_structp png_ptr, png_row_infop row_info, png_bytep row) green = (png_uint_16)(((*(sp))<<8) | *(sp+1)); sp+=2; blue = (png_uint_16)(((*(sp))<<8) | *(sp+1)); sp+=2; - if(red != green || red != blue) + if (red != green || red != blue) rgb_error |= 1; gray16 = (png_uint_16)((rc*red + gc*green + bc*blue)>>15); *(dp++) = (png_byte)((gray16>>8) & 0xff); @@ -2358,7 +2467,7 @@ png_do_rgb_to_gray(png_structp png_ptr, png_row_infop row_info, png_bytep row) png_byte red = png_ptr->gamma_to_1[*(sp++)]; png_byte green = png_ptr->gamma_to_1[*(sp++)]; png_byte blue = png_ptr->gamma_to_1[*(sp++)]; - if(red != green || red != blue) + if (red != green || red != blue) rgb_error |= 1; *(dp++) = png_ptr->gamma_from_1 [(rc*red + gc*green + bc*blue)>>15]; @@ -2375,7 +2484,7 @@ png_do_rgb_to_gray(png_structp png_ptr, png_row_infop row_info, png_bytep row) png_byte red = *(sp++); png_byte green = *(sp++); png_byte blue = *(sp++); - if(red != green || red != blue) + if (red != green || red != blue) rgb_error |= 1; *(dp++) = (png_byte)((rc*red + gc*green + bc*blue)>>15); *(dp++) = *(sp++); /* alpha */ @@ -2398,18 +2507,19 @@ png_do_rgb_to_gray(png_structp png_ptr, png_row_infop row_info, png_bytep row) green = (png_uint_16)(((*(sp))<<8) | *(sp+1)); sp+=2; blue = (png_uint_16)(((*(sp))<<8) | *(sp+1)); sp+=2; - if(red == green && red == blue) + if (red == green && red == blue) w = red; else { png_uint_16 red_1 = png_ptr->gamma_16_to_1[(red&0xff) >> - png_ptr->gamma_shift][red>>8]; - png_uint_16 green_1 = png_ptr->gamma_16_to_1[(green&0xff) >> - png_ptr->gamma_shift][green>>8]; + png_ptr->gamma_shift][red>>8]; + png_uint_16 green_1 = + png_ptr->gamma_16_to_1[(green&0xff) >> + png_ptr->gamma_shift][green>>8]; png_uint_16 blue_1 = png_ptr->gamma_16_to_1[(blue&0xff) >> - png_ptr->gamma_shift][blue>>8]; + png_ptr->gamma_shift][blue>>8]; png_uint_16 gray16 = (png_uint_16)((rc * red_1 - + gc * green_1 + bc * blue_1)>>15); + + gc * green_1 + bc * blue_1)>>15); w = png_ptr->gamma_16_from_1[(gray16&0xff) >> png_ptr->gamma_shift][gray16 >> 8]; rgb_error |= 1; @@ -2432,7 +2542,7 @@ png_do_rgb_to_gray(png_structp png_ptr, png_row_infop row_info, png_bytep row) red = (png_uint_16)((*(sp)<<8) | *(sp+1)); sp+=2; green = (png_uint_16)((*(sp)<<8) | *(sp+1)); sp+=2; blue = (png_uint_16)((*(sp)<<8) | *(sp+1)); sp+=2; - if(red != green || red != blue) + if (red != green || red != blue) rgb_error |= 1; gray16 = (png_uint_16)((rc*red + gc*green + bc*blue)>>15); *(dp++) = (png_byte)((gray16>>8) & 0xff); @@ -2447,7 +2557,7 @@ png_do_rgb_to_gray(png_structp png_ptr, png_row_infop row_info, png_bytep row) row_info->color_type &= ~PNG_COLOR_MASK_COLOR; row_info->pixel_depth = (png_byte)(row_info->channels * row_info->bit_depth); - row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth,row_width); + row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth, row_width); } return rgb_error; } @@ -2466,7 +2576,8 @@ png_build_grayscale_palette(int bit_depth, png_colorp palette) int i; int v; - png_debug(1, "in png_do_build_grayscale_palette\n"); + png_debug(1, "in png_do_build_grayscale_palette"); + if (palette == NULL) return; @@ -2476,18 +2587,22 @@ png_build_grayscale_palette(int bit_depth, png_colorp palette) num_palette = 2; color_inc = 0xff; break; + case 2: num_palette = 4; color_inc = 0x55; break; + case 4: num_palette = 16; color_inc = 0x11; break; + case 8: num_palette = 256; color_inc = 1; break; + default: num_palette = 0; color_inc = 0; @@ -2503,14 +2618,17 @@ png_build_grayscale_palette(int bit_depth, png_colorp palette) } /* This function is currently unused. Do we really need it? */ -#if defined(PNG_READ_DITHER_SUPPORTED) && defined(PNG_CORRECT_PALETTE_SUPPORTED) +#if defined(PNG_READ_DITHER_SUPPORTED) && \ + defined(PNG_CORRECT_PALETTE_SUPPORTED) void /* PRIVATE */ png_correct_palette(png_structp png_ptr, png_colorp palette, int num_palette) { - png_debug(1, "in png_correct_palette\n"); + png_debug(1, "in png_correct_palette"); + #if defined(PNG_READ_BACKGROUND_SUPPORTED) && \ - defined(PNG_READ_GAMMA_SUPPORTED) && defined(PNG_FLOATING_POINT_SUPPORTED) + defined(PNG_READ_GAMMA_SUPPORTED) && \ + defined(PNG_FLOATING_POINT_SUPPORTED) if (png_ptr->transformations & (PNG_GAMMA | PNG_BACKGROUND)) { png_color back, back_1; @@ -2531,8 +2649,8 @@ png_correct_palette(png_structp png_ptr, png_colorp palette, g = 1.0 / (png_ptr->background_gamma * png_ptr->screen_gamma); - if (png_ptr->background_gamma_type == PNG_BACKGROUND_GAMMA_SCREEN || - fabs(g - 1.0) < PNG_GAMMA_THRESHOLD) + if (png_ptr->background_gamma_type == PNG_BACKGROUND_GAMMA_SCREEN + || fabs(g - 1.0) < PNG_GAMMA_THRESHOLD) { back.red = png_ptr->background.red; back.green = png_ptr->background.green; @@ -2619,7 +2737,7 @@ png_correct_palette(png_structp png_ptr, png_colorp palette, } else #endif -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (png_ptr->transformations & PNG_GAMMA) { int i; @@ -2631,11 +2749,11 @@ png_correct_palette(png_structp png_ptr, png_colorp palette, palette[i].blue = png_ptr->gamma_table[palette[i].blue]; } } -#if defined(PNG_READ_BACKGROUND_SUPPORTED) +#ifdef PNG_READ_BACKGROUND_SUPPORTED else #endif #endif -#if defined(PNG_READ_BACKGROUND_SUPPORTED) +#ifdef PNG_READ_BACKGROUND_SUPPORTED if (png_ptr->transformations & PNG_BACKGROUND) { if (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE) @@ -2665,7 +2783,7 @@ png_correct_palette(png_structp png_ptr, png_colorp palette, } } } - else /* assume grayscale palette (what else could it be?) */ + else /* Assume grayscale palette (what else could it be?) */ { int i; @@ -2684,7 +2802,7 @@ png_correct_palette(png_structp png_ptr, png_colorp palette, } #endif -#if defined(PNG_READ_BACKGROUND_SUPPORTED) +#ifdef PNG_READ_BACKGROUND_SUPPORTED /* Replace any alpha or transparency with the supplied background color. * "background" is already in the screen gamma, while "background_1" is * at a gamma of 1.0. Paletted files have already been taken care of. @@ -2692,7 +2810,7 @@ png_correct_palette(png_structp png_ptr, png_colorp palette, void /* PRIVATE */ png_do_background(png_row_infop row_info, png_bytep row, png_color_16p trans_values, png_color_16p background -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED , png_color_16p background_1, png_bytep gamma_table, png_bytep gamma_from_1, png_bytep gamma_to_1, png_uint_16pp gamma_16, png_uint_16pp gamma_16_from_1, @@ -2705,9 +2823,10 @@ png_do_background(png_row_infop row_info, png_bytep row, png_uint_32 row_width=row_info->width; int shift; - png_debug(1, "in png_do_background\n"); + png_debug(1, "in png_do_background"); + if (background != NULL && -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && #endif (!(row_info->color_type & PNG_COLOR_MASK_ALPHA) || @@ -2741,9 +2860,10 @@ png_do_background(png_row_infop row_info, png_bytep row, } break; } + case 2: { -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (gamma_table != NULL) { sp = row; @@ -2797,9 +2917,10 @@ png_do_background(png_row_infop row_info, png_bytep row, } break; } + case 4: { -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (gamma_table != NULL) { sp = row; @@ -2853,9 +2974,10 @@ png_do_background(png_row_infop row_info, png_bytep row, } break; } + case 8: { -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (gamma_table != NULL) { sp = row; @@ -2885,9 +3007,10 @@ png_do_background(png_row_infop row_info, png_bytep row, } break; } + case 16: { -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (gamma_16 != NULL) { sp = row; @@ -2898,7 +3021,7 @@ png_do_background(png_row_infop row_info, png_bytep row, v = (png_uint_16)(((*sp) << 8) + *(sp + 1)); if (v == trans_values->gray) { - /* background is already in screen gamma */ + /* Background is already in screen gamma */ *sp = (png_byte)((background->gray >> 8) & 0xff); *(sp + 1) = (png_byte)(background->gray & 0xff); } @@ -2931,11 +3054,12 @@ png_do_background(png_row_infop row_info, png_bytep row, } break; } + case PNG_COLOR_TYPE_RGB: { if (row_info->bit_depth == 8) { -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (gamma_table != NULL) { sp = row; @@ -2976,7 +3100,7 @@ png_do_background(png_row_infop row_info, png_bytep row, } else /* if (row_info->bit_depth == 16) */ { -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (gamma_16 != NULL) { sp = row; @@ -2988,7 +3112,7 @@ png_do_background(png_row_infop row_info, png_bytep row, if (r == trans_values->red && g == trans_values->green && b == trans_values->blue) { - /* background is already in screen gamma */ + /* Background is already in screen gamma */ *sp = (png_byte)((background->red >> 8) & 0xff); *(sp + 1) = (png_byte)(background->red & 0xff); *(sp + 2) = (png_byte)((background->green >> 8) & 0xff); @@ -3035,11 +3159,12 @@ png_do_background(png_row_infop row_info, png_bytep row, } break; } + case PNG_COLOR_TYPE_GRAY_ALPHA: { if (row_info->bit_depth == 8) { -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (gamma_to_1 != NULL && gamma_from_1 != NULL && gamma_table != NULL) { @@ -3055,7 +3180,7 @@ png_do_background(png_row_infop row_info, png_bytep row, } else if (a == 0) { - /* background is already in screen gamma */ + /* Background is already in screen gamma */ *dp = (png_byte)background->gray; } else @@ -3081,7 +3206,7 @@ png_do_background(png_row_infop row_info, png_bytep row, { *dp = *sp; } -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED else if (a == 0) { *dp = (png_byte)background->gray; @@ -3098,7 +3223,7 @@ png_do_background(png_row_infop row_info, png_bytep row, } else /* if (png_ptr->bit_depth == 16) */ { -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (gamma_16 != NULL && gamma_16_from_1 != NULL && gamma_16_to_1 != NULL) { @@ -3116,17 +3241,17 @@ png_do_background(png_row_infop row_info, png_bytep row, *dp = (png_byte)((v >> 8) & 0xff); *(dp + 1) = (png_byte)(v & 0xff); } -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED else if (a == 0) #else else #endif { - /* background is already in screen gamma */ + /* Background is already in screen gamma */ *dp = (png_byte)((background->gray >> 8) & 0xff); *(dp + 1) = (png_byte)(background->gray & 0xff); } -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED else { png_uint_16 g, v, w; @@ -3152,7 +3277,7 @@ png_do_background(png_row_infop row_info, png_bytep row, { png_memcpy(dp, sp, 2); } -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED else if (a == 0) #else else @@ -3161,7 +3286,7 @@ png_do_background(png_row_infop row_info, png_bytep row, *dp = (png_byte)((background->gray >> 8) & 0xff); *(dp + 1) = (png_byte)(background->gray & 0xff); } -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED else { png_uint_16 g, v; @@ -3177,11 +3302,12 @@ png_do_background(png_row_infop row_info, png_bytep row, } break; } + case PNG_COLOR_TYPE_RGB_ALPHA: { if (row_info->bit_depth == 8) { -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (gamma_to_1 != NULL && gamma_from_1 != NULL && gamma_table != NULL) { @@ -3199,7 +3325,7 @@ png_do_background(png_row_infop row_info, png_bytep row, } else if (a == 0) { - /* background is already in screen gamma */ + /* Background is already in screen gamma */ *dp = (png_byte)background->red; *(dp + 1) = (png_byte)background->green; *(dp + 2) = (png_byte)background->blue; @@ -3254,7 +3380,7 @@ png_do_background(png_row_infop row_info, png_bytep row, } else /* if (row_info->bit_depth == 16) */ { -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED if (gamma_16 != NULL && gamma_16_from_1 != NULL && gamma_16_to_1 != NULL) { @@ -3280,7 +3406,7 @@ png_do_background(png_row_infop row_info, png_bytep row, } else if (a == 0) { - /* background is already in screen gamma */ + /* Background is already in screen gamma */ *dp = (png_byte)((background->red >> 8) & 0xff); *(dp + 1) = (png_byte)(background->red & 0xff); *(dp + 2) = (png_byte)((background->green >> 8) & 0xff); @@ -3365,13 +3491,13 @@ png_do_background(png_row_infop row_info, png_bytep row, row_info->channels--; row_info->pixel_depth = (png_byte)(row_info->channels * row_info->bit_depth); - row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth,row_width); + row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth, row_width); } } } #endif -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED /* Gamma correct the image, avoiding the alpha channel. Make sure * you do this after you deal with the transparency issue on grayscale * or RGB images. If your bit depth is 8, use gamma_table, if it @@ -3387,9 +3513,10 @@ png_do_gamma(png_row_infop row_info, png_bytep row, png_uint_32 i; png_uint_32 row_width=row_info->width; - png_debug(1, "in png_do_gamma\n"); + png_debug(1, "in png_do_gamma"); + if ( -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && #endif ((row_info->bit_depth <= 8 && gamma_table != NULL) || @@ -3435,6 +3562,7 @@ png_do_gamma(png_row_infop row_info, png_bytep row, } break; } + case PNG_COLOR_TYPE_RGB_ALPHA: { if (row_info->bit_depth == 8) @@ -3472,6 +3600,7 @@ png_do_gamma(png_row_infop row_info, png_bytep row, } break; } + case PNG_COLOR_TYPE_GRAY_ALPHA: { if (row_info->bit_depth == 8) @@ -3496,6 +3625,7 @@ png_do_gamma(png_row_infop row_info, png_bytep row, } break; } + case PNG_COLOR_TYPE_GRAY: { if (row_info->bit_depth == 2) @@ -3509,13 +3639,14 @@ png_do_gamma(png_row_infop row_info, png_bytep row, int d = *sp & 0x03; *sp = (png_byte)( - ((((int)gamma_table[a|(a>>2)|(a>>4)|(a>>6)]) ) & 0xc0)| - ((((int)gamma_table[(b<<2)|b|(b>>2)|(b>>4)])>>2) & 0x30)| - ((((int)gamma_table[(c<<4)|(c<<2)|c|(c>>2)])>>4) & 0x0c)| - ((((int)gamma_table[(d<<6)|(d<<4)|(d<<2)|d])>>6) )); + ((((int)gamma_table[a|(a>>2)|(a>>4)|(a>>6)]) ) & 0xc0)| + ((((int)gamma_table[(b<<2)|b|(b>>2)|(b>>4)])>>2) & 0x30)| + ((((int)gamma_table[(c<<4)|(c<<2)|c|(c>>2)])>>4) & 0x0c)| + ((((int)gamma_table[(d<<6)|(d<<4)|(d<<2)|d])>>6) )); sp++; } } + if (row_info->bit_depth == 4) { sp = row; @@ -3525,10 +3656,11 @@ png_do_gamma(png_row_infop row_info, png_bytep row, int lsb = *sp & 0x0f; *sp = (png_byte)((((int)gamma_table[msb | (msb >> 4)]) & 0xf0) - | (((int)gamma_table[(lsb << 4) | lsb]) >> 4)); + | (((int)gamma_table[(lsb << 4) | lsb]) >> 4)); sp++; } } + else if (row_info->bit_depth == 8) { sp = row; @@ -3538,6 +3670,7 @@ png_do_gamma(png_row_infop row_info, png_bytep row, sp++; } } + else if (row_info->bit_depth == 16) { sp = row; @@ -3556,7 +3689,7 @@ png_do_gamma(png_row_infop row_info, png_bytep row, } #endif -#if defined(PNG_READ_EXPAND_SUPPORTED) +#ifdef PNG_READ_EXPAND_SUPPORTED /* Expands a palette row to an RGB or RGBA row depending * upon whether you supply trans and num_trans. */ @@ -3569,9 +3702,10 @@ png_do_expand_palette(png_row_infop row_info, png_bytep row, png_uint_32 i; png_uint_32 row_width=row_info->width; - png_debug(1, "in png_do_expand_palette\n"); + png_debug(1, "in png_do_expand_palette"); + if ( -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && #endif row_info->color_type == PNG_COLOR_TYPE_PALETTE) @@ -3603,6 +3737,7 @@ png_do_expand_palette(png_row_infop row_info, png_bytep row, } break; } + case 2: { sp = row + (png_size_t)((row_width - 1) >> 2); @@ -3624,6 +3759,7 @@ png_do_expand_palette(png_row_infop row_info, png_bytep row, } break; } + case 4: { sp = row + (png_size_t)((row_width - 1) >> 1); @@ -3688,6 +3824,7 @@ png_do_expand_palette(png_row_infop row_info, png_bytep row, *dp-- = palette[*sp].red; sp--; } + row_info->bit_depth = 8; row_info->pixel_depth = 24; row_info->rowbytes = row_width * 3; @@ -3712,8 +3849,9 @@ png_do_expand(png_row_infop row_info, png_bytep row, png_uint_32 i; png_uint_32 row_width=row_info->width; - png_debug(1, "in png_do_expand\n"); -#if defined(PNG_USELESS_TESTS_SUPPORTED) + png_debug(1, "in png_do_expand"); + +#ifdef PNG_USELESS_TESTS_SUPPORTED if (row != NULL && row_info != NULL) #endif { @@ -3749,6 +3887,7 @@ png_do_expand(png_row_infop row_info, png_bytep row, } break; } + case 2: { gray = (png_uint_16)((gray&0x03)*0x55); @@ -3772,6 +3911,7 @@ png_do_expand(png_row_infop row_info, png_bytep row, } break; } + case 4: { gray = (png_uint_16)((gray&0x0f)*0x11); @@ -3795,6 +3935,7 @@ png_do_expand(png_row_infop row_info, png_bytep row, break; } } + row_info->bit_depth = 8; row_info->pixel_depth = 8; row_info->rowbytes = row_width; @@ -3816,6 +3957,7 @@ png_do_expand(png_row_infop row_info, png_bytep row, *dp-- = *sp--; } } + else if (row_info->bit_depth == 16) { png_byte gray_high = (gray >> 8) & 0xff; @@ -3824,7 +3966,7 @@ png_do_expand(png_row_infop row_info, png_bytep row, dp = row + (row_info->rowbytes << 1) - 1; for (i = 0; i < row_width; i++) { - if (*(sp-1) == gray_high && *(sp) == gray_low) + if (*(sp - 1) == gray_high && *(sp) == gray_low) { *dp-- = 0; *dp-- = 0; @@ -3838,6 +3980,7 @@ png_do_expand(png_row_infop row_info, png_bytep row, *dp-- = *sp--; } } + row_info->color_type = PNG_COLOR_TYPE_GRAY_ALPHA; row_info->channels = 2; row_info->pixel_depth = (png_byte)(row_info->bit_depth << 1); @@ -3903,13 +4046,13 @@ png_do_expand(png_row_infop row_info, png_bytep row, row_info->color_type = PNG_COLOR_TYPE_RGB_ALPHA; row_info->channels = 4; row_info->pixel_depth = (png_byte)(row_info->bit_depth << 2); - row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth,row_width); + row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth, row_width); } } } #endif -#if defined(PNG_READ_DITHER_SUPPORTED) +#ifdef PNG_READ_DITHER_SUPPORTED void /* PRIVATE */ png_do_dither(png_row_infop row_info, png_bytep row, png_bytep palette_lookup, png_bytep dither_lookup) @@ -3918,8 +4061,9 @@ png_do_dither(png_row_infop row_info, png_bytep row, png_uint_32 i; png_uint_32 row_width=row_info->width; - png_debug(1, "in png_do_dither\n"); -#if defined(PNG_USELESS_TESTS_SUPPORTED) + png_debug(1, "in png_do_dither"); + +#ifdef PNG_USELESS_TESTS_SUPPORTED if (row != NULL && row_info != NULL) #endif { @@ -3935,13 +4079,13 @@ png_do_dither(png_row_infop row_info, png_bytep row, g = *sp++; b = *sp++; - /* this looks real messy, but the compiler will reduce - it down to a reasonable formula. For example, with - 5 bits per color, we get: - p = (((r >> 3) & 0x1f) << 10) | - (((g >> 3) & 0x1f) << 5) | - ((b >> 3) & 0x1f); - */ + /* This looks real messy, but the compiler will reduce + * it down to a reasonable formula. For example, with + * 5 bits per color, we get: + * p = (((r >> 3) & 0x1f) << 10) | + * (((g >> 3) & 0x1f) << 5) | + * ((b >> 3) & 0x1f); + */ p = (((r >> (8 - PNG_DITHER_RED_BITS)) & ((1 << PNG_DITHER_RED_BITS) - 1)) << (PNG_DITHER_GREEN_BITS + PNG_DITHER_BLUE_BITS)) | @@ -3956,7 +4100,7 @@ png_do_dither(png_row_infop row_info, png_bytep row, row_info->color_type = PNG_COLOR_TYPE_PALETTE; row_info->channels = 1; row_info->pixel_depth = row_info->bit_depth; - row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth,row_width); + row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth, row_width); } else if (row_info->color_type == PNG_COLOR_TYPE_RGB_ALPHA && palette_lookup != NULL && row_info->bit_depth == 8) @@ -3985,7 +4129,7 @@ png_do_dither(png_row_infop row_info, png_bytep row, row_info->color_type = PNG_COLOR_TYPE_PALETTE; row_info->channels = 1; row_info->pixel_depth = row_info->bit_depth; - row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth,row_width); + row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth, row_width); } else if (row_info->color_type == PNG_COLOR_TYPE_PALETTE && dither_lookup && row_info->bit_depth == 8) @@ -4001,7 +4145,7 @@ png_do_dither(png_row_infop row_info, png_bytep row, #endif #ifdef PNG_FLOATING_POINT_SUPPORTED -#if defined(PNG_READ_GAMMA_SUPPORTED) +#ifdef PNG_READ_GAMMA_SUPPORTED static PNG_CONST int png_gamma_shift[] = {0x10, 0x21, 0x42, 0x84, 0x110, 0x248, 0x550, 0xff0, 0x00}; @@ -4009,11 +4153,39 @@ static PNG_CONST int png_gamma_shift[] = * tables, we don't make a full table if we are reducing to 8-bit in * the future. Note also how the gamma_16 tables are segmented so that * we don't need to allocate > 64K chunks for a full 16-bit table. + * + * See the PNG extensions document for an integer algorithm for creating + * the gamma tables. Maybe we will implement that here someday. + * + * We should only reach this point if + * + * the file_gamma is known (i.e., the gAMA or sRGB chunk is present, + * or the application has provided a file_gamma) + * + * AND + * { + * the screen_gamma is known + * OR + * + * RGB_to_gray transformation is being performed + * } + * + * AND + * { + * the screen_gamma is different from the reciprocal of the + * file_gamma by more than the specified threshold + * + * OR + * + * a background color has been specified and the file_gamma + * and screen_gamma are not 1.0, within the specified threshold. + * } */ + void /* PRIVATE */ png_build_gamma_table(png_structp png_ptr) { - png_debug(1, "in png_build_gamma_table\n"); + png_debug(1, "in png_build_gamma_table"); if (png_ptr->bit_depth <= 8) { @@ -4022,6 +4194,7 @@ png_build_gamma_table(png_structp png_ptr) if (png_ptr->screen_gamma > .000001) g = 1.0 / (png_ptr->gamma * png_ptr->screen_gamma); + else g = 1.0; @@ -4054,10 +4227,11 @@ png_build_gamma_table(png_structp png_ptr) png_ptr->gamma_from_1 = (png_bytep)png_malloc(png_ptr, (png_uint_32)256); - if(png_ptr->screen_gamma > 0.000001) + if (png_ptr->screen_gamma > 0.000001) g = 1.0 / png_ptr->screen_gamma; + else - g = png_ptr->gamma; /* probably doing rgb_to_gray */ + g = png_ptr->gamma; /* Probably doing rgb_to_gray */ for (i = 0; i < 256; i++) { @@ -4078,8 +4252,10 @@ png_build_gamma_table(png_structp png_ptr) if (png_ptr->color_type & PNG_COLOR_MASK_COLOR) { sig_bit = (int)png_ptr->sig_bit.red; + if ((int)png_ptr->sig_bit.green > sig_bit) sig_bit = png_ptr->sig_bit.green; + if ((int)png_ptr->sig_bit.blue > sig_bit) sig_bit = png_ptr->sig_bit.blue; } @@ -4090,6 +4266,7 @@ png_build_gamma_table(png_structp png_ptr) if (sig_bit > 0) shift = 16 - sig_bit; + else shift = 0; @@ -4101,6 +4278,7 @@ png_build_gamma_table(png_structp png_ptr) if (shift > 8) shift = 8; + if (shift < 0) shift = 0; @@ -4113,8 +4291,8 @@ png_build_gamma_table(png_structp png_ptr) else g = 1.0; - png_ptr->gamma_16_table = (png_uint_16pp)png_malloc(png_ptr, - (png_uint_32)(num * png_sizeof (png_uint_16p))); + png_ptr->gamma_16_table = (png_uint_16pp)png_calloc(png_ptr, + (png_uint_32)(num * png_sizeof(png_uint_16p))); if (png_ptr->transformations & (PNG_16_TO_8 | PNG_BACKGROUND)) { @@ -4124,7 +4302,7 @@ png_build_gamma_table(png_structp png_ptr) for (i = 0; i < num; i++) { png_ptr->gamma_16_table[i] = (png_uint_16p)png_malloc(png_ptr, - (png_uint_32)(256 * png_sizeof (png_uint_16))); + (png_uint_32)(256 * png_sizeof(png_uint_16))); } g = 1.0 / g; @@ -4154,9 +4332,10 @@ png_build_gamma_table(png_structp png_ptr) for (i = 0; i < num; i++) { png_ptr->gamma_16_table[i] = (png_uint_16p)png_malloc(png_ptr, - (png_uint_32)(256 * png_sizeof (png_uint_16))); + (png_uint_32)(256 * png_sizeof(png_uint_16))); ig = (((png_uint_32)i * (png_uint_32)png_gamma_shift[shift]) >> 4); + for (j = 0; j < 256; j++) { png_ptr->gamma_16_table[i][j] = @@ -4173,13 +4352,13 @@ png_build_gamma_table(png_structp png_ptr) g = 1.0 / (png_ptr->gamma); - png_ptr->gamma_16_to_1 = (png_uint_16pp)png_malloc(png_ptr, - (png_uint_32)(num * png_sizeof (png_uint_16p ))); + png_ptr->gamma_16_to_1 = (png_uint_16pp)png_calloc(png_ptr, + (png_uint_32)(num * png_sizeof(png_uint_16p ))); for (i = 0; i < num; i++) { png_ptr->gamma_16_to_1[i] = (png_uint_16p)png_malloc(png_ptr, - (png_uint_32)(256 * png_sizeof (png_uint_16))); + (png_uint_32)(256 * png_sizeof(png_uint_16))); ig = (((png_uint_32)i * (png_uint_32)png_gamma_shift[shift]) >> 4); @@ -4191,21 +4370,23 @@ png_build_gamma_table(png_structp png_ptr) } } - if(png_ptr->screen_gamma > 0.000001) + if (png_ptr->screen_gamma > 0.000001) g = 1.0 / png_ptr->screen_gamma; + else - g = png_ptr->gamma; /* probably doing rgb_to_gray */ + g = png_ptr->gamma; /* Probably doing rgb_to_gray */ - png_ptr->gamma_16_from_1 = (png_uint_16pp)png_malloc(png_ptr, - (png_uint_32)(num * png_sizeof (png_uint_16p))); + png_ptr->gamma_16_from_1 = (png_uint_16pp)png_calloc(png_ptr, + (png_uint_32)(num * png_sizeof(png_uint_16p))); for (i = 0; i < num; i++) { png_ptr->gamma_16_from_1[i] = (png_uint_16p)png_malloc(png_ptr, - (png_uint_32)(256 * png_sizeof (png_uint_16))); + (png_uint_32)(256 * png_sizeof(png_uint_16))); ig = (((png_uint_32)i * (png_uint_32)png_gamma_shift[shift]) >> 4); + for (j = 0; j < 256; j++) { png_ptr->gamma_16_from_1[i][j] = @@ -4221,14 +4402,15 @@ png_build_gamma_table(png_structp png_ptr) /* To do: install integer version of png_build_gamma_table here */ #endif -#if defined(PNG_MNG_FEATURES_SUPPORTED) -/* undoes intrapixel differencing */ +#ifdef PNG_MNG_FEATURES_SUPPORTED +/* Undoes intrapixel differencing */ void /* PRIVATE */ png_do_read_intrapixel(png_row_infop row_info, png_bytep row) { - png_debug(1, "in png_do_read_intrapixel\n"); + png_debug(1, "in png_do_read_intrapixel"); + if ( -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && #endif (row_info->color_type & PNG_COLOR_MASK_COLOR)) @@ -4242,8 +4424,10 @@ png_do_read_intrapixel(png_row_infop row_info, png_bytep row) if (row_info->color_type == PNG_COLOR_TYPE_RGB) bytes_per_pixel = 3; + else if (row_info->color_type == PNG_COLOR_TYPE_RGB_ALPHA) bytes_per_pixel = 4; + else return; @@ -4260,18 +4444,20 @@ png_do_read_intrapixel(png_row_infop row_info, png_bytep row) if (row_info->color_type == PNG_COLOR_TYPE_RGB) bytes_per_pixel = 6; + else if (row_info->color_type == PNG_COLOR_TYPE_RGB_ALPHA) bytes_per_pixel = 8; + else return; for (i = 0, rp = row; i < row_width; i++, rp += bytes_per_pixel) { - png_uint_32 s0 = (*(rp ) << 8) | *(rp+1); - png_uint_32 s1 = (*(rp+2) << 8) | *(rp+3); - png_uint_32 s2 = (*(rp+4) << 8) | *(rp+5); - png_uint_32 red = (png_uint_32)((s0+s1+65536L) & 0xffffL); - png_uint_32 blue = (png_uint_32)((s2+s1+65536L) & 0xffffL); + png_uint_32 s0 = (*(rp ) << 8) | *(rp + 1); + png_uint_32 s1 = (*(rp + 2) << 8) | *(rp + 3); + png_uint_32 s2 = (*(rp + 4) << 8) | *(rp + 5); + png_uint_32 red = (png_uint_32)((s0 + s1 + 65536L) & 0xffffL); + png_uint_32 blue = (png_uint_32)((s2 + s1 + 65536L) & 0xffffL); *(rp ) = (png_byte)((red >> 8) & 0xff); *(rp+1) = (png_byte)(red & 0xff); *(rp+4) = (png_byte)((blue >> 8) & 0xff); diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngrutil.c b/graf2d/asimage/src/libAfterImage/libpng/pngrutil.c index 08d03ff6cc1a5..1de7427de2493 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngrutil.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngrutil.c @@ -1,36 +1,40 @@ /* pngrutil.c - utilities to read a PNG file * - * Last changed in libpng 1.2.22 [November 6, 2007] - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * Last changed in libpng 1.2.48 [March 8, 2012] + * Copyright (c) 1998-2012 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h + * * This file contains routines that are only called from within * libpng itself during the course of reading an image. */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" - -#if defined(PNG_READ_SUPPORTED) +#ifdef PNG_READ_SUPPORTED #if defined(_WIN32_WCE) && (_WIN32_WCE<0x500) # define WIN32_WCE_OLD #endif #ifdef PNG_FLOATING_POINT_SUPPORTED -# if defined(WIN32_WCE_OLD) -/* strtod() function is not supported on WindowsCE */ -__inline double png_strtod(png_structp png_ptr, PNG_CONST char *nptr, char **endptr) +# ifdef WIN32_WCE_OLD +/* The strtod() function is not supported on WindowsCE */ +__inline double png_strtod(png_structp png_ptr, PNG_CONST char *nptr, + char **endptr) { double result = 0; int len; wchar_t *str, *end; len = MultiByteToWideChar(CP_ACP, 0, nptr, -1, NULL, 0); - str = (wchar_t *)png_malloc(png_ptr, len * sizeof(wchar_t)); + str = (wchar_t *)png_malloc(png_ptr, len * png_sizeof(wchar_t)); if ( NULL != str ) { MultiByteToWideChar(CP_ACP, 0, nptr, -1, str, len); @@ -49,7 +53,15 @@ __inline double png_strtod(png_structp png_ptr, PNG_CONST char *nptr, char **end png_uint_32 PNGAPI png_get_uint_31(png_structp png_ptr, png_bytep buf) { +#ifdef PNG_READ_BIG_ENDIAN_SUPPORTED png_uint_32 i = png_get_uint_32(buf); +#else + /* Avoid an extra function call by inlining the result. */ + png_uint_32 i = ((png_uint_32)(*buf) << 24) + + ((png_uint_32)(*(buf + 1)) << 16) + + ((png_uint_32)(*(buf + 2)) << 8) + + (png_uint_32)(*(buf + 3)); +#endif if (i > PNG_UINT_31_MAX) png_error(png_ptr, "PNG unsigned integer out of range."); return (i); @@ -69,7 +81,8 @@ png_get_uint_32(png_bytep buf) /* Grab a signed 32-bit integer from a buffer in big-endian format. The * data is stored in the PNG file in two's complement format, and it is - * assumed that the machine format for signed integers is the same. */ + * assumed that the machine format for signed integers is the same. + */ png_int_32 PNGAPI png_get_int_32(png_bytep buf) { @@ -92,19 +105,50 @@ png_get_uint_16(png_bytep buf) } #endif /* PNG_READ_BIG_ENDIAN_SUPPORTED */ +/* Read the chunk header (length + type name). + * Put the type name into png_ptr->chunk_name, and return the length. + */ +png_uint_32 /* PRIVATE */ +png_read_chunk_header(png_structp png_ptr) +{ + png_byte buf[8]; + png_uint_32 length; + + /* Read the length and the chunk name */ + png_read_data(png_ptr, buf, 8); + length = png_get_uint_31(png_ptr, buf); + + /* Put the chunk name into png_ptr->chunk_name */ + png_memcpy(png_ptr->chunk_name, buf + 4, 4); + + png_debug2(0, "Reading %s chunk, length = %lu", + png_ptr->chunk_name, length); + + /* Reset the crc and run it over the chunk name */ + png_reset_crc(png_ptr); + png_calculate_crc(png_ptr, png_ptr->chunk_name, 4); + + /* Check to see if chunk name is valid */ + png_check_chunk_name(png_ptr, png_ptr->chunk_name); + + return length; +} + /* Read data, and (optionally) run it through the CRC. */ void /* PRIVATE */ png_crc_read(png_structp png_ptr, png_bytep buf, png_size_t length) { - if(png_ptr == NULL) return; + if (png_ptr == NULL) + return; png_read_data(png_ptr, buf, length); png_calculate_crc(png_ptr, buf, length); } /* Optionally skip data and then check the CRC. Depending on whether we - are reading a ancillary or critical chunk, and how the program has set - things up, we may calculate the CRC on the data and print a message. - Returns '1' if there was a CRC error, '0' otherwise. */ + * are reading a ancillary or critical chunk, and how the program has set + * things up, we may calculate the CRC on the data and print a message. + * Returns '1' if there was a CRC error, '0' otherwise. + */ int /* PRIVATE */ png_crc_finish(png_structp png_ptr, png_uint_32 skip) { @@ -123,7 +167,7 @@ png_crc_finish(png_structp png_ptr, png_uint_32 skip) if (png_crc_error(png_ptr)) { if (((png_ptr->chunk_name[0] & 0x20) && /* Ancillary */ - !(png_ptr->flags & PNG_FLAG_CRC_ANCILLARY_NOWARN)) || + !(png_ptr->flags & PNG_FLAG_CRC_ANCILLARY_NOWARN)) || (!(png_ptr->chunk_name[0] & 0x20) && /* Critical */ (png_ptr->flags & PNG_FLAG_CRC_CRITICAL_USE))) { @@ -140,7 +184,8 @@ png_crc_finish(png_structp png_ptr, png_uint_32 skip) } /* Compare the CRC stored in the PNG file with that calculated by libpng from - the data it has read thus far. */ + * the data it has read thus far. + */ int /* PRIVATE */ png_crc_error(png_structp png_ptr) { @@ -173,177 +218,213 @@ png_crc_error(png_structp png_ptr) #if defined(PNG_READ_zTXt_SUPPORTED) || defined(PNG_READ_iTXt_SUPPORTED) || \ defined(PNG_READ_iCCP_SUPPORTED) -/* - * Decompress trailing data in a chunk. The assumption is that chunkdata - * points at an allocated area holding the contents of a chunk with a - * trailing compressed part. What we get back is an allocated area - * holding the original prefix part and an uncompressed version of the - * trailing part (the malloc area passed in is freed). - */ -png_charp /* PRIVATE */ -png_decompress_chunk(png_structp png_ptr, int comp_type, - png_charp chunkdata, png_size_t chunklength, - png_size_t prefix_size, png_size_t *newlength) +static png_size_t +png_inflate(png_structp png_ptr, const png_byte *data, png_size_t size, + png_bytep output, png_size_t output_size) { - static PNG_CONST char msg[] = "Error decoding compressed text"; - png_charp text; - png_size_t text_size; + png_size_t count = 0; + + png_ptr->zstream.next_in = (png_bytep)data; /* const_cast: VALID */ + png_ptr->zstream.avail_in = size; - if (comp_type == PNG_COMPRESSION_TYPE_BASE) + while (1) { - int ret = Z_OK; - png_ptr->zstream.next_in = (png_bytep)(chunkdata + prefix_size); - png_ptr->zstream.avail_in = (uInt)(chunklength - prefix_size); + int ret, avail; + + /* Reset the output buffer each time round - we empty it + * after every inflate call. + */ png_ptr->zstream.next_out = png_ptr->zbuf; - png_ptr->zstream.avail_out = (uInt)png_ptr->zbuf_size; + png_ptr->zstream.avail_out = png_ptr->zbuf_size; - text_size = 0; - text = NULL; + ret = inflate(&png_ptr->zstream, Z_NO_FLUSH); + avail = png_ptr->zbuf_size - png_ptr->zstream.avail_out; - while (png_ptr->zstream.avail_in) + /* First copy/count any new output - but only if we didn't + * get an error code. + */ + if ((ret == Z_OK || ret == Z_STREAM_END) && avail > 0) { - ret = inflate(&png_ptr->zstream, Z_PARTIAL_FLUSH); - if (ret != Z_OK && ret != Z_STREAM_END) + if (output != 0 && output_size > count) { - if (png_ptr->zstream.msg != NULL) - png_warning(png_ptr, png_ptr->zstream.msg); - else - png_warning(png_ptr, msg); - inflateReset(&png_ptr->zstream); - png_ptr->zstream.avail_in = 0; + png_size_t copy = output_size - count; + if ((png_size_t) avail < copy) copy = (png_size_t) avail; + png_memcpy(output + count, png_ptr->zbuf, copy); + } + count += avail; + } - if (text == NULL) - { - text_size = prefix_size + png_sizeof(msg) + 1; - text = (png_charp)png_malloc_warn(png_ptr, text_size); - if (text == NULL) - { - png_free(png_ptr,chunkdata); - png_error(png_ptr,"Not enough memory to decompress chunk"); - } - png_memcpy(text, chunkdata, prefix_size); - } + if (ret == Z_OK) + continue; - text[text_size - 1] = 0x00; + /* Termination conditions - always reset the zstream, it + * must be left in inflateInit state. + */ + png_ptr->zstream.avail_in = 0; + inflateReset(&png_ptr->zstream); - /* Copy what we can of the error message into the text chunk */ - text_size = (png_size_t)(chunklength - (text - chunkdata) - 1); - text_size = png_sizeof(msg) > text_size ? text_size : - png_sizeof(msg); - png_memcpy(text + prefix_size, msg, text_size + 1); - break; - } - if (!png_ptr->zstream.avail_out || ret == Z_STREAM_END) + if (ret == Z_STREAM_END) + return count; /* NOTE: may be zero. */ + + /* Now handle the error codes - the API always returns 0 + * and the error message is dumped into the uncompressed + * buffer if available. + */ + { + PNG_CONST char *msg; + if (png_ptr->zstream.msg != 0) + msg = png_ptr->zstream.msg; + else { - if (text == NULL) - { - text_size = prefix_size + - png_ptr->zbuf_size - png_ptr->zstream.avail_out; - text = (png_charp)png_malloc_warn(png_ptr, text_size + 1); - if (text == NULL) - { - png_free(png_ptr,chunkdata); - png_error(png_ptr,"Not enough memory to decompress chunk."); - } - png_memcpy(text + prefix_size, png_ptr->zbuf, - text_size - prefix_size); - png_memcpy(text, chunkdata, prefix_size); - *(text + text_size) = 0x00; - } - else - { - png_charp tmp; +#if defined(PNG_STDIO_SUPPORTED) && !defined(_WIN32_WCE) + char umsg[52]; - tmp = text; - text = (png_charp)png_malloc_warn(png_ptr, - (png_uint_32)(text_size + - png_ptr->zbuf_size - png_ptr->zstream.avail_out + 1)); - if (text == NULL) - { - png_free(png_ptr, tmp); - png_free(png_ptr, chunkdata); - png_error(png_ptr,"Not enough memory to decompress chunk.."); - } - png_memcpy(text, tmp, text_size); - png_free(png_ptr, tmp); - png_memcpy(text + text_size, png_ptr->zbuf, - (png_ptr->zbuf_size - png_ptr->zstream.avail_out)); - text_size += png_ptr->zbuf_size - png_ptr->zstream.avail_out; - *(text + text_size) = 0x00; - } - if (ret == Z_STREAM_END) - break; - else + switch (ret) { - png_ptr->zstream.next_out = png_ptr->zbuf; - png_ptr->zstream.avail_out = (uInt)png_ptr->zbuf_size; + case Z_BUF_ERROR: + msg = "Buffer error in compressed datastream in %s chunk"; + break; + case Z_DATA_ERROR: + msg = "Data error in compressed datastream in %s chunk"; + break; + default: + msg = "Incomplete compressed datastream in %s chunk"; + break; } - } - } - if (ret != Z_STREAM_END) - { -#if !defined(PNG_NO_STDIO) && !defined(_WIN32_WCE) - char umsg[52]; - - if (ret == Z_BUF_ERROR) - png_snprintf(umsg, 52, - "Buffer error in compressed datastream in %s chunk", - png_ptr->chunk_name); - else if (ret == Z_DATA_ERROR) - png_snprintf(umsg, 52, - "Data error in compressed datastream in %s chunk", - png_ptr->chunk_name); - else - png_snprintf(umsg, 52, - "Incomplete compressed datastream in %s chunk", - png_ptr->chunk_name); - png_warning(png_ptr, umsg); + + png_snprintf(umsg, sizeof umsg, msg, png_ptr->chunk_name); + msg = umsg; #else - png_warning(png_ptr, - "Incomplete compressed datastream in chunk other than IDAT"); + msg = "Damaged compressed datastream in chunk other than IDAT"; #endif - text_size=prefix_size; - if (text == NULL) - { - text = (png_charp)png_malloc_warn(png_ptr, text_size+1); - if (text == NULL) - { - png_free(png_ptr, chunkdata); - png_error(png_ptr,"Not enough memory for text."); - } - png_memcpy(text, chunkdata, prefix_size); } - *(text + text_size) = 0x00; + + png_warning(png_ptr, msg); } - inflateReset(&png_ptr->zstream); - png_ptr->zstream.avail_in = 0; + /* 0 means an error - notice that this code simple ignores + * zero length compressed chunks as a result. + */ + return 0; + } +} + +/* + * Decompress trailing data in a chunk. The assumption is that chunkdata + * points at an allocated area holding the contents of a chunk with a + * trailing compressed part. What we get back is an allocated area + * holding the original prefix part and an uncompressed version of the + * trailing part (the malloc area passed in is freed). + */ +void /* PRIVATE */ +png_decompress_chunk(png_structp png_ptr, int comp_type, + png_size_t chunklength, + png_size_t prefix_size, png_size_t *newlength) +{ + /* The caller should guarantee this */ + if (prefix_size > chunklength) + { + /* The recovery is to delete the chunk. */ + png_warning(png_ptr, "invalid chunklength"); + prefix_size = 0; /* To delete everything */ + } + + else if (comp_type == PNG_COMPRESSION_TYPE_BASE) + { + png_size_t expanded_size = png_inflate(png_ptr, + (png_bytep)(png_ptr->chunkdata + prefix_size), + chunklength - prefix_size, + 0/*output*/, 0/*output size*/); + + /* Now check the limits on this chunk - if the limit fails the + * compressed data will be removed, the prefix will remain. + */ + if (prefix_size >= (~(png_size_t)0) - 1 || + expanded_size >= (~(png_size_t)0) - 1 - prefix_size +#ifdef PNG_USER_CHUNK_MALLOC_MAX + || ((PNG_USER_CHUNK_MALLOC_MAX > 0) && + prefix_size + expanded_size >= PNG_USER_CHUNK_MALLOC_MAX - 1) +#endif + ) + png_warning(png_ptr, "Exceeded size limit while expanding chunk"); + + /* If the size is zero either there was an error and a message + * has already been output (warning) or the size really is zero + * and we have nothing to do - the code will exit through the + * error case below. + */ + else if (expanded_size > 0) + { + /* Success (maybe) - really uncompress the chunk. */ + png_size_t new_size = 0; - png_free(png_ptr, chunkdata); - chunkdata = text; - *newlength=text_size; + png_charp text = png_malloc_warn(png_ptr, + prefix_size + expanded_size + 1); + + if (text != NULL) + { + png_memcpy(text, png_ptr->chunkdata, prefix_size); + new_size = png_inflate(png_ptr, + (png_bytep)(png_ptr->chunkdata + prefix_size), + chunklength - prefix_size, + (png_bytep)(text + prefix_size), expanded_size); + text[prefix_size + expanded_size] = 0; /* just in case */ + + if (new_size == expanded_size) + { + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = text; + *newlength = prefix_size + expanded_size; + return; /* The success return! */ + } + + png_warning(png_ptr, "png_inflate logic error"); + png_free(png_ptr, text); + } + else + png_warning(png_ptr, "Not enough memory to decompress chunk."); + } } + else /* if (comp_type != PNG_COMPRESSION_TYPE_BASE) */ { -#if !defined(PNG_NO_STDIO) && !defined(_WIN32_WCE) +#if defined(PNG_STDIO_SUPPORTED) && !defined(_WIN32_WCE) char umsg[50]; - png_snprintf(umsg, 50, - "Unknown zTXt compression type %d", comp_type); + png_snprintf(umsg, sizeof umsg, "Unknown zTXt compression type %d", + comp_type); png_warning(png_ptr, umsg); #else png_warning(png_ptr, "Unknown zTXt compression type"); #endif - *(chunkdata + prefix_size) = 0x00; - *newlength=prefix_size; + /* The recovery is to simply drop the data. */ } - return chunkdata; + /* Generic error return - leave the prefix, delete the compressed + * data, reallocate the chunkdata to remove the potentially large + * amount of compressed data. + */ + { + png_charp text = png_malloc_warn(png_ptr, prefix_size + 1); + if (text != NULL) + { + if (prefix_size > 0) + png_memcpy(text, png_ptr->chunkdata, prefix_size); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = text; + + /* This is an extra zero in the 'uncompressed' part. */ + *(png_ptr->chunkdata + prefix_size) = 0x00; + } + /* Ignore a malloc error here - it is safe. */ + } + + *newlength = prefix_size; } #endif -/* read and check the IDHR chunk */ +/* Read and check the IDHR chunk */ void /* PRIVATE */ png_handle_IHDR(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { @@ -352,12 +433,12 @@ png_handle_IHDR(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) int bit_depth, color_type, compression_type, filter_type; int interlace_type; - png_debug(1, "in png_handle_IHDR\n"); + png_debug(1, "in png_handle_IHDR"); if (png_ptr->mode & PNG_HAVE_IHDR) png_error(png_ptr, "Out of place IHDR"); - /* check the length */ + /* Check the length */ if (length != 13) png_error(png_ptr, "Invalid IHDR chunk"); @@ -374,66 +455,71 @@ png_handle_IHDR(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) filter_type = buf[11]; interlace_type = buf[12]; - /* set internal variables */ + /* Set internal variables */ png_ptr->width = width; png_ptr->height = height; png_ptr->bit_depth = (png_byte)bit_depth; png_ptr->interlaced = (png_byte)interlace_type; png_ptr->color_type = (png_byte)color_type; -#if defined(PNG_MNG_FEATURES_SUPPORTED) +#ifdef PNG_MNG_FEATURES_SUPPORTED png_ptr->filter_type = (png_byte)filter_type; #endif png_ptr->compression_type = (png_byte)compression_type; - /* find number of channels */ + /* Find number of channels */ switch (png_ptr->color_type) { case PNG_COLOR_TYPE_GRAY: case PNG_COLOR_TYPE_PALETTE: png_ptr->channels = 1; break; + case PNG_COLOR_TYPE_RGB: png_ptr->channels = 3; break; + case PNG_COLOR_TYPE_GRAY_ALPHA: png_ptr->channels = 2; break; + case PNG_COLOR_TYPE_RGB_ALPHA: png_ptr->channels = 4; break; } - /* set up other useful info */ + /* Set up other useful info */ png_ptr->pixel_depth = (png_byte)(png_ptr->bit_depth * png_ptr->channels); - png_ptr->rowbytes = PNG_ROWBYTES(png_ptr->pixel_depth,png_ptr->width); - png_debug1(3,"bit_depth = %d\n", png_ptr->bit_depth); - png_debug1(3,"channels = %d\n", png_ptr->channels); - png_debug1(3,"rowbytes = %lu\n", png_ptr->rowbytes); + png_ptr->rowbytes = PNG_ROWBYTES(png_ptr->pixel_depth, png_ptr->width); + png_debug1(3, "bit_depth = %d", png_ptr->bit_depth); + png_debug1(3, "channels = %d", png_ptr->channels); + png_debug1(3, "rowbytes = %lu", png_ptr->rowbytes); png_set_IHDR(png_ptr, info_ptr, width, height, bit_depth, color_type, interlace_type, compression_type, filter_type); } -/* read and check the palette */ +/* Read and check the palette */ void /* PRIVATE */ png_handle_PLTE(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { png_color palette[PNG_MAX_PALETTE_LENGTH]; int num, i; -#ifndef PNG_NO_POINTER_INDEXING +#ifdef PNG_POINTER_INDEXING_SUPPORTED png_colorp pal_ptr; #endif - png_debug(1, "in png_handle_PLTE\n"); + png_debug(1, "in png_handle_PLTE"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before PLTE"); + else if (png_ptr->mode & PNG_HAVE_IDAT) { png_warning(png_ptr, "Invalid PLTE after IDAT"); png_crc_finish(png_ptr, length); return; } + else if (png_ptr->mode & PNG_HAVE_PLTE) png_error(png_ptr, "Duplicate PLTE chunk"); @@ -446,7 +532,7 @@ png_handle_PLTE(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_crc_finish(png_ptr, length); return; } -#if !defined(PNG_READ_OPT_PLTE_SUPPORTED) +#ifndef PNG_READ_OPT_PLTE_SUPPORTED if (png_ptr->color_type != PNG_COLOR_TYPE_PALETTE) { png_crc_finish(png_ptr, length); @@ -462,6 +548,7 @@ png_handle_PLTE(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_crc_finish(png_ptr, length); return; } + else { png_error(png_ptr, "Invalid palette chunk"); @@ -470,7 +557,7 @@ png_handle_PLTE(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) num = (int)length / 3; -#ifndef PNG_NO_POINTER_INDEXING +#ifdef PNG_POINTER_INDEXING_SUPPORTED for (i = 0, pal_ptr = palette; i < num; i++, pal_ptr++) { png_byte buf[3]; @@ -486,7 +573,7 @@ png_handle_PLTE(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_byte buf[3]; png_crc_read(png_ptr, buf, 3); - /* don't depend upon png_color being any order */ + /* Don't depend upon png_color being any order */ palette[i].red = buf[0]; palette[i].green = buf[1]; palette[i].blue = buf[2]; @@ -494,16 +581,17 @@ png_handle_PLTE(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) #endif /* If we actually NEED the PLTE chunk (ie for a paletted image), we do - whatever the normal CRC configuration tells us. However, if we - have an RGB image, the PLTE can be considered ancillary, so - we will act as though it is. */ -#if !defined(PNG_READ_OPT_PLTE_SUPPORTED) + * whatever the normal CRC configuration tells us. However, if we + * have an RGB image, the PLTE can be considered ancillary, so + * we will act as though it is. + */ +#ifndef PNG_READ_OPT_PLTE_SUPPORTED if (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE) #endif { png_crc_finish(png_ptr, 0); } -#if !defined(PNG_READ_OPT_PLTE_SUPPORTED) +#ifndef PNG_READ_OPT_PLTE_SUPPORTED else if (png_crc_error(png_ptr)) /* Only if we have a CRC error */ { /* If we don't want to use the data from an ancillary chunk, @@ -532,7 +620,7 @@ png_handle_PLTE(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_set_PLTE(png_ptr, info_ptr, palette, num); -#if defined(PNG_READ_tRNS_SUPPORTED) +#ifdef PNG_READ_tRNS_SUPPORTED if (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE) { if (info_ptr != NULL && (info_ptr->valid & PNG_INFO_tRNS)) @@ -556,7 +644,7 @@ png_handle_PLTE(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) void /* PRIVATE */ png_handle_IEND(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { - png_debug(1, "in png_handle_IEND\n"); + png_debug(1, "in png_handle_IEND"); if (!(png_ptr->mode & PNG_HAVE_IHDR) || !(png_ptr->mode & PNG_HAVE_IDAT)) { @@ -571,10 +659,10 @@ png_handle_IEND(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } png_crc_finish(png_ptr, length); - info_ptr =info_ptr; /* quiet compiler warnings about unused info_ptr */ + info_ptr = info_ptr; /* Quiet compiler warnings about unused info_ptr */ } -#if defined(PNG_READ_gAMA_SUPPORTED) +#ifdef PNG_READ_gAMA_SUPPORTED void /* PRIVATE */ png_handle_gAMA(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { @@ -584,7 +672,7 @@ png_handle_gAMA(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) #endif png_byte buf[4]; - png_debug(1, "in png_handle_gAMA\n"); + png_debug(1, "in png_handle_gAMA"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before gAMA"); @@ -599,7 +687,7 @@ png_handle_gAMA(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_warning(png_ptr, "Out of place gAMA chunk"); if (info_ptr != NULL && (info_ptr->valid & PNG_INFO_gAMA) -#if defined(PNG_READ_sRGB_SUPPORTED) +#ifdef PNG_READ_sRGB_SUPPORTED && !(info_ptr->valid & PNG_INFO_sRGB) #endif ) @@ -621,7 +709,7 @@ png_handle_gAMA(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) return; igamma = (png_fixed_point)png_get_uint_32(buf); - /* check for zero gamma */ + /* Check for zero gamma */ if (igamma == 0) { png_warning(png_ptr, @@ -629,14 +717,14 @@ png_handle_gAMA(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) return; } -#if defined(PNG_READ_sRGB_SUPPORTED) +#ifdef PNG_READ_sRGB_SUPPORTED if (info_ptr != NULL && (info_ptr->valid & PNG_INFO_sRGB)) if (PNG_OUT_OF_RANGE(igamma, 45500L, 500)) { png_warning(png_ptr, "Ignoring incorrect gAMA value when sRGB is also present"); -#ifndef PNG_NO_CONSOLE_IO - fprintf(stderr, "gamma = (%d/100000)\n", (int)igamma); +#ifdef PNG_CONSOLE_IO_SUPPORTED + fprintf(stderr, "gamma = (%d/100000)", (int)igamma); #endif return; } @@ -655,14 +743,14 @@ png_handle_gAMA(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif -#if defined(PNG_READ_sBIT_SUPPORTED) +#ifdef PNG_READ_sBIT_SUPPORTED void /* PRIVATE */ png_handle_sBIT(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { png_size_t truelen; png_byte buf[4]; - png_debug(1, "in png_handle_sBIT\n"); + png_debug(1, "in png_handle_sBIT"); buf[0] = buf[1] = buf[2] = buf[3] = 0; @@ -721,11 +809,11 @@ png_handle_sBIT(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif -#if defined(PNG_READ_cHRM_SUPPORTED) +#ifdef PNG_READ_cHRM_SUPPORTED void /* PRIVATE */ png_handle_cHRM(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { - png_byte buf[4]; + png_byte buf[32]; #ifdef PNG_FLOATING_POINT_SUPPORTED float white_x, white_y, red_x, red_y, green_x, green_y, blue_x, blue_y; #endif @@ -734,7 +822,7 @@ png_handle_cHRM(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_uint_32 uint_x, uint_y; - png_debug(1, "in png_handle_cHRM\n"); + png_debug(1, "in png_handle_cHRM"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before cHRM"); @@ -749,7 +837,7 @@ png_handle_cHRM(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_warning(png_ptr, "Missing PLTE before cHRM"); if (info_ptr != NULL && (info_ptr->valid & PNG_INFO_cHRM) -#if defined(PNG_READ_sRGB_SUPPORTED) +#ifdef PNG_READ_sRGB_SUPPORTED && !(info_ptr->valid & PNG_INFO_sRGB) #endif ) @@ -766,64 +854,27 @@ png_handle_cHRM(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) return; } - png_crc_read(png_ptr, buf, 4); - uint_x = png_get_uint_32(buf); - - png_crc_read(png_ptr, buf, 4); - uint_y = png_get_uint_32(buf); - - if (uint_x > 80000L || uint_y > 80000L || - uint_x + uint_y > 100000L) - { - png_warning(png_ptr, "Invalid cHRM white point"); - png_crc_finish(png_ptr, 24); + png_crc_read(png_ptr, buf, 32); + if (png_crc_finish(png_ptr, 0)) return; - } - int_x_white = (png_fixed_point)uint_x; - int_y_white = (png_fixed_point)uint_y; - png_crc_read(png_ptr, buf, 4); uint_x = png_get_uint_32(buf); + uint_y = png_get_uint_32(buf + 4); + int_x_white = (png_fixed_point)uint_x; + int_y_white = (png_fixed_point)uint_y; - png_crc_read(png_ptr, buf, 4); - uint_y = png_get_uint_32(buf); - - if (uint_x + uint_y > 100000L) - { - png_warning(png_ptr, "Invalid cHRM red point"); - png_crc_finish(png_ptr, 16); - return; - } + uint_x = png_get_uint_32(buf + 8); + uint_y = png_get_uint_32(buf + 12); int_x_red = (png_fixed_point)uint_x; int_y_red = (png_fixed_point)uint_y; - png_crc_read(png_ptr, buf, 4); - uint_x = png_get_uint_32(buf); - - png_crc_read(png_ptr, buf, 4); - uint_y = png_get_uint_32(buf); - - if (uint_x + uint_y > 100000L) - { - png_warning(png_ptr, "Invalid cHRM green point"); - png_crc_finish(png_ptr, 8); - return; - } + uint_x = png_get_uint_32(buf + 16); + uint_y = png_get_uint_32(buf + 20); int_x_green = (png_fixed_point)uint_x; int_y_green = (png_fixed_point)uint_y; - png_crc_read(png_ptr, buf, 4); - uint_x = png_get_uint_32(buf); - - png_crc_read(png_ptr, buf, 4); - uint_y = png_get_uint_32(buf); - - if (uint_x + uint_y > 100000L) - { - png_warning(png_ptr, "Invalid cHRM blue point"); - png_crc_finish(png_ptr, 0); - return; - } + uint_x = png_get_uint_32(buf + 24); + uint_y = png_get_uint_32(buf + 28); int_x_blue = (png_fixed_point)uint_x; int_y_blue = (png_fixed_point)uint_y; @@ -838,7 +889,7 @@ png_handle_cHRM(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) blue_y = (float)int_y_blue / (float)100000.0; #endif -#if defined(PNG_READ_sRGB_SUPPORTED) +#ifdef PNG_READ_sRGB_SUPPORTED if ((info_ptr != NULL) && (info_ptr->valid & PNG_INFO_sRGB)) { if (PNG_OUT_OF_RANGE(int_x_white, 31270, 1000) || @@ -852,21 +903,22 @@ png_handle_cHRM(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { png_warning(png_ptr, "Ignoring incorrect cHRM value when sRGB is also present"); -#ifndef PNG_NO_CONSOLE_IO +#ifdef PNG_CONSOLE_IO_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED - fprintf(stderr,"wx=%f, wy=%f, rx=%f, ry=%f\n", + fprintf(stderr, "wx=%f, wy=%f, rx=%f, ry=%f\n", white_x, white_y, red_x, red_y); - fprintf(stderr,"gx=%f, gy=%f, bx=%f, by=%f\n", + fprintf(stderr, "gx=%f, gy=%f, bx=%f, by=%f\n", green_x, green_y, blue_x, blue_y); #else - fprintf(stderr,"wx=%ld, wy=%ld, rx=%ld, ry=%ld\n", - int_x_white, int_y_white, int_x_red, int_y_red); - fprintf(stderr,"gx=%ld, gy=%ld, bx=%ld, by=%ld\n", - int_x_green, int_y_green, int_x_blue, int_y_blue); -#endif -#endif /* PNG_NO_CONSOLE_IO */ + fprintf(stderr, "wx=%ld, wy=%ld, rx=%ld, ry=%ld\n", + (long)int_x_white, (long)int_y_white, + (long)int_x_red, (long)int_y_red); + fprintf(stderr, "gx=%ld, gy=%ld, bx=%ld, by=%ld\n", + (long)int_x_green, (long)int_y_green, + (long)int_x_blue, (long)int_y_blue); +#endif +#endif /* PNG_CONSOLE_IO_SUPPORTED */ } - png_crc_finish(png_ptr, 0); return; } #endif /* PNG_READ_sRGB_SUPPORTED */ @@ -880,19 +932,17 @@ png_handle_cHRM(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) int_x_white, int_y_white, int_x_red, int_y_red, int_x_green, int_y_green, int_x_blue, int_y_blue); #endif - if (png_crc_finish(png_ptr, 0)) - return; } #endif -#if defined(PNG_READ_sRGB_SUPPORTED) +#ifdef PNG_READ_sRGB_SUPPORTED void /* PRIVATE */ png_handle_sRGB(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { int intent; png_byte buf[1]; - png_debug(1, "in png_handle_sRGB\n"); + png_debug(1, "in png_handle_sRGB"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before sRGB"); @@ -925,7 +975,7 @@ png_handle_sRGB(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) return; intent = buf[0]; - /* check for bad intent */ + /* Check for bad intent */ if (intent >= PNG_sRGB_INTENT_LAST) { png_warning(png_ptr, "Unknown sRGB intent"); @@ -947,12 +997,13 @@ png_handle_sRGB(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { png_warning(png_ptr, "Ignoring incorrect gAMA value when sRGB is also present"); -#ifndef PNG_NO_CONSOLE_IO +#ifdef PNG_CONSOLE_IO_SUPPORTED # ifdef PNG_FIXED_POINT_SUPPORTED - fprintf(stderr,"incorrect gamma=(%d/100000)\n",(int)png_ptr->int_gamma); + fprintf(stderr, "incorrect gamma=(%d/100000)\n", + (int)png_ptr->int_gamma); # else # ifdef PNG_FLOATING_POINT_SUPPORTED - fprintf(stderr,"incorrect gamma=%f\n",png_ptr->gamma); + fprintf(stderr, "incorrect gamma=%f\n", png_ptr->gamma); # endif # endif #endif @@ -982,12 +1033,11 @@ png_handle_sRGB(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif /* PNG_READ_sRGB_SUPPORTED */ -#if defined(PNG_READ_iCCP_SUPPORTED) +#ifdef PNG_READ_iCCP_SUPPORTED void /* PRIVATE */ png_handle_iCCP(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) /* Note: this does not properly handle chunks that are > 64K under DOS */ { - png_charp chunkdata; png_byte compression_type; png_bytep pC; png_charp profile; @@ -995,7 +1045,7 @@ png_handle_iCCP(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_uint_32 profile_size, profile_length; png_size_t slength, prefix_length, data_length; - png_debug(1, "in png_handle_iCCP\n"); + png_debug(1, "in png_handle_iCCP"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before iCCP"); @@ -1025,93 +1075,117 @@ png_handle_iCCP(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif - chunkdata = (png_charp)png_malloc(png_ptr, length + 1); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = (png_charp)png_malloc(png_ptr, length + 1); slength = (png_size_t)length; - png_crc_read(png_ptr, (png_bytep)chunkdata, slength); + png_crc_read(png_ptr, (png_bytep)png_ptr->chunkdata, slength); if (png_crc_finish(png_ptr, skip)) { - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } - chunkdata[slength] = 0x00; + png_ptr->chunkdata[slength] = 0x00; - for (profile = chunkdata; *profile; profile++) - /* empty loop to find end of name */ ; + for (profile = png_ptr->chunkdata; *profile; profile++) + /* Empty loop to find end of name */ ; ++profile; - /* there should be at least one zero (the compression type byte) - following the separator, and we should be on it */ - if ( profile >= chunkdata + slength - 1) + /* There should be at least one zero (the compression type byte) + * following the separator, and we should be on it + */ + if ( profile >= png_ptr->chunkdata + slength - 1) { - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; png_warning(png_ptr, "Malformed iCCP chunk"); return; } - /* compression_type should always be zero */ + /* Compression_type should always be zero */ compression_type = *profile++; if (compression_type) { png_warning(png_ptr, "Ignoring nonzero compression type in iCCP chunk"); - compression_type=0x00; /* Reset it to zero (libpng-1.0.6 through 1.0.8 + compression_type = 0x00; /* Reset it to zero (libpng-1.0.6 through 1.0.8 wrote nonzero) */ } - prefix_length = profile - chunkdata; - chunkdata = png_decompress_chunk(png_ptr, compression_type, chunkdata, - slength, prefix_length, &data_length); + prefix_length = profile - png_ptr->chunkdata; + png_decompress_chunk(png_ptr, compression_type, + slength, prefix_length, &data_length); profile_length = data_length - prefix_length; if ( prefix_length > data_length || profile_length < 4) { - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; png_warning(png_ptr, "Profile size field missing from iCCP chunk"); return; } /* Check the profile_size recorded in the first 32 bits of the ICC profile */ - pC = (png_bytep)(chunkdata+prefix_length); - profile_size = ((*(pC ))<<24) | - ((*(pC+1))<<16) | - ((*(pC+2))<< 8) | - ((*(pC+3)) ); + pC = (png_bytep)(png_ptr->chunkdata + prefix_length); + profile_size = ((*(pC ))<<24) | + ((*(pC + 1))<<16) | + ((*(pC + 2))<< 8) | + ((*(pC + 3)) ); - if(profile_size < profile_length) + if (profile_size < profile_length) profile_length = profile_size; - if(profile_size > profile_length) + if (profile_size > profile_length) { - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; png_warning(png_ptr, "Ignoring truncated iCCP profile."); return; } - png_set_iCCP(png_ptr, info_ptr, chunkdata, compression_type, - chunkdata + prefix_length, profile_length); - png_free(png_ptr, chunkdata); + png_set_iCCP(png_ptr, info_ptr, png_ptr->chunkdata, + compression_type, png_ptr->chunkdata + prefix_length, profile_length); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; } #endif /* PNG_READ_iCCP_SUPPORTED */ -#if defined(PNG_READ_sPLT_SUPPORTED) +#ifdef PNG_READ_sPLT_SUPPORTED void /* PRIVATE */ png_handle_sPLT(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) /* Note: this does not properly handle chunks that are > 64K under DOS */ { - png_bytep chunkdata; png_bytep entry_start; png_sPLT_t new_palette; -#ifdef PNG_NO_POINTER_INDEXING +#ifdef PNG_POINTER_INDEXING_SUPPORTED png_sPLT_entryp pp; #endif int data_length, entry_size, i; png_uint_32 skip = 0; png_size_t slength; - png_debug(1, "in png_handle_sPLT\n"); + png_debug(1, "in png_handle_sPLT"); + +#ifdef PNG_USER_LIMITS_SUPPORTED + + if (png_ptr->user_chunk_cache_max != 0) + { + if (png_ptr->user_chunk_cache_max == 1) + { + png_crc_finish(png_ptr, length); + return; + } + if (--png_ptr->user_chunk_cache_max == 1) + { + png_warning(png_ptr, "No space in chunk cache for sPLT"); + png_crc_finish(png_ptr, length); + return; + } + } +#endif if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before sPLT"); @@ -1131,45 +1205,50 @@ png_handle_sPLT(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif - chunkdata = (png_bytep)png_malloc(png_ptr, length + 1); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = (png_charp)png_malloc(png_ptr, length + 1); slength = (png_size_t)length; - png_crc_read(png_ptr, (png_bytep)chunkdata, slength); + png_crc_read(png_ptr, (png_bytep)png_ptr->chunkdata, slength); if (png_crc_finish(png_ptr, skip)) { - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } - chunkdata[slength] = 0x00; + png_ptr->chunkdata[slength] = 0x00; - for (entry_start = chunkdata; *entry_start; entry_start++) - /* empty loop to find end of name */ ; + for (entry_start = (png_bytep)png_ptr->chunkdata; *entry_start; + entry_start++) + /* Empty loop to find end of name */ ; ++entry_start; - /* a sample depth should follow the separator, and we should be on it */ - if (entry_start > chunkdata + slength - 2) + /* A sample depth should follow the separator, and we should be on it */ + if (entry_start > (png_bytep)png_ptr->chunkdata + slength - 2) { - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; png_warning(png_ptr, "malformed sPLT chunk"); return; } new_palette.depth = *entry_start++; entry_size = (new_palette.depth == 8 ? 6 : 10); - data_length = (slength - (entry_start - chunkdata)); + data_length = (slength - (entry_start - (png_bytep)png_ptr->chunkdata)); - /* integrity-check the data length */ + /* Integrity-check the data length */ if (data_length % entry_size) { - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; png_warning(png_ptr, "sPLT chunk has bad length"); return; } new_palette.nentries = (png_int_32) ( data_length / entry_size); - if ((png_uint_32) new_palette.nentries > (png_uint_32) (PNG_SIZE_MAX / - png_sizeof(png_sPLT_entry))) + if ((png_uint_32) new_palette.nentries > + (png_uint_32) (PNG_SIZE_MAX / png_sizeof(png_sPLT_entry))) { png_warning(png_ptr, "sPLT chunk too long"); return; @@ -1182,10 +1261,10 @@ png_handle_sPLT(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) return; } -#ifndef PNG_NO_POINTER_INDEXING +#ifdef PNG_POINTER_INDEXING_SUPPORTED for (i = 0; i < new_palette.nentries; i++) { - png_sPLT_entryp pp = new_palette.entries + i; + pp = new_palette.entries + i; if (new_palette.depth == 8) { @@ -1226,29 +1305,24 @@ png_handle_sPLT(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif - /* discard all chunk data except the name and stash that */ - new_palette.name = (png_charp)chunkdata; + /* Discard all chunk data except the name and stash that */ + new_palette.name = png_ptr->chunkdata; png_set_sPLT(png_ptr, info_ptr, &new_palette, 1); - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; png_free(png_ptr, new_palette.entries); } #endif /* PNG_READ_sPLT_SUPPORTED */ -#if defined(PNG_READ_tRNS_SUPPORTED) +#ifdef PNG_READ_tRNS_SUPPORTED void /* PRIVATE */ png_handle_tRNS(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { png_byte readbuf[PNG_MAX_PALETTE_LENGTH]; - int bit_mask; - - png_debug(1, "in png_handle_tRNS\n"); - /* For non-indexed color, mask off any bits in the tRNS value that - * exceed the bit depth. Some creators were writing extra bits there. - * This is not needed for indexed color. */ - bit_mask = (1 << png_ptr->bit_depth) - 1; + png_debug(1, "in png_handle_tRNS"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before tRNS"); @@ -1278,7 +1352,7 @@ png_handle_tRNS(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_crc_read(png_ptr, buf, 2); png_ptr->num_trans = 1; - png_ptr->trans_values.gray = png_get_uint_16(buf) & bit_mask; + png_ptr->trans_values.gray = png_get_uint_16(buf); } else if (png_ptr->color_type == PNG_COLOR_TYPE_RGB) { @@ -1292,9 +1366,9 @@ png_handle_tRNS(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } png_crc_read(png_ptr, buf, (png_size_t)length); png_ptr->num_trans = 1; - png_ptr->trans_values.red = png_get_uint_16(buf) & bit_mask; - png_ptr->trans_values.green = png_get_uint_16(buf + 2) & bit_mask; - png_ptr->trans_values.blue = png_get_uint_16(buf + 4) & bit_mask; + png_ptr->trans_values.red = png_get_uint_16(buf); + png_ptr->trans_values.green = png_get_uint_16(buf + 2); + png_ptr->trans_values.blue = png_get_uint_16(buf + 4); } else if (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE) { @@ -1337,14 +1411,14 @@ png_handle_tRNS(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif -#if defined(PNG_READ_bKGD_SUPPORTED) +#ifdef PNG_READ_bKGD_SUPPORTED void /* PRIVATE */ png_handle_bKGD(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { png_size_t truelen; png_byte buf[6]; - png_debug(1, "in png_handle_bKGD\n"); + png_debug(1, "in png_handle_bKGD"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before bKGD"); @@ -1393,9 +1467,9 @@ png_handle_bKGD(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) if (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE) { png_ptr->background.index = buf[0]; - if(info_ptr->num_palette) + if (info_ptr && info_ptr->num_palette) { - if(buf[0] > info_ptr->num_palette) + if (buf[0] >= info_ptr->num_palette) { png_warning(png_ptr, "Incorrect bKGD chunk index value"); return; @@ -1426,14 +1500,14 @@ png_handle_bKGD(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif -#if defined(PNG_READ_hIST_SUPPORTED) +#ifdef PNG_READ_hIST_SUPPORTED void /* PRIVATE */ png_handle_hIST(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { unsigned int num, i; png_uint_16 readbuf[PNG_MAX_PALETTE_LENGTH]; - png_debug(1, "in png_handle_hIST\n"); + png_debug(1, "in png_handle_hIST"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before hIST"); @@ -1456,15 +1530,16 @@ png_handle_hIST(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) return; } - num = length / 2 ; - if (num != (unsigned int) png_ptr->num_palette || num > - (unsigned int) PNG_MAX_PALETTE_LENGTH) + if (length > 2*PNG_MAX_PALETTE_LENGTH || + length != (unsigned int) (2*png_ptr->num_palette)) { png_warning(png_ptr, "Incorrect hIST chunk length"); png_crc_finish(png_ptr, length); return; } + num = length / 2 ; + for (i = 0; i < num; i++) { png_byte buf[2]; @@ -1480,7 +1555,7 @@ png_handle_hIST(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif -#if defined(PNG_READ_pHYs_SUPPORTED) +#ifdef PNG_READ_pHYs_SUPPORTED void /* PRIVATE */ png_handle_pHYs(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { @@ -1488,7 +1563,7 @@ png_handle_pHYs(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_uint_32 res_x, res_y; int unit_type; - png_debug(1, "in png_handle_pHYs\n"); + png_debug(1, "in png_handle_pHYs"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before pHYs"); @@ -1523,7 +1598,7 @@ png_handle_pHYs(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif -#if defined(PNG_READ_oFFs_SUPPORTED) +#ifdef PNG_READ_oFFs_SUPPORTED void /* PRIVATE */ png_handle_oFFs(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { @@ -1531,7 +1606,7 @@ png_handle_oFFs(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_int_32 offset_x, offset_y; int unit_type; - png_debug(1, "in png_handle_oFFs\n"); + png_debug(1, "in png_handle_oFFs"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before oFFs"); @@ -1566,12 +1641,11 @@ png_handle_oFFs(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif -#if defined(PNG_READ_pCAL_SUPPORTED) -/* read the pCAL chunk (described in the PNG Extensions document) */ +#ifdef PNG_READ_pCAL_SUPPORTED +/* Read the pCAL chunk (described in the PNG Extensions document) */ void /* PRIVATE */ png_handle_pCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { - png_charp purpose; png_int_32 X0, X1; png_byte type, nparams; png_charp buf, units, endptr; @@ -1579,7 +1653,7 @@ png_handle_pCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_size_t slength; int i; - png_debug(1, "in png_handle_pCAL\n"); + png_debug(1, "in png_handle_pCAL"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before pCAL"); @@ -1596,48 +1670,51 @@ png_handle_pCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) return; } - png_debug1(2, "Allocating and reading pCAL chunk data (%lu bytes)\n", + png_debug1(2, "Allocating and reading pCAL chunk data (%lu bytes)", length + 1); - purpose = (png_charp)png_malloc_warn(png_ptr, length + 1); - if (purpose == NULL) + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = (png_charp)png_malloc_warn(png_ptr, length + 1); + if (png_ptr->chunkdata == NULL) { png_warning(png_ptr, "No memory for pCAL purpose."); return; } slength = (png_size_t)length; - png_crc_read(png_ptr, (png_bytep)purpose, slength); + png_crc_read(png_ptr, (png_bytep)png_ptr->chunkdata, slength); if (png_crc_finish(png_ptr, 0)) { - png_free(png_ptr, purpose); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } - purpose[slength] = 0x00; /* null terminate the last string */ + png_ptr->chunkdata[slength] = 0x00; /* Null terminate the last string */ - png_debug(3, "Finding end of pCAL purpose string\n"); - for (buf = purpose; *buf; buf++) - /* empty loop */ ; + png_debug(3, "Finding end of pCAL purpose string"); + for (buf = png_ptr->chunkdata; *buf; buf++) + /* Empty loop */ ; - endptr = purpose + slength; + endptr = png_ptr->chunkdata + slength; /* We need to have at least 12 bytes after the purpose string in order to get the parameter information. */ if (endptr <= buf + 12) { png_warning(png_ptr, "Invalid pCAL data"); - png_free(png_ptr, purpose); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } - png_debug(3, "Reading pCAL X0, X1, type, nparams, and units\n"); + png_debug(3, "Reading pCAL X0, X1, type, nparams, and units"); X0 = png_get_int_32((png_bytep)buf+1); X1 = png_get_int_32((png_bytep)buf+5); type = buf[9]; nparams = buf[10]; units = buf + 11; - png_debug(3, "Checking pCAL equation type and number of parameters\n"); + png_debug(3, "Checking pCAL equation type and number of parameters"); /* Check that we have the right number of parameters for known equation types. */ if ((type == PNG_EQUATION_LINEAR && nparams != 2) || @@ -1646,7 +1723,8 @@ png_handle_pCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) (type == PNG_EQUATION_HYPERBOLIC && nparams != 4)) { png_warning(png_ptr, "Invalid pCAL parameters for equation type"); - png_free(png_ptr, purpose); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } else if (type >= PNG_EQUATION_LAST) @@ -1657,12 +1735,13 @@ png_handle_pCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) for (buf = units; *buf; buf++) /* Empty loop to move past the units string. */ ; - png_debug(3, "Allocating pCAL parameters array\n"); - params = (png_charpp)png_malloc_warn(png_ptr, (png_uint_32)(nparams - *png_sizeof(png_charp))) ; + png_debug(3, "Allocating pCAL parameters array"); + params = (png_charpp)png_malloc_warn(png_ptr, + (png_uint_32)(nparams * png_sizeof(png_charp))) ; if (params == NULL) { - png_free(png_ptr, purpose); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; png_warning(png_ptr, "No memory for pCAL params."); return; } @@ -1672,7 +1751,7 @@ png_handle_pCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { buf++; /* Skip the null string terminator from previous parameter. */ - png_debug1(3, "Reading pCAL parameter %d\n", i); + png_debug1(3, "Reading pCAL parameter %d", i); for (params[i] = buf; buf <= endptr && *buf != 0x00; buf++) /* Empty loop to move past each parameter string */ ; @@ -1680,26 +1759,28 @@ png_handle_pCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) if (buf > endptr) { png_warning(png_ptr, "Invalid pCAL data"); - png_free(png_ptr, purpose); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; png_free(png_ptr, params); return; } } - png_set_pCAL(png_ptr, info_ptr, purpose, X0, X1, type, nparams, + png_set_pCAL(png_ptr, info_ptr, png_ptr->chunkdata, X0, X1, type, nparams, units, params); - png_free(png_ptr, purpose); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; png_free(png_ptr, params); } #endif -#if defined(PNG_READ_sCAL_SUPPORTED) -/* read the sCAL chunk */ +#ifdef PNG_READ_sCAL_SUPPORTED +/* Read the sCAL chunk */ void /* PRIVATE */ png_handle_sCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { - png_charp buffer, ep; + png_charp ep; #ifdef PNG_FLOATING_POINT_SUPPORTED double width, height; png_charp vp; @@ -1710,7 +1791,7 @@ png_handle_sCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) #endif png_size_t slength; - png_debug(1, "in png_handle_sCAL\n"); + png_debug(1, "in png_handle_sCAL"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before sCAL"); @@ -1727,88 +1808,113 @@ png_handle_sCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) return; } - png_debug1(2, "Allocating and reading sCAL chunk data (%lu bytes)\n", + /* Need unit type, width, \0, height: minimum 4 bytes */ + else if (length < 4) + { + png_warning(png_ptr, "sCAL chunk too short"); + png_crc_finish(png_ptr, length); + return; + } + + png_debug1(2, "Allocating and reading sCAL chunk data (%lu bytes)", length + 1); - buffer = (png_charp)png_malloc_warn(png_ptr, length + 1); - if (buffer == NULL) - { - png_warning(png_ptr, "Out of memory while processing sCAL chunk"); - return; - } + png_ptr->chunkdata = (png_charp)png_malloc_warn(png_ptr, length + 1); + if (png_ptr->chunkdata == NULL) + { + png_warning(png_ptr, "Out of memory while processing sCAL chunk"); + png_crc_finish(png_ptr, length); + return; + } slength = (png_size_t)length; - png_crc_read(png_ptr, (png_bytep)buffer, slength); + png_crc_read(png_ptr, (png_bytep)png_ptr->chunkdata, slength); if (png_crc_finish(png_ptr, 0)) { - png_free(png_ptr, buffer); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } - buffer[slength] = 0x00; /* null terminate the last string */ + png_ptr->chunkdata[slength] = 0x00; /* Null terminate the last string */ - ep = buffer + 1; /* skip unit byte */ + ep = png_ptr->chunkdata + 1; /* Skip unit byte */ #ifdef PNG_FLOATING_POINT_SUPPORTED width = png_strtod(png_ptr, ep, &vp); if (*vp) { - png_warning(png_ptr, "malformed width string in sCAL chunk"); - return; + png_warning(png_ptr, "malformed width string in sCAL chunk"); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; + return; } #else #ifdef PNG_FIXED_POINT_SUPPORTED swidth = (png_charp)png_malloc_warn(png_ptr, png_strlen(ep) + 1); if (swidth == NULL) - { - png_warning(png_ptr, "Out of memory while processing sCAL chunk width"); - return; - } - png_memcpy(swidth, ep, (png_size_t)png_strlen(ep)); + { + png_warning(png_ptr, "Out of memory while processing sCAL chunk width"); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; + return; + } + png_memcpy(swidth, ep, (png_size_t)png_strlen(ep) + 1); #endif #endif - for (ep = buffer; *ep; ep++) - /* empty loop */ ; + for (ep = png_ptr->chunkdata + 1; *ep; ep++) + /* Empty loop */ ; ep++; - if (buffer + slength < ep) + if (png_ptr->chunkdata + slength < ep) { - png_warning(png_ptr, "Truncated sCAL chunk"); -#if defined(PNG_FIXED_POINT_SUPPORTED) && \ - !defined(PNG_FLOATING_POINT_SUPPORTED) - png_free(png_ptr, swidth); + png_warning(png_ptr, "Truncated sCAL chunk"); +#if defined(PNG_FIXED_POINT_SUPPORTED) && !defined(PNG_FLOATING_POINT_SUPPORTED) + png_free(png_ptr, swidth); #endif - png_free(png_ptr, buffer); - return; + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; + return; } #ifdef PNG_FLOATING_POINT_SUPPORTED height = png_strtod(png_ptr, ep, &vp); if (*vp) { - png_warning(png_ptr, "malformed height string in sCAL chunk"); - return; + png_warning(png_ptr, "malformed height string in sCAL chunk"); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; +#if defined(PNG_FIXED_POINT_SUPPORTED) && !defined(PNG_FLOATING_POINT_SUPPORTED) + png_free(png_ptr, swidth); +#endif + return; } #else #ifdef PNG_FIXED_POINT_SUPPORTED sheight = (png_charp)png_malloc_warn(png_ptr, png_strlen(ep) + 1); - if (swidth == NULL) - { - png_warning(png_ptr, "Out of memory while processing sCAL chunk height"); - return; - } - png_memcpy(sheight, ep, (png_size_t)png_strlen(ep)); + if (sheight == NULL) + { + png_warning(png_ptr, "Out of memory while processing sCAL chunk height"); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; +#if defined(PNG_FIXED_POINT_SUPPORTED) && !defined(PNG_FLOATING_POINT_SUPPORTED) + png_free(png_ptr, swidth); +#endif + return; + } + png_memcpy(sheight, ep, (png_size_t)png_strlen(ep) + 1); #endif #endif - if (buffer + slength < ep + if (png_ptr->chunkdata + slength < ep #ifdef PNG_FLOATING_POINT_SUPPORTED || width <= 0. || height <= 0. #endif ) { png_warning(png_ptr, "Invalid sCAL data"); - png_free(png_ptr, buffer); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; #if defined(PNG_FIXED_POINT_SUPPORTED) && !defined(PNG_FLOATING_POINT_SUPPORTED) png_free(png_ptr, swidth); png_free(png_ptr, sheight); @@ -1818,14 +1924,15 @@ png_handle_sCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) #ifdef PNG_FLOATING_POINT_SUPPORTED - png_set_sCAL(png_ptr, info_ptr, buffer[0], width, height); + png_set_sCAL(png_ptr, info_ptr, png_ptr->chunkdata[0], width, height); #else #ifdef PNG_FIXED_POINT_SUPPORTED - png_set_sCAL_s(png_ptr, info_ptr, buffer[0], swidth, sheight); + png_set_sCAL_s(png_ptr, info_ptr, png_ptr->chunkdata[0], swidth, sheight); #endif #endif - png_free(png_ptr, buffer); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; #if defined(PNG_FIXED_POINT_SUPPORTED) && !defined(PNG_FLOATING_POINT_SUPPORTED) png_free(png_ptr, swidth); png_free(png_ptr, sheight); @@ -1833,14 +1940,14 @@ png_handle_sCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif -#if defined(PNG_READ_tIME_SUPPORTED) +#ifdef PNG_READ_tIME_SUPPORTED void /* PRIVATE */ png_handle_tIME(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { png_byte buf[7]; png_time mod_time; - png_debug(1, "in png_handle_tIME\n"); + png_debug(1, "in png_handle_tIME"); if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Out of place tIME chunk"); @@ -1876,7 +1983,7 @@ png_handle_tIME(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif -#if defined(PNG_READ_tEXt_SUPPORTED) +#ifdef PNG_READ_tEXt_SUPPORTED /* Note: this does not properly handle chunks that are > 64K under DOS */ void /* PRIVATE */ png_handle_tEXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) @@ -1888,7 +1995,24 @@ png_handle_tEXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_size_t slength; int ret; - png_debug(1, "in png_handle_tEXt\n"); + png_debug(1, "in png_handle_tEXt"); + +#ifdef PNG_USER_LIMITS_SUPPORTED + if (png_ptr->user_chunk_cache_max != 0) + { + if (png_ptr->user_chunk_cache_max == 1) + { + png_crc_finish(png_ptr, length); + return; + } + if (--png_ptr->user_chunk_cache_max == 1) + { + png_warning(png_ptr, "No space in chunk cache for tEXt"); + png_crc_finish(png_ptr, length); + return; + } + } +#endif if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before tEXt"); @@ -1905,25 +2029,30 @@ png_handle_tEXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif - key = (png_charp)png_malloc_warn(png_ptr, length + 1); - if (key == NULL) + png_free(png_ptr, png_ptr->chunkdata); + + png_ptr->chunkdata = (png_charp)png_malloc_warn(png_ptr, length + 1); + if (png_ptr->chunkdata == NULL) { png_warning(png_ptr, "No memory to process text chunk."); return; } slength = (png_size_t)length; - png_crc_read(png_ptr, (png_bytep)key, slength); + png_crc_read(png_ptr, (png_bytep)png_ptr->chunkdata, slength); if (png_crc_finish(png_ptr, skip)) { - png_free(png_ptr, key); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } + key = png_ptr->chunkdata; + key[slength] = 0x00; for (text = key; *text; text++) - /* empty loop to find end of key */ ; + /* Empty loop to find end of key */ ; if (text != key + slength) text++; @@ -1933,7 +2062,8 @@ png_handle_tEXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) if (text_ptr == NULL) { png_warning(png_ptr, "Not enough memory to process text chunk."); - png_free(png_ptr, key); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } text_ptr->compression = PNG_TEXT_COMPRESSION_NONE; @@ -1946,28 +2076,46 @@ png_handle_tEXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) text_ptr->text = text; text_ptr->text_length = png_strlen(text); - ret=png_set_text_2(png_ptr, info_ptr, text_ptr, 1); + ret = png_set_text_2(png_ptr, info_ptr, text_ptr, 1); - png_free(png_ptr, key); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; png_free(png_ptr, text_ptr); if (ret) png_warning(png_ptr, "Insufficient memory to process text chunk."); } #endif -#if defined(PNG_READ_zTXt_SUPPORTED) -/* note: this does not correctly handle chunks that are > 64K under DOS */ +#ifdef PNG_READ_zTXt_SUPPORTED +/* Note: this does not correctly handle chunks that are > 64K under DOS */ void /* PRIVATE */ png_handle_zTXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { png_textp text_ptr; - png_charp chunkdata; png_charp text; int comp_type; int ret; png_size_t slength, prefix_len, data_len; - png_debug(1, "in png_handle_zTXt\n"); + png_debug(1, "in png_handle_zTXt"); + +#ifdef PNG_USER_LIMITS_SUPPORTED + if (png_ptr->user_chunk_cache_max != 0) + { + if (png_ptr->user_chunk_cache_max == 1) + { + png_crc_finish(png_ptr, length); + return; + } + if (--png_ptr->user_chunk_cache_max == 1) + { + png_warning(png_ptr, "No space in chunk cache for zTXt"); + png_crc_finish(png_ptr, length); + return; + } + } +#endif + if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before zTXt"); @@ -1979,36 +2127,39 @@ png_handle_zTXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) there is no hard and fast rule to tell us where to stop. */ if (length > (png_uint_32)65535L) { - png_warning(png_ptr,"zTXt chunk too large to fit in memory"); + png_warning(png_ptr, "zTXt chunk too large to fit in memory"); png_crc_finish(png_ptr, length); return; } #endif - chunkdata = (png_charp)png_malloc_warn(png_ptr, length + 1); - if (chunkdata == NULL) + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = (png_charp)png_malloc_warn(png_ptr, length + 1); + if (png_ptr->chunkdata == NULL) { - png_warning(png_ptr,"Out of memory processing zTXt chunk."); + png_warning(png_ptr, "Out of memory processing zTXt chunk."); return; } slength = (png_size_t)length; - png_crc_read(png_ptr, (png_bytep)chunkdata, slength); + png_crc_read(png_ptr, (png_bytep)png_ptr->chunkdata, slength); if (png_crc_finish(png_ptr, 0)) { - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } - chunkdata[slength] = 0x00; + png_ptr->chunkdata[slength] = 0x00; - for (text = chunkdata; *text; text++) - /* empty loop */ ; + for (text = png_ptr->chunkdata; *text; text++) + /* Empty loop */ ; /* zTXt must have some text after the chunkdataword */ - if (text >= chunkdata + slength - 2) + if (text >= png_ptr->chunkdata + slength - 2) { png_warning(png_ptr, "Truncated zTXt chunk"); - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } else @@ -2019,54 +2170,72 @@ png_handle_zTXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_warning(png_ptr, "Unknown compression type in zTXt chunk"); comp_type = PNG_TEXT_COMPRESSION_zTXt; } - text++; /* skip the compression_method byte */ + text++; /* Skip the compression_method byte */ } - prefix_len = text - chunkdata; + prefix_len = text - png_ptr->chunkdata; - chunkdata = (png_charp)png_decompress_chunk(png_ptr, comp_type, chunkdata, - (png_size_t)length, prefix_len, &data_len); + png_decompress_chunk(png_ptr, comp_type, + (png_size_t)length, prefix_len, &data_len); text_ptr = (png_textp)png_malloc_warn(png_ptr, - (png_uint_32)png_sizeof(png_text)); + (png_uint_32)png_sizeof(png_text)); if (text_ptr == NULL) { - png_warning(png_ptr,"Not enough memory to process zTXt chunk."); - png_free(png_ptr, chunkdata); + png_warning(png_ptr, "Not enough memory to process zTXt chunk."); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } text_ptr->compression = comp_type; - text_ptr->key = chunkdata; + text_ptr->key = png_ptr->chunkdata; #ifdef PNG_iTXt_SUPPORTED text_ptr->lang = NULL; text_ptr->lang_key = NULL; text_ptr->itxt_length = 0; #endif - text_ptr->text = chunkdata + prefix_len; + text_ptr->text = png_ptr->chunkdata + prefix_len; text_ptr->text_length = data_len; - ret=png_set_text_2(png_ptr, info_ptr, text_ptr, 1); + ret = png_set_text_2(png_ptr, info_ptr, text_ptr, 1); png_free(png_ptr, text_ptr); - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; if (ret) png_error(png_ptr, "Insufficient memory to store zTXt chunk."); } #endif -#if defined(PNG_READ_iTXt_SUPPORTED) -/* note: this does not correctly handle chunks that are > 64K under DOS */ +#ifdef PNG_READ_iTXt_SUPPORTED +/* Note: this does not correctly handle chunks that are > 64K under DOS */ void /* PRIVATE */ png_handle_iTXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { png_textp text_ptr; - png_charp chunkdata; png_charp key, lang, text, lang_key; int comp_flag; int comp_type = 0; int ret; png_size_t slength, prefix_len, data_len; - png_debug(1, "in png_handle_iTXt\n"); + png_debug(1, "in png_handle_iTXt"); + +#ifdef PNG_USER_LIMITS_SUPPORTED + if (png_ptr->user_chunk_cache_max != 0) + { + if (png_ptr->user_chunk_cache_max == 1) + { + png_crc_finish(png_ptr, length); + return; + } + if (--png_ptr->user_chunk_cache_max == 1) + { + png_warning(png_ptr, "No space in chunk cache for iTXt"); + png_crc_finish(png_ptr, length); + return; + } + } +#endif if (!(png_ptr->mode & PNG_HAVE_IHDR)) png_error(png_ptr, "Missing IHDR before iTXt"); @@ -2079,40 +2248,44 @@ png_handle_iTXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) there is no hard and fast rule to tell us where to stop. */ if (length > (png_uint_32)65535L) { - png_warning(png_ptr,"iTXt chunk too large to fit in memory"); + png_warning(png_ptr, "iTXt chunk too large to fit in memory"); png_crc_finish(png_ptr, length); return; } #endif - chunkdata = (png_charp)png_malloc_warn(png_ptr, length + 1); - if (chunkdata == NULL) + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = (png_charp)png_malloc_warn(png_ptr, length + 1); + if (png_ptr->chunkdata == NULL) { png_warning(png_ptr, "No memory to process iTXt chunk."); return; } slength = (png_size_t)length; - png_crc_read(png_ptr, (png_bytep)chunkdata, slength); + png_crc_read(png_ptr, (png_bytep)png_ptr->chunkdata, slength); if (png_crc_finish(png_ptr, 0)) { - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } - chunkdata[slength] = 0x00; + png_ptr->chunkdata[slength] = 0x00; - for (lang = chunkdata; *lang; lang++) - /* empty loop */ ; - lang++; /* skip NUL separator */ + for (lang = png_ptr->chunkdata; *lang; lang++) + /* Empty loop */ ; + lang++; /* Skip NUL separator */ /* iTXt must have a language tag (possibly empty), two compression bytes, - translated keyword (possibly empty), and possibly some text after the - keyword */ + * translated keyword (possibly empty), and possibly some text after the + * keyword + */ - if (lang >= chunkdata + slength - 3) + if (lang >= png_ptr->chunkdata + slength - 3) { png_warning(png_ptr, "Truncated iTXt chunk"); - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } else @@ -2122,54 +2295,58 @@ png_handle_iTXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } for (lang_key = lang; *lang_key; lang_key++) - /* empty loop */ ; - lang_key++; /* skip NUL separator */ + /* Empty loop */ ; + lang_key++; /* Skip NUL separator */ - if (lang_key >= chunkdata + slength) + if (lang_key >= png_ptr->chunkdata + slength) { png_warning(png_ptr, "Truncated iTXt chunk"); - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } for (text = lang_key; *text; text++) - /* empty loop */ ; - text++; /* skip NUL separator */ - if (text >= chunkdata + slength) + /* Empty loop */ ; + text++; /* Skip NUL separator */ + if (text >= png_ptr->chunkdata + slength) { png_warning(png_ptr, "Malformed iTXt chunk"); - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } - prefix_len = text - chunkdata; + prefix_len = text - png_ptr->chunkdata; - key=chunkdata; + key=png_ptr->chunkdata; if (comp_flag) - chunkdata = png_decompress_chunk(png_ptr, comp_type, chunkdata, - (size_t)length, prefix_len, &data_len); + png_decompress_chunk(png_ptr, comp_type, + (size_t)length, prefix_len, &data_len); else - data_len=png_strlen(chunkdata + prefix_len); + data_len = png_strlen(png_ptr->chunkdata + prefix_len); text_ptr = (png_textp)png_malloc_warn(png_ptr, (png_uint_32)png_sizeof(png_text)); if (text_ptr == NULL) { - png_warning(png_ptr,"Not enough memory to process iTXt chunk."); - png_free(png_ptr, chunkdata); + png_warning(png_ptr, "Not enough memory to process iTXt chunk."); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; return; } text_ptr->compression = (int)comp_flag + 1; - text_ptr->lang_key = chunkdata+(lang_key-key); - text_ptr->lang = chunkdata+(lang-key); + text_ptr->lang_key = png_ptr->chunkdata + (lang_key - key); + text_ptr->lang = png_ptr->chunkdata + (lang - key); text_ptr->itxt_length = data_len; text_ptr->text_length = 0; - text_ptr->key = chunkdata; - text_ptr->text = chunkdata + prefix_len; + text_ptr->key = png_ptr->chunkdata; + text_ptr->text = png_ptr->chunkdata + prefix_len; - ret=png_set_text_2(png_ptr, info_ptr, text_ptr, 1); + ret = png_set_text_2(png_ptr, info_ptr, text_ptr, 1); png_free(png_ptr, text_ptr); - png_free(png_ptr, chunkdata); + png_free(png_ptr, png_ptr->chunkdata); + png_ptr->chunkdata = NULL; if (ret) png_error(png_ptr, "Insufficient memory to store iTXt chunk."); } @@ -2185,25 +2362,40 @@ png_handle_unknown(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) { png_uint_32 skip = 0; - png_debug(1, "in png_handle_unknown\n"); + png_debug(1, "in png_handle_unknown"); + +#ifdef PNG_USER_LIMITS_SUPPORTED + if (png_ptr->user_chunk_cache_max != 0) + { + if (png_ptr->user_chunk_cache_max == 1) + { + png_crc_finish(png_ptr, length); + return; + } + if (--png_ptr->user_chunk_cache_max == 1) + { + png_warning(png_ptr, "No space in chunk cache for unknown chunk"); + png_crc_finish(png_ptr, length); + return; + } + } +#endif if (png_ptr->mode & PNG_HAVE_IDAT) { #ifdef PNG_USE_LOCAL_ARRAYS PNG_CONST PNG_IDAT; #endif - if (png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) /* not an IDAT */ + if (png_memcmp(png_ptr->chunk_name, png_IDAT, 4)) /* Not an IDAT */ png_ptr->mode |= PNG_AFTER_IDAT; } - png_check_chunk_name(png_ptr, png_ptr->chunk_name); - if (!(png_ptr->chunk_name[0] & 0x20)) { -#if defined(PNG_READ_UNKNOWN_CHUNKS_SUPPORTED) - if(png_handle_as_unknown(png_ptr, png_ptr->chunk_name) != +#ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED + if (png_handle_as_unknown(png_ptr, png_ptr->chunk_name) != PNG_HANDLE_CHUNK_ALWAYS -#if defined(PNG_READ_USER_CHUNKS_SUPPORTED) +#ifdef PNG_READ_USER_CHUNKS_SUPPORTED && png_ptr->read_user_chunk_fn == NULL #endif ) @@ -2211,9 +2403,12 @@ png_handle_unknown(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_chunk_error(png_ptr, "unknown critical chunk"); } -#if defined(PNG_READ_UNKNOWN_CHUNKS_SUPPORTED) - if ((png_ptr->flags & PNG_FLAG_KEEP_UNKNOWN_CHUNKS) || - (png_ptr->read_user_chunk_fn != NULL)) +#ifdef PNG_READ_UNKNOWN_CHUNKS_SUPPORTED + if ((png_ptr->flags & PNG_FLAG_KEEP_UNKNOWN_CHUNKS) +#ifdef PNG_READ_USER_CHUNKS_SUPPORTED + || (png_ptr->read_user_chunk_fn != NULL) +#endif + ) { #ifdef PNG_MAX_MALLOC_64K if (length > (png_uint_32)65535L) @@ -2224,16 +2419,22 @@ png_handle_unknown(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) } #endif png_memcpy((png_charp)png_ptr->unknown_chunk.name, - (png_charp)png_ptr->chunk_name, + (png_charp)png_ptr->chunk_name, png_sizeof(png_ptr->unknown_chunk.name)); - png_ptr->unknown_chunk.name[png_sizeof(png_ptr->unknown_chunk.name)-1] = '\0'; - png_ptr->unknown_chunk.data = (png_bytep)png_malloc(png_ptr, length); + png_ptr->unknown_chunk.name[png_sizeof(png_ptr->unknown_chunk.name)-1] + = '\0'; png_ptr->unknown_chunk.size = (png_size_t)length; - png_crc_read(png_ptr, (png_bytep)png_ptr->unknown_chunk.data, length); -#if defined(PNG_READ_USER_CHUNKS_SUPPORTED) - if(png_ptr->read_user_chunk_fn != NULL) + if (length == 0) + png_ptr->unknown_chunk.data = NULL; + else + { + png_ptr->unknown_chunk.data = (png_bytep)png_malloc(png_ptr, length); + png_crc_read(png_ptr, (png_bytep)png_ptr->unknown_chunk.data, length); + } +#ifdef PNG_READ_USER_CHUNKS_SUPPORTED + if (png_ptr->read_user_chunk_fn != NULL) { - /* callback to user unknown chunk handler */ + /* Callback to user unknown chunk handler */ int ret; ret = (*(png_ptr->read_user_chunk_fn)) (png_ptr, &png_ptr->unknown_chunk); @@ -2242,16 +2443,18 @@ png_handle_unknown(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) if (ret == 0) { if (!(png_ptr->chunk_name[0] & 0x20)) - if(png_handle_as_unknown(png_ptr, png_ptr->chunk_name) != +#ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED + if (png_handle_as_unknown(png_ptr, png_ptr->chunk_name) != PNG_HANDLE_CHUNK_ALWAYS) +#endif png_chunk_error(png_ptr, "unknown critical chunk"); png_set_unknown_chunks(png_ptr, info_ptr, &png_ptr->unknown_chunk, 1); } } -#else - png_set_unknown_chunks(png_ptr, info_ptr, &png_ptr->unknown_chunk, 1); + else #endif + png_set_unknown_chunks(png_ptr, info_ptr, &png_ptr->unknown_chunk, 1); png_free(png_ptr, png_ptr->unknown_chunk.data); png_ptr->unknown_chunk.data = NULL; } @@ -2261,8 +2464,8 @@ png_handle_unknown(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_crc_finish(png_ptr, skip); -#if !defined(PNG_READ_USER_CHUNKS_SUPPORTED) - info_ptr = info_ptr; /* quiet compiler warnings about unused info_ptr */ +#ifndef PNG_READ_USER_CHUNKS_SUPPORTED + info_ptr = info_ptr; /* Quiet compiler warnings about unused info_ptr */ #endif } @@ -2277,7 +2480,7 @@ png_handle_unknown(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) void /* PRIVATE */ png_check_chunk_name(png_structp png_ptr, png_bytep chunk_name) { - png_debug(1, "in png_check_chunk_name\n"); + png_debug(1, "in png_check_chunk_name"); if (isnonalpha(chunk_name[0]) || isnonalpha(chunk_name[1]) || isnonalpha(chunk_name[2]) || isnonalpha(chunk_name[3])) { @@ -2299,7 +2502,7 @@ png_check_chunk_name(png_structp png_ptr, png_bytep chunk_name) void /* PRIVATE */ png_combine_row(png_structp png_ptr, png_bytep row, int mask) { - png_debug(1,"in png_combine_row\n"); + png_debug(1, "in png_combine_row"); if (mask == 0xff) { png_memcpy(row, png_ptr->row_buf + 1, @@ -2319,7 +2522,7 @@ png_combine_row(png_structp png_ptr, png_bytep row, int mask) png_uint_32 i; png_uint_32 row_width = png_ptr->width; -#if defined(PNG_READ_PACKSWAP_SUPPORTED) +#ifdef PNG_READ_PACKSWAP_SUPPORTED if (png_ptr->transformations & PNG_PACKSWAP) { s_start = 0; @@ -2374,7 +2577,7 @@ png_combine_row(png_structp png_ptr, png_bytep row, int mask) png_uint_32 row_width = png_ptr->width; int value; -#if defined(PNG_READ_PACKSWAP_SUPPORTED) +#ifdef PNG_READ_PACKSWAP_SUPPORTED if (png_ptr->transformations & PNG_PACKSWAP) { s_start = 0; @@ -2426,7 +2629,7 @@ png_combine_row(png_structp png_ptr, png_bytep row, int mask) png_uint_32 row_width = png_ptr->width; int value; -#if defined(PNG_READ_PACKSWAP_SUPPORTED) +#ifdef PNG_READ_PACKSWAP_SUPPORTED if (png_ptr->transformations & PNG_PACKSWAP) { s_start = 0; @@ -2509,13 +2712,11 @@ png_do_read_interlace(png_structp png_ptr) png_bytep row = png_ptr->row_buf + 1; int pass = png_ptr->pass; png_uint_32 transformations = png_ptr->transformations; -#ifdef PNG_USE_LOCAL_ARRAYS - /* arrays to facilitate easy interlacing - use pass (0 - 6) as index */ - /* offset to next interlace block */ + /* Arrays to facilitate easy interlacing - use pass (0 - 6) as index */ + /* Offset to next interlace block */ PNG_CONST int png_pass_inc[7] = {8, 8, 4, 4, 2, 2, 1}; -#endif - png_debug(1,"in png_do_read_interlace\n"); + png_debug(1, "in png_do_read_interlace"); if (row != NULL && row_info != NULL) { png_uint_32 final_width; @@ -2535,7 +2736,7 @@ png_do_read_interlace(png_structp png_ptr) png_uint_32 i; int j; -#if defined(PNG_READ_PACKSWAP_SUPPORTED) +#ifdef PNG_READ_PACKSWAP_SUPPORTED if (transformations & PNG_PACKSWAP) { sshift = (int)((row_info->width + 7) & 0x07); @@ -2588,7 +2789,7 @@ png_do_read_interlace(png_structp png_ptr) int jstop = png_pass_inc[pass]; png_uint_32 i; -#if defined(PNG_READ_PACKSWAP_SUPPORTED) +#ifdef PNG_READ_PACKSWAP_SUPPORTED if (transformations & PNG_PACKSWAP) { sshift = (int)(((row_info->width + 3) & 0x03) << 1); @@ -2644,7 +2845,7 @@ png_do_read_interlace(png_structp png_ptr) png_uint_32 i; int jstop = png_pass_inc[pass]; -#if defined(PNG_READ_PACKSWAP_SUPPORTED) +#ifdef PNG_READ_PACKSWAP_SUPPORTED if (transformations & PNG_PACKSWAP) { sshift = (int)(((row_info->width + 1) & 0x01) << 2); @@ -2693,7 +2894,8 @@ png_do_read_interlace(png_structp png_ptr) default: { png_size_t pixel_bytes = (row_info->pixel_depth >> 3); - png_bytep sp = row + (png_size_t)(row_info->width - 1) * pixel_bytes; + png_bytep sp = row + (png_size_t)(row_info->width - 1) + * pixel_bytes; png_bytep dp = row + (png_size_t)(final_width - 1) * pixel_bytes; int jstop = png_pass_inc[pass]; @@ -2716,10 +2918,10 @@ png_do_read_interlace(png_structp png_ptr) } } row_info->width = final_width; - row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth,final_width); + row_info->rowbytes = PNG_ROWBYTES(row_info->pixel_depth, final_width); } -#if !defined(PNG_READ_PACKSWAP_SUPPORTED) - transformations = transformations; /* silence compiler warning */ +#ifndef PNG_READ_PACKSWAP_SUPPORTED + transformations = transformations; /* Silence compiler warning */ #endif } #endif /* PNG_READ_INTERLACING_SUPPORTED */ @@ -2728,8 +2930,8 @@ void /* PRIVATE */ png_read_filter_row(png_structp png_ptr, png_row_infop row_info, png_bytep row, png_bytep prev_row, int filter) { - png_debug(1, "in png_read_filter_row\n"); - png_debug2(2,"row = %lu, filter = %d\n", png_ptr->row_number, filter); + png_debug(1, "in png_read_filter_row"); + png_debug2(2, "row = %lu, filter = %d", png_ptr->row_number, filter); switch (filter) { case PNG_FILTER_VALUE_NONE: @@ -2803,7 +3005,7 @@ png_read_filter_row(png_structp png_ptr, png_row_infop row_info, png_bytep row, rp++; } - for (i = 0; i < istop; i++) /* use leftover rp,pp */ + for (i = 0; i < istop; i++) /* Use leftover rp,pp */ { int a, b, c, pa, pb, pc, p; @@ -2833,7 +3035,7 @@ png_read_filter_row(png_structp png_ptr, png_row_infop row_info, png_bytep row, p = c; */ - p = (pa <= pb && pa <=pc) ? a : (pb <= pc) ? b : c; + p = (pa <= pb && pa <= pc) ? a : (pb <= pc) ? b : c; *rp = (png_byte)(((int)(*rp) + p) & 0xff); rp++; @@ -2842,35 +3044,37 @@ png_read_filter_row(png_structp png_ptr, png_row_infop row_info, png_bytep row, } default: png_warning(png_ptr, "Ignoring bad adaptive filter type"); - *row=0; + *row = 0; break; } } +#ifdef PNG_SEQUENTIAL_READ_SUPPORTED void /* PRIVATE */ png_read_finish_row(png_structp png_ptr) { -#ifdef PNG_USE_LOCAL_ARRAYS - /* arrays to facilitate easy interlacing - use pass (0 - 6) as index */ +#ifdef PNG_READ_INTERLACING_SUPPORTED + /* Arrays to facilitate easy interlacing - use pass (0 - 6) as index */ - /* start of interlace block */ + /* Start of interlace block */ PNG_CONST int png_pass_start[7] = {0, 4, 0, 2, 0, 1, 0}; - /* offset to next interlace block */ + /* Offset to next interlace block */ PNG_CONST int png_pass_inc[7] = {8, 8, 4, 4, 2, 2, 1}; - /* start of interlace block in the y direction */ + /* Start of interlace block in the y direction */ PNG_CONST int png_pass_ystart[7] = {0, 0, 4, 0, 2, 0, 1}; - /* offset to next interlace block in the y direction */ + /* Offset to next interlace block in the y direction */ PNG_CONST int png_pass_yinc[7] = {8, 8, 8, 4, 4, 2, 2}; -#endif +#endif /* PNG_READ_INTERLACING_SUPPORTED */ - png_debug(1, "in png_read_finish_row\n"); + png_debug(1, "in png_read_finish_row"); png_ptr->row_number++; if (png_ptr->row_number < png_ptr->num_rows) return; +#ifdef PNG_READ_INTERLACING_SUPPORTED if (png_ptr->interlaced) { png_ptr->row_number = 0; @@ -2886,9 +3090,6 @@ png_read_finish_row(png_structp png_ptr) png_pass_start[png_ptr->pass]) / png_pass_inc[png_ptr->pass]; - png_ptr->irowbytes = PNG_ROWBYTES(png_ptr->pixel_depth, - png_ptr->iwidth) + 1; - if (!(png_ptr->transformations & PNG_INTERLACE)) { png_ptr->num_rows = (png_ptr->height + @@ -2905,6 +3106,7 @@ png_read_finish_row(png_structp png_ptr) if (png_ptr->pass < 7) return; } +#endif /* PNG_READ_INTERLACING_SUPPORTED */ if (!(png_ptr->flags & PNG_FLAG_ZLIB_FINISHED)) { @@ -2916,7 +3118,7 @@ png_read_finish_row(png_structp png_ptr) png_ptr->zstream.next_out = (Byte *)&extra; png_ptr->zstream.avail_out = (uInt)1; - for(;;) + for (;;) { if (!(png_ptr->zstream.avail_in)) { @@ -2946,7 +3148,7 @@ png_read_finish_row(png_structp png_ptr) { if (!(png_ptr->zstream.avail_out) || png_ptr->zstream.avail_in || png_ptr->idat_size) - png_warning(png_ptr, "Extra compressed data"); + png_warning(png_ptr, "Extra compressed data."); png_ptr->mode |= PNG_AFTER_IDAT; png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED; break; @@ -2968,38 +3170,40 @@ png_read_finish_row(png_structp png_ptr) } if (png_ptr->idat_size || png_ptr->zstream.avail_in) - png_warning(png_ptr, "Extra compression data"); + png_warning(png_ptr, "Extra compression data."); inflateReset(&png_ptr->zstream); png_ptr->mode |= PNG_AFTER_IDAT; } +#endif /* PNG_SEQUENTIAL_READ_SUPPORTED */ void /* PRIVATE */ png_read_start_row(png_structp png_ptr) { -#ifdef PNG_USE_LOCAL_ARRAYS - /* arrays to facilitate easy interlacing - use pass (0 - 6) as index */ +#ifdef PNG_READ_INTERLACING_SUPPORTED + /* Arrays to facilitate easy interlacing - use pass (0 - 6) as index */ - /* start of interlace block */ + /* Start of interlace block */ PNG_CONST int png_pass_start[7] = {0, 4, 0, 2, 0, 1, 0}; - /* offset to next interlace block */ + /* Offset to next interlace block */ PNG_CONST int png_pass_inc[7] = {8, 8, 4, 4, 2, 2, 1}; - /* start of interlace block in the y direction */ + /* Start of interlace block in the y direction */ PNG_CONST int png_pass_ystart[7] = {0, 0, 4, 0, 2, 0, 1}; - /* offset to next interlace block in the y direction */ + /* Offset to next interlace block in the y direction */ PNG_CONST int png_pass_yinc[7] = {8, 8, 8, 4, 4, 2, 2}; #endif int max_pixel_depth; - png_uint_32 row_bytes; + png_size_t row_bytes; - png_debug(1, "in png_read_start_row\n"); + png_debug(1, "in png_read_start_row"); png_ptr->zstream.avail_in = 0; png_init_read_transformations(png_ptr); +#ifdef PNG_READ_INTERLACING_SUPPORTED if (png_ptr->interlaced) { if (!(png_ptr->transformations & PNG_INTERLACE)) @@ -3012,27 +3216,21 @@ png_read_start_row(png_structp png_ptr) png_pass_inc[png_ptr->pass] - 1 - png_pass_start[png_ptr->pass]) / png_pass_inc[png_ptr->pass]; - - row_bytes = PNG_ROWBYTES(png_ptr->pixel_depth,png_ptr->iwidth) + 1; - - png_ptr->irowbytes = (png_size_t)row_bytes; - if((png_uint_32)png_ptr->irowbytes != row_bytes) - png_error(png_ptr, "Rowbytes overflow in png_read_start_row"); } else +#endif /* PNG_READ_INTERLACING_SUPPORTED */ { png_ptr->num_rows = png_ptr->height; png_ptr->iwidth = png_ptr->width; - png_ptr->irowbytes = png_ptr->rowbytes + 1; } max_pixel_depth = png_ptr->pixel_depth; -#if defined(PNG_READ_PACK_SUPPORTED) +#ifdef PNG_READ_PACK_SUPPORTED if ((png_ptr->transformations & PNG_PACK) && png_ptr->bit_depth < 8) max_pixel_depth = 8; #endif -#if defined(PNG_READ_EXPAND_SUPPORTED) +#ifdef PNG_READ_EXPAND_SUPPORTED if (png_ptr->transformations & PNG_EXPAND) { if (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE) @@ -3060,7 +3258,7 @@ png_read_start_row(png_structp png_ptr) } #endif -#if defined(PNG_READ_FILLER_SUPPORTED) +#ifdef PNG_READ_FILLER_SUPPORTED if (png_ptr->transformations & (PNG_FILLER)) { if (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE) @@ -3082,14 +3280,14 @@ png_read_start_row(png_structp png_ptr) } #endif -#if defined(PNG_READ_GRAY_TO_RGB_SUPPORTED) +#ifdef PNG_READ_GRAY_TO_RGB_SUPPORTED if (png_ptr->transformations & PNG_GRAY_TO_RGB) { if ( -#if defined(PNG_READ_EXPAND_SUPPORTED) +#ifdef PNG_READ_EXPAND_SUPPORTED (png_ptr->num_trans && (png_ptr->transformations & PNG_EXPAND)) || #endif -#if defined(PNG_READ_FILLER_SUPPORTED) +#ifdef PNG_READ_FILLER_SUPPORTED (png_ptr->transformations & (PNG_FILLER)) || #endif png_ptr->color_type == PNG_COLOR_TYPE_GRAY_ALPHA) @@ -3118,46 +3316,70 @@ png_read_start_row(png_structp png_ptr) #if defined(PNG_READ_USER_TRANSFORM_SUPPORTED) && \ defined(PNG_USER_TRANSFORM_PTR_SUPPORTED) - if(png_ptr->transformations & PNG_USER_TRANSFORM) + if (png_ptr->transformations & PNG_USER_TRANSFORM) { - int user_pixel_depth=png_ptr->user_transform_depth* + int user_pixel_depth = png_ptr->user_transform_depth* png_ptr->user_transform_channels; - if(user_pixel_depth > max_pixel_depth) + if (user_pixel_depth > max_pixel_depth) max_pixel_depth=user_pixel_depth; } #endif - /* align the width on the next larger 8 pixels. Mainly used - for interlacing */ + /* Align the width on the next larger 8 pixels. Mainly used + * for interlacing + */ row_bytes = ((png_ptr->width + 7) & ~((png_uint_32)7)); - /* calculate the maximum bytes needed, adding a byte and a pixel - for safety's sake */ - row_bytes = PNG_ROWBYTES(max_pixel_depth,row_bytes) + + /* Calculate the maximum bytes needed, adding a byte and a pixel + * for safety's sake + */ + row_bytes = PNG_ROWBYTES(max_pixel_depth, row_bytes) + 1 + ((max_pixel_depth + 7) >> 3); #ifdef PNG_MAX_MALLOC_64K if (row_bytes > (png_uint_32)65536L) png_error(png_ptr, "This image requires a row greater than 64KB"); #endif - png_ptr->big_row_buf = (png_bytep)png_malloc(png_ptr, row_bytes+64); - png_ptr->row_buf = png_ptr->big_row_buf+32; + + if (row_bytes + 64 > png_ptr->old_big_row_buf_size) + { + png_free(png_ptr, png_ptr->big_row_buf); + if (png_ptr->interlaced) + png_ptr->big_row_buf = (png_bytep)png_calloc(png_ptr, + row_bytes + 64); + else + png_ptr->big_row_buf = (png_bytep)png_malloc(png_ptr, + row_bytes + 64); + png_ptr->old_big_row_buf_size = row_bytes + 64; + + /* Use 32 bytes of padding before and after row_buf. */ + png_ptr->row_buf = png_ptr->big_row_buf + 32; + png_ptr->old_big_row_buf_size = row_bytes + 64; + } #ifdef PNG_MAX_MALLOC_64K - if ((png_uint_32)png_ptr->rowbytes + 1 > (png_uint_32)65536L) + if ((png_uint_32)row_bytes + 1 > (png_uint_32)65536L) png_error(png_ptr, "This image requires a row greater than 64KB"); #endif - if ((png_uint_32)png_ptr->rowbytes > (png_uint_32)(PNG_SIZE_MAX - 1)) + if ((png_uint_32)row_bytes > (png_uint_32)(PNG_SIZE_MAX - 1)) png_error(png_ptr, "Row has too many bytes to allocate in memory."); - png_ptr->prev_row = (png_bytep)png_malloc(png_ptr, (png_uint_32)( - png_ptr->rowbytes + 1)); - png_memset_check(png_ptr, png_ptr->prev_row, 0, png_ptr->rowbytes + 1); + if (row_bytes + 1 > png_ptr->old_prev_row_size) + { + png_free(png_ptr, png_ptr->prev_row); + png_ptr->prev_row = (png_bytep)png_malloc(png_ptr, (png_uint_32)( + row_bytes + 1)); + png_memset_check(png_ptr, png_ptr->prev_row, 0, row_bytes + 1); + png_ptr->old_prev_row_size = row_bytes + 1; + } + + png_ptr->rowbytes = row_bytes; - png_debug1(3, "width = %lu,\n", png_ptr->width); - png_debug1(3, "height = %lu,\n", png_ptr->height); - png_debug1(3, "iwidth = %lu,\n", png_ptr->iwidth); - png_debug1(3, "num_rows = %lu\n", png_ptr->num_rows); - png_debug1(3, "rowbytes = %lu,\n", png_ptr->rowbytes); - png_debug1(3, "irowbytes = %lu,\n", png_ptr->irowbytes); + png_debug1(3, "width = %lu,", png_ptr->width); + png_debug1(3, "height = %lu,", png_ptr->height); + png_debug1(3, "iwidth = %lu,", png_ptr->iwidth); + png_debug1(3, "num_rows = %lu,", png_ptr->num_rows); + png_debug1(3, "rowbytes = %lu,", png_ptr->rowbytes); + png_debug1(3, "irowbytes = %lu", + PNG_ROWBYTES(png_ptr->pixel_depth, png_ptr->iwidth) + 1); png_ptr->flags |= PNG_FLAG_ROW_INIT; } diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngset.c b/graf2d/asimage/src/libAfterImage/libpng/pngset.c index 447c3f8acdc45..72d89fcf47ced 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngset.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngset.c @@ -1,12 +1,15 @@ /* pngset.c - storage of image information into info struct * - * Last changed in libpng 1.2.22 [November 6, 2007] - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * Last changed in libpng 1.2.49 [March 29, 2012] + * Copyright (c) 1998-2012 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h + * * The functions here are used during reads to store data from the file * into the info struct, and during writes to store application data * into the info struct for writing into the file. This abstracts the @@ -14,15 +17,16 @@ */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" - #if defined(PNG_READ_SUPPORTED) || defined(PNG_WRITE_SUPPORTED) -#if defined(PNG_bKGD_SUPPORTED) +#ifdef PNG_bKGD_SUPPORTED void PNGAPI png_set_bKGD(png_structp png_ptr, png_infop info_ptr, png_color_16p background) { - png_debug1(1, "in %s storage function\n", "bKGD"); + png_debug1(1, "in %s storage function", "bKGD"); + if (png_ptr == NULL || info_ptr == NULL) return; @@ -31,41 +35,17 @@ png_set_bKGD(png_structp png_ptr, png_infop info_ptr, png_color_16p background) } #endif -#if defined(PNG_cHRM_SUPPORTED) +#ifdef PNG_cHRM_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED void PNGAPI png_set_cHRM(png_structp png_ptr, png_infop info_ptr, double white_x, double white_y, double red_x, double red_y, double green_x, double green_y, double blue_x, double blue_y) { - png_debug1(1, "in %s storage function\n", "cHRM"); + png_debug1(1, "in %s storage function", "cHRM"); + if (png_ptr == NULL || info_ptr == NULL) return; - if (!(white_x || white_y || red_x || red_y || green_x || green_y || - blue_x || blue_y)) - { - png_warning(png_ptr, - "Ignoring attempt to set all-zero chromaticity values"); - return; - } - if (white_x < 0.0 || white_y < 0.0 || - red_x < 0.0 || red_y < 0.0 || - green_x < 0.0 || green_y < 0.0 || - blue_x < 0.0 || blue_y < 0.0) - { - png_warning(png_ptr, - "Ignoring attempt to set negative chromaticity value"); - return; - } - if (white_x > 21474.83 || white_y > 21474.83 || - red_x > 21474.83 || red_y > 21474.83 || - green_x > 21474.83 || green_y > 21474.83 || - blue_x > 21474.83 || blue_y > 21474.83) - { - png_warning(png_ptr, - "Ignoring attempt to set chromaticity value exceeding 21474.83"); - return; - } info_ptr->x_white = (float)white_x; info_ptr->y_white = (float)white_y; @@ -87,7 +67,8 @@ png_set_cHRM(png_structp png_ptr, png_infop info_ptr, #endif info_ptr->valid |= PNG_INFO_cHRM; } -#endif +#endif /* PNG_FLOATING_POINT_SUPPORTED */ + #ifdef PNG_FIXED_POINT_SUPPORTED void PNGAPI png_set_cHRM_fixed(png_structp png_ptr, png_infop info_ptr, @@ -95,80 +76,49 @@ png_set_cHRM_fixed(png_structp png_ptr, png_infop info_ptr, png_fixed_point red_y, png_fixed_point green_x, png_fixed_point green_y, png_fixed_point blue_x, png_fixed_point blue_y) { - png_debug1(1, "in %s storage function\n", "cHRM"); + png_debug1(1, "in %s storage function", "cHRM fixed"); + if (png_ptr == NULL || info_ptr == NULL) return; - if (!(white_x || white_y || red_x || red_y || green_x || green_y || - blue_x || blue_y)) - { - png_warning(png_ptr, - "Ignoring attempt to set all-zero chromaticity values"); - return; - } - if (white_x < 0 || white_y < 0 || - red_x < 0 || red_y < 0 || - green_x < 0 || green_y < 0 || - blue_x < 0 || blue_y < 0) - { - png_warning(png_ptr, - "Ignoring attempt to set negative chromaticity value"); - return; - } -#ifdef PNG_FLOATING_POINT_SUPPORTED - if (white_x > (double) PNG_UINT_31_MAX || - white_y > (double) PNG_UINT_31_MAX || - red_x > (double) PNG_UINT_31_MAX || - red_y > (double) PNG_UINT_31_MAX || - green_x > (double) PNG_UINT_31_MAX || - green_y > (double) PNG_UINT_31_MAX || - blue_x > (double) PNG_UINT_31_MAX || - blue_y > (double) PNG_UINT_31_MAX) -#else - if (white_x > (png_fixed_point) PNG_UINT_31_MAX/100000L || - white_y > (png_fixed_point) PNG_UINT_31_MAX/100000L || - red_x > (png_fixed_point) PNG_UINT_31_MAX/100000L || - red_y > (png_fixed_point) PNG_UINT_31_MAX/100000L || - green_x > (png_fixed_point) PNG_UINT_31_MAX/100000L || - green_y > (png_fixed_point) PNG_UINT_31_MAX/100000L || - blue_x > (png_fixed_point) PNG_UINT_31_MAX/100000L || - blue_y > (png_fixed_point) PNG_UINT_31_MAX/100000L) +#ifdef PNG_CHECK_cHRM_SUPPORTED + if (png_check_cHRM_fixed(png_ptr, + white_x, white_y, red_x, red_y, green_x, green_y, blue_x, blue_y)) #endif { - png_warning(png_ptr, - "Ignoring attempt to set chromaticity value exceeding 21474.83"); - return; + info_ptr->int_x_white = white_x; + info_ptr->int_y_white = white_y; + info_ptr->int_x_red = red_x; + info_ptr->int_y_red = red_y; + info_ptr->int_x_green = green_x; + info_ptr->int_y_green = green_y; + info_ptr->int_x_blue = blue_x; + info_ptr->int_y_blue = blue_y; +#ifdef PNG_FLOATING_POINT_SUPPORTED + info_ptr->x_white = (float)(white_x/100000.); + info_ptr->y_white = (float)(white_y/100000.); + info_ptr->x_red = (float)( red_x/100000.); + info_ptr->y_red = (float)( red_y/100000.); + info_ptr->x_green = (float)(green_x/100000.); + info_ptr->y_green = (float)(green_y/100000.); + info_ptr->x_blue = (float)( blue_x/100000.); + info_ptr->y_blue = (float)( blue_y/100000.); +#endif + info_ptr->valid |= PNG_INFO_cHRM; } - info_ptr->int_x_white = white_x; - info_ptr->int_y_white = white_y; - info_ptr->int_x_red = red_x; - info_ptr->int_y_red = red_y; - info_ptr->int_x_green = green_x; - info_ptr->int_y_green = green_y; - info_ptr->int_x_blue = blue_x; - info_ptr->int_y_blue = blue_y; -#ifdef PNG_FLOATING_POINT_SUPPORTED - info_ptr->x_white = (float)(white_x/100000.); - info_ptr->y_white = (float)(white_y/100000.); - info_ptr->x_red = (float)( red_x/100000.); - info_ptr->y_red = (float)( red_y/100000.); - info_ptr->x_green = (float)(green_x/100000.); - info_ptr->y_green = (float)(green_y/100000.); - info_ptr->x_blue = (float)( blue_x/100000.); - info_ptr->y_blue = (float)( blue_y/100000.); -#endif - info_ptr->valid |= PNG_INFO_cHRM; } -#endif -#endif +#endif /* PNG_FIXED_POINT_SUPPORTED */ +#endif /* PNG_cHRM_SUPPORTED */ -#if defined(PNG_gAMA_SUPPORTED) +#ifdef PNG_gAMA_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED void PNGAPI png_set_gAMA(png_structp png_ptr, png_infop info_ptr, double file_gamma) { - double gamma; - png_debug1(1, "in %s storage function\n", "gAMA"); + double png_gamma; + + png_debug1(1, "in %s storage function", "gAMA"); + if (png_ptr == NULL || info_ptr == NULL) return; @@ -176,16 +126,16 @@ png_set_gAMA(png_structp png_ptr, png_infop info_ptr, double file_gamma) if (file_gamma > 21474.83) { png_warning(png_ptr, "Limiting gamma to 21474.83"); - gamma=21474.83; + png_gamma=21474.83; } else - gamma=file_gamma; - info_ptr->gamma = (float)gamma; + png_gamma = file_gamma; + info_ptr->gamma = (float)png_gamma; #ifdef PNG_FIXED_POINT_SUPPORTED - info_ptr->int_gamma = (int)(gamma*100000.+.5); + info_ptr->int_gamma = (int)(png_gamma*100000.+.5); #endif info_ptr->valid |= PNG_INFO_gAMA; - if(gamma == 0.0) + if (png_gamma == 0.0) png_warning(png_ptr, "Setting gamma=0"); } #endif @@ -193,71 +143,75 @@ void PNGAPI png_set_gAMA_fixed(png_structp png_ptr, png_infop info_ptr, png_fixed_point int_gamma) { - png_fixed_point gamma; + png_fixed_point png_gamma; + + png_debug1(1, "in %s storage function", "gAMA"); - png_debug1(1, "in %s storage function\n", "gAMA"); if (png_ptr == NULL || info_ptr == NULL) return; - if (int_gamma > (png_fixed_point) PNG_UINT_31_MAX) + if (int_gamma > (png_fixed_point)PNG_UINT_31_MAX) { - png_warning(png_ptr, "Limiting gamma to 21474.83"); - gamma=PNG_UINT_31_MAX; + png_warning(png_ptr, "Limiting gamma to 21474.83"); + png_gamma=PNG_UINT_31_MAX; } else { - if (int_gamma < 0) - { - png_warning(png_ptr, "Setting negative gamma to zero"); - gamma=0; - } - else - gamma=int_gamma; + if (int_gamma < 0) + { + png_warning(png_ptr, "Setting negative gamma to zero"); + png_gamma = 0; + } + else + png_gamma = int_gamma; } #ifdef PNG_FLOATING_POINT_SUPPORTED - info_ptr->gamma = (float)(gamma/100000.); + info_ptr->gamma = (float)(png_gamma/100000.); #endif #ifdef PNG_FIXED_POINT_SUPPORTED - info_ptr->int_gamma = gamma; + info_ptr->int_gamma = png_gamma; #endif info_ptr->valid |= PNG_INFO_gAMA; - if(gamma == 0) + if (png_gamma == 0) png_warning(png_ptr, "Setting gamma=0"); } #endif -#if defined(PNG_hIST_SUPPORTED) +#ifdef PNG_hIST_SUPPORTED void PNGAPI png_set_hIST(png_structp png_ptr, png_infop info_ptr, png_uint_16p hist) { int i; - png_debug1(1, "in %s storage function\n", "hIST"); + png_debug1(1, "in %s storage function", "hIST"); + if (png_ptr == NULL || info_ptr == NULL) return; + if (info_ptr->num_palette == 0 || info_ptr->num_palette > PNG_MAX_PALETTE_LENGTH) { - png_warning(png_ptr, - "Invalid palette size, hIST allocation skipped."); - return; + png_warning(png_ptr, + "Invalid palette size, hIST allocation skipped."); + return; } #ifdef PNG_FREE_ME_SUPPORTED png_free_data(png_ptr, info_ptr, PNG_FREE_HIST, 0); #endif - /* Changed from info->num_palette to PNG_MAX_PALETTE_LENGTH in version - 1.2.1 */ + /* Changed from info->num_palette to PNG_MAX_PALETTE_LENGTH in + * version 1.2.1 + */ png_ptr->hist = (png_uint_16p)png_malloc_warn(png_ptr, - (png_uint_32)(PNG_MAX_PALETTE_LENGTH * png_sizeof (png_uint_16))); + (png_uint_32)(PNG_MAX_PALETTE_LENGTH * png_sizeof(png_uint_16))); if (png_ptr->hist == NULL) - { - png_warning(png_ptr, "Insufficient memory for hIST chunk data."); - return; - } + { + png_warning(png_ptr, "Insufficient memory for hIST chunk data."); + return; + } for (i = 0; i < info_ptr->num_palette; i++) - png_ptr->hist[i] = hist[i]; + png_ptr->hist[i] = hist[i]; info_ptr->hist = png_ptr->hist; info_ptr->valid |= PNG_INFO_hIST; @@ -275,86 +229,23 @@ png_set_IHDR(png_structp png_ptr, png_infop info_ptr, int color_type, int interlace_type, int compression_type, int filter_type) { - png_debug1(1, "in %s storage function\n", "IHDR"); + png_debug1(1, "in %s storage function", "IHDR"); + if (png_ptr == NULL || info_ptr == NULL) return; - /* check for width and height valid values */ - if (width == 0 || height == 0) - png_error(png_ptr, "Image width or height is zero in IHDR"); -#ifdef PNG_SET_USER_LIMITS_SUPPORTED - if (width > png_ptr->user_width_max || height > png_ptr->user_height_max) - png_error(png_ptr, "image size exceeds user limits in IHDR"); -#else - if (width > PNG_USER_WIDTH_MAX || height > PNG_USER_HEIGHT_MAX) - png_error(png_ptr, "image size exceeds user limits in IHDR"); -#endif - if (width > PNG_UINT_31_MAX || height > PNG_UINT_31_MAX) - png_error(png_ptr, "Invalid image size in IHDR"); - if ( width > (PNG_UINT_32_MAX - >> 3) /* 8-byte RGBA pixels */ - - 64 /* bigrowbuf hack */ - - 1 /* filter byte */ - - 7*8 /* rounding of width to multiple of 8 pixels */ - - 8) /* extra max_pixel_depth pad */ - png_warning(png_ptr, "Width is too large for libpng to process pixels"); - - /* check other values */ - if (bit_depth != 1 && bit_depth != 2 && bit_depth != 4 && - bit_depth != 8 && bit_depth != 16) - png_error(png_ptr, "Invalid bit depth in IHDR"); - - if (color_type < 0 || color_type == 1 || - color_type == 5 || color_type > 6) - png_error(png_ptr, "Invalid color type in IHDR"); - - if (((color_type == PNG_COLOR_TYPE_PALETTE) && bit_depth > 8) || - ((color_type == PNG_COLOR_TYPE_RGB || - color_type == PNG_COLOR_TYPE_GRAY_ALPHA || - color_type == PNG_COLOR_TYPE_RGB_ALPHA) && bit_depth < 8)) - png_error(png_ptr, "Invalid color type/bit depth combination in IHDR"); - - if (interlace_type >= PNG_INTERLACE_LAST) - png_error(png_ptr, "Unknown interlace method in IHDR"); - - if (compression_type != PNG_COMPRESSION_TYPE_BASE) - png_error(png_ptr, "Unknown compression method in IHDR"); - -#if defined(PNG_MNG_FEATURES_SUPPORTED) - /* Accept filter_method 64 (intrapixel differencing) only if - * 1. Libpng was compiled with PNG_MNG_FEATURES_SUPPORTED and - * 2. Libpng did not read a PNG signature (this filter_method is only - * used in PNG datastreams that are embedded in MNG datastreams) and - * 3. The application called png_permit_mng_features with a mask that - * included PNG_FLAG_MNG_FILTER_64 and - * 4. The filter_method is 64 and - * 5. The color_type is RGB or RGBA - */ - if((png_ptr->mode&PNG_HAVE_PNG_SIGNATURE)&&png_ptr->mng_features_permitted) - png_warning(png_ptr,"MNG features are not allowed in a PNG datastream"); - if(filter_type != PNG_FILTER_TYPE_BASE) - { - if(!((png_ptr->mng_features_permitted & PNG_FLAG_MNG_FILTER_64) && - (filter_type == PNG_INTRAPIXEL_DIFFERENCING) && - ((png_ptr->mode&PNG_HAVE_PNG_SIGNATURE) == 0) && - (color_type == PNG_COLOR_TYPE_RGB || - color_type == PNG_COLOR_TYPE_RGB_ALPHA))) - png_error(png_ptr, "Unknown filter method in IHDR"); - if(png_ptr->mode&PNG_HAVE_PNG_SIGNATURE) - png_warning(png_ptr, "Invalid filter method in IHDR"); - } -#else - if(filter_type != PNG_FILTER_TYPE_BASE) - png_error(png_ptr, "Unknown filter method in IHDR"); -#endif - info_ptr->width = width; info_ptr->height = height; info_ptr->bit_depth = (png_byte)bit_depth; - info_ptr->color_type =(png_byte) color_type; + info_ptr->color_type = (png_byte)color_type; info_ptr->compression_type = (png_byte)compression_type; info_ptr->filter_type = (png_byte)filter_type; info_ptr->interlace_type = (png_byte)interlace_type; + + png_check_IHDR (png_ptr, info_ptr->width, info_ptr->height, + info_ptr->bit_depth, info_ptr->color_type, info_ptr->interlace_type, + info_ptr->compression_type, info_ptr->filter_type); + if (info_ptr->color_type == PNG_COLOR_TYPE_PALETTE) info_ptr->channels = 1; else if (info_ptr->color_type & PNG_COLOR_MASK_COLOR) @@ -365,7 +256,7 @@ png_set_IHDR(png_structp png_ptr, png_infop info_ptr, info_ptr->channels++; info_ptr->pixel_depth = (png_byte)(info_ptr->channels * info_ptr->bit_depth); - /* check for potential overflow */ + /* Check for potential overflow */ if (width > (PNG_UINT_32_MAX >> 3) /* 8-byte RGBA pixels */ - 64 /* bigrowbuf hack */ @@ -374,15 +265,16 @@ png_set_IHDR(png_structp png_ptr, png_infop info_ptr, - 8) /* extra max_pixel_depth pad */ info_ptr->rowbytes = (png_size_t)0; else - info_ptr->rowbytes = PNG_ROWBYTES(info_ptr->pixel_depth,width); + info_ptr->rowbytes = PNG_ROWBYTES(info_ptr->pixel_depth, width); } -#if defined(PNG_oFFs_SUPPORTED) +#ifdef PNG_oFFs_SUPPORTED void PNGAPI png_set_oFFs(png_structp png_ptr, png_infop info_ptr, png_int_32 offset_x, png_int_32 offset_y, int unit_type) { - png_debug1(1, "in %s storage function\n", "oFFs"); + png_debug1(1, "in %s storage function", "oFFs"); + if (png_ptr == NULL || info_ptr == NULL) return; @@ -393,7 +285,7 @@ png_set_oFFs(png_structp png_ptr, png_infop info_ptr, } #endif -#if defined(PNG_pCAL_SUPPORTED) +#ifdef PNG_pCAL_SUPPORTED void PNGAPI png_set_pCAL(png_structp png_ptr, png_infop info_ptr, png_charp purpose, png_int_32 X0, png_int_32 X1, int type, int nparams, @@ -402,56 +294,60 @@ png_set_pCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length; int i; - png_debug1(1, "in %s storage function\n", "pCAL"); + png_debug1(1, "in %s storage function", "pCAL"); + if (png_ptr == NULL || info_ptr == NULL) return; length = png_strlen(purpose) + 1; - png_debug1(3, "allocating purpose for info (%lu bytes)\n", length); + png_debug1(3, "allocating purpose for info (%lu bytes)", + (unsigned long)length); info_ptr->pcal_purpose = (png_charp)png_malloc_warn(png_ptr, length); if (info_ptr->pcal_purpose == NULL) - { - png_warning(png_ptr, "Insufficient memory for pCAL purpose."); - return; - } + { + png_warning(png_ptr, "Insufficient memory for pCAL purpose."); + return; + } png_memcpy(info_ptr->pcal_purpose, purpose, (png_size_t)length); - png_debug(3, "storing X0, X1, type, and nparams in info\n"); + png_debug(3, "storing X0, X1, type, and nparams in info"); info_ptr->pcal_X0 = X0; info_ptr->pcal_X1 = X1; info_ptr->pcal_type = (png_byte)type; info_ptr->pcal_nparams = (png_byte)nparams; length = png_strlen(units) + 1; - png_debug1(3, "allocating units for info (%lu bytes)\n", length); + png_debug1(3, "allocating units for info (%lu bytes)", + (unsigned long)length); info_ptr->pcal_units = (png_charp)png_malloc_warn(png_ptr, length); if (info_ptr->pcal_units == NULL) - { - png_warning(png_ptr, "Insufficient memory for pCAL units."); - return; - } + { + png_warning(png_ptr, "Insufficient memory for pCAL units."); + return; + } png_memcpy(info_ptr->pcal_units, units, (png_size_t)length); info_ptr->pcal_params = (png_charpp)png_malloc_warn(png_ptr, (png_uint_32)((nparams + 1) * png_sizeof(png_charp))); if (info_ptr->pcal_params == NULL) - { - png_warning(png_ptr, "Insufficient memory for pCAL params."); - return; - } + { + png_warning(png_ptr, "Insufficient memory for pCAL params."); + return; + } - info_ptr->pcal_params[nparams] = NULL; + png_memset(info_ptr->pcal_params, 0, (nparams + 1) * png_sizeof(png_charp)); for (i = 0; i < nparams; i++) { length = png_strlen(params[i]) + 1; - png_debug2(3, "allocating parameter %d for info (%lu bytes)\n", i, length); + png_debug2(3, "allocating parameter %d for info (%lu bytes)", i, + (unsigned long)length); info_ptr->pcal_params[i] = (png_charp)png_malloc_warn(png_ptr, length); if (info_ptr->pcal_params[i] == NULL) - { - png_warning(png_ptr, "Insufficient memory for pCAL parameter."); - return; - } + { + png_warning(png_ptr, "Insufficient memory for pCAL parameter."); + return; + } png_memcpy(info_ptr->pcal_params[i], params[i], (png_size_t)length); } @@ -468,7 +364,8 @@ void PNGAPI png_set_sCAL(png_structp png_ptr, png_infop info_ptr, int unit, double width, double height) { - png_debug1(1, "in %s storage function\n", "sCAL"); + png_debug1(1, "in %s storage function", "sCAL"); + if (png_ptr == NULL || info_ptr == NULL) return; @@ -486,33 +383,38 @@ png_set_sCAL_s(png_structp png_ptr, png_infop info_ptr, { png_uint_32 length; - png_debug1(1, "in %s storage function\n", "sCAL"); + png_debug1(1, "in %s storage function", "sCAL"); + if (png_ptr == NULL || info_ptr == NULL) return; info_ptr->scal_unit = (png_byte)unit; length = png_strlen(swidth) + 1; - png_debug1(3, "allocating unit for info (%d bytes)\n", length); + png_debug1(3, "allocating unit for info (%u bytes)", + (unsigned int)length); info_ptr->scal_s_width = (png_charp)png_malloc_warn(png_ptr, length); if (info_ptr->scal_s_width == NULL) { png_warning(png_ptr, - "Memory allocation failed while processing sCAL."); + "Memory allocation failed while processing sCAL."); + return; } png_memcpy(info_ptr->scal_s_width, swidth, (png_size_t)length); length = png_strlen(sheight) + 1; - png_debug1(3, "allocating unit for info (%d bytes)\n", length); + png_debug1(3, "allocating unit for info (%u bytes)", + (unsigned int)length); info_ptr->scal_s_height = (png_charp)png_malloc_warn(png_ptr, length); if (info_ptr->scal_s_height == NULL) { png_free (png_ptr, info_ptr->scal_s_width); + info_ptr->scal_s_width = NULL; png_warning(png_ptr, - "Memory allocation failed while processing sCAL."); + "Memory allocation failed while processing sCAL."); + return; } png_memcpy(info_ptr->scal_s_height, sheight, (png_size_t)length); - info_ptr->valid |= PNG_INFO_sCAL; #ifdef PNG_FREE_ME_SUPPORTED info_ptr->free_me |= PNG_FREE_SCAL; @@ -522,12 +424,13 @@ png_set_sCAL_s(png_structp png_ptr, png_infop info_ptr, #endif #endif -#if defined(PNG_pHYs_SUPPORTED) +#ifdef PNG_pHYs_SUPPORTED void PNGAPI png_set_pHYs(png_structp png_ptr, png_infop info_ptr, png_uint_32 res_x, png_uint_32 res_y, int unit_type) { - png_debug1(1, "in %s storage function\n", "pHYs"); + png_debug1(1, "in %s storage function", "pHYs"); + if (png_ptr == NULL || info_ptr == NULL) return; @@ -543,23 +446,23 @@ png_set_PLTE(png_structp png_ptr, png_infop info_ptr, png_colorp palette, int num_palette) { - png_debug1(1, "in %s storage function\n", "PLTE"); + png_debug1(1, "in %s storage function", "PLTE"); + if (png_ptr == NULL || info_ptr == NULL) return; if (num_palette < 0 || num_palette > PNG_MAX_PALETTE_LENGTH) - { - if (info_ptr->color_type == PNG_COLOR_TYPE_PALETTE) + { + if (info_ptr->color_type == PNG_COLOR_TYPE_PALETTE) png_error(png_ptr, "Invalid palette length"); - else - { + else + { png_warning(png_ptr, "Invalid palette length"); return; - } - } + } + } - /* - * It may not actually be necessary to set png_ptr->palette here; + /* It may not actually be necessary to set png_ptr->palette here; * we do it for backward compatibility with the way the png_handle_tRNS * function used to do the allocation. */ @@ -568,13 +471,12 @@ png_set_PLTE(png_structp png_ptr, png_infop info_ptr, #endif /* Changed in libpng-1.2.1 to allocate PNG_MAX_PALETTE_LENGTH instead - of num_palette entries, - in case of an invalid PNG file that has too-large sample values. */ - png_ptr->palette = (png_colorp)png_malloc(png_ptr, + * of num_palette entries, in case of an invalid PNG file that has + * too-large sample values. + */ + png_ptr->palette = (png_colorp)png_calloc(png_ptr, PNG_MAX_PALETTE_LENGTH * png_sizeof(png_color)); - png_memset(png_ptr->palette, 0, PNG_MAX_PALETTE_LENGTH * - png_sizeof(png_color)); - png_memcpy(png_ptr->palette, palette, num_palette * png_sizeof (png_color)); + png_memcpy(png_ptr->palette, palette, num_palette * png_sizeof(png_color)); info_ptr->palette = png_ptr->palette; info_ptr->num_palette = png_ptr->num_palette = (png_uint_16)num_palette; @@ -587,25 +489,27 @@ png_set_PLTE(png_structp png_ptr, png_infop info_ptr, info_ptr->valid |= PNG_INFO_PLTE; } -#if defined(PNG_sBIT_SUPPORTED) +#ifdef PNG_sBIT_SUPPORTED void PNGAPI png_set_sBIT(png_structp png_ptr, png_infop info_ptr, png_color_8p sig_bit) { - png_debug1(1, "in %s storage function\n", "sBIT"); + png_debug1(1, "in %s storage function", "sBIT"); + if (png_ptr == NULL || info_ptr == NULL) return; - png_memcpy(&(info_ptr->sig_bit), sig_bit, png_sizeof (png_color_8)); + png_memcpy(&(info_ptr->sig_bit), sig_bit, png_sizeof(png_color_8)); info_ptr->valid |= PNG_INFO_sBIT; } #endif -#if defined(PNG_sRGB_SUPPORTED) +#ifdef PNG_sRGB_SUPPORTED void PNGAPI png_set_sRGB(png_structp png_ptr, png_infop info_ptr, int intent) { - png_debug1(1, "in %s storage function\n", "sRGB"); + png_debug1(1, "in %s storage function", "sRGB"); + if (png_ptr == NULL || info_ptr == NULL) return; @@ -617,7 +521,7 @@ void PNGAPI png_set_sRGB_gAMA_and_cHRM(png_structp png_ptr, png_infop info_ptr, int intent) { -#if defined(PNG_gAMA_SUPPORTED) +#ifdef PNG_gAMA_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED float file_gamma; #endif @@ -625,22 +529,21 @@ png_set_sRGB_gAMA_and_cHRM(png_structp png_ptr, png_infop info_ptr, png_fixed_point int_file_gamma; #endif #endif -#if defined(PNG_cHRM_SUPPORTED) +#ifdef PNG_cHRM_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED float white_x, white_y, red_x, red_y, green_x, green_y, blue_x, blue_y; #endif -#ifdef PNG_FIXED_POINT_SUPPORTED png_fixed_point int_white_x, int_white_y, int_red_x, int_red_y, int_green_x, int_green_y, int_blue_x, int_blue_y; #endif -#endif - png_debug1(1, "in %s storage function\n", "sRGB_gAMA_and_cHRM"); + png_debug1(1, "in %s storage function", "sRGB_gAMA_and_cHRM"); + if (png_ptr == NULL || info_ptr == NULL) return; png_set_sRGB(png_ptr, info_ptr, intent); -#if defined(PNG_gAMA_SUPPORTED) +#ifdef PNG_gAMA_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED file_gamma = (float).45455; png_set_gAMA(png_ptr, info_ptr, file_gamma); @@ -651,8 +554,7 @@ png_set_sRGB_gAMA_and_cHRM(png_structp png_ptr, png_infop info_ptr, #endif #endif -#if defined(PNG_cHRM_SUPPORTED) -#ifdef PNG_FIXED_POINT_SUPPORTED +#ifdef PNG_cHRM_SUPPORTED int_white_x = 31270L; int_white_y = 32900L; int_red_x = 64000L; @@ -662,10 +564,6 @@ png_set_sRGB_gAMA_and_cHRM(png_structp png_ptr, png_infop info_ptr, int_blue_x = 15000L; int_blue_y = 6000L; - png_set_cHRM_fixed(png_ptr, info_ptr, - int_white_x, int_white_y, int_red_x, int_red_y, int_green_x, int_green_y, - int_blue_x, int_blue_y); -#endif #ifdef PNG_FLOATING_POINT_SUPPORTED white_x = (float).3127; white_y = (float).3290; @@ -675,16 +573,23 @@ png_set_sRGB_gAMA_and_cHRM(png_structp png_ptr, png_infop info_ptr, green_y = (float).60; blue_x = (float).15; blue_y = (float).06; +#endif - png_set_cHRM(png_ptr, info_ptr, - white_x, white_y, red_x, red_y, green_x, green_y, blue_x, blue_y); +#ifdef PNG_FIXED_POINT_SUPPORTED + png_set_cHRM_fixed(png_ptr, info_ptr, + int_white_x, int_white_y, int_red_x, int_red_y, int_green_x, + int_green_y, int_blue_x, int_blue_y); #endif +#ifdef PNG_FLOATING_POINT_SUPPORTED + png_set_cHRM(png_ptr, info_ptr, + white_x, white_y, red_x, red_y, green_x, green_y, blue_x, blue_y); #endif +#endif /* cHRM */ } -#endif +#endif /* sRGB */ -#if defined(PNG_iCCP_SUPPORTED) +#ifdef PNG_iCCP_SUPPORTED void PNGAPI png_set_iCCP(png_structp png_ptr, png_infop info_ptr, png_charp name, int compression_type, @@ -694,7 +599,8 @@ png_set_iCCP(png_structp png_ptr, png_infop info_ptr, png_charp new_iccp_profile; png_uint_32 length; - png_debug1(1, "in %s storage function\n", "iCCP"); + png_debug1(1, "in %s storage function", "iCCP"); + if (png_ptr == NULL || info_ptr == NULL || name == NULL || profile == NULL) return; @@ -702,7 +608,7 @@ png_set_iCCP(png_structp png_ptr, png_infop info_ptr, new_iccp_name = (png_charp)png_malloc_warn(png_ptr, length); if (new_iccp_name == NULL) { - png_warning(png_ptr, "Insufficient memory to process iCCP chunk."); + png_warning(png_ptr, "Insufficient memory to process iCCP chunk."); return; } png_memcpy(new_iccp_name, name, length); @@ -710,7 +616,8 @@ png_set_iCCP(png_structp png_ptr, png_infop info_ptr, if (new_iccp_profile == NULL) { png_free (png_ptr, new_iccp_name); - png_warning(png_ptr, "Insufficient memory to process iCCP profile."); + png_warning(png_ptr, + "Insufficient memory to process iCCP profile."); return; } png_memcpy(new_iccp_profile, profile, (png_size_t)proflen); @@ -721,7 +628,8 @@ png_set_iCCP(png_structp png_ptr, png_infop info_ptr, info_ptr->iccp_name = new_iccp_name; info_ptr->iccp_profile = new_iccp_profile; /* Compression is always zero but is here so the API and info structure - * does not have to change if we introduce multiple compression types */ + * does not have to change if we introduce multiple compression types + */ info_ptr->iccp_compression = (png_byte)compression_type; #ifdef PNG_FREE_ME_SUPPORTED info_ptr->free_me |= PNG_FREE_ICCP; @@ -730,24 +638,25 @@ png_set_iCCP(png_structp png_ptr, png_infop info_ptr, } #endif -#if defined(PNG_TEXT_SUPPORTED) +#ifdef PNG_TEXT_SUPPORTED void PNGAPI png_set_text(png_structp png_ptr, png_infop info_ptr, png_textp text_ptr, - int num_text) + int num_text) { int ret; - ret=png_set_text_2(png_ptr, info_ptr, text_ptr, num_text); + ret = png_set_text_2(png_ptr, info_ptr, text_ptr, num_text); if (ret) - png_error(png_ptr, "Insufficient memory to store text"); + png_error(png_ptr, "Insufficient memory to store text"); } int /* PRIVATE */ png_set_text_2(png_structp png_ptr, png_infop info_ptr, png_textp text_ptr, - int num_text) + int num_text) { int i; - png_debug1(1, "in %s storage function\n", (png_ptr->chunk_name[0] == '\0' ? + png_debug1(1, "in %s storage function", ((png_ptr == NULL || + png_ptr->chunk_name[0] == '\0') ? "text" : (png_const_charp)png_ptr->chunk_name)); if (png_ptr == NULL || info_ptr == NULL || num_text == 0) @@ -758,22 +667,26 @@ png_set_text_2(png_structp png_ptr, png_infop info_ptr, png_textp text_ptr, */ if (info_ptr->num_text + num_text > info_ptr->max_text) { + int old_max_text = info_ptr->max_text; + int old_num_text = info_ptr->num_text; + if (info_ptr->text != NULL) { png_textp old_text; - int old_max; - old_max = info_ptr->max_text; info_ptr->max_text = info_ptr->num_text + num_text + 8; old_text = info_ptr->text; + info_ptr->text = (png_textp)png_malloc_warn(png_ptr, - (png_uint_32)(info_ptr->max_text * png_sizeof (png_text))); + (png_uint_32)(info_ptr->max_text * png_sizeof(png_text))); if (info_ptr->text == NULL) - { - png_free(png_ptr, old_text); - return(1); - } - png_memcpy(info_ptr->text, old_text, (png_size_t)(old_max * + { + /* Restore to previous condition */ + info_ptr->max_text = old_max_text; + info_ptr->text = old_text; + return(1); + } + png_memcpy(info_ptr->text, old_text, (png_size_t)(old_max_text * png_sizeof(png_text))); png_free(png_ptr, old_text); } @@ -782,20 +695,26 @@ png_set_text_2(png_structp png_ptr, png_infop info_ptr, png_textp text_ptr, info_ptr->max_text = num_text + 8; info_ptr->num_text = 0; info_ptr->text = (png_textp)png_malloc_warn(png_ptr, - (png_uint_32)(info_ptr->max_text * png_sizeof (png_text))); + (png_uint_32)(info_ptr->max_text * png_sizeof(png_text))); if (info_ptr->text == NULL) - return(1); + { + /* Restore to previous condition */ + info_ptr->num_text = old_num_text; + info_ptr->max_text = old_max_text; + return(1); + } #ifdef PNG_FREE_ME_SUPPORTED info_ptr->free_me |= PNG_FREE_TEXT; #endif } - png_debug1(3, "allocated %d entries for info_ptr->text\n", + png_debug1(3, "allocated %d entries for info_ptr->text", info_ptr->max_text); } + for (i = 0; i < num_text; i++) { - png_size_t text_length,key_len; - png_size_t lang_len,lang_key_len; + png_size_t text_length, key_len; + png_size_t lang_len, lang_key_len; png_textp textp = &(info_ptr->text[info_ptr->num_text]); if (text_ptr[i].key == NULL) @@ -803,28 +722,30 @@ png_set_text_2(png_structp png_ptr, png_infop info_ptr, png_textp text_ptr, key_len = png_strlen(text_ptr[i].key); - if(text_ptr[i].compression <= 0) + if (text_ptr[i].compression <= 0) { - lang_len = 0; - lang_key_len = 0; + lang_len = 0; + lang_key_len = 0; } + else #ifdef PNG_iTXt_SUPPORTED { - /* set iTXt data */ - if (text_ptr[i].lang != NULL) - lang_len = png_strlen(text_ptr[i].lang); - else - lang_len = 0; - if (text_ptr[i].lang_key != NULL) - lang_key_len = png_strlen(text_ptr[i].lang_key); - else - lang_key_len = 0; + /* Set iTXt data */ + + if (text_ptr[i].lang != NULL) + lang_len = png_strlen(text_ptr[i].lang); + else + lang_len = 0; + if (text_ptr[i].lang_key != NULL) + lang_key_len = png_strlen(text_ptr[i].lang_key); + else + lang_key_len = 0; } -#else +#else /* PNG_iTXt_SUPPORTED */ { - png_warning(png_ptr, "iTXt chunk not supported."); - continue; + png_warning(png_ptr, "iTXt chunk not supported."); + continue; } #endif @@ -832,12 +753,13 @@ png_set_text_2(png_structp png_ptr, png_infop info_ptr, png_textp text_ptr, { text_length = 0; #ifdef PNG_iTXt_SUPPORTED - if(text_ptr[i].compression > 0) + if (text_ptr[i].compression > 0) textp->compression = PNG_ITXT_COMPRESSION_NONE; else #endif textp->compression = PNG_TEXT_COMPRESSION_NONE; } + else { text_length = png_strlen(text_ptr[i].text); @@ -845,26 +767,27 @@ png_set_text_2(png_structp png_ptr, png_infop info_ptr, png_textp text_ptr, } textp->key = (png_charp)png_malloc_warn(png_ptr, - (png_uint_32)(key_len + text_length + lang_len + lang_key_len + 4)); + (png_uint_32) + (key_len + text_length + lang_len + lang_key_len + 4)); if (textp->key == NULL) - return(1); - png_debug2(2, "Allocated %lu bytes at %x in png_set_text\n", - (png_uint_32)(key_len + lang_len + lang_key_len + text_length + 4), - (int)textp->key); - - png_memcpy(textp->key, text_ptr[i].key, - (png_size_t)(key_len)); - *(textp->key+key_len) = '\0'; + return(1); + png_debug2(2, "Allocated %lu bytes at %x in png_set_text", + (png_uint_32) + (key_len + lang_len + lang_key_len + text_length + 4), + (int)textp->key); + + png_memcpy(textp->key, text_ptr[i].key,(png_size_t)(key_len)); + *(textp->key + key_len) = '\0'; #ifdef PNG_iTXt_SUPPORTED if (text_ptr[i].compression > 0) { - textp->lang=textp->key + key_len + 1; + textp->lang = textp->key + key_len + 1; png_memcpy(textp->lang, text_ptr[i].lang, lang_len); - *(textp->lang+lang_len) = '\0'; - textp->lang_key=textp->lang + lang_len + 1; + *(textp->lang + lang_len) = '\0'; + textp->lang_key = textp->lang + lang_len + 1; png_memcpy(textp->lang_key, text_ptr[i].lang_key, lang_key_len); - *(textp->lang_key+lang_key_len) = '\0'; - textp->text=textp->lang_key + lang_key_len + 1; + *(textp->lang_key + lang_key_len) = '\0'; + textp->text = textp->lang_key + lang_key_len + 1; } else #endif @@ -873,21 +796,22 @@ png_set_text_2(png_structp png_ptr, png_infop info_ptr, png_textp text_ptr, textp->lang=NULL; textp->lang_key=NULL; #endif - textp->text=textp->key + key_len + 1; + textp->text = textp->key + key_len + 1; } - if(text_length) + if (text_length) png_memcpy(textp->text, text_ptr[i].text, (png_size_t)(text_length)); - *(textp->text+text_length) = '\0'; + *(textp->text + text_length) = '\0'; #ifdef PNG_iTXt_SUPPORTED - if(textp->compression > 0) + if (textp->compression > 0) { textp->text_length = 0; textp->itxt_length = text_length; } else #endif + { textp->text_length = text_length; #ifdef PNG_iTXt_SUPPORTED @@ -895,197 +819,224 @@ png_set_text_2(png_structp png_ptr, png_infop info_ptr, png_textp text_ptr, #endif } info_ptr->num_text++; - png_debug1(3, "transferred text chunk %d\n", info_ptr->num_text); + png_debug1(3, "transferred text chunk %d", info_ptr->num_text); } return(0); } #endif -#if defined(PNG_tIME_SUPPORTED) +#ifdef PNG_tIME_SUPPORTED void PNGAPI png_set_tIME(png_structp png_ptr, png_infop info_ptr, png_timep mod_time) { - png_debug1(1, "in %s storage function\n", "tIME"); + png_debug1(1, "in %s storage function", "tIME"); + if (png_ptr == NULL || info_ptr == NULL || (png_ptr->mode & PNG_WROTE_tIME)) return; - png_memcpy(&(info_ptr->mod_time), mod_time, png_sizeof (png_time)); + png_memcpy(&(info_ptr->mod_time), mod_time, png_sizeof(png_time)); info_ptr->valid |= PNG_INFO_tIME; } #endif -#if defined(PNG_tRNS_SUPPORTED) +#ifdef PNG_tRNS_SUPPORTED void PNGAPI png_set_tRNS(png_structp png_ptr, png_infop info_ptr, png_bytep trans, int num_trans, png_color_16p trans_values) { - png_debug1(1, "in %s storage function\n", "tRNS"); + png_debug1(1, "in %s storage function", "tRNS"); + if (png_ptr == NULL || info_ptr == NULL) return; if (trans != NULL) { - /* - * It may not actually be necessary to set png_ptr->trans here; + /* It may not actually be necessary to set png_ptr->trans here; * we do it for backward compatibility with the way the png_handle_tRNS * function used to do the allocation. */ + #ifdef PNG_FREE_ME_SUPPORTED png_free_data(png_ptr, info_ptr, PNG_FREE_TRNS, 0); #endif + /* Changed from num_trans to PNG_MAX_PALETTE_LENGTH in version 1.2.1 */ png_ptr->trans = info_ptr->trans = (png_bytep)png_malloc(png_ptr, (png_uint_32)PNG_MAX_PALETTE_LENGTH); - if (num_trans <= PNG_MAX_PALETTE_LENGTH) - png_memcpy(info_ptr->trans, trans, (png_size_t)num_trans); -#ifdef PNG_FREE_ME_SUPPORTED - info_ptr->free_me |= PNG_FREE_TRNS; -#else - png_ptr->flags |= PNG_FLAG_FREE_TRNS; -#endif + if (num_trans > 0 && num_trans <= PNG_MAX_PALETTE_LENGTH) + png_memcpy(info_ptr->trans, trans, (png_size_t)num_trans); } if (trans_values != NULL) { + int sample_max = (1 << info_ptr->bit_depth); + if ((info_ptr->color_type == PNG_COLOR_TYPE_GRAY && + (int)trans_values->gray > sample_max) || + (info_ptr->color_type == PNG_COLOR_TYPE_RGB && + ((int)trans_values->red > sample_max || + (int)trans_values->green > sample_max || + (int)trans_values->blue > sample_max))) + png_warning(png_ptr, + "tRNS chunk has out-of-range samples for bit_depth"); png_memcpy(&(info_ptr->trans_values), trans_values, png_sizeof(png_color_16)); if (num_trans == 0) - num_trans = 1; + num_trans = 1; } + info_ptr->num_trans = (png_uint_16)num_trans; - info_ptr->valid |= PNG_INFO_tRNS; + if (num_trans != 0) + { + info_ptr->valid |= PNG_INFO_tRNS; +#ifdef PNG_FREE_ME_SUPPORTED + info_ptr->free_me |= PNG_FREE_TRNS; +#else + png_ptr->flags |= PNG_FLAG_FREE_TRNS; +#endif + } } #endif -#if defined(PNG_sPLT_SUPPORTED) +#ifdef PNG_sPLT_SUPPORTED void PNGAPI png_set_sPLT(png_structp png_ptr, png_infop info_ptr, png_sPLT_tp entries, int nentries) +/* + * entries - array of png_sPLT_t structures + * to be added to the list of palettes + * in the info structure. + * nentries - number of palette structures to be + * added. + */ { - png_sPLT_tp np; - int i; + png_sPLT_tp np; + int i; - if (png_ptr == NULL || info_ptr == NULL) - return; + if (png_ptr == NULL || info_ptr == NULL) + return; - np = (png_sPLT_tp)png_malloc_warn(png_ptr, - (info_ptr->splt_palettes_num + nentries) * png_sizeof(png_sPLT_t)); - if (np == NULL) - { + np = (png_sPLT_tp)png_malloc_warn(png_ptr, + (info_ptr->splt_palettes_num + nentries) * + (png_uint_32)png_sizeof(png_sPLT_t)); + if (np == NULL) + { png_warning(png_ptr, "No memory for sPLT palettes."); return; - } - - png_memcpy(np, info_ptr->splt_palettes, - info_ptr->splt_palettes_num * png_sizeof(png_sPLT_t)); - png_free(png_ptr, info_ptr->splt_palettes); - info_ptr->splt_palettes=NULL; - - for (i = 0; i < nentries; i++) - { - png_sPLT_tp to = np + info_ptr->splt_palettes_num + i; - png_sPLT_tp from = entries + i; - png_uint_32 length; - - length = png_strlen(from->name) + 1; - to->name = (png_charp)png_malloc_warn(png_ptr, length); - if (to->name == NULL) - { - png_warning(png_ptr, - "Out of memory while processing sPLT chunk"); - } - /* TODO: use png_malloc_warn */ - png_memcpy(to->name, from->name, length); - to->entries = (png_sPLT_entryp)png_malloc_warn(png_ptr, - from->nentries * png_sizeof(png_sPLT_entry)); - /* TODO: use png_malloc_warn */ - png_memcpy(to->entries, from->entries, - from->nentries * png_sizeof(png_sPLT_entry)); - if (to->entries == NULL) - { - png_warning(png_ptr, - "Out of memory while processing sPLT chunk"); - png_free(png_ptr,to->name); - to->name = NULL; - } - to->nentries = from->nentries; - to->depth = from->depth; - } - - info_ptr->splt_palettes = np; - info_ptr->splt_palettes_num += nentries; - info_ptr->valid |= PNG_INFO_sPLT; + } + + png_memcpy(np, info_ptr->splt_palettes, + info_ptr->splt_palettes_num * png_sizeof(png_sPLT_t)); + png_free(png_ptr, info_ptr->splt_palettes); + info_ptr->splt_palettes=NULL; + + for (i = 0; i < nentries; i++) + { + png_sPLT_tp to = np + info_ptr->splt_palettes_num + i; + png_sPLT_tp from = entries + i; + png_uint_32 length; + + length = png_strlen(from->name) + 1; + to->name = (png_charp)png_malloc_warn(png_ptr, length); + if (to->name == NULL) + { + png_warning(png_ptr, + "Out of memory while processing sPLT chunk"); + continue; + } + png_memcpy(to->name, from->name, length); + to->entries = (png_sPLT_entryp)png_malloc_warn(png_ptr, + (png_uint_32)(from->nentries * png_sizeof(png_sPLT_entry))); + if (to->entries == NULL) + { + png_warning(png_ptr, + "Out of memory while processing sPLT chunk"); + png_free(png_ptr, to->name); + to->name = NULL; + continue; + } + png_memcpy(to->entries, from->entries, + from->nentries * png_sizeof(png_sPLT_entry)); + to->nentries = from->nentries; + to->depth = from->depth; + } + + info_ptr->splt_palettes = np; + info_ptr->splt_palettes_num += nentries; + info_ptr->valid |= PNG_INFO_sPLT; #ifdef PNG_FREE_ME_SUPPORTED - info_ptr->free_me |= PNG_FREE_SPLT; + info_ptr->free_me |= PNG_FREE_SPLT; #endif } #endif /* PNG_sPLT_SUPPORTED */ -#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) +#ifdef PNG_UNKNOWN_CHUNKS_SUPPORTED void PNGAPI png_set_unknown_chunks(png_structp png_ptr, png_infop info_ptr, png_unknown_chunkp unknowns, int num_unknowns) { - png_unknown_chunkp np; - int i; - - if (png_ptr == NULL || info_ptr == NULL || num_unknowns == 0) - return; - - np = (png_unknown_chunkp)png_malloc_warn(png_ptr, - (info_ptr->unknown_chunks_num + num_unknowns) * - png_sizeof(png_unknown_chunk)); - if (np == NULL) - { - png_warning(png_ptr, + png_unknown_chunkp np; + int i; + + if (png_ptr == NULL || info_ptr == NULL || num_unknowns == 0) + return; + + np = (png_unknown_chunkp)png_malloc_warn(png_ptr, + (png_uint_32)((info_ptr->unknown_chunks_num + num_unknowns) * + png_sizeof(png_unknown_chunk))); + if (np == NULL) + { + png_warning(png_ptr, "Out of memory while processing unknown chunk."); - return; - } - - png_memcpy(np, info_ptr->unknown_chunks, - info_ptr->unknown_chunks_num * png_sizeof(png_unknown_chunk)); - png_free(png_ptr, info_ptr->unknown_chunks); - info_ptr->unknown_chunks=NULL; - - for (i = 0; i < num_unknowns; i++) - { - png_unknown_chunkp to = np + info_ptr->unknown_chunks_num + i; - png_unknown_chunkp from = unknowns + i; - - png_memcpy((png_charp)to->name, - (png_charp)from->name, - png_sizeof(from->name)); - to->name[png_sizeof(to->name)-1] = '\0'; - - to->data = (png_bytep)png_malloc_warn(png_ptr, from->size); - if (to->data == NULL) - { - png_warning(png_ptr, - "Out of memory while processing unknown chunk."); - } - else - { - png_memcpy(to->data, from->data, from->size); - to->size = from->size; - - /* note our location in the read or write sequence */ - to->location = (png_byte)(png_ptr->mode & 0xff); - } - } - - info_ptr->unknown_chunks = np; - info_ptr->unknown_chunks_num += num_unknowns; + return; + } + + png_memcpy(np, info_ptr->unknown_chunks, + info_ptr->unknown_chunks_num * png_sizeof(png_unknown_chunk)); + png_free(png_ptr, info_ptr->unknown_chunks); + info_ptr->unknown_chunks = NULL; + + for (i = 0; i < num_unknowns; i++) + { + png_unknown_chunkp to = np + info_ptr->unknown_chunks_num + i; + png_unknown_chunkp from = unknowns + i; + + png_memcpy((png_charp)to->name, (png_charp)from->name, + png_sizeof(from->name)); + to->name[png_sizeof(to->name)-1] = '\0'; + to->size = from->size; + /* Note our location in the read or write sequence */ + to->location = (png_byte)(png_ptr->mode & 0xff); + + if (from->size == 0) + to->data=NULL; + else + { + to->data = (png_bytep)png_malloc_warn(png_ptr, + (png_uint_32)from->size); + if (to->data == NULL) + { + png_warning(png_ptr, + "Out of memory while processing unknown chunk."); + to->size = 0; + } + else + png_memcpy(to->data, from->data, from->size); + } + } + + info_ptr->unknown_chunks = np; + info_ptr->unknown_chunks_num += num_unknowns; #ifdef PNG_FREE_ME_SUPPORTED - info_ptr->free_me |= PNG_FREE_UNKN; + info_ptr->free_me |= PNG_FREE_UNKN; #endif } void PNGAPI png_set_unknown_chunk_location(png_structp png_ptr, png_infop info_ptr, int chunk, int location) { - if(png_ptr != NULL && info_ptr != NULL && chunk >= 0 && chunk < - (int)info_ptr->unknown_chunks_num) + if (png_ptr != NULL && info_ptr != NULL && chunk >= 0 && chunk < + (int)info_ptr->unknown_chunks_num) info_ptr->unknown_chunks[chunk].location = (png_byte)location; } #endif @@ -1098,7 +1049,9 @@ png_permit_empty_plte (png_structp png_ptr, int empty_plte_permitted) { /* This function is deprecated in favor of png_permit_mng_features() and will be removed from libpng-1.3.0 */ - png_debug(1, "in png_permit_empty_plte, DEPRECATED.\n"); + + png_debug(1, "in png_permit_empty_plte, DEPRECATED."); + if (png_ptr == NULL) return; png_ptr->mng_features_permitted = (png_byte) @@ -1108,11 +1061,12 @@ png_permit_empty_plte (png_structp png_ptr, int empty_plte_permitted) #endif #endif -#if defined(PNG_MNG_FEATURES_SUPPORTED) +#ifdef PNG_MNG_FEATURES_SUPPORTED png_uint_32 PNGAPI png_permit_mng_features (png_structp png_ptr, png_uint_32 mng_features) { - png_debug(1, "in png_permit_mng_features\n"); + png_debug(1, "in png_permit_mng_features"); + if (png_ptr == NULL) return (png_uint_32)0; png_ptr->mng_features_permitted = @@ -1121,96 +1075,97 @@ png_permit_mng_features (png_structp png_ptr, png_uint_32 mng_features) } #endif -#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) +#ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED void PNGAPI png_set_keep_unknown_chunks(png_structp png_ptr, int keep, png_bytep chunk_list, int num_chunks) { - png_bytep new_list, p; - int i, old_num_chunks; - if (png_ptr == NULL) - return; - if (num_chunks == 0) - { - if(keep == PNG_HANDLE_CHUNK_ALWAYS || keep == PNG_HANDLE_CHUNK_IF_SAFE) - png_ptr->flags |= PNG_FLAG_KEEP_UNKNOWN_CHUNKS; + png_bytep new_list, p; + int i, old_num_chunks; + if (png_ptr == NULL) + return; + if (num_chunks == 0) + { + if (keep == PNG_HANDLE_CHUNK_ALWAYS || keep == PNG_HANDLE_CHUNK_IF_SAFE) + png_ptr->flags |= PNG_FLAG_KEEP_UNKNOWN_CHUNKS; else - png_ptr->flags &= ~PNG_FLAG_KEEP_UNKNOWN_CHUNKS; + png_ptr->flags &= ~PNG_FLAG_KEEP_UNKNOWN_CHUNKS; - if(keep == PNG_HANDLE_CHUNK_ALWAYS) - png_ptr->flags |= PNG_FLAG_KEEP_UNSAFE_CHUNKS; + if (keep == PNG_HANDLE_CHUNK_ALWAYS) + png_ptr->flags |= PNG_FLAG_KEEP_UNSAFE_CHUNKS; else - png_ptr->flags &= ~PNG_FLAG_KEEP_UNSAFE_CHUNKS; + png_ptr->flags &= ~PNG_FLAG_KEEP_UNSAFE_CHUNKS; return; - } - if (chunk_list == NULL) + } + if (chunk_list == NULL) return; - old_num_chunks=png_ptr->num_chunk_list; - new_list=(png_bytep)png_malloc(png_ptr, - (png_uint_32)(5*(num_chunks+old_num_chunks))); - if(png_ptr->chunk_list != NULL) - { - png_memcpy(new_list, png_ptr->chunk_list, + old_num_chunks = png_ptr->num_chunk_list; + new_list=(png_bytep)png_malloc(png_ptr, + (png_uint_32) + (5*(num_chunks + old_num_chunks))); + if (png_ptr->chunk_list != NULL) + { + png_memcpy(new_list, png_ptr->chunk_list, (png_size_t)(5*old_num_chunks)); - png_free(png_ptr, png_ptr->chunk_list); - png_ptr->chunk_list=NULL; - } - png_memcpy(new_list+5*old_num_chunks, chunk_list, + png_free(png_ptr, png_ptr->chunk_list); + png_ptr->chunk_list=NULL; + } + png_memcpy(new_list + 5*old_num_chunks, chunk_list, (png_size_t)(5*num_chunks)); - for (p=new_list+5*old_num_chunks+4, i=0; inum_chunk_list=old_num_chunks+num_chunks; - png_ptr->chunk_list=new_list; + for (p = new_list + 5*old_num_chunks + 4, i = 0; inum_chunk_list = old_num_chunks + num_chunks; + png_ptr->chunk_list = new_list; #ifdef PNG_FREE_ME_SUPPORTED - png_ptr->free_me |= PNG_FREE_LIST; + png_ptr->free_me |= PNG_FREE_LIST; #endif } #endif -#if defined(PNG_READ_USER_CHUNKS_SUPPORTED) +#ifdef PNG_READ_USER_CHUNKS_SUPPORTED void PNGAPI png_set_read_user_chunk_fn(png_structp png_ptr, png_voidp user_chunk_ptr, png_user_chunk_ptr read_user_chunk_fn) { - png_debug(1, "in png_set_read_user_chunk_fn\n"); + png_debug(1, "in png_set_read_user_chunk_fn"); + if (png_ptr == NULL) return; + png_ptr->read_user_chunk_fn = read_user_chunk_fn; png_ptr->user_chunk_ptr = user_chunk_ptr; } #endif -#if defined(PNG_INFO_IMAGE_SUPPORTED) +#ifdef PNG_INFO_IMAGE_SUPPORTED void PNGAPI png_set_rows(png_structp png_ptr, png_infop info_ptr, png_bytepp row_pointers) { - png_debug1(1, "in %s storage function\n", "rows"); + png_debug1(1, "in %s storage function", "rows"); if (png_ptr == NULL || info_ptr == NULL) return; - if(info_ptr->row_pointers && (info_ptr->row_pointers != row_pointers)) + if (info_ptr->row_pointers && (info_ptr->row_pointers != row_pointers)) png_free_data(png_ptr, info_ptr, PNG_FREE_ROWS, 0); info_ptr->row_pointers = row_pointers; - if(row_pointers) + if (row_pointers) info_ptr->valid |= PNG_INFO_IDAT; } #endif -#ifdef PNG_WRITE_SUPPORTED void PNGAPI -png_set_compression_buffer_size(png_structp png_ptr, png_uint_32 size) +png_set_compression_buffer_size(png_structp png_ptr, + png_uint_32 size) { if (png_ptr == NULL) return; - if(png_ptr->zbuf) - png_free(png_ptr, png_ptr->zbuf); + png_free(png_ptr, png_ptr->zbuf); png_ptr->zbuf_size = (png_size_t)size; png_ptr->zbuf = (png_bytep)png_malloc(png_ptr, size); png_ptr->zstream.next_out = png_ptr->zbuf; png_ptr->zstream.avail_out = (uInt)png_ptr->zbuf_size; } -#endif void PNGAPI png_set_invalid(png_structp png_ptr, png_infop info_ptr, int mask) @@ -1222,16 +1177,17 @@ png_set_invalid(png_structp png_ptr, png_infop info_ptr, int mask) #ifndef PNG_1_0_X #ifdef PNG_ASSEMBLER_CODE_SUPPORTED -/* function was added to libpng 1.2.0 and should always exist by default */ +/* Function was added to libpng 1.2.0 and should always exist by default */ void PNGAPI png_set_asm_flags (png_structp png_ptr, png_uint_32 asm_flags) { /* Obsolete as of libpng-1.2.20 and will be removed from libpng-1.4.0 */ if (png_ptr != NULL) png_ptr->asm_flags = 0; + asm_flags = asm_flags; /* Quiet the compiler */ } -/* this function was added to libpng 1.2.0 */ +/* This function was added to libpng 1.2.0 */ void PNGAPI png_set_mmx_thresholds (png_structp png_ptr, png_byte mmx_bitdepth_threshold, @@ -1240,24 +1196,41 @@ png_set_mmx_thresholds (png_structp png_ptr, /* Obsolete as of libpng-1.2.20 and will be removed from libpng-1.4.0 */ if (png_ptr == NULL) return; + /* Quiet the compiler */ + mmx_bitdepth_threshold = mmx_bitdepth_threshold; + mmx_rowbytes_threshold = mmx_rowbytes_threshold; } #endif /* ?PNG_ASSEMBLER_CODE_SUPPORTED */ #ifdef PNG_SET_USER_LIMITS_SUPPORTED -/* this function was added to libpng 1.2.6 */ +/* This function was added to libpng 1.2.6 */ void PNGAPI png_set_user_limits (png_structp png_ptr, png_uint_32 user_width_max, png_uint_32 user_height_max) { - /* Images with dimensions larger than these limits will be - * rejected by png_set_IHDR(). To accept any PNG datastream - * regardless of dimensions, set both limits to 0x7ffffffL. - */ - if(png_ptr == NULL) return; - png_ptr->user_width_max = user_width_max; - png_ptr->user_height_max = user_height_max; + /* Images with dimensions larger than these limits will be + * rejected by png_set_IHDR(). To accept any PNG datastream + * regardless of dimensions, set both limits to 0x7ffffffL. + */ + if (png_ptr == NULL) + return; + png_ptr->user_width_max = user_width_max; + png_ptr->user_height_max = user_height_max; } #endif /* ?PNG_SET_USER_LIMITS_SUPPORTED */ + +#ifdef PNG_BENIGN_ERRORS_SUPPORTED +void PNGAPI +png_set_benign_errors(png_structp png_ptr, int allowed) +{ + png_debug(1, "in png_set_benign_errors"); + + if (allowed) + png_ptr->flags |= PNG_FLAG_BENIGN_ERRORS_WARN; + else + png_ptr->flags &= ~PNG_FLAG_BENIGN_ERRORS_WARN; +} +#endif /* PNG_BENIGN_ERRORS_SUPPORTED */ #endif /* ?PNG_1_0_X */ #endif /* PNG_READ_SUPPORTED || PNG_WRITE_SUPPORTED */ diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngtrans.c b/graf2d/asimage/src/libAfterImage/libpng/pngtrans.c index 1640095020c72..6ad9dcf628cf0 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngtrans.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngtrans.c @@ -1,47 +1,57 @@ /* pngtrans.c - transforms the data in a row (used by both readers and writers) * - * Last changed in libpng 1.2.17 May 15, 2007 - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * Last changed in libpng 1.2.41 [December 3, 2009] + * Copyright (c) 1998-2009 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) + * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" - #if defined(PNG_READ_SUPPORTED) || defined(PNG_WRITE_SUPPORTED) + #if defined(PNG_READ_BGR_SUPPORTED) || defined(PNG_WRITE_BGR_SUPPORTED) -/* turn on BGR-to-RGB mapping */ +/* Turn on BGR-to-RGB mapping */ void PNGAPI png_set_bgr(png_structp png_ptr) { - png_debug(1, "in png_set_bgr\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_bgr"); + + if (png_ptr == NULL) + return; png_ptr->transformations |= PNG_BGR; } #endif #if defined(PNG_READ_SWAP_SUPPORTED) || defined(PNG_WRITE_SWAP_SUPPORTED) -/* turn on 16 bit byte swapping */ +/* Turn on 16 bit byte swapping */ void PNGAPI png_set_swap(png_structp png_ptr) { - png_debug(1, "in png_set_swap\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_swap"); + + if (png_ptr == NULL) + return; if (png_ptr->bit_depth == 16) png_ptr->transformations |= PNG_SWAP_BYTES; } #endif #if defined(PNG_READ_PACK_SUPPORTED) || defined(PNG_WRITE_PACK_SUPPORTED) -/* turn on pixel packing */ +/* Turn on pixel packing */ void PNGAPI png_set_packing(png_structp png_ptr) { - png_debug(1, "in png_set_packing\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_packing"); + + if (png_ptr == NULL) + return; if (png_ptr->bit_depth < 8) { png_ptr->transformations |= PNG_PACK; @@ -51,12 +61,14 @@ png_set_packing(png_structp png_ptr) #endif #if defined(PNG_READ_PACKSWAP_SUPPORTED)||defined(PNG_WRITE_PACKSWAP_SUPPORTED) -/* turn on packed pixel swapping */ +/* Turn on packed pixel swapping */ void PNGAPI png_set_packswap(png_structp png_ptr) { - png_debug(1, "in png_set_packswap\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_packswap"); + + if (png_ptr == NULL) + return; if (png_ptr->bit_depth < 8) png_ptr->transformations |= PNG_PACKSWAP; } @@ -66,8 +78,10 @@ png_set_packswap(png_structp png_ptr) void PNGAPI png_set_shift(png_structp png_ptr, png_color_8p true_bits) { - png_debug(1, "in png_set_shift\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_shift"); + + if (png_ptr == NULL) + return; png_ptr->transformations |= PNG_SHIFT; png_ptr->shift = *true_bits; } @@ -78,7 +92,8 @@ png_set_shift(png_structp png_ptr, png_color_8p true_bits) int PNGAPI png_set_interlace_handling(png_structp png_ptr) { - png_debug(1, "in png_set_interlace handling\n"); + png_debug(1, "in png_set_interlace handling"); + if (png_ptr && png_ptr->interlaced) { png_ptr->transformations |= PNG_INTERLACE; @@ -98,10 +113,16 @@ png_set_interlace_handling(png_structp png_ptr) void PNGAPI png_set_filler(png_structp png_ptr, png_uint_32 filler, int filler_loc) { - png_debug(1, "in png_set_filler\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_filler"); + + if (png_ptr == NULL) + return; png_ptr->transformations |= PNG_FILLER; +#ifdef PNG_LEGACY_SUPPORTED png_ptr->filler = (png_byte)filler; +#else + png_ptr->filler = (png_uint_16)filler; +#endif if (filler_loc == PNG_FILLER_AFTER) png_ptr->flags |= PNG_FLAG_FILLER_AFTER; else @@ -126,13 +147,15 @@ png_set_filler(png_structp png_ptr, png_uint_32 filler, int filler_loc) } } -#if !defined(PNG_1_0_X) +#ifndef PNG_1_0_X /* Added to libpng-1.2.7 */ void PNGAPI png_set_add_alpha(png_structp png_ptr, png_uint_32 filler, int filler_loc) { - png_debug(1, "in png_set_add_alpha\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_add_alpha"); + + if (png_ptr == NULL) + return; png_set_filler(png_ptr, filler, filler_loc); png_ptr->transformations |= PNG_ADD_ALPHA; } @@ -145,8 +168,10 @@ png_set_add_alpha(png_structp png_ptr, png_uint_32 filler, int filler_loc) void PNGAPI png_set_swap_alpha(png_structp png_ptr) { - png_debug(1, "in png_set_swap_alpha\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_swap_alpha"); + + if (png_ptr == NULL) + return; png_ptr->transformations |= PNG_SWAP_ALPHA; } #endif @@ -156,8 +181,10 @@ png_set_swap_alpha(png_structp png_ptr) void PNGAPI png_set_invert_alpha(png_structp png_ptr) { - png_debug(1, "in png_set_invert_alpha\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_invert_alpha"); + + if (png_ptr == NULL) + return; png_ptr->transformations |= PNG_INVERT_ALPHA; } #endif @@ -166,20 +193,23 @@ png_set_invert_alpha(png_structp png_ptr) void PNGAPI png_set_invert_mono(png_structp png_ptr) { - png_debug(1, "in png_set_invert_mono\n"); - if(png_ptr == NULL) return; + png_debug(1, "in png_set_invert_mono"); + + if (png_ptr == NULL) + return; png_ptr->transformations |= PNG_INVERT_MONO; } -/* invert monochrome grayscale data */ +/* Invert monochrome grayscale data */ void /* PRIVATE */ png_do_invert(png_row_infop row_info, png_bytep row) { - png_debug(1, "in png_do_invert\n"); + png_debug(1, "in png_do_invert"); + /* This test removed from libpng version 1.0.13 and 1.2.0: * if (row_info->bit_depth == 1 && */ -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED if (row == NULL || row_info == NULL) return; #endif @@ -226,13 +256,14 @@ png_do_invert(png_row_infop row_info, png_bytep row) #endif #if defined(PNG_READ_SWAP_SUPPORTED) || defined(PNG_WRITE_SWAP_SUPPORTED) -/* swaps byte order on 16 bit depth images */ +/* Swaps byte order on 16 bit depth images */ void /* PRIVATE */ png_do_swap(png_row_infop row_info, png_bytep row) { - png_debug(1, "in png_do_swap\n"); + png_debug(1, "in png_do_swap"); + if ( -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && #endif row_info->bit_depth == 16) @@ -357,13 +388,14 @@ static PNG_CONST png_byte fourbppswaptable[256] = { 0x8F, 0x9F, 0xAF, 0xBF, 0xCF, 0xDF, 0xEF, 0xFF }; -/* swaps pixel packing order within bytes */ +/* Swaps pixel packing order within bytes */ void /* PRIVATE */ png_do_packswap(png_row_infop row_info, png_bytep row) { - png_debug(1, "in png_do_packswap\n"); + png_debug(1, "in png_do_packswap"); + if ( -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && #endif row_info->bit_depth < 8) @@ -389,12 +421,13 @@ png_do_packswap(png_row_infop row_info, png_bytep row) #if defined(PNG_WRITE_FILLER_SUPPORTED) || \ defined(PNG_READ_STRIP_ALPHA_SUPPORTED) -/* remove filler or alpha byte(s) */ +/* Remove filler or alpha byte(s) */ void /* PRIVATE */ png_do_strip_filler(png_row_infop row_info, png_bytep row, png_uint_32 flags) { - png_debug(1, "in png_do_strip_filler\n"); -#if defined(PNG_USELESS_TESTS_SUPPORTED) + png_debug(1, "in png_do_strip_filler"); + +#ifdef PNG_USELESS_TESTS_SUPPORTED if (row != NULL && row_info != NULL) #endif { @@ -404,9 +437,9 @@ png_do_strip_filler(png_row_infop row_info, png_bytep row, png_uint_32 flags) png_uint_32 i; if ((row_info->color_type == PNG_COLOR_TYPE_RGB || - (row_info->color_type == PNG_COLOR_TYPE_RGB_ALPHA && - (flags & PNG_FLAG_STRIP_ALPHA))) && - row_info->channels == 4) + (row_info->color_type == PNG_COLOR_TYPE_RGB_ALPHA && + (flags & PNG_FLAG_STRIP_ALPHA))) && + row_info->channels == 4) { if (row_info->bit_depth == 8) { @@ -547,13 +580,14 @@ png_do_strip_filler(png_row_infop row_info, png_bytep row, png_uint_32 flags) #endif #if defined(PNG_READ_BGR_SUPPORTED) || defined(PNG_WRITE_BGR_SUPPORTED) -/* swaps red and blue bytes within a pixel */ +/* Swaps red and blue bytes within a pixel */ void /* PRIVATE */ png_do_bgr(png_row_infop row_info, png_bytep row) { - png_debug(1, "in png_do_bgr\n"); + png_debug(1, "in png_do_bgr"); + if ( -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && #endif (row_info->color_type & PNG_COLOR_MASK_COLOR)) @@ -624,20 +658,22 @@ png_do_bgr(png_row_infop row_info, png_bytep row) #endif /* PNG_READ_BGR_SUPPORTED or PNG_WRITE_BGR_SUPPORTED */ #if defined(PNG_READ_USER_TRANSFORM_SUPPORTED) || \ - defined(PNG_WRITE_USER_TRANSFORM_SUPPORTED) || \ - defined(PNG_LEGACY_SUPPORTED) + defined(PNG_LEGACY_SUPPORTED) || \ + defined(PNG_WRITE_USER_TRANSFORM_SUPPORTED) void PNGAPI png_set_user_transform_info(png_structp png_ptr, png_voidp user_transform_ptr, int user_transform_depth, int user_transform_channels) { - png_debug(1, "in png_set_user_transform_info\n"); - if(png_ptr == NULL) return; -#if defined(PNG_USER_TRANSFORM_PTR_SUPPORTED) + png_debug(1, "in png_set_user_transform_info"); + + if (png_ptr == NULL) + return; +#ifdef PNG_USER_TRANSFORM_PTR_SUPPORTED png_ptr->user_transform_ptr = user_transform_ptr; png_ptr->user_transform_depth = (png_byte)user_transform_depth; png_ptr->user_transform_channels = (png_byte)user_transform_channels; #else - if(user_transform_ptr || user_transform_depth || user_transform_channels) + if (user_transform_ptr || user_transform_depth || user_transform_channels) png_warning(png_ptr, "This version of libpng does not support user transform info"); #endif @@ -652,8 +688,9 @@ png_set_user_transform_info(png_structp png_ptr, png_voidp png_voidp PNGAPI png_get_user_transform_ptr(png_structp png_ptr) { -#if defined(PNG_USER_TRANSFORM_PTR_SUPPORTED) - if (png_ptr == NULL) return (NULL); + if (png_ptr == NULL) + return (NULL); +#ifdef PNG_USER_TRANSFORM_PTR_SUPPORTED return ((png_voidp)png_ptr->user_transform_ptr); #else return (NULL); diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngwio.c b/graf2d/asimage/src/libAfterImage/libpng/pngwio.c index 371a4fad624b8..44e5ea91ca822 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngwio.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngwio.c @@ -1,12 +1,15 @@ /* pngwio.c - functions for data output * - * Last changed in libpng 1.2.13 November 13, 2006 - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2006 Glenn Randers-Pehrson + * Last changed in libpng 1.2.41 [December 3, 2009] + * Copyright (c) 1998-2009 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h + * * This file provides a location for all output. Users who need * special handling are expected to write functions that have the same * arguments as these and perform similar functions, but that possibly @@ -16,14 +19,16 @@ */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" #ifdef PNG_WRITE_SUPPORTED /* Write the data to whatever output you are using. The default routine - writes to a file pointer. Note that this routine sometimes gets called - with very small lengths, so you should implement some kind of simple - buffering if you are using unbuffered writes. This should never be asked - to write more than 64K on a 16 bit machine. */ + * writes to a file pointer. Note that this routine sometimes gets called + * with very small lengths, so you should implement some kind of simple + * buffering if you are using unbuffered writes. This should never be asked + * to write more than 64K on a 16 bit machine. + */ void /* PRIVATE */ png_write_data(png_structp png_ptr, png_bytep data, png_size_t length) @@ -34,19 +39,21 @@ png_write_data(png_structp png_ptr, png_bytep data, png_size_t length) png_error(png_ptr, "Call to NULL write function"); } -#if !defined(PNG_NO_STDIO) +#ifdef PNG_STDIO_SUPPORTED /* This is the function that does the actual writing of data. If you are - not writing to a standard C stream, you should create a replacement - write_data function and use it at run time with png_set_write_fn(), rather - than changing the library. */ + * not writing to a standard C stream, you should create a replacement + * write_data function and use it at run time with png_set_write_fn(), rather + * than changing the library. + */ #ifndef USE_FAR_KEYWORD void PNGAPI png_default_write_data(png_structp png_ptr, png_bytep data, png_size_t length) { png_uint_32 check; - if(png_ptr == NULL) return; -#if defined(_WIN32_WCE) + if (png_ptr == NULL) + return; +#ifdef _WIN32_WCE if ( !WriteFile((HANDLE)(png_ptr->io_ptr), data, length, &check, NULL) ) check = 0; #else @@ -56,10 +63,10 @@ png_default_write_data(png_structp png_ptr, png_bytep data, png_size_t length) png_error(png_ptr, "Write Error"); } #else -/* this is the model-independent version. Since the standard I/O library - can't handle far buffers in the medium and small models, we have to copy - the data. -*/ +/* This is the model-independent version. Since the standard I/O library + * can't handle far buffers in the medium and small models, we have to copy + * the data. + */ #define NEAR_BUF_SIZE 1024 #define MIN(a,b) (a <= b ? a : b) @@ -71,13 +78,14 @@ png_default_write_data(png_structp png_ptr, png_bytep data, png_size_t length) png_byte *near_data; /* Needs to be "png_byte *" instead of "png_bytep" */ png_FILE_p io_ptr; - if(png_ptr == NULL) return; + if (png_ptr == NULL) + return; /* Check if data really is near. If so, use usual code. */ near_data = (png_byte *)CVT_PTR_NOCHECK(data); io_ptr = (png_FILE_p)CVT_PTR(png_ptr->io_ptr); if ((png_bytep)near_data == data) { -#if defined(_WIN32_WCE) +#ifdef _WIN32_WCE if ( !WriteFile(io_ptr, near_data, length, &check, NULL) ) check = 0; #else @@ -93,8 +101,8 @@ png_default_write_data(png_structp png_ptr, png_bytep data, png_size_t length) do { written = MIN(NEAR_BUF_SIZE, remaining); - png_memcpy(buf, data, written); /* copy far buffer to near buffer */ -#if defined(_WIN32_WCE) + png_memcpy(buf, data, written); /* Copy far buffer to near buffer */ +#ifdef _WIN32_WCE if ( !WriteFile(io_ptr, buf, written, &err, NULL) ) err = 0; #else @@ -102,8 +110,10 @@ png_default_write_data(png_structp png_ptr, png_bytep data, png_size_t length) #endif if (err != written) break; + else check += err; + data += written; remaining -= written; } @@ -117,9 +127,10 @@ png_default_write_data(png_structp png_ptr, png_bytep data, png_size_t length) #endif /* This function is called to output any data pending writing (normally - to disk). After png_flush is called, there should be no data pending - writing in any buffers. */ -#if defined(PNG_WRITE_FLUSH_SUPPORTED) + * to disk). After png_flush is called, there should be no data pending + * writing in any buffers. + */ +#ifdef PNG_WRITE_FLUSH_SUPPORTED void /* PRIVATE */ png_flush(png_structp png_ptr) { @@ -127,65 +138,76 @@ png_flush(png_structp png_ptr) (*(png_ptr->output_flush_fn))(png_ptr); } -#if !defined(PNG_NO_STDIO) +#ifdef PNG_STDIO_SUPPORTED void PNGAPI png_default_flush(png_structp png_ptr) { -#if !defined(_WIN32_WCE) +#ifndef _WIN32_WCE png_FILE_p io_ptr; #endif - if(png_ptr == NULL) return; -#if !defined(_WIN32_WCE) + if (png_ptr == NULL) + return; +#ifndef _WIN32_WCE io_ptr = (png_FILE_p)CVT_PTR((png_ptr->io_ptr)); - if (io_ptr != NULL) - fflush(io_ptr); + fflush(io_ptr); #endif } #endif #endif /* This function allows the application to supply new output functions for - libpng if standard C streams aren't being used. - - This function takes as its arguments: - png_ptr - pointer to a png output data structure - io_ptr - pointer to user supplied structure containing info about - the output functions. May be NULL. - write_data_fn - pointer to a new output function that takes as its - arguments a pointer to a png_struct, a pointer to - data to be written, and a 32-bit unsigned int that is - the number of bytes to be written. The new write - function should call png_error(png_ptr, "Error msg") - to exit and output any fatal error messages. - flush_data_fn - pointer to a new flush function that takes as its - arguments a pointer to a png_struct. After a call to - the flush function, there should be no data in any buffers - or pending transmission. If the output method doesn't do - any buffering of ouput, a function prototype must still be - supplied although it doesn't have to do anything. If - PNG_WRITE_FLUSH_SUPPORTED is not defined at libpng compile - time, output_flush_fn will be ignored, although it must be - supplied for compatibility. */ + * libpng if standard C streams aren't being used. + * + * This function takes as its arguments: + * png_ptr - pointer to a png output data structure + * io_ptr - pointer to user supplied structure containing info about + * the output functions. May be NULL. + * write_data_fn - pointer to a new output function that takes as its + * arguments a pointer to a png_struct, a pointer to + * data to be written, and a 32-bit unsigned int that is + * the number of bytes to be written. The new write + * function should call png_error(png_ptr, "Error msg") + * to exit and output any fatal error messages. May be + * NULL, in which case libpng's default function will + * be used. + * flush_data_fn - pointer to a new flush function that takes as its + * arguments a pointer to a png_struct. After a call to + * the flush function, there should be no data in any buffers + * or pending transmission. If the output method doesn't do + * any buffering of output, a function prototype must still be + * supplied although it doesn't have to do anything. If + * PNG_WRITE_FLUSH_SUPPORTED is not defined at libpng compile + * time, output_flush_fn will be ignored, although it must be + * supplied for compatibility. May be NULL, in which case + * libpng's default function will be used, if + * PNG_WRITE_FLUSH_SUPPORTED is defined. This is not + * a good idea if io_ptr does not point to a standard + * *FILE structure. + */ void PNGAPI png_set_write_fn(png_structp png_ptr, png_voidp io_ptr, png_rw_ptr write_data_fn, png_flush_ptr output_flush_fn) { - if(png_ptr == NULL) return; + if (png_ptr == NULL) + return; + png_ptr->io_ptr = io_ptr; -#if !defined(PNG_NO_STDIO) +#ifdef PNG_STDIO_SUPPORTED if (write_data_fn != NULL) png_ptr->write_data_fn = write_data_fn; + else png_ptr->write_data_fn = png_default_write_data; #else png_ptr->write_data_fn = write_data_fn; #endif -#if defined(PNG_WRITE_FLUSH_SUPPORTED) -#if !defined(PNG_NO_STDIO) +#ifdef PNG_WRITE_FLUSH_SUPPORTED +#ifdef PNG_STDIO_SUPPORTED if (output_flush_fn != NULL) png_ptr->output_flush_fn = output_flush_fn; + else png_ptr->output_flush_fn = png_default_flush; #else @@ -204,29 +226,33 @@ png_set_write_fn(png_structp png_ptr, png_voidp io_ptr, } } -#if defined(USE_FAR_KEYWORD) -#if defined(_MSC_VER) -void *png_far_to_near(png_structp png_ptr,png_voidp ptr, int check) +#ifdef USE_FAR_KEYWORD +#ifdef _MSC_VER +void *png_far_to_near(png_structp png_ptr, png_voidp ptr, int check) { void *near_ptr; void FAR *far_ptr; FP_OFF(near_ptr) = FP_OFF(ptr); far_ptr = (void FAR *)near_ptr; - if(check != 0) - if(FP_SEG(ptr) != FP_SEG(far_ptr)) - png_error(png_ptr,"segment lost in conversion"); + + if (check != 0) + if (FP_SEG(ptr) != FP_SEG(far_ptr)) + png_error(png_ptr, "segment lost in conversion"); + return(near_ptr); } # else -void *png_far_to_near(png_structp png_ptr,png_voidp ptr, int check) +void *png_far_to_near(png_structp png_ptr, png_voidp ptr, int check) { void *near_ptr; void FAR *far_ptr; near_ptr = (void FAR *)ptr; far_ptr = (void FAR *)near_ptr; - if(check != 0) - if(far_ptr != ptr) - png_error(png_ptr,"segment lost in conversion"); + + if (check != 0) + if (far_ptr != ptr) + png_error(png_ptr, "segment lost in conversion"); + return(near_ptr); } # endif diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngwrite.c b/graf2d/asimage/src/libAfterImage/libpng/pngwrite.c index c6df1ef342558..1d8c53f922402 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngwrite.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngwrite.c @@ -1,15 +1,19 @@ /* pngwrite.c - general routines to write a PNG file * - * Last changed in libpng 1.2.15 January 5, 2007 - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * Last changed in libpng 1.2.45 [July 7, 2011] + * Copyright (c) 1998-2011 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) + * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h */ -/* get internal access to png.h */ +/* Get internal access to png.h */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" #ifdef PNG_WRITE_SUPPORTED @@ -25,31 +29,35 @@ void PNGAPI png_write_info_before_PLTE(png_structp png_ptr, png_infop info_ptr) { - png_debug(1, "in png_write_info_before_PLTE\n"); + png_debug(1, "in png_write_info_before_PLTE"); + if (png_ptr == NULL || info_ptr == NULL) return; if (!(png_ptr->mode & PNG_WROTE_INFO_BEFORE_PLTE)) { - png_write_sig(png_ptr); /* write PNG signature */ -#if defined(PNG_MNG_FEATURES_SUPPORTED) - if((png_ptr->mode&PNG_HAVE_PNG_SIGNATURE)&&(png_ptr->mng_features_permitted)) + /* Write PNG signature */ + png_write_sig(png_ptr); +#ifdef PNG_MNG_FEATURES_SUPPORTED + if ((png_ptr->mode&PNG_HAVE_PNG_SIGNATURE) && \ + (png_ptr->mng_features_permitted)) { - png_warning(png_ptr,"MNG features are not allowed in a PNG datastream"); - png_ptr->mng_features_permitted=0; + png_warning(png_ptr, "MNG features are not allowed in a PNG datastream"); + png_ptr->mng_features_permitted = 0; } #endif - /* write IHDR information. */ + /* Write IHDR information. */ png_write_IHDR(png_ptr, info_ptr->width, info_ptr->height, info_ptr->bit_depth, info_ptr->color_type, info_ptr->compression_type, info_ptr->filter_type, -#if defined(PNG_WRITE_INTERLACING_SUPPORTED) +#ifdef PNG_WRITE_INTERLACING_SUPPORTED info_ptr->interlace_type); #else 0); #endif - /* the rest of these check to see if the valid field has the appropriate - flag set, and if it does, writes the chunk. */ -#if defined(PNG_WRITE_gAMA_SUPPORTED) + /* The rest of these check to see if the valid field has the appropriate + * flag set, and if it does, writes the chunk. + */ +#ifdef PNG_WRITE_gAMA_SUPPORTED if (info_ptr->valid & PNG_INFO_gAMA) { # ifdef PNG_FLOATING_POINT_SUPPORTED @@ -61,20 +69,20 @@ png_write_info_before_PLTE(png_structp png_ptr, png_infop info_ptr) #endif } #endif -#if defined(PNG_WRITE_sRGB_SUPPORTED) +#ifdef PNG_WRITE_sRGB_SUPPORTED if (info_ptr->valid & PNG_INFO_sRGB) png_write_sRGB(png_ptr, (int)info_ptr->srgb_intent); #endif -#if defined(PNG_WRITE_iCCP_SUPPORTED) +#ifdef PNG_WRITE_iCCP_SUPPORTED if (info_ptr->valid & PNG_INFO_iCCP) png_write_iCCP(png_ptr, info_ptr->iccp_name, PNG_COMPRESSION_TYPE_BASE, info_ptr->iccp_profile, (int)info_ptr->iccp_proflen); #endif -#if defined(PNG_WRITE_sBIT_SUPPORTED) +#ifdef PNG_WRITE_sBIT_SUPPORTED if (info_ptr->valid & PNG_INFO_sBIT) png_write_sBIT(png_ptr, &(info_ptr->sig_bit), info_ptr->color_type); #endif -#if defined(PNG_WRITE_cHRM_SUPPORTED) +#ifdef PNG_WRITE_cHRM_SUPPORTED if (info_ptr->valid & PNG_INFO_cHRM) { #ifdef PNG_FLOATING_POINT_SUPPORTED @@ -94,27 +102,29 @@ png_write_info_before_PLTE(png_structp png_ptr, png_infop info_ptr) #endif } #endif -#if defined(PNG_WRITE_UNKNOWN_CHUNKS_SUPPORTED) +#ifdef PNG_WRITE_UNKNOWN_CHUNKS_SUPPORTED if (info_ptr->unknown_chunks_num) { - png_unknown_chunk *up; + png_unknown_chunk *up; - png_debug(5, "writing extra chunks\n"); + png_debug(5, "writing extra chunks"); - for (up = info_ptr->unknown_chunks; - up < info_ptr->unknown_chunks + info_ptr->unknown_chunks_num; - up++) - { - int keep=png_handle_as_unknown(png_ptr, up->name); + for (up = info_ptr->unknown_chunks; + up < info_ptr->unknown_chunks + info_ptr->unknown_chunks_num; + up++) + { + int keep = png_handle_as_unknown(png_ptr, up->name); if (keep != PNG_HANDLE_CHUNK_NEVER && up->location && !(up->location & PNG_HAVE_PLTE) && !(up->location & PNG_HAVE_IDAT) && ((up->name[3] & 0x20) || keep == PNG_HANDLE_CHUNK_ALWAYS || (png_ptr->flags & PNG_FLAG_KEEP_UNSAFE_CHUNKS))) { + if (up->size == 0) + png_warning(png_ptr, "Writing zero-length unknown chunk"); png_write_chunk(png_ptr, up->name, up->data, up->size); } - } + } } #endif png_ptr->mode |= PNG_WROTE_INFO_BEFORE_PLTE; @@ -128,7 +138,7 @@ png_write_info(png_structp png_ptr, png_infop info_ptr) int i; #endif - png_debug(1, "in png_write_info\n"); + png_debug(1, "in png_write_info"); if (png_ptr == NULL || info_ptr == NULL) return; @@ -141,85 +151,92 @@ png_write_info(png_structp png_ptr, png_infop info_ptr) else if (info_ptr->color_type == PNG_COLOR_TYPE_PALETTE) png_error(png_ptr, "Valid palette required for paletted images"); -#if defined(PNG_WRITE_tRNS_SUPPORTED) +#ifdef PNG_WRITE_tRNS_SUPPORTED if (info_ptr->valid & PNG_INFO_tRNS) + { +#ifdef PNG_WRITE_INVERT_ALPHA_SUPPORTED + /* Invert the alpha channel (in tRNS) */ + if ((png_ptr->transformations & PNG_INVERT_ALPHA) && + info_ptr->color_type == PNG_COLOR_TYPE_PALETTE) { -#if defined(PNG_WRITE_INVERT_ALPHA_SUPPORTED) - /* invert the alpha channel (in tRNS) */ - if ((png_ptr->transformations & PNG_INVERT_ALPHA) && - info_ptr->color_type == PNG_COLOR_TYPE_PALETTE) - { - int j; - for (j=0; j<(int)info_ptr->num_trans; j++) - info_ptr->trans[j] = (png_byte)(255 - info_ptr->trans[j]); - } + int j; + for (j = 0; j<(int)info_ptr->num_trans; j++) + info_ptr->trans[j] = (png_byte)(255 - info_ptr->trans[j]); + } #endif png_write_tRNS(png_ptr, info_ptr->trans, &(info_ptr->trans_values), info_ptr->num_trans, info_ptr->color_type); - } + } #endif -#if defined(PNG_WRITE_bKGD_SUPPORTED) +#ifdef PNG_WRITE_bKGD_SUPPORTED if (info_ptr->valid & PNG_INFO_bKGD) png_write_bKGD(png_ptr, &(info_ptr->background), info_ptr->color_type); #endif -#if defined(PNG_WRITE_hIST_SUPPORTED) +#ifdef PNG_WRITE_hIST_SUPPORTED if (info_ptr->valid & PNG_INFO_hIST) png_write_hIST(png_ptr, info_ptr->hist, info_ptr->num_palette); #endif -#if defined(PNG_WRITE_oFFs_SUPPORTED) +#ifdef PNG_WRITE_oFFs_SUPPORTED if (info_ptr->valid & PNG_INFO_oFFs) png_write_oFFs(png_ptr, info_ptr->x_offset, info_ptr->y_offset, info_ptr->offset_unit_type); #endif -#if defined(PNG_WRITE_pCAL_SUPPORTED) +#ifdef PNG_WRITE_pCAL_SUPPORTED if (info_ptr->valid & PNG_INFO_pCAL) png_write_pCAL(png_ptr, info_ptr->pcal_purpose, info_ptr->pcal_X0, info_ptr->pcal_X1, info_ptr->pcal_type, info_ptr->pcal_nparams, info_ptr->pcal_units, info_ptr->pcal_params); #endif -#if defined(PNG_WRITE_sCAL_SUPPORTED) + +#ifdef PNG_sCAL_SUPPORTED if (info_ptr->valid & PNG_INFO_sCAL) -#if defined(PNG_FLOATING_POINT_SUPPORTED) && !defined(PNG_NO_STDIO) +#ifdef PNG_WRITE_sCAL_SUPPORTED +#if defined(PNG_FLOATING_POINT_SUPPORTED) && defined(PNG_STDIO_SUPPORTED) png_write_sCAL(png_ptr, (int)info_ptr->scal_unit, info_ptr->scal_pixel_width, info_ptr->scal_pixel_height); -#else +#else /* !FLOATING_POINT */ #ifdef PNG_FIXED_POINT_SUPPORTED png_write_sCAL_s(png_ptr, (int)info_ptr->scal_unit, info_ptr->scal_s_width, info_ptr->scal_s_height); -#else +#endif /* FIXED_POINT */ +#endif /* FLOATING_POINT */ +#else /* !WRITE_sCAL */ png_warning(png_ptr, "png_write_sCAL not supported; sCAL chunk not written."); -#endif -#endif -#endif -#if defined(PNG_WRITE_pHYs_SUPPORTED) +#endif /* WRITE_sCAL */ +#endif /* sCAL */ + +#ifdef PNG_WRITE_pHYs_SUPPORTED if (info_ptr->valid & PNG_INFO_pHYs) png_write_pHYs(png_ptr, info_ptr->x_pixels_per_unit, info_ptr->y_pixels_per_unit, info_ptr->phys_unit_type); -#endif -#if defined(PNG_WRITE_tIME_SUPPORTED) +#endif /* pHYs */ + +#ifdef PNG_WRITE_tIME_SUPPORTED if (info_ptr->valid & PNG_INFO_tIME) { png_write_tIME(png_ptr, &(info_ptr->mod_time)); png_ptr->mode |= PNG_WROTE_tIME; } -#endif -#if defined(PNG_WRITE_sPLT_SUPPORTED) +#endif /* tIME */ + +#ifdef PNG_WRITE_sPLT_SUPPORTED if (info_ptr->valid & PNG_INFO_sPLT) for (i = 0; i < (int)info_ptr->splt_palettes_num; i++) png_write_sPLT(png_ptr, info_ptr->splt_palettes + i); -#endif -#if defined(PNG_WRITE_TEXT_SUPPORTED) +#endif /* sPLT */ + +#ifdef PNG_WRITE_TEXT_SUPPORTED /* Check to see if we need to write text chunks */ for (i = 0; i < info_ptr->num_text; i++) { - png_debug2(2, "Writing header text chunk %d, type %d\n", i, + png_debug2(2, "Writing header text chunk %d, type %d", i, info_ptr->text[i].compression); - /* an internationalized chunk? */ + /* An internationalized chunk? */ if (info_ptr->text[i].compression > 0) { -#if defined(PNG_WRITE_iTXt_SUPPORTED) - /* write international chunk */ +#ifdef PNG_WRITE_iTXt_SUPPORTED + /* Write international chunk */ png_write_iTXt(png_ptr, info_ptr->text[i].compression, info_ptr->text[i].key, @@ -235,8 +252,8 @@ png_write_info(png_structp png_ptr, png_infop info_ptr) /* If we want a compressed text chunk */ else if (info_ptr->text[i].compression == PNG_TEXT_COMPRESSION_zTXt) { -#if defined(PNG_WRITE_zTXt_SUPPORTED) - /* write compressed chunk */ +#ifdef PNG_WRITE_zTXt_SUPPORTED + /* Write compressed chunk */ png_write_zTXt(png_ptr, info_ptr->text[i].key, info_ptr->text[i].text, 0, info_ptr->text[i].compression); @@ -248,40 +265,43 @@ png_write_info(png_structp png_ptr, png_infop info_ptr) } else if (info_ptr->text[i].compression == PNG_TEXT_COMPRESSION_NONE) { -#if defined(PNG_WRITE_tEXt_SUPPORTED) - /* write uncompressed chunk */ +#ifdef PNG_WRITE_tEXt_SUPPORTED + /* Write uncompressed chunk */ png_write_tEXt(png_ptr, info_ptr->text[i].key, info_ptr->text[i].text, 0); + /* Mark this chunk as written */ + info_ptr->text[i].compression = PNG_TEXT_COMPRESSION_NONE_WR; #else + /* Can't get here */ png_warning(png_ptr, "Unable to write uncompressed text"); #endif - /* Mark this chunk as written */ - info_ptr->text[i].compression = PNG_TEXT_COMPRESSION_NONE_WR; } } -#endif -#if defined(PNG_WRITE_UNKNOWN_CHUNKS_SUPPORTED) +#endif /* tEXt */ + +#ifdef PNG_WRITE_UNKNOWN_CHUNKS_SUPPORTED if (info_ptr->unknown_chunks_num) { - png_unknown_chunk *up; + png_unknown_chunk *up; - png_debug(5, "writing extra chunks\n"); + png_debug(5, "writing extra chunks"); - for (up = info_ptr->unknown_chunks; - up < info_ptr->unknown_chunks + info_ptr->unknown_chunks_num; - up++) - { - int keep=png_handle_as_unknown(png_ptr, up->name); + for (up = info_ptr->unknown_chunks; + up < info_ptr->unknown_chunks + info_ptr->unknown_chunks_num; + up++) + { + int keep = png_handle_as_unknown(png_ptr, up->name); if (keep != PNG_HANDLE_CHUNK_NEVER && up->location && (up->location & PNG_HAVE_PLTE) && !(up->location & PNG_HAVE_IDAT) && + !(up->location & PNG_AFTER_IDAT) && ((up->name[3] & 0x20) || keep == PNG_HANDLE_CHUNK_ALWAYS || (png_ptr->flags & PNG_FLAG_KEEP_UNSAFE_CHUNKS))) { png_write_chunk(png_ptr, up->name, up->data, up->size); } - } + } } #endif } @@ -294,51 +314,52 @@ png_write_info(png_structp png_ptr, png_infop info_ptr) void PNGAPI png_write_end(png_structp png_ptr, png_infop info_ptr) { - png_debug(1, "in png_write_end\n"); + png_debug(1, "in png_write_end"); + if (png_ptr == NULL) return; if (!(png_ptr->mode & PNG_HAVE_IDAT)) png_error(png_ptr, "No IDATs written into file"); - /* see if user wants us to write information chunks */ + /* See if user wants us to write information chunks */ if (info_ptr != NULL) { -#if defined(PNG_WRITE_TEXT_SUPPORTED) +#ifdef PNG_WRITE_TEXT_SUPPORTED int i; /* local index variable */ #endif -#if defined(PNG_WRITE_tIME_SUPPORTED) - /* check to see if user has supplied a time chunk */ +#ifdef PNG_WRITE_tIME_SUPPORTED + /* Check to see if user has supplied a time chunk */ if ((info_ptr->valid & PNG_INFO_tIME) && !(png_ptr->mode & PNG_WROTE_tIME)) png_write_tIME(png_ptr, &(info_ptr->mod_time)); #endif -#if defined(PNG_WRITE_TEXT_SUPPORTED) - /* loop through comment chunks */ +#ifdef PNG_WRITE_TEXT_SUPPORTED + /* Loop through comment chunks */ for (i = 0; i < info_ptr->num_text; i++) { - png_debug2(2, "Writing trailer text chunk %d, type %d\n", i, + png_debug2(2, "Writing trailer text chunk %d, type %d", i, info_ptr->text[i].compression); - /* an internationalized chunk? */ + /* An internationalized chunk? */ if (info_ptr->text[i].compression > 0) { -#if defined(PNG_WRITE_iTXt_SUPPORTED) - /* write international chunk */ - png_write_iTXt(png_ptr, - info_ptr->text[i].compression, - info_ptr->text[i].key, - info_ptr->text[i].lang, - info_ptr->text[i].lang_key, - info_ptr->text[i].text); +#ifdef PNG_WRITE_iTXt_SUPPORTED + /* Write international chunk */ + png_write_iTXt(png_ptr, + info_ptr->text[i].compression, + info_ptr->text[i].key, + info_ptr->text[i].lang, + info_ptr->text[i].lang_key, + info_ptr->text[i].text); #else - png_warning(png_ptr, "Unable to write international text"); + png_warning(png_ptr, "Unable to write international text"); #endif - /* Mark this chunk as written */ - info_ptr->text[i].compression = PNG_TEXT_COMPRESSION_NONE_WR; + /* Mark this chunk as written */ + info_ptr->text[i].compression = PNG_TEXT_COMPRESSION_NONE_WR; } else if (info_ptr->text[i].compression >= PNG_TEXT_COMPRESSION_zTXt) { -#if defined(PNG_WRITE_zTXt_SUPPORTED) - /* write compressed chunk */ +#ifdef PNG_WRITE_zTXt_SUPPORTED + /* Write compressed chunk */ png_write_zTXt(png_ptr, info_ptr->text[i].key, info_ptr->text[i].text, 0, info_ptr->text[i].compression); @@ -350,8 +371,8 @@ png_write_end(png_structp png_ptr, png_infop info_ptr) } else if (info_ptr->text[i].compression == PNG_TEXT_COMPRESSION_NONE) { -#if defined(PNG_WRITE_tEXt_SUPPORTED) - /* write uncompressed chunk */ +#ifdef PNG_WRITE_tEXt_SUPPORTED + /* Write uncompressed chunk */ png_write_tEXt(png_ptr, info_ptr->text[i].key, info_ptr->text[i].text, 0); #else @@ -363,18 +384,18 @@ png_write_end(png_structp png_ptr, png_infop info_ptr) } } #endif -#if defined(PNG_WRITE_UNKNOWN_CHUNKS_SUPPORTED) +#ifdef PNG_WRITE_UNKNOWN_CHUNKS_SUPPORTED if (info_ptr->unknown_chunks_num) { - png_unknown_chunk *up; + png_unknown_chunk *up; - png_debug(5, "writing extra chunks\n"); + png_debug(5, "writing extra chunks"); - for (up = info_ptr->unknown_chunks; - up < info_ptr->unknown_chunks + info_ptr->unknown_chunks_num; - up++) - { - int keep=png_handle_as_unknown(png_ptr, up->name); + for (up = info_ptr->unknown_chunks; + up < info_ptr->unknown_chunks + info_ptr->unknown_chunks_num; + up++) + { + int keep = png_handle_as_unknown(png_ptr, up->name); if (keep != PNG_HANDLE_CHUNK_NEVER && up->location && (up->location & PNG_AFTER_IDAT) && ((up->name[3] & 0x20) || keep == PNG_HANDLE_CHUNK_ALWAYS || @@ -382,24 +403,36 @@ png_write_end(png_structp png_ptr, png_infop info_ptr) { png_write_chunk(png_ptr, up->name, up->data, up->size); } - } + } } #endif } png_ptr->mode |= PNG_AFTER_IDAT; - /* write end of PNG file */ + /* Write end of PNG file */ png_write_IEND(png_ptr); + /* This flush, added in libpng-1.0.8, removed from libpng-1.0.9beta03, + * and restored again in libpng-1.2.30, may cause some applications that + * do not set png_ptr->output_flush_fn to crash. If your application + * experiences a problem, please try building libpng with + * PNG_WRITE_FLUSH_AFTER_IEND_SUPPORTED defined, and report the event to + * png-mng-implement at lists.sf.net . + */ +#ifdef PNG_WRITE_FLUSH_SUPPORTED +# ifdef PNG_WRITE_FLUSH_AFTER_IEND_SUPPORTED + png_flush(png_ptr); +# endif +#endif } -#if defined(PNG_WRITE_tIME_SUPPORTED) -#if !defined(_WIN32_WCE) -/* "time.h" functions are not supported on WindowsCE */ +#ifdef PNG_CONVERT_tIME_SUPPORTED +/* "tm" structure is not supported on WindowsCE */ void PNGAPI png_convert_from_struct_tm(png_timep ptime, struct tm FAR * ttime) { - png_debug(1, "in png_convert_from_struct_tm\n"); + png_debug(1, "in png_convert_from_struct_tm"); + ptime->year = (png_uint_16)(1900 + ttime->tm_year); ptime->month = (png_byte)(ttime->tm_mon + 1); ptime->day = (png_byte)ttime->tm_mday; @@ -413,12 +446,12 @@ png_convert_from_time_t(png_timep ptime, time_t ttime) { struct tm *tbuf; - png_debug(1, "in png_convert_from_time_t\n"); + png_debug(1, "in png_convert_from_time_t"); + tbuf = gmtime(&ttime); png_convert_from_struct_tm(ptime, tbuf); } #endif -#endif /* Initialize png_ptr structure, and allocate any memory needed */ png_structp PNGAPI @@ -437,6 +470,9 @@ png_create_write_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, png_malloc_ptr malloc_fn, png_free_ptr free_fn) { #endif /* PNG_USER_MEM_SUPPORTED */ +#ifdef PNG_SETJMP_SUPPORTED + volatile +#endif png_structp png_ptr; #ifdef PNG_SETJMP_SUPPORTED #ifdef USE_FAR_KEYWORD @@ -444,7 +480,9 @@ png_create_write_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, #endif #endif int i; - png_debug(1, "in png_create_write_struct\n"); + + png_debug(1, "in png_create_write_struct"); + #ifdef PNG_USER_MEM_SUPPORTED png_ptr = (png_structp)png_create_struct_2(PNG_STRUCT_PNG, (png_malloc_ptr)malloc_fn, (png_voidp)mem_ptr); @@ -454,10 +492,10 @@ png_create_write_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, if (png_ptr == NULL) return (NULL); - /* added at libpng-1.2.6 */ + /* Added at libpng-1.2.6 */ #ifdef PNG_SET_USER_LIMITS_SUPPORTED - png_ptr->user_width_max=PNG_USER_WIDTH_MAX; - png_ptr->user_height_max=PNG_USER_HEIGHT_MAX; + png_ptr->user_width_max = PNG_USER_WIDTH_MAX; + png_ptr->user_height_max = PNG_USER_HEIGHT_MAX; #endif #ifdef PNG_SETJMP_SUPPORTED @@ -468,12 +506,17 @@ png_create_write_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, #endif { png_free(png_ptr, png_ptr->zbuf); - png_ptr->zbuf=NULL; - png_destroy_struct(png_ptr); + png_ptr->zbuf = NULL; +#ifdef PNG_USER_MEM_SUPPORTED + png_destroy_struct_2((png_voidp)png_ptr, + (png_free_ptr)free_fn, (png_voidp)mem_ptr); +#else + png_destroy_struct((png_voidp)png_ptr); +#endif return (NULL); } #ifdef USE_FAR_KEYWORD - png_memcpy(png_ptr->jmpbuf,jmpbuf,png_sizeof(jmp_buf)); + png_memcpy(png_ptr->jmpbuf, jmpbuf, png_sizeof(jmp_buf)); #endif #endif @@ -482,12 +525,15 @@ png_create_write_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, #endif /* PNG_USER_MEM_SUPPORTED */ png_set_error_fn(png_ptr, error_ptr, error_fn, warn_fn); - i=0; - do + if (user_png_ver) { - if(user_png_ver[i] != png_libpng_ver[i]) - png_ptr->flags |= PNG_FLAG_LIBRARY_MISMATCH; - } while (png_libpng_ver[i++]); + i = 0; + do + { + if (user_png_ver[i] != png_libpng_ver[i]) + png_ptr->flags |= PNG_FLAG_LIBRARY_MISMATCH; + } while (png_libpng_ver[i++]); + } if (png_ptr->flags & PNG_FLAG_LIBRARY_MISMATCH) { @@ -500,14 +546,14 @@ png_create_write_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, (user_png_ver[0] == '1' && user_png_ver[2] != png_libpng_ver[2]) || (user_png_ver[0] == '0' && user_png_ver[2] < '9')) { -#if !defined(PNG_NO_STDIO) && !defined(_WIN32_WCE) +#if defined(PNG_STDIO_SUPPORTED) && !defined(_WIN32_WCE) char msg[80]; if (user_png_ver) { - png_snprintf(msg, 80, - "Application was compiled with png.h from libpng-%.20s", - user_png_ver); - png_warning(png_ptr, msg); + png_snprintf(msg, 80, + "Application was compiled with png.h from libpng-%.20s", + user_png_ver); + png_warning(png_ptr, msg); } png_snprintf(msg, 80, "Application is running with png.c from libpng-%.20s", @@ -515,34 +561,35 @@ png_create_write_struct_2(png_const_charp user_png_ver, png_voidp error_ptr, png_warning(png_ptr, msg); #endif #ifdef PNG_ERROR_NUMBERS_SUPPORTED - png_ptr->flags=0; + png_ptr->flags = 0; #endif png_error(png_ptr, "Incompatible libpng version in application and library"); } } - /* initialize zbuf - compression buffer */ + /* Initialize zbuf - compression buffer */ png_ptr->zbuf_size = PNG_ZBUF_SIZE; png_ptr->zbuf = (png_bytep)png_malloc(png_ptr, - (png_uint_32)png_ptr->zbuf_size); + (png_uint_32)png_ptr->zbuf_size); png_set_write_fn(png_ptr, png_voidp_NULL, png_rw_ptr_NULL, png_flush_ptr_NULL); -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED png_set_filter_heuristics(png_ptr, PNG_FILTER_HEURISTIC_DEFAULT, 1, png_doublep_NULL, png_doublep_NULL); #endif #ifdef PNG_SETJMP_SUPPORTED -/* Applications that neglect to set up their own setjmp() and then encounter - a png_error() will longjmp here. Since the jmpbuf is then meaningless we - abort instead of returning. */ + /* Applications that neglect to set up their own setjmp() and then + * encounter a png_error() will longjmp here. Since the jmpbuf is + * then meaningless we abort instead of returning. + */ #ifdef USE_FAR_KEYWORD if (setjmp(jmpbuf)) PNG_ABORT(); - png_memcpy(png_ptr->jmpbuf,jmpbuf,png_sizeof(jmp_buf)); + png_memcpy(png_ptr->jmpbuf, jmpbuf, png_sizeof(jmp_buf)); #else if (setjmp(png_ptr->jmpbuf)) PNG_ABORT(); @@ -567,19 +614,19 @@ png_write_init_2(png_structp png_ptr, png_const_charp user_png_ver, png_size_t png_struct_size, png_size_t png_info_size) { /* We only come here via pre-1.0.12-compiled applications */ - if(png_ptr == NULL) return; -#if !defined(PNG_NO_STDIO) && !defined(_WIN32_WCE) - if(png_sizeof(png_struct) > png_struct_size || + if (png_ptr == NULL) return; +#if defined(PNG_STDIO_SUPPORTED) && !defined(_WIN32_WCE) + if (png_sizeof(png_struct) > png_struct_size || png_sizeof(png_info) > png_info_size) { char msg[80]; - png_ptr->warning_fn=NULL; + png_ptr->warning_fn = NULL; if (user_png_ver) { - png_snprintf(msg, 80, - "Application was compiled with png.h from libpng-%.20s", - user_png_ver); - png_warning(png_ptr, msg); + png_snprintf(msg, 80, + "Application was compiled with png.h from libpng-%.20s", + user_png_ver); + png_warning(png_ptr, msg); } png_snprintf(msg, 80, "Application is running with png.c from libpng-%.20s", @@ -587,24 +634,26 @@ png_write_init_2(png_structp png_ptr, png_const_charp user_png_ver, png_warning(png_ptr, msg); } #endif - if(png_sizeof(png_struct) > png_struct_size) - { - png_ptr->error_fn=NULL; + if (png_sizeof(png_struct) > png_struct_size) + { + png_ptr->error_fn = NULL; #ifdef PNG_ERROR_NUMBERS_SUPPORTED - png_ptr->flags=0; + png_ptr->flags = 0; #endif - png_error(png_ptr, - "The png struct allocated by the application for writing is too small."); - } - if(png_sizeof(png_info) > png_info_size) - { - png_ptr->error_fn=NULL; + png_error(png_ptr, + "The png struct allocated by the application for writing is" + " too small."); + } + if (png_sizeof(png_info) > png_info_size) + { + png_ptr->error_fn = NULL; #ifdef PNG_ERROR_NUMBERS_SUPPORTED - png_ptr->flags=0; + png_ptr->flags = 0; #endif - png_error(png_ptr, - "The info struct allocated by the application for writing is too small."); - } + png_error(png_ptr, + "The info struct allocated by the application for writing is" + " too small."); + } png_write_init_3(&png_ptr, user_png_ver, png_struct_size); } #endif /* PNG_1_0_X || PNG_1_2_X */ @@ -614,7 +663,7 @@ void PNGAPI png_write_init_3(png_structpp ptr_ptr, png_const_charp user_png_ver, png_size_t png_struct_size) { - png_structp png_ptr=*ptr_ptr; + png_structp png_ptr = *ptr_ptr; #ifdef PNG_SETJMP_SUPPORTED jmp_buf tmp_jmp; /* to save current jump buffer */ #endif @@ -626,56 +675,54 @@ png_write_init_3(png_structpp ptr_ptr, png_const_charp user_png_ver, do { - if (user_png_ver[i] != png_libpng_ver[i]) - { + if (user_png_ver[i] != png_libpng_ver[i]) + { #ifdef PNG_LEGACY_SUPPORTED - png_ptr->flags |= PNG_FLAG_LIBRARY_MISMATCH; + png_ptr->flags |= PNG_FLAG_LIBRARY_MISMATCH; #else - png_ptr->warning_fn=NULL; - png_warning(png_ptr, - "Application uses deprecated png_write_init() and should be recompiled."); - break; + png_ptr->warning_fn = NULL; + png_warning(png_ptr, + "Application uses deprecated png_write_init() and should be recompiled."); #endif - } + } } while (png_libpng_ver[i++]); - png_debug(1, "in png_write_init_3\n"); + png_debug(1, "in png_write_init_3"); #ifdef PNG_SETJMP_SUPPORTED - /* save jump buffer and error functions */ - png_memcpy(tmp_jmp, png_ptr->jmpbuf, png_sizeof (jmp_buf)); + /* Save jump buffer and error functions */ + png_memcpy(tmp_jmp, png_ptr->jmpbuf, png_sizeof(jmp_buf)); #endif if (png_sizeof(png_struct) > png_struct_size) - { - png_destroy_struct(png_ptr); - png_ptr = (png_structp)png_create_struct(PNG_STRUCT_PNG); - *ptr_ptr = png_ptr; - } + { + png_destroy_struct(png_ptr); + png_ptr = (png_structp)png_create_struct(PNG_STRUCT_PNG); + *ptr_ptr = png_ptr; + } - /* reset all variables to 0 */ - png_memset(png_ptr, 0, png_sizeof (png_struct)); + /* Reset all variables to 0 */ + png_memset(png_ptr, 0, png_sizeof(png_struct)); - /* added at libpng-1.2.6 */ + /* Added at libpng-1.2.6 */ #ifdef PNG_SET_USER_LIMITS_SUPPORTED - png_ptr->user_width_max=PNG_USER_WIDTH_MAX; - png_ptr->user_height_max=PNG_USER_HEIGHT_MAX; + png_ptr->user_width_max = PNG_USER_WIDTH_MAX; + png_ptr->user_height_max = PNG_USER_HEIGHT_MAX; #endif #ifdef PNG_SETJMP_SUPPORTED - /* restore jump buffer */ - png_memcpy(png_ptr->jmpbuf, tmp_jmp, png_sizeof (jmp_buf)); + /* Restore jump buffer */ + png_memcpy(png_ptr->jmpbuf, tmp_jmp, png_sizeof(jmp_buf)); #endif png_set_write_fn(png_ptr, png_voidp_NULL, png_rw_ptr_NULL, png_flush_ptr_NULL); - /* initialize zbuf - compression buffer */ + /* Initialize zbuf - compression buffer */ png_ptr->zbuf_size = PNG_ZBUF_SIZE; png_ptr->zbuf = (png_bytep)png_malloc(png_ptr, - (png_uint_32)png_ptr->zbuf_size); - -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) + (png_uint_32)png_ptr->zbuf_size); +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED png_set_filter_heuristics(png_ptr, PNG_FILTER_HEURISTIC_DEFAULT, 1, png_doublep_NULL, png_doublep_NULL); #endif @@ -693,12 +740,12 @@ png_write_rows(png_structp png_ptr, png_bytepp row, png_uint_32 i; /* row counter */ png_bytepp rp; /* row pointer */ - png_debug(1, "in png_write_rows\n"); + png_debug(1, "in png_write_rows"); if (png_ptr == NULL) return; - /* loop through the rows */ + /* Loop through the rows */ for (i = 0, rp = row; i < num_rows; i++, rp++) { png_write_row(png_ptr, *rp); @@ -718,18 +765,20 @@ png_write_image(png_structp png_ptr, png_bytepp image) if (png_ptr == NULL) return; - png_debug(1, "in png_write_image\n"); -#if defined(PNG_WRITE_INTERLACING_SUPPORTED) - /* intialize interlace handling. If image is not interlaced, - this will set pass to 1 */ + png_debug(1, "in png_write_image"); + +#ifdef PNG_WRITE_INTERLACING_SUPPORTED + /* Initialize interlace handling. If image is not interlaced, + * this will set pass to 1 + */ num_pass = png_set_interlace_handling(png_ptr); #else num_pass = 1; #endif - /* loop through passes */ + /* Loop through passes */ for (pass = 0; pass < num_pass; pass++) { - /* loop through image */ + /* Loop through image */ for (i = 0, rp = image; i < png_ptr->height; i++, rp++) { png_write_row(png_ptr, *rp); @@ -737,58 +786,63 @@ png_write_image(png_structp png_ptr, png_bytepp image) } } -/* called by user to write a row of image data */ +/* Called by user to write a row of image data */ void PNGAPI png_write_row(png_structp png_ptr, png_bytep row) { if (png_ptr == NULL) return; - png_debug2(1, "in png_write_row (row %ld, pass %d)\n", + + png_debug2(1, "in png_write_row (row %ld, pass %d)", png_ptr->row_number, png_ptr->pass); - /* initialize transformations and other stuff if first time */ + /* Initialize transformations and other stuff if first time */ if (png_ptr->row_number == 0 && png_ptr->pass == 0) { - /* make sure we wrote the header info */ - if (!(png_ptr->mode & PNG_WROTE_INFO_BEFORE_PLTE)) - png_error(png_ptr, - "png_write_info was never called before png_write_row."); + /* Make sure we wrote the header info */ + if (!(png_ptr->mode & PNG_WROTE_INFO_BEFORE_PLTE)) + png_error(png_ptr, + "png_write_info was never called before png_write_row."); - /* check for transforms that have been set but were defined out */ + /* Check for transforms that have been set but were defined out */ #if !defined(PNG_WRITE_INVERT_SUPPORTED) && defined(PNG_READ_INVERT_SUPPORTED) - if (png_ptr->transformations & PNG_INVERT_MONO) - png_warning(png_ptr, "PNG_WRITE_INVERT_SUPPORTED is not defined."); + if (png_ptr->transformations & PNG_INVERT_MONO) + png_warning(png_ptr, + "PNG_WRITE_INVERT_SUPPORTED is not defined."); #endif #if !defined(PNG_WRITE_FILLER_SUPPORTED) && defined(PNG_READ_FILLER_SUPPORTED) - if (png_ptr->transformations & PNG_FILLER) - png_warning(png_ptr, "PNG_WRITE_FILLER_SUPPORTED is not defined."); + if (png_ptr->transformations & PNG_FILLER) + png_warning(png_ptr, + "PNG_WRITE_FILLER_SUPPORTED is not defined."); #endif -#if !defined(PNG_WRITE_PACKSWAP_SUPPORTED) && defined(PNG_READ_PACKSWAP_SUPPORTED) - if (png_ptr->transformations & PNG_PACKSWAP) - png_warning(png_ptr, "PNG_WRITE_PACKSWAP_SUPPORTED is not defined."); +#if !defined(PNG_WRITE_PACKSWAP_SUPPORTED) && \ + defined(PNG_READ_PACKSWAP_SUPPORTED) + if (png_ptr->transformations & PNG_PACKSWAP) + png_warning(png_ptr, + "PNG_WRITE_PACKSWAP_SUPPORTED is not defined."); #endif #if !defined(PNG_WRITE_PACK_SUPPORTED) && defined(PNG_READ_PACK_SUPPORTED) - if (png_ptr->transformations & PNG_PACK) - png_warning(png_ptr, "PNG_WRITE_PACK_SUPPORTED is not defined."); + if (png_ptr->transformations & PNG_PACK) + png_warning(png_ptr, "PNG_WRITE_PACK_SUPPORTED is not defined."); #endif #if !defined(PNG_WRITE_SHIFT_SUPPORTED) && defined(PNG_READ_SHIFT_SUPPORTED) - if (png_ptr->transformations & PNG_SHIFT) - png_warning(png_ptr, "PNG_WRITE_SHIFT_SUPPORTED is not defined."); + if (png_ptr->transformations & PNG_SHIFT) + png_warning(png_ptr, "PNG_WRITE_SHIFT_SUPPORTED is not defined."); #endif #if !defined(PNG_WRITE_BGR_SUPPORTED) && defined(PNG_READ_BGR_SUPPORTED) - if (png_ptr->transformations & PNG_BGR) - png_warning(png_ptr, "PNG_WRITE_BGR_SUPPORTED is not defined."); + if (png_ptr->transformations & PNG_BGR) + png_warning(png_ptr, "PNG_WRITE_BGR_SUPPORTED is not defined."); #endif #if !defined(PNG_WRITE_SWAP_SUPPORTED) && defined(PNG_READ_SWAP_SUPPORTED) - if (png_ptr->transformations & PNG_SWAP_BYTES) - png_warning(png_ptr, "PNG_WRITE_SWAP_SUPPORTED is not defined."); + if (png_ptr->transformations & PNG_SWAP_BYTES) + png_warning(png_ptr, "PNG_WRITE_SWAP_SUPPORTED is not defined."); #endif png_write_start_row(png_ptr); } -#if defined(PNG_WRITE_INTERLACING_SUPPORTED) - /* if interlaced and not interested in row, return */ +#ifdef PNG_WRITE_INTERLACING_SUPPORTED + /* If interlaced and not interested in row, return */ if (png_ptr->interlaced && (png_ptr->transformations & PNG_INTERLACE)) { switch (png_ptr->pass) @@ -846,7 +900,7 @@ png_write_row(png_structp png_ptr, png_bytep row) } #endif - /* set up row info for transformations */ + /* Set up row info for transformations */ png_ptr->row_info.color_type = png_ptr->color_type; png_ptr->row_info.width = png_ptr->usr_width; png_ptr->row_info.channels = png_ptr->usr_channels; @@ -857,25 +911,25 @@ png_write_row(png_structp png_ptr, png_bytep row) png_ptr->row_info.rowbytes = PNG_ROWBYTES(png_ptr->row_info.pixel_depth, png_ptr->row_info.width); - png_debug1(3, "row_info->color_type = %d\n", png_ptr->row_info.color_type); - png_debug1(3, "row_info->width = %lu\n", png_ptr->row_info.width); - png_debug1(3, "row_info->channels = %d\n", png_ptr->row_info.channels); - png_debug1(3, "row_info->bit_depth = %d\n", png_ptr->row_info.bit_depth); - png_debug1(3, "row_info->pixel_depth = %d\n", png_ptr->row_info.pixel_depth); - png_debug1(3, "row_info->rowbytes = %lu\n", png_ptr->row_info.rowbytes); + png_debug1(3, "row_info->color_type = %d", png_ptr->row_info.color_type); + png_debug1(3, "row_info->width = %lu", png_ptr->row_info.width); + png_debug1(3, "row_info->channels = %d", png_ptr->row_info.channels); + png_debug1(3, "row_info->bit_depth = %d", png_ptr->row_info.bit_depth); + png_debug1(3, "row_info->pixel_depth = %d", png_ptr->row_info.pixel_depth); + png_debug1(3, "row_info->rowbytes = %lu", png_ptr->row_info.rowbytes); /* Copy user's row into buffer, leaving room for filter byte. */ png_memcpy_check(png_ptr, png_ptr->row_buf + 1, row, png_ptr->row_info.rowbytes); -#if defined(PNG_WRITE_INTERLACING_SUPPORTED) - /* handle interlacing */ +#ifdef PNG_WRITE_INTERLACING_SUPPORTED + /* Handle interlacing */ if (png_ptr->interlaced && png_ptr->pass < 6 && (png_ptr->transformations & PNG_INTERLACE)) { png_do_write_interlace(&(png_ptr->row_info), png_ptr->row_buf + 1, png_ptr->pass); - /* this should always get caught above, but still ... */ + /* This should always get caught above, but still ... */ if (!(png_ptr->row_info.width)) { png_write_finish_row(png_ptr); @@ -884,11 +938,11 @@ png_write_row(png_structp png_ptr, png_bytep row) } #endif - /* handle other transformations */ + /* Handle other transformations */ if (png_ptr->transformations) png_do_write_transformations(png_ptr); -#if defined(PNG_MNG_FEATURES_SUPPORTED) +#ifdef PNG_MNG_FEATURES_SUPPORTED /* Write filter_method 64 (intrapixel differencing) only if * 1. Libpng was compiled with PNG_MNG_FEATURES_SUPPORTED and * 2. Libpng did not write a PNG signature (this filter_method is only @@ -898,7 +952,7 @@ png_write_row(png_structp png_ptr, png_bytep row) * 4. The filter_method is 64 and * 5. The color_type is RGB or RGBA */ - if((png_ptr->mng_features_permitted & PNG_FLAG_MNG_FILTER_64) && + if ((png_ptr->mng_features_permitted & PNG_FLAG_MNG_FILTER_64) && (png_ptr->filter_type == PNG_INTRAPIXEL_DIFFERENCING)) { /* Intrapixel differencing */ @@ -913,39 +967,41 @@ png_write_row(png_structp png_ptr, png_bytep row) (*(png_ptr->write_row_fn))(png_ptr, png_ptr->row_number, png_ptr->pass); } -#if defined(PNG_WRITE_FLUSH_SUPPORTED) +#ifdef PNG_WRITE_FLUSH_SUPPORTED /* Set the automatic flush interval or 0 to turn flushing off */ void PNGAPI png_set_flush(png_structp png_ptr, int nrows) { - png_debug(1, "in png_set_flush\n"); + png_debug(1, "in png_set_flush"); + if (png_ptr == NULL) return; png_ptr->flush_dist = (nrows < 0 ? 0 : nrows); } -/* flush the current output buffers now */ +/* Flush the current output buffers now */ void PNGAPI png_write_flush(png_structp png_ptr) { int wrote_IDAT; - png_debug(1, "in png_write_flush\n"); + png_debug(1, "in png_write_flush"); + if (png_ptr == NULL) return; /* We have already written out all of the data */ if (png_ptr->row_number >= png_ptr->num_rows) - return; + return; do { int ret; - /* compress the data */ + /* Compress the data */ ret = deflate(&png_ptr->zstream, Z_SYNC_FLUSH); wrote_IDAT = 0; - /* check for compression errors */ + /* Check for compression errors */ if (ret != Z_OK) { if (png_ptr->zstream.msg != NULL) @@ -956,7 +1012,7 @@ png_write_flush(png_structp png_ptr) if (!(png_ptr->zstream.avail_out)) { - /* write the IDAT and reset the zlib output buffer */ + /* Write the IDAT and reset the zlib output buffer */ png_write_IDAT(png_ptr, png_ptr->zbuf, png_ptr->zbuf_size); png_ptr->zstream.next_out = png_ptr->zbuf; @@ -968,7 +1024,7 @@ png_write_flush(png_structp png_ptr) /* If there is any data left to be output, write it into a new IDAT */ if (png_ptr->zbuf_size != png_ptr->zstream.avail_out) { - /* write the IDAT and reset the zlib output buffer */ + /* Write the IDAT and reset the zlib output buffer */ png_write_IDAT(png_ptr, png_ptr->zbuf, png_ptr->zbuf_size - png_ptr->zstream.avail_out); png_ptr->zstream.next_out = png_ptr->zbuf; @@ -979,7 +1035,7 @@ png_write_flush(png_structp png_ptr) } #endif /* PNG_WRITE_FLUSH_SUPPORTED */ -/* free all memory used by the write */ +/* Free all memory used by the write */ void PNGAPI png_destroy_write_struct(png_structpp png_ptr_ptr, png_infopp info_ptr_ptr) { @@ -990,7 +1046,8 @@ png_destroy_write_struct(png_structpp png_ptr_ptr, png_infopp info_ptr_ptr) png_voidp mem_ptr = NULL; #endif - png_debug(1, "in png_destroy_write_struct\n"); + png_debug(1, "in png_destroy_write_struct"); + if (png_ptr_ptr != NULL) { png_ptr = *png_ptr_ptr; @@ -1000,21 +1057,32 @@ png_destroy_write_struct(png_structpp png_ptr_ptr, png_infopp info_ptr_ptr) #endif } +#ifdef PNG_USER_MEM_SUPPORTED + if (png_ptr != NULL) + { + free_fn = png_ptr->free_fn; + mem_ptr = png_ptr->mem_ptr; + } +#endif + if (info_ptr_ptr != NULL) info_ptr = *info_ptr_ptr; if (info_ptr != NULL) { - png_free_data(png_ptr, info_ptr, PNG_FREE_ALL, -1); - -#if defined(PNG_UNKNOWN_CHUNKS_SUPPORTED) - if (png_ptr->num_chunk_list) + if (png_ptr != NULL) { - png_free(png_ptr, png_ptr->chunk_list); - png_ptr->chunk_list=NULL; - png_ptr->num_chunk_list=0; - } + png_free_data(png_ptr, info_ptr, PNG_FREE_ALL, -1); + +#ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED + if (png_ptr->num_chunk_list) + { + png_free(png_ptr, png_ptr->chunk_list); + png_ptr->chunk_list = NULL; + png_ptr->num_chunk_list = 0; + } #endif + } #ifdef PNG_USER_MEM_SUPPORTED png_destroy_struct_2((png_voidp)info_ptr, (png_free_ptr)free_fn, @@ -1044,7 +1112,7 @@ void /* PRIVATE */ png_write_destroy(png_structp png_ptr) { #ifdef PNG_SETJMP_SUPPORTED - jmp_buf tmp_jmp; /* save jump buffer */ + jmp_buf tmp_jmp; /* Save jump buffer */ #endif png_error_ptr error_fn; png_error_ptr warning_fn; @@ -1053,24 +1121,27 @@ png_write_destroy(png_structp png_ptr) png_free_ptr free_fn; #endif - png_debug(1, "in png_write_destroy\n"); - /* free any memory zlib uses */ + png_debug(1, "in png_write_destroy"); + + /* Free any memory zlib uses */ deflateEnd(&png_ptr->zstream); - /* free our memory. png_free checks NULL for us. */ + /* Free our memory. png_free checks NULL for us. */ png_free(png_ptr, png_ptr->zbuf); png_free(png_ptr, png_ptr->row_buf); +#ifdef PNG_WRITE_FILTER_SUPPORTED png_free(png_ptr, png_ptr->prev_row); png_free(png_ptr, png_ptr->sub_row); png_free(png_ptr, png_ptr->up_row); png_free(png_ptr, png_ptr->avg_row); png_free(png_ptr, png_ptr->paeth_row); +#endif -#if defined(PNG_TIME_RFC1123_SUPPORTED) +#ifdef PNG_TIME_RFC1123_SUPPORTED png_free(png_ptr, png_ptr->time_buffer); #endif -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED png_free(png_ptr, png_ptr->prev_filters); png_free(png_ptr, png_ptr->filter_weights); png_free(png_ptr, png_ptr->inv_filter_weights); @@ -1079,8 +1150,8 @@ png_write_destroy(png_structp png_ptr) #endif #ifdef PNG_SETJMP_SUPPORTED - /* reset structure */ - png_memcpy(tmp_jmp, png_ptr->jmpbuf, png_sizeof (jmp_buf)); + /* Reset structure */ + png_memcpy(tmp_jmp, png_ptr->jmpbuf, png_sizeof(jmp_buf)); #endif error_fn = png_ptr->error_fn; @@ -1090,7 +1161,7 @@ png_write_destroy(png_structp png_ptr) free_fn = png_ptr->free_fn; #endif - png_memset(png_ptr, 0, png_sizeof (png_struct)); + png_memset(png_ptr, 0, png_sizeof(png_struct)); png_ptr->error_fn = error_fn; png_ptr->warning_fn = warning_fn; @@ -1100,7 +1171,7 @@ png_write_destroy(png_structp png_ptr) #endif #ifdef PNG_SETJMP_SUPPORTED - png_memcpy(png_ptr->jmpbuf, tmp_jmp, png_sizeof (jmp_buf)); + png_memcpy(png_ptr->jmpbuf, tmp_jmp, png_sizeof(jmp_buf)); #endif } @@ -1108,11 +1179,12 @@ png_write_destroy(png_structp png_ptr) void PNGAPI png_set_filter(png_structp png_ptr, int method, int filters) { - png_debug(1, "in png_set_filter\n"); + png_debug(1, "in png_set_filter"); + if (png_ptr == NULL) return; -#if defined(PNG_MNG_FEATURES_SUPPORTED) - if((png_ptr->mng_features_permitted & PNG_FLAG_MNG_FILTER_64) && +#ifdef PNG_MNG_FEATURES_SUPPORTED + if ((png_ptr->mng_features_permitted & PNG_FLAG_MNG_FILTER_64) && (method == PNG_INTRAPIXEL_DIFFERENCING)) method = PNG_FILTER_TYPE_BASE; #endif @@ -1120,26 +1192,26 @@ png_set_filter(png_structp png_ptr, int method, int filters) { switch (filters & (PNG_ALL_FILTERS | 0x07)) { -#ifndef PNG_NO_WRITE_FILTER +#ifdef PNG_WRITE_FILTER_SUPPORTED case 5: case 6: case 7: png_warning(png_ptr, "Unknown row filter for method 0"); -#endif /* PNG_NO_WRITE_FILTER */ +#endif /* PNG_WRITE_FILTER_SUPPORTED */ case PNG_FILTER_VALUE_NONE: - png_ptr->do_filter=PNG_FILTER_NONE; break; -#ifndef PNG_NO_WRITE_FILTER + png_ptr->do_filter = PNG_FILTER_NONE; break; +#ifdef PNG_WRITE_FILTER_SUPPORTED case PNG_FILTER_VALUE_SUB: - png_ptr->do_filter=PNG_FILTER_SUB; break; + png_ptr->do_filter = PNG_FILTER_SUB; break; case PNG_FILTER_VALUE_UP: - png_ptr->do_filter=PNG_FILTER_UP; break; + png_ptr->do_filter = PNG_FILTER_UP; break; case PNG_FILTER_VALUE_AVG: - png_ptr->do_filter=PNG_FILTER_AVG; break; + png_ptr->do_filter = PNG_FILTER_AVG; break; case PNG_FILTER_VALUE_PAETH: - png_ptr->do_filter=PNG_FILTER_PAETH; break; + png_ptr->do_filter = PNG_FILTER_PAETH; break; default: png_ptr->do_filter = (png_byte)filters; break; #else default: png_warning(png_ptr, "Unknown row filter for method 0"); -#endif /* PNG_NO_WRITE_FILTER */ +#endif /* PNG_WRITE_FILTER_SUPPORTED */ } /* If we have allocated the row_buf, this means we have already started @@ -1153,7 +1225,7 @@ png_set_filter(png_structp png_ptr, int method, int filters) */ if (png_ptr->row_buf != NULL) { -#ifndef PNG_NO_WRITE_FILTER +#ifdef PNG_WRITE_FILTER_SUPPORTED if ((png_ptr->do_filter & PNG_FILTER_SUB) && png_ptr->sub_row == NULL) { png_ptr->sub_row = (png_bytep)png_malloc(png_ptr, @@ -1208,7 +1280,7 @@ png_set_filter(png_structp png_ptr, int method, int filters) } if (png_ptr->do_filter == PNG_NO_FILTERS) -#endif /* PNG_NO_WRITE_FILTER */ +#endif /* PNG_WRITE_FILTER_SUPPORTED */ png_ptr->do_filter = PNG_FILTER_NONE; } } @@ -1223,7 +1295,7 @@ png_set_filter(png_structp png_ptr, int method, int filters) * filtered data going to zlib more consistent, hopefully resulting in * better compression. */ -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) /* GRR 970116 */ +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED /* GRR 970116 */ void PNGAPI png_set_filter_heuristics(png_structp png_ptr, int heuristic_method, int num_weights, png_doublep filter_weights, @@ -1231,7 +1303,8 @@ png_set_filter_heuristics(png_structp png_ptr, int heuristic_method, { int i; - png_debug(1, "in png_set_filter_heuristics\n"); + png_debug(1, "in png_set_filter_heuristics"); + if (png_ptr == NULL) return; if (heuristic_method >= PNG_FILTER_HEURISTIC_LAST) @@ -1345,7 +1418,8 @@ png_set_filter_heuristics(png_structp png_ptr, int heuristic_method, void PNGAPI png_set_compression_level(png_structp png_ptr, int level) { - png_debug(1, "in png_set_compression_level\n"); + png_debug(1, "in png_set_compression_level"); + if (png_ptr == NULL) return; png_ptr->flags |= PNG_FLAG_ZLIB_CUSTOM_LEVEL; @@ -1355,7 +1429,8 @@ png_set_compression_level(png_structp png_ptr, int level) void PNGAPI png_set_compression_mem_level(png_structp png_ptr, int mem_level) { - png_debug(1, "in png_set_compression_mem_level\n"); + png_debug(1, "in png_set_compression_mem_level"); + if (png_ptr == NULL) return; png_ptr->flags |= PNG_FLAG_ZLIB_CUSTOM_MEM_LEVEL; @@ -1365,7 +1440,8 @@ png_set_compression_mem_level(png_structp png_ptr, int mem_level) void PNGAPI png_set_compression_strategy(png_structp png_ptr, int strategy) { - png_debug(1, "in png_set_compression_strategy\n"); + png_debug(1, "in png_set_compression_strategy"); + if (png_ptr == NULL) return; png_ptr->flags |= PNG_FLAG_ZLIB_CUSTOM_STRATEGY; @@ -1382,11 +1458,11 @@ png_set_compression_window_bits(png_structp png_ptr, int window_bits) else if (window_bits < 8) png_warning(png_ptr, "Only compression windows >= 256 supported by PNG"); #ifndef WBITS_8_OK - /* avoid libpng bug with 256-byte windows */ + /* Avoid libpng bug with 256-byte windows */ if (window_bits == 8) { png_warning(png_ptr, "Compression window is being reset to 512"); - window_bits=9; + window_bits = 9; } #endif png_ptr->flags |= PNG_FLAG_ZLIB_CUSTOM_WINDOW_BITS; @@ -1396,7 +1472,8 @@ png_set_compression_window_bits(png_structp png_ptr, int window_bits) void PNGAPI png_set_compression_method(png_structp png_ptr, int method) { - png_debug(1, "in png_set_compression_method\n"); + png_debug(1, "in png_set_compression_method"); + if (png_ptr == NULL) return; if (method != 8) @@ -1413,12 +1490,13 @@ png_set_write_status_fn(png_structp png_ptr, png_write_status_ptr write_row_fn) png_ptr->write_row_fn = write_row_fn; } -#if defined(PNG_WRITE_USER_TRANSFORM_SUPPORTED) +#ifdef PNG_WRITE_USER_TRANSFORM_SUPPORTED void PNGAPI png_set_write_user_transform_fn(png_structp png_ptr, png_user_transform_ptr write_user_transform_fn) { - png_debug(1, "in png_set_write_user_transform_fn\n"); + png_debug(1, "in png_set_write_user_transform_fn"); + if (png_ptr == NULL) return; png_ptr->transformations |= PNG_USER_TRANSFORM; @@ -1427,87 +1505,88 @@ png_set_write_user_transform_fn(png_structp png_ptr, png_user_transform_ptr #endif -#if defined(PNG_INFO_IMAGE_SUPPORTED) +#ifdef PNG_INFO_IMAGE_SUPPORTED void PNGAPI png_write_png(png_structp png_ptr, png_infop info_ptr, int transforms, voidp params) { if (png_ptr == NULL || info_ptr == NULL) return; -#if defined(PNG_WRITE_INVERT_ALPHA_SUPPORTED) - /* invert the alpha channel from opacity to transparency */ - if (transforms & PNG_TRANSFORM_INVERT_ALPHA) - png_set_invert_alpha(png_ptr); -#endif /* Write the file header information. */ png_write_info(png_ptr, info_ptr); /* ------ these transformations don't touch the info structure ------- */ -#if defined(PNG_WRITE_INVERT_SUPPORTED) - /* invert monochrome pixels */ +#ifdef PNG_WRITE_INVERT_SUPPORTED + /* Invert monochrome pixels */ if (transforms & PNG_TRANSFORM_INVERT_MONO) - png_set_invert_mono(png_ptr); + png_set_invert_mono(png_ptr); #endif -#if defined(PNG_WRITE_SHIFT_SUPPORTED) +#ifdef PNG_WRITE_SHIFT_SUPPORTED /* Shift the pixels up to a legal bit depth and fill in * as appropriate to correctly scale the image. */ if ((transforms & PNG_TRANSFORM_SHIFT) && (info_ptr->valid & PNG_INFO_sBIT)) - png_set_shift(png_ptr, &info_ptr->sig_bit); + png_set_shift(png_ptr, &info_ptr->sig_bit); #endif -#if defined(PNG_WRITE_PACK_SUPPORTED) - /* pack pixels into bytes */ +#ifdef PNG_WRITE_PACK_SUPPORTED + /* Pack pixels into bytes */ if (transforms & PNG_TRANSFORM_PACKING) png_set_packing(png_ptr); #endif -#if defined(PNG_WRITE_SWAP_ALPHA_SUPPORTED) - /* swap location of alpha bytes from ARGB to RGBA */ +#ifdef PNG_WRITE_SWAP_ALPHA_SUPPORTED + /* Swap location of alpha bytes from ARGB to RGBA */ if (transforms & PNG_TRANSFORM_SWAP_ALPHA) - png_set_swap_alpha(png_ptr); + png_set_swap_alpha(png_ptr); #endif -#if defined(PNG_WRITE_FILLER_SUPPORTED) - /* Get rid of filler (OR ALPHA) bytes, pack XRGB/RGBX/ARGB/RGBA into - * RGB (4 channels -> 3 channels). The second parameter is not used. - */ - if (transforms & PNG_TRANSFORM_STRIP_FILLER) - png_set_filler(png_ptr, 0, PNG_FILLER_BEFORE); +#ifdef PNG_WRITE_FILLER_SUPPORTED + /* Pack XRGB/RGBX/ARGB/RGBA into * RGB (4 channels -> 3 channels) */ + if (transforms & PNG_TRANSFORM_STRIP_FILLER_AFTER) + png_set_filler(png_ptr, 0, PNG_FILLER_AFTER); + else if (transforms & PNG_TRANSFORM_STRIP_FILLER_BEFORE) + png_set_filler(png_ptr, 0, PNG_FILLER_BEFORE); #endif -#if defined(PNG_WRITE_BGR_SUPPORTED) - /* flip BGR pixels to RGB */ +#ifdef PNG_WRITE_BGR_SUPPORTED + /* Flip BGR pixels to RGB */ if (transforms & PNG_TRANSFORM_BGR) - png_set_bgr(png_ptr); + png_set_bgr(png_ptr); #endif -#if defined(PNG_WRITE_SWAP_SUPPORTED) - /* swap bytes of 16-bit files to most significant byte first */ +#ifdef PNG_WRITE_SWAP_SUPPORTED + /* Swap bytes of 16-bit files to most significant byte first */ if (transforms & PNG_TRANSFORM_SWAP_ENDIAN) - png_set_swap(png_ptr); + png_set_swap(png_ptr); #endif -#if defined(PNG_WRITE_PACKSWAP_SUPPORTED) - /* swap bits of 1, 2, 4 bit packed pixel formats */ +#ifdef PNG_WRITE_PACKSWAP_SUPPORTED + /* Swap bits of 1, 2, 4 bit packed pixel formats */ if (transforms & PNG_TRANSFORM_PACKSWAP) - png_set_packswap(png_ptr); + png_set_packswap(png_ptr); +#endif + +#ifdef PNG_WRITE_INVERT_ALPHA_SUPPORTED + /* Invert the alpha channel from opacity to transparency */ + if (transforms & PNG_TRANSFORM_INVERT_ALPHA) + png_set_invert_alpha(png_ptr); #endif /* ----------------------- end of transformations ------------------- */ - /* write the bits */ + /* Write the bits */ if (info_ptr->valid & PNG_INFO_IDAT) png_write_image(png_ptr, info_ptr->row_pointers); /* It is REQUIRED to call this to finish writing the rest of the file */ png_write_end(png_ptr, info_ptr); - transforms = transforms; /* quiet compiler warnings */ + transforms = transforms; /* Quiet compiler warnings */ params = params; } #endif diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngwtran.c b/graf2d/asimage/src/libAfterImage/libpng/pngwtran.c index 0372fe656ced7..0ce9b9b501ea6 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngwtran.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngwtran.c @@ -1,14 +1,18 @@ /* pngwtran.c - transforms the data in a row for PNG writers * - * Last changed in libpng 1.2.9 April 14, 2006 - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2006 Glenn Randers-Pehrson + * Last changed in libpng 1.2.43 [February 25, 2010] + * Copyright (c) 1998-2010 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) + * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" #ifdef PNG_WRITE_SUPPORTED @@ -18,15 +22,16 @@ void /* PRIVATE */ png_do_write_transformations(png_structp png_ptr) { - png_debug(1, "in png_do_write_transformations\n"); + png_debug(1, "in png_do_write_transformations"); if (png_ptr == NULL) return; -#if defined(PNG_WRITE_USER_TRANSFORM_SUPPORTED) +#ifdef PNG_WRITE_USER_TRANSFORM_SUPPORTED if (png_ptr->transformations & PNG_USER_TRANSFORM) - if(png_ptr->write_user_transform_fn != NULL) - (*(png_ptr->write_user_transform_fn)) /* user write transform function */ + if (png_ptr->write_user_transform_fn != NULL) + (*(png_ptr->write_user_transform_fn)) /* User write transform + function */ (png_ptr, /* png_ptr */ &(png_ptr->row_info), /* row_info: */ /* png_uint_32 width; width of row */ @@ -37,48 +42,48 @@ png_do_write_transformations(png_structp png_ptr) /* png_byte pixel_depth; bits per pixel (depth*channels) */ png_ptr->row_buf + 1); /* start of pixel data for row */ #endif -#if defined(PNG_WRITE_FILLER_SUPPORTED) +#ifdef PNG_WRITE_FILLER_SUPPORTED if (png_ptr->transformations & PNG_FILLER) png_do_strip_filler(&(png_ptr->row_info), png_ptr->row_buf + 1, png_ptr->flags); #endif -#if defined(PNG_WRITE_PACKSWAP_SUPPORTED) +#ifdef PNG_WRITE_PACKSWAP_SUPPORTED if (png_ptr->transformations & PNG_PACKSWAP) png_do_packswap(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_WRITE_PACK_SUPPORTED) +#ifdef PNG_WRITE_PACK_SUPPORTED if (png_ptr->transformations & PNG_PACK) png_do_pack(&(png_ptr->row_info), png_ptr->row_buf + 1, (png_uint_32)png_ptr->bit_depth); #endif -#if defined(PNG_WRITE_SWAP_SUPPORTED) +#ifdef PNG_WRITE_SWAP_SUPPORTED if (png_ptr->transformations & PNG_SWAP_BYTES) png_do_swap(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_WRITE_SHIFT_SUPPORTED) +#ifdef PNG_WRITE_SHIFT_SUPPORTED if (png_ptr->transformations & PNG_SHIFT) png_do_shift(&(png_ptr->row_info), png_ptr->row_buf + 1, &(png_ptr->shift)); #endif -#if defined(PNG_WRITE_SWAP_ALPHA_SUPPORTED) +#ifdef PNG_WRITE_SWAP_ALPHA_SUPPORTED if (png_ptr->transformations & PNG_SWAP_ALPHA) png_do_write_swap_alpha(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_WRITE_INVERT_ALPHA_SUPPORTED) +#ifdef PNG_WRITE_INVERT_ALPHA_SUPPORTED if (png_ptr->transformations & PNG_INVERT_ALPHA) png_do_write_invert_alpha(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_WRITE_BGR_SUPPORTED) +#ifdef PNG_WRITE_BGR_SUPPORTED if (png_ptr->transformations & PNG_BGR) png_do_bgr(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif -#if defined(PNG_WRITE_INVERT_SUPPORTED) +#ifdef PNG_WRITE_INVERT_SUPPORTED if (png_ptr->transformations & PNG_INVERT_MONO) png_do_invert(&(png_ptr->row_info), png_ptr->row_buf + 1); #endif } -#if defined(PNG_WRITE_PACK_SUPPORTED) +#ifdef PNG_WRITE_PACK_SUPPORTED /* Pack pixels into bytes. Pass the true bit depth in bit_depth. The * row_info bit depth should be 8 (one pixel per byte). The channels * should be 1 (this only happens on grayscale and paletted images). @@ -86,9 +91,10 @@ png_do_write_transformations(png_structp png_ptr) void /* PRIVATE */ png_do_pack(png_row_infop row_info, png_bytep row, png_uint_32 bit_depth) { - png_debug(1, "in png_do_pack\n"); + png_debug(1, "in png_do_pack"); + if (row_info->bit_depth == 8 && -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && #endif row_info->channels == 1) @@ -201,7 +207,7 @@ png_do_pack(png_row_infop row_info, png_bytep row, png_uint_32 bit_depth) } #endif -#if defined(PNG_WRITE_SHIFT_SUPPORTED) +#ifdef PNG_WRITE_SHIFT_SUPPORTED /* Shift pixel values to take advantage of whole range. Pass the * true number of bits in bit_depth. The row should be packed * according to row_info->bit_depth. Thus, if you had a row of @@ -212,8 +218,9 @@ png_do_pack(png_row_infop row_info, png_bytep row, png_uint_32 bit_depth) void /* PRIVATE */ png_do_shift(png_row_infop row_info, png_bytep row, png_color_8p bit_depth) { - png_debug(1, "in png_do_shift\n"); -#if defined(PNG_USELESS_TESTS_SUPPORTED) + png_debug(1, "in png_do_shift"); + +#ifdef PNG_USELESS_TESTS_SUPPORTED if (row != NULL && row_info != NULL && #else if ( @@ -248,7 +255,7 @@ png_do_shift(png_row_infop row_info, png_bytep row, png_color_8p bit_depth) channels++; } - /* with low row depths, could only be grayscale, so one channel */ + /* With low row depths, could only be grayscale, so one channel */ if (row_info->bit_depth < 8) { png_bytep bp = row; @@ -332,12 +339,13 @@ png_do_shift(png_row_infop row_info, png_bytep row, png_color_8p bit_depth) } #endif -#if defined(PNG_WRITE_SWAP_ALPHA_SUPPORTED) +#ifdef PNG_WRITE_SWAP_ALPHA_SUPPORTED void /* PRIVATE */ png_do_write_swap_alpha(png_row_infop row_info, png_bytep row) { - png_debug(1, "in png_do_write_swap_alpha\n"); -#if defined(PNG_USELESS_TESTS_SUPPORTED) + png_debug(1, "in png_do_write_swap_alpha"); + +#ifdef PNG_USELESS_TESTS_SUPPORTED if (row != NULL && row_info != NULL) #endif { @@ -420,12 +428,13 @@ png_do_write_swap_alpha(png_row_infop row_info, png_bytep row) } #endif -#if defined(PNG_WRITE_INVERT_ALPHA_SUPPORTED) +#ifdef PNG_WRITE_INVERT_ALPHA_SUPPORTED void /* PRIVATE */ png_do_write_invert_alpha(png_row_infop row_info, png_bytep row) { - png_debug(1, "in png_do_write_invert_alpha\n"); -#if defined(PNG_USELESS_TESTS_SUPPORTED) + png_debug(1, "in png_do_write_invert_alpha"); + +#ifdef PNG_USELESS_TESTS_SUPPORTED if (row != NULL && row_info != NULL) #endif { @@ -439,7 +448,7 @@ png_do_write_invert_alpha(png_row_infop row_info, png_bytep row) png_uint_32 row_width = row_info->width; for (i = 0, sp = dp = row; i < row_width; i++) { - /* does nothing + /* Does nothing *(dp++) = *(sp++); *(dp++) = *(sp++); *(dp++) = *(sp++); @@ -457,7 +466,7 @@ png_do_write_invert_alpha(png_row_infop row_info, png_bytep row) for (i = 0, sp = dp = row; i < row_width; i++) { - /* does nothing + /* Does nothing *(dp++) = *(sp++); *(dp++) = *(sp++); *(dp++) = *(sp++); @@ -495,7 +504,7 @@ png_do_write_invert_alpha(png_row_infop row_info, png_bytep row) for (i = 0, sp = dp = row; i < row_width; i++) { - /* does nothing + /* Does nothing *(dp++) = *(sp++); *(dp++) = *(sp++); */ @@ -509,14 +518,15 @@ png_do_write_invert_alpha(png_row_infop row_info, png_bytep row) } #endif -#if defined(PNG_MNG_FEATURES_SUPPORTED) -/* undoes intrapixel differencing */ +#ifdef PNG_MNG_FEATURES_SUPPORTED +/* Undoes intrapixel differencing */ void /* PRIVATE */ png_do_write_intrapixel(png_row_infop row_info, png_bytep row) { - png_debug(1, "in png_do_write_intrapixel\n"); + png_debug(1, "in png_do_write_intrapixel"); + if ( -#if defined(PNG_USELESS_TESTS_SUPPORTED) +#ifdef PNG_USELESS_TESTS_SUPPORTED row != NULL && row_info != NULL && #endif (row_info->color_type & PNG_COLOR_MASK_COLOR)) @@ -558,8 +568,8 @@ png_do_write_intrapixel(png_row_infop row_info, png_bytep row) png_uint_32 s0 = (*(rp ) << 8) | *(rp+1); png_uint_32 s1 = (*(rp+2) << 8) | *(rp+3); png_uint_32 s2 = (*(rp+4) << 8) | *(rp+5); - png_uint_32 red = (png_uint_32)((s0-s1) & 0xffffL); - png_uint_32 blue = (png_uint_32)((s2-s1) & 0xffffL); + png_uint_32 red = (png_uint_32)((s0 - s1) & 0xffffL); + png_uint_32 blue = (png_uint_32)((s2 - s1) & 0xffffL); *(rp ) = (png_byte)((red >> 8) & 0xff); *(rp+1) = (png_byte)(red & 0xff); *(rp+4) = (png_byte)((blue >> 8) & 0xff); diff --git a/graf2d/asimage/src/libAfterImage/libpng/pngwutil.c b/graf2d/asimage/src/libAfterImage/libpng/pngwutil.c index fef38aef9dd68..c75f53eb7de8d 100644 --- a/graf2d/asimage/src/libAfterImage/libpng/pngwutil.c +++ b/graf2d/asimage/src/libAfterImage/libpng/pngwutil.c @@ -1,14 +1,18 @@ /* pngwutil.c - utilities to write a PNG file * - * Last changed in libpng 1.2.20 Septhember 3, 2007 - * For conditions of distribution and use, see copyright notice in png.h - * Copyright (c) 1998-2007 Glenn Randers-Pehrson + * Last changed in libpng 1.2.43 [February 25, 2010] + * Copyright (c) 1998-2010 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) + * + * This code is released under the libpng license. + * For conditions of distribution and use, see the disclaimer + * and license in png.h */ #define PNG_INTERNAL +#define PNG_NO_PEDANTIC_WARNINGS #include "png.h" #ifdef PNG_WRITE_SUPPORTED @@ -49,6 +53,24 @@ png_save_uint_16(png_bytep buf, unsigned int i) buf[1] = (png_byte)(i & 0xff); } +/* Simple function to write the signature. If we have already written + * the magic bytes of the signature, or more likely, the PNG stream is + * being embedded into another stream and doesn't need its own signature, + * we should call png_set_sig_bytes() to tell libpng how many of the + * bytes have already been written. + */ +void /* PRIVATE */ +png_write_sig(png_structp png_ptr) +{ + png_byte png_signature[8] = {137, 80, 78, 71, 13, 10, 26, 10}; + + /* Write the rest of the 8 byte signature */ + png_write_data(png_ptr, &png_signature[png_ptr->sig_bytes], + (png_size_t)(8 - png_ptr->sig_bytes)); + if (png_ptr->sig_bytes < 3) + png_ptr->mode |= PNG_HAVE_PNG_SIGNATURE; +} + /* Write a PNG chunk all at once. The type is an array of ASCII characters * representing the chunk name. The array must be at least 4 bytes in * length, and does not need to be null terminated. To be safe, pass the @@ -62,9 +84,10 @@ void PNGAPI png_write_chunk(png_structp png_ptr, png_bytep chunk_name, png_bytep data, png_size_t length) { - if(png_ptr == NULL) return; + if (png_ptr == NULL) + return; png_write_chunk_start(png_ptr, chunk_name, (png_uint_32)length); - png_write_chunk_data(png_ptr, data, length); + png_write_chunk_data(png_ptr, data, (png_size_t)length); png_write_chunk_end(png_ptr); } @@ -76,17 +99,22 @@ void PNGAPI png_write_chunk_start(png_structp png_ptr, png_bytep chunk_name, png_uint_32 length) { - png_byte buf[4]; - png_debug2(0, "Writing %s chunk (%lu bytes)\n", chunk_name, length); - if(png_ptr == NULL) return; + png_byte buf[8]; - /* write the length */ - png_save_uint_32(buf, length); - png_write_data(png_ptr, buf, (png_size_t)4); + png_debug2(0, "Writing %s chunk, length = %lu", chunk_name, + (unsigned long)length); + + if (png_ptr == NULL) + return; - /* write the chunk name */ - png_write_data(png_ptr, chunk_name, (png_size_t)4); - /* reset the crc and run it over the chunk name */ + + /* Write the length and the chunk name */ + png_save_uint_32(buf, length); + png_memcpy(buf + 4, chunk_name, 4); + png_write_data(png_ptr, buf, (png_size_t)8); + /* Put the chunk name into png_ptr->chunk_name */ + png_memcpy(png_ptr->chunk_name, chunk_name, 4); + /* Reset the crc and run it over the chunk name */ png_reset_crc(png_ptr); png_calculate_crc(png_ptr, chunk_name, (png_size_t)4); } @@ -99,12 +127,16 @@ png_write_chunk_start(png_structp png_ptr, png_bytep chunk_name, void PNGAPI png_write_chunk_data(png_structp png_ptr, png_bytep data, png_size_t length) { - /* write the data, and run the CRC over it */ - if(png_ptr == NULL) return; + /* Write the data, and run the CRC over it */ + if (png_ptr == NULL) + return; if (data != NULL && length > 0) { - png_calculate_crc(png_ptr, data, length); png_write_data(png_ptr, data, length); + /* Update the CRC after writing the data, + * in case that the user I/O routine alters it. + */ + png_calculate_crc(png_ptr, data, length); } } @@ -114,34 +146,16 @@ png_write_chunk_end(png_structp png_ptr) { png_byte buf[4]; - if(png_ptr == NULL) return; + if (png_ptr == NULL) return; - /* write the crc */ + /* Write the crc in a single operation */ png_save_uint_32(buf, png_ptr->crc); png_write_data(png_ptr, buf, (png_size_t)4); } -/* Simple function to write the signature. If we have already written - * the magic bytes of the signature, or more likely, the PNG stream is - * being embedded into another stream and doesn't need its own signature, - * we should call png_set_sig_bytes() to tell libpng how many of the - * bytes have already been written. - */ -void /* PRIVATE */ -png_write_sig(png_structp png_ptr) -{ - png_byte png_signature[8] = {137, 80, 78, 71, 13, 10, 26, 10}; - /* write the rest of the 8 byte signature */ - png_write_data(png_ptr, &png_signature[png_ptr->sig_bytes], - (png_size_t)8 - png_ptr->sig_bytes); - if(png_ptr->sig_bytes < 3) - png_ptr->mode |= PNG_HAVE_PNG_SIGNATURE; -} - #if defined(PNG_WRITE_TEXT_SUPPORTED) || defined(PNG_WRITE_iCCP_SUPPORTED) -/* - * This pair of functions encapsulates the operation of (a) compressing a +/* This pair of functions encapsulates the operation of (a) compressing a * text string, and (b) issuing it later as a series of chunk data writes. * The compression_state structure is shared context for these functions * set up by the caller in order to make the whole mess thread-safe. @@ -149,14 +163,14 @@ png_write_sig(png_structp png_ptr) typedef struct { - char *input; /* the uncompressed input data */ - int input_len; /* its length */ - int num_output_ptr; /* number of output pointers used */ - int max_output_ptr; /* size of output_ptr */ - png_charpp output_ptr; /* array of pointers to output */ + char *input; /* The uncompressed input data */ + int input_len; /* Its length */ + int num_output_ptr; /* Number of output pointers used */ + int max_output_ptr; /* Size of output_ptr */ + png_charpp output_ptr; /* Array of pointers to output */ } compression_state; -/* compress given text into storage in the png_ptr structure */ +/* Compress given text into storage in the png_ptr structure */ static int /* PRIVATE */ png_text_compress(png_structp png_ptr, png_charp text, png_size_t text_len, int compression, @@ -170,7 +184,7 @@ png_text_compress(png_structp png_ptr, comp->input = NULL; comp->input_len = 0; - /* we may just want to pass the text right through */ + /* We may just want to pass the text right through */ if (compression == PNG_TEXT_COMPRESSION_NONE) { comp->input = text; @@ -180,7 +194,7 @@ png_text_compress(png_structp png_ptr, if (compression >= PNG_TEXT_COMPRESSION_LAST) { -#if !defined(PNG_NO_STDIO) && !defined(_WIN32_WCE) +#if defined(PNG_STDIO_SUPPORTED) && !defined(_WIN32_WCE) char msg[50]; png_snprintf(msg, 50, "Unknown compression type %d", compression); png_warning(png_ptr, msg); @@ -204,29 +218,29 @@ png_text_compress(png_structp png_ptr, * wouldn't cause a failure, just a slowdown due to swapping). */ - /* set up the compression buffers */ + /* Set up the compression buffers */ png_ptr->zstream.avail_in = (uInt)text_len; png_ptr->zstream.next_in = (Bytef *)text; png_ptr->zstream.avail_out = (uInt)png_ptr->zbuf_size; png_ptr->zstream.next_out = (Bytef *)png_ptr->zbuf; - /* this is the same compression loop as in png_write_row() */ + /* This is the same compression loop as in png_write_row() */ do { - /* compress the data */ + /* Compress the data */ ret = deflate(&png_ptr->zstream, Z_NO_FLUSH); if (ret != Z_OK) { - /* error */ + /* Error */ if (png_ptr->zstream.msg != NULL) png_error(png_ptr, png_ptr->zstream.msg); else png_error(png_ptr, "zlib error"); } - /* check to see if we need more room */ + /* Check to see if we need more room */ if (!(png_ptr->zstream.avail_out)) { - /* make sure the output array has room */ + /* Make sure the output array has room */ if (comp->num_output_ptr >= comp->max_output_ptr) { int old_max; @@ -239,20 +253,21 @@ png_text_compress(png_structp png_ptr, old_ptr = comp->output_ptr; comp->output_ptr = (png_charpp)png_malloc(png_ptr, - (png_uint_32)(comp->max_output_ptr * - png_sizeof (png_charpp))); + (png_uint_32) + (comp->max_output_ptr * png_sizeof(png_charpp))); png_memcpy(comp->output_ptr, old_ptr, old_max - * png_sizeof (png_charp)); + * png_sizeof(png_charp)); png_free(png_ptr, old_ptr); } else comp->output_ptr = (png_charpp)png_malloc(png_ptr, - (png_uint_32)(comp->max_output_ptr * - png_sizeof (png_charp))); + (png_uint_32) + (comp->max_output_ptr * png_sizeof(png_charp))); } - /* save the data */ - comp->output_ptr[comp->num_output_ptr] = (png_charp)png_malloc(png_ptr, + /* Save the data */ + comp->output_ptr[comp->num_output_ptr] = + (png_charp)png_malloc(png_ptr, (png_uint_32)png_ptr->zbuf_size); png_memcpy(comp->output_ptr[comp->num_output_ptr], png_ptr->zbuf, png_ptr->zbuf_size); @@ -262,21 +277,21 @@ png_text_compress(png_structp png_ptr, png_ptr->zstream.avail_out = (uInt)png_ptr->zbuf_size; png_ptr->zstream.next_out = png_ptr->zbuf; } - /* continue until we don't have any more to compress */ + /* Continue until we don't have any more to compress */ } while (png_ptr->zstream.avail_in); - /* finish the compression */ + /* Finish the compression */ do { - /* tell zlib we are finished */ + /* Tell zlib we are finished */ ret = deflate(&png_ptr->zstream, Z_FINISH); if (ret == Z_OK) { - /* check to see if we need more room */ + /* Check to see if we need more room */ if (!(png_ptr->zstream.avail_out)) { - /* check to make sure our output array has room */ + /* Check to make sure our output array has room */ if (comp->num_output_ptr >= comp->max_output_ptr) { int old_max; @@ -291,20 +306,21 @@ png_text_compress(png_structp png_ptr, /* This could be optimized to realloc() */ comp->output_ptr = (png_charpp)png_malloc(png_ptr, (png_uint_32)(comp->max_output_ptr * - png_sizeof (png_charpp))); + png_sizeof(png_charp))); png_memcpy(comp->output_ptr, old_ptr, - old_max * png_sizeof (png_charp)); + old_max * png_sizeof(png_charp)); png_free(png_ptr, old_ptr); } else comp->output_ptr = (png_charpp)png_malloc(png_ptr, (png_uint_32)(comp->max_output_ptr * - png_sizeof (png_charp))); + png_sizeof(png_charp))); } - /* save off the data */ + /* Save the data */ comp->output_ptr[comp->num_output_ptr] = - (png_charp)png_malloc(png_ptr, (png_uint_32)png_ptr->zbuf_size); + (png_charp)png_malloc(png_ptr, + (png_uint_32)png_ptr->zbuf_size); png_memcpy(comp->output_ptr[comp->num_output_ptr], png_ptr->zbuf, png_ptr->zbuf_size); comp->num_output_ptr++; @@ -316,7 +332,7 @@ png_text_compress(png_structp png_ptr, } else if (ret != Z_STREAM_END) { - /* we got an error */ + /* We got an error */ if (png_ptr->zstream.msg != NULL) png_error(png_ptr, png_ptr->zstream.msg); else @@ -324,7 +340,7 @@ png_text_compress(png_structp png_ptr, } } while (ret != Z_STREAM_END); - /* text length is number of buffers plus last buffer */ + /* Text length is number of buffers plus last buffer */ text_len = png_ptr->zbuf_size * comp->num_output_ptr; if (png_ptr->zstream.avail_out < png_ptr->zbuf_size) text_len += png_ptr->zbuf_size - (png_size_t)png_ptr->zstream.avail_out; @@ -332,37 +348,37 @@ png_text_compress(png_structp png_ptr, return((int)text_len); } -/* ship the compressed text out via chunk writes */ +/* Ship the compressed text out via chunk writes */ static void /* PRIVATE */ png_write_compressed_data_out(png_structp png_ptr, compression_state *comp) { int i; - /* handle the no-compression case */ + /* Handle the no-compression case */ if (comp->input) { - png_write_chunk_data(png_ptr, (png_bytep)comp->input, + png_write_chunk_data(png_ptr, (png_bytep)comp->input, (png_size_t)comp->input_len); - return; + return; } - /* write saved output buffers, if any */ + /* Write saved output buffers, if any */ for (i = 0; i < comp->num_output_ptr; i++) { - png_write_chunk_data(png_ptr,(png_bytep)comp->output_ptr[i], - png_ptr->zbuf_size); + png_write_chunk_data(png_ptr, (png_bytep)comp->output_ptr[i], + (png_size_t)png_ptr->zbuf_size); png_free(png_ptr, comp->output_ptr[i]); - comp->output_ptr[i]=NULL; + comp->output_ptr[i]=NULL; } if (comp->max_output_ptr != 0) png_free(png_ptr, comp->output_ptr); - comp->output_ptr=NULL; - /* write anything left in zbuf */ + comp->output_ptr=NULL; + /* Write anything left in zbuf */ if (png_ptr->zstream.avail_out < (png_uint_32)png_ptr->zbuf_size) png_write_chunk_data(png_ptr, png_ptr->zbuf, - png_ptr->zbuf_size - png_ptr->zstream.avail_out); + (png_size_t)(png_ptr->zbuf_size - png_ptr->zstream.avail_out)); - /* reset zlib for another zTXt/iTXt or image data */ + /* Reset zlib for another zTXt/iTXt or image data */ deflateReset(&png_ptr->zstream); png_ptr->zstream.data_type = Z_BINARY; } @@ -380,9 +396,12 @@ png_write_IHDR(png_structp png_ptr, png_uint_32 width, png_uint_32 height, #ifdef PNG_USE_LOCAL_ARRAYS PNG_IHDR; #endif - png_byte buf[13]; /* buffer to store the IHDR info */ + int ret; + + png_byte buf[13]; /* Buffer to store the IHDR info */ + + png_debug(1, "in png_write_IHDR"); - png_debug(1, "in png_write_IHDR\n"); /* Check that we have valid input data from the application info */ switch (color_type) { @@ -394,7 +413,8 @@ png_write_IHDR(png_structp png_ptr, png_uint_32 width, png_uint_32 height, case 4: case 8: case 16: png_ptr->channels = 1; break; - default: png_error(png_ptr,"Invalid bit depth for grayscale image"); + default: png_error(png_ptr, + "Invalid bit depth for grayscale image"); } break; case PNG_COLOR_TYPE_RGB: @@ -442,7 +462,7 @@ png_write_IHDR(png_structp png_ptr, png_uint_32 width, png_uint_32 height, * 5. The color_type is RGB or RGBA */ if ( -#if defined(PNG_MNG_FEATURES_SUPPORTED) +#ifdef PNG_MNG_FEATURES_SUPPORTED !((png_ptr->mng_features_permitted & PNG_FLAG_MNG_FILTER_64) && ((png_ptr->mode&PNG_HAVE_PNG_SIGNATURE) == 0) && (color_type == PNG_COLOR_TYPE_RGB || @@ -466,11 +486,11 @@ png_write_IHDR(png_structp png_ptr, png_uint_32 width, png_uint_32 height, interlace_type=PNG_INTERLACE_NONE; #endif - /* save off the relevent information */ + /* Save the relevent information */ png_ptr->bit_depth = (png_byte)bit_depth; png_ptr->color_type = (png_byte)color_type; png_ptr->interlaced = (png_byte)interlace_type; -#if defined(PNG_MNG_FEATURES_SUPPORTED) +#ifdef PNG_MNG_FEATURES_SUPPORTED png_ptr->filter_type = (png_byte)filter_type; #endif png_ptr->compression_type = (png_byte)compression_type; @@ -479,12 +499,12 @@ png_write_IHDR(png_structp png_ptr, png_uint_32 width, png_uint_32 height, png_ptr->pixel_depth = (png_byte)(bit_depth * png_ptr->channels); png_ptr->rowbytes = PNG_ROWBYTES(png_ptr->pixel_depth, width); - /* set the usr info, so any transformations can modify it */ + /* Set the usr info, so any transformations can modify it */ png_ptr->usr_width = png_ptr->width; png_ptr->usr_bit_depth = png_ptr->bit_depth; png_ptr->usr_channels = png_ptr->channels; - /* pack the header information into the buffer */ + /* Pack the header information into the buffer */ png_save_uint_32(buf, width); png_save_uint_32(buf + 4, height); buf[8] = (png_byte)bit_depth; @@ -493,10 +513,10 @@ png_write_IHDR(png_structp png_ptr, png_uint_32 width, png_uint_32 height, buf[11] = (png_byte)filter_type; buf[12] = (png_byte)interlace_type; - /* write the chunk */ - png_write_chunk(png_ptr, png_IHDR, buf, (png_size_t)13); + /* Write the chunk */ + png_write_chunk(png_ptr, (png_bytep)png_IHDR, buf, (png_size_t)13); - /* initialize zlib with PNG info */ + /* Initialize zlib with PNG info */ png_ptr->zstream.zalloc = png_zalloc; png_ptr->zstream.zfree = png_zfree; png_ptr->zstream.opaque = (voidpf)png_ptr; @@ -523,20 +543,29 @@ png_write_IHDR(png_structp png_ptr, png_uint_32 width, png_uint_32 height, png_ptr->zlib_window_bits = 15; if (!(png_ptr->flags & PNG_FLAG_ZLIB_CUSTOM_METHOD)) png_ptr->zlib_method = 8; - if (deflateInit2(&png_ptr->zstream, png_ptr->zlib_level, - png_ptr->zlib_method, png_ptr->zlib_window_bits, - png_ptr->zlib_mem_level, png_ptr->zlib_strategy) != Z_OK) - png_error(png_ptr, "zlib failed to initialize compressor"); + ret = deflateInit2(&png_ptr->zstream, png_ptr->zlib_level, + png_ptr->zlib_method, png_ptr->zlib_window_bits, + png_ptr->zlib_mem_level, png_ptr->zlib_strategy); + if (ret != Z_OK) + { + if (ret == Z_VERSION_ERROR) png_error(png_ptr, + "zlib failed to initialize compressor -- version error"); + if (ret == Z_STREAM_ERROR) png_error(png_ptr, + "zlib failed to initialize compressor -- stream error"); + if (ret == Z_MEM_ERROR) png_error(png_ptr, + "zlib failed to initialize compressor -- mem error"); + png_error(png_ptr, "zlib failed to initialize compressor"); + } png_ptr->zstream.next_out = png_ptr->zbuf; png_ptr->zstream.avail_out = (uInt)png_ptr->zbuf_size; /* libpng is not interested in zstream.data_type */ - /* set it to a predefined value, to avoid its evaluation inside zlib */ + /* Set it to a predefined value, to avoid its evaluation inside zlib */ png_ptr->zstream.data_type = Z_BINARY; png_ptr->mode = PNG_HAVE_IHDR; } -/* write the palette. We are careful not to trust png_color to be in the +/* Write the palette. We are careful not to trust png_color to be in the * correct order for PNG, so people can redefine it to any convenient * structure. */ @@ -550,9 +579,10 @@ png_write_PLTE(png_structp png_ptr, png_colorp palette, png_uint_32 num_pal) png_colorp pal_ptr; png_byte buf[3]; - png_debug(1, "in png_write_PLTE\n"); + png_debug(1, "in png_write_PLTE"); + if (( -#if defined(PNG_MNG_FEATURES_SUPPORTED) +#ifdef PNG_MNG_FEATURES_SUPPORTED !(png_ptr->mng_features_permitted & PNG_FLAG_MNG_EMPTY_PLTE) && #endif num_pal == 0) || num_pal > 256) @@ -576,10 +606,11 @@ png_write_PLTE(png_structp png_ptr, png_colorp palette, png_uint_32 num_pal) } png_ptr->num_palette = (png_uint_16)num_pal; - png_debug1(3, "num_palette = %d\n", png_ptr->num_palette); + png_debug1(3, "num_palette = %d", png_ptr->num_palette); - png_write_chunk_start(png_ptr, png_PLTE, num_pal * 3); -#ifndef PNG_NO_POINTER_INDEXING + png_write_chunk_start(png_ptr, (png_bytep)png_PLTE, + (png_uint_32)(num_pal * 3)); +#ifdef PNG_POINTER_INDEXING_SUPPORTED for (i = 0, pal_ptr = palette; i < num_pal; i++, pal_ptr++) { buf[0] = pal_ptr->red; @@ -588,7 +619,9 @@ png_write_PLTE(png_structp png_ptr, png_colorp palette, png_uint_32 num_pal) png_write_chunk_data(png_ptr, buf, (png_size_t)3); } #else - /* This is a little slower but some buggy compilers need to do this instead */ + /* This is a little slower but some buggy compilers need to do this + * instead + */ pal_ptr=palette; for (i = 0; i < num_pal; i++) { @@ -602,14 +635,15 @@ png_write_PLTE(png_structp png_ptr, png_colorp palette, png_uint_32 num_pal) png_ptr->mode |= PNG_HAVE_PLTE; } -/* write an IDAT chunk */ +/* Write an IDAT chunk */ void /* PRIVATE */ png_write_IDAT(png_structp png_ptr, png_bytep data, png_size_t length) { #ifdef PNG_USE_LOCAL_ARRAYS PNG_IDAT; #endif - png_debug(1, "in png_write_IDAT\n"); + + png_debug(1, "in png_write_IDAT"); /* Optimize the CMF field in the zlib stream. */ /* This hack of the zlib stream is compliant to the stream specification. */ @@ -619,9 +653,11 @@ png_write_IDAT(png_structp png_ptr, png_bytep data, png_size_t length) unsigned int z_cmf = data[0]; /* zlib compression method and flags */ if ((z_cmf & 0x0f) == 8 && (z_cmf & 0xf0) <= 0x70) { - /* Avoid memory underflows and multiplication overflows. */ - /* The conditions below are practically always satisfied; - however, they still must be checked. */ + /* Avoid memory underflows and multiplication overflows. + * + * The conditions below are practically always satisfied; + * however, they still must be checked. + */ if (length >= 2 && png_ptr->height < 16384 && png_ptr->width < 16384) { @@ -650,25 +686,27 @@ png_write_IDAT(png_structp png_ptr, png_bytep data, png_size_t length) "Invalid zlib compression method or flags in IDAT"); } - png_write_chunk(png_ptr, png_IDAT, data, length); + png_write_chunk(png_ptr, (png_bytep)png_IDAT, data, length); png_ptr->mode |= PNG_HAVE_IDAT; } -/* write an IEND chunk */ +/* Write an IEND chunk */ void /* PRIVATE */ png_write_IEND(png_structp png_ptr) { #ifdef PNG_USE_LOCAL_ARRAYS PNG_IEND; #endif - png_debug(1, "in png_write_IEND\n"); - png_write_chunk(png_ptr, png_IEND, png_bytep_NULL, + + png_debug(1, "in png_write_IEND"); + + png_write_chunk(png_ptr, (png_bytep)png_IEND, png_bytep_NULL, (png_size_t)0); png_ptr->mode |= PNG_HAVE_IEND; } -#if defined(PNG_WRITE_gAMA_SUPPORTED) -/* write a gAMA chunk */ +#ifdef PNG_WRITE_gAMA_SUPPORTED +/* Write a gAMA chunk */ #ifdef PNG_FLOATING_POINT_SUPPORTED void /* PRIVATE */ png_write_gAMA(png_structp png_ptr, double file_gamma) @@ -679,11 +717,12 @@ png_write_gAMA(png_structp png_ptr, double file_gamma) png_uint_32 igamma; png_byte buf[4]; - png_debug(1, "in png_write_gAMA\n"); + png_debug(1, "in png_write_gAMA"); + /* file_gamma is saved in 1/100,000ths */ igamma = (png_uint_32)(file_gamma * 100000.0 + 0.5); png_save_uint_32(buf, igamma); - png_write_chunk(png_ptr, png_gAMA, buf, (png_size_t)4); + png_write_chunk(png_ptr, (png_bytep)png_gAMA, buf, (png_size_t)4); } #endif #ifdef PNG_FIXED_POINT_SUPPORTED @@ -695,16 +734,17 @@ png_write_gAMA_fixed(png_structp png_ptr, png_fixed_point file_gamma) #endif png_byte buf[4]; - png_debug(1, "in png_write_gAMA\n"); + png_debug(1, "in png_write_gAMA"); + /* file_gamma is saved in 1/100,000ths */ png_save_uint_32(buf, (png_uint_32)file_gamma); - png_write_chunk(png_ptr, png_gAMA, buf, (png_size_t)4); + png_write_chunk(png_ptr, (png_bytep)png_gAMA, buf, (png_size_t)4); } #endif #endif -#if defined(PNG_WRITE_sRGB_SUPPORTED) -/* write a sRGB chunk */ +#ifdef PNG_WRITE_sRGB_SUPPORTED +/* Write a sRGB chunk */ void /* PRIVATE */ png_write_sRGB(png_structp png_ptr, int srgb_intent) { @@ -713,17 +753,18 @@ png_write_sRGB(png_structp png_ptr, int srgb_intent) #endif png_byte buf[1]; - png_debug(1, "in png_write_sRGB\n"); - if(srgb_intent >= PNG_sRGB_INTENT_LAST) + png_debug(1, "in png_write_sRGB"); + + if (srgb_intent >= PNG_sRGB_INTENT_LAST) png_warning(png_ptr, "Invalid sRGB rendering intent specified"); buf[0]=(png_byte)srgb_intent; - png_write_chunk(png_ptr, png_sRGB, buf, (png_size_t)1); + png_write_chunk(png_ptr, (png_bytep)png_sRGB, buf, (png_size_t)1); } #endif -#if defined(PNG_WRITE_iCCP_SUPPORTED) -/* write an iCCP chunk */ +#ifdef PNG_WRITE_iCCP_SUPPORTED +/* Write an iCCP chunk */ void /* PRIVATE */ png_write_iCCP(png_structp png_ptr, png_charp name, int compression_type, png_charp profile, int profile_len) @@ -736,7 +777,7 @@ png_write_iCCP(png_structp png_ptr, png_charp name, int compression_type, compression_state comp; int embedded_profile_len = 0; - png_debug(1, "in png_write_iCCP\n"); + png_debug(1, "in png_write_iCCP"); comp.num_output_ptr = 0; comp.max_output_ptr = 0; @@ -744,12 +785,9 @@ png_write_iCCP(png_structp png_ptr, png_charp name, int compression_type, comp.input = NULL; comp.input_len = 0; - if (name == NULL || (name_len = png_check_keyword(png_ptr, name, + if ((name_len = png_check_keyword(png_ptr, name, &new_name)) == 0) - { - png_warning(png_ptr, "Empty keyword in iCCP chunk"); return; - } if (compression_type != PNG_COMPRESSION_TYPE_BASE) png_warning(png_ptr, "Unknown compression type in iCCP chunk"); @@ -759,34 +797,44 @@ png_write_iCCP(png_structp png_ptr, png_charp name, int compression_type, if (profile_len > 3) embedded_profile_len = - ((*( (png_bytep)profile ))<<24) | - ((*( (png_bytep)profile+1))<<16) | - ((*( (png_bytep)profile+2))<< 8) | - ((*( (png_bytep)profile+3)) ); + ((*( (png_bytep)profile ))<<24) | + ((*( (png_bytep)profile + 1))<<16) | + ((*( (png_bytep)profile + 2))<< 8) | + ((*( (png_bytep)profile + 3)) ); + + if (embedded_profile_len < 0) + { + png_warning(png_ptr, + "Embedded profile length in iCCP chunk is negative"); + png_free(png_ptr, new_name); + return; + } if (profile_len < embedded_profile_len) - { - png_warning(png_ptr, - "Embedded profile length too large in iCCP chunk"); - return; - } + { + png_warning(png_ptr, + "Embedded profile length too large in iCCP chunk"); + png_free(png_ptr, new_name); + return; + } if (profile_len > embedded_profile_len) - { - png_warning(png_ptr, - "Truncating profile to actual length in iCCP chunk"); - profile_len = embedded_profile_len; - } + { + png_warning(png_ptr, + "Truncating profile to actual length in iCCP chunk"); + profile_len = embedded_profile_len; + } if (profile_len) - profile_len = png_text_compress(png_ptr, profile, (png_size_t)profile_len, - PNG_COMPRESSION_TYPE_BASE, &comp); + profile_len = png_text_compress(png_ptr, profile, + (png_size_t)profile_len, PNG_COMPRESSION_TYPE_BASE, &comp); - /* make sure we include the NULL after the name and the compression type */ - png_write_chunk_start(png_ptr, png_iCCP, - (png_uint_32)name_len+profile_len+2); - new_name[name_len+1]=0x00; - png_write_chunk_data(png_ptr, (png_bytep)new_name, name_len + 2); + /* Make sure we include the NULL after the name and the compression type */ + png_write_chunk_start(png_ptr, (png_bytep)png_iCCP, + (png_uint_32)(name_len + profile_len + 2)); + new_name[name_len + 1] = 0x00; + png_write_chunk_data(png_ptr, (png_bytep)new_name, + (png_size_t)(name_len + 2)); if (profile_len) png_write_compressed_data_out(png_ptr, &comp); @@ -796,8 +844,8 @@ png_write_iCCP(png_structp png_ptr, png_charp name, int compression_type, } #endif -#if defined(PNG_WRITE_sPLT_SUPPORTED) -/* write a sPLT chunk */ +#ifdef PNG_WRITE_sPLT_SUPPORTED +/* Write a sPLT chunk */ void /* PRIVATE */ png_write_sPLT(png_structp png_ptr, png_sPLT_tp spalette) { @@ -810,67 +858,65 @@ png_write_sPLT(png_structp png_ptr, png_sPLT_tp spalette) int entry_size = (spalette->depth == 8 ? 6 : 10); int palette_size = entry_size * spalette->nentries; png_sPLT_entryp ep; -#ifdef PNG_NO_POINTER_INDEXING +#ifndef PNG_POINTER_INDEXING_SUPPORTED int i; #endif - png_debug(1, "in png_write_sPLT\n"); - if (spalette->name == NULL || (name_len = png_check_keyword(png_ptr, - spalette->name, &new_name))==0) - { - png_warning(png_ptr, "Empty keyword in sPLT chunk"); + png_debug(1, "in png_write_sPLT"); + + if ((name_len = png_check_keyword(png_ptr,spalette->name, &new_name))==0) return; - } - /* make sure we include the NULL after the name */ - png_write_chunk_start(png_ptr, png_sPLT, - (png_uint_32)(name_len + 2 + palette_size)); - png_write_chunk_data(png_ptr, (png_bytep)new_name, name_len + 1); - png_write_chunk_data(png_ptr, (png_bytep)&spalette->depth, 1); - - /* loop through each palette entry, writing appropriately */ -#ifndef PNG_NO_POINTER_INDEXING - for (ep = spalette->entries; epentries+spalette->nentries; ep++) - { - if (spalette->depth == 8) - { - entrybuf[0] = (png_byte)ep->red; - entrybuf[1] = (png_byte)ep->green; - entrybuf[2] = (png_byte)ep->blue; - entrybuf[3] = (png_byte)ep->alpha; - png_save_uint_16(entrybuf + 4, ep->frequency); - } - else - { - png_save_uint_16(entrybuf + 0, ep->red); - png_save_uint_16(entrybuf + 2, ep->green); - png_save_uint_16(entrybuf + 4, ep->blue); - png_save_uint_16(entrybuf + 6, ep->alpha); - png_save_uint_16(entrybuf + 8, ep->frequency); - } - png_write_chunk_data(png_ptr, entrybuf, (png_size_t)entry_size); + /* Make sure we include the NULL after the name */ + png_write_chunk_start(png_ptr, (png_bytep)png_sPLT, + (png_uint_32)(name_len + 2 + palette_size)); + png_write_chunk_data(png_ptr, (png_bytep)new_name, + (png_size_t)(name_len + 1)); + png_write_chunk_data(png_ptr, (png_bytep)&spalette->depth, (png_size_t)1); + + /* Loop through each palette entry, writing appropriately */ +#ifdef PNG_POINTER_INDEXING_SUPPORTED + for (ep = spalette->entries; epentries + spalette->nentries; ep++) + { + if (spalette->depth == 8) + { + entrybuf[0] = (png_byte)ep->red; + entrybuf[1] = (png_byte)ep->green; + entrybuf[2] = (png_byte)ep->blue; + entrybuf[3] = (png_byte)ep->alpha; + png_save_uint_16(entrybuf + 4, ep->frequency); + } + else + { + png_save_uint_16(entrybuf + 0, ep->red); + png_save_uint_16(entrybuf + 2, ep->green); + png_save_uint_16(entrybuf + 4, ep->blue); + png_save_uint_16(entrybuf + 6, ep->alpha); + png_save_uint_16(entrybuf + 8, ep->frequency); + } + png_write_chunk_data(png_ptr, entrybuf, (png_size_t)entry_size); } #else ep=spalette->entries; for (i=0; i>spalette->nentries; i++) { - if (spalette->depth == 8) - { - entrybuf[0] = (png_byte)ep[i].red; - entrybuf[1] = (png_byte)ep[i].green; - entrybuf[2] = (png_byte)ep[i].blue; - entrybuf[3] = (png_byte)ep[i].alpha; - png_save_uint_16(entrybuf + 4, ep[i].frequency); - } - else - { - png_save_uint_16(entrybuf + 0, ep[i].red); - png_save_uint_16(entrybuf + 2, ep[i].green); - png_save_uint_16(entrybuf + 4, ep[i].blue); - png_save_uint_16(entrybuf + 6, ep[i].alpha); - png_save_uint_16(entrybuf + 8, ep[i].frequency); - } - png_write_chunk_data(png_ptr, entrybuf, entry_size); + if (spalette->depth == 8) + { + entrybuf[0] = (png_byte)ep[i].red; + entrybuf[1] = (png_byte)ep[i].green; + entrybuf[2] = (png_byte)ep[i].blue; + entrybuf[3] = (png_byte)ep[i].alpha; + png_save_uint_16(entrybuf + 4, ep[i].frequency); + } + else + { + png_save_uint_16(entrybuf + 0, ep[i].red); + png_save_uint_16(entrybuf + 2, ep[i].green); + png_save_uint_16(entrybuf + 4, ep[i].blue); + png_save_uint_16(entrybuf + 6, ep[i].alpha); + png_save_uint_16(entrybuf + 8, ep[i].frequency); + } + png_write_chunk_data(png_ptr, entrybuf, (png_size_t)entry_size); } #endif @@ -879,8 +925,8 @@ png_write_sPLT(png_structp png_ptr, png_sPLT_tp spalette) } #endif -#if defined(PNG_WRITE_sBIT_SUPPORTED) -/* write the sBIT chunk */ +#ifdef PNG_WRITE_sBIT_SUPPORTED +/* Write the sBIT chunk */ void /* PRIVATE */ png_write_sBIT(png_structp png_ptr, png_color_8p sbit, int color_type) { @@ -890,8 +936,9 @@ png_write_sBIT(png_structp png_ptr, png_color_8p sbit, int color_type) png_byte buf[4]; png_size_t size; - png_debug(1, "in png_write_sBIT\n"); - /* make sure we don't depend upon the order of PNG_COLOR_8 */ + png_debug(1, "in png_write_sBIT"); + + /* Make sure we don't depend upon the order of PNG_COLOR_8 */ if (color_type & PNG_COLOR_MASK_COLOR) { png_byte maxbits; @@ -931,12 +978,12 @@ png_write_sBIT(png_structp png_ptr, png_color_8p sbit, int color_type) buf[size++] = sbit->alpha; } - png_write_chunk(png_ptr, png_sBIT, buf, size); + png_write_chunk(png_ptr, (png_bytep)png_sBIT, buf, size); } #endif -#if defined(PNG_WRITE_cHRM_SUPPORTED) -/* write the cHRM chunk */ +#ifdef PNG_WRITE_cHRM_SUPPORTED +/* Write the cHRM chunk */ #ifdef PNG_FLOATING_POINT_SUPPORTED void /* PRIVATE */ png_write_cHRM(png_structp png_ptr, double white_x, double white_y, @@ -947,55 +994,42 @@ png_write_cHRM(png_structp png_ptr, double white_x, double white_y, PNG_cHRM; #endif png_byte buf[32]; - png_uint_32 itemp; - png_debug(1, "in png_write_cHRM\n"); - /* each value is saved in 1/100,000ths */ - if (white_x < 0 || white_x > 0.8 || white_y < 0 || white_y > 0.8 || - white_x + white_y > 1.0) - { - png_warning(png_ptr, "Invalid cHRM white point specified"); -#if !defined(PNG_NO_CONSOLE_IO) - fprintf(stderr,"white_x=%f, white_y=%f\n",white_x, white_y); -#endif - return; - } - itemp = (png_uint_32)(white_x * 100000.0 + 0.5); - png_save_uint_32(buf, itemp); - itemp = (png_uint_32)(white_y * 100000.0 + 0.5); - png_save_uint_32(buf + 4, itemp); + png_fixed_point int_white_x, int_white_y, int_red_x, int_red_y, + int_green_x, int_green_y, int_blue_x, int_blue_y; - if (red_x < 0 || red_y < 0 || red_x + red_y > 1.0) - { - png_warning(png_ptr, "Invalid cHRM red point specified"); - return; - } - itemp = (png_uint_32)(red_x * 100000.0 + 0.5); - png_save_uint_32(buf + 8, itemp); - itemp = (png_uint_32)(red_y * 100000.0 + 0.5); - png_save_uint_32(buf + 12, itemp); + png_debug(1, "in png_write_cHRM"); - if (green_x < 0 || green_y < 0 || green_x + green_y > 1.0) - { - png_warning(png_ptr, "Invalid cHRM green point specified"); - return; - } - itemp = (png_uint_32)(green_x * 100000.0 + 0.5); - png_save_uint_32(buf + 16, itemp); - itemp = (png_uint_32)(green_y * 100000.0 + 0.5); - png_save_uint_32(buf + 20, itemp); + int_white_x = (png_uint_32)(white_x * 100000.0 + 0.5); + int_white_y = (png_uint_32)(white_y * 100000.0 + 0.5); + int_red_x = (png_uint_32)(red_x * 100000.0 + 0.5); + int_red_y = (png_uint_32)(red_y * 100000.0 + 0.5); + int_green_x = (png_uint_32)(green_x * 100000.0 + 0.5); + int_green_y = (png_uint_32)(green_y * 100000.0 + 0.5); + int_blue_x = (png_uint_32)(blue_x * 100000.0 + 0.5); + int_blue_y = (png_uint_32)(blue_y * 100000.0 + 0.5); - if (blue_x < 0 || blue_y < 0 || blue_x + blue_y > 1.0) +#ifdef PNG_CHECK_cHRM_SUPPORTED + if (png_check_cHRM_fixed(png_ptr, int_white_x, int_white_y, + int_red_x, int_red_y, int_green_x, int_green_y, int_blue_x, int_blue_y)) +#endif { - png_warning(png_ptr, "Invalid cHRM blue point specified"); - return; - } - itemp = (png_uint_32)(blue_x * 100000.0 + 0.5); - png_save_uint_32(buf + 24, itemp); - itemp = (png_uint_32)(blue_y * 100000.0 + 0.5); - png_save_uint_32(buf + 28, itemp); + /* Each value is saved in 1/100,000ths */ + + png_save_uint_32(buf, int_white_x); + png_save_uint_32(buf + 4, int_white_y); + + png_save_uint_32(buf + 8, int_red_x); + png_save_uint_32(buf + 12, int_red_y); + + png_save_uint_32(buf + 16, int_green_x); + png_save_uint_32(buf + 20, int_green_y); - png_write_chunk(png_ptr, png_cHRM, buf, (png_size_t)32); + png_save_uint_32(buf + 24, int_blue_x); + png_save_uint_32(buf + 28, int_blue_y); + + png_write_chunk(png_ptr, (png_bytep)png_cHRM, buf, (png_size_t)32); + } } #endif #ifdef PNG_FIXED_POINT_SUPPORTED @@ -1010,50 +1044,34 @@ png_write_cHRM_fixed(png_structp png_ptr, png_fixed_point white_x, #endif png_byte buf[32]; - png_debug(1, "in png_write_cHRM\n"); - /* each value is saved in 1/100,000ths */ - if (white_x > 80000L || white_y > 80000L || white_x + white_y > 100000L) - { - png_warning(png_ptr, "Invalid fixed cHRM white point specified"); -#if !defined(PNG_NO_CONSOLE_IO) - fprintf(stderr,"white_x=%ld, white_y=%ld\n",white_x, white_y); -#endif - return; - } - png_save_uint_32(buf, (png_uint_32)white_x); - png_save_uint_32(buf + 4, (png_uint_32)white_y); + png_debug(1, "in png_write_cHRM"); - if (red_x + red_y > 100000L) + /* Each value is saved in 1/100,000ths */ +#ifdef PNG_CHECK_cHRM_SUPPORTED + if (png_check_cHRM_fixed(png_ptr, white_x, white_y, red_x, red_y, + green_x, green_y, blue_x, blue_y)) +#endif { - png_warning(png_ptr, "Invalid cHRM fixed red point specified"); - return; - } - png_save_uint_32(buf + 8, (png_uint_32)red_x); - png_save_uint_32(buf + 12, (png_uint_32)red_y); + png_save_uint_32(buf, (png_uint_32)white_x); + png_save_uint_32(buf + 4, (png_uint_32)white_y); - if (green_x + green_y > 100000L) - { - png_warning(png_ptr, "Invalid fixed cHRM green point specified"); - return; - } - png_save_uint_32(buf + 16, (png_uint_32)green_x); - png_save_uint_32(buf + 20, (png_uint_32)green_y); + png_save_uint_32(buf + 8, (png_uint_32)red_x); + png_save_uint_32(buf + 12, (png_uint_32)red_y); - if (blue_x + blue_y > 100000L) - { - png_warning(png_ptr, "Invalid fixed cHRM blue point specified"); - return; - } - png_save_uint_32(buf + 24, (png_uint_32)blue_x); - png_save_uint_32(buf + 28, (png_uint_32)blue_y); + png_save_uint_32(buf + 16, (png_uint_32)green_x); + png_save_uint_32(buf + 20, (png_uint_32)green_y); + + png_save_uint_32(buf + 24, (png_uint_32)blue_x); + png_save_uint_32(buf + 28, (png_uint_32)blue_y); - png_write_chunk(png_ptr, png_cHRM, buf, (png_size_t)32); + png_write_chunk(png_ptr, (png_bytep)png_cHRM, buf, (png_size_t)32); + } } #endif #endif -#if defined(PNG_WRITE_tRNS_SUPPORTED) -/* write the tRNS chunk */ +#ifdef PNG_WRITE_tRNS_SUPPORTED +/* Write the tRNS chunk */ void /* PRIVATE */ png_write_tRNS(png_structp png_ptr, png_bytep trans, png_color_16p tran, int num_trans, int color_type) @@ -1063,42 +1081,44 @@ png_write_tRNS(png_structp png_ptr, png_bytep trans, png_color_16p tran, #endif png_byte buf[6]; - png_debug(1, "in png_write_tRNS\n"); + png_debug(1, "in png_write_tRNS"); + if (color_type == PNG_COLOR_TYPE_PALETTE) { if (num_trans <= 0 || num_trans > (int)png_ptr->num_palette) { - png_warning(png_ptr,"Invalid number of transparent colors specified"); + png_warning(png_ptr, "Invalid number of transparent colors specified"); return; } - /* write the chunk out as it is */ - png_write_chunk(png_ptr, png_tRNS, trans, (png_size_t)num_trans); + /* Write the chunk out as it is */ + png_write_chunk(png_ptr, (png_bytep)png_tRNS, trans, + (png_size_t)num_trans); } else if (color_type == PNG_COLOR_TYPE_GRAY) { - /* one 16 bit value */ - if(tran->gray >= (1 << png_ptr->bit_depth)) + /* One 16 bit value */ + if (tran->gray >= (1 << png_ptr->bit_depth)) { png_warning(png_ptr, "Ignoring attempt to write tRNS chunk out-of-range for bit_depth"); return; } png_save_uint_16(buf, tran->gray); - png_write_chunk(png_ptr, png_tRNS, buf, (png_size_t)2); + png_write_chunk(png_ptr, (png_bytep)png_tRNS, buf, (png_size_t)2); } else if (color_type == PNG_COLOR_TYPE_RGB) { - /* three 16 bit values */ + /* Three 16 bit values */ png_save_uint_16(buf, tran->red); png_save_uint_16(buf + 2, tran->green); png_save_uint_16(buf + 4, tran->blue); - if(png_ptr->bit_depth == 8 && (buf[0] | buf[2] | buf[4])) - { - png_warning(png_ptr, - "Ignoring attempt to write 16-bit tRNS chunk when bit_depth is 8"); - return; - } - png_write_chunk(png_ptr, png_tRNS, buf, (png_size_t)6); + if (png_ptr->bit_depth == 8 && (buf[0] | buf[2] | buf[4])) + { + png_warning(png_ptr, + "Ignoring attempt to write 16-bit tRNS chunk when bit_depth is 8"); + return; + } + png_write_chunk(png_ptr, (png_bytep)png_tRNS, buf, (png_size_t)6); } else { @@ -1107,8 +1127,8 @@ png_write_tRNS(png_structp png_ptr, png_bytep trans, png_color_16p tran, } #endif -#if defined(PNG_WRITE_bKGD_SUPPORTED) -/* write the background chunk */ +#ifdef PNG_WRITE_bKGD_SUPPORTED +/* Write the background chunk */ void /* PRIVATE */ png_write_bKGD(png_structp png_ptr, png_color_16p back, int color_type) { @@ -1117,51 +1137,52 @@ png_write_bKGD(png_structp png_ptr, png_color_16p back, int color_type) #endif png_byte buf[6]; - png_debug(1, "in png_write_bKGD\n"); + png_debug(1, "in png_write_bKGD"); + if (color_type == PNG_COLOR_TYPE_PALETTE) { if ( -#if defined(PNG_MNG_FEATURES_SUPPORTED) +#ifdef PNG_MNG_FEATURES_SUPPORTED (png_ptr->num_palette || (!(png_ptr->mng_features_permitted & PNG_FLAG_MNG_EMPTY_PLTE))) && #endif - back->index > png_ptr->num_palette) + back->index >= png_ptr->num_palette) { png_warning(png_ptr, "Invalid background palette index"); return; } buf[0] = back->index; - png_write_chunk(png_ptr, png_bKGD, buf, (png_size_t)1); + png_write_chunk(png_ptr, (png_bytep)png_bKGD, buf, (png_size_t)1); } else if (color_type & PNG_COLOR_MASK_COLOR) { png_save_uint_16(buf, back->red); png_save_uint_16(buf + 2, back->green); png_save_uint_16(buf + 4, back->blue); - if(png_ptr->bit_depth == 8 && (buf[0] | buf[2] | buf[4])) - { - png_warning(png_ptr, - "Ignoring attempt to write 16-bit bKGD chunk when bit_depth is 8"); - return; - } - png_write_chunk(png_ptr, png_bKGD, buf, (png_size_t)6); + if (png_ptr->bit_depth == 8 && (buf[0] | buf[2] | buf[4])) + { + png_warning(png_ptr, + "Ignoring attempt to write 16-bit bKGD chunk when bit_depth is 8"); + return; + } + png_write_chunk(png_ptr, (png_bytep)png_bKGD, buf, (png_size_t)6); } else { - if(back->gray >= (1 << png_ptr->bit_depth)) + if (back->gray >= (1 << png_ptr->bit_depth)) { png_warning(png_ptr, "Ignoring attempt to write bKGD chunk out-of-range for bit_depth"); return; } png_save_uint_16(buf, back->gray); - png_write_chunk(png_ptr, png_bKGD, buf, (png_size_t)2); + png_write_chunk(png_ptr, (png_bytep)png_bKGD, buf, (png_size_t)2); } } #endif -#if defined(PNG_WRITE_hIST_SUPPORTED) -/* write the histogram */ +#ifdef PNG_WRITE_hIST_SUPPORTED +/* Write the histogram */ void /* PRIVATE */ png_write_hIST(png_structp png_ptr, png_uint_16p hist, int num_hist) { @@ -1171,16 +1192,18 @@ png_write_hIST(png_structp png_ptr, png_uint_16p hist, int num_hist) int i; png_byte buf[3]; - png_debug(1, "in png_write_hIST\n"); + png_debug(1, "in png_write_hIST"); + if (num_hist > (int)png_ptr->num_palette) { - png_debug2(3, "num_hist = %d, num_palette = %d\n", num_hist, + png_debug2(3, "num_hist = %d, num_palette = %d", num_hist, png_ptr->num_palette); png_warning(png_ptr, "Invalid number of histogram entries specified"); return; } - png_write_chunk_start(png_ptr, png_hIST, (png_uint_32)(num_hist * 2)); + png_write_chunk_start(png_ptr, (png_bytep)png_hIST, + (png_uint_32)(num_hist * 2)); for (i = 0; i < num_hist; i++) { png_save_uint_16(buf, hist[i]); @@ -1210,7 +1233,8 @@ png_check_keyword(png_structp png_ptr, png_charp key, png_charpp new_key) int kflag; int kwarn=0; - png_debug(1, "in png_check_keyword\n"); + png_debug(1, "in png_check_keyword"); + *new_key = NULL; if (key == NULL || (key_len = png_strlen(key)) == 0) @@ -1219,7 +1243,7 @@ png_check_keyword(png_structp png_ptr, png_charp key, png_charpp new_key) return ((png_size_t)0); } - png_debug1(2, "Keyword to be checked is '%s'\n", key); + png_debug1(2, "Keyword to be checked is '%s'", key); *new_key = (png_charp)png_malloc_warn(png_ptr, (png_uint_32)(key_len + 2)); if (*new_key == NULL) @@ -1234,7 +1258,7 @@ png_check_keyword(png_structp png_ptr, png_charp key, png_charpp new_key) if ((png_byte)*kp < 0x20 || ((png_byte)*kp > 0x7E && (png_byte)*kp < 0xA1)) { -#if !defined(PNG_NO_STDIO) && !defined(_WIN32_WCE) +#if defined(PNG_STDIO_SUPPORTED) && !defined(_WIN32_WCE) char msg[40]; png_snprintf(msg, 40, @@ -1260,8 +1284,8 @@ png_check_keyword(png_structp png_ptr, png_charp key, png_charpp new_key) while (*kp == ' ') { - *(kp--) = '\0'; - key_len--; + *(kp--) = '\0'; + key_len--; } } @@ -1273,12 +1297,12 @@ png_check_keyword(png_structp png_ptr, png_charp key, png_charpp new_key) while (*kp == ' ') { - kp++; - key_len--; + kp++; + key_len--; } } - png_debug1(2, "Checking for multiple internal spaces in '%s'\n", kp); + png_debug1(2, "Checking for multiple internal spaces in '%s'", kp); /* Remove multiple internal spaces. */ for (kflag = 0, dp = *new_key; *kp != '\0'; kp++) @@ -1300,20 +1324,20 @@ png_check_keyword(png_structp png_ptr, png_charp key, png_charpp new_key) } } *dp = '\0'; - if(kwarn) + if (kwarn) png_warning(png_ptr, "extra interior spaces removed from keyword"); if (key_len == 0) { png_free(png_ptr, *new_key); - *new_key=NULL; + *new_key=NULL; png_warning(png_ptr, "Zero length keyword"); } if (key_len > 79) { png_warning(png_ptr, "keyword length must be 1 - 79 characters"); - new_key[79] = '\0'; + (*new_key)[79] = '\0'; key_len = 79; } @@ -1321,8 +1345,8 @@ png_check_keyword(png_structp png_ptr, png_charp key, png_charpp new_key) } #endif -#if defined(PNG_WRITE_tEXt_SUPPORTED) -/* write a tEXt chunk */ +#ifdef PNG_WRITE_tEXt_SUPPORTED +/* Write a tEXt chunk */ void /* PRIVATE */ png_write_tEXt(png_structp png_ptr, png_charp key, png_charp text, png_size_t text_len) @@ -1333,37 +1357,37 @@ png_write_tEXt(png_structp png_ptr, png_charp key, png_charp text, png_size_t key_len; png_charp new_key; - png_debug(1, "in png_write_tEXt\n"); - if (key == NULL || (key_len = png_check_keyword(png_ptr, key, &new_key))==0) - { - png_warning(png_ptr, "Empty keyword in tEXt chunk"); + png_debug(1, "in png_write_tEXt"); + + if ((key_len = png_check_keyword(png_ptr, key, &new_key))==0) return; - } if (text == NULL || *text == '\0') text_len = 0; else text_len = png_strlen(text); - /* make sure we include the 0 after the key */ - png_write_chunk_start(png_ptr, png_tEXt, (png_uint_32)key_len+text_len+1); + /* Make sure we include the 0 after the key */ + png_write_chunk_start(png_ptr, (png_bytep)png_tEXt, + (png_uint_32)(key_len + text_len + 1)); /* * We leave it to the application to meet PNG-1.0 requirements on the * contents of the text. PNG-1.0 through PNG-1.2 discourage the use of * any non-Latin-1 characters except for NEWLINE. ISO PNG will forbid them. * The NUL character is forbidden by PNG-1.0 through PNG-1.2 and ISO PNG. */ - png_write_chunk_data(png_ptr, (png_bytep)new_key, key_len + 1); + png_write_chunk_data(png_ptr, (png_bytep)new_key, + (png_size_t)(key_len + 1)); if (text_len) - png_write_chunk_data(png_ptr, (png_bytep)text, text_len); + png_write_chunk_data(png_ptr, (png_bytep)text, (png_size_t)text_len); png_write_chunk_end(png_ptr); png_free(png_ptr, new_key); } #endif -#if defined(PNG_WRITE_zTXt_SUPPORTED) -/* write a compressed text chunk */ +#ifdef PNG_WRITE_zTXt_SUPPORTED +/* Write a compressed text chunk */ void /* PRIVATE */ png_write_zTXt(png_structp png_ptr, png_charp key, png_charp text, png_size_t text_len, int compression) @@ -1376,7 +1400,7 @@ png_write_zTXt(png_structp png_ptr, png_charp key, png_charp text, png_charp new_key; compression_state comp; - png_debug(1, "in png_write_zTXt\n"); + png_debug(1, "in png_write_zTXt"); comp.num_output_ptr = 0; comp.max_output_ptr = 0; @@ -1384,9 +1408,9 @@ png_write_zTXt(png_structp png_ptr, png_charp key, png_charp text, comp.input = NULL; comp.input_len = 0; - if (key == NULL || (key_len = png_check_keyword(png_ptr, key, &new_key))==0) + if ((key_len = png_check_keyword(png_ptr, key, &new_key))==0) { - png_warning(png_ptr, "Empty keyword in zTXt chunk"); + png_free(png_ptr, new_key); return; } @@ -1399,30 +1423,31 @@ png_write_zTXt(png_structp png_ptr, png_charp key, png_charp text, text_len = png_strlen(text); - /* compute the compressed data; do it now for the length */ + /* Compute the compressed data; do it now for the length */ text_len = png_text_compress(png_ptr, text, text_len, compression, &comp); - /* write start of chunk */ - png_write_chunk_start(png_ptr, png_zTXt, (png_uint_32) - (key_len+text_len+2)); - /* write key */ - png_write_chunk_data(png_ptr, (png_bytep)new_key, key_len + 1); + /* Write start of chunk */ + png_write_chunk_start(png_ptr, (png_bytep)png_zTXt, + (png_uint_32)(key_len+text_len + 2)); + /* Write key */ + png_write_chunk_data(png_ptr, (png_bytep)new_key, + (png_size_t)(key_len + 1)); png_free(png_ptr, new_key); buf[0] = (png_byte)compression; - /* write compression */ + /* Write compression */ png_write_chunk_data(png_ptr, (png_bytep)buf, (png_size_t)1); - /* write the compressed data */ + /* Write the compressed data */ png_write_compressed_data_out(png_ptr, &comp); - /* close the chunk */ + /* Close the chunk */ png_write_chunk_end(png_ptr); } #endif -#if defined(PNG_WRITE_iTXt_SUPPORTED) -/* write an iTXt chunk */ +#ifdef PNG_WRITE_iTXt_SUPPORTED +/* Write an iTXt chunk */ void /* PRIVATE */ png_write_iTXt(png_structp png_ptr, int compression, png_charp key, png_charp lang, png_charp lang_key, png_charp text) @@ -1431,23 +1456,22 @@ png_write_iTXt(png_structp png_ptr, int compression, png_charp key, PNG_iTXt; #endif png_size_t lang_len, key_len, lang_key_len, text_len; - png_charp new_lang, new_key; + png_charp new_lang; + png_charp new_key = NULL; png_byte cbuf[2]; compression_state comp; - png_debug(1, "in png_write_iTXt\n"); + png_debug(1, "in png_write_iTXt"); comp.num_output_ptr = 0; comp.max_output_ptr = 0; comp.output_ptr = NULL; comp.input = NULL; - if (key == NULL || (key_len = png_check_keyword(png_ptr, key, &new_key))==0) - { - png_warning(png_ptr, "Empty keyword in iTXt chunk"); + if ((key_len = png_check_keyword(png_ptr, key, &new_key))==0) return; - } - if (lang == NULL || (lang_len = png_check_keyword(png_ptr, lang, &new_lang))==0) + + if ((lang_len = png_check_keyword(png_ptr, lang, &new_lang))==0) { png_warning(png_ptr, "Empty language field in iTXt chunk"); new_lang = NULL; @@ -1455,24 +1479,24 @@ png_write_iTXt(png_structp png_ptr, int compression, png_charp key, } if (lang_key == NULL) - lang_key_len = 0; + lang_key_len = 0; else - lang_key_len = png_strlen(lang_key); + lang_key_len = png_strlen(lang_key); if (text == NULL) text_len = 0; else - text_len = png_strlen(text); + text_len = png_strlen(text); - /* compute the compressed data; do it now for the length */ + /* Compute the compressed data; do it now for the length */ text_len = png_text_compress(png_ptr, text, text_len, compression-2, &comp); - /* make sure we include the compression flag, the compression byte, + /* Make sure we include the compression flag, the compression byte, * and the NULs after the key, lang, and lang_key parts */ - png_write_chunk_start(png_ptr, png_iTXt, + png_write_chunk_start(png_ptr, (png_bytep)png_iTXt, (png_uint_32)( 5 /* comp byte, comp flag, terminators for key, lang and lang_key */ + key_len @@ -1480,38 +1504,39 @@ png_write_iTXt(png_structp png_ptr, int compression, png_charp key, + lang_key_len + text_len)); - /* - * We leave it to the application to meet PNG-1.0 requirements on the + /* We leave it to the application to meet PNG-1.0 requirements on the * contents of the text. PNG-1.0 through PNG-1.2 discourage the use of * any non-Latin-1 characters except for NEWLINE. ISO PNG will forbid them. * The NUL character is forbidden by PNG-1.0 through PNG-1.2 and ISO PNG. */ - png_write_chunk_data(png_ptr, (png_bytep)new_key, key_len + 1); + png_write_chunk_data(png_ptr, (png_bytep)new_key, + (png_size_t)(key_len + 1)); - /* set the compression flag */ + /* Set the compression flag */ if (compression == PNG_ITXT_COMPRESSION_NONE || \ compression == PNG_TEXT_COMPRESSION_NONE) cbuf[0] = 0; else /* compression == PNG_ITXT_COMPRESSION_zTXt */ cbuf[0] = 1; - /* set the compression method */ + /* Set the compression method */ cbuf[1] = 0; - png_write_chunk_data(png_ptr, cbuf, 2); + png_write_chunk_data(png_ptr, cbuf, (png_size_t)2); cbuf[0] = 0; - png_write_chunk_data(png_ptr, (new_lang ? (png_bytep)new_lang : cbuf), lang_len + 1); - png_write_chunk_data(png_ptr, (lang_key ? (png_bytep)lang_key : cbuf), lang_key_len + 1); + png_write_chunk_data(png_ptr, (new_lang ? (png_bytep)new_lang : cbuf), + (png_size_t)(lang_len + 1)); + png_write_chunk_data(png_ptr, (lang_key ? (png_bytep)lang_key : cbuf), + (png_size_t)(lang_key_len + 1)); png_write_compressed_data_out(png_ptr, &comp); png_write_chunk_end(png_ptr); png_free(png_ptr, new_key); - if (new_lang) - png_free(png_ptr, new_lang); + png_free(png_ptr, new_lang); } #endif -#if defined(PNG_WRITE_oFFs_SUPPORTED) -/* write the oFFs chunk */ +#ifdef PNG_WRITE_oFFs_SUPPORTED +/* Write the oFFs chunk */ void /* PRIVATE */ png_write_oFFs(png_structp png_ptr, png_int_32 x_offset, png_int_32 y_offset, int unit_type) @@ -1521,7 +1546,8 @@ png_write_oFFs(png_structp png_ptr, png_int_32 x_offset, png_int_32 y_offset, #endif png_byte buf[9]; - png_debug(1, "in png_write_oFFs\n"); + png_debug(1, "in png_write_oFFs"); + if (unit_type >= PNG_OFFSET_LAST) png_warning(png_ptr, "Unrecognized unit type for oFFs chunk"); @@ -1529,11 +1555,11 @@ png_write_oFFs(png_structp png_ptr, png_int_32 x_offset, png_int_32 y_offset, png_save_int_32(buf + 4, y_offset); buf[8] = (png_byte)unit_type; - png_write_chunk(png_ptr, png_oFFs, buf, (png_size_t)9); + png_write_chunk(png_ptr, (png_bytep)png_oFFs, buf, (png_size_t)9); } #endif -#if defined(PNG_WRITE_pCAL_SUPPORTED) -/* write the pCAL chunk (described in the PNG extensions document) */ +#ifdef PNG_WRITE_pCAL_SUPPORTED +/* Write the pCAL chunk (described in the PNG extensions document) */ void /* PRIVATE */ png_write_pCAL(png_structp png_ptr, png_charp purpose, png_int_32 X0, png_int_32 X1, int type, int nparams, png_charp units, png_charpp params) @@ -1547,31 +1573,34 @@ png_write_pCAL(png_structp png_ptr, png_charp purpose, png_int_32 X0, png_charp new_purpose; int i; - png_debug1(1, "in png_write_pCAL (%d parameters)\n", nparams); + png_debug1(1, "in png_write_pCAL (%d parameters)", nparams); + if (type >= PNG_EQUATION_LAST) png_warning(png_ptr, "Unrecognized equation type for pCAL chunk"); purpose_len = png_check_keyword(png_ptr, purpose, &new_purpose) + 1; - png_debug1(3, "pCAL purpose length = %d\n", (int)purpose_len); + png_debug1(3, "pCAL purpose length = %d", (int)purpose_len); units_len = png_strlen(units) + (nparams == 0 ? 0 : 1); - png_debug1(3, "pCAL units length = %d\n", (int)units_len); + png_debug1(3, "pCAL units length = %d", (int)units_len); total_len = purpose_len + units_len + 10; - params_len = (png_uint_32p)png_malloc(png_ptr, (png_uint_32)(nparams - *png_sizeof(png_uint_32))); + params_len = (png_uint_32p)png_malloc(png_ptr, + (png_uint_32)(nparams * png_sizeof(png_uint_32))); /* Find the length of each parameter, making sure we don't count the null terminator for the last parameter. */ for (i = 0; i < nparams; i++) { params_len[i] = png_strlen(params[i]) + (i == nparams - 1 ? 0 : 1); - png_debug2(3, "pCAL parameter %d length = %lu\n", i, params_len[i]); + png_debug2(3, "pCAL parameter %d length = %lu", i, + (unsigned long) params_len[i]); total_len += (png_size_t)params_len[i]; } - png_debug1(3, "pCAL total length = %d\n", (int)total_len); - png_write_chunk_start(png_ptr, png_pCAL, (png_uint_32)total_len); - png_write_chunk_data(png_ptr, (png_bytep)new_purpose, purpose_len); + png_debug1(3, "pCAL total length = %d", (int)total_len); + png_write_chunk_start(png_ptr, (png_bytep)png_pCAL, (png_uint_32)total_len); + png_write_chunk_data(png_ptr, (png_bytep)new_purpose, + (png_size_t)purpose_len); png_save_int_32(buf, X0); png_save_int_32(buf + 4, X1); buf[8] = (png_byte)type; @@ -1592,9 +1621,9 @@ png_write_pCAL(png_structp png_ptr, png_charp purpose, png_int_32 X0, } #endif -#if defined(PNG_WRITE_sCAL_SUPPORTED) -/* write the sCAL chunk */ -#if defined(PNG_FLOATING_POINT_SUPPORTED) && !defined(PNG_NO_STDIO) +#ifdef PNG_WRITE_sCAL_SUPPORTED +/* Write the sCAL chunk */ +#if defined(PNG_FLOATING_POINT_SUPPORTED) && defined(PNG_STDIO_SUPPORTED) void /* PRIVATE */ png_write_sCAL(png_structp png_ptr, int unit, double width, double height) { @@ -1604,17 +1633,18 @@ png_write_sCAL(png_structp png_ptr, int unit, double width, double height) char buf[64]; png_size_t total_len; - png_debug(1, "in png_write_sCAL\n"); + png_debug(1, "in png_write_sCAL"); buf[0] = (char)unit; -#if defined(_WIN32_WCE) +#ifdef _WIN32_WCE /* sprintf() function is not supported on WindowsCE */ { wchar_t wc_buf[32]; size_t wc_len; swprintf(wc_buf, TEXT("%12.12e"), width); wc_len = wcslen(wc_buf); - WideCharToMultiByte(CP_ACP, 0, wc_buf, -1, buf + 1, wc_len, NULL, NULL); + WideCharToMultiByte(CP_ACP, 0, wc_buf, -1, buf + 1, wc_len, NULL, + NULL); total_len = wc_len + 2; swprintf(wc_buf, TEXT("%12.12e"), height); wc_len = wcslen(wc_buf); @@ -1629,8 +1659,8 @@ png_write_sCAL(png_structp png_ptr, int unit, double width, double height) total_len += png_strlen(buf + total_len); #endif - png_debug1(3, "sCAL total length = %u\n", (unsigned int)total_len); - png_write_chunk(png_ptr, png_sCAL, (png_bytep)buf, total_len); + png_debug1(3, "sCAL total length = %u", (unsigned int)total_len); + png_write_chunk(png_ptr, (png_bytep)png_sCAL, (png_bytep)buf, total_len); } #else #ifdef PNG_FIXED_POINT_SUPPORTED @@ -1644,7 +1674,7 @@ png_write_sCAL_s(png_structp png_ptr, int unit, png_charp width, png_byte buf[64]; png_size_t wlen, hlen, total_len; - png_debug(1, "in png_write_sCAL_s\n"); + png_debug(1, "in png_write_sCAL_s"); wlen = png_strlen(width); hlen = png_strlen(height); @@ -1656,18 +1686,18 @@ png_write_sCAL_s(png_structp png_ptr, int unit, png_charp width, } buf[0] = (png_byte)unit; - png_memcpy(buf + 1, width, wlen + 1); /* append the '\0' here */ - png_memcpy(buf + wlen + 2, height, hlen); /* do NOT append the '\0' here */ + png_memcpy(buf + 1, width, wlen + 1); /* Append the '\0' here */ + png_memcpy(buf + wlen + 2, height, hlen); /* Do NOT append the '\0' here */ - png_debug1(3, "sCAL total length = %u\n", (unsigned int)total_len); - png_write_chunk(png_ptr, png_sCAL, buf, total_len); + png_debug1(3, "sCAL total length = %u", (unsigned int)total_len); + png_write_chunk(png_ptr, (png_bytep)png_sCAL, buf, total_len); } #endif #endif #endif -#if defined(PNG_WRITE_pHYs_SUPPORTED) -/* write the pHYs chunk */ +#ifdef PNG_WRITE_pHYs_SUPPORTED +/* Write the pHYs chunk */ void /* PRIVATE */ png_write_pHYs(png_structp png_ptr, png_uint_32 x_pixels_per_unit, png_uint_32 y_pixels_per_unit, @@ -1678,7 +1708,8 @@ png_write_pHYs(png_structp png_ptr, png_uint_32 x_pixels_per_unit, #endif png_byte buf[9]; - png_debug(1, "in png_write_pHYs\n"); + png_debug(1, "in png_write_pHYs"); + if (unit_type >= PNG_RESOLUTION_LAST) png_warning(png_ptr, "Unrecognized unit type for pHYs chunk"); @@ -1686,11 +1717,11 @@ png_write_pHYs(png_structp png_ptr, png_uint_32 x_pixels_per_unit, png_save_uint_32(buf + 4, y_pixels_per_unit); buf[8] = (png_byte)unit_type; - png_write_chunk(png_ptr, png_pHYs, buf, (png_size_t)9); + png_write_chunk(png_ptr, (png_bytep)png_pHYs, buf, (png_size_t)9); } #endif -#if defined(PNG_WRITE_tIME_SUPPORTED) +#ifdef PNG_WRITE_tIME_SUPPORTED /* Write the tIME chunk. Use either png_convert_from_struct_tm() * or png_convert_from_time_t(), or fill in the structure yourself. */ @@ -1702,7 +1733,8 @@ png_write_tIME(png_structp png_ptr, png_timep mod_time) #endif png_byte buf[7]; - png_debug(1, "in png_write_tIME\n"); + png_debug(1, "in png_write_tIME"); + if (mod_time->month > 12 || mod_time->month < 1 || mod_time->day > 31 || mod_time->day < 1 || mod_time->hour > 23 || mod_time->second > 60) @@ -1718,83 +1750,83 @@ png_write_tIME(png_structp png_ptr, png_timep mod_time) buf[5] = mod_time->minute; buf[6] = mod_time->second; - png_write_chunk(png_ptr, png_tIME, buf, (png_size_t)7); + png_write_chunk(png_ptr, (png_bytep)png_tIME, buf, (png_size_t)7); } #endif -/* initializes the row writing capability of libpng */ +/* Initializes the row writing capability of libpng */ void /* PRIVATE */ png_write_start_row(png_structp png_ptr) { #ifdef PNG_WRITE_INTERLACING_SUPPORTED -#ifdef PNG_USE_LOCAL_ARRAYS - /* arrays to facilitate easy interlacing - use pass (0 - 6) as index */ + /* Arrays to facilitate easy interlacing - use pass (0 - 6) as index */ - /* start of interlace block */ + /* Start of interlace block */ int png_pass_start[7] = {0, 4, 0, 2, 0, 1, 0}; - /* offset to next interlace block */ + /* Offset to next interlace block */ int png_pass_inc[7] = {8, 8, 4, 4, 2, 2, 1}; - /* start of interlace block in the y direction */ + /* Start of interlace block in the y direction */ int png_pass_ystart[7] = {0, 0, 4, 0, 2, 0, 1}; - /* offset to next interlace block in the y direction */ + /* Offset to next interlace block in the y direction */ int png_pass_yinc[7] = {8, 8, 8, 4, 4, 2, 2}; -#endif #endif png_size_t buf_size; - png_debug(1, "in png_write_start_row\n"); + png_debug(1, "in png_write_start_row"); + buf_size = (png_size_t)(PNG_ROWBYTES( - png_ptr->usr_channels*png_ptr->usr_bit_depth,png_ptr->width)+1); + png_ptr->usr_channels*png_ptr->usr_bit_depth, png_ptr->width) + 1); - /* set up row buffer */ - png_ptr->row_buf = (png_bytep)png_malloc(png_ptr, (png_uint_32)buf_size); + /* Set up row buffer */ + png_ptr->row_buf = (png_bytep)png_malloc(png_ptr, + (png_uint_32)buf_size); png_ptr->row_buf[0] = PNG_FILTER_VALUE_NONE; -#ifndef PNG_NO_WRITE_FILTERING - /* set up filtering buffer, if using this filter */ +#ifdef PNG_WRITE_FILTER_SUPPORTED + /* Set up filtering buffer, if using this filter */ if (png_ptr->do_filter & PNG_FILTER_SUB) { png_ptr->sub_row = (png_bytep)png_malloc(png_ptr, - (png_ptr->rowbytes + 1)); + (png_uint_32)(png_ptr->rowbytes + 1)); png_ptr->sub_row[0] = PNG_FILTER_VALUE_SUB; } /* We only need to keep the previous row if we are using one of these. */ if (png_ptr->do_filter & (PNG_FILTER_AVG | PNG_FILTER_UP | PNG_FILTER_PAETH)) { - /* set up previous row buffer */ - png_ptr->prev_row = (png_bytep)png_malloc(png_ptr, (png_uint_32)buf_size); - png_memset(png_ptr->prev_row, 0, buf_size); + /* Set up previous row buffer */ + png_ptr->prev_row = (png_bytep)png_calloc(png_ptr, + (png_uint_32)buf_size); if (png_ptr->do_filter & PNG_FILTER_UP) { png_ptr->up_row = (png_bytep)png_malloc(png_ptr, - (png_ptr->rowbytes + 1)); + (png_uint_32)(png_ptr->rowbytes + 1)); png_ptr->up_row[0] = PNG_FILTER_VALUE_UP; } if (png_ptr->do_filter & PNG_FILTER_AVG) { png_ptr->avg_row = (png_bytep)png_malloc(png_ptr, - (png_ptr->rowbytes + 1)); + (png_uint_32)(png_ptr->rowbytes + 1)); png_ptr->avg_row[0] = PNG_FILTER_VALUE_AVG; } if (png_ptr->do_filter & PNG_FILTER_PAETH) { png_ptr->paeth_row = (png_bytep)png_malloc(png_ptr, - (png_ptr->rowbytes + 1)); + (png_uint_32)(png_ptr->rowbytes + 1)); png_ptr->paeth_row[0] = PNG_FILTER_VALUE_PAETH; } -#endif /* PNG_NO_WRITE_FILTERING */ } +#endif /* PNG_WRITE_FILTER_SUPPORTED */ #ifdef PNG_WRITE_INTERLACING_SUPPORTED - /* if interlaced, we need to set up width and height of pass */ + /* If interlaced, we need to set up width and height of pass */ if (png_ptr->interlaced) { if (!(png_ptr->transformations & PNG_INTERLACE)) @@ -1825,35 +1857,34 @@ void /* PRIVATE */ png_write_finish_row(png_structp png_ptr) { #ifdef PNG_WRITE_INTERLACING_SUPPORTED -#ifdef PNG_USE_LOCAL_ARRAYS - /* arrays to facilitate easy interlacing - use pass (0 - 6) as index */ + /* Arrays to facilitate easy interlacing - use pass (0 - 6) as index */ - /* start of interlace block */ + /* Start of interlace block */ int png_pass_start[7] = {0, 4, 0, 2, 0, 1, 0}; - /* offset to next interlace block */ + /* Offset to next interlace block */ int png_pass_inc[7] = {8, 8, 4, 4, 2, 2, 1}; - /* start of interlace block in the y direction */ + /* Start of interlace block in the y direction */ int png_pass_ystart[7] = {0, 0, 4, 0, 2, 0, 1}; - /* offset to next interlace block in the y direction */ + /* Offset to next interlace block in the y direction */ int png_pass_yinc[7] = {8, 8, 8, 4, 4, 2, 2}; -#endif #endif int ret; - png_debug(1, "in png_write_finish_row\n"); - /* next row */ + png_debug(1, "in png_write_finish_row"); + + /* Next row */ png_ptr->row_number++; - /* see if we are done */ + /* See if we are done */ if (png_ptr->row_number < png_ptr->num_rows) return; #ifdef PNG_WRITE_INTERLACING_SUPPORTED - /* if interlaced, go to next pass */ + /* If interlaced, go to next pass */ if (png_ptr->interlaced) { png_ptr->row_number = 0; @@ -1863,7 +1894,7 @@ png_write_finish_row(png_structp png_ptr) } else { - /* loop until we find a non-zero width or height pass */ + /* Loop until we find a non-zero width or height pass */ do { png_ptr->pass++; @@ -1883,28 +1914,28 @@ png_write_finish_row(png_structp png_ptr) } - /* reset the row above the image for the next pass */ + /* Reset the row above the image for the next pass */ if (png_ptr->pass < 7) { if (png_ptr->prev_row != NULL) png_memset(png_ptr->prev_row, 0, (png_size_t)(PNG_ROWBYTES(png_ptr->usr_channels* - png_ptr->usr_bit_depth,png_ptr->width))+1); + png_ptr->usr_bit_depth, png_ptr->width)) + 1); return; } } #endif - /* if we get here, we've just written the last row, so we need + /* If we get here, we've just written the last row, so we need to flush the compressor */ do { - /* tell the compressor we are done */ + /* Tell the compressor we are done */ ret = deflate(&png_ptr->zstream, Z_FINISH); - /* check for an error */ + /* Check for an error */ if (ret == Z_OK) { - /* check to see if we need more room */ + /* Check to see if we need more room */ if (!(png_ptr->zstream.avail_out)) { png_write_IDAT(png_ptr, png_ptr->zbuf, png_ptr->zbuf_size); @@ -1921,7 +1952,7 @@ png_write_finish_row(png_structp png_ptr) } } while (ret != Z_STREAM_END); - /* write any extra space */ + /* Write any extra space */ if (png_ptr->zstream.avail_out < png_ptr->zbuf_size) { png_write_IDAT(png_ptr, png_ptr->zbuf, png_ptr->zbuf_size - @@ -1932,7 +1963,7 @@ png_write_finish_row(png_structp png_ptr) png_ptr->zstream.data_type = Z_BINARY; } -#if defined(PNG_WRITE_INTERLACING_SUPPORTED) +#ifdef PNG_WRITE_INTERLACING_SUPPORTED /* Pick out the correct pixels for the interlace pass. * The basic idea here is to go through the row with a source * pointer and a destination pointer (sp and dp), and copy the @@ -1943,25 +1974,24 @@ png_write_finish_row(png_structp png_ptr) void /* PRIVATE */ png_do_write_interlace(png_row_infop row_info, png_bytep row, int pass) { -#ifdef PNG_USE_LOCAL_ARRAYS - /* arrays to facilitate easy interlacing - use pass (0 - 6) as index */ + /* Arrays to facilitate easy interlacing - use pass (0 - 6) as index */ - /* start of interlace block */ + /* Start of interlace block */ int png_pass_start[7] = {0, 4, 0, 2, 0, 1, 0}; - /* offset to next interlace block */ + /* Offset to next interlace block */ int png_pass_inc[7] = {8, 8, 4, 4, 2, 2, 1}; -#endif - png_debug(1, "in png_do_write_interlace\n"); - /* we don't have to do anything on the last pass (6) */ -#if defined(PNG_USELESS_TESTS_SUPPORTED) + png_debug(1, "in png_do_write_interlace"); + + /* We don't have to do anything on the last pass (6) */ +#ifdef PNG_USELESS_TESTS_SUPPORTED if (row != NULL && row_info != NULL && pass < 6) #else if (pass < 6) #endif { - /* each pixel depth is handled separately */ + /* Each pixel depth is handled separately */ switch (row_info->pixel_depth) { case 1: @@ -2072,27 +2102,27 @@ png_do_write_interlace(png_row_infop row_info, png_bytep row, int pass) png_uint_32 row_width = row_info->width; png_size_t pixel_bytes; - /* start at the beginning */ + /* Start at the beginning */ dp = row; - /* find out how many bytes each pixel takes up */ + /* Find out how many bytes each pixel takes up */ pixel_bytes = (row_info->pixel_depth >> 3); - /* loop through the row, only looking at the pixels that + /* Loop through the row, only looking at the pixels that matter */ for (i = png_pass_start[pass]; i < row_width; i += png_pass_inc[pass]) { - /* find out where the original pixel is */ + /* Find out where the original pixel is */ sp = row + (png_size_t)i * pixel_bytes; - /* move the pixel */ + /* Move the pixel */ if (dp != sp) png_memcpy(dp, sp, pixel_bytes); - /* next pixel */ + /* Next pixel */ dp += pixel_bytes; } break; } } - /* set new row width */ + /* Set new row width */ row_info->width = (row_info->width + png_pass_inc[pass] - 1 - png_pass_start[pass]) / @@ -2115,23 +2145,32 @@ void /* PRIVATE */ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) { png_bytep best_row; -#ifndef PNG_NO_WRITE_FILTER +#ifdef PNG_WRITE_FILTER_SUPPORTED png_bytep prev_row, row_buf; png_uint_32 mins, bpp; png_byte filter_to_do = png_ptr->do_filter; png_uint_32 row_bytes = row_info->rowbytes; -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED int num_p_filters = (int)png_ptr->num_prev_filters; -#endif +#endif + + png_debug(1, "in png_write_find_filter"); - png_debug(1, "in png_write_find_filter\n"); - /* find out how many bytes offset each pixel is */ +#ifndef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED + if (png_ptr->row_number == 0 && filter_to_do == PNG_ALL_FILTERS) + { + /* These will never be selected so we need not test them. */ + filter_to_do &= ~(PNG_FILTER_UP | PNG_FILTER_PAETH); + } +#endif + + /* Find out how many bytes offset each pixel is */ bpp = (row_info->pixel_depth + 7) >> 3; prev_row = png_ptr->prev_row; #endif best_row = png_ptr->row_buf; -#ifndef PNG_NO_WRITE_FILTER +#ifdef PNG_WRITE_FILTER_SUPPORTED row_buf = best_row; mins = PNG_MAXSUM; @@ -2174,7 +2213,7 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) sum += (v < 128) ? v : 256 - v; } -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED if (png_ptr->heuristic_method == PNG_FILTER_HEURISTIC_WEIGHTED) { png_uint_32 sumhi, sumlo; @@ -2212,9 +2251,9 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) mins = sum; } - /* sub filter */ + /* Sub filter */ if (filter_to_do == PNG_FILTER_SUB) - /* it's the only filter so no testing is needed */ + /* It's the only filter so no testing is needed */ { png_bytep rp, lp, dp; png_uint_32 i; @@ -2238,7 +2277,7 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) png_uint_32 i; int v; -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED /* We temporarily increase the "minimum sum" by the factor we * would reduce the sum of this filter, so that we can do the * early exit comparison without scaling the sum each time. @@ -2291,7 +2330,7 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) break; } -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED if (png_ptr->heuristic_method == PNG_FILTER_HEURISTIC_WEIGHTED) { int j; @@ -2329,7 +2368,7 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) } } - /* up filter */ + /* Up filter */ if (filter_to_do == PNG_FILTER_UP) { png_bytep rp, dp, pp; @@ -2352,7 +2391,7 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) int v; -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED if (png_ptr->heuristic_method == PNG_FILTER_HEURISTIC_WEIGHTED) { int j; @@ -2394,7 +2433,7 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) break; } -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED if (png_ptr->heuristic_method == PNG_FILTER_HEURISTIC_WEIGHTED) { int j; @@ -2432,7 +2471,7 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) } } - /* avg filter */ + /* Avg filter */ if (filter_to_do == PNG_FILTER_AVG) { png_bytep rp, dp, pp, lp; @@ -2457,7 +2496,7 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) png_uint_32 i; int v; -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED if (png_ptr->heuristic_method == PNG_FILTER_HEURISTIC_WEIGHTED) { int j; @@ -2506,7 +2545,7 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) break; } -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED if (png_ptr->heuristic_method == PNG_FILTER_HEURISTIC_WEIGHTED) { int j; @@ -2590,7 +2629,7 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) png_uint_32 i; int v; -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED if (png_ptr->heuristic_method == PNG_FILTER_HEURISTIC_WEIGHTED) { int j; @@ -2671,7 +2710,7 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) break; } -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED if (png_ptr->heuristic_method == PNG_FILTER_HEURISTIC_WEIGHTED) { int j; @@ -2707,13 +2746,13 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) best_row = png_ptr->paeth_row; } } -#endif /* PNG_NO_WRITE_FILTER */ +#endif /* PNG_WRITE_FILTER_SUPPORTED */ /* Do the actual writing of the filtered row data from the chosen filter. */ png_write_filtered_row(png_ptr, best_row); -#ifndef PNG_NO_WRITE_FILTER -#if defined(PNG_WRITE_WEIGHTED_FILTER_SUPPORTED) +#ifdef PNG_WRITE_FILTER_SUPPORTED +#ifdef PNG_WRITE_WEIGHTED_FILTER_SUPPORTED /* Save the type of filter we picked this time for future calculations */ if (png_ptr->num_prev_filters > 0) { @@ -2725,7 +2764,7 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) png_ptr->prev_filters[j] = best_row[0]; } #endif -#endif /* PNG_NO_WRITE_FILTER */ +#endif /* PNG_WRITE_FILTER_SUPPORTED */ } @@ -2733,20 +2772,21 @@ png_write_find_filter(png_structp png_ptr, png_row_infop row_info) void /* PRIVATE */ png_write_filtered_row(png_structp png_ptr, png_bytep filtered_row) { - png_debug(1, "in png_write_filtered_row\n"); - png_debug1(2, "filter = %d\n", filtered_row[0]); - /* set up the zlib input buffer */ + png_debug(1, "in png_write_filtered_row"); + + png_debug1(2, "filter = %d", filtered_row[0]); + /* Set up the zlib input buffer */ png_ptr->zstream.next_in = filtered_row; png_ptr->zstream.avail_in = (uInt)png_ptr->row_info.rowbytes + 1; - /* repeat until we have compressed all the data */ + /* Repeat until we have compressed all the data */ do { - int ret; /* return of zlib */ + int ret; /* Return of zlib */ - /* compress the data */ + /* Compress the data */ ret = deflate(&png_ptr->zstream, Z_NO_FLUSH); - /* check for compression errors */ + /* Check for compression errors */ if (ret != Z_OK) { if (png_ptr->zstream.msg != NULL) @@ -2755,18 +2795,18 @@ png_write_filtered_row(png_structp png_ptr, png_bytep filtered_row) png_error(png_ptr, "zlib error"); } - /* see if it is time to write another IDAT */ + /* See if it is time to write another IDAT */ if (!(png_ptr->zstream.avail_out)) { - /* write the IDAT and reset the zlib output buffer */ + /* Write the IDAT and reset the zlib output buffer */ png_write_IDAT(png_ptr, png_ptr->zbuf, png_ptr->zbuf_size); png_ptr->zstream.next_out = png_ptr->zbuf; png_ptr->zstream.avail_out = (uInt)png_ptr->zbuf_size; } - /* repeat until all data has been compressed */ + /* Repeat until all data has been compressed */ } while (png_ptr->zstream.avail_in); - /* swap the current and previous rows */ + /* Swap the current and previous rows */ if (png_ptr->prev_row != NULL) { png_bytep tptr; @@ -2776,10 +2816,10 @@ png_write_filtered_row(png_structp png_ptr, png_bytep filtered_row) png_ptr->row_buf = tptr; } - /* finish row - updates counters and flushes zlib if last row */ + /* Finish row - updates counters and flushes zlib if last row */ png_write_finish_row(png_ptr); -#if defined(PNG_WRITE_FLUSH_SUPPORTED) +#ifdef PNG_WRITE_FLUSH_SUPPORTED png_ptr->flush_rows++; if (png_ptr->flush_dist > 0 && diff --git a/graf2d/asimage/src/libAfterImage/libungif/dgif_lib.c b/graf2d/asimage/src/libAfterImage/libungif/dgif_lib.c index c333d307b318c..fee76c99aaaef 100644 --- a/graf2d/asimage/src/libAfterImage/libungif/dgif_lib.c +++ b/graf2d/asimage/src/libAfterImage/libungif/dgif_lib.c @@ -687,7 +687,7 @@ static int DGifGetPrefixChar(unsigned int *Prefix, int Code, int ClearCode) * The LZ decompression input routine: * * This routine is responsable for the decompression of the bit stream from * * 8 bits (bytes) packets, into the real codes. * -* Returns GIF_OK if read succesfully. * +* Returns GIF_OK if read successfully. * ******************************************************************************/ static int DGifDecompressInput(GifFileType *GifFile, int *Code) { @@ -730,7 +730,7 @@ static int DGifDecompressInput(GifFileType *GifFile, int *Code) * This routines read one gif data block at a time and buffers it internally * * so that the decompression routine could access it. * * The routine returns the next byte from its internal buffer (or read next * -* block in if buffer empty) and returns GIF_OK if succesful. * +* block in if buffer empty) and returns GIF_OK if successful. * ******************************************************************************/ static int DGifBufferedInput(GifFileType *GifFile, GifByteType *Buf, GifByteType *NextByte) diff --git a/graf2d/asimage/src/libAfterImage/libungif/egif_lib.c b/graf2d/asimage/src/libAfterImage/libungif/egif_lib.c index 6b0acbfb6d3db..27dfec6504afe 100644 --- a/graf2d/asimage/src/libAfterImage/libungif/egif_lib.c +++ b/graf2d/asimage/src/libAfterImage/libungif/egif_lib.c @@ -69,7 +69,7 @@ static int EGifBufferedOutput(GifFileType *GifFile, GifByteType *Buf, int c); * Update a new gif file, given its file handle, which must be opened for * * write in binary mode. * * Returns GifFileType pointer dynamically allocated which serves as the gif * -* info record. _GifError is cleared if succesfull. * +* info record. _GifError is cleared if successful. * ******************************************************************************/ GifFileType *EGifOpenFileHandle(int FileHandle) { @@ -732,7 +732,7 @@ static int EGifCompressLine(GifFileType *GifFile, GifPixelType *Line, * The LZ compression output routine: * * This routine is responsible for the compression of the bit stream into * * 8 bits (bytes) packets. * -* Returns GIF_OK if written succesfully. * +* Returns GIF_OK if written successfully. * ******************************************************************************/ static int EGifCompressOutput(GifFileType *GifFile, int Code) { @@ -778,7 +778,7 @@ static int EGifCompressOutput(GifFileType *GifFile, int Code) * This routines buffers the given characters until 255 characters are ready * * to be output. If Code is equal to -1 the buffer is flushed (EOF). * * The buffer is Dumped with first byte as its size, as GIF format requires. * -* Returns GIF_OK if written succesfully. * +* Returns GIF_OK if written successfully. * ******************************************************************************/ static int EGifBufferedOutput(GifFileType *GifFile, GifByteType *Buf, int c) { diff --git a/graf2d/asimage/src/libAfterImage/transform.c b/graf2d/asimage/src/libAfterImage/transform.c index 4134e59c501a2..9c86e3ac9772a 100644 --- a/graf2d/asimage/src/libAfterImage/transform.c +++ b/graf2d/asimage/src/libAfterImage/transform.c @@ -2639,7 +2639,7 @@ static void calc_gauss_double(double radius, double* gauss) gauss[0] = 1.0; return; } - /* after radius of 128 - gaussian degrades into something wierd, + /* after radius of 128 - gaussian degrades into something weird, since our colors are only 8 bit */ if (radius > 128.0) radius = 128.0; std_dev = (radius - 1) * 0.3003866304; @@ -2707,7 +2707,7 @@ static void calc_gauss_int(int radius, GAUSS_COEFF_TYPE* gauss, GAUSS_COEFF_TYPE gauss_sums[0] = 1024; return; } - /* after radius of 128 - gaussian degrades into something wierd, + /* after radius of 128 - gaussian degrades into something weird, since our colors are only 8 bit */ if (i > 128) i = 128; #if 1 diff --git a/graf2d/asimage/src/libAfterImage/win32/asview.dsp b/graf2d/asimage/src/libAfterImage/win32/asview.dsp index 2959037d38747..af83fef23adc9 100644 --- a/graf2d/asimage/src/libAfterImage/win32/asview.dsp +++ b/graf2d/asimage/src/libAfterImage/win32/asview.dsp @@ -1,122 +1,122 @@ -# Microsoft Developer Studio Project File - Name="asview" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** DO NOT EDIT ** - -# TARGTYPE "Win32 (x86) Application" 0x0101 - -CFG=asview - Win32 Debug -!MESSAGE This is not a valid makefile. To build this project using NMAKE, -!MESSAGE use the Export Makefile command and run -!MESSAGE -!MESSAGE NMAKE /f "asview.mak". -!MESSAGE -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "asview.mak" CFG="asview - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "asview - Win32 Release" (based on "Win32 (x86) Application") -!MESSAGE "asview - Win32 Debug" (based on "Win32 (x86) Application") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -MTL=midl.exe -RSC=rc.exe - -!IF "$(CFG)" == "asview - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "Release" -# PROP Intermediate_Dir "Release" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /c -# ADD CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /c -# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x409 /d "NDEBUG" -# ADD RSC /l 0x409 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 /nodefaultlib:"LIBCD" /nodefaultlib:"LIBC" /out:"asview.exe" /editandcontinue:NO -# SUBTRACT LINK32 /pdb:none - -!ELSEIF "$(CFG)" == "asview - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "asview___Win32_Debug" -# PROP BASE Intermediate_Dir "asview___Win32_Debug" -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "Debug" -# PROP Intermediate_Dir "Debug" -# PROP Ignore_Export_Lib 0 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /GZ /c -# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /GZ /c -# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 -# ADD BASE RSC /l 0x409 /d "_DEBUG" -# ADD RSC /l 0x409 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /nodefaultlib:"LIBC" /out:"asview.exe" /pdbtype:sept -# SUBTRACT LINK32 /pdb:none - -!ENDIF - -# Begin Target - -# Name "asview - Win32 Release" -# Name "asview - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\asview.cpp -# End Source File -# Begin Source File - -SOURCE=.\StdAfx.cpp -# ADD CPP /Yc"stdafx.h" -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# Begin Source File - -SOURCE=.\StdAfx.h -# End Source File -# End Group -# Begin Group "Resource Files" - -# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" -# End Group -# Begin Source File - -SOURCE=..\libAfterImage.lib -# End Source File -# End Target -# End Project +# Microsoft Developer Studio Project File - Name="asview" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Application" 0x0101 + +CFG=asview - Win32 Debug +!MESSAGE This is not a valid makefile. To build this project using NMAKE, +!MESSAGE use the Export Makefile command and run +!MESSAGE +!MESSAGE NMAKE /f "asview.mak". +!MESSAGE +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "asview.mak" CFG="asview - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "asview - Win32 Release" (based on "Win32 (x86) Application") +!MESSAGE "asview - Win32 Debug" (based on "Win32 (x86) Application") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName "" +# PROP Scc_LocalPath "" +CPP=cl.exe +MTL=midl.exe +RSC=rc.exe + +!IF "$(CFG)" == "asview - Win32 Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "Release" +# PROP BASE Intermediate_Dir "Release" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "Release" +# PROP Intermediate_Dir "Release" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /c +# ADD CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /c +# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x409 /d "NDEBUG" +# ADD RSC /l 0x409 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 /nodefaultlib:"LIBCD" /nodefaultlib:"LIBC" /out:"asview.exe" /editandcontinue:NO +# SUBTRACT LINK32 /pdb:none + +!ELSEIF "$(CFG)" == "asview - Win32 Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "asview___Win32_Debug" +# PROP BASE Intermediate_Dir "asview___Win32_Debug" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "Debug" +# PROP Intermediate_Dir "Debug" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /GZ /c +# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Yu"stdafx.h" /FD /GZ /c +# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x409 /d "_DEBUG" +# ADD RSC /l 0x409 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /nodefaultlib:"LIBC" /out:"asview.exe" /pdbtype:sept +# SUBTRACT LINK32 /pdb:none + +!ENDIF + +# Begin Target + +# Name "asview - Win32 Release" +# Name "asview - Win32 Debug" +# Begin Group "Source Files" + +# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" +# Begin Source File + +SOURCE=.\asview.cpp +# End Source File +# Begin Source File + +SOURCE=.\StdAfx.cpp +# ADD CPP /Yc"stdafx.h" +# End Source File +# End Group +# Begin Group "Header Files" + +# PROP Default_Filter "h;hpp;hxx;hm;inl" +# Begin Source File + +SOURCE=.\StdAfx.h +# End Source File +# End Group +# Begin Group "Resource Files" + +# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" +# End Group +# Begin Source File + +SOURCE=..\libAfterImage.lib +# End Source File +# End Target +# End Project diff --git a/graf2d/asimage/src/libAfterImage/win32/asview.mak b/graf2d/asimage/src/libAfterImage/win32/asview.mak index c9a8eed130332..ee1bd8cd616e9 100644 --- a/graf2d/asimage/src/libAfterImage/win32/asview.mak +++ b/graf2d/asimage/src/libAfterImage/win32/asview.mak @@ -1,229 +1,229 @@ -# Microsoft Developer Studio Generated NMAKE File, Based on asview.dsp -!IF "$(CFG)" == "" -CFG=asview - Win32 Debug -!MESSAGE No configuration specified. Defaulting to asview - Win32 Debug. -!ENDIF - -!IF "$(CFG)" != "asview - Win32 Release" && "$(CFG)" != "asview - Win32 Debug" -!MESSAGE Invalid configuration "$(CFG)" specified. -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "asview.mak" CFG="asview - Win32 Debug" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "asview - Win32 Release" (based on "Win32 (x86) Application") -!MESSAGE "asview - Win32 Debug" (based on "Win32 (x86) Application") -!MESSAGE -!ERROR An invalid configuration is specified. -!ENDIF - -!IF "$(OS)" == "Windows_NT" -NULL= -!ELSE -NULL=nul -!ENDIF - -CPP=cl.exe -MTL=midl.exe -RSC=rc.exe - -!IF "$(CFG)" == "asview - Win32 Release" - -OUTDIR=.\Release -INTDIR=.\Release - -!IF "$(RECURSE)" == "0" - -ALL : ".\asview.exe" - -!ELSE - -ALL : "libAfterImage - Win32 Release" ".\asview.exe" - -!ENDIF - -!IF "$(RECURSE)" == "1" -CLEAN :"libAfterImage - Win32 ReleaseCLEAN" -!ELSE -CLEAN : -!ENDIF - -@erase "$(INTDIR)\asview.obj" - -@erase "$(INTDIR)\asview.pch" - -@erase "$(INTDIR)\StdAfx.obj" - -@erase "$(INTDIR)\vc60.idb" - -@erase ".\asview.exe" - -"$(OUTDIR)" : - if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" - -CPP_PROJ=/nologo /ML /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Fp"$(INTDIR)\asview.pch" /Yu"stdafx.h" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c -MTL_PROJ=/nologo /D "NDEBUG" /mktyplib203 /win32 -BSC32=bscmake.exe -BSC32_FLAGS=/nologo /o"$(OUTDIR)\asview.bsc" -BSC32_SBRS= \ - -LINK32=link.exe -LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /incremental:no /pdb:"$(OUTDIR)\asview.pdb" /machine:I386 /nodefaultlib:"LIBCD" /out:"asview.exe" /editandcontinue:NO -LINK32_OBJS= \ - "$(INTDIR)\asview.obj" \ - "$(INTDIR)\StdAfx.obj" \ - "..\libAfterImage.lib" - -".\asview.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) - $(LINK32) @<< - $(LINK32_FLAGS) $(LINK32_OBJS) -<< - -!ELSEIF "$(CFG)" == "asview - Win32 Debug" - -OUTDIR=.\Debug -INTDIR=.\Debug - -!IF "$(RECURSE)" == "0" - -ALL : ".\asview.exe" - -!ELSE - -ALL : "libAfterImage - Win32 Debug" ".\asview.exe" - -!ENDIF - -!IF "$(RECURSE)" == "1" -CLEAN :"libAfterImage - Win32 DebugCLEAN" -!ELSE -CLEAN : -!ENDIF - -@erase "$(INTDIR)\asview.obj" - -@erase "$(INTDIR)\asview.pch" - -@erase "$(INTDIR)\StdAfx.obj" - -@erase "$(INTDIR)\vc60.idb" - -@erase "$(INTDIR)\vc60.pdb" - -@erase "$(OUTDIR)\asview.pdb" - -@erase ".\asview.exe" - -@erase ".\asview.ilk" - -"$(OUTDIR)" : - if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" - -CPP_PROJ=/nologo /MLd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Fp"$(INTDIR)\asview.pch" /Yu"stdafx.h" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c -MTL_PROJ=/nologo /D "_DEBUG" /mktyplib203 /win32 -BSC32=bscmake.exe -BSC32_FLAGS=/nologo /o"$(OUTDIR)\asview.bsc" -BSC32_SBRS= \ - -LINK32=link.exe -LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /incremental:yes /pdb:"$(OUTDIR)\asview.pdb" /debug /machine:I386 /nodefaultlib:"LIBC" /out:"asview.exe" /pdbtype:sept -LINK32_OBJS= \ - "$(INTDIR)\asview.obj" \ - "$(INTDIR)\StdAfx.obj" \ - "..\libAfterImage.lib" - -".\asview.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) - $(LINK32) @<< - $(LINK32_FLAGS) $(LINK32_OBJS) -<< - -!ENDIF - -.c{$(INTDIR)}.obj:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.cpp{$(INTDIR)}.obj:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.cxx{$(INTDIR)}.obj:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.c{$(INTDIR)}.sbr:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.cpp{$(INTDIR)}.sbr:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.cxx{$(INTDIR)}.sbr:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - - -!IF "$(NO_EXTERNAL_DEPS)" != "1" -!IF EXISTS("asview.dep") -!INCLUDE "asview.dep" -!ELSE -!MESSAGE Warning: cannot find "asview.dep" -!ENDIF -!ENDIF - - -!IF "$(CFG)" == "asview - Win32 Release" || "$(CFG)" == "asview - Win32 Debug" -SOURCE=.\asview.cpp - -"$(INTDIR)\asview.obj" : $(SOURCE) "$(INTDIR)" "$(INTDIR)\asview.pch" - - -SOURCE=.\StdAfx.cpp - -!IF "$(CFG)" == "asview - Win32 Release" - -CPP_SWITCHES=/nologo /ML /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Fp"$(INTDIR)\asview.pch" /Yc"stdafx.h" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c - -"$(INTDIR)\StdAfx.obj" "$(INTDIR)\asview.pch" : $(SOURCE) "$(INTDIR)" - $(CPP) @<< - $(CPP_SWITCHES) $(SOURCE) -<< - - -!ELSEIF "$(CFG)" == "asview - Win32 Debug" - -CPP_SWITCHES=/nologo /MLd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Fp"$(INTDIR)\asview.pch" /Yc"stdafx.h" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c - -"$(INTDIR)\StdAfx.obj" "$(INTDIR)\asview.pch" : $(SOURCE) "$(INTDIR)" - $(CPP) @<< - $(CPP_SWITCHES) $(SOURCE) -<< - - -!ENDIF - -!IF "$(CFG)" == "asview - Win32 Release" - -"libAfterImage - Win32 Release" : - cd "\devel\AfterStep\afterstep-stable\libAfterImage" - $(MAKE) /$(MAKEFLAGS) /F ".\libAfterImage.mak" CFG="libAfterImage - Win32 Release" - cd ".\win32" - -"libAfterImage - Win32 ReleaseCLEAN" : - cd "\devel\AfterStep\afterstep-stable\libAfterImage" - $(MAKE) /$(MAKEFLAGS) /F ".\libAfterImage.mak" CFG="libAfterImage - Win32 Release" RECURSE=1 CLEAN - cd ".\win32" - -!ELSEIF "$(CFG)" == "asview - Win32 Debug" - -"libAfterImage - Win32 Debug" : - cd "\devel\AfterStep\afterstep-stable\libAfterImage" - $(MAKE) /$(MAKEFLAGS) /F ".\libAfterImage.mak" CFG="libAfterImage - Win32 Debug" - cd ".\win32" - -"libAfterImage - Win32 DebugCLEAN" : - cd "\devel\AfterStep\afterstep-stable\libAfterImage" - $(MAKE) /$(MAKEFLAGS) /F ".\libAfterImage.mak" CFG="libAfterImage - Win32 Debug" RECURSE=1 CLEAN - cd ".\win32" - -!ENDIF - - -!ENDIF - +# Microsoft Developer Studio Generated NMAKE File, Based on asview.dsp +!IF "$(CFG)" == "" +CFG=asview - Win32 Debug +!MESSAGE No configuration specified. Defaulting to asview - Win32 Debug. +!ENDIF + +!IF "$(CFG)" != "asview - Win32 Release" && "$(CFG)" != "asview - Win32 Debug" +!MESSAGE Invalid configuration "$(CFG)" specified. +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "asview.mak" CFG="asview - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "asview - Win32 Release" (based on "Win32 (x86) Application") +!MESSAGE "asview - Win32 Debug" (based on "Win32 (x86) Application") +!MESSAGE +!ERROR An invalid configuration is specified. +!ENDIF + +!IF "$(OS)" == "Windows_NT" +NULL= +!ELSE +NULL=nul +!ENDIF + +CPP=cl.exe +MTL=midl.exe +RSC=rc.exe + +!IF "$(CFG)" == "asview - Win32 Release" + +OUTDIR=.\Release +INTDIR=.\Release + +!IF "$(RECURSE)" == "0" + +ALL : ".\asview.exe" + +!ELSE + +ALL : "libAfterImage - Win32 Release" ".\asview.exe" + +!ENDIF + +!IF "$(RECURSE)" == "1" +CLEAN :"libAfterImage - Win32 ReleaseCLEAN" +!ELSE +CLEAN : +!ENDIF + -@erase "$(INTDIR)\asview.obj" + -@erase "$(INTDIR)\asview.pch" + -@erase "$(INTDIR)\StdAfx.obj" + -@erase "$(INTDIR)\vc60.idb" + -@erase ".\asview.exe" + +"$(OUTDIR)" : + if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" + +CPP_PROJ=/nologo /ML /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Fp"$(INTDIR)\asview.pch" /Yu"stdafx.h" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c +MTL_PROJ=/nologo /D "NDEBUG" /mktyplib203 /win32 +BSC32=bscmake.exe +BSC32_FLAGS=/nologo /o"$(OUTDIR)\asview.bsc" +BSC32_SBRS= \ + +LINK32=link.exe +LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /incremental:no /pdb:"$(OUTDIR)\asview.pdb" /machine:I386 /nodefaultlib:"LIBCD" /out:"asview.exe" /editandcontinue:NO +LINK32_OBJS= \ + "$(INTDIR)\asview.obj" \ + "$(INTDIR)\StdAfx.obj" \ + "..\libAfterImage.lib" + +".\asview.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) + $(LINK32) @<< + $(LINK32_FLAGS) $(LINK32_OBJS) +<< + +!ELSEIF "$(CFG)" == "asview - Win32 Debug" + +OUTDIR=.\Debug +INTDIR=.\Debug + +!IF "$(RECURSE)" == "0" + +ALL : ".\asview.exe" + +!ELSE + +ALL : "libAfterImage - Win32 Debug" ".\asview.exe" + +!ENDIF + +!IF "$(RECURSE)" == "1" +CLEAN :"libAfterImage - Win32 DebugCLEAN" +!ELSE +CLEAN : +!ENDIF + -@erase "$(INTDIR)\asview.obj" + -@erase "$(INTDIR)\asview.pch" + -@erase "$(INTDIR)\StdAfx.obj" + -@erase "$(INTDIR)\vc60.idb" + -@erase "$(INTDIR)\vc60.pdb" + -@erase "$(OUTDIR)\asview.pdb" + -@erase ".\asview.exe" + -@erase ".\asview.ilk" + +"$(OUTDIR)" : + if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" + +CPP_PROJ=/nologo /MLd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Fp"$(INTDIR)\asview.pch" /Yu"stdafx.h" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c +MTL_PROJ=/nologo /D "_DEBUG" /mktyplib203 /win32 +BSC32=bscmake.exe +BSC32_FLAGS=/nologo /o"$(OUTDIR)\asview.bsc" +BSC32_SBRS= \ + +LINK32=link.exe +LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /incremental:yes /pdb:"$(OUTDIR)\asview.pdb" /debug /machine:I386 /nodefaultlib:"LIBC" /out:"asview.exe" /pdbtype:sept +LINK32_OBJS= \ + "$(INTDIR)\asview.obj" \ + "$(INTDIR)\StdAfx.obj" \ + "..\libAfterImage.lib" + +".\asview.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) + $(LINK32) @<< + $(LINK32_FLAGS) $(LINK32_OBJS) +<< + +!ENDIF + +.c{$(INTDIR)}.obj:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cpp{$(INTDIR)}.obj:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cxx{$(INTDIR)}.obj:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.c{$(INTDIR)}.sbr:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cpp{$(INTDIR)}.sbr:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cxx{$(INTDIR)}.sbr:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + + +!IF "$(NO_EXTERNAL_DEPS)" != "1" +!IF EXISTS("asview.dep") +!INCLUDE "asview.dep" +!ELSE +!MESSAGE Warning: cannot find "asview.dep" +!ENDIF +!ENDIF + + +!IF "$(CFG)" == "asview - Win32 Release" || "$(CFG)" == "asview - Win32 Debug" +SOURCE=.\asview.cpp + +"$(INTDIR)\asview.obj" : $(SOURCE) "$(INTDIR)" "$(INTDIR)\asview.pch" + + +SOURCE=.\StdAfx.cpp + +!IF "$(CFG)" == "asview - Win32 Release" + +CPP_SWITCHES=/nologo /ML /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Fp"$(INTDIR)\asview.pch" /Yc"stdafx.h" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c + +"$(INTDIR)\StdAfx.obj" "$(INTDIR)\asview.pch" : $(SOURCE) "$(INTDIR)" + $(CPP) @<< + $(CPP_SWITCHES) $(SOURCE) +<< + + +!ELSEIF "$(CFG)" == "asview - Win32 Debug" + +CPP_SWITCHES=/nologo /MLd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Fp"$(INTDIR)\asview.pch" /Yc"stdafx.h" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c + +"$(INTDIR)\StdAfx.obj" "$(INTDIR)\asview.pch" : $(SOURCE) "$(INTDIR)" + $(CPP) @<< + $(CPP_SWITCHES) $(SOURCE) +<< + + +!ENDIF + +!IF "$(CFG)" == "asview - Win32 Release" + +"libAfterImage - Win32 Release" : + cd "\devel\AfterStep\afterstep-stable\libAfterImage" + $(MAKE) /$(MAKEFLAGS) /F ".\libAfterImage.mak" CFG="libAfterImage - Win32 Release" + cd ".\win32" + +"libAfterImage - Win32 ReleaseCLEAN" : + cd "\devel\AfterStep\afterstep-stable\libAfterImage" + $(MAKE) /$(MAKEFLAGS) /F ".\libAfterImage.mak" CFG="libAfterImage - Win32 Release" RECURSE=1 CLEAN + cd ".\win32" + +!ELSEIF "$(CFG)" == "asview - Win32 Debug" + +"libAfterImage - Win32 Debug" : + cd "\devel\AfterStep\afterstep-stable\libAfterImage" + $(MAKE) /$(MAKEFLAGS) /F ".\libAfterImage.mak" CFG="libAfterImage - Win32 Debug" + cd ".\win32" + +"libAfterImage - Win32 DebugCLEAN" : + cd "\devel\AfterStep\afterstep-stable\libAfterImage" + $(MAKE) /$(MAKEFLAGS) /F ".\libAfterImage.mak" CFG="libAfterImage - Win32 Debug" RECURSE=1 CLEAN + cd ".\win32" + +!ENDIF + + +!ENDIF + diff --git a/graf2d/asimage/src/libAfterImage/zlib/zlib.h b/graf2d/asimage/src/libAfterImage/zlib/zlib.h index 022817927ce3d..46e2db4908ea0 100644 --- a/graf2d/asimage/src/libAfterImage/zlib/zlib.h +++ b/graf2d/asimage/src/libAfterImage/zlib/zlib.h @@ -869,7 +869,7 @@ ZEXTERN int ZEXPORT inflateBackInit OF((z_streamp strm, int windowBits, See inflateBack() for the usage of these routines. inflateBackInit will return Z_OK on success, Z_STREAM_ERROR if any of - the paramaters are invalid, Z_MEM_ERROR if the internal state could not + the parameters are invalid, Z_MEM_ERROR if the internal state could not be allocated, or Z_VERSION_ERROR if the version of the library does not match the version of the header file. */ diff --git a/graf2d/cocoa/CMakeLists.txt b/graf2d/cocoa/CMakeLists.txt index 556051cb83655..45dc23e8b00ae 100644 --- a/graf2d/cocoa/CMakeLists.txt +++ b/graf2d/cocoa/CMakeLists.txt @@ -6,10 +6,12 @@ ROOT_USE_PACKAGE(graf2d/quartz) ROOT_USE_PACKAGE(gui/gui) -add_definitions("-ObjC++ -std=c++11") +add_definitions("-ObjC++") +include_directories(${FREETYPE_INCLUDE_DIRS}) + ROOT_GENERATE_DICTIONARY(G__Cocoa T*.h LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(GCocoa LINKDEF LinkDef.h DEPENDENCIES Gui GQuartz ) -ROOT_LINKER_LIBRARY(GCocoa *.mm G__Cocoa.cxx LIBRARIES "-framework Cocoa" DEPENDENCIES Gui GQuartz ) +ROOT_LINKER_LIBRARY(GCocoa *.mm G__Cocoa.cxx LIBRARIES "-framework Cocoa" ${FREETYPE_LIBRARIES} DEPENDENCIES Gui GQuartz ) ROOT_INSTALL_HEADERS() diff --git a/graf2d/cocoa/Module.mk b/graf2d/cocoa/Module.mk index 5b547c529650e..995f1869c22f5 100644 --- a/graf2d/cocoa/Module.mk +++ b/graf2d/cocoa/Module.mk @@ -3,6 +3,11 @@ # # Author: Timur Pocheptsov, 22/11/2011 +COCOANDEBUG := -DNDEBUG +ifeq ($(ROOTBUILD),debug) + COCOANDEBUG := +endif + MODNAME := cocoa MODDIR := $(ROOT_SRCDIR)/graf2d/$(MODNAME) MODDIRS := $(MODDIR)/src @@ -44,17 +49,18 @@ INCLUDEFILES += $(COCOADEP) include/%.h: $(COCOADIRI)/%.h cp $< $@ -$(COCOALIB): $(COCOAO) $(COCOAOBJCPPO) $(COCOADO) $(ORDER_) $(MAINLIBS) \ +$(COCOALIB): $(COCOAO) $(COCOAOBJCPPO) $(COCOADO) $(FREETYPEDEP) $(ORDER_) $(MAINLIBS) \ $(COCOALIBDEP) @$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \ "$(SOFLAGS)" libGCocoa.$(SOEXT) $@ \ "$(COCOAO) $(COCOAOBJCPPO) $(COCOADO)" \ - "$(COCOALIBEXTRA) -framework Cocoa -framework OpenGL" + "$(FREETYPELDFLAGS) $(FREETYPELIB) \ + $(COCOALIBEXTRA) -framework Cocoa -framework OpenGL" $(COCOADS): $(COCOAH1) $(COCOAL) $(ROOTCINTTMPDEP) $(MAKEDIR) @echo "Generating dictionary $@..." - $(ROOTCINTTMP) -f $@ -c $(COCOAH1) $(COCOAL) + $(ROOTCINTTMP) -f $@ -c $(FREETYPEINC) $(COCOAH1) $(COCOAL) $(COCOAMAP): $(RLIBMAP) $(MAKEFILEDEP) $(COCOAL) $(RLIBMAP) -o $@ -l $(COCOALIB) \ @@ -71,3 +77,6 @@ distclean-$(MODNAME): clean-$(MODNAME) @rm -f $(COCOADEP) $(COCOADS) $(COCOADH) $(COCOALIB) $(COCOAMAP) distclean:: distclean-$(MODNAME) + +$(COCOAOBJCPPO) $(COCOADO) $(COCOAO): CXXFLAGS += $(COCOANDEBUG) $(FREETYPEINC) + diff --git a/graf2d/cocoa/inc/CocoaGuiTypes.h b/graf2d/cocoa/inc/CocoaGuiTypes.h new file mode 100644 index 0000000000000..c5c8f910d85ea --- /dev/null +++ b/graf2d/cocoa/inc/CocoaGuiTypes.h @@ -0,0 +1,35 @@ +#ifndef ROOT_CocoaGuiTypes +#define ROOT_CocoaGuiTypes + +//This file extends ROOT's GuiTypes.h with additional types I need - Point/Rectangle which can use integers (not short integers). +//To be used in copy:xxxxx methods of X11Drawables and somewhere else. +//It's a shame I have to write such "classes" :)) + +namespace ROOT { +namespace MacOSX { +namespace X11 { + +struct Point { + int fX; + int fY; + + Point(); + Point(int x, int y); +}; + +struct Rectangle { + int fX; + int fY; + + unsigned fWidth; + unsigned fHeight; + + Rectangle(); + Rectangle(int x, int y, unsigned w, unsigned h); +}; + +}//X11 +}//MacOSX +}//ROOT + +#endif diff --git a/graf2d/cocoa/inc/CocoaPrivate.h b/graf2d/cocoa/inc/CocoaPrivate.h index e35e24068a9c3..6cf64b6ec1242 100644 --- a/graf2d/cocoa/inc/CocoaPrivate.h +++ b/graf2d/cocoa/inc/CocoaPrivate.h @@ -9,7 +9,6 @@ * For the list of contributors see $ROOTSYS/README/CREDITS. * *************************************************************************/ - #ifndef ROOT_CocoaPrivate #define ROOT_CocoaPrivate @@ -38,8 +37,12 @@ @protocol X11Drawable; @protocol X11Window; +@class ROOTApplicationDelegate; +@class NSOpenGLContext; @class NSObject; +@class QuartzWindow; + class TGQuartz; class TGCocoa; @@ -55,48 +58,67 @@ namespace MacOSX { namespace Details { class CocoaPrivate { - friend class TGCocoa; - friend class TGQuartz; + friend class ::TGCocoa; + friend class ::TGQuartz; friend class X11::CommandBuffer; public: ~CocoaPrivate(); private: CocoaPrivate(); - int GetRootWindowID()const; - bool IsRootWindow(int wid)const; + Window_t GetRootWindowID()const; + bool IsRootWindow(Window_t windowID)const; CocoaPrivate(const CocoaPrivate &rhs); CocoaPrivate &operator = (const CocoaPrivate &rhs); - unsigned RegisterDrawable(NSObject *nsObj); - NSObject *GetDrawable(unsigned drawableD)const; - NSObject *GetWindow(unsigned windowID)const; - void DeleteDrawable(unsigned drawableID); + Drawable_t RegisterDrawable(NSObject *nsObj); + NSObject *GetDrawable(Drawable_t drawableD)const; + NSObject *GetWindow(Window_t windowID)const; + void DeleteDrawable(Drawable_t drawableID); + + Handle_t RegisterGLContext(NSOpenGLContext *glContext); + void DeleteGLContext(Handle_t contextID); + NSOpenGLContext *GetGLContextForHandle(Handle_t contextID); + Handle_t GetHandleForGLContext(NSOpenGLContext *glContext); + + void SetFakeGLWindow(QuartzWindow *fakeWin); + QuartzWindow *GetFakeGLWindow(); //This function resets strong reference, if you still want NSObject for drawableID to live, //you have to retain the pointer (probably) and also drawableID will become id for nsObj (replacement). - void ReplaceDrawable(unsigned drawableID, NSObject *nsObj); + void ReplaceDrawable(Drawable_t drawableID, NSObject *nsObj); //Color "parser": either parse string like "#ddeeaa", or //search rgb.txt like table for named color. - X11::ColorParser fX11ColorParser; + X11::ColorParser fX11ColorParser; //Event translator, converts Cocoa events into X11 events //and generates X11 events. - X11::EventTranslator fX11EventTranslator; + X11::EventTranslator fX11EventTranslator; //Command buffer - for "buffered" drawing commands. - X11::CommandBuffer fX11CommandBuffer; + X11::CommandBuffer fX11CommandBuffer; //Font manager - cache CTFontRef for GUI. - FontCache fFontManager; + FontCache fFontManager; //Id for the new registered drawable. - unsigned fCurrentDrawableID; - //Cache of ids. - std::vector fFreeDrawableIDs; + Drawable_t fCurrentDrawableID; + //"Cache" of ids. + std::vector fFreeDrawableIDs; //Cocoa objects (views, windows, "pixmaps"). std::map > > fDrawables; typedef std::map > >::iterator drawable_iterator; typedef std::map > >::const_iterator const_drawable_iterator; + + typedef std::map > handle2ctx_map; + typedef std::map ctx2handle_map; + + handle2ctx_map fHandleToGLContext; + ctx2handle_map fGLContextToHandle; + + Handle_t fFreeGLContextID; + Util::NSStrongReference fFakeGLWindow; + + Util::NSScopeGuard fApplicationDelegate; }; }//Details diff --git a/graf2d/cocoa/inc/FontCache.h b/graf2d/cocoa/inc/FontCache.h index 31793b199b302..2bdfed863d96d 100644 --- a/graf2d/cocoa/inc/FontCache.h +++ b/graf2d/cocoa/inc/FontCache.h @@ -12,6 +12,7 @@ #ifndef ROOT_FontCache #define ROOT_FontCache +#include #include #include #include @@ -30,9 +31,6 @@ // FontCache class: // // ROOT's GUI relies on TVirtualX to create and use fonts, // // fonts are referenced by integer identifiers. // -// Also, non-GUI graphics wants difference fonts. // -// For the moment, this is quite lame implementation, // -// which I will fix in a future (I promise! ;) ). // // // ////////////////////////////////////////////////////////////////// @@ -43,7 +41,7 @@ namespace Details { class FontCache { public: enum Details { - nPadFonts = 13 + nPadFonts = 15 }; FontCache(); @@ -70,7 +68,9 @@ class FontCache { private: - CTFontRef SelectSymbolFont(Float_t fontSize); + //We have "two symbolic" fonts, both of them use the same symbol.ttf (index 11), + //but the second one (index + CTFontRef SelectSymbolFont(Float_t fontSize, unsigned fontIndex); typedef Util::CFStrongReference CTFontGuard_t; @@ -102,10 +102,15 @@ class FontCache { }; std::list fFontLists;//list of "lists" of fonts :) - FontList fDummyList; + FontList fDummyList; + + typedef std::map PSNameMap_t; + PSNameMap_t fXLFDtoPostscriptNames; FontCache(const FontCache &rhs); FontCache &operator = (const FontCache &rhs); + + bool fSymbolFontRegistered; }; } diff --git a/graf2d/cocoa/inc/MenuLoader.h b/graf2d/cocoa/inc/MenuLoader.h new file mode 100644 index 0000000000000..5798904083315 --- /dev/null +++ b/graf2d/cocoa/inc/MenuLoader.h @@ -0,0 +1,17 @@ +#ifndef ROOT_MenuLoader +#define ROOT_MenuLoader + +#include + +namespace ROOT { +namespace MacOSX { +namespace Details { + +//Fill app's menu. +void PopulateMainMenu(); + +} +} +} + +#endif diff --git a/graf2d/cocoa/inc/QuartzPixmap.h b/graf2d/cocoa/inc/QuartzPixmap.h index caf3268882c3a..17c9ff4c327a2 100644 --- a/graf2d/cocoa/inc/QuartzPixmap.h +++ b/graf2d/cocoa/inc/QuartzPixmap.h @@ -13,10 +13,17 @@ #ifndef ROOT_QuartzPixmap #define ROOT_QuartzPixmap -#import +#include -#import "X11Drawable.h" -#import "GuiTypes.h" +#ifndef ROOT_CocoaGuiTypes +#include "CocoaGuiTypes.h" +#endif +#ifndef ROOT_X11Drawable +#include "X11Drawable.h" +#endif +#ifndef ROOT_GuiTypes +#include "GuiTypes.h" +#endif /////////////////////////////////////////////////////// // // @@ -26,11 +33,11 @@ @interface QuartzPixmap : NSObject -- (id) initWithW : (unsigned) width H : (unsigned) height; -- (BOOL) resizeW : (unsigned) width H : (unsigned) height; +- (id) initWithW : (unsigned) width H : (unsigned) height scaleFactor : (CGFloat) scaleFactor; +- (BOOL) resizeW : (unsigned) width H : (unsigned) height scaleFactor : (CGFloat) scaleFactor; - (CGImageRef) createImageFromPixmap; -- (CGImageRef) createImageFromPixmap : (Rectangle_t) cropArea; +- (CGImageRef) createImageFromPixmap : (ROOT::MacOSX::X11::Rectangle) cropArea; //X11Drawable protocol. @@ -44,13 +51,19 @@ - (unsigned) fWidth; - (unsigned) fHeight; -//Point_t, Rectangle_t are in GuiTypes.h -- (void) copy : (NSObject *) src area : (Rectangle_t) area withMask : (QuartzImage *) mask - clipOrigin : (Point_t) origin toPoint : (Point_t) dstPoint; +- (void) copy : (NSObject *) src area : (ROOT::MacOSX::X11::Rectangle) area withMask : (QuartzImage *) mask + clipOrigin : (ROOT::MacOSX::X11::Point) origin toPoint : (ROOT::MacOSX::X11::Point) dstPoint; + +- (unsigned char *) readColorBits : (ROOT::MacOSX::X11::Rectangle) area; // - (unsigned char *) fData; +//XPutPixel. +- (void) putPixel : (const unsigned char *) data X : (unsigned) x Y : (unsigned) y; +//XAddPixel. +- (void) addPixel : (const unsigned char *) rgb; + @end ///////////////////////////////////////////////////////// @@ -60,10 +73,17 @@ // // ///////////////////////////////////////////////////////// +//TODO: split image and mask image? + @interface QuartzImage : NSObject - (id) initWithW : (unsigned) width H : (unsigned) height data : (unsigned char *) data; - (id) initMaskWithW : (unsigned) width H : (unsigned) height bitmapMask : (unsigned char *) mask; +- (id) initMaskWithW : (unsigned) width H : (unsigned) height; +- (id) initFromPixmap : (QuartzPixmap *) pixmap; +- (id) initFromImage : (QuartzImage *) image; +- (id) initFromImageFlipped : (QuartzImage *) image; + - (void) dealloc; @property (nonatomic, readonly) BOOL fIsStippleMask; - (CGImageRef) fImage; @@ -77,20 +97,21 @@ - (unsigned) fWidth; - (unsigned) fHeight; -- (unsigned char *) readColorBits : (Rectangle_t) area; +- (unsigned char *) readColorBits : (ROOT::MacOSX::X11::Rectangle) area; @end namespace ROOT { namespace MacOSX { -namespace X11 {//X11 emulation. But must go into quartz module later. +namespace X11 { -CGImageRef CreateSubImage(QuartzImage *image, const Rectangle_t &area); +CGImageRef CreateSubImage(QuartzImage *image, const Rectangle &area); // -bool AdjustCropArea(const Rectangle_t &srcRect, Rectangle_t &cropArea); -bool AdjustCropArea(QuartzImage *srcImage, Rectangle_t &cropArea); -bool AdjustCropArea(QuartzPixmap *srcImage, Rectangle_t &cropArea); +bool AdjustCropArea(const Rectangle &srcRect, Rectangle &cropArea); +bool AdjustCropArea(QuartzImage *srcImage, Rectangle &cropArea); +bool AdjustCropArea(QuartzImage *srcImage, NSRect &cropArea); +bool AdjustCropArea(QuartzPixmap *srcImage, Rectangle &cropArea); //Aux. function for TGCocoa. void FillPixmapBuffer(const unsigned char *bitmap, unsigned width, unsigned height, ULong_t foregroundPixel, diff --git a/graf2d/cocoa/inc/QuartzWindow.h b/graf2d/cocoa/inc/QuartzWindow.h index be6e9c1f93409..f066a09ef3c06 100644 --- a/graf2d/cocoa/inc/QuartzWindow.h +++ b/graf2d/cocoa/inc/QuartzWindow.h @@ -9,14 +9,20 @@ * For the list of contributors see $ROOTSYS/README/CREDITS. * *************************************************************************/ - #ifndef ROOT_QuartzWindow #define ROOT_QuartzWindow -#import +#include -#import "X11Drawable.h" -#import "GuiTypes.h" +#ifndef ROOT_CocoaGuiTypes +#include "CocoaGuiTypes.h" +#endif +#ifndef ROOT_X11Drawable +#include "X11Drawable.h" +#endif +#ifndef ROOT_GuiTypes +#include "GuiTypes.h" +#endif //////////////////////////////////////////////// // // @@ -24,25 +30,48 @@ // // //////////////////////////////////////////////// +@class ROOTOpenGLView; +@class QuartzImage; + @interface QuartzWindow : NSWindow +//In Obj-C you do not have to declared everything in an interface declaration. +//I do declare all methods here, just for clarity. + //Life-cycle: "ctor". -- (id) initWithContentRect : (NSRect) contentRect styleMask : (NSUInteger) windowStyle +- (id) initWithContentRect : (NSRect) contentRect styleMask : (NSUInteger) windowStyle backing : (NSBackingStoreType) bufferingType defer : (BOOL) deferCreation windowAttributes : (const SetWindowAttributes_t *) attr; +- (id) initWithGLView : (ROOTOpenGLView *) glView; + +- (void) dealloc; + +//With reference counting and autorelease pools, it's possible that +//TGCocoa::DestroyWindow was called and window was correctly deleted, +//but it's still on screen and if used in some functions (like FindWindowForPointerEvent) +//and this ends in a segmentation fault. +//fIsDeleted property is here to solve this problem. +- (BOOL) fIsDeleted; +- (void) setFIsDeleted : (BOOL) deleted; + +//Many properties in QuartzWindow just forwards to fContentView. +- (void) forwardInvocation : (NSInvocation *) anInvocation; +- (NSMethodSignature*) methodSignatureForSelector : (SEL) selector; + //This is to emulate "transient" window/main window relationship: @property (nonatomic, assign) QuartzWindow *fMainWindow; - (void) addTransientWindow : (QuartzWindow *) window; -//1. X11Drawable protocol. -@property (nonatomic, assign) unsigned fID; +//Shape mask - non-rectangular window. +@property (nonatomic, assign) QuartzImage *fShapeCombineMask; +//@property (nonatomic, assign) NSPoint fShapeMaskShift; + +//1. X11Drawable protocol. - (BOOL) fIsPixmap; - (BOOL) fIsOpenGLWidget; -@property (nonatomic, readonly) CGContextRef fContext; - //Geometry. - (int) fX; - (int) fY; @@ -55,22 +84,16 @@ - (void) setX : (int) x Y : (int) y; // -- (void) copy : (NSObject *) src area : (Rectangle_t) area withMask : (QuartzImage *) mask - clipOrigin : (Point_t) origin toPoint : (Point_t) dstPoint; +- (void) copy : (NSObject *) src area : (ROOT::MacOSX::X11::Rectangle) area withMask : (QuartzImage *) mask + clipOrigin : (ROOT::MacOSX::X11::Point) origin toPoint : (ROOT::MacOSX::X11::Point) dstPoint; -- (unsigned char *) readColorBits : (Rectangle_t) area; +- (unsigned char *) readColorBits : (ROOT::MacOSX::X11::Rectangle) area; //X11Window protocol. ///////////////////////////////////////////////////////////////// //SetWindowAttributes_t/WindowAttributes_t - -@property (nonatomic, assign) long fEventMask; -@property (nonatomic, assign) int fClass; -@property (nonatomic, assign) int fDepth; -@property (nonatomic, assign) int fBitGravity; -@property (nonatomic, assign) int fWinGravity; @property (nonatomic, assign) unsigned long fBackgroundPixel; @property (nonatomic, readonly) int fMapState; @@ -78,16 +101,10 @@ ///////////////////////////////////////////////////////////////// //"Back buffer" is a bitmap, attached to a window by TCanvas. -@property (nonatomic, assign) QuartzPixmap *fBackBuffer; @property (nonatomic, assign) QuartzView *fParentView; @property (nonatomic, readonly) NSView *fContentView; @property (nonatomic, readonly) QuartzWindow *fQuartzWindow; -@property (nonatomic, assign) int fGrabButton; -@property (nonatomic, assign) unsigned fGrabButtonEventMask; -@property (nonatomic, assign) unsigned fGrabKeyModifiers; -@property (nonatomic, assign) BOOL fOwnerEvents; - //Children subviews. - (void) addChild : (NSView *) child; @@ -101,9 +118,6 @@ - (void) mapSubwindows; - (void) unmapWindow; -//Cursors. -@property (nonatomic, assign) ECursor fCurrentCursor; - @end ////////////////////////////////////////////////////////////// @@ -126,6 +140,8 @@ // // //////////////////////////////////////// +@class QuartzImage; + @interface QuartzView : NSView //Life-cycle. @@ -149,9 +165,9 @@ - (void) setX : (int) x Y : (int) y width : (unsigned) w height : (unsigned) h; - (void) setX : (int) x Y : (int) y; -- (void) copy : (NSObject *) src area : (Rectangle_t) area withMask : (QuartzImage *)mask - clipOrigin : (Point_t) origin toPoint : (Point_t) dstPoint; -- (unsigned char *) readColorBits : (Rectangle_t) area; +- (void) copy : (NSObject *) src area : (ROOT::MacOSX::X11::Rectangle) area withMask : (QuartzImage *)mask + clipOrigin : (ROOT::MacOSX::X11::Point) origin toPoint : (ROOT::MacOSX::X11::Point) dstPoint; +- (unsigned char *) readColorBits : (ROOT::MacOSX::X11::Rectangle) area; //X11Window protocol. @@ -164,22 +180,35 @@ @property (nonatomic, assign) int fBitGravity; @property (nonatomic, assign) int fWinGravity; @property (nonatomic, assign) unsigned long fBackgroundPixel; +@property (nonatomic, retain) QuartzImage *fBackgroundPixmap;//Hmm, image, pixmap ... @property (nonatomic, readonly) int fMapState; +@property (nonatomic, assign) BOOL fOverrideRedirect; //End of SetWindowAttributes_t/WindowAttributes_t ///////////////////////////////////////////////////////////////// -@property (nonatomic, assign) QuartzPixmap *fBackBuffer; +@property (nonatomic, retain) QuartzPixmap *fBackBuffer; @property (nonatomic, assign) QuartzView *fParentView; -@property (nonatomic, assign) unsigned fLevel; @property (nonatomic, readonly) NSView *fContentView; @property (nonatomic, readonly) QuartzWindow *fQuartzWindow; -@property (nonatomic, assign) int fGrabButton; -@property (nonatomic, assign) unsigned fGrabButtonEventMask; -@property (nonatomic, assign) unsigned fGrabKeyModifiers; -@property (nonatomic, assign) BOOL fOwnerEvents; +// + +@property (nonatomic, assign) int fPassiveGrabButton; +@property (nonatomic, assign) unsigned fPassiveGrabEventMask; +@property (nonatomic, assign) unsigned fPassiveGrabKeyModifiers; + +@property (nonatomic, assign) BOOL fPassiveGrabOwnerEvents; + +- (void) activatePassiveGrab; +- (void) activateImplicitGrab; +- (void) activateGrab : (unsigned) eventMask ownerEvents : (BOOL) ownerEvents; +- (void) cancelGrab; + +- (BOOL) acceptsCrossingEvents : (unsigned) eventMask; + +// //Children subviews. - (void) addChild : (NSView *)child; @@ -201,7 +230,6 @@ - (BOOL) fIsOverlapped; - (void) setOverlapped : (BOOL) overlap; -- (void) updateLevel : (unsigned) newLevel; - (void) configureNotifyTree; //Additional methods and properties. @@ -218,6 +246,20 @@ //Cursors. @property (nonatomic, assign) ECursor fCurrentCursor; +//X11 "properties". +- (void) setProperty : (const char *) propName data : (unsigned char *) propData size : (unsigned) dataSize + forType : (Atom_t) dataType format : (unsigned) format; +- (BOOL) hasProperty : (const char *) propName; +- (unsigned char *) getProperty : (const char *) propName returnType : (Atom_t *) type + returnFormat : (unsigned *) format nElements : (unsigned *) nElements; +- (void) removeProperty : (const char *) propName; + +//DND +@property (nonatomic, assign) BOOL fIsDNDAware; + +- (NSDragOperation) draggingEntered : (id) sender; +- (BOOL) performDragOperation : (id) sender; + @end @@ -232,9 +274,18 @@ QuartzView *CreateChildView(QuartzView *parent, Int_t x, Int_t y, UInt_t w, UInt UInt_t clss, void *visual, SetWindowAttributes_t *attr, UInt_t wtype); void GetRootWindowAttributes(WindowAttributes_t *attr); +void GetWindowAttributes(NSObject *window, WindowAttributes_t *dst); //Coordinate conversion. + +//This two functions operate with Cocoa's coordinate system (so, 'to screen' will return Cocoa's +//point, and 'from screen' expects Cocoa's point (not ROOT)). +NSPoint ConvertPointFromBaseToScreen(NSWindow *window, NSPoint windowPoint); +NSPoint ConvertPointFromScreenToBase(NSPoint screenPoint, NSWindow *window); + +int GlobalXCocoaToROOT(CGFloat xCocoa); int GlobalYCocoaToROOT(CGFloat yCocoa); +int GlobalXROOTToCocoa(CGFloat xROOT); int GlobalYROOTToCocoa(CGFloat yROOT); int LocalYCocoaToROOT(NSView *parentView, CGFloat yCocoa); @@ -246,9 +297,29 @@ NSPoint TranslateFromScreen(NSPoint point, NSView *to); NSPoint TranslateCoordinates(NSView *fromView, NSView *toView, NSPoint sourcePoint); bool ViewIsTextViewFrame(NSView *view, bool checkParent); +bool ViewIsHtmlViewFrame(NSView *view, bool checkParent); bool LockFocus(NSView *view); void UnlockFocus(NSView *view);//For symmetry only. +bool ScreenPointIsInView(NSView *view, Int_t x, Int_t y); +QuartzWindow *FindWindowInPoint(Int_t x, Int_t y); +NSView *FindDNDAwareViewInPoint(NSView *parentView, Window_t dragWinID, Window_t inputWinID, Int_t x, Int_t y, Int_t maxDepth); + +//Pointer == cursor in X11's terms. + +//These two functions use "mouse location outside of event stream" - simply +//asks for the current cursor location +//("regardless of the current event being handled or of any events pending"). +QuartzWindow *FindWindowUnderPointer(); +NSView *FindViewUnderPointer(); + +//These two functions use coordinates from the event to find a window/view. +QuartzWindow *FindWindowForPointerEvent(NSEvent *pointerEvent); +NSView *FindViewForPointerEvent(NSEvent *pointerEvent); + +//Add shape mask to context. +void ClipToShapeMask(NSView *view, CGContextRef ctx); + }//X11 }//MacOSX }//ROOT diff --git a/graf2d/cocoa/inc/ROOTApplicationDelegate.h b/graf2d/cocoa/inc/ROOTApplicationDelegate.h new file mode 100644 index 0000000000000..572aee2ff6849 --- /dev/null +++ b/graf2d/cocoa/inc/ROOTApplicationDelegate.h @@ -0,0 +1,9 @@ +#ifndef ROOT_ROOTApplicationDelegate +#define ROOT_ROOTApplicationDelegate + +#include + +@interface ROOTApplicationDelegate : NSObject +@end + +#endif diff --git a/graf2d/cocoa/inc/ROOTOpenGLView.h b/graf2d/cocoa/inc/ROOTOpenGLView.h index d07a91a558ecd..914d682997795 100644 --- a/graf2d/cocoa/inc/ROOTOpenGLView.h +++ b/graf2d/cocoa/inc/ROOTOpenGLView.h @@ -12,9 +12,9 @@ #ifndef ROOT_ROOTOpenGLView #define ROOT_ROOTOpenGLView -#import "X11Drawable.h" - -@class QuartzView; +#ifndef ROOT_QuartzWindow +#include "QuartzWindow.h" +#endif /////////////////////////////////////////// // // @@ -22,73 +22,55 @@ // // /////////////////////////////////////////// -@interface ROOTOpenGLView : NSOpenGLView +@interface ROOTOpenGLView : QuartzView -//NSOpenGLView methods. - (id) initWithFrame : (NSRect) frameRect pixelFormat : (NSOpenGLPixelFormat *) format; -- (void) clearGLContext; -- (NSOpenGLContext *) openGLContext; -- (NSOpenGLPixelFormat *) pixelFormat; -- (void) prepareOpenGL; -- (void) reshape; -- (void) setOpenGLContext : (NSOpenGLContext *) context; -- (void) setPixelFormat : (NSOpenGLPixelFormat *) pixelFormat; -- (void) update; -//X11Drawable protocol +//GL-view does not own GL-context, different GL contexts can be attached to the same view +//(though ROOT never does this). View has to know about GL-context only to notify it about +//geometry changes (calls -update method) and to clear drawable in a -dealloc method. -@property (nonatomic, assign) unsigned fID; +@property (nonatomic, retain) NSOpenGLContext *fOpenGLContext; -- (BOOL) fIsPixmap; -- (BOOL) fIsOpenGLWidget; +//ROOT's GL uses pixel format (TGLFormat class) when TGLWidget is +//created, after that, pixel format never changed (though I can do +//this with ROOTOpenGLView, there is no interface in ROOT's GL code for this). +//So, pixel format is a property of ROOTOpenGLView. GL-view owns pixel format, +//it can also be reset externally (again, GL module never does this). +//Later, when creating GL-context, this pixel format is used (and +//ROOT creates GL-context per GL-widget, thus using pixel format from a widget. -- (int) fX; -- (int) fY; -- (unsigned) fWidth; -- (unsigned) fHeight; - -//X11Window protocol. +- (NSOpenGLPixelFormat *) pixelFormat; +- (void) setPixelFormat : (NSOpenGLPixelFormat *) pixelFormat; -- (void) setDrawableSize : (NSSize) newSize; -- (void) setX : (int) x Y : (int) y width : (unsigned) w height : (unsigned) h; -- (void) setX : (int) x Y : (int) y; +//View's geometry is updated by ROOT's GUI, but view +//can be hidden at the moment (for example, tab with GL-view is not active +//at the moment). If so, when view is visible again, context must +//be notified about changes in a drawable's geometry. +@property (nonatomic, assign) BOOL fUpdateContext; -@property (nonatomic, assign) long fEventMask; -@property (nonatomic, readonly) int fMapState; +- (BOOL) fIsOpenGLWidget; -@property (nonatomic, assign) QuartzView *fParentView; -@property (nonatomic, assign) unsigned fLevel; -@property (nonatomic, readonly) NSView *fContentView; -@property (nonatomic, readonly) QuartzWindow *fQuartzWindow; +//X11Window protocol. -@property (nonatomic, assign) int fGrabButton; -@property (nonatomic, assign) unsigned fGrabButtonEventMask; -@property (nonatomic, assign) unsigned fGrabKeyModifiers; -@property (nonatomic, assign) BOOL fOwnerEvents; -/* -- (void) getAttributes : (WindowAttributes_t *) attr; -- (void) setAttributes : (const SetWindowAttributes_t *) attr; +@property (nonatomic, retain) QuartzPixmap *fBackBuffer;//nil. -- (void) mapRaised; - (void) mapWindow; - (void) mapSubwindows; -- (void) unmapWindow; -- (void) raiseWindow; -- (void) lowerWindow; - +- (void) configureNotifyTree; - (BOOL) fIsOverlapped; - (void) setOverlapped : (BOOL) overlap; -- (void) updateLevel : (unsigned) newLevel; -- (void) configureNotifyTree; -*/ -- (void) addPassiveKeyGrab : (unichar) keyCode modifiers : (NSUInteger) modifiers; -- (void) removePassiveKeyGrab : (unichar) keyCode modifiers : (NSUInteger) modifiers; -- (PassiveKeyGrab *) findPassiveKeyGrab : (unichar) keyCode modifiers : (NSUInteger) modifiers; -- (PassiveKeyGrab *) findPassiveKeyGrab : (unichar) keyCode; - -//Cursors. -@property (nonatomic, assign) ECursor fCurrentCursor; @end +namespace ROOT { +namespace MacOSX { +namespace OpenGL { + +bool GLViewIsValidDrawable(ROOTOpenGLView *glView); + +} +} +} + #endif diff --git a/graf2d/cocoa/inc/SharedViewMethods.h b/graf2d/cocoa/inc/SharedViewMethods.h deleted file mode 100644 index e07dfec59a354..0000000000000 --- a/graf2d/cocoa/inc/SharedViewMethods.h +++ /dev/null @@ -1,362 +0,0 @@ -// @(#)root/graf2d:$Id$ -// Author: Timur Pocheptsov 26/04/2012 - -/************************************************************************* - * Copyright (C) 1995-2012, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_SharedViewMethods -#define ROOT_SharedViewMethods - -///////////////////////////////////////////////////////////////////////////////// -// // -// Inclusion guards are no really needed, this is unusuall header file. // -// Since I can not inherit ROOTOpenGLView from QuartzView and have to // -// inherit NSOpenGLView, QuartzView and ROOTOpenGLView are two completely // -// unrelated classes (and can not have a common custom view class as base). // -// But still they have a lot in common (event processing, etc.), // -// this common part - "shared methods". // -// // -///////////////////////////////////////////////////////////////////////////////// - - -//X11Window protocol. - -//______________________________________________________________________________ -- (int) fX -{ - return self.frame.origin.x; -} - -//______________________________________________________________________________ -- (int) fY -{ - return self.frame.origin.y; -} - -//______________________________________________________________________________ -- (unsigned) fWidth -{ - return self.frame.size.width; -} - -//______________________________________________________________________________ -- (unsigned) fHeight -{ - return self.frame.size.height; -} - - -//TODO: check, if it can be used by OpenGLView. -//______________________________________________________________________________ -- (void) setDrawableSize : (NSSize) newSize -{ - assert(!(newSize.width < 0) && "setDrawableSize, width is negative"); - assert(!(newSize.height < 0) && "setDrawableSize, height is negative"); - - //This will cause redraw(?) - - //In X11, resize changes the size, but upper-left corner is not changed. - //In Cocoa, bottom-left is fixed. - NSRect frame = self.frame; - frame.size = newSize; - - self.frame = frame; -} - -//______________________________________________________________________________ -- (void) setX : (int) x Y : (int) y width : (unsigned) w height : (unsigned) h -{ - assert(fParentView != nil && "setX:Y:width:height:, parent view is nil"); - - NSRect newFrame = {}; - newFrame.origin.x = x; - newFrame.origin.y = y; - newFrame.size.width = w; - newFrame.size.height = h; - - self.frame = newFrame; -} - -//______________________________________________________________________________ -- (void) setX : (int) x Y : (int) y -{ - assert(fParentView != nil && "setX:Y:, parent view is nil"); - - NSRect newFrame = self.frame; - newFrame.origin.x = x; - newFrame.origin.y = y; - - self.frame = newFrame; -} - -//______________________________________________________________________________ -- (int) fMapState -{ - if ([self isHidden]) - return kIsUnmapped; - - for (QuartzView *parent = fParentView; parent; parent = parent.fParentView) { - if ([parent isHidden]) - return kIsUnviewable; - } - - return kIsViewable; -} - - -//______________________________________________________________________________ -- (NSView *) fContentView -{ - return self; -} - -//______________________________________________________________________________ -- (QuartzWindow *) fQuartzWindow -{ - return (QuartzWindow *)[self window]; -} - -//Events. - -//______________________________________________________________________________ -- (void) mouseDown : (NSEvent *) theEvent -{ - assert(fID != 0 && "mouseDown, fID is 0"); - - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != nullptr && "mouseDown, gVirtualX is either null or has a type, different from TGCocoa"); - vx->GetEventTranslator()->GenerateButtonPressEvent(self, theEvent, kButton1); -} - -//______________________________________________________________________________ -- (void) scrollWheel : (NSEvent*) theEvent -{ - assert(fID != 0 && "scrollWheel, fID is 0"); - - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != nullptr && "scrollWheel, gVirtualX is either null or has a type, different from TGCocoa"); - - const CGFloat deltaY = [theEvent deltaY]; - if (deltaY < 0) { - vx->GetEventTranslator()->GenerateButtonPressEvent(self, theEvent, kButton5); - vx->GetEventTranslator()->GenerateButtonReleaseEvent(self, theEvent, kButton5); - } else if (deltaY > 0) { - vx->GetEventTranslator()->GenerateButtonPressEvent(self, theEvent, kButton4); - vx->GetEventTranslator()->GenerateButtonReleaseEvent(self, theEvent, kButton4); - } -} - -//______________________________________________________________________________ -- (void) rightMouseDown : (NSEvent *) theEvent -{ - assert(fID != 0 && "rightMouseDown, fID is 0"); - - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != nullptr && "rightMouseDown, gVirtualX is either null or has type different from TGCocoa"); - vx->GetEventTranslator()->GenerateButtonPressEvent(self, theEvent, kButton3); -} - -//______________________________________________________________________________ -- (void) mouseUp : (NSEvent *) theEvent -{ - assert(fID != 0 && "mouseUp, fID is 0"); - - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx && "mouseUp, gVirtualX is either null or has type different from TGCocoa"); - vx->GetEventTranslator()->GenerateButtonReleaseEvent(self, theEvent, kButton1); -} - -//______________________________________________________________________________ -- (void) rightMouseUp : (NSEvent *) theEvent -{ - - assert(fID != 0 && "rightMouseUp, fID is 0"); - - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != nullptr && "rightMouseUp, gVirtualX is either null or has type different from TGCocoa"); - vx->GetEventTranslator()->GenerateButtonReleaseEvent(self, theEvent, kButton2); -} - -//______________________________________________________________________________ -- (void) mouseEntered : (NSEvent *) theEvent -{ - assert(fID != 0 && "mouseEntered, fID is 0"); - - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != nullptr && "mouseEntered, gVirtualX is null or not of TGCocoa type"); - - vx->GetEventTranslator()->GenerateCrossingEvent(self, theEvent); -} - -//______________________________________________________________________________ -- (void) mouseExited : (NSEvent *) theEvent -{ - assert(fID != 0 && "mouseExited, fID is 0"); - - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != nullptr && "mouseExited, gVirtualX is null or not of TGCocoa type"); - - vx->GetEventTranslator()->GenerateCrossingEvent(self, theEvent); -} - -//______________________________________________________________________________ -- (void) mouseMoved : (NSEvent *) theEvent -{ - assert(fID != 0 && "mouseMoved, fID is 0"); - - if (fParentView)//Suppress events in all views, except the top-level one. - return; - - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != nullptr && "mouseMoved, gVirtualX is null or not of TGCocoa type"); - - vx->GetEventTranslator()->GeneratePointerMotionEvent(self, theEvent); -} - -//______________________________________________________________________________ -- (void) mouseDragged : (NSEvent *) theEvent -{ - assert(fID != 0 && "mouseDragged, fID is 0"); - - //mouseMoved and mouseDragged work differently - //(drag events are generated only for one view, where drag started). - //if (fParentView) - // return; - - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != nullptr && "mouseMoved, gVirtualX is null or not of TGCocoa type"); - - vx->GetEventTranslator()->GeneratePointerMotionEvent(self, theEvent); -} - -//______________________________________________________________________________ -- (void) rightMouseDragged : (NSEvent *) theEvent -{ - assert(fID != 0 && "rightMouseDragged, fID is 0"); - - //mouseMoved and mouseDragged work differently - //(drag events are generated only for one view, where drag started). - //if (fParentView) - // return; - - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != nullptr && "rightMouseMoved, gVirtualX is null or not of TGCocoa type"); - - vx->GetEventTranslator()->GeneratePointerMotionEvent(self, theEvent); -} - -//______________________________________________________________________________ -- (void) keyDown : (NSEvent *) theEvent -{ - assert(fID != 0 && "keyDown, fID is 0"); - - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != nullptr && "keyDown, gVirtualX is null or not of TGCocoa type"); - vx->GetEventTranslator()->GenerateKeyPressEvent(self, theEvent); -} - -//______________________________________________________________________________ -- (void) keyUp:(NSEvent *)theEvent -{ - (void)theEvent; -} - -//First responder staff. - -//______________________________________________________________________________ -- (BOOL) acceptsFirstMouse : (NSEvent *)theEvent -{ - (void)theEvent; - return YES; -} - -//______________________________________________________________________________ -- (BOOL) acceptsFirstResponder -{ - return YES; -} - -//______________________________________________________________________________ -- (BOOL) becomeFirstResponder -{ - //Change focus. - NSView *focusView = nil; - for (NSView *view = self; view; view = view.fParentView) { - if (view.fEventMask & kFocusChangeMask) { - focusView = view; - break; - } - } - - if (!focusView) - focusView = ((QuartzWindow *)[self window]).fContentView; - - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != nullptr && "becomeFirstResponder, gVirtualX is null or not of TGCocoa type"); - vx->GetEventTranslator()->GenerateFocusChangeEvent(focusView); - - return YES; -} - -//______________________________________________________________________________ -- (BOOL) resignFirstResponder -{ - //Change focus. - //NSResponder returns YES, so do I. - return YES; -} - -//______________________________________________________________________________ -- (void) addPassiveKeyGrab : (unichar) keyCode modifiers : (NSUInteger) modifiers -{ - //Remove and add (not to traverse twice). - [self removePassiveKeyGrab : keyCode modifiers : modifiers]; - PassiveKeyGrab *newGrab = [[PassiveKeyGrab alloc] initWithKey : keyCode modifiers : modifiers]; - [fPassiveKeyGrabs addObject : newGrab]; - [newGrab release]; -} - -//______________________________________________________________________________ -- (void) removePassiveKeyGrab : (unichar) keyCode modifiers : (NSUInteger) modifiers -{ - const NSUInteger count = [fPassiveKeyGrabs count]; - for (NSUInteger i = 0; i < count; ++i) { - PassiveKeyGrab *grab = [fPassiveKeyGrabs objectAtIndex : i]; - if ([grab matchKey : keyCode modifiers : modifiers]) { - [fPassiveKeyGrabs removeObjectAtIndex : i]; - break; - } - } -} - -//______________________________________________________________________________ -- (PassiveKeyGrab *) findPassiveKeyGrab : (unichar) keyCode modifiers : (NSUInteger) modifiers -{ - NSEnumerator *enumerator = [fPassiveKeyGrabs objectEnumerator]; - while (PassiveKeyGrab *grab = (PassiveKeyGrab *)[enumerator nextObject]) { - if ([grab matchKey : keyCode modifiers : modifiers]) - return grab; - } - - return nil; -} - -//______________________________________________________________________________ -- (PassiveKeyGrab *) findPassiveKeyGrab : (unichar) keyCode -{ - //Do not check modifiers. - NSEnumerator *enumerator = [fPassiveKeyGrabs objectEnumerator]; - while (PassiveKeyGrab *grab = (PassiveKeyGrab *)[enumerator nextObject]) { - if ([grab matchKey : keyCode]) - return grab; - } - - return nil; -} - -#endif diff --git a/graf2d/cocoa/inc/TGCocoa.h b/graf2d/cocoa/inc/TGCocoa.h index 16540e704f0b7..ed662dd0d9b66 100644 --- a/graf2d/cocoa/inc/TGCocoa.h +++ b/graf2d/cocoa/inc/TGCocoa.h @@ -16,11 +16,18 @@ #include #include #include +#include #include +#ifndef ROOT_CocoaGuiTypes +#include "CocoaGuiTypes.h" +#endif #ifndef ROOT_TVirtualX #include "TVirtualX.h" #endif +#ifndef ROOT_X11Atoms +#include "X11Atoms.h" +#endif ////////////////////////////////////////////////////////////////////////// // // @@ -34,28 +41,13 @@ // // ////////////////////////////////////////////////////////////////////////// -namespace ROOT { -namespace Quartz { - -class CGStateGuard { -public: - CGStateGuard(void *ctx); - ~CGStateGuard(); - -private: - void *fCtx; - - CGStateGuard(const CGStateGuard &rhs); - CGStateGuard &operator = (const CGStateGuard &rhs); -}; - -} - +namespace ROOT { namespace MacOSX { namespace X11 { class EventTranslator; class CommandBuffer; + } namespace Details { @@ -78,20 +70,26 @@ class TGCocoa : public TVirtualX { /////////////////////////////////////// //General. virtual Bool_t Init(void *display); - virtual Int_t OpenDisplay(const char *dpyName); + virtual Int_t OpenDisplay(const char *displayName); virtual const char *DisplayName(const char *); + virtual Int_t SupportsExtension(const char *extensionName)const; virtual void CloseDisplay(); virtual Display_t GetDisplay()const; virtual Visual_t GetVisual()const; virtual Int_t GetScreen()const; + virtual UInt_t ScreenWidthMM()const; virtual Int_t GetDepth()const; virtual void Update(Int_t mode); + + //Non-virtual functions. + void ReconfigureDisplay(); + ROOT::MacOSX::X11::Rectangle GetDisplayGeometry()const; //End of general. /////////////////////////////////////// /////////////////////////////////////// //Window management part: - virtual Window_t GetDefaultRootWindow() const; + virtual Window_t GetDefaultRootWindow()const; //-Functions used by TCanvas/TPad (work with window, selected by SelectWindow). virtual Int_t InitWindow(ULong_t window); virtual Window_t GetWindowID(Int_t wid);//TGCocoa simply returns wid. @@ -102,12 +100,10 @@ class TGCocoa : public TVirtualX { virtual void RescaleWindow(Int_t wid, UInt_t w, UInt_t h); virtual void ResizeWindow(Int_t wid); virtual void UpdateWindow(Int_t mode); - virtual Window_t GetCurrentWindow() const; + virtual Window_t GetCurrentWindow()const; virtual void CloseWindow(); - - //-"Qt ROOT". - virtual Int_t AddWindow(ULong_t qwid, UInt_t w, UInt_t h); - virtual void RemoveWindow(ULong_t qwid); + virtual Int_t AddWindow(ULong_t qwid, UInt_t w, UInt_t h); //-"Qt ROOT". + virtual void RemoveWindow(ULong_t qwid); //-"Qt ROOT". //-Functions used by GUI. @@ -148,15 +144,29 @@ class TGCocoa : public TVirtualX { virtual void SetWindowBackground(Window_t wid, ULong_t color); virtual void SetWindowBackgroundPixmap(Window_t wid, Pixmap_t pxm); - virtual Window_t GetParent(Window_t wid) const; + virtual Window_t GetParent(Window_t wid)const; virtual void SetWindowName(Window_t wid, char *name); virtual void SetIconName(Window_t wid, char *name); virtual void SetIconPixmap(Window_t wid, Pixmap_t pix); virtual void SetClassHints(Window_t wid, char *className, char *resourceName); + //Non-rectangular window: + virtual void ShapeCombineMask(Window_t wid, Int_t x, Int_t y, Pixmap_t mask); + //End window-management part. /////////////////////////////////////// + ///////////////////////////// + //Set of "Window manager hints". + virtual void SetMWMHints(Window_t winID, UInt_t value, UInt_t decorators, UInt_t inputMode); + virtual void SetWMPosition(Window_t winID, Int_t x, Int_t y); + virtual void SetWMSize(Window_t winID, UInt_t w, UInt_t h); + virtual void SetWMSizeHints(Window_t winID, UInt_t wMin, UInt_t hMin, UInt_t wMax, UInt_t hMax, UInt_t wInc, UInt_t hInc); + virtual void SetWMState(Window_t winID, EInitialState state); + virtual void SetWMTransientHint(Window_t winID, Window_t mainWinID); + //"Window manager hints". + ///////////////////////////// + /////////////////////////////////////// //GUI-rendering part. @@ -208,6 +218,18 @@ class TGCocoa : public TVirtualX { //End of pixmap management. ///////////////////////////// + + ///////////////////////////// + //"Images" - emulation of XCreateImage/XPutImage etc. + virtual Drawable_t CreateImage(UInt_t width, UInt_t height); + virtual void GetImageSize(Drawable_t wid, UInt_t &width, UInt_t &height); + virtual void PutPixel(Drawable_t wid, Int_t x, Int_t y, ULong_t pixel); + virtual void PutImage(Drawable_t wid, GContext_t gc, Drawable_t img, Int_t dx, Int_t dy, + Int_t x, Int_t y, UInt_t w, UInt_t h); + virtual void DeleteImage(Drawable_t img); + //"Images". + ///////////////////////////// + ///////////////////////////// //Mouse (cursor, events, etc.) virtual void GrabButton(Window_t wid, EMouseButton button, UInt_t modifier, @@ -216,9 +238,20 @@ class TGCocoa : public TVirtualX { virtual void GrabPointer(Window_t wid, UInt_t evmask, Window_t confine, Cursor_t cursor, Bool_t grab = kTRUE, Bool_t owner_events = kTRUE); - + virtual void ChangeActivePointerGrab(Window_t, UInt_t, Cursor_t);//Noop. //End of mouse related part. ///////////////////////////// + + ///////////////////////////// + //Keyboard management. + virtual void SetKeyAutoRepeat(Bool_t on = kTRUE); + virtual void GrabKey(Window_t wid, Int_t keycode, UInt_t modifier, Bool_t grab = kTRUE); + virtual Int_t KeysymToKeycode(UInt_t keysym); + virtual Window_t GetInputFocus(); + virtual void SetInputFocus(Window_t wid); + virtual void LookupString(Event_t *event, char *buf, Int_t buflen, UInt_t &keysym); + //End of keyboard management. + ///////////////////////////// ///////////////////////////// //Font management. @@ -265,36 +298,87 @@ class TGCocoa : public TVirtualX { //Cursors. virtual Cursor_t CreateCursor(ECursor cursor); virtual void SetCursor(Window_t wid, Cursor_t curid); - virtual void SetCursor(Int_t win, ECursor cursor); + virtual void SetCursor(Int_t win, ECursor cursor); + virtual void QueryPointer(Int_t &x, Int_t &y); + virtual void QueryPointer(Window_t wid, Window_t &rootw, Window_t &childw, + Int_t &root_x, Int_t &root_y, Int_t &win_x, + Int_t &win_y, UInt_t &mask); //Cursors. ///////////////////////////// - //Remaining bunch of functions is not sorted yet (and not imlemented at the moment). + + ///////////////////////////// + //OpenGL. + virtual Double_t GetOpenGLScalingFactor(); + virtual Window_t CreateOpenGLWindow(Window_t parentID, UInt_t width, UInt_t height, const std::vector > &format); + virtual Handle_t CreateOpenGLContext(Window_t windowID, Handle_t sharedContext); + virtual void CreateOpenGLContext(Int_t wid); + virtual Bool_t MakeOpenGLContextCurrent(Handle_t ctx, Window_t windowID); + virtual Handle_t GetCurrentOpenGLContext(); + virtual void FlushOpenGLBuffer(Handle_t ctx); + + virtual void DeleteOpenGLContext(Int_t wid); + //OpenGL. + ///////////////////////////// + + ///////////////////////////// + //TPad's/TCanvas' specific - "double buffer" (off-screen rendering) + 'xor' mode. + virtual void SetDoubleBuffer(Int_t wid, Int_t mode); + virtual void SetDoubleBufferOFF(); + virtual void SetDoubleBufferON(); + virtual void SetDrawMode(EDrawMode mode); + //TPad's/TCanvas'. + ///////////////////////////// + + ///////////////////////////// + //Event management. + virtual void SendEvent(Window_t wid, Event_t *ev); + virtual void NextEvent(Event_t &event); + virtual Int_t EventsPending(); + virtual Bool_t CheckEvent(Window_t wid, EGEventType type, Event_t &ev); + virtual Handle_t GetNativeEvent() const; + //Event management. + ///////////////////////////// + + ///////////////////////////// + //"Drag and drop" and "Copy and paste" (quotes are intentional :)). + + //Names here are total mess, but this comes from TVirtualX interface. + virtual Atom_t InternAtom(const char *atom_name, Bool_t only_if_exist); + + virtual void SetPrimarySelectionOwner(Window_t wid); + virtual Bool_t SetSelectionOwner(Window_t windowID, Atom_t &selectionID); + virtual Window_t GetPrimarySelectionOwner(); + + virtual void ConvertPrimarySelection(Window_t wid, Atom_t clipboard, Time_t when); + virtual void ConvertSelection(Window_t, Atom_t&, Atom_t&, Atom_t&, Time_t&); + virtual Int_t GetProperty(Window_t, Atom_t, Long_t, Long_t, Bool_t, Atom_t, + Atom_t*, Int_t*, ULong_t*, ULong_t*, unsigned char**); + virtual void GetPasteBuffer(Window_t wid, Atom_t atom, TString &text, Int_t &nchar, + Bool_t del); virtual void ChangeProperty(Window_t wid, Atom_t property, Atom_t type, UChar_t *data, Int_t len); + virtual void ChangeProperties(Window_t wid, Atom_t property, Atom_t type, + Int_t format, UChar_t *data, Int_t len); + virtual void DeleteProperty(Window_t, Atom_t&); - //Set of "Window manager hints". - virtual void SetMWMHints(Window_t wid, UInt_t value, UInt_t funcs, UInt_t input); - virtual void SetWMPosition(Window_t wid, Int_t x, Int_t y); - virtual void SetWMSize(Window_t wid, UInt_t w, UInt_t h); - virtual void SetWMSizeHints(Window_t wid, UInt_t wmin, UInt_t hmin, - UInt_t wmax, UInt_t hmax, UInt_t winc, UInt_t hinc); - virtual void SetWMState(Window_t wid, EInitialState state); - virtual void SetWMTransientHint(Window_t wid, Window_t main_id); + virtual void SetDNDAware(Window_t, Atom_t *); + virtual Bool_t IsDNDAware(Window_t win, Atom_t *typelist); - virtual void CreateOpenGLContext(Int_t wid); - virtual void DeleteOpenGLContext(Int_t wid); + virtual void SetTypeList(Window_t win, Atom_t prop, Atom_t *typelist); + //FindRWindow is in DND part, since it looks for a DND aware window. + virtual Window_t FindRWindow(Window_t win, Window_t dragwin, Window_t input, int x, int y, int maxd); + //"Drag and drop" and "Copy and paste". + ///////////////////////////// + + //The remaining bunch of functions is not sorted yet (and not imlemented at the moment). virtual UInt_t ExecCommand(TGWin32Command *code); virtual void GetCharacterUp(Float_t &chupx, Float_t &chupy); virtual Int_t GetDoubleBuffer(Int_t wid); - virtual Handle_t GetNativeEvent() const; - - - virtual void QueryPointer(Int_t &ix, Int_t &iy); virtual Pixmap_t ReadGIF(Int_t x0, Int_t y0, const char *file, Window_t wid); virtual Int_t RequestLocator(Int_t mode, Int_t ctyp, Int_t &x, Int_t &y); virtual Int_t RequestString(Int_t x, Int_t y, char *text); @@ -302,10 +386,6 @@ class TGCocoa : public TVirtualX { virtual void SetCharacterUp(Float_t chupx, Float_t chupy); virtual void SetClipOFF(Int_t wid); virtual void SetClipRegion(Int_t wid, Int_t x, Int_t y, UInt_t w, UInt_t h); - virtual void SetDoubleBuffer(Int_t wid, Int_t mode); - virtual void SetDoubleBufferOFF(); - virtual void SetDoubleBufferON(); - virtual void SetDrawMode(EDrawMode mode); virtual void SetTextMagnitude(Float_t mgn); @@ -313,14 +393,10 @@ class TGCocoa : public TVirtualX { virtual void Warp(Int_t ix, Int_t iy, Window_t wid); virtual Int_t WriteGIF(char *name); virtual void WritePixmap(Int_t wid, UInt_t w, UInt_t h, char *pxname); - virtual Int_t SupportsExtension(const char *ext) const; virtual Bool_t NeedRedraw(ULong_t tgwindow, Bool_t force); - virtual UInt_t ScreenWidthMM() const; - virtual Atom_t InternAtom(const char *atom_name, Bool_t only_if_exist); - virtual Bool_t CreatePictureFromFile(Drawable_t wid, const char *filename, Pixmap_t &pict, Pixmap_t &pict_mask, PictureAttributes_t &attr); @@ -330,29 +406,12 @@ class TGCocoa : public TVirtualX { virtual Bool_t ReadPictureDataFromFile(const char *filename, char ***ret_data); virtual void DeletePictureData(void *data); virtual void SetDashes(GContext_t gc, Int_t offset, const char *dash_list, Int_t n); - virtual Int_t EventsPending(); - virtual void NextEvent(Event_t &event); + + virtual void Bell(Int_t percent); - virtual Bool_t CheckEvent(Window_t wid, EGEventType type, Event_t &ev); - virtual void SendEvent(Window_t wid, Event_t *ev); - virtual void DispatchClientMessage(UInt_t messageID); - virtual void RemoveEventsForWindow(Window_t wid); virtual void WMDeleteNotify(Window_t wid); - virtual void SetKeyAutoRepeat(Bool_t on = kTRUE); - virtual void GrabKey(Window_t wid, Int_t keycode, UInt_t modifier, Bool_t grab = kTRUE); - virtual Int_t KeysymToKeycode(UInt_t keysym); - virtual Window_t GetInputFocus(); - virtual void SetInputFocus(Window_t wid); - virtual Window_t GetPrimarySelectionOwner(); - virtual void SetPrimarySelectionOwner(Window_t wid); - virtual void ConvertPrimarySelection(Window_t wid, Atom_t clipboard, Time_t when); - virtual void LookupString(Event_t *event, char *buf, Int_t buflen, UInt_t &keysym); - virtual void GetPasteBuffer(Window_t wid, Atom_t atom, TString &text, Int_t &nchar, - Bool_t del); - virtual void QueryPointer(Window_t wid, Window_t &rootw, Window_t &childw, - Int_t &root_x, Int_t &root_y, Int_t &win_x, - Int_t &win_y, UInt_t &mask); + virtual void SetClipRectangles(GContext_t gc, Int_t x, Int_t y, Rectangle_t *recs, Int_t n); virtual Region_t CreateRegion(); virtual void DestroyRegion(Region_t reg); @@ -366,31 +425,9 @@ class TGCocoa : public TVirtualX { virtual Bool_t PointInRegion(Int_t x, Int_t y, Region_t reg); virtual Bool_t EqualRegion(Region_t rega, Region_t regb); virtual void GetRegionBox(Region_t reg, Rectangle_t *rect); - virtual Drawable_t CreateImage(UInt_t width, UInt_t height); - virtual void GetImageSize(Drawable_t wid, UInt_t &width, UInt_t &height); - virtual void PutPixel(Drawable_t wid, Int_t x, Int_t y, ULong_t pixel); - virtual void PutImage(Drawable_t wid, GContext_t gc, Drawable_t img, Int_t dx, Int_t dy, - Int_t x, Int_t y, UInt_t w, UInt_t h); - virtual void DeleteImage(Drawable_t img); - virtual void ShapeCombineMask(Window_t wid, Int_t x, Int_t y, Pixmap_t mask); + // - //---- Drag and Drop ----- - virtual void DeleteProperty(Window_t, Atom_t&); - virtual Int_t GetProperty(Window_t, Atom_t, Long_t, Long_t, Bool_t, Atom_t, - Atom_t*, Int_t*, ULong_t*, ULong_t*, unsigned char**); - virtual void ChangeActivePointerGrab(Window_t, UInt_t, Cursor_t); - virtual void ConvertSelection(Window_t, Atom_t&, Atom_t&, Atom_t&, Time_t&); - virtual Bool_t SetSelectionOwner(Window_t, Atom_t&); - virtual void ChangeProperties(Window_t wid, Atom_t property, Atom_t type, - Int_t format, UChar_t *data, Int_t len); - virtual void SetDNDAware(Window_t, Atom_t *); - virtual void SetTypeList(Window_t win, Atom_t prop, Atom_t *typelist); - virtual Window_t FindRWindow(Window_t win, Window_t dragwin, Window_t input, int x, int y, int maxd); - virtual Bool_t IsDNDAware(Window_t win, Atom_t *typelist); - - virtual void BeginModalSessionFor(Window_t wid); - - virtual Bool_t IsCmdThread() const { return kTRUE; } + virtual Bool_t IsCmdThread()const { return kTRUE; } //Non virtual, non-overriding functions. ROOT::MacOSX::X11::EventTranslator *GetEventTranslator()const; @@ -403,44 +440,37 @@ class TGCocoa : public TVirtualX { protected: void *GetCurrentContext(); - Int_t fSelectedDrawable; + Drawable_t fSelectedDrawable; std::auto_ptr fPimpl; //! Int_t fCocoaDraw; EDrawMode fDrawMode; bool fDirectDraw;//Primitive in canvas tries to draw into window directly. - - //TODO: - //There is no property support yet, - //only this two valus to make GUI work - //(used in client messages). - -public: - - enum EInternAtom { - kIA_DELETE_WINDOW = 1, - kIA_ROOT_MESSAGE - }; private: - bool IsDialog(Window_t wid)const; bool MakeProcessForeground(); + Atom_t FindAtom(const std::string &atomName, bool addIfNotFound); + void SetApplicationIcon(); bool fForegroundProcess; - std::vector fX11Contexts; + std::vector fX11Contexts; + // + ROOT::MacOSX::X11::name_to_atom_map fNameToAtom; + std::vector fAtomToName; - typedef std::pair ClientMessage_t; - std::vector fFreeMessageIDs; - UInt_t fCurrentMessageID; - std::map fClientMessages; - typedef std::map::iterator message_iterator; + std::map fSelectionOwners; + typedef std::map::iterator selection_iterator; - //Quite ugly solution for the moment. - std::map > fClientMessagesToWindow; - typedef std::map >::iterator message_window_iterator; - - //I'd prefere to use = delete syntax from C++0x11, but this file is processed by CINT. + bool fSetApp; + mutable bool fDisplayShapeChanged; + mutable ROOT::MacOSX::X11::Rectangle fDisplayRect; + +public: + static Atom_t fgDeleteWindowAtom; + +private: + //I'd prefer to use = delete syntax from C++0x11, but this file is processed by CINT. TGCocoa(const TGCocoa &rhs); TGCocoa &operator = (const TGCocoa &rhs); diff --git a/graf2d/cocoa/inc/TGQuartz.h b/graf2d/cocoa/inc/TGQuartz.h index 49109d37e02db..ac13955ba7b3f 100644 --- a/graf2d/cocoa/inc/TGQuartz.h +++ b/graf2d/cocoa/inc/TGQuartz.h @@ -9,13 +9,20 @@ * For the list of contributors see $ROOTSYS/README/CREDITS. * *************************************************************************/ - #ifndef ROOT_TGQuartz #define ROOT_TGQuartz +#include + #ifndef ROOT_TGCocoa #include "TGCocoa.h" #endif +#ifndef ROOT_TPoint +#include "TPoint.h" +#endif +#ifndef ROOT_TTF +#include "TTF.h" +#endif ////////////////////////////////////////////////////////////////////////// // // @@ -23,7 +30,13 @@ // MacOS X, using CoreGraphics (Quartz). // // // ////////////////////////////////////////////////////////////////////////// + class TGQuartz : public TGCocoa { +private: + enum EAlign {kNone, kTLeft, kTCenter, kTRight, kMLeft, + kMCenter, kMRight, kBLeft, kBCenter, kBRight}; + + FT_Vector fAlign; // alignment vector public: TGQuartz(); TGQuartz(const char *name, const char *title); @@ -35,14 +48,20 @@ class TGQuartz : public TGCocoa { Int_t nx, Int_t ny, Int_t *ic); virtual void DrawFillArea(Int_t n, TPoint *xy); - using TGCocoa::DrawLine; + using TGCocoa::DrawLine;//There is a GUI version of DrawLine. virtual void DrawLine(Int_t x1, Int_t y1, Int_t x2, Int_t y2); virtual void DrawPolyLine(Int_t n, TPoint *xy); virtual void DrawPolyMarker(Int_t n, TPoint *xy); virtual void DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, - const char *text, ETextMode mode); + const char *text, ETextMode mode); + virtual void DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, + const wchar_t *text, ETextMode mode); + //I have to override these setters, since they are alredy overriden + //in TVirtualX (originally, they are declared in TAttXXX classes) + //and do nothing in TVirtualX (though, they are implemented + //correctly in TAttXXX classes). virtual void SetFillColor(Color_t cindex); virtual void SetFillStyle(Style_t style); virtual void SetLineColor(Color_t cindex); @@ -58,19 +77,29 @@ class TGQuartz : public TGCocoa { virtual Int_t SetTextFont(char *fontname, ETextSetMode mode); virtual void SetTextSize(Float_t textsize); - virtual void GetTextExtent(UInt_t &w, UInt_t &h, char *mess); + virtual void GetTextExtent(UInt_t &w, UInt_t &h, char *text); virtual Int_t GetFontAscent() const; virtual Int_t GetFontDescent() const ; virtual Float_t GetTextMagnitude(); private: - Bool_t SetContextFillColor(Int_t ci); - Bool_t SetContextStrokeColor(Int_t ci); + + //Unfortunately, I have to convert from + //top-left to bottom-left corner system. + std::vector fConvertedPoints; + + void AlignTTFString(); + Bool_t IsTTFStringVisible(Int_t x, Int_t y, UInt_t w, UInt_t h); + void RenderTTFString(Int_t x, Int_t y, ETextMode mode); + //I have to use void * instead of QuartzPixmap * because of CINT :( + void DrawFTGlyphIntoPixmap(void *pixmap, FT_Bitmap *source, ULong_t fore, ULong_t back, Int_t bx, Int_t by); + + void *GetSelectedDrawableChecked(const char *calledFrom) const; TGQuartz(const TGQuartz &rhs); TGQuartz &operator = (const TGQuartz &rhs); - ClassDef(TGQuartz, 0);//2D graphics for Mac OSX. + ClassDef(TGQuartz, 0);//2D non-GUI graphics for Mac OSX. }; #endif diff --git a/graf2d/cocoa/inc/X11Atoms.h b/graf2d/cocoa/inc/X11Atoms.h new file mode 100644 index 0000000000000..e4ca790ce2846 --- /dev/null +++ b/graf2d/cocoa/inc/X11Atoms.h @@ -0,0 +1,24 @@ +#ifndef ROOT_X11Atoms +#define ROOT_X11Atoms + +#include +#include +#include + +#ifndef ROOT_GuiTypes +#include "GuiTypes.h" +#endif + +namespace ROOT { +namespace MacOSX { +namespace X11 { + +typedef std::map name_to_atom_map; + +void InitWithPredefinedAtoms(name_to_atom_map &nameToAtom, std::vector &atomNames); + +} +} +} + +#endif diff --git a/graf2d/cocoa/inc/X11Buffer.h b/graf2d/cocoa/inc/X11Buffer.h index c2e0ea8cf77fb..fb301869d03a3 100644 --- a/graf2d/cocoa/inc/X11Buffer.h +++ b/graf2d/cocoa/inc/X11Buffer.h @@ -15,6 +15,11 @@ #include #include +#include + +#ifndef ROOT_CocoaGuiTypes +#include "CocoaGuiTypes.h" +#endif #ifndef ROOT_GuiTypes #include "GuiTypes.h" #endif @@ -57,6 +62,7 @@ class Command { virtual bool IsGraphicsCommand()const;//By-default - false. virtual void Execute()const = 0; + virtual void Execute(CGContextRef /*ctx*/)const; private: Command(const Command &rhs); @@ -65,11 +71,11 @@ class Command { class DrawLine : public Command { private: - const Point_t fP1; - const Point_t fP2; + const Point fP1; + const Point fP2; public: - DrawLine(Drawable_t wid, const GCValues_t &gc, const Point_t &p1, const Point_t &p2); + DrawLine(Drawable_t wid, const GCValues_t &gc, const Point &p1, const Point &p2); void Execute()const; bool IsGraphicsCommand()const { @@ -92,7 +98,7 @@ class DrawSegments : public Command { class ClearArea : public Command { private: - const Rectangle_t fArea; + const Rectangle_t fArea;//to be replaced with X11::Rectangle public: ClearArea(Window_t wid, const Rectangle_t &area); @@ -106,11 +112,11 @@ class ClearArea : public Command { class CopyArea : public Command { private: const Drawable_t fSrc; - const Rectangle_t fArea; - const Point_t fDstPoint; + const Rectangle_t fArea;//to be replaced with X11::Rectangle + const Point fDstPoint; public: - CopyArea(Drawable_t src, Drawable_t dst, const GCValues_t &gc, const Rectangle_t &area, const Point_t &dstPoint); + CopyArea(Drawable_t src, Drawable_t dst, const GCValues_t &gc, const Rectangle_t &area, const Point &dstPoint); bool HasOperand(Drawable_t drawable)const; bool IsGraphicsCommand()const @@ -124,11 +130,11 @@ class CopyArea : public Command { class DrawString : public Command { private: - const Point_t fPoint; + const Point fPoint; const std::string fText; public: - DrawString(Drawable_t wid, const GCValues_t &gc, const Point_t &point, const std::string &text); + DrawString(Drawable_t wid, const GCValues_t &gc, const Point &point, const std::string &text); bool IsGraphicsCommand()const { @@ -140,7 +146,7 @@ class DrawString : public Command { class FillRectangle : public Command { private: - const Rectangle_t fRectangle; + const Rectangle_t fRectangle;//to be replaced with X11::Rectangle public: FillRectangle(Drawable_t wid, const GCValues_t &gc, const Rectangle_t &rectangle); @@ -170,7 +176,7 @@ class FillPolygon : public Command { class DrawRectangle : public Command { private: - Rectangle_t fRectangle; + Rectangle_t fRectangle;//to be replaced with X11::Rectangle public: DrawRectangle(Drawable_t wid, const GCValues_t &gc, const Rectangle_t &rectangle); @@ -204,13 +210,40 @@ class DeletePixmap : public Command { void Execute()const; }; +//Set of 'xor' operations, required by TCanvas and ExecuteEvent's machinery. +class DrawBoxXor : public Command { +private: + Point fP1; + Point fP2; + +public: + DrawBoxXor(Window_t windowID, const Point &p1, const Point &p2); + + void Execute()const; + void Execute(CGContextRef ctx)const; +}; + +class DrawLineXor : public Command { +private: + Point fP1; + Point fP2; + +public: + DrawLineXor(Window_t windowID, const Point &p1, const Point &p2); + + void Execute()const; + void Execute(CGContextRef ctx)const; +}; + class CommandBuffer { private: CommandBuffer(const CommandBuffer &rhs); CommandBuffer &operator = (const CommandBuffer &rhs); std::vector fCommands; + std::vector fViewBranch; + std::vector fXorOps; public: typedef std::vector::size_type size_type; @@ -227,10 +260,16 @@ class CommandBuffer { void AddDrawRectangle(Drawable_t wid, const GCValues_t &gc, Int_t x, Int_t y, UInt_t w, UInt_t h); void AddUpdateWindow(QuartzView *view); void AddDeletePixmap(Pixmap_t pixmap); + + //'XOR' graphics for canvas. + void AddDrawBoxXor(Window_t windowID, Int_t x1, Int_t y1, Int_t x2, Int_t y2); + void AddDrawLineXor(Window_t windowID, Int_t x1, Int_t y1, Int_t x2, Int_t y2); void Flush(Details::CocoaPrivate *impl); + void FlushXOROps(Details::CocoaPrivate *impl); void RemoveOperationsForDrawable(Drawable_t wid); void RemoveGraphicsOperationsForWindow(Window_t wid); + void RemoveXORGraphicsOperationsForWindow(Window_t wid); size_type BufferSize()const { @@ -238,6 +277,35 @@ class CommandBuffer { } private: void ClearCommands(); + void ClearXOROperations(); + + //Clip related stuff. + + struct WidgetRect { + int fX1; + int fY1; + int fX2; + int fY2; + + WidgetRect() + : fX1(0), fY1(0), fX2(0), fY2(0) + { + } + + WidgetRect(int leftX, int bottomY, int rightX, int topY) + : fX1(leftX), fY1(bottomY), fX2(rightX), fY2(topY) + { + } + }; + + void ClipOverlaps(QuartzView *view); + void BuildClipRegion(const WidgetRect &rect); + + std::vector fRectsToClip; + std::vector fClippedRegion; + std::vector fXBounds; + std::vector fYBounds; + std::vector fGrid; }; }//X11 diff --git a/graf2d/cocoa/inc/X11Drawable.h b/graf2d/cocoa/inc/X11Drawable.h index f245f225beae3..0f5a0a498bf39 100644 --- a/graf2d/cocoa/inc/X11Drawable.h +++ b/graf2d/cocoa/inc/X11Drawable.h @@ -12,10 +12,17 @@ #ifndef ROOT_X11Drawable #define ROOT_X11Drawable -#import +#include -#import "TVirtualX.h" -#import "GuiTypes.h" +#ifndef ROOT_CocoaGuiTypes +#include "CocoaGuiTypes.h" +#endif +#ifndef ROOT_TVirtualX +#include "TVirtualX.h" +#endif +#ifndef ROOT_GuiTypes +#include "GuiTypes.h" +#endif @class PassiveKeyGrab; @class QuartzWindow; @@ -52,12 +59,11 @@ - (unsigned) fHeight; //Functions to copy one drawable into another. -//Point_t, Rectangle_t are in GuiTypes.h -- (void) copy : (NSObject *) src area : (Rectangle_t) area withMask : (QuartzImage *)mask - clipOrigin : (Point_t) origin toPoint : (Point_t) dstPoint; +- (void) copy : (NSObject *) src area : (ROOT::MacOSX::X11::Rectangle) area withMask : (QuartzImage *)mask + clipOrigin : (ROOT::MacOSX::X11::Point) origin toPoint : (ROOT::MacOSX::X11::Point) dstPoint; //Get access to pixel data. -- (unsigned char *) readColorBits : (Rectangle_t) area; +- (unsigned char *) readColorBits : (ROOT::MacOSX::X11::Rectangle) area; @end @@ -83,17 +89,18 @@ @property (nonatomic, assign) int fBitGravity; @property (nonatomic, assign) int fWinGravity; @property (nonatomic, assign) unsigned long fBackgroundPixel;//Used by TGCocoa::ClearArea. +@property (nonatomic, retain) QuartzImage *fBackgroundPixmap;//Hmm, image, pixmap ... @property (nonatomic, readonly) int fMapState; +@property (nonatomic, assign) BOOL fOverrideRedirect; //End of SetWindowAttributes_t/WindowAttributes_t ///////////////////////////////////////////////////////////////// //"Back buffer" is a bitmap, used by canvas window (only). -@property (nonatomic, assign) QuartzPixmap *fBackBuffer; +@property (nonatomic, retain) QuartzPixmap *fBackBuffer; //Parent view can be only QuartzView. @property (nonatomic, assign) QuartzView *fParentView; -@property (nonatomic, assign) unsigned fLevel;//Window's "level" in a hierarchy. //Window has a content view, self is a content view for a view. //I NSView is a parent for QuartzView and ROOTOpenGLView. @property (nonatomic, readonly) NSView *fContentView; @@ -103,10 +110,20 @@ //ROOT's GUI does not use several passive button //grabs on the same window, so no containers, //just one grab. -@property (nonatomic, assign) int fGrabButton; -@property (nonatomic, assign) unsigned fGrabButtonEventMask; -@property (nonatomic, assign) unsigned fGrabKeyModifiers; -@property (nonatomic, assign) BOOL fOwnerEvents; +@property (nonatomic, assign) int fPassiveGrabButton; +@property (nonatomic, assign) unsigned fPassiveGrabEventMask; +@property (nonatomic, assign) unsigned fPassiveGrabKeyModifiers; + +@property (nonatomic, assign) unsigned fActiveGrabEventMask; + +@property (nonatomic, assign) BOOL fPassiveGrabOwnerEvents; + +- (void) activatePassiveGrab; +- (void) activateImplicitGrab; +- (void) activateGrab : (unsigned) eventMask ownerEvents : (BOOL) ownerEvents; +- (void) cancelGrab; + +- (BOOL) acceptsCrossingEvents : (unsigned) eventMask; //Nested views ("windows"). //Child can be any view, inherited @@ -127,7 +144,6 @@ - (BOOL) fIsOverlapped; - (void) setOverlapped : (BOOL) overlap; -- (void) updateLevel : (unsigned) newLevel; - (void) configureNotifyTree; - (void) addPassiveKeyGrab : (unichar) keyCode modifiers : (NSUInteger) modifiers; @@ -138,6 +154,16 @@ //Cursors. @property (nonatomic, assign) ECursor fCurrentCursor; +@property (nonatomic, assign) BOOL fIsDNDAware; + +//"Properties" (X11 properties) +- (void) setProperty : (const char *) propName data : (unsigned char *) propData size : (unsigned) dataSize + forType : (Atom_t) dataType format : (unsigned) format; +- (BOOL) hasProperty : (const char *) propName; +- (unsigned char *) getProperty : (const char *) propName returnType : (Atom_t *) type + returnFormat : (unsigned *) format nElements : (unsigned *) nElements; +- (void) removeProperty : (const char *) propName; + @end #endif diff --git a/graf2d/cocoa/inc/X11Events.h b/graf2d/cocoa/inc/X11Events.h index 7c8463b121da0..08705d7d40c15 100644 --- a/graf2d/cocoa/inc/X11Events.h +++ b/graf2d/cocoa/inc/X11Events.h @@ -1,9 +1,18 @@ -//Author: Timur Pocheptsov 16/02/2012 +// @(#)root/graf2d:$Id$ +// Author: Timur Pocheptsov 16/02/2012 + +/************************************************************************* + * Copyright (C) 1995-2012, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ #ifndef ROOT_X11Events #define ROOT_X11Events -#include +#include #ifndef ROOT_GuiTypes #include "GuiTypes.h" @@ -18,6 +27,8 @@ // // ////////////////////////////////////////////////////////////////////////// +class TGCocoa; + @protocol X11Window; @class QuartzWindow; @@ -28,13 +39,6 @@ namespace ROOT { namespace MacOSX { namespace X11 {//X11 emulation for Cocoa. -enum Ancestry { - kAView1IsParent, - kAView2IsParent, - kAHaveNonRootAncestor, - kAAncestorIsRoot -}; - enum PointerGrab { kPGNoGrab, kPGImplicitGrab, @@ -42,8 +46,10 @@ enum PointerGrab { kPGPassiveGrab }; -class EventTranslator { +typedef std::deque EventQueue_t; +class EventTranslator { + friend class ::TGCocoa; public: EventTranslator(); @@ -51,8 +57,8 @@ class EventTranslator { void GenerateDestroyNotify(unsigned winID); void GenerateExposeEvent(NSView *view, const NSRect &exposedRect); - void GenerateCrossingEvent(NSView *viewUnderPointer, NSEvent *theEvent); - void GeneratePointerMotionEvent(NSView *eventView, NSEvent *theEvent); + void GenerateCrossingEvent(NSEvent *theEvent); + void GeneratePointerMotionEvent(NSEvent *theEvent); //TODO: instead of passing EMouseButton, use info from NSEvent??? void GenerateButtonPressEvent(NSView *eventView, NSEvent *theEvent, EMouseButton btn); @@ -80,11 +86,11 @@ class EventTranslator { private: //Used both by grab and non-grab case. - void GenerateCrossingEvent(NSView *viewUnderPointer, NSEvent *theEvent, EXMagic detail); - void GenerateCrossingEventActiveGrab(NSView *eventView, NSEvent *theEvent); + void GenerateCrossingEventNoGrab(NSEvent *theEvent); + void GenerateCrossingEventActiveGrab(NSEvent *theEvent); - void GeneratePointerMotionEventNoGrab(NSView *view, NSEvent *theEvent); - void GeneratePointerMotionEventActiveGrab(NSView *eventView, NSEvent *theEvent); + void GeneratePointerMotionEventNoGrab(NSEvent *theEvent); + void GeneratePointerMotionEventActiveGrab(NSEvent *theEvent); void GenerateButtonPressEventNoGrab(NSView *view, NSEvent *theEvent, EMouseButton btn); void GenerateButtonPressEventActiveGrab(NSView *view, NSEvent *theEvent, EMouseButton btn); @@ -98,19 +104,12 @@ class EventTranslator { void GenerateKeyEventActiveGrab(NSEvent *theEvent);//Both press/release events. void GenerateKeyEventForView(NSView *view, NSEvent *theEvent);//Both press/release events. - void FindButtonGrabView(NSView *fromView, NSEvent *theEvent, EMouseButton btn); + void FindButtonGrab(NSView *fromView, NSEvent *theEvent, EMouseButton btn); void FindKeyGrabView(NSView *fromView, NSEvent *theEvent); - NSView *FindViewUnderPointer(); - - Ancestry FindRelation(NSView *view1, NSView *view2, NSView **lca); - void SortTopLevelWindows(); - QuartzWindow *FindTopLevelWindowForMouseEvent(); NSView *fViewUnderPointer; - std::vector *> fBranch1; - std::vector *> fBranch2; - PointerGrab fPointerGrab; + PointerGrab fPointerGrabType; unsigned fGrabEventMask; bool fOwnerEvents; @@ -118,14 +117,17 @@ class EventTranslator { NSView *fButtonGrabView; NSView *fKeyGrabView; NSView *fFocusView; - - std::vector fWindowStack; + EMouseButton fImplicitGrabButton; + + EventQueue_t fEventQueue; }; void MapUnicharToKeySym(unichar key, char *buf, Int_t len, UInt_t &rootKeySym); Int_t MapKeySymToKeyCode(Int_t keySym); NSUInteger GetCocoaKeyModifiersFromROOTKeyModifiers(UInt_t rootKeyModifiers); +UInt_t GetModifiers();//Mouse buttons + keyboard modifiers. + }//X11 }//MacOSX }//ROOT diff --git a/graf2d/cocoa/inc/XLFDParser.h b/graf2d/cocoa/inc/XLFDParser.h index d740c9fb0ab8d..dff671cf9e1df 100644 --- a/graf2d/cocoa/inc/XLFDParser.h +++ b/graf2d/cocoa/inc/XLFDParser.h @@ -25,16 +25,19 @@ namespace MacOSX { namespace X11 {//X11 emulation. enum FontSlant { + kFSAny, //For '*' wildcard in xlfd string. kFSRegular, kFSItalic }; enum FontWeight { + kFWAny, //For '*' wildcard in xlfd string. kFWMedium, kFWBold }; struct XLFDName { + XLFDName(); //foundry * std::string fFamilyName; FontWeight fWeight; diff --git a/graf2d/cocoa/src/CocoaGuiTypes.mm b/graf2d/cocoa/src/CocoaGuiTypes.mm new file mode 100644 index 0000000000000..fdefdd1d5ef61 --- /dev/null +++ b/graf2d/cocoa/src/CocoaGuiTypes.mm @@ -0,0 +1,33 @@ +#include "CocoaGuiTypes.h" + +namespace ROOT { +namespace MacOSX { +namespace X11 { + +//______________________________________________________________________________ +Point::Point() + : fX(0), fY(0) +{ +} + +//______________________________________________________________________________ +Point::Point(int x, int y) + : fX(x), fY(y) +{ +} + +//______________________________________________________________________________ +Rectangle::Rectangle() + : fX(0), fY(0), fWidth(0), fHeight(0) +{ +} + +//______________________________________________________________________________ +Rectangle::Rectangle(int x, int y, unsigned w, unsigned h) + : fX(x), fY(y), fWidth(w), fHeight(h) +{ +} + +}//X11 +}//MacOSX +}//ROOT diff --git a/graf2d/cocoa/src/CocoaPrivate.mm b/graf2d/cocoa/src/CocoaPrivate.mm index cd006d8e66be7..ff02f84a465df 100644 --- a/graf2d/cocoa/src/CocoaPrivate.mm +++ b/graf2d/cocoa/src/CocoaPrivate.mm @@ -20,8 +20,11 @@ #include #include +#include #include +#include "ROOTApplicationDelegate.h" +#include "ROOTOpenGLView.h" #include "CocoaPrivate.h" #include "QuartzWindow.h" #include "CocoaUtils.h" @@ -32,8 +35,10 @@ //______________________________________________________________________________ CocoaPrivate::CocoaPrivate() - : fCurrentDrawableID(GetRootWindowID() + 1)//Any real window has id > rootID. - //0 is also used by some X11 functions as None. + : fCurrentDrawableID(GetRootWindowID() + 1), //Any real window has id > rootID. + //0 is also used by some X11 functions as None. + fFreeGLContextID(1), + fApplicationDelegate([[ROOTApplicationDelegate alloc] init]) { //Init NSApplication, if it was not done yet. Util::AutoreleasePool pool; @@ -46,7 +51,7 @@ } //______________________________________________________________________________ -int CocoaPrivate::GetRootWindowID()const +Window_t CocoaPrivate::GetRootWindowID()const { //First I had root ID == 0, but this is None in X11 and //it can be used by ROOT, for example, I had trouble with @@ -55,16 +60,20 @@ } //______________________________________________________________________________ -bool CocoaPrivate::IsRootWindow(int wid)const +bool CocoaPrivate::IsRootWindow(Window_t windowID)const { - return wid == GetRootWindowID(); + return windowID == GetRootWindowID(); } //______________________________________________________________________________ -unsigned CocoaPrivate::RegisterDrawable(NSObject *nsObj) +Drawable_t CocoaPrivate::RegisterDrawable(NSObject *nsObj) { //Return integer identifier for a new "drawable" (like in X11) - unsigned newID = fCurrentDrawableID; + + if (fCurrentDrawableID == 999)//I have to skip this, many thanks to ROOT who uses 999 as "all windows". + ++fCurrentDrawableID; + + Drawable_t newID = fCurrentDrawableID; if (fFreeDrawableIDs.size()) { newID = fFreeDrawableIDs.back(); @@ -73,22 +82,21 @@ fCurrentDrawableID++; assert(fDrawables.find(newID) == fDrawables.end() && "RegisterDrawable, id for new drawable is still in use"); - fDrawables[newID] = nsObj; return newID; } //______________________________________________________________________________ -NSObject *CocoaPrivate::GetDrawable(unsigned drawableID)const +NSObject *CocoaPrivate::GetDrawable(Drawable_t drawableID)const { const_drawable_iterator drawableIter = fDrawables.find(drawableID); #ifdef DEBUG_ROOT_COCOA if (drawableIter == fDrawables.end()) { - NSLog(@"Fatal error: requested non-existing drawable %u", drawableID); + NSLog(@"Fatal error: requested non-existing drawable %lu", drawableID); //We do not care about efficiency, ROOT's gonna die on assert :) - std::vector::const_iterator deletedDrawable = std::find(fFreeDrawableIDs.begin(), fFreeDrawableIDs.end(), drawableID); + std::vector::const_iterator deletedDrawable = std::find(fFreeDrawableIDs.begin(), fFreeDrawableIDs.end(), drawableID); if (deletedDrawable != fFreeDrawableIDs.end()) { NSLog(@"This drawable was deleted already"); } else { @@ -101,14 +109,14 @@ } //______________________________________________________________________________ -NSObject *CocoaPrivate::GetWindow(unsigned windowID)const +NSObject *CocoaPrivate::GetWindow(Window_t windowID)const { const_drawable_iterator winIter = fDrawables.find(windowID); #ifdef DEBUG_ROOT_COCOA if (winIter == fDrawables.end()) { - NSLog(@"Fatal error: requested non-existing drawable %u", windowID); + NSLog(@"Fatal error: requested non-existing drawable %lu", windowID); //We do not care about efficiency, ROOT's gonna die on assert :) - std::vector::const_iterator deletedDrawable = std::find(fFreeDrawableIDs.begin(), fFreeDrawableIDs.end(), windowID); + std::vector::const_iterator deletedDrawable = std::find(fFreeDrawableIDs.begin(), fFreeDrawableIDs.end(), windowID); if (deletedDrawable != fFreeDrawableIDs.end()) { NSLog(@"This window was deleted already"); } else { @@ -121,23 +129,23 @@ } //______________________________________________________________________________ -void CocoaPrivate::DeleteDrawable(unsigned drawableID) +void CocoaPrivate::DeleteDrawable(Drawable_t drawableID) { drawable_iterator drawableIter = fDrawables.find(drawableID); assert(drawableIter != fDrawables.end() && "DeleteDrawable, non existing drawableID"); //Probably, I'll need some additional cleanup here later. Now just delete NSObject and //reuse its id. - NSObject *base = drawableIter->second.Get(); + NSObject * const base = drawableIter->second.Get(); if ([base isKindOfClass : [QuartzView class]]) { [(QuartzView *)base removeFromSuperview]; ((QuartzView *)base).fParentView = nil; } else if ([base isKindOfClass : [QuartzWindow class]]) { QuartzWindow *qw = (QuartzWindow *)base; - [qw.fContentView removeFromSuperview]; qw.fContentView.fParentView = nil; + [qw.fContentView removeFromSuperview]; qw.contentView = nil; - + qw.fIsDeleted = YES; //Remove transient windows? /* const Util::NSScopeGuard children([[qw childWindows] copy]); @@ -158,7 +166,72 @@ } //______________________________________________________________________________ -void CocoaPrivate::ReplaceDrawable(unsigned drawableID, NSObject *nsObj) +Handle_t CocoaPrivate::RegisterGLContext(NSOpenGLContext *glContext) +{ + assert(fGLContextToHandle.find(glContext) == fGLContextToHandle.end() && "RegisterGLContext, context was registered already"); + + //Strong es-guarantee guarantee - if we have an exception, everything is rolled-back. + + bool contextInserted = false; + try { + fHandleToGLContext[fFreeGLContextID] = glContext; + contextInserted = true; + fGLContextToHandle[glContext] = fFreeGLContextID; + } catch (const std::exception &) {//bad alloc in one of two insertions. + if (contextInserted) + fHandleToGLContext.erase(fHandleToGLContext.find(fFreeGLContextID)); + throw; + } + + return fFreeGLContextID++; +} + +//______________________________________________________________________________ +void CocoaPrivate::DeleteGLContext(Handle_t contextID) +{ + assert(fHandleToGLContext.find(contextID) != fHandleToGLContext.end() && "DeleteGLContext, bad context id"); + + handle2ctx_map::iterator h2cIt = fHandleToGLContext.find(contextID); + + ctx2handle_map::iterator c2hIt = fGLContextToHandle.find(h2cIt->second.Get()); + assert(c2hIt != fGLContextToHandle.end() && "DeleteGLContext, inconsistent context map"); + + fGLContextToHandle.erase(c2hIt); + fHandleToGLContext.erase(h2cIt);//RAII does work here. +} + +//______________________________________________________________________________ +NSOpenGLContext *CocoaPrivate::GetGLContextForHandle(Handle_t ctxID) +{ + if (fHandleToGLContext.find(ctxID) == fHandleToGLContext.end()) + return nil; + + return fHandleToGLContext[ctxID].Get(); +} + +//______________________________________________________________________________ +Handle_t CocoaPrivate::GetHandleForGLContext(NSOpenGLContext *glContext) +{ + if (fGLContextToHandle.find(glContext) == fGLContextToHandle.end()) + return Handle_t(); + + return fGLContextToHandle[glContext]; +} + +//______________________________________________________________________________ +void CocoaPrivate::SetFakeGLWindow(QuartzWindow *fakeWin) +{ + fFakeGLWindow.Reset(fakeWin); +} + +//______________________________________________________________________________ +QuartzWindow *CocoaPrivate::GetFakeGLWindow() +{ + return fFakeGLWindow.Get(); +} + +//______________________________________________________________________________ +void CocoaPrivate::ReplaceDrawable(Drawable_t drawableID, NSObject *nsObj) { drawable_iterator drawableIter = fDrawables.find(drawableID); assert(drawableIter != fDrawables.end() && "ReplaceDrawable, can not replace non existing drawable"); diff --git a/graf2d/cocoa/src/FontCache.mm b/graf2d/cocoa/src/FontCache.mm index 8e75b69c4bc98..896006a7c13e1 100644 --- a/graf2d/cocoa/src/FontCache.mm +++ b/graf2d/cocoa/src/FontCache.mm @@ -30,12 +30,14 @@ namespace { -//ROOT uses indices for fonts. -//Later, I'll find (I promise! ;) better -//way to map font indices to actual fonts -//(families, etc.) - I simply do not have any time now. +//ROOT uses indices for fonts. Indices are in the range [1 .. 15], +//12 is a symbol font (quite special thing, see the code below, +//15 is a "symbol italic" font - shear transformation is applied. + +//TODO: actually, it's not good to assume I have these fonts for sure, +//find a better way to check the available fonts and search for the best +//match. -const int fmdNOfFonts = 13; const CFStringRef fixedFontNames[FontCache::nPadFonts] = { CFSTR("TimesNewRomanPS-ItalicMT"), @@ -50,14 +52,21 @@ CFSTR("Courier-Bold"), CFSTR("Courier-BoldOblique"), CFSTR("Symbol"), - CFSTR("TimesNewRomanPSMT") + CFSTR("TimesNewRomanPSMT"), + CFSTR("Wingdings"), + CFSTR("Symbol-Italic") }; //______________________________________________________________________________ -CTFontCollectionRef CreateFontCollection(const X11::XLFDName &xlfd) +CTFontCollectionRef CreateFontCollection(const X11::XLFDName &/*xlfd*/) { - CTFontCollectionRef ctCollection = 0; + CTFontCollectionRef ctCollection = CTFontCollectionCreateFromAvailableFonts(0); + if (!ctCollection) + ::Error("CreateFontCollection", "CTFontCollectionCreateFromAvailableFonts failed"); + + return ctCollection; +/* CTFontCollectionRef ctCollection = 0; if (xlfd.fFamilyName == "*") ctCollection = CTFontCollectionCreateFromAvailableFonts(0);//Select all available fonts. else { @@ -90,7 +99,7 @@ CTFontCollectionRef CreateFontCollection(const X11::XLFDName &xlfd) } - return ctCollection; + return ctCollection;*/ } //______________________________________________________________________________ @@ -115,6 +124,23 @@ void GetWeightAndSlant(CTFontDescriptorRef fontDescriptor, X11::XLFDName &newXLF //Let's ask for a weight and pixel size. const Util::CFScopeGuard traits((CFDictionaryRef)CTFontDescriptorCopyAttribute(fontDescriptor, kCTFontTraitsAttribute)); if (traits.Get()) { + if (CFNumberRef symbolTraits = (CFNumberRef)CFDictionaryGetValue(traits.Get(), kCTFontSymbolicTrait)) { + uint32_t val = 0; + CFNumberGetValue(symbolTraits, kCFNumberIntType, &val); + if (val & kCTFontItalicTrait) + newXLFD.fSlant = X11::kFSItalic; + else + newXLFD.fSlant = X11::kFSRegular; + + if (val & kCTFontBoldTrait) + newXLFD.fWeight = X11::kFWBold; + else + newXLFD.fWeight = X11::kFWMedium; + } + + /* + //The code below is wrong - using it, I can not identify bold or italic and always have + //only medium/regular. if(CFNumberRef weight = (CFNumberRef)CFDictionaryGetValue(traits.Get(), kCTFontWeightTrait)) { double val = 0.; if (CFNumberGetValue(weight, kCFNumberDoubleType, &val)) @@ -126,6 +152,7 @@ void GetWeightAndSlant(CTFontDescriptorRef fontDescriptor, X11::XLFDName &newXLF if (CFNumberGetValue(slant, kCFNumberDoubleType, &val)) newXLFD.fSlant = val > 0. ? X11::kFSItalic : X11::kFSRegular; } + */ } } @@ -156,7 +183,7 @@ void CreateXLFDString(const X11::XLFDName &xlfd, std::string &xlfdString) if (xlfd.fWeight == X11::kFWBold) xlfdString += "-bold"; else - xlfdString += "-*"; + xlfdString += "-normal"; if (xlfd.fSlant == X11::kFSItalic) xlfdString += "-i"; @@ -180,7 +207,12 @@ void CreateXLFDString(const X11::XLFDName &xlfd, std::string &xlfdString) //_________________________________________________________________ FontCache::FontCache() + : fSymbolFontRegistered(false) { + //XLFD name is not exactly PS name thus generating a warning with a new Core Text. + fXLFDtoPostscriptNames["helvetica"] = "Helvetica"; + fXLFDtoPostscriptNames["courier"] = "Courier"; + fXLFDtoPostscriptNames["times"] = "Times-Roman"; } //______________________________________________________________________________ @@ -188,8 +220,15 @@ void CreateXLFDString(const X11::XLFDName &xlfd, std::string &xlfdString) { using Util::CFScopeGuard; using Util::CFStrongReference; - + +#ifdef MAC_OS_X_VERSION_10_9 + PSNameMap_t::const_iterator nameIt = fXLFDtoPostscriptNames.find(xlfd.fFamilyName); + const std::string &psName = nameIt == fXLFDtoPostscriptNames.end() ? xlfd.fFamilyName : nameIt->second; + const CFScopeGuard fontName(CFStringCreateWithCString(kCFAllocatorDefault, psName.c_str(), kCFStringEncodingMacRoman)); +#else const CFScopeGuard fontName(CFStringCreateWithCString(kCFAllocatorDefault, xlfd.fFamilyName.c_str(), kCFStringEncodingMacRoman)); +#endif + const CFStrongReference baseFont(CTFontCreateWithName(fontName.Get(), xlfd.fPixelSize, 0), false);//false == do not retain if (!baseFont.Get()) { @@ -257,7 +296,7 @@ void CreateXLFDString(const X11::XLFDName &xlfd, std::string &xlfdString) std::vector xlfdData; std::vector familyName; - X11::XLFDName newXLFD = {}; + X11::XLFDName newXLFD; std::string xlfdString; const CFIndex nFonts = CFArrayGetCount(fonts.Get()); @@ -266,21 +305,29 @@ void CreateXLFDString(const X11::XLFDName &xlfd, std::string &xlfdString) if (!GetFamilyName(font, familyName)) continue; - //I do not check family name: if xlfd.fFamilyName is '*', all font names fit, - //if it's a special name - collection is created using this name. + + if (xlfd.fFamilyName != "*" && xlfd.fFamilyName != &familyName[0]) + continue; + newXLFD.fFamilyName = &familyName[0]; + + //If family name has '-', ROOT's GUI can not parse it correctly - + //'-' is a separator in XLFD. Just skip this font (anyway, it wan not requested by GUI, only + //listed by FontCache. + if (newXLFD.fFamilyName.find('-') != std::string::npos) + continue; GetWeightAndSlant(font, newXLFD); + //Check weight and slant. - if (newXLFD.fWeight != xlfd.fWeight) + if (xlfd.fWeight != X11::kFWAny && newXLFD.fWeight != xlfd.fWeight) continue; - if (newXLFD.fSlant != xlfd.fSlant) + if (xlfd.fSlant != X11::kFSAny && newXLFD.fSlant != xlfd.fSlant) continue; if (xlfd.fPixelSize) {//Size was requested. GetPixelSize(font, newXLFD); - //I do not think, that font has a pixel size. - //But Core Text supports different font sizes. + //Core Text supports different font sizes. if (!newXLFD.fPixelSize) newXLFD.fPixelSize = xlfd.fPixelSize; } @@ -365,12 +412,9 @@ void CreateXLFDString(const X11::XLFDName &xlfd, std::string &xlfdString) assert(fLoadedFonts.find(fontRef) != fLoadedFonts.end() && "Font was not created by font manager"); - //Instead of this, use CT funtion to request ascent/descent. try { - const Quartz::TextLine textLine("LALALA", fontRef); - textLine.GetAscentDescent(maxAscent, maxDescent); - maxAscent += 1; - maxDescent += 1; + maxAscent = int(CTFontGetAscent(fontRef) + 0.5) + 2; + maxDescent = int(CTFontGetDescent(fontRef) + 0.5); } catch (const std::exception &) { throw; } @@ -384,13 +428,12 @@ void CreateXLFDString(const X11::XLFDName &xlfd, std::string &xlfdString) if (fontIndex > nPadFonts || !fontIndex) { ::Warning("FontCache::SelectFont", "Font with index %d was requested", fontIndex); - fontIndex = 1; - } - - fontIndex -= 1; + fontIndex = 3;//Select the Helvetica as default. + } else + fontIndex -= 1; - if (fontIndex == 11)//Special case, our own symbol.ttf file. - return SelectSymbolFont(fontSize); + if (fontIndex == 11 || fontIndex == 14)//Special case, our own symbol.ttf file. + return SelectSymbolFont(fontSize, fontIndex); const UInt_t fixedSize = UInt_t(fontSize); font_map_iterator it = fFonts[fontIndex].find(fixedSize); @@ -415,19 +458,22 @@ void CreateXLFDString(const X11::XLFDName &xlfd, std::string &xlfdString) } //_________________________________________________________________ -CTFontRef FontCache::SelectSymbolFont(Float_t fontSize) +CTFontRef FontCache::SelectSymbolFont(Float_t fontSize, unsigned fontIndex) { + assert(fontIndex == 11 || fontIndex == 14 && "SelectSymbolFont, parameter fontIndex has invalid value"); + const UInt_t fixedSize = UInt_t(fontSize); - font_map_iterator it = fFonts[11].find(fixedSize);//In ROOT, 11 is a font from symbol.ttf. + font_map_iterator it = fFonts[fontIndex].find(fixedSize);//In ROOT, 11 is a font from symbol.ttf. - if (it == fFonts[11].end()) { + if (it == fFonts[fontIndex].end()) { //This GetValue + Which I took from Olivier's code. - const char *fontDirectoryPath = gEnv->GetValue("Root.TTFontPath","$(ROOTSYS)/fonts");//This one I do not own. - char *fontFileName = gSystem->Which(fontDirectoryPath, "symbol.ttf", kReadPermission);//This must be deleted. + const char * const fontDirectoryPath = gEnv->GetValue("Root.TTFontPath","$(ROOTSYS)/fonts");//This one I do not own. + char * const fontFileName = gSystem->Which(fontDirectoryPath, "symbol.ttf", kReadPermission);//This must be deleted. + + const Util::ScopedArray arrayGuard(fontFileName); if (!fontFileName || fontFileName[0] == 0) { - ::Error("FontCache::SelectSymbolFont", "sumbol.ttf file not found"); - delete [] fontFileName; + ::Error("FontCache::SelectSymbolFont", "symbol.ttf file not found"); return 0; } @@ -435,28 +481,45 @@ void CreateXLFDString(const X11::XLFDName &xlfd, std::string &xlfdString) const Util::CFScopeGuard path(CFStringCreateWithCString(kCFAllocatorDefault, fontFileName, kCFURLPOSIXPathStyle)); if (!path.Get()) { ::Error("FontCache::SelectSymbolFont", "CFStringCreateWithCString failed"); - delete [] fontFileName; return 0; } + + const Util::CFScopeGuard fontURL(CFURLCreateWithFileSystemPath(kCFAllocatorDefault, path.Get(), kCFURLPOSIXPathStyle, false)); + if (!fontURL.Get()) { + ::Error("FontCache::SelectSymbolFont", "CFURLCreateWithFileSystemPath failed"); + return 0; + } + + //Try to register this font. + if (!fSymbolFontRegistered) { + CFErrorRef err = 0; + fSymbolFontRegistered = CTFontManagerRegisterFontsForURL(fontURL.Get(), kCTFontManagerScopeProcess, &err); + if (!fSymbolFontRegistered) { + ::Error("FontCache::SelectSymbolFont", "CTFontManagerRegisterFontsForURL failed"); + if (err) + CFRelease(err); + return 0; + } + } - const Util::CFScopeGuard arr(CTFontManagerCreateFontDescriptorsFromURL(CFURLCreateWithFileSystemPath(kCFAllocatorDefault, path.Get(), kCFURLPOSIXPathStyle, false))); + const Util::CFScopeGuard arr(CTFontManagerCreateFontDescriptorsFromURL(fontURL.Get())); if (!arr.Get()) { ::Error("FontCache::SelectSymbolFont", "CTFontManagerCreateFontDescriptorsFromURL failed"); - delete [] fontFileName; return 0; } CTFontDescriptorRef fontDesc = (CTFontDescriptorRef)CFArrayGetValueAtIndex(arr.Get(), 0); - const CTFontGuard_t font(CTFontCreateWithFontDescriptor(fontDesc, fixedSize, 0), false); + + const CGAffineTransform shearMatrix = {1., 0., 0.26794, 1., 0., 0.};//Yes, these are hardcoded values, taken from TPDF class. + const CTFontGuard_t font(CTFontCreateWithFontDescriptorAndOptions(fontDesc, fixedSize, + fontIndex == 11 ? &CGAffineTransformIdentity : + &shearMatrix, kCTFontOptionsDefault), false); if (!font.Get()) { ::Error("FontCache::SelectSymbolFont", "CTFontCreateWithFontDescriptor failed"); - delete [] fontFileName; return 0; } - delete [] fontFileName; - - fFonts[11][fixedSize] = font;//This can throw. + fFonts[fontIndex][fixedSize] = font;//This can throw. return fSelectedFont = font.Get(); } catch (const std::exception &) {//Bad alloc. //RAII destructors should do their work. @@ -467,7 +530,6 @@ void CreateXLFDString(const X11::XLFDName &xlfd, std::string &xlfdString) return fSelectedFont = it->second.Get(); } - //_________________________________________________________________ void FontCache::GetTextBounds(UInt_t &w, UInt_t &h, const char *text)const { diff --git a/graf2d/cocoa/src/MenuLoader.mm b/graf2d/cocoa/src/MenuLoader.mm new file mode 100644 index 0000000000000..d2034d7ae1737 --- /dev/null +++ b/graf2d/cocoa/src/MenuLoader.mm @@ -0,0 +1,118 @@ +#include + +#include + +#include "MenuLoader.h" +#include "CocoaUtils.h" + +namespace ROOT { +namespace MacOSX { +namespace Details { + +//Fill ROOT's menu (standard Apple's menu at the top of desktop). +//This is a very preliminary version, to be updated/modified. + +void PopulateApplicationMenu(NSMenu *submenu); +void PopulateWindowMenu(NSMenu *submenu); +void PopulateHelpMenu(NSMenu *submenu); + +//Fill app's menu. + +//______________________________________________________________________________ +void PopulateMainMenu() +{ + const Util::AutoreleasePool pool; + + NSMenu * const mainMenu = [[NSMenu alloc] initWithTitle : @"NSMainMenu"]; + const Util::NSScopeGuard mainMenuGuard(mainMenu); + + // The strings in the menu bar come from the submenu titles, + // except for the application menu, whose title is ignored at runtime. + NSMenuItem *menuItem = [mainMenu addItemWithTitle : @"Apple" action : nil keyEquivalent:@""]; + NSMenu *submenu = [[NSMenu alloc] initWithTitle : @"Apple"]; + const Util::NSScopeGuard submenuGuard1(submenu); + + PopulateApplicationMenu(submenu); + [mainMenu setSubmenu : submenu forItem : menuItem]; + + menuItem = [mainMenu addItemWithTitle : @"Window" action : nil keyEquivalent : @""]; + submenu = [[NSMenu alloc] initWithTitle : NSLocalizedString(@"Window", @"The Window menu")]; + const Util::NSScopeGuard submenuGuard2(submenu); + PopulateWindowMenu(submenu); + [mainMenu setSubmenu : submenu forItem : menuItem]; + [NSApp setWindowsMenu : submenu]; + + menuItem = [mainMenu addItemWithTitle:@"Help" action:NULL keyEquivalent:@""]; + submenu = [[NSMenu alloc] initWithTitle:NSLocalizedString(@"Help", @"The Help menu")]; + const Util::NSScopeGuard submenuGuard3(submenu); + PopulateHelpMenu(submenu); + [mainMenu setSubmenu : submenu forItem : menuItem]; + + [NSApp setMainMenu : mainMenu]; + [NSMenu setMenuBarVisible : YES]; +} + +//______________________________________________________________________________ +void PopulateApplicationMenu(NSMenu *aMenu) +{ + assert(aMenu != nil && "PopulateApplicationMenu, aMenu parameter is nil"); + + NSString * const applicationName = @"root"; + + NSMenuItem *menuItem = [aMenu addItemWithTitle:[NSString stringWithFormat : @"%@ %@", NSLocalizedString(@"About", nil), applicationName] + action : @selector(orderFrontStandardAboutPanel:) keyEquivalent : @""]; + [menuItem setTarget : NSApp]; + [aMenu addItem : [NSMenuItem separatorItem]]; + /* + menuItem = [aMenu addItemWithTitle : NSLocalizedString(@"Preferences...", nil) action : nil keyEquivalent : @","]; + [aMenu addItem : [NSMenuItem separatorItem]]; + + menuItem = [aMenu addItemWithTitle : NSLocalizedString(@"Services", nil) action : nil keyEquivalent : @""]; + + + + + NSMenu * servicesMenu = [[NSMenu alloc] initWithTitle:@"Services"]; + [aMenu setSubmenu:servicesMenu forItem:menuItem]; + [NSApp setServicesMenu:servicesMenu]; + + [aMenu addItem:[NSMenuItem separatorItem]]; + */ + + menuItem = [aMenu addItemWithTitle:[NSString stringWithFormat:@"%@ %@", NSLocalizedString(@"Hide", nil), applicationName] action : @selector(hide:) keyEquivalent : @"h"]; + [menuItem setTarget : NSApp]; + + menuItem = [aMenu addItemWithTitle:NSLocalizedString(@"Hide Others", nil) action : @selector(hideOtherApplications:) keyEquivalent : @"h"]; + [menuItem setKeyEquivalentModifierMask : NSCommandKeyMask | NSAlternateKeyMask]; + [menuItem setTarget : NSApp]; + + menuItem = [aMenu addItemWithTitle:NSLocalizedString(@"Show All", nil) action : @selector(unhideAllApplications:) keyEquivalent : @""]; + [menuItem setTarget : NSApp]; + + [aMenu addItem : [NSMenuItem separatorItem]]; + //TODO: ROOTApplicationDelegate should implement the corresponding method to quit ROOT appropriately. + menuItem = [aMenu addItemWithTitle:[NSString stringWithFormat:@"%@ %@", NSLocalizedString(@"Quit", nil), applicationName] action : @selector(terminate:) keyEquivalent : @"q"]; + [menuItem setTarget : NSApp]; +} + +//______________________________________________________________________________ +void PopulateWindowMenu(NSMenu *aMenu) +{ + assert(aMenu != nil && "PopulateWindowMenu, aMenu parameter is nil"); + + NSMenuItem *menuItem = [aMenu addItemWithTitle : NSLocalizedString(@"Minimize", nil) action : @selector(performMinimize:) keyEquivalent : @"m"]; + menuItem = [aMenu addItemWithTitle : NSLocalizedString(@"Zoom", nil) action : @selector(performZoom:) keyEquivalent : @""]; + [aMenu addItem : [NSMenuItem separatorItem]]; + menuItem = [aMenu addItemWithTitle : NSLocalizedString(@"Bring All to Front", nil) action : @selector(arrangeInFront:) keyEquivalent : @""]; +} + +//______________________________________________________________________________ +void PopulateHelpMenu(NSMenu *aMenu) +{ + NSMenuItem * const menuItem = [aMenu addItemWithTitle : [NSString stringWithFormat:@"%@ %@", @"root", NSLocalizedString(@"Help", nil)] action : @selector(showHelp:) keyEquivalent : @"?"]; + [menuItem setTarget : NSApp]; +} + +}//Detail +}//MacOSX +}//ROOT diff --git a/graf2d/cocoa/src/QuartzPixmap.mm b/graf2d/cocoa/src/QuartzPixmap.mm index 0ded063ca30ec..359ede874c491 100644 --- a/graf2d/cocoa/src/QuartzPixmap.mm +++ b/graf2d/cocoa/src/QuartzPixmap.mm @@ -11,15 +11,19 @@ //#define NDEBUG -#import - -#import -#import -#import - -#import "QuartzWindow.h"//TODO: Move conversion functions from QuartzWindow to X11Coords or something like this. -#import "QuartzPixmap.h" -#import "X11Colors.h" +#include +#include +#include +#include +#include +#include + +#include "CocoaGuiTypes.h" +#include "QuartzWindow.h" +#include "QuartzPixmap.h" +#include "QuartzUtils.h" +#include "CocoaUtils.h" +#include "X11Colors.h" //Call backs for data provider. extern "C" { @@ -46,33 +50,38 @@ void ROOT_QuartzImage_ReleaseBytePointer(void *, const void *) } +namespace X11 = ROOT::MacOSX::X11; +namespace Util = ROOT::MacOSX::Util; +namespace Quartz = ROOT::Quartz; + @implementation QuartzPixmap { @private unsigned fWidth; unsigned fHeight; unsigned char *fData; CGContextRef fContext; + + unsigned fScaleFactor; } @synthesize fID; //______________________________________________________________________________ -- (id) initWithW : (unsigned) width H : (unsigned) height +- (id) initWithW : (unsigned) width H : (unsigned) height scaleFactor : (CGFloat) scaleFactor { if (self = [super init]) { fWidth = 0; fHeight = 0; fData = 0; + fContext = 0; - if ([self resizeW : width H : height]) - return self; + if (![self resizeW : width H : height scaleFactor : scaleFactor]) { + [self release]; + return nil; + } } - //Two step initialization: - //1. p = [QuartzPixmap alloc]; - //2. p1 = [p initWithW : w H : h]; - // if (!p1) [p release]; - return nil; + return self; } //______________________________________________________________________________ @@ -80,80 +89,89 @@ - (void) dealloc { if (fContext) CGContextRelease(fContext); - if (fData) - std::free(fData); + + delete [] fData; [super dealloc]; } //______________________________________________________________________________ -- (BOOL) resizeW : (unsigned) width H : (unsigned) height +- (BOOL) resizeW : (unsigned) width H : (unsigned) height scaleFactor : (CGFloat) scaleFactor { - assert(width > 0 && "Pixmap width must be positive"); - assert(height > 0 && "Pixmap height must be positive"); + assert(width > 0 && "resizeW:H:, Pixmap width must be positive"); + assert(height > 0 && "resizeW:H:, Pixmap height must be positive"); - unsigned char *memory = (unsigned char *)malloc(width * height * 4);//[0] - if (!memory) { - assert(0 && "resizeW:H:, malloc failed"); + fScaleFactor = unsigned(scaleFactor + 0.5); + + //Part, which does not change anything in a state: + unsigned char *memory = 0; + + const unsigned scaledW = width * fScaleFactor; + const unsigned scaledH = height * fScaleFactor; + + try { + memory = new unsigned char[scaledW * scaledH * 4]();//[0] + } catch (const std::bad_alloc &) { + NSLog(@"QuartzPixmap: -resizeW:H:, memory allocation failed"); return NO; } + + Util::ScopedArray arrayGuard(memory); - CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceRGB();//[1] - if (!colorSpace) { - assert(0 && "resizeW:H:, CGColorSpaceCreateDeviceRGB failed"); - std::free(memory); + const Util::CFScopeGuard colorSpace(CGColorSpaceCreateDeviceRGB());//[1] + if (!colorSpace.Get()) { + NSLog(@"QuartzPixmap: -resizeW:H:, CGColorSpaceCreateDeviceRGB failed"); return NO; } - // - CGContextRef ctx = CGBitmapContextCreateWithData(memory, width, height, 8, width * 4, colorSpace, kCGImageAlphaPremultipliedLast, NULL, 0); - if (!ctx) { - assert(0 && "resizeW:H:, CGBitmapContextCreateWidthData failed"); - CGColorSpaceRelease(colorSpace); - std::free(memory); + Util::CFScopeGuard ctx(CGBitmapContextCreateWithData(memory, scaledW, scaledH, 8, scaledW * 4, colorSpace.Get(), kCGImageAlphaPremultipliedLast, NULL, 0)); + if (!ctx.Get()) { + NSLog(@"QuartzPixmap: -resizeW:H:, CGBitmapContextCreateWithData failed"); return NO; } + + //Now, apply scaling. + + if (fScaleFactor > 1) + CGContextScaleCTM(ctx.Get(), fScaleFactor, fScaleFactor); + //All initializations are OK, now change the state: if (fContext) { //New context was created OK, we can release now the old one. CGContextRelease(fContext);//[2] } - - if (fData) { - //Release old memory. - std::free(fData); - } - //Size to be used later - to identify, - //if we really have to resize. + //Release old memory. + delete [] fData; + + //sizes, data. fWidth = width; fHeight = height; fData = memory; + + arrayGuard.Release(); - fContext = ctx;//[2] - - CGColorSpaceRelease(colorSpace);//[1] + fContext = ctx.Get();//[2] + ctx.Release();//Stop the ownership. return YES; - } //______________________________________________________________________________ - (CGImageRef) createImageFromPixmap { - Rectangle_t imageRect = {}; - imageRect.fX = 0; - imageRect.fY = 0; - imageRect.fWidth = fWidth; - imageRect.fHeight = fHeight; - - return [self createImageFromPixmap : imageRect]; + return [self createImageFromPixmap : X11::Rectangle(0, 0, fWidth, fHeight)]; } //______________________________________________________________________________ -- (CGImageRef) createImageFromPixmap : (Rectangle_t) cropArea +- (CGImageRef) createImageFromPixmap : (X11::Rectangle) cropArea { //Crop area must be valid and adjusted by caller. + + //This function is incorrect in a general case, it does not care about + //cropArea.fX and cropArea.fY, very sloppy implementation. + //TODO: either fix it or remove completely. + assert(cropArea.fX >= 0 && "createImageFromPixmap:, cropArea.fX is negative"); assert(cropArea.fY >= 0 && "createImageFromPixmap:, cropArea.fY is negative"); assert(cropArea.fWidth <= fWidth && "createImageFromPixmap:, bad cropArea.fWidth"); @@ -164,27 +182,27 @@ - (CGImageRef) createImageFromPixmap : (Rectangle_t) cropArea ROOT_QuartzImage_ReleaseBytePointer, ROOT_QuartzImage_GetBytesAtPosition, 0}; + const unsigned scaledW = fWidth * fScaleFactor; + const unsigned scaledH = fHeight * fScaleFactor; - CGDataProviderRef provider = CGDataProviderCreateDirect(fData, fWidth * fHeight * 4, &providerCallbacks); - if (!provider) { + + const Util::CFScopeGuard provider(CGDataProviderCreateDirect(fData, scaledW * scaledH * 4, &providerCallbacks)); + if (!provider.Get()) { NSLog(@"QuartzPixmap: -pixmapToImage, CGDataProviderCreateDirect failed"); return 0; } //RGB - this is only for TGCocoa::CreatePixmapFromData. - CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceRGB(); - if (!colorSpace) { + const Util::CFScopeGuard colorSpace(CGColorSpaceCreateDeviceRGB()); + if (!colorSpace.Get()) { NSLog(@"QuartzPixmap: -pixmapToImage, CGColorSpaceCreateDeviceRGB failed"); - CGDataProviderRelease(provider); return 0; } //8 bits per component, 32 bits per pixel, 4 bytes per pixel, kCGImageAlphaLast: //all values hardcoded for TGCocoa. - CGImageRef image = CGImageCreate(cropArea.fWidth, cropArea.fHeight, 8, 32, fWidth * 4, colorSpace, kCGImageAlphaPremultipliedLast, provider, 0, false, kCGRenderingIntentDefault); - CGColorSpaceRelease(colorSpace); - CGDataProviderRelease(provider); - + CGImageRef image = CGImageCreate(cropArea.fWidth * fScaleFactor, cropArea.fHeight * fScaleFactor, 8, 32, fWidth * 4 * fScaleFactor, colorSpace.Get(), kCGImageAlphaPremultipliedLast, provider.Get(), 0, false, kCGRenderingIntentDefault); + return image; } @@ -203,7 +221,8 @@ - (BOOL) fIsOpenGLWidget //______________________________________________________________________________ - (CGContextRef) fContext { - assert(fContext != 0 && "fContext, called for bad pixmap"); + assert(fContext != 0 && "fContext, called for bad pixmap"); + return fContext; } @@ -224,7 +243,7 @@ - (unsigned) fHeight } //______________________________________________________________________________ -- (void) copyImage : (QuartzImage *) srcImage area : (Rectangle_t) area withMask : (QuartzImage *) mask clipOrigin : (Point_t) clipXY toPoint : (Point_t) dstPoint +- (void) copyImage : (QuartzImage *) srcImage area : (X11::Rectangle) area withMask : (QuartzImage *) mask clipOrigin : (X11::Point) clipXY toPoint : (X11::Point) dstPoint { using namespace ROOT::MacOSX::X11; @@ -237,7 +256,7 @@ - (void) copyImage : (QuartzImage *) srcImage area : (Rectangle_t) area withMask return; } - CGImageRef subImage = 0; + CGImageRef subImage = 0;//RAII not really needed. bool needSubImage = false; if (area.fX || area.fY || area.fWidth != srcImage.fWidth || area.fHeight != srcImage.fHeight) { needSubImage = true; @@ -250,32 +269,26 @@ - (void) copyImage : (QuartzImage *) srcImage area : (Rectangle_t) area withMask subImage = srcImage.fImage; //Save context state. - CGContextSaveGState(fContext); - - CGContextTranslateCTM(fContext, 0., fHeight); - CGContextScaleCTM(fContext, 1., -1.); - + const Quartz::CGStateGuard stateGuard(fContext); if (mask) { assert(mask.fImage != nil && "copyImage:area:withMask:clipOrigin:toPoint, mask is not nil, but mask.fImage is nil"); assert(CGImageIsMask(mask.fImage) && "copyImage:area:withMask:clipOrigin:toPoint, mask.fImage is not a mask"); - clipXY.fY = LocalYROOTToCocoa(self, clipXY.fY + mask.fHeight); + clipXY.fY = LocalYROOTToCocoa(self, clipXY.fY + mask.fHeight);//TODO: fix the possible overflow? (though, who can have such images???) const CGRect clipRect = CGRectMake(clipXY.fX, clipXY.fY, mask.fWidth, mask.fHeight); CGContextClipToMask(fContext, clipRect, mask.fImage); } - dstPoint.fY = LocalYROOTToCocoa(self, dstPoint.fY + area.fHeight); + dstPoint.fY = LocalYROOTToCocoa(self, dstPoint.fY + area.fHeight);//TODO: fix the possible overflow? (though, who can have such images???) const CGRect imageRect = CGRectMake(dstPoint.fX, dstPoint.fY, area.fWidth, area.fHeight); CGContextDrawImage(fContext, imageRect, subImage); - //Restore context state. - CGContextRestoreGState(fContext); if (needSubImage) CGImageRelease(subImage); } //______________________________________________________________________________ -- (void) copyPixmap : (QuartzPixmap *) srcPixmap area : (Rectangle_t) area withMask : (QuartzImage *)mask clipOrigin : (Point_t) clipXY toPoint : (Point_t) dstPoint +- (void) copyPixmap : (QuartzPixmap *) srcPixmap area : (X11::Rectangle) area withMask : (QuartzImage *)mask clipOrigin : (X11::Point) clipXY toPoint : (X11::Point) dstPoint { using namespace ROOT::MacOSX::X11; @@ -286,35 +299,30 @@ - (void) copyPixmap : (QuartzPixmap *) srcPixmap area : (Rectangle_t) area withM return; } - CGImageRef image = [srcPixmap createImageFromPixmap : area]; - - if (!image) + const Util::CFScopeGuard image([srcPixmap createImageFromPixmap : area]); + if (!image.Get()) return; - - CGContextSaveGState(fContext); - CGContextTranslateCTM(fContext, 0., fHeight); - CGContextScaleCTM(fContext, 1., -1.); + + const Quartz::CGStateGuard stateGuard(fContext); if (mask) { assert(mask.fImage != nil && "copyPixmap:area:withMask:clipOrigin:toPoint, mask is not nil, but mask.fImage is nil"); assert(CGImageIsMask(mask.fImage) && "copyPixmap:area:withMask:clipOrigin:toPoint, mask.fImage is not a mask"); - clipXY.fY = LocalYROOTToCocoa(self, clipXY.fY + mask.fHeight); + clipXY.fY = LocalYROOTToCocoa(self, clipXY.fY + mask.fHeight);//TODO: fix the possible overflow? (though, who can have such images???) const CGRect clipRect = CGRectMake(clipXY.fX, clipXY.fY, mask.fWidth, mask.fHeight); CGContextClipToMask(fContext, clipRect, mask.fImage); } - dstPoint.fY = LocalYROOTToCocoa(self, dstPoint.fY + area.fHeight); + dstPoint.fY = LocalYROOTToCocoa(self, dstPoint.fY + area.fHeight);//TODO: fix the possible overflow? (though, who can have such images???) const CGRect imageRect = CGRectMake(dstPoint.fX, dstPoint.fY, area.fWidth, area.fHeight); - CGContextDrawImage(fContext, imageRect, image); - //Restore context state. - CGContextRestoreGState(fContext); - - CGImageRelease(image); + CGContextDrawImage(fContext, imageRect, image.Get()); } //______________________________________________________________________________ -- (void) copy : (NSObject *) src area : (Rectangle_t) area withMask : (QuartzImage *)mask clipOrigin : (Point_t) origin toPoint : (Point_t) dstPoint +- (void) copy : (NSObject *) src area : (X11::Rectangle) area withMask : (QuartzImage *)mask clipOrigin : (X11::Point) origin toPoint : (X11::Point) dstPoint { + assert(area.fWidth && area.fHeight && "copy:area:widthMask:clipOrigin:toPoint, empty area to copy"); + if ([src isKindOfClass : [QuartzImage class]]) { [self copyImage : (QuartzImage *)src area : area withMask : mask clipOrigin : origin toPoint : dstPoint]; } else if ([src isKindOfClass : [QuartzPixmap class]]) { @@ -323,12 +331,124 @@ - (void) copy : (NSObject *) src area : (Rectangle_t) area withMask assert(0 && "Can copy only from pixmap or image"); } +//______________________________________________________________________________ +- (unsigned char *) readColorBits : (X11::Rectangle) area +{ + assert(area.fWidth && area.fHeight && "readColorBits:, empty area to copy"); + + if (!X11::AdjustCropArea(self, area)) { + NSLog(@"QuartzPixmap: readColorBits:intoBuffer:, src and copy area do not intersect"); + return 0; + } + + unsigned char *buffer = 0; + + try { + buffer = new unsigned char[area.fWidth * area.fHeight * 4](); + } catch (const std::bad_alloc &) { + NSLog(@"QuartzImage: -readColorBits:, memory allocation failed"); + return 0; + } + + + Util::NSScopeGuard scaledPixmap; + + if (fScaleFactor > 1) { + scaledPixmap.Reset([[QuartzPixmap alloc] initWithW : fWidth H : fHeight scaleFactor : 1.]); + //Ooops, all screwed up!!! + if (!scaledPixmap.Get()) { + NSLog(@"QuartzImage: -readColorBits:, can not create scaled pixmap"); + return buffer;//empty buffer. + } + + [scaledPixmap.Get() copy : self area : X11::Rectangle(0, 0, fWidth, fHeight) withMask : nil clipOrigin : X11::Point() toPoint : X11::Point()]; + } + + unsigned char *dstPixel = buffer; + + //fImageData has 4 bytes per pixel. + //TODO: possible overflows everywhere :( + const unsigned char *line = fScaleFactor == 1 ? fData + area.fY * fWidth * 4 + : scaledPixmap.Get()->fData + area.fY * fWidth * 4; + + const unsigned char *srcPixel = line + area.fX * 4; + + for (unsigned i = 0; i < area.fHeight; ++i) { + for (unsigned j = 0; j < area.fWidth; ++j, srcPixel += 4, dstPixel += 4) { + dstPixel[0] = srcPixel[0]; + dstPixel[1] = srcPixel[1]; + dstPixel[2] = srcPixel[2]; + dstPixel[3] = srcPixel[3]; + } + + line += fWidth * 4; + srcPixel = line + area.fX * 4; + } + + return buffer; +} + //______________________________________________________________________________ - (unsigned char *) fData { return fData; } +//______________________________________________________________________________ +- (void) putPixel : (const unsigned char *) rgb X : (unsigned) x Y : (unsigned) y +{ + //Primitive version of XPutPixel. + assert(rgb != 0 && "putPixel:X:Y:, rgb parameter is null"); + assert(x < fWidth && "putPixel:X:Y:, x parameter is >= self.fWidth"); + assert(y < fHeight && "putPixel:X:Y:, y parameter is >= self.fHeight"); + + if (fScaleFactor > 1) { + //Ooops, and what should I do now??? + const unsigned scaledW = fWidth * fScaleFactor; + unsigned char *dst = fData + y * fScaleFactor * scaledW * 4 + x * fScaleFactor * 4; + + for (unsigned i = 0; i < 2; ++i, dst += 4) { + dst[0] = rgb[0]; + dst[1] = rgb[1]; + dst[2] = rgb[2]; + dst[3] = 255; + } + + dst -= 8; + dst += scaledW * 4; + + for (unsigned i = 0; i < 2; ++i, dst += 4) { + dst[0] = rgb[0]; + dst[1] = rgb[1]; + dst[2] = rgb[2]; + dst[3] = 255; + } + } else { + unsigned char *dst = fData + y * fWidth * 4 + x * 4; + + dst[0] = rgb[0]; + dst[1] = rgb[1]; + dst[2] = rgb[2]; + dst[3] = 255; + } +} + +//______________________________________________________________________________ +- (void) addPixel : (const unsigned char *) rgb +{ + //Primitive version of XAddPixel. + assert(rgb != 0 && "addPixel:, rgb parameter is null"); + + for (unsigned i = 0; i < fHeight; ++i) { + for (unsigned j = 0; j < fWidth; ++j) { + fData[i * fWidth * 4 + j * 4] = rgb[0]; + fData[i * fWidth * 4 + j * 4 + 1] = rgb[1]; + fData[i * fWidth * 4 + j * 4 + 2] = rgb[2]; + fData[i * fWidth * 4 + j * 4 + 3] = rgb[3]; + } + } +} + @end @implementation QuartzImage { @@ -341,94 +461,270 @@ @implementation QuartzImage { @synthesize fIsStippleMask; @synthesize fID; +//TODO: all these "ctors" were added at different times, not from the beginnning. +//Refactor them to reduce code duplication, where possible. + //______________________________________________________________________________ -- (id) initWithW : (unsigned) width H : (unsigned) height data : (unsigned char *)data +- (id) initWithW : (unsigned) width H : (unsigned) height data : (unsigned char *) data { - //Two step initialization. If the second step (initWithW:....) fails, user must call release - //(after he checked the result of init call). - assert(width != 0 && "initWithW:H:data:, width parameter is 0"); assert(height != 0 && "initWithW:H:data:, height parameter is 0"); assert(data != 0 && "initWithW:H:data:, data parameter is null"); if (self = [super init]) { + Util::NSScopeGuard selfGuard(self); + + //This w * h * 4 is ONLY for TGCocoa::CreatePixmapFromData. + //If needed something else, I'll make this code more generic. + + unsigned char *dataCopy = 0; + try { + dataCopy = new unsigned char[width * height * 4](); + } catch (const std::bad_alloc &) { + NSLog(@"QuartzImage: -initWithW:H:data:, memory allocation failed"); + return nil; + } + + std::copy(data, data + width * height * 4, dataCopy); + Util::ScopedArray arrayGuard(dataCopy); + fIsStippleMask = NO; const CGDataProviderDirectCallbacks providerCallbacks = {0, ROOT_QuartzImage_GetBytePointer, ROOT_QuartzImage_ReleaseBytePointer, ROOT_QuartzImage_GetBytesAtPosition, 0}; - //This w * h * 4 is ONLY for TGCocoa::CreatePixmapFromData. - //If needed something else, I'll make this code more generic. - CGDataProviderRef provider = CGDataProviderCreateDirect(data, width * height * 4, &providerCallbacks); - if (!provider) { - NSLog(@"QuartzPixmap: -initWithW:H:data: CGDataProviderCreateDirect failed"); + const Util::CFScopeGuard provider(CGDataProviderCreateDirect(dataCopy, width * height * 4, &providerCallbacks)); + if (!provider.Get()) { + NSLog(@"QuartzImage: -initWithW:H:data: CGDataProviderCreateDirect failed"); return nil; } //RGB - this is only for TGCocoa::CreatePixmapFromData. - CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceRGB(); - if (!colorSpace) { - NSLog(@"QuartzPixmap: -initWithW:H:data: CGColorSpaceCreateDeviceRGB failed"); - CGDataProviderRelease(provider); + const Util::CFScopeGuard colorSpace(CGColorSpaceCreateDeviceRGB()); + if (!colorSpace.Get()) { + NSLog(@"QuartzImage: -initWithW:H:data: CGColorSpaceCreateDeviceRGB failed"); return nil; } - + //8 bits per component, 32 bits per pixel, 4 bytes per pixel, kCGImageAlphaLast: //all values hardcoded for TGCocoa::CreatePixmapFromData. - fImage = CGImageCreate(width, height, 8, 32, width * 4, colorSpace, kCGImageAlphaLast, provider, 0, false, kCGRenderingIntentDefault); - CGColorSpaceRelease(colorSpace); - CGDataProviderRelease(provider); + fImage = CGImageCreate(width, height, 8, 32, width * 4, colorSpace.Get(), kCGImageAlphaLast, provider.Get(), 0, false, kCGRenderingIntentDefault); if (!fImage) { - NSLog(@"QuartzPixmap: -initWithW:H:data: CGImageCreate failed"); + NSLog(@"QuartzImage: -initWithW:H:data: CGImageCreate failed"); return nil; } + selfGuard.Release(); + arrayGuard.Release(); + fWidth = width; fHeight = height; - - fImageData = data; - - return self; + fImageData = dataCopy; } - return nil; + return self; } //______________________________________________________________________________ -- (id) initMaskWithW : (unsigned) width H : (unsigned) height bitmapMask : (unsigned char *)mask +- (id) initMaskWithW : (unsigned) width H : (unsigned) height bitmapMask : (unsigned char *) mask { - assert(width > 0 && "initMaskWithW:H:bitmapMask:, width parameter is zero"); - assert(height > 0 && "initMaskWithW:H:bitmapMask:, height parameter is zero"); + assert(width != 0 && "initMaskWithW:H:bitmapMask:, width parameter is zero"); + assert(height != 0 && "initMaskWithW:H:bitmapMask:, height parameter is zero"); assert(mask != 0 && "initMaskWithW:H:bitmapMask:, mask parameter is null"); if (self = [super init]) { + Util::NSScopeGuard selfGuard(self); + + unsigned char *dataCopy = 0; + try { + dataCopy = new unsigned char[width * height](); + } catch (const std::bad_alloc &) { + NSLog(@"QuartzImage: -initMaskWithW:H:bitmapMask:, memory allocation failed"); + return nil; + } + + std::copy(mask, mask + width * height, dataCopy); + Util::ScopedArray arrayGuard(dataCopy); + fIsStippleMask = YES; const CGDataProviderDirectCallbacks providerCallbacks = {0, ROOT_QuartzImage_GetBytePointer, ROOT_QuartzImage_ReleaseBytePointer, ROOT_QuartzImage_GetBytesAtPosition, 0}; - CGDataProviderRef provider = CGDataProviderCreateDirect(mask, width * height, &providerCallbacks); - if (!provider) { - NSLog(@"QuartzPixmap: -initMaskWithW:H:bitmapMask: CGDataProviderCreateDirect failed"); + + + const Util::CFScopeGuard provider(CGDataProviderCreateDirect(dataCopy, width * height, &providerCallbacks)); + if (!provider.Get()) { + NSLog(@"QuartzImage: -initMaskWithW:H:bitmapMask: CGDataProviderCreateDirect failed"); + return nil; + } + + fImage = CGImageMaskCreate(width, height, 8, 8, width, provider.Get(), 0, false);//null -> decode, false -> shouldInterpolate. + if (!fImage) { + NSLog(@"QuartzImage: -initMaskWithW:H:bitmapMask:, CGImageMaskCreate failed"); + return nil; + } + + selfGuard.Release(); + arrayGuard.Release(); + + fWidth = width; + fHeight = height; + fImageData = dataCopy; + } + + return self; +} + +//______________________________________________________________________________ +- (id) initMaskWithW : (unsigned) width H : (unsigned) height +{ + //Two-step initialization. + + assert(width != 0 && "initMaskWithW:H:, width parameter is zero"); + assert(height != 0 && "initMaskWithW:H:, height parameter is zero"); + + if (self = [super init]) { + Util::NSScopeGuard selfGuard(self); + + try { + fImageData = new unsigned char[width * height](); + } catch (const std::bad_alloc &) { + NSLog(@"QuartzImage: -initMaskWithW:H:, memory allocation failed"); return nil; } - fImage = CGImageMaskCreate(width, height, 8, 8, width, provider, 0, false);//null -> decode, false -> shouldInterpolate. + fIsStippleMask = YES; + const CGDataProviderDirectCallbacks providerCallbacks = {0, ROOT_QuartzImage_GetBytePointer, + ROOT_QuartzImage_ReleaseBytePointer, + ROOT_QuartzImage_GetBytesAtPosition, 0}; + + const Util::CFScopeGuard provider(CGDataProviderCreateDirect(fImageData, width * height, &providerCallbacks)); + if (!provider.Get()) { + NSLog(@"QuartzImage: -initMaskWithW:H: CGDataProviderCreateDirect failed"); + return nil; + } + fImage = CGImageMaskCreate(width, height, 8, 8, width, provider.Get(), 0, false);//null -> decode, false -> shouldInterpolate. if (!fImage) { - NSLog(@"QuartzPixmap: -initMaskWithW:H:bitmapMask:, CGImageMaskCreate failed"); + NSLog(@"QuartzImage: -initMaskWithW:H:, CGImageMaskCreate failed"); return nil; } + selfGuard.Release(); + fWidth = width; fHeight = height; + } + + return self; +} + +//______________________________________________________________________________ +- (id) initFromPixmap : (QuartzPixmap *) pixmap +{ + //Two-step initialization. + assert(pixmap != nil && "initFromPixmap:, pixmap parameter is nil"); + assert(pixmap.fWidth != 0 && "initFromPixmap:, pixmap width is zero"); + assert(pixmap.fHeight != 0 && "initFromPixmap:, pixmap height is zero"); + + return [self initWithW : pixmap.fWidth H : pixmap.fHeight data : pixmap.fData]; +} + +//______________________________________________________________________________ +- (id) initFromImage : (QuartzImage *) image +{ + assert(image != nil && "initFromImage:, image parameter is nil"); + assert(image.fWidth != 0 && "initFromImage:, image width is 0"); + assert(image.fHeight != 0 && "initFromImage:, image height is 0"); + assert(image.fIsStippleMask == NO && "initFromImage:, image is a stipple mask, not implemented"); + + return [self initWithW : image.fWidth H : image.fHeight data : image->fImageData]; +} + +//______________________________________________________________________________ +- (id) initFromImageFlipped : (QuartzImage *) image +{ + assert(image != nil && "initFromImageFlipped:, image parameter is nil"); + assert(image.fWidth != 0 && "initFromImageFlipped:, image width is 0"); + assert(image.fHeight != 0 && "initFromImageFlipped:, image height is 0"); + + const unsigned bpp = image.fIsStippleMask ? 1 : 4; + + if (self = [super init]) { + const unsigned width = image.fWidth; + const unsigned height = image.fHeight; + + Util::NSScopeGuard selfGuard(self); + + unsigned char *dataCopy = 0; + try { + dataCopy = new unsigned char[width * height * bpp](); + } catch (const std::bad_alloc &) { + NSLog(@"QuartzImage: -initFromImageFlipped:, memory allocation failed"); + return nil; + } + + const unsigned lineSize = bpp * width; + for (unsigned i = 0; i < height; ++i) { + const unsigned char *sourceLine = image->fImageData + lineSize * (height - 1 - i); + unsigned char *dstLine = dataCopy + i * lineSize; + std::copy(sourceLine, sourceLine + lineSize, dstLine); + } + + Util::ScopedArray arrayGuard(dataCopy); + + const CGDataProviderDirectCallbacks providerCallbacks = {0, ROOT_QuartzImage_GetBytePointer, + ROOT_QuartzImage_ReleaseBytePointer, + ROOT_QuartzImage_GetBytesAtPosition, 0}; + + if (bpp == 1) { + fIsStippleMask = YES; + + const Util::CFScopeGuard provider(CGDataProviderCreateDirect(dataCopy, width * height, &providerCallbacks)); + if (!provider.Get()) { + NSLog(@"QuartzImage: -initFromImageFlipped:, CGDataProviderCreateDirect failed"); + return nil; + } - fImageData = mask; + fImage = CGImageMaskCreate(width, height, 8, 8, width, provider.Get(), 0, false);//null -> decode, false -> shouldInterpolate. + if (!fImage) { + NSLog(@"QuartzImage: -initFromImageFlipped:, CGImageMaskCreate failed"); + return nil; + } + } else { + fIsStippleMask = NO; + + const Util::CFScopeGuard provider(CGDataProviderCreateDirect(dataCopy, width * height * 4, &providerCallbacks)); + if (!provider.Get()) { + NSLog(@"QuartzImage: -initFromImageFlipped:, CGDataProviderCreateDirect failed"); + return nil; + } + + const Util::CFScopeGuard colorSpace(CGColorSpaceCreateDeviceRGB()); + if (!colorSpace.Get()) { + NSLog(@"QuartzImage: -initFromImageFlipped:, CGColorSpaceCreateDeviceRGB failed"); + return nil; + } + + //8 bits per component, 32 bits per pixel, 4 bytes per pixel, kCGImageAlphaLast: + //all values hardcoded for TGCocoa::CreatePixmapFromData. + fImage = CGImageCreate(width, height, 8, 32, width * 4, colorSpace.Get(), kCGImageAlphaLast, provider.Get(), 0, false, kCGRenderingIntentDefault); + if (!fImage) { + NSLog(@"QuartzImage: -initFromImageFlipped:, CGImageCreate failed"); + return nil; + } + } - return self; + selfGuard.Release(); + arrayGuard.Release(); + + fWidth = width; + fHeight = height; + fImageData = dataCopy; } - return nil; + return self; } //______________________________________________________________________________ @@ -443,7 +739,7 @@ - (void) dealloc } //______________________________________________________________________________ -- (BOOL) isRectInside : (Rectangle_t) area +- (BOOL) isRectInside : (X11::Rectangle) area { if (area.fX < 0 || (unsigned)area.fX >= fWidth) return NO; @@ -458,11 +754,19 @@ - (BOOL) isRectInside : (Rectangle_t) area } //______________________________________________________________________________ -- (unsigned char *) readColorBits : (Rectangle_t) area +- (unsigned char *) readColorBits : (X11::Rectangle) area { assert([self isRectInside : area] == YES && "readColorBits: bad area parameter"); //Image, bitmap - they all must be converted to ARGB (bitmap) or BGRA (image) (for libAfterImage). - unsigned char *buffer = new unsigned char[area.fWidth * area.fHeight * 4](); + unsigned char *buffer = 0; + + try { + buffer = new unsigned char[area.fWidth * area.fHeight * 4](); + } catch (const std::bad_alloc &) { + NSLog(@"QuartzImage: -readColorBits:, memory allocation failed"); + return 0; + } + unsigned char *dstPixel = buffer; if (CGImageIsMask(fImage)) { @@ -470,8 +774,8 @@ - (unsigned char *) readColorBits : (Rectangle_t) area const unsigned char *line = fImageData + area.fY * fWidth; const unsigned char *srcPixel = line + area.fX; - for (UShort_t i = 0; i < area.fHeight; ++i) { - for (UShort_t j = 0; j < area.fWidth; ++j, ++srcPixel, dstPixel += 4) { + for (unsigned i = 0; i < area.fHeight; ++i) { + for (unsigned j = 0; j < area.fWidth; ++j, ++srcPixel, dstPixel += 4) { if (!srcPixel[0]) dstPixel[0] = 255;//can be 1 or anything different from 0. } @@ -485,8 +789,8 @@ - (unsigned char *) readColorBits : (Rectangle_t) area const unsigned char *line = fImageData + area.fY * fWidth * 4; const unsigned char *srcPixel = line + area.fX * 4; - for (UShort_t i = 0; i < area.fHeight; ++i) { - for (UShort_t j = 0; j < area.fWidth; ++j, srcPixel += 4, dstPixel += 4) { + for (unsigned i = 0; i < area.fHeight; ++i) { + for (unsigned j = 0; j < area.fWidth; ++j, srcPixel += 4, dstPixel += 4) { dstPixel[0] = srcPixel[2]; dstPixel[1] = srcPixel[1]; dstPixel[2] = srcPixel[0]; @@ -540,7 +844,7 @@ - (CGImageRef) fImage namespace X11 { //______________________________________________________________________________ -CGImageRef CreateSubImage(QuartzImage *image, const Rectangle_t &area) +CGImageRef CreateSubImage(QuartzImage *image, const Rectangle &area) { assert(image != nil && "CreateSubImage, image parameter is nil"); @@ -548,61 +852,141 @@ CGImageRef CreateSubImage(QuartzImage *image, const Rectangle_t &area) return CGImageCreateWithImageInRect(image.fImage, subImageRect); } +namespace { + +//Now, close your eyes and open them at the end of this block. :) +//Sure, this can be done easy, but I hate to convert between negative signed integers and +//unsigned integers and the other way, so I have this implementation (integers will be always +//positive and they obviously fit into unsigned integers). + +typedef std::pair range_type; + +//______________________________________________________________________________ +bool FindOverlapSameSigns(const range_type &left, const range_type &right, range_type &intersection) +{ + //"Same" means both xs are non-negative, or both are negative. + //left.x <= right.x. + const unsigned dX(right.first - left.first);//diff fits into the positive range of int. + //No intersection. + if (dX >= left.second) + return false; + //Find an intersection. + intersection.first = right.first; + intersection.second = std::min(right.second, left.second - dX);//left.second is always > dX. + + return true; +} + //______________________________________________________________________________ -bool AdjustCropArea(const Rectangle_t &srcRect, Rectangle_t &cropArea) +bool FindOverlapDifferentSigns(const range_type &left, const range_type &right, range_type &intersection) { - //First, find cases, when srcRect and cropArea do not intersect. - if (cropArea.fX >= srcRect.fX + int(srcRect.fWidth)) - return false;//No intersection: crop on the right of source. - if (cropArea.fX + int(cropArea.fWidth) <= srcRect.fX) - return false;//No intersection: crop on the left of source. + //x2 - x1 can overflow. + //Left.x is negative, right.x is non-negative (0 included). + const unsigned signedMinAbs(std::numeric_limits::max() / 2 + 1); + + if (left.first == std::numeric_limits::min()) {//hehehe + if (left.second <= signedMinAbs) + return false; - if (cropArea.fY >= srcRect.fY + int(srcRect.fHeight)) - return false;//No intersection: crop is above the source. - if (cropArea.fY + int(cropArea.fHeight) <= srcRect.fY) - return false;//No intersection: crop is under the source. + if (left.second - signedMinAbs <= unsigned(right.first)) + return false; - //Intersection exists, set crop area to this intersection. - if (cropArea.fX < srcRect.fX) { - cropArea.fWidth = std::min(int(srcRect.fWidth), int(cropArea.fWidth) - int(srcRect.fX - cropArea.fX)); - cropArea.fX = srcRect.fX; - } else - cropArea.fWidth = std::min(srcRect.fWidth, cropArea.fWidth); + intersection.first = right.first; + intersection.second = std::min(right.second, left.second - signedMinAbs - unsigned(right.first)); + } else { + const unsigned leftXAbs(-left.first);//-left.first can't overflow. + if (leftXAbs >= left.second) + return false; - if (cropArea.fY < srcRect.fY) { - cropArea.fHeight = std::min(int(srcRect.fHeight), int(cropArea.fHeight) - int(srcRect.fY - cropArea.fY)); - cropArea.fY = srcRect.fY; - } else - cropArea.fHeight = std::min(srcRect.fHeight, cropArea.fHeight); + if (left.second - leftXAbs <= unsigned(right.first)) + return false; + + intersection.first = right.first; + intersection.second = std::min(right.second, left.second - leftXAbs - unsigned(right.first)); + } + + return true; +} + +//______________________________________________________________________________ +bool FindOverlap(const range_type &range1, const range_type &range2, range_type &intersection) +{ + range_type left; + range_type right; + + if (range1.first < range2.first) { + left = range1; + right = range2; + } else { + left = range2; + right = range1; + } + + if (left.first < 0) + return right.first < 0 ? FindOverlapSameSigns(left, right, intersection) : FindOverlapDifferentSigns(left, right, intersection); + + return FindOverlapSameSigns(left, right, intersection); +} + +} + +//______________________________________________________________________________ +bool AdjustCropArea(const Rectangle &srcRect, Rectangle &cropArea) +{ + //Find rects intersection. + range_type xIntersection; + if (!FindOverlap(range_type(srcRect.fX, srcRect.fWidth), range_type(cropArea.fX, cropArea.fWidth), xIntersection)) + return false; + + range_type yIntersection; + if (!FindOverlap(range_type(srcRect.fY, srcRect.fHeight), range_type(cropArea.fY, cropArea.fHeight), yIntersection)) + return false; + + cropArea.fX = xIntersection.first; + cropArea.fWidth = xIntersection.second; + + cropArea.fY = yIntersection.first; + cropArea.fHeight = yIntersection.second; return true; } //______________________________________________________________________________ -bool AdjustCropArea(QuartzImage *srcImage, Rectangle_t &cropArea) +bool AdjustCropArea(QuartzImage *srcImage, Rectangle &cropArea) { assert(srcImage != nil && "AdjustCropArea, srcImage parameter is nil"); assert(srcImage.fImage != nil && "AdjustCropArea, srcImage.fImage is nil"); + + return AdjustCropArea(X11::Rectangle(0, 0, srcImage.fWidth, srcImage.fHeight), cropArea); +} + +//______________________________________________________________________________ +bool AdjustCropArea(QuartzImage *srcImage, NSRect &cropArea) +{ + assert(srcImage != nil && "AdjustCropArea, srcImage parameter is nil"); + assert(srcImage.fImage != 0 && "AdjustCropArea, srcImage.fImage is null"); - Rectangle_t srcRect = {}; - srcRect.fX = 0, srcRect.fY = 0; - srcRect.fWidth = srcImage.fWidth; - srcRect.fHeight = srcImage.fHeight; + const Rectangle srcRect(0, 0, srcImage.fWidth, srcImage.fHeight); + Rectangle dstRect(int(cropArea.origin.x), int(cropArea.origin.y), unsigned(cropArea.size.width), unsigned(cropArea.size.height)); - return AdjustCropArea(srcRect, cropArea); + if (AdjustCropArea(srcRect, dstRect)) { + cropArea.origin.x = dstRect.fX; + cropArea.origin.y = dstRect.fY; + cropArea.size.width = dstRect.fWidth; + cropArea.size.height = dstRect.fHeight; + + return true; + } + + return false; } //______________________________________________________________________________ -bool AdjustCropArea(QuartzPixmap *srcPixmap, Rectangle_t &cropArea) +bool AdjustCropArea(QuartzPixmap *srcPixmap, X11::Rectangle &cropArea) { assert(srcPixmap != nil && "AdjustCropArea, srcPixmap parameter is nil"); - Rectangle_t srcRect = {}; - srcRect.fX = 0, srcRect.fY = 0; - srcRect.fWidth = srcPixmap.fWidth; - srcRect.fHeight = srcPixmap.fHeight; - - return AdjustCropArea(srcRect, cropArea); + return AdjustCropArea(X11::Rectangle(0, 0, srcPixmap.fWidth, srcPixmap.fHeight), cropArea); } //______________________________________________________________________________ @@ -632,9 +1016,9 @@ void FillPixmapBuffer(const unsigned char *bitmap, unsigned width, unsigned heig if (depth > 1) { unsigned char foregroundColor[4] = {}; - X11::PixelToRGB(foregroundPixel, foregroundColor); + PixelToRGB(foregroundPixel, foregroundColor); unsigned char backgroundColor[4] = {}; - X11::PixelToRGB(backgroundPixel, backgroundColor); + PixelToRGB(backgroundPixel, backgroundColor); for (unsigned j = 0; j < height; ++j) { const unsigned line = j * width * 4; @@ -669,6 +1053,6 @@ void FillPixmapBuffer(const unsigned char *bitmap, unsigned width, unsigned heig } } -} -} -} +}//X11 +}//MacOSX +}//ROOT diff --git a/graf2d/cocoa/src/QuartzWindow.mm b/graf2d/cocoa/src/QuartzWindow.mm index 53dbb09e35f1f..2763f626ec628 100644 --- a/graf2d/cocoa/src/QuartzWindow.mm +++ b/graf2d/cocoa/src/QuartzWindow.mm @@ -13,26 +13,29 @@ //#define NDEBUG -#include - #ifdef DEBUG_ROOT_COCOA -#import -#import +#include +#include -#import "TClass.h" +#include "TClass.h" #endif -#import -#import - -#import "QuartzWindow.h" -#import "QuartzPixmap.h" -#import "X11Buffer.h" -#import "X11Events.h" -#import "TGWindow.h" -#import "TGClient.h" -#import "TSystem.h" -#import "TGCocoa.h" +#include +#include +#include + +#include "ROOTOpenGLView.h" +#include "QuartzWindow.h" +#include "QuartzPixmap.h" +#include "QuartzUtils.h" +#include "CocoaUtils.h" +#include "X11Colors.h" +#include "X11Buffer.h" +#include "X11Events.h" +#include "TGWindow.h" +#include "TGClient.h" +#include "TSystem.h" +#include "TGCocoa.h" namespace ROOT { namespace MacOSX { @@ -43,15 +46,15 @@ UInt_t clss, void */*visual*/, SetWindowAttributes_t *attr, UInt_t) { NSRect winRect = {}; - winRect.origin.x = x; - winRect.origin.y = GlobalYROOTToCocoa(y); + winRect.origin.x = GlobalXROOTToCocoa(x); + winRect.origin.y = GlobalYROOTToCocoa(y + h); winRect.size.width = w; winRect.size.height = h; //TODO check mask. const NSUInteger styleMask = NSTitledWindowMask | NSClosableWindowMask | NSMiniaturizableWindowMask | NSResizableWindowMask; // - QuartzWindow *newWindow = [[QuartzWindow alloc] initWithContentRect : winRect styleMask : styleMask backing : NSBackingStoreBuffered defer : YES windowAttributes : attr]; + QuartzWindow * const newWindow = [[QuartzWindow alloc] initWithContentRect : winRect styleMask : styleMask backing : NSBackingStoreBuffered defer : YES windowAttributes : attr]; if (!newWindow) throw std::runtime_error("CreateTopLevelWindow failed"); // @@ -71,7 +74,7 @@ viewRect.size.width = w; viewRect.size.height = h; - QuartzView *view = [[QuartzView alloc] initWithFrame : viewRect windowAttributes : attr]; + QuartzView * const view = [[QuartzView alloc] initWithFrame : viewRect windowAttributes : attr]; if (!view) throw std::runtime_error("CreateChildView failed"); @@ -83,22 +86,24 @@ void GetRootWindowAttributes(WindowAttributes_t *attr) { //'root' window does not exist, but we can request its attributes. assert(attr != 0 && "GetRootWindowAttributes, attr parameter is null"); + - NSArray *screens = [NSScreen screens]; + NSArray * const screens = [NSScreen screens]; assert(screens != nil && "screens array is nil"); - - NSScreen *mainScreen = [screens objectAtIndex : 0]; + NSScreen * const mainScreen = [screens objectAtIndex : 0]; assert(mainScreen != nil && "screen with index 0 is nil"); - + *attr = WindowAttributes_t(); + + TGCocoa * const gCocoa = dynamic_cast(gVirtualX); + assert(gCocoa != 0 && "GetRootWindowAttributes, gVirtualX is either null or has a wrong type"); + + const Rectangle &frame = gCocoa->GetDisplayGeometry(); attr->fX = 0; attr->fY = 0; - - const NSRect frame = [mainScreen frame]; - - attr->fWidth = frame.size.width; - attr->fHeight = frame.size.height; + attr->fWidth = frame.fWidth; + attr->fHeight = frame.fHeight; attr->fBorderWidth = 0; attr->fYourEventMask = 0; attr->fAllEventMasks = 0;//??? @@ -113,29 +118,82 @@ void GetRootWindowAttributes(WindowAttributes_t *attr) //TODO: check how TGX11 extracts/changes window attributes. +//______________________________________________________________________________ +NSPoint ConvertPointFromBaseToScreen(NSWindow *window, NSPoint windowPoint) +{ + assert(window != nil && "ConvertPointFromBaseToScreen, window parameter is nil"); + + //I have no idea why apple deprecated function for a point conversion and requires rect conversion, + //point conversion seems to produce wrong results with HiDPI. + + NSRect tmpRect = {}; + tmpRect.origin = windowPoint; + tmpRect.size = CGSizeMake(1., 1.);//This is strange size :) But if they require rect, 0,0 - will not work? + tmpRect = [window convertRectToScreen : tmpRect]; + + return tmpRect.origin; +} + +//______________________________________________________________________________ +NSPoint ConvertPointFromScreenToBase(NSPoint screenPoint, NSWindow *window) +{ + assert(window != nil && "ConvertPointFromScreenToBase, window parameter is nil"); + + //I have no idea why apple deprecated function for a point conversion and requires rect conversion, + //point conversion seems to produce wrong results with HiDPI. + + NSRect tmpRect = {}; + tmpRect.origin = screenPoint; + tmpRect.size = CGSizeMake(1., 1.); + tmpRect = [window convertRectFromScreen : tmpRect]; + + return tmpRect.origin; +} + //______________________________________________________________________________ int GlobalYCocoaToROOT(CGFloat yCocoa) { - NSArray *screens = [NSScreen screens]; - assert(screens != nil && "GlobalYCocoaToROOT, screens array is nil"); + //We can have several physical displays and thus several NSScreens in some arbitrary order. + //With Cocoa, some screens can have negative coordinates - to the left ro down to the primary + //screen (whatever it means). With X11 (XQuartz) though it's always 0,0. + + TGCocoa * gCocoa = dynamic_cast(gVirtualX); + assert(gCocoa != 0 && "GlobalYCocoaToROOT, gVirtualX is either nul or has a wrong type"); + const Rectangle frame = gCocoa->GetDisplayGeometry(); - NSScreen *mainScreen = [screens objectAtIndex : 0]; - assert(mainScreen != nil && "GlobalYCocoaToROOT, screen at index 0 is nil"); + return int(frame.fHeight - (yCocoa - frame.fY)); +} + +//______________________________________________________________________________ +int GlobalXCocoaToROOT(CGFloat xCocoa) +{ + TGCocoa * gCocoa = dynamic_cast(gVirtualX); + assert(gCocoa != 0 && "GlobalXCocoaToROOT, gVirtualX is either nul or has a wrong type"); + const Rectangle frame = gCocoa->GetDisplayGeometry(); - return int(mainScreen.frame.size.height - yCocoa); + //With X11 coordinate space always starts from 0, 0 + return int(xCocoa - frame.fX); } //______________________________________________________________________________ int GlobalYROOTToCocoa(CGFloat yROOT) { - //hehe :)) actually, no need in this function. - NSArray *screens = [NSScreen screens]; - assert(screens != nil && "GlobalYROOTToCocoa, screens array is nil"); + TGCocoa * gCocoa = dynamic_cast(gVirtualX); + assert(gCocoa != 0 && "GlobalYROOTToCocoa, gVirtualX is either nul or has a wrong type"); + const Rectangle frame = gCocoa->GetDisplayGeometry(); - NSScreen *mainScreen = [screens objectAtIndex : 0]; - assert(mainScreen != nil && "GlobalYROOTToCocoa, screen at index 0 is nil"); + return int(frame.fY + (frame.fHeight - yROOT)); +} + +//______________________________________________________________________________ +int GlobalXROOTToCocoa(CGFloat xROOT) +{ + TGCocoa * gCocoa = dynamic_cast(gVirtualX); + assert(gCocoa != 0 && "GlobalXROOTToCocoa, gVirtualX is either nul or has a wrong type"); + const Rectangle frame = gCocoa->GetDisplayGeometry(); - return int(mainScreen.frame.size.height - yROOT); + //With X11 coordinate space always starts from 0, 0 + return int(frame.fX + xROOT); } //______________________________________________________________________________ @@ -170,12 +228,12 @@ NSPoint TranslateToScreen(NSView *from, NSPoint point) { assert(from != nil && "TranslateToScreen, 'from' parameter is nil"); - //TODO: I do not know, if I can use convertToBacking ..... - have to check this. - NSPoint winPoint = [from convertPoint : point toView : nil]; - NSPoint screenPoint = [[from window] convertBaseToScreen : winPoint];; - //TODO: This is Cocoa's coordinates, but for ROOT I have to convert. - screenPoint.y = GlobalYCocoaToROOT(screenPoint.y); + const NSPoint winPoint = [from convertPoint : point toView : nil]; + NSPoint screenPoint = ConvertPointFromBaseToScreen([from window], winPoint); + screenPoint.x = GlobalXCocoaToROOT(screenPoint.x); + screenPoint.y = GlobalYCocoaToROOT(screenPoint.y); + return screenPoint; } @@ -184,11 +242,11 @@ NSPoint TranslateFromScreen(NSPoint point, NSView *to) { assert(to != nil && "TranslateFromScreen, 'to' parameter is nil"); + point.x = GlobalXROOTToCocoa(point.x); point.y = GlobalYROOTToCocoa(point.y); + point = ConvertPointFromScreenToBase(point, [to window]); - //May be I can use convertBackingTo .... have to check this. - const NSPoint winPoint = [[to window] convertScreenToBase : point]; - return [to convertPoint : winPoint fromView : nil]; + return [to convertPoint : point fromView : nil]; } //______________________________________________________________________________ @@ -206,14 +264,268 @@ NSPoint TranslateCoordinates(NSView *from, NSView *to, NSP //what is 'pixel aligned backing store coordinates' and //if they are the same as screen coordinates. + //Many thanks to Apple for deprecated functions!!! + const NSPoint win1Point = [from convertPoint : sourcePoint toView : nil]; - const NSPoint screenPoint = [[from window] convertBaseToScreen : win1Point]; - const NSPoint win2Point = [[to window] convertScreenToBase : screenPoint]; + const NSPoint screenPoint = ConvertPointFromBaseToScreen([from window], win1Point); + const NSPoint win2Point = ConvertPointFromScreenToBase(screenPoint, [to window]); return [to convertPoint : win2Point fromView : nil]; } } +//______________________________________________________________________________ +bool ScreenPointIsInView(NSView *view, Int_t x, Int_t y) +{ + assert(view != nil && "ScreenPointIsInView, view parameter is nil"); + + NSPoint point = {}; + point.x = x, point.y = y; + point = TranslateFromScreen(point, view); + const NSRect viewFrame = view.frame; + + if (point.x < 0 || point.x > viewFrame.size.width) + return false; + if (point.y < 0 || point.y > viewFrame.size.height) + return false; + + return true; +} + +//______________________________________________________________________________ +QuartzWindow *FindWindowInPoint(Int_t x, Int_t y) +{ + const Util::AutoreleasePool pool;//array's counter is increased, all object in array are also retained. + + NSArray * const orderedWindows = [NSApp orderedWindows]; + for (NSWindow *window in orderedWindows) { + if (![window isKindOfClass : [QuartzWindow class]]) + continue; + QuartzWindow * const qw = (QuartzWindow *)window; + if (qw.fIsDeleted)//Because of reference counting this can happen. + continue; + //Check if point is inside. + if (ScreenPointIsInView(qw.fContentView, x, y)) + return qw; + } + + return nil; +} + +//______________________________________________________________________________ +NSView *FindDNDAwareViewInPoint(NSArray *children, Window_t dragWinID, Window_t inputWinID, Int_t x, Int_t y, Int_t maxDepth) +{ + assert(children != nil && "FindDNDAwareViewInPoint, children parameter is nil"); + + if (maxDepth <= 0) + return nil; + + NSEnumerator * const reverseEnumerator = [children reverseObjectEnumerator]; + for (NSView *child in reverseEnumerator) { + if (!ScreenPointIsInView(child, x, y)) + continue; + if (child.fIsDNDAware && child.fID != dragWinID && child.fID != inputWinID) + return child;//got it! + + NSView * const testView = FindDNDAwareViewInPoint([child subviews], dragWinID, inputWinID, x, y, maxDepth - 1); + if (testView) + return testView; + } + + return nil; +} + +//______________________________________________________________________________ +NSView *FindDNDAwareViewInPoint(NSView *parentView, Window_t dragWinID, Window_t inputWinID, Int_t x, Int_t y, Int_t maxDepth) +{ + //X and Y are ROOT's screen coordinates (Y is inverted). + if (maxDepth <= 0) + return nil; + + const Util::AutoreleasePool pool; + + if (!parentView) {//Start from the screen as a 'root' window. + NSArray * const orderedWindows = [NSApp orderedWindows]; + for (NSWindow *window in orderedWindows) { + if (![window isKindOfClass : [QuartzWindow class]]) + continue; + QuartzWindow * const qw = (QuartzWindow *)window; + + if (qw.fIsDeleted)//Because of reference counting this can happen. + continue; + + if (qw.fMapState != kIsViewable) + continue; + + //First, check this view itself, my be we found what we need already. + NSView *testView = qw.fContentView; + if (!ScreenPointIsInView(testView, x, y)) + continue; + + if (testView.fIsDNDAware && testView.fID != dragWinID && testView.fID != inputWinID) + return testView; + + //Recursive part, check children. + NSArray * const children = [testView subviews]; + testView = FindDNDAwareViewInPoint(children, dragWinID, inputWinID, x, y, maxDepth - 1); + if (testView) + return testView; + } + + //We did not find anything for 'root' window as parent. + return nil; + } else { + //Parent view is tested already (or should not be tested at all, check children. + return FindDNDAwareViewInPoint([parentView subviews], dragWinID, inputWinID, x, y, maxDepth); + } +} + +//______________________________________________________________________________ +QuartzWindow *FindWindowUnderPointer() +{ + const Util::AutoreleasePool pool; + + NSArray * const orderedWindows = [NSApp orderedWindows]; + for (NSWindow *nsWindow in orderedWindows) { + if (![nsWindow isKindOfClass : [QuartzWindow class]]) + continue; + + QuartzWindow * const qWindow = (QuartzWindow *)nsWindow; + + if (qWindow.fIsDeleted)//Because of reference counting this can happen. + continue; + + if (qWindow.fMapState != kIsViewable)//Can it be false and still in this array??? + continue; + + const NSPoint mousePosition = [qWindow mouseLocationOutsideOfEventStream]; + const NSSize windowSize = qWindow.frame.size; + if (mousePosition.x >= 0 && mousePosition.x <= windowSize.width && mousePosition.y >= 0 && mousePosition.y <= windowSize.height) + return qWindow; + } + + return nil; +} + +//______________________________________________________________________________ +NSView *FindViewUnderPointer() +{ + //TODO: call FindViewInPoint using cursor screen coordiantes. + const Util::AutoreleasePool pool; + + if (QuartzWindow *topLevel = FindWindowUnderPointer()) { + const NSPoint mousePosition = [topLevel mouseLocationOutsideOfEventStream]; + return (NSView *)[[topLevel contentView] hitTest : mousePosition]; + } + + return nil; +} + +//______________________________________________________________________________ +QuartzWindow *FindWindowForPointerEvent(NSEvent *pointerEvent) +{ + //FindWindowForPointerEvent is required because due to grabs the receiver of the event + //can be different from the actual window under cursor. + + assert(pointerEvent != nil && "FindWindowForPointerEvent, pointerEvent parameter is nil"); + + const Util::AutoreleasePool pool; + + NSArray * const orderedWindows = [NSApp orderedWindows]; + for (NSWindow *nsWindow in orderedWindows) { + if (![nsWindow isKindOfClass : [QuartzWindow class]]) + continue; + + QuartzWindow * const qWindow = (QuartzWindow *)nsWindow; + + if (qWindow.fIsDeleted)//Because of reference counting this can happen. + continue; + + if (qWindow.fMapState != kIsViewable)//Can it be false and still in this array??? + continue; + + NSPoint mousePosition = [pointerEvent locationInWindow]; + //The event has a window, so position is in this window's coordinate system, + //convert it into screen point first. + if ([pointerEvent window]) { + //convertBaseToScreen is deprecated. + //mousePosition = [[pointerEvent window] convertBaseToScreen : mousePosition]; + mousePosition = ConvertPointFromBaseToScreen([pointerEvent window], mousePosition); + } + + //convertScreenToBase is deprecated. + //mousePosition = [qWindow convertScreenToBase : mousePosition]; + mousePosition = ConvertPointFromScreenToBase(mousePosition, qWindow); + + const NSSize windowSize = qWindow.frame.size; + if (mousePosition.x >= 0 && mousePosition.x <= windowSize.width && mousePosition.y >= 0 && mousePosition.y <= windowSize.height) + return qWindow; + } + + return nil; +} + +//______________________________________________________________________________ +NSView *FindViewForPointerEvent(NSEvent *pointerEvent) +{ + //FindViewForPointerEvent is required because of grabs - the receiver of the + //event can be different from the actual window under cursor. + + assert(pointerEvent != nil && "FindViewForPointerEvent, pointerEvent parameter is nil"); + + const Util::AutoreleasePool pool; + + if (QuartzWindow *topLevel = FindWindowForPointerEvent(pointerEvent)) { + NSPoint mousePosition = [pointerEvent locationInWindow]; + if ([pointerEvent window]) + mousePosition = ConvertPointFromBaseToScreen([pointerEvent window], mousePosition); + + //convertScreenToBase is deprecated. + //mousePosition = [topLevel convertScreenToBase : mousePosition]; + mousePosition = ConvertPointFromScreenToBase(mousePosition, topLevel); + + return (NSView *)[[topLevel contentView] hitTest : mousePosition]; + } + + return nil; +} + +//______________________________________________________________________________ +void ClipToShapeMask(NSView *view, CGContextRef ctx) +{ + assert(view != nil && "ClipToShapeMask, view parameter is nil"); + assert(ctx != 0 && "ClipToShapeMask, ctx parameter is null"); + + QuartzWindow * const topLevelParent = view.fQuartzWindow; + assert(topLevelParent.fShapeCombineMask != nil && "ClipToShapeMask, fShapeCombineMask is nil on a top-level window"); + assert(topLevelParent.fShapeCombineMask.fImage != 0 && "ClipToShapeMask, shape mask is null"); + + //Important: shape mask should have the same width and height as + //a top-level window. In ROOT it does not :( Say hello to visual artifacts. + + //Attach clip mask to the context. + NSRect clipRect = view.frame; + if (!view.fParentView) { + //'view' is a top-level view. + clipRect = CGRectMake(0, 0, topLevelParent.fShapeCombineMask.fWidth, topLevelParent.fShapeCombineMask.fHeight); + CGContextClipToMask(ctx, clipRect, topLevelParent.fShapeCombineMask.fImage); + } else { + //More complex case: 'self' is a child view, we have to create a subimage from shape mask. + clipRect.origin = [view.fParentView convertPoint : clipRect.origin toView : [view window].contentView]; + clipRect.origin.y = X11::LocalYROOTToCocoa((NSView *)[view window].contentView, clipRect.origin.y + clipRect.size.height); + + if (AdjustCropArea(topLevelParent.fShapeCombineMask, clipRect)) { + const Util::CFScopeGuard clipImageGuard(CGImageCreateWithImageInRect(topLevelParent.fShapeCombineMask.fImage, clipRect)); + clipRect.origin = CGPointZero; + CGContextClipToMask(ctx, clipRect, clipImageGuard.Get()); + } else { + //View is invisible. + CGRect rect = {}; + CGContextClipToRect(ctx, rect); + } + } +} + //______________________________________________________________________________ void SetWindowAttributes(const SetWindowAttributes_t *attr, NSObject *window) { @@ -240,9 +552,12 @@ void SetWindowAttributes(const SetWindowAttributes_t *attr, NSObject //This is quite a special case. //TODO: Must be checked yet, if I understand this correctly! if ([(NSObject *)window isKindOfClass : [QuartzWindow class]]) { - QuartzWindow *qw = (QuartzWindow *)window; + QuartzWindow * const qw = (QuartzWindow *)window; [qw setStyleMask : NSBorderlessWindowMask]; + [qw setAlphaValue : 0.95]; } + + window.fOverrideRedirect = YES; } } @@ -302,7 +617,7 @@ void GetWindowAttributes(NSObject *window, WindowAttributes_t *dst) //Not used by GUI. //dst->fDoNotPropagateMask - dst->fOverrideRedirect = 0; + dst->fOverrideRedirect = window.fOverrideRedirect; //Dummy value. dst->fScreen = 0; } @@ -319,6 +634,7 @@ NSComparisonResult CompareViewsToLower(id view1, id view2, void *context) return NSOrderedAscending; if (view2 == topView) return NSOrderedDescending; + return NSOrderedSame; } @@ -347,17 +663,20 @@ NSPoint GetCursorHotStop(NSImage *image, ECursor cursor) return CGPointMake(imageSize.width / 2, imageSize.height / 2); } -//TGTextView is a very special window: it's a TGCompositeFrame, +//TGTextView/TGHtml is a very special window: it's a TGCompositeFrame, //which has TGCompositeFrame inside (TGViewFrame). This TGViewFrame //delegates Expose events to its parent, and parent tries to draw //inside a TGViewFrame. This does not work with default //QuartzView -drawRect/TGCocoa. So I need a trick to identify //this special window. +//TODO: possibly refactor these functions in a more generic way - not +//to have two separate versions for text and html. + //______________________________________________________________________________ bool ViewIsTextView(unsigned viewID) { - TGWindow *window = gClient->GetWindowById(viewID); + const TGWindow * const window = gClient->GetWindowById(viewID); if (!window) return false; return window->InheritsFrom("TGTextView"); @@ -376,7 +695,7 @@ bool ViewIsTextViewFrame(NSView *view, bool checkParent) { assert(view != nil && "ViewIsTextViewFrame, view parameter is nil"); - TGWindow *window = gClient->GetWindowById(view.fID); + const TGWindow * const window = gClient->GetWindowById(view.fID); if (!window) return false; @@ -392,6 +711,45 @@ bool ViewIsTextViewFrame(NSView *view, bool checkParent) return ViewIsTextView(view.fParentView); } +//______________________________________________________________________________ +bool ViewIsHtmlView(unsigned viewID) +{ + const TGWindow * const window = gClient->GetWindowById(viewID); + if (!window) + return false; + return window->InheritsFrom("TGHtml"); +} + +//______________________________________________________________________________ +bool ViewIsHtmlView(NSView *view) +{ + assert(view != nil && "ViewIsHtmlView, view parameter is nil"); + + return ViewIsHtmlView(view.fID); +} + +//______________________________________________________________________________ +bool ViewIsHtmlViewFrame(NSView *view, bool checkParent) +{ + // + assert(view != nil && "ViewIsHtmlViewFrame, view parameter is nil"); + + const TGWindow * const window = gClient->GetWindowById(view.fID); + if (!window) + return false; + + if (!window->InheritsFrom("TGViewFrame")) + return false; + + if (!checkParent) + return true; + + if (!view.fParentView) + return false; + + return ViewIsHtmlView(view.fParentView); +} + //______________________________________________________________________________ NSView *FrameForTextView(NSView *textView) { @@ -405,6 +763,19 @@ bool ViewIsTextViewFrame(NSView *view, bool checkParent) return nil; } +//______________________________________________________________________________ +NSView *FrameForHtmlView(NSView *htmlView) +{ + assert(htmlView != nil && "FrameForHtmlView, htmlView parameter is nil"); + + for (NSView *child in [htmlView subviews]) { + if (ViewIsHtmlViewFrame(child, false)) + return child; + } + + return nil; +} + //______________________________________________________________________________ bool LockFocus(NSView *view) { @@ -435,9 +806,13 @@ void UnlockFocus(NSView *view) ((QuartzView *)view).fContext = 0; } -} -} -} +}//X11 +}//MacOSX +}//ROOT + +namespace Quartz = ROOT::Quartz; +namespace Util = ROOT::MacOSX::Util; +namespace X11 = ROOT::MacOSX::X11; #ifdef DEBUG_ROOT_COCOA @@ -512,12 +887,24 @@ void print_mask_info(ULong_t mask) @implementation QuartzWindow { @private QuartzView *fContentView; + BOOL fDelayedTransient; + QuartzImage *fShapeCombineMask; + BOOL fIsDeleted; } - @synthesize fMainWindow; -@synthesize fBackBuffer; +/* +//______________________________________________________________________________ +- (BOOL) canBecomeKeyWindow +{ + //Before I did not need this. Default implementation returns NO for a window + //without a title-bar and ... when (for example) switching between applications + //with alt-tab, the Z-order breaks :( Strange enough, for previous versions + //it was enough to make such a window a child of another window + //(it's always a popup and derived classes), but now it's not enough :( + return YES; +}*/ //QuartzWindow's life cycle. //______________________________________________________________________________ @@ -543,86 +930,167 @@ - (id) initWithContentRect : (NSRect) contentRect styleMask : (NSUInteger) windo [self setContentView : fContentView]; [fContentView release]; + fDelayedTransient = NO; if (attr) - ROOT::MacOSX::X11::SetWindowAttributes(attr, self); + X11::SetWindowAttributes(attr, self); + + fIsDeleted = NO; } return self; } //______________________________________________________________________________ -- (void) addTransientWindow : (QuartzWindow *)window +- (id) initWithGLView : (ROOTOpenGLView *) glView { - assert(window != nil && "addTransientWindow, window parameter is nil"); + assert(glView != nil && "initWithGLView, glView parameter is nil"); + + const NSUInteger styleMask = NSTitledWindowMask | NSClosableWindowMask | NSMiniaturizableWindowMask | NSResizableWindowMask; + + NSRect contentRect = glView.frame; + contentRect.origin = CGPointZero; + + self = [super initWithContentRect : contentRect styleMask : styleMask backing : NSBackingStoreBuffered defer : NO]; - window.fMainWindow = self; - [self addChildWindow : window ordered : NSWindowAbove]; + if (self) { + //ROOT's not able to draw GUI concurrently, thanks to global variables and gVirtualX itself. + [self setAllowsConcurrentViewDrawing : NO]; + self.delegate = self; + fContentView = glView; + [self setContentView : fContentView]; + fDelayedTransient = NO; + fIsDeleted = NO; + } + + return self; } //______________________________________________________________________________ - (void) dealloc { + [fShapeCombineMask release]; [super dealloc]; } -/////////////////////////////////////////////////////////// -//X11Drawable's protocol. +//______________________________________________________________________________ +- (BOOL) fIsDeleted +{ + return fIsDeleted; +} + +//______________________________________________________________________________ +- (void) setFIsDeleted : (BOOL) deleted +{ + fIsDeleted = deleted; +} + +//I want to forward a lot of property setters/getters to content view. //______________________________________________________________________________ -- (unsigned) fID +- (void) forwardInvocation : (NSInvocation *) anInvocation { - assert(fContentView != nil && "fID, content view is nil"); + assert(fContentView != nil && "forwardInvocation:, fContentView is nil"); - return fContentView.fID; + if ([fContentView respondsToSelector : [anInvocation selector]]) { + [anInvocation invokeWithTarget : fContentView]; + } else { + [super forwardInvocation : anInvocation]; + } } //______________________________________________________________________________ -- (void) setFID : (unsigned) winID +- (NSMethodSignature*) methodSignatureForSelector : (SEL) selector { - assert(fContentView != nil && "setFID, content view is nil"); + NSMethodSignature *signature = [super methodSignatureForSelector : selector]; + + if (!signature) { + assert(fContentView != nil && "methodSignatureForSelector:, fContentView is nil"); + signature = [fContentView methodSignatureForSelector : selector]; + } + + return signature; +} + +//______________________________________________________________________________ +- (void) addTransientWindow : (QuartzWindow *) window +{ + assert(window != nil && "addTransientWindow, window parameter is nil"); + + window.fMainWindow = self; - fContentView.fID = winID; + if (window.fMapState != kIsViewable) { + window.fDelayedTransient = YES; + } else { + [self addChildWindow : window ordered : NSWindowAbove]; + window.fDelayedTransient = NO; + } } //______________________________________________________________________________ -- (BOOL) fIsPixmap +- (void) makeKeyAndOrderFront:(id)sender { - return NO; + (void) sender; + //The more I know Cocoa, the less I like it. + //Window behavior between spaces is a total mess. + //Set the window to join all spaces. + [self setCollectionBehavior : NSWindowCollectionBehaviorCanJoinAllSpaces]; + //now bring it to the front, it will appear on the active space. + [super makeKeyAndOrderFront : self]; + //then reset the collection behavior to default, so the window + [self setCollectionBehavior : NSWindowCollectionBehaviorDefault]; } //______________________________________________________________________________ -- (BOOL) fIsOpenGLWidget +- (void) setFDelayedTransient : (BOOL) d { - return NO; + fDelayedTransient = d; } //______________________________________________________________________________ -- (CGContextRef) fContext +- (QuartzImage *) fShapeCombineMask { - assert(fContentView != nil && "fContext, fContentView is nil"); + return fShapeCombineMask; +} - return fContentView.fContext; +//______________________________________________________________________________ +- (void) setFShapeCombineMask : (QuartzImage *) mask +{ + if (mask != fShapeCombineMask) { + [fShapeCombineMask release]; + if (mask) { + fShapeCombineMask = [mask retain]; + + //Check window's shadow??? + } + } } +/////////////////////////////////////////////////////////// +//X11Drawable's protocol. + //______________________________________________________________________________ -- (void) setFContext : (CGContextRef) ctx +- (BOOL) fIsPixmap { - assert(fContentView != nil && "setFContext, fContentView is nil"); + return NO; +} - fContentView.fContext = ctx; +//______________________________________________________________________________ +- (BOOL) fIsOpenGLWidget +{ + return NO; } //______________________________________________________________________________ - (int) fX { - return self.frame.origin.x; + return X11::GlobalXCocoaToROOT(self.frame.origin.x); } //______________________________________________________________________________ - (int) fY { - return ROOT::MacOSX::X11::GlobalYCocoaToROOT(self.frame.origin.y + self.frame.size.height); + return X11::GlobalYCocoaToROOT(self.frame.origin.y + self.frame.size.height); } //______________________________________________________________________________ @@ -649,7 +1117,17 @@ - (void) setDrawableSize : (NSSize) newSize assert(!(newSize.width < 0) && "setDrawableSize, width is negative"); assert(!(newSize.height < 0) && "setDrawableSize, height is negative"); - [self setContentSize : newSize]; + NSRect frame = self.frame; + //dY is potentially a titlebar height. + const CGFloat dY = fContentView ? frame.size.height - fContentView.frame.size.height : 0.; + //Adjust the frame. + frame.origin.y = frame.origin.y + frame.size.height - newSize.height - dY; + frame.size = newSize; + frame.size.height += dY; + [self setFrame : frame display : YES]; + + //Was before: MOVES window (top-left corner). + //[self setContentSize : newSize]; } //______________________________________________________________________________ @@ -662,8 +1140,8 @@ - (void) setX : (int) x Y : (int) y width : (unsigned) w height : (unsigned) h //Check how this is affected by title bar's height. NSPoint topLeft = {}; - topLeft.x = x; - topLeft.y = ROOT::MacOSX::X11::GlobalYROOTToCocoa(y); + topLeft.x = X11::GlobalXROOTToCocoa(x); + topLeft.y = X11::GlobalYROOTToCocoa(y); [self setFrameTopLeftPoint : topLeft]; } @@ -672,14 +1150,14 @@ - (void) setX : (int) x Y : (int) y width : (unsigned) w height : (unsigned) h - (void) setX : (int) x Y : (int) y { NSPoint topLeft = {}; - topLeft.x = x; - topLeft.y = ROOT::MacOSX::X11::GlobalYROOTToCocoa(y); + topLeft.x = X11::GlobalXROOTToCocoa(x); + topLeft.y = X11::GlobalYROOTToCocoa(y); [self setFrameTopLeftPoint : topLeft]; } //______________________________________________________________________________ -- (void) copy : (NSObject *) src area : (Rectangle_t) area withMask : (QuartzImage *)mask clipOrigin : (Point_t) clipXY toPoint : (Point_t) dstPoint +- (void) copy : (NSObject *) src area : (X11::Rectangle) area withMask : (QuartzImage *)mask clipOrigin : (X11::Point) clipXY toPoint : (X11::Point) dstPoint { assert(fContentView != nil && "copy:area:toPoint:, fContentView is nil"); @@ -687,7 +1165,7 @@ - (void) copy : (NSObject *) src area : (Rectangle_t) area withMask } //______________________________________________________________________________ -- (unsigned char *) readColorBits : (Rectangle_t) area +- (unsigned char *) readColorBits : (X11::Rectangle) area { assert(fContentView != nil && "readColorBits:, fContentView is nil"); @@ -723,100 +1201,29 @@ - (QuartzWindow *) fQuartzWindow ///////////////////////////////////////////////////////////// //SetWindowAttributes_t/WindowAttributes_t. -//______________________________________________________________________________ -- (long) fEventMask -{ - assert(fContentView != nil && "fEventMask, content view is nil"); - - return fContentView.fEventMask; -} - -//______________________________________________________________________________ -- (void) setFEventMask : (long)mask -{ - assert(fContentView != nil && "setFEventMask, content view is nil"); - - fContentView.fEventMask = mask; -} - -//______________________________________________________________________________ -- (int) fClass -{ - assert(fContentView != nil && "fClass, content view is nil"); - - return fContentView.fClass; -} +//... forwards to fContentView. //______________________________________________________________________________ -- (void) setFClass : (int) windowClass +- (void) setFBackgroundPixel : (unsigned long) backgroundColor { - assert(fContentView != nil && "setFClass, content view is nil"); - - fContentView.fClass = windowClass; -} + assert(fContentView != nil && "setFBackgroundPixel, fContentView is nil"); -//______________________________________________________________________________ -- (int) fDepth -{ - assert(fContentView != nil && "fDepth, content view is nil"); - - return fContentView.fDepth; -} + if (!fShapeCombineMask) { + CGFloat rgba[] = {0., 0., 0., 1.}; + X11::PixelToRGB(backgroundColor, rgba); -//______________________________________________________________________________ -- (void) setFDepth : (int) depth -{ - assert(fContentView != nil && "setFDepth, content view is nil"); - - fContentView.fDepth = depth; -} - -//______________________________________________________________________________ -- (int) fBitGravity -{ - assert(fContentView != nil && "fBitGravity, content view is nil"); - - return fContentView.fBitGravity; -} - -//______________________________________________________________________________ -- (void) setFBitGravity : (int) bit -{ - assert(fContentView != nil && "setFBitGravity, content view is nil"); - - fContentView.fBitGravity = bit; -} - -//______________________________________________________________________________ -- (int) fWinGravity -{ - assert(fContentView != nil && "fWinGravity, content view is nil"); - - return fContentView.fWinGravity; -} - -//______________________________________________________________________________ -- (void) setFWinGravity : (int) bit -{ - assert(fContentView != nil && "setFWinGravity, content view is nil"); + [self setBackgroundColor : [NSColor colorWithColorSpace : [NSColorSpace deviceRGBColorSpace] components : rgba count : 4]]; + } - fContentView.fWinGravity = bit; + fContentView.fBackgroundPixel = backgroundColor; } //______________________________________________________________________________ - (unsigned long) fBackgroundPixel { - assert(fContentView != nil && "fBackgroundPixel, content view is nil"); - - return fContentView.fBackgroundPixel; -} + assert(fContentView != nil && "fBackgroundPixel, fContentView is nil"); -//______________________________________________________________________________ -- (void) setFBackgroundPixel : (unsigned long) pixel -{ - assert(fContentView != nil && "SetFBackgroundPixel, content view is nil"); - - fContentView.fBackgroundPixel = pixel; + return fContentView.fBackgroundPixel; } //______________________________________________________________________________ @@ -831,78 +1238,19 @@ - (int) fMapState return kIsViewable; } -//______________________________________________________________________________ -- (int) fGrabButton -{ - assert(fContentView != nil && "fGrabButton, content view is nil"); - - return fContentView.fGrabButton; -} - -//______________________________________________________________________________ -- (void) setFGrabButton : (int) btn -{ - assert(fContentView != nil && "setFGrabButton, content view is nil"); - - fContentView.fGrabButton = btn; -} - -//______________________________________________________________________________ -- (unsigned) fGrabButtonEventMask -{ - assert(fContentView != nil && "fGrabButtonEventMask, content view is nil"); - - return fContentView.fGrabButtonEventMask; -} - -//______________________________________________________________________________ -- (void) setFGrabButtonEventMask : (unsigned) mask -{ - assert(fContentView != nil && "setFGrabButtonEventMask, content view is nil"); - - fContentView.fGrabButtonEventMask = mask; -} - -//______________________________________________________________________________ -- (unsigned) fGrabKeyModifiers -{ - assert(fContentView != nil && "fGrabKeyModifiers, content view is nil"); - - return fContentView.fGrabKeyModifiers; -} - -//______________________________________________________________________________ -- (void) setFGrabKeyModifiers : (unsigned) mod -{ - assert(fContentView != nil && "setFGrabKeyModifiers, content view is nil"); - - fContentView.fGrabKeyModifiers = mod; -} - -//______________________________________________________________________________ -- (BOOL) fOwnerEvents -{ - assert(fContentView != nil && "fOwnerEvents, content view is nil"); - - return fContentView.fOwnerEvents; -} - -//______________________________________________________________________________ -- (void) setFOwnerEvents : (BOOL) owner -{ - assert(fContentView != nil && "setFOwnerEvents, content view is nil"); - - fContentView.fOwnerEvents = owner; -} - - //______________________________________________________________________________ - (void) addChild : (NSView *) child { - assert(fContentView != nil && "addChild, content view is nil"); assert(child != nil && "addChild, child view is nil"); - - [fContentView addChild : child]; + + if (!fContentView) { + //This can happen only in case of re-parent operation. + assert([child isKindOfClass : [QuartzView class]] && "addChild: gl view in a top-level window as content view is not supported"); + fContentView = (QuartzView *)child; + [self setContentView : child]; + fContentView.fParentView = nil; + } else + [fContentView addChild : child]; } //______________________________________________________________________________ @@ -911,7 +1259,7 @@ - (void) getAttributes : (WindowAttributes_t *) attr assert(fContentView != 0 && "getAttributes, content view is nil"); assert(attr && "getAttributes, attr parameter is nil"); - ROOT::MacOSX::X11::GetWindowAttributes(self, attr); + X11::GetWindowAttributes(self, attr); } //______________________________________________________________________________ @@ -923,18 +1271,24 @@ - (void) setAttributes : (const SetWindowAttributes_t *)attr log_attributes(attr, self.fID); #endif - ROOT::MacOSX::X11::SetWindowAttributes(attr, self); + X11::SetWindowAttributes(attr, self); } //______________________________________________________________________________ - (void) mapRaised { assert(fContentView && "mapRaised, content view is nil"); + + const Util::AutoreleasePool pool; -// [self orderFront : self]; - [self makeKeyAndOrderFront : self]; [fContentView setHidden : NO]; + [self makeKeyAndOrderFront : self]; [fContentView configureNotifyTree]; + + if (fDelayedTransient) { + fDelayedTransient = NO; + [fMainWindow addChildWindow : self ordered : NSWindowAbove]; + } } //______________________________________________________________________________ @@ -942,10 +1296,16 @@ - (void) mapWindow { assert(fContentView != nil && "mapWindow, content view is nil"); + const Util::AutoreleasePool pool; // [self orderFront : self]; - [self makeKeyAndOrderFront : self]; [fContentView setHidden : NO]; + [self makeKeyAndOrderFront : self]; [fContentView configureNotifyTree]; + + if (fDelayedTransient) { + fDelayedTransient = NO; + [fMainWindow addChildWindow : self ordered : NSWindowAbove]; + } } //______________________________________________________________________________ @@ -953,6 +1313,8 @@ - (void) mapSubwindows { assert(fContentView != nil && "mapSubwindows, content view is nil"); + const Util::AutoreleasePool pool; + [fContentView mapSubwindows]; [fContentView configureNotifyTree]; } @@ -964,6 +1326,11 @@ - (void) unmapWindow [fContentView setHidden : YES]; [self orderOut : self]; + + if (fMainWindow && !fDelayedTransient) { + [fMainWindow removeChildWindow : self]; + fMainWindow = nil; + } } //Events. @@ -974,19 +1341,32 @@ - (void) sendEvent : (NSEvent *) theEvent assert(fContentView != nil && "sendEvent, content view is nil"); if (theEvent.type == NSLeftMouseDown || theEvent.type == NSRightMouseDown) { + bool generateFakeRelease = false; + const NSPoint windowPoint = [theEvent locationInWindow]; - const NSPoint viewPoint = [fContentView convertPointFromBase : windowPoint]; - if (viewPoint.y <= 0 && windowPoint.y >= 0) { - //Very special case: mouse is in a title bar. - //There are not NSView object in this area, - //this event will never go to any QuartzView, and this - //can be a problem: if drop-down menu is open and - //you move window using title-bar, ROOT's menu will - //"fell through" the main window, which is weird. - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != 0 && "sendEvent, gVirtualX is either null or not of TGCocoa type"); - if (vx->GetEventTranslator()->HasPointerGrab()) - vx->GetEventTranslator()->GenerateButtonReleaseEvent(fContentView, theEvent, theEvent.type == NSLeftMouseDown ? kButton1 : kButton3);//yes, button release??? + + if (windowPoint.x <= 4 || windowPoint.x >= self.fWidth - 4) + generateFakeRelease = true; + + if (windowPoint.y <= 4 || windowPoint.y >= self.fHeight - 4) + generateFakeRelease = true; + + //convertPointFromBase is deprectated. + //const NSPoint viewPoint = [fContentView convertPointFromBase : windowPoint]; + const NSPoint viewPoint = [fContentView convertPoint : windowPoint fromView : nil]; + + if (viewPoint.y <= 0 && windowPoint.y >= 0) + generateFakeRelease = true; + + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx != 0 && "sendEvent, gVirtualX is either null or not of TGCocoa type"); + if (vx->GetEventTranslator()->HasPointerGrab() && generateFakeRelease) { + vx->GetEventTranslator()->GenerateButtonReleaseEvent(fContentView, theEvent, theEvent.type == NSLeftMouseDown ? kButton1 : kButton3);//yes, button release??? + + //Yes, ignore this event completely (this means, you are not able to immediately start + //resizing a window, if some popup is open. Actually, this is more or less + //the same as with X11.app and X11 version. + return; } } @@ -994,24 +1374,6 @@ - (void) sendEvent : (NSEvent *) theEvent [super sendEvent : theEvent]; } -//Cursors. -//______________________________________________________________________________ -- (ECursor) fCurrentCursor -{ - assert(fContentView != nil && "fCurrentCursor, content view is nil"); - - return fContentView.fCurrentCursor; -} - -//______________________________________________________________________________ -- (void) setFCurrentCursor : (ECursor) cursor -{ - assert(fContentView != nil && "setFCurrentCursor, content view is nil"); - - fContentView.fCurrentCursor = cursor; -} - - //NSWindowDelegate's methods. //______________________________________________________________________________ @@ -1032,10 +1394,10 @@ - (BOOL) windowShouldClose : (id) sender closeEvent.fWindow = fContentView.fID; closeEvent.fType = kClientMessage; closeEvent.fFormat = 32;//Taken from GUI classes. - closeEvent.fHandle = TGCocoa::kIA_DELETE_WINDOW; - closeEvent.fUser[0] = TGCocoa::kIA_DELETE_WINDOW; + closeEvent.fHandle = TGCocoa::fgDeleteWindowAtom; + closeEvent.fUser[0] = TGCocoa::fgDeleteWindowAtom; //Place it into the queue. - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "windowShouldClose, gVirtualX is either null or has a type different from TGCocoa"); vx->SendEvent(fContentView.fID, &closeEvent); @@ -1043,6 +1405,40 @@ - (BOOL) windowShouldClose : (id) sender return NO; } +//______________________________________________________________________________ +- (void) windowDidBecomeKey : (NSNotification *) aNotification +{ + assert(fContentView != nil && "windowDidBecomeKey, fContentView is nil"); + + (void) aNotification; + + if (!fContentView.fOverrideRedirect) { + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx != 0 && "becomeFirstResponder, gVirtualX is null or not of TGCocoa type"); + vx->GetEventTranslator()->GenerateFocusChangeEvent(self.fContentView); + } +} + +/* +//______________________________________________________________________________ +- (void) windowDidResignKey : (NSNotification *) aNotification +{ +// TGCocoa * const vx = dynamic_cast(gVirtualX); +// assert(vx != 0 && "becomeFirstResponder, gVirtualX is null or not of TGCocoa type"); +// vx->GetEventTranslator()->GenerateFocusChangeEvent(nil); +} +*/ + +/* +//______________________________________________________________________________ +-(BOOL)canBecomeKeyWindow +{ + assert(fContentView != nil && "canBecomeKeyWindow, fContentView is nil"); + + return !fContentView.fOverrideRedirect; +} +*/ + @end // @@ -1057,45 +1453,124 @@ @implementation PassiveKeyGrab { } //______________________________________________________________________________ -- (id) initWithKey : (unichar) keyCode modifiers : (NSUInteger) modifiers +- (id) initWithKey : (unichar) keyCode modifiers : (NSUInteger) modifiers +{ + if (self = [super init]) { + fKeyCode = keyCode; + fModifiers = modifiers; + } + + return self; +} + +//______________________________________________________________________________ +- (BOOL) matchKey : (unichar) keyCode modifiers : (NSUInteger) modifiers +{ + return keyCode == fKeyCode && modifiers == fModifiers; +} + +//______________________________________________________________________________ +- (BOOL) matchKey : (unichar) keyCode +{ + return keyCode == fKeyCode; +} + +//______________________________________________________________________________ +- (unichar) fKeyCode +{ + return fKeyCode; +} + +//______________________________________________________________________________ +- (NSUInteger) fModifiers +{ + return fModifiers; +} + +@end + +// +// +//X11 "property". +@interface QuartzWindowProperty : NSObject { + NSData *fPropertyData; + Atom_t fType; + unsigned fFormat; +} + +@property (nonatomic, readonly) Atom_t fType; + +@end + +@implementation QuartzWindowProperty + +@synthesize fType; + +//______________________________________________________________________________ +- (id) initWithData : (unsigned char *) data size : (unsigned) dataSize type : (Atom_t) type format : (unsigned) format { if (self = [super init]) { - fKeyCode = keyCode; - fModifiers = modifiers; + //Memory is zero-initialized, but just to make it explicit: + fPropertyData = nil; + fType = 0; + fFormat = 0; + + [self resetPropertyData : data size : dataSize type : type format : format]; } - + return self; } //______________________________________________________________________________ -- (BOOL) matchKey : (unichar) keyCode modifiers : (NSUInteger) modifiers +- (void) dealloc { - return keyCode == fKeyCode && modifiers == fModifiers; + [fPropertyData release]; + + [super dealloc]; } //______________________________________________________________________________ -- (BOOL) matchKey : (unichar) keyCode +- (void) resetPropertyData : (unsigned char *) data size : (unsigned) dataSize type : (Atom_t) type format : (unsigned) format { - return keyCode == fKeyCode; + [fPropertyData release]; + + fFormat = format; + if (format == 16) + dataSize *= 2; + else if (format == 32) + dataSize *= 4; + + fPropertyData = [[NSData dataWithBytes : data length : dataSize] retain]; + + fType = type; } //______________________________________________________________________________ -- (unichar) fKeyCode +- (NSData *) fPropertyData { - return fKeyCode; + return fPropertyData; } //______________________________________________________________________________ -- (NSUInteger) fModifiers +- (unsigned) fFormat { - return fModifiers; + return fFormat; } @end + @implementation QuartzView { + QuartzPixmap *fBackBuffer; NSMutableArray *fPassiveKeyGrabs; BOOL fIsOverlapped; + + NSMutableDictionary *fX11Properties; + QuartzImage *fBackgroundPixmap; + + X11::PointerGrab fCurrentGrabType; + unsigned fActiveGrabEventMask; + BOOL fActiveGrabOwnerEvents; } @synthesize fID; @@ -1108,52 +1583,103 @@ @implementation QuartzView { @synthesize fBitGravity; @synthesize fWinGravity; @synthesize fBackgroundPixel; +@synthesize fOverrideRedirect; //SetWindowAttributes_t/WindowAttributes_t ///////////////////// -@synthesize fBackBuffer; @synthesize fParentView; -@synthesize fLevel; -@synthesize fGrabButton; -@synthesize fGrabButtonEventMask; -@synthesize fGrabKeyModifiers; -@synthesize fOwnerEvents; + +@synthesize fPassiveGrabButton; +@synthesize fPassiveGrabEventMask; +@synthesize fPassiveGrabKeyModifiers; +@synthesize fActiveGrabEventMask; +@synthesize fPassiveGrabOwnerEvents; @synthesize fSnapshotDraw; @synthesize fCurrentCursor; +@synthesize fIsDNDAware; //______________________________________________________________________________ - (id) initWithFrame : (NSRect) frame windowAttributes : (const SetWindowAttributes_t *)attr { if (self = [super initWithFrame : frame]) { //Make this explicit (though memory is zero initialized). + fBackBuffer = nil; fID = 0; - fLevel = 0; //Passive grab parameters. - fGrabButton = -1;//0 is kAnyButton. - fGrabButtonEventMask = 0; - fOwnerEvents = NO; + fPassiveGrabButton = -1;//0 is kAnyButton. + fPassiveGrabEventMask = 0; + fPassiveGrabOwnerEvents = NO; fPassiveKeyGrabs = [[NSMutableArray alloc] init]; [self setCanDrawConcurrently : NO]; [self setHidden : YES]; - //Actually, check if view need this. - const NSUInteger trackerOptions = NSTrackingMouseMoved | NSTrackingMouseEnteredAndExited | NSTrackingActiveInActiveApp | NSTrackingInVisibleRect; - frame.origin = CGPointZero; - NSTrackingArea *tracker = [[NSTrackingArea alloc] initWithRect : frame options : trackerOptions owner : self userInfo : nil]; - [self addTrackingArea : tracker]; - [tracker release]; + //Actually, check if view need this. // if (attr) - ROOT::MacOSX::X11::SetWindowAttributes(attr, self); + X11::SetWindowAttributes(attr, self); fCurrentCursor = kPointer; + fX11Properties = [[NSMutableDictionary alloc] init]; + + fCurrentGrabType = X11::kPGNoGrab; + fActiveGrabEventMask = 0; + fActiveGrabOwnerEvents = YES; } return self; } +//______________________________________________________________________________ +- (void) dealloc +{ + [fBackBuffer release]; + [fPassiveKeyGrabs release]; + [fX11Properties release]; + [fBackgroundPixmap release]; + [super dealloc]; +} + +//______________________________________________________________________________ +- (void)updateTrackingAreas +{ + if (!fID) + return; + + if (NSIsEmptyRect([self visibleRect])) + return; + + + const Util::AutoreleasePool pool; + + if (NSArray *trackingArray = [self trackingAreas]) { + const NSUInteger size = [trackingArray count]; + for (NSUInteger i = 0; i < size; ++i) { + NSTrackingArea * const t = [trackingArray objectAtIndex : i]; + [self removeTrackingArea : t]; + } + } + + const NSUInteger trackerOptions = NSTrackingMouseMoved | NSTrackingMouseEnteredAndExited | NSTrackingActiveInActiveApp | NSTrackingInVisibleRect + | NSTrackingEnabledDuringMouseDrag; + NSRect frame = {}; + frame.size.width = self.fWidth; + frame.size.height = self.fHeight; + + NSTrackingArea * const tracker = [[NSTrackingArea alloc] initWithRect : frame options : trackerOptions owner : self userInfo : nil]; + [self addTrackingArea : tracker]; + [tracker release]; +} + +//______________________________________________________________________________ +- (void) updateTrackingAreasAfterRaise +{ + [self updateTrackingAreas]; + for (QuartzView *childView in [self subviews]) + [childView updateTrackingAreasAfterRaise]; +} + //X11Drawable protocol. //______________________________________________________________________________ - (BOOL) fIsPixmap @@ -1210,8 +1736,6 @@ - (void) setDrawableSize : (NSSize) newSize //______________________________________________________________________________ - (void) setX : (int) x Y : (int) y width : (unsigned) w height : (unsigned) h { - assert(fParentView != nil && "setX:Y:width:height:, parent view is nil"); - NSRect newFrame = {}; newFrame.origin.x = x; newFrame.origin.y = y; @@ -1224,8 +1748,6 @@ - (void) setX : (int) x Y : (int) y width : (unsigned) w height : (unsigned) h //______________________________________________________________________________ - (void) setX : (int) x Y : (int) y { - assert(fParentView != nil && "setX:Y:, parent view is nil"); - NSRect newFrame = self.frame; newFrame.origin.x = x; newFrame.origin.y = y; @@ -1234,8 +1756,10 @@ - (void) setX : (int) x Y : (int) y } //______________________________________________________________________________ -- (void) copyImage : (QuartzImage *) srcImage area : (Rectangle_t) area withMask : (QuartzImage *) mask clipOrigin : (Point_t) clipXY toPoint : (Point_t) dstPoint +- (void) copyImage : (QuartzImage *) srcImage area : (X11::Rectangle) area withMask : (QuartzImage *) mask clipOrigin : (X11::Point) clipXY toPoint : (X11::Point) dstPoint { + //TODO: test and fix all possible cases with crop area and masks. + //Check parameters. assert(srcImage != nil && "copyImage:area:withMask:clipOrigin:toPoint:, srcImage parameter is nil"); assert(srcImage.fImage != nil && "copyImage:area:withMask:clipOrigin:toPoint:, srcImage.fImage is nil"); @@ -1243,11 +1767,18 @@ - (void) copyImage : (QuartzImage *) srcImage area : (Rectangle_t) area withMask //Check self. assert(self.fContext != 0 && "copyImage:area:withMask:clipOrigin:toPoint:, self.fContext is null"); + if (!X11::AdjustCropArea(srcImage, area)) { + NSLog(@"QuartzView: -copyImage:area:withMask:clipOrigin:toPoint:, srcRect and copyRect do not intersect"); + return; + } + + //No RAII for subImage, since it can be really subimage or image itself and + //in these cases there is no need to release image. CGImageRef subImage = 0; bool needSubImage = false; if (area.fX || area.fY || area.fWidth != srcImage.fWidth || area.fHeight != srcImage.fHeight) { needSubImage = true; - subImage = ROOT::MacOSX::X11::CreateSubImage(srcImage, area); + subImage = X11::CreateSubImage(srcImage, area); if (!subImage) { NSLog(@"QuartzView: -copyImage:area:withMask:clipOrigin:toPoint:, subimage creation failed"); return; @@ -1256,7 +1787,7 @@ - (void) copyImage : (QuartzImage *) srcImage area : (Rectangle_t) area withMask subImage = srcImage.fImage; //Save context state. - CGContextSaveGState(self.fContext); + const Quartz::CGStateGuard ctxGuard(self.fContext); //Scale and translate to undo isFlipped. CGContextTranslateCTM(self.fContext, 0., self.fHeight); @@ -1266,33 +1797,37 @@ - (void) copyImage : (QuartzImage *) srcImage area : (Rectangle_t) area withMask if (mask) { assert(mask.fImage != nil && "copyImage:area:withMask:clipOrigin:toPoint:, mask.fImage is nil"); assert(CGImageIsMask(mask.fImage) == true && "copyImage:area:withMask:clipOrigin:toPoint:, mask.fImage is not a mask"); - clipXY.fY = ROOT::MacOSX::X11::LocalYROOTToCocoa(self, clipXY.fY + mask.fHeight); - const CGRect clipRect = CGRectMake(clipXY.fX, clipXY.fY, mask.fWidth, mask.fHeight); + //clipXY.fY = X11::LocalYROOTToCocoa(self, clipXY.fY + mask.fHeight); + const CGFloat clipY = X11::LocalYROOTToCocoa(self, CGFloat(clipXY.fY) + mask.fHeight); + //const CGRect clipRect = CGRectMake(clipXY.fX, clipXY.fY, mask.fWidth, mask.fHeight); + const CGRect clipRect = CGRectMake(clipXY.fX, clipY, mask.fWidth, mask.fHeight); CGContextClipToMask(self.fContext, clipRect, mask.fImage); } //Convert from X11 to Cocoa (as soon as we scaled y * -1). - dstPoint.fY = ROOT::MacOSX::X11::LocalYROOTToCocoa(self, dstPoint.fY + area.fHeight); - const CGRect imageRect = CGRectMake(dstPoint.fX, dstPoint.fY, area.fWidth, area.fHeight); + //dstPoint.fY = X11::LocalYROOTToCocoa(self, dstPoint.fY + area.fHeight); + const CGFloat dstY = X11::LocalYROOTToCocoa(self, CGFloat(dstPoint.fY) + area.fHeight); + //const CGRect imageRect = CGRectMake(dstPoint.fX, dstPoint.fY, area.fWidth, area.fHeight); + const CGRect imageRect = CGRectMake(dstPoint.fX, dstY, area.fWidth, area.fHeight); CGContextDrawImage(self.fContext, imageRect, subImage); - //Restore context state. - CGContextRestoreGState(self.fContext); - if (needSubImage) CGImageRelease(subImage); } //______________________________________________________________________________ -- (void) copyView : (QuartzView *) srcView area : (Rectangle_t) area toPoint : (Point_t) dstPoint +- (void) copyView : (QuartzView *) srcView area : (X11::Rectangle) area toPoint : (X11::Point) dstPoint { //To copy one "window" to another "window", I have to ask source QuartzView to draw intself into //bitmap, and copy this bitmap into the destination view. + + //TODO: this code must be tested, with all possible cases. assert(srcView != nil && "copyView:area:toPoint:, srcView parameter is nil"); const NSRect frame = [srcView frame]; - NSBitmapImageRep *imageRep = [srcView bitmapImageRepForCachingDisplayInRect : frame]; + //imageRep is in autorelease pool now. + NSBitmapImageRep * const imageRep = [srcView bitmapImageRepForCachingDisplayInRect : frame]; if (!imageRep) { NSLog(@"QuartzView: -copyView:area:toPoint failed"); return; @@ -1311,77 +1846,88 @@ - (void) copyView : (QuartzView *) srcView area : (Rectangle_t) area toPoint : ( srcView.fContext = ctx; const CGRect subImageRect = CGRectMake(area.fX, area.fY, area.fWidth, area.fHeight); - CGImageRef subImage = CGImageCreateWithImageInRect(imageRep.CGImage, subImageRect); + const Util::CFScopeGuard subImage(CGImageCreateWithImageInRect(imageRep.CGImage, subImageRect)); - CGContextSaveGState(self.fContext); + if (!subImage.Get()) { + NSLog(@"QuartzView: -copyView:area:toPoint, CGImageCreateWithImageInRect failed"); + return; + } - const CGRect imageRect = CGRectMake(dstPoint.fX, [self visibleRect].size.height - (dstPoint.fY + area.fHeight), area.fWidth, area.fHeight); + const Quartz::CGStateGuard ctxGuard(self.fContext); + const CGRect imageRect = CGRectMake(dstPoint.fX, [self visibleRect].size.height - (CGFloat(dstPoint.fY) + area.fHeight), area.fWidth, area.fHeight); CGContextTranslateCTM(self.fContext, 0., [self visibleRect].size.height); CGContextScaleCTM(self.fContext, 1., -1.); - CGContextDrawImage(self.fContext, imageRect, subImage); - - //Restore context state. - CGContextRestoreGState(self.fContext); - - //imageRep in autorelease pool now. - CGImageRelease(subImage); + CGContextDrawImage(self.fContext, imageRect, subImage.Get()); } //______________________________________________________________________________ -- (void) copyPixmap : (QuartzPixmap *) srcPixmap area : (Rectangle_t) area withMask : (QuartzImage *) mask clipOrigin : (Point_t) clipXY toPoint : (Point_t) dstPoint +- (void) copyPixmap : (QuartzPixmap *) srcPixmap area : (X11::Rectangle) area withMask : (QuartzImage *) mask clipOrigin : (X11::Point) clipXY toPoint : (X11::Point) dstPoint { - using ROOT::MacOSX::X11::AdjustCropArea; - - //Check parameters. + //Check parameters. assert(srcPixmap != nil && "copyPixmap:area:withMask:clipOrigin:toPoint:, srcPixmap parameter is nil"); - - //More difficult case: pixmap already contains reflected image. - area.fY = ROOT::MacOSX::X11::LocalYROOTToCocoa(srcPixmap, area.fY) - area.fHeight; - - if (!AdjustCropArea(srcPixmap, area)) { - NSLog(@"QuartzView: -copyPixmap:area:withMask:clipOrigin:toPoint, pixmap and copy are no intersection between pixmap rectangle and cropArea"); + + if (!X11::AdjustCropArea(srcPixmap, area)) { + NSLog(@"QuartzView: -copyPixmap:area:withMask:clipOrigin:toPoint, no intersection between pixmap rectangle and cropArea"); return; } - + //Check self. assert(self.fContext != 0 && "copyPixmap:area:withMask:clipOrigin:toPoint:, self.fContext is null"); - - CGImageRef imageFromPixmap = [srcPixmap createImageFromPixmap : area]; - assert(imageFromPixmap != nil && "copyPixmap:area:withMask:clipOrigin:toPoint:, createImageFromPixmap failed"); //Save context state. - CGContextSaveGState(self.fContext); + const Quartz::CGStateGuard ctxGuard(self.fContext); + + CGContextTranslateCTM(self.fContext, 0., self.frame.size.height);//??? + CGContextScaleCTM(self.fContext, 1., -1.); + + const Util::CFScopeGuard imageFromPixmap([srcPixmap createImageFromPixmap]); + assert(imageFromPixmap.Get() != 0 && "copyPixmap:area:withMask:clipOrigin:toPoint:, createImageFromPixmap failed"); + + CGImageRef subImage = 0; + bool needSubImage = false; + if (area.fX || area.fY || area.fWidth != srcPixmap.fWidth || area.fHeight != srcPixmap.fHeight) { + needSubImage = true; + const CGRect subImageRect = CGRectMake(area.fX, area.fY, area.fHeight, area.fWidth); + subImage = CGImageCreateWithImageInRect(imageFromPixmap.Get(), subImageRect); + if (!subImage) { + NSLog(@"QuartzView: -copyImage:area:withMask:clipOrigin:toPoint:, subimage creation failed"); + return; + } + } else + subImage = imageFromPixmap.Get(); if (mask) { + //TODO: testtesttest!!! assert(mask.fImage != nil && "copyPixmap:area:withMask:clipOrigin:toPoint:, mask.fImage is nil"); assert(CGImageIsMask(mask.fImage) == true && "copyPixmap:area:withMask:clipOrigin:toPoint:, mask.fImage is not a mask"); - const CGRect clipRect = CGRectMake(clipXY.fX, clipXY.fY, mask.fWidth, mask.fHeight); + //clipXY.fY = X11::LocalYROOTToCocoa(self, clipXY.fY + mask.fHeight); + const CGFloat clipY = X11::LocalYROOTToCocoa(self, CGFloat(clipXY.fY) + mask.fHeight); + //const CGRect clipRect = CGRectMake(clipXY.fX, clipXY.fY, mask.fWidth, mask.fHeight); + const CGRect clipRect = CGRectMake(clipXY.fX, clipY, mask.fWidth, mask.fHeight); CGContextClipToMask(self.fContext, clipRect, mask.fImage); } - const CGRect imageRect = CGRectMake(dstPoint.fX, dstPoint.fY, area.fWidth, area.fHeight); - CGContextDrawImage(self.fContext, imageRect, imageFromPixmap); - - //Restore context state. - CGContextRestoreGState(self.fContext); + //dstPoint.fY = X11::LocalYCocoaToROOT(self, dstPoint.fY + area.fHeight); + const CGFloat dstY = X11::LocalYCocoaToROOT(self, CGFloat(dstPoint.fY) + area.fHeight); + const CGRect imageRect = CGRectMake(dstPoint.fX, dstY, area.fWidth, area.fHeight); + CGContextDrawImage(self.fContext, imageRect, imageFromPixmap.Get()); - CGImageRelease(imageFromPixmap); + if (needSubImage) + CGImageRelease(subImage); } //______________________________________________________________________________ -- (void) copyImage : (QuartzImage *) srcImage area : (Rectangle_t) area toPoint : (Point_t) dstPoint +- (void) copyImage : (QuartzImage *) srcImage area : (X11::Rectangle) area toPoint : (X11::Point) dstPoint { - using ROOT::MacOSX::X11::AdjustCropArea; - assert(srcImage != nil && "copyImage:area:toPoint:, srcImage parameter is nil"); assert(srcImage.fImage != nil && "copyImage:area:toPoint:, srcImage.fImage is nil"); assert(self.fContext != 0 && "copyImage:area:toPoint:, fContext is null"); - if (!AdjustCropArea(srcImage, area)) { + if (!X11::AdjustCropArea(srcImage, area)) { NSLog(@"QuartzView: -copyImage:area:toPoint, image and copy area do not intersect"); return; } @@ -1390,7 +1936,7 @@ - (void) copyImage : (QuartzImage *) srcImage area : (Rectangle_t) area toPoint bool needSubImage = false; if (area.fX || area.fY || area.fWidth != srcImage.fWidth || area.fHeight != srcImage.fHeight) { needSubImage = true; - subImage = ROOT::MacOSX::X11::CreateSubImage(srcImage, area); + subImage = X11::CreateSubImage(srcImage, area); if (!subImage) { NSLog(@"QuartzView: -copyImage:area:toPoint:, subimage creation failed"); return; @@ -1398,29 +1944,30 @@ - (void) copyImage : (QuartzImage *) srcImage area : (Rectangle_t) area toPoint } else subImage = srcImage.fImage; - CGContextSaveGState(self.fContext); + const Quartz::CGStateGuard ctxGuard(self.fContext); CGContextTranslateCTM(self.fContext, 0., self.fHeight); CGContextScaleCTM(self.fContext, 1., -1.); - dstPoint.fY = ROOT::MacOSX::X11::LocalYCocoaToROOT(self, dstPoint.fY + area.fHeight); - const CGRect imageRect = CGRectMake(dstPoint.fX, dstPoint.fY, area.fWidth, area.fHeight); + //dstPoint.fY = X11::LocalYCocoaToROOT(self, dstPoint.fY + area.fHeight); + const CGFloat dstY = X11::LocalYCocoaToROOT(self, CGFloat(dstPoint.fY) + area.fHeight); + //const CGRect imageRect = CGRectMake(dstPoint.fX, dstPoint.fY, area.fWidth, area.fHeight); + const CGRect imageRect = CGRectMake(dstPoint.fX, dstY, area.fWidth, area.fHeight); CGContextDrawImage(self.fContext, imageRect, subImage); - - CGContextRestoreGState(self.fContext); if (needSubImage) CGImageRelease(subImage); } //______________________________________________________________________________ -- (void) copy : (NSObject *) src area : (Rectangle_t) area withMask : (QuartzImage *)mask clipOrigin : (Point_t) clipXY toPoint : (Point_t) dstPoint +- (void) copy : (NSObject *) src area : (X11::Rectangle) area withMask : (QuartzImage *)mask clipOrigin : (X11::Point) clipXY toPoint : (X11::Point) dstPoint { assert(src != nil && "copy:area:withMask:clipOrigin:toPoint:, src parameter is nil"); + assert(area.fWidth && area.fHeight && "copy:area:withMask:clipOrigin:toPoint:, area to copy is empty"); if ([src isKindOfClass : [QuartzWindow class]]) { //Forget about mask (can I have it???) - QuartzWindow *qw = (QuartzWindow *)src; + QuartzWindow * const qw = (QuartzWindow *)src; //Will not work with OpenGL. [self copyView : (QuartzView *)qw.fContentView area : area toPoint : dstPoint]; } else if ([src isKindOfClass : [QuartzView class]]) { @@ -1436,28 +1983,22 @@ - (void) copy : (NSObject *) src area : (Rectangle_t) area withMask } //______________________________________________________________________________ -- (unsigned char *) readColorBits : (Rectangle_t) area +- (unsigned char *) readColorBits : (X11::Rectangle) area { - //TODO: make the part, reading pixels - //from NSBitmapImageRep not so lame. - - using ROOT::MacOSX::X11::AdjustCropArea; + // + assert(area.fWidth && area.fHeight && "readColorBits:, area to copy is empty"); const NSRect visRect = [self visibleRect]; - Rectangle_t srcRect = {}; - srcRect.fX = visRect.origin.x; - srcRect.fY = visRect.origin.y; - srcRect.fWidth = visRect.size.width; - srcRect.fHeight = visRect.size.height; + const X11::Rectangle srcRect(int(visRect.origin.x), int(visRect.origin.y), unsigned(visRect.size.width), unsigned(visRect.size.height)); - if (!AdjustCropArea(srcRect, area)) { + if (!X11::AdjustCropArea(srcRect, area)) { NSLog(@"QuartzView: -readColorBits:, visible rect of view and copy area do not intersect"); return 0; } - NSBitmapImageRep *imageRep = [self bitmapImageRepForCachingDisplayInRect : visRect]; + NSBitmapImageRep * const imageRep = [self bitmapImageRepForCachingDisplayInRect : visRect];//imageRect is autoreleased. if (!imageRep) { - NSLog(@"QuartzView: -readColorBits: failed"); + NSLog(@"QuartzView: -readColorBits:, bitmapImageRepForCachingDisplayInRect failed"); return 0; } @@ -1467,7 +2008,15 @@ - (unsigned char *) readColorBits : (Rectangle_t) area // const unsigned char *srcData = [imageRep bitmapData]; //We have a source data now. Let's allocate buffer for ROOT's GUI and convert source data. - unsigned char *data = new unsigned char[area.fWidth * area.fHeight * 4];//bgra? + unsigned char *data = 0; + + try { + data = new unsigned char[area.fWidth * area.fHeight * 4];//bgra? + } catch (const std::bad_alloc &) { + NSLog(@"QuartzView: -readColorBits:, memory allocation failed"); + return 0; + } + const NSInteger bitsPerPixel = [imageRep bitsPerPixel]; //TODO: ohhh :((( assert(bitsPerPixel == 32 && "-readColorBits:, no alpha channel???"); @@ -1479,8 +2028,8 @@ - (unsigned char *) readColorBits : (Rectangle_t) area const unsigned char *line = srcData + area.fY * dataWidth * 4; const unsigned char *srcPixel = line + area.fX * 4; - for (UShort_t i = 0; i < area.fHeight; ++i) { - for (UShort_t j = 0; j < area.fWidth; ++j, srcPixel += 4, dstPixel += 4) { + for (unsigned i = 0; i < area.fHeight; ++i) { + for (unsigned j = 0; j < area.fWidth; ++j, srcPixel += 4, dstPixel += 4) { dstPixel[0] = srcPixel[2]; dstPixel[1] = srcPixel[1]; dstPixel[2] = srcPixel[0]; @@ -1494,6 +2043,27 @@ - (unsigned char *) readColorBits : (Rectangle_t) area return data; } + +//______________________________________________________________________________ +- (void) setFBackgroundPixmap : (QuartzImage *) pixmap +{ + if (fBackgroundPixmap != pixmap) { + [fBackgroundPixmap release]; + if (pixmap) + fBackgroundPixmap = [pixmap retain]; + else + fBackgroundPixmap = nil; + } +} + +//______________________________________________________________________________ +- (QuartzImage *) fBackgroundPixmap +{ + //I do not autorelease, screw this idiom! + + return fBackgroundPixmap; +} + //______________________________________________________________________________ - (int) fMapState { @@ -1508,6 +2078,25 @@ - (int) fMapState return kIsViewable; } +//______________________________________________________________________________ +- (QuartzPixmap *) fBackBuffer +{ + return fBackBuffer;//No autorelease, I know the object's lifetime myself. +} + +//______________________________________________________________________________ +- (void) setFBackBuffer : (QuartzPixmap *) backBuffer +{ + if (fBackBuffer != backBuffer) { + [fBackBuffer release]; + + if (backBuffer) + fBackBuffer = [backBuffer retain]; + else + fBackBuffer = nil; + } +} + //______________________________________________________________________________ - (NSView *) fContentView { @@ -1520,6 +2109,51 @@ - (QuartzWindow *) fQuartzWindow return (QuartzWindow *)[self window]; } +//______________________________________________________________________________ +- (void) activatePassiveGrab +{ + fCurrentGrabType = X11::kPGPassiveGrab; +} + +//______________________________________________________________________________ +- (void) activateImplicitGrab +{ + fCurrentGrabType = X11::kPGImplicitGrab; +} + +//______________________________________________________________________________ +- (void) activateGrab : (unsigned) eventMask ownerEvents : (BOOL) ownerEvents +{ + fCurrentGrabType = X11::kPGActiveGrab; + fActiveGrabEventMask = eventMask; + fActiveGrabOwnerEvents = ownerEvents; +} + +//______________________________________________________________________________ +- (void) cancelGrab +{ + fCurrentGrabType = X11::kPGNoGrab; + fActiveGrabEventMask = 0; + fActiveGrabOwnerEvents = YES; +} + +//______________________________________________________________________________ +- (BOOL) acceptsCrossingEvents : (unsigned) eventMask +{ + bool accepts = fEventMask & eventMask; + if (fCurrentGrabType == X11::kPGPassiveGrab)//In ROOT passive grabs are always with owner_events == true. + accepts = accepts || (fPassiveGrabEventMask & eventMask); + + if (fCurrentGrabType == X11::kPGActiveGrab) { + if (fActiveGrabOwnerEvents) + accepts = accepts || (fActiveGrabOwnerEvents & eventMask); + else + accepts = fActiveGrabOwnerEvents & eventMask; + } + + return accepts; +} + //______________________________________________________________________________ - (void) addChild : (NSView *) child { @@ -1527,7 +2161,6 @@ - (void) addChild : (NSView *) child [self addSubview : child]; child.fParentView = self; - [child updateLevel : self.fLevel + 1]; } //______________________________________________________________________________ @@ -1535,7 +2168,7 @@ - (void) getAttributes : (WindowAttributes_t *)attr { assert(attr != 0 && "getAttributes, attr parameter is null"); - ROOT::MacOSX::X11::GetWindowAttributes(self, attr); + X11::GetWindowAttributes(self, attr); } //______________________________________________________________________________ @@ -1547,14 +2180,14 @@ - (void) setAttributes : (const SetWindowAttributes_t *)attr log_attributes(attr, fID); #endif - ROOT::MacOSX::X11::SetWindowAttributes(attr, self); + X11::SetWindowAttributes(attr, self); } //______________________________________________________________________________ - (void) mapRaised { //Move view to the top of subviews (in UIKit there is a special method). - QuartzView *parent = fParentView; + QuartzView * const parent = fParentView; [self removeFromSuperview]; [parent addSubview : self]; [self setHidden : NO]; @@ -1571,7 +2204,7 @@ - (void) mapSubwindows { for (QuartzView * v in [self subviews]) { [v setHidden : NO]; - [v mapSubwindows]; + //[v mapSubwindows]; } } @@ -1598,35 +2231,54 @@ - (void) setOverlapped : (BOOL) overlap //______________________________________________________________________________ - (void) raiseWindow { - using namespace ROOT::MacOSX::X11;//Comparators. + using namespace X11;//Comparators. for (QuartzView *sibling in [fParentView subviews]) { if (self == sibling) continue; + if ([sibling isHidden]) + continue; //TODO: equal test is not good :) I have a baaad feeling about this ;) - if (CGRectEqualToRect(sibling.frame, self.frame)) + if (CGRectEqualToRect(sibling.frame, self.frame)) { [sibling setOverlapped : YES]; + // + [sibling setHidden : YES]; + // + } } [self setOverlapped : NO]; + // + [self setHidden : NO]; + // [fParentView sortSubviewsUsingFunction : CompareViewsToRaise context : (void *)self]; + // + [self updateTrackingAreasAfterRaise]; + // [self setNeedsDisplay : YES];//? } //______________________________________________________________________________ - (void) lowerWindow { - using namespace ROOT::MacOSX::X11; + using namespace X11; - NSEnumerator *reverseEnumerator = [[fParentView subviews] reverseObjectEnumerator]; + NSEnumerator * const reverseEnumerator = [[fParentView subviews] reverseObjectEnumerator]; for (QuartzView *sibling in reverseEnumerator) { if (sibling == self) continue; + //TODO: equal test is not good :) I have a baaad feeling about this ;) if (CGRectEqualToRect(sibling.frame, self.frame)) { [sibling setOverlapped : NO]; + // + [sibling setHidden : NO]; + // [sibling setNeedsDisplay : YES]; [self setOverlapped : YES]; + // + [self setHidden : YES]; + // break; } } @@ -1634,15 +2286,6 @@ - (void) lowerWindow [fParentView sortSubviewsUsingFunction : CompareViewsToLower context : (void*)self];//NO ARC! No __bridge! } -//______________________________________________________________________________ -- (void) updateLevel : (unsigned) newLevel -{ - fLevel = newLevel; - - for (QuartzView *child in [self subviews]) - [child updateLevel : fLevel + 1]; -} - //______________________________________________________________________________ - (BOOL) isFlipped { @@ -1654,9 +2297,9 @@ - (BOOL) isFlipped //______________________________________________________________________________ - (void) configureNotifyTree { - if (self.fMapState == kIsViewable) { + if (self.fMapState == kIsViewable || fIsOverlapped == YES) { if (fEventMask & kStructureNotifyMask) { - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx && "configureNotifyTree, gVirtualX is either null or has type different from TGCocoa"); vx->GetEventTranslator()->GenerateConfigureNotifyEvent(self, self.frame); } @@ -1670,9 +2313,9 @@ - (void) configureNotifyTree //______________________________________________________________________________ - (void) addPassiveKeyGrab : (unichar) keyCode modifiers : (NSUInteger) modifiers { - //Remove and add (not to traverse twice). + //TODO: why am I removing the old one??? :) [self removePassiveKeyGrab : keyCode modifiers : modifiers]; - PassiveKeyGrab *newGrab = [[PassiveKeyGrab alloc] initWithKey : keyCode modifiers : modifiers]; + PassiveKeyGrab * const newGrab = [[PassiveKeyGrab alloc] initWithKey : keyCode modifiers : modifiers]; [fPassiveKeyGrabs addObject : newGrab]; [newGrab release]; } @@ -1693,7 +2336,7 @@ - (void) removePassiveKeyGrab : (unichar) keyCode modifiers : (NSUInteger) modif //______________________________________________________________________________ - (PassiveKeyGrab *) findPassiveKeyGrab : (unichar) keyCode modifiers : (NSUInteger) modifiers { - NSEnumerator *enumerator = [fPassiveKeyGrabs objectEnumerator]; + NSEnumerator * const enumerator = [fPassiveKeyGrabs objectEnumerator]; while (PassiveKeyGrab *grab = (PassiveKeyGrab *)[enumerator nextObject]) { if ([grab matchKey : keyCode modifiers : modifiers]) return grab; @@ -1706,7 +2349,7 @@ - (PassiveKeyGrab *) findPassiveKeyGrab : (unichar) keyCode modifiers : (NSUInte - (PassiveKeyGrab *) findPassiveKeyGrab : (unichar) keyCode { //Do not check modifiers. - NSEnumerator *enumerator = [fPassiveKeyGrabs objectEnumerator]; + NSEnumerator * const enumerator = [fPassiveKeyGrabs objectEnumerator]; while (PassiveKeyGrab *grab = (PassiveKeyGrab *)[enumerator nextObject]) { if ([grab matchKey : keyCode]) return grab; @@ -1720,25 +2363,29 @@ - (PassiveKeyGrab *) findPassiveKeyGrab : (unichar) keyCode //______________________________________________________________________________ - (void) drawRect : (NSRect) dirtyRect { - using namespace ROOT::MacOSX::X11; + using namespace X11; (void)dirtyRect; if (fID) { - if (TGWindow *window = gClient->GetWindowById(fID)) { - if (ViewIsTextViewFrame(self, true))//It's never painted, parent renders child. true == check the parent also. + if (TGWindow * const window = gClient->GetWindowById(fID)) { + if (ViewIsTextViewFrame(self, true) ||ViewIsHtmlViewFrame(self, true))//It's never painted, parent renders child. true == check the parent also. return; - NSGraphicsContext *nsContext = [NSGraphicsContext currentContext]; + NSGraphicsContext * const nsContext = [NSGraphicsContext currentContext]; assert(nsContext != nil && "drawRect, currentContext returned nil"); - TGCocoa *vx = (TGCocoa *)gVirtualX; + TGCocoa * const vx = (TGCocoa *)gVirtualX; vx->CocoaDrawON(); fContext = (CGContextRef)[nsContext graphicsPort]; assert(fContext != 0 && "drawRect, graphicsPort returned null"); - - CGContextSaveGState(fContext); + + const Quartz::CGStateGuard ctxGuard(fContext); + + //Non-rectangular windows. + if (self.fQuartzWindow.fShapeCombineMask) + X11::ClipToShapeMask(self, fContext); if (window->InheritsFrom("TGContainer"))//It always has an ExposureMask. vx->GetEventTranslator()->GenerateExposeEvent(self, [self visibleRect]); @@ -1746,15 +2393,22 @@ - (void) drawRect : (NSRect) dirtyRect if (fEventMask & kExposureMask) { if (ViewIsTextView(self)) { //Send Expose event, using child view (this is how it's done in GUI :( ). - NSView *viewFrame = FrameForTextView(self); + NSView * const viewFrame = FrameForTextView(self); if (viewFrame) vx->GetEventTranslator()->GenerateExposeEvent(viewFrame, [viewFrame visibleRect]);//Now we set fExposedRegion for TGView. } + + if (ViewIsHtmlView(self)) { + //TODO: remove code duplication here. + NSView *const viewFrame = FrameForHtmlView(self); + if (viewFrame) + vx->GetEventTranslator()->GenerateExposeEvent(viewFrame, [viewFrame visibleRect]); + } //Ask ROOT's widget/window to draw itself. gClient->NeedRedraw(window, kTRUE); - if (!fSnapshotDraw && !ViewIsTextView(self)) { + if (!fSnapshotDraw && !ViewIsTextView(self) && !ViewIsHtmlView(self)) { //If Cocoa repaints widget, cancel all ROOT's "outside of paint event" //rendering into this widget ... Except it's a text view :) gClient->CancelRedraw(window); @@ -1764,15 +2418,11 @@ - (void) drawRect : (NSRect) dirtyRect if (fBackBuffer) { //Very "special" window. - CGImageRef image = [fBackBuffer createImageFromPixmap];// CGBitmapContextCreateImage(fBackBuffer.fContext); - if (image) { - const CGRect imageRect = CGRectMake(0, 0, fBackBuffer.fWidth, fBackBuffer.fHeight); - CGContextDrawImage(fContext, imageRect, image); - CGImageRelease(image); - } - } + const X11::Rectangle copyArea(0, 0, fBackBuffer.fWidth, fBackBuffer.fHeight); - CGContextRestoreGState(fContext); + [self copy : fBackBuffer area : copyArea withMask : nil clipOrigin : X11::Point() toPoint : X11::Point()]; + } + vx->CocoaDrawOFF(); #ifdef DEBUG_ROOT_COCOA CGContextSetRGBStrokeColor(fContext, 1., 0., 0., 1.); @@ -1809,8 +2459,8 @@ - (void) setFrameSize : (NSSize) newSize [super setFrameSize : newSize]; - if ((fEventMask & kStructureNotifyMask) && self.fMapState == kIsViewable) { - TGCocoa *vx = dynamic_cast(gVirtualX); + if ((fEventMask & kStructureNotifyMask) && (self.fMapState == kIsViewable || fIsOverlapped == YES)) { + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "setFrameSize:, gVirtualX is either null or has a type, different from TGCocoa"); vx->GetEventTranslator()->GenerateConfigureNotifyEvent(self, self.frame); } @@ -1823,7 +2473,7 @@ - (void) mouseDown : (NSEvent *) theEvent { assert(fID != 0 && "mouseDown, fID is 0"); - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "mouseDown, gVirtualX is either null or has a type, different from TGCocoa"); vx->GetEventTranslator()->GenerateButtonPressEvent(self, theEvent, kButton1); } @@ -1833,7 +2483,7 @@ - (void) scrollWheel : (NSEvent*) theEvent { assert(fID != 0 && "scrollWheel, fID is 0"); - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "scrollWheel, gVirtualX is either null or has a type, different from TGCocoa"); const CGFloat deltaY = [theEvent deltaY]; @@ -1851,7 +2501,7 @@ - (void) scrollWheel : (NSEvent*) theEvent - (void) printViewInformation { assert(fID != 0 && "printWindowInformation, fID is 0"); - TGWindow *window = gClient->GetWindowById(fID); + const TGWindow * const window = gClient->GetWindowById(fID); assert(window != 0 && "printWindowInformation, window not found"); NSLog(@"-----------------View %u info:---------------------", fID); @@ -1859,7 +2509,8 @@ - (void) printViewInformation NSLog(@"event mask is:"); print_mask_info(fEventMask); NSLog(@"grab mask is:"); - print_mask_info(fGrabButtonEventMask); + print_mask_info(fPassiveGrabEventMask); + NSLog(@"view's geometry: x == %g, y == %g, w == %g, h == %g", self.frame.origin.x, self.frame.origin.y, self.frame.size.width, self.frame.size.height); NSLog(@"----------------End of view info------------------"); } #endif @@ -1873,17 +2524,33 @@ - (void) rightMouseDown : (NSEvent *) theEvent [self printViewInformation]; #endif - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "rightMouseDown, gVirtualX is either null or has type different from TGCocoa"); vx->GetEventTranslator()->GenerateButtonPressEvent(self, theEvent, kButton3); } +//______________________________________________________________________________ +- (void) otherMouseDown : (NSEvent *) theEvent +{ + assert(fID != 0 && "otherMouseDown, fID is 0"); + + //Funny enough, [theEvent buttonNumber] is not the same thing as button masked in [NSEvent pressedMouseButtons], + //button number actually is a kind of right operand for bitshift for pressedMouseButtons. + if ([theEvent buttonNumber] == 2) {//this '2' will correspond to '4' in pressedMouseButtons. + //I do not care about mouse buttons after left/right/wheel - ROOT does not have + //any code for this. + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx != 0 && "otherMouseDown, gVirtualX is either null or has type different from TGCocoa"); + vx->GetEventTranslator()->GenerateButtonPressEvent(self, theEvent, kButton2); + } +} + //______________________________________________________________________________ - (void) mouseUp : (NSEvent *) theEvent { assert(fID != 0 && "mouseUp, fID is 0"); - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx && "mouseUp, gVirtualX is either null or has type different from TGCocoa"); vx->GetEventTranslator()->GenerateButtonReleaseEvent(self, theEvent, kButton1); } @@ -1894,8 +2561,19 @@ - (void) rightMouseUp : (NSEvent *) theEvent assert(fID != 0 && "rightMouseUp, fID is 0"); - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "rightMouseUp, gVirtualX is either null or has type different from TGCocoa"); + vx->GetEventTranslator()->GenerateButtonReleaseEvent(self, theEvent, kButton3); +} + +//______________________________________________________________________________ +- (void) otherMouseUp : (NSEvent *) theEvent +{ + assert(fID != 0 && "otherMouseUp, fID is 0"); + + //Here I assume it's always kButton2. + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx != 0 && "otherMouseUp, gVirtualX is either null or has type different from TGCocoa"); vx->GetEventTranslator()->GenerateButtonReleaseEvent(self, theEvent, kButton2); } @@ -1903,11 +2581,11 @@ - (void) rightMouseUp : (NSEvent *) theEvent - (void) mouseEntered : (NSEvent *) theEvent { assert(fID != 0 && "mouseEntered, fID is 0"); - - TGCocoa *vx = dynamic_cast(gVirtualX); + + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "mouseEntered, gVirtualX is null or not of TGCocoa type"); - vx->GetEventTranslator()->GenerateCrossingEvent(self, theEvent); + vx->GetEventTranslator()->GenerateCrossingEvent(theEvent); } //______________________________________________________________________________ @@ -1915,10 +2593,10 @@ - (void) mouseExited : (NSEvent *) theEvent { assert(fID != 0 && "mouseExited, fID is 0"); - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "mouseExited, gVirtualX is null or not of TGCocoa type"); - vx->GetEventTranslator()->GenerateCrossingEvent(self, theEvent); + vx->GetEventTranslator()->GenerateCrossingEvent(theEvent); } //______________________________________________________________________________ @@ -1932,7 +2610,7 @@ - (void) mouseMoved : (NSEvent *) theEvent TGCocoa *vx = dynamic_cast(gVirtualX); assert(vx != 0 && "mouseMoved, gVirtualX is null or not of TGCocoa type"); - vx->GetEventTranslator()->GeneratePointerMotionEvent(self, theEvent); + vx->GetEventTranslator()->GeneratePointerMotionEvent(theEvent); } //______________________________________________________________________________ @@ -1940,10 +2618,10 @@ - (void) mouseDragged : (NSEvent *)theEvent { assert(fID != 0 && "mouseDragged, fID is 0"); - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != 0 && "mouseMoved, gVirtualX is null or not of TGCocoa type"); + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx != 0 && "mouseDragged, gVirtualX is null or not of TGCocoa type"); - vx->GetEventTranslator()->GeneratePointerMotionEvent(self, theEvent); + vx->GetEventTranslator()->GeneratePointerMotionEvent(theEvent); } //______________________________________________________________________________ @@ -1951,10 +2629,22 @@ - (void) rightMouseDragged : (NSEvent *)theEvent { assert(fID != 0 && "rightMouseDragged, fID is 0"); - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != 0 && "rightMouseMoved, gVirtualX is null or not of TGCocoa type"); + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx != 0 && "rightMouseDragged, gVirtualX is null or not of TGCocoa type"); - vx->GetEventTranslator()->GeneratePointerMotionEvent(self, theEvent); + vx->GetEventTranslator()->GeneratePointerMotionEvent(theEvent); +} + +//______________________________________________________________________________ +- (void) otherMouseDragged : (NSEvent *)theEvent +{ + assert(fID != 0 && "otherMouseDragged, fID is 0"); + + if ([theEvent buttonNumber] == 2) { + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx != 0 && "otherMouseDragged, gVirtualX is null or not of TGCocoa type"); + vx->GetEventTranslator()->GeneratePointerMotionEvent(theEvent); + } } //______________________________________________________________________________ @@ -1962,15 +2652,20 @@ - (void) keyDown:(NSEvent *)theEvent { assert(fID != 0 && "keyDown, fID is 0"); - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "keyDown, gVirtualX is null or not of TGCocoa type"); vx->GetEventTranslator()->GenerateKeyPressEvent(self, theEvent); } //______________________________________________________________________________ -- (void) keyUp:(NSEvent *)theEvent +- (void) keyUp : (NSEvent *) theEvent { - (void)theEvent; + assert(fID != 0 && "keyUp, fID is 0"); + + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx != 0 && "keyUp, gVirtualX is null or not of TGCocoa type"); + vx->GetEventTranslator()->GenerateKeyReleaseEvent(self, theEvent); + } //First responder staff. @@ -1988,25 +2683,28 @@ - (BOOL) acceptsFirstResponder return YES; } +/* //______________________________________________________________________________ - (BOOL) becomeFirstResponder { - //Change focus. - NSView *focusView = nil; - for (NSView *view = self; view; view = view.fParentView) { - if (view.fEventMask & kFocusChangeMask) { - focusView = view; - break; + if (!fOverrideRedirect) { + //Change focus. + NSView *focusView = nil; + for (NSView *view = self; view; view = view.fParentView) { + if (view.fEventMask & kFocusChangeMask) { + focusView = view; + break; + } } - } - if (!focusView) - focusView = ((QuartzWindow *)[self window]).fContentView; + if (!focusView) + focusView = ((QuartzWindow *)[self window]).fContentView; + + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx != 0 && "becomeFirstResponder, gVirtualX is null or not of TGCocoa type"); + vx->GetEventTranslator()->GenerateFocusChangeEvent(focusView); + } - TGCocoa *vx = dynamic_cast(gVirtualX); - assert(vx != 0 && "becomeFirstResponder, gVirtualX is null or not of TGCocoa type"); - vx->GetEventTranslator()->GenerateFocusChangeEvent(focusView); - return YES; } @@ -2018,7 +2716,7 @@ - (BOOL) resignFirstResponder //NSResponder returns YES, so do I. return YES; } - +*/ //Cursors. //______________________________________________________________________________ @@ -2048,6 +2746,9 @@ - (NSCursor *) createCustomCursor case kArrowRight: pngFileName = "right_arrow_cursor.png"; break; + case kRotate: + pngFileName = "rotate.png"; + break; case kBottomLeft: case kTopRight: pngFileName = "top_right_cursor.png"; @@ -2060,24 +2761,23 @@ - (NSCursor *) createCustomCursor } if (pngFileName) { - const char *path = gSystem->Which("$ROOTSYS/icons", pngFileName, kReadPermission);//This must be deleted. + const char * const path = gSystem->Which("$ROOTSYS/icons", pngFileName, kReadPermission);//This must be deleted. + const Util::ScopedArray arrayGuard(path); if (!path || path[0] == 0) { //File was not found. - delete [] path; return nil; } NSString *nsPath = [NSString stringWithFormat : @"%s", path];//in autorelease pool. - delete [] path; + NSImage * const cursorImage = [[NSImage alloc] initWithContentsOfFile : nsPath];//must call release. - NSImage *cursorImage = [[NSImage alloc] initWithContentsOfFile : nsPath];//must call release. if (!cursorImage) return nil; - - NSPoint hotSpot = ROOT::MacOSX::X11::GetCursorHotStop(cursorImage, fCurrentCursor); - NSCursor *customCursor = [[[NSCursor alloc] initWithImage : cursorImage hotSpot : hotSpot] autorelease];//in autorelease pool. + + NSPoint hotSpot = X11::GetCursorHotStop(cursorImage, fCurrentCursor); + NSCursor * const customCursor = [[[NSCursor alloc] initWithImage : cursorImage hotSpot : hotSpot] autorelease];//in autorelease pool. [cursorImage release]; @@ -2136,4 +2836,179 @@ - (void) resetCursorRects [super resetCursorRects]; } +//______________________________________________________________________________ +- (void) setProperty : (const char *) propName data : (unsigned char *) propData size : (unsigned) dataSize forType : (Atom_t) dataType format : (unsigned) format +{ + assert(propName != 0 && "setProperty:data:size:forType:, propName parameter is null"); + assert(propData != 0 && "setProperty:data:size:forType:, propData parameter is null"); + assert(dataSize != 0 && "setProperty:data:size:forType:, dataSize parameter is 0"); + + NSString * const key = [NSString stringWithCString : propName encoding : NSASCIIStringEncoding]; + QuartzWindowProperty * property = (QuartzWindowProperty *)[fX11Properties valueForKey : key]; + + //At the moment (and I think this will never change) TGX11 always calls XChangeProperty with PropModeReplace. + if (property) + [property resetPropertyData : propData size : dataSize type : dataType format : format]; + else { + //No property found, add a new one. + property = [[QuartzWindowProperty alloc] initWithData : propData size : dataSize type : dataType format : format]; + [fX11Properties setObject : property forKey : key]; + [property release]; + } +} + +//______________________________________________________________________________ +- (BOOL) hasProperty : (const char *) propName +{ + assert(propName != 0 && "hasProperty, propName parameter is null"); + + NSString * const key = [NSString stringWithCString : propName encoding : NSASCIIStringEncoding]; + QuartzWindowProperty * const property = (QuartzWindowProperty *)[fX11Properties valueForKey : key]; + + return property != nil; +} + +//______________________________________________________________________________ +- (unsigned char *) getProperty : (const char *) propName returnType : (Atom_t *) type + returnFormat : (unsigned *) format nElements : (unsigned *) nElements +{ + assert(propName != 0 && "getProperty:returnType:returnFormat:nElements, propName parameter is null"); + assert(type != 0 && "getProperty:returnType:returnFormat:nElements, type parameter is null"); + assert(format != 0 && "getProperty:returnType:returnFormat:nElements, format parameter is null"); + assert(nElements != 0 && "getProperty:returnType:returnFormat:nElements, nElements parameter is null"); + + NSString * const key = [NSString stringWithCString : propName encoding : NSASCIIStringEncoding]; + QuartzWindowProperty * const property = (QuartzWindowProperty *)[fX11Properties valueForKey : key]; + assert(property != 0 && "getProperty:returnType:returnFormat:nElements, property not found"); + + NSData * const propData = property.fPropertyData; + + const NSUInteger dataSize = [propData length]; + unsigned char *buff = 0; + try { + buff = new unsigned char[dataSize](); + } catch (const std::bad_alloc &) { + NSLog(@"QuartzWindow: -getProperty:returnType:returnFormat:nElements, memory allocation failed");//Hmm, can I log, if new failed? :) + return 0; + } + + [propData getBytes : buff length : dataSize]; + *format = property.fFormat; + + *nElements = dataSize; + + if (*format == 16) + *nElements= dataSize / 2; + else if (*format == 32) + *nElements = dataSize / 4; + + *type = property.fType; + + return buff; +} + +//______________________________________________________________________________ +- (void) removeProperty : (const char *) propName +{ + assert(propName != 0 && "removeProperty:, propName parameter is null"); + + NSString * const key = [NSString stringWithCString : propName encoding : NSASCIIStringEncoding]; + [fX11Properties removeObjectForKey : key]; +} + +//DND +//______________________________________________________________________________ +- (NSDragOperation) draggingEntered : (id) sender +{ + NSPasteboard * const pasteBoard = [sender draggingPasteboard]; + const NSDragOperation sourceDragMask = [sender draggingSourceOperationMask]; + + if ([[pasteBoard types] containsObject : NSFilenamesPboardType] && (sourceDragMask & NSDragOperationCopy)) + return NSDragOperationCopy; + + return NSDragOperationNone; +} + +//______________________________________________________________________________ +- (BOOL) performDragOperation : (id) sender +{ + //We can drag some files (images, pdfs, source code files) from + //finder to ROOT's window (mainly TCanvas or text editor). + //The logic is totally screwed here :((( - ROOT will try to + //read a property of some window (not 'self', unfortunately) - + //this works since on Window all data is in a global clipboard + //(on X11 it simply does not work at all). + //I'm attaching the file name as a property for the top level window, + //there is no other way to make this data accessible for ROOT. + + NSPasteboard * const pasteBoard = [sender draggingPasteboard]; + const NSDragOperation sourceDragMask = [sender draggingSourceOperationMask]; + + if ([[pasteBoard types] containsObject : NSFilenamesPboardType] && (sourceDragMask & NSDragOperationCopy)) { + + //Here I try to put string ("file://....") into window's property to make + //it accesible from ROOT's GUI. + const Atom_t textUriAtom = gVirtualX->InternAtom("text/uri-list", kFALSE); + + NSArray * const files = [pasteBoard propertyListForType : NSFilenamesPboardType]; + for (NSString *path in files) { + //ROOT can not process several files, use the first one. + NSString * const item = [@"file://" stringByAppendingString : path]; + //Yes, only ASCII encoding, but after all, ROOT's not able to work with NON-ASCII strings. + const NSUInteger len = [item lengthOfBytesUsingEncoding : NSASCIIStringEncoding] + 1; + try { + std::vector propertyData(len); + [item getCString : (char *)&propertyData[0] maxLength : propertyData.size() encoding : NSASCIIStringEncoding]; + //There is no any guarantee, that this will ever work, logic in TGDNDManager is totally crazy. + NSView * const targetView = self.fQuartzWindow.fContentView; + [targetView setProperty : "_XC_DND_DATA" data : &propertyData[0] size : propertyData.size() forType : textUriAtom format : 8]; + } catch (const std::bad_alloc &) { + NSLog(@"QuartzView: -performDragOperation, memory allocation failed");//Hehe, can I log something in case of bad_alloc??? ;) + return NO; + } + + break; + } + + //Property is attached now. + + //Gdk on windows creates three events on file drop (WM_DROPFILES): XdndEnter, XdndPosition, XdndDrop. + //1. Dnd enter. + Event_t event1 = {}; + event1.fType = kClientMessage; + event1.fWindow = fID; + event1.fHandle = gVirtualX->InternAtom("XdndEnter", kFALSE); + event1.fUser[0] = long(fID); + event1.fUser[2] = textUriAtom;//gVirtualX->InternAtom("text/uri-list", kFALSE); + // + gVirtualX->SendEvent(fID, &event1); + + //2. Dnd position. + Event_t event2 = {}; + event2.fType = kClientMessage; + event2.fWindow = fID; + event2.fHandle = gVirtualX->InternAtom("XdndPosition", kFALSE); + event2.fUser[0] = long(fID); + event2.fUser[2] = 0;//Here I have to pack x and y for drop coordinates, shifting by 16 bits. + NSPoint dropPoint = [sender draggingLocation]; + //convertPointFromBase is deprecated. + //dropPoint = [self convertPointFromBase : dropPoint]; + dropPoint = [self convertPoint : dropPoint fromView : nil]; + // + dropPoint = X11::TranslateToScreen(self, dropPoint); + event2.fUser[2] = UShort_t(dropPoint.y) | (UShort_t(dropPoint.x) << 16); + + gVirtualX->SendEvent(fID, &event2); + + Event_t event3 = {}; + event3.fType = kClientMessage; + event3.fWindow = fID; + event3.fHandle = gVirtualX->InternAtom("XdndDrop", kFALSE); + + gVirtualX->SendEvent(fID, &event3); + } + + return YES;//Always ok, even if file type is not supported - no need in "animation". +} + @end diff --git a/graf2d/cocoa/src/ROOTApplicationDelegate.mm b/graf2d/cocoa/src/ROOTApplicationDelegate.mm new file mode 100644 index 0000000000000..ac22d13810c3c --- /dev/null +++ b/graf2d/cocoa/src/ROOTApplicationDelegate.mm @@ -0,0 +1,68 @@ +#include "ROOTApplicationDelegate.h" +#include "TApplication.h" + +@implementation ROOTApplicationDelegate + +//______________________________________________________________________________ +- (id) init +{ + if (self = [super init]) { + [NSApp setDelegate : self]; + } + + return self; +} + +//______________________________________________________________________________ +- (void) dealloc +{ + [NSApp setDelegate : nil];//? + [super dealloc]; +} + + +//NSApplicationDelegate. + +//______________________________________________________________________________ +- (void) applicationWillResignActive : (NSNotification *) aNotification +{ + //Popup windows, menus, color-selectors, etc. - they all have + //a problem: due to some reason, Cocoa changes the z-stack order + //of such a window while switching between applications (using alt-tab, for example). + //This leads to a very annoying effect: you open a menu, alt-tab, + //alt-tab back and ... popup or menu is now behind the main window. + //I have to save/restore this z-stack order here. + + //Popups were fixed using transient hint, noop now + (void) aNotification; +} + +//______________________________________________________________________________ +- (void) applicationDidBecomeActive : (NSNotification *) aNotification +{ + //Popup windows, menus, color-selectors, etc. - they all have + //a problem: due to some reason, Cocoa changes the z-stack order + //of such a window while switching between applications (using alt-tab, for example). + //This leads to a very annoying effect: you open a menu, alt-tab, + //alt-tab back and ... popup or menu is now behind the main window. + //I have to save/restore this z-stack order here. + + //Popups were fixed using transient hint, noop now. + (void) aNotification; +} + +//______________________________________________________________________________ +- (void) quitROOT +{ + gApplication->Terminate(0); +} + +//______________________________________________________________________________ +- (NSApplicationTerminateReply) applicationShouldTerminate : (NSApplication *) sender +{ + (void) sender; + [self performSelector : @selector(quitROOT) withObject : nil afterDelay : 0.1]; + return NSTerminateCancel; +} + +@end diff --git a/graf2d/cocoa/src/ROOTOpenGLView.mm b/graf2d/cocoa/src/ROOTOpenGLView.mm index a2aeeb15db636..c348ac5f98e23 100644 --- a/graf2d/cocoa/src/ROOTOpenGLView.mm +++ b/graf2d/cocoa/src/ROOTOpenGLView.mm @@ -1,112 +1,224 @@ -#import "ROOTOpenGLView.h" -#import "QuartzWindow.h" -#import "X11Events.h" -#import "TGCocoa.h" +// @(#)root/graf2d:$Id$ +// Author: Timur Pocheptsov 26/04/2012 + +/************************************************************************* + * Copyright (C) 1995-2012, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#include + +#include "ROOTOpenGLView.h" +#include "X11Events.h" +#include "TGCocoa.h" + +namespace ROOT { +namespace MacOSX { +namespace OpenGL { + +//______________________________________________________________________________ +bool GLViewIsValidDrawable(ROOTOpenGLView *glView) +{ + assert(glView != nil && "GLViewIsValid, glView parameter is nil"); + + if ([glView isHiddenOrHasHiddenAncestor]) { + //This will result in "invalid drawable" message + //from -setView:. + return false; + } + + const NSRect visibleRect = [glView visibleRect]; + if (visibleRect.size.width < 1. || visibleRect.size.height < 1.) { + //Another reason for "invalid drawable" message. + return false; + } + + return true; +} + +} +} +} @implementation ROOTOpenGLView { - NSMutableArray *fPassiveKeyGrabs; BOOL fIsOverlapped; + + NSOpenGLPixelFormat *fPixelFormat; + BOOL fUpdateContext; } -@synthesize fID; -@synthesize fEventMask; -@synthesize fParentView; -@synthesize fLevel; -@synthesize fGrabButton; -@synthesize fGrabButtonEventMask; -@synthesize fGrabKeyModifiers; -@synthesize fOwnerEvents; -@synthesize fCurrentCursor; +@synthesize fOpenGLContext; +@synthesize fUpdateContext; //______________________________________________________________________________ - (id) initWithFrame : (NSRect) frameRect pixelFormat : (NSOpenGLPixelFormat *) format { - - if (self = [super initWithFrame : frameRect pixelFormat : format]) { - fPassiveKeyGrabs = [[NSMutableArray alloc] init]; + if (self = [super initWithFrame : frameRect windowAttributes : 0]) { [self setHidden : YES];//Not sure. - fCurrentCursor = kPointer; - //Tracking area? + fIsOverlapped = NO; + fPixelFormat = [format retain]; + + if ([[NSScreen mainScreen] backingScaleFactor] > 1.) + [self setWantsBestResolutionOpenGLSurface : YES]; } - + return self; } //______________________________________________________________________________ - (void) dealloc { - [fPassiveKeyGrabs release]; + if (fOpenGLContext && [fOpenGLContext view] == self) + [fOpenGLContext clearDrawable]; + + self.fOpenGLContext = nil; + [fPixelFormat release]; + //View does not own context. [super dealloc]; } -//NSOpenGLView's overriders. - //______________________________________________________________________________ -- (void) clearGLContext +- (NSOpenGLPixelFormat *) pixelFormat { - [super clearGLContext]; + return fPixelFormat; } //______________________________________________________________________________ -- (NSOpenGLContext *) openGLContext +- (void) setPixelFormat : (NSOpenGLPixelFormat *) pixelFormat { - return [super openGLContext]; + if (fPixelFormat != pixelFormat) { + [fPixelFormat release]; + fPixelFormat = [pixelFormat retain]; + } } +//X11Drawable protocol. + //______________________________________________________________________________ -- (NSOpenGLPixelFormat *) pixelFormat +- (BOOL) fIsOpenGLWidget { - return [super pixelFormat]; + return YES; } //______________________________________________________________________________ -- (void) prepareOpenGL +- (QuartzPixmap *) fBackBuffer { - [super prepareOpenGL]; + //GL-view does not have/need any "back buffer". + return nil; } //______________________________________________________________________________ -- (void) reshape +- (void) setFBackBuffer : (QuartzPixmap *) notUsed { - [super reshape]; + //GL-view does not have/need any "back buffer". + (void) notUsed; } //______________________________________________________________________________ -- (void) setOpenGLContext : (NSOpenGLContext *) context -{ - [super setOpenGLContext : context]; +- (void) mapWindow +{ + [self setHidden : NO]; } //______________________________________________________________________________ -- (void) setPixelFormat : (NSOpenGLPixelFormat *) pixelFormat +- (void) mapSubwindows { - [super setPixelFormat : pixelFormat]; + //GL-view can not have any subwindows. + assert([[self subviews] count] == 0 && "mapSubwindows, GL-view has children"); } //______________________________________________________________________________ -- (void) update +- (void) configureNotifyTree { - [super update]; + //The only node in the tree is 'self'. + if (self.fMapState == kIsViewable) { + if (self.fEventMask & kStructureNotifyMask) { + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx && "configureNotifyTree, gVirtualX is either null or has type different from TGCocoa"); + vx->GetEventTranslator()->GenerateConfigureNotifyEvent(self, self.frame); + } + } } -//X11Drawable protocol. +//______________________________________________________________________________ +- (BOOL) fIsOverlapped +{ + return fIsOverlapped; +} //______________________________________________________________________________ -- (BOOL) fIsPixmap +- (void) setOverlapped : (BOOL) overlap { - return NO; + //If GL-view is overlapped by another view, + //it must be hidden (overwise it will be always on top, + //producing some strange-looking buggy GUI). + + fIsOverlapped = overlap; + [self setHidden : fIsOverlapped]; + + if (!overlap) { + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx != 0 && "setFrameSize:, gVirtualX is either null or has a type, different from TGCocoa"); + [fOpenGLContext update]; + //View becomes visible, geometry can be changed at this point, + //notify ROOT's GL code about this changes. + vx->GetEventTranslator()->GenerateConfigureNotifyEvent(self, self.frame); + vx->GetEventTranslator()->GenerateExposeEvent(self, self.frame); + } } //______________________________________________________________________________ -- (BOOL) fIsOpenGLWidget +- (BOOL) isFlipped { return YES; } -//////// -//Shared methods: +//______________________________________________________________________________ +- (void) setFrame : (NSRect) newFrame +{ + //In case of TBrowser, setFrame started infinite recursion: + //HandleConfigure for embedded main frame emits signal, slot + //calls layout, layout calls setFrame -> HandleConfigure and etc. etc. + if (CGRectEqualToRect(newFrame, self.frame)) + return; + + [super setFrame : newFrame]; +} + +//______________________________________________________________________________ +- (void) setFrameSize : (NSSize) newSize +{ + //Check, if setFrameSize calls setFrame. + + [super setFrameSize : newSize]; + + if (![self isHiddenOrHasHiddenAncestor] && !fIsOverlapped) + [fOpenGLContext update]; + else + fUpdateContext = YES; + + if ((self.fEventMask & kStructureNotifyMask) && (self.fMapState == kIsViewable || fIsOverlapped == YES)) { + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx != 0 && "setFrameSize:, gVirtualX is either null or has a type, different from TGCocoa"); + vx->GetEventTranslator()->GenerateConfigureNotifyEvent(self, self.frame); + vx->GetEventTranslator()->GenerateExposeEvent(self, self.frame); + } +} -#import "SharedViewMethods.h" +//______________________________________________________________________________ +- (void) drawRect : (NSRect) dirtyRect +{ + (void) dirtyRect; +/* + if ((fEventMask & kStructureNotifyMask) && (self.fMapState == kIsViewable || fIsOverlapped == YES)) { + TGCocoa * const vx = dynamic_cast(gVirtualX); + assert(vx != 0 && "drawRect:, gVirtualX is either null or has a type, different from TGCocoa"); + vx->GetEventTranslator()->GenerateConfigureNotifyEvent(self, self.frame); + vx->GetEventTranslator()->GenerateExposeEvent(self, self.frame); + }*/ +} @end - diff --git a/graf2d/cocoa/src/TGCocoa.mm b/graf2d/cocoa/src/TGCocoa.mm index 69beac92ec7f8..0a6faded517b1 100644 --- a/graf2d/cocoa/src/TGCocoa.mm +++ b/graf2d/cocoa/src/TGCocoa.mm @@ -18,62 +18,79 @@ #include #include -#include +#include +#include +#include +#include +#include "ROOTOpenGLView.h" +#include "TMacOSXSystem.h" #include "CocoaPrivate.h" #include "QuartzWindow.h" #include "QuartzPixmap.h" +#include "QuartzUtils.h" #include "X11Drawable.h" #include "QuartzText.h" #include "CocoaUtils.h" +#include "MenuLoader.h" +#include "TVirtualGL.h" #include "X11Events.h" #include "X11Buffer.h" #include "TGClient.h" #include "TGWindow.h" +#include "TSystem.h" #include "TGFrame.h" #include "TGCocoa.h" #include "TError.h" #include "TColor.h" #include "TROOT.h" - -ClassImp(TGCocoa) +#include "TEnv.h" //Style notes: I'm using a lot of asserts to check pre-conditions - mainly function parameters. //In asserts, expression always looks like 'p != 0' for "C++ pointer" (either object of built-in type //or C++ class), and 'p != nil' for object from Objective-C. There is no difference, this is to make //asserts more explicit. In conditional statement, it'll always be 'if (p)' or 'if (!p)' for both -//C++ and Objective-C. +//C++ and Objective-C pointers/code. + //I never use const qualifier for pointers to Objective-C objects since they are useless: //there are no cv-qualified methods (member-functions in C++) in Objective-C, and I do not use //'->' operator to access instance variables (data-members in C++) of Objective-C's object. +//I also declare pointer as a const, if it's const: +//NSWindow * const topLevelWindow = ... (and note, not pointer to const - no use with Obj-C). -namespace ROOT { -namespace Quartz { - -//______________________________________________________________________________ -CGStateGuard::CGStateGuard(void *ctx) - : fCtx(ctx) -{ - CGContextSaveGState(static_cast(ctx)); -} - -//______________________________________________________________________________ -CGStateGuard::~CGStateGuard() -{ - CGContextRestoreGState(static_cast(fCtx)); -} +//Asserts on drawables ids usually only check, that it's not a 'root' window id (unless operation +//is permitted on a 'root' window): +//a) assert(!fPimpl->IsRootWindow(windowID)) and later I also check that windowID != 0 (kNone). +//b) assert(drawableID > fPimpl->GetRootWindowID()) so drawableID can not be kNone and +// can not be a 'root' window. -}//Quartz -}//ROOT +//ROOT window has id 1. So if id > 1 (id > fPimpl->GetRootWindowID()) +//id is considered as valid (if it's out of range and > maximum valid id, this will be +//caught by CocoaPrivate. namespace Details = ROOT::MacOSX::Details; namespace Util = ROOT::MacOSX::Util; namespace X11 = ROOT::MacOSX::X11; namespace Quartz = ROOT::Quartz; - +namespace OpenGL = ROOT::MacOSX::OpenGL; namespace { +//Display configuration management. + +//______________________________________________________________________________ +void DisplayReconfigurationCallback(CGDirectDisplayID /*display*/, CGDisplayChangeSummaryFlags flags, void * /*userInfo*/) +{ + if (flags & kCGDisplayBeginConfigurationFlag) + return; + + if (flags & kCGDisplayDesktopShapeChangedFlag) { + TGCocoa * const gCocoa = dynamic_cast(gVirtualX); + assert(gCocoa != 0 && "DisplayReconfigurationCallback, gVirtualX is either null or has a wrong type"); + gCocoa->ReconfigureDisplay(); + } +} + //Aux. functions called from GUI-rendering part. //______________________________________________________________________________ @@ -162,13 +179,68 @@ void SetFilledAreaColorFromX11Context(CGContextRef ctx, const GCValues_t &gcVals } struct PatternContext { - Mask_t fMask; - ULong_t fForeground; - ULong_t fBackground; - QuartzImage *fImage; - CGSize fPhase; + Mask_t fMask; + Int_t fFillStyle; + ULong_t fForeground; + ULong_t fBackground; + NSObject *fImage;//Either stipple or tile image. + CGSize fPhase; }; + +//______________________________________________________________________________ +bool HasFillTiledStyle(Mask_t mask, Int_t fillStyle) +{ + return (mask & kGCFillStyle) && (fillStyle == kFillTiled); +} + +//______________________________________________________________________________ +bool HasFillTiledStyle(const GCValues_t &gcVals) +{ + return HasFillTiledStyle(gcVals.fMask, gcVals.fFillStyle); +} + +//______________________________________________________________________________ +bool HasFillStippledStyle(Mask_t mask, Int_t fillStyle) +{ + return (mask & kGCFillStyle) && (fillStyle == kFillStippled); +} + +//______________________________________________________________________________ +bool HasFillStippledStyle(const GCValues_t &gcVals) +{ + return HasFillStippledStyle(gcVals.fMask, gcVals.fFillStyle); +} + +//______________________________________________________________________________ +bool HasFillOpaqueStippledStyle(Mask_t mask, Int_t fillStyle) +{ + return (mask & kGCFillStyle) && (fillStyle == kFillOpaqueStippled); +} + +//______________________________________________________________________________ +bool HasFillOpaqueStippledStyle(const GCValues_t &gcVals) +{ + return HasFillOpaqueStippledStyle(gcVals.fMask, gcVals.fFillStyle); +} + +//______________________________________________________________________________ +void DrawTile(NSObject *patternImage, CGContextRef ctx) +{ + assert(patternImage != nil && "DrawTile, patternImage parameter is nil"); + assert(ctx != 0 && "DrawTile, ctx parameter is null"); + + const CGRect patternRect = CGRectMake(0, 0, patternImage.fWidth, patternImage.fHeight); + if ([patternImage isKindOfClass : [QuartzImage class]]) { + CGContextDrawImage(ctx, patternRect, ((QuartzImage *)patternImage).fImage); + } else if ([patternImage isKindOfClass : [QuartzPixmap class]]){ + const Util::CFScopeGuard imageFromPixmap([((QuartzPixmap *)patternImage) createImageFromPixmap]); + assert(imageFromPixmap.Get() != 0 && "DrawTile, createImageFromPixmap failed"); + CGContextDrawImage(ctx, patternRect, imageFromPixmap.Get()); + } else + assert(0 && "DrawTile, pattern is neither a QuartzImage, nor a QuartzPixmap"); +} + //______________________________________________________________________________ void DrawPattern(void *info, CGContextRef ctx) { @@ -179,29 +251,40 @@ void DrawPattern(void *info, CGContextRef ctx) assert(info != 0 && "DrawPattern, info parameter is null"); assert(ctx != 0 && "DrawPattern, ctx parameter is null"); - const PatternContext *patternContext = (PatternContext *)info; - assert(patternContext->fImage != nil && "DrawPatter, pattern image is nil"); + const PatternContext * const patternContext = (PatternContext *)info; + const Mask_t mask = patternContext->fMask; + const Int_t fillStyle = patternContext->fFillStyle; - QuartzImage *patternImage = patternContext->fImage; + NSObject * const patternImage = patternContext->fImage; + assert(patternImage != nil && "DrawPattern, pattern (stipple) image is nil"); const CGRect patternRect = CGRectMake(0, 0, patternImage.fWidth, patternImage.fHeight); - if (patternImage.fIsStippleMask) { - if (patternContext->fMask & kGCBackground) { - CGFloat rgb[3] = {}; + if (HasFillTiledStyle(mask, fillStyle)) { + DrawTile(patternImage, ctx); + } else if (HasFillStippledStyle(mask, fillStyle) || HasFillOpaqueStippledStyle(mask, fillStyle)) { + assert([patternImage isKindOfClass : [QuartzImage class]] && "DrawPattern, stipple must be a QuartzImage object"); + QuartzImage * const image = (QuartzImage *)patternImage; + assert(image.fIsStippleMask == YES && "DrawPattern, image is not a stipple mask"); + + CGFloat rgb[3] = {}; + + if (HasFillOpaqueStippledStyle(mask,fillStyle)) { + //Fill background first. + assert((mask & kGCBackground) && "DrawPattern, fill style is FillOpaqueStippled, but background color is not set in a context"); X11::PixelToRGB(patternContext->fBackground, rgb); CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], 1.); CGContextFillRect(ctx, patternRect); } - - if (patternContext->fMask & kGCForeground) { - CGFloat rgb[3] = {}; - X11::PixelToRGB(patternContext->fForeground, rgb); - CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], 1.); - CGContextClipToMask(ctx, patternRect, patternImage.fImage); - CGContextFillRect(ctx, patternRect); - } + + //Fill rectangle with foreground colour, using stipple mask. + assert((mask & kGCForeground) && "DrawPattern, foreground color is not set"); + X11::PixelToRGB(patternContext->fForeground, rgb); + CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], 1.); + CGContextClipToMask(ctx, patternRect, image.fImage); + CGContextFillRect(ctx, patternRect); } else { - CGContextDrawImage(ctx, patternRect, patternImage.fImage); + //This can be a window background pixmap + DrawTile(patternImage, ctx); } } @@ -236,13 +319,50 @@ bool ParentRendersToChild(NSView *child) assert(child != nil && "ParentRendersToChild, child parameter is nil"); //Adovo poluchaetsia, tashhem-ta! ;) - return X11::ViewIsTextViewFrame(child, true) && !child.fContext && + return (X11::ViewIsTextViewFrame(child, true) || X11::ViewIsHtmlViewFrame(child, true)) && !child.fContext && child.fMapState == kIsViewable && child.fParentView.fContext && !child.fIsOverlapped; } +//______________________________________________________________________________ +bool IsNonPrintableAsciiCharacter(UniChar c) +{ + if (c == 9 || (c >= 32 && c < 127)) + return false; + + return true; +} + +//______________________________________________________________________________ +void FixAscii(std::vector &text) +{ + //GUI text is essentially ASCII. Our GUI + //calculates text metrix 'per-symbol', this means, + //it never asks about 'Text' metrics, but 'T', 'e', 'x', 't'. + //Obviously, text does not fit any widget because of + //this and I have to place all glyphs manually. + //And here I have another problem from our GUI - it + //can easily feed TGCocoa with non-printable symbols + //(this is a bug). Obviously, I do not have glyphs for, say, form feed + //or 'data link escape'. So I have to fix ascii text before + //manual glyph rendering: DLE symbol - replaced by space (this + //is done in TGText, but due to a bug it fails to replace them all) + //Other non-printable symbols simply removed (and thus ignored). + + //Replace remaining ^P symbols with whitespaces, I have not idea why + //TGTextView replaces only part of them and not all of them. + std::replace(text.begin(), text.end(), UniChar(16), UniChar(' ')); + + //Now, remove remaining non-printable characters (no glyphs exist for them). + text.erase(std::remove_if(text.begin(), text.end(), IsNonPrintableAsciiCharacter), text.end()); +} + } +ClassImp(TGCocoa) + +Atom_t TGCocoa::fgDeleteWindowAtom = 0; + //______________________________________________________________________________ TGCocoa::TGCocoa() : fSelectedDrawable(0), @@ -250,13 +370,21 @@ bool ParentRendersToChild(NSView *child) fDrawMode(kCopy), fDirectDraw(false), fForegroundProcess(false), - fCurrentMessageID(1) + fSetApp(true), + fDisplayShapeChanged(true) { - try { - fPimpl.reset(new Details::CocoaPrivate); - } catch (const std::exception &) { - throw; - } + assert(dynamic_cast(gSystem) != nullptr && "TGCocoa, gSystem is eihter null or has a wrong type"); + TMacOSXSystem * const system = (TMacOSXSystem *)gSystem; + + if (!system->CocoaInitialized()) + system->InitializeCocoa(); + + fPimpl.reset(new Details::CocoaPrivate); + + X11::InitWithPredefinedAtoms(fNameToAtom, fAtomToName); + fgDeleteWindowAtom = FindAtom("WM_DELETE_WINDOW", true); + + CGDisplayRegisterReconfigurationCallback (DisplayReconfigurationCallback, 0); } //______________________________________________________________________________ @@ -267,19 +395,28 @@ bool ParentRendersToChild(NSView *child) fDrawMode(kCopy), fDirectDraw(false), fForegroundProcess(false), - fCurrentMessageID(1) + fSetApp(true), + fDisplayShapeChanged(true) { - try { - fPimpl.reset(new Details::CocoaPrivate); - } catch (const std::exception &) { - throw; - } + assert(dynamic_cast(gSystem) != nullptr && "TGCocoa, gSystem is eihter null or has a wrong type"); + TMacOSXSystem * const system = (TMacOSXSystem *)gSystem; + + if (!system->CocoaInitialized()) + system->InitializeCocoa(); + + fPimpl.reset(new Details::CocoaPrivate); + + X11::InitWithPredefinedAtoms(fNameToAtom, fAtomToName); + fgDeleteWindowAtom = FindAtom("WM_DELETE_WINDOW", true); + + CGDisplayRegisterReconfigurationCallback (DisplayReconfigurationCallback, 0); } //______________________________________________________________________________ TGCocoa::~TGCocoa() { // + CGDisplayRemoveReconfigurationCallback (DisplayReconfigurationCallback, 0); } //General part (empty, since it's not an X server. @@ -307,6 +444,13 @@ bool ParentRendersToChild(NSView *child) return "dummy"; } +//______________________________________________________________________________ +Int_t TGCocoa::SupportsExtension(const char *) const +{ + //No, thank you, I'm not supporting any of X11 extensions! + return -1; +} + //______________________________________________________________________________ void TGCocoa::CloseDisplay() { @@ -334,13 +478,28 @@ bool ParentRendersToChild(NSView *child) return 0; } +//______________________________________________________________________________ +UInt_t TGCocoa::ScreenWidthMM() const +{ + //Comment from TVirtualX: + // Returns the width of the screen in millimeters. + //End of comment. + + return CGDisplayScreenSize(CGMainDisplayID()).width; +} + //______________________________________________________________________________ Int_t TGCocoa::GetDepth() const { - NSArray *screens = [NSScreen screens]; + //Comment from TVirtualX: + // Returns depth of screen (number of bit planes). + // Equivalent to GetPlanes(). + //End of comment. + + NSArray * const screens = [NSScreen screens]; assert(screens != nil && "screens array is nil"); - NSScreen *mainScreen = [screens objectAtIndex : 0]; + NSScreen * const mainScreen = [screens objectAtIndex : 0]; assert(mainScreen != nil && "screen with index 0 is nil"); return NSBitsPerPixelFromDepth([mainScreen depth]); @@ -349,13 +508,52 @@ bool ParentRendersToChild(NSView *child) //______________________________________________________________________________ void TGCocoa::Update(Int_t mode) { - //Mode == 2 - force widgets to redraw, - //Mode == 3 - execute graphics requests. if (mode == 2) { + assert(gClient != 0 && "Update, gClient is null"); gClient->DoRedraw();//Call DoRedraw for all widgets, who need to be updated. } else if (mode > 0) { + //Execute buffered commands. fPimpl->fX11CommandBuffer.Flush(fPimpl.get()); } + + if (fDirectDraw && mode != 2) + fPimpl->fX11CommandBuffer.FlushXOROps(fPimpl.get()); +} + +//______________________________________________________________________________ +void TGCocoa::ReconfigureDisplay() +{ + fDisplayShapeChanged = true; +} + +//______________________________________________________________________________ +X11::Rectangle TGCocoa::GetDisplayGeometry()const +{ + if (fDisplayShapeChanged) { + NSArray * const screens = [NSScreen screens]; + assert(screens != nil && screens.count != 0 && "GetDisplayGeometry, no screens found"); + + CGRect frame = [(NSScreen *)[screens objectAtIndex : 0] frame]; + CGFloat xMin = frame.origin.x, xMax = xMin + frame.size.width; + CGFloat yMin = frame.origin.y, yMax = yMin + frame.size.height; + + for (NSUInteger i = 1, e = screens.count; i < e; ++i) { + frame = [(NSScreen *)[screens objectAtIndex : i] frame]; + xMin = std::min(xMin, frame.origin.x); + xMax = std::max(xMax, frame.origin.x + frame.size.width); + yMin = std::min(yMin, frame.origin.y); + yMax = std::max(yMax, frame.origin.y + frame.size.height); + } + + fDisplayRect.fX = int(xMin); + fDisplayRect.fY = int(yMin); + fDisplayRect.fWidth = unsigned(xMax - xMin); + fDisplayRect.fHeight = unsigned(yMax - yMin); + + fDisplayShapeChanged = false; + } + + return fDisplayRect; } //Window management part. @@ -370,12 +568,19 @@ bool ParentRendersToChild(NSView *child) //______________________________________________________________________________ Int_t TGCocoa::InitWindow(ULong_t parentID) { - //InitWindow is a strange name, since this function - //creates a window, but this name is in TVirtualX interface. + //InitWindow is a bad name, since this function + //creates a window, but this name comes from the TVirtualX interface. //Actually, there is no special need in this function, //it's a kind of simplified CreateWindow (with only //one parameter). This function is called by TRootCanvas, //to create a special window inside TGCanvas. + //TGX11/TGWin32 have internal array of such special windows, + //they return index into this array, instead of drawable's ids. + //I simply re-use CreateWindow and return drawable's id. + + assert(parentID != 0 && "InitWindow, parentID parameter is 0");//0 is an invalid id. + + //Use parent's attributes (as it's done in TGX11). WindowAttributes_t attr = {}; if (fPimpl->IsRootWindow(parentID)) { @@ -388,48 +593,55 @@ bool ParentRendersToChild(NSView *child) } //______________________________________________________________________________ -Window_t TGCocoa::GetWindowID(Int_t wid) +Window_t TGCocoa::GetWindowID(Int_t windowID) { - //In case of X11, there is a mixture of - //casted X11 ids (Window_t) and index in some internal array (in TGX11), which + //In case of TGX11/TGWin32, there is a mixture of + //casted X11 ids (Window_t) and indices in some internal array, which //contains such an id. On Mac I always have indices. Yes, I'm smart. - return wid; + return windowID; } //______________________________________________________________________________ -void TGCocoa::SelectWindow(Int_t wid) +void TGCocoa::SelectWindow(Int_t windowID) { //This function can be called from pad/canvas, both for window and for pixmap. - assert(wid > fPimpl->GetRootWindowID() && "SelectWindow, called for 'root' window"); - - fSelectedDrawable = wid; + fSelectedDrawable = windowID; } //______________________________________________________________________________ void TGCocoa::ClearWindow() { - //Clear the selected drawable (can be window or pixmap, so the name is ambiguous). + //Clear the selected drawable OR pixmap (the name - from TVirtualX interface - is bad). assert(fSelectedDrawable > fPimpl->GetRootWindowID() && "ClearWindow, fSelectedDrawable is invalid"); - NSObject *drawable = fPimpl->GetDrawable(fSelectedDrawable); + NSObject * const drawable = fPimpl->GetDrawable(fSelectedDrawable); if (drawable.fIsPixmap) { //Pixmaps are white by default. + //This is bad - we can not have transparent sub-pads (in TCanvas) + //because of this. But there is no way how gVirtualX can + //obtain real pad's color and check for its transparency. CGContextRef pixmapCtx = drawable.fContext; + assert(pixmapCtx != 0 && "ClearWindow, pixmap's context is null"); const Quartz::CGStateGuard ctxGuard(pixmapCtx); CGContextSetRGBFillColor(pixmapCtx, 1., 1., 1., 1.); CGContextFillRect(pixmapCtx, CGRectMake(0, 0, drawable.fWidth, drawable.fHeight)); } else { + //For a window call ClearArea, 0, 0 for width and height means the whole window. ClearArea(fSelectedDrawable, 0, 0, 0, 0); } } //______________________________________________________________________________ -void TGCocoa::GetGeometry(Int_t wid, Int_t & x, Int_t &y, UInt_t &w, UInt_t &h) +void TGCocoa::GetGeometry(Int_t windowID, Int_t & x, Int_t &y, UInt_t &w, UInt_t &h) { //In TGX11, GetGeometry works with special windows, created by InitWindow - //(so this function is called from TCanvas/TGCanvas/TRootCanvas). - //It also translates x and y from parent's coordinates into screen coordinates. - if (wid < 0 || fPimpl->IsRootWindow(wid)) { + //(thus this function is called from TCanvas/TGCanvas/TRootCanvas). + + //IMPORTANT: this function also translates x and y + //from parent's coordinates into screen coordinates - so, again, name "GetGeometry" + //from the TVirtualX interface is bad and misleading. + + if (windowID < 0 || fPimpl->IsRootWindow(windowID)) { //Comment in TVirtualX suggests, that wid can be < 0. //This will be screen's geometry. WindowAttributes_t attr = {}; @@ -439,18 +651,18 @@ bool ParentRendersToChild(NSView *child) w = attr.fWidth; h = attr.fHeight; } else { - NSObject *drawable = fPimpl->GetDrawable(wid); + NSObject * const drawable = fPimpl->GetDrawable(windowID); x = drawable.fX; y = drawable.fY; w = drawable.fWidth; h = drawable.fHeight; if (!drawable.fIsPixmap) { - NSObject *window = (NSObject *)drawable; + NSObject * const window = (NSObject *)drawable; NSPoint srcPoint = {}; srcPoint.x = x; srcPoint.y = y; - NSView *view = window.fContentView.fParentView ? window.fContentView.fParentView : window.fContentView; + NSView * const view = window.fContentView.fParentView ? window.fContentView.fParentView : window.fContentView; //View parameter for TranslateToScreen call must //be parent view, since x and y are in parent's //coordinate system. @@ -462,37 +674,44 @@ bool ParentRendersToChild(NSView *child) } //______________________________________________________________________________ -void TGCocoa::MoveWindow(Int_t wid, Int_t x, Int_t y) +void TGCocoa::MoveWindow(Int_t windowID, Int_t x, Int_t y) { - if (!wid)//From TGX11. - return; + //windowID is either kNone or a valid window id. + //x and y are coordinates of a top-left corner relative to the parent's coordinate system. - assert(!fPimpl->IsRootWindow(wid) && "MoveWindow, called for 'root' window"); + assert(!fPimpl->IsRootWindow(windowID) && "MoveWindow, called for 'root' window"); - [fPimpl->GetWindow(wid) setX : x Y : y]; + if (!windowID)//From TGX11. + return; + + [fPimpl->GetWindow(windowID) setX : x Y : y]; } //______________________________________________________________________________ void TGCocoa::RescaleWindow(Int_t /*wid*/, UInt_t /*w*/, UInt_t /*h*/) { - // + //This function is for TRootCanvas and related stuff, never gets + //called/used from/by any our GUI class. + //Noop. } //______________________________________________________________________________ -void TGCocoa::ResizeWindow(Int_t wid) +void TGCocoa::ResizeWindow(Int_t windowID) { - //This function does not resize window (it was done already), + //This function does not resize window (it was done already by layout management?), //it resizes "back buffer" if any. - if (!wid)//From TGX11. + if (!windowID)//From TGX11. return; - assert(wid != fPimpl->GetRootWindowID() && "ResizeWindow, called for root window"); + assert(!fPimpl->IsRootWindow(windowID) && "ResizeWindow, windowID parameter is a 'root' window"); - NSObject *window = fPimpl->GetWindow(wid); + const Util::AutoreleasePool pool; + + NSObject * const window = fPimpl->GetWindow(windowID); if (window.fBackBuffer) { - int currentDrawable = fSelectedDrawable; - fSelectedDrawable = wid; + const Drawable_t currentDrawable = fSelectedDrawable; + fSelectedDrawable = windowID; SetDoubleBufferON(); fSelectedDrawable = currentDrawable; } @@ -503,27 +722,30 @@ bool ParentRendersToChild(NSView *child) { //This function is used by TCanvas/TPad: //draw "back buffer" image into the view. - assert(fSelectedDrawable > fPimpl->GetRootWindowID() && "UpdateWindow, no window was selected, can not update 'root' window"); -// assert(fPimpl->GetDrawable(fSelectedDrawable).fIsPixmap == NO && "UpdateWindow, called for a pixmap"); + //fContentView (destination) MUST be a QuartzView. + + //Basic es-guarantee: X11Buffer::AddUpdateWindow modifies vector with commands, + //if the following call to TGCocoa::Update will produce an exception dusing X11Buffer::Flush, + //initial state of X11Buffer can not be restored, but it still must be in some valid state. - NSObject *window = fPimpl->GetWindow(fSelectedDrawable); + assert(fSelectedDrawable > fPimpl->GetRootWindowID() && "UpdateWindow, fSelectedDrawable is not a valid window id"); + + if (fPimpl->GetDrawable(fSelectedDrawable).fIsPixmap == YES)//Have no idea, why this can happen with ROOT - done by TGDNDManager :( + return; //TODO: check, when DND is implemented, if this still is required. + + NSObject * const window = fPimpl->GetWindow(fSelectedDrawable); - if (QuartzPixmap *pixmap = window.fBackBuffer) { + if (QuartzPixmap * const pixmap = window.fBackBuffer) { assert([window.fContentView isKindOfClass : [QuartzView class]] && "UpdateWindow, content view is not a QuartzView"); - QuartzView *dstView = (QuartzView *)window.fContentView; - assert(dstView != nil && "UpdateWindow, destination view is nil"); if (dstView.fIsOverlapped) return; if (dstView.fContext) { //We can draw directly. - const Util::CFScopeGuard image([pixmap createImageFromPixmap]); - if (image.Get()) { - const CGRect imageRect = CGRectMake(0, 0, pixmap.fWidth, pixmap.fHeight); - CGContextDrawImage(dstView.fContext, imageRect, image.Get()); - } + const X11::Rectangle copyArea(0, 0, pixmap.fWidth, pixmap.fHeight); + [dstView copy : pixmap area : copyArea withMask : nil clipOrigin : X11::Point() toPoint : X11::Point()]; } else { //Have to wait. fPimpl->fX11CommandBuffer.AddUpdateWindow(dstView); @@ -566,34 +788,32 @@ bool ParentRendersToChild(NSView *child) UInt_t clss, void *visual, SetWindowAttributes_t *attr, UInt_t wtype) { //Create new window (top-level == QuartzWindow + QuartzView, or child == QuartzView) + + //Strong es-guarantee - exception can be only during registration, class state will remain + //unchanged, no leaks (scope guards). + const Util::AutoreleasePool pool; if (fPimpl->IsRootWindow(parentID)) {//parent == root window. - try { - QuartzWindow *newWindow = X11::CreateTopLevelWindow(x, y, w, h, border, depth, clss, visual, attr, wtype);//Can throw. - const Util::NSScopeGuard winGuard(newWindow); - const Window_t result = fPimpl->RegisterDrawable(newWindow);//Can throw. - newWindow.fID = result; - - return result; - } catch (const std::exception &) {//Bad alloc. - throw; - } + QuartzWindow * const newWindow = X11::CreateTopLevelWindow(x, y, w, h, border, depth, clss, visual, attr, wtype);//Can throw. + const Util::NSScopeGuard winGuard(newWindow); + const Window_t result = fPimpl->RegisterDrawable(newWindow);//Can throw. + newWindow.fID = result; + + [newWindow setAcceptsMouseMovedEvents : YES]; + + return result; } else { - NSObject *parentWin = fPimpl->GetWindow(parentID); + NSObject * const parentWin = fPimpl->GetWindow(parentID); //OpenGL view can not have children. assert([parentWin.fContentView isKindOfClass : [QuartzView class]] && "CreateWindow, parent view must be QuartzView"); - try { - QuartzView *childView = X11::CreateChildView((QuartzView *)parentWin.fContentView, x, y, w, h, border, depth, clss, visual, attr, wtype);//Can throw. - const Util::NSScopeGuard viewGuard(childView); - const Window_t result = fPimpl->RegisterDrawable(childView);//Can throw. - childView.fID = result; - [parentWin addChild : childView]; - - return result; - } catch (const std::exception &) {//Bad alloc. - throw; - } + QuartzView * const childView = X11::CreateChildView((QuartzView *)parentWin.fContentView, x, y, w, h, border, depth, clss, visual, attr, wtype);//Can throw. + const Util::NSScopeGuard viewGuard(childView); + const Window_t result = fPimpl->RegisterDrawable(childView);//Can throw. + childView.fID = result; + [parentWin addChild : childView]; + + return result; } } @@ -613,6 +833,8 @@ bool ParentRendersToChild(NSView *child) //I have NO idea why ROOT's GUI calls DestroyWindow with illegal //window id, but it does. + //No-throw guarantee??? + if (!wid) return; @@ -625,13 +847,7 @@ bool ParentRendersToChild(NSView *child) assert(fPimpl->GetDrawable(wid).fIsPixmap == NO && "DestroyWindow, can not be called for QuartzPixmap or QuartzImage object"); - NSObject *window = fPimpl->GetWindow(wid); - if (window.fBackBuffer) { - if (fPimpl->fX11CommandBuffer.BufferSize()) - fPimpl->fX11CommandBuffer.RemoveOperationsForDrawable(window.fBackBuffer.fID); - fPimpl->DeleteDrawable(window.fBackBuffer.fID); - } - + NSObject * const window = fPimpl->GetWindow(wid); if (fPimpl->fX11CommandBuffer.BufferSize()) fPimpl->fX11CommandBuffer.RemoveOperationsForDrawable(wid); @@ -644,7 +860,6 @@ bool ParentRendersToChild(NSView *child) if (gClient->GetWaitForEvent() == kDestroyNotify && wid == gClient->GetWaitForWindow()) gClient->SetWaitForWindow(kNone); - RemoveEventsForWindow(wid); fPimpl->DeleteDrawable(wid); } @@ -654,6 +869,8 @@ bool ParentRendersToChild(NSView *child) // The DestroySubwindows function destroys all inferior windows of the // specified window, in bottom-to-top stacking order. + //No-throw guarantee?? + if (!wid)//From TGX11. return; @@ -678,6 +895,8 @@ bool ParentRendersToChild(NSView *child) //______________________________________________________________________________ void TGCocoa::GetWindowAttributes(Window_t wid, WindowAttributes_t &attr) { + //No-throw guarantee. + if (!wid)//X11's None? return; @@ -692,6 +911,8 @@ bool ParentRendersToChild(NSView *child) //______________________________________________________________________________ void TGCocoa::ChangeWindowAttributes(Window_t wid, SetWindowAttributes_t *attr) { + //No-throw guarantee. + if (!wid)//From TGX11 return; @@ -702,16 +923,21 @@ bool ParentRendersToChild(NSView *child) } //______________________________________________________________________________ -void TGCocoa::SelectInput(Window_t wid, UInt_t evmask) +void TGCocoa::SelectInput(Window_t windowID, UInt_t evmask) { + //No-throw guarantee. + // Defines which input events the window is interested in. By default // events are propageted up the window stack. This mask can also be // set at window creation time via the SetWindowAttributes_t::fEventMask // attribute. - assert(!fPimpl->IsRootWindow(wid) && "SelectInput, called for 'root' window"); + //TGuiBldDragManager selects input on a 'root' window. + //TGWin32 has a check on windowID == 0. + if (windowID <= fPimpl->GetRootWindowID()) + return; - NSObject *window = fPimpl->GetWindow(wid); + NSObject * const window = fPimpl->GetWindow(windowID); //XSelectInput overrides previous mask. window.fEventMask = evmask; } @@ -724,9 +950,9 @@ bool ParentRendersToChild(NSView *child) assert(!fPimpl->IsRootWindow(wid) && "ReparentChild, can not re-parent 'root' window"); //TODO: does ROOT cares about reparent X11 events? - const ROOT::MacOSX::Util::AutoreleasePool pool;//TODO: check? + const Util::AutoreleasePool pool;//TODO: check? - NSView *view = fPimpl->GetWindow(wid).fContentView; + NSView * const view = fPimpl->GetWindow(wid).fContentView; if (fPimpl->IsRootWindow(pid)) { //Make a top-level view from a child view. [view retain]; @@ -735,22 +961,24 @@ bool ParentRendersToChild(NSView *child) NSRect frame = view.frame; frame.origin = CGPointZero; - const NSUInteger styleMask = NSTitledWindowMask | NSClosableWindowMask | NSMiniaturizableWindowMask | NSResizableWindowMask; - QuartzWindow *newTopLevel = [[QuartzWindow alloc] initWithContentRect : frame styleMask : styleMask backing : NSBackingStoreBuffered defer : NO]; + + NSUInteger styleMask = NSClosableWindowMask | NSMiniaturizableWindowMask | NSResizableWindowMask; + if (!view.fOverrideRedirect) + styleMask |= NSTitledWindowMask; + + QuartzWindow * const newTopLevel = [[QuartzWindow alloc] initWithContentRect : frame styleMask : styleMask backing : NSBackingStoreBuffered defer : NO]; [view setX : x Y : y]; - [newTopLevel setContentView : view]; + [newTopLevel addChild : view]; fPimpl->ReplaceDrawable(wid, newTopLevel); - [view updateLevel : 0]; - [view release]; [newTopLevel release]; } else { [view retain]; [view removeFromSuperview]; // - NSObject *newParent = fPimpl->GetWindow(pid); + NSObject * const newParent = fPimpl->GetWindow(pid); assert(newParent.fIsPixmap == NO && "ReparentChild, pixmap can not be a new parent"); [view setX : x Y : y]; [newParent addChild : view];//It'll also update view's level, no need to call updateLevel. @@ -769,9 +997,10 @@ bool ParentRendersToChild(NSView *child) const Util::AutoreleasePool pool;//TODO: check? - NSView *contentView = fPimpl->GetWindow(wid).fContentView; + NSView * const contentView = fPimpl->GetWindow(wid).fContentView; [contentView retain]; - QuartzWindow *topLevel = (QuartzWindow *)[contentView window]; + [contentView removeFromSuperview]; + QuartzWindow * const topLevel = (QuartzWindow *)[contentView window]; [topLevel setContentView : nil]; fPimpl->ReplaceDrawable(wid, contentView); [contentView setX : x Y : y]; @@ -789,7 +1018,7 @@ bool ParentRendersToChild(NSView *child) assert(!fPimpl->IsRootWindow(wid) && "ReparentWindow, can not re-parent 'root' window"); - NSView *view = fPimpl->GetWindow(wid).fContentView; + NSView * const view = fPimpl->GetWindow(wid).fContentView; if (view.fParentView) { ReparentChild(wid, pid, x, y); } else { @@ -808,6 +1037,12 @@ bool ParentRendersToChild(NSView *child) if (MakeProcessForeground()) [fPimpl->GetWindow(wid) mapWindow]; + + if (fSetApp) { + SetApplicationIcon(); + Details::PopulateMainMenu(); + fSetApp = false; + } } //______________________________________________________________________________ @@ -830,10 +1065,17 @@ bool ParentRendersToChild(NSView *child) // stack of all windows. assert(!fPimpl->IsRootWindow(wid) && "MapRaised, called for 'root' window"); - //ROOT::MacOSX::Util::AutoreleasePool pool;//TODO + + const Util::AutoreleasePool pool; if (MakeProcessForeground()) [fPimpl->GetWindow(wid) mapRaised]; + + if (fSetApp) { + SetApplicationIcon(); + Details::PopulateMainMenu(); + fSetApp = false; + } } //______________________________________________________________________________ @@ -857,8 +1099,6 @@ bool ParentRendersToChild(NSView *child) //Interrupt modal loop (TGClient::WaitForUnmap). if (gClient->GetWaitForEvent() == kUnmapNotify && gClient->GetWaitForWindow() == wid) gClient->SetWaitForWindow(kNone); - - //RemoveEventsForWindow(wid);//???? } //______________________________________________________________________________ @@ -907,7 +1147,7 @@ bool ParentRendersToChild(NSView *child) if (!wid)//From TGX11. return; - + assert(!fPimpl->IsRootWindow(wid) && "MoveWindow, called for 'root' window"); [fPimpl->GetWindow(wid) setX : x Y : y]; @@ -978,7 +1218,10 @@ bool ParentRendersToChild(NSView *child) //From man for XTranslateCoordinates it's not clear, what should be in child. dstX = srcX; dstY = srcY; - child = 0;//TODO: check, if X11 searches for any window. + + if (QuartzWindow * const qw = X11::FindWindowInPoint(srcX, srcY)) + child = qw.fID; + return; } @@ -990,10 +1233,10 @@ bool ParentRendersToChild(NSView *child) if (dstIsRoot) { - NSView *srcView = fPimpl->GetWindow(srcWin).fContentView; + NSView * const srcView = fPimpl->GetWindow(srcWin).fContentView; dstPoint = X11::TranslateToScreen(srcView, srcPoint); } else if (srcIsRoot) { - NSView *dstView = fPimpl->GetWindow(dstWin).fContentView; + NSView * const dstView = fPimpl->GetWindow(dstWin).fContentView; dstPoint = X11::TranslateFromScreen(srcPoint, dstView); if ([dstView superview]) { @@ -1001,22 +1244,22 @@ bool ParentRendersToChild(NSView *child) //Even contentView of QuartzWindow has a superview (NSThemeFrame), //so this should always work. dstPoint = [[dstView superview] convertPoint : dstPoint fromView : dstView]; - if (NSView *view = (NSView *)[dstView hitTest : dstPoint]) { + if (NSView * const view = (NSView *)[dstView hitTest : dstPoint]) { if (view != dstView && view.fMapState == kIsViewable) child = view.fID; } } } else { - NSView *srcView = fPimpl->GetWindow(srcWin).fContentView; - NSView *dstView = fPimpl->GetWindow(dstWin).fContentView; + NSView * const srcView = fPimpl->GetWindow(srcWin).fContentView; + NSView * const dstView = fPimpl->GetWindow(dstWin).fContentView; dstPoint = X11::TranslateCoordinates(srcView, dstView, srcPoint); if ([dstView superview]) { //hitTest requires a point in a view's superview coordinate system. //Even contentView of QuartzWindow has a superview (NSThemeFrame), //so this should always work. - dstPoint = [[dstView superview] convertPoint : dstPoint fromView : dstView]; - if (NSView *view = (NSView *)[dstView hitTest : dstPoint]) { + const NSPoint pt = [[dstView superview] convertPoint : dstPoint fromView : dstView]; + if (NSView * const view = (NSView *)[dstView hitTest : pt]) { if (view != dstView && view.fMapState == kIsViewable) child = view.fID; } @@ -1075,22 +1318,54 @@ bool ParentRendersToChild(NSView *child) } //______________________________________________________________________________ -void TGCocoa::SetWindowBackgroundPixmap(Window_t wid, Pixmap_t /*pxm*/) +void TGCocoa::SetWindowBackgroundPixmap(Window_t windowID, Pixmap_t pixmapID) { // Sets the background pixmap of the window "wid" to the specified // pixmap "pxm". - if (!wid)//From TGX11. + + if (!windowID)//From TGX11/TGWin32. + return; + + assert(!fPimpl->IsRootWindow(windowID) && "SetWindowBackgroundPixmap, windowID parameter is a 'root' window"); + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "SetWindowBackgroundPixmap, windowID parameter is not a window"); + + NSObject * const window = fPimpl->GetWindow(windowID); + if (pixmapID == kNone) { + window.fBackgroundPixmap = nil; return; + } + + assert(pixmapID > fPimpl->GetRootWindowID() && "SetWindowBackgroundPixmap, pixmapID parameter is not a valid pixmap id"); + assert(fPimpl->GetDrawable(pixmapID).fIsPixmap == YES && "SetWindowBackgroundPixmap, pixmapID parameter is not a pixmap"); + + NSObject * const pixmapOrImage = fPimpl->GetDrawable(pixmapID); + //X11 doc says, that pixmap can be freed immediately after call XSetWindowBackgroundPixmap, so I have to copy a pixmap. + Util::NSScopeGuard backgroundImage; + + if ([pixmapOrImage isKindOfClass : [QuartzPixmap class]]) { + backgroundImage.Reset([[QuartzImage alloc] initFromPixmap : (QuartzPixmap *)pixmapOrImage]); + if (backgroundImage.Get()) + window.fBackgroundPixmap = backgroundImage.Get();//the window is retaining the image. + } else { + backgroundImage.Reset([[QuartzImage alloc] initFromImage : (QuartzImage *)pixmapOrImage]); + if (backgroundImage.Get()) + window.fBackgroundPixmap = backgroundImage.Get();//the window is retaining the image. + } + + if (!backgroundImage.Get()) + Error("SetWindowBackgroundPixmap", "QuartzImage initialization failed");//More concrete message was issued by QuartzImage. } //______________________________________________________________________________ -Window_t TGCocoa::GetParent(Window_t wid) const +Window_t TGCocoa::GetParent(Window_t windowID) const { - // Returns the parent of the window "wid". - if (wid <= (Window_t)fPimpl->GetRootWindowID()) - return wid; + // Returns the parent of the window "windowID". + + //0 (checked in TGX11) or 'root'. + if (windowID <= fPimpl->GetRootWindowID()) + return windowID; - NSView *view = fPimpl->GetWindow(wid).fContentView; + NSView *view = fPimpl->GetWindow(windowID).fContentView; return view.fParentView ? view.fParentView.fID : fPimpl->GetRootWindowID(); } @@ -1102,10 +1377,10 @@ bool ParentRendersToChild(NSView *child) const Util::AutoreleasePool pool; - NSObject *drawable = fPimpl->GetDrawable(wid); + NSObject * const drawable = fPimpl->GetDrawable(wid); if ([(NSObject *)drawable isKindOfClass : [NSWindow class]]) { - NSString *windowTitle = [NSString stringWithCString : name encoding : NSASCIIStringEncoding]; + NSString * const windowTitle = [NSString stringWithCString : name encoding : NSASCIIStringEncoding]; [(NSWindow *)drawable setTitle : windowTitle]; } @@ -1130,65 +1405,222 @@ bool ParentRendersToChild(NSView *child) void TGCocoa::SetClassHints(Window_t /*wid*/, char * /*className*/, char * /*resourceName*/) { - // Sets the windows class and resource name. + //Noop. } -///////////////////////////////////////// -//GUI-rendering part. //______________________________________________________________________________ -void TGCocoa::DrawLineAux(Drawable_t wid, const GCValues_t &gcVals, Int_t x1, Int_t y1, Int_t x2, Int_t y2) +void TGCocoa::ShapeCombineMask(Window_t windowID, Int_t /*x*/, Int_t /*y*/, Pixmap_t pixmapID) { - //Can be called directly of when flushing command buffer. - assert(!fPimpl->IsRootWindow(wid) && "DrawLineAux, called for 'root' window"); + //Comment from TVirtualX: + // The Nonrectangular Window Shape Extension adds nonrectangular + // windows to the System. + // This allows for making shaped (partially transparent) windows - CGContextRef ctx = fPimpl->GetDrawable(wid).fContext; - assert(ctx != 0 && "DrawLineAux, ctx is null"); - - const Quartz::CGStateGuard ctxGuard(ctx);//Will restore state back. - //Draw a line. - //This draw line is a special GUI method, it's used not by ROOT's graphics, but - //widgets. The problem is: - //-I have to switch off anti-aliasing, since if anti-aliasing is on, - //the line is thick and has different color. - //-As soon as I switch-off anti-aliasing, and line is precise, I can not - //draw a line [0, 0, -> w, 0]. - //I use a small translation, after all, this is ONLY gui method and it - //will not affect anything except GUI. - CGContextTranslateCTM(ctx, 0.f, 1.); - CGContextSetAllowsAntialiasing(ctx, false);//Smoothed line is of wrong color and in a wrong position - this is bad for GUI. - - SetStrokeParametersFromX11Context(ctx, gcVals); - CGContextBeginPath(ctx); - CGContextMoveToPoint(ctx, x1, y1); - CGContextAddLineToPoint(ctx, x2, y2); - CGContextStrokePath(ctx); + assert(!fPimpl->IsRootWindow(windowID) && "ShapeCombineMask, windowID parameter is a 'root' window"); + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "ShapeCombineMask, windowID parameter is a bad window id"); + assert([fPimpl->GetDrawable(pixmapID) isKindOfClass : [QuartzImage class]] && "ShapeCombineMask, pixmapID parameter must point to QuartzImage object"); - CGContextSetAllowsAntialiasing(ctx, true);//Somehow, it's not saved/restored, this affects ... window's titlebar. + //TODO: nonrectangular window can be only NSWindow object, + //not NSView (and mask is attached to a window). + //This means, if some nonrectangular window is created as a child + //first, and detached later (becoming top-level), the shape will be lost. + //Find a better way to fix it. + if (fPimpl->GetWindow(windowID).fContentView.fParentView) + return; + + QuartzImage * const srcImage = (QuartzImage *)fPimpl->GetDrawable(pixmapID); + assert(srcImage.fIsStippleMask == YES && "ShapeCombineMask, source image is not a stipple mask"); + + //TODO: there is some kind of problems with shape masks and + //flipped views, I have to do an image flip here - check this! + const Util::NSScopeGuard image([[QuartzImage alloc] initFromImageFlipped : srcImage]); + if (image.Get()) { + QuartzWindow * const qw = fPimpl->GetWindow(windowID).fQuartzWindow; + qw.fShapeCombineMask = image.Get(); + [qw setOpaque : NO]; + [qw setBackgroundColor : [NSColor clearColor]]; + } } +//"Window manager hints" set of functions. + //______________________________________________________________________________ -void TGCocoa::DrawLine(Drawable_t wid, GContext_t gc, Int_t x1, Int_t y1, Int_t x2, Int_t y2) +void TGCocoa::SetMWMHints(Window_t wid, UInt_t value, UInt_t funcs, UInt_t /*input*/) { - //This function can be called: - //a)'normal' way - from view's drawRect method. - //b) for 'direct rendering' - operation was initiated by ROOT's GUI, not by - // drawRect. - - if (!wid) //From TGX11. - return; + // Sets decoration style. + assert(!fPimpl->IsRootWindow(wid) && "SetMWMHints, called for 'root' window"); - assert(!fPimpl->IsRootWindow(wid) && "DrawLine, called for 'root' window"); - assert(gc > 0 && gc <= fX11Contexts.size() && "DrawLine, strange context index"); + QuartzWindow * const qw = fPimpl->GetWindow(wid).fQuartzWindow; + NSUInteger newMask = 0; + + if ([qw styleMask] & NSTitledWindowMask) {//Do not modify this. + newMask |= NSTitledWindowMask; + newMask |= NSClosableWindowMask; + } - const GCValues_t &gcVals = fX11Contexts[gc - 1]; + if (value & kMWMFuncAll) { + newMask |= NSMiniaturizableWindowMask | NSResizableWindowMask; + } else { + if (value & kMWMDecorMinimize) + newMask |= NSMiniaturizableWindowMask; + if (funcs & kMWMFuncResize) + newMask |= NSResizableWindowMask; + } + + [qw setStyleMask : newMask]; - NSObject *drawable = fPimpl->GetDrawable(wid); - if (!drawable.fIsPixmap) { - NSObject *window = (NSObject *)drawable; - QuartzView *view = (QuartzView *)window.fContentView; - - if (ParentRendersToChild(view)) { - if (X11::LockFocus(view)) { + if (funcs & kMWMDecorAll) { + if (!qw.fMainWindow) {//Do not touch buttons for transient window. + [[qw standardWindowButton : NSWindowZoomButton] setEnabled : YES]; + [[qw standardWindowButton : NSWindowMiniaturizeButton] setEnabled : YES]; + } + } else { + if (!qw.fMainWindow) {//Do not touch transient window's titlebar. + [[qw standardWindowButton : NSWindowZoomButton] setEnabled : funcs & kMWMDecorMaximize]; + [[qw standardWindowButton : NSWindowMiniaturizeButton] setEnabled : funcs & kMWMDecorMinimize]; + } + } +} + +//______________________________________________________________________________ +void TGCocoa::SetWMPosition(Window_t /*wid*/, Int_t /*x*/, Int_t /*y*/) +{ + // Tells the window manager the desired position [x,y] of window "wid". +} + +//______________________________________________________________________________ +void TGCocoa::SetWMSize(Window_t /*wid*/, UInt_t /*w*/, UInt_t /*h*/) +{ + // Tells window manager the desired size of window "wid". + // + // w - the width + // h - the height +} + +//______________________________________________________________________________ +void TGCocoa::SetWMSizeHints(Window_t wid, UInt_t wMin, UInt_t hMin, UInt_t wMax, UInt_t hMax, UInt_t /*wInc*/, UInt_t /*hInc*/) +{ + // + assert(!fPimpl->IsRootWindow(wid) && "SetWMSizeHints, called for 'root' window"); + + const NSUInteger styleMask = NSTitledWindowMask | NSClosableWindowMask | NSMiniaturizableWindowMask | NSResizableWindowMask; + const NSRect minRect = [NSWindow frameRectForContentRect : CGRectMake(0., 0., wMin, hMin) styleMask : styleMask]; + const NSRect maxRect = [NSWindow frameRectForContentRect : CGRectMake(0., 0., wMax, hMax) styleMask : styleMask]; + + QuartzWindow * const qw = fPimpl->GetWindow(wid).fQuartzWindow; + [qw setMinSize : minRect.size]; + [qw setMaxSize : maxRect.size]; +} + +//______________________________________________________________________________ +void TGCocoa::SetWMState(Window_t /*wid*/, EInitialState /*state*/) +{ + // Sets the initial state of the window "wid": either kNormalState + // or kIconicState. +} + +//______________________________________________________________________________ +void TGCocoa::SetWMTransientHint(Window_t wid, Window_t mainWid) +{ + //Comment from TVirtualX: + // Tells window manager that the window "wid" is a transient window + // of the window "main_id". A window manager may decide not to decorate + // a transient window or may treat it differently in other ways. + //End of TVirtualX's comment. + + //TGTransientFrame uses this hint to attach a window to some "main" window, + //so that transient window is alway above the main window. This is used for + //dialogs and dockable panels. + assert(wid > fPimpl->GetRootWindowID() && "SetWMTransientHint, wid parameter is not a valid window id"); + + if (fPimpl->IsRootWindow(mainWid)) + return; + + QuartzWindow * const mainWindow = fPimpl->GetWindow(mainWid).fQuartzWindow; + + if (![mainWindow isVisible]) + return; + + QuartzWindow * const transientWindow = fPimpl->GetWindow(wid).fQuartzWindow; + + if (mainWindow != transientWindow) { + if (transientWindow.fMainWindow) { + if (transientWindow.fMainWindow != mainWindow) + Error("SetWMTransientHint", "window is already transient for other window"); + } else { + [[transientWindow standardWindowButton : NSWindowZoomButton] setEnabled : NO]; + [mainWindow addTransientWindow : transientWindow]; + } + } else + Warning("SetWMTransientHint", "transient and main windows are the same window"); +} + +///////////////////////////////////////// +//GUI-rendering part. +//______________________________________________________________________________ +void TGCocoa::DrawLineAux(Drawable_t wid, const GCValues_t &gcVals, Int_t x1, Int_t y1, Int_t x2, Int_t y2) +{ + //Can be called directly of when flushing command buffer. + assert(!fPimpl->IsRootWindow(wid) && "DrawLineAux, called for 'root' window"); + + NSObject * const drawable = fPimpl->GetDrawable(wid); + CGContextRef ctx = drawable.fContext; + assert(ctx != 0 && "DrawLineAux, ctx is null"); + + const Quartz::CGStateGuard ctxGuard(ctx);//Will restore state back. + //Draw a line. + //This draw line is a special GUI method, it's used not by ROOT's graphics, but + //widgets. The problem is: + //-I have to switch off anti-aliasing, since if anti-aliasing is on, + //the line is thick and has different color. + //-As soon as I switch-off anti-aliasing, and line is precise, I can not + //draw a line [0, 0, -> w, 0]. + //I use a small translation, after all, this is ONLY gui method and it + //will not affect anything except GUI. + + CGContextSetAllowsAntialiasing(ctx, false);//Smoothed line is of wrong color and in a wrong position - this is bad for GUI. + + if (!drawable.fIsPixmap) + CGContextTranslateCTM(ctx, 0.5, 0.5); + else { + //Pixmap uses native Cocoa's left-low-corner system. + //TODO: check the line on the edge. + y1 = Int_t(X11::LocalYROOTToCocoa(drawable, y1)); + y2 = Int_t(X11::LocalYROOTToCocoa(drawable, y2)); + } + + SetStrokeParametersFromX11Context(ctx, gcVals); + CGContextBeginPath(ctx); + CGContextMoveToPoint(ctx, x1, y1); + CGContextAddLineToPoint(ctx, x2, y2); + CGContextStrokePath(ctx); + + CGContextSetAllowsAntialiasing(ctx, true);//Somehow, it's not saved/restored, this affects ... window's titlebar. +} + +//______________________________________________________________________________ +void TGCocoa::DrawLine(Drawable_t wid, GContext_t gc, Int_t x1, Int_t y1, Int_t x2, Int_t y2) +{ + //This function can be called: + //a)'normal' way - from view's drawRect method. + //b) for 'direct rendering' - operation was initiated by ROOT's GUI, not by + // drawRect. + + if (!wid) //From TGX11. + return; + + assert(!fPimpl->IsRootWindow(wid) && "DrawLine, called for 'root' window"); + assert(gc > 0 && gc <= fX11Contexts.size() && "DrawLine, strange context index"); + + const GCValues_t &gcVals = fX11Contexts[gc - 1]; + + NSObject * const drawable = fPimpl->GetDrawable(wid); + if (!drawable.fIsPixmap) { + NSObject * const window = (NSObject *)drawable; + QuartzView * const view = (QuartzView *)window.fContentView; + + if (ParentRendersToChild(view)) { + if (X11::LockFocus(view)) { DrawLineAux(view.fID, gcVals, x1, y1, x2, y2); X11::UnlockFocus(view); return; @@ -1233,11 +1665,11 @@ bool ParentRendersToChild(NSView *child) assert(segments != 0 && "DrawSegments, segments parameter is null"); assert(nSegments > 0 && "DrawSegments, number of segments <= 0"); - NSObject *drawable = fPimpl->GetDrawable(wid); + NSObject * const drawable = fPimpl->GetDrawable(wid); const GCValues_t &gcVals = fX11Contexts[gc - 1]; if (!drawable.fIsPixmap) { - QuartzView *view = (QuartzView *)fPimpl->GetWindow(wid).fContentView; + QuartzView * const view = (QuartzView *)fPimpl->GetWindow(wid).fContentView; if (ParentRendersToChild(view)) { if (X11::LockFocus(view)) { @@ -1267,11 +1699,19 @@ bool ParentRendersToChild(NSView *child) //Can be called directly or during flushing command buffer. assert(!fPimpl->IsRootWindow(wid) && "DrawRectangleAux, called for 'root' window"); - //I can not draw a line at y == 0, shift the rectangle to 1 pixel (and reduce its height). - if (!y) { - y = 1; - if (h) - h -= 1; + NSObject * const drawable = fPimpl->GetDrawable(wid); + + if (!drawable.fIsPixmap) { + //I can not draw a line at y == 0, shift the rectangle to 1 pixel (and reduce its height). + if (!y) { + y = 1; + if (h) + h -= 1; + } + } else { + //TODO: check the line on the edge. + //Pixmap has native Cocoa's low-left-corner system. + y = Int_t(X11::LocalYROOTToCocoa(drawable, y + h)); } CGContextRef ctx = fPimpl->GetDrawable(wid).fContext; @@ -1302,11 +1742,11 @@ bool ParentRendersToChild(NSView *child) const GCValues_t &gcVals = fX11Contexts[gc - 1]; - NSObject *drawable = fPimpl->GetDrawable(wid); + NSObject * const drawable = fPimpl->GetDrawable(wid); if (!drawable.fIsPixmap) { - NSObject *window = (NSObject *)drawable; - QuartzView *view = (QuartzView *)window.fContentView; + NSObject * const window = (NSObject *)drawable; + QuartzView * const view = (QuartzView *)window.fContentView; if (ParentRendersToChild(view)) { if (X11::LockFocus(view)) { @@ -1334,33 +1774,57 @@ bool ParentRendersToChild(NSView *child) void TGCocoa::FillRectangleAux(Drawable_t wid, const GCValues_t &gcVals, Int_t x, Int_t y, UInt_t w, UInt_t h) { //Can be called directly or when flushing command buffer. + //Can be called directly or when flushing command buffer. if (!wid)//From TGX11. return; assert(!fPimpl->IsRootWindow(wid) && "FillRectangleAux, called for 'root' window"); - NSObject *drawable = fPimpl->GetDrawable(wid); + NSObject * const drawable = fPimpl->GetDrawable(wid); CGContextRef ctx = drawable.fContext; CGSize patternPhase = {}; + + if (drawable.fIsPixmap) { + //Pixmap has low-left-corner based system. + //TODO: check how pixmap works with pattern fill. + y = Int_t(X11::LocalYROOTToCocoa(drawable, y + h)); + } const CGRect fillRect = CGRectMake(x, y, w, h); if (!drawable.fIsPixmap) { - QuartzView *view = (QuartzView *)fPimpl->GetWindow(wid).fContentView; - const CGPoint origin = [view convertPoint : view.frame.origin toView : nil]; - patternPhase.width = origin.x; - patternPhase.height = origin.y; + QuartzView * const view = (QuartzView *)fPimpl->GetWindow(wid).fContentView; + if (view.fParentView) { + const CGPoint origin = [view.fParentView convertPoint : view.frame.origin toView : nil]; + patternPhase.width = origin.x; + patternPhase.height = origin.y; + } } const Quartz::CGStateGuard ctxGuard(ctx);//Will restore context state. + //TODO: At the moment I ignore: clip_mask, clip_x_origin, clip_y_origin, stipple and tile origins, + //check if any widget uses them. + + if (HasFillStippledStyle(gcVals) || HasFillOpaqueStippledStyle(gcVals) || HasFillTiledStyle(gcVals)) { + PatternContext patternContext = {gcVals.fMask, gcVals.fFillStyle, 0, 0, nil, patternPhase}; + + if (HasFillStippledStyle(gcVals) || HasFillOpaqueStippledStyle(gcVals)) { + assert(gcVals.fStipple != kNone && "FillRectangleAux, fill_style is FillStippled/FillOpaqueStippled, but no stipple is set in a context"); + + patternContext.fForeground = gcVals.fForeground; + patternContext.fImage = fPimpl->GetDrawable(gcVals.fStipple); + + if (HasFillOpaqueStippledStyle(gcVals)) + patternContext.fBackground = gcVals.fBackground; + } else { + assert(gcVals.fTile != kNone && "FillRectangleAux, fill_style is FillTiled, but not tile is set in a context"); + + patternContext.fImage = fPimpl->GetDrawable(gcVals.fTile); + } - if (gcVals.fMask & kGCStipple) { - assert(fPimpl->GetDrawable(gcVals.fStipple).fIsPixmap == YES && "FillRectangleAux, stipple is not a pixmap"); - PatternContext patternContext = {gcVals.fMask, gcVals.fForeground, gcVals.fBackground, - (QuartzImage *)fPimpl->GetDrawable(gcVals.fStipple), - patternPhase}; SetFillPattern(ctx, &patternContext); CGContextFillRect(ctx, fillRect); + return; } @@ -1381,11 +1845,11 @@ bool ParentRendersToChild(NSView *child) assert(gc > 0 && gc <= fX11Contexts.size() && "FillRectangle, bad GContext_t"); const GCValues_t &gcVals = fX11Contexts[gc - 1]; - NSObject *drawable = fPimpl->GetDrawable(wid); + NSObject * const drawable = fPimpl->GetDrawable(wid); if (!drawable.fIsPixmap) { - NSObject *window = (NSObject *)drawable; - QuartzView *view = (QuartzView *)window.fContentView; + NSObject * const window = (NSObject *)drawable; + QuartzView * const view = (QuartzView *)window.fContentView; if (ParentRendersToChild(view)) { if (X11::LockFocus(view)) { @@ -1402,10 +1866,15 @@ bool ParentRendersToChild(NSView *child) FillRectangleAux(wid, gcVals, x, y, w, h); } } else { + /* if (!IsCocoaDraw()) fPimpl->fX11CommandBuffer.AddFillRectangle(wid, gcVals, x, y, w, h); else - FillRectangleAux(wid, gcVals, x, y, w, h); + */ + //Commented part: looks like it was not good idea: we can draw into + //pixmap just to set the contents of this pixmap, outside of any GUI rendering. + //TODO: check, if other functions are also affected. + FillRectangleAux(wid, gcVals, x, y, w, h); } } @@ -1420,13 +1889,13 @@ bool ParentRendersToChild(NSView *child) assert(polygon != 0 && "FillPolygonAux, polygon parameter is null"); assert(nPoints > 0 && "FillPolygonAux, nPoints <= 0"); - NSObject *drawable = fPimpl->GetDrawable(wid); + NSObject * const drawable = fPimpl->GetDrawable(wid); CGContextRef ctx = drawable.fContext; CGSize patternPhase = {}; if (!drawable.fIsPixmap) { - QuartzView *view = (QuartzView *)fPimpl->GetWindow(wid).fContentView; + QuartzView * const view = (QuartzView *)fPimpl->GetWindow(wid).fContentView; const CGPoint origin = [view convertPoint : view.frame.origin toView : nil]; patternPhase.width = origin.x; patternPhase.height = origin.y; @@ -1436,21 +1905,45 @@ bool ParentRendersToChild(NSView *child) CGContextSetAllowsAntialiasing(ctx, false); - if (gcVals.fMask & kGCStipple) { - assert(fPimpl->GetDrawable(gcVals.fStipple).fIsPixmap == YES && "FillRectangleAux, stipple is not a pixmap"); - PatternContext patternContext = {gcVals.fMask, gcVals.fForeground, gcVals.fBackground, - (QuartzImage *)fPimpl->GetDrawable(gcVals.fStipple), - patternPhase}; + //TODO: At the moment I ignore: clip_mask, clip_x_origin, clip_y_origin, stipple and tile origins, + //check if any widget uses them. + + if (HasFillStippledStyle(gcVals) || HasFillOpaqueStippledStyle(gcVals) || HasFillTiledStyle(gcVals)) { + PatternContext patternContext = {gcVals.fMask, gcVals.fFillStyle, 0, 0, nil, patternPhase}; + + if (HasFillStippledStyle(gcVals) || HasFillOpaqueStippledStyle(gcVals)) { + assert(gcVals.fStipple != kNone && "FillRectangleAux, fill_style is FillStippled/FillOpaqueStippled, but no stipple is set in a context"); + + patternContext.fForeground = gcVals.fForeground; + patternContext.fImage = fPimpl->GetDrawable(gcVals.fStipple); + + if (HasFillOpaqueStippledStyle(gcVals)) + patternContext.fBackground = gcVals.fBackground; + } else { + assert(gcVals.fTile != kNone && "FillRectangleAux, fill_style is FillTiled, but not tile is set in a context"); + + patternContext.fImage = fPimpl->GetDrawable(gcVals.fTile); + } + SetFillPattern(ctx, &patternContext); } else SetFilledAreaColorFromX11Context(ctx, gcVals); - + + //These +2 -2 shit is the result of ROOT's GUI producing strange coordinates out of .... + // - first noticed on checkmarks in a menu - they were all shifted. + CGContextBeginPath(ctx); - CGContextMoveToPoint(ctx, polygon[0].fX, polygon[0].fY - 2); - for (Int_t i = 1; i < nPoints; ++i) - CGContextAddLineToPoint(ctx, polygon[i].fX, polygon[i].fY - 2); + if (!drawable.fIsPixmap) { + CGContextMoveToPoint(ctx, polygon[0].fX, polygon[0].fY - 2); + for (Int_t i = 1; i < nPoints; ++i) + CGContextAddLineToPoint(ctx, polygon[i].fX, polygon[i].fY - 2); + } else { + CGContextMoveToPoint(ctx, polygon[0].fX, X11::LocalYROOTToCocoa(drawable, polygon[0].fY + 2)); + for (Int_t i = 1; i < nPoints; ++i) + CGContextAddLineToPoint(ctx, polygon[i].fX, X11::LocalYROOTToCocoa(drawable, polygon[i].fY + 2)); + } + CGContextFillPath(ctx); - CGContextSetAllowsAntialiasing(ctx, true); } @@ -1477,11 +1970,11 @@ bool ParentRendersToChild(NSView *child) assert(nPoints > 0 && "FillPolygon, bad number of points"); assert(gc > 0 && gc <= fX11Contexts.size() && "FillPolygon, bad CGContext_t"); - NSObject *drawable = fPimpl->GetDrawable(wid); + NSObject * const drawable = fPimpl->GetDrawable(wid); const GCValues_t &gcVals = fX11Contexts[gc - 1]; if (!drawable.fIsPixmap) { - QuartzView *view = (QuartzView *)fPimpl->GetWindow(wid).fContentView; + QuartzView * const view = (QuartzView *)fPimpl->GetWindow(wid).fContentView; if (ParentRendersToChild(view)) { if (X11::LockFocus(view)) { @@ -1519,18 +2012,11 @@ bool ParentRendersToChild(NSView *child) //I do not want them to wait till run loop's iteration end to die. const Util::AutoreleasePool pool; - NSObject *srcDrawable = fPimpl->GetDrawable(src); - NSObject *dstDrawable = fPimpl->GetDrawable(dst); - - Point_t dstPoint = {}; - dstPoint.fX = dstX; - dstPoint.fY = dstY; + NSObject * const srcDrawable = fPimpl->GetDrawable(src); + NSObject * const dstDrawable = fPimpl->GetDrawable(dst); - Rectangle_t copyArea = {}; - copyArea.fX = srcX; - copyArea.fY = srcY; - copyArea.fWidth = (UShort_t)width;//TODO: check size? - copyArea.fHeight = (UShort_t)height;//TODO: check size? + const X11::Point dstPoint(dstX, dstY); + const X11::Rectangle copyArea(srcX, srcY, width, height); QuartzImage *mask = nil; if ((gcVals.fMask & kGCClipMask) && gcVals.fClipMask) { @@ -1538,7 +2024,7 @@ bool ParentRendersToChild(NSView *child) mask = (QuartzImage *)fPimpl->GetDrawable(gcVals.fClipMask); } - Point_t clipOrigin = {}; + X11::Point clipOrigin; if (gcVals.fMask & kGCClipXOrigin) clipOrigin.fX = gcVals.fClipXOrigin; if (gcVals.fMask & kGCClipYOrigin) @@ -1557,11 +2043,11 @@ bool ParentRendersToChild(NSView *child) assert(!fPimpl->IsRootWindow(dst) && "CopyArea, dst parameter is 'root' window"); assert(gc > 0 && gc <= fX11Contexts.size() && "CopyArea, bad GContext_t"); - NSObject *drawable = fPimpl->GetDrawable(dst); + NSObject * const drawable = fPimpl->GetDrawable(dst); const GCValues_t &gcVals = fX11Contexts[gc - 1]; if (!drawable.fIsPixmap) { - QuartzView *view = (QuartzView *)fPimpl->GetWindow(dst).fContentView; + QuartzView * const view = (QuartzView *)fPimpl->GetWindow(dst).fContentView; if (ParentRendersToChild(view)) { if (X11::LockFocus(view)) { @@ -1578,20 +2064,25 @@ bool ParentRendersToChild(NSView *child) CopyAreaAux(src, dst, gcVals, srcX, srcY, width, height, dstX, dstY); } } else { - if (!IsCocoaDraw()) - fPimpl->fX11CommandBuffer.AddCopyArea(src, dst, gcVals, srcX, srcY, width, height, dstX, dstY); - else + if (fPimpl->GetDrawable(src).fIsPixmap) { + //Both are pixmaps, nothing is buffered for src (???). CopyAreaAux(src, dst, gcVals, srcX, srcY, width, height, dstX, dstY); + } else { + if (!IsCocoaDraw()) + fPimpl->fX11CommandBuffer.AddCopyArea(src, dst, gcVals, srcX, srcY, width, height, dstX, dstY); + else + CopyAreaAux(src, dst, gcVals, srcX, srcY, width, height, dstX, dstY); + } } } //______________________________________________________________________________ void TGCocoa::DrawStringAux(Drawable_t wid, const GCValues_t &gcVals, Int_t x, Int_t y, const char *text, Int_t len) { - //Can be called by ROOT directly, or indirectly by AppKit. + //Can be called by ROOT directly, or indirectly by AppKit. assert(!fPimpl->IsRootWindow(wid) && "DrawStringAux, called for the 'root' window"); - NSObject *drawable = fPimpl->GetDrawable(wid); + NSObject * const drawable = fPimpl->GetDrawable(wid); CGContextRef ctx = drawable.fContext; assert(ctx != 0 && "DrawStringAux, ctx is null"); @@ -1600,17 +2091,18 @@ bool ParentRendersToChild(NSView *child) CGContextSetTextMatrix(ctx, CGAffineTransformIdentity); //View is flipped, I have to transform for text to work. - CGContextTranslateCTM(ctx, 0., drawable.fHeight); - CGContextScaleCTM(ctx, 1., -1.); + if (!drawable.fIsPixmap) { + CGContextTranslateCTM(ctx, 0., drawable.fHeight); + CGContextScaleCTM(ctx, 1., -1.); + } - //Text must be antialiased. + //Text must be antialiased CGContextSetAllowsAntialiasing(ctx, true); assert(gcVals.fMask & kGCFont && "DrawString, font is not set in a context"); if (len < 0)//Negative length can come from caller. len = std::strlen(text); - const std::string substr(text, len); //Text can be not black, for example, highlighted label. CGFloat textColor[4] = {0., 0., 0., 1.};//black by default. //I do not check the results here, it's ok to have a black text. @@ -1620,7 +2112,11 @@ bool ParentRendersToChild(NSView *child) CGContextSetRGBFillColor(ctx, textColor[0], textColor[1], textColor[2], textColor[3]); //Do a simple text layout using CGGlyphs. - std::vector unichars(text, text + len); + //GUI uses non-ascii symbols, and does not care about signed/unsigned - just dump everything + //into a char and be happy. I'm not. + std::vector unichars((unsigned char *)text, (unsigned char *)text + len); + FixAscii(unichars); + Quartz::DrawTextLineNoKerning(ctx, (CTFontRef)gcVals.fFont, unichars, x, X11::LocalYROOTToCocoa(drawable, y)); } @@ -1634,16 +2130,23 @@ bool ParentRendersToChild(NSView *child) assert(!fPimpl->IsRootWindow(wid) && "DrawString, called for the 'root' window"); assert(gc > 0 && gc <= fX11Contexts.size() && "DrawString, bad GContext_t"); - NSObject *drawable = fPimpl->GetDrawable(wid); + NSObject * const drawable = fPimpl->GetDrawable(wid); const GCValues_t &gcVals = fX11Contexts[gc - 1]; assert(gcVals.fMask & kGCFont && "DrawString, font is not set in a context"); if (!drawable.fIsPixmap) { - QuartzView *view = (QuartzView *)fPimpl->GetWindow(wid).fContentView; + QuartzView * const view = (QuartzView *)fPimpl->GetWindow(wid).fContentView; if (ParentRendersToChild(view)) {//Ufff. if (X11::LockFocus(view)) { - DrawStringAux(view.fID, gcVals, x, y, text, len); + + try { + DrawStringAux(view.fID, gcVals, x, y, text, len); + } catch (const std::exception &) { + X11::UnlockFocus(view); + throw; + } + X11::UnlockFocus(view); return; } @@ -1665,11 +2168,11 @@ bool ParentRendersToChild(NSView *child) } //______________________________________________________________________________ -void TGCocoa::ClearAreaAux(Window_t wid, Int_t x, Int_t y, UInt_t w, UInt_t h) +void TGCocoa::ClearAreaAux(Window_t windowID, Int_t x, Int_t y, UInt_t w, UInt_t h) { - assert(!fPimpl->IsRootWindow(wid) && "ClearAreaAux, called for the 'root' window"); + assert(!fPimpl->IsRootWindow(windowID) && "ClearAreaAux, called for the 'root' window"); - QuartzView *view = (QuartzView *)fPimpl->GetWindow(wid).fContentView; + QuartzView * const view = (QuartzView *)fPimpl->GetWindow(windowID).fContentView; assert(view.fContext != 0 && "ClearAreaAux, view.fContext is null"); //w and h can be 0 (comment from TGX11) - clear the entire window. @@ -1677,13 +2180,30 @@ bool ParentRendersToChild(NSView *child) w = view.fWidth; if (!h) h = view.fHeight; - - CGFloat rgb[3] = {}; - X11::PixelToRGB(view.fBackgroundPixel, rgb); + + if (!view.fBackgroundPixmap) { + //Simple solid fill. + CGFloat rgb[3] = {}; + X11::PixelToRGB(view.fBackgroundPixel, rgb); + + const Quartz::CGStateGuard ctxGuard(view.fContext); + CGContextSetRGBFillColor(view.fContext, rgb[0], rgb[1], rgb[2], 1.);//alpha can be also used. + CGContextFillRect(view.fContext, CGRectMake(x, y, w, h)); + } else { + const CGRect fillRect = CGRectMake(x, y, w, h); + + CGSize patternPhase = {}; + if (view.fParentView) { + const CGPoint origin = [view.fParentView convertPoint : view.frame.origin toView : nil]; + patternPhase.width = origin.x; + patternPhase.height = origin.y; + } + const Quartz::CGStateGuard ctxGuard(view.fContext);//Will restore context state. - const Quartz::CGStateGuard ctxGuard(view.fContext); - CGContextSetRGBFillColor(view.fContext, rgb[0], rgb[1], rgb[2], 1.);//alpha can be also used. - CGContextFillRect(view.fContext, CGRectMake(x, y, w, h)); + PatternContext patternContext = {Mask_t(), 0, 0, 0, view.fBackgroundPixmap, patternPhase}; + SetFillPattern(view.fContext, &patternContext); + CGContextFillRect(view.fContext, fillRect); + } } //______________________________________________________________________________ @@ -1697,7 +2217,7 @@ bool ParentRendersToChild(NSView *child) assert(!fPimpl->IsRootWindow(wid) && "ClearArea, called for the 'root' window"); - QuartzView *view = (QuartzView *)fPimpl->GetWindow(wid).fContentView;//If wid is pixmap or image, this will crush. + QuartzView * const view = (QuartzView *)fPimpl->GetWindow(wid).fContentView;//If wid is pixmap or image, this will crush. if (ParentRendersToChild(view)) { if (X11::LockFocus(view)) { @@ -1736,18 +2256,13 @@ bool ParentRendersToChild(NSView *child) newSize.width = w; newSize.height = h; - try { - Util::NSScopeGuard obj([QuartzPixmap alloc]); - if (QuartzPixmap *pixmap = [obj.Get() initWithW : w H : h]) { - obj.Reset(pixmap); - pixmap.fID = fPimpl->RegisterDrawable(pixmap);//Can throw. - return (Int_t)pixmap.fID; - } else { - Error("OpenPixmap", "Pixmap initialization failed"); - return -1; - } - } catch (const std::exception &) {//std::bad_alloc. - throw; + Util::NSScopeGuard pixmap([[QuartzPixmap alloc] initWithW : w H : h scaleFactor : [[NSScreen mainScreen] backingScaleFactor]]); + if (pixmap.Get()) { + pixmap.Get().fID = fPimpl->RegisterDrawable(pixmap.Get());//Can throw. + return (Int_t)pixmap.Get().fID; + } else { + Error("OpenPixmap", "QuartzPixmap initialization failed");//More concrete message was issued by QuartzPixmap. + return -1; } } @@ -1763,51 +2278,54 @@ bool ParentRendersToChild(NSView *child) if (w == pixmap.fWidth && h == pixmap.fHeight) return 1; - if ([pixmap resizeW : w H : h]) + if ([pixmap resizeW : w H : h scaleFactor : [[NSScreen mainScreen] backingScaleFactor]])//This can throw std::bad_alloc, ok, no resource will leak. return 1; return -1; } //______________________________________________________________________________ -void TGCocoa::SelectPixmap(Int_t pixid) +void TGCocoa::SelectPixmap(Int_t pixmapID) { - assert(pixid > fPimpl->GetRootWindowID() && "SelectPixmap, 'root' window can not be selected"); + assert(pixmapID > (Int_t)fPimpl->GetRootWindowID() && "SelectPixmap, pixmapID parameter is not a valid id"); - fSelectedDrawable = pixid; + fSelectedDrawable = pixmapID; } //______________________________________________________________________________ -void TGCocoa::CopyPixmap(Int_t wid, Int_t xpos, Int_t ypos) +void TGCocoa::CopyPixmap(Int_t pixmapID, Int_t x, Int_t y) { - //const ROOT::MacOSX::Util::AutoreleasePool pool; - - NSObject *source = fPimpl->GetDrawable(wid); - assert(source.fIsPixmap == YES && "CopyPixmap, source is not a pixmap"); + assert(pixmapID > (Int_t)fPimpl->GetRootWindowID() && "CopyPixmap, pixmapID parameter is not a valid id"); + assert(fSelectedDrawable > fPimpl->GetRootWindowID() && "CopyPixmap, fSelectedDrawable is not a valid window id"); - QuartzPixmap *pixmap = (QuartzPixmap *)source; + NSObject * const source = fPimpl->GetDrawable(pixmapID); + assert([source isKindOfClass : [QuartzPixmap class]] && "CopyPixmap, source is not a pixmap"); + QuartzPixmap * const pixmap = (QuartzPixmap *)source; - NSObject *window = fPimpl->GetWindow(fSelectedDrawable); - if (window.fBackBuffer) { - const Util::CFScopeGuard image([pixmap createImageFromPixmap]); - if (image.Get()) { - CGContextRef dstCtx = window.fBackBuffer.fContext; - assert(dstCtx != 0 && "CopyPixmap, destination context is null"); - - const CGRect imageRect = CGRectMake(xpos, ypos, pixmap.fWidth, pixmap.fHeight); + NSObject * const drawable = fPimpl->GetDrawable(fSelectedDrawable); + NSObject * destination = nil; - CGContextDrawImage(dstCtx, imageRect, image.Get()); - CGContextFlush(dstCtx); - } + if (drawable.fIsPixmap) { + destination = drawable; } else { - Warning("CopyPixmap", "Operation skipped, since destination window is not double buffered"); + NSObject * const window = fPimpl->GetWindow(fSelectedDrawable); + if (window.fBackBuffer) { + destination = window.fBackBuffer; + } else { + Warning("CopyPixmap", "Operation skipped, since destination window is not double buffered"); + return; + } } + + const X11::Rectangle copyArea(0, 0, pixmap.fWidth, pixmap.fHeight); + const X11::Point dstPoint(x, y); + + [destination copy : pixmap area : copyArea withMask : nil clipOrigin : X11::Point() toPoint : dstPoint]; } //______________________________________________________________________________ void TGCocoa::ClosePixmap() { - // Deletes current pixmap. } @@ -1832,46 +2350,25 @@ bool ParentRendersToChild(NSView *child) assert(width > 0 && "CreatePixmap, width parameter is 0"); assert(height > 0 && "CreatePixmap, height parameter is 0"); - try { - unsigned char *imageData = 0; - if (depth > 1) - imageData = new unsigned char[width * height * 4](); - else - imageData = new unsigned char[width * height]; + std::vector imageData (depth > 1 ? width * height * 4 : width * height); - X11::FillPixmapBuffer((unsigned char*)bitmap, width, height, foregroundPixel, backgroundPixel, depth, imageData); + X11::FillPixmapBuffer((unsigned char*)bitmap, width, height, foregroundPixel, backgroundPixel, depth, &imageData[0]); - //Now we can create CGImageRef. - Util::NSScopeGuard mem([QuartzImage alloc]); - if (!mem.Get()) { - Error("CreatePixmap", "[QuartzImage alloc] failed"); - delete [] imageData; - return Pixmap_t(); - } + //Now we can create CGImageRef. + Util::NSScopeGuard image; - QuartzImage *image = nil; - - if (depth > 1) - image = [mem.Get() initWithW : width H : height data: imageData]; - else - image = [mem.Get() initMaskWithW : width H : height bitmapMask : imageData]; - - if (!image) { - delete [] imageData; - Error("CreatePixmap", "[QuartzImage initWithW:H:data:] failed"); - return Pixmap_t(); - } + if (depth > 1) + image.Reset([[QuartzImage alloc] initWithW : width H : height data: &imageData[0]]); + else + image.Reset([[QuartzImage alloc] initMaskWithW : width H : height bitmapMask : &imageData[0]]); - mem.Reset(image); - //Now imageData is owned by image. - image.fID = fPimpl->RegisterDrawable(image);//This can throw. - return image.fID; - } catch (const std::exception &) { - //Memory is owned by QuartzImage. - throw; + if (!image.Get()) { + Error("CreatePixmap", "QuartzImage initialization failed");//More concrete message was issued by QuartzImage. + return kNone; } - return Pixmap_t(); + image.Get().fID = fPimpl->RegisterDrawable(image.Get());//This can throw. + return image.Get().fID; } //______________________________________________________________________________ @@ -1882,42 +2379,25 @@ bool ParentRendersToChild(NSView *child) assert(width != 0 && "CreatePixmapFromData, width parameter is 0"); assert(height != 0 && "CreatePixmapFromData, height parameter is 0"); - try { - //I'm not using vector here, since I have to pass this pointer to Obj-C code - //(and Obj-C object will own this memory later). - unsigned char *imageData = new unsigned char[width * height * 4]; - std::copy(bits, bits + width * height * 4, imageData); - - //Convert bgra to rgba. - unsigned char *p = imageData; - for (unsigned i = 0, e = width * height; i < e; ++i, p += 4) - std::swap(p[0], p[2]); - - //Now we can create CGImageRef. - Util::NSScopeGuard mem([QuartzImage alloc]); - if (!mem.Get()) { - Error("CreatePixmapFromData", "[QuartzImage alloc] failed"); - delete [] imageData; - return Pixmap_t(); - } - - QuartzImage *image = [mem.Get() initWithW : width H : height data : imageData]; - if (!image) { - delete [] imageData; - Error("CreatePixmapFromData", "[QuartzImage initWithW:H:data:] failed"); - return Pixmap_t(); - } - - mem.Reset(image); - //Now imageData is owned by image. - image.fID = fPimpl->RegisterDrawable(image);//This can throw. - - return image.fID; - } catch (const std::exception &) {//Bad alloc. - throw; + //I'm not using vector here, since I have to pass this pointer to Obj-C code + //(and Obj-C object will own this memory later). + std::vector imageData(bits, bits + width * height * 4); + + //Convert bgra to rgba. + unsigned char *p = &imageData[0]; + for (unsigned i = 0, e = width * height; i < e; ++i, p += 4) + std::swap(p[0], p[2]); + + //Now we can create CGImageRef. + Util::NSScopeGuard image([[QuartzImage alloc] initWithW : width H : height data : &imageData[0]]); + + if (!image.Get()) { + Error("CreatePixmapFromData", "QuartzImage initialziation failed");//More concrete message was issued by QuartzImage. + return kNone; } - return Pixmap_t(); + image.Get().fID = fPimpl->RegisterDrawable(image.Get());//This can throw. + return image.Get().fID; } //______________________________________________________________________________ @@ -1926,47 +2406,32 @@ bool ParentRendersToChild(NSView *child) //Create QuartzImage with image mask. assert(std::numeric_limits::digits == 8 && "CreateBitmap, ASImage requires octets"); - try { - //I'm not using vector here, since I have to pass this pointer to Obj-C code - //(and Obj-C object will own this memory later). - - //TASImage has a bug, it calculates size in pixels (making a with to multiple-of eight and - //allocates memory as each bit occupies one byte, and later packs bits into bytes. - //Posylaiu luchi ponosa avtoru. - - unsigned char *imageData = new unsigned char[width * height](); - for (unsigned i = 0, j = 0, e = width / 8 * height; i < e; ++i) {//TASImage supposes 8-bit bytes and packs mask bits. - for(unsigned bit = 0; bit < 8; ++bit, ++j) { - if (bitmap[i] & (1 << bit)) - imageData[j] = 0;//Opaque. - else - imageData[j] = 255;//Masked out bit. - } - } - - //Now we can create CGImageRef. - Util::NSScopeGuard mem([QuartzImage alloc]); - if (!mem.Get()) { - Error("CreateBitmap", "[QuartzImage alloc] failed"); - delete [] imageData; - return Pixmap_t(); - } + //I'm not using vector here, since I have to pass this pointer to Obj-C code + //(and Obj-C object will own this memory later). - QuartzImage *image = [mem.Get() initMaskWithW : width H : height bitmapMask: imageData]; - if (!image) { - delete [] imageData; - return Pixmap_t(); + //TASImage has a bug, it calculates size in pixels (making a with to multiple-of eight and + //allocates memory as each bit occupies one byte, and later packs bits into bytes. + + std::vector imageData(width * height); + + for (unsigned i = 0, j = 0, e = width / 8 * height; i < e; ++i) {//TASImage supposes 8-bit bytes and packs mask bits. + for(unsigned bit = 0; bit < 8; ++bit, ++j) { + if (bitmap[i] & (1 << bit)) + imageData[j] = 0;//Opaque. + else + imageData[j] = 255;//Masked out bit. } - - mem.Reset(image); - //Now, imageData is owned by image. - image.fID = fPimpl->RegisterDrawable(image);//This can throw. - return image.fID; - } catch (const std::exception &e) {//Bad alloc. - throw; } - return Pixmap_t(); + //Now we can create CGImageRef. + Util::NSScopeGuard image([[QuartzImage alloc] initMaskWithW : width H : height bitmapMask : &imageData[0]]); + if (!image.Get()) { + Error("CreateBitmap", "QuartzImage initialization failed");//More concrete message was issued by QuartzImage. + return kNone; + } + + image.Get().fID = fPimpl->RegisterDrawable(image.Get());//This can throw. + return image.Get().fID; } //______________________________________________________________________________ @@ -2004,56 +2469,121 @@ bool ParentRendersToChild(NSView *child) assert(w != 0 && "GetColorBits, w parameter is 0"); assert(h != 0 && "GetColorBits, h parameter is 0"); - Rectangle_t area = {}; - area.fX = x, area.fY = y, area.fWidth = w, area.fHeight = h; - return [fPimpl->GetDrawable(wid) readColorBits : area]; + const X11::Rectangle area(x, y, w, h); + return [fPimpl->GetDrawable(wid) readColorBits : area];//readColorBits can throw std::bad_alloc, no resource will leak. } return 0; } -//Mouse related code. +//"XImage" emulation. //______________________________________________________________________________ -void TGCocoa::GrabButton(Window_t wid, EMouseButton button, UInt_t keyModifiers, UInt_t eventMask, - Window_t /*confine*/, Cursor_t /*cursor*/, Bool_t grab) +Drawable_t TGCocoa::CreateImage(UInt_t width, UInt_t height) { - //Emulate "passive grab" feature of X11 (similar to "implicit grab" in Cocoa - //and implicit grab on X11, the difference is that "implicit grab" works as - //if owner_events parameter for XGrabButton was False, but in ROOT - //owner_events for XGrabButton is _always_ True. - //Confine will never be used - no such feature on MacOSX and - //I'm not going to emulate it.. - //This function also does ungrab. - - assert(!fPimpl->IsRootWindow(wid) && "GrabButton, called for 'root' window"); - - NSObject *widget = fPimpl->GetWindow(wid); - - if (grab) { - widget.fOwnerEvents = YES; //This is how TGX11 works. - widget.fGrabButton = button; - widget.fGrabButtonEventMask = eventMask; - widget.fGrabKeyModifiers = keyModifiers; - //Set the cursor. - } else { - widget.fOwnerEvents = NO; - widget.fGrabButton = -1;//0 is kAnyButton. - widget.fGrabButtonEventMask = 0; - widget.fGrabKeyModifiers = 0; - } + // Allocates the memory needed for a drawable. + // + // width - the width of the image, in pixels + // height - the height of the image, in pixels + return OpenPixmap(width, height); } //______________________________________________________________________________ -void TGCocoa::GrabPointer(Window_t wid, UInt_t eventMask, Window_t /*confine*/, Cursor_t /*cursor*/, Bool_t grab, Bool_t ownerEvents) +void TGCocoa::GetImageSize(Drawable_t wid, UInt_t &width, UInt_t &height) { - //Emulate pointer grab from X11. + // Returns the width and height of the image wid + assert(wid > fPimpl->GetRootWindowID() && "GetImageSize, wid parameter is a bad image id"); + + NSObject * const drawable = fPimpl->GetDrawable(wid); + width = drawable.fWidth; + height = drawable.fHeight; +} + +//______________________________________________________________________________ +void TGCocoa::PutPixel(Drawable_t imageID, Int_t x, Int_t y, ULong_t pixel) +{ + // Overwrites the pixel in the image with the specified pixel value. + // The image must contain the x and y coordinates. + // + // imageID - specifies the image + // x, y - coordinates + // pixel - the new pixel value + + assert([fPimpl->GetDrawable(imageID) isKindOfClass : [QuartzPixmap class]] && "PutPixel, imageID parameter is a bad pixmap id"); + assert(x >= 0 && "PutPixel, x parameter is negative"); + assert(y >= 0 && "PutPixel, y parameter is negative"); + + QuartzPixmap * const pixmap = (QuartzPixmap *)fPimpl->GetDrawable(imageID); + + unsigned char rgb[3] = {}; + X11::PixelToRGB(pixel, rgb); + [pixmap putPixel : rgb X : x Y : y]; +} + +//______________________________________________________________________________ +void TGCocoa::PutImage(Drawable_t drawableID, GContext_t gc, Drawable_t imageID, Int_t dstX, Int_t dstY, Int_t srcX, Int_t srcY, UInt_t width, UInt_t height) +{ + //TGX11 uses ZPixmap in CreateImage ... so background/foreground + //in gc can NEVER be used (and the depth is ALWAYS > 1). + //This means .... I can call CopyArea! + + CopyArea(imageID, drawableID, gc, srcX, srcY, width, height, dstX, dstY); +} + +//______________________________________________________________________________ +void TGCocoa::DeleteImage(Drawable_t imageID) +{ + // Deallocates the memory associated with the image img + assert([fPimpl->GetDrawable(imageID) isKindOfClass : [QuartzPixmap class]] && + "DeleteImage, imageID parameter is not a valid image id"); + DeletePixmap(imageID); +} + +//Mouse related code. + +//______________________________________________________________________________ +void TGCocoa::GrabButton(Window_t wid, EMouseButton button, UInt_t keyModifiers, UInt_t eventMask, + Window_t /*confine*/, Cursor_t /*cursor*/, Bool_t grab) +{ + //Emulate "passive grab" feature of X11 (similar to "implicit grab" in Cocoa + //and implicit grab on X11, the difference is that "implicit grab" works as + //if owner_events parameter for XGrabButton was False, but in ROOT + //owner_events for XGrabButton is _always_ True. + //Confine will never be used - no such feature on MacOSX and + //I'm not going to emulate it.. + //This function also does ungrab. + + if (!wid)//From TGWin32. + return; + + assert(!fPimpl->IsRootWindow(wid) && "GrabButton, called for 'root' window"); + + NSObject * const widget = fPimpl->GetWindow(wid); + + if (grab) { + widget.fPassiveGrabOwnerEvents = YES; //This is how TGX11 works. + widget.fPassiveGrabButton = button; + widget.fPassiveGrabEventMask = eventMask; + widget.fPassiveGrabKeyModifiers = keyModifiers; + //Set the cursor. + } else { + widget.fPassiveGrabOwnerEvents = NO; + widget.fPassiveGrabButton = -1;//0 is kAnyButton. + widget.fPassiveGrabEventMask = 0; + widget.fPassiveGrabKeyModifiers = 0; + } +} + +//______________________________________________________________________________ +void TGCocoa::GrabPointer(Window_t wid, UInt_t eventMask, Window_t /*confine*/, Cursor_t /*cursor*/, Bool_t grab, Bool_t ownerEvents) +{ + //Emulate pointer grab from X11. //Confine will never be used - no such feature on MacOSX and //I'm not going to emulate it.. //This function also does ungrab. if (grab) { - NSView *view = fPimpl->GetWindow(wid).fContentView; + NSView * const view = fPimpl->GetWindow(wid).fContentView; assert(!fPimpl->IsRootWindow(wid) && "GrabPointer, called for 'root' window"); //set the cursor. //set active grab. @@ -2065,6 +2595,112 @@ bool ParentRendersToChild(NSView *child) } } +//______________________________________________________________________________ +void TGCocoa::ChangeActivePointerGrab(Window_t, UInt_t, Cursor_t) +{ + // Changes the specified dynamic parameters if the pointer is actively + // grabbed by the client and if the specified time is no earlier than the + // last-pointer-grab time and no later than the current X server time. +} + +//______________________________________________________________________________ +void TGCocoa::SetKeyAutoRepeat(Bool_t /*on = kTRUE*/) +{ + // Turns key auto repeat on (kTRUE) or off (kFALSE). +} + +//______________________________________________________________________________ +void TGCocoa::GrabKey(Window_t wid, Int_t keyCode, UInt_t rootKeyModifiers, Bool_t grab) +{ + //Comment from TVirtualX: + // Establishes a passive grab on the keyboard. In the future, the + // keyboard is actively grabbed, the last-keyboard-grab time is set + // to the time at which the key was pressed (as transmitted in the + // KeyPress event), and the KeyPress event is reported if all of the + // following conditions are true: + // - the keyboard is not grabbed and the specified key (which can + // itself be a modifier key) is logically pressed when the + // specified modifier keys are logically down, and no other + // modifier keys are logically down; + // - either the grab window "id" is an ancestor of (or is) the focus + // window, or "id" is a descendant of the focus window and contains + // the pointer; + // - a passive grab on the same key combination does not exist on any + // ancestor of grab_window + // + // id - window id + // keycode - specifies the KeyCode or AnyKey + // modifier - specifies the set of keymasks or AnyModifier; the mask is + // the bitwise inclusive OR of the valid keymask bits + // grab - a switch between grab/ungrab key + // grab = kTRUE grab the key and modifier + // grab = kFALSE ungrab the key and modifier + //End of comment. + + + //Key code already must be Cocoa's key code, this is done by GUI classes, + //they call KeySymToKeyCode. + assert(!fPimpl->IsRootWindow(wid) && "GrabKey, called for 'root' window"); + + NSView * const view = fPimpl->GetWindow(wid).fContentView; + const NSUInteger cocoaKeyModifiers = X11::GetCocoaKeyModifiersFromROOTKeyModifiers(rootKeyModifiers); + + if (grab) + [view addPassiveKeyGrab : keyCode modifiers : cocoaKeyModifiers]; + else + [view removePassiveKeyGrab : keyCode modifiers : cocoaKeyModifiers]; +} + +//______________________________________________________________________________ +Int_t TGCocoa::KeysymToKeycode(UInt_t keySym) +{ + // Converts the "keysym" to the appropriate keycode. For example, + // keysym is a letter and keycode is the matching keyboard key (which + // is dependend on the current keyboard mapping). If the specified + // "keysym" is not defined for any keycode, returns zero. + + return X11::MapKeySymToKeyCode(keySym); +} + +//______________________________________________________________________________ +Window_t TGCocoa::GetInputFocus() +{ + // Returns the window id of the window having the input focus. + + return fPimpl->fX11EventTranslator.GetInputFocus(); +} + +//______________________________________________________________________________ +void TGCocoa::SetInputFocus(Window_t wid) +{ + // Changes the input focus to specified window "wid". + assert(!fPimpl->IsRootWindow(wid) && "SetInputFocus, called for 'root' window"); + + if (wid == kNone) + fPimpl->fX11EventTranslator.SetInputFocus(nil); + else + fPimpl->fX11EventTranslator.SetInputFocus(fPimpl->GetWindow(wid).fContentView); +} + +//______________________________________________________________________________ +void TGCocoa::LookupString(Event_t *event, char *buf, Int_t length, UInt_t &keysym) +{ + // Converts the keycode from the event structure to a key symbol (according + // to the modifiers specified in the event structure and the current + // keyboard mapping). In "buf" a null terminated ASCII string is returned + // representing the string that is currently mapped to the key code. + // + // event - specifies the event structure to be used + // buf - returns the translated characters + // buflen - the length of the buffer + // keysym - returns the "keysym" computed from the event + // if this argument is not NULL + assert(buf != 0 && "LookupString, buf parameter is null"); + assert(length >= 2 && "LookupString, length parameter - not enough memory to return null-terminated ASCII string"); + + X11::MapUnicharToKeySym(event->fCode, buf, length, keysym); +} + //Font management. //______________________________________________________________________________ @@ -2074,7 +2710,7 @@ bool ParentRendersToChild(NSView *child) //-foundry-family- ..... etc., some components can be omitted and replaced by *. assert(fontName != 0 && "LoadQueryFont, fontName is null"); - ROOT::MacOSX::X11::XLFDName xlfd = {}; + X11::XLFDName xlfd; if (ParseXLFDName(fontName, xlfd)) { //Make names more flexible: fFamilyName can be empty or '*'. if (!xlfd.fFamilyName.length() || xlfd.fFamilyName == "*") @@ -2147,7 +2783,7 @@ bool ParentRendersToChild(NSView *child) count = 0; if (fontName && fontName[0]) { - X11::XLFDName xlfd = {}; + X11::XLFDName xlfd; if (X11::ParseXLFDName(fontName, xlfd)) return fPimpl->fFontManager.ListFonts(xlfd, maxNames, count); } @@ -2205,7 +2841,7 @@ bool ParentRendersToChild(NSView *child) ULong_t TGCocoa::GetPixel(Color_t rootColorIndex) { ULong_t pixel = 0; - if (const TColor *color = gROOT->GetColor(rootColorIndex)) { + if (const TColor * const color = gROOT->GetColor(rootColorIndex)) { Float_t red = 0.f, green = 0.f, blue = 0.f; color->GetRGB(red, green, blue); pixel = unsigned(red * 255) << 16; @@ -2300,30 +2936,16 @@ bool ParentRendersToChild(NSView *child) x11Context.fCapStyle = gval->fCapStyle; if (mask & kGCJoinStyle)//nobody uses x11Context.fJoinStyle = gval->fJoinStyle; - // - if (mask & kGCFillRule)//nobody uses x11Context.fFillRule = gval->fFillRule; if (mask & kGCArcMode)//nobody uses x11Context.fArcMode = gval->fArcMode; - - if (mask & kGCFillStyle) { + if (mask & kGCFillStyle) x11Context.fFillStyle = gval->fFillStyle; - x11Context.fMask &= ~kGCStipple; - x11Context.fMask &= ~kGCTile; - } - if (mask & kGCTile) { + if (mask & kGCTile) x11Context.fTile = gval->fTile; - x11Context.fMask &= ~kGCStipple; - x11Context.fMask &= ~kGCFillStyle; - } - if (mask & kGCStipple) { + if (mask & kGCStipple) x11Context.fStipple = gval->fStipple; - x11Context.fMask &= ~kGCFillStyle; - x11Context.fMask &= ~kGCTile; - } - - // if (mask & kGCTileStipXOrigin) x11Context.fTsXOrigin = gval->fTsXOrigin; if (mask & kGCTileStipYOrigin) @@ -2401,7 +3023,7 @@ bool ParentRendersToChild(NSView *child) // window "wid". assert(!fPimpl->IsRootWindow(wid) && "SetCursor, called for 'root' window"); - NSView *view = fPimpl->GetWindow(wid).fContentView; + NSView * const view = fPimpl->GetWindow(wid).fContentView; view.fCurrentCursor = cursor; } @@ -2412,152 +3034,310 @@ bool ParentRendersToChild(NSView *child) // window "wid". if (cursorID > 0) SetCursor(Int_t(wid), ECursor(cursorID - 1)); + else + SetCursor(Int_t(wid), kPointer); } //______________________________________________________________________________ -void TGCocoa::NextEvent(Event_t &/*event*/) +void TGCocoa::QueryPointer(Int_t &x, Int_t &y) { + // Returns the pointer position. + + //I ignore fSelectedDrawable here. If you have any problems with this, hehe, you can ask me :) + const NSPoint screenPoint = [NSEvent mouseLocation]; + x = X11::GlobalXCocoaToROOT(screenPoint.x); + y = X11::GlobalYCocoaToROOT(screenPoint.y); } //______________________________________________________________________________ -void TGCocoa::GetPasteBuffer(Window_t /*id*/, Atom_t /*atom*/, TString &/*text*/, Int_t &/*nchar*/, Bool_t /*del*/) +void TGCocoa::QueryPointer(Window_t winID, Window_t &rootWinID, Window_t &childWinID, Int_t &rootX, Int_t &rootY, Int_t &winX, Int_t &winY, UInt_t &mask) { - // Gets contents of the paste buffer "atom" into the string "text". - // (nchar = number of characters) If "del" is true deletes the paste - // buffer afterwards. + //Emulate XQueryPointer(?). + + //From TGX11/TGWin32. + if (!winID) + return;//Neither TGX11, nor TGWin32 set any of out parameters. + + //We have only one root window. + rootWinID = fPimpl->GetRootWindowID(); + //Find cursor position (screen coordinates). + NSPoint screenPoint = [NSEvent mouseLocation]; + screenPoint.x = X11::GlobalXCocoaToROOT(screenPoint.x); + screenPoint.y = X11::GlobalYCocoaToROOT(screenPoint.y); + rootX = screenPoint.x; + rootY = screenPoint.y; + + //Convert a screen point to winID's coordinate system. + if (winID > fPimpl->GetRootWindowID()) { + NSObject * const window = fPimpl->GetWindow(winID); + const NSPoint winPoint = X11::TranslateFromScreen(screenPoint, window.fContentView); + winX = winPoint.x; + winY = winPoint.y; + } else { + //Warning("QueryPointer", "Window %d parameter is a root window", (int)winID); + winX = 0; + winY = 0; + } + + //Find child window in these coordinates (?). + if (QuartzWindow * const childWin = X11::FindWindowInPoint(screenPoint.x, screenPoint.y)) { + childWinID = childWin.fID; + mask = X11::GetModifiers(); + } else { + childWinID = 0; + mask = 0; + } } +//OpenGL management. + //______________________________________________________________________________ -void TGCocoa::CreateOpenGLContext(Int_t /*wid*/) +Double_t TGCocoa::GetOpenGLScalingFactor() { - // Creates OpenGL context for window "wid" + //Scaling factor to let our OpenGL code know, that we probably + //work on a retina display. + + return [[NSScreen mainScreen] backingScaleFactor]; } //______________________________________________________________________________ -void TGCocoa::DeleteOpenGLContext(Int_t /*wid*/) +Window_t TGCocoa::CreateOpenGLWindow(Window_t parentID, UInt_t width, UInt_t height, const std::vector > &formatComponents) { - // Deletes OpenGL context for window "wid" + //ROOT never creates GL widgets with 'root' as a parent (so not top-level gl-windows). + //If this change, assert must be deleted. + typedef std::pair component_type; + typedef std::vector::size_type size_type; + + //Convert pairs into Cocoa's GL attributes. + std::vector attribs; + for (size_type i = 0, e = formatComponents.size(); i < e; ++i) { + const component_type &comp = formatComponents[i]; + + if (comp.first == Rgl::kDoubleBuffer) { + attribs.push_back(NSOpenGLPFADoubleBuffer); + } else if (comp.first == Rgl::kDepth) { + attribs.push_back(NSOpenGLPFADepthSize); + attribs.push_back(comp.second > 0 ? comp.second : 32); + } else if (comp.first == Rgl::kAccum) { + attribs.push_back(NSOpenGLPFAAccumSize); + attribs.push_back(comp.second > 0 ? comp.second : 1); + } else if (comp.first == Rgl::kStencil) { + attribs.push_back(NSOpenGLPFAStencilSize); + attribs.push_back(comp.second > 0 ? comp.second : 8); + } else if (comp.first == Rgl::kMultiSample) { + attribs.push_back(NSOpenGLPFAMultisample); + attribs.push_back(NSOpenGLPFASampleBuffers); + attribs.push_back(1); + attribs.push_back(NSOpenGLPFASamples); + attribs.push_back(comp.second ? comp.second : 8); + } + } + + attribs.push_back(NSOpenGLPFAAccelerated);//??? I think, TGLWidget always wants this. + attribs.push_back(0); + + NSOpenGLPixelFormat * const pixelFormat = [[NSOpenGLPixelFormat alloc] initWithAttributes : &attribs[0]]; + const Util::NSScopeGuard formatGuard(pixelFormat); + + NSView *parentView = nil; + if (!fPimpl->IsRootWindow(parentID)) { + parentView = fPimpl->GetWindow(parentID).fContentView; + assert([parentView isKindOfClass : [QuartzView class]] && "CreateOpenGLWindow, parent view must be QuartzView"); + } + + NSRect viewFrame = {}; + viewFrame.size.width = width; + viewFrame.size.height = height; + + ROOTOpenGLView * const glView = [[ROOTOpenGLView alloc] initWithFrame : viewFrame pixelFormat : pixelFormat]; + const Util::NSScopeGuard viewGuard(glView); + + Window_t glID = kNone; + + if (parentView) { + [parentView addChild : glView]; + glID = fPimpl->RegisterDrawable(glView); + glView.fID = glID; + } else { + //"top-level glview". + //Create a window to be parent of this gl-view. + QuartzWindow *parent = [[QuartzWindow alloc] initWithGLView : glView]; + const Util::NSScopeGuard winGuard(parent); + + + if (!parent) { + Error("CreateOpenGLWindow", "QuartzWindow allocation/initialization failed for a top-level GL widget"); + return kNone; + } + + glID = fPimpl->RegisterDrawable(parent); + parent.fID = glID; + } + + return glID; } //______________________________________________________________________________ -UInt_t TGCocoa::ExecCommand(TGWin32Command * /*code*/) +Handle_t TGCocoa::CreateOpenGLContext(Window_t windowID, Handle_t sharedID) { - // Executes the command "code" coming from the other threads (Win32) - return 0; + assert(!fPimpl->IsRootWindow(windowID) && "CreateOpenGLContext, windowID is a 'root' window"); + assert([fPimpl->GetWindow(windowID).fContentView isKindOfClass : [ROOTOpenGLView class]] && + "CreateOpenGLContext, view is not an OpenGL view"); + + NSOpenGLContext * const sharedContext = fPimpl->GetGLContextForHandle(sharedID); + ROOTOpenGLView * const glView = (ROOTOpenGLView *)fPimpl->GetWindow(windowID); + + const Util::NSScopeGuard newContext([[NSOpenGLContext alloc] initWithFormat : glView.pixelFormat shareContext : sharedContext]); + glView.fOpenGLContext = newContext.Get(); + const Handle_t ctxID = fPimpl->RegisterGLContext(newContext.Get()); + + return ctxID; } //______________________________________________________________________________ -Int_t TGCocoa::GetDoubleBuffer(Int_t /*wid*/) +void TGCocoa::CreateOpenGLContext(Int_t /*wid*/) { - // Queries the double buffer value for the window "wid". - return 0; + // Creates OpenGL context for window "wid" } //______________________________________________________________________________ -void TGCocoa::GetCharacterUp(Float_t &chupx, Float_t &chupy) +Bool_t TGCocoa::MakeOpenGLContextCurrent(Handle_t ctxID, Window_t windowID) { - // Returns character up vector. - chupx = chupy = 0; + assert(ctxID > 0 && "MakeOpenGLContextCurrent, invalid context id"); + + NSOpenGLContext * const glContext = fPimpl->GetGLContextForHandle(ctxID); + if (!glContext) { + Error("MakeOpenGLContextCurrent", "No OpenGL context found for id %d", int(ctxID)); + + return kFALSE; + } + + ROOTOpenGLView * const glView = (ROOTOpenGLView *)fPimpl->GetWindow(windowID).fContentView; + + if (OpenGL::GLViewIsValidDrawable(glView)) { + if ([glContext view] != glView) + [glContext setView : glView]; + + if (glView.fUpdateContext) { + [glContext update]; + glView.fUpdateContext = NO; + } + + glView.fOpenGLContext = glContext; + [glContext makeCurrentContext]; + + return kTRUE; + } else { + //Oh, here's the real black magic. + //Our brilliant GL code is sure that MakeCurrent always succeeds. + //But it does not: if view is not visible, context can not be attached, + //gl operations will fail. + //Funny enough, but if you have invisible window with visible view, + //this trick works. + + //TODO: this code is a total mess, refactor. + + NSView *fakeView = nil; + QuartzWindow *fakeWindow = fPimpl->GetFakeGLWindow(); + + if (!fakeWindow) { + //We did not find any window. Create a new one. + SetWindowAttributes_t attr = {}; + const UInt_t width = std::max(glView.frame.size.width, CGFloat(100));//100 - is just a stupid hardcoded value. + const UInt_t height = std::max(glView.frame.size.height, CGFloat(100)); + + NSRect viewFrame = {}; + viewFrame.size.width = width; + viewFrame.size.height = height; + + const NSUInteger styleMask = NSTitledWindowMask | NSClosableWindowMask | NSMiniaturizableWindowMask | NSResizableWindowMask; + + //NOTE: defer parameter is 'NO', otherwise this trick will not help. + fakeWindow = [[QuartzWindow alloc] initWithContentRect : viewFrame styleMask : styleMask backing : NSBackingStoreBuffered defer : NO windowAttributes : &attr]; + Util::NSScopeGuard winGuard(fakeWindow); + + fakeView = fakeWindow.fContentView; + [fakeView setHidden : NO];//! + + fPimpl->SetFakeGLWindow(fakeWindow);//Can throw. + winGuard.Release(); + } else { + fakeView = fakeWindow.fContentView; + [fakeView setHidden : NO]; + } + + glView.fOpenGLContext = nil; + [glContext setView : fakeView]; + [glContext makeCurrentContext]; + } + + return kTRUE; } //______________________________________________________________________________ -Handle_t TGCocoa::GetNativeEvent() const +Handle_t TGCocoa::GetCurrentOpenGLContext() { - // Returns the current native event handle. - return 0; + NSOpenGLContext * const currentContext = [NSOpenGLContext currentContext]; + if (!currentContext) { + Error("GetCurrentOpenGLContext", "The current OpenGL context is null"); + return kNone; + } + + const Handle_t contextID = fPimpl->GetHandleForGLContext(currentContext); + if (!contextID) + Error("GetCurrentOpenGLContext", "The current OpenGL context was not created/registered by TGCocoa"); + + return contextID; } //______________________________________________________________________________ -void TGCocoa::QueryPointer(Int_t & /*ix*/, Int_t &/*iy*/) +void TGCocoa::FlushOpenGLBuffer(Handle_t ctxID) { - // Returns the pointer position. + assert(ctxID > 0 && "FlushOpenGLBuffer, invalid context id"); + + NSOpenGLContext * const glContext = fPimpl->GetGLContextForHandle(ctxID); + assert(glContext != nil && "FlushOpenGLBuffer, bad context id"); + + if (glContext != [NSOpenGLContext currentContext])//??? + return; + + glFlush();//??? + [glContext flushBuffer]; } //______________________________________________________________________________ -Pixmap_t TGCocoa::ReadGIF(Int_t /*x0*/, Int_t /*y0*/, const char * /*file*/, Window_t /*id*/) +void TGCocoa::DeleteOpenGLContext(Int_t ctxID) { - // If id is NULL - loads the specified gif file at position [x0,y0] in the - // current window. Otherwise creates pixmap from gif file - - return 0; -} - -//______________________________________________________________________________ -Int_t TGCocoa::RequestLocator(Int_t /*mode*/, Int_t /*ctyp*/, Int_t &/*x*/, Int_t &/*y*/) -{ - // Requests Locator position. - // x,y - cursor position at moment of button press (output) - // ctyp - cursor type (input) - // ctyp = 1 tracking cross - // ctyp = 2 cross-hair - // ctyp = 3 rubber circle - // ctyp = 4 rubber band - // ctyp = 5 rubber rectangle - // - // mode - input mode - // mode = 0 request - // mode = 1 sample - // - // The returned value is: - // in request mode: - // 1 = left is pressed - // 2 = middle is pressed - // 3 = right is pressed - // in sample mode: - // 11 = left is released - // 12 = middle is released - // 13 = right is released - // -1 = nothing is pressed or released - // -2 = leave the window - // else = keycode (keyboard is pressed) - - return 0; -} - -//______________________________________________________________________________ -Int_t TGCocoa::RequestString(Int_t /*x*/, Int_t /*y*/, char * /*text*/) -{ - // Requests string: text is displayed and can be edited with Emacs-like - // keybinding. Returns termination code (0 for ESC, 1 for RETURN) - // - // x,y - position where text is displayed - // text - displayed text (as input), edited text (as output) - return 0; -} - -//______________________________________________________________________________ -void TGCocoa::SetCharacterUp(Float_t /*chupx*/, Float_t /*chupy*/) -{ - // Sets character up vector. -} + //Historically, DeleteOpenGLContext was accepting window id, + //now it's a context id. DeleteOpenGLContext is not used in ROOT, + //only in TGLContext for Cocoa. + NSOpenGLContext * const glContext = fPimpl->GetGLContextForHandle(ctxID); + if (NSView * const v = [glContext view]) { + if ([v isKindOfClass : [ROOTOpenGLView class]]) + ((ROOTOpenGLView *)v).fOpenGLContext = nil; + + [glContext clearDrawable]; + } + + if (glContext == [NSOpenGLContext currentContext]) + [NSOpenGLContext clearCurrentContext]; -//______________________________________________________________________________ -void TGCocoa::SetClipOFF(Int_t /*wid*/) -{ - // Turns off the clipping for the window "wid". + fPimpl->DeleteGLContext(ctxID); } -//______________________________________________________________________________ -void TGCocoa::SetClipRegion(Int_t /*wid*/, Int_t /*x*/, Int_t /*y*/, UInt_t /*w*/, UInt_t /*h*/) -{ - // Sets clipping region for the window "wid". - // - // wid - window indentifier - // x, y - origin of clipping rectangle - // w, h - the clipping rectangle dimensions - -} +//Off-screen rendering for TPad/TCanvas. //______________________________________________________________________________ -void TGCocoa::SetDoubleBuffer(Int_t wid, Int_t mode) +void TGCocoa::SetDoubleBuffer(Int_t windowID, Int_t mode) { //In ROOT, canvas has a "double buffer" - pixmap attached to 'wid'. - assert(wid > fPimpl->GetRootWindowID() && "SetDoubleBuffer called for 'root' window"); + assert(windowID > (Int_t)fPimpl->GetRootWindowID() && "SetDoubleBuffer called for 'root' window"); - if (wid == 999) {//Comment in TVirtaulX suggests, that 999 means all windows. + if (windowID == 999) {//Comment in TVirtaulX suggests, that 999 means all windows. Warning("SetDoubleBuffer", "called with wid == 999"); + //Window with id 999 can not exists - this is checked in CocoaPrivate. } else { - fSelectedDrawable = wid; + fSelectedDrawable = windowID; mode ? SetDoubleBufferON() : SetDoubleBufferOFF(); } } @@ -2576,35 +3356,23 @@ bool ParentRendersToChild(NSView *child) assert(fSelectedDrawable > fPimpl->GetRootWindowID() && "SetDoubleBufferON, called, but no correct window was selected before"); - NSObject *window = fPimpl->GetWindow(fSelectedDrawable); + NSObject * const window = fPimpl->GetWindow(fSelectedDrawable); assert(window.fIsPixmap == NO && "SetDoubleBufferON, selected drawable is a pixmap, can not attach pixmap to pixmap"); const unsigned currW = window.fWidth; const unsigned currH = window.fHeight; - if (QuartzPixmap *currentPixmap = window.fBackBuffer) { + if (QuartzPixmap *const currentPixmap = window.fBackBuffer) { if (currH == currentPixmap.fHeight && currW == currentPixmap.fWidth) return; } - try { - Util::NSScopeGuard mem([QuartzPixmap alloc]); - if (QuartzPixmap *pixmap = [mem.Get() initWithW : currW H : currH]) { - mem.Reset(pixmap); - pixmap.fID = fPimpl->RegisterDrawable(pixmap);//Can throw. - if (window.fBackBuffer) {//Now we can delete the old one, since the new was created. - if (fPimpl->fX11CommandBuffer.BufferSize()) - fPimpl->fX11CommandBuffer.RemoveOperationsForDrawable(window.fBackBuffer.fID); - fPimpl->DeleteDrawable(window.fBackBuffer.fID); - } - - window.fBackBuffer = pixmap; - } else { - Error("SetDoubleBufferON", "Can't create a pixmap"); - } - } catch (const std::exception &) {//std::bad_alloc. - throw; + Util::NSScopeGuard pixmap([[QuartzPixmap alloc] initWithW : currW H : currH scaleFactor : [[NSScreen mainScreen] backingScaleFactor]]); + if (pixmap.Get()) { + window.fBackBuffer = pixmap.Get(); + } else { + Error("SetDoubleBufferON", "QuartzPixmap initialization failed");//More concrete message was issued by QuartzPixmap. } } @@ -2617,548 +3385,710 @@ bool ParentRendersToChild(NSView *child) fDrawMode = mode; } +//Event management part. + //______________________________________________________________________________ -void TGCocoa::SetTextMagnitude(Float_t /*mgn*/) +void TGCocoa::SendEvent(Window_t wid, Event_t *event) { - // Sets the current text magnification factor to "mgn" + if (fPimpl->IsRootWindow(wid))//ROOT's GUI can send events to 'root' window. + return; + + if (!wid || !event) //From TGX11. + return; + + Event_t newEvent = *event; + newEvent.fWindow = wid; + fPimpl->fX11EventTranslator.fEventQueue.push_back(newEvent); } //______________________________________________________________________________ -void TGCocoa::Sync(Int_t /*mode*/) +void TGCocoa::NextEvent(Event_t &event) { - // Set synchronisation on or off. - // mode : synchronisation on/off - // mode=1 on - // mode<>0 off + assert(fPimpl->fX11EventTranslator.fEventQueue.size() > 0 && "NextEvent, event queue is empty"); + + event = fPimpl->fX11EventTranslator.fEventQueue.front(); + fPimpl->fX11EventTranslator.fEventQueue.pop_front(); } //______________________________________________________________________________ -void TGCocoa::Warp(Int_t /*ix*/, Int_t /*iy*/, Window_t /*id*/) +Int_t TGCocoa::EventsPending() { - // Sets the pointer position. - // ix - new X coordinate of pointer - // iy - new Y coordinate of pointer - // Coordinates are relative to the origin of the window id - // or to the origin of the current window if id == 0. + return (Int_t)fPimpl->fX11EventTranslator.fEventQueue.size(); } + //______________________________________________________________________________ -Int_t TGCocoa::WriteGIF(char * /*name*/) +Bool_t TGCocoa::CheckEvent(Window_t windowID, EGEventType type, Event_t &event) { - // Writes the current window into GIF file. - // Returns 1 in case of success, 0 otherwise. + typedef X11::EventQueue_t::iterator iterator_type; + + iterator_type it = fPimpl->fX11EventTranslator.fEventQueue.begin(); + iterator_type eIt = fPimpl->fX11EventTranslator.fEventQueue.end(); + + for (; it != eIt; ++it) { + const Event_t &queuedEvent = *it; + if (queuedEvent.fWindow == windowID && queuedEvent.fType == type) { + event = queuedEvent; + fPimpl->fX11EventTranslator.fEventQueue.erase(it); + return kTRUE; + } + } - return 0; + return kFALSE; } //______________________________________________________________________________ -void TGCocoa::WritePixmap(Int_t /*wid*/, UInt_t /*w*/, UInt_t /*h*/, char * /*pxname*/) +Handle_t TGCocoa::GetNativeEvent() const { - // Writes the pixmap "wid" in the bitmap file "pxname". - // - // wid - the pixmap address - // w, h - the width and height of the pixmap. - // pxname - the file name + //I can not give an access to the native event, + //it even, probably, does not exist already. + return kNone; } -//______________________________________________________________________________ -Bool_t TGCocoa::NeedRedraw(ULong_t /*tgwindow*/, Bool_t /*force*/) -{ - // Notify the low level GUI layer ROOT requires "tgwindow" to be - // updated - // - // Returns kTRUE if the notification was desirable and it was sent - // - // At the moment only Qt4 layer needs that - // - // One needs explicitly cast the first parameter to TGWindow to make - // it working in the implementation. - // - // One needs to process the notification to confine - // all paint operations within "expose" / "paint" like low level event - // or equivalent - - return kFALSE; -} +//"Drag and drop", "Copy and paste", X11 properties. +//Quite preliminary and not-tested yet. //______________________________________________________________________________ -Atom_t TGCocoa::InternAtom(const char *atomName, Bool_t /*only_if_exist*/) +Atom_t TGCocoa::InternAtom(const char *name, Bool_t onlyIfExist) { //X11 properties emulation. //TODO: this is a temporary hack to make //client message (close window) work. - assert(atomName != 0 && "InternAtom, atomName is null"); - - if (!std::strcmp(atomName, "WM_DELETE_WINDOW")) - return kIA_DELETE_WINDOW; - else if (!std::strcmp(atomName, "_ROOT_MESSAGE")) - return kIA_ROOT_MESSAGE; - - return Atom_t(); + assert(name != 0 && "InternAtom, atomName parameter is null"); + return FindAtom(name, !onlyIfExist); } //______________________________________________________________________________ -Bool_t TGCocoa::CreatePictureFromFile(Drawable_t /*wid*/, - const char * /*filename*/, - Pixmap_t &/*pict*/, - Pixmap_t &/*pict_mask*/, - PictureAttributes_t &/*attr*/) +void TGCocoa::SetPrimarySelectionOwner(Window_t windowID) { - // Creates a picture pict from data in file "filename". The picture - // attributes "attr" are used for input and output. Returns kTRUE in - // case of success, kFALSE otherwise. If the mask "pict_mask" does not - // exist it is set to kNone. - - return kFALSE; -} + //Comment from TVirtualX: + // Makes the window "wid" the current owner of the primary selection. + // That is the window in which, for example some text is selected. + //End of comment. + + //It's not clear, why SetPrimarySelectionOwner and SetSelectionOwner have different return types. + + if (!windowID)//From TGWin32. + return; -//______________________________________________________________________________ -Bool_t TGCocoa::CreatePictureFromData(Drawable_t /*wid*/, char ** /*data*/, - Pixmap_t &/*pict*/, - Pixmap_t &/*pict_mask*/, - PictureAttributes_t & /*attr*/) -{ - // Creates a picture pict from data in bitmap format. The picture - // attributes "attr" are used for input and output. Returns kTRUE in - // case of success, kFALSE otherwise. If the mask "pict_mask" does not - // exist it is set to kNone. + //TODO: check, if this really happens and probably remove assert. + assert(!fPimpl->IsRootWindow(windowID) && "SetPrimarySelectionOwner, windowID parameter is a 'root' window"); + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "SetPrimarySelectionOwner, windowID parameter is not a valid window"); - return kFALSE; -} -//______________________________________________________________________________ -Bool_t TGCocoa::ReadPictureDataFromFile(const char * /*filename*/, char *** /*ret_data*/) -{ - // Reads picture data from file "filename" and store it in "ret_data". - // Returns kTRUE in case of success, kFALSE otherwise. + const Atom_t primarySelectionAtom = FindAtom("XA_PRIMARY", false); + assert(primarySelectionAtom != kNone && "SetPrimarySelectionOwner, predefined XA_PRIMARY atom was not found"); - return kFALSE; + fSelectionOwners[primarySelectionAtom] = windowID; + //No events will be send - I do not have different clients, so nobody to send SelectionClear. } //______________________________________________________________________________ -void TGCocoa::DeletePictureData(void * /*data*/) +Bool_t TGCocoa::SetSelectionOwner(Window_t windowID, Atom_t &selection) { - // Delete picture data created by the function ReadPictureDataFromFile. -} + //Comment from TVirtualX: + // Changes the owner and last-change time for the specified selection. + //End of comment. + + //It's not clear, why SetPrimarySelectionOwner and SetSelectionOwner have different return types. + + if (!windowID) + return kFALSE; + + assert(!fPimpl->IsRootWindow(windowID) && "SetSelectionOwner, windowID parameter is a 'root' window'"); + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "SetSelectionOwner, windowID parameter is not a valid window"); + + fSelectionOwners[selection] = windowID; + //No messages, since I do not have different clients. -//______________________________________________________________________________ -void TGCocoa::SetDashes(GContext_t /*gc*/, Int_t /*offset*/, const char * /*dash_list*/, Int_t /*n*/) -{ - // Sets the dash-offset and dash-list attributes for dashed line styles - // in the specified GC. There must be at least one element in the - // specified dash_list. The initial and alternating elements (second, - // fourth, and so on) of the dash_list are the even dashes, and the - // others are the odd dashes. Each element in the "dash_list" array - // specifies the length (in pixels) of a segment of the pattern. - // - // gc - specifies the GC (see GCValues_t structure) - // offset - the phase of the pattern for the dashed line-style you - // want to set for the specified GC. - // dash_list - the dash-list for the dashed line-style you want to set - // for the specified GC - // n - the number of elements in dash_list - // (see also the GCValues_t structure) + return kTRUE; } //______________________________________________________________________________ -Int_t TGCocoa::EventsPending() +Window_t TGCocoa::GetPrimarySelectionOwner() { - // Returns the number of events that have been received from the X server - // but have not been removed from the event queue. - return 0; -} + //Comment from TVirtualX: + // Returns the window id of the current owner of the primary selection. + // That is the window in which, for example some text is selected. + //End of comment. + const Atom_t primarySelectionAtom = FindAtom("XA_PRIMARY", false); + assert(primarySelectionAtom != kNone && "GetPrimarySelectionOwner, predefined XA_PRIMARY atom was not found"); -//______________________________________________________________________________ -void TGCocoa::Bell(Int_t /*percent*/) -{ - // Sets the sound bell. Percent is loudness from -100% .. 100%. + return fSelectionOwners[primarySelectionAtom]; } //______________________________________________________________________________ -void TGCocoa::ChangeProperty(Window_t /*wid*/, Atom_t /*property*/, - Atom_t /*type*/, UChar_t * /*data*/, - Int_t /*len*/) +void TGCocoa::ConvertPrimarySelection(Window_t windowID, Atom_t clipboard, Time_t when) { - // Alters the property for the specified window and causes the X server - // to generate a PropertyNotify event on that window. - // - // wid - the window whose property you want to change - // property - specifies the property name - // type - the type of the property; the X server does not - // interpret the type but simply passes it back to - // an application that might ask about the window - // properties - // data - the property data - // len - the length of the specified data format -} + //Comment from TVirtualX: + // Causes a SelectionRequest event to be sent to the current primary + // selection owner. This event specifies the selection property + // (primary selection), the format into which to convert that data before + // storing it (target = XA_STRING), the property in which the owner will + // place the information (sel_property), the window that wants the + // information (id), and the time of the conversion request (when). + // The selection owner responds by sending a SelectionNotify event, which + // confirms the selected atom and type. + //End of comment. + + if (!windowID)//From TGWin32. + return; -//______________________________________________________________________________ -Bool_t TGCocoa::CheckEvent(Window_t /*wid*/, EGEventType /*type*/, Event_t & /*ev*/) -{ - //No need in this. - return kFALSE; -} + assert(!fPimpl->IsRootWindow(windowID) && "ConvertPrimarySelection, windowID parameter is a 'root' window"); + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "ConvertPrimarySelection, windowID parameter is not a valid window"); + + Atom_t primarySelectionAtom = FindAtom("XA_PRIMARY", false); + assert(primarySelectionAtom != kNone && "ConvertPrimarySelection, XA_PRIMARY predefined atom not found"); + + Atom_t stringAtom = FindAtom("XA_STRING", false); + assert(stringAtom != kNone && "ConvertPrimarySelection, XA_STRING predefined atom not found"); -///////////////////////////////////////////////////////// -// Next three functions are quite ugly piece of code -// for now. SendEvent is called by GUI classes to, for example, -// execute menu actions or for similar purposes (button was pressed). -// -// Problems: -// 1. I can not dispatch them immediately: -// some commands can call DestroWindow(DestroySubwindows), -// for example, on button release event in a dialog, and at the same time -// on button release event GUI wants to repaint unpressed button (for example). -// But if window was deleted, repaint will cause a crash. So, event is "sent" - -// I put it into NSApplication's event queue. This -// also has an obvious problem: -// 2. I put it into NSApplication event queue, and it -// will be (probably) extracted and processed almost immediately after I put it here. -// So in case we execute something heavy and time-consuming, GUI (probably) will "hang". -// 3. Next problem, during execution of sent events, window can be destroyed before -// all events for this window were processed. -// -// For now the solution is the following: -// a) SendEvent creates NSEvent (of type NSApplicationDefined) and puts it into event queue. -// MessageID for this event is "allocated" and saved in data2 property of NSEvent. -// Map Window_t -> events_for_window is filled. -// b) TMacOSXSystem extracts user-defined event from the queue and tries to execute it, using messageID - -// calls DispatchClientMessage function. DispatchClientMessage checks, if Event_t for messageID -// can be found, and if yes (this assumes window is alive yet) calls window->HandleEvent(clientMessage). -// If DestroyWindow is called for window, I also check, if any events for this window -// were queued and delete them, so if event queue still has events for this window (this can happen :( ) - -// they will not be executed. -// -// TODO: One thing I can try, instead of NSApplication's queue use queue data member in TGCocoa, -// and process queued messages at the end of event loop's iteration (this solution, probably, -// will have the same problems as NSApplication's queue). + ConvertSelection(windowID, primarySelectionAtom, stringAtom, clipboard, when); +} //______________________________________________________________________________ -void TGCocoa::SendEvent(Window_t wid, Event_t *event) +void TGCocoa::ConvertSelection(Window_t windowID, Atom_t &selection, Atom_t &target, Atom_t &property, Time_t &/*timeStamp*/) { - if (fPimpl->IsRootWindow(wid))//ROOT's GUI can send events to 'root' window. + // Requests that the specified selection be converted to the specified + // target type. + + // Requests that the specified selection be converted to the specified + // target type. + + if (!windowID) return; - if (!wid || !event) //From TGX11. - return; + assert(!fPimpl->IsRootWindow(windowID) && "ConvertSelection, windowID parameter is a 'root' window'"); + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "ConvertSelection, windowID parameter is not a valid window"); - UInt_t messageID = fCurrentMessageID; - if (fFreeMessageIDs.size()) { - messageID = fFreeMessageIDs.back(); - fFreeMessageIDs.pop_back(); - } else - ++fCurrentMessageID; - - //Window 'wid' has an event with number 'messageID' in a NSApplication's queue. - fClientMessagesToWindow[wid].push_back(messageID); + Event_t newEvent = {}; + selection_iterator selIter = fSelectionOwners.find(selection); + + if (selIter != fSelectionOwners.end()) + newEvent.fType = kSelectionRequest; + else + newEvent.fType = kSelectionNotify; - const ClientMessage_t newMessage(wid, *event); - assert(fClientMessages.find(messageID) == fClientMessages.end() && "SendEvent, messageID is already busy"); - fClientMessages[messageID] = newMessage; + newEvent.fWindow = windowID; + newEvent.fUser[0] = windowID;//requestor + newEvent.fUser[1] = selection; + newEvent.fUser[2] = target; + newEvent.fUser[3] = property; - NSEvent *cocoaEvent = [NSEvent otherEventWithType : NSApplicationDefined location : NSMakePoint(0, 0) modifierFlags : 0 - timestamp: 0. windowNumber : 0 context : nil subtype : 0 data1 : 0 data2 : NSInteger(messageID)]; - [NSApp postEvent : cocoaEvent atStart : NO]; + SendEvent(windowID, &newEvent); } //______________________________________________________________________________ -void TGCocoa::DispatchClientMessage(UInt_t messageID) +Int_t TGCocoa::GetProperty(Window_t windowID, Atom_t propertyID, Long_t, Long_t, Bool_t, Atom_t, + Atom_t *actualType, Int_t *actualFormat, ULong_t *nItems, ULong_t *bytesAfterReturn, unsigned char **propertyReturn) { - assert(messageID != 0 && "DispatchClientMessage, messageID parameter is 0"); - - message_iterator messageIter = fClientMessages.find(messageID); - if (messageIter == fClientMessages.end()) { - //Window for such event was deleted already? - return; - } + //Comment from TVirtualX: + // Returns the actual type of the property; the actual format of the property; + // the number of 8-bit, 16-bit, or 32-bit items transferred; the number of + // bytes remaining to be read in the property; and a pointer to the data + // actually returned. + //End of comment. + + //TODO: actually, property can be set for a 'root' window. I have to save this data somehow. + if (fPimpl->IsRootWindow(windowID)) + return 0; + + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "GetProperty, windowID is not a valid window id"); + assert(propertyID > 0 && propertyID <= fAtomToName.size() && "GetProperty, propertyID parameter is not a valid atom"); + assert(actualType != 0 && "GetProperty, actualType parameter is null"); + assert(actualFormat != 0 && "GetProperty, actualFormat parameter is null"); + assert(bytesAfterReturn != 0 && "GetProperty, bytesAfterReturn parameter is null"); + assert(propertyReturn != 0 && "GetProperty, propertyReturn parameter is null"); - NSObject *widget = fPimpl->GetDrawable(messageIter->second.first);//:) - assert(widget.fID != 0 && "DispatchClientMessage, widget.fID is 0"); + const Util::AutoreleasePool pool; + + *bytesAfterReturn = 0;//In TGWin32 the value set to .. nItems? + *propertyReturn = 0; + *nItems = 0; + + const std::string &atomName = fAtomToName[propertyID - 1]; + NSObject *window = fPimpl->GetWindow(windowID); - TGWindow *window = gClient->GetWindowById(widget.fID); - assert(window != 0 && "DispatchClientMessage, no window was found"); - Event_t clientMessage = messageIter->second.second; + if (![window hasProperty : atomName.c_str()]) { + Error("GetProperty", "Unknown property %s requested", atomName.c_str()); + return 0;//actually, 0 is ... Success (X11)? + } - fClientMessages.erase(messageIter); - fFreeMessageIDs.push_back(messageID); + unsigned tmpFormat = 0, tmpElements = 0; + *propertyReturn = [window getProperty : atomName.c_str() returnType : actualType returnFormat : &tmpFormat nElements : &tmpElements]; + *actualFormat = (Int_t)tmpFormat; + *nItems = tmpElements; - window->HandleEvent(&clientMessage); + return *nItems;//Success (X11) is 0? } //______________________________________________________________________________ -void TGCocoa::RemoveEventsForWindow(Window_t wid) +void TGCocoa::GetPasteBuffer(Window_t windowID, Atom_t propertyID, TString &text, Int_t &nChars, Bool_t clearBuffer) { - //Window 'wid' will be deleted, do not process any events for it (if - //we have any in NSApplication's queue). - //Remove events for window 'wid', recycle event IDs for future use. - //Remove entry for window 'wid' and all its event IDs. - typedef std::vector::size_type size_type; + //Comment from TVirtualX: + // Gets contents of the paste buffer "atom" into the string "text". + // (nchar = number of characters) If "del" is true deletes the paste + // buffer afterwards. + //End of comment. - message_window_iterator iter = fClientMessagesToWindow.find(wid); - if (iter != fClientMessagesToWindow.end()) { - const std::vector &messages = iter->second; - for (size_type i = 0, e = messages.size(); i < e; ++i) { - message_iterator messageIter = fClientMessages.find(messages[i]); - if (messageIter != fClientMessages.end()) {//May be, it was deleted already as a result of some DispatchClientMessage?? - fClientMessages.erase(messageIter); - fFreeMessageIDs.push_back(messages[i]); - } - } + if (!windowID)//From TGX11. + return; + + assert(!fPimpl->IsRootWindow(windowID) && "GetPasteBuffer, windowID parameter is a 'root' window"); + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "GetPasteBuffer, windowID parameter is not a valid window"); + assert(propertyID && propertyID <= fAtomToName.size() && "GetPasteBuffer, propertyID parameter is not a valid atom"); + + const Util::AutoreleasePool pool; + + const std::string &atomString = fAtomToName[propertyID - 1]; + NSObject *window = fPimpl->GetWindow(windowID); + + if (![window hasProperty : atomString.c_str()]) { + Error("GetPasteBuffer", "No property %s on a window", atomString.c_str()); + return; + } - fClientMessagesToWindow.erase(iter); + Atom_t tmpType = 0; + unsigned tmpFormat = 0, nElements = 0; + + const Util::ScopedArray propertyData((char *)[window getProperty : atomString.c_str() returnType : &tmpType returnFormat : &tmpFormat nElements : &nElements]); + assert(tmpFormat == 8 && "GetPasteBuffer, property has wrong format"); + + text.Insert(0, propertyData.Get(), nElements); + nChars = (Int_t)nElements; + + if (clearBuffer) { + //For the moment - just remove the property (anyway, ChangeProperty/ChangeProperties will re-create it). + [window removeProperty : atomString.c_str()]; } } //______________________________________________________________________________ -void TGCocoa::WMDeleteNotify(Window_t /*wid*/) +void TGCocoa::ChangeProperty(Window_t windowID, Atom_t propertyID, Atom_t type, UChar_t *data, Int_t len) { - // Tells WM to send message when window is closed via WM. + //Comment from TVirtualX: + // Alters the property for the specified window and causes the X server + // to generate a PropertyNotify event on that window. + // + // wid - the window whose property you want to change + // property - specifies the property name + // type - the type of the property; the X server does not + // interpret the type but simply passes it back to + // an application that might ask about the window + // properties + // data - the property data + // len - the length of the specified data format + //End of comment. + + //TGX11 always calls XChangeProperty with PropModeReplace. + //I simply reset the property (or create a new one). + + if (!windowID) //From TGWin32. + return; + + if (!data || !len) //From TGWin32. + return; + + assert(!fPimpl->IsRootWindow(windowID) && "ChangeProperty, windowID parameter is a 'root' window"); + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "ChangeProperty, windowID parameter is not a valid window id"); + assert(propertyID && propertyID <= fAtomToName.size() && "ChangeProperty, propertyID parameter is not a valid atom"); + + const Util::AutoreleasePool pool; + + const std::string &atomString = fAtomToName[propertyID - 1]; + + NSObject * const window = fPimpl->GetWindow(windowID); + [window setProperty : atomString.c_str() data : data size : len forType : type format : 8]; + //ROOT ignores PropertyNotify events. } //______________________________________________________________________________ -void TGCocoa::SetKeyAutoRepeat(Bool_t /*on = kTRUE*/) +void TGCocoa::ChangeProperties(Window_t windowID, Atom_t propertyID, Atom_t type, Int_t format, UChar_t *data, Int_t len) { - // Turns key auto repeat on (kTRUE) or off (kFALSE). + //Comment from TVirtualX: + // Alters the property for the specified window and causes the X server + // to generate a PropertyNotify event on that window. + //End of comment. + + //TGX11 always calls XChangeProperty with PropModeReplace. + //I simply reset the property (or create a new one). + + if (!windowID)//From TGWin32. + return; + + if (!data || !len)//From TGWin32. + return; + + assert(!fPimpl->IsRootWindow(windowID) && "ChangeProperties, windowID parameter is a 'root' window"); + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "ChangeProperties, windowID parameter is not a valid window id"); + assert(propertyID && propertyID <= fAtomToName.size() && "ChangeProperties, propertyID parameter is not a valid atom"); + + const Util::AutoreleasePool pool; + + const std::string &atomName = fAtomToName[propertyID - 1]; + + NSObject * const window = fPimpl->GetWindow(windowID); + [window setProperty : atomName.c_str() data : data size : len forType : type format : format]; + //No property notify, ROOT does not know about this. } //______________________________________________________________________________ -void TGCocoa::GrabKey(Window_t wid, Int_t keyCode, UInt_t rootKeyModifiers, Bool_t grab) +void TGCocoa::DeleteProperty(Window_t windowID, Atom_t &propertyID) { - // Establishes a passive grab on the keyboard. In the future, the - // keyboard is actively grabbed, the last-keyboard-grab time is set - // to the time at which the key was pressed (as transmitted in the - // KeyPress event), and the KeyPress event is reported if all of the - // following conditions are true: - // - the keyboard is not grabbed and the specified key (which can - // itself be a modifier key) is logically pressed when the - // specified modifier keys are logically down, and no other - // modifier keys are logically down; - // - either the grab window "id" is an ancestor of (or is) the focus - // window, or "id" is a descendant of the focus window and contains - // the pointer; - // - a passive grab on the same key combination does not exist on any - // ancestor of grab_window - // - // id - window id - // keycode - specifies the KeyCode or AnyKey - // modifier - specifies the set of keymasks or AnyModifier; the mask is - // the bitwise inclusive OR of the valid keymask bits - // grab - a switch between grab/ungrab key - // grab = kTRUE grab the key and modifier - // grab = kFALSE ungrab the key and modifier + //Comment from TVirtualX: + // Deletes the specified property only if the property was defined on the + // specified window and causes the X server to generate a PropertyNotify + // event on the window unless the property does not exist. + //End of comment. - //Key code already must be Cocoa's key code, this is done by GUI classes, - //they call KeySymToKeyCode. + if (!windowID)//Can this happen? + return; - assert(!fPimpl->IsRootWindow(wid) && "GrabKey, called for 'root' window"); + //Strange signature - why propertyID is a reference? + //TODO: check, if ROOT sets/deletes properties on a 'root' window. + assert(!fPimpl->IsRootWindow(windowID) && "DeleteProperty, windowID parameter is a 'root' window"); + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "DeleteProperty, windowID parameter is not a valid window"); + assert(propertyID && propertyID <= fAtomToName.size() && "DeleteProperty, propertyID parameter is invalid atom"); + + const std::string &atomString = fAtomToName[propertyID - 1]; + [fPimpl->GetWindow(windowID) removeProperty : atomString.c_str()]; +} - NSView *view = fPimpl->GetWindow(wid).fContentView; +//______________________________________________________________________________ +void TGCocoa::SetDNDAware(Window_t windowID, Atom_t *typeList) +{ + //Comment from TVirtaulX: + // Add XdndAware property and the list of drag and drop types to the + // Window win. + //End of comment. - const NSUInteger cocoaKeyModifiers = X11::GetCocoaKeyModifiersFromROOTKeyModifiers(rootKeyModifiers); + + //TGX11 first replaces XdndAware property for a windowID, and then appends atoms from a typelist. + //I simply put all data for a property into a vector and set the property (either creating + //a new property or replacing the existing). + + assert(windowID > fPimpl->GetRootWindowID() && "SetDNDAware, windowID parameter is a bad window id"); + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "SetDNDAware, windowID parameter is not a window"); + + const Util::AutoreleasePool pool; + + QuartzView * const view = (QuartzView *)fPimpl->GetWindow(windowID).fContentView; + NSArray * const supportedTypes = [NSArray arrayWithObjects : NSFilenamesPboardType, nil];//In a pool. - if (grab) - [view addPassiveKeyGrab : keyCode modifiers : cocoaKeyModifiers]; - else - [view removePassiveKeyGrab : keyCode modifiers : cocoaKeyModifiers]; + //Do this for Cocoa - to make it possible to drag something to a + //ROOT's window (also this will change cursor shape while dragging). + [view registerForDraggedTypes : supportedTypes]; + //Declared property - for convenience, not to check atoms/shmatoms or X11 properties. + view.fIsDNDAware = YES; + + FindAtom("XdndAware", true);//Add it, if not yet. + const Atom_t xaAtomAtom = FindAtom("XA_ATOM", false); + + assert(xaAtomAtom == 4 && "SetDNDAware, XA_ATOM is not defined");//This is a predefined atom. + + //ROOT's GUI uses Atom_t, which is unsigned long, and it's 64-bit. + //While calling XChangeProperty, it passes the address of this typelist + //and format is ... 32. I have to pack data into unsigned and force the size: + assert(sizeof(unsigned) == 4 && "SetDNDAware, sizeof(unsigned) must be 4"); + //TODO: find fixed-width integer type (I do not have cstdint header at the moment?) + + std::vector propertyData; + propertyData.push_back(4);//This '4' is from TGX11 (is it XA_ATOM???) + + if (typeList) { + for (unsigned i = 0; typeList[i]; ++i) + propertyData.push_back(unsigned(typeList[i]));//hehe. + } + + [view setProperty : "XdndAware" data : (unsigned char *)&propertyData[0] size : propertyData.size() forType : xaAtomAtom format : 32]; } //______________________________________________________________________________ -void TGCocoa::SetMWMHints(Window_t wid, UInt_t value, UInt_t funcs, UInt_t /*input*/) +Bool_t TGCocoa::IsDNDAware(Window_t windowID, Atom_t * /*typeList*/) { - // Sets decoration style. - assert(!fPimpl->IsRootWindow(wid) && "SetMWMHints, called for 'root' window"); + //Checks if the Window is DND aware. typeList is ignored. + + if (windowID <= fPimpl->GetRootWindowID())//kNone or 'root'. + return kFALSE; - QuartzWindow *qw = fPimpl->GetWindow(wid).fQuartzWindow; - NSUInteger newMask = 0; + assert(fPimpl->GetDrawable(windowID).fIsPixmap == NO && "IsDNDAware, windowID parameter is not a window"); + + QuartzView * const view = (QuartzView *)fPimpl->GetWindow(windowID).fContentView; + return view.fIsDNDAware; +} + +//______________________________________________________________________________ +void TGCocoa::SetTypeList(Window_t, Atom_t, Atom_t *) +{ + // Add the list of drag and drop types to the Window win. - if ([qw styleMask] & NSTitledWindowMask) {//Do not modify this. - newMask |= NSTitledWindowMask; - newMask |= NSClosableWindowMask; - } + //It's never called from GUI. + + Warning("SetTypeList", "Not implemented"); +} - if (value & kMWMFuncAll) { - newMask |= NSMiniaturizableWindowMask | NSResizableWindowMask; - } else { - if (value & kMWMDecorMinimize) - newMask |= NSMiniaturizableWindowMask; - if (funcs & kMWMFuncResize) - newMask |= NSResizableWindowMask; - } +//______________________________________________________________________________ +Window_t TGCocoa::FindRWindow(Window_t winID, Window_t dragWinID, Window_t inputWinID, int x, int y, int maxDepth) +{ + //Comment from TVirtualX: - [qw setStyleMask : newMask]; + // Recursively search in the children of Window for a Window which is at + // location x, y and is DND aware, with a maximum depth of maxd. + // Ignore dragwin and input (???) + //End of comment from TVirtualX. + + + //Now my comments. The name of this function, as usually, says nothing about what it does. + //It's searching for some window, probably child of winID, or may be winID itself(?) and + //window must be DND aware. So the name should be FindDNDAwareWindowRecursively or something like this. - if (funcs & kMWMDecorAll) { - if (!qw.fMainWindow) {//Do not touch buttons for transient window. - [[qw standardWindowButton : NSWindowZoomButton] setEnabled : YES]; - [[qw standardWindowButton : NSWindowMiniaturizeButton] setEnabled : YES]; - } - } else { - if (!qw.fMainWindow) {//Do not touch transient window's titlebar. - [[qw standardWindowButton : NSWindowZoomButton] setEnabled : funcs & kMWMDecorMaximize]; - [[qw standardWindowButton : NSWindowMiniaturizeButton] setEnabled : funcs & kMWMDecorMinimize]; - } - } + //This function is not documented, comments suck as soon as they are simply wrong - the + //first return statement in X11 version contradicts with comments + //about child. Since X11 version is more readable, I'm reproducing X11 version here, + //and ... my code can't be wrong, since there is nothing right about this function. + + NSView * const testView = X11::FindDNDAwareViewInPoint(fPimpl->IsRootWindow(winID) ? nil : fPimpl->GetWindow(winID).fContentView, + dragWinID, inputWinID, x, y, maxDepth); + if (testView) + return testView.fID; + + return kNone; +} + +////////////// + +//______________________________________________________________________________ +UInt_t TGCocoa::ExecCommand(TGWin32Command * /*code*/) +{ + // Executes the command "code" coming from the other threads (Win32) + return 0; } //______________________________________________________________________________ -void TGCocoa::SetWMPosition(Window_t /*wid*/, Int_t /*x*/, Int_t /*y*/) +Int_t TGCocoa::GetDoubleBuffer(Int_t /*wid*/) { - // Tells the window manager the desired position [x,y] of window "wid". + // Queries the double buffer value for the window "wid". + return 0; } //______________________________________________________________________________ -void TGCocoa::SetWMSize(Window_t /*wid*/, UInt_t /*w*/, UInt_t /*h*/) +void TGCocoa::GetCharacterUp(Float_t &chupx, Float_t &chupy) { - // Tells window manager the desired size of window "wid". + // Returns character up vector. + chupx = chupy = 0; +} + +//______________________________________________________________________________ +Pixmap_t TGCocoa::ReadGIF(Int_t /*x0*/, Int_t /*y0*/, const char * /*file*/, Window_t /*id*/) +{ + // If id is NULL - loads the specified gif file at position [x0,y0] in the + // current window. Otherwise creates pixmap from gif file + + return kNone; +} + +//______________________________________________________________________________ +Int_t TGCocoa::RequestLocator(Int_t /*mode*/, Int_t /*ctyp*/, Int_t &/*x*/, Int_t &/*y*/) +{ + // Requests Locator position. + // x,y - cursor position at moment of button press (output) + // ctyp - cursor type (input) + // ctyp = 1 tracking cross + // ctyp = 2 cross-hair + // ctyp = 3 rubber circle + // ctyp = 4 rubber band + // ctyp = 5 rubber rectangle // - // w - the width - // h - the height + // mode - input mode + // mode = 0 request + // mode = 1 sample + // + // The returned value is: + // in request mode: + // 1 = left is pressed + // 2 = middle is pressed + // 3 = right is pressed + // in sample mode: + // 11 = left is released + // 12 = middle is released + // 13 = right is released + // -1 = nothing is pressed or released + // -2 = leave the window + // else = keycode (keyboard is pressed) + + return 0; } //______________________________________________________________________________ -void TGCocoa::SetWMSizeHints(Window_t wid, UInt_t wMin, UInt_t hMin, UInt_t wMax, UInt_t hMax, UInt_t /*wInc*/, UInt_t /*hInc*/) +Int_t TGCocoa::RequestString(Int_t /*x*/, Int_t /*y*/, char * /*text*/) { + // Requests string: text is displayed and can be edited with Emacs-like + // keybinding. Returns termination code (0 for ESC, 1 for RETURN) // - assert(!fPimpl->IsRootWindow(wid) && "SetWMSizeHints, called for 'root' window"); + // x,y - position where text is displayed + // text - displayed text (as input), edited text (as output) + return 0; +} - QuartzWindow *qw = fPimpl->GetWindow(wid).fQuartzWindow; - //I can use CGSizeMake, but what if NSSize one bad day becomes something else? :) - NSSize minSize = {}; minSize.width = wMin, minSize.height = hMin; - [qw setMinSize : minSize]; - NSSize maxSize = {}; maxSize.width = wMax, maxSize.height = hMax; - [qw setMaxSize : maxSize]; +//______________________________________________________________________________ +void TGCocoa::SetCharacterUp(Float_t /*chupx*/, Float_t /*chupy*/) +{ + // Sets character up vector. } //______________________________________________________________________________ -void TGCocoa::SetWMState(Window_t /*wid*/, EInitialState /*state*/) +void TGCocoa::SetClipOFF(Int_t /*wid*/) { - // Sets the initial state of the window "wid": either kNormalState - // or kIconicState. + // Turns off the clipping for the window "wid". } //______________________________________________________________________________ -void TGCocoa::SetWMTransientHint(Window_t wid, Window_t mainWid) +void TGCocoa::SetClipRegion(Int_t /*wid*/, Int_t /*x*/, Int_t /*y*/, UInt_t /*w*/, UInt_t /*h*/) { - //Comment from TVirtualX: - // Tells window manager that the window "wid" is a transient window - // of the window "main_id". A window manager may decide not to decorate - // a transient window or may treat it differently in other ways. - //End of TVirtualX's comment. - - //TGTransientFrame uses this hint to attach a window to some "main" window, - //so that transient window is alway above the main window. This is used for - //dialogs and dockable panels. - assert(Int_t(wid) > fPimpl->GetRootWindowID() && "SetWMTransientHint, wid parameter is a root window"); + // Sets clipping region for the window "wid". + // + // wid - window indentifier + // x, y - origin of clipping rectangle + // w, h - the clipping rectangle dimensions - if (fPimpl->IsRootWindow(mainWid)) - return; - - QuartzWindow *mainWindow = fPimpl->GetWindow(mainWid).fQuartzWindow; - QuartzWindow *transientWindow = fPimpl->GetWindow(wid).fQuartzWindow; +} - if (mainWindow != transientWindow) { - [[transientWindow standardWindowButton : NSWindowZoomButton] setEnabled : NO]; - [mainWindow addTransientWindow : transientWindow]; - } else - Warning("SetWMTransientHint", "transient and main windows are the same window"); +//______________________________________________________________________________ +void TGCocoa::SetTextMagnitude(Float_t /*mgn*/) +{ + // Sets the current text magnification factor to "mgn" } //______________________________________________________________________________ -Int_t TGCocoa::KeysymToKeycode(UInt_t keySym) +void TGCocoa::Sync(Int_t /*mode*/) { - // Converts the "keysym" to the appropriate keycode. For example, - // keysym is a letter and keycode is the matching keyboard key (which - // is dependend on the current keyboard mapping). If the specified - // "keysym" is not defined for any keycode, returns zero. + // Set synchronisation on or off. + // mode : synchronisation on/off + // mode=1 on + // mode<>0 off +} - return X11::MapKeySymToKeyCode(keySym); +//______________________________________________________________________________ +void TGCocoa::Warp(Int_t /*ix*/, Int_t /*iy*/, Window_t /*id*/) +{ + // Sets the pointer position. + // ix - new X coordinate of pointer + // iy - new Y coordinate of pointer + // Coordinates are relative to the origin of the window id + // or to the origin of the current window if id == 0. } //______________________________________________________________________________ -Window_t TGCocoa::GetInputFocus() +Int_t TGCocoa::WriteGIF(char * /*name*/) { - // Returns the window id of the window having the input focus. + // Writes the current window into GIF file. + // Returns 1 in case of success, 0 otherwise. + + return 0; +} + +//______________________________________________________________________________ +void TGCocoa::WritePixmap(Int_t /*wid*/, UInt_t /*w*/, UInt_t /*h*/, char * /*pxname*/) +{ + // Writes the pixmap "wid" in the bitmap file "pxname". + // + // wid - the pixmap address + // w, h - the width and height of the pixmap. + // pxname - the file name +} + +//______________________________________________________________________________ +Bool_t TGCocoa::NeedRedraw(ULong_t /*tgwindow*/, Bool_t /*force*/) +{ + // Notify the low level GUI layer ROOT requires "tgwindow" to be + // updated + // + // Returns kTRUE if the notification was desirable and it was sent + // + // At the moment only Qt4 layer needs that + // + // One needs explicitly cast the first parameter to TGWindow to make + // it working in the implementation. + // + // One needs to process the notification to confine + // all paint operations within "expose" / "paint" like low level event + // or equivalent + + return kFALSE; +} + +//______________________________________________________________________________ +Bool_t TGCocoa::CreatePictureFromFile(Drawable_t /*wid*/, + const char * /*filename*/, + Pixmap_t &/*pict*/, + Pixmap_t &/*pict_mask*/, + PictureAttributes_t &/*attr*/) +{ + // Creates a picture pict from data in file "filename". The picture + // attributes "attr" are used for input and output. Returns kTRUE in + // case of success, kFALSE otherwise. If the mask "pict_mask" does not + // exist it is set to kNone. - return fPimpl->fX11EventTranslator.GetInputFocus(); + return kFALSE; } //______________________________________________________________________________ -void TGCocoa::SetInputFocus(Window_t wid) +Bool_t TGCocoa::CreatePictureFromData(Drawable_t /*wid*/, char ** /*data*/, + Pixmap_t &/*pict*/, + Pixmap_t &/*pict_mask*/, + PictureAttributes_t & /*attr*/) { - // Changes the input focus to specified window "wid". - assert(!fPimpl->IsRootWindow(wid) && "SetInputFocus, called for 'root' window"); - - if (wid == kNone) - fPimpl->fX11EventTranslator.SetInputFocus(nil); - else - fPimpl->fX11EventTranslator.SetInputFocus(fPimpl->GetWindow(wid).fContentView); -} + // Creates a picture pict from data in bitmap format. The picture + // attributes "attr" are used for input and output. Returns kTRUE in + // case of success, kFALSE otherwise. If the mask "pict_mask" does not + // exist it is set to kNone. + return kFALSE; +} //______________________________________________________________________________ -Window_t TGCocoa::GetPrimarySelectionOwner() +Bool_t TGCocoa::ReadPictureDataFromFile(const char * /*filename*/, char *** /*ret_data*/) { - // Returns the window id of the current owner of the primary selection. - // That is the window in which, for example some text is selected. + // Reads picture data from file "filename" and store it in "ret_data". + // Returns kTRUE in case of success, kFALSE otherwise. - return kNone; + return kFALSE; } //______________________________________________________________________________ -void TGCocoa::SetPrimarySelectionOwner(Window_t /*wid*/) +void TGCocoa::DeletePictureData(void * /*data*/) { - // Makes the window "wid" the current owner of the primary selection. - // That is the window in which, for example some text is selected. + // Delete picture data created by the function ReadPictureDataFromFile. } //______________________________________________________________________________ -void TGCocoa::ConvertPrimarySelection(Window_t /*wid*/, Atom_t /*clipboard*/, Time_t /*when*/) +void TGCocoa::SetDashes(GContext_t /*gc*/, Int_t /*offset*/, const char * /*dash_list*/, Int_t /*n*/) { - // Causes a SelectionRequest event to be sent to the current primary - // selection owner. This event specifies the selection property - // (primary selection), the format into which to convert that data before - // storing it (target = XA_STRING), the property in which the owner will - // place the information (sel_property), the window that wants the - // information (id), and the time of the conversion request (when). - // The selection owner responds by sending a SelectionNotify event, which - // confirms the selected atom and type. + // Sets the dash-offset and dash-list attributes for dashed line styles + // in the specified GC. There must be at least one element in the + // specified dash_list. The initial and alternating elements (second, + // fourth, and so on) of the dash_list are the even dashes, and the + // others are the odd dashes. Each element in the "dash_list" array + // specifies the length (in pixels) of a segment of the pattern. + // + // gc - specifies the GC (see GCValues_t structure) + // offset - the phase of the pattern for the dashed line-style you + // want to set for the specified GC. + // dash_list - the dash-list for the dashed line-style you want to set + // for the specified GC + // n - the number of elements in dash_list + // (see also the GCValues_t structure) } //______________________________________________________________________________ -void TGCocoa::LookupString(Event_t *event, char *buf, Int_t length, UInt_t &keysym) +void TGCocoa::Bell(Int_t /*percent*/) { - // Converts the keycode from the event structure to a key symbol (according - // to the modifiers specified in the event structure and the current - // keyboard mapping). In "buf" a null terminated ASCII string is returned - // representing the string that is currently mapped to the key code. - // - // event - specifies the event structure to be used - // buf - returns the translated characters - // buflen - the length of the buffer - // keysym - returns the "keysym" computed from the event - // if this argument is not NULL - assert(buf != 0 && "LookupString, buf parameter is null"); - assert(length >= 2 && "LookupString, length parameter - not enough memory to return null-terminated ASCII string"); - - X11::MapUnicharToKeySym(event->fCode, buf, length, keysym); + // Sets the sound bell. Percent is loudness from -100% .. 100%. } //______________________________________________________________________________ -void TGCocoa::QueryPointer(Window_t /*wid*/, Window_t &/*rootw*/, Window_t &/*childw*/, - Int_t &/*root_x*/, Int_t &/*root_y*/, Int_t &/*win_x*/, - Int_t &/*win_y*/, UInt_t &/*mask*/) +void TGCocoa::WMDeleteNotify(Window_t /*wid*/) { - // Returns the root window the pointer is logically on and the pointer - // coordinates relative to the root window's origin. - // - // id - specifies the window - // rotw - the root window that the pointer is in - // childw - the child window that the pointer is located in, if any - // root_x, root_y - the pointer coordinates relative to the root window's - // origin - // win_x, win_y - the pointer coordinates relative to the specified - // window "id" - // mask - the current state of the modifier keys and pointer - // buttons + // Tells WM to send message when window is closed via WM. } //______________________________________________________________________________ @@ -3277,209 +4207,6 @@ bool ParentRendersToChild(NSView *child) // Returns smallest enclosing rectangle. } -//______________________________________________________________________________ -Drawable_t TGCocoa::CreateImage(UInt_t width, UInt_t height) -{ - // Allocates the memory needed for an drawable. - // - // width - the width of the image, in pixels - // height - the height of the image, in pixels - return OpenPixmap(width, height); -} - -//______________________________________________________________________________ -void TGCocoa::GetImageSize(Drawable_t wid, UInt_t &width, UInt_t &height) -{ - // Returns the width and height of the image wid - assert(int(wid) > fPimpl->GetRootWindowID() && "GetImageSize, wid parameter is a bad image id"); - - NSObject *drawable = fPimpl->GetDrawable(wid); - width = drawable.fWidth; - height = drawable.fHeight; -} - -//______________________________________________________________________________ -void TGCocoa::PutPixel(Drawable_t /*wid*/, Int_t /*x*/, Int_t /*y*/, ULong_t /*pixel*/) -{ - // Overwrites the pixel in the image with the specified pixel value. - // The image must contain the x and y coordinates. - // - // wid - specifies the image - // x, y - coordinates - // pixel - the new pixel value -} - -//______________________________________________________________________________ -void TGCocoa::PutImage(Drawable_t /*wid*/, GContext_t /*gc*/, - Drawable_t /*img*/, Int_t /*dx*/, Int_t /*dy*/, - Int_t /*x*/, Int_t /*y*/, UInt_t /*w*/, UInt_t /*h*/) -{ - // Combines an image with a rectangle of the specified drawable. The - // section of the image defined by the x, y, width, and height arguments - // is drawn on the specified part of the drawable. - // - // wid - the drawable - // gc - the GC - // img - the image you want combined with the rectangle - // dx - the offset in X from the left edge of the image - // dy - the offset in Y from the top edge of the image - // x, y - coordinates, which are relative to the origin of the - // drawable and are the coordinates of the subimage - // w, h - the width and height of the subimage, which define the - // rectangle dimensions - // - // GC components in use: function, plane-mask, subwindow-mode, - // clip-x-origin, clip-y-origin, and clip-mask. - // GC mode-dependent components: foreground and background. - // (see also the GCValues_t structure) -} - -//______________________________________________________________________________ -void TGCocoa::DeleteImage(Drawable_t /*img*/) -{ - // Deallocates the memory associated with the image img -} - -//______________________________________________________________________________ -void TGCocoa::ShapeCombineMask(Window_t, Int_t, Int_t, Pixmap_t) -{ - // The Nonrectangular Window Shape Extension adds nonrectangular - // windows to the System. - // This allows for making shaped (partially transparent) windows -} - -//______________________________________________________________________________ -UInt_t TGCocoa::ScreenWidthMM() const -{ - //Comment from TVirtualX: Returns the width of the screen in millimeters. -/* - NSArray *screens = [NSScreen screens]; - assert(screens != nil && "screens array is nil"); - - NSScreen *mainScreen = [screens objectAtIndex : 0]; - assert(mainScreen != nil && "screen with index 0 is nil"); - - NSDictionary *screenParameters = [mainScreen deviceDescription]; - assert(screenParameters != nil && "deviceDescription dictionary is nil"); - - //This casts are just terrible and rely on the current documentation only. - //But this is ... elegant Objective-C. - NSNumber *screenNumber = (NSNumber *)[screenParameters objectForKey : @"NSScreenNumber"]; - assert(screenNumber != nil && "no screen number in device description"); - const CGSize screenSize = CGDisplayScreenSize([screenNumber integerValue]); - */ - - return CGDisplayScreenSize(CGMainDisplayID()).width; -} - -//______________________________________________________________________________ -void TGCocoa::DeleteProperty(Window_t, Atom_t&) -{ - // Deletes the specified property only if the property was defined on the - // specified window and causes the X server to generate a PropertyNotify - // event on the window unless the property does not exist. - -} - -//______________________________________________________________________________ -Int_t TGCocoa::GetProperty(Window_t, Atom_t, Long_t, Long_t, Bool_t, Atom_t, - Atom_t*, Int_t*, ULong_t*, ULong_t*, unsigned char**) -{ - // Returns the actual type of the property; the actual format of the property; - // the number of 8-bit, 16-bit, or 32-bit items transferred; the number of - // bytes remaining to be read in the property; and a pointer to the data - // actually returned. - - return 0; -} - -//______________________________________________________________________________ -void TGCocoa::ChangeActivePointerGrab(Window_t, UInt_t, Cursor_t) -{ - // Changes the specified dynamic parameters if the pointer is actively - // grabbed by the client and if the specified time is no earlier than the - // last-pointer-grab time and no later than the current X server time. - -} - -//______________________________________________________________________________ -void TGCocoa::ConvertSelection(Window_t, Atom_t&, Atom_t&, Atom_t&, Time_t&) -{ - // Requests that the specified selection be converted to the specified - // target type. - -} - -//______________________________________________________________________________ -Bool_t TGCocoa::SetSelectionOwner(Window_t, Atom_t&) -{ - // Changes the owner and last-change time for the specified selection. - - return kFALSE; -} - -//______________________________________________________________________________ -void TGCocoa::ChangeProperties(Window_t, Atom_t, Atom_t, Int_t, UChar_t *, Int_t) -{ - // Alters the property for the specified window and causes the X server - // to generate a PropertyNotify event on that window. -} - -//______________________________________________________________________________ -void TGCocoa::SetDNDAware(Window_t, Atom_t *) -{ - // Add XdndAware property and the list of drag and drop types to the - // Window win. - -} - -//______________________________________________________________________________ -void TGCocoa::SetTypeList(Window_t, Atom_t, Atom_t *) -{ - // Add the list of drag and drop types to the Window win. - -} - -//______________________________________________________________________________ -Window_t TGCocoa::FindRWindow(Window_t, Window_t, Window_t, int, int, int) -{ - // Recursively search in the children of Window for a Window which is at - // location x, y and is DND aware, with a maximum depth of maxd. - - return kNone; -} - -//______________________________________________________________________________ -Bool_t TGCocoa::IsDNDAware(Window_t, Atom_t *) -{ - // Checks if the Window is DND aware, and knows any of the DND formats - // passed in argument. - - return kFALSE; -} - -//______________________________________________________________________________ -void TGCocoa::BeginModalSessionFor(Window_t wid) -{ - assert(!fPimpl->IsRootWindow(wid) && "BeginModalSessionFor, called for 'root' window"); - - //We start special modal session _ONLY_ for dialogs. - //Everything else is done in a different way. - if (IsDialog(wid)) { - //QuartzWindow *qw = fPimpl->GetWindow(wid).fQuartzWindow; - } -} - -//______________________________________________________________________________ -Int_t TGCocoa::SupportsExtension(const char *) const -{ - // Returns 1 if window system server supports extension given by the - // argument, returns 0 in case extension is not supported and returns -1 - // in case of error (like server not initialized). - - return -1; -} - //______________________________________________________________________________ ROOT::MacOSX::X11::EventTranslator *TGCocoa::GetEventTranslator()const { @@ -3514,7 +4241,7 @@ bool ParentRendersToChild(NSView *child) //______________________________________________________________________________ void *TGCocoa::GetCurrentContext() { - NSObject *drawable = fPimpl->GetDrawable(fSelectedDrawable); + NSObject * const drawable = fPimpl->GetDrawable(fSelectedDrawable); if (!drawable.fIsPixmap) { Error("GetCurrentContext", "TCanvas/TPad's internal error, selected drawable is not a pixmap!"); return 0; @@ -3523,24 +4250,6 @@ bool ParentRendersToChild(NSView *child) return drawable.fContext; } -//______________________________________________________________________________ -bool TGCocoa::IsDialog(Window_t wid)const -{ - if (Int_t(wid) <= fPimpl->GetRootWindowID()) - return false; - - TGWindow *window = gClient->GetWindowById(wid); - if (!window) - return false; - - const NSUInteger styleMask = [fPimpl->GetWindow(wid).fQuartzWindow styleMask]; - - if (window->InheritsFrom("TGTransientFrame") && styleMask != NSBorderlessWindowMask) - return true; - - return false; -} - //______________________________________________________________________________ bool TGCocoa::MakeProcessForeground() { @@ -3549,29 +4258,41 @@ bool ParentRendersToChild(NSView *child) //if it tries to create and manage windows. //So, first time we convert process to foreground, next time //we make it front. - + if (!fForegroundProcess) { ProcessSerialNumber psn = {0, kCurrentProcess}; const OSStatus res1 = TransformProcessType(&psn, kProcessTransformToForegroundApplication); - if (res1 != noErr) { + + //When TGCocoa's functions are called from the python (Apple's system version), + //TransformProcessType fails with paramErr (looks like process is _already_ foreground), + //why is it a paramErr - I've no idea. + if (res1 != noErr && res1 != paramErr) { Error("MakeProcessForeground", "TransformProcessType failed with code %d", res1); return false; } - +#ifdef MAC_OS_X_VERSION_10_9 + //Instead of quite transparent Carbon calls we now have another black-box function. + [[NSApplication sharedApplication] activateIgnoringOtherApps : YES]; +#else const OSErr res2 = SetFrontProcess(&psn); if (res2 != noErr) { Error("MakeProcessForeground", "SetFrontProcess failed with code %d", res2); return false; } +#endif fForegroundProcess = true; } else { +#ifdef MAC_OS_X_VERSION_10_9 + //Instead of quite transparent Carbon calls we now have another black-box function. + [[NSApplication sharedApplication] activateIgnoringOtherApps : YES]; +#else ProcessSerialNumber psn = {}; OSErr res = GetCurrentProcess(&psn); if (res != noErr) { - Error("MapProcessForeground", "GetCurrentProcess failed with code %d", res); + Error("MakeProcessForeground", "GetCurrentProcess failed with code %d", res); return false; } @@ -3580,7 +4301,43 @@ bool ParentRendersToChild(NSView *child) Error("MapProcessForeground", "SetFrontProcess failed with code %d", res); return false; } +#endif } return true; } + +//______________________________________________________________________________ +Atom_t TGCocoa::FindAtom(const std::string &atomName, bool addIfNotFound) +{ + const std::map::const_iterator it = fNameToAtom.find(atomName); + + if (it != fNameToAtom.end()) + return it->second; + else if (addIfNotFound) { + //Create a new atom. + fAtomToName.push_back(atomName); + fNameToAtom[atomName] = Atom_t(fAtomToName.size()); + + return Atom_t(fAtomToName.size()); + } + + return kNone; +} + +//______________________________________________________________________________ +void TGCocoa::SetApplicationIcon() +{ + if (gEnv) { + const char * const iconDirectoryPath = gEnv->GetValue("Gui.IconPath","$(ROOTSYS)/icons");//This one I do not own. + if (iconDirectoryPath) { + const Util::ScopedArray fileName(gSystem->Which(iconDirectoryPath, "RootIcon.ico", kReadPermission)); + if (fileName.Get()) { + const Util::AutoreleasePool pool; + NSString *cocoaStr = [NSString stringWithCString : fileName.Get() encoding : NSASCIIStringEncoding];//Aha, ASCII ;) do not install root in ... + NSImage *image = [[[NSImage alloc] initWithContentsOfFile : cocoaStr] autorelease]; + [NSApp setApplicationIconImage : image]; + } + } + } +} diff --git a/graf2d/cocoa/src/TGQuartz.mm b/graf2d/cocoa/src/TGQuartz.mm index f0a2f0f52e545..01dddbd40cea4 100644 --- a/graf2d/cocoa/src/TGQuartz.mm +++ b/graf2d/cocoa/src/TGQuartz.mm @@ -13,20 +13,28 @@ //#define NDEBUG #include +#include #include #include +#include #include +# include +# include FT_FREETYPE_H +# include FT_GLYPH_H + #include "QuartzFillArea.h" #include "TColorGradient.h" #include "QuartzMarker.h" #include "CocoaPrivate.h" #include "QuartzWindow.h" +#include "QuartzPixmap.h" +#include "QuartzUtils.h" #include "X11Drawable.h" #include "QuartzText.h" #include "QuartzLine.h" - +#include "CocoaUtils.h" #include "TGQuartz.h" #include "TPoint.h" #include "TColor.h" @@ -35,16 +43,56 @@ ClassImp(TGQuartz) -using namespace ROOT; +//TODO: +//Originally, Olivier Couet suggested to have a separate module quartz with quartz-related graphics, +//to be used by both iOS and MacOSX code. Also, the separation of non-GUI and gui parts was suggested +//that's why we have TGQuartz and TGCocoa classes (TGCocoa is never used as it is, TGQuartz is +//created and initialzed by TROOT. +//Today it's clear that there is not need in any special quartz classes anymore - +//in my iOS applications/module I do not need anything from quartz module, also, the +//amount of code in quartz module is so small, that it can be merged back into cocoa module. + +//At some point, I'll merge cocoa and quartz modules and cleanup all this +//mess and weird code we have in a quartz module. -//TODO: re-arrange all these SetContextXXX in a more logical and consistent -//way and to check, what we actually have to set -//and when. + +namespace X11 = ROOT::MacOSX::X11; +namespace Quartz = ROOT::Quartz; +namespace Util = ROOT::MacOSX::Util; + +namespace { + +//______________________________________________________________________________ +void ConvertPointsROOTToCocoa(Int_t nPoints, const TPoint *xy, std::vector &dst, NSObject *drawable) +{ + assert(nPoints != 0 && "ConvertPointsROOTToCocoa, nPoints parameter is 0"); + assert(xy != 0 && "ConvertPointsROOTToCocoa, xy parameter is null"); + assert(drawable != 0 && "ConvertPointsROOTToCocoa, drawable parameter is null"); + + dst.resize(nPoints); + for (Int_t i = 0; i < nPoints; ++i) { + dst[i].fX = xy[i].fX; + dst[i].fY = SCoord_t(X11::LocalYROOTToCocoa(drawable, xy[i].fY)); + } +} + +} //______________________________________________________________________________ TGQuartz::TGQuartz() { - // TGQuartz default constructor + //Default ctor. + + + if (!TTF::IsInitialized()) + TTF::Init(); + + //I do not know why TTF::Init returns void and I have to check IsInitialized() again. + if (!TTF::IsInitialized()) + Error("TGQuartz", "TTF::Init() failed"); + + fAlign.x = 0; + fAlign.y = 0; } @@ -52,100 +100,120 @@ TGQuartz::TGQuartz(const char *name, const char *title) : TGCocoa(name, title) { - // TGQuartz normal constructor + //Constructor. + if (!TTF::IsInitialized()) + TTF::Init(); + + //I do not know why TTF::Init returns void and I have to check IsInitialized() again. + if (!TTF::IsInitialized()) + Error("TGQuartz", "TTF::Init() failed"); + + fAlign.x = 0; + fAlign.y = 0; } //______________________________________________________________________________ void TGQuartz::DrawBox(Int_t x1, Int_t y1, Int_t x2, Int_t y2, EBoxMode mode) { - // Draw a box - - if (fDirectDraw)//To avoid warnings from Quartz - no context at the moment! + //Check some conditions first. + if (fDirectDraw) { + if (!fPimpl->GetDrawable(fSelectedDrawable).fIsPixmap) + fPimpl->fX11CommandBuffer.AddDrawBoxXor(fSelectedDrawable, x1, y1, x2, y2); return; + } - CGContextRef ctx = (CGContextRef)GetCurrentContext(); - if (!ctx) { - Error("DrawBox", "Current context is null"); + NSObject * const drawable = (NSObject *)GetSelectedDrawableChecked("DrawBox"); + if (!drawable) return; - } + CGContextRef ctx = drawable.fContext; const Quartz::CGStateGuard ctxGuard(ctx); - const TColor *fillColor = gROOT->GetColor(GetFillColor()); + const TColor * const fillColor = gROOT->GetColor(GetFillColor()); if (!fillColor) { Error("DrawBox", "Fill color for index %d not found", GetFillColor()); return; } - if (const TColorGradient *extendedColor = dynamic_cast(fillColor)) { + //Go to low-left-corner system. + y1 = Int_t(X11::LocalYROOTToCocoa(drawable, y1)); + y2 = Int_t(X11::LocalYROOTToCocoa(drawable, y2)); + + if (const TColorGradient * const extendedColor = dynamic_cast(fillColor)) { //Draw a box with a gradient fill and a shadow. - Quartz::DrawBoxGradient(ctx, x1, y1, x2, y2, extendedColor, kTRUE);//kTRUE == draw shadow. + //Ignore all fill styles and EBoxMode, use a gradient fill. + Quartz::DrawBoxGradient(ctx, x1, y1, x2, y2, extendedColor, kTRUE);//kTRUE == draw a shadow. } else { - SetContextFillColor(GetFillColor());//For coverity: Do not check the result, TColor exists. - if (!SetContextStrokeColor(GetLineColor())) { - Error("DrawBox", "Line color for index %d not found", GetLineColor()); - return; + const bool isHollow = mode == kHollow || GetFillStyle() / 1000 == 2; + unsigned patternIndex = 0; + if (isHollow) { + if (!Quartz::SetLineColor(ctx, GetLineColor())) { + Error("DrawBox", "Can not find color for index %d", int(GetLineColor())); + return; + } + } else { + if (!Quartz::SetFillAreaParameters(ctx, &patternIndex)) { + Error("DrawBox", "SetFillAreaParameters failed"); + return; + } } - - Float_t r = 0.f; - Float_t g = 0.f; - Float_t b = 0.f; - const Float_t a = fillColor->GetAlpha(); - fillColor->GetRGB(r, g, b); - Quartz::SetFillStyle(ctx, GetFillStyle(), r, g, b, a); - Quartz::DrawBox(ctx, x1, y1, x2, y2, (Int_t)mode); + + Quartz::DrawBox(ctx, x1, y1, x2, y2, isHollow); } } //______________________________________________________________________________ -void TGQuartz::DrawFillArea(Int_t n, TPoint * xy) +void TGQuartz::DrawFillArea(Int_t n, TPoint *xy) { + //Comment from TVirtualX: + // Draw a filled area through all points. // n : number of points - // xy : list of points + // xy : array of points + + //End of comment. + //Do some checks first. if (fDirectDraw)//To avoid warnings from Quartz - no context at the moment! return; - CGContextRef ctx = (CGContextRef)GetCurrentContext(); - if (!ctx) { - Error("DrawFillArea", "Current context is null"); + NSObject * const drawable = (NSObject *)GetSelectedDrawableChecked("DrawFillArea"); + if (!drawable) return; - } + + CGContextRef ctx = drawable.fContext; + + //Convert points to bottom-left system: + ConvertPointsROOTToCocoa(n, xy, fConvertedPoints, drawable); const Quartz::CGStateGuard ctxGuard(ctx); - const TColor *fillColor = gROOT->GetColor(GetFillColor()); + const TColor * const fillColor = gROOT->GetColor(GetFillColor()); if (!fillColor) { Error("DrawFillArea", "Could not find TColor for index %d", GetFillColor()); return; } - if (const TColorGradient *extendedColor = dynamic_cast(fillColor)) { - Quartz::DrawFillAreaGradient(ctx, n, xy, extendedColor, kTRUE);//kTRUE == draw shadow. + if (const TColorGradient * const extendedColor = dynamic_cast(fillColor)) { + Quartz::DrawFillAreaGradient(ctx, n, &fConvertedPoints[0], extendedColor, kTRUE);//kTRUE == draw a shadow. } else { - SetContextStrokeColor(GetFillColor()); - SetContextFillColor(GetFillColor()); - - Float_t rgb[3] = {}; - fillColor->GetRGB(rgb[0], rgb[1], rgb[2]); - const Float_t alpha = fillColor->GetAlpha(); + unsigned patternIndex = 0; + if (!Quartz::SetFillAreaParameters(ctx, &patternIndex)) { + Error("DrawFillArea", "SetFillAreaParameters failed"); + return; + } - Quartz::SetFillStyle(ctx, GetFillStyle(), rgb[0], rgb[1], rgb[2], alpha); - Quartz::DrawFillArea(ctx, n, xy, kFALSE);//The last argument - do not draw shadows. + Quartz::DrawFillArea(ctx, n, &fConvertedPoints[0], kFALSE);//The last argument - do not draw shadows. } } //______________________________________________________________________________ -void TGQuartz::DrawCellArray(Int_t /*x1*/, Int_t /*y1*/, Int_t /*x2*/, Int_t /*y2*/, - Int_t /*nx*/, Int_t /*ny*/, Int_t */*ic*/) +void TGQuartz::DrawCellArray(Int_t /*x1*/, Int_t /*y1*/, Int_t /*x2*/, Int_t /*y2*/, Int_t /*nx*/, Int_t /*ny*/, Int_t */*ic*/) { - // Draw CellArray - - //CGContextRef ctx = (CGContextRef)GetCurrentContext(); + //Noop. } @@ -156,85 +224,100 @@ // x1,y1 : begin of line // x2,y2 : end of line - if (fDirectDraw)//To avoid warnings from Quartz - no context at the moment! - return; - - CGContextRef ctx = (CGContextRef)GetCurrentContext(); - if (!ctx) { - Error("DrawLine", "Current context is null"); + if (fDirectDraw) { + if (!fPimpl->GetDrawable(fSelectedDrawable).fIsPixmap) + fPimpl->fX11CommandBuffer.AddDrawLineXor(fSelectedDrawable, x1, y1, x2, y2); return; } - - const Quartz::CGStateGuard ctxGuard(ctx); - if (!SetContextStrokeColor(GetLineColor())) { - Error("DrawLine", "Could not find TColor for index %d", GetLineColor()); + //Do some checks first: + assert(fSelectedDrawable > fPimpl->GetRootWindowID() && "DrawLine, bad drawable is selected"); + NSObject * const drawable = (NSObject *)GetSelectedDrawableChecked("DrawLine"); + if (!drawable) return; - } + CGContextRef ctx = drawable.fContext; + const Quartz::CGStateGuard ctxGuard(ctx); + + if (!Quartz::SetLineColor(ctx, GetLineColor())) { + Error("DrawLine", "Could not set line color for index %d", int(GetLineColor())); + return; + } + Quartz::SetLineStyle(ctx, GetLineStyle()); Quartz::SetLineWidth(ctx, GetLineWidth()); - Quartz::DrawLine(ctx, x1, y1, x2, y2); + + Quartz::DrawLine(ctx, x1, X11::LocalYROOTToCocoa(drawable, y1), x2, X11::LocalYROOTToCocoa(drawable, y2)); } //______________________________________________________________________________ void TGQuartz::DrawPolyLine(Int_t n, TPoint *xy) { + //Comment from TVirtualX: // Draw a line through all points. // n : number of points - // xy : list of points + // xy : list of points + //End of comment. + //Some checks first. if (fDirectDraw)//To avoid warnings from Quartz - no context at the moment! return; - CGContextRef ctx = (CGContextRef)GetCurrentContext(); - if (!ctx) { - Error("DrawPolyLine", "Current context is null"); + NSObject * const drawable = (NSObject *)GetSelectedDrawableChecked("DrawPolyLine"); + if (!drawable) return; - } + CGContextRef ctx = drawable.fContext; const Quartz::CGStateGuard ctxGuard(ctx); - if (!SetContextStrokeColor(GetLineColor())) { + if (!Quartz::SetLineColor(ctx, GetLineColor())) { Error("DrawPolyLine", "Could not find TColor for index %d", GetLineColor()); return; } Quartz::SetLineStyle(ctx, GetLineStyle()); Quartz::SetLineWidth(ctx, GetLineWidth()); - Quartz::DrawPolyLine(ctx, n, xy); + + //Convert to bottom-left-corner system. + ConvertPointsROOTToCocoa(n, xy, fConvertedPoints, drawable); + + Quartz::DrawPolyLine(ctx, n, &fConvertedPoints[0]); } //______________________________________________________________________________ void TGQuartz::DrawPolyMarker(Int_t n, TPoint *xy) { + //Comment from TVirtualX: // Draw PolyMarker // n : number of points // xy : list of points + //End of comment. + //Do some checks first. if (fDirectDraw)//To avoid warnings from Quartz - no context at the moment! return; - CGContextRef ctx = (CGContextRef)GetCurrentContext(); - if (!ctx) { - Error("DrawPolyMarker", "Current context is null"); + NSObject * const drawable = (NSObject *)GetSelectedDrawableChecked("DrawPolyMarker"); + if (!drawable) return; - } - + + CGContextRef ctx = drawable.fContext; const Quartz::CGStateGuard ctxGuard(ctx); - if (!SetContextFillColor(GetMarkerColor())) { + if (!Quartz::SetFillColor(ctx, GetMarkerColor())) { Error("DrawPolyMarker", "Could not find TColor for index %d", GetMarkerColor()); return; } - SetContextStrokeColor(GetMarkerColor());//Can not fail (for coverity). - + Quartz::SetLineColor(ctx, GetMarkerColor());//Can not fail (for coverity). Quartz::SetLineStyle(ctx, 1); Quartz::SetLineWidth(ctx, 1); - Quartz::DrawPolyMarker(ctx, n, xy, GetMarkerSize(), GetMarkerStyle()); + + ConvertPointsROOTToCocoa(n, xy, fConvertedPoints, drawable); + + Quartz::DrawPolyMarker(ctx, n, &fConvertedPoints[0], GetMarkerSize(), GetMarkerStyle()); } @@ -246,38 +329,24 @@ if (!text || !text[0])//Can this ever happen? TPad::PaintText does not check this. return; - - if (fSelectedDrawable <= 0) { - Error("DrawText", "internal error, no pixmap was selected"); - return; - } - - if (!fPimpl.get()) { - Error("DrawText", "internal error, internal data was not initialized correctly"); - return; - } - - assert(fSelectedDrawable > fPimpl->GetRootWindowID() && "DrawText, no pixmap selected"); - NSObject *pixmap = fPimpl->GetDrawable(fSelectedDrawable); - assert(pixmap.fIsPixmap == YES && "DrawText, selected drawable is not a pixmap"); - - CGContextRef ctx = (CGContextRef)GetCurrentContext(); - if (!ctx) { - Error("DrawText", "Current context is null"); + if (!GetTextSize())//Do not draw anything, or CoreText will create some small (but not of size 0 font). return; - } + NSObject * const drawable = (NSObject *)GetSelectedDrawableChecked("DrawText"); + if (!drawable) + return; + + CGContextRef ctx = drawable.fContext; const Quartz::CGStateGuard ctxGuard(ctx); //Before any core text drawing operations, reset text matrix. CGContextSetTextMatrix(ctx, CGAffineTransformIdentity); - CGContextTranslateCTM(ctx, 0., pixmap.fHeight); - CGContextScaleCTM(ctx, 1., -1.); try { if (CTFontRef currentFont = fPimpl->fFontManager.SelectFont(GetTextFont(), GetTextSize())) { - if (GetTextFont() / 10 == 12) {//Greek and math symbols. + const unsigned fontIndex = GetTextFont() / 10; + if (fontIndex == 12 || fontIndex == 15) {//Greek and math symbols. //This is a hack. Correct way is to extract glyphs from symbol.ttf, //find correct mapping, place this glyphs. This requires manual layout though (?), //and as usually, I have to many things to do, may be, one day I'll fix text rendering also. @@ -290,10 +359,10 @@ unichars[i] = 0xF000 + (unsigned char)text[i]; Quartz::TextLine ctLine(unichars, currentFont, GetTextColor()); - ctLine.DrawLine(ctx, x, ROOT::MacOSX::X11::LocalYROOTToCocoa(pixmap, y)); + ctLine.DrawLine(ctx, x, X11::LocalYROOTToCocoa(drawable, y)); } else { const Quartz::TextLine ctLine(text, currentFont, GetTextColor()); - ctLine.DrawLine(ctx, x, ROOT::MacOSX::X11::LocalYROOTToCocoa(pixmap, y)); + ctLine.DrawLine(ctx, x, X11::LocalYROOTToCocoa(drawable, y)); } } } catch (const std::exception &e) { @@ -301,6 +370,34 @@ } } +//______________________________________________________________________________ +void TGQuartz::DrawText(Int_t x, Int_t y, Float_t angle, Float_t /*mgn*/, const wchar_t *text, ETextMode mode) +{ + if (!text || !text[0]) + return; + + if (!TTF::IsInitialized()) { + Error("DrawText", "wchar_t string to draw, but TTF initialization failed"); + return; + } + + if (!GetTextSize())//Do not draw anything, or CoreText will create some small (but not of size 0 font). + return; + + (void)x; + (void)y; + (void)angle; + (void)mode; + + TTF::SetSmoothing(kTRUE); + TTF::SetRotationMatrix(angle); + TTF::PrepareString(text); + TTF::LayoutGlyphs(); + + AlignTTFString(); + RenderTTFString(x, y, mode); +} + //______________________________________________________________________________ void TGQuartz::GetTextExtent(UInt_t &w, UInt_t &h, char *text) { @@ -320,7 +417,6 @@ fPimpl->fFontManager.GetTextBounds(w, h, text); } - //______________________________________________________________________________ Int_t TGQuartz::GetFontAscent() const { @@ -333,7 +429,6 @@ return 0; } - //______________________________________________________________________________ Int_t TGQuartz::GetFontDescent() const { @@ -434,7 +529,6 @@ TAttText::SetTextAlign(talign); } - //______________________________________________________________________________ void TGQuartz::SetTextColor(Color_t cindex) { @@ -445,13 +539,31 @@ //______________________________________________________________________________ -void TGQuartz::SetTextFont(Font_t fontnumber) +void TGQuartz::SetTextFont(Font_t fontNumber) { // Set the current text font number. - TAttText::SetTextFont(fontnumber); + TAttText::SetTextFont(fontNumber); + + if (!TTF::IsInitialized()) { + Error("SetTextFont", "TTF is not initialized"); + return; + } + + TTF::SetTextFont(fontNumber); } +//______________________________________________________________________________ +Int_t TGQuartz::SetTextFont(char *fontName, ETextSetMode /*mode*/) +{ + //This function is never used in gPad (in normal text rendering, so I'm not setting anything for CoreText). + if (!TTF::IsInitialized()) { + Error("SetTextFont", "TTF is not initialized"); + return 0; + } + + return TTF::SetTextFont(fontName); +} //______________________________________________________________________________ void TGQuartz::SetTextSize(Float_t textsize) @@ -459,6 +571,13 @@ // Set the current text size to "textsize" TAttText::SetTextSize(textsize); + + if (!TTF::IsInitialized()) { + Error("SetTextSize", "TTF is not initialized"); + return; + } + + TTF::SetTextSize(textsize); } @@ -472,55 +591,330 @@ // colors). } +//TTF related part. //______________________________________________________________________________ -Int_t TGQuartz::SetTextFont(char * /*fontname*/, ETextSetMode /*mode*/) +void TGQuartz::AlignTTFString() { - // Set text font to specified name "fontname".This function returns 0 if - // the specified font is found, 1 if it is not. - // - // mode - loading flag - // mode = 0 search if the font exist (kCheck) - // mode = 1 search the font and load it if it exists (kLoad) + //Comment from TGX11TTF: + // Compute alignment variables. The alignment is done on the horizontal string + // then the rotation is applied on the alignment variables. + // SetRotation and LayoutGlyphs should have been called before. + //End of comment. - return 0; + //This code is from TGX11TTF (with my fixes). + //It looks like align can not be both X and Y aling? + + const EAlign align = EAlign(fTextAlign); + + // vertical alignment + if (align == kTLeft || align == kTCenter || align == kTRight) { + fAlign.y = TTF::GetAscent(); + } else if (align == kMLeft || align == kMCenter || align == kMRight) { + fAlign.y = TTF::GetAscent() / 2; + } else { + fAlign.y = 0; + } + + // horizontal alignment + if (align == kTRight || align == kMRight || align == kBRight) { + fAlign.x = TTF::GetWidth(); + } else if (align == kTCenter || align == kMCenter || align == kBCenter) { + fAlign.x = TTF::GetWidth() / 2; + } else { + fAlign.x = 0; + } + + FT_Vector_Transform(&fAlign, TTF::GetRotMatrix()); + //This shift is from the original code. + fAlign.x = fAlign.x >> 6; + fAlign.y = fAlign.y >> 6; } //______________________________________________________________________________ -Bool_t TGQuartz::SetContextFillColor(Int_t ci) +Bool_t TGQuartz::IsTTFStringVisible(Int_t x, Int_t y, UInt_t w, UInt_t h) { - // Set the current fill color in the current context. - - CGContextRef ctx = (CGContextRef)GetCurrentContext(); + //Comment from TGX11TTF: + // Test if there is really something to render. + //End of comment. + + //This code is from TGX11TTF (with modifications). - const TColor *color = gROOT->GetColor(ci); - if (!color) + //Comment from TGX11TTF: + // If w or h is 0, very likely the string is only blank characters + if (!w || !h) return kFALSE; - const CGFloat a = color->GetAlpha(); - Float_t rgb[3] = {}; - color->GetRGB(rgb[0], rgb[1], rgb[2]); - CGContextSetRGBFillColor (ctx, rgb[0], rgb[1], rgb[2], a); + UInt_t width = 0; + UInt_t height = 0; + Int_t xy = 0; + GetWindowSize(GetCurrentWindow(), xy, xy, width, height); + + // If string falls outside window, there is probably no need to draw it. + if (x + int(w) <= 0 || x >= int(width)) + return kFALSE; + + if (y + int(h) <= 0 || y >= int(height)) + return kFALSE; + return kTRUE; } +//______________________________________________________________________________ +void TGQuartz::RenderTTFString(Int_t x, Int_t y, ETextMode mode) +{ + //Comment from TGX11TTF: + // Perform the string rendering in the pad. + // LayoutGlyphs should have been called before. + //End of comment. + + //This code is a modified (for Quartz) version of TG11TTF::RenderString. + + NSObject * const drawable = (NSObject *)GetSelectedDrawableChecked("DrawText"); + if (!drawable) + return; + + QuartzPixmap *dstPixmap = nil; + if ([drawable isKindOfClass : [QuartzPixmap class]]) + dstPixmap = (QuartzPixmap *)drawable; + else if ([drawable isKindOfClass : [QuartzView class]] || [drawable isKindOfClass : [QuartzWindow class]]) + dstPixmap = ((NSObject *)drawable).fBackBuffer; + + if (!dstPixmap) { + //I can not read pixels from a window (I can, but this is too slow and unreliable). + Error("DrawText", "fSelectedDrawable is neither QuartzPixmap nor a double buffered window"); + return; + } + + //Comment from TGX11TTF: + // compute the size and position of the XImage that will contain the text + const Int_t xOff = TTF::GetBox().xMin < 0 ? -TTF::GetBox().xMin : 0; + const Int_t yOff = TTF::GetBox().yMin < 0 ? -TTF::GetBox().yMin : 0; + + const Int_t w = TTF::GetBox().xMax + xOff; + const Int_t h = TTF::GetBox().yMax + yOff; + + const Int_t x1 = x - xOff - fAlign.x; + const Int_t y1 = y + yOff + fAlign.y - h; + + if (!IsTTFStringVisible(x1, y1, w, h)) + return; + + //By default, all pixels are set to 0 (all components, that's what code in TGX11TTF also does here). + Util::NSScopeGuard pixmap([[QuartzPixmap alloc] initWithW : w H : h scaleFactor : 1.f]); + if (!pixmap.Get()) { + Error("DrawText", "pixmap creation failed"); + return; + } + + const unsigned char defaultBackgroundPixel[] = {255, 255, 255, 255}; + Util::ScopedArray arrayGuard; + if (mode == kClear) { + //For this mode, TGX11TTF does some work to: a) preserve pixels under symbols + //b) calculate (interpolate) pixel for glyphs. + + X11::Rectangle bbox(x1, y1, w, h); + //We already check IsVisible, so, in principle, bbox at least has intersection with + //the current selected drawable. + if (X11::AdjustCropArea(dstPixmap, bbox)) + arrayGuard.Reset([dstPixmap readColorBits : bbox]); + + if (!arrayGuard.Get()) { + Error("DrawText", "problem with reading background pixels"); + return; + } + + //TODO: this is copy & paste from TGX11TTF, needs more checks (indices). + const Int_t xo = x1 < 0 ? -x1 : 0; + const Int_t yo = y1 < 0 ? -y1 : 0; + + for (int yp = 0; yp < int(bbox.fHeight) && yo + yp < h; ++yp) { + const unsigned char *srcBase = arrayGuard.Get() + bbox.fWidth * yp * 4; + for (int xp = 0; xp < int(bbox.fWidth) && xo + xp < w; ++xp) { + const unsigned char * const pixel = srcBase + xp * 4; + [pixmap.Get() putPixel : pixel X : xo + xp Y : yo + yp]; + } + } + } else { + //Find background color and set for all pixels. + [pixmap.Get() addPixel : defaultBackgroundPixel]; + } + + CGContextRef ctx = drawable.fContext; + const Quartz::CGStateGuard ctxGuard(ctx); + + CGContextSetRGBStrokeColor(ctx, 0., 0., 1., 1.); + // paint the glyphs in the pixmap. + TTGlyph *glyph = TTF::GetGlyphs(); + for (int n = 0; n < TTF::GetNumGlyphs(); ++n, ++glyph) { + if (FT_Glyph_To_Bitmap(&glyph->fImage, TTF::GetSmoothing() ? ft_render_mode_normal : ft_render_mode_mono, 0, 1 )) + continue; + + FT_BitmapGlyph bitmap = (FT_BitmapGlyph)glyph->fImage; + FT_Bitmap *source = &bitmap->bitmap; + const Int_t bx = bitmap->left + xOff; + const Int_t by = h - bitmap->top - yOff; + + DrawFTGlyphIntoPixmap(pixmap.Get(), source, TGCocoa::GetPixel(GetTextColor()), + mode == kClear ? ULong_t(-1) : 0xffffff, bx, by); + } + + const X11::Rectangle copyArea(0, 0, w, h); + const X11::Point dstPoint(x1, y1); + [dstPixmap copy : pixmap.Get() area : copyArea withMask : nil clipOrigin : X11::Point() toPoint : dstPoint]; +} //______________________________________________________________________________ -Bool_t TGQuartz::SetContextStrokeColor(Int_t ci) +void TGQuartz::DrawFTGlyphIntoPixmap(void *pHack, FT_Bitmap *source, ULong_t fore, ULong_t back, Int_t bx, Int_t by) { - // Set the current fill color in the current context. + //This function is a "remake" of TGX11FFT::DrawImage. + + //I'm using this code to reproduce the same text as generated by TGX11TTF. + //It's quite sloppy, as in original version. I tried to make it not so ugly and + //more or less readable. + + QuartzPixmap *pixmap = (QuartzPixmap *)pHack; + assert(pixmap != nil && "DrawFTGlyphIntoPixmap, pixmap parameter is nil"); + assert(source != 0 && "DrawFTGlyphIntoPixmap, source parameter is null"); + + if (TTF::GetSmoothing()) { + static ColorStruct_t col[5]; + // background kClear, i.e. transparent, we take as background color + // the average of the rgb values of all pixels covered by this character + if (back == ULong_t(-1) && source->width) { + const int maxDots = 50000; + int dots = Int_t(source->width * source->rows); + if (dots > maxDots) + dots = maxDots; + + //In original code, they first have to extract + //pixels and call XQueryColors. + //I have only one loop here. + ULong_t r = 0, g = 0, b = 0; + for (int y = 0, dotCnt = 0; y < int(source->rows); y++) { + for (int x = 0; x < int(source->width); x++) { + if (x + bx < int(pixmap.fWidth) && y + by < int(pixmap.fHeight)) { + const unsigned char * const pixels = pixmap.fData + (y + by) * pixmap.fWidth * 4 + (x + bx) * 4; + r += UShort_t(pixels[0] / 255. * 0xffff); + g += UShort_t(pixels[1] / 255. * 0xffff); + b += UShort_t(pixels[2] / 255. * 0xffff); + } + + if (++dotCnt >= maxDots) + break; + } + } + + if (dots) { + r /= dots; + g /= dots; + b /= dots; + } - CGContextRef ctx = (CGContextRef)GetCurrentContext(); + if (col[0].fRed == r && col[0].fGreen == g && col[0].fBlue == b) { + col[0].fPixel = back; + } else { + col[0].fPixel = ~back;//??? + col[0].fRed = (UShort_t) r; + col[0].fGreen = (UShort_t) g; + col[0].fBlue = (UShort_t) b; + } + } - const TColor *color = gROOT->GetColor(ci); - if (!color) - return kFALSE; + // if fore or background have changed from previous character + // recalculate the 3 smooting colors (interpolation between fore- + // and background colors) + if (fore != col[4].fPixel || back != col[0].fPixel) { + col[4].fPixel = fore; + TGCocoa::QueryColor(kNone, col[4]);//calculate fRed/fGreen/fBlue triple from fPixel. + if (back != (ULong_t)-1) { + col[0].fPixel = back; + TGCocoa::QueryColor(kNone, col[0]); + } - const CGFloat a = 1.; - Float_t rgb[3] = {}; - color->GetRGB(rgb[0], rgb[1], rgb[2]); - CGContextSetRGBStrokeColor (ctx, rgb[0], rgb[1], rgb[2], a); + // interpolate between fore and backgound colors + for (int x = 3; x > 0; --x) { + col[x].fRed = (col[4].fRed * x + col[0].fRed * (4 - x)) / 4; + col[x].fGreen = (col[4].fGreen * x + col[0].fGreen * (4 - x)) / 4; + col[x].fBlue = (col[4].fBlue * x + col[0].fBlue * (4 - x)) / 4; + TGCocoa::AllocColor(kNone, col[x]);//Calculate fPixel from fRed/fGreen/fBlue triplet. + } + } + + // put smoothed character, character pixmap values are an index + // into the 5 colors used for aliasing (4 = foreground, 0 = background) + const unsigned char *s = source->buffer; + for (int y = 0; y < (int) source->rows; ++y) { + for (int x = 0; x < (int) source->width; ++x) { + unsigned char d = *s++ & 0xff;//??? + d = ((d + 10) * 5) / 256;//??? + if (d > 4) + d = 4; + if (d && x < (int) source->width) { + const UChar_t pixel[] = {UChar_t(double(col[d].fRed) / 0xffff * 255), + UChar_t(double(col[d].fGreen) / 0xffff * 255), + UChar_t(double(col[d].fBlue) / 0xffff * 255), 255}; + [pixmap putPixel : pixel X : bx + x Y : by + y]; + } + } + } + } else { + // no smoothing, just put character using foreground color + unsigned char rgba[4] = {}; + rgba[3] = 255; + X11::PixelToRGB(fore, rgba); + unsigned char d = 0; + + const unsigned char *row = source->buffer; + for (int y = 0; y < int(source->rows); ++y) { + int n = 0; + const unsigned char *s = row; + for (int x = 0; x < int(source->width); ++x) { + if (!n) + d = *s++; + + if (TESTBIT(d,7 - n)) + [pixmap putPixel : rgba X : bx + x Y : by + y]; + + if (++n == int(kBitsPerByte)) + n = 0; + } + + row += source->pitch; + } + } +} + +//Aux. function. + +//______________________________________________________________________________ +void *TGQuartz::GetSelectedDrawableChecked(const char *calledFrom) const +{ + assert(calledFrom != 0 && "GetSelectedDrawableChecked, calledFrom parameter is null"); + assert(fSelectedDrawable > fPimpl->GetRootWindowID() && "GetSelectedDrawableChecked, bad drawable is selected"); - return kTRUE; + NSObject *drawable = fPimpl->GetDrawable(fSelectedDrawable); + if (!drawable.fIsPixmap) { + //TPad/TCanvas ALWAYS draw only into a pixmap. + if ([drawable isKindOfClass : [QuartzView class]]) { + QuartzView *view = (QuartzView *)drawable; + if (!view.fBackBuffer) { + Error(calledFrom, "Selected window is not double buffered"); + return 0; + } + + drawable = view.fBackBuffer; + } else { + Error(calledFrom, "Selected drawable is neither a pixmap, nor a double buffered window"); + return 0; + } + } + + if (!drawable.fContext) { + Error(calledFrom, "Context is null"); + return 0; + } + + return drawable; } diff --git a/graf2d/cocoa/src/X11Atoms.mm b/graf2d/cocoa/src/X11Atoms.mm new file mode 100644 index 0000000000000..7f12ea0e1ff8e --- /dev/null +++ b/graf2d/cocoa/src/X11Atoms.mm @@ -0,0 +1,95 @@ +#include "X11Atoms.h" + +namespace ROOT { +namespace MacOSX { +namespace X11 { + +//Predefined atoms. +const char *predefinedAtoms[] = +{ + "XA_PRIMARY", + "XA_SECONDARY", + "XA_ARC", + "XA_ATOM", + "XA_BITMAP", + "XA_CARDINAL", + "XA_COLORMAP", + "XA_CURSOR", + "XA_CUT_BUFFER0", + "XA_CUT_BUFFER1", + "XA_CUT_BUFFER2", + "XA_CUT_BUFFER3", + "XA_CUT_BUFFER4", + "XA_CUT_BUFFER5", + "XA_CUT_BUFFER6", + "XA_CUT_BUFFER7", + "XA_DRAWABLE", + "XA_FONT", + "XA_INTEGER", + "XA_PIXMAP", + "XA_POINT", + "XA_RECTANGLE", + "XA_RESOURCE_MANAGER", + "XA_RGB_COLOR_MAP", + "XA_RGB_BEST_MAP", + "XA_RGB_BLUE_MAP", + "XA_RGB_DEFAULT_MAP", + "XA_RGB_GRAY_MAP", + "XA_RGB_GREEN_MAP", + "XA_RGB_RED_MAP", + "XA_STRING", + "XA_VISUALID", + "XA_WINDOW", + "XA_WM_COMMAND", + "XA_WM_HINTS", + "XA_WM_CLIENT_MACHINE", + "XA_WM_ICON_NAME", + "XA_WM_ICON_SIZE", + "XA_WM_NAME", + "XA_WM_NORMAL_HINTS", + "XA_WM_SIZE_HINTS", + "XA_WM_ZOOM_HINTS", + "XA_MIN_SPACE", + "XA_NORM_SPACE", + "XA_MAX_SPACE", + "XA_END_SPACE", + "XA_SUPERSCRIPT_X", + "XA_SUPERSCRIPT_Y", + "XA_SUBSCRIPT_X", + "XA_SUBSCRIPT_Y", + "XA_UNDERLINE_POSITION", + "XA_UNDERLINE_THICKNESS", + "XA_STRIKEOUT_ASCENT", + "XA_STRIKEOUT_DESCENT", + "XA_ITALIC_ANGLE", + "XA_X_HEIGHT", + "XA_QUAD_WIDTH", + "XA_WEIGHT", + "XA_POINT_SIZE", + "XA_RESOLUTION", + "XA_COPYRIGHT", + "XA_NOTICE", + "XA_FONT_NAME", + "XA_FAMILY_NAME", + "XA_FULL_NAME", + "XA_CAP_HEIGHT", + "XA_WM_CLASS", + "XA_WM_TRANSIENT_FOR" +}; + +const unsigned nPredefined = sizeof predefinedAtoms / sizeof predefinedAtoms[0]; + +//______________________________________________________________________________ +void InitWithPredefinedAtoms(name_to_atom_map &nameToAtom, std::vector &atomNames) +{ + nameToAtom.clear(); + + for (unsigned i = 0; i < nPredefined; ++i) + nameToAtom[predefinedAtoms[i]] = i + 1; + + atomNames.assign(predefinedAtoms, predefinedAtoms + nPredefined); +} + +}//X11 +}//MacOSX +}//ROOT diff --git a/graf2d/cocoa/src/X11Buffer.mm b/graf2d/cocoa/src/X11Buffer.mm index 32346e7d4795a..cc4e2332e30fd 100644 --- a/graf2d/cocoa/src/X11Buffer.mm +++ b/graf2d/cocoa/src/X11Buffer.mm @@ -18,9 +18,11 @@ #include +#include "ROOTOpenGLView.h" #include "CocoaPrivate.h" #include "QuartzWindow.h" #include "QuartzPixmap.h" +#include "QuartzUtils.h" #include "X11Drawable.h" #include "X11Buffer.h" #include "TGWindow.h" @@ -50,6 +52,11 @@ { } +//______________________________________________________________________________ +void Command::Execute(CGContextRef /*ctx*/)const +{ +} + //______________________________________________________________________________ bool Command::HasOperand(Drawable_t wid)const { @@ -63,7 +70,7 @@ } //______________________________________________________________________________ -DrawLine::DrawLine(Drawable_t wid, const GCValues_t &gc, const Point_t &p1, const Point_t &p2) +DrawLine::DrawLine(Drawable_t wid, const GCValues_t &gc, const Point &p1, const Point &p2) : Command(wid, gc), fP1(p1), fP2(p2) @@ -73,7 +80,7 @@ //______________________________________________________________________________ void DrawLine::Execute()const { - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "Execute, gVirtualX is either null or not of TGCocoa type"); vx->DrawLineAux(fID, fGC, fP1.fX, fP1.fY, fP2.fX, fP2.fY); } @@ -91,7 +98,7 @@ //______________________________________________________________________________ void DrawSegments::Execute()const { - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "Execute, gVirtualX is either null or not of TGCocoa type"); vx->DrawSegmentsAux(fID, fGC, &fSegments[0], (Int_t)fSegments.size()); } @@ -106,13 +113,13 @@ //______________________________________________________________________________ void ClearArea::Execute()const { - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "Execute, gVirtualX is either null or not of TGCocoa type"); vx->ClearAreaAux(fID, fArea.fX, fArea.fY, fArea.fWidth, fArea.fHeight); } //______________________________________________________________________________ -CopyArea::CopyArea(Drawable_t src, Drawable_t dst, const GCValues_t &gc, const Rectangle_t &area, const Point_t &dstPoint) +CopyArea::CopyArea(Drawable_t src, Drawable_t dst, const GCValues_t &gc, const Rectangle_t &area, const Point &dstPoint) : Command(dst, gc), fSrc(src), fArea(area), @@ -129,13 +136,13 @@ //______________________________________________________________________________ void CopyArea::Execute()const { - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "Execute, gVirtualX is either null or not of TGCocoa type"); vx->CopyAreaAux(fSrc, fID, fGC, fArea.fX, fArea.fY, fArea.fWidth, fArea.fHeight, fDstPoint.fX, fDstPoint.fY); } //______________________________________________________________________________ -DrawString::DrawString(Drawable_t wid, const GCValues_t &gc, const Point_t &point, const std::string &text) +DrawString::DrawString(Drawable_t wid, const GCValues_t &gc, const Point &point, const std::string &text) : Command(wid, gc), fPoint(point), fText(text) @@ -145,7 +152,7 @@ //______________________________________________________________________________ void DrawString::Execute()const { - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "Execute, gVirtualX is either null or not of TGCocoa type"); vx->DrawStringAux(fID, fGC, fPoint.fX, fPoint.fY, fText.c_str(), fText.length()); } @@ -160,7 +167,7 @@ //______________________________________________________________________________ void FillRectangle::Execute()const { - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "Execute, gVirtualX is either null or not of TGCocoa type"); vx->FillRectangleAux(fID, fGC, fRectangle.fX, fRectangle.fY, fRectangle.fWidth, fRectangle.fHeight); } @@ -178,7 +185,7 @@ //______________________________________________________________________________ void FillPolygon::Execute()const { - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "Execute, gVirtualX is either null or not of TGCocoa type"); vx->FillPolygonAux(fID, fGC, &fPolygon[0], (Int_t)fPolygon.size()); } @@ -193,7 +200,7 @@ //______________________________________________________________________________ void DrawRectangle::Execute()const { - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "Execute, gVirtualX is either null or not of TGCocoa type"); vx->DrawRectangleAux(fID, fGC, fRectangle.fX, fRectangle.fY, fRectangle.fWidth, fRectangle.fHeight); } @@ -211,12 +218,8 @@ { assert(fView.fContext != 0 && "Execute, view.fContext is null"); - if (QuartzPixmap *pixmap = fView.fBackBuffer) { - CGImageRef image = [pixmap createImageFromPixmap];//CGBitmapContextCreateImage(pixmap.fContext); - const CGRect imageRect = CGRectMake(0, 0, pixmap.fWidth, pixmap.fHeight); - CGContextDrawImage(fView.fContext, imageRect, image); - CGImageRelease(image); - } + if (QuartzPixmap *pixmap = fView.fBackBuffer) + [fView copy : pixmap area : Rectangle(0, 0, pixmap.fWidth, pixmap.fHeight) withMask : nil clipOrigin : Point() toPoint : Point()]; } //______________________________________________________________________________ @@ -228,11 +231,70 @@ //______________________________________________________________________________ void DeletePixmap::Execute()const { - TGCocoa *vx = dynamic_cast(gVirtualX); + TGCocoa * const vx = dynamic_cast(gVirtualX); assert(vx != 0 && "Execute, gVirtualX is either null or not of TGCocoa type"); vx->DeletePixmapAux(fID); } +//______________________________________________________________________________ +DrawBoxXor::DrawBoxXor(Window_t windowID, const Point &p1, const Point &p2) + : Command(windowID, GCValues_t()), + fP1(p1), + fP2(p2) +{ + if (fP1.fX > fP2.fX) + std::swap(fP1.fX, fP2.fX); + if (fP1.fY > fP2.fY) + std::swap(fP1.fY, fP2.fY); +} + +//______________________________________________________________________________ +void DrawBoxXor::Execute()const +{ + //Noop. +} + +//______________________________________________________________________________ +void DrawBoxXor::Execute(CGContextRef ctx)const +{ + // + assert(ctx != 0 && "Execute, ctx parameter is null"); + + CGContextSetRGBStrokeColor(ctx, 0., 0., 0., 1.); + CGContextSetLineWidth(ctx, 1.); + + CGContextStrokeRect(ctx, CGRectMake(fP1.fX, fP1.fY, fP2.fX - fP1.fX, fP2.fY - fP1.fY)); +} + +//______________________________________________________________________________ +DrawLineXor::DrawLineXor(Window_t windowID, const Point &p1, const Point &p2) + : Command(windowID, GCValues_t()), + fP1(p1), + fP2(p2) +{ +} + +//______________________________________________________________________________ +void DrawLineXor::Execute()const +{ + //Noop. +} + +//______________________________________________________________________________ +void DrawLineXor::Execute(CGContextRef ctx)const +{ + // + assert(ctx != 0 && "Execute, ctx parameter is null"); + + CGContextSetRGBStrokeColor(ctx, 0., 0., 0., 1.); + CGContextSetLineWidth(ctx, 1.); + + CGContextBeginPath(ctx); + CGContextMoveToPoint(ctx, fP1.fX, fP1.fY); + CGContextAddLineToPoint(ctx, fP2.fX, fP2.fY); + CGContextStrokePath(ctx); +} + //______________________________________________________________________________ CommandBuffer::CommandBuffer() { @@ -242,21 +304,14 @@ CommandBuffer::~CommandBuffer() { ClearCommands(); + ClearXOROperations(); } //______________________________________________________________________________ void CommandBuffer::AddDrawLine(Drawable_t wid, const GCValues_t &gc, Int_t x1, Int_t y1, Int_t x2, Int_t y2) { try { - Point_t p1 = {}; - //I'd use .fX = x1 from standard C, but ... this is already C++0x + Obj-C :) - //So, not to make it worse :) - p1.fX = x1; - p1.fY = y1; - Point_t p2 = {}; - p2.fX = x2; - p2.fY = y2; - std::auto_ptr cmd(new DrawLine(wid, gc, p1, p2));//if this throws, I do not care. + std::auto_ptr cmd(new DrawLine(wid, gc, Point(x1, y1), Point(x2, y2)));//if this throws, I do not care. fCommands.push_back(cmd.get());//this can throw. cmd.release(); } catch (const std::exception &) { @@ -283,7 +338,7 @@ void CommandBuffer::AddClearArea(Window_t wid, Int_t x, Int_t y, UInt_t w, UInt_t h) { try { - Rectangle_t r = {}; + Rectangle_t r = {};//To be replaced with X11::Rectangle. r.fX = x; r.fY = y; r.fWidth = (UShort_t)w; @@ -306,10 +361,7 @@ area.fY = srcY; area.fWidth = (UShort_t)width; area.fHeight = (UShort_t)height; - Point_t dstPoint = {}; - dstPoint.fX = dstX; - dstPoint.fY = dstY; - std::auto_ptr cmd(new CopyArea(src, dst, gc, area, dstPoint));//Can throw, nothing leaks. + std::auto_ptr cmd(new CopyArea(src, dst, gc, area, Point(dstX, dstY)));//Can throw, nothing leaks. fCommands.push_back(cmd.get());//this can throw. cmd.release(); } catch (const std::exception &) { @@ -324,10 +376,7 @@ if (len < 0)//Negative length can come from caller. len = std::strlen(text); const std::string substr(text, len);//Can throw. - Point_t p = {}; - p.fX = x; - p.fY = y; - std::auto_ptr cmd(new DrawString(wid, gc, p, substr));//Can throw. + std::auto_ptr cmd(new DrawString(wid, gc, Point(x, y), substr));//Can throw. fCommands.push_back(cmd.get());//can throw. cmd.release(); } catch (const std::exception &) { @@ -410,45 +459,28 @@ } } -namespace { - //______________________________________________________________________________ -void RepaintTree(QuartzView *view) +void CommandBuffer::AddDrawBoxXor(Window_t windowID, Int_t x1, Int_t y1, Int_t x2, Int_t y2) { - //Can be only QuartzView, ROOTOpenGLView should never have children views. - assert(view != nil && "RepaintTree, view parameter is nil"); - - TGCocoa *vx = (TGCocoa *)gVirtualX; - vx->CocoaDrawON(); - - for (NSView *child in [view subviews]) { - if ([child isKindOfClass : [QuartzView class]]) { - QuartzView *qv = (QuartzView *)child; - if ([qv lockFocusIfCanDraw]) { - NSGraphicsContext *nsContext = [NSGraphicsContext currentContext]; - assert(nsContext != nil && "RepaintTree, nsContext is nil"); - CGContextRef cgContext = (CGContextRef)[nsContext graphicsPort]; - assert(cgContext != 0 && "RepaintTree, cgContext is null");//remove this assert? - - CGContextRef oldCtx = qv.fContext; - qv.fContext = cgContext; - - TGWindow *window = gClient->GetWindowById(qv.fID); - assert(window != 0 && "RepaintTree, window was not found"); - - gClient->NeedRedraw(window, kTRUE); - qv.fContext = oldCtx; - - [qv unlockFocus]; - if ([[qv subviews] count]) - RepaintTree(qv); - } - } + try { + std::auto_ptr cmd(new DrawBoxXor(windowID, Point(x1, y1), Point(x2, y2))); + fXorOps.push_back(cmd.get()); + cmd.release(); + } catch (const std::exception &) { + throw; } - - vx->CocoaDrawOFF(); } +//______________________________________________________________________________ +void CommandBuffer::AddDrawLineXor(Window_t windowID, Int_t x1, Int_t y1, Int_t x2, Int_t y2) +{ + try { + std::auto_ptr cmd(new DrawLineXor(windowID, Point(x1, y1), Point(x2, y2))); + fXorOps.push_back(cmd.get()); + cmd.release(); + } catch (const std::exception &) { + throw; + } } //______________________________________________________________________________ @@ -456,6 +488,9 @@ void RepaintTree(QuartzView *view) { assert(impl != 0 && "Flush, impl parameter is null"); + //Basic es-guarantee: state is unknown, but valid, no + //resource leaks, no locked focus. + //All magic is here. CGContextRef prevContext = 0; CGContextRef currContext = 0; @@ -468,53 +503,121 @@ void RepaintTree(QuartzView *view) NSObject *drawable = impl->GetDrawable(cmd->fID); if (drawable.fIsPixmap) { - cmd->Execute(); + cmd->Execute();//Can throw, ok. continue; } QuartzView *view = (QuartzView *)impl->GetWindow(cmd->fID).fContentView; - if (prevView && prevView != view && [[prevView subviews] count]) - RepaintTree(prevView); + if (prevView != view) + ClipOverlaps(view);//Can throw, ok. prevView = view; - if ([view lockFocusIfCanDraw]) { - NSGraphicsContext *nsContext = [NSGraphicsContext currentContext]; - assert(nsContext != nil && "Flush, currentContext is nil"); - currContext = (CGContextRef)[nsContext graphicsPort]; - assert(currContext != 0 && "Flush, graphicsPort is null");//remove this assert? - - view.fContext = currContext; - if (prevContext && prevContext != currContext) - CGContextFlush(prevContext); - prevContext = currContext; - - cmd->Execute(); - if (view.fBackBuffer) { - //Very "special" window. - CGImageRef image = [view.fBackBuffer createImageFromPixmap];//CGBitmapContextCreateImage(view.fBackBuffer.fContext); - if (image) { - const CGRect imageRect = CGRectMake(0, 0, view.fBackBuffer.fWidth, view.fBackBuffer.fHeight); - CGContextDrawImage(view.fContext, imageRect, image); - CGImageRelease(image); + try { + if ([view lockFocusIfCanDraw]) { + NSGraphicsContext *nsContext = [NSGraphicsContext currentContext]; + assert(nsContext != nil && "Flush, currentContext is nil"); + currContext = (CGContextRef)[nsContext graphicsPort]; + assert(currContext != 0 && "Flush, graphicsPort is null");//remove this assert? + + view.fContext = currContext; + if (prevContext && prevContext != currContext) + CGContextFlush(prevContext); + prevContext = currContext; + + const Quartz::CGStateGuard ctxGuard(currContext); + + //Clip regions first. + if (fClippedRegion.size()) + CGContextClipToRects(currContext, &fClippedRegion[0], fClippedRegion.size()); + + //Now add also shape combine mask. + if (view.fQuartzWindow.fShapeCombineMask) + ClipToShapeMask(view, currContext); + + cmd->Execute();//This can throw, we should restore as much as we can here. + + if (view.fBackBuffer) { + //Very "special" window. + const Rectangle copyArea(0, 0, view.fBackBuffer.fWidth, view.fBackBuffer.fHeight); + [view copy : view.fBackBuffer area : copyArea withMask : nil clipOrigin : Point() toPoint : Point()]; } - } - + + [view unlockFocus]; + + view.fContext = 0; + } + } catch (const std::exception &) { + //Focus was locked, roll-back: [view unlockFocus]; + //View's context was modified, roll-back: view.fContext = 0; + //Re-throw, something really bad happened (std::bad_alloc). + throw; } } - - if (prevView && [[prevView subviews] count]) - RepaintTree(prevView); - + if (currContext) CGContextFlush(currContext); ClearCommands(); } +//______________________________________________________________________________ +void CommandBuffer::FlushXOROps(Details::CocoaPrivate *impl) +{ + assert(impl != 0 && "FlushXOROps, impl parameter is null"); + + if (!fXorOps.size()) + return; + + //I assume here, that all XOR ops in one iteration (one Update call) must + //be for the same window (if not, there is no normal way to implement this at all). + //TODO: verify and check this condition. + + NSObject *drawable = impl->GetDrawable(fXorOps[0]->fID); + + assert([drawable isKindOfClass : [QuartzView class]] && "FlushXOROps, drawable must be of type QuartzView"); + + QuartzView *view = (QuartzView *)drawable; + + if ([view lockFocusIfCanDraw]) { + NSGraphicsContext *nsContext = [NSGraphicsContext currentContext]; + assert(nsContext != nil && "FlushXOROps, currentContext is nil"); + CGContextRef currContext = (CGContextRef)[nsContext graphicsPort]; + assert(currContext != 0 && "FlushXOROps, graphicsPort is null");//remove this assert? + + const Quartz::CGStateGuard ctxGuard(currContext);//ctx guard. + + CGContextSetAllowsAntialiasing(currContext, false); + + view.fContext = currContext; + + if (view.fBackBuffer) {//back buffer has canvas' contents. + //Very "special" window. + const Rectangle copyArea(0, 0, view.fBackBuffer.fWidth, view.fBackBuffer.fHeight); + [view copy : view.fBackBuffer area : copyArea withMask : nil clipOrigin : Point() toPoint : Point()]; + } + + //Now, do "XOR" drawings. + for (size_type i = 0, e = fXorOps.size(); i < e; ++i) { + if (fXorOps[i]) { + fXorOps[i]->Execute(currContext); + } + } + + [view unlockFocus]; + view.fContext = 0; + + CGContextFlush(currContext); + + CGContextSetAllowsAntialiasing(currContext, true); + } + + ClearXOROperations(); +} + //______________________________________________________________________________ void CommandBuffer::RemoveOperationsForDrawable(Drawable_t drawable) { @@ -524,6 +627,13 @@ void RepaintTree(QuartzView *view) fCommands[i] = 0; } } + + for (size_type i = 0; i < fXorOps.size(); ++i) { + if (fXorOps[i] && fXorOps[i]->HasOperand(drawable)) { + delete fXorOps[i]; + fXorOps[i] = 0; + } + } } //______________________________________________________________________________ @@ -537,6 +647,17 @@ void RepaintTree(QuartzView *view) } } +//______________________________________________________________________________ +void CommandBuffer::RemoveXORGraphicsOperationsForWindow(Window_t wid) +{ + for (size_type i = 0; i < fCommands.size(); ++i) { + if (fXorOps[i] && fXorOps[i]->HasOperand(wid)) { + delete fXorOps[i]; + fXorOps[i] = 0; + } + } +} + //______________________________________________________________________________ void CommandBuffer::ClearCommands() { @@ -546,6 +667,297 @@ void RepaintTree(QuartzView *view) fCommands.clear(); } +//______________________________________________________________________________ +void CommandBuffer::ClearXOROperations() +{ + for (size_type i = 0, e = fXorOps.size(); i < e; ++i) + delete fXorOps[i]; + + fXorOps.clear(); +} + +//Clipping machinery. + +namespace { + +//________________________________________________________________________________________ +bool RectsOverlap(const NSRect &r1, const NSRect &r2) +{ + if (r2.origin.x >= r1.origin.x + r1.size.width) + return false; + if (r2.origin.x + r2.size.width <= r1.origin.x) + return false; + if (r2.origin.y >= r1.origin.y + r1.size.height) + return false; + if (r2.origin.y + r2.size.height <= r1.origin.y) + return false; + + return true; +} + +} + +//______________________________________________________________________________ +void CommandBuffer::ClipOverlaps(QuartzView *view) +{ + //QuartzViews do not have backing store. + //But ROOT calls gClient->NeedRedraw ignoring + //children or overlapping siblings. This leads + //to obvious problems, for example, parent + //erasing every child inside while repainting itself. + //To fix this and emulate window with backing store + //without real backing store, I'm calculating the + //area of a view this is visible and not overlapped. + + //Who can overlap our view? + //1. Its own siblings and, probably, siblings of its ancestors. + //2. Children views. + + assert(view != nil && "ClipOverlaps, view parameter is nil"); + + typedef std::vector::reverse_iterator reverse_iterator; + typedef std::vector::iterator rect_iterator; + + fRectsToClip.clear(); + fClippedRegion.clear(); + + //Check siblings and ancestors' siblings: + + //1. Remember the whole branch starting from our view + //up to a top-level window. + fViewBranch.clear(); + for (QuartzView *v = view; v; v = v.fParentView) + fViewBranch.push_back(v); + + //We do not need content view, since it does not have any siblings. + if (fViewBranch.size()) + fViewBranch.pop_back(); + + //For every fViewBranch[i] in our branch, we're looking for overlapping siblings. + //Calculations are in view.fParentView's coordinate system. + + WidgetRect clipRect; + NSRect frame1 = {}; + + const NSRect frame2 = view.frame; + + for (reverse_iterator it = fViewBranch.rbegin(), eIt = fViewBranch.rend(); it != eIt; ++it) { + QuartzView *ancestorView = *it;//This is either one of ancestors, or a view itself. + bool doCheck = false; + for (QuartzView *sibling in [ancestorView.fParentView subviews]) { + if (ancestorView == sibling) { + //View has its children in an array, and for every subviews[i] in this array, + //only views with index > i can overlap subviews[i]. + doCheck = true;//all views after this must be checked. + continue; + } else if (!doCheck || sibling.fMapState != kIsViewable) { + continue; + } + + frame1 = sibling.frame; + + if (!frame1.size.width || !frame1.size.height) + continue; + + frame1.origin = [sibling.fParentView convertPoint : frame1.origin toView : view.fParentView]; + + //Check if two rects intersect. + if (RectsOverlap(frame2, frame1)) { + //Substruct frame1 from our view's rect. + clipRect.fX1 = frame1.origin.x; + clipRect.fX2 = clipRect.fX1 + frame1.size.width; + clipRect.fY1 = frame1.origin.y; + clipRect.fY2 = clipRect.fY1 + frame1.size.height; + fRectsToClip.push_back(clipRect); + } + } + } + + //Substruct children. + + for (QuartzView *child in [view subviews]) { + if (child.fMapState != kIsViewable) + continue; + + frame1 = child.frame; + + if (!frame1.size.width || !frame1.size.height) + continue; + + if (view.fParentView)//view can also be a content view. + frame1.origin = [view convertPoint : frame1.origin toView : view.fParentView]; + + if (RectsOverlap(frame2, frame1)) { + clipRect.fX1 = frame1.origin.x; + clipRect.fX2 = clipRect.fX1 + frame1.size.width; + clipRect.fY1 = frame1.origin.y; + clipRect.fY2 = clipRect.fY1 + frame1.size.height; + fRectsToClip.push_back(clipRect); + } + } + + if (fRectsToClip.size()) { + //Now, if we have any rectanges to substruct them from our view's frame, + //we are building a set of rectangles, which represents visible part of view. + + WidgetRect rect(frame2.origin.x, frame2.origin.y, frame2.origin.x + frame2.size.width, frame2.origin.y + frame2.size.height); + + BuildClipRegion(rect); + + if (view.fParentView) { + //To able to use this set of rectangles with CGContextClipToRects, + //convert them (if needed) into view's own coordinate system. + for (rect_iterator recIt = fClippedRegion.begin(), eIt = fClippedRegion.end(); recIt != eIt; ++recIt) { + if (!recIt->size.width && !recIt->size.height) {//This is a special 'empty' rectangle, which means our + assert(fClippedRegion.size() == 1 && "ClipOverlaps, internal logic error"); + break; //view is completely hidden. + } + recIt->origin = [view.fParentView convertPoint : recIt->origin toView : view]; + } + } + } +} + +namespace { + +typedef std::vector::iterator int_iterator; + +//_____________________________________________________________________________________________________ +int_iterator BinarySearchLeft(int_iterator first, int_iterator last, int value) +{ + if (first == last) + return last; + + const int_iterator it = std::lower_bound(first, last, value); + assert(it != last && (it == first || *it == value) && "internal logic error"); + + //If value < *first, return last (not found). + return it == first && *it != value ? last : it; +} + +//_____________________________________________________________________________________________________ +int_iterator BinarySearchRight(int_iterator first, int_iterator last, int value) +{ + if (first == last) + return last; + + const int_iterator it = std::lower_bound(first, last, value); + assert((it == last || *it == value) && "internal logic error"); + + return it; +} + +}//unnamed namespace. + +//_____________________________________________________________________________________________________ +void CommandBuffer::BuildClipRegion(const WidgetRect &rect) +{ + //Input requirements: + // 1) all rects are valid (non-empty and x1 < x2, y1 < y2); + // 2) all rects intersect with widget's rect. + //I do not check these conditions here, this is done when filling rectsToClip. + + //I did not find any reasonable algorithm (have to search better?), + //code in gdk and pixman has to many dependencies and is lib-specific + + //they require input to be quite special: + // a) no overlaps (in my case I have overlaps) + // b) sorted in a special way. + //To convert my input into such a format + //means to implement everything myself (for example, to work out overlaps). + + //Also, my case is more simple: gdk and pixman substract region (== set of rectangles) + //from another region, I have to substract region from _one_ rectangle. + + //This is quite straightforward implementation - I'm calculation rectangles, which are part of + //a widget's rect, not hidden by any of fRectsToClip. + //TODO: find a better algorithm. + typedef std::vector::const_iterator rect_const_iterator; + typedef std::vector::size_type size_type; + + assert(fRectsToClip.size() != 0 && "BuildClipRegion, nothing to clip"); + + fClippedRegion.clear(); + fXBounds.clear(); + fYBounds.clear(); + + //[First, we "cut" the original rect into stripes. + for (rect_const_iterator recIt = fRectsToClip.begin(), endIt = fRectsToClip.end(); recIt != endIt; ++recIt) { + if (recIt->fX1 <= rect.fX1 && recIt->fX2 >= rect.fX2 && recIt->fY1 <= rect.fY1 && recIt->fY2 >= rect.fY2) { + //this rect completely overlaps our view, not need to calculate anything at all. + fClippedRegion.push_back(CGRectMake(0., 0., 0., 0.)); + return; + } + + if (recIt->fX1 > rect.fX1)//recIt->x1 is always < rect.x2 (input validation). + fXBounds.push_back(recIt->fX1); + + if (recIt->fX2 < rect.fX2)//recIt->x2 is always > rect.x1 (input validation). + fXBounds.push_back(recIt->fX2); + + if (recIt->fY1 > rect.fY1) + fYBounds.push_back(recIt->fY1); + + if (recIt->fY2 < rect.fY2) + fYBounds.push_back(recIt->fY2); + } + + std::sort(fXBounds.begin(), fXBounds.end()); + std::sort(fYBounds.begin(), fYBounds.end()); + + //We do not need duplicates. + const int_iterator xBoundsEnd = std::unique(fXBounds.begin(), fXBounds.end()); + const int_iterator yBoundsEnd = std::unique(fYBounds.begin(), fYBounds.end()); + //Rectangle is now "cut into pieces"]. + + const size_type nXBands = size_type(xBoundsEnd - fXBounds.begin()) + 1; + const size_type nYBands = size_type(yBoundsEnd - fYBounds.begin()) + 1; + + fGrid.assign(nXBands * nYBands, false); + + //Mark the overlapped parts. + for (rect_const_iterator recIt = fRectsToClip.begin(), endIt = fRectsToClip.end(); recIt != endIt; ++recIt) { + const int_iterator left = BinarySearchLeft(fXBounds.begin(), xBoundsEnd, recIt->fX1); + const size_type firstXBand = left == xBoundsEnd ? 0 : left - fXBounds.begin() + 1; + + const int_iterator right = BinarySearchRight(fXBounds.begin(), xBoundsEnd, recIt->fX2); + const size_type lastXBand = right - fXBounds.begin() + 1; + + const int_iterator bottom = BinarySearchLeft(fYBounds.begin(), yBoundsEnd, recIt->fY1); + const size_type firstYBand = bottom == yBoundsEnd ? 0 : bottom - fYBounds.begin() + 1; + + const int_iterator top = BinarySearchRight(fYBounds.begin(), yBoundsEnd, recIt->fY2); + const size_type lastYBand = top - fYBounds.begin() + 1; + + for (size_type i = firstYBand; i < lastYBand; ++i) { + const size_type baseIndex = i * nXBands; + for (size_type j = firstXBand; j < lastXBand; ++j) + fGrid[baseIndex + j] = true; + } + } + + //I do not merge rectangles. + //Search for non-overlapped parts and create rectangles for them. + CGRect newRect = {}; + + for (size_type i = 0; i < nYBands; ++i) { + const size_type baseIndex = i * nXBands; + for (size_type j = 0; j < nXBands; ++j) { + if (!fGrid[baseIndex + j]) { + newRect.origin.x = j ? fXBounds[j - 1] : rect.fX1; + newRect.origin.y = i ? fYBounds[i - 1] : rect.fY1; + + newRect.size.width = (j == nXBands - 1 ? rect.fX2 : fXBounds[j]) - newRect.origin.x; + newRect.size.height = (i == nYBands - 1 ? rect.fY2 : fYBounds[i]) - newRect.origin.y; + + fClippedRegion.push_back(newRect); + } + } + } + + if (!fClippedRegion.size())//Completely hidden + fClippedRegion.push_back(CGRectMake(0., 0., 0., 0.)); +} + }//X11 }//MacOSX }//ROOT diff --git a/graf2d/cocoa/src/X11Events.mm b/graf2d/cocoa/src/X11Events.mm index 49a60a5851145..aea4c8d125a1c 100644 --- a/graf2d/cocoa/src/X11Events.mm +++ b/graf2d/cocoa/src/X11Events.mm @@ -16,6 +16,7 @@ #include +#include "ROOTOpenGLView.h" #include "QuartzWindow.h" #include "CocoaUtils.h" #include "KeySymbols.h" @@ -24,6 +25,56 @@ #include "TGWindow.h" #include "TList.h" +//TODO: check if different GenerateButtonXXXEvent functions can be affected by the fact mouse is pressed (and not released) +//in some view (Cocoa has "its own grab" - which view is receiving an event and if it's actually a view under cursor?) + +@interface FakeCrossingEvent : NSEvent { + NSWindow *fQuartzWindow; + NSPoint fLocationInWindow; +} + +@end + +@implementation FakeCrossingEvent + +//______________________________________________________________________________ +- (id) initWithWindow : (NSWindow *) window location : (NSPoint) location +{ + //Window should be always non-nil: we either enter some window, or exit some window. + assert(window && "initWithWindow:location:, window parameter is nil"); + + if (self = [super init]) { + fQuartzWindow = window; + fLocationInWindow = location; + } + + return self; +} + +//______________________________________________________________________________ +- (NSWindow *) window +{ + assert(fQuartzWindow && "window, fQuartzWindow is nil"); + return fQuartzWindow; +} + +//______________________________________________________________________________ +- (NSPoint) locationInWindow +{ + assert(fQuartzWindow != nil && "locationInWindow, fQuartzWindow is nil"); + return fLocationInWindow; +} + +//______________________________________________________________________________ +- (NSTimeInterval) timestamp +{ + //Hehe. + return 0.; +} + +@end + + namespace ROOT { namespace MacOSX { namespace X11 { @@ -128,6 +179,10 @@ void MapUnicharToKeySym(unichar key, char *buf, Int_t /*len*/, UInt_t &rootKeySy //______________________________________________________________________________ Int_t MapKeySymToKeyCode(Int_t keySym) { + //Apart from special keys, ROOT has also ASCII symbols, they map directly to themselves. + if (keySym >= 0x20 && keySym <= 0x7e) + return keySym; + static const KeySymPair keyMap[] = { {kKey_Escape, 27}, {kKey_Tab, NSTabCharacter}, @@ -223,6 +278,41 @@ NSUInteger GetCocoaKeyModifiersFromROOTKeyModifiers(UInt_t rootModifiers) return cocoaModifiers; } +//______________________________________________________________________________ +UInt_t GetKeyboardModifiers() +{ + const NSUInteger modifiers = [NSEvent modifierFlags]; + + UInt_t rootModifiers = 0; + if (modifiers & NSAlphaShiftKeyMask) + rootModifiers |= kKeyLockMask; + if (modifiers & NSShiftKeyMask) + rootModifiers |= kKeyShiftMask; + if (modifiers & NSControlKeyMask) + rootModifiers |= kKeyControlMask; + if (modifiers & NSAlternateKeyMask) + rootModifiers |= kKeyMod1Mask; + if (modifiers & NSCommandKeyMask) + rootModifiers |= kKeyMod2Mask; + + return rootModifiers; +} + +//______________________________________________________________________________ +UInt_t GetModifiers() +{ + UInt_t rootModifiers = GetKeyboardModifiers(); + const NSUInteger buttons = [NSEvent pressedMouseButtons]; + if (buttons & 1) + rootModifiers |= kButton1Mask; + if (buttons & 2) + rootModifiers |= kButton3Mask; + if (buttons & (1 << 2)) + rootModifiers |= kButton2Mask; + + return rootModifiers; +} + namespace Detail { //Several aux. functions to extract parameters from Cocoa events. @@ -262,19 +352,19 @@ void ConvertEventLocationToROOTXY(NSEvent *cocoaEvent, NSView *eventV //TODO: can [event window] be nil? (this can probably happen with mouse grabs). if (![cocoaEvent window]) NSLog(@"Error in ConvertEventLocationToROOTXY, window property of event is nil, can not convert coordinates correctly"); - - const NSPoint screenPoint = [[cocoaEvent window] convertBaseToScreen : [cocoaEvent locationInWindow]]; - NSPoint viewPoint = [[eventView window] convertScreenToBase : screenPoint]; - viewPoint = [eventView convertPointFromBase : viewPoint]; + + //Due to some reason, Apple has deprectated point conversion and requires to convert ... a rect. + //Even more, on HiDPI point conversion produces wrong results and rect conversion works. + + const NSPoint screenPoint = ConvertPointFromBaseToScreen([cocoaEvent window], [cocoaEvent locationInWindow]); + const NSPoint winPoint = ConvertPointFromScreenToBase(screenPoint, [eventView window]); + const NSPoint viewPoint = [eventView convertPoint : winPoint fromView : nil]; rootEvent->fX = viewPoint.x; rootEvent->fY = viewPoint.y; - WindowAttributes_t attr = {}; - GetRootWindowAttributes(&attr); - - rootEvent->fXRoot = screenPoint.x; - rootEvent->fYRoot = attr.fHeight - screenPoint.y; + rootEvent->fXRoot = GlobalXCocoaToROOT(screenPoint.x); + rootEvent->fYRoot = GlobalYCocoaToROOT(screenPoint.y); } //______________________________________________________________________________ @@ -308,6 +398,8 @@ unsigned GetModifiersFromCocoaEvent(NSEvent *theEvent) if (buttons & 1) rootModifiers |= kButton1Mask; if (buttons & 2) + rootModifiers |= kButton3Mask; + if (buttons & (1 << 2)) rootModifiers |= kButton2Mask; return rootModifiers; @@ -334,27 +426,32 @@ bool IsParent(NSView *testParent, NSView *testChild) } //______________________________________________________________________________ -void BuildAncestryBranch(NSView *view, std::vector *> &branch) +bool IsInBranch(NSView *parent, NSView *child, NSView *testView) { - assert(view != nil && "BuildAncestryBranch, view parameter is nil"); - assert(view.fParentView != nil && "BuildAncestryBranch, view must have a parent"); - assert(view.fLevel > 0 && "BuildAncestryBranch, view has nested level 0"); - - branch.resize(view.fLevel); + assert(child != nil && "IsInBranch, child parameter is nil"); + assert(testView != nil && "IsInBranch, testView parameter is nil"); - NSView *parent = view.fParentView; - std::vector *>::reverse_iterator iter = branch.rbegin(), endIter = branch.rend(); - for (; iter != endIter; ++iter) { - assert(parent != nil && "BuildAncestryBranch, fParentView is nil"); - *iter = parent; - parent = parent.fParentView; + if (testView == child || testView == parent) + return true; + + for (NSView *current = child.fParentView; current != parent; current = current.fParentView) { + if (current == testView) + return true; } + + return false; } +//Relation between two views. +enum Ancestry { + kAView1IsParent, + kAView2IsParent, + kAHaveNonRootAncestor, + kAAncestorIsRoot +}; + //______________________________________________________________________________ -Ancestry FindLowestCommonAncestor(NSView *view1, std::vector *> &branch1, - NSView *view2, std::vector *> &branch2, - NSView **lca) +Ancestry FindLowestCommonAncestor(NSView *view1, NSView *view2, NSView **lca) { //Search for the lowest common ancestor. //View1 can not be parent of view2, view2 can not be parent of view1, @@ -370,15 +467,9 @@ Ancestry FindLowestCommonAncestor(NSView *view1, std::vector *ancestor = nil; - - for (unsigned i = 0, j = 0; i < view1.fLevel && j < view2.fLevel && branch1[i] == branch2[j]; ++i, ++j) - ancestor = branch1[i]; + NSView * const ancestor = (NSView *)[view1 ancestorSharedWithView : view2]; - if (ancestor) { + if (ancestor) { *lca = ancestor; return kAHaveNonRootAncestor; } @@ -386,6 +477,22 @@ Ancestry FindLowestCommonAncestor(NSView *view1, std::vector *view1, NSView *view2, NSView **lca) +{ + assert(view1 != nil && "FindRelation, view1 parameter is nil"); + assert(view2 != nil && "FindRelation, view2 parameter is nil"); + assert(lca != 0 && "FindRelation, lca parameter is nil"); + + if (IsParent(view1, view2)) + return kAView1IsParent; + + if (IsParent(view2, view1)) + return kAView2IsParent; + + return FindLowestCommonAncestor(view1, view2, lca); +} + //______________________________________________________________________________ NSView *FindViewToPropagateEvent(NSView *viewFrom, Mask_t checkMask) { @@ -406,7 +513,11 @@ Ancestry FindLowestCommonAncestor(NSView *view1, std::vector *FindViewToPropagateEvent(NSView *viewFrom, Mask_t checkMask, NSView *grabView, Mask_t grabMask) { - //This function does not check passive grabs. + //This function is called when we have a grab and owner_events == true, + //in this case the grab view itself (and its grab mask) is checked + //at the end (if no view was found before). Grab view can be in a hierarchy + //for a 'viewFrom' view and can have matching fEventMask. + assert(viewFrom != nil && "FindViewToPropagateEvent, view parameter is nil"); if (viewFrom.fEventMask & checkMask) @@ -426,90 +537,7 @@ Ancestry FindLowestCommonAncestor(NSView *view1, std::vectorProcessedEvent(&event, window->GetId()); - } - - //This loop is from TGClient. Why window without parent can not handle event - //(and be "waitforwindow" - I do not know). - const bool maskedEvent = IsMaskedEvent(event.fType); - - for (TGWindow *ptr = window; ptr->GetParent() != 0; ptr = (TGWindow *) ptr->GetParent()) { - if (ptr->GetId() == gClient->GetWaitForWindow() || !maskedEvent) { - window->HandleEvent(&event); - //Actually, this can never happen now, but may change in future, so I have this check here. - if (event.fType == gClient->GetWaitForEvent() && event.fWindow == gClient->GetWaitForWindow()) - gClient->SetWaitForWindow(kNone); - - return; - } - } - - //This is the second loop (with nested loop) from TGClient. - //check if this is a popup menu - if (TList *lst = gClient->GetListOfPopups()) { - TIter next(lst); - - while (TGWindow *popup = (TGWindow *)next()) { - for (TGWindow *ptr = window; ptr->GetParent() != 0; ptr = (TGWindow *) ptr->GetParent()) { - if (ptr->GetId() == popup->GetId() && maskedEvent) { - window->HandleEvent(&event); - - //Actually, this can never happen now, but may change in future, so I have this check here. - if (event.fType == gClient->GetWaitForEvent() && event.fWindow == gClient->GetWaitForWindow()) - gClient->SetWaitForWindow(kNone); - - return; - } - } - } - } -} - -//______________________________________________________________________________ -void SendEvent(TGWindow *window, Event_t &event) -{ - //Event parameter is non-const, it can go to gClient->ProcessedEvent, which - //accepts non-const. - - assert(window != 0 && "SendEvent, window parameter is null"); - - if (gClient->GetWaitForWindow() == kNone) - window->HandleEvent(&event); - else - SendEventWithFilter(window, event); -} - -//______________________________________________________________________________ -void SendEnterEvent(NSView *view, NSEvent *theEvent, EXMagic detail) +void SendEnterEvent(EventQueue_t &queue, NSView *view, NSEvent *theEvent, EXMagic detail) { //1. Parameters are valid. //2. view.fID is valid. @@ -520,7 +548,7 @@ void SendEnterEvent(NSView *view, NSEvent *theEvent, EXMagic detail) assert(theEvent != nil && "SendEnterEvent, event parameter is nil"); assert(view.fID != 0 && "SendEnterEvent, view.fID is 0"); - TGWindow *window = gClient->GetWindowById(view.fID); + TGWindow * const window = gClient->GetWindowById(view.fID); if (!window) { #ifdef DEBUG_ROOT_COCOA NSLog(@"SendEnterEvent, ROOT's widget %u was not found", view.fID); @@ -537,15 +565,13 @@ void SendEnterEvent(NSView *view, NSEvent *theEvent, EXMagic detail) //inside a view. ConvertEventLocationToROOTXY(theEvent, view, &enterEvent); - - //Dispatch: -// window->HandleEvent(&enterEvent); - SendEvent(window, enterEvent); + //Enqueue event again. + queue.push_back(enterEvent); } //______________________________________________________________________________ -void SendLeaveEvent(NSView *view, NSEvent *theEvent, EXMagic detail) +void SendLeaveEvent(EventQueue_t &queue, NSView *view, NSEvent *theEvent, EXMagic detail) { //1. Parameters are valid. //2. view.fID is valid. @@ -556,7 +582,7 @@ void SendLeaveEvent(NSView *view, NSEvent *theEvent, EXMagic detail) assert(theEvent != nil && "SendLeaveEvent, event parameter is nil"); assert(view.fID != 0 && "SendLeaveEvent, view.fID is 0"); - TGWindow *window = gClient->GetWindowById(view.fID); + TGWindow * const window = gClient->GetWindowById(view.fID); if (!window) { #ifdef DEBUG_ROOT_COCOA NSLog(@"SendLeaveEvent, ROOT's widget %u was not found", view.fID); @@ -571,13 +597,12 @@ void SendLeaveEvent(NSView *view, NSEvent *theEvent, EXMagic detail) //Coordinates. Event possibly happend not in a view, also, coordinates are out of //the view. ConvertEventLocationToROOTXY(theEvent, view, &leaveEvent); - //Dispatch: -// window->HandleEvent(&leaveEvent); - SendEvent(window, leaveEvent); + //Enqueue event for ROOT. + queue.push_back(leaveEvent); } //______________________________________________________________________________ -void SendPointerMotionEvent(NSView *view, NSEvent *theEvent) +void SendPointerMotionEvent(EventQueue_t &queue, NSView *view, NSEvent *theEvent) { //1. Parameters are valid. //2. view.fID is valid. @@ -588,7 +613,7 @@ void SendPointerMotionEvent(NSView *view, NSEvent *theEvent) assert(theEvent != nil && "SendPointerMotionEvent, event parameter is nil"); assert(view.fID != 0 && "SendPointerMotionEvent, view.fID is 0"); - TGWindow *window = gClient->GetWindowById(view.fID); + TGWindow * const window = gClient->GetWindowById(view.fID); if (!window) { #ifdef DEBUG_ROOT_COCOA NSLog(@"SendPointerMotionEvent, ROOT's widget %u was not found", view.fID); @@ -603,13 +628,12 @@ void SendPointerMotionEvent(NSView *view, NSEvent *theEvent) //TODO: motionEvent.fUser[0] = find subwindow. ConvertEventLocationToROOTXY(theEvent, view, &motionEvent); - //Dispatch: - //window->HandleEvent(&motionEvent); - SendEvent(window, motionEvent); + //Enqueue event for ROOT. + queue.push_back(motionEvent); } //______________________________________________________________________________ -void SendButtonPressEvent(NSView *view, NSEvent *theEvent, EMouseButton btn) +void SendButtonPressEvent(EventQueue_t &queue, NSView *view, NSEvent *theEvent, EMouseButton btn) { //1. Parameters are valid. //2. view.fID is valid. @@ -621,7 +645,7 @@ void SendButtonPressEvent(NSView *view, NSEvent *theEvent, EMouseButt assert(theEvent != nil && "SendButtonPressEvent, event parameter is nil"); assert(view.fID != 0 && "SendButtonPressEvent, view.fID is 0"); - TGWindow *window = gClient->GetWindowById(view.fID); + TGWindow * const window = gClient->GetWindowById(view.fID); if (!window) { #ifdef DEBUG_ROOT_COCOA NSLog(@"SendButtonpressEvent, ROOT's widget %u was not found", view.fID); @@ -653,12 +677,12 @@ void SendButtonPressEvent(NSView *view, NSEvent *theEvent, EMouseButt } } - //Dispatch: - SendEvent(window, pressEvent); + //Enqueue event for ROOT. + queue.push_back(pressEvent); } //______________________________________________________________________________ -void SendButtonReleaseEvent(NSView *view, NSEvent *theEvent, EMouseButton btn) +void SendButtonReleaseEvent(EventQueue_t &queue, NSView *view, NSEvent *theEvent, EMouseButton btn) { //1. Parameters are valid. //2. view.fID is valid. @@ -669,7 +693,7 @@ void SendButtonReleaseEvent(NSView *view, NSEvent *theEvent, EMouseBu assert(theEvent != nil && "SendButtonReleaseEvent, event parameter is nil"); assert(view.fID != 0 && "SendButtonReleaseEvent, view.fID is 0"); - TGWindow *window = gClient->GetWindowById(view.fID); + TGWindow * const window = gClient->GetWindowById(view.fID); if (!window) { #ifdef DEBUG_ROOT_COCOA NSLog(@"SendButtonReleaseEvent, ROOT's widget %u was not found", view.fID); @@ -683,18 +707,18 @@ void SendButtonReleaseEvent(NSView *view, NSEvent *theEvent, EMouseBu releaseEvent.fState = GetKeyboardModifiersFromCocoaEvent(theEvent); // ConvertEventLocationToROOTXY(theEvent, view, &releaseEvent); - //Dispatch: - SendEvent(window, releaseEvent); + //Enqueue for ROOT. + queue.push_back(releaseEvent); } //______________________________________________________________________________ -void SendKeyPressEvent(NSView *view, NSView *childView, NSEvent *theEvent, NSPoint windowPoint) +void SendKeyPressEvent(EventQueue_t &queue, NSView *view, NSView *childView, NSEvent *theEvent, NSPoint windowPoint) { assert(view != nil && "SendKeyPressEvent, view parameter is nil"); assert(theEvent != nil && "SendKeyPressEvent, event parameter is nil"); assert(view.fID != 0 && "SendKeyPressEvent, view.fID is 0"); - TGWindow *window = gClient->GetWindowById(view.fID); + TGWindow * const window = gClient->GetWindowById(view.fID); if (!window) { #ifdef DEBUG_ROOT_COCOA NSLog(@"SendKeyPressEvent, ROOT's widget %u was not found", view.fID); @@ -712,7 +736,10 @@ void SendKeyPressEvent(NSView *view, NSView *childView, NS keyPressEvent.fCode = [characters characterAtIndex : 0]; - const NSPoint viewPoint = [view convertPointFromBase : windowPoint]; + //convertPointFromBase is deprecated. + //const NSPoint viewPoint = [view convertPointFromBase : windowPoint]; + const NSPoint viewPoint = [view convertPoint : windowPoint fromView : nil]; + //Coords. keyPressEvent.fX = viewPoint.x; keyPressEvent.fY = viewPoint.y; @@ -723,15 +750,16 @@ void SendKeyPressEvent(NSView *view, NSView *childView, NS if (childView) keyPressEvent.fUser[0] = childView.fID; - SendEvent(window, keyPressEvent); + //Enqueue for ROOT. + queue.push_back(keyPressEvent); } //______________________________________________________________________________ -void SendFocusInEvent(NSView *view, EXMagic mode) +void SendFocusInEvent(EventQueue_t &queue, NSView *view, EXMagic mode) { assert(view != nil && "SendFocusInEvent, view parameter is nil"); // - TGWindow *window = gClient->GetWindowById(view.fID); + TGWindow * const window = gClient->GetWindowById(view.fID); if (!window) { #ifdef DEBUG_ROOT_COCOA NSLog(@"SendFocusInEvent, ROOT's widget %u was not found", view.fID); @@ -740,19 +768,20 @@ void SendFocusInEvent(NSView *view, EXMagic mode) } Event_t focusInEvent = {}; + focusInEvent.fWindow = view.fID; focusInEvent.fType = kFocusIn; focusInEvent.fCode = mode; // focusInEvent.fState = ; - SendEvent(window, focusInEvent); + queue.push_back(focusInEvent); } //______________________________________________________________________________ -void SendFocusOutEvent(NSView *view, EXMagic mode) +void SendFocusOutEvent(EventQueue_t &queue, NSView *view, EXMagic mode) { assert(view != nil && "SendFocusOutEvent, view parameter is nil"); // - TGWindow *window = gClient->GetWindowById(view.fID); + TGWindow * const window = gClient->GetWindowById(view.fID); if (!window) { #ifdef DEBUG_ROOT_COCOA NSLog(@"SendFocusOutEvent, ROOT's widget %u was not found", view.fID); @@ -761,17 +790,18 @@ void SendFocusOutEvent(NSView *view, EXMagic mode) } Event_t focusOutEvent = {}; + focusOutEvent.fWindow = view.fID; focusOutEvent.fType = kFocusOut; focusOutEvent.fCode = mode;//code mode :) //focusOutEvent.fState = ; - SendEvent(window, focusOutEvent); + queue.push_back(focusOutEvent); } //Aux. functions to send events to view's branch. //______________________________________________________________________________ -void SendEnterEventRange(NSView *from, NSView *to, NSEvent *theEvent, EXMagic mode) +void SendEnterEventRange(EventQueue_t &queue, NSView *from, NSView *to, NSEvent *theEvent, EXMagic mode) { //[from, to) - legal range, 'to' must be ancestor for 'from'. assert(from != nil && "SendEnterEventRange, 'from' parameter is nil"); @@ -779,27 +809,27 @@ void SendEnterEventRange(NSView *from, NSView *to, NSEvent assert(theEvent != nil && "SendEnterEventRange, event parameter is nil"); while (from != to) { - if (from.fEventMask & kEnterWindowMask) - SendEnterEvent(from, theEvent, mode); + if ([from acceptsCrossingEvents : kEnterWindowMask]) + SendEnterEvent(queue, from, theEvent, mode); from = from.fParentView; } } //______________________________________________________________________________ -void SendEnterEventClosedRange(NSView *from, NSView *to, NSEvent *theEvent, EXMagic mode) +void SendEnterEventClosedRange(EventQueue_t &queue, NSView *from, NSView *to, NSEvent *theEvent, EXMagic mode) { //[from, to] - inclusive, legal range, 'to' must be ancestor for 'from'. assert(from != nil && "SendEnterEventClosedRange, 'from' parameter is nil"); assert(to != nil && "SendEnterEventClosedRange, 'to' parameter is nil"); assert(theEvent != nil && "SendEnterEventClosedRange, event parameter is nil"); - SendEnterEventRange(from, to, theEvent, mode); - if (to.fEventMask & kEnterWindowMask) - SendEnterEvent(to, theEvent, mode); + SendEnterEventRange(queue, from, to, theEvent, mode); + if ([to acceptsCrossingEvents : kEnterWindowMask]) + SendEnterEvent(queue, to, theEvent, mode); } //______________________________________________________________________________ -void SendLeaveEventRange(NSView *from, NSView *to, NSEvent *theEvent, EXMagic mode) +void SendLeaveEventRange(EventQueue_t &queue, NSView *from, NSView *to, NSEvent *theEvent, EXMagic mode) { //[from, to) - legal range, 'to' must be ancestor for 'from'. assert(from != nil && "SendLeaveEventRange, 'from' parameter is nil"); @@ -807,29 +837,30 @@ void SendLeaveEventRange(NSView *from, NSView *to, NSEvent assert(theEvent != nil && "SendLeaveEventRange, event parameter is nil"); while (from != to) { - if (from.fEventMask & kLeaveWindowMask) - SendLeaveEvent(from, theEvent, mode); + if ([from acceptsCrossingEvents : kLeaveWindowMask]) + SendLeaveEvent(queue, from, theEvent, mode); from = from.fParentView; } } //______________________________________________________________________________ -void SendLeaveEventClosedRange(NSView *from, NSView *to, NSEvent *theEvent, EXMagic mode) +void SendLeaveEventClosedRange(EventQueue_t &queue, NSView *from, NSView *to, NSEvent *theEvent, EXMagic mode) { //[from, to] - inclusive, legal range, 'to' must be ancestor for 'from'. assert(from != nil && "SendLeaveEventClosedRange, 'from' parameter is nil"); assert(to != nil && "SendLeaveEventClosedRange, 'to' parameter is nil"); assert(theEvent != nil && "SendLeaveEventClosedRange, event parameter is nil"); - SendLeaveEventRange(from, to, theEvent, mode); - if (to.fEventMask & kLeaveWindowMask) - SendLeaveEvent(to, theEvent, mode); + SendLeaveEventRange(queue, from, to, theEvent, mode); + if ([to acceptsCrossingEvents : kLeaveWindowMask]) + SendLeaveEvent(queue, to, theEvent, mode); } //Top-level crossing event generators. +//When passing parent and child view, parent view always precedes the child, even if function's name is GenerateCrossingEventChildToParent. //______________________________________________________________________________ -void GenerateCrossingEventChildToParent(NSView *parent, NSView *child, NSEvent *theEvent, EXMagic detail) +void GenerateCrossingEventChildToParent(EventQueue_t &queue, NSView *parent, NSView *child, NSEvent *theEvent, EXMagic detail) { //Pointer moves from window A to window B and A is an inferior of B. //Generate LeaveNotify on A (with detail NotifyAncestor). @@ -843,17 +874,21 @@ void GenerateCrossingEventChildToParent(NSView *parent, NSView *parent, NSView *child, NSEvent *theEvent, EXMagic detail) +void GenerateCrossingEventParentToChild(EventQueue_t &queue, NSView *parent, NSView *child, NSEvent *theEvent, EXMagic detail) { //Pointer moves from window A to window B and B is an inferior of A. //Generate LeaveNotify event for A, detail == NotifyInferior. @@ -866,20 +901,22 @@ void GenerateCrossingEventParentToChild(NSView *parent, NSView *child1, NSView *child2, NSView *ancestor, NSEvent *theEvent, EXMagic detail) +void GenerateCrossingEventFromChild1ToChild2(EventQueue_t &queue, NSView *child1, NSView *child2, NSView *ancestor, NSEvent *theEvent, EXMagic detail) { //Pointer moves from window A to window B and window C is their lowest common ancestor. //Generate LeaveNotify for window A with detail == NotifyNonlinear. @@ -892,24 +929,138 @@ void GenerateCrossingEventFromChild1ToChild2(NSView *child1, NSView *)[[child1 window] contentView], theEvent, detail); - if (child2.fParentView) - SendEnterEventClosedRange(child2.fParentView, (NSView *)[[child2 window] contentView], theEvent, detail); + if (child1.fParentView)//Leave [child1.fParentView contentView] + SendLeaveEventClosedRange(queue, child1.fParentView, (NSView *)[[child1 window] contentView], theEvent, detail); + if (child2.fParentView)//Enter [child2.fParentView contentView] - order is reversed. + SendEnterEventClosedRange(queue, child2.fParentView, (NSView *)[[child2 window] contentView], theEvent, detail); } else { - if (child1.fParentView) - SendLeaveEventRange(child1.fParentView, ancestor, theEvent, detail); - if (child2.fParentView) - SendEnterEventRange(child2.fParentView, ancestor, theEvent, detail); + if (child1.fParentView)//Leave [child1.fParentView ancestor) + SendLeaveEventRange(queue, child1.fParentView, ancestor, theEvent, detail); + if (child2.fParentView)//Enter [child2.fParentView, ancestor) - order reversed. + SendEnterEventRange(queue, child2.fParentView, ancestor, theEvent, detail); } - if (child2.fEventMask & kEnterWindowMask) - SendEnterEvent(child2, theEvent, detail); + if ([child2 acceptsCrossingEvents : kEnterWindowMask]) + SendEnterEvent(queue, child2, theEvent, detail); +} + + +//______________________________________________________________________________ +void GenerateCrossingEvents(EventQueue_t &queue, NSView *fromView, NSView *toView, NSEvent *theEvent, EXMagic detail) +{ + //Pointer moved from 'fromView' to 'toView'. + //Check their relationship and generate leave/enter notify events. + + assert(theEvent != nil && "GenerateCrossingEvent, event parameter is nil"); + + if (fromView == toView) { + //This can happen: tracking areas for stacked windows call + //mouseExited even for overlapped views (so you have a bunch of mouseExited/mouseEntered + //for one cursor move). In mouseEntered/mouseExited + //I'm looking for the top level view under cursor and try to generate cross event + //for this view only. + return; + } + + if (!fromView) { + //We enter window "from the screen" - do not leave any window. + //Send EnterNotify event. + if (toView)//Send enter notify event to a branch [toView contentView], order of views is reversed, but no GUI actually depends on this. + SendEnterEventClosedRange(queue, toView, (NSView *)[[toView window] contentView], theEvent, detail); + } else if (!toView) { + //We exit all views. Order is correct here. + SendLeaveEventClosedRange(queue, fromView, (NSView *)[[fromView window] contentView], theEvent, detail); + } else { + NSView *ancestor = 0; + const Ancestry rel = FindRelation(fromView, toView, &ancestor); + if (rel == kAView1IsParent) { + //Case 1. + //From A to B. + //_________________ + //| A | + //| |---------| | + //| | B | | + //| | | | + //| |---------| | + //| | + //|________________| + GenerateCrossingEventParentToChild(queue, fromView, toView, theEvent, detail); + } else if (rel == kAView2IsParent) { + //Case 2. + //From A to B. + //_________________ + //| B | + //| |---------| | + //| | A | | + //| | | | + //| |---------| | + //| | + //|________________| + GenerateCrossingEventChildToParent(queue, toView, fromView, theEvent, detail); + } else { + //Case 3. + //|--------------------------------| + //| C |------| |-------| | + //| | A | | B | | + //| |______| |_______| | + //|________________________________| + //Ancestor is either some view, or 'root' window. + //The fourth case (different screens) is not implemented (and I do not know, if I want to implement it). + GenerateCrossingEventFromChild1ToChild2(queue, fromView, toView, ancestor, theEvent, detail); + } + } +} + +//______________________________________________________________________________ +void GenerateCrossingEventForGrabView(EventQueue_t &queue, NSView *fromView, NSView *toView, + NSView *grabView, Mask_t grabEventMask, NSEvent *theEvent) +{ + //When owner events == false, only grab view receives enter/leave notify events. + + //Send enter/leave event to a grab view. + assert(theEvent != nil && "GenerateCrossingEventForGrabView, event parameter is nil"); + assert(grabView != nil && "GenerateCrossingEventForGrabView, grabView parameter is nil"); + assert((fromView != nil || toView != nil) && "GenerateCrossingEventForGrabView, both toView and fromView parameters are nil"); + + if (fromView == toView)//No crossing at all? + return; + + const bool wantsEnter = grabEventMask & kEnterWindowMask; + const bool wantsLeave = grabEventMask & kLeaveWindowMask; + + if (fromView == grabView && wantsLeave) + return SendLeaveEvent(queue, grabView, theEvent, kNotifyNormal); + + if (toView == grabView && wantsEnter) + return SendEnterEvent(queue, grabView, theEvent, kNotifyNormal); + + if (!fromView) { + //We enter window "from the screen" - do not leave any window. + //Send EnterNotify event to the grab view, if it's "in the branch". + if (wantsEnter && IsParent(grabView, toView)) + SendEnterEvent(queue, grabView, theEvent, kNotifyNormal); + } else if (!toView) { + //We exit all views.. + if (wantsLeave && IsParent(grabView, fromView)) + SendLeaveEvent(queue, grabView, theEvent, kNotifyNormal); + } else { + NSView *ancestor = 0; + FindRelation(fromView, toView, &ancestor); + + if (IsInBranch(nil, fromView, grabView)) { + if (wantsLeave) + SendLeaveEvent(queue, grabView, theEvent, kNotifyNormal); + } else if (IsInBranch(nil, toView, grabView)) { + if (wantsEnter) + SendEnterEvent(queue, grabView, theEvent, kNotifyNormal); + } + } } }//Detail @@ -917,12 +1068,13 @@ void GenerateCrossingEventFromChild1ToChild2(NSView *child1, NSView *child1, NSViewGetWindowById(view.fID); + TGWindow * const window = gClient->GetWindowById(view.fID); assert(window != 0 && "GenerateConfigureNotifyEvent, window was not found"); window->HandleEvent(&newEvent); } @@ -975,152 +1127,74 @@ void GenerateCrossingEventFromChild1ToChild2(NSView *child1, NSViewGetWindowById(view.fID); + TGWindow * const window = gClient->GetWindowById(view.fID); assert(window != 0 && "GenerateExposeEvent, window was not found"); window->HandleEvent(&exposeEvent); } //______________________________________________________________________________ -void EventTranslator::GenerateCrossingEvent(NSView *view, NSEvent *theEvent) +void EventTranslator::GenerateCrossingEvent(NSEvent *theEvent) { - //View parameter can be nil (we exit any window). + //View parameter can be nil. + //TODO: change interface, it looks like I do not need the 'view' parameter. assert(theEvent != nil && "GenerateCrossingEvent, event parameter is nil"); - if (fPointerGrab == kPGNoGrab) { - NSView *candidateView = [[[view window] contentView] hitTest : [theEvent locationInWindow]]; - if (candidateView && ![candidateView isKindOfClass : [QuartzView class]]) {//TODO: add a test for OpenGL view. - NSLog(@"EventTranslator::GenerateCrossingEvent: error, hit test returned not a QuartzView!"); - candidateView = nil; - } + fPointerGrabType == kPGNoGrab ? GenerateCrossingEventNoGrab(theEvent) : + GenerateCrossingEventActiveGrab(theEvent); +} - GenerateCrossingEvent((NSView *)candidateView, theEvent, kNotifyNormal); - } else - GenerateCrossingEventActiveGrab(view, theEvent); +//______________________________________________________________________________ +void EventTranslator::GenerateCrossingEventNoGrab(NSEvent *theEvent) +{ + assert(theEvent && "GenerateCrossingEventNoGrab, theEvent parameter is nil"); + + NSView * const candidateView = FindViewForPointerEvent(theEvent); + //We moved from fViewUnderPointer (leave event) to candidateView (enter event). + Detail::GenerateCrossingEvents(fEventQueue, fViewUnderPointer, candidateView, theEvent, kNotifyNormal); + fViewUnderPointer = candidateView; } //______________________________________________________________________________ -void EventTranslator::GenerateCrossingEventActiveGrab(NSView *view, NSEvent *theEvent) +void EventTranslator::GenerateCrossingEventActiveGrab(NSEvent *theEvent) { - assert(view != nil && "GenerateCrossingEventActiveGrab, view parameter is nil"); assert(theEvent != nil && "GenerateCrossingEventActiveGrab, event parameter is nil"); - if (!fButtonGrabView)//implicit grab with 'root'? - return; - + + NSView * const candidateView = FindViewForPointerEvent(theEvent); + if (fOwnerEvents) { - NSView *candidateView = nil; - SortTopLevelWindows(); - QuartzWindow *topLevel = FindTopLevelWindowForMouseEvent(); - if (topLevel) { - const NSPoint mousePosition = [topLevel mouseLocationOutsideOfEventStream]; - candidateView = (NSView *)[[topLevel contentView] hitTest : mousePosition]; - if (candidateView) - //Do propagation. - candidateView = Detail::FindViewToPropagateEvent(candidateView, kEnterWindowMask | kLeaveWindowMask, fButtonGrabView, fGrabEventMask); - } - - GenerateCrossingEvent(candidateView, theEvent, kNotifyNormal); - } else { - if (view == fButtonGrabView) {//We enter or leave grab view. - const NSEventType type = [theEvent type]; - if (type == NSMouseEntered && (fButtonGrabView.fGrabButtonEventMask & kEnterWindowMask)) { - if (fViewUnderPointer != fButtonGrabView) {//Can it be false??? - Detail::SendEnterEvent(fButtonGrabView, theEvent, kNotifyNormal); - fViewUnderPointer = fButtonGrabView; - } - } - - if (type == NSMouseExited && (fButtonGrabView.fGrabButtonEventMask & kEnterWindowMask)) { - Detail::SendLeaveEvent(fButtonGrabView, theEvent, kNotifyNormal); - //Who is now under pointer? - fViewUnderPointer = nil; - } - } + //Either passive grab (which was activated) or active grab set by TGCocoa::GrabPointer with + //owner_events == true. This works the same way as nograb case, except not only fEventMask + //is checked, but for grab view (if it's boundary was crossed) either it's passive grab mask + //or active is also checked. + Detail::GenerateCrossingEvents(fEventQueue, fViewUnderPointer, candidateView, theEvent, kNotifyNormal); + } else if (fButtonGrabView && (fViewUnderPointer || candidateView)) { + //Either implicit grab or GrabPointer with owner_events == false, + //only grab view can receive enter/leave notify events. Only + //grab event mask is checked, not view's own event mask. + Detail::GenerateCrossingEventForGrabView(fEventQueue, fViewUnderPointer, candidateView, fButtonGrabView, fGrabEventMask, theEvent); } -} -//______________________________________________________________________________ -bool EventTranslator::HasPointerGrab()const -{ - return fPointerGrab != kPGNoGrab; + fViewUnderPointer = candidateView; } //______________________________________________________________________________ -void EventTranslator::GenerateCrossingEvent(NSView *view, NSEvent *theEvent, EXMagic detail) +bool EventTranslator::HasPointerGrab()const { - assert(theEvent != nil && "GenerateCrossingEvent, event parameter is nil"); - - if (view == fViewUnderPointer) { - //This can happen: tracking areas for stacked windows call - //mouseExited even for overlapped views (so you have a bunch of mouseExited/mouseEntered - //for one cursor move). In mouseEntered/mouseExited - //I'm looking for the top level view under cursor and try to generate cross event - //for this view only. - return; - } - - if (!fViewUnderPointer) { - //We enter window "from the screen" - do not leave any window. - //Send EnterNotify event. - if (view)//Check, if order is OK. - Detail::SendEnterEventClosedRange(view, (NSView *)[[view window] contentView], theEvent, detail); - } else if (!view) { - //We exit all views. Order must be OK here. - Detail::SendLeaveEventClosedRange(fViewUnderPointer, (NSView *)[[fViewUnderPointer window] contentView], theEvent, detail); - } else { - NSView *ancestor = 0; - Ancestry rel = FindRelation(fViewUnderPointer, view, &ancestor); - if (rel == kAView1IsParent) { - //Case 1. - //From A to B. - //_________________ - //| A | - //| |---------| | - //| | B | | - //| | | | - //| |---------| | - //| | - //|________________| - Detail::GenerateCrossingEventParentToChild(fViewUnderPointer, view, theEvent, detail); - } else if (rel == kAView2IsParent) { - //Case 2. - //From A to B. - //_________________ - //| B | - //| |---------| | - //| | A | | - //| | | | - //| |---------| | - //| | - //|________________| - Detail::GenerateCrossingEventChildToParent(view, fViewUnderPointer, theEvent, detail); - } else { - //Case 3. - //|--------------------------------| - //| C |------| |-------| | - //| | A | | B | | - //| |______| |_______| | - //|________________________________| - //Ancestor is either some view, or 'root' window. - //The fourth case (different screens) is not implemented (and I do not know, if I want to implement it). - Detail::GenerateCrossingEventFromChild1ToChild2(fViewUnderPointer, view, ancestor, theEvent, detail); - } - } - - fViewUnderPointer = view; + return fPointerGrabType != kPGNoGrab; } //______________________________________________________________________________ -void EventTranslator::GeneratePointerMotionEvent(NSView *eventView, NSEvent *theEvent) +void EventTranslator::GeneratePointerMotionEvent(NSEvent *theEvent) { - assert(eventView != nil && "GeneratePointerMotionEvent, view parameter is nil"); assert(theEvent != nil && "GeneratePointerMotionEvent, event parameter is nil"); + + - if (fPointerGrab == kPGNoGrab) { - return GeneratePointerMotionEventNoGrab(eventView, theEvent); - } else { - return GeneratePointerMotionEventActiveGrab(eventView, theEvent); - } + if (fPointerGrabType == kPGNoGrab) + return GeneratePointerMotionEventNoGrab(theEvent); + else + return GeneratePointerMotionEventActiveGrab(theEvent); } //______________________________________________________________________________ @@ -1129,7 +1203,7 @@ void GenerateCrossingEventFromChild1ToChild2(NSView *child1, NSView *child1, NSView *child1, NSView *child1, NSView *child1, NSView *grabView, unsigned eventMask, bool ownerEvents) { assert(grabView != nil && "SetPointerGrab, view parameter is nil"); + + if (fButtonGrabView) { + //This can happen with X11, does this happen with ROOT's GUI? + //Hm, should I send leave notify to the previous grab??? + //TODO: check this! + [fButtonGrabView cancelGrab]; + } + + //There is no kNoButton, unfortunately (but there is additional check on + //grab type). + fImplicitGrabButton = kAnyButton; - //Now some magic to receive mouse move events even outside any window. - if (eventMask & kPointerMotionMask) - [[grabView window] setAcceptsMouseMovedEvents : YES]; - + // fButtonGrabView = grabView; - fPointerGrab = kPGActiveGrab; + fPointerGrabType = kPGActiveGrab; fGrabEventMask = eventMask; fOwnerEvents = ownerEvents; + + //Generate sequence of crossing events - as if pointer + //"jumps" to the grab view. + + if (grabView != fViewUnderPointer) { + const NSPoint location = [[grabView window] mouseLocationOutsideOfEventStream]; + const Util::NSScopeGuard event([[FakeCrossingEvent alloc] initWithWindow : [grabView window] location : location]); + if (!event.Get()) { + //Hehe, if this happend, is it still possible to log???? + NSLog(@"EventTranslator::SetPointerGrab, crossing event initialization failed"); + return; + } + + Detail::GenerateCrossingEvents(fEventQueue, fViewUnderPointer, grabView, event.Get(), kNotifyGrab);//Uffffff, done! + } + + //Activate the current grab now. + [fButtonGrabView activateGrab : eventMask ownerEvents : fOwnerEvents]; } //______________________________________________________________________________ void EventTranslator::CancelPointerGrab() { - if (!fButtonGrabView) - return; + if (fButtonGrabView) + //Cancel grab (active, passive, implicit). + [fButtonGrabView cancelGrab]; + + //We generate sequence of leave/enter notify events (if any) as if we jumped from the grab view to the pointer view. + if (NSView * const candidateView = FindViewUnderPointer()) { + const NSPoint location = [[candidateView window] mouseLocationOutsideOfEventStream]; + const Util::NSScopeGuard event([[FakeCrossingEvent alloc] initWithWindow : [candidateView window] location : location ]); - [[fButtonGrabView window] setAcceptsMouseMovedEvents : NO];//Do not track mouse move events outside window anymore. - + if (!event.Get()) { + //Hehe, if this happend, is it still possible to log???? + NSLog(@"EventTranslator::CancelPointerGrab, crossing event initialization failed"); + return; + } + + Detail::GenerateCrossingEvents(fEventQueue, fButtonGrabView, candidateView, event.Get(), kNotifyUngrab); + } else if (fButtonGrabView) { + //convertScreenToBase is deprecated. + //const NSPoint location = [[fButtonGrabView window] convertScreenToBase : [NSEvent mouseLocation]]; + const NSPoint location = ConvertPointFromScreenToBase([NSEvent mouseLocation], [fButtonGrabView window]); + + const Util::NSScopeGuard event([[FakeCrossingEvent alloc] initWithWindow : [fButtonGrabView window] location : location ]); + if (!event.Get()) { + //Hehe, if this happend, is it still possible to log???? + NSLog(@"EventTranslator::CancelPointerGrab, crossing event initialization failed"); + fViewUnderPointer = nil; + return; + } + + Detail::GenerateCrossingEvents(fEventQueue, fButtonGrabView, nil, event.Get(), kNotifyUngrab);//Ufff, done!!! + } + + // + + fImplicitGrabButton = kAnyButton; fButtonGrabView = nil; - fPointerGrab = kPGNoGrab; + fPointerGrabType = kPGNoGrab; fGrabEventMask = 0; fOwnerEvents = true; } @@ -1234,11 +1364,11 @@ void GenerateCrossingEventFromChild1ToChild2(NSView *child1, NSView *newFocusView) { if (fFocusView && (fFocusView.fEventMask & kFocusChangeMask)) - Detail::SendFocusOutEvent(fFocusView, kNotifyNormal); + Detail::SendFocusOutEvent(fEventQueue, fFocusView, kNotifyNormal); if (newFocusView) { if (newFocusView.fEventMask & kFocusChangeMask) - Detail::SendFocusInEvent(newFocusView, kNotifyNormal); + Detail::SendFocusInEvent(fEventQueue, newFocusView, kNotifyNormal); fFocusView = newFocusView; } else @@ -1276,6 +1406,12 @@ void ClearPointerIfViewIsRelated(NSView *&view, Window_t winID) //______________________________________________________________________________ void EventTranslator::CheckUnmappedView(Window_t winID) { + //Window was unmapped, check, if it's the same window as the current grab, + //or focus window, or key grabbing window and if so - do cleanup. + + //TODO: This is quite rough implementation - not sure, if this also has to + //generate some additional events. + if (fButtonGrabView) { for (NSView *view = fButtonGrabView; view; view = view.fParentView) { if (view.fID == winID) { @@ -1285,31 +1421,52 @@ void ClearPointerIfViewIsRelated(NSView *&view, Window_t winID) } } - ClearPointerIfViewIsRelated(fViewUnderPointer, winID);//TODO: send event to this view first? + if (fViewUnderPointer) { + for (NSView *view = fViewUnderPointer; view; view = view.fParentView) { + if (view.fID == winID) { + NSPoint location = {}; + location.x = fViewUnderPointer.fWidth / 2; + location.y = fViewUnderPointer.fHeight / 2; + location = [fViewUnderPointer convertPoint : location toView : nil]; + + const Util::NSScopeGuard event([[FakeCrossingEvent alloc] initWithWindow : [fViewUnderPointer window] location : location]); + if (!event.Get()) { + //Hehe, if this happend, is it still possible to log???? + NSLog(@"EventTranslator::CheckUnmappedView, crossing event initialization failed"); + return; + } + + Detail::SendLeaveEvent(fEventQueue, fViewUnderPointer, event.Get(), kNotifyNormal); + fViewUnderPointer = nil; + + break; + } + } + } + ClearPointerIfViewIsRelated(fFocusView, winID);//TODO: send event to this view first? ClearPointerIfViewIsRelated(fKeyGrabView, winID);//TODO: send event to this view first?? } //______________________________________________________________________________ -void EventTranslator::GeneratePointerMotionEventNoGrab(NSView *eventView, NSEvent *theEvent) +void EventTranslator::GeneratePointerMotionEventNoGrab(NSEvent *theEvent) { //Without grab, things are simple: find a view which accepts pointer motion event. - - assert(eventView != nil && "GeneratePointerMotionEventNoGrab, view parameter is nil"); assert(theEvent != nil && "GeneratePointerMotionEventNoGrab, event parameter is nil"); - //Find a view on the top of stack: - NSView *candidateView = (NSView *)[[[eventView window] contentView] hitTest : [theEvent locationInWindow]]; - if (candidateView) { + const Mask_t maskToTest = [NSEvent pressedMouseButtons] ? (kPointerMotionMask | kButtonMotionMask) : kPointerMotionMask; + + //Event without any emulated grab, receiver view can be "wrong" (result of Cocoa's "dragging"). + if (NSView *candidateView = FindViewForPointerEvent(theEvent)) { //Do propagation. - candidateView = Detail::FindViewToPropagateEvent(candidateView, kPointerMotionMask); + candidateView = Detail::FindViewToPropagateEvent(candidateView, maskToTest); if (candidateView)//We have such a view, send event to a corresponding ROOT's window. - Detail::SendPointerMotionEvent(candidateView, theEvent); + Detail::SendPointerMotionEvent(fEventQueue, candidateView, theEvent); } } //______________________________________________________________________________ -void EventTranslator::GeneratePointerMotionEventActiveGrab(NSView * /*eventView*/, NSEvent *theEvent) +void EventTranslator::GeneratePointerMotionEventActiveGrab(NSEvent *theEvent) { //More complex case. Grab can be result of button press and set by SetPointerGrab. //In case of button press (this is either passive->active or implicit grab), @@ -1324,54 +1481,63 @@ void ClearPointerIfViewIsRelated(NSView *&view, Window_t winID) //assert(eventView != nil && "GeneratePointerMotionEventActiveGrab, view parameter is nil"); assert(theEvent != nil && "GeneratePointerMotionEventActiveGrab, event parameter is nil"); + const Mask_t maskToTest = [NSEvent pressedMouseButtons] ? (kPointerMotionMask | kButtonMotionMask) : kPointerMotionMask; + if (fOwnerEvents) { //Complex case, we have to correctly report event. - SortTopLevelWindows(); - if (QuartzWindow *topLevel = FindTopLevelWindowForMouseEvent()) { - const NSPoint mousePosition = [topLevel mouseLocationOutsideOfEventStream]; - NSView *candidateView = (NSView *)[[topLevel contentView] hitTest : mousePosition]; - if (candidateView) { - //Do propagation. - candidateView = Detail::FindViewToPropagateEvent(candidateView, kPointerMotionMask, fButtonGrabView, fGrabEventMask); - if (candidateView) {//We have such a view, send event to a corresponding ROOT's window. - Detail::SendPointerMotionEvent(candidateView, theEvent); - } - } + if (NSView *candidateView = FindViewForPointerEvent(theEvent)) { + candidateView = Detail::FindViewToPropagateEvent(candidateView, maskToTest, fButtonGrabView, fGrabEventMask); + if (candidateView)//We have such a view, send event to a corresponding ROOT's window. + Detail::SendPointerMotionEvent(fEventQueue, candidateView, theEvent); } else { //No such window - dispatch to the grab view. - if (fGrabEventMask & kPointerMotionMask) - Detail::SendPointerMotionEvent(fButtonGrabView, theEvent); + //Else: either implicit grab, or user requested grab with owner_grab == False. + if (fGrabEventMask & maskToTest) + Detail::SendPointerMotionEvent(fEventQueue, fButtonGrabView, theEvent); } } else { //Else: either implicit grab, or user requested grab with owner_grab == False. - if (fGrabEventMask & kPointerMotionMask) - Detail::SendPointerMotionEvent(fButtonGrabView, theEvent); + if (fGrabEventMask & maskToTest) + Detail::SendPointerMotionEvent(fEventQueue, fButtonGrabView, theEvent); } } //______________________________________________________________________________ void EventTranslator::GenerateButtonPressEventNoGrab(NSView *view, NSEvent *theEvent, EMouseButton btn) { + //Generate button press event when no pointer grab is active: + //either find a window with a passive grab, or create an implicit + //grab (to emulate X11's behavior). + assert(view != nil && "GenerateButtonPressEventNoGrab, view parameter is nil"); assert(theEvent != nil && "GenerateButtonPressEventNoGrab, event parameter is nil"); - FindButtonGrabView(view, theEvent, btn); - //And now something badly defined. I tried X11 on mac and on linux, they do different things. - //I'll do what was said in a spec and I do not care, if it's right or not, since there - //is nothing 'right' in all this crap and mess. Since I'm activating grab, - //before I send ButtonPress event, I'll send leave/enter notify events, if this is - //required (previously entered view and current view are different). - //If nothing was selected, on linux it looks like 'root' window - //becomes a grab and all pointer events are discarded until ungrab. - GenerateCrossingEvent(fButtonGrabView, theEvent, kNotifyGrab); + FindButtonGrab(view, theEvent, btn); - if (fButtonGrabView) - Detail::SendButtonPressEvent(fButtonGrabView, theEvent, btn); + fImplicitGrabButton = btn;//This info is useless for any grab type except the implicit one. + + //Now we have to generate a sequence of enter/leave notify events, + //like we "jump" from the previous view under the pointer to a grab view. + + Detail::GenerateCrossingEvents(fEventQueue, fViewUnderPointer, fButtonGrabView, theEvent, kNotifyGrab); + + //"Activate" a grab now, depending on type. + if (fButtonGrabView) { + if (fPointerGrabType == kPGPassiveGrab) + [fButtonGrabView activatePassiveGrab]; + else if (fPointerGrabType == kPGImplicitGrab) + [fButtonGrabView activateImplicitGrab]; + } + + if (fButtonGrabView)//Send press event to a grab view (either passive grab or implicit, but it has the required event bitmask). + Detail::SendButtonPressEvent(fEventQueue, fButtonGrabView, theEvent, btn); } //______________________________________________________________________________ void EventTranslator::GenerateButtonPressEventActiveGrab(NSView * /*view*/, NSEvent *theEvent, EMouseButton btn) { + //Generate button press event in the presence of activated pointer grab. + //TODO: change interface? remove view parameter from declaration. //assert(view != nil && "GenerateButtonPressEventActiveGrab, view parameter is nil"); @@ -1385,89 +1551,72 @@ void ClearPointerIfViewIsRelated(NSView *&view, Window_t winID) return; if (fOwnerEvents) { - SortTopLevelWindows(); - if (QuartzWindow *topLevel = FindTopLevelWindowForMouseEvent()) { - const NSPoint mousePosition = [topLevel mouseLocationOutsideOfEventStream]; - NSView *candidateView = (NSView *)[[topLevel contentView] hitTest : mousePosition]; - if (candidateView) { - //Do propagation. - candidateView = Detail::FindViewToPropagateEvent(candidateView, kButtonPressMask, fButtonGrabView, fGrabEventMask); - if (candidateView)//We have such a view, send event to a corresponding ROOT's window. - Detail::SendButtonPressEvent(candidateView, theEvent, btn); - } + if (NSView *candidateView = FindViewForPointerEvent(theEvent)) { + //Do propagation. + candidateView = Detail::FindViewToPropagateEvent(candidateView, kButtonPressMask, fButtonGrabView, fGrabEventMask); + if (candidateView)//We have such a view, send event to a corresponding ROOT's window. + Detail::SendButtonPressEvent(fEventQueue, candidateView, theEvent, btn); } else { if (fGrabEventMask & kButtonPressMask) - Detail::SendButtonPressEvent(fButtonGrabView, theEvent, btn); + Detail::SendButtonPressEvent(fEventQueue, fButtonGrabView, theEvent, btn); } } else { if (fGrabEventMask & kButtonPressMask) - Detail::SendButtonPressEvent(fButtonGrabView, theEvent, btn); + Detail::SendButtonPressEvent(fEventQueue, fButtonGrabView, theEvent, btn); } } //______________________________________________________________________________ void EventTranslator::GenerateButtonReleaseEventNoGrab(NSView *eventView, NSEvent *theEvent, EMouseButton btn) { + //Generate button release event when there is no active pointer grab. Can this even happen?? + assert(eventView != nil && "GenerateButtonReleaseEventNoGrab, view parameter is nil"); assert(theEvent != nil && "GenerateButtonReleaseEventNoGrabm event parameter is nil"); - if (NSView *candidateView = Detail::FindViewToPropagateEvent(eventView, kButtonPressMask)) - Detail::SendButtonReleaseEvent(candidateView, theEvent, btn); + if (NSView *candidateView = Detail::FindViewToPropagateEvent(eventView, kButtonReleaseMask)) + Detail::SendButtonReleaseEvent(fEventQueue, candidateView, theEvent, btn); } //______________________________________________________________________________ void EventTranslator::GenerateButtonReleaseEventActiveGrab(NSView *eventView, NSEvent *theEvent, EMouseButton btn) { + //Generate button release event in the presence of active grab (explicit pointer grab, activated passive grab or implicit grab). + assert(eventView != nil && "GenerateButtonReleaseEventActiveGrab, view parameter is nil"); assert(theEvent != nil && "GenerateButtonReleaseEventActiveGrab, event parameter is nil"); - - const Util::NSStrongReference *> eventViewGuard(eventView);//What if view is deleted in the middle of this function? if (!fButtonGrabView) { - if (fPointerGrab == kPGPassiveGrab || fPointerGrab == kPGImplicitGrab) { - //'root' window was a grab window. - fButtonGrabView = nil; - fPointerGrab = kPGNoGrab; - GenerateCrossingEvent(eventView, theEvent, kNotifyUngrab); - } - + //Still we have to cancel this grab (it's implicit grab on a 'root' window). + CancelPointerGrab(); return; } - if (fOwnerEvents) {//X11: Either XGrabPointer with owner_events == True or passive grab (owner_events is always true) - SortTopLevelWindows(); - if (QuartzWindow *topLevel = FindTopLevelWindowForMouseEvent()) { - const NSPoint mousePosition = [topLevel mouseLocationOutsideOfEventStream]; - NSView *candidateView = (NSView *)[[topLevel contentView] hitTest : mousePosition]; - if (candidateView) { - /* - bool continueSearch = true; - if (fPointerGrab == PointerGrab::passiveGrab && candidateView == fButtonGrabView) { - if (fGrabEventMask & kButtonReleaseMask) - continueSearch = false; - } - //Do propagation. - if (continueSearch)*/ + const Util::NSStrongReference *> eventViewGuard(eventView);//What if view is deleted in the middle of this function? + + if (fButtonGrabView) { + if (fOwnerEvents) {//X11: Either XGrabPointer with owner_events == True or passive grab (owner_events is always true) + if (NSView *candidateView = FindViewForPointerEvent(theEvent)) { candidateView = Detail::FindViewToPropagateEvent(candidateView, kButtonReleaseMask, fButtonGrabView, fGrabEventMask); - if (candidateView)//We have such a view, send event to a corresponding ROOT's window. - Detail::SendButtonReleaseEvent(candidateView, theEvent, btn); + //candidateView is either some view, or grab view, if its mask is ok. + if (candidateView) + Detail::SendButtonReleaseEvent(fEventQueue, candidateView, theEvent, btn); } else if (fGrabEventMask & kButtonReleaseMask) - Detail::SendButtonReleaseEvent(fButtonGrabView, theEvent, btn); - } else {//Report to the grab view, if it has a corresponding bit set. + Detail::SendButtonReleaseEvent(fEventQueue, fButtonGrabView, theEvent, btn); + } else {//Either implicit grab or GrabPointer with owner_events == False. if (fGrabEventMask & kButtonReleaseMask) - Detail::SendButtonReleaseEvent(fButtonGrabView, theEvent, btn); + Detail::SendButtonReleaseEvent(fEventQueue, fButtonGrabView, theEvent, btn); } - } else {//Either implicit grab or XGrabPointer with owner_events == False. - if (fGrabEventMask & kButtonReleaseMask) - Detail::SendButtonReleaseEvent(fButtonGrabView, theEvent, btn); + } else { + CancelPointerGrab();//'root' window had a grab, cancel it now. } - - if (fPointerGrab == kPGPassiveGrab || fPointerGrab == kPGImplicitGrab) { - fButtonGrabView = nil; - fPointerGrab = kPGNoGrab; - GenerateCrossingEvent(eventView, theEvent, kNotifyUngrab); - } + if (fPointerGrabType == kPGPassiveGrab && + (btn == fButtonGrabView.fPassiveGrabButton || fButtonGrabView.fPassiveGrabButton == kAnyButton)) + CancelPointerGrab(); + + if (fPointerGrabType == kPGImplicitGrab && btn == fImplicitGrabButton) + CancelPointerGrab(); } //______________________________________________________________________________ @@ -1477,7 +1626,7 @@ void ClearPointerIfViewIsRelated(NSView *&view, Window_t winID) assert(fFocusView != nil && "GenerateKeyPressEventNoGrab, fFocusView is nil"); FindKeyGrabView(fFocusView, theEvent); - + if (!fKeyGrabView) { NSView *candidateView = nil; @@ -1505,7 +1654,7 @@ void ClearPointerIfViewIsRelated(NSView *&view, Window_t winID) assert(theEvent != nil && "GenerateKeyEventActiveGrab, theEvent parameter is nil"); assert(fKeyGrabView != nil && "GenerateKeyEventActiveGrab, theEvent parameter is nil"); - if (NSView *candidateView = FindViewUnderPointer()) { + if (NSView * const candidateView = FindViewUnderPointer()) { //Since owner_events is always true in ROOT ... GenerateKeyEventForView(candidateView, theEvent); } else {// else part for grab view?? @@ -1528,11 +1677,11 @@ void ClearPointerIfViewIsRelated(NSView *&view, Window_t winID) { assert(theEvent != nil && "GenerateKeyReleaseEventNoGrab, theEvent parameter is nil"); - NSView *candidateView = FindViewUnderPointer(); + NSView * const candidateView = FindViewUnderPointer(); if (candidateView && Detail::IsParent(fFocusView, candidateView)) GenerateKeyEventForView(candidateView, theEvent); - else + else GenerateKeyEventForView(fFocusView, theEvent); } @@ -1547,7 +1696,7 @@ void ClearPointerIfViewIsRelated(NSView *&view, Window_t winID) const Mask_t eventType = theEvent.type == NSKeyDown ? kKeyPressMask : kKeyReleaseMask; NSView *childView = nil; - +/* for (;;) { if (!view.isHidden && (view.fEventMask & eventType)) break; @@ -1557,23 +1706,26 @@ void ClearPointerIfViewIsRelated(NSView *&view, Window_t winID) childView = view.isHidden ? nil : view; view = view.fParentView; } - + */ NSPoint mousePosition = {}; - SortTopLevelWindows(); - if (QuartzWindow *topLevel = FindTopLevelWindowForMouseEvent()) + if (QuartzWindow * const topLevel = FindWindowUnderPointer()) mousePosition = [topLevel mouseLocationOutsideOfEventStream]; if (eventType == kKeyPressMask) - Detail::SendKeyPressEvent(view, childView, theEvent, mousePosition); + Detail::SendKeyPressEvent(fEventQueue, view, childView, theEvent, mousePosition); else; } //______________________________________________________________________________ -void EventTranslator::FindButtonGrabView(NSView *fromView, NSEvent *theEvent, EMouseButton btn) +void EventTranslator::FindButtonGrab(NSView *fromView, NSEvent *theEvent, EMouseButton btn) { + //Find a view to become a grab view - either passive or implicit. + assert(fromView != nil && "FindButtonGrabView, view parameter is nil"); assert(theEvent != nil && "FindButtonGrabView, event parameter is nil"); + assert(fPointerGrabType == kPGNoGrab && "FindButtonGrabView, grab is already activated"); + const unsigned keyModifiers = Detail::GetKeyboardModifiersFromCocoaEvent(theEvent); NSView *grabView = 0; @@ -1585,28 +1737,28 @@ void ClearPointerIfViewIsRelated(NSView *&view, Window_t winID) buttonPressView = view; //Bottom-first view with passive grab. - if (view.fGrabButton == kAnyButton || view.fGrabButton == btn) { + if (view.fPassiveGrabButton == kAnyButton || view.fPassiveGrabButton == btn) { //Check modifiers. - if (view.fGrabKeyModifiers == kAnyModifier || (view.fGrabKeyModifiers & keyModifiers)) + if (view.fPassiveGrabKeyModifiers == kAnyModifier || (view.fPassiveGrabKeyModifiers & keyModifiers)) grabView = view; } } if (grabView) { fButtonGrabView = grabView; - fPointerGrab = kPGPassiveGrab; - fGrabEventMask = grabView.fGrabButtonEventMask; - fOwnerEvents = grabView.fOwnerEvents; + fPointerGrabType = kPGPassiveGrab; + fGrabEventMask = grabView.fPassiveGrabEventMask; + fOwnerEvents = grabView.fPassiveGrabOwnerEvents; } else if (buttonPressView) { - //This is implicit grab. + //This is an implicit grab. fButtonGrabView = buttonPressView; - fPointerGrab = kPGImplicitGrab; - fGrabEventMask = buttonPressView.fEventMask;//? + fPointerGrabType = kPGImplicitGrab; + fGrabEventMask = buttonPressView.fEventMask; fOwnerEvents = false; } else { //Implicit grab with 'root' window? fButtonGrabView = nil; - fPointerGrab = kPGImplicitGrab; + fPointerGrabType = kPGImplicitGrab; fGrabEventMask = 0; fOwnerEvents = false; } @@ -1618,11 +1770,11 @@ void ClearPointerIfViewIsRelated(NSView *&view, Window_t winID) assert(fromView != nil && "FindKeyGrabView, fromView parameter is nil"); assert(theEvent != nil && "FindKeyGrabView, theEvent parameter is nil"); - NSString *characters = [theEvent charactersIgnoringModifiers]; + NSString * const characters = [theEvent charactersIgnoringModifiers]; assert(characters != nil && "FindKeyGrabView, [theEvent characters] returned nil"); assert([characters length] > 0 && "FindKeyGrabView, characters is an empty string"); - const NSUInteger modifiers = [theEvent modifierFlags]; + const NSUInteger modifiers = [theEvent modifierFlags] & NSDeviceIndependentModifierFlagsMask; const unichar keyCode = [characters characterAtIndex : 0]; for (NSView *v = fromView; v; v = v.fParentView) { @@ -1631,72 +1783,6 @@ void ClearPointerIfViewIsRelated(NSView *&view, Window_t winID) } } -//______________________________________________________________________________ -NSView *EventTranslator::FindViewUnderPointer() -{ - SortTopLevelWindows(); - if (QuartzWindow *topLevel = FindTopLevelWindowForMouseEvent()) { - const NSPoint mousePosition = [topLevel mouseLocationOutsideOfEventStream]; - if (NSView *candidateView = (NSView *)[[topLevel contentView] hitTest : mousePosition]) - return candidateView; - } - - return nil; -} - -//______________________________________________________________________________ -Ancestry EventTranslator::FindRelation(NSView *view1, NSView *view2, NSView **lca) -{ - assert(view1 != nil && "FindRelation, view1 parameter is nil"); - assert(view2 != nil && "FindRelation, view2 parameter is nil"); - assert(lca != 0 && "FindRelation, lca parameter is nil"); - - if (Detail::IsParent(view1, view2)) - return kAView1IsParent; - - if (Detail::IsParent(view2, view1)) - return kAView2IsParent; - - //TODO: check if I can use [view1 ancestorSharedWithView : view2]; - return Detail::FindLowestCommonAncestor(view1, fBranch1, view2, fBranch2, lca); -} - -//______________________________________________________________________________ -void EventTranslator::SortTopLevelWindows() -{ - const ROOT::MacOSX::Util::AutoreleasePool pool; - - fWindowStack.clear(); - - NSArray *orderedWindows = [NSApp orderedWindows]; - for (NSWindow *window in orderedWindows) { - if (![window isKindOfClass : [QuartzWindow class]]) - continue; - QuartzWindow *qw = (QuartzWindow *)window; - if (qw.fMapState == kIsViewable) - fWindowStack.push_back((QuartzWindow *)window); - } -} - -//______________________________________________________________________________ -QuartzWindow *EventTranslator::FindTopLevelWindowForMouseEvent() -{ - if (!fWindowStack.size()) - return nil; - - std::vector::iterator iter = fWindowStack.begin(), endIt = fWindowStack.end(); - for (; iter != endIt; ++iter) { - QuartzWindow *topLevel = *iter; - const NSPoint mousePosition = [topLevel mouseLocationOutsideOfEventStream]; - const NSSize windowSize = topLevel.frame.size; - if (mousePosition.x >= 0 && mousePosition.x <= windowSize.width && - mousePosition.y >= 0 && mousePosition.y <= windowSize.height) - return topLevel; - } - - return nil; -} - }//X11 }//MacOSX }//ROOT diff --git a/graf2d/cocoa/src/XLFDParser.mm b/graf2d/cocoa/src/XLFDParser.mm index 7e8f9bfe8a9c4..ed0437938e966 100644 --- a/graf2d/cocoa/src/XLFDParser.mm +++ b/graf2d/cocoa/src/XLFDParser.mm @@ -122,7 +122,13 @@ size_type ParseWeight(const std::string &name, size_type pos, XLFDName &dst) //and integer. std::string weight; pos = GetXLFDNameComponentAsString(name, "weight", pos, weight); - weight == "bold" ? dst.fWeight = kFWBold : dst.fWeight = kFWMedium; + + if (weight == "*") + dst.fWeight = kFWAny; + else if (weight == "bold") + dst.fWeight = kFWBold; + else + dst.fWeight = kFWMedium; return pos; } @@ -135,11 +141,13 @@ size_type ParseSlant(const std::string &name, size_type pos, XLFDName &dst) std::string slant; pos = GetXLFDNameComponentAsString(name, "slant", pos, slant); - //Can be 'r', 'R', 'i', 'I', 'o', 'O', and now I add also '*' - let it be regular. - dst.fSlant = kFSRegular; - - if (slant == "i" || slant == "I" || slant == "o" || slant == "O") + //Can be 'r', 'R', 'i', 'I', 'o', 'O', '*'. + if (slant == "*") + dst.fSlant = kFSAny; + else if (slant == "i" || slant == "I" || slant == "o" || slant == "O") dst.fSlant = kFSItalic; + else + dst.fSlant = kFSRegular; return pos; } @@ -174,8 +182,11 @@ size_type ParsePixelSize(const std::string &name, size_type pos, XLFDName &dst) return endOfSize; } + const size_type pos1 = GetXLFDNameComponentAsInteger(name, "pixel size", pos, dst.fPixelSize); + if (dst.fPixelSize < 12) + dst.fPixelSize = 12; //Real size in pixel? - return GetXLFDNameComponentAsInteger(name, "pixel size", pos, dst.fPixelSize); + return pos1;//GetXLFDNameComponentAsInteger(name, "pixel size", pos, dst.fPixelSize); } //______________________________________________________________________________ @@ -238,6 +249,14 @@ size_type ParseEncoding(const std::string &name, size_type pos, XLFDName &dst) }//Anonymous namespace. +//______________________________________________________________________________ +XLFDName::XLFDName() + : fWeight(kFWAny), + fSlant(kFSAny), + fPixelSize(0) +{ +} + //______________________________________________________________________________ bool ParseXLFDName(const std::string &xlfdName, XLFDName &dst) { @@ -253,8 +272,8 @@ bool ParseXLFDName(const std::string &xlfdName, XLFDName &dst) try { if (xlfdName == "fixed" || xlfdName == "*") { //Is this correct XLFD name???? Who knows. Replace it. - dst.fFamilyName = "Courier"; - dst.fPixelSize = 11; + dst.fFamilyName = "Lucida Grande"; + dst.fPixelSize = 12; } else { size_type pos = ParseFoundry(xlfdName, 0, dst); if (pos + 1 < nameLength) diff --git a/graf2d/doc/v520/index.html b/graf2d/doc/v520/index.html index fc9d99caa52c1..f39e92149a692 100644 --- a/graf2d/doc/v520/index.html +++ b/graf2d/doc/v520/index.html @@ -15,7 +15,7 @@

TASImage

mode were wrong.
  • In FillRectangleInternal when the rectangle to be drawn had its width or its height equal to 0, they were set to the current image width or height. - This was not a good solution because this obscured completly the picture. + This was not a good solution because this obscured completely the picture. In particular, some markers being drawn with a filled rectangle, they obscured the picture when they were really small because in that case the rectangle drawn had width=height=0. Now, when a rectangle has its width or diff --git a/graf2d/doc/v534/index.html b/graf2d/doc/v534/index.html index 3263103ce3911..02e3e75e97b04 100644 --- a/graf2d/doc/v534/index.html +++ b/graf2d/doc/v534/index.html @@ -89,6 +89,17 @@

    TPad

    graphics window in interactive mode is kept for OpenGL canvases.
  • + +

    TGaxis and TAxis

    +
      +
    • The time axis behavior should now be correct along time zone and summer + saving time. A fix has been done with the of Philippe Gras (CEA Saclay. + IRFU/SEDI) and Julian Sitarek (IFAE). Time axis transported from a time + zone to an other in a ROOT file are correct too. A new example test have + been introduced to test the time axis (timeonaxis3.C) +
    • +
    +

    New graphical back-end for MacOSX

    TGCocoa/TGQuartz classes are the implementation of TVirtualX based on Cocoa and Quartz 2D. diff --git a/graf2d/fitsio/inc/TFITS.h b/graf2d/fitsio/inc/TFITS.h index d5420444bfd26..095cfac622ac3 100644 --- a/graf2d/fitsio/inc/TFITS.h +++ b/graf2d/fitsio/inc/TFITS.h @@ -84,8 +84,6 @@ class TFITSHDU : public TNamed { Int_t fNumber; // HDU number (1=PRIMARY) TArrayI *fSizes; // Image sizes in each dimension (when fType == kImageHDU) TArrayD *fPixels; // Image pixels (when fType == kImageHDU) - TString *fColumnNames; // Array of column names following the order within the FITS file (when fType == kTableHDU) - enum EColumnTypes *fColumnTypes; // Array of column types following the order within the FITS file (when fType == kTableHDU) struct Column *fColumnsInfo; // Information about columns (when fType == kTableHDU) Int_t fNColumns; // Number of columns (when fType == kTableHDU) Int_t fNRows; // Number of rows (when fType == kTableHDU) @@ -126,6 +124,7 @@ class TFITSHDU : public TNamed { Int_t GetTabNColumns() const { return fNColumns; } Int_t GetTabNRows() const { return fNRows; } Int_t GetColumnNumber(const char *colname); + const TString& GetColumnName(Int_t colnum); TObjArray *GetTabStringColumn(Int_t colnum); TObjArray *GetTabStringColumn(const char *colname); TVectorD *GetTabRealVectorColumn(Int_t colnum); diff --git a/graf2d/fitsio/src/TFITS.cxx b/graf2d/fitsio/src/TFITS.cxx index b528eaba4242e..100f243fb3031 100644 --- a/graf2d/fitsio/src/TFITS.cxx +++ b/graf2d/fitsio/src/TFITS.cxx @@ -354,7 +354,7 @@ Bool_t TFITSHDU::LoadHDU(TString& filepath_filter) // Allocate column info array fColumnsInfo = new struct Column[table_cols]; - // Retrieve column names and place them into fColumnNames + // Read column names char colname[80]; int colnum; @@ -375,7 +375,6 @@ Bool_t TFITSHDU::LoadHDU(TString& filepath_filter) long repeat, width; Int_t cellindex; - fColumnTypes = new enum EColumnTypes [table_cols]; for (colnum = 0, cellindex = 0; colnum < fNColumns; colnum++) { fits_get_coltype(fp, colnum+1, &typecode, &repeat, &width, &status); @@ -1412,6 +1411,21 @@ TVectorD *TFITSHDU::GetTabRealVectorCell(Int_t rownum, const char *colname) } +//______________________________________________________________________________ +const TString& TFITSHDU::GetColumnName(Int_t colnum) +{ + // Get the name of a column given its index (column>=0). + // In case of error the column name is "". - - + static TString noName; + if (fType != kTableHDU) { + Error("GetColumnName", "this is not a table HDU."); + return noName; + } + + if ((colnum < 0) || (colnum >= fNColumns)) { + Error("GetColumnName", "column index out of bounds."); + return noName; + } + return fColumnsInfo[colnum].fName; +} diff --git a/graf2d/freetype/CMakeLists.txt b/graf2d/freetype/CMakeLists.txt index 28ebd2f0cc237..45b8e113c2365 100644 --- a/graf2d/freetype/CMakeLists.txt +++ b/graf2d/freetype/CMakeLists.txt @@ -34,7 +34,7 @@ if(WIN32) COMMAND cmake -E copy win/freetype.mak ${FREETYPE_VERSION}/builds/win32/visualc COMMAND cmake -E copy win/freetype.dep ${FREETYPE_VERSION}/builds/win32/visualc COMMAND cmake -E chdir ${FREETYPE_VERSION}/builds/win32/visualc - nmake -nologo -f freetype.mak CFG=${freetypebuild} NMAKECXXFLAGS="-D_CRT_SECURE_NO_DEPRECATE" ) + nmake -nologo -f freetype.mak CFG=${freetypebuild} NMAKECXXFLAGS="${BLDCXXFLAGS} -D_CRT_SECURE_NO_DEPRECATE" ) else() set(freetypelib ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/libfreetype.a) set(freetypeliba ${CMAKE_CURRENT_BINARY_DIR}/${FREETYPE_VERSION}/objs/.libs/libfreetype.a) @@ -110,4 +110,4 @@ endif() # build directory. add_custom_target(FREETYPE DEPENDS ${freetypelib}) set_target_properties(FREETYPE PROPERTIES FOLDER Builtins) -install(FILES ${freetypelib} DESTINATION lib) +install(FILES ${freetypelib} DESTINATION ${CMAKE_INSTALL_LIBDIR}) diff --git a/graf2d/freetype/Module.mk b/graf2d/freetype/Module.mk index db5ce526dd4ab..eece696bc1b7c 100644 --- a/graf2d/freetype/Module.mk +++ b/graf2d/freetype/Module.mk @@ -44,8 +44,12 @@ endif else FREETYPELIBA := $(call stripsrc,$(MODDIRS)/$(FREETYPEVERS)/objs/.libs/libfreetype.a) FREETYPELIBB := $(LPATH)/libfreetype.a +ifeq ($(PLATFORM),linux-k1om) +FREETYPELIB := $(FREETYPELIBB) +else FREETYPELIB := $(FREETYPELIBB) -lz endif +endif FREETYPEINC := $(FREETYPEDIRI:%=-I%) FREETYPEDEP := $(FREETYPELIBB) @@ -116,6 +120,11 @@ else FREECC="$$FREECC -m64"; \ FREE_CFLAGS="-m64"; \ fi; \ + if [ $(ARCH) = "linuxx8664k1omicc" ]; then \ + FREECC="$$FREECC -m64 $(MICFLAGS)"; \ + FREE_CFLAGS="-m64 $(MICFLAGS)"; \ + FREE_HOST="--host=x86_64-unknown-linux-gnu"; \ + fi; \ if [ $(ARCH) = "macosx" ]; then \ FREECC="$$FREECC -m32"; \ FREE_CFLAGS="-m32"; \ @@ -125,12 +134,10 @@ else FREE_CFLAGS="-m64"; \ fi; \ if [ $(ARCH) = "iossim" ]; then \ - FREECC="$$FREECC -arch i386"; \ FREE_CFLAGS="-arch i386 -isysroot $(IOSSDK) -miphoneos-version-min=$(IOSVERS)"; \ FREE_HOST="--host=i686-apple-darwin10"; \ fi; \ if [ $(ARCH) = "ios" ]; then \ - FREECC="$$FREECC -arch armv7"; \ FREE_CFLAGS="-arch armv7 -isysroot $(IOSSDK) -miphoneos-version-min=$(IOSVERS)"; \ FREE_HOST="--host=arm-apple-darwin10"; \ fi; \ diff --git a/graf2d/gpad/inc/TPad.h b/graf2d/gpad/inc/TPad.h index d288550f97b86..0a9e8c55b8daa 100644 --- a/graf2d/gpad/inc/TPad.h +++ b/graf2d/gpad/inc/TPad.h @@ -127,7 +127,7 @@ class TPad : public TVirtualPad { void PaintBorder(Color_t color, Bool_t tops); virtual void PaintBorderPS(Double_t xl,Double_t yl,Double_t xt,Double_t yt,Int_t bmode,Int_t bsize,Int_t dark,Int_t light); void PaintDate(); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); virtual void SetBatch(Bool_t batch=kTRUE); private: @@ -284,7 +284,9 @@ class TPad : public TVirtualPad { void PaintPolyMarker(Int_t n, Double_t *x, Double_t *y, Option_t *option=""); virtual void PaintModified(); void PaintText(Double_t x, Double_t y, const char *text); + void PaintText(Double_t x, Double_t y, const wchar_t *text); void PaintTextNDC(Double_t u, Double_t v, const char *text); + void PaintTextNDC(Double_t u, Double_t v, const wchar_t *text); virtual TPad *Pick(Int_t px, Int_t py, TObjLink *&pickobj); Double_t PixeltoX(Int_t px); Double_t PixeltoY(Int_t py); diff --git a/graf2d/gpad/inc/TPadPainter.h b/graf2d/gpad/inc/TPadPainter.h index 5b45800f022fc..d2b98651f39d5 100644 --- a/graf2d/gpad/inc/TPadPainter.h +++ b/graf2d/gpad/inc/TPadPainter.h @@ -74,7 +74,9 @@ class TPadPainter : public TVirtualPadPainter { void DrawPolyMarker(Int_t n, const Float_t *x, const Float_t *y); void DrawText(Double_t x, Double_t y, const char *text, ETextMode mode); + void DrawText(Double_t x, Double_t y, const wchar_t *text, ETextMode mode); void DrawTextNDC(Double_t u, Double_t v, const char *text, ETextMode mode); + void DrawTextNDC(Double_t u, Double_t v, const wchar_t *text, ETextMode mode); //jpg, png, bmp, gif output. void SaveImage(TVirtualPad *pad, const char *fileName, Int_t type) const; diff --git a/graf2d/gpad/src/TCanvas.cxx b/graf2d/gpad/src/TCanvas.cxx index 338e9dee193e8..da4111a0981a5 100644 --- a/graf2d/gpad/src/TCanvas.cxx +++ b/graf2d/gpad/src/TCanvas.cxx @@ -111,9 +111,10 @@ of the canvas. It gives a short explanation about the canvas' menus.

    A canvas may be automatically divided into pads via TPad::Divide.

    -At creation time, the canvas size defines the size of the canvas window -(including the window manager's decoration). To define precisely the graphics -area size of a canvas, the following four lines of code should be used: +At creation time, in interactive mode, the canvas size defines the size of the +canvas window (including the window manager's decoration). To define precisely +the graphics area size of a canvas, the following four lines of code should be +used:

        {
           Double_t w = 600;
    @@ -122,6 +123,10 @@ area size of a canvas, the following four lines of code should be used:
           c->SetWindowSize(w + (w - c->GetWw()), h + (h - c->GetWh()));
        }
     
    +in batch mode simply do: +
    +      c->SetCanvasSize(w,h);
    +
    End_Html */ @@ -813,6 +818,20 @@ void TCanvas::Draw(Option_t *) fCanvasImp = gGuiFactory->CreateCanvasImp(this, GetName(), fWindowTopX, fWindowTopY, fWindowWidth, fWindowHeight); if (!fCanvasImp) return; + //This new canvas imp can support OpenGL. + if (fGLDevice != -1) { + TIter next(GetListOfPrimitives()); + while (TObject * const obj = next()) { + if (obj->InheritsFrom(TPad::Class())) { + //I do not think we can have TCanvas inside TCanvas, + //so it's a pad. + //TODO: check the logic, what if we had + //canvas imp/gl device before? Mess. + ((TPad *)obj)->SetGLDevice(fGLDevice); + } + } + } + // fCanvasImp->ShowMenuBar(TestBit(kMenuBar)); } Build(); diff --git a/graf2d/gpad/src/TCreatePrimitives.cxx b/graf2d/gpad/src/TCreatePrimitives.cxx index c269ff99fd707..cff18178ef85c 100644 --- a/graf2d/gpad/src/TCreatePrimitives.cxx +++ b/graf2d/gpad/src/TCreatePrimitives.cxx @@ -36,6 +36,7 @@ #include "TROOT.h" #include "TSystem.h" #include "TMath.h" +#include "KeySymbols.h" //______________________________________________________________________________ TCreatePrimitives::TCreatePrimitives() @@ -304,18 +305,47 @@ void TCreatePrimitives::Pave(Int_t event, Int_t px, Int_t py, Int_t mode) static Int_t pxold, pyold; static Int_t px0, py0; static Int_t linedrawn; - const Int_t kTMAX=100; - Int_t i,pxl,pyl; Double_t temp; Double_t xp0,xp1,yp0,yp1; - static char atext[kTMAX]; - TObject *pave = 0; + static TObject *pave = 0; if (mode == kPaveLabel) ((TPad *)gPad)->EventPave(); switch (event) { + case kKeyPress: + if (mode == kPaveLabel) { + if ((py == kKey_Return) || (py == kKey_Enter)) { + TString s(pave->GetTitle()); + Int_t l = s.Length(); + s.Remove(l-1); + ((TPaveLabel*)pave)->SetLabel(s.Data()); + gSystem->ProcessEvents(); + gPad->Modified(kTRUE); + gROOT->SetEditorMode(); + gPad->Update(); + pave = 0; + } else if (py == kKey_Backspace) { + TString s(pave->GetTitle()); + Int_t l = s.Length(); + if (l>1) { + s.Replace(l-2, 2, "<"); + ((TPaveLabel*)pave)->SetLabel(s.Data()); + gPad->Modified(kTRUE); + gPad->Update(); + } + } else if (isprint(py)) { + TString s(pave->GetTitle()); + Int_t l = s.Length(); + s.Insert(l-1,(char)py); + ((TPaveLabel*)pave)->SetLabel(s.Data()); + gPad->Modified(kTRUE); + gPad->Update(); + } + } + break; + case kButton1Down: gVirtualX->SetLineColor(-1); x0 = gPad->AbsPixeltoX(px); @@ -349,31 +379,16 @@ void TCreatePrimitives::Pave(Int_t event, Int_t px, Int_t py, Int_t mode) if (mode == kPaveText ) pave = new TPaveText(xp0,yp0,xp1,yp1); if (mode == kPavesText) pave = new TPavesText(xp0,yp0,xp1,yp1); if (mode == kDiamond) pave = new TDiamond(x0,y0,x1,y1); - if (mode == kPaveLabel || mode == kButton) { + if (mode == kPaveLabel) { ((TPad *)gPad)->StartEditing(); gSystem->ProcessEvents(); - pxl = (px0 + px)/2; - pyl = (py0 + py)/2; - for (i=0;iRequestString(pxl, pyl, atext); - for (i=kTMAX-2;i>=0;i--) { - if ((i==0) || (atext[i] != ' ')) { - atext[i+1] = 0; - break; - } - } - if (mode == kPaveLabel) { - pave = new TPaveLabel(xp0,yp0,xp1,yp1,atext); - gSystem->ProcessEvents(); - ((TPad *)gPad)->RecordPave(pave); + if (mode == kPaveLabel) { + pave = new TPaveLabel(xp0,yp0,xp1,yp1,"<"); + pave->Draw(); + gPad->Modified(kTRUE); + gPad->Update(); + break; } - if (mode == kButton) pave = new TButton(atext,"", - (x0-gPad->GetX1())/(gPad->GetX2() - gPad->GetX1()), - (y0-gPad->GetY1())/(gPad->GetY2() - gPad->GetY1()), - (x1-gPad->GetX1())/(gPad->GetX2() - gPad->GetX1()), - (y1-gPad->GetY1())/(gPad->GetY2() - - gPad->GetY1())); } TCanvas *canvas = gPad->GetCanvas(); if (canvas) canvas->FeedbackMode(kFALSE); @@ -490,54 +505,70 @@ void TCreatePrimitives::Text(Int_t event, Int_t px, Int_t py, Int_t mode) // Click left button to indicate the text position // - const Int_t kTMAX=100; - static char atext[kTMAX]; - Int_t i, lentext; - TLatex *newtext; - TMarker *marker; - Double_t x, y; - TCanvas *canvas = gPad->GetCanvas(); + static TLatex *text = 0; + static Double_t x, y; switch (event) { + case kKeyPress: + if ((py == kKey_Return) || (py == kKey_Enter)) { + TString s(text->GetTitle()); + Int_t l = s.Length(); + s.Remove(l-1); + text->SetText(x,y,s.Data()); + gSystem->ProcessEvents(); + gPad->Modified(kTRUE); + gROOT->SetEditorMode(); + gPad->Update(); + text = 0; + } else if (py == kKey_Backspace) { + TString s(text->GetTitle()); + Int_t l = s.Length(); + if (l>1) { + s.Replace(l-2, 2, "<"); + text->SetText(x,y,s.Data()); + gPad->Modified(kTRUE); + gPad->Update(); + } + } else if (isprint(py)) { + TString s(text->GetTitle()); + Int_t l = s.Length(); + s.Insert(l-1,(char)py); + text->SetText(x,y,s.Data()); + gPad->Modified(kTRUE); + gPad->Update(); + } + break; + case kButton1Down: + if (text) { + TString s(text->GetTitle()); + Int_t l = s.Length(); + s.Remove(l-1); + text->SetText(x,y,s.Data()); + } + x = gPad->AbsPixeltoX(px); y = gPad->AbsPixeltoY(py); if (gPad->GetLogx()) x = TMath::Power(10,x); if (gPad->GetLogy()) y = TMath::Power(10,y); + if (mode == kMarker) { + TMarker *marker; marker = new TMarker(x,y,gStyle->GetMarkerStyle()); marker->Draw(); - if (canvas) canvas->Selected((TPad*)gPad, marker, event); gROOT->SetEditorMode(); break; } + ((TPad *)gPad)->StartEditing(); gSystem->ProcessEvents(); - for (i=0;iSetLineColor(-1); - newtext->TAttText::Modify(); - gVirtualX->RequestString(px, py, atext); - lentext = strlen(atext); - for (i=lentext-1;i>=0;i--) { - if (atext[i] != ' ') { - atext[lentext] = 0; - break; - } - lentext--; - } - if (!lentext) break; - TLatex copytext(x, y, atext); - gSystem->ProcessEvents(); - ((TPad *)gPad)->RecordLatex(©text); - newtext->DrawLatex(x, y, atext); + + text = new TLatex(x,y,"<"); + text->Draw(); gPad->Modified(kTRUE); - if (canvas) canvas->Selected((TPad*)gPad, newtext, event); - gROOT->SetEditorMode(); gPad->Update(); + break; } -} +} \ No newline at end of file diff --git a/graf2d/gpad/src/TPad.cxx b/graf2d/gpad/src/TPad.cxx index 0cf5bc721cd37..f00ef44293f73 100644 --- a/graf2d/gpad/src/TPad.cxx +++ b/graf2d/gpad/src/TPad.cxx @@ -396,14 +396,15 @@ TLegend *TPad::BuildLegend(Double_t x1, Double_t y1, Double_t x2, Double_t y2, { // Build a legend from the graphical objects in the pad // - // A simple method to to build automatically a TLegend from the primitives in - // a TPad. Only those deriving from TAttLine, TAttMarker and TAttFill are - // added, excluding TPave and TFrame derived classes. - // x1, y1, x2, y2 are the Tlegend coordinates. - // title is the legend title. By default it is " ". + // A simple method to to build automatically a TLegend from the + // primitives in a TPad. Only those deriving from TAttLine, + // TAttMarker and TAttFill are added, excluding TPave and TFrame + // derived classes. x1, y1, x2, y2 are the TLegend coordinates. + // title is the legend title. By default it is " ". The caller + // program owns the returned TLegend. // - // If the pad contains some TMultiGraph or THStack the individual graphs or - // histograms in them are added to the TLegend. + // If the pad contains some TMultiGraph or THStack the individual + // graphs or histograms in them are added to the TLegend. TList *lop=GetListOfPrimitives(); if (!lop) return 0; @@ -1492,7 +1493,7 @@ TH1F *TPad::DrawFrame(Double_t xmin, Double_t ymin, Double_t xmax, Double_t ymax if (!IsEditable()) return 0; TPad *padsav = (TPad*)gPad; if (this != padsav) { - Warning("DrawFrame","Drawframe must be called for the current pad only"); + Warning("DrawFrame","Must be called for the current pad only"); return padsav->DrawFrame(xmin,ymin,xmax,ymax,title); } @@ -2777,8 +2778,8 @@ void TPad::ls(Option_t *option) const // List all primitives in pad. TROOT::IndentLevel(); - cout <GetName()<<" fXlowNDC=" <GetListOfSpecials()->FindObject(psname); + + Bool_t noScreen = kFALSE; + if (!GetCanvas()->IsBatch() && GetCanvas()->GetCanvasID() == -1) { + noScreen = kTRUE; + GetCanvas()->SetBatch(kTRUE); + } + + TPad *padsav = (TPad*)gPad; + cd(); + TVirtualPS *psave = gVirtualPS; + + if (!gVirtualPS) { + // Plugin Postscript/SVG driver + TPluginHandler *h; + if ((h = gROOT->GetPluginManager()->FindHandler("TVirtualPS", "tex"))) { + if (h->LoadPlugin() == -1) + return; + h->ExecPlugin(0); + } + } + + // Create a new SVG file + gVirtualPS->SetName(psname); + gVirtualPS->Open(psname); + gVirtualPS->SetBit(kPrintingPS); + gVirtualPS->NewPage(); + Paint(); + + if (noScreen) GetCanvas()->SetBatch(kFALSE); + + if (!gSystem->AccessPathName(psname)) Info("Print", "TeX file %s has been created", psname.Data()); + + delete gVirtualPS; + gVirtualPS = psave; + gVirtualPS = 0; + padsav->cd(); + + return; + } + //==============Save pad/canvas as a Postscript file========================= // in case we read directly from a Root file and the canvas @@ -4431,13 +4512,13 @@ void TPad::Print(const char *filenam, Option_t *option) char *l; Bool_t mustOpen = kTRUE; Bool_t mustClose = kTRUE; - char *copen=0, *cclose=0, *copenb=0, *ccloseb=0; + Bool_t copen=kFALSE, cclose=kFALSE, copenb=kFALSE, ccloseb=kFALSE; if (!image) { // The parenthesis mechanism is only valid for PS and PDF files. - copen = (char*)strstr(psname.Data(),"("); if (copen) *copen = 0; - cclose = (char*)strstr(psname.Data(),")"); if (cclose) *cclose = 0; - copenb = (char*)strstr(psname.Data(),"["); if (copenb) *copenb = 0; - ccloseb = (char*)strstr(psname.Data(),"]"); if (ccloseb) *ccloseb = 0; + copen = psname.EndsWith("("); if (copen) psname[psname.Length()-1] = 0; + cclose = psname.EndsWith(")"); if (cclose) psname[psname.Length()-1] = 0; + copenb = psname.EndsWith("["); if (copenb) psname[psname.Length()-1] = 0; + ccloseb = psname.EndsWith("]"); if (ccloseb) psname[psname.Length()-1] = 0; } gVirtualPS = (TVirtualPS*)gROOT->GetListOfSpecials()->FindObject(psname); if (gVirtualPS) {mustOpen = kFALSE; mustClose = kFALSE;} @@ -4497,7 +4578,6 @@ void TPad::Print(const char *filenam, Option_t *option) Paint(); } if (noScreen) GetCanvas()->SetBatch(kFALSE); - if (!gSystem->AccessPathName(psname)) Info("Print", "%s file %s has been created", opt, psname.Data()); if (mustClose) { gROOT->GetListOfSpecials()->Remove(gVirtualPS); @@ -4507,6 +4587,8 @@ void TPad::Print(const char *filenam, Option_t *option) gROOT->GetListOfSpecials()->Add(gVirtualPS); gVirtualPS = 0; } + + if (!gSystem->AccessPathName(psname)) Info("Print", "%s file %s has been created", opt, psname.Data()); } else { // Append to existing Postscript, PDF or GIF file if (!ccloseb) { @@ -4888,6 +4970,7 @@ void TPad::SaveAs(const char *filename, Option_t * /*option*/) const // if filename contains .eps, an Encapsulated Postscript file is produced // if filename contains .pdf, a PDF file is produced // if filename contains .svg, a SVG file is produced + // if filename contains .tex, a TeX file is produced // if filename contains .gif, a GIF file is produced // if filename contains .gif+NN, an animated GIF file is produced // if filename contains .xpm, a XPM file is produced @@ -4939,6 +5022,8 @@ void TPad::SaveAs(const char *filename, Option_t * /*option*/) const ((TPad*)this)->Print(psname,"pdf"); else if (psname.EndsWith(".svg")) ((TPad*)this)->Print(psname,"svg"); + else if (psname.EndsWith(".tex")) + ((TPad*)this)->Print(psname,"tex"); else if (psname.EndsWith(".xpm")) ((TPad*)this)->Print(psname,"xpm"); else if (psname.EndsWith(".png")) @@ -4957,7 +5042,7 @@ void TPad::SaveAs(const char *filename, Option_t * /*option*/) const //______________________________________________________________________________ -void TPad::SavePrimitive(ostream &out, Option_t * /*= ""*/) +void TPad::SavePrimitive(std::ostream &out, Option_t * /*= ""*/) { // Save primitives in this pad on the C++ source file out. @@ -4979,8 +5064,8 @@ void TPad::SavePrimitive(ostream &out, Option_t * /*= ""*/) // Write pad parameters if (this != gPad->GetCanvas()) { - out <<" "<Primitives in pad: "<Primitives in pad: "<ClassSaved(TPad::Class())) { out<<" "; @@ -4993,103 +5078,103 @@ void TPad::SavePrimitive(ostream &out, Option_t * /*= ""*/) <<","<Draw();"<cd();"<Draw();"<cd();"<Range("<Range("<GetRange(rmin, rmax); - out<<" TView *view = TView::CreateView(1);"<SetRange("< 228) { TColor::SaveColor(out, GetFillColor()); - out<<" "<SetFillColor(ci);" << endl; + out<<" "<SetFillColor(ci);" << std::endl; } else - out<<" "<SetFillColor("<SetFillColor("<SetFillStyle("<SetFillStyle("<SetBorderMode("<SetBorderMode("<SetBorderSize("<SetBorderSize("<SetLogx();"<SetLogx();"<SetLogy();"<SetLogy();"<SetLogz();"<SetLogz();"<SetGridx();"<SetGridx();"<SetGridy();"<SetGridy();"<SetTickx("<SetTickx("<SetTicky("<SetTicky("<SetTheta("<SetTheta("<SetPhi("<SetPhi("< 0.01) { - out<<" "<SetLeftMargin("<SetLeftMargin("< 0.01) { - out<<" "<SetRightMargin("<SetRightMargin("< 0.01) { - out<<" "<SetTopMargin("<SetTopMargin("< 0.01) { - out<<" "<SetBottomMargin("<SetBottomMargin("< 228) { TColor::SaveColor(out, GetFrameFillColor()); - out<<" "<SetFrameFillColor(ci);" << endl; + out<<" "<SetFrameFillColor(ci);" << std::endl; } else - out<<" "<SetFrameFillColor("<SetFrameFillColor("<SetFrameFillStyle("<SetFrameFillStyle("<SetFrameLineStyle("<SetFrameLineStyle("< 228) { TColor::SaveColor(out, GetFrameLineColor()); - out<<" "<SetFrameLineColor(ci);" << endl; + out<<" "<SetFrameLineColor(ci);" << std::endl; } else - out<<" "<SetFrameLineColor("<SetFrameLineColor("<SetFrameLineWidth("<SetFrameLineWidth("<SetFrameBorderMode("<SetFrameBorderMode("<SetFrameBorderSize("<SetFrameBorderSize("<GetFillColor() != GetFillColor()) { if (frame->GetFillColor() > 228) { TColor::SaveColor(out, frame->GetFillColor()); - out<<" "<SetFrameFillColor(ci);" << endl; + out<<" "<SetFrameFillColor(ci);" << std::endl; } else - out<<" "<SetFrameFillColor("<GetFillColor()<<");"<SetFrameFillColor("<GetFillColor()<<");"<GetFillStyle() != 1001) { - out<<" "<SetFrameFillStyle("<GetFillStyle()<<");"<SetFrameFillStyle("<GetFillStyle()<<");"<GetLineStyle() != 1) { - out<<" "<SetFrameLineStyle("<GetLineStyle()<<");"<SetFrameLineStyle("<GetLineStyle()<<");"<GetLineColor() != 1) { if (frame->GetLineColor() > 228) { TColor::SaveColor(out, frame->GetLineColor()); - out<<" "<SetFrameLineColor(ci);" << endl; + out<<" "<SetFrameLineColor(ci);" << std::endl; } else - out<<" "<SetFrameLineColor("<GetLineColor()<<");"<SetFrameLineColor("<GetLineColor()<<");"<GetLineWidth() != 1) { - out<<" "<SetFrameLineWidth("<GetLineWidth()<<");"<SetFrameLineWidth("<GetLineWidth()<<");"<GetBorderMode() != 1) { - out<<" "<SetFrameBorderMode("<GetBorderMode()<<");"<SetFrameBorderMode("<GetBorderMode()<<");"<GetBorderSize() != 1) { - out<<" "<SetFrameBorderSize("<GetBorderSize()<<");"<SetFrameBorderSize("<GetBorderSize()<<");"<SavePrimitive(out, (Option_t *)next.GetOption()); - out<<" "<Modified();"<GetName()<<"->cd();"<InheritsFrom(TGraph::Class())) + if (!strcmp(obj->GetName(),"Graph")) ((TGraph*)obj)->SetName(Form("Graph%d",grnum++)); + obj->SavePrimitive(out, (Option_t *)next.GetOption()); + } + out<<" "<Modified();"<GetName()<<"->cd();"<cd(); } diff --git a/graf2d/gpad/src/TPadPainter.cxx b/graf2d/gpad/src/TPadPainter.cxx index 870f5549c94c9..cf40e21dfa962 100644 --- a/graf2d/gpad/src/TPadPainter.cxx +++ b/graf2d/gpad/src/TPadPainter.cxx @@ -474,6 +474,19 @@ void TPadPainter::DrawText(Double_t x, Double_t y, const char *text, ETextMode m } +//______________________________________________________________________________ +void TPadPainter::DrawText(Double_t x, Double_t y, const wchar_t *text, ETextMode mode) +{ + // Paint text. + + Int_t px = gPad->XtoPixel(x); + Int_t py = gPad->YtoPixel(y); + Double_t angle = GetTextAngle(); + Double_t mgn = GetTextMagnitude(); + gVirtualX->DrawText(px, py, angle, mgn, text, (TVirtualX::ETextMode)mode); +} + + //______________________________________________________________________________ void TPadPainter::DrawTextNDC(Double_t u, Double_t v, const char *text, ETextMode mode) { @@ -504,3 +517,16 @@ void TPadPainter::SaveImage(TVirtualPad *pad, const char *fileName, Int_t type) } } } + + +//______________________________________________________________________________ +void TPadPainter::DrawTextNDC(Double_t u, Double_t v, const wchar_t *text, ETextMode mode) +{ + // Paint text in normalized coordinates. + + Int_t px = gPad->UtoPixel(u); + Int_t py = gPad->VtoPixel(v); + Double_t angle = GetTextAngle(); + Double_t mgn = GetTextMagnitude(); + gVirtualX->DrawText(px, py, angle, mgn, text, (TVirtualX::ETextMode)mode); +} diff --git a/graf2d/graf/CMakeLists.txt b/graf2d/graf/CMakeLists.txt index 310e37d0cc473..1224f4487c5a0 100644 --- a/graf2d/graf/CMakeLists.txt +++ b/graf2d/graf/CMakeLists.txt @@ -8,14 +8,15 @@ set(libname Graf) ROOT_USE_PACKAGE(core) ROOT_USE_PACKAGE(math/matrix) ROOT_USE_PACKAGE(io/io) -include_directories(${CMAKE_SOURCE_DIR}/hist/hist/inc) # This is to avoid a circular dependency graf <--> hist +ROOT_USE_PACKAGE(graf2d/mathtext) +include_directories(${CMAKE_SOURCE_DIR}/hist/hist/inc) # This is to avoid a circular dependency graf <--> hist ROOT_GENERATE_DICTIONARY(G__${libname} *.h LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(${libname} LINKDEF LinkDef.h DEPENDENCIES Hist Matrix MathCore RIO) include_directories(${FREETYPE_INCLUDE_DIRS}) -ROOT_LINKER_LIBRARY(${libname} *.cxx G__${libname}.cxx LIBRARIES ${FREETYPE_LIBRARIES} DEPENDENCIES Hist Matrix MathCore RIO) +ROOT_LINKER_LIBRARY(${libname} *.cxx G__${libname}.cxx LIBRARIES ${FREETYPE_LIBRARIES} ${ZLIB_LIBRARY} mathtext DEPENDENCIES Hist Matrix MathCore RIO) if(builtin_freetype) add_dependencies(${libname} FREETYPE) diff --git a/graf2d/graf/Module.mk b/graf2d/graf/Module.mk index e703f9e6f94cf..32668c830177b 100644 --- a/graf2d/graf/Module.mk +++ b/graf2d/graf/Module.mk @@ -41,11 +41,12 @@ INCLUDEFILES += $(GRAFDEP) include/%.h: $(GRAFDIRI)/%.h cp $< $@ -$(GRAFLIB): $(GRAFO) $(GRAFDO) $(FREETYPEDEP) $(ORDER_) $(MAINLIBS) $(GRAFLIBDEP) +$(GRAFLIB): $(GRAFO) $(GRAFDO) $(MATHTEXTLIBDEP) $(FREETYPEDEP) $(ORDER_) \ + $(MAINLIBS) $(GRAFLIBDEP) @$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \ "$(SOFLAGS)" libGraf.$(SOEXT) $@ \ "$(GRAFO) $(GRAFDO)" \ - "$(FREETYPELDFLAGS) $(FREETYPELIB) $(GRAFLIBEXTRA)" + "$(GRAFLIBEXTRA) $(MATHTEXTLIB) $(FREETYPELDFLAGS) $(FREETYPELIB)" $(GRAFDS): $(GRAFH) $(GRAFL) $(ROOTCINTTMPDEP) $(MAKEDIR) @@ -74,9 +75,9 @@ $(GRAFDO): OPT = $(NOOPT) $(GRAFDO): CXXFLAGS += $(FREETYPEINC) $(GRAFDS): CINTFLAGS += $(FREETYPEINC) -$(call stripsrc,$(GRAFDIRS)/TTF.o $(GRAFDIRS)/TText.o $(GRAFDIRS)/TLatex.o): \ +$(call stripsrc,$(GRAFDIRS)/TTF.o $(GRAFDIRS)/TText.o $(GRAFDIRS)/TLatex.o $(GRAFDIRS)/TMathText.o): \ $(FREETYPEDEP) -$(call stripsrc,$(GRAFDIRS)/TTF.o $(GRAFDIRS)/TText.o $(GRAFDIRS)/TLatex.o): \ +$(call stripsrc,$(GRAFDIRS)/TTF.o $(GRAFDIRS)/TText.o $(GRAFDIRS)/TLatex.o $(GRAFDIRS)/TMathText.o): \ CXXFLAGS += $(FREETYPEINC) ifeq ($(PLATFORM),win32) diff --git a/graf2d/graf/doc/macros/mathsymbols.C b/graf2d/graf/doc/macros/mathsymbols.C index 15ef758414b0d..b278b3642a7aa 100644 --- a/graf2d/graf/doc/macros/mathsymbols.C +++ b/graf2d/graf/doc/macros/mathsymbols.C @@ -2,12 +2,12 @@ TCanvas *Ms = new TCanvas("mathsymb","Mathematical Symbols",800,500); TLatex Tl; - Tl.SetTextSize(0.036); + Tl.SetTextSize(0.033); // Draw First Column Tl.SetTextAlign(12); float y, step, x1, x2; - float step = 0.057; + float step = 0.054; y = 0.96; x1 = 0.02; x2 = x1+0.04; Tl.DrawLatex(x1, y, "#club") ; Tl.DrawText(x2, y, "#club"); y -= step ; Tl.DrawLatex(x1, y, "#voidn") ; Tl.DrawText(x2, y, "#voidn"); @@ -26,11 +26,11 @@ y -= step ; Tl.DrawLatex(x1, y, "#arcbottom") ; Tl.DrawText(x2, y, "#arcbottom"); y -= step ; Tl.DrawLatex(x1, y, "#downarrow") ; Tl.DrawText(x2, y, "#downarrow"); y -= step ; Tl.DrawLatex(x1, y, "#leftrightarrow") ; Tl.DrawText(x2, y, "#leftrightarrow"); + y -= step ; Tl.DrawLatex(x1, y, "#Downarrow") ; Tl.DrawText(x2, y, "#Downarrow"); // Draw Second Column y = 0.96; x1 = 0.22; x2 = x1+0.04; - Tl.DrawLatex(x1, y, "#Downarrow") ; Tl.DrawText(x2, y, "#Downarrow"); - y -= step ; Tl.DrawLatex(x1, y, "#Leftrightarrow") ; Tl.DrawText(x2, y, "#Leftrightarrow"); + Tl.DrawLatex(x1, y, "#Leftrightarrow") ; Tl.DrawText(x2, y, "#Leftrightarrow"); y -= step ; Tl.DrawLatex(x1, y, "#void8") ; Tl.DrawText(x2, y, "#void8"); y -= step ; Tl.DrawLatex(x1, y, "#hbar") ; Tl.DrawText(x2, y, "#hbar"); y -= step ; Tl.DrawLatex(x1, y, "#diamond") ; Tl.DrawText(x2, y, "#diamond"); @@ -46,13 +46,12 @@ y -= step ; Tl.DrawLatex(x1, y, "#circ") ; Tl.DrawText(x2, y, "#circ"); y -= step ; Tl.DrawLatex(x1, y, "#infty") ; Tl.DrawText(x2, y, "#infty"); y -= step ; Tl.DrawLatex(x1, y, "#angle") ; Tl.DrawText(x2, y, "#angle"); - + y -= step ; Tl.DrawLatex(x1, y, "#cbar") ; Tl.DrawText(x2, y, "#cbar"); + y -= step ; Tl.DrawLatex(x1, y, "#arctop") ; Tl.DrawText(x2, y, "#arctop"); // Draw Third Column y = 0.96; x1 = 0.42; x2 = x1+0.04; - Tl.DrawLatex(x1, y, "#cbar") ; Tl.DrawText(x2, y, "#cbar"); - y -= step ; Tl.DrawLatex(x1, y, "#arctop") ; Tl.DrawText(x2, y, "#arctop"); - y -= step ; Tl.DrawLatex(x1, y, "#leftarrow") ; Tl.DrawText(x2, y, "#leftarrow"); + Tl.DrawLatex(x1, y, "#leftarrow") ; Tl.DrawText(x2, y, "#leftarrow"); y -= step ; Tl.DrawLatex(x1, y, "#otimes") ; Tl.DrawText(x2, y, "#otimes"); y -= step ; Tl.DrawLatex(x1, y, "#Leftarrow") ; Tl.DrawText(x2, y, "#Leftarrow"); y -= step ; Tl.DrawLatex(x1, y, "#prod") ; Tl.DrawText(x2, y, "#prod"); @@ -67,14 +66,13 @@ y -= step ; Tl.DrawLatex(x1, y, "#wedge") ; Tl.DrawText(x2, y, "#wedge"); y -= step ; Tl.DrawLatex(x1, y, "#oright") ; Tl.DrawText(x2, y, "#oright"); y -= step ; Tl.DrawLatex(x1, y, "#AA") ; Tl.DrawText(x2, y, "#AA"); - + y -= step ; Tl.DrawLatex(x1, y, "#pm") ; Tl.DrawText(x2, y, "#pm"); + y -= step ; Tl.DrawLatex(x1, y, "#mp") ; Tl.DrawText(x2, y, "#mp"); + y -= step ; Tl.DrawLatex(x1, y, "#3dots") ; Tl.DrawText(x2, y, "#3dots"); // Draw Fourth Column y = 0.96; x1 = 0.62; x2 = x1+0.04; - Tl.DrawLatex(x1, y, "#pm") ; Tl.DrawText(x2, y, "#pm"); - y -= step ; Tl.DrawLatex(x1, y, "#mp") ; Tl.DrawText(x2, y, "#mp"); - y -= step ; Tl.DrawLatex(x1, y, "#3dots") ; Tl.DrawText(x2, y, "#3dots"); - y -= step ; Tl.DrawLatex(x1, y, "#nabla") ; Tl.DrawText(x2, y, "#nabla"); + Tl.DrawLatex(x1, y, "#nabla") ; Tl.DrawText(x2, y, "#nabla"); y -= step ; Tl.DrawLatex(x1, y, "#downleftarrow") ; Tl.DrawText(x2, y, "#downleftarrow"); y -= step ; Tl.DrawLatex(x1, y, "#topbar") ; Tl.DrawText(x2, y, "#topbar"); y -= step ; Tl.DrawLatex(x1, y, "#arcbar") ; Tl.DrawText(x2, y, "#arcbar"); @@ -83,20 +81,21 @@ y -= step ; Tl.DrawLatex(x1, y, "#Uparrow") ; Tl.DrawText(x2, y, "#Uparrow"); y -= step ; Tl.DrawLatex(x1, y-0.01, "#sum") ; Tl.DrawText(x2, y, "#sum"); y -= step ; Tl.DrawLatex(x1, y, "#perp") ; Tl.DrawText(x2, y, "#perp"); - y -= step ; Tl.DrawLatex(x1, y, "#forall") ; Tl.DrawText(x2, y, "#forall"); + y -= step ; Tl.DrawLatex(x1, y, "#forall") ; Tl.DrawText(x2, y, "#forall"); y -= step ; Tl.DrawLatex(x1, y, "#spade") ; Tl.DrawText(x2, y, "#spade"); y -= step ; Tl.DrawLatex(x1, y, "#Rgothic") ; Tl.DrawText(x2, y, "#Rgothic"); y -= step ; Tl.DrawLatex(x1, y, "#GT") ; Tl.DrawText(x2, y, "#GT"); y -= step ; Tl.DrawLatex(x1, y, "#propto") ; Tl.DrawText(x2, y, "#propto"); - - // Draw Fith Column - y = 0.96; x1 = 0.82; x2 = x1+0.04; - Tl.DrawLatex(x1, y, "#notsubset") ; Tl.DrawText(x2, y, "#notsubset"); + y -= step ; Tl.DrawLatex(x1, y, "#notsubset") ; Tl.DrawText(x2, y, "#notsubset"); y -= step ; Tl.DrawLatex(x1, y, "#oslash") ; Tl.DrawText(x2, y, "#oslash"); y -= step ; Tl.DrawLatex(x1, y, "#vee") ; Tl.DrawText(x2, y, "#vee"); y -= step ; Tl.DrawLatex(x1, y, "#void1") ; Tl.DrawText(x2, y, "#void1"); - y -= step ; Tl.DrawLatex(x1, y, "#aa") ; Tl.DrawText(x2, y, "#aa"); + + // Draw Fith Column + y = 0.96; x1 = 0.82; x2 = x1+0.04; + Tl.DrawLatex(x1, y, "#aa") ; Tl.DrawText(x2, y, "#aa"); y -= step ; Tl.DrawLatex(x1, y, "#/") ; Tl.DrawText(x2, y, "#/"); + y -= step ; Tl.DrawLatex(x1, y, "#backslash") ; Tl.DrawText(x2, y, "#backslash"); y -= step ; Tl.DrawLatex(x1, y, "#upoint") ; Tl.DrawText(x2, y, "#upoint"); y -= step ; Tl.DrawLatex(x1, y, "#partial") ; Tl.DrawText(x2, y, "#partial"); y -= step ; Tl.DrawLatex(x1, y, "#corner") ; Tl.DrawText(x2, y, "#corner"); @@ -107,7 +106,9 @@ y -= step ; Tl.DrawLatex(x1, y, "#Rightarrow") ; Tl.DrawText(x2, y, "#Rightarrow"); y -= step ; Tl.DrawLatex(x1, y-0.015, "#int") ; Tl.DrawText(x2, y, "#int"); y -= step ; Tl.DrawLatex(x1, y, "#odot") ; Tl.DrawText(x2, y, "#odot"); - y -= step ; Tl.DrawLatex(x1, y, "#exists") ; Tl.DrawText(x2, y, "#exists"); + y -= step ; Tl.DrawLatex(x1, y, "#exists") ; Tl.DrawText(x2, y, "#exists"); + y -= step ; Tl.DrawLatex(x1, y, "#plus") ; Tl.DrawText(x2, y, "#plus"); + y -= step ; Tl.DrawLatex(x1, y, "#minus") ; Tl.DrawText(x2, y, "#minus"); return Ms; } diff --git a/graf2d/graf/inc/LinkDef.h b/graf2d/graf/inc/LinkDef.h index 629f3c8a2618a..952d43c9c770b 100644 --- a/graf2d/graf/inc/LinkDef.h +++ b/graf2d/graf/inc/LinkDef.h @@ -38,6 +38,7 @@ #pragma link C++ class TImagePlugin; #pragma link C++ class TImagePalette; #pragma link C++ class TLatex+; +#pragma link C++ class TMathText+; #pragma link C++ class TLegend+; #pragma link C++ class TLegendEntry+; #pragma link C++ class TLine-; diff --git a/graf2d/graf/inc/TGaxis.h b/graf2d/graf/inc/TGaxis.h index 43211b6edc6ab..25db9e906a9fb 100644 --- a/graf2d/graf/inc/TGaxis.h +++ b/graf2d/graf/inc/TGaxis.h @@ -59,6 +59,10 @@ class TGaxis : public TLine, public TAttText { TAxis *fAxis; //!pointer to original TAxis axis (if any) static Int_t fgMaxDigits; //!Number of digits above which the 10>N notation is used + static Float_t fXAxisExpXOffset; //!Exponent X offset for the X axis + static Float_t fXAxisExpYOffset; //!Exponent Y offset for the X axis + static Float_t fYAxisExpXOffset; //!Exponent X offset for the Y axis + static Float_t fYAxisExpYOffset; //!Exponent Y offset for the Y axis TGaxis(const TGaxis&); TGaxis& operator=(const TGaxis&); @@ -105,7 +109,7 @@ class TGaxis : public TLine, public TAttText { Double_t gridlength = 0, Bool_t drawGridOnly = kFALSE); virtual void Rotate(Double_t X, Double_t Y, Double_t CFI, Double_t SFI ,Double_t XT, Double_t YT, Double_t &U, Double_t &V); - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); void SetFunction(const char *funcname=""); void SetOption(Option_t *option=""); void SetLabelColor(Int_t labelcolor) {fLabelColor = labelcolor;} // *MENU* @@ -129,7 +133,8 @@ class TGaxis : public TLine, public TAttText { void SetTitleColor(Int_t titlecolor) {SetTextColor(titlecolor);} // *MENU* void SetWmin(Double_t wmin) {fWmin = wmin;} void SetWmax(Double_t wmax) {fWmax = wmax;} - + static void SetExponentOffset(Float_t xoff=0., Float_t yoff=0., Option_t *axis="xy"); + ClassDef(TGaxis,5) //Graphics axis }; diff --git a/graf2d/graf/inc/TGraphPolar.h b/graf2d/graf/inc/TGraphPolar.h index 23ec0b10395da..56bf170d0eafc 100644 --- a/graf2d/graf/inc/TGraphPolar.h +++ b/graf2d/graf/inc/TGraphPolar.h @@ -48,8 +48,8 @@ class TGraphPolar: public TGraphErrors { public: TGraphPolar(); - TGraphPolar(Int_t n, const Double_t* x=0, const Double_t* y=0, - const Double_t* ex=0, const Double_t* ey=0); + TGraphPolar(Int_t n, const Double_t* theta=0, const Double_t* r=0, + const Double_t* etheta=0, const Double_t* er=0); virtual ~TGraphPolar(); TGraphPolargram *GetPolargram() {return fPolargram;}; diff --git a/graf2d/graf/inc/TLatex.h b/graf2d/graf/inc/TLatex.h index 5af09cd7f5943..e115ae3da881d 100644 --- a/graf2d/graf/inc/TLatex.h +++ b/graf2d/graf/inc/TLatex.h @@ -113,6 +113,8 @@ class TLatex : public TText, public TAttLine { void Copy(TObject &text) const; TLatex *DrawLatex(Double_t x, Double_t y, const char *text); + TLatex *DrawLatexNDC(Double_t x, Double_t y, const char *text); + Double_t GetHeight() const; Double_t GetXsize(); Double_t GetYsize(); diff --git a/graf2d/graf/inc/TLine.h b/graf2d/graf/inc/TLine.h index c6ccdf02d94f9..cafc6204057d4 100644 --- a/graf2d/graf/inc/TLine.h +++ b/graf2d/graf/inc/TLine.h @@ -68,6 +68,7 @@ class TLine : public TObject, public TAttLine { virtual void PaintLineNDC(Double_t u1, Double_t v1,Double_t u2, Double_t v2); virtual void Print(Option_t *option="") const; virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SetNDC(Bool_t isNDC=kTRUE); void SetHorizontal(Bool_t set = kTRUE); // *TOGGLE* *GETTER=IsHorizontal void SetVertical(Bool_t set = kTRUE); // *TOGGLE* *GETTER=IsVertical virtual void SetX1(Double_t x1) {fX1=x1;} diff --git a/graf2d/graf/inc/TMathText.h b/graf2d/graf/inc/TMathText.h new file mode 100644 index 0000000000000..ae97ce495a29c --- /dev/null +++ b/graf2d/graf/inc/TMathText.h @@ -0,0 +1,70 @@ +// @(#)root/graf:$Id: TMathText.h 20882 2007-11-19 11:31:26Z rdm $ +// Author: Yue Shi Lai 12/12/09 + +/************************************************************************* + * Copyright (C) 2009, Yue Shi Lai. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ +#ifndef ROOT_TMathText +#define ROOT_TMathText + +#ifndef ROOT_Riosfwd +#include "Riosfwd.h" +#endif +#ifndef ROOT_TText +#include "TText.h" +#endif +#ifndef ROOT_TAttFill +#include "TAttFill.h" +#endif + +class TMathTextRenderer; + +class TMathText + : public TText, public TAttFill { +protected: + void *fRenderer; + TMathText &operator=(const TMathText &); + + void Render(const Double_t x, const Double_t y, + const Double_t size, const Double_t angle, + const Char_t *t, const Int_t length); + void GetSize(Double_t &x0, Double_t &y0, + Double_t &x1, Double_t &y1, + const Double_t size, const Double_t angle, + const Char_t *t, const Int_t length); + void GetAlignPoint(Double_t &x0, Double_t &y0, + const Double_t size, const Double_t angle, + const Char_t *t, const Int_t length, + const Short_t align); +public: + enum { + kTextNDC = BIT(14) + }; + TMathText(void); + TMathText( + Double_t x, Double_t y, const char *text); + TMathText(const TMathText &text); + virtual ~TMathText(void); + void Copy(TObject &text) const; + TMathText *DrawMathText( + Double_t x, Double_t y, const char *text); + void GetBoundingBox( + UInt_t &w, UInt_t &h, Bool_t angle = kFALSE); + Double_t GetXsize(void); + Double_t GetYsize(void); + virtual void Paint(Option_t *option = ""); + virtual void PaintMathText( + Double_t x, Double_t y, Double_t angle, Double_t size, + const char *text); + virtual void SavePrimitive( + std::ostream &out, Option_t *option = ""); + friend class TMathTextRenderer; + + ClassDef(TMathText,1) +}; + +#endif diff --git a/graf2d/graf/inc/TTF.h b/graf2d/graf/inc/TTF.h index f53ca8f32687b..838f786250334 100644 --- a/graf2d/graf/inc/TTF.h +++ b/graf2d/graf/inc/TTF.h @@ -54,14 +54,16 @@ class TTGlyph { class TGX11TTF; class TGWin32; +class TMathTextRenderer; class TTF { friend class TGX11TTF; friend class TGWin32; +friend class TMathTextRenderer; -private: +protected: enum { kTTMaxFonts = 32, kMaxGlyphs = 1024 }; static Int_t fgAscent; // string ascent, used to compute Y alignment @@ -87,6 +89,7 @@ friend class TGWin32; static Short_t CharToUnicode(UInt_t code); static void LayoutGlyphs(); static void PrepareString(const char *string); + static void PrepareString(const wchar_t *string); static void SetRotationMatrix(Float_t angle); public: @@ -108,6 +111,7 @@ friend class TGWin32; static void SetKerning(Bool_t state); static void SetSmoothing(Bool_t state); static void GetTextExtent(UInt_t &w, UInt_t &h, char *text); + static void GetTextExtent(UInt_t &w, UInt_t &h, wchar_t *text); static void GetTextAdvance(UInt_t &a, char *text); static void SetTextFont(Font_t fontnumber); static Int_t SetTextFont(const char *fontname, Int_t italic=0); diff --git a/graf2d/graf/inc/TText.h b/graf2d/graf/inc/TText.h index 43b0a142a3e00..f01636d12d3fa 100644 --- a/graf2d/graf/inc/TText.h +++ b/graf2d/graf/inc/TText.h @@ -36,6 +36,7 @@ class TText : public TNamed, public TAttText { protected: Double_t fX; // X position of text (left,center,etc..) Double_t fY; // Y position of text (left,center,etc..) + void *fWcsTitle; //!Used by TMathText public: // TText status bits @@ -43,12 +44,15 @@ class TText : public TNamed, public TAttText { TText(); TText(Double_t x, Double_t y, const char *text); + TText(Double_t x, Double_t y, const wchar_t *text); TText(const TText &text); virtual ~TText(); void Copy(TObject &text) const; virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); virtual TText *DrawText(Double_t x, Double_t y, const char *text); + virtual TText *DrawText(Double_t x, Double_t y, const wchar_t *text); virtual TText *DrawTextNDC(Double_t x, Double_t y, const char *text); + virtual TText *DrawTextNDC(Double_t x, Double_t y, const wchar_t *text); virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py); virtual void GetControlBox(Int_t x, Int_t y, Double_t theta, @@ -56,19 +60,26 @@ class TText : public TNamed, public TAttText { Double_t GetX() const { return fX; } virtual void GetBoundingBox(UInt_t &w, UInt_t &h, Bool_t angle = kFALSE); virtual void GetTextAscentDescent(UInt_t &a, UInt_t &d, const char *text) const; + virtual void GetTextAscentDescent(UInt_t &a, UInt_t &d, const wchar_t *text) const; virtual void GetTextExtent(UInt_t &w, UInt_t &h, const char *text) const; + virtual void GetTextExtent(UInt_t &w, UInt_t &h, const wchar_t *text) const; virtual void GetTextAdvance(UInt_t &a, const char *text, const Bool_t kern=kTRUE) const; + const void * GetWcsTitle(void) const; Double_t GetY() const { return fY; } virtual void ls(Option_t *option="") const; virtual void Paint(Option_t *option=""); virtual void PaintControlBox(Int_t x, Int_t y, Double_t theta); virtual void PaintText(Double_t x, Double_t y, const char *text); + virtual void PaintText(Double_t x, Double_t y, const wchar_t *text); virtual void PaintTextNDC(Double_t u, Double_t v, const char *text); + virtual void PaintTextNDC(Double_t u, Double_t v, const wchar_t *text); virtual void Print(Option_t *option="") const; - virtual void SavePrimitive(ostream &out, Option_t *option = ""); + virtual void SavePrimitive(std::ostream &out, Option_t *option = ""); + virtual void SetMbTitle(const wchar_t *title=L""); // *MENU* virtual void SetNDC(Bool_t isNDC=kTRUE); virtual void SetText(Double_t x, Double_t y, const char *text) {fX=x; fY=y; SetTitle(text);} // *MENU* *ARGS={x=>fX,y=>fY,text=>fTitle} + virtual void SetText(Double_t x, Double_t y, const wchar_t *text) {fX=x; fY=y; SetMbTitle(text);} virtual void SetX(Double_t x) { fX = x; } // *MENU* virtual void SetY(Double_t y) { fY = y; } // *MENU* diff --git a/graf2d/graf/src/TCutG.cxx b/graf2d/graf/src/TCutG.cxx index 60709adc7c791..1ed6d673dd5e7 100644 --- a/graf2d/graf/src/TCutG.cxx +++ b/graf2d/graf/src/TCutG.cxx @@ -71,10 +71,10 @@ corresponding to x,y if one wants to use the cut as input to TTree::Draw,eg cutg->SetPoint(4,0.756681,0.1853814); cutg->SetPoint(5,-0.3586207,1.509534);
    - +

    Example of use of a TCutG in TTree::Draw:

    -       tree.Draw("x:y","mycutg && z>0 %% sqrt(x)>1")
    +   tree.Draw("x:y","mycutg && z>0 %% sqrt(x)>1")
     

    A Graphical cut may be drawn via TGraph::Draw. It can be edited like a normal diff --git a/graf2d/graf/src/TGaxis.cxx b/graf2d/graf/src/TGaxis.cxx index 231ff41e8d09d..39febdc3b4034 100644 --- a/graf2d/graf/src/TGaxis.cxx +++ b/graf2d/graf/src/TGaxis.cxx @@ -31,8 +31,13 @@ #include "TColor.h" #include "TClass.h" #include "TTimeStamp.h" +#include "TSystem.h" Int_t TGaxis::fgMaxDigits = 5; +Float_t TGaxis::fXAxisExpXOffset = 0.; //Exponent X offset for the X axis +Float_t TGaxis::fXAxisExpYOffset = 0.; //Exponent Y offset for the X axis +Float_t TGaxis::fYAxisExpXOffset = 0.; //Exponent X offset for the Y axis +Float_t TGaxis::fYAxisExpYOffset = 0.; //Exponent Y offset for the Y axis const Int_t kHori = BIT(9); //defined in TPad ClassImp(TGaxis) @@ -703,7 +708,10 @@ void TGaxis::PaintAxis(Double_t xmin, Double_t ymin, Double_t xmax, Double_t yma timeformat = fTimeFormat; } -// Determine the time offset and correct for time offset not being integer. + //GMT option + if (fTimeFormat.Index("GMT")>=0) optionTime =2; + + // Determine the time offset and correct for time offset not being integer. Double_t timeoffset =0; if (optionTime) { if (idF>=0) { @@ -711,26 +719,28 @@ void TGaxis::PaintAxis(Double_t xmin, Double_t ymin, Double_t xmax, Double_t yma TString stringtimeoffset = fTimeFormat(idF+2,lnF); Int_t year, mm, dd, hh, mi, ss; if (sscanf(stringtimeoffset.Data(), "%d-%d-%d %d:%d:%d", &year, &mm, &dd, &hh, &mi, &ss) == 6) { - struct tm tp; - struct tm* tptest; - time_t timeoffsettest; - // get timezone offset for the current location - Int_t zoneoffset_seconds = TTimeStamp::GetZoneOffset(); - // convert offset in hours - Int_t zoneoffset_hours = zoneoffset_seconds/3600; - tp.tm_year = year-1900; - tp.tm_mon = mm-1; - tp.tm_mday = dd; - tp.tm_hour = hh - zoneoffset_hours; - tp.tm_min = mi ; - tp.tm_sec = ss; - tp.tm_isdst = 1; //daylight saving time is on. + struct tm tp; + tp.tm_year = year-1900; + tp.tm_mon = mm-1; + tp.tm_mday = dd; + tp.tm_hour = hh; + tp.tm_min = mi; + tp.tm_sec = ss; + tp.tm_isdst = -1; //automatic determination of daylight saving time + TString tz = (TString)gSystem->Getenv("TZ"); //save timezone + Bool_t isUTC = kFALSE; + if (gSystem->Getenv("TZ") && tz.Length()==0) isUTC=kTRUE; + gSystem->Setenv("TZ", "UTC"); //sets timezone to UTC + tzset(); timeoffset = mktime(&tp); - if (timeoffset<0.) timeoffset=0.; - // have to correct this time to go back to UTC - timeoffsettest = (time_t)((Long_t)timeoffset); - tptest = gmtime(&timeoffsettest); - timeoffset += timeoffsettest - mktime(tptest); + //restore TZ + if (tz.Length()) { + gSystem->Setenv("TZ", tz.Data()); + } else { + if (isUTC) gSystem->Setenv("TZ", ""); + else gSystem->Unsetenv("TZ"); + } + tzset(); // Add the time offset's decimal part if it is there Int_t ids = stringtimeoffset.Index("s"); if (ids >= 0) { @@ -740,16 +750,6 @@ void TGaxis::PaintAxis(Double_t xmin, Double_t ymin, Double_t xmax, Double_t yma sscanf(sdp.Data(),"%g",&dp); timeoffset += dp; } - // if optionTime = 2 gmtime will be used instead of localtime - Int_t idG = stringtimeoffset.Index("GMT"); - if (idG>=0) { - lnF = stringtimeoffset.Length(); - TString gmtoffset = stringtimeoffset(idG+3,lnF); - Int_t itz; - sscanf(gmtoffset.Data(), "%d", &itz); - timeoffset += zoneoffset_seconds-itz; - optionTime = 2; - } } else { Error(where, "Time offset has not the right format"); } @@ -758,7 +758,8 @@ void TGaxis::PaintAxis(Double_t xmin, Double_t ymin, Double_t xmax, Double_t yma } wmin += timeoffset - (int)(timeoffset); wmax += timeoffset - (int)(timeoffset); - // correct for time offset at a good limit (min, hour, day, month, year) + + // correct for time offset at a good limit (min, hour, day, month, year) struct tm* tp0; time_t timetp = (time_t)((Long_t)(timeoffset)); Double_t range = wmax - wmin; @@ -1452,8 +1453,8 @@ void TGaxis::PaintAxis(Double_t xmin, Double_t ymin, Double_t xmax, Double_t yma coded = &chcoded[0]; if (if1 > 14) if1=14; if (if2 > 14) if2=14; - if (if2) snprintf(coded,8,"%%%d.%df",if1,if2); - else snprintf(coded,8,"%%%d.%df",if1+1,1); + if (if2>0) snprintf(coded,8,"%%%d.%df",if1,if2); + else snprintf(coded,8,"%%%d.%df",if1+1,1); } //*-*- We draw labels @@ -1494,7 +1495,7 @@ void TGaxis::PaintAxis(Double_t xmin, Double_t ymin, Double_t xmax, Double_t yma LabelsLimits(label,first,last); //Eliminate blanks - if (label[first] == '.') { //check if '.' is preceeded by a digit + if (label[first] == '.') { //check if '.' is preceded by a digit strncpy(chtemp, "0",256); strlcat(chtemp, &label[first],256); strncpy(label, chtemp,256); @@ -1634,6 +1635,14 @@ void TGaxis::PaintAxis(Double_t xmin, Double_t ymin, Double_t xmax, Double_t yma textaxis->SetTextAlign(11); if (GetLabelFont()%10 < 2) // force TLatex mode in PaintLatex textaxis->SetTextFont((Int_t)(GetLabelFont()/10)*10+2); + if (fAxis && !strcmp(fAxis->GetName(),"xaxis")) { + xx = xx + fXAxisExpXOffset; + yy = yy + fXAxisExpYOffset; + } + if (fAxis && !strcmp(fAxis->GetName(),"yaxis")) { + xx = xx + fYAxisExpXOffset; + yy = yy + fYAxisExpYOffset; + } textaxis->PaintLatex(gPad->GetX1() + xx*(gPad->GetX2() - gPad->GetX1()), gPad->GetY1() + yy*(gPad->GetY2() - gPad->GetY1()), 0, @@ -1849,7 +1858,7 @@ void TGaxis::PaintAxis(Double_t xmin, Double_t ymin, Double_t xmax, Double_t yma Double_t u = gPad->GetX1() + xx*(gPad->GetX2() - gPad->GetX1()); Double_t v = gPad->GetY1() + yy*(gPad->GetY2() - gPad->GetY1()); if (firstintlab) { - textaxis->GetBoundingBox(wi, hi); wi=(UInt_t)(wi*1.3); hi*=(UInt_t)(hi*1.3); + textaxis->GetBoundingBox(wi, hi); wi=(UInt_t)(wi*1.3); hi=(UInt_t)(hi*1.3); xi1 = gPad->XtoAbsPixel(u); yi1 = gPad->YtoAbsPixel(v); firstintlab = kFALSE; @@ -1864,7 +1873,7 @@ void TGaxis::PaintAxis(Double_t xmin, Double_t ymin, Double_t xmax, Double_t yma } else { xi1 = xi2; yi1 = yi2; - textaxis->GetBoundingBox(wi, hi); wi=(UInt_t)(wi*1.3); hi*=(UInt_t)(hi*1.3); + textaxis->GetBoundingBox(wi, hi); wi=(UInt_t)(wi*1.3); hi=(UInt_t)(hi*1.3); textaxis->PaintLatex(u,v,0,textaxis->GetTextSize(),chtemp); } } @@ -1960,7 +1969,7 @@ void TGaxis::Rotate(Double_t X, Double_t Y, Double_t CFI, Double_t SFI //______________________________________________________________________________ -void TGaxis::SavePrimitive(ostream &out, Option_t * /*= ""*/) +void TGaxis::SavePrimitive(std::ostream &out, Option_t * /*= ""*/) { // Save primitive as a C++ statement(s) on output stream out @@ -1971,54 +1980,54 @@ void TGaxis::SavePrimitive(ostream &out, Option_t * /*= ""*/) out<<" TGaxis *"; } out<<"gaxis = new TGaxis("<SetLabelOffset("<SetLabelSize("<SetTickSize("<SetGridLength("<SetTitleOffset("<SetTitleSize("<SetTitleColor("<SetTitleFont("<SetLabelOffset("<SetLabelSize("<SetTickSize("<SetGridLength("<SetTitleOffset("<SetTitleSize("<SetTitleColor("<SetTitleFont("<SetName("<SetName("<SetTitle("<SetTitle("< 228) { TColor::SaveColor(out, fLabelColor); - out<<" gaxis->SetLabelColor(ci);" << endl; + out<<" gaxis->SetLabelColor(ci);" << std::endl; } else - out<<" gaxis->SetLabelColor("<SetLabelColor("< 228) { TColor::SaveColor(out, fLineColor); - out<<" gaxis->SetLineColor(ci);" << endl; + out<<" gaxis->SetLineColor(ci);" << std::endl; } else - out<<" gaxis->SetLineColor("<SetLineColor("<SetLineStyle("<SetLineStyle("<SetLineWidth("<SetLineWidth("<SetLabelFont("<SetLabelFont("<SetMoreLogLabels();"<SetMoreLogLabels();"<SetNoExponent();"<SetNoExponent();"<Draw();"<Draw();"<=0 || timeformat.IsNull()) { fTimeFormat = timeformat; return; @@ -2163,7 +2164,7 @@ void TGaxis::SetTimeFormat(const char *tformat) Int_t idF = fTimeFormat.Index("%F"); if (idF>=0) { - lnF = fTimeFormat.Length(); + Int_t lnF = fTimeFormat.Length(); TString stringtimeoffset = fTimeFormat(idF,lnF); fTimeFormat = tformat; fTimeFormat.Append(stringtimeoffset); @@ -2178,14 +2179,11 @@ void TGaxis::SetTimeFormat(const char *tformat) void TGaxis::SetTimeOffset(Double_t toffset, Option_t *option) { // Change the time offset. - // If option = "gmt" the time offset is treated as a GMT time. + // If option = "gmt", set display mode to GMT. TString opt = option; opt.ToLower(); - Bool_t gmt = kFALSE; - if (opt.Contains("gmt")) gmt = kTRUE; - char tmp[20]; time_t timeoff; struct tm* utctis; @@ -2194,20 +2192,43 @@ void TGaxis::SetTimeOffset(Double_t toffset, Option_t *option) fTimeFormat.Append("%F"); timeoff = (time_t)((Long_t)(toffset)); + + // offset is always saved in GMT to allow file transport + // to different time zones utctis = gmtime(&timeoff); - strftime(tmp,20,"%Y-%m-%d %H:%M:%S",utctis); + strftime(tmp, 20,"%Y-%m-%d %H:%M:%S",utctis); fTimeFormat.Append(tmp); // append the decimal part of the time offset Double_t ds = toffset-(Int_t)toffset; - if(ds!= 0) { - snprintf(tmp,20,"s%g",ds); - fTimeFormat.Append(tmp); - } + snprintf(tmp,20,"s%g",ds); + fTimeFormat.Append(tmp); + + // add GMT/local option + if (opt.Contains("gmt")) fTimeFormat.Append(" GMT"); +} + - // If the time is GMT, stamp fTimeFormat - if (gmt) fTimeFormat.Append(Form(" GMT%d",TTimeStamp::GetZoneOffset())); +//______________________________________________________________________________ +void TGaxis::SetExponentOffset(Float_t xoff, Float_t yoff, Option_t *axis) +{ + // Static function to set X and Y offset of the axis 10^n notation. + // It is in % of the pad size. It can be negative. + // axis specifies which axis ("x","y"), default = "x" + // if axis="xz" set the two axes + + TString opt = axis; + opt.ToLower(); + + if (opt.Contains("x")) { + fXAxisExpXOffset = xoff; + fXAxisExpYOffset = yoff; + } + if (opt.Contains("y")) { + fYAxisExpXOffset = xoff; + fYAxisExpYOffset = yoff; + } } diff --git a/graf2d/graf/src/TLatex.cxx b/graf2d/graf/src/TLatex.cxx index 640f43e906267..b68fc41a6c84b 100644 --- a/graf2d/graf/src/TLatex.cxx +++ b/graf2d/graf/src/TLatex.cxx @@ -13,16 +13,12 @@ #include "TROOT.h" #include "TClass.h" #include "TLatex.h" +#include "TMathText.h" #include "TMath.h" #include "TVirtualPad.h" #include "TVirtualPS.h" -#ifdef R__SUNCCBUG -const Double_t kPI = 3.14159265358979323846; -#else const Double_t kPI = TMath::Pi(); -#endif -const Int_t kLatex = BIT(10); ClassImp(TLatex) @@ -48,6 +44,7 @@ It provides several functionalities:

  • Character Adjustement
  • Italic and Boldface
  • Examples
  • +
  • Interface to TMathText
  • When the font precision (see TAttText) is low (0 or 1), TLatex is @@ -63,10 +60,16 @@ which set relative size of subscripts and superscripts, and subscipts and superscripts.

    Examples: End_Html - x^{2y} : Begin_Latex x^{2y} End_Latex x_{2y} : Begin_Latex x^{2y} End_Latex + x^{2y} : Begin_Latex x^{2y} End_Latex x_{2y} : Begin_Latex x_{2y} End_Latex x^{y^{2}} : Begin_Latex x^{y^{2}} End_Latex x^{y_{1}} : Begin_Latex x^{y_{1}} End_Latex x^{y}_{1} : Begin_Latex x^{y}_{1} End_Latex x_{1}^{y} : Begin_Latex x_{1}^{y} End_Latex +Begin_Html +The best way to put the subscipts and superscripts before the character and not +after, is to use an empty character: +End_Html + {}^{40}_{20}Ca : Begin_Latex {}^{40}_{20}Ca End_Latex + Begin_Html The subscripts and superscripts operators apply not only on one character but on all the "normal text" preceding them. In the following example the second @@ -297,6 +300,15 @@ Begin_Macro(source) return ex3; } End_Macro + +Begin_Html +

    Interface to TMathText

    +The class TMathText is a TeX math formulae interpreter. It uses plain +TeX syntax and uses "\" as control instead of "#". If a piece of text containing +"\" is given to TLatex then TMathText is automatically invoked. +Therefore, as histograms' titles, axis titles, labels etc ... are drawn using +TLatex, the TMathText syntax can be used for them also. +End_Html */ @@ -529,9 +541,9 @@ TLatexFormSize TLatex::Analyse(Double_t x, Double_t y, TextSpec_t spec, const Ch Int_t opCurlyCurly = -1; // Position of first }{ Int_t opSquareCurly = -1; // Position of first ]{ Int_t opCloseCurly = -2; // Position of first } - Int_t opColor = -1; // Position of first \color - Int_t opFont = -1; // Position of first \font - Int_t opScale = -1; // Position of first \scale + Int_t opColor = -1; // Position of first #color + Int_t opFont = -1; // Position of first #font + Int_t opScale = -1; // Position of first #scale Int_t opGreek = -1; // Position of a Greek letter Int_t opSpec = -1; // position of a special character Int_t opAbove = -1; // position of a vector/overline @@ -544,13 +556,18 @@ TLatexFormSize TLatex::Analyse(Double_t x, Double_t y, TextSpec_t spec, const Ch Int_t opPerp = 0; // position of #perp Int_t opOdot = 0; // position of #odot Int_t opHbar = 0; // position of #hbar + Int_t opMinus = 0; // position of #minus + Int_t opPlus = 0; // position of #plus Int_t opMp = 0; // position of #mp + Int_t opBackslash = 0; // position of #backslash Int_t opParallel = 0; // position of #parallel - Int_t opSplitLine = -1; // Position of first \splitline + Int_t opSplitLine = -1; // Position of first #splitline Int_t opKern = -1; // Position of first #kern Int_t opLower = -1; // Position of first #lower Int_t opBf = -1; // Position of first #bf Int_t opIt = -1; // Position of first #it + Int_t opMbox = -1; // Position of first #mbox + Bool_t opFound = kFALSE; Bool_t quote1 = kFALSE, quote2 = kFALSE ; @@ -647,6 +664,15 @@ TLatexFormSize TLatex::Analyse(Double_t x, Double_t y, TextSpec_t spec, const Ch continue; } } + if (length>i+9) { + Char_t buf[10]; + strncpy(buf,&text[i+1],9); + if (!opBackslash && strncmp(buf,"backslash",9)==0) { + opBackslash=1; opFound = kTRUE; + if (i>0 && opCloseCurly==-2) opCloseCurly=i-1; + continue; + } + } if (length>i+8) { Char_t buf[9]; strncpy(buf,&text[i+1],8); @@ -698,6 +724,16 @@ TLatexFormSize TLatex::Analyse(Double_t x, Double_t y, TextSpec_t spec, const Ch if (i>0 && opCloseCurly==-2) opCloseCurly=i-1; continue ; } + if (!opMinus && strncmp(buf,"minus",5)==0) { + opMinus=1; opFound = kTRUE; + if (i>0 && opCloseCurly==-2) opCloseCurly=i-1; + continue; + } + if (strncmp(buf,"mbox[",5)==0 || strncmp(buf,"mbox{",5)==0) { + opMbox=i; opFound = kTRUE; + if (i>0 && opCloseCurly==-2) opCloseCurly=i-1; + continue ; + } } if (length>i+4) { Char_t buf[5]; @@ -717,6 +753,11 @@ TLatexFormSize TLatex::Analyse(Double_t x, Double_t y, TextSpec_t spec, const Ch if (i>0 && opCloseCurly==-2) opCloseCurly=i-1; continue; } + if (!opPlus && strncmp(buf,"plus",4)==0) { + opPlus=1; opFound = kTRUE; + if (i>0 && opCloseCurly==-2) opCloseCurly=i-1; + continue; + } } if (length>i+3) { Char_t buf[4]; @@ -1053,7 +1094,7 @@ TLatexFormSize TLatex::Analyse(Double_t x, Double_t y, TextSpec_t spec, const Ch fs1 = Analyse(x+square,y,spec,text+5,length-5); TText hbar; hbar.SetTextFont(12); - hbar.SetTextColor(fTextColor); + hbar.SetTextColor(spec.fColor); hbar.SetTextSize(spec.fSize); hbar.SetTextAngle(fTextAngle); Double_t xOrigin = (Double_t)gPad->XtoAbsPixel(fX); @@ -1066,6 +1107,46 @@ TLatexFormSize TLatex::Analyse(Double_t x, Double_t y, TextSpec_t spec, const Ch } result = fs1 + TLatexFormSize(square,square,0); } + else if (opMinus) { + Double_t square = GetHeight()*spec.fSize/2; + if (!fShow) { + fs1 = Anal1(spec,text+6,length-6); + } else { + fs1 = Analyse(x+square,y,spec,text+6,length-6); + TText minus; + minus.SetTextFont(122); + minus.SetTextColor(spec.fColor); + minus.SetTextSize(spec.fSize); + minus.SetTextAngle(fTextAngle); + Double_t xOrigin = (Double_t)gPad->XtoAbsPixel(fX); + Double_t yOrigin = (Double_t)gPad->YtoAbsPixel(fY); + Double_t angle = kPI*spec.fAngle/180.; + Double_t xx = gPad->AbsPixeltoX(Int_t((x-xOrigin)*TMath::Cos(angle)+(y-yOrigin)*TMath::Sin(angle)+xOrigin)); + Double_t yy = gPad->AbsPixeltoY(Int_t((x-xOrigin)*TMath::Sin(-angle)+(y-yOrigin)*TMath::Cos(angle)+yOrigin)); + minus.PaintText(xx,yy,"-"); + } + result = fs1 + TLatexFormSize(square,square,0); + } + else if (opPlus) { + Double_t square = GetHeight()*spec.fSize/2; + if (!fShow) { + fs1 = Anal1(spec,text+5,length-5); + } else { + fs1 = Analyse(x+square,y,spec,text+5,length-5); + TText plus; + plus.SetTextFont(122); + plus.SetTextColor(spec.fColor); + plus.SetTextSize(spec.fSize); + plus.SetTextAngle(fTextAngle); + Double_t xOrigin = (Double_t)gPad->XtoAbsPixel(fX); + Double_t yOrigin = (Double_t)gPad->YtoAbsPixel(fY); + Double_t angle = kPI*spec.fAngle/180.; + Double_t xx = gPad->AbsPixeltoX(Int_t((x-xOrigin)*TMath::Cos(angle)+(y-yOrigin)*TMath::Sin(angle)+xOrigin)); + Double_t yy = gPad->AbsPixeltoY(Int_t((x-xOrigin)*TMath::Sin(-angle)+(y-yOrigin)*TMath::Cos(angle)+yOrigin)); + plus.PaintText(xx,yy,"+"); + } + result = fs1 + TLatexFormSize(square,square,0); + } else if (opMp) { Double_t square = GetHeight()*spec.fSize/2; if (!fShow) { @@ -1074,7 +1155,7 @@ TLatexFormSize TLatex::Analyse(Double_t x, Double_t y, TextSpec_t spec, const Ch fs1 = Analyse(x+square,y,spec,text+3,length-3); TText mp; mp.SetTextFont(122); - mp.SetTextColor(fTextColor); + mp.SetTextColor(spec.fColor); mp.SetTextSize(spec.fSize); mp.SetTextAngle(fTextAngle+180); Double_t xOrigin = (Double_t)gPad->XtoAbsPixel(fX); @@ -1102,6 +1183,26 @@ TLatexFormSize TLatex::Analyse(Double_t x, Double_t y, TextSpec_t spec, const Ch } result = fs1; } + else if (opBackslash) { + Double_t square = GetHeight()*spec.fSize/2; + if (!fShow) { + fs1 = Anal1(spec,text+10,length-10); + } else { + fs1 = Analyse(x+square,y,spec,text+10,length-10); + TText bs; + bs.SetTextFont(GetTextFont()); + bs.SetTextColor(spec.fColor); + bs.SetTextSize(spec.fSize); + bs.SetTextAngle(fTextAngle); + Double_t xOrigin = (Double_t)gPad->XtoAbsPixel(fX); + Double_t yOrigin = (Double_t)gPad->YtoAbsPixel(fY); + Double_t angle = kPI*spec.fAngle/180.; + Double_t xx = gPad->AbsPixeltoX(Int_t((x-xOrigin)*TMath::Cos(angle)+(y-yOrigin)*TMath::Sin(angle)+xOrigin)); + Double_t yy = gPad->AbsPixeltoY(Int_t((x-xOrigin)*TMath::Sin(-angle)+(y-yOrigin)*TMath::Cos(angle)+yOrigin)); + bs.PaintText(xx,yy,"\\"); + } + result = fs1 + TLatexFormSize(square,square,0); + } else if (opParallel) { Double_t square = GetHeight()*spec.fSize/1.4; if (!fShow) { @@ -1264,16 +1365,16 @@ TLatexFormSize TLatex::Analyse(Double_t x, Double_t y, TextSpec_t spec, const Ch Double_t yy = gPad->AbsPixeltoY(Int_t((x2-xOrigin)*-sinang+(y2-yOrigin)*cosang+yOrigin)); TText tilde; tilde.SetTextFont(fTextFont); - tilde.SetTextColor(fTextColor); + tilde.SetTextColor(spec.fColor); tilde.SetTextSize(0.9*spec.fSize); tilde.SetTextAlign(22); tilde.SetTextAngle(fTextAngle); tilde.PaintText(xx,yy,"~"); if (saveps) { - y2 -= 4*sub; + gVirtualPS = saveps; + if (!strstr(gVirtualPS->GetTitle(),"IMG")) y2 -= 4*sub; xx = gPad->AbsPixeltoX(Int_t((x2-xOrigin)*cosang+(y2-yOrigin)*sinang+xOrigin)); yy = gPad->AbsPixeltoY(Int_t((x2-xOrigin)*-sinang+(y2-yOrigin)*cosang+yOrigin)); - gVirtualPS = saveps; gVirtualPS->SetTextAlign(22); gVirtualPS->Text(xx, yy, "~"); } @@ -1636,6 +1737,17 @@ TLatexFormSize TLatex::Analyse(Double_t x, Double_t y, TextSpec_t spec, const Ch } result = fs1; } + else if (opMbox>-1) { // dummy operator #mbox{arg} + TextSpec_t newSpec = spec; + if (!fShow) { + fs1 = Anal1(newSpec,text+5,length-5); + Savefs(&fs1); + } else { + fs1 = Readfs(); + Analyse(x,y,newSpec,text+5,length-5); + } + result = fs1; + } else if (opIt>-1) { // operator #it{arg} TextSpec_t newSpec = spec; Int_t lut[] = {13, 3, 2, 5, 4, 7, 6, 9, 8, 11, 10, 15, 1, 14, 12}; @@ -1724,6 +1836,17 @@ TLatex *TLatex::DrawLatex(Double_t x, Double_t y, const char *text) } +//______________________________________________________________________________ +TLatex *TLatex::DrawLatexNDC(Double_t x, Double_t y, const char *text) +{ + // Draw this TLatex with new coordinates in NDC. + + TLatex *newtext = DrawLatex(x, y, text); + newtext->SetNDC(); + return newtext; +} + + //______________________________________________________________________________ void TLatex::DrawLine(Double_t x1, Double_t y1, Double_t x2, Double_t y2, TextSpec_t spec) { @@ -1836,16 +1959,97 @@ void TLatex::PaintLatex(Double_t x, Double_t y, Double_t angle, Double_t size, c TAttText::Modify(); // Change text attributes only if necessary. + TVirtualPS *saveps = gVirtualPS; + + if (gVirtualPS) { + if (gVirtualPS->InheritsFrom("TTeXDump")) { + gVirtualPS->SetTextAngle(angle); + TString t(text1); + if (t.Index("#")>=0 || t.Index("^")>=0 || t.Index("\\")>=0) { + t.ReplaceAll("#LT","\\langle"); + t.ReplaceAll("#GT","\\rangle"); + t.ReplaceAll("#club","\\clubsuit"); + t.ReplaceAll("#spade","\\spadesuit"); + t.ReplaceAll("#heart","\\heartsuit"); + t.ReplaceAll("#diamond","\\diamondsuit"); + t.ReplaceAll("#voidn","\\wp"); + t.ReplaceAll("#voidb","f"); + t.ReplaceAll("#ocopyright","\\copyright"); + t.ReplaceAll("#trademark","TM"); + t.ReplaceAll("#void3","TM"); + t.ReplaceAll("#oright","R"); + t.ReplaceAll("#void1","R"); + t.ReplaceAll("#3dots","\\ldots"); + t.ReplaceAll("#lbar","\\mid"); + t.ReplaceAll("#void8","\\mid"); + t.ReplaceAll("#divide","\\div"); + t.ReplaceAll("#Jgothic","\\Im"); + t.ReplaceAll("#Rgothic","\\Re"); + t.ReplaceAll("#doublequote","\""); + t.ReplaceAll("#plus","+"); + t.ReplaceAll("#minus","-"); + t.ReplaceAll("#/","/"); + t.ReplaceAll("#upoint","."); + t.ReplaceAll("#aa","\\mbox{\\aa}"); + t.ReplaceAll("#AA","\\mbox{\\AA}"); + + t.ReplaceAll("#omicron","o"); + t.ReplaceAll("#Alpha","A"); + t.ReplaceAll("#Beta","B"); + t.ReplaceAll("#Epsilon","E"); + t.ReplaceAll("#Zeta","Z"); + t.ReplaceAll("#Eta","H"); + t.ReplaceAll("#Iota","I"); + t.ReplaceAll("#Kappa","K"); + t.ReplaceAll("#Mu","M"); + t.ReplaceAll("#Nu","N"); + t.ReplaceAll("#Omicron","O"); + t.ReplaceAll("#Rho","P"); + t.ReplaceAll("#Tau","T"); + t.ReplaceAll("#Chi","X"); + t.ReplaceAll("#varomega","\\varpi"); + + t.ReplaceAll("#varUpsilon","?"); + t.ReplaceAll("#corner","?"); + t.ReplaceAll("#ltbar","?"); + t.ReplaceAll("#bottombar","?"); + t.ReplaceAll("#notsubset","?"); + t.ReplaceAll("#arcbottom","?"); + t.ReplaceAll("#cbar","?"); + t.ReplaceAll("#arctop","?"); + t.ReplaceAll("#topbar","?"); + t.ReplaceAll("#arcbar","?"); + t.ReplaceAll("#downleftarrow","?"); + + t.ReplaceAll("#","\\"); + t.ReplaceAll("%","\\%"); + } + gVirtualPS->Text(x,y,t.Data()); + gVirtualPS = 0; + } + } + // Do not use Latex if font is low precision. if (fTextFont%10 < 2) { if (gVirtualX) gVirtualX->SetTextAngle(angle); if (gVirtualPS) gVirtualPS->SetTextAngle(angle); gPad->PaintText(x,y,text1); + if (saveps) gVirtualPS = saveps; + return; + } + + // Paint the text using TMathText if contains a "\" + if (strstr(text1,"\\")) { + TMathText tm; + tm.SetTextAlign(GetTextAlign()); + tm.PaintMathText(x, y, angle, size, text1); + if (saveps) gVirtualPS = saveps; return; } TString newText = text1; if( newText.Length() == 0) return; + newText.ReplaceAll("#hbox","#mbox"); Double_t saveSize = size; Int_t saveFont = fTextFont; @@ -1860,12 +2064,12 @@ void TLatex::PaintLatex(Double_t x, Double_t y, Double_t angle, Double_t size, c size = size/h; SetTextFont(10*(saveFont/10) + 2); } - if (gVirtualPS) gVirtualPS->SetBit(kLatex); fError = 0 ; if (CheckLatexSyntax(newText)) { - cout<<"\n*ERROR: "< "<: "< "<: "< "<: "< "<ResetBit(kLatex); + if (saveps) gVirtualPS = saveps; } @@ -1933,18 +2136,18 @@ Int_t TLatex::CheckLatexSyntax(TString &text) // Check if the Latex syntax is correct const Char_t *kWord1[] = {"{}^{","{}_{","^{","_{","#scale{","#color{","#font{","#sqrt{","#[]{","#{}{","#||{", - "#bar{","#vec{","#dot{","#hat{","#ddot{","#acute{","#grave{","#check{","#tilde{","#slash{","#bf{","#it{", + "#bar{","#vec{","#dot{","#hat{","#ddot{","#acute{","#grave{","#check{","#tilde{","#slash{","#bf{","#it{","#mbox{", "\\scale{","\\color{","\\font{","\\sqrt{","\\[]{","\\{}{","\\||{","#(){","\\(){", - "\\bar{","\\vec{","\\dot{","\\hat{","\\ddot{","\\acute{","\\grave{","\\check{","\\bf{","\\it{"}; // check for } + "\\bar{","\\vec{","\\dot{","\\hat{","\\ddot{","\\acute{","\\grave{","\\check{","\\bf{","\\it{","\\mbox{"}; // check for } const Char_t *kWord2[] = {"#scale[","#color[","#font[","#sqrt[","#kern[","#lower[","\\scale[","\\color[","\\font[","\\sqrt[","\\kern[","\\lower["}; // check for ]{ + } const Char_t *kWord3[] = {"#frac{","\\frac{","#splitline{","\\splitline{"}; // check for }{ then } const Char_t *kLeft1[] = {"#left[","\\left[","#left{","\\left{","#left|","\\left|","#left(","\\left("}; const Char_t *kLeft2[] = {"#[]{","#[]{","#{}{","#{}{","#||{","#||{","#(){","#(){"}; const Char_t *kRight[] = {"#right]","\\right]","#right}","\\right}","#right|","\\right|","#right)","\\right)"}; - const Int_t lkWord1[] = {4,4,2,2,7,7,6,6,4,4,4,5,5,5,5,6,7,7,7,7,7,4,4,7,7,6,6,4,4,4,4,4,5,5,5,5,6,7,7,7,4,4}; + const Int_t lkWord1[] = {4,4,2,2,7,7,6,6,4,4,4,5,5,5,5,6,7,7,7,7,7,4,4,6,7,7,6,6,4,4,4,4,4,5,5,5,5,6,7,7,7,4,4,6}; const Int_t lkWord2[] = {7,7,6,6,6,7,7,7,6,6,6,7} ; const Int_t lkWord3[] = {6,6,11,11} ; - Int_t nkWord1 = 42, nkWord2 = 12, nkWord3 = 4; + Int_t nkWord1 = 44, nkWord2 = 12, nkWord3 = 4; Int_t i,k ; Int_t nLeft1 , nRight , nOfLeft, nOfRight; Int_t lLeft1 = 6 ; @@ -2199,10 +2402,17 @@ Double_t TLatex::GetXsize() if (!gPad) return 0; TString newText = GetTitle(); if( newText.Length() == 0) return 0; + + // The text is a TMathText. + if ( newText.Contains("\\") ) { + TMathText tm(0., 0., newText.Data()); + return tm.GetXsize(); + } + fError = 0 ; if (CheckLatexSyntax(newText)) { - cout<<"\n*ERROR: "< "<: "< "<: "< "<: "< "<: "< "<: "< "<ClassSaved(TLatex::Class())) { out<<" "; } else { out<<" TLatex *"; } + TString s = GetTitle(); + + s.ReplaceAll("\\","\\\\"); s.ReplaceAll("\"","\\\""); - out<<" tex = new TLatex("<SetNDC();"<SetNDC();"<Draw();"<Draw();"< +TLegend inherits from TAttText therefore changing any +text attributes (text alignmemt, font, color...) on a legend will changed the +text attributes on each line. +
    +In particular it can be interessting to change the text alignement that way. In +order to have a base-line vertical alignment instead of a centered one simply do: +
    +   leg->SetTextAlign(13);
    +
    + leg->SetTextAlign(11); + + TLegendEntry *le = leg->AddEntry(h1,"Histogram filled with random numbers","f"); + le->SetTextColor(kBlue);; + +
    Note that the TPad class has a method to build automatically a legend for all objects in the pad. It is called TPad::BuildLegend().

    @@ -122,10 +141,10 @@ Begin_Macro(source) TLegend* leg = new TLegend(0.2, 0.2, .8, .8); TH1* h = new TH1F("", "", 1, 0, 1); - leg->AddEntry(h, "Histogram \"h\"", "l"); - leg->AddEntry((TObject*)0, "", ""); + leg->AddEntry(h, "Histogram \"h\"", "l"); + leg->AddEntry((TObject*)0, "", ""); leg->AddEntry((TObject*)0, "Some text", ""); - leg->AddEntry((TObject*)0, "", ""); + leg->AddEntry((TObject*)0, "", ""); leg->AddEntry(h, "Histogram \"h\" again", "l"); leg->Draw(); @@ -141,17 +160,17 @@ End_Html Begin_Macro(source) { TCanvas *c3 = new TCanvas("c2","c2",500,300); - + TLegend* leg = new TLegend(0.2, 0.2, .8, .8); TH1* h = new TH1F("", "", 1, 0, 1); - + leg-> SetNColumns(2); - + leg->AddEntry(h, "Column 1 line 1", "l"); leg->AddEntry(h, "Column 2 line 1", "l"); leg->AddEntry(h, "Column 1 line 2", "l"); leg->AddEntry(h, "Column 2 line 2", "l"); - + leg->Draw(); return c3; } @@ -299,6 +318,11 @@ TLegendEntry *TLegend::AddEntry(const char *name, const char *label, Option_t *o End_Html */ + if (!gPad) { + Error("AddEntry", "need to create a canvas first"); + return 0; + } + TObject *obj = gPad->FindObject(name); // If the object "name" has not been found, the following code tries to @@ -312,12 +336,12 @@ TLegendEntry *TLegend::AddEntry(const char *name, const char *label, Option_t *o if ( o->InheritsFrom(TMultiGraph::Class() ) ) { TList * grlist = ((TMultiGraph *)o)->GetListOfGraphs(); obj = grlist->FindObject(name); - if (obj) continue; + if (obj) break; } if ( o->InheritsFrom(THStack::Class() ) ) { TList * hlist = ((THStack *)o)->GetHists(); obj = hlist->FindObject(name); - if (obj) continue; + if (obj) break; } } } @@ -444,12 +468,17 @@ TLegendEntry *TLegend::GetEntry() const This method is mostly a tool for other methods inside this class. End_Html */ + if (!gPad) { + Error("GetEntry", "need to create a canvas first"); + return 0; + } + Int_t nRows = GetNRows(); if ( nRows == 0 ) return 0; Double_t ymouse = gPad->AbsPixeltoY(gPad->GetEventY())-fY1; Double_t yspace = (fY2 - fY1)/nRows; - + Int_t nColumns = GetNColumns(); Double_t xmouse = gPad->AbsPixeltoX(gPad->GetEventX())-fX1; Double_t xspace = 0.; @@ -459,11 +488,11 @@ TLegendEntry *TLegend::GetEntry() const if (xspace > 0.) ix = (Int_t)(xmouse/xspace)+1; if (ix > nColumns) ix = nColumns; if (ix < 1) ix = 1; - + Int_t iy = nRows-(Int_t)(ymouse/yspace); if (iy > nRows) iy = nRows; if (iy < 1) iy = 1; - + Int_t nloops = TMath::Min(ix+(nColumns*(iy-1)), fPrimitives->GetSize()); TIter next(fPrimitives); @@ -502,6 +531,11 @@ void TLegend::InsertEntry( const char* objectName, const char* label, Option_t* Add a new entry before the entry at the mouse position. End_Html */ + if (!gPad) { + Error("InsertEntry", "need to create a canvas first"); + return; + } + TLegendEntry* beforeEntry = GetEntry(); // get entry pointed by the mouse TObject *obj = gPad->FindObject( objectName ); @@ -593,11 +627,13 @@ void TLegend::PaintPrimitives() Double_t boxw = boxwidth*0.35; Double_t yspace = (y2-y1)/nRows; Double_t textsize = GetTextSize(); + Bool_t autosize = kFALSE; Double_t save_textsize = textsize; Double_t* columnWidths = new Double_t[fNColumns]; memset(columnWidths, 0, fNColumns*sizeof(Double_t)); if ( textsize == 0 ) { + autosize = kTRUE; textsize = ( 1. - fEntrySeparation ) * yspace; // find the max width and height (in pad coords) of one latex entry label @@ -610,6 +646,7 @@ void TLegend::PaintPrimitives() entrytex.SetNDC(); Style_t tfont = entrysize->GetTextFont(); if (tfont == 0) tfont = GetTextFont(); + if (tfont%10 == 3) --tfont; entrytex.SetTextFont(tfont); entrytex.SetTextSize(textsize); if ( entrytex.GetYsize() > maxentryheight ) { @@ -654,6 +691,7 @@ void TLegend::PaintPrimitives() entrytex.SetNDC(); Style_t tfont = entry->GetTextFont(); if (tfont == 0) tfont = GetTextFont(); + if (autosize && tfont%10 == 3) --tfont; entrytex.SetTextFont(tfont); if(entry->GetTextSize() == 0) entrytex.SetTextSize(textsize); TString opt = entry->GetOption(); @@ -695,7 +733,11 @@ void TLegend::PaintPrimitives() if (talign == 0) entry->SetTextAlign(GetTextAlign()); if (tangle == 0) entry->SetTextAngle(GetTextAngle()); if (tcolor == 0) entry->SetTextColor(GetTextColor()); - if (tfont == 0) entry->SetTextFont(GetTextFont()); + if (tfont == 0) { + tfont = GetTextFont(); + if (autosize && tfont%10 == 3) --tfont; + entry->SetTextFont(tfont); + } if (tsize == 0) entry->SetTextSize(GetTextSize()); // set x,y according to the requested alignment Double_t x=0,y=0; @@ -717,10 +759,15 @@ void TLegend::PaintPrimitives() if (halign == 2) x = 0.5*( (x1+entrymargin) + x2 ); if (halign == 3) x = x2 - entrymargin/10.; Int_t valign = entry->GetTextAlign()%10; + + // The vertical alignment "centered" is treated in a special to + // ensure a better spacing between lines. + if (valign == 2) entry->SetTextAlign(10*halign+1); + if (valign == 1) y = ytext - (1. - fEntrySeparation)* yspace/2.; - if (valign == 2) y = ytext; + if (valign == 2) y = ytext - (1. - fEntrySeparation)* yspace/4.; if (valign == 3) y = ytext + (1. - fEntrySeparation)* yspace/2.; - // + TLatex entrytex( x, y, entry->GetLabel() ); entrytex.SetNDC(); entry->TAttText::Copy(entrytex); @@ -801,6 +848,9 @@ void TLegend::PaintPrimitives() // Draw error only if (opt.Contains("e") && !(opt.Contains("l") || opt.Contains("f"))) { + if (eobj && eobj->InheritsFrom(TAttLine::Class())) { + dynamic_cast(eobj)->Copy(*entry); + } TLine entryline(xsym, ysym - yspace*0.30, xsym, ysym + yspace*0.30); entryline.SetBit(TLine::kLineNDC); @@ -894,7 +944,7 @@ void TLegend::SetEntryLabel( const char* label ) /* Begin_Html Edit the label of the entry pointed to by the mouse. End_Html */ - + TLegendEntry* entry = GetEntry(); // get entry pointed by the mouse if ( entry ) entry->SetLabel( label ); } diff --git a/graf2d/graf/src/TLine.cxx b/graf2d/graf/src/TLine.cxx index 49e6b37aec21f..01e77b8e94525 100644 --- a/graf2d/graf/src/TLine.cxx +++ b/graf2d/graf/src/TLine.cxx @@ -368,6 +368,16 @@ Bool_t TLine::IsVertical() } +//______________________________________________________________________________ +void TLine::SetNDC(Bool_t isNDC) +{ + // Set NDC mode on if isNDC = kTRUE, off otherwise + + ResetBit(kLineNDC); + if (isNDC) SetBit(kLineNDC); +} + + //______________________________________________________________________________ void TLine::SetHorizontal(Bool_t set /*= kTRUE*/) { diff --git a/graf2d/graf/src/TMathText.cxx b/graf2d/graf/src/TMathText.cxx new file mode 100644 index 0000000000000..b6fd813b510c3 --- /dev/null +++ b/graf2d/graf/src/TMathText.cxx @@ -0,0 +1,701 @@ +// @(#)root/graf:$Id: TMathText.cxx $ +// Author: Yue Shi Lai 16/10/12 + +/************************************************************************* + * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#include "Riostream.h" +#include "TROOT.h" +#include "TClass.h" +#include "TTF.h" +#include "TMathText.h" +#include "TMath.h" +#include "TVirtualPad.h" +#include "TVirtualPS.h" +#include "TText.h" + +#include "mathtext.h" +#include "mathrender.h" + +//______________________________________________________________________________ +/* Begin_Html +

    TMathText : to draw TeX Mathematical Formula

    + +TMathText's purpose is to write mathematical equations, exactly as TeX would +do it. The syntax is the same as the TeX's one. +

    +The following example demonstate how to use TMathText: +End_Html +Begin_Macro(source) +../../../tutorials/graphics/tmathtext.C +End_Macro +Begin_Html +

    +The list of all available symbol is given in the following example: +End_Html +Begin_Macro(source) +../../../tutorials/graphics/tmathtext2.C +End_Macro +Begin_Html +

    +End_Html +*/ + +const Double_t kPI = TMath::Pi(); + +class TMathTextRenderer : public TText, public TAttFill, + public mathtext::math_text_renderer_t { +private: + TMathText *_parent; + float _font_size; + float _x0; + float _y0; + float _angle_degree; + float _pad_pixel_transform[6]; + float _pad_scale; + float _pad_scale_x; + float _pad_scale_y; + float _pad_scale_x_relative; + float _pad_scale_y_relative; + float _current_font_size[mathtext::math_text_renderer_t::NFAMILY]; + inline size_t root_face_number( + const unsigned int family, const bool serif = false) const + { + static const int precision = 2; + + if (family >= mathtext::math_text_renderer_t:: + FAMILY_REGULAR && + family <= mathtext::math_text_renderer_t:: + FAMILY_BOLD_ITALIC) { + const unsigned int offset = family - + mathtext::math_text_renderer_t::FAMILY_REGULAR; + return serif ? + ((offset == 0 ? 13 : offset) * 10 + precision) : + ((offset + 4) * 10 + precision); + } else if (family >= mathtext::math_text_renderer_t:: + FAMILY_STIX_REGULAR) { + const unsigned int offset = family - + mathtext::math_text_renderer_t::FAMILY_STIX_REGULAR; + return (offset + 16) * 10 + precision; + } + + return precision; + } + inline bool is_cyrillic_or_cjk(const wchar_t c) const + { + return mathtext::math_text_renderer_t::is_cyrillic(c) || + mathtext::math_text_renderer_t::is_cjk(c); + } + inline size_t root_cjk_face_number( + const bool serif = false) const + { + return (serif ? 28 : 29) * 10 + 2; + } +protected: + inline mathtext::affine_transform_t + transform_logical_to_pixel(void) const + { + return mathtext::affine_transform_t::identity; + } + inline mathtext::affine_transform_t + transform_pixel_to_logical(void) const + { + return mathtext::affine_transform_t::identity; + } +public: + inline TMathTextRenderer(TMathText *parent) + : TText(), TAttFill(0, 1001), + _parent(parent), _font_size(0), _angle_degree(0) + { + int i; + _font_size = 0; + _x0 = 0; + _y0 = 0; + _angle_degree = 0; + for (i = 0; i<6; i++) _pad_pixel_transform[i] = 0; + _pad_scale = 0; + _pad_scale_x = 0; + _pad_scale_y = 0; + _pad_scale_x_relative = 0; + _pad_scale_y_relative = 0; + for (i = 0; i < mathtext::math_text_renderer_t::NFAMILY; i++) _current_font_size[i] = 0; + } + inline float + font_size(const unsigned int family = FAMILY_PLAIN) const + { + return _current_font_size[family]; + } + inline void + point(const float /*x*/, const float /*y*/) + { + } + inline void + set_font_size(const float size, const unsigned int family) + { + _current_font_size[family] = size; + } + inline void + set_font_size(const float size) + { + _font_size = size; + std::fill(_current_font_size, + _current_font_size + NFAMILY, size); + } + inline void + reset_font_size(const unsigned int /*family*/) + { + } + inline void + set_parameter(const float x, const float y, const float size, + const float angle_degree) + { + _x0 = gPad->XtoAbsPixel(x); + _y0 = gPad->YtoAbsPixel(y); + _pad_scale_x = + gPad->XtoPixel(gPad->GetX2()) - + gPad->XtoPixel(gPad->GetX1()); + _pad_scale_y = + gPad->YtoPixel(gPad->GetY1()) - + gPad->YtoPixel(gPad->GetY2()); + _pad_scale = std::min(_pad_scale_x, _pad_scale_y); + + _angle_degree = angle_degree; + + const float angle_radiant = _angle_degree * (kPI / 180.0); + + // Initialize the affine transform + _pad_pixel_transform[0] = _pad_scale * cosf(angle_radiant); + _pad_pixel_transform[1] = -_pad_scale * sinf(angle_radiant); + _pad_pixel_transform[2] = _x0; + _pad_pixel_transform[3] = _pad_pixel_transform[1]; + _pad_pixel_transform[4] = -_pad_pixel_transform[0]; + _pad_pixel_transform[5] = _y0; + + set_font_size(size); + SetTextAngle(_angle_degree); + SetTextColor(_parent->fTextColor); + } + inline void + transform_pad(double &xt, double &yt, + const float x, const float y) const + { + xt = gPad->AbsPixeltoX(Int_t( + x * _pad_pixel_transform[0] + + y * _pad_pixel_transform[1] + _pad_pixel_transform[2])); + yt = gPad->AbsPixeltoY(Int_t( + x * _pad_pixel_transform[3] + + y * _pad_pixel_transform[4] + _pad_pixel_transform[5])); + } + inline void + filled_rectangle(const mathtext::bounding_box_t &bounding_box_0) + { + SetFillColor(_parent->fTextColor); + SetFillStyle(1001); + TAttFill::Modify(); + + double xt[4]; + double yt[4]; + + transform_pad(xt[0], yt[0], + bounding_box_0.left(), + bounding_box_0.bottom()); + transform_pad(xt[1], yt[1], + bounding_box_0.right(), + bounding_box_0.bottom()); + transform_pad(xt[2], yt[2], + bounding_box_0.right(), + bounding_box_0.top()); + transform_pad(xt[3], yt[3], + bounding_box_0.left(), + bounding_box_0.top()); + gPad->PaintFillArea(4, xt, yt); + } + inline void + rectangle(const mathtext::bounding_box_t &/*bounding_box*/) + { + } + inline mathtext::bounding_box_t + bounding_box(const wchar_t character, float ¤t_x, + const unsigned int family) + { + const size_t old_font_index = TTF::fgCurFontIdx; + const bool cyrillic_or_cjk = is_cyrillic_or_cjk(character); + + if (cyrillic_or_cjk) { + TTF::SetTextFont(root_cjk_face_number()); + } else { + TTF::SetTextFont(root_face_number(family)); + } + FT_Load_Glyph( + TTF::fgFace[TTF::fgCurFontIdx], + FT_Get_Char_Index( + TTF::fgFace[TTF::fgCurFontIdx], character), + FT_LOAD_NO_SCALE); + + const float scale = _current_font_size[family] / + TTF::fgFace[TTF::fgCurFontIdx]->units_per_EM; + const FT_Glyph_Metrics metrics = + TTF::fgFace[TTF::fgCurFontIdx]->glyph->metrics; + const float lower_left_x = metrics.horiBearingX; + const float lower_left_y = + metrics.horiBearingY - metrics.height; + const float upper_right_x = + metrics.horiBearingX + metrics.width; + const float upper_right_y = metrics.horiBearingY; + const float advance = metrics.horiAdvance; + const float margin = std::max(0.0F, lower_left_x); + const float italic_correction = + upper_right_x <= advance ? 0.0F : + std::max(0.0F, upper_right_x + margin - advance); + const mathtext::bounding_box_t ret = + mathtext::bounding_box_t( + lower_left_x, lower_left_y, + upper_right_x, upper_right_y, + advance, italic_correction) * scale; + + current_x += ret.advance(); + TTF::fgCurFontIdx = old_font_index; + + return ret; + } + inline mathtext::bounding_box_t + bounding_box(const std::wstring string, + const unsigned int family = FAMILY_PLAIN) + { + if (TTF::fgCurFontIdx<0) return mathtext::bounding_box_t(0, 0, 0, 0, 0, 0); + if (string.empty() || TTF::fgFace[TTF::fgCurFontIdx] == NULL || + TTF::fgFace[TTF::fgCurFontIdx]->units_per_EM == 0) { + return mathtext::bounding_box_t(0, 0, 0, 0, 0, 0); + } + + std::wstring::const_iterator iterator = string.begin(); + float current_x = 0; + mathtext::bounding_box_t ret = + bounding_box(*iterator, current_x, family); + + iterator++; + for(; iterator != string.end(); iterator++) { + const mathtext::point_t position = + mathtext::point_t(current_x, 0); + const mathtext::bounding_box_t glyph_bounding_box = + bounding_box(*iterator, current_x, family); + ret = ret.merge(position + glyph_bounding_box); + } + + return ret; + } + inline void + text_raw(const float x, const float y, + const std::wstring string, + const unsigned int family = FAMILY_PLAIN) + { + SetTextFont(root_face_number(family)); + SetTextSize(_current_font_size[family]); + TAttText::Modify(); + + wchar_t buf[2]; + float advance = 0; + + buf[1] = L'\0'; + for(std::wstring::const_iterator iterator = string.begin(); + iterator != string.end(); iterator++) { + buf[0] = *iterator; + const bool cyrillic_or_cjk = is_cyrillic_or_cjk(buf[0]); + + if (cyrillic_or_cjk) { + SetTextFont(root_cjk_face_number()); + TAttText::Modify(); + } + + const mathtext::bounding_box_t b = + bounding_box(buf, family); + double xt; + double yt; + + transform_pad(xt, yt, x + advance, y); + gPad->PaintText(xt, yt, buf); + advance += b.advance(); + if (cyrillic_or_cjk) { + SetTextFont(root_face_number(family)); + TAttText::Modify(); + } + } + } + inline void + text_with_bounding_box(const float /*x*/, const float /*y*/, + const std::wstring /*string*/, + const unsigned int /*family = FAMILY_PLAIN*/) + { + } + using mathtext::math_text_renderer_t::bounding_box; +}; + +ClassImp(TMathText) + + +//______________________________________________________________________________ +TMathText::TMathText(void) + : TAttFill(0, 1001) +{ + // Default constructor. + + fRenderer = new TMathTextRenderer(this); +} + + +//______________________________________________________________________________ +TMathText::TMathText(Double_t x, Double_t y, const char *text) + : TText(x, y, text), TAttFill(0, 1001) +{ + // Normal constructor. + + fRenderer = new TMathTextRenderer(this); +} + + +//______________________________________________________________________________ +TMathText::~TMathText(void) +{ + // Destructor. +} + + +//______________________________________________________________________________ +TMathText::TMathText(const TMathText &text) + : TText(text), TAttFill(text) +{ + // Copy constructor. + + ((TMathText &)text).Copy(*this); + fRenderer = new TMathTextRenderer(this); +} + + +//______________________________________________________________________________ +TMathText &TMathText::operator=(const TMathText &rhs) +{ + // Assignment operator. + + if (this != &rhs) { + TText::operator = (rhs); + TAttFill::operator = (rhs); + } + return *this; +} + + +//______________________________________________________________________________ +void TMathText::Copy(TObject &obj) const +{ + // Copy. + + ((TMathText &)obj).fRenderer = fRenderer; + TText::Copy(obj); + TAttFill::Copy((TAttFill &)obj); +} + + +//______________________________________________________________________________ +void TMathText:: +Render(const Double_t x, const Double_t y, const Double_t size, + const Double_t angle, const Char_t *t, const Int_t /*length*/) +{ + // Render the text. + + const mathtext::math_text_t math_text(t); + TMathTextRenderer *renderer = (TMathTextRenderer *)fRenderer; + + renderer->set_parameter(x, y, size, angle); + renderer->text(0, 0, math_text); +} + + +//______________________________________________________________________________ +void TMathText:: +GetSize(Double_t &x0, Double_t &y0, Double_t &x1, Double_t &y1, + const Double_t size, const Double_t angle, const Char_t *t, + const Int_t /*length*/) +{ + // Get the text bounding box. + + const mathtext::math_text_t math_text(t); + TMathTextRenderer *renderer = (TMathTextRenderer *)fRenderer; + + renderer->set_parameter(0, 0, size, angle); + + const mathtext::bounding_box_t bounding_box = + renderer->bounding_box(math_text); + double x[4]; + double y[4]; + + renderer->transform_pad( + x[0], y[0], bounding_box.left(), bounding_box.bottom()); + renderer->transform_pad( + x[1], y[1], bounding_box.right(), bounding_box.bottom()); + renderer->transform_pad( + x[2], y[2], bounding_box.right(), bounding_box.top()); + renderer->transform_pad( + x[3], y[3], bounding_box.left(), bounding_box.top()); + + x0 = std::min(std::min(x[0], x[1]), std::min(x[2], x[3])); + y0 = std::min(std::min(y[0], y[1]), std::min(y[2], y[3])); + x1 = std::max(std::max(x[0], x[1]), std::max(x[2], x[3])); + y1 = std::max(std::max(y[0], y[1]), std::max(y[2], y[3])); +} + + +//______________________________________________________________________________ +void TMathText:: +GetAlignPoint(Double_t &x0, Double_t &y0, + const Double_t size, const Double_t angle, + const Char_t *t, const Int_t /*length*/, + const Short_t align) +{ + // Alignment. + + const mathtext::math_text_t math_text(t); + TMathTextRenderer *renderer = (TMathTextRenderer *)fRenderer; + + renderer->set_parameter(0, 0, size, angle); + + const mathtext::bounding_box_t bounding_box = + renderer->bounding_box(math_text); + float x = 0; + float y = 0; + + Short_t halign = align / 10; + Short_t valign = align - 10 * halign; + + switch(halign) { + case 0: x = bounding_box.left(); break; + case 1: x = 0; break; + case 2: x = bounding_box.horizontal_center(); break; + case 3: x = bounding_box.right(); break; + } + switch(valign) { + case 0: y = bounding_box.bottom(); break; + case 1: y = 0; break; + case 2: y = bounding_box.vertical_center(); break; + case 3: y = bounding_box.top(); break; + } + renderer->transform_pad(x0, y0, x, y); +} + + +//______________________________________________________________________________ +void TMathText::GetBoundingBox(UInt_t &w, UInt_t &h, Bool_t /*angle*/) +{ + // Get the text width and height. + + const TString newText = GetTitle(); + const Int_t length = newText.Length(); + const Char_t *text = newText.Data(); + const Double_t size = GetTextSize(); + + Double_t x0; + Double_t y0; + Double_t x1; + Double_t y1; + + GetSize(x0, y0, x1, y1, size, 0, text, length); + w = (UInt_t)(TMath::Abs(gPad->XtoAbsPixel(x1) - gPad->XtoAbsPixel(x0))); + h = (UInt_t)(TMath::Abs(gPad->YtoAbsPixel(y0) - gPad->YtoAbsPixel(y1))); +} + + +//______________________________________________________________________________ +Double_t TMathText::GetXsize(void) +{ + // Get X size. + + const TString newText = GetTitle(); + const Int_t length = newText.Length(); + const Char_t *text = newText.Data(); + const Double_t size = GetTextSize(); + const Double_t angle = GetTextAngle(); + + Double_t x0; + Double_t y0; + Double_t x1; + Double_t y1; + + GetSize(x0, y0, x1, y1, size, angle, text, length); + + return TMath::Abs(x1 - x0); +} + + +//______________________________________________________________________________ +Double_t TMathText::GetYsize(void) +{ + // Get Y size. + + const TString newText = GetTitle(); + const Int_t length = newText.Length(); + const Char_t *text = newText.Data(); + const Double_t size = GetTextSize(); + const Double_t angle = GetTextAngle(); + + Double_t x0; + Double_t y0; + Double_t x1; + Double_t y1; + + GetSize(x0, y0, x1, y1, size, angle, text, length); + + return TMath::Abs(y0 - y1); +} + + +//______________________________________________________________________________ +TMathText *TMathText::DrawMathText(Double_t x, Double_t y, const char *text) +{ + // Make a copy of this object with the new parameters + // and copy object attributes. + + TMathText *newtext = new TMathText(x, y, text); + TAttText::Copy(*newtext); + + newtext->SetBit(kCanDelete); + if (TestBit(kTextNDC)) newtext->SetNDC(); + newtext->AppendPad(); + + return newtext; +} + + +//______________________________________________________________________________ +void TMathText::Paint(Option_t *) +{ + // Paint text. + + Double_t xsave = fX; + Double_t ysave = fY; + + if (TestBit(kTextNDC)) { + fX = gPad->GetX1() + xsave * (gPad->GetX2() - gPad->GetX1()); + fY = gPad->GetY1() + ysave * (gPad->GetY2() - gPad->GetY1()); + PaintMathText(fX, fY, GetTextAngle(), GetTextSize(), GetTitle()); + } else { + PaintMathText(gPad->XtoPad(fX), gPad->YtoPad(fY), + GetTextAngle(), GetTextSize(), GetTitle()); + } + fX = xsave; + fY = ysave; +} + + +//______________________________________________________________________________ +void TMathText::PaintMathText(Double_t x, Double_t y, Double_t angle, + Double_t size, const Char_t *text1) +{ + // Paint text (used by Paint()). + + Double_t saveSize = size; + Int_t saveFont = fTextFont; + Short_t saveAlign = fTextAlign; + + TAttText::Modify(); + + // Do not use Latex if font is low precision. + if (fTextFont % 10 < 2) { + if (gVirtualX) { + gVirtualX->SetTextAngle(angle); + } + if (gVirtualPS) { + gVirtualPS->SetTextAngle(angle); + } + gPad->PaintText(x, y, text1); + return; + } + + if (fTextFont % 10 > 2) { + UInt_t w = TMath::Abs(gPad->XtoAbsPixel(gPad->GetX2()) - + gPad->XtoAbsPixel(gPad->GetX1())); + UInt_t h = TMath::Abs(gPad->YtoAbsPixel(gPad->GetY2()) - + gPad->YtoAbsPixel(gPad->GetY1())); + size = size / std::min(w, h); + SetTextFont(10 * (saveFont / 10) + 2); + } + + TString newText = text1; + + if (newText.Length() == 0) return; + + // Compatibility with TLatex and Latex + newText.ReplaceAll("\\omicron","o"); + newText.ReplaceAll("\\Alpha","A"); + newText.ReplaceAll("\\Beta","B"); + newText.ReplaceAll("\\Epsilon","E"); + newText.ReplaceAll("\\Zeta","Z"); + newText.ReplaceAll("\\Eta","H"); + newText.ReplaceAll("\\Iota","I"); + newText.ReplaceAll("\\Kappa","K"); + newText.ReplaceAll("\\Mu","M"); + newText.ReplaceAll("\\Nu","N"); + newText.ReplaceAll("\\Omicron","O"); + newText.ReplaceAll("\\Rho","P"); + newText.ReplaceAll("\\Tau","T"); + newText.ReplaceAll("\\Chi","X"); + newText.ReplaceAll("\\varomega","\\varpi"); + newText.ReplaceAll("\\mbox","\\hbox"); + if (newText.Contains("\\frac")) { + Int_t len,i1,i2; + TString str; + while (newText.Contains("\\frac")) { + len = newText.Length(); + i1 = newText.Index("\\frac"); + str = newText(i1,len).Data(); + i2 = str.Index("}{"); + newText.Replace(i1+i2,2," \\over "); + newText.Remove(i1,5); + } + } + + const Int_t length = newText.Length(); + const Char_t *text = newText.Data(); + Double_t x0; + Double_t y0; + GetAlignPoint(x0, y0, size, angle, text, length, fTextAlign); + + Render(x - x0, y - y0, size, angle, text, length); + + SetTextSize(saveSize); + SetTextFont(saveFont); + SetTextAlign(saveAlign); +} + + +//______________________________________________________________________________ +void TMathText::SavePrimitive(std::ostream &out, Option_t * /*= ""*/) +{ + // Save primitive as a C++ statement(s) on output stream out + + const char quote = '"'; + + if (gROOT->ClassSaved(TMathText::Class())) { + out << " "; + } else { + out << " TMathText *"; + } + + TString s = GetTitle(); + + s.ReplaceAll("\\","\\\\"); + s.ReplaceAll("\"","\\\""); + out << "mathtex = new TMathText("<< fX << "," << fY << "," + << quote << s.Data() << quote << ");" << std::endl; + if (TestBit(kTextNDC)) { + out << "mathtex->SetNDC();" << std::endl; + } + + SaveTextAttributes(out, "mathtex", 11, 0, 1, 42, 0.05); + SaveFillAttributes(out, "mathtex", 0, 1001); + + out<<" mathtex->Draw();" << std::endl; +} \ No newline at end of file diff --git a/graf2d/graf/src/TPaveText.cxx b/graf2d/graf/src/TPaveText.cxx index 4b628982cd7f5..0279f4623f15c 100644 --- a/graf2d/graf/src/TPaveText.cxx +++ b/graf2d/graf/src/TPaveText.cxx @@ -62,7 +62,7 @@ TPaveText::TPaveText(Double_t x1, Double_t y1,Double_t x2, Double_t y2, Option_ // pavetext normal constructor. // // a PaveText is a Pave with several lines of text - // The Pave is by default defined bith bordersize=5 and option ="br". + // The Pave is by default defined with bordersize=5 and option ="br". // option = "T" Top frame // option = "B" Bottom frame // option = "R" Right frame diff --git a/graf2d/graf/src/TPie.cxx b/graf2d/graf/src/TPie.cxx index a2a7382321811..06ab95ef02ecf 100644 --- a/graf2d/graf/src/TPie.cxx +++ b/graf2d/graf/src/TPie.cxx @@ -810,6 +810,7 @@ void TPie::Paint(Option_t *option) // "R" Print the labels along the central "R"adius of slices. // "T" Print the label in a direction "T"angent to circle that describes // the TPie. + // "SC" Paint the the labels with the "S"ame "C"olor as the slices. // "3D" Draw the pie-chart with a pseudo 3D effect. // "NOL" No OutLine: Don't draw the slices' outlines, any property over the // slices' line is ignored. @@ -830,6 +831,9 @@ void TPie::Paint(Option_t *option) // if true the lines around the slices are drawn, if false not Bool_t optionLine(kTRUE); + + // if true the labels' colors are the same as the slices' colors + Bool_t optionSameColor(kFALSE); // For the label orientation there are 3 possibilities: // 0: horizontal @@ -849,6 +853,11 @@ void TPie::Paint(Option_t *option) optionLine = kFALSE; soption.Remove(idx,3); } + + if ( (idx=soption.Index("sc"))>=0 ) { + optionSameColor = kTRUE; + soption.Remove(idx,2); + } // check if is active the pseudo-3d if ( (idx=soption.Index("3d"))>=0 ) { @@ -1049,7 +1058,8 @@ void TPie::Paint(Option_t *option) Float_t rphi = TMath::ATan2((ly-fY)*radXY,lx-fX); if (rphi < 0 && fIs3D && label_off>=0.) ly -= fHeight; - + + if (optionSameColor) textlabel->SetTextColor((fPieSlices[i]->GetFillColor())); textlabel->PaintLatex(lx,ly, lblang*180/TMath::Pi()+GetTextAngle(), GetTextSize(), tmptxt.Data()); @@ -1131,57 +1141,57 @@ void TPie::Paint(Option_t *option) //______________________________________________________________________________ -void TPie::SavePrimitive(ostream &out, Option_t *option) +void TPie::SavePrimitive(std::ostream &out, Option_t *option) { // Save primitive as a C++ statement(s) on output stream out - out << " " << endl; + out << " " << std::endl; if (gROOT->ClassSaved(TPie::Class())) { out << " "; } else { out << " TPie *"; } out << GetName() << " = new TPie(\"" << GetName() << "\", \"" << GetTitle() - << "\", " << fNvals << ");" << endl; + << "\", " << fNvals << ");" << std::endl; out << " " << GetName() << "->SetCircle(" << fX << ", " << fY << ", " - << fRadius << ");" << endl; + << fRadius << ");" << std::endl; out << " " << GetName() << "->SetValueFormat(\"" << GetValueFormat() - << "\");" << endl; + << "\");" << std::endl; out << " " << GetName() << "->SetLabelFormat(\"" << GetLabelFormat() - << "\");" << endl; + << "\");" << std::endl; out << " " << GetName() << "->SetPercentFormat(\"" << GetPercentFormat() - << "\");" << endl; + << "\");" << std::endl; out << " " << GetName() << "->SetLabelsOffset(" << GetLabelsOffset() - << ");" << endl; + << ");" << std::endl; out << " " << GetName() << "->SetAngularOffset(" << GetAngularOffset() - << ");" << endl; - out << " " << GetName() << "->SetTextAngle(" << GetTextAngle() << ");" << endl; - out << " " << GetName() << "->SetTextColor(" << GetTextColor() << ");" << endl; - out << " " << GetName() << "->SetTextFont(" << GetTextFont() << ");" << endl; - out << " " << GetName() << "->SetTextSize(" << GetTextSize() << ");" << endl; + << ");" << std::endl; + out << " " << GetName() << "->SetTextAngle(" << GetTextAngle() << ");" << std::endl; + out << " " << GetName() << "->SetTextColor(" << GetTextColor() << ");" << std::endl; + out << " " << GetName() << "->SetTextFont(" << GetTextFont() << ");" << std::endl; + out << " " << GetName() << "->SetTextSize(" << GetTextSize() << ");" << std::endl; // Save the values for the slices for (Int_t i=0;iGetSlice(" << i << ")->SetTitle(\"" - << fPieSlices[i]->GetTitle() << "\");" << endl; + << fPieSlices[i]->GetTitle() << "\");" << std::endl; out << " " << GetName() << "->GetSlice(" << i << ")->SetValue(" - << fPieSlices[i]->GetValue() << ");" << endl; + << fPieSlices[i]->GetValue() << ");" << std::endl; out << " " << GetName() << "->GetSlice(" << i << ")->SetRadiusOffset(" - << fPieSlices[i]->GetRadiusOffset() << ");" << endl; + << fPieSlices[i]->GetRadiusOffset() << ");" << std::endl; out << " " << GetName() << "->GetSlice(" << i << ")->SetFillColor(" - << fPieSlices[i]->GetFillColor() << ");" << endl; + << fPieSlices[i]->GetFillColor() << ");" << std::endl; out << " " << GetName() << "->GetSlice(" << i << ")->SetFillStyle(" - << fPieSlices[i]->GetFillStyle() << ");" << endl; + << fPieSlices[i]->GetFillStyle() << ");" << std::endl; out << " " << GetName() << "->GetSlice(" << i << ")->SetLineColor(" - << fPieSlices[i]->GetLineColor() << ");" << endl; + << fPieSlices[i]->GetLineColor() << ");" << std::endl; out << " " << GetName() << "->GetSlice(" << i << ")->SetLineStyle(" - << fPieSlices[i]->GetLineStyle() << ");" << endl; + << fPieSlices[i]->GetLineStyle() << ");" << std::endl; out << " " << GetName() << "->GetSlice(" << i << ")->SetLineWidth(" - << fPieSlices[i]->GetLineWidth() << ");" << endl; + << fPieSlices[i]->GetLineWidth() << ");" << std::endl; } - out << " " << GetName() << "->Draw(\"" << option << "\");" << endl; + out << " " << GetName() << "->Draw(\"" << option << "\");" << std::endl; } diff --git a/graf2d/graf/src/TTF.cxx b/graf2d/graf/src/TTF.cxx index cf2c7bbd32ffe..47a5289cf5566 100644 --- a/graf2d/graf/src/TTF.cxx +++ b/graf2d/graf/src/TTF.cxx @@ -158,6 +158,22 @@ void TTF::GetTextAdvance(UInt_t &a, char *text) a = GetWidth()>>6; } +//______________________________________________________________________________ +void TTF::GetTextExtent(UInt_t &w, UInt_t &h, wchar_t *text) +{ + // Get width (w) and height (h) when text is horizontal. + + if (!fgInit) Init(); + + SetRotationMatrix(0); + PrepareString(text); + LayoutGlyphs(); + Int_t Xoff = 0; if (fgCBox.xMin < 0) Xoff = -fgCBox.xMin; + Int_t Yoff = 0; if (fgCBox.yMin < 0) Yoff = -fgCBox.yMin; + w = fgCBox.xMax + Xoff + fgTBlankW; + h = fgCBox.yMax + Yoff; +} + //______________________________________________________________________________ void TTF::LayoutGlyphs() { @@ -247,7 +263,45 @@ void TTF::PrepareString(const char *string) glyph++; fgNumGlyphs++; } - if (index == 3) { + if (*p == ' ') { + NbTBlank++; + } else { + NbTBlank = 0; + } + if (fgNumGlyphs >= kMaxGlyphs) break; + p++; + } + + // compute the trailing blanks width. It is use to compute the text + // width in GetTextExtent + if (NbTBlank) { + FT_UInt load_flags = FT_LOAD_DEFAULT; + if (!fgHinting) load_flags |= FT_LOAD_NO_HINTING; + if (FT_Load_Glyph(fgFace[fgCurFontIdx], 3, load_flags)) return; + fgTBlankW = (Int_t)((fgFace[fgCurFontIdx]->glyph->advance.x)>>6)*NbTBlank; + } +} + +//______________________________________________________________________________ +void TTF::PrepareString(const wchar_t *string) +{ + // Put the characters in "string" in the "glyphs" array. + + const wchar_t *p = string; + TTGlyph *glyph = fgGlyphs; + UInt_t index; // Unicode value + Int_t NbTBlank = 0; // number of trailing blanks + + fgTBlankW = 0; + fgNumGlyphs = 0; + while (*p) { + index = FT_Get_Char_Index(fgFace[fgCurFontIdx], (FT_ULong)*p); + if (index != 0) { + glyph->fIndex = index; + glyph++; + fgNumGlyphs++; + } + if (*p == ' ') { NbTBlank++; } else { NbTBlank = 0; @@ -445,30 +499,45 @@ void TTF::SetTextFont(Font_t fontnumber) // Table of Microsoft and (for non-MSFT operating systems) backup // FreeFont TTF fonts. static const char *fonttable[][2] = { - // fontnumber/10 MSFT font Free font - /* 0 */ { "arialbd.ttf", "FreeSansBold.ttf" }, - /* 1 */ { "timesi.ttf", "FreeSerifItalic.ttf" }, - /* 2 */ { "timesbd.ttf", "FreeSerifBold.ttf" }, - /* 3 */ { "timesbi.ttf", "FreeSerifBoldItalic.ttf" }, - /* 4 */ { "arial.ttf", "FreeSans.ttf" }, - /* 5 */ { "ariali.ttf", "FreeSansOblique.ttf" }, - /* 6 */ { "arialbd.ttf", "FreeSansBold.ttf" }, - /* 7 */ { "arialbi.ttf", "FreeSansBoldOblique.ttf" }, - /* 8 */ { "cour.ttf", "FreeMono.ttf" }, - /* 9 */ { "couri.ttf", "FreeMonoOblique.ttf" }, - /*10 */ { "courbd.ttf", "FreeMonoBold.ttf" }, - /*11 */ { "courbi.ttf", "FreeMonoBoldOblique.ttf" }, - /*12 */ { "symbol.ttf", "symbol.ttf" }, - /*13 */ { "times.ttf", "FreeSerif.ttf" }, - /*14 */ { "wingding.ttf", "opens___.ttf" }, - /*15 */ { "symbol.ttf", "symbol.ttf" } + { "Root.TTFont.0", "FreeSansBold.otf" }, + { "Root.TTFont.1", "FreeSerifItalic.otf" }, + { "Root.TTFont.2", "FreeSerifBold.otf" }, + { "Root.TTFont.3", "FreeSerifBoldItalic.otf" }, + { "Root.TTFont.4", "FreeSans.otf" }, + { "Root.TTFont.5", "FreeSansOblique.otf" }, + { "Root.TTFont.6", "FreeSansBold.otf" }, + { "Root.TTFont.7", "FreeSansBoldOblique.otf" }, + { "Root.TTFont.8", "FreeMono.otf" }, + { "Root.TTFont.9", "FreeMonoOblique.otf" }, + { "Root.TTFont.10", "FreeMonoBold.otf" }, + { "Root.TTFont.11", "FreeMonoBoldOblique.otf" }, + { "Root.TTFont.12", "symbol.ttf" }, + { "Root.TTFont.13", "FreeSerif.otf" }, + { "Root.TTFont.14", "wingding.ttf" }, + { "Root.TTFont.15", "symbol.ttf" }, + { "Root.TTFont.STIXGen", "STIXGeneral.otf" }, + { "Root.TTFont.STIXGenIt", "STIXGeneralItalic.otf" }, + { "Root.TTFont.STIXGenBd", "STIXGeneralBol.otf" }, + { "Root.TTFont.STIXGenBdIt", "STIXGeneralBolIta.otf" }, + { "Root.TTFont.STIXSiz1Sym", "STIXSiz1Sym.otf" }, + { "Root.TTFont.STIXSiz1SymBd", "STIXSiz1SymBol.otf" }, + { "Root.TTFont.STIXSiz2Sym", "STIXSiz2Sym.otf" }, + { "Root.TTFont.STIXSiz2SymBd", "STIXSiz2SymBol.otf" }, + { "Root.TTFont.STIXSiz3Sym", "STIXSiz3Sym.otf" }, + { "Root.TTFont.STIXSiz3SymBd", "STIXSiz3SymBol.otf" }, + { "Root.TTFont.STIXSiz4Sym", "STIXSiz4Sym.otf" }, + { "Root.TTFont.STIXSiz4SymBd", "STIXSiz4SymBol.otf" }, + { "Root.TTFont.STIXSiz5Sym", "STIXSiz5Sym.otf" }, + { "Root.TTFont.ME", "DroidSansFallback.ttf" }, + { "Root.TTFont.CJKMing", "DroidSansFallback.ttf" }, + { "Root.TTFont.CJKGothic", "DroidSansFallback.ttf" } }; static int fontset = -1; int thisset = fontset; int fontid = fontnumber / 10; - if (fontid < 0 || fontid > 15) fontid = 0; + if (fontid < 0 || fontid > 31) fontid = 0; if (thisset == -1) { // try to load font (font must be in Root.TTFontPath resource) @@ -480,7 +549,7 @@ void TTF::SetTextFont(Font_t fontnumber) "$(ROOTSYS)/fonts" #endif ); - char *ttfont = gSystem->Which(ttpath, fonttable[fontid][0], kReadPermission); + char *ttfont = gSystem->Which(ttpath, gEnv->GetValue(fonttable[fontid][0], fonttable[fontid][1]), kReadPermission); if (ttfont) { delete [] ttfont; thisset = 0; @@ -491,7 +560,7 @@ void TTF::SetTextFont(Font_t fontnumber) } Int_t italic = 0; if (fontid==15) italic = 1; - int ret = SetTextFont(fonttable[fontid][thisset], italic); + int ret = SetTextFont(gEnv->GetValue(fonttable[fontid][thisset], fonttable[fontid][1]), italic); // Do not define font set is we're loading the symbol.ttf - it's // the same in both cases. if (ret == 0 && fontid != 12) fontset = thisset; diff --git a/graf2d/graf/src/TText.cxx b/graf2d/graf/src/TText.cxx index af20d3e32a9e4..fcebc29df3e43 100644 --- a/graf2d/graf/src/TText.cxx +++ b/graf2d/graf/src/TText.cxx @@ -18,6 +18,8 @@ #include "TMath.h" #include "TPoint.h" #include "TClass.h" +#include +#include ClassImp(TText) @@ -35,7 +37,7 @@ ClassImp(TText) //______________________________________________________________________________ -TText::TText(): TNamed(), TAttText() +TText::TText(): TNamed(), TAttText(), fWcsTitle(NULL) { // Text default constructor. @@ -45,7 +47,7 @@ TText::TText(): TNamed(), TAttText() //______________________________________________________________________________ -TText::TText(Double_t x, Double_t y, const char *text) : TNamed("",text), TAttText() +TText::TText(Double_t x, Double_t y, const char *text) : TNamed("",text), TAttText(), fWcsTitle(NULL) { // Text normal constructor. @@ -54,10 +56,25 @@ TText::TText(Double_t x, Double_t y, const char *text) : TNamed("",text), TAttTe } +//______________________________________________________________________________ +TText::TText(Double_t x, Double_t y, const wchar_t *text) : TAttText() +{ + // Text normal constructor. + + fX = x; + fY = y; + fWcsTitle = new std::wstring(text); + SetName(""); + SetMbTitle(text); +} + + //______________________________________________________________________________ TText::~TText() { // Text default destructor. + + if (fWcsTitle != NULL) delete reinterpret_cast(fWcsTitle); } @@ -81,6 +98,27 @@ void TText::Copy(TObject &obj) const ((TText&)obj).fY = fY; TNamed::Copy(obj); TAttText::Copy(((TText&)obj)); + if (fWcsTitle != NULL) { + *reinterpret_cast(fWcsTitle) = + *reinterpret_cast(((TText&)obj).fWcsTitle); + } else { + dynamic_cast(obj).fWcsTitle = + new std::wstring(*reinterpret_cast( + dynamic_cast(obj).fWcsTitle)); + } +} + + +//______________________________________________________________________________ +const void *TText::GetWcsTitle(void) const +{ + // Returns teh text as UNICODE. + + if (fWcsTitle != NULL) { + return reinterpret_cast(fWcsTitle)->c_str(); + } else { + return NULL; + } } @@ -132,6 +170,20 @@ TText *TText::DrawText(Double_t x, Double_t y, const char *text) } +//______________________________________________________________________________ +TText *TText::DrawText(Double_t x, Double_t y, const wchar_t *text) +{ + // Draw this text with new coordinates. + + TText *newtext = new TText(x, y, text); + TAttText::Copy(*newtext); + newtext->SetBit(kCanDelete); + if (TestBit(kTextNDC)) newtext->SetNDC(); + newtext->AppendPad(); + return newtext; +} + + //______________________________________________________________________________ TText *TText::DrawTextNDC(Double_t x, Double_t y, const char *text) { @@ -143,6 +195,17 @@ TText *TText::DrawTextNDC(Double_t x, Double_t y, const char *text) } +//______________________________________________________________________________ +TText *TText::DrawTextNDC(Double_t x, Double_t y, const wchar_t *text) +{ + // Draw this text with new coordinates in NDC. + + TText *newtext = DrawText(x, y, text); + newtext->SetNDC(); + return newtext; +} + + //______________________________________________________________________________ void TText::ExecuteEvent(Int_t event, Int_t px, Int_t py) { @@ -382,7 +445,7 @@ void TText::GetBoundingBox(UInt_t &w, UInt_t &h, Bool_t angle) w = h = 0; return; } - + if (angle) { Int_t cBoxX[4], cBoxY[4]; Int_t ptx, pty; @@ -446,6 +509,36 @@ void TText::GetTextAscentDescent(UInt_t &a, UInt_t &d, const char *text) const } +//______________________________________________________________________________ +void TText::GetTextAscentDescent(UInt_t &a, UInt_t &d, const wchar_t *text) const +{ + // Return text ascent and descent for string text + // in a return total text ascent + // in d return text descent + + Double_t wh = (Double_t)gPad->XtoPixel(gPad->GetX2()); + Double_t hh = (Double_t)gPad->YtoPixel(gPad->GetY1()); + Double_t tsize; + if (wh < hh) tsize = fTextSize*wh; + else tsize = fTextSize*hh; + + if (gVirtualX->HasTTFonts() || gPad->IsBatch() || gVirtualX->InheritsFrom("TGCocoa")) { + TTF::SetTextFont(fTextFont); + TTF::SetTextSize(tsize); + a = TTF::GetBox().yMax; + d = TMath::Abs(TTF::GetBox().yMin); + } else { + gVirtualX->SetTextSize((int)tsize); + a = gVirtualX->GetFontAscent(); + if (!a) { + UInt_t w; + gVirtualX->GetTextExtent(w, a, (wchar_t*)text); + } + d = gVirtualX->GetFontDescent(); + } +} + + //______________________________________________________________________________ void TText::GetTextExtent(UInt_t &w, UInt_t &h, const char *text) const { @@ -498,6 +591,30 @@ void TText::GetTextAdvance(UInt_t &a, const char *text, const Bool_t kern) const } +//______________________________________________________________________________ +void TText::GetTextExtent(UInt_t &w, UInt_t &h, const wchar_t *text) const +{ + // Return text extent for string text + // in w return total text width + // in h return text height + + Double_t wh = (Double_t)gPad->XtoPixel(gPad->GetX2()); + Double_t hh = (Double_t)gPad->YtoPixel(gPad->GetY1()); + Double_t tsize; + if (wh < hh) tsize = fTextSize*wh; + else tsize = fTextSize*hh; + + if (gVirtualX->HasTTFonts() || gPad->IsBatch() || gVirtualX->InheritsFrom("TGCocoa")) { + TTF::SetTextFont(fTextFont); + TTF::SetTextSize(tsize); + TTF::GetTextExtent(w, h, (wchar_t*)text); + } else { + gVirtualX->SetTextSize((int)tsize); + gVirtualX->GetTextExtent(w, h, (wchar_t*)text); + } +} + + //______________________________________________________________________________ void TText::ls(Option_t *) const { @@ -584,6 +701,16 @@ void TText::PaintText(Double_t x, Double_t y, const char *text) } +//______________________________________________________________________________ +void TText::PaintText(Double_t x, Double_t y, const wchar_t *text) +{ + // Draw this text with new coordinates. + + TAttText::Modify(); //Change text attributes only if necessary + gPad->PaintText(x,y,text); +} + + //______________________________________________________________________________ void TText::PaintTextNDC(Double_t u, Double_t v, const char *text) { @@ -594,6 +721,16 @@ void TText::PaintTextNDC(Double_t u, Double_t v, const char *text) } +//______________________________________________________________________________ +void TText::PaintTextNDC(Double_t u, Double_t v, const wchar_t *text) +{ + // Draw this text with new coordinates in NDC. + + TAttText::Modify(); //Change text attributes only if necessary + gPad->PaintTextNDC(u,v,text); +} + + //______________________________________________________________________________ void TText::Print(Option_t *) const { @@ -608,7 +745,7 @@ void TText::Print(Option_t *) const //______________________________________________________________________________ -void TText::SavePrimitive(ostream &out, Option_t * /*= ""*/) +void TText::SavePrimitive(std::ostream &out, Option_t * /*= ""*/) { // Save primitive as a C++ statement(s) on output stream out @@ -620,12 +757,12 @@ void TText::SavePrimitive(ostream &out, Option_t * /*= ""*/) } TString s = GetTitle(); s.ReplaceAll("\"","\\\""); - out<<"text = new TText("<SetNDC();"<SetNDC();"<Draw();"<Draw();"<= 0) p += n; + } + fTitle = mb_title; + delete [] mb_title; + if (gPad && TestBit(kMustCleanup)) gPad->Modified(); +} + + //______________________________________________________________________________ void TText::Streamer(TBuffer &R__b) { diff --git a/graf2d/gviz/Module.mk b/graf2d/gviz/Module.mk index 1971075eb90d3..b36eaa1ed01b5 100644 --- a/graf2d/gviz/Module.mk +++ b/graf2d/gviz/Module.mk @@ -68,4 +68,4 @@ distclean-$(MODNAME): clean-$(MODNAME) distclean:: distclean-$(MODNAME) ##### extra rules ###### -$(GVIZO): CXXFLAGS += $(GRAPHVIZINCDIR:%=-I%) $(GRAPHVIZCFLAGS) +$(GVIZO) $(GVIZDO): CXXFLAGS += $(GRAPHVIZINCDIR:%=-I%) $(GRAPHVIZCFLAGS) diff --git a/graf2d/gviz/doc/index.txt b/graf2d/gviz/doc/index.txt new file mode 100644 index 0000000000000..cc83ff7eb881a --- /dev/null +++ b/graf2d/gviz/doc/index.txt @@ -0,0 +1,5 @@ +BEGIN_HTML +

    +END_HTML diff --git a/graf2d/gviz/inc/TGraphEdge.h b/graf2d/gviz/inc/TGraphEdge.h index 26764f3450fc9..b766bb4b0831c 100644 --- a/graf2d/gviz/inc/TGraphEdge.h +++ b/graf2d/gviz/inc/TGraphEdge.h @@ -20,8 +20,13 @@ #include "TAttLine.h" #endif +#if !defined(__CINT__) +#include +#else struct Agraph_t; struct Agedge_t; +#endif + class TGraphNode; ////////////////////////////////////////////////////////////////////////// diff --git a/graf2d/gviz/inc/TGraphNode.h b/graf2d/gviz/inc/TGraphNode.h index def3d9bb83796..06ca98d570c2b 100644 --- a/graf2d/gviz/inc/TGraphNode.h +++ b/graf2d/gviz/inc/TGraphNode.h @@ -28,9 +28,12 @@ #include "TAttLine.h" #endif +#if !defined(__CINT__) +#include +#else struct Agraph_t; struct Agnode_t; - +#endif ////////////////////////////////////////////////////////////////////////// // // diff --git a/graf2d/gviz/inc/TGraphStruct.h b/graf2d/gviz/inc/TGraphStruct.h index e3da3256f206c..a7448ae821548 100644 --- a/graf2d/gviz/inc/TGraphStruct.h +++ b/graf2d/gviz/inc/TGraphStruct.h @@ -25,7 +25,12 @@ #include "TList.h" #endif +#if !defined(__CINT__) +#include +#else struct Agraph_t; +#endif + struct GVC_s; ////////////////////////////////////////////////////////////////////////// diff --git a/graf2d/gviz/src/TGraphEdge.cxx b/graf2d/gviz/src/TGraphEdge.cxx index 4b0ee16cda6a8..d86a3eb0320c0 100644 --- a/graf2d/gviz/src/TGraphEdge.cxx +++ b/graf2d/gviz/src/TGraphEdge.cxx @@ -81,7 +81,11 @@ void TGraphEdge::CreateGVEdge(Agraph_t *gv) if (gv) { Agnode_t *n1 = fNode1->GetGVNode(); Agnode_t *n2 = fNode2->GetGVNode(); +#ifdef WITH_CGRAPH + fGVEdge = agedge(gv, n1, n2, NULL, 1); +#else fGVEdge = agedge(gv, n1, n2); +#endif } else { Error("CreateGVEdge","Invalid graphviz graph"); } diff --git a/graf2d/gviz/src/TGraphNode.cxx b/graf2d/gviz/src/TGraphNode.cxx index 7717b3451da1e..3b1852fb1dfe9 100644 --- a/graf2d/gviz/src/TGraphNode.cxx +++ b/graf2d/gviz/src/TGraphNode.cxx @@ -65,7 +65,11 @@ void TGraphNode::CreateGVNode(Agraph_t *gv) // Create the GraphViz node into the GraphViz data structure gv. if (gv) { +#ifdef WITH_CGRAPH + fGVNode = agnode(gv, (char *)GetName(), 1); +#else fGVNode = agnode(gv, (char *)GetName()); +#endif } else { Error("CreateGVNode","Invalid graphviz graph"); } diff --git a/graf2d/gviz/src/TGraphStruct.cxx b/graf2d/gviz/src/TGraphStruct.cxx index 047d5dbbddd2c..c513a1c940f4c 100644 --- a/graf2d/gviz/src/TGraphStruct.cxx +++ b/graf2d/gviz/src/TGraphStruct.cxx @@ -226,7 +226,11 @@ Int_t TGraphStruct::Layout() gvFreeLayout(fGVC,fGVGraph); agclose(fGVGraph); } +#ifdef WITH_CGRAPH + fGVGraph = agopen((char*)"GVGraph", Agdirected, 0); +#else fGVGraph = agopen((char*)"GVGraph", AGDIGRAPH); +#endif // Put the GV nodes into the GV graph if (fNodes) { diff --git a/graf2d/ios/inc/IOSPad.h b/graf2d/ios/inc/IOSPad.h index ea36d2b115648..0ef438cf67fad 100644 --- a/graf2d/ios/inc/IOSPad.h +++ b/graf2d/ios/inc/IOSPad.h @@ -233,6 +233,8 @@ class Pad : public PadStub { void PaintPolyMarker(Int_t n, Float_t *x, Float_t *y, Option_t *option=""); void PaintPolyMarker(Int_t n, Double_t *x, Double_t *y, Option_t *option=""); + using PadStub::PaintText; + using PadStub::PaintTextNDC; void PaintText(Double_t x, Double_t y, const char *text); void PaintTextNDC(Double_t u, Double_t v, const char *text); diff --git a/graf2d/ios/inc/IOSPadStub.h b/graf2d/ios/inc/IOSPadStub.h index c8ac17d2f7344..fb039bad9b156 100644 --- a/graf2d/ios/inc/IOSPadStub.h +++ b/graf2d/ios/inc/IOSPadStub.h @@ -66,6 +66,12 @@ class PadStub : public TVirtualPad { void SetAttMarkerPS(Color_t, Style_t, Size_t); void SetAttTextPS(Int_t, Float_t, Color_t, Style_t, Float_t); void PaintBorderPS(Double_t, Double_t, Double_t, Double_t, Int_t, Int_t, Int_t, Int_t); + //PaintText with a parameter of a type wchar_t is a special version + //used by mathtext. It relies strongly on ttf and actually requires + //ttf. NOOP at the moment (whence it's here, in a 'stub' class). + virtual void PaintText(Double_t, Double_t, const wchar_t *); + virtual void PaintTextNDC(Double_t, Double_t, const wchar_t *); + // Int_t GetGLDevice(); void SetCopyGLDevice(Bool_t); void Pop(); diff --git a/graf2d/ios/src/IOSFillPatterns.cxx b/graf2d/ios/src/IOSFillPatterns.cxx index 0343377bbcbcb..ac032cba12682 100644 --- a/graf2d/ios/src/IOSFillPatterns.cxx +++ b/graf2d/ios/src/IOSFillPatterns.cxx @@ -33,8 +33,8 @@ const unsigned stippleBase = 3000; //______________________________________________________________________________ void draw_pattern_1(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 0.f, 1.f, 1.f)); @@ -42,7 +42,7 @@ void draw_pattern_1(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_1(float *rgb) +CGPatternRef create_pattern_1(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -55,8 +55,8 @@ CGPatternRef create_pattern_1(float *rgb) //______________________________________________________________________________ void draw_pattern_2(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(2.f, 0.f, 1.f, 1.f)); @@ -66,7 +66,7 @@ void draw_pattern_2(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_2(float *rgb) +CGPatternRef create_pattern_2(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -79,8 +79,8 @@ CGPatternRef create_pattern_2(float *rgb) //______________________________________________________________________________ void draw_pattern_3(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 0.f, 1.f, 1.f)); @@ -88,7 +88,7 @@ void draw_pattern_3(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_3(float *rgb) +CGPatternRef create_pattern_3(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -101,8 +101,8 @@ CGPatternRef create_pattern_3(float *rgb) //______________________________________________________________________________ void draw_pattern_4(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 7.f, 1.f, 1.f)); @@ -116,7 +116,7 @@ void draw_pattern_4(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_4(float *rgb) +CGPatternRef create_pattern_4(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -129,8 +129,8 @@ CGPatternRef create_pattern_4(float *rgb) //______________________________________________________________________________ void draw_pattern_5(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 0.f, 1.f, 1.f)); @@ -144,7 +144,7 @@ void draw_pattern_5(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_5(float *rgb) +CGPatternRef create_pattern_5(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -157,8 +157,8 @@ CGPatternRef create_pattern_5(float *rgb) //______________________________________________________________________________ void draw_pattern_6(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(2.f, 0.f, 1.f, 1.f)); @@ -168,7 +168,7 @@ void draw_pattern_6(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_6(float *rgb) +CGPatternRef create_pattern_6(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -181,8 +181,8 @@ CGPatternRef create_pattern_6(float *rgb) //______________________________________________________________________________ void draw_pattern_7(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 1.f, 1.f, 1.f)); @@ -192,7 +192,7 @@ void draw_pattern_7(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_7(float *rgb) +CGPatternRef create_pattern_7(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -205,8 +205,8 @@ CGPatternRef create_pattern_7(float *rgb) //______________________________________________________________________________ void draw_pattern_8(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); //0x11 @@ -257,7 +257,7 @@ void draw_pattern_8(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_8(float *rgb) +CGPatternRef create_pattern_8(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -270,8 +270,8 @@ CGPatternRef create_pattern_8(float *rgb) //______________________________________________________________________________ void draw_pattern_9(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 0.f, 1.f, 1.f)); @@ -298,7 +298,7 @@ void draw_pattern_9(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_9(float *rgb) +CGPatternRef create_pattern_9(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -311,8 +311,8 @@ CGPatternRef create_pattern_9(float *rgb) //______________________________________________________________________________ void draw_pattern_10(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 0.f, 1.f, 1.f)); @@ -344,7 +344,7 @@ void draw_pattern_10(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_10(float *rgb) +CGPatternRef create_pattern_10(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -357,8 +357,8 @@ CGPatternRef create_pattern_10(float *rgb) //______________________________________________________________________________ void draw_pattern_11(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 4.f, 1.f, 1.f)); @@ -400,7 +400,7 @@ void draw_pattern_11(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_11(float *rgb) +CGPatternRef create_pattern_11(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -413,8 +413,8 @@ CGPatternRef create_pattern_11(float *rgb) //______________________________________________________________________________ void draw_pattern_12(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 1.f, 1.f, 1.f)); @@ -459,7 +459,7 @@ void draw_pattern_12(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_12(float *rgb) +CGPatternRef create_pattern_12(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -472,8 +472,8 @@ CGPatternRef create_pattern_12(float *rgb) //______________________________________________________________________________ void draw_pattern_13(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 7.f, 1.f, 1.f)); @@ -500,7 +500,7 @@ void draw_pattern_13(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_13(float *rgb) +CGPatternRef create_pattern_13(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -513,8 +513,8 @@ CGPatternRef create_pattern_13(float *rgb) //______________________________________________________________________________ void draw_pattern_14(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); for (unsigned i = 0; i < 16; ++i) { @@ -535,7 +535,7 @@ void draw_pattern_14(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_14(float *rgb) +CGPatternRef create_pattern_14(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -548,8 +548,8 @@ CGPatternRef create_pattern_14(float *rgb) //______________________________________________________________________________ void draw_pattern_15(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 2.f, 1.f, 1.f)); @@ -578,7 +578,7 @@ void draw_pattern_15(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_15(float *rgb) +CGPatternRef create_pattern_15(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -591,8 +591,8 @@ CGPatternRef create_pattern_15(float *rgb) //______________________________________________________________________________ void draw_pattern_16(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 2.f, 1.f, 1.f)); @@ -617,7 +617,7 @@ void draw_pattern_16(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_16(float *rgb) +CGPatternRef create_pattern_16(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -630,8 +630,8 @@ CGPatternRef create_pattern_16(float *rgb) //______________________________________________________________________________ void draw_pattern_17(void *color, CGContextRef ctx) { - const float *rgb = static_cast(color); - const float alpha = 1.f; + const CGFloat *rgb = static_cast(color); + const CGFloat alpha = 1.f; CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); CGContextFillRect(ctx, CGRectMake(0.f, 3.f, 1.f, 1.f)); @@ -640,7 +640,7 @@ void draw_pattern_17(void *color, CGContextRef ctx) } //______________________________________________________________________________ -CGPatternRef create_pattern_17(float *rgb) +CGPatternRef create_pattern_17(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; @@ -651,7 +651,7 @@ CGPatternRef create_pattern_17(float *rgb) } //______________________________________________________________________________ -CGPatternRef create_pattern_18(float *rgb) +CGPatternRef create_pattern_18(CGFloat *rgb) { CGPatternCallbacks patternCallbacks; patternCallbacks.version = 0; diff --git a/graf2d/ios/src/IOSPadStub.cxx b/graf2d/ios/src/IOSPadStub.cxx index a3ea40b2dff3e..692e5e2dbf5b7 100644 --- a/graf2d/ios/src/IOSPadStub.cxx +++ b/graf2d/ios/src/IOSPadStub.cxx @@ -191,6 +191,16 @@ void PadStub::SetAttTextPS(Int_t, Float_t, Color_t, Style_t, Float_t) { } +//______________________________________________________________________________ +void PadStub::PaintText(Double_t, Double_t, const wchar_t *) +{ +} + +//______________________________________________________________________________ +void PadStub::PaintTextNDC(Double_t, Double_t, const wchar_t *) +{ +} + //______________________________________________________________________________ void PadStub::PaintBorderPS(Double_t, Double_t, Double_t, Double_t, Int_t, Int_t, Int_t, Int_t) { diff --git a/graf2d/mathtext/CMakeLists.txt b/graf2d/mathtext/CMakeLists.txt new file mode 100644 index 0000000000000..8f87b998e3a45 --- /dev/null +++ b/graf2d/mathtext/CMakeLists.txt @@ -0,0 +1 @@ +ROOT_LINKER_LIBRARY(mathtext *.cxx TYPE STATIC) diff --git a/graf2d/mathtext/Module.mk b/graf2d/mathtext/Module.mk new file mode 100644 index 0000000000000..77c1929bc5e12 --- /dev/null +++ b/graf2d/mathtext/Module.mk @@ -0,0 +1,63 @@ +# Module.mk for mathtex module +# Copyright (c) 2012 Rene Brun and Fons Rademakers +# +# Author: Olivier Couet, 30/10/2012 + +MODNAME := mathtext +MODDIR := $(ROOT_SRCDIR)/graf2d/$(MODNAME) +MODDIRS := $(MODDIR)/src +MODDIRI := $(MODDIR)/inc + +MATHTEXTDIR := $(MODDIR) +MATHTEXTDIRS := $(MATHTEXTDIR)/src +MATHTEXTDIRI := $(MATHTEXTDIR)/inc + +##### libmathtext ##### +MATHTEXTH := $(filter-out $(MODDIRI)/LinkDef%,$(wildcard $(MODDIRI)/*.h)) +MATHTEXTS := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx)) +MATHTEXTO := $(call stripsrc,$(MATHTEXTS:.cxx=.o)) + +MATHTEXTDEP := $(MATHTEXTO:.o=.d) + +ifeq ($(PLATFORM),win32) +MATHTEXTLIB := $(LPATH)/libmathtext.lib +MATHTEXTAR := link.exe -lib /out: +else +MATHTEXTLIB := $(LPATH)/libmathtext.a +MATHTEXTAR := $(AR) cru +endif + +MATHTEXTLIBDEP := $(MATHTEXTLIB) + +# used in the main Makefile +ALLHDRS += $(patsubst $(MODDIRI)/%.h,include/%.h,$(MATHTEXTH)) +ALLLIBS += $(MATHTEXTLIB) + +# include all dependency files +INCLUDEFILES += $(MATHTEXTDEP) + +##### local rules ##### +.PHONY: all-$(MODNAME) clean-$(MODNAME) distclean-$(MODNAME) + +include/%.h: $(MATHTEXTDIRI)/%.h + cp $< $@ + +$(MATHTEXTLIB): $(MATHTEXTO) + $(MATHTEXTAR)$@ $(MATHTEXTO) + @(if [ $(PLATFORM) = "macosx" ]; then \ + ranlib $@; \ + fi) + +all-$(MODNAME): $(MATHTEXTLIB) + +clean-$(MODNAME): + @rm -f $(MATHTEXTO) + +clean:: clean-$(MODNAME) + +distclean-$(MODNAME): clean-$(MODNAME) + @rm -f $(MATHTEXTDEP) $(MATHTEXTLIB) + +distclean:: distclean-$(MODNAME) + +##### extra rules ###### diff --git a/graf2d/mathtext/inc/fontembed.h b/graf2d/mathtext/inc/fontembed.h new file mode 100644 index 0000000000000..9318dbf404681 --- /dev/null +++ b/graf2d/mathtext/inc/fontembed.h @@ -0,0 +1,122 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +#ifdef _MSC_VER +// Visual C++ 2008 doesn't have stdint.h +typedef __int8 int8_t; +typedef __int16 int16_t; +typedef __int32 int32_t; +typedef __int64 int64_t; +typedef unsigned __int8 uint8_t; +typedef unsigned __int16 uint16_t; +typedef unsigned __int32 uint32_t; +typedef unsigned __int64 uint64_t; +#else +#include +#endif +#include +#include +#include +#include + +namespace mathtext { + + class font_embed_t { + private: + struct table_data_s { + char tag[4]; + std::vector data; + }; + static void subset_rename_otf_name_table( + struct table_data_s &table_data, uint8_t *glyph_usage); + static void subset_ttf_glyf_table( + struct table_data_s &table_data, uint8_t *glyph_usage); + static void subset_ttf_loca_table( + struct table_data_s &table_data, uint8_t *glyph_usage); + static void subset_ttf_post_table( + struct table_data_s &table_data, uint8_t *glyph_usage); + static void subset_otf_cff_table( + struct table_data_s &table_data, uint8_t *glyph_usage); + static void parse_ttf_encoding_subtable_format4( + std::map &cid_map, + const std::vector &font_data, + const size_t offset, const uint16_t length); + static unsigned int otf_check_sum( + const std::vector &table_data); + public: + // I/O + static std::vector read_font_data(FILE *); + static std::vector read_font_data(const std::string &filename); + // Font parsing + static bool parse_otf_cff_header( + std::string &font_name, unsigned short &cid_encoding_id, + unsigned int &cff_offset, unsigned int &cff_length, + const std::vector &font_data); + static bool parse_ttf_header( + std::string &font_name, double *font_bbox, + std::map &cid_map, + std::vector &char_strings, + const std::vector &font_data); + // Font subsetting + static std::vector subset_otf( + const std::vector &font_data, + const std::map &glyph_usage); + }; + + class font_embed_postscript_t : public font_embed_t { + public: + static void append_asciihex( + std::string &ascii, const uint8_t *buffer, + const size_t length); + static unsigned int ascii85_line_count( + const uint8_t *buffer, const size_t length); + static void append_ascii85( + std::string &ascii, const uint8_t *buffer, + const size_t length); + public: + static std::string font_embed_type_1( + std::string &font_name, + const std::vector &font_data); + static std::string font_embed_type_2( + std::string &font_name, + const std::vector &font_data); + static std::string font_embed_type_42( + std::string &font_name, + const std::vector &font_data); + }; + + class font_embed_pdf_t : public font_embed_t { + public: + static std::string font_embed_type_1( + std::string &font_name, + const std::vector &font_data); + static std::string font_embed_type_2( + std::string &font_name, + const std::vector &font_data); + static std::string font_embed_type_42( + std::string &font_name, + const std::vector &font_data); + }; + + class font_embed_svg_t : public font_embed_t { + static std::string font_embed_svg( + std::string &font_name, + const std::vector &font_data); + }; + +} diff --git a/graf2d/mathtext/inc/mathrender.h b/graf2d/mathtext/inc/mathrender.h new file mode 100644 index 0000000000000..fb314319bbbfc --- /dev/null +++ b/graf2d/mathtext/inc/mathrender.h @@ -0,0 +1,888 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +#ifndef MATHRENDER_H_ +#define MATHRENDER_H_ + +#ifdef _MSC_VER +// Visual C++ 2008 doesn't have stdint.h +typedef __int8 int8_t; +typedef __int16 int16_t; +typedef __int32 int32_t; +typedef __int64 int64_t; +typedef unsigned __int8 uint8_t; +typedef unsigned __int16 uint16_t; +typedef unsigned __int32 uint32_t; +typedef unsigned __int64 uint64_t; +#else +#include +#endif +#include +#include +#include +#include "mathtext.h" + +namespace mathtext { + + /** + * 2D point (and vector) + */ + class point_t { + private: + float _x[2]; + public: + inline point_t(void) : _x() + { + } + inline point_t(const point_t &point) + { + _x[0] = point._x[0]; + _x[1] = point._x[1]; + } + inline point_t(const float x0, const float y0) + { + _x[0] = x0; + _x[1] = y0; + } + inline const float *x(void) const + { + return _x; + } + inline float *x(void) + { + return _x; + } + inline float operator[](const int n) const + { + return _x[n]; + } + inline float &operator[](const int n) + { + return _x[n]; + } + inline point_t operator+(const point_t &point) const + { + return point_t(_x[0] + point._x[0], + _x[1] + point._x[1]); + } + inline point_t operator-(const point_t &point) const + { + return point_t(_x[0] - point._x[0], + _x[1] - point._x[1]); + } + inline point_t operator+=(const point_t &point) + { + _x[0] += point._x[0]; + _x[1] += point._x[1]; + + return *this; + } + inline point_t operator-=(const point_t &point) + { + _x[0] -= point._x[0]; + _x[1] -= point._x[1]; + + return *this; + } + inline point_t operator*(const float scale) const + { + return point_t(_x[0] * scale, _x[1] * scale); + } + inline point_t operator/(const float scale) const + { + return point_t(_x[0] / scale, _x[1] / scale); + } + inline point_t operator*=(const float scale) + { + _x[0] *= scale; + _x[1] *= scale; + + return *this; + } + inline float dot(const point_t &point) const + { + return _x[0] * point._x[0] + _x[1] * point._x[1]; + } + inline float cross(const point_t &point) const + { + return _x[0] * point._x[1] - _x[1] * point._x[0]; + } + inline float norm_square(void) const + { + return _x[0] * _x[0] + _x[1] * _x[1]; + } + inline float norm(void) const + { + return sqrtf(norm_square()); + } + inline point_t unit_vector(void) const + { + return *this / norm(); + } + inline point_t rotate_cw(void) const + { + return point_t(_x[1], -_x[0]); + } + inline point_t rotate_ccw(void) const + { + return point_t(-_x[1], _x[0]); + } + inline bool operator==(const point_t &point) const + { + return _x[0] == point._x[0] && _x[1] == point._x[1]; + } + inline bool operator!=(const point_t &point) const + { + return _x[0] != point._x[0] || _x[1] != point._x[1]; + } + friend point_t operator*(const float scale, + const point_t &point); + operator std::string(void) const; + }; + + inline point_t operator*(const float scale, const point_t &point) + { + return point_t(scale * point._x[0], scale * point._x[1]); + } + + /** + * General 2D affine transform of the Adobe Imaging Model + * + * The n-D affine transform is generally represented by + * + * ( xt ) ( a0 a1 a2 ) ( x ) + * ( yt ) = ( a3 a4 a5 ) ( y ) + * ( 1 ) ( 0 0 1 ) ( 1 ) + * + * with (a0, a1, a3, a4) representing the linear component of the + * transform, i.e. rotation and scaling, while (a2, a5) is the + * translation vector + * + * @see Adobe Systems, Inc., PostScript Language Reference Manual + * (Addison-Wesley, Reading, MA, 1999), section 4.3.3, pp. + * 187-189. + * @see Adobe Systems, Inc., PDF Reference, 6th Edition, Version + * 1.7 (Adobe Systems, Inc., San Jose, CA, 2006), section + * 4.2.2-4.2.3, pp. 204-209. + */ + class affine_transform_t { + private: + float _a[6]; + public: + static const affine_transform_t identity; + static const affine_transform_t flip_y; + static affine_transform_t + translate(const float tx, const float ty); + static affine_transform_t + scale(const float sx, const float sy); + static affine_transform_t rotate(const float angle); + inline affine_transform_t( + const float a0, const float b, const float c, + const float d, const float tx, const float ty) + { + _a[0] = a0; + _a[1] = b; + _a[2] = c; + _a[3] = d; + _a[4] = tx; + _a[5] = ty; + } + inline const float *a(void) const + { + return _a; + } + inline float *a(void) + { + return _a; + } + inline float operator[](const int n) const + { + return _a[n]; + } + inline float &operator[](const int n) + { + return _a[n]; + } + inline affine_transform_t linear(void) const + { + return affine_transform_t( + _a[0], _a[1], _a[2], _a[3], 0.0F, 0.0F); + } + inline affine_transform_t translate(void) const + { + return affine_transform_t( + 1.0F, 0.0F, 0.0F, 1.0F, _a[4], _a[5]); + } + inline affine_transform_t operator*(const float s) const + { + return affine_transform_t( + _a[0] * s, _a[1] * s, _a[2] * s, _a[3] * s, + _a[4] * s, _a[5] * s); + } + inline affine_transform_t operator/(const float s) const + { + return affine_transform_t( + _a[0] / s, _a[1] / s, _a[2] / s, _a[3] / s, + _a[4] / s, _a[5] / s); + } + inline point_t operator*(const point_t x) const + { + return point_t( + _a[0] * x[0] + _a[2] * x[1] + _a[4], + _a[1] * x[0] + _a[3] * x[1] + _a[5]); + } + /** + * Returns the affine transform of b, i.e. the matrix-vector + * product (*this) (b^T, 1)^T, of the vector b + * + * @returns the affine transform of the vector b + */ + inline affine_transform_t + operator*(const affine_transform_t b) const + { + return affine_transform_t( + _a[0] * b._a[0] + _a[1] * b._a[2], + _a[0] * b._a[1] + _a[1] * b._a[3], + _a[2] * b._a[0] + _a[3] * b._a[2], + _a[2] * b._a[1] + _a[3] * b._a[3], + _a[4] * b._a[0] + _a[5] * b._a[2] + b._a[4], + _a[4] * b._a[1] + _a[5] * b._a[3] + b._a[5]); + } + /** + * Returns the determinant det(*this) of the affine transform + * + * @returns the determinant det(*this) of the affine transform + */ + inline float determinant(void) const + { + return _a[0] * _a[3] - _a[1] * _a[2]; + } + /** + * Returns the determinant (*this)^(-1) of the affine + * transform + * + * @returns the determinant (*this)^(-1) of the affine + * transform + */ + inline affine_transform_t inverse(void) const + { + return affine_transform_t( + _a[3], -_a[1], -_a[2], _a[0], + _a[2] * _a[5] - _a[3] * _a[4], + _a[1] * _a[4] - _a[0] * _a[5]) * + (1.0F / determinant()); + } + operator std::string(void) const; + }; + + /** + * General TeX bounding box + */ + // FIXME: The skewchar mechanism is missing + class bounding_box_t { + private: + point_t _lower_left; + point_t _upper_right; + float _advance; + float _italic_correction; + public: + inline bounding_box_t(void) : _lower_left(), _upper_right(), _advance(), _italic_correction() + { + } + inline bounding_box_t( + const point_t lower_left_0, const point_t upper_right_0, + const float advance_0, const float italic_correction_0) + : _lower_left(lower_left_0), _upper_right(upper_right_0), + _advance(advance_0), + _italic_correction(italic_correction_0) + { + } + inline bounding_box_t( + const float left_0, const float bottom_0, const float right_0, + const float top_0, const float advance_0, + const float italic_correction_0) + : _advance(advance_0), + _italic_correction(italic_correction_0) + { + _lower_left[0] = left_0; + _lower_left[1] = bottom_0; + _upper_right[0] = right_0; + _upper_right[1] = top_0; + } + inline point_t lower_left(void) const + { + return _lower_left; + } + inline point_t &lower_left(void) + { + return _lower_left; + } + inline point_t upper_right(void) const + { + return _upper_right; + } + inline point_t &upper_right(void) + { + return _upper_right; + } + inline float left(void) const + { + return _lower_left[0]; + } + inline float &left(void) + { + return _lower_left[0]; + } + inline float top(void) const + { + return _upper_right[1]; + } + inline float &top(void) + { + return _upper_right[1]; + } + inline float right(void) const + { + return _upper_right[0]; + } + inline float &right(void) + { + return _upper_right[0]; + } + inline float bottom(void) const + { + return _lower_left[1]; + } + inline float &bottom(void) + { + return _lower_left[1]; + } + inline float advance(void) const + { + return _advance; + } + inline float &advance(void) + { + return _advance; + } + inline float italic_correction(void) const + { + return _italic_correction; + } + inline float &italic_correction(void) + { + return _italic_correction; + } + inline float width(void) const + { + return _upper_right[0] - _lower_left[0]; + } + inline float height(void) const + { + return _upper_right[1] - _lower_left[1]; + } + inline float horizontal_center(void) const + { + return 0.5F * (_lower_left[0] + _upper_right[0]); + } + inline float vertical_center(void) const + { + return 0.5F * (_lower_left[1] + _upper_right[1]); + } + inline float ascent(void) const + { + return _upper_right[1]; + } + inline float descent(void) const + { + return -_lower_left[1]; + } + inline bounding_box_t + merge(const bounding_box_t &bounding_box) const + { + bounding_box_t ret; + + ret._lower_left[0] = + std::min(_lower_left[0], + bounding_box._lower_left[0]); + ret._lower_left[1] = + std::min(_lower_left[1], + bounding_box._lower_left[1]); + if(bounding_box._upper_right[0] > _upper_right[0]) { + ret._upper_right[0] = bounding_box._upper_right[0]; + ret._italic_correction = + bounding_box._italic_correction; + } + else { + ret._upper_right[0] = _upper_right[0]; + ret._italic_correction = _italic_correction; + } + ret._upper_right[1] = + std::max(_upper_right[1], + bounding_box._upper_right[1]); + ret._advance = + std::max(_upper_right[0] + _advance, + bounding_box._upper_right[0] + + bounding_box._advance) - + ret._upper_right[0]; + + return ret; + } + inline bounding_box_t operator+(const point_t &point) const + { + return bounding_box_t( + _lower_left + point, _upper_right + point, + _advance + point[0], _italic_correction); + } + inline bounding_box_t operator-(const point_t &point) const + { + return bounding_box_t( + _lower_left - point, _upper_right - point, + _advance - point[0], _italic_correction); + } + inline bounding_box_t operator+=(const point_t &point) + { + _lower_left += point; + _upper_right += point; + _advance += point[0]; + + return *this; + } + inline bounding_box_t operator-=(const point_t &point) + { + _lower_left -= point; + _upper_right -= point; + _advance -= point[0]; + + return *this; + } + inline bounding_box_t operator*(const float scale) const + { + return bounding_box_t( + _lower_left * scale, _upper_right * scale, + _advance * scale, _italic_correction * scale); + } + inline bounding_box_t operator*=(const float scale) + { + _lower_left *= scale; + _upper_right *= scale; + _advance *= scale; + _italic_correction *= scale; + + return *this; + } + friend bounding_box_t + operator+(const point_t &, const bounding_box_t &); + friend bounding_box_t + operator-(const point_t &, const bounding_box_t &); + friend bounding_box_t + operator*(const affine_transform_t &, + const bounding_box_t &); + }; + + inline bounding_box_t + operator+(const point_t &point, + const bounding_box_t &bounding_box) + { + return bounding_box_t( + point + bounding_box._lower_left, + point + bounding_box._upper_right, + point[0] + bounding_box._advance, + bounding_box._italic_correction); + } + + inline bounding_box_t + operator-(const point_t &point, + const bounding_box_t &bounding_box) + { + return bounding_box_t( + point - bounding_box._lower_left, + point - bounding_box._upper_right, + point[0] + bounding_box._advance, + bounding_box._italic_correction); + } + + inline bounding_box_t + operator*(const affine_transform_t &transform, + const bounding_box_t &bounding_box) + { + return bounding_box_t( + transform * bounding_box._lower_left, + transform * bounding_box._upper_right, + (transform * point_t(bounding_box._advance, 0))[0], + (transform * point_t( + bounding_box._italic_correction, 0))[0]); + } + +#ifdef __INTEL_COMPILER +#pragma warning(push) +#pragma warning(disable: 869) +#endif // __INTEL_COMPILER + /** + * Mathematical layout engine for formulae represented by + * math_text_t + * + * The class math_text_renderer_t is a layout engine based on + * TeX's conversion algorithm from a math list to a horizontal + * list. + * + * @see ISO/IEC JTC1/SC2/WG2, ISO/IEC 10646:2003/Amd.2:2006 (ISO, + * Geneva, 2006). + * @see D. E. Knuth, The TeXbook (Addision-Wesley, Cambridge, MA, + * 1986). + * @see D. E. Knuth, The METAFONTbook (Addision-Wesley, Cambridge, + * MA, 1986). + * @see W. Schmidt, The macro package lucimatx (2005), + * unpublished. + * @see W. Schmidt, Using the MathTime Professional II fonts with + * LaTeX (2006), unpublished. + * @see B. Beeton, A. Freytag, M. Sargent III, Unicode support for + * mathematics, Unicode Technical Report #25 + * @author Yue Shi Lai + * @version 1.0 + */ + class math_text_renderer_t { + public: + enum { + DIRECTION_LEFT_TO_RIGHT = 0, + DIRECTION_RIGHT_TO_LEFT, + DIRECTION_TOP_TO_BOTTOM + }; + enum { + MATH_STYLE_LATIN = 0, + MATH_STYLE_MAGHREB + }; + enum { + FAMILY_PLAIN = 0, + FAMILY_REGULAR, + FAMILY_ITALIC, + FAMILY_BOLD, + FAMILY_BOLD_ITALIC, + FAMILY_STIX_REGULAR, + FAMILY_STIX_ITALIC, + FAMILY_STIX_BOLD, + FAMILY_STIX_BOLD_ITALIC, + FAMILY_STIX_SIZE_1_REGULAR, + FAMILY_STIX_SIZE_1_BOLD, + FAMILY_STIX_SIZE_2_REGULAR, + FAMILY_STIX_SIZE_2_BOLD, + FAMILY_STIX_SIZE_3_REGULAR, + FAMILY_STIX_SIZE_3_BOLD, + FAMILY_STIX_SIZE_4_REGULAR, + FAMILY_STIX_SIZE_4_BOLD, + FAMILY_STIX_SIZE_5_REGULAR, + NFAMILY + }; + private: + ///////////////////////////////////////////////////////////// + // Font parameter + static const float script_ratio; + static const float script_script_ratio; + static const float thin_mu_skip; + static const float med_mu_skip; + static const float thick_mu_skip; + static const float delimiter_factor; + static const float delimiter_shortfall; + ///////////////////////////////////////////////////////////// + static const float num_1; + static const float num_2; + static const float num_3; + static const float denom_1; + static const float denom_2; + static const float sup_1; + static const float sup_2; + static const float sup_3; + static const float sub_1; + static const float sub_2; + static const float sup_drop; + static const float sub_drop; + static const float delim_1; + static const float delim_2; + static const float axis_height; + static const float default_rule_thickness; + static const float big_op_spacing_1; + static const float big_op_spacing_2; + static const float big_op_spacing_3; + static const float big_op_spacing_4; + static const float big_op_spacing_5; + ///////////////////////////////////////////////////////////// + static const float radical_rule_thickness; + static const float large_operator_display_scale; + ///////////////////////////////////////////////////////////// + static const float baselineskip_factor; + ///////////////////////////////////////////////////////////// + // Token + class math_token_t { + public: + point_t _offset; + bounding_box_t _bounding_box; + struct extension_t { + wchar_t _glyph; + unsigned int _family; + float _size; + }; + union { + unsigned int _style; + extension_t _extensible; + }; + float _delimiter_height; + inline math_token_t( + const bounding_box_t bounding_box, + const unsigned int style, + const float delimiter_height = 0.0F) + : _offset(0, 0), _bounding_box(bounding_box), + _style(style), _delimiter_height(delimiter_height) + { + } + inline math_token_t( + const point_t offset, + const bounding_box_t bounding_box, + const unsigned int style, + const float delimiter_height = 0.0F) + : _offset(offset), _bounding_box(bounding_box), + _style(style), _delimiter_height(delimiter_height) + { + } + inline math_token_t( + const bounding_box_t bounding_box, + const wchar_t glyph, const unsigned int family, + const float size) + : _offset(0, 0), _bounding_box(bounding_box), + _delimiter_height(0.0F) + { + _extensible._glyph = glyph; + _extensible._family = family; + _extensible._size = size; + } + inline math_token_t( + const point_t offset, + const bounding_box_t bounding_box, + const wchar_t glyph, const unsigned int family, + const float size) + : _offset(offset), _bounding_box(bounding_box), + _delimiter_height(0.0F) + { + _extensible._glyph = glyph; + _extensible._family = family; + _extensible._size = size; + } + }; + ///////////////////////////////////////////////////////////// + // Style test and change + float style_size(const unsigned int style) const; + bool is_display_style(const unsigned int style) const; + bool is_script_style(const unsigned int style) const; + unsigned int prime_style(const unsigned int style) const; + bool is_prime_style(const unsigned int style) const; + template + inline value_t + if_else_display(const unsigned int style, + const value_t display_value, + const value_t otherwise_value) const + { + switch(style) { + case math_text_t::item_t::STYLE_DISPLAY: + case math_text_t::item_t::STYLE_DISPLAY_PRIME: + return display_value; + default: + return otherwise_value; + } + } + unsigned int next_superscript_style(const unsigned int style) + const; + unsigned int next_subscript_style(const unsigned int style) + const; + unsigned int next_numerator_style(const unsigned int style) + const; + unsigned int next_denominator_style(const unsigned int style) + const; + ///////////////////////////////////////////////////////////// + float x_height(const unsigned int style); + float quad(const unsigned int style) const; + unsigned int + math_family(const math_text_t::math_symbol_t &math_symbol) + const; + void post_process_atom_type_initial(unsigned int &atom_type) + const; + void post_process_atom_type_interior( + unsigned int &previous_atom_type, + unsigned int &atom_type) + const; + bool valid_accent( + bool &vertical_alignment, + const std::vector::const_iterator & + iterator, + const std::vector::const_iterator & + math_list_end) const; + float kerning_mu(float amount) const; + float math_spacing( + unsigned int left_type, unsigned int right_type, + unsigned int style) const; + protected: + inline virtual affine_transform_t + transform_logical_to_pixel(void) const = 0; + virtual affine_transform_t + transform_pixel_to_logical(void) const = 0; + ///////////////////////////////////////////////////////////// + // Box rendering + bounding_box_t math_bounding_box( + const math_text_t::box_t &box, const unsigned int style); + void math_text( + const point_t origin, const math_text_t::box_t &box, + const unsigned int style, const bool render_structure); + ///////////////////////////////////////////////////////////// + // Symbol rendering + static bool is_wgl_4(const wchar_t c); + static bool is_left_to_right(const wchar_t c); + static bool is_right_to_left(const wchar_t c); + static bool is_top_to_bottom(const wchar_t c); + static bool is_cyrillic(const wchar_t c); + static bool is_cjk(const wchar_t c); + static bool is_cjk_punctuation_open(const wchar_t c); + static bool is_cjk_punctuation_closed(const wchar_t c); + bounding_box_t math_bounding_box( + const wchar_t &glyph, const unsigned int family, + const float size); + void math_text( + const point_t origin, const wchar_t &glyph, + const unsigned int family, const float size, + const bool render_structure); + bounding_box_t math_bounding_box( + const math_text_t::math_symbol_t &math_symbol, + const unsigned int style); + void math_text( + const point_t origin, + const math_text_t::math_symbol_t &math_symbol, + const unsigned int style, const bool render_structure); + ///////////////////////////////////////////////////////////// + // Extensible glyph rendering + void large_family( + unsigned long &nfamily, const unsigned int *&family, + const math_text_t::math_symbol_t &math_symbol) const; + void extensible_glyph( + wchar_t glyph[4], unsigned long &nrepeat, + const math_text_t::math_symbol_t &math_symbol, + const unsigned int style, const float height); + std::vector math_tokenize( + const math_text_t::math_symbol_t &math_symbol, + const unsigned int style, const float height); + bounding_box_t math_bounding_box( + const math_text_t::math_symbol_t &math_symbol, + const unsigned int style, const float height); + void math_text( + const point_t origin, + const math_text_t::math_symbol_t &math_symbol, + const unsigned int style, const float height, + const bool render_structure); + ///////////////////////////////////////////////////////////// + // Math list rendering + std::vector math_tokenize( + const std::vector::const_iterator & + math_list_begin, + const std::vector::const_iterator & + math_list_end, + unsigned int style); + bounding_box_t math_bounding_box( + const std::vector::const_iterator & + math_list_begin, + const std::vector::const_iterator & + math_list_end, + unsigned int style); + void math_text( + const point_t origin, + const std::vector::const_iterator & + math_list_begin, + const std::vector::const_iterator & + math_list_end, + const unsigned int style, const bool render_structure); + ///////////////////////////////////////////////////////////// + // Field rendering + bounding_box_t math_bounding_box( + const math_text_t::field_t &field, + const unsigned int style); + void math_text( + const point_t origin, const math_text_t::field_t &field, + const unsigned int style, const bool render_structure); + ///////////////////////////////////////////////////////////// + // Atom rendering + std::vector math_tokenize( + const math_text_t::atom_t &atom, unsigned int style); + bounding_box_t math_bounding_box( + const math_text_t::atom_t &atom, + const unsigned int style); + void math_text( + const point_t origin, const math_text_t::atom_t &atom, + const unsigned int style, const bool render_structure); + ///////////////////////////////////////////////////////////// + public: + ///////////////////////////////////////////////////////////// + // Constructor and destructor + inline math_text_renderer_t(void) + { + } + inline virtual ~math_text_renderer_t(void) + { + } + ///////////////////////////////////////////////////////////// + // Virtual functions + virtual float font_size( + const unsigned int family = FAMILY_PLAIN) const = 0; + virtual void set_font_size( + const float size, const unsigned int family) = 0; + inline virtual void set_font_size(const float size) = 0; + virtual void reset_font_size( + const unsigned int family) = 0; + virtual void point(const float x, const float y) = 0; + virtual void filled_rectangle( + const bounding_box_t &bounding_box) = 0; + virtual void rectangle( + const bounding_box_t &bounding_box) = 0; + virtual bounding_box_t bounding_box( + const std::wstring string, + const unsigned int family = FAMILY_PLAIN) = 0; + virtual void text_raw( + const float x, const float y, const std::wstring string, + const unsigned int family = FAMILY_PLAIN) = 0; + virtual void text_with_bounding_box( + const float x, const float y, const std::wstring string, + const unsigned int family = FAMILY_PLAIN) = 0; + ///////////////////////////////////////////////////////////// + // Interface + bounding_box_t bounding_box( + const math_text_t &math_text, + const bool display_style = false); + void text( + const float x, const float y, + const math_text_t &math_text, + const bool display_style = false); + ///////////////////////////////////////////////////////////// + inline float default_axis_height( + const bool /*display_style = false*/) const + { + return axis_height * style_size( + math_text_t::item_t::STYLE_TEXT); + } + ///////////////////////////////////////////////////////////// + }; +#ifdef __INTEL_COMPILER +#pragma warning(pop) +#endif // __INTEL_COMPILER + +} + +#endif // MATHRENDER_H_ diff --git a/graf2d/mathtext/inc/mathtext.h b/graf2d/mathtext/inc/mathtext.h new file mode 100644 index 0000000000000..88625eb455214 --- /dev/null +++ b/graf2d/mathtext/inc/mathtext.h @@ -0,0 +1,512 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +#ifndef MATHTEXT_H_ +#define MATHTEXT_H_ + +#include + +namespace mathtext { + + class surface_t; + + /** + * Hierarchical representation of mathematical formulae + * + * The class math_text_t is a hierarchical representation of + * mathematical formulae similar to TeX's math list. + * + * Limitations: + * + * - Only (spacing) symbols and combining diacritical marks from + * TeX, AMS-TeX, LaTeX, AMS-LaTeX, and MathTime Professional II + * that are representable within ISO/IEC 10646:2003/Amd.2:2006 + * Universal Character Set can be accessed. + * + * - Illegal TeX syntax may result in not well defined behaviors. + * Most notably, `a^b^c' or `a_b_c' result in `a^c' and `a_c', + * i.e. the overwriting of the previous superscripts and + * subscripts, and `a \atop b \atop c' or `a \over b \over c' + * result in `a \atop {b \atop c}' and `a \over {b \over c}', i.e. + * a right associative interpretation. + * + * @see ISO/IEC JTC1/SC2/WG2, ISO/IEC 10646:2003/Amd.2:2006 (ISO, + * Geneva, 2006). + * @see D. E. Knuth, The TeXbook (Addision-Wesley, Cambridge, MA, + * 1986). + * @see D. E. Knuth, The METAFONTbook (Addision-Wesley, Cambridge, + * MA, 1986). + * @see B. Beeton, A. Freytag, M. Sargent III, Unicode support for + * mathematics, Unicode Technical Report #25 + * @author Yue Shi Lai + * @version 1.0 + */ + class math_text_t { + private: + /** + * Mathematical symbol + * + * The class math_symbol_t represents all (spacing) symbols + * and combining diacritical marks representable within + * ISO/IEC 10646:2003/Amd.2:2006 Universal Character Set from + * TeX, AMS-TeX, LaTeX, AMS-LaTeX, and MathTime Professional + * II. + * + * @author Yue Shi Lai + * @version 1.0 + */ + class math_symbol_t { + public: + enum { + FAMILY_PLAIN = 0, + // Math fonts start + FAMILY_REGULAR, + FAMILY_ITALIC, + FAMILY_BOLD, + FAMILY_BOLD_ITALIC, + FAMILY_STIX_REGULAR, + FAMILY_STIX_ITALIC, + FAMILY_STIX_BOLD, + FAMILY_STIX_BOLD_ITALIC, + FAMILY_STIX_SIZE_1_REGULAR, + FAMILY_STIX_SIZE_1_BOLD, + FAMILY_STIX_SIZE_2_REGULAR, + FAMILY_STIX_SIZE_2_BOLD, + FAMILY_STIX_SIZE_3_REGULAR, + FAMILY_STIX_SIZE_3_BOLD, + FAMILY_STIX_SIZE_4_REGULAR, + FAMILY_STIX_SIZE_4_BOLD, + FAMILY_STIX_SIZE_5_REGULAR, + // Below are virtual fonts for bookkeeping and do not + // have to correspond to a physical font available in + // surface_t. + // + // TeX combined styles + FAMILY_MATH_ITALIC, + FAMILY_MATH_BOLD_ITALIC, + // Mathematical Alphanumerical Symbols, mostly in the + // Unicode range U+1D500 - U+1D5FF + FAMILY_MATH_SCRIPT_ITALIC, + FAMILY_MATH_SCRIPT_BOLD_ITALIC, + FAMILY_MATH_FRAKTUR_REGULAR, + FAMILY_MATH_FRAKTUR_BOLD, + FAMILY_MATH_BLACKBOARD_BOLD, + FAMILY_MATH_SANS_SERIF_REGULAR, + FAMILY_MATH_SANS_SERIF_ITALIC, + FAMILY_MATH_SANS_SERIF_BOLD, + FAMILY_MATH_SANS_SERIF_BOLD_ITALIC, + FAMILY_MATH_MONOSPACE, + NFAMILY + }; + private: + /** + * Sets any family that is mathematical italic into the + * upright variant of the same weight, thus preventing + * them from converted into the italic form in the final + * step. + * + * @see void math_italic_is_italic(void) + */ + void math_italic_is_upright(void); + /** + * Sets any family that is mathematical italic into the + * italic variant of the same weight, usually used in the + * final step to convert all remaining character in + * mathematical italic into the italic form. + * + * @see void math_italic_is_upright(void) + */ + void math_italic_is_italic(void); + void encode_character(void); + void encode_control_sequence(void); + void encode_math_blackboard_bold(void); + void encode_math_script_italic(void); + void encode_math_script_bold_italic(void); + void encode_math_fraktur_regular(void); + void encode_math_fraktur_bold(void); + void encode_math_sans_serif_regular(void); + void encode_math_sans_serif_italic(void); + void encode_math_sans_serif_bold(void); + void encode_math_sans_serif_bold_italic(void); + void encode_math_alpha(void); + void encode(void); + public: + std::string _code; + unsigned int _family; + wchar_t _glyph; + unsigned int _type; + inline math_symbol_t(void) + : _family(FAMILY_PLAIN), _type(atom_t::TYPE_UNKNOWN) + { + } + inline math_symbol_t(std::string code, wchar_t glyph, + const unsigned int family) + : _code(code), _family(family), _glyph(glyph), + _type(atom_t::TYPE_UNKNOWN) + { + } + inline math_symbol_t(std::string code, + const unsigned int family) + : _code(code), _family(family), _glyph(0), + _type(atom_t::TYPE_UNKNOWN) + { + encode(); + } + inline bool is_combining_diacritical(void) const + { + // ISO/IEC JTC1/SC2/WG2 (2003), Annex B, but without + // the additional characters from the list + return + (_glyph >= L'\u0300' && _glyph <= L'\u036f') || + (_glyph >= L'\u20d0' && _glyph <= L'\u20ff') || + (_glyph >= L'\ufe20' && _glyph <= L'\ufe2f'); + } + bool bold(void) const; + }; + /** + * (Horizontal) Box + * + * @author Yue Shi Lai + * @version 1.0 + */ + class box_t { + public: + bool _vertical; + std::wstring _string; + box_t(void) + { + } + box_t(std::wstring string) + : _vertical(false), _string(string) + { + } + }; + class atom_t; + class item_t; + /** + * Math field + * + * @author Yue Shi Lai + * @version 1.0 + */ + class field_t { + private: + void transform_script(void); + void append(const item_t &item); + void append(const field_t &field, const bool superscript, + const bool subscript); + void prepend(const unsigned int type, + const math_symbol_t &math_symbol); + void append(const unsigned int type, + const math_symbol_t &math_symbol, + const bool superscript, + const bool subscript); + void parse_math_list( + const std::vector &str_split, + const unsigned int default_family); + public: + enum { + // The explicit TYPE_EMPTY in TeX is represented here + // by an empty math list + TYPE_UNKNOWN = 0, + TYPE_MATH_SYMBOL, + TYPE_BOX, // unused + TYPE_MATH_LIST, + NTYPE + }; + unsigned int _type; + math_symbol_t _math_symbol; + box_t _box; + std::vector _math_list; + inline field_t(void) + : _type(TYPE_MATH_LIST) + { + // Empty math list == implicit TYPE_EMPTY + } + inline field_t(const math_symbol_t &math_symbol) + : _type(TYPE_MATH_SYMBOL), _math_symbol(math_symbol) + { + } + inline field_t(const box_t &box) + : _type(TYPE_BOX), _box(box) + { + } + inline field_t(const std::vector &math_list) + : _type(TYPE_MATH_LIST), _math_list(math_list) + { + } + field_t(const std::vector &str_split, + const unsigned int default_family); + field_t(const std::string &str_delimiter_left, + const std::vector &str_split, + const std::string &str_delimiter_right, + const unsigned int default_family); + inline bool empty(void) const + { + return _type == TYPE_MATH_LIST && _math_list.empty(); + } + bool generalized_fraction(void) const; + }; + /** + * Math atom + * + * @author Yue Shi Lai + * @version 1.0 + */ + class atom_t { + private: + void classify(void); + public: + // TeX's 13 types of math atom + enum { + TYPE_UNKNOWN = 0, + TYPE_ORD, + TYPE_OP, + TYPE_BIN, + TYPE_REL, + TYPE_OPEN, + TYPE_CLOSE, + TYPE_PUNCT, + TYPE_INNER, + TYPE_OVER, // not implemented + TYPE_UNDER, // not implemented + TYPE_ACC, + TYPE_RAD, + TYPE_VCENT, // unused + NTYPE + }; + enum { + LIMITS_UNKNOWN = 0, + LIMITS_LIMITS, + LIMITS_NOLIMITS, + LIMITS_DISPLAYLIMITS, + NLIMITS + }; + unsigned int _type; + // Fields + field_t _nucleus; + field_t _superscript; + field_t _subscript; + unsigned int _limits; + // Index the root with the radicand _nucleus, if _type == + // TYPE_RAD (while TeX uses absolute positioning for the + // index, it is not possible to represent it in an font + // independent way). + field_t _index; + inline atom_t(const unsigned int type, + const field_t &nucleus) + : _type(type), _nucleus(nucleus) + { + } + inline atom_t(const unsigned int type, + const field_t &nucleus, + const unsigned int limits) + : _type(type), _nucleus(nucleus), _limits(limits) + { + } + inline atom_t(const field_t &nucleus) + : _nucleus(nucleus) + { + classify(); + } + inline atom_t(const field_t &nucleus, + const field_t &superscript, + const field_t &subscript) + : _nucleus(nucleus), _superscript(superscript), + _subscript(subscript) + { + classify(); + } + /** + * Returns true if the atom is of type Acc, or if it is a + * math symbol and its character representation is a + * combining diacritical mark within the ISO/IEC + * 10646:2003/Amd.2:2006 Universal Character Set, and + * false otherwise. + * + * @return true if the atom is of type Acc, or if it is a + * math symbol and its character representation is a + * combining diacritical mark within the ISO/IEC + * 10646:2003/Amd.2:2006 Universal Character Set, and + * false otherwise + */ + bool is_combining_diacritical(void) const; + /** + * Returns the interelement spacing between the given left + * and right atom types, and whether the present style is + * script or scriptscript, with 0, 1, 2, and 3 + * representing no space, \thinkmuskip, \medmuskip, and + * \thickmuskip, respectively. + * + * TeX defaults to \thinkmuskip to 3 mu, \medmuskip to 4 + * mu, and \thickmuskip to 5 mu, with 1 mu being 1/18 + * quad. + * + * @param[in] left_type left (enum) atom type + * @param[in] right_type right (enum) atom type + * @return interelement spacing, with 0, 1, 2, and 3 + * representing no space, \thinkmuskip, \medmuskip, and + * \thickmuskip, respectively + */ + static unsigned int + spacing(const unsigned int left_type, + const unsigned int right_type, const bool script); + }; + /** + * Math item + * + * @author Yue Shi Lai + * @version 1.0 + */ + class item_t { + public: + // TeX's 9 types of math item + enum { + TYPE_UNKNOWN = 0, + TYPE_ATOM, // implemented + TYPE_HORIZONTAL, // unused + TYPE_VERTICAL, // unused + TYPE_GLOB_OR_GLUE, // unused + TYPE_KERN, // implemented + TYPE_STYLE_CHANGE, // not implemented + TYPE_GENERALIZED_FRACTION, // not implemented + TYPE_BOUNDARY, // implemented + TYPE_FOUR_WAY_CHOICE, // unused + NTYPE + }; + // TeX's 8 math styles + enum { + STYLE_UNKNOWN = 0, + STYLE_SCRIPT_SCRIPT_PRIME, + STYLE_SCRIPT_SCRIPT, + STYLE_SCRIPT_PRIME, + STYLE_SCRIPT, + STYLE_TEXT_PRIME, + STYLE_TEXT, + STYLE_DISPLAY_PRIME, + STYLE_DISPLAY, + NSTYLE + }; + // TeX's left and right math boundary + enum { + BOUNDARY_UNKNOWN = 0, + BOUNDARY_LEFT, + BOUNDARY_RIGHT, + NBOUNDARY + }; + unsigned int _type; + atom_t _atom; + float _length; + unsigned int _style_change; + unsigned int _boundary; + inline item_t(const unsigned int type, + const float length = 0) + : _type(type), _atom(field_t()), _length(length) + { + } + inline item_t(const atom_t &atom) + : _type(TYPE_ATOM), _atom(atom) + { + } + inline item_t(const unsigned int type, + const atom_t &atom) + : _type(type), _atom(atom) + { + } + bool operator==(const item_t &item) const; + }; + std::wstring _code; + field_t _math_list; + bool _render_structure; + ///////////////////////////////////////////////////////////// + void tree_view_prefix(const std::vector &branch, + const bool final) const; + void tree_view(const field_t &field, + std::vector &branch, const bool final) + const; + void tree_view(const item_t &item, std::vector &branch, + const bool final) const; + void tree_view(const atom_t &atom, std::vector &branch, + const bool final) const; + static std::wstring bad_cast(const std::string string); + static std::wstring utf8_cast(const std::string string); + ///////////////////////////////////////////////////////////// + static std::vector + tex_split(const std::string &raw_code, + const char escape_character = '\\'); + static std::vector + tex_replace(const std::vector &code); + field_t build_math_list(const std::vector & + code_split) const + { + return field_t(code_split, + math_symbol_t::FAMILY_MATH_ITALIC); + } + public: + math_text_t(void) + : _code(), _math_list(), _render_structure(false) + { + } + math_text_t(const std::string &code_string) + : _code(bad_cast(code_string)), _render_structure(false) + { + std::cerr << __FILE__ << ':' << __LINE__ << ": " << std::endl; + std::vector code_split = tex_split(code_string); + _math_list = build_math_list(code_split); + } + math_text_t(const char code_string[]) + : _code(bad_cast(code_string)), _render_structure(false) + { + std::vector code_split = tex_split(code_string); + _math_list = build_math_list(code_split); + } + inline std::wstring code(void) const + { + return _code; + } + inline bool render_structure(void) const + { + return _render_structure; + } + inline bool &render_structure(void) + { + return _render_structure; + } + bool well_formed(void) const; + inline bool empty(void) const + { + return _math_list.empty(); + } + inline void tree_view(void) const + { + std::vector branch; + + tree_view(_math_list, branch, true); + } + friend class math_text_renderer_t; + }; + + /** + * Returns the TeX-formatted scientific representation of a real + * number + */ + extern std::string tex_form(const double x); + +} + +#endif // MATHTEXT_H_ diff --git a/graf2d/mathtext/src/fontembed.cxx b/graf2d/mathtext/src/fontembed.cxx new file mode 100644 index 0000000000000..f71409dbaa7a8 --- /dev/null +++ b/graf2d/mathtext/src/fontembed.cxx @@ -0,0 +1,1189 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +#include "fontembed.h" +#include +#include +#include +#ifdef WIN32 +#define snprintf _snprintf +#endif + +// ROOT integration +#include "RConfig.h" +#ifdef R__BYTESWAP +#ifndef LITTLE_ENDIAN +#define LITTLE_ENDIAN 1 +#endif // LITTLE_ENDIAN +#include "Byteswap.h" +#define bswap_16(x) Rbswap_16((x)) +#define bswap_32(x) Rbswap_32((x)) +#else // R__BYTESWAP +#ifdef LITTLE_ENDIAN +#undef LITTLE_ENDIAN +#endif // LITTLE_ENDIAN +#endif // R__BYTESWAP + +// References: +// +// Adobe Systems, Inc. and Microsoft Corp., OpenType specification +// (2002), version 1.4. +// +// Apple Computer, Inc., TrueType reference ranual (2002) +// +// Microsoft Corp., TrueType 1.0 font files: technical specification +// (1995), version 1.66 + +namespace mathtext { + + typedef int32_t fixed_t; + + void font_embed_t::parse_ttf_encoding_subtable_format4( + std::map &cid_map, + const std::vector &font_data, const size_t offset, + const uint16_t length) + { + cid_map.clear(); + + size_t offset_current = offset; + + struct ttf_encoding_subtable_format4_s { + uint16_t seg_count_x2; + uint16_t search_range; + uint16_t entry_selector; + uint16_t range_shift; + } encoding_subtable_format4; + + memcpy(&encoding_subtable_format4, + &font_data[offset_current], + sizeof(struct ttf_encoding_subtable_format4_s)); + offset_current += + sizeof(struct ttf_encoding_subtable_format4_s); +#ifdef LITTLE_ENDIAN + encoding_subtable_format4.seg_count_x2 = + bswap_16(encoding_subtable_format4.seg_count_x2); +#endif // LITTLE_ENDIAN + + const uint16_t seg_count = + encoding_subtable_format4.seg_count_x2 >> 1; + uint16_t *end_code = new uint16_t[seg_count]; + + memcpy(end_code, &font_data[offset_current], + seg_count * sizeof(uint16_t)); + offset_current += seg_count * sizeof(uint16_t); +#ifdef LITTLE_ENDIAN + for (uint16_t segment = 0; segment < seg_count; segment++) { + end_code[segment] = bswap_16(end_code[segment]); + } +#endif // LITTLE_ENDIAN + + uint16_t reserved_pad; + + memcpy(&reserved_pad, &font_data[offset_current], + sizeof(uint16_t)); + offset_current += sizeof(uint16_t); + + uint16_t *start_code = new uint16_t[seg_count]; + + memcpy(start_code, &font_data[offset_current], + seg_count * sizeof(uint16_t)); + offset_current += seg_count * sizeof(uint16_t); +#ifdef LITTLE_ENDIAN + for (uint16_t segment = 0; segment < seg_count; segment++) { + start_code[segment] = bswap_16(start_code[segment]); + } +#endif // LITTLE_ENDIAN + + uint16_t *id_delta = new uint16_t[seg_count]; + + memcpy(id_delta, &font_data[offset_current], + seg_count * sizeof(uint16_t)); + offset_current += seg_count * sizeof(uint16_t); +#ifdef LITTLE_ENDIAN + for (uint16_t segment = 0; segment < seg_count; segment++) { + id_delta[segment] = bswap_16(id_delta[segment]); + } +#endif // LITTLE_ENDIAN + + const uint16_t variable = + (length >> 1) - (seg_count << 2) - 8; + uint16_t *id_range_offset = + new uint16_t[seg_count + variable]; + + memcpy(id_range_offset, &font_data[offset_current], + (seg_count + variable) * sizeof(uint16_t)); + offset_current += (seg_count + variable) * sizeof(uint16_t); +#ifdef LITTLE_ENDIAN + for (uint16_t j = 0; j < seg_count + variable; j++) { + id_range_offset[j] = bswap_16(id_range_offset[j]); + } +#endif // LITTLE_ENDIAN + + for (uint16_t segment = 0; segment < seg_count; segment++) { + for (uint32_t code = start_code[segment]; + code <= end_code[segment]; code++) { + const uint16_t inner_offset = segment + + (id_range_offset[segment] >> 1) + + (code - start_code[segment]); + const uint16_t glyph_index = + id_range_offset[segment] == 0 ? + id_delta[segment] + code : + inner_offset >= seg_count + variable ? + 0 : id_range_offset[inner_offset]; + + cid_map[static_cast(code)] = glyph_index; + } + } + + delete [] end_code; + delete [] start_code; + delete [] id_delta; + delete [] id_range_offset; + } + +///////////////////////////////////////////////////////////////////// +// Currently unfinished font subsetting code below +///////////////////////////////////////////////////////////////////// + +#if 0 + // Rename: + // name + // Subset: + // glyf, loca, hmtx, vmtx, cmap, hdmx, VDMX, kern, LTSH, VORG + // Conditional subset: + // post 2.0 + // Remove completely: + // DSIG, BASE, GDEF, GPOS, GSUB, JSTF, EBDT, EBLC, EBSC + + void font_embed_t::subset_rename_otf_name_table( + struct table_data_s &table_data, + std::map glyph_usage) + { + // Prefix name IDs 1, 4, 6, 16, 19, 20, 21 + + // No platform ID other than 1 and 3 is permitted for the name + // table + + // Platform ID = 1: 1 byte + // Platform ID = 3: 2 byte + + // Reset UID 4,000,000 and 4,999,999 and XUID + } + + void font_embed_t::subset_ttf_glyf_table( + struct table_data_s &table_data, + std::map glyph_usage) + { + } + + void font_embed_t::subset_ttf_loca_table( + struct table_data_s &table_data, + std::map glyph_usage) + { + } + + void font_embed_t::subset_ttf_post_table( + struct table_data_s &table_data, + std::map glyph_usage) + { + } + + class cff_index_t { + public: + uint16_t count; + uint8_t off_size; + std::vector offset; + std::vector data; + cff_index_t(const uint8_t *input_data) + { + memcpy(&count, input_data, sizeof(uint16_t)); +#ifdef LITTLE_ENDIAN + count = bswap_16(count); +#endif // LITTLE_ENDIAN + memcpy(&off_size, input_data + sizeof(uint16_t), + sizeof(uint8_t)); + + if (!(off_size >= 1 && off_size < 5)) { + return; + } + + const uint8_t *input_data_offset = + input_data + sizeof(uint16_t) + sizeof(uint8_t); + + // The off by one or indexing from one convention in CFF + // is corrected here, i.e. the resulting offset table is + // zero-based, and not the CFF one. + + offset.reserve(count + 1); + switch (off_size) { + case 1: + for (size_t i = 0; i < count + 1; i++) { + offset.push_back(input_data_offset[i]); + } + break; + case 2: + for (size_t i = 0; i < count + 1; i++) { + offset.push_back(reinterpret_cast( + input_data_offset)[i]); +#ifdef LITTLE_ENDIAN + offset.back() = bswap_16(offset.back()); +#endif // LITTLE_ENDIAN + } + break; + case 3: + for (size_t i = 0; i < 3 * (count + 1); i += 3) { + const uint32_t value = + input_data_offset[3 * i] << 16 | + input_data_offset[3 * i + 1] << 8 | + input_data_offset[3 * i + 2]; + + offset.push_back(value); + } + break; + case 4: + for (size_t i = 0; i < count + 1; i++) { + offset.push_back(reinterpret_cast( + input_data_offset)[i]); +#ifdef LITTLE_ENDIAN + offset.back() = bswap_32(offset.back()); +#endif // LITTLE_ENDIAN + } + break; + } + + const uint8_t *input_data_data = + input_data_offset + off_size * (count + 1); + + data = std::vector(input_data_data, input_data_data + } + ~cff_index_t(void) + { + } + }; + + void font_embed_t::subset_otf_cff_table( + struct table_data_s &table_data, + std::map glyph_usage) + { + } +#endif + + uint32_t font_embed_t::otf_check_sum( + const std::vector &table_data) + { + const uint32_t *table = + reinterpret_cast(&(table_data[0])); + const uint32_t nword = table_data.size() >> 2; + uint32_t sum = 0; + + for (size_t i = 0; i < nword; i++) { +#ifdef LITTLE_ENDIAN + sum += bswap_32(table[i]); +#else // LITTLE_ENDIAN + sum += table[i]; +#endif // LITTLE_ENDIAN + } + + // Do not assume 0x00 padding and calculate partial uint32_t + // checksums directly. + const uint8_t *table_tail = + reinterpret_cast(&(table[nword])); + + switch(table_data.size() & 3U) { + case 3: sum += table_tail[2] << 8; + case 2: sum += table_tail[1] << 16; + case 1: sum += table_tail[0] << 24; break; + } + + return sum; + } + + std::vector font_embed_t::read_font_data( + FILE *fp) + { + std::vector font_data; + + if (fp == NULL) { + return font_data; + } + if (fseek(fp, 0L, SEEK_SET) == -1) { + perror("fseek"); + return font_data; + } + if (fseek(fp, 0L, SEEK_END) == -1) { + perror("fseek"); + return font_data; + } + + const long length = ftell(fp); + + if (length == -1) { + perror("ftell"); + return font_data; + } + font_data.resize(length); + if (fseek(fp, 0L, SEEK_SET) == -1) { + perror("fseek"); + font_data.clear(); + return font_data; + } + if (fread(&font_data[0], sizeof(uint8_t), + length, fp) != static_cast(length)) { + perror("fread"); + font_data.clear(); + return font_data; + } + fseek(fp, 0L, SEEK_SET); + + return font_data; + } + + std::vector font_embed_t::read_font_data( + const std::string &filename) + { + FILE *fp = fopen(filename.c_str(), "r"); + std::vector font_data; + + if (fp == NULL) { + perror("fopen"); + return font_data; + } + font_data = read_font_data(fp); + fclose(fp); + + return font_data; + } + + bool font_embed_t::parse_otf_cff_header( + std::string &font_name, unsigned short &cid_encoding_id, + unsigned int &cff_offset, unsigned int &cff_length, + const std::vector &font_data) + { + // OpenType file structure + struct otf_offset_table_s { + char sfnt_version[4]; + uint16_t num_tables; + uint16_t search_range; + uint16_t entry_selector; + uint16_t range_shift; + } offset_table; + + memcpy(&offset_table, &font_data[0], + sizeof(struct otf_offset_table_s)); + if (strncmp(offset_table.sfnt_version, "OTTO", 4) != 0) { + // Not a OpenType CFF/Type 2 font + return false; + } +#ifdef LITTLE_ENDIAN + offset_table.num_tables = bswap_16(offset_table.num_tables); +#endif // LITTLE_ENDIAN + + bool name_table_exists = false; + bool cff_table_exists = false; + uint32_t name_offset = 0; + + for (uint16_t i = 0; i < offset_table.num_tables; i++) { + struct otf_table_directory_s { + char tag[4]; + uint32_t check_sum; + uint32_t offset; + uint32_t length; + } table_directory; + + memcpy(&table_directory, + &font_data[sizeof(struct otf_offset_table_s) + i * + sizeof(struct otf_table_directory_s)], + sizeof(struct otf_table_directory_s)); +#ifdef LITTLE_ENDIAN + table_directory.offset = + bswap_32(table_directory.offset); + table_directory.length = + bswap_32(table_directory.length); +#endif // LITTLE_ENDIAN + if (strncmp(table_directory.tag, "name", 4) == 0) { + name_offset = table_directory.offset; + name_table_exists = true; + } + else if (strncmp(table_directory.tag, "CFF ", 4) == 0) { + cff_offset = table_directory.offset; + cff_length = table_directory.length; + cff_table_exists = true; + } + } + + if (!(name_table_exists && cff_table_exists)) { + return false; + } + + // name + + struct otf_naming_table_header_s { + uint16_t format; + uint16_t count; + uint16_t string_offset; + } naming_table_header; + + memcpy(&naming_table_header, &font_data[name_offset], + sizeof(struct otf_naming_table_header_s)); +#ifdef LITTLE_ENDIAN + naming_table_header.format = + bswap_16(naming_table_header.format); + naming_table_header.count = + bswap_16(naming_table_header.count); + naming_table_header.string_offset = + bswap_16(naming_table_header.string_offset); +#endif // LITTLE_ENDIAN + + cid_encoding_id = 0xffffU; + + for (uint16_t i = 0; i < naming_table_header.count; i++) { + struct otf_name_record_s { + uint16_t platform_id; + uint16_t encoding_id; + uint16_t language_id; + uint16_t name_id; + uint16_t length; + uint16_t offset; + } name_record; + const size_t base_offset = name_offset + + sizeof(struct otf_naming_table_header_s); + + memcpy(&name_record, + &font_data[base_offset + i * + sizeof(struct otf_name_record_s)], + sizeof(struct otf_name_record_s)); +#ifdef LITTLE_ENDIAN + name_record.platform_id = + bswap_16(name_record.platform_id); + name_record.encoding_id = + bswap_16(name_record.encoding_id); + name_record.name_id = bswap_16(name_record.name_id); +#endif // LITTLE_ENDIAN + if (name_record.platform_id == 1 && + name_record.encoding_id == 0 && + name_record.name_id == 6) { + // Postscript name in Mac OS Roman + // + // The font name in Mac OS Roman encoding is + // sufficient to obtain an ASCII PostScript name (and + // is required by OpenType specification), while the + // Windows platform uses a UCS-2 string that would + // require conversion. +#ifdef LITTLE_ENDIAN + name_record.length = bswap_16(name_record.length); + name_record.offset = bswap_16(name_record.offset); +#endif // LITTLE_ENDIAN + + char *buffer = new char[name_record.length + 1]; + + memcpy(buffer, + &font_data[name_offset + + naming_table_header.string_offset + + name_record.offset], + name_record.length); + buffer[name_record.length] = '\0'; + font_name = buffer; + + delete [] buffer; + } + if (name_record.platform_id == 1 && + name_record.name_id == 20) { + // PostScript CID findfont name + // + // encoding_id Macintosh CMap + // --------------------------- + // 1 83pv-RKSJ-H + // 2 B5pc-H + // 3 KSCpc-EUC-H + // 25 GBpc-EUC-H + cid_encoding_id = name_record.encoding_id; + // The actual Macintosh encoding CMap name is of no + // further use. Note that Adobe currently only + // actively maintains the Unicode based CMaps. + } + } + + return true; + } + + bool font_embed_t::parse_ttf_header( + std::string &font_name, double *font_bbox, + std::map &cid_map, + std::vector &char_strings, + const std::vector &font_data) + { + cid_map.clear(); + char_strings.clear(); + + struct ttf_offset_table_s { + fixed_t sfnt_version; + uint16_t num_tables; + uint16_t search_range; + uint16_t entry_selector; + uint16_t range_shift; + } offset_table; + + memcpy(&offset_table, &font_data[0], + sizeof(struct ttf_offset_table_s)); +#ifdef LITTLE_ENDIAN + offset_table.sfnt_version = + bswap_32(offset_table.sfnt_version); + offset_table.num_tables = bswap_16(offset_table.num_tables); +#endif // LITTLE_ENDIAN + if (offset_table.sfnt_version != 0x00010000) { + return false; + } + + size_t name_offset = 0; + //size_t name_length = 0; + size_t head_offset = 0; + //size_t head_length = 0; + size_t cmap_offset = 0; + //size_t cmap_length = 0; + size_t post_offset = 0; + //size_t post_length = 0; + + for (uint16_t i = 0; i < offset_table.num_tables; i++) { + struct ttf_table_directory_s { + char tag[4]; + uint32_t check_sum; + uint32_t offset; + uint32_t length; + } table_directory; + + memcpy(&table_directory, + &font_data[sizeof(struct ttf_offset_table_s) + i * + sizeof(struct ttf_table_directory_s)], + sizeof(struct ttf_table_directory_s)); +#ifdef LITTLE_ENDIAN + table_directory.offset = + bswap_32(table_directory.offset); + table_directory.length = + bswap_32(table_directory.length); +#endif // LITTLE_ENDIAN +#if 0 + fprintf(stderr, "%s:%d: tag = %c%c%c%c, offset = %u, " + "length = %u\n", __FILE__, __LINE__, + table_directory.tag[0], table_directory.tag[1], + table_directory.tag[2], table_directory.tag[3], + table_directory.offset, table_directory.length); +#endif + if (strncmp(table_directory.tag, "name", 4) == 0) { + name_offset = table_directory.offset; + //name_length = table_directory.length; + } + else if (strncmp(table_directory.tag, "head", 4) == 0) { + head_offset = table_directory.offset; + //head_length = table_directory.length; + } + else if (strncmp(table_directory.tag, "cmap", 4) == 0) { + cmap_offset = table_directory.offset; + //cmap_length = table_directory.length; + } + else if (strncmp(table_directory.tag, "post", 4) == 0) { + post_offset = table_directory.offset; + //post_length = table_directory.length; + } + } + + // name + + struct ttf_naming_table_header_s { + uint16_t format; + uint16_t count; + uint16_t string_offset; + } naming_table_header; + + memcpy(&naming_table_header, + &font_data[name_offset], + sizeof(struct ttf_naming_table_header_s)); +#ifdef LITTLE_ENDIAN + naming_table_header.format = + bswap_16(naming_table_header.format); + naming_table_header.count = + bswap_16(naming_table_header.count); + naming_table_header.string_offset = + bswap_16(naming_table_header.string_offset); +#endif // LITTLE_ENDIAN + + for (uint16_t i = 0; i < naming_table_header.count; i++) { + struct ttf_name_record_s { + uint16_t platform_id; + uint16_t encoding_id; + uint16_t language_id; + uint16_t name_id; + uint16_t length; + uint16_t offset; + } name_record; + + memcpy( + &name_record, + &font_data[name_offset + + sizeof(struct ttf_naming_table_header_s) + + i * sizeof(struct ttf_name_record_s)], + sizeof(struct ttf_name_record_s)); +#ifdef LITTLE_ENDIAN + name_record.platform_id = + bswap_16(name_record.platform_id); + name_record.encoding_id = + bswap_16(name_record.encoding_id); + name_record.name_id = bswap_16(name_record.name_id); +#endif // LITTLE_ENDIAN + // the font name in mac os roman encoding is good enough + // to obtain an ASCII post_script name, while the windows + // platform uses a utF-16 string that would require + // conversion. + if (name_record.platform_id == 1 && + name_record.encoding_id == 0 && + name_record.name_id == 6) { +#ifdef LITTLE_ENDIAN + name_record.length = bswap_16(name_record.length); + name_record.offset = bswap_16(name_record.offset); +#endif // LITTLE_ENDIAN + + char *buffer = new char[name_record.length + 1]; + + memcpy(buffer, + &font_data[name_offset + + naming_table_header.string_offset + + name_record.offset], + name_record.length * sizeof(char)); + buffer[name_record.length] = '\0'; + font_name = buffer; + + delete [] buffer; + } + else if (name_record.platform_id == 3 && + name_record.encoding_id == 1 && + name_record.name_id == 6) { +#ifdef LITTLE_ENDIAN + name_record.length = bswap_16(name_record.length); + name_record.offset = bswap_16(name_record.offset); +#endif // LITTLE_ENDIAN + + // Very ugly UCS-2 to ASCII conversion, but should + // work for most font names + char *buffer = + new char[(name_record.length >> 1) + 1]; + + for (uint16_t j = 0; j < (name_record.length >> 1); + j++) { + buffer[j] = + font_data[name_offset + + naming_table_header.string_offset + + name_record.offset + j * 2 + 1]; + } + buffer[name_record.length >> 1] = '\0'; + font_name = buffer; + + delete [] buffer; + } + } + + // head + + struct ttf_head_table_s { + fixed_t version; + fixed_t font_revision; + uint32_t check_sum_adjustment; + uint32_t magic_number; + uint16_t flags; + uint16_t units_per_em; + char created[8]; + char modified[8]; + int16_t x_min; + int16_t y_min; + int16_t x_max; + int16_t y_max; + uint16_t mac_style; + uint16_t lowest_rec_ppem; + int16_t font_direction_hint; + int16_t index_to_loc_format; + int16_t glyph_data_format; + } head_table; + + memcpy(&head_table, &font_data[head_offset], + sizeof(struct ttf_head_table_s)); +#ifdef LITTLE_ENDIAN + head_table.units_per_em = bswap_16(head_table.units_per_em); + head_table.x_min = bswap_16(head_table.x_min); + head_table.y_min = bswap_16(head_table.y_min); + head_table.x_max = bswap_16(head_table.x_max); + head_table.y_max = bswap_16(head_table.y_max); +#endif // LITTLE_ENDIAN + + font_bbox[0] = + (double)head_table.x_min / head_table.units_per_em; + font_bbox[1] = + (double)head_table.y_min / head_table.units_per_em; + font_bbox[2] = + (double)head_table.x_max / head_table.units_per_em; + font_bbox[3] = + (double)head_table.y_max / head_table.units_per_em; + + // post + + struct ttf_post_script_table_s { + fixed_t format_type; + fixed_t italic_angle; + int16_t underline_position; + int16_t underline_thickness; + uint32_t is_fixed_pitch; + uint32_t min_mem_type42; + uint32_t max_mem_type42; + uint32_t min_mem_type1; + uint32_t max_mem_type1; + } post_script_table; + + memcpy(&post_script_table, + &font_data[post_offset], + sizeof(struct ttf_post_script_table_s)); + +#ifdef LITTLE_ENDIAN + post_script_table.format_type = + bswap_32(post_script_table.format_type); + post_script_table.min_mem_type42 = + bswap_32(post_script_table.min_mem_type42); + post_script_table.max_mem_type42 = + bswap_32(post_script_table.max_mem_type42); +#endif // LITTLE_ENDIAN + + size_t offset_current = post_offset; + +#if 0 + if (post_script_table.format_type == 0x00010000) { + // Exactly the 258 glyphs in the standard Macintosh glyph + // set + } +#endif + if (post_script_table.format_type == 0x00020000) { + // Version required by TrueType-based fonts to be used on + // Windows + // + // numberOfGlyphs, glyphNameIndex[numGlyphs], + // names[numberNewGlyphs] table + + uint16_t num_glyphs; + + memcpy(&num_glyphs, + &font_data[post_offset + + sizeof(struct ttf_post_script_table_s)], + sizeof(uint16_t)); +#ifdef LITTLE_ENDIAN + num_glyphs = bswap_16(num_glyphs); +#endif // LITTLE_ENDIAN + + uint16_t *glyph_name_index = new uint16_t[num_glyphs]; + + memcpy(glyph_name_index, + &font_data[post_offset + + sizeof(struct ttf_post_script_table_s) + + sizeof(uint16_t)], + num_glyphs * sizeof(uint16_t)); +#ifdef LITTLE_ENDIAN + for (uint16_t i = 0; i < num_glyphs; i++) { + glyph_name_index[i] = bswap_16(glyph_name_index[i]); + } +#endif // LITTLE_ENDIAN + + uint16_t max_glyph_name_index = 0; + for (int i = num_glyphs - 1; i >= 0; i--) { + if (glyph_name_index[i] > max_glyph_name_index) { + max_glyph_name_index = glyph_name_index[i]; + } + } + + std::string *glyph_name = + new std::string[max_glyph_name_index - 258 + 1]; + + offset_current += + sizeof(struct ttf_post_script_table_s) + + (num_glyphs + 1) * sizeof(uint16_t); + for (uint16_t i = 0; i <= max_glyph_name_index - 258; i++) { + uint8_t length; + + memcpy(&length, &font_data[offset_current], + sizeof(uint8_t)); + offset_current += sizeof(uint8_t); + + char *buffer = new char[length + 1UL]; + + memcpy(buffer, &font_data[offset_current], + length * sizeof(uint8_t)); + offset_current += length * sizeof(uint8_t); + buffer[length] = '\0'; + glyph_name[i] = buffer; + + delete [] buffer; + } + + char_strings.resize(num_glyphs); +#include "table/macintoshordering.h" + for (uint16_t glyph = 0; glyph < num_glyphs; glyph++) { + char_strings[glyph] = glyph_name_index[glyph] >= 258 ? + glyph_name[glyph_name_index[glyph] - 258].c_str() : + macintosh_ordering[glyph_name_index[glyph]]; + } + + delete [] glyph_name_index; + delete [] glyph_name; + } + else if (post_script_table.format_type == 0x00030000) { + // No PostScript name information is provided for the + // glyphs + + // Do nothing, cid_map will be initialized with standard + // Adobe glyph names once cmap is read + } + else { + fprintf(stderr, "%s:%d: unsupported post table format " + "0x%08x\n", __FILE__, __LINE__, + post_script_table.format_type); + + return false; + } +#if 0 + if (post_script_table.format_type == 0x00025000) { + // Pure subset/simple reordering of the standard Macintosh + // glyph set. Deprecated as of OpenType Specification v1.3 + // + // numberOfGlyphs, offset[numGlyphs] + return false; + } +#endif + + // cmap + + struct ttf_mapping_table_s { + uint16_t version; + uint16_t num_encoding_tables; + } mapping_table; + + memcpy(&mapping_table, &font_data[cmap_offset], + sizeof(struct ttf_mapping_table_s)); +#ifdef LITTLE_ENDIAN + mapping_table.num_encoding_tables = + bswap_16(mapping_table.num_encoding_tables); +#endif // LITTLE_ENDIAN + + uint32_t *subtable_offset = + new uint32_t[mapping_table.num_encoding_tables]; + + for (uint16_t i = 0; + i < mapping_table.num_encoding_tables; i++) { + struct ttf_encoding_table_s { + uint16_t platform_id; + uint16_t encoding_id; + uint32_t offset; + } encoding_table; + + memcpy( + &encoding_table, + &font_data[cmap_offset + + sizeof(struct ttf_mapping_table_s) + + i * sizeof(struct ttf_encoding_table_s)], + sizeof(struct ttf_encoding_table_s)); +#ifdef LITTLE_ENDIAN + encoding_table.platform_id = + bswap_16(encoding_table.platform_id); + encoding_table.encoding_id = + bswap_16(encoding_table.encoding_id); + encoding_table.offset = bswap_32(encoding_table.offset); +#endif // LITTLE_ENDIAN + subtable_offset[i] = cmap_offset + encoding_table.offset; + } + + int priority_max = 0; + + for (uint16_t i = 0; + i < mapping_table.num_encoding_tables; i++) { + struct ttf_encoding_subtable_common_s { + uint16_t format; + uint16_t length; + uint16_t language; + } encoding_subtable_common; + + memcpy(&encoding_subtable_common, + &font_data[subtable_offset[i]], + sizeof(struct ttf_encoding_subtable_common_s)); +#ifdef LITTLE_ENDIAN + encoding_subtable_common.format = + bswap_16(encoding_subtable_common.format); + encoding_subtable_common.length = + bswap_16(encoding_subtable_common.length); + encoding_subtable_common.language = + bswap_16(encoding_subtable_common.language); +#endif // LITTLE_ENDIAN + + offset_current = subtable_offset[i] + + sizeof(struct ttf_encoding_subtable_common_s); +#if 0 + fprintf(stderr, "%s:%d: encoding_subtable_common.format " + "= %hu\n", __FILE__, __LINE__, + encoding_subtable_common.format); + fprintf(stderr, "%s:%d: encoding_subtable_common.length " + "= %hu\n", __FILE__, __LINE__, + encoding_subtable_common.length); + fprintf(stderr, "%s:%d: encoding_subtable_common.language " + "= %hu\n", __FILE__, __LINE__, + encoding_subtable_common.language); +#endif + + int priority; + + switch(encoding_subtable_common.format) { + ///////////////////////////////////////////////////// + // 8 and 16 bit mappings + // Priority range 1, 3..5 (2 reserved for format 13) + case 0: + priority = 1; + // Byte encoding table + break; + case 2: + // High-byte mapping through table + priority = 3; + break; + case 4: + // Segment mapping to delta values + priority = 5; +#if 0 + fprintf(stderr, "%s:%d: priority = %d, priority_max " + "= %d\n", __FILE__, __LINE__, priority, + priority_max); +#endif + if (priority_max <= priority) { + parse_ttf_encoding_subtable_format4( + cid_map, font_data, offset_current, + encoding_subtable_common.length); + priority_max = priority; + } + break; + case 6: + // Trimmed table mapping + priority = 5; + break; + ///////////////////////////////////////////////////// + // 32-bit mappings + // Priority range 6..9 (2 reserved for format 13) + case 8: + // Mixed 16-bit and 32-bit coverage + priority = 6; + break; + case 10: + // Trimmed array + priority = 6; + break; + case 12: + // Segmented coverage + priority = 6; + break; + case 13: + // Last resort font + priority = 2; + break; + case 14: + // Unicode variation sequences + priority = 9; + break; + default: + delete [] subtable_offset; + return false; + } + } + + delete [] subtable_offset; + + // Regenerate cid_map from the Adobe glyph list + + if (char_strings.empty() && !cid_map.empty()) { + char_strings.resize(cid_map.size()); + for (std::map::const_iterator iterator = + cid_map.begin(); + iterator != cid_map.end(); iterator++) { + if (iterator->second < char_strings.size()) { +#include "table/adobeglyphlist.h" + + const wchar_t *lower = + std::lower_bound( + adobe_glyph_ucs, + adobe_glyph_ucs + nadobe_glyph, + iterator->first); + // The longest Adobe glyph name is 20 characters + // long (0x03b0 = upsilondieresistonos) + char buf[21]; + + if (iterator->first == L'\uffff') { + strncpy(buf, ".notdef", 8); + } + else if (lower < adobe_glyph_ucs + nadobe_glyph && + *lower == iterator->first) { + const size_t index = + lower - adobe_glyph_ucs; + + snprintf(buf, 21, "%s", adobe_glyph_name[index]); + } + else { + snprintf(buf, 21, "uni%04X", iterator->first); + } + char_strings[iterator->second] = buf; + } + } + } + + return true; + } + +#if 0 + std::vector font_embed_t::subset_otf( + const std::vector &font_data, + const std::map &glyph_usage) + { + std::vector retval; + struct otf_offset_table_s { + char sfnt_version[4]; + uint16_t num_tables; + uint16_t search_range; + uint16_t entry_selector; + uint16_t range_shift; + } offset_table; + + memcpy(&offset_table, &font_data[0], + sizeof(struct otf_offset_table_s)); + if (strncmp(offset_table.sfnt_version, "OTTO", 4) != 0 || + strncmp(offset_table.sfnt_version, "\0\1\0\0", 4) != 0) { + // Neither a OpenType, nor TrueType font +#if 0 + fprintf(stderr, "%s:%d: error: unknown sfnt_version = " + "0x%02x%02x%02x%02x\n", __FILE__, __LINE__, + offset_table.sfnt_version[0], + offset_table.sfnt_version[1], + offset_table.sfnt_version[2], + offset_table.sfnt_version[3]); +#endif + return retval; + } +#ifdef LITTLE_ENDIAN + offset_table.num_tables = bswap_16(offset_table.num_tables); +#endif // LITTLE_ENDIAN + + struct otf_table_directory_s { + char tag[4]; + uint32_t check_sum; + uint32_t offset; + uint32_t length; + }; + struct table_data_s *table_data = + new struct table_data_s[offset_table.num_tables]; + + for (uint16_t i = 0; i < offset_table.num_tables; i++) { + struct otf_table_directory_s table_directory; + + memcpy(&table_directory, + &font_data[sizeof(struct otf_offset_table_s) + i * + sizeof(struct otf_table_directory_s)], + sizeof(struct otf_table_directory_s)); +#ifdef LITTLE_ENDIAN + table_directory.offset = + bswap_32(table_directory.offset); + table_directory.length = + bswap_32(table_directory.length); +#endif // LITTLE_ENDIAN +#if 0 + fprintf(stderr, "%s:%d: tag = %c%c%c%c, offset = %u, " + "length = %u\n", __FILE__, __LINE__, + table_directory.tag[0], table_directory.tag[1], + table_directory.tag[2], table_directory.tag[3], + table_directory.offset, table_directory.length); +#endif + memcpy(table_data[i].tag, table_directory.tag, + 4 * sizeof(char)); + table_data[i].data.resize(table_directory.length); + memcpy(&(table_data[i].data[0]), + &font_data[table_directory.offset], + table_directory.length); + } + + size_t size_count; + + size_count = sizeof(struct otf_offset_table_s) + + offset_table.num_tables * + sizeof(struct otf_table_directory_s); + for (size_t i = 0; i < offset_table.num_tables; i++) { + size_count += table_data[i].data.size(); + } + + size_t offset_current = sizeof(struct otf_offset_table_s); + size_t offset_check_sum_adjustment = 0; + bool head_table_exists = false; + + retval.resize(size_count); + memcpy(&retval[0], &font_data[0], + sizeof(struct otf_offset_table_s)); + for (size_t i = 0; i < offset_table.num_tables; i++) { + struct otf_table_directory_s table_directory; + const bool head_table = + strncmp(table_directory.tag, "head", 4) == 0; + + memcpy(table_directory.tag, table_data[i].tag, + 4 * sizeof(char)); + if (head_table) { + // Reset checkSumAdjustment in order to calculate the + // check sum of the head table + offset_check_sum_adjustment = 2 * sizeof(fixed_t); + *reinterpret_cast(&(table_data[i].data[ + offset_check_sum_adjustment])) = 0U; + // Change the offset for checkSumAdjustment to the + // global indexing + offset_check_sum_adjustment += offset_current; + head_table_exists = true; + } + table_directory.check_sum = + otf_check_sum(table_data[i].data); + table_directory.offset = size_count; + table_directory.length = table_data[i].data.size(); + + memcpy(&retval[offset_current], &table_directory, + sizeof(struct otf_table_directory_s)); + size_count += table_data[i].data.size(); + offset_current += sizeof(struct otf_table_directory_s); + } + + for (size_t i = 0; i < offset_table.num_tables; i++) { + memcpy(&retval[offset_current], &(table_data[i].data[0]), + table_data[i].data.size()); + offset_current += table_data[i].data.size(); + + const size_t padding_size = + (4U - table_data[i].data.size()) & 3U; + + memset(&retval[offset_current], '\0', padding_size); + offset_current += padding_size; + } + + if (head_table_exists) { + // Set checkSumAdjustment in the head table + *reinterpret_cast(&(retval[ + offset_check_sum_adjustment])) = + 0xb1b0afbaU - otf_check_sum(retval); + } + + return retval; + } +#endif + +} diff --git a/graf2d/mathtext/src/fontembedps.cxx b/graf2d/mathtext/src/fontembedps.cxx new file mode 100644 index 0000000000000..5775b6ea074c8 --- /dev/null +++ b/graf2d/mathtext/src/fontembedps.cxx @@ -0,0 +1,434 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +#include "fontembed.h" +#include +#include +#ifdef WIN32 +#define snprintf _snprintf +#endif + +// ROOT integration +#include "RConfig.h" +#ifdef R__BYTESWAP +#ifndef LITTLE_ENDIAN +#define LITTLE_ENDIAN 1 +#endif // LITTLE_ENDIAN +#include "Byteswap.h" +#define bswap_16(x) Rbswap_16((x)) +#define bswap_32(x) Rbswap_32((x)) +#else // R__BYTESWAP +#ifdef LITTLE_ENDIAN +#undef LITTLE_ENDIAN +#endif // LITTLE_ENDIAN +#endif // R__BYTESWAP + +// References: +// +// Adobe Systems, Inc., PostScript language Document Structuring +// Convention specification (Adobe Systems, Inc., San Jose, CA, 1992), +// version 3.0, section 5.1. +// +// Adobe Systems, Inc., PostScript language reference manual +// (Addison-Wesley, Reading, MA, 1999), 3rd edition, section 5.8.1. +// +// Adobe Systems, Inc., Adobe Type 1 Font Format (Addison-Wesley, +// Reading, MA, 1993), version 1.1 +// +// Adobe Systems, Inc., The Compact Font Format specification, Adobe +// Technical Note 5176 (Adobe, Mountain View, CA, 2003), 4 December +// 2003 document +// +// Adobe Systems, Inc., Type 2 charstring format, Adobe Technical Note +// 5177 (Adobe, San Jose, CA, 2000), 16 March 2000 document + +namespace mathtext { + + void font_embed_postscript_t::append_asciihex( + std::string &ascii, const unsigned char *buffer, + const size_t length) + { + const int width = 64; + int column = 0; + + for(size_t i = 0; i < length; i++) { + char str[3]; + + snprintf(str, 3, "%02hhX", buffer[i]); + ascii.append(str, 2); + column += 2; + if(column >= width) { + ascii.append(1, '\n'); + column = 0; + } + } + } + + unsigned int font_embed_postscript_t::ascii85_line_count( + const uint8_t *buffer, const size_t length) + { + const unsigned int width = 64; + unsigned int column = 0; + unsigned int line = 0; + + if (length >= 4) { + for (size_t i = 0; i < length - 3; i += 4) { + unsigned int b = reinterpret_cast< + const unsigned int *>(buffer)[i >> 2]; + + if (b == 0) { + column++; + if (column == width - 1) { + line++; + column = 0; + } + } + else { + if (column + 5 >= width) { + column += 5 - width; + line++; + } + else { + column += 5; + } + } + } + } + if (column + (length & 3) + 3 >= width) { + line++; + } + + return line; + } + + void font_embed_postscript_t::append_ascii85( + std::string &ascii, const uint8_t *buffer, + const size_t length) + { + const int width = 64; + int column = 0; + + if (length >= 4) { + for (size_t i = 0; i < length - 3; i += 4) { + unsigned int dword = reinterpret_cast< + const unsigned int *>(buffer)[i >> 2]; + + if (dword == 0) { + ascii.append(1, 'z'); + column++; + if (column == width - 1) { + ascii.append(1, '\n'); + column = 0; + } + } + else { +#ifdef LITTLE_ENDIAN + dword = bswap_32(dword); +#endif // LITTLE_ENDIAN + + char str[5]; + + str[4] = static_cast(dword % 85 + '!'); + dword /= 85; + str[3] = static_cast(dword % 85 + '!'); + dword /= 85; + str[2] = static_cast(dword % 85 + '!'); + dword /= 85; + str[1] = static_cast(dword % 85 + '!'); + dword /= 85; + str[0] = static_cast(dword % 85 + '!'); + for (size_t j = 0; j < 5; j++) { + ascii.append(1, str[j]); + column++; + if(column == width) { + ascii.append(1, '\n'); + column = 0; + } + } + } + } + } + + int k = length & 3; + + if(k > 0) { + unsigned int dword = 0; + + memcpy(&dword, buffer + (length & ~3), k); +#ifdef LITTLE_ENDIAN + dword = bswap_32(dword); +#endif // LITTLE_ENDIAN + + char str[5]; + + str[4] = static_cast(dword % 85 + '!'); + dword /= 85; + str[3] = static_cast(dword % 85 + '!'); + dword /= 85; + str[2] = static_cast(dword % 85 + '!'); + dword /= 85; + str[1] = static_cast(dword % 85 + '!'); + dword /= 85; + str[0] = static_cast(dword % 85 + '!'); + for(int j = 0; j < k + 1; j++) { + ascii.append(1, str[j]); + column++; + if(column == width) { + ascii.append(1, '\n'); + column = 0; + } + } + + } + if(column > width - 2) + ascii.append(1, '\n'); + ascii.append("~>"); + } + + std::string font_embed_postscript_t::font_embed_type_1( + std::string &font_name, + const std::vector &font_data) + { + // Embed font type 1 + + struct pfb_segment_header_s { + char always_128; + char type; + unsigned int length; + }; + enum { + TYPE_ASCII = 1, + TYPE_BINARY, + TYPE_EOF + }; + + char magic_number[2]; + std::string ret; + + memcpy(magic_number, &font_data[0], 2); + if(magic_number[0] == '\200') { + // IBM PC format printer font binary + + // FIXME: Maybe the real name can be parsed out of the + // file + font_name = ""; + + struct pfb_segment_header_s segment_header; + size_t offset = 2; + + // The two char elements of struct pfb_segment_header_s + // are most likely aligned to larger than 1 byte + // boundaries, so copy all the elements individually + segment_header.always_128 = font_data[offset]; + segment_header.type = font_data[offset + 1]; + memcpy(&segment_header.length, &font_data[offset + 2], + sizeof(unsigned int)); + offset += sizeof(unsigned int) + 2; + while (segment_header.type != TYPE_EOF) { +#ifdef LITTLE_ENDIAN + segment_header.length = + bswap_32(segment_header.length); +#endif // LITTLE_ENDIAN + char *buffer = new char[segment_header.length]; + + memcpy(buffer, &font_data[offset], + segment_header.length); + offset += segment_header.length; + + switch(segment_header.type) { + case TYPE_ASCII: + // Simple CR -> LF conversion + for (int i = 0; + i < (int)(segment_header.length) - 1; i++) { + if(buffer[i] == '\r' && + buffer[i + 1] != '\n') { + buffer[i] = '\n'; + } + } + if (buffer[segment_header.length - 1] == '\r') { + buffer[segment_header.length - 1] = '\n'; + } + ret.append(buffer, segment_header.length); + break; + case TYPE_BINARY: + append_asciihex( + ret, reinterpret_cast(buffer), + segment_header.length); + break; + default: + {} + } + + delete [] buffer; + } + + return ret; + } + else if(strncmp(magic_number, "%!", 2) == 0) { + // Printer font ASCII + fprintf(stderr, "%s:%d: Printer font ASCII is not " + "implemented\n", __FILE__, __LINE__); + return std::string(); + } + + return std::string(); + } + + std::string font_embed_postscript_t::font_embed_type_2( + std::string &font_name, + const std::vector &font_data) + { + // Embed an OpenType CFF (Type 2) file in ASCII85 encoding + // with the PostScript syntax + + unsigned short cid_encoding_id; + unsigned int cff_offset; + unsigned int cff_length; + + if (!parse_otf_cff_header(font_name, cid_encoding_id, + cff_offset, cff_length, + font_data)) { + return std::string(); + } + + std::vector cff; + + cff.resize(cff_length + 10); + memcpy(&cff[0], "StartData\r", 10); + memcpy(&cff[10], &font_data[cff_offset], cff_length); + + char linebuf[BUFSIZ]; + std::string ret; + + snprintf(linebuf, BUFSIZ, "%%%%BeginResource: FontSet (%s)\n", + font_name.c_str()); + ret.append(linebuf); + ret.append("%%VMusage: 0 0\n"); + ret.append("/FontSetInit /ProcSet findresource begin\n"); + snprintf(linebuf, BUFSIZ, "%%%%BeginData: %u ASCII Lines\n", + ascii85_line_count(&cff[0], cff_length) + 2); + ret.append(linebuf); + snprintf(linebuf, BUFSIZ, + "/%s %u currentfile /ASCII85Decode filter cvx exec\n", + font_name.c_str(), cff_length); + ret.append(linebuf); + append_ascii85(ret, &cff[0], cff_length + 10); + ret.append(1, '\n'); + ret.append("%%EndData\n"); + ret.append("%%EndResource\n"); + + return ret; + } + + std::string font_embed_postscript_t::font_embed_type_42( + std::string &font_name, + const std::vector &font_data) + { + // Embed an TrueType as Type 42 with the PostScript syntax + + double font_bbox[4]; + std::map cid_map; + std::vector char_strings; + + if (!parse_ttf_header(font_name, font_bbox, cid_map, + char_strings, font_data)) { + fprintf(stderr, "%s:%d:\n", __FILE__, __LINE__); + return std::string(); + } + + char linebuf[BUFSIZ]; + std::string ret; + + snprintf(linebuf, BUFSIZ, "%%%%BeginResource: FontSet (%s)\n", + font_name.c_str()); + ret.append(linebuf); + ret.append("%%VMusage: 0 0\n"); + ret.append("11 dict begin\n"); + snprintf(linebuf, BUFSIZ, "/FontName /%s def\n", + font_name.c_str()); + ret.append(linebuf); + ret.append("/Encoding 256 array\n"); + snprintf(linebuf, BUFSIZ, + "0 1 255 { 1 index exch /%s put } for\n", + char_strings[0].c_str()); + ret.append(linebuf); + for (unsigned int code_point = 0; code_point < 256; + code_point++) { + unsigned int glyph_index = cid_map[code_point]; + + if (char_strings[glyph_index] != ".notdef" && + char_strings[glyph_index] != "") { + snprintf(linebuf, BUFSIZ, "dup %u /%s put\n", + code_point, + char_strings[glyph_index].c_str()); + ret.append(linebuf); + } + } + ret.append("readonly def\n"); + ret.append("/PaintType 0 def\n"); // 0 for filled, 2 for stroked + ret.append("/FontMatrix [1 0 0 1 0 0] def\n"); + snprintf(linebuf, BUFSIZ, "/FontBBox [%f %f %f %f] def\n", + font_bbox[0], font_bbox[1], font_bbox[2], font_bbox[3]); + ret.append(linebuf); + ret.append("/FontType 42 def\n"); + // FIXME: XUID generation using the font data's MD5 + ret.append("/sfnts [\n"); + + const size_t block_size = 32262; + size_t offset = 0; + + while (offset < font_data.size()) { + const size_t output_length = + std::min(block_size, font_data.size() - offset); + + ret.append("<\n"); + append_asciihex(ret, &font_data[offset], output_length); + ret.append(">\n"); + offset += output_length; + } + ret.append("] def\n"); + + unsigned int char_strings_count = 0; + + for (std::vector::const_iterator iterator = + char_strings.begin(); + iterator < char_strings.end(); iterator++) { + if (!iterator->empty()) { + char_strings_count++; + } + } + + snprintf(linebuf, BUFSIZ, "/CharStrings %u dict dup begin\n", + char_strings_count); + ret.append(linebuf); + for (unsigned int glyph_index = 0; + glyph_index < char_strings.size(); glyph_index++) { + if (!char_strings[glyph_index].empty()) { + snprintf(linebuf, BUFSIZ, "/%s %u def\n", + char_strings[glyph_index].c_str(), + glyph_index); + ret.append(linebuf); + } + } + ret.append("end readonly def\n"); + ret.append("FontName currentdict end definefont pop\n"); + ret.append("%%EndResource\n"); + + return ret; + } +} diff --git a/graf2d/mathtext/src/mathrender.cxx b/graf2d/mathtext/src/mathrender.cxx new file mode 100644 index 0000000000000..d292dcb5b36fa --- /dev/null +++ b/graf2d/mathtext/src/mathrender.cxx @@ -0,0 +1,636 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +#ifdef WIN32 +// On Windows, Disable the warning: +// "characters beyond first in wide-character constant ignored" +#pragma warning( push ) +#pragma warning( disable : 4066) +#endif + +#include +#include +#include +#include "mathrender.h" + +///////////////////////////////////////////////////////////////////// + +namespace mathtext { + + point_t::operator std::string(void) const + { + std::stringstream stream; + + stream << '(' << _x[0] << ", " << _x[1] << ')'; + + return stream.str(); + } + + const affine_transform_t affine_transform_t::identity = + affine_transform_t(1.0F, 0.0F, 0.0F, 1.0F, 0.0F, 0.0F); + const affine_transform_t affine_transform_t::flip_y = + affine_transform_t(1.0F, 0.0F, 0.0F, -1.0F, 0.0F, 0.0F); + + affine_transform_t affine_transform_t:: + translate(const float tx, const float ty) + { + return affine_transform_t(1.0F, 0.0F, 0.0F, 1.0F, tx, ty); + } + + affine_transform_t affine_transform_t:: + scale(const float sx, const float sy) + { + return affine_transform_t(sx, 0.0F, 0.0F, sy, 0.0F, 0.0F); + } + + affine_transform_t affine_transform_t::rotate(const float angle) + { + float sin_angle; + float cos_angle; + + sin_angle = sin(angle); + cos_angle = cos(angle); + + return affine_transform_t(cos_angle, sin_angle, + -sin_angle, cos_angle, 0, 0); + } + + affine_transform_t::operator std::string(void) const + { + std::stringstream stream; + + stream << '(' << _a[0] << ", " << _a[1] << ", 0)" << std::endl; + stream << '(' << _a[2] << ", " << _a[3] << ", 0)" << std::endl; + stream << '(' << _a[4] << ", " << _a[5] << ", 1)"; + + return stream.str(); + } + +#ifdef __INTEL_COMPILER +#pragma warning(push) +#pragma warning(disable: 869) +#endif // __INTEL_COMPILER + + bool math_text_renderer_t::is_cyrillic(const wchar_t c) + { + return c >= L'\u0400' && c <= L'\u052f'; + } + + bool math_text_renderer_t::is_cjk(const wchar_t c) + { + return + // Acceleration when most characters are below the CJK + // Radicals Supplement + c >= L'\u2e80' && + (// CJK Radicals Supplement ... Yi Radicals + (/* c >= L'\u2e80' && */ c <= L'\ua4cf') || + // Modifier Tone Letters + (c >= L'\ua700' && c <= L'\ua71f') || + // Hangul Syllables + (c >= L'\uac00' && c <= L'\ud7af') || + // CJK Compatibility Ideographs + (c >= L'\uf900' && c <= L'\ufaff') || + // Vertical Forms + (c >= L'\ufe10' && c <= L'\ufe1f') || + // CJK Compatibility Forms + (c >= L'\ufe30' && c <= L'\ufe4f') || + // Halfwidth and Fullwidth Forms + (c >= L'\uff00' && c <= L'\uffef') || + // CJK Unified Ideographs, Extension B + (c >= L'\U00020000' && c <= L'\U0002a6df') || + // CJK Unified Ideographs, Extension C + (c >= L'\U0002a700' && c <= L'\U0002b73f') || + // CJK Compatibility Ideographs + (c >= L'\U0002f800' && c <= L'\U0002fa1f')); + } + +#if 0 + bool math_text_renderer_t::is_wgl_4(const wchar_t c) + { + return true; + } +#endif + + // @see http://www.w3.org/International/questions/qa-scripts + // @see http://www.unicode.org/reports/tr9/tr9-21.html + bool math_text_renderer_t::is_right_to_left(const wchar_t c) + { + return + (// Hebrew ... N'Ko + (c >= L'\u0590' && c <= L'\u07ff') || + // Tifinagh + (c >= L'\u2d30' && c <= L'\u2d7f') || + // Hebrew Presentation Forms ... Arabic Presentation + // Forms A + (c >= L'\ufb1d' && c <= L'\ufdff') || + // Arabic Presentation Forms B + (c >= L'\ufb1d' && c <= L'\ufb4f')); + } + +#if 0 + bool math_text_renderer_t::is_cjk_punctuation_open(const wchar_t c) + { + return false; + } + + bool math_text_renderer_t::is_cjk_punctuation_closed(const wchar_t c) + { + return false; + } +#endif + + bounding_box_t math_text_renderer_t:: + math_bounding_box(const math_text_t::box_t &box, + const unsigned int style) + { + set_font_size(style_size(style), FAMILY_REGULAR); + + const bounding_box_t box_bounding_box = + bounding_box(box._string, FAMILY_REGULAR); + + reset_font_size(FAMILY_REGULAR); + + return box_bounding_box; + } + + void math_text_renderer_t:: + math_text(const point_t origin, + const math_text_t::box_t &box, + const unsigned int style, + const bool render_structure) + { + if (render_structure) { + // Nothing + } + set_font_size(style_size(style), FAMILY_REGULAR); + text_raw(origin[0], origin[1], box._string, FAMILY_REGULAR); + reset_font_size(FAMILY_REGULAR); + } +#ifdef __INTEL_COMPILER +#pragma warning(pop) +#endif // __INTEL_COMPILER + + bounding_box_t math_text_renderer_t:: + math_bounding_box(const wchar_t &glyph, + const unsigned int family, const float size) + { + set_font_size(size, family); + + const std::wstring string = std::wstring(1, glyph); + const bounding_box_t math_symbol_bounding_box = + bounding_box(string, family); + + reset_font_size(family); + + return math_symbol_bounding_box; + } + + void math_text_renderer_t:: + math_text(const point_t origin, const wchar_t &glyph, + const unsigned int family, const float size, + const bool render_structure) + { + set_font_size(size, family); + + const std::wstring string = std::wstring(1, glyph); + + if(render_structure) { + text_with_bounding_box(origin[0], origin[1], string, + family); + } + else { + text_raw(origin[0], origin[1], string, family); + } + reset_font_size(family); + } + + bounding_box_t math_text_renderer_t:: + math_bounding_box(const math_text_t::math_symbol_t &math_symbol, + const unsigned int style) + { + const unsigned int family = math_family(math_symbol); + const float size = style_size(style); + + return math_bounding_box(math_symbol._glyph, family, size); + } + + void math_text_renderer_t:: + math_text(const point_t origin, + const math_text_t::math_symbol_t &math_symbol, + const unsigned int style, + const bool render_structure) + { + const unsigned int family = math_family(math_symbol); + const float size = style_size(style); + + math_text(origin, math_symbol._glyph, family, size, + render_structure); + } + + bounding_box_t math_text_renderer_t:: + math_bounding_box(const math_text_t::math_symbol_t &math_symbol, + const unsigned int style, const float height) + { + std::vector token = + math_tokenize(math_symbol, style, height); + + if(token.empty()) + return bounding_box_t(0, 0, 0, 0, 0, 0); + + std::vector::const_iterator iterator = + token.begin(); + bounding_box_t ret = iterator->_offset + + iterator->_bounding_box; + + for(; iterator != token.end(); iterator++) + ret = ret.merge(iterator->_offset + + iterator->_bounding_box); + + return ret; + } + + void math_text_renderer_t:: + math_text(const point_t origin, + const math_text_t::math_symbol_t &math_symbol, + const unsigned int style, const float height, + const bool render_structure) + { + std::vector token = + math_tokenize(math_symbol, style, height); + + for(std::vector::const_iterator iterator = + token.begin(); + iterator != token.end(); iterator++) + math_text(origin + + transform_pixel_to_logical().linear() * + iterator->_offset, + iterator->_extensible._glyph, + iterator->_extensible._family, + iterator->_extensible._size, render_structure); + } + + ///////////////////////////////////////////////////////////////// + + // A field can be a math symbol or a math list + bounding_box_t math_text_renderer_t:: + math_bounding_box(const std::vector:: + const_iterator &math_list_begin, + const std::vector:: + const_iterator &math_list_end, + unsigned int style) + { + std::vector token = + math_tokenize(math_list_begin, math_list_end, style); + + if(token.empty()) + return bounding_box_t(0, 0, 0, 0, 0, 0); + + std::vector::const_iterator iterator = + token.begin(); + bounding_box_t ret = iterator->_offset + + iterator->_bounding_box; + + for(; iterator != token.end(); iterator++) + ret = ret.merge(iterator->_offset + + iterator->_bounding_box); + + return ret; + } + + void math_text_renderer_t:: + math_text(const point_t origin, + const std::vector:: + const_iterator &math_list_begin, + const std::vector:: + const_iterator &math_list_end, + const unsigned int style, + const bool render_structure) + { + if(render_structure) { + point(origin[0], origin[1]); + rectangle(origin + + math_bounding_box(math_list_begin, + math_list_end, style)); + } + + std::vector::const_iterator + math_list_begin_interior = math_list_begin; + std::vector::const_iterator + math_list_end_interior = math_list_end; + bool delimiter = false; + + if(math_list_begin->_type == + math_text_t::item_t::TYPE_BOUNDARY && + (math_list_end - 1)->_type == + math_text_t::item_t::TYPE_BOUNDARY) { + math_list_begin_interior++; + math_list_end_interior--; + delimiter = true; + } + + std::vector token = + math_tokenize(math_list_begin, math_list_end, style); + std::vector::const_iterator token_iterator = + token.begin(); + + if(delimiter) { + math_text(origin + + transform_pixel_to_logical().linear() * + token_iterator->_offset, + math_list_begin->_atom._nucleus._math_symbol, + style, token_iterator->_delimiter_height, + render_structure); + token_iterator++; + } + + static const math_text_t::item_t fraction_item = + math_text_t::item_t::TYPE_GENERALIZED_FRACTION; + const std::vector::const_iterator + fraction_iterator = + std::find(math_list_begin_interior, + math_list_end_interior, fraction_item); + + if(fraction_iterator != math_list_end_interior) { + const float thickness = fraction_iterator->_length * + default_rule_thickness * style_size(style); + + math_text(origin + + transform_pixel_to_logical().linear() * + token_iterator->_offset, + fraction_iterator + 1, math_list_end_interior, + token_iterator->_style, + render_structure); + token_iterator++; + if(thickness > 0) { + filled_rectangle( + origin + + transform_pixel_to_logical().linear() * + (token_iterator->_offset + + token_iterator->_bounding_box)); + token_iterator++; + } + math_text(origin + + transform_pixel_to_logical().linear() * + token_iterator->_offset, + math_list_begin_interior, fraction_iterator, + token_iterator->_style, + render_structure); + token_iterator++; + } + else + // Incrementally process a math list + for(std::vector::const_iterator + iterator = math_list_begin_interior; + iterator != math_list_end_interior; iterator++) { + switch(iterator->_type) { + case math_text_t::item_t::TYPE_ATOM: + if(render_structure) + rectangle(origin + + transform_pixel_to_logical().linear() * + (token_iterator->_offset + + token_iterator->_bounding_box)); + math_text(origin + + transform_pixel_to_logical().linear() * + token_iterator->_offset, + iterator->_atom, + token_iterator->_style, + render_structure); + token_iterator++; + break; + } + // math_text_t::item_t::TYPE_KERN can be ignored + } + + if(delimiter) + math_text(origin + + transform_pixel_to_logical().linear() * + token_iterator->_offset, + (math_list_end - 1)-> + _atom._nucleus._math_symbol, + token_iterator->_style, + token_iterator->_delimiter_height, + render_structure); + } + + bounding_box_t math_text_renderer_t:: + math_bounding_box(const math_text_t::field_t &field, + const unsigned int style) + { + switch(field._type) { + case math_text_t::field_t::TYPE_MATH_SYMBOL: + return math_bounding_box(field._math_symbol, style); + break; + case math_text_t::field_t::TYPE_BOX: + return math_bounding_box(field._box, style); + break; + case math_text_t::field_t::TYPE_MATH_LIST: + return math_bounding_box(field._math_list.begin(), + field._math_list.end(), style); + break; + default: + return bounding_box_t(0, 0, 0, 0, 0, 0); + } + } + + void math_text_renderer_t:: + math_text(const point_t origin, + const math_text_t::field_t &field, + const unsigned int style, const bool render_structure) + { + switch(field._type) { + case math_text_t::field_t::TYPE_MATH_SYMBOL: + math_text(origin, field._math_symbol, style, + render_structure); + break; + case math_text_t::field_t::TYPE_BOX: + math_text(origin, field._box, style, render_structure); + break; + case math_text_t::field_t::TYPE_MATH_LIST: + math_text(origin, field._math_list.begin(), + field._math_list.end(), style, + render_structure); + break; + } + } + + // TeX algorithm for (three-way) atoms: + // + // See Knuth, The TeXbook (1986), pp. 445f. + bounding_box_t math_text_renderer_t:: + math_bounding_box(const math_text_t::atom_t &atom, + const unsigned int style) + { + std::vector token = + math_tokenize(atom, style); + + if(token.empty()) + return bounding_box_t(0, 0, 0, 0, 0, 0); + + std::vector::const_iterator iterator = + token.begin(); + bounding_box_t ret = iterator->_offset + + iterator->_bounding_box; + + for(; iterator != token.end(); iterator++) + ret = ret.merge(iterator->_offset + + iterator->_bounding_box); + + return ret; + } + + void math_text_renderer_t:: + math_text(const point_t origin, + const math_text_t::atom_t &atom, + const unsigned int style, + const bool render_structure) + { + const float x = origin[0]; + const float y = origin[1]; + + if(render_structure) { + point(x, y); + rectangle(point_t(x, y) + + math_bounding_box(atom, style)); + } + + std::vector token = + math_tokenize(atom, style); + std::vector::const_iterator token_iterator = + token.begin(); + + bounding_box_t nucleus_bounding_box; + + // Rule 11 + if(atom._type == math_text_t::atom_t::TYPE_RAD) { + if(!atom._index.empty()) { + math_text(origin + + transform_pixel_to_logical().linear() * + token_iterator->_offset, + atom._index, token_iterator->_style, + render_structure); + token_iterator++; + } + + const math_text_t::math_symbol_t + symbol_surd("\\surd", style); + + // Surd + math_text(origin + + transform_pixel_to_logical().linear() * + token_iterator->_offset, + symbol_surd, token_iterator->_style, + token_iterator->_delimiter_height, + render_structure); + token_iterator++; + // Rule with clearance + filled_rectangle( + origin + transform_pixel_to_logical().linear() * + (token_iterator->_offset + + token_iterator->_bounding_box)); + // Skip the clearance token, too + token_iterator += 2; + } + if(atom._type == math_text_t::atom_t::TYPE_OP && + atom._nucleus._type == + math_text_t::field_t::TYPE_MATH_SYMBOL) + math_text(origin + + transform_pixel_to_logical().linear() * + token_iterator->_offset, + atom._nucleus._math_symbol._glyph, + FAMILY_STIX_REGULAR, + style_size(style) * if_else_display(style, + large_operator_display_scale, 1.0F), + render_structure); + else + math_text(origin + + transform_pixel_to_logical().linear() * + token_iterator->_offset, + atom._nucleus, token_iterator->_style, + render_structure); + + if(atom._superscript.empty() && atom._subscript.empty()) + return; + + token_iterator++; + + if(atom._superscript.empty()) { + math_text(origin + + transform_pixel_to_logical().linear() * + token_iterator->_offset, + atom._subscript, token_iterator->_style, + render_structure); + return; + } + if(atom._subscript.empty()) { + math_text(origin + + transform_pixel_to_logical().linear() * + token_iterator->_offset, + atom._superscript, token_iterator->_style, + render_structure); + return; + } + math_text(origin + transform_pixel_to_logical().linear() * + token_iterator->_offset, + atom._superscript, token_iterator->_style, + render_structure); + token_iterator++; + math_text(origin + transform_pixel_to_logical().linear() * + token_iterator->_offset, + atom._subscript, token_iterator->_style, + render_structure); + } + + bounding_box_t math_text_renderer_t:: + bounding_box(const math_text_t &textbb, const bool display_style) + { + if(!textbb.well_formed()) + bounding_box(L"*** invalid: " + textbb.code()); + + const unsigned int initial_style = display_style ? + math_text_t::item_t::STYLE_DISPLAY : + math_text_t::item_t::STYLE_TEXT; + + return math_bounding_box(textbb._math_list._math_list, + initial_style); + } + + void math_text_renderer_t:: + text(const float x, const float y, const math_text_t &texti, + const bool display_style) + { + if(!texti.well_formed()) { + text_raw(x, y, L"*** invalid: " + texti.code()); + } + + const unsigned int initial_style = display_style ? + math_text_t::item_t::STYLE_DISPLAY : + math_text_t::item_t::STYLE_TEXT; + + if(texti._render_structure) { + point(x, y); + rectangle(point_t(x, y) + math_bounding_box( + texti._math_list._math_list, initial_style)); + } + math_text(point_t(x, y), texti._math_list._math_list, + initial_style, texti._render_structure); + } + +} +#ifdef WIN32 +#pragma warning( pop ) +#endif diff --git a/graf2d/mathtext/src/mathrenderstyle.cxx b/graf2d/mathtext/src/mathrenderstyle.cxx new file mode 100644 index 0000000000000..6dac54570434d --- /dev/null +++ b/graf2d/mathtext/src/mathrenderstyle.cxx @@ -0,0 +1,475 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +#include +#include +#include "mathrender.h" + +///////////////////////////////////////////////////////////////////// + +namespace mathtext { + + ///////////////////////////////////////////////////////////////// + + float math_text_renderer_t:: + style_size(const unsigned int style) const + { + // Intel C++ Compiler 10.1 chokes on this if declared static + // const and using -O1: + const float size[math_text_t::item_t::NSTYLE - 1] = { + script_script_ratio, script_script_ratio, + script_ratio, script_ratio, 1.0F, 1.0F, 1.0F, 1.0F + }; + + if(style == math_text_t::item_t::STYLE_UNKNOWN || + style >= math_text_t::item_t::NSTYLE) + return font_size(); + + return size[style - 1] * font_size(); + } + + bool math_text_renderer_t:: + is_display_style(const unsigned int style) const + { + switch(style) { + case math_text_t::item_t::STYLE_DISPLAY: + case math_text_t::item_t::STYLE_DISPLAY_PRIME: + return true; + default: + return false; + } + } + + bool math_text_renderer_t:: + is_script_style(const unsigned int style) const + { + switch(style) { + case math_text_t::item_t::STYLE_SCRIPT: + case math_text_t::item_t::STYLE_SCRIPT_PRIME: + case math_text_t::item_t::STYLE_SCRIPT_SCRIPT: + case math_text_t::item_t::STYLE_SCRIPT_SCRIPT_PRIME: + return true; + default: + return false; + } + } + + unsigned int math_text_renderer_t:: + prime_style(const unsigned int style) const + { + switch(style) { + case math_text_t::item_t::STYLE_DISPLAY: + return math_text_t::item_t::STYLE_DISPLAY_PRIME; + case math_text_t::item_t::STYLE_TEXT: + return math_text_t::item_t::STYLE_TEXT_PRIME; + case math_text_t::item_t::STYLE_SCRIPT: + return math_text_t::item_t::STYLE_SCRIPT_PRIME; + case math_text_t::item_t::STYLE_SCRIPT_SCRIPT: + return math_text_t::item_t::STYLE_SCRIPT_SCRIPT_PRIME; + default: + return style; + } + } + + bool math_text_renderer_t:: + is_prime_style(const unsigned int style) const + { + switch(style) { + case math_text_t::item_t::STYLE_DISPLAY_PRIME: + case math_text_t::item_t::STYLE_TEXT_PRIME: + case math_text_t::item_t::STYLE_SCRIPT_PRIME: + case math_text_t::item_t::STYLE_SCRIPT_SCRIPT_PRIME: + return true; + default: + return false; + } + } + + // Knuth, The TeXbook (1986), p. 441 + + unsigned int math_text_renderer_t:: + next_superscript_style(const unsigned int style) const + { + switch(style) { + case math_text_t::item_t::STYLE_DISPLAY: + case math_text_t::item_t::STYLE_TEXT: + return math_text_t::item_t::STYLE_SCRIPT; + case math_text_t::item_t::STYLE_DISPLAY_PRIME: + case math_text_t::item_t::STYLE_TEXT_PRIME: + return math_text_t::item_t::STYLE_SCRIPT_PRIME; + case math_text_t::item_t::STYLE_SCRIPT: + case math_text_t::item_t::STYLE_SCRIPT_SCRIPT: + return math_text_t::item_t::STYLE_SCRIPT_SCRIPT; + case math_text_t::item_t::STYLE_SCRIPT_PRIME: + case math_text_t::item_t::STYLE_SCRIPT_SCRIPT_PRIME: + return math_text_t::item_t::STYLE_SCRIPT_SCRIPT_PRIME; + default: + return style; + } + } + + unsigned int math_text_renderer_t:: + next_subscript_style(const unsigned int style) const + { + return prime_style(next_superscript_style(style)); + } + + unsigned int math_text_renderer_t:: + next_numerator_style(const unsigned int style) const + { + switch(style) { + case math_text_t::item_t::STYLE_DISPLAY: + return math_text_t::item_t::STYLE_TEXT; + case math_text_t::item_t::STYLE_DISPLAY_PRIME: + return math_text_t::item_t::STYLE_TEXT_PRIME; + default: + return next_superscript_style(style); + } + } + + unsigned int math_text_renderer_t:: + next_denominator_style(const unsigned int style) const + { + return if_else_display( + style, + static_cast( + math_text_t::item_t::STYLE_TEXT_PRIME), + next_subscript_style(style)); + } + + // The most elementary building block is the math symbol + float math_text_renderer_t::x_height(const unsigned int style) + { + const unsigned int family = FAMILY_ITALIC; + const float size = style_size(style); + + set_font_size(size, family); + + bounding_box_t math_symbol_bounding_box = + bounding_box(L"x", family); + + reset_font_size(family); + + return math_symbol_bounding_box.ascent(); + } + + float math_text_renderer_t::quad(const unsigned int style) + const + { + const float size = style_size(style); + + return size; + } + + void math_text_renderer_t:: + post_process_atom_type_initial(unsigned int &atom_type) const + { + // Rule 5, initial atom + if(atom_type == math_text_t::atom_t::TYPE_BIN) + atom_type = math_text_t::atom_t::TYPE_ORD; + } + + void math_text_renderer_t:: + post_process_atom_type_interior(unsigned int & + previous_atom_type, + unsigned int &atom_type) const + { + // Rule 5, interior/final atom + if(atom_type == math_text_t::atom_t::TYPE_BIN) + switch(previous_atom_type) { + case math_text_t::atom_t::TYPE_BIN: + case math_text_t::atom_t::TYPE_OP: + case math_text_t::atom_t::TYPE_REL: + case math_text_t::atom_t::TYPE_OPEN: + case math_text_t::atom_t::TYPE_PUNCT: + atom_type = math_text_t::atom_t::TYPE_ORD; + break; + } + // Rule 6 + else if(previous_atom_type == math_text_t::atom_t::TYPE_BIN) + switch(atom_type) { + case math_text_t::atom_t::TYPE_REL: + case math_text_t::atom_t::TYPE_CLOSE: + case math_text_t::atom_t::TYPE_PUNCT: + previous_atom_type = math_text_t::atom_t::TYPE_ORD; + break; + } + } + + bool math_text_renderer_t:: + valid_accent(bool &vertical_alignment, + const std::vector:: + const_iterator &iterator, + const std::vector:: + const_iterator &math_list_end) + const + { + if(iterator->_atom._type == math_text_t::atom_t::TYPE_ACC) { + std::vector::const_iterator + iterator_next = iterator + 1; + + vertical_alignment = true; + return iterator_next != math_list_end && + iterator_next->_type == + math_text_t::item_t::TYPE_ATOM; + } + else if(iterator->_atom.is_combining_diacritical()) { + std::vector::const_iterator + iterator_next = iterator + 1; + + vertical_alignment = false; + return iterator_next != math_list_end && + iterator_next->_type == + math_text_t::item_t::TYPE_ATOM; + } + else + return false; + } + + float math_text_renderer_t::kerning_mu(const float amount) const + { + // Rule 2 + return amount / 18.0F * font_size(); + } + + float math_text_renderer_t:: + math_spacing(unsigned int left_type, unsigned int right_type, + unsigned int style) const + { + const unsigned int left_type_modified = + left_type <= (unsigned int) math_text_t::atom_t::TYPE_INNER ? + left_type : (unsigned int) math_text_t::atom_t::TYPE_ORD; + const unsigned int right_type_modified = + right_type <= (unsigned int) math_text_t::atom_t::TYPE_INNER ? + right_type : (unsigned int) math_text_t::atom_t::TYPE_ORD; + const unsigned int space = math_text_t::atom_t:: + spacing(left_type_modified, right_type_modified, + is_script_style(style)); + float mu_skip; + + switch(space) { + case 1: mu_skip = thin_mu_skip; break; + case 2: mu_skip = med_mu_skip; break; + case 3: mu_skip = thick_mu_skip; break; + default: mu_skip = 0.0F; + } + + return kerning_mu(mu_skip); + } + + unsigned int math_text_renderer_t:: + math_family(const math_text_t::math_symbol_t &math_symbol) const + { + // Use the text font for Latin, Greek, Cyrillic and the minus + // sign, and STIX for everything else. + if(math_symbol._glyph <= L'\u017e' || + (math_symbol._glyph >= L'\u0384' && + math_symbol._glyph <= L'\u03ce') || + (math_symbol._glyph >= L'\u0400' && + math_symbol._glyph <= L'\u052f') || + math_symbol._glyph == L'\u2212') { + return math_symbol._family; + } + else { + switch(math_symbol._family) { + case FAMILY_REGULAR: + return FAMILY_STIX_REGULAR; + case FAMILY_ITALIC: + return FAMILY_STIX_ITALIC; + case FAMILY_BOLD: + return FAMILY_STIX_BOLD; + case FAMILY_BOLD_ITALIC: + return FAMILY_STIX_BOLD_ITALIC; + case FAMILY_STIX_REGULAR: + case FAMILY_STIX_ITALIC: + case FAMILY_STIX_BOLD: + case FAMILY_STIX_BOLD_ITALIC: + case FAMILY_STIX_SIZE_1_REGULAR: + case FAMILY_STIX_SIZE_1_BOLD: + case FAMILY_STIX_SIZE_2_REGULAR: + case FAMILY_STIX_SIZE_2_BOLD: + case FAMILY_STIX_SIZE_3_REGULAR: + case FAMILY_STIX_SIZE_3_BOLD: + case FAMILY_STIX_SIZE_4_REGULAR: + case FAMILY_STIX_SIZE_4_BOLD: + case FAMILY_STIX_SIZE_5_REGULAR: + return math_symbol._family; + default: + return FAMILY_STIX_REGULAR; + } + } + } + + void math_text_renderer_t:: + large_family(unsigned long &nfamily, const unsigned int *&family, + const math_text_t::math_symbol_t &math_symbol) const + { + static const unsigned long nlarge_family = 5; + static const unsigned int + large_family_regular[nlarge_family] = { + FAMILY_STIX_REGULAR, + FAMILY_STIX_SIZE_1_REGULAR, + FAMILY_STIX_SIZE_2_REGULAR, + FAMILY_STIX_SIZE_3_REGULAR, + FAMILY_STIX_SIZE_4_REGULAR, + }; + static const unsigned int + large_family_bold[nlarge_family] = { + FAMILY_STIX_BOLD, + FAMILY_STIX_SIZE_1_BOLD, + FAMILY_STIX_SIZE_2_BOLD, + FAMILY_STIX_SIZE_3_BOLD, + FAMILY_STIX_SIZE_4_BOLD, + }; + + nfamily = nlarge_family; + family = math_symbol.bold() ? + large_family_bold : large_family_regular; + } + + void math_text_renderer_t:: + extensible_glyph(wchar_t glyph[4], unsigned long &nrepeat, + const math_text_t::math_symbol_t &math_symbol, + const unsigned int style, const float height) + { + // See Knuth, The METAFONTbook (1986), p. 318 + enum { + GLYPH_TOP = 0, + GLYPH_MIDDLE, + GLYPH_BOTTOM, + GLYPH_REPEATABLE, + NGLYPH + }; + + switch(math_symbol._glyph) { + case L'(': + glyph[GLYPH_TOP] = L'\u239b'; + glyph[GLYPH_MIDDLE] = L'\0'; + glyph[GLYPH_BOTTOM] = L'\u239d'; + glyph[GLYPH_REPEATABLE] = L'\u239c'; + break; + case L')': + glyph[GLYPH_TOP] = L'\u239e'; + glyph[GLYPH_MIDDLE] = L'\0'; + glyph[GLYPH_BOTTOM] = L'\u23a0'; + glyph[GLYPH_REPEATABLE] = L'\u239f'; + break; + case L'[': + glyph[GLYPH_TOP] = L'\u23a1'; + glyph[GLYPH_MIDDLE] = L'\0'; + glyph[GLYPH_BOTTOM] = L'\u23a3'; + glyph[GLYPH_REPEATABLE] = L'\u23a2'; + break; + case L']': + glyph[GLYPH_TOP] = L'\u23a4'; + glyph[GLYPH_MIDDLE] = L'\0'; + glyph[GLYPH_BOTTOM] = L'\u23a6'; + glyph[GLYPH_REPEATABLE] = L'\u23a5'; + break; + case L'{': + glyph[GLYPH_TOP] = L'\u23a7'; + glyph[GLYPH_MIDDLE] = L'\u23a8'; + glyph[GLYPH_BOTTOM] = L'\u23a9'; + glyph[GLYPH_REPEATABLE] = L'\u23aa'; + break; + case L'|': + glyph[GLYPH_TOP] = math_symbol._glyph; + glyph[GLYPH_MIDDLE] = L'\0'; + glyph[GLYPH_BOTTOM] = math_symbol._glyph; + glyph[GLYPH_REPEATABLE] = math_symbol._glyph; + break; + case L'}': + glyph[GLYPH_TOP] = L'\u23ab'; + glyph[GLYPH_MIDDLE] = L'\u23ac'; + glyph[GLYPH_BOTTOM] = L'\u23ad'; + glyph[GLYPH_REPEATABLE] = L'\u23aa'; + break; +#if 0 + // FIXME: \lmoustache, \rmoustache, \radical require + // horizontal offsets + case L'\u211a': // \lmoustache + glyph[GLYPH_TOP] = L'\0'; + glyph[GLYPH_MIDDLE] = L'\0'; + glyph[GLYPH_BOTTOM] = L'\u23b7'; + glyph[GLYPH_REPEATABLE] = L'\u23b9'; + break; + case L'\u23b0': // \rmoustache + glyph[GLYPH_TOP] = L'\u239b'; + glyph[GLYPH_MIDDLE] = L'\0'; + glyph[GLYPH_BOTTOM] = L'\u23a0'; + glyph[GLYPH_REPEATABLE] = L'\u239c'; + break; + case L'\u23b1': // \radical + glyph[GLYPH_TOP] = L'\u239e'; + glyph[GLYPH_MIDDLE] = L'\0'; + glyph[GLYPH_BOTTOM] = L'\u239d'; + glyph[GLYPH_REPEATABLE] = L'\u239f'; + break; +#endif + default: + glyph[GLYPH_TOP] = L'\0'; + glyph[GLYPH_MIDDLE] = L'\0'; + glyph[GLYPH_BOTTOM] = L'\0'; + glyph[GLYPH_REPEATABLE] = L'\0'; + } + + const unsigned int family = math_symbol._glyph == L'|' ? + FAMILY_STIX_REGULAR : FAMILY_STIX_SIZE_1_REGULAR; + const float size = style_size(style); + + if(glyph[GLYPH_REPEATABLE] != L'\0') { + bounding_box_t bounding_box_sum(0, 0, 0, 0, 0, 0); + float current_y = 0; + + for(unsigned long i = GLYPH_TOP; i <= GLYPH_BOTTOM; + i++) { + if(glyph[i] != L'\0') { + bounding_box_t glyph_bounding_box = + math_bounding_box(glyph[i], family, size); + + current_y += glyph_bounding_box.descent(); + bounding_box_sum = bounding_box_sum. + merge(point_t(0, current_y) + + glyph_bounding_box); + current_y += glyph_bounding_box.ascent(); + } + } + + const bounding_box_t bounding_box_repeatable = + math_bounding_box(glyph[GLYPH_REPEATABLE], family, + size); + const float remaining_height = + height - bounding_box_sum.height(); + unsigned long repeat_ratio = 0; + if (bounding_box_repeatable.height() !=0) { + repeat_ratio = + (unsigned long)ceil( + remaining_height / + bounding_box_repeatable.height()); + } + nrepeat = glyph[GLYPH_MIDDLE] == L'\0' ? + repeat_ratio : ((repeat_ratio + 1UL) >> 1); + } + else + nrepeat = 0; + } + + // Font parameters +#include "table/mathfontparam.h" + +} diff --git a/graf2d/mathtext/src/mathrendertoken.cxx b/graf2d/mathtext/src/mathrendertoken.cxx new file mode 100644 index 0000000000000..597d7ec2e8833 --- /dev/null +++ b/graf2d/mathtext/src/mathrendertoken.cxx @@ -0,0 +1,899 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +#include +#include +#include "mathrender.h" + +///////////////////////////////////////////////////////////////////// + +namespace mathtext { + + ///////////////////////////////////////////////////////////////// + // Math List Tokenization + + std::vector + math_text_renderer_t:: + math_tokenize(const math_text_t::math_symbol_t &math_symbol, + const unsigned int style, const float height) + { + if(math_symbol._glyph == L'.') + return std::vector(); + + enum { + GLYPH_TOP = 0, + GLYPH_MIDDLE, + GLYPH_BOTTOM, + GLYPH_REPEATABLE, + NGLYPH + }; + const unsigned int family = math_family(math_symbol); + const float size = style_size(style); + const bounding_box_t normal_bounding_box = + math_bounding_box(math_symbol._glyph, family, size); + + if(normal_bounding_box.height() >= height) { + const math_token_t token(normal_bounding_box, + math_symbol._glyph, family, + size); + + return std::vector(1, token); + } + + unsigned long nmath_symbol_large_family; + const unsigned int *math_symbol_large_family; + + large_family(nmath_symbol_large_family, + math_symbol_large_family, math_symbol); + + for(unsigned int i = 0; i < nmath_symbol_large_family; i++) { + const bounding_box_t large_bounding_box = + math_bounding_box(math_symbol._glyph, + math_symbol_large_family[i], size); + + if(large_bounding_box.height() >= height) { + const math_token_t token(large_bounding_box, + math_symbol._glyph, + math_symbol_large_family[i], + size); + + return std::vector(1, token); + } + } + + // Extensible glyph after the TFM charlist mechanism, see + // Knuth, The METAFONTbook (1986), p. 317f. + + wchar_t glyph[NGLYPH]; + unsigned long nrepeat; + + extensible_glyph(glyph, nrepeat, math_symbol, style, height); + + if(glyph[GLYPH_BOTTOM] != L'\0' && + glyph[GLYPH_REPEATABLE] != L'\0') { + static const unsigned int extensible_family = + math_symbol._glyph == L'|' ? FAMILY_STIX_REGULAR : + FAMILY_STIX_SIZE_1_REGULAR; + const bounding_box_t bounding_box_bottom = + math_bounding_box(glyph[GLYPH_BOTTOM], + extensible_family, size); + std::vector token_list; + + token_list.push_back(math_token_t( + bounding_box_bottom, glyph[GLYPH_BOTTOM], + extensible_family, size)); + float current_y = 0; + + current_y += bounding_box_bottom.ascent(); + for(unsigned long i = 0; i < nrepeat; i++) { + const bounding_box_t bounding_box_repeatable = + math_bounding_box(glyph[GLYPH_REPEATABLE], + extensible_family, size); + + current_y += bounding_box_repeatable.descent(); + token_list.push_back(math_token_t( + point_t(0, current_y), bounding_box_repeatable, + glyph[GLYPH_REPEATABLE], extensible_family, + size)); + current_y += bounding_box_repeatable.ascent(); + } + if(glyph[GLYPH_MIDDLE] != L'\0') { + const bounding_box_t bounding_box_middle = + math_bounding_box(glyph[GLYPH_MIDDLE], + extensible_family, size); + + current_y += bounding_box_middle.descent(); + token_list.push_back(math_token_t( + point_t(0, current_y), bounding_box_middle, + glyph[GLYPH_MIDDLE], extensible_family, size)); + current_y += bounding_box_middle.ascent(); + for(unsigned long i = 0; i < nrepeat; i++) { + const bounding_box_t bounding_box_repeatable = + math_bounding_box(glyph[GLYPH_REPEATABLE], + extensible_family, size); + + current_y += bounding_box_repeatable.descent(); + token_list.push_back(math_token_t( + point_t(0, current_y), + bounding_box_repeatable, + glyph[GLYPH_REPEATABLE], extensible_family, + size)); + current_y += bounding_box_repeatable.ascent(); + } + } + + const bounding_box_t bounding_box_top = + math_bounding_box(glyph[GLYPH_TOP], + extensible_family, size); + + current_y += bounding_box_top.descent(); + token_list.push_back(math_token_t( + point_t(0, current_y), bounding_box_top, + glyph[GLYPH_TOP], extensible_family, size)); + + return token_list; + } + + const math_token_t token(normal_bounding_box, + math_symbol._glyph, family, size); + + return std::vector(1, token); + } + + std::vector + math_text_renderer_t:: + math_tokenize(const std::vector:: + const_iterator &math_list_begin, + const std::vector:: + const_iterator &math_list_end, + const unsigned int style) + { + const float size = style_size(style); + const float style_axis_height = axis_height * size; + unsigned int previous_atom_type = + math_text_t::atom_t::TYPE_UNKNOWN; + float current_x = 0; + bool has_accent = false; + + // Rule 19 + std::vector::const_iterator + math_list_begin_interior = math_list_begin; + std::vector::const_iterator + math_list_end_interior = math_list_end; + static const math_text_t::item_t fraction_item = + math_text_t::item_t::TYPE_GENERALIZED_FRACTION; + const std::vector::const_iterator + fraction_iterator = + std::find(math_list_begin_interior, + math_list_end_interior, fraction_item); + const bool generalized_fraction = + fraction_iterator != math_list_end_interior; + bool delimiter = false; + float delimiter_height = 0.f; + bounding_box_t bounding_box_delimiter_left(0, 0, 0, 0, 0, 0); + bounding_box_t bounding_box_delimiter_right(0, 0, 0, 0, 0, 0); + + if(math_list_begin->_type == + math_text_t::item_t::TYPE_BOUNDARY && + (math_list_end - 1)->_type == + math_text_t::item_t::TYPE_BOUNDARY) { + math_list_begin_interior++; + math_list_end_interior--; + delimiter = true; + + const bounding_box_t bounding_box_interior = + math_bounding_box(math_list_begin_interior, + math_list_end_interior, style); + const float extension = + std::max(bounding_box_interior.ascent() - + style_axis_height, + bounding_box_interior.descent() + + style_axis_height); + + delimiter_height = extension * 0.002F * delimiter_factor; + if(generalized_fraction) + // Rule 15e + delimiter_height = std::max(delimiter_height, + if_else_display(style, delim_1, delim_2) * size); + + bounding_box_delimiter_left = + math_bounding_box(math_list_begin->_atom. + _nucleus._math_symbol, + style, delimiter_height); + bounding_box_delimiter_right = + math_bounding_box((math_list_end - 1)->_atom. + _nucleus._math_symbol, + style, delimiter_height); + } + + std::vector token_list; + + if(delimiter) { + // Standard advance mode + + // post_process_atom_type_initial(atom_type) is not + // necessary, since the current item is guaranteed not to + // be of type Bin. + + // FIXME: Must be in starting style. + + const float shift_delimiter_left = style_axis_height - + bounding_box_delimiter_left.vertical_center(); + + token_list.push_back(math_token_t( + point_t(current_x, shift_delimiter_left), + bounding_box_delimiter_left, style, + delimiter_height)); + + current_x += bounding_box_delimiter_left.advance(); + previous_atom_type = math_list_begin->_atom._type; + } + + if(generalized_fraction) { + // Rule 15a, 15b + const float thickness = fraction_iterator->_length * + default_rule_thickness * size; + const bounding_box_t numerator_bounding_box = + math_bounding_box(math_list_begin_interior, + fraction_iterator, + next_numerator_style(style)); + const bounding_box_t denominator_bounding_box = + math_bounding_box(fraction_iterator + 1, + math_list_end_interior, + next_denominator_style(style)); + const float min_shift_up = + if_else_display(style, num_1, + thickness > 0 ? num_2 : num_3) * + size; + const float min_shift_down = + if_else_display(style, denom_1, denom_2) * size; + float shift_up; + float shift_down; + + if(thickness <= 0) { + // Rule 15c (\atop) + const float min_clearance = + if_else_display(style, 7.0F, 3.0F) * + default_rule_thickness * size; + const float actual_clearance = + (min_shift_up - + numerator_bounding_box.descent()) - + (denominator_bounding_box.ascent() - + min_shift_down); + + if(actual_clearance < min_clearance) { + const float difference = 0.5F * + (min_clearance - actual_clearance); + + shift_up = min_shift_up + difference; + shift_down = min_shift_down + difference; + } + else { + shift_up = min_shift_up; + shift_down = min_shift_down; + } + } + else { + // Rule 15d (\over) + const float min_bar_clearance = + if_else_display(style, 3.0F, 1.0F) * thickness; + const float actual_numerator_clearance = + (min_shift_up - + numerator_bounding_box.descent()) - + (style_axis_height + 0.5F * thickness); + const float actual_denominator_clearance = + (style_axis_height - 0.5F * thickness) - + (denominator_bounding_box.ascent() - + min_shift_down); + + if(actual_numerator_clearance < + min_bar_clearance) { + const float difference = + (min_bar_clearance - + actual_numerator_clearance); + + shift_up = min_shift_up + difference; + } + else + shift_up = min_shift_up; + if(actual_denominator_clearance < + min_bar_clearance) { + const float difference = + (min_bar_clearance - + actual_denominator_clearance); + + shift_down = min_shift_down + difference; + } + else + shift_down = min_shift_down; + } + + const float horizontal_center_difference = + numerator_bounding_box.horizontal_center() - + denominator_bounding_box.horizontal_center(); + float horizontal_shift_numerator; + float horizontal_shift_denominator; + + if(horizontal_center_difference > 0) { + horizontal_shift_numerator = 0; + horizontal_shift_denominator = + horizontal_center_difference; + } + else { + horizontal_shift_numerator = + -horizontal_center_difference; + horizontal_shift_denominator = 0; + } + + token_list.push_back(math_token_t( + point_t(current_x + horizontal_shift_denominator, + -shift_down), + denominator_bounding_box, + next_denominator_style(style))); + if(thickness > 0) { +#if 0 + const float constrained_thickness = + std::max(1.0F, thickness); +#endif + const float left = + std::min(numerator_bounding_box.left(), + denominator_bounding_box.left()); + const float right = + std::max(numerator_bounding_box.right(), + denominator_bounding_box.right()); + + token_list.push_back(math_token_t( + point_t(current_x + left, + style_axis_height - 0.5F * thickness), + bounding_box_t(0, 0, right - left, thickness, + 0, 0), + style)); + } + token_list.push_back(math_token_t( + point_t(current_x + horizontal_shift_numerator, + shift_up), + numerator_bounding_box, + next_numerator_style(style))); + + const float advance = + std::max(horizontal_shift_numerator + + numerator_bounding_box.left() + + numerator_bounding_box.right(), + horizontal_shift_denominator + + denominator_bounding_box.left() + + denominator_bounding_box.right()); + + current_x += advance; + } + else + // Incrementally process a math list + for(std::vector::const_iterator + iterator = math_list_begin_interior; + iterator != math_list_end_interior; iterator++) { + unsigned int atom_type; + bounding_box_t item_bounding_box; + unsigned int current_style = has_accent ? + prime_style(style) : style; + bool accent; + bool vertical_alignment; + + switch(iterator->_type) { + case math_text_t::item_t::TYPE_ATOM: + atom_type = iterator->_atom._type; + item_bounding_box = + math_bounding_box(iterator->_atom, + current_style); + accent = valid_accent(vertical_alignment, + iterator, math_list_end); + if(accent) { + // Accent advance mode + const std::vector:: + const_iterator iterator_next = + iterator + 1; + const bounding_box_t next_item_bounding_box = + math_bounding_box(iterator_next->_atom, + style); + const float horizontal_shift = + (iterator == math_list_begin ? 0.0F : + math_spacing(previous_atom_type, + atom_type, style)) + + next_item_bounding_box. + horizontal_center() + + 0.5F * next_item_bounding_box. + italic_correction() - + item_bounding_box.horizontal_center(); + const float vertical_shift = + vertical_alignment ? + std::max(0.0F, + next_item_bounding_box.ascent() - + x_height(style)) : 0.0F; + + token_list.push_back(math_token_t( + point_t(current_x + horizontal_shift, + vertical_shift), + item_bounding_box, style)); + has_accent = true; + } + else { + // Standard advance mode + if(iterator == math_list_begin) + post_process_atom_type_initial(atom_type); + else { + post_process_atom_type_interior( + previous_atom_type, atom_type); + + const float horizontal_shift = + math_spacing(previous_atom_type, + atom_type, + current_style); + + current_x += + horizontal_shift; + } + + token_list.push_back(math_token_t( + point_t(current_x, 0), item_bounding_box, + current_style)); + current_x += item_bounding_box.advance(); + has_accent = false; + previous_atom_type = atom_type; + } + break; + case math_text_t::item_t::TYPE_KERN: + // Rule 2 + current_x += kerning_mu(iterator->_length); + break; + } + } + + // Rule 19 (again) + if(delimiter) { + unsigned int atom_type = + (math_list_end - 1)->_atom._type; + // Standard advance mode + + // FIXME: Must be in starting style. + + post_process_atom_type_interior(previous_atom_type, + atom_type); + + const float horizontal_shift = + math_spacing(previous_atom_type, atom_type, style); + + current_x += horizontal_shift; + + const float shift_delimiter_right = style_axis_height - + bounding_box_delimiter_right.vertical_center(); + + token_list.push_back(math_token_t( + point_t(current_x, shift_delimiter_right), + bounding_box_delimiter_right, style, + delimiter_height)); + } + + return token_list; + } + + std::vector + math_text_renderer_t:: + math_tokenize(const math_text_t::atom_t &atom, + const unsigned int style) + { + const float size = style_size(style); + std::vector token_list; + bounding_box_t nucleus_bounding_box; + float current_x = 0; + float nucleus_shift_up = 0; + + // Rule 11 + if(atom._type == math_text_t::atom_t::TYPE_RAD) { + float style_radical_rule_thickness = + default_rule_thickness * size; + const float min_clearance = + style_radical_rule_thickness + 0.25F * + if_else_display(style, x_height(style), + style_radical_rule_thickness); + const bounding_box_t bounding_box_radicand = + math_bounding_box(atom._nucleus, + prime_style(style)); + const float min_delimiter_height = + bounding_box_radicand.height() + min_clearance + + style_radical_rule_thickness; + const math_text_t::math_symbol_t + symbol_surd("\\surd", style); + const bounding_box_t bounding_box_surd = + math_bounding_box(symbol_surd, style, + min_delimiter_height); + const float surd_intrinsic_shift_down = + bounding_box_surd.ascent() - + style_radical_rule_thickness; + const float modified_descent = + bounding_box_surd.descent() + + surd_intrinsic_shift_down; + const float clearance = modified_descent > + bounding_box_radicand.height() + min_clearance ? + 0.5F * (min_clearance + modified_descent - + bounding_box_radicand.height()) : + min_clearance; + + if(!atom._index.empty()) { + // The positive space of 5 mu to the index is hard + // wired in plain.tex + current_x += (5.0F / 18.0F) * size; + + const bounding_box_t bounding_box_index = + math_bounding_box(atom._index, + math_text_t::item_t::STYLE_SCRIPT_SCRIPT); + const float radical_height = + (std::max(math_bounding_box( + atom._index, prime_style(style)).ascent(), + bounding_box_radicand.ascent() + + clearance + + 2.0F * style_radical_rule_thickness) - + std::max(math_bounding_box( + atom._index, prime_style(style)).descent(), + bounding_box_radicand.descent())); + + nucleus_bounding_box = + point_t(current_x, 0.6F * radical_height) + + math_bounding_box( + atom._index, + math_text_t::item_t::STYLE_SCRIPT_SCRIPT); + token_list.push_back(math_token_t( + point_t(current_x, 0.6F * radical_height), + bounding_box_index, + math_text_t::item_t::STYLE_SCRIPT_SCRIPT)); + // The negative space of 10 mu to the surd is hard + // wired in plain.tex + current_x += bounding_box_index.advance() - + (10.0F / 18.0F) * size; + } + + const float radicand_ascent_clearance = + bounding_box_radicand.ascent() + clearance; + + nucleus_bounding_box = nucleus_bounding_box.merge( + point_t(current_x, + radicand_ascent_clearance - + surd_intrinsic_shift_down) + + bounding_box_surd); + token_list.push_back(math_token_t( + point_t(current_x, + radicand_ascent_clearance - + surd_intrinsic_shift_down), + bounding_box_surd, style, min_delimiter_height)); + current_x += bounding_box_surd.advance(); + + const float constrained_thickness = +#if 0 + // Pixel height constraint + std::max(1.0F, style_radical_rule_thickness) +#else + style_radical_rule_thickness +#endif + ; + static const float surd_rule_correction_x = -1.5F; + static const float surd_rule_correction_y = -0.5F; + + const point_t origin_rule = + point_t(current_x, radicand_ascent_clearance); + const bounding_box_t bounding_box_rule = + bounding_box_t(surd_rule_correction_x * + constrained_thickness, + surd_rule_correction_y * + constrained_thickness, + bounding_box_radicand.advance(), + (surd_rule_correction_y + 1.0F) * + constrained_thickness, + 0, 0); + + nucleus_bounding_box = nucleus_bounding_box.merge( + origin_rule + bounding_box_rule); + token_list.push_back(math_token_t( + origin_rule, bounding_box_rule, style)); + + const bounding_box_t bounding_box_clearance = + bounding_box_t(0, -2.0F * constrained_thickness, + bounding_box_radicand.advance(), + constrained_thickness, + 0, 0); + + nucleus_bounding_box = nucleus_bounding_box.merge( + origin_rule + bounding_box_clearance); + token_list.push_back(math_token_t( + origin_rule, bounding_box_clearance, style)); + + const point_t origin_radicand = point_t(current_x, 0); + + nucleus_bounding_box = nucleus_bounding_box.merge( + origin_radicand + bounding_box_radicand); + token_list.push_back(math_token_t( + origin_radicand, bounding_box_radicand, + prime_style(style))); + current_x += bounding_box_radicand.advance(); + } + else if(atom._type == math_text_t::atom_t::TYPE_OP) { + const bool limits = + atom._limits == math_text_t::atom_t::LIMITS_LIMITS || + (atom._limits == + math_text_t::atom_t::LIMITS_DISPLAYLIMITS && + is_display_style(style)); + + if(atom._nucleus._type == + math_text_t::field_t::TYPE_MATH_SYMBOL) { + // Rule 13 + nucleus_bounding_box = math_bounding_box( + atom._nucleus._math_symbol._glyph, + FAMILY_STIX_REGULAR, + size * if_else_display(style, + large_operator_display_scale, 1.0F)); + nucleus_shift_up = + axis_height * size - + nucleus_bounding_box.vertical_center(); + if(limits && atom._subscript.empty()) + nucleus_bounding_box.advance() += + nucleus_bounding_box.italic_correction(); + } + else + nucleus_bounding_box = + math_bounding_box(atom._nucleus, style); + + if(limits && !(atom._superscript.empty() && + atom._subscript.empty())) { + // Rule 13a + const unsigned int superscript_style = + next_superscript_style(style); + const unsigned int subscript_style = + next_subscript_style(style); + + if(atom._superscript.empty()) { + const bounding_box_t subscript_bounding_box = + math_bounding_box(atom._subscript, + subscript_style); + const float shift_right = + nucleus_bounding_box.horizontal_center() - + subscript_bounding_box.horizontal_center() - + 0.5F * + nucleus_bounding_box.italic_correction(); + const float clearance = + std::max(big_op_spacing_2 * size, + big_op_spacing_4 * size - + subscript_bounding_box.ascent()); + const float shift_down = + nucleus_bounding_box.descent() + clearance + + subscript_bounding_box.ascent() - + nucleus_shift_up; + + if(shift_right >= 0) { + token_list.push_back(math_token_t( + point_t(0, nucleus_shift_up), + nucleus_bounding_box, style)); + token_list.push_back(math_token_t( + point_t(shift_right, -shift_down), + subscript_bounding_box, + subscript_style)); + } + else { + token_list.push_back(math_token_t( + point_t(-shift_right, + nucleus_shift_up), + nucleus_bounding_box, style)); + token_list.push_back(math_token_t( + point_t(0, -shift_down), + subscript_bounding_box, + subscript_style)); + } + return token_list; + } + if(atom._subscript.empty()) { + const bounding_box_t superscript_bounding_box = + math_bounding_box(atom._superscript, + superscript_style); + const float shift_right = + nucleus_bounding_box.horizontal_center() - + superscript_bounding_box. + horizontal_center() + 0.5F * + nucleus_bounding_box.italic_correction(); + const float clearance = + std::max(big_op_spacing_1 * size, + big_op_spacing_3 * size - + superscript_bounding_box.descent()); + const float shift_up = + nucleus_bounding_box.ascent() + clearance + + superscript_bounding_box.descent() + + nucleus_shift_up; + + if(shift_right >= 0) { + token_list.push_back(math_token_t( + point_t(0, nucleus_shift_up), + nucleus_bounding_box, style)); + token_list.push_back(math_token_t( + point_t(shift_right, shift_up), + superscript_bounding_box, + superscript_style)); + } + else { + token_list.push_back(math_token_t( + point_t(-shift_right, + nucleus_shift_up), + nucleus_bounding_box, style)); + token_list.push_back(math_token_t( + point_t(0, shift_up), + superscript_bounding_box, + superscript_style)); + } + return token_list; + } + const bounding_box_t superscript_bounding_box = + math_bounding_box(atom._superscript, + superscript_style); + const bounding_box_t subscript_bounding_box = + math_bounding_box(atom._subscript, + subscript_style); + const float shift_right_superscript = + nucleus_bounding_box.horizontal_center() - + superscript_bounding_box.horizontal_center() + + 0.5F * nucleus_bounding_box.italic_correction(); + const float shift_right_subscript = + nucleus_bounding_box.horizontal_center() - + subscript_bounding_box.horizontal_center() - + 0.5F * nucleus_bounding_box.italic_correction(); + const float clearance_superscript = + std::max(big_op_spacing_1 * size, + big_op_spacing_3 * size - + superscript_bounding_box.descent()); + const float clearance_subscript = + std::max(big_op_spacing_2 * size, + big_op_spacing_4 * size - + subscript_bounding_box.ascent()); + const float shift_up = + nucleus_bounding_box.ascent() + + clearance_superscript + + superscript_bounding_box.descent() + + nucleus_shift_up; + const float shift_down = + nucleus_bounding_box.descent() + + clearance_subscript + + subscript_bounding_box.ascent() - + nucleus_shift_up; + const float min_shift_right = + std::min(0.0F, std::min(shift_right_superscript, + shift_right_subscript)); + + token_list.push_back(math_token_t( + point_t(-min_shift_right, + nucleus_shift_up), + nucleus_bounding_box, style)); + token_list.push_back(math_token_t( + point_t(shift_right_superscript - + min_shift_right, + shift_up), + superscript_bounding_box, + superscript_style)); + token_list.push_back(math_token_t( + point_t(shift_right_subscript - + min_shift_right, + -shift_down), + subscript_bounding_box, + subscript_style)); + return token_list; + } + + // \nolimits or nucleus only + token_list.push_back(math_token_t( + point_t(0, nucleus_shift_up), + nucleus_bounding_box, style)); + current_x += nucleus_bounding_box.advance(); + } + else { // Neither Rad nor Op + nucleus_bounding_box = + math_bounding_box(atom._nucleus, style); + token_list.push_back(math_token_t( + nucleus_bounding_box, style)); + current_x += nucleus_bounding_box.advance(); + } + + if(atom._superscript.empty() && atom._subscript.empty()) + return token_list; + + const float current_x_italic_corrected = current_x + + nucleus_bounding_box.italic_correction(); + const float nucleus_size = size; + const unsigned int superscript_style = + next_superscript_style(style); + const unsigned int subscript_style = + next_subscript_style(style); + const float superscript_size = style_size(superscript_style); + const float subscript_size = style_size(subscript_style); + // Rule 18a + const float min_shift_up = nucleus_bounding_box.ascent() - + superscript_size * sup_drop; + const float min_shift_down = nucleus_bounding_box.descent() + + subscript_size * sub_drop; + + // Rule 18b + if(atom._superscript.empty()) { + const bounding_box_t subscript_bounding_box = + math_bounding_box(atom._subscript, subscript_style); + const float shift_down = + std::max(std::max(min_shift_down, + nucleus_size * sub_1), + subscript_bounding_box.ascent() - + 0.8F * x_height(subscript_style)); + token_list.push_back(math_token_t( + point_t(current_x, nucleus_shift_up - shift_down), + subscript_bounding_box, subscript_style)); + return token_list; + } + // Rule 18c + const bounding_box_t superscript_bounding_box = + math_bounding_box(atom._superscript, superscript_style); + const float min_shift_up_2 = nucleus_size * + (style == math_text_t::item_t::STYLE_DISPLAY ? + sup_1 : is_prime_style(style) ? sup_3 : sup_2); + float shift_up = + std::max(std::max(min_shift_up, min_shift_up_2), + superscript_bounding_box.descent() + + 0.2F * x_height(superscript_style)); + // Rule 18d + if(atom._subscript.empty()) { + token_list.push_back(math_token_t( + point_t(current_x_italic_corrected, + nucleus_shift_up + shift_up), + superscript_bounding_box, superscript_style)); + return token_list; + } + + // Still rule 18d + float shift_down = + std::max(min_shift_down, nucleus_size * sub_2); + // Rule 18e + const bounding_box_t subscript_bounding_box = + math_bounding_box(atom._subscript, subscript_style); + + if((shift_up - superscript_bounding_box.descent()) - + (subscript_bounding_box.ascent() - shift_down) < + 4.0F * default_rule_thickness * + nucleus_size) { + shift_down = 4.0F * default_rule_thickness * + nucleus_size + subscript_bounding_box.ascent() + + superscript_bounding_box.descent() - shift_up; + + const float superscript_adjustment = + 0.8F * x_height(superscript_style) - + (shift_up - superscript_bounding_box.descent()); + + if(superscript_adjustment > 0) { + shift_up += superscript_adjustment; + shift_down -= superscript_adjustment; + } + } + // Rule 18f + token_list.push_back(math_token_t( + point_t(current_x_italic_corrected, + nucleus_shift_up + shift_up), + superscript_bounding_box, superscript_style)); + token_list.push_back(math_token_t( + point_t(current_x, + nucleus_shift_up - shift_down), + subscript_bounding_box, subscript_style)); + + return token_list; + } + +} diff --git a/graf2d/mathtext/src/mathtext.cxx b/graf2d/mathtext/src/mathtext.cxx new file mode 100644 index 0000000000000..4abbda18a01dd --- /dev/null +++ b/graf2d/mathtext/src/mathtext.cxx @@ -0,0 +1,352 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +#include +#include +#include +#include "mathtext.h" + +///////////////////////////////////////////////////////////////////// + +namespace mathtext { + + ///////////////////////////////////////////////////////////////// + + void math_text_t::field_t::transform_script(void) + { + const unsigned long size = _math_list.size(); + + if(size < 2) + return; + + std::vector::reverse_iterator last = + _math_list.rbegin(); + std::vector::reverse_iterator second_last = + last + 1; + + if(last->_type == item_t::TYPE_ATOM && + second_last->_type == item_t::TYPE_ATOM && + second_last->_atom._type == atom_t::TYPE_ACC && + !(last->_atom._superscript.empty() && + last->_atom._subscript.empty())) { + // Rule 12 + atom_t atom = field_t(); + + atom._nucleus._math_list.push_back(*second_last); + atom._nucleus._math_list.push_back(*last); + atom._superscript = + atom._nucleus._math_list.back()._atom._superscript; + atom._subscript = + atom._nucleus._math_list.back()._atom._subscript; + atom._nucleus._math_list.back()._atom._superscript = + field_t(); + atom._nucleus._math_list.back()._atom._subscript = + field_t(); + _math_list.pop_back(); + _math_list.pop_back(); + _math_list.push_back(item_t(atom)); + } + } + + void math_text_t::field_t::append(const item_t &item) + { + _math_list.push_back(item); + } + + // FIXME: Check for malformed "..._a^b_c" (instead of just + // overwriting) + void math_text_t::field_t:: + append(const field_t &field, const bool superscript, + const bool subscript) + { + if((superscript || subscript) && _math_list.empty()) + _math_list.push_back(item_t(field_t())); + + if(superscript) { + _math_list.back()._atom._superscript = field; + transform_script(); + } + else if(subscript) { + _math_list.back()._atom._subscript = field; + transform_script(); + } + else + append(item_t(item_t::TYPE_ATOM, atom_t(field))); + } + + void math_text_t::field_t:: + prepend(const unsigned int type, + const math_symbol_t &math_symbol) + { + _math_list.insert(_math_list.begin(), + item_t(type, + atom_t(field_t(math_symbol)))); + } + + void math_text_t::field_t:: + append(const unsigned int type, const math_symbol_t &math_symbol, + const bool superscript, const bool subscript) + { + if((superscript || subscript) && _math_list.empty()) + _math_list.push_back(item_t(field_t())); + + if(superscript) { + _math_list.back()._atom._superscript = + field_t(math_symbol); + transform_script(); + } + else if(subscript) { + _math_list.back()._atom._subscript = + field_t(math_symbol); + transform_script(); + } + else + append(item_t(type, atom_t(field_t(math_symbol)))); + } + + math_text_t::field_t:: + field_t(const std::vector &str_split, + const unsigned int default_family) + : _type(TYPE_MATH_LIST) + { + parse_math_list(str_split, default_family); + } + + math_text_t::field_t:: + field_t(const std::string &str_delimiter_left, + const std::vector &str_split, + const std::string &str_delimiter_right, + const unsigned int default_family) + : _type(TYPE_MATH_LIST) + { + parse_math_list(str_split, default_family); + + const math_symbol_t + symbol_left(str_delimiter_left, default_family); + + prepend(item_t::TYPE_BOUNDARY, symbol_left); + + const math_symbol_t + symbol_right(str_delimiter_right, default_family); + + append(item_t::TYPE_BOUNDARY, symbol_right, false, false); + } + + bool math_text_t::field_t::generalized_fraction(void) const + { + if(_type == TYPE_MATH_LIST) + for(std::vector::const_iterator iterator = + _math_list.begin(); + iterator != _math_list.end(); iterator++) + if(iterator->_type == + item_t::TYPE_GENERALIZED_FRACTION) + return true; + return false; + } + + void math_text_t::atom_t::classify(void) + { + // Only nucleus affects the atom type (Knuth, The TeXbook, + // 1986, p. 171) + if(_nucleus._type == field_t::TYPE_MATH_SYMBOL) + _type = _nucleus._math_symbol._type; + else if(_nucleus.generalized_fraction()) + _type = atom_t::TYPE_INNER; + else + // FIXME: Does TeX flatten compound expressions before + // classify them? + _type = TYPE_ORD; + } + + bool math_text_t::atom_t::is_combining_diacritical(void) const + { + return _nucleus._type == field_t::TYPE_MATH_SYMBOL && + _nucleus._math_symbol.is_combining_diacritical(); + } + + unsigned int math_text_t::atom_t:: + spacing(const unsigned int left_type, + const unsigned int right_type, const bool script) + { +#include "table/mathspacing.h" + // Since we only handle atom types upto Inner, the upper bound + // is type <= TYPE_INNER and not type < NTYPE. + if(left_type == TYPE_UNKNOWN || left_type > TYPE_INNER || + right_type == TYPE_UNKNOWN || right_type > TYPE_INNER) { + // Invalid + return 0; + } + + int index = ((left_type - TYPE_ORD) << 3) + + (right_type - TYPE_ORD); + int space = spacing_table[index]; + + if(space == nvr) { + // Invalid + return 0; + } + // Interpret the \nonscript sign, which denotes spaces that + // should be ignored within the script (and scriptscript) + // style. + if(space < 0) + space = script ? 0 : -space; + + return space; + } + + bool math_text_t::item_t::operator==(const item_t &item) const + { + switch(_type) { + case TYPE_GENERALIZED_FRACTION: + return item._type == TYPE_GENERALIZED_FRACTION; + break; + default: + return false; + } + } + + std::wstring math_text_t::bad_cast(const std::string string) + { + std::wstring wstring; + + for(std::string::const_iterator iterator = string.begin(); + iterator != string.end(); iterator++) { + wstring.push_back(*iterator); + } + + return wstring; + } + + std::wstring math_text_t::utf8_cast(const std::string string) + { + std::wstring wstring; + + for(std::string::const_iterator iterator = string.begin(); + iterator != string.end();) { + wchar_t c; + + // Skip over byte ordering marks + if((unsigned char)(*iterator) == 0xef) { + iterator++; + if((unsigned char)(*iterator) == 0xbb) { + iterator++; + if((unsigned char)(*iterator) == 0xbf) { + iterator++; + } + } + } + if((*iterator & 0xf0) == 0xf0) { + c = (*iterator & 0x7) << 18; + iterator++; + if((*iterator & 0xc0) != 0x80) { + continue; + } + c |= (*iterator & 0x3f) << 12; + iterator++; + if((*iterator & 0xc0) != 0x80) { + continue; + } + c |= (*iterator & 0x3f) << 6; + iterator++; + if((*iterator & 0xc0) != 0x80) { + continue; + } + c |= (*iterator & 0x3f); + iterator++; + } + else if((*iterator & 0xe0) == 0xe0) { + c = (*iterator & 0xf) << 12; + iterator++; + if((*iterator & 0xc0) != 0x80) { + continue; + } + c |= (*iterator & 0x3f) << 6; + iterator++; + if((*iterator & 0xc0) != 0x80) { + continue; + } + c |= (*iterator & 0x3f); + iterator++; + } + else if((*iterator & 0xc0) == 0xc0) { + c = (*iterator & 0x1f) << 6; + iterator++; + if((*iterator & 0xc0) != 0x80) { + continue; + } + c |= (*iterator & 0x3f); + iterator++; + } + else if((*iterator & 0x80) == 0x0) { + c = (*iterator & 0x7f); + iterator++; + } + else { + iterator++; + continue; + } + wstring.push_back(c); + } + + return wstring; + } + +#if 0 + std::wstring math_text_t::gb_18030_cast( + const std::string string) + { + } + + std::wstring math_text_t::shift_jis_x_0213_cast( + const std::string string) + { + } + + std::wstring math_text_t::euc_jis_x_0213_cast( + const std::string string) + { + } + + std::wstring math_text_t::ks_x_2901_cast( + const std::string string) + { + } +#endif + + // Apply JIS X 4051:2004 + + bool math_text_t::well_formed(void) const + { + if(_math_list._type != field_t::TYPE_MATH_LIST) + return false; + return true; + } + +#if 0 + std::string tex_form(const double x) + { + std::string retval; + + switch(std::fpclassify(x)) { + default: + return retval; + } + } +#endif + +} diff --git a/graf2d/mathtext/src/mathtextencode.cxx b/graf2d/mathtext/src/mathtextencode.cxx new file mode 100644 index 0000000000000..557c259936e2d --- /dev/null +++ b/graf2d/mathtext/src/mathtextencode.cxx @@ -0,0 +1,438 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +#ifdef WIN32 +// On Windows, Disable the warning: +// "characters beyond first in wide-character constant ignored" +#pragma warning( push ) +#pragma warning( disable : 4066) +#endif + +#include +#include +#include +#include +#include "mathtext.h" + +///////////////////////////////////////////////////////////////////// + +namespace mathtext { + + ///////////////////////////////////////////////////////////////// + + // For the symbol classification, see Knuth, The TeXbook (1986), + // pp. 434ff. + + void math_text_t::math_symbol_t::math_italic_is_upright(void) + { + if(_family == FAMILY_MATH_ITALIC) { + _family = FAMILY_REGULAR; + } + else if(_family == FAMILY_MATH_BOLD_ITALIC) { + _family = FAMILY_BOLD; + } + } + + void math_text_t::math_symbol_t::math_italic_is_italic(void) + { + if(_family == FAMILY_MATH_ITALIC) { + _family = FAMILY_ITALIC; + } + else if(_family == FAMILY_MATH_BOLD_ITALIC) { + _family = FAMILY_BOLD_ITALIC; + } + } + + void math_text_t::math_symbol_t::encode_character(void) + { + if(_code.size() != 1) + return; + + // Character encoding for plain characters (not a TeX control + // sequence) + switch(_code[0]) { + case '|': + case '/': + case '.': + math_italic_is_upright(); + _glyph = _code[0]; + _type = atom_t::TYPE_ORD; + break; + case '+': + math_italic_is_upright(); + _glyph = _code[0]; + _type = atom_t::TYPE_BIN; + break; + case '-': + math_italic_is_upright(); + _glyph = L'\u2212'; + _type = atom_t::TYPE_BIN; + break; + case '*': + math_italic_is_upright(); + _glyph = L'\u2217'; + _type = atom_t::TYPE_BIN; + break; + case '<': + case '=': + case '>': + case ':': + math_italic_is_upright(); + _glyph = _code[0]; + _type = atom_t::TYPE_REL; + break; + case '(': + case '[': + math_italic_is_upright(); + _glyph = _code[0]; + _type = atom_t::TYPE_OPEN; + break; + case '!': + case '?': + case ')': + case ']': + math_italic_is_upright(); + _glyph = _code[0]; + _type = atom_t::TYPE_CLOSE; + break; + case ',': + case ';': + math_italic_is_upright(); + _glyph = _code[0]; + _type = atom_t::TYPE_PUNCT; + break; + default: + if((_code[0] >= 'A' && _code[0] <= 'Z') || + (_code[0] >= 'a' && _code[0] <= 'z')) { + _glyph = _code[0]; + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= '0' && _code[0] <= '9') { + math_italic_is_upright(); + _glyph = _code[0]; + _type = atom_t::TYPE_ORD; + } + } + } + + void math_text_t::math_symbol_t::encode_control_sequence(void) + { + // Character encoding for TeX control sequences +#include "table/mathglyphstd.h" + const char **lower = + std::lower_bound(glyph_control_sequence, + glyph_control_sequence + nglyph, + _code); + + if(lower < glyph_control_sequence + nglyph && +#ifdef WIN32 + strncmp(*lower, _code.c_str(), _code.size()) == 0 +#else // WIN32 + *lower == _code +#endif // WIN32 + ) { + const unsigned long index = + lower - glyph_control_sequence; + + if(glyph_upright[index]) + math_italic_is_upright(); + _glyph = glyph_code_point[index]; + _type = glyph_type[index]; + } + } + + void math_text_t::math_symbol_t::encode_math_blackboard_bold(void) + { + if(_code.size() != 1) { + return; + } + + if(_code[0] >= 'A' && _code[0] <= 'Z') { + _family = FAMILY_STIX_REGULAR; + switch(_code[0]) { + case 'C': _glyph = L'\u2102'; break; + case 'H': _glyph = L'\u210d'; break; + case 'N': _glyph = L'\u2115'; break; + case 'P': _glyph = L'\u2119'; break; + case 'Q': _glyph = L'\u211a'; break; + case 'R': _glyph = L'\u211d'; break; + case 'Z': _glyph = L'\u2124'; break; + default: _glyph = L'\U0001d538' + (_code[0] - 'A'); + } + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= 'a' && _code[0] <= 'z') { + _family = FAMILY_STIX_REGULAR; + _glyph = L'\U0001d552' + (_code[0] - 'a'); + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= '0' && _code[0] <= '9') { + _family = FAMILY_STIX_REGULAR; + _glyph = L'\U0001d7d8' + (_code[0] - '0'); + _type = atom_t::TYPE_ORD; + } + } + + void math_text_t::math_symbol_t::encode_math_script_italic(void) + { + if(_code.size() != 1) { + return; + } + + if(_code[0] >= 'A' && _code[0] <= 'Z') { + _family = FAMILY_STIX_ITALIC; + switch(_code[0]) { + case 'H': _glyph = L'\u210b'; break; + case 'I': _glyph = L'\u2110'; break; + case 'L': _glyph = L'\u2112'; break; + case 'P': _glyph = L'\u2118'; break; + case 'R': _glyph = L'\u211b'; break; + case 'B': _glyph = L'\u212c'; break; + case 'E': _glyph = L'\u2130'; break; + case 'F': _glyph = L'\u2131'; break; + case 'M': _glyph = L'\u2133'; break; + default: _glyph = L'\U0001d49c' + (_code[0] - 'A'); + } + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= 'a' && _code[0] <= 'z') { + _family = FAMILY_STIX_ITALIC; + switch(_code[0]) { + case 'g': _glyph = L'\u210a'; break; + case 'l': _glyph = L'\u2113'; break; + case 'e': _glyph = L'\u212f'; break; + case 'o': _glyph = L'\u2134'; break; + default: _glyph = L'\U0001d4b6' + (_code[0] - 'a'); + } + _type = atom_t::TYPE_ORD; + } + } + + void math_text_t::math_symbol_t::encode_math_script_bold_italic(void) + { + if(_code.size() != 1) + return; + + if(_code[0] >= 'A' && _code[0] <= 'Z') { + _family = FAMILY_STIX_BOLD_ITALIC; + _glyph = L'\U0001d49c' + (_code[0] - 'A'); + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= 'a' && _code[0] <= 'z') { + _family = FAMILY_STIX_BOLD_ITALIC; + _glyph = L'\U0001d4b6' + (_code[0] - 'a'); + _type = atom_t::TYPE_ORD; + } + } + + void math_text_t::math_symbol_t::encode_math_fraktur_regular(void) + { + if(_code.size() != 1) + return; + + if(_code[0] >= 'A' && _code[0] <= 'Z') { + _family = FAMILY_STIX_REGULAR; + switch(_code[0]) { + case 'H': _glyph = L'\u210c'; break; + case 'I': _glyph = L'\u2111'; break; + case 'R': _glyph = L'\u211c'; break; + case 'Z': _glyph = L'\u2128'; break; + case 'C': _glyph = L'\u212d'; break; + default: _glyph = L'\U0001d504' + (_code[0] - 'A'); + } + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= 'a' && _code[0] <= 'z') { + _family = FAMILY_STIX_REGULAR; + _glyph = L'\U0001d51e' + (_code[0] - 'a'); + _type = atom_t::TYPE_ORD; + } + } + + void math_text_t::math_symbol_t::encode_math_fraktur_bold(void) + { + if(_code.size() != 1) + return; + + if(_code[0] >= 'A' && _code[0] <= 'Z') { + _family = FAMILY_STIX_BOLD; + _glyph = L'\U0001d56c' + (_code[0] - 'A'); + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= 'a' && _code[0] <= 'z') { + _family = FAMILY_STIX_BOLD; + _glyph = L'\U0001d586' + (_code[0] - 'a'); + _type = atom_t::TYPE_ORD; + } + } + + void math_text_t::math_symbol_t:: + encode_math_sans_serif_regular(void) + { + if(_code.size() != 1) + return; + + if(_code[0] >= 'A' && _code[0] <= 'Z') { + _family = FAMILY_STIX_REGULAR; + _glyph = L'\U0001d5a0' + (_code[0] - 'A'); + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= 'a' && _code[0] <= 'z') { + _family = FAMILY_STIX_REGULAR; + _glyph = L'\U0001d5ba' + (_code[0] - 'a'); + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= '0' && _code[0] <= '9') { + _family = FAMILY_STIX_REGULAR; + _glyph = L'\U0001d7e2' + (_code[0] - '0'); + _type = atom_t::TYPE_ORD; + } + } + + void math_text_t::math_symbol_t:: + encode_math_sans_serif_italic(void) + { + if(_code.size() != 1) + return; + + if(_code[0] >= 'A' && _code[0] <= 'Z') { + _family = FAMILY_STIX_ITALIC; + _glyph = L'\U0001d608' + (_code[0] - 'A'); + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= 'a' && _code[0] <= 'z') { + _family = FAMILY_STIX_ITALIC; + _glyph = L'\U0001d622' + (_code[0] - 'a'); + _type = atom_t::TYPE_ORD; + } + } + + void math_text_t::math_symbol_t:: + encode_math_sans_serif_bold(void) + { + if(_code.size() != 1) + return; + + if(_code[0] >= 'A' && _code[0] <= 'Z') { + _family = FAMILY_STIX_BOLD; + _glyph = L'\U0001d5d4' + (_code[0] - 'A'); + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= 'a' && _code[0] <= 'z') { + _family = FAMILY_STIX_BOLD; + _glyph = L'\U0001d5ee' + (_code[0] - 'a'); + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= '0' && _code[0] <= '9') { + _family = FAMILY_STIX_BOLD; + _glyph = L'\U0001d7ec' + (_code[0] - '0'); + _type = atom_t::TYPE_ORD; + } + } + + void math_text_t::math_symbol_t:: + encode_math_sans_serif_bold_italic(void) + { + if(_code.size() != 1) + return; + + if(_code[0] >= 'A' && _code[0] <= 'Z') { + _family = FAMILY_STIX_BOLD_ITALIC; + _glyph = L'\U0001d63c' + (_code[0] - 'A'); + _type = atom_t::TYPE_ORD; + } + else if(_code[0] >= 'a' && _code[0] <= 'z') { + _family = FAMILY_STIX_BOLD_ITALIC; + _glyph = L'\U0001d656' + (_code[0] - 'a'); + _type = atom_t::TYPE_ORD; + } + } + + void math_text_t::math_symbol_t::encode_math_alpha(void) + { + switch(_family) { + case FAMILY_MATH_BLACKBOARD_BOLD: + encode_math_blackboard_bold(); + break; + case FAMILY_MATH_SCRIPT_ITALIC: + encode_math_script_italic(); + break; + case FAMILY_MATH_SCRIPT_BOLD_ITALIC: + encode_math_script_bold_italic(); + break; + case FAMILY_MATH_FRAKTUR_REGULAR: + encode_math_fraktur_regular(); + break; + case FAMILY_MATH_FRAKTUR_BOLD: + encode_math_fraktur_bold(); + break; + case FAMILY_MATH_SANS_SERIF_REGULAR: + encode_math_sans_serif_regular(); + break; + case FAMILY_MATH_SANS_SERIF_ITALIC: + encode_math_sans_serif_italic(); + break; + case FAMILY_MATH_SANS_SERIF_BOLD: + encode_math_sans_serif_bold(); + break; + case FAMILY_MATH_SANS_SERIF_BOLD_ITALIC: + encode_math_sans_serif_bold_italic(); + break; + } + } + + void math_text_t::math_symbol_t::encode(void) + { + encode_character(); + encode_control_sequence(); + encode_math_alpha(); + math_italic_is_italic(); + if(_family > FAMILY_STIX_SIZE_5_REGULAR) { + std::cerr << __FILE__ << ':' << __LINE__ + << ": error: encoding results in a " + "nonphysical font family" << std::endl; + } + } + + bool math_text_t::math_symbol_t::bold(void) const + { + switch(_family) { + case FAMILY_BOLD: + case FAMILY_BOLD_ITALIC: + case FAMILY_STIX_BOLD: + case FAMILY_STIX_BOLD_ITALIC: + case FAMILY_STIX_SIZE_1_BOLD: + case FAMILY_STIX_SIZE_2_BOLD: + case FAMILY_STIX_SIZE_3_BOLD: + case FAMILY_STIX_SIZE_4_BOLD: + case FAMILY_MATH_BOLD_ITALIC: + case FAMILY_MATH_SCRIPT_BOLD_ITALIC: + case FAMILY_MATH_FRAKTUR_BOLD: + case FAMILY_MATH_BLACKBOARD_BOLD: + case FAMILY_MATH_SANS_SERIF_BOLD: + case FAMILY_MATH_SANS_SERIF_BOLD_ITALIC: + return true; + default: + return false; + } + } + +} +#ifdef WIN32 +#pragma warning( pop ) +#endif diff --git a/graf2d/mathtext/src/mathtextparse.cxx b/graf2d/mathtext/src/mathtextparse.cxx new file mode 100644 index 0000000000000..d7aa73d7b10b2 --- /dev/null +++ b/graf2d/mathtext/src/mathtextparse.cxx @@ -0,0 +1,458 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +#include +#include +#include +#include +#include "mathtext.h" + +///////////////////////////////////////////////////////////////////// + +namespace mathtext { + + ///////////////////////////////////////////////////////////////// + + void math_text_t::field_t:: + parse_math_list(const std::vector &str_split, + const unsigned int default_family) + { +#if 0 + std::cerr << "parsing ["; + for(std::vector::const_iterator iterator = + str_split.begin(); + iterator != str_split.end(); iterator++) + std::cerr << '"' << *iterator << "\", "; + std::cerr << ']' << std::endl; +#endif + + // State of radical parsing + enum { + RADICAL_STATE_NONE = 0, + RADICAL_STATE_RADICAND, + RADICAL_STATE_OF, + RADICAL_STATE_INDEX + }; + + unsigned int family = default_family; + int level = 0; + int delimiter_level = 0; + std::vector buffer; +#if 1 + bool superscript = false; + bool subscript = false; + bool delimiter_right = false; + unsigned int radical_state = RADICAL_STATE_NONE; + std::vector radical_index; + bool horizontal_box = false; + + for(std::vector::const_iterator iterator = + str_split.begin(); + iterator != str_split.end(); iterator++) { + // ONLY LEVEL 0 superscript and subscript are interpreted, + // and they are ignored afterwards. + if(level == 0 && delimiter_level == 0) { + if((*iterator)[0] == '^') { + superscript = true; + continue; + } + else if((*iterator)[0] == '_') { + subscript = true; + continue; + } + else if(*iterator == "\\sqrt") { + radical_state = RADICAL_STATE_RADICAND; + radical_index = std::vector(); + continue; + } + else if(iterator->substr(0, 5) == "\\root") { + radical_state = RADICAL_STATE_INDEX; + continue; + } + else if(radical_state == RADICAL_STATE_INDEX && + *iterator == "\\of") { + radical_index = buffer; + buffer.clear(); + radical_state = RADICAL_STATE_RADICAND; + continue; + } + else if(iterator->substr(0, 5) == "\\hbox" || + iterator->substr(0, 5) == "\\text") { + horizontal_box = true; + continue; + } + + const char **lower; + +#include "table/mathfontch.h" + lower = std::lower_bound( + font_change_control_sequence, + font_change_control_sequence + nfont_change, + *iterator); + + if(lower < + font_change_control_sequence + nfont_change && + *lower == *iterator) { + const unsigned long index = + lower - font_change_control_sequence; + + family = font_change_family[index]; + continue; + } +#include "table/mathopstd.h" + lower = std::lower_bound( + operator_control_sequence, + operator_control_sequence + noperator, + *iterator); + if(lower < + operator_control_sequence + noperator && + *lower == *iterator) { + const unsigned long index = + lower - operator_control_sequence; + + if(operator_code_point[index] == L'\0') { + // Operator defined with \mathop + const field_t operator_math_list(field_t( + tex_split(operator_content[index]), + math_symbol_t::FAMILY_REGULAR)); + atom_t atom(atom_t::TYPE_OP, field_t( + operator_math_list)); + + atom._limits = operator_nolimits[index] ? + atom_t::LIMITS_NOLIMITS : + atom_t::LIMITS_DISPLAYLIMITS; + append(atom); + } + else { + // Operator defined with \mathchardef + const field_t operator_math_symbol( + math_symbol_t( + *iterator, + operator_code_point[index], + math_symbol_t::FAMILY_REGULAR)); + atom_t atom(atom_t::TYPE_OP, field_t( + operator_math_symbol)); + + atom._limits = operator_nolimits[index] ? + atom_t::LIMITS_NOLIMITS : + atom_t::LIMITS_DISPLAYLIMITS; + append(atom); + } + continue; + } + } + + if((*iterator)[0] == '}') { + level--; + // When the level decreases to 0 here, the compound + // expression is complete, create a subfield and + // append it to the math list. + if(level == 0 && delimiter_level == 0) { + // Create subfields recursively + const field_t subfield(buffer, family); + + if(radical_state == RADICAL_STATE_RADICAND) { + atom_t atom(atom_t::TYPE_RAD, subfield); + + atom._index = field_t(radical_index, family); + append(item_t(atom)); + radical_state = RADICAL_STATE_NONE; + } + else + append(subfield, superscript, subscript); + buffer.clear(); + } + } + else if(*iterator == "\\right") { + delimiter_level--; + // When the delimtier level decreases to 0 here, the + // compound expression is complete, create a subfield + // and append it with the appropriate delimiter atoms + // to the math list. + if(level == 0 && delimiter_level == 0) { + delimiter_right = true; + continue; + } + } + + ///////////////////////////////////////////////////////// + +#if 0 + std::cerr << __FILE__ << ':' << __LINE__ + << ": L" << level << ", DL" + << delimiter_level << ", hbox = " + << horizontal_box << ", *iterator = " + << *iterator << std::endl; +#endif + + if(level > 0 || delimiter_level > 0 || + radical_state == RADICAL_STATE_INDEX) { + buffer.push_back(*iterator); + } + else if(delimiter_right) { + const std::string left = buffer.front(); + + buffer.erase(buffer.begin()); + + const field_t subfield(left, buffer, *iterator, + family); + + if(radical_state == RADICAL_STATE_RADICAND) { + atom_t atom(atom_t::TYPE_RAD, subfield); + + atom._index = field_t(radical_index, family); + append(item_t(atom)); + radical_state = RADICAL_STATE_NONE; + } + else + append(subfield, superscript, subscript); + buffer.clear(); + } + else if(horizontal_box) { + box_t box(math_text_t::utf8_cast(*iterator)); + + append(field_t(box), superscript, subscript); + } + else if((*iterator)[0] != '{' && + (*iterator)[0] != '}' && + *iterator != "\\left" && + *iterator != "\\right") { + if(radical_state == RADICAL_STATE_RADICAND) { + const field_t subfield( + std::vector(1, *iterator), + family); + atom_t atom(atom_t::TYPE_RAD, subfield); + + atom._index = field_t(radical_index, family); + append(item_t(atom)); + } + // FIXME: This should be a true table + else if(*iterator == "\\over") { + append(item_t(item_t::TYPE_GENERALIZED_FRACTION, + 1.0F)); + } + else if(*iterator == "\\atop") { + append(item_t(item_t::TYPE_GENERALIZED_FRACTION, + 0.0F)); + } + // FIXME: This should be a true table + else if(*iterator == "\\!") { + append(item_t(item_t::TYPE_KERN, -3.0F)); + } + else if(*iterator == "\\,") { + append(item_t(item_t::TYPE_KERN, 3.0F)); + } + else if(*iterator == "\\:") { + append(item_t(item_t::TYPE_KERN, 4.0F)); + } + else if(*iterator == "\\;") { + append(item_t(item_t::TYPE_KERN, 5.0F)); + } + else if(*iterator == "\\quad") { + append(item_t(item_t::TYPE_KERN, 18.0F)); + } + else if(*iterator == "\\qquad") { + append(item_t(item_t::TYPE_KERN, 36.0F)); + } + else { + const math_symbol_t + math_symbol(*iterator, family); + + append(item_t::TYPE_ATOM, math_symbol, + superscript, subscript); + } + } + + if((*iterator)[0] == '{') { + level++; + } + else if(*iterator == "\\left") { + // Since the actual delimiter follows, it is going to + // be appended to the buffer "automatically". + delimiter_level++; + } + // Reset superscript and subscript flags only for level 0 + if(level == 0 && delimiter_level == 0 && + (radical_state == RADICAL_STATE_RADICAND || + radical_state == RADICAL_STATE_NONE)) { + superscript = false; + subscript = false; + delimiter_right = false; + radical_state = RADICAL_STATE_NONE; + family = default_family; + horizontal_box = false; + } + } +#else + for(std::vector::const_iterator iterator = + str_split.begin(); + iterator != str_split.end(); iterator++) { + if((*iterator)[0] == '}') { + level--; + + } + else if(*iterator == "\\right") { + delimiter_level--; + } + if((*iterator)[0] == '{') { + level++; + } + else if(*iterator == "\\left") { + // Since the actual delimiter follows, it is going to + // be appended to the buffer "automatically". + delimiter_level++; + } + else if(level == 0 && delimiter_level == 0) { +#if 1 + std::cerr << __FILE__ << ':' << __LINE__ + << ": L" << level << ", DL" + << delimiter_level << ", *iterator = " + << *iterator << ", buffer = { "; + for(std::vector::const_iterator + buffer_iterator = buffer.begin(); + buffer_iterator != buffer.end(); buffer_iterator++) { + std::cerr << '"' << *buffer_iterator << "\" "; + } + std::cerr << '}' << std::endl; +#endif + buffer.clear(); + } + else { + buffer.push_back(*iterator); + } + } +#endif + } + + std::vector math_text_t:: + tex_split(const std::string &raw_code, const char escape_character) + { + std::string code = raw_code; + + for(std::string::iterator iterator = code.begin(); + iterator != code.end(); iterator++) { + if(*iterator == escape_character) { + *iterator = '\\'; + } + } + + std::vector ret; + + if(code.size() <= 0) { + return ret; + } + + size_t begin = 0; + size_t end = 1; + bool box = false; + + while (code[begin] == ' ') { + begin++; + } + while (begin < code.size()) { + end = begin + 1; + if(code[begin] == '\\') { + if(isalpha(code[end])) { + while(end < code.size() && isalpha(code[end])) { + end++; + } + } + else if(end < code.size()) { + end++; + } + +#include "table/mathbracketcs.h" + const char **lower = + std::lower_bound(bracket_control_sequence, + bracket_control_sequence + + nbracket_control_sequence, + code.substr(begin, + end - begin)); + + if(lower < bracket_control_sequence + + nbracket_control_sequence && + *lower == code.substr(begin, end - begin) && + end + 1 < code.size() && code[end] == '[') { + while(end < code.size() && code[end] != ']') { + end++; + } + if(end < code.size()) { + end++; + } + } + } + + std::string code_substr = + code.substr(begin, end - begin); + +#if 1 + if(code_substr == "\\hbox" || code_substr == "\\text") { + box = true; + } + else if(box) { + if(code[begin] == '{') { + for(unsigned int level = 1; + end < code.size() && level > 0; end++) { + if(code[end - 1] != '\\') { + switch(code[end]) { + case '{': level++; break; + case '}': level--; break; + } + } + } + code_substr = + code.substr(begin + 1, end - begin - 2); + } + else if(code[begin] == '\\' && + begin + 1 < code.size()) { + code_substr = code.substr(begin, 2); + } + else { + code_substr = code.substr(begin, 1); + } + // FIXME: Proper interpretation of escaped characters + box = false; + } +#endif + + ret.push_back(code_substr); + begin = end; + while( begin math_text_t:: + tex_replace(const std::vector &/*code*/) + { +#if 0 + static const size_t ncontrol_max = 256; + static const char *table[][ncontrol_max] = { + { "\\%", "\0", "\\root", "\1", "\\of", "\2", NULL }, + { "\\sqrt", "[]", "\1", "\\root", "\1", "\\of", "\2", NULL }, + { "\\frac", "\2", "{", "\1", "\\over", "\2", "}", NULL } + }; +#endif + + return std::vector(); + } + +} diff --git a/graf2d/mathtext/src/mathtextview.cxx b/graf2d/mathtext/src/mathtextview.cxx new file mode 100644 index 0000000000000..ebfb5b2b70122 --- /dev/null +++ b/graf2d/mathtext/src/mathtextview.cxx @@ -0,0 +1,235 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +#include +#include +#include +#include "mathtext.h" + +///////////////////////////////////////////////////////////////////// + +namespace mathtext { + + ///////////////////////////////////////////////////////////////// + + void math_text_t:: + tree_view_prefix(const std::vector &branch, + const bool final) const + { + if(branch.size() > 0) { + std::cerr << ' '; + for(std::vector::const_iterator iterator = + branch.begin(); + iterator != branch.end(); iterator++) { + if(*iterator) { + if(iterator + 1 == branch.end()) { + if(final) + std::cerr << "\342\224\224\342\224\200 "; + else + std::cerr << "\342\224\234\342\224\200 "; + } + else + std::cerr << "\342\224\202 "; + } + else + if(iterator + 1 == branch.end()) + std::cerr << " "; + else + std::cerr << " "; + } + } + } + + void math_text_t::tree_view(const field_t &field, + std::vector &branch, + const bool final) const + { + switch(field._type) { + case field_t::TYPE_MATH_SYMBOL: + tree_view_prefix(branch, true); + std::cerr << "" << std::endl; + break; + case field_t::TYPE_BOX: + tree_view_prefix(branch, true); + std::cerr << "" << std::endl; + break; + case field_t::TYPE_MATH_LIST: + if(field._math_list.empty()) { + tree_view_prefix(branch, true); + std::cerr << "" << std::endl; + } + else { + tree_view_prefix(branch, false); + std::cerr << "" << std::endl; + + std::vector branch_copy = branch; + + branch_copy.back() = !final; + for(std::vector::const_iterator iterator = + field._math_list.begin(); + iterator != field._math_list.end(); iterator++) { + branch_copy.back() = !final; + branch_copy.push_back(true); + tree_view(*iterator, branch_copy, + iterator + 1 == field._math_list.end()); + branch_copy.pop_back(); + } + branch_copy.back() = !final; + tree_view_prefix(branch_copy, true); + std::cerr << "" << std::endl; + } + break; + default: + tree_view_prefix(branch, true); + std::cerr << "" << std::endl; + } + } + + void math_text_t::tree_view(const item_t &item, + std::vector &branch, + const bool final) const + { + std::vector branch_copy = branch; + + switch(item._type) { + case item_t::TYPE_ATOM: + tree_view_prefix(branch, final); + std::cerr << "" << std::endl; + branch_copy.back() = !final; + branch_copy.push_back(true); + tree_view(item._atom, branch_copy, final); + branch_copy.pop_back(); + tree_view_prefix(branch_copy, final); + std::cerr << "" << std::endl; + break; + case item_t::TYPE_BOUNDARY: + tree_view_prefix(branch, final); + std::cerr << "" << std::endl; + branch_copy.back() = !final; + branch_copy.push_back(true); + tree_view(item._atom, branch_copy, final); + branch_copy.pop_back(); + tree_view_prefix(branch_copy, final); + std::cerr << "" << std::endl; + break; + case item_t::TYPE_GENERALIZED_FRACTION: + tree_view_prefix(branch, final); + std::cerr << "" << std::endl; + break; + default: + tree_view_prefix(branch, final); + std::cerr << "" << std::endl; + } + } + + void math_text_t::tree_view(const atom_t &atom, + std::vector &branch, + const bool final) const + { + tree_view_prefix(branch, false); + std::cerr << ""; + switch(atom._type) { + case atom_t::TYPE_ORD: + std::cerr << "Ord"; + break; + case atom_t::TYPE_OP: + std::cerr << "Op"; + break; + case atom_t::TYPE_BIN: + std::cerr << "Bin"; + break; + case atom_t::TYPE_REL: + std::cerr << "Rel"; + break; + case atom_t::TYPE_OPEN: + std::cerr << "Open"; + break; + case atom_t::TYPE_CLOSE: + std::cerr << "Close"; + break; + case atom_t::TYPE_PUNCT: + std::cerr << "Punct"; + break; + case atom_t::TYPE_INNER: + std::cerr << "Inner"; + break; + case atom_t::TYPE_OVER: + std::cerr << "Over"; + break; + case atom_t::TYPE_UNDER: + std::cerr << "Under"; + break; + case atom_t::TYPE_ACC: + std::cerr << "Acc"; + break; + case atom_t::TYPE_RAD: + std::cerr << "Rad"; + break; + case atom_t::TYPE_VCENT: + std::cerr << "Vcent"; + break; + default: + std::cerr << "??" << atom._type; + break; + } + std::cerr << "" << std::endl; + + std::vector branch_copy = branch; + + if(!atom._nucleus.empty()) { + const bool way_final = atom._superscript.empty() && + atom._subscript.empty(); + + tree_view_prefix(branch, way_final); + std::cerr << "" << std::endl; + branch_copy.back() = !way_final; + branch_copy.push_back(true); + tree_view(atom._nucleus, branch_copy, final); + branch_copy.pop_back(); + tree_view_prefix(branch_copy, way_final); + std::cerr << "" << std::endl; + } + if(!atom._superscript.empty()) { + const bool way_final = atom._subscript.empty(); + + tree_view_prefix(branch, way_final); + std::cerr << "" << std::endl; + branch_copy.back() = !way_final; + branch_copy.push_back(true); + tree_view(atom._superscript, branch_copy, final); + branch_copy.pop_back(); + tree_view_prefix(branch_copy, way_final); + std::cerr << "" << std::endl; + } + if(!atom._subscript.empty()) { + tree_view_prefix(branch, true); + std::cerr << "" << std::endl; + branch_copy.back() = false; + branch_copy.push_back(true); + tree_view(atom._subscript, branch_copy, final); + branch_copy.pop_back(); + tree_view_prefix(branch_copy, true); + std::cerr << "" << std::endl; + } + } + +} diff --git a/graf2d/mathtext/src/table/adobeglyphlist.h b/graf2d/mathtext/src/table/adobeglyphlist.h new file mode 100644 index 0000000000000..8b6dbfdca4def --- /dev/null +++ b/graf2d/mathtext/src/table/adobeglyphlist.h @@ -0,0 +1,315 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +static const unsigned long nadobe_glyph = 835; +static const wchar_t adobe_glyph_ucs[nadobe_glyph] = { + L'\040', L'\041', L'\042', L'\043', L'\044', L'\045', L'\046', + L'\047', L'\050', L'\051', L'\052', L'\053', L'\054', L'\055', + L'\056', L'\057', L'\060', L'\061', L'\062', L'\063', L'\064', + L'\065', L'\066', L'\067', L'\070', L'\071', L'\072', L'\073', + L'\074', L'\075', L'\076', L'\077', L'\100', L'\101', L'\102', + L'\103', L'\104', L'\105', L'\106', L'\107', L'\110', L'\111', + L'\112', L'\113', L'\114', L'\115', L'\116', L'\117', L'\120', + L'\121', L'\122', L'\123', L'\124', L'\125', L'\126', L'\127', + L'\130', L'\131', L'\132', L'\133', L'\134', L'\135', L'\136', + L'\137', L'\140', L'\141', L'\142', L'\143', L'\144', L'\145', + L'\146', L'\147', L'\150', L'\151', L'\152', L'\153', L'\154', + L'\155', L'\156', L'\157', L'\160', L'\161', L'\162', L'\163', + L'\164', L'\165', L'\166', L'\167', L'\170', L'\171', L'\172', + L'\173', L'\174', L'\175', L'\176', L'\241', L'\242', L'\243', + L'\244', L'\245', L'\246', L'\247', L'\250', L'\251', L'\252', + L'\253', L'\254', L'\256', L'\257', L'\260', L'\261', L'\264', + L'\266', L'\267', L'\270', L'\272', L'\273', L'\274', L'\275', + L'\276', L'\277', L'\300', L'\301', L'\302', L'\303', L'\304', + L'\305', L'\306', L'\307', L'\310', L'\311', L'\312', L'\313', + L'\314', L'\315', L'\316', L'\317', L'\320', L'\321', L'\322', + L'\323', L'\324', L'\325', L'\326', L'\327', L'\330', L'\331', + L'\332', L'\333', L'\334', L'\335', L'\336', L'\337', L'\340', + L'\341', L'\342', L'\343', L'\344', L'\345', L'\346', L'\347', + L'\350', L'\351', L'\352', L'\353', L'\354', L'\355', L'\356', + L'\357', L'\360', L'\361', L'\362', L'\363', L'\364', L'\365', + L'\366', L'\367', L'\370', L'\371', L'\372', L'\373', L'\374', + L'\375', L'\376', L'\377', L'\u0100', L'\u0101', L'\u0102', + L'\u0103', L'\u0104', L'\u0105', L'\u0106', L'\u0107', L'\u0108', + L'\u0109', L'\u010a', L'\u010b', L'\u010c', L'\u010d', L'\u010e', + L'\u010f', L'\u0110', L'\u0111', L'\u0112', L'\u0113', L'\u0114', + L'\u0115', L'\u0116', L'\u0117', L'\u0118', L'\u0119', L'\u011a', + L'\u011b', L'\u011c', L'\u011d', L'\u011e', L'\u011f', L'\u0120', + L'\u0121', L'\u0122', L'\u0123', L'\u0124', L'\u0125', L'\u0126', + L'\u0127', L'\u0128', L'\u0129', L'\u012a', L'\u012b', L'\u012c', + L'\u012d', L'\u012e', L'\u012f', L'\u0130', L'\u0131', L'\u0132', + L'\u0133', L'\u0134', L'\u0135', L'\u0136', L'\u0137', L'\u0138', + L'\u0139', L'\u013a', L'\u013b', L'\u013c', L'\u013d', L'\u013e', + L'\u013f', L'\u0140', L'\u0141', L'\u0142', L'\u0143', L'\u0144', + L'\u0145', L'\u0146', L'\u0147', L'\u0148', L'\u0149', L'\u014a', + L'\u014b', L'\u014c', L'\u014d', L'\u014e', L'\u014f', L'\u0150', + L'\u0151', L'\u0152', L'\u0153', L'\u0154', L'\u0155', L'\u0156', + L'\u0157', L'\u0158', L'\u0159', L'\u015a', L'\u015b', L'\u015c', + L'\u015d', L'\u015e', L'\u015f', L'\u0160', L'\u0161', L'\u0162', + L'\u0163', L'\u0164', L'\u0165', L'\u0166', L'\u0167', L'\u0168', + L'\u0169', L'\u016a', L'\u016b', L'\u016c', L'\u016d', L'\u016e', + L'\u016f', L'\u0170', L'\u0171', L'\u0172', L'\u0173', L'\u0174', + L'\u0175', L'\u0176', L'\u0177', L'\u0178', L'\u0179', L'\u017a', + L'\u017b', L'\u017c', L'\u017d', L'\u017e', L'\u017f', L'\u0192', + L'\u01a0', L'\u01a1', L'\u01af', L'\u01b0', L'\u01e6', L'\u01e7', + L'\u01fa', L'\u01fb', L'\u01fc', L'\u01fd', L'\u01fe', L'\u01ff', + L'\u0218', L'\u0219', L'\u02bc', L'\u02bd', L'\u02c6', L'\u02c7', + L'\u02d8', L'\u02d9', L'\u02da', L'\u02db', L'\u02dc', L'\u02dd', + L'\u0300', L'\u0301', L'\u0303', L'\u0309', L'\u0323', L'\u0384', + L'\u0385', L'\u0386', L'\u0387', L'\u0388', L'\u0389', L'\u038a', + L'\u038c', L'\u038e', L'\u038f', L'\u0390', L'\u0391', L'\u0392', + L'\u0393', L'\u0394', L'\u0395', L'\u0396', L'\u0397', L'\u0398', + L'\u0399', L'\u039a', L'\u039b', L'\u039c', L'\u039d', L'\u039e', + L'\u039f', L'\u03a0', L'\u03a1', L'\u03a3', L'\u03a4', L'\u03a5', + L'\u03a6', L'\u03a7', L'\u03a8', L'\u03a9', L'\u03aa', L'\u03ab', + L'\u03ac', L'\u03ad', L'\u03ae', L'\u03af', L'\u03b0', L'\u03b1', + L'\u03b2', L'\u03b3', L'\u03b4', L'\u03b5', L'\u03b6', L'\u03b7', + L'\u03b8', L'\u03b9', L'\u03ba', L'\u03bb', L'\u03bc', L'\u03bd', + L'\u03be', L'\u03bf', L'\u03c0', L'\u03c1', L'\u03c2', L'\u03c3', + L'\u03c4', L'\u03c5', L'\u03c6', L'\u03c7', L'\u03c8', L'\u03c9', + L'\u03ca', L'\u03cb', L'\u03cc', L'\u03cd', L'\u03ce', L'\u03d1', + L'\u03d2', L'\u03d5', L'\u03d6', L'\u0401', L'\u0402', L'\u0403', + L'\u0404', L'\u0405', L'\u0406', L'\u0407', L'\u0408', L'\u0409', + L'\u040a', L'\u040b', L'\u040c', L'\u040e', L'\u040f', L'\u0410', + L'\u0411', L'\u0412', L'\u0413', L'\u0414', L'\u0415', L'\u0416', + L'\u0417', L'\u0418', L'\u0419', L'\u041a', L'\u041b', L'\u041c', + L'\u041d', L'\u041e', L'\u041f', L'\u0420', L'\u0421', L'\u0422', + L'\u0423', L'\u0424', L'\u0425', L'\u0426', L'\u0427', L'\u0428', + L'\u0429', L'\u042a', L'\u042b', L'\u042c', L'\u042d', L'\u042e', + L'\u042f', L'\u0430', L'\u0431', L'\u0432', L'\u0433', L'\u0434', + L'\u0435', L'\u0436', L'\u0437', L'\u0438', L'\u0439', L'\u043a', + L'\u043b', L'\u043c', L'\u043d', L'\u043e', L'\u043f', L'\u0440', + L'\u0441', L'\u0442', L'\u0443', L'\u0444', L'\u0445', L'\u0446', + L'\u0447', L'\u0448', L'\u0449', L'\u044a', L'\u044b', L'\u044c', + L'\u044d', L'\u044e', L'\u044f', L'\u0451', L'\u0452', L'\u0453', + L'\u0454', L'\u0455', L'\u0456', L'\u0457', L'\u0458', L'\u0459', + L'\u045a', L'\u045b', L'\u045c', L'\u045e', L'\u045f', L'\u0462', + L'\u0463', L'\u0472', L'\u0473', L'\u0474', L'\u0475', L'\u0490', + L'\u0491', L'\u04d9', L'\u05b0', L'\u05b1', L'\u05b2', L'\u05b3', + L'\u05b4', L'\u05b5', L'\u05b6', L'\u05b7', L'\u05b8', L'\u05b9', + L'\u05bb', L'\u05bc', L'\u05bd', L'\u05be', L'\u05bf', L'\u05c0', + L'\u05c1', L'\u05c2', L'\u05c3', L'\u05d0', L'\u05d1', L'\u05d2', + L'\u05d3', L'\u05d4', L'\u05d5', L'\u05d6', L'\u05d7', L'\u05d8', + L'\u05d9', L'\u05da', L'\u05db', L'\u05dc', L'\u05dd', L'\u05de', + L'\u05df', L'\u05e0', L'\u05e1', L'\u05e2', L'\u05e3', L'\u05e4', + L'\u05e5', L'\u05e6', L'\u05e7', L'\u05e8', L'\u05e9', L'\u05ea', + L'\u05f0', L'\u05f1', L'\u05f2', L'\u060c', L'\u061b', L'\u061f', + L'\u0621', L'\u0622', L'\u0623', L'\u0624', L'\u0625', L'\u0626', + L'\u0627', L'\u0628', L'\u0629', L'\u062a', L'\u062b', L'\u062c', + L'\u062d', L'\u062e', L'\u062f', L'\u0630', L'\u0631', L'\u0632', + L'\u0633', L'\u0634', L'\u0635', L'\u0636', L'\u0637', L'\u0638', + L'\u0639', L'\u063a', L'\u0640', L'\u0641', L'\u0642', L'\u0643', + L'\u0644', L'\u0645', L'\u0646', L'\u0647', L'\u0648', L'\u0649', + L'\u064a', L'\u064b', L'\u064c', L'\u064d', L'\u064e', L'\u064f', + L'\u0650', L'\u0651', L'\u0652', L'\u0660', L'\u0661', L'\u0662', + L'\u0663', L'\u0664', L'\u0665', L'\u0666', L'\u0667', L'\u0668', + L'\u0669', L'\u066a', L'\u066d', L'\u0679', L'\u067e', L'\u0686', + L'\u0688', L'\u0691', L'\u0698', L'\u06a4', L'\u06af', L'\u06ba', + L'\u06d2', L'\u06d5', L'\u1e80', L'\u1e81', L'\u1e82', L'\u1e83', + L'\u1e84', L'\u1e85', L'\u1ef2', L'\u1ef3', L'\u200c', L'\u200d', + L'\u200e', L'\u200f', L'\u2012', L'\u2013', L'\u2014', L'\u2015', + L'\u2017', L'\u2018', L'\u2019', L'\u201a', L'\u201b', L'\u201c', + L'\u201d', L'\u201e', L'\u2020', L'\u2021', L'\u2022', L'\u2024', + L'\u2025', L'\u2026', L'\u202c', L'\u202d', L'\u202e', L'\u2030', + L'\u2032', L'\u2033', L'\u2039', L'\u203a', L'\u203c', L'\u2044', + L'\u20a1', L'\u20a3', L'\u20a4', L'\u20a7', L'\u20aa', L'\u20ab', + L'\u20ac', L'\u2105', L'\u2111', L'\u2113', L'\u2116', L'\u2118', + L'\u211c', L'\u211e', L'\u2122', L'\u212e', L'\u2135', L'\u2153', + L'\u2154', L'\u215b', L'\u215c', L'\u215d', L'\u215e', L'\u2190', + L'\u2191', L'\u2192', L'\u2193', L'\u2194', L'\u2195', L'\u21a8', + L'\u21b5', L'\u21d0', L'\u21d1', L'\u21d2', L'\u21d3', L'\u21d4', + L'\u2200', L'\u2202', L'\u2203', L'\u2205', L'\u2207', L'\u2208', + L'\u2209', L'\u220b', L'\u220f', L'\u2211', L'\u2212', L'\u2217', + L'\u221a', L'\u221d', L'\u221e', L'\u221f', L'\u2220', L'\u2227', + L'\u2228', L'\u2229', L'\u222a', L'\u222b', L'\u2234', L'\u223c', + L'\u2245', L'\u2248', L'\u2260', L'\u2261', L'\u2264', L'\u2265', + L'\u2282', L'\u2283', L'\u2284', L'\u2286', L'\u2287', L'\u2295', + L'\u2297', L'\u22a5', L'\u22c5', L'\u2302', L'\u2310', L'\u2320', + L'\u2321', L'\u2329', L'\u232a', L'\u2500', L'\u2502', L'\u250c', + L'\u2510', L'\u2514', L'\u2518', L'\u251c', L'\u2524', L'\u252c', + L'\u2534', L'\u253c', L'\u2550', L'\u2551', L'\u2552', L'\u2553', + L'\u2554', L'\u2555', L'\u2556', L'\u2557', L'\u2558', L'\u2559', + L'\u255a', L'\u255b', L'\u255c', L'\u255d', L'\u255e', L'\u255f', + L'\u2560', L'\u2561', L'\u2562', L'\u2563', L'\u2564', L'\u2565', + L'\u2566', L'\u2567', L'\u2568', L'\u2569', L'\u256a', L'\u256b', + L'\u256c', L'\u2580', L'\u2584', L'\u2588', L'\u258c', L'\u2590', + L'\u2591', L'\u2592', L'\u2593', L'\u25a0', L'\u25a1', L'\u25aa', + L'\u25ab', L'\u25ac', L'\u25b2', L'\u25ba', L'\u25bc', L'\u25c4', + L'\u25ca', L'\u25cb', L'\u25cf', L'\u25d8', L'\u25d9', L'\u25e6', + L'\u263a', L'\u263b', L'\u263c', L'\u2640', L'\u2642', L'\u2660', + L'\u2663', L'\u2665', L'\u2666', L'\u266a', L'\u266b' +}; +static const char *adobe_glyph_name[nadobe_glyph] = { + "space", "exclam", "quotedbl", "numbersign", "dollar", "percent", + "ampersand", "quotesingle", "parenleft", "parenright", "asterisk", + "plus", "comma", "hyphen", "period", "slash", "zero", "one", + "two", "three", "four", "five", "six", "seven", "eight", "nine", + "colon", "semicolon", "less", "equal", "greater", "question", + "at", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", + "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", + "Z", "bracketleft", "backslash", "bracketright", "asciicircum", + "underscore", "grave", "a", "b", "c", "d", "e", "f", "g", "h", + "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", + "v", "w", "x", "y", "z", "braceleft", "bar", "braceright", + "asciitilde", "exclamdown", "cent", "sterling", "currency", "yen", + "brokenbar", "section", "dieresis", "copyright", "ordfeminine", + "guillemotleft", "logicalnot", "registered", "macron", "degree", + "plusminus", "acute", "paragraph", "periodcentered", "cedilla", + "ordmasculine", "guillemotright", "onequarter", "onehalf", + "threequarters", "questiondown", "Agrave", "Aacute", + "Acircumflex", "Atilde", "Adieresis", "Aring", "AE", "Ccedilla", + "Egrave", "Eacute", "Ecircumflex", "Edieresis", "Igrave", + "Iacute", "Icircumflex", "Idieresis", "Eth", "Ntilde", "Ograve", + "Oacute", "Ocircumflex", "Otilde", "Odieresis", "multiply", + "Oslash", "Ugrave", "Uacute", "Ucircumflex", "Udieresis", + "Yacute", "Thorn", "germandbls", "agrave", "aacute", + "acircumflex", "atilde", "adieresis", "aring", "ae", "ccedilla", + "egrave", "eacute", "ecircumflex", "edieresis", "igrave", + "iacute", "icircumflex", "idieresis", "eth", "ntilde", "ograve", + "oacute", "ocircumflex", "otilde", "odieresis", "divide", + "oslash", "ugrave", "uacute", "ucircumflex", "udieresis", + "yacute", "thorn", "ydieresis", "Amacron", "amacron", "Abreve", + "abreve", "Aogonek", "aogonek", "Cacute", "cacute", "Ccircumflex", + "ccircumflex", "Cdotaccent", "cdotaccent", "Ccaron", "ccaron", + "Dcaron", "dcaron", "Dcroat", "dcroat", "Emacron", "emacron", + "Ebreve", "ebreve", "Edotaccent", "edotaccent", "Eogonek", + "eogonek", "Ecaron", "ecaron", "Gcircumflex", "gcircumflex", + "Gbreve", "gbreve", "Gdotaccent", "gdotaccent", "Gcommaaccent", + "gcommaaccent", "Hcircumflex", "hcircumflex", "Hbar", "hbar", + "Itilde", "itilde", "Imacron", "imacron", "Ibreve", "ibreve", + "Iogonek", "iogonek", "Idotaccent", "dotlessi", "IJ", "ij", + "Jcircumflex", "jcircumflex", "Kcommaaccent", "kcommaaccent", + "kgreenlandic", "Lacute", "lacute", "Lcommaaccent", + "lcommaaccent", "Lcaron", "lcaron", "Ldot", "ldot", "Lslash", + "lslash", "Nacute", "nacute", "Ncommaaccent", "ncommaaccent", + "Ncaron", "ncaron", "napostrophe", "Eng", "eng", "Omacron", + "omacron", "Obreve", "obreve", "Ohungarumlaut", "ohungarumlaut", + "OE", "oe", "Racute", "racute", "Rcommaaccent", "rcommaaccent", + "Rcaron", "rcaron", "Sacute", "sacute", "Scircumflex", + "scircumflex", "Scedilla", "scedilla", "Scaron", "scaron", + "Tcommaaccent", "tcommaaccent", "Tcaron", "tcaron", "Tbar", + "tbar", "Utilde", "utilde", "Umacron", "umacron", "Ubreve", + "ubreve", "Uring", "uring", "Uhungarumlaut", "uhungarumlaut", + "Uogonek", "uogonek", "Wcircumflex", "wcircumflex", "Ycircumflex", + "ycircumflex", "Ydieresis", "Zacute", "zacute", "Zdotaccent", + "zdotaccent", "Zcaron", "zcaron", "longs", "florin", "Ohorn", + "ohorn", "Uhorn", "uhorn", "Gcaron", "gcaron", "Aringacute", + "aringacute", "AEacute", "aeacute", "Oslashacute", "oslashacute", + "Scommaaccent", "scommaaccent", "afii57929", "afii64937", + "circumflex", "caron", "breve", "dotaccent", "ring", "ogonek", + "tilde", "hungarumlaut", "gravecomb", "acutecomb", "tildecomb", + "hookabovecomb", "dotbelowcomb", "tonos", "dieresistonos", + "Alphatonos", "anoteleia", "Epsilontonos", "Etatonos", + "Iotatonos", "Omicrontonos", "Upsilontonos", "Omegatonos", + "iotadieresistonos", "Alpha", "Beta", "Gamma", "Delta", "Epsilon", + "Zeta", "Eta", "Theta", "Iota", "Kappa", "Lambda", "Mu", "Nu", + "Xi", "Omicron", "Pi", "Rho", "Sigma", "Tau", "Upsilon", "Phi", + "Chi", "Psi", "Omega", "Iotadieresis", "Upsilondieresis", + "alphatonos", "epsilontonos", "etatonos", "iotatonos", + "upsilondieresistonos", "alpha", "beta", "gamma", "delta", + "epsilon", "zeta", "eta", "theta", "iota", "kappa", "lambda", + "mu", "nu", "xi", "omicron", "pi", "rho", "sigma1", "sigma", + "tau", "upsilon", "phi", "chi", "psi", "omega", "iotadieresis", + "upsilondieresis", "omicrontonos", "upsilontonos", "omegatonos", + "theta1", "Upsilon1", "phi1", "omega1", "afii10023", "afii10051", + "afii10052", "afii10053", "afii10054", "afii10055", "afii10056", + "afii10057", "afii10058", "afii10059", "afii10060", "afii10061", + "afii10062", "afii10145", "afii10017", "afii10018", "afii10019", + "afii10020", "afii10021", "afii10022", "afii10024", "afii10025", + "afii10026", "afii10027", "afii10028", "afii10029", "afii10030", + "afii10031", "afii10032", "afii10033", "afii10034", "afii10035", + "afii10036", "afii10037", "afii10038", "afii10039", "afii10040", + "afii10041", "afii10042", "afii10043", "afii10044", "afii10045", + "afii10046", "afii10047", "afii10048", "afii10049", "afii10065", + "afii10066", "afii10067", "afii10068", "afii10069", "afii10070", + "afii10072", "afii10073", "afii10074", "afii10075", "afii10076", + "afii10077", "afii10078", "afii10079", "afii10080", "afii10081", + "afii10082", "afii10083", "afii10084", "afii10085", "afii10086", + "afii10087", "afii10088", "afii10089", "afii10090", "afii10091", + "afii10092", "afii10093", "afii10094", "afii10095", "afii10096", + "afii10097", "afii10071", "afii10099", "afii10100", "afii10101", + "afii10102", "afii10103", "afii10104", "afii10105", "afii10106", + "afii10107", "afii10108", "afii10109", "afii10110", "afii10193", + "afii10146", "afii10194", "afii10147", "afii10195", "afii10148", + "afii10196", "afii10050", "afii10098", "afii10846", "afii57799", + "afii57801", "afii57800", "afii57802", "afii57793", "afii57794", + "afii57795", "afii57798", "afii57797", "afii57806", "afii57796", + "afii57807", "afii57839", "afii57645", "afii57841", "afii57842", + "afii57804", "afii57803", "afii57658", "afii57664", "afii57665", + "afii57666", "afii57667", "afii57668", "afii57669", "afii57670", + "afii57671", "afii57672", "afii57673", "afii57674", "afii57675", + "afii57676", "afii57677", "afii57678", "afii57679", "afii57680", + "afii57681", "afii57682", "afii57683", "afii57684", "afii57685", + "afii57686", "afii57687", "afii57688", "afii57689", "afii57690", + "afii57716", "afii57717", "afii57718", "afii57388", "afii57403", + "afii57407", "afii57409", "afii57410", "afii57411", "afii57412", + "afii57413", "afii57414", "afii57415", "afii57416", "afii57417", + "afii57418", "afii57419", "afii57420", "afii57421", "afii57422", + "afii57423", "afii57424", "afii57425", "afii57426", "afii57427", + "afii57428", "afii57429", "afii57430", "afii57431", "afii57432", + "afii57433", "afii57434", "afii57440", "afii57441", "afii57442", + "afii57443", "afii57444", "afii57445", "afii57446", "afii57470", + "afii57448", "afii57449", "afii57450", "afii57451", "afii57452", + "afii57453", "afii57454", "afii57455", "afii57456", "afii57457", + "afii57458", "afii57392", "afii57393", "afii57394", "afii57395", + "afii57396", "afii57397", "afii57398", "afii57399", "afii57400", + "afii57401", "afii57381", "afii63167", "afii57511", "afii57506", + "afii57507", "afii57512", "afii57513", "afii57508", "afii57505", + "afii57509", "afii57514", "afii57519", "afii57534", "Wgrave", + "wgrave", "Wacute", "wacute", "Wdieresis", "wdieresis", "Ygrave", + "ygrave", "afii61664", "afii301", "afii299", "afii300", + "figuredash", "endash", "emdash", "afii00208", "underscoredbl", + "quoteleft", "quoteright", "quotesinglbase", "quotereversed", + "quotedblleft", "quotedblright", "quotedblbase", "dagger", + "daggerdbl", "bullet", "onedotenleader", "twodotenleader", + "ellipsis", "afii61573", "afii61574", "afii61575", "perthousand", + "minute", "second", "guilsinglleft", "guilsinglright", + "exclamdbl", "fraction", "colonmonetary", "franc", "lira", + "peseta", "afii57636", "dong", "Euro", "afii61248", "Ifraktur", + "afii61289", "afii61352", "weierstrass", "Rfraktur", + "prescription", "trademark", "estimated", "aleph", "onethird", + "twothirds", "oneeighth", "threeeighths", "fiveeighths", + "seveneighths", "arrowleft", "arrowup", "arrowright", "arrowdown", + "arrowboth", "arrowupdn", "arrowupdnbse", "carriagereturn", + "arrowdblleft", "arrowdblup", "arrowdblright", "arrowdbldown", + "arrowdblboth", "universal", "partialdiff", "existential", + "emptyset", "gradient", "element", "notelement", "suchthat", + "product", "summation", "minus", "asteriskmath", "radical", + "proportional", "infinity", "orthogonal", "angle", "logicaland", + "logicalor", "intersection", "union", "integral", "therefore", + "similar", "congruent", "approxequal", "notequal", "equivalence", + "lessequal", "greaterequal", "propersubset", "propersuperset", + "notsubset", "reflexsubset", "reflexsuperset", "circleplus", + "circlemultiply", "perpendicular", "dotmath", "house", + "revlogicalnot", "integraltp", "integralbt", "angleleft", + "angleright", "SF100000", "SF110000", "SF010000", "SF030000", + "SF020000", "SF040000", "SF080000", "SF090000", "SF060000", + "SF070000", "SF050000", "SF430000", "SF240000", "SF510000", + "SF520000", "SF390000", "SF220000", "SF210000", "SF250000", + "SF500000", "SF490000", "SF380000", "SF280000", "SF270000", + "SF260000", "SF360000", "SF370000", "SF420000", "SF190000", + "SF200000", "SF230000", "SF470000", "SF480000", "SF410000", + "SF450000", "SF460000", "SF400000", "SF540000", "SF530000", + "SF440000", "upblock", "dnblock", "block", "lfblock", "rtblock", + "ltshade", "shade", "dkshade", "filledbox", "H22073", "H18543", + "H18551", "filledrect", "triagup", "triagrt", "triagdn", + "triaglf", "lozenge", "circle", "H18533", "invbullet", + "invcircle", "openbullet", "smileface", "invsmileface", "sun", + "female", "male", "spade", "club", "heart", "diamond", + "musicalnote", "musicalnotedbl" +}; diff --git a/graf2d/mathtext/src/table/macintoshordering.h b/graf2d/mathtext/src/table/macintoshordering.h new file mode 100644 index 0000000000000..c97247f23cee9 --- /dev/null +++ b/graf2d/mathtext/src/table/macintoshordering.h @@ -0,0 +1,65 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +static const char *macintosh_ordering[] = { + ".notdef", ".null", "nonmarkingreturn", "space", "exclam", + "quotedbl", "numbersign", "dollar", "percent", "ampersand", + "quotesingle", "parenleft", "parenright", "asterisk", "plus", + "comma", "hyphen", "period", "slash", "zero", "one", "two", + "three", "four", "five", "six", "seven", "eight", "nine", + "colon", "semicolon", "less", "equal", "greater", "question", + "at", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", + "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", + "X", "Y", "Z", "bracketleft", "backslash", "bracketright", + "asciicircum", "underscore", "grave", "a", "b", "c", "d", "e", + "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", + "r", "s", "t", "u", "v", "w", "x", "y", "z", "braceleft", + "bar", "braceright", "asciitilde", "Adieresis", "Aring", + "Ccedilla", "Eacute", "Ntilde", "Odieresis", "Udieresis", + "aacute", "agrave", "acircumflex", "adieresis", "atilde", + "aring", "ccedilla", "eacute", "egrave", "ecircumflex", + "edieresis", "iacute", "igrave", "icircumflex", "idieresis", + "ntilde", "oacute", "ograve", "ocircumflex", "odieresis", + "otilde", "uacute", "ugrave", "ucircumflex", "udieresis", + "dagger", "degree", "cent", "sterling", "section", "bullet", + "paragraph", "germandbls", "registered", "copyright", + "trademark", "acute", "dieresis", "notequal", "AE", "Oslash", + "infinity", "plusminus", "lessequal", "greaterequal", "yen", + "mu", "partialdiff", "summation", "product", "pi", "integral", + "ordfeminine", "ordmasculine", "Omega", "ae", "oslash", + "questiondown", "exclamdown", "logicalnot", "radical", + "florin", "approxequal", "Delta", "guillemotleft", + "guillemotright", "ellipsis", "nonbreakingspace", "Agrave", + "Atilde", "Otilde", "OE", "oe", "endash", "emdash", + "quotedblleft", "quotedblright", "quoteleft", "quoteright", + "divide", "lozenge", "ydieresis", "Ydieresis", "fraction", + "currency", "guilsinglleft", "guilsinglright", "fi", "fl", + "daggerdbl", "periodcentered", "quotesinglbase", + "quotedblbase", "perthousand", "Acircumflex", "Ecircumflex", + "Aacute", "Edieresis", "Egrave", "Iacute", "Icircumflex", + "Idieresis", "Igrave", "Oacute", "Ocircumflex", "apple", + "Ograve", "Uacute", "Ucircumflex", "Ugrave", "dotlessi", + "circumflex", "tilde", "macron", "breve", "dotaccent", "ring", + "cedilla", "hungarumlaut", "ogonek", "caron", "Lslash", + "lslash", "Scaron", "scaron", "Zcaron", "zcaron", "brokenbar", + "Eth", "eth", "Yacute", "yacute", "Thorn", "thorn", "minus", + "multiply", "onesuperior", "twosuperior", "threesuperior", + "onehalf", "onequarter", "threequarters", "franc", "Gbreve", + "gbreve", "Idotaccent", "Scedilla", "scedilla", "Cacute", + "cacute", "Ccaron", "ccaron", "dcroat" +}; diff --git a/graf2d/mathtext/src/table/mathbracketcs.h b/graf2d/mathtext/src/table/mathbracketcs.h new file mode 100644 index 0000000000000..0368b9b4e815f --- /dev/null +++ b/graf2d/mathtext/src/table/mathbracketcs.h @@ -0,0 +1,23 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +static const unsigned long nbracket_control_sequence = 1; +static const char * +bracket_control_sequence[nbracket_control_sequence] = { + "\\sqrt" +}; diff --git a/graf2d/mathtext/src/table/mathfontch.h b/graf2d/mathtext/src/table/mathfontch.h new file mode 100644 index 0000000000000..74eddad36c07e --- /dev/null +++ b/graf2d/mathtext/src/table/mathfontch.h @@ -0,0 +1,34 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +static const unsigned long nfont_change = 8; +static const char * +font_change_control_sequence[nfont_change] = { + "\\mathbb", "\\mathbf", "\\mathfr", "\\mathit", "\\mathrm", + "\\mathscr", "\\mathsf", "\\mathtt" +}; +static const unsigned int font_change_family[nfont_change] = { + math_symbol_t::FAMILY_MATH_BLACKBOARD_BOLD, + math_symbol_t::FAMILY_BOLD, + math_symbol_t::FAMILY_MATH_FRAKTUR_REGULAR, + math_symbol_t::FAMILY_ITALIC, + math_symbol_t::FAMILY_REGULAR, + math_symbol_t::FAMILY_MATH_SCRIPT_ITALIC, + math_symbol_t::FAMILY_MATH_SANS_SERIF_REGULAR, + math_symbol_t::FAMILY_MATH_MONOSPACE +}; diff --git a/graf2d/mathtext/src/table/mathfontparam.h b/graf2d/mathtext/src/table/mathfontparam.h new file mode 100644 index 0000000000000..32ca9794b9888 --- /dev/null +++ b/graf2d/mathtext/src/table/mathfontparam.h @@ -0,0 +1,76 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +// See also Knuth (1986), p. 447 + +///////////////////////////////////////////////////////////////////// +// TeX Font Parameters + +// Following variables are derived from MathTime Professional II's +// mtpro2.sty +const float math_text_renderer_t::script_ratio = 0.7; +const float math_text_renderer_t::script_script_ratio = 0.55; +// Following variables are derived from plain.tex +const float math_text_renderer_t::thin_mu_skip = 3.0F; +const float math_text_renderer_t::med_mu_skip = 4.0F; +const float math_text_renderer_t::thick_mu_skip = 5.0F; +const float math_text_renderer_t::delimiter_factor = 901.0F; +const float math_text_renderer_t::delimiter_shortfall = 5.0F; + +///////////////////////////////////////////////////////////////////// +// (Explicit) TFM Font Parameters + +// Following variables are derived from MathTime Professional II's +// mt2syt.tfm +const float math_text_renderer_t::num_1 = 0.701F; +const float math_text_renderer_t::num_2 = 0.404F; +const float math_text_renderer_t::num_3 = 0.454F; +const float math_text_renderer_t::denom_1 = 0.710F; +const float math_text_renderer_t::denom_2 = 0.355F; +const float math_text_renderer_t::sup_1 = 0.413F; +const float math_text_renderer_t::sup_2 = 0.363F; +const float math_text_renderer_t::sup_3 = 0.289F; +const float math_text_renderer_t::sub_1 = 0.150F; +const float math_text_renderer_t::sub_2 = 0.269F; +const float math_text_renderer_t::sup_drop = 0.386F; +const float math_text_renderer_t::sub_drop = 0.050F; +const float math_text_renderer_t::delim_1 = 2.390F; +const float math_text_renderer_t::delim_2 = 1.010F; +// Following variables are derived from the STIX fonts. Axis +// height is defined by the horizontal axis of the minus sign +// (U+2212), the default rule thickness is the thickness of the em +// dash (U+2014). +const float math_text_renderer_t::axis_height = 0.253F; +const float math_text_renderer_t::default_rule_thickness = 0.049F; +// Following variables are derived from MathTime Professional II's +// mt2exa.tfm +const float math_text_renderer_t::big_op_spacing_1 = 0.116667F; +const float math_text_renderer_t::big_op_spacing_2 = 0.177777F; +const float math_text_renderer_t::big_op_spacing_3 = 0.211111F; +const float math_text_renderer_t::big_op_spacing_4 = 0.6F; +const float math_text_renderer_t::big_op_spacing_5 = 0.111111F; + +///////////////////////////////////////////////////////////////////// +// Implicit TFM Font Parameters +const float math_text_renderer_t::radical_rule_thickness = 0.054F; +const float math_text_renderer_t::large_operator_display_scale = + 1.4F; + +///////////////////////////////////////////////////////////////////// +// Text Mode Parameters +const float math_text_renderer_t::baselineskip_factor = 1.2F; diff --git a/graf2d/mathtext/src/table/mathglyphstd.h b/graf2d/mathtext/src/table/mathglyphstd.h new file mode 100644 index 0000000000000..e9a22fab4a1ef --- /dev/null +++ b/graf2d/mathtext/src/table/mathglyphstd.h @@ -0,0 +1,2210 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +static const unsigned long nglyph = 545; +static const char *glyph_control_sequence[nglyph] = { + "\\\"", + "\\'", + "\\.", + "\\=", + "\\Box", + "\\Bumpeq", + "\\Cap", + "\\Cup", + "\\Delta", + "\\Diamond", + "\\Digamma", + "\\Doteq", + "\\Downarrow", + "\\Finv", + "\\Game", + "\\Gamma", + "\\Im", + "\\Koppa", + "\\Lambda", + "\\Leftarrow", + "\\Leftrightarrow", + "\\Lleftarrow", + "\\Longleftarrow", + "\\Longleftrightarrow", + "\\Longrightarrow", + "\\Lsh", + "\\Omega", + "\\P", + "\\Phi", + "\\Pi", + "\\Psi", + "\\Re", + "\\Rightarrow", + "\\Rrightarrow", + "\\Rsh", + "\\S", + "\\Sampi", + "\\San", + "\\Sho", + "\\Sigma", + "\\Stigma", + "\\Subset", + "\\Supset", + "\\Theta", + "\\Uparrow", + "\\Updownarrow", + "\\Upsilon", + "\\VarKoppa", + "\\Vdash", + "\\Vert", + "\\Vvdash", + "\\Xi", + "\\^", + "\\`", + "\\aa", + "\\aleph", + "\\alpha", + "\\angle", + "\\approx", + "\\approxeq", + "\\asymp", + "\\backepsilon", + "\\backprime", + "\\backsim", + "\\backsimeq", + "\\backslash", + "\\barwedge", + "\\because", + "\\beta", + "\\beth", + "\\between", + "\\bigcirc", + "\\bigstar", + "\\bigtriangledown", + "\\bigtriangleup", + "\\blacklozenge", + "\\blacksquare", + "\\blacktriangle", + "\\blacktriangledown", + "\\blacktriangleleft", + "\\blacktriangleright", + "\\bowtie", + "\\boxdot", + "\\boxminus", + "\\boxplus", + "\\boxtimes", + "\\bullet", + "\\bulletdashcirc", + "\\bumpeq", + "\\cap", + "\\cdot", + "\\cdots", + "\\centerdot", + "\\checkmark", + "\\chi", + "\\circ", + "\\circdashbullet", + "\\circeq", + "\\circlearrowleft", + "\\circlearrowright", + "\\circledR", + "\\circledS", + "\\circledast", + "\\circledcirc", + "\\circleddash", + "\\clubsuit", + "\\coloneq", + "\\comp", + "\\complement", + "\\cong", + "\\coprod", + "\\cup", + "\\curlyeqprec", + "\\curlyeqsucc", + "\\curlyvee", + "\\curlywedge", + "\\curvearrowleft", + "\\dagger", + "\\daleth", + "\\dasharrow", + "\\dashdownarrow", + "\\dashleftarrow", + "\\dashrightarrow", + "\\dashuparrow", + "\\dashv", + "\\dbar", + "\\ddagger", + "\\ddddot", + "\\dddot", + "\\ddots", + "\\defineeq", + "\\defineequal", + "\\delta", + "\\diagdown", + "\\diagup", + "\\diamond", + "\\diamondsuit", + "\\digamma", + "\\digamma", + "\\div", + "\\divideontimes", + "\\doteq", + "\\doteqdot", + "\\dotplus", + "\\doublebarwedge", + "\\doublecap", + "\\doublecup", + "\\downarrow", + "\\downdownarrows", + "\\downdownharpoons", + "\\downharpoonleft", + "\\downharpoonright", + "\\downuparrows", + "\\downupharpoons", + "\\ell", + "\\emptyset", + "\\epsilon", + "\\eqcirc", + "\\eqcolon", + "\\eqsim", + "\\eqslantgtr", + "\\eqslantless", + "\\equiv", + "\\eta", + "\\eth", + "\\exists", + "\\fallingdotseq", + "\\flat", + "\\forall", + "\\frown", + "\\gamma", + "\\ge", + "\\geq", + "\\geqq", + "\\geqslant", + "\\gets", + "\\gg", + "\\ggg", + "\\gggtr", + "\\gimel", + "\\gnapprox", + "\\gneq", + "\\gneqq", + "\\gnsim", + "\\gtrapprox", + "\\gtrdot", + "\\gtreqless", + "\\gtreqqless", + "\\gtrless", + "\\gtrsim", + "\\hateq", + "\\hbar", + "\\heartsuit", + "\\hookleftarrow", + "\\hookrightarrow", + "\\hslash", + "\\imath", + "\\in", + "\\infty", + "\\intercal", + "\\iota", + "\\jmath", + "\\kappa", + "\\koppa", + "\\lambda", + "\\land", + "\\langle", + "\\lceil", + "\\ldbrack", + "\\ldots", + "\\le", + "\\leadsfrom", + "\\leadsto", + "\\leftarrow", + "\\leftarrowtail", + "\\leftharpoondown", + "\\leftharpoonup", + "\\leftleftarrows", + "\\leftrightarrow", + "\\leftrightarrows", + "\\leftrightharpoons", + "\\leftsquigarrow", + "\\leftthreetimes", + "\\leq", + "\\leqq", + "\\leqslant", + "\\lessapprox", + "\\lessdot", + "\\lesseqgtr", + "\\lesseqqgtr", + "\\lessgtr", + "\\lesssim", + "\\lfloor", + "\\lightning", + "\\ll", + "\\llcorner", + "\\lll", + "\\llless", + "\\lnapprox", + "\\lneq", + "\\lneqq", + "\\lnot", + "\\lnsim", + "\\longleftarrow", + "\\longleftrightarrow", + "\\longmapsto", + "\\longrightarrow", + "\\lor", + "\\lozenge", + "\\lrcorner", + "\\ltimes", + "\\maltese", + "\\mapsto", + "\\measuredangle", + "\\mho", + "\\mp", + "\\mu", + "\\multimap", + "\\nLeftarrow", + "\\nLeftrightarrow", + "\\nRightarrow", + "\\nVDash", + "\\nVdash", + "\\nabla", + "\\napprox", + "\\nasymp", + "\\natural", + "\\ncong", + "\\ne", + "\\nearrow", + "\\neg", + "\\neq", + "\\nequiv", + "\\nexists", + "\\ngeq", + "\\ngeqq", + "\\ngeqslant", + "\\ngtr", + "\\ni", + "\\nleftarrow", + "\\nleftrightarrow", + "\\nleq", + "\\nleqq", + "\\nleqslant", + "\\nless", + "\\nmid", + "\\not", + "\\notapprox", + "\\notasymp", + "\\notcong", + "\\notcong", + "\\notequiv", + "\\notgeq", + "\\notgeq", + "\\notgr", + "\\notgr", + "\\notin", + "\\notleq", + "\\notleq", + "\\notless", + "\\notless", + "\\notni", + "\\notprec", + "\\notprec", + "\\notsimeq", + "\\notsubset", + "\\notsubseteq", + "\\notsubseteq", + "\\notsucc", + "\\notsucc", + "\\notsupset", + "\\notsupseteq", + "\\notsupseteq", + "\\nparallel", + "\\nprec", + "\\nrightarrow", + "\\nsim", + "\\nsim", + "\\nsimeq", + "\\nsubset", + "\\nsubseteq", + "\\nsubseteqq", + "\\nsucc", + "\\nsupset", + "\\nsupseteq", + "\\nsupseteqq", + "\\ntriangleleft", + "\\ntrianglelefteq", + "\\ntriangleright", + "\\ntrianglerighteq", + "\\nu", + "\\nvDash", + "\\nvdash", + "\\nwarrow", + "\\odot", + "\\omega", + "\\ominus", + "\\openclubsuit", + "\\openspadesuit", + "\\oplus", + "\\oslash", + "\\otimes", + "\\owns", + "\\parallel", + "\\partial", + "\\perp", + "\\phi", + "\\pi", + "\\pitchfork", + "\\pm", + "\\prec", + "\\precapprox", + "\\preccurlyeq", + "\\preceq", + "\\precnapprox", + "\\precneqq", + "\\precnsim", + "\\precsim", + "\\prime", + "\\propto", + "\\psi", + "\\rangle", + "\\rceil", + "\\rdbrack", + "\\restriction", + "\\rfloor", + "\\rho", + "\\rightarrow", + "\\rightarrowtail", + "\\rightharpoondown", + "\\rightharpoonup", + "\\rightleftarrows", + "\\rightleftharpoons", + "\\rightrightarrows", + "\\rightsquigarrow", + "\\rightthreetimes", + "\\risingdotseq", + "\\rtimes", + "\\sampi", + "\\san", + "\\searrow", + "\\setdif", + "\\sharp", + "\\sho", + "\\sigma", + "\\sim", + "\\simarrow", + "\\simeq", + "\\smallfrown", + "\\smallint", + "\\smallsetminus", + "\\smallsmile", + "\\smile", + "\\spadesuit", + "\\sphericalangle", + "\\sqcap", + "\\sqcup", + "\\sqsubset", + "\\sqsubseteq", + "\\sqsupset", + "\\sqsupseteq", + "\\square", + "\\star", + "\\stigma", + "\\subset", + "\\subseteq", + "\\subseteqq", + "\\subsetneq", + "\\subsetneqq", + "\\succ", + "\\succapprox", + "\\succcurlyeq", + "\\succeq", + "\\succnapprox", + "\\succneqq", + "\\succnsim", + "\\succsim", + "\\supset", + "\\supseteq", + "\\supseteqq", + "\\supsetneq", + "\\supsetneqq", + "\\surd", + "\\swarrow", + "\\t", + "\\tau", + "\\therefore", + "\\theta", + "\\times", + "\\to", + "\\top", + "\\triangledown", + "\\triangleleft", + "\\triangleleft", + "\\trianglelefteq", + "\\triangleq", + "\\triangleright", + "\\trianglerighteq", + "\\twoheadleftarrow", + "\\twoheadrightarrow", + "\\u", + "\\ulcorner", + "\\undercurvearrowright", + "\\upDelta", + "\\upDigamma", + "\\upGamma", + "\\upKoppa", + "\\upLambda", + "\\upOmega", + "\\upPhi", + "\\upPi", + "\\upPsi", + "\\upSampi", + "\\upSan", + "\\upSho", + "\\upSigma", + "\\upStigma", + "\\upTheta", + "\\upUpsilon", + "\\upVarKoppa", + "\\upXi", + "\\upalpha", + "\\uparrow", + "\\upbeta", + "\\upchi", + "\\updbar", + "\\updelta", + "\\updigamma", + "\\updownarrow", + "\\updownarrows", + "\\updownharpoons", + "\\upepsilon", + "\\upeta", + "\\upgamma", + "\\upharpoonleft", + "\\upharpoonright", + "\\upiota", + "\\upkappa", + "\\upkoppa", + "\\uplambda", + "\\uplus", + "\\upmu", + "\\upnu", + "\\upomega", + "\\upphi", + "\\uppi", + "\\uppsi", + "\\uprho", + "\\upsampi", + "\\upsan", + "\\upsho", + "\\upsigma", + "\\upsilon", + "\\upstigma", + "\\uptau", + "\\uptheta", + "\\upuparrows", + "\\upupharpoons", + "\\upupsilon", + "\\upvarbeta", + "\\upvarepsilon", + "\\upvarkappa", + "\\upvarkoppa", + "\\upvarphi", + "\\upvarpi", + "\\upvarrho", + "\\upvarsigma", + "\\upvartheta", + "\\upxi", + "\\upzeta", + "\\urcorner", + "\\v", + "\\vDash", + "\\vDash", + "\\varbeta", + "\\varepsilon", + "\\varkappa", + "\\varkoppa", + "\\varnothing", + "\\varphi", + "\\varpi", + "\\varpropto", + "\\varrho", + "\\varsigma", + "\\vartheta", + "\\vartriangle", + "\\vartriangleleft", + "\\vartriangleright", + "\\vdash", + "\\vdots", + "\\vec", + "\\vee", + "\\veebar", + "\\vert", + "\\wedge", + "\\wp", + "\\wr", + "\\wwbar", + "\\xi", + "\\yen", + "\\zeta", + "\\{", + "\\|", + "\\}", + "\\~", +}; + +static const unsigned int glyph_type[nglyph] = { + atom_t::TYPE_ACC, + atom_t::TYPE_ACC, + atom_t::TYPE_ACC, + atom_t::TYPE_ACC, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ACC, + atom_t::TYPE_ACC, + atom_t::TYPE_ACC, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_OP, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_ACC, + atom_t::TYPE_ACC, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_OPEN, + atom_t::TYPE_OPEN, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_OPEN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_OPEN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_CLOSE, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_CLOSE, + atom_t::TYPE_CLOSE, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_CLOSE, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_OP, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_OP, + atom_t::TYPE_REL, + atom_t::TYPE_ACC, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_BIN, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ACC, + atom_t::TYPE_OPEN, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_CLOSE, + atom_t::TYPE_ACC, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_REL, + atom_t::TYPE_ORD, + atom_t::TYPE_ACC, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_BIN, + atom_t::TYPE_ORD, + atom_t::TYPE_BIN, + atom_t::TYPE_ACC, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_ORD, + atom_t::TYPE_OPEN, + atom_t::TYPE_BIN, + atom_t::TYPE_CLOSE, + atom_t::TYPE_ACC, +}; + +static const bool glyph_upright[nglyph] = { + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + false, + true, + true, + true, + true, + false, + true, + false, + false, + true, + true, + true, + true, + true, + true, + true, + false, + true, + false, + false, + false, + true, + true, + true, + true, + true, + false, + false, + false, + false, + false, + true, + true, + false, + true, + true, + false, + false, + true, + true, + true, + false, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + true, + false, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + false, + true, + true, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + true, + true, + false, + false, + false, + false, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + false, + true, + true, + true, + false, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + false, + false, + false, + true, + false, + false, + true, + false, + false, + false, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + true, + false, + true, + false, + true, + true, + true, + true, +}; + +static const wchar_t glyph_code_point[nglyph] = { + L'\u00a8', + L'\u00b4', + L'\u02d9', + L'\u00af', + L'\u25a1', + L'\u224e', + L'\u22d2', + L'\u22d3', + L'\u0394', + L'\u25c7', + L'\u03dc', + L'\u2251', + L'\u21d3', + L'\u2132', + L'\u2141', + L'\u0393', + L'\u2111', + L'\u03de', + L'\u039b', + L'\u21d0', + L'\u21d4', + L'\u21da', + L'\u27f8', + L'\u27fa', + L'\u27f9', + L'\u21b0', + L'\u03a9', + L'\u00b6', + L'\u03a6', + L'\u03a0', + L'\u03a8', + L'\u211c', + L'\u21d2', + L'\u21db', + L'\u21b1', + L'\u00a7', + L'\u03e0', + L'\u03fa', + L'\u03f7', + L'\u03a3', + L'\u03da', + L'\u22d0', + L'\u22d1', + L'\u0398', + L'\u21d1', + L'\u21d5', + L'\u03a5', + L'\u03d8', + L'\u22a9', + L'\u2016', + L'\u22aa', + L'\u039e', + L'\u02c6', + L'\140', + L'\u02da', + L'\u2135', + L'\u03b1', + L'\u2220', + L'\u2248', + L'\u224a', + L'\u224d', + L'\u220b', + L'\u2035', + L'\u223d', + L'\u22cd', + L'\134', + L'\u22bc', + L'\u2235', + L'\u03b2', + L'\u2136', + L'\u226c', + L'\u20dd', + L'\u2605', + L'\u25bd', + L'\u25b3', + L'\u29eb', + L'\u25a0', + L'\u25b4', + L'\u25be', + L'\u25c4', + L'\u25ba', + L'\u22c8', + L'\u22a1', + L'\u229f', + L'\u229e', + L'\u22a0', + L'\u2022', + L'\u22b7', + L'\u224f', + L'\u2229', + L'\u00b7', + L'\u22ef', + L'\u2b1d', + L'\u2713', + L'\u03c7', + L'\u25e6', + L'\u22b6', + L'\u2257', + L'\u21ba', + L'\u21bb', + L'\u00ae', + L'\u24c8', + L'\u229b', + L'\u229a', + L'\u229d', + L'\u2663', + L'\u2254', + L'\u2218', + L'\u2201', + L'\u2245', + L'\u2a3f', + L'\u222a', + L'\u22de', + L'\u22df', + L'\u22ce', + L'\u22cf', + L'\u293a', + L'\u2020', + L'\u2138', + L'\u21e2', + L'\u21e3', + L'\u21e0', + L'\u21e2', + L'\u21e1', + L'\u22a3', + L'\u0111', + L'\u2021', + L'\u20dc', + L'\u20db', + L'\u22f1', + L'\u225d', + L'\u225d', + L'\u03b4', + L'\u2572', + L'\u2571', + L'\u22c4', + L'\u2666', + L'\u03dd', + L'\u03dc', + L'\u00f7', + L'\u22c7', + L'\u2250', + L'\u2251', + L'\u2214', + L'\u2a5e', + L'\u22d2', + L'\u22d3', + L'\u2193', + L'\u21ca', + L'\u2965', + L'\u21c3', + L'\u21c2', + L'\u21f5', + L'\u296f', + L'\u2113', + L'\u2205', + L'\u03f5', + L'\u2256', + L'\u2255', + L'\u2242', + L'\u2a96', + L'\u2a95', + L'\u2261', + L'\u03b7', + L'\u00f0', + L'\u2203', + L'\u2252', + L'\u266d', + L'\u2200', + L'\u2322', + L'\u03b3', + L'\u2265', + L'\u2265', + L'\u2267', + L'\u2a7e', + L'\u2190', + L'\u226b', + L'\u226b', + L'\u226b', + L'\u05d2', + L'\u2a8a', + L'\u2a88', + L'\u2269', + L'\u22e7', + L'\u2a86', + L'\u22d7', + L'\u22db', + L'\u2a8c', + L'\u2277', + L'\u2273', + L'\u2259', + L'\u0127', + L'\u2665', + L'\u21a9', + L'\u21aa', + L'\u210f', + L'\u0131', + L'\u2208', + L'\u221e', + L'\u22ba', + L'\u03b9', + L'\u0237', + L'\u03ba', + L'\u03df', + L'\u03bb', + L'\u2227', + L'\u27e8', + L'\u2308', + L'\u27e6', + L'\u2026', + L'\u2264', + L'\u219c', + L'\u219d', + L'\u2190', + L'\u21a2', + L'\u21bd', + L'\u21bc', + L'\u21d4', + L'\u2194', + L'\u21c6', + L'\u21cb', + L'\u21dc', + L'\u22cb', + L'\u2264', + L'\u2266', + L'\u2a7d', + L'\u2a85', + L'\u22d6', + L'\u22da', + L'\u2a8b', + L'\u2276', + L'\u2272', + L'\u230a', + L'\u21af', + L'\u226a', + L'\u230e', + L'\u226a', + L'\u226a', + L'\u2a89', + L'\u2a87', + L'\u2268', + L'\u00ac', + L'\u22e6', + L'\u27f5', + L'\u27f7', + L'\u27fc', + L'\u27f6', + L'\u2228', + L'\u25ca', + L'\u230f', + L'\u22c9', + L'\u2720', + L'\u21a6', + L'\u2221', + L'\u2127', + L'\u2213', + L'\u03bc', + L'\u22b8', + L'\u21cd', + L'\u21ce', + L'\u21cf', + L'\u22af', + L'\u22ae', + L'\u2207', + L'\u2249', + L'\u226d', + L'\u266e', + L'\u2247', + L'\u2260', + L'\u2197', + L'\u00ac', + L'\u2260', + L'\u2262', + L'\u2204', + L'\u2271', + L'\ue08a', + L'\ue0b1', + L'\u226f', + L'\u220b', + L'\u219a', + L'\u21ae', + L'\u2270', + L'\ue088', + L'\ue0af', + L'\u226e', + L'\u2224', + L'\u0338', + L'\u2249', + L'\u226d', + L'\u2247', + L'\u2247', + L'\u2262', + L'\u2271', + L'\u2271', + L'\u226f', + L'\u226f', + L'\u2209', + L'\u2270', + L'\u2270', + L'\u226e', + L'\u226e', + L'\u220c', + L'\u2280', + L'\u2280', + L'\u2244', + L'\u2284', + L'\u2288', + L'\u2288', + L'\u2281', + L'\u2281', + L'\u2285', + L'\u2289', + L'\u2289', + L'\u2226', + L'\u2280', + L'\u219b', + L'\u2241', + L'\u2241', + L'\u2244', + L'\u2284', + L'\u2288', + L'\ue0bd', + L'\u2281', + L'\u2285', + L'\u2289', + L'\ue0bf', + L'\u22ea', + L'\u22ec', + L'\u22eb', + L'\u22ed', + L'\u03bd', + L'\u22ad', + L'\u22ac', + L'\u2196', + L'\u2299', + L'\u03c9', + L'\u2296', + L'\u2667', + L'\u2664', + L'\u2295', + L'\u2298', + L'\u2297', + L'\u220b', + L'\u2225', + L'\u2202', + L'\u22a5', + L'\u03d5', + L'\u03c0', + L'\u22d4', + L'\u00b1', + L'\u227a', + L'\u2ab7', + L'\u227c', + L'\u2aaf', + L'\u2ab9', + L'\u2ab5', + L'\u22e8', + L'\u227e', + L'\u2032', + L'\u221d', + L'\u03c8', + L'\u27e9', + L'\u2309', + L'\u27e7', + L'\u21be', + L'\u230b', + L'\u03c1', + L'\u2192', + L'\u21a3', + L'\u21c1', + L'\u21c0', + L'\u21c4', + L'\u21cc', + L'\u21d2', + L'\u21dd', + L'\u22cc', + L'\u2253', + L'\u22ca', + L'\u03e1', + L'\u03fb', + L'\u2198', + L'\u2216', + L'\u266f', + L'\u03f8', + L'\u03c3', + L'\u223c', + L'\u2b47', + L'\u2243', + L'\u2322', + L'\u222b', + L'\u2216', + L'\u2323', + L'\u2323', + L'\u2660', + L'\u2222', + L'\u2293', + L'\u2294', + L'\u228f', + L'\u2291', + L'\u2290', + L'\u2292', + L'\u25a1', + L'\u22c6', + L'\u03db', + L'\u2282', + L'\u2286', + L'\u2ac5', + L'\u228a', + L'\u2acb', + L'\u227b', + L'\u2ab8', + L'\u227d', + L'\u2ab0', + L'\u2aba', + L'\u2ab6', + L'\u22e9', + L'\u227f', + L'\u2283', + L'\u2287', + L'\u2ac6', + L'\u228b', + L'\u2acc', + L'\u221a', + L'\u2199', + L'\u2040', + L'\u03c4', + L'\u2234', + L'\u03b8', + L'\u00d7', + L'\u2192', + L'\u22a4', + L'\u25bf', + L'\u25b9', + L'\ue0c8', + L'\u22b4', + L'\u225c', + L'\u25c3', + L'\u22b5', + L'\u219e', + L'\u21a0', + L'\u02d8', + L'\u230c', + L'\u293b', + L'\u0394', + L'\u03dc', + L'\u0393', + L'\u03de', + L'\u039b', + L'\u03a9', + L'\u03a6', + L'\u03a0', + L'\u03a8', + L'\u03e0', + L'\u03fa', + L'\u03f7', + L'\u03a3', + L'\u03da', + L'\u0398', + L'\u03a5', + L'\u03d8', + L'\u039e', + L'\u03b1', + L'\u2191', + L'\u03b2', + L'\u03c7', + L'\u0111', + L'\u03b4', + L'\u03dd', + L'\u2195', + L'\u21c5', + L'\u296e', + L'\u03f5', + L'\u03b7', + L'\u03b3', + L'\u21bf', + L'\u21be', + L'\u03b9', + L'\u03ba', + L'\u03df', + L'\u03bb', + L'\u228e', + L'\u03bc', + L'\u03bd', + L'\u03c9', + L'\u03d5', + L'\u03c0', + L'\u03c8', + L'\u03c1', + L'\u03e1', + L'\u03fb', + L'\u03f8', + L'\u03c3', + L'\u03c5', + L'\u03db', + L'\u03c4', + L'\u03b8', + L'\u21c8', + L'\u2963', + L'\u03c5', + L'\u03d0', + L'\u03b5', + L'\u03f0', + L'\u03d9', + L'\u03c6', + L'\u03d6', + L'\u03f1', + L'\u03c2', + L'\u03d1', + L'\u03be', + L'\u03b6', + L'\u230d', + L'\u02c7', + L'\u22a8', + L'\u22a8', + L'\u03d0', + L'\u03b5', + L'\u03f0', + L'\u03d9', + L'\u2205', + L'\u03c6', + L'\u03d6', + L'\u221d', + L'\u03f1', + L'\u03c2', + L'\u03d1', + L'\u25b5', + L'\u25c5', + L'\u25bb', + L'\u22a2', + L'\u22ee', + L'\u20d7', + L'\u2228', + L'\u22bb', + L'\174', + L'\u2227', + L'\u2118', + L'\u2240', + L'\u0305', + L'\u03be', + L'\u00a5', + L'\u03b6', + L'\173', + L'\u2016', + L'\175', + L'\u02dc', +}; diff --git a/graf2d/mathtext/src/table/mathopstd.h b/graf2d/mathtext/src/table/mathopstd.h new file mode 100644 index 0000000000000..637c9e2743e7d --- /dev/null +++ b/graf2d/mathtext/src/table/mathopstd.h @@ -0,0 +1,62 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +static const unsigned long noperator = 66; +static const char *operator_control_sequence[noperator] = { + "\\Pr", "\\arccos", "\\arcsin", "\\arctan", "\\arg", "\\awoint", + "\\awointop", "\\barint", "\\barintop", "\\bigcap", "\\bigcup", + "\\bigodot", "\\bigoplus", "\\bigotimes", "\\bigsqcup", + "\\biguplus", "\\bigvee", "\\bigwedge", "\\coprod", "\\cos", + "\\cosh", "\\cot", "\\coth", "\\csc", "\\cwint", "\\cwintop", + "\\cwoint", "\\cwointop", "\\deg", "\\det", "\\dim", "\\exp", + "\\gcd", "\\hom", "\\iiint", "\\iiintop", "\\iint", "\\iintop", + "\\inf", "\\int", "\\intop", "\\ker", "\\lg", "\\lim", "\\liminf", + "\\limsup", "\\ln", "\\log", "\\max", "\\min", "\\oiiint", + "\\oiiintop", "\\oiint", "\\oiintop", "\\oint", "\\ointop", + "\\prod", "\\sec", "\\sin", "\\sinh", "\\slashint", + "\\slashintop", "\\sum", "\\sup", "\\tan", "\\tanh" +}; +static const wchar_t operator_code_point[noperator] = { + L'\0', L'\0', L'\0', L'\0', L'\0', L'\u2233', L'\u2233', + L'\u2a0d', L'\u2a0d', L'\u22c2', L'\u22c3', L'\u2a00', L'\u2a01', + L'\u2a02', L'\u2a06', L'\u2a04', L'\u22c1', L'\u22c0', L'\u2210', + L'\0', L'\0', L'\0', L'\0', L'\0', L'\u2231', L'\u2231', + L'\u2232', L'\u2232', L'\0', L'\0', L'\0', L'\0', L'\0', L'\0', + L'\u222d', L'\u222d', L'\u222c', L'\u222c', L'\0', L'\u222b', + L'\u222b', L'\0', L'\0', L'\0', L'\0', L'\0', L'\0', L'\0', L'\0', + L'\0', L'\u2230', L'\u2230', L'\u222f', L'\u222f', L'\u222e', + L'\u222e', L'\u220f', L'\0', L'\0', L'\0', L'\u2a0f', L'\u2a0f', + L'\u2211', L'\0', L'\0', L'\0' +}; +static const char *operator_content[noperator] = { + "Pr", "arccos", "arcsin", "arctan", "arg", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", "cos", "cosh", "cot", "coth", + "csc", "", "", "", "", "deg", "det", "dim", "exp", "gcd", "hom", + "", "", "", "", "inf", "", "", "ker", "lg", "lim", "lim\\,inf", + "lim\\,sup", "ln", "log", "max", "min", "", "", "", "", "", "", + "", "sec", "sin", "sinh", "", "", "", "sup", "tan", "tanh" +}; +static const bool operator_nolimits[noperator] = { + false, true, true, true, true, true, false, true, false, false, + false, false, false, false, false, false, false, false, false, + true, true, true, true, true, true, false, true, false, true, + false, true, true, false, true, true, false, true, false, false, + true, false, true, true, false, false, false, true, true, false, + false, true, false, true, false, true, false, false, true, true, + true, true, false, false, false, true, true +}; diff --git a/graf2d/mathtext/src/table/mathspacing.h b/graf2d/mathtext/src/table/mathspacing.h new file mode 100644 index 0000000000000..8c948f76dff0c --- /dev/null +++ b/graf2d/mathtext/src/table/mathspacing.h @@ -0,0 +1,31 @@ +// mathtext - A TeX/LaTeX compatible rendering library. Copyright (C) +// 2008-2012 Yue Shi Lai +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License +// as published by the Free Software Foundation; either version 2.1 of +// the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +// 02110-1301 USA + +// See also Knuth (1986), p. 170. +static const int nvr = INT_MIN; +static const int spacing_table[64] = { + // right -> Ord Op Bin Rel Open Close Punct Inner + /* Ord */ 0, 1, -2, -3, 0, 0, 0, -1, + /* Op */ 1, 1, nvr, -3, 0, 0, 0, -1, + /* Bin */ -2, -2, nvr, nvr, -2, nvr, nvr, -2, + /* Rel */ -3, -3, nvr, 0, -2, nvr, nvr, -2, + /* Open */ 0, 0, nvr, 0, 0, 0, 0, 0, + /* Close */ 0, 1, -2, -3, 0, 0, 0, -1, + /* Punct */ -1, -1, nvr, -1, -1, -1, -1, -1, + /* Inner */ -1, 1, -2, -3, -1, 0, -1, -1 +}; diff --git a/graf2d/postscript/CMakeLists.txt b/graf2d/postscript/CMakeLists.txt index bca51b5a385a1..011a43e29d15a 100644 --- a/graf2d/postscript/CMakeLists.txt +++ b/graf2d/postscript/CMakeLists.txt @@ -4,8 +4,9 @@ ############################################################################ ROOT_USE_PACKAGE(graf2d/graf) +ROOT_USE_PACKAGE(graf2d/mathtext) ROOT_GENERATE_DICTIONARY(G__PostScript *.h LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(Postscript LINKDEF LinkDef.h DEPENDENCIES Graf) -ROOT_LINKER_LIBRARY(Postscript *.cxx G__PostScript.cxx LIBRARIES ${ZLIB_LIBRARY} DEPENDENCIES Graf) +ROOT_LINKER_LIBRARY(Postscript *.cxx G__PostScript.cxx LIBRARIES ${ZLIB_LIBRARY} mathtext DEPENDENCIES Graf) ROOT_INSTALL_HEADERS() diff --git a/graf2d/postscript/Module.mk b/graf2d/postscript/Module.mk index 917e8e3e20da8..7871f9898f3b3 100644 --- a/graf2d/postscript/Module.mk +++ b/graf2d/postscript/Module.mk @@ -45,12 +45,12 @@ endif include/%.h: $(POSTSCRIPTDIRI)/%.h cp $< $@ -$(POSTSCRIPTLIB): $(POSTSCRIPTO) $(POSTSCRIPTDO) $(ORDER_) $(MAINLIBS) \ - $(POSTSCRIPTLIBDEP) +$(POSTSCRIPTLIB): $(POSTSCRIPTO) $(POSTSCRIPTDO) $(MATHTEXTLIBDEP) $(FREETYPEDEP) \ + $(ORDER_) $(MAINLIBS) $(POSTSCRIPTLIBDEP) @$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \ "$(SOFLAGS)" libPostscript.$(SOEXT) $@ \ "$(POSTSCRIPTO) $(POSTSCRIPTDO)" \ - "$(POSTSCRIPTLIBEXTRA)" + "$(POSTSCRIPTLIBEXTRA) $(MATHTEXTLIB) $(FREETYPELDFLAGS) $(FREETYPELIB)" $(POSTSCRIPTDS): $(POSTSCRIPTH) $(POSTSCRIPTL) $(ROOTCINTTMPDEP) $(MAKEDIR) @@ -75,6 +75,3 @@ distclean-$(MODNAME): clean-$(MODNAME) distclean:: distclean-$(MODNAME) ##### extra rules ###### -ifeq ($(ARCH),alphacxx6) -$(call stripsrc,$(POSTSCRIPTDIRS)/TPostScript.o): OPT = $(NOOPT) -endif diff --git a/graf2d/postscript/inc/LinkDef.h b/graf2d/postscript/inc/LinkDef.h index c0e37200696fe..6c3b934f5f66a 100644 --- a/graf2d/postscript/inc/LinkDef.h +++ b/graf2d/postscript/inc/LinkDef.h @@ -18,5 +18,6 @@ #pragma link C++ class TSVG+; #pragma link C++ class TPDF+; #pragma link C++ class TImageDump+; +#pragma link C++ class TTeXDump+; #endif diff --git a/graf2d/postscript/inc/TImageDump.h b/graf2d/postscript/inc/TImageDump.h index cc1f84f5bbb2d..12d5c510a0b42 100644 --- a/graf2d/postscript/inc/TImageDump.h +++ b/graf2d/postscript/inc/TImageDump.h @@ -59,6 +59,7 @@ class TImageDump : public TVirtualPS { void NewPage(); void Open(const char *filename, Int_t type = -111); void Text(Double_t x, Double_t y, const char *string); + void Text(Double_t x, Double_t y, const wchar_t *string); void SetColor(Float_t r, Float_t g, Float_t b); void *GetStream() const { return (void*)fImage; } void SetType(Int_t type = -111) { fType = type; } diff --git a/graf2d/postscript/inc/TPDF.h b/graf2d/postscript/inc/TPDF.h index 56c60145b30da..497677c8adf59 100644 --- a/graf2d/postscript/inc/TPDF.h +++ b/graf2d/postscript/inc/TPDF.h @@ -97,9 +97,11 @@ class TPDF : public TVirtualPS { void SetMarkerColor( Color_t cindex=1); void SetTextColor( Color_t cindex=1); void Text(Double_t x, Double_t y, const char *string); + void Text(Double_t, Double_t, const wchar_t *){} void TextNDC(Double_t u, Double_t v, const char *string); + void TextNDC(Double_t, Double_t, const wchar_t *){} void WriteCompressedBuffer(); - virtual void WriteReal(Float_t r); + virtual void WriteReal(Float_t r, Bool_t space=kTRUE); Double_t UtoPDF(Double_t u); Double_t VtoPDF(Double_t v); Double_t XtoPDF(Double_t x); diff --git a/graf2d/postscript/inc/TPostScript.h b/graf2d/postscript/inc/TPostScript.h index cf2d477ecaefa..c4cc007ccf9bc 100644 --- a/graf2d/postscript/inc/TPostScript.h +++ b/graf2d/postscript/inc/TPostScript.h @@ -86,6 +86,8 @@ class TPostScript : public TVirtualPS { Int_t fLastCellGreen; //Last green value Int_t fLastCellBlue; //Last blue value Int_t fNBSameColorCell; //Number of boxes with the same color + TString fFileName; //PS file name + Bool_t fFontEmbed; //True is FontEmbed has been called static Int_t fgLineJoin; //Appearance of joining lines @@ -114,6 +116,10 @@ class TPostScript : public TVirtualPS { void DrawPolyMarker(Int_t n, Double_t *x, Double_t *y); void DrawPS(Int_t n, Float_t *xw, Float_t *yw); void DrawPS(Int_t n, Double_t *xw, Double_t *yw); + bool FontEmbedType1(const char *filename); + bool FontEmbedType2(const char *filename); + bool FontEmbedType42(const char *filename); + void FontEmbed(); void FontEncode(); void Initialize(); void NewPage(); @@ -135,7 +141,9 @@ class TPostScript : public TVirtualPS { void SetColor(Int_t color = 1); void SetColor(Float_t r, Float_t g, Float_t b); void Text(Double_t x, Double_t y, const char *string); + void Text(Double_t x, Double_t y, const wchar_t *string); void TextNDC(Double_t u, Double_t v, const char *string); + void TextNDC(Double_t u, Double_t v, const wchar_t *string); Int_t UtoPS(Double_t u); Int_t VtoPS(Double_t v); Int_t XtoPS(Double_t x); diff --git a/graf2d/postscript/inc/TSVG.h b/graf2d/postscript/inc/TSVG.h index 3b11adebf9ee1..987884b146f72 100644 --- a/graf2d/postscript/inc/TSVG.h +++ b/graf2d/postscript/inc/TSVG.h @@ -73,7 +73,9 @@ class TSVG : public TVirtualPS { void SetMarkerColor( Color_t cindex=1); void SetTextColor( Color_t cindex=1); void Text(Double_t x, Double_t y, const char *string); + void Text(Double_t, Double_t, const wchar_t *){} void TextNDC(Double_t u, Double_t v, const char *string); + void TextNDC(Double_t, Double_t, const wchar_t *){} Int_t UtoSVG(Double_t u); Int_t VtoSVG(Double_t v); Int_t XtoSVG(Double_t x); diff --git a/graf2d/postscript/inc/TTeXDump.h b/graf2d/postscript/inc/TTeXDump.h new file mode 100644 index 0000000000000..98225a064b897 --- /dev/null +++ b/graf2d/postscript/inc/TTeXDump.h @@ -0,0 +1,90 @@ +// @(#)root/postscript:$Id$ +// Author: Olivier Couet + +/************************************************************************* + * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TTeXDump +#define ROOT_TTeXDump + + +////////////////////////////////////////////////////////////////////////// +// // +// TTeXDump // +// // +// Tex driver. // +// // +////////////////////////////////////////////////////////////////////////// + +#ifndef ROOT_TVirtualPS +#include "TVirtualPS.h" +#endif + +class TPoints; + +class TTeXDump : public TVirtualPS { + +protected: + Float_t fXsize; //Page size along X + Float_t fYsize; //Page size along Y + Int_t fType; //Workstation type used to know if the Tex is open + Bool_t fBoundingBox; //True when the Tex header is printed + Bool_t fRange; //True when a range has been defined + Float_t fCurrentRed; //Current Red component + Float_t fCurrentGreen; //Current Green component + Float_t fCurrentBlue; //Current Blue component + + +public: + TTeXDump(); + TTeXDump(const char *filename, Int_t type=-113); + virtual ~TTeXDump(); + + void CellArrayBegin(Int_t W, Int_t H, Double_t x1, Double_t x2, Double_t y1, Double_t y2); + void CellArrayFill(Int_t r, Int_t g, Int_t b); + void CellArrayEnd(); + void Close(Option_t *opt=""); + Int_t CMtoTeX(Double_t u) {return Int_t(0.5 + 72*u/2.54);} + void DefineMarkers(); + void DrawBox(Double_t x1, Double_t y1,Double_t x2, Double_t y2); + void DrawFrame(Double_t xl, Double_t yl, Double_t xt, Double_t yt, + Int_t mode, Int_t border, Int_t dark, Int_t light); + void DrawPolyLine(Int_t n, TPoints *xy); + void DrawPolyLineNDC(Int_t n, TPoints *uv); + void DrawPolyMarker(Int_t n, Float_t *x, Float_t *y); + void DrawPolyMarker(Int_t n, Double_t *x, Double_t *y); + void DrawPS(Int_t n, Float_t *xw, Float_t *yw); + void DrawPS(Int_t n, Double_t *xw, Double_t *yw); + void NewPage(); + void Off(); + void On(); + void Open(const char *filename, Int_t type=-111); + void Range(Float_t xrange, Float_t yrange); + void SetColor(Int_t color = 1); + void SetColor(Float_t r, Float_t g, Float_t b); + void SetFillColor( Color_t cindex=1); + void SetLineColor( Color_t cindex=1); + void SetLineStyle(Style_t linestyle = 1); + void SetLineWidth(Width_t linewidth = 1); + void SetLineScale(Float_t =3) { } + void SetMarkerSize( Size_t msize=1); + void SetMarkerColor( Color_t cindex=1); + void SetTextColor( Color_t cindex=1); + void Text(Double_t x, Double_t y, const char *string); + void Text(Double_t, Double_t, const wchar_t *){} + void TextNDC(Double_t u, Double_t v, const char *string); + void TextNDC(Double_t, Double_t, const wchar_t *){} + Float_t UtoTeX(Double_t u); + Float_t VtoTeX(Double_t v); + Float_t XtoTeX(Double_t x); + Float_t YtoTeX(Double_t y); + + ClassDef(TTeXDump,0) //Tex driver +}; + +#endif diff --git a/graf2d/postscript/src/AdobeGlyphList.h b/graf2d/postscript/src/AdobeGlyphList.h new file mode 100644 index 0000000000000..61e707088a350 --- /dev/null +++ b/graf2d/postscript/src/AdobeGlyphList.h @@ -0,0 +1,297 @@ +static const unsigned long nadobe_glyph = 835; +static const wchar_t adobe_glyph_ucs[nadobe_glyph] = { + L'\040', L'\041', L'\042', L'\043', L'\044', L'\045', L'\046', + L'\047', L'\050', L'\051', L'\052', L'\053', L'\054', L'\055', + L'\056', L'\057', L'\060', L'\061', L'\062', L'\063', L'\064', + L'\065', L'\066', L'\067', L'\070', L'\071', L'\072', L'\073', + L'\074', L'\075', L'\076', L'\077', L'\100', L'\101', L'\102', + L'\103', L'\104', L'\105', L'\106', L'\107', L'\110', L'\111', + L'\112', L'\113', L'\114', L'\115', L'\116', L'\117', L'\120', + L'\121', L'\122', L'\123', L'\124', L'\125', L'\126', L'\127', + L'\130', L'\131', L'\132', L'\133', L'\134', L'\135', L'\136', + L'\137', L'\140', L'\141', L'\142', L'\143', L'\144', L'\145', + L'\146', L'\147', L'\150', L'\151', L'\152', L'\153', L'\154', + L'\155', L'\156', L'\157', L'\160', L'\161', L'\162', L'\163', + L'\164', L'\165', L'\166', L'\167', L'\170', L'\171', L'\172', + L'\173', L'\174', L'\175', L'\176', L'\241', L'\242', L'\243', + L'\244', L'\245', L'\246', L'\247', L'\250', L'\251', L'\252', + L'\253', L'\254', L'\256', L'\257', L'\260', L'\261', L'\264', + L'\266', L'\267', L'\270', L'\272', L'\273', L'\274', L'\275', + L'\276', L'\277', L'\300', L'\301', L'\302', L'\303', L'\304', + L'\305', L'\306', L'\307', L'\310', L'\311', L'\312', L'\313', + L'\314', L'\315', L'\316', L'\317', L'\320', L'\321', L'\322', + L'\323', L'\324', L'\325', L'\326', L'\327', L'\330', L'\331', + L'\332', L'\333', L'\334', L'\335', L'\336', L'\337', L'\340', + L'\341', L'\342', L'\343', L'\344', L'\345', L'\346', L'\347', + L'\350', L'\351', L'\352', L'\353', L'\354', L'\355', L'\356', + L'\357', L'\360', L'\361', L'\362', L'\363', L'\364', L'\365', + L'\366', L'\367', L'\370', L'\371', L'\372', L'\373', L'\374', + L'\375', L'\376', L'\377', L'\u0100', L'\u0101', L'\u0102', + L'\u0103', L'\u0104', L'\u0105', L'\u0106', L'\u0107', L'\u0108', + L'\u0109', L'\u010a', L'\u010b', L'\u010c', L'\u010d', L'\u010e', + L'\u010f', L'\u0110', L'\u0111', L'\u0112', L'\u0113', L'\u0114', + L'\u0115', L'\u0116', L'\u0117', L'\u0118', L'\u0119', L'\u011a', + L'\u011b', L'\u011c', L'\u011d', L'\u011e', L'\u011f', L'\u0120', + L'\u0121', L'\u0122', L'\u0123', L'\u0124', L'\u0125', L'\u0126', + L'\u0127', L'\u0128', L'\u0129', L'\u012a', L'\u012b', L'\u012c', + L'\u012d', L'\u012e', L'\u012f', L'\u0130', L'\u0131', L'\u0132', + L'\u0133', L'\u0134', L'\u0135', L'\u0136', L'\u0137', L'\u0138', + L'\u0139', L'\u013a', L'\u013b', L'\u013c', L'\u013d', L'\u013e', + L'\u013f', L'\u0140', L'\u0141', L'\u0142', L'\u0143', L'\u0144', + L'\u0145', L'\u0146', L'\u0147', L'\u0148', L'\u0149', L'\u014a', + L'\u014b', L'\u014c', L'\u014d', L'\u014e', L'\u014f', L'\u0150', + L'\u0151', L'\u0152', L'\u0153', L'\u0154', L'\u0155', L'\u0156', + L'\u0157', L'\u0158', L'\u0159', L'\u015a', L'\u015b', L'\u015c', + L'\u015d', L'\u015e', L'\u015f', L'\u0160', L'\u0161', L'\u0162', + L'\u0163', L'\u0164', L'\u0165', L'\u0166', L'\u0167', L'\u0168', + L'\u0169', L'\u016a', L'\u016b', L'\u016c', L'\u016d', L'\u016e', + L'\u016f', L'\u0170', L'\u0171', L'\u0172', L'\u0173', L'\u0174', + L'\u0175', L'\u0176', L'\u0177', L'\u0178', L'\u0179', L'\u017a', + L'\u017b', L'\u017c', L'\u017d', L'\u017e', L'\u017f', L'\u0192', + L'\u01a0', L'\u01a1', L'\u01af', L'\u01b0', L'\u01e6', L'\u01e7', + L'\u01fa', L'\u01fb', L'\u01fc', L'\u01fd', L'\u01fe', L'\u01ff', + L'\u0218', L'\u0219', L'\u02bc', L'\u02bd', L'\u02c6', L'\u02c7', + L'\u02d8', L'\u02d9', L'\u02da', L'\u02db', L'\u02dc', L'\u02dd', + L'\u0300', L'\u0301', L'\u0303', L'\u0309', L'\u0323', L'\u0384', + L'\u0385', L'\u0386', L'\u0387', L'\u0388', L'\u0389', L'\u038a', + L'\u038c', L'\u038e', L'\u038f', L'\u0390', L'\u0391', L'\u0392', + L'\u0393', L'\u0394', L'\u0395', L'\u0396', L'\u0397', L'\u0398', + L'\u0399', L'\u039a', L'\u039b', L'\u039c', L'\u039d', L'\u039e', + L'\u039f', L'\u03a0', L'\u03a1', L'\u03a3', L'\u03a4', L'\u03a5', + L'\u03a6', L'\u03a7', L'\u03a8', L'\u03a9', L'\u03aa', L'\u03ab', + L'\u03ac', L'\u03ad', L'\u03ae', L'\u03af', L'\u03b0', L'\u03b1', + L'\u03b2', L'\u03b3', L'\u03b4', L'\u03b5', L'\u03b6', L'\u03b7', + L'\u03b8', L'\u03b9', L'\u03ba', L'\u03bb', L'\u03bc', L'\u03bd', + L'\u03be', L'\u03bf', L'\u03c0', L'\u03c1', L'\u03c2', L'\u03c3', + L'\u03c4', L'\u03c5', L'\u03c6', L'\u03c7', L'\u03c8', L'\u03c9', + L'\u03ca', L'\u03cb', L'\u03cc', L'\u03cd', L'\u03ce', L'\u03d1', + L'\u03d2', L'\u03d5', L'\u03d6', L'\u0401', L'\u0402', L'\u0403', + L'\u0404', L'\u0405', L'\u0406', L'\u0407', L'\u0408', L'\u0409', + L'\u040a', L'\u040b', L'\u040c', L'\u040e', L'\u040f', L'\u0410', + L'\u0411', L'\u0412', L'\u0413', L'\u0414', L'\u0415', L'\u0416', + L'\u0417', L'\u0418', L'\u0419', L'\u041a', L'\u041b', L'\u041c', + L'\u041d', L'\u041e', L'\u041f', L'\u0420', L'\u0421', L'\u0422', + L'\u0423', L'\u0424', L'\u0425', L'\u0426', L'\u0427', L'\u0428', + L'\u0429', L'\u042a', L'\u042b', L'\u042c', L'\u042d', L'\u042e', + L'\u042f', L'\u0430', L'\u0431', L'\u0432', L'\u0433', L'\u0434', + L'\u0435', L'\u0436', L'\u0437', L'\u0438', L'\u0439', L'\u043a', + L'\u043b', L'\u043c', L'\u043d', L'\u043e', L'\u043f', L'\u0440', + L'\u0441', L'\u0442', L'\u0443', L'\u0444', L'\u0445', L'\u0446', + L'\u0447', L'\u0448', L'\u0449', L'\u044a', L'\u044b', L'\u044c', + L'\u044d', L'\u044e', L'\u044f', L'\u0451', L'\u0452', L'\u0453', + L'\u0454', L'\u0455', L'\u0456', L'\u0457', L'\u0458', L'\u0459', + L'\u045a', L'\u045b', L'\u045c', L'\u045e', L'\u045f', L'\u0462', + L'\u0463', L'\u0472', L'\u0473', L'\u0474', L'\u0475', L'\u0490', + L'\u0491', L'\u04d9', L'\u05b0', L'\u05b1', L'\u05b2', L'\u05b3', + L'\u05b4', L'\u05b5', L'\u05b6', L'\u05b7', L'\u05b8', L'\u05b9', + L'\u05bb', L'\u05bc', L'\u05bd', L'\u05be', L'\u05bf', L'\u05c0', + L'\u05c1', L'\u05c2', L'\u05c3', L'\u05d0', L'\u05d1', L'\u05d2', + L'\u05d3', L'\u05d4', L'\u05d5', L'\u05d6', L'\u05d7', L'\u05d8', + L'\u05d9', L'\u05da', L'\u05db', L'\u05dc', L'\u05dd', L'\u05de', + L'\u05df', L'\u05e0', L'\u05e1', L'\u05e2', L'\u05e3', L'\u05e4', + L'\u05e5', L'\u05e6', L'\u05e7', L'\u05e8', L'\u05e9', L'\u05ea', + L'\u05f0', L'\u05f1', L'\u05f2', L'\u060c', L'\u061b', L'\u061f', + L'\u0621', L'\u0622', L'\u0623', L'\u0624', L'\u0625', L'\u0626', + L'\u0627', L'\u0628', L'\u0629', L'\u062a', L'\u062b', L'\u062c', + L'\u062d', L'\u062e', L'\u062f', L'\u0630', L'\u0631', L'\u0632', + L'\u0633', L'\u0634', L'\u0635', L'\u0636', L'\u0637', L'\u0638', + L'\u0639', L'\u063a', L'\u0640', L'\u0641', L'\u0642', L'\u0643', + L'\u0644', L'\u0645', L'\u0646', L'\u0647', L'\u0648', L'\u0649', + L'\u064a', L'\u064b', L'\u064c', L'\u064d', L'\u064e', L'\u064f', + L'\u0650', L'\u0651', L'\u0652', L'\u0660', L'\u0661', L'\u0662', + L'\u0663', L'\u0664', L'\u0665', L'\u0666', L'\u0667', L'\u0668', + L'\u0669', L'\u066a', L'\u066d', L'\u0679', L'\u067e', L'\u0686', + L'\u0688', L'\u0691', L'\u0698', L'\u06a4', L'\u06af', L'\u06ba', + L'\u06d2', L'\u06d5', L'\u1e80', L'\u1e81', L'\u1e82', L'\u1e83', + L'\u1e84', L'\u1e85', L'\u1ef2', L'\u1ef3', L'\u200c', L'\u200d', + L'\u200e', L'\u200f', L'\u2012', L'\u2013', L'\u2014', L'\u2015', + L'\u2017', L'\u2018', L'\u2019', L'\u201a', L'\u201b', L'\u201c', + L'\u201d', L'\u201e', L'\u2020', L'\u2021', L'\u2022', L'\u2024', + L'\u2025', L'\u2026', L'\u202c', L'\u202d', L'\u202e', L'\u2030', + L'\u2032', L'\u2033', L'\u2039', L'\u203a', L'\u203c', L'\u2044', + L'\u20a1', L'\u20a3', L'\u20a4', L'\u20a7', L'\u20aa', L'\u20ab', + L'\u20ac', L'\u2105', L'\u2111', L'\u2113', L'\u2116', L'\u2118', + L'\u211c', L'\u211e', L'\u2122', L'\u212e', L'\u2135', L'\u2153', + L'\u2154', L'\u215b', L'\u215c', L'\u215d', L'\u215e', L'\u2190', + L'\u2191', L'\u2192', L'\u2193', L'\u2194', L'\u2195', L'\u21a8', + L'\u21b5', L'\u21d0', L'\u21d1', L'\u21d2', L'\u21d3', L'\u21d4', + L'\u2200', L'\u2202', L'\u2203', L'\u2205', L'\u2207', L'\u2208', + L'\u2209', L'\u220b', L'\u220f', L'\u2211', L'\u2212', L'\u2217', + L'\u221a', L'\u221d', L'\u221e', L'\u221f', L'\u2220', L'\u2227', + L'\u2228', L'\u2229', L'\u222a', L'\u222b', L'\u2234', L'\u223c', + L'\u2245', L'\u2248', L'\u2260', L'\u2261', L'\u2264', L'\u2265', + L'\u2282', L'\u2283', L'\u2284', L'\u2286', L'\u2287', L'\u2295', + L'\u2297', L'\u22a5', L'\u22c5', L'\u2302', L'\u2310', L'\u2320', + L'\u2321', L'\u2329', L'\u232a', L'\u2500', L'\u2502', L'\u250c', + L'\u2510', L'\u2514', L'\u2518', L'\u251c', L'\u2524', L'\u252c', + L'\u2534', L'\u253c', L'\u2550', L'\u2551', L'\u2552', L'\u2553', + L'\u2554', L'\u2555', L'\u2556', L'\u2557', L'\u2558', L'\u2559', + L'\u255a', L'\u255b', L'\u255c', L'\u255d', L'\u255e', L'\u255f', + L'\u2560', L'\u2561', L'\u2562', L'\u2563', L'\u2564', L'\u2565', + L'\u2566', L'\u2567', L'\u2568', L'\u2569', L'\u256a', L'\u256b', + L'\u256c', L'\u2580', L'\u2584', L'\u2588', L'\u258c', L'\u2590', + L'\u2591', L'\u2592', L'\u2593', L'\u25a0', L'\u25a1', L'\u25aa', + L'\u25ab', L'\u25ac', L'\u25b2', L'\u25ba', L'\u25bc', L'\u25c4', + L'\u25ca', L'\u25cb', L'\u25cf', L'\u25d8', L'\u25d9', L'\u25e6', + L'\u263a', L'\u263b', L'\u263c', L'\u2640', L'\u2642', L'\u2660', + L'\u2663', L'\u2665', L'\u2666', L'\u266a', L'\u266b' +}; +static const char *adobe_glyph_name[nadobe_glyph] = { + "space", "exclam", "quotedbl", "numbersign", "dollar", "percent", + "ampersand", "quotesingle", "parenleft", "parenright", "asterisk", + "plus", "comma", "hyphen", "period", "slash", "zero", "one", + "two", "three", "four", "five", "six", "seven", "eight", "nine", + "colon", "semicolon", "less", "equal", "greater", "question", + "at", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", + "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", + "Z", "bracketleft", "backslash", "bracketright", "asciicircum", + "underscore", "grave", "a", "b", "c", "d", "e", "f", "g", "h", + "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", + "v", "w", "x", "y", "z", "braceleft", "bar", "braceright", + "asciitilde", "exclamdown", "cent", "sterling", "currency", "yen", + "brokenbar", "section", "dieresis", "copyright", "ordfeminine", + "guillemotleft", "logicalnot", "registered", "macron", "degree", + "plusminus", "acute", "paragraph", "periodcentered", "cedilla", + "ordmasculine", "guillemotright", "onequarter", "onehalf", + "threequarters", "questiondown", "Agrave", "Aacute", + "Acircumflex", "Atilde", "Adieresis", "Aring", "AE", "Ccedilla", + "Egrave", "Eacute", "Ecircumflex", "Edieresis", "Igrave", + "Iacute", "Icircumflex", "Idieresis", "Eth", "Ntilde", "Ograve", + "Oacute", "Ocircumflex", "Otilde", "Odieresis", "multiply", + "Oslash", "Ugrave", "Uacute", "Ucircumflex", "Udieresis", + "Yacute", "Thorn", "germandbls", "agrave", "aacute", + "acircumflex", "atilde", "adieresis", "aring", "ae", "ccedilla", + "egrave", "eacute", "ecircumflex", "edieresis", "igrave", + "iacute", "icircumflex", "idieresis", "eth", "ntilde", "ograve", + "oacute", "ocircumflex", "otilde", "odieresis", "divide", + "oslash", "ugrave", "uacute", "ucircumflex", "udieresis", + "yacute", "thorn", "ydieresis", "Amacron", "amacron", "Abreve", + "abreve", "Aogonek", "aogonek", "Cacute", "cacute", "Ccircumflex", + "ccircumflex", "Cdotaccent", "cdotaccent", "Ccaron", "ccaron", + "Dcaron", "dcaron", "Dcroat", "dcroat", "Emacron", "emacron", + "Ebreve", "ebreve", "Edotaccent", "edotaccent", "Eogonek", + "eogonek", "Ecaron", "ecaron", "Gcircumflex", "gcircumflex", + "Gbreve", "gbreve", "Gdotaccent", "gdotaccent", "Gcommaaccent", + "gcommaaccent", "Hcircumflex", "hcircumflex", "Hbar", "hbar", + "Itilde", "itilde", "Imacron", "imacron", "Ibreve", "ibreve", + "Iogonek", "iogonek", "Idotaccent", "dotlessi", "IJ", "ij", + "Jcircumflex", "jcircumflex", "Kcommaaccent", "kcommaaccent", + "kgreenlandic", "Lacute", "lacute", "Lcommaaccent", + "lcommaaccent", "Lcaron", "lcaron", "Ldot", "ldot", "Lslash", + "lslash", "Nacute", "nacute", "Ncommaaccent", "ncommaaccent", + "Ncaron", "ncaron", "napostrophe", "Eng", "eng", "Omacron", + "omacron", "Obreve", "obreve", "Ohungarumlaut", "ohungarumlaut", + "OE", "oe", "Racute", "racute", "Rcommaaccent", "rcommaaccent", + "Rcaron", "rcaron", "Sacute", "sacute", "Scircumflex", + "scircumflex", "Scedilla", "scedilla", "Scaron", "scaron", + "Tcommaaccent", "tcommaaccent", "Tcaron", "tcaron", "Tbar", + "tbar", "Utilde", "utilde", "Umacron", "umacron", "Ubreve", + "ubreve", "Uring", "uring", "Uhungarumlaut", "uhungarumlaut", + "Uogonek", "uogonek", "Wcircumflex", "wcircumflex", "Ycircumflex", + "ycircumflex", "Ydieresis", "Zacute", "zacute", "Zdotaccent", + "zdotaccent", "Zcaron", "zcaron", "longs", "florin", "Ohorn", + "ohorn", "Uhorn", "uhorn", "Gcaron", "gcaron", "Aringacute", + "aringacute", "AEacute", "aeacute", "Oslashacute", "oslashacute", + "Scommaaccent", "scommaaccent", "afii57929", "afii64937", + "circumflex", "caron", "breve", "dotaccent", "ring", "ogonek", + "tilde", "hungarumlaut", "gravecomb", "acutecomb", "tildecomb", + "hookabovecomb", "dotbelowcomb", "tonos", "dieresistonos", + "Alphatonos", "anoteleia", "Epsilontonos", "Etatonos", + "Iotatonos", "Omicrontonos", "Upsilontonos", "Omegatonos", + "iotadieresistonos", "Alpha", "Beta", "Gamma", "Delta", "Epsilon", + "Zeta", "Eta", "Theta", "Iota", "Kappa", "Lambda", "Mu", "Nu", + "Xi", "Omicron", "Pi", "Rho", "Sigma", "Tau", "Upsilon", "Phi", + "Chi", "Psi", "Omega", "Iotadieresis", "Upsilondieresis", + "alphatonos", "epsilontonos", "etatonos", "iotatonos", + "upsilondieresistonos", "alpha", "beta", "gamma", "delta", + "epsilon", "zeta", "eta", "theta", "iota", "kappa", "lambda", + "mu", "nu", "xi", "omicron", "pi", "rho", "sigma1", "sigma", + "tau", "upsilon", "phi", "chi", "psi", "omega", "iotadieresis", + "upsilondieresis", "omicrontonos", "upsilontonos", "omegatonos", + "theta1", "Upsilon1", "phi1", "omega1", "afii10023", "afii10051", + "afii10052", "afii10053", "afii10054", "afii10055", "afii10056", + "afii10057", "afii10058", "afii10059", "afii10060", "afii10061", + "afii10062", "afii10145", "afii10017", "afii10018", "afii10019", + "afii10020", "afii10021", "afii10022", "afii10024", "afii10025", + "afii10026", "afii10027", "afii10028", "afii10029", "afii10030", + "afii10031", "afii10032", "afii10033", "afii10034", "afii10035", + "afii10036", "afii10037", "afii10038", "afii10039", "afii10040", + "afii10041", "afii10042", "afii10043", "afii10044", "afii10045", + "afii10046", "afii10047", "afii10048", "afii10049", "afii10065", + "afii10066", "afii10067", "afii10068", "afii10069", "afii10070", + "afii10072", "afii10073", "afii10074", "afii10075", "afii10076", + "afii10077", "afii10078", "afii10079", "afii10080", "afii10081", + "afii10082", "afii10083", "afii10084", "afii10085", "afii10086", + "afii10087", "afii10088", "afii10089", "afii10090", "afii10091", + "afii10092", "afii10093", "afii10094", "afii10095", "afii10096", + "afii10097", "afii10071", "afii10099", "afii10100", "afii10101", + "afii10102", "afii10103", "afii10104", "afii10105", "afii10106", + "afii10107", "afii10108", "afii10109", "afii10110", "afii10193", + "afii10146", "afii10194", "afii10147", "afii10195", "afii10148", + "afii10196", "afii10050", "afii10098", "afii10846", "afii57799", + "afii57801", "afii57800", "afii57802", "afii57793", "afii57794", + "afii57795", "afii57798", "afii57797", "afii57806", "afii57796", + "afii57807", "afii57839", "afii57645", "afii57841", "afii57842", + "afii57804", "afii57803", "afii57658", "afii57664", "afii57665", + "afii57666", "afii57667", "afii57668", "afii57669", "afii57670", + "afii57671", "afii57672", "afii57673", "afii57674", "afii57675", + "afii57676", "afii57677", "afii57678", "afii57679", "afii57680", + "afii57681", "afii57682", "afii57683", "afii57684", "afii57685", + "afii57686", "afii57687", "afii57688", "afii57689", "afii57690", + "afii57716", "afii57717", "afii57718", "afii57388", "afii57403", + "afii57407", "afii57409", "afii57410", "afii57411", "afii57412", + "afii57413", "afii57414", "afii57415", "afii57416", "afii57417", + "afii57418", "afii57419", "afii57420", "afii57421", "afii57422", + "afii57423", "afii57424", "afii57425", "afii57426", "afii57427", + "afii57428", "afii57429", "afii57430", "afii57431", "afii57432", + "afii57433", "afii57434", "afii57440", "afii57441", "afii57442", + "afii57443", "afii57444", "afii57445", "afii57446", "afii57470", + "afii57448", "afii57449", "afii57450", "afii57451", "afii57452", + "afii57453", "afii57454", "afii57455", "afii57456", "afii57457", + "afii57458", "afii57392", "afii57393", "afii57394", "afii57395", + "afii57396", "afii57397", "afii57398", "afii57399", "afii57400", + "afii57401", "afii57381", "afii63167", "afii57511", "afii57506", + "afii57507", "afii57512", "afii57513", "afii57508", "afii57505", + "afii57509", "afii57514", "afii57519", "afii57534", "Wgrave", + "wgrave", "Wacute", "wacute", "Wdieresis", "wdieresis", "Ygrave", + "ygrave", "afii61664", "afii301", "afii299", "afii300", + "figuredash", "endash", "emdash", "afii00208", "underscoredbl", + "quoteleft", "quoteright", "quotesinglbase", "quotereversed", + "quotedblleft", "quotedblright", "quotedblbase", "dagger", + "daggerdbl", "bullet", "onedotenleader", "twodotenleader", + "ellipsis", "afii61573", "afii61574", "afii61575", "perthousand", + "minute", "second", "guilsinglleft", "guilsinglright", + "exclamdbl", "fraction", "colonmonetary", "franc", "lira", + "peseta", "afii57636", "dong", "Euro", "afii61248", "Ifraktur", + "afii61289", "afii61352", "weierstrass", "Rfraktur", + "prescription", "trademark", "estimated", "aleph", "onethird", + "twothirds", "oneeighth", "threeeighths", "fiveeighths", + "seveneighths", "arrowleft", "arrowup", "arrowright", "arrowdown", + "arrowboth", "arrowupdn", "arrowupdnbse", "carriagereturn", + "arrowdblleft", "arrowdblup", "arrowdblright", "arrowdbldown", + "arrowdblboth", "universal", "partialdiff", "existential", + "emptyset", "gradient", "element", "notelement", "suchthat", + "product", "summation", "minus", "asteriskmath", "radical", + "proportional", "infinity", "orthogonal", "angle", "logicaland", + "logicalor", "intersection", "union", "integral", "therefore", + "similar", "congruent", "approxequal", "notequal", "equivalence", + "lessequal", "greaterequal", "propersubset", "propersuperset", + "notsubset", "reflexsubset", "reflexsuperset", "circleplus", + "circlemultiply", "perpendicular", "dotmath", "house", + "revlogicalnot", "integraltp", "integralbt", "angleleft", + "angleright", "SF100000", "SF110000", "SF010000", "SF030000", + "SF020000", "SF040000", "SF080000", "SF090000", "SF060000", + "SF070000", "SF050000", "SF430000", "SF240000", "SF510000", + "SF520000", "SF390000", "SF220000", "SF210000", "SF250000", + "SF500000", "SF490000", "SF380000", "SF280000", "SF270000", + "SF260000", "SF360000", "SF370000", "SF420000", "SF190000", + "SF200000", "SF230000", "SF470000", "SF480000", "SF410000", + "SF450000", "SF460000", "SF400000", "SF540000", "SF530000", + "SF440000", "upblock", "dnblock", "block", "lfblock", "rtblock", + "ltshade", "shade", "dkshade", "filledbox", "H22073", "H18543", + "H18551", "filledrect", "triagup", "triagrt", "triagdn", + "triaglf", "lozenge", "circle", "H18533", "invbullet", + "invcircle", "openbullet", "smileface", "invsmileface", "sun", + "female", "male", "spade", "club", "heart", "diamond", + "musicalnote", "musicalnotedbl" +}; diff --git a/graf2d/postscript/src/TImageDump.cxx b/graf2d/postscript/src/TImageDump.cxx index f67b15b5b4671..7ca0b18e5a7e0 100644 --- a/graf2d/postscript/src/TImageDump.cxx +++ b/graf2d/postscript/src/TImageDump.cxx @@ -60,6 +60,7 @@ TImageDump::TImageDump() : TVirtualPS() fImage = 0; gVirtualPS = this; fType = 0; + SetTitle("IMG"); } //______________________________________________________________________________ @@ -76,6 +77,7 @@ TImageDump::TImageDump(const char *fname, Int_t wtype) : TVirtualPS(fname, wtype Open(fname, wtype); gVirtualPS = this; + SetTitle("IMG"); } //______________________________________________________________________________ @@ -132,6 +134,9 @@ void TImageDump::DrawBox(Double_t x1, Double_t y1, Double_t x2, Double_t y2) Int_t ix2 = x1 < x2 ? XtoPixel(x2) : XtoPixel(x1); Int_t iy1 = y1 < y2 ? YtoPixel(y1) : YtoPixel(y2); Int_t iy2 = y1 < y2 ? YtoPixel(y2) : YtoPixel(y1); + + if (ix1<0 || ix2 <0 || iy1 < 0 || iy2 <0) return; // box is not visible + if (TMath::Abs(ix2-ix1) < 1) ix2 = ix1+1; if (TMath::Abs(iy1-iy2) < 1) iy1 = iy2+1; @@ -374,7 +379,7 @@ void TImageDump::DrawPolyMarker(Int_t n, Double_t *xw, Double_t *yw) pt[1].fX = Short_t(ix+m2); pt[1].fY = Short_t(iy-m2); pt[2].fX = Short_t(ix); pt[2].fY = Short_t(iy+m2); pt[3].fX = Short_t(ix-m2); pt[3].fY = Short_t(iy-m2); - ms == 32 ? fImage->DrawPolyLine(4, pt, col->AsHexString()) : + ms == 32 ? fImage->DrawPolyLine(4, pt, col->AsHexString()) : fImage->FillPolygon(3, pt, col->AsHexString()); break; // Up triangle @@ -669,6 +674,30 @@ void TImageDump::Text(Double_t x, Double_t y, const char *chars) } +//______________________________________________________________________________ +void TImageDump::Text(Double_t x, Double_t y, const wchar_t *chars) +{ + // Draw text + // + // x: x position of the text + // y: y position of the text + + if (!gPad || !fImage) { + return; + } + + fImage->BeginPaint(); + + TText t(x, y, chars); + t.SetTextSize(fTextSize); + t.SetTextFont(fTextFont); + t.SetTextAlign(fTextAlign); + t.SetTextAngle(fTextAngle); + t.SetTextColor(fTextColor); + fImage->DrawText(&t, XtoPixel(x), YtoPixel(y)); +} + + ////////////////////////// CellArray code //////////////////////////////////// static UInt_t *gCellArrayColors = 0; static Int_t gCellArrayN = 0; diff --git a/graf2d/postscript/src/TPDF.cxx b/graf2d/postscript/src/TPDF.cxx index 4b9ba3a4875d7..0ca6f7bacc713 100644 --- a/graf2d/postscript/src/TPDF.cxx +++ b/graf2d/postscript/src/TPDF.cxx @@ -505,8 +505,8 @@ void TPDF::DrawPolyLine(Int_t nn, TPoints *xy) WriteReal(XtoPDF(xy[0].GetX())); WriteReal(YtoPDF(xy[0].GetY())); - if( n <= 1) { - if( n == 0) return; + if (n <= 1) { + if (n == 0) return; PrintFast(2," m"); return; } @@ -515,7 +515,7 @@ void TPDF::DrawPolyLine(Int_t nn, TPoints *xy) for (Int_t i=1;i 0 ) { + if (nn > 0) { if (xy[0].GetX() == xy[n-1].GetX() && xy[0].GetY() == xy[n-1].GetY()) PrintFast(3," cl"); PrintFast(2," S"); } else { @@ -558,8 +558,8 @@ void TPDF::DrawPolyLineNDC(Int_t nn, TPoints *xy) WriteReal(UtoPDF(xy[0].GetX())); WriteReal(VtoPDF(xy[0].GetY())); - if( n <= 1) { - if( n == 0) return; + if (n <= 1) { + if (n == 0) return; PrintFast(2," m"); return; } @@ -568,7 +568,7 @@ void TPDF::DrawPolyLineNDC(Int_t nn, TPoints *xy) for (Int_t i=1;i 0 ) { + if (nn > 0) { if (xy[0].GetX() == xy[n-1].GetX() && xy[0].GetY() == xy[n-1].GetY()) PrintFast(3," cl"); PrintFast(2," S"); } else { @@ -913,8 +913,8 @@ void TPDF::DrawPS(Int_t nn, Float_t *xw, Float_t *yw) WriteReal(XtoPDF(xw[0])); WriteReal(YtoPDF(yw[0])); - if( n <= 1) { - if( n == 0) return; + if (n <= 1) { + if (n == 0) return; PrintFast(2," m"); return; } @@ -923,7 +923,7 @@ void TPDF::DrawPS(Int_t nn, Float_t *xw, Float_t *yw) for (Int_t i=1;i 0 ) { + if (nn > 0) { if (xw[0] == xw[n-1] && yw[0] == yw[n-1]) PrintFast(2," h"); PrintFast(2," S"); } else { @@ -999,8 +999,8 @@ void TPDF::DrawPS(Int_t nn, Double_t *xw, Double_t *yw) WriteReal(XtoPDF(xw[0])); WriteReal(YtoPDF(yw[0])); - if( n <= 1) { - if( n == 0) return; + if (n <= 1) { + if (n == 0) return; PrintFast(2," m"); return; } @@ -1009,7 +1009,7 @@ void TPDF::DrawPS(Int_t nn, Double_t *xw, Double_t *yw) for (Int_t i=1;i 0 ) { + if (nn > 0) { if (xw[0] == xw[n-1] && yw[0] == yw[n-1]) PrintFast(2," h"); PrintFast(2," S"); } else { @@ -1118,7 +1118,7 @@ void TPDF::NewPage() { // Start a new PDF page. - if(!fPageNotEmpty)return; + if (!fPageNotEmpty) return; // Compute pad conversion coefficients if (gPad) { @@ -1364,7 +1364,7 @@ void TPDF::Open(const char *fname, Int_t wtype) // orientation = 1 for portrait // orientation = 2 for landscape fPageOrientation = fType%10; - if( fPageOrientation < 1 || fPageOrientation > 2) { + if (fPageOrientation < 1 || fPageOrientation > 2) { Error("Open", "Invalid page orientation %d", fPageOrientation); return; } @@ -1374,8 +1374,8 @@ void TPDF::Open(const char *fname, Int_t wtype) // format = 200 is the US format 8.5x14.0 inch // format = 300 is the US format 11.0x17.0 inch fPageFormat = fType/1000; - if( fPageFormat == 0 ) fPageFormat = 4; - if( fPageFormat == 99 ) fPageFormat = 0; + if (fPageFormat == 0) fPageFormat = 4; + if (fPageFormat == 99) fPageFormat = 0; fRange = kFALSE; @@ -1923,9 +1923,9 @@ void TPDF::Range(Float_t xsize, Float_t ysize) xps = xsize; yps = ysize; - if( xsize <= xps && ysize < yps) { - if ( xps > yps ) xymax = xps; - else xymax = yps; + if (xsize <= xps && ysize < yps) { + if ( xps > yps) xymax = xps; + else xymax = yps; xncm = xsize/xymax; yncm = ysize/xymax; dxwn = ((xps/xymax)-xncm)/2; @@ -1941,7 +1941,7 @@ void TPDF::Range(Float_t xsize, Float_t ysize) yncm = ywkwn; dxwn = (xwkwn-xncm)/2; dywn = 0; - if( dxwn < 0) { + if (dxwn < 0) { xncm = xwkwn; dxwn = 0; yncm = xwkwn*ysize/xsize; @@ -1952,7 +1952,7 @@ void TPDF::Range(Float_t xsize, Float_t ysize) yncm = xwkwn*ysize/xsize; dxwn = 0; dywn = (ywkwn-yncm)/2; - if( dywn < 0) { + if (dywn < 0) { yncm = ywkwn; dywn = 0; xncm = ywkwn*xsize/ysize; @@ -2208,7 +2208,7 @@ void TPDF::Text(Double_t xx, Double_t yy, const char *chars) // Font and text size Int_t font = abs(fTextFont)/10; - if( font > kNumberOfFonts || font < 1) font = 1; + if (font > kNumberOfFonts || font < 1) font = 1; Double_t wh = (Double_t)gPad->XtoPixel(gPad->GetX2()); Double_t hh = (Double_t)gPad->YtoPixel(gPad->GetY1()); @@ -2223,7 +2223,7 @@ void TPDF::Text(Double_t xx, Double_t yy, const char *chars) ftsize = (sizeTTF*fYsize*gPad->GetAbsHNDC())/hh; } Double_t fontsize = 72*(ftsize)/2.54; - if( fontsize <= 0) return; + if (fontsize <= 0) return; // Text alignment Float_t tsizex = gPad->AbsPixeltoX(Int_t(tsize))-gPad->AbsPixeltoX(0); @@ -2232,10 +2232,10 @@ void TPDF::Text(Double_t xx, Double_t yy, const char *chars) if (txalh < 1) txalh = 1; if (txalh > 3) txalh = 3; Int_t txalv = fTextAlign%10; if (txalv < 1) txalv = 1; if (txalv > 3) txalv = 3; - if( txalv == 3) { + if (txalv == 3) { y -= 0.8*tsizey*TMath::Cos(kDEGRAD*fTextAngle); x += 0.8*tsizex*TMath::Sin(kDEGRAD*fTextAngle); - } else if( txalv == 2) { + } else if (txalv == 2) { y -= 0.4*tsizey*TMath::Cos(kDEGRAD*fTextAngle); x += 0.4*tsizex*TMath::Sin(kDEGRAD*fTextAngle); } @@ -2248,49 +2248,29 @@ void TPDF::Text(Double_t xx, Double_t yy, const char *chars) t.GetTextExtent(w, h, chars); Double_t twx = gPad->AbsPixeltoX(w)-gPad->AbsPixeltoX(0); Double_t twy = gPad->AbsPixeltoY(0)-gPad->AbsPixeltoY(w); - if(txalh == 2){ + if (txalh == 2) { x = x-(twx/2)*TMath::Cos(kDEGRAD*fTextAngle); y = y-(twy/2)*TMath::Sin(kDEGRAD*fTextAngle); } - if(txalh == 3){ + if (txalh == 3) { x = x-twx*TMath::Cos(kDEGRAD*fTextAngle); y = y-twy*TMath::Sin(kDEGRAD*fTextAngle); } } - // Symbol Italic tan(15) = .26794 - if (font == 15) { - Float_t tanAlpha = 0.26794; - Float_t dx = - tanAlpha * YtoPDF(y); - PrintStr(" q 1 0"); - WriteReal(tanAlpha); - PrintStr(" 1"); - WriteReal(dx); - PrintStr(" 0 cm"); - } - - PrintStr(" BT"); - - snprintf(str,8," /F%d",font); - PrintStr(str); - WriteReal(fontsize); - PrintStr(" Tf"); - // Text angle - if(fTextAngle == 0) { + if (fTextAngle == 0) { + PrintStr(" 1 0 0 1"); WriteReal(XtoPDF(x)); WriteReal(YtoPDF(y)); - PrintStr(" Td"); } else if (fTextAngle == 90) { PrintStr(" 0 1 -1 0"); WriteReal(XtoPDF(x)); WriteReal(YtoPDF(y)); - PrintStr(" Tm"); } else if (fTextAngle == 270) { PrintStr(" 0 -1 1 0"); WriteReal(XtoPDF(x)); WriteReal(YtoPDF(y)); - PrintStr(" Tm"); } else { WriteReal(TMath::Cos(kDEGRAD*fTextAngle)); WriteReal(TMath::Sin(kDEGRAD*fTextAngle)); @@ -2298,8 +2278,18 @@ void TPDF::Text(Double_t xx, Double_t yy, const char *chars) WriteReal(TMath::Cos(kDEGRAD*fTextAngle)); WriteReal(XtoPDF(x)); WriteReal(YtoPDF(y)); - PrintStr(" Tm"); } + PrintStr(" cm"); + + // Symbol Italic tan(15) = .26794 + if (font == 15) PrintStr(" 1 0 0.26794 1 0 0 cm"); + + PrintStr(" BT"); + + snprintf(str,8," /F%d",font); + PrintStr(str); + WriteReal(fontsize); + PrintStr(" Tf"); const Int_t len=strlen(chars); @@ -2372,7 +2362,6 @@ void TPDF::Text(Double_t xx, Double_t yy, const char *chars) if (kerning) PrintStr("] TJ ET Q"); else PrintStr(") Tj ET Q"); - if (font == 15) PrintStr(" Q"); if (!fCompress) PrintStr("@"); if (kerning) delete [] charDeltas; } @@ -2471,7 +2460,7 @@ void TPDF::WriteCompressedBuffer() } //______________________________________________________________________________ -void TPDF::WriteReal(Float_t z) +void TPDF::WriteReal(Float_t z, Bool_t space) { // Write a Real number to the file. // This method overwrites TVirtualPS::WriteReal. Some PDF reader like @@ -2480,7 +2469,12 @@ void TPDF::WriteReal(Float_t z) // format "%g" when writing it with "%g" generates a number with exponent. char str[15]; - snprintf(str,15," %g", z); - if (strstr(str,"e") || strstr(str,"E")) snprintf(str,15," %10.8f", z); + if (space) { + snprintf(str,15," %g", z); + if (strstr(str,"e") || strstr(str,"E")) snprintf(str,15," %10.8f", z); + } else { + snprintf(str,15,"%g", z); + if (strstr(str,"e") || strstr(str,"E")) snprintf(str,15,"%10.8f", z); + } PrintStr(str); -} +} \ No newline at end of file diff --git a/graf2d/postscript/src/TPostScript.cxx b/graf2d/postscript/src/TPostScript.cxx index 6406c86efcfce..a83316073e693 100644 --- a/graf2d/postscript/src/TPostScript.cxx +++ b/graf2d/postscript/src/TPostScript.cxx @@ -1,5 +1,5 @@ // @(#)root/postscript:$Id$ -// Author: Rene Brun, Olivier Couet, Pierre Juillot, Oleksandr Grebenyuk +// Author: Rene Brun, Olivier Couet, Pierre Juillot, Oleksandr Grebenyuk, Yue Shi Lai /************************************************************************* * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * @@ -237,8 +237,10 @@ End_Html */ #include #include #include +#include #include "Riostream.h" +#include "Byteswap.h" #include "TROOT.h" #include "TColor.h" #include "TVirtualPad.h" @@ -248,6 +250,9 @@ End_Html */ #include "TMath.h" #include "TText.h" #include "TSystem.h" +#include "TEnv.h" + +#include "fontembed.h" // to scale fonts to the same size as the old TT version const Float_t kScale = 0.93376068; @@ -318,7 +323,10 @@ TPostScript::TPostScript() : TVirtualPS() fYVS2 = 0.; fYsize = 0.; fZone = kFALSE; + fFileName = ""; + fFontEmbed = kFALSE; for (Int_t i=0; i<32; i++) fPatterns[i]=0; + SetTitle("PS"); } @@ -338,6 +346,7 @@ TPostScript::TPostScript(const char *fname, Int_t wtype) // 113 eps fStream = 0; + SetTitle("PS"); Open(fname, wtype); } @@ -362,6 +371,7 @@ void TPostScript::Open(const char *fname, Int_t wtype) fClear = kTRUE; fZone = kFALSE; fSave = 0; + fFontEmbed = kFALSE; SetLineScale(gStyle->GetLineScalePS()); gStyle->GetPaperSize(fXsize, fYsize); fMode = fType%10; @@ -386,10 +396,11 @@ void TPostScript::Open(const char *fname, Int_t wtype) fXsize = xrange; fYsize = yrange; } - // open OS file - fStream = new ofstream(fname,ios::out); - if (fStream == 0 || gSystem->AccessPathName(fname,kWritePermission)) { - printf("ERROR in TPostScript::Open: Cannot open file:%s\n",fname); + // Open OS file + fFileName = fname; + fStream = new std::ofstream(fFileName.Data(),std::ios::out); + if (fStream == 0 || gSystem->AccessPathName(fFileName.Data(),kWritePermission)) { + printf("ERROR in TPostScript::Open: Cannot open file:%s\n",fFileName.Data()); return; } gVirtualPS = this; @@ -450,6 +461,8 @@ void TPostScript::Close(Option_t *) PrintStr("@"); PrintStr("%%EOF@"); + fFontEmbed = kFALSE; + // Close file stream if (fStream) { fStream->close(); delete fStream; fStream = 0;} @@ -1390,6 +1403,206 @@ void TPostScript::DrawHatch(Float_t, Float_t, Int_t, Double_t *, Double_t *) } +//______________________________________________________________________________ +Bool_t TPostScript::FontEmbedType1(const char *filename) +{ + std::ifstream font_file(filename, std::ios::binary); + + // We cannot read directly using iostream iterators due to + // signedness + font_file.seekg(0, std::ios::end); + + const size_t font_file_length = font_file.tellg(); + + font_file.seekg(0, std::ios::beg); + + std::vector font_data(font_file_length, '\0'); + + font_file.read(reinterpret_cast(&font_data[0]), + font_file_length); + + std::string font_name; + std::string postscript_string = + mathtext::font_embed_postscript_t::font_embed_type_1( + font_name, font_data); + + if (!postscript_string.empty()) { + PrintRaw(postscript_string.size(), postscript_string.data()); + PrintStr("@"); + + return true; + } + + return false; +} + + +//______________________________________________________________________________ +Bool_t TPostScript::FontEmbedType2(const char *filename) +{ + std::ifstream font_file(filename, std::ios::binary); + + // We cannot read directly using iostream iterators due to + // signedness + font_file.seekg(0, std::ios::end); + + const size_t font_file_length = font_file.tellg(); + + font_file.seekg(0, std::ios::beg); + + std::vector font_data(font_file_length, '\0'); + + font_file.read(reinterpret_cast(&font_data[0]), + font_file_length); + + std::string font_name; + std::string postscript_string = + mathtext::font_embed_postscript_t::font_embed_type_2( + font_name, font_data); + + if (!postscript_string.empty()) { + PrintRaw(postscript_string.size(), postscript_string.data()); + PrintStr("@"); + + return true; + } + + return false; +} + + +//______________________________________________________________________________ +Bool_t TPostScript::FontEmbedType42(const char *filename) +{ + std::ifstream font_file(filename, std::ios::binary); + + // We cannot read directly using iostream iterators due to + // signedness + font_file.seekg(0, std::ios::end); + + const size_t font_file_length = font_file.tellg(); + + font_file.seekg(0, std::ios::beg); + + std::vector font_data(font_file_length, '\0'); + + font_file.read(reinterpret_cast(&font_data[0]), + font_file_length); + + std::string font_name; + std::string postscript_string = + mathtext::font_embed_postscript_t::font_embed_type_42( + font_name, font_data); + + if (!postscript_string.empty()) { + PrintRaw(postscript_string.size(), postscript_string.data()); + PrintStr("@"); + + return true; + } + fprintf(stderr, "%s:%d:\n", __FILE__, __LINE__); + + return false; +} + + +//______________________________________________________________________________ +void TPostScript::FontEmbed(void) +{ + // Embed font in PS file. + + static const char *fonttable[32][2] = { + { "Root.TTFont.0", "FreeSansBold.otf" }, + { "Root.TTFont.1", "FreeSerifItalic.otf" }, + { "Root.TTFont.2", "FreeSerifBold.otf" }, + { "Root.TTFont.3", "FreeSerifBoldItalic.otf" }, + { "Root.TTFont.4", "FreeSans.otf" }, + { "Root.TTFont.5", "FreeSansOblique.otf" }, + { "Root.TTFont.6", "FreeSansBold.otf" }, + { "Root.TTFont.7", "FreeSansBoldOblique.otf" }, + { "Root.TTFont.8", "FreeMono.otf" }, + { "Root.TTFont.9", "FreeMonoOblique.otf" }, + { "Root.TTFont.10", "FreeMonoBold.otf" }, + { "Root.TTFont.11", "FreeMonoBoldOblique.otf" }, + { "Root.TTFont.12", "symbol.ttf" }, + { "Root.TTFont.13", "FreeSerif.otf" }, + { "Root.TTFont.14", "wingding.ttf" }, + { "Root.TTFont.15", "symbol.ttf" }, + { "Root.TTFont.STIXGen", "STIXGeneral.otf" }, + { "Root.TTFont.STIXGenIt", "STIXGeneralItalic.otf" }, + { "Root.TTFont.STIXGenBd", "STIXGeneralBol.otf" }, + { "Root.TTFont.STIXGenBdIt", "STIXGeneralBolIta.otf" }, + { "Root.TTFont.STIXSiz1Sym", "STIXSiz1Sym.otf" }, + { "Root.TTFont.STIXSiz1SymBd", "STIXSiz1SymBol.otf" }, + { "Root.TTFont.STIXSiz2Sym", "STIXSiz2Sym.otf" }, + { "Root.TTFont.STIXSiz2SymBd", "STIXSiz2SymBol.otf" }, + { "Root.TTFont.STIXSiz3Sym", "STIXSiz3Sym.otf" }, + { "Root.TTFont.STIXSiz3SymBd", "STIXSiz3SymBol.otf" }, + { "Root.TTFont.STIXSiz4Sym", "STIXSiz4Sym.otf" }, + { "Root.TTFont.STIXSiz4SymBd", "STIXSiz4SymBol.otf" }, + { "Root.TTFont.STIXSiz5Sym", "STIXSiz5Sym.otf" }, + { "Root.TTFont.ME", "DroidSansFallback.ttf" }, + { "Root.TTFont.CJKMing", "DroidSansFallback.ttf" }, + { "Root.TTFont.CJKCothic", "DroidSansFallback.ttf" } + }; + + PrintStr("%%IncludeResource: ProcSet (FontSetInit)@"); + + // try to load font (font must be in Root.TTFontPath resource) + const char *ttpath = gEnv->GetValue("Root.TTFontPath", +#ifdef TTFFONTDIR + TTFFONTDIR +#else // TTFFONTDIR + "$(ROOTSYS)/fonts" +#endif // TTFFONTDIR + ); + + for (Int_t fontid = 1; fontid < 30; fontid++) { + if (fontid != 15) { + const char *filename = gEnv->GetValue( + fonttable[fontid][0], fonttable[fontid][1]); + char *ttfont = gSystem->Which(ttpath, filename, + kReadPermission); + + if(!ttfont) { + Error("TPostScript::FontEmbed", + "font %d (filename `%s') not found in path", + fontid, filename); + } else { + if (FontEmbedType2(ttfont)) { + // nothing + } else if(FontEmbedType1(ttfont)) { + // nothing + } else if(FontEmbedType42(ttfont)) { + // nothing + } else { + Error("TPostScript::FontEmbed", + "failed to embed font %d (filename `%s')", + fontid, filename); + } + delete [] ttfont; + } + } + } + PrintStr("%%IncludeResource: font Times-Roman@"); + PrintStr("%%IncludeResource: font Times-Italic@"); + PrintStr("%%IncludeResource: font Times-Bold@"); + PrintStr("%%IncludeResource: font Times-BoldItalic@"); + PrintStr("%%IncludeResource: font Helvetica@"); + PrintStr("%%IncludeResource: font Helvetica-Oblique@"); + PrintStr("%%IncludeResource: font Helvetica-Bold@"); + PrintStr("%%IncludeResource: font Helvetica-BoldOblique@"); + PrintStr("%%IncludeResource: font Courier@"); + PrintStr("%%IncludeResource: font Courier-Oblique@"); + PrintStr("%%IncludeResource: font Courier-Bold@"); + PrintStr("%%IncludeResource: font Courier-BoldOblique@"); + PrintStr("%%IncludeResource: font Symbol@"); + PrintStr("%%IncludeResource: font ZapfDingbats@"); + + fFontEmbed = kTRUE; +} + + //______________________________________________________________________________ void TPostScript::FontEncode() { @@ -1580,6 +1793,7 @@ void TPostScript::Initialize() PrintStr("/ita {/ang 15 def gsave [1 0 ang dup sin exch cos div 1 0 0] concat} def @"); DefineMarkers(); + FontEncode(); // mode=1 for portrait black/white @@ -2349,12 +2563,39 @@ void TPostScript::Text(Double_t xx, Double_t yy, const char *chars) // This routine writes the string chars into a PostScript file // at position xx,yy in world coordinates. - static const char *psfont[] = { - "/Times-Italic" , "/Times-Bold" , "/Times-BoldItalic", - "/Helvetica" , "/Helvetica-Oblique" , "/Helvetica-Bold" , - "/Helvetica-BoldOblique", "/Courier" , "/Courier-Oblique" , - "/Courier-Bold" , "/Courier-BoldOblique", "/Symbol" , - "/Times-Roman" , "/ZapfDingbats" , "/Symbol"}; + static const char *psfont[31][2] = { + { "Root.PSFont.1", "/Times-Italic" }, + { "Root.PSFont.2", "/Times-Bold" }, + { "Root.PSFont.3", "/Times-BoldItalic" }, + { "Root.PSFont.4", "/Helvetica" }, + { "Root.PSFont.5", "/Helvetica-Oblique" }, + { "Root.PSFont.6", "/Helvetica-Bold" }, + { "Root.PSFont.7", "/Helvetica-BoldOblique" }, + { "Root.PSFont.8", "/Courrier" }, + { "Root.PSFont.9", "/Courrier-Oblique" }, + { "Root.PSFont.10", "/Courrier-Bold" }, + { "Root.PSFont.11", "/Courrier-BoldOblique" }, + { "Root.PSFont.12", "/Symbol" }, + { "Root.PSFont.13", "/Times-Roman" }, + { "Root.PSFont.14", "/ZapfDingbats" }, + { "Root.PSFont.15", "/Symbol" }, + { "Root.PSFont.STIXGen", "/STIXGeneral" }, + { "Root.PSFont.STIXGenIt", "/STIXGeneral-Italic" }, + { "Root.PSFont.STIXGenBd", "/STIXGeneral-Bold" }, + { "Root.PSFont.STIXGenBdIt", "/STIXGeneral-BoldItalic" }, + { "Root.PSFont.STIXSiz1Sym", "/STIXSize1Symbols" }, + { "Root.PSFont.STIXSiz1SymBd", "/STIXSize1Symbols-Bold" }, + { "Root.PSFont.STIXSiz2Sym", "/STIXSize2Symbols" }, + { "Root.PSFont.STIXSiz2SymBd", "/STIXSize2Symbols-Bold" }, + { "Root.PSFont.STIXSiz3Sym", "/STIXSize3Symbols" }, + { "Root.PSFont.STIXSiz3SymBd", "/STIXSize3Symbols-Bold" }, + { "Root.PSFont.STIXSiz4Sym", "/STIXSize4Symbols" }, + { "Root.PSFont.STIXSiz4SymBd", "/STIXSize4Symbols-Bold" }, + { "Root.PSFont.STIXSiz5Sym", "/STIXSize5Symbols" }, + { "Root.PSFont.ME", "/DroidSansFallback" }, + { "Root.PSFont.CJKMing", "/DroidSansFallback" }, + { "Root.PSFont.CJKGothic", "/DroidSansFallback" } + }; const Double_t kDEGRAD = TMath::Pi()/180.; Double_t x = xx; @@ -2384,7 +2625,7 @@ void TPostScript::Text(Double_t xx, Double_t yy, const char *chars) Float_t tsizey = gPad->AbsPixeltoY(0)-gPad->AbsPixeltoY(Int_t(tsize)); Int_t font = abs(fTextFont)/10; - if( font > 15 || font < 1) font = 1; + if( font > 31 || font < 1) font = 1; // Text color. SetColor(Int_t(fTextColor)); @@ -2467,7 +2708,7 @@ void TPostScript::Text(Double_t xx, Double_t yy, const char *chars) PrintStr(Form(" t %d r ", psangle)); if(txalh == 2) PrintStr(Form(" %d 0 t ", -psCharsLength/2)); if(txalh == 3) PrintStr(Form(" %d 0 t ", -psCharsLength)); - PrintStr(psfont[font-1]); + PrintStr(gEnv->GetValue(psfont[font-1][0], psfont[font-1][1])); if (font != 15) { PrintStr(Form(" findfont %g sf 0 0 m ",fontsize)); } else { @@ -2520,6 +2761,209 @@ void TPostScript::Text(Double_t xx, Double_t yy, const char *chars) } +//______________________________________________________________________________ +void TPostScript::Text(Double_t xx, Double_t yy, const wchar_t *chars) +{ + // Write a string of characters + // + // This routine writes the string chars into a PostScript file + // at position xx,yy in world coordinates. + + static const char *psfont[31][2] = { + { "Root.PSFont.1", "/FreeSerifItalic" }, + { "Root.PSFont.2", "/FreeSerifBold" }, + { "Root.PSFont.3", "/FreeSerifBoldItalic" }, + { "Root.PSFont.4", "/FreeSans" }, + { "Root.PSFont.5", "/FreeSansOblique" }, + { "Root.PSFont.6", "/FreeSansBold" }, + { "Root.PSFont.7", "/FreeSansBoldOblique" }, + { "Root.PSFont.8", "/FreeMono" }, + { "Root.PSFont.9", "/FreeMonoOblique" }, + { "Root.PSFont.10", "/FreeMonoBold" }, + { "Root.PSFont.11", "/FreeMonoBoldOblique" }, + { "Root.PSFont.12", "/SymbolMT" }, + { "Root.PSFont.13", "/FreeSerif" }, + { "Root.PSFont.14", "/Wingdings-Regular" }, + { "Root.PSFont.15", "/SymbolMT" }, + { "Root.PSFont.STIXGen", "/STIXGeneral" }, + { "Root.PSFont.STIXGenIt", "/STIXGeneral-Italic" }, + { "Root.PSFont.STIXGenBd", "/STIXGeneral-Bold" }, + { "Root.PSFont.STIXGenBdIt", "/STIXGeneral-BoldItalic" }, + { "Root.PSFont.STIXSiz1Sym", "/STIXSize1Symbols" }, + { "Root.PSFont.STIXSiz1SymBd", "/STIXSize1Symbols-Bold" }, + { "Root.PSFont.STIXSiz2Sym", "/STIXSize2Symbols" }, + { "Root.PSFont.STIXSiz2SymBd", "/STIXSize2Symbols-Bold" }, + { "Root.PSFont.STIXSiz3Sym", "/STIXSize3Symbols" }, + { "Root.PSFont.STIXSiz3SymBd", "/STIXSize3Symbols-Bold" }, + { "Root.PSFont.STIXSiz4Sym", "/STIXSize4Symbols" }, + { "Root.PSFont.STIXSiz4SymBd", "/STIXSize4Symbols-Bold" }, + { "Root.PSFont.STIXSiz5Sym", "/STIXSize5Symbols" }, + { "Root.PSFont.ME", "/DroidSansFallback" }, + { "Root.PSFont.CJKMing", "/DroidSansFallback" }, + { "Root.PSFont.CJKGothic", "/DroidSansFallback" } + }; + + Int_t len = wcslen(chars); + if (len<=0) return; + + const Double_t kDEGRAD = TMath::Pi()/180.; + Double_t x = xx; + Double_t y = yy; + if (!gPad) return; + + if (!fFontEmbed) { + // Close the the file fFileName + if (fStream) { + PrintStr("@"); + fStream->close(); delete fStream; fStream = 0; + } + + // Rename the file fFileName + TString tmpname = Form("%s_tmp_%d",fFileName.Data(),gSystem->GetPid()); + if (gSystem->Rename( fFileName.Data() , tmpname.Data())) { + Error("Text", "Cannot open temporary file: %s\n", tmpname.Data()); + return; + } + + // Reopen the file fFileName + fStream = new std::ofstream(fFileName.Data(),std::ios::out); + if (fStream == 0 || gSystem->AccessPathName(fFileName.Data(),kWritePermission)) { + Error("Text", "Cannot open file: %s\n", fFileName.Data()); + return; + } + + // Embed the fonts at the right place + FILE *sg = fopen(tmpname.Data(),"r"); + char line[255]; + while (fgets(line,255,sg)) { + if (strstr(line,"EndComments")) PrintStr("%%DocumentNeededResources: ProcSet (FontSetInit)@"); + fStream->write(line,strlen(line)); + if (!fFontEmbed && strstr(line,"m5")) { + FontEmbed(); + PrintStr("@"); + } + } + fclose(sg); + if (gSystem->Unlink(tmpname.Data())) return; + } + + // Compute the font size. Exit if it is 0 + // The font size is computed from the TTF size to get exactly the same + // size on the screen and in the PostScript file. + Double_t wh = (Double_t)gPad->XtoPixel(gPad->GetX2()); + Double_t hh = (Double_t)gPad->YtoPixel(gPad->GetY1()); + Float_t tsize, ftsize; + + if (wh < hh) { + tsize = fTextSize*wh; + Int_t sizeTTF = (Int_t)(tsize*kScale+0.5); // TTF size + ftsize = (sizeTTF*fXsize*gPad->GetAbsWNDC())/wh; + } else { + tsize = fTextSize*hh; + Int_t sizeTTF = (Int_t)(tsize*kScale+0.5); // TTF size + ftsize = (sizeTTF*fYsize*gPad->GetAbsHNDC())/hh; + } + Double_t fontsize = 4*(72*(ftsize)/2.54); + if( fontsize <= 0) return; + + Float_t tsizex = gPad->AbsPixeltoX(Int_t(tsize))-gPad->AbsPixeltoX(0); + Float_t tsizey = gPad->AbsPixeltoY(0)-gPad->AbsPixeltoY(Int_t(tsize)); + + Int_t font = abs(fTextFont)/10; + if( font > 29 || font < 1) font = 1; + + // Text color. + SetColor(Int_t(fTextColor)); + + // Text alignment. + Int_t txalh = fTextAlign/10; + if (txalh <1) txalh = 1; if (txalh > 3) txalh = 3; + Int_t txalv = fTextAlign%10; + if (txalv <1) txalv = 1; if (txalv > 3) txalv = 3; + if (txalv == 3) { + y -= 0.8*tsizey*TMath::Cos(kDEGRAD*fTextAngle); + x += 0.8*tsizex*TMath::Sin(kDEGRAD*fTextAngle); + } else if (txalv == 2) { + y -= 0.4*tsizey*TMath::Cos(kDEGRAD*fTextAngle); + x += 0.4*tsizex*TMath::Sin(kDEGRAD*fTextAngle); + } + UInt_t w = 0, h = 0; + + TText t; + t.SetTextSize(fTextSize); + t.SetTextFont(fTextFont); + t.GetTextExtent(w, h, chars); + Double_t charsLength = gPad->AbsPixeltoX(w)-gPad->AbsPixeltoX(0); + Int_t psCharsLength = XtoPS(charsLength)-XtoPS(0); + + // Text angle. + Int_t psangle = Int_t(0.5 + fTextAngle); + + // Save context. + PrintStr("@"); + SaveRestore(1); + + // Clipping + Int_t xc1 = XtoPS(gPad->GetX1()); + Int_t xc2 = XtoPS(gPad->GetX2()); + Int_t yc1 = YtoPS(gPad->GetY1()); + Int_t yc2 = YtoPS(gPad->GetY2()); + WriteInteger(xc2 - xc1); + WriteInteger(yc2 - yc1); + WriteInteger(xc1); + WriteInteger(yc1); + PrintStr(" C"); + + // Output text position and angle. + WriteInteger(XtoPS(x)); + WriteInteger(YtoPS(y)); + PrintStr(Form(" t %d r ", psangle)); + if(txalh == 2) PrintStr(Form(" %d 0 t ", -psCharsLength/2)); + if(txalh == 3) PrintStr(Form(" %d 0 t ", -psCharsLength)); + PrintStr(gEnv->GetValue(psfont[font-1][0], psfont[font-1][1])); + PrintStr(Form(" findfont %g sf 0 0 m ",fontsize)); + PrintStr("@"); + + // Output text. + if (len > 1) PrintStr(Form("%d ", len)); + for(Int_t i = 0; i < len; i++) { + // Adobe Glyph Naming Convention + // http://www.adobe.com/devnet/opentype/archives/glyph.html +#include "AdobeGlyphList.h" + const wchar_t *lower = std::lower_bound( + adobe_glyph_ucs, adobe_glyph_ucs + nadobe_glyph, + chars[i]); + if(lower < adobe_glyph_ucs + nadobe_glyph && + *lower == chars[i]) { + // Named glyph from AGL 1.2 + const unsigned long index = + lower - adobe_glyph_ucs; + PrintStr(Form("/%s ", adobe_glyph_name[index])); + } + else if((unsigned int)chars[i] < 0xffff) { + // Unicode BMP + PrintStr(Form("/uni%04X ", + (unsigned int)chars[i])); + } + else { + // Unicode supplemental planes + PrintStr(Form("/u%04X ", + (unsigned int)chars[i])); + } + } + if(len > 1) { + PrintStr("{glyphshow} repeat "); + } + else { + PrintStr("glyphshow "); + } + + PrintStr("NC"); + + SaveRestore(-1); +} + + //______________________________________________________________________________ void TPostScript::TextNDC(Double_t u, Double_t v, const char *chars) { @@ -2531,6 +2975,17 @@ void TPostScript::TextNDC(Double_t u, Double_t v, const char *chars) } +//______________________________________________________________________________ +void TPostScript::TextNDC(Double_t u, Double_t v, const wchar_t *chars) +{ + // Write a string of characters in NDC + + Double_t x = gPad->GetX1() + u*(gPad->GetX2() - gPad->GetX1()); + Double_t y = gPad->GetY1() + v*(gPad->GetY2() - gPad->GetY1()); + Text(x, y, chars); +} + + //______________________________________________________________________________ Int_t TPostScript::UtoPS(Double_t u) { diff --git a/graf2d/postscript/src/TSVG.cxx b/graf2d/postscript/src/TSVG.cxx index 9b8ba616367c9..96d6367b58437 100644 --- a/graf2d/postscript/src/TSVG.cxx +++ b/graf2d/postscript/src/TSVG.cxx @@ -132,7 +132,7 @@ void TSVG::Open(const char *fname, Int_t wtype) } // Open OS file - fStream = new ofstream(fname,ios::out); + fStream = new std::ofstream(fname,ios::out); if (fStream == 0 || !fStream->good()) { printf("ERROR in TSVG::Open: Cannot open file:%s\n",fname); if (fStream == 0) return; @@ -1143,7 +1143,7 @@ void TSVG::DrawPS(Int_t nn, Double_t *xw, Double_t *yw) //______________________________________________________________________________ void TSVG::Initialize() { - // Initialize the SVG file. The main task of the function is to ouput the + // Initialize the SVG file. The main task of the function is to output the // SVG header file which consist in , <desc> and <defs>. The // HeaderPS provided by the user program is written in the <defs> part. @@ -1202,7 +1202,7 @@ void TSVG::MovePS(Int_t ix, Int_t iy) void TSVG::NewPage() { // Start the SVG page. This function initialize the pad conversion - // coefficients and ouput the <svg> directive which is close later in the + // coefficients and output the <svg> directive which is close later in the // the function Close. // Compute pad conversion coefficients @@ -1427,13 +1427,13 @@ void TSVG::Text(Double_t xx, Double_t yy, const char *chars) Float_t ftsize; Int_t font = abs(fTextFont)/10; - Int_t ifont = font-1; if (font > 42 || font < 1) font = 1; if (wh < hh) { ftsize = fTextSize*fXsize*gPad->GetAbsWNDC(); } else { ftsize = fTextSize*fYsize*gPad->GetAbsHNDC(); } + Int_t ifont = font-1; Int_t fontsize = CMtoSVG(ftsize/fontrap); if( fontsize <= 0) return; @@ -1502,6 +1502,7 @@ void TSVG::Text(Double_t xx, Double_t yy, const char *chars) if (ic == 834) ichar = 8747; if (ic == 769) ichar = 177; if (ic == 772) ichar = 215; + if (ic == 768) ichar = 176; // Greek characters if (ic == 918) ichar = 934; diff --git a/graf2d/postscript/src/TTeXDump.cxx b/graf2d/postscript/src/TTeXDump.cxx new file mode 100644 index 0000000000000..f339e9a6f8eea --- /dev/null +++ b/graf2d/postscript/src/TTeXDump.cxx @@ -0,0 +1,929 @@ +// @(#)root/postscript:$Id$ +// Author: Olivier Couet + +/************************************************************************* + * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifdef WIN32 +#pragma optimize("",off) +#endif + +#include <stdlib.h> +#include <string.h> +#include <ctype.h> + +#include "Riostream.h" +#include "TROOT.h" +#include "TColor.h" +#include "TVirtualPad.h" +#include "TPoints.h" +#include "TTeXDump.h" +#include "TStyle.h" +#include "TMath.h" +#include "TObjString.h" +#include "TObjArray.h" +#include "TClass.h" + +ClassImp(TTeXDump) + + +//______________________________________________________________________________ +/*Begin_Html +<center><h2>TTeXDump: Graphics interface to TeX</h2></center> +This class allow to generate <b>PGF/TikZ</b> vector graphics output +which can be included in TeX and LaTeX documents. +<p> +PGF is a TeX macro package for generating graphics. It is platform +and format-independent and works together with the most important TeX +backend drivers, including pdftex and dvips. It comes with a +user-friendly syntax layer called TikZ. +<p> +To generate a such file it is enough to do: +<pre> + gStyle->SetPaperSize(10.,10.); + hpx->Draw(); + gPad->Print("hpx.tex"); +</pre> + +<p>Then, the generated file (<tt>hpx.tex</tt>) can be included in a +LaTeX document (<tt>simple.tex</tt>) in the following way: +<pre> +\documentclass{article} +\usepackage{tikz} +\usetikzlibrary{patterns} +\usetikzlibrary{plotmarks} +\title{A simple LaTeX example} +\date{July 2013} +\begin{document} +\maketitle +The following image as been generated using the TTeXDump class: +\par +\input{hpx.tex} +\end{document} +</pre> + +Note the three directives needed at the top of the LaTeX file: +<pre> +\usepackage{tikz} +\usetikzlibrary{patterns} +\usetikzlibrary{plotmarks} +</pre> + +Then including the picture in the document is done with the +<tt>\input<\tt> directive. + +<p> The command <tt>pdflatex simple.tex</tt> will generate the +corresponding pdf file <tt>simple.pdf</tt>. + +End_Html */ + + +//______________________________________________________________________________ +TTeXDump::TTeXDump() : TVirtualPS() +{ + // Default TeX constructor + + fStream = 0; + fType = 0; + gVirtualPS = this; + fBoundingBox = kFALSE; + fRange = kFALSE; + fXsize = 0.; + fYsize = 0.; + fCurrentRed = 0.; + fCurrentGreen = 0.; + fCurrentBlue = 0.; +} + + +//______________________________________________________________________________ +TTeXDump::TTeXDump(const char *fname, Int_t wtype) : TVirtualPS(fname, wtype) +{ + // Initialize the TeX interface + // + // fname : TeX file name + // wtype : TeX workstation type. Not used in the TeX driver. But as TTeXDump + // inherits from TVirtualPS it should be kept. Anyway it is not + // necessary to specify this parameter at creation time because it + // has a default value (which is ignore in the TeX case). + + fStream = 0; + fType = 0; + gVirtualPS = this; + fBoundingBox = kFALSE; + fRange = kFALSE; + fXsize = 0.; + fYsize = 0.; + fCurrentRed = 0.; + fCurrentGreen = 0.; + fCurrentBlue = 0.; + + Open(fname, wtype); +} + + +//______________________________________________________________________________ +void TTeXDump::Open(const char *fname, Int_t wtype) +{ + // Open a TeX file + + if (fStream) { + Warning("Open", "TeX file already open"); + return; + } + + fLenBuffer = 0; + fType = abs(wtype); + + gStyle->GetPaperSize(fXsize, fYsize); + + Float_t xrange, yrange; + if (gPad) { + Double_t ww = gPad->GetWw(); + Double_t wh = gPad->GetWh(); + ww *= gPad->GetWNDC(); + wh *= gPad->GetHNDC(); + Double_t ratio = wh/ww; + xrange = fXsize; + yrange = fXsize*ratio; + if (yrange > fYsize) { yrange = fYsize; xrange = yrange/ratio;} + fXsize = xrange; fYsize = yrange; + } + + // Open OS file + fStream = new std::ofstream(fname,std::ios::out); + if (fStream == 0 || !fStream->good()) { + printf("ERROR in TTeXDump::Open: Cannot open file:%s\n",fname); + if (fStream == 0) return; + } + + gVirtualPS = this; + + for (Int_t i=0;i<fSizBuffer;i++) fBuffer[i] = ' '; + + fBoundingBox = kFALSE; + fRange = kFALSE; + + // Set a default range + Range(fXsize, fYsize); + + NewPage(); +} + + +//______________________________________________________________________________ +TTeXDump::~TTeXDump() +{ + // Default TeX destructor + + Close(); +} + + +//______________________________________________________________________________ +void TTeXDump::Close(Option_t *) +{ + // Close a TeX file + + if (!gVirtualPS) return; + if (!fStream) return; + if (gPad) gPad->Update(); + PrintStr("@"); + PrintStr("\\end{tikzpicture}@"); + + // Close file stream + if (fStream) { fStream->close(); delete fStream; fStream = 0;} + + gVirtualPS = 0; +} + + +//______________________________________________________________________________ +void TTeXDump::On() +{ + // Activate an already open TeX file + + // fType is used to know if the TeX file is open. Unlike TPostScript, TTeXDump + // has no "workstation type". In fact there is only one TeX type. + + if (!fType) { + Error("On", "no TeX file open"); + Off(); + return; + } + gVirtualPS = this; +} + + +//______________________________________________________________________________ +void TTeXDump::Off() +{ + // Deactivate an already open TeX file + + gVirtualPS = 0; +} + + +//______________________________________________________________________________ +void TTeXDump::DrawBox(Double_t x1, Double_t y1, Double_t x2, Double_t y2) +{ + // Draw a Box + + Float_t x1c = XtoTeX(x1); + Float_t y1c = YtoTeX(y1); + Float_t x2c = XtoTeX(x2); + Float_t y2c = YtoTeX(y2); + + Int_t fillis = fFillStyle/1000; + Int_t fillsi = fFillStyle%1000; + + if (fillis==1) { + SetColor(fFillColor); + PrintStr("@"); + PrintStr("\\draw [color=c, fill=c] ("); + WriteReal(x1c, kFALSE); + PrintFast(1,","); + WriteReal(y1c, kFALSE); + PrintStr(") rectangle ("); + WriteReal(x2c, kFALSE); + PrintFast(1,","); + WriteReal(y2c, kFALSE); + PrintStr(");"); + } else if (fillis>1) { + SetColor(fFillColor); + PrintStr("@"); + PrintStr("\\draw [pattern="); + if (fillsi==1) PrintStr("crosshatch dots"); + if (fillsi==2) PrintStr("dots"); + if (fillsi==4) PrintStr("north east lines"); + if (fillsi==5) PrintStr("north west lines"); + if (fillsi==6) PrintStr("vertical lines"); + if (fillsi==7) PrintStr("horizontal lines"); + if (fillsi==10) PrintStr("bricks"); + if (fillsi==13) PrintStr("crosshatch"); + PrintStr(", pattern color=c] ("); + WriteReal(x1c, kFALSE); + PrintFast(1,","); + WriteReal(y1c, kFALSE); + PrintStr(") rectangle ("); + WriteReal(x2c, kFALSE); + PrintFast(1,","); + WriteReal(y2c, kFALSE); + PrintStr(");"); + } else { + SetColor(fLineColor); + PrintStr("@"); + PrintStr("\\draw [c] ("); + WriteReal(x1c, kFALSE); + PrintFast(1,","); + WriteReal(y1c, kFALSE); + PrintStr(") -- ("); + WriteReal(x1c, kFALSE); + PrintFast(1,","); + WriteReal(y2c, kFALSE); + PrintStr(") -- ("); + WriteReal(x2c, kFALSE); + PrintFast(1,","); + WriteReal(y2c, kFALSE); + PrintStr(") -- ("); + WriteReal(x2c, kFALSE); + PrintFast(1,","); + WriteReal(y1c, kFALSE); + PrintStr(") -- ("); + WriteReal(x1c, kFALSE); + PrintFast(1,","); + WriteReal(y1c, kFALSE); + PrintStr(");"); + } +} + + +//______________________________________________________________________________ +void TTeXDump::DrawFrame(Double_t, Double_t, Double_t, Double_t, + Int_t, Int_t, Int_t, Int_t) +{ + // Draw a Frame around a box + // + // mode = -1 the box looks as it is behind the screen + // mode = 1 the box looks as it is in front of the screen + // border is the border size in already pre-computed TeX units dark is the + // color for the dark part of the frame light is the color for the light + // part of the frame + + Warning("DrawFrame", "not yet implemented"); +} + + +//______________________________________________________________________________ +void TTeXDump::DrawPolyLine(Int_t, TPoints *) +{ + // Draw a PolyLine + // + // Draw a polyline through the points xy. + // If NN=1 moves only to point x,y. + // If NN=0 the x,y are written in the TeX file + // according to the current transformation. + // If NN>0 the line is clipped as a line. + // If NN<0 the line is clipped as a fill area. + + Warning("DrawPolyLine", "not yet implemented"); +} + + +//______________________________________________________________________________ +void TTeXDump::DrawPolyLineNDC(Int_t, TPoints *) +{ + // Draw a PolyLine in NDC space + // + // Draw a polyline through the points xy. + // If NN=1 moves only to point x,y. + // If NN=0 the x,y are written in the TeX file + // according to the current transformation. + // If NN>0 the line is clipped as a line. + // If NN<0 the line is clipped as a fill area. + + Warning("DrawPolyLineNDC", "not yet implemented"); +} + + +//______________________________________________________________________________ +void TTeXDump::DrawPolyMarker(Int_t, Float_t *, Float_t *) +{ + // Paint PolyMarker + + Warning("DrawPolyMarker", "not yet implemented"); +} + + +//______________________________________________________________________________ +void TTeXDump::DrawPolyMarker(Int_t n, Double_t *xw, Double_t *yw) +{ + // Paint PolyMarker + + Float_t x, y; + + SetColor(fMarkerColor); + + PrintStr("@"); + PrintStr("\\foreach \\P in {"); + + x = XtoTeX(xw[0]); + y = YtoTeX(yw[0]); + + PrintStr("("); + WriteReal(x, kFALSE); + PrintFast(1,","); + WriteReal(y, kFALSE); + PrintStr(")"); + + for (Int_t i=1;i<n;i++) { + x = XtoTeX(xw[i]); + y = YtoTeX(yw[i]); + PrintFast(2,",("); + WriteReal(x, kFALSE); + PrintFast(1,","); + WriteReal(y, kFALSE); + PrintFast(1,")"); + } + + PrintStr("}{\\draw[mark options={color=c,fill=c},mark size="); + PrintStr(Form("%fpt,mark=",8./3.33*fMarkerSize)); + switch (fMarkerStyle) { + case 1 : + PrintStr("*"); + PrintStr(",mark size=1pt"); + break; + case 2 : + PrintStr("+"); + break; + case 3 : + PrintStr("asterisk"); + break; + case 4 : + PrintStr("o"); + break; + case 5 : + PrintStr("x"); + break; + case 20 : + PrintStr("*"); + break; + case 21 : + PrintStr("square*"); + break; + case 22 : + PrintStr("triangle*"); + break; + case 23 : + PrintStr("triangle*"); + PrintStr(",mark options={rotate=180}"); + break; + case 24 : + PrintStr("o"); + break; + case 25 : + PrintStr("square"); + break; + case 26 : + PrintStr("triangle"); + break; + case 27 : + PrintStr("diamond"); + break; + case 28 : + PrintStr("cross"); + break; + case 29 : + PrintStr("newstar*"); + break; + case 30 : + PrintStr("newstar"); + break; + case 31 : + PrintStr("10-pointed star"); + break; + case 32 : + PrintStr("triangle"); + PrintStr(",mark options={rotate=180}"); + break; + case 33 : + PrintStr("diamond*"); + break; + case 34 : + PrintStr("cross*"); + break; + } + PrintStr("] plot coordinates {\\P};}"); +} + + +//______________________________________________________________________________ +void TTeXDump::DrawPS(Int_t nn, Double_t *xw, Double_t *yw) +{ + // This function defines a path with xw and yw and draw it according the + // value of nn: + // + // If nn>0 a line is drawn. + // If nn<0 a closed polygon is drawn. + + Int_t n = TMath::Abs(nn);; + Float_t x, y; + + if( n <= 1) { + Error("DrawPS", "Two points are needed"); + return; + } + + x = XtoTeX(xw[0]); + y = YtoTeX(yw[0]); + + Int_t fillis = fFillStyle/1000; + Int_t fillsi = fFillStyle%1000; + + if (nn>0) { + SetColor(fLineColor); + PrintStr("@"); + PrintStr("\\draw [c"); + switch(fLineStyle) { + case 1: + break; + case 2: + PrintStr(",dashed"); + break; + case 3: + PrintStr(",dotted"); + break; + case 4: + PrintStr(",dash pattern=on 2.4pt off 3.2pt on 0.8pt off 3.2pt"); + break; + case 5: + PrintStr(",dash pattern=on 4pt off 2.4pt on 0.8pt off 2.4pt"); + break; + case 6: + PrintStr(",dash pattern=on 4pt off 2.4pt on 0.8pt off 2.4pt on 0.8pt off 2.4pt on 0.8pt off 2.4pt"); + break; + case 7: + PrintStr(",dash pattern=on 4pt off 4pt"); + break; + case 8: + PrintStr(",dash pattern=on 4pt off 2.4pt on 0.8pt off 2.4pt on 0.8pt off 2.4pt"); + break; + case 9: + PrintStr(",dash pattern=on 16pt off 4pt"); + break; + case 10: + PrintStr(",dash pattern=on 16pt off 8pt on 0.8pt off 8pt"); + break; + } + if (fLineWidth>1) { + PrintStr(",line width="); + WriteReal(fLineWidth*0.2, kFALSE); + } + } else { + SetColor(fFillColor); + if (fillis==1) { + PrintStr("@"); + PrintStr("\\draw [c, fill=c"); + } else { + PrintStr("\\draw [pattern="); + if (fillsi==1) PrintStr("crosshatch dots"); + if (fillsi==2) PrintStr("dots"); + if (fillsi==4) PrintStr("north east lines"); + if (fillsi==5) PrintStr("north west lines"); + if (fillsi==6) PrintStr("vertical lines"); + if (fillsi==7) PrintStr("horizontal lines"); + if (fillsi==10) PrintStr("bricks"); + if (fillsi==13) PrintStr("crosshatch"); + PrintStr(", pattern color=c"); + } + } + + PrintStr("] ("); + WriteReal(x, kFALSE); + PrintFast(1,","); + WriteReal(y, kFALSE); + PrintStr(") -- "); + + for (Int_t i=1;i<n;i++) { + x = XtoTeX(xw[i]); + y = YtoTeX(yw[i]); + PrintFast(1,"("); + WriteReal(x, kFALSE); + PrintFast(1,","); + WriteReal(y, kFALSE); + PrintFast(1,")"); + if (i<n-1) PrintStr(" -- "); + else PrintStr(";@"); + } +} + + +//______________________________________________________________________________ +void TTeXDump::NewPage() +{ + // Start the TeX page. This function starts the tikzpicture environment + + // Compute pad conversion coefficients + if (gPad) { + Double_t ww = gPad->GetWw(); + Double_t wh = gPad->GetWh(); + fYsize = fXsize*wh/ww; + } else { + fYsize = 27; + } + + if(!fBoundingBox) { + DefineMarkers(); + PrintStr("\\begin{tikzpicture}@"); + /* + PrintStr("\\draw[help lines] (0,0) grid ("); + WriteReal(fXsize, kFALSE); + PrintStr(","); + WriteReal(fYsize, kFALSE); + PrintStr(");@"); + */ + fBoundingBox = kTRUE; + } +} + + +//______________________________________________________________________________ +void TTeXDump::Range(Float_t xsize, Float_t ysize) +{ + // Set the range for the paper in centimetres + + fXsize = xsize; + fYsize = ysize; + + fRange = kTRUE; +} + + +//______________________________________________________________________________ +void TTeXDump::SetFillColor( Color_t cindex ) +{ + // Set color index for fill areas + + fFillColor = cindex; + if (gStyle->GetFillColor() <= 0) cindex = 0; +} + + +//______________________________________________________________________________ +void TTeXDump::SetLineColor( Color_t cindex ) +{ + // Set color index for lines + + fLineColor = cindex; +} + + +//______________________________________________________________________________ +void TTeXDump::SetLineStyle(Style_t linestyle) +{ + // Change the line style + // + // linestyle = 2 dashed + // = 3 dotted + // = 4 dash-dotted + // = else solid (1 in is used most of the time) + + fLineStyle = linestyle; +} + + +//______________________________________________________________________________ +void TTeXDump::SetLineWidth(Width_t linewidth) +{ + // Set the lines width. + + fLineWidth = linewidth; +} + +//______________________________________________________________________________ +void TTeXDump::SetMarkerSize( Size_t msize) +{ + // Set size for markers. + + fMarkerSize = msize; +} + + +//______________________________________________________________________________ +void TTeXDump::SetMarkerColor( Color_t cindex) +{ + // Set color index for markers. + + fMarkerColor = cindex; +} + + +//______________________________________________________________________________ +void TTeXDump::SetColor(Int_t color) +{ + // Set color with its color index + + if (color < 0) color = 0; + + TColor *col = gROOT->GetColor(color); + if (col) SetColor(col->GetRed(), col->GetGreen(), col->GetBlue()); + else SetColor(1., 1., 1.); +} + + +//______________________________________________________________________________ +void TTeXDump::SetColor(Float_t r, Float_t g, Float_t b) +{ + // Set color with its R G B components + // + // r: % of red in [0,1] + // g: % of green in [0,1] + // b: % of blue in [0,1] + + if (fCurrentRed == r && fCurrentGreen == g && fCurrentBlue == b) return; + + fCurrentRed = r; + fCurrentGreen = g; + fCurrentBlue = b; + PrintStr("@"); + PrintStr("\\definecolor{c}{rgb}{"); + WriteReal(r, kFALSE); + PrintFast(1,","); + WriteReal(g, kFALSE); + PrintFast(1,","); + WriteReal(b, kFALSE); + PrintFast(2,"};"); +} + + +//______________________________________________________________________________ +void TTeXDump::SetTextColor( Color_t cindex ) +{ + // Set color index for text + + fTextColor = cindex; +} + + +//______________________________________________________________________________ +void TTeXDump::Text(Double_t x, Double_t y, const char *chars) +{ + // Draw text + // + // xx: x position of the text + // yy: y position of the text + // chars: text to be drawn + + Float_t ftsize; + if (fXsize < fYsize) { + ftsize = fTextSize*fXsize; + } else { + ftsize = fTextSize*fYsize; + } + ftsize *= 2.22097; + + TString t(chars); + if (t.Index("\\")>=0 || t.Index("^")>=0) { + t.Prepend("$"); + t.Append("$"); + } else { + t.ReplaceAll("<","$<$"); + t.ReplaceAll(">","$>$"); + } + t.ReplaceAll("&","\\&"); + t.ReplaceAll("#","\\#"); + + Int_t txalh = fTextAlign/10; + if (txalh <1) txalh = 1; if (txalh > 3) txalh = 3; + Int_t txalv = fTextAlign%10; + if (txalv <1) txalv = 1; if (txalv > 3) txalv = 3; + + PrintStr("@"); + PrintStr("\\draw"); + if (txalh!=2 || txalv!=2) { + PrintStr(" [anchor="); + if (txalv==1) PrintStr("base"); + if (txalv==3) PrintStr("north"); + if (txalh==1) PrintStr(" west"); + if (txalh==3) PrintStr(" east"); + PrintFast(1,"]"); + } + PrintFast(2," ("); + WriteReal(XtoTeX(x), kFALSE); + PrintFast(1,","); + WriteReal(YtoTeX(y), kFALSE); + PrintStr(") node[scale="); + WriteReal(ftsize, kFALSE); + PrintStr(", rotate="); + WriteReal(fTextAngle, kFALSE); + PrintFast(2,"]{"); + PrintStr(t.Data()); + PrintFast(2,"};"); +} + + +//______________________________________________________________________________ +void TTeXDump::TextNDC(Double_t u, Double_t v, const char *chars) +{ + // Write a string of characters in NDC + + Double_t x = gPad->GetX1() + u*(gPad->GetX2() - gPad->GetX1()); + Double_t y = gPad->GetY1() + v*(gPad->GetY2() - gPad->GetY1()); + Text(x, y, chars); +} + + +//______________________________________________________________________________ +Float_t TTeXDump::UtoTeX(Double_t u) +{ + // Convert U from NDC coordinate to TeX + + Double_t cm = fXsize*(gPad->GetAbsXlowNDC() + u*gPad->GetAbsWNDC()); + return cm; +} + + +//______________________________________________________________________________ +Float_t TTeXDump::VtoTeX(Double_t v) +{ + // Convert V from NDC coordinate to TeX + + Double_t cm = fYsize*(gPad->GetAbsYlowNDC() + v*gPad->GetAbsHNDC()); + return cm; +} + + +//______________________________________________________________________________ +Float_t TTeXDump::XtoTeX(Double_t x) +{ + // Convert X from world coordinate to TeX + + Double_t u = (x - gPad->GetX1())/(gPad->GetX2() - gPad->GetX1()); + return UtoTeX(u); +} + + +//______________________________________________________________________________ +Float_t TTeXDump::YtoTeX(Double_t y) +{ + // Convert Y from world coordinate to TeX + + Double_t v = (y - gPad->GetY1())/(gPad->GetY2() - gPad->GetY1()); + return VtoTeX(v); +} + + +//______________________________________________________________________________ +void TTeXDump::CellArrayBegin(Int_t, Int_t, Double_t, Double_t, Double_t, + Double_t) +{ + // Begin the Cell Array painting + + Warning("CellArrayBegin", "not yet implemented"); +} + + +//______________________________________________________________________________ +void TTeXDump::CellArrayFill(Int_t, Int_t, Int_t) +{ + // Paint the Cell Array + + Warning("CellArrayFill", "not yet implemented"); +} + + +//______________________________________________________________________________ +void TTeXDump::CellArrayEnd() +{ + // End the Cell Array painting + + Warning("CellArrayEnd", "not yet implemented"); +} + + +//______________________________________________________________________________ +void TTeXDump::DrawPS(Int_t, Float_t *, Float_t *) +{ + // Not needed in TeX case + + Warning("DrawPS", "not yet implemented"); +} + +//______________________________________________________________________________ +void TTeXDump::DefineMarkers() +{ + // add additional pgfplotmarks + + // open cross + PrintStr("\\pgfdeclareplotmark{cross} {@"); + PrintStr("\\pgfpathmoveto{\\pgfpoint{-0.3\\pgfplotmarksize}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{+0.3\\pgfplotmarksize}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{+0.3\\pgfplotmarksize}{0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{+1\\pgfplotmarksize}{0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{+1\\pgfplotmarksize}{-0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{+0.3\\pgfplotmarksize}{-0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{+0.3\\pgfplotmarksize}{-1.\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{-0.3\\pgfplotmarksize}{-1.\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{-0.3\\pgfplotmarksize}{-0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{-1.\\pgfplotmarksize}{-0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{-1.\\pgfplotmarksize}{0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{-0.3\\pgfplotmarksize}{0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathclose@"); + PrintStr("\\pgfusepathqstroke@"); + PrintStr("}@"); + + // filled cross + PrintStr("\\pgfdeclareplotmark{cross*} {@"); + PrintStr("\\pgfpathmoveto{\\pgfpoint{-0.3\\pgfplotmarksize}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{+0.3\\pgfplotmarksize}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{+0.3\\pgfplotmarksize}{0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{+1\\pgfplotmarksize}{0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{+1\\pgfplotmarksize}{-0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{+0.3\\pgfplotmarksize}{-0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{+0.3\\pgfplotmarksize}{-1.\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{-0.3\\pgfplotmarksize}{-1.\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{-0.3\\pgfplotmarksize}{-0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{-1.\\pgfplotmarksize}{-0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{-1.\\pgfplotmarksize}{0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfpoint{-0.3\\pgfplotmarksize}{0.3\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathclose@"); + PrintStr("\\pgfusepathqfillstroke@"); + PrintStr("}@"); + + // open star + PrintStr("\\pgfdeclareplotmark{newstar} {@"); + PrintStr("\\pgfpathmoveto{\\pgfqpoint{0pt}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{44}{0.5\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{18}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{-20}{0.5\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{-54}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{-90}{0.5\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{234}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{198}{0.5\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{162}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{134}{0.5\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathclose@"); + PrintStr("\\pgfusepathqstroke@"); + PrintStr("}@"); + + // filled star + PrintStr("\\pgfdeclareplotmark{newstar*} {@"); + PrintStr("\\pgfpathmoveto{\\pgfqpoint{0pt}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{44}{0.5\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{18}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{-20}{0.5\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{-54}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{-90}{0.5\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{234}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{198}{0.5\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{162}{\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathlineto{\\pgfqpointpolar{134}{0.5\\pgfplotmarksize}}@"); + PrintStr("\\pgfpathclose@"); + PrintStr("\\pgfusepathqfillstroke@"); + PrintStr("}@"); +} \ No newline at end of file diff --git a/graf2d/qt/Module.mk b/graf2d/qt/Module.mk index 7f7036a627a07..863455aed44e2 100644 --- a/graf2d/qt/Module.mk +++ b/graf2d/qt/Module.mk @@ -148,5 +148,5 @@ lib/qtcint.dll: $(CINTTMP) $(ROOTCINTTMPEXE) cint/cint/lib/qt/qtcint.h \ "$(CINTTMP)" "$(ROOTCINTTMP)" \ "$(MAKELIB)" "$(CXX)" "$(CC)" "$(LD)" "$(OPT)" \ "$(CINTCXXFLAGS) $(GQTCXXFLAGS)" "$(CINTCFLAGS)" \ - "$(LDFLAGS) $(QTLIBDIR) $(QTLIB) $(CINTDLLLIBLINK)" "$(SOFLAGS)" \ + "$(LDFLAGS)" "$(QTLIBDIR) $(QTLIB) $(CINTDLLLIBLINK)" "$(SOFLAGS)" \ "$(SOEXT)" "$(COMPILER)" "$(CXXOUT)" diff --git a/graf2d/qt/inc/TVirtualX.interface.h b/graf2d/qt/inc/TVirtualX.interface.h index 287e7d74314cc..363bc65fb2a37 100644 --- a/graf2d/qt/inc/TVirtualX.interface.h +++ b/graf2d/qt/inc/TVirtualX.interface.h @@ -21,6 +21,14 @@ virtual void ClosePixmap(); virtual void CloseWindow(); virtual void CopyPixmap(Int_t wid, Int_t xpos, Int_t ypos); + + //TVirtualX has two versions of CreateOpenGLContext + using TVirtualX::CreateOpenGLContext; + + //TVirtualX has these two methods with wchar_t + using TVirtualX::DrawText; + using TVirtualX::GetTextExtent;; + virtual void CreateOpenGLContext(Int_t wid=0); virtual void DeleteOpenGLContext(Int_t wid=0); virtual void DrawBox(Int_t x1, Int_t y1, Int_t x2, Int_t y2, EBoxMode mode); diff --git a/graf2d/qt/src/GQtGUI.cxx b/graf2d/qt/src/GQtGUI.cxx index a2fd53ff11fe7..919ea4e0e8689 100644 --- a/graf2d/qt/src/GQtGUI.cxx +++ b/graf2d/qt/src/GQtGUI.cxx @@ -2242,7 +2242,7 @@ void TGQt::DrawString(Drawable_t id, GContext_t gc, Int_t x, Int_t y, //______________________________________________________________________________ Int_t TGQt::TextWidth(FontStruct_t font, const char *s, Int_t len) { - // Return lenght of string in pixels. Size depends on font. + // Return length of string in pixels. Size depends on font. Int_t textWidth = 0; if (len >0 && s && s[0] != 0 ) { diff --git a/graf2d/qt/src/TQtApplication.cxx b/graf2d/qt/src/TQtApplication.cxx index 6ca65f7862ce7..010b121fd01ef 100644 --- a/graf2d/qt/src/TQtApplication.cxx +++ b/graf2d/qt/src/TQtApplication.cxx @@ -83,7 +83,7 @@ void TQtApplication::CreateQApplication(int &argc, char ** argv, bool GUIenabled << "ATTENTION !!! " << "The env variable \"QT_FATAL_WARNIGNS\" was defined. The special debug option has been turned on." << " argc = " << argc << " argv = " << argv[0] << argv[1]; - qDebug() << " You may want to restart ROOT with " << argC << " paramaters :" + qDebug() << " You may want to restart ROOT with " << argC << " parameters :" << " like this: \"" << argV[0] << " " << argV[1]; // new QApplication(argC,argV,GUIenabled); new QApplication(argc,argv,GUIenabled); diff --git a/graf2d/qt/src/TQtTimer.cxx b/graf2d/qt/src/TQtTimer.cxx index 17d1fc1b4318d..35a22bd64c823 100644 --- a/graf2d/qt/src/TQtTimer.cxx +++ b/graf2d/qt/src/TQtTimer.cxx @@ -27,7 +27,7 @@ TQtTimer *TQtTimer::fgQTimer=0; void TQtTimer::AwakeRootEvent(){ // proceess the ROOT events inside of Qt event loop gSystem->DispatchOneEvent(kFALSE); - start(300); + start(5); } //______________________________________________________________________________ TQtTimer * TQtTimer::Create(QObject *parent) diff --git a/graf2d/qt/src/TQtWidget.cxx b/graf2d/qt/src/TQtWidget.cxx index 368062701a1d0..4c6634ac1e607 100644 --- a/graf2d/qt/src/TQtWidget.cxx +++ b/graf2d/qt/src/TQtWidget.cxx @@ -751,7 +751,7 @@ bool TQtWidget::Save(const char *fileName) const // it saves the double buffer of this object using the default save // format defined the file extension // If the "fileName" has no extension the "default" format is to be used instead - // The deafult format is "PNG". + // The default format is "PNG". // It can be changed with the TQtWidget::SetSaveFormat method // return Save(QString(fileName)); @@ -764,7 +764,7 @@ bool TQtWidget::Save(const QString &fileName) const // it saves the double buffer of this object using the default save // format defined the file extension // If the "fileName" has no extension the "default" format is to be used instead - // The deafult format is "PNG". + // The default format is "PNG". // It can be changed with the TQtWidget::SetSaveFormat method // QString fileNameExtension = QFileInfo(fileName).suffix().toUpper(); diff --git a/graf2d/quartz/CMakeLists.txt b/graf2d/quartz/CMakeLists.txt index 32851e9934992..7d36effb345c6 100644 --- a/graf2d/quartz/CMakeLists.txt +++ b/graf2d/quartz/CMakeLists.txt @@ -3,7 +3,7 @@ # @author Pere Mato, CERN ############################################################################ -add_definitions("-ObjC++ -std=c++11") +add_definitions("-ObjC++") ROOT_GENERATE_DICTIONARY(G__Quartz "" LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(GQuartz LINKDEF LinkDef.h DEPENDENCIES ) diff --git a/graf2d/quartz/Module.mk b/graf2d/quartz/Module.mk index 2d4cdb2820816..8e5ec4744907b 100644 --- a/graf2d/quartz/Module.mk +++ b/graf2d/quartz/Module.mk @@ -3,6 +3,11 @@ # # Author: Olivier Couet, 24/01/2012 +QUARTZNDEBUG := -DNDEBUG +ifeq ($(ROOTBUILD),debug) + QUARTZNDEBUG := +endif + MODNAME := quartz MODDIR := $(ROOT_SRCDIR)/graf2d/$(MODNAME) MODDIRS := $(MODDIR)/src @@ -72,3 +77,5 @@ distclean-$(MODNAME): clean-$(MODNAME) $(QUARTZMAP) distclean:: distclean-$(MODNAME) + +$(QUARTZOBJCPPO): CXXFLAGS += $(QUARTZNDEBUG) diff --git a/graf2d/quartz/inc/QuartzFillArea.h b/graf2d/quartz/inc/QuartzFillArea.h index 37fce5b7c976b..132c7c3d0598c 100644 --- a/graf2d/quartz/inc/QuartzFillArea.h +++ b/graf2d/quartz/inc/QuartzFillArea.h @@ -39,18 +39,16 @@ class TColorGradient; namespace ROOT { namespace Quartz { - -void DrawBox(CGContextRef ctx, Int_t x1, Int_t y1, Int_t x2, Int_t y2, Int_t mode); + +Bool_t SetFillColor(CGContextRef ctx, Color_t colorIndex); +Bool_t SetFillAreaParameters(CGContextRef ctx, unsigned *patternIndex); + +void DrawBox(CGContextRef ctx, Int_t x1, Int_t y1, Int_t x2, Int_t y2, bool hollow); void DrawBoxGradient(CGContextRef ctx, Int_t x1, Int_t y1, Int_t x2, Int_t y2, const TColorGradient *extendedColor, Bool_t drawShadow); void DrawFillArea(CGContextRef ctx, Int_t n, TPoint * xy, Bool_t drawShadow); void DrawFillAreaGradient(CGContextRef ctx, Int_t nPoints, const TPoint *xy, const TColorGradient *extendedColor, Bool_t drawShadow); -void SetFillStyle(CGContextRef ctx, Int_t style, - Float_t r, Float_t g, Float_t b, Float_t a); -void SetStencilPattern(CGContextRef ctx, - Float_t r, Float_t g, Float_t b, Float_t a); - } } diff --git a/graf2d/quartz/inc/QuartzLine.h b/graf2d/quartz/inc/QuartzLine.h index 3338ea8defa35..10bb73619dbb1 100644 --- a/graf2d/quartz/inc/QuartzLine.h +++ b/graf2d/quartz/inc/QuartzLine.h @@ -34,13 +34,14 @@ namespace ROOT { namespace Quartz { - -void DrawLine(CGContextRef ctx, Int_t x1, Int_t y1, Int_t x2, Int_t y2); -void DrawPolyLine(CGContextRef ctx, Int_t n, TPoint * xy); + +Bool_t SetLineColor(CGContextRef ctx, Color_t colorIndex); void SetLineStyle(CGContextRef ctx, Int_t lstyle); -void SetLineType(CGContextRef ctx, Int_t n, Int_t *dash); void SetLineWidth(CGContextRef ctx, Int_t width); +void DrawLine(CGContextRef ctx, Int_t x1, Int_t y1, Int_t x2, Int_t y2); +void DrawPolyLine(CGContextRef ctx, Int_t n, TPoint * xy); + } } diff --git a/graf2d/quartz/inc/QuartzUtils.h b/graf2d/quartz/inc/QuartzUtils.h new file mode 100644 index 0000000000000..3fa1fc2a597c0 --- /dev/null +++ b/graf2d/quartz/inc/QuartzUtils.h @@ -0,0 +1,36 @@ +// @(#)root/graf2d:$Id$ +// Author: Timur Pocheptsov, 11/06/2012 + +/************************************************************************* + * Copyright (C) 1995-2011, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_QuartzUtils +#define ROOT_QuartzUtils + +#include <ApplicationServices/ApplicationServices.h> + +namespace ROOT { +namespace Quartz { + +//Scope guard class for CGContextRef. +class CGStateGuard { +public: + CGStateGuard(CGContextRef ctx); + ~CGStateGuard(); + +private: + CGContextRef fCtx; + + CGStateGuard(const CGStateGuard &rhs); + CGStateGuard &operator = (const CGStateGuard &rhs); +}; + +} +} + +#endif diff --git a/graf2d/quartz/src/QuartzFillArea.mm b/graf2d/quartz/src/QuartzFillArea.mm index 7347711ad6f8c..c7157ea6495c6 100644 --- a/graf2d/quartz/src/QuartzFillArea.mm +++ b/graf2d/quartz/src/QuartzFillArea.mm @@ -8,23 +8,26 @@ * For the licensing terms see $ROOTSYS/LICENSE. * * For the list of contributors see $ROOTSYS/README/CREDITS. * *************************************************************************/ + #include <algorithm> #include <cassert> #include <vector> #include "QuartzFillArea.h" #include "TColorGradient.h" +#include "QuartzLine.h" #include "CocoaUtils.h" +#include "TVirtualX.h" #include "RStipples.h" #include "TError.h" #include "TROOT.h" -static Int_t gFillHollow; // Flag if fill style is hollow -static Int_t gFillPattern; // Fill pattern namespace ROOT { namespace Quartz { +namespace Util = MacOSX::Util; + namespace { const CGSize shadowOffset = CGSizeMake(10., 10.); @@ -39,27 +42,143 @@ void InvertGradientPositions(std::vector<CGFloat> &positions) positions[i] = 1. - positions[i]; } +}//Unnamed namespace. + +//______________________________________________________________________________ +Bool_t SetFillColor(CGContextRef ctx, Color_t colorIndex) +{ + assert(ctx != 0 && "SetFillColor, ctx parameter is null"); + + const TColor * const color = gROOT->GetColor(colorIndex); + if (!color) + return kFALSE; + + const CGFloat alpha = color->GetAlpha(); + + Float_t rgb[3] = {}; + color->GetRGB(rgb[0], rgb[1], rgb[2]); + CGContextSetRGBFillColor(ctx, rgb[0], rgb[1], rgb[2], alpha); + + return kTRUE; +} + +//______________________________________________________________________________ +void DrawPattern(void *data, CGContextRef ctx) +{ + assert(data != 0 && "DrawPattern, data parameter is null"); + assert(ctx != 0 && "DrawPattern, ctx parameter is null"); + + //Draw a stencil pattern from gStipples + const unsigned stencilIndex = *static_cast<unsigned *>(data); + + for (int i = 30, y = 0; i >= 0; i -= 2, ++y) { + int x = 0; + for (int j = 0; j < 8; ++j, ++x) { + if (gStipples[stencilIndex][i] & (1 << j)) + CGContextFillRect(ctx, CGRectMake(x, y, 1, 1)); + } + + for (int j = 0; j < 8; ++j, ++x) { + if (gStipples[stencilIndex][i + 1] & (1 << j)) + CGContextFillRect(ctx, CGRectMake(x, y, 1, 1)); + } + } +} + +//______________________________________________________________________________ +bool SetFillPattern(CGContextRef ctx, const unsigned *patternIndex) +{ + assert(ctx != 0 && "SetFillPattern, ctx parameter is null"); + assert(patternIndex != 0 && "SetFillPattern, patternIndex parameter is null"); + + const TColor *fillColor = gROOT->GetColor(gVirtualX->GetFillColor()); + if (!fillColor) + return false; + + CGFloat rgba[] = {fillColor->GetRed(), fillColor->GetGreen(), fillColor->GetBlue(), fillColor->GetAlpha()}; + + const Util::CFScopeGuard<CGColorSpaceRef> baseSpace(CGColorSpaceCreateDeviceRGB()); + if (!baseSpace.Get()) + return false; + + const Util::CFScopeGuard<CGColorSpaceRef> patternSpace(CGColorSpaceCreatePattern (baseSpace.Get())); + if (!patternSpace.Get()) + return false; + + CGContextSetFillColorSpace(ctx, patternSpace.Get()); + + CGPatternCallbacks callbacks = {0, &DrawPattern, 0}; + const Util::CFScopeGuard<CGPatternRef> pattern(CGPatternCreate((void*)patternIndex, + CGRectMake(0, 0, 16, 16), + CGAffineTransformIdentity, 16, 16, + kCGPatternTilingConstantSpacing, + false, &callbacks)); + + if (!pattern.Get()) + return false; + + CGContextSetFillPattern(ctx, pattern.Get(), rgba); + + return true; } +//______________________________________________________________________________ +bool SetFillAreaParameters(CGContextRef ctx, unsigned *patternIndex) +{ + assert(ctx != 0 && "SetFillAreaParameters, ctx parameter is null"); + + const unsigned fillStyle = gVirtualX->GetFillStyle() / 1000; + + //2 is hollow, 1 is solid and 3 is a hatch, !solid and !hatch - this is from O.C.'s code. + if (fillStyle == 2 || (fillStyle != 1 && fillStyle != 3)) { + if (!SetLineColor(ctx, gVirtualX->GetFillColor())) { + ::Error("SetFillAreaParameters", "Line color for index %d was not found", int(gVirtualX->GetLineColor())); + return false; + } + } else if (fillStyle == 1) { + //Solid fill. + if (!SetFillColor(ctx, gVirtualX->GetFillColor())) { + ::Error("SetFillAreaParameters", "Fill color for index %d was not found", int(gVirtualX->GetFillColor())); + return false; + } + } else { + assert(patternIndex != 0 && "SetFillAreaParameters, pattern index in null"); + + *patternIndex = gVirtualX->GetFillStyle() % 1000; + //ROOT has 26 fixed patterns. + if (*patternIndex >= 26) { + ::Error("SetFillAreaParameters", "Pattern index must be < 26"); + return false; + } + + if (!SetFillPattern(ctx, patternIndex)) { + ::Error("SetFillAreaParameters", "SetFillPattern failed"); + return false; + } + } + + return true; +} //______________________________________________________________________________ -void DrawBox(CGContextRef ctx, Int_t x1, Int_t y1, Int_t x2, Int_t y2, - Int_t mode) +void DrawBox(CGContextRef ctx, Int_t x1, Int_t y1, Int_t x2, Int_t y2, bool hollow) { // Draw a box - if (x1 > x2) std::swap(x1, x2); - if (y1 > y2) std::swap(y1, y2); - - if (mode) CGContextFillRect(ctx, CGRectMake(x1, y1, x2 - x1, y2 - y1)); - else CGContextStrokeRect(ctx, CGRectMake(x1, y1, x2 - x1, y2 - y1)); + if (x1 > x2) + std::swap(x1, x2); + if (y1 > y2) + std::swap(y1, y2); + + if (hollow) + CGContextStrokeRect(ctx, CGRectMake(x1, y1, x2 - x1, y2 - y1)); + else + CGContextFillRect(ctx, CGRectMake(x1, y1, x2 - x1, y2 - y1)); } //______________________________________________________________________________ void DrawBoxGradient(CGContextRef ctx, Int_t x1, Int_t y1, Int_t x2, Int_t y2, const TColorGradient *extendedColor, Bool_t drawShadow) { - using ROOT::MacOSX::Util::CFScopeGuard; - assert(ctx != nullptr && "DrawBoxGradient, ctx parameter is null"); assert(extendedColor != nullptr && "DrawBoxGradient, extendedColor parameter is null"); assert(extendedColor->GetNumberOfSteps() != 0 && "DrawBoxGradient, no colors in extendedColor"); @@ -91,36 +210,47 @@ void DrawBoxGradient(CGContextRef ctx, Int_t x1, Int_t y1, Int_t x2, Int_t y2, c CGContextClip(ctx); //Create a gradient. - const CFScopeGuard<CGColorSpaceRef> baseSpace(CGColorSpaceCreateDeviceRGB()); + const Util::CFScopeGuard<CGColorSpaceRef> baseSpace(CGColorSpaceCreateDeviceRGB()); std::vector<CGFloat> positions(extendedColor->GetColorPositions(), extendedColor->GetColorPositions() + extendedColor->GetNumberOfSteps()); InvertGradientPositions(positions); - const CFScopeGuard<CGGradientRef> gradient(CGGradientCreateWithColorComponents(baseSpace.Get(), extendedColor->GetColors(), &positions[0], extendedColor->GetNumberOfSteps())); + const Util::CFScopeGuard<CGGradientRef> gradient(CGGradientCreateWithColorComponents(baseSpace.Get(), extendedColor->GetColors(), &positions[0], extendedColor->GetNumberOfSteps())); CGContextDrawLinearGradient(ctx, gradient.Get(), startPoint, endPoint, 0); } //______________________________________________________________________________ -void DrawFillArea(CGContextRef ctx, Int_t n, TPoint * xy, Bool_t shadow) +void DrawFillArea(CGContextRef ctx, Int_t n, TPoint *xy, Bool_t shadow) { // Draw a filled area through all points. // n : number of points // xy : list of points + + assert(ctx != 0 && "DrawFillArea, ctx parameter is null"); + assert(xy != 0 && "DrawFillArea, xy parameter is null"); - CGContextBeginPath (ctx); + CGContextBeginPath(ctx); - CGContextMoveToPoint (ctx, xy[0].fX, xy[0].fY); + CGContextMoveToPoint(ctx, xy[0].fX, xy[0].fY); for (Int_t i = 1; i < n; ++i) - CGContextAddLineToPoint (ctx, xy[i].fX, xy[i].fY); + CGContextAddLineToPoint(ctx, xy[i].fX, xy[i].fY); CGContextClosePath(ctx); - if (gFillHollow) + const unsigned fillStyle = gVirtualX->GetFillStyle() / 1000; + + //2 is hollow, 1 is solid and 3 is a hatch, !solid and !hatch - this is from O.C.'s code. + if (fillStyle == 2 || (fillStyle != 1 && fillStyle != 3)) { CGContextStrokePath(ctx); - else { + } else if (fillStyle == 1) { if (shadow) CGContextSetShadow(ctx, shadowOffset, shadowBlur); + CGContextFillPath(ctx); + } else { + if (shadow) + CGContextSetShadow(ctx, shadowOffset, shadowBlur); + CGContextFillPath(ctx); } } @@ -195,101 +325,6 @@ void DrawFillAreaGradient(CGContextRef ctx, Int_t nPoints, const TPoint *xy, con extendedColor->GetNumberOfSteps())); CGContextDrawLinearGradient(ctx, gradient.Get(), startPoint, endPoint, 0); } - -//______________________________________________________________________________ -void SetFillStyle(CGContextRef ctx, Int_t style, - Float_t r, Float_t g, Float_t b, Float_t a) - -{ - // Set fill area style. - // - // style - compound fill area interior style - // style = 1000 * interiorstyle + styleindex - - Int_t fais = style/1000; - Int_t fasi = style%1000; - - gFillHollow = 0; - gFillPattern = 0; - - switch (fais) { - case 1: // solid - break; - - case 2: // pattern - gFillHollow = 1; - break; - - case 3: // hatch - gFillHollow = 0; - gFillPattern = fasi; - SetStencilPattern(ctx, r, g, b, a); - break; - - default: - gFillHollow = 1; - break; - } -} - - -//______________________________________________________________________________ -void DrawStencil (void *sti, CGContextRef ctx) -{ - // Draw a stencil pattern from gStipples - - int i,j; - - int *st = static_cast<int *>(sti); - - int x , y=0; - for (i=0; i<31; i=i+2) { - x = 0; - for (j=0; j<8; j++) { - if (gStipples[*st][i] & (1<<j)) - CGContextFillRect(ctx, CGRectMake(x, y, 1, 1)); - x++; - } - for (j=0; j<8; j++) { - if (gStipples[*st][i+1] & (1<<j)) - CGContextFillRect(ctx, CGRectMake(x, y, 1, 1)); - x++; - } - y++; - } -} - - -//______________________________________________________________________________ -void SetStencilPattern(CGContextRef ctx, - Float_t r, Float_t g, Float_t b, Float_t a) -{ - // Set the fill pattern - - CGPatternRef pattern; - CGColorSpaceRef baseSpace; - CGColorSpaceRef patternSpace; - - CGFloat RGB[4]; - RGB[0] = r; - RGB[1] = g; - RGB[2] = b; - RGB[3] = a; - CGPatternCallbacks callbacks = {0, &DrawStencil, NULL}; - - baseSpace = CGColorSpaceCreateDeviceRGB (); - patternSpace = CGColorSpaceCreatePattern (baseSpace); - CGContextSetFillColorSpace (ctx, patternSpace); - CGColorSpaceRelease (patternSpace); - CGColorSpaceRelease (baseSpace); - - pattern = CGPatternCreate(&gFillPattern, CGRectMake(0, 0, 16, 16), - CGAffineTransformIdentity, 16, 16, - kCGPatternTilingConstantSpacing, - false, &callbacks); - CGContextSetFillPattern (ctx, pattern, RGB); - CGPatternRelease (pattern); -} }//namespace Quartz }//namespace ROOT diff --git a/graf2d/quartz/src/QuartzLine.mm b/graf2d/quartz/src/QuartzLine.mm index c2c25d00c2b1d..bf0c2765b8362 100644 --- a/graf2d/quartz/src/QuartzLine.mm +++ b/graf2d/quartz/src/QuartzLine.mm @@ -9,13 +9,16 @@ * For the list of contributors see $ROOTSYS/README/CREDITS. * *************************************************************************/ +#include <cassert> #include <vector> +#include "CocoaUtils.h" #include "TObjString.h" #include "QuartzLine.h" #include "RStipples.h" #include "TObjArray.h" #include "TString.h" +#include "TColor.h" #include "TStyle.h" #include "TROOT.h" @@ -23,34 +26,51 @@ namespace Quartz { //______________________________________________________________________________ -void DrawLine(CGContextRef ctx, Int_t x1, Int_t y1, Int_t x2, Int_t y2) +Bool_t SetLineColor(CGContextRef ctx, Color_t colorIndex) { - CGContextBeginPath(ctx); - CGContextMoveToPoint(ctx, x1, y1); - CGContextAddLineToPoint(ctx, x2, y2); - CGContextStrokePath(ctx); -} + assert(ctx != 0 && "SetLineColor, ctx parameter is null"); + const TColor * const color = gROOT->GetColor(colorIndex); + if (!color) + return kFALSE; + + const CGFloat alpha = color->GetAlpha(); + Float_t rgb[3] = {}; + color->GetRGB(rgb[0], rgb[1], rgb[2]); + CGContextSetRGBStrokeColor(ctx, rgb[0], rgb[1], rgb[2], alpha); + + return kTRUE; +} //______________________________________________________________________________ -void DrawPolyLine(CGContextRef ctx, Int_t n, TPoint * xy) +void SetLineType(CGContextRef ctx, Int_t n, Int_t *dash) { - // Draw a line through all points. - // n : number of points - // xy : list of points - - CGContextBeginPath(ctx); - CGContextMoveToPoint (ctx, xy[0].fX, xy[0].fY); - for (Int_t i = 1; i < n; ++i) - CGContextAddLineToPoint(ctx, xy[i].fX, xy[i].fY); - CGContextStrokePath(ctx); -} + // Set the line type in the context ctx. + // + // n - length of the dash list + // n <= 0 use solid lines + // n > 0 use dashed lines described by dash(n) + // e.g. n = 4,dash = (6,3,1,3) gives a dashed-dotted line + // with dash length 6 and a gap of 7 between dashes + // dash(n) - dash segment lengths + + assert(ctx != 0 && "SetLineType, ctx parameter is null"); + if (n) { + CGFloat lengths[n]; + for (int i = 0; i < n; i++) + lengths[i] = dash[i]; + CGContextSetLineDash(ctx, 0, lengths, n); + } else { + CGContextSetLineDash(ctx, 0, NULL, 0); + } +} //______________________________________________________________________________ void SetLineStyle(CGContextRef ctx, Int_t lstyle) { // Set current line style in the context ctx. + assert(ctx != 0 && "SetLineStyle, ctx parameter is null"); static Int_t dashed[2] = {3, 3}; static Int_t dotted[2] = {1, 2}; @@ -79,29 +99,6 @@ void SetLineStyle(CGContextRef ctx, Int_t lstyle) delete tokens; } } - - -//______________________________________________________________________________ -void SetLineType(CGContextRef ctx, Int_t n, Int_t *dash) -{ - // Set the line type in the context ctx. - // - // n - length of the dash list - // n <= 0 use solid lines - // n > 0 use dashed lines described by dash(n) - // e.g. n = 4,dash = (6,3,1,3) gives a dashed-dotted line - // with dash length 6 and a gap of 7 between dashes - // dash(n) - dash segment lengths - - if (n) { - CGFloat lengths[n]; - for (int i=0; i<n;i++) lengths[i] = (CGFloat)dash[i]; - CGContextSetLineDash(ctx,0,lengths,n); - } else { - CGContextSetLineDash(ctx,0,NULL,0); - } -} - //______________________________________________________________________________ void SetLineWidth(CGContextRef ctx, Int_t width) @@ -109,6 +106,8 @@ void SetLineWidth(CGContextRef ctx, Int_t width) // Set the line width in the context ctx. // // width - the line width in pixels + assert(ctx != 0 && "SetLineWidth, ctx parameter is null"); + if (width < 0) return; @@ -116,6 +115,38 @@ void SetLineWidth(CGContextRef ctx, Int_t width) CGContextSetLineWidth(ctx, width); } +//______________________________________________________________________________ +void DrawLine(CGContextRef ctx, Int_t x1, Int_t y1, Int_t x2, Int_t y2) +{ + assert(ctx != 0 && "DrawLine, ctx parameter is null"); + + CGContextBeginPath(ctx); + CGContextMoveToPoint(ctx, x1, y1); + CGContextAddLineToPoint(ctx, x2, y2); + CGContextStrokePath(ctx); +} + + +//______________________________________________________________________________ +void DrawPolyLine(CGContextRef ctx, Int_t n, TPoint * xy) +{ + // Draw a line through all points. + // n : number of points + // xy : list of points + + assert(ctx != 0 && "DrawPolyLine, ctx parameter is null"); + assert(xy != 0 && "DrawPolyLine, xy parameter is null"); + + CGContextBeginPath(ctx); + CGContextMoveToPoint(ctx, xy[0].fX, xy[0].fY); + for (Int_t i = 1; i < n; ++i) + CGContextAddLineToPoint(ctx, xy[i].fX, xy[i].fY); + + if (xy[n - 1].fX == xy[0].fX && xy[n - 1].fY == xy[0].fY) + CGContextClosePath(ctx); + + CGContextStrokePath(ctx); +} }//namespace Quartz }//namespace ROOT diff --git a/graf2d/quartz/src/QuartzText.mm b/graf2d/quartz/src/QuartzText.mm index e9c85bf6297c1..7e928bd0de4aa 100644 --- a/graf2d/quartz/src/QuartzText.mm +++ b/graf2d/quartz/src/QuartzText.mm @@ -28,10 +28,12 @@ namespace { //______________________________________________________________________________ -void GetTextColorForIndex(Color_t colorIndex, Float_t &r, Float_t &g, Float_t &b) +void GetTextColorForIndex(Color_t colorIndex, Float_t &r, Float_t &g, Float_t &b, Float_t &a) { - if (const TColor *color = gROOT->GetColor(colorIndex)) + if (const TColor * const color = gROOT->GetColor(colorIndex)) { color->GetRGB(r, g, b); + a = color->GetAlpha(); + } } } @@ -69,8 +71,8 @@ void GetTextColorForIndex(Color_t colorIndex, Float_t &r, Float_t &g, Float_t &b throw std::runtime_error("TextLine: color space"); Float_t rgba[] = {0.f, 0.f, 0.f, 1.f}; - GetTextColorForIndex(color, rgba[0], rgba[1], rgba[2]); - const CGFloat cgRgba[] = {rgba[0], rgba[1], rgba[2], 1.}; + GetTextColorForIndex(color, rgba[0], rgba[1], rgba[2], rgba[3]); + const CGFloat cgRgba[] = {rgba[0], rgba[1], rgba[2], rgba[3]}; const CFScopeGuard<CGColorRef> textColor(CGColorCreate(rgbColorSpace.Get(), cgRgba)); //Not clear from docs, if textColor.Get() can be 0. @@ -114,8 +116,8 @@ void GetTextColorForIndex(Color_t colorIndex, Float_t &r, Float_t &g, Float_t &b throw std::runtime_error("TextLine: color space"); Float_t rgba[] = {0.f, 0.f, 0.f, 1.f}; - GetTextColorForIndex(color, rgba[0], rgba[1], rgba[2]); - const CGFloat cgRgba[] = {rgba[0], rgba[1], rgba[2], 1.}; + GetTextColorForIndex(color, rgba[0], rgba[1], rgba[2], rgba[3]); + const CGFloat cgRgba[] = {rgba[0], rgba[1], rgba[2], rgba[3]}; const CFScopeGuard<CGColorRef> textColor(CGColorCreate(rgbColorSpace.Get(), cgRgba)); //Not clear from docs, if textColor.Get() can be 0. diff --git a/graf2d/quartz/src/QuartzUtils.mm b/graf2d/quartz/src/QuartzUtils.mm new file mode 100644 index 0000000000000..596a5a5f3b82f --- /dev/null +++ b/graf2d/quartz/src/QuartzUtils.mm @@ -0,0 +1,34 @@ +// @(#)root/graf2d:$Id$ +// Author: Timur Pocheptsov, 11/06/2012 + +/************************************************************************* + * Copyright (C) 1995-2011, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#include <cassert> + +#include "QuartzUtils.h" + +namespace ROOT { +namespace Quartz { + +//______________________________________________________________________________ +CGStateGuard::CGStateGuard(CGContextRef ctx) + : fCtx(ctx) +{ + assert(ctx != 0 && "CGStateGuard, ctx parameter is null"); + CGContextSaveGState(ctx); +} + +//______________________________________________________________________________ +CGStateGuard::~CGStateGuard() +{ + CGContextRestoreGState(fCtx); +} + +}//Quartz +}//ROOT diff --git a/graf2d/win32gdk/CMakeLists.txt b/graf2d/win32gdk/CMakeLists.txt index f3b935011e401..b1b348e320238 100644 --- a/graf2d/win32gdk/CMakeLists.txt +++ b/graf2d/win32gdk/CMakeLists.txt @@ -4,52 +4,107 @@ ############################################################################ ROOT_USE_PACKAGE(gui/gui) include_directories(${FREETYPE_INCLUDE_DIRS} ${CMAKE_CURRENT_SOURCE_DIR}/gdk/src - ${CMAKE_CURRENT_SOURCE_DIR}/gdk/src/gdk ${CMAKE_CURRENT_SOURCE_DIR}/gdk/src/glib) + ${CMAKE_CURRENT_SOURCE_DIR}/gdk/src/gdk + ${CMAKE_CURRENT_BINARY_DIR}/gdk/src/glib) + +set(iconvlib ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/iconv-1.3.lib) +set(iconvdll ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${CMAKE_CFG_INTDIR}/iconv-1.3.dll) +set(iconvliba ${CMAKE_CURRENT_BINARY_DIR}/gdk/src/iconv/iconv-1.3.lib) +set(iconvdlla ${CMAKE_CURRENT_BINARY_DIR}/gdk/src/iconv/iconv-1.3.dll) + +set(gliblib ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/glib-1.3.lib) +set(glibdll ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${CMAKE_CFG_INTDIR}/glib-1.3.dll) +set(glibliba ${CMAKE_CURRENT_BINARY_DIR}/gdk/src/glib/glib-1.3.lib) +set(glibdlla ${CMAKE_CURRENT_BINARY_DIR}/gdk/src/glib/glib-1.3.dll) set(gdklib ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/gdk-1.3.lib) -set(glib ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/glib-1.3.lib) set(gdkdll ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${CMAKE_CFG_INTDIR}/gdk-1.3.dll) set(gdkliba ${CMAKE_CURRENT_BINARY_DIR}/gdk/src/gdk/gdk-1.3.lib) set(gdkdlla ${CMAKE_CURRENT_BINARY_DIR}/gdk/src/gdk/gdk-1.3.dll) + if(winrtdebug) set(nmcxxflags "${CMAKE_CXX_FLAGS}" DEBUG=1) else() set(nmcxxflags "${CMAKE_CXX_FLAGS}") endif() +# Build iconv + +add_custom_command( OUTPUT ${iconvliba} ${iconvdlla} + COMMAND cmake -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/gdk gdk + COMMAND echo "*** Building ${iconvliba}" + COMMAND cmake -E chdir gdk/src/iconv + nmake -nologo -f makefile.msc NMCXXFLAGS=${nmcxxflags} VC_MAJOR=${VC_MAJOR} + ) + +add_custom_command( OUTPUT ${iconvlib} ${iconvdll} + COMMAND cmake -E copy_if_different ${iconvliba} ${iconvlib} + COMMAND cmake -E copy_if_different ${iconvdlla} ${iconvdll} + DEPENDS ${iconvliba} ${iconvdlla} + ) + +add_custom_target(iconv DEPENDS ${iconvlib}) +set_target_properties(iconv PROPERTIES FOLDER Builtins) + +# Build glib + +add_custom_command( OUTPUT ${glibliba} ${glibdlla} + COMMAND echo "*** Building ${glibliba}" + COMMAND cmake -E chdir gdk/src/glib + nmake -nologo -f makefile.msc NMCXXFLAGS=${nmcxxflags} VC_MAJOR=${VC_MAJOR} + DEPENDS iconv + ) + +add_custom_command( OUTPUT ${gliblib} ${glibdll} + COMMAND cmake -E copy_if_different ${glibliba} ${gliblib} + COMMAND cmake -E copy_if_different ${glibdlla} ${glibdll} + DEPENDS ${glibliba} ${glibdlla}) + +add_custom_target(glib DEPENDS ${gliblib}) +set_target_properties(glib PROPERTIES FOLDER Builtins) + +# Build gdk + add_custom_command( OUTPUT ${gdkliba} - COMMAND cmake -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/gdk gdk - COMMAND cmake -E copy_if_different gdk/lib/glib-1.3.lib ${CMAKE_LIBRARY_OUTPUT_DIRECTORY} - COMMAND cmake -E copy_if_different gdk/dll/glib-1.3.dll ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${CMAKE_CFG_INTDIR} - COMMAND cmake -E copy_if_different gdk/dll/iconv-1.3.dll ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${CMAKE_CFG_INTDIR} COMMAND echo "*** Building ${gdkliba}" - COMMAND cmake -E chdir gdk/src/gdk/win32 - nmake -nologo -f makefile.msc NMCXXFLAGS=${nmcxxflags} VC_MAJOR=${VC_MAJOR} - COMMAND cmake -E chdir gdk/src/gdk - nmake -nologo -f makefile.msc NMCXXFLAGS=${nmcxxflags} VC_MAJOR=${VC_MAJOR} + COMMAND cmake -E chdir gdk/src/gdk/win32 + nmake -nologo -f makefile.msc NMCXXFLAGS=${nmcxxflags} VC_MAJOR=${VC_MAJOR} + COMMAND cmake -E chdir gdk/src/gdk + nmake -nologo -f makefile.msc NMCXXFLAGS=${nmcxxflags} VC_MAJOR=${VC_MAJOR} + DEPENDS glib ) add_custom_command( OUTPUT ${gdklib} ${gdkdll} - COMMAND cmake -E copy_if_different ${gdkliba} ${gdklib} + COMMAND cmake -E copy_if_different ${gdkliba} ${gdklib} COMMAND cmake -E copy_if_different ${gdkdlla} ${gdkdll} DEPENDS ${gdkliba} ) add_custom_target(GDKLIB DEPENDS ${gdklib}) set_target_properties(GDKLIB PROPERTIES FOLDER Builtins) +# +# ROOT Dicts for the win32gdk library +# + ROOT_GENERATE_DICTIONARY(G__Win32gdk TGWin32.h TGWin32GL.h LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(Win32gdk LINKDEF LinkDef.h DEPENDENCIES) +# +# The library itself +# + ROOT_LINKER_LIBRARY(Win32gdk *.cxx *.c G__Win32gdk.cxx LIBRARIES Cint Core Graf ${FREETYPE_LIBRARIES} - ${gdklib} ${glib} Glu32.lib Opengl32.lib) -add_dependencies(Win32gdk GDKLIB) + ${gdklib} ${gliblib} Glu32.lib Opengl32.lib) + +add_dependencies(Win32gdk GDKLIB glib) + if(builtin_freetype) add_dependencies(Win32gdk FREETYPE) endif() install(FILES ${gdkdlla} - gdk/dll/glib-1.3.dll - gdk/dll/iconv-1.3.dll - DESTINATION bin) + ${glibdlla} + ${iconvdlla} + DESTINATION ${CMAKE_INSTALL_BINDIR}) ROOT_INSTALL_HEADERS() diff --git a/graf2d/win32gdk/Module.mk b/graf2d/win32gdk/Module.mk index 9c6e0da695fd3..7031bac0a2995 100644 --- a/graf2d/win32gdk/Module.mk +++ b/graf2d/win32gdk/Module.mk @@ -15,7 +15,32 @@ WIN32GDKDIRI := $(WIN32GDKDIR)/inc GDKVERS := gdk/src GDKDIRS := $(MODDIR)/$(GDKVERS)/gdk GDKDIRI := $(MODDIR)/$(GDKVERS)/gdk +GLIBDIR := $(MODDIR)/$(GDKVERS)/glib GLIBDIRI := $(MODDIR)/$(GDKVERS)/glib +ICONVDIR := $(MODDIR)/$(GDKVERS)/iconv + +##### iconv-1.3.dll ##### +ICONVDLLA := $(call stripsrc,$(ICONVDIR))/iconv-1.3.dll +ICONVLIBA := $(call stripsrc,$(ICONVDIR))/iconv-1.3.lib +ICONVDLL := bin/iconv-1.3.dll +ICONVSRC := $(wildcard $(ICONVDIR)/*.c) + +ICONVNMCXXFLAGS:= "$(OPT) $(BLDCXXFLAGS) -FI$(shell cygpath -w '$(ROOT_SRCDIR)/build/win/w32pragma.h')" +ifeq (yes,$(WINRTDEBUG)) +ICONVNMCXXFLAGS += DEBUG=1 +endif + +##### glib-1.3.dll ##### +GLIBDLLA := $(call stripsrc,$(GLIBDIR))/glib-1.3.dll +GLIBLIBA := $(call stripsrc,$(GLIBDIR))/glib-1.3.lib +GLIBDLL := bin/glib-1.3.dll +GLIBLIB := $(LPATH)/glib-1.3.lib +GLIBSRC := $(wildcard $(GLIBDIR)/*.c) + +GLIBNMCXXFLAGS:= "$(OPT) $(BLDCXXFLAGS) -FI$(shell cygpath -w '$(ROOT_SRCDIR)/build/win/w32pragma.h')" +ifeq (yes,$(WINRTDEBUG)) +GLIBNMCXXFLAGS += DEBUG=1 +endif ##### gdk-1.3.dll ##### GDKDLLA := $(call stripsrc,$(GDKDIRS)/gdk-1.3.dll) @@ -49,8 +74,8 @@ WIN32GDKLIB := $(LPATH)/libWin32gdk.$(SOEXT) WIN32GDKMAP := $(WIN32GDKLIB:.$(SOEXT)=.rootmap) # GDK libraries and DLL's -GDKLIBS := lib/glib-1.3.lib -GDKDLLS := bin/glib-1.3.dll bin/iconv-1.3.dll +GDKLIBS := $(GLIBLIB) +GDKDLLS := $(GLIBDLL) $(ICONVDLL) # used in the main Makefile ALLHDRS += $(patsubst $(MODDIRI)/%.h,include/%.h,$(WIN32GDKH)) @@ -66,23 +91,47 @@ INCLUDEFILES += $(WIN32GDKDEP) include/%.h: $(WIN32GDKDIRI)/%.h cp $< $@ -lib/%.lib: $(WIN32GDKDIR)/gdk/lib/%.lib - cp $< $@ +$(ICONVLIBA): $(ICONVSRC) + $(MAKEDIR) +ifneq ($(ROOT_OBJDIR),$(ROOT_SRCDIR)) + @$(RSYNC) --exclude '.svn' --exclude '*.o' --exclude '*.lib' --exclude '*.dll' $(ICONVDIR) $(dir $(call stripsrc,$(ICONVDIR))) +endif + @(echo "*** Building $@..."; \ + unset MAKEFLAGS; \ + cd $(call stripsrc,$(ICONVDIR)); \ + nmake -nologo -f makefile.msc \ + NMCXXFLAGS=$(ICONVNMCXXFLAGS) VC_MAJOR=$(VC_MAJOR)); + +$(GLIBLIBA): $(GLIBSRC) $(ICONVLIBA) + $(MAKEDIR) +ifneq ($(ROOT_OBJDIR),$(ROOT_SRCDIR)) + @$(RSYNC) --exclude '.svn' --exclude '*.o' --exclude '*.lib' --exclude '*.dll' $(GLIBDIR) $(dir $(call stripsrc,$(GLIBDIR))) +endif + @(echo "*** Building $@..."; \ + unset MAKEFLAGS; \ + cd $(call stripsrc,$(GLIBDIR)); \ + nmake -nologo -f makefile.msc \ + NMCXXFLAGS=$(GLIBNMCXXFLAGS) VC_MAJOR=$(VC_MAJOR)); + +$(ICONVDLL): $(ICONVLIBA) + cp $(ICONVDLLA) $@ -bin/%.dll: $(WIN32GDKDIR)/gdk/dll/%.dll +$(GLIBLIB): $(GLIBLIBA) cp $< $@ +$(GLIBDLL): $(GLIBLIBA) + cp $(GLIBDLLA) $@ + $(GDKLIB): $(GDKLIBA) cp $< $@ $(GDKDLL): $(GDKLIBA) cp $(GDKDLLA) $@ -$(GDKLIBA): $(GDKSRC) +$(GDKLIBA): $(GDKSRC) $(GLIBLIB) $(MAKEDIR) ifneq ($(ROOT_OBJDIR),$(ROOT_SRCDIR)) @$(RSYNC) --exclude '.svn' --exclude '*.o' --exclude '*.lib' --exclude '*.dll' $(GDKDIRS) $(dir $(call stripsrc,$(GDKDIRS))) - @$(RSYNC) --exclude '.svn' $(WIN32GDKDIR)/gdk/lib $(call stripsrc,$(WIN32GDKDIR)/gdk) endif @(echo "*** Building $@..."; \ unset MAKEFLAGS; \ diff --git a/graf2d/win32gdk/gdk/dll/glib-1.3.dll b/graf2d/win32gdk/gdk/dll/glib-1.3.dll deleted file mode 100755 index b3d65ec5007b1..0000000000000 Binary files a/graf2d/win32gdk/gdk/dll/glib-1.3.dll and /dev/null differ diff --git a/graf2d/win32gdk/gdk/dll/iconv-1.3.dll b/graf2d/win32gdk/gdk/dll/iconv-1.3.dll deleted file mode 100755 index 4463871dc6aae..0000000000000 Binary files a/graf2d/win32gdk/gdk/dll/iconv-1.3.dll and /dev/null differ diff --git a/graf2d/win32gdk/gdk/lib/glib-1.3.lib b/graf2d/win32gdk/gdk/lib/glib-1.3.lib deleted file mode 100644 index 2a12574b056cf..0000000000000 Binary files a/graf2d/win32gdk/gdk/lib/glib-1.3.lib and /dev/null differ diff --git a/graf2d/win32gdk/gdk/src/gdk/gdkcolor.c b/graf2d/win32gdk/gdk/src/gdk/gdkcolor.c index 5f408095623f2..aeef551fd6130 100644 --- a/graf2d/win32gdk/gdk/src/gdk/gdkcolor.c +++ b/graf2d/win32gdk/gdk/src/gdk/gdkcolor.c @@ -173,11 +173,11 @@ gboolean gdk_color_black(GdkColormap * colormap, GdkColor * color) gboolean gdk_colormap_alloc_color(GdkColormap * colormap, GdkColor * color, - gboolean writeable, gboolean best_match) + gboolean writable, gboolean best_match) { gboolean success; - gdk_colormap_alloc_colors(colormap, color, 1, writeable, best_match, + gdk_colormap_alloc_colors(colormap, color, 1, writable, best_match, &success); return success; diff --git a/graf2d/win32gdk/gdk/src/gdk/gdkcolor.h b/graf2d/win32gdk/gdk/src/gdk/gdkcolor.h index 443013e085dca..9b701aeffece7 100644 --- a/graf2d/win32gdk/gdk/src/gdk/gdkcolor.h +++ b/graf2d/win32gdk/gdk/src/gdk/gdkcolor.h @@ -42,11 +42,11 @@ extern "C" { gint gdk_colormap_alloc_colors(GdkColormap * colormap, GdkColor * colors, gint ncolors, - gboolean writeable, + gboolean writable, gboolean best_match, gboolean * success); gboolean gdk_colormap_alloc_color(GdkColormap * colormap, GdkColor * color, - gboolean writeable, + gboolean writable, gboolean best_match); void gdk_colormap_free_colors(GdkColormap * colormap, GdkColor * colors, gint ncolors); diff --git a/graf2d/win32gdk/gdk/src/gdk/gdkdraw.c b/graf2d/win32gdk/gdk/src/gdk/gdkdraw.c index 28bba9def0527..5591986b223a5 100644 --- a/graf2d/win32gdk/gdk/src/gdk/gdkdraw.c +++ b/graf2d/win32gdk/gdk/src/gdk/gdkdraw.c @@ -237,7 +237,7 @@ gdk_draw_polygon(GdkDrawable * drawable, * * Modified by Li-Da Lho to draw 16 bits and Multibyte strings * - * Interface changed: add "GdkFont *font" to specify font or fontset explicitely + * Interface changed: add "GdkFont *font" to specify font or fontset explicitly */ void gdk_draw_string(GdkDrawable * drawable, @@ -252,7 +252,7 @@ gdk_draw_string(GdkDrawable * drawable, * * Modified by Li-Da Lho to draw 16 bits and Multibyte strings * - * Interface changed: add "GdkFont *font" to specify font or fontset explicitely + * Interface changed: add "GdkFont *font" to specify font or fontset explicitly */ void gdk_draw_text(GdkDrawable * drawable, diff --git a/graf2d/win32gdk/gdk/src/gdk/gdkevents.c b/graf2d/win32gdk/gdk/src/gdk/gdkevents.c index ce2c84547b684..7c4bbd9218433 100644 --- a/graf2d/win32gdk/gdk/src/gdk/gdkevents.c +++ b/graf2d/win32gdk/gdk/src/gdk/gdkevents.c @@ -604,10 +604,6 @@ gboolean gdk_check_typed_window_event(GdkWindow * w, gint type, GdkEvent * event) { - GList *cPtr; - GdkEventPrivate *pevent; - GList *head; - // GList *tmp_list = gdk_queued_events; GList *tmp_list = gdk_event_queue_find_first(); while (tmp_list) { diff --git a/graf2d/win32gdk/gdk/src/gdk/makefile.msc b/graf2d/win32gdk/gdk/src/gdk/makefile.msc index c4d07b60dff4c..274620807f8c9 100644 --- a/graf2d/win32gdk/gdk/src/gdk/makefile.msc +++ b/graf2d/win32gdk/gdk/src/gdk/makefile.msc @@ -73,7 +73,7 @@ win32\gdk-win32.lib: cd .. gdk-$(GTK_VER).dll : $(gdk_OBJECTS) gdk.def win32\gdk-win32.lib - $(CC) $(CFLAGS) -LD -Fegdk-$(GTK_VER).dll $(gdk_OBJECTS) win32\gdk-win32.lib ..\..\lib\glib-$(GLIB_VER).lib gdi32.lib user32.lib imm32.lib shell32.lib ole32.lib uuid.lib Msimg32.lib win32\gdk.res $(LDFLAGS) /def:gdk.def + $(CC) $(CFLAGS) -LD -Fegdk-$(GTK_VER).dll $(gdk_OBJECTS) win32\gdk-win32.lib $(GLIB)\glib-$(GLIB_VER).lib gdi32.lib user32.lib imm32.lib shell32.lib ole32.lib uuid.lib Msimg32.lib win32\gdk.res $(LDFLAGS) /def:gdk.def $(MT_DLL) $(CLEAN_MT) diff --git a/graf2d/win32gdk/gdk/src/gdk/win32/gdkcolor-win32.c b/graf2d/win32gdk/gdk/src/gdk/win32/gdkcolor-win32.c index 4628923831bd7..196dcf59ff8d3 100644 --- a/graf2d/win32gdk/gdk/src/gdk/win32/gdkcolor-win32.c +++ b/graf2d/win32gdk/gdk/src/gdk/win32/gdkcolor-win32.c @@ -165,7 +165,6 @@ terms specified in this license. static int alloc_color(Colormap colormap, XColor * color, gulong * pixelp) { PALETTEENTRY entry, closeEntry; - HDC hdc; unsigned int i; entry = *color; @@ -333,7 +332,6 @@ static Colormap create_colormap(HWND w, Visual * visual, gboolean alloc) { char logPalBuf[sizeof(LOGPALETTE) + 256 * sizeof(PALETTEENTRY)]; LOGPALETTE *logPalettePtr; - PALETTEENTRY *entryPtr; Colormap colormap; guint i; HPALETTE sysPal; @@ -1263,7 +1261,6 @@ gboolean parse_color(Colormap map, const char *spec, GdkColor * colorPtr) static Colormap default_colormap() { static Colormap colormap; - gint i; if (colormap) return colormap; @@ -1277,7 +1274,6 @@ GdkColormap *gdk_colormap_new(GdkVisual * visual, gint private_cmap) GdkColormap *colormap; GdkColormapPrivateWin32 *private; Visual *xvisual; - int size; int i; g_return_val_if_fail(visual != NULL, NULL); @@ -1410,7 +1406,6 @@ GdkColormap *gdk_colormap_get_system(void) { static GdkColormap *colormap = NULL; GdkColormapPrivateWin32 *private; - gint i; if (!colormap) { private = g_new(GdkColormapPrivateWin32, 1); @@ -1467,11 +1462,7 @@ gint gdk_colormap_get_system_size(void) void gdk_colormap_change(GdkColormap * colormap, gint ncolors) { GdkColormapPrivateWin32 *private; - GdkVisual *visual; XColor *palette; - gint shift; - int max_colors; - int size; int i; g_return_if_fail(colormap != NULL); @@ -1532,7 +1523,6 @@ gdk_colors_alloc(GdkColormap * colormap, gboolean gdk_color_parse(const gchar * spec, GdkColor * color) { Colormap xcolormap; - XColor xcolor; g_return_val_if_fail(spec != NULL, FALSE); g_return_val_if_fail(color != NULL, FALSE); @@ -1674,10 +1664,10 @@ gdk_colormap_alloc1(GdkColormap * colormap, } static gint -gdk_colormap_alloc_colors_writeable(GdkColormap * colormap, +gdk_colormap_alloc_colors_writable(GdkColormap * colormap, GdkColor * colors, gint ncolors, - gboolean writeable, + gboolean writable, gboolean best_match, gboolean * success) { @@ -1706,7 +1696,7 @@ gdk_colormap_alloc_colors_writeable(GdkColormap * colormap, return i; } else { pixels = g_new(gulong, ncolors); - /* Allocation of a writeable color cells */ + /* Allocation of a writable color cells */ status = alloc_color_cells(private->xcolormap, FALSE, NULL, 0, pixels, ncolors); @@ -1728,7 +1718,7 @@ static gint gdk_colormap_alloc_colors_private(GdkColormap * colormap, GdkColor * colors, gint ncolors, - gboolean writeable, + gboolean writable, gboolean best_match, gboolean * success) { GdkColormapPrivateWin32 *private; @@ -1801,7 +1791,7 @@ static gint gdk_colormap_alloc_colors_shared(GdkColormap * colormap, GdkColor * colors, gint ncolors, - gboolean writeable, + gboolean writable, gboolean best_match, gboolean * success) { GdkColormapPrivateWin32 *private; @@ -1878,7 +1868,7 @@ static gint gdk_colormap_alloc_colors_pseudocolor(GdkColormap * colormap, GdkColor * colors, gint ncolors, - gboolean writeable, + gboolean writable, gboolean best_match, gboolean * success) { @@ -1909,11 +1899,11 @@ gdk_colormap_alloc_colors_pseudocolor(GdkColormap * colormap, if (nremaining > 0) { if (private->private_val) return gdk_colormap_alloc_colors_private(colormap, colors, - ncolors, writeable, + ncolors, writable, best_match, success); else return gdk_colormap_alloc_colors_shared(colormap, colors, ncolors, - writeable, best_match, + writable, best_match, success); } else return 0; @@ -1923,7 +1913,7 @@ gint gdk_colormap_alloc_colors(GdkColormap * colormap, GdkColor * colors, gint ncolors, - gboolean writeable, + gboolean writable, gboolean best_match, gboolean * success) { GdkColormapPrivateWin32 *private; @@ -1944,13 +1934,13 @@ gdk_colormap_alloc_colors(GdkColormap * colormap, switch (private->base.visual->type) { case GDK_VISUAL_PSEUDO_COLOR: case GDK_VISUAL_GRAYSCALE: - if (writeable) - return gdk_colormap_alloc_colors_writeable(colormap, colors, - ncolors, writeable, + if (writable) + return gdk_colormap_alloc_colors_writable(colormap, colors, + ncolors, writable, best_match, success); else return gdk_colormap_alloc_colors_pseudocolor(colormap, colors, - ncolors, writeable, + ncolors, writable, best_match, success); break; diff --git a/graf2d/win32gdk/gdk/src/gdk/win32/gdkdnd-win32.c b/graf2d/win32gdk/gdk/src/gdk/win32/gdkdnd-win32.c index 2a6041abf2bae..b10fb20876df0 100644 --- a/graf2d/win32gdk/gdk/src/gdk/win32/gdkdnd-win32.c +++ b/graf2d/win32gdk/gdk/src/gdk/win32/gdkdnd-win32.c @@ -591,7 +591,7 @@ gdk_dropfiles_filter(GdkXEvent * xev, GdkEvent * event, gpointer data) MSG *msg = (MSG *) xev; HANDLE hdrop; POINT pt; - gint nfiles, i, k; + gint nfiles, i; guchar fileName[MAX_PATH], linkedFile[MAX_PATH]; if (text_uri_list_atom == GDK_NONE) @@ -658,7 +658,6 @@ gdk_dropfiles_filter(GdkXEvent * xev, GdkEvent * event, gpointer data) void gdk_dnd_init(void) { - HRESULT hres; #ifdef OLE2_DND hres = OleInitialize(NULL); diff --git a/graf2d/win32gdk/gdk/src/gdk/win32/gdkdrawable-win32.c b/graf2d/win32gdk/gdk/src/gdk/win32/gdkdrawable-win32.c index 319cbe670396e..b0c1a4bd7d1b0 100644 --- a/graf2d/win32gdk/gdk/src/gdk/win32/gdkdrawable-win32.c +++ b/graf2d/win32gdk/gdk/src/gdk/win32/gdkdrawable-win32.c @@ -177,7 +177,6 @@ gdk_win32_draw_rectangle(GdkDrawable * drawable, HDC hdc; HGDIOBJ oldpen_or_brush; POINT pts[4]; - HBRUSH stipple; gboolean ok = TRUE; GDK_NOTE(MISC, @@ -597,7 +596,7 @@ gdk_win32_draw_text_wc(GdkDrawable * drawable, gint y, const GdkWChar * text, gint text_length) { GdkGCPrivate *gc_private; - gint i, wlen; + gint i; wchar_t *wcstr; gdk_draw_text_arg arg; diff --git a/graf2d/win32gdk/gdk/src/gdk/win32/gdkevents-win32.c b/graf2d/win32gdk/gdk/src/gdk/win32/gdkevents-win32.c index 94fda911ac9b2..273c5688368ef 100644 --- a/graf2d/win32gdk/gdk/src/gdk/win32/gdkevents-win32.c +++ b/graf2d/win32gdk/gdk/src/gdk/win32/gdkevents-win32.c @@ -283,8 +283,6 @@ void gdk_events_init(void) { GSource *source; HRESULT hres; - HMODULE user32, imm32; - HINSTANCE commctrl32; gdk_ping_msg = RegisterWindowMessage("gdk-ping"); GDK_NOTE(EVENTS, g_print("gdk-ping = %#x\n", gdk_ping_msg)); @@ -389,8 +387,6 @@ gboolean gdk_events_pending(void) GdkEvent *gdk_event_get_graphics_expose(GdkWindow * window) { - MSG xevent; - GdkEvent *event; GdkWindowPrivate *private = (GdkWindowPrivate *) window; g_return_val_if_fail(window != NULL, NULL); @@ -686,7 +682,6 @@ gint gdk_key_grab(gint keycode, gint mod, GdkWindow * window) void gdk_key_ungrab(gint keycode, gint mod, GdkWindow * window) { _Gdk_key_mod *key_mod; - int i; if (window == NULL) return; if (!GDK_IS_WINDOW(window)) return; @@ -4212,7 +4207,6 @@ build_keypress_event(GdkWindowWin32Data * windata, bp = event->key.string; while (ucleft-- > 0) { int first; - int i; wchar_t c = *wcp++; if (c < 0x80) { @@ -4765,9 +4759,6 @@ gdk_event_translate(GdkEvent * event, MSG * xevent, gboolean * ret_val_flagp, gint * ret_valp) { - DWORD pidActWin; - DWORD pidThis; - DWORD dwStyle; PAINTSTRUCT paintstruct; HDC hdc; HDC bgdc; @@ -4781,15 +4772,12 @@ gdk_event_translate(GdkEvent * event, HCURSOR xcursor; GdkWindow *window, *orig_window, *newwindow; GdkColormapPrivateWin32 *colormap_private; - GdkEventMask mask; GdkPixmap *pixmap; GdkDrawablePrivate *pixmap_private; int button; - int i, j, n, k; + int i, j; gchar buf[256]; - gchar *msgname; gboolean return_val; - gboolean flag; return_val = FALSE; @@ -6462,10 +6450,7 @@ gdk_event_translate(GdkEvent * event, void gdk_events_queue(void) { - GList *node; - GdkEvent *event; MSG msg; - LRESULT lres; while (!gdk_event_queue_find_first() && PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) { diff --git a/graf2d/win32gdk/gdk/src/gdk/win32/gdkfont-win32.c b/graf2d/win32gdk/gdk/src/gdk/win32/gdkfont-win32.c index 8dd0d67197614..dff4fc0daf782 100644 --- a/graf2d/win32gdk/gdk/src/gdk/win32/gdkfont-win32.c +++ b/graf2d/win32gdk/gdk/src/gdk/win32/gdkfont-win32.c @@ -229,7 +229,7 @@ static gchar *logfont_to_xlfd(const LOGFONT * lfp, /* Convert the facename Windows fives us from the locale-dependent * codepage to UTF-8. */ - utf8_facename = g_filename_to_utf8(lfp->lfFaceName, NULL); + utf8_facename = g_filename_to_utf8(lfp->lfFaceName, -1, NULL, NULL, NULL); /* Replace characters illegal in an XLFD with hex escapes. */ p = facename; @@ -1103,7 +1103,7 @@ GdkWin32SingleFont *gdk_font_load_internal(const gchar * font_name) fdwClipPrecision = CLIP_DEFAULT_PRECIS; fdwQuality = PROOF_QUALITY; fdwPitchAndFamily = DEFAULT_PITCH; - lpszFace = g_filename_from_utf8(font_name, NULL); + lpszFace = g_filename_from_utf8(font_name, -1, NULL, NULL, NULL); } else if (numfields != 5) { g_warning("gdk_font_load: font name %s illegal", font_name); return NULL; @@ -1287,7 +1287,7 @@ GdkWin32SingleFont *gdk_font_load_internal(const gchar * font_name) fdwPitchAndFamily = VARIABLE_PITCH; else fdwPitchAndFamily = DEFAULT_PITCH; - lpszFace = g_filename_from_utf8(family, NULL); + lpszFace = g_filename_from_utf8(family, -1, NULL, NULL, NULL); } for (tries = 0;; tries++) { @@ -1385,7 +1385,6 @@ GdkFont *gdk_font_load(const gchar * font_name) GdkFontPrivateWin32 *private; GdkWin32SingleFont *singlefont; HGDIOBJ oldfont; - HANDLE *f; TEXTMETRIC textmetric; g_return_val_if_fail(font_name != NULL, NULL); @@ -1428,7 +1427,6 @@ GdkFont *gdk_fontset_load(const gchar * fontset_name) GdkFontPrivateWin32 *private; GdkWin32SingleFont *singlefont; HGDIOBJ oldfont; - HANDLE *f; TEXTMETRIC textmetric; GSList *base_font_list = NULL; gchar *fs; @@ -1611,7 +1609,7 @@ gdk_wchar_text_handle(GdkFont * font, GdkFontPrivateWin32 *private; GdkWin32SingleFont *singlefont; GSList *list; - int i, block; + int block; const wchar_t *start, *end, *wcp; wcp = wcstr; diff --git a/graf2d/win32gdk/gdk/src/gdk/win32/gdkim-win32.c b/graf2d/win32gdk/gdk/src/gdk/win32/gdkim-win32.c index d9f9e3730bc85..5eaf4537e55d7 100644 --- a/graf2d/win32gdk/gdk/src/gdk/win32/gdkim-win32.c +++ b/graf2d/win32gdk/gdk/src/gdk/win32/gdkim-win32.c @@ -161,7 +161,6 @@ gchar *gdk_wcstombs(const GdkWChar * src) bp = mbstr; while (*wcp) { int first; - int i; GdkWChar c = *wcp++; if (c < 0x80) { diff --git a/graf2d/win32gdk/gdk/src/gdk/win32/gdkmain-win32.c b/graf2d/win32gdk/gdk/src/gdk/win32/gdkmain-win32.c index 98c91ce0c69d8..879cd21b2792c 100644 --- a/graf2d/win32gdk/gdk/src/gdk/win32/gdkmain-win32.c +++ b/graf2d/win32gdk/gdk/src/gdk/win32/gdkmain-win32.c @@ -63,7 +63,6 @@ int __stdcall DllMain(HINSTANCE hinstDLL, DWORD dwReason, LPVOID reserved) gboolean _gdk_windowing_init_check(int argc, char **argv) { - gint i, j, k; if (getenv("GDK_IGNORE_WINTAB") != NULL) gdk_input_ignore_wintab = TRUE; diff --git a/graf2d/win32gdk/gdk/src/gdk/win32/gdkpixmap-win32.c b/graf2d/win32gdk/gdk/src/gdk/win32/gdkpixmap-win32.c index 9db6316a0a19d..a787ce4d585fe 100644 --- a/graf2d/win32gdk/gdk/src/gdk/win32/gdkpixmap-win32.c +++ b/graf2d/win32gdk/gdk/src/gdk/win32/gdkpixmap-win32.c @@ -874,7 +874,7 @@ GdkPixmap *gdk_pixmap_foreign_new(guint32 anid) GdkDrawablePrivate *private; HBITMAP xpixmap; SIZE size; - unsigned int x_ret, y_ret, w_ret, h_ret, bw_ret, depth_ret; + unsigned int w_ret, h_ret; /* check to make sure we were passed something at least a little sane */ diff --git a/graf2d/win32gdk/gdk/src/gdk/win32/gdkproperty-win32.c b/graf2d/win32gdk/gdk/src/gdk/win32/gdkproperty-win32.c index d73ba84392919..0686ea10596c3 100644 --- a/graf2d/win32gdk/gdk/src/gdk/win32/gdkproperty-win32.c +++ b/graf2d/win32gdk/gdk/src/gdk/win32/gdkproperty-win32.c @@ -208,7 +208,7 @@ gdk_property_change(GdkWindow * window, void gdk_property_delete(GdkWindow * window, GdkAtom property) { - gchar *prop_name, *type_name; + gchar *prop_name; extern void gdk_selection_property_delete(GdkWindow *); g_return_if_fail(window != NULL); diff --git a/graf2d/win32gdk/gdk/src/gdk/win32/gdkregion-win32.c b/graf2d/win32gdk/gdk/src/gdk/win32/gdkregion-win32.c index 31081ad00c239..8bb5afe6bd435 100644 --- a/graf2d/win32gdk/gdk/src/gdk/win32/gdkregion-win32.c +++ b/graf2d/win32gdk/gdk/src/gdk/win32/gdkregion-win32.c @@ -117,7 +117,6 @@ GdkOverlapType gdk_region_rect_in(GdkRegion * region, GdkRectangle * rect) { GdkRegionPrivate *private; RECT r; - int res; g_return_val_if_fail(region != NULL, 0); diff --git a/graf2d/win32gdk/gdk/src/gdk/win32/gdkselection-win32.c b/graf2d/win32gdk/gdk/src/gdk/win32/gdkselection-win32.c index 52731855da86a..623fd98736cb8 100644 --- a/graf2d/win32gdk/gdk/src/gdk/win32/gdkselection-win32.c +++ b/graf2d/win32gdk/gdk/src/gdk/win32/gdkselection-win32.c @@ -158,7 +158,6 @@ gdk_selection_convert(GdkWindow * requestor, GdkAtom selection, GdkAtom target, guint32 time) { HGLOBAL hdata; - GdkSelProp *prop; guchar *ptr, *data, *datap, *p; guint i, length, slength; gchar *sel_name, *tgt_name; diff --git a/graf2d/win32gdk/gdk/src/gdk/win32/gdkwindow-win32.c b/graf2d/win32gdk/gdk/src/gdk/win32/gdkwindow-win32.c index db84d576a4dce..96db3932ba0be 100644 --- a/graf2d/win32gdk/gdk/src/gdk/win32/gdkwindow-win32.c +++ b/graf2d/win32gdk/gdk/src/gdk/win32/gdkwindow-win32.c @@ -1214,7 +1214,6 @@ gdk_window_set_geometry_hints(GdkWindow * window, RECT rect; DWORD dwStyle; DWORD dwExStyle; - int diff; int maxw, maxh; g_return_if_fail(window != NULL); @@ -1317,10 +1316,6 @@ gdk_window_set_geometry_hints(GdkWindow * window, void gdk_window_set_title(GdkWindow * window, const gchar * title) { - gint titlelen; - wchar_t *wcstr; - gint wlen; - char *mbstr; g_return_if_fail(window != NULL); g_return_if_fail(GDK_IS_WINDOW(window)); @@ -1721,7 +1716,6 @@ GdkWindow *gdk_window_at_pointer(gint * win_x, gint * win_y) GList *gdk_window_get_children(GdkWindow * window) { - GdkWindowPrivate *private; GList *children; g_return_val_if_fail(window != NULL, NULL); @@ -1868,15 +1862,10 @@ gdk_window_set_icon(GdkWindow * window, icon_info.hbmMask = hbitmap_mask; icon_info.hbmColor = (HBITMAP) GDK_DRAWABLE_XID(pixmap); - hicon = (HICON)GetClassLong((HWND)GDK_DRAWABLE_XID(window), GCL_HICONSM); - if (hicon) DestroyIcon(hicon); - hicon = (HICON)GetClassLong((HWND)GDK_DRAWABLE_XID(window), GCL_HICON); - if (hicon) DestroyIcon(hicon); - hicon = CreateIconIndirect(&icon_info); - SetClassLong((HWND)GDK_DRAWABLE_XID(window), GCL_HICONSM, (LPARAM)CopyIcon(hicon)); - SetClassLong((HWND)GDK_DRAWABLE_XID(window), GCL_HICON, (LPARAM)CopyIcon(hicon)); + SendMessage((HWND)GDK_DRAWABLE_XID(window), WM_SETICON, ICON_BIG, (LPARAM)CopyIcon(hicon)); + SendMessage((HWND)GDK_DRAWABLE_XID(window), WM_SETICON, ICON_SMALL, (LPARAM)CopyIcon(hicon)); DestroyIcon(hicon); DeleteObject(hbitmap_mask); @@ -2020,7 +2009,6 @@ static void gdk_propagate_shapes(HANDLE win, gboolean merge) { RECT emptyRect; HRGN region, childRegion; - RECT rect; HWND *list = NULL; gint i, num; diff --git a/graf2d/win32gdk/gdk/src/glib/config.h b/graf2d/win32gdk/gdk/src/glib/config.h new file mode 100644 index 0000000000000..801c796b3d00a --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/config.h @@ -0,0 +1,182 @@ +/* config.h.win32. Handcrafted for Microsoft C and gcc -mno-cygwin */ + +#if ! (defined(_MSC_VER) || defined(__GNUC__)) +#error Unrecognized Win32 compiler, edit config.h.win32 by hand +#endif + +/* Define if using alloca.c. */ +/* #undef C_ALLOCA */ + +/* Define to empty if the keyword does not work. */ +/* #undef const */ + +/* Define to one of _getb67, GETB67, getb67 for Cray-2 and Cray-YMP systems. + This function is required for alloca.c support on those systems. */ +/* #undef CRAY_STACKSEG_END */ + +/* Define if you have a working `mmap' system call. */ +/* #undef HAVE_MMAP */ + +/* Define to empty, or __inline if that's what your compiler wants. */ +#define inline __inline + +/* Define to `long' if <sys/types.h> doesn't define. */ +/* #undef off_t */ + +/* Define if you need to in order for stat and other things to work. */ +/* #undef _POSIX_SOURCE*/ + +/* Define as the return type of signal handlers (int or void). */ +#define RETSIGTYPE void + +/* Define to `unsigned' if <sys/types.h> doesn't define. */ +/* #undef size_t */ + +/* If using the C implementation of alloca, define if you know the + direction of stack growth for your system; otherwise it will be + automatically deduced at run-time. + STACK_DIRECTION > 0 => grows toward higher addresses + STACK_DIRECTION < 0 => grows toward lower addresses + STACK_DIRECTION = 0 => direction of growth unknown + */ +/* #undef STACK_DIRECTION */ + +/* Define if you have the ANSI C header files. */ +#define STDC_HEADERS 1 + +/* Other stuff */ +//#define ENABLE_NLS 1 +#define GTK_COMPILED_WITH_DEBUGGING "minimum" + +/* #undef HAVE_CATGETS */ +/* #undef HAVE_DIRENT_H */ +#define HAVE_GETTEXT 1 +/* #undef HAVE_IPC_H */ +/* #undef HAVE_LC_MESSAGES */ +/* #undef HAVE_PWD_H */ +/* #undef HAVE_SHM_H */ +/* #undef HAVE_STPCPY */ +/* #undef HAVE_XSHM_H */ +#define HAVE_SHAPE_EXT 1 +/* #undef HAVE_SYS_SELECT_H */ +/* #undef HAVE_SYS_TIME_H */ +/* #undef HAVE_XCONVERTCASE */ + +/* #undef NO_FD_SET */ + +/* #undef XINPUT_NONE */ +/* #undef XINPUT_GXI */ +/* #undef XINPUT_XFREE */ +#define XINPUT_WIN32 1 + +/* Define as the return type of signal handlers (int or void). */ +#define RETSIGTYPE void + +/* Define if you have the __argz_count function. */ +/* #undef HAVE___ARGZ_COUNT */ + +/* Define if you have the __argz_next function. */ +/* #undef HAVE___ARGZ_NEXT */ + +/* Define if you have the __argz_stringify function. */ +/* #undef HAVE___ARGZ_STRINGIFY */ + +/* Define if you have the broken_wctype function. */ +/* #undef HAVE_BROKEN_WCTYPE */ + +/* Define if you have the dcgettext function. */ +/* #undef HAVE_DCGETTEXT */ + +/* Define if you have the getcwd function. */ +#define HAVE_GETCWD 1 + +/* Define if you have the getpagesize function. */ +#define HAVE_GETPAGESIZE 1 + +/* Define if you have the lstat function. */ +/* #undef HAVE_LSTAT */ + +/* Define if you have the munmap function. */ +/* #undef HAVE_MUNMAP */ + +/* Define if you have the putenv function. */ +#define HAVE_PUTENV 1 +#define putenv _putenv + +/* Define if you have the setenv function. */ +/* #undef HAVE_SETENV */ + +/* Define if you have the setlocale function. */ +#define HAVE_SETLOCALE 1 + +/* Define if you have the stpcpy function. */ +/* #undef HAVE_STPCPY */ + +/* Define if you have the strcasecmp function. */ +#define HAVE_STRCASECMP 1 +#define strcasecmp _stricmp + +/* Define if you have the strchr function. */ +#define HAVE_STRCHR 1 + +/* Define if you have the strdup function. */ +#define HAVE_STRDUP 1 + +/* Define if you have the <argz.h> header file. */ +/* #undef HAVE_ARGZ_H */ + +/* Define if you have the <dirent.h> header file. */ +/* #undef HAVE_DIRENT_H */ + +/* Define if you have the <limits.h> header file. */ +#define HAVE_LIMITS_H 1 + +/* Define if you have the <locale.h> header file. */ +#define HAVE_LOCALE_H 1 + +/* Define if you have the <malloc.h> header file. */ +#define HAVE_MALLOC_H 1 + +/* Define if you have the <nl_types.h> header file. */ +/* #undef HAVE_NL_TYPES_H */ + +/* Define if you have the <pwd.h> header file. */ +/* #undef HAVE_PWD_H */ + +/* Define if you have the <string.h> header file. */ +#define HAVE_STRING_H 1 + +/* Define if you have the <sys/param.h> header file. */ +/* #undef HAVE_SYS_PARAM_H */ + +/* Define if you have the <sys/time.h> header file. */ +/* #undef HAVE_SYS_TIME_H */ + +/* Define if you have the <unistd.h> header file. */ +/* #undef HAVE_UNISTD_H */ + +/* Define if you have the <wchar.h> header file. */ +#define HAVE_WCHAR_H 1 + +/* Define if you have the <wctype.h> header file. */ +#ifdef _MSC_VER +#define HAVE_WCTYPE_H 1 +#endif /* _MSC_VER */ + +/* Define if you have the i library (-li). */ +/* #undef HAVE_LIBI */ + +/* Define if you have the intl library (-lintl). */ +/*#define HAVE_LIBINTL 1*/ + +/* define if compiled symbols have a leading underscore */ +/* #undef WITH_SYMBOL_UNDERSCORE */ + +/* Define if you have the Wintab programmer's kit */ +/* #define HAVE_WINTAB 1 */ +#undef HAVE_WINTAB + +/* Define if you have the <dimm.h> header file + * (available in the Platform SDK) +*/ +/* #define HAVE_DIMM_H 1 */ diff --git a/graf2d/win32gdk/gdk/src/glib/config.h.win32 b/graf2d/win32gdk/gdk/src/glib/config.h.win32 new file mode 100644 index 0000000000000..801c796b3d00a --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/config.h.win32 @@ -0,0 +1,182 @@ +/* config.h.win32. Handcrafted for Microsoft C and gcc -mno-cygwin */ + +#if ! (defined(_MSC_VER) || defined(__GNUC__)) +#error Unrecognized Win32 compiler, edit config.h.win32 by hand +#endif + +/* Define if using alloca.c. */ +/* #undef C_ALLOCA */ + +/* Define to empty if the keyword does not work. */ +/* #undef const */ + +/* Define to one of _getb67, GETB67, getb67 for Cray-2 and Cray-YMP systems. + This function is required for alloca.c support on those systems. */ +/* #undef CRAY_STACKSEG_END */ + +/* Define if you have a working `mmap' system call. */ +/* #undef HAVE_MMAP */ + +/* Define to empty, or __inline if that's what your compiler wants. */ +#define inline __inline + +/* Define to `long' if <sys/types.h> doesn't define. */ +/* #undef off_t */ + +/* Define if you need to in order for stat and other things to work. */ +/* #undef _POSIX_SOURCE*/ + +/* Define as the return type of signal handlers (int or void). */ +#define RETSIGTYPE void + +/* Define to `unsigned' if <sys/types.h> doesn't define. */ +/* #undef size_t */ + +/* If using the C implementation of alloca, define if you know the + direction of stack growth for your system; otherwise it will be + automatically deduced at run-time. + STACK_DIRECTION > 0 => grows toward higher addresses + STACK_DIRECTION < 0 => grows toward lower addresses + STACK_DIRECTION = 0 => direction of growth unknown + */ +/* #undef STACK_DIRECTION */ + +/* Define if you have the ANSI C header files. */ +#define STDC_HEADERS 1 + +/* Other stuff */ +//#define ENABLE_NLS 1 +#define GTK_COMPILED_WITH_DEBUGGING "minimum" + +/* #undef HAVE_CATGETS */ +/* #undef HAVE_DIRENT_H */ +#define HAVE_GETTEXT 1 +/* #undef HAVE_IPC_H */ +/* #undef HAVE_LC_MESSAGES */ +/* #undef HAVE_PWD_H */ +/* #undef HAVE_SHM_H */ +/* #undef HAVE_STPCPY */ +/* #undef HAVE_XSHM_H */ +#define HAVE_SHAPE_EXT 1 +/* #undef HAVE_SYS_SELECT_H */ +/* #undef HAVE_SYS_TIME_H */ +/* #undef HAVE_XCONVERTCASE */ + +/* #undef NO_FD_SET */ + +/* #undef XINPUT_NONE */ +/* #undef XINPUT_GXI */ +/* #undef XINPUT_XFREE */ +#define XINPUT_WIN32 1 + +/* Define as the return type of signal handlers (int or void). */ +#define RETSIGTYPE void + +/* Define if you have the __argz_count function. */ +/* #undef HAVE___ARGZ_COUNT */ + +/* Define if you have the __argz_next function. */ +/* #undef HAVE___ARGZ_NEXT */ + +/* Define if you have the __argz_stringify function. */ +/* #undef HAVE___ARGZ_STRINGIFY */ + +/* Define if you have the broken_wctype function. */ +/* #undef HAVE_BROKEN_WCTYPE */ + +/* Define if you have the dcgettext function. */ +/* #undef HAVE_DCGETTEXT */ + +/* Define if you have the getcwd function. */ +#define HAVE_GETCWD 1 + +/* Define if you have the getpagesize function. */ +#define HAVE_GETPAGESIZE 1 + +/* Define if you have the lstat function. */ +/* #undef HAVE_LSTAT */ + +/* Define if you have the munmap function. */ +/* #undef HAVE_MUNMAP */ + +/* Define if you have the putenv function. */ +#define HAVE_PUTENV 1 +#define putenv _putenv + +/* Define if you have the setenv function. */ +/* #undef HAVE_SETENV */ + +/* Define if you have the setlocale function. */ +#define HAVE_SETLOCALE 1 + +/* Define if you have the stpcpy function. */ +/* #undef HAVE_STPCPY */ + +/* Define if you have the strcasecmp function. */ +#define HAVE_STRCASECMP 1 +#define strcasecmp _stricmp + +/* Define if you have the strchr function. */ +#define HAVE_STRCHR 1 + +/* Define if you have the strdup function. */ +#define HAVE_STRDUP 1 + +/* Define if you have the <argz.h> header file. */ +/* #undef HAVE_ARGZ_H */ + +/* Define if you have the <dirent.h> header file. */ +/* #undef HAVE_DIRENT_H */ + +/* Define if you have the <limits.h> header file. */ +#define HAVE_LIMITS_H 1 + +/* Define if you have the <locale.h> header file. */ +#define HAVE_LOCALE_H 1 + +/* Define if you have the <malloc.h> header file. */ +#define HAVE_MALLOC_H 1 + +/* Define if you have the <nl_types.h> header file. */ +/* #undef HAVE_NL_TYPES_H */ + +/* Define if you have the <pwd.h> header file. */ +/* #undef HAVE_PWD_H */ + +/* Define if you have the <string.h> header file. */ +#define HAVE_STRING_H 1 + +/* Define if you have the <sys/param.h> header file. */ +/* #undef HAVE_SYS_PARAM_H */ + +/* Define if you have the <sys/time.h> header file. */ +/* #undef HAVE_SYS_TIME_H */ + +/* Define if you have the <unistd.h> header file. */ +/* #undef HAVE_UNISTD_H */ + +/* Define if you have the <wchar.h> header file. */ +#define HAVE_WCHAR_H 1 + +/* Define if you have the <wctype.h> header file. */ +#ifdef _MSC_VER +#define HAVE_WCTYPE_H 1 +#endif /* _MSC_VER */ + +/* Define if you have the i library (-li). */ +/* #undef HAVE_LIBI */ + +/* Define if you have the intl library (-lintl). */ +/*#define HAVE_LIBINTL 1*/ + +/* define if compiled symbols have a leading underscore */ +/* #undef WITH_SYMBOL_UNDERSCORE */ + +/* Define if you have the Wintab programmer's kit */ +/* #define HAVE_WINTAB 1 */ +#undef HAVE_WINTAB + +/* Define if you have the <dimm.h> header file + * (available in the Platform SDK) +*/ +/* #define HAVE_DIMM_H 1 */ diff --git a/graf2d/win32gdk/gdk/src/glib/galloca.h b/graf2d/win32gdk/gdk/src/glib/galloca.h index 703802b58b2c1..7bc0a5fa34b63 100644 --- a/graf2d/win32gdk/gdk/src/glib/galloca.h +++ b/graf2d/win32gdk/gdk/src/glib/galloca.h @@ -27,7 +27,7 @@ #ifndef __G_ALLOCA_H__ #define __G_ALLOCA_H__ -#include <g_types.h> +#include <glib/gtypes.h> #ifdef __GNUC__ /* GCC does the right thing */ diff --git a/graf2d/win32gdk/gdk/src/glib/garray.c b/graf2d/win32gdk/gdk/src/glib/garray.c new file mode 100644 index 0000000000000..9a5758f8854dd --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/garray.c @@ -0,0 +1,670 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <string.h> +#include <stdlib.h> +#include "glib.h" + + +#define MIN_ARRAY_SIZE 16 + +typedef struct _GRealArray GRealArray; + +struct _GRealArray +{ + guint8 *data; + guint len; + guint alloc; + guint elt_size; + guint zero_terminated : 1; + guint clear : 1; +}; + +#define g_array_elt_len(array,i) ((array)->elt_size * (i)) +#define g_array_elt_pos(array,i) ((array)->data + g_array_elt_len((array),(i))) +#define g_array_elt_zero(array, pos, len) \ + (memset (g_array_elt_pos ((array), pos), 0, g_array_elt_len ((array), len))) +#define g_array_zero_terminate(array) G_STMT_START{ \ + if ((array)->zero_terminated) \ + g_array_elt_zero ((array), (array)->len, 1); \ +}G_STMT_END + +static gint g_nearest_pow (gint num) G_GNUC_CONST; +static void g_array_maybe_expand (GRealArray *array, + gint len); + +static GMemChunk *array_mem_chunk = NULL; +G_LOCK_DEFINE_STATIC (array_mem_chunk); + +GArray* +g_array_new (gboolean zero_terminated, + gboolean clear, + guint elt_size) +{ + return (GArray*) g_array_sized_new (zero_terminated, clear, elt_size, 0); +} + +GArray* g_array_sized_new (gboolean zero_terminated, + gboolean clear, + guint elt_size, + guint reserved_size) +{ + GRealArray *array; + + G_LOCK (array_mem_chunk); + if (!array_mem_chunk) + array_mem_chunk = g_mem_chunk_new ("array mem chunk", + sizeof (GRealArray), + 1024, G_ALLOC_AND_FREE); + + array = g_chunk_new (GRealArray, array_mem_chunk); + G_UNLOCK (array_mem_chunk); + + array->data = NULL; + array->len = 0; + array->alloc = 0; + array->zero_terminated = (zero_terminated ? 1 : 0); + array->clear = (clear ? 1 : 0); + array->elt_size = elt_size; + + if (array->zero_terminated || reserved_size != 0) + { + g_array_maybe_expand (array, reserved_size); + g_array_zero_terminate(array); + } + + return (GArray*) array; +} + +gchar* +g_array_free (GArray *array, + gboolean free_segment) +{ + gchar* segment; + + g_return_val_if_fail (array, NULL); + + if (free_segment) + { + g_free (array->data); + segment = NULL; + } + else + segment = array->data; + + G_LOCK (array_mem_chunk); + g_mem_chunk_free (array_mem_chunk, array); + G_UNLOCK (array_mem_chunk); + + return segment; +} + +GArray* +g_array_append_vals (GArray *farray, + gconstpointer data, + guint len) +{ + GRealArray *array = (GRealArray*) farray; + + g_array_maybe_expand (array, len); + + memcpy (g_array_elt_pos (array, array->len), data, + g_array_elt_len (array, len)); + + array->len += len; + + g_array_zero_terminate (array); + + return farray; +} + +GArray* +g_array_prepend_vals (GArray *farray, + gconstpointer data, + guint len) +{ + GRealArray *array = (GRealArray*) farray; + + g_array_maybe_expand (array, len); + + g_memmove (g_array_elt_pos (array, len), g_array_elt_pos (array, 0), + g_array_elt_len (array, array->len)); + + memcpy (g_array_elt_pos (array, 0), data, g_array_elt_len (array, len)); + + array->len += len; + + g_array_zero_terminate (array); + + return farray; +} + +GArray* +g_array_insert_vals (GArray *farray, + guint index, + gconstpointer data, + guint len) +{ + GRealArray *array = (GRealArray*) farray; + + g_array_maybe_expand (array, len); + + g_memmove (g_array_elt_pos (array, len + index), + g_array_elt_pos (array, index), + g_array_elt_len (array, array->len - index)); + + memcpy (g_array_elt_pos (array, index), data, g_array_elt_len (array, len)); + + array->len += len; + + g_array_zero_terminate (array); + + return farray; +} + +GArray* +g_array_set_size (GArray *farray, + guint length) +{ + GRealArray *array = (GRealArray*) farray; + if (length > array->len) + { + g_array_maybe_expand (array, length - array->len); + + if (array->clear) + g_array_elt_zero (array, array->len, length - array->len); + } +#ifdef ENABLE_GC_FRIENDLY + else if (length < array->len) + g_array_elt_zero (array, length, array->len - length); +#endif /* ENABLE_GC_FRIENDLY */ + + array->len = length; + + g_array_zero_terminate (array); + + return farray; +} + +GArray* +g_array_remove_index (GArray* farray, + guint index) +{ + GRealArray* array = (GRealArray*) farray; + + g_return_val_if_fail (array, NULL); + + g_return_val_if_fail (index < array->len, NULL); + + if (index != array->len - 1) + g_memmove (g_array_elt_pos (array, index), + g_array_elt_pos (array, index + 1), + g_array_elt_len (array, array->len - index - 1)); + + array->len -= 1; + +#ifdef ENABLE_GC_FRIENDLY + g_array_elt_zero (array, array->len, 1); +#else /* !ENABLE_GC_FRIENDLY */ + g_array_zero_terminate (array); +#endif /* ENABLE_GC_FRIENDLY */ + + return farray; +} + +GArray* +g_array_remove_index_fast (GArray* farray, + guint index) +{ + GRealArray* array = (GRealArray*) farray; + + g_return_val_if_fail (array, NULL); + + g_return_val_if_fail (index < array->len, NULL); + + if (index != array->len - 1) + memcpy (g_array_elt_pos (array, index), + g_array_elt_pos (array, array->len - 1), + g_array_elt_len (array, 1)); + + array->len -= 1; + +#ifdef ENABLE_GC_FRIENDLY + g_array_elt_zero (array, array->len, 1); +#else /* !ENABLE_GC_FRIENDLY */ + g_array_zero_terminate (array); +#endif /* ENABLE_GC_FRIENDLY */ + + return farray; +} + +void +g_array_sort (GArray *farray, + GCompareFunc compare_func) +{ + GRealArray *array = (GRealArray*) farray; + + g_return_if_fail (array != NULL); + g_return_if_fail (array->data != NULL); + + qsort (array->data, + array->len, + array->elt_size, + compare_func); +} + +void +g_array_sort_with_data (GArray *farray, + GCompareDataFunc compare_func, + gpointer user_data) +{ + GRealArray *array = (GRealArray*) farray; + + g_return_if_fail (array != NULL); + g_return_if_fail (array->data != NULL); + + g_qsort_with_data (array->data, + array->len, + array->elt_size, + compare_func, + user_data); +} + + +static gint +g_nearest_pow (gint num) +{ + gint n = 1; + + while (n < num) + n <<= 1; + + return n; +} + +static void +g_array_maybe_expand (GRealArray *array, + gint len) +{ + guint want_alloc = g_array_elt_len (array, array->len + len + + array->zero_terminated); + + if (want_alloc > array->alloc) + { + want_alloc = g_nearest_pow (want_alloc); + want_alloc = MAX (want_alloc, MIN_ARRAY_SIZE); + + array->data = g_realloc (array->data, want_alloc); + +#ifdef ENABLE_GC_FRIENDLY + memset (array->data + array->alloc, 0, want_alloc - array->alloc); +#endif /* ENABLE_GC_FRIENDLY */ + + array->alloc = want_alloc; + } +} + +/* Pointer Array + */ + +typedef struct _GRealPtrArray GRealPtrArray; + +struct _GRealPtrArray +{ + gpointer *pdata; + guint len; + guint alloc; +}; + +static void g_ptr_array_maybe_expand (GRealPtrArray *array, + gint len); + +static GMemChunk *ptr_array_mem_chunk = NULL; +G_LOCK_DEFINE_STATIC (ptr_array_mem_chunk); + + +GPtrArray* +g_ptr_array_new (void) +{ + return g_ptr_array_sized_new (0); +} + +GPtrArray* +g_ptr_array_sized_new (guint reserved_size) +{ + GRealPtrArray *array; + + G_LOCK (ptr_array_mem_chunk); + if (!ptr_array_mem_chunk) + ptr_array_mem_chunk = g_mem_chunk_new ("array mem chunk", + sizeof (GRealPtrArray), + 1024, G_ALLOC_AND_FREE); + + array = g_chunk_new (GRealPtrArray, ptr_array_mem_chunk); + G_UNLOCK (ptr_array_mem_chunk); + + array->pdata = NULL; + array->len = 0; + array->alloc = 0; + + if (reserved_size != 0) + g_ptr_array_maybe_expand (array, reserved_size); + + return (GPtrArray*) array; +} + +gpointer* +g_ptr_array_free (GPtrArray *array, + gboolean free_segment) +{ + gpointer* segment; + + g_return_val_if_fail (array, NULL); + + if (free_segment) + { + g_free (array->pdata); + segment = NULL; + } + else + segment = array->pdata; + + G_LOCK (ptr_array_mem_chunk); + g_mem_chunk_free (ptr_array_mem_chunk, array); + G_UNLOCK (ptr_array_mem_chunk); + + return segment; +} + +static void +g_ptr_array_maybe_expand (GRealPtrArray *array, + gint len) +{ + if ((array->len + len) > array->alloc) + { +#ifdef ENABLE_GC_FRIENDLY + guint old_alloc = array->alloc; +#endif /* ENABLE_GC_FRIENDLY */ + array->alloc = g_nearest_pow (array->len + len); + array->alloc = MAX (array->alloc, MIN_ARRAY_SIZE); + array->pdata = g_realloc (array->pdata, sizeof(gpointer) * array->alloc); +#ifdef ENABLE_GC_FRIENDLY + for ( ; old_alloc < array->alloc; old_alloc++) + array->pdata [old_alloc] = NULL; +#endif /* ENABLE_GC_FRIENDLY */ + } +} + +void +g_ptr_array_set_size (GPtrArray *farray, + gint length) +{ + GRealPtrArray* array = (GRealPtrArray*) farray; + + g_return_if_fail (array); + + if (length > array->len) + { + int i; + g_ptr_array_maybe_expand (array, (length - array->len)); + /* This is not + * memset (array->pdata + array->len, 0, + * sizeof (gpointer) * (length - array->len)); + * to make it really portable. Remember (void*)NULL needn't be + * bitwise zero. It of course is silly not to use memset (..,0,..). + */ + for (i = array->len; i < length; i++) + array->pdata[i] = NULL; + } +#ifdef ENABLE_GC_FRIENDLY + else if (length < array->len) + { + int i; + for (i = length; i < array->len; i++) + array->pdata[i] = NULL; + } +#endif /* ENABLE_GC_FRIENDLY */ + + array->len = length; +} + +gpointer +g_ptr_array_remove_index (GPtrArray* farray, + guint index) +{ + GRealPtrArray* array = (GRealPtrArray*) farray; + gpointer result; + + g_return_val_if_fail (array, NULL); + + g_return_val_if_fail (index < array->len, NULL); + + result = array->pdata[index]; + + if (index != array->len - 1) + g_memmove (array->pdata + index, array->pdata + index + 1, + sizeof (gpointer) * (array->len - index - 1)); + + array->len -= 1; + +#ifdef ENABLE_GC_FRIENDLY + array->pdata[array->len] = NULL; +#endif /* ENABLE_GC_FRIENDLY */ + + return result; +} + +gpointer +g_ptr_array_remove_index_fast (GPtrArray* farray, + guint index) +{ + GRealPtrArray* array = (GRealPtrArray*) farray; + gpointer result; + + g_return_val_if_fail (array, NULL); + + g_return_val_if_fail (index < array->len, NULL); + + result = array->pdata[index]; + + if (index != array->len - 1) + array->pdata[index] = array->pdata[array->len - 1]; + + array->len -= 1; + +#ifdef ENABLE_GC_FRIENDLY + array->pdata[array->len] = NULL; +#endif /* ENABLE_GC_FRIENDLY */ + + return result; +} + +gboolean +g_ptr_array_remove (GPtrArray* farray, + gpointer data) +{ + GRealPtrArray* array = (GRealPtrArray*) farray; + guint i; + + g_return_val_if_fail (array, FALSE); + + for (i = 0; i < array->len; i += 1) + { + if (array->pdata[i] == data) + { + g_ptr_array_remove_index (farray, i); + return TRUE; + } + } + + return FALSE; +} + +gboolean +g_ptr_array_remove_fast (GPtrArray* farray, + gpointer data) +{ + GRealPtrArray* array = (GRealPtrArray*) farray; + guint i; + + g_return_val_if_fail (array, FALSE); + + for (i = 0; i < array->len; i += 1) + { + if (array->pdata[i] == data) + { + g_ptr_array_remove_index_fast (farray, i); + return TRUE; + } + } + + return FALSE; +} + +void +g_ptr_array_add (GPtrArray* farray, + gpointer data) +{ + GRealPtrArray* array = (GRealPtrArray*) farray; + + g_return_if_fail (array); + + g_ptr_array_maybe_expand (array, 1); + + array->pdata[array->len++] = data; +} + +void +g_ptr_array_sort (GPtrArray *array, + GCompareFunc compare_func) +{ + g_return_if_fail (array != NULL); + g_return_if_fail (array->pdata != NULL); + + qsort (array->pdata, + array->len, + sizeof (gpointer), + compare_func); +} + +void +g_ptr_array_sort_with_data (GPtrArray *array, + GCompareDataFunc compare_func, + gpointer user_data) +{ + g_return_if_fail (array != NULL); + g_return_if_fail (array->pdata != NULL); + + g_qsort_with_data (array->pdata, + array->len, + sizeof (gpointer), + compare_func, + user_data); +} + +/* Byte arrays + */ + +GByteArray* g_byte_array_new (void) +{ + return (GByteArray*) g_array_sized_new (FALSE, FALSE, 1, 0); +} + +GByteArray* g_byte_array_sized_new (guint reserved_size) +{ + return (GByteArray*) g_array_sized_new (FALSE, FALSE, 1, reserved_size); +} + +guint8* g_byte_array_free (GByteArray *array, + gboolean free_segment) +{ + return (guint8*) g_array_free ((GArray*) array, free_segment); +} + +GByteArray* g_byte_array_append (GByteArray *array, + const guint8 *data, + guint len) +{ + g_array_append_vals ((GArray*) array, (guint8*)data, len); + + return array; +} + +GByteArray* g_byte_array_prepend (GByteArray *array, + const guint8 *data, + guint len) +{ + g_array_prepend_vals ((GArray*) array, (guint8*)data, len); + + return array; +} + +GByteArray* g_byte_array_set_size (GByteArray *array, + guint length) +{ + g_array_set_size ((GArray*) array, length); + + return array; +} + +GByteArray* g_byte_array_remove_index (GByteArray *array, + guint index) +{ + g_array_remove_index((GArray*) array, index); + + return array; +} + +GByteArray* g_byte_array_remove_index_fast (GByteArray *array, + guint index) +{ + g_array_remove_index_fast((GArray*) array, index); + + return array; +} + +void +g_byte_array_sort (GByteArray *array, + GCompareFunc compare_func) +{ + g_array_sort ((GArray *) array, compare_func); +} + +void +g_byte_array_sort_with_data (GByteArray *array, + GCompareDataFunc compare_func, + gpointer user_data) +{ + g_array_sort_with_data ((GArray *) array, compare_func, user_data); +} diff --git a/graf2d/win32gdk/gdk/src/glib/garray.h b/graf2d/win32gdk/gdk/src/glib/garray.h index 30189d06c9949..56b3937fef07a 100644 --- a/graf2d/win32gdk/gdk/src/glib/garray.h +++ b/graf2d/win32gdk/gdk/src/glib/garray.h @@ -27,7 +27,7 @@ #ifndef __G_ARRAY_H__ #define __G_ARRAY_H__ -#include <g_types.h> +#include <glib/gtypes.h> G_BEGIN_DECLS @@ -58,9 +58,9 @@ struct _GPtrArray * order by moving the last element to the position of the removed */ -#define g_array_append_val(a,v) g_array_append_vals (a, &v, 1) -#define g_array_prepend_val(a,v) g_array_prepend_vals (a, &v, 1) -#define g_array_insert_val(a,i,v) g_array_insert_vals (a, i, &v, 1) +#define g_array_append_val(a,v) g_array_append_vals (a, &(v), 1) +#define g_array_prepend_val(a,v) g_array_prepend_vals (a, &(v), 1) +#define g_array_insert_val(a,i,v) g_array_insert_vals (a, i, &(v), 1) #define g_array_index(a,t,i) (((t*) (a)->data) [(i)]) GArray* g_array_new (gboolean zero_terminated, @@ -91,7 +91,7 @@ GArray* g_array_remove_index_fast (GArray *array, void g_array_sort (GArray *array, GCompareFunc compare_func); void g_array_sort_with_data (GArray *array, - GCompareFuncData compare_func, + GCompareDataFunc compare_func, gpointer user_data); /* Resizable pointer array. This interface is much less complicated @@ -119,7 +119,7 @@ void g_ptr_array_add (GPtrArray *array, void g_ptr_array_sort (GPtrArray *array, GCompareFunc compare_func); void g_ptr_array_sort_with_data (GPtrArray *array, - GCompareFuncData compare_func, + GCompareDataFunc compare_func, gpointer user_data); @@ -146,7 +146,7 @@ GByteArray* g_byte_array_remove_index_fast (GByteArray *array, void g_byte_array_sort (GByteArray *array, GCompareFunc compare_func); void g_byte_array_sort_with_data (GByteArray *array, - GCompareFuncData compare_func, + GCompareDataFunc compare_func, gpointer user_data); diff --git a/graf2d/win32gdk/gdk/src/glib/gasyncqueue.c b/graf2d/win32gdk/gdk/src/glib/gasyncqueue.c new file mode 100644 index 0000000000000..cb966b0ee0dfc --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gasyncqueue.c @@ -0,0 +1,443 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * GAsyncQueue: asynchronous queue implementation, based on Gqueue. + * Copyright (C) 2000 Sebastian Wilhelmi; University of Karlsruhe + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * MT safe + */ + +#include "glib.h" + +struct _GAsyncQueue +{ + GMutex *mutex; + GCond *cond; + GQueue *queue; + guint waiting_threads; + guint ref_count; +}; + +/** + * g_async_queue_new: + * + * Creates a new asynchronous queue with the initial reference count of 1. + * + * Return value: the new #GAsyncQueue. + **/ +GAsyncQueue* +g_async_queue_new () +{ + GAsyncQueue* retval = g_new (GAsyncQueue, 1); + retval->mutex = g_mutex_new (); + retval->cond = g_cond_new (); + retval->queue = g_queue_new (); + retval->waiting_threads = 0; + retval->ref_count = 1; + return retval; +} + +/** + * g_async_queue_ref: + * @queue: a #GAsyncQueue. + * + * Increases the reference count of the asynchronous @queue by 1. + **/ +void +g_async_queue_ref (GAsyncQueue *queue) +{ + g_return_if_fail (queue); + g_return_if_fail (queue->ref_count > 0); + + g_mutex_lock (queue->mutex); + queue->ref_count++; + g_mutex_unlock (queue->mutex); +} + +/** + * g_async_queue_ref_unlocked: + * @queue: a #GAsyncQueue. + * + * Increases the reference count of the asynchronous @queue by 1. This + * function must be called while holding the @queue's lock. + **/ +void +g_async_queue_ref_unlocked (GAsyncQueue *queue) +{ + g_return_if_fail (queue); + g_return_if_fail (queue->ref_count > 0); + + queue->ref_count++; +} + +/** + * g_async_queue_unref_and_unlock: + * @queue: a #GAsyncQueue. + * + * Decreases the reference count of the asynchronous @queue by 1 and + * releases the lock. This function must be called while holding the + * @queue's lock. If the reference count went to 0, the @queue will be + * destroyed and the memory allocated will be freed. So you are not + * allowed to use the @queue afterwards, as it might have disappeared. + * The obvious asymmetry (it is not named + * g_async_queue_unref_unlocked) is because the queue can't be + * unlocked after dereffing it, as it might already have disappeared. + **/ +void +g_async_queue_unref_and_unlock (GAsyncQueue *queue) +{ + gboolean stop; + + g_return_if_fail (queue); + g_return_if_fail (queue->ref_count > 0); + + queue->ref_count--; + stop = (queue->ref_count == 0); + g_mutex_unlock (queue->mutex); + + if (stop) + { + g_return_if_fail (queue->waiting_threads == 0); + g_mutex_free (queue->mutex); + g_cond_free (queue->cond); + g_queue_free (queue->queue); + g_free (queue); + } +} + +/** + * g_async_queue_unref: + * @queue: a #GAsyncQueue. + * + * Decreases the reference count of the asynchronous @queue by 1. If + * the reference count went to 0, the @queue will be destroyed and the + * memory allocated will be freed. So you are not allowed to use the + * @queue afterwards, as it might have disappeared. + **/ +void +g_async_queue_unref (GAsyncQueue *queue) +{ + g_return_if_fail (queue); + g_return_if_fail (queue->ref_count > 0); + + g_mutex_lock (queue->mutex); + g_async_queue_unref_and_unlock (queue); +} + +/** + * g_async_queue_lock: + * @queue: a #GAsyncQueue. + * + * Acquire the @queue's lock. After that you can only call the + * g_async_queue_*_unlocked function variants on that + * @queue. Otherwise it will deadlock. + **/ +void +g_async_queue_lock (GAsyncQueue *queue) +{ + g_return_if_fail (queue); + g_return_if_fail (queue->ref_count > 0); + + g_mutex_lock (queue->mutex); +} + +/** + * g_async_queue_unlock: + * @queue: a #GAsyncQueue. + * + * Release the queue's lock. + **/ +void +g_async_queue_unlock (GAsyncQueue *queue) +{ + g_return_if_fail (queue); + g_return_if_fail (queue->ref_count > 0); + + g_mutex_unlock (queue->mutex); +} + +/** + * g_async_queue_push: + * @queue: a #GAsyncQueue. + * @data: @data to push into the @queue. + * + * Push the @data into the @queue. @data must not be #NULL. + **/ +void +g_async_queue_push (GAsyncQueue* queue, gpointer data) +{ + g_return_if_fail (queue); + g_return_if_fail (queue->ref_count > 0); + g_return_if_fail (data); + + g_mutex_lock (queue->mutex); + g_async_queue_push_unlocked (queue, data); + g_mutex_unlock (queue->mutex); +} + +/** + * g_async_queue_push_unlocked: + * @queue: a #GAsyncQueue. + * @data: @data to push into the @queue. + * + * Push the @data into the @queue. @data must not be #NULL. This + * function must be called while holding the @queue's lock. + **/ +void +g_async_queue_push_unlocked (GAsyncQueue* queue, gpointer data) +{ + g_return_if_fail (queue); + g_return_if_fail (queue->ref_count > 0); + g_return_if_fail (data); + + g_queue_push_head (queue->queue, data); + g_cond_signal (queue->cond); +} + +static gpointer +g_async_queue_pop_intern_unlocked (GAsyncQueue* queue, gboolean tryit, + GTimeVal *end_time) +{ + gpointer retval; + + if (!g_queue_peek_tail (queue->queue)) + { + if (tryit) + return NULL; + if (!end_time) + { + queue->waiting_threads++; + while (!g_queue_peek_tail (queue->queue)) + g_cond_wait(queue->cond, queue->mutex); + queue->waiting_threads--; + } + else + { + queue->waiting_threads++; + while (!g_queue_peek_tail (queue->queue)) + if (!g_cond_timed_wait (queue->cond, queue->mutex, end_time)) + break; + queue->waiting_threads--; + if (!g_queue_peek_tail (queue->queue)) + return NULL; + } + } + + retval = g_queue_pop_tail (queue->queue); + + g_assert (retval); + + return retval; +} + +/** + * g_async_queue_pop: + * @queue: a #GAsyncQueue. + * + * Pop data from the @queue. This function blocks until data become + * available. + * + * Return value: data from the queue. + **/ +gpointer +g_async_queue_pop (GAsyncQueue* queue) +{ + gpointer retval; + + g_return_val_if_fail (queue, NULL); + g_return_val_if_fail (queue->ref_count > 0, NULL); + + g_mutex_lock (queue->mutex); + retval = g_async_queue_pop_intern_unlocked (queue, FALSE, NULL); + g_mutex_unlock (queue->mutex); + + return retval; +} + +/** + * g_async_queue_pop_unlocked: + * @queue: a #GAsyncQueue. + * + * Pop data from the @queue. This function blocks until data become + * available. This function must be called while holding the @queue's + * lock. + * + * Return value: data from the queue. + **/ +gpointer +g_async_queue_pop_unlocked (GAsyncQueue* queue) +{ + g_return_val_if_fail (queue, NULL); + g_return_val_if_fail (queue->ref_count > 0, NULL); + + return g_async_queue_pop_intern_unlocked (queue, FALSE, NULL); +} + +/** + * g_async_queue_try_pop: + * @queue: a #GAsyncQueue. + * + * Try to pop data from the @queue. If no data is available, #NULL is + * returned. + * + * Return value: data from the queue or #NULL, when no data is + * available immediately. + **/ +gpointer +g_async_queue_try_pop (GAsyncQueue* queue) +{ + gpointer retval; + + g_return_val_if_fail (queue, NULL); + g_return_val_if_fail (queue->ref_count > 0, NULL); + + g_mutex_lock (queue->mutex); + retval = g_async_queue_pop_intern_unlocked (queue, TRUE, NULL); + g_mutex_unlock (queue->mutex); + + return retval; +} + +/** + * g_async_queue_try_pop_unlocked: + * @queue: a #GAsyncQueue. + * + * Try to pop data from the @queue. If no data is available, #NULL is + * returned. This function must be called while holding the @queue's + * lock. + * + * Return value: data from the queue or #NULL, when no data is + * available immediately. + **/ +gpointer +g_async_queue_try_pop_unlocked (GAsyncQueue* queue) +{ + g_return_val_if_fail (queue, NULL); + g_return_val_if_fail (queue->ref_count > 0, NULL); + + return g_async_queue_pop_intern_unlocked (queue, TRUE, NULL); +} + +/** + * g_async_queue_timed_pop: + * @queue: a #GAsyncQueue. + * @end_time: a #GTimeVal, determining the final time. + * + * Pop data from the @queue. If no data is received before @end_time, + * #NULL is returned. + * + * To easily calculate @end_time a combination of g_get_current_time() + * and g_time_val_add() can be used. + * + * Return value: data from the queue or #NULL, when no data is + * received before @end_time. + **/ +gpointer +g_async_queue_timed_pop (GAsyncQueue* queue, GTimeVal *end_time) +{ + gpointer retval; + + g_return_val_if_fail (queue, NULL); + g_return_val_if_fail (queue->ref_count > 0, NULL); + + g_mutex_lock (queue->mutex); + retval = g_async_queue_pop_intern_unlocked (queue, FALSE, end_time); + g_mutex_unlock (queue->mutex); + + return retval; +} + +/** + * g_async_queue_timed_pop_unlocked: + * @queue: a #GAsyncQueue. + * @end_time: a #GTimeVal, determining the final time. + * + * Pop data from the @queue. If no data is received before @end_time, + * #NULL is returned. This function must be called while holding the + * @queue's lock. + * + * To easily calculate @end_time a combination of g_get_current_time() + * and g_time_val_add() can be used. + * + * Return value: data from the queue or #NULL, when no data is + * received before @end_time. + **/ +gpointer +g_async_queue_timed_pop_unlocked (GAsyncQueue* queue, GTimeVal *end_time) +{ + g_return_val_if_fail (queue, NULL); + g_return_val_if_fail (queue->ref_count > 0, NULL); + + return g_async_queue_pop_intern_unlocked (queue, FALSE, end_time); +} + +/** + * g_async_queue_length: + * @queue: a #GAsyncQueue. + * + * Returns the length of the queue, negative values mean waiting + * threads, positive values mean available entries in the + * @queue. Actually this function returns the number of data items in + * the queue minus the number of waiting threads. Thus a return value + * of 0 could mean 'n' entries in the queue and 'n' thread waiting. + * That can happen due to locking of the queue or due to + * scheduling. + * + * Return value: the length of the @queue. + **/ +gint +g_async_queue_length (GAsyncQueue* queue) +{ + gint retval; + + g_return_val_if_fail (queue, 0); + g_return_val_if_fail (queue->ref_count > 0, 0); + + g_mutex_lock (queue->mutex); + retval = queue->queue->length - queue->waiting_threads; + g_mutex_unlock (queue->mutex); + + return retval; +} + +/** + * g_async_queue_length_unlocked: + * @queue: a #GAsyncQueue. + * + * Returns the length of the queue, negative values mean waiting + * threads, positive values mean available entries in the + * @queue. Actually this function returns the number of data items in + * the queue minus the number of waiting threads. Thus a return value + * of 0 could mean 'n' entries in the queue and 'n' thread waiting. + * That can happen due to locking of the queue or due to + * scheduling. This function must be called while holding the @queue's + * lock. + * + * Return value: the length of the @queue. + **/ +gint +g_async_queue_length_unlocked (GAsyncQueue* queue) +{ + g_return_val_if_fail (queue, 0); + g_return_val_if_fail (queue->ref_count > 0, 0); + + return queue->queue->length - queue->waiting_threads; +} + diff --git a/graf2d/win32gdk/gdk/src/glib/gasyncqueue.h b/graf2d/win32gdk/gdk/src/glib/gasyncqueue.h index 6e87425f7a892..0f1a80db99650 100644 --- a/graf2d/win32gdk/gdk/src/glib/gasyncqueue.h +++ b/graf2d/win32gdk/gdk/src/glib/gasyncqueue.h @@ -27,7 +27,7 @@ #ifndef __G_ASYNCQUEUE_H__ #define __G_ASYNCQUEUE_H__ -#include <gthread.h> +#include <glib/gthread.h> G_BEGIN_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gbacktrace.c b/graf2d/win32gdk/gdk/src/glib/gbacktrace.c new file mode 100644 index 0000000000000..7d131af740702 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gbacktrace.c @@ -0,0 +1,300 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe ; except for g_on_error_stack_trace, but who wants thread safety + * then + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <signal.h> +#include <stdarg.h> +#include <stdio.h> +#include <stdlib.h> +#include "glib.h" +#ifdef HAVE_SYS_TIME_H +#include <sys/time.h> +#endif +#ifdef HAVE_SYS_TIMES_H +#include <sys/times.h> +#endif +#include <sys/types.h> + +#include <time.h> +#ifdef HAVE_UNISTD_H +#include <unistd.h> +#endif + +#ifdef HAVE_SYS_SELECT_H +#include <sys/select.h> +#endif /* HAVE_SYS_SELECT_H */ + +#ifdef STDC_HEADERS +#include <string.h> /* for bzero on BSD systems */ +#endif + +#ifdef G_OS_WIN32 +# define STRICT /* Strict typing, please */ +# include <windows.h> +# undef STRICT +#endif + +#ifndef NO_FD_SET +# define SELECT_MASK fd_set +#else +# if defined(_IBMR2) +# define SELECT_MASK void +# else +# define SELECT_MASK int +# endif +#endif + + +#ifndef G_OS_WIN32 +static void stack_trace (char **args); +#endif + +extern volatile gboolean glib_on_error_halt; +volatile gboolean glib_on_error_halt = TRUE; + +void +g_on_error_query (const gchar *prg_name) +{ +#ifndef G_OS_WIN32 + static const gchar *query1 = "[E]xit, [H]alt"; + static const gchar *query2 = ", show [S]tack trace"; + static const gchar *query3 = " or [P]roceed"; + gchar buf[16]; + + if (!prg_name) + prg_name = g_get_prgname (); + + retry: + + if (prg_name) + fprintf (stdout, + "%s (pid:%u): %s%s%s: ", + prg_name, + (guint) getpid (), + query1, + query2, + query3); + else + fprintf (stdout, + "(process:%u): %s%s: ", + (guint) getpid (), + query1, + query3); + fflush (stdout); + + if (isatty(0) && isatty(1)) + fgets (buf, 8, stdin); + else + strcpy (buf, "E\n"); + + if ((buf[0] == 'E' || buf[0] == 'e') + && buf[1] == '\n') + _exit (0); + else if ((buf[0] == 'P' || buf[0] == 'p') + && buf[1] == '\n') + return; + else if (prg_name + && (buf[0] == 'S' || buf[0] == 's') + && buf[1] == '\n') + { + g_on_error_stack_trace (prg_name); + goto retry; + } + else if ((buf[0] == 'H' || buf[0] == 'h') + && buf[1] == '\n') + { + while (glib_on_error_halt) + ; + glib_on_error_halt = TRUE; + return; + } + else + goto retry; +#else + if (!prg_name) + prg_name = g_get_prgname (); + + MessageBox (NULL, "g_on_error_query called, program terminating", + (prg_name && *prg_name) ? prg_name : NULL, + MB_OK|MB_ICONERROR); + _exit(0); +#endif +} + +void +g_on_error_stack_trace (const gchar *prg_name) +{ +#ifdef G_OS_UNIX + pid_t pid; + gchar buf[16]; + gchar *args[4] = { "gdb", NULL, NULL, NULL }; + + if (!prg_name) + return; + + sprintf (buf, "%u", (guint) getpid ()); + + args[1] = (gchar*) prg_name; + args[2] = buf; + + pid = fork (); + if (pid == 0) + { + stack_trace (args); + _exit (0); + } + else if (pid == (pid_t) -1) + { + perror ("unable to fork gdb"); + return; + } + + while (glib_on_error_halt) + ; + glib_on_error_halt = TRUE; +#else + abort (); +#endif +} + +#ifndef G_OS_WIN32 + +static gboolean stack_trace_done = FALSE; + +static void +stack_trace_sigchld (int signum) +{ + stack_trace_done = TRUE; +} + +static void +stack_trace (char **args) +{ + pid_t pid; + int in_fd[2]; + int out_fd[2]; + SELECT_MASK fdset; + SELECT_MASK readset; + struct timeval tv; + int sel, index, state; + char buffer[256]; + char c; + + stack_trace_done = FALSE; + signal (SIGCHLD, stack_trace_sigchld); + + if ((pipe (in_fd) == -1) || (pipe (out_fd) == -1)) + { + perror ("unable to open pipe"); + _exit (0); + } + + pid = fork (); + if (pid == 0) + { + close (0); dup (in_fd[0]); /* set the stdin to the in pipe */ + close (1); dup (out_fd[1]); /* set the stdout to the out pipe */ + close (2); dup (out_fd[1]); /* set the stderr to the out pipe */ + + execvp (args[0], args); /* exec gdb */ + perror ("exec failed"); + _exit (0); + } + else if (pid == (pid_t) -1) + { + perror ("unable to fork"); + _exit (0); + } + + FD_ZERO (&fdset); + FD_SET (out_fd[0], &fdset); + + write (in_fd[1], "backtrace\n", 10); + write (in_fd[1], "p x = 0\n", 8); + write (in_fd[1], "quit\n", 5); + + index = 0; + state = 0; + + while (1) + { + readset = fdset; + tv.tv_sec = 1; + tv.tv_usec = 0; + + sel = select (FD_SETSIZE, &readset, NULL, NULL, &tv); + if (sel == -1) + break; + + if ((sel > 0) && (FD_ISSET (out_fd[0], &readset))) + { + if (read (out_fd[0], &c, 1)) + { + switch (state) + { + case 0: + if (c == '#') + { + state = 1; + index = 0; + buffer[index++] = c; + } + break; + case 1: + buffer[index++] = c; + if ((c == '\n') || (c == '\r')) + { + buffer[index] = 0; + fprintf (stdout, "%s", buffer); + state = 0; + index = 0; + } + break; + default: + break; + } + } + } + else if (stack_trace_done) + break; + } + + close (in_fd[0]); + close (in_fd[1]); + close (out_fd[0]); + close (out_fd[1]); + _exit (0); +} + +#endif /* !G_OS_WIN32 */ diff --git a/graf2d/win32gdk/gdk/src/glib/gbacktrace.h b/graf2d/win32gdk/gdk/src/glib/gbacktrace.h index 38d667ff46ad6..93b51749ca9b3 100644 --- a/graf2d/win32gdk/gdk/src/glib/gbacktrace.h +++ b/graf2d/win32gdk/gdk/src/glib/gbacktrace.h @@ -27,7 +27,7 @@ #ifndef __G_BACKTRACE_H__ #define __G_BACKTRACE_H__ -#include <g_types.h> +#include <glib/gtypes.h> G_BEGIN_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gbsearcharray.c b/graf2d/win32gdk/gdk/src/glib/gbsearcharray.c new file mode 100644 index 0000000000000..3343e8477dd8c --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gbsearcharray.c @@ -0,0 +1,213 @@ +/* GObject - GLib Type, Object, Parameter and Signal Library + * Copyright (C) 2000-2001 Tim Janik + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General + * Public License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place, Suite 330, + * Boston, MA 02111-1307, USA. + */ +#define G_IMPLEMENT_INLINES 1 +#define __G_BSEARCHARRAY_C__ +#include "gbsearcharray.h" + +#include <string.h> + + +/* --- structures --- */ +GBSearchArray* +g_bsearch_array_new (guint16 sizeof_node, + GBSearchCompareFunc node_cmp_func, + GBSearchArrayFlags flags) +{ + GBSearchArray *barray; + + g_return_val_if_fail (sizeof_node > 0, NULL); + g_return_val_if_fail (node_cmp_func != NULL, NULL); + + barray = g_new0 (GBSearchArray, 1); + barray->sizeof_node = sizeof_node; + barray->cmp_nodes = node_cmp_func; + barray->flags = flags; + + return barray; +} + +void +g_bsearch_array_destroy (GBSearchArray *barray) +{ + g_return_if_fail (barray != NULL); + +#if 0 + if (barray->destroy_node) + while (barray->n_nodes) + { + barray->destroy_node (((guint8*) barray->nodes) + (barray->n_nodes - 1) * barray->sizeof_node); + barray->n_nodes--; + } +#endif + g_free (barray->nodes); + g_free (barray); +} + +static inline guint +upper_power2 (guint number) +{ +#ifdef DISABLE_MEM_POOLS + return number; +#else /* !DISABLE_MEM_POOLS */ + return number ? 1 << g_bit_storage (number - 1) : 0; +#endif /* !DISABLE_MEM_POOLS */ +} + +static inline gpointer +bsearch_array_insert (GBSearchArray *barray, + gconstpointer key_node, + gboolean replace) +{ + gint sizeof_node; + guint8 *check; + + sizeof_node = barray->sizeof_node; + if (barray->n_nodes == 0) + { + guint new_size = barray->sizeof_node; + + if (barray->flags & G_BSEARCH_ARRAY_ALIGN_POWER2) + new_size = upper_power2 (new_size); + barray->nodes = g_realloc (barray->nodes, new_size); + barray->n_nodes = 1; + check = barray->nodes; + } + else + { + GBSearchCompareFunc cmp_nodes = barray->cmp_nodes; + guint n_nodes = barray->n_nodes; + guint8 *nodes = barray->nodes; + gint cmp; + guint i; + + nodes -= sizeof_node; + do + { + i = (n_nodes + 1) >> 1; + check = nodes + i * sizeof_node; + cmp = cmp_nodes (key_node, check); + if (cmp > 0) + { + n_nodes -= i; + nodes = check; + } + else if (cmp < 0) + n_nodes = i - 1; + else /* if (cmp == 0) */ + { + if (replace) + { +#if 0 + if (barray->destroy_node) + barray->destroy_node (check); +#endif + memcpy (check, key_node, sizeof_node); + } + return check; + } + } + while (n_nodes); + /* grow */ + if (cmp > 0) + check += sizeof_node; + i = (check - ((guint8*) barray->nodes)) / sizeof_node; + n_nodes = barray->n_nodes++; + if (barray->flags & G_BSEARCH_ARRAY_ALIGN_POWER2) + { + guint new_size = upper_power2 (barray->n_nodes * sizeof_node); + guint old_size = upper_power2 (n_nodes * sizeof_node); + + if (new_size != old_size) + barray->nodes = g_realloc (barray->nodes, new_size); + } + else + barray->nodes = g_realloc (barray->nodes, barray->n_nodes * sizeof_node); + check = ((guint8*) barray->nodes) + i * sizeof_node; + g_memmove (check + sizeof_node, check, (n_nodes - i) * sizeof_node); + } + memcpy (check, key_node, sizeof_node); + + return check; +} + +gpointer +g_bsearch_array_insert (GBSearchArray *barray, + gconstpointer key_node, + gboolean replace_existing) +{ + g_return_val_if_fail (barray != NULL, NULL); + g_return_val_if_fail (key_node != NULL, NULL); + + return bsearch_array_insert (barray, key_node, replace_existing); +} + +void +g_bsearch_array_remove_node (GBSearchArray *barray, + gpointer _node_in_array) +{ + guint8 *nodes, *bound, *node_in_array = _node_in_array; + guint old_size; + + g_return_if_fail (barray != NULL); + + nodes = barray->nodes; + old_size = barray->sizeof_node; + old_size *= barray->n_nodes; /* beware of int widths */ + bound = nodes + old_size; + + g_return_if_fail (node_in_array >= nodes && node_in_array < bound); + +#if 0 + if (barray->destroy_node) + barray->destroy_node (node_in_array); +#endif + bound -= barray->sizeof_node; + barray->n_nodes -= 1; + g_memmove (node_in_array, node_in_array + barray->sizeof_node, (bound - node_in_array) / barray->sizeof_node); + + if ((barray->flags & G_BSEARCH_ARRAY_DEFER_SHRINK) == 0) + { + guint new_size = bound - nodes; /* old_size - barray->sizeof_node */ + + if (barray->flags & G_BSEARCH_ARRAY_ALIGN_POWER2) + { + new_size = upper_power2 (new_size); + old_size = upper_power2 (old_size); + if (old_size != new_size) + barray->nodes = g_realloc (barray->nodes, new_size); + } + else + barray->nodes = g_realloc (barray->nodes, new_size); + } +} + +void +g_bsearch_array_remove (GBSearchArray *barray, + gconstpointer key_node) +{ + gpointer node_in_array; + + g_return_if_fail (barray != NULL); + + node_in_array = g_bsearch_array_lookup (barray, key_node); + if (!node_in_array) + g_warning (G_STRLOC ": unable to remove unexistant node"); + else + g_bsearch_array_remove_node (barray, node_in_array); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gbsearcharray.h b/graf2d/win32gdk/gdk/src/glib/gbsearcharray.h new file mode 100644 index 0000000000000..1682a76064e86 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gbsearcharray.h @@ -0,0 +1,148 @@ +/* GObject - GLib Type, Object, Parameter and Signal Library + * Copyright (C) 2000-2001 Tim Janik + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General + * Public License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place, Suite 330, + * Boston, MA 02111-1307, USA. + * + * gbsearcharray.h: binary searchable sorted array maintenance + */ +#ifndef __G_BSEARCH_ARRAY_H__ +#define __G_BSEARCH_ARRAY_H__ + +#include <gobject/gtype.h> + +G_BEGIN_DECLS + +/* helper macro to avoid signed overflow for value comparisions */ +#define G_BSEARCH_ARRAY_CMP(v1,v2) ((v1) < (v2) ? -1 : (v1) > (v2)) + + +/* --- typedefs --- */ +typedef struct _GBSearchArray GBSearchArray; +typedef gint (*GBSearchCompareFunc) (gconstpointer bsearch_node1, + gconstpointer bsearch_node2); +typedef enum +{ + G_BSEARCH_ARRAY_ALIGN_POWER2 = 1 << 0, + G_BSEARCH_ARRAY_DEFER_SHRINK = 1 << 1 +} GBSearchArrayFlags; + + +/* --- structures --- */ +struct _GBSearchArray +{ + GBSearchCompareFunc cmp_nodes; + guint16 flags; + guint16 sizeof_node; + guint n_nodes; + gpointer nodes; +}; + + +/* --- prototypes --- */ +GBSearchArray* g_bsearch_array_new (guint16 sizeof_node, + GBSearchCompareFunc node_cmp_func, + GBSearchArrayFlags flags); +void g_bsearch_array_destroy (GBSearchArray *barray); +gpointer g_bsearch_array_insert (GBSearchArray *barray, + gconstpointer key_node, + gboolean replace_existing); +void g_bsearch_array_remove (GBSearchArray *barray, + gconstpointer key_node); +void g_bsearch_array_remove_node (GBSearchArray *barray, + gpointer node_in_array); +G_INLINE_FUNC +gpointer g_bsearch_array_lookup (GBSearchArray *barray, + gconstpointer key_node); +G_INLINE_FUNC +gpointer g_bsearch_array_get_nth (GBSearchArray *barray, + guint n); +G_INLINE_FUNC +guint g_bsearch_array_get_index (GBSearchArray *barray, + gpointer node_in_array); + + +/* initialization of static arrays */ +#define G_STATIC_BSEARCH_ARRAY_INIT(sizeof_node, cmp_nodes, flags) \ + { (cmp_nodes), (flags), (sizeof_node), 0, NULL } + + +/* --- implementation details --- */ +#if defined (G_CAN_INLINE) || defined (__G_BSEARCHARRAY_C__) +G_INLINE_FUNC gpointer +g_bsearch_array_lookup (GBSearchArray *barray, + gconstpointer key_node) +{ + if (barray->n_nodes > 0) + { + GBSearchCompareFunc cmp_nodes = barray->cmp_nodes; + gint sizeof_node = barray->sizeof_node; + guint n_nodes = barray->n_nodes; + guint8 *nodes = (guint8 *) barray->nodes; + + nodes -= sizeof_node; + do + { + guint8 *check; + guint i; + register gint cmp; + + i = (n_nodes + 1) >> 1; + check = nodes + i * sizeof_node; + cmp = cmp_nodes (key_node, check); + if (cmp == 0) + return check; + else if (cmp > 0) + { + n_nodes -= i; + nodes = check; + } + else /* if (cmp < 0) */ + n_nodes = i - 1; + } + while (n_nodes); + } + + return NULL; +} +G_INLINE_FUNC gpointer +g_bsearch_array_get_nth (GBSearchArray *barray, + guint n) +{ + if (n < barray->n_nodes) + { + guint8 *nodes = (guint8*) barray->nodes; + + return nodes + n * barray->sizeof_node; + } + else + return NULL; +} +G_INLINE_FUNC +guint +g_bsearch_array_get_index (GBSearchArray *barray, + gpointer node_in_array) +{ + guint distance = ((guint8*) node_in_array) - ((guint8*) barray->nodes); + + distance /= barray->sizeof_node; + + return MIN (distance, barray->n_nodes); +} +#endif /* G_CAN_INLINE || __G_BSEARCHARRAY_C__ */ + +G_END_DECLS + +#endif /* __G_BSEARCH_ARRAY_H__ */ diff --git a/graf2d/win32gdk/gdk/src/glib/gcache.c b/graf2d/win32gdk/gdk/src/glib/gcache.c new file mode 100644 index 0000000000000..12e99a66b3c57 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gcache.c @@ -0,0 +1,212 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#include "glib.h" + + +typedef struct _GCacheNode GCacheNode; + +struct _GCacheNode +{ + /* A reference counted node */ + gpointer value; + gint ref_count; +}; + +struct _GCache +{ + /* Called to create a value from a key */ + GCacheNewFunc value_new_func; + + /* Called to destroy a value */ + GCacheDestroyFunc value_destroy_func; + + /* Called to duplicate a key */ + GCacheDupFunc key_dup_func; + + /* Called to destroy a key */ + GCacheDestroyFunc key_destroy_func; + + /* Associates keys with nodes */ + GHashTable *key_table; + + /* Associates nodes with keys */ + GHashTable *value_table; +}; + + +static GCacheNode* g_cache_node_new (gpointer value); +static void g_cache_node_destroy (GCacheNode *node); + + +static GMemChunk *node_mem_chunk = NULL; +G_LOCK_DEFINE_STATIC (node_mem_chunk); + +GCache* +g_cache_new (GCacheNewFunc value_new_func, + GCacheDestroyFunc value_destroy_func, + GCacheDupFunc key_dup_func, + GCacheDestroyFunc key_destroy_func, + GHashFunc hash_key_func, + GHashFunc hash_value_func, + GEqualFunc key_equal_func) +{ + GCache *cache; + + g_return_val_if_fail (value_new_func != NULL, NULL); + g_return_val_if_fail (value_destroy_func != NULL, NULL); + g_return_val_if_fail (key_dup_func != NULL, NULL); + g_return_val_if_fail (key_destroy_func != NULL, NULL); + g_return_val_if_fail (hash_key_func != NULL, NULL); + g_return_val_if_fail (hash_value_func != NULL, NULL); + g_return_val_if_fail (key_equal_func != NULL, NULL); + + cache = g_new (GCache, 1); + cache->value_new_func = value_new_func; + cache->value_destroy_func = value_destroy_func; + cache->key_dup_func = key_dup_func; + cache->key_destroy_func = key_destroy_func; + cache->key_table = g_hash_table_new (hash_key_func, key_equal_func); + cache->value_table = g_hash_table_new (hash_value_func, NULL); + + return cache; +} + +void +g_cache_destroy (GCache *cache) +{ + g_return_if_fail (cache != NULL); + + g_hash_table_destroy (cache->key_table); + g_hash_table_destroy (cache->value_table); + g_free (cache); +} + +gpointer +g_cache_insert (GCache *cache, + gpointer key) +{ + GCacheNode *node; + gpointer value; + + g_return_val_if_fail (cache != NULL, NULL); + + node = g_hash_table_lookup (cache->key_table, key); + if (node) + { + node->ref_count += 1; + return node->value; + } + + key = (* cache->key_dup_func) (key); + value = (* cache->value_new_func) (key); + node = g_cache_node_new (value); + + g_hash_table_insert (cache->key_table, key, node); + g_hash_table_insert (cache->value_table, value, key); + + return node->value; +} + +void +g_cache_remove (GCache *cache, + gconstpointer value) +{ + GCacheNode *node; + gpointer key; + + g_return_if_fail (cache != NULL); + + key = g_hash_table_lookup (cache->value_table, value); + node = g_hash_table_lookup (cache->key_table, key); + + g_return_if_fail (node != NULL); + + node->ref_count -= 1; + if (node->ref_count == 0) + { + g_hash_table_remove (cache->value_table, value); + g_hash_table_remove (cache->key_table, key); + + (* cache->key_destroy_func) (key); + (* cache->value_destroy_func) (node->value); + g_cache_node_destroy (node); + } +} + +void +g_cache_key_foreach (GCache *cache, + GHFunc func, + gpointer user_data) +{ + g_return_if_fail (cache != NULL); + g_return_if_fail (func != NULL); + + g_hash_table_foreach (cache->value_table, func, user_data); +} + +void +g_cache_value_foreach (GCache *cache, + GHFunc func, + gpointer user_data) +{ + g_return_if_fail (cache != NULL); + g_return_if_fail (func != NULL); + + g_hash_table_foreach (cache->key_table, func, user_data); +} + + +static GCacheNode* +g_cache_node_new (gpointer value) +{ + GCacheNode *node; + + G_LOCK (node_mem_chunk); + if (!node_mem_chunk) + node_mem_chunk = g_mem_chunk_new ("cache node mem chunk", sizeof (GCacheNode), + 1024, G_ALLOC_AND_FREE); + + node = g_chunk_new (GCacheNode, node_mem_chunk); + G_UNLOCK (node_mem_chunk); + + node->value = value; + node->ref_count = 1; + + return node; +} + +static void +g_cache_node_destroy (GCacheNode *node) +{ + G_LOCK (node_mem_chunk); + g_mem_chunk_free (node_mem_chunk, node); + G_UNLOCK (node_mem_chunk); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gcache.h b/graf2d/win32gdk/gdk/src/glib/gcache.h index 74ef5b654b959..a9128b653a0de 100644 --- a/graf2d/win32gdk/gdk/src/glib/gcache.h +++ b/graf2d/win32gdk/gdk/src/glib/gcache.h @@ -27,7 +27,7 @@ #ifndef __G_CACHE_H__ #define __G_CACHE_H__ -#include <glist.h> +#include <glib/glist.h> G_BEGIN_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gcompletion.c b/graf2d/win32gdk/gdk/src/glib/gcompletion.c new file mode 100644 index 0000000000000..9a33ff5ca19c5 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gcompletion.c @@ -0,0 +1,294 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#include "glib.h" +#include <string.h> + +static void completion_check_cache (GCompletion* cmp, + gchar** new_prefix); + +GCompletion* +g_completion_new (GCompletionFunc func) +{ + GCompletion* gcomp; + + gcomp = g_new (GCompletion, 1); + gcomp->items = NULL; + gcomp->cache = NULL; + gcomp->prefix = NULL; + gcomp->func = func; + gcomp->strncmp_func = strncmp; + + return gcomp; +} + +void +g_completion_add_items (GCompletion* cmp, + GList* items) +{ + GList* it; + + g_return_if_fail (cmp != NULL); + g_return_if_fail (items != NULL); + + /* optimize adding to cache? */ + if (cmp->cache) + { + g_list_free (cmp->cache); + cmp->cache = NULL; + } + + if (cmp->prefix) + { + g_free (cmp->prefix); + cmp->prefix = NULL; + } + + it = items; + while (it) + { + cmp->items = g_list_prepend (cmp->items, it->data); + it = it->next; + } +} + +void +g_completion_remove_items (GCompletion* cmp, + GList* items) +{ + GList* it; + + g_return_if_fail (cmp != NULL); + g_return_if_fail (items != NULL); + + it = items; + while (cmp->items && it) + { + cmp->items = g_list_remove (cmp->items, it->data); + it = it->next; + } + + it = items; + while (cmp->cache && it) + { + cmp->cache = g_list_remove(cmp->cache, it->data); + it = it->next; + } +} + +void +g_completion_clear_items (GCompletion* cmp) +{ + g_return_if_fail (cmp != NULL); + + g_list_free (cmp->items); + cmp->items = NULL; + g_list_free (cmp->cache); + cmp->cache = NULL; + g_free (cmp->prefix); + cmp->prefix = NULL; +} + +static void +completion_check_cache (GCompletion* cmp, + gchar** new_prefix) +{ + register GList* list; + register gsize len; + register gsize i; + register gsize plen; + gchar* postfix; + gchar* s; + + if (!new_prefix) + return; + if (!cmp->cache) + { + *new_prefix = NULL; + return; + } + + len = strlen(cmp->prefix); + list = cmp->cache; + s = cmp->func ? cmp->func (list->data) : (gchar*) list->data; + postfix = s + len; + plen = strlen (postfix); + list = list->next; + + while (list && plen) + { + s = cmp->func ? cmp->func (list->data) : (gchar*) list->data; + s += len; + for (i = 0; i < plen; ++i) + { + if (postfix[i] != s[i]) + break; + } + plen = i; + list = list->next; + } + + *new_prefix = g_new0 (gchar, len + plen + 1); + strncpy (*new_prefix, cmp->prefix, len); + strncpy (*new_prefix + len, postfix, plen); +} + +GList* +g_completion_complete (GCompletion* cmp, + gchar* prefix, + gchar** new_prefix) +{ + gsize plen, len; + gboolean done = FALSE; + GList* list; + + g_return_val_if_fail (cmp != NULL, NULL); + g_return_val_if_fail (prefix != NULL, NULL); + + len = strlen (prefix); + if (cmp->prefix && cmp->cache) + { + plen = strlen (cmp->prefix); + if (plen <= len && ! cmp->strncmp_func (prefix, cmp->prefix, plen)) + { + /* use the cache */ + list = cmp->cache; + while (list) + { + GList *next = list->next; + + if (cmp->strncmp_func (prefix, + cmp->func ? cmp->func (list->data) : (gchar*) list->data, + len)) + cmp->cache = g_list_delete_link (cmp->cache, list); + + list = next; + } + done = TRUE; + } + } + + if (!done) + { + /* normal code */ + g_list_free (cmp->cache); + cmp->cache = NULL; + list = cmp->items; + while (*prefix && list) + { + if (!cmp->strncmp_func (prefix, + cmp->func ? cmp->func (list->data) : (gchar*) list->data, + len)) + cmp->cache = g_list_prepend (cmp->cache, list->data); + list = list->next; + } + } + if (cmp->prefix) + { + g_free (cmp->prefix); + cmp->prefix = NULL; + } + if (cmp->cache) + cmp->prefix = g_strdup (prefix); + completion_check_cache (cmp, new_prefix); + + return *prefix ? cmp->cache : cmp->items; +} + +void +g_completion_free (GCompletion* cmp) +{ + g_return_if_fail (cmp != NULL); + + g_completion_clear_items (cmp); + g_free (cmp); +} + +void +g_completion_set_compare(GCompletion *cmp, + GCompletionStrncmpFunc strncmp_func) +{ + cmp->strncmp_func = strncmp_func; +} + +#ifdef TEST_COMPLETION +#include <stdio.h> +int +main (int argc, + char* argv[]) +{ + FILE *file; + gchar buf[1024]; + GList *list; + GList *result; + GList *tmp; + GCompletion *cmp; + gint i; + gchar *longp = NULL; + + if (argc < 3) + { + g_warning ("Usage: %s filename prefix1 [prefix2 ...]\n", argv[0]); + return 1; + } + + file = fopen (argv[1], "r"); + if (!file) + { + g_warning ("Cannot open %s\n", argv[1]); + return 1; + } + + cmp = g_completion_new (NULL); + list = g_list_alloc (); + while (fgets (buf, 1024, file)) + { + list->data = g_strdup (buf); + g_completion_add_items (cmp, list); + } + fclose (file); + + for (i = 2; i < argc; ++i) + { + printf ("COMPLETING: %s\n", argv[i]); + result = g_completion_complete (cmp, argv[i], &longp); + g_list_foreach (result, (GFunc) printf, NULL); + printf ("LONG MATCH: %s\n", longp); + g_free (longp); + longp = NULL; + } + + g_list_foreach (cmp->items, (GFunc) g_free, NULL); + g_completion_free (cmp); + g_list_free (list); + + return 0; +} +#endif diff --git a/graf2d/win32gdk/gdk/src/glib/gcompletion.h b/graf2d/win32gdk/gdk/src/glib/gcompletion.h index d5fca3f3af449..eab0699b518fc 100644 --- a/graf2d/win32gdk/gdk/src/glib/gcompletion.h +++ b/graf2d/win32gdk/gdk/src/glib/gcompletion.h @@ -27,11 +27,7 @@ #ifndef __G_COMPLETION_H__ #define __G_COMPLETION_H__ -#include <glist.h> -#include <stddef.h> /* For size_t */ -#ifdef G_OS_UNIX -#include <unistd.h> -#endif +#include <glib/glist.h> G_BEGIN_DECLS @@ -42,7 +38,9 @@ typedef gchar* (*GCompletionFunc) (gpointer); /* GCompletion */ -typedef int (*GCompletionStrncmpFunc)(const char *s1, const char *s2, size_t n); +typedef gint (*GCompletionStrncmpFunc) (const gchar *s1, + const gchar *s2, + gsize n); struct _GCompletion { diff --git a/graf2d/win32gdk/gdk/src/glib/gconvert.c b/graf2d/win32gdk/gdk/src/glib/gconvert.c new file mode 100644 index 0000000000000..d904335503f49 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gconvert.c @@ -0,0 +1,1321 @@ +/* GLIB - Library of useful routines for C programming + * + * gconvert.c: Convert between character sets using iconv + * Copyright Red Hat Inc., 2000 + * Authors: Havoc Pennington <hp@redhat.com>, Owen Taylor <otaylor@redhat.com + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include <iconv.h> +#include <errno.h> +#include <string.h> +#include <stdlib.h> + +#include "glib.h" +#include "config.h" + +#ifdef G_PLATFORM_WIN32 +#define STRICT +#include <windows.h> +#undef STRICT +#endif + +#include "glibintl.h" + +GQuark +g_convert_error_quark() +{ + static GQuark quark; + if (!quark) + quark = g_quark_from_static_string ("g_convert_error"); + + return quark; +} + +#if defined(USE_LIBICONV) && !defined (_LIBICONV_H) +#error libiconv in use but included iconv.h not from libiconv +#endif +#if !defined(USE_LIBICONV) && defined (_LIBICONV_H) +#error libiconv not in use but included iconv.h is from libiconv +#endif + +/** + * g_iconv_open: + * @to_codeset: destination codeset + * @from_codeset: source codeset + * + * Same as the standard UNIX routine iconv_open(), but + * may be implemented via libiconv on UNIX flavors that lack + * a native implementation. + * + * GLib provides g_convert() and g_locale_to_utf8() which are likely + * more convenient than the raw iconv wrappers. + * + * Return value: a "conversion descriptor" + **/ +GIConv +g_iconv_open (const gchar *to_codeset, + const gchar *from_codeset) +{ + iconv_t cd = iconv_open (to_codeset, from_codeset); + + return (GIConv)cd; +} + +/** + * g_iconv: + * @converter: conversion descriptor from g_iconv_open() + * @inbuf: bytes to convert + * @inbytes_left: inout parameter, bytes remaining to convert in @inbuf + * @outbuf: converted output bytes + * @outbytes_left: inout parameter, bytes available to fill in @outbuf + * + * Same as the standard UNIX routine iconv(), but + * may be implemented via libiconv on UNIX flavors that lack + * a native implementation. + * + * GLib provides g_convert() and g_locale_to_utf8() which are likely + * more convenient than the raw iconv wrappers. + * + * Return value: count of non-reversible conversions, or -1 on error + **/ +size_t +g_iconv (GIConv converter, + gchar **inbuf, + gsize *inbytes_left, + gchar **outbuf, + gsize *outbytes_left) +{ + iconv_t cd = (iconv_t)converter; + + return iconv (cd, inbuf, inbytes_left, outbuf, outbytes_left); +} + +/** + * g_iconv_close: + * @converter: a conversion descriptor from g_iconv_open() + * + * Same as the standard UNIX routine iconv_close(), but + * may be implemented via libiconv on UNIX flavors that lack + * a native implementation. Should be called to clean up + * the conversion descriptor from iconv_open() when + * you are done converting things. + * + * GLib provides g_convert() and g_locale_to_utf8() which are likely + * more convenient than the raw iconv wrappers. + * + * Return value: -1 on error, 0 on success + **/ +gint +g_iconv_close (GIConv converter) +{ + iconv_t cd = (iconv_t)converter; + + return iconv_close (cd); +} + +static GIConv +open_converter (const gchar *to_codeset, + const gchar *from_codeset, + GError **error) +{ + GIConv cd = g_iconv_open (to_codeset, from_codeset); + + if (cd == (iconv_t) -1) + { + /* Something went wrong. */ + if (errno == EINVAL) + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_NO_CONVERSION, + _("Conversion from character set `%s' to `%s' is not supported"), + from_codeset, to_codeset); + else + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED, + _("Could not open converter from `%s' to `%s': %s"), + from_codeset, to_codeset, strerror (errno)); + } + + return cd; + +} + +/** + * g_convert: + * @str: the string to convert + * @len: the length of the string + * @to_codeset: name of character set into which to convert @str + * @from_codeset: character set of @str. + * @bytes_read: location to store the number of bytes in the + * input string that were successfully converted, or %NULL. + * Even if the conversion was succesful, this may be + * less than len if there were partial characters + * at the end of the input. If the error + * G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value + * stored will the byte fofset after the last valid + * input sequence. + * @bytes_written: the stored in the output buffer (not including the + * terminating nul. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError may occur. + * + * Convert a string from one character set to another. + * + * Return value: If the conversion was successful, a newly allocated + * NUL-terminated string, which must be freed with + * g_free. Otherwise %NULL and @error will be set. + **/ +gchar* +g_convert (const gchar *str, + gssize len, + const gchar *to_codeset, + const gchar *from_codeset, + gsize *bytes_read, + gsize *bytes_written, + GError **error) +{ + gchar *res; + GIConv cd; + + g_return_val_if_fail (str != NULL, NULL); + g_return_val_if_fail (to_codeset != NULL, NULL); + g_return_val_if_fail (from_codeset != NULL, NULL); + + cd = open_converter (to_codeset, from_codeset, error); + + if (cd == (GIConv) -1) + { + if (bytes_read) + *bytes_read = 0; + + if (bytes_written) + *bytes_written = 0; + + return NULL; + } + + res = g_convert_with_iconv (str, len, cd, + bytes_read, bytes_written, + error); + + g_iconv_close (cd); + + return res; +} + +/** + * g_convert_with_iconv: + * @str: the string to convert + * @len: the length of the string + * @converter: conversion descriptor from g_iconv_open() + * @bytes_read: location to store the number of bytes in the + * input string that were successfully converted, or %NULL. + * Even if the conversion was succesful, this may be + * less than len if there were partial characters + * at the end of the input. If the error + * G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value + * stored will the byte fofset after the last valid + * input sequence. + * @bytes_written: the stored in the output buffer (not including the + * terminating nul. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError may occur. + * + * Convert a string from one character set to another. + * + * Return value: If the conversion was successful, a newly allocated + * NUL-terminated string, which must be freed with + * g_free. Otherwise %NULL and @error will be set. + **/ +gchar* +g_convert_with_iconv (const gchar *str, + gssize len, + GIConv converter, + gsize *bytes_read, + gsize *bytes_written, + GError **error) +{ + gchar *dest; + gchar *outp; + const gchar *p; + gsize inbytes_remaining; + gsize outbytes_remaining; + gsize err; + gsize outbuf_size; + gboolean have_error = FALSE; + + g_return_val_if_fail (str != NULL, NULL); + g_return_val_if_fail (converter != (GIConv) -1, NULL); + + if (len < 0) + len = strlen (str); + + p = str; + inbytes_remaining = len; + outbuf_size = len + 1; /* + 1 for nul in case len == 1 */ + + outbytes_remaining = outbuf_size - 1; /* -1 for nul */ + outp = dest = g_malloc (outbuf_size); + + again: + + err = g_iconv (converter, (char **)&p, &inbytes_remaining, &outp, &outbytes_remaining); + + if (err == (size_t) -1) + { + switch (errno) + { + case EINVAL: + /* Incomplete text, do not report an error */ + break; + case E2BIG: + { + size_t used = outp - dest; + + outbuf_size *= 2; + dest = g_realloc (dest, outbuf_size); + + outp = dest + used; + outbytes_remaining = outbuf_size - used - 1; /* -1 for nul */ + + goto again; + } + case EILSEQ: + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid byte sequence in conversion input")); + have_error = TRUE; + break; + default: + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED, + _("Error during conversion: %s"), + strerror (errno)); + have_error = TRUE; + break; + } + } + + *outp = '\0'; + + if (bytes_read) + *bytes_read = p - str; + else + { + if ((p - str) != len) + { + if (!have_error) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_PARTIAL_INPUT, + _("Partial character sequence at end of input")); + have_error = TRUE; + } + } + } + + if (bytes_written) + *bytes_written = outp - dest; /* Doesn't include '\0' */ + + if (have_error) + { + g_free (dest); + return NULL; + } + else + return dest; +} + +/** + * g_convert_with_fallback: + * @str: the string to convert + * @len: the length of the string + * @to_codeset: name of character set into which to convert @str + * @from_codeset: character set of @str. + * @fallback: UTF-8 string to use in place of character not + * present in the target encoding. (This must be + * in the target encoding), if %NULL, characters + * not in the target encoding will be represented + * as Unicode escapes \x{XXXX} or \x{XXXXXX}. + * @bytes_read: location to store the number of bytes in the + * input string that were successfully converted, or %NULL. + * Even if the conversion was succesful, this may be + * less than len if there were partial characters + * at the end of the input. + * @bytes_written: the stored in the output buffer (not including the + * terminating nul. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError may occur. + * + * Convert a string from one character set to another, possibly + * including fallback sequences for characters not representable + * in the output. Note that it is not guaranteed that the specification + * for the fallback sequences in @fallback will be honored. Some + * systems may do a approximate conversion from @from_codeset + * to @to_codeset in their iconv() functions, in which case GLib + * will simply return that approximate conversion. + * + * Return value: If the conversion was successful, a newly allocated + * NUL-terminated string, which must be freed with + * g_free. Otherwise %NULL and @error will be set. + **/ +gchar* +g_convert_with_fallback (const gchar *str, + gssize len, + const gchar *to_codeset, + const gchar *from_codeset, + gchar *fallback, + gsize *bytes_read, + gsize *bytes_written, + GError **error) +{ + gchar *utf8; + gchar *dest; + gchar *outp; + const gchar *insert_str = NULL; + const gchar *p; + gsize inbytes_remaining; + const gchar *save_p = NULL; + gsize save_inbytes = 0; + gsize outbytes_remaining; + gsize err; + GIConv cd; + gsize outbuf_size; + gboolean have_error = FALSE; + gboolean done = FALSE; + + GError *local_error = NULL; + + g_return_val_if_fail (str != NULL, NULL); + g_return_val_if_fail (to_codeset != NULL, NULL); + g_return_val_if_fail (from_codeset != NULL, NULL); + + if (len < 0) + len = strlen (str); + + /* Try an exact conversion; we only proceed if this fails + * due to an illegal sequence in the input string. + */ + dest = g_convert (str, len, to_codeset, from_codeset, + bytes_read, bytes_written, &local_error); + if (!local_error) + return dest; + + if (!g_error_matches (local_error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE)) + { + g_propagate_error (error, local_error); + return NULL; + } + else + g_error_free (local_error); + + local_error = NULL; + + /* No go; to proceed, we need a converter from "UTF-8" to + * to_codeset, and the string as UTF-8. + */ + cd = open_converter (to_codeset, "UTF-8", error); + if (cd == (GIConv) -1) + { + if (bytes_read) + *bytes_read = 0; + + if (bytes_written) + *bytes_written = 0; + + return NULL; + } + + utf8 = g_convert (str, len, "UTF-8", from_codeset, + bytes_read, &inbytes_remaining, error); + if (!utf8) + return NULL; + + /* Now the heart of the code. We loop through the UTF-8 string, and + * whenever we hit an offending character, we form fallback, convert + * the fallback to the target codeset, and then go back to + * converting the original string after finishing with the fallback. + * + * The variables save_p and save_inbytes store the input state + * for the original string while we are converting the fallback + */ + p = utf8; + + outbuf_size = len + 1; /* + 1 for nul in case len == 1 */ + outbytes_remaining = outbuf_size - 1; /* -1 for nul */ + outp = dest = g_malloc (outbuf_size); + + while (!done && !have_error) + { + size_t inbytes_tmp = inbytes_remaining; + err = g_iconv (cd, (char **)&p, &inbytes_tmp, &outp, &outbytes_remaining); + inbytes_remaining = inbytes_tmp; + + if (err == (size_t) -1) + { + switch (errno) + { + case EINVAL: + g_assert_not_reached(); + break; + case E2BIG: + { + size_t used = outp - dest; + + outbuf_size *= 2; + dest = g_realloc (dest, outbuf_size); + + outp = dest + used; + outbytes_remaining = outbuf_size - used - 1; /* -1 for nul */ + + break; + } + case EILSEQ: + if (save_p) + { + /* Error converting fallback string - fatal + */ + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Cannot convert fallback '%s' to codeset '%s'"), + insert_str, to_codeset); + have_error = TRUE; + break; + } + else + { + if (!fallback) + { + gunichar ch = g_utf8_get_char (p); + insert_str = g_strdup_printf ("\\x{%0*X}", + (ch < 0x10000) ? 4 : 6, + ch); + } + else + insert_str = fallback; + + save_p = g_utf8_next_char (p); + save_inbytes = inbytes_remaining - (save_p - p); + p = insert_str; + inbytes_remaining = strlen (p); + } + break; + default: + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED, + _("Error during conversion: %s"), + strerror (errno)); + have_error = TRUE; + break; + } + } + else + { + if (save_p) + { + if (!fallback) + g_free ((gchar *)insert_str); + p = save_p; + inbytes_remaining = save_inbytes; + save_p = NULL; + } + else + done = TRUE; + } + } + + /* Cleanup + */ + *outp = '\0'; + + g_iconv_close (cd); + + if (bytes_written) + *bytes_written = outp - str; /* Doesn't include '\0' */ + + g_free (utf8); + + if (have_error) + { + if (save_p && !fallback) + g_free ((gchar *)insert_str); + g_free (dest); + return NULL; + } + else + return dest; +} + +/* + * g_locale_to_utf8 + * + * + */ + +static gchar * +strdup_len (const gchar *string, + gssize len, + gsize *bytes_written, + gsize *bytes_read, + GError **error) + +{ + gsize real_len; + + if (!g_utf8_validate (string, -1, NULL)) + { + if (bytes_read) + *bytes_read = 0; + if (bytes_written) + *bytes_written = 0; + + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid byte sequence in conversion input")); + return NULL; + } + + if (len < 0) + real_len = strlen (string); + else + { + real_len = 0; + + while (real_len < len && string[real_len]) + real_len++; + } + + if (bytes_read) + *bytes_read = real_len; + if (bytes_written) + *bytes_written = real_len; + + return g_strndup (string, real_len); +} + +/** + * g_locale_to_utf8: + * @opsysstring: a string in the encoding of the current locale + * @len: the length of the string, or -1 if the string is + * NULL-terminated. + * @bytes_read: location to store the number of bytes in the + * input string that were successfully converted, or %NULL. + * Even if the conversion was succesful, this may be + * less than len if there were partial characters + * at the end of the input. If the error + * G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value + * stored will the byte fofset after the last valid + * input sequence. + * @bytes_written: the stored in the output buffer (not including the + * terminating nul. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError may occur. + * + * Converts a string which is in the encoding used for strings by + * the C runtime (usually the same as that used by the operating + * system) in the current locale into a UTF-8 string. + * + * Return value: The converted string, or %NULL on an error. + **/ +gchar * +g_locale_to_utf8 (const gchar *opsysstring, + gssize len, + gsize *bytes_read, + gsize *bytes_written, + GError **error) +{ +#ifdef G_PLATFORM_WIN32 + + gint i, clen, total_len, wclen, first; + wchar_t *wcs, wc; + gchar *result, *bp; + const wchar_t *wcp; + + if (len == -1) + len = strlen (opsysstring); + + wcs = g_new (wchar_t, len); + wclen = MultiByteToWideChar (CP_ACP, 0, opsysstring, len, wcs, len); + + wcp = wcs; + total_len = 0; + for (i = 0; i < wclen; i++) + { + wc = *wcp++; + + if (wc < 0x80) + total_len += 1; + else if (wc < 0x800) + total_len += 2; + else if (wc < 0x10000) + total_len += 3; + else if (wc < 0x200000) + total_len += 4; + else if (wc < 0x4000000) + total_len += 5; + else + total_len += 6; + } + + result = g_malloc (total_len + 1); + + wcp = wcs; + bp = result; + for (i = 0; i < wclen; i++) + { + wc = *wcp++; + + if (wc < 0x80) + { + first = 0; + clen = 1; + } + else if (wc < 0x800) + { + first = 0xc0; + clen = 2; + } + else if (wc < 0x10000) + { + first = 0xe0; + clen = 3; + } + else if (wc < 0x200000) + { + first = 0xf0; + clen = 4; + } + else if (wc < 0x4000000) + { + first = 0xf8; + clen = 5; + } + else + { + first = 0xfc; + clen = 6; + } + + /* Woo-hoo! */ + switch (clen) + { + case 6: bp[5] = (wc & 0x3f) | 0x80; wc >>= 6; /* Fall through */ + case 5: bp[4] = (wc & 0x3f) | 0x80; wc >>= 6; /* Fall through */ + case 4: bp[3] = (wc & 0x3f) | 0x80; wc >>= 6; /* Fall through */ + case 3: bp[2] = (wc & 0x3f) | 0x80; wc >>= 6; /* Fall through */ + case 2: bp[1] = (wc & 0x3f) | 0x80; wc >>= 6; /* Fall through */ + case 1: bp[0] = wc | first; + } + + bp += clen; + } + *bp = 0; + + g_free (wcs); + + if (bytes_read) + *bytes_read = len; + if (bytes_written) + *bytes_written = total_len; + + return result; + +#else /* !G_PLATFORM_WIN32 */ + + const char *charset; + + if (g_get_charset (&charset)) + return strdup_len (opsysstring, len, bytes_read, bytes_written, error); + else + return g_convert (opsysstring, len, + "UTF-8", charset, bytes_read, bytes_written, error); + +#endif /* !G_PLATFORM_WIN32 */ +} + +/** + * g_locale_from_utf8: + * @utf8string: a UTF-8 encoded string + * @len: the length of the string, or -1 if the string is + * NULL-terminated. + * @bytes_read: location to store the number of bytes in the + * input string that were successfully converted, or %NULL. + * Even if the conversion was succesful, this may be + * less than len if there were partial characters + * at the end of the input. If the error + * G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value + * stored will the byte fofset after the last valid + * input sequence. + * @bytes_written: the stored in the output buffer (not including the + * terminating nul. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError may occur. + * + * Converts a string from UTF-8 to the encoding used for strings by + * the C runtime (usually the same as that used by the operating + * system) in the current locale. + * + * Return value: The converted string, or %NULL on an error. + **/ +gchar * +g_locale_from_utf8 (const gchar *utf8string, + gssize len, + gsize *bytes_read, + gsize *bytes_written, + GError **error) +{ +#ifdef G_PLATFORM_WIN32 + + gint i, mask, clen, mblen; + wchar_t *wcs, *wcp; + gchar *result; + guchar *cp, *end, c; + gint n; + + if (len == -1) + len = strlen (utf8string); + + /* First convert to wide chars */ + cp = (guchar *) utf8string; + end = cp + len; + n = 0; + wcs = g_new (wchar_t, len + 1); + wcp = wcs; + while (cp != end) + { + mask = 0; + c = *cp; + + if (c < 0x80) + { + clen = 1; + mask = 0x7f; + } + else if ((c & 0xe0) == 0xc0) + { + clen = 2; + mask = 0x1f; + } + else if ((c & 0xf0) == 0xe0) + { + clen = 3; + mask = 0x0f; + } + else if ((c & 0xf8) == 0xf0) + { + clen = 4; + mask = 0x07; + } + else if ((c & 0xfc) == 0xf8) + { + clen = 5; + mask = 0x03; + } + else if ((c & 0xfc) == 0xfc) + { + clen = 6; + mask = 0x01; + } + else + { + g_free (wcs); + return NULL; + } + + if (cp + clen > end) + { + g_free (wcs); + return NULL; + } + + *wcp = (cp[0] & mask); + for (i = 1; i < clen; i++) + { + if ((cp[i] & 0xc0) != 0x80) + { + g_free (wcs); + return NULL; + } + *wcp <<= 6; + *wcp |= (cp[i] & 0x3f); + } + + cp += clen; + wcp++; + n++; + } + if (cp != end) + { + g_free (wcs); + return NULL; + } + + /* n is the number of wide chars constructed */ + + /* Convert to a string in the current ANSI codepage */ + + result = g_new (gchar, 3 * n + 1); + mblen = WideCharToMultiByte (CP_ACP, 0, wcs, n, result, 3*n, NULL, NULL); + result[mblen] = 0; + g_free (wcs); + + if (bytes_read) + *bytes_read = len; + if (bytes_written) + *bytes_written = mblen; + + return result; + +#else /* !G_PLATFORM_WIN32 */ + + const gchar *charset; + + if (g_get_charset (&charset)) + return strdup_len (utf8string, len, bytes_read, bytes_written, error); + else + return g_convert (utf8string, len, + charset, "UTF-8", bytes_read, bytes_written, error); + +#endif /* !G_PLATFORM_WIN32 */ +} + +/** + * g_filename_to_utf8: + * @opsysstring: a string in the encoding for filenames + * @len: the length of the string, or -1 if the string is + * NULL-terminated. + * @bytes_read: location to store the number of bytes in the + * input string that were successfully converted, or %NULL. + * Even if the conversion was succesful, this may be + * less than len if there were partial characters + * at the end of the input. If the error + * G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value + * stored will the byte fofset after the last valid + * input sequence. + * @bytes_written: the stored in the output buffer (not including the + * terminating nul. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError may occur. + * + * Converts a string which is in the encoding used for filenames + * into a UTF-8 string. + * + * Return value: The converted string, or %NULL on an error. + **/ +gchar* +g_filename_to_utf8 (const gchar *opsysstring, + gssize len, + gsize *bytes_read, + gsize *bytes_written, + GError **error) +{ +#ifdef G_PLATFORM_WIN32 + return g_locale_to_utf8 (opsysstring, len, + bytes_read, bytes_written, + error); +#else /* !G_PLATFORM_WIN32 */ + + if (getenv ("G_BROKEN_FILENAMES")) + return g_locale_to_utf8 (opsysstring, len, + bytes_read, bytes_written, + error); + else + return strdup_len (opsysstring, len, bytes_read, bytes_written, error); +#endif /* !G_PLATFORM_WIN32 */ +} + +/** + * g_filename_from_utf8: + * @utf8string: a UTF-8 encoded string + * @len: the length of the string, or -1 if the string is + * NULL-terminated. + * @bytes_read: location to store the number of bytes in the + * input string that were successfully converted, or %NULL. + * Even if the conversion was succesful, this may be + * less than len if there were partial characters + * at the end of the input. If the error + * G_CONVERT_ERROR_ILLEGAL_SEQUENCE occurs, the value + * stored will the byte fofset after the last valid + * input sequence. + * @bytes_written: the stored in the output buffer (not including the + * terminating nul. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError may occur. + * + * Converts a string from UTF-8 to the encoding used for filenames. + * + * Return value: The converted string, or %NULL on an error. + **/ +gchar* +g_filename_from_utf8 (const gchar *utf8string, + gssize len, + gsize *bytes_read, + gsize *bytes_written, + GError **error) +{ +#ifdef G_PLATFORM_WIN32 + return g_locale_from_utf8 (utf8string, len, + bytes_read, bytes_written, + error); +#else /* !G_PLATFORM_WIN32 */ + if (getenv ("G_BROKEN_FILENAMES")) + return g_locale_from_utf8 (utf8string, len, + bytes_read, bytes_written, + error); + else + return strdup_len (utf8string, len, bytes_read, bytes_written, error); +#endif /* !G_PLATFORM_WIN32 */ +} + +/* Test of haystack has the needle prefix, comparing case + * insensitive. haystack may be UTF-8, but needle must + * contain only ascii. */ +static gboolean +has_case_prefix (const gchar *haystack, const gchar *needle) +{ + const gchar *h, *n; + + /* Eat one character at a time. */ + h = haystack; + n = needle; + + while (*n && *h && + g_ascii_tolower (*n) == g_ascii_tolower (*h)) + { + n++; + h++; + } + + return *n == '\0'; +} + +typedef enum { + UNSAFE_ALL = 0x1, /* Escape all unsafe characters */ + UNSAFE_ALLOW_PLUS = 0x2, /* Allows '+' */ + UNSAFE_PATH = 0x4, /* Allows '/' and '?' and '&' and '=' */ + UNSAFE_DOS_PATH = 0x8, /* Allows '/' and '?' and '&' and '=' and ':' */ + UNSAFE_HOST = 0x10, /* Allows '/' and ':' and '@' */ + UNSAFE_SLASHES = 0x20 /* Allows all characters except for '/' and '%' */ +} UnsafeCharacterSet; + +static const guchar acceptable[96] = { + /* X0 X1 X2 X3 X4 X5 X6 X7 X8 X9 XA XB XC XD XE XF */ + 0x00,0x3F,0x20,0x20,0x20,0x00,0x2C,0x3F,0x3F,0x3F,0x3F,0x22,0x20,0x3F,0x3F,0x1C, /* 2X !"#$%&'()*+,-./ */ + 0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x38,0x20,0x20,0x2C,0x20,0x2C, /* 3X 0123456789:;<=>? */ + 0x30,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F, /* 4X @ABCDEFGHIJKLMNO */ + 0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x20,0x20,0x20,0x20,0x3F, /* 5X PQRSTUVWXYZ[\]^_ */ + 0x20,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F, /* 6X `abcdefghijklmno */ + 0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x20,0x20,0x20,0x3F,0x20 /* 7X pqrstuvwxyz{|}~DEL */ +}; + +static const gchar hex[16] = "0123456789ABCDEF"; + +/* Note: This escape function works on file: URIs, but if you want to + * escape something else, please read RFC-2396 */ +static gchar * +g_escape_uri_string (const gchar *string, + UnsafeCharacterSet mask) +{ +#define ACCEPTABLE(a) ((a)>=32 && (a)<128 && (acceptable[(a)-32] & use_mask)) + + const gchar *p; + gchar *q; + gchar *result; + int c; + gint unacceptable; + UnsafeCharacterSet use_mask; + + g_return_val_if_fail (mask == UNSAFE_ALL + || mask == UNSAFE_ALLOW_PLUS + || mask == UNSAFE_PATH + || mask == UNSAFE_DOS_PATH + || mask == UNSAFE_HOST + || mask == UNSAFE_SLASHES, NULL); + + unacceptable = 0; + use_mask = mask; + for (p = string; *p != '\0'; p++) + { + c = *p; + if (!ACCEPTABLE (c)) + unacceptable++; + } + + result = g_malloc (p - string + unacceptable * 2 + 1); + + use_mask = mask; + for (q = result, p = string; *p != '\0'; p++) + { + c = (unsigned char)*p; + + if (!ACCEPTABLE (c)) + { + *q++ = '%'; /* means hex coming */ + *q++ = hex[c >> 4]; + *q++ = hex[c & 15]; + } + else + *q++ = *p; + } + + *q = '\0'; + + return result; +} + + +static gchar * +g_escape_file_uri (const gchar *hostname, + const gchar *pathname) +{ + char *escaped_hostname = NULL; + char *escaped_path; + char *res; + + if (hostname && *hostname != '\0') + { + escaped_hostname = g_escape_uri_string (hostname, UNSAFE_HOST); + } + + escaped_path = g_escape_uri_string (pathname, UNSAFE_DOS_PATH); + + res = g_strconcat ("file://", + (escaped_hostname) ? escaped_hostname : "", + (*escaped_path != '/') ? "/" : "", + escaped_path, + NULL); + + g_free (escaped_hostname); + g_free (escaped_path); + + return res; +} + +static int +unescape_character (const char *scanner) +{ + int first_digit; + int second_digit; + + first_digit = g_ascii_xdigit_value (*scanner++); + + if (first_digit < 0) + return -1; + + second_digit = g_ascii_xdigit_value (*scanner++); + if (second_digit < 0) + return -1; + + return (first_digit << 4) | second_digit; +} + +static gchar * +g_unescape_uri_string (const gchar *escaped, + const gchar *illegal_characters, + int len) +{ + const gchar *in, *in_end; + gchar *out, *result; + int character; + + if (escaped == NULL) + return NULL; + + if (len < 0) + len = strlen (escaped); + + result = g_malloc (len + 1); + + out = result; + for (in = escaped, in_end = escaped + len; in < in_end && *in != '\0'; in++) + { + character = *in; + if (character == '%') + { + character = unescape_character (in + 1); + + /* Check for an illegal character. We consider '\0' illegal here. */ + if (character == 0 + || (illegal_characters != NULL + && strchr (illegal_characters, (char)character) != NULL)) + { + g_free (result); + return NULL; + } + in += 2; + } + *out++ = character; + } + + *out = '\0'; + + g_assert (out - result <= strlen (escaped)); + + if (!g_utf8_validate (result, -1, NULL)) + { + g_free (result); + return NULL; + } + + return result; +} + +/** + * g_filename_from_uri: + * @uri: a uri describing a filename (escaped, encoded in UTF-8) + * @hostname: Location to store hostname for the URI, or %NULL. + * If there is no hostname in the URI, %NULL will be + * stored in this location. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError may occur. + * + * Converts an escaped UTF-8 encoded URI to a local filename in the + * encoding used for filenames. + * + * Return value: a newly allocated string holding the resulting + * filename, or %NULL on an error. + **/ +gchar * +g_filename_from_uri (const char *uri, + char **hostname, + GError **error) +{ + const char *path_part; + const char *host_part; + char *unescaped_hostname; + char *result; + char *filename; + int offs; + + if (hostname) + *hostname = NULL; + + if (!has_case_prefix (uri, "file:/")) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_NOT_ABSOLUTE_FILE_URI, + _("The URI `%s' is not an absolute URI using the file scheme"), + uri); + return NULL; + } + + path_part = uri + strlen ("file:"); + + if (strchr (path_part, '#') != NULL) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_INVALID_URI, + _("The local file URI `%s' may not include a `#'"), + uri); + return NULL; + } + + if (has_case_prefix (path_part, "///")) + path_part += 2; + else if (has_case_prefix (path_part, "//")) + { + path_part += 2; + host_part = path_part; + + path_part = strchr (path_part, '/'); + + if (path_part == NULL) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_INVALID_URI, + _("The URI `%s' is invalid"), + uri); + return NULL; + } + + unescaped_hostname = g_unescape_uri_string (host_part, "", path_part - host_part); + if (unescaped_hostname == NULL) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_INVALID_URI, + _("The hostname of the URI `%s' contains invalidly escaped characters"), + uri); + return NULL; + } + + if (hostname) + *hostname = unescaped_hostname; + else + g_free (unescaped_hostname); + } + + filename = g_unescape_uri_string (path_part, "/", -1); + + if (filename == NULL) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_INVALID_URI, + _("The URI `%s' contains invalidly escaped characters"), + uri); + return NULL; + } + + /* DOS uri's are like "file://host/c:\foo", so we need to check if we need to + * drop the initial slash */ + offs = 0; + if (g_path_is_absolute (filename+1)) + offs = 1; + + result = g_filename_from_utf8 (filename + offs, -1, NULL, NULL, error); + g_free (filename); + + return result; +} + +/** + * g_filename_to_uri: + * @filename: an absolute filename specified in the encoding + * used for filenames by the operating system. + * @hostname: A UTF-8 encoded hostname, or %NULL for none. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError may occur. + * + * Converts an absolute filename to an escaped UTF-8 encoded URI. + * + * Return value: a newly allocated string holding the resulting + * URI, or %NULL on an error. + **/ +gchar * +g_filename_to_uri (const char *filename, + char *hostname, + GError **error) +{ + char *escaped_uri; + char *utf8_filename; + + g_return_val_if_fail (filename != NULL, NULL); + + if (!g_path_is_absolute (filename)) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_NOT_ABSOLUTE_PATH, + _("The pathname '%s' is not an absolute path"), + filename); + return NULL; + } + + utf8_filename = g_filename_to_utf8 (filename, -1, NULL, NULL, error); + if (utf8_filename == NULL) + return NULL; + + if (hostname && + !g_utf8_validate (hostname, -1, NULL)) + { + g_free (utf8_filename); + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid byte sequence in hostname")); + return NULL; + } + + escaped_uri = g_escape_file_uri (hostname, + utf8_filename); + g_free (utf8_filename); + + return escaped_uri; +} + diff --git a/graf2d/win32gdk/gdk/src/glib/gconvert.h b/graf2d/win32gdk/gdk/src/glib/gconvert.h index ce19b36722b5b..a6e9d78744f27 100644 --- a/graf2d/win32gdk/gdk/src/glib/gconvert.h +++ b/graf2d/win32gdk/gdk/src/glib/gconvert.h @@ -28,7 +28,7 @@ #define __G_CONVERT_H__ #include <stddef.h> /* For size_t */ -#include <gerror.h> +#include <glib/gerror.h> G_BEGIN_DECLS @@ -37,11 +37,14 @@ typedef enum G_CONVERT_ERROR_NO_CONVERSION, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, G_CONVERT_ERROR_FAILED, - G_CONVERT_ERROR_PARTIAL_INPUT + G_CONVERT_ERROR_PARTIAL_INPUT, + G_CONVERT_ERROR_NOT_ABSOLUTE_FILE_URI, + G_CONVERT_ERROR_INVALID_URI, + G_CONVERT_ERROR_NOT_ABSOLUTE_PATH } GConvertError; #define G_CONVERT_ERROR g_convert_error_quark() -GQuark g_convert_error_quark(); +GQuark g_convert_error_quark (void); /* Thin wrappers around iconv */ @@ -51,39 +54,70 @@ GIConv g_iconv_open (const gchar *to_codeset, const gchar *from_codeset); size_t g_iconv (GIConv converter, gchar **inbuf, - size_t *inbytes_left, + gsize *inbytes_left, gchar **outbuf, - size_t *outbytes_left); + gsize *outbytes_left); gint g_iconv_close (GIConv converter); gchar* g_convert (const gchar *str, - gint len, + gssize len, const gchar *to_codeset, const gchar *from_codeset, - gint *bytes_read, - gint *bytes_written, + gsize *bytes_read, + gsize *bytes_written, + GError **error); +gchar* g_convert_with_iconv (const gchar *str, + gssize len, + GIConv converter, + gsize *bytes_read, + gsize *bytes_written, GError **error); gchar* g_convert_with_fallback (const gchar *str, - gint len, + gssize len, const gchar *to_codeset, const gchar *from_codeset, gchar *fallback, - gint *bytes_read, - gint *bytes_written, + gsize *bytes_read, + gsize *bytes_written, GError **error); /* Convert between libc's idea of strings and UTF-8. */ -gchar* g_locale_to_utf8 (const gchar *opsysstring, GError **error); -gchar* g_locale_from_utf8 (const gchar *utf8string, GError **error); +gchar* g_locale_to_utf8 (const gchar *opsysstring, + gssize len, + gsize *bytes_read, + gsize *bytes_written, + GError **error); +gchar* g_locale_from_utf8 (const gchar *utf8string, + gssize len, + gsize *bytes_read, + gsize *bytes_written, + GError **error); /* Convert between the operating system (or C runtime) * representation of file names and UTF-8. */ -gchar* g_filename_to_utf8 (const gchar *opsysstring, GError **error); -gchar* g_filename_from_utf8 (const gchar *utf8string, GError **error); +gchar* g_filename_to_utf8 (const gchar *opsysstring, + gssize len, + gsize *bytes_read, + gsize *bytes_written, + GError **error); +gchar* g_filename_from_utf8 (const gchar *utf8string, + gssize len, + gsize *bytes_read, + gsize *bytes_written, + GError **error); + +gchar *g_filename_from_uri (const char *uri, + char **hostname, + GError **error); + +gchar *g_filename_to_uri (const char *filename, + char *hostname, + GError **error); + G_END_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gdataset.c b/graf2d/win32gdk/gdk/src/glib/gdataset.c new file mode 100644 index 0000000000000..7d8d9afd47ffd --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gdataset.c @@ -0,0 +1,631 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * gdataset.c: Generic dataset mechanism, similar to GtkObject data. + * Copyright (C) 1998 Tim Janik + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe ; FIXME: might still freeze, watch out, not thoroughly + * looked at yet. + */ + +#include <string.h> +#include "glib.h" + + + +/* --- defines --- */ +#define G_QUARK_BLOCK_SIZE (512) +#define G_DATA_MEM_CHUNK_PREALLOC (128) +#define G_DATA_CACHE_MAX (512) +#define G_DATASET_MEM_CHUNK_PREALLOC (32) + + +/* --- structures --- */ +typedef struct _GDataset GDataset; +struct _GData +{ + GData *next; + GQuark id; + gpointer data; + GDestroyNotify destroy_func; +}; + +struct _GDataset +{ + gconstpointer location; + GData *datalist; +}; + + +/* --- prototypes --- */ +static inline GDataset* g_dataset_lookup (gconstpointer dataset_location); +static inline void g_datalist_clear_i (GData **datalist); +static void g_dataset_destroy_internal (GDataset *dataset); +static inline gpointer g_data_set_internal (GData **datalist, + GQuark key_id, + gpointer data, + GDestroyNotify destroy_func, + GDataset *dataset); +static void g_data_initialize (void); +static inline GQuark g_quark_new (gchar *string); + + +/* --- variables --- */ +G_LOCK_DEFINE_STATIC (g_dataset_global); +static GHashTable *g_dataset_location_ht = NULL; +static GDataset *g_dataset_cached = NULL; /* should this be + threadspecific? */ +static GMemChunk *g_dataset_mem_chunk = NULL; +static GMemChunk *g_data_mem_chunk = NULL; +static GData *g_data_cache = NULL; +static guint g_data_cache_length = 0; + +G_LOCK_DEFINE_STATIC (g_quark_global); +static GHashTable *g_quark_ht = NULL; +static gchar **g_quarks = NULL; +static GQuark g_quark_seq_id = 0; + + +/* --- functions --- */ + +/* HOLDS: g_dataset_global_lock */ +static inline void +g_datalist_clear_i (GData **datalist) +{ + register GData *list; + + /* unlink *all* items before walking their destructors + */ + list = *datalist; + *datalist = NULL; + + while (list) + { + register GData *prev; + + prev = list; + list = prev->next; + + if (prev->destroy_func) + { + G_UNLOCK (g_dataset_global); + prev->destroy_func (prev->data); + G_LOCK (g_dataset_global); + } + + if (g_data_cache_length < G_DATA_CACHE_MAX) + { + prev->next = g_data_cache; + g_data_cache = prev; + g_data_cache_length++; + } + else + g_mem_chunk_free (g_data_mem_chunk, prev); + } +} + +void +g_datalist_clear (GData **datalist) +{ + g_return_if_fail (datalist != NULL); + + G_LOCK (g_dataset_global); + if (!g_dataset_location_ht) + g_data_initialize (); + + while (*datalist) + g_datalist_clear_i (datalist); + G_UNLOCK (g_dataset_global); +} + +/* HOLDS: g_dataset_global_lock */ +static inline GDataset* +g_dataset_lookup (gconstpointer dataset_location) +{ + register GDataset *dataset; + + if (g_dataset_cached && g_dataset_cached->location == dataset_location) + return g_dataset_cached; + + dataset = g_hash_table_lookup (g_dataset_location_ht, dataset_location); + if (dataset) + g_dataset_cached = dataset; + + return dataset; +} + +/* HOLDS: g_dataset_global_lock */ +static void +g_dataset_destroy_internal (GDataset *dataset) +{ + register gconstpointer dataset_location; + + dataset_location = dataset->location; + while (dataset) + { + if (!dataset->datalist) + { + if (dataset == g_dataset_cached) + g_dataset_cached = NULL; + g_hash_table_remove (g_dataset_location_ht, dataset_location); + g_mem_chunk_free (g_dataset_mem_chunk, dataset); + break; + } + + g_datalist_clear_i (&dataset->datalist); + dataset = g_dataset_lookup (dataset_location); + } +} + +void +g_dataset_destroy (gconstpointer dataset_location) +{ + g_return_if_fail (dataset_location != NULL); + + G_LOCK (g_dataset_global); + if (g_dataset_location_ht) + { + register GDataset *dataset; + + dataset = g_dataset_lookup (dataset_location); + if (dataset) + g_dataset_destroy_internal (dataset); + } + G_UNLOCK (g_dataset_global); +} + +/* HOLDS: g_dataset_global_lock */ +static inline gpointer +g_data_set_internal (GData **datalist, + GQuark key_id, + gpointer data, + GDestroyNotify destroy_func, + GDataset *dataset) +{ + register GData *list; + + list = *datalist; + if (!data) + { + register GData *prev; + + prev = NULL; + while (list) + { + if (list->id == key_id) + { + gpointer ret_data = NULL; + + if (prev) + prev->next = list->next; + else + { + *datalist = list->next; + + /* the dataset destruction *must* be done + * prior to invokation of the data destroy function + */ + if (!*datalist && dataset) + g_dataset_destroy_internal (dataset); + } + + /* the GData struct *must* already be unlinked + * when invoking the destroy function. + * we use (data==NULL && destroy_func!=NULL) as + * a special hint combination to "steal" + * data without destroy notification + */ + if (list->destroy_func && !destroy_func) + { + G_UNLOCK (g_dataset_global); + list->destroy_func (list->data); + G_LOCK (g_dataset_global); + } + else + ret_data = list->data; + + if (g_data_cache_length < G_DATA_CACHE_MAX) + { + list->next = g_data_cache; + g_data_cache = list; + g_data_cache_length++; + } + else + g_mem_chunk_free (g_data_mem_chunk, list); + + return ret_data; + } + + prev = list; + list = list->next; + } + } + else + { + while (list) + { + if (list->id == key_id) + { + if (!list->destroy_func) + { + list->data = data; + list->destroy_func = destroy_func; + } + else + { + register GDestroyNotify dfunc; + register gpointer ddata; + + dfunc = list->destroy_func; + ddata = list->data; + list->data = data; + list->destroy_func = destroy_func; + + /* we need to have updated all structures prior to + * invokation of the destroy function + */ + G_UNLOCK (g_dataset_global); + dfunc (ddata); + G_LOCK (g_dataset_global); + } + + return NULL; + } + + list = list->next; + } + + if (g_data_cache) + { + list = g_data_cache; + g_data_cache = list->next; + g_data_cache_length--; + } + else + list = g_chunk_new (GData, g_data_mem_chunk); + list->next = *datalist; + list->id = key_id; + list->data = data; + list->destroy_func = destroy_func; + *datalist = list; + } + + return NULL; +} + +void +g_dataset_id_set_data_full (gconstpointer dataset_location, + GQuark key_id, + gpointer data, + GDestroyNotify destroy_func) +{ + register GDataset *dataset; + + g_return_if_fail (dataset_location != NULL); + if (!data) + g_return_if_fail (destroy_func == NULL); + if (!key_id) + { + if (data) + g_return_if_fail (key_id > 0); + else + return; + } + + G_LOCK (g_dataset_global); + if (!g_dataset_location_ht) + g_data_initialize (); + + dataset = g_dataset_lookup (dataset_location); + if (!dataset) + { + dataset = g_chunk_new (GDataset, g_dataset_mem_chunk); + dataset->location = dataset_location; + g_datalist_init (&dataset->datalist); + g_hash_table_insert (g_dataset_location_ht, + (gpointer) dataset->location, + dataset); + } + + g_data_set_internal (&dataset->datalist, key_id, data, destroy_func, dataset); + G_UNLOCK (g_dataset_global); +} + +void +g_datalist_id_set_data_full (GData **datalist, + GQuark key_id, + gpointer data, + GDestroyNotify destroy_func) +{ + g_return_if_fail (datalist != NULL); + if (!data) + g_return_if_fail (destroy_func == NULL); + if (!key_id) + { + if (data) + g_return_if_fail (key_id > 0); + else + return; + } + + G_LOCK (g_dataset_global); + if (!g_dataset_location_ht) + g_data_initialize (); + + g_data_set_internal (datalist, key_id, data, destroy_func, NULL); + G_UNLOCK (g_dataset_global); +} + +gpointer +g_dataset_id_remove_no_notify (gconstpointer dataset_location, + GQuark key_id) +{ + gpointer ret_data = NULL; + + g_return_val_if_fail (dataset_location != NULL, NULL); + + G_LOCK (g_dataset_global); + if (key_id && g_dataset_location_ht) + { + GDataset *dataset; + + dataset = g_dataset_lookup (dataset_location); + if (dataset) + ret_data = g_data_set_internal (&dataset->datalist, key_id, NULL, (GDestroyNotify) 42, dataset); + } + G_UNLOCK (g_dataset_global); + + return ret_data; +} + +gpointer +g_datalist_id_remove_no_notify (GData **datalist, + GQuark key_id) +{ + gpointer ret_data = NULL; + + g_return_val_if_fail (datalist != NULL, NULL); + + G_LOCK (g_dataset_global); + if (key_id && g_dataset_location_ht) + ret_data = g_data_set_internal (datalist, key_id, NULL, (GDestroyNotify) 42, NULL); + G_UNLOCK (g_dataset_global); + + return ret_data; +} + +gpointer +g_dataset_id_get_data (gconstpointer dataset_location, + GQuark key_id) +{ + g_return_val_if_fail (dataset_location != NULL, NULL); + + G_LOCK (g_dataset_global); + if (key_id && g_dataset_location_ht) + { + register GDataset *dataset; + + dataset = g_dataset_lookup (dataset_location); + if (dataset) + { + register GData *list; + + for (list = dataset->datalist; list; list = list->next) + if (list->id == key_id) + { + G_UNLOCK (g_dataset_global); + return list->data; + } + } + } + G_UNLOCK (g_dataset_global); + + return NULL; +} + +gpointer +g_datalist_id_get_data (GData **datalist, + GQuark key_id) +{ + g_return_val_if_fail (datalist != NULL, NULL); + + if (key_id) + { + register GData *list; + + for (list = *datalist; list; list = list->next) + if (list->id == key_id) + return list->data; + } + + return NULL; +} + +void +g_dataset_foreach (gconstpointer dataset_location, + GDataForeachFunc func, + gpointer user_data) +{ + register GDataset *dataset; + + g_return_if_fail (dataset_location != NULL); + g_return_if_fail (func != NULL); + + G_LOCK (g_dataset_global); + if (g_dataset_location_ht) + { + dataset = g_dataset_lookup (dataset_location); + G_UNLOCK (g_dataset_global); + if (dataset) + { + register GData *list, *next; + + for (list = dataset->datalist; list; list = next) + { + next = list->next; + func (list->id, list->data, user_data); + } + } + } + else + { + G_UNLOCK (g_dataset_global); + } +} + +void +g_datalist_foreach (GData **datalist, + GDataForeachFunc func, + gpointer user_data) +{ + register GData *list, *next; + + g_return_if_fail (datalist != NULL); + g_return_if_fail (func != NULL); + + for (list = *datalist; list; list = next) + { + next = list->next; + func (list->id, list->data, user_data); + } +} + +void +g_datalist_init (GData **datalist) +{ + g_return_if_fail (datalist != NULL); + + *datalist = NULL; +} + +/* HOLDS: g_dataset_global_lock */ +static void +g_data_initialize (void) +{ + g_return_if_fail (g_dataset_location_ht == NULL); + + g_dataset_location_ht = g_hash_table_new (g_direct_hash, NULL); + g_dataset_cached = NULL; + g_dataset_mem_chunk = + g_mem_chunk_new ("GDataset MemChunk", + sizeof (GDataset), + sizeof (GDataset) * G_DATASET_MEM_CHUNK_PREALLOC, + G_ALLOC_AND_FREE); + g_data_mem_chunk = + g_mem_chunk_new ("GData MemChunk", + sizeof (GData), + sizeof (GData) * G_DATA_MEM_CHUNK_PREALLOC, + G_ALLOC_AND_FREE); +} + +GQuark +g_quark_try_string (const gchar *string) +{ + GQuark quark = 0; + g_return_val_if_fail (string != NULL, 0); + + G_LOCK (g_quark_global); + if (g_quark_ht) + quark = GPOINTER_TO_UINT (g_hash_table_lookup (g_quark_ht, string)); + G_UNLOCK (g_quark_global); + + return quark; +} + +GQuark +g_quark_from_string (const gchar *string) +{ + GQuark quark; + + g_return_val_if_fail (string != NULL, 0); + + G_LOCK (g_quark_global); + if (g_quark_ht) + quark = (gulong) g_hash_table_lookup (g_quark_ht, string); + else + { + g_quark_ht = g_hash_table_new (g_str_hash, g_str_equal); + quark = 0; + } + + if (!quark) + quark = g_quark_new (g_strdup (string)); + G_UNLOCK (g_quark_global); + + return quark; +} + +GQuark +g_quark_from_static_string (const gchar *string) +{ + GQuark quark; + + g_return_val_if_fail (string != NULL, 0); + + G_LOCK (g_quark_global); + if (g_quark_ht) + quark = (gulong) g_hash_table_lookup (g_quark_ht, string); + else + { + g_quark_ht = g_hash_table_new (g_str_hash, g_str_equal); + quark = 0; + } + + if (!quark) + quark = g_quark_new ((gchar*) string); + G_UNLOCK (g_quark_global); + + return quark; +} + +G_CONST_RETURN gchar* +g_quark_to_string (GQuark quark) +{ + gchar* result = NULL; + G_LOCK (g_quark_global); + if (quark > 0 && quark <= g_quark_seq_id) + result = g_quarks[quark - 1]; + G_UNLOCK (g_quark_global); + + return result; +} + +/* HOLDS: g_quark_global_lock */ +static inline GQuark +g_quark_new (gchar *string) +{ + GQuark quark; + + if (g_quark_seq_id % G_QUARK_BLOCK_SIZE == 0) + g_quarks = g_renew (gchar*, g_quarks, g_quark_seq_id + G_QUARK_BLOCK_SIZE); + + g_quarks[g_quark_seq_id] = string; + g_quark_seq_id++; + quark = g_quark_seq_id; + g_hash_table_insert (g_quark_ht, string, GUINT_TO_POINTER (quark)); + + return quark; +} diff --git a/graf2d/win32gdk/gdk/src/glib/gdataset.h b/graf2d/win32gdk/gdk/src/glib/gdataset.h index f9d15b3088fea..e04a706c10276 100644 --- a/graf2d/win32gdk/gdk/src/glib/gdataset.h +++ b/graf2d/win32gdk/gdk/src/glib/gdataset.h @@ -27,7 +27,7 @@ #ifndef __G_DATASET_H__ #define __G_DATASET_H__ -#include <gquark.h> +#include <glib/gquark.h> G_BEGIN_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gdate.c b/graf2d/win32gdk/gdk/src/glib/gdate.c new file mode 100644 index 0000000000000..08b0334bb9df3 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gdate.c @@ -0,0 +1,1445 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#define DEBUG_MSG(x) /* */ +#ifdef G_ENABLE_DEBUG +/* #define DEBUG_MSG(args) g_message args ; */ +#endif + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include "glib.h" + +#include <time.h> +#include <string.h> +#include <ctype.h> +#include <stdlib.h> +#include <locale.h> + +GDate* +g_date_new () +{ + GDate *d = g_new0 (GDate, 1); /* happily, 0 is the invalid flag for everything. */ + + return d; +} + +GDate* +g_date_new_dmy (GDateDay day, GDateMonth m, GDateYear y) +{ + GDate *d; + g_return_val_if_fail (g_date_valid_dmy (day, m, y), NULL); + + d = g_new (GDate, 1); + + d->julian = FALSE; + d->dmy = TRUE; + + d->month = m; + d->day = day; + d->year = y; + + g_assert (g_date_valid (d)); + + return d; +} + +GDate* +g_date_new_julian (guint32 j) +{ + GDate *d; + g_return_val_if_fail (g_date_valid_julian (j), NULL); + + d = g_new (GDate, 1); + + d->julian = TRUE; + d->dmy = FALSE; + + d->julian_days = j; + + g_assert (g_date_valid (d)); + + return d; +} + +void +g_date_free (GDate *d) +{ + g_return_if_fail (d != NULL); + + g_free (d); +} + +gboolean +g_date_valid (const GDate *d) +{ + g_return_val_if_fail (d != NULL, FALSE); + + return (d->julian || d->dmy); +} + +static const guint8 days_in_months[2][13] = +{ /* error, jan feb mar apr may jun jul aug sep oct nov dec */ + { 0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 }, + { 0, 31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 } /* leap year */ +}; + +static const guint16 days_in_year[2][14] = +{ /* 0, jan feb mar apr may jun jul aug sep oct nov dec */ + { 0, 0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365 }, + { 0, 0, 31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 335, 366 } +}; + +gboolean +g_date_valid_month (GDateMonth m) +{ + return ( (m > G_DATE_BAD_MONTH) && (m < 13) ); +} + +gboolean +g_date_valid_year (GDateYear y) +{ + return ( y > G_DATE_BAD_YEAR ); +} + +gboolean +g_date_valid_day (GDateDay d) +{ + return ( (d > G_DATE_BAD_DAY) && (d < 32) ); +} + +gboolean +g_date_valid_weekday (GDateWeekday w) +{ + return ( (w > G_DATE_BAD_WEEKDAY) && (w < 8) ); +} + +gboolean +g_date_valid_julian (guint32 j) +{ + return (j > G_DATE_BAD_JULIAN); +} + +gboolean +g_date_valid_dmy (GDateDay d, + GDateMonth m, + GDateYear y) +{ + return ( (m > G_DATE_BAD_MONTH) && + (m < 13) && + (d > G_DATE_BAD_DAY) && + (y > G_DATE_BAD_YEAR) && /* must check before using g_date_is_leap_year */ + (d <= (g_date_is_leap_year (y) ? + days_in_months[1][m] : days_in_months[0][m])) ); +} + + +/* "Julian days" just means an absolute number of days, where Day 1 == + * Jan 1, Year 1 + */ +static void +g_date_update_julian (const GDate *const_d) +{ + GDate *d = (GDate *) const_d; + GDateYear year; + gint index; + + g_return_if_fail (d != NULL); + g_return_if_fail (d->dmy); + g_return_if_fail (!d->julian); + g_return_if_fail (g_date_valid_dmy (d->day, d->month, d->year)); + + /* What we actually do is: multiply years * 365 days in the year, + * add the number of years divided by 4, subtract the number of + * years divided by 100 and add the number of years divided by 400, + * which accounts for leap year stuff. Code from Steffen Beyer's + * DateCalc. + */ + + year = d->year - 1; /* we know d->year > 0 since it's valid */ + + d->julian_days = year * 365U; + d->julian_days += (year >>= 2); /* divide by 4 and add */ + d->julian_days -= (year /= 25); /* divides original # years by 100 */ + d->julian_days += year >> 2; /* divides by 4, which divides original by 400 */ + + index = g_date_is_leap_year (d->year) ? 1 : 0; + + d->julian_days += days_in_year[index][d->month] + d->day; + + g_return_if_fail (g_date_valid_julian (d->julian_days)); + + d->julian = TRUE; +} + +static void +g_date_update_dmy (const GDate *const_d) +{ + GDate *d = (GDate *) const_d; + GDateYear y; + GDateMonth m; + GDateDay day; + + guint32 A, B, C, D, E, M; + + g_return_if_fail (d != NULL); + g_return_if_fail (d->julian); + g_return_if_fail (!d->dmy); + g_return_if_fail (g_date_valid_julian (d->julian_days)); + + /* Formula taken from the Calendar FAQ; the formula was for the + * Julian Period which starts on 1 January 4713 BC, so we add + * 1,721,425 to the number of days before doing the formula. + * + * I'm sure this can be simplified for our 1 January 1 AD period + * start, but I can't figure out how to unpack the formula. + */ + + A = d->julian_days + 1721425 + 32045; + B = ( 4 *(A + 36524) )/ 146097 - 1; + C = A - (146097 * B)/4; + D = ( 4 * (C + 365) ) / 1461 - 1; + E = C - ((1461*D) / 4); + M = (5 * (E - 1) + 2)/153; + + m = M + 3 - (12*(M/10)); + day = E - (153*M + 2)/5; + y = 100 * B + D - 4800 + (M/10); + +#ifdef G_ENABLE_DEBUG + if (!g_date_valid_dmy (day, m, y)) + { + g_warning ("\nOOPS julian: %u computed dmy: %u %u %u\n", + d->julian_days, day, m, y); + } +#endif + + d->month = m; + d->day = day; + d->year = y; + + d->dmy = TRUE; +} + +GDateWeekday +g_date_get_weekday (const GDate *d) +{ + g_return_val_if_fail (d != NULL, G_DATE_BAD_WEEKDAY); + g_return_val_if_fail (g_date_valid (d), G_DATE_BAD_WEEKDAY); + + if (!d->julian) + { + g_date_update_julian (d); + } + g_return_val_if_fail (d->julian, G_DATE_BAD_WEEKDAY); + + return ((d->julian_days - 1) % 7) + 1; +} + +GDateMonth +g_date_get_month (const GDate *d) +{ + g_return_val_if_fail (d != NULL, G_DATE_BAD_MONTH); + g_return_val_if_fail (g_date_valid (d), G_DATE_BAD_MONTH); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_val_if_fail (d->dmy, G_DATE_BAD_MONTH); + + return d->month; +} + +GDateYear +g_date_get_year (const GDate *d) +{ + g_return_val_if_fail (d != NULL, G_DATE_BAD_YEAR); + g_return_val_if_fail (g_date_valid (d), G_DATE_BAD_YEAR); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_val_if_fail (d->dmy, G_DATE_BAD_YEAR); + + return d->year; +} + +GDateDay +g_date_get_day (const GDate *d) +{ + g_return_val_if_fail (d != NULL, G_DATE_BAD_DAY); + g_return_val_if_fail (g_date_valid (d), G_DATE_BAD_DAY); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_val_if_fail (d->dmy, G_DATE_BAD_DAY); + + return d->day; +} + +guint32 +g_date_get_julian (const GDate *d) +{ + g_return_val_if_fail (d != NULL, G_DATE_BAD_JULIAN); + g_return_val_if_fail (g_date_valid (d), G_DATE_BAD_JULIAN); + + if (!d->julian) + { + g_date_update_julian (d); + } + g_return_val_if_fail (d->julian, G_DATE_BAD_JULIAN); + + return d->julian_days; +} + +guint +g_date_get_day_of_year (const GDate *d) +{ + gint index; + + g_return_val_if_fail (d != NULL, 0); + g_return_val_if_fail (g_date_valid (d), 0); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_val_if_fail (d->dmy, 0); + + index = g_date_is_leap_year (d->year) ? 1 : 0; + + return (days_in_year[index][d->month] + d->day); +} + +guint +g_date_get_monday_week_of_year (const GDate *d) +{ + GDateWeekday wd; + guint day; + GDate first; + + g_return_val_if_fail (d != NULL, 0); + g_return_val_if_fail (g_date_valid (d), 0); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_val_if_fail (d->dmy, 0); + + g_date_clear (&first, 1); + + g_date_set_dmy (&first, 1, 1, d->year); + + wd = g_date_get_weekday (&first) - 1; /* make Monday day 0 */ + day = g_date_get_day_of_year (d) - 1; + + return ((day + wd)/7U + (wd == 0 ? 1 : 0)); +} + +guint +g_date_get_sunday_week_of_year (const GDate *d) +{ + GDateWeekday wd; + guint day; + GDate first; + + g_return_val_if_fail (d != NULL, 0); + g_return_val_if_fail (g_date_valid (d), 0); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_val_if_fail (d->dmy, 0); + + g_date_clear (&first, 1); + + g_date_set_dmy (&first, 1, 1, d->year); + + wd = g_date_get_weekday (&first); + if (wd == 7) wd = 0; /* make Sunday day 0 */ + day = g_date_get_day_of_year (d) - 1; + + return ((day + wd)/7U + (wd == 0 ? 1 : 0)); +} + +gint +g_date_days_between (const GDate *d1, + const GDate *d2) +{ + g_return_val_if_fail (d1 != NULL, 0); + g_return_val_if_fail (d2 != NULL, 0); + + g_return_val_if_fail (g_date_valid (d1), 0); + g_return_val_if_fail (g_date_valid (d2), 0); + + return (gint)g_date_get_julian (d2) - (gint)g_date_get_julian (d1); +} + +void +g_date_clear (GDate *d, guint ndates) +{ + g_return_if_fail (d != NULL); + g_return_if_fail (ndates != 0); + + memset (d, 0x0, ndates*sizeof (GDate)); +} + +G_LOCK_DEFINE_STATIC (g_date_global); + +/* These are for the parser, output to the user should use * + * g_date_strftime () - this creates more never-freed memory to annoy + * all those memory debugger users. :-) + */ + +static gchar *long_month_names[13] = +{ + "Error", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL +}; + +static gchar *short_month_names[13] = +{ + "Error", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL +}; + +/* This tells us if we need to update the parse info */ +static gchar *current_locale = NULL; + +/* order of these in the current locale */ +static GDateDMY dmy_order[3] = +{ + G_DATE_DAY, G_DATE_MONTH, G_DATE_YEAR +}; + +/* Where to chop two-digit years: i.e., for the 1930 default, numbers + * 29 and below are counted as in the year 2000, numbers 30 and above + * are counted as in the year 1900. + */ + +static GDateYear twodigit_start_year = 1930; + +/* It is impossible to enter a year between 1 AD and 99 AD with this + * in effect. + */ +static gboolean using_twodigit_years = FALSE; + +struct _GDateParseTokens { + gint num_ints; + gint n[3]; + guint month; +}; + +typedef struct _GDateParseTokens GDateParseTokens; + +#define NUM_LEN 10 + +/* HOLDS: g_date_global_lock */ +static void +g_date_fill_parse_tokens (const gchar *str, GDateParseTokens *pt) +{ + gchar num[4][NUM_LEN+1]; + gint i; + const guchar *s; + + /* We count 4, but store 3; so we can give an error + * if there are 4. + */ + num[0][0] = num[1][0] = num[2][0] = num[3][0] = '\0'; + + s = (const guchar *) str; + pt->num_ints = 0; + while (*s && pt->num_ints < 4) + { + + i = 0; + while (*s && isdigit (*s) && i <= NUM_LEN) + { + num[pt->num_ints][i] = *s; + ++s; + ++i; + } + + if (i > 0) + { + num[pt->num_ints][i] = '\0'; + ++(pt->num_ints); + } + + if (*s == '\0') break; + + ++s; + } + + pt->n[0] = pt->num_ints > 0 ? atoi (num[0]) : 0; + pt->n[1] = pt->num_ints > 1 ? atoi (num[1]) : 0; + pt->n[2] = pt->num_ints > 2 ? atoi (num[2]) : 0; + + pt->month = G_DATE_BAD_MONTH; + + if (pt->num_ints < 3) + { + gchar *casefold; + gchar *normalized; + + casefold = g_utf8_casefold (str, -1); + normalized = g_utf8_normalize (casefold, -1, G_NORMALIZE_ALL); + g_free (casefold); + + i = 1; + while (i < 13) + { + if (long_month_names[i] != NULL) + { + const gchar *found = strstr (normalized, long_month_names[i]); + + if (found != NULL) + { + pt->month = i; + return; + } + } + + if (short_month_names[i] != NULL) + { + const gchar *found = strstr (normalized, short_month_names[i]); + + if (found != NULL) + { + pt->month = i; + return; + } + } + + ++i; + } + } +} + +/* HOLDS: g_date_global_lock */ +static void +g_date_prepare_to_parse (const gchar *str, GDateParseTokens *pt) +{ + const gchar *locale = setlocale (LC_TIME, NULL); + gboolean recompute_localeinfo = FALSE; + GDate d; + + g_return_if_fail (locale != NULL); /* should not happen */ + + g_date_clear (&d, 1); /* clear for scratch use */ + + if ( (current_locale == NULL) || (strcmp (locale, current_locale) != 0) ) + { + recompute_localeinfo = TRUE; /* Uh, there used to be a reason for the temporary */ + } + + if (recompute_localeinfo) + { + int i = 1; + GDateParseTokens testpt; + gchar buf[128]; + + g_free (current_locale); /* still works if current_locale == NULL */ + + current_locale = g_strdup (locale); + + while (i < 13) + { + gchar *casefold; + + g_date_set_dmy (&d, 1, i, 1); + + g_return_if_fail (g_date_valid (&d)); + + g_date_strftime (buf, 127, "%b", &d); + + casefold = g_utf8_casefold (buf, -1); + g_free (short_month_names[i]); + short_month_names[i] = g_utf8_normalize (casefold, -1, G_NORMALIZE_ALL); + g_free (casefold); + + g_date_strftime (buf, 127, "%B", &d); + casefold = g_utf8_casefold (buf, -1); + g_free (long_month_names[i]); + long_month_names[i] = g_utf8_normalize (casefold, -1, G_NORMALIZE_ALL); + g_free (casefold); + + ++i; + } + + /* Determine DMY order */ + + /* had to pick a random day - don't change this, some strftimes + * are broken on some days, and this one is good so far. */ + g_date_set_dmy (&d, 4, 7, 1976); + + g_date_strftime (buf, 127, "%x", &d); + + g_date_fill_parse_tokens (buf, &testpt); + + i = 0; + while (i < testpt.num_ints) + { + switch (testpt.n[i]) + { + case 7: + dmy_order[i] = G_DATE_MONTH; + break; + case 4: + dmy_order[i] = G_DATE_DAY; + break; + case 76: + using_twodigit_years = TRUE; /* FALL THRU */ + case 1976: + dmy_order[i] = G_DATE_YEAR; + break; + default: + /* leave it unchanged */ + break; + } + ++i; + } + +#ifdef G_ENABLE_DEBUG + DEBUG_MSG (("**GDate prepared a new set of locale-specific parse rules.")); + i = 1; + while (i < 13) + { + DEBUG_MSG ((" %s %s", long_month_names[i], short_month_names[i])); + ++i; + } + if (using_twodigit_years) + DEBUG_MSG (("**Using twodigit years with cutoff year: %u", twodigit_start_year)); + { + gchar *strings[3]; + i = 0; + while (i < 3) + { + switch (dmy_order[i]) + { + case G_DATE_MONTH: + strings[i] = "Month"; + break; + case G_DATE_YEAR: + strings[i] = "Year"; + break; + case G_DATE_DAY: + strings[i] = "Day"; + break; + default: + strings[i] = NULL; + break; + } + ++i; + } + DEBUG_MSG (("**Order: %s, %s, %s", strings[0], strings[1], strings[2])); + DEBUG_MSG (("**Sample date in this locale: `%s'", buf)); + } +#endif + } + + g_date_fill_parse_tokens (str, pt); +} + +void +g_date_set_parse (GDate *d, + const gchar *str) +{ + GDateParseTokens pt; + guint m = G_DATE_BAD_MONTH, day = G_DATE_BAD_DAY, y = G_DATE_BAD_YEAR; + + g_return_if_fail (d != NULL); + + /* set invalid */ + g_date_clear (d, 1); + + G_LOCK (g_date_global); + + g_date_prepare_to_parse (str, &pt); + + DEBUG_MSG (("Found %d ints, `%d' `%d' `%d' and written out month %d", + pt.num_ints, pt.n[0], pt.n[1], pt.n[2], pt.month)); + + + if (pt.num_ints == 4) + { + G_UNLOCK (g_date_global); + return; /* presumably a typo; bail out. */ + } + + if (pt.num_ints > 1) + { + int i = 0; + int j = 0; + + g_assert (pt.num_ints < 4); /* i.e., it is 2 or 3 */ + + while (i < pt.num_ints && j < 3) + { + switch (dmy_order[j]) + { + case G_DATE_MONTH: + { + if (pt.num_ints == 2 && pt.month != G_DATE_BAD_MONTH) + { + m = pt.month; + ++j; /* skip months, but don't skip this number */ + continue; + } + else + m = pt.n[i]; + } + break; + case G_DATE_DAY: + { + if (pt.num_ints == 2 && pt.month == G_DATE_BAD_MONTH) + { + day = 1; + ++j; /* skip days, since we may have month/year */ + continue; + } + day = pt.n[i]; + } + break; + case G_DATE_YEAR: + { + y = pt.n[i]; + + if (using_twodigit_years && y < 100) + { + guint two = twodigit_start_year % 100; + guint century = (twodigit_start_year / 100) * 100; + + if (y < two) + century += 100; + + y += century; + } + } + break; + default: + break; + } + + ++i; + ++j; + } + + + if (pt.num_ints == 3 && !g_date_valid_dmy (day, m, y)) + { + /* Try YYYY MM DD */ + y = pt.n[0]; + m = pt.n[1]; + day = pt.n[2]; + + if (using_twodigit_years && y < 100) + y = G_DATE_BAD_YEAR; /* avoids ambiguity */ + } + else if (pt.num_ints == 2) + { + if (m == G_DATE_BAD_MONTH && pt.month != G_DATE_BAD_MONTH) + { + m = pt.month; + } + } + } + else if (pt.num_ints == 1) + { + if (pt.month != G_DATE_BAD_MONTH) + { + /* Month name and year? */ + m = pt.month; + day = 1; + y = pt.n[0]; + } + else + { + /* Try yyyymmdd and yymmdd */ + + m = (pt.n[0]/100) % 100; + day = pt.n[0] % 100; + y = pt.n[0]/10000; + + /* FIXME move this into a separate function */ + if (using_twodigit_years && y < 100) + { + guint two = twodigit_start_year % 100; + guint century = (twodigit_start_year / 100) * 100; + + if (y < two) + century += 100; + + y += century; + } + } + } + + /* See if we got anything valid out of all this. */ + /* y < 8000 is to catch 19998 style typos; the library is OK up to 65535 or so */ + if (y < 8000 && g_date_valid_dmy (day, m, y)) + { + d->month = m; + d->day = day; + d->year = y; + d->dmy = TRUE; + } +#ifdef G_ENABLE_DEBUG + else + DEBUG_MSG (("Rejected DMY %u %u %u", day, m, y)); +#endif + G_UNLOCK (g_date_global); +} + +void +g_date_set_time (GDate *d, + GTime time) +{ + time_t t = time; + struct tm tm; + + g_return_if_fail (d != NULL); + +#ifdef HAVE_LOCALTIME_R + localtime_r (&t, &tm); +#else + { + struct tm *ptm = localtime (&t); + g_assert (ptm); + memcpy ((void *) &tm, (void *) ptm, sizeof(struct tm)); + } +#endif + + d->julian = FALSE; + + d->month = tm.tm_mon + 1; + d->day = tm.tm_mday; + d->year = tm.tm_year + 1900; + + g_return_if_fail (g_date_valid_dmy (d->day, d->month, d->year)); + + d->dmy = TRUE; +} + +void +g_date_set_month (GDate *d, + GDateMonth m) +{ + g_return_if_fail (d != NULL); + g_return_if_fail (g_date_valid_month (m)); + + if (d->julian && !d->dmy) g_date_update_dmy(d); + d->julian = FALSE; + + d->month = m; + + if (g_date_valid_dmy (d->day, d->month, d->year)) + d->dmy = TRUE; + else + d->dmy = FALSE; +} + +void +g_date_set_day (GDate *d, + GDateDay day) +{ + g_return_if_fail (d != NULL); + g_return_if_fail (g_date_valid_day (day)); + + if (d->julian && !d->dmy) g_date_update_dmy(d); + d->julian = FALSE; + + d->day = day; + + if (g_date_valid_dmy (d->day, d->month, d->year)) + d->dmy = TRUE; + else + d->dmy = FALSE; +} + +void +g_date_set_year (GDate *d, + GDateYear y) +{ + g_return_if_fail (d != NULL); + g_return_if_fail (g_date_valid_year (y)); + + if (d->julian && !d->dmy) g_date_update_dmy(d); + d->julian = FALSE; + + d->year = y; + + if (g_date_valid_dmy (d->day, d->month, d->year)) + d->dmy = TRUE; + else + d->dmy = FALSE; +} + +void +g_date_set_dmy (GDate *d, + GDateDay day, + GDateMonth m, + GDateYear y) +{ + g_return_if_fail (d != NULL); + g_return_if_fail (g_date_valid_dmy (day, m, y)); + + d->julian = FALSE; + + d->month = m; + d->day = day; + d->year = y; + + d->dmy = TRUE; +} + +void +g_date_set_julian (GDate *d, guint32 j) +{ + g_return_if_fail (d != NULL); + g_return_if_fail (g_date_valid_julian (j)); + + d->julian_days = j; + d->julian = TRUE; + d->dmy = FALSE; +} + + +gboolean +g_date_is_first_of_month (const GDate *d) +{ + g_return_val_if_fail (d != NULL, FALSE); + g_return_val_if_fail (g_date_valid (d), FALSE); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_val_if_fail (d->dmy, FALSE); + + if (d->day == 1) return TRUE; + else return FALSE; +} + +gboolean +g_date_is_last_of_month (const GDate *d) +{ + gint index; + + g_return_val_if_fail (d != NULL, FALSE); + g_return_val_if_fail (g_date_valid (d), FALSE); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_val_if_fail (d->dmy, FALSE); + + index = g_date_is_leap_year (d->year) ? 1 : 0; + + if (d->day == days_in_months[index][d->month]) return TRUE; + else return FALSE; +} + +void +g_date_add_days (GDate *d, guint ndays) +{ + g_return_if_fail (d != NULL); + g_return_if_fail (g_date_valid (d)); + + if (!d->julian) + { + g_date_update_julian (d); + } + g_return_if_fail (d->julian); + + d->julian_days += ndays; + d->dmy = FALSE; +} + +void +g_date_subtract_days (GDate *d, guint ndays) +{ + g_return_if_fail (d != NULL); + g_return_if_fail (g_date_valid (d)); + + if (!d->julian) + { + g_date_update_julian (d); + } + g_return_if_fail (d->julian); + g_return_if_fail (d->julian_days > ndays); + + d->julian_days -= ndays; + d->dmy = FALSE; +} + +void +g_date_add_months (GDate *d, + guint nmonths) +{ + guint years, months; + gint index; + + g_return_if_fail (d != NULL); + g_return_if_fail (g_date_valid (d)); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_if_fail (d->dmy); + + nmonths += d->month - 1; + + years = nmonths/12; + months = nmonths%12; + + d->month = months + 1; + d->year += years; + + index = g_date_is_leap_year (d->year) ? 1 : 0; + + if (d->day > days_in_months[index][d->month]) + d->day = days_in_months[index][d->month]; + + d->julian = FALSE; + + g_return_if_fail (g_date_valid (d)); +} + +void +g_date_subtract_months (GDate *d, + guint nmonths) +{ + guint years, months; + gint index; + + g_return_if_fail (d != NULL); + g_return_if_fail (g_date_valid (d)); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_if_fail (d->dmy); + + years = nmonths/12; + months = nmonths%12; + + g_return_if_fail (d->year > years); + + d->year -= years; + + if (d->month > months) d->month -= months; + else + { + months -= d->month; + d->month = 12 - months; + d->year -= 1; + } + + index = g_date_is_leap_year (d->year) ? 1 : 0; + + if (d->day > days_in_months[index][d->month]) + d->day = days_in_months[index][d->month]; + + d->julian = FALSE; + + g_return_if_fail (g_date_valid (d)); +} + +void +g_date_add_years (GDate *d, + guint nyears) +{ + g_return_if_fail (d != NULL); + g_return_if_fail (g_date_valid (d)); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_if_fail (d->dmy); + + d->year += nyears; + + if (d->month == 2 && d->day == 29) + { + if (!g_date_is_leap_year (d->year)) + { + d->day = 28; + } + } + + d->julian = FALSE; +} + +void +g_date_subtract_years (GDate *d, + guint nyears) +{ + g_return_if_fail (d != NULL); + g_return_if_fail (g_date_valid (d)); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_if_fail (d->dmy); + g_return_if_fail (d->year > nyears); + + d->year -= nyears; + + if (d->month == 2 && d->day == 29) + { + if (!g_date_is_leap_year (d->year)) + { + d->day = 28; + } + } + + d->julian = FALSE; +} + + +gboolean +g_date_is_leap_year (GDateYear year) +{ + g_return_val_if_fail (g_date_valid_year (year), FALSE); + + return ( (((year % 4) == 0) && ((year % 100) != 0)) || + (year % 400) == 0 ); +} + +guint8 +g_date_get_days_in_month (GDateMonth month, + GDateYear year) +{ + gint index; + + g_return_val_if_fail (g_date_valid_year (year), 0); + g_return_val_if_fail (g_date_valid_month (month), 0); + + index = g_date_is_leap_year (year) ? 1 : 0; + + return days_in_months[index][month]; +} + +guint8 +g_date_get_monday_weeks_in_year (GDateYear year) +{ + GDate d; + + g_return_val_if_fail (g_date_valid_year (year), 0); + + g_date_clear (&d, 1); + g_date_set_dmy (&d, 1, 1, year); + if (g_date_get_weekday (&d) == G_DATE_MONDAY) return 53; + g_date_set_dmy (&d, 31, 12, year); + if (g_date_get_weekday (&d) == G_DATE_MONDAY) return 53; + if (g_date_is_leap_year (year)) + { + g_date_set_dmy (&d, 2, 1, year); + if (g_date_get_weekday (&d) == G_DATE_MONDAY) return 53; + g_date_set_dmy (&d, 30, 12, year); + if (g_date_get_weekday (&d) == G_DATE_MONDAY) return 53; + } + return 52; +} + +guint8 +g_date_get_sunday_weeks_in_year (GDateYear year) +{ + GDate d; + + g_return_val_if_fail (g_date_valid_year (year), 0); + + g_date_clear (&d, 1); + g_date_set_dmy (&d, 1, 1, year); + if (g_date_get_weekday (&d) == G_DATE_SUNDAY) return 53; + g_date_set_dmy (&d, 31, 12, year); + if (g_date_get_weekday (&d) == G_DATE_SUNDAY) return 53; + if (g_date_is_leap_year (year)) + { + g_date_set_dmy (&d, 2, 1, year); + if (g_date_get_weekday (&d) == G_DATE_SUNDAY) return 53; + g_date_set_dmy (&d, 30, 12, year); + if (g_date_get_weekday (&d) == G_DATE_SUNDAY) return 53; + } + return 52; +} + +gint +g_date_compare (const GDate *lhs, + const GDate *rhs) +{ + g_return_val_if_fail (lhs != NULL, 0); + g_return_val_if_fail (rhs != NULL, 0); + g_return_val_if_fail (g_date_valid (lhs), 0); + g_return_val_if_fail (g_date_valid (rhs), 0); + + /* Remember the self-comparison case! I think it works right now. */ + + while (TRUE) + { + + if (lhs->julian && rhs->julian) + { + if (lhs->julian_days < rhs->julian_days) return -1; + else if (lhs->julian_days > rhs->julian_days) return 1; + else return 0; + } + else if (lhs->dmy && rhs->dmy) + { + if (lhs->year < rhs->year) return -1; + else if (lhs->year > rhs->year) return 1; + else + { + if (lhs->month < rhs->month) return -1; + else if (lhs->month > rhs->month) return 1; + else + { + if (lhs->day < rhs->day) return -1; + else if (lhs->day > rhs->day) return 1; + else return 0; + } + + } + + } + else + { + if (!lhs->julian) g_date_update_julian (lhs); + if (!rhs->julian) g_date_update_julian (rhs); + g_return_val_if_fail (lhs->julian, 0); + g_return_val_if_fail (rhs->julian, 0); + } + + } + return 0; /* warnings */ +} + + +void +g_date_to_struct_tm (const GDate *d, + struct tm *tm) +{ + GDateWeekday day; + + g_return_if_fail (d != NULL); + g_return_if_fail (g_date_valid (d)); + g_return_if_fail (tm != NULL); + + if (!d->dmy) + { + g_date_update_dmy (d); + } + g_return_if_fail (d->dmy); + + /* zero all the irrelevant fields to be sure they're valid */ + + /* On Linux and maybe other systems, there are weird non-POSIX + * fields on the end of struct tm that choke strftime if they + * contain garbage. So we need to 0 the entire struct, not just the + * fields we know to exist. + */ + + memset (tm, 0x0, sizeof (struct tm)); + + tm->tm_mday = d->day; + tm->tm_mon = d->month - 1; /* 0-11 goes in tm */ + tm->tm_year = ((int)d->year) - 1900; /* X/Open says tm_year can be negative */ + + day = g_date_get_weekday (d); + if (day == 7) day = 0; /* struct tm wants days since Sunday, so Sunday is 0 */ + + tm->tm_wday = (int)day; + + tm->tm_yday = g_date_get_day_of_year (d) - 1; /* 0 to 365 */ + tm->tm_isdst = -1; /* -1 means "information not available" */ +} + +void +g_date_clamp (GDate *date, + const GDate *min_date, + const GDate *max_date) +{ + g_return_if_fail (date); + g_return_if_fail (g_date_valid (date)); + if (min_date != NULL) + g_return_if_fail (g_date_valid (min_date)); + if (max_date != NULL) + g_return_if_fail (g_date_valid (max_date)); + if (min_date != NULL && max_date != NULL) + g_return_if_fail (g_date_compare (min_date, max_date) <= 0); + + if (min_date && g_date_compare (date, min_date) < 0) + *date = *min_date; + + if (max_date && g_date_compare (max_date, date) < 0) + *date = *max_date; +} + +void +g_date_order (GDate *date1, + GDate *date2) +{ + g_return_if_fail (date1 != NULL); + g_return_if_fail (date2 != NULL); + g_return_if_fail (g_date_valid (date1)); + g_return_if_fail (g_date_valid (date2)); + + if (g_date_compare (date1, date2) == 1) { + GDate tmp = *date1; + *date1 = *date2; + *date2 = tmp; + } +} + +gsize +g_date_strftime (gchar *s, + gsize slen, + const gchar *format, + const GDate *d) +{ + struct tm tm; + const gchar *charset; + + g_return_val_if_fail (d != NULL, 0); + g_return_val_if_fail (g_date_valid (d), 0); + g_return_val_if_fail (slen > 0, 0); + g_return_val_if_fail (format != 0, 0); + g_return_val_if_fail (s != 0, 0); + + g_date_to_struct_tm (d, &tm); + + if (g_get_charset (&charset)) + { + gint retval = strftime (s, slen, format, &tm); + if (retval == 0) + { + /* If retval == 0, the contents of s are undefined. We define + * them. + */ + s[0] = '\0'; + } + + return retval; + } + else + { + gchar *locale_format; + gsize tmplen; + gchar *tmpbuf; + gsize tmpbufsize; + gsize convlen = 0; + gchar *convbuf; + GError *error = NULL; + + locale_format = g_convert (format, -1 , "UTF-8", charset, + NULL, NULL, &error); + if (error) + { + g_warning (G_STRLOC "Error converting format to %s: %s\n", + charset, error->message); + g_error_free (error); + + return 0; + } + + tmpbufsize = MAX (128, strlen (locale_format) * 2); + while (TRUE) + { + tmpbuf = g_malloc (tmpbufsize + 1); + tmplen = strftime (tmpbuf, tmpbufsize + 1, locale_format, &tm); + if (tmplen == tmpbufsize + 1) + { + g_free (tmpbuf); + tmpbufsize *= 2; + } + else + break; + } + g_free (locale_format); + + if (tmplen == 0) + { + /* If retval == 0, the contents of s are undefined. We define + * them. + */ + g_free (locale_format); + s[0] = '\0'; + return 0; + } + + convbuf = g_convert (tmpbuf, tmplen, "UTF-8", charset, NULL, &convlen, &error); + g_free (tmpbuf); + + if (error) + { + g_warning (G_STRLOC "Error converting results of strftime to UTF-8: %s\n", error->message); + g_error_free (error); + } + else + { + /* Only copy whole characters into the buffer + */ + gchar *in = convbuf; + gchar *out = s; + gchar *end = s + slen - 1; + + while (*in) + { + int len = g_utf8_skip[*(guchar *)in]; + if (out + len < end) + { + out += len; + in += len; + } + else + break; + } + + memcpy (s, convbuf, out - s); + *out = '\0'; + } + + g_free (convbuf); + + return convlen; + } +} diff --git a/graf2d/win32gdk/gdk/src/glib/gdate.h b/graf2d/win32gdk/gdk/src/glib/gdate.h index c5fa2dc2c3606..96d827f66b2f8 100644 --- a/graf2d/win32gdk/gdk/src/glib/gdate.h +++ b/graf2d/win32gdk/gdk/src/glib/gdate.h @@ -27,7 +27,7 @@ #ifndef __G_DATE_H__ #define __G_DATE_H__ -#include <gquark.h> +#include <glib/gquark.h> G_BEGIN_DECLS @@ -126,7 +126,7 @@ void g_date_free (GDate *date); * dates (the exceptions are the mutators, since you need those to * return to validity). */ -gboolean g_date_valid (GDate *date); +gboolean g_date_valid (const GDate *date); gboolean g_date_valid_day (GDateDay day) G_GNUC_CONST; gboolean g_date_valid_month (GDateMonth month) G_GNUC_CONST; gboolean g_date_valid_year (GDateYear year) G_GNUC_CONST; @@ -136,20 +136,20 @@ gboolean g_date_valid_dmy (GDateDay day, GDateMonth month, GDateYear year) G_GNUC_CONST; -GDateWeekday g_date_get_weekday (GDate *date); -GDateMonth g_date_get_month (GDate *date); -GDateYear g_date_get_year (GDate *date); -GDateDay g_date_get_day (GDate *date); -guint32 g_date_get_julian (GDate *date); -guint g_date_get_day_of_year (GDate *date); +GDateWeekday g_date_get_weekday (const GDate *date); +GDateMonth g_date_get_month (const GDate *date); +GDateYear g_date_get_year (const GDate *date); +GDateDay g_date_get_day (const GDate *date); +guint32 g_date_get_julian (const GDate *date); +guint g_date_get_day_of_year (const GDate *date); /* First monday/sunday is the start of week 1; if we haven't reached * that day, return 0. These are not ISO weeks of the year; that * routine needs to be added. * these functions return the number of weeks, starting on the * corrsponding day */ -guint g_date_get_monday_week_of_year (GDate *date); -guint g_date_get_sunday_week_of_year (GDate *date); +guint g_date_get_monday_week_of_year (const GDate *date); +guint g_date_get_sunday_week_of_year (const GDate *date); /* If you create a static date struct you need to clear it to get it * in a sane state before use. You can clear a whole array at @@ -178,8 +178,8 @@ void g_date_set_dmy (GDate *date, GDateYear y); void g_date_set_julian (GDate *date, guint32 julian_date); -gboolean g_date_is_first_of_month (GDate *date); -gboolean g_date_is_last_of_month (GDate *date); +gboolean g_date_is_first_of_month (const GDate *date); +gboolean g_date_is_last_of_month (const GDate *date); /* To go forward by some number of weeks just go forward weeks*7 days */ void g_date_add_days (GDate *date, @@ -204,19 +204,47 @@ guint8 g_date_get_days_in_month (GDateMonth month, guint8 g_date_get_monday_weeks_in_year (GDateYear year) G_GNUC_CONST; guint8 g_date_get_sunday_weeks_in_year (GDateYear year) G_GNUC_CONST; +/* Returns the number of days between the two dates. If date2 comes + before date1, a negative value is return. */ +gint g_date_days_between (const GDate *date1, + const GDate *date2); + /* qsort-friendly (with a cast...) */ -gint g_date_compare (GDate *lhs, - GDate *rhs); -void g_date_to_struct_tm (GDate *date, +gint g_date_compare (const GDate *lhs, + const GDate *rhs); +void g_date_to_struct_tm (const GDate *date, struct tm *tm); +void g_date_clamp (GDate *date, + const GDate *min_date, + const GDate *max_date); + +/* Swap date1 and date2's values if date1 > date2. */ +void g_date_order (GDate *date1, GDate *date2); + /* Just like strftime() except you can only use date-related formats. * Using a time format is undefined. */ gsize g_date_strftime (gchar *s, gsize slen, const gchar *format, - GDate *date); + const GDate *date); + +#ifndef G_DISABLE_DEPRECATED + +#define g_date_weekday g_date_get_weekday +#define g_date_month g_date_get_month +#define g_date_year g_date_get_year +#define g_date_day g_date_get_day +#define g_date_julian g_date_get_julian +#define g_date_day_of_year g_date_get_day_of_year +#define g_date_monday_week_of_year g_date_get_monday_week_of_year +#define g_date_sunday_week_of_year g_date_get_sunday_week_of_year +#define g_date_days_in_month g_date_get_days_in_month +#define g_date_monday_weeks_in_year g_date_get_monday_weeks_in_year +#define g_date_sunday_weeks_in_year g_date_get_sunday_weeks_in_year + +#endif /* G_DISABLE_DEPRECATED */ G_END_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gerror.c b/graf2d/win32gdk/gdk/src/glib/gerror.c new file mode 100644 index 0000000000000..eff62588a85ec --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gerror.c @@ -0,0 +1,254 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +#include "glib.h" + +static GError* +g_error_new_valist(GQuark domain, + gint code, + const gchar *format, + va_list args) +{ + GError *error; + + error = g_new (GError, 1); + + error->domain = domain; + error->code = code; + error->message = g_strdup_vprintf (format, args); + + return error; +} + +/** + * g_error_new: + * @domain: error domain + * @code: error code + * @format: printf()-style format for error message + * @Varargs: parameters for message format + * + * Creates a new #GError with the given @domain and @code, + * and a message formatted with @format. + * + * Return value: a new #GError + **/ +GError* +g_error_new (GQuark domain, + gint code, + const gchar *format, + ...) +{ + GError* error; + va_list args; + + g_return_val_if_fail (format != NULL, NULL); + g_return_val_if_fail (domain != 0, NULL); + + va_start (args, format); + error = g_error_new_valist (domain, code, format, args); + va_end (args); + + return error; +} + +/** + * g_error_new_literal: + * @domain: error domain + * @code: error code + * @message: error message + * + * Creates a new #GError; unlike g_error_new(), @message is not + * a printf()-style format string. Use this function if @message + * contains text you don't have control over, that could include + * printf() escape sequences. + * + * Return value: a new #GError + **/ +GError* +g_error_new_literal (GQuark domain, + gint code, + const gchar *message) +{ + GError* err; + + g_return_val_if_fail (message != NULL, NULL); + g_return_val_if_fail (domain != 0, NULL); + + err = g_new (GError, 1); + + err->domain = domain; + err->code = code; + err->message = g_strdup (message); + + return err; +} + +/** + * g_error_free: + * @error: a #GError + * + * Frees a #GError and associated resources. + * + **/ +void +g_error_free (GError *error) +{ + g_return_if_fail (error != NULL); + + g_free (error->message); + + g_free (error); +} + +/** + * g_error_copy: + * @error: a #GError + * + * Makes a copy of @error. + * + * Return value: a new #GError + **/ +GError* +g_error_copy (const GError *error) +{ + GError *copy; + + g_return_val_if_fail (error != NULL, NULL); + + copy = g_new (GError, 1); + + *copy = *error; + + copy->message = g_strdup (error->message); + + return copy; +} + +/** + * g_error_matches: + * @error: a #GError + * @domain: an error domain + * @code: an error code + * + * Returns TRUE if @error matches @domain and @code, FALSE + * otherwise. + * + * Return value: whether @error has @domain and @code + **/ +gboolean +g_error_matches (const GError *error, + GQuark domain, + gint code) +{ + return error && + error->domain == domain && + error->code == code; +} + +#define ERROR_OVERWRITTEN_WARNING "GError set over the top of a previous GError or uninitialized memory.\n" \ + "This indicates a bug in someone's code. You must ensure an error is NULL before it's set.\n" \ + "The overwriting error message was: %s" + +/** + * g_set_error: + * @err: a return location for a #GError, or NULL + * @domain: error domain + * @code: error code + * @format: printf()-style format + * @Varargs: args for @format + * + * Does nothing if @err is NULL; if @err is non-NULL, then *@err must + * be NULL. A new #GError is created and assigned to *@err. + **/ +void +g_set_error (GError **err, + GQuark domain, + gint code, + const gchar *format, + ...) +{ + GError *new; + + va_list args; + + if (err == NULL) + return; + + va_start (args, format); + new = g_error_new_valist (domain, code, format, args); + va_end (args); + + if (*err == NULL) + *err = new; + else + g_warning (ERROR_OVERWRITTEN_WARNING, new->message); +} + +/** + * g_propagate_error: + * @dest: error return location + * @src: error to move into the return location + * + * If @dest is NULL, free @src; otherwise, + * moves @src into *@dest. *@dest must be NULL. + **/ +void +g_propagate_error (GError **dest, + GError *src) +{ + g_return_if_fail (src != NULL); + + if (dest == NULL) + { + if (src) + g_error_free (src); + return; + } + else + { + if (*dest != NULL) + g_warning (ERROR_OVERWRITTEN_WARNING, src->message); + else + *dest = src; + } +} + +/** + * g_clear_error: + * @err: a #GError return location + * + * If @err is NULL, does nothing. If @err is non-NULL, + * calls g_error_free() on *@err and sets *@err to NULL. + **/ +void +g_clear_error (GError **err) +{ + if (err && *err) + { + g_error_free (*err); + *err = NULL; + } +} diff --git a/graf2d/win32gdk/gdk/src/glib/gerror.h b/graf2d/win32gdk/gdk/src/glib/gerror.h index a7eb8fdab7d4b..ea0d25aaf5fd2 100644 --- a/graf2d/win32gdk/gdk/src/glib/gerror.h +++ b/graf2d/win32gdk/gdk/src/glib/gerror.h @@ -21,7 +21,7 @@ #ifndef __G_ERROR_H__ #define __G_ERROR_H__ -#include <gquark.h> +#include <glib/gquark.h> G_BEGIN_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gfileutils.c b/graf2d/win32gdk/gdk/src/glib/gfileutils.c new file mode 100644 index 0000000000000..3ab354c4ca330 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gfileutils.c @@ -0,0 +1,820 @@ +/* gfileutils.c - File utility functions + * + * Copyright 2000 Red Hat, Inc. + * + * GLib is free software; you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2 of the + * License, or (at your option) any later version. + * + * GLib is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with GLib; see the file COPYING.LIB. If not, + * write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "config.h" + +#include "glib.h" + +#include <sys/stat.h> +#ifdef HAVE_UNISTD_H +#include <unistd.h> +#endif +#include <stdio.h> +#include <stdlib.h> +#include <stdarg.h> +#include <string.h> +#include <errno.h> +#include <sys/types.h> +#include <sys/stat.h> +#include <fcntl.h> +#include <stdlib.h> + +#ifdef G_OS_WIN32 +#include <io.h> +#ifndef F_OK +#define F_OK 0 +#define X_OK 1 +#define W_OK 2 +#define R_OK 4 +#endif /* !F_OK */ + +#ifndef S_ISREG +#define S_ISREG(mode) ((mode)&_S_IFREG) +#endif + +#ifndef S_ISDIR +#define S_ISDIR(mode) ((mode)&_S_IFDIR) +#endif + +#endif /* G_OS_WIN32 */ + +#ifndef S_ISLNK +#define S_ISLNK(x) 0 +#endif + +#ifndef O_BINARY +#define O_BINARY 0 +#endif + +#include "glibintl.h" + +/** + * g_file_test: + * @filename: a filename to test + * @test: bitfield of #GFileTest flags + * + * Returns TRUE if any of the tests in the bitfield @test are + * TRUE. For example, (G_FILE_TEST_EXISTS | G_FILE_TEST_IS_DIR) + * will return TRUE if the file exists; the check whether it's + * a directory doesn't matter since the existence test is TRUE. + * With the current set of available tests, there's no point + * passing in more than one test at a time. + * + * Return value: whether a test was TRUE + **/ +gboolean +g_file_test (const gchar *filename, + GFileTest test) +{ + if (test & G_FILE_TEST_EXISTS) + return (access (filename, F_OK) == 0); + else if (test & G_FILE_TEST_IS_EXECUTABLE) + return (access (filename, X_OK) == 0); + else + { + struct stat s; + + if (stat (filename, &s) < 0) + return FALSE; + + if ((test & G_FILE_TEST_IS_REGULAR) && + S_ISREG (s.st_mode)) + return TRUE; + else if ((test & G_FILE_TEST_IS_DIR) && + S_ISDIR (s.st_mode)) + return TRUE; + else if ((test & G_FILE_TEST_IS_SYMLINK) && + S_ISLNK (s.st_mode)) + return TRUE; + else + return FALSE; + } +} + +GQuark +g_file_error_quark (void) +{ + static GQuark q = 0; + if (q == 0) + q = g_quark_from_static_string ("g-file-error-quark"); + + return q; +} + +/** + * g_file_error_from_errno: + * @err_no: an "errno" value + * + * Gets a #GFileError constant based on the passed-in errno. + * For example, if you pass in EEXIST this function returns + * #G_FILE_ERROR_EXIST. Unlike errno values, you can portably + * assume that all #GFileError values will exist. + * + * Normally a #GFileError value goes into a #GError returned + * from a function that manipulates files. So you would use + * g_file_error_from_errno() when constructing a #GError. + * + * Return value: #GFileError corresponding to the given errno + **/ +GFileError +g_file_error_from_errno (gint err_no) +{ + switch (err_no) + { +#ifdef EEXIST + case EEXIST: + return G_FILE_ERROR_EXIST; + break; +#endif + +#ifdef EISDIR + case EISDIR: + return G_FILE_ERROR_ISDIR; + break; +#endif + +#ifdef EACCES + case EACCES: + return G_FILE_ERROR_ACCES; + break; +#endif + +#ifdef ENAMETOOLONG + case ENAMETOOLONG: + return G_FILE_ERROR_NAMETOOLONG; + break; +#endif + +#ifdef ENOENT + case ENOENT: + return G_FILE_ERROR_NOENT; + break; +#endif + +#ifdef ENOTDIR + case ENOTDIR: + return G_FILE_ERROR_NOTDIR; + break; +#endif + +#ifdef ENXIO + case ENXIO: + return G_FILE_ERROR_NXIO; + break; +#endif + +#ifdef ENODEV + case ENODEV: + return G_FILE_ERROR_NODEV; + break; +#endif + +#ifdef EROFS + case EROFS: + return G_FILE_ERROR_ROFS; + break; +#endif + +#ifdef ETXTBSY + case ETXTBSY: + return G_FILE_ERROR_TXTBSY; + break; +#endif + +#ifdef EFAULT + case EFAULT: + return G_FILE_ERROR_FAULT; + break; +#endif + +#ifdef ELOOP + case ELOOP: + return G_FILE_ERROR_LOOP; + break; +#endif + +#ifdef ENOSPC + case ENOSPC: + return G_FILE_ERROR_NOSPC; + break; +#endif + +#ifdef ENOMEM + case ENOMEM: + return G_FILE_ERROR_NOMEM; + break; +#endif + +#ifdef EMFILE + case EMFILE: + return G_FILE_ERROR_MFILE; + break; +#endif + +#ifdef ENFILE + case ENFILE: + return G_FILE_ERROR_NFILE; + break; +#endif + +#ifdef EBADF + case EBADF: + return G_FILE_ERROR_BADF; + break; +#endif + +#ifdef EINVAL + case EINVAL: + return G_FILE_ERROR_INVAL; + break; +#endif + +#ifdef EPIPE + case EPIPE: + return G_FILE_ERROR_PIPE; + break; +#endif + +#ifdef EAGAIN + case EAGAIN: + return G_FILE_ERROR_AGAIN; + break; +#endif + +#ifdef EINTR + case EINTR: + return G_FILE_ERROR_INTR; + break; +#endif + +#ifdef EIO + case EIO: + return G_FILE_ERROR_IO; + break; +#endif + +#ifdef EPERM + case EPERM: + return G_FILE_ERROR_PERM; + break; +#endif + + default: + return G_FILE_ERROR_FAILED; + break; + } +} + +static gboolean +get_contents_stdio (const gchar *filename, + FILE *f, + gchar **contents, + gsize *length, + GError **error) +{ + gchar buf[2048]; + size_t bytes; + GString *str; + + g_assert (f != NULL); + + str = g_string_new (""); + + while (!feof (f)) + { + bytes = fread (buf, 1, 2048, f); + + if (ferror (f)) + { + g_set_error (error, + G_FILE_ERROR, + g_file_error_from_errno (errno), + _("Error reading file '%s': %s"), + filename, strerror (errno)); + + g_string_free (str, TRUE); + fclose (f); + + return FALSE; + } + + g_string_append_len (str, buf, bytes); + } + + fclose (f); + + if (length) + *length = str->len; + + *contents = g_string_free (str, FALSE); + + return TRUE; +} + +#ifndef G_OS_WIN32 + +static gboolean +get_contents_regfile (const gchar *filename, + struct stat *stat_buf, + gint fd, + gchar **contents, + gsize *length, + GError **error) +{ + gchar *buf; + size_t bytes_read; + size_t size; + + size = stat_buf->st_size; + + buf = g_new (gchar, size + 1); + + bytes_read = 0; + while (bytes_read < size) + { + gssize rc; + + rc = read (fd, buf + bytes_read, size - bytes_read); + + if (rc < 0) + { + if (errno != EINTR) + { + close (fd); + + g_free (buf); + + g_set_error (error, + G_FILE_ERROR, + g_file_error_from_errno (errno), + _("Failed to read from file '%s': %s"), + filename, strerror (errno)); + + return FALSE; + } + } + else if (rc == 0) + break; + else + bytes_read += rc; + } + + buf[bytes_read] = '\0'; + + if (length) + *length = bytes_read; + + *contents = buf; + + return TRUE; +} + +static gboolean +get_contents_posix (const gchar *filename, + gchar **contents, + gsize *length, + GError **error) +{ + struct stat stat_buf; + gint fd; + + /* O_BINARY useful on Cygwin */ + fd = open (filename, O_RDONLY|O_BINARY); + + if (fd < 0) + { + g_set_error (error, + G_FILE_ERROR, + g_file_error_from_errno (errno), + _("Failed to open file '%s': %s"), + filename, strerror (errno)); + + return FALSE; + } + + /* I don't think this will ever fail, aside from ENOMEM, but. */ + if (fstat (fd, &stat_buf) < 0) + { + close (fd); + + g_set_error (error, + G_FILE_ERROR, + g_file_error_from_errno (errno), + _("Failed to get attributes of file '%s': fstat() failed: %s"), + filename, strerror (errno)); + + return FALSE; + } + + if (stat_buf.st_size > 0 && S_ISREG (stat_buf.st_mode)) + { + return get_contents_regfile (filename, + &stat_buf, + fd, + contents, + length, + error); + } + else + { + FILE *f; + + f = fdopen (fd, "r"); + + if (f == NULL) + { + g_set_error (error, + G_FILE_ERROR, + g_file_error_from_errno (errno), + _("Failed to open file '%s': fdopen() failed: %s"), + filename, strerror (errno)); + + return FALSE; + } + + return get_contents_stdio (filename, f, contents, length, error); + } +} + +#else /* G_OS_WIN32 */ + +static gboolean +get_contents_win32 (const gchar *filename, + gchar **contents, + gsize *length, + GError **error) +{ + FILE *f; + + /* I guess you want binary mode; maybe you want text sometimes? */ + f = fopen (filename, "rb"); + + if (f == NULL) + { + g_set_error (error, + G_FILE_ERROR, + g_file_error_from_errno (errno), + _("Failed to open file '%s': %s"), + filename, strerror (errno)); + + return FALSE; + } + + return get_contents_stdio (filename, f, contents, length, error); +} + +#endif + +/** + * g_file_get_contents: + * @filename: a file to read contents from + * @contents: location to store an allocated string + * @length: location to store length in bytes of the contents + * @error: return location for a #GError + * + * Reads an entire file into allocated memory, with good error + * checking. If @error is set, FALSE is returned, and @contents is set + * to NULL. If TRUE is returned, @error will not be set, and @contents + * will be set to the file contents. The string stored in @contents + * will be nul-terminated, so for text files you can pass NULL for the + * @length argument. The error domain is #G_FILE_ERROR. Possible + * error codes are those in the #GFileError enumeration. + * + * FIXME currently crashes if the file is too big to fit in memory; + * should probably use g_try_malloc() when we have that function. + * + * Return value: TRUE on success, FALSE if error is set + **/ +gboolean +g_file_get_contents (const gchar *filename, + gchar **contents, + gsize *length, + GError **error) +{ + g_return_val_if_fail (filename != NULL, FALSE); + g_return_val_if_fail (contents != NULL, FALSE); + + *contents = NULL; + if (length) + *length = 0; + +#ifdef G_OS_WIN32 + return get_contents_win32 (filename, contents, length, error); +#else + return get_contents_posix (filename, contents, length, error); +#endif +} + +/* + * mkstemp() implementation is from the GNU C library. + * Copyright (C) 1991,92,93,94,95,96,97,98,99 Free Software Foundation, Inc. + */ +/** + * g_mkstemp: + * @tmpl: template filename + * + * Open a temporary file. See "man mkstemp" on most UNIX-like systems. + * This is a portability wrapper, which simply calls mkstemp() on systems + * that have it, and implements it in GLib otherwise. + * + * The parameter is a string that should match the rules for mktemp, i.e. + * end in "XXXXXX". The X string will be modified to form the name + * of a file that didn't exist. + * + * Return value: A file handle (as from open()) to the file + * opened for reading and writing. The file is opened in binary mode + * on platforms where there is a difference. The file handle should be + * closed with close(). In case of errors, -1 is returned. + */ +int +g_mkstemp (char *tmpl) +{ +#ifdef HAVE_MKSTEMP + return mkstemp (tmpl); +#else + int len; + char *XXXXXX; + int count, fd; + static const char letters[] = + "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"; + static const int NLETTERS = sizeof (letters) - 1; + glong value; + GTimeVal tv; + static int counter = 0; + + len = strlen (tmpl); + if (len < 6 || strcmp (&tmpl[len - 6], "XXXXXX")) + return -1; + + /* This is where the Xs start. */ + XXXXXX = &tmpl[len - 6]; + + /* Get some more or less random data. */ + g_get_current_time (&tv); + value = (tv.tv_usec ^ tv.tv_sec) + counter++; + + for (count = 0; count < 100; value += 7777, ++count) + { + glong v = value; + + /* Fill in the random bits. */ + XXXXXX[0] = letters[v % NLETTERS]; + v /= NLETTERS; + XXXXXX[1] = letters[v % NLETTERS]; + v /= NLETTERS; + XXXXXX[2] = letters[v % NLETTERS]; + v /= NLETTERS; + XXXXXX[3] = letters[v % NLETTERS]; + v /= NLETTERS; + XXXXXX[4] = letters[v % NLETTERS]; + v /= NLETTERS; + XXXXXX[5] = letters[v % NLETTERS]; + + fd = open (tmpl, O_RDWR | O_CREAT | O_EXCL | O_BINARY, 0600); + + if (fd >= 0) + return fd; + else if (errno != EEXIST) + /* Any other error will apply also to other names we might + * try, and there are 2^32 or so of them, so give up now. + */ + return -1; + } + + /* We got out of the loop because we ran out of combinations to try. */ + return -1; +#endif +} + +/** + * g_file_open_tmp: + * @tmpl: Template for file name, as in g_mkstemp, basename only + * @name_used: location to store actual name used + * @error: return location for a #GError + * + * Opens a file for writing in the preferred directory for temporary + * files (as returned by g_get_tmp_dir()). + * + * @tmpl should be a string ending with six 'X' characters, as the + * parameter to g_mkstemp() (or mkstemp()). However, unlike these + * functions, the template should only be a basename, no directory + * components are allowed. If template is NULL, a default template is + * used. + * + * Note that in contrast to g_mkstemp() (and mkstemp()) @tmpl is not + * modified, and might thus be a read-only literal string. + * + * The actual name used is returned in @name_used if non-NULL. This + * string should be freed with g_free when not needed any longer. + * + * Return value: A file handle (as from open()) to the file + * opened for reading and writing. The file is opened in binary mode + * on platforms where there is a difference. The file handle should be + * closed with close(). In case of errors, -1 is returned and + * @error will be set. + **/ +int +g_file_open_tmp (const char *tmpl, + char **name_used, + GError **error) +{ + int retval; + const char *tmpdir; + char *sep; + char *fulltemplate; + + if (tmpl == NULL) + tmpl = ".XXXXXX"; + + if (strchr (tmpl, G_DIR_SEPARATOR) +#ifdef G_OS_WIN32 + || strchr (tmpl, '/') +#endif + ) + { + g_set_error (error, + G_FILE_ERROR, + G_FILE_ERROR_FAILED, + _("Template '%s' invalid, should not contain a '%s'"), + tmpl, G_DIR_SEPARATOR_S); + + return -1; + } + + if (strlen (tmpl) < 6 || + strcmp (tmpl + strlen (tmpl) - 6, "XXXXXX") != 0) + { + g_set_error (error, + G_FILE_ERROR, + G_FILE_ERROR_FAILED, + _("Template '%s' doesn't end with XXXXXX"), + tmpl); + return -1; + } + + tmpdir = g_get_tmp_dir (); + + if (tmpdir [strlen (tmpdir) - 1] == G_DIR_SEPARATOR) + sep = ""; + else + sep = G_DIR_SEPARATOR_S; + + fulltemplate = g_strconcat (tmpdir, sep, tmpl, NULL); + + retval = g_mkstemp (fulltemplate); + + if (retval == -1) + { + g_set_error (error, + G_FILE_ERROR, + g_file_error_from_errno (errno), + _("Failed to create file '%s': %s"), + fulltemplate, strerror (errno)); + g_free (fulltemplate); + return -1; + } + + if (name_used) + *name_used = fulltemplate; + else + g_free (fulltemplate); + + return retval; +} + +static gchar * +g_build_pathv (const gchar *separator, + const gchar *first_element, + va_list args) +{ + GString *result; + gint separator_len = strlen (separator); + gboolean is_first = TRUE; + const gchar *next_element; + + result = g_string_new (NULL); + + next_element = first_element; + + while (TRUE) + { + const gchar *element; + const gchar *start; + const gchar *end; + + if (next_element) + { + element = next_element; + next_element = va_arg (args, gchar *); + } + else + break; + + start = element; + + if (is_first) + is_first = FALSE; + else if (separator_len) + { + while (start && + strncmp (start, separator, separator_len) == 0) + start += separator_len; + } + + end = start + strlen (start); + + if (next_element && separator_len) + { + while (end > start + separator_len && + strncmp (end - separator_len, separator, separator_len) == 0) + end -= separator_len; + } + + if (end > start) + { + if (result->len > 0) + g_string_append (result, separator); + + g_string_append_len (result, start, end - start); + } + } + + return g_string_free (result, FALSE); +} + +/** + * g_build_path: + * @separator: a string used to separator the elements of the path. + * @first_element: the first element in the path + * @Varargs: remaining elements in path + * + * Create a path from a series of elements using @separator as the + * separator between elements. At the boundary between two elements, + * any trailing occurrences of separator in the first element, or + * leading occurrences of separator in the second element are removed + * and exactly one copy of the separator is inserted. + * + * Return value: a newly allocated string that must be freed with g_free(). + **/ +gchar * +g_build_path (const gchar *separator, + const gchar *first_element, + ...) +{ + gchar *str; + va_list args; + + g_return_val_if_fail (separator != NULL, NULL); + + va_start (args, first_element); + str = g_build_pathv (separator, first_element, args); + va_end (args); + + return str; +} + +/** + * g_build_filename: + * @first_element: the first element in the path + * @Varargs: remaining elements in path + * + * Create a filename from a series of elements using the correct + * separator for filenames. This function behaves identically + * to g_build_path (G_DIR_SEPARATOR_S, first_element, ....) + * + * No attempt is made to force the resulting filename to be an absolute + * path. If the first element is a relative path, the result will + * be a relative path. + * + * Return value: a newly allocated string that must be freed with g_free(). + **/ +gchar * +g_build_filename (const gchar *first_element, + ...) +{ + gchar *str; + va_list args; + + va_start (args, first_element); + str = g_build_pathv (G_DIR_SEPARATOR_S, first_element, args); + va_end (args); + + return str; +} diff --git a/graf2d/win32gdk/gdk/src/glib/gfileutils.h b/graf2d/win32gdk/gdk/src/glib/gfileutils.h index 9929ee152bf28..f966e01451ae8 100644 --- a/graf2d/win32gdk/gdk/src/glib/gfileutils.h +++ b/graf2d/win32gdk/gdk/src/glib/gfileutils.h @@ -21,7 +21,7 @@ #ifndef __G_FILEUTILS_H__ #define __G_FILEUTILS_H__ -#include <gerror.h> +#include <glib/gerror.h> G_BEGIN_DECLS @@ -76,7 +76,7 @@ gboolean g_file_test (const gchar *filename, GFileTest test); gboolean g_file_get_contents (const gchar *filename, gchar **contents, - guint *length, + gsize *length, GError **error); @@ -88,6 +88,12 @@ int g_file_open_tmp (const char *tmpl, char **name_used, GError **error); +gchar *g_build_path (const gchar *separator, + const gchar *first_element, + ...); +gchar *g_build_filename (const gchar *first_element, + ...); + G_END_DECLS #endif /* __G_FILEUTILS_H__ */ diff --git a/graf2d/win32gdk/gdk/src/glib/ghash.c b/graf2d/win32gdk/gdk/src/glib/ghash.c new file mode 100644 index 0000000000000..40be7d391dc4d --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/ghash.c @@ -0,0 +1,696 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include "glib.h" + + +#define HASH_TABLE_MIN_SIZE 11 +#define HASH_TABLE_MAX_SIZE 13845163 + + +typedef struct _GHashNode GHashNode; + +struct _GHashNode +{ + gpointer key; + gpointer value; + GHashNode *next; +}; + +struct _GHashTable +{ + gint size; + gint nnodes; + GHashNode **nodes; + GHashFunc hash_func; + GEqualFunc key_equal_func; + GDestroyNotify key_destroy_func; + GDestroyNotify value_destroy_func; +}; + +#define G_HASH_TABLE_RESIZE(hash_table) \ + G_STMT_START { \ + if ((hash_table->size >= 3 * hash_table->nnodes && \ + hash_table->size > HASH_TABLE_MIN_SIZE) || \ + (3 * hash_table->size <= hash_table->nnodes && \ + hash_table->size < HASH_TABLE_MAX_SIZE)) \ + g_hash_table_resize (hash_table); \ + } G_STMT_END + +static void g_hash_table_resize (GHashTable *hash_table); +static GHashNode** g_hash_table_lookup_node (GHashTable *hash_table, + gconstpointer key); +static GHashNode* g_hash_node_new (gpointer key, + gpointer value); +static void g_hash_node_destroy (GHashNode *hash_node, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func); +static void g_hash_nodes_destroy (GHashNode *hash_node, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func); +static guint g_hash_table_foreach_remove_or_steal (GHashTable *hash_table, + GHRFunc func, + gpointer user_data, + gboolean notify); + + +G_LOCK_DEFINE_STATIC (g_hash_global); + +static GMemChunk *node_mem_chunk = NULL; +static GHashNode *node_free_list = NULL; + +/** + * g_hash_table_new: + * @hash_func: a function to create a hash value from a key. + * Hash values are used to determine where keys are stored within the + * #GHashTable data structure. The g_direct_hash(), g_int_hash() and + * g_str_hash() functions are provided for some common types of keys. + * If hash_func is NULL, g_direct_hash() is used. + * @key_equal_func: a function to check two keys for equality. This is + * used when looking up keys in the #GHashTable. The g_direct_equal(), + * g_int_equal() and g_str_equal() functions are provided for the most + * common types of keys. If @key_equal_func is NULL, keys are compared + * directly in a similar fashion to g_direct_equal(), but without the + * overhead of a function call. + * + * Creates a new #GHashTable. + * + * Return value: a new #GHashTable. + **/ +GHashTable* +g_hash_table_new (GHashFunc hash_func, + GEqualFunc key_equal_func) +{ + return g_hash_table_new_full (hash_func, key_equal_func, NULL, NULL); +} + + +/** + * g_hash_table_new_full: + * @hash_func: a function to create a hash value from a key. + * @key_equal_func: a function to check two keys for equality. + * @key_destroy_func: a function to free the memory allocated for the key + * used when removing the entry from the #GHashTable or #NULL if you + * don't want to supply such a function. + * @value_destroy_func: a function to free the memory allocated for the + * value used when removing the entry from the #GHashTable or #NULL if + * you don't want to supply such a function. + * + * Creates a new #GHashTable like g_hash_table_new() and allows to specify + * functions to free the memory allocated for the key and value that get + * called when removing the entry from the #GHashTable. + * + * Return value: a new #GHashTable. + **/ +GHashTable* +g_hash_table_new_full (GHashFunc hash_func, + GEqualFunc key_equal_func, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func) +{ + GHashTable *hash_table; + guint i; + + hash_table = g_new (GHashTable, 1); + hash_table->size = HASH_TABLE_MIN_SIZE; + hash_table->nnodes = 0; + hash_table->hash_func = hash_func ? hash_func : g_direct_hash; + hash_table->key_equal_func = key_equal_func; + hash_table->key_destroy_func = key_destroy_func; + hash_table->value_destroy_func = value_destroy_func; + hash_table->nodes = g_new (GHashNode*, hash_table->size); + + for (i = 0; i < hash_table->size; i++) + hash_table->nodes[i] = NULL; + + return hash_table; +} + +/** + * g_hash_table_destroy: + * @hash_table: a #GHashTable. + * + * Destroys the #GHashTable. If keys and/or values are dynamically + * allocated, you should either free them first or create the #GHashTable + * using g_hash_table_new_full(). In the latter case the destroy functions + * you supplied will be called on all keys and values before destroying + * the #GHashTable. + **/ +void +g_hash_table_destroy (GHashTable *hash_table) +{ + guint i; + + g_return_if_fail (hash_table != NULL); + + for (i = 0; i < hash_table->size; i++) + g_hash_nodes_destroy (hash_table->nodes[i], + hash_table->key_destroy_func, + hash_table->value_destroy_func); + + g_free (hash_table->nodes); + g_free (hash_table); +} + +static inline GHashNode** +g_hash_table_lookup_node (GHashTable *hash_table, + gconstpointer key) +{ + GHashNode **node; + + node = &hash_table->nodes + [(* hash_table->hash_func) (key) % hash_table->size]; + + /* Hash table lookup needs to be fast. + * We therefore remove the extra conditional of testing + * whether to call the key_equal_func or not from + * the inner loop. + */ + if (hash_table->key_equal_func) + while (*node && !(*hash_table->key_equal_func) ((*node)->key, key)) + node = &(*node)->next; + else + while (*node && (*node)->key != key) + node = &(*node)->next; + + return node; +} + +/** + * g_hash_table_lookup: + * @hash_table: a #GHashTable. + * @key: the key to look up. + * + * Looks up a key in a #GHashTable. + * + * Return value: the associated value, or NULL if the key is not found. + **/ +gpointer +g_hash_table_lookup (GHashTable *hash_table, + gconstpointer key) +{ + GHashNode *node; + + g_return_val_if_fail (hash_table != NULL, NULL); + + node = *g_hash_table_lookup_node (hash_table, key); + + return node ? node->value : NULL; +} + +/** + * g_hash_table_lookup_extended: + * @hash_table: a #GHashTable. + * @lookup_key: the key to look up. + * @orig_key: returns the original key. + * @value: returns the value associated with the key. + * + * Looks up a key in the #GHashTable, returning the original key and the + * associated value and a gboolean which is TRUE if the key was found. This + * is useful if you need to free the memory allocated for the original key, + * for example before calling g_hash_table_remove(). + * + * Return value: #TRUE if the key was found in the #GHashTable. + **/ +gboolean +g_hash_table_lookup_extended (GHashTable *hash_table, + gconstpointer lookup_key, + gpointer *orig_key, + gpointer *value) +{ + GHashNode *node; + + g_return_val_if_fail (hash_table != NULL, FALSE); + + node = *g_hash_table_lookup_node (hash_table, lookup_key); + + if (node) + { + if (orig_key) + *orig_key = node->key; + if (value) + *value = node->value; + return TRUE; + } + else + return FALSE; +} + +/** + * g_hash_table_insert: + * @hash_table: a #GHashTable. + * @key: a key to insert. + * @value: the value to associate with the key. + * + * Inserts a new key and value into a #GHashTable. + * + * If the key already exists in the #GHashTable its current value is replaced + * with the new value. If you supplied a value_destroy_func when creating the + * #GHashTable, the old value is freed using that function. If you supplied + * a key_destroy_func when creating the #GHashTable, the passed key is freed + * using that function. + **/ +void +g_hash_table_insert (GHashTable *hash_table, + gpointer key, + gpointer value) +{ + GHashNode **node; + + g_return_if_fail (hash_table != NULL); + + node = g_hash_table_lookup_node (hash_table, key); + + if (*node) + { + /* do not reset node->key in this place, keeping + * the old key is the intended behaviour. + * g_hash_table_replace() can be used instead. + */ + + /* free the passed key */ + if (hash_table->key_destroy_func) + hash_table->key_destroy_func (key); + + if (hash_table->value_destroy_func) + hash_table->value_destroy_func ((*node)->value); + + (*node)->value = value; + } + else + { + *node = g_hash_node_new (key, value); + hash_table->nnodes++; + G_HASH_TABLE_RESIZE (hash_table); + } +} + +/** + * g_hash_table_replace: + * @hash_table: a #GHashTable. + * @key: a key to insert. + * @value: the value to associate with the key. + * + * Inserts a new key and value into a #GHashTable similar to + * g_hash_table_insert(). The difference is that if the key already exists + * in the #GHashTable, it gets replaced by the new key. If you supplied a + * value_destroy_func when creating the #GHashTable, the old value is freed + * using that function. If you supplied a key_destroy_func when creating the + * #GHashTable, the old key is freed using that function. + **/ +void +g_hash_table_replace (GHashTable *hash_table, + gpointer key, + gpointer value) +{ + GHashNode **node; + + g_return_if_fail (hash_table != NULL); + + node = g_hash_table_lookup_node (hash_table, key); + + if (*node) + { + if (hash_table->key_destroy_func) + hash_table->key_destroy_func ((*node)->key); + + if (hash_table->value_destroy_func) + hash_table->value_destroy_func ((*node)->value); + + (*node)->key = key; + (*node)->value = value; + } + else + { + *node = g_hash_node_new (key, value); + hash_table->nnodes++; + G_HASH_TABLE_RESIZE (hash_table); + } +} + +/** + * g_hash_table_remove: + * @hash_table: a #GHashTable. + * @key: the key to remove. + * + * Removes a key and its associated value from a #GHashTable. + * + * If the #GHashTable was created using g_hash_table_new_full(), the + * key and value are freed using the supplied destroy_functions, otherwise + * you have to make sure that any dynamically allocated values are freed + * yourself. + * + * Return value: #TRUE if the key was found and removed from the #GHashTable. + **/ +gboolean +g_hash_table_remove (GHashTable *hash_table, + gconstpointer key) +{ + GHashNode **node, *dest; + + g_return_val_if_fail (hash_table != NULL, FALSE); + + node = g_hash_table_lookup_node (hash_table, key); + if (*node) + { + dest = *node; + (*node) = dest->next; + g_hash_node_destroy (dest, + hash_table->key_destroy_func, + hash_table->value_destroy_func); + hash_table->nnodes--; + + G_HASH_TABLE_RESIZE (hash_table); + + return TRUE; + } + + return FALSE; +} + +/** + * g_hash_table_steal: + * @hash_table: a #GHashTable. + * @key: the key to remove. + * + * Removes a key and its associated value from a #GHashTable without + * calling the key and value destroy functions. + * + * Return value: #TRUE if the key was found and removed from the #GHashTable. + **/ +gboolean +g_hash_table_steal (GHashTable *hash_table, + gconstpointer key) +{ + GHashNode **node, *dest; + + g_return_val_if_fail (hash_table != NULL, FALSE); + + node = g_hash_table_lookup_node (hash_table, key); + if (*node) + { + dest = *node; + (*node) = dest->next; + g_hash_node_destroy (dest, NULL, NULL); + hash_table->nnodes--; + + G_HASH_TABLE_RESIZE (hash_table); + + return TRUE; + } + + return FALSE; +} + +/** + * g_hash_table_foreach_remove: + * @hash_table: a #GHashTable. + * @func: the function to call for each key/value pair. + * @user_data: user data to pass to the function. + * + * Calls the given function for each key/value pair in the #GHashTable. + * If the function returns TRUE, then the key/value pair is removed from the + * #GHashTable. If you supplied key or value destroy functions when creating + * the #GHashTable, they are used to free the memory allocated for the removed + * keys and values. + * + * Return value: the number of key/value pairs removed. + **/ +guint +g_hash_table_foreach_remove (GHashTable *hash_table, + GHRFunc func, + gpointer user_data) +{ + g_return_val_if_fail (hash_table != NULL, 0); + g_return_val_if_fail (func != NULL, 0); + + return g_hash_table_foreach_remove_or_steal (hash_table, func, user_data, TRUE); +} + +/** + * g_hash_table_foreach_steal: + * @hash_table: a #GHashTable. + * @func: the function to call for each key/value pair. + * @user_data: user data to pass to the function. + * + * Calls the given function for each key/value pair in the #GHashTable. + * If the function returns TRUE, then the key/value pair is removed from the + * #GHashTable, but no key or value destroy functions are called. + * + * Return value: the number of key/value pairs removed. + **/ +guint +g_hash_table_foreach_steal (GHashTable *hash_table, + GHRFunc func, + gpointer user_data) +{ + g_return_val_if_fail (hash_table != NULL, 0); + g_return_val_if_fail (func != NULL, 0); + + return g_hash_table_foreach_remove_or_steal (hash_table, func, user_data, FALSE); +} + +static guint +g_hash_table_foreach_remove_or_steal (GHashTable *hash_table, + GHRFunc func, + gpointer user_data, + gboolean notify) +{ + GHashNode *node, *prev; + guint i; + guint deleted = 0; + + for (i = 0; i < hash_table->size; i++) + { + restart: + + prev = NULL; + + for (node = hash_table->nodes[i]; node; prev = node, node = node->next) + { + if ((* func) (node->key, node->value, user_data)) + { + deleted += 1; + + hash_table->nnodes -= 1; + + if (prev) + { + prev->next = node->next; + g_hash_node_destroy (node, + notify ? hash_table->key_destroy_func : NULL, + notify ? hash_table->value_destroy_func : NULL); + node = prev; + } + else + { + hash_table->nodes[i] = node->next; + g_hash_node_destroy (node, + notify ? hash_table->key_destroy_func : NULL, + notify ? hash_table->value_destroy_func : NULL); + goto restart; + } + } + } + } + + G_HASH_TABLE_RESIZE (hash_table); + + return deleted; +} + +/** + * g_hash_table_foreach: + * @hash_table: a #GHashTable. + * @func: the function to call for each key/value pair. + * @user_data: user data to pass to the function. + * + * Calls the given function for each of the key/value pairs in the #GHashTable. + * The function is passed the key and value of each pair, and the given + * @user_data parameter. + **/ +void +g_hash_table_foreach (GHashTable *hash_table, + GHFunc func, + gpointer user_data) +{ + GHashNode *node; + gint i; + + g_return_if_fail (hash_table != NULL); + g_return_if_fail (func != NULL); + + for (i = 0; i < hash_table->size; i++) + for (node = hash_table->nodes[i]; node; node = node->next) + (* func) (node->key, node->value, user_data); +} + +/** + * g_hash_table_size: + * @hash_table: a #GHashTable. + * + * Returns the number of elements contained in the #GHashTable. + * + * Return value: the number of key/value pairs in the #GHashTable. + **/ +guint +g_hash_table_size (GHashTable *hash_table) +{ + g_return_val_if_fail (hash_table != NULL, 0); + + return hash_table->nnodes; +} + +static void +g_hash_table_resize (GHashTable *hash_table) +{ + GHashNode **new_nodes; + GHashNode *node; + GHashNode *next; + guint hash_val; + gint new_size; + gint i; + + new_size = CLAMP(g_spaced_primes_closest (hash_table->nnodes), + HASH_TABLE_MIN_SIZE, + HASH_TABLE_MAX_SIZE); + new_nodes = g_new0 (GHashNode*, new_size); + + for (i = 0; i < hash_table->size; i++) + for (node = hash_table->nodes[i]; node; node = next) + { + next = node->next; + + hash_val = (* hash_table->hash_func) (node->key) % new_size; + + node->next = new_nodes[hash_val]; + new_nodes[hash_val] = node; + } + + g_free (hash_table->nodes); + hash_table->nodes = new_nodes; + hash_table->size = new_size; +} + +static GHashNode* +g_hash_node_new (gpointer key, + gpointer value) +{ + GHashNode *hash_node; + + G_LOCK (g_hash_global); + if (node_free_list) + { + hash_node = node_free_list; + node_free_list = node_free_list->next; + } + else + { + if (!node_mem_chunk) + node_mem_chunk = g_mem_chunk_new ("hash node mem chunk", + sizeof (GHashNode), + 1024, G_ALLOC_ONLY); + + hash_node = g_chunk_new (GHashNode, node_mem_chunk); + } + G_UNLOCK (g_hash_global); + + hash_node->key = key; + hash_node->value = value; + hash_node->next = NULL; + + return hash_node; +} + +static void +g_hash_node_destroy (GHashNode *hash_node, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func) +{ + if (key_destroy_func) + key_destroy_func (hash_node->key); + if (value_destroy_func) + value_destroy_func (hash_node->value); + +#ifdef ENABLE_GC_FRIENDLY + hash_node->key = NULL; + hash_node->value = NULL; +#endif /* ENABLE_GC_FRIENDLY */ + + G_LOCK (g_hash_global); + hash_node->next = node_free_list; + node_free_list = hash_node; + G_UNLOCK (g_hash_global); +} + +static void +g_hash_nodes_destroy (GHashNode *hash_node, + GFreeFunc key_destroy_func, + GFreeFunc value_destroy_func) +{ + if (hash_node) + { + GHashNode *node = hash_node; + + while (node->next) + { + if (key_destroy_func) + key_destroy_func (node->key); + if (value_destroy_func) + value_destroy_func (node->value); + +#ifdef ENABLE_GC_FRIENDLY + node->key = NULL; + node->value = NULL; +#endif /* ENABLE_GC_FRIENDLY */ + + node = node->next; + } + + if (key_destroy_func) + key_destroy_func (node->key); + if (value_destroy_func) + value_destroy_func (node->value); + +#ifdef ENABLE_GC_FRIENDLY + node->key = NULL; + node->value = NULL; +#endif /* ENABLE_GC_FRIENDLY */ + + G_LOCK (g_hash_global); + node->next = node_free_list; + node_free_list = hash_node; + G_UNLOCK (g_hash_global); + } +} diff --git a/graf2d/win32gdk/gdk/src/glib/ghash.h b/graf2d/win32gdk/gdk/src/glib/ghash.h index 6a9a8e263ec48..acc2d176ea66a 100644 --- a/graf2d/win32gdk/gdk/src/glib/ghash.h +++ b/graf2d/win32gdk/gdk/src/glib/ghash.h @@ -27,54 +27,70 @@ #ifndef __G_HASH_H__ #define __G_HASH_H__ -#include <g_types.h> +#include <glib/gtypes.h> G_BEGIN_DECLS -typedef struct _GHashTable GHashTable; +typedef struct _GHashTable GHashTable; -typedef gboolean (*GHRFunc) (gpointer key, - gpointer value, - gpointer user_data); +typedef gboolean (*GHRFunc) (gpointer key, + gpointer value, + gpointer user_data); /* Hash tables */ -GHashTable* g_hash_table_new (GHashFunc hash_func, - GEqualFunc key_equal_func); -void g_hash_table_destroy (GHashTable *hash_table); -void g_hash_table_insert (GHashTable *hash_table, - gpointer key, - gpointer value); -gboolean g_hash_table_remove (GHashTable *hash_table, - gconstpointer key); -gpointer g_hash_table_lookup (GHashTable *hash_table, - gconstpointer key); -gboolean g_hash_table_lookup_extended(GHashTable *hash_table, - gconstpointer lookup_key, - gpointer *orig_key, - gpointer *value); -void g_hash_table_foreach (GHashTable *hash_table, - GHFunc func, - gpointer user_data); -guint g_hash_table_foreach_remove (GHashTable *hash_table, - GHRFunc func, - gpointer user_data); -guint g_hash_table_size (GHashTable *hash_table); +GHashTable* g_hash_table_new (GHashFunc hash_func, + GEqualFunc key_equal_func); +GHashTable* g_hash_table_new_full (GHashFunc hash_func, + GEqualFunc key_equal_func, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func); +void g_hash_table_destroy (GHashTable *hash_table); +void g_hash_table_insert (GHashTable *hash_table, + gpointer key, + gpointer value); +void g_hash_table_replace (GHashTable *hash_table, + gpointer key, + gpointer value); +gboolean g_hash_table_remove (GHashTable *hash_table, + gconstpointer key); +gboolean g_hash_table_steal (GHashTable *hash_table, + gconstpointer key); +gpointer g_hash_table_lookup (GHashTable *hash_table, + gconstpointer key); +gboolean g_hash_table_lookup_extended (GHashTable *hash_table, + gconstpointer lookup_key, + gpointer *orig_key, + gpointer *value); +void g_hash_table_foreach (GHashTable *hash_table, + GHFunc func, + gpointer user_data); +guint g_hash_table_foreach_remove (GHashTable *hash_table, + GHRFunc func, + gpointer user_data); +guint g_hash_table_foreach_steal (GHashTable *hash_table, + GHRFunc func, + gpointer user_data); +guint g_hash_table_size (GHashTable *hash_table); + +#ifndef G_DISABLE_DEPRECATED /* The following two functions are deprecated and will be removed in * the next major release. They do no good. */ -void g_hash_table_freeze (GHashTable *hash_table); -void g_hash_table_thaw (GHashTable *hash_table); +#define g_hash_table_freeze(hash_table) ((void)0) +#define g_hash_table_thaw(hash_table) ((void)0) + +#endif /* G_DISABLE_DEPRECATED */ /* Hash Functions */ -gboolean g_str_equal (gconstpointer v, - gconstpointer v2); -guint g_str_hash (gconstpointer v); +gboolean g_str_equal (gconstpointer v, + gconstpointer v2); +guint g_str_hash (gconstpointer v); -gboolean g_int_equal (gconstpointer v, - gconstpointer v2) G_GNUC_CONST; -guint g_int_hash (gconstpointer v) G_GNUC_CONST; +gboolean g_int_equal (gconstpointer v, + gconstpointer v2) G_GNUC_CONST; +guint g_int_hash (gconstpointer v) G_GNUC_CONST; /* This "hash" function will just return the key's adress as an * unsigned integer. Useful for hashing on plain adresses or @@ -82,9 +98,9 @@ guint g_int_hash (gconstpointer v) G_GNUC_CONST; * passing NULL into g_hash_table_new() as GHashFunc has the * same effect as passing g_direct_hash(). */ -guint g_direct_hash (gconstpointer v) G_GNUC_CONST; -gboolean g_direct_equal (gconstpointer v, - gconstpointer v2) G_GNUC_CONST; +guint g_direct_hash (gconstpointer v) G_GNUC_CONST; +gboolean g_direct_equal (gconstpointer v, + gconstpointer v2) G_GNUC_CONST; G_END_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/ghook.c b/graf2d/win32gdk/gdk/src/glib/ghook.c new file mode 100644 index 0000000000000..d04162fa16227 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/ghook.c @@ -0,0 +1,640 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * GHook: Callback maintenance functions + * Copyright (C) 1998 Tim Janik + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#include "glib.h" + + +/* --- defines --- */ +#define G_HOOKS_PREALLOC (16) + + +/* --- functions --- */ +static void +default_finalize_hook (GHookList *hook_list, + GHook *hook) +{ + GDestroyNotify destroy = hook->destroy; + + if (destroy) + { + hook->destroy = NULL; + destroy (hook->data); + } +} + +void +g_hook_list_init (GHookList *hook_list, + guint hook_size) +{ + g_return_if_fail (hook_list != NULL); + g_return_if_fail (hook_size >= sizeof (GHook)); + g_return_if_fail (hook_size < 65536); + + hook_list->seq_id = 1; + hook_list->hook_size = hook_size; + hook_list->is_setup = TRUE; + hook_list->hooks = NULL; + hook_list->hook_memchunk = g_mem_chunk_new ("GHook Memchunk", + hook_size, + hook_size * G_HOOKS_PREALLOC, + G_ALLOC_AND_FREE); + hook_list->finalize_hook = default_finalize_hook; +} + +void +g_hook_list_clear (GHookList *hook_list) +{ + g_return_if_fail (hook_list != NULL); + + if (hook_list->is_setup) + { + GHook *hook; + + hook_list->is_setup = FALSE; + + hook = hook_list->hooks; + if (!hook) + { + g_mem_chunk_destroy (hook_list->hook_memchunk); + hook_list->hook_memchunk = NULL; + } + else + do + { + GHook *tmp; + + g_hook_ref (hook_list, hook); + g_hook_destroy_link (hook_list, hook); + tmp = hook->next; + g_hook_unref (hook_list, hook); + hook = tmp; + } + while (hook); + if (hook_list->hook_memchunk) + g_warning (G_STRLOC ": failed to clear hooklist, unconsolidated references on hooks left"); + } +} + +GHook* +g_hook_alloc (GHookList *hook_list) +{ + GHook *hook; + + g_return_val_if_fail (hook_list != NULL, NULL); + g_return_val_if_fail (hook_list->is_setup, NULL); + + hook = g_chunk_new0 (GHook, hook_list->hook_memchunk); + hook->data = NULL; + hook->next = NULL; + hook->prev = NULL; + hook->flags = G_HOOK_FLAG_ACTIVE; + hook->ref_count = 0; + hook->hook_id = 0; + hook->func = NULL; + hook->destroy = NULL; + + return hook; +} + +void +g_hook_free (GHookList *hook_list, + GHook *hook) +{ + g_return_if_fail (hook_list != NULL); + g_return_if_fail (hook_list->is_setup); + g_return_if_fail (hook != NULL); + g_return_if_fail (G_HOOK_IS_UNLINKED (hook)); + g_return_if_fail (!G_HOOK_IN_CALL (hook)); + + hook_list->finalize_hook (hook_list, hook); + g_chunk_free (hook, hook_list->hook_memchunk); +} + +void +g_hook_destroy_link (GHookList *hook_list, + GHook *hook) +{ + g_return_if_fail (hook_list != NULL); + g_return_if_fail (hook != NULL); + + hook->flags &= ~G_HOOK_FLAG_ACTIVE; + if (hook->hook_id) + { + hook->hook_id = 0; + g_hook_unref (hook_list, hook); /* counterpart to g_hook_insert_before */ + } +} + +gboolean +g_hook_destroy (GHookList *hook_list, + gulong hook_id) +{ + GHook *hook; + + g_return_val_if_fail (hook_list != NULL, FALSE); + g_return_val_if_fail (hook_id > 0, FALSE); + + hook = g_hook_get (hook_list, hook_id); + if (hook) + { + g_hook_destroy_link (hook_list, hook); + return TRUE; + } + + return FALSE; +} + +void +g_hook_unref (GHookList *hook_list, + GHook *hook) +{ + g_return_if_fail (hook_list != NULL); + g_return_if_fail (hook_list->hook_memchunk != NULL); + g_return_if_fail (hook != NULL); + g_return_if_fail (hook->ref_count > 0); + + hook->ref_count--; + if (!hook->ref_count) + { + g_return_if_fail (hook->hook_id == 0); + g_return_if_fail (!G_HOOK_IN_CALL (hook)); + + if (hook->prev) + hook->prev->next = hook->next; + else + hook_list->hooks = hook->next; + if (hook->next) + { + hook->next->prev = hook->prev; + hook->next = NULL; + } + hook->prev = NULL; + + if (!hook_list->is_setup) + { + hook_list->is_setup = TRUE; + g_hook_free (hook_list, hook); + hook_list->is_setup = FALSE; + + if (!hook_list->hooks) + { + g_mem_chunk_destroy (hook_list->hook_memchunk); + hook_list->hook_memchunk = NULL; + } + } + else + g_hook_free (hook_list, hook); + } +} + +void +g_hook_ref (GHookList *hook_list, + GHook *hook) +{ + g_return_if_fail (hook_list != NULL); + g_return_if_fail (hook != NULL); + g_return_if_fail (hook->ref_count > 0); + + hook->ref_count++; +} + +void +g_hook_prepend (GHookList *hook_list, + GHook *hook) +{ + g_return_if_fail (hook_list != NULL); + + g_hook_insert_before (hook_list, hook_list->hooks, hook); +} + +void +g_hook_insert_before (GHookList *hook_list, + GHook *sibling, + GHook *hook) +{ + g_return_if_fail (hook_list != NULL); + g_return_if_fail (hook_list->is_setup); + g_return_if_fail (hook != NULL); + g_return_if_fail (G_HOOK_IS_UNLINKED (hook)); + g_return_if_fail (hook->ref_count == 0); + + hook->hook_id = hook_list->seq_id++; + hook->ref_count = 1; /* counterpart to g_hook_destroy_link */ + + if (sibling) + { + if (sibling->prev) + { + hook->prev = sibling->prev; + hook->prev->next = hook; + hook->next = sibling; + sibling->prev = hook; + } + else + { + hook_list->hooks = hook; + hook->next = sibling; + sibling->prev = hook; + } + } + else + { + if (hook_list->hooks) + { + sibling = hook_list->hooks; + while (sibling->next) + sibling = sibling->next; + hook->prev = sibling; + sibling->next = hook; + } + else + hook_list->hooks = hook; + } +} + +void +g_hook_list_invoke (GHookList *hook_list, + gboolean may_recurse) +{ + GHook *hook; + + g_return_if_fail (hook_list != NULL); + g_return_if_fail (hook_list->is_setup); + + hook = g_hook_first_valid (hook_list, may_recurse); + while (hook) + { + GHookFunc func; + gboolean was_in_call; + + func = (GHookFunc) hook->func; + + was_in_call = G_HOOK_IN_CALL (hook); + hook->flags |= G_HOOK_FLAG_IN_CALL; + func (hook->data); + if (!was_in_call) + hook->flags &= ~G_HOOK_FLAG_IN_CALL; + + hook = g_hook_next_valid (hook_list, hook, may_recurse); + } +} + +void +g_hook_list_invoke_check (GHookList *hook_list, + gboolean may_recurse) +{ + GHook *hook; + + g_return_if_fail (hook_list != NULL); + g_return_if_fail (hook_list->is_setup); + + hook = g_hook_first_valid (hook_list, may_recurse); + while (hook) + { + GHookCheckFunc func; + gboolean was_in_call; + gboolean need_destroy; + + func = (GHookCheckFunc) hook->func; + + was_in_call = G_HOOK_IN_CALL (hook); + hook->flags |= G_HOOK_FLAG_IN_CALL; + need_destroy = !func (hook->data); + if (!was_in_call) + hook->flags &= ~G_HOOK_FLAG_IN_CALL; + if (need_destroy) + g_hook_destroy_link (hook_list, hook); + + hook = g_hook_next_valid (hook_list, hook, may_recurse); + } +} + +void +g_hook_list_marshal_check (GHookList *hook_list, + gboolean may_recurse, + GHookCheckMarshaller marshaller, + gpointer data) +{ + GHook *hook; + + g_return_if_fail (hook_list != NULL); + g_return_if_fail (hook_list->is_setup); + g_return_if_fail (marshaller != NULL); + + hook = g_hook_first_valid (hook_list, may_recurse); + while (hook) + { + gboolean was_in_call; + gboolean need_destroy; + + was_in_call = G_HOOK_IN_CALL (hook); + hook->flags |= G_HOOK_FLAG_IN_CALL; + need_destroy = !marshaller (hook, data); + if (!was_in_call) + hook->flags &= ~G_HOOK_FLAG_IN_CALL; + if (need_destroy) + g_hook_destroy_link (hook_list, hook); + + hook = g_hook_next_valid (hook_list, hook, may_recurse); + } +} + +void +g_hook_list_marshal (GHookList *hook_list, + gboolean may_recurse, + GHookMarshaller marshaller, + gpointer data) +{ + GHook *hook; + + g_return_if_fail (hook_list != NULL); + g_return_if_fail (hook_list->is_setup); + g_return_if_fail (marshaller != NULL); + + hook = g_hook_first_valid (hook_list, may_recurse); + while (hook) + { + gboolean was_in_call; + + was_in_call = G_HOOK_IN_CALL (hook); + hook->flags |= G_HOOK_FLAG_IN_CALL; + marshaller (hook, data); + if (!was_in_call) + hook->flags &= ~G_HOOK_FLAG_IN_CALL; + + hook = g_hook_next_valid (hook_list, hook, may_recurse); + } +} + +GHook* +g_hook_first_valid (GHookList *hook_list, + gboolean may_be_in_call) +{ + g_return_val_if_fail (hook_list != NULL, NULL); + + if (hook_list->is_setup) + { + GHook *hook; + + hook = hook_list->hooks; + if (hook) + { + g_hook_ref (hook_list, hook); + if (G_HOOK_IS_VALID (hook) && (may_be_in_call || !G_HOOK_IN_CALL (hook))) + return hook; + else + return g_hook_next_valid (hook_list, hook, may_be_in_call); + } + } + + return NULL; +} + +GHook* +g_hook_next_valid (GHookList *hook_list, + GHook *hook, + gboolean may_be_in_call) +{ + GHook *ohook = hook; + + g_return_val_if_fail (hook_list != NULL, NULL); + + if (!hook) + return NULL; + + hook = hook->next; + while (hook) + { + if (G_HOOK_IS_VALID (hook) && (may_be_in_call || !G_HOOK_IN_CALL (hook))) + { + g_hook_ref (hook_list, hook); + g_hook_unref (hook_list, ohook); + + return hook; + } + hook = hook->next; + } + g_hook_unref (hook_list, ohook); + + return NULL; +} + +GHook* +g_hook_get (GHookList *hook_list, + gulong hook_id) +{ + GHook *hook; + + g_return_val_if_fail (hook_list != NULL, NULL); + g_return_val_if_fail (hook_id > 0, NULL); + + hook = hook_list->hooks; + while (hook) + { + if (hook->hook_id == hook_id) + return hook; + hook = hook->next; + } + + return NULL; +} + +GHook* +g_hook_find (GHookList *hook_list, + gboolean need_valids, + GHookFindFunc func, + gpointer data) +{ + GHook *hook; + + g_return_val_if_fail (hook_list != NULL, NULL); + g_return_val_if_fail (func != NULL, NULL); + + hook = hook_list->hooks; + while (hook) + { + GHook *tmp; + + /* test only non-destroyed hooks */ + if (!hook->hook_id) + { + hook = hook->next; + continue; + } + + g_hook_ref (hook_list, hook); + + if (func (hook, data) && hook->hook_id && (!need_valids || G_HOOK_ACTIVE (hook))) + { + g_hook_unref (hook_list, hook); + + return hook; + } + + tmp = hook->next; + g_hook_unref (hook_list, hook); + hook = tmp; + } + + return NULL; +} + +GHook* +g_hook_find_data (GHookList *hook_list, + gboolean need_valids, + gpointer data) +{ + GHook *hook; + + g_return_val_if_fail (hook_list != NULL, NULL); + + hook = hook_list->hooks; + while (hook) + { + /* test only non-destroyed hooks */ + if (hook->data == data && + hook->hook_id && + (!need_valids || G_HOOK_ACTIVE (hook))) + return hook; + + hook = hook->next; + } + + return NULL; +} + +GHook* +g_hook_find_func (GHookList *hook_list, + gboolean need_valids, + gpointer func) +{ + GHook *hook; + + g_return_val_if_fail (hook_list != NULL, NULL); + g_return_val_if_fail (func != NULL, NULL); + + hook = hook_list->hooks; + while (hook) + { + /* test only non-destroyed hooks */ + if (hook->func == func && + hook->hook_id && + (!need_valids || G_HOOK_ACTIVE (hook))) + return hook; + + hook = hook->next; + } + + return NULL; +} + +GHook* +g_hook_find_func_data (GHookList *hook_list, + gboolean need_valids, + gpointer func, + gpointer data) +{ + GHook *hook; + + g_return_val_if_fail (hook_list != NULL, NULL); + g_return_val_if_fail (func != NULL, NULL); + + hook = hook_list->hooks; + while (hook) + { + /* test only non-destroyed hooks */ + if (hook->data == data && + hook->func == func && + hook->hook_id && + (!need_valids || G_HOOK_ACTIVE (hook))) + return hook; + + hook = hook->next; + } + + return NULL; +} + +void +g_hook_insert_sorted (GHookList *hook_list, + GHook *hook, + GHookCompareFunc func) +{ + GHook *sibling; + + g_return_if_fail (hook_list != NULL); + g_return_if_fail (hook_list->is_setup); + g_return_if_fail (hook != NULL); + g_return_if_fail (G_HOOK_IS_UNLINKED (hook)); + g_return_if_fail (hook->func != NULL); + g_return_if_fail (func != NULL); + + /* first non-destroyed hook */ + sibling = hook_list->hooks; + while (sibling && !sibling->hook_id) + sibling = sibling->next; + + while (sibling) + { + GHook *tmp; + + g_hook_ref (hook_list, sibling); + if (func (hook, sibling) <= 0 && sibling->hook_id) + { + g_hook_unref (hook_list, sibling); + break; + } + + /* next non-destroyed hook */ + tmp = sibling->next; + while (tmp && !tmp->hook_id) + tmp = tmp->next; + + g_hook_unref (hook_list, sibling); + sibling = tmp; + } + + g_hook_insert_before (hook_list, sibling, hook); +} + +gint +g_hook_compare_ids (GHook *new_hook, + GHook *sibling) +{ + if (new_hook->hook_id < sibling->hook_id) + return -1; + else if (new_hook->hook_id > sibling->hook_id) + return 1; + + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/glib/ghook.h b/graf2d/win32gdk/gdk/src/glib/ghook.h index fe350e18e2ddb..e6bfb4614806c 100644 --- a/graf2d/win32gdk/gdk/src/glib/ghook.h +++ b/graf2d/win32gdk/gdk/src/glib/ghook.h @@ -27,10 +27,12 @@ #ifndef __G_HOOK_H__ #define __G_HOOK_H__ -#include <gmem.h> +#include <glib/gmem.h> G_BEGIN_DECLS + +/* --- typedefs --- */ typedef struct _GHook GHook; typedef struct _GHookList GHookList; @@ -39,60 +41,63 @@ typedef gint (*GHookCompareFunc) (GHook *new_hook, typedef gboolean (*GHookFindFunc) (GHook *hook, gpointer data); typedef void (*GHookMarshaller) (GHook *hook, - gpointer data); + gpointer marshal_data); typedef gboolean (*GHookCheckMarshaller) (GHook *hook, - gpointer data); + gpointer marshal_data); typedef void (*GHookFunc) (gpointer data); typedef gboolean (*GHookCheckFunc) (gpointer data); -typedef void (*GHookFreeFunc) (GHookList *hook_list, +typedef void (*GHookFinalizeFunc) (GHookList *hook_list, GHook *hook); - -/* Callback maintenance functions - */ -#define G_HOOK_FLAG_USER_SHIFT (4) typedef enum { - G_HOOK_FLAG_ACTIVE = 1 << 0, - G_HOOK_FLAG_IN_CALL = 1 << 1, - G_HOOK_FLAG_MASK = 0x0f + G_HOOK_FLAG_ACTIVE = 1 << 0, + G_HOOK_FLAG_IN_CALL = 1 << 1, + G_HOOK_FLAG_MASK = 0x0f } GHookFlagMask; +#define G_HOOK_FLAG_USER_SHIFT (4) -#define G_HOOK_DEFERRED_DESTROY ((GHookFreeFunc) 0x01) +/* --- structures --- */ struct _GHookList { - guint seq_id; - guint hook_size; - guint is_setup : 1; - GHook *hooks; - GMemChunk *hook_memchunk; - GHookFreeFunc hook_free; /* virtual function */ - GHookFreeFunc hook_destroy; /* virtual function */ + gulong seq_id; + guint hook_size : 16; + guint is_setup : 1; + GHook *hooks; + GMemChunk *hook_memchunk; + GHookFinalizeFunc finalize_hook; }; - struct _GHook { gpointer data; GHook *next; GHook *prev; guint ref_count; - guint hook_id; + gulong hook_id; guint flags; gpointer func; GDestroyNotify destroy; }; -#define G_HOOK_ACTIVE(hook) ((((GHook*) hook)->flags & \ + +/* --- macros --- */ +#define G_HOOK(hook) ((GHook*) (hook)) +#define G_HOOK_FLAGS(hook) (G_HOOK (hook)->flags) +#define G_HOOK_ACTIVE(hook) ((G_HOOK_FLAGS (hook) & \ G_HOOK_FLAG_ACTIVE) != 0) -#define G_HOOK_IN_CALL(hook) ((((GHook*) hook)->flags & \ +#define G_HOOK_IN_CALL(hook) ((G_HOOK_FLAGS (hook) & \ G_HOOK_FLAG_IN_CALL) != 0) -#define G_HOOK_IS_VALID(hook) (((GHook*) hook)->hook_id != 0 && \ - G_HOOK_ACTIVE (hook)) -#define G_HOOK_IS_UNLINKED(hook) (((GHook*) hook)->next == NULL && \ - ((GHook*) hook)->prev == NULL && \ - ((GHook*) hook)->hook_id == 0 && \ - ((GHook*) hook)->ref_count == 0) +#define G_HOOK_IS_VALID(hook) (G_HOOK (hook)->hook_id != 0 && \ + (G_HOOK_FLAGS (hook) & \ + G_HOOK_FLAG_ACTIVE)) +#define G_HOOK_IS_UNLINKED(hook) (G_HOOK (hook)->next == NULL && \ + G_HOOK (hook)->prev == NULL && \ + G_HOOK (hook)->hook_id == 0 && \ + G_HOOK (hook)->ref_count == 0) + +/* --- prototypes --- */ +/* callback mainenance functions */ void g_hook_list_init (GHookList *hook_list, guint hook_size); void g_hook_list_clear (GHookList *hook_list); @@ -104,7 +109,7 @@ void g_hook_ref (GHookList *hook_list, void g_hook_unref (GHookList *hook_list, GHook *hook); gboolean g_hook_destroy (GHookList *hook_list, - guint hook_id); + gulong hook_id); void g_hook_destroy_link (GHookList *hook_list, GHook *hook); void g_hook_prepend (GHookList *hook_list, @@ -116,7 +121,7 @@ void g_hook_insert_sorted (GHookList *hook_list, GHook *hook, GHookCompareFunc func); GHook* g_hook_get (GHookList *hook_list, - guint hook_id); + gulong hook_id); GHook* g_hook_find (GHookList *hook_list, gboolean need_valids, GHookFindFunc func, @@ -140,15 +145,12 @@ GHook* g_hook_first_valid (GHookList *hook_list, GHook* g_hook_next_valid (GHookList *hook_list, GHook *hook, gboolean may_be_in_call); - /* GHookCompareFunc implementation to insert hooks sorted by their id */ gint g_hook_compare_ids (GHook *new_hook, GHook *sibling); - /* convenience macros */ #define g_hook_append( hook_list, hook ) \ g_hook_insert_before ((hook_list), NULL, (hook)) - /* invoke all valid hooks with the (*GHookFunc) signature. */ void g_hook_list_invoke (GHookList *hook_list, @@ -163,11 +165,11 @@ void g_hook_list_invoke_check (GHookList *hook_list, void g_hook_list_marshal (GHookList *hook_list, gboolean may_recurse, GHookMarshaller marshaller, - gpointer data); + gpointer marshal_data); void g_hook_list_marshal_check (GHookList *hook_list, gboolean may_recurse, GHookCheckMarshaller marshaller, - gpointer data); + gpointer marshal_data); G_END_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/giochannel.c b/graf2d/win32gdk/gdk/src/glib/giochannel.c new file mode 100644 index 0000000000000..bebab838cafab --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/giochannel.c @@ -0,0 +1,2256 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * giochannel.c: IO Channel abstraction + * Copyright 1998 Owen Taylor + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#include "config.h" +#include "giochannel.h" + +#include <string.h> +#include <errno.h> + +#ifdef HAVE_UNISTD_H +#include <unistd.h> +#endif + +#undef G_DISABLE_DEPRECATED + +#include "glib.h" + +#include "glibintl.h" + +#define G_IO_NICE_BUF_SIZE 1024 + +/* This needs to be as wide as the largest character in any possible encoding */ +#define MAX_CHAR_SIZE 10 + +/* Some simplifying macros, which reduce the need to worry whether the + * buffers have been allocated. These also make USE_BUF () an lvalue, + * which is used in g_io_channel_read_to_end (). + */ +#define USE_BUF(channel) ((channel)->encoding ? (channel)->encoded_read_buf \ + : (channel)->read_buf) +#define BUF_LEN(string) ((string) ? (string)->len : 0) + +static GIOError g_io_error_get_from_g_error (GIOStatus status, + GError *err); +static void g_io_channel_purge (GIOChannel *channel); +static GIOStatus g_io_channel_fill_buffer (GIOChannel *channel, + GError **err); +static GIOStatus g_io_channel_read_line_backend (GIOChannel *channel, + gsize *length, + gsize *terminator_pos, + GError **error); + +void +g_io_channel_init (GIOChannel *channel) +{ + channel->ref_count = 1; + channel->encoding = g_strdup ("UTF-8"); + channel->line_term = NULL; + channel->line_term_len = 0; + channel->buf_size = G_IO_NICE_BUF_SIZE; + channel->read_cd = (GIConv) -1; + channel->write_cd = (GIConv) -1; + channel->read_buf = NULL; /* Lazy allocate buffers */ + channel->encoded_read_buf = NULL; + channel->write_buf = NULL; + channel->partial_write_buf[0] = '\0'; + channel->use_buffer = TRUE; + channel->do_encode = FALSE; + channel->close_on_unref = FALSE; +} + +void +g_io_channel_ref (GIOChannel *channel) +{ + g_return_if_fail (channel != NULL); + + channel->ref_count++; +} + +void +g_io_channel_unref (GIOChannel *channel) +{ + g_return_if_fail (channel != NULL); + + channel->ref_count--; + if (channel->ref_count == 0) + { + if (channel->close_on_unref) + g_io_channel_shutdown (channel, TRUE, NULL); + else + g_io_channel_purge (channel); + g_free (channel->encoding); + if (channel->read_cd != (GIConv) -1) + g_iconv_close (channel->read_cd); + if (channel->write_cd != (GIConv) -1) + g_iconv_close (channel->write_cd); + if (channel->line_term) + g_free (channel->line_term); + if (channel->read_buf) + g_string_free (channel->read_buf, TRUE); + if (channel->write_buf) + g_string_free (channel->write_buf, TRUE); + if (channel->encoded_read_buf) + g_string_free (channel->encoded_read_buf, TRUE); + channel->funcs->io_free (channel); + } +} + +static GIOError +g_io_error_get_from_g_error (GIOStatus status, + GError *err) +{ + switch (status) + { + case G_IO_STATUS_NORMAL: + case G_IO_STATUS_EOF: + return G_IO_ERROR_NONE; + case G_IO_STATUS_AGAIN: + return G_IO_ERROR_AGAIN; + case G_IO_STATUS_ERROR: + if (err->domain != G_IO_CHANNEL_ERROR) + return G_IO_ERROR_UNKNOWN; + switch (err->code) + { + case G_IO_CHANNEL_ERROR_INVAL: + return G_IO_ERROR_INVAL; + default: + return G_IO_ERROR_UNKNOWN; + } + default: + g_assert_not_reached (); + return G_IO_ERROR_UNKNOWN; /* Keep the compiler happy */ + } +} + +/** + * g_io_channel_read: + * @channel: a #GIOChannel. + * @buf: a buffer to read the data into (which should be at least count bytes long). + * @count: the number of bytes to read from the #GIOChannel. + * @bytes_read: returns the number of bytes actually read. + * + * Reads data from a #GIOChannel. This function is depricated. New code should + * use g_io_channel_read_chars() instead. + * + * Return value: %G_IO_ERROR_NONE if the operation was successful. + **/ +GIOError +g_io_channel_read (GIOChannel *channel, + gchar *buf, + gsize count, + gsize *bytes_read) +{ + GError *err = NULL; + GIOError error; + GIOStatus status; + + g_return_val_if_fail (channel != NULL, G_IO_ERROR_UNKNOWN); + g_return_val_if_fail (bytes_read != NULL, G_IO_ERROR_UNKNOWN); + + status = channel->funcs->io_read (channel, buf, count, bytes_read, &err); + + error = g_io_error_get_from_g_error (status, err); + + if (err) + g_error_free (err); + + return error; +} + +/** + * g_io_channel_write: + * @channel: a #GIOChannel. + * @buf: the buffer containing the data to write. + * @count: the number of bytes to write. + * @bytes_written: the number of bytes actually written. + * + * Writes data to a #GIOChannel. This function is depricated. New code should + * use g_io_channel_write_chars() instead. + * + * Return value: %G_IO_ERROR_NONE if the operation was successful. + **/ +GIOError +g_io_channel_write (GIOChannel *channel, + const gchar *buf, + gsize count, + gsize *bytes_written) +{ + GError *err = NULL; + GIOError error; + GIOStatus status; + + g_return_val_if_fail (channel != NULL, G_IO_ERROR_UNKNOWN); + g_return_val_if_fail (bytes_written != NULL, G_IO_ERROR_UNKNOWN); + + status = channel->funcs->io_write (channel, buf, count, bytes_written, &err); + + error = g_io_error_get_from_g_error (status, err); + + if (err) + g_error_free (err); + + return error; +} + +/** + * g_io_channel_seek: + * @channel: a #GIOChannel. + * @offset: an offset, in bytes, which is added to the position specified by @type + * @type: the position in the file, which can be %G_SEEK_CUR (the current + * position), %G_SEEK_SET (the start of the file), or %G_SEEK_END (the end of the + * file). + * + * Sets the current position in the #GIOChannel, similar to the standard library + * function fseek(). This function is depricated. New code should + * use g_io_channel_seek_position() instead. + * + * Return value: %G_IO_ERROR_NONE if the operation was successful. + **/ +GIOError +g_io_channel_seek (GIOChannel *channel, + glong offset, + GSeekType type) +{ + GError *err = NULL; + GIOError error; + GIOStatus status; + + g_return_val_if_fail (channel != NULL, G_IO_ERROR_UNKNOWN); + g_return_val_if_fail (channel->is_seekable, G_IO_ERROR_UNKNOWN); + + switch (type) + { + case G_SEEK_CUR: + case G_SEEK_SET: + case G_SEEK_END: + break; + default: + g_warning ("g_io_channel_seek: unknown seek type"); + return G_IO_ERROR_UNKNOWN; + } + + status = channel->funcs->io_seek (channel, offset, type, &err); + + error = g_io_error_get_from_g_error (status, err); + + if (err) + g_error_free (err); + + return error; +} + +/* The function g_io_channel_new_file() is prototyped in both + * giounix.c and giowin32.c, so we stick its documentation here. + */ + +/** + * g_io_channel_new_file: + * @filename: A string containing the name of a file. + * @mode: One of "r", "w", "a", "r+", "w+", "a+". These have + * the same meaning as in fopen(). + * @error: A location to return an error of type %G_IO_FILE_ERROR. + * + * Open a file @filename as a #GIOChannel using mode @mode. This + * channel will be closed when the last reference to it is dropped, + * so there is no need to call g_io_channel_close() (though doing + * so will not cause problems, as long as no attempt is made to + * access the channel after it is closed). + * + * Return value: A #GIOChannel on success, %NULL on failure. + **/ + +/** + * g_io_channel_close: + * @channel: A #GIOChannel + * + * Close an IO channel. Any pending data to be written will be + * flushed, ignoring errors. The channel will not be freed until the + * last reference is dropped using g_io_channel_unref(). This + * function is deprecated: you should use g_io_channel_shutdown() + * instead. + **/ +void +g_io_channel_close (GIOChannel *channel) +{ + GError *err = NULL; + + g_return_if_fail (channel != NULL); + + g_io_channel_purge (channel); + + channel->funcs->io_close (channel, &err); + + if (err) + { /* No way to return the error */ + g_warning ("Error closing channel: %s", err->message); + g_error_free (err); + } + + channel->close_on_unref = FALSE; /* Because we already did */ + channel->is_readable = FALSE; + channel->is_writeable = FALSE; + channel->is_seekable = FALSE; +} + +/** + * g_io_channel_shutdown: + * @channel: a #GIOChannel + * @flush: if %TRUE, flush pending + * @err: location to store a #GIOChannelError + * + * Close an IO channel. Any pending data to be written will be + * flushed if @flush is %TRUE. The channel will not be freed until the + * last reference is dropped using g_io_channel_unref(). + * + * Return value: + **/ +GIOStatus +g_io_channel_shutdown (GIOChannel *channel, + gboolean flush, + GError **err) +{ + GIOStatus status, result; + GError *tmperr = NULL; + + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail (err == NULL || *err == NULL, G_IO_STATUS_ERROR); + + if (flush && channel->write_buf && channel->write_buf->len > 0) + { + GIOFlags flags; + + /* Set the channel to blocking, to avoid a busy loop + */ + flags = g_io_channel_get_flags (channel); + /* Ignore any errors here, they're irrelevant */ + g_io_channel_set_flags (channel, flags & ~G_IO_FLAG_NONBLOCK, NULL); + + result = g_io_channel_flush (channel, &tmperr); + + if (channel->partial_write_buf[0] != '\0') + { + g_warning ("Partial character at end of write buffer not flushed.\n"); + channel->partial_write_buf[0] = '\0'; + } + } + else + result = G_IO_STATUS_NORMAL; + + status = channel->funcs->io_close (channel, err); + + channel->close_on_unref = FALSE; /* Because we already did */ + channel->is_readable = FALSE; + channel->is_writeable = FALSE; + channel->is_seekable = FALSE; + + if (status != G_IO_STATUS_NORMAL) + { + g_clear_error (&tmperr); + return status; + } + else if (result != G_IO_STATUS_NORMAL) + { + g_propagate_error (err, tmperr); + return result; + } + else + return G_IO_STATUS_NORMAL; +} + +/* This function is used for the final flush on close or unref */ +static void +g_io_channel_purge (GIOChannel *channel) +{ + GError *err = NULL; + GIOStatus status; + + g_return_if_fail (channel != NULL); + + if (channel->write_buf && channel->write_buf->len > 0) + { + GIOFlags flags; + + /* Set the channel to blocking, to avoid a busy loop + */ + flags = g_io_channel_get_flags (channel); + g_io_channel_set_flags (channel, flags & ~G_IO_FLAG_NONBLOCK, NULL); + + status = g_io_channel_flush (channel, &err); + + if (err) + { /* No way to return the error */ + g_warning ("Error flushing string: %s", err->message); + g_error_free (err); + } + } + + /* Flush these in case anyone tries to close without unrefing */ + + if (channel->read_buf) + g_string_truncate (channel->read_buf, 0); + if (channel->write_buf) + g_string_truncate (channel->write_buf, 0); + if (channel->encoding) + { + if (channel->encoded_read_buf) + g_string_truncate (channel->encoded_read_buf, 0); + + if (channel->partial_write_buf[0] != '\0') + { + g_warning ("Partial character at end of write buffer not flushed.\n"); + channel->partial_write_buf[0] = '\0'; + } + } +} + +GSource * +g_io_create_watch (GIOChannel *channel, + GIOCondition condition) +{ + g_return_val_if_fail (channel != NULL, NULL); + + return channel->funcs->io_create_watch (channel, condition); +} + +guint +g_io_add_watch_full (GIOChannel *channel, + gint priority, + GIOCondition condition, + GIOFunc func, + gpointer user_data, + GDestroyNotify notify) +{ + GSource *source; + guint id; + + g_return_val_if_fail (channel != NULL, 0); + + source = g_io_create_watch (channel, condition); + + if (priority != G_PRIORITY_DEFAULT) + g_source_set_priority (source, priority); + g_source_set_callback (source, (GSourceFunc)func, user_data, notify); + + id = g_source_attach (source, NULL); + g_source_unref (source); + + return id; +} + +guint +g_io_add_watch (GIOChannel *channel, + GIOCondition condition, + GIOFunc func, + gpointer user_data) +{ + return g_io_add_watch_full (channel, G_PRIORITY_DEFAULT, condition, func, user_data, NULL); +} + +/** + * g_io_channel_get_buffer_condition: + * @channel: A #GIOChannel + * + * This function returns a #GIOCondition depending on whether there + * is data to be read/space to write data in the + * internal buffers in the #GIOChannel. Only the flags %G_IO_IN and + * %G_IO_OUT may be set. + * + * Return value: A #GIOCondition + **/ +GIOCondition +g_io_channel_get_buffer_condition (GIOChannel *channel) +{ + GIOCondition condition = 0; + + if (channel->encoding) + { + if (channel->encoded_read_buf && (channel->encoded_read_buf->len > 0)) + condition |= G_IO_IN; /* Only return if we have full characters */ + } + else + { + if (channel->read_buf && (channel->read_buf->len > 0)) + condition |= G_IO_IN; + } + + if (channel->write_buf && (channel->write_buf->len < channel->buf_size)) + condition |= G_IO_OUT; + + return condition; +} + +/** + * g_io_channel_error_from_errno: + * @en: An errno error number, e.g. EINVAL + * + * Return value: A #GIOChannelError error number, e.g. %G_IO_CHANNEL_ERROR_INVAL + **/ +GIOChannelError +g_io_channel_error_from_errno (gint en) +{ +#ifdef EAGAIN + g_return_val_if_fail (en != EAGAIN, G_IO_CHANNEL_ERROR_FAILED); +#endif +#ifdef EINTR + g_return_val_if_fail (en != EINTR, G_IO_CHANNEL_ERROR_FAILED); +#endif + + switch (en) + { +#ifdef EBADF + case EBADF: + g_warning("Invalid file descriptor.\n"); + return G_IO_CHANNEL_ERROR_FAILED; +#endif + +#ifdef EFAULT + case EFAULT: + g_warning("File descriptor outside valid address space.\n"); + return G_IO_CHANNEL_ERROR_FAILED; +#endif + +#ifdef EFBIG + case EFBIG: + return G_IO_CHANNEL_ERROR_FBIG; +#endif + +#ifdef EINVAL + case EINVAL: + return G_IO_CHANNEL_ERROR_INVAL; +#endif + +#ifdef EIO + case EIO: + return G_IO_CHANNEL_ERROR_IO; +#endif + +#ifdef EISDIR + case EISDIR: + return G_IO_CHANNEL_ERROR_ISDIR; +#endif + +#ifdef ENOSPC + case ENOSPC: + return G_IO_CHANNEL_ERROR_NOSPC; +#endif + +#ifdef ENXIO + case ENXIO: + return G_IO_CHANNEL_ERROR_NXIO; +#endif + +#ifdef EOVERFLOW + case EOVERFLOW: + return G_IO_CHANNEL_ERROR_OVERFLOW; +#endif + +#ifdef EPIPE + case EPIPE: + return G_IO_CHANNEL_ERROR_PIPE; +#endif + + default: + return G_IO_CHANNEL_ERROR_FAILED; + } +} + +/** + * g_io_channel_set_buffer_size: + * @channel: a #GIOChannel + * @size: the size of the buffer. 0 == pick a good size + * + * Set the buffer size. + **/ +void +g_io_channel_set_buffer_size (GIOChannel *channel, + gsize size) +{ + g_return_if_fail (channel != NULL); + + if (size == 0) + size = G_IO_NICE_BUF_SIZE; + + if (size < MAX_CHAR_SIZE) + size = MAX_CHAR_SIZE; + + channel->buf_size = size; +} + +/** + * g_io_channel_get_buffer_size: + * @channel: a #GIOChannel + * + * Get the buffer size. + * + * Return value: the size of the buffer. + **/ +gsize +g_io_channel_get_buffer_size (GIOChannel *channel) +{ + g_return_val_if_fail (channel != NULL, 0); + + return channel->buf_size; +} + +/** + * g_io_channel_set_line_term: + * @channel: a #GIOChannel + * @line_term: The line termination string. Use %NULL for auto detect. + * Auto detection breaks on "\n", "\r\n", "\r", "\0", and + * the unicode paragraph separator. Auto detection should + * not be used for anything other than file-based channels. + * @length: The length of the termination string. If -1 is passed, the + * string is assumed to be null terminated. This option allows + * termination strings with embeded nulls. + * + * This sets the string that #GIOChannel uses to determine + * where in the file a line break occurs. + **/ +void +g_io_channel_set_line_term (GIOChannel *channel, + const gchar *line_term, + gint length) +{ + g_return_if_fail (channel != NULL); + g_return_if_fail (line_term == NULL || length != 0); /* Disallow "" */ + + if (line_term == NULL) + length = 0; + else if (length < 0) + length = strlen (line_term); + + if (channel->line_term) + g_free (channel->line_term); + channel->line_term = line_term ? g_memdup (line_term, length) : NULL; + channel->line_term_len = length; +} + +/** + * g_io_channel_get_line_term: + * @channel: a #GIOChannel + * @length: a location to return the length of the line terminator + * + * This returns the string that #GIOChannel uses to determine + * where in the file a line break occurs. A value of %NULL + * indicates auto detection. + * + * Return value: The line termination string. This value + * is owned by GLib and must not be freed. + **/ +G_CONST_RETURN gchar* +g_io_channel_get_line_term (GIOChannel *channel, + gint *length) +{ + g_return_val_if_fail (channel != NULL, 0); + + if (length) + *length = channel->line_term_len; + + return channel->line_term; +} + +/** + * g_io_channel_set_flags: + * @channel: a #GIOChannel + * @flags: the flags to set on the channel + * @error: A location to return an error of type #GIOChannelError + * + * Return value: + **/ +GIOStatus +g_io_channel_set_flags (GIOChannel *channel, + GIOFlags flags, + GError **error) +{ + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail ((error == NULL) || (*error == NULL), + G_IO_STATUS_ERROR); + + return (* channel->funcs->io_set_flags)(channel, + flags & G_IO_FLAG_SET_MASK, + error); +} + +/** + * g_io_channel_get_flags: + * @channel: a #GIOChannel + * + * Gets the current flags for a #GIOChannel, including read-only + * flags such as %G_IO_FLAG_IS_READABLE. + * + * The values of the flags %G_IO_FLAG_IS_READABLE and %G_IO_FLAG_IS_WRITEABLE + * are cached for internal use by the channel when it is created. + * If they should change at some later point (e.g. partial shutdown + * of a socket with the unix shutdown () function), the user + * should immediately call g_io_channel_get_flags () to update + * the internal values of these flags. + * + * Return value: the flags which are set on the channel + **/ +GIOFlags +g_io_channel_get_flags (GIOChannel *channel) +{ + GIOFlags flags; + + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + + flags = (* channel->funcs->io_get_flags) (channel); + + /* Cross implementation code */ + + if (channel->is_seekable) + flags |= G_IO_FLAG_IS_SEEKABLE; + if (channel->is_readable) + flags |= G_IO_FLAG_IS_READABLE; + if (channel->is_writeable) + flags |= G_IO_FLAG_IS_WRITEABLE; + + return flags; +} + +/** + * g_io_channel_set_close_on_unref: + * @channel: a #GIOChannel + * @do_close: Whether to close the channel on the final unref of + * the GIOChannel data structure. The default value of + * this is %TRUE for channels created by g_io_channel_new_file (), + * and %FALSE for all other channels. + * + * Setting this flag to %TRUE for a channel you have already closed + * can cause problems. + **/ +void +g_io_channel_set_close_on_unref (GIOChannel *channel, + gboolean do_close) +{ + g_return_if_fail (channel != NULL); + + channel->close_on_unref = do_close; +} + +/** + * g_io_channel_get_close_on_unref: + * @channel: a #GIOChannel + * + * Return value: Whether the channel will be closedi on the final unref of + * the GIOChannel data structure. The default value of + * this is %TRUE for channels created by g_io_channel_new_file (), + * and %FALSE for all other channels. + **/ +gboolean +g_io_channel_get_close_on_unref (GIOChannel *channel) +{ + g_return_val_if_fail (channel != NULL, FALSE); + + return channel->close_on_unref; +} + +/** + * g_io_channel_seek_position: + * @channel: a #GIOChannel + * @offset: The offset in bytes from the position specified by @type + * @type: a #GSeekType. The type %G_SEEK_CUR is only allowed in those + * cases where a call to g_io_channel_set_encoding () + * is allowed. See the documentation for + * g_io_channel_set_encoding () for details. + * @error: A location to return an error of type #GIOChannelError + * + * Replacement for g_io_channel_seek() with the new API. + * + * Return value: + **/ +GIOStatus +g_io_channel_seek_position (GIOChannel* channel, + glong offset, + GSeekType type, + GError **error) +{ + GIOStatus status; + + /* For files, only one of the read and write buffers can contain data. + * For sockets, both can contain data. + */ + + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail ((error == NULL) || (*error == NULL), + G_IO_STATUS_ERROR); + g_return_val_if_fail (channel->is_seekable, G_IO_STATUS_ERROR); + + switch (type) + { + case G_SEEK_CUR: /* The user is seeking relative to the head of the buffer */ + if (channel->use_buffer) + { + if (channel->do_encode && channel->encoded_read_buf + && channel->encoded_read_buf->len > 0) + { + g_warning ("Seek type G_SEEK_CUR not allowed for this" + " channel's encoding.\n"); + return G_IO_STATUS_ERROR; + } + if (channel->read_buf) + offset -= channel->read_buf->len; + if (channel->encoded_read_buf) + { + g_assert (channel->encoded_read_buf->len == 0 || !channel->do_encode); + + /* If there's anything here, it's because the encoding is UTF-8, + * so we can just subtract the buffer length, the same as for + * the unencoded data. + */ + + offset -= channel->encoded_read_buf->len; + } + } + break; + case G_SEEK_SET: + case G_SEEK_END: + break; + default: + g_warning ("g_io_channel_seek_position: unknown seek type"); + return G_IO_STATUS_ERROR; + } + + if (channel->use_buffer) + { + status = g_io_channel_flush (channel, error); + if (status != G_IO_STATUS_NORMAL) + return status; + } + + status = channel->funcs->io_seek (channel, offset, type, error); + + if ((status == G_IO_STATUS_NORMAL) && (channel->use_buffer)) + { + if (channel->read_buf) + g_string_truncate (channel->read_buf, 0); + + /* Conversion state no longer matches position in file */ + if (channel->read_cd != (GIConv) -1) + g_iconv (channel->read_cd, NULL, NULL, NULL, NULL); + if (channel->write_cd != (GIConv) -1) + g_iconv (channel->write_cd, NULL, NULL, NULL, NULL); + + if (channel->encoded_read_buf) + { + g_assert (channel->encoded_read_buf->len == 0 || !channel->do_encode); + g_string_truncate (channel->encoded_read_buf, 0); + } + + if (channel->partial_write_buf[0] != '\0') + { + g_warning ("Partial character at end of write buffer not flushed.\n"); + channel->partial_write_buf[0] = '\0'; + } + } + + return status; +} + +/** + * g_io_channel_flush: + * @channel: a #GIOChannel + * @error: location to store an error of type #GIOChannelError + * + * Flush the write buffer for the GIOChannel. + * + * Return value: the status of the operation: One of + * G_IO_CHANNEL_NORMAL, G_IO_CHANNEL_AGAIN, or + * G_IO_CHANNEL_ERROR. + **/ +GIOStatus +g_io_channel_flush (GIOChannel *channel, + GError **error) +{ + GIOStatus status; + gsize this_time = 1, bytes_written = 0; + + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail ((error == NULL) || (*error == NULL), G_IO_STATUS_ERROR); + + if (channel->write_buf == NULL || channel->write_buf->len == 0) + return G_IO_STATUS_NORMAL; + + do + { + g_assert (this_time > 0); + + status = channel->funcs->io_write (channel, + channel->write_buf->str + bytes_written, + channel->write_buf->len - bytes_written, + &this_time, error); + bytes_written += this_time; + } + while ((bytes_written < channel->write_buf->len) + && (status == G_IO_STATUS_NORMAL)); + + g_string_erase (channel->write_buf, 0, bytes_written); + + return status; +} + +/** + * g_io_channel_set_buffered: + * @channel: a #GIOChannel + * @buffered: whether to set the channel buffered or unbuffered + * + * The buffering state can only be set if the channel's encoding + * is %NULL. For any other encoding, the channel must be buffered. + * + * A buffered channel can only be set unbuffered if the channel's + * internal buffers have been flushed. Newly created channels or + * channels which have returned G_IO_STATUS_EOF + * not require such a flush. For write-only channels, a call to + * g_io_channel_flush () is sufficient. For all other channels, + * the buffers may be flushed by a call to g_io_channel_seek_position (). + * This includes the possibility of seeking with seek type %G_SEEK_CUR + * and an offset of zero. Note that this means that socket-based + * channels cannot be set unbuffered once they have had data + * read from them. + * + * On unbuffered channels, it is safe to mix read and write + * calls from the new and old APIs, if this is necessary for + * maintaining old code. + * + * The default state of the channel is buffered. + **/ +void +g_io_channel_set_buffered (GIOChannel *channel, + gboolean buffered) +{ + g_return_if_fail (channel != NULL); + + if (channel->encoding != NULL) + { + g_warning ("Need to have NULL encoding to set the buffering state of the " + "channel.\n"); + return; + } + + g_return_if_fail (!channel->read_buf || channel->read_buf->len == 0); + g_return_if_fail (!channel->write_buf || channel->write_buf->len == 0); + + channel->use_buffer = buffered; +} + +/** + * g_io_channel_get_buffered: + * @channel: a #GIOChannel + * + * Return Value: the buffering state of the channel + **/ +gboolean +g_io_channel_get_buffered (GIOChannel *channel) +{ + g_return_val_if_fail (channel != NULL, FALSE); + + return channel->use_buffer; +} + +/** + * g_io_channel_set_encoding: + * @channel: a #GIOChannel + * @encoding: the encoding type + * @error: location to store an error of type #GConvertError. + * + * Set the encoding for the input/output of the channel. The internal + * encoding is always UTF-8. The default encoding for the + * external file is UTF-8. + * + * The encoding %NULL is safe to use with binary data. + * + * The encoding can only be set under the following conditions: + * + * 1. The channel was just created, and has not been written to + * or read from yet. + * + * 2. The channel is write-only. + * + * 3. The channel is a file, and the file pointer was just + * repositioned by a call to g_io_channel_seek_position(). + * (This flushes all the internal buffers.) + * + * 4. The current encoding is %NULL or UTF-8. + * + * 5. One of the (new API) read functions has just returned G_IO_STATUS_EOF + * (or, in the case of g_io_channel_read_to_end (), G_IO_STATUS_NORMAL). + * + * 6. One of the functions g_io_channel_read_chars () or g_io_channel_read_unichar () + * has returned G_IO_STATUS_AGAIN or G_IO_STATUS_ERROR. This may be + * useful in the case of G_CONVERT_ERROR_ILLEGAL_SEQUENCE. + * Returning one of these statuses from g_io_channel_read_line (), + * g_io_channel_read_line_string (), or g_io_channel_read_to_end () + * does _not_ guarantee that the encoding can be changed. + * + * Channels which do not meet the above conditions cannot call + * g_io_channel_seek_position () with an offset of %G_SEEK_CUR, + * and if they are "seekable" cannot + * call g_io_channel_write_chars () after calling one + * of the API "read" functions. + * + * Return Value: %G_IO_STATUS_NORMAL if the encoding was succesfully set. + **/ +GIOStatus +g_io_channel_set_encoding (GIOChannel *channel, + const gchar *encoding, + GError **error) +{ + GIConv read_cd, write_cd; + gboolean did_encode; + + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail ((error == NULL) || (*error == NULL), G_IO_STATUS_ERROR); + + /* Make sure the encoded buffers are empty */ + + g_return_val_if_fail (!channel->do_encode || !channel->encoded_read_buf || + channel->encoded_read_buf->len == 0, G_IO_STATUS_ERROR); + + if (!channel->use_buffer) + { + g_warning ("Need to set the channel buffered before setting the encoding.\n"); + g_warning ("Assuming this is what you meant and acting accordingly.\n"); + + channel->use_buffer = TRUE; + } + + if (channel->partial_write_buf[0] != '\0') + { + g_warning ("Partial character at end of write buffer not flushed.\n"); + channel->partial_write_buf[0] = '\0'; + } + + did_encode = channel->do_encode; + + if (!encoding || strcmp (encoding, "UTF8") == 0 || strcmp (encoding, "UTF-8") == 0) + { + channel->do_encode = FALSE; + read_cd = write_cd = (GIConv) -1; + } + else + { + gint err = 0; + const gchar *from_enc = NULL, *to_enc = NULL; + + if (channel->is_readable) + { + read_cd = g_iconv_open ("UTF-8", encoding); + + if (read_cd == (GIConv) -1) + { + err = errno; + from_enc = "UTF-8"; + to_enc = encoding; + } + } + else + read_cd = (GIConv) -1; + + if (channel->is_writeable && err == 0) + { + write_cd = g_iconv_open (encoding, "UTF-8"); + + if (write_cd == (GIConv) -1) + { + err = errno; + from_enc = encoding; + to_enc = "UTF-8"; + } + } + else + write_cd = (GIConv) -1; + + if (err != 0) + { + g_assert (from_enc); + g_assert (to_enc); + + if (err == EINVAL) + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_NO_CONVERSION, + _("Conversion from character set `%s' to `%s' is not supported"), + from_enc, to_enc); + else + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED, + _("Could not open converter from `%s' to `%s': %s"), + from_enc, to_enc, strerror (err)); + + if (read_cd != (GIConv) -1) + g_iconv_close (read_cd); + if (write_cd != (GIConv) -1) + g_iconv_close (write_cd); + + return G_IO_STATUS_ERROR; + } + + channel->do_encode = TRUE; + } + + /* The encoding is ok, so set the fields in channel */ + + if (channel->read_cd != (GIConv) -1) + g_iconv_close (channel->read_cd); + if (channel->write_cd != (GIConv) -1) + g_iconv_close (channel->write_cd); + + if (channel->encoded_read_buf && channel->encoded_read_buf->len > 0) + { + g_assert (!did_encode); /* Encoding UTF-8, NULL doesn't use encoded_read_buf */ + + /* This is just validated UTF-8, so we can copy it back into read_buf + * so it can be encoded in whatever the new encoding is. + */ + + g_string_prepend_len (channel->read_buf, channel->encoded_read_buf->str, + channel->encoded_read_buf->len); + g_string_truncate (channel->encoded_read_buf, 0); + } + + channel->read_cd = read_cd; + channel->write_cd = write_cd; + + g_free (channel->encoding); + channel->encoding = g_strdup (encoding); + + return G_IO_STATUS_NORMAL; +} + +/** + * g_io_channel_get_encoding: + * @channel: a #GIOChannel + * + * Get the encoding for the input/output of the channel. The internal + * encoding is always UTF-8. The encoding %NULL makes the + * channel safe for binary data. + * + * Return value: A string containing the encoding, this string is + * owned by GLib and must not be freed. + **/ +G_CONST_RETURN gchar* +g_io_channel_get_encoding (GIOChannel *channel) +{ + g_return_val_if_fail (channel != NULL, NULL); + + return channel->encoding; +} + +static GIOStatus +g_io_channel_fill_buffer (GIOChannel *channel, + GError **err) +{ + gsize read_size, cur_len, oldlen; + GIOStatus status; + + if (channel->is_seekable && channel->write_buf && channel->write_buf->len > 0) + { + status = g_io_channel_flush (channel, err); + if (status != G_IO_STATUS_NORMAL) + return status; + } + if (channel->is_seekable && channel->partial_write_buf[0] != '\0') + { + g_warning ("Partial character at end of write buffer not flushed.\n"); + channel->partial_write_buf[0] = '\0'; + } + + if (!channel->read_buf) + channel->read_buf = g_string_sized_new (channel->buf_size); + + cur_len = channel->read_buf->len; + + g_string_set_size (channel->read_buf, channel->read_buf->len + channel->buf_size); + + status = channel->funcs->io_read (channel, channel->read_buf->str + cur_len, + channel->buf_size, &read_size, err); + + g_assert ((status == G_IO_STATUS_NORMAL) || (read_size == 0)); + + g_string_truncate (channel->read_buf, read_size + cur_len); + + if ((status != G_IO_STATUS_NORMAL) + && ((status != G_IO_STATUS_EOF) || (channel->read_buf->len == 0))) + return status; + + g_assert (channel->read_buf->len > 0); + + if (channel->encoded_read_buf) + oldlen = channel->encoded_read_buf->len; + else + { + oldlen = 0; + if (channel->encoding) + channel->encoded_read_buf = g_string_sized_new (channel->buf_size); + } + + if (channel->do_encode) + { + size_t errnum, inbytes_left, outbytes_left; + gchar *inbuf, *outbuf; + int errval; + + g_assert (channel->encoded_read_buf); + +reencode: + + inbytes_left = channel->read_buf->len; + outbytes_left = MAX (channel->read_buf->len, + channel->encoded_read_buf->allocated_len + - channel->encoded_read_buf->len - 1); /* 1 for NULL */ + outbytes_left = MAX (outbytes_left, 6); + + inbuf = channel->read_buf->str; + g_string_set_size (channel->encoded_read_buf, + channel->encoded_read_buf->len + outbytes_left); + outbuf = channel->encoded_read_buf->str + channel->encoded_read_buf->len + - outbytes_left; + + errnum = g_iconv (channel->read_cd, &inbuf, &inbytes_left, + &outbuf, &outbytes_left); + errval = errno; + + g_assert (inbuf + inbytes_left == channel->read_buf->str + + channel->read_buf->len); + g_assert (outbuf + outbytes_left == channel->encoded_read_buf->str + + channel->encoded_read_buf->len); + + g_string_erase (channel->read_buf, 0, + channel->read_buf->len - inbytes_left); + g_string_truncate (channel->encoded_read_buf, + channel->encoded_read_buf->len - outbytes_left); + + if (errnum == (size_t) -1) + { + switch (errval) + { + case EINVAL: + if ((oldlen == channel->encoded_read_buf->len) + && (status == G_IO_STATUS_EOF)) + status = G_IO_STATUS_EOF; + else + status = G_IO_STATUS_NORMAL; + break; + case E2BIG: + /* Buffer size at least 6, wrote at least on character */ + g_assert (inbuf != channel->read_buf->str); + goto reencode; + case EILSEQ: + if (oldlen < channel->encoded_read_buf->len) + status = G_IO_STATUS_NORMAL; + else + { + g_set_error (err, G_CONVERT_ERROR, + G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid byte sequence in conversion input")); + return G_IO_STATUS_ERROR; + } + break; + default: + g_assert (errval != EBADF); /* The converter should be open */ + g_set_error (err, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED, + _("Error during conversion: %s"), strerror (errval)); + return G_IO_STATUS_ERROR; + } + } + g_assert ((status != G_IO_STATUS_NORMAL) + || (channel->encoded_read_buf->len > 0)); + } + else if (channel->encoding) /* UTF-8 */ + { + gchar *nextchar, *lastchar; + + g_assert (channel->encoded_read_buf); + + nextchar = channel->read_buf->str; + lastchar = channel->read_buf->str + channel->read_buf->len; + + while (nextchar < lastchar) + { + gunichar val_char; + + val_char = g_utf8_get_char_validated (nextchar, lastchar - nextchar); + + switch (val_char) + { + case -2: + /* stop, leave partial character in buffer */ + lastchar = nextchar; + break; + case -1: + if (oldlen < channel->encoded_read_buf->len) + status = G_IO_STATUS_NORMAL; + else + { + g_set_error (err, G_CONVERT_ERROR, + G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid byte sequence in conversion input")); + status = G_IO_STATUS_ERROR; + } + lastchar = nextchar; + break; + default: + nextchar = g_utf8_next_char (nextchar); + break; + } + } + + if (lastchar > channel->read_buf->str) + { + gint copy_len = lastchar - channel->read_buf->str; + + g_string_append_len (channel->encoded_read_buf, channel->read_buf->str, + copy_len); + g_string_erase (channel->read_buf, 0, copy_len); + } + } + + return status; +} + +/** + * g_io_channel_read_line: + * @channel: a #GIOChannel + * @str_return: The line read from the #GIOChannel, not including the + * line terminator. This data should be freed with g_free() + * when no longer needed. This + * is a null terminated string. If a @length of zero is + * returned, this will be %NULL instead. + * @length: location to store length of the read data, or %NULL + * @terminator_pos: location to store position of line terminator, or %NULL + * @error: A location to return an error of type #GConvertError + * or #GIOChannelError + * + * Read a line, including the terminating character(s), + * from a #GIOChannel into a newly allocated string. + * @length will contain allocated memory if the return + * is %G_IO_STATUS_NORMAL. + * + * Return value: a newly allocated string. Free this string + * with g_free() when you are done with it. + **/ +GIOStatus +g_io_channel_read_line (GIOChannel *channel, + gchar **str_return, + gsize *length, + gsize *terminator_pos, + GError **error) +{ + GIOStatus status; + gsize got_length; + + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail (str_return != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail ((error == NULL) || (*error == NULL), + G_IO_STATUS_ERROR); + g_return_val_if_fail (channel->is_readable, G_IO_STATUS_ERROR); + + status = g_io_channel_read_line_backend (channel, &got_length, terminator_pos, error); + + if (length) + *length = got_length; + + if (status == G_IO_STATUS_NORMAL) + { + g_assert (USE_BUF (channel)); + *str_return = g_strndup (USE_BUF (channel)->str, got_length); + g_string_erase (USE_BUF (channel), 0, got_length); + } + else + *str_return = NULL; + + return status; +} + +/** + * g_io_channel_read_line_string: + * @channel: a #GIOChannel + * @buffer: a #GString into which the line will be written. + * If @buffer already contains data, the old data will + * be overwritten. + * @terminator_pos: location to store position of line terminator, or %NULL + * @error: a location to store an error of type #GConvertError + * or #GIOChannelError + * + * Read a line from a #GIOChannel, using a #GString as a buffer. + * + * Return value: + **/ +GIOStatus +g_io_channel_read_line_string (GIOChannel *channel, + GString *buffer, + gsize *terminator_pos, + GError **error) +{ + gsize length; + GIOStatus status; + + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail (buffer != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail ((error == NULL) || (*error == NULL), + G_IO_STATUS_ERROR); + g_return_val_if_fail (channel->is_readable, G_IO_STATUS_ERROR); + + if (buffer->len > 0) + g_string_truncate (buffer, 0); /* clear out the buffer */ + + status = g_io_channel_read_line_backend (channel, &length, terminator_pos, error); + + if (status == G_IO_STATUS_NORMAL) + { + g_assert (USE_BUF (channel)); + g_string_append_len (buffer, USE_BUF (channel)->str, length); + g_string_erase (USE_BUF (channel), 0, length); + } + + return status; +} + + +static GIOStatus +g_io_channel_read_line_backend (GIOChannel *channel, + gsize *length, + gsize *terminator_pos, + GError **error) +{ + GIOStatus status; + gsize checked_to, line_term_len, line_length, got_term_len; + gboolean first_time = TRUE; + + if (!channel->use_buffer) + { + /* Can't do a raw read in read_line */ + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED, + _("Can't do a raw read in g_io_channel_read_line_string")); + return G_IO_STATUS_ERROR; + } + + status = G_IO_STATUS_NORMAL; + + if (channel->line_term) + line_term_len = channel->line_term_len; + else + line_term_len = 3; + /* This value used for setting checked_to, it's the longest of the four + * we autodetect for. + */ + + checked_to = 0; + + while (TRUE) + { + gchar *nextchar, *lastchar; + GString *use_buf; + + if (!first_time || (BUF_LEN (USE_BUF (channel)) == 0)) + { +read_again: + status = g_io_channel_fill_buffer (channel, error); + switch (status) + { + case G_IO_STATUS_NORMAL: + if (BUF_LEN (USE_BUF (channel)) == 0) + /* Can happen when using conversion and only read + * part of a character + */ + { + first_time = FALSE; + continue; + } + break; + case G_IO_STATUS_EOF: + if (BUF_LEN (USE_BUF (channel)) == 0) + { + if (length) + *length = 0; + + if (channel->encoding && channel->read_buf->len != 0) + { + g_set_error (error, G_CONVERT_ERROR, + G_CONVERT_ERROR_PARTIAL_INPUT, + "Leftover unconverted data in read buffer"); + return G_IO_STATUS_ERROR; + } + else + return G_IO_STATUS_EOF; + } + break; + default: + if (length) + *length = 0; + return status; + } + } + + g_assert (BUF_LEN (USE_BUF (channel)) != 0); + + use_buf = USE_BUF (channel); /* The buffer has been created by this point */ + + first_time = FALSE; + + lastchar = use_buf->str + use_buf->len; + + for (nextchar = use_buf->str + checked_to; nextchar < lastchar; + channel->encoding ? nextchar = g_utf8_next_char (nextchar) : nextchar++) + { + if (channel->line_term) + { + if (memcmp (channel->line_term, nextchar, line_term_len) == 0) + { + line_length = nextchar - use_buf->str; + got_term_len = line_term_len; + goto done; + } + } + else /* auto detect */ + { + switch (*nextchar) + { + case '\n': /* unix */ + line_length = nextchar - use_buf->str; + got_term_len = 1; + goto done; + case '\r': /* Warning: do not use with sockets */ + line_length = nextchar - use_buf->str; + if ((nextchar == lastchar - 1) && (status != G_IO_STATUS_EOF) + && (lastchar == use_buf->str + use_buf->len)) + goto read_again; /* Try to read more data */ + if ((nextchar < lastchar - 1) && (*(nextchar + 1) == '\n')) /* dos */ + got_term_len = 2; + else /* mac */ + got_term_len = 1; + goto done; + case '\xe2': /* Unicode paragraph separator */ + if (strncmp ("\xe2\x80\xa9", nextchar, 3) == 0) + { + line_length = nextchar - use_buf->str; + got_term_len = 3; + goto done; + } + break; + case '\0': /* Embeded null in input */ + line_length = nextchar - use_buf->str; + got_term_len = 1; + goto done; + default: /* no match */ + break; + } + } + } + + /* If encoding != NULL, valid UTF-8, didn't overshoot */ + g_assert (nextchar == lastchar); + + /* Check for EOF */ + + if (status == G_IO_STATUS_EOF) + { + if (channel->encoding && channel->read_buf->len > 0) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_PARTIAL_INPUT, + "Channel terminates in a partial character"); + return G_IO_STATUS_ERROR; + } + line_length = use_buf->len; + got_term_len = 0; + break; + } + + checked_to = MAX (use_buf->len - (line_term_len - 1), 0); + } + +done: + + if (terminator_pos) + *terminator_pos = line_length; + + if (length) + *length = line_length + got_term_len; + + return G_IO_STATUS_NORMAL; +} + +/** + * g_io_channel_read_to_end: + * @channel: a #GIOChannel + * @str_return: Location to store a pointer to a string holding + * the remaining data in the #GIOChannel. This data should + * be freed with g_free() when no longer needed. This + * data is terminated by an extra null, but there may be other + * nulls in the intervening data. + * @length: Location to store length of the data + * @error: A location to return an error of type #GConvertError + * or #GIOChannelError + * + * Read all the remaining data from the file. + * + * Return value: %G_IO_STATUS_NORMAL on success. This function never + * returns %G_IO_STATUS_EOF. + **/ +GIOStatus +g_io_channel_read_to_end (GIOChannel *channel, + gchar **str_return, + gsize *length, + GError **error) +{ + GIOStatus status; + + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail ((error == NULL) || (*error == NULL), + G_IO_STATUS_ERROR); + g_return_val_if_fail (channel->is_readable, G_IO_STATUS_ERROR); + + if (str_return) + *str_return = NULL; + if (length) + *length = 0; + + if (!channel->use_buffer) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED, + _("Can't do a raw read in g_io_channel_read_to_end")); + return G_IO_STATUS_ERROR; + } + + do + status = g_io_channel_fill_buffer (channel, error); + while (status == G_IO_STATUS_NORMAL); + + if (status != G_IO_STATUS_EOF) + return status; + + if (channel->encoding && channel->read_buf->len > 0) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_PARTIAL_INPUT, + "Channel terminates in a partial character"); + return G_IO_STATUS_ERROR; + } + + if (USE_BUF (channel) == NULL) + { + /* length is already set to zero */ + if (str_return) + *str_return = g_strdup (""); + } + else + { + if (length) + *length = USE_BUF (channel)->len; + + if (str_return) + *str_return = g_string_free (USE_BUF (channel), FALSE); + else + g_string_free (USE_BUF (channel), TRUE); + + if (channel->encoding) + channel->encoded_read_buf = NULL; + else + channel->read_buf = NULL; + } + + return G_IO_STATUS_NORMAL; +} + +/** + * g_io_channel_read_chars: + * @channel: a #GIOChannel + * @buf: a buffer to read data into + * @count: the size of the buffer. Note that the buffer may + * not be complelely filled even if there is data + * in the buffer if the remaining data is not a + * complete character. + * @bytes_read: The number of bytes read. This may be zero even on + * success if count < 6 and the channel's encoding is non-%NULL. + * This indicates that the next UTF-8 character is too wide for + * the buffer. + * @error: A location to return an error of type #GConvertError + * or #GIOChannelError. + * + * Replacement for g_io_channel_read() with the new API. + * + * Return value: + **/ +GIOStatus +g_io_channel_read_chars (GIOChannel *channel, + gchar *buf, + gsize count, + gsize *bytes_read, + GError **error) +{ + GIOStatus status; + gsize got_bytes; + + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail ((error == NULL) || (*error == NULL), + G_IO_STATUS_ERROR); + g_return_val_if_fail (channel->is_readable, G_IO_STATUS_ERROR); + + if (count == 0) + { + *bytes_read = 0; + return G_IO_STATUS_NORMAL; + } + g_return_val_if_fail (buf != NULL, G_IO_STATUS_ERROR); + + if (!channel->use_buffer) + { + gint tmp_bytes; + + g_assert (!channel->read_buf || channel->read_buf->len == 0); + + status = channel->funcs->io_read (channel, buf, count, &tmp_bytes, error); + + if (bytes_read) + *bytes_read = tmp_bytes; + + return status; + } + + status = G_IO_STATUS_NORMAL; + + while (BUF_LEN (USE_BUF (channel)) < count && status == G_IO_STATUS_NORMAL) + status = g_io_channel_fill_buffer (channel, error); + + /* Only return an error if we have no data */ + + if (BUF_LEN (USE_BUF (channel)) == 0) + { + g_assert (status != G_IO_STATUS_NORMAL); + + if (status == G_IO_STATUS_EOF && channel->encoding + && BUF_LEN (channel->read_buf) > 0) + { + g_set_error (error, G_CONVERT_ERROR, + G_CONVERT_ERROR_PARTIAL_INPUT, + "Leftover unconverted data in read buffer"); + status = G_IO_STATUS_ERROR; + } + + if (bytes_read) + *bytes_read = 0; + + return status; + } + + if (status == G_IO_STATUS_ERROR) + g_clear_error (error); + + got_bytes = MIN (count, BUF_LEN (USE_BUF (channel))); + + g_assert (got_bytes > 0); + + if (channel->encoding) + /* Don't validate for NULL encoding, binary safe */ + { + gchar *nextchar, *prevchar; + + g_assert (USE_BUF (channel) == channel->encoded_read_buf); + + nextchar = channel->encoded_read_buf->str; + + do + { + prevchar = nextchar; + nextchar = g_utf8_next_char (nextchar); + g_assert (nextchar != prevchar); /* Possible for *prevchar of -1 or -2 */ + } + while (nextchar < channel->encoded_read_buf->str + got_bytes); + + if (nextchar > channel->encoded_read_buf->str + got_bytes) + got_bytes = prevchar - channel->encoded_read_buf->str; + + g_assert (got_bytes > 0 || count < 6); + } + + memcpy (buf, USE_BUF (channel)->str, got_bytes); + g_string_erase (USE_BUF (channel), 0, got_bytes); + + if (bytes_read) + *bytes_read = got_bytes; + + return G_IO_STATUS_NORMAL; +} + +/** + * g_io_channel_read_unichar: + * @channel: a #GIOChannel + * @thechar: a location to return a character + * @error: A location to return an error of type #GConvertError + * or #GIOChannelError + * + * This function cannot be called on a channel with %NULL encoding. + * + * Return value: a #GIOStatus + **/ +GIOStatus +g_io_channel_read_unichar (GIOChannel *channel, + gunichar *thechar, + GError **error) +{ + GIOStatus status = G_IO_STATUS_NORMAL; + + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail (channel->encoding != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail ((error == NULL) || (*error == NULL), + G_IO_STATUS_ERROR); + g_return_val_if_fail (channel->is_readable, G_IO_STATUS_ERROR); + + while (BUF_LEN (channel->encoded_read_buf) == 0 && status == G_IO_STATUS_NORMAL) + status = g_io_channel_fill_buffer (channel, error); + + /* Only return an error if we have no data */ + + if (BUF_LEN (USE_BUF (channel)) == 0) + { + g_assert (status != G_IO_STATUS_NORMAL); + + if (status == G_IO_STATUS_EOF && BUF_LEN (channel->read_buf) > 0) + { + g_set_error (error, G_CONVERT_ERROR, + G_CONVERT_ERROR_PARTIAL_INPUT, + "Leftover unconverted data in read buffer"); + status = G_IO_STATUS_ERROR; + } + + if (thechar) + *thechar = (gunichar) -1; + + return status; + } + + if (status == G_IO_STATUS_ERROR) + g_clear_error (error); + + if (thechar) + *thechar = g_utf8_get_char (channel->encoded_read_buf->str); + + g_string_erase (channel->encoded_read_buf, 0, + g_utf8_next_char (channel->encoded_read_buf->str) + - channel->encoded_read_buf->str); + + return G_IO_STATUS_NORMAL; +} + +/** + * g_io_channel_write_chars: + * @channel: a #GIOChannel + * @buf: a buffer to write data from + * @count: the size of the buffer. If -1, the buffer + * is taken to be a nul terminated string. + * @bytes_written: The number of bytes written. This can be nonzero + * even if the return value is not %G_IO_STATUS_NORMAL. + * If the return value is %G_IO_STATUS_NORMAL and the + * channel is blocking, this will always be equal + * to @count if @count >= 0. + * @error: A location to return an error of type #GConvertError + * or #GIOChannelError + * + * Replacement for g_io_channel_write() with the new API. + * + * On seekable channels with encodings other than %NULL or UTF-8, generic + * mixing of reading and writing is not allowed. A call to g_io_channel_write_chars () + * may only be made on a channel from which data has been read in the + * cases described in the documentation for g_io_channel_set_encoding (). + * + * Return value: + **/ +GIOStatus +g_io_channel_write_chars (GIOChannel *channel, + const gchar *buf, + gssize count, + gsize *bytes_written, + GError **error) +{ + GIOStatus status; + gssize wrote_bytes = 0; + + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail ((error == NULL) || (*error == NULL), + G_IO_STATUS_ERROR); + g_return_val_if_fail (channel->is_writeable, G_IO_STATUS_ERROR); + + if ((count < 0) && buf) + count = strlen (buf); + + if (count == 0) + { + if (bytes_written) + *bytes_written = 0; + return G_IO_STATUS_NORMAL; + } + + g_return_val_if_fail (buf != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail (count > 0, G_IO_STATUS_ERROR); + + /* Raw write case */ + + if (!channel->use_buffer) + { + gint tmp_bytes; + + g_assert (!channel->write_buf || channel->write_buf->len == 0); + g_assert (channel->partial_write_buf[0] == '\0'); + + status = channel->funcs->io_write (channel, buf, count, &tmp_bytes, error); + + if (bytes_written) + *bytes_written = tmp_bytes; + + return status; + } + + /* General case */ + + if (channel->is_seekable && (( BUF_LEN (channel->read_buf) > 0) + || (BUF_LEN (channel->encoded_read_buf) > 0))) + { + if (channel->do_encode && BUF_LEN (channel->encoded_read_buf) > 0) + { + g_warning("Mixed reading and writing not allowed on encoded files"); + return G_IO_STATUS_ERROR; + } + status = g_io_channel_seek_position (channel, 0, G_SEEK_CUR, error); + if (status != G_IO_STATUS_NORMAL) + { + if (bytes_written) + *bytes_written = 0; + return status; + } + } + + if (!channel->write_buf) + channel->write_buf = g_string_sized_new (channel->buf_size); + + while (wrote_bytes < count) + { + gsize space_in_buf; + + /* If the buffer is full, try a write immediately. In + * the nonblocking case, this prevents the user from + * writing just a little bit to the buffer every time + * and never receiving an EAGAIN. + */ + + if (channel->write_buf->len >= channel->buf_size) + { + gsize did_write = 0, this_time; + + do + { + status = channel->funcs->io_write (channel, channel->write_buf->str + + did_write, channel->write_buf->len + - did_write, &this_time, error); + did_write += this_time; + } + while (status == G_IO_STATUS_NORMAL && + did_write < MIN (channel->write_buf->len, MAX_CHAR_SIZE)); + + g_string_erase (channel->write_buf, 0, did_write); + + if (status != G_IO_STATUS_NORMAL) + { + if (status == G_IO_STATUS_AGAIN && wrote_bytes > 0) + status = G_IO_STATUS_NORMAL; + if (bytes_written) + *bytes_written = wrote_bytes; + return status; + } + } + + space_in_buf = MAX (channel->buf_size, channel->write_buf->allocated_len - 1) + - channel->write_buf->len; /* 1 for NULL */ + + /* This is only true because g_io_channel_set_buffer_size () + * ensures that channel->buf_size >= MAX_CHAR_SIZE. + */ + g_assert (space_in_buf >= MAX_CHAR_SIZE); + + if (!channel->encoding) + { + gssize write_this = MIN (space_in_buf, count - wrote_bytes); + + g_string_append_len (channel->write_buf, buf, write_this); + buf += write_this; + wrote_bytes += write_this; + } + else + { + const gchar *from_buf; + gsize from_buf_len, from_buf_old_len, left_len; + size_t err; + gint errnum; + + if (channel->partial_write_buf[0] != '\0') + { + g_assert (wrote_bytes == 0); + + from_buf = channel->partial_write_buf; + from_buf_old_len = strlen (channel->partial_write_buf); + g_assert (from_buf_old_len > 0); + from_buf_len = MIN (6, from_buf_old_len + count); + + memcpy (channel->partial_write_buf + from_buf_old_len, buf, + from_buf_len - from_buf_old_len); + } + else + { + from_buf = buf; + from_buf_len = count - wrote_bytes; + from_buf_old_len = 0; + } + +reconvert: + + if (!channel->do_encode) /* UTF-8 encoding */ + { + const gchar *badchar; + gsize try_len = MIN (from_buf_len, space_in_buf); + + /* UTF-8, just validate, emulate g_iconv */ + + if (!g_utf8_validate (from_buf, try_len, &badchar)) + { + gunichar try_char; + + left_len = from_buf + try_len - badchar; + + try_char = g_utf8_get_char_validated (badchar, left_len); + + switch (try_char) + { + case -2: + g_assert (left_len < 6); + if (try_len == from_buf_len) + { + errnum = EINVAL; + err = (size_t) -1; + } + else + { + errnum = 0; + err = (size_t) -1; + } + break; + case -1: + g_warning ("Invalid UTF-8 passed to g_io_channel_write_chars()."); + /* FIXME bail here? */ + errnum = EILSEQ; + err = (size_t) -1; + break; + default: + g_assert_not_reached (); + err = (size_t) -1; + errnum = 0; /* Don't confunse the compiler */ + } + } + else + { + err = (size_t) 0; + errnum = 0; + left_len = 0; + } + + g_string_append_len (channel->write_buf, from_buf, + try_len - left_len); + from_buf += try_len - left_len; + } + else + { + gchar *outbuf; + + left_len = from_buf_len; + g_string_set_size (channel->write_buf, channel->write_buf->len + + space_in_buf); + outbuf = channel->write_buf->str + channel->write_buf->len + - space_in_buf; + err = g_iconv (channel->write_cd, (gchar **) &from_buf, &left_len, + &outbuf, &space_in_buf); + errnum = errno; + g_string_truncate (channel->write_buf, channel->write_buf->len + - space_in_buf); + } + + if (err == (size_t) -1) + { + switch (errnum) + { + case EINVAL: + g_assert (left_len < 6); + + if (from_buf_old_len == 0) + { + /* Not from partial_write_buf */ + + memcpy (channel->partial_write_buf, from_buf, left_len); + channel->partial_write_buf[left_len] = '\0'; + if (bytes_written) + *bytes_written = count; + return G_IO_STATUS_NORMAL; + } + + /* Working in partial_write_buf */ + + if (left_len == from_buf_len) + { + /* Didn't convert anything, must still have + * less than a full character + */ + + g_assert (count == from_buf_len - from_buf_old_len); + + channel->partial_write_buf[from_buf_len] = '\0'; + + if (bytes_written) + *bytes_written = count; + + return G_IO_STATUS_NORMAL; + } + + g_assert (from_buf_len - left_len >= from_buf_old_len); + + /* We converted all the old data. This is fine */ + + break; + case E2BIG: + if (from_buf_len == left_len) + { + /* Nothing was written, add enough space for + * at least one character. + */ + space_in_buf += MAX_CHAR_SIZE; + goto reconvert; + } + break; + case EILSEQ: + g_set_error (error, G_CONVERT_ERROR, + G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid byte sequence in conversion input")); + if (from_buf_old_len > 0 && from_buf_len == left_len) + g_warning ("Illegal sequence due to partial character " + "at the end of a previous write.\n"); + else + wrote_bytes += from_buf_len - left_len - from_buf_old_len; + if (bytes_written) + *bytes_written = wrote_bytes; + channel->partial_write_buf[0] = '\0'; + return G_IO_STATUS_ERROR; + default: + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_FAILED, + _("Error during conversion: %s"), strerror (errnum)); + if (from_buf_len >= left_len + from_buf_old_len) + wrote_bytes += from_buf_len - left_len - from_buf_old_len; + if (bytes_written) + *bytes_written = wrote_bytes; + channel->partial_write_buf[0] = '\0'; + return G_IO_STATUS_ERROR; + } + } + + g_assert (from_buf_len - left_len >= from_buf_old_len); + + wrote_bytes += from_buf_len - left_len - from_buf_old_len; + + if (from_buf_old_len > 0) + { + /* We were working in partial_write_buf */ + + buf += from_buf_len - left_len - from_buf_old_len; + channel->partial_write_buf[0] = '\0'; + } + else + buf = from_buf; + } + } + + if (bytes_written) + *bytes_written = count; + + return G_IO_STATUS_NORMAL; +} + +/** + * g_io_channel_write_unichar: + * @channel: a #GIOChannel + * @thechar: a character + * @error: A location to return an error of type #GConvertError + * or #GIOChannelError + * + * This function cannot be called on a channel with %NULL encoding. + * + * Return value: a #GIOStatus + **/ +GIOStatus +g_io_channel_write_unichar (GIOChannel *channel, + gunichar thechar, + GError **error) +{ + GIOStatus status; + gchar static_buf[6]; + gsize char_len, wrote_len; + + g_return_val_if_fail (channel != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail (channel->encoding != NULL, G_IO_STATUS_ERROR); + g_return_val_if_fail ((error == NULL) || (*error == NULL), + G_IO_STATUS_ERROR); + g_return_val_if_fail (channel->is_writeable, G_IO_STATUS_ERROR); + + char_len = g_unichar_to_utf8 (thechar, static_buf); + + if (channel->partial_write_buf[0] != '\0') + { + g_warning ("Partial charater written before writing unichar.\n"); + channel->partial_write_buf[0] = '\0'; + } + + status = g_io_channel_write_chars (channel, static_buf, + char_len, &wrote_len, error); + + /* We validate UTF-8, so we can't get a partial write */ + + g_assert (wrote_len == char_len || status != G_IO_STATUS_NORMAL); + + return status; +} + +/** + * g_io_channel_error_quark: + * + * Return value: The quark used as %G_IO_CHANNEL_ERROR + **/ +GQuark +g_io_channel_error_quark (void) +{ + static GQuark q = 0; + if (q == 0) + q = g_quark_from_static_string ("g-io-channel-error-quark"); + + return q; +} diff --git a/graf2d/win32gdk/gdk/src/glib/giochannel.h b/graf2d/win32gdk/gdk/src/glib/giochannel.h index cf9f11526c2c3..1ff325b5b3ab2 100644 --- a/graf2d/win32gdk/gdk/src/glib/giochannel.h +++ b/graf2d/win32gdk/gdk/src/glib/giochannel.h @@ -27,8 +27,9 @@ #ifndef __G_IOCHANNEL_H__ #define __G_IOCHANNEL_H__ -#include <gmain.h> -#include <g_types.h> +#include <glib/gconvert.h> +#include <glib/gmain.h> +#include <glib/gstring.h> G_BEGIN_DECLS @@ -37,6 +38,7 @@ G_BEGIN_DECLS typedef struct _GIOChannel GIOChannel; typedef struct _GIOFuncs GIOFuncs; + typedef enum { G_IO_ERROR_NONE, @@ -44,12 +46,39 @@ typedef enum G_IO_ERROR_INVAL, G_IO_ERROR_UNKNOWN } GIOError; + +#define G_IO_CHANNEL_ERROR g_io_channel_error_quark() + +typedef enum +{ + /* Derived from errno */ + G_IO_CHANNEL_ERROR_FBIG, + G_IO_CHANNEL_ERROR_INVAL, + G_IO_CHANNEL_ERROR_IO, + G_IO_CHANNEL_ERROR_ISDIR, + G_IO_CHANNEL_ERROR_NOSPC, + G_IO_CHANNEL_ERROR_NXIO, + G_IO_CHANNEL_ERROR_OVERFLOW, + G_IO_CHANNEL_ERROR_PIPE, + /* Other */ + G_IO_CHANNEL_ERROR_FAILED +} GIOChannelError; + +typedef enum +{ + G_IO_STATUS_ERROR, + G_IO_STATUS_NORMAL, + G_IO_STATUS_EOF, + G_IO_STATUS_AGAIN +} GIOStatus; + typedef enum { G_SEEK_CUR, G_SEEK_SET, G_SEEK_END } GSeekType; + typedef enum { G_IO_IN GLIB_SYSDEF_POLLIN, @@ -60,11 +89,44 @@ typedef enum G_IO_NVAL GLIB_SYSDEF_POLLNVAL } GIOCondition; +typedef enum +{ + G_IO_FLAG_APPEND = 1 << 0, + G_IO_FLAG_NONBLOCK = 1 << 1, + G_IO_FLAG_IS_READABLE = 1 << 2, /* Read only flag */ + G_IO_FLAG_IS_WRITEABLE = 1 << 3, /* Read only flag */ + G_IO_FLAG_IS_SEEKABLE = 1 << 4, /* Read only flag */ + G_IO_FLAG_MASK = (1 << 5) - 1, + G_IO_FLAG_GET_MASK = G_IO_FLAG_MASK, + G_IO_FLAG_SET_MASK = G_IO_FLAG_APPEND | G_IO_FLAG_NONBLOCK +} GIOFlags; + struct _GIOChannel { - guint channel_flags; + /*< private >*/ guint ref_count; GIOFuncs *funcs; + + gchar *encoding; + GIConv read_cd; + GIConv write_cd; + gchar *line_term; /* String which indicates the end of a line of text */ + guint line_term_len; /* So we can have null in the line term */ + + gsize buf_size; + GString *read_buf; /* Raw data from the channel */ + GString *encoded_read_buf; /* Channel data converted to UTF-8 */ + GString *write_buf; /* Data ready to be written to the file */ + gchar partial_write_buf[6]; /* UTF-8 partial characters, null terminated */ + + /* Group the flags together, immediately after partial_write_buf, to save memory */ + + guint use_buffer : 1; /* The encoding uses the buffers */ + guint do_encode : 1; /* The encoding uses the GIConv coverters */ + guint close_on_unref : 1; /* Close the channel on final unref */ + guint is_readable : 1; /* Cached GIOFlag */ + guint is_writeable : 1; /* ditto */ + guint is_seekable : 1; /* ditto */ }; typedef gboolean (*GIOFunc) (GIOChannel *source, @@ -72,66 +134,163 @@ typedef gboolean (*GIOFunc) (GIOChannel *source, gpointer data); struct _GIOFuncs { - GIOError (*io_read) (GIOChannel *channel, - gchar *buf, - guint count, - guint *bytes_read); - GIOError (*io_write) (GIOChannel *channel, - gchar *buf, - guint count, - guint *bytes_written); - GIOError (*io_seek) (GIOChannel *channel, - gint offset, - GSeekType type); - void (*io_close) (GIOChannel *channel); - GSource * (*io_create_watch) (GIOChannel *channel, - GIOCondition condition); - void (*io_free) (GIOChannel *channel); + GIOStatus (*io_read) (GIOChannel *channel, + gchar *buf, + gsize count, + gsize *bytes_read, + GError **err); + GIOStatus (*io_write) (GIOChannel *channel, + const gchar *buf, + gsize count, + gsize *bytes_written, + GError **err); + GIOStatus (*io_seek) (GIOChannel *channel, + glong offset, + GSeekType type, + GError **err); + GIOStatus (*io_close) (GIOChannel *channel, + GError **err); + GSource* (*io_create_watch) (GIOChannel *channel, + GIOCondition condition); + void (*io_free) (GIOChannel *channel); + GIOStatus (*io_set_flags) (GIOChannel *channel, + GIOFlags flags, + GError **err); + GIOFlags (*io_get_flags) (GIOChannel *channel); }; void g_io_channel_init (GIOChannel *channel); void g_io_channel_ref (GIOChannel *channel); void g_io_channel_unref (GIOChannel *channel); + +#ifndef G_DISABLE_DEPRECATED GIOError g_io_channel_read (GIOChannel *channel, gchar *buf, - guint count, - guint *bytes_read); + gsize count, + gsize *bytes_read); GIOError g_io_channel_write (GIOChannel *channel, - gchar *buf, - guint count, - guint *bytes_written); + const gchar *buf, + gsize count, + gsize *bytes_written); GIOError g_io_channel_seek (GIOChannel *channel, - gint offset, + glong offset, GSeekType type); void g_io_channel_close (GIOChannel *channel); -guint g_io_add_watch_full (GIOChannel *channel, - gint priority, - GIOCondition condition, - GIOFunc func, - gpointer user_data, - GDestroyNotify notify); -GSource *g_io_create_watch (GIOChannel *channel, - GIOCondition condition); -guint g_io_add_watch (GIOChannel *channel, - GIOCondition condition, - GIOFunc func, - gpointer user_data); +#endif /* G_DISABLE_DEPRECATED */ + +GIOStatus g_io_channel_shutdown (GIOChannel *channel, + gboolean flush, + GError **err); +guint g_io_add_watch_full (GIOChannel *channel, + gint priority, + GIOCondition condition, + GIOFunc func, + gpointer user_data, + GDestroyNotify notify); +GSource * g_io_create_watch (GIOChannel *channel, + GIOCondition condition); +guint g_io_add_watch (GIOChannel *channel, + GIOCondition condition, + GIOFunc func, + gpointer user_data); + +/* character encoding conversion involved functions. + */ + +void g_io_channel_set_buffer_size (GIOChannel *channel, + gsize size); +gsize g_io_channel_get_buffer_size (GIOChannel *channel); +GIOCondition g_io_channel_get_buffer_condition (GIOChannel *channel); +GIOStatus g_io_channel_set_flags (GIOChannel *channel, + GIOFlags flags, + GError **error); +GIOFlags g_io_channel_get_flags (GIOChannel *channel); +void g_io_channel_set_line_term (GIOChannel *channel, + const gchar *line_term, + gint length); +G_CONST_RETURN gchar* g_io_channel_get_line_term (GIOChannel *channel, + gint *length); +void g_io_channel_set_buffered (GIOChannel *channel, + gboolean buffered); +gboolean g_io_channel_get_buffered (GIOChannel *channel); +GIOStatus g_io_channel_set_encoding (GIOChannel *channel, + const gchar *encoding, + GError **error); +G_CONST_RETURN gchar* g_io_channel_get_encoding (GIOChannel *channel); +void g_io_channel_set_close_on_unref (GIOChannel *channel, + gboolean do_close); +gboolean g_io_channel_get_close_on_unref (GIOChannel *channel); + + +GIOStatus g_io_channel_flush (GIOChannel *channel, + GError **error); +GIOStatus g_io_channel_read_line (GIOChannel *channel, + gchar **str_return, + gsize *length, + gsize *terminator_pos, + GError **error); +GIOStatus g_io_channel_read_line_string (GIOChannel *channel, + GString *buffer, + gsize *terminator_pos, + GError **error); +GIOStatus g_io_channel_read_to_end (GIOChannel *channel, + gchar **str_return, + gsize *length, + GError **error); +GIOStatus g_io_channel_read_chars (GIOChannel *channel, + gchar *buf, + gsize count, + gsize *bytes_read, + GError **error); +GIOStatus g_io_channel_read_unichar (GIOChannel *channel, + gunichar *thechar, + GError **error); +GIOStatus g_io_channel_write_chars (GIOChannel *channel, + const gchar *buf, + gssize count, + gsize *bytes_written, + GError **error); +GIOStatus g_io_channel_write_unichar (GIOChannel *channel, + gunichar thechar, + GError **error); +GIOStatus g_io_channel_seek_position (GIOChannel *channel, + glong offset, + GSeekType type, + GError **error); +GIOChannel* g_io_channel_new_file (const gchar *filename, + const gchar *mode, + GError **error); + +/* Error handling */ + +GQuark g_io_channel_error_quark (void); +GIOChannelError g_io_channel_error_from_errno (gint en); /* On Unix, IO channels created with this function for any file * descriptor or socket. * - * On Win32, use this only for files opened with the MSVCRT (the - * Microsoft run-time C library) _open() or _pipe, including file - * descriptors 0, 1 and 2 (corresponding to stdin, stdout and stderr). + * On Win32, this can be used either for files opened with the MSVCRT + * (the Microsoft run-time C library) _open() or _pipe, including file + * descriptors 0, 1 and 2 (corresponding to stdin, stdout and stderr), + * or for Winsock SOCKETs. If the parameter is a legal file + * descriptor, it is assumed to be such, otherwise it should be a + * SOCKET. This relies on SOCKETs and file descriptors not + * overlapping. If you want to be certain, call either + * g_io_channel_win32_new_fd() or g_io_channel_win32_new_socket() + * instead as appropriate. * * The term file descriptor as used in the context of Win32 refers to * the emulated Unix-like file descriptors MSVCRT provides. The native * corresponding concept is file HANDLE. There isn't as of yet a way to - * get GIOChannels for file HANDLEs. + * get GIOChannels for Win32 file HANDLEs. */ GIOChannel* g_io_channel_unix_new (int fd); gint g_io_channel_unix_get_fd (GIOChannel *channel); + +/* Hook for GClosure / GSource integration. Don't touch */ +GLIB_VAR GSourceFuncs g_io_watch_funcs; + #ifdef G_OS_WIN32 #define G_WIN32_MSG_HANDLE 19981206 @@ -139,7 +298,8 @@ gint g_io_channel_unix_get_fd (GIOChannel *channel); /* Use this to get a GPollFD from a GIOChannel, so that you can call * g_io_channel_win32_poll(). After calling this you should only use * g_io_channel_read() to read from the GIOChannel, i.e. never read() - * or recv() from the underlying file descriptor or SOCKET. + * from the underlying file descriptor. For SOCKETs, it is possible to call + * recv(). */ void g_io_channel_win32_make_pollfd (GIOChannel *channel, GIOCondition condition, @@ -147,7 +307,6 @@ void g_io_channel_win32_make_pollfd (GIOChannel *channel, /* This can be used to wait a until at least one of the channels is readable. * On Unix you would do a select() on the file descriptors of the channels. - * This should probably be available for all platforms? */ gint g_io_channel_win32_poll (GPollFD *fds, gint n_fds, @@ -160,25 +319,29 @@ void g_main_poll_win32_msg_add (gint priority, GPollFD *fd, guint hwnd); -/* An IO channel for Windows messages for window handle hwnd. */ +/* Create an IO channel for Windows messages for window handle hwnd. */ GIOChannel *g_io_channel_win32_new_messages (guint hwnd); -/* An IO channel for C runtime (emulated Unix-like) file - * descriptors. Identical to g_io_channel_unix_new above. - * After calling g_io_add_watch() on a IO channel returned - * by this function, you shouldn't call read() on the file - * descriptor. +/* Create an IO channel for C runtime (emulated Unix-like) file + * descriptors. After calling g_io_add_watch() on a IO channel + * returned by this function, you shouldn't call read() on the file + * descriptor. This is because adding polling for a file descriptor is + * implemented on Win32 by starting a thread that sits blocked in a + * read() from the file descriptor most of the time. All reads from + * the file descriptor should be done by this internal GLib + * thread. Your code should call only g_io_channel_read(). */ -GIOChannel* g_io_channel_win32_new_fd (int fd); +GIOChannel* g_io_channel_win32_new_fd (gint fd); /* Get the C runtime file descriptor of a channel. */ gint g_io_channel_win32_get_fd (GIOChannel *channel); -/* An IO channel for a SOCK_STREAM winsock socket. The parameter - * should be a SOCKET. After calling g_io_add_watch() on a IO channel - * returned by this function, you shouldn't call recv() on the SOCKET. +/* Create an IO channel for a winsock socket. The parameter should be + * a SOCKET. Contrary to IO channels for file descriptors (on *Win32), + * you can use normal recv() or recvfrom() on sockets even if GLib + * is polling them. */ -GIOChannel *g_io_channel_win32_new_stream_socket (int socket); +GIOChannel *g_io_channel_win32_new_socket (gint socket); #endif diff --git a/graf2d/win32gdk/gdk/src/glib/giounix.c b/graf2d/win32gdk/gdk/src/glib/giounix.c new file mode 100644 index 0000000000000..c2db911a87496 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/giounix.c @@ -0,0 +1,583 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * giounix.c: IO Channels using unix file descriptors + * Copyright 1998 Owen Taylor + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#include "glib.h" +#include <sys/types.h> +#include <sys/stat.h> +#include <stdio.h> +#include <unistd.h> +#include <errno.h> +#include <string.h> +#include <fcntl.h> + +/* + * Unix IO Channels + */ + +typedef struct _GIOUnixChannel GIOUnixChannel; +typedef struct _GIOUnixWatch GIOUnixWatch; + +struct _GIOUnixChannel +{ + GIOChannel channel; + gint fd; +}; + +struct _GIOUnixWatch +{ + GSource source; + GPollFD pollfd; + GIOChannel *channel; + GIOCondition condition; + GIOFunc callback; +}; + + +static GIOStatus g_io_unix_read (GIOChannel *channel, + gchar *buf, + gsize count, + gsize *bytes_read, + GError **err); +static GIOStatus g_io_unix_write (GIOChannel *channel, + const gchar *buf, + gsize count, + gsize *bytes_written, + GError **err); +static GIOStatus g_io_unix_seek (GIOChannel *channel, + glong offset, + GSeekType type, + GError **err); +static GIOStatus g_io_unix_close (GIOChannel *channel, + GError **err); +static void g_io_unix_free (GIOChannel *channel); +static GSource* g_io_unix_create_watch (GIOChannel *channel, + GIOCondition condition); +static GIOStatus g_io_unix_set_flags (GIOChannel *channel, + GIOFlags flags, + GError **err); +static GIOFlags g_io_unix_get_flags (GIOChannel *channel); + +static gboolean g_io_unix_prepare (GSource *source, + gint *timeout); +static gboolean g_io_unix_check (GSource *source); +static gboolean g_io_unix_dispatch (GSource *source, + GSourceFunc callback, + gpointer user_data); +static void g_io_unix_finalize (GSource *source); + +GSourceFuncs g_io_watch_funcs = { + g_io_unix_prepare, + g_io_unix_check, + g_io_unix_dispatch, + g_io_unix_finalize +}; + +static GIOFuncs unix_channel_funcs = { + g_io_unix_read, + g_io_unix_write, + g_io_unix_seek, + g_io_unix_close, + g_io_unix_create_watch, + g_io_unix_free, + g_io_unix_set_flags, + g_io_unix_get_flags, +}; + +static gboolean +g_io_unix_prepare (GSource *source, + gint *timeout) +{ + GIOUnixWatch *watch = (GIOUnixWatch *)source; + GIOCondition buffer_condition = g_io_channel_get_buffer_condition (watch->channel); + + *timeout = -1; + + /* Only return TRUE here if _all_ bits in watch->condition will be set + */ + return ((watch->condition & buffer_condition) == watch->condition); +} + +static gboolean +g_io_unix_check (GSource *source) +{ + GIOUnixWatch *watch = (GIOUnixWatch *)source; + GIOCondition buffer_condition = g_io_channel_get_buffer_condition (watch->channel); + GIOCondition poll_condition = watch->pollfd.revents; + + return ((poll_condition | buffer_condition) & watch->condition); +} + +static gboolean +g_io_unix_dispatch (GSource *source, + GSourceFunc callback, + gpointer user_data) + +{ + GIOFunc func = (GIOFunc)callback; + GIOUnixWatch *watch = (GIOUnixWatch *)source; + GIOCondition buffer_condition = g_io_channel_get_buffer_condition (watch->channel); + + if (!func) + { + g_warning ("IO watch dispatched without callback\n" + "You must call g_source_connect()."); + return FALSE; + } + + return (*func) (watch->channel, + (watch->pollfd.revents | buffer_condition) & watch->condition, + user_data); +} + +static void +g_io_unix_finalize (GSource *source) +{ + GIOUnixWatch *watch = (GIOUnixWatch *)source; + + g_io_channel_unref (watch->channel); +} + +static GIOStatus +g_io_unix_read (GIOChannel *channel, + gchar *buf, + gsize count, + gsize *bytes_read, + GError **err) +{ + GIOUnixChannel *unix_channel = (GIOUnixChannel *)channel; + gssize result; + + if (count > SSIZE_MAX) /* At least according to the Debian manpage for read */ + count = SSIZE_MAX; + + retry: + result = read (unix_channel->fd, buf, count); + + if (result < 0) + { + *bytes_read = 0; + + switch (errno) + { +#ifdef EINTR + case EINTR: + goto retry; +#endif +#ifdef EAGAIN + case EAGAIN: + return G_IO_STATUS_AGAIN; +#endif + default: + g_set_error (err, G_IO_CHANNEL_ERROR, + g_io_channel_error_from_errno (errno), + strerror (errno)); + return G_IO_STATUS_ERROR; + } + } + + *bytes_read = result; + + return (result > 0) ? G_IO_STATUS_NORMAL : G_IO_STATUS_EOF; +} + +static GIOStatus +g_io_unix_write (GIOChannel *channel, + const gchar *buf, + gsize count, + gsize *bytes_written, + GError **err) +{ + GIOUnixChannel *unix_channel = (GIOUnixChannel *)channel; + gssize result; + + retry: + result = write (unix_channel->fd, buf, count); + + if (result < 0) + { + *bytes_written = 0; + + switch (errno) + { +#ifdef EINTR + case EINTR: + goto retry; +#endif +#ifdef EAGAIN + case EAGAIN: + return G_IO_STATUS_AGAIN; +#endif + default: + g_set_error (err, G_IO_CHANNEL_ERROR, + g_io_channel_error_from_errno (errno), + strerror (errno)); + return G_IO_STATUS_ERROR; + } + } + + *bytes_written = result; + + return G_IO_STATUS_NORMAL; +} + +static GIOStatus +g_io_unix_seek (GIOChannel *channel, + glong offset, + GSeekType type, + GError **err) +{ + GIOUnixChannel *unix_channel = (GIOUnixChannel *)channel; + int whence; + off_t result; + + switch (type) + { + case G_SEEK_SET: + whence = SEEK_SET; + break; + case G_SEEK_CUR: + whence = SEEK_CUR; + break; + case G_SEEK_END: + whence = SEEK_END; + break; + default: + whence = -1; /* Shut the compiler up */ + g_assert_not_reached (); + } + + result = lseek (unix_channel->fd, offset, whence); + + if (result < 0) + { + g_set_error (err, G_IO_CHANNEL_ERROR, + g_io_channel_error_from_errno (errno), + strerror (errno)); + return G_IO_STATUS_ERROR; + } + + return G_IO_STATUS_NORMAL; +} + + +static GIOStatus +g_io_unix_close (GIOChannel *channel, + GError **err) +{ + GIOUnixChannel *unix_channel = (GIOUnixChannel *)channel; + + if (close (unix_channel->fd) < 0) + { + g_set_error (err, G_IO_CHANNEL_ERROR, + g_io_channel_error_from_errno (errno), + strerror (errno)); + return G_IO_STATUS_ERROR; + } + + return G_IO_STATUS_NORMAL; +} + +static void +g_io_unix_free (GIOChannel *channel) +{ + GIOUnixChannel *unix_channel = (GIOUnixChannel *)channel; + + g_free (unix_channel); +} + +static GSource * +g_io_unix_create_watch (GIOChannel *channel, + GIOCondition condition) +{ + GIOUnixChannel *unix_channel = (GIOUnixChannel *)channel; + GSource *source; + GIOUnixWatch *watch; + + + source = g_source_new (&g_io_watch_funcs, sizeof (GIOUnixWatch)); + watch = (GIOUnixWatch *)source; + + watch->channel = channel; + g_io_channel_ref (channel); + + watch->condition = condition; + + watch->pollfd.fd = unix_channel->fd; + watch->pollfd.events = condition; + + g_source_add_poll (source, &watch->pollfd); + + return source; +} + +static GIOStatus +g_io_unix_set_flags (GIOChannel *channel, + GIOFlags flags, + GError **err) +{ + glong fcntl_flags; + GIOUnixChannel *unix_channel = (GIOUnixChannel *) channel; + + fcntl_flags = 0; + + if (flags & G_IO_FLAG_APPEND) + fcntl_flags |= O_APPEND; + if (flags & G_IO_FLAG_NONBLOCK) +#ifdef O_NONBLOCK + fcntl_flags |= O_NONBLOCK; +#else + fcntl_flags |= O_NDELAY; +#endif + + if (fcntl (unix_channel->fd, F_SETFL, fcntl_flags) == -1) + { + g_set_error (err, G_IO_CHANNEL_ERROR, + g_io_channel_error_from_errno (errno), + g_strerror (errno)); + return G_IO_STATUS_ERROR; + } + + return G_IO_STATUS_NORMAL; +} + +static GIOFlags +g_io_unix_get_flags (GIOChannel *channel) +{ + GIOFlags flags = 0; + glong fcntl_flags; + GIOUnixChannel *unix_channel = (GIOUnixChannel *) channel; + + fcntl_flags = fcntl (unix_channel->fd, F_GETFL); + + if (fcntl_flags == -1) + { + g_warning (G_STRLOC "Error while getting flags for FD: %s (%d)\n", + g_strerror (errno), errno); + return 0; + } + + if (fcntl_flags & O_APPEND) + flags |= G_IO_FLAG_APPEND; +#ifdef O_NONBLOCK + if (fcntl_flags & O_NONBLOCK) +#else + if (fcntl_flags & O_NDELAY) +#endif + flags |= G_IO_FLAG_NONBLOCK; + + switch (fcntl_flags & (O_RDONLY | O_WRONLY | O_RDWR)) + { + case O_RDONLY: + channel->is_readable = TRUE; + channel->is_writeable = FALSE; + break; + case O_WRONLY: + channel->is_readable = FALSE; + channel->is_writeable = TRUE; + break; + case O_RDWR: + channel->is_readable = TRUE; + channel->is_writeable = TRUE; + break; + default: + g_assert_not_reached (); + } + + return flags; +} + +GIOChannel * +g_io_channel_new_file (const gchar *filename, + const gchar *mode, + GError **error) +{ + int fid, flags; + mode_t create_mode; + GIOChannel *channel; + enum { /* Cheesy hack */ + MODE_R = 1 << 0, + MODE_W = 1 << 1, + MODE_A = 1 << 2, + MODE_PLUS = 1 << 3, + } mode_num; + struct stat buffer; + + g_return_val_if_fail (filename != NULL, NULL); + g_return_val_if_fail (mode != NULL, NULL); + g_return_val_if_fail ((error == NULL) || (*error == NULL), NULL); + + switch (mode[0]) + { + case 'r': + mode_num = MODE_R; + break; + case 'w': + mode_num = MODE_W; + break; + case 'a': + mode_num = MODE_A; + break; + default: + g_warning ("Invalid GIOFileMode %s.\n", mode); + return NULL; + } + + switch (mode[1]) + { + case '\0': + break; + case '+': + if (mode[2] == '\0') + { + mode_num |= MODE_PLUS; + break; + } + /* Fall through */ + default: + g_warning ("Invalid GIOFileMode %s.\n", mode); + return NULL; + } + + switch (mode_num) + { + case MODE_R: + flags = O_RDONLY; + break; + case MODE_W: + flags = O_WRONLY | O_TRUNC | O_CREAT; + break; + case MODE_A: + flags = O_WRONLY | O_APPEND | O_CREAT; + break; + case MODE_R | MODE_PLUS: + flags = O_RDWR; + break; + case MODE_W | MODE_PLUS: + flags = O_RDWR | O_TRUNC | O_CREAT; + break; + case MODE_A | MODE_PLUS: + flags = O_RDWR | O_APPEND | O_CREAT; + break; + default: + g_assert_not_reached (); + flags = 0; + } + + create_mode = S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH; + fid = open (filename, flags, create_mode); + if (fid == -1) + { + g_set_error (error, G_FILE_ERROR, + g_file_error_from_errno (errno), + strerror (errno)); + return (GIOChannel *)NULL; + } + + if (fstat (fid, &buffer) == -1) /* In case someone opens a FIFO */ + { + close (fid); + g_set_error (error, G_FILE_ERROR, + g_file_error_from_errno (errno), + strerror (errno)); + return (GIOChannel *)NULL; + } + + channel = (GIOChannel *) g_new (GIOUnixChannel, 1); + + channel->is_seekable = S_ISREG (buffer.st_mode) || S_ISCHR (buffer.st_mode) + || S_ISBLK (buffer.st_mode); + + switch (mode_num) + { + case MODE_R: + channel->is_readable = TRUE; + channel->is_writeable = FALSE; + break; + case MODE_W: + case MODE_A: + channel->is_readable = FALSE; + channel->is_writeable = TRUE; + break; + case MODE_R | MODE_PLUS: + case MODE_W | MODE_PLUS: + case MODE_A | MODE_PLUS: + channel->is_readable = TRUE; + channel->is_writeable = TRUE; + break; + default: + g_assert_not_reached (); + } + + g_io_channel_init (channel); + channel->close_on_unref = TRUE; /* must be after g_io_channel_init () */ + channel->funcs = &unix_channel_funcs; + + ((GIOUnixChannel *) channel)->fd = fid; + return channel; +} + +GIOChannel * +g_io_channel_unix_new (gint fd) +{ + struct stat buffer; + GIOUnixChannel *unix_channel = g_new (GIOUnixChannel, 1); + GIOChannel *channel = (GIOChannel *)unix_channel; + + g_io_channel_init (channel); + channel->funcs = &unix_channel_funcs; + + /* I'm not sure if fstat on a non-file (e.g., socket) works + * it should be safe to say if it fails, the fd isn't seekable. + */ + /* Newer UNIX versions support S_ISSOCK(), fstat() will probably + * succeed in most cases. + */ + if (fstat (unix_channel->fd, &buffer) == 0) + channel->is_seekable = S_ISREG (buffer.st_mode) || S_ISCHR (buffer.st_mode) + || S_ISBLK (buffer.st_mode); + else /* Assume not seekable */ + channel->is_seekable = FALSE; + + unix_channel->fd = fd; + + g_io_unix_get_flags (channel); /* Sets is_readable, is_writeable */ + + return channel; +} + +gint +g_io_channel_unix_get_fd (GIOChannel *channel) +{ + GIOUnixChannel *unix_channel = (GIOUnixChannel *)channel; + return unix_channel->fd; +} diff --git a/graf2d/win32gdk/gdk/src/glib/giowin32.c b/graf2d/win32gdk/gdk/src/glib/giowin32.c new file mode 100644 index 0000000000000..425e710d43b75 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/giowin32.c @@ -0,0 +1,1463 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * giowin32.c: IO Channels for Win32. + * Copyright 1998 Owen Taylor and Tor Lillqvist + * Copyright 1999-2000 Tor Lillqvist and Craig Setera + * Copyright 2001 Andrew Lanoix + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* Define this to get (very) verbose logging of all channels */ +/* #define G_IO_WIN32_DEBUG */ + +#include "glib.h" + +#include <stdlib.h> +#include <windows.h> +#include <winsock.h> /* Not everybody has winsock2 */ +#include <fcntl.h> +#include <io.h> +#include <process.h> +#include <errno.h> +#include <sys/stat.h> + +#include "glibintl.h" + +typedef struct _GIOWin32Channel GIOWin32Channel; +typedef struct _GIOWin32Watch GIOWin32Watch; + +#define BUFFER_SIZE 4096 + +typedef enum { + G_IO_WIN32_WINDOWS_MESSAGES, /* Windows messages */ + G_IO_WIN32_FILE_DESC, /* Unix-like file descriptors from + * _open() or _pipe(). Read with read(). + * Have to create separate thread to read. + */ + G_IO_WIN32_SOCKET /* Sockets. A separate thread is blocked + * in select() most of the time. + */ +} GIOWin32ChannelType; + +struct _GIOWin32Channel { + GIOChannel channel; + gint fd; /* Either a Unix-like file handle as provided + * by the Microsoft C runtime, or a SOCKET + * as provided by WinSock. + */ + GIOWin32ChannelType type; + + gboolean debug; + + CRITICAL_SECTION mutex; + + /* This is used by G_IO_WIN32_WINDOWS_MESSAGES channels */ + HWND hwnd; /* handle of window, or NULL */ + + /* Following fields are used by both fd and socket channels. */ + gboolean running; /* Is reader thread running. FALSE if + * EOF has been reached. + */ + gboolean needs_close; /* If the channel has been closed while + * the reader thread was still running. + */ + guint thread_id; /* If non-NULL has a reader thread, or has + * had.*/ + HANDLE thread_handle; + HANDLE data_avail_event; + + gushort revents; + + /* Following fields used by fd channels for input */ + + /* Data is kept in a circular buffer. To be able to distinguish between + * empty and full buffer, we cannot fill it completely, but have to + * leave a one character gap. + * + * Data available is between indexes rdp and wrp-1 (modulo BUFFER_SIZE). + * + * Empty: wrp == rdp + * Full: (wrp + 1) % BUFFER_SIZE == rdp + * Partial: otherwise + */ + guchar *buffer; /* (Circular) buffer */ + gint wrp, rdp; /* Buffer indices for writing and reading */ + HANDLE space_avail_event; + + /* Following fields used by socket channels */ + GSList *watches; + HANDLE data_avail_noticed_event; +}; + +#define LOCK(mutex) EnterCriticalSection (&mutex) +#define UNLOCK(mutex) LeaveCriticalSection (&mutex) + +struct _GIOWin32Watch { + GSource source; + GPollFD pollfd; + GIOChannel *channel; + GIOCondition condition; + GIOFunc callback; +}; + +static void +g_io_channel_win32_init (GIOWin32Channel *channel) +{ +#ifdef G_IO_WIN32_DEBUG + channel->debug = TRUE; +#else + if (getenv ("G_IO_WIN32_DEBUG") != NULL) + channel->debug = TRUE; + else + channel->debug = FALSE; +#endif + channel->buffer = NULL; + channel->running = FALSE; + channel->needs_close = FALSE; + channel->thread_id = 0; + channel->data_avail_event = NULL; + channel->revents = 0; + channel->space_avail_event = NULL; + channel->data_avail_noticed_event = NULL; + channel->watches = NULL; + InitializeCriticalSection (&channel->mutex); +} + +static void +create_events (GIOWin32Channel *channel) +{ + SECURITY_ATTRIBUTES sec_attrs; + + sec_attrs.nLength = sizeof(SECURITY_ATTRIBUTES); + sec_attrs.lpSecurityDescriptor = NULL; + sec_attrs.bInheritHandle = FALSE; + + /* The data available event is manual reset, the space available event + * is automatic reset. + */ + if (!(channel->data_avail_event = CreateEvent (&sec_attrs, TRUE, FALSE, NULL)) + || !(channel->space_avail_event = CreateEvent (&sec_attrs, FALSE, FALSE, NULL)) + || !(channel->data_avail_noticed_event = CreateEvent (&sec_attrs, FALSE, FALSE, NULL))) + { + gchar *msg = g_win32_error_message (GetLastError ()); + g_error ("Error creating event: %s", msg); + } +} + +static unsigned __stdcall +read_thread (void *parameter) +{ + GIOWin32Channel *channel = parameter; + guchar *buffer; + guint nbytes; + + g_io_channel_ref ((GIOChannel *)channel); + + if (channel->debug) + g_print ("read_thread %#x: start fd:%d, data_avail:%#x, space_avail:%#x\n", + channel->thread_id, + channel->fd, + (guint) channel->data_avail_event, + (guint) channel->space_avail_event); + + channel->buffer = g_malloc (BUFFER_SIZE); + channel->rdp = channel->wrp = 0; + channel->running = TRUE; + + SetEvent (channel->space_avail_event); + + while (channel->running) + { + LOCK (channel->mutex); + if (channel->debug) + g_print ("read_thread %#x: rdp=%d, wrp=%d\n", + channel->thread_id, channel->rdp, channel->wrp); + if ((channel->wrp + 1) % BUFFER_SIZE == channel->rdp) + { + /* Buffer is full */ + if (channel->debug) + g_print ("read_thread %#x: resetting space_avail\n", + channel->thread_id); + ResetEvent (channel->space_avail_event); + if (channel->debug) + g_print ("read_thread %#x: waiting for space\n", + channel->thread_id); + UNLOCK (channel->mutex); + WaitForSingleObject (channel->space_avail_event, INFINITE); + LOCK (channel->mutex); + if (channel->debug) + g_print ("read_thread %#x: rdp=%d, wrp=%d\n", + channel->thread_id, channel->rdp, channel->wrp); + } + + buffer = channel->buffer + channel->wrp; + + /* Always leave at least one byte unused gap to be able to + * distinguish between the full and empty condition... + */ + nbytes = MIN ((channel->rdp + BUFFER_SIZE - channel->wrp - 1) % BUFFER_SIZE, + BUFFER_SIZE - channel->wrp); + + if (channel->debug) + g_print ("read_thread %#x: calling read() for %d bytes\n", + channel->thread_id, nbytes); + + UNLOCK (channel->mutex); + + nbytes = read (channel->fd, buffer, nbytes); + + LOCK (channel->mutex); + + channel->revents = G_IO_IN; + if (nbytes == 0) + channel->revents |= G_IO_HUP; + else if (nbytes < 0) + channel->revents |= G_IO_ERR; + + if (channel->debug) + g_print ("read_thread %#x: read() returned %d, rdp=%d, wrp=%d\n", + channel->thread_id, nbytes, channel->rdp, channel->wrp); + + if (nbytes <= 0) + break; + + channel->wrp = (channel->wrp + nbytes) % BUFFER_SIZE; + if (channel->debug) + g_print ("read_thread %#x: rdp=%d, wrp=%d, setting data_avail\n", + channel->thread_id, channel->rdp, channel->wrp); + SetEvent (channel->data_avail_event); + UNLOCK (channel->mutex); + } + + channel->running = FALSE; + if (channel->needs_close) + { + if (channel->debug) + g_print ("read_thread %#x: channel fd %d needs closing\n", + channel->thread_id, channel->fd); + close (channel->fd); + channel->fd = -1; + } + + if (channel->debug) + g_print ("read_thread %#x: EOF, rdp=%d, wrp=%d, setting data_avail\n", + channel->thread_id, channel->rdp, channel->wrp); + SetEvent (channel->data_avail_event); + UNLOCK (channel->mutex); + + g_io_channel_unref((GIOChannel *)channel); + + /* No need to call _endthreadex(), the actual thread starter routine + * in MSVCRT (see crt/src/threadex.c:_threadstartex) calls + * _endthreadex() for us. + */ + + CloseHandle (channel->thread_handle); + + return 0; +} + +static void +create_thread (GIOWin32Channel *channel, + GIOCondition condition, + unsigned (__stdcall *thread) (void *parameter)) +{ + channel->thread_handle = + (HANDLE) _beginthreadex (NULL, 0, thread, channel, 0, + &channel->thread_id); + if (channel->thread_handle == 0) + g_warning (G_STRLOC ": Error creating reader thread: %s", + strerror (errno)); + WaitForSingleObject (channel->space_avail_event, INFINITE); +} + +static GIOStatus +buffer_read (GIOWin32Channel *channel, + guchar *dest, + gsize count, + gsize *bytes_read, + GError **err) +{ + guint nbytes; + guint left = count; + + LOCK (channel->mutex); + if (channel->debug) + g_print ("reading from thread %#x %d bytes, rdp=%d, wrp=%d\n", + channel->thread_id, count, channel->rdp, channel->wrp); + + if (channel->wrp == channel->rdp) + { + UNLOCK (channel->mutex); + if (channel->debug) + g_print ("waiting for data from thread %#x\n", channel->thread_id); + WaitForSingleObject (channel->data_avail_event, INFINITE); + if (channel->debug) + g_print ("done waiting for data from thread %#x\n", channel->thread_id); + LOCK (channel->mutex); + if (channel->wrp == channel->rdp && !channel->running) + { + UNLOCK (channel->mutex); + *bytes_read = 0; + return G_IO_STATUS_NORMAL; /* as before, normal case ? */ + } + } + + if (channel->rdp < channel->wrp) + nbytes = channel->wrp - channel->rdp; + else + nbytes = BUFFER_SIZE - channel->rdp; + UNLOCK (channel->mutex); + nbytes = MIN (left, nbytes); + if (channel->debug) + g_print ("moving %d bytes from thread %#x\n", + nbytes, channel->thread_id); + memcpy (dest, channel->buffer + channel->rdp, nbytes); + dest += nbytes; + left -= nbytes; + LOCK (channel->mutex); + channel->rdp = (channel->rdp + nbytes) % BUFFER_SIZE; + if (channel->debug) + g_print ("setting space_avail for thread %#x\n", channel->thread_id); + SetEvent (channel->space_avail_event); + if (channel->debug) + g_print ("for thread %#x: rdp=%d, wrp=%d\n", + channel->thread_id, channel->rdp, channel->wrp); + if (channel->running && channel->wrp == channel->rdp) + { + if (channel->debug) + g_print ("resetting data_avail of thread %#x\n", + channel->thread_id); + ResetEvent (channel->data_avail_event); + }; + UNLOCK (channel->mutex); + + /* We have no way to indicate any errors form the actual + * read() or recv() call in the reader thread. Should we have? + */ + *bytes_read = count - left; + return (*bytes_read > 0) ? G_IO_STATUS_NORMAL : G_IO_STATUS_EOF; +} + +static unsigned __stdcall +select_thread (void *parameter) +{ + GIOWin32Channel *channel = parameter; + fd_set read_fds, write_fds, except_fds; + GSList *tmp; + int n; + + g_io_channel_ref ((GIOChannel *)channel); + + if (channel->debug) + g_print ("select_thread %#x: start fd:%d,\n\tdata_avail:%#x, data_avail_noticed:%#x\n", + channel->thread_id, + channel->fd, + (guint) channel->data_avail_event, + (guint) channel->data_avail_noticed_event); + + channel->rdp = channel->wrp = 0; + channel->running = TRUE; + + SetEvent (channel->space_avail_event); + + while (channel->running) + { + FD_ZERO (&read_fds); + FD_ZERO (&write_fds); + FD_ZERO (&except_fds); + + tmp = channel->watches; + while (tmp) + { + GIOWin32Watch *watch = (GIOWin32Watch *)tmp->data; + + if (watch->condition & (G_IO_IN | G_IO_HUP)) + FD_SET (channel->fd, &read_fds); + if (watch->condition & G_IO_OUT) + FD_SET (channel->fd, &write_fds); + if (watch->condition & G_IO_ERR) + FD_SET (channel->fd, &except_fds); + + tmp = tmp->next; + } + if (channel->debug) + g_print ("select_thread %#x: calling select() for%s%s%s\n", + channel->thread_id, + (FD_ISSET (channel->fd, &read_fds) ? " IN" : ""), + (FD_ISSET (channel->fd, &write_fds) ? " OUT" : ""), + (FD_ISSET (channel->fd, &except_fds) ? " ERR" : "")); + + n = select (1, &read_fds, &write_fds, &except_fds, NULL); + + if (n == SOCKET_ERROR) + { + if (channel->debug) + g_print ("select_thread %#x: select returned SOCKET_ERROR\n", + channel->thread_id); + break; + } + + if (channel->debug) + g_print ("select_thread %#x: got%s%s%s\n", + channel->thread_id, + (FD_ISSET (channel->fd, &read_fds) ? " IN" : ""), + (FD_ISSET (channel->fd, &write_fds) ? " OUT" : ""), + (FD_ISSET (channel->fd, &except_fds) ? " ERR" : "")); + + if (FD_ISSET (channel->fd, &read_fds)) + channel->revents |= G_IO_IN; + if (FD_ISSET (channel->fd, &write_fds)) + channel->revents |= G_IO_OUT; + if (FD_ISSET (channel->fd, &except_fds)) + channel->revents |= G_IO_ERR; + + if (channel->debug) + g_print ("select_thread %#x: resetting data_avail_noticed,\n" + "\tsetting data_avail\n", + channel->thread_id); + ResetEvent (channel->data_avail_noticed_event); + SetEvent (channel->data_avail_event); + + LOCK (channel->mutex); + if (channel->needs_close) + { + UNLOCK (channel->mutex); + break; + } + UNLOCK (channel->mutex); + + if (channel->debug) + g_print ("select_thread %#x: waiting for data_avail_noticed\n", + channel->thread_id); + + WaitForSingleObject (channel->data_avail_noticed_event, INFINITE); + if (channel->debug) + g_print ("select_thread %#x: got data_avail_noticed\n", + channel->thread_id); + } + + channel->running = FALSE; + LOCK (channel->mutex); + if (channel->fd != -1) + { + /* DO NOT close the fd here */ + channel->fd = -1; + } + + if (channel->debug) + g_print ("select_thread %#x: got error, setting data_avail\n", + channel->thread_id); + SetEvent (channel->data_avail_event); + UNLOCK (channel->mutex); + + g_io_channel_unref((GIOChannel *)channel); + + /* No need to call _endthreadex(), the actual thread starter routine + * in MSVCRT (see crt/src/threadex.c:_threadstartex) calls + * _endthreadex() for us. + */ + + CloseHandle (channel->thread_handle); + + return 0; +} + +static gboolean +g_io_win32_prepare (GSource *source, + gint *timeout) +{ + GIOWin32Watch *watch = (GIOWin32Watch *)source; + GIOWin32Channel *channel = (GIOWin32Channel *)watch->channel; + + *timeout = -1; + + if (channel->type == G_IO_WIN32_FILE_DESC) + { + LOCK (channel->mutex); + if (channel->running && channel->wrp == channel->rdp) + channel->revents = 0; + UNLOCK (channel->mutex); + } + else if (channel->type == G_IO_WIN32_SOCKET) + { + channel->revents = 0; + + if (channel->debug) + g_print ("g_io_win32_prepare: thread %#x, setting data_avail_noticed\n", + channel->thread_id); + SetEvent (channel->data_avail_noticed_event); + if (channel->debug) + g_print ("g_io_win32_prepare: thread %#x, there.\n", + channel->thread_id); + } + + return FALSE; + /* XXX: why should we want to do this ? */ + watch->condition = g_io_channel_get_buffer_condition (watch->channel); + + return (watch->pollfd.revents & (G_IO_IN | G_IO_OUT)) == watch->condition; +} + +static gboolean +g_io_win32_check (GSource *source) +{ + MSG msg; + GIOWin32Watch *watch = (GIOWin32Watch *)source; + GIOWin32Channel *channel = (GIOWin32Channel *)watch->channel; + GIOCondition buffer_condition = g_io_channel_get_buffer_condition (watch->channel); + + + if (channel->debug) + g_print ("g_io_win32_check: for thread %#x:\n" + "\twatch->pollfd.events:%#x, watch->pollfd.revents:%#x, channel->revents:%#x\n", + channel->thread_id, + watch->pollfd.events, watch->pollfd.revents, channel->revents); + + if (channel->type != G_IO_WIN32_WINDOWS_MESSAGES) + { + watch->pollfd.revents = (watch->pollfd.events & channel->revents); + } + else + { + return (PeekMessage (&msg, channel->hwnd, 0, 0, PM_NOREMOVE)); + } + + if (channel->type == G_IO_WIN32_SOCKET) + { + if (channel->debug) + g_print ("g_io_win32_check: thread %#x, resetting data_avail\n", + channel->thread_id); + ResetEvent (channel->data_avail_event); + if (channel->debug) + g_print ("g_io_win32_check: thread %#x, there.\n", + channel->thread_id); + } + + return (watch->pollfd.revents & watch->condition); +} + +static gboolean +g_io_win32_dispatch (GSource *source, + GSourceFunc callback, + gpointer user_data) +{ + GIOFunc func = (GIOFunc)callback; + GIOWin32Watch *watch = (GIOWin32Watch *)source; + + if (!func) + { + g_warning (G_STRLOC ": GIOWin32Watch dispatched without callback\n" + "You must call g_source_connect()."); + return FALSE; + } + + return (*func) (watch->channel, + watch->pollfd.revents & watch->condition, + user_data); +} + +static void +g_io_win32_finalize (GSource *source) +{ + GIOWin32Watch *watch = (GIOWin32Watch *)source; + GIOWin32Channel *channel = (GIOWin32Channel *)watch->channel; + + if (channel->debug) + g_print ("g_io_win32_finalize: channel with thread %#x\n", + channel->thread_id); + + channel->watches = g_slist_remove (channel->watches, watch); + + SetEvent (channel->data_avail_noticed_event); + g_io_channel_unref (watch->channel); +} + +#if defined(G_PLATFORM_WIN32) && defined(__GNUC__) +__declspec(dllexport) +#endif +GSourceFuncs g_io_watch_funcs = { + g_io_win32_prepare, + g_io_win32_check, + g_io_win32_dispatch, + g_io_win32_finalize +}; + +static GSource * +g_io_win32_create_watch (GIOChannel *channel, + GIOCondition condition, + unsigned (__stdcall *thread) (void *parameter)) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + GIOWin32Watch *watch; + GSource *source; + + source = g_source_new (&g_io_watch_funcs, sizeof (GIOWin32Watch)); + watch = (GIOWin32Watch *)source; + + watch->channel = channel; + g_io_channel_ref (channel); + + watch->condition = condition; + + if (win32_channel->data_avail_event == NULL) + create_events (win32_channel); + + watch->pollfd.fd = (gint) win32_channel->data_avail_event; + watch->pollfd.events = condition; + + if (win32_channel->debug) + g_print ("g_io_win32_create_watch: fd:%d condition:%#x handle:%#x\n", + win32_channel->fd, condition, watch->pollfd.fd); + + win32_channel->watches = g_slist_append (win32_channel->watches, watch); + + if (win32_channel->thread_id == 0) + create_thread (win32_channel, condition, thread); + + g_source_add_poll (source, &watch->pollfd); + + return source; +} + +static GIOStatus +g_io_win32_msg_read (GIOChannel *channel, + gchar *buf, + gsize count, + gsize *bytes_read, + GError **err) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + MSG msg; /* In case of alignment problems */ + + if (count < sizeof (MSG)) + { + g_set_error(err, G_IO_CHANNEL_ERROR, G_IO_CHANNEL_ERROR_INVAL, + _("Incorrect message size")); /* Correct error message? FIXME */ + return G_IO_STATUS_ERROR; + } + + if (win32_channel->debug) + g_print ("g_io_win32_msg_read: for %#x\n", + win32_channel->hwnd); + if (!PeekMessage (&msg, win32_channel->hwnd, 0, 0, PM_REMOVE)) + return G_IO_STATUS_AGAIN; + + memmove (buf, &msg, sizeof (MSG)); + *bytes_read = sizeof (MSG); + + return (*bytes_read > 0) ? G_IO_STATUS_NORMAL : G_IO_STATUS_EOF; +} + +static GIOStatus +g_io_win32_msg_write (GIOChannel *channel, + const gchar *buf, + gsize count, + gsize *bytes_written, + GError **err) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + MSG msg; + + if (count != sizeof (MSG)) + { + g_set_error(err, G_IO_CHANNEL_ERROR, G_IO_CHANNEL_ERROR_INVAL, + _("Incorrect message size")); /* Correct error message? FIXME */ + return G_IO_STATUS_ERROR; + } + + /* In case of alignment problems */ + memmove (&msg, buf, sizeof (MSG)); + if (!PostMessage (win32_channel->hwnd, msg.message, msg.wParam, msg.lParam)) + { + g_set_error(err, G_IO_CHANNEL_ERROR, G_IO_CHANNEL_ERROR_FAILED, + _("Unknown error")); /* Correct error message? FIXME */ + return G_IO_STATUS_ERROR; + } + + *bytes_written = sizeof (MSG); + + return G_IO_STATUS_NORMAL; +} + +static GIOStatus +g_io_win32_no_seek (GIOChannel *channel, + glong offset, + GSeekType type, + GError **err) +{ + g_assert_not_reached (); + + return G_IO_STATUS_ERROR; +} + +static GIOStatus +g_io_win32_msg_close (GIOChannel *channel, + GError **err) +{ + /* Nothing to be done. Or should we set hwnd to some invalid value? */ + + return G_IO_STATUS_NORMAL; +} + +static void +g_io_win32_free (GIOChannel *channel) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + + if (win32_channel->debug) + g_print ("thread %#x: freeing channel, fd: %d\n", + win32_channel->thread_id, + win32_channel->fd); + + if (win32_channel->data_avail_event) + CloseHandle (win32_channel->data_avail_event); + if (win32_channel->space_avail_event) + CloseHandle (win32_channel->space_avail_event); + if (win32_channel->data_avail_noticed_event) + CloseHandle (win32_channel->data_avail_noticed_event); + DeleteCriticalSection (&win32_channel->mutex); + + g_free (win32_channel->buffer); + g_slist_free (win32_channel->watches); + g_free (win32_channel); +} + +static GSource * +g_io_win32_msg_create_watch (GIOChannel *channel, + GIOCondition condition) +{ + GIOWin32Watch *watch; + GSource *source; + + source = g_source_new (&g_io_watch_funcs, sizeof (GIOWin32Watch)); + watch = (GIOWin32Watch *)source; + + watch->channel = channel; + g_io_channel_ref (channel); + + watch->condition = condition; + + watch->pollfd.fd = G_WIN32_MSG_HANDLE; + watch->pollfd.events = condition; + + g_source_add_poll (source, &watch->pollfd); + + return source; +} + +static GIOStatus +g_io_win32_fd_read (GIOChannel *channel, + gchar *buf, + gsize count, + gsize *bytes_read, + GError **err) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + gint result; + + if (win32_channel->debug) + g_print ("g_io_win32_fd_read: fd:%d count:%d\n", + win32_channel->fd, count); + + if (win32_channel->thread_id) + { + return buffer_read (win32_channel, buf, count, bytes_read, err); + } + + result = read (win32_channel->fd, buf, count); + + if (result < 0) + { + *bytes_read = 0; + + switch(errno) + { +#ifdef EAGAIN + case EAGAIN: + return G_IO_STATUS_AGAIN; +#endif + default: + g_set_error (err, G_IO_CHANNEL_ERROR, + g_io_channel_error_from_errno (errno), + strerror (errno)); + return G_IO_STATUS_ERROR; + } + } + + *bytes_read = result; + + return G_IO_STATUS_NORMAL; /* XXX: 0 byte read an error ?? */ + return (result > 0) ? G_IO_STATUS_NORMAL : G_IO_STATUS_EOF; +} + +static GIOStatus +g_io_win32_fd_write (GIOChannel *channel, + const gchar *buf, + gsize count, + gsize *bytes_written, + GError **err) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + gint result; + + result = write (win32_channel->fd, buf, count); + if (win32_channel->debug) + g_print ("g_io_win32_fd_write: fd:%d count:%d = %d\n", + win32_channel->fd, count, result); + + if (result < 0) + { + *bytes_written = 0; + + switch(errno) + { +#ifdef EAGAIN + case EAGAIN: + return G_IO_STATUS_AGAIN; +#endif + default: + g_set_error (err, G_IO_CHANNEL_ERROR, + g_io_channel_error_from_errno (errno), + strerror (errno)); + return G_IO_STATUS_ERROR; + } + } + + *bytes_written = result; + + return G_IO_STATUS_NORMAL; +} + +static GIOStatus +g_io_win32_fd_seek (GIOChannel *channel, + glong offset, + GSeekType type, + GError **err) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + int whence; + off_t result; + + switch (type) + { + case G_SEEK_SET: + whence = SEEK_SET; + break; + case G_SEEK_CUR: + whence = SEEK_CUR; + break; + case G_SEEK_END: + whence = SEEK_END; + break; + default: + whence = -1; /* Keep the compiler quiet */ + g_assert_not_reached(); + } + + result = lseek (win32_channel->fd, offset, whence); + + if (result < 0) + { + g_set_error (err, G_IO_CHANNEL_ERROR, + g_io_channel_error_from_errno (errno), + strerror (errno)); + return G_IO_STATUS_ERROR; + } + + return G_IO_STATUS_NORMAL; +} + +static GIOStatus +g_io_win32_fd_close (GIOChannel *channel, + GError **err) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + + if (win32_channel->debug) + g_print ("thread %#x: closing fd %d\n", + win32_channel->thread_id, + win32_channel->fd); + LOCK (win32_channel->mutex); + if (win32_channel->running) + { + if (win32_channel->debug) + g_print ("thread %#x: running, marking fd %d for later close\n", + win32_channel->thread_id, win32_channel->fd); + win32_channel->running = FALSE; + win32_channel->needs_close = TRUE; + SetEvent (win32_channel->data_avail_event); + } + else + { + if (win32_channel->debug) + g_print ("closing fd %d\n", win32_channel->fd); + close (win32_channel->fd); + if (win32_channel->debug) + g_print ("closed fd %d, setting to -1\n", + win32_channel->fd); + win32_channel->fd = -1; + } + UNLOCK (win32_channel->mutex); + + /* FIXME error detection? */ + + return G_IO_STATUS_NORMAL; +} + +static GSource * +g_io_win32_fd_create_watch (GIOChannel *channel, + GIOCondition condition) +{ + return g_io_win32_create_watch (channel, condition, read_thread); +} + +static GIOStatus +g_io_win32_sock_read (GIOChannel *channel, + gchar *buf, + gsize count, + gsize *bytes_read, + GError **err) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + gint result; + GIOChannelError error; + + if (win32_channel->debug) + g_print ("g_io_win32_sock_read: sockfd:%d count:%d\n", + win32_channel->fd, count); +#ifdef WE_NEED_TO_HANDLE_WSAEINTR /* not anymore with wsock2 ? */ +repeat: +#endif + result = recv (win32_channel->fd, buf, count, 0); + + if (win32_channel->debug) + g_print ("g_io_win32_sock_read: recv:%d\n", result); + + if (result == SOCKET_ERROR) + { + *bytes_read = 0; + + switch (WSAGetLastError ()) + { + case WSAEINVAL: + error = G_IO_CHANNEL_ERROR_INVAL; + break; + case WSAEWOULDBLOCK: + return G_IO_STATUS_AGAIN; +#ifdef WE_NEED_TO_HANDLE_WSAEINTR /* not anymore with wsock2 ? */ + case WSAEINTR: + goto repeat; +#endif + default: + error = G_IO_CHANNEL_ERROR_FAILED; + break; + } + g_set_error(err, G_IO_CHANNEL_ERROR, error, _("Socket error")); + return G_IO_STATUS_ERROR; + /* FIXME get all errors, better error messages */ + } + else + { + *bytes_read = result; + + return G_IO_STATUS_NORMAL; /* XXX: 0 byte read an error ?? */ + return (result > 0) ? G_IO_STATUS_NORMAL : G_IO_STATUS_EOF; + } +} + +static GIOStatus +g_io_win32_sock_write (GIOChannel *channel, + const gchar *buf, + gsize count, + gsize *bytes_written, + GError **err) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + gint result; + GIOChannelError error; + + if (win32_channel->debug) + g_print ("g_io_win32_sock_write: sockfd:%d count:%d\n", + win32_channel->fd, count); +#ifdef WE_NEED_TO_HANDLE_WSAEINTR /* not anymore with wsock2 ? */ +repeat: +#endif + result = send (win32_channel->fd, buf, count, 0); + + if (win32_channel->debug) + g_print ("g_io_win32_sock_write: send:%d\n", result); + + if (result == SOCKET_ERROR) + { + *bytes_written = 0; + + switch (WSAGetLastError ()) + { + case WSAEINVAL: + error = G_IO_CHANNEL_ERROR_INVAL; + break; + case WSAEWOULDBLOCK: + return G_IO_STATUS_AGAIN; +#ifdef WE_NEED_TO_HANDLE_WSAEINTR /* not anymore with wsock2 ? */ + case WSAEINTR: + goto repeat; +#endif + default: + error = G_IO_CHANNEL_ERROR_FAILED; + break; + } + g_set_error(err, G_IO_CHANNEL_ERROR, error, _("Socket error")); + return G_IO_STATUS_ERROR; + /* FIXME get all errors, better error messages */ + } + else + { + *bytes_written = result; + + return G_IO_STATUS_NORMAL; + } +} + +static GIOStatus +g_io_win32_sock_close (GIOChannel *channel, + GError **err) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + + LOCK(win32_channel->mutex); + if (win32_channel->running) + { + if (win32_channel->debug) + g_print ("thread %#x: running, marking for later close\n", + win32_channel->thread_id); + win32_channel->running = FALSE; + win32_channel->needs_close = TRUE; + SetEvent(win32_channel->data_avail_noticed_event); + } + if (win32_channel->fd != -1) + { + if (win32_channel->debug) + g_print ("thread %#x: closing socket %d\n", + win32_channel->thread_id, + win32_channel->fd); + + closesocket (win32_channel->fd); + win32_channel->fd = -1; + } + UNLOCK(win32_channel->mutex); + + /* FIXME error detection? */ + + return G_IO_STATUS_NORMAL; +} + +static GSource * +g_io_win32_sock_create_watch (GIOChannel *channel, + GIOCondition condition) +{ + return g_io_win32_create_watch (channel, condition, select_thread); +} + +GIOChannel * +g_io_channel_new_file (const gchar *filename, + const gchar *mode, + GError **error) +{ + int fid, flags, pmode; + GIOChannel *channel; + + enum { /* Cheesy hack */ + MODE_R = 1 << 0, + MODE_W = 1 << 1, + MODE_A = 1 << 2, + MODE_PLUS = 1 << 3, + } mode_num; + + g_return_val_if_fail (filename != NULL, NULL); + g_return_val_if_fail (mode != NULL, NULL); + g_return_val_if_fail ((error == NULL) || (*error == NULL), NULL); + + switch (mode[0]) + { + case 'r': + mode_num = MODE_R; + break; + case 'w': + mode_num = MODE_W; + break; + case 'a': + mode_num = MODE_A; + break; + default: + g_warning (G_STRLOC ": Invalid GIOFileMode %s.\n", mode); + return NULL; + } + + switch (mode[1]) + { + case '\0': + break; + case '+': + if (mode[2] == '\0') + { + mode_num |= MODE_PLUS; + break; + } + /* Fall through */ + default: + g_warning (G_STRLOC ": Invalid GIOFileMode %s.\n", mode); + return NULL; + } + + switch (mode_num) + { + case MODE_R: + flags = O_RDONLY; + pmode = _S_IREAD; + break; + case MODE_W: + flags = O_WRONLY | O_TRUNC | O_CREAT; + pmode = _S_IWRITE; + break; + case MODE_A: + flags = O_WRONLY | O_APPEND | O_CREAT; + pmode = _S_IWRITE; + break; + case MODE_R | MODE_PLUS: + flags = O_RDWR; + pmode = _S_IREAD | _S_IWRITE; + break; + case MODE_W | MODE_PLUS: + flags = O_RDWR | O_TRUNC | O_CREAT; + pmode = _S_IREAD | _S_IWRITE; + break; + case MODE_A | MODE_PLUS: + flags = O_RDWR | O_APPEND | O_CREAT; + pmode = _S_IREAD | _S_IWRITE; + break; + default: + g_assert_not_reached (); + flags = 0; + pmode = 0; + } + + + /* always open 'untranslated' */ + fid = open (filename, flags | _O_BINARY, pmode); + if (fid < 0) + { + g_set_error (error, G_FILE_ERROR, + g_file_error_from_errno (errno), + strerror (errno)); + return (GIOChannel *)NULL; + } + + channel = g_io_channel_win32_new_fd (fid); + + /* XXX: move this to g_io_channel_win32_new_fd () */ + channel->close_on_unref = TRUE; + channel->is_seekable = TRUE; + + switch (mode_num) + { + case MODE_R: + channel->is_readable = TRUE; + channel->is_writeable = FALSE; + break; + case MODE_W: + case MODE_A: + channel->is_readable = FALSE; + channel->is_writeable = TRUE; + break; + case MODE_R | MODE_PLUS: + case MODE_W | MODE_PLUS: + case MODE_A | MODE_PLUS: + channel->is_readable = TRUE; + channel->is_writeable = TRUE; + break; + default: + g_assert_not_reached (); + } + + if (((GIOWin32Channel *)channel)->debug) + g_print ("g_io_channel_win32_new_file: fd = %ud\n", fid); + + return channel; +} + +GIOStatus +g_io_win32_set_flags (GIOChannel *channel, + GIOFlags flags, + GError **err) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + + g_set_error (err, + G_IO_CHANNEL_ERROR, + g_file_error_from_errno (EACCES), + _("Channel set flags unsupported")); + return G_IO_STATUS_ERROR; +} + +GIOFlags +g_io_win32_fd_get_flags (GIOChannel *channel) +{ + GIOFlags flags = 0; + struct _stat st; + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + + g_return_val_if_fail (win32_channel != NULL, 0); + g_return_val_if_fail (win32_channel->type == G_IO_WIN32_FILE_DESC, 0); + + if (0 == _fstat (win32_channel->fd, &st)) + { + /* XXX: G_IO_FLAG_APPEND */ + /* XXX: G_IO_FLAG_NONBLOCK */ + if (st.st_mode & _S_IREAD) flags |= G_IO_FLAG_IS_READABLE; + if (st.st_mode & _S_IWRITE) flags |= G_IO_FLAG_IS_WRITEABLE; + /* XXX: */ + if (!(st.st_mode & _S_IFIFO)) flags |= G_IO_FLAG_IS_SEEKABLE; + } + + return flags; +} + +/* + * Generic implementation, just translating createion flags + */ +GIOFlags +g_io_win32_get_flags (GIOChannel *channel) +{ + GIOFlags flags; + + flags = (channel->is_readable ? G_IO_FLAG_IS_READABLE : 0) + | (channel->is_writeable ? G_IO_FLAG_IS_READABLE : 0) + | (channel->is_seekable ? G_IO_FLAG_IS_SEEKABLE : 0); + + return flags; +} + +static GIOFuncs win32_channel_msg_funcs = { + g_io_win32_msg_read, + g_io_win32_msg_write, + g_io_win32_no_seek, + g_io_win32_msg_close, + g_io_win32_msg_create_watch, + g_io_win32_free, + g_io_win32_set_flags, + g_io_win32_get_flags, +}; + +static GIOFuncs win32_channel_fd_funcs = { + g_io_win32_fd_read, + g_io_win32_fd_write, + g_io_win32_fd_seek, + g_io_win32_fd_close, + g_io_win32_fd_create_watch, + g_io_win32_free, + g_io_win32_set_flags, + g_io_win32_fd_get_flags, +}; + +static GIOFuncs win32_channel_sock_funcs = { + g_io_win32_sock_read, + g_io_win32_sock_write, + g_io_win32_no_seek, + g_io_win32_sock_close, + g_io_win32_sock_create_watch, + g_io_win32_free, + g_io_win32_set_flags, + g_io_win32_get_flags, +}; + +GIOChannel * +g_io_channel_win32_new_messages (guint hwnd) +{ + GIOWin32Channel *win32_channel = g_new (GIOWin32Channel, 1); + GIOChannel *channel = (GIOChannel *)win32_channel; + + g_io_channel_init (channel); + g_io_channel_win32_init (win32_channel); + if (win32_channel->debug) + g_print ("g_io_channel_win32_new_messages: hwnd = %ud\n", hwnd); + channel->funcs = &win32_channel_msg_funcs; + win32_channel->type = G_IO_WIN32_WINDOWS_MESSAGES; + win32_channel->hwnd = (HWND) hwnd; + + /* XXX: check this. */ + channel->is_readable = IsWindow (win32_channel->hwnd); + channel->is_writeable = IsWindow (win32_channel->hwnd); + + channel->is_seekable = FALSE; + + return channel; +} + +GIOChannel * +g_io_channel_win32_new_fd (gint fd) +{ + GIOWin32Channel *win32_channel; + GIOChannel *channel; + struct stat st; + + if (fstat (fd, &st) == -1) + { + g_warning (G_STRLOC ": %d isn't a (emulated) file descriptor", fd); + return NULL; + } + + win32_channel = g_new (GIOWin32Channel, 1); + channel = (GIOChannel *)win32_channel; + + g_io_channel_init (channel); + g_io_channel_win32_init (win32_channel); + if (win32_channel->debug) + g_print ("g_io_channel_win32_new_fd: fd = %d\n", fd); + channel->funcs = &win32_channel_fd_funcs; + win32_channel->type = G_IO_WIN32_FILE_DESC; + win32_channel->fd = fd; + + + /* fstat doesn't deliver senseful values, but + * fcntl isn't available, so guess ... + */ + if (st.st_mode & _S_IFIFO) + { + channel->is_readable = TRUE; + channel->is_writeable = TRUE; + channel->is_seekable = FALSE; + } + else + { + channel->is_readable = !!(st.st_mode & _S_IREAD); + channel->is_writeable = !!(st.st_mode & _S_IWRITE); + /* XXX: pipes aren't seeakable, are they ? */ + channel->is_seekable = !(st.st_mode & _S_IFIFO); + } + + return channel; +} + +gint +g_io_channel_win32_get_fd (GIOChannel *channel) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + + return win32_channel->fd; +} + +GIOChannel * +g_io_channel_win32_new_socket (int socket) +{ + GIOWin32Channel *win32_channel = g_new (GIOWin32Channel, 1); + GIOChannel *channel = (GIOChannel *)win32_channel; + + g_io_channel_init (channel); + g_io_channel_win32_init (win32_channel); + if (win32_channel->debug) + g_print ("g_io_channel_win32_new_socket: sockfd:%d\n", socket); + channel->funcs = &win32_channel_sock_funcs; + win32_channel->type = G_IO_WIN32_SOCKET; + win32_channel->fd = socket; + + /* XXX: check this */ + channel->is_readable = TRUE; + channel->is_writeable = TRUE; + channel->is_seekable = FALSE; + + return channel; +} + +GIOChannel * +g_io_channel_unix_new (gint fd) +{ + struct stat st; + + if (fstat (fd, &st) == 0) + return g_io_channel_win32_new_fd (fd); + + if (getsockopt (fd, SOL_SOCKET, SO_TYPE, NULL, NULL) != SO_ERROR) + return g_io_channel_win32_new_socket(fd); + + g_warning (G_STRLOC ": %d is neither a file descriptor or a socket", fd); + return NULL; +} + +gint +g_io_channel_unix_get_fd (GIOChannel *channel) +{ + return g_io_channel_win32_get_fd (channel); +} + +void +g_io_channel_win32_set_debug (GIOChannel *channel, + gboolean flag) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + + win32_channel->debug = flag; +} + +gint +g_io_channel_win32_poll (GPollFD *fds, + gint n_fds, + gint timeout) +{ + int result; + + g_return_val_if_fail (n_fds >= 0, 0); + + result = (*g_main_context_get_poll_func (NULL)) (fds, n_fds, timeout); + + return result; +} + +void +g_io_channel_win32_make_pollfd (GIOChannel *channel, + GIOCondition condition, + GPollFD *fd) +{ + GIOWin32Channel *win32_channel = (GIOWin32Channel *)channel; + + if (win32_channel->data_avail_event == NULL) + create_events (win32_channel); + + fd->fd = (gint) win32_channel->data_avail_event; + fd->events = condition; + + if (win32_channel->thread_id == 0) + if ((condition & G_IO_IN) && win32_channel->type == G_IO_WIN32_FILE_DESC) + create_thread (win32_channel, condition, read_thread); + else if (win32_channel->type == G_IO_WIN32_SOCKET) + create_thread (win32_channel, condition, select_thread); +} + +/* Binary compatibility */ +GIOChannel * +g_io_channel_win32_new_stream_socket (int socket) +{ + return g_io_channel_win32_new_socket (socket); +} diff --git a/graf2d/win32gdk/gdk/src/glib/glib-object.h b/graf2d/win32gdk/gdk/src/glib/glib-object.h index b4392431b741a..aefdd2f804585 100644 --- a/graf2d/win32gdk/gdk/src/glib/glib-object.h +++ b/graf2d/win32gdk/gdk/src/glib/glib-object.h @@ -21,16 +21,17 @@ /* topmost include file for GObject header files */ #include <gobject/gboxed.h> -#include <gobject/gbsearcharray.h> #include <gobject/genums.h> #include <gobject/gobject.h> #include <gobject/gparam.h> #include <gobject/gparamspecs.h> #include <gobject/gsignal.h> +#include <gobject/gsourceclosure.h> #include <gobject/gtype.h> #include <gobject/gtypemodule.h> #include <gobject/gtypeplugin.h> #include <gobject/gvalue.h> +#include <gobject/gvaluearray.h> #include <gobject/gvaluetypes.h> diff --git a/graf2d/win32gdk/gdk/src/glib/glib.def b/graf2d/win32gdk/gdk/src/glib/glib.def new file mode 100644 index 0000000000000..c24f57e222ae1 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/glib.def @@ -0,0 +1,703 @@ +EXPORTS + g_allocator_free + g_allocator_new + g_array_append_vals + g_array_free + g_array_insert_vals + g_array_new + g_array_prepend_vals + g_array_remove_index + g_array_remove_index_fast + g_array_set_size + g_array_sized_new + g_array_sort + g_array_sort_with_data + g_ascii_digit_value + g_ascii_strcasecmp + g_ascii_strncasecmp + g_ascii_strdown + g_ascii_strup + g_ascii_table + g_ascii_tolower + g_ascii_toupper + g_ascii_xdigit_value + g_async_queue_length + g_async_queue_length_unlocked + g_async_queue_lock + g_async_queue_new + g_async_queue_pop + g_async_queue_pop_unlocked + g_async_queue_push + g_async_queue_push_unlocked + g_async_queue_ref + g_async_queue_ref_unlocked + g_async_queue_timed_pop + g_async_queue_timed_pop_unlocked + g_async_queue_try_pop + g_async_queue_try_pop_unlocked + g_async_queue_unlock + g_async_queue_unref + g_async_queue_unref_and_unlock + g_atexit + g_basename + g_bit_nth_lsf + g_bit_nth_msf + g_bit_storage + g_blow_chunks + g_bsearch_array_destroy + g_bsearch_array_get_index + g_bsearch_array_get_nth + g_bsearch_array_new + g_bsearch_array_insert + g_bsearch_array_lookup + g_bsearch_array_remove + g_bsearch_array_remove_node + g_build_filename + g_build_path + g_byte_array_append + g_byte_array_free + g_byte_array_new + g_byte_array_prepend + g_byte_array_remove_index + g_byte_array_remove_index_fast + g_byte_array_set_size + g_byte_array_sized_new + g_byte_array_sort + g_byte_array_sort_with_data + g_cache_destroy + g_cache_insert + g_cache_key_foreach + g_cache_new + g_cache_remove + g_cache_value_foreach + g_clear_error + g_completion_add_items + g_completion_clear_items + g_completion_complete + g_completion_free + g_completion_new + g_completion_remove_items + g_convert + g_convert_error_quark + g_convert_with_fallback + g_datalist_clear + g_datalist_foreach + g_datalist_id_get_data + g_datalist_id_remove_no_notify + g_datalist_id_set_data_full + g_datalist_init + g_dataset_destroy + g_dataset_foreach + g_dataset_id_get_data + g_dataset_id_remove_no_notify + g_dataset_id_set_data_full + g_date_add_days + g_date_add_months + g_date_add_years + g_date_clear + g_date_compare + g_date_free + g_date_get_day + g_date_get_day_of_year + g_date_get_days_in_month + g_date_get_julian + g_date_get_monday_week_of_year + g_date_get_monday_weeks_in_year + g_date_get_month + g_date_get_sunday_week_of_year + g_date_get_sunday_weeks_in_year + g_date_get_weekday + g_date_get_year + g_date_is_first_of_month + g_date_is_last_of_month + g_date_is_leap_year + g_date_new + g_date_new_dmy + g_date_new_julian + g_date_set_day + g_date_set_dmy + g_date_set_julian + g_date_set_month + g_date_set_parse + g_date_set_time + g_date_set_year + g_date_strftime + g_date_subtract_days + g_date_subtract_months + g_date_subtract_years + g_date_to_struct_tm + g_date_valid + g_date_valid_day + g_date_valid_dmy + g_date_valid_julian + g_date_valid_month + g_date_valid_weekday + g_date_valid_year + g_direct_equal + g_direct_hash + g_error_copy + g_error_free + g_error_matches + g_error_new + g_error_new_literal + g_file_error_from_errno + g_file_error_quark + g_file_get_contents + g_file_open_tmp + g_file_test + g_filename_from_uri + g_filename_from_utf8 + g_filename_to_uri + g_filename_to_utf8 + g_find_program_in_path + g_free + g_get_charset + g_get_codeset + g_get_current_dir + g_get_current_time + g_get_home_dir + g_get_prgname + g_get_real_name + g_get_tmp_dir + g_get_user_name + g_getenv + g_hash_table_destroy + g_hash_table_foreach + g_hash_table_foreach_remove + g_hash_table_insert + g_hash_table_lookup + g_hash_table_lookup_extended + g_hash_table_new + g_hash_table_new_full + g_hash_table_remove + g_hash_table_size + g_hook_alloc + g_hook_compare_ids + g_hook_destroy + g_hook_destroy_link + g_hook_find + g_hook_find_data + g_hook_find_func + g_hook_find_func_data + g_hook_first_valid + g_hook_free + g_hook_get + g_hook_insert_before + g_hook_insert_sorted + g_hook_list_clear + g_hook_list_init + g_hook_list_invoke + g_hook_list_invoke_check + g_hook_list_marshal + g_hook_list_marshal_check + g_hook_next_valid + g_hook_prepend + g_hook_ref + g_hook_unref + g_iconv + g_iconv_close + g_iconv_open + g_idle_add + g_idle_add_full + g_idle_funcs + g_idle_remove_by_data + g_idle_source_new + g_int_equal + g_int_hash + g_io_add_watch + g_io_add_watch_full + g_io_channel_close + g_io_channel_error_from_errno + g_io_channel_error_quark + g_io_channel_flush + g_io_channel_get_buffer_condition + g_io_channel_get_buffer_size + g_io_channel_get_buffered + g_io_channel_get_close_on_unref + g_io_channel_get_encoding + g_io_channel_get_flags + g_io_channel_get_line_term + g_io_channel_init + g_io_channel_new_file + g_io_channel_read + g_io_channel_read_chars + g_io_channel_read_line + g_io_channel_read_line_string + g_io_channel_read_to_end + g_io_channel_read_unichar + g_io_channel_ref + g_io_channel_seek + g_io_channel_seek_position + g_io_channel_set_buffer_size + g_io_channel_set_buffered + g_io_channel_set_close_on_unref + g_io_channel_set_encoding + g_io_channel_set_flags + g_io_channel_set_line_term + g_io_channel_unix_get_fd + g_io_channel_unix_new + g_io_channel_unref + g_io_channel_win32_get_fd + g_io_channel_win32_make_pollfd + g_io_channel_win32_new_fd + g_io_channel_win32_new_messages + g_io_channel_win32_new_socket + g_io_channel_win32_new_stream_socket + g_io_channel_win32_poll + g_io_channel_win32_set_debug + g_io_channel_write + g_io_channel_write_chars + g_io_channel_write_unichar + g_io_create_watch + g_io_watch_funcs + g_list_alloc + g_list_append + g_list_concat + g_list_copy + g_list_delete_link + g_list_find + g_list_find_custom + g_list_first + g_list_foreach + g_list_free + g_list_free_1 + g_list_index + g_list_insert + g_list_insert_before + g_list_insert_sorted + g_list_last + g_list_length + g_list_nth + g_list_nth_data + g_list_position + g_list_prepend + g_list_remove + g_list_remove_all + g_list_remove_link + g_list_reverse + g_list_sort + g_list_sort_with_data + g_locale_from_utf8 + g_locale_to_utf8 + g_log + g_log_default_handler + g_log_domain_glib + g_log_remove_handler + g_log_set_always_fatal + g_log_set_fatal_mask + g_log_set_handler + g_logv + g_main_context_add_poll + g_main_context_check + g_main_context_default + g_main_context_dispatch + g_main_context_find_source_by_funcs_user_data + g_main_context_find_source_by_id + g_main_context_find_source_by_user_data + g_main_context_new + g_main_context_get_poll_func + g_main_context_iteration + g_main_context_pending + g_main_context_prepare + g_main_context_query + g_main_context_remove_poll + g_main_context_set_poll_func + g_main_loop_is_running + g_main_loop_new + g_main_loop_quit + g_main_loop_ref + g_main_loop_run + g_main_loop_unref + g_malloc + g_malloc0 + g_markup_error_quark + g_markup_escape_text + g_markup_parse_context_end_parse + g_markup_parse_context_free + g_markup_parse_context_get_position + g_markup_parse_context_new + g_markup_parse_context_parse + g_mem_chunk_alloc + g_mem_chunk_alloc0 + g_mem_chunk_clean + g_mem_chunk_destroy + g_mem_chunk_free + g_mem_chunk_info + g_mem_chunk_new + g_mem_chunk_print + g_mem_chunk_reset + g_mem_init + g_mem_profile + g_mem_set_vtable + g_memdup + g_messages_init + g_mkstemp + g_mutex_init + g_node_child_index + g_node_child_position + g_node_children_foreach + g_node_copy + g_node_depth + g_node_destroy + g_node_find + g_node_find_child + g_node_first_sibling + g_node_get_root + g_node_insert + g_node_insert_after + g_node_insert_before + g_node_is_ancestor + g_node_last_child + g_node_last_sibling + g_node_max_height + g_node_n_children + g_node_n_nodes + g_node_new + g_node_nth_child + g_node_prepend + g_node_reverse_children + g_node_traverse + g_node_unlink + g_nullify_pointer + g_on_error_query + g_on_error_stack_trace + g_parse_debug_string + g_path_get_basename + g_path_get_dirname + g_path_is_absolute + g_path_skip_root + g_pattern_match + g_pattern_match_string + g_pattern_spec_free + g_pattern_spec_new + g_print + g_printerr + g_printf_string_upper_bound + g_propagate_error + g_ptr_array_add + g_ptr_array_free + g_ptr_array_new + g_ptr_array_remove + g_ptr_array_remove_fast + g_ptr_array_remove_index + g_ptr_array_remove_index_fast + g_ptr_array_set_size + g_ptr_array_sized_new + g_ptr_array_sort + g_ptr_array_sort_with_data + g_qsort_with_data + g_quark_from_static_string + g_quark_from_string + g_quark_to_string + g_quark_try_string + g_queue_free + g_queue_is_empty + g_queue_new + g_queue_peek_head + g_queue_peek_tail + g_queue_pop_head + g_queue_pop_head_link + g_queue_pop_tail + g_queue_pop_tail_link + g_queue_push_head + g_queue_push_head_link + g_queue_push_tail + g_queue_push_tail_link + g_rand_double + g_rand_double_range + g_rand_free + g_rand_int + g_rand_int_range + g_rand_new + g_rand_new_with_seed + g_rand_set_seed + g_random_double + g_random_double_range + g_random_int + g_random_int_range + g_random_set_seed + g_realloc + g_relation_count + g_relation_delete + g_relation_destroy + g_relation_exists + g_relation_index + g_relation_insert + g_relation_new + g_relation_print + g_relation_select + g_scanner_cur_line + g_scanner_cur_position + g_scanner_cur_token + g_scanner_cur_value + g_scanner_destroy + g_scanner_eof + g_scanner_error + g_scanner_get_next_token + g_scanner_input_file + g_scanner_input_text + g_scanner_lookup_symbol + g_scanner_new + g_scanner_peek_next_token + g_scanner_scope_add_symbol + g_scanner_scope_foreach_symbol + g_scanner_scope_lookup_symbol + g_scanner_scope_remove_symbol + g_scanner_set_scope + g_scanner_sync_file_offset + g_scanner_unexp_token + g_scanner_warn + g_set_error + g_set_prgname + g_set_print_handler + g_set_printerr_handler + g_shell_error_quark + g_shell_parse_argv + g_shell_quote + g_shell_unquote + g_slist_alloc + g_slist_append + g_slist_concat + g_slist_copy + g_slist_delete_link + g_slist_find + g_slist_find_custom + g_slist_foreach + g_slist_free + g_slist_free_1 + g_slist_index + g_slist_insert + g_slist_insert_before + g_slist_insert_sorted + g_slist_last + g_slist_length + g_slist_nth + g_slist_nth_data + g_slist_position + g_slist_prepend + g_slist_remove + g_slist_remove_all + g_slist_remove_link + g_slist_reverse + g_slist_sort + g_slist_sort_with_data + g_snprintf + g_source_add_poll + g_source_attach + g_source_destroy + g_source_get_can_recurse + g_source_get_context + g_source_get_current_time + g_source_get_id + g_source_get_priority + g_source_new + g_source_ref + g_source_remove + g_source_remove_by_funcs_user_data + g_source_remove_by_user_data + g_source_set_callback + g_source_set_callback_indirect + g_source_set_can_recurse + g_source_set_priority + g_source_unref + g_spaced_primes_closest + g_spawn_async + g_spawn_async_with_pipes + g_spawn_command_line_async + g_spawn_command_line_sync + g_spawn_error_quark + g_spawn_sync + g_static_mutex_get_mutex_impl + g_static_private_free + g_static_private_get + g_static_private_init + g_static_private_set + g_static_rec_mutex_free + g_static_rec_mutex_init + g_static_rec_mutex_lock + g_static_rec_mutex_trylock + g_static_rec_mutex_unlock + g_static_rw_lock_free + g_static_rw_lock_init + g_static_rw_lock_reader_lock + g_static_rw_lock_reader_trylock + g_static_rw_lock_reader_unlock + g_static_rw_lock_writer_lock + g_static_rw_lock_writer_trylock + g_static_rw_lock_writer_unlock + g_stpcpy + g_str_equal + g_str_hash + g_strcanon + g_strcasecmp + g_strchomp + g_strchug + g_strcompress + g_strconcat + g_strdelimit + g_strdown + g_strdup + g_strdup_printf + g_strdup_vprintf + g_strdupv + g_strerror + g_strescape + g_strfreev + g_string_append + g_string_append_c + g_string_append_len + g_string_append_unichar + g_string_ascii_down + g_string_assign + g_string_chunk_free + g_string_chunk_insert + g_string_chunk_insert_const + g_string_chunk_new + g_string_down + g_string_equal + g_string_erase + g_string_free + g_string_insert + g_string_insert_c + g_string_insert_len + g_string_insert_unichar + g_string_new + g_string_new_len + g_string_prepend + g_string_prepend_c + g_string_prepend_len + g_string_prepend_unichar + g_string_printf + g_string_printfa + g_string_sized_new + g_string_truncate + g_string_up + g_strjoin + g_strjoinv + g_strlcat + g_strlcpy + g_strncasecmp + g_strndup + g_strnfill + g_strreverse + g_strsignal + g_strsplit + g_strrstr + g_strrstr_len + g_strstr_len + g_strtod + g_strup + g_thread_create_full + g_thread_error_quark + g_thread_functions_for_glib_use + g_thread_join + g_thread_exit + g_thread_pool_free + g_thread_pool_new + g_thread_pool_push + g_thread_self + g_thread_set_priority + g_thread_use_default_impl + g_threads_got_initialized + g_timeout_add + g_timeout_add_full + g_timeout_funcs + g_timeout_source_new + g_timer_destroy + g_timer_elapsed + g_timer_new + g_timer_reset + g_timer_start + g_timer_stop + g_trash_stack_height + g_trash_stack_peek + g_trash_stack_pop + g_trash_stack_push + g_tree_destroy + g_tree_height + g_tree_insert + g_tree_lookup + g_tree_new + g_tree_nnodes + g_tree_remove + g_tree_search + g_tree_traverse + g_try_malloc + g_try_realloc + g_tuples_destroy + g_tuples_index + g_ucs4_to_utf16 + g_ucs4_to_utf8 + g_unichar_break_type + g_unichar_digit_value + g_unichar_isalnum + g_unichar_isalpha + g_unichar_iscntrl + g_unichar_isdefined + g_unichar_isdigit + g_unichar_isgraph + g_unichar_islower + g_unichar_isprint + g_unichar_ispunct + g_unichar_isspace + g_unichar_istitle + g_unichar_isupper + g_unichar_iswide + g_unichar_isxdigit + g_unichar_to_utf8 + g_unichar_tolower + g_unichar_totitle + g_unichar_toupper + g_unichar_type + g_unichar_validate + g_unichar_xdigit_value + g_unicode_canonical_decomposition + g_unicode_canonical_ordering + g_usleep + g_utf16_to_ucs4 + g_utf16_to_utf8 + g_utf8_casefold + g_utf8_collate + g_utf8_collate_key + g_utf8_find_next_char + g_utf8_find_prev_char + g_utf8_get_char + g_utf8_get_char_validated + g_utf8_normalize + g_utf8_offset_to_pointer + g_utf8_pointer_to_offset + g_utf8_prev_char + g_utf8_skip + g_utf8_strchr + g_utf8_strdown + g_utf8_strlen + g_utf8_strncpy + g_utf8_strup + g_utf8_to_ucs4 + g_utf8_to_ucs4_fast + g_utf8_to_utf16 + g_utf8_validate + g_vsnprintf + g_win32_closedir + g_win32_error_message + g_win32_ftruncate + g_win32_get_package_installation_directory + g_win32_get_package_installation_subdirectory + g_win32_getlocale + g_win32_opendir + g_win32_readdir + g_win32_rewinddir + glib_binary_age + glib_interface_age + glib_major_version + glib_mem_profiler_table + glib_micro_version + glib_minor_version + +; compatibility for older win32 apps, which should +; not need an update because of simple function renaming +; and vice versa, i.e.: +; compatibility of Dia 0.87 with tml's latest Gtk+ version (2000-12-26) + g_dirname=g_path_get_dirname + g_string_sprintfa=g_string_printfa + g_string_sprintf=g_string_printf diff --git a/graf2d/win32gdk/gdk/src/glib/glib.h b/graf2d/win32gdk/gdk/src/glib/glib.h index 8b2ee4e769a93..0febae39e4e0f 100644 --- a/graf2d/win32gdk/gdk/src/glib/glib.h +++ b/graf2d/win32gdk/gdk/src/glib/glib.h @@ -27,49 +27,49 @@ #ifndef __G_LIB_H__ #define __G_LIB_H__ -#include <galloca.h> -#include <garray.h> -#include <gasyncqueue.h> -#include <gbacktrace.h> -#include <gcache.h> -#include <gcompat.h> -#include <gcompletion.h> -#include <gconvert.h> -#include <gdataset.h> -#include <gdate.h> -#include <gerror.h> -#include <gfileutils.h> -#include <ghash.h> -#include <ghook.h> -#include <giochannel.h> -#include <glist.h> -#include <gmacros.h> -#include <gmain.h> -#include <gmarkup.h> -#include <gmem.h> -#include <gmessages.h> -#include <gnode.h> -#include <gprimes.h> -#include <gqsort.h> -#include <gquark.h> -#include <gqueue.h> -#include <grand.h> -#include <grel.h> -#include <gscanner.h> -#include <gshell.h> -#include <gslist.h> -#include <gspawn.h> -#include <gstrfuncs.h> -#include <gstring.h> -#include <gthread.h> -#include <gthreadpool.h> -#include <gtimer.h> -#include <gtree.h> -#include <g_types.h> -#include <gunicode.h> -#include <gutils.h> -#ifdef G_OS_WIN32 -#include <gwin32.h> +#include <glib/galloca.h> +#include <glib/garray.h> +#include <glib/gasyncqueue.h> +#include <glib/gbacktrace.h> +#include <glib/gcache.h> +#include <glib/gcompletion.h> +#include <glib/gconvert.h> +#include <glib/gdataset.h> +#include <glib/gdate.h> +#include <glib/gerror.h> +#include <glib/gfileutils.h> +#include <glib/ghash.h> +#include <glib/ghook.h> +#include <glib/giochannel.h> +#include <glib/glist.h> +#include <glib/gmacros.h> +#include <glib/gmain.h> +#include <glib/gmarkup.h> +#include <glib/gmem.h> +#include <glib/gmessages.h> +#include <glib/gnode.h> +#include <glib/gpattern.h> +#include <glib/gprimes.h> +#include <glib/gqsort.h> +#include <glib/gquark.h> +#include <glib/gqueue.h> +#include <glib/grand.h> +#include <glib/grel.h> +#include <glib/gscanner.h> +#include <glib/gshell.h> +#include <glib/gslist.h> +#include <glib/gspawn.h> +#include <glib/gstrfuncs.h> +#include <glib/gstring.h> +#include <glib/gthread.h> +#include <glib/gthreadpool.h> +#include <glib/gtimer.h> +#include <glib/gtree.h> +#include <glib/gtypes.h> +#include <glib/gunicode.h> +#include <glib/gutils.h> +#ifdef G_PLATFORM_WIN32 +#include <glib/gwin32.h> #endif #endif /* __G_LIB_H__ */ diff --git a/graf2d/win32gdk/gdk/src/glib/glib.rc b/graf2d/win32gdk/gdk/src/glib/glib.rc new file mode 100644 index 0000000000000..c31875be4c2ce --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/glib.rc @@ -0,0 +1,30 @@ +#include <winver.h> + +VS_VERSION_INFO VERSIONINFO + FILEVERSION 1,3,9,BUILDNUMBER + PRODUCTVERSION 1,3,9,0 + FILEFLAGSMASK 0 + FILEFLAGS 0 + FILEOS VOS__WINDOWS32 + FILETYPE VFT_DLL + FILESUBTYPE VFT2_UNKNOWN + BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904B0" + BEGIN + VALUE "CompanyName", "The GLib developer community" + VALUE "FileDescription", "GLib" + VALUE "FileVersion", "1.3.9.BUILDNUMBER" + VALUE "InternalName", "libglib-1.3-9" + VALUE "LegalCopyright", "Copyright � 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald. Modified by the GLib Team and others 1997-2000." + VALUE "OriginalFilename", "libglib-1.3-9.dll" + VALUE "ProductName", "GLib" + VALUE "ProductVersion", "1.3.9" + END + END + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1200 + END + END diff --git a/graf2d/win32gdk/gdk/src/glib/glibconfig-bogus.h b/graf2d/win32gdk/gdk/src/glib/glibconfig-bogus.h new file mode 100644 index 0000000000000..b2def8614981b --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/glibconfig-bogus.h @@ -0,0 +1,202 @@ +/* glibconfig.h.win32 */ +/* Handcrafted for Microsoft C and gcc -mno-cygwin ("mingw32"). */ + +#ifndef __G_LIBCONFIG_H__ +#define __G_LIBCONFIG_H__ + +#include <gmacros.h> + +#ifdef _MSC_VER +/* Make MSVC more pedantic, this is a recommended pragma list + * from _Win32_Programming_ by Rector and Newcomer. + */ + +#pragma warning(error:4002) +#pragma warning(error:4003) +#pragma warning(1:4010) +#pragma warning(error:4013) +#pragma warning(1:4016) +#pragma warning(error:4020) +#pragma warning(error:4021) +#pragma warning(error:4027) +#pragma warning(error:4029) +#pragma warning(error:4033) +#pragma warning(error:4035) +#pragma warning(error:4045) +#pragma warning(error:4047) +#pragma warning(error:4049) +#pragma warning(error:4053) +#pragma warning(error:4071) +#pragma warning(disable:4101) +#pragma warning(error:4150) + +#pragma warning(disable:4244) // No possible loss of data warnings +#pragma warning(disable:4305) // No truncation from int to char warnings + +#endif /* _MSC_VER */ + +#include <limits.h> +#include <float.h> + +#define G_MINFLOAT FLT_MIN +#define G_MAXFLOAT FLT_MAX +#define G_MINDOUBLE DBL_MIN +#define G_MAXDOUBLE DBL_MAX +#define G_MINSHORT SHRT_MIN +#define G_MAXSHORT SHRT_MAX +#define G_MAXUSHORT USHRT_MAX +#define G_MININT INT_MIN +#define G_MAXINT INT_MAX +#define G_MAXUINT UINT_MAX +#define G_MINLONG LONG_MIN +#define G_MAXLONG LONG_MAX +#define G_MAXULONG ULONG_MAX + +G_BEGIN_DECLS + +typedef signed char gint8; +typedef unsigned char guint8; +typedef signed short gint16; +typedef unsigned short guint16; +#define G_GINT16_FORMAT "hi" +#define G_GUINT16_FORMAT "hu" +typedef signed int gint32; +typedef unsigned int guint32; +#define G_GINT32_FORMAT "i" +#define G_GUINT32_FORMAT "u" + +#define G_HAVE_GINT64 1 + +/* These are compiler specific */ +#ifdef _MSC_VER +typedef __int64 gint64; +typedef unsigned __int64 guint64; +#define G_GINT64_CONSTANT(val) (val##i64) +#elif __GNUC__ +typedef long long gint64; +typedef unsigned long long guint64; +#define G_GINT64_CONSTANT(val) (val##LL) +#endif + +/* These depend on the C library. Using this file means the we + * use the (bundled) Microsoft msvcrt.dll. + */ +#define G_GINT64_FORMAT "I64i" +#define G_GUINT64_FORMAT "I64u" + +typedef gint32 gssize; +typedef guint32 gsize; + +#define GPOINTER_TO_INT(p) ((gint)(p)) +#define GPOINTER_TO_UINT(p) ((guint)(p)) + +#define GINT_TO_POINTER(i) ((gpointer)(i)) +#define GUINT_TO_POINTER(u) ((gpointer)(u)) + +#define g_ATEXIT(proc) (atexit (proc)) + +#define g_memmove(d,s,n) G_STMT_START { memmove ((d), (s), (n)); } G_STMT_END + +#define GLIB_MAJOR_VERSION 1 +#define GLIB_MINOR_VERSION 3 +#define GLIB_MICRO_VERSION 2 + +#define G_OS_WIN32 + +#ifdef __cplusplus +#define G_HAVE_INLINE 1 +#else /* !__cplusplus */ +#define G_HAVE___INLINE 1 +#endif + +#define G_THREADS_ENABLED +/* + * The following program can be used to determine the magic values below: + * #include <stdio.h> + * #include <pthread.h> + * main(int argc, char **argv) + * { + * int i; + * pthread_mutex_t m = PTHREAD_MUTEX_INITIALIZER; + * printf ("sizeof (pthread_mutex_t) = %d\n", sizeof (pthread_mutex_t)); + * printf ("sizeof (pthread_t) = %d\n", sizeof (pthread_t)); + * printf ("PTHREAD_MUTEX_INITIALIZER = "); + * for (i = 0; i < sizeof (pthread_mutex_t); i++) + * printf ("%u, ", ((unsigned char *) &m)[i]); + * printf ("\n"); + * exit(0); + * } + */ + +#define G_THREADS_IMPL_POSIX +typedef struct _GStaticMutex GStaticMutex; +struct _GStaticMutex +{ + struct _GMutex *runtime_mutex; + union { + /* The size of the pad array should be sizeof (pthread_mutex_t) */ + /* This value corresponds to the 1999-05-30 version of pthreads-win32 */ + char pad[4]; + double dummy_double; + void *dummy_pointer; + long dummy_long; + } aligned_pad_u; +}; +/* This should be NULL followed by the bytes in PTHREAD_MUTEX_INITIALIZER */ +#define G_STATIC_MUTEX_INIT { NULL, { { 255, 255, 255, 255 } } } +#define g_static_mutex_get_mutex(mutex) \ + (g_thread_use_default_impl ? ((GMutex*) &((mutex)->aligned_pad_u)) : \ + g_static_mutex_get_mutex_impl (&((mutex)->runtime_mutex))) +/* This represents a system thread as used by the implementation. An + * alien implementaion, as loaded by g_thread_init can only count on + * "sizeof (gpointer)" bytes to store their info. We however need more + * for some of our native implementations. */ +typedef union _GSystemThread GSystemThread; +union _GSystemThread +{ + /* The size of the data array should be sizeof (pthread_t) */ + /* This value corresponds to the 1999-05-30 version of pthreads-win32 */ + char data[4]; + double dummy_double; + void *dummy_pointer; + long dummy_long; +}; + +#define GINT16_TO_LE(val) ((gint16) (val)) +#define GUINT16_TO_LE(val) ((guint16) (val)) +#define GINT16_TO_BE(val) ((gint16) GUINT16_SWAP_LE_BE (val)) +#define GUINT16_TO_BE(val) (GUINT16_SWAP_LE_BE (val)) + +#define GINT32_TO_LE(val) ((gint32) (val)) +#define GUINT32_TO_LE(val) ((guint32) (val)) +#define GINT32_TO_BE(val) ((gint32) GUINT32_SWAP_LE_BE (val)) +#define GUINT32_TO_BE(val) (GUINT32_SWAP_LE_BE (val)) + +#define GINT64_TO_LE(val) ((gint64) (val)) +#define GUINT64_TO_LE(val) ((guint64) (val)) +#define GINT64_TO_BE(val) ((gint64) GUINT64_SWAP_LE_BE (val)) +#define GUINT64_TO_BE(val) (GUINT64_SWAP_LE_BE (val)) + +#define GLONG_TO_LE(val) ((glong) GINT32_TO_LE (val)) +#define GULONG_TO_LE(val) ((gulong) GUINT32_TO_LE (val)) +#define GLONG_TO_BE(val) ((glong) GINT32_TO_BE (val)) +#define GULONG_TO_BE(val) ((gulong) GUINT32_TO_BE (val)) + +#define GINT_TO_LE(val) ((gint) GINT32_TO_LE (val)) +#define GUINT_TO_LE(val) ((guint) GUINT32_TO_LE (val)) +#define GINT_TO_BE(val) ((gint) GINT32_TO_BE (val)) +#define GUINT_TO_BE(val) ((guint) GUINT32_TO_BE (val)) +#define G_BYTE_ORDER G_LITTLE_ENDIAN + +#define GLIB_SYSDEF_POLLIN = 1 +#define GLIB_SYSDEF_POLLOUT = 4 +#define GLIB_SYSDEF_POLLPRI = 2 +#define GLIB_SYSDEF_POLLERR = 8 +#define GLIB_SYSDEF_POLLHUP = 16 +#define GLIB_SYSDEF_POLLNVAL = 32 + +#define G_MODULE_SUFFIX "dll" + +G_END_DECLS + +#endif /* __G_LIBCONFIG_H__ */ diff --git a/graf2d/win32gdk/gdk/src/glib/glibconfig.h b/graf2d/win32gdk/gdk/src/glib/glibconfig.h index b2def8614981b..e2e23be589a45 100644 --- a/graf2d/win32gdk/gdk/src/glib/glibconfig.h +++ b/graf2d/win32gdk/gdk/src/glib/glibconfig.h @@ -1,43 +1,19 @@ -/* glibconfig.h.win32 */ -/* Handcrafted for Microsoft C and gcc -mno-cygwin ("mingw32"). */ +/* glibconfig.h.win32.in Merged from two versions generated by configure for gcc and MSVC. */ +/* glibconfig.h + * + * This is a generated file. Please modify 'configure.in' + */ #ifndef __G_LIBCONFIG_H__ #define __G_LIBCONFIG_H__ -#include <gmacros.h> - -#ifdef _MSC_VER -/* Make MSVC more pedantic, this is a recommended pragma list - * from _Win32_Programming_ by Rector and Newcomer. - */ - -#pragma warning(error:4002) -#pragma warning(error:4003) -#pragma warning(1:4010) -#pragma warning(error:4013) -#pragma warning(1:4016) -#pragma warning(error:4020) -#pragma warning(error:4021) -#pragma warning(error:4027) -#pragma warning(error:4029) -#pragma warning(error:4033) -#pragma warning(error:4035) -#pragma warning(error:4045) -#pragma warning(error:4047) -#pragma warning(error:4049) -#pragma warning(error:4053) -#pragma warning(error:4071) -#pragma warning(disable:4101) -#pragma warning(error:4150) - -#pragma warning(disable:4244) // No possible loss of data warnings -#pragma warning(disable:4305) // No truncation from int to char warnings - -#endif /* _MSC_VER */ +#include <glib/gmacros.h> #include <limits.h> #include <float.h> +G_BEGIN_DECLS + #define G_MINFLOAT FLT_MIN #define G_MAXFLOAT FLT_MAX #define G_MINDOUBLE DBL_MIN @@ -52,7 +28,9 @@ #define G_MAXLONG LONG_MAX #define G_MAXULONG ULONG_MAX -G_BEGIN_DECLS +#define G_MININT64 ((gint64) 0x8000000000000000) +#define G_MAXINT64 ((gint64) 0x7fffffffffffffff) +#define G_MAXUINT64 ((guint64) 0xffffffffffffffff) typedef signed char gint8; typedef unsigned char guint8; @@ -64,89 +42,84 @@ typedef signed int gint32; typedef unsigned int guint32; #define G_GINT32_FORMAT "i" #define G_GUINT32_FORMAT "u" +#define G_HAVE_GINT64 1 /* deprecated, always true */ -#define G_HAVE_GINT64 1 - -/* These are compiler specific */ -#ifdef _MSC_VER -typedef __int64 gint64; +#ifndef _MSC_VER +G_GNUC_EXTENSION typedef signed long long gint64; +G_GNUC_EXTENSION typedef unsigned long long guint64; +#else /* _MSC_VER */ +typedef signed __int64 gint64; typedef unsigned __int64 guint64; -#define G_GINT64_CONSTANT(val) (val##i64) -#elif __GNUC__ -typedef long long gint64; -typedef unsigned long long guint64; -#define G_GINT64_CONSTANT(val) (val##LL) -#endif +#endif /* _MSC_VER */ -/* These depend on the C library. Using this file means the we - * use the (bundled) Microsoft msvcrt.dll. - */ +#ifndef _MSC_VER +#define G_GINT64_CONSTANT(val) (G_GNUC_EXTENSION (val##LL)) +#else /* _MSC_VER */ +#define G_GINT64_CONSTANT(val) (val##i64) +#endif /* _MSC_VER */ #define G_GINT64_FORMAT "I64i" #define G_GUINT64_FORMAT "I64u" -typedef gint32 gssize; +#define GLIB_SIZEOF_VOID_P 4 +#define GLIB_SIZEOF_LONG 4 +#define GLIB_SIZEOF_SIZE_T 4 + +typedef gint32 gssize; typedef guint32 gsize; -#define GPOINTER_TO_INT(p) ((gint)(p)) -#define GPOINTER_TO_UINT(p) ((guint)(p)) +#define GPOINTER_TO_INT(p) ((gint) (p)) +#define GPOINTER_TO_UINT(p) ((guint) (p)) -#define GINT_TO_POINTER(i) ((gpointer)(i)) -#define GUINT_TO_POINTER(u) ((gpointer)(u)) +#define GINT_TO_POINTER(i) ((gpointer) (i)) +#define GUINT_TO_POINTER(u) ((gpointer) (u)) -#define g_ATEXIT(proc) (atexit (proc)) +#ifdef NeXT /* @#%@! NeXTStep */ +# define g_ATEXIT(proc) (!atexit (proc)) +#else +# define g_ATEXIT(proc) (atexit (proc)) +#endif +#define G_NATIVE_ATEXIT #define g_memmove(d,s,n) G_STMT_START { memmove ((d), (s), (n)); } G_STMT_END #define GLIB_MAJOR_VERSION 1 #define GLIB_MINOR_VERSION 3 -#define GLIB_MICRO_VERSION 2 +#define GLIB_MICRO_VERSION 15 #define G_OS_WIN32 +#define G_PLATFORM_WIN32 + + #ifdef __cplusplus #define G_HAVE_INLINE 1 #else /* !__cplusplus */ +#ifndef _MSC_VER +#define G_HAVE_INLINE 1 +#else /* _MSC_VER */ + +#endif /* _MSC_VER */ #define G_HAVE___INLINE 1 +#ifndef _MSC_VER +#define G_HAVE___INLINE__ 1 +#endif /* not _MSC_VER */ +#endif /* !__cplusplus */ + +#ifndef _MSC_VER +#ifndef __cplusplus +# define G_HAVE_ISO_VARARGS 1 #endif -#define G_THREADS_ENABLED -/* - * The following program can be used to determine the magic values below: - * #include <stdio.h> - * #include <pthread.h> - * main(int argc, char **argv) - * { - * int i; - * pthread_mutex_t m = PTHREAD_MUTEX_INITIALIZER; - * printf ("sizeof (pthread_mutex_t) = %d\n", sizeof (pthread_mutex_t)); - * printf ("sizeof (pthread_t) = %d\n", sizeof (pthread_t)); - * printf ("PTHREAD_MUTEX_INITIALIZER = "); - * for (i = 0; i < sizeof (pthread_mutex_t); i++) - * printf ("%u, ", ((unsigned char *) &m)[i]); - * printf ("\n"); - * exit(0); - * } - */ +#define G_HAVE_GNUC_VARARGS 1 +#endif /* not _MSC_VER */ +#define G_HAVE_GROWING_STACK 0 -#define G_THREADS_IMPL_POSIX -typedef struct _GStaticMutex GStaticMutex; -struct _GStaticMutex -{ - struct _GMutex *runtime_mutex; - union { - /* The size of the pad array should be sizeof (pthread_mutex_t) */ - /* This value corresponds to the 1999-05-30 version of pthreads-win32 */ - char pad[4]; - double dummy_double; - void *dummy_pointer; - long dummy_long; - } aligned_pad_u; -}; -/* This should be NULL followed by the bytes in PTHREAD_MUTEX_INITIALIZER */ -#define G_STATIC_MUTEX_INIT { NULL, { { 255, 255, 255, 255 } } } -#define g_static_mutex_get_mutex(mutex) \ - (g_thread_use_default_impl ? ((GMutex*) &((mutex)->aligned_pad_u)) : \ - g_static_mutex_get_mutex_impl (&((mutex)->runtime_mutex))) + +#define G_THREADS_ENABLED +#define G_THREADS_IMPL_WIN32 +typedef struct _GMutex* GStaticMutex; +#define G_STATIC_MUTEX_INIT NULL +#define g_static_mutex_get_mutex(mutex) (g_static_mutex_get_mutex_impl (mutex)) /* This represents a system thread as used by the implementation. An * alien implementaion, as loaded by g_thread_init can only count on * "sizeof (gpointer)" bytes to store their info. We however need more @@ -154,8 +127,6 @@ struct _GStaticMutex typedef union _GSystemThread GSystemThread; union _GSystemThread { - /* The size of the data array should be sizeof (pthread_t) */ - /* This value corresponds to the 1999-05-30 version of pthreads-win32 */ char data[4]; double dummy_double; void *dummy_pointer; @@ -166,37 +137,33 @@ union _GSystemThread #define GUINT16_TO_LE(val) ((guint16) (val)) #define GINT16_TO_BE(val) ((gint16) GUINT16_SWAP_LE_BE (val)) #define GUINT16_TO_BE(val) (GUINT16_SWAP_LE_BE (val)) - #define GINT32_TO_LE(val) ((gint32) (val)) #define GUINT32_TO_LE(val) ((guint32) (val)) #define GINT32_TO_BE(val) ((gint32) GUINT32_SWAP_LE_BE (val)) #define GUINT32_TO_BE(val) (GUINT32_SWAP_LE_BE (val)) - #define GINT64_TO_LE(val) ((gint64) (val)) #define GUINT64_TO_LE(val) ((guint64) (val)) #define GINT64_TO_BE(val) ((gint64) GUINT64_SWAP_LE_BE (val)) #define GUINT64_TO_BE(val) (GUINT64_SWAP_LE_BE (val)) - #define GLONG_TO_LE(val) ((glong) GINT32_TO_LE (val)) #define GULONG_TO_LE(val) ((gulong) GUINT32_TO_LE (val)) #define GLONG_TO_BE(val) ((glong) GINT32_TO_BE (val)) #define GULONG_TO_BE(val) ((gulong) GUINT32_TO_BE (val)) - #define GINT_TO_LE(val) ((gint) GINT32_TO_LE (val)) #define GUINT_TO_LE(val) ((guint) GUINT32_TO_LE (val)) #define GINT_TO_BE(val) ((gint) GINT32_TO_BE (val)) #define GUINT_TO_BE(val) ((guint) GUINT32_TO_BE (val)) #define G_BYTE_ORDER G_LITTLE_ENDIAN -#define GLIB_SYSDEF_POLLIN = 1 -#define GLIB_SYSDEF_POLLOUT = 4 -#define GLIB_SYSDEF_POLLPRI = 2 -#define GLIB_SYSDEF_POLLERR = 8 -#define GLIB_SYSDEF_POLLHUP = 16 -#define GLIB_SYSDEF_POLLNVAL = 32 +#define GLIB_SYSDEF_POLLIN =1 +#define GLIB_SYSDEF_POLLOUT =4 +#define GLIB_SYSDEF_POLLPRI =2 +#define GLIB_SYSDEF_POLLERR =8 +#define GLIB_SYSDEF_POLLHUP =16 +#define GLIB_SYSDEF_POLLNVAL =32 #define G_MODULE_SUFFIX "dll" G_END_DECLS -#endif /* __G_LIBCONFIG_H__ */ +#endif /* GLIBCONFIG_H */ diff --git a/graf2d/win32gdk/gdk/src/glib/glibconfig.h.win32 b/graf2d/win32gdk/gdk/src/glib/glibconfig.h.win32 new file mode 100644 index 0000000000000..e2e23be589a45 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/glibconfig.h.win32 @@ -0,0 +1,169 @@ +/* glibconfig.h.win32.in Merged from two versions generated by configure for gcc and MSVC. */ +/* glibconfig.h + * + * This is a generated file. Please modify 'configure.in' + */ + +#ifndef __G_LIBCONFIG_H__ +#define __G_LIBCONFIG_H__ + +#include <glib/gmacros.h> + +#include <limits.h> +#include <float.h> + +G_BEGIN_DECLS + +#define G_MINFLOAT FLT_MIN +#define G_MAXFLOAT FLT_MAX +#define G_MINDOUBLE DBL_MIN +#define G_MAXDOUBLE DBL_MAX +#define G_MINSHORT SHRT_MIN +#define G_MAXSHORT SHRT_MAX +#define G_MAXUSHORT USHRT_MAX +#define G_MININT INT_MIN +#define G_MAXINT INT_MAX +#define G_MAXUINT UINT_MAX +#define G_MINLONG LONG_MIN +#define G_MAXLONG LONG_MAX +#define G_MAXULONG ULONG_MAX + +#define G_MININT64 ((gint64) 0x8000000000000000) +#define G_MAXINT64 ((gint64) 0x7fffffffffffffff) +#define G_MAXUINT64 ((guint64) 0xffffffffffffffff) + +typedef signed char gint8; +typedef unsigned char guint8; +typedef signed short gint16; +typedef unsigned short guint16; +#define G_GINT16_FORMAT "hi" +#define G_GUINT16_FORMAT "hu" +typedef signed int gint32; +typedef unsigned int guint32; +#define G_GINT32_FORMAT "i" +#define G_GUINT32_FORMAT "u" +#define G_HAVE_GINT64 1 /* deprecated, always true */ + +#ifndef _MSC_VER +G_GNUC_EXTENSION typedef signed long long gint64; +G_GNUC_EXTENSION typedef unsigned long long guint64; +#else /* _MSC_VER */ +typedef signed __int64 gint64; +typedef unsigned __int64 guint64; +#endif /* _MSC_VER */ + +#ifndef _MSC_VER +#define G_GINT64_CONSTANT(val) (G_GNUC_EXTENSION (val##LL)) +#else /* _MSC_VER */ +#define G_GINT64_CONSTANT(val) (val##i64) +#endif /* _MSC_VER */ +#define G_GINT64_FORMAT "I64i" +#define G_GUINT64_FORMAT "I64u" + +#define GLIB_SIZEOF_VOID_P 4 +#define GLIB_SIZEOF_LONG 4 +#define GLIB_SIZEOF_SIZE_T 4 + +typedef gint32 gssize; +typedef guint32 gsize; + +#define GPOINTER_TO_INT(p) ((gint) (p)) +#define GPOINTER_TO_UINT(p) ((guint) (p)) + +#define GINT_TO_POINTER(i) ((gpointer) (i)) +#define GUINT_TO_POINTER(u) ((gpointer) (u)) + +#ifdef NeXT /* @#%@! NeXTStep */ +# define g_ATEXIT(proc) (!atexit (proc)) +#else +# define g_ATEXIT(proc) (atexit (proc)) +#endif +#define G_NATIVE_ATEXIT + +#define g_memmove(d,s,n) G_STMT_START { memmove ((d), (s), (n)); } G_STMT_END + +#define GLIB_MAJOR_VERSION 1 +#define GLIB_MINOR_VERSION 3 +#define GLIB_MICRO_VERSION 15 + +#define G_OS_WIN32 +#define G_PLATFORM_WIN32 + + + +#ifdef __cplusplus +#define G_HAVE_INLINE 1 +#else /* !__cplusplus */ +#ifndef _MSC_VER +#define G_HAVE_INLINE 1 +#else /* _MSC_VER */ + +#endif /* _MSC_VER */ +#define G_HAVE___INLINE 1 +#ifndef _MSC_VER +#define G_HAVE___INLINE__ 1 +#endif /* not _MSC_VER */ +#endif /* !__cplusplus */ + +#ifndef _MSC_VER +#ifndef __cplusplus +# define G_HAVE_ISO_VARARGS 1 +#endif + +#define G_HAVE_GNUC_VARARGS 1 +#endif /* not _MSC_VER */ +#define G_HAVE_GROWING_STACK 0 + + +#define G_THREADS_ENABLED +#define G_THREADS_IMPL_WIN32 +typedef struct _GMutex* GStaticMutex; +#define G_STATIC_MUTEX_INIT NULL +#define g_static_mutex_get_mutex(mutex) (g_static_mutex_get_mutex_impl (mutex)) +/* This represents a system thread as used by the implementation. An + * alien implementaion, as loaded by g_thread_init can only count on + * "sizeof (gpointer)" bytes to store their info. We however need more + * for some of our native implementations. */ +typedef union _GSystemThread GSystemThread; +union _GSystemThread +{ + char data[4]; + double dummy_double; + void *dummy_pointer; + long dummy_long; +}; + +#define GINT16_TO_LE(val) ((gint16) (val)) +#define GUINT16_TO_LE(val) ((guint16) (val)) +#define GINT16_TO_BE(val) ((gint16) GUINT16_SWAP_LE_BE (val)) +#define GUINT16_TO_BE(val) (GUINT16_SWAP_LE_BE (val)) +#define GINT32_TO_LE(val) ((gint32) (val)) +#define GUINT32_TO_LE(val) ((guint32) (val)) +#define GINT32_TO_BE(val) ((gint32) GUINT32_SWAP_LE_BE (val)) +#define GUINT32_TO_BE(val) (GUINT32_SWAP_LE_BE (val)) +#define GINT64_TO_LE(val) ((gint64) (val)) +#define GUINT64_TO_LE(val) ((guint64) (val)) +#define GINT64_TO_BE(val) ((gint64) GUINT64_SWAP_LE_BE (val)) +#define GUINT64_TO_BE(val) (GUINT64_SWAP_LE_BE (val)) +#define GLONG_TO_LE(val) ((glong) GINT32_TO_LE (val)) +#define GULONG_TO_LE(val) ((gulong) GUINT32_TO_LE (val)) +#define GLONG_TO_BE(val) ((glong) GINT32_TO_BE (val)) +#define GULONG_TO_BE(val) ((gulong) GUINT32_TO_BE (val)) +#define GINT_TO_LE(val) ((gint) GINT32_TO_LE (val)) +#define GUINT_TO_LE(val) ((guint) GUINT32_TO_LE (val)) +#define GINT_TO_BE(val) ((gint) GINT32_TO_BE (val)) +#define GUINT_TO_BE(val) ((guint) GUINT32_TO_BE (val)) +#define G_BYTE_ORDER G_LITTLE_ENDIAN + +#define GLIB_SYSDEF_POLLIN =1 +#define GLIB_SYSDEF_POLLOUT =4 +#define GLIB_SYSDEF_POLLPRI =2 +#define GLIB_SYSDEF_POLLERR =8 +#define GLIB_SYSDEF_POLLHUP =16 +#define GLIB_SYSDEF_POLLNVAL =32 + +#define G_MODULE_SUFFIX "dll" + +G_END_DECLS + +#endif /* GLIBCONFIG_H */ diff --git a/graf2d/win32gdk/gdk/src/glib/glibintl.h b/graf2d/win32gdk/gdk/src/glib/glibintl.h new file mode 100644 index 0000000000000..c7a1b6acce7a4 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/glibintl.h @@ -0,0 +1,28 @@ +#ifndef __GLIBINTL_H__ +#define __GLIBINTL_H__ + +#include "config.h" + +#ifdef ENABLE_NLS + +gchar *_glib_gettext (const gchar *str); + +#include <libintl.h> +#define _(String) _glib_gettext(String) + +#ifdef gettext_noop +#define N_(String) gettext_noop(String) +#else +#define N_(String) (String) +#endif +#else /* NLS is disabled */ +#define _(String) (String) +#define N_(String) (String) +#define textdomain(String) (String) +#define gettext(String) (String) +#define dgettext(Domain,String) (String) +#define dcgettext(Domain,String,Type) (String) +#define bindtextdomain(Domain,Directory) (Domain) +#endif + +#endif /* __GLIBINTL_H__ */ diff --git a/graf2d/win32gdk/gdk/src/glib/glist.c b/graf2d/win32gdk/gdk/src/glib/glist.c new file mode 100644 index 0000000000000..3935cb1b1169c --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/glist.c @@ -0,0 +1,876 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include "glib.h" + + +#ifndef DISABLE_MEM_POOLS +struct _GAllocator /* from gmem.c */ +{ + gchar *name; + guint16 n_preallocs; + guint is_unused : 1; + guint type : 4; + GAllocator *last; + GMemChunk *mem_chunk; + GList *free_lists; /* implementation specific */ +}; + +static GAllocator *current_allocator = NULL; +G_LOCK_DEFINE_STATIC (current_allocator); + +/* HOLDS: current_allocator_lock */ +static void +g_list_validate_allocator (GAllocator *allocator) +{ + g_return_if_fail (allocator != NULL); + g_return_if_fail (allocator->is_unused == TRUE); + + if (allocator->type != G_ALLOCATOR_LIST) + { + allocator->type = G_ALLOCATOR_LIST; + if (allocator->mem_chunk) + { + g_mem_chunk_destroy (allocator->mem_chunk); + allocator->mem_chunk = NULL; + } + } + + if (!allocator->mem_chunk) + { + allocator->mem_chunk = g_mem_chunk_new (allocator->name, + sizeof (GList), + sizeof (GList) * allocator->n_preallocs, + G_ALLOC_ONLY); + allocator->free_lists = NULL; + } + + allocator->is_unused = FALSE; +} + +void +g_list_push_allocator(GAllocator *allocator) +{ + G_LOCK (current_allocator); + g_list_validate_allocator (allocator); + allocator->last = current_allocator; + current_allocator = allocator; + G_UNLOCK (current_allocator); +} + +void +g_list_pop_allocator (void) +{ + G_LOCK (current_allocator); + if (current_allocator) + { + GAllocator *allocator; + + allocator = current_allocator; + current_allocator = allocator->last; + allocator->last = NULL; + allocator->is_unused = TRUE; + } + G_UNLOCK (current_allocator); +} + +static inline GList* +_g_list_alloc (void) +{ + GList *list; + + G_LOCK (current_allocator); + if (!current_allocator) + { + GAllocator *allocator = g_allocator_new ("GLib default GList allocator", + 128); + g_list_validate_allocator (allocator); + allocator->last = NULL; + current_allocator = allocator; + } + if (!current_allocator->free_lists) + { + list = g_chunk_new (GList, current_allocator->mem_chunk); + list->data = NULL; + } + else + { + if (current_allocator->free_lists->data) + { + list = current_allocator->free_lists->data; + current_allocator->free_lists->data = list->next; + list->data = NULL; + } + else + { + list = current_allocator->free_lists; + current_allocator->free_lists = list->next; + } + } + G_UNLOCK (current_allocator); + list->next = NULL; + list->prev = NULL; + + return list; +} + +GList* +g_list_alloc (void) +{ + return _g_list_alloc (); +} + +void +g_list_free (GList *list) +{ + if (list) + { + GList *last_node = list; + +#ifdef ENABLE_GC_FRIENDLY + while (last_node->next) + { + last_node->data = NULL; + last_node->prev = NULL; + last_node = last_node->next; + } + last_node->data = NULL; + last_node->prev = NULL; +#else /* !ENABLE_GC_FRIENDLY */ + list->data = list->next; +#endif /* ENABLE_GC_FRIENDLY */ + + G_LOCK (current_allocator); + last_node->next = current_allocator->free_lists; + current_allocator->free_lists = list; + G_UNLOCK (current_allocator); + } +} + +static inline void +_g_list_free_1 (GList *list) +{ + if (list) + { + list->data = NULL; + +#ifdef ENABLE_GC_FRIENDLY + list->prev = NULL; +#endif /* ENABLE_GC_FRIENDLY */ + + G_LOCK (current_allocator); + list->next = current_allocator->free_lists; + current_allocator->free_lists = list; + G_UNLOCK (current_allocator); + } +} + +void +g_list_free_1 (GList *list) +{ + _g_list_free_1 (list); +} + +#else /* DISABLE_MEM_POOLS */ + +#define _g_list_alloc g_list_alloc +GList* +g_list_alloc (void) +{ + GList *list; + + list = g_new0 (GList, 1); + + return list; +} + +void +g_list_free (GList *list) +{ + GList *last; + + while (list) + { + last = list; + list = list->next; + g_free (last); + } +} + +#define _g_list_free_1 g_list_free_1 +void +g_list_free_1 (GList *list) +{ + g_free (list); +} + +#endif + +GList* +g_list_append (GList *list, + gpointer data) +{ + GList *new_list; + GList *last; + + new_list = _g_list_alloc (); + new_list->data = data; + + if (list) + { + last = g_list_last (list); + /* g_assert (last != NULL); */ + last->next = new_list; + new_list->prev = last; + + return list; + } + else + return new_list; +} + +GList* +g_list_prepend (GList *list, + gpointer data) +{ + GList *new_list; + + new_list = _g_list_alloc (); + new_list->data = data; + + if (list) + { + if (list->prev) + { + list->prev->next = new_list; + new_list->prev = list->prev; + } + list->prev = new_list; + new_list->next = list; + } + + return new_list; +} + +GList* +g_list_insert (GList *list, + gpointer data, + gint position) +{ + GList *new_list; + GList *tmp_list; + + if (position < 0) + return g_list_append (list, data); + else if (position == 0) + return g_list_prepend (list, data); + + tmp_list = g_list_nth (list, position); + if (!tmp_list) + return g_list_append (list, data); + + new_list = _g_list_alloc (); + new_list->data = data; + + if (tmp_list->prev) + { + tmp_list->prev->next = new_list; + new_list->prev = tmp_list->prev; + } + new_list->next = tmp_list; + tmp_list->prev = new_list; + + if (tmp_list == list) + return new_list; + else + return list; +} + +GList* +g_list_insert_before (GList *list, + GList *sibling, + gpointer data) +{ + if (!list) + { + list = g_list_alloc (); + list->data = data; + g_return_val_if_fail (sibling == NULL, list); + return list; + } + else if (sibling) + { + GList *node; + + node = g_list_alloc (); + node->data = data; + if (sibling->prev) + { + node->prev = sibling->prev; + node->prev->next = node; + node->next = sibling; + sibling->prev = node; + return list; + } + else + { + node->next = sibling; + sibling->prev = node; + g_return_val_if_fail (sibling == list, node); + return node; + } + } + else + { + GList *last; + + last = list; + while (last->next) + last = last->next; + + last->next = g_list_alloc (); + last->next->data = data; + last->next->prev = last; + + return list; + } +} + +GList * +g_list_concat (GList *list1, GList *list2) +{ + GList *tmp_list; + + if (list2) + { + tmp_list = g_list_last (list1); + if (tmp_list) + tmp_list->next = list2; + else + list1 = list2; + list2->prev = tmp_list; + } + + return list1; +} + +GList* +g_list_remove (GList *list, + gconstpointer data) +{ + GList *tmp; + + tmp = list; + while (tmp) + { + if (tmp->data != data) + tmp = tmp->next; + else + { + if (tmp->prev) + tmp->prev->next = tmp->next; + if (tmp->next) + tmp->next->prev = tmp->prev; + + if (list == tmp) + list = list->next; + + _g_list_free_1 (tmp); + + break; + } + } + return list; +} + +GList* +g_list_remove_all (GList *list, + gconstpointer data) +{ + GList *tmp = list; + + while (tmp) + { + if (tmp->data != data) + tmp = tmp->next; + else + { + GList *next = tmp->next; + + if (tmp->prev) + tmp->prev->next = next; + else + list = next; + if (next) + next->prev = tmp->prev; + + _g_list_free_1 (tmp); + tmp = next; + } + } + return list; +} + +static inline GList* +_g_list_remove_link (GList *list, + GList *link) +{ + if (link) + { + if (link->prev) + link->prev->next = link->next; + if (link->next) + link->next->prev = link->prev; + + if (link == list) + list = list->next; + + link->next = NULL; + link->prev = NULL; + } + + return list; +} + +GList* +g_list_remove_link (GList *list, + GList *link) +{ + return _g_list_remove_link (list, link); +} + +GList* +g_list_delete_link (GList *list, + GList *link) +{ + list = _g_list_remove_link (list, link); + _g_list_free_1 (link); + + return list; +} + +GList* +g_list_copy (GList *list) +{ + GList *new_list = NULL; + + if (list) + { + GList *last; + + new_list = _g_list_alloc (); + new_list->data = list->data; + last = new_list; + list = list->next; + while (list) + { + last->next = _g_list_alloc (); + last->next->prev = last; + last = last->next; + last->data = list->data; + list = list->next; + } + } + + return new_list; +} + +GList* +g_list_reverse (GList *list) +{ + GList *last; + + last = NULL; + while (list) + { + last = list; + list = last->next; + last->next = last->prev; + last->prev = list; + } + + return last; +} + +GList* +g_list_nth (GList *list, + guint n) +{ + while ((n-- > 0) && list) + list = list->next; + + return list; +} + +GList* +g_list_nth_prev (GList *list, + guint n) +{ + while ((n-- > 0) && list) + list = list->prev; + + return list; +} + +gpointer +g_list_nth_data (GList *list, + guint n) +{ + while ((n-- > 0) && list) + list = list->next; + + return list ? list->data : NULL; +} + +GList* +g_list_find (GList *list, + gconstpointer data) +{ + while (list) + { + if (list->data == data) + break; + list = list->next; + } + + return list; +} + +GList* +g_list_find_custom (GList *list, + gconstpointer data, + GCompareFunc func) +{ + g_return_val_if_fail (func != NULL, list); + + while (list) + { + if (! func (list->data, data)) + return list; + list = list->next; + } + + return NULL; +} + + +gint +g_list_position (GList *list, + GList *link) +{ + gint i; + + i = 0; + while (list) + { + if (list == link) + return i; + i++; + list = list->next; + } + + return -1; +} + +gint +g_list_index (GList *list, + gconstpointer data) +{ + gint i; + + i = 0; + while (list) + { + if (list->data == data) + return i; + i++; + list = list->next; + } + + return -1; +} + +GList* +g_list_last (GList *list) +{ + if (list) + { + while (list->next) + list = list->next; + } + + return list; +} + +GList* +g_list_first (GList *list) +{ + if (list) + { + while (list->prev) + list = list->prev; + } + + return list; +} + +guint +g_list_length (GList *list) +{ + guint length; + + length = 0; + while (list) + { + length++; + list = list->next; + } + + return length; +} + +void +g_list_foreach (GList *list, + GFunc func, + gpointer user_data) +{ + while (list) + { + GList *next = list->next; + (*func) (list->data, user_data); + list = next; + } +} + + +GList* +g_list_insert_sorted (GList *list, + gpointer data, + GCompareFunc func) +{ + GList *tmp_list = list; + GList *new_list; + gint cmp; + + g_return_val_if_fail (func != NULL, list); + + if (!list) + { + new_list = _g_list_alloc (); + new_list->data = data; + return new_list; + } + + cmp = (*func) (data, tmp_list->data); + + while ((tmp_list->next) && (cmp > 0)) + { + tmp_list = tmp_list->next; + cmp = (*func) (data, tmp_list->data); + } + + new_list = _g_list_alloc (); + new_list->data = data; + + if ((!tmp_list->next) && (cmp > 0)) + { + tmp_list->next = new_list; + new_list->prev = tmp_list; + return list; + } + + if (tmp_list->prev) + { + tmp_list->prev->next = new_list; + new_list->prev = tmp_list->prev; + } + new_list->next = tmp_list; + tmp_list->prev = new_list; + + if (tmp_list == list) + return new_list; + else + return list; +} + +static GList * +g_list_sort_merge (GList *l1, + GList *l2, + GFunc compare_func, + gboolean use_data, + gpointer user_data) +{ + GList list, *l, *lprev; + gint cmp; + + l = &list; + lprev = NULL; + + while (l1 && l2) + { + if (use_data) + cmp = ((GCompareDataFunc) compare_func) (l1->data, l2->data, user_data); + else + cmp = ((GCompareFunc) compare_func) (l1->data, l2->data); + + if (cmp <= 0) + { + l->next = l1; + l = l->next; + l->prev = lprev; + lprev = l; + l1 = l1->next; + } + else + { + l->next = l2; + l = l->next; + l->prev = lprev; + lprev = l; + l2 = l2->next; + } + } + l->next = l1 ? l1 : l2; + l->next->prev = l; + + return list.next; +} + +static GList* +g_list_sort_real (GList *list, + GFunc compare_func, + gboolean use_data, + gpointer user_data) +{ + GList *l1, *l2; + + if (!list) + return NULL; + if (!list->next) + return list; + + l1 = list; + l2 = list->next; + + while ((l2 = l2->next) != NULL) + { + if ((l2 = l2->next) == NULL) + break; + l1 = l1->next; + } + l2 = l1->next; + l1->next = NULL; + + return g_list_sort_merge (g_list_sort_real (list, compare_func, use_data, user_data), + g_list_sort_real (l2, compare_func, use_data, user_data), + compare_func, + use_data, + user_data); +} + +GList * +g_list_sort (GList *list, + GCompareFunc compare_func) +{ + return g_list_sort_real (list, (GFunc) compare_func, FALSE, NULL); + +} + +GList * +g_list_sort_with_data (GList *list, + GCompareDataFunc compare_func, + gpointer user_data) +{ + return g_list_sort_real (list, (GFunc) compare_func, TRUE, user_data); +} + +static GList* +g_list_sort2 (GList *list, + GCompareFunc compare_func) +{ + GSList *runs = NULL; + GList *tmp; + + /* Degenerate case. */ + if (!list) return NULL; + + /* Assume: list = [12,2,4,11,2,4,6,1,1,12]. */ + for (tmp = list; tmp; ) + { + GList *tmp2; + for (tmp2 = tmp; + tmp2->next && compare_func (tmp2->data, tmp2->next->data) <= 0; + tmp2 = tmp2->next) + /* Nothing */; + runs = g_slist_append (runs, tmp); + tmp = tmp2->next; + tmp2->next = NULL; + } + /* Now: runs = [[12],[2,4,11],[2,4,6],[1,1,12]]. */ + + while (runs->next) + { + /* We have more than one run. Merge pairwise. */ + GSList *dst, *src, *dstprev = NULL; + dst = src = runs; + while (src && src->next) + { + dst->data = g_list_sort_merge (src->data, + src->next->data, + (GFunc) compare_func, + FALSE, NULL); + dstprev = dst; + dst = dst->next; + src = src->next->next; + } + + /* If number of runs was odd, just keep the last. */ + if (src) + { + dst->data = src->data; + dstprev = dst; + dst = dst->next; + } + + dstprev->next = NULL; + g_slist_free (dst); + } + + /* After 1st loop: runs = [[2,4,11,12],[1,1,2,4,6,12]]. */ + /* After 2nd loop: runs = [[1,1,2,2,4,4,6,11,12,12]]. */ + + list = runs->data; + g_slist_free (runs); + return list; +} diff --git a/graf2d/win32gdk/gdk/src/glib/glist.h b/graf2d/win32gdk/gdk/src/glib/glist.h index 8f8ae939933e6..e434d6951c16d 100644 --- a/graf2d/win32gdk/gdk/src/glib/glist.h +++ b/graf2d/win32gdk/gdk/src/glib/glist.h @@ -27,7 +27,7 @@ #ifndef __G_LIST_H__ #define __G_LIST_H__ -#include <gmem.h> +#include <glib/gmem.h> G_BEGIN_DECLS @@ -42,7 +42,7 @@ struct _GList /* Doubly linked lists */ -void g_list_push_allocator (GAllocator *allocato); +void g_list_push_allocator (GAllocator *allocator); void g_list_pop_allocator (void); GList* g_list_alloc (void); void g_list_free (GList *list); @@ -57,10 +57,15 @@ GList* g_list_insert (GList *list, GList* g_list_insert_sorted (GList *list, gpointer data, GCompareFunc func); +GList* g_list_insert_before (GList *list, + GList *sibling, + gpointer data); GList* g_list_concat (GList *list1, GList *list2); GList* g_list_remove (GList *list, gconstpointer data); +GList* g_list_remove_all (GList *list, + gconstpointer data); GList* g_list_remove_link (GList *list, GList *llink); GList* g_list_delete_link (GList *list, @@ -69,6 +74,8 @@ GList* g_list_reverse (GList *list); GList* g_list_copy (GList *list); GList* g_list_nth (GList *list, guint n); +GList* g_list_nth_prev (GList *list, + guint n); GList* g_list_find (GList *list, gconstpointer data); GList* g_list_find_custom (GList *list, @@ -87,7 +94,7 @@ void g_list_foreach (GList *list, GList* g_list_sort (GList *list, GCompareFunc compare_func); GList* g_list_sort_with_data (GList *list, - GCompareFuncData compare_func, + GCompareDataFunc compare_func, gpointer user_data); gpointer g_list_nth_data (GList *list, guint n); diff --git a/graf2d/win32gdk/gdk/src/glib/gmacros.h b/graf2d/win32gdk/gdk/src/glib/gmacros.h index 633d7fa3cc84a..896948e87355c 100644 --- a/graf2d/win32gdk/gdk/src/glib/gmacros.h +++ b/graf2d/win32gdk/gdk/src/glib/gmacros.h @@ -31,6 +31,10 @@ #ifndef __G_MACROS_H__ #define __G_MACROS_H__ +/* We include stddef.h to get the system's definition of NULL + */ +#include <stddef.h> + /* Here we provide G_GNUC_EXTENSION as an alias for __extension__, * where this is valid. This allows for warningless compilation of * "long long" types even in the presence of '-ansi -pedantic'. @@ -63,6 +67,8 @@ __attribute__((const)) #define G_GNUC_UNUSED \ __attribute__((unused)) +#define G_GNUC_NO_INSTRUMENT \ + __attribute__((no_instrument_function)) #else /* !__GNUC__ */ #define G_GNUC_PRINTF( format_idx, arg_idx ) #define G_GNUC_SCANF( format_idx, arg_idx ) @@ -70,6 +76,7 @@ #define G_GNUC_NORETURN #define G_GNUC_CONST #define G_GNUC_UNUSED +#define G_GNUC_NO_INSTRUMENT #endif /* !__GNUC__ */ /* Wrap the gcc __PRETTY_FUNCTION__ and __FUNCTION__ variables with @@ -141,6 +148,11 @@ */ #define G_N_ELEMENTS(arr) (sizeof (arr) / sizeof ((arr)[0])) +/* Macros by analogy to GINT_TO_POINTER, GPOINTER_TO_INT + */ +#define GPOINTER_TO_SIZE(p) ((gsize) (p)) +#define GSIZE_TO_POINTER(s) ((gpointer) (gsize) (s)) + /* Provide convenience macros for handling structure * fields through their offsets. */ diff --git a/graf2d/win32gdk/gdk/src/glib/gmain.c b/graf2d/win32gdk/gdk/src/glib/gmain.c new file mode 100644 index 0000000000000..fe152f3a427fc --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gmain.c @@ -0,0 +1,3203 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * gmain.c: Main loop abstraction, timeouts, and idle functions + * Copyright 1998 Owen Taylor + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#include "config.h" + +/* uncomment the next line to get poll() debugging info */ +/* #define G_MAIN_POLL_DEBUG */ + +#include "glib.h" +#include <sys/types.h> +#include <time.h> +#ifdef HAVE_SYS_TIME_H +#include <sys/time.h> +#endif /* HAVE_SYS_TIME_H */ +#ifdef GLIB_HAVE_SYS_POLL_H +# include <sys/poll.h> +# undef events /* AIX 4.1.5 & 4.3.2 define this for SVR3,4 compatibility */ +# undef revents /* AIX 4.1.5 & 4.3.2 define this for SVR3,4 compatibility */ +#endif /* GLIB_HAVE_SYS_POLL_H */ +#ifdef HAVE_UNISTD_H +#include <unistd.h> +#endif /* HAVE_UNISTD_H */ +#include <errno.h> + +#ifdef G_OS_WIN32 +#define STRICT +#include <windows.h> +#endif /* G_OS_WIN32 */ + +#ifdef G_OS_BEOS +#include <net/socket.h> +#endif /* G_OS_BEOS */ + +/* Types */ + +typedef struct _GTimeoutSource GTimeoutSource; +typedef struct _GPollRec GPollRec; +typedef struct _GSourceCallback GSourceCallback; + +typedef enum +{ + G_SOURCE_READY = 1 << G_HOOK_FLAG_USER_SHIFT, + G_SOURCE_CAN_RECURSE = 1 << (G_HOOK_FLAG_USER_SHIFT + 1) +} GSourceFlags; + +#ifdef G_THREADS_ENABLED +typedef struct _GMainWaiter GMainWaiter; + +struct _GMainWaiter +{ + GCond *cond; + GMutex *mutex; +}; +#endif + +struct _GMainContext +{ +#ifdef G_THREADS_ENABLED + /* The following lock is used for both the list of sources + * and the list of poll records + */ + GStaticMutex mutex; + GCond *cond; + GThread *owner; + guint owner_count; + GSList *waiters; +#endif + + guint ref_count; + + GPtrArray *pending_dispatches; + gint timeout; /* Timeout for current iteration */ + + guint next_id; + GSource *source_list; + gint in_check_or_prepare; + + GPollRec *poll_records; + GPollRec *poll_free_list; + GMemChunk *poll_chunk; + guint n_poll_records; + GPollFD *cached_poll_array; + guint cached_poll_array_size; + +#ifdef G_THREADS_ENABLED +#ifndef G_OS_WIN32 +/* this pipe is used to wake up the main loop when a source is added. + */ + gint wake_up_pipe[2]; +#else /* G_OS_WIN32 */ + HANDLE wake_up_semaphore; +#endif /* G_OS_WIN32 */ + + GPollFD wake_up_rec; + gboolean poll_waiting; + +/* Flag indicating whether the set of fd's changed during a poll */ + gboolean poll_changed; +#endif /* G_THREADS_ENABLED */ + + GPollFunc poll_func; + + GTimeVal current_time; + gboolean time_is_current; +}; + +struct _GSourceCallback +{ + guint ref_count; + GSourceFunc func; + gpointer data; + GDestroyNotify notify; +}; + +struct _GMainLoop +{ + GMainContext *context; + gboolean is_running; + guint ref_count; +}; + +struct _GTimeoutSource +{ + GSource source; + GTimeVal expiration; + gint interval; +}; + +struct _GPollRec +{ + gint priority; + GPollFD *fd; + GPollRec *next; +}; + +#ifdef G_THREADS_ENABLED +#define LOCK_CONTEXT(context) g_static_mutex_lock (&context->mutex) +#define UNLOCK_CONTEXT(context) g_static_mutex_unlock (&context->mutex) +#define G_THREAD_SELF g_thread_self () +#else +#define LOCK_CONTEXT(context) (void)0 +#define UNLOCK_CONTEXT(context) (void)0 +#define G_THREAD_SELF NULL +#endif + +#define SOURCE_DESTROYED(source) (((source)->flags & G_HOOK_FLAG_ACTIVE) == 0) + +#define SOURCE_UNREF(source, context) \ + G_STMT_START { \ + if ((source)->ref_count > 1) \ + (source)->ref_count--; \ + else \ + g_source_unref_internal ((source), (context), TRUE); \ + } G_STMT_END + + +/* Forward declarations */ + +static void g_source_unref_internal (GSource *source, + GMainContext *context, + gboolean have_lock); +static void g_source_destroy_internal (GSource *source, + GMainContext *context, + gboolean have_lock); +static void g_main_context_poll (GMainContext *context, + gint timeout, + gint priority, + GPollFD *fds, + gint n_fds); +static void g_main_context_add_poll_unlocked (GMainContext *context, + gint priority, + GPollFD *fd); +static void g_main_context_remove_poll_unlocked (GMainContext *context, + GPollFD *fd); +static void g_main_context_wakeup_unlocked (GMainContext *context); + +static gboolean g_timeout_prepare (GSource *source, + gint *timeout); +static gboolean g_timeout_check (GSource *source); +static gboolean g_timeout_dispatch (GSource *source, + GSourceFunc callback, + gpointer user_data); +static gboolean g_idle_prepare (GSource *source, + gint *timeout); +static gboolean g_idle_check (GSource *source); +static gboolean g_idle_dispatch (GSource *source, + GSourceFunc callback, + gpointer user_data); + +G_LOCK_DEFINE_STATIC (main_loop); +static GMainContext *default_main_context; + +#if defined(G_PLATFORM_WIN32) && defined(__GNUC__) +__declspec(dllexport) +#endif +GSourceFuncs g_timeout_funcs = +{ + g_timeout_prepare, + g_timeout_check, + g_timeout_dispatch, + NULL +}; + +#if defined(G_PLATFORM_WIN32) && defined(__GNUC__) +__declspec(dllexport) +#endif +GSourceFuncs g_idle_funcs = +{ + g_idle_prepare, + g_idle_check, + g_idle_dispatch, + NULL +}; + +#ifdef HAVE_POLL +/* SunOS has poll, but doesn't provide a prototype. */ +# if defined (sun) && !defined (__SVR4) +extern gint poll (GPollFD *ufds, guint nfsd, gint timeout); +# endif /* !sun */ +#else /* !HAVE_POLL */ + +#ifdef G_OS_WIN32 + +static gint +g_poll (GPollFD *fds, + guint nfds, + gint timeout) +{ + HANDLE handles[MAXIMUM_WAIT_OBJECTS]; + gboolean poll_msgs = FALSE; + GPollFD *f; + DWORD ready; + MSG msg; + UINT timer; + gint nhandles = 0; + + for (f = fds; f < &fds[nfds]; ++f) + if (f->fd >= 0) + { + if (f->events & G_IO_IN) + { + if (f->fd == G_WIN32_MSG_HANDLE) + poll_msgs = TRUE; + else + { +#ifdef G_MAIN_POLL_DEBUG + g_print ("g_poll: waiting for %#x\n", f->fd); +#endif + handles[nhandles++] = (HANDLE) f->fd; + } + } + } + + if (timeout == -1) + timeout = INFINITE; + + if (poll_msgs) + { + /* Waiting for messages, and maybe events + * -> First PeekMessage + */ +#ifdef G_MAIN_POLL_DEBUG + g_print ("PeekMessage\n"); +#endif + if (PeekMessage (&msg, NULL, 0, 0, PM_NOREMOVE)) + ready = WAIT_OBJECT_0 + nhandles; + else + { + if (nhandles == 0) + { + /* Waiting just for messages */ + if (timeout == INFINITE) + { + /* Infinite timeout + * -> WaitMessage + */ +#ifdef G_MAIN_POLL_DEBUG + g_print ("WaitMessage\n"); +#endif + if (!WaitMessage ()) + g_warning (G_STRLOC ": WaitMessage() failed"); + ready = WAIT_OBJECT_0 + nhandles; + } + else if (timeout == 0) + { + /* Waiting just for messages, zero timeout. + * If we got here, there was no message + */ + ready = WAIT_TIMEOUT; + } + else + { + /* Waiting just for messages, some timeout + * -> Set a timer, wait for message, + * kill timer, use PeekMessage + */ + timer = SetTimer (NULL, 0, timeout, NULL); + if (timer == 0) + g_warning (G_STRLOC ": SetTimer() failed"); + else + { +#ifdef G_MAIN_POLL_DEBUG + g_print ("WaitMessage\n"); +#endif + WaitMessage (); + KillTimer (NULL, timer); +#ifdef G_MAIN_POLL_DEBUG + g_print ("PeekMessage\n"); +#endif + if (PeekMessage (&msg, NULL, 0, 0, PM_NOREMOVE) + && msg.message != WM_TIMER) + ready = WAIT_OBJECT_0; + else + ready = WAIT_TIMEOUT; + } + } + } + else + { + /* Wait for either message or event + * -> Use MsgWaitForMultipleObjects + */ +#ifdef G_MAIN_POLL_DEBUG + g_print ("MsgWaitForMultipleObjects(%d, %d)\n", nhandles, timeout); +#endif + ready = MsgWaitForMultipleObjects (nhandles, handles, FALSE, + timeout, QS_ALLINPUT); + + if (ready == WAIT_FAILED) + g_warning (G_STRLOC ": MsgWaitForMultipleObjects() failed"); + } + } + } + else if (nhandles == 0) + { + /* Wait for nothing (huh?) */ + return 0; + } + else + { + /* Wait for just events + * -> Use WaitForMultipleObjects + */ +#ifdef G_MAIN_POLL_DEBUG + g_print ("WaitForMultipleObjects(%d, %d)\n", nhandles, timeout); +#endif + ready = WaitForMultipleObjects (nhandles, handles, FALSE, timeout); + if (ready == WAIT_FAILED) + g_warning (G_STRLOC ": WaitForMultipleObjects() failed"); + } + +#ifdef G_MAIN_POLL_DEBUG + g_print ("wait returns %d%s\n", + ready, + (ready == WAIT_FAILED ? " (WAIT_FAILED)" : + (ready == WAIT_TIMEOUT ? " (WAIT_TIMEOUT)" : + (poll_msgs && ready == WAIT_OBJECT_0 + nhandles ? " (msg)" : "")))); +#endif + for (f = fds; f < &fds[nfds]; ++f) + f->revents = 0; + + if (ready == WAIT_FAILED) + return -1; + else if (ready == WAIT_TIMEOUT) + return 0; + else if (poll_msgs && ready == WAIT_OBJECT_0 + nhandles) + { + for (f = fds; f < &fds[nfds]; ++f) + if (f->fd >= 0) + { + if (f->events & G_IO_IN) + if (f->fd == G_WIN32_MSG_HANDLE) + f->revents |= G_IO_IN; + } + } +#if TEST_WITHOUT_THIS + else if (ready >= WAIT_OBJECT_0 && ready < WAIT_OBJECT_0 + nhandles) + for (f = fds; f < &fds[nfds]; ++f) + { + if ((f->events & G_IO_IN) + && f->fd == (gint) handles[ready - WAIT_OBJECT_0]) + { + f->revents |= G_IO_IN; +#ifdef G_MAIN_POLL_DEBUG + g_print ("g_poll: got event %#x\n", f->fd); +#endif +#if 0 + ResetEvent ((HANDLE) f->fd); +#endif + } + } +#endif + + return 1; +} + +#else /* !G_OS_WIN32 */ + +/* The following implementation of poll() comes from the GNU C Library. + * Copyright (C) 1994, 1996, 1997 Free Software Foundation, Inc. + */ + +#include <string.h> /* for bzero on BSD systems */ + +#ifdef HAVE_SYS_SELECT_H +#include <sys/select.h> +#endif /* HAVE_SYS_SELECT_H */ + +#ifdef G_OS_BEOS +#undef NO_FD_SET +#endif /* G_OS_BEOS */ + +#ifndef NO_FD_SET +# define SELECT_MASK fd_set +#else /* !NO_FD_SET */ +# ifndef _AIX +typedef long fd_mask; +# endif /* _AIX */ +# ifdef _IBMR2 +# define SELECT_MASK void +# else /* !_IBMR2 */ +# define SELECT_MASK int +# endif /* !_IBMR2 */ +#endif /* !NO_FD_SET */ + +static gint +g_poll (GPollFD *fds, + guint nfds, + gint timeout) +{ + struct timeval tv; + SELECT_MASK rset, wset, xset; + GPollFD *f; + int ready; + int maxfd = 0; + + FD_ZERO (&rset); + FD_ZERO (&wset); + FD_ZERO (&xset); + + for (f = fds; f < &fds[nfds]; ++f) + if (f->fd >= 0) + { + if (f->events & G_IO_IN) + FD_SET (f->fd, &rset); + if (f->events & G_IO_OUT) + FD_SET (f->fd, &wset); + if (f->events & G_IO_PRI) + FD_SET (f->fd, &xset); + if (f->fd > maxfd && (f->events & (G_IO_IN|G_IO_OUT|G_IO_PRI))) + maxfd = f->fd; + } + + tv.tv_sec = timeout / 1000; + tv.tv_usec = (timeout % 1000) * 1000; + + ready = select (maxfd + 1, &rset, &wset, &xset, + timeout == -1 ? NULL : &tv); + if (ready > 0) + for (f = fds; f < &fds[nfds]; ++f) + { + f->revents = 0; + if (f->fd >= 0) + { + if (FD_ISSET (f->fd, &rset)) + f->revents |= G_IO_IN; + if (FD_ISSET (f->fd, &wset)) + f->revents |= G_IO_OUT; + if (FD_ISSET (f->fd, &xset)) + f->revents |= G_IO_PRI; + } + } + + return ready; +} + +#endif /* !G_OS_WIN32 */ + +#endif /* !HAVE_POLL */ + +/** + * g_main_context_ref: + * @context: a #GMainContext + * + * Increases the reference count on a #GMainContext object by one. + **/ +void +g_main_context_ref (GMainContext *context) +{ + g_return_if_fail (context != NULL); + g_return_if_fail (context->ref_count > 0); + + LOCK_CONTEXT (context); + + context->ref_count++; + + UNLOCK_CONTEXT (context); +} + +static void +g_main_context_unref_and_unlock (GMainContext *context) +{ + GSource *source; + + context->ref_count--; + + if (context->ref_count != 0) + { + UNLOCK_CONTEXT (context); + return; + } + + source = context->source_list; + while (source) + { + GSource *next = source->next; + g_source_destroy_internal (source, context, TRUE); + source = next; + } + UNLOCK_CONTEXT (context); + +#ifdef G_THREADS_ENABLED + g_static_mutex_free (&context->mutex); +#endif + + g_ptr_array_free (context->pending_dispatches, TRUE); + g_free (context->cached_poll_array); + + g_mem_chunk_destroy (context->poll_chunk); + +#ifdef G_THREADS_ENABLED + if (g_thread_supported()) + { +#ifndef G_OS_WIN32 + close (context->wake_up_pipe[0]); + close (context->wake_up_pipe[1]); +#else + CloseHandle (context->wake_up_semaphore); +#endif + } +#endif + + g_free (context); +} + +/** + * g_main_context_unref: + * @context: a #GMainContext + * + * Decreases the reference count on a #GMainContext object by one. If + * the result is zero, free the context and free all associated memory. + **/ +void +g_main_context_unref (GMainContext *context) +{ + g_return_if_fail (context != NULL); + g_return_if_fail (context->ref_count > 0); + + LOCK_CONTEXT (context); + g_main_context_unref_and_unlock (context); +} + +/** + * g_main_context_new: + * + * Creates a new #GMainContext strcuture + * + * Return value: the new #GMainContext + **/ +GMainContext * +g_main_context_new () +{ + GMainContext *context = g_new0 (GMainContext, 1); + +#ifdef G_THREADS_ENABLED + g_static_mutex_init (&context->mutex); + + context->owner = NULL; + context->waiters = NULL; +#endif + + context->ref_count = 1; + + context->next_id = 1; + + context->source_list = NULL; + +#if HAVE_POLL + context->poll_func = (GPollFunc)poll; +#else + context->poll_func = g_poll; +#endif + + context->cached_poll_array = NULL; + context->cached_poll_array_size = 0; + + context->pending_dispatches = g_ptr_array_new (); + + context->time_is_current = FALSE; + +#ifdef G_THREADS_ENABLED + if (g_thread_supported ()) + { +#ifndef G_OS_WIN32 + if (pipe (context->wake_up_pipe) < 0) + g_error ("Cannot create pipe main loop wake-up: %s\n", + g_strerror (errno)); + + context->wake_up_rec.fd = context->wake_up_pipe[0]; + context->wake_up_rec.events = G_IO_IN; + g_main_context_add_poll_unlocked (context, 0, &context->wake_up_rec); +#else + context->wake_up_semaphore = CreateSemaphore (NULL, 0, 100, NULL); + if (context->wake_up_semaphore == NULL) + g_error ("Cannot create wake-up semaphore: %s", + g_win32_error_message (GetLastError ())); + context->wake_up_rec.fd = (gint) context->wake_up_semaphore; + context->wake_up_rec.events = G_IO_IN; +#ifdef G_MAIN_POLL_DEBUG + g_print ("wake-up semaphore: %#x\n", (guint) context->wake_up_semaphore); +#endif + g_main_context_add_poll_unlocked (context, 0, &context->wake_up_rec); +#endif + } +#endif + + return context; +} + +/** + * g_main_context_default: + * + * Return the default main context. This is the main context used + * for main loop functions when a main loop is not explicitly + * specified. + * + * Return value: the default main context. + **/ +GMainContext * +g_main_context_default (void) +{ + /* Slow, but safe */ + + G_LOCK (main_loop); + + if (!default_main_context) + default_main_context = g_main_context_new (); + + G_UNLOCK (main_loop); + + return default_main_context; +} + +/* Hooks for adding to the main loop */ + +/** + * g_source_new: + * @source_funcs: structure containing functions that implement + * the sources behavior. + * @struct_size: size of the #GSource structure to create + * + * Create a new GSource structure. The size is specified to + * allow creating structures derived from GSource that contain + * additional data. The size passed in must be at least + * sizeof(GSource). + * + * The source will not initially be associated with any #GMainContext + * and must be added to one with g_source_add() before it will be + * executed. + * + * Return value: the newly create #GSource + **/ +GSource * +g_source_new (GSourceFuncs *source_funcs, + guint struct_size) +{ + GSource *source; + + g_return_val_if_fail (source_funcs != NULL, NULL); + g_return_val_if_fail (struct_size >= sizeof (GSource), NULL); + + source = (GSource*) g_malloc0 (struct_size); + + source->source_funcs = source_funcs; + source->ref_count = 1; + + source->priority = G_PRIORITY_DEFAULT; + + source->flags = G_HOOK_FLAG_ACTIVE; + + /* NULL/0 initialization for all other fields */ + + return source; +} + +/* Holds context's lock + */ +static void +g_source_list_add (GSource *source, + GMainContext *context) +{ + GSource *tmp_source, *last_source; + + last_source = NULL; + tmp_source = context->source_list; + while (tmp_source && tmp_source->priority <= source->priority) + { + last_source = tmp_source; + tmp_source = tmp_source->next; + } + + source->next = tmp_source; + if (tmp_source) + tmp_source->prev = source; + + source->prev = last_source; + if (last_source) + last_source->next = source; + else + context->source_list = source; +} + +/* Holds context's lock + */ +static void +g_source_list_remove (GSource *source, + GMainContext *context) +{ + if (source->prev) + source->prev->next = source->next; + else + context->source_list = source->next; + + if (source->next) + source->next->prev = source->prev; + + source->prev = NULL; + source->next = NULL; +} + +/** + * g_source_attach: + * @source: a #GSource + * @context: a #GMainContext (if %NULL, the default context will be used) + * + * Adds a #GSource to a @context so that it will be executed within + * that context. + * + * Return value: the ID for the source within the #GMainContext + **/ +guint +g_source_attach (GSource *source, + GMainContext *context) +{ + guint result = 0; + GSList *tmp_list; + + g_return_val_if_fail (source->context == NULL, 0); + g_return_val_if_fail (!SOURCE_DESTROYED (source), 0); + + if (!context) + context = g_main_context_default (); + + LOCK_CONTEXT (context); + + source->context = context; + result = source->id = context->next_id++; + + source->ref_count++; + g_source_list_add (source, context); + + tmp_list = source->poll_fds; + while (tmp_list) + { + g_main_context_add_poll_unlocked (context, source->priority, tmp_list->data); + tmp_list = tmp_list->next; + } + +#ifdef G_THREADS_ENABLED + /* Now wake up the main loop if it is waiting in the poll() */ + g_main_context_wakeup_unlocked (context); +#endif + + UNLOCK_CONTEXT (context); + + return result; +} + +static void +g_source_destroy_internal (GSource *source, + GMainContext *context, + gboolean have_lock) +{ + if (!have_lock) + LOCK_CONTEXT (context); + + if (!SOURCE_DESTROYED (source)) + { + GSList *tmp_list; + gpointer old_cb_data; + GSourceCallbackFuncs *old_cb_funcs; + + source->flags &= ~G_HOOK_FLAG_ACTIVE; + + old_cb_data = source->callback_data; + old_cb_funcs = source->callback_funcs; + + source->callback_data = NULL; + source->callback_funcs = NULL; + + if (old_cb_funcs) + { + UNLOCK_CONTEXT (context); + old_cb_funcs->unref (old_cb_data); + LOCK_CONTEXT (context); + } + + tmp_list = source->poll_fds; + while (tmp_list) + { + g_main_context_remove_poll_unlocked (context, tmp_list->data); + tmp_list = tmp_list->next; + } + + g_source_unref_internal (source, context, TRUE); + } + + if (!have_lock) + UNLOCK_CONTEXT (context); +} + +/** + * g_source_destroy: + * @source: a #GSource + * + * Remove a source from its #GMainContext, if any, and mark it as + * destroyed. The source cannot be subsequently added to another + * context. + **/ +void +g_source_destroy (GSource *source) +{ + GMainContext *context; + + g_return_if_fail (source != NULL); + + context = source->context; + + if (context) + g_source_destroy_internal (source, context, FALSE); + else + source->flags &= ~G_HOOK_FLAG_ACTIVE; +} + +/** + * g_source_get_id: + * @source: a #GSource + * + * Return the numeric ID for a particular source. The ID of a source + * is unique within a particular main loop context. The reverse + * mapping from ID to source is done by g_main_context_find_source_by_id(). + * + * Return value: the ID for the source + **/ +guint +g_source_get_id (GSource *source) +{ + guint result; + + g_return_val_if_fail (source != NULL, 0); + g_return_val_if_fail (source->context != NULL, 0); + + LOCK_CONTEXT (source->context); + result = source->id; + UNLOCK_CONTEXT (source->context); + + return result; +} + +/** + * g_source_get_context: + * @source: a #GSource + * + * Get the #GMainContext with which the source is associated. + * Calling this function on a destroyed source is an error. + * + * Return value: the #GMainContext with which the source is associated, + * or %NULL if the context has not yet been added + * to a source. + **/ +GMainContext * +g_source_get_context (GSource *source) +{ + g_return_val_if_fail (!SOURCE_DESTROYED (source), NULL); + + return source->context; +} + +/** + * g_source_add_poll: + * @source:a #GSource + * @fd: a #GPollFD structure holding information about a file + * descriptor to watch. + * + * Add a file descriptor to the set of file descriptors polled for + * this source. This is usually combined with g_source_new() to add an + * event source. The event source's check function will typically test + * the revents field in the #GPollFD struct and return %TRUE if events need + * to be processed. + **/ +void +g_source_add_poll (GSource *source, + GPollFD *fd) +{ + GMainContext *context; + + g_return_if_fail (source != NULL); + g_return_if_fail (fd != NULL); + g_return_if_fail (!SOURCE_DESTROYED (source)); + + context = source->context; + + if (context) + LOCK_CONTEXT (context); + + source->poll_fds = g_slist_prepend (source->poll_fds, fd); + + if (context) + { + g_main_context_add_poll_unlocked (context, source->priority, fd); + UNLOCK_CONTEXT (context); + } +} + +/** + * g_source_remove_poll: + * @source:a #GSource + * @fd: a #GPollFD structure previously passed to g_source_poll. + * + * Remove a file descriptor from the set of file descriptors polled for + * this source. + **/ +void +g_source_remove_poll (GSource *source, + GPollFD *fd) +{ + GMainContext *context; + + g_return_if_fail (source != NULL); + g_return_if_fail (fd != NULL); + g_return_if_fail (!SOURCE_DESTROYED (source)); + + context = source->context; + + if (context) + LOCK_CONTEXT (context); + + source->poll_fds = g_slist_remove (source->poll_fds, fd); + + if (context) + { + g_main_context_remove_poll_unlocked (context, fd); + UNLOCK_CONTEXT (context); + } +} + +/** + * g_source_set_callback_indirect: + * @source: the source + * @callback_data: pointer to callback data "object" + * @callback_funcs: functions for reference counting callback_data + * and getting the callback and data + * + * Set the callback function storing the data as a refcounted callback + * "object". This is used to implement g_source_set_callback_closure() + * and internally. Note that calling g_source_set_callback_indirect() assumes + * an initial reference count on @callback_data, and thus + * @callback_funcs->unref will eventually be called once more + * than @callback_funcs->ref. + **/ +void +g_source_set_callback_indirect (GSource *source, + gpointer callback_data, + GSourceCallbackFuncs *callback_funcs) +{ + GMainContext *context; + gpointer old_cb_data; + GSourceCallbackFuncs *old_cb_funcs; + + g_return_if_fail (source != NULL); + g_return_if_fail (callback_funcs != NULL || callback_data == NULL); + + context = source->context; + + if (context) + LOCK_CONTEXT (context); + + old_cb_data = source->callback_data; + old_cb_funcs = source->callback_funcs; + + source->callback_data = callback_data; + source->callback_funcs = callback_funcs; + + if (context) + UNLOCK_CONTEXT (context); + + if (old_cb_funcs) + old_cb_funcs->unref (old_cb_data); +} + +static void +g_source_callback_ref (gpointer cb_data) +{ + GSourceCallback *callback = cb_data; + + callback->ref_count++; +} + + +static void +g_source_callback_unref (gpointer cb_data) +{ + GSourceCallback *callback = cb_data; + + callback->ref_count--; + if (callback->ref_count == 0) + { + if (callback->notify) + callback->notify (callback->data); + g_free (callback); + } +} + +static void +g_source_callback_get (gpointer cb_data, + GSource *source, + GSourceFunc *func, + gpointer *data) +{ + GSourceCallback *callback = cb_data; + + *func = callback->func; + *data = callback->data; +} + +static GSourceCallbackFuncs g_source_callback_funcs = { + g_source_callback_ref, + g_source_callback_unref, + g_source_callback_get, +}; + +/** + * g_source_set_callback: + * @source: the source + * @func: a callback function + * @data: the data to pass to callback function + * @notify: a function to call when @data is no longer in use, or %NULL. + * + * Set the callback function for a source. + **/ +void +g_source_set_callback (GSource *source, + GSourceFunc func, + gpointer data, + GDestroyNotify notify) +{ + GSourceCallback *new_callback; + + g_return_if_fail (source != NULL); + + new_callback = g_new (GSourceCallback, 1); + + new_callback->ref_count = 1; + new_callback->func = func; + new_callback->data = data; + new_callback->notify = notify; + + g_source_set_callback_indirect (source, new_callback, &g_source_callback_funcs); +} + +/** + * g_source_set_priority: + * @source: a #GSource + * @priority: the new priority. + * + * Set the priority of a source. While the main loop is being + * run, a source will + **/ +void +g_source_set_priority (GSource *source, + gint priority) +{ + GSList *tmp_list; + GMainContext *context; + + g_return_if_fail (source != NULL); + + context = source->context; + + if (context) + LOCK_CONTEXT (context); + + source->priority = priority; + + if (context) + { + source->next = NULL; + source->prev = NULL; + + tmp_list = source->poll_fds; + while (tmp_list) + { + g_main_context_remove_poll_unlocked (context, tmp_list->data); + g_main_context_add_poll_unlocked (context, priority, tmp_list->data); + + tmp_list = tmp_list->next; + } + + UNLOCK_CONTEXT (source->context); + } +} + +/** + * g_source_get_priority: + * @source: a #GSource + * + * Gets the priority of a surce + * + * Return value: the priority of the source + **/ +gint +g_source_get_priority (GSource *source) +{ + g_return_val_if_fail (source != NULL, 0); + + return source->priority; +} + +/** + * g_source_set_can_recurse: + * @source: a #GSource + * @can_recurse: whether recursion is allowed for this source + * + * Sets whether a source can be called recursively. If @can_recurse is + * %TRUE, then while the source is being dispatched then this source + * will be processed normally. Otherwise, all processing of this + * source is blocked until the dispatch function returns. + **/ +void +g_source_set_can_recurse (GSource *source, + gboolean can_recurse) +{ + GMainContext *context; + + g_return_if_fail (source != NULL); + + context = source->context; + + if (context) + LOCK_CONTEXT (context); + + if (can_recurse) + source->flags |= G_SOURCE_CAN_RECURSE; + else + source->flags &= ~G_SOURCE_CAN_RECURSE; + + if (context) + UNLOCK_CONTEXT (context); +} + +/** + * g_source_get_can_recurse: + * @source: a #GSource + * + * Checks whether a source is allowed to be called recursively. + * see g_source_set_can_recurse. + * + * Return value: whether recursion is allowed. + **/ +gboolean +g_source_get_can_recurse (GSource *source) +{ + g_return_val_if_fail (source != NULL, FALSE); + + return (source->flags & G_SOURCE_CAN_RECURSE) != 0; +} + +/** + * g_source_ref: + * @source: a #GSource + * + * Increases the reference count on a source by one. + * + * Return value: @source + **/ +GSource * +g_source_ref (GSource *source) +{ + GMainContext *context; + + g_return_val_if_fail (source != NULL, NULL); + + context = source->context; + + if (context) + LOCK_CONTEXT (context); + + source->ref_count++; + + if (context) + UNLOCK_CONTEXT (context); + + return source; +} + +/* g_source_unref() but possible to call within context lock + */ +static void +g_source_unref_internal (GSource *source, + GMainContext *context, + gboolean have_lock) +{ + gpointer old_cb_data = NULL; + GSourceCallbackFuncs *old_cb_funcs = NULL; + + g_return_if_fail (source != NULL); + + if (!have_lock && context) + LOCK_CONTEXT (context); + + source->ref_count--; + if (source->ref_count == 0) + { + old_cb_data = source->callback_data; + old_cb_funcs = source->callback_funcs; + + source->callback_data = NULL; + source->callback_funcs = NULL; + + if (context && !SOURCE_DESTROYED (source)) + { + g_warning (G_STRLOC ": ref_count == 0, but source is still attached to a context!"); + source->ref_count++; + } + else if (context) + g_source_list_remove (source, context); + + if (source->source_funcs->finalize) + source->source_funcs->finalize (source); + + g_slist_free (source->poll_fds); + source->poll_fds = NULL; + g_free (source); + } + + if (!have_lock && context) + UNLOCK_CONTEXT (context); + + if (old_cb_funcs) + { + if (have_lock) + UNLOCK_CONTEXT (context); + + old_cb_funcs->unref (old_cb_data); + + if (have_lock) + LOCK_CONTEXT (context); + } +} + +/** + * g_source_unref: + * @source: a #GSource + * + * Decreases the reference count of a source by one. If the + * resulting reference count is zero the source and associated + * memory will be destroyed. + **/ +void +g_source_unref (GSource *source) +{ + g_return_if_fail (source != NULL); + + g_source_unref_internal (source, source->context, FALSE); +} + +/** + * g_main_context_find_source_by_id: + * @context: a #GMainContext (if %NULL, the default context will be used) + * @id: the source ID, as returned by g_source_get_id() + * + * Finds a #GSource given a pair of context and ID + * + * Return value: the #GSource if found, otherwise, %NULL + **/ +GSource * +g_main_context_find_source_by_id (GMainContext *context, + guint id) +{ + GSource *source; + + g_return_val_if_fail (id > 0, FALSE); + + if (context == NULL) + context = g_main_context_default (); + + LOCK_CONTEXT (context); + + source = context->source_list; + while (source) + { + if (!SOURCE_DESTROYED (source) && + source->id == id) + break; + source = source->next; + } + + UNLOCK_CONTEXT (context); + + return source; +} + +/** + * g_main_context_find_source_by_funcs_user_data: + * @context: a #GMainContext (if %NULL, the default context will be used). + * @funcs: the @source_funcs passed to g_source_new(). + * @user_data: the user data from the callback. + * + * Finds a source with the given source functions and user data. If + * multiple sources exist with the same source function and user data, + * the first one found will be returned. + * + * Return value: the source, if one was found, otherwise %NULL + **/ +GSource * +g_main_context_find_source_by_funcs_user_data (GMainContext *context, + GSourceFuncs *funcs, + gpointer user_data) +{ + GSource *source; + + g_return_val_if_fail (funcs != NULL, FALSE); + + if (context == NULL) + context = g_main_context_default (); + + LOCK_CONTEXT (context); + + source = context->source_list; + while (source) + { + if (!SOURCE_DESTROYED (source) && + source->source_funcs == funcs && + source->callback_funcs) + { + GSourceFunc callback; + gpointer callback_data; + + source->callback_funcs->get (source->callback_data, source, &callback, &callback_data); + + if (callback_data == user_data) + break; + } + source = source->next; + } + + UNLOCK_CONTEXT (context); + + return source; +} + +/** + * g_main_context_find_source_by_user_data: + * @context: a #GMainContext + * @user_data: the user_data for the callback. + * + * Finds a source with the given user data for the callback. If + * multiple sources exist with the same user data, the first + * one found will be returned. + * + * Return value: the source, if one was found, otherwise %NULL + **/ +GSource * +g_main_context_find_source_by_user_data (GMainContext *context, + gpointer user_data) +{ + GSource *source; + + if (context == NULL) + context = g_main_context_default (); + + LOCK_CONTEXT (context); + + source = context->source_list; + while (source) + { + if (!SOURCE_DESTROYED (source) && + source->callback_funcs) + { + GSourceFunc callback; + gpointer callback_data = NULL; + + source->callback_funcs->get (source->callback_data, source, &callback, &callback_data); + + if (callback_data == user_data) + break; + } + source = source->next; + } + + UNLOCK_CONTEXT (context); + + return source; +} + +/** + * g_source_remove: + * @tag: the id of the source to remove. + * + * Removes the source with the given id from the default main + * context. The id of a #GSource is given by g_source_get_id(), + * or will be returned by the functions g_source_attach(), + * g_idle_add(), g_idle_add_full(), g_timeout_add(), + * g_timeout_add_full(), g_io_add_watch, and g_io_add_watch_full(). + * + * See also g_source_destroy(). + * + * Return value: %TRUE if the source was found and removed. + **/ +gboolean +g_source_remove (guint tag) +{ + GSource *source; + + g_return_val_if_fail (tag > 0, FALSE); + + source = g_main_context_find_source_by_id (NULL, tag); + if (source) + g_source_destroy (source); + + return source != NULL; +} + +/** + * g_source_remove_by_user_data: + * @user_data: the user_data for the callback. + * + * Removes a source from the default main loop context given the user + * data for the callback. If multiple sources exist with the same user + * data, only one will be destroyed. + * + * Return value: %TRUE if a source was found and removed. + **/ +gboolean +g_source_remove_by_user_data (gpointer user_data) +{ + GSource *source; + + source = g_main_context_find_source_by_user_data (NULL, user_data); + if (source) + { + g_source_destroy (source); + return TRUE; + } + else + return FALSE; +} + +/** + * g_source_remove_by_funcs_user_data: + * @funcs: The @source_funcs passed to g_source_new() + * @user_data: the user data for the callback + * + * Removes a source from the default main loop context given the + * source functions and user data. If multiple sources exist with the + * same source functions and user data, only one will be destroyed. + * + * Return value: %TRUE if a source was found and removed. + **/ +gboolean +g_source_remove_by_funcs_user_data (GSourceFuncs *funcs, + gpointer user_data) +{ + GSource *source; + + g_return_val_if_fail (funcs != NULL, FALSE); + + source = g_main_context_find_source_by_funcs_user_data (NULL, funcs, user_data); + if (source) + { + g_source_destroy (source); + return TRUE; + } + else + return FALSE; +} + +/** + * g_get_current_time: + * @result: #GTimeVal structure in which to store current time. + * + * Equivalent to Unix's <function>gettimeofday()</function>, but portable + **/ +void +g_get_current_time (GTimeVal *result) +{ +#ifndef G_OS_WIN32 + struct timeval r; + + g_return_if_fail (result != NULL); + + /*this is required on alpha, there the timeval structs are int's + not longs and a cast only would fail horribly*/ + gettimeofday (&r, NULL); + result->tv_sec = r.tv_sec; + result->tv_usec = r.tv_usec; +#else + /* Avoid calling time() except for the first time. + * GetTickCount() should be pretty fast and low-level? + * I could also use ftime() but it seems unnecessarily overheady. + */ + static DWORD start_tick = 0; + static time_t start_time; + DWORD tick; + + g_return_if_fail (result != NULL); + + if (start_tick == 0) + { + start_tick = GetTickCount (); + time (&start_time); + } + + tick = GetTickCount (); + + result->tv_sec = (tick - start_tick) / 1000 + start_time; + result->tv_usec = ((tick - start_tick) % 1000) * 1000; +#endif +} + +/* Running the main loop */ + +/* HOLDS: context's lock */ +static void +g_main_dispatch (GMainContext *context) +{ + guint i; + + for (i = 0; i < context->pending_dispatches->len; i++) + { + GSource *source = context->pending_dispatches->pdata[i]; + + context->pending_dispatches->pdata[i] = NULL; + g_assert (source); + + source->flags &= ~G_SOURCE_READY; + + if (!SOURCE_DESTROYED (source)) + { + gboolean was_in_call; + gpointer user_data = NULL; + GSourceFunc callback = NULL; + GSourceCallbackFuncs *cb_funcs; + gpointer cb_data; + gboolean need_destroy; + + gboolean (*dispatch) (GSource *, + GSourceFunc, + gpointer); + + dispatch = source->source_funcs->dispatch; + cb_funcs = source->callback_funcs; + cb_data = source->callback_data; + + if (cb_funcs) + cb_funcs->ref (cb_data); + + was_in_call = source->flags & G_HOOK_FLAG_IN_CALL; + source->flags |= G_HOOK_FLAG_IN_CALL; + + if (cb_funcs) + cb_funcs->get (cb_data, source, &callback, &user_data); + + UNLOCK_CONTEXT (context); + + need_destroy = ! dispatch (source, + callback, + user_data); + LOCK_CONTEXT (context); + + if (cb_funcs) + cb_funcs->unref (cb_data); + + if (!was_in_call) + source->flags &= ~G_HOOK_FLAG_IN_CALL; + + /* Note: this depends on the fact that we can't switch + * sources from one main context to another + */ + if (need_destroy && !SOURCE_DESTROYED (source)) + { + g_assert (source->context == context); + g_source_destroy_internal (source, context, TRUE); + } + } + + SOURCE_UNREF (source, context); + } + + g_ptr_array_set_size (context->pending_dispatches, 0); +} + +/* Holds context's lock */ +static inline GSource * +next_valid_source (GMainContext *context, + GSource *source) +{ + GSource *new_source = source ? source->next : context->source_list; + + while (new_source) + { + if (!SOURCE_DESTROYED (new_source)) + { + new_source->ref_count++; + break; + } + + new_source = new_source->next; + } + + if (source) + SOURCE_UNREF (source, context); + + return new_source; +} + +/** + * g_main_context_acquire: + * @context: a #GMainContext + * + * Tries to become the owner of the specified context. + * If some other context is the owner of the context, + * returns %FALSE immediately. Ownership is properly + * recursive: the owner can require ownership again + * and will release ownership when g_main_context_release() + * is called as many times as g_main_context_acquire(). + * + * You must be the owner of a context before you + * can call g_main_context_prepare(), g_main_context_query(), + * g_main_context_check(), g_main_context_dispatch(). + * + * Return value: %TRUE if the operation succeeded, and + * this thread is now the owner of @context. + **/ +gboolean +g_main_context_acquire (GMainContext *context) +{ +#ifdef G_THREAD_ENABLED + gboolean result = FALSE; + GThread *self = G_THREAD_SELF; + + if (context == NULL) + context = g_main_context_default (); + + LOCK_CONTEXT (context); + + if (!context->owner) + { + context->owner = self; + g_assert (context->owner_count == 0); + } + + if (context->owner == self) + { + context->owner_count++; + result = TRUE; + } + + UNLOCK_CONTEXT (context); + + return result; +#else /* !G_THREAD_ENABLED */ + return TRUE; +#endif /* G_THREAD_ENABLED */ +} + +/** + * g_main_context_release: + * @context: a #GMainContext + * + * Release ownership of a context previously acquired by this thread + * with g_main_context_acquire(). If the context was acquired multiple + * times, the only release ownership when g_main_context_release() + * is called as many times as it was acquired. + **/ +void +g_main_context_release (GMainContext *context) +{ +#ifdef G_THREAD_ENABLED + if (context == NULL) + context = g_main_context_default (); + + LOCK_CONTEXT (context); + + context->owner_count--; + if (context->owner_count == 0) + { + context->owner = NULL; + + if (context->waiters) + { + GMainWaiter *waiter = context->waiters->data; + gboolean loop_internal_waiter = + (waiter->mutex == g_static_mutex_get_mutex (&context->mutex)); + context->waiters = g_slist_delete_link (context->waiters, + context->waiters); + if (!loop_internal_waiter) + g_mutex_lock (waiter->mutex); + + g_cond_signal (waiter->cond); + + if (!loop_internal_waiter) + g_mutex_unlock (waiter->mutex); + } + } + + UNLOCK_CONTEXT (context); + + return result; +#endif /* G_THREAD_ENABLED */ +} + +/** + * g_main_context_wait: + * @context: a #GMainContext + * @cond: a condition variable + * @mutex: a mutex, currently held + * + * Tries to become the owner of the specified context, + * as with g_main_context_acquire. But if another thread + * is the owner, atomically drop @mutex and wait on + * @cond until wait until that owner releases + * ownership or until @cond is signaled, then + * try again (once) to become the owner. + * + * Return value: %TRUE if the operation succeeded, and + * this thread is now the owner of @context. + **/ +gboolean +g_main_context_wait (GMainContext *context, + GCond *cond, + GMutex *mutex) +{ +#ifdef G_THREAD_ENABLED + gboolean result = FALSE; + GThread *self = G_THREAD_SELF; + gboolean loop_internal_waiter; + + if (context == NULL) + context = g_main_context_default (); + + loop_internal_waiter = (mutex == g_static_mutex_get_mutex (&context->mutex)); + + if (!loop_internal_waiter) + LOCK_CONTEXT (context); + + if (context->owner && context->owner != self) + { + GMainWaiter waiter; + + waiter.cond = cond; + waiter.mutex = mutex; + + context->waiters = g_slist_append (context->waiters, &waiter); + + if (!loop_internal_waiter) + UNLOCK_CONTEXT (context); + g_cond_wait (cond, mutex); + if (!loop_internal_waiter) + LOCK_CONTEXT (context); + + context->waiters = g_slist_remove (context->waiters, &waiter); + } + + if (!context->owner) + { + context->owner = self; + g_assert (context->owner_count == 0); + } + + if (context->owner == self) + { + context->owner_count++; + result = TRUE; + } + + if (!loop_internal_waiter) + UNLOCK_CONTEXT (context); + + return result; +#else /* !G_THREAD_ENABLED */ + return TRUE; +#endif /* G_THREAD_ENABLED */ +} + +/** + * g_main_context_prepare: + * @context: a #GMainContext + * @priority: location to store priority of highest priority + * source already ready. + * + * Prepares to poll sources within a main loop. The resulting information + * for polling is determined by calling g_main_context_query (). + * + * Return value: %TRUE if some source is ready to be dispatched + * prior to polling. + **/ +gboolean +g_main_context_prepare (GMainContext *context, + gint *priority) +{ + gint n_ready = 0; + gint current_priority = G_MAXINT; + GSource *source; + + if (context == NULL) + context = g_main_context_default (); + + LOCK_CONTEXT (context); + + context->time_is_current = FALSE; + + if (context->in_check_or_prepare) + { + g_warning ("g_main_context_prepare() called recursively from within a source's check() or " + "prepare() member."); + UNLOCK_CONTEXT (context); + return FALSE; + } + +#ifdef G_THREADS_ENABLED + if (context->poll_waiting) + { + g_warning("g_main_context_prepare(): main loop already active in another thread"); + UNLOCK_CONTEXT (context); + return FALSE; + } + + context->poll_waiting = TRUE; +#endif /* G_THREADS_ENABLED */ + +#if 0 + /* If recursing, finish up current dispatch, before starting over */ + if (context->pending_dispatches) + { + if (dispatch) + g_main_dispatch (context, ¤t_time); + + UNLOCK_CONTEXT (context); + return TRUE; + } +#endif + + /* If recursing, clear list of pending dispatches */ + g_ptr_array_set_size (context->pending_dispatches, 0); + + /* Prepare all sources */ + + context->timeout = -1; + + source = next_valid_source (context, NULL); + while (source) + { + gint source_timeout = -1; + + if ((n_ready > 0) && (source->priority > current_priority)) + { + SOURCE_UNREF (source, context); + break; + } + if ((source->flags & G_HOOK_FLAG_IN_CALL) && !(source->flags & G_SOURCE_CAN_RECURSE)) + goto next; + + if (!(source->flags & G_SOURCE_READY)) + { + gboolean result; + gboolean (*prepare) (GSource *source, + gint *timeout); + + prepare = source->source_funcs->prepare; + context->in_check_or_prepare++; + UNLOCK_CONTEXT (context); + + result = (*prepare) (source, &source_timeout); + + LOCK_CONTEXT (context); + context->in_check_or_prepare--; + + if (result) + source->flags |= G_SOURCE_READY; + } + + if (source->flags & G_SOURCE_READY) + { + n_ready++; + current_priority = source->priority; + context->timeout = 0; + } + + if (source_timeout >= 0) + { + if (context->timeout < 0) + context->timeout = source_timeout; + else + context->timeout = MIN (context->timeout, source_timeout); + } + + next: + source = next_valid_source (context, source); + } + + UNLOCK_CONTEXT (context); + + if (priority) + *priority = current_priority; + + return (n_ready > 0); +} + +/** + * g_main_context_query: + * @context: a #GMainContext + * @max_priority: maximum priority source to check + * @timeout: location to store timeout to be used in polling + * @fds: location to store #GPollFD records that need to be polled. + * @n_fds: length of @fds. + * + * Determines information necessary to poll this main loop. + * + * Return value: the number of records actually stored in @fds, + * or, if more than @n_fds records need to be stored, the number + * of records that need to be stored. + **/ +gint +g_main_context_query (GMainContext *context, + gint max_priority, + gint *timeout, + GPollFD *fds, + gint n_fds) +{ + gint n_poll; + GPollRec *pollrec; + + LOCK_CONTEXT (context); + + pollrec = context->poll_records; + n_poll = 0; + while (pollrec && max_priority >= pollrec->priority) + { + if (pollrec->fd->events) + { + if (n_poll < n_fds) + { + fds[n_poll].fd = pollrec->fd->fd; + /* In direct contradiction to the Unix98 spec, IRIX runs into + * difficulty if you pass in POLLERR, POLLHUP or POLLNVAL + * flags in the events field of the pollfd while it should + * just ignoring them. So we mask them out here. + */ + fds[n_poll].events = pollrec->fd->events & ~(G_IO_ERR|G_IO_HUP|G_IO_NVAL); + fds[n_poll].revents = 0; + } + n_poll++; + } + + pollrec = pollrec->next; + } + +#ifdef G_THREADS_ENABLED + context->poll_changed = FALSE; +#endif + + if (timeout) + { + *timeout = context->timeout; + if (timeout != 0) + context->time_is_current = FALSE; + } + + UNLOCK_CONTEXT (context); + + return n_poll; +} + +/** + * g_main_context_check: + * @context: a #GMainContext + * @max_priority: the maximum numerical priority of sources to check + * @fds: array of #GPollFD's that was passed to the last call to + * g_main_context_query() + * @n_fds: return value of g_main_context_query() + * + * Pass the results of polling back to the main loop. + * + * Return value: %TRUE if some sources are ready to be dispatched. + **/ +gboolean +g_main_context_check (GMainContext *context, + gint max_priority, + GPollFD *fds, + gint n_fds) +{ + GSource *source; + GPollRec *pollrec; + gint n_ready = 0; + gint i; + + LOCK_CONTEXT (context); + + if (context->in_check_or_prepare) + { + g_warning ("g_main_context_check() called recursively from within a source's check() or " + "prepare() member."); + UNLOCK_CONTEXT (context); + return FALSE; + } + +#ifdef G_THREADS_ENABLED + if (!context->poll_waiting) + { +#ifndef G_OS_WIN32 + gchar c; + read (context->wake_up_pipe[0], &c, 1); +#endif + } + else + context->poll_waiting = FALSE; + + /* If the set of poll file descriptors changed, bail out + * and let the main loop rerun + */ + if (context->poll_changed) + { + UNLOCK_CONTEXT (context); + return 0; + } +#endif /* G_THREADS_ENABLED */ + + pollrec = context->poll_records; + i = 0; + while (i < n_fds) + { + if (pollrec->fd->events) + { + pollrec->fd->revents = fds[i].revents; + i++; + } + pollrec = pollrec->next; + } + + source = next_valid_source (context, NULL); + while (source) + { + if ((n_ready > 0) && (source->priority > max_priority)) + { + SOURCE_UNREF (source, context); + break; + } + if ((source->flags & G_HOOK_FLAG_IN_CALL) && !(source->flags & G_SOURCE_CAN_RECURSE)) + goto next; + + if (!(source->flags & G_SOURCE_READY)) + { + gboolean result; + gboolean (*check) (GSource *source); + + check = source->source_funcs->check; + + context->in_check_or_prepare++; + UNLOCK_CONTEXT (context); + + result = (*check) (source); + + LOCK_CONTEXT (context); + context->in_check_or_prepare--; + + if (result) + source->flags |= G_SOURCE_READY; + } + + if (source->flags & G_SOURCE_READY) + { + source->ref_count++; + g_ptr_array_add (context->pending_dispatches, source); + + n_ready++; + } + + next: + source = next_valid_source (context, source); + } + + UNLOCK_CONTEXT (context); + + return n_ready > 0; +} + +/** + * g_main_context_dispatch: + * @context: a #GMainContext + * + * Dispatch all pending sources() + **/ +void +g_main_context_dispatch (GMainContext *context) +{ + LOCK_CONTEXT (context); + + if (context->pending_dispatches->len > 0) + { + g_main_dispatch (context); + } + + UNLOCK_CONTEXT (context); +} + +/* HOLDS context lock */ +static gboolean +g_main_context_iterate (GMainContext *context, + gboolean block, + gboolean dispatch, + GThread *self) +{ + gint max_priority; + gint timeout; + gboolean some_ready; + gint nfds, allocated_nfds; + GPollFD *fds = NULL; + + UNLOCK_CONTEXT (context); + +#ifdef G_THREADS_ENABLED + if (!g_main_context_acquire (context)) + { + gboolean got_ownership; + + g_return_val_if_fail (g_thread_supported (), FALSE); + + if (!block) + return FALSE; + + LOCK_CONTEXT (context); + + if (!context->cond) + context->cond = g_cond_new (); + + got_ownership = g_main_context_wait (context, + context->cond, + g_static_mutex_get_mutex (&context->mutex)); + + if (!got_ownership) + { + UNLOCK_CONTEXT (context); + return FALSE; + } + } + else + LOCK_CONTEXT (context); +#endif /* G_THREADS_ENABLED */ + + if (!context->cached_poll_array) + { + context->cached_poll_array_size = context->n_poll_records; + context->cached_poll_array = g_new (GPollFD, context->n_poll_records); + } + + allocated_nfds = context->cached_poll_array_size; + fds = context->cached_poll_array; + + UNLOCK_CONTEXT (context); + + some_ready = g_main_context_prepare (context, &max_priority); + + while ((nfds = g_main_context_query (context, max_priority, &timeout, fds, + allocated_nfds)) > allocated_nfds) + { + LOCK_CONTEXT (context); + g_free (fds); + context->cached_poll_array_size = allocated_nfds = nfds; + context->cached_poll_array = fds = g_new (GPollFD, nfds); + UNLOCK_CONTEXT (context); + } + + if (!block) + timeout = 0; + + g_main_context_poll (context, timeout, max_priority, fds, nfds); + + g_main_context_check (context, max_priority, fds, nfds); + + if (dispatch) + g_main_context_dispatch (context); + +#ifdef G_THREADS_ENABLED + g_main_context_release (context); +#endif /* G_THREADS_ENABLED */ + + LOCK_CONTEXT (context); + + return some_ready; +} + +/** + * g_main_context_pending: + * @context: a #GMainContext (if %NULL, the default context will be used) + * + * Check if any sources have pending events for the given context. + * + * Return value: %TRUE if events are pending. + **/ +gboolean +g_main_context_pending (GMainContext *context) +{ + gboolean retval; + + if (!context) + context = g_main_context_default(); + + LOCK_CONTEXT (context); + retval = g_main_context_iterate (context, FALSE, FALSE, G_THREAD_SELF); + UNLOCK_CONTEXT (context); + + return retval; +} + +/** + * g_main_context_iteration: + * @context: a #GMainContext (if %NULL, the default context will be used) + * @may_block: whether the call may block. + * + * Run a single iteration for the given main loop. This involves + * checking to see if any event sources are ready to be processed, + * then if no events sources are ready and @may_block is %TRUE, waiting + * for a source to become ready, then dispatching the highest priority + * events sources that are ready. Note that even when @may_block is %TRUE, + * it is still possible for g_main_context_iteration() to return + * %FALSE, since the the wait may be interrupted for other + * reasons than an event source becoming ready. + * + * Return value: %TRUE if events were dispatched. + **/ +gboolean +g_main_context_iteration (GMainContext *context, gboolean may_block) +{ + gboolean retval; + + if (!context) + context = g_main_context_default(); + + LOCK_CONTEXT (context); + retval = g_main_context_iterate (context, may_block, TRUE, G_THREAD_SELF); + UNLOCK_CONTEXT (context); + + return retval; +} + +/** + * g_main_loop_new: + * @context: a #GMainContext (if %NULL, the default context will be used). + * @is_running: set to TRUE to indicate that the loop is running. This + * is not very important since calling g_main_run() will set this to + * TRUE anyway. + * + * Create a new #GMainLoop structure + * + * Return value: + **/ +GMainLoop * +g_main_loop_new (GMainContext *context, + gboolean is_running) +{ + GMainLoop *loop; + + if (!context) + context = g_main_context_default(); + + g_main_context_ref (context); + + loop = g_new0 (GMainLoop, 1); + loop->context = context; + loop->is_running = is_running != FALSE; + loop->ref_count = 1; + + return loop; +} + +/** + * g_main_loop_ref: + * @loop: a #GMainLoop + * + * Increase the reference count on a #GMainLoop object by one. + * + * Return value: @loop + **/ +GMainLoop * +g_main_loop_ref (GMainLoop *loop) +{ + g_return_val_if_fail (loop != NULL, NULL); + g_return_val_if_fail (loop->ref_count > 0, NULL); + + LOCK_CONTEXT (loop->context); + loop->ref_count++; + UNLOCK_CONTEXT (loop->context); + + return loop; +} + +static void +g_main_loop_unref_and_unlock (GMainLoop *loop) +{ + loop->ref_count--; + if (loop->ref_count == 0) + { + /* When the ref_count is 0, there can be nobody else using the + * loop, so it is safe to unlock before destroying. + */ + g_main_context_unref_and_unlock (loop->context); + g_free (loop); + } + else + UNLOCK_CONTEXT (loop->context); +} + +/** + * g_main_loop_unref: + * @loop: a #GMainLoop + * + * Decreases the reference count on a #GMainLoop object by one. If + * the result is zero, free the loop and free all associated memory. + **/ +void +g_main_loop_unref (GMainLoop *loop) +{ + g_return_if_fail (loop != NULL); + g_return_if_fail (loop->ref_count > 0); + + LOCK_CONTEXT (loop->context); + + g_main_loop_unref_and_unlock (loop); +} + +/** + * g_main_loop_run: + * @loop: a #GMainLoop + * + * Run a main loop until g_main_quit() is called on the loop. + * If this is called for the thread of the loop's #GMainContext, + * it will process events from the loop, otherwise it will + * simply wait. + **/ +void +g_main_loop_run (GMainLoop *loop) +{ + GThread *self = G_THREAD_SELF; + + g_return_if_fail (loop != NULL); + g_return_if_fail (loop->ref_count > 0); + +#ifdef G_THREADS_ENABLED + if (!g_main_context_acquire (loop->context)) + { + gboolean got_ownership = FALSE; + + /* Another thread owns this context */ + if (!g_thread_supported ()) + { + g_warning ("g_main_loop_run() was called from second thread but" + "g_thread_init() was never called."); + return; + } + + LOCK_CONTEXT (loop->context); + + loop->ref_count++; + + if (!loop->is_running) + loop->is_running = TRUE; + + if (!loop->context->cond) + loop->context->cond = g_cond_new (); + + while (loop->is_running || !got_ownership) + got_ownership = g_main_context_wait (loop->context, + loop->context->cond, + g_static_mutex_get_mutex (&loop->context->mutex)); + + if (!loop->is_running) + { + UNLOCK_CONTEXT (loop->context); + if (got_ownership) + g_main_context_release (loop->context); + g_main_loop_unref (loop); + return; + } + + g_assert (got_ownership); + } + else + LOCK_CONTEXT (loop->context); +#endif /* G_THREADS_ENABLED */ + + if (loop->context->in_check_or_prepare) + { + g_warning ("g_main_run(): called recursively from within a source's check() or " + "prepare() member, iteration not possible."); + return; + } + + loop->ref_count++; + loop->is_running = TRUE; + while (loop->is_running) + g_main_context_iterate (loop->context, TRUE, TRUE, self); + +#ifdef G_THREADS_ENABLED + g_main_context_release (loop->context); +#endif /* G_THREADS_ENABLED */ + + g_main_loop_unref_and_unlock (loop); +} + +/** + * g_main_loop_quit: + * @loop: a #GMainLoop + * + * Stops a #GMainLoop from running. Any calls to g_main_loop_run() + * for the loop will return. + **/ +void +g_main_loop_quit (GMainLoop *loop) +{ + g_return_if_fail (loop != NULL); + g_return_if_fail (loop->ref_count > 0); + + LOCK_CONTEXT (loop->context); + loop->is_running = FALSE; + g_main_context_wakeup_unlocked (loop->context); + + if (loop->context->cond) + g_cond_broadcast (loop->context->cond); + UNLOCK_CONTEXT (loop->context); +} + +/** + * g_main_loop_is_running: + * @loop: a #GMainLoop. + * + * Check to see if the main loop is currently being run via g_main_run() + * + * Return value: %TRUE if the mainloop is currently being run. + **/ +gboolean +g_main_loop_is_running (GMainLoop *loop) +{ + g_return_val_if_fail (loop != NULL, FALSE); + g_return_val_if_fail (loop->ref_count > 0, FALSE); + + return loop->is_running; +} + +/** + * g_main_loop_get_context: + * @loop: a #GMainLoop. + * + * Returns the #GMainContext of @loop. + * + * Return value: the #GMainContext of @loop + **/ +GMainContext * +g_main_loop_get_context (GMainLoop *loop) +{ + g_return_val_if_fail (loop != NULL, NULL); + g_return_val_if_fail (loop->ref_count > 0, NULL); + + return loop->context; +} + +/* HOLDS: context's lock */ +static void +g_main_context_poll (GMainContext *context, + gint timeout, + gint priority, + GPollFD *fds, + gint n_fds) +{ +#ifdef G_MAIN_POLL_DEBUG + GTimer *poll_timer; + GPollRec *pollrec; + gint i; +#endif + + GPollFunc poll_func; + + if (n_fds || timeout != 0) + { +#ifdef G_MAIN_POLL_DEBUG + g_print ("g_main_poll(%d) timeout: %d\n", n_fds, timeout); + poll_timer = g_timer_new (); +#endif + + LOCK_CONTEXT (context); + + poll_func = context->poll_func; + + UNLOCK_CONTEXT (context); + if ((*poll_func) (fds, n_fds, timeout) < 0 && errno != EINTR) + g_warning ("poll(2) failed due to: %s.", + g_strerror (errno)); + +#ifdef G_MAIN_POLL_DEBUG + LOCK_CONTEXT (context); + + g_print ("g_main_poll(%d) timeout: %d - elapsed %12.10f seconds", + n_fds, + timeout, + g_timer_elapsed (poll_timer, NULL)); + g_timer_destroy (poll_timer); + pollrec = context->poll_records; + i = 0; + while (i < n_fds) + { + if (pollrec->fd->events) + { + if (fds[i].revents) + { + g_print (" [%d:", fds[i].fd); + if (fds[i].revents & G_IO_IN) + g_print ("i"); + if (fds[i].revents & G_IO_OUT) + g_print ("o"); + if (fds[i].revents & G_IO_PRI) + g_print ("p"); + if (fds[i].revents & G_IO_ERR) + g_print ("e"); + if (fds[i].revents & G_IO_HUP) + g_print ("h"); + if (fds[i].revents & G_IO_NVAL) + g_print ("n"); + g_print ("]"); + } + i++; + } + pollrec = pollrec->next; + } + g_print ("\n"); + + UNLOCK_CONTEXT (context); +#endif + } /* if (n_fds || timeout != 0) */ +} + +/** + * g_main_context_add_poll: + * @context: a #GMainContext (or %NULL for the default context) + * @fd: a #GPollFD structure holding information about a file + * descriptor to watch. + * @priority: the priority for this file descriptor which should be + * the same as the priority used for g_source_attach() to ensure that the + * file descriptor is polled whenever the results may be needed. + * + * Add a file descriptor to the set of file descriptors polled * for + * this context. This will very seldom be used directly. Instead + * a typical event source will use g_source_add_poll() instead. + **/ +void +g_main_context_add_poll (GMainContext *context, + GPollFD *fd, + gint priority) +{ + if (!context) + context = g_main_context_default (); + + g_return_if_fail (context->ref_count > 0); + g_return_if_fail (fd); + + LOCK_CONTEXT (context); + g_main_context_add_poll_unlocked (context, priority, fd); + UNLOCK_CONTEXT (context); +} + +/* HOLDS: main_loop_lock */ +static void +g_main_context_add_poll_unlocked (GMainContext *context, + gint priority, + GPollFD *fd) +{ + GPollRec *lastrec, *pollrec, *newrec; + + if (!context->poll_chunk) + context->poll_chunk = g_mem_chunk_create (GPollRec, 32, G_ALLOC_ONLY); + + if (context->poll_free_list) + { + newrec = context->poll_free_list; + context->poll_free_list = newrec->next; + } + else + newrec = g_chunk_new (GPollRec, context->poll_chunk); + + /* This file descriptor may be checked before we ever poll */ + fd->revents = 0; + newrec->fd = fd; + newrec->priority = priority; + + lastrec = NULL; + pollrec = context->poll_records; + while (pollrec && priority >= pollrec->priority) + { + lastrec = pollrec; + pollrec = pollrec->next; + } + + if (lastrec) + lastrec->next = newrec; + else + context->poll_records = newrec; + + newrec->next = pollrec; + + context->n_poll_records++; + +#ifdef G_THREADS_ENABLED + context->poll_changed = TRUE; + + /* Now wake up the main loop if it is waiting in the poll() */ + g_main_context_wakeup_unlocked (context); +#endif +} + +/** + * g_main_context_remove_poll: + * @context:a #GMainContext + * @fd: a #GPollFD descriptor previously added with g_main_context_add_poll() + * + * Remove file descriptor from the set of file descriptors to be + * polled for a particular context. + **/ +void +g_main_context_remove_poll (GMainContext *context, + GPollFD *fd) +{ + if (!context) + context = g_main_context_default (); + + g_return_if_fail (context->ref_count > 0); + g_return_if_fail (fd); + + LOCK_CONTEXT (context); + g_main_context_remove_poll_unlocked (context, fd); + UNLOCK_CONTEXT (context); +} + +static void +g_main_context_remove_poll_unlocked (GMainContext *context, + GPollFD *fd) +{ + GPollRec *pollrec, *lastrec; + + lastrec = NULL; + pollrec = context->poll_records; + + while (pollrec) + { + if (pollrec->fd == fd) + { + if (lastrec != NULL) + lastrec->next = pollrec->next; + else + context->poll_records = pollrec->next; + +#ifdef ENABLE_GC_FRIENDLY + pollrec->fd = NULL; +#endif /* ENABLE_GC_FRIENDLY */ + + pollrec->next = context->poll_free_list; + context->poll_free_list = pollrec; + + context->n_poll_records--; + break; + } + lastrec = pollrec; + pollrec = pollrec->next; + } + +#ifdef G_THREADS_ENABLED + context->poll_changed = TRUE; + + /* Now wake up the main loop if it is waiting in the poll() */ + g_main_context_wakeup_unlocked (context); +#endif +} + +/** + * g_source_get_current_time: + * @source: a #GSource + * @timeval: #GTimeVal structure in which to store current time. + * + * Gets the "current time" to be used when checking + * this source. The advantage of calling this function over + * calling g_get_current_time() directly is that when + * checking multiple sources, GLib can cache a single value + * instead of having to repeatedly get the system time. + **/ +void +g_source_get_current_time (GSource *source, + GTimeVal *timeval) +{ + GMainContext *context; + + g_return_if_fail (source->context != NULL); + + context = source->context; + + LOCK_CONTEXT (context); + + if (!context->time_is_current) + { + g_get_current_time (&context->current_time); + context->time_is_current = TRUE; + } + + *timeval = context->current_time; + + UNLOCK_CONTEXT (context); +} + +/** + * g_main_context_set_poll_func: + * @context: a #GMainContext + * @func: the function to call to poll all file descriptors + * + * Sets the function to use to handle polling of file descriptors. It + * will be used instead of the poll() system call (or GLib's + * replacement function, which is used where poll() isn't available). + * + * This function could possibly be used to integrate the GLib event + * loop with an external event loop. + **/ +void +g_main_context_set_poll_func (GMainContext *context, + GPollFunc func) +{ + if (!context) + context = g_main_context_default (); + + g_return_if_fail (context->ref_count > 0); + + LOCK_CONTEXT (context); + + if (func) + context->poll_func = func; + else + { +#ifdef HAVE_POLL + context->poll_func = (GPollFunc) poll; +#else + context->poll_func = (GPollFunc) g_poll; +#endif + } + + UNLOCK_CONTEXT (context); +} + +/** + * g_main_context_get_poll_func: + * @context: a #GMainContext + * + * Gets the poll function set by g_main_context_set_poll_func() + * + * Return value: the poll function + **/ +GPollFunc +g_main_context_get_poll_func (GMainContext *context) +{ + GPollFunc result; + + if (!context) + context = g_main_context_default (); + + g_return_val_if_fail (context->ref_count > 0, NULL); + + LOCK_CONTEXT (context); + result = context->poll_func; + UNLOCK_CONTEXT (context); + + return result; +} + +/* HOLDS: context's lock */ +/* Wake the main loop up from a poll() */ +static void +g_main_context_wakeup_unlocked (GMainContext *context) +{ +#ifdef G_THREADS_ENABLED + if (g_thread_supported() && context->poll_waiting) + { + context->poll_waiting = FALSE; +#ifndef G_OS_WIN32 + write (context->wake_up_pipe[1], "A", 1); +#else + ReleaseSemaphore (context->wake_up_semaphore, 1, NULL); +#endif + } +#endif +} + +/** + * g_main_context_wakeup: + * @context: a #GMainContext + * + * If @context is currently waiting in a poll(), interrupt + * the poll(), and continue the iteration process. + **/ +void +g_main_context_wakeup (GMainContext *context) +{ + if (!context) + context = g_main_context_default (); + + g_return_if_fail (context->ref_count > 0); + + LOCK_CONTEXT (context); + g_main_context_wakeup_unlocked (context); + UNLOCK_CONTEXT (context); +} + +/* Timeouts */ + +static void +g_timeout_set_expiration (GTimeoutSource *timeout_source, + GTimeVal *current_time) +{ + guint seconds = timeout_source->interval / 1000; + guint msecs = timeout_source->interval - seconds * 1000; + + timeout_source->expiration.tv_sec = current_time->tv_sec + seconds; + timeout_source->expiration.tv_usec = current_time->tv_usec + msecs * 1000; + if (timeout_source->expiration.tv_usec >= 1000000) + { + timeout_source->expiration.tv_usec -= 1000000; + timeout_source->expiration.tv_sec++; + } +} + +static gboolean +g_timeout_prepare (GSource *source, + gint *timeout) +{ + glong sec; + glong msec; + GTimeVal current_time; + + GTimeoutSource *timeout_source = (GTimeoutSource *)source; + + g_source_get_current_time (source, ¤t_time); + + sec = timeout_source->expiration.tv_sec - current_time.tv_sec; + msec = (timeout_source->expiration.tv_usec - current_time.tv_usec) / 1000; + + /* We do the following in a rather convoluted fashion to deal with + * the fact that we don't have an integral type big enough to hold + * the difference of two timevals in millseconds. + */ + if (sec < 0 || (sec == 0 && msec < 0)) + msec = 0; + else + { + glong interval_sec = timeout_source->interval / 1000; + glong interval_msec = timeout_source->interval % 1000; + + if (msec < 0) + { + msec += 1000; + sec -= 1; + } + + if (sec > interval_sec || + (sec == interval_sec && msec > interval_msec)) + { + /* The system time has been set backwards, so we + * reset the expiration time to now + timeout_source->interval; + * this at least avoids hanging for long periods of time. + */ + g_timeout_set_expiration (timeout_source, ¤t_time); + msec = timeout_source->interval; + } + else + { + msec += sec * 1000; + } + } + + *timeout = (gint)msec; + + return msec == 0; +} + +static gboolean +g_timeout_check (GSource *source) +{ + GTimeVal current_time; + GTimeoutSource *timeout_source = (GTimeoutSource *)source; + + g_source_get_current_time (source, ¤t_time); + + return ((timeout_source->expiration.tv_sec < current_time.tv_sec) || + ((timeout_source->expiration.tv_sec == current_time.tv_sec) && + (timeout_source->expiration.tv_usec <= current_time.tv_usec))); +} + +static gboolean +g_timeout_dispatch (GSource *source, + GSourceFunc callback, + gpointer user_data) +{ + GTimeoutSource *timeout_source = (GTimeoutSource *)source; + + if (!callback) + { + g_warning ("Timeout source dispatched without callback\n" + "You must call g_source_set_callback()."); + return FALSE; + } + + if (callback (user_data)) + { + GTimeVal current_time; + + g_source_get_current_time (source, ¤t_time); + g_timeout_set_expiration (timeout_source, ¤t_time); + + return TRUE; + } + else + return FALSE; +} + +/** + * g_timeout_source_new: + * @interval: the timeout interval in milliseconds. + * + * Create a new timeout source. + * + * The source will not initially be associated with any #GMainContext + * and must be added to one with g_source_attach() before it will be + * executed. + * + * Return value: the newly create timeout source + **/ +GSource * +g_timeout_source_new (guint interval) +{ + GSource *source = g_source_new (&g_timeout_funcs, sizeof (GTimeoutSource)); + GTimeoutSource *timeout_source = (GTimeoutSource *)source; + GTimeVal current_time; + + timeout_source->interval = interval; + + g_get_current_time (¤t_time); + g_timeout_set_expiration (timeout_source, ¤t_time); + + return source; +} + +/** + * g_timeout_add_full: + * @priority: the priority of the idle source. Typically this will be in the + * range btweeen #G_PRIORITY_DEFAULT_IDLE and #G_PRIORITY_HIGH_IDLE. + * @interval: the time between calls to the function, in milliseconds + * (1/1000ths of a second.) + * @function: function to call + * @data: data to pass to @function + * @notify: function to call when the idle is removed, or %NULL + * + * Sets a function to be called at regular intervals, with the given + * priority. The function is called repeatedly until it returns + * FALSE, at which point the timeout is automatically destroyed and + * the function will not be called again. The @notify function is + * called when the timeout is destroyed. The first call to the + * function will be at the end of the first @interval. + * + * Note that timeout functions may be delayed, due to the processing of other + * event sources. Thus they should not be relied on for precise timing. + * After each call to the timeout function, the time of the next + * timeout is recalculated based on the current time and the given interval + * (it does not try to 'catch up' time lost in delays). + * + * Return value: the id of event source. + **/ +guint +g_timeout_add_full (gint priority, + guint interval, + GSourceFunc function, + gpointer data, + GDestroyNotify notify) +{ + GSource *source; + guint id; + + g_return_val_if_fail (function != NULL, 0); + + source = g_timeout_source_new (interval); + + if (priority != G_PRIORITY_DEFAULT) + g_source_set_priority (source, priority); + + g_source_set_callback (source, function, data, notify); + id = g_source_attach (source, NULL); + g_source_unref (source); + + return id; +} + +/** + * g_timeout_add: + * @interval: the time between calls to the function, in milliseconds + * (1/1000ths of a second.) + * @function: function to call + * @data: data to pass to @function + * + * Sets a function to be called at regular intervals, with the default + * priority, #G_PRIORITY_DEFAULT. The function is called repeatedly + * until it returns FALSE, at which point the timeout is automatically + * destroyed and the function will not be called again. The @notify + * function is called when the timeout is destroyed. The first call + * to the function will be at the end of the first @interval. + * + * Note that timeout functions may be delayed, due to the processing of other + * event sources. Thus they should not be relied on for precise timing. + * After each call to the timeout function, the time of the next + * timeout is recalculated based on the current time and the given interval + * (it does not try to 'catch up' time lost in delays). + * + * Return value: the id of event source. + **/ +guint +g_timeout_add (guint32 interval, + GSourceFunc function, + gpointer data) +{ + return g_timeout_add_full (G_PRIORITY_DEFAULT, + interval, function, data, NULL); +} + +/* Idle functions */ + +static gboolean +g_idle_prepare (GSource *source, + gint *timeout) +{ + *timeout = 0; + + return TRUE; +} + +static gboolean +g_idle_check (GSource *source) +{ + return TRUE; +} + +static gboolean +g_idle_dispatch (GSource *source, + GSourceFunc callback, + gpointer user_data) +{ + if (!callback) + { + g_warning ("Idle source dispatched without callback\n" + "You must call g_source_set_callback()."); + return FALSE; + } + + return callback (user_data); +} + +/** + * g_idle_source_new: + * + * Create a new idle source. + * + * The source will not initially be associated with any #GMainContext + * and must be added to one with g_source_attach() before it will be + * executed. + * + * Return value: the newly created idle source + **/ +GSource * +g_idle_source_new (void) +{ + return g_source_new (&g_idle_funcs, sizeof (GSource)); +} + +/** + * g_idle_add_full: + * @priority: the priority of the idle source. Typically this will be in the + * range btweeen #G_PRIORITY_DEFAULT_IDLE and #G_PRIORITY_HIGH_IDLE. + * @function: function to call + * @data: data to pass to @function + * @notify: function to call when the idle is removed, or %NULL + * + * Adds a function to be called whenever there are no higher priority + * events pending. If the function returns FALSE it is automatically + * removed from the list of event sources and will not be called again. + * + * Return value: the id of the event source. + **/ +guint +g_idle_add_full (gint priority, + GSourceFunc function, + gpointer data, + GDestroyNotify notify) +{ + GSource *source; + guint id; + + g_return_val_if_fail (function != NULL, 0); + + source = g_idle_source_new (); + + if (priority != G_PRIORITY_DEFAULT) + g_source_set_priority (source, priority); + + g_source_set_callback (source, function, data, notify); + id = g_source_attach (source, NULL); + g_source_unref (source); + + return id; +} + +/** + * g_idle_add: + * @function: function to call + * @data: data to pass to @function. + * + * Adds a function to be called whenever there are no higher priority + * events pending to the default main loop. The function is given the + * default idle priority, #G_PRIORITY_DEFAULT_IDLE. If the function + * returns FALSE it is automatically removed from the list of event + * sources and will not be called again. + * + * Return value: the id of the event source. + **/ +guint +g_idle_add (GSourceFunc function, + gpointer data) +{ + return g_idle_add_full (G_PRIORITY_DEFAULT_IDLE, function, data, NULL); +} + +/** + * g_idle_remove_by_data: + * @data: the data for the idle source's callback. + * + * Removes the idle function with the given data. + * + * Return value: %TRUE if an idle source was found and removed. + **/ +gboolean +g_idle_remove_by_data (gpointer data) +{ + return g_source_remove_by_funcs_user_data (&g_idle_funcs, data); +} + diff --git a/graf2d/win32gdk/gdk/src/glib/gmain.h b/graf2d/win32gdk/gdk/src/glib/gmain.h index dd500c6e83c6b..cd95288871279 100644 --- a/graf2d/win32gdk/gdk/src/glib/gmain.h +++ b/graf2d/win32gdk/gdk/src/glib/gmain.h @@ -20,8 +20,8 @@ #ifndef __G_MAIN_H__ #define __G_MAIN_H__ -#include <gslist.h> -#include <gthread.h> +#include <glib/gslist.h> +#include <glib/gthread.h> G_BEGIN_DECLS @@ -59,10 +59,13 @@ struct _GSourceCallbackFuncs void (*ref) (gpointer cb_data); void (*unref) (gpointer cb_data); void (*get) (gpointer cb_data, + GSource *source, GSourceFunc *func, gpointer *data); }; +typedef void (*GSourceDummyMarshal) (void); + struct _GSourceFuncs { gboolean (*prepare) (GSource *source, @@ -71,7 +74,11 @@ struct _GSourceFuncs gboolean (*dispatch) (GSource *source, GSourceFunc callback, gpointer user_data); - void (*destroy) (GSource *source); /* Can be NULL */ + void (*finalize) (GSource *source); /* Can be NULL */ + + /* For use by g_source_set_closure */ + GSourceFunc closure_callback; + GSourceDummyMarshal closure_marshal; /* Really is of type GClosureMarshal */ }; /* Any definitions using GPollFD or GPollFunc are primarily @@ -124,7 +131,9 @@ struct _GPollFD /* GMainContext: */ -GMainContext *g_main_context_get (GThread *thread); +GMainContext *g_main_context_new (void); +void g_main_context_ref (GMainContext *context); +void g_main_context_unref (GMainContext *context); GMainContext *g_main_context_default (void); gboolean g_main_context_iteration (GMainContext *context, @@ -143,6 +152,13 @@ GSource *g_main_context_find_source_by_funcs_user_data (GMainContext *conte /* Low level functions for implementing custom main loops. */ +void g_main_context_wakeup (GMainContext *context); +gboolean g_main_context_acquire (GMainContext *context); +void g_main_context_release (GMainContext *context); +gboolean g_main_context_wait (GMainContext *context, + GCond *cond, + GMutex *mutex); + gboolean g_main_context_prepare (GMainContext *context, gint *priority); gint g_main_context_query (GMainContext *context, @@ -174,8 +190,10 @@ GMainLoop *g_main_loop_new (GMainContext *context, gboolean is_running); void g_main_loop_run (GMainLoop *loop); void g_main_loop_quit (GMainLoop *loop); -void g_main_loop_destroy (GMainLoop *loop); +GMainLoop *g_main_loop_ref (GMainLoop *loop); +void g_main_loop_unref (GMainLoop *loop); gboolean g_main_loop_is_running (GMainLoop *loop); +GMainContext *g_main_loop_get_context (GMainLoop *loop); /* GSource: */ @@ -232,20 +250,16 @@ void g_get_current_time (GTimeVal *result); /* ============== Compat main loop stuff ================== */ +#ifndef G_DISABLE_DEPRECATED + /* Legacy names for GMainLoop functions */ #define g_main_new(is_running) g_main_loop_new (NULL, is_running); #define g_main_run(loop) g_main_loop_run(loop) #define g_main_quit(loop) g_main_loop_quit(loop) -#define g_main_destroy(loop) g_main_loop_destroy(loop) +#define g_main_destroy(loop) g_main_loop_unref(loop) #define g_main_is_running(loop) g_main_loop_is_running(loop) -/* Source manipulation by ID */ -gboolean g_source_remove (guint tag); -gboolean g_source_remove_by_user_data (gpointer user_data); -gboolean g_source_remove_by_funcs_user_data (GSourceFuncs *funcs, - gpointer user_data); - /* Functions to manipulate the default main loop */ @@ -254,6 +268,14 @@ gboolean g_source_remove_by_funcs_user_data (GSourceFuncs *funcs, #define g_main_set_poll_func(func) g_main_context_set_poll_func (NULL, func) +#endif /* G_DISABLE_DEPRECATED */ + +/* Source manipulation by ID */ +gboolean g_source_remove (guint tag); +gboolean g_source_remove_by_user_data (gpointer user_data); +gboolean g_source_remove_by_funcs_user_data (GSourceFuncs *funcs, + gpointer user_data); + /* Idles and timeouts */ guint g_timeout_add_full (gint priority, guint interval, @@ -271,6 +293,10 @@ guint g_idle_add_full (gint priority, GDestroyNotify notify); gboolean g_idle_remove_by_data (gpointer data); +/* Hook for GClosure / GSource integration. Don't touch */ +GLIB_VAR GSourceFuncs g_timeout_funcs; +GLIB_VAR GSourceFuncs g_idle_funcs; + #ifdef G_OS_WIN32 /* This is used to add polling for Windows messages. GDK (GTK+) programs diff --git a/graf2d/win32gdk/gdk/src/glib/gmarkup.c b/graf2d/win32gdk/gdk/src/glib/gmarkup.c new file mode 100644 index 0000000000000..bf7ff376c97af --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gmarkup.c @@ -0,0 +1,1735 @@ +/* gmarkup.c - Simple XML-like parser + * + * Copyright 2000 Red Hat, Inc. + * + * GLib is free software; you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2 of the + * License, or (at your option) any later version. + * + * GLib is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with GLib; see the file COPYING.LIB. If not, + * write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "glib.h" + +#include <string.h> +#include <stdio.h> +#include <stdlib.h> +#include <errno.h> + +#include "glibintl.h" + +GQuark +g_markup_error_quark () +{ + static GQuark error_quark = 0; + + if (error_quark == 0) + error_quark = g_quark_from_static_string ("g-markup-error-quark"); + + return error_quark; +} + +typedef enum +{ + STATE_START, + STATE_AFTER_OPEN_ANGLE, + STATE_AFTER_CLOSE_ANGLE, + STATE_AFTER_ELISION_SLASH, /* the slash that obviates need for end element */ + STATE_INSIDE_OPEN_TAG_NAME, + STATE_INSIDE_ATTRIBUTE_NAME, + STATE_BETWEEN_ATTRIBUTES, + STATE_AFTER_ATTRIBUTE_EQUALS_SIGN, + STATE_INSIDE_ATTRIBUTE_VALUE, + STATE_INSIDE_TEXT, + STATE_AFTER_CLOSE_TAG_SLASH, + STATE_INSIDE_CLOSE_TAG_NAME, + STATE_INSIDE_PASSTHROUGH, + STATE_ERROR +} GMarkupParseState; + +struct _GMarkupParseContext +{ + const GMarkupParser *parser; + + GMarkupParseFlags flags; + + gint line_number; + gint char_number; + + gpointer user_data; + GDestroyNotify dnotify; + + /* A piece of character data or an element that + * hasn't "ended" yet so we haven't yet called + * the callback for it. + */ + GString *partial_chunk; + + GMarkupParseState state; + GSList *tag_stack; + gchar **attr_names; + gchar **attr_values; + gint cur_attr; + gint alloc_attrs; + + const gchar *current_text; + gssize current_text_len; + const gchar *current_text_end; + + GString *leftover_char_portion; + + /* used to save the start of the last interesting thingy */ + const gchar *start; + + const gchar *iter; + + guint document_empty : 1; + guint parsing : 1; +}; + +/** + * g_markup_parse_context_new: + * @parser: a #GMarkupParser + * @flags: one or more #GMarkupParseFlags + * @user_data: user data to pass to #GMarkupParser functions + * @user_data_dnotify: user data destroy notifier called when the parse context is freed + * + * Creates a new parse context. A parse context is used to parse + * marked-up documents. You can feed any number of documents into + * a context, as long as no errors occur; once an error occurs, + * the parse context can't continue to parse text (you have to free it + * and create a new parse context). + * + * Return value: a new #GMarkupParseContext + **/ +GMarkupParseContext * +g_markup_parse_context_new (const GMarkupParser *parser, + GMarkupParseFlags flags, + gpointer user_data, + GDestroyNotify user_data_dnotify) +{ + GMarkupParseContext *context; + + g_return_val_if_fail (parser != NULL, NULL); + + context = g_new (GMarkupParseContext, 1); + + context->parser = parser; + context->flags = flags; + context->user_data = user_data; + context->dnotify = user_data_dnotify; + + context->line_number = 1; + context->char_number = 1; + + context->partial_chunk = NULL; + + context->state = STATE_START; + context->tag_stack = NULL; + context->attr_names = NULL; + context->attr_values = NULL; + context->cur_attr = -1; + context->alloc_attrs = 0; + + context->current_text = NULL; + context->current_text_len = -1; + context->current_text_end = NULL; + context->leftover_char_portion = NULL; + + context->start = NULL; + context->iter = NULL; + + context->document_empty = TRUE; + context->parsing = FALSE; + + return context; +} + +/** + * g_markup_parse_context_free: + * @context: a #GMarkupParseContext + * + * Frees a #GMarkupParseContext. Can't be called from inside + * one of the #GMarkupParser functions. + * + **/ +void +g_markup_parse_context_free (GMarkupParseContext *context) +{ + g_return_if_fail (context != NULL); + g_return_if_fail (!context->parsing); + + if (context->dnotify) + (* context->dnotify) (context->user_data); + + g_strfreev (context->attr_names); + g_strfreev (context->attr_values); + + g_slist_foreach (context->tag_stack, (GFunc)g_free, NULL); + g_slist_free (context->tag_stack); + + if (context->partial_chunk) + g_string_free (context->partial_chunk, TRUE); + + if (context->leftover_char_portion) + g_string_free (context->leftover_char_portion, TRUE); + + g_free (context); +} + +static void +mark_error (GMarkupParseContext *context, + GError *error) +{ + context->state = STATE_ERROR; + + if (context->parser->error) + (*context->parser->error) (context, error, context->user_data); +} + +static void +set_error (GMarkupParseContext *context, + GError **error, + GMarkupError code, + const gchar *format, + ...) +{ + GError *tmp_error; + gchar *s; + va_list args; + + va_start (args, format); + s = g_strdup_vprintf (format, args); + va_end (args); + + tmp_error = g_error_new (G_MARKUP_ERROR, + code, + _("Error on line %d char %d: %s"), + context->line_number, + context->char_number, + s); + + g_free (s); + + mark_error (context, tmp_error); + + g_propagate_error (error, tmp_error); +} + +static gboolean +is_name_start_char (gunichar c) +{ + if (g_unichar_isalpha (c) || + c == '_' || + c == ':') + return TRUE; + else + return FALSE; +} + +static gboolean +is_name_char (gunichar c) +{ + if (g_unichar_isalnum (c) || + c == '.' || + c == '-' || + c == '_' || + c == ':') + return TRUE; + else + return FALSE; +} + + +static gchar* +char_str (gunichar c, + gchar *buf) +{ + memset (buf, 0, 7); + g_unichar_to_utf8 (c, buf); + return buf; +} + +static gchar* +utf8_str (const gchar *utf8, + gchar *buf) +{ + char_str (g_utf8_get_char (utf8), buf); + return buf; +} + +static void +set_unescape_error (GMarkupParseContext *context, + GError **error, + const gchar *remaining_text, + const gchar *remaining_text_end, + GMarkupError code, + const gchar *format, + ...) +{ + GError *tmp_error; + gchar *s; + va_list args; + gint remaining_newlines; + const gchar *p; + + remaining_newlines = 0; + p = remaining_text; + while (p != remaining_text_end) + { + if (*p == '\n') + ++remaining_newlines; + ++p; + } + + va_start (args, format); + s = g_strdup_vprintf (format, args); + va_end (args); + + tmp_error = g_error_new (G_MARKUP_ERROR, + code, + _("Error on line %d: %s"), + context->line_number - remaining_newlines, + s); + + g_free (s); + + mark_error (context, tmp_error); + + g_propagate_error (error, tmp_error); +} + +typedef enum +{ + USTATE_INSIDE_TEXT, + USTATE_AFTER_AMPERSAND, + USTATE_INSIDE_ENTITY_NAME, + USTATE_AFTER_CHARREF_HASH +} UnescapeState; + +static gboolean +unescape_text (GMarkupParseContext *context, + const gchar *text, + const gchar *text_end, + gchar **unescaped, + GError **error) +{ +#define MAX_ENT_LEN 5 + GString *str; + const gchar *p; + UnescapeState state; + const gchar *start; + + str = g_string_new (""); + + state = USTATE_INSIDE_TEXT; + p = text; + start = p; + while (p != text_end && context->state != STATE_ERROR) + { + g_assert (p < text_end); + + switch (state) + { + case USTATE_INSIDE_TEXT: + { + while (p != text_end && *p != '&') + p = g_utf8_next_char (p); + + if (p != start) + { + g_string_append_len (str, start, p - start); + + start = NULL; + } + + if (p != text_end && *p == '&') + { + p = g_utf8_next_char (p); + state = USTATE_AFTER_AMPERSAND; + } + } + break; + + case USTATE_AFTER_AMPERSAND: + { + if (*p == '#') + { + p = g_utf8_next_char (p); + + start = p; + state = USTATE_AFTER_CHARREF_HASH; + } + else if (!is_name_start_char (g_utf8_get_char (p))) + { + if (*p == ';') + { + set_unescape_error (context, error, + p, text_end, + G_MARKUP_ERROR_PARSE, + _("Empty entity '&;' seen; valid " + "entities are: & " < > '")); + } + else + { + gchar buf[7]; + + set_unescape_error (context, error, + p, text_end, + G_MARKUP_ERROR_PARSE, + _("Character '%s' is not valid at " + "the start of an entity name; " + "the & character begins an entity; " + "if this ampersand isn't supposed " + "to be an entity, escape it as " + "&"), + utf8_str (p, buf)); + } + } + else + { + start = p; + state = USTATE_INSIDE_ENTITY_NAME; + } + } + break; + + + case USTATE_INSIDE_ENTITY_NAME: + { + gchar buf[MAX_ENT_LEN+1] = { + '\0', '\0', '\0', '\0', '\0', '\0' + }; + gchar *dest; + + while (p != text_end) + { + if (*p == ';') + break; + else if (!is_name_char (*p)) + { + gchar ubuf[7]; + + set_unescape_error (context, error, + p, text_end, + G_MARKUP_ERROR_PARSE, + _("Character '%s' is not valid " + "inside an entity name"), + utf8_str (p, ubuf)); + break; + } + + p = g_utf8_next_char (p); + } + + if (context->state != STATE_ERROR) + { + if (p != text_end) + { + const gchar *src; + + src = start; + dest = buf; + while (src != p) + { + *dest = *src; + ++dest; + ++src; + } + + /* move to after semicolon */ + p = g_utf8_next_char (p); + start = p; + state = USTATE_INSIDE_TEXT; + + if (strcmp (buf, "lt") == 0) + g_string_append_c (str, '<'); + else if (strcmp (buf, "gt") == 0) + g_string_append_c (str, '>'); + else if (strcmp (buf, "amp") == 0) + g_string_append_c (str, '&'); + else if (strcmp (buf, "quot") == 0) + g_string_append_c (str, '"'); + else if (strcmp (buf, "apos") == 0) + g_string_append_c (str, '\''); + else + { + set_unescape_error (context, error, + p, text_end, + G_MARKUP_ERROR_PARSE, + _("Entity name '%s' is not known"), + buf); + } + } + else + { + set_unescape_error (context, error, + /* give line number of the & */ + start, text_end, + G_MARKUP_ERROR_PARSE, + _("Entity did not end with a semicolon; " + "most likely you used an ampersand " + "character without intending to start " + "an entity - escape ampersand as &")); + } + } + } + break; + + case USTATE_AFTER_CHARREF_HASH: + { + gboolean is_hex = FALSE; + if (*p == 'x') + { + is_hex = TRUE; + p = g_utf8_next_char (p); + start = p; + } + + while (p != text_end && *p != ';') + p = g_utf8_next_char (p); + + if (p != text_end) + { + g_assert (*p == ';'); + + /* digit is between start and p */ + + if (start != p) + { + gchar *digit = g_strndup (start, p - start); + gulong l; + gchar *end = NULL; + gchar *digit_end = digit + (p - start); + + errno = 0; + if (is_hex) + l = strtoul (digit, &end, 16); + else + l = strtoul (digit, &end, 10); + + if (end != digit_end || errno != 0) + { + set_unescape_error (context, error, + start, text_end, + G_MARKUP_ERROR_PARSE, + _("Failed to parse '%s', which " + "should have been a digit " + "inside a character reference " + "(ê for example) - perhaps " + "the digit is too large"), + digit); + } + else + { + /* characters XML permits */ + if (l == 0x9 || + l == 0xA || + l == 0xD || + (l >= 0x20 && l <= 0xD7FF) || + (l >= 0xE000 && l <= 0xFFFD) || + (l >= 0x10000 && l <= 0x10FFFF)) + { + gchar buf[7]; + g_string_append (str, char_str (l, buf)); + } + else + { + set_unescape_error (context, error, + start, text_end, + G_MARKUP_ERROR_PARSE, + _("Character reference '%s' does not encode a permitted character"), + digit); + } + } + + g_free (digit); + + /* Move to next state */ + p = g_utf8_next_char (p); /* past semicolon */ + start = p; + state = USTATE_INSIDE_TEXT; + } + else + { + set_unescape_error (context, error, + start, text_end, + G_MARKUP_ERROR_PARSE, + _("Empty character reference; " + "should include a digit such as " + "dž")); + } + } + else + { + set_unescape_error (context, error, + start, text_end, + G_MARKUP_ERROR_PARSE, + _("Character reference did not end with a " + "semicolon; " + "most likely you used an ampersand " + "character without intending to start " + "an entity - escape ampersand as &")); + } + } + break; + + default: + g_assert_not_reached (); + break; + } + } + + /* If no errors, we should have returned to USTATE_INSIDE_TEXT */ + g_assert (context->state == STATE_ERROR || + state == USTATE_INSIDE_TEXT); + + if (context->state == STATE_ERROR) + { + g_string_free (str, TRUE); + *unescaped = NULL; + return FALSE; + } + else + { + *unescaped = g_string_free (str, FALSE); + return TRUE; + } + +#undef MAX_ENT_LEN +} + +static gboolean +advance_char (GMarkupParseContext *context) +{ + + context->iter = g_utf8_next_char (context->iter); + context->char_number += 1; + if (*context->iter == '\n') + { + context->line_number += 1; + context->char_number = 1; + } + + return context->iter != context->current_text_end; +} + +static void +skip_spaces (GMarkupParseContext *context) +{ + do + { + if (!g_unichar_isspace (g_utf8_get_char (context->iter))) + return; + } + while (advance_char (context)); +} + +static void +advance_to_name_end (GMarkupParseContext *context) +{ + do + { + if (!is_name_char (g_utf8_get_char (context->iter))) + return; + } + while (advance_char (context)); +} + +static void +add_to_partial (GMarkupParseContext *context, + const gchar *text_start, + const gchar *text_end) +{ + if (context->partial_chunk == NULL) + context->partial_chunk = g_string_new (""); + + if (text_start != text_end) + g_string_append_len (context->partial_chunk, text_start, + text_end - text_start); + + /* Invariant here that partial_chunk exists */ +} + +static void +truncate_partial (GMarkupParseContext *context) +{ + if (context->partial_chunk != NULL) + { + context->partial_chunk = g_string_truncate (context->partial_chunk, 0); + } +} + +static const gchar* +current_element (GMarkupParseContext *context) +{ + return context->tag_stack->data; +} + +static const gchar* +current_attribute (GMarkupParseContext *context) +{ + g_assert (context->cur_attr >= 0); + return context->attr_names[context->cur_attr]; +} + +static void +find_current_text_end (GMarkupParseContext *context) +{ + /* This function must be safe (non-segfaulting) on invalid UTF8 */ + const gchar *end = context->current_text + context->current_text_len; + const gchar *p; + const gchar *next; + + g_assert (context->current_text_len > 0); + + p = context->current_text; + next = g_utf8_find_next_char (p, end); + + while (next) + { + p = next; + next = g_utf8_find_next_char (p, end); + } + + /* p is now the start of the last character or character portion. */ + g_assert (p != end); + next = g_utf8_next_char (p); /* this only touches *p, nothing beyond */ + + if (next == end) + { + /* whole character */ + context->current_text_end = end; + } + else + { + /* portion */ + context->leftover_char_portion = g_string_new_len (p, end - p); + context->current_text_len -= (end - p); + context->current_text_end = p; + } +} + +static void +add_attribute (GMarkupParseContext *context, char *name) +{ + if (context->cur_attr + 2 >= context->alloc_attrs) + { + context->alloc_attrs += 5; /* silly magic number */ + context->attr_names = g_realloc (context->attr_names, sizeof(char*)*context->alloc_attrs); + context->attr_values = g_realloc (context->attr_values, sizeof(char*)*context->alloc_attrs); + } + context->cur_attr++; + context->attr_names[context->cur_attr] = name; + context->attr_values[context->cur_attr] = NULL; + context->attr_names[context->cur_attr+1] = NULL; +} + +/** + * g_markup_parse_context_parse: + * @context: a #GMarkupParseContext + * @text: chunk of text to parse + * @text_len: length of @text in bytes + * @error: return location for a #GError + * + * Feed some data to the #GMarkupParseContext. The data need not + * be valid UTF-8; an error will be signaled if it's invalid. + * The data need not be an entire document; you can feed a document + * into the parser incrementally, via multiple calls to this function. + * Typically, as you receive data from a network connection or file, + * you feed each received chunk of data into this function, aborting + * the process if an error occurs. Once an error is reported, no further + * data may be fed to the #GMarkupParseContext; all errors are fatal. + * + * Return value: %FALSE if an error occurred, %TRUE on success + **/ +gboolean +g_markup_parse_context_parse (GMarkupParseContext *context, + const gchar *text, + gssize text_len, + GError **error) +{ + const gchar *first_invalid; + + g_return_val_if_fail (context != NULL, FALSE); + g_return_val_if_fail (text != NULL, FALSE); + g_return_val_if_fail (context->state != STATE_ERROR, FALSE); + g_return_val_if_fail (!context->parsing, FALSE); + + if (text_len < 0) + text_len = strlen (text); + + if (text_len == 0) + return TRUE; + + context->parsing = TRUE; + + if (context->leftover_char_portion) + { + const gchar *first_char; + + if ((*text & 0xc0) != 0x80) + first_char = text; + else + first_char = g_utf8_find_next_char (text, text + text_len); + + if (first_char) + { + /* leftover_char_portion was completed. Parse it. */ + GString *portion = context->leftover_char_portion; + + g_string_append_len (context->leftover_char_portion, + text, first_char - text); + + /* hacks to allow recursion */ + context->parsing = FALSE; + context->leftover_char_portion = NULL; + + if (!g_markup_parse_context_parse (context, + portion->str, portion->len, + error)) + { + g_assert (context->state == STATE_ERROR); + } + + g_string_free (portion, TRUE); + context->parsing = TRUE; + + /* Skip the fraction of char that was in this text */ + text_len -= (first_char - text); + text = first_char; + } + else + { + /* another little chunk of the leftover char; geez + * someone is inefficient. + */ + g_string_append_len (context->leftover_char_portion, + text, text_len); + + if (context->leftover_char_portion->len > 7) + { + /* The leftover char portion is too big to be + * a UTF-8 character + */ + set_error (context, + error, + G_MARKUP_ERROR_BAD_UTF8, + _("Invalid UTF-8 encoded text")); + } + + goto finished; + } + } + + context->current_text = text; + context->current_text_len = text_len; + context->iter = context->current_text; + context->start = context->iter; + + /* Nothing left after finishing the leftover char, or nothing + * passed in to begin with. + */ + if (context->current_text_len == 0) + goto finished; + + /* find_current_text_end () assumes the string starts at + * a character start, so we need to validate at least + * that much. It doesn't assume any following bytes + * are valid. + */ + if ((*context->current_text & 0xc0) == 0x80) /* not a char start */ + { + set_error (context, + error, + G_MARKUP_ERROR_BAD_UTF8, + _("Invalid UTF-8 encoded text")); + goto finished; + } + + /* Initialize context->current_text_end, possibly adjusting + * current_text_len, and add any leftover char portion + */ + find_current_text_end (context); + + /* Validate UTF8 (must be done after we find the end, since + * we could have a trailing incomplete char) + */ + if (!g_utf8_validate (context->current_text, + context->current_text_len, + &first_invalid)) + { + gint newlines = 0; + const gchar *p; + p = context->current_text; + while (p != context->current_text_end) + { + if (*p == '\n') + ++newlines; + ++p; + } + + context->line_number += newlines; + + set_error (context, + error, + G_MARKUP_ERROR_BAD_UTF8, + _("Invalid UTF-8 encoded text")); + goto finished; + } + + while (context->iter != context->current_text_end) + { + switch (context->state) + { + case STATE_START: + /* Possible next state: AFTER_OPEN_ANGLE */ + + g_assert (context->tag_stack == NULL); + + /* whitespace is ignored outside of any elements */ + skip_spaces (context); + + if (context->iter != context->current_text_end) + { + if (*context->iter == '<') + { + /* Move after the open angle */ + advance_char (context); + + context->state = STATE_AFTER_OPEN_ANGLE; + + /* this could start a passthrough */ + context->start = context->iter; + + /* document is now non-empty */ + context->document_empty = FALSE; + } + else + { + set_error (context, + error, + G_MARKUP_ERROR_PARSE, + _("Document must begin with an element (e.g. <book>)")); + } + } + break; + + case STATE_AFTER_OPEN_ANGLE: + /* Possible next states: INSIDE_OPEN_TAG_NAME, + * AFTER_CLOSE_TAG_SLASH, INSIDE_PASSTHROUGH + */ + if (*context->iter == '?' || + *context->iter == '!') + { + /* include < in the passthrough */ + const gchar *openangle = "<"; + add_to_partial (context, openangle, openangle + 1); + context->start = context->iter; + context->state = STATE_INSIDE_PASSTHROUGH; + } + else if (*context->iter == '/') + { + /* move after it */ + advance_char (context); + + context->state = STATE_AFTER_CLOSE_TAG_SLASH; + } + else if (is_name_start_char (g_utf8_get_char (context->iter))) + { + context->state = STATE_INSIDE_OPEN_TAG_NAME; + + /* start of tag name */ + context->start = context->iter; + } + else + { + gchar buf[7]; + set_error (context, + error, + G_MARKUP_ERROR_PARSE, + _("'%s' is not a valid character following " + "a '<' character; it may not begin an " + "element name"), + utf8_str (context->iter, buf)); + } + break; + + /* The AFTER_CLOSE_ANGLE state is actually sort of + * broken, because it doesn't correspond to a range + * of characters in the input stream as the others do, + * and thus makes things harder to conceptualize + */ + case STATE_AFTER_CLOSE_ANGLE: + /* Possible next states: INSIDE_TEXT, STATE_START */ + if (context->tag_stack == NULL) + { + context->start = NULL; + context->state = STATE_START; + } + else + { + context->start = context->iter; + context->state = STATE_INSIDE_TEXT; + } + break; + + case STATE_AFTER_ELISION_SLASH: + /* Possible next state: AFTER_CLOSE_ANGLE */ + + { + /* We need to pop the tag stack and call the end_element + * function, since this is the close tag + */ + GError *tmp_error = NULL; + + g_assert (context->tag_stack != NULL); + + tmp_error = NULL; + if (context->parser->end_element) + (* context->parser->end_element) (context, + context->tag_stack->data, + context->user_data, + &tmp_error); + + if (tmp_error) + { + mark_error (context, tmp_error); + g_propagate_error (error, tmp_error); + } + else + { + if (*context->iter == '>') + { + /* move after the close angle */ + advance_char (context); + context->state = STATE_AFTER_CLOSE_ANGLE; + } + else + { + gchar buf[7]; + set_error (context, + error, + G_MARKUP_ERROR_PARSE, + _("Odd character '%s', expected a '>' character " + "to end the start tag of element '%s'"), + utf8_str (context->iter, buf), + current_element (context)); + } + } + + g_free (context->tag_stack->data); + context->tag_stack = g_slist_delete_link (context->tag_stack, + context->tag_stack); + } + break; + + case STATE_INSIDE_OPEN_TAG_NAME: + /* Possible next states: BETWEEN_ATTRIBUTES */ + + /* if there's a partial chunk then it's the first part of the + * tag name. If there's a context->start then it's the start + * of the tag name in current_text, the partial chunk goes + * before that start though. + */ + advance_to_name_end (context); + + if (context->iter == context->current_text_end) + { + /* The name hasn't necessarily ended. Merge with + * partial chunk, leave state unchanged. + */ + add_to_partial (context, context->start, context->iter); + } + else + { + /* The name has ended. Combine it with the partial chunk + * if any; push it on the stack; enter next state. + */ + add_to_partial (context, context->start, context->iter); + context->tag_stack = + g_slist_prepend (context->tag_stack, + g_string_free (context->partial_chunk, + FALSE)); + + context->partial_chunk = NULL; + + context->state = STATE_BETWEEN_ATTRIBUTES; + context->start = NULL; + } + break; + + case STATE_INSIDE_ATTRIBUTE_NAME: + /* Possible next states: AFTER_ATTRIBUTE_EQUALS_SIGN */ + + /* read the full name, if we enter the equals sign state + * then add the attribute to the list (without the value), + * otherwise store a partial chunk to be prepended later. + */ + advance_to_name_end (context); + + if (context->iter == context->current_text_end) + { + /* The name hasn't necessarily ended. Merge with + * partial chunk, leave state unchanged. + */ + add_to_partial (context, context->start, context->iter); + } + else + { + /* The name has ended. Combine it with the partial chunk + * if any; push it on the stack; enter next state. + */ + add_to_partial (context, context->start, context->iter); + + add_attribute (context, g_string_free (context->partial_chunk, FALSE)); + + context->partial_chunk = NULL; + context->start = NULL; + + if (*context->iter == '=') + { + advance_char (context); + context->state = STATE_AFTER_ATTRIBUTE_EQUALS_SIGN; + } + else + { + gchar buf[7]; + set_error (context, + error, + G_MARKUP_ERROR_PARSE, + _("Odd character '%s', expected a '=' after " + "attribute name '%s' of element '%s'"), + utf8_str (context->iter, buf), + current_attribute (context), + current_element (context)); + + } + } + break; + + case STATE_BETWEEN_ATTRIBUTES: + /* Possible next states: AFTER_CLOSE_ANGLE, + * AFTER_ELISION_SLASH, INSIDE_ATTRIBUTE_NAME + */ + skip_spaces (context); + + if (context->iter != context->current_text_end) + { + if (*context->iter == '/') + { + advance_char (context); + context->state = STATE_AFTER_ELISION_SLASH; + } + else if (*context->iter == '>') + { + + advance_char (context); + context->state = STATE_AFTER_CLOSE_ANGLE; + } + else if (is_name_start_char (g_utf8_get_char (context->iter))) + { + context->state = STATE_INSIDE_ATTRIBUTE_NAME; + /* start of attribute name */ + context->start = context->iter; + } + else + { + gchar buf[7]; + set_error (context, + error, + G_MARKUP_ERROR_PARSE, + _("Odd character '%s', expected a '>' or '/' " + "character to end the start tag of " + "element '%s', or optionally an attribute; " + "perhaps you used an invalid character in " + "an attribute name"), + utf8_str (context->iter, buf), + current_element (context)); + } + + /* If we're done with attributes, invoke + * the start_element callback + */ + if (context->state == STATE_AFTER_ELISION_SLASH || + context->state == STATE_AFTER_CLOSE_ANGLE) + { + const gchar *start_name; + /* Ugly, but the current code expects an empty array instead of NULL */ + const gchar *empty = NULL; + const gchar **attr_names = ∅ + const gchar **attr_values = ∅ + GError *tmp_error; + + /* Call user callback for element start */ + start_name = current_element (context); + + if (context->cur_attr >= 0) + { + attr_names = (const gchar**)context->attr_names; + attr_values = (const gchar**)context->attr_values; + } + + tmp_error = NULL; + if (context->parser->start_element) + (* context->parser->start_element) (context, + start_name, + (const gchar **)attr_names, + (const gchar **)attr_values, + context->user_data, + &tmp_error); + + /* Go ahead and free the attributes. */ + for (; context->cur_attr >= 0; context->cur_attr--) + { + int pos = context->cur_attr; + g_free (context->attr_names[pos]); + g_free (context->attr_values[pos]); + context->attr_names[pos] = context->attr_values[pos] = NULL; + } + context->cur_attr = -1; + + if (tmp_error != NULL) + { + mark_error (context, tmp_error); + g_propagate_error (error, tmp_error); + } + } + } + break; + + case STATE_AFTER_ATTRIBUTE_EQUALS_SIGN: + /* Possible next state: INSIDE_ATTRIBUTE_VALUE */ + if (*context->iter == '"') + { + advance_char (context); + context->state = STATE_INSIDE_ATTRIBUTE_VALUE; + context->start = context->iter; + } + else + { + gchar buf[7]; + set_error (context, + error, + G_MARKUP_ERROR_PARSE, + _("Odd character '%s', expected an open quote mark " + "after the equals sign when giving value for " + "attribute '%s' of element '%s'"), + utf8_str (context->iter, buf), + current_attribute (context), + current_element (context)); + } + break; + + case STATE_INSIDE_ATTRIBUTE_VALUE: + /* Possible next states: BETWEEN_ATTRIBUTES */ + do + { + if (*context->iter == '"') + break; + } + while (advance_char (context)); + + if (context->iter == context->current_text_end) + { + /* The value hasn't necessarily ended. Merge with + * partial chunk, leave state unchanged. + */ + add_to_partial (context, context->start, context->iter); + } + else + { + /* The value has ended at the quote mark. Combine it + * with the partial chunk if any; set it for the current + * attribute. + */ + add_to_partial (context, context->start, context->iter); + + g_assert (context->cur_attr >= 0); + + if (unescape_text (context, + context->partial_chunk->str, + context->partial_chunk->str + + context->partial_chunk->len, + &context->attr_values[context->cur_attr], + error)) + { + /* success, advance past quote and set state. */ + advance_char (context); + context->state = STATE_BETWEEN_ATTRIBUTES; + context->start = NULL; + } + + truncate_partial (context); + } + break; + + case STATE_INSIDE_TEXT: + /* Possible next states: AFTER_OPEN_ANGLE */ + do + { + if (*context->iter == '<') + break; + } + while (advance_char (context)); + + /* The text hasn't necessarily ended. Merge with + * partial chunk, leave state unchanged. + */ + + add_to_partial (context, context->start, context->iter); + + if (context->iter != context->current_text_end) + { + gchar *unescaped = NULL; + + /* The text has ended at the open angle. Call the text + * callback. + */ + + if (unescape_text (context, + context->partial_chunk->str, + context->partial_chunk->str + + context->partial_chunk->len, + &unescaped, + error)) + { + GError *tmp_error = NULL; + + if (context->parser->text) + (*context->parser->text) (context, + unescaped, + strlen (unescaped), + context->user_data, + &tmp_error); + + g_free (unescaped); + + if (tmp_error == NULL) + { + /* advance past open angle and set state. */ + advance_char (context); + context->state = STATE_AFTER_OPEN_ANGLE; + /* could begin a passthrough */ + context->start = context->iter; + } + else + { + mark_error (context, tmp_error); + g_propagate_error (error, tmp_error); + } + } + + truncate_partial (context); + } + break; + + case STATE_AFTER_CLOSE_TAG_SLASH: + /* Possible next state: INSIDE_CLOSE_TAG_NAME */ + if (is_name_start_char (g_utf8_get_char (context->iter))) + { + context->state = STATE_INSIDE_CLOSE_TAG_NAME; + + /* start of tag name */ + context->start = context->iter; + } + else + { + gchar buf[7]; + set_error (context, + error, + G_MARKUP_ERROR_PARSE, + _("'%s' is not a valid character following " + "the characters '</'; '%s' may not begin an " + "element name"), + utf8_str (context->iter, buf), + utf8_str (context->iter, buf)); + } + break; + + case STATE_INSIDE_CLOSE_TAG_NAME: + /* Possible next state: AFTER_CLOSE_ANGLE */ + advance_to_name_end (context); + + if (context->iter == context->current_text_end) + { + /* The name hasn't necessarily ended. Merge with + * partial chunk, leave state unchanged. + */ + add_to_partial (context, context->start, context->iter); + } + else + { + /* The name has ended. Combine it with the partial chunk + * if any; check that it matches stack top and pop + * stack; invoke proper callback; enter next state. + */ + gchar *close_name; + + add_to_partial (context, context->start, context->iter); + + close_name = g_string_free (context->partial_chunk, FALSE); + context->partial_chunk = NULL; + + if (context->tag_stack == NULL) + { + set_error (context, + error, + G_MARKUP_ERROR_PARSE, + _("Element '%s' was closed, no element " + "is currently open"), + close_name); + } + else if (strcmp (close_name, current_element (context)) != 0) + { + set_error (context, + error, + G_MARKUP_ERROR_PARSE, + _("Element '%s' was closed, but the currently " + "open element is '%s'"), + close_name, + current_element (context)); + } + else if (*context->iter != '>') + { + gchar buf[7]; + set_error (context, + error, + G_MARKUP_ERROR_PARSE, + _("'%s' is not a valid character following " + "the close element name '%s'; the allowed " + "character is '>'"), + utf8_str (context->iter, buf), + close_name); + } + else + { + GError *tmp_error; + advance_char (context); + context->state = STATE_AFTER_CLOSE_ANGLE; + context->start = NULL; + + /* call the end_element callback */ + tmp_error = NULL; + if (context->parser->end_element) + (* context->parser->end_element) (context, + close_name, + context->user_data, + &tmp_error); + + + /* Pop the tag stack */ + g_free (context->tag_stack->data); + context->tag_stack = g_slist_delete_link (context->tag_stack, + context->tag_stack); + + if (tmp_error) + { + mark_error (context, tmp_error); + g_propagate_error (error, tmp_error); + } + } + + g_free (close_name); + } + break; + + case STATE_INSIDE_PASSTHROUGH: + /* Possible next state: AFTER_CLOSE_ANGLE */ + do + { + if (*context->iter == '>') + break; + } + while (advance_char (context)); + + if (context->iter == context->current_text_end) + { + /* The passthrough hasn't necessarily ended. Merge with + * partial chunk, leave state unchanged. + */ + add_to_partial (context, context->start, context->iter); + } + else + { + /* The passthrough has ended at the close angle. Combine + * it with the partial chunk if any. Call the passthrough + * callback. Note that the open/close angles are + * included in the text of the passthrough. + */ + GError *tmp_error = NULL; + + advance_char (context); /* advance past close angle */ + add_to_partial (context, context->start, context->iter); + + if (context->parser->passthrough) + (*context->parser->passthrough) (context, + context->partial_chunk->str, + context->partial_chunk->len, + context->user_data, + &tmp_error); + + truncate_partial (context); + + if (tmp_error == NULL) + { + context->state = STATE_AFTER_CLOSE_ANGLE; + context->start = context->iter; /* could begin text */ + } + else + { + mark_error (context, tmp_error); + g_propagate_error (error, tmp_error); + } + } + break; + + case STATE_ERROR: + goto finished; + break; + + default: + g_assert_not_reached (); + break; + } + } + + finished: + context->parsing = FALSE; + + return context->state != STATE_ERROR; +} + +/** + * g_markup_parse_context_end_parse: + * @context: a #GMarkupParseContext + * @error: return location for a #GError + * + * Signals to the #GMarkupParseContext that all data has been + * fed into the parse context with g_markup_parse_context_parse(). + * This function reports an error if the document isn't complete, + * for example if elements are still open. + * + * Return value: %TRUE on success, %FALSE if an error was set + **/ +gboolean +g_markup_parse_context_end_parse (GMarkupParseContext *context, + GError **error) +{ + g_return_val_if_fail (context != NULL, FALSE); + g_return_val_if_fail (!context->parsing, FALSE); + g_return_val_if_fail (context->state != STATE_ERROR, FALSE); + + if (context->partial_chunk != NULL) + { + g_string_free (context->partial_chunk, TRUE); + context->partial_chunk = NULL; + } + + if (context->document_empty) + { + set_error (context, error, G_MARKUP_ERROR_EMPTY, + _("Document was empty or contained only whitespace")); + return FALSE; + } + + context->parsing = TRUE; + + switch (context->state) + { + case STATE_START: + /* Nothing to do */ + break; + + case STATE_AFTER_OPEN_ANGLE: + set_error (context, error, G_MARKUP_ERROR_PARSE, + _("Document ended unexpectedly just after an open angle bracket '<'")); + break; + + case STATE_AFTER_CLOSE_ANGLE: + if (context->tag_stack != NULL) + { + /* Error message the same as for INSIDE_TEXT */ + set_error (context, error, G_MARKUP_ERROR_PARSE, + _("Document ended unexpectedly with elements still open - " + "'%s' was the last element opened"), + current_element (context)); + } + break; + + case STATE_AFTER_ELISION_SLASH: + set_error (context, error, G_MARKUP_ERROR_PARSE, + _("Document ended unexpectedly, expected to see a close angle " + "bracket ending the tag <%s/>"), current_element (context)); + break; + + case STATE_INSIDE_OPEN_TAG_NAME: + set_error (context, error, G_MARKUP_ERROR_PARSE, + _("Document ended unexpectedly inside an element name")); + break; + + case STATE_INSIDE_ATTRIBUTE_NAME: + set_error (context, error, G_MARKUP_ERROR_PARSE, + _("Document ended unexpectedly inside an attribute name")); + break; + + case STATE_BETWEEN_ATTRIBUTES: + set_error (context, error, G_MARKUP_ERROR_PARSE, + _("Document ended unexpectedly inside an element-opening " + "tag.")); + break; + + case STATE_AFTER_ATTRIBUTE_EQUALS_SIGN: + set_error (context, error, G_MARKUP_ERROR_PARSE, + _("Document ended unexpectedly after the equals sign " + "following an attribute name; no attribute value")); + break; + + case STATE_INSIDE_ATTRIBUTE_VALUE: + set_error (context, error, G_MARKUP_ERROR_PARSE, + _("Document ended unexpectedly while inside an attribute " + "value")); + break; + + case STATE_INSIDE_TEXT: + g_assert (context->tag_stack != NULL); + set_error (context, error, G_MARKUP_ERROR_PARSE, + _("Document ended unexpectedly with elements still open - " + "'%s' was the last element opened"), + current_element (context)); + break; + + case STATE_AFTER_CLOSE_TAG_SLASH: + case STATE_INSIDE_CLOSE_TAG_NAME: + set_error (context, error, G_MARKUP_ERROR_PARSE, + _("Document ended unexpectedly inside the close tag for " + "element '%s'"), current_element); + break; + + case STATE_INSIDE_PASSTHROUGH: + set_error (context, error, G_MARKUP_ERROR_PARSE, + _("Document ended unexpectedly inside a comment or " + "processing instruction")); + break; + + case STATE_ERROR: + default: + g_assert_not_reached (); + break; + } + + context->parsing = FALSE; + + return context->state != STATE_ERROR; +} + +/** + * g_markup_parse_context_get_position: + * @context: a #GMarkupParseContext + * @line_number: return location for a line number, or %NULL + * @char_number: return location for a char-on-line number, or %NULL + * + * Retrieves the current line number and the number of the character on + * that line. Intended for use in error messages; there are no strict + * semantics for what constitutes the "current" line number other than + * "the best number we could come up with for error messages." + * + **/ +void +g_markup_parse_context_get_position (GMarkupParseContext *context, + gint *line_number, + gint *char_number) +{ + g_return_if_fail (context != NULL); + + if (line_number) + *line_number = context->line_number; + + if (char_number) + *char_number = context->char_number; +} + +static void +append_escaped_text (GString *str, + const gchar *text, + gssize length) +{ + const gchar *p; + const gchar *end; + + p = text; + end = text + length; + + while (p != end) + { + const gchar *next; + next = g_utf8_next_char (p); + + switch (*p) + { + case '&': + g_string_append (str, "&"); + break; + + case '<': + g_string_append (str, "<"); + break; + + case '>': + g_string_append (str, ">"); + break; + + case '\'': + g_string_append (str, "'"); + break; + + case '"': + g_string_append (str, """); + break; + + default: + g_string_append_len (str, p, next - p); + break; + } + + p = next; + } +} + +/** + * g_markup_escape_text: + * @text: some valid UTF-8 text + * @length: length of @text in bytes + * + * Escapes text so that the markup parser will parse it verbatim. + * Less than, greater than, ampersand, etc. are replaced with the + * corresponding entities. This function would typically be used + * when writing out a file to be parsed with the markup parser. + * + * Return value: escaped text + **/ +gchar* +g_markup_escape_text (const gchar *text, + gssize length) +{ + GString *str; + + g_return_val_if_fail (text != NULL, NULL); + + if (length < 0) + length = strlen (text); + + str = g_string_new (""); + append_escaped_text (str, text, length); + + return g_string_free (str, FALSE); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gmarkup.h b/graf2d/win32gdk/gdk/src/glib/gmarkup.h index 57a7c1e394711..3fba0d6771789 100644 --- a/graf2d/win32gdk/gdk/src/glib/gmarkup.h +++ b/graf2d/win32gdk/gdk/src/glib/gmarkup.h @@ -21,12 +21,9 @@ #ifndef __G_MARKUP_H__ #define __G_MARKUP_H__ -#include <gerror.h> +#include <glib/gerror.h> -#ifdef __cplusplus -extern "C" -{ -#endif +G_BEGIN_DECLS typedef enum { @@ -75,7 +72,7 @@ struct _GMarkupParser /* text is not nul-terminated */ void (*text) (GMarkupParseContext *context, const gchar *text, - gint text_len, + gsize text_len, gpointer user_data, GError **error); @@ -86,7 +83,7 @@ struct _GMarkupParser /* text is not nul-terminated. */ void (*passthrough) (GMarkupParseContext *context, const gchar *passthrough_text, - gint text_len, + gsize text_len, gpointer user_data, GError **error); @@ -105,7 +102,7 @@ GMarkupParseContext *g_markup_parse_context_new (const GMarkupParser *parser, void g_markup_parse_context_free (GMarkupParseContext *context); gboolean g_markup_parse_context_parse (GMarkupParseContext *context, const gchar *text, - gint text_len, + gssize text_len, GError **error); gboolean g_markup_parse_context_end_parse (GMarkupParseContext *context, @@ -118,12 +115,9 @@ void g_markup_parse_context_get_position (GMarkupParseContext *c /* useful when saving */ gchar* g_markup_escape_text (const gchar *text, - gint length); - + gssize length); -#ifdef __cplusplus -} -#endif +G_END_DECLS #endif /* __G_MARKUP_H__ */ diff --git a/graf2d/win32gdk/gdk/src/glib/gmem.c b/graf2d/win32gdk/gdk/src/glib/gmem.c new file mode 100644 index 0000000000000..43623aa04f543 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gmem.c @@ -0,0 +1,1262 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include <string.h> +#include "glib.h" + + +/* notes on macros: + * having DISABLE_MEM_POOLS defined, disables mem_chunks alltogether, their + * allocations are performed through ordinary g_malloc/g_free. + * having G_DISABLE_CHECKS defined disables use of glib_mem_profiler_table and + * g_mem_profile(). + * REALLOC_0_WORKS is defined if g_realloc (NULL, x) works. + * SANE_MALLOC_PROTOS is defined if the systems malloc() and friends functions + * match the corresponding GLib prototypes, keep configure.in and gmem.h in sync here. + * if ENABLE_GC_FRIENDLY is defined, freed memory should be 0-wiped. + */ + +#define MEM_PROFILE_TABLE_SIZE 4096 + +#define MEM_AREA_SIZE 4L + +#ifdef G_DISABLE_CHECKS +# define ENTER_MEM_CHUNK_ROUTINE() +# define LEAVE_MEM_CHUNK_ROUTINE() +# define IN_MEM_CHUNK_ROUTINE() FALSE +#else /* !G_DISABLE_CHECKS */ +static GPrivate* mem_chunk_recursion = NULL; +# define MEM_CHUNK_ROUTINE_COUNT() GPOINTER_TO_UINT (g_private_get (mem_chunk_recursion)) +# define ENTER_MEM_CHUNK_ROUTINE() g_private_set (mem_chunk_recursion, GUINT_TO_POINTER (MEM_CHUNK_ROUTINE_COUNT () + 1)) +# define LEAVE_MEM_CHUNK_ROUTINE() g_private_set (mem_chunk_recursion, GUINT_TO_POINTER (MEM_CHUNK_ROUTINE_COUNT () - 1)) +#endif /* !G_DISABLE_CHECKS */ + +#ifndef REALLOC_0_WORKS +static gpointer +standard_realloc (gpointer mem, + gsize n_bytes) +{ + if (!mem) + return malloc (n_bytes); + else + return realloc (mem, n_bytes); +} +#endif /* !REALLOC_0_WORKS */ + +#ifdef SANE_MALLOC_PROTOS +# define standard_malloc malloc +# ifdef REALLOC_0_WORKS +# define standard_realloc realloc +# endif /* REALLOC_0_WORKS */ +# define standard_free free +# define standard_calloc calloc +# define standard_try_malloc malloc +# define standard_try_realloc realloc +#else /* !SANE_MALLOC_PROTOS */ +static gpointer +standard_malloc (gsize n_bytes) +{ + return malloc (n_bytes); +} +# ifdef REALLOC_0_WORKS +static gpointer +standard_realloc (gpointer mem, + gsize n_bytes) +{ + return realloc (mem, n_bytes); +} +# endif /* REALLOC_0_WORKS */ +static void +standard_free (gpointer mem) +{ + free (mem); +} +static gpointer +standard_calloc (gsize n_blocks, + gsize n_bytes) +{ + return calloc (n_blocks, n_bytes); +} +#define standard_try_malloc standard_malloc +#define standard_try_realloc standard_realloc +#endif /* !SANE_MALLOC_PROTOS */ + + +/* --- variables --- */ +static GMemVTable glib_mem_vtable = { + standard_malloc, + standard_realloc, + standard_free, + standard_calloc, + standard_try_malloc, + standard_try_realloc, +}; + + +/* --- functions --- */ +gpointer +g_malloc (gulong n_bytes) +{ + if (n_bytes) + { + gpointer mem; + + mem = glib_mem_vtable.malloc (n_bytes); + if (mem) + return mem; + + g_error ("%s: failed to allocate %lu bytes", G_STRLOC, n_bytes); + } + + return NULL; +} + +gpointer +g_malloc0 (gulong n_bytes) +{ + if (n_bytes) + { + gpointer mem; + + mem = glib_mem_vtable.calloc (1, n_bytes); + if (mem) + return mem; + + g_error ("%s: failed to allocate %lu bytes", G_STRLOC, n_bytes); + } + + return NULL; +} + +gpointer +g_realloc (gpointer mem, + gulong n_bytes) +{ + if (n_bytes) + { + mem = glib_mem_vtable.realloc (mem, n_bytes); + if (mem) + return mem; + + g_error ("%s: failed to allocate %lu bytes", G_STRLOC, n_bytes); + } + + if (mem) + glib_mem_vtable.free (mem); + + return NULL; +} + +void +g_free (gpointer mem) +{ + if (mem) + glib_mem_vtable.free (mem); +} + +gpointer +g_try_malloc (gulong n_bytes) +{ + if (n_bytes) + return glib_mem_vtable.try_malloc (n_bytes); + else + return NULL; +} + +gpointer +g_try_realloc (gpointer mem, + gulong n_bytes) +{ + if (n_bytes) + return glib_mem_vtable.try_realloc (mem, n_bytes); + + if (mem) + glib_mem_vtable.free (mem); + + return NULL; +} + +static gpointer +fallback_calloc (gsize n_blocks, + gsize n_block_bytes) +{ + gsize l = n_blocks * n_block_bytes; + gpointer mem = glib_mem_vtable.malloc (l); + + if (mem) + memset (mem, 0, l); + + return mem; +} + +static gboolean vtable_set = FALSE; + +/** + * g_mem_is_system_malloc + * + * Checks whether the allocator used by g_malloc() is the system's + * malloc implementation. If it returns %TRUE memory allocated with + * malloc() can be used interchangeable with memory allocated using + * g_malloc(). This function is useful for avoiding an extra copy + * of allocated memory returned by a non-GLib-based API. + * + * A different allocator can be set using g_mem_set_vtable(). + * + * Return value: if %TRUE, malloc() and g_malloc() can be mixed. + **/ +gboolean +g_mem_is_system_malloc (void) +{ + return vtable_set; +} + +void +g_mem_set_vtable (GMemVTable *vtable) +{ + if (!vtable_set) + { + vtable_set = TRUE; + if (vtable->malloc && vtable->realloc && vtable->free) + { + glib_mem_vtable.malloc = vtable->malloc; + glib_mem_vtable.realloc = vtable->realloc; + glib_mem_vtable.free = vtable->free; + glib_mem_vtable.calloc = vtable->calloc ? vtable->calloc : fallback_calloc; + glib_mem_vtable.try_malloc = vtable->try_malloc ? vtable->try_malloc : glib_mem_vtable.malloc; + glib_mem_vtable.try_realloc = vtable->try_realloc ? vtable->try_realloc : glib_mem_vtable.realloc; + } + else + g_warning (G_STRLOC ": memory allocation vtable lacks one of malloc(), realloc() or free()"); + } + else + g_warning (G_STRLOC ": memory allocation vtable can only be set once at startup"); +} + + +/* --- memory profiling and checking --- */ +#ifdef G_DISABLE_CHECKS +GMemVTable *glib_mem_profiler_table = &glib_mem_vtable; +void +g_mem_profile (void) +{ +} +#else /* !G_DISABLE_CHECKS */ +typedef enum { + PROFILER_FREE = 0, + PROFILER_ALLOC = 1, + PROFILER_RELOC = 2, + PROFILER_ZINIT = 4 +} ProfilerJob; +static guint *profile_data = NULL; +static gulong profile_allocs = 0; +static gulong profile_mc_allocs = 0; +static gulong profile_zinit = 0; +static gulong profile_frees = 0; +static gulong profile_mc_frees = 0; +static GMutex *g_profile_mutex = NULL; +#ifdef G_ENABLE_DEBUG +static volatile gulong g_trap_free_size = 0; +static volatile gulong g_trap_realloc_size = 0; +static volatile gulong g_trap_malloc_size = 0; +#endif /* G_ENABLE_DEBUG */ + +#define PROFILE_TABLE(f1,f2,f3) ( ( ((f3) << 2) | ((f2) << 1) | (f1) ) * (MEM_PROFILE_TABLE_SIZE + 1)) + +static void +profiler_log (ProfilerJob job, + gulong n_bytes, + gboolean success) +{ + g_mutex_lock (g_profile_mutex); + if (!profile_data) + { + profile_data = standard_malloc ((MEM_PROFILE_TABLE_SIZE + 1) * 8 * sizeof (profile_data[0])); + if (!profile_data) /* memory system kiddin' me, eh? */ + { + g_mutex_unlock (g_profile_mutex); + return; + } + } + + if (MEM_CHUNK_ROUTINE_COUNT () == 0) + { + if (n_bytes < MEM_PROFILE_TABLE_SIZE) + profile_data[n_bytes + PROFILE_TABLE ((job & PROFILER_ALLOC) != 0, + (job & PROFILER_RELOC) != 0, + success != 0)] += 1; + else + profile_data[MEM_PROFILE_TABLE_SIZE + PROFILE_TABLE ((job & PROFILER_ALLOC) != 0, + (job & PROFILER_RELOC) != 0, + success != 0)] += 1; + if (success) + { + if (job & PROFILER_ALLOC) + { + profile_allocs += n_bytes; + if (job & PROFILER_ZINIT) + profile_zinit += n_bytes; + } + else + profile_frees += n_bytes; + } + } + else if (success) + { + if (job & PROFILER_ALLOC) + profile_mc_allocs += n_bytes; + else + profile_mc_frees += n_bytes; + } + g_mutex_unlock (g_profile_mutex); +} + +static void +profile_print_locked (guint *local_data, + gboolean success) +{ + gboolean need_header = TRUE; + guint i; + + for (i = 0; i <= MEM_PROFILE_TABLE_SIZE; i++) + { + glong t_malloc = local_data[i + PROFILE_TABLE (1, 0, success)]; + glong t_realloc = local_data[i + PROFILE_TABLE (1, 1, success)]; + glong t_free = local_data[i + PROFILE_TABLE (0, 0, success)]; + glong t_refree = local_data[i + PROFILE_TABLE (0, 1, success)]; + + if (!t_malloc && !t_realloc && !t_free && !t_refree) + continue; + else if (need_header) + { + need_header = FALSE; + g_print (" blocks of | allocated | freed | allocated | freed | n_bytes \n"); + g_print (" n_bytes | n_times by | n_times by | n_times by | n_times by | remaining \n"); + g_print (" | malloc() | free() | realloc() | realloc() | \n"); + g_print ("===========|============|============|============|============|===========\n"); + } + if (i < MEM_PROFILE_TABLE_SIZE) + g_print ("%10u | %10ld | %10ld | %10ld | %10ld |%+11ld\n", + i, t_malloc, t_free, t_realloc, t_refree, + (t_malloc - t_free + t_realloc - t_refree) * i); + else if (i >= MEM_PROFILE_TABLE_SIZE) + g_print (" >%6u | %10ld | %10ld | %10ld | %10ld | ***\n", + i, t_malloc, t_free, t_realloc, t_refree); + } + if (need_header) + g_print (" --- none ---\n"); +} + +void +g_mem_profile (void) +{ + guint local_data[(MEM_PROFILE_TABLE_SIZE + 1) * 8 * sizeof (profile_data[0])]; + gulong local_allocs; + gulong local_zinit; + gulong local_frees; + gulong local_mc_allocs; + gulong local_mc_frees; + + g_mutex_lock (g_profile_mutex); + + local_allocs = profile_allocs; + local_zinit = profile_zinit; + local_frees = profile_frees; + local_mc_allocs = profile_mc_allocs; + local_mc_frees = profile_mc_frees; + + if (!profile_data) + { + g_mutex_unlock (g_profile_mutex); + return; + } + + memcpy (local_data, profile_data, + (MEM_PROFILE_TABLE_SIZE + 1) * 8 * sizeof (profile_data[0])); + + g_mutex_unlock (g_profile_mutex); + + g_print ("GLib Memory statistics (successful operations):\n"); + profile_print_locked (local_data, TRUE); + g_print ("GLib Memory statistics (failing operations):\n"); + profile_print_locked (local_data, FALSE); + g_print ("Total bytes: allocated=%lu, zero-initialized=%lu (%.2f%%), freed=%lu (%.2f%%), remaining=%lu\n", + local_allocs, + local_zinit, + ((gdouble) local_zinit) / local_allocs * 100.0, + local_frees, + ((gdouble) local_frees) / local_allocs * 100.0, + local_allocs - local_frees); + g_print ("MemChunk bytes: allocated=%lu, freed=%lu (%.2f%%), remaining=%lu\n", + local_mc_allocs, + local_mc_frees, + ((gdouble) local_mc_frees) / local_mc_allocs * 100.0, + local_mc_allocs - local_mc_frees); +} + +static gpointer +profiler_try_malloc (gsize n_bytes) +{ + gulong *p; + +#ifdef G_ENABLE_DEBUG + if (g_trap_malloc_size == n_bytes) + G_BREAKPOINT (); +#endif /* G_ENABLE_DEBUG */ + + p = standard_malloc (sizeof (gulong) * 2 + n_bytes); + + if (p) + { + p[0] = 0; /* free count */ + p[1] = n_bytes; /* length */ + profiler_log (PROFILER_ALLOC, n_bytes, TRUE); + p += 2; + } + else + profiler_log (PROFILER_ALLOC, n_bytes, FALSE); + + return p; +} + +static gpointer +profiler_malloc (gsize n_bytes) +{ + gpointer mem = profiler_try_malloc (n_bytes); + + if (!mem) + g_mem_profile (); + + return mem; +} + +static gpointer +profiler_calloc (gsize n_blocks, + gsize n_block_bytes) +{ + gsize l = n_blocks * n_block_bytes; + gulong *p; + +#ifdef G_ENABLE_DEBUG + if (g_trap_malloc_size == l) + G_BREAKPOINT (); +#endif /* G_ENABLE_DEBUG */ + + p = standard_calloc (1, sizeof (gulong) * 2 + l); + + if (p) + { + p[0] = 0; /* free count */ + p[1] = l; /* length */ + profiler_log (PROFILER_ALLOC | PROFILER_ZINIT, l, TRUE); + p += 2; + } + else + { + profiler_log (PROFILER_ALLOC | PROFILER_ZINIT, l, FALSE); + g_mem_profile (); + } + + return p; +} + +static void +profiler_free (gpointer mem) +{ + gulong *p = mem; + + p -= 2; + if (p[0]) /* free count */ + { + g_warning ("free(%p): memory has been freed %lu times already", p + 2, p[0]); + profiler_log (PROFILER_FREE, + p[1], /* length */ + FALSE); + } + else + { +#ifdef G_ENABLE_DEBUG + if (g_trap_free_size == p[1]) + G_BREAKPOINT (); +#endif /* G_ENABLE_DEBUG */ + + profiler_log (PROFILER_FREE, + p[1], /* length */ + TRUE); + memset (p + 2, 0xaa, p[1]); + + /* for all those that miss standard_free (p); in this place, yes, + * we do leak all memory when profiling, and that is intentional + * to catch double frees. patch submissions are futile. + */ + } + p[0] += 1; +} + +static gpointer +profiler_try_realloc (gpointer mem, + gsize n_bytes) +{ + gulong *p = mem; + + p -= 2; + +#ifdef G_ENABLE_DEBUG + if (g_trap_realloc_size == n_bytes) + G_BREAKPOINT (); +#endif /* G_ENABLE_DEBUG */ + + if (mem && p[0]) /* free count */ + { + g_warning ("realloc(%p, %u): memory has been freed %lu times already", p + 2, n_bytes, p[0]); + profiler_log (PROFILER_ALLOC | PROFILER_RELOC, n_bytes, FALSE); + + return NULL; + } + else + { + p = standard_realloc (mem ? p : NULL, sizeof (gulong) * 2 + n_bytes); + + if (p) + { + if (mem) + profiler_log (PROFILER_FREE | PROFILER_RELOC, p[1], TRUE); + p[0] = 0; + p[1] = n_bytes; + profiler_log (PROFILER_ALLOC | PROFILER_RELOC, p[1], TRUE); + p += 2; + } + else + profiler_log (PROFILER_ALLOC | PROFILER_RELOC, n_bytes, FALSE); + + return p; + } +} + +static gpointer +profiler_realloc (gpointer mem, + gsize n_bytes) +{ + mem = profiler_try_realloc (mem, n_bytes); + + if (!mem) + g_mem_profile (); + + return mem; +} + +static GMemVTable profiler_table = { + profiler_malloc, + profiler_realloc, + profiler_free, + profiler_calloc, + profiler_try_malloc, + profiler_try_realloc, +}; +GMemVTable *glib_mem_profiler_table = &profiler_table; + +#endif /* !G_DISABLE_CHECKS */ + + +/* --- MemChunks --- */ +typedef struct _GFreeAtom GFreeAtom; +typedef struct _GMemArea GMemArea; + +struct _GFreeAtom +{ + GFreeAtom *next; +}; + +struct _GMemArea +{ + GMemArea *next; /* the next mem area */ + GMemArea *prev; /* the previous mem area */ + gulong index; /* the current index into the "mem" array */ + gulong free; /* the number of free bytes in this mem area */ + gulong allocated; /* the number of atoms allocated from this area */ + gulong mark; /* is this mem area marked for deletion */ + gchar mem[MEM_AREA_SIZE]; /* the mem array from which atoms get allocated + * the actual size of this array is determined by + * the mem chunk "area_size". ANSI says that it + * must be declared to be the maximum size it + * can possibly be (even though the actual size + * may be less). + */ +}; + +struct _GMemChunk +{ + const gchar *name; /* name of this MemChunk...used for debugging output */ + gint type; /* the type of MemChunk: ALLOC_ONLY or ALLOC_AND_FREE */ + gint num_mem_areas; /* the number of memory areas */ + gint num_marked_areas; /* the number of areas marked for deletion */ + guint atom_size; /* the size of an atom */ + gulong area_size; /* the size of a memory area */ + GMemArea *mem_area; /* the current memory area */ + GMemArea *mem_areas; /* a list of all the mem areas owned by this chunk */ + GMemArea *free_mem_area; /* the free area...which is about to be destroyed */ + GFreeAtom *free_atoms; /* the free atoms list */ + GTree *mem_tree; /* tree of mem areas sorted by memory address */ + GMemChunk *next; /* pointer to the next chunk */ + GMemChunk *prev; /* pointer to the previous chunk */ +}; + + +#ifndef DISABLE_MEM_POOLS +static gulong g_mem_chunk_compute_size (gulong size, + gulong min_size) G_GNUC_CONST; +static gint g_mem_chunk_area_compare (GMemArea *a, + GMemArea *b); +static gint g_mem_chunk_area_search (GMemArea *a, + gchar *addr); + +/* here we can't use StaticMutexes, as they depend upon a working + * g_malloc, the same holds true for StaticPrivate + */ +static GMutex *mem_chunks_lock = NULL; +static GMemChunk *mem_chunks = NULL; + +GMemChunk* +g_mem_chunk_new (const gchar *name, + gint atom_size, + gulong area_size, + gint type) +{ + GMemChunk *mem_chunk; + gulong rarea_size; + + g_return_val_if_fail (atom_size > 0, NULL); + g_return_val_if_fail (area_size >= atom_size, NULL); + + ENTER_MEM_CHUNK_ROUTINE (); + + area_size = (area_size + atom_size - 1) / atom_size; + area_size *= atom_size; + + mem_chunk = g_new (GMemChunk, 1); + mem_chunk->name = name; + mem_chunk->type = type; + mem_chunk->num_mem_areas = 0; + mem_chunk->num_marked_areas = 0; + mem_chunk->mem_area = NULL; + mem_chunk->free_mem_area = NULL; + mem_chunk->free_atoms = NULL; + mem_chunk->mem_tree = NULL; + mem_chunk->mem_areas = NULL; + mem_chunk->atom_size = atom_size; + + if (mem_chunk->type == G_ALLOC_AND_FREE) + mem_chunk->mem_tree = g_tree_new ((GCompareFunc) g_mem_chunk_area_compare); + + if (mem_chunk->atom_size % G_MEM_ALIGN) + mem_chunk->atom_size += G_MEM_ALIGN - (mem_chunk->atom_size % G_MEM_ALIGN); + + rarea_size = area_size + sizeof (GMemArea) - MEM_AREA_SIZE; + rarea_size = g_mem_chunk_compute_size (rarea_size, atom_size + sizeof (GMemArea) - MEM_AREA_SIZE); + mem_chunk->area_size = rarea_size - (sizeof (GMemArea) - MEM_AREA_SIZE); + + g_mutex_lock (mem_chunks_lock); + mem_chunk->next = mem_chunks; + mem_chunk->prev = NULL; + if (mem_chunks) + mem_chunks->prev = mem_chunk; + mem_chunks = mem_chunk; + g_mutex_unlock (mem_chunks_lock); + + LEAVE_MEM_CHUNK_ROUTINE (); + + return mem_chunk; +} + +void +g_mem_chunk_destroy (GMemChunk *mem_chunk) +{ + GMemArea *mem_areas; + GMemArea *temp_area; + + g_return_if_fail (mem_chunk != NULL); + + ENTER_MEM_CHUNK_ROUTINE (); + + mem_areas = mem_chunk->mem_areas; + while (mem_areas) + { + temp_area = mem_areas; + mem_areas = mem_areas->next; + g_free (temp_area); + } + + if (mem_chunk->next) + mem_chunk->next->prev = mem_chunk->prev; + if (mem_chunk->prev) + mem_chunk->prev->next = mem_chunk->next; + + g_mutex_lock (mem_chunks_lock); + if (mem_chunk == mem_chunks) + mem_chunks = mem_chunks->next; + g_mutex_unlock (mem_chunks_lock); + + if (mem_chunk->type == G_ALLOC_AND_FREE) + g_tree_destroy (mem_chunk->mem_tree); + + g_free (mem_chunk); + + LEAVE_MEM_CHUNK_ROUTINE (); +} + +gpointer +g_mem_chunk_alloc (GMemChunk *mem_chunk) +{ + GMemArea *temp_area; + gpointer mem; + + ENTER_MEM_CHUNK_ROUTINE (); + + g_return_val_if_fail (mem_chunk != NULL, NULL); + + while (mem_chunk->free_atoms) + { + /* Get the first piece of memory on the "free_atoms" list. + * We can go ahead and destroy the list node we used to keep + * track of it with and to update the "free_atoms" list to + * point to its next element. + */ + mem = mem_chunk->free_atoms; + mem_chunk->free_atoms = mem_chunk->free_atoms->next; + + /* Determine which area this piece of memory is allocated from */ + temp_area = g_tree_search (mem_chunk->mem_tree, + (GCompareFunc) g_mem_chunk_area_search, + mem); + + /* If the area has been marked, then it is being destroyed. + * (ie marked to be destroyed). + * We check to see if all of the segments on the free list that + * reference this area have been removed. This occurs when + * the ammount of free memory is less than the allocatable size. + * If the chunk should be freed, then we place it in the "free_mem_area". + * This is so we make sure not to free the mem area here and then + * allocate it again a few lines down. + * If we don't allocate a chunk a few lines down then the "free_mem_area" + * will be freed. + * If there is already a "free_mem_area" then we'll just free this mem area. + */ + if (temp_area->mark) + { + /* Update the "free" memory available in that area */ + temp_area->free += mem_chunk->atom_size; + + if (temp_area->free == mem_chunk->area_size) + { + if (temp_area == mem_chunk->mem_area) + mem_chunk->mem_area = NULL; + + if (mem_chunk->free_mem_area) + { + mem_chunk->num_mem_areas -= 1; + + if (temp_area->next) + temp_area->next->prev = temp_area->prev; + if (temp_area->prev) + temp_area->prev->next = temp_area->next; + if (temp_area == mem_chunk->mem_areas) + mem_chunk->mem_areas = mem_chunk->mem_areas->next; + + if (mem_chunk->type == G_ALLOC_AND_FREE) + g_tree_remove (mem_chunk->mem_tree, temp_area); + g_free (temp_area); + } + else + mem_chunk->free_mem_area = temp_area; + + mem_chunk->num_marked_areas -= 1; + } + } + else + { + /* Update the number of allocated atoms count. + */ + temp_area->allocated += 1; + + /* The area wasn't marked...return the memory + */ + goto outa_here; + } + } + + /* If there isn't a current mem area or the current mem area is out of space + * then allocate a new mem area. We'll first check and see if we can use + * the "free_mem_area". Otherwise we'll just malloc the mem area. + */ + if ((!mem_chunk->mem_area) || + ((mem_chunk->mem_area->index + mem_chunk->atom_size) > mem_chunk->area_size)) + { + if (mem_chunk->free_mem_area) + { + mem_chunk->mem_area = mem_chunk->free_mem_area; + mem_chunk->free_mem_area = NULL; + } + else + { +#ifdef ENABLE_GC_FRIENDLY + mem_chunk->mem_area = (GMemArea*) g_malloc0 (sizeof (GMemArea) - + MEM_AREA_SIZE + + mem_chunk->area_size); +#else /* !ENABLE_GC_FRIENDLY */ + mem_chunk->mem_area = (GMemArea*) g_malloc (sizeof (GMemArea) - + MEM_AREA_SIZE + + mem_chunk->area_size); +#endif /* ENABLE_GC_FRIENDLY */ + + mem_chunk->num_mem_areas += 1; + mem_chunk->mem_area->next = mem_chunk->mem_areas; + mem_chunk->mem_area->prev = NULL; + + if (mem_chunk->mem_areas) + mem_chunk->mem_areas->prev = mem_chunk->mem_area; + mem_chunk->mem_areas = mem_chunk->mem_area; + + if (mem_chunk->type == G_ALLOC_AND_FREE) + g_tree_insert (mem_chunk->mem_tree, mem_chunk->mem_area, mem_chunk->mem_area); + } + + mem_chunk->mem_area->index = 0; + mem_chunk->mem_area->free = mem_chunk->area_size; + mem_chunk->mem_area->allocated = 0; + mem_chunk->mem_area->mark = 0; + } + + /* Get the memory and modify the state variables appropriately. + */ + mem = (gpointer) &mem_chunk->mem_area->mem[mem_chunk->mem_area->index]; + mem_chunk->mem_area->index += mem_chunk->atom_size; + mem_chunk->mem_area->free -= mem_chunk->atom_size; + mem_chunk->mem_area->allocated += 1; + +outa_here: + + LEAVE_MEM_CHUNK_ROUTINE (); + + return mem; +} + +gpointer +g_mem_chunk_alloc0 (GMemChunk *mem_chunk) +{ + gpointer mem; + + mem = g_mem_chunk_alloc (mem_chunk); + if (mem) + { + memset (mem, 0, mem_chunk->atom_size); + } + + return mem; +} + +void +g_mem_chunk_free (GMemChunk *mem_chunk, + gpointer mem) +{ + GMemArea *temp_area; + GFreeAtom *free_atom; + + g_return_if_fail (mem_chunk != NULL); + g_return_if_fail (mem != NULL); + + ENTER_MEM_CHUNK_ROUTINE (); + +#ifdef ENABLE_GC_FRIENDLY + memset (mem, 0, mem_chunk->atom_size); +#endif /* ENABLE_GC_FRIENDLY */ + + /* Don't do anything if this is an ALLOC_ONLY chunk + */ + if (mem_chunk->type == G_ALLOC_AND_FREE) + { + /* Place the memory on the "free_atoms" list + */ + free_atom = (GFreeAtom*) mem; + free_atom->next = mem_chunk->free_atoms; + mem_chunk->free_atoms = free_atom; + + temp_area = g_tree_search (mem_chunk->mem_tree, + (GCompareFunc) g_mem_chunk_area_search, + mem); + + temp_area->allocated -= 1; + + if (temp_area->allocated == 0) + { + temp_area->mark = 1; + mem_chunk->num_marked_areas += 1; + } + } + + LEAVE_MEM_CHUNK_ROUTINE (); +} + +/* This doesn't free the free_area if there is one */ +void +g_mem_chunk_clean (GMemChunk *mem_chunk) +{ + GMemArea *mem_area; + GFreeAtom *prev_free_atom; + GFreeAtom *temp_free_atom; + gpointer mem; + + g_return_if_fail (mem_chunk != NULL); + + ENTER_MEM_CHUNK_ROUTINE (); + + if (mem_chunk->type == G_ALLOC_AND_FREE) + { + prev_free_atom = NULL; + temp_free_atom = mem_chunk->free_atoms; + + while (temp_free_atom) + { + mem = (gpointer) temp_free_atom; + + mem_area = g_tree_search (mem_chunk->mem_tree, + (GCompareFunc) g_mem_chunk_area_search, + mem); + + /* If this mem area is marked for destruction then delete the + * area and list node and decrement the free mem. + */ + if (mem_area->mark) + { + if (prev_free_atom) + prev_free_atom->next = temp_free_atom->next; + else + mem_chunk->free_atoms = temp_free_atom->next; + temp_free_atom = temp_free_atom->next; + + mem_area->free += mem_chunk->atom_size; + if (mem_area->free == mem_chunk->area_size) + { + mem_chunk->num_mem_areas -= 1; + mem_chunk->num_marked_areas -= 1; + + if (mem_area->next) + mem_area->next->prev = mem_area->prev; + if (mem_area->prev) + mem_area->prev->next = mem_area->next; + if (mem_area == mem_chunk->mem_areas) + mem_chunk->mem_areas = mem_chunk->mem_areas->next; + if (mem_area == mem_chunk->mem_area) + mem_chunk->mem_area = NULL; + + if (mem_chunk->type == G_ALLOC_AND_FREE) + g_tree_remove (mem_chunk->mem_tree, mem_area); + g_free (mem_area); + } + } + else + { + prev_free_atom = temp_free_atom; + temp_free_atom = temp_free_atom->next; + } + } + } + LEAVE_MEM_CHUNK_ROUTINE (); +} + +void +g_mem_chunk_reset (GMemChunk *mem_chunk) +{ + GMemArea *mem_areas; + GMemArea *temp_area; + + g_return_if_fail (mem_chunk != NULL); + + ENTER_MEM_CHUNK_ROUTINE (); + + mem_areas = mem_chunk->mem_areas; + mem_chunk->num_mem_areas = 0; + mem_chunk->mem_areas = NULL; + mem_chunk->mem_area = NULL; + + while (mem_areas) + { + temp_area = mem_areas; + mem_areas = mem_areas->next; + g_free (temp_area); + } + + mem_chunk->free_atoms = NULL; + + if (mem_chunk->mem_tree) + g_tree_destroy (mem_chunk->mem_tree); + mem_chunk->mem_tree = g_tree_new ((GCompareFunc) g_mem_chunk_area_compare); + + LEAVE_MEM_CHUNK_ROUTINE (); +} + +void +g_mem_chunk_print (GMemChunk *mem_chunk) +{ + GMemArea *mem_areas; + gulong mem; + + g_return_if_fail (mem_chunk != NULL); + + mem_areas = mem_chunk->mem_areas; + mem = 0; + + while (mem_areas) + { + mem += mem_chunk->area_size - mem_areas->free; + mem_areas = mem_areas->next; + } + + g_log (g_log_domain_glib, G_LOG_LEVEL_INFO, + "%s: %ld bytes using %d mem areas", + mem_chunk->name, mem, mem_chunk->num_mem_areas); +} + +void +g_mem_chunk_info (void) +{ + GMemChunk *mem_chunk; + gint count; + + count = 0; + g_mutex_lock (mem_chunks_lock); + mem_chunk = mem_chunks; + while (mem_chunk) + { + count += 1; + mem_chunk = mem_chunk->next; + } + g_mutex_unlock (mem_chunks_lock); + + g_log (g_log_domain_glib, G_LOG_LEVEL_INFO, "%d mem chunks", count); + + g_mutex_lock (mem_chunks_lock); + mem_chunk = mem_chunks; + g_mutex_unlock (mem_chunks_lock); + + while (mem_chunk) + { + g_mem_chunk_print ((GMemChunk*) mem_chunk); + mem_chunk = mem_chunk->next; + } +} + +void +g_blow_chunks (void) +{ + GMemChunk *mem_chunk; + + g_mutex_lock (mem_chunks_lock); + mem_chunk = mem_chunks; + g_mutex_unlock (mem_chunks_lock); + while (mem_chunk) + { + g_mem_chunk_clean ((GMemChunk*) mem_chunk); + mem_chunk = mem_chunk->next; + } +} + +static gulong +g_mem_chunk_compute_size (gulong size, + gulong min_size) +{ + gulong power_of_2; + gulong lower, upper; + + power_of_2 = 16; + while (power_of_2 < size) + power_of_2 <<= 1; + + lower = power_of_2 >> 1; + upper = power_of_2; + + if (size - lower < upper - size && lower >= min_size) + return lower; + else + return upper; +} + +static gint +g_mem_chunk_area_compare (GMemArea *a, + GMemArea *b) +{ + if (a->mem > b->mem) + return 1; + else if (a->mem < b->mem) + return -1; + return 0; +} + +static gint +g_mem_chunk_area_search (GMemArea *a, + gchar *addr) +{ + if (a->mem <= addr) + { + if (addr < &a->mem[a->index]) + return 0; + return 1; + } + return -1; +} + +#else /* DISABLE_MEM_POOLS */ + +typedef struct { + guint alloc_size; /* the size of an atom */ +} GMinimalMemChunk; + +GMemChunk* +g_mem_chunk_new (const gchar *name, + gint atom_size, + gulong area_size, + gint type) +{ + GMinimalMemChunk *mem_chunk; + + g_return_val_if_fail (atom_size > 0, NULL); + + mem_chunk = g_new (GMinimalMemChunk, 1); + mem_chunk->alloc_size = atom_size; + + return ((GMemChunk*) mem_chunk); +} + +void +g_mem_chunk_destroy (GMemChunk *mem_chunk) +{ + g_return_if_fail (mem_chunk != NULL); + + g_free (mem_chunk); +} + +gpointer +g_mem_chunk_alloc (GMemChunk *mem_chunk) +{ + GMinimalMemChunk *minimal = (GMinimalMemChunk *)mem_chunk; + + g_return_val_if_fail (mem_chunk != NULL, NULL); + + return g_malloc (minimal->alloc_size); +} + +gpointer +g_mem_chunk_alloc0 (GMemChunk *mem_chunk) +{ + GMinimalMemChunk *minimal = (GMinimalMemChunk *)mem_chunk; + + g_return_val_if_fail (mem_chunk != NULL, NULL); + + return g_malloc0 (minimal->alloc_size); +} + +void +g_mem_chunk_free (GMemChunk *mem_chunk, + gpointer mem) +{ + g_return_if_fail (mem_chunk != NULL); + + g_free (mem); +} + +void g_mem_chunk_clean (GMemChunk *mem_chunk) {} +void g_mem_chunk_reset (GMemChunk *mem_chunk) {} +void g_mem_chunk_print (GMemChunk *mem_chunk) {} +void g_mem_chunk_info (void) {} +void g_blow_chunks (void) {} + +#endif /* DISABLE_MEM_POOLS */ + + +/* generic allocators + */ +struct _GAllocator /* from gmem.c */ +{ + gchar *name; + guint16 n_preallocs; + guint is_unused : 1; + guint type : 4; + GAllocator *last; + GMemChunk *mem_chunk; + gpointer dummy; /* implementation specific */ +}; + +GAllocator* +g_allocator_new (const gchar *name, + guint n_preallocs) +{ + GAllocator *allocator; + + g_return_val_if_fail (name != NULL, NULL); + + allocator = g_new0 (GAllocator, 1); + allocator->name = g_strdup (name); + allocator->n_preallocs = CLAMP (n_preallocs, 1, 65535); + allocator->is_unused = TRUE; + allocator->type = 0; + allocator->last = NULL; + allocator->mem_chunk = NULL; + allocator->dummy = NULL; + + return allocator; +} + +void +g_allocator_free (GAllocator *allocator) +{ + g_return_if_fail (allocator != NULL); + g_return_if_fail (allocator->is_unused == TRUE); + + g_free (allocator->name); + if (allocator->mem_chunk) + g_mem_chunk_destroy (allocator->mem_chunk); + + g_free (allocator); +} + +void +g_mem_init (void) +{ +#ifndef DISABLE_MEM_POOLS + mem_chunks_lock = g_mutex_new (); +#endif +#ifndef G_DISABLE_CHECKS + mem_chunk_recursion = g_private_new (NULL); + g_profile_mutex = g_mutex_new (); +#endif +} diff --git a/graf2d/win32gdk/gdk/src/glib/gmem.h b/graf2d/win32gdk/gdk/src/glib/gmem.h index e9cdb867d8ae6..9d5b41850e99b 100644 --- a/graf2d/win32gdk/gdk/src/glib/gmem.h +++ b/graf2d/win32gdk/gdk/src/glib/gmem.h @@ -27,37 +27,72 @@ #ifndef __G_MEM_H__ #define __G_MEM_H__ -#include <g_types.h> +#include <glib/gtypes.h> -/* optionally feature DMALLOC memory allocation debugger +G_BEGIN_DECLS + +typedef struct _GAllocator GAllocator; +typedef struct _GMemChunk GMemChunk; +typedef struct _GMemVTable GMemVTable; + + +#if GLIB_SIZEOF_VOID_P > GLIB_SIZEOF_LONG +# define G_MEM_ALIGN GLIB_SIZEOF_VOID_P +#else /* GLIB_SIZEOF_VOID_P <= GLIB_SIZEOF_LONG */ +# define G_MEM_ALIGN GLIB_SIZEOF_LONG +#endif /* GLIB_SIZEOF_VOID_P <= GLIB_SIZEOF_LONG */ + + +/* Memory allocation functions */ -#ifdef USE_DMALLOC -#include "dmalloc.h" -#endif +gpointer g_malloc (gulong n_bytes); +gpointer g_malloc0 (gulong n_bytes); +gpointer g_realloc (gpointer mem, + gulong n_bytes); +void g_free (gpointer mem); +gpointer g_try_malloc (gulong n_bytes); +gpointer g_try_realloc (gpointer mem, + gulong n_bytes); -G_BEGIN_DECLS -typedef struct _GAllocator GAllocator; -typedef struct _GMemChunk GMemChunk; +/* Convenience memory allocators + */ +#define g_new(struct_type, n_structs) \ + ((struct_type *) g_malloc (((gsize) sizeof (struct_type)) * ((gsize) (n_structs)))) +#define g_new0(struct_type, n_structs) \ + ((struct_type *) g_malloc0 (((gsize) sizeof (struct_type)) * ((gsize) (n_structs)))) +#define g_renew(struct_type, mem, n_structs) \ + ((struct_type *) g_realloc ((mem), ((gsize) sizeof (struct_type)) * ((gsize) (n_structs)))) -/* Provide macros for easily allocating memory. The macros - * will cast the allocated memory to the specified type - * in order to avoid compiler warnings. (Makes the code neater). + +/* Memory allocation virtualization for debugging purposes + * g_mem_set_vtable() has to be the very first GLib function called + * if being used + */ +struct _GMemVTable +{ + gpointer (*malloc) (gsize n_bytes); + gpointer (*realloc) (gpointer mem, + gsize n_bytes); + void (*free) (gpointer mem); + /* optional */ + gpointer (*calloc) (gsize n_blocks, + gsize n_block_bytes); + gpointer (*try_malloc) (gsize n_bytes); + gpointer (*try_realloc) (gpointer mem, + gsize n_bytes); +}; +void g_mem_set_vtable (GMemVTable *vtable); +gboolean g_mem_is_system_malloc (void); + +/* Memory profiler and checker, has to be enabled via g_mem_set_vtable() */ +GLIB_VAR GMemVTable *glib_mem_profiler_table; +void g_mem_profile (void); -#ifdef __DMALLOC_H__ -# define g_new(type, count) (ALLOC (type, count)) -# define g_new0(type, count) (CALLOC (type, count)) -# define g_renew(type, mem, count) (REALLOC (mem, type, count)) -#else /* __DMALLOC_H__ */ -# define g_new(type, count) \ - ((type *) g_malloc ((unsigned) sizeof (type) * (count))) -# define g_new0(type, count) \ - ((type *) g_malloc0 ((unsigned) sizeof (type) * (count))) -# define g_renew(type, mem, count) \ - ((type *) g_realloc (mem, (unsigned) sizeof (type) * (count))) -#endif /* __DMALLOC_H__ */ +/* Memchunk convenience functions + */ #define g_mem_chunk_create(type, pre_alloc, alloc_type) ( \ g_mem_chunk_new (#type " mem chunks (" #pre_alloc ")", \ sizeof (type), \ @@ -74,37 +109,6 @@ typedef struct _GMemChunk GMemChunk; g_mem_chunk_free ((mem_chunk), (mem)); \ } G_STMT_END -/* Memory allocation and debugging - */ -#ifdef USE_DMALLOC - -#define g_malloc(size) ((gpointer) MALLOC (size)) -#define g_malloc0(size) ((gpointer) CALLOC (char, size)) -#define g_realloc(mem,size) ((gpointer) REALLOC (mem, char, size)) -#define g_free(mem) FREE (mem) - -#else /* !USE_DMALLOC */ - -gpointer g_malloc (gulong size); -gpointer g_malloc0 (gulong size); -gpointer g_realloc (gpointer mem, - gulong size); -void g_free (gpointer mem); - -#endif /* !USE_DMALLOC */ - -void g_mem_profile (void); -void g_mem_check (gpointer mem); - -/* Generic allocators - */ -GAllocator* g_allocator_new (const gchar *name, - guint n_preallocs); -void g_allocator_free (GAllocator *allocato); - -#define G_ALLOCATOR_LIST (1) -#define G_ALLOCATOR_SLIST (2) -#define G_ALLOCATOR_NODE (3) /* "g_mem_chunk_new" creates a new memory chunk. * Memory chunks are used to allocate pieces of memory which are @@ -128,19 +132,19 @@ void g_allocator_free (GAllocator *allocato); #define G_ALLOC_ONLY 1 #define G_ALLOC_AND_FREE 2 -GMemChunk* g_mem_chunk_new (gchar *name, - gint atom_size, - gulong area_size, - gint type); -void g_mem_chunk_destroy (GMemChunk *mem_chunk); -gpointer g_mem_chunk_alloc (GMemChunk *mem_chunk); -gpointer g_mem_chunk_alloc0 (GMemChunk *mem_chunk); -void g_mem_chunk_free (GMemChunk *mem_chunk, - gpointer mem); -void g_mem_chunk_clean (GMemChunk *mem_chunk); -void g_mem_chunk_reset (GMemChunk *mem_chunk); -void g_mem_chunk_print (GMemChunk *mem_chunk); -void g_mem_chunk_info (void); +GMemChunk* g_mem_chunk_new (const gchar *name, + gint atom_size, + gulong area_size, + gint type); +void g_mem_chunk_destroy (GMemChunk *mem_chunk); +gpointer g_mem_chunk_alloc (GMemChunk *mem_chunk); +gpointer g_mem_chunk_alloc0 (GMemChunk *mem_chunk); +void g_mem_chunk_free (GMemChunk *mem_chunk, + gpointer mem); +void g_mem_chunk_clean (GMemChunk *mem_chunk); +void g_mem_chunk_reset (GMemChunk *mem_chunk); +void g_mem_chunk_print (GMemChunk *mem_chunk); +void g_mem_chunk_info (void); /* Ah yes...we have a "g_blow_chunks" function. * "g_blow_chunks" simply compresses all the chunks. This operation @@ -150,9 +154,21 @@ void g_mem_chunk_info (void); * much better name than "g_mem_chunk_clean_all" or something * similar. */ -void g_blow_chunks (void); +void g_blow_chunks (void); + + +/* Generic allocators + */ +GAllocator* g_allocator_new (const gchar *name, + guint n_preallocs); +void g_allocator_free (GAllocator *allocator); + +/* internal */ +#define G_ALLOCATOR_LIST (1) +#define G_ALLOCATOR_SLIST (2) +#define G_ALLOCATOR_NODE (3) + G_END_DECLS #endif /* __G_MEM_H__ */ - diff --git a/graf2d/win32gdk/gdk/src/glib/gmessages.c b/graf2d/win32gdk/gdk/src/glib/gmessages.c new file mode 100644 index 0000000000000..f659dbc68033d --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gmessages.c @@ -0,0 +1,1185 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include <stdarg.h> +#include <stdio.h> +#include <string.h> +#include "glib.h" +#ifdef HAVE_UNISTD_H +#include <unistd.h> +#endif +#include <signal.h> +#include <locale.h> +#include <errno.h> + +#ifdef G_OS_WIN32 +typedef FILE* GFileDescriptor; +#else +typedef gint GFileDescriptor; +#endif + +/* --- structures --- */ +typedef struct _GLogDomain GLogDomain; +typedef struct _GLogHandler GLogHandler; +struct _GLogDomain +{ + gchar *log_domain; + GLogLevelFlags fatal_mask; + GLogHandler *handlers; + GLogDomain *next; +}; +struct _GLogHandler +{ + guint id; + GLogLevelFlags log_level; + GLogFunc log_func; + gpointer data; + GLogHandler *next; +}; + + +/* --- prototypes --- */ +static gsize printf_string_upper_bound (const gchar *format, + gboolean may_warn, + va_list args); + + +/* --- variables --- */ + +static GMutex* g_messages_lock = NULL; + +const gchar *g_log_domain_glib = "GLib"; +static GLogDomain *g_log_domains = NULL; +static GLogLevelFlags g_log_always_fatal = G_LOG_FATAL_MASK; +static GPrintFunc glib_print_func = NULL; +static GPrintFunc glib_printerr_func = NULL; + +static GPrivate* g_log_depth = NULL; + +/* --- functions --- */ +#ifdef G_OS_WIN32 +# define STRICT +# include <windows.h> +# undef STRICT +# include <process.h> /* For _getpid() */ + +static gboolean alloc_console_called = FALSE; + +static gboolean gonna_abort = FALSE; + +/* This default message will usually be overwritten. */ +/* Yes, a fixed size buffer is bad. So sue me. But g_error is never + * with huge strings, is it? */ +static char fatal_msg_buf[1000] = "Unspecified fatal error encountered, aborting."; +static char *fatal_msg_ptr = fatal_msg_buf; + +/* Just use stdio. If we're out of memory, we're hosed anyway. */ +#undef write +static inline int +dowrite (GFileDescriptor fd, + const void *buf, + unsigned int len) +{ + if (gonna_abort) + { + memcpy (fatal_msg_ptr, buf, len); + fatal_msg_ptr += len; + *fatal_msg_ptr = 0; + return len; + } + + fwrite (buf, len, 1, fd); + fflush (fd); + + return len; +} + +#define write(fd, buf, len) dowrite(fd, buf, len) + +static void +ensure_stdout_valid (void) +{ + HANDLE handle; + + if (gonna_abort) + return; + + if (!alloc_console_called) + { + handle = GetStdHandle (STD_OUTPUT_HANDLE); + + if (handle == INVALID_HANDLE_VALUE) + { + AllocConsole (); + alloc_console_called = TRUE; + freopen ("CONOUT$", "w", stdout); + } + } +} +#else +#define ensure_stdout_valid() /* Define as empty */ +#endif + +static void +write_unsigned (GFileDescriptor fd, + gulong num, + guint radix) +{ + char buffer[64]; + gulong tmp; + char c; + int i, n; + + g_return_if_fail (radix >= 2 && radix <= 36); + + if (!num) + { + write (fd, "0", 1); + return; + } + + if (radix == 16) + write (fd, "0x", 2); + else if (radix == 8) + write (fd, "0", 1); + + n = 0; + tmp = num; + while (tmp) + { + tmp /= radix; + n++; + } + + i = n; + while (num) + { + i--; + c = (num % radix); + if (c < 10) + buffer[i] = c + '0'; + else + buffer[i] = c + 'a' - 10; + num /= radix; + } + + write (fd, buffer, n); +} + +static void +write_string (GFileDescriptor fd, + gchar *string) +{ + write (fd, string, strlen (string)); +} + +static void +g_log_write_prefix (GFileDescriptor fd, + GLogLevelFlags mask) +{ + static GLogLevelFlags g_log_msg_prefix = G_LOG_LEVEL_ERROR | G_LOG_LEVEL_WARNING | G_LOG_LEVEL_CRITICAL | G_LOG_LEVEL_DEBUG; + static gboolean initialized = FALSE; + + g_mutex_lock (g_messages_lock); + + if (!initialized) + { + const gchar *val; + initialized = TRUE; + + val = g_getenv ("G_MESSAGES_PREFIXED"); + + if (val) + { + static const GDebugKey keys[] = { + { "error", G_LOG_LEVEL_ERROR }, + { "critical", G_LOG_LEVEL_CRITICAL }, + { "warning", G_LOG_LEVEL_WARNING }, + { "message", G_LOG_LEVEL_MESSAGE }, + { "info", G_LOG_LEVEL_INFO }, + { "debug", G_LOG_LEVEL_DEBUG } + }; + + g_log_msg_prefix = g_parse_debug_string (val, keys, G_N_ELEMENTS (keys)); + } + } + + g_mutex_unlock (g_messages_lock); + + if ((g_log_msg_prefix & mask) == mask) + { + gchar *prg_name; + + prg_name = g_get_prgname (); + + if (!prg_name) + write_string (fd, "(process:"); + else + { + write_string (fd, prg_name); + write_string (fd, " (pid:"); + } + + write_unsigned (fd, getpid (), 10); + write_string (fd, "): "); + } +} + +static inline GLogDomain* +g_log_find_domain (const gchar *log_domain) +{ + register GLogDomain *domain; + + g_mutex_lock (g_messages_lock); + domain = g_log_domains; + while (domain) + { + if (strcmp (domain->log_domain, log_domain) == 0) + { + g_mutex_unlock (g_messages_lock); + return domain; + } + domain = domain->next; + } + g_mutex_unlock (g_messages_lock); + return NULL; +} + +static inline GLogDomain* +g_log_domain_new (const gchar *log_domain) +{ + register GLogDomain *domain; + + domain = g_new (GLogDomain, 1); + domain->log_domain = g_strdup (log_domain); + domain->fatal_mask = G_LOG_FATAL_MASK; + domain->handlers = NULL; + + g_mutex_lock (g_messages_lock); + domain->next = g_log_domains; + g_log_domains = domain; + g_mutex_unlock (g_messages_lock); + + return domain; +} + +static inline void +g_log_domain_check_free (GLogDomain *domain) +{ + if (domain->fatal_mask == G_LOG_FATAL_MASK && + domain->handlers == NULL) + { + register GLogDomain *last, *work; + + last = NULL; + + g_mutex_lock (g_messages_lock); + work = g_log_domains; + while (work) + { + if (work == domain) + { + if (last) + last->next = domain->next; + else + g_log_domains = domain->next; + g_free (domain->log_domain); + g_free (domain); + break; + } + last = work; + work = last->next; + } + g_mutex_unlock (g_messages_lock); + } +} + +static inline GLogFunc +g_log_domain_get_handler (GLogDomain *domain, + GLogLevelFlags log_level, + gpointer *data) +{ + if (domain && log_level) + { + register GLogHandler *handler; + + handler = domain->handlers; + while (handler) + { + if ((handler->log_level & log_level) == log_level) + { + *data = handler->data; + return handler->log_func; + } + handler = handler->next; + } + } + return g_log_default_handler; +} + +GLogLevelFlags +g_log_set_always_fatal (GLogLevelFlags fatal_mask) +{ + GLogLevelFlags old_mask; + + /* restrict the global mask to levels that are known to glib */ + fatal_mask &= (1 << G_LOG_LEVEL_USER_SHIFT) - 1; + /* force errors to be fatal */ + fatal_mask |= G_LOG_LEVEL_ERROR; + /* remove bogus flag */ + fatal_mask &= ~G_LOG_FLAG_FATAL; + + g_mutex_lock (g_messages_lock); + old_mask = g_log_always_fatal; + g_log_always_fatal = fatal_mask; + g_mutex_unlock (g_messages_lock); + + return old_mask; +} + +GLogLevelFlags +g_log_set_fatal_mask (const gchar *log_domain, + GLogLevelFlags fatal_mask) +{ + GLogLevelFlags old_flags; + register GLogDomain *domain; + + if (!log_domain) + log_domain = ""; + + /* force errors to be fatal */ + fatal_mask |= G_LOG_LEVEL_ERROR; + /* remove bogus flag */ + fatal_mask &= ~G_LOG_FLAG_FATAL; + + domain = g_log_find_domain (log_domain); + if (!domain) + domain = g_log_domain_new (log_domain); + old_flags = domain->fatal_mask; + + domain->fatal_mask = fatal_mask; + g_log_domain_check_free (domain); + + return old_flags; +} + +guint +g_log_set_handler (const gchar *log_domain, + GLogLevelFlags log_levels, + GLogFunc log_func, + gpointer user_data) +{ + register GLogDomain *domain; + register GLogHandler *handler; + static guint handler_id = 0; + + g_return_val_if_fail ((log_levels & G_LOG_LEVEL_MASK) != 0, 0); + g_return_val_if_fail (log_func != NULL, 0); + + if (!log_domain) + log_domain = ""; + + domain = g_log_find_domain (log_domain); + if (!domain) + domain = g_log_domain_new (log_domain); + + handler = g_new (GLogHandler, 1); + g_mutex_lock (g_messages_lock); + handler->id = ++handler_id; + g_mutex_unlock (g_messages_lock); + handler->log_level = log_levels; + handler->log_func = log_func; + handler->data = user_data; + handler->next = domain->handlers; + domain->handlers = handler; + + return handler_id; +} + +void +g_log_remove_handler (const gchar *log_domain, + guint handler_id) +{ + register GLogDomain *domain; + + g_return_if_fail (handler_id > 0); + + if (!log_domain) + log_domain = ""; + + domain = g_log_find_domain (log_domain); + if (domain) + { + register GLogHandler *work, *last; + + last = NULL; + work = domain->handlers; + while (work) + { + if (work->id == handler_id) + { + if (last) + last->next = work->next; + else + domain->handlers = work->next; + g_free (work); + g_log_domain_check_free (domain); + return; + } + last = work; + work = last->next; + } + } + g_warning ("g_log_remove_handler(): could not find handler with id `%d' for domain \"%s\"", + handler_id, + log_domain); +} + +void +g_logv (const gchar *log_domain, + GLogLevelFlags log_level, + const gchar *format, + va_list args1) +{ + va_list args2; + gchar buffer[1025]; + register gint i; + + log_level &= G_LOG_LEVEL_MASK; + if (!log_level) + return; + + /* we use a stack buffer of fixed size, because we might get called + * recursively. + */ +#ifdef HAVE_VSNPRINTF + vsnprintf (buffer, 1024, format, args1); +#else /* !HAVE_VSNPRINTF */ + G_VA_COPY (args2, args1); + if (printf_string_upper_bound (format, FALSE, args1) < 1024) + vsprintf (buffer, format, args2); + else + { + /* since we might be out of memory, we can't use g_vsnprintf(). */ + /* we are out of luck here */ + strncpy (buffer, format, 1024); + buffer[1024] = 0; + } + va_end (args2); +#endif /* !HAVE_VSNPRINTF */ + + for (i = g_bit_nth_msf (log_level, -1); i >= 0; i = g_bit_nth_msf (log_level, i)) + { + register GLogLevelFlags test_level; + + test_level = 1 << i; + if (log_level & test_level) + { + guint depth = GPOINTER_TO_UINT (g_private_get (g_log_depth)); + GLogDomain *domain; + GLogFunc log_func; + gpointer data = NULL; + + domain = g_log_find_domain (log_domain ? log_domain : ""); + + if (depth) + test_level |= G_LOG_FLAG_RECURSION; + + depth++; + g_private_set (g_log_depth, GUINT_TO_POINTER (depth)); + + g_mutex_lock (g_messages_lock); + if ((((domain ? domain->fatal_mask : G_LOG_FATAL_MASK) | + g_log_always_fatal) & test_level) != 0) + test_level |= G_LOG_FLAG_FATAL; + g_mutex_unlock (g_messages_lock); + + log_func = g_log_domain_get_handler (domain, test_level, &data); + log_func (log_domain, test_level, buffer, data); + + /* *domain can be cluttered now */ + + if (test_level & G_LOG_FLAG_FATAL) + { +#if defined (G_ENABLE_DEBUG) && defined (SIGTRAP) + if (!(test_level & G_LOG_FLAG_RECURSION)) + G_BREAKPOINT (); + else + abort (); +#else /* !G_ENABLE_DEBUG || !SIGTRAP */ +#ifdef G_OS_WIN32 + MessageBox (NULL, fatal_msg_buf, NULL, MB_OK); +#endif +# if defined (_MSC_VER) && defined (_DEBUG) + /* let's see the call stack ... */ + __asm int 3 +# endif + abort (); +#endif /* !G_ENABLE_DEBUG || !SIGTRAP */ + } + + depth--; + g_private_set (g_log_depth, GUINT_TO_POINTER (depth)); + } + } +} + +void +g_log (const gchar *log_domain, + GLogLevelFlags log_level, + const gchar *format, + ...) +{ + va_list args; + + va_start (args, format); + g_logv (log_domain, log_level, format, args); + va_end (args); +} + +void +g_log_default_handler (const gchar *log_domain, + GLogLevelFlags log_level, + const gchar *message, + gpointer unused_data) +{ + GFileDescriptor fd; + gboolean in_recursion; + gboolean is_fatal; + + in_recursion = (log_level & G_LOG_FLAG_RECURSION) != 0; + is_fatal = (log_level & G_LOG_FLAG_FATAL) != 0; + log_level &= G_LOG_LEVEL_MASK; + + if (!message) + message = "g_log_default_handler(): (NULL) message"; + +#ifdef G_OS_WIN32 + /* Use just stdout as stderr is hard to get redirected from the + * DOS prompt. + */ + fd = stdout; + gonna_abort = is_fatal; +#else + fd = (log_level > G_LOG_LEVEL_MESSAGE) ? 1 : 2; +#endif + + switch (log_level) + { + case G_LOG_LEVEL_ERROR: + /* use write(2) for output, in case we are out of memeory */ + ensure_stdout_valid (); + write (fd, "\n", 1); + g_log_write_prefix (fd, log_level); + + if (log_domain) + { + write (fd, log_domain, strlen (log_domain)); + write (fd, "-", 1); + } + else + write (fd, "** ", 3); + if (in_recursion) + write (fd, "ERROR (recursed) **: ", 21); + else + write (fd, "ERROR **: ", 10); + write (fd, message, strlen (message)); + if (is_fatal) + write (fd, "\naborting...\n", 13); + else + write (fd, "\n", 1); + break; + case G_LOG_LEVEL_CRITICAL: + ensure_stdout_valid (); + write (fd, "\n", 1); + g_log_write_prefix (fd, log_level); + + if (log_domain) + { + write (fd, log_domain, strlen (log_domain)); + write (fd, "-", 1); + } + else + write (fd, "** ", 3); + if (in_recursion) + write (fd, "CRITICAL (recursed) **: ", 24); + else + write (fd, "CRITICAL **: ", 13); + write (fd, message, strlen (message)); + if (is_fatal) + write (fd, "\naborting...\n", 13); + else + write (fd, "\n", 1); + break; + case G_LOG_LEVEL_WARNING: + ensure_stdout_valid (); + write (fd, "\n", 1); + g_log_write_prefix (fd, log_level); + + if (log_domain) + { + write (fd, log_domain, strlen (log_domain)); + write (fd, "-", 1); + } + else + write (fd, "** ", 3); + if (in_recursion) + write (fd, "WARNING (recursed) **: ", 23); + else + write (fd, "WARNING **: ", 12); + write (fd, message, strlen (message)); + if (is_fatal) + write (fd, "\naborting...\n", 13); + else + write (fd, "\n", 1); + break; + case G_LOG_LEVEL_MESSAGE: + ensure_stdout_valid (); + + g_log_write_prefix (fd, log_level); + + if (log_domain) + { + write (fd, log_domain, strlen (log_domain)); + write (fd, "-", 1); + } + if (in_recursion) + write (fd, "Message (recursed): ", 20); + else + write (fd, "Message: ", 9); + write (fd, message, strlen (message)); + if (is_fatal) + write (fd, "\naborting...\n", 13); + else + write (fd, "\n", 1); + break; + case G_LOG_LEVEL_INFO: + ensure_stdout_valid (); + + g_log_write_prefix (fd, log_level); + + if (log_domain) + { + write (fd, log_domain, strlen (log_domain)); + write (fd, "-", 1); + } + if (in_recursion) + write (fd, "INFO (recursed): ", 17); + else + write (fd, "INFO: ", 6); + write (fd, message, strlen (message)); + if (is_fatal) + write (fd, "\naborting...\n", 13); + else + write (fd, "\n", 1); + break; + case G_LOG_LEVEL_DEBUG: + ensure_stdout_valid (); + + g_log_write_prefix (fd, log_level); + + if (log_domain) + { + write (fd, log_domain, strlen (log_domain)); + write (fd, "-", 1); + } + if (in_recursion) + write (fd, "DEBUG (recursed): ", 18); + else + write (fd, "DEBUG: ", 7); + write (fd, message, strlen (message)); + if (is_fatal) + write (fd, "\naborting...\n", 13); + else + write (fd, "\n", 1); + break; + default: + /* we are used for a log level that is not defined by GLib itself, + * try to make the best out of it. + */ + ensure_stdout_valid (); + + g_log_write_prefix (fd, log_level); + + if (log_domain) + { + write (fd, log_domain, strlen (log_domain)); + if (in_recursion) + write (fd, "-LOG (recursed:", 15); + else + write (fd, "-LOG (", 6); + } + else if (in_recursion) + write (fd, "LOG (recursed:", 14); + else + write (fd, "LOG (", 5); + if (log_level) + { + gchar string[] = "0x00): "; + gchar *p = string + 2; + guint i; + + i = g_bit_nth_msf (log_level, -1); + *p = i >> 4; + p++; + *p = '0' + (i & 0xf); + if (*p > '9') + *p += 'A' - '9' - 1; + + write (fd, string, 7); + } + else + write (fd, "): ", 3); + write (fd, message, strlen (message)); + if (is_fatal) + write (fd, "\naborting...\n", 13); + else + write (fd, "\n", 1); + break; + } +} + +GPrintFunc +g_set_print_handler (GPrintFunc func) +{ + GPrintFunc old_print_func; + + g_mutex_lock (g_messages_lock); + old_print_func = glib_print_func; + glib_print_func = func; + g_mutex_unlock (g_messages_lock); + + return old_print_func; +} + +void +g_print (const gchar *format, + ...) +{ + va_list args; + gchar *string; + GPrintFunc local_glib_print_func; + + g_return_if_fail (format != NULL); + + va_start (args, format); + string = g_strdup_vprintf (format, args); + va_end (args); + + g_mutex_lock (g_messages_lock); + local_glib_print_func = glib_print_func; + g_mutex_unlock (g_messages_lock); + + if (local_glib_print_func) + local_glib_print_func (string); + else + { + ensure_stdout_valid (); + fputs (string, stdout); + fflush (stdout); + } + g_free (string); +} + +GPrintFunc +g_set_printerr_handler (GPrintFunc func) +{ + GPrintFunc old_printerr_func; + + g_mutex_lock (g_messages_lock); + old_printerr_func = glib_printerr_func; + glib_printerr_func = func; + g_mutex_unlock (g_messages_lock); + + return old_printerr_func; +} + +void +g_printerr (const gchar *format, + ...) +{ + va_list args; + gchar *string; + GPrintFunc local_glib_printerr_func; + + g_return_if_fail (format != NULL); + + va_start (args, format); + string = g_strdup_vprintf (format, args); + va_end (args); + + g_mutex_lock (g_messages_lock); + local_glib_printerr_func = glib_printerr_func; + g_mutex_unlock (g_messages_lock); + + if (local_glib_printerr_func) + local_glib_printerr_func (string); + else + { + fputs (string, stderr); + fflush (stderr); + } + g_free (string); +} + +#ifndef MB_LEN_MAX +# define MB_LEN_MAX 8 +#endif + +typedef struct +{ + guint min_width; + guint precision; + gboolean alternate_format, zero_padding, adjust_left, locale_grouping; + gboolean add_space, add_sign, possible_sign, seen_precision; + gboolean mod_half, mod_long, mod_extra_long; +} PrintfArgSpec; + +static gsize +printf_string_upper_bound (const gchar *format, + gboolean may_warn, + va_list args) +{ + static const gboolean honour_longs = sizeof(long) > 4 || sizeof(void*) > 4; + gsize len = 1; + + if (!format) + return len; + + while (*format) + { + register gchar c = *format++; + + if (c != '%') + len += 1; + else /* (c == '%') */ + { + PrintfArgSpec spec = { 0, }; + gboolean seen_l = FALSE, conv_done = FALSE; + gsize conv_len = 0; + const gchar *spec_start = format; + + do + { + c = *format++; + switch (c) + { + GDoubleIEEE754 u_double; + guint v_uint; + gint v_int; + const gchar *v_string; + + /* beware of positional parameters + */ + case '$': + if (may_warn) + g_warning (G_GNUC_PRETTY_FUNCTION + "(): unable to handle positional parameters (%%n$)"); + len += 1024; /* try adding some safety padding */ + conv_done = TRUE; + break; + + /* parse flags + */ + case '#': + spec.alternate_format = TRUE; + break; + case '0': + spec.zero_padding = TRUE; + break; + case '-': + spec.adjust_left = TRUE; + break; + case ' ': + spec.add_space = TRUE; + break; + case '+': + spec.add_sign = TRUE; + break; + case '\'': + spec.locale_grouping = TRUE; + break; + + /* parse output size specifications + */ + case '.': + spec.seen_precision = TRUE; + break; + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': + v_uint = c - '0'; + c = *format; + while (c >= '0' && c <= '9') + { + format++; + v_uint = v_uint * 10 + c - '0'; + c = *format; + } + if (spec.seen_precision) + spec.precision = MAX (spec.precision, v_uint); + else + spec.min_width = MAX (spec.min_width, v_uint); + break; + case '*': + v_int = va_arg (args, int); + if (spec.seen_precision) + { + /* forget about negative precision */ + if (v_int >= 0) + spec.precision = MAX (spec.precision, v_int); + } + else + { + if (v_int < 0) + { + v_int = - v_int; + spec.adjust_left = TRUE; + } + spec.min_width = MAX (spec.min_width, v_int); + } + break; + + /* parse type modifiers + */ + case 'h': + spec.mod_half = TRUE; + break; + case 'l': + if (!seen_l) + { + spec.mod_long = TRUE; + seen_l = TRUE; + break; + } + /* else, fall through */ + case 'L': + case 'q': + spec.mod_long = TRUE; + spec.mod_extra_long = TRUE; + break; + case 'z': + case 'Z': +#if GLIB_SIZEOF_SIZE_T > 4 + spec.mod_long = TRUE; + spec.mod_extra_long = TRUE; +#endif /* GLIB_SIZEOF_SIZE_T > 4 */ + break; + case 't': +#if GLIB_SIZEOF_PTRDIFF_T > 4 + spec.mod_long = TRUE; + spec.mod_extra_long = TRUE; +#endif /* GLIB_SIZEOF_PTRDIFF_T > 4 */ + break; + case 'j': +#if GLIB_SIZEOF_INTMAX_T > 4 + spec.mod_long = TRUE; + spec.mod_extra_long = TRUE; +#endif /* GLIB_SIZEOF_INTMAX_T > 4 */ + break; + + /* parse output conversions + */ + case '%': + conv_len += 1; + break; + case 'O': + case 'D': + case 'I': + case 'U': + /* some C libraries feature long variants for these as well? */ + spec.mod_long = TRUE; + /* fall through */ + case 'o': + conv_len += 2; + /* fall through */ + case 'd': + case 'i': + conv_len += 1; /* sign */ + /* fall through */ + case 'u': + conv_len += 4; + /* fall through */ + case 'x': + case 'X': + spec.possible_sign = TRUE; + conv_len += 10; + if (spec.mod_long && honour_longs) + conv_len *= 2; + if (spec.mod_extra_long) + conv_len *= 2; + if (spec.mod_extra_long) + { +#ifdef G_HAVE_GINT64 + (void) va_arg (args, gint64); +#else /* !G_HAVE_GINT64 */ + (void) va_arg (args, long); +#endif /* !G_HAVE_GINT64 */ + } + else if (spec.mod_long) + (void) va_arg (args, long); + else + (void) va_arg (args, int); + break; + case 'A': + case 'a': + /* 0x */ + conv_len += 2; + /* fall through */ + case 'g': + case 'G': + case 'e': + case 'E': + case 'f': + spec.possible_sign = TRUE; + /* n . dddddddddddddddddddddddd E +- eeee */ + conv_len += 1 + 1 + MAX (24, spec.precision) + 1 + 1 + 4; + if (may_warn && spec.mod_extra_long) + g_warning (G_GNUC_PRETTY_FUNCTION + "(): unable to handle long double, collecting double only"); +#ifdef HAVE_LONG_DOUBLE +#error need to implement special handling for long double +#endif + u_double.v_double = va_arg (args, double); + /* %f can expand up to all significant digits before '.' (308) */ + if (c == 'f' && + u_double.mpn.biased_exponent > 0 && u_double.mpn.biased_exponent < 2047) + { + gint exp = u_double.mpn.biased_exponent; + + exp -= G_IEEE754_DOUBLE_BIAS; + exp = exp * G_LOG_2_BASE_10 + 1; + conv_len += ABS (exp); /* exp can be <0 */ + } + /* some printf() implementations require extra padding for rounding */ + conv_len += 2; + /* we can't really handle locale specific grouping here */ + if (spec.locale_grouping) + conv_len *= 2; + break; + case 'C': + spec.mod_long = TRUE; + /* fall through */ + case 'c': + conv_len += spec.mod_long ? MB_LEN_MAX : 1; + (void) va_arg (args, int); + break; + case 'S': + spec.mod_long = TRUE; + /* fall through */ + case 's': + v_string = va_arg (args, char*); + if (!v_string) + conv_len += 8; /* hold "(null)" */ + else if (spec.seen_precision) + conv_len += spec.precision; + else + conv_len += strlen (v_string); + conv_done = TRUE; + if (spec.mod_long) + { + if (may_warn) + g_warning (G_GNUC_PRETTY_FUNCTION + "(): unable to handle wide char strings"); + len += 1024; /* try adding some safety padding */ + } + break; + case 'P': /* do we actually need this? */ + /* fall through */ + case 'p': + spec.alternate_format = TRUE; + conv_len += 10; + if (honour_longs) + conv_len *= 2; + /* fall through */ + case 'n': + conv_done = TRUE; + (void) va_arg (args, void*); + break; + case 'm': + /* there's not much we can do to be clever */ + v_string = g_strerror (errno); + v_uint = v_string ? strlen (v_string) : 0; + conv_len += MAX (256, v_uint); + break; + + /* handle invalid cases + */ + case '\000': + /* no conversion specification, bad bad */ + conv_len += format - spec_start; + break; + default: + if (may_warn) + g_warning (G_GNUC_PRETTY_FUNCTION + "(): unable to handle `%c' while parsing format", + c); + break; + } + conv_done |= conv_len > 0; + } + while (!conv_done); + /* handle width specifications */ + conv_len = MAX (conv_len, MAX (spec.precision, spec.min_width)); + /* handle flags */ + conv_len += spec.alternate_format ? 2 : 0; + conv_len += (spec.add_space || spec.add_sign || spec.possible_sign); + /* finally done */ + len += conv_len; + } /* else (c == '%') */ + } /* while (*format) */ + + return len; +} + +gsize +g_printf_string_upper_bound (const gchar *format, + va_list args) +{ + return printf_string_upper_bound (format, TRUE, args); +} + +void +g_messages_init (void) +{ + g_messages_lock = g_mutex_new(); + g_log_depth = g_private_new(NULL); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gmessages.h b/graf2d/win32gdk/gdk/src/glib/gmessages.h index f5a11ad4b8f96..9fc556fa721ad 100644 --- a/graf2d/win32gdk/gdk/src/glib/gmessages.h +++ b/graf2d/win32gdk/gdk/src/glib/gmessages.h @@ -28,13 +28,13 @@ #define __G_MESSAGES_H__ #include <stdarg.h> -#include <g_types.h> +#include <glib/gtypes.h> G_BEGIN_DECLS /* calculate a string size, guarranteed to fit format + args. */ -guint g_printf_string_upper_bound (const gchar* format, +gsize g_printf_string_upper_bound (const gchar* format, va_list args); /* Log level shift offset for user defined @@ -71,7 +71,7 @@ typedef void (*GLogFunc) (const gchar *log_domain, /* Logging mechanism */ -extern const gchar *g_log_domain_glib; +GLIB_VAR const gchar *g_log_domain_glib; guint g_log_set_handler (const gchar *log_domain, GLogLevelFlags log_levels, GLogFunc log_func, @@ -97,7 +97,7 @@ GLogLevelFlags g_log_set_always_fatal (GLogLevelFlags fatal_mask); #ifndef G_LOG_DOMAIN #define G_LOG_DOMAIN ((gchar*) 0) #endif /* G_LOG_DOMAIN */ -#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L +#ifdef G_HAVE_ISO_VARARGS #define g_error(...) g_log (G_LOG_DOMAIN, \ G_LOG_LEVEL_ERROR, \ __VA_ARGS__) @@ -110,7 +110,7 @@ GLogLevelFlags g_log_set_always_fatal (GLogLevelFlags fatal_mask); #define g_warning(...) g_log (G_LOG_DOMAIN, \ G_LOG_LEVEL_WARNING, \ __VA_ARGS__) -#elif __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 4) +#elif defined(G_HAVE_GNUC_VARARGS) #define g_error(format...) g_log (G_LOG_DOMAIN, \ G_LOG_LEVEL_ERROR, \ format) @@ -123,7 +123,7 @@ GLogLevelFlags g_log_set_always_fatal (GLogLevelFlags fatal_mask); #define g_warning(format...) g_log (G_LOG_DOMAIN, \ G_LOG_LEVEL_WARNING, \ format) -#else /* !__GNUC__ */ +#else /* no varargs macros */ static void g_error (const gchar *format, ...) @@ -170,12 +170,6 @@ void g_printerr (const gchar *format, ...) G_GNUC_PRINTF (1, 2); GPrintFunc g_set_printerr_handler (GPrintFunc func); -/* deprecated compatibility functions, use g_log_set_handler() instead */ -typedef void (*GErrorFunc) (const gchar *str); -typedef void (*GWarningFunc) (const gchar *str); -GErrorFunc g_set_error_handler (GErrorFunc func); -GWarningFunc g_set_warning_handler (GWarningFunc func); -GPrintFunc g_set_message_handler (GPrintFunc func); /* Provide macros for error handling. The "assert" macros will * exit on failure. The "return" macros will exit the current @@ -186,8 +180,8 @@ GPrintFunc g_set_message_handler (GPrintFunc func); #ifdef G_DISABLE_ASSERT -#define g_assert(expr) -#define g_assert_not_reached() +#define g_assert(expr) G_STMT_START{ }G_STMT_END +#define g_assert_not_reached() G_STMT_START{ }G_STMT_END #else /* !G_DISABLE_ASSERT */ @@ -236,10 +230,10 @@ GPrintFunc g_set_message_handler (GPrintFunc func); #ifdef G_DISABLE_CHECKS -#define g_return_if_fail(expr) -#define g_return_val_if_fail(expr,val) -#define g_return_if_reached() return -#define g_return_val_if_reached(val) return (val) +#define g_return_if_fail(expr) G_STMT_START{ }G_STMT_END +#define g_return_val_if_fail(expr,val) G_STMT_START{ }G_STMT_END +#define g_return_if_reached() G_STMT_START{ return; }G_STMT_END +#define g_return_val_if_reached(val) G_STMT_START{ return (val); }G_STMT_END #else /* !G_DISABLE_CHECKS */ diff --git a/graf2d/win32gdk/gdk/src/glib/gnode.c b/graf2d/win32gdk/gdk/src/glib/gnode.c new file mode 100644 index 0000000000000..77143a8c4321f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gnode.c @@ -0,0 +1,1064 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * GNode: N-way tree implementation. + * Copyright (C) 1998 Tim Janik + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include "glib.h" + +#ifndef DISABLE_MEM_POOLS +/* node allocation + */ +struct _GAllocator /* from gmem.c */ +{ + gchar *name; + guint16 n_preallocs; + guint is_unused : 1; + guint type : 4; + GAllocator *last; + GMemChunk *mem_chunk; + GNode *free_nodes; /* implementation specific */ +}; + +G_LOCK_DEFINE_STATIC (current_allocator); +static GAllocator *current_allocator = NULL; + +/* HOLDS: current_allocator_lock */ +static void +g_node_validate_allocator (GAllocator *allocator) +{ + g_return_if_fail (allocator != NULL); + g_return_if_fail (allocator->is_unused == TRUE); + + if (allocator->type != G_ALLOCATOR_NODE) + { + allocator->type = G_ALLOCATOR_NODE; + if (allocator->mem_chunk) + { + g_mem_chunk_destroy (allocator->mem_chunk); + allocator->mem_chunk = NULL; + } + } + + if (!allocator->mem_chunk) + { + allocator->mem_chunk = g_mem_chunk_new (allocator->name, + sizeof (GNode), + sizeof (GNode) * allocator->n_preallocs, + G_ALLOC_ONLY); + allocator->free_nodes = NULL; + } + + allocator->is_unused = FALSE; +} + +void +g_node_push_allocator (GAllocator *allocator) +{ + G_LOCK (current_allocator); + g_node_validate_allocator (allocator); + allocator->last = current_allocator; + current_allocator = allocator; + G_UNLOCK (current_allocator); +} + +void +g_node_pop_allocator (void) +{ + G_LOCK (current_allocator); + if (current_allocator) + { + GAllocator *allocator; + + allocator = current_allocator; + current_allocator = allocator->last; + allocator->last = NULL; + allocator->is_unused = TRUE; + } + G_UNLOCK (current_allocator); +} + + +/* --- functions --- */ +GNode* +g_node_new (gpointer data) +{ + GNode *node; + + G_LOCK (current_allocator); + if (!current_allocator) + { + GAllocator *allocator = g_allocator_new ("GLib default GNode allocator", + 128); + g_node_validate_allocator (allocator); + allocator->last = NULL; + current_allocator = allocator; + } + if (!current_allocator->free_nodes) + node = g_chunk_new (GNode, current_allocator->mem_chunk); + else + { + node = current_allocator->free_nodes; + current_allocator->free_nodes = node->next; + } + G_UNLOCK (current_allocator); + + node->data = data; + node->next = NULL; + node->prev = NULL; + node->parent = NULL; + node->children = NULL; + + return node; +} + +static void +g_nodes_free (GNode *node) +{ + GNode *parent; + + parent = node; + while (1) + { + if (parent->children) + g_nodes_free (parent->children); + +#ifdef ENABLE_GC_FRIENDLY + parent->data = NULL; + parent->prev = NULL; + parent->parent = NULL; + parent->children = NULL; +#endif /* ENABLE_GC_FRIENDLY */ + + if (parent->next) + parent = parent->next; + else + break; + } + + G_LOCK (current_allocator); + parent->next = current_allocator->free_nodes; + current_allocator->free_nodes = node; + G_UNLOCK (current_allocator); +} +#else /* DISABLE_MEM_POOLS */ + +GNode* +g_node_new (gpointer data) +{ + GNode *node; + + node = g_new0 (GNode, 1); + + node->data = data; + + return node; +} + +static void +g_nodes_free (GNode *root) +{ + GNode *node, *next; + + node = root; + while (node != NULL) + { + next = node->next; + g_nodes_free (node->children); + g_free (node); + node = next; + } +} +#endif + +void +g_node_destroy (GNode *root) +{ + g_return_if_fail (root != NULL); + + if (!G_NODE_IS_ROOT (root)) + g_node_unlink (root); + + g_nodes_free (root); +} + +void +g_node_unlink (GNode *node) +{ + g_return_if_fail (node != NULL); + + if (node->prev) + node->prev->next = node->next; + else if (node->parent) + node->parent->children = node->next; + node->parent = NULL; + if (node->next) + { + node->next->prev = node->prev; + node->next = NULL; + } + node->prev = NULL; +} + +GNode* +g_node_copy (GNode *node) +{ + GNode *new_node = NULL; + + if (node) + { + GNode *child; + + new_node = g_node_new (node->data); + + for (child = g_node_last_child (node); child; child = child->prev) + g_node_prepend (new_node, g_node_copy (child)); + } + + return new_node; +} + +GNode* +g_node_insert (GNode *parent, + gint position, + GNode *node) +{ + g_return_val_if_fail (parent != NULL, node); + g_return_val_if_fail (node != NULL, node); + g_return_val_if_fail (G_NODE_IS_ROOT (node), node); + + if (position > 0) + return g_node_insert_before (parent, + g_node_nth_child (parent, position), + node); + else if (position == 0) + return g_node_prepend (parent, node); + else /* if (position < 0) */ + return g_node_append (parent, node); +} + +GNode* +g_node_insert_before (GNode *parent, + GNode *sibling, + GNode *node) +{ + g_return_val_if_fail (parent != NULL, node); + g_return_val_if_fail (node != NULL, node); + g_return_val_if_fail (G_NODE_IS_ROOT (node), node); + if (sibling) + g_return_val_if_fail (sibling->parent == parent, node); + + node->parent = parent; + + if (sibling) + { + if (sibling->prev) + { + node->prev = sibling->prev; + node->prev->next = node; + node->next = sibling; + sibling->prev = node; + } + else + { + node->parent->children = node; + node->next = sibling; + sibling->prev = node; + } + } + else + { + if (parent->children) + { + sibling = parent->children; + while (sibling->next) + sibling = sibling->next; + node->prev = sibling; + sibling->next = node; + } + else + node->parent->children = node; + } + + return node; +} + +GNode* +g_node_insert_after (GNode *parent, + GNode *sibling, + GNode *node) +{ + g_return_val_if_fail (parent != NULL, node); + g_return_val_if_fail (node != NULL, node); + g_return_val_if_fail (G_NODE_IS_ROOT (node), node); + if (sibling) + g_return_val_if_fail (sibling->parent == parent, node); + + node->parent = parent; + + if (sibling) + { + if (sibling->next) + { + sibling->next->prev = node; + } + node->next = sibling->next; + node->prev = sibling; + sibling->next = node; + } + else + { + if (parent->children) + { + node->next = parent->children; + parent->children->prev = node; + } + parent->children = node; + } + + return node; +} + +GNode* +g_node_prepend (GNode *parent, + GNode *node) +{ + g_return_val_if_fail (parent != NULL, node); + + return g_node_insert_before (parent, parent->children, node); +} + +GNode* +g_node_get_root (GNode *node) +{ + g_return_val_if_fail (node != NULL, NULL); + + while (node->parent) + node = node->parent; + + return node; +} + +gboolean +g_node_is_ancestor (GNode *node, + GNode *descendant) +{ + g_return_val_if_fail (node != NULL, FALSE); + g_return_val_if_fail (descendant != NULL, FALSE); + + while (descendant) + { + if (descendant->parent == node) + return TRUE; + + descendant = descendant->parent; + } + + return FALSE; +} + +/* returns 1 for root, 2 for first level children, + * 3 for children's children... + */ +guint +g_node_depth (GNode *node) +{ + register guint depth = 0; + + while (node) + { + depth++; + node = node->parent; + } + + return depth; +} + +void +g_node_reverse_children (GNode *node) +{ + GNode *child; + GNode *last; + + g_return_if_fail (node != NULL); + + child = node->children; + last = NULL; + while (child) + { + last = child; + child = last->next; + last->next = last->prev; + last->prev = child; + } + node->children = last; +} + +guint +g_node_max_height (GNode *root) +{ + register GNode *child; + register guint max_height = 0; + + if (!root) + return 0; + + child = root->children; + while (child) + { + register guint tmp_height; + + tmp_height = g_node_max_height (child); + if (tmp_height > max_height) + max_height = tmp_height; + child = child->next; + } + + return max_height + 1; +} + +static gboolean +g_node_traverse_pre_order (GNode *node, + GTraverseFlags flags, + GNodeTraverseFunc func, + gpointer data) +{ + if (node->children) + { + GNode *child; + + if ((flags & G_TRAVERSE_NON_LEAFS) && + func (node, data)) + return TRUE; + + child = node->children; + while (child) + { + register GNode *current; + + current = child; + child = current->next; + if (g_node_traverse_pre_order (current, flags, func, data)) + return TRUE; + } + } + else if ((flags & G_TRAVERSE_LEAFS) && + func (node, data)) + return TRUE; + + return FALSE; +} + +static gboolean +g_node_depth_traverse_pre_order (GNode *node, + GTraverseFlags flags, + guint depth, + GNodeTraverseFunc func, + gpointer data) +{ + if (node->children) + { + GNode *child; + + if ((flags & G_TRAVERSE_NON_LEAFS) && + func (node, data)) + return TRUE; + + depth--; + if (!depth) + return FALSE; + + child = node->children; + while (child) + { + register GNode *current; + + current = child; + child = current->next; + if (g_node_depth_traverse_pre_order (current, flags, depth, func, data)) + return TRUE; + } + } + else if ((flags & G_TRAVERSE_LEAFS) && + func (node, data)) + return TRUE; + + return FALSE; +} + +static gboolean +g_node_traverse_post_order (GNode *node, + GTraverseFlags flags, + GNodeTraverseFunc func, + gpointer data) +{ + if (node->children) + { + GNode *child; + + child = node->children; + while (child) + { + register GNode *current; + + current = child; + child = current->next; + if (g_node_traverse_post_order (current, flags, func, data)) + return TRUE; + } + + if ((flags & G_TRAVERSE_NON_LEAFS) && + func (node, data)) + return TRUE; + + } + else if ((flags & G_TRAVERSE_LEAFS) && + func (node, data)) + return TRUE; + + return FALSE; +} + +static gboolean +g_node_depth_traverse_post_order (GNode *node, + GTraverseFlags flags, + guint depth, + GNodeTraverseFunc func, + gpointer data) +{ + if (node->children) + { + depth--; + if (depth) + { + GNode *child; + + child = node->children; + while (child) + { + register GNode *current; + + current = child; + child = current->next; + if (g_node_depth_traverse_post_order (current, flags, depth, func, data)) + return TRUE; + } + } + + if ((flags & G_TRAVERSE_NON_LEAFS) && + func (node, data)) + return TRUE; + + } + else if ((flags & G_TRAVERSE_LEAFS) && + func (node, data)) + return TRUE; + + return FALSE; +} + +static gboolean +g_node_traverse_in_order (GNode *node, + GTraverseFlags flags, + GNodeTraverseFunc func, + gpointer data) +{ + if (node->children) + { + GNode *child; + register GNode *current; + + child = node->children; + current = child; + child = current->next; + + if (g_node_traverse_in_order (current, flags, func, data)) + return TRUE; + + if ((flags & G_TRAVERSE_NON_LEAFS) && + func (node, data)) + return TRUE; + + while (child) + { + current = child; + child = current->next; + if (g_node_traverse_in_order (current, flags, func, data)) + return TRUE; + } + } + else if ((flags & G_TRAVERSE_LEAFS) && + func (node, data)) + return TRUE; + + return FALSE; +} + +static gboolean +g_node_depth_traverse_in_order (GNode *node, + GTraverseFlags flags, + guint depth, + GNodeTraverseFunc func, + gpointer data) +{ + if (node->children) + { + depth--; + if (depth) + { + GNode *child; + register GNode *current; + + child = node->children; + current = child; + child = current->next; + + if (g_node_depth_traverse_in_order (current, flags, depth, func, data)) + return TRUE; + + if ((flags & G_TRAVERSE_NON_LEAFS) && + func (node, data)) + return TRUE; + + while (child) + { + current = child; + child = current->next; + if (g_node_depth_traverse_in_order (current, flags, depth, func, data)) + return TRUE; + } + } + else if ((flags & G_TRAVERSE_NON_LEAFS) && + func (node, data)) + return TRUE; + } + else if ((flags & G_TRAVERSE_LEAFS) && + func (node, data)) + return TRUE; + + return FALSE; +} + +static gboolean +g_node_traverse_children (GNode *node, + GTraverseFlags flags, + GNodeTraverseFunc func, + gpointer data) +{ + GNode *child; + + child = node->children; + + while (child) + { + register GNode *current; + + current = child; + child = current->next; + + if (current->children) + { + if ((flags & G_TRAVERSE_NON_LEAFS) && + func (current, data)) + return TRUE; + } + else if ((flags & G_TRAVERSE_LEAFS) && + func (current, data)) + return TRUE; + } + + child = node->children; + + while (child) + { + register GNode *current; + + current = child; + child = current->next; + + if (current->children && + g_node_traverse_children (current, flags, func, data)) + return TRUE; + } + + return FALSE; +} + +static gboolean +g_node_depth_traverse_children (GNode *node, + GTraverseFlags flags, + guint depth, + GNodeTraverseFunc func, + gpointer data) +{ + GNode *child; + + child = node->children; + + while (child) + { + register GNode *current; + + current = child; + child = current->next; + + if (current->children) + { + if ((flags & G_TRAVERSE_NON_LEAFS) && + func (current, data)) + return TRUE; + } + else if ((flags & G_TRAVERSE_LEAFS) && + func (current, data)) + return TRUE; + } + + depth--; + if (!depth) + return FALSE; + + child = node->children; + + while (child) + { + register GNode *current; + + current = child; + child = current->next; + + if (current->children && + g_node_depth_traverse_children (current, flags, depth, func, data)) + return TRUE; + } + + return FALSE; +} + +void +g_node_traverse (GNode *root, + GTraverseType order, + GTraverseFlags flags, + gint depth, + GNodeTraverseFunc func, + gpointer data) +{ + g_return_if_fail (root != NULL); + g_return_if_fail (func != NULL); + g_return_if_fail (order <= G_LEVEL_ORDER); + g_return_if_fail (flags <= G_TRAVERSE_MASK); + g_return_if_fail (depth == -1 || depth > 0); + + switch (order) + { + case G_PRE_ORDER: + if (depth < 0) + g_node_traverse_pre_order (root, flags, func, data); + else + g_node_depth_traverse_pre_order (root, flags, depth, func, data); + break; + case G_POST_ORDER: + if (depth < 0) + g_node_traverse_post_order (root, flags, func, data); + else + g_node_depth_traverse_post_order (root, flags, depth, func, data); + break; + case G_IN_ORDER: + if (depth < 0) + g_node_traverse_in_order (root, flags, func, data); + else + g_node_depth_traverse_in_order (root, flags, depth, func, data); + break; + case G_LEVEL_ORDER: + if (root->children) + { + if (!((flags & G_TRAVERSE_NON_LEAFS) && + func (root, data))) + { + if (depth < 0) + g_node_traverse_children (root, flags, func, data); + else + { + depth--; + if (depth) + g_node_depth_traverse_children (root, flags, depth, func, data); + } + } + } + else if (flags & G_TRAVERSE_LEAFS) + func (root, data); + break; + } +} + +static gboolean +g_node_find_func (GNode *node, + gpointer data) +{ + register gpointer *d = data; + + if (*d != node->data) + return FALSE; + + *(++d) = node; + + return TRUE; +} + +GNode* +g_node_find (GNode *root, + GTraverseType order, + GTraverseFlags flags, + gpointer data) +{ + gpointer d[2]; + + g_return_val_if_fail (root != NULL, NULL); + g_return_val_if_fail (order <= G_LEVEL_ORDER, NULL); + g_return_val_if_fail (flags <= G_TRAVERSE_MASK, NULL); + + d[0] = data; + d[1] = NULL; + + g_node_traverse (root, order, flags, -1, g_node_find_func, d); + + return d[1]; +} + +static void +g_node_count_func (GNode *node, + GTraverseFlags flags, + guint *n) +{ + if (node->children) + { + GNode *child; + + if (flags & G_TRAVERSE_NON_LEAFS) + (*n)++; + + child = node->children; + while (child) + { + g_node_count_func (child, flags, n); + child = child->next; + } + } + else if (flags & G_TRAVERSE_LEAFS) + (*n)++; +} + +guint +g_node_n_nodes (GNode *root, + GTraverseFlags flags) +{ + guint n = 0; + + g_return_val_if_fail (root != NULL, 0); + g_return_val_if_fail (flags <= G_TRAVERSE_MASK, 0); + + g_node_count_func (root, flags, &n); + + return n; +} + +GNode* +g_node_last_child (GNode *node) +{ + g_return_val_if_fail (node != NULL, NULL); + + node = node->children; + if (node) + while (node->next) + node = node->next; + + return node; +} + +GNode* +g_node_nth_child (GNode *node, + guint n) +{ + g_return_val_if_fail (node != NULL, NULL); + + node = node->children; + if (node) + while ((n-- > 0) && node) + node = node->next; + + return node; +} + +guint +g_node_n_children (GNode *node) +{ + guint n = 0; + + g_return_val_if_fail (node != NULL, 0); + + node = node->children; + while (node) + { + n++; + node = node->next; + } + + return n; +} + +GNode* +g_node_find_child (GNode *node, + GTraverseFlags flags, + gpointer data) +{ + g_return_val_if_fail (node != NULL, NULL); + g_return_val_if_fail (flags <= G_TRAVERSE_MASK, NULL); + + node = node->children; + while (node) + { + if (node->data == data) + { + if (G_NODE_IS_LEAF (node)) + { + if (flags & G_TRAVERSE_LEAFS) + return node; + } + else + { + if (flags & G_TRAVERSE_NON_LEAFS) + return node; + } + } + node = node->next; + } + + return NULL; +} + +gint +g_node_child_position (GNode *node, + GNode *child) +{ + register guint n = 0; + + g_return_val_if_fail (node != NULL, -1); + g_return_val_if_fail (child != NULL, -1); + g_return_val_if_fail (child->parent == node, -1); + + node = node->children; + while (node) + { + if (node == child) + return n; + n++; + node = node->next; + } + + return -1; +} + +gint +g_node_child_index (GNode *node, + gpointer data) +{ + register guint n = 0; + + g_return_val_if_fail (node != NULL, -1); + + node = node->children; + while (node) + { + if (node->data == data) + return n; + n++; + node = node->next; + } + + return -1; +} + +GNode* +g_node_first_sibling (GNode *node) +{ + g_return_val_if_fail (node != NULL, NULL); + + if (node->parent) + return node->parent->children; + + while (node->prev) + node = node->prev; + + return node; +} + +GNode* +g_node_last_sibling (GNode *node) +{ + g_return_val_if_fail (node != NULL, NULL); + + while (node->next) + node = node->next; + + return node; +} + +void +g_node_children_foreach (GNode *node, + GTraverseFlags flags, + GNodeForeachFunc func, + gpointer data) +{ + g_return_if_fail (node != NULL); + g_return_if_fail (flags <= G_TRAVERSE_MASK); + g_return_if_fail (func != NULL); + + node = node->children; + while (node) + { + register GNode *current; + + current = node; + node = current->next; + if (G_NODE_IS_LEAF (current)) + { + if (flags & G_TRAVERSE_LEAFS) + func (current, data); + } + else + { + if (flags & G_TRAVERSE_NON_LEAFS) + func (current, data); + } + } +} diff --git a/graf2d/win32gdk/gdk/src/glib/gnode.h b/graf2d/win32gdk/gdk/src/glib/gnode.h index ba584948467e5..6d79ab0a471a4 100644 --- a/graf2d/win32gdk/gdk/src/glib/gnode.h +++ b/graf2d/win32gdk/gdk/src/glib/gnode.h @@ -27,7 +27,7 @@ #ifndef __G_NODE_H__ #define __G_NODE_H__ -#include <gmem.h> +#include <glib/gmem.h> G_BEGIN_DECLS @@ -72,7 +72,7 @@ struct _GNode ((GNode*) (node))->next == NULL) #define G_NODE_IS_LEAF(node) (((GNode*) (node))->children == NULL) -void g_node_push_allocator (GAllocator *allocato); +void g_node_push_allocator (GAllocator *allocator); void g_node_pop_allocator (void); GNode* g_node_new (gpointer data); void g_node_destroy (GNode *root); diff --git a/graf2d/win32gdk/gdk/src/glib/gobject/gtype.h b/graf2d/win32gdk/gdk/src/glib/gobject/gtype.h new file mode 100644 index 0000000000000..64f82851bb101 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gobject/gtype.h @@ -0,0 +1,401 @@ +/* GObject - GLib Type, Object, Parameter and Signal Library + * Copyright (C) 1998-1999, 2000-2001 Tim Janik and Red Hat, Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General + * Public License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place, Suite 330, + * Boston, MA 02111-1307, USA. + */ +#ifndef __G_TYPE_H__ +#define __G_TYPE_H__ + +extern const char *g_log_domain_gruntime; +#include <glib.h> + +G_BEGIN_DECLS + +/* Basic Type Macros + */ +#define G_TYPE_FUNDAMENTAL(type) ((type) & 0xff) +#define G_TYPE_FUNDAMENTAL_MAX (0xff) +#define G_TYPE_DERIVE_ID(ptype, branch_seqno) (G_TYPE_FUNDAMENTAL (ptype) | ((branch_seqno) << 8)) +#define G_TYPE_BRANCH_SEQNO(type) ((type) >> 8) +#define G_TYPE_FUNDAMENTAL_LAST ((GType) g_type_fundamental_last ()) + + +/* predefined fundamental and derived types + */ +typedef enum /*< skip >*/ +{ + /* standard types, introduced by g_type_init() */ + G_TYPE_INVALID, + G_TYPE_NONE, + G_TYPE_INTERFACE, + + /* GLib type ids */ + G_TYPE_CHAR, + G_TYPE_UCHAR, + G_TYPE_BOOLEAN, + G_TYPE_INT, + G_TYPE_UINT, + G_TYPE_LONG, + G_TYPE_ULONG, + G_TYPE_ENUM, + G_TYPE_FLAGS, + G_TYPE_FLOAT, + G_TYPE_DOUBLE, + G_TYPE_STRING, + G_TYPE_POINTER, + G_TYPE_BOXED, + G_TYPE_PARAM, + G_TYPE_OBJECT, + + /* reserved fundamental type ids, + * mail gtk-devel-list@redhat.com for reservations + */ + G_TYPE_RESERVED_BSE_FIRST, + G_TYPE_RESERVED_BSE_LAST = G_TYPE_RESERVED_BSE_FIRST + 15, + G_TYPE_RESERVED_LAST_FUNDAMENTAL, + + /* derived type ids */ + G_TYPE_CLOSURE = G_TYPE_DERIVE_ID (G_TYPE_BOXED, 1), + G_TYPE_VALUE = G_TYPE_DERIVE_ID (G_TYPE_BOXED, 2), + G_TYPE_VALUE_ARRAY = G_TYPE_DERIVE_ID (G_TYPE_BOXED, 3), + G_TYPE_GSTRING = G_TYPE_DERIVE_ID (G_TYPE_BOXED, 4), + G_TYPE_PARAM_CHAR = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 1), + G_TYPE_PARAM_UCHAR = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 2), + G_TYPE_PARAM_BOOLEAN = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 3), + G_TYPE_PARAM_INT = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 4), + G_TYPE_PARAM_UINT = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 5), + G_TYPE_PARAM_LONG = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 6), + G_TYPE_PARAM_ULONG = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 7), + G_TYPE_PARAM_UNICHAR = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 8), + G_TYPE_PARAM_ENUM = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 9), + G_TYPE_PARAM_FLAGS = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 10), + G_TYPE_PARAM_FLOAT = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 11), + G_TYPE_PARAM_DOUBLE = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 12), + G_TYPE_PARAM_STRING = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 13), + G_TYPE_PARAM_PARAM = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 14), + G_TYPE_PARAM_BOXED = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 15), + G_TYPE_PARAM_POINTER = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 16), + G_TYPE_PARAM_VALUE_ARRAY = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 17), + G_TYPE_PARAM_CLOSURE = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 18), + G_TYPE_PARAM_OBJECT = G_TYPE_DERIVE_ID (G_TYPE_PARAM, 19) +} GTypeFundamentals; + + +/* Type Checking Macros + */ +#define G_TYPE_IS_FUNDAMENTAL(type) (G_TYPE_BRANCH_SEQNO (type) == 0) +#define G_TYPE_IS_DERIVED(type) (G_TYPE_BRANCH_SEQNO (type) > 0) +#define G_TYPE_IS_INTERFACE(type) (G_TYPE_FUNDAMENTAL (type) == G_TYPE_INTERFACE) +#define G_TYPE_IS_CLASSED(type) (g_type_check_flags ((type), G_TYPE_FLAG_CLASSED)) +#define G_TYPE_IS_INSTANTIATABLE(type) (g_type_check_flags ((type), G_TYPE_FLAG_INSTANTIATABLE)) +#define G_TYPE_IS_DERIVABLE(type) (g_type_check_flags ((type), G_TYPE_FLAG_DERIVABLE)) +#define G_TYPE_IS_DEEP_DERIVABLE(type) (g_type_check_flags ((type), G_TYPE_FLAG_DEEP_DERIVABLE)) +#define G_TYPE_IS_ABSTRACT(type) (g_type_check_flags ((type), G_TYPE_FLAG_ABSTRACT)) +#define G_TYPE_IS_VALUE_ABSTRACT(type) (g_type_check_flags ((type), G_TYPE_FLAG_VALUE_ABSTRACT)) +#define G_TYPE_IS_PARAM(type) (G_TYPE_FUNDAMENTAL (type) == G_TYPE_PARAM) +#define G_TYPE_IS_VALUE_TYPE(type) (g_type_check_is_value_type (type)) +#define G_TYPE_HAS_VALUE_TABLE(type) (g_type_value_table_peek (type) != NULL) + + +/* Typedefs + */ +typedef guint32 GType; +typedef struct _GValue GValue; +typedef union _GTypeCValue GTypeCValue; +typedef struct _GTypePlugin GTypePlugin; +typedef struct _GTypeClass GTypeClass; +typedef struct _GTypeInterface GTypeInterface; +typedef struct _GTypeInstance GTypeInstance; +typedef struct _GTypeInfo GTypeInfo; +typedef struct _GTypeFundamentalInfo GTypeFundamentalInfo; +typedef struct _GInterfaceInfo GInterfaceInfo; +typedef struct _GTypeValueTable GTypeValueTable; +typedef struct _GTypeQuery GTypeQuery; + + +/* Basic Type Structures + */ +struct _GTypeClass +{ + /*< private >*/ + GType g_type; +}; +struct _GTypeInstance +{ + /*< private >*/ + GTypeClass *g_class; +}; +struct _GTypeInterface +{ + /*< private >*/ + GType g_type; /* iface type */ + GType g_instance_type; +}; +struct _GTypeQuery +{ + GType type; + const gchar *type_name; + guint class_size; + guint instance_size; +}; + + +/* Casts, checks and accessors for structured types + * usage of these macros is reserved to type implementations only + */ +/*< protected >*/ +#define G_TYPE_CHECK_INSTANCE(instance) (_G_TYPE_CHI ((GTypeInstance*) (instance))) +#define G_TYPE_CHECK_INSTANCE_CAST(instance, g_type, c_type) (_G_TYPE_CIC ((instance), (g_type), c_type)) +#define G_TYPE_CHECK_INSTANCE_TYPE(instance, g_type) (_G_TYPE_CIT ((instance), (g_type))) +#define G_TYPE_INSTANCE_GET_CLASS(instance, g_type, c_type) (_G_TYPE_IGC ((instance), (g_type), c_type)) +#define G_TYPE_INSTANCE_GET_INTERFACE(instance, g_type, c_type) (_G_TYPE_IGI ((instance), (g_type), c_type)) +#define G_TYPE_CHECK_CLASS_CAST(g_class, g_type, c_type) (_G_TYPE_CCC ((g_class), (g_type), c_type)) +#define G_TYPE_CHECK_CLASS_TYPE(g_class, g_type) (_G_TYPE_CCT ((g_class), (g_type))) +#define G_TYPE_CHECK_VALUE(value) (_G_TYPE_CHV ((value))) +#define G_TYPE_CHECK_VALUE_TYPE(value, g_type) (_G_TYPE_CVH ((value), (g_type))) +#define G_TYPE_FROM_INSTANCE(instance) (G_TYPE_FROM_CLASS (((GTypeInstance*) (instance))->g_class)) +#define G_TYPE_FROM_CLASS(g_class) (((GTypeClass*) (g_class))->g_type) +#define G_TYPE_FROM_INTERFACE(g_iface) (((GTypeInterface*) (g_iface))->g_type) + + +/* debug flags for g_type_init_with_debug_flags() */ +typedef enum /*< skip >*/ +{ + G_TYPE_DEBUG_NONE = 0, + G_TYPE_DEBUG_OBJECTS = 1 << 0, + G_TYPE_DEBUG_SIGNALS = 1 << 1, + G_TYPE_DEBUG_MASK = 0x03 +} GTypeDebugFlags; + + +/* --- prototypes --- */ +void g_type_init (void); +void g_type_init_with_debug_flags (GTypeDebugFlags debug_flags); +G_CONST_RETURN gchar* g_type_name (GType type); +GQuark g_type_qname (GType type); +GType g_type_from_name (const gchar *name); +GType g_type_parent (GType type); +guint g_type_depth (GType type); +GType g_type_next_base (GType leaf_type, + GType root_type); +gboolean g_type_is_a (GType type, + GType is_a_type); +guint g_type_fundamental_branch_last (GType type); +gpointer g_type_class_ref (GType type); +gpointer g_type_class_peek (GType type); +void g_type_class_unref (gpointer g_class); +gpointer g_type_class_peek_parent (gpointer g_class); +gpointer g_type_interface_peek (gpointer instance_class, + GType iface_type); +gpointer g_type_interface_peek_parent (gpointer g_iface); + +/* g_free() the returned arrays */ +GType* g_type_children (GType type, + guint *n_children); +GType* g_type_interfaces (GType type, + guint *n_interfaces); + +/* per-type _static_ data */ +void g_type_set_qdata (GType type, + GQuark quark, + gpointer data); +gpointer g_type_get_qdata (GType type, + GQuark quark); +void g_type_query (GType type, + GTypeQuery *query); + + +/* --- type registration --- */ +typedef void (*GBaseInitFunc) (gpointer g_class); +typedef void (*GBaseFinalizeFunc) (gpointer g_class); +typedef void (*GClassInitFunc) (gpointer g_class, + gpointer class_data); +typedef void (*GClassFinalizeFunc) (gpointer g_class, + gpointer class_data); +typedef void (*GInstanceInitFunc) (GTypeInstance *instance, + gpointer g_class); +typedef void (*GInterfaceInitFunc) (gpointer g_iface, + gpointer iface_data); +typedef void (*GInterfaceFinalizeFunc) (gpointer g_iface, + gpointer iface_data); +typedef gboolean (*GTypeClassCacheFunc) (gpointer cache_data, + GTypeClass *g_class); +typedef enum /*< skip >*/ +{ + G_TYPE_FLAG_CLASSED = (1 << 0), + G_TYPE_FLAG_INSTANTIATABLE = (1 << 1), + G_TYPE_FLAG_DERIVABLE = (1 << 2), + G_TYPE_FLAG_DEEP_DERIVABLE = (1 << 3) +} GTypeFundamentalFlags; +typedef enum /*< skip >*/ +{ + G_TYPE_FLAG_ABSTRACT = (1 << 4), + G_TYPE_FLAG_VALUE_ABSTRACT = (1 << 5) +} GTypeFlags; +struct _GTypeInfo +{ + /* interface types, classed types, instantiated types */ + guint16 class_size; + + GBaseInitFunc base_init; + GBaseFinalizeFunc base_finalize; + + /* classed types, instantiated types */ + GClassInitFunc class_init; + GClassFinalizeFunc class_finalize; + gconstpointer class_data; + + /* instantiated types */ + guint16 instance_size; + guint16 n_preallocs; + GInstanceInitFunc instance_init; + + /* value handling */ + const GTypeValueTable *value_table; +}; +struct _GTypeFundamentalInfo +{ + GTypeFundamentalFlags type_flags; +}; +struct _GInterfaceInfo +{ + GInterfaceInitFunc interface_init; + GInterfaceFinalizeFunc interface_finalize; + gpointer interface_data; +}; +struct _GTypeValueTable +{ + void (*value_init) (GValue *value); + void (*value_free) (GValue *value); + void (*value_copy) (const GValue *src_value, + GValue *dest_value); + /* varargs functionality (optional) */ + gpointer (*value_peek_pointer) (const GValue *value); + gchar *collect_format; + gchar* (*collect_value) (GValue *value, + guint n_collect_values, + GTypeCValue *collect_values, + guint collect_flags); + gchar *lcopy_format; + gchar* (*lcopy_value) (const GValue *value, + guint n_collect_values, + GTypeCValue *collect_values, + guint collect_flags); +}; +GType g_type_register_static (GType parent_type, + const gchar *type_name, + const GTypeInfo *info, + GTypeFlags flags); +GType g_type_register_dynamic (GType parent_type, + const gchar *type_name, + GTypePlugin *plugin, + GTypeFlags flags); +GType g_type_register_fundamental (GType type_id, + const gchar *type_name, + const GTypeInfo *info, + const GTypeFundamentalInfo *finfo, + GTypeFlags flags); +void g_type_add_interface_static (GType instance_type, + GType interface_type, + const GInterfaceInfo *info); +void g_type_add_interface_dynamic (GType instance_type, + GType interface_type, + GTypePlugin *plugin); +void g_type_interface_add_prerequisite (GType interface_type, + GType prerequisite_type); + + +/* --- protected (for fundamental type implementations) --- */ +GTypePlugin* g_type_get_plugin (GType type); +GTypePlugin* g_type_interface_get_plugin (GType instance_type, + GType implementation_type); + +GType g_type_fundamental_last (void); +gboolean g_type_check_flags (GType type, + guint flags); +GTypeInstance* g_type_create_instance (GType type); +void g_type_free_instance (GTypeInstance *instance); +void g_type_add_class_cache_func (gpointer cache_data, + GTypeClassCacheFunc cache_func); +void g_type_remove_class_cache_func (gpointer cache_data, + GTypeClassCacheFunc cache_func); +void g_type_class_unref_uncached (gpointer g_class); + + +/*< private >*/ +gboolean g_type_check_instance (GTypeInstance *instance); +GTypeInstance* g_type_check_instance_cast (GTypeInstance *instance, + GType iface_type); +gboolean g_type_instance_is_a (GTypeInstance *instance, + GType iface_type); +GTypeClass* g_type_check_class_cast (GTypeClass *g_class, + GType is_a_type); +gboolean g_type_class_is_a (GTypeClass *g_class, + GType is_a_type); +gboolean g_type_check_is_value_type (GType type); +gboolean g_type_check_value (GValue *value); +gboolean g_type_check_value_holds (GValue *value, + GType type); +GTypeValueTable* g_type_value_table_peek (GType type); + + +/* --- debugging functions --- */ +G_CONST_RETURN gchar* g_type_name_from_instance (GTypeInstance *instance); +G_CONST_RETURN gchar* g_type_name_from_class (GTypeClass *g_class); + + +/* --- implementation bits --- */ +#ifndef G_DISABLE_CAST_CHECKS +# define _G_TYPE_CIC(ip, gt, ct) \ + ((ct*) g_type_check_instance_cast ((GTypeInstance*) ip, gt)) +# define _G_TYPE_CCC(cp, gt, ct) \ + ((ct*) g_type_check_class_cast ((GTypeClass*) cp, gt)) +#else /* G_DISABLE_CAST_CHECKS */ +# define _G_TYPE_CIC(ip, gt, ct) ((ct*) ip) +# define _G_TYPE_CCC(cp, gt, ct) ((ct*) cp) +#endif /* G_DISABLE_CAST_CHECKS */ +#define _G_TYPE_CHI(ip) (g_type_check_instance ((GTypeInstance*) ip)) +#define _G_TYPE_CVH(vl, gt) (g_type_check_value_holds ((GValue*) vl, gt)) +#define _G_TYPE_CHV(vl) (g_type_check_value ((GValue*) vl)) +#define _G_TYPE_IGC(ip, gt, ct) ((ct*) (((GTypeInstance*) ip)->g_class)) +#define _G_TYPE_IGI(ip, gt, ct) ((ct*) g_type_interface_peek (((GTypeInstance*) ip)->g_class, gt)) +#ifdef __GNUC__ +# define _G_TYPE_CIT(ip, gt) ({ \ + GTypeInstance *__inst = (GTypeInstance*) ip; GType __t = gt; gboolean __r; \ + if (__inst && __inst->g_class && __inst->g_class->g_type == __t) \ + __r = TRUE; \ + else \ + __r = g_type_instance_is_a (__inst, __t); \ + __r; \ +}) +# define _G_TYPE_CCT(cp, gt) ({ \ + GTypeClass *__class = (GTypeClass*) cp; GType __t = gt; gboolean __r; \ + if (__class && __class->g_type == __t) \ + __r = TRUE; \ + else \ + __r = g_type_class_is_a (__class, __t); \ + __r; \ +}) +#else /* !__GNUC__ */ +# define _G_TYPE_CIT(ip, gt) (g_type_instance_is_a ((GTypeInstance*) ip, gt)) +# define _G_TYPE_CCT(cp, gt) (g_type_class_is_a ((GTypeClass*) cp, gt)) +#endif /* !__GNUC__ */ +#define G_TYPE_FLAG_RESERVED_ID_BIT (1 << 30) +extern GTypeDebugFlags _g_type_debug_flags; + +G_END_DECLS + +#endif /* __G_TYPE_H__ */ diff --git a/graf2d/win32gdk/gdk/src/glib/gpattern.c b/graf2d/win32gdk/gdk/src/glib/gpattern.c new file mode 100644 index 0000000000000..a149273a0d3be --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gpattern.c @@ -0,0 +1,300 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997, 1999 Peter Mattis, Red Hat, Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ +#include "gpattern.h" + +#include "gmacros.h" +#include "gmessages.h" +#include "gmem.h" +#include "gutils.h" /* inline hassle */ +#include <string.h> + + +/* --- functions --- */ +static inline gboolean +g_pattern_ph_match (const gchar *match_pattern, + const gchar *match_string) +{ + register const gchar *pattern, *string; + register gchar ch; + + pattern = match_pattern; + string = match_string; + + ch = *pattern; + pattern++; + while (ch) + { + switch (ch) + { + case '?': + if (!*string) + return FALSE; + string++; + break; + + case '*': + do + { + ch = *pattern; + pattern++; + if (ch == '?') + { + if (!*string) + return FALSE; + string++; + } + } + while (ch == '*' || ch == '?'); + if (!ch) + return TRUE; + do + { + while (ch != *string) + { + if (!*string) + return FALSE; + string++; + } + string++; + if (g_pattern_ph_match (pattern, string)) + return TRUE; + } + while (*string); + break; + + default: + if (ch == *string) + string++; + else + return FALSE; + break; + } + + ch = *pattern; + pattern++; + } + + return *string == 0; +} + +gboolean +g_pattern_match (GPatternSpec *pspec, + guint string_length, + const gchar *string, + const gchar *string_reversed) +{ + g_return_val_if_fail (pspec != NULL, FALSE); + g_return_val_if_fail (string != NULL, FALSE); + g_return_val_if_fail (string_reversed != NULL, FALSE); + + switch (pspec->match_type) + { + case G_MATCH_ALL: + return g_pattern_ph_match (pspec->pattern, string); + + case G_MATCH_ALL_TAIL: + return g_pattern_ph_match (pspec->pattern_reversed, string_reversed); + + case G_MATCH_HEAD: + if (pspec->pattern_length > string_length) + return FALSE; + else if (pspec->pattern_length == string_length) + return strcmp (pspec->pattern, string) == 0; + else if (pspec->pattern_length) + return strncmp (pspec->pattern, string, pspec->pattern_length) == 0; + else + return TRUE; + + case G_MATCH_TAIL: + if (pspec->pattern_length > string_length) + return FALSE; + else if (pspec->pattern_length == string_length) + return strcmp (pspec->pattern_reversed, string_reversed) == 0; + else if (pspec->pattern_length) + return strncmp (pspec->pattern_reversed, + string_reversed, + pspec->pattern_length) == 0; + else + return TRUE; + + case G_MATCH_EXACT: + if (pspec->pattern_length != string_length) + return FALSE; + else + return strcmp (pspec->pattern_reversed, string_reversed) == 0; + + default: + g_return_val_if_fail (pspec->match_type < G_MATCH_LAST, FALSE); + return FALSE; + } +} + +GPatternSpec* +g_pattern_spec_new (const gchar *pattern) +{ + GPatternSpec *pspec; + gchar *p, *t; + const gchar *h; + guint hw = 0, tw = 0, hj = 0, tj = 0; + + g_return_val_if_fail (pattern != NULL, NULL); + + pspec = g_new (GPatternSpec, 1); + pspec->pattern_length = strlen (pattern); + pspec->pattern = strcpy (g_new (gchar, pspec->pattern_length + 1), pattern); + pspec->pattern_reversed = g_new (gchar, pspec->pattern_length + 1); + t = pspec->pattern_reversed + pspec->pattern_length; + *(t--) = 0; + h = pattern; + while (t >= pspec->pattern_reversed) + { + register gchar c = *(h++); + + if (c == '*') + { + if (t < h) + hw++; + else + tw++; + } + else if (c == '?') + { + if (t < h) + hj++; + else + tj++; + } + + *(t--) = c; + } + pspec->match_type = hw > tw || (hw == tw && hj > tj) ? G_MATCH_ALL_TAIL : G_MATCH_ALL; + + if (hj || tj) + return pspec; + + if (hw == 0 && tw == 0) + { + pspec->match_type = G_MATCH_EXACT; + return pspec; + } + + if (hw) + { + p = pspec->pattern; + while (*p == '*') + p++; + if (p > pspec->pattern && !strchr (p, '*')) + { + gchar *tmp; + + pspec->match_type = G_MATCH_TAIL; + pspec->pattern_length = strlen (p); + tmp = pspec->pattern; + pspec->pattern = strcpy (g_new (gchar, pspec->pattern_length + 1), p); + g_free (tmp); + g_free (pspec->pattern_reversed); + pspec->pattern_reversed = g_new (gchar, pspec->pattern_length + 1); + t = pspec->pattern_reversed + pspec->pattern_length; + *(t--) = 0; + h = pspec->pattern; + while (t >= pspec->pattern_reversed) + *(t--) = *(h++); + return pspec; + } + } + + if (tw) + { + p = pspec->pattern_reversed; + while (*p == '*') + p++; + if (p > pspec->pattern_reversed && !strchr (p, '*')) + { + gchar *tmp; + + pspec->match_type = G_MATCH_HEAD; + pspec->pattern_length = strlen (p); + tmp = pspec->pattern_reversed; + pspec->pattern_reversed = strcpy (g_new (gchar, pspec->pattern_length + 1), p); + g_free (tmp); + g_free (pspec->pattern); + pspec->pattern = g_new (gchar, pspec->pattern_length + 1); + t = pspec->pattern + pspec->pattern_length; + *(t--) = 0; + h = pspec->pattern_reversed; + while (t >= pspec->pattern) + *(t--) = *(h++); + } + } + + return pspec; +} + +gboolean +g_pattern_match_string (GPatternSpec *pspec, + const gchar *string) +{ + gchar *string_reversed, *t; + const gchar *h; + guint length; + gboolean ergo; + + g_return_val_if_fail (pspec != NULL, FALSE); + g_return_val_if_fail (string != NULL, FALSE); + + length = strlen (string); + string_reversed = g_new (gchar, length + 1); + t = string_reversed + length; + *(t--) = 0; + h = string; + while (t >= string_reversed) + *(t--) = *(h++); + + ergo = g_pattern_match (pspec, length, string, string_reversed); + g_free (string_reversed); + + return ergo; +} + +gboolean +g_pattern_match_simple (const gchar *pattern, + const gchar *string) +{ + GPatternSpec *pspec; + gboolean ergo; + + g_return_val_if_fail (pattern != NULL, FALSE); + g_return_val_if_fail (string != NULL, FALSE); + + pspec = g_pattern_spec_new (pattern); + ergo = g_pattern_match_string (pspec, string); + g_pattern_spec_free (pspec); + + return ergo; +} + +void +g_pattern_spec_free (GPatternSpec *pspec) +{ + g_return_if_fail (pspec != NULL); + + g_free (pspec->pattern); + g_free (pspec->pattern_reversed); + g_free (pspec); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gpattern.h b/graf2d/win32gdk/gdk/src/glib/gpattern.h new file mode 100644 index 0000000000000..bd29ad7ac7cfa --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gpattern.h @@ -0,0 +1,58 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997, 1999 Peter Mattis, Red Hat, Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ +#ifndef __G_PATTERN_H__ +#define __G_PATTERN_H__ + +#include <glib/gtypes.h> + +G_BEGIN_DECLS + +typedef enum +{ + G_MATCH_ALL, /* "*A?A*" */ + G_MATCH_ALL_TAIL, /* "*A?AA" */ + G_MATCH_HEAD, /* "AAAA*" */ + G_MATCH_TAIL, /* "*AAAA" */ + G_MATCH_EXACT, /* "AAAAA" */ + G_MATCH_LAST +} GMatchType; + +typedef struct _GPatternSpec GPatternSpec; +struct _GPatternSpec +{ + GMatchType match_type; + guint pattern_length; + gchar *pattern; + gchar *pattern_reversed; +}; + +GPatternSpec* g_pattern_spec_new (const gchar *pattern); +void g_pattern_spec_free (GPatternSpec *pspec); +gboolean g_pattern_match (GPatternSpec *pspec, + guint string_length, + const gchar *string, + const gchar *string_reversed); +gboolean g_pattern_match_string (GPatternSpec *pspec, + const gchar *string); +gboolean g_pattern_match_simple (const gchar *pattern, + const gchar *string); + +G_END_DECLS + +#endif /* __G_PATTERN_H__ */ diff --git a/graf2d/win32gdk/gdk/src/glib/gprimes.c b/graf2d/win32gdk/gdk/src/glib/gprimes.c new file mode 100644 index 0000000000000..0d63bb76c75de --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gprimes.c @@ -0,0 +1,83 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#include "glib.h" + +static const guint g_primes[] = +{ + 11, + 19, + 37, + 73, + 109, + 163, + 251, + 367, + 557, + 823, + 1237, + 1861, + 2777, + 4177, + 6247, + 9371, + 14057, + 21089, + 31627, + 47431, + 71143, + 106721, + 160073, + 240101, + 360163, + 540217, + 810343, + 1215497, + 1823231, + 2734867, + 4102283, + 6153409, + 9230113, + 13845163, +}; + +static const guint g_nprimes = sizeof (g_primes) / sizeof (g_primes[0]); + +guint +g_spaced_primes_closest (guint num) +{ + gint i; + + for (i = 0; i < g_nprimes; i++) + if (g_primes[i] > num) + return g_primes[i]; + + return g_primes[g_nprimes - 1]; +} diff --git a/graf2d/win32gdk/gdk/src/glib/gprimes.h b/graf2d/win32gdk/gdk/src/glib/gprimes.h index 5431b8929b825..0f1740cb16fe9 100644 --- a/graf2d/win32gdk/gdk/src/glib/gprimes.h +++ b/graf2d/win32gdk/gdk/src/glib/gprimes.h @@ -27,7 +27,7 @@ #ifndef __G_PRIMES_H__ #define __G_PRIMES_H__ -#include <g_types.h> +#include <glib/gtypes.h> G_BEGIN_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gqsort.c b/graf2d/win32gdk/gdk/src/glib/gqsort.c new file mode 100644 index 0000000000000..040be793fbf77 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gqsort.c @@ -0,0 +1,282 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1991, 1992, 1996, 1997 Free Software Foundation, Inc. + * Copyright (C) 2000 Eazel, Inc. + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * This file was originally part of the GNU C Library, and was modified to allow + * user data to be passed in to the sorting function. + * + * Written by Douglas C. Schmidt (schmidt@ics.uci.edu). + * Modified by Maciej Stachowiak (mjs@eazel.com) + * + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with GLib + * at ftp://ftp.gtk.org/pub/gtk/. + */ + +#include <string.h> + +#include "glib.h" + +/* Byte-wise swap two items of size SIZE. */ +#define SWAP(a, b, size) \ + do \ + { \ + register size_t __size = (size); \ + register char *__a = (a), *__b = (b); \ + do \ + { \ + char __tmp = *__a; \ + *__a++ = *__b; \ + *__b++ = __tmp; \ + } while (--__size > 0); \ + } while (0) + +/* Discontinue quicksort algorithm when partition gets below this size. + This particular magic number was chosen to work best on a Sun 4/260. */ +#define MAX_THRESH 4 + +/* Stack node declarations used to store unfulfilled partition obligations. */ +typedef struct +{ + char *lo; + char *hi; +} +stack_node; + +/* The next 4 #defines implement a very fast in-line stack abstraction. */ +#define STACK_SIZE (8 * sizeof(unsigned long int)) +#define PUSH(low, high) ((void) ((top->lo = (low)), (top->hi = (high)), ++top)) +#define POP(low, high) ((void) (--top, (low = top->lo), (high = top->hi))) +#define STACK_NOT_EMPTY (stack < top) + + +/* Order size using quicksort. This implementation incorporates + * four optimizations discussed in Sedgewick: + * + * 1. Non-recursive, using an explicit stack of pointer that store the next + * array partition to sort. To save time, this maximum amount of space + * required to store an array of MAX_INT is allocated on the stack. Assuming + * a 32-bit integer, this needs only 32 * sizeof(stack_node) == 136 bits. + * Pretty cheap, actually. + * + * 2. Chose the pivot element using a median-of-three decision tree. This + * reduces the probability of selecting a bad pivot value and eliminates + * certain * extraneous comparisons. + * + * 3. Only quicksorts TOTAL_ELEMS / MAX_THRESH partitions, leaving insertion + * sort to order the MAX_THRESH items within each partition. This is a big + * win, since insertion sort is faster for small, mostly sorted array + * segments. + * + * 4. The larger of the two sub-partitions is always pushed onto the stack + * first, with the algorithm then concentrating on the smaller partition. + * This *guarantees* no more than log (n) stack size is needed (actually O(1) + * in this case)! + */ + +/** + * g_qsort_with_data: + * @pbase: start of array to sort + * @total_elems: elements in the array + * @size: size of each element + * @compare_func: function to compare elements + * @user_data: data to pass to @compare_func + * + * This is just like the standard C qsort() function, but + * the comparison routine accepts a user data argument. + * + **/ +void +g_qsort_with_data (gconstpointer pbase, + gint total_elems, + size_t size, + GCompareDataFunc compare_func, + gpointer user_data) +{ + register char *base_ptr = (char *) pbase; + + /* Allocating SIZE bytes for a pivot buffer facilitates a better + * algorithm below since we can do comparisons directly on the pivot. + */ + char *pivot_buffer = (char *) g_alloca (size); + const size_t max_thresh = MAX_THRESH * size; + + g_return_if_fail (total_elems > 0); + g_return_if_fail (pbase != NULL); + g_return_if_fail (compare_func != NULL); + + if (total_elems > MAX_THRESH) + { + char *lo = base_ptr; + char *hi = &lo[size * (total_elems - 1)]; + /* Largest size needed for 32-bit int!!! */ + stack_node stack[STACK_SIZE]; + stack_node *top = stack + 1; + + while (STACK_NOT_EMPTY) + { + char *left_ptr; + char *right_ptr; + + char *pivot = pivot_buffer; + + /* Select median value from among LO, MID, and HI. Rearrange + * LO and HI so the three values are sorted. This lowers the + * probability of picking a pathological pivot value and + * skips a comparison for both the LEFT_PTR and RIGHT_PTR. */ + + char *mid = lo + size * ((hi - lo) / size >> 1); + + if ((*compare_func) ((void *) mid, (void *) lo, user_data) < 0) + SWAP (mid, lo, size); + if ((*compare_func) ((void *) hi, (void *) mid, user_data) < 0) + SWAP (mid, hi, size); + else + goto jump_over; + if ((*compare_func) ((void *) mid, (void *) lo, user_data) < 0) + SWAP (mid, lo, size); + jump_over:; + memcpy (pivot, mid, size); + pivot = pivot_buffer; + + left_ptr = lo + size; + right_ptr = hi - size; + + /* Here's the famous ``collapse the walls'' section of quicksort. + * Gotta like those tight inner loops! They are the main reason + * that this algorithm runs much faster than others. */ + do + { + while ((*compare_func) + ((void *) left_ptr, (void *) pivot, + user_data) < 0) + left_ptr += size; + + while ((*compare_func) + ((void *) pivot, (void *) right_ptr, + user_data) < 0) + right_ptr -= size; + + if (left_ptr < right_ptr) + { + SWAP (left_ptr, right_ptr, size); + left_ptr += size; + right_ptr -= size; + } + else if (left_ptr == right_ptr) + { + left_ptr += size; + right_ptr -= size; + break; + } + } + while (left_ptr <= right_ptr); + + /* Set up pointers for next iteration. First determine whether + * left and right partitions are below the threshold size. If so, + * ignore one or both. Otherwise, push the larger partition's + * bounds on the stack and continue sorting the smaller one. */ + + if ((size_t) (right_ptr - lo) <= max_thresh) + { + if ((size_t) (hi - left_ptr) <= max_thresh) + /* Ignore both small partitions. */ + POP (lo, hi); + else + /* Ignore small left partition. */ + lo = left_ptr; + } + else if ((size_t) (hi - left_ptr) <= max_thresh) + /* Ignore small right partition. */ + hi = right_ptr; + else if ((right_ptr - lo) > (hi - left_ptr)) + { + /* Push larger left partition indices. */ + PUSH (lo, right_ptr); + lo = left_ptr; + + } + else + { + /* Push larger right partition indices. */ + PUSH (left_ptr, hi); + hi = right_ptr; + } + } + } + + /* Once the BASE_PTR array is partially sorted by quicksort the rest + * is completely sorted using insertion sort, since this is efficient + * for partitions below MAX_THRESH size. BASE_PTR points to the beginning + * of the array to sort, and END_PTR points at the very last element in + * the array (*not* one beyond it!). */ + + { + char *const end_ptr = &base_ptr[size * (total_elems - 1)]; + char *tmp_ptr = base_ptr; + char *thresh = MIN (end_ptr, base_ptr + max_thresh); + register char *run_ptr; + + /* Find smallest element in first threshold and place it at the + * array's beginning. This is the smallest array element, + * and the operation speeds up insertion sort's inner loop. */ + + for (run_ptr = tmp_ptr + size; run_ptr <= thresh; + run_ptr += + size) if ((*compare_func) ((void *) run_ptr, (void *) tmp_ptr, + user_data) < 0) + tmp_ptr = run_ptr; + + if (tmp_ptr != base_ptr) + SWAP (tmp_ptr, base_ptr, size); + + /* Insertion sort, running from left-hand-side up to right-hand-side. */ + + run_ptr = base_ptr + size; + while ((run_ptr += size) <= end_ptr) + { + tmp_ptr = run_ptr - size; + while ((*compare_func) + ((void *) run_ptr, (void *) tmp_ptr, + user_data) < 0) + tmp_ptr -= size; + + tmp_ptr += size; + if (tmp_ptr != run_ptr) + { + char *trav; + + trav = run_ptr + size; + while (--trav >= run_ptr) + { + char c = *trav; + char *hi, *lo; + + for (hi = lo = trav; + (lo -= size) >= tmp_ptr; hi = lo) + *hi = *lo; + *hi = c; + } + } + } + } +} diff --git a/graf2d/win32gdk/gdk/src/glib/gqsort.h b/graf2d/win32gdk/gdk/src/glib/gqsort.h index 45fe333005f3b..12e7a05b13eed 100644 --- a/graf2d/win32gdk/gdk/src/glib/gqsort.h +++ b/graf2d/win32gdk/gdk/src/glib/gqsort.h @@ -28,14 +28,14 @@ #ifndef __G_QSORT_H__ #define __G_QSORT_H__ -#include <g_types.h> +#include <glib/gtypes.h> G_BEGIN_DECLS void g_qsort_with_data (gconstpointer pbase, gint total_elems, size_t size, - GCompareFuncData compare_func, + GCompareDataFunc compare_func, gpointer user_data); G_END_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gquark.h b/graf2d/win32gdk/gdk/src/glib/gquark.h index 69d5fb0889c7b..6b96dcf64d184 100644 --- a/graf2d/win32gdk/gdk/src/glib/gquark.h +++ b/graf2d/win32gdk/gdk/src/glib/gquark.h @@ -27,7 +27,7 @@ #ifndef __G_QUARK_H__ #define __G_QUARK_H__ -#include <g_types.h> +#include <glib/gtypes.h> G_BEGIN_DECLS @@ -35,10 +35,10 @@ typedef guint32 GQuark; /* Quarks (string<->id association) */ -GQuark g_quark_try_string (const gchar *string); -GQuark g_quark_from_static_string (const gchar *string); -GQuark g_quark_from_string (const gchar *string); -gchar* g_quark_to_string (GQuark quark) G_GNUC_CONST; +GQuark g_quark_try_string (const gchar *string); +GQuark g_quark_from_static_string (const gchar *string); +GQuark g_quark_from_string (const gchar *string); +G_CONST_RETURN gchar* g_quark_to_string (GQuark quark) G_GNUC_CONST; G_END_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gqueue.c b/graf2d/win32gdk/gdk/src/glib/gqueue.c new file mode 100644 index 0000000000000..b15adb4f9f833 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gqueue.c @@ -0,0 +1,263 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * GQueue: Double ended queue implementation, piggy backed on GList. + * Copyright (C) 1998 Tim Janik + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include "glib.h" + + +G_LOCK_DEFINE_STATIC (queue_memchunk); +static GMemChunk *queue_memchunk = NULL; +static GTrashStack *free_queue_nodes = NULL; + +GQueue* +g_queue_new (void) +{ + GQueue *queue; + + G_LOCK (queue_memchunk); + queue = g_trash_stack_pop (&free_queue_nodes); + + if (!queue) + { + if (!queue_memchunk) + queue_memchunk = g_mem_chunk_new ("GLib GQueue chunk", + sizeof (GNode), + sizeof (GNode) * 128, + G_ALLOC_ONLY); + queue = g_chunk_new (GQueue, queue_memchunk); + } + G_UNLOCK (queue_memchunk); + + queue->head = NULL; + queue->tail = NULL; + queue->length = 0; + + return queue; +} + +void +g_queue_free (GQueue *queue) +{ + g_return_if_fail (queue != NULL); + + g_list_free (queue->head); + +#ifdef ENABLE_GC_FRIENDLY + queue->head = NULL; + queue->tail = NULL; +#endif /* ENABLE_GC_FRIENDLY */ + + G_LOCK (queue_memchunk); + g_trash_stack_push (&free_queue_nodes, queue); + G_UNLOCK (queue_memchunk); +} + +void +g_queue_push_head (GQueue *queue, + gpointer data) +{ + g_return_if_fail (queue != NULL); + + queue->head = g_list_prepend (queue->head, data); + if (!queue->tail) + queue->tail = queue->head; + queue->length++; +} + +void +g_queue_push_head_link (GQueue *queue, + GList *link) +{ + g_return_if_fail (queue != NULL); + g_return_if_fail (link != NULL); + g_return_if_fail (link->prev == NULL); + g_return_if_fail (link->next == NULL); + + link->next = queue->head; + if (queue->head) + queue->head->prev = link; + else + queue->tail = link; + queue->head = link; + queue->length++; +} + +void +g_queue_push_tail (GQueue *queue, + gpointer data) +{ + g_return_if_fail (queue != NULL); + + queue->tail = g_list_append (queue->tail, data); + if (queue->tail->next) + queue->tail = queue->tail->next; + else + queue->head = queue->tail; + queue->length++; +} + +void +g_queue_push_tail_link (GQueue *queue, + GList *link) +{ + g_return_if_fail (queue != NULL); + g_return_if_fail (link != NULL); + g_return_if_fail (link->prev == NULL); + g_return_if_fail (link->next == NULL); + + link->prev = queue->tail; + if (queue->tail) + queue->tail->next = link; + else + queue->head = link; + queue->tail = link; + queue->length++; +} + +gpointer +g_queue_pop_head (GQueue *queue) +{ + g_return_val_if_fail (queue != NULL, NULL); + + if (queue->head) + { + GList *node = queue->head; + gpointer data = node->data; + + queue->head = node->next; + if (queue->head) + queue->head->prev = NULL; + else + queue->tail = NULL; + g_list_free_1 (node); + queue->length--; + + return data; + } + + return NULL; +} + +GList* +g_queue_pop_head_link (GQueue *queue) +{ + g_return_val_if_fail (queue != NULL, NULL); + + if (queue->head) + { + GList *node = queue->head; + + queue->head = node->next; + if (queue->head) + { + queue->head->prev = NULL; + node->next = NULL; + } + else + queue->tail = NULL; + queue->length--; + + return node; + } + + return NULL; +} + +gpointer +g_queue_pop_tail (GQueue *queue) +{ + g_return_val_if_fail (queue != NULL, NULL); + + if (queue->tail) + { + GList *node = queue->tail; + gpointer data = node->data; + + queue->tail = node->prev; + if (queue->tail) + queue->tail->next = NULL; + else + queue->head = NULL; + queue->length--; + g_list_free_1 (node); + + return data; + } + + return NULL; +} + +GList* +g_queue_pop_tail_link (GQueue *queue) +{ + g_return_val_if_fail (queue != NULL, NULL); + + if (queue->tail) + { + GList *node = queue->tail; + + queue->tail = node->prev; + if (queue->tail) + { + queue->tail->next = NULL; + node->prev = NULL; + } + else + queue->head = NULL; + queue->length--; + + return node; + } + + return NULL; +} + +gboolean +g_queue_is_empty (GQueue *queue) +{ + g_return_val_if_fail (queue != NULL, TRUE); + + return queue->head == NULL; +} + +gpointer +g_queue_peek_head (GQueue *queue) +{ + g_return_val_if_fail (queue != NULL, NULL); + + return queue->head ? queue->head->data : NULL; +} + +gpointer +g_queue_peek_tail (GQueue *queue) +{ + g_return_val_if_fail (queue != NULL, NULL); + + return queue->tail ? queue->tail->data : NULL; +} diff --git a/graf2d/win32gdk/gdk/src/glib/gqueue.h b/graf2d/win32gdk/gdk/src/glib/gqueue.h index b71b6d61ef294..64fd692822226 100644 --- a/graf2d/win32gdk/gdk/src/glib/gqueue.h +++ b/graf2d/win32gdk/gdk/src/glib/gqueue.h @@ -27,7 +27,7 @@ #ifndef __G_QUEUE_H__ #define __G_QUEUE_H__ -#include <glist.h> +#include <glib/glist.h> G_BEGIN_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/grand.c b/graf2d/win32gdk/gdk/src/glib/grand.c new file mode 100644 index 0000000000000..2a60e5bd51ddb --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/grand.c @@ -0,0 +1,403 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* Originally developed and coded by Makoto Matsumoto and Takuji + * Nishimura. Please mail <matumoto@math.keio.ac.jp>, if you're using + * code from this file in your own programs or libraries. + * Further information on the Mersenne Twister can be found at + * http://www.math.keio.ac.jp/~matumoto/emt.html + * This code was adapted to glib by Sebastian Wilhelmi <wilhelmi@ira.uka.de>. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#include <glib.h> +#include <math.h> +#include <stdio.h> + +G_LOCK_DEFINE_STATIC (global_random); +static GRand* global_random = NULL; + +/* Period parameters */ +#define N 624 +#define M 397 +#define MATRIX_A 0x9908b0df /* constant vector a */ +#define UPPER_MASK 0x80000000 /* most significant w-r bits */ +#define LOWER_MASK 0x7fffffff /* least significant r bits */ + +/* Tempering parameters */ +#define TEMPERING_MASK_B 0x9d2c5680 +#define TEMPERING_MASK_C 0xefc60000 +#define TEMPERING_SHIFT_U(y) (y >> 11) +#define TEMPERING_SHIFT_S(y) (y << 7) +#define TEMPERING_SHIFT_T(y) (y << 15) +#define TEMPERING_SHIFT_L(y) (y >> 18) + +struct _GRand +{ + guint32 mt[N]; /* the array for the state vector */ + guint mti; +}; + +/** + * g_rand_new_with_seed: + * @seed: a value to initialize the random number generator. + * + * Creates a new random number generator initialized with @seed. + * + * Return value: the new #GRand. + **/ +GRand* +g_rand_new_with_seed (guint32 seed) +{ + GRand *rand = g_new0 (GRand, 1); + g_rand_set_seed (rand, seed); + return rand; +} + +/** + * g_rand_new: + * + * Creates a new random number generator initialized with a seed taken + * either from /dev/urandom (if existing) or from the current time (as + * a fallback). + * + * Return value: the new #GRand. + **/ +GRand* +g_rand_new (void) +{ + guint32 seed; + GTimeVal now; + static gboolean dev_urandom_exists = TRUE; + + if (dev_urandom_exists) + { + FILE* dev_urandom = fopen("/dev/urandom", "rb"); + if (dev_urandom) + { + if (fread (&seed, sizeof (seed), 1, dev_urandom) != 1) + dev_urandom_exists = FALSE; + fclose (dev_urandom); + } + else + dev_urandom_exists = FALSE; + } + if (!dev_urandom_exists) + { + g_get_current_time (&now); + seed = now.tv_sec ^ now.tv_usec; + } + + return g_rand_new_with_seed (seed); +} + +/** + * g_rand_free: + * @rand: a #GRand. + * + * Frees the memory allocated for the #GRand. + **/ +void +g_rand_free (GRand* rand) +{ + g_return_if_fail (rand != NULL); + + g_free (rand); +} + +/** + * g_rand_set_seed: + * @rand: a #GRand. + * @seed: a value to reinitialize the random number generator. + * + * Sets the seed for the random number generator #GRand to @seed. + **/ +void +g_rand_set_seed (GRand* rand, guint32 seed) +{ + g_return_if_fail (rand != NULL); + + /* setting initial seeds to mt[N] using */ + /* the generator Line 25 of Table 1 in */ + /* [KNUTH 1981, The Art of Computer Programming */ + /* Vol. 2 (2nd Ed.), pp102] */ + + if (seed == 0) /* This would make the PRNG procude only zeros */ + seed = 0x6b842128; /* Just set it to another number */ + + rand->mt[0]= seed & 0xffffffff; + for (rand->mti=1; rand->mti<N; rand->mti++) + rand->mt[rand->mti] = (69069 * rand->mt[rand->mti-1]) & 0xffffffff; +} + +/** + * g_rand_int: + * @rand: a #GRand. + * + * Return the next random #guint32 from @rand equaly distributed over + * the range [0..2^32-1]. + * + * Return value: A random number. + **/ +guint32 +g_rand_int (GRand* rand) +{ + guint32 y; + static const guint32 mag01[2]={0x0, MATRIX_A}; + /* mag01[x] = x * MATRIX_A for x=0,1 */ + + g_return_val_if_fail (rand != NULL, 0); + + if (rand->mti >= N) { /* generate N words at one time */ + int kk; + + for (kk=0;kk<N-M;kk++) { + y = (rand->mt[kk]&UPPER_MASK)|(rand->mt[kk+1]&LOWER_MASK); + rand->mt[kk] = rand->mt[kk+M] ^ (y >> 1) ^ mag01[y & 0x1]; + } + for (;kk<N-1;kk++) { + y = (rand->mt[kk]&UPPER_MASK)|(rand->mt[kk+1]&LOWER_MASK); + rand->mt[kk] = rand->mt[kk+(M-N)] ^ (y >> 1) ^ mag01[y & 0x1]; + } + y = (rand->mt[N-1]&UPPER_MASK)|(rand->mt[0]&LOWER_MASK); + rand->mt[N-1] = rand->mt[M-1] ^ (y >> 1) ^ mag01[y & 0x1]; + + rand->mti = 0; + } + + y = rand->mt[rand->mti++]; + y ^= TEMPERING_SHIFT_U(y); + y ^= TEMPERING_SHIFT_S(y) & TEMPERING_MASK_B; + y ^= TEMPERING_SHIFT_T(y) & TEMPERING_MASK_C; + y ^= TEMPERING_SHIFT_L(y); + + return y; +} + +/* transform [0..2^32] -> [0..1] */ +#define G_RAND_DOUBLE_TRANSFORM 2.3283064365386962890625e-10 + +/** + * g_rand_int_range: + * @rand: a #GRand. + * @begin: lower closed bound of the interval. + * @end: upper open bound of the interval. + * + * Return the next random #gint32 from @rand equaly distributed over + * the range [@begin..@end-1]. + * + * Return value: A random number. + **/ +gint32 +g_rand_int_range (GRand* rand, gint32 begin, gint32 end) +{ + guint32 dist = end - begin; + guint32 random; + + g_return_val_if_fail (rand != NULL, begin); + g_return_val_if_fail (end > begin, begin); + + /* All tricks doing modulo calculations do not have a perfect + * distribution -> We must use the slower way through gdouble for + * maximal quality. */ + + if (dist <= 0x10000L) /* 2^16 */ + { + /* This method, which only calls g_rand_int once is only good + * for (end - begin) <= 2^16, because we only have 32 bits set + * from the one call to g_rand_int (). */ + + /* we are using (trans + trans * trans), because g_rand_int only + * covers [0..2^32-1] and thus g_rand_int * trans only covers + * [0..1-2^-32], but the biggest double < 1 is 1-2^-52. + */ + + gdouble double_rand = g_rand_int (rand) * + (G_RAND_DOUBLE_TRANSFORM + + G_RAND_DOUBLE_TRANSFORM * G_RAND_DOUBLE_TRANSFORM); + + random = (gint32) (double_rand * dist); + } + else + { + /* Now we use g_rand_double_range (), which will set 52 bits for + us, so that it is safe to round and still get a decent + distribution */ + random = (gint32) g_rand_double_range (rand, 0, dist); + } + + return begin + random; +} + +/** + * g_rand_double: + * @rand: a #GRand. + * + * Return the next random #gdouble from @rand equaly distributed over + * the range [0..1). + * + * Return value: A random number. + **/ +gdouble +g_rand_double (GRand* rand) +{ + /* We set all 52 bits after the point for this, not only the first + 32. Thats why we need two calls to g_rand_int */ + gdouble retval = g_rand_int (rand) * G_RAND_DOUBLE_TRANSFORM; + retval = (retval + g_rand_int (rand)) * G_RAND_DOUBLE_TRANSFORM; + + /* The following might happen due to very bad rounding luck, but + * actually this should be more than rare, we just try again then */ + if (retval >= 1.0) + return g_rand_double (rand); + + return retval; +} + +/** + * g_rand_double_range: + * @rand: a #GRand. + * @begin: lower closed bound of the interval. + * @end: upper open bound of the interval. + * + * Return the next random #gdouble from @rand equaly distributed over + * the range [@begin..@end). + * + * Return value: A random number. + **/ +gdouble +g_rand_double_range (GRand* rand, gdouble begin, gdouble end) +{ + return g_rand_double (rand) * (end - begin) + begin; +} + +/** + * g_random_int: + * + * Return a random #guint32 equaly distributed over the range + * [0..2^32-1]. + * + * Return value: A random number. + **/ +guint32 +g_random_int (void) +{ + guint32 result; + G_LOCK (global_random); + if (!global_random) + global_random = g_rand_new (); + + result = g_rand_int (global_random); + G_UNLOCK (global_random); + return result; +} + +/** + * g_random_int_range: + * @begin: lower closed bound of the interval. + * @end: upper open bound of the interval. + * + * Return a random #gint32 equaly distributed over the range + * [@begin..@end-1]. + * + * Return value: A random number. + **/ +gint32 +g_random_int_range (gint32 begin, gint32 end) +{ + gint32 result; + G_LOCK (global_random); + if (!global_random) + global_random = g_rand_new (); + + result = g_rand_int_range (global_random, begin, end); + G_UNLOCK (global_random); + return result; +} + +/** + * g_random_double: + * + * Return a random #gdouble equaly distributed over the range [0..1). + * + * Return value: A random number. + **/ +gdouble +g_random_double (void) +{ + double result; + G_LOCK (global_random); + if (!global_random) + global_random = g_rand_new (); + + result = g_rand_double (global_random); + G_UNLOCK (global_random); + return result; +} + +/** + * g_random_double_range: + * @begin: lower closed bound of the interval. + * @end: upper open bound of the interval. + * + * Return a random #gdouble equaly distributed over the range [@begin..@end). + * + * Return value: A random number. + **/ +gdouble +g_random_double_range (gdouble begin, gdouble end) +{ + double result; + G_LOCK (global_random); + if (!global_random) + global_random = g_rand_new (); + + result = g_rand_double_range (global_random, begin, end); + G_UNLOCK (global_random); + return result; +} + +/** + * g_random_set_seed: + * @seed: a value to reinitialize the global random number generator. + * + * Sets the seed for the global random number generator, which is used + * by te g_random_* functions, to @seed. + **/ +void +g_random_set_seed (guint32 seed) +{ + G_LOCK (global_random); + if (!global_random) + global_random = g_rand_new_with_seed (seed); + else + g_rand_set_seed (global_random, seed); + G_UNLOCK (global_random); +} + diff --git a/graf2d/win32gdk/gdk/src/glib/grand.h b/graf2d/win32gdk/gdk/src/glib/grand.h index 020ca1b7ce638..d743953f94c39 100644 --- a/graf2d/win32gdk/gdk/src/glib/grand.h +++ b/graf2d/win32gdk/gdk/src/glib/grand.h @@ -27,7 +27,7 @@ #ifndef __G_RAND_H__ #define __G_RAND_H__ -#include <g_types.h> +#include <glib/gtypes.h> G_BEGIN_DECLS @@ -49,7 +49,7 @@ void g_rand_free (GRand *rand); void g_rand_set_seed (GRand *rand, guint32 seed); -#define g_rand_boolean(rand) (g_rand_int ((rand)) & (1<<15)) +#define g_rand_boolean(rand) ((g_rand_int (rand) & (1 << 15)) != 0) guint32 g_rand_int (GRand *rand); gint32 g_rand_int_range (GRand *rand, @@ -62,7 +62,7 @@ gdouble g_rand_double_range (GRand *rand, void g_random_set_seed (guint32 seed); -#define g_random_boolean() (g_rand_boolean ((rand))) +#define g_random_boolean() ((g_random_int () & (1 << 15)) != 0) guint32 g_random_int (void); gint32 g_random_int_range (gint32 begin, diff --git a/graf2d/win32gdk/gdk/src/glib/grel.c b/graf2d/win32gdk/gdk/src/glib/grel.c new file mode 100644 index 0000000000000..69cad2c997332 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/grel.c @@ -0,0 +1,449 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free + * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#include "glib.h" +#include <stdarg.h> +#include <string.h> + +typedef struct _GRealTuples GRealTuples; + +struct _GRelation +{ + gint fields; + gint current_field; + + GHashTable *all_tuples; + GHashTable **hashed_tuple_tables; + GMemChunk *tuple_chunk; + + gint count; +}; + +struct _GRealTuples +{ + gint len; + gint width; + gpointer *data; +}; + +static gboolean +tuple_equal_2 (gconstpointer v_a, + gconstpointer v_b) +{ + gpointer* a = (gpointer*) v_a; + gpointer* b = (gpointer*) v_b; + + return a[0] == b[0] && a[1] == b[1]; +} + +static guint +tuple_hash_2 (gconstpointer v_a) +{ + gpointer* a = (gpointer*) v_a; + + return (gulong)a[0] ^ (gulong)a[1]; +} + +static GHashFunc +tuple_hash (gint fields) +{ + switch (fields) + { + case 2: + return tuple_hash_2; + default: + g_error ("no tuple hash for %d", fields); + } + + return NULL; +} + +static GEqualFunc +tuple_equal (gint fields) +{ + switch (fields) + { + case 2: + return tuple_equal_2; + default: + g_error ("no tuple equal for %d", fields); + } + + return NULL; +} + +GRelation* +g_relation_new (gint fields) +{ + GRelation* rel = g_new0 (GRelation, 1); + + rel->fields = fields; + rel->tuple_chunk = g_mem_chunk_new ("Relation Chunk", + fields * sizeof (gpointer), + fields * sizeof (gpointer) * 128, + G_ALLOC_AND_FREE); + rel->all_tuples = g_hash_table_new (tuple_hash (fields), tuple_equal (fields)); + rel->hashed_tuple_tables = g_new0 (GHashTable*, fields); + + return rel; +} + +static void +g_relation_free_array (gpointer key, gpointer value, gpointer user_data) +{ + g_hash_table_destroy ((GHashTable*) value); +} + +void +g_relation_destroy (GRelation *relation) +{ + gint i; + + if (relation) + { + g_hash_table_destroy (relation->all_tuples); + g_mem_chunk_destroy (relation->tuple_chunk); + + for (i = 0; i < relation->fields; i += 1) + { + if (relation->hashed_tuple_tables[i]) + { + g_hash_table_foreach (relation->hashed_tuple_tables[i], g_relation_free_array, NULL); + g_hash_table_destroy (relation->hashed_tuple_tables[i]); + } + } + + g_free (relation->hashed_tuple_tables); + g_free (relation); + } +} + +void +g_relation_index (GRelation *relation, + gint field, + GHashFunc hash_func, + GEqualFunc key_equal_func) +{ + g_return_if_fail (relation != NULL); + + g_return_if_fail (relation->count == 0 && relation->hashed_tuple_tables[field] == NULL); + + relation->hashed_tuple_tables[field] = g_hash_table_new (hash_func, key_equal_func); +} + +void +g_relation_insert (GRelation *relation, + ...) +{ + gpointer* tuple = g_chunk_new (gpointer, relation->tuple_chunk); + va_list args; + gint i; + + va_start(args, relation); + + for (i = 0; i < relation->fields; i += 1) + tuple[i] = va_arg(args, gpointer); + + va_end(args); + + g_hash_table_insert (relation->all_tuples, tuple, tuple); + + relation->count += 1; + + for (i = 0; i < relation->fields; i += 1) + { + GHashTable *table; + gpointer key; + GHashTable *per_key_table; + + table = relation->hashed_tuple_tables[i]; + + if (table == NULL) + continue; + + key = tuple[i]; + per_key_table = g_hash_table_lookup (table, key); + + if (per_key_table == NULL) + { + per_key_table = g_hash_table_new (tuple_hash (relation->fields), tuple_equal (relation->fields)); + g_hash_table_insert (table, key, per_key_table); + } + + g_hash_table_insert (per_key_table, tuple, tuple); + } +} + +static void +g_relation_delete_tuple (gpointer tuple_key, + gpointer tuple_value, + gpointer user_data) +{ + gpointer *tuple = (gpointer*) tuple_value; + GRelation *rel = (GRelation *) user_data; + gint j; + + g_assert (tuple_key == tuple_value); + + for (j = 0; j < rel->fields; j += 1) + { + GHashTable *one_table = rel->hashed_tuple_tables[j]; + gpointer one_key; + GHashTable *per_key_table; + + if (one_table == NULL) + continue; + + if (j == rel->current_field) + /* can't delete from the table we're foreaching in */ + continue; + + one_key = tuple[j]; + + per_key_table = g_hash_table_lookup (one_table, one_key); + + g_hash_table_remove (per_key_table, tuple); + } + + g_hash_table_remove (rel->all_tuples, tuple); + + rel->count -= 1; +} + +gint +g_relation_delete (GRelation *relation, + gconstpointer key, + gint field) +{ + GHashTable *table = relation->hashed_tuple_tables[field]; + GHashTable *key_table; + gint count = relation->count; + + g_return_val_if_fail (relation != NULL, 0); + g_return_val_if_fail (table != NULL, 0); + + key_table = g_hash_table_lookup (table, key); + + if (!key_table) + return 0; + + relation->current_field = field; + + g_hash_table_foreach (key_table, g_relation_delete_tuple, relation); + + g_hash_table_remove (table, key); + + g_hash_table_destroy (key_table); + + /* @@@ FIXME: Remove empty hash tables. */ + + return count - relation->count; +} + +static void +g_relation_select_tuple (gpointer tuple_key, + gpointer tuple_value, + gpointer user_data) +{ + gpointer *tuple = (gpointer*) tuple_value; + GRealTuples *tuples = (GRealTuples*) user_data; + gint stride = sizeof (gpointer) * tuples->width; + + g_assert (tuple_key == tuple_value); + + memcpy (tuples->data + (tuples->len * tuples->width), + tuple, + stride); + + tuples->len += 1; +} + +GTuples* +g_relation_select (GRelation *relation, + gconstpointer key, + gint field) +{ + GHashTable *table = relation->hashed_tuple_tables[field]; + GHashTable *key_table; + GRealTuples *tuples = g_new0 (GRealTuples, 1); + gint count; + + g_return_val_if_fail (relation != NULL, NULL); + g_return_val_if_fail (table != NULL, NULL); + + key_table = g_hash_table_lookup (table, key); + + if (!key_table) + return (GTuples*)tuples; + + count = g_relation_count (relation, key, field); + + tuples->data = g_malloc (sizeof (gpointer) * relation->fields * count); + tuples->width = relation->fields; + + g_hash_table_foreach (key_table, g_relation_select_tuple, tuples); + + g_assert (count == tuples->len); + + return (GTuples*)tuples; +} + +gint +g_relation_count (GRelation *relation, + gconstpointer key, + gint field) +{ + GHashTable *table = relation->hashed_tuple_tables[field]; + GHashTable *key_table; + + g_return_val_if_fail (relation != NULL, 0); + g_return_val_if_fail (table != NULL, 0); + + key_table = g_hash_table_lookup (table, key); + + if (!key_table) + return 0; + + return g_hash_table_size (key_table); +} + +gboolean +g_relation_exists (GRelation *relation, ...) +{ + gpointer* tuple = g_chunk_new (gpointer, relation->tuple_chunk); + va_list args; + gint i; + gboolean result; + + va_start(args, relation); + + for (i = 0; i < relation->fields; i += 1) + tuple[i] = va_arg(args, gpointer); + + va_end(args); + + result = g_hash_table_lookup (relation->all_tuples, tuple) != NULL; + + g_mem_chunk_free (relation->tuple_chunk, tuple); + + return result; +} + +void +g_tuples_destroy (GTuples *tuples0) +{ + GRealTuples *tuples = (GRealTuples*) tuples0; + + if (tuples) + { + g_free (tuples->data); + g_free (tuples); + } +} + +gpointer +g_tuples_index (GTuples *tuples0, + gint index, + gint field) +{ + GRealTuples *tuples = (GRealTuples*) tuples0; + + g_return_val_if_fail (tuples0 != NULL, NULL); + g_return_val_if_fail (field < tuples->width, NULL); + + return tuples->data[index * tuples->width + field]; +} + +/* Print + */ + +static void +g_relation_print_one (gpointer tuple_key, + gpointer tuple_value, + gpointer user_data) +{ + gint i; + GString *gstring; + GRelation* rel = (GRelation*) user_data; + gpointer* tuples = (gpointer*) tuple_value; + + gstring = g_string_new ("["); + + for (i = 0; i < rel->fields; i += 1) + { + g_string_printfa (gstring, "%p", tuples[i]); + + if (i < (rel->fields - 1)) + g_string_append (gstring, ","); + } + + g_string_append (gstring, "]"); + g_log (g_log_domain_glib, G_LOG_LEVEL_INFO, gstring->str); + g_string_free (gstring, TRUE); +} + +static void +g_relation_print_index (gpointer tuple_key, + gpointer tuple_value, + gpointer user_data) +{ + GRelation* rel = (GRelation*) user_data; + GHashTable* table = (GHashTable*) tuple_value; + + g_log (g_log_domain_glib, G_LOG_LEVEL_INFO, "*** key %p", tuple_key); + + g_hash_table_foreach (table, + g_relation_print_one, + rel); +} + +void +g_relation_print (GRelation *relation) +{ + gint i; + + g_log (g_log_domain_glib, G_LOG_LEVEL_INFO, "*** all tuples (%d)", relation->count); + + g_hash_table_foreach (relation->all_tuples, + g_relation_print_one, + relation); + + for (i = 0; i < relation->fields; i += 1) + { + if (relation->hashed_tuple_tables[i] == NULL) + continue; + + g_log (g_log_domain_glib, G_LOG_LEVEL_INFO, "*** index %d", i); + + g_hash_table_foreach (relation->hashed_tuple_tables[i], + g_relation_print_index, + relation); + } + +} diff --git a/graf2d/win32gdk/gdk/src/glib/grel.h b/graf2d/win32gdk/gdk/src/glib/grel.h index 5d92b43930c44..562bd13601750 100644 --- a/graf2d/win32gdk/gdk/src/glib/grel.h +++ b/graf2d/win32gdk/gdk/src/glib/grel.h @@ -27,7 +27,7 @@ #ifndef __G_REL_H__ #define __G_REL_H__ -#include <g_types.h> +#include <glib/gtypes.h> G_BEGIN_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gscanner.c b/graf2d/win32gdk/gdk/src/glib/gscanner.c new file mode 100644 index 0000000000000..dd95b71a96ff2 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gscanner.c @@ -0,0 +1,1707 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * GScanner: Flexible lexical scanner for general purpose. + * Copyright (C) 1997, 1998 Tim Janik + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include <stdarg.h> +#include <string.h> +#include <stdio.h> +#include "glib.h" +#ifdef HAVE_UNISTD_H +#include <unistd.h> +#endif +#include <errno.h> +#ifdef G_OS_WIN32 +#include <io.h> /* For _read() */ +#endif + +/* --- defines --- */ +#define to_lower(c) ( \ + (guchar) ( \ + ( (((guchar)(c))>='A' && ((guchar)(c))<='Z') * ('a'-'A') ) | \ + ( (((guchar)(c))>=192 && ((guchar)(c))<=214) * (224-192) ) | \ + ( (((guchar)(c))>=216 && ((guchar)(c))<=222) * (248-216) ) | \ + ((guchar)(c)) \ + ) \ +) +#define READ_BUFFER_SIZE (4000) + + +/* --- typedefs --- */ +typedef struct _GScannerKey GScannerKey; + +struct _GScannerKey +{ + guint scope_id; + gchar *symbol; + gpointer value; +}; + + + +/* --- variables --- */ +static GScannerConfig g_scanner_config_template = +{ + ( + " \t\r\n" + ) /* cset_skip_characters */, + ( + G_CSET_a_2_z + "_" + G_CSET_A_2_Z + ) /* cset_identifier_first */, + ( + G_CSET_a_2_z + "_" + G_CSET_A_2_Z + G_CSET_DIGITS + G_CSET_LATINS + G_CSET_LATINC + ) /* cset_identifier_nth */, + ( "#\n" ) /* cpair_comment_single */, + + FALSE /* case_sensitive */, + + TRUE /* skip_comment_multi */, + TRUE /* skip_comment_single */, + TRUE /* scan_comment_multi */, + TRUE /* scan_identifier */, + FALSE /* scan_identifier_1char */, + FALSE /* scan_identifier_NULL */, + TRUE /* scan_symbols */, + FALSE /* scan_binary */, + TRUE /* scan_octal */, + TRUE /* scan_float */, + TRUE /* scan_hex */, + FALSE /* scan_hex_dollar */, + TRUE /* scan_string_sq */, + TRUE /* scan_string_dq */, + TRUE /* numbers_2_int */, + FALSE /* int_2_float */, + FALSE /* identifier_2_string */, + TRUE /* char_2_token */, + FALSE /* symbol_2_token */, + FALSE /* scope_0_fallback */, +}; + + +/* --- prototypes --- */ +static inline +GScannerKey* g_scanner_lookup_internal (GScanner *scanner, + guint scope_id, + const gchar *symbol); +static gboolean g_scanner_key_equal (gconstpointer v1, + gconstpointer v2); +static guint g_scanner_key_hash (gconstpointer v); +static void g_scanner_get_token_ll (GScanner *scanner, + GTokenType *token_p, + GTokenValue *value_p, + guint *line_p, + guint *position_p); +static void g_scanner_get_token_i (GScanner *scanner, + GTokenType *token_p, + GTokenValue *value_p, + guint *line_p, + guint *position_p); + +static guchar g_scanner_peek_next_char (GScanner *scanner); +static guchar g_scanner_get_char (GScanner *scanner, + guint *line_p, + guint *position_p); +static void g_scanner_msg_handler (GScanner *scanner, + gchar *message, + gint is_error); + + +/* --- functions --- */ +static inline gint +g_scanner_char_2_num (guchar c, + guchar base) +{ + if (c >= '0' && c <= '9') + c -= '0'; + else if (c >= 'A' && c <= 'Z') + c -= 'A' - 10; + else if (c >= 'a' && c <= 'z') + c -= 'a' - 10; + else + return -1; + + if (c < base) + return c; + + return -1; +} + +GScanner* +g_scanner_new (const GScannerConfig *config_templ) +{ + GScanner *scanner; + + if (!config_templ) + config_templ = &g_scanner_config_template; + + scanner = g_new0 (GScanner, 1); + + scanner->user_data = NULL; + scanner->max_parse_errors = 0; + scanner->parse_errors = 0; + scanner->input_name = NULL; + g_datalist_init (&scanner->qdata); + + scanner->config = g_new0 (GScannerConfig, 1); + + scanner->config->case_sensitive = config_templ->case_sensitive; + scanner->config->cset_skip_characters = config_templ->cset_skip_characters; + if (!scanner->config->cset_skip_characters) + scanner->config->cset_skip_characters = ""; + scanner->config->cset_identifier_first = config_templ->cset_identifier_first; + scanner->config->cset_identifier_nth = config_templ->cset_identifier_nth; + scanner->config->cpair_comment_single = config_templ->cpair_comment_single; + scanner->config->skip_comment_multi = config_templ->skip_comment_multi; + scanner->config->skip_comment_single = config_templ->skip_comment_single; + scanner->config->scan_comment_multi = config_templ->scan_comment_multi; + scanner->config->scan_identifier = config_templ->scan_identifier; + scanner->config->scan_identifier_1char = config_templ->scan_identifier_1char; + scanner->config->scan_identifier_NULL = config_templ->scan_identifier_NULL; + scanner->config->scan_symbols = config_templ->scan_symbols; + scanner->config->scan_binary = config_templ->scan_binary; + scanner->config->scan_octal = config_templ->scan_octal; + scanner->config->scan_float = config_templ->scan_float; + scanner->config->scan_hex = config_templ->scan_hex; + scanner->config->scan_hex_dollar = config_templ->scan_hex_dollar; + scanner->config->scan_string_sq = config_templ->scan_string_sq; + scanner->config->scan_string_dq = config_templ->scan_string_dq; + scanner->config->numbers_2_int = config_templ->numbers_2_int; + scanner->config->int_2_float = config_templ->int_2_float; + scanner->config->identifier_2_string = config_templ->identifier_2_string; + scanner->config->char_2_token = config_templ->char_2_token; + scanner->config->symbol_2_token = config_templ->symbol_2_token; + scanner->config->scope_0_fallback = config_templ->scope_0_fallback; + + scanner->token = G_TOKEN_NONE; + scanner->value.v_int = 0; + scanner->line = 1; + scanner->position = 0; + + scanner->next_token = G_TOKEN_NONE; + scanner->next_value.v_int = 0; + scanner->next_line = 1; + scanner->next_position = 0; + + scanner->symbol_table = g_hash_table_new (g_scanner_key_hash, g_scanner_key_equal); + scanner->input_fd = -1; + scanner->text = NULL; + scanner->text_end = NULL; + scanner->buffer = NULL; + scanner->scope_id = 0; + + scanner->msg_handler = g_scanner_msg_handler; + + return scanner; +} + +static inline void +g_scanner_free_value (GTokenType *token_p, + GTokenValue *value_p) +{ + switch (*token_p) + { + case G_TOKEN_STRING: + case G_TOKEN_IDENTIFIER: + case G_TOKEN_IDENTIFIER_NULL: + case G_TOKEN_COMMENT_SINGLE: + case G_TOKEN_COMMENT_MULTI: + g_free (value_p->v_string); + break; + + default: + break; + } + + *token_p = G_TOKEN_NONE; +} + +static void +g_scanner_destroy_symbol_table_entry (gpointer _key, + gpointer _value, + gpointer _data) +{ + GScannerKey *key = _key; + + g_free (key->symbol); + g_free (key); +} + +void +g_scanner_destroy (GScanner *scanner) +{ + g_return_if_fail (scanner != NULL); + + g_datalist_clear (&scanner->qdata); + g_hash_table_foreach (scanner->symbol_table, + g_scanner_destroy_symbol_table_entry, NULL); + g_hash_table_destroy (scanner->symbol_table); + g_scanner_free_value (&scanner->token, &scanner->value); + g_scanner_free_value (&scanner->next_token, &scanner->next_value); + g_free (scanner->config); + g_free (scanner->buffer); + g_free (scanner); +} + +static void +g_scanner_msg_handler (GScanner *scanner, + gchar *message, + gint is_error) +{ + g_return_if_fail (scanner != NULL); + + fprintf (stderr, "%s:%d: ", scanner->input_name, scanner->line); + if (is_error) + fprintf (stderr, "error: "); + fprintf (stderr, "%s\n", message); +} + +void +g_scanner_error (GScanner *scanner, + const gchar *format, + ...) +{ + g_return_if_fail (scanner != NULL); + g_return_if_fail (format != NULL); + + scanner->parse_errors++; + + if (scanner->msg_handler) + { + va_list args; + gchar *string; + + va_start (args, format); + string = g_strdup_vprintf (format, args); + va_end (args); + + scanner->msg_handler (scanner, string, TRUE); + + g_free (string); + } +} + +void +g_scanner_warn (GScanner *scanner, + const gchar *format, + ...) +{ + g_return_if_fail (scanner != NULL); + g_return_if_fail (format != NULL); + + if (scanner->msg_handler) + { + va_list args; + gchar *string; + + va_start (args, format); + string = g_strdup_vprintf (format, args); + va_end (args); + + scanner->msg_handler (scanner, string, FALSE); + + g_free (string); + } +} + +static gboolean +g_scanner_key_equal (gconstpointer v1, + gconstpointer v2) +{ + const GScannerKey *key1 = v1; + const GScannerKey *key2 = v2; + + return (key1->scope_id == key2->scope_id) && (strcmp (key1->symbol, key2->symbol) == 0); +} + +static guint +g_scanner_key_hash (gconstpointer v) +{ + const GScannerKey *key = v; + gchar *c; + guint h; + + h = key->scope_id; + for (c = key->symbol; *c; c++) + h = (h << 5) - h + *c; + + return h; +} + +static inline GScannerKey* +g_scanner_lookup_internal (GScanner *scanner, + guint scope_id, + const gchar *symbol) +{ + GScannerKey *key_p; + GScannerKey key; + + key.scope_id = scope_id; + + if (!scanner->config->case_sensitive) + { + gchar *d; + const gchar *c; + + key.symbol = g_new (gchar, strlen (symbol) + 1); + for (d = key.symbol, c = symbol; *c; c++, d++) + *d = to_lower (*c); + *d = 0; + key_p = g_hash_table_lookup (scanner->symbol_table, &key); + g_free (key.symbol); + } + else + { + key.symbol = (gchar*) symbol; + key_p = g_hash_table_lookup (scanner->symbol_table, &key); + } + + return key_p; +} + +void +g_scanner_scope_add_symbol (GScanner *scanner, + guint scope_id, + const gchar *symbol, + gpointer value) +{ + GScannerKey *key; + + g_return_if_fail (scanner != NULL); + g_return_if_fail (symbol != NULL); + + key = g_scanner_lookup_internal (scanner, scope_id, symbol); + + if (!key) + { + key = g_new (GScannerKey, 1); + key->scope_id = scope_id; + key->symbol = g_strdup (symbol); + key->value = value; + if (!scanner->config->case_sensitive) + { + gchar *c; + + c = key->symbol; + while (*c != 0) + { + *c = to_lower (*c); + c++; + } + } + g_hash_table_insert (scanner->symbol_table, key, key); + } + else + key->value = value; +} + +void +g_scanner_scope_remove_symbol (GScanner *scanner, + guint scope_id, + const gchar *symbol) +{ + GScannerKey *key; + + g_return_if_fail (scanner != NULL); + g_return_if_fail (symbol != NULL); + + key = g_scanner_lookup_internal (scanner, scope_id, symbol); + + if (key) + { + g_hash_table_remove (scanner->symbol_table, key); + g_free (key->symbol); + g_free (key); + } +} + +gpointer +g_scanner_lookup_symbol (GScanner *scanner, + const gchar *symbol) +{ + GScannerKey *key; + guint scope_id; + + g_return_val_if_fail (scanner != NULL, NULL); + + if (!symbol) + return NULL; + + scope_id = scanner->scope_id; + key = g_scanner_lookup_internal (scanner, scope_id, symbol); + if (!key && scope_id && scanner->config->scope_0_fallback) + key = g_scanner_lookup_internal (scanner, 0, symbol); + + if (key) + return key->value; + else + return NULL; +} + +gpointer +g_scanner_scope_lookup_symbol (GScanner *scanner, + guint scope_id, + const gchar *symbol) +{ + GScannerKey *key; + + g_return_val_if_fail (scanner != NULL, NULL); + + if (!symbol) + return NULL; + + key = g_scanner_lookup_internal (scanner, scope_id, symbol); + + if (key) + return key->value; + else + return NULL; +} + +guint +g_scanner_set_scope (GScanner *scanner, + guint scope_id) +{ + guint old_scope_id; + + g_return_val_if_fail (scanner != NULL, 0); + + old_scope_id = scanner->scope_id; + scanner->scope_id = scope_id; + + return old_scope_id; +} + +static void +g_scanner_foreach_internal (gpointer _key, + gpointer _value, + gpointer _user_data) +{ + GScannerKey *key; + gpointer *d; + GHFunc func; + gpointer user_data; + guint *scope_id; + + d = _user_data; + func = (GHFunc) d[0]; + user_data = d[1]; + scope_id = d[2]; + key = _value; + + if (key->scope_id == *scope_id) + func (key->symbol, key->value, user_data); +} + +void +g_scanner_scope_foreach_symbol (GScanner *scanner, + guint scope_id, + GHFunc func, + gpointer user_data) +{ + gpointer d[3]; + + g_return_if_fail (scanner != NULL); + + d[0] = (gpointer) func; + d[1] = user_data; + d[2] = &scope_id; + + g_hash_table_foreach (scanner->symbol_table, g_scanner_foreach_internal, d); +} + +GTokenType +g_scanner_peek_next_token (GScanner *scanner) +{ + g_return_val_if_fail (scanner != NULL, G_TOKEN_EOF); + + if (scanner->next_token == G_TOKEN_NONE) + { + scanner->next_line = scanner->line; + scanner->next_position = scanner->position; + g_scanner_get_token_i (scanner, + &scanner->next_token, + &scanner->next_value, + &scanner->next_line, + &scanner->next_position); + } + + return scanner->next_token; +} + +GTokenType +g_scanner_get_next_token (GScanner *scanner) +{ + g_return_val_if_fail (scanner != NULL, G_TOKEN_EOF); + + if (scanner->next_token != G_TOKEN_NONE) + { + g_scanner_free_value (&scanner->token, &scanner->value); + + scanner->token = scanner->next_token; + scanner->value = scanner->next_value; + scanner->line = scanner->next_line; + scanner->position = scanner->next_position; + scanner->next_token = G_TOKEN_NONE; + } + else + g_scanner_get_token_i (scanner, + &scanner->token, + &scanner->value, + &scanner->line, + &scanner->position); + + return scanner->token; +} + +GTokenType +g_scanner_cur_token (GScanner *scanner) +{ + g_return_val_if_fail (scanner != NULL, G_TOKEN_EOF); + + return scanner->token; +} + +GTokenValue +g_scanner_cur_value (GScanner *scanner) +{ + GTokenValue v; + + v.v_int = 0; + + g_return_val_if_fail (scanner != NULL, v); + + /* MSC isn't capable of handling return scanner->value; ? */ + + v = scanner->value; + + return v; +} + +guint +g_scanner_cur_line (GScanner *scanner) +{ + g_return_val_if_fail (scanner != NULL, 0); + + return scanner->line; +} + +guint +g_scanner_cur_position (GScanner *scanner) +{ + g_return_val_if_fail (scanner != NULL, 0); + + return scanner->position; +} + +gboolean +g_scanner_eof (GScanner *scanner) +{ + g_return_val_if_fail (scanner != NULL, TRUE); + + return scanner->token == G_TOKEN_EOF; +} + +void +g_scanner_input_file (GScanner *scanner, + gint input_fd) +{ + g_return_if_fail (scanner != NULL); + g_return_if_fail (input_fd >= 0); + + if (scanner->input_fd >= 0) + g_scanner_sync_file_offset (scanner); + + scanner->token = G_TOKEN_NONE; + scanner->value.v_int = 0; + scanner->line = 1; + scanner->position = 0; + scanner->next_token = G_TOKEN_NONE; + + scanner->input_fd = input_fd; + scanner->text = NULL; + scanner->text_end = NULL; + + if (!scanner->buffer) + scanner->buffer = g_new (gchar, READ_BUFFER_SIZE + 1); +} + +void +g_scanner_input_text (GScanner *scanner, + const gchar *text, + guint text_len) +{ + g_return_if_fail (scanner != NULL); + if (text_len) + g_return_if_fail (text != NULL); + else + text = NULL; + + if (scanner->input_fd >= 0) + g_scanner_sync_file_offset (scanner); + + scanner->token = G_TOKEN_NONE; + scanner->value.v_int = 0; + scanner->line = 1; + scanner->position = 0; + scanner->next_token = G_TOKEN_NONE; + + scanner->input_fd = -1; + scanner->text = text; + scanner->text_end = text + text_len; + + if (scanner->buffer) + { + g_free (scanner->buffer); + scanner->buffer = NULL; + } +} + +static guchar +g_scanner_peek_next_char (GScanner *scanner) +{ + if (scanner->text < scanner->text_end) + { + return *scanner->text; + } + else if (scanner->input_fd >= 0) + { + gint count; + gchar *buffer; + + buffer = scanner->buffer; + do + { + count = read (scanner->input_fd, buffer, READ_BUFFER_SIZE); + } + while (count == -1 && (errno == EINTR || errno == EAGAIN)); + + if (count < 1) + { + scanner->input_fd = -1; + + return 0; + } + else + { + scanner->text = buffer; + scanner->text_end = buffer + count; + + return *buffer; + } + } + else + return 0; +} + +void +g_scanner_sync_file_offset (GScanner *scanner) +{ + g_return_if_fail (scanner != NULL); + + /* for file input, rewind the filedescriptor to the current + * buffer position and blow the file read ahead buffer. usefull for + * third party uses of our filedescriptor, which hooks onto the current + * scanning position. + */ + + if (scanner->input_fd >= 0 && scanner->text_end > scanner->text) + { + gint buffered; + + buffered = scanner->text_end - scanner->text; + if (lseek (scanner->input_fd, - buffered, SEEK_CUR) >= 0) + { + /* we succeeded, blow our buffer's contents now */ + scanner->text = NULL; + scanner->text_end = NULL; + } + else + errno = 0; + } +} + +static guchar +g_scanner_get_char (GScanner *scanner, + guint *line_p, + guint *position_p) +{ + guchar fchar; + + if (scanner->text < scanner->text_end) + fchar = *(scanner->text++); + else if (scanner->input_fd >= 0) + { + gint count; + gchar *buffer; + + buffer = scanner->buffer; + do + { + count = read (scanner->input_fd, buffer, READ_BUFFER_SIZE); + } + while (count == -1 && (errno == EINTR || errno == EAGAIN)); + + if (count < 1) + { + scanner->input_fd = -1; + fchar = 0; + } + else + { + scanner->text = buffer + 1; + scanner->text_end = buffer + count; + fchar = *buffer; + if (!fchar) + { + g_scanner_sync_file_offset (scanner); + scanner->text_end = scanner->text; + scanner->input_fd = -1; + } + } + } + else + fchar = 0; + + if (fchar == '\n') + { + (*position_p) = 0; + (*line_p)++; + } + else if (fchar) + { + (*position_p)++; + } + + return fchar; +} + +void +g_scanner_unexp_token (GScanner *scanner, + GTokenType expected_token, + const gchar *identifier_spec, + const gchar *symbol_spec, + const gchar *symbol_name, + const gchar *message, + gint is_error) +{ + gchar *token_string; + guint token_string_len; + gchar *expected_string; + guint expected_string_len; + gchar *message_prefix; + gboolean print_unexp; + void (*msg_handler) (GScanner*, const gchar*, ...); + + g_return_if_fail (scanner != NULL); + + if (is_error) + msg_handler = g_scanner_error; + else + msg_handler = g_scanner_warn; + + if (!identifier_spec) + identifier_spec = "identifier"; + if (!symbol_spec) + symbol_spec = "symbol"; + + token_string_len = 56; + token_string = g_new (gchar, token_string_len + 1); + expected_string_len = 64; + expected_string = g_new (gchar, expected_string_len + 1); + print_unexp = TRUE; + + switch (scanner->token) + { + case G_TOKEN_EOF: + g_snprintf (token_string, token_string_len, "end of file"); + break; + + default: + if (scanner->token >= 1 && scanner->token <= 255) + { + if ((scanner->token >= ' ' && scanner->token <= '~') || + strchr (scanner->config->cset_identifier_first, scanner->token) || + strchr (scanner->config->cset_identifier_nth, scanner->token)) + g_snprintf (token_string, expected_string_len, "character `%c'", scanner->token); + else + g_snprintf (token_string, expected_string_len, "character `\\%o'", scanner->token); + break; + } + else if (!scanner->config->symbol_2_token) + { + g_snprintf (token_string, token_string_len, "(unknown) token <%d>", scanner->token); + break; + } + /* fall through */ + case G_TOKEN_SYMBOL: + if (expected_token == G_TOKEN_SYMBOL || + (scanner->config->symbol_2_token && + expected_token > G_TOKEN_LAST)) + print_unexp = FALSE; + if (symbol_name) + g_snprintf (token_string, + token_string_len, + "%s%s `%s'", + print_unexp ? "" : "invalid ", + symbol_spec, + symbol_name); + else + g_snprintf (token_string, + token_string_len, + "%s%s", + print_unexp ? "" : "invalid ", + symbol_spec); + break; + + case G_TOKEN_ERROR: + print_unexp = FALSE; + expected_token = G_TOKEN_NONE; + switch (scanner->value.v_error) + { + case G_ERR_UNEXP_EOF: + g_snprintf (token_string, token_string_len, "scanner: unexpected end of file"); + break; + + case G_ERR_UNEXP_EOF_IN_STRING: + g_snprintf (token_string, token_string_len, "scanner: unterminated string constant"); + break; + + case G_ERR_UNEXP_EOF_IN_COMMENT: + g_snprintf (token_string, token_string_len, "scanner: unterminated comment"); + break; + + case G_ERR_NON_DIGIT_IN_CONST: + g_snprintf (token_string, token_string_len, "scanner: non digit in constant"); + break; + + case G_ERR_FLOAT_RADIX: + g_snprintf (token_string, token_string_len, "scanner: invalid radix for floating constant"); + break; + + case G_ERR_FLOAT_MALFORMED: + g_snprintf (token_string, token_string_len, "scanner: malformed floating constant"); + break; + + case G_ERR_DIGIT_RADIX: + g_snprintf (token_string, token_string_len, "scanner: digit is beyond radix"); + break; + + case G_ERR_UNKNOWN: + default: + g_snprintf (token_string, token_string_len, "scanner: unknown error"); + break; + } + break; + + case G_TOKEN_CHAR: + g_snprintf (token_string, token_string_len, "character `%c'", scanner->value.v_char); + break; + + case G_TOKEN_IDENTIFIER: + case G_TOKEN_IDENTIFIER_NULL: + if (expected_token == G_TOKEN_IDENTIFIER || + expected_token == G_TOKEN_IDENTIFIER_NULL) + print_unexp = FALSE; + g_snprintf (token_string, + token_string_len, + "%s%s `%s'", + print_unexp ? "" : "invalid ", + identifier_spec, + scanner->token == G_TOKEN_IDENTIFIER ? scanner->value.v_string : "null"); + break; + + case G_TOKEN_BINARY: + case G_TOKEN_OCTAL: + case G_TOKEN_INT: + case G_TOKEN_HEX: + g_snprintf (token_string, token_string_len, "number `%ld'", scanner->value.v_int); + break; + + case G_TOKEN_FLOAT: + g_snprintf (token_string, token_string_len, "number `%.3f'", scanner->value.v_float); + break; + + case G_TOKEN_STRING: + if (expected_token == G_TOKEN_STRING) + print_unexp = FALSE; + g_snprintf (token_string, + token_string_len, + "%s%sstring constant \"%s\"", + print_unexp ? "" : "invalid ", + scanner->value.v_string[0] == 0 ? "empty " : "", + scanner->value.v_string); + token_string[token_string_len - 2] = '"'; + token_string[token_string_len - 1] = 0; + break; + + case G_TOKEN_COMMENT_SINGLE: + case G_TOKEN_COMMENT_MULTI: + g_snprintf (token_string, token_string_len, "comment"); + break; + + case G_TOKEN_NONE: + /* somehow the user's parsing code is screwed, there isn't much + * we can do about it. + * Note, a common case to trigger this is + * g_scanner_peek_next_token(); g_scanner_unexp_token(); + * without an intermediate g_scanner_get_next_token(). + */ + g_assert_not_reached (); + break; + } + + + switch (expected_token) + { + gboolean need_valid; + + default: + if (expected_token >= 1 && expected_token <= 255) + { + if ((expected_token >= ' ' && expected_token <= '~') || + strchr (scanner->config->cset_identifier_first, expected_token) || + strchr (scanner->config->cset_identifier_nth, expected_token)) + g_snprintf (expected_string, expected_string_len, "character `%c'", expected_token); + else + g_snprintf (expected_string, expected_string_len, "character `\\%o'", expected_token); + break; + } + else if (!scanner->config->symbol_2_token) + { + g_snprintf (expected_string, expected_string_len, "(unknown) token <%d>", expected_token); + break; + } + /* fall through */ + case G_TOKEN_SYMBOL: + need_valid = (scanner->token == G_TOKEN_SYMBOL || + (scanner->config->symbol_2_token && + scanner->token > G_TOKEN_LAST)); + g_snprintf (expected_string, + expected_string_len, + "%s%s", + need_valid ? "valid " : "", + symbol_spec); + /* FIXME: should we attempt to lookup the symbol_name for symbol_2_token? */ + break; + + case G_TOKEN_INT: + g_snprintf (expected_string, expected_string_len, "%snumber (integer)", + scanner->token == G_TOKEN_INT ? "valid " : ""); + break; + + case G_TOKEN_FLOAT: + g_snprintf (expected_string, expected_string_len, "%snumber (float)", + scanner->token == G_TOKEN_FLOAT ? "valid " : ""); + break; + + case G_TOKEN_STRING: + g_snprintf (expected_string, + expected_string_len, + "%sstring constant", + scanner->token == G_TOKEN_STRING ? "valid " : ""); + break; + + case G_TOKEN_IDENTIFIER: + case G_TOKEN_IDENTIFIER_NULL: + g_snprintf (expected_string, + expected_string_len, + "%s%s", + (scanner->token == G_TOKEN_IDENTIFIER_NULL || + scanner->token == G_TOKEN_IDENTIFIER ? "valid " : ""), + identifier_spec); + break; + + case G_TOKEN_EOF: + g_snprintf (expected_string, expected_string_len, "end of file"); + break; + + case G_TOKEN_NONE: + break; + } + + if (message && message[0] != 0) + message_prefix = " - "; + else + { + message_prefix = ""; + message = ""; + } + + if (expected_token != G_TOKEN_NONE) + { + if (print_unexp) + msg_handler (scanner, + "unexpected %s, expected %s%s%s", + token_string, + expected_string, + message_prefix, + message); + else + msg_handler (scanner, + "%s, expected %s%s%s", + token_string, + expected_string, + message_prefix, + message); + } + else + { + if (print_unexp) + msg_handler (scanner, + "unexpected %s%s%s", + token_string, + message_prefix, + message); + else + msg_handler (scanner, + "%s%s%s", + token_string, + message_prefix, + message); + } + + g_free (token_string); + g_free (expected_string); +} + +static void +g_scanner_get_token_i (GScanner *scanner, + GTokenType *token_p, + GTokenValue *value_p, + guint *line_p, + guint *position_p) +{ + do + { + g_scanner_free_value (token_p, value_p); + g_scanner_get_token_ll (scanner, token_p, value_p, line_p, position_p); + } + while (((*token_p > 0 && *token_p < 256) && + strchr (scanner->config->cset_skip_characters, *token_p)) || + (*token_p == G_TOKEN_CHAR && + strchr (scanner->config->cset_skip_characters, value_p->v_char)) || + (*token_p == G_TOKEN_COMMENT_MULTI && + scanner->config->skip_comment_multi) || + (*token_p == G_TOKEN_COMMENT_SINGLE && + scanner->config->skip_comment_single)); + + switch (*token_p) + { + case G_TOKEN_IDENTIFIER: + if (scanner->config->identifier_2_string) + *token_p = G_TOKEN_STRING; + break; + + case G_TOKEN_SYMBOL: + if (scanner->config->symbol_2_token) + *token_p = (GTokenType) value_p->v_symbol; + break; + + case G_TOKEN_BINARY: + case G_TOKEN_OCTAL: + case G_TOKEN_HEX: + if (scanner->config->numbers_2_int) + *token_p = G_TOKEN_INT; + break; + + default: + break; + } + + if (*token_p == G_TOKEN_INT && + scanner->config->int_2_float) + { + *token_p = G_TOKEN_FLOAT; + value_p->v_float = value_p->v_int; + } + + errno = 0; +} + +static void +g_scanner_get_token_ll (GScanner *scanner, + GTokenType *token_p, + GTokenValue *value_p, + guint *line_p, + guint *position_p) +{ + GScannerConfig *config; + GTokenType token; + gboolean in_comment_multi; + gboolean in_comment_single; + gboolean in_string_sq; + gboolean in_string_dq; + GString *gstring; + GTokenValue value; + guchar ch; + + config = scanner->config; + (*value_p).v_int = 0; + + if ((scanner->text >= scanner->text_end && scanner->input_fd < 0) || + scanner->token == G_TOKEN_EOF) + { + *token_p = G_TOKEN_EOF; + return; + } + + in_comment_multi = FALSE; + in_comment_single = FALSE; + in_string_sq = FALSE; + in_string_dq = FALSE; + gstring = NULL; + + do /* while (ch != 0) */ + { + gboolean dotted_float = FALSE; + + ch = g_scanner_get_char (scanner, line_p, position_p); + + value.v_int = 0; + token = G_TOKEN_NONE; + + /* this is *evil*, but needed ;( + * we first check for identifier first character, because it + * might interfere with other key chars like slashes or numbers + */ + if (config->scan_identifier && + ch && strchr (config->cset_identifier_first, ch)) + goto identifier_precedence; + + switch (ch) + { + case 0: + token = G_TOKEN_EOF; + (*position_p)++; + /* ch = 0; */ + break; + + case '/': + if (!config->scan_comment_multi || + g_scanner_peek_next_char (scanner) != '*') + goto default_case; + g_scanner_get_char (scanner, line_p, position_p); + token = G_TOKEN_COMMENT_MULTI; + in_comment_multi = TRUE; + gstring = g_string_new (""); + while ((ch = g_scanner_get_char (scanner, line_p, position_p)) != 0) + { + if (ch == '*' && g_scanner_peek_next_char (scanner) == '/') + { + g_scanner_get_char (scanner, line_p, position_p); + in_comment_multi = FALSE; + break; + } + else + gstring = g_string_append_c (gstring, ch); + } + ch = 0; + break; + + case '\'': + if (!config->scan_string_sq) + goto default_case; + token = G_TOKEN_STRING; + in_string_sq = TRUE; + gstring = g_string_new (""); + while ((ch = g_scanner_get_char (scanner, line_p, position_p)) != 0) + { + if (ch == '\'') + { + in_string_sq = FALSE; + break; + } + else + gstring = g_string_append_c (gstring, ch); + } + ch = 0; + break; + + case '"': + if (!config->scan_string_dq) + goto default_case; + token = G_TOKEN_STRING; + in_string_dq = TRUE; + gstring = g_string_new (""); + while ((ch = g_scanner_get_char (scanner, line_p, position_p)) != 0) + { + if (ch == '"') + { + in_string_dq = FALSE; + break; + } + else + { + if (ch == '\\') + { + ch = g_scanner_get_char (scanner, line_p, position_p); + switch (ch) + { + guint i; + guint fchar; + + case 0: + break; + + case '\\': + gstring = g_string_append_c (gstring, '\\'); + break; + + case 'n': + gstring = g_string_append_c (gstring, '\n'); + break; + + case 't': + gstring = g_string_append_c (gstring, '\t'); + break; + + case 'r': + gstring = g_string_append_c (gstring, '\r'); + break; + + case 'b': + gstring = g_string_append_c (gstring, '\b'); + break; + + case 'f': + gstring = g_string_append_c (gstring, '\f'); + break; + + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + i = ch - '0'; + fchar = g_scanner_peek_next_char (scanner); + if (fchar >= '0' && fchar <= '7') + { + ch = g_scanner_get_char (scanner, line_p, position_p); + i = i * 8 + ch - '0'; + fchar = g_scanner_peek_next_char (scanner); + if (fchar >= '0' && fchar <= '7') + { + ch = g_scanner_get_char (scanner, line_p, position_p); + i = i * 8 + ch - '0'; + } + } + gstring = g_string_append_c (gstring, i); + break; + + default: + gstring = g_string_append_c (gstring, ch); + break; + } + } + else + gstring = g_string_append_c (gstring, ch); + } + } + ch = 0; + break; + + case '.': + if (!config->scan_float) + goto default_case; + token = G_TOKEN_FLOAT; + dotted_float = TRUE; + ch = g_scanner_get_char (scanner, line_p, position_p); + goto number_parsing; + + case '$': + if (!config->scan_hex_dollar) + goto default_case; + token = G_TOKEN_HEX; + ch = g_scanner_get_char (scanner, line_p, position_p); + goto number_parsing; + + case '0': + if (config->scan_octal) + token = G_TOKEN_OCTAL; + else + token = G_TOKEN_INT; + ch = g_scanner_peek_next_char (scanner); + if (config->scan_hex && (ch == 'x' || ch == 'X')) + { + token = G_TOKEN_HEX; + g_scanner_get_char (scanner, line_p, position_p); + ch = g_scanner_get_char (scanner, line_p, position_p); + if (ch == 0) + { + token = G_TOKEN_ERROR; + value.v_error = G_ERR_UNEXP_EOF; + (*position_p)++; + break; + } + if (g_scanner_char_2_num (ch, 16) < 0) + { + token = G_TOKEN_ERROR; + value.v_error = G_ERR_DIGIT_RADIX; + ch = 0; + break; + } + } + else if (config->scan_binary && (ch == 'b' || ch == 'B')) + { + token = G_TOKEN_BINARY; + g_scanner_get_char (scanner, line_p, position_p); + ch = g_scanner_get_char (scanner, line_p, position_p); + if (ch == 0) + { + token = G_TOKEN_ERROR; + value.v_error = G_ERR_UNEXP_EOF; + (*position_p)++; + break; + } + if (g_scanner_char_2_num (ch, 10) < 0) + { + token = G_TOKEN_ERROR; + value.v_error = G_ERR_NON_DIGIT_IN_CONST; + ch = 0; + break; + } + } + else + ch = '0'; + /* fall through */ + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': + number_parsing: + { + gboolean in_number = TRUE; + gchar *endptr; + + if (token == G_TOKEN_NONE) + token = G_TOKEN_INT; + + gstring = g_string_new (dotted_float ? "0." : ""); + gstring = g_string_append_c (gstring, ch); + + do /* while (in_number) */ + { + gboolean is_E; + + is_E = token == G_TOKEN_FLOAT && (ch == 'e' || ch == 'E'); + + ch = g_scanner_peek_next_char (scanner); + + if (g_scanner_char_2_num (ch, 36) >= 0 || + (config->scan_float && ch == '.') || + (is_E && (ch == '+' || ch == '-'))) + { + ch = g_scanner_get_char (scanner, line_p, position_p); + + switch (ch) + { + case '.': + if (token != G_TOKEN_INT && token != G_TOKEN_OCTAL) + { + value.v_error = token == G_TOKEN_FLOAT ? G_ERR_FLOAT_MALFORMED : G_ERR_FLOAT_RADIX; + token = G_TOKEN_ERROR; + in_number = FALSE; + } + else + { + token = G_TOKEN_FLOAT; + gstring = g_string_append_c (gstring, ch); + } + break; + + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': + gstring = g_string_append_c (gstring, ch); + break; + + case '-': + case '+': + if (token != G_TOKEN_FLOAT) + { + token = G_TOKEN_ERROR; + value.v_error = G_ERR_NON_DIGIT_IN_CONST; + in_number = FALSE; + } + else + gstring = g_string_append_c (gstring, ch); + break; + + case 'e': + case 'E': + if ((token != G_TOKEN_HEX && !config->scan_float) || + (token != G_TOKEN_HEX && + token != G_TOKEN_OCTAL && + token != G_TOKEN_FLOAT && + token != G_TOKEN_INT)) + { + token = G_TOKEN_ERROR; + value.v_error = G_ERR_NON_DIGIT_IN_CONST; + in_number = FALSE; + } + else + { + if (token != G_TOKEN_HEX) + token = G_TOKEN_FLOAT; + gstring = g_string_append_c (gstring, ch); + } + break; + + default: + if (token != G_TOKEN_HEX) + { + token = G_TOKEN_ERROR; + value.v_error = G_ERR_NON_DIGIT_IN_CONST; + in_number = FALSE; + } + else + gstring = g_string_append_c (gstring, ch); + break; + } + } + else + in_number = FALSE; + } + while (in_number); + + endptr = NULL; + switch (token) + { + case G_TOKEN_BINARY: + value.v_binary = strtol (gstring->str, &endptr, 2); + break; + + case G_TOKEN_OCTAL: + value.v_octal = strtol (gstring->str, &endptr, 8); + break; + + case G_TOKEN_INT: + value.v_int = strtol (gstring->str, &endptr, 10); + break; + + case G_TOKEN_FLOAT: + value.v_float = g_strtod (gstring->str, &endptr); + break; + + case G_TOKEN_HEX: + value.v_hex = strtol (gstring->str, &endptr, 16); + break; + + default: + break; + } + if (endptr && *endptr) + { + token = G_TOKEN_ERROR; + if (*endptr == 'e' || *endptr == 'E') + value.v_error = G_ERR_NON_DIGIT_IN_CONST; + else + value.v_error = G_ERR_DIGIT_RADIX; + } + g_string_free (gstring, TRUE); + gstring = NULL; + ch = 0; + } /* number_parsing:... */ + break; + + default: + default_case: + { + if (config->cpair_comment_single && + ch == config->cpair_comment_single[0]) + { + token = G_TOKEN_COMMENT_SINGLE; + in_comment_single = TRUE; + gstring = g_string_new (""); + ch = g_scanner_get_char (scanner, line_p, position_p); + while (ch != 0) + { + if (ch == config->cpair_comment_single[1]) + { + in_comment_single = FALSE; + ch = 0; + break; + } + + gstring = g_string_append_c (gstring, ch); + ch = g_scanner_get_char (scanner, line_p, position_p); + } + } + else if (config->scan_identifier && ch && + strchr (config->cset_identifier_first, ch)) + { + identifier_precedence: + + if (config->cset_identifier_nth && ch && + strchr (config->cset_identifier_nth, + g_scanner_peek_next_char (scanner))) + { + token = G_TOKEN_IDENTIFIER; + gstring = g_string_new (""); + gstring = g_string_append_c (gstring, ch); + do + { + ch = g_scanner_get_char (scanner, line_p, position_p); + gstring = g_string_append_c (gstring, ch); + ch = g_scanner_peek_next_char (scanner); + } + while (ch && strchr (config->cset_identifier_nth, ch)); + ch = 0; + } + else if (config->scan_identifier_1char) + { + token = G_TOKEN_IDENTIFIER; + value.v_identifier = g_new0 (gchar, 2); + value.v_identifier[0] = ch; + ch = 0; + } + } + if (ch) + { + if (config->char_2_token) + token = ch; + else + { + token = G_TOKEN_CHAR; + value.v_char = ch; + } + ch = 0; + } + } /* default_case:... */ + break; + } + g_assert (ch == 0 && token != G_TOKEN_NONE); /* paranoid */ + } + while (ch != 0); + + if (in_comment_multi || in_comment_single || + in_string_sq || in_string_dq) + { + token = G_TOKEN_ERROR; + if (gstring) + { + g_string_free (gstring, TRUE); + gstring = NULL; + } + (*position_p)++; + if (in_comment_multi || in_comment_single) + value.v_error = G_ERR_UNEXP_EOF_IN_COMMENT; + else /* (in_string_sq || in_string_dq) */ + value.v_error = G_ERR_UNEXP_EOF_IN_STRING; + } + + if (gstring) + { + value.v_string = gstring->str; + g_string_free (gstring, FALSE); + gstring = NULL; + } + + if (token == G_TOKEN_IDENTIFIER) + { + if (config->scan_symbols) + { + GScannerKey *key; + guint scope_id; + + scope_id = scanner->scope_id; + key = g_scanner_lookup_internal (scanner, scope_id, value.v_identifier); + if (!key && scope_id && scanner->config->scope_0_fallback) + key = g_scanner_lookup_internal (scanner, 0, value.v_identifier); + + if (key) + { + g_free (value.v_identifier); + token = G_TOKEN_SYMBOL; + value.v_symbol = key->value; + } + } + + if (token == G_TOKEN_IDENTIFIER && + config->scan_identifier_NULL && + strlen (value.v_identifier) == 4) + { + gchar *null_upper = "NULL"; + gchar *null_lower = "null"; + + if (scanner->config->case_sensitive) + { + if (value.v_identifier[0] == null_upper[0] && + value.v_identifier[1] == null_upper[1] && + value.v_identifier[2] == null_upper[2] && + value.v_identifier[3] == null_upper[3]) + token = G_TOKEN_IDENTIFIER_NULL; + } + else + { + if ((value.v_identifier[0] == null_upper[0] || + value.v_identifier[0] == null_lower[0]) && + (value.v_identifier[1] == null_upper[1] || + value.v_identifier[1] == null_lower[1]) && + (value.v_identifier[2] == null_upper[2] || + value.v_identifier[2] == null_lower[2]) && + (value.v_identifier[3] == null_upper[3] || + value.v_identifier[3] == null_lower[3])) + token = G_TOKEN_IDENTIFIER_NULL; + } + } + } + + *token_p = token; + *value_p = value; +} diff --git a/graf2d/win32gdk/gdk/src/glib/gscanner.h b/graf2d/win32gdk/gdk/src/glib/gscanner.h index 8cee79b414ece..951d3ff20d0f7 100644 --- a/graf2d/win32gdk/gdk/src/glib/gscanner.h +++ b/graf2d/win32gdk/gdk/src/glib/gscanner.h @@ -27,7 +27,7 @@ #ifndef __G_SCANNER_H__ #define __G_SCANNER_H__ -#include <ghash.h> +#include <glib/ghash.h> G_BEGIN_DECLS @@ -168,8 +168,8 @@ struct _GScanner /* name of input stream, featured by the default message handler */ const gchar *input_name; - /* data pointer for derived structures */ - gpointer derived_data; + /* quarked data */ + GData *qdata; /* link into the scanner configuration */ GScannerConfig *config; @@ -198,7 +198,7 @@ struct _GScanner GScannerMsgFunc msg_handler; }; -GScanner* g_scanner_new (GScannerConfig *config_templ); +GScanner* g_scanner_new (const GScannerConfig *config_templ); void g_scanner_destroy (GScanner *scanner); void g_scanner_input_file (GScanner *scanner, gint input_fd); @@ -244,7 +244,6 @@ void g_scanner_error (GScanner *scanner, void g_scanner_warn (GScanner *scanner, const gchar *format, ...) G_GNUC_PRINTF (2,3); -gint g_scanner_stat_mode (const gchar *filename); /* keep downward source compatibility */ #define g_scanner_add_symbol( scanner, symbol, value ) G_STMT_START { \ g_scanner_scope_add_symbol ((scanner), 0, (symbol), (value)); \ @@ -256,10 +255,14 @@ gint g_scanner_stat_mode (const gchar *filename); g_scanner_scope_foreach_symbol ((scanner), 0, (func), (data)); \ } G_STMT_END +#ifndef G_DISABLE_DEPRECATED + /* The following two functions are deprecated and will be removed in * the next major release. They do no good. */ -void g_scanner_freeze_symbol_table (GScanner *scanner); -void g_scanner_thaw_symbol_table (GScanner *scanner); +#define g_scanner_freeze_symbol_table(scanner) ((void)0) +#define g_scanner_thaw_symbol_table(scanner) ((void)0) + +#endif /* G_DISABLE_DEPRECATED */ G_END_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gshell.c b/graf2d/win32gdk/gdk/src/glib/gshell.c new file mode 100644 index 0000000000000..3f6134b6be8d7 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gshell.c @@ -0,0 +1,658 @@ +/* gshell.c - Shell-related utilities + * + * Copyright 2000 Red Hat, Inc. + * g_execvpe implementation based on GNU libc execvp: + * Copyright 1991, 92, 95, 96, 97, 98, 99 Free Software Foundation, Inc. + * + * GLib is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2 of the + * License, or (at your option) any later version. + * + * GLib is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with GLib; see the file COPYING.LIB. If not, write + * to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "glib.h" +#include <string.h> + +#ifdef _ +#warning "FIXME remove gettext hack" +#endif + +#include "glibintl.h" + +GQuark +g_shell_error_quark (void) +{ + static GQuark quark = 0; + if (quark == 0) + quark = g_quark_from_static_string ("g-shell-error-quark"); + return quark; +} + +/* Single quotes preserve the literal string exactly. escape + * sequences are not allowed; not even \' - if you want a ' + * in the quoted text, you have to do something like 'foo'\''bar' + * + * Double quotes allow $ ` " \ and newline to be escaped with backslash. + * Otherwise double quotes preserve things literally. + */ + +static gboolean +unquote_string_inplace (gchar* str, gchar** end, GError** err) +{ + gchar* dest; + gchar* s; + gchar quote_char; + + g_return_val_if_fail(end != NULL, FALSE); + g_return_val_if_fail(err == NULL || *err == NULL, FALSE); + g_return_val_if_fail(str != NULL, FALSE); + + dest = s = str; + + quote_char = *s; + + if (!(*s == '"' || *s == '\'')) + { + if (err) + *err = g_error_new(G_SHELL_ERROR, + G_SHELL_ERROR_BAD_QUOTING, + _("Quoted text doesn't begin with a quotation mark")); + *end = str; + return FALSE; + } + + /* Skip the initial quote mark */ + ++s; + + if (quote_char == '"') + { + while (*s) + { + g_assert(s > dest); /* loop invariant */ + + switch (*s) + { + case '"': + /* End of the string, return now */ + *dest = '\0'; + ++s; + *end = s; + return TRUE; + break; + + case '\\': + /* Possible escaped quote or \ */ + ++s; + switch (*s) + { + case '"': + case '\\': + case '`': + case '$': + case '\n': + *dest = *s; + ++s; + ++dest; + break; + + default: + /* not an escaped char */ + *dest = '\\'; + ++dest; + /* ++s already done. */ + break; + } + break; + + default: + *dest = *s; + ++dest; + ++s; + break; + } + + g_assert(s > dest); /* loop invariant */ + } + } + else + { + while (*s) + { + g_assert(s > dest); /* loop invariant */ + + if (*s == '\'') + { + /* End of the string, return now */ + *dest = '\0'; + ++s; + *end = s; + return TRUE; + } + else + { + *dest = *s; + ++dest; + ++s; + } + + g_assert(s > dest); /* loop invariant */ + } + } + + /* If we reach here this means the close quote was never encountered */ + + *dest = '\0'; + + if (err) + *err = g_error_new(G_SHELL_ERROR, + G_SHELL_ERROR_BAD_QUOTING, + _("Unmatched quotation mark in command line or other shell-quoted text")); + *end = s; + return FALSE; +} + +/** + * g_shell_quote: + * @unquoted_string: a literal string + * + * Quotes a string so that the shell (/bin/sh) will interpret the + * quoted string to mean @unquoted_string. If you pass a filename to + * the shell, for example, you should first quote it with this + * function. The return value must be freed with g_free(). The + * quoting style used is undefined (single or double quotes may be + * used). + * + * Return value: quoted string + **/ +gchar* +g_shell_quote (const gchar *unquoted_string) +{ + /* We always use single quotes, because the algorithm is cheesier. + * We could use double if we felt like it, that might be more + * human-readable. + */ + + const gchar *p; + GString *dest; + + g_return_val_if_fail (unquoted_string != NULL, NULL); + + dest = g_string_new ("'"); + + p = unquoted_string; + + /* could speed this up a lot by appending chunks of text at a + * time. + */ + while (*p) + { + /* Replace literal ' with a close ', a \', and a open ' */ + if (*p == '\'') + g_string_append (dest, "'\\''"); + else + g_string_append_c (dest, *p); + + ++p; + } + + /* close the quote */ + g_string_append_c (dest, '\''); + + return g_string_free (dest, FALSE); +} + +/** + * g_shell_unquote: + * @quoted_string: shell-quoted string + * @error: error return location or NULL + * + * Unquotes a string as the shell (/bin/sh) would. Only handles + * quotes; if a string contains file globs, arithmetic operators, + * variables, backticks, redirections, or other special-to-the-shell + * features, the result will be different from the result a real shell + * would produce (the variables, backticks, etc. will be passed + * through literally instead of being expanded). This function is + * guaranteed to succeed if applied to the result of + * g_shell_quote(). If it fails, it returns NULL and sets the + * error. The @quoted_string need not actually contain quoted or + * escaped text; g_shell_unquote() simply goes through the string and + * unquotes/unescapes anything that the shell would. Both single and + * double quotes are handled, as are escapes including escaped + * newlines. The return value must be freed with g_free(). Possible + * errors are in the #G_SHELL_ERROR domain. + * + * Shell quoting rules are a bit strange. Single quotes preserve the + * literal string exactly. escape sequences are not allowed; not even + * \' - if you want a ' in the quoted text, you have to do something + * like 'foo'\''bar'. Double quotes allow $, `, ", \, and newline to + * be escaped with backslash. Otherwise double quotes preserve things + * literally. + * + * Return value: an unquoted string + **/ +gchar* +g_shell_unquote (const gchar *quoted_string, + GError **error) +{ + gchar *unquoted; + gchar *end; + gchar *start; + GString *retval; + + g_return_val_if_fail (quoted_string != NULL, NULL); + + unquoted = g_strdup (quoted_string); + + start = unquoted; + end = unquoted; + retval = g_string_new (""); + + /* The loop allows cases such as + * "foo"blah blah'bar'woo foo"baz"la la la\'\''foo' + */ + while (*start) + { + /* Append all non-quoted chars, honoring backslash escape + */ + + while (*start && !(*start == '"' || *start == '\'')) + { + if (*start == '\\') + { + /* all characters can get escaped by backslash, + * except newline, which is removed if it follows + * a backslash outside of quotes + */ + + ++start; + if (*start) + { + if (*start != '\n') + g_string_append_c (retval, *start); + ++start; + } + } + else + { + g_string_append_c (retval, *start); + ++start; + } + } + + if (*start) + { + if (!unquote_string_inplace (start, &end, error)) + { + goto error; + } + else + { + g_string_append (retval, start); + start = end; + } + } + } + + return g_string_free (retval, FALSE); + + error: + g_assert (error == NULL || *error != NULL); + + g_free (unquoted); + g_string_free (retval, TRUE); + return NULL; +} + +/* g_parse_argv() does a semi-arbitrary weird subset of the way + * the shell parses a command line. We don't do variable expansion, + * don't understand that operators are tokens, don't do tilde expansion, + * don't do command substitution, no arithmetic expansion, IFS gets ignored, + * don't do filename globs, don't remove redirection stuff, etc. + * + * READ THE UNIX98 SPEC on "Shell Command Language" before changing + * the behavior of this code. + * + * Steps to parsing the argv string: + * + * - tokenize the string (but since we ignore operators, + * our tokenization may diverge from what the shell would do) + * note that tokenization ignores the internals of a quoted + * word and it always splits on spaces, not on IFS even + * if we used IFS. We also ignore "end of input indicator" + * (I guess this is control-D?) + * + * Tokenization steps, from UNIX98 with operator stuff removed, + * are: + * + * 1) "If the current character is backslash, single-quote or + * double-quote (\, ' or ") and it is not quoted, it will affect + * quoting for subsequent characters up to the end of the quoted + * text. The rules for quoting are as described in Quoting + * . During token recognition no substitutions will be actually + * performed, and the result token will contain exactly the + * characters that appear in the input (except for newline + * character joining), unmodified, including any embedded or + * enclosing quotes or substitution operators, between the quote + * mark and the end of the quoted text. The token will not be + * delimited by the end of the quoted field." + * + * 2) "If the current character is an unquoted newline character, + * the current token will be delimited." + * + * 3) "If the current character is an unquoted blank character, any + * token containing the previous character is delimited and the + * current character will be discarded." + * + * 4) "If the previous character was part of a word, the current + * character will be appended to that word." + * + * 5) "If the current character is a "#", it and all subsequent + * characters up to, but excluding, the next newline character + * will be discarded as a comment. The newline character that + * ends the line is not considered part of the comment. The + * "#" starts a comment only when it is at the beginning of a + * token. Since the search for the end-of-comment does not + * consider an escaped newline character specially, a comment + * cannot be continued to the next line." + * + * 6) "The current character will be used as the start of a new word." + * + * + * - for each token (word), perform portions of word expansion, namely + * field splitting (using default whitespace IFS) and quote + * removal. Field splitting may increase the number of words. + * Quote removal does not increase the number of words. + * + * "If the complete expansion appropriate for a word results in an + * empty field, that empty field will be deleted from the list of + * fields that form the completely expanded command, unless the + * original word contained single-quote or double-quote characters." + * - UNIX98 spec + * + * + */ + +static inline void +ensure_token (GString **token) +{ + if (*token == NULL) + *token = g_string_new (""); +} + +static void +delimit_token (GString **token, + GSList **retval) +{ + if (*token == NULL) + return; + + *retval = g_slist_prepend (*retval, g_string_free (*token, FALSE)); + + *token = NULL; +} + +static GSList* +tokenize_command_line (const gchar *command_line, + GError **error) +{ + gchar current_quote; + const gchar *p; + GString *current_token = NULL; + GSList *retval = NULL; + + current_quote = '\0'; + p = command_line; + + while (*p) + { + if (current_quote == '\\') + { + if (*p == '\n') + { + /* we append nothing; backslash-newline become nothing */ + } + else + { + /* we append the backslash and the current char, + * to be interpreted later after tokenization + */ + ensure_token (¤t_token); + g_string_append_c (current_token, '\\'); + g_string_append_c (current_token, *p); + } + + current_quote = '\0'; + } + else if (current_quote == '#') + { + /* Discard up to and including next newline */ + while (*p && *p != '\n') + ++p; + + current_quote = '\0'; + + if (*p == '\0') + break; + } + else if (current_quote) + { + if (*p == current_quote && + /* check that it isn't an escaped double quote */ + !(current_quote == '"' && p != command_line && *(p - 1) == '\\')) + { + /* close the quote */ + current_quote = '\0'; + } + + /* Everything inside quotes, and the close quote, + * gets appended literally. + */ + + ensure_token (¤t_token); + g_string_append_c (current_token, *p); + } + else + { + switch (*p) + { + case '\n': + delimit_token (¤t_token, &retval); + break; + + case ' ': + case '\t': + /* If the current token contains the previous char, delimit + * the current token. A nonzero length + * token should always contain the previous char. + */ + if (current_token && + current_token->len > 0) + { + delimit_token (¤t_token, &retval); + } + + /* discard all unquoted blanks (don't add them to a token) */ + break; + + + /* single/double quotes are appended to the token, + * escapes are maybe appended next time through the loop, + * comment chars are never appended. + */ + + case '\'': + case '"': + ensure_token (¤t_token); + g_string_append_c (current_token, *p); + + /* FALL THRU */ + + case '#': + case '\\': + current_quote = *p; + break; + + default: + /* Combines rules 4) and 6) - if we have a token, append to it, + * otherwise create a new token. + */ + ensure_token (¤t_token); + g_string_append_c (current_token, *p); + break; + } + } + + ++p; + } + + delimit_token (¤t_token, &retval); + + if (current_quote) + { + if (current_quote == '\\') + g_set_error (error, + G_SHELL_ERROR, + G_SHELL_ERROR_BAD_QUOTING, + _("Text ended just after a '\' character." + " (The text was '%s')"), + command_line); + else + g_set_error (error, + G_SHELL_ERROR, + G_SHELL_ERROR_BAD_QUOTING, + _("Text ended before matching quote was found for %c." + " (The text was '%s')"), + current_quote, command_line); + + goto error; + } + + if (retval == NULL) + { + g_set_error (error, + G_SHELL_ERROR, + G_SHELL_ERROR_EMPTY_STRING, + _("Text was empty (or contained only whitespace)")); + + goto error; + } + + /* we appended backward */ + retval = g_slist_reverse (retval); + + return retval; + + error: + g_assert (error == NULL || *error != NULL); + + if (retval) + { + g_slist_foreach (retval, (GFunc)g_free, NULL); + g_slist_free (retval); + } + + return NULL; +} + +/** + * g_shell_parse_argv: + * @command_line: command line to parse + * @argcp: return location for number of args + * @argvp: return location for array of args + * @error: return location for error + * + * Parses a command line into an argument vector, in much the same way + * the shell would, but without many of the expansions the shell would + * perform (variable expansion, globs, operators, filename expansion, + * etc. are not supported). The results are defined to be the same as + * those you would get from a UNIX98 /bin/sh, as long as the input + * contains none of the unsupported shell expansions. If the input + * does contain such expansions, they are passed through + * literally. Possible errors are those from the #G_SHELL_ERROR + * domain. + * + * Return value: TRUE on success, FALSE if error set + **/ +gboolean +g_shell_parse_argv (const gchar *command_line, + gint *argcp, + gchar ***argvp, + GError **error) +{ + /* Code based on poptParseArgvString() from libpopt */ + gint argc = 0; + gchar **argv = NULL; + GSList *tokens = NULL; + gint i; + GSList *tmp_list; + + g_return_val_if_fail (command_line != NULL, FALSE); + + tokens = tokenize_command_line (command_line, error); + if (tokens == NULL) + return FALSE; + + /* Because we can't have introduced any new blank space into the + * tokens (we didn't do any new expansions), we don't need to + * perform field splitting. If we were going to honor IFS or do any + * expansions, we would have to do field splitting on each word + * here. Also, if we were going to do any expansion we would need to + * remove any zero-length words that didn't contain quotes + * originally; but since there's no expansion we know all words have + * nonzero length, unless they contain quotes. + * + * So, we simply remove quotes, and don't do any field splitting or + * empty word removal, since we know there was no way to introduce + * such things. + */ + + argc = g_slist_length (tokens); + argv = g_new0 (gchar*, argc + 1); + i = 0; + tmp_list = tokens; + while (tmp_list) + { + argv[i] = g_shell_unquote (tmp_list->data, error); + + /* Since we already checked that quotes matched up in the + * tokenizer, this shouldn't be possible to reach I guess. + */ + if (argv[i] == NULL) + goto failed; + + tmp_list = g_slist_next (tmp_list); + ++i; + } + + g_slist_foreach (tokens, (GFunc)g_free, NULL); + g_slist_free (tokens); + + if (argcp) + *argcp = argc; + + if (argvp) + *argvp = argv; + else + g_strfreev (argv); + + return TRUE; + + failed: + + g_assert (error == NULL || *error != NULL); + g_strfreev (argv); + g_slist_foreach (tokens, (GFunc) g_free, NULL); + g_slist_free (tokens); + + return FALSE; +} diff --git a/graf2d/win32gdk/gdk/src/glib/gshell.h b/graf2d/win32gdk/gdk/src/glib/gshell.h index c433cbaeb48b0..b3f9d91480702 100644 --- a/graf2d/win32gdk/gdk/src/glib/gshell.h +++ b/graf2d/win32gdk/gdk/src/glib/gshell.h @@ -21,7 +21,7 @@ #ifndef __G_SHELL_H__ #define __G_SHELL_H__ -#include <gerror.h> +#include <glib/gerror.h> G_BEGIN_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gslist.c b/graf2d/win32gdk/gdk/src/glib/gslist.c new file mode 100644 index 0000000000000..18e08e42dc6ca --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gslist.c @@ -0,0 +1,767 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include "glib.h" + + +#ifndef DISABLE_MEM_POOLS +struct _GAllocator /* from gmem.c */ +{ + gchar *name; + guint16 n_preallocs; + guint is_unused : 1; + guint type : 4; + GAllocator *last; + GMemChunk *mem_chunk; + GSList *free_lists; /* implementation specific */ +}; + +G_LOCK_DEFINE_STATIC (current_allocator); +static GAllocator *current_allocator = NULL; + +/* HOLDS: current_allocator_lock */ +static void +g_slist_validate_allocator (GAllocator *allocator) +{ + g_return_if_fail (allocator != NULL); + g_return_if_fail (allocator->is_unused == TRUE); + + if (allocator->type != G_ALLOCATOR_SLIST) + { + allocator->type = G_ALLOCATOR_SLIST; + if (allocator->mem_chunk) + { + g_mem_chunk_destroy (allocator->mem_chunk); + allocator->mem_chunk = NULL; + } + } + + if (!allocator->mem_chunk) + { + allocator->mem_chunk = g_mem_chunk_new (allocator->name, + sizeof (GSList), + sizeof (GSList) * allocator->n_preallocs, + G_ALLOC_ONLY); + allocator->free_lists = NULL; + } + + allocator->is_unused = FALSE; +} + +void +g_slist_push_allocator (GAllocator *allocator) +{ + G_LOCK (current_allocator); + g_slist_validate_allocator (allocator); + allocator->last = current_allocator; + current_allocator = allocator; + G_UNLOCK (current_allocator); +} + +void +g_slist_pop_allocator (void) +{ + G_LOCK (current_allocator); + if (current_allocator) + { + GAllocator *allocator; + + allocator = current_allocator; + current_allocator = allocator->last; + allocator->last = NULL; + allocator->is_unused = TRUE; + } + G_UNLOCK (current_allocator); +} + +static inline GSList* +_g_slist_alloc (void) +{ + GSList *list; + + G_LOCK (current_allocator); + if (!current_allocator) + { + GAllocator *allocator = g_allocator_new ("GLib default GSList allocator", + 128); + g_slist_validate_allocator (allocator); + allocator->last = NULL; + current_allocator = allocator; + } + if (!current_allocator->free_lists) + { + list = g_chunk_new (GSList, current_allocator->mem_chunk); + list->data = NULL; + } + else + { + if (current_allocator->free_lists->data) + { + list = current_allocator->free_lists->data; + current_allocator->free_lists->data = list->next; + list->data = NULL; + } + else + { + list = current_allocator->free_lists; + current_allocator->free_lists = list->next; + } + } + G_UNLOCK (current_allocator); + + list->next = NULL; + + return list; +} + +GSList* +g_slist_alloc (void) +{ + return _g_slist_alloc (); +} + +void +g_slist_free (GSList *list) +{ + if (list) + { + GSList *last_node = list; + +#ifdef ENABLE_GC_FRIENDLY + while (last_node->next) + { + last_node->data = NULL; + last_node = last_node->next; + } + last_node->data = NULL; +#else /* !ENABLE_GC_FRIENDLY */ + list->data = list->next; +#endif /* ENABLE_GC_FRIENDLY */ + + G_LOCK (current_allocator); + last_node->next = current_allocator->free_lists; + current_allocator->free_lists = list; + G_UNLOCK (current_allocator); + } +} + +static inline void +_g_slist_free_1 (GSList *list) +{ + if (list) + { + list->data = NULL; + G_LOCK (current_allocator); + list->next = current_allocator->free_lists; + current_allocator->free_lists = list; + G_UNLOCK (current_allocator); + } +} + +void +g_slist_free_1 (GSList *list) +{ + _g_slist_free_1 (list); +} +#else /* DISABLE_MEM_POOLS */ + +#define _g_slist_alloc g_slist_alloc +GSList* +g_slist_alloc (void) +{ + GSList *list; + + list = g_new0 (GSList, 1); + + return list; +} + +void +g_slist_free (GSList *list) +{ + GSList *last; + + while (list) + { + last = list; + list = list->next; + g_free (last); + } +} + +#define _g_slist_free_1 g_slist_free_1 +void +g_slist_free_1 (GSList *list) +{ + g_free (list); +} + +#endif + +GSList* +g_slist_append (GSList *list, + gpointer data) +{ + GSList *new_list; + GSList *last; + + new_list = _g_slist_alloc (); + new_list->data = data; + + if (list) + { + last = g_slist_last (list); + /* g_assert (last != NULL); */ + last->next = new_list; + + return list; + } + else + return new_list; +} + +GSList* +g_slist_prepend (GSList *list, + gpointer data) +{ + GSList *new_list; + + new_list = _g_slist_alloc (); + new_list->data = data; + new_list->next = list; + + return new_list; +} + +GSList* +g_slist_insert (GSList *list, + gpointer data, + gint position) +{ + GSList *prev_list; + GSList *tmp_list; + GSList *new_list; + + if (position < 0) + return g_slist_append (list, data); + else if (position == 0) + return g_slist_prepend (list, data); + + new_list = _g_slist_alloc (); + new_list->data = data; + + if (!list) + return new_list; + + prev_list = NULL; + tmp_list = list; + + while ((position-- > 0) && tmp_list) + { + prev_list = tmp_list; + tmp_list = tmp_list->next; + } + + if (prev_list) + { + new_list->next = prev_list->next; + prev_list->next = new_list; + } + else + { + new_list->next = list; + list = new_list; + } + + return list; +} + +GSList* +g_slist_insert_before (GSList *slist, + GSList *sibling, + gpointer data) +{ + if (!slist) + { + slist = g_slist_alloc (); + slist->data = data; + g_return_val_if_fail (sibling == NULL, slist); + return slist; + } + else + { + GSList *node, *last = NULL; + + for (node = slist; node; last = node, node = last->next) + if (node == sibling) + break; + if (!last) + { + node = g_slist_alloc (); + node->data = data; + node->next = slist; + + return node; + } + else + { + node = g_slist_alloc (); + node->data = data; + node->next = last->next; + last->next = node; + + return slist; + } + } +} + +GSList * +g_slist_concat (GSList *list1, GSList *list2) +{ + if (list2) + { + if (list1) + g_slist_last (list1)->next = list2; + else + list1 = list2; + } + + return list1; +} + +GSList* +g_slist_remove (GSList *list, + gconstpointer data) +{ + GSList *tmp, *prev = NULL; + + tmp = list; + while (tmp) + { + if (tmp->data == data) + { + if (prev) + prev->next = tmp->next; + else + list = tmp->next; + + g_slist_free_1 (tmp); + break; + } + prev = tmp; + tmp = prev->next; + } + + return list; +} + +GSList* +g_slist_remove_all (GSList *list, + gconstpointer data) +{ + GSList *tmp, *prev = NULL; + + tmp = list; + while (tmp) + { + if (tmp->data == data) + { + GSList *next = tmp->next; + + if (prev) + prev->next = next; + else + list = next; + + g_slist_free_1 (tmp); + tmp = next; + } + else + { + prev = tmp; + tmp = prev->next; + } + } + + return list; +} + +static inline GSList* +_g_slist_remove_link (GSList *list, + GSList *link) +{ + GSList *tmp; + GSList *prev; + + prev = NULL; + tmp = list; + + while (tmp) + { + if (tmp == link) + { + if (prev) + prev->next = tmp->next; + if (list == tmp) + list = list->next; + + tmp->next = NULL; + break; + } + + prev = tmp; + tmp = tmp->next; + } + + return list; +} + +GSList* +g_slist_remove_link (GSList *list, + GSList *link) +{ + return _g_slist_remove_link (list, link); +} + +GSList* +g_slist_delete_link (GSList *list, + GSList *link) +{ + list = _g_slist_remove_link (list, link); + _g_slist_free_1 (link); + + return list; +} + +GSList* +g_slist_copy (GSList *list) +{ + GSList *new_list = NULL; + + if (list) + { + GSList *last; + + new_list = _g_slist_alloc (); + new_list->data = list->data; + last = new_list; + list = list->next; + while (list) + { + last->next = _g_slist_alloc (); + last = last->next; + last->data = list->data; + list = list->next; + } + } + + return new_list; +} + +GSList* +g_slist_reverse (GSList *list) +{ + GSList *prev = NULL; + + while (list) + { + GSList *next = list->next; + + list->next = prev; + + prev = list; + list = next; + } + + return prev; +} + +GSList* +g_slist_nth (GSList *list, + guint n) +{ + while (n-- > 0 && list) + list = list->next; + + return list; +} + +gpointer +g_slist_nth_data (GSList *list, + guint n) +{ + while (n-- > 0 && list) + list = list->next; + + return list ? list->data : NULL; +} + +GSList* +g_slist_find (GSList *list, + gconstpointer data) +{ + while (list) + { + if (list->data == data) + break; + list = list->next; + } + + return list; +} + +GSList* +g_slist_find_custom (GSList *list, + gconstpointer data, + GCompareFunc func) +{ + g_return_val_if_fail (func != NULL, list); + + while (list) + { + if (! func (list->data, data)) + return list; + list = list->next; + } + + return NULL; +} + +gint +g_slist_position (GSList *list, + GSList *link) +{ + gint i; + + i = 0; + while (list) + { + if (list == link) + return i; + i++; + list = list->next; + } + + return -1; +} + +gint +g_slist_index (GSList *list, + gconstpointer data) +{ + gint i; + + i = 0; + while (list) + { + if (list->data == data) + return i; + i++; + list = list->next; + } + + return -1; +} + +GSList* +g_slist_last (GSList *list) +{ + if (list) + { + while (list->next) + list = list->next; + } + + return list; +} + +guint +g_slist_length (GSList *list) +{ + guint length; + + length = 0; + while (list) + { + length++; + list = list->next; + } + + return length; +} + +void +g_slist_foreach (GSList *list, + GFunc func, + gpointer user_data) +{ + while (list) + { + GSList *next = list->next; + (*func) (list->data, user_data); + list = next; + } +} + +GSList* +g_slist_insert_sorted (GSList *list, + gpointer data, + GCompareFunc func) +{ + GSList *tmp_list = list; + GSList *prev_list = NULL; + GSList *new_list; + gint cmp; + + g_return_val_if_fail (func != NULL, list); + + if (!list) + { + new_list = _g_slist_alloc (); + new_list->data = data; + return new_list; + } + + cmp = (*func) (data, tmp_list->data); + + while ((tmp_list->next) && (cmp > 0)) + { + prev_list = tmp_list; + tmp_list = tmp_list->next; + cmp = (*func) (data, tmp_list->data); + } + + new_list = _g_slist_alloc (); + new_list->data = data; + + if ((!tmp_list->next) && (cmp > 0)) + { + tmp_list->next = new_list; + return list; + } + + if (prev_list) + { + prev_list->next = new_list; + new_list->next = tmp_list; + return list; + } + else + { + new_list->next = list; + return new_list; + } +} + +static GSList * +g_slist_sort_merge (GSList *l1, + GSList *l2, + GFunc compare_func, + gboolean use_data, + gpointer user_data) +{ + GSList list, *l; + gint cmp; + + l=&list; + + while (l1 && l2) + { + if (use_data) + cmp = ((GCompareDataFunc) compare_func) (l1->data, l2->data, user_data); + else + cmp = ((GCompareFunc) compare_func) (l1->data, l2->data); + + if (cmp <= 0) + { + l=l->next=l1; + l1=l1->next; + } + else + { + l=l->next=l2; + l2=l2->next; + } + } + l->next= l1 ? l1 : l2; + + return list.next; +} + +static GSList * +g_slist_sort_real (GSList *list, + GFunc compare_func, + gboolean use_data, + gpointer user_data) +{ + GSList *l1, *l2; + + if (!list) + return NULL; + if (!list->next) + return list; + + l1 = list; + l2 = list->next; + + while ((l2 = l2->next) != NULL) + { + if ((l2 = l2->next) == NULL) + break; + l1=l1->next; + } + l2 = l1->next; + l1->next = NULL; + + return g_slist_sort_merge (g_slist_sort_real (list, compare_func, use_data, user_data), + g_slist_sort_real (l2, compare_func, use_data, user_data), + compare_func, + use_data, + user_data); +} + +GSList * +g_slist_sort (GSList *list, + GCompareFunc compare_func) +{ + return g_slist_sort_real (list, (GFunc) compare_func, FALSE, NULL); +} + +GSList * +g_slist_sort_with_data (GSList *list, + GCompareDataFunc compare_func, + gpointer user_data) +{ + return g_slist_sort_real (list, (GFunc) compare_func, TRUE, user_data); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gslist.h b/graf2d/win32gdk/gdk/src/glib/gslist.h index a31d0efc65e73..32a3b245255b3 100644 --- a/graf2d/win32gdk/gdk/src/glib/gslist.h +++ b/graf2d/win32gdk/gdk/src/glib/gslist.h @@ -27,7 +27,7 @@ #ifndef __G_SLIST_H__ #define __G_SLIST_H__ -#include <gmem.h> +#include <glib/gmem.h> G_BEGIN_DECLS @@ -41,7 +41,7 @@ struct _GSList /* Singly linked lists */ -void g_slist_push_allocator (GAllocator *allocato); +void g_slist_push_allocator (GAllocator *allocator); void g_slist_pop_allocator (void); GSList* g_slist_alloc (void); void g_slist_free (GSList *list); @@ -63,6 +63,8 @@ GSList* g_slist_concat (GSList *list1, GSList *list2); GSList* g_slist_remove (GSList *list, gconstpointer data); +GSList* g_slist_remove_all (GSList *list, + gconstpointer data); GSList* g_slist_remove_link (GSList *list, GSList *link); GSList* g_slist_delete_link (GSList *list, @@ -88,7 +90,7 @@ void g_slist_foreach (GSList *list, GSList* g_slist_sort (GSList *list, GCompareFunc compare_func); GSList* g_slist_sort_with_data (GSList *list, - GCompareFuncData compare_func, + GCompareDataFunc compare_func, gpointer user_data); gpointer g_slist_nth_data (GSList *list, guint n); diff --git a/graf2d/win32gdk/gdk/src/glib/gspawn-win32-helper.c b/graf2d/win32gdk/gdk/src/glib/gspawn-win32-helper.c new file mode 100644 index 0000000000000..59709b8d24cce --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gspawn-win32-helper.c @@ -0,0 +1,231 @@ +/* gspawn-win32-helper.c - Helper program for process launching on Win32. + * + * Copyright 2000 Red Hat, Inc. + * Copyright 2000 Tor Lillqvist + * + * GLib is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2 of the + * License, or (at your option) any later version. + * + * GLib is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with GLib; see the file COPYING.LIB. If not, write + * to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#undef G_LOG_DOMAIN +#include "glib.h" +#define GSPAWN_HELPER +#include "gspawn-win32.c" /* For shared definitions */ + +static GString *debugstring; + +static void +write_err_and_exit (gint fd, + gint msg) +{ + gint en = errno; + + if (debug) + { + debugstring = g_string_new (""); + g_string_append (debugstring, + g_strdup_printf ("writing error code %d and errno %d", + msg, en)); + MessageBox (NULL, debugstring->str, "gspawn-win32-helper", 0); + } + + write (fd, &msg, sizeof(msg)); + write (fd, &en, sizeof(en)); + + _exit (1); +} + +#ifdef __GNUC__ +# ifndef _stdcall +# define _stdcall __attribute__((stdcall)) +# endif +#endif + +/* We build gspawn-win32-helper.exe as a Windows GUI application + * to avoid any temporarily flashing console windows in case + * the gspawn function is invoked by a GUI program. Thus, no main() + * but a WinMain(). We do, however, still use argc and argv tucked + * away in the global __argc and __argv by the C runtime startup code. + */ + +int _stdcall +WinMain (struct HINSTANCE__ *hInstance, + struct HINSTANCE__ *hPrevInstance, + char *lpszCmdLine, + int nCmdShow) +{ + int child_err_report_fd; + int i; + int fd; + int mode; + gint zero = 0; + + SETUP_DEBUG(); + + if (debug) + { + debugstring = g_string_new (""); + + g_string_append (debugstring, + g_strdup_printf ("g-spawn-win32-helper: " + "argc = %d, argv: ", + __argc)); + for (i = 0; i < __argc; i++) + { + if (i > 0) + g_string_append (debugstring, " "); + g_string_append (debugstring, __argv[i]); + } + + MessageBox (NULL, debugstring->str, "gspawn-win32-helper", 0); + } + + g_assert (__argc >= ARG_COUNT); + + /* argv[ARG_CHILD_ERR_REPORT] is the file descriptor onto which + * write error messages. + */ + child_err_report_fd = atoi (__argv[ARG_CHILD_ERR_REPORT]); + + /* argv[ARG_STDIN..ARG_STDERR] are the file descriptors that should + * be dup2'd to stdin, stdout and stderr, '-' if the corresponding + * std* should be let alone, and 'z' if it should be connected to + * the bit bucket NUL:. + */ + if (__argv[ARG_STDIN][0] == '-') + ; /* Nothing */ + else if (__argv[ARG_STDIN][0] == 'z') + { + fd = open ("NUL:", O_RDONLY); + if (fd != 0) + { + dup2 (fd, 0); + close (fd); + } + } + else + { + fd = atoi (__argv[ARG_STDIN]); + if (fd != 0) + { + dup2 (fd, 0); + close (fd); + } + } + + if (__argv[ARG_STDOUT][0] == '-') + ; /* Nothing */ + else if (__argv[ARG_STDOUT][0] == 'z') + { + fd = open ("NUL:", O_WRONLY); + if (fd != 1) + { + dup2 (fd, 1); + close (fd); + } + } + else + { + fd = atoi (__argv[ARG_STDOUT]); + if (fd != 1) + { + dup2 (fd, 1); + close (fd); + } + } + + if (__argv[ARG_STDERR][0] == '-') + ; /* Nothing */ + else if (__argv[ARG_STDERR][0] == 'z') + { + fd = open ("NUL:", O_WRONLY); + if (fd != 2) + { + dup2 (fd, 2); + close (fd); + } + } + else + { + fd = atoi (__argv[ARG_STDERR]); + if (fd != 2) + { + dup2 (fd, 2); + close (fd); + } + } + + /* __argv[ARG_WORKING_DIRECTORY] is the directory in which to run the + * process. If "-", don't change directory. + */ + if (__argv[ARG_WORKING_DIRECTORY][0] == '-' && + __argv[ARG_WORKING_DIRECTORY][1] == 0) + ; /* Nothing */ + else if (chdir (__argv[ARG_WORKING_DIRECTORY]) < 0) + write_err_and_exit (child_err_report_fd, + CHILD_CHDIR_FAILED); + + /* __argv[ARG_CLOSE_DESCRIPTORS] is "y" if file descriptors from 3 + * upwards should be closed + */ + + if (__argv[ARG_CLOSE_DESCRIPTORS][0] == 'y') + for (i = 3; i < 1000; i++) /* FIXME real limit? */ + if (i != child_err_report_fd) + close (i); + + /* __argv[ARG_WAIT] is "w" to wait for the program to exit */ + + if (__argv[ARG_WAIT][0] == 'w') + mode = P_WAIT; + else + mode = P_NOWAIT; + + /* __argv[ARG_USE_PATH] is "y" to use PATH, otherwise not */ + + /* __argv[ARG_PROGRAM] is program file to run, + * __argv[ARG_PROGRAM+1]... is its __argv. + */ + + if (debug) + { + debugstring = g_string_new (""); + g_string_append (debugstring, + g_strdup_printf ("calling %s on program %s, __argv: ", + (__argv[ARG_USE_PATH][0] == 'y' ? + "spawnvp" : "spawnv"), + __argv[ARG_PROGRAM])); + i = ARG_PROGRAM+1; + while (__argv[i]) + g_string_append (debugstring, __argv[i++]); + MessageBox (NULL, debugstring->str, "gspawn-win32-helper", 0); + } + + if (__argv[ARG_USE_PATH][0] == 'y') + { + if (spawnvp (mode, __argv[ARG_PROGRAM], __argv+ARG_PROGRAM) < 0) + write_err_and_exit (child_err_report_fd, CHILD_SPAWN_FAILED); + } + else + { + if (spawnv (mode, __argv[ARG_PROGRAM], __argv+ARG_PROGRAM) < 0) + write_err_and_exit (child_err_report_fd, CHILD_SPAWN_FAILED); + } + write (child_err_report_fd, &zero, sizeof (zero)); + write (child_err_report_fd, &zero, sizeof (zero)); + Sleep (10000); + return 0; +} + diff --git a/graf2d/win32gdk/gdk/src/glib/gspawn-win32.c b/graf2d/win32gdk/gdk/src/glib/gspawn-win32.c new file mode 100644 index 0000000000000..aa9e3072da1bf --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gspawn-win32.c @@ -0,0 +1,984 @@ +/* gspawn-win32.c - Process launching on Win32 + * + * Copyright 2000 Red Hat, Inc. + * + * GLib is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2 of the + * License, or (at your option) any later version. + * + * GLib is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with GLib; see the file COPYING.LIB. If not, write + * to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Implementation details on Win32. + * + * - There is no way to set the no-inherit flag for + * a "file descriptor" in the MS C runtime. The flag is there, + * and the dospawn() function uses it, but unfortunately + * this flag can only be set when opening the file. + * - As there is no fork(), we cannot reliably change directory + * before starting the child process. (There might be several threads + * running, and the current directory is common for all threads.) + * + * Thus, we must in most cases use a helper program to handle closing + * of (inherited) file descriptors and changing of directory. In fact, + * we do it all the time. + */ + +/* Define this to get some logging all the time */ +/* #define G_SPAWN_WIN32_DEBUG */ + +#include "glib.h" + +#include <string.h> +#include <stdlib.h> +#include <stdio.h> + +#include <windows.h> +#include <errno.h> +#include <fcntl.h> +#include <io.h> +#include <process.h> +#include <direct.h> + +#include "glibintl.h" + +#ifdef G_SPAWN_WIN32_DEBUG + static int debug = 1; + #define SETUP_DEBUG() /* empty */ + +#else + static int debug = -1; + #define SETUP_DEBUG() \ + G_STMT_START \ + { \ + if (debug == -1) \ + { \ + if (getenv ("G_SPAWN_WIN32_DEBUG") != NULL) \ + debug = 1; \ + else \ + debug = 0; \ + } \ + } \ + G_STMT_END +#endif + +enum +{ + CHILD_NO_ERROR, + CHILD_CHDIR_FAILED, + CHILD_SPAWN_FAILED, +}; + +enum { + ARG_CHILD_ERR_REPORT = 1, + ARG_STDIN, + ARG_STDOUT, + ARG_STDERR, + ARG_WORKING_DIRECTORY, + ARG_CLOSE_DESCRIPTORS, + ARG_USE_PATH, + ARG_WAIT, + ARG_PROGRAM, + ARG_COUNT = ARG_PROGRAM +}; + +#ifndef GSPAWN_HELPER + +static gboolean make_pipe (gint p[2], + GError **error); +static gboolean fork_exec_with_pipes (gboolean dont_wait, + const gchar *working_directory, + gchar **argv, + gchar **envp, + gboolean close_descriptors, + gboolean search_path, + gboolean stdout_to_null, + gboolean stderr_to_null, + gboolean child_inherits_stdin, + GSpawnChildSetupFunc child_setup, + gpointer user_data, + gint *standard_input, + gint *standard_output, + gint *standard_error, + gint *exit_status, + GError **error); + +GQuark +g_spawn_error_quark (void) +{ + static GQuark quark = 0; + if (quark == 0) + quark = g_quark_from_static_string ("g-exec-error-quark"); + return quark; +} + +/** + * g_spawn_async: + * @working_directory: child's current working directory, or NULL to inherit parent's + * @argv: child's argument vector + * @envp: child's environment, or NULL to inherit parent's + * @flags: flags from #GSpawnFlags + * @child_setup: function to run in the child just before exec() + * @user_data: user data for @child_setup + * @child_pid: return location for child process ID, or NULL + * @error: return location for error + * + * See g_spawn_async_with_pipes() for a full description; this function + * simply calls the g_spawn_async_with_pipes() without any pipes. + * + * Return value: TRUE on success, FALSE if error is set + **/ +gboolean +g_spawn_async (const gchar *working_directory, + gchar **argv, + gchar **envp, + GSpawnFlags flags, + GSpawnChildSetupFunc child_setup, + gpointer user_data, + gint *child_pid, + GError **error) +{ + g_return_val_if_fail (argv != NULL, FALSE); + + return g_spawn_async_with_pipes (working_directory, + argv, envp, + flags, + child_setup, + user_data, + child_pid, + NULL, NULL, NULL, + error); +} + +/* Avoids a danger in threaded situations (calling close() + * on a file descriptor twice, and another thread has + * re-opened it since the first close) + */ +static gint +close_and_invalidate (gint *fd) +{ + gint ret; + + ret = close (*fd); + *fd = -1; + + return ret; +} + +typedef enum +{ + READ_FAILED = 0, /* FALSE */ + READ_OK, + READ_EOF +} ReadResult; + +static ReadResult +read_data (GString *str, + GIOChannel *iochannel, + GError **error) +{ + GIOError gioerror; + gint bytes; + gchar buf[4096]; + + again: + + gioerror = g_io_channel_read (iochannel, buf, sizeof (buf), &bytes); + + if (bytes == 0) + return READ_EOF; + else if (bytes > 0) + { + g_string_append_len (str, buf, bytes); + return READ_OK; + } + else if (gioerror == G_IO_ERROR_AGAIN) + goto again; + else if (gioerror != G_IO_ERROR_NONE) + { + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_READ, + _("Failed to read data from child process")); + + return READ_FAILED; + } + else + return READ_OK; +} + +/** + * g_spawn_sync: + * @working_directory: child's current working directory, or NULL to inherit parent's + * @argv: child's argument vector + * @envp: child's environment, or NULL to inherit parent's + * @flags: flags from #GSpawnFlags + * @child_setup: function to run in the child just before exec() + * @user_data: user data for @child_setup + * @standard_output: return location for child output + * @standard_error: return location for child error messages + * @exit_status: child exit status, as returned by waitpid() + * @error: return location for error + * + * Executes a child synchronously (waits for the child to exit before returning). + * All output from the child is stored in @standard_output and @standard_error, + * if those parameters are non-NULL. If @exit_status is non-NULL, the exit status + * of the child is stored there as it would be by waitpid(); standard UNIX + * macros such as WIFEXITED() and WEXITSTATUS() must be used to evaluate the + * exit status. If an error occurs, no data is returned in @standard_output, + * @standard_error, or @exit_status. + * + * This function calls g_spawn_async_with_pipes() internally; see that function + * for full details on the other parameters. + * + * Return value: TRUE on success, FALSE if an error was set. + **/ +gboolean +g_spawn_sync (const gchar *working_directory, + gchar **argv, + gchar **envp, + GSpawnFlags flags, + GSpawnChildSetupFunc child_setup, + gpointer user_data, + gchar **standard_output, + gchar **standard_error, + gint *exit_status, + GError **error) +{ + gint outpipe = -1; + gint errpipe = -1; + GIOChannel *outchannel = NULL; + GIOChannel *errchannel = NULL; + GPollFD outfd, errfd; + GPollFD fds[2]; + gint nfds; + gint outindex = -1; + gint errindex = -1; + gint ret; + GString *outstr = NULL; + GString *errstr = NULL; + gboolean failed; + gint status; + + g_return_val_if_fail (argv != NULL, FALSE); + g_return_val_if_fail (!(flags & G_SPAWN_DO_NOT_REAP_CHILD), FALSE); + g_return_val_if_fail (standard_output == NULL || + !(flags & G_SPAWN_STDOUT_TO_DEV_NULL), FALSE); + g_return_val_if_fail (standard_error == NULL || + !(flags & G_SPAWN_STDERR_TO_DEV_NULL), FALSE); + + /* Just to ensure segfaults if callers try to use + * these when an error is reported. + */ + if (standard_output) + *standard_output = NULL; + + if (standard_error) + *standard_error = NULL; + + if (!fork_exec_with_pipes (FALSE, + working_directory, + argv, + envp, + !(flags & G_SPAWN_LEAVE_DESCRIPTORS_OPEN), + (flags & G_SPAWN_SEARCH_PATH) != 0, + (flags & G_SPAWN_STDOUT_TO_DEV_NULL) != 0, + (flags & G_SPAWN_STDERR_TO_DEV_NULL) != 0, + (flags & G_SPAWN_CHILD_INHERITS_STDIN) != 0, + child_setup, + user_data, + NULL, + standard_output ? &outpipe : NULL, + standard_error ? &errpipe : NULL, + &status, + error)) + return FALSE; + + /* Read data from child. */ + + failed = FALSE; + + if (outpipe >= 0) + { + outstr = g_string_new (""); + outchannel = g_io_channel_win32_new_fd (outpipe); + g_io_channel_win32_make_pollfd (outchannel, + G_IO_IN | G_IO_ERR | G_IO_HUP, + &outfd); + } + + if (errpipe >= 0) + { + errstr = g_string_new (""); + errchannel = g_io_channel_win32_new_fd (errpipe); + g_io_channel_win32_make_pollfd (errchannel, + G_IO_IN | G_IO_ERR | G_IO_HUP, + &errfd); + } + + /* Read data until we get EOF on both pipes. */ + while (!failed && + (outpipe >= 0 || + errpipe >= 0)) + { + nfds = 0; + if (outpipe >= 0) + { + fds[nfds] = outfd; + outindex = nfds; + nfds++; + } + if (errpipe >= 0) + { + fds[nfds] = errfd; + errindex = nfds; + nfds++; + } + + if (debug) + g_print ("%s:g_spawn_sync: calling g_io_channel_win32_poll, nfds=%d\n", + __FILE__, nfds); + + ret = g_io_channel_win32_poll (fds, nfds, -1); + + if (ret < 0) + { + failed = TRUE; + + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_READ, + _("Unexpected error in g_io_channel_win32_poll() reading data from a child process")); + + break; + } + + if (outpipe >= 0 && (fds[outindex].revents & G_IO_IN)) + { + switch (read_data (outstr, outchannel, error)) + { + case READ_FAILED: + if (debug) + g_print ("g_spawn_sync: outchannel: READ_FAILED\n"); + failed = TRUE; + break; + case READ_EOF: + if (debug) + g_print ("g_spawn_sync: outchannel: READ_EOF\n"); + g_io_channel_unref (outchannel); + outchannel = NULL; + close_and_invalidate (&outpipe); + break; + default: + if (debug) + g_print ("g_spawn_sync: outchannel: OK\n"); + break; + } + + if (failed) + break; + } + + if (errpipe >= 0 && (fds[errindex].revents & G_IO_IN)) + { + switch (read_data (errstr, errchannel, error)) + { + case READ_FAILED: + if (debug) + g_print ("g_spawn_sync: errchannel: READ_FAILED\n"); + failed = TRUE; + break; + case READ_EOF: + if (debug) + g_print ("g_spawn_sync: errchannel: READ_EOF\n"); + g_io_channel_unref (errchannel); + errchannel = NULL; + close_and_invalidate (&errpipe); + break; + default: + if (debug) + g_print ("g_spawn_sync: errchannel: OK\n"); + break; + } + + if (failed) + break; + } + } + + /* These should only be open still if we had an error. */ + + if (outchannel != NULL) + g_io_channel_unref (outchannel); + if (errchannel != NULL) + g_io_channel_unref (errchannel); + if (outpipe >= 0) + close_and_invalidate (&outpipe); + if (errpipe >= 0) + close_and_invalidate (&errpipe); + + if (failed) + { + if (outstr) + g_string_free (outstr, TRUE); + if (errstr) + g_string_free (errstr, TRUE); + + return FALSE; + } + else + { + if (exit_status) + *exit_status = status; + + if (standard_output) + *standard_output = g_string_free (outstr, FALSE); + + if (standard_error) + *standard_error = g_string_free (errstr, FALSE); + + return TRUE; + } +} + +/** + * g_spawn_async_with_pipes: + * @working_directory: child's current working directory, or NULL to inherit parent's + * @argv: child's argument vector + * @envp: child's environment, or NULL to inherit parent's + * @flags: flags from #GSpawnFlags + * @child_setup: function to run in the child just before exec() + * @user_data: user data for @child_setup + * @child_pid: return location for child process ID, or NULL + * @standard_input: return location for file descriptor to write to child's stdin, or NULL + * @standard_output: return location for file descriptor to read child's stdout, or NULL + * @standard_error: return location for file descriptor to read child's stderr, or NULL + * @error: return location for error + * + * Executes a child program asynchronously (your program will not + * block waiting for the child to exit). The child program is + * specified by the only argument that must be provided, @argv. @argv + * should be a NULL-terminated array of strings, to be passed as the + * argument vector for the child. The first string in @argv is of + * course the name of the program to execute. By default, the name of + * the program must be a full path; the PATH shell variable will only + * be searched if you pass the %G_SPAWN_SEARCH_PATH flag. + * + * @envp is a NULL-terminated array of strings, where each string + * has the form <literal>KEY=VALUE</literal>. This will become + * the child's environment. If @envp is NULL, the child inherits its + * parent's environment. + * + * @flags should be the bitwise OR of any flags you want to affect the + * function's behavior. The %G_SPAWN_DO_NOT_REAP_CHILD means that the + * child will not be automatically reaped; you must call waitpid() or + * handle SIGCHLD yourself, or the child will become a zombie. + * %G_SPAWN_LEAVE_DESCRIPTORS_OPEN means that the parent's open file + * descriptors will be inherited by the child; otherwise all + * descriptors except stdin/stdout/stderr will be closed before + * calling exec() in the child. %G_SPAWN_SEARCH_PATH means that + * <literal>argv[0]</literal> need not be an absolute path, it + * will be looked for in the user's PATH. %G_SPAWN_STDOUT_TO_DEV_NULL + * means that the child's standad output will be discarded, instead + * of going to the same location as the parent's standard output. + * %G_SPAWN_STDERR_TO_DEV_NULL means that the child's standard error + * will be discarded. %G_SPAWN_CHILD_INHERITS_STDIN means that + * the child will inherit the parent's standard input (by default, + * the child's standard input is attached to /dev/null). + * + * @child_setup and @user_data are a function and user data to be + * called in the child after GLib has performed all the setup it plans + * to perform (including creating pipes, closing file descriptors, + * etc.) but before calling exec(). That is, @child_setup is called + * just before calling exec() in the child. Obviously actions taken in + * this function will only affect the child, not the parent. + * + * If non-NULL, @child_pid will be filled with the child's process + * ID. You can use the process ID to send signals to the child, or + * to waitpid() if you specified the %G_SPAWN_DO_NOT_REAP_CHILD flag. + * + * If non-NULL, the @standard_input, @standard_output, @standard_error + * locations will be filled with file descriptors for writing to the child's + * standard input or reading from its standard output or standard error. + * The caller of g_spawn_async_with_pipes() must close these file descriptors + * when they are no longer in use. If these parameters are NULL, the + * corresponding pipe won't be created. + * + * @error can be NULL to ignore errors, or non-NULL to report errors. + * If an error is set, the function returns FALSE. Errors + * are reported even if they occur in the child (for example if the + * executable in <literal>argv[0]</literal> is not found). Typically + * the <literal>message</literal> field of returned errors should be displayed + * to users. Possible errors are those from the #G_SPAWN_ERROR domain. + * + * If an error occurs, @child_pid, @standard_input, @standard_output, + * and @standard_error will not be filled with valid values. + * + * Return value: TRUE on success, FALSE if an error was set + **/ +gboolean +g_spawn_async_with_pipes (const gchar *working_directory, + gchar **argv, + gchar **envp, + GSpawnFlags flags, + GSpawnChildSetupFunc child_setup, + gpointer user_data, + gint *child_pid, + gint *standard_input, + gint *standard_output, + gint *standard_error, + GError **error) +{ + g_return_val_if_fail (argv != NULL, FALSE); + g_return_val_if_fail (standard_output == NULL || + !(flags & G_SPAWN_STDOUT_TO_DEV_NULL), FALSE); + g_return_val_if_fail (standard_error == NULL || + !(flags & G_SPAWN_STDERR_TO_DEV_NULL), FALSE); + /* can't inherit stdin if we have an input pipe. */ + g_return_val_if_fail (standard_input == NULL || + !(flags & G_SPAWN_CHILD_INHERITS_STDIN), FALSE); + + return fork_exec_with_pipes (!(flags & G_SPAWN_DO_NOT_REAP_CHILD), + working_directory, + argv, + envp, + !(flags & G_SPAWN_LEAVE_DESCRIPTORS_OPEN), + (flags & G_SPAWN_SEARCH_PATH) != 0, + (flags & G_SPAWN_STDOUT_TO_DEV_NULL) != 0, + (flags & G_SPAWN_STDERR_TO_DEV_NULL) != 0, + (flags & G_SPAWN_CHILD_INHERITS_STDIN) != 0, + child_setup, + user_data, + standard_input, + standard_output, + standard_error, + NULL, + error); +} + +/** + * g_spawn_command_line_sync: + * @command_line: a command line + * @standard_output: return location for child output + * @standard_error: return location for child errors + * @exit_status: return location for child exit status + * @error: return location for errors + * + * A simple version of g_spawn_sync() with little-used parameters + * removed, taking a command line instead of an argument vector. See + * g_spawn_sync() for full details. @command_line will be parsed by + * g_shell_parse_argv(). Unlike g_spawn_sync(), the %G_SPAWN_SEARCH_PATH flag + * is enabled. Note that %G_SPAWN_SEARCH_PATH can have security + * implications, so consider using g_spawn_sync() directly if + * appropriate. Possible errors are those from g_spawn_sync() and those + * from g_shell_parse_argv(). + * + * Return value: TRUE on success, FALSE if an error was set + **/ +gboolean +g_spawn_command_line_sync (const gchar *command_line, + gchar **standard_output, + gchar **standard_error, + gint *exit_status, + GError **error) +{ + gboolean retval; + gchar **argv = 0; + + g_return_val_if_fail (command_line != NULL, FALSE); + + if (!g_shell_parse_argv (command_line, + NULL, &argv, + error)) + return FALSE; + + retval = g_spawn_sync (NULL, + argv, + NULL, + G_SPAWN_SEARCH_PATH, + NULL, + NULL, + standard_output, + standard_error, + exit_status, + error); + g_strfreev (argv); + + return retval; +} + +/** + * g_spawn_command_line_async: + * @command_line: a command line + * @error: return location for errors + * + * A simple version of g_spawn_async() that parses a command line with + * g_shell_parse_argv() and passes it to g_spawn_async(). Runs a + * command line in the background. Unlike g_spawn_async(), the + * %G_SPAWN_SEARCH_PATH flag is enabled, other flags are not. Note + * that %G_SPAWN_SEARCH_PATH can have security implications, so + * consider using g_spawn_async() directly if appropriate. Possible + * errors are those from g_shell_parse_argv() and g_spawn_async(). + * + * Return value: TRUE on success, FALSE if error is set. + **/ +gboolean +g_spawn_command_line_async (const gchar *command_line, + GError **error) +{ + gboolean retval; + gchar **argv = 0; + + g_return_val_if_fail (command_line != NULL, FALSE); + + if (!g_shell_parse_argv (command_line, + NULL, &argv, + error)) + return FALSE; + + retval = g_spawn_async (NULL, + argv, + NULL, + G_SPAWN_SEARCH_PATH, + NULL, + NULL, + NULL, + error); + g_strfreev (argv); + + return retval; +} + +static gint +do_exec (gboolean dont_wait, + gint child_err_report_fd, + gint stdin_fd, + gint stdout_fd, + gint stderr_fd, + const gchar *working_directory, + gchar **argv, + gchar **envp, + gboolean close_descriptors, + gboolean search_path, + gboolean stdout_to_null, + gboolean stderr_to_null, + gboolean child_inherits_stdin, + GSpawnChildSetupFunc child_setup, + gpointer user_data) +{ + const gchar **new_argv; + gchar args[ARG_COUNT][10]; + gint i; + int argc = 0; + + SETUP_DEBUG(); + + while (argv[argc]) + ++argc; + + new_argv = g_new (gchar *, argc + 1 + ARG_COUNT); + + new_argv[0] = "gspawn-win32-helper"; + sprintf (args[ARG_CHILD_ERR_REPORT], "%d", child_err_report_fd); + new_argv[ARG_CHILD_ERR_REPORT] = args[ARG_CHILD_ERR_REPORT]; + + if (stdin_fd >= 0) + { + sprintf (args[ARG_STDIN], "%d", stdin_fd); + new_argv[ARG_STDIN] = args[ARG_STDIN]; + } + else if (child_inherits_stdin) + { + /* Let stdin be alone */ + new_argv[ARG_STDIN] = "-"; + } + else + { + /* Keep process from blocking on a read of stdin */ + new_argv[ARG_STDIN] = "z"; + } + + if (stdout_fd >= 0) + { + sprintf (args[ARG_STDOUT], "%d", stdout_fd); + new_argv[ARG_STDOUT] = args[ARG_STDOUT]; + } + else if (stdout_to_null) + { + new_argv[ARG_STDOUT] = "z"; + } + else + { + new_argv[ARG_STDOUT] = "-"; + } + + if (stderr_fd >= 0) + { + sprintf (args[ARG_STDERR], "%d", stderr_fd); + new_argv[ARG_STDERR] = args[ARG_STDERR]; + } + else if (stderr_to_null) + { + new_argv[ARG_STDERR] = "z"; + } + else + { + new_argv[ARG_STDERR] = "-"; + } + + if (working_directory && *working_directory) + new_argv[ARG_WORKING_DIRECTORY] = working_directory; + else + new_argv[ARG_WORKING_DIRECTORY] = "-"; + + if (close_descriptors) + new_argv[ARG_CLOSE_DESCRIPTORS] = "y"; + else + new_argv[ARG_CLOSE_DESCRIPTORS] = "-"; + + if (search_path) + new_argv[ARG_USE_PATH] = "y"; + else + new_argv[ARG_USE_PATH] = "-"; + + if (dont_wait) + new_argv[ARG_WAIT] = "-"; + else + new_argv[ARG_WAIT] = "w"; + + for (i = 0; i <= argc; i++) + new_argv[ARG_PROGRAM + i] = argv[i]; + + /* Call user function just before we execute the helper program, + * which executes the program. Dunno what's the usefulness of this. + * A child setup function used on Unix probably isn't of much use + * as such on Win32, anyhow. + */ + if (child_setup) + { + (* child_setup) (user_data); + } + + if (debug) + { + g_print ("calling gspawn-win32-helper with argv:\n"); + for (i = 0; i < argc + 1 + ARG_COUNT; i++) + g_print ("argv[%d]: %s\n", i, (new_argv[i] ? new_argv[i] : "NULL")); + } + + if (envp != NULL) + /* Let's hope envp hasn't mucked with PATH so that + * gspawn-win32-helper.exe isn't found. + */ + spawnvpe (P_NOWAIT, "gspawn-win32-helper", new_argv, envp); + else + spawnvp (P_NOWAIT, "gspawn-win32-helper", new_argv); + + /* FIXME: What if gspawn-win32-helper.exe isn't found? */ + + /* Close the child_err_report_fd and the other process's ends of the + * pipes in this process, otherwise the reader will never get + * EOF. + */ + close (child_err_report_fd); + if (stdin_fd >= 0) + close (stdin_fd); + if (stdout_fd >= 0) + close (stdout_fd); + if (stderr_fd >= 0) + close (stderr_fd); + + g_free ((void*)new_argv); + + return 0; +} + +static gboolean +read_ints (int fd, + gint* buf, + gint n_ints_in_buf, + gint *n_ints_read, + GError **error) +{ + gint bytes = 0; + + while (bytes < sizeof(gint)*n_ints_in_buf) + { + gint chunk; + + if (debug) + g_print ("%s:read_ints: trying to read %d bytes from pipe...\n", + __FILE__, + sizeof(gint)*n_ints_in_buf - bytes); + + chunk = read (fd, ((gchar*)buf) + bytes, + sizeof(gint)*n_ints_in_buf - bytes); + + if (debug) + g_print ("... got %d bytes\n", chunk); + + if (chunk < 0) + { + /* Some weird shit happened, bail out */ + + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_FAILED, + _("Failed to read from child pipe (%s)"), + g_strerror (errno)); + + return FALSE; + } + else if (chunk == 0) + break; /* EOF */ + else + bytes += chunk; + } + + *n_ints_read = bytes/sizeof(gint); + + return TRUE; +} + +static gboolean +fork_exec_with_pipes (gboolean dont_wait, + const gchar *working_directory, + gchar **argv, + gchar **envp, + gboolean close_descriptors, + gboolean search_path, + gboolean stdout_to_null, + gboolean stderr_to_null, + gboolean child_inherits_stdin, + GSpawnChildSetupFunc child_setup, + gpointer user_data, + gint *standard_input, + gint *standard_output, + gint *standard_error, + gint *exit_status, + GError **error) +{ + gint stdin_pipe[2] = { -1, -1 }; + gint stdout_pipe[2] = { -1, -1 }; + gint stderr_pipe[2] = { -1, -1 }; + gint child_err_report_pipe[2] = { -1, -1 }; + gint status; + //gint bytes; + gint buf[2]; + gint n_ints = 0; + + if (!make_pipe (child_err_report_pipe, error)) + return FALSE; + + if (standard_input && !make_pipe (stdin_pipe, error)) + goto cleanup_and_fail; + + if (standard_output && !make_pipe (stdout_pipe, error)) + goto cleanup_and_fail; + + if (standard_error && !make_pipe (stderr_pipe, error)) + goto cleanup_and_fail; + + status = do_exec (dont_wait, + child_err_report_pipe[1], + stdin_pipe[0], + stdout_pipe[1], + stderr_pipe[1], + working_directory, + argv, + envp, + close_descriptors, + search_path, + stdout_to_null, + stderr_to_null, + child_inherits_stdin, + child_setup, + user_data); + + if (!read_ints (child_err_report_pipe[0], + buf, 2, &n_ints, + error)) + goto cleanup_and_fail; + + if (n_ints == 2) + { + /* Error from the child. */ + + switch (buf[0]) + { + case CHILD_NO_ERROR: + break; + + case CHILD_CHDIR_FAILED: + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_CHDIR, + _("Failed to change to directory '%s' (%s)"), + working_directory, + g_strerror (buf[1])); + goto cleanup_and_fail; + + case CHILD_SPAWN_FAILED: + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_FAILED, + _("Failed to execute child process (%s)"), + g_strerror (buf[1])); + goto cleanup_and_fail; + } + } + + /* Success against all odds! return the information */ + + if (standard_input) + *standard_input = stdin_pipe[1]; + if (standard_output) + *standard_output = stdout_pipe[0]; + if (standard_error) + *standard_error = stderr_pipe[0]; + if (exit_status) + *exit_status = status; + + return TRUE; + + cleanup_and_fail: + close_and_invalidate (&child_err_report_pipe[0]); + close_and_invalidate (&child_err_report_pipe[1]); + close_and_invalidate (&stdin_pipe[0]); + close_and_invalidate (&stdin_pipe[1]); + close_and_invalidate (&stdout_pipe[0]); + close_and_invalidate (&stdout_pipe[1]); + close_and_invalidate (&stderr_pipe[0]); + close_and_invalidate (&stderr_pipe[1]); + + return FALSE; +} + +static gboolean +make_pipe (gint p[2], + GError **error) +{ + if (pipe (p) < 0) + { + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_FAILED, + _("Failed to create pipe for communicating with child process (%s)"), + g_strerror (errno)); + return FALSE; + } + else + return TRUE; +} + +#endif /* !GSPAWN_HELPER */ diff --git a/graf2d/win32gdk/gdk/src/glib/gspawn.c b/graf2d/win32gdk/gdk/src/glib/gspawn.c new file mode 100644 index 0000000000000..8dc0e4b131cac --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gspawn.c @@ -0,0 +1,1404 @@ +/* gspawn.c - Process launching + * + * Copyright 2000 Red Hat, Inc. + * g_execvpe implementation based on GNU libc execvp: + * Copyright 1991, 92, 95, 96, 97, 98, 99 Free Software Foundation, Inc. + * + * GLib is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2 of the + * License, or (at your option) any later version. + * + * GLib is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with GLib; see the file COPYING.LIB. If not, write + * to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "glib.h" +#include <sys/time.h> +#include <sys/types.h> +#include <sys/wait.h> +#include <unistd.h> +#include <errno.h> +#include <fcntl.h> +#include <signal.h> +#include <string.h> + +#ifdef HAVE_SYS_SELECT_H +#include <sys/select.h> +#endif /* HAVE_SYS_SELECT_H */ + +#include "glibintl.h" + +static gint g_execute (const gchar *file, + gchar **argv, + gchar **envp, + gboolean search_path); + +static gboolean make_pipe (gint p[2], + GError **error); +static gboolean fork_exec_with_pipes (gboolean intermediate_child, + const gchar *working_directory, + gchar **argv, + gchar **envp, + gboolean close_descriptors, + gboolean search_path, + gboolean stdout_to_null, + gboolean stderr_to_null, + gboolean child_inherits_stdin, + gboolean file_and_argv_zero, + GSpawnChildSetupFunc child_setup, + gpointer user_data, + gint *child_pid, + gint *standard_input, + gint *standard_output, + gint *standard_error, + GError **error); + +GQuark +g_spawn_error_quark (void) +{ + static GQuark quark = 0; + if (quark == 0) + quark = g_quark_from_static_string ("g-exec-error-quark"); + return quark; +} + +/** + * g_spawn_async: + * @working_directory: child's current working directory, or NULL to inherit parent's + * @argv: child's argument vector + * @envp: child's environment, or NULL to inherit parent's + * @flags: flags from #GSpawnFlags + * @child_setup: function to run in the child just before exec() + * @user_data: user data for @child_setup + * @child_pid: return location for child process ID, or NULL + * @error: return location for error + * + * See g_spawn_async_with_pipes() for a full description; this function + * simply calls the g_spawn_async_with_pipes() without any pipes. + * + * Return value: TRUE on success, FALSE if error is set + **/ +gboolean +g_spawn_async (const gchar *working_directory, + gchar **argv, + gchar **envp, + GSpawnFlags flags, + GSpawnChildSetupFunc child_setup, + gpointer user_data, + gint *child_pid, + GError **error) +{ + g_return_val_if_fail (argv != NULL, FALSE); + + return g_spawn_async_with_pipes (working_directory, + argv, envp, + flags, + child_setup, + user_data, + child_pid, + NULL, NULL, NULL, + error); +} + +/* Avoids a danger in threaded situations (calling close() + * on a file descriptor twice, and another thread has + * re-opened it since the first close) + */ +static gint +close_and_invalidate (gint *fd) +{ + gint ret; + + ret = close (*fd); + *fd = -1; + + return ret; +} + +typedef enum +{ + READ_FAILED = 0, /* FALSE */ + READ_OK, + READ_EOF +} ReadResult; + +static ReadResult +read_data (GString *str, + gint fd, + GError **error) +{ + gssize bytes; + gchar buf[4096]; + + again: + + bytes = read (fd, &buf, 4096); + + if (bytes == 0) + return READ_EOF; + else if (bytes > 0) + { + g_string_append_len (str, buf, bytes); + return READ_OK; + } + else if (bytes < 0 && errno == EINTR) + goto again; + else if (bytes < 0) + { + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_READ, + _("Failed to read data from child process (%s)"), + g_strerror (errno)); + + return READ_FAILED; + } + else + return READ_OK; +} + +/** + * g_spawn_sync: + * @working_directory: child's current working directory, or NULL to inherit parent's + * @argv: child's argument vector + * @envp: child's environment, or NULL to inherit parent's + * @flags: flags from #GSpawnFlags + * @child_setup: function to run in the child just before exec() + * @user_data: user data for @child_setup + * @standard_output: return location for child output + * @standard_error: return location for child error messages + * @exit_status: child exit status, as returned by waitpid() + * @error: return location for error + * + * Executes a child synchronously (waits for the child to exit before returning). + * All output from the child is stored in @standard_output and @standard_error, + * if those parameters are non-NULL. If @exit_status is non-NULL, the exit status + * of the child is stored there as it would be by waitpid(); standard UNIX + * macros such as WIFEXITED() and WEXITSTATUS() must be used to evaluate the + * exit status. If an error occurs, no data is returned in @standard_output, + * @standard_error, or @exit_status. + * + * This function calls g_spawn_async_with_pipes() internally; see that function + * for full details on the other parameters. + * + * Return value: TRUE on success, FALSE if an error was set. + **/ +gboolean +g_spawn_sync (const gchar *working_directory, + gchar **argv, + gchar **envp, + GSpawnFlags flags, + GSpawnChildSetupFunc child_setup, + gpointer user_data, + gchar **standard_output, + gchar **standard_error, + gint *exit_status, + GError **error) +{ + gint outpipe = -1; + gint errpipe = -1; + gint pid; + fd_set fds; + gint ret; + GString *outstr = NULL; + GString *errstr = NULL; + gboolean failed; + gint status; + + g_return_val_if_fail (argv != NULL, FALSE); + g_return_val_if_fail (!(flags & G_SPAWN_DO_NOT_REAP_CHILD), FALSE); + g_return_val_if_fail (standard_output == NULL || + !(flags & G_SPAWN_STDOUT_TO_DEV_NULL), FALSE); + g_return_val_if_fail (standard_error == NULL || + !(flags & G_SPAWN_STDERR_TO_DEV_NULL), FALSE); + + /* Just to ensure segfaults if callers try to use + * these when an error is reported. + */ + if (standard_output) + *standard_output = NULL; + + if (standard_error) + *standard_error = NULL; + + if (!fork_exec_with_pipes (FALSE, + working_directory, + argv, + envp, + !(flags & G_SPAWN_LEAVE_DESCRIPTORS_OPEN), + (flags & G_SPAWN_SEARCH_PATH) != 0, + (flags & G_SPAWN_STDOUT_TO_DEV_NULL) != 0, + (flags & G_SPAWN_STDERR_TO_DEV_NULL) != 0, + (flags & G_SPAWN_CHILD_INHERITS_STDIN) != 0, + (flags & G_SPAWN_FILE_AND_ARGV_ZERO) != 0, + child_setup, + user_data, + &pid, + NULL, + standard_output ? &outpipe : NULL, + standard_error ? &errpipe : NULL, + error)) + return FALSE; + + /* Read data from child. */ + + failed = FALSE; + + if (outpipe >= 0) + { + outstr = g_string_new (""); + } + + if (errpipe >= 0) + { + errstr = g_string_new (""); + } + + /* Read data until we get EOF on both pipes. */ + while (!failed && + (outpipe >= 0 || + errpipe >= 0)) + { + ret = 0; + + FD_ZERO (&fds); + if (outpipe >= 0) + FD_SET (outpipe, &fds); + if (errpipe >= 0) + FD_SET (errpipe, &fds); + + ret = select (MAX (outpipe, errpipe) + 1, + &fds, + NULL, NULL, + NULL /* no timeout */); + + if (ret < 0 && errno != EINTR) + { + failed = TRUE; + + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_READ, + _("Unexpected error in select() reading data from a child process (%s)"), + g_strerror (errno)); + + break; + } + + if (outpipe >= 0 && FD_ISSET (outpipe, &fds)) + { + switch (read_data (outstr, outpipe, error)) + { + case READ_FAILED: + failed = TRUE; + break; + case READ_EOF: + close_and_invalidate (&outpipe); + outpipe = -1; + break; + default: + break; + } + + if (failed) + break; + } + + if (errpipe >= 0 && FD_ISSET (errpipe, &fds)) + { + switch (read_data (errstr, errpipe, error)) + { + case READ_FAILED: + failed = TRUE; + break; + case READ_EOF: + close_and_invalidate (&errpipe); + errpipe = -1; + break; + default: + break; + } + + if (failed) + break; + } + } + + /* These should only be open still if we had an error. */ + + if (outpipe >= 0) + close_and_invalidate (&outpipe); + if (errpipe >= 0) + close_and_invalidate (&errpipe); + + /* Wait for child to exit, even if we have + * an error pending. + */ + again: + + ret = waitpid (pid, &status, 0); + + if (ret < 0) + { + if (errno == EINTR) + goto again; + else if (errno == ECHILD) + { + if (exit_status) + { + g_warning ("In call to g_spawn_sync(), exit status of a child process was requested but SIGCHLD action was set to SIG_IGN and ECHILD was received by waitpid(), so exit status can't be returned. This is a bug in the program calling g_spawn_sync(); either don't request the exit status, or don't set the SIGCHLD action."); + } + else + { + /* We don't need the exit status. */ + } + } + else + { + if (!failed) /* avoid error pileups */ + { + failed = TRUE; + + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_READ, + _("Unexpected error in waitpid() (%s)"), + g_strerror (errno)); + } + } + } + + if (failed) + { + if (outstr) + g_string_free (outstr, TRUE); + if (errstr) + g_string_free (errstr, TRUE); + + return FALSE; + } + else + { + if (exit_status) + *exit_status = status; + + if (standard_output) + *standard_output = g_string_free (outstr, FALSE); + + if (standard_error) + *standard_error = g_string_free (errstr, FALSE); + + return TRUE; + } +} + +/** + * g_spawn_async_with_pipes: + * @working_directory: child's current working directory, or NULL to inherit parent's + * @argv: child's argument vector + * @envp: child's environment, or NULL to inherit parent's + * @flags: flags from #GSpawnFlags + * @child_setup: function to run in the child just before exec() + * @user_data: user data for @child_setup + * @child_pid: return location for child process ID, or NULL + * @standard_input: return location for file descriptor to write to child's stdin, or NULL + * @standard_output: return location for file descriptor to read child's stdout, or NULL + * @standard_error: return location for file descriptor to read child's stderr, or NULL + * @error: return location for error + * + * Executes a child program asynchronously (your program will not + * block waiting for the child to exit). The child program is + * specified by the only argument that must be provided, @argv. @argv + * should be a NULL-terminated array of strings, to be passed as the + * argument vector for the child. The first string in @argv is of + * course the name of the program to execute. By default, the name of + * the program must be a full path; the PATH shell variable will only + * be searched if you pass the %G_SPAWN_SEARCH_PATH flag. + * + * @envp is a NULL-terminated array of strings, where each string + * has the form <literal>KEY=VALUE</literal>. This will become + * the child's environment. If @envp is NULL, the child inherits its + * parent's environment. + * + * @flags should be the bitwise OR of any flags you want to affect the + * function's behavior. The %G_SPAWN_DO_NOT_REAP_CHILD means that the + * child will not be automatically reaped; you must call waitpid() or + * handle SIGCHLD yourself, or the child will become a zombie. + * %G_SPAWN_LEAVE_DESCRIPTORS_OPEN means that the parent's open file + * descriptors will be inherited by the child; otherwise all + * descriptors except stdin/stdout/stderr will be closed before + * calling exec() in the child. %G_SPAWN_SEARCH_PATH means that + * <literal>argv[0]</literal> need not be an absolute path, it + * will be looked for in the user's PATH. %G_SPAWN_STDOUT_TO_DEV_NULL + * means that the child's standad output will be discarded, instead + * of going to the same location as the parent's standard output. + * %G_SPAWN_STDERR_TO_DEV_NULL means that the child's standard error + * will be discarded. %G_SPAWN_CHILD_INHERITS_STDIN means that + * the child will inherit the parent's standard input (by default, + * the child's standard input is attached to /dev/null). + * %G_SPAWN_FILE_AND_ARGV_ZERO means that the first element of @argv is + * the file to execute, while the remaining elements are the + * actual argument vector to pass to the file. Normally + * g_spawn_async_with_pipes() uses @argv[0] as the file to execute, and + * passes all of @argv to the child. + * + * @child_setup and @user_data are a function and user data to be + * called in the child after GLib has performed all the setup it plans + * to perform (including creating pipes, closing file descriptors, + * etc.) but before calling exec(). That is, @child_setup is called + * just before calling exec() in the child. Obviously actions taken in + * this function will only affect the child, not the parent. + * + * If non-NULL, @child_pid will be filled with the child's process + * ID. You can use the process ID to send signals to the child, or + * to waitpid() if you specified the %G_SPAWN_DO_NOT_REAP_CHILD flag. + * + * If non-NULL, the @standard_input, @standard_output, @standard_error + * locations will be filled with file descriptors for writing to the child's + * standard input or reading from its standard output or standard error. + * The caller of g_spawn_async_with_pipes() must close these file descriptors + * when they are no longer in use. If these parameters are NULL, the + * corresponding pipe won't be created. + * + * @error can be NULL to ignore errors, or non-NULL to report errors. + * If an error is set, the function returns FALSE. Errors + * are reported even if they occur in the child (for example if the + * executable in <literal>argv[0]</literal> is not found). Typically + * the <literal>message</literal> field of returned errors should be displayed + * to users. Possible errors are those from the #G_SPAWN_ERROR domain. + * + * If an error occurs, @child_pid, @standard_input, @standard_output, + * and @standard_error will not be filled with valid values. + * + * Return value: TRUE on success, FALSE if an error was set + **/ +gboolean +g_spawn_async_with_pipes (const gchar *working_directory, + gchar **argv, + gchar **envp, + GSpawnFlags flags, + GSpawnChildSetupFunc child_setup, + gpointer user_data, + gint *child_pid, + gint *standard_input, + gint *standard_output, + gint *standard_error, + GError **error) +{ + g_return_val_if_fail (argv != NULL, FALSE); + g_return_val_if_fail (standard_output == NULL || + !(flags & G_SPAWN_STDOUT_TO_DEV_NULL), FALSE); + g_return_val_if_fail (standard_error == NULL || + !(flags & G_SPAWN_STDERR_TO_DEV_NULL), FALSE); + /* can't inherit stdin if we have an input pipe. */ + g_return_val_if_fail (standard_input == NULL || + !(flags & G_SPAWN_CHILD_INHERITS_STDIN), FALSE); + + return fork_exec_with_pipes (!(flags & G_SPAWN_DO_NOT_REAP_CHILD), + working_directory, + argv, + envp, + !(flags & G_SPAWN_LEAVE_DESCRIPTORS_OPEN), + (flags & G_SPAWN_SEARCH_PATH) != 0, + (flags & G_SPAWN_STDOUT_TO_DEV_NULL) != 0, + (flags & G_SPAWN_STDERR_TO_DEV_NULL) != 0, + (flags & G_SPAWN_CHILD_INHERITS_STDIN) != 0, + (flags & G_SPAWN_FILE_AND_ARGV_ZERO) != 0, + child_setup, + user_data, + child_pid, + standard_input, + standard_output, + standard_error, + error); +} + +/** + * g_spawn_command_line_sync: + * @command_line: a command line + * @standard_output: return location for child output + * @standard_error: return location for child errors + * @exit_status: return location for child exit status + * @error: return location for errors + * + * A simple version of g_spawn_sync() with little-used parameters + * removed, taking a command line instead of an argument vector. See + * g_spawn_sync() for full details. @command_line will be parsed by + * g_shell_parse_argv(). Unlike g_spawn_sync(), the %G_SPAWN_SEARCH_PATH flag + * is enabled. Note that %G_SPAWN_SEARCH_PATH can have security + * implications, so consider using g_spawn_sync() directly if + * appropriate. Possible errors are those from g_spawn_sync() and those + * from g_shell_parse_argv(). + * + * Return value: TRUE on success, FALSE if an error was set + **/ +gboolean +g_spawn_command_line_sync (const gchar *command_line, + gchar **standard_output, + gchar **standard_error, + gint *exit_status, + GError **error) +{ + gboolean retval; + gchar **argv = 0; + + g_return_val_if_fail (command_line != NULL, FALSE); + + if (!g_shell_parse_argv (command_line, + NULL, &argv, + error)) + return FALSE; + + retval = g_spawn_sync (NULL, + argv, + NULL, + G_SPAWN_SEARCH_PATH, + NULL, + NULL, + standard_output, + standard_error, + exit_status, + error); + g_strfreev (argv); + + return retval; +} + +/** + * g_spawn_command_line_async: + * @command_line: a command line + * @error: return location for errors + * + * A simple version of g_spawn_async() that parses a command line with + * g_shell_parse_argv() and passes it to g_spawn_async(). Runs a + * command line in the background. Unlike g_spawn_async(), the + * %G_SPAWN_SEARCH_PATH flag is enabled, other flags are not. Note + * that %G_SPAWN_SEARCH_PATH can have security implications, so + * consider using g_spawn_async() directly if appropriate. Possible + * errors are those from g_shell_parse_argv() and g_spawn_async(). + * + * Return value: TRUE on success, FALSE if error is set. + **/ +gboolean +g_spawn_command_line_async (const gchar *command_line, + GError **error) +{ + gboolean retval; + gchar **argv = 0; + + g_return_val_if_fail (command_line != NULL, FALSE); + + if (!g_shell_parse_argv (command_line, + NULL, &argv, + error)) + return FALSE; + + retval = g_spawn_async (NULL, + argv, + NULL, + G_SPAWN_SEARCH_PATH, + NULL, + NULL, + NULL, + error); + g_strfreev (argv); + + return retval; +} + +static gint +exec_err_to_g_error (gint en) +{ + switch (en) + { +#ifdef EACCES + case EACCES: + return G_SPAWN_ERROR_ACCES; + break; +#endif + +#ifdef EPERM + case EPERM: + return G_SPAWN_ERROR_PERM; + break; +#endif + +#ifdef E2BIG + case E2BIG: + return G_SPAWN_ERROR_2BIG; + break; +#endif + +#ifdef ENOEXEC + case ENOEXEC: + return G_SPAWN_ERROR_NOEXEC; + break; +#endif + +#ifdef ENAMETOOLONG + case ENAMETOOLONG: + return G_SPAWN_ERROR_NAMETOOLONG; + break; +#endif + +#ifdef ENOENT + case ENOENT: + return G_SPAWN_ERROR_NOENT; + break; +#endif + +#ifdef ENOMEM + case ENOMEM: + return G_SPAWN_ERROR_NOMEM; + break; +#endif + +#ifdef ENOTDIR + case ENOTDIR: + return G_SPAWN_ERROR_NOTDIR; + break; +#endif + +#ifdef ELOOP + case ELOOP: + return G_SPAWN_ERROR_LOOP; + break; +#endif + +#ifdef ETXTBUSY + case ETXTBUSY: + return G_SPAWN_ERROR_TXTBUSY; + break; +#endif + +#ifdef EIO + case EIO: + return G_SPAWN_ERROR_IO; + break; +#endif + +#ifdef ENFILE + case ENFILE: + return G_SPAWN_ERROR_NFILE; + break; +#endif + +#ifdef EMFILE + case EMFILE: + return G_SPAWN_ERROR_MFILE; + break; +#endif + +#ifdef EINVAL + case EINVAL: + return G_SPAWN_ERROR_INVAL; + break; +#endif + +#ifdef EISDIR + case EISDIR: + return G_SPAWN_ERROR_ISDIR; + break; +#endif + +#ifdef ELIBBAD + case ELIBBAD: + return G_SPAWN_ERROR_LIBBAD; + break; +#endif + + default: + return G_SPAWN_ERROR_FAILED; + break; + } +} + +static void +write_err_and_exit (gint fd, gint msg) +{ + gint en = errno; + + write (fd, &msg, sizeof(msg)); + write (fd, &en, sizeof(en)); + + _exit (1); +} + +static void +set_cloexec (gint fd) +{ + fcntl (fd, F_SETFD, FD_CLOEXEC); +} + +static gint +sane_dup2 (gint fd1, gint fd2) +{ + gint ret; + + retry: + ret = dup2 (fd1, fd2); + if (ret < 0 && errno == EINTR) + goto retry; + + return ret; +} + +enum +{ + CHILD_CHDIR_FAILED, + CHILD_EXEC_FAILED, + CHILD_DUP2_FAILED, + CHILD_FORK_FAILED +}; + +static void +do_exec (gint child_err_report_fd, + gint stdin_fd, + gint stdout_fd, + gint stderr_fd, + const gchar *working_directory, + gchar **argv, + gchar **envp, + gboolean close_descriptors, + gboolean search_path, + gboolean stdout_to_null, + gboolean stderr_to_null, + gboolean child_inherits_stdin, + gboolean file_and_argv_zero, + GSpawnChildSetupFunc child_setup, + gpointer user_data) +{ + if (working_directory && chdir (working_directory) < 0) + write_err_and_exit (child_err_report_fd, + CHILD_CHDIR_FAILED); + + /* Close all file descriptors but stdin stdout and stderr as + * soon as we exec. Note that this includes + * child_err_report_fd, which keeps the parent from blocking + * forever on the other end of that pipe. + */ + if (close_descriptors) + { + gint open_max; + gint i; + + open_max = sysconf (_SC_OPEN_MAX); + for (i = 3; i < open_max; i++) + set_cloexec (i); + } + else + { + /* We need to do child_err_report_fd anyway */ + set_cloexec (child_err_report_fd); + } + + /* Redirect pipes as required */ + + if (stdin_fd >= 0) + { + /* dup2 can't actually fail here I don't think */ + + if (sane_dup2 (stdin_fd, 0) < 0) + write_err_and_exit (child_err_report_fd, + CHILD_DUP2_FAILED); + + /* ignore this if it doesn't work */ + close_and_invalidate (&stdin_fd); + } + else if (!child_inherits_stdin) + { + /* Keep process from blocking on a read of stdin */ + gint read_null = open ("/dev/null", O_RDONLY); + sane_dup2 (read_null, 0); + close_and_invalidate (&read_null); + } + + if (stdout_fd >= 0) + { + /* dup2 can't actually fail here I don't think */ + + if (sane_dup2 (stdout_fd, 1) < 0) + write_err_and_exit (child_err_report_fd, + CHILD_DUP2_FAILED); + + /* ignore this if it doesn't work */ + close_and_invalidate (&stdout_fd); + } + else if (stdout_to_null) + { + gint write_null = open ("/dev/null", O_WRONLY); + sane_dup2 (write_null, 1); + close_and_invalidate (&write_null); + } + + if (stderr_fd >= 0) + { + /* dup2 can't actually fail here I don't think */ + + if (sane_dup2 (stderr_fd, 2) < 0) + write_err_and_exit (child_err_report_fd, + CHILD_DUP2_FAILED); + + /* ignore this if it doesn't work */ + close_and_invalidate (&stderr_fd); + } + else if (stderr_to_null) + { + gint write_null = open ("/dev/null", O_WRONLY); + sane_dup2 (write_null, 2); + close_and_invalidate (&write_null); + } + + /* Call user function just before we exec */ + if (child_setup) + { + (* child_setup) (user_data); + } + + g_execute (argv[0], + file_and_argv_zero ? argv + 1 : argv, + envp, search_path); + + /* Exec failed */ + write_err_and_exit (child_err_report_fd, + CHILD_EXEC_FAILED); +} + +static gboolean +read_ints (int fd, + gint* buf, + gint n_ints_in_buf, + gint *n_ints_read, + GError **error) +{ + gsize bytes = 0; + + while (TRUE) + { + gssize chunk; + + if (bytes >= sizeof(gint)*2) + break; /* give up, who knows what happened, should not be + * possible. + */ + + again: + chunk = read (fd, + ((gchar*)buf) + bytes, + sizeof(gint) * n_ints_in_buf - bytes); + if (chunk < 0 && errno == EINTR) + goto again; + + if (chunk < 0) + { + /* Some weird shit happened, bail out */ + + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_FAILED, + _("Failed to read from child pipe (%s)"), + g_strerror (errno)); + + return FALSE; + } + else if (chunk == 0) + break; /* EOF */ + else /* chunk > 0 */ + bytes += chunk; + } + + *n_ints_read = (gint)(bytes / sizeof(gint)); + + return TRUE; +} + +static gboolean +fork_exec_with_pipes (gboolean intermediate_child, + const gchar *working_directory, + gchar **argv, + gchar **envp, + gboolean close_descriptors, + gboolean search_path, + gboolean stdout_to_null, + gboolean stderr_to_null, + gboolean child_inherits_stdin, + gboolean file_and_argv_zero, + GSpawnChildSetupFunc child_setup, + gpointer user_data, + gint *child_pid, + gint *standard_input, + gint *standard_output, + gint *standard_error, + GError **error) +{ + gint pid; + gint stdin_pipe[2] = { -1, -1 }; + gint stdout_pipe[2] = { -1, -1 }; + gint stderr_pipe[2] = { -1, -1 }; + gint child_err_report_pipe[2] = { -1, -1 }; + gint child_pid_report_pipe[2] = { -1, -1 }; + gint status; + + if (!make_pipe (child_err_report_pipe, error)) + return FALSE; + + if (intermediate_child && !make_pipe (child_pid_report_pipe, error)) + goto cleanup_and_fail; + + if (standard_input && !make_pipe (stdin_pipe, error)) + goto cleanup_and_fail; + + if (standard_output && !make_pipe (stdout_pipe, error)) + goto cleanup_and_fail; + + if (standard_error && !make_pipe (stderr_pipe, error)) + goto cleanup_and_fail; + + pid = fork (); + + if (pid < 0) + { + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_FORK, + _("Failed to fork (%s)"), + g_strerror (errno)); + + goto cleanup_and_fail; + } + else if (pid == 0) + { + /* Immediate child. This may or may not be the child that + * actually execs the new process. + */ + + /* Be sure we crash if the parent exits + * and we write to the err_report_pipe + */ + signal (SIGPIPE, SIG_DFL); + + /* Close the parent's end of the pipes; + * not needed in the close_descriptors case, + * though + */ + close_and_invalidate (&child_err_report_pipe[0]); + close_and_invalidate (&child_pid_report_pipe[0]); + close_and_invalidate (&stdin_pipe[1]); + close_and_invalidate (&stdout_pipe[0]); + close_and_invalidate (&stderr_pipe[0]); + + if (intermediate_child) + { + /* We need to fork an intermediate child that launches the + * final child. The purpose of the intermediate child + * is to exit, so we can waitpid() it immediately. + * Then the grandchild will not become a zombie. + */ + gint grandchild_pid; + + grandchild_pid = fork (); + + if (grandchild_pid < 0) + { + /* report -1 as child PID */ + write (child_pid_report_pipe[1], &grandchild_pid, + sizeof(grandchild_pid)); + + write_err_and_exit (child_err_report_pipe[1], + CHILD_FORK_FAILED); + } + else if (grandchild_pid == 0) + { + do_exec (child_err_report_pipe[1], + stdin_pipe[0], + stdout_pipe[1], + stderr_pipe[1], + working_directory, + argv, + envp, + close_descriptors, + search_path, + stdout_to_null, + stderr_to_null, + child_inherits_stdin, + file_and_argv_zero, + child_setup, + user_data); + } + else + { + write (child_pid_report_pipe[1], &grandchild_pid, sizeof(grandchild_pid)); + close_and_invalidate (&child_pid_report_pipe[1]); + + _exit (0); + } + } + else + { + /* Just run the child. + */ + + do_exec (child_err_report_pipe[1], + stdin_pipe[0], + stdout_pipe[1], + stderr_pipe[1], + working_directory, + argv, + envp, + close_descriptors, + search_path, + stdout_to_null, + stderr_to_null, + child_inherits_stdin, + file_and_argv_zero, + child_setup, + user_data); + } + } + else + { + /* Parent */ + + gint buf[2]; + gint n_ints = 0; + + /* Close the uncared-about ends of the pipes */ + close_and_invalidate (&child_err_report_pipe[1]); + close_and_invalidate (&child_pid_report_pipe[1]); + close_and_invalidate (&stdin_pipe[0]); + close_and_invalidate (&stdout_pipe[1]); + close_and_invalidate (&stderr_pipe[1]); + + /* If we had an intermediate child, reap it */ + if (intermediate_child) + { + wait_again: + if (waitpid (pid, &status, 0) < 0) + { + if (errno == EINTR) + goto wait_again; + else if (errno == ECHILD) + ; /* do nothing, child already reaped */ + else + g_warning ("waitpid() should not fail in " + "'fork_exec_with_pipes'"); + } + } + + + if (!read_ints (child_err_report_pipe[0], + buf, 2, &n_ints, + error)) + goto cleanup_and_fail; + + if (n_ints >= 2) + { + /* Error from the child. */ + + switch (buf[0]) + { + case CHILD_CHDIR_FAILED: + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_CHDIR, + _("Failed to change to directory '%s' (%s)"), + working_directory, + g_strerror (buf[1])); + + break; + + case CHILD_EXEC_FAILED: + g_set_error (error, + G_SPAWN_ERROR, + exec_err_to_g_error (buf[1]), + _("Failed to execute child process (%s)"), + g_strerror (buf[1])); + + break; + + case CHILD_DUP2_FAILED: + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_FAILED, + _("Failed to redirect output or input of child process (%s)"), + g_strerror (buf[1])); + + break; + + case CHILD_FORK_FAILED: + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_FORK, + _("Failed to fork child process (%s)"), + g_strerror (buf[1])); + break; + + default: + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_FAILED, + _("Unknown error executing child process")); + break; + } + + goto cleanup_and_fail; + } + + /* Get child pid from intermediate child pipe. */ + if (intermediate_child) + { + n_ints = 0; + + if (!read_ints (child_pid_report_pipe[0], + buf, 1, &n_ints, error)) + goto cleanup_and_fail; + + if (n_ints < 1) + { + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_FAILED, + _("Failed to read enough data from child pid pipe (%s)"), + g_strerror (errno)); + goto cleanup_and_fail; + } + else + { + /* we have the child pid */ + pid = buf[0]; + } + } + + /* Success against all odds! return the information */ + + if (child_pid) + *child_pid = pid; + + if (standard_input) + *standard_input = stdin_pipe[1]; + if (standard_output) + *standard_output = stdout_pipe[0]; + if (standard_error) + *standard_error = stderr_pipe[0]; + + return TRUE; + } + + cleanup_and_fail: + close_and_invalidate (&child_err_report_pipe[0]); + close_and_invalidate (&child_err_report_pipe[1]); + close_and_invalidate (&child_pid_report_pipe[0]); + close_and_invalidate (&child_pid_report_pipe[1]); + close_and_invalidate (&stdin_pipe[0]); + close_and_invalidate (&stdin_pipe[1]); + close_and_invalidate (&stdout_pipe[0]); + close_and_invalidate (&stdout_pipe[1]); + close_and_invalidate (&stderr_pipe[0]); + close_and_invalidate (&stderr_pipe[1]); + + return FALSE; +} + +static gboolean +make_pipe (gint p[2], + GError **error) +{ + if (pipe (p) < 0) + { + g_set_error (error, + G_SPAWN_ERROR, + G_SPAWN_ERROR_FAILED, + _("Failed to create pipe for communicating with child process (%s)"), + g_strerror (errno)); + return FALSE; + } + else + return TRUE; +} + +/* Based on execvp from GNU C Library */ + +static void +script_execute (const gchar *file, + gchar **argv, + gchar **envp, + gboolean search_path) +{ + /* Count the arguments. */ + int argc = 0; + while (argv[argc]) + ++argc; + + /* Construct an argument list for the shell. */ + { + gchar **new_argv; + + new_argv = g_new0 (gchar*, argc + 1); + + new_argv[0] = (char *) "/bin/sh"; + new_argv[1] = (char *) file; + while (argc > 1) + { + new_argv[argc] = argv[argc - 1]; + --argc; + } + + /* Execute the shell. */ + if (envp) + execve (new_argv[0], new_argv, envp); + else + execv (new_argv[0], new_argv); + + g_free (new_argv); + } +} + +static gchar* +my_strchrnul (const gchar *str, gchar c) +{ + gchar *p = (gchar*) str; + while (*p && (*p != c)) + ++p; + + return p; +} + +static gint +g_execute (const gchar *file, + gchar **argv, + gchar **envp, + gboolean search_path) +{ + if (*file == '\0') + { + /* We check the simple case first. */ + errno = ENOENT; + return -1; + } + + if (!search_path || strchr (file, '/') != NULL) + { + /* Don't search when it contains a slash. */ + if (envp) + execve (file, argv, envp); + else + execv (file, argv); + + if (errno == ENOEXEC) + script_execute (file, argv, envp, FALSE); + } + else + { + gboolean got_eacces = 0; + const gchar *path, *p; + gchar *name, *freeme; + size_t len; + size_t pathlen; + + path = g_getenv ("PATH"); + if (path == NULL) + { + /* There is no `PATH' in the environment. The default + * search path in libc is the current directory followed by + * the path `confstr' returns for `_CS_PATH'. + */ + + /* In GLib we put . last, for security, and don't use the + * unportable confstr(); UNIX98 does not actually specify + * what to search if PATH is unset. POSIX may, dunno. + */ + + path = "/bin:/usr/bin:."; + } + + len = strlen (file) + 1; + pathlen = strlen (path); + freeme = name = g_malloc (pathlen + len + 1); + + /* Copy the file name at the top, including '\0' */ + memcpy (name + pathlen + 1, file, len); + name = name + pathlen; + /* And add the slash before the filename */ + *name = '/'; + + p = path; + do + { + char *startp; + + path = p; + p = my_strchrnul (path, ':'); + + if (p == path) + /* Two adjacent colons, or a colon at the beginning or the end + * of `PATH' means to search the current directory. + */ + startp = name + 1; + else + startp = memcpy (name - (p - path), path, p - path); + + /* Try to execute this name. If it works, execv will not return. */ + if (envp) + execve (startp, argv, envp); + else + execv (startp, argv); + + if (errno == ENOEXEC) + script_execute (startp, argv, envp, search_path); + + switch (errno) + { + case EACCES: + /* Record the we got a `Permission denied' error. If we end + * up finding no executable we can use, we want to diagnose + * that we did find one but were denied access. + */ + got_eacces = TRUE; + + /* FALL THRU */ + + case ENOENT: +#ifdef ESTALE + case ESTALE: +#endif +#ifdef ENOTDIR + case ENOTDIR: +#endif + /* Those errors indicate the file is missing or not executable + * by us, in which case we want to just try the next path + * directory. + */ + break; + + default: + /* Some other error means we found an executable file, but + * something went wrong executing it; return the error to our + * caller. + */ + g_free (freeme); + return -1; + } + } + while (*p++ != '\0'); + + /* We tried every element and none of them worked. */ + if (got_eacces) + /* At least one failure was due to permissions, so report that + * error. + */ + errno = EACCES; + + g_free (freeme); + } + + /* Return the error from the last attempt (probably ENOENT). */ + return -1; +} diff --git a/graf2d/win32gdk/gdk/src/glib/gspawn.h b/graf2d/win32gdk/gdk/src/glib/gspawn.h index 57530cb6d4bd8..795bb3ce6425a 100644 --- a/graf2d/win32gdk/gdk/src/glib/gspawn.h +++ b/graf2d/win32gdk/gdk/src/glib/gspawn.h @@ -21,7 +21,7 @@ #ifndef __G_SPAWN_H__ #define __G_SPAWN_H__ -#include <gerror.h> +#include <glib/gerror.h> G_BEGIN_DECLS @@ -59,13 +59,14 @@ typedef void (* GSpawnChildSetupFunc) (gpointer user_data); typedef enum { G_SPAWN_LEAVE_DESCRIPTORS_OPEN = 1 << 0, - G_SPAWN_DO_NOT_REAP_CHILD = 1 << 1, + G_SPAWN_DO_NOT_REAP_CHILD = 1 << 1, /* look for argv[0] in the path i.e. use execvp() */ - G_SPAWN_SEARCH_PATH = 1 << 2, + G_SPAWN_SEARCH_PATH = 1 << 2, /* Dump output to /dev/null */ - G_SPAWN_STDOUT_TO_DEV_NULL = 1 << 3, - G_SPAWN_STDERR_TO_DEV_NULL = 1 << 4, - G_SPAWN_CHILD_INHERITS_STDIN = 1 << 5 + G_SPAWN_STDOUT_TO_DEV_NULL = 1 << 3, + G_SPAWN_STDERR_TO_DEV_NULL = 1 << 4, + G_SPAWN_CHILD_INHERITS_STDIN = 1 << 5, + G_SPAWN_FILE_AND_ARGV_ZERO = 1 << 6 } GSpawnFlags; GQuark g_spawn_error_quark (void); diff --git a/graf2d/win32gdk/gdk/src/glib/gstrfuncs.c b/graf2d/win32gdk/gdk/src/glib/gstrfuncs.c new file mode 100644 index 0000000000000..94e96f187bf67 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gstrfuncs.c @@ -0,0 +1,1428 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#define _GNU_SOURCE /* For stpcpy */ + +#include <stdarg.h> +#include <stdio.h> +#include <stdlib.h> +#include <string.h> +#include <locale.h> +#include <ctype.h> /* For tolower() */ +#if !defined (HAVE_STRSIGNAL) || !defined(NO_SYS_SIGLIST_DECL) +#include <signal.h> +#endif +#include "glib.h" + +#ifdef G_OS_WIN32 +#include <windows.h> +#endif + +/* do not include <unistd.h> in this place since it + * inteferes with g_strsignal() on some OSes + */ + +static const guint16 ascii_table_data[256] = { + 0x004, 0x004, 0x004, 0x004, 0x004, 0x004, 0x004, 0x004, + 0x004, 0x104, 0x104, 0x004, 0x104, 0x104, 0x004, 0x004, + 0x004, 0x004, 0x004, 0x004, 0x004, 0x004, 0x004, 0x004, + 0x004, 0x004, 0x004, 0x004, 0x004, 0x004, 0x004, 0x004, + 0x140, 0x0d0, 0x0d0, 0x0d0, 0x0d0, 0x0d0, 0x0d0, 0x0d0, + 0x0d0, 0x0d0, 0x0d0, 0x0d0, 0x0d0, 0x0d0, 0x0d0, 0x0d0, + 0x459, 0x459, 0x459, 0x459, 0x459, 0x459, 0x459, 0x459, + 0x459, 0x459, 0x0d0, 0x0d0, 0x0d0, 0x0d0, 0x0d0, 0x0d0, + 0x0d0, 0x653, 0x653, 0x653, 0x653, 0x653, 0x653, 0x253, + 0x253, 0x253, 0x253, 0x253, 0x253, 0x253, 0x253, 0x253, + 0x253, 0x253, 0x253, 0x253, 0x253, 0x253, 0x253, 0x253, + 0x253, 0x253, 0x253, 0x0d0, 0x0d0, 0x0d0, 0x0d0, 0x0d0, + 0x0d0, 0x473, 0x473, 0x473, 0x473, 0x473, 0x473, 0x073, + 0x073, 0x073, 0x073, 0x073, 0x073, 0x073, 0x073, 0x073, + 0x073, 0x073, 0x073, 0x073, 0x073, 0x073, 0x073, 0x073, + 0x073, 0x073, 0x073, 0x0d0, 0x0d0, 0x0d0, 0x0d0, 0x004 + /* the upper 128 are all zeroes */ +}; + +#if defined(G_PLATFORM_WIN32) && defined(__GNUC__) +__declspec(dllexport) +#endif +const guint16 * const g_ascii_table = ascii_table_data; + +gchar* +g_strdup (const gchar *str) +{ + gchar *new_str; + + if (str) + { + new_str = g_new (char, strlen (str) + 1); + strcpy (new_str, str); + } + else + new_str = NULL; + + return new_str; +} + +gpointer +g_memdup (gconstpointer mem, + guint byte_size) +{ + gpointer new_mem; + + if (mem) + { + new_mem = g_malloc (byte_size); + memcpy (new_mem, mem, byte_size); + } + else + new_mem = NULL; + + return new_mem; +} + +gchar* +g_strndup (const gchar *str, + gsize n) +{ + gchar *new_str; + + if (str) + { + new_str = g_new (gchar, n + 1); + strncpy (new_str, str, n); + new_str[n] = '\0'; + } + else + new_str = NULL; + + return new_str; +} + +gchar* +g_strnfill (gsize length, + gchar fill_char) +{ + register gchar *str, *s, *end; + + str = g_new (gchar, length + 1); + s = str; + end = str + length; + while (s < end) + *(s++) = fill_char; + *s = 0; + + return str; +} + +/** + * g_stpcpy: + * @dest: destination buffer + * @src: source string + * + * Copies a nul-terminated string into the dest buffer, include the + * trailing nul, and return a pointer to the trailing nul byte. + * This is useful for concatenating multiple strings together + * without having to repeatedly scan for the end. + * + * Return value: a pointer to trailing nul byte. + **/ +gchar * +g_stpcpy (gchar *dest, + const gchar *src) +{ +#ifdef HAVE_STPCPY + g_return_val_if_fail (dest != NULL, NULL); + g_return_val_if_fail (src != NULL, NULL); + return stpcpy (dest, src); +#else + register gchar *d = dest; + register const gchar *s = src; + + g_return_val_if_fail (dest != NULL, NULL); + g_return_val_if_fail (src != NULL, NULL); + do + *d++ = *s; + while (*s++ != '\0'); + + return d - 1; +#endif +} + +gchar* +g_strdup_vprintf (const gchar *format, + va_list args1) +{ + gchar *buffer; +#ifdef HAVE_VASPRINTF + vasprintf (&buffer, format, args1); + if (g_mem_is_system_malloc ()) + { + gchar *buffer1 = g_strdup (buffer); + free (buffer); + buffer = buffer1; + } +#else + va_list args2; + + G_VA_COPY (args2, args1); + + buffer = g_new (gchar, g_printf_string_upper_bound (format, args1)); + + vsprintf (buffer, format, args2); + va_end (args2); +#endif + return buffer; +} + +gchar* +g_strdup_printf (const gchar *format, + ...) +{ + gchar *buffer; + va_list args; + + va_start (args, format); + buffer = g_strdup_vprintf (format, args); + va_end (args); + + return buffer; +} + +gchar* +g_strconcat (const gchar *string1, ...) +{ + gsize l; + va_list args; + gchar *s; + gchar *concat; + gchar *ptr; + + g_return_val_if_fail (string1 != NULL, NULL); + + l = 1 + strlen (string1); + va_start (args, string1); + s = va_arg (args, gchar*); + while (s) + { + l += strlen (s); + s = va_arg (args, gchar*); + } + va_end (args); + + concat = g_new (gchar, l); + ptr = concat; + + ptr = g_stpcpy (ptr, string1); + va_start (args, string1); + s = va_arg (args, gchar*); + while (s) + { + ptr = g_stpcpy (ptr, s); + s = va_arg (args, gchar*); + } + va_end (args); + + return concat; +} + +gdouble +g_strtod (const gchar *nptr, + gchar **endptr) +{ + gchar *fail_pos_1; + gchar *fail_pos_2; + gdouble val_1; + gdouble val_2 = 0; + + g_return_val_if_fail (nptr != NULL, 0); + + fail_pos_1 = NULL; + fail_pos_2 = NULL; + + val_1 = strtod (nptr, &fail_pos_1); + + if (fail_pos_1 && fail_pos_1[0] != 0) + { + gchar *old_locale; + + old_locale = g_strdup (setlocale (LC_NUMERIC, NULL)); + setlocale (LC_NUMERIC, "C"); + val_2 = strtod (nptr, &fail_pos_2); + setlocale (LC_NUMERIC, old_locale); + g_free (old_locale); + } + + if (!fail_pos_1 || fail_pos_1[0] == 0 || fail_pos_1 >= fail_pos_2) + { + if (endptr) + *endptr = fail_pos_1; + return val_1; + } + else + { + if (endptr) + *endptr = fail_pos_2; + return val_2; + } +} + +G_CONST_RETURN gchar* +g_strerror (gint errnum) +{ + static GStaticPrivate msg_private = G_STATIC_PRIVATE_INIT; + char *msg; + + // + // Removed a lot fo code as errors are not common on windows that actually would mean anythign here... + // + + msg = g_static_private_get (&msg_private); + if (!msg) + { + msg = g_new (gchar, 64); + g_static_private_set (&msg_private, msg, g_free); + } + + sprintf (msg, "unknown error (%d)", errnum); + + return msg; +} + +G_CONST_RETURN gchar* +g_strsignal (gint signum) +{ + static GStaticPrivate msg_private = G_STATIC_PRIVATE_INIT; + char *msg; + + // + // A lot of code removed by GTW - this will be building only on win32, and signals are... not really the thing + // here! + // + + msg = g_static_private_get (&msg_private); + if (!msg) + { + msg = g_new (gchar, 64); + g_static_private_set (&msg_private, msg, g_free); + } + + sprintf (msg, "unknown signal (%d)", signum); + + return msg; +} + +/* Functions g_strlcpy and g_strlcat were originally developed by + * Todd C. Miller <Todd.Miller@courtesan.com> to simplify writing secure code. + * See ftp://ftp.openbsd.org/pub/OpenBSD/src/lib/libc/string/strlcpy.3 + * for more information. + */ + +#ifdef HAVE_STRLCPY +/* Use the native ones, if available; they might be implemented in assembly */ +gsize +g_strlcpy (gchar *dest, + const gchar *src, + gsize dest_size) +{ + g_return_val_if_fail (dest != NULL, 0); + g_return_val_if_fail (src != NULL, 0); + + return strlcpy (dest, src, dest_size); +} + +gsize +g_strlcat (gchar *dest, + const gchar *src, + gsize dest_size) +{ + g_return_val_if_fail (dest != NULL, 0); + g_return_val_if_fail (src != NULL, 0); + + return strlcat (dest, src, dest_size); +} + +#else /* ! HAVE_STRLCPY */ +/* g_strlcpy + * + * Copy string src to buffer dest (of buffer size dest_size). At most + * dest_size-1 characters will be copied. Always NUL terminates + * (unless dest_size == 0). This function does NOT allocate memory. + * Unlike strncpy, this function doesn't pad dest (so it's often faster). + * Returns size of attempted result, strlen(src), + * so if retval >= dest_size, truncation occurred. + */ +gsize +g_strlcpy (gchar *dest, + const gchar *src, + gsize dest_size) +{ + register gchar *d = dest; + register const gchar *s = src; + register gsize n = dest_size; + + g_return_val_if_fail (dest != NULL, 0); + g_return_val_if_fail (src != NULL, 0); + + /* Copy as many bytes as will fit */ + if (n != 0 && --n != 0) + do + { + register gchar c = *s++; + + *d++ = c; + if (c == 0) + break; + } + while (--n != 0); + + /* If not enough room in dest, add NUL and traverse rest of src */ + if (n == 0) + { + if (dest_size != 0) + *d = 0; + while (*s++) + ; + } + + return s - src - 1; /* count does not include NUL */ +} + +/* g_strlcat + * + * Appends string src to buffer dest (of buffer size dest_size). + * At most dest_size-1 characters will be copied. + * Unlike strncat, dest_size is the full size of dest, not the space left over. + * This function does NOT allocate memory. + * This always NUL terminates (unless siz == 0 or there were no NUL characters + * in the dest_size characters of dest to start with). + * Returns size of attempted result, which is + * MIN (dest_size, strlen (original dest)) + strlen (src), + * so if retval >= dest_size, truncation occurred. + */ +gsize +g_strlcat (gchar *dest, + const gchar *src, + gsize dest_size) +{ + register gchar *d = dest; + register const gchar *s = src; + register gsize bytes_left = dest_size; + gsize dlength; /* Logically, MIN (strlen (d), dest_size) */ + + g_return_val_if_fail (dest != NULL, 0); + g_return_val_if_fail (src != NULL, 0); + + /* Find the end of dst and adjust bytes left but don't go past end */ + while (*d != 0 && bytes_left-- != 0) + d++; + dlength = d - dest; + bytes_left = dest_size - dlength; + + if (bytes_left == 0) + return dlength + strlen (s); + + while (*s != 0) + { + if (bytes_left != 1) + { + *d++ = *s; + bytes_left--; + } + s++; + } + *d = 0; + + return dlength + (s - src); /* count does not include NUL */ +} +#endif /* ! HAVE_STRLCPY */ + +/** + * g_ascii_strdown: + * @str: a string + * @len: length of @str in bytes, or -1 if @str is nul-terminated. + * + * Converts all upper case ASCII letters to lower case ASCII letters. + * + * Return value: a newly allocated string, with all the upper case + * characters in @str converted to lower case, with + * semantics that exactly match g_ascii_tolower. (Note + * that this is unlike the old g_strdown, which modified + * the string in place.) + **/ +gchar* +g_ascii_strdown (const gchar *str, + gint len) +{ + gchar *result, *s; + + g_return_val_if_fail (str != NULL, NULL); + + if (len < 0) + len = strlen (str); + + result = g_strndup (str, len); + for (s = result; *s; s++) + *s = g_ascii_tolower (*s); + + return result; +} + +/** + * g_ascii_strup: + * @str: a string + * @len: length of @str in bytes, or -1 if @str is nul-terminated. + * + * Converts all lower case ASCII letters to upper case ASCII letters. + * + * Return value: a newly allocated string, with all the lower case + * characters in @str converted to upper case, with + * semantics that exactly match g_ascii_toupper. (Note + * that this is unlike the old g_strup, which modified + * the string in place.) + **/ +gchar* +g_ascii_strup (const gchar *str, + gint len) +{ + gchar *result, *s; + + g_return_val_if_fail (str != NULL, NULL); + + if (len < 0) + len = strlen (str); + + result = g_strndup (str, len); + for (s = result; *s; s++) + *s = g_ascii_toupper (*s); + + return result; +} + +gchar* +g_strdown (gchar *string) +{ + register guchar *s; + + g_return_val_if_fail (string != NULL, NULL); + + s = (guchar *) string; + + while (*s) + { + if (isupper (*s)) + *s = tolower (*s); + s++; + } + + return (gchar *) string; +} + +gchar* +g_strup (gchar *string) +{ + register guchar *s; + + g_return_val_if_fail (string != NULL, NULL); + + s = (guchar *) string; + + while (*s) + { + if (islower (*s)) + *s = toupper (*s); + s++; + } + + return (gchar *) string; +} + +gchar* +g_strreverse (gchar *string) +{ + g_return_val_if_fail (string != NULL, NULL); + + if (*string) + { + register gchar *h, *t; + + h = string; + t = string + strlen (string) - 1; + + while (h < t) + { + register gchar c; + + c = *h; + *h = *t; + h++; + *t = c; + t--; + } + } + + return string; +} + +/** + * g_ascii_tolower: + * @c: any character + * + * Convert a character to ASCII lower case. + * + * Unlike the standard C library tolower function, this only + * recognizes standard ASCII letters and ignores the locale, returning + * all non-ASCII characters unchanged, even if they are lower case + * letters in a particular character set. Also unlike the standard + * library function, this takes and returns a char, not an int, so + * don't call it on EOF but no need to worry about casting to guchar + * before passing a possibly non-ASCII character in. + * + * Return value: the result of converting @c to lower case. + * If @c is not an ASCII upper case letter, + * @c is returned unchanged. + **/ +gchar +g_ascii_tolower (gchar c) +{ + return g_ascii_isupper (c) ? c - 'A' + 'a' : c; +} + +/** + * g_ascii_toupper: + * @c: any character + * + * Convert a character to ASCII upper case. + * + * Unlike the standard C library toupper function, this only + * recognizes standard ASCII letters and ignores the locale, returning + * all non-ASCII characters unchanged, even if they are upper case + * letters in a particular character set. Also unlike the standard + * library function, this takes and returns a char, not an int, so + * don't call it on EOF but no need to worry about casting to guchar + * before passing a possibly non-ASCII character in. + * + * Return value: the result of converting @c to upper case. + * If @c is not an ASCII lower case letter, + * @c is returned unchanged. + **/ +gchar +g_ascii_toupper (gchar c) +{ + return g_ascii_islower (c) ? c - 'a' + 'A' : c; +} + +/** + * g_ascii_digit_value: + * @c: an ASCII character + * + * Determines the numeric value of a character as a decimal + * digit. Differs from g_unichar_digit_value because it takes + * a char, so there's no worry about sign extension if characters + * are signed. + * + * Return value: If @c is a decimal digit (according to + * `g_ascii_isdigit'), its numeric value. Otherwise, -1. + **/ +int +g_ascii_digit_value (gchar c) +{ + if (g_ascii_isdigit (c)) + return c - '0'; + return -1; +} + +/** + * g_ascii_xdigit_value: + * @c: an ASCII character + * + * Determines the numeric value of a character as a hexidecimal + * digit. Differs from g_unichar_xdigit_value because it takes + * a char, so there's no worry about sign extension if characters + * are signed. + * + * Return value: If @c is a hex digit (according to + * `g_ascii_isxdigit'), its numeric value. Otherwise, -1. + **/ +int +g_ascii_xdigit_value (gchar c) +{ + if (c >= 'A' && c <= 'F') + return c - 'A' + 10; + if (c >= 'a' && c <= 'f') + return c - 'a' + 10; + return g_ascii_digit_value (c); +} + +/** + * g_ascii_strcasecmp: + * @s1: string to compare with @s2 + * @s2: string to compare with @s1 + * + * Compare two strings, ignoring the case of ASCII characters. + * + * Unlike the BSD strcasecmp function, this only recognizes standard + * ASCII letters and ignores the locale, treating all non-ASCII + * characters as if they are not letters. + * + * Return value: an integer less than, equal to, or greater than + * zero if @s1 is found, respectively, to be less than, + * to match, or to be greater than @s2. + **/ +gint +g_ascii_strcasecmp (const gchar *s1, + const gchar *s2) +{ + gint c1, c2; + + g_return_val_if_fail (s1 != NULL, 0); + g_return_val_if_fail (s2 != NULL, 0); + + while (*s1 && *s2) + { + c1 = (gint)(guchar) g_ascii_tolower (*s1); + c2 = (gint)(guchar) g_ascii_tolower (*s2); + if (c1 != c2) + return (c1 - c2); + s1++; s2++; + } + + return (((gint)(guchar) *s1) - ((gint)(guchar) *s2)); +} + +/** + * g_ascii_strncasecmp: + * @s1: string to compare with @s2 + * @s2: string to compare with @s1 + * @n: number of characters to compare + * + * Compare @s1 and @s2, ignoring the case of ASCII characters and any + * characters after the first @n in each string. + * + * Unlike the BSD strcasecmp function, this only recognizes standard + * ASCII letters and ignores the locale, treating all non-ASCII + * characters as if they are not letters. + * + * Return value: an integer less than, equal to, or greater than zero + * if the first @n bytes of @s1 is found, respectively, + * to be less than, to match, or to be greater than the + * first @n bytes of @s2. + **/ +gint +g_ascii_strncasecmp (const gchar *s1, + const gchar *s2, + guint n) +{ + gint c1, c2; + + g_return_val_if_fail (s1 != NULL, 0); + g_return_val_if_fail (s2 != NULL, 0); + + while (n && *s1 && *s2) + { + n -= 1; + c1 = (gint)(guchar) g_ascii_tolower (*s1); + c2 = (gint)(guchar) g_ascii_tolower (*s2); + if (c1 != c2) + return (c1 - c2); + s1++; s2++; + } + + if (n) + return (((gint) (guchar) *s1) - ((gint) (guchar) *s2)); + else + return 0; +} + +gint +g_strcasecmp (const gchar *s1, + const gchar *s2) +{ +#ifdef HAVE_STRCASECMP + g_return_val_if_fail (s1 != NULL, 0); + g_return_val_if_fail (s2 != NULL, 0); + + return strcasecmp (s1, s2); +#else + gint c1, c2; + + g_return_val_if_fail (s1 != NULL, 0); + g_return_val_if_fail (s2 != NULL, 0); + + while (*s1 && *s2) + { + /* According to A. Cox, some platforms have islower's that + * don't work right on non-uppercase + */ + c1 = isupper ((guchar)*s1) ? tolower ((guchar)*s1) : *s1; + c2 = isupper ((guchar)*s2) ? tolower ((guchar)*s2) : *s2; + if (c1 != c2) + return (c1 - c2); + s1++; s2++; + } + + return (((gint)(guchar) *s1) - ((gint)(guchar) *s2)); +#endif +} + +gint +g_strncasecmp (const gchar *s1, + const gchar *s2, + gsize n) +{ +#ifdef HAVE_STRNCASECMP + return strncasecmp (s1, s2, n); +#else + gint c1, c2; + + g_return_val_if_fail (s1 != NULL, 0); + g_return_val_if_fail (s2 != NULL, 0); + + while (n && *s1 && *s2) + { + n -= 1; + /* According to A. Cox, some platforms have islower's that + * don't work right on non-uppercase + */ + c1 = isupper ((guchar)*s1) ? tolower ((guchar)*s1) : *s1; + c2 = isupper ((guchar)*s2) ? tolower ((guchar)*s2) : *s2; + if (c1 != c2) + return (c1 - c2); + s1++; s2++; + } + + if (n) + return (((gint) (guchar) *s1) - ((gint) (guchar) *s2)); + else + return 0; +#endif +} + +gchar* +g_strdelimit (gchar *string, + const gchar *delimiters, + gchar new_delim) +{ + register gchar *c; + + g_return_val_if_fail (string != NULL, NULL); + + if (!delimiters) + delimiters = G_STR_DELIMITERS; + + for (c = string; *c; c++) + { + if (strchr (delimiters, *c)) + *c = new_delim; + } + + return string; +} + +gchar* +g_strcanon (gchar *string, + const gchar *valid_chars, + gchar substitutor) +{ + register gchar *c; + + g_return_val_if_fail (string != NULL, NULL); + g_return_val_if_fail (valid_chars != NULL, NULL); + + for (c = string; *c; c++) + { + if (!strchr (valid_chars, *c)) + *c = substitutor; + } + + return string; +} + +gchar* +g_strcompress (const gchar *source) +{ + const gchar *p = source, *octal; + gchar *dest = g_malloc (strlen (source) + 1); + gchar *q = dest; + + while (*p) + { + if (*p == '\\') + { + p++; + switch (*p) + { + case '0': case '1': case '2': case '3': case '4': + case '5': case '6': case '7': + *q = 0; + octal = p; + while ((p < octal + 3) && (*p >= '0') && (*p <= '7')) + { + *q = (*q * 8) + (*p - '0'); + p++; + } + q++; + p--; + break; + case 'b': + *q++ = '\b'; + break; + case 'f': + *q++ = '\f'; + break; + case 'n': + *q++ = '\n'; + break; + case 'r': + *q++ = '\r'; + break; + case 't': + *q++ = '\t'; + break; + default: /* Also handles \" and \\ */ + *q++ = *p; + break; + } + } + else + *q++ = *p; + p++; + } + *q = 0; + + return dest; +} + +gchar * +g_strescape (const gchar *source, + const gchar *exceptions) +{ + const guchar *p; + gchar *dest; + gchar *q; + guchar excmap[256]; + + g_return_val_if_fail (source != NULL, NULL); + + p = (guchar *) source; + /* Each source byte needs maximally four destination chars (\777) */ + q = dest = g_malloc (strlen (source) * 4 + 1); + + memset (excmap, 0, 256); + if (exceptions) + { + guchar *e = (guchar *) exceptions; + + while (*e) + { + excmap[*e] = 1; + e++; + } + } + + while (*p) + { + if (excmap[*p]) + *q++ = *p; + else + { + switch (*p) + { + case '\b': + *q++ = '\\'; + *q++ = 'b'; + break; + case '\f': + *q++ = '\\'; + *q++ = 'f'; + break; + case '\n': + *q++ = '\\'; + *q++ = 'n'; + break; + case '\r': + *q++ = '\\'; + *q++ = 'r'; + break; + case '\t': + *q++ = '\\'; + *q++ = 't'; + break; + case '\\': + *q++ = '\\'; + *q++ = '\\'; + break; + case '"': + *q++ = '\\'; + *q++ = '"'; + break; + default: + if ((*p < ' ') || (*p >= 0177)) + { + *q++ = '\\'; + *q++ = '0' + (((*p) >> 6) & 07); + *q++ = '0' + (((*p) >> 3) & 07); + *q++ = '0' + ((*p) & 07); + } + else + *q++ = *p; + break; + } + } + p++; + } + *q = 0; + return dest; +} + +gchar* +g_strchug (gchar *string) +{ + guchar *start; + + g_return_val_if_fail (string != NULL, NULL); + + for (start = (guchar*) string; *start && g_ascii_isspace (*start); start++) + ; + + g_memmove (string, start, strlen ((gchar *) start) + 1); + + return string; +} + +gchar* +g_strchomp (gchar *string) +{ + gchar *s; + + g_return_val_if_fail (string != NULL, NULL); + + if (!*string) + return string; + + for (s = string + strlen (string) - 1; s >= string && g_ascii_isspace ((guchar)*s); + s--) + *s = '\0'; + + return string; +} + +/** + * g_strsplit: + * @string: a string to split. + * @delimiter: a string which specifies the places at which to split the string. + * The delimiter is not included in any of the resulting strings, unless + * max_tokens is reached. + * @max_tokens: the maximum number of pieces to split @string into. If this is + * less than 1, the string is split completely. + * + * Splits a string into a maximum of @max_tokens pieces, using the given + * @delimiter. If @max_tokens is reached, the remainder of @string is appended + * to the last token. + * + * As a special case, the result of splitting the empty string "" is an empty + * vector, not a vector containing a single string. The reason for this + * special case is that being able to represent a empty vector is typically + * more useful than consistent handling of empty elements. If you do need + * to represent empty elements, you'll need to check for the empty string + * before calling g_strsplit(). + * + * Return value: a newly-allocated %NULL-terminated array of strings. Use g_strfreev() + * to free it. + **/ +gchar** +g_strsplit (const gchar *string, + const gchar *delimiter, + gint max_tokens) +{ + GSList *string_list = NULL, *slist; + gchar **str_array, *s; + guint n = 0; + const gchar *remainder; + + g_return_val_if_fail (string != NULL, NULL); + g_return_val_if_fail (delimiter != NULL, NULL); + g_return_val_if_fail (delimiter[0] != '\0', NULL); + + if (max_tokens < 1) + max_tokens = G_MAXINT; + else + --max_tokens; + + remainder = string; + s = strstr (remainder, delimiter); + if (s) + { + gsize delimiter_len = strlen (delimiter); + + do + { + gsize len; + gchar *new_string; + + len = s - remainder; + new_string = g_new (gchar, len + 1); + strncpy (new_string, remainder, len); + new_string[len] = 0; + string_list = g_slist_prepend (string_list, new_string); + n++; + remainder = s + delimiter_len; + s = strstr (remainder, delimiter); + } + while (--max_tokens && s); + } + if (*string) + { + n++; + string_list = g_slist_prepend (string_list, g_strdup (remainder)); + } + + str_array = g_new (gchar*, n + 1); + + str_array[n--] = NULL; + for (slist = string_list; slist; slist = slist->next) + str_array[n--] = slist->data; + + g_slist_free (string_list); + + return str_array; +} + +void +g_strfreev (gchar **str_array) +{ + if (str_array) + { + int i; + + for(i = 0; str_array[i] != NULL; i++) + g_free(str_array[i]); + + g_free (str_array); + } +} + +/** + * g_strdupv: + * @str_array: %NULL-terminated array of strings + * + * Copies %NULL-terminated array of strings. The copy is a deep copy; + * the new array should be freed by first freeing each string, then + * the array itself. g_strfreev() does this for you. If called + * on a %NULL value, g_strdupv() simply returns %NULL. + * + * Return value: a new %NULL-terminated array of strings + **/ +gchar** +g_strdupv (gchar **str_array) +{ + if (str_array) + { + gint i; + gchar **retval; + + i = 0; + while (str_array[i]) + ++i; + + retval = g_new (gchar*, i + 1); + + i = 0; + while (str_array[i]) + { + retval[i] = g_strdup (str_array[i]); + ++i; + } + retval[i] = NULL; + + return retval; + } + else + return NULL; +} + +gchar* +g_strjoinv (const gchar *separator, + gchar **str_array) +{ + gchar *string; + gchar *ptr; + + g_return_val_if_fail (str_array != NULL, NULL); + + if (separator == NULL) + separator = ""; + + if (*str_array) + { + gint i; + gsize len; + gsize separator_len; + + separator_len = strlen (separator); + /* First part, getting length */ + len = 1 + strlen (str_array[0]); + for (i = 1; str_array[i] != NULL; i++) + len += strlen (str_array[i]); + len += separator_len * (i - 1); + + /* Second part, building string */ + string = g_new (gchar, len); + ptr = g_stpcpy (string, *str_array); + for (i = 1; str_array[i] != NULL; i++) + { + ptr = g_stpcpy (ptr, separator); + ptr = g_stpcpy (ptr, str_array[i]); + } + } + else + string = g_strdup (""); + + return string; +} + +gchar* +g_strjoin (const gchar *separator, + ...) +{ + gchar *string, *s; + va_list args; + gsize len; + gsize separator_len; + gchar *ptr; + + if (separator == NULL) + separator = ""; + + separator_len = strlen (separator); + + va_start (args, separator); + + s = va_arg (args, gchar*); + + if (s) + { + /* First part, getting length */ + len = 1 + strlen (s); + + s = va_arg (args, gchar*); + while (s) + { + len += separator_len + strlen (s); + s = va_arg (args, gchar*); + } + va_end (args); + + /* Second part, building string */ + string = g_new (gchar, len); + + va_start (args, separator); + + s = va_arg (args, gchar*); + ptr = g_stpcpy (string, s); + + s = va_arg (args, gchar*); + while (s) + { + ptr = g_stpcpy (ptr, separator); + ptr = g_stpcpy (ptr, s); + s = va_arg (args, gchar*); + } + } + else + string = g_strdup (""); + + va_end (args); + + return string; +} + + +/** + * g_strstr_len: + * @haystack: a string + * @haystack_len: The maximum length of haystack + * @needle: The string to search for. + * + * Searches the string haystack for the first occurrence + * of the string needle, limiting the length of the search + * to haystack_len. + * + * Return value: A pointer to the found occurrence, or + * NULL if not found. + **/ +gchar * +g_strstr_len (const gchar *haystack, + gssize haystack_len, + const gchar *needle) +{ + g_return_val_if_fail (haystack != NULL, NULL); + g_return_val_if_fail (needle != NULL, NULL); + + if (haystack_len < 0) + return strstr (haystack, needle); + else + { + const gchar *p = haystack; + gsize needle_len = strlen (needle); + const gchar *end; + gsize i; + + if (needle_len == 0) + return (gchar *)haystack; + + if (haystack_len < needle_len) + return NULL; + + end = haystack + haystack_len - needle_len; + + while (*p && p <= end) + { + for (i = 0; i < needle_len; i++) + if (p[i] != needle[i]) + goto next; + + return (gchar *)p; + + next: + p++; + } + + return NULL; + } +} + +/** + * g_strrstr_len: + * @haystack: a nul-terminated string + * @needle: The nul-terminated string to search for. + * + * Searches the string haystack for the last occurrence + * of the string needle. + * + * Return value: A pointer to the found occurrence, or + * NULL if not found. + **/ +gchar * +g_strrstr (const gchar *haystack, + const gchar *needle) +{ + gsize i; + gsize needle_len; + gsize haystack_len; + const gchar *p; + + g_return_val_if_fail (haystack != NULL, NULL); + g_return_val_if_fail (needle != NULL, NULL); + + needle_len = strlen (needle); + haystack_len = strlen (haystack); + + if (needle_len == 0) + return (gchar *)haystack; + + if (haystack_len < needle_len) + return NULL; + + p = haystack + haystack_len - needle_len; + + while (p >= haystack) + { + for (i = 0; i < needle_len; i++) + if (p[i] != needle[i]) + goto next; + + return (gchar *)p; + + next: + p--; + } + + return NULL; +} + +/** + * g_strrstr_len: + * @haystack: a nul-terminated string + * @haystack_len: The maximum length of haystack + * @needle: The nul-terminated string to search for. + * + * Searches the string haystack for the last occurrence + * of the string needle, limiting the length of the search + * to haystack_len. + * + * Return value: A pointer to the found occurrence, or + * NULL if not found. + **/ +gchar * +g_strrstr_len (const gchar *haystack, + gssize haystack_len, + const gchar *needle) +{ + g_return_val_if_fail (haystack != NULL, NULL); + g_return_val_if_fail (needle != NULL, NULL); + + if (haystack_len < 0) + return g_strrstr (haystack, needle); + else + { + gsize needle_len = strlen (needle); + const gchar *haystack_max = haystack + haystack_len; + const gchar *p = haystack; + gsize i; + + while (p < haystack_max && *p) + p++; + + if (p < haystack + needle_len) + return NULL; + + p -= needle_len; + + while (p >= haystack) + { + for (i = 0; i < needle_len; i++) + if (p[i] != needle[i]) + goto next; + + return (gchar *)p; + + next: + p--; + } + + return NULL; + } +} + + diff --git a/graf2d/win32gdk/gdk/src/glib/gstrfuncs.h b/graf2d/win32gdk/gdk/src/glib/gstrfuncs.h index ac6b456de67ce..2f5bfbfd4689e 100644 --- a/graf2d/win32gdk/gdk/src/glib/gstrfuncs.h +++ b/graf2d/win32gdk/gdk/src/glib/gstrfuncs.h @@ -28,66 +28,151 @@ #define __G_STRFUNCS_H__ #include <stdarg.h> -#include <g_types.h> +#include <glib/gtypes.h> G_BEGIN_DECLS +/* Functions like the ones in <ctype.h> that are not affected by locale. */ +typedef enum { + G_ASCII_ALNUM = 1 << 0, + G_ASCII_ALPHA = 1 << 1, + G_ASCII_CNTRL = 1 << 2, + G_ASCII_DIGIT = 1 << 3, + G_ASCII_GRAPH = 1 << 4, + G_ASCII_LOWER = 1 << 5, + G_ASCII_PRINT = 1 << 6, + G_ASCII_PUNCT = 1 << 7, + G_ASCII_SPACE = 1 << 8, + G_ASCII_UPPER = 1 << 9, + G_ASCII_XDIGIT = 1 << 10 +} GAsciiType; + +GLIB_VAR const guint16 * const g_ascii_table; + +#define g_ascii_isalnum(c) \ + ((g_ascii_table[(guchar) (c)] & G_ASCII_ALNUM) != 0) + +#define g_ascii_isalpha(c) \ + ((g_ascii_table[(guchar) (c)] & G_ASCII_ALPHA) != 0) + +#define g_ascii_iscntrl(c) \ + ((g_ascii_table[(guchar) (c)] & G_ASCII_CNTRL) != 0) + +#define g_ascii_isdigit(c) \ + ((g_ascii_table[(guchar) (c)] & G_ASCII_DIGIT) != 0) + +#define g_ascii_isgraph(c) \ + ((g_ascii_table[(guchar) (c)] & G_ASCII_GRAPH) != 0) + +#define g_ascii_islower(c) \ + ((g_ascii_table[(guchar) (c)] & G_ASCII_LOWER) != 0) + +#define g_ascii_isprint(c) \ + ((g_ascii_table[(guchar) (c)] & G_ASCII_PRINT) != 0) + +#define g_ascii_ispunct(c) \ + ((g_ascii_table[(guchar) (c)] & G_ASCII_PUNCT) != 0) + +#define g_ascii_isspace(c) \ + ((g_ascii_table[(guchar) (c)] & G_ASCII_SPACE) != 0) + +#define g_ascii_isupper(c) \ + ((g_ascii_table[(guchar) (c)] & G_ASCII_UPPER) != 0) + +#define g_ascii_isxdigit(c) \ + ((g_ascii_table[(guchar) (c)] & G_ASCII_XDIGIT) != 0) + +gchar g_ascii_tolower (gchar c) G_GNUC_CONST; +gchar g_ascii_toupper (gchar c) G_GNUC_CONST; + +gint g_ascii_digit_value (gchar c) G_GNUC_CONST; +gint g_ascii_xdigit_value (gchar c) G_GNUC_CONST; + /* String utility functions that modify a string argument or * return a constant string that must not be freed. */ #define G_STR_DELIMITERS "_-|> <." -gchar* g_strdelimit (gchar *string, - const gchar *delimiters, - gchar new_delimiter); -gchar* g_strcanon (gchar *string, - const gchar *valid_chars, - gchar subsitutor); -gdouble g_strtod (const gchar *nptr, - gchar **endptr); -gchar* g_strerror (gint errnum) G_GNUC_CONST; -gchar* g_strsignal (gint signum) G_GNUC_CONST; -gint g_strcasecmp (const gchar *s1, - const gchar *s2); -gint g_strncasecmp (const gchar *s1, - const gchar *s2, - guint n); -gchar* g_strdown (gchar *string); -gchar* g_strup (gchar *string); -gchar* g_strreverse (gchar *string); -gsize g_strlcpy (gchar *dest, - const gchar *src, - gsize dest_size); -gsize g_strlcat (gchar *dest, - const gchar *src, - gsize dest_size); +gchar* g_strdelimit (gchar *string, + const gchar *delimiters, + gchar new_delimiter); +gchar* g_strcanon (gchar *string, + const gchar *valid_chars, + gchar substitutor); +gdouble g_strtod (const gchar *nptr, + gchar **endptr); +G_CONST_RETURN gchar* g_strerror (gint errnum) G_GNUC_CONST; +G_CONST_RETURN gchar* g_strsignal (gint signum) G_GNUC_CONST; +gchar* g_strreverse (gchar *string); +gsize g_strlcpy (gchar *dest, + const gchar *src, + gsize dest_size); +gsize g_strlcat (gchar *dest, + const gchar *src, + gsize dest_size); +gchar * g_strstr_len (const gchar *haystack, + gssize haystack_len, + const gchar *needle); +gchar * g_strrstr (const gchar *haystack, + const gchar *needle); +gchar * g_strrstr_len (const gchar *haystack, + gssize haystack_len, + const gchar *needle); + /* removes leading spaces */ -gchar* g_strchug (gchar *string); +gchar* g_strchug (gchar *string); /* removes trailing spaces */ -gchar* g_strchomp (gchar *string); +gchar* g_strchomp (gchar *string); /* removes leading & trailing spaces */ #define g_strstrip( string ) g_strchomp (g_strchug (string)) +gint g_ascii_strcasecmp (const gchar *s1, + const gchar *s2); +gint g_ascii_strncasecmp (const gchar *s1, + const gchar *s2, + guint n); +gchar* g_ascii_strdown (const gchar *str, + gssize len); +gchar* g_ascii_strup (const gchar *str, + gssize len); + +#ifndef G_DISABLE_DEPRECATED + +/* The following four functions are deprecated and will be removed in + * the next major release. They use the locale-specific tolower and + * toupper, which is almost never the right thing. + */ + +gint g_strcasecmp (const gchar *s1, + const gchar *s2); +gint g_strncasecmp (const gchar *s1, + const gchar *s2, + guint n); +gchar* g_strdown (gchar *string); +gchar* g_strup (gchar *string); + +#endif /* G_DISABLE_DEPRECATED */ + /* String utility functions that return a newly allocated string which * ought to be freed with g_free from the caller at some point. */ -gchar* g_strdup (const gchar *str); -gchar* g_strdup_printf (const gchar *format, - ...) G_GNUC_PRINTF (1, 2); -gchar* g_strdup_vprintf (const gchar *format, - va_list args); -gchar* g_strndup (const gchar *str, - guint n); -gchar* g_strnfill (guint length, - gchar fill_char); -gchar* g_strconcat (const gchar *string1, - ...); /* NULL terminated */ -gchar* g_strjoin (const gchar *separator, - ...); /* NULL terminated */ +gchar* g_strdup (const gchar *str); +gchar* g_strdup_printf (const gchar *format, + ...) G_GNUC_PRINTF (1, 2); +gchar* g_strdup_vprintf (const gchar *format, + va_list args); +gchar* g_strndup (const gchar *str, + gsize n); +gchar* g_strnfill (gsize length, + gchar fill_char); +gchar* g_strconcat (const gchar *string1, + ...); /* NULL terminated */ +gchar* g_strjoin (const gchar *separator, + ...); /* NULL terminated */ /* Make a copy of a string interpreting C string -style escape * sequences. Inverse of g_strescape. The recognized sequences are \b * \f \n \r \t \\ \" and the octal format. */ -gchar* g_strcompress (const gchar *source); +gchar* g_strcompress (const gchar *source); /* Copy a string escaping nonprintable characters like in C strings. * Inverse of g_strcompress. The exceptions parameter, if non-NULL, points @@ -97,11 +182,11 @@ gchar* g_strcompress (const gchar *source); * Luckily this function wasn't used much, using NULL as second parameter * provides mostly identical semantics. */ -gchar* g_strescape (const gchar *source, - const gchar *exceptions); +gchar* g_strescape (const gchar *source, + const gchar *exceptions); -gpointer g_memdup (gconstpointer mem, - guint byte_size); +gpointer g_memdup (gconstpointer mem, + guint byte_size); /* NULL terminated string arrays. * g_strsplit() splits up string into max_tokens tokens at delim and @@ -111,13 +196,16 @@ gpointer g_memdup (gconstpointer mem, * g_strfreev() frees the array itself and all of its strings. * g_strdupv() copies a NULL-terminated array of strings */ -gchar** g_strsplit (const gchar *string, - const gchar *delimiter, - gint max_tokens); -gchar* g_strjoinv (const gchar *separator, - gchar **str_array); -void g_strfreev (gchar **str_array); -gchar** g_strdupv (gchar **str_array); +gchar** g_strsplit (const gchar *string, + const gchar *delimiter, + gint max_tokens); +gchar* g_strjoinv (const gchar *separator, + gchar **str_array); +void g_strfreev (gchar **str_array); +gchar** g_strdupv (gchar **str_array); + +gchar* g_stpcpy (gchar *dest, + const char *src); G_END_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gstring.c b/graf2d/win32gdk/gdk/src/glib/gstring.c new file mode 100644 index 0000000000000..a062bbbc11ae7 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gstring.c @@ -0,0 +1,750 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#ifdef HAVE_UNISTD_H +#include <unistd.h> +#endif +#include <stdarg.h> +#include <stdlib.h> +#include <stdio.h> +#include <string.h> +#include <ctype.h> +#include "glib.h" + +struct _GStringChunk +{ + GHashTable *const_table; + GSList *storage_list; + gsize storage_next; + gsize this_size; + gsize default_size; +}; + +G_LOCK_DEFINE_STATIC (string_mem_chunk); +static GMemChunk *string_mem_chunk = NULL; + +/* Hash Functions. + */ + +gboolean +g_str_equal (gconstpointer v1, + gconstpointer v2) +{ + const gchar *string1 = v1; + const gchar *string2 = v2; + + return strcmp (string1, string2) == 0; +} + +/* 31 bit hash function */ +guint +g_str_hash (gconstpointer key) +{ + const char *p = key; + guint h = *p; + + if (h) + for (p += 1; *p != '\0'; p++) + h = (h << 5) - h + *p; + + return h; +} + +#define MY_MAXSIZE ((gsize)-1) + +static inline gsize +nearest_power (gsize base, gsize num) +{ + if (num > MY_MAXSIZE / 2) + { + return MY_MAXSIZE; + } + else + { + gsize n = base; + + while (n < num) + n <<= 1; + + return n; + } +} + +/* String Chunks. + */ + +GStringChunk* +g_string_chunk_new (gsize default_size) +{ + GStringChunk *new_chunk = g_new (GStringChunk, 1); + gsize size = 1; + + size = nearest_power (1, default_size); + + new_chunk->const_table = NULL; + new_chunk->storage_list = NULL; + new_chunk->storage_next = size; + new_chunk->default_size = size; + new_chunk->this_size = size; + + return new_chunk; +} + +void +g_string_chunk_free (GStringChunk *chunk) +{ + GSList *tmp_list; + + g_return_if_fail (chunk != NULL); + + if (chunk->storage_list) + { + for (tmp_list = chunk->storage_list; tmp_list; tmp_list = tmp_list->next) + g_free (tmp_list->data); + + g_slist_free (chunk->storage_list); + } + + if (chunk->const_table) + g_hash_table_destroy (chunk->const_table); + + g_free (chunk); +} + +gchar* +g_string_chunk_insert (GStringChunk *chunk, + const gchar *string) +{ + gsize len = strlen (string); + char* pos; + + g_return_val_if_fail (chunk != NULL, NULL); + + if ((chunk->storage_next + len + 1) > chunk->this_size) + { + gsize new_size = nearest_power (chunk->default_size, len + 1); + + chunk->storage_list = g_slist_prepend (chunk->storage_list, + g_new (char, new_size)); + + chunk->this_size = new_size; + chunk->storage_next = 0; + } + + pos = ((char *) chunk->storage_list->data) + chunk->storage_next; + + strcpy (pos, string); + + chunk->storage_next += len + 1; + + return pos; +} + +gchar* +g_string_chunk_insert_const (GStringChunk *chunk, + const gchar *string) +{ + char* lookup; + + g_return_val_if_fail (chunk != NULL, NULL); + + if (!chunk->const_table) + chunk->const_table = g_hash_table_new (g_str_hash, g_str_equal); + + lookup = (char*) g_hash_table_lookup (chunk->const_table, (gchar *)string); + + if (!lookup) + { + lookup = g_string_chunk_insert (chunk, string); + g_hash_table_insert (chunk->const_table, lookup, lookup); + } + + return lookup; +} + +/* Strings. + */ +static void +g_string_maybe_expand (GString* string, + gsize len) +{ + if (string->len + len >= string->allocated_len) + { + string->allocated_len = nearest_power (1, string->len + len + 1); + string->str = g_realloc (string->str, string->allocated_len); + } +} + +GString* +g_string_sized_new (gsize dfl_size) +{ + GString *string; + + G_LOCK (string_mem_chunk); + if (!string_mem_chunk) + string_mem_chunk = g_mem_chunk_new ("string mem chunk", + sizeof (GString), + 1024, G_ALLOC_AND_FREE); + + string = g_chunk_new (GString, string_mem_chunk); + G_UNLOCK (string_mem_chunk); + + string->allocated_len = 0; + string->len = 0; + string->str = NULL; + + g_string_maybe_expand (string, MAX (dfl_size, 2)); + string->str[0] = 0; + + return string; +} + +GString* +g_string_new (const gchar *init) +{ + GString *string; + + string = g_string_sized_new (init ? strlen (init) + 2 : 2); + + if (init) + g_string_append (string, init); + + return string; +} + +GString* +g_string_new_len (const gchar *init, + gssize len) +{ + GString *string; + + if (len < 0) + return g_string_new (init); + else + { + string = g_string_sized_new (len); + + if (init) + g_string_append_len (string, init, len); + + return string; + } +} + +gchar* +g_string_free (GString *string, + gboolean free_segment) +{ + gchar *segment; + + g_return_val_if_fail (string != NULL, NULL); + + if (free_segment) + { + g_free (string->str); + segment = NULL; + } + else + segment = string->str; + + G_LOCK (string_mem_chunk); + g_mem_chunk_free (string_mem_chunk, string); + G_UNLOCK (string_mem_chunk); + + return segment; +} + +gboolean +g_string_equal (const GString *v, + const GString *v2) +{ + gchar *p, *q; + GString *string1 = (GString *) v; + GString *string2 = (GString *) v2; + gsize i = string1->len; + + if (i != string2->len) + return FALSE; + + p = string1->str; + q = string2->str; + while (i) + { + if (*p != *q) + return FALSE; + p++; + q++; + i--; + } + return TRUE; +} + +/* 31 bit hash function */ +guint +g_string_hash (const GString *str) +{ + const gchar *p = str->str; + gsize n = str->len; + guint h = 0; + + while (n--) + { + h = (h << 5) - h + *p; + p++; + } + + return h; +} + +GString* +g_string_assign (GString *string, + const gchar *rval) +{ + g_return_val_if_fail (string != NULL, NULL); + g_return_val_if_fail (rval != NULL, string); + + g_string_truncate (string, 0); + g_string_append (string, rval); + + return string; +} + +GString* +g_string_truncate (GString *string, + gsize len) +{ + g_return_val_if_fail (string != NULL, NULL); + + string->len = MIN (len, string->len); + string->str[string->len] = 0; + + return string; +} + +/** + * g_string_set_size: + * @string: a #GString + * @len: the new length + * + * Sets the length of a #GString. If the length is less than + * the current length, the string will be truncated. If the + * length is greater than the current length, the contents + * of the newly added area are undefined. (However, as + * always, string->str[string->len] will be a nul byte.) + * + * Return value: @string + **/ +GString* +g_string_set_size (GString *string, + gsize len) +{ + g_return_val_if_fail (string != NULL, NULL); + + if (len >= string->allocated_len) + g_string_maybe_expand (string, len - string->len); + + string->len = len; + string->str[len] = 0; + + return string; +} + +GString* +g_string_insert_len (GString *string, + gssize pos, + const gchar *val, + gssize len) +{ + g_return_val_if_fail (string != NULL, NULL); + g_return_val_if_fail (val != NULL, string); + + if (len < 0) + len = strlen (val); + + if (pos < 0) + pos = string->len; + else + g_return_val_if_fail (pos <= string->len, string); + + g_string_maybe_expand (string, len); + + /* If we aren't appending at the end, move a hunk + * of the old string to the end, opening up space + */ + if (pos < string->len) + g_memmove (string->str + pos + len, string->str + pos, string->len - pos); + + /* insert the new string */ + g_memmove (string->str + pos, val, len); + + string->len += len; + + string->str[string->len] = 0; + + return string; +} + +GString* +g_string_append (GString *string, + const gchar *val) +{ + g_return_val_if_fail (string != NULL, NULL); + g_return_val_if_fail (val != NULL, string); + + return g_string_insert_len (string, -1, val, -1); +} + +GString* +g_string_append_len (GString *string, + const gchar *val, + gssize len) +{ + g_return_val_if_fail (string != NULL, NULL); + g_return_val_if_fail (val != NULL, string); + + return g_string_insert_len (string, -1, val, len); +} + +GString* +g_string_append_c (GString *string, + gchar c) +{ + g_return_val_if_fail (string != NULL, NULL); + + return g_string_insert_c (string, -1, c); +} + +/** + * g_string_append_unichar: + * @string: a #GString + * @wc: a Unicode character + * + * Converts a Unicode character into UTF-8, and appends it + * to the string. + * + * Return value: @string + **/ +GString* +g_string_append_unichar (GString *string, + gunichar wc) +{ + g_return_val_if_fail (string != NULL, NULL); + + return g_string_insert_unichar (string, -1, wc); +} + +GString* +g_string_prepend (GString *string, + const gchar *val) +{ + g_return_val_if_fail (string != NULL, NULL); + g_return_val_if_fail (val != NULL, string); + + return g_string_insert_len (string, 0, val, -1); +} + +GString* +g_string_prepend_len (GString *string, + const gchar *val, + gssize len) +{ + g_return_val_if_fail (string != NULL, NULL); + g_return_val_if_fail (val != NULL, string); + + return g_string_insert_len (string, 0, val, len); +} + +GString* +g_string_prepend_c (GString *string, + gchar c) +{ + g_return_val_if_fail (string != NULL, NULL); + + return g_string_insert_c (string, 0, c); +} + +/** + * g_string_append_unichar: + * @string: a #GString + * @wc: a Unicode character + * + * Converts a Unicode character into UTF-8, and prepends it + * to the string. + * + * Return value: @string + **/ +GString* +g_string_prepend_unichar (GString *string, + gunichar wc) +{ + g_return_val_if_fail (string != NULL, NULL); + + return g_string_insert_unichar (string, 0, wc); +} + +GString* +g_string_insert (GString *string, + gssize pos, + const gchar *val) +{ + g_return_val_if_fail (string != NULL, NULL); + g_return_val_if_fail (val != NULL, string); + if (pos >= 0) + g_return_val_if_fail (pos <= string->len, string); + + return g_string_insert_len (string, pos, val, -1); +} + +GString* +g_string_insert_c (GString *string, + gssize pos, + gchar c) +{ + g_return_val_if_fail (string != NULL, NULL); + + g_string_maybe_expand (string, 1); + + if (pos < 0) + pos = string->len; + else + g_return_val_if_fail (pos <= string->len, string); + + /* If not just an append, move the old stuff */ + if (pos < string->len) + g_memmove (string->str + pos + 1, string->str + pos, string->len - pos); + + string->str[pos] = c; + + string->len += 1; + + string->str[string->len] = 0; + + return string; +} + +/** + * g_string_insert_unichar: + * @string: a #Gstring + * @pos: the position at which to insert character, or -1 to + * append at the end of the string. + * @wc: a Unicode character + * + * Converts a Unicode character into UTF-8, and insert it + * into the string at the given position. + * + * Return value: @string + **/ +GString* +g_string_insert_unichar (GString *string, + gssize pos, + gunichar wc) +{ + gchar buf[6]; + gint charlen; + + /* We could be somewhat more efficient here by computing + * the length, adding the space, then converting into that + * space, by cut-and-pasting the internals of g_unichar_to_utf8. + */ + g_return_val_if_fail (string != NULL, NULL); + + charlen = g_unichar_to_utf8 (wc, buf); + return g_string_insert_len (string, pos, buf, charlen); +} + +GString* +g_string_erase (GString *string, + gsize pos, + gsize len) +{ + g_return_val_if_fail (string != NULL, NULL); + g_return_val_if_fail (pos >= 0, string); + g_return_val_if_fail (pos <= string->len, string); + + if (len < 0) + len = string->len - pos; + else + { + g_return_val_if_fail (pos + len <= string->len, string); + + if (pos + len < string->len) + g_memmove (string->str + pos, string->str + pos + len, string->len - (pos + len)); + } + + string->len -= len; + + string->str[string->len] = 0; + + return string; +} + +/** + * g_string_ascii_down: + * @string: a GString + * + * Converts all upper case ASCII letters to lower case ASCII letters. + * + * Return value: passed-in @string pointer, with all the upper case + * characters converted to lower case in place, with + * semantics that exactly match g_ascii_tolower. + **/ +GString* +g_string_ascii_down (GString *string) +{ + gchar *s; + gint n = string->len; + + g_return_val_if_fail (string != NULL, NULL); + + s = string->str; + + while (n) + { + *s = g_ascii_tolower (*s); + s++; + n--; + } + + return string; +} + +/** + * g_string_ascii_up: + * @string: a GString + * + * Converts all lower case ASCII letters to upper case ASCII letters. + * + * Return value: passed-in @string pointer, with all the lower case + * characters converted to upper case in place, with + * semantics that exactly match g_ascii_toupper. + **/ +GString* +g_string_ascii_up (GString *string) +{ + gchar *s; + gint n = string->len; + + g_return_val_if_fail (string != NULL, NULL); + + s = string->str; + + while (n) + { + *s = g_ascii_toupper (*s); + s++; + n--; + } + + return string; +} + +GString* +g_string_down (GString *string) +{ + guchar *s; + glong n = string->len; + + g_return_val_if_fail (string != NULL, NULL); + + s = (guchar *) string->str; + + while (n) + { + if (isupper (*s)) + *s = tolower (*s); + s++; + n--; + } + + return string; +} + +GString* +g_string_up (GString *string) +{ + guchar *s; + glong n = string->len; + + g_return_val_if_fail (string != NULL, NULL); + + s = (guchar *) string->str; + + while (n) + { + if (islower (*s)) + *s = toupper (*s); + s++; + n--; + } + + return string; +} + +static void +g_string_printfa_internal (GString *string, + const gchar *fmt, + va_list args) +{ + gchar *buffer; + + buffer = g_strdup_vprintf (fmt, args); + g_string_append (string, buffer); + g_free (buffer); +} + +void +g_string_printf (GString *string, + const gchar *fmt, + ...) +{ + va_list args; + + g_string_truncate (string, 0); + + va_start (args, fmt); + g_string_printfa_internal (string, fmt, args); + va_end (args); +} + +void +g_string_printfa (GString *string, + const gchar *fmt, + ...) +{ + va_list args; + + va_start (args, fmt); + g_string_printfa_internal (string, fmt, args); + va_end (args); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gstring.h b/graf2d/win32gdk/gdk/src/glib/gstring.h index cdd0c6c15b819..7241273b668ec 100644 --- a/graf2d/win32gdk/gdk/src/glib/gstring.h +++ b/graf2d/win32gdk/gdk/src/glib/gstring.h @@ -27,7 +27,8 @@ #ifndef __G_STRING_H__ #define __G_STRING_H__ -#include <g_types.h> +#include <glib/gtypes.h> +#include <glib/gunicode.h> G_BEGIN_DECLS @@ -36,13 +37,14 @@ typedef struct _GStringChunk GStringChunk; struct _GString { - gchar *str; - gint len; + gchar *str; + gsize len; + gsize allocated_len; }; /* String Chunks */ -GStringChunk* g_string_chunk_new (gint size); +GStringChunk* g_string_chunk_new (gsize size); void g_string_chunk_free (GStringChunk *chunk); gchar* g_string_chunk_insert (GStringChunk *chunk, const gchar *string); @@ -54,8 +56,8 @@ gchar* g_string_chunk_insert_const (GStringChunk *chunk, */ GString* g_string_new (const gchar *init); GString* g_string_new_len (const gchar *init, - gint len); -GString* g_string_sized_new (guint dfl_size); + gssize len); +GString* g_string_sized_new (gsize dfl_size); gchar* g_string_free (GString *string, gboolean free_segment); gboolean g_string_equal (const GString *v, @@ -64,43 +66,68 @@ guint g_string_hash (const GString *str); GString* g_string_assign (GString *string, const gchar *rval); GString* g_string_truncate (GString *string, - guint len); + gsize len); +GString* g_string_set_size (GString *string, + gsize len); GString* g_string_insert_len (GString *string, - gint pos, + gssize pos, const gchar *val, - gint len); + gssize len); GString* g_string_append (GString *string, const gchar *val); GString* g_string_append_len (GString *string, const gchar *val, - gint len); + gssize len); GString* g_string_append_c (GString *string, gchar c); +GString* g_string_append_unichar (GString *string, + gunichar wc); GString* g_string_prepend (GString *string, const gchar *val); GString* g_string_prepend_c (GString *string, gchar c); +GString* g_string_prepend_unichar (GString *string, + gunichar wc); GString* g_string_prepend_len (GString *string, const gchar *val, - gint len); + gssize len); GString* g_string_insert (GString *string, - gint pos, + gssize pos, const gchar *val); GString* g_string_insert_c (GString *string, - gint pos, + gssize pos, gchar c); +GString* g_string_insert_unichar (GString *string, + gssize pos, + gunichar wc); GString* g_string_erase (GString *string, - gint pos, - gint len); -GString* g_string_down (GString *string); -GString* g_string_up (GString *string); -void g_string_sprintf (GString *string, + gsize pos, + gsize len); +GString* g_string_ascii_down (GString *string); +GString* g_string_ascii_up (GString *string); +void g_string_printf (GString *string, const gchar *format, ...) G_GNUC_PRINTF (2, 3); -void g_string_sprintfa (GString *string, +void g_string_printfa (GString *string, const gchar *format, ...) G_GNUC_PRINTF (2, 3); +#ifndef G_DISABLE_DEPRECATED + +/* The following two functions are deprecated and will be removed in + * the next major release. They use the locale-specific tolower and + * toupper, which is almost never the right thing. + */ + +GString* g_string_down (GString *string); +GString* g_string_up (GString *string); + +/* These aliases are included for compatibility. */ +#define g_string_sprintf g_string_printf +#define g_string_sprintfa g_string_printfa + +#endif /* G_DISABLE_DEPRECATED */ + G_END_DECLS #endif /* __G_STRING_H__ */ diff --git a/graf2d/win32gdk/gdk/src/glib/gthread.c b/graf2d/win32gdk/gdk/src/glib/gthread.c new file mode 100644 index 0000000000000..0392f282d7072 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gthread.c @@ -0,0 +1,823 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * gmutex.c: MT safety related functions + * Copyright 1998 Sebastian Wilhelmi; University of Karlsruhe + * Owen Taylor + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#include "config.h" +#include "glib.h" + +#ifdef G_THREAD_USE_PID_SURROGATE +#include <sys/types.h> +#include <sys/time.h> +#include <sys/resource.h> +#include <errno.h> +#endif /* G_THREAD_USE_PID_SURROGATE */ + +#ifdef HAVE_UNISTD_H +#include <unistd.h> +#endif + +#include <string.h> + +#if GLIB_SIZEOF_SYSTEM_THREAD == SIZEOF_VOID_P +# define g_system_thread_equal_simple(thread1, thread2) \ + ((thread1).dummy_pointer == (thread2).dummy_pointer) +# define g_system_thread_assign(dest, src) \ + ((dest).dummy_pointer = (src).dummy_pointer) +#else /* GLIB_SIZEOF_SYSTEM_THREAD != SIZEOF_VOID_P */ +# define g_system_thread_equal_simple(thread1, thread2) \ + (memcmp (&(thread1), &(thread2), GLIB_SIZEOF_SYSTEM_THREAD) == 0) +# define g_system_thread_assign(dest, src) \ + (memcpy (&(dest), &(src), GLIB_SIZEOF_SYSTEM_THREAD)) +#endif /* GLIB_SIZEOF_SYSTEM_THREAD == SIZEOF_VOID_P */ + +#define g_system_thread_equal(thread1, thread2) \ + (g_thread_functions_for_glib_use.thread_equal ? \ + g_thread_functions_for_glib_use.thread_equal (&(thread1), &(thread2)) :\ + g_system_thread_equal_simple((thread1), (thread2))) + +GQuark +g_thread_error_quark (void) +{ + static GQuark quark; + if (!quark) + quark = g_quark_from_static_string ("g_thread_error"); + return quark; +} + +/* Keep this in sync with GRealThread in gmain.c! */ +typedef struct _GRealThread GRealThread; +struct _GRealThread +{ + GThread thread; + gpointer private_data; + gpointer retval; + GSystemThread system_thread; +#ifdef G_THREAD_USE_PID_SURROGATE + pid_t pid; +#endif /* G_THREAD_USE_PID_SURROGATE */ +}; + +#ifdef G_THREAD_USE_PID_SURROGATE +static gint priority_map[] = { 15, 0, -15, -20 }; +static gboolean prio_warned = FALSE; +# define SET_PRIO(pid, prio) G_STMT_START{ \ + gint error = setpriority (PRIO_PROCESS, (pid), priority_map[prio]); \ + if (error == -1 && errno == EACCES && !prio_warned) \ + { \ + prio_warned = TRUE; \ + g_warning ("Priorities can only be increased by root."); \ + } \ + }G_STMT_END +#endif /* G_THREAD_USE_PID_SURROGATE */ + +typedef struct _GStaticPrivateNode GStaticPrivateNode; +struct _GStaticPrivateNode +{ + gpointer data; + GDestroyNotify destroy; +}; + +static void g_thread_cleanup (gpointer data); +static void g_thread_fail (void); + +/* Global variables */ + +static GSystemThread zero_thread; /* This is initialized to all zero */ +gboolean g_thread_use_default_impl = TRUE; +gboolean g_threads_got_initialized = FALSE; + +#if defined(G_PLATFORM_WIN32) && defined(__GNUC__) +__declspec(dllexport) +#endif +GThreadFunctions g_thread_functions_for_glib_use = { + (GMutex*(*)(void))g_thread_fail, /* mutex_new */ + NULL, /* mutex_lock */ + NULL, /* mutex_trylock */ + NULL, /* mutex_unlock */ + NULL, /* mutex_free */ + (GCond*(*)(void))g_thread_fail, /* cond_new */ + NULL, /* cond_signal */ + NULL, /* cond_broadcast */ + NULL, /* cond_wait */ + NULL, /* cond_timed_wait */ + NULL, /* cond_free */ + (GPrivate*(*)(GDestroyNotify))g_thread_fail, /* private_new */ + NULL, /* private_get */ + NULL, /* private_set */ + (void(*)(GThreadFunc, gpointer, gulong, + gboolean, gboolean, GThreadPriority, + gpointer, GError**))g_thread_fail, /* thread_create */ + NULL, /* thread_yield */ + NULL, /* thread_join */ + NULL, /* thread_exit */ + NULL, /* thread_set_priority */ + NULL /* thread_self */ +}; + +/* Local data */ + +static GMutex *g_mutex_protect_static_mutex_allocation = NULL; +static GPrivate *g_thread_specific_private = NULL; +static GSList *g_thread_all_threads = NULL; +static GSList *g_thread_free_indeces = NULL; + +G_LOCK_DEFINE_STATIC (g_thread); + +/* This must be called only once, before any threads are created. + * It will only be called from g_thread_init() in -lgthread. + */ +void +g_mutex_init (void) +{ + GRealThread* main_thread; + + /* We let the main thread (the one that calls g_thread_init) inherit + * the data, that it set before calling g_thread_init + */ + main_thread = (GRealThread*) g_thread_self (); + + g_thread_specific_private = g_private_new (g_thread_cleanup); + G_THREAD_UF (private_set, (g_thread_specific_private, main_thread)); + G_THREAD_UF (thread_self, (&main_thread->system_thread)); + + g_mutex_protect_static_mutex_allocation = g_mutex_new (); +} + +void +g_static_mutex_init (GStaticMutex *mutex) +{ + static GStaticMutex init_mutex = G_STATIC_MUTEX_INIT; + + g_return_if_fail (mutex); + + *mutex = init_mutex; +} + +GMutex * +g_static_mutex_get_mutex_impl (GMutex** mutex) +{ + if (!g_thread_supported ()) + return NULL; + + g_assert (g_mutex_protect_static_mutex_allocation); + + g_mutex_lock (g_mutex_protect_static_mutex_allocation); + + if (!(*mutex)) + *mutex = g_mutex_new (); + + g_mutex_unlock (g_mutex_protect_static_mutex_allocation); + + return *mutex; +} + +void +g_static_mutex_free (GStaticMutex* mutex) +{ + GMutex **runtime_mutex; + + g_return_if_fail (mutex); + + /* The runtime_mutex is the first (or only) member of GStaticMutex, + * see both versions (of glibconfig.h) in configure.in */ + runtime_mutex = ((GMutex**)mutex); + + if (*runtime_mutex) + g_mutex_free (*runtime_mutex); + + *runtime_mutex = NULL; +} + +void +g_static_rec_mutex_init (GStaticRecMutex *mutex) +{ + static GStaticRecMutex init_mutex = G_STATIC_REC_MUTEX_INIT; + + g_return_if_fail (mutex); + + *mutex = init_mutex; +} + +void +g_static_rec_mutex_lock (GStaticRecMutex* mutex) +{ + GSystemThread self; + + g_return_if_fail (mutex); + + if (!g_thread_supported ()) + return; + + G_THREAD_UF (thread_self, (&self)); + + if (g_system_thread_equal (self, mutex->owner)) + { + mutex->depth++; + return; + } + g_static_mutex_lock (&mutex->mutex); + g_system_thread_assign (mutex->owner, self); + mutex->depth = 1; +} + +gboolean +g_static_rec_mutex_trylock (GStaticRecMutex* mutex) +{ + GSystemThread self; + + g_return_val_if_fail (mutex, FALSE); + + if (!g_thread_supported ()) + return TRUE; + + G_THREAD_UF (thread_self, (&self)); + + if (g_system_thread_equal (self, mutex->owner)) + { + mutex->depth++; + return TRUE; + } + + if (!g_static_mutex_trylock (&mutex->mutex)) + return FALSE; + + g_system_thread_assign (mutex->owner, self); + mutex->depth = 1; + return TRUE; +} + +void +g_static_rec_mutex_unlock (GStaticRecMutex* mutex) +{ + g_return_if_fail (mutex); + + if (!g_thread_supported ()) + return; + + if (mutex->depth > 1) + { + mutex->depth--; + return; + } + g_system_thread_assign (mutex->owner, zero_thread); + g_static_mutex_unlock (&mutex->mutex); +} + +void +g_static_rec_mutex_lock_full (GStaticRecMutex *mutex, + guint depth) +{ + GSystemThread self; + g_return_if_fail (mutex); + + if (!g_thread_supported ()) + return; + + G_THREAD_UF (thread_self, (&self)); + + if (g_system_thread_equal (self, mutex->owner)) + { + mutex->depth += depth; + return; + } + g_static_mutex_lock (&mutex->mutex); + g_system_thread_assign (mutex->owner, self); + mutex->depth = depth; +} + +guint +g_static_rec_mutex_unlock_full (GStaticRecMutex *mutex) +{ + gint depth; + + g_return_val_if_fail (mutex, 0); + + if (!g_thread_supported ()) + return 1; + + depth = mutex->depth; + + g_system_thread_assign (mutex->owner, zero_thread); + mutex->depth = 0; + g_static_mutex_unlock (&mutex->mutex); + + return depth; +} + +void +g_static_rec_mutex_free (GStaticRecMutex *mutex) +{ + g_return_if_fail (mutex); + + g_static_mutex_free (&mutex->mutex); +} + +void +g_static_private_init (GStaticPrivate *private_key) +{ + private_key->index = 0; +} + +gpointer +g_static_private_get (GStaticPrivate *private_key) +{ + GRealThread *self = (GRealThread*) g_thread_self (); + GArray *array; + + array = self->private_data; + if (!array) + return NULL; + + if (!private_key->index) + return NULL; + else if (private_key->index <= array->len) + return g_array_index (array, GStaticPrivateNode, + private_key->index - 1).data; + else + return NULL; +} + +void +g_static_private_set (GStaticPrivate *private_key, + gpointer data, + GDestroyNotify notify) +{ + GRealThread *self = (GRealThread*) g_thread_self (); + GArray *array; + static guint next_index = 0; + GStaticPrivateNode *node; + + array = self->private_data; + if (!array) + { + array = g_array_new (FALSE, TRUE, sizeof (GStaticPrivateNode)); + self->private_data = array; + } + + if (!private_key->index) + { + G_LOCK (g_thread); + + if (!private_key->index) + { + if (g_thread_free_indeces) + { + private_key->index = + GPOINTER_TO_UINT (g_thread_free_indeces->data); + g_thread_free_indeces = + g_slist_delete_link (g_thread_free_indeces, + g_thread_free_indeces); + } + else + private_key->index = ++next_index; + } + + G_UNLOCK (g_thread); + } + + if (private_key->index > array->len) + g_array_set_size (array, private_key->index); + + node = &g_array_index (array, GStaticPrivateNode, private_key->index - 1); + if (node->destroy) + { + gpointer ddata = node->data; + GDestroyNotify ddestroy = node->destroy; + + node->data = data; + node->destroy = notify; + + ddestroy (ddata); + } + else + { + node->data = data; + node->destroy = notify; + } +} + +void +g_static_private_free (GStaticPrivate *private_key) +{ + guint index = private_key->index; + GSList *list; + + if (!index) + return; + + private_key->index = 0; + + G_LOCK (g_thread); + list = g_thread_all_threads; + while (list) + { + GRealThread *thread = list->data; + GArray *array = thread->private_data; + list = list->next; + + if (array && index <= array->len) + { + GStaticPrivateNode *node = &g_array_index (array, + GStaticPrivateNode, + index - 1); + gpointer ddata = node->data; + GDestroyNotify ddestroy = node->destroy; + + node->data = NULL; + node->destroy = NULL; + + if (ddestroy) + { + G_UNLOCK (g_thread); + ddestroy (ddata); + G_LOCK (g_thread); + } + } + } + g_thread_free_indeces = g_slist_prepend (g_thread_free_indeces, + GUINT_TO_POINTER (index)); + G_UNLOCK (g_thread); +} + +static void +g_thread_cleanup (gpointer data) +{ + if (data) + { + GRealThread* thread = data; + if (thread->private_data) + { + GArray* array = thread->private_data; + guint i; + + for (i = 0; i < array->len; i++ ) + { + GStaticPrivateNode *node = + &g_array_index (array, GStaticPrivateNode, i); + if (node->destroy) + node->destroy (node->data); + } + g_array_free (array, TRUE); + } + + /* We only free the thread structure, if it isn't joinable. If + it is, the structure is freed in g_thread_join */ + if (!thread->thread.joinable) + { + G_LOCK (g_thread); + g_thread_all_threads = g_slist_remove (g_thread_all_threads, data); + G_UNLOCK (g_thread); + + /* Just to make sure, this isn't used any more */ + g_system_thread_assign (thread->system_thread, zero_thread); + g_free (thread); + } + } +} + +static void +g_thread_fail (void) +{ + g_error ("The thread system is not yet initialized."); +} + +static gpointer +g_thread_create_proxy (gpointer data) +{ + GRealThread* thread = data; + + g_assert (data); + +#ifdef G_THREAD_USE_PID_SURROGATE + thread->pid = getpid (); +#endif /* G_THREAD_USE_PID_SURROGATE */ + + /* This has to happen before G_LOCK, as that might call g_thread_self */ + g_private_set (g_thread_specific_private, data); + + /* the lock makes sure, that thread->system_thread is written, + before thread->thread.func is called. See g_thread_create. */ + G_LOCK (g_thread); + G_UNLOCK (g_thread); + +#ifdef G_THREAD_USE_PID_SURROGATE + if (g_thread_use_default_impl) + SET_PRIO (thread->pid, thread->thread.priority); +#endif /* G_THREAD_USE_PID_SURROGATE */ + + thread->retval = thread->thread.func (thread->thread.data); + + return NULL; +} + +GThread* +g_thread_create_full (GThreadFunc func, + gpointer data, + gulong stack_size, + gboolean joinable, + gboolean bound, + GThreadPriority priority, + GError **error) +{ + GRealThread* result = g_new (GRealThread, 1); + GError *local_error = NULL; + g_return_val_if_fail (func, NULL); + g_return_val_if_fail (priority >= G_THREAD_PRIORITY_LOW, NULL); + g_return_val_if_fail (priority <= G_THREAD_PRIORITY_URGENT, NULL); + + result->thread.joinable = joinable; + result->thread.priority = priority; + result->thread.func = func; + result->thread.data = data; + result->private_data = NULL; + G_LOCK (g_thread); + G_THREAD_UF (thread_create, (g_thread_create_proxy, result, + stack_size, joinable, bound, priority, + &result->system_thread, &local_error)); + g_thread_all_threads = g_slist_prepend (g_thread_all_threads, result); + G_UNLOCK (g_thread); + + if (local_error) + { + g_propagate_error (error, local_error); + g_free (result); + return NULL; + } + + return (GThread*) result; +} + +void +g_thread_exit (gpointer retval) +{ + GRealThread* real = (GRealThread*) g_thread_self (); + real->retval = retval; + G_THREAD_CF (thread_exit, (void)0, ()); +} + +gpointer +g_thread_join (GThread* thread) +{ + GRealThread* real = (GRealThread*) thread; + gpointer retval; + + g_return_val_if_fail (thread, NULL); + g_return_val_if_fail (thread->joinable, NULL); + g_return_val_if_fail (!g_system_thread_equal (real->system_thread, + zero_thread), NULL); + + G_THREAD_UF (thread_join, (&real->system_thread)); + + retval = real->retval; + + G_LOCK (g_thread); + g_thread_all_threads = g_slist_remove (g_thread_all_threads, thread); + G_UNLOCK (g_thread); + + /* Just to make sure, this isn't used any more */ + thread->joinable = 0; + g_system_thread_assign (real->system_thread, zero_thread); + + /* the thread structure for non-joinable threads is freed upon + thread end. We free the memory here. This will leave a loose end, + if a joinable thread is not joined. */ + + g_free (thread); + + return retval; +} + +void +g_thread_set_priority (GThread* thread, + GThreadPriority priority) +{ + GRealThread* real = (GRealThread*) thread; + + g_return_if_fail (thread); + g_return_if_fail (!g_system_thread_equal (real->system_thread, zero_thread)); + g_return_if_fail (priority >= G_THREAD_PRIORITY_LOW); + g_return_if_fail (priority <= G_THREAD_PRIORITY_URGENT); + + thread->priority = priority; + +#ifdef G_THREAD_USE_PID_SURROGATE + if (g_thread_use_default_impl) + SET_PRIO (real->pid, priority); + else +#endif /* G_THREAD_USE_PID_SURROGATE */ + G_THREAD_CF (thread_set_priority, (void)0, + (&real->system_thread, priority)); +} + +GThread* +g_thread_self (void) +{ + GRealThread* thread = g_private_get (g_thread_specific_private); + + if (!thread) + { + /* If no thread data is available, provide and set one. This + can happen for the main thread and for threads, that are not + created by GLib. */ + thread = g_new (GRealThread, 1); + thread->thread.joinable = FALSE; /* This is a save guess */ + thread->thread.priority = G_THREAD_PRIORITY_NORMAL; /* This is + just a guess */ + thread->thread.func = NULL; + thread->thread.data = NULL; + thread->private_data = NULL; + + if (g_thread_supported ()) + G_THREAD_UF (thread_self, (&thread->system_thread)); + +#ifdef G_THREAD_USE_PID_SURROGATE + thread->pid = getpid (); +#endif /* G_THREAD_USE_PID_SURROGATE */ + + g_private_set (g_thread_specific_private, thread); + + G_LOCK (g_thread); + g_thread_all_threads = g_slist_prepend (g_thread_all_threads, thread); + G_UNLOCK (g_thread); + } + + return (GThread*)thread; +} + +void +g_static_rw_lock_init (GStaticRWLock* lock) +{ + static GStaticRWLock init_lock = G_STATIC_RW_LOCK_INIT; + + g_return_if_fail (lock); + + *lock = init_lock; +} + +static void inline +g_static_rw_lock_wait (GCond** cond, GStaticMutex* mutex) +{ + if (!*cond) + *cond = g_cond_new (); + g_cond_wait (*cond, g_static_mutex_get_mutex (mutex)); +} + +static void inline +g_static_rw_lock_signal (GStaticRWLock* lock) +{ + if (lock->want_to_write && lock->write_cond) + g_cond_signal (lock->write_cond); + else if (lock->want_to_read && lock->read_cond) + g_cond_broadcast (lock->read_cond); +} + +void +g_static_rw_lock_reader_lock (GStaticRWLock* lock) +{ + g_return_if_fail (lock); + + if (!g_threads_got_initialized) + return; + + g_static_mutex_lock (&lock->mutex); + lock->want_to_read++; + while (lock->write || lock->want_to_write) + g_static_rw_lock_wait (&lock->read_cond, &lock->mutex); + lock->want_to_read--; + lock->read_counter++; + g_static_mutex_unlock (&lock->mutex); +} + +gboolean +g_static_rw_lock_reader_trylock (GStaticRWLock* lock) +{ + gboolean ret_val = FALSE; + + g_return_val_if_fail (lock, FALSE); + + if (!g_threads_got_initialized) + return TRUE; + + g_static_mutex_lock (&lock->mutex); + if (!lock->write && !lock->want_to_write) + { + lock->read_counter++; + ret_val = TRUE; + } + g_static_mutex_unlock (&lock->mutex); + return ret_val; +} + +void +g_static_rw_lock_reader_unlock (GStaticRWLock* lock) +{ + g_return_if_fail (lock); + + if (!g_threads_got_initialized) + return; + + g_static_mutex_lock (&lock->mutex); + lock->read_counter--; + if (lock->read_counter == 0) + g_static_rw_lock_signal (lock); + g_static_mutex_unlock (&lock->mutex); +} + +void +g_static_rw_lock_writer_lock (GStaticRWLock* lock) +{ + g_return_if_fail (lock); + + if (!g_threads_got_initialized) + return; + + g_static_mutex_lock (&lock->mutex); + lock->want_to_write++; + while (lock->write || lock->read_counter) + g_static_rw_lock_wait (&lock->write_cond, &lock->mutex); + lock->want_to_write--; + lock->write = TRUE; + g_static_mutex_unlock (&lock->mutex); +} + +gboolean +g_static_rw_lock_writer_trylock (GStaticRWLock* lock) +{ + gboolean ret_val = FALSE; + + g_return_val_if_fail (lock, FALSE); + + if (!g_threads_got_initialized) + return TRUE; + + g_static_mutex_lock (&lock->mutex); + if (!lock->write && !lock->read_counter) + { + lock->write = TRUE; + ret_val = TRUE; + } + g_static_mutex_unlock (&lock->mutex); + return ret_val; +} + +void +g_static_rw_lock_writer_unlock (GStaticRWLock* lock) +{ + g_return_if_fail (lock); + + if (!g_threads_got_initialized) + return; + + g_static_mutex_lock (&lock->mutex); + lock->write = FALSE; + g_static_rw_lock_signal (lock); + g_static_mutex_unlock (&lock->mutex); +} + +void +g_static_rw_lock_free (GStaticRWLock* lock) +{ + g_return_if_fail (lock); + + if (lock->read_cond) + { + g_cond_free (lock->read_cond); + lock->read_cond = NULL; + } + if (lock->write_cond) + { + g_cond_free (lock->write_cond); + lock->write_cond = NULL; + } + g_static_mutex_free (&lock->mutex); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gthread.h b/graf2d/win32gdk/gdk/src/glib/gthread.h index 12681784be2be..d4573a1b83cea 100644 --- a/graf2d/win32gdk/gdk/src/glib/gthread.h +++ b/graf2d/win32gdk/gdk/src/glib/gthread.h @@ -27,34 +27,23 @@ #ifndef __G_THREAD_H__ #define __G_THREAD_H__ -#include <gerror.h> +#include <glib/gerror.h> +#include <glib/gtypes.h> G_BEGIN_DECLS -#ifndef GLIB_VAR -# ifdef G_OS_WIN32 -# ifdef GLIB_COMPILATION -# define GLIB_VAR __declspec(dllexport) -# else /* !GLIB_COMPILATION */ -# define GLIB_VAR extern __declspec(dllimport) -# endif /* !GLIB_COMPILATION */ -# else /* !G_OS_WIN32 */ -# define GLIB_VAR extern -# endif /* !G_OS_WIN32 */ -#endif /* GLIB_VAR */ - /* GLib Thread support */ -extern GQuark g_thread_error_quark(); -#define G_THREAD_ERROR g_thread_error_quark() +extern GQuark g_thread_error_quark (void); +#define G_THREAD_ERROR g_thread_error_quark () typedef enum { G_THREAD_ERROR_AGAIN /* Resource temporarily unavailable */ } GThreadError; -typedef void (*GThreadFunc) (gpointer value); +typedef gpointer (*GThreadFunc) (gpointer data); typedef enum { @@ -67,9 +56,10 @@ typedef enum typedef struct _GThread GThread; struct _GThread { - GThreadPriority priority; - gboolean bound; + GThreadFunc func; + gpointer data; gboolean joinable; + GThreadPriority priority; }; typedef struct _GMutex GMutex; @@ -98,8 +88,8 @@ struct _GThreadFunctions gpointer (*private_get) (GPrivate *private_key); void (*private_set) (GPrivate *private_key, gpointer data); - void (*thread_create) (GThreadFunc thread_func, - gpointer arg, + void (*thread_create) (GThreadFunc func, + gpointer data, gulong stack_size, gboolean joinable, gboolean bound, @@ -112,6 +102,8 @@ struct _GThreadFunctions void (*thread_set_priority)(gpointer thread, GThreadPriority priority); void (*thread_self) (gpointer thread); + gboolean (*thread_equal) (gpointer thread1, + gpointer thread2); }; GLIB_VAR GThreadFunctions g_thread_functions_for_glib_use; @@ -147,7 +139,7 @@ GMutex* g_static_mutex_get_mutex_impl (GMutex **mutex); #define G_THREAD_UF(op, arglist) \ (*g_thread_functions_for_glib_use . op) arglist -#define G_THREAD_CF(op, fail, arg) \ +#define G_THREAD_CF(op, fail, arg) \ (g_thread_supported () ? G_THREAD_UF (op, arg) : (fail)) #define G_THREAD_ECF(op, fail, mutex, type) \ (g_thread_supported () ? ((type(*)(GMutex*, gulong, gchar*)) \ @@ -155,37 +147,40 @@ GMutex* g_static_mutex_get_mutex_impl (GMutex **mutex); (mutex, G_MUTEX_DEBUG_MAGIC, G_STRLOC) : (fail)) #ifndef G_ERRORCHECK_MUTEXES -# define g_mutex_lock(mutex) \ +# define g_mutex_lock(mutex) \ G_THREAD_CF (mutex_lock, (void)0, (mutex)) -# define g_mutex_trylock(mutex) \ +# define g_mutex_trylock(mutex) \ G_THREAD_CF (mutex_trylock, TRUE, (mutex)) -# define g_mutex_unlock(mutex) \ +# define g_mutex_unlock(mutex) \ G_THREAD_CF (mutex_unlock, (void)0, (mutex)) -# define g_cond_wait(cond, mutex) \ +# define g_mutex_free(mutex) \ + G_THREAD_CF (mutex_free, (void)0, (mutex)) +# define g_cond_wait(cond, mutex) \ G_THREAD_CF (cond_wait, (void)0, (cond, mutex)) -# define g_cond_timed_wait(cond, mutex, abs_time) \ +# define g_cond_timed_wait(cond, mutex, abs_time) \ G_THREAD_CF (cond_timed_wait, TRUE, (cond, mutex, abs_time)) #else /* G_ERRORCHECK_MUTEXES */ -# define g_mutex_lock(mutex) \ - G_THREAD_ECF (mutex_lock, (void)0, mutex, void) -# define g_mutex_trylock(mutex) \ - G_THREAD_ECF (mutex_trylock, TRUE, mutex, gboolean) -# define g_mutex_unlock(mutex) \ - G_THREAD_ECF (mutex_unlock, (void)0, mutex, void) +# define g_mutex_lock(mutex) \ + G_THREAD_ECF (mutex_lock, (void)0, (mutex), void) +# define g_mutex_trylock(mutex) \ + G_THREAD_ECF (mutex_trylock, TRUE, (mutex), gboolean) +# define g_mutex_unlock(mutex) \ + G_THREAD_ECF (mutex_unlock, (void)0, (mutex), void) +# define g_mutex_free(mutex) \ + G_THREAD_ECF (mutex_free, (void)0, (mutex), void) # define g_cond_wait(cond, mutex) \ (g_thread_supported () ? ((void(*)(GCond*, GMutex*, gulong, gchar*))\ g_thread_functions_for_glib_use.cond_wait) \ (cond, mutex, G_MUTEX_DEBUG_MAGIC, G_STRLOC) : (void) 0) -# define g_cond_timed_wait(cond, mutex, abs_time) \ - (g_thread_supported () ? \ +# define g_cond_timed_wait(cond, mutex, abs_time) \ + (g_thread_supported () ? \ ((gboolean(*)(GCond*, GMutex*, GTimeVal*, gulong, gchar*)) \ - g_thread_functions_for_glib_use.cond_timed_wait) \ + g_thread_functions_for_glib_use.cond_timed_wait) \ (cond, mutex, abs_time, G_MUTEX_DEBUG_MAGIC, G_STRLOC) : TRUE) #endif /* G_ERRORCHECK_MUTEXES */ #define g_thread_supported() (g_threads_got_initialized) #define g_mutex_new() G_THREAD_UF (mutex_new, ()) -#define g_mutex_free(mutex) G_THREAD_CF (mutex_free, (void)0, (mutex)) #define g_cond_new() G_THREAD_UF (cond_new, ()) #define g_cond_signal(cond) G_THREAD_CF (cond_signal, (void)0, (cond)) #define g_cond_broadcast(cond) G_THREAD_CF (cond_broadcast, (void)0, (cond)) @@ -199,19 +194,24 @@ GMutex* g_static_mutex_get_mutex_impl (GMutex **mutex); (GPrivate*) (value)), \ (private_key, value)) #define g_thread_yield() G_THREAD_CF (thread_yield, (void)0, ()) -#define g_thread_exit() G_THREAD_CF (thread_exit, (void)0, ()) - -GThread* g_thread_create (GThreadFunc thread_func, - gpointer arg, - gulong stack_size, - gboolean joinable, - gboolean bound, - GThreadPriority priority, - GError **error); -GThread* g_thread_self (void); -void g_thread_join (GThread *thread); -void g_thread_set_priority (GThread *thread, - GThreadPriority priority); + +#define g_thread_create(func, data, joinable, error) \ + (g_thread_create_full (func, data, 0, joinable, FALSE, \ + G_THREAD_PRIORITY_NORMAL, error)) + +GThread* g_thread_create_full (GThreadFunc func, + gpointer data, + gulong stack_size, + gboolean joinable, + gboolean bound, + GThreadPriority priority, + GError **error); +GThread* g_thread_self (void); +void g_thread_exit (gpointer retval); +gpointer g_thread_join (GThread *thread); + +void g_thread_set_priority (GThread *thread, + GThreadPriority priority); /* GStaticMutexes can be statically initialized with the value * G_STATIC_MUTEX_INIT, and then they can directly be used, that is @@ -224,22 +224,20 @@ void g_thread_set_priority (GThread *thread, g_mutex_trylock (g_static_mutex_get_mutex (mutex)) #define g_static_mutex_unlock(mutex) \ g_mutex_unlock (g_static_mutex_get_mutex (mutex)) +void g_static_mutex_init (GStaticMutex *mutex); +void g_static_mutex_free (GStaticMutex *mutex); struct _GStaticPrivate { guint index; }; #define G_STATIC_PRIVATE_INIT { 0 } -gpointer g_static_private_get (GStaticPrivate *private_key); -void g_static_private_set (GStaticPrivate *private_key, - gpointer data, - GDestroyNotify notify); -gpointer g_static_private_get_for_thread (GStaticPrivate *private_key, - GThread *thread); -void g_static_private_set_for_thread (GStaticPrivate *private_key, - GThread *thread, - gpointer data, - GDestroyNotify notify); +void g_static_private_init (GStaticPrivate *private_key); +gpointer g_static_private_get (GStaticPrivate *private_key); +void g_static_private_set (GStaticPrivate *private_key, + gpointer data, + GDestroyNotify notify); +void g_static_private_free (GStaticPrivate *private_key); typedef struct _GStaticRecMutex GStaticRecMutex; struct _GStaticRecMutex @@ -250,12 +248,14 @@ struct _GStaticRecMutex }; #define G_STATIC_REC_MUTEX_INIT { G_STATIC_MUTEX_INIT } +void g_static_rec_mutex_init (GStaticRecMutex *mutex); void g_static_rec_mutex_lock (GStaticRecMutex *mutex); gboolean g_static_rec_mutex_trylock (GStaticRecMutex *mutex); void g_static_rec_mutex_unlock (GStaticRecMutex *mutex); void g_static_rec_mutex_lock_full (GStaticRecMutex *mutex, guint depth); guint g_static_rec_mutex_unlock_full (GStaticRecMutex *mutex); +void g_static_rec_mutex_free (GStaticRecMutex *mutex); typedef struct _GStaticRWLock GStaticRWLock; struct _GStaticRWLock @@ -265,18 +265,20 @@ struct _GStaticRWLock GCond *write_cond; guint read_counter; gboolean write; + guint want_to_read; guint want_to_write; }; -#define G_STATIC_RW_LOCK_INIT { G_STATIC_MUTEX_INIT, NULL, NULL, 0, FALSE, FALSE } +#define G_STATIC_RW_LOCK_INIT { G_STATIC_MUTEX_INIT, NULL, NULL, 0, FALSE, 0, 0 } +void g_static_rw_lock_init (GStaticRWLock* lock); void g_static_rw_lock_reader_lock (GStaticRWLock* lock); gboolean g_static_rw_lock_reader_trylock (GStaticRWLock* lock); void g_static_rw_lock_reader_unlock (GStaticRWLock* lock); void g_static_rw_lock_writer_lock (GStaticRWLock* lock); gboolean g_static_rw_lock_writer_trylock (GStaticRWLock* lock); void g_static_rw_lock_writer_unlock (GStaticRWLock* lock); -void g_static_rw_lock_free (GStaticRWLock* lock); +void g_static_rw_lock_free (GStaticRWLock* lock); /* these are some convenience macros that expand to nothing if GLib * was configured with --disable-threads. for using StaticMutexes, diff --git a/graf2d/win32gdk/gdk/src/glib/gthreadpool.c b/graf2d/win32gdk/gdk/src/glib/gthreadpool.c new file mode 100644 index 0000000000000..601022830c4cf --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gthreadpool.c @@ -0,0 +1,678 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * GAsyncQueue: thread pool implementation. + * Copyright (C) 2000 Sebastian Wilhelmi; University of Karlsruhe + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * MT safe + */ + +#include "glib.h" + +typedef struct _GRealThreadPool GRealThreadPool; + +struct _GRealThreadPool +{ + GThreadPool pool; + GAsyncQueue* queue; + gint max_threads; + gint num_threads; + gboolean running; + gboolean immediate; + gboolean waiting; +}; + +/* The following is just an address to mark the stop order for a + * thread, it could be any address (as long, as it isn't a valid + * GThreadPool address) */ +static const gpointer stop_this_thread_marker = (gpointer) &g_thread_pool_new; + +/* Here all unused threads are waiting */ +static GAsyncQueue *unused_thread_queue; +static gint unused_threads = 0; +static gint max_unused_threads = 0; +G_LOCK_DEFINE_STATIC (unused_threads); + +static GMutex *inform_mutex = NULL; +static GCond *inform_cond = NULL; + +static void g_thread_pool_free_internal (GRealThreadPool* pool); +static gpointer g_thread_pool_thread_proxy (gpointer data); +static void g_thread_pool_start_thread (GRealThreadPool* pool, + GError **error); +static void g_thread_pool_wakeup_and_stop_all (GRealThreadPool* pool); + +#define g_thread_should_run(pool, len) \ + ((pool)->running || (!(pool)->immediate && (len) > 0)) + +static gpointer +g_thread_pool_thread_proxy (gpointer data) +{ + GRealThreadPool *pool = data; + gboolean watcher = FALSE; + + g_async_queue_lock (pool->queue); + while (TRUE) + { + gpointer task; + gboolean goto_global_pool = !pool->pool.exclusive; + gint len = g_async_queue_length_unlocked (pool->queue); + + if (g_thread_should_run (pool, len)) + { + if (watcher) + { + /* This thread is actually not needed here, but it waits + * for some time anyway. If during that time a new + * request arrives, this saves process + * swicthes. Otherwise the thread will go to the global + * pool afterwards */ + GTimeVal end_time; + g_get_current_time (&end_time); + g_time_val_add (&end_time, G_USEC_PER_SEC / 2); /* 1/2 second */ + task = g_async_queue_timed_pop_unlocked (pool->queue, &end_time); + } + else + task = g_async_queue_pop_unlocked (pool->queue); + + if (task) + { + watcher = FALSE; + if (pool->num_threads > pool->max_threads && + pool->max_threads != -1) + /* We are in fact a superfluous threads, so we go to + * the global pool and just hand the data further to + * the next one waiting in the queue */ + { + g_async_queue_push_unlocked (pool->queue, task); + goto_global_pool = TRUE; + } + else if (pool->running || !pool->immediate) + { + g_async_queue_unlock (pool->queue); + pool->pool.func (task, pool->pool.user_data); + g_async_queue_lock (pool->queue); + } + } + len = g_async_queue_length_unlocked (pool->queue); + } + + if (!g_thread_should_run (pool, len)) + { + g_cond_broadcast (inform_cond); + goto_global_pool = TRUE; + } + else if (len > 0) + { + /* At this pool there are no threads waiting, but tasks are. */ + goto_global_pool = FALSE; + } + else if (len == 0 && !watcher && !pool->pool.exclusive) + { + /* Here neither threads nor tasks are queued and we didn't + * just return from a timed wait. We now wait for a limited + * time at this pool for new tasks to avoid costly context + * switches. */ + goto_global_pool = FALSE; + watcher = TRUE; + } + + + if (goto_global_pool) + { + pool->num_threads--; + + if (!pool->running && !pool->waiting) + { + if (pool->num_threads == 0) + { + g_async_queue_unlock (pool->queue); + g_thread_pool_free_internal (pool); + } + else if (len == - pool->num_threads) + { + g_thread_pool_wakeup_and_stop_all (pool); + g_async_queue_unlock (pool->queue); + } + } + else + g_async_queue_unlock (pool->queue); + + g_async_queue_lock (unused_thread_queue); + + G_LOCK (unused_threads); + if ((unused_threads >= max_unused_threads && + max_unused_threads != -1)) + { + G_UNLOCK (unused_threads); + g_async_queue_unlock (unused_thread_queue); + /* Stop this thread */ + return NULL; + } + unused_threads++; + G_UNLOCK (unused_threads); + + pool = g_async_queue_pop_unlocked (unused_thread_queue); + + G_LOCK (unused_threads); + unused_threads--; + G_UNLOCK (unused_threads); + + g_async_queue_unlock (unused_thread_queue); + + if (pool == stop_this_thread_marker) + /* Stop this thread */ + return NULL; + + g_async_queue_lock (pool->queue); + + /* pool->num_threads++ is not done here, but in + * g_thread_pool_start_thread to make the new started thread + * known to the pool, before itself can do it. */ + } + } + return NULL; +} + +static void +g_thread_pool_start_thread (GRealThreadPool *pool, + GError **error) +{ + gboolean success = FALSE; + + if (pool->num_threads >= pool->max_threads && pool->max_threads != -1) + /* Enough threads are already running */ + return; + + g_async_queue_lock (unused_thread_queue); + + if (g_async_queue_length_unlocked (unused_thread_queue) < 0) + { + g_async_queue_push_unlocked (unused_thread_queue, pool); + success = TRUE; + } + + g_async_queue_unlock (unused_thread_queue); + + if (!success) + { + GError *local_error = NULL; + /* No thread was found, we have to start a new one */ + g_thread_create (g_thread_pool_thread_proxy, pool, FALSE, &local_error); + + if (local_error) + { + g_propagate_error (error, local_error); + return; + } + } + + /* See comment in g_thread_pool_thread_proxy as to why this is done + * here and not there */ + pool->num_threads++; +} + +/** + * g_thread_pool_new: + * @func: a function to execute in the threads of the new thread pool + * @user_data: user data that is handed over to @func every time it + * is called + * @max_threads: the maximal number of threads to execute concurrently in + * the new thread pool, -1 means no limit + * @exclusive: should this thread pool be exclusive? + * @error: return location for error + * + * This function creates a new thread pool. + * + * Whenever you call g_thread_pool_push(), either a new thread is + * created or an unused one is reused. At most @max_threads threads + * are running concurrently for this thread pool. @max_threads = -1 + * allows unlimited threads to be created for this thread pool. The + * newly created or reused thread now executes the function @func with + * the two arguments. The first one is the parameter to + * g_thread_pool_push() and the second one is @user_data. + * + * The parameter @exclusive determines, whether the thread pool owns + * all threads exclusive or whether the threads are shared + * globally. If @exclusive is @TRUE, @max_threads threads are started + * immediately and they will run exclusively for this thread pool until + * it is destroyed by g_thread_pool_free(). If @exclusive is @FALSE, + * threads are created, when needed and shared between all + * non-exclusive thread pools. This implies that @max_threads may not + * be -1 for exclusive thread pools. + * + * @error can be NULL to ignore errors, or non-NULL to report + * errors. An error can only occur, when @exclusive is set to @TRUE and + * not all @max_threads threads could be created. + * + * Return value: the new #GThreadPool + **/ +GThreadPool* +g_thread_pool_new (GFunc func, + gpointer user_data, + gint max_threads, + gboolean exclusive, + GError **error) +{ + GRealThreadPool *retval; + G_LOCK_DEFINE_STATIC (init); + + g_return_val_if_fail (func, NULL); + g_return_val_if_fail (!exclusive || max_threads != -1, NULL); + g_return_val_if_fail (max_threads >= -1, NULL); + g_return_val_if_fail (g_thread_supported (), NULL); + + retval = g_new (GRealThreadPool, 1); + + retval->pool.func = func; + retval->pool.user_data = user_data; + retval->pool.exclusive = exclusive; + retval->queue = g_async_queue_new (); + retval->max_threads = max_threads; + retval->num_threads = 0; + retval->running = TRUE; + + G_LOCK (init); + + if (!inform_mutex) + { + inform_mutex = g_mutex_new (); + inform_cond = g_cond_new (); + unused_thread_queue = g_async_queue_new (); + } + + G_UNLOCK (init); + + if (retval->pool.exclusive) + { + g_async_queue_lock (retval->queue); + + while (retval->num_threads < retval->max_threads) + { + GError *local_error = NULL; + g_thread_pool_start_thread (retval, &local_error); + if (local_error) + { + g_propagate_error (error, local_error); + break; + } + } + + g_async_queue_unlock (retval->queue); + } + + return (GThreadPool*) retval; +} + +/** + * g_thread_pool_push: + * @pool: a #GThreadPool + * @data: a new task for @pool + * @error: return location for error + * + * Inserts @data into the list of tasks to be executed by @pool. When + * the number of currently running threads is lower than the maximal + * allowed number of threads, a new thread is started (or reused) with + * the properties given to g_thread_pool_new (). Otherwise @data stays + * in the queue until a thread in this pool finishes its previous task + * and processes @data. + * + * @error can be NULL to ignore errors, or non-NULL to report + * errors. An error can only occur, when a new thread couldn't be + * created. In that case @data is simply appended to the queue of work + * to do. + **/ +void +g_thread_pool_push (GThreadPool *pool, + gpointer data, + GError **error) +{ + GRealThreadPool *real = (GRealThreadPool*) pool; + + g_return_if_fail (real); + + g_async_queue_lock (real->queue); + + if (!real->running) + { + g_async_queue_unlock (real->queue); + g_return_if_fail (real->running); + } + + if (g_async_queue_length_unlocked (real->queue) >= 0) + /* No thread is waiting in the queue */ + g_thread_pool_start_thread (real, error); + + g_async_queue_push_unlocked (real->queue, data); + g_async_queue_unlock (real->queue); +} + +/** + * g_thread_pool_set_max_threads: + * @pool: a #GThreadPool + * @max_threads: a new maximal number of threads for @pool + * @error: return location for error + * + * Sets the maximal allowed number of threads for @pool. A value of -1 + * means, that the maximal number of threads is unlimited. + * + * Setting @max_threads to 0 means stopping all work for @pool. It is + * effectively frozen until @max_threads is set to a non-zero value + * again. + * + * A thread is never terminated while calling @func, as supplied by + * g_thread_pool_new (). Instead the maximal number of threads only + * has effect for the allocation of new threads in g_thread_pool_push + * (). A new thread is allocated, whenever the number of currently + * running threads in @pool is smaller than the maximal number. + * + * @error can be NULL to ignore errors, or non-NULL to report + * errors. An error can only occur, when a new thread couldn't be + * created. + **/ +void +g_thread_pool_set_max_threads (GThreadPool *pool, + gint max_threads, + GError **error) +{ + GRealThreadPool *real = (GRealThreadPool*) pool; + gint to_start; + + g_return_if_fail (real); + g_return_if_fail (real->running); + g_return_if_fail (!real->pool.exclusive || max_threads != -1); + g_return_if_fail (max_threads >= -1); + + g_async_queue_lock (real->queue); + + real->max_threads = max_threads; + + if (pool->exclusive) + to_start = real->max_threads - real->num_threads; + else + to_start = g_async_queue_length_unlocked (real->queue); + + for ( ; to_start > 0; to_start--) + { + GError *local_error = NULL; + g_thread_pool_start_thread (real, &local_error); + if (local_error) + { + g_propagate_error (error, local_error); + break; + } + } + + g_async_queue_unlock (real->queue); +} + +/** + * g_thread_pool_get_max_threads: + * @pool: a #GThreadPool + * + * Returns the maximal number of threads for @pool. + * + * Return value: the maximal number of threads + **/ +gint +g_thread_pool_get_max_threads (GThreadPool *pool) +{ + GRealThreadPool *real = (GRealThreadPool*) pool; + gint retval; + + g_return_val_if_fail (real, 0); + g_return_val_if_fail (real->running, 0); + + g_async_queue_lock (real->queue); + + retval = real->max_threads; + + g_async_queue_unlock (real->queue); + + return retval; +} + +/** + * g_thread_pool_get_num_threads: + * @pool: a #GThreadPool + * + * Returns the number of threads currently running in @pool. + * + * Return value: the number of threads currently running + **/ +guint +g_thread_pool_get_num_threads (GThreadPool *pool) +{ + GRealThreadPool *real = (GRealThreadPool*) pool; + guint retval; + + g_return_val_if_fail (real, 0); + g_return_val_if_fail (real->running, 0); + + g_async_queue_lock (real->queue); + + retval = real->num_threads; + + g_async_queue_unlock (real->queue); + + return retval; +} + +/** + * g_thread_pool_unprocessed: + * @pool: a #GThreadPool + * + * Returns the number of tasks still unprocessed in @pool. + * + * Return value: the number of unprocessed tasks + **/ +guint +g_thread_pool_unprocessed (GThreadPool *pool) +{ + GRealThreadPool *real = (GRealThreadPool*) pool; + gint unprocessed; + + g_return_val_if_fail (real, 0); + g_return_val_if_fail (real->running, 0); + + unprocessed = g_async_queue_length (real->queue); + + return MAX (unprocessed, 0); +} + +/** + * g_thread_pool_free: + * @pool: a #GThreadPool + * @immediate: should @pool shut down immediately? + * @wait: should the function wait for all tasks to be finished? + * + * Frees all resources allocated for @pool. + * + * If @immediate is #TRUE, no new task is processed for + * @pool. Otherwise @pool is not freed before the last task is + * processed. Note however, that no thread of this pool is + * interrupted, while processing a task. Instead at least all still + * running threads can finish their tasks before the @pool is freed. + * + * If @wait is #TRUE, the functions does not return before all tasks + * to be processed (dependent on @immediate, whether all or only the + * currently running) are ready. Otherwise the function returns immediately. + * + * After calling this function @pool must not be used anymore. + **/ +void +g_thread_pool_free (GThreadPool *pool, + gboolean immediate, + gboolean wait) +{ + GRealThreadPool *real = (GRealThreadPool*) pool; + + g_return_if_fail (real); + g_return_if_fail (real->running); + /* It there's no thread allowed here, there is not much sense in + * not stopping this pool immediately, when it's not empty */ + g_return_if_fail (immediate || real->max_threads != 0 || + g_async_queue_length (real->queue) == 0); + + g_async_queue_lock (real->queue); + + real->running = FALSE; + real->immediate = immediate; + real->waiting = wait; + + if (wait) + { + g_mutex_lock (inform_mutex); + while (g_async_queue_length_unlocked (real->queue) != -real->num_threads) + { + g_async_queue_unlock (real->queue); + g_cond_wait (inform_cond, inform_mutex); + g_async_queue_lock (real->queue); + } + g_mutex_unlock (inform_mutex); + } + + if (g_async_queue_length_unlocked (real->queue) == -real->num_threads) + { + /* No thread is currently doing something (and nothing is left + * to process in the queue) */ + if (real->num_threads == 0) /* No threads left, we clean up */ + { + g_async_queue_unlock (real->queue); + g_thread_pool_free_internal (real); + return; + } + + g_thread_pool_wakeup_and_stop_all (real); + } + + real->waiting = FALSE; /* The last thread should cleanup the pool */ + g_async_queue_unlock (real->queue); +} + +static void +g_thread_pool_free_internal (GRealThreadPool* pool) +{ + g_return_if_fail (pool); + g_return_if_fail (!pool->running); + g_return_if_fail (pool->num_threads == 0); + + g_async_queue_unref (pool->queue); + + g_free (pool); +} + +static void +g_thread_pool_wakeup_and_stop_all (GRealThreadPool* pool) +{ + guint i; + + g_return_if_fail (pool); + g_return_if_fail (!pool->running); + g_return_if_fail (pool->num_threads != 0); + g_return_if_fail (g_async_queue_length_unlocked (pool->queue) == + -pool->num_threads); + + pool->immediate = TRUE; + for (i = 0; i < pool->num_threads; i++) + g_async_queue_push_unlocked (pool->queue, GUINT_TO_POINTER (1)); +} + +/** + * g_thread_pool_set_max_unused_threads: + * @max_threads: maximal number of unused threads + * + * Sets the maximal number of unused threads to @max_threads. If + * @max_threads is -1, no limit is imposed on the number of unused + * threads. + **/ +void +g_thread_pool_set_max_unused_threads (gint max_threads) +{ + g_return_if_fail (max_threads >= -1); + + G_LOCK (unused_threads); + + max_unused_threads = max_threads; + + if (max_unused_threads < unused_threads && max_unused_threads != -1) + { + guint i; + + g_async_queue_lock (unused_thread_queue); + for (i = unused_threads - max_unused_threads; i > 0; i--) + g_async_queue_push_unlocked (unused_thread_queue, + stop_this_thread_marker); + g_async_queue_unlock (unused_thread_queue); + } + + G_UNLOCK (unused_threads); +} + +/** + * g_thread_pool_get_max_unused_threads: + * + * Returns the maximal allowed number of unused threads. + * + * Return value: the maximal number of unused threads + **/ +gint +g_thread_pool_get_max_unused_threads (void) +{ + gint retval; + + G_LOCK (unused_threads); + retval = max_unused_threads; + G_UNLOCK (unused_threads); + + return retval; +} + +/** + * g_thread_pool_get_num_unused_threads: + * + * Returns the number of currently unused threads. + * + * Return value: the number of currently unused threads + **/ +guint g_thread_pool_get_num_unused_threads (void) +{ + guint retval; + + G_LOCK (unused_threads); + retval = unused_threads; + G_UNLOCK (unused_threads); + + return retval; +} + +/** + * g_thread_pool_stop_unused_threads: + * + * Stops all currently unused threads. This does not change the + * maximal number of unused threads. This function can be used to + * regularly stop all unused threads e.g. from g_timeout_add(). + **/ +void g_thread_pool_stop_unused_threads (void) +{ + guint oldval = g_thread_pool_get_max_unused_threads (); + g_thread_pool_set_max_unused_threads (0); + g_thread_pool_set_max_unused_threads (oldval); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gthreadpool.h b/graf2d/win32gdk/gdk/src/glib/gthreadpool.h index d6fa87c8a984f..ed1e81ba350c3 100644 --- a/graf2d/win32gdk/gdk/src/glib/gthreadpool.h +++ b/graf2d/win32gdk/gdk/src/glib/gthreadpool.h @@ -27,7 +27,7 @@ #ifndef __G_THREADPOOL_H__ #define __G_THREADPOOL_H__ -#include <gthread.h> +#include <glib/gthread.h> G_BEGIN_DECLS @@ -40,26 +40,20 @@ typedef struct _GThreadPool GThreadPool; * pool with the constructor function */ struct _GThreadPool { - GFunc thread_func; - gulong stack_size; - gboolean bound; - GThreadPriority priority; - gboolean exclusive; + GFunc func; gpointer user_data; + gboolean exclusive; }; -/* Get a thread pool with the function thread_func, at most max_threads may - * run at a time (max_threads == -1 means no limit), stack_size, bound, - * priority like in g_thread_create, exclusive == TRUE means, that the threads - * shouldn't be shared and that they will be prestarted (otherwise they are - * started, as needed) user_data is the 2nd argument to the thread_func */ -GThreadPool* g_thread_pool_new (GFunc thread_func, +/* Get a thread pool with the function func, at most max_threads may + * run at a time (max_threads == -1 means no limit), exclusive == TRUE + * means, that the threads shouldn't be shared and that they will be + * prestarted (otherwise they are started as needed) user_data is the + * 2nd argument to the func */ +GThreadPool* g_thread_pool_new (GFunc func, + gpointer user_data, gint max_threads, - gulong stack_size, - gboolean bound, - GThreadPriority priority, gboolean exclusive, - gpointer user_data, GError **error); /* Push new data into the thread pool. This task is assigned to a thread later diff --git a/graf2d/win32gdk/gdk/src/glib/gtimer.c b/graf2d/win32gdk/gdk/src/glib/gtimer.c new file mode 100644 index 0000000000000..f06d5bb9e7ff2 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gtimer.c @@ -0,0 +1,261 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include "glib.h" +#ifdef HAVE_UNISTD_H +#include <unistd.h> +#endif /* HAVE_UNISTD_H */ +#ifndef G_OS_WIN32 +#include <sys/time.h> +#include <time.h> +#include <errno.h> +#endif /* G_OS_WIN32 */ + +#ifdef G_OS_WIN32 +#include <windows.h> +#endif /* G_OS_WIN32 */ + +struct _GTimer +{ +#ifdef G_OS_WIN32 + DWORD start; + DWORD end; +#else /* !G_OS_WIN32 */ + struct timeval start; + struct timeval end; +#endif /* !G_OS_WIN32 */ + + guint active : 1; +}; + +#ifdef G_OS_WIN32 +# define GETTIME(v) \ + v = GetTickCount () +#else /* !G_OS_WIN32 */ +# define GETTIME(v) \ + gettimeofday (&v, NULL) +#endif /* !G_OS_WIN32 */ + +GTimer* +g_timer_new (void) +{ + GTimer *timer; + + timer = g_new (GTimer, 1); + timer->active = TRUE; + + GETTIME (timer->start); + + return timer; +} + +void +g_timer_destroy (GTimer *timer) +{ + g_return_if_fail (timer != NULL); + + g_free (timer); +} + +void +g_timer_start (GTimer *timer) +{ + g_return_if_fail (timer != NULL); + + timer->active = TRUE; + + GETTIME (timer->start); +} + +void +g_timer_stop (GTimer *timer) +{ + g_return_if_fail (timer != NULL); + + timer->active = FALSE; + + GETTIME(timer->end); +} + +void +g_timer_reset (GTimer *timer) +{ + g_return_if_fail (timer != NULL); + + GETTIME (timer->start); +} + +gdouble +g_timer_elapsed (GTimer *timer, + gulong *microseconds) +{ + gdouble total; +#ifndef G_OS_WIN32 + struct timeval elapsed; +#endif /* G_OS_WIN32 */ + + g_return_val_if_fail (timer != NULL, 0); + +#ifdef G_OS_WIN32 + if (timer->active) + timer->end = GetTickCount (); + + /* Check for wraparound, which happens every 49.7 days. */ + if (timer->end < timer->start) + total = (UINT_MAX - (timer->start - timer->end)) / 1000.0; + else + total = (timer->end - timer->start) / 1000.0; + + if (microseconds) + { + if (timer->end < timer->start) + *microseconds = + ((UINT_MAX - (timer->start - timer->end)) % 1000) * 1000; + else + *microseconds = + ((timer->end - timer->start) % 1000) * 1000; + } +#else /* !G_OS_WIN32 */ + if (timer->active) + gettimeofday (&timer->end, NULL); + + if (timer->start.tv_usec > timer->end.tv_usec) + { + timer->end.tv_usec += G_USEC_PER_SEC; + timer->end.tv_sec--; + } + + elapsed.tv_usec = timer->end.tv_usec - timer->start.tv_usec; + elapsed.tv_sec = timer->end.tv_sec - timer->start.tv_sec; + + total = elapsed.tv_sec + ((gdouble) elapsed.tv_usec / 1e6); + if (total < 0) + { + total = 0; + + if (microseconds) + *microseconds = 0; + } + else if (microseconds) + *microseconds = elapsed.tv_usec; + +#endif /* !G_OS_WIN32 */ + + return total; +} + +void +g_usleep (gulong microseconds) +{ +#ifdef G_OS_WIN32 + Sleep (microseconds / 1000); +#else /* !G_OS_WIN32 */ +# ifdef HAVE_NANOSLEEP + struct timespec request, remaining; + request.tv_sec = microseconds / G_USEC_PER_SEC; + request.tv_nsec = 1000 * (microseconds % G_USEC_PER_SEC); + while (nanosleep (&request, &remaining) == EINTR) + request = remaining; +# else /* !HAVE_NANOSLEEP */ + if (g_thread_supported ()) + { + static GStaticMutex mutex = G_STATIC_MUTEX_INIT; + static GCond* cond = NULL; + GTimeVal end_time; + + g_get_current_time (&end_time); + if (microseconds > G_MAXLONG) + { + microseconds -= G_MAXLONG; + g_time_val_add (&end_time, G_MAXLONG); + } + g_time_val_add (&end_time, microseconds); + + g_static_mutex_lock (&mutex); + + if (!cond) + cond = g_cond_new (); + + while (g_cond_timed_wait (cond, g_static_mutex_get_mutex (&mutex), + &end_time)) + /* do nothing */; + + g_static_mutex_unlock (&mutex); + } + else + { + struct timeval tv; + tv.tv_sec = microseconds / G_USEC_PER_SEC; + tv.tv_usec = microseconds % G_USEC_PER_SEC; + select(0, NULL, NULL, NULL, &tv); + } +# endif /* !HAVE_NANOSLEEP */ +#endif /* !G_OS_WIN32 */ +} + +/** + * g_time_val_add: + * @time: a #GTimeVal + * @microseconds: number of microseconds to add to @time + * + * Adds the given number of microseconds to @time. @microseconds can + * also be negative to decrease the value of @time. + **/ +void +g_time_val_add (GTimeVal *time, glong microseconds) +{ + g_return_if_fail (time->tv_usec >= 0 && time->tv_usec < G_USEC_PER_SEC); + + if (microseconds >= 0) + { + time->tv_usec += microseconds % G_USEC_PER_SEC; + time->tv_sec += microseconds / G_USEC_PER_SEC; + if (time->tv_usec >= G_USEC_PER_SEC) + { + time->tv_usec -= G_USEC_PER_SEC; + time->tv_sec++; + } + } + else + { + microseconds *= -1; + time->tv_usec -= microseconds % G_USEC_PER_SEC; + time->tv_sec -= microseconds / G_USEC_PER_SEC; + if (time->tv_usec < 0) + { + time->tv_usec += G_USEC_PER_SEC; + time->tv_sec--; + } + } +} diff --git a/graf2d/win32gdk/gdk/src/glib/gtimer.h b/graf2d/win32gdk/gdk/src/glib/gtimer.h index d537921e68a8e..3a9b265063d9a 100644 --- a/graf2d/win32gdk/gdk/src/glib/gtimer.h +++ b/graf2d/win32gdk/gdk/src/glib/gtimer.h @@ -27,7 +27,7 @@ #ifndef __G_TIMER_H__ #define __G_TIMER_H__ -#include <g_types.h> +#include <glib/gtypes.h> G_BEGIN_DECLS @@ -40,13 +40,17 @@ typedef struct _GTimer GTimer; #define G_USEC_PER_SEC 1000000 GTimer* g_timer_new (void); -void g_timer_destroy (GTimer *timer); -void g_timer_start (GTimer *timer); -void g_timer_stop (GTimer *timer); -void g_timer_reset (GTimer *timer); -gdouble g_timer_elapsed (GTimer *timer, - gulong *microseconds); -void g_usleep (gulong microseconds); +void g_timer_destroy (GTimer *timer); +void g_timer_start (GTimer *timer); +void g_timer_stop (GTimer *timer); +void g_timer_reset (GTimer *timer); +gdouble g_timer_elapsed (GTimer *timer, + gulong *microseconds); + +void g_usleep (gulong microseconds); + +void g_time_val_add (GTimeVal *time, + glong microseconds); G_END_DECLS diff --git a/graf2d/win32gdk/gdk/src/glib/gtree.c b/graf2d/win32gdk/gdk/src/glib/gtree.c new file mode 100644 index 0000000000000..5b0406bc2a347 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gtree.c @@ -0,0 +1,1066 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include "glib.h" + + +typedef struct _GTreeNode GTreeNode; + +struct _GTree +{ + GTreeNode *root; + GCompareDataFunc key_compare; + GDestroyNotify key_destroy_func; + GDestroyNotify value_destroy_func; + gpointer key_compare_data; +}; + +struct _GTreeNode +{ + gint balance; /* height (left) - height (right) */ + GTreeNode *left; /* left subtree */ + GTreeNode *right; /* right subtree */ + gpointer key; /* key for this node */ + gpointer value; /* value stored at this node */ +}; + + +static GTreeNode* g_tree_node_new (gpointer key, + gpointer value); +static void g_tree_node_destroy (GTreeNode *node, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func); +static GTreeNode* g_tree_node_insert (GTree *tree, + GTreeNode *node, + gpointer key, + gpointer value, + gboolean replace, + gboolean *inserted); +static GTreeNode* g_tree_node_remove (GTree *tree, + GTreeNode *node, + gconstpointer key, + gboolean notify); +static GTreeNode* g_tree_node_balance (GTreeNode *node); +static GTreeNode* g_tree_node_remove_leftmost (GTreeNode *node, + GTreeNode **leftmost); +static GTreeNode* g_tree_node_restore_left_balance (GTreeNode *node, + gint old_balance); +static GTreeNode* g_tree_node_restore_right_balance (GTreeNode *node, + gint old_balance); +static GTreeNode* g_tree_node_lookup (GTreeNode *node, + GCompareDataFunc compare, + gpointer comp_data, + gconstpointer key); +static gint g_tree_node_count (GTreeNode *node); +static gint g_tree_node_pre_order (GTreeNode *node, + GTraverseFunc traverse_func, + gpointer data); +static gint g_tree_node_in_order (GTreeNode *node, + GTraverseFunc traverse_func, + gpointer data); +static gint g_tree_node_post_order (GTreeNode *node, + GTraverseFunc traverse_func, + gpointer data); +static gpointer g_tree_node_search (GTreeNode *node, + GCompareFunc search_func, + gconstpointer data); +static gint g_tree_node_height (GTreeNode *node); +static GTreeNode* g_tree_node_rotate_left (GTreeNode *node); +static GTreeNode* g_tree_node_rotate_right (GTreeNode *node); +static void g_tree_node_check (GTreeNode *node); + + +G_LOCK_DEFINE_STATIC (g_tree_global); +static GMemChunk *node_mem_chunk = NULL; +static GTreeNode *node_free_list = NULL; + + +static GTreeNode* +g_tree_node_new (gpointer key, + gpointer value) +{ + GTreeNode *node; + + G_LOCK (g_tree_global); + if (node_free_list) + { + node = node_free_list; + node_free_list = node->right; + } + else + { + if (!node_mem_chunk) + node_mem_chunk = g_mem_chunk_new ("GLib GTreeNode mem chunk", + sizeof (GTreeNode), + 1024, + G_ALLOC_ONLY); + + node = g_chunk_new (GTreeNode, node_mem_chunk); + } + G_UNLOCK (g_tree_global); + + node->balance = 0; + node->left = NULL; + node->right = NULL; + node->key = key; + node->value = value; + + return node; +} + +static void +g_tree_node_destroy (GTreeNode *node, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func) +{ + if (node) + { + g_tree_node_destroy (node->right, + key_destroy_func, value_destroy_func); + g_tree_node_destroy (node->left, + key_destroy_func, value_destroy_func); + + if (key_destroy_func) + key_destroy_func (node->key); + if (value_destroy_func) + value_destroy_func (node->value); + +#ifdef ENABLE_GC_FRIENDLY + node->left = NULL; + node->key = NULL; + node->value = NULL; +#endif /* ENABLE_GC_FRIENDLY */ + + G_LOCK (g_tree_global); + node->right = node_free_list; + node_free_list = node; + G_UNLOCK (g_tree_global); + } +} + +/** + * g_tree_new: + * @key_compare_func: the function used to order the nodes in the #GTree. + * It should return values similar to the standard + * <function>strcmp()</function> function - + * 0 if the two arguments are equal, a negative value if the first argument + * comes before the second, or a positive value if the first argument comes + * after the second. + * + * Creates a new #GTree. + * + * Return value: a new #GTree. + **/ +GTree* +g_tree_new (GCompareFunc key_compare_func) +{ + g_return_val_if_fail (key_compare_func != NULL, NULL); + + return g_tree_new_full ((GCompareDataFunc) key_compare_func, NULL, + NULL, NULL); +} + +/** + * g_tree_new_with_data: + * @key_compare_func: qsort()-style comparison function. + * @key_compare_data: data to pass to comparison function. + * + * Creates a new #GTree with a comparison function that accepts user data. + * See g_tree_new() for more details. + * + * Return value: a new #GTree. + **/ +GTree* +g_tree_new_with_data (GCompareDataFunc key_compare_func, + gpointer key_compare_data) +{ + g_return_val_if_fail (key_compare_func != NULL, NULL); + + return g_tree_new_full (key_compare_func, key_compare_data, + NULL, NULL); +} + +/** + * g_tree_new_full: + * @key_compare_func: qsort()-style comparison function. + * @key_compare_data: data to pass to comparison function. + * @key_destroy_func: a function to free the memory allocated for the key + * used when removing the entry from the #GTree or #NULL if you don't + * want to supply such a function. + * @value_destroy_func: a function to free the memory allocated for the + * value used when removing the entry from the #GTree or #NULL if you + * don't want to supply such a function. + * + * Creates a new #GTree like g_tree_new() and allows to specify functions + * to free the memory allocated for the key and value that get called when + * removing the entry from the #GTree. + * + * Return value: a new #GTree. + **/ +GTree* +g_tree_new_full (GCompareDataFunc key_compare_func, + gpointer key_compare_data, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func) +{ + GTree *tree; + + g_return_val_if_fail (key_compare_func != NULL, NULL); + + tree = g_new (GTree, 1); + tree->root = NULL; + tree->key_compare = key_compare_func; + tree->key_destroy_func = key_destroy_func; + tree->value_destroy_func = value_destroy_func; + tree->key_compare_data = key_compare_data; + + return tree; +} + +/** + * g_tree_destroy: + * @tree: a #GTree. + * + * Destroys the #GTree. If keys and/or values are dynamically allocated, you + * should either free them first or create the #GTree using g_tree_new_full(). + * In the latter case the destroy functions you supplied will be called on + * all keys and values before destroying the #GTree. + **/ +void +g_tree_destroy (GTree *tree) +{ + g_return_if_fail (tree != NULL); + + g_tree_node_destroy (tree->root, + tree->key_destroy_func, + tree->value_destroy_func); + + g_free (tree); +} + +/** + * g_tree_insert: + * @tree: a #Gtree. + * @key: the key to insert. + * @value: the value corresponding to the key. + * + * Inserts a key/value pair into a #GTree. If the given key already exists + * in the #GTree its corresponding value is set to the new value. If you + * supplied a value_destroy_func when creating the #GTree, the old value is + * freed using that function. If you supplied a key_destroy_func when + * creating the #GTree, the passed key is freed using that function. + * + * The tree is automatically 'balanced' as new key/value pairs are added, + * so that the distance from the root to every leaf is as small as possible. + **/ +void +g_tree_insert (GTree *tree, + gpointer key, + gpointer value) +{ + gboolean inserted; + + g_return_if_fail (tree != NULL); + + inserted = FALSE; + tree->root = g_tree_node_insert (tree, + tree->root, + key, value, + FALSE, &inserted); +} + +/** + * g_tree_replace: + * @tree: a #Gtree. + * @key: the key to insert. + * @value: the value corresponding to the key. + * + * Inserts a new key and value into a #GTree similar to g_tree_insert(). + * The difference is that if the key already exists in the #GTree, it gets + * replaced by the new key. If you supplied a value_destroy_func when + * creating the #GTree, the old value is freed using that function. If you + * supplied a key_destroy_func when creating the #GTree, the old key is + * freed using that function. + * + * The tree is automatically 'balanced' as new key/value pairs are added, + * so that the distance from the root to every leaf is as small as possible. + **/ +void +g_tree_replace (GTree *tree, + gpointer key, + gpointer value) +{ + gboolean inserted; + + g_return_if_fail (tree != NULL); + + inserted = FALSE; + tree->root = g_tree_node_insert (tree, + tree->root, + key, value, + TRUE, &inserted); +} + +/** + * g_tree_remove: + * @tree: a #Gtree. + * @key: the key to remove. + * + * Removes a key/value pair from a #GTree. + * + * If the #GTree was created using g_tree_new_full(), the key and value + * are freed using the supplied destroy_functions, otherwise you have to + * make sure that any dynamically allocated values are freed yourself. + **/ +void +g_tree_remove (GTree *tree, + gconstpointer key) +{ + g_return_if_fail (tree != NULL); + + tree->root = g_tree_node_remove (tree, tree->root, key, TRUE); +} + +/** + * g_tree_steal: + * @tree: a #Gtree. + * @key: the key to remove. + * + * Removes a key and its associated value from a #GTree without calling + * the key and value destroy functions. + **/ +void +g_tree_steal (GTree *tree, + gconstpointer key) +{ + g_return_if_fail (tree != NULL); + + tree->root = g_tree_node_remove (tree, tree->root, key, FALSE); +} + +/** + * g_tree_lookup: + * @tree: a #GTree. + * @key: the key to look up. + * + * Gets the value corresponding to the given key. Since a #GTree is + * automatically balanced as key/value pairs are added, key lookup is very + * fast. + * + * Return value: the value corresponding to the key. + **/ +gpointer +g_tree_lookup (GTree *tree, + gconstpointer key) +{ + GTreeNode *node; + + g_return_val_if_fail (tree != NULL, NULL); + + node = g_tree_node_lookup (tree->root, + tree->key_compare, tree->key_compare_data, key); + + return node ? node->value : NULL; +} + +/** + * g_tree_lookup_extended: + * @tree: a #GTree. + * @lookup_key: the key to look up. + * @orig_key: returns the original key. + * @value: returns the value associated with the key. + * + * Looks up a key in the #GTree, returning the original key and the + * associated value and a gboolean which is TRUE if the key was found. This + * is useful if you need to free the memory allocated for the original key, + * for example before calling g_tree_remove(). + * + * Return value: #TRUE if the key was found in the #GTree. + **/ +gboolean +g_tree_lookup_extended (GTree *tree, + gconstpointer lookup_key, + gpointer *orig_key, + gpointer *value) +{ + GTreeNode *node; + + g_return_val_if_fail (tree != NULL, FALSE); + + node = g_tree_node_lookup (tree->root, + tree->key_compare, tree->key_compare_data, lookup_key); + + if (node) + { + if (orig_key) + *orig_key = node->key; + if (value) + *value = node->value; + return TRUE; + } + else + return FALSE; +} + +/** + * g_tree_foreach: + * @tree: a #GTree. + * @func: the function to call for each node visited. If this function + * returns TRUE, the traversal is stopped. + * @user_data: user data to pass to the function. + * + * Calls the given function for each of the key/value pairs in the #GTree. + * The function is passed the key and value of each pair, and the given + * @data parameter. + **/ +void +g_tree_foreach (GTree *tree, + GTraverseFunc func, + gpointer user_data) +{ + g_return_if_fail (tree != NULL); + + if (!tree->root) + return; + + g_tree_node_in_order (tree->root, func, user_data); +} + +/** + * g_tree_traverse: + * @tree: a #GTree. + * @traverse_func: the function to call for each node visited. If this + * function returns TRUE, the traversal is stopped. + * @traverse_type: the order in which nodes are visited, one of %G_IN_ORDER, + * %G_PRE_ORDER and %G_POST_ORDER. + * @user_data: user data to pass to the function. + * + * Calls the given function for each node in the GTree. This function is + * deprecated, use g_tree_foreach() instead. + **/ +void +g_tree_traverse (GTree *tree, + GTraverseFunc traverse_func, + GTraverseType traverse_type, + gpointer user_data) +{ + g_return_if_fail (tree != NULL); + + if (!tree->root) + return; + + switch (traverse_type) + { + case G_PRE_ORDER: + g_tree_node_pre_order (tree->root, traverse_func, user_data); + break; + + case G_IN_ORDER: + g_tree_node_in_order (tree->root, traverse_func, user_data); + break; + + case G_POST_ORDER: + g_tree_node_post_order (tree->root, traverse_func, user_data); + break; + + case G_LEVEL_ORDER: + g_warning ("g_tree_traverse(): traverse type G_LEVEL_ORDER isn't implemented."); + break; + } +} + +/** + * g_tree_search: + * @tree: a #GTree. + * @search_func: the comparison function used to search the #GTree. + * @user_data: the data passed as the second argument to the @search_func + * function. + * + * Searches a #GTree using an alternative form of the comparison function. + * + * This function is not as useful as it sounds. + * It allows you to use a different function for performing the lookup of + * a key. However, since the tree is ordered according to the @key_compare_func + * function passed to g_tree_new(), the function you pass to g_tree_search() + * must return exactly the same value as would be returned by the comparison + * function, for each pair of tree nodes, or the search will not work. + * + * To search for a specific value, you can use g_tree_foreach() or + * g_tree_traverse(). + * + * Return value: the value corresponding to the found key, or NULL if the key + * is not found. + **/ +gpointer +g_tree_search (GTree *tree, + GCompareFunc search_func, + gconstpointer user_data) +{ + g_return_val_if_fail (tree != NULL, NULL); + + if (tree->root) + return g_tree_node_search (tree->root, search_func, user_data); + else + return NULL; +} + +/** + * g_tree_height: + * @tree: a #GTree. + * + * Gets the height of a #GTree. + * + * If the #GTree contains no nodes, the height is 0. + * If the #GTree contains only one root node the height is 1. + * If the root node has children the height is 2, etc. + * + * Return value: the height of the #GTree. + **/ +gint +g_tree_height (GTree *tree) +{ + g_return_val_if_fail (tree != NULL, 0); + + if (tree->root) + return g_tree_node_height (tree->root); + else + return 0; +} + +/** + * g_tree_nnodes: + * @tree: a #GTree. + * + * Gets the number of nodes in a #GTree. + * + * Return value: the number of nodes in the #GTree. + **/ +gint +g_tree_nnodes (GTree *tree) +{ + g_return_val_if_fail (tree != NULL, 0); + + if (tree->root) + return g_tree_node_count (tree->root); + else + return 0; +} + +static GTreeNode* +g_tree_node_insert (GTree *tree, + GTreeNode *node, + gpointer key, + gpointer value, + gboolean replace, + gboolean *inserted) +{ + gint old_balance; + gint cmp; + + if (!node) + { + *inserted = TRUE; + return g_tree_node_new (key, value); + } + + cmp = tree->key_compare (key, node->key, tree->key_compare_data); + if (cmp == 0) + { + *inserted = FALSE; + + if (tree->value_destroy_func) + tree->value_destroy_func (node->value); + + node->value = value; + + if (replace) + { + if (tree->key_destroy_func) + tree->key_destroy_func (node->key); + + node->key = key; + } + else + { + /* free the passed key */ + if (tree->key_destroy_func) + tree->key_destroy_func (key); + } + + return node; + } + + if (cmp < 0) + { + if (node->left) + { + old_balance = node->left->balance; + node->left = g_tree_node_insert (tree, + node->left, + key, value, + replace, inserted); + + if ((old_balance != node->left->balance) && node->left->balance) + node->balance -= 1; + } + else + { + *inserted = TRUE; + node->left = g_tree_node_new (key, value); + node->balance -= 1; + } + } + else if (cmp > 0) + { + if (node->right) + { + old_balance = node->right->balance; + node->right = g_tree_node_insert (tree, + node->right, + key, value, + replace, inserted); + + if ((old_balance != node->right->balance) && node->right->balance) + node->balance += 1; + } + else + { + *inserted = TRUE; + node->right = g_tree_node_new (key, value); + node->balance += 1; + } + } + + if (*inserted) + { + if ((node->balance < -1) || (node->balance > 1)) + node = g_tree_node_balance (node); + } + + return node; +} + +static GTreeNode* +g_tree_node_remove (GTree *tree, + GTreeNode *node, + gconstpointer key, + gboolean notify) +{ + GTreeNode *new_root; + gint old_balance; + gint cmp; + + if (!node) + return NULL; + + cmp = tree->key_compare (key, node->key, tree->key_compare_data); + if (cmp == 0) + { + GTreeNode *garbage; + + garbage = node; + + if (!node->right) + { + node = node->left; + } + else + { + old_balance = node->right->balance; + node->right = g_tree_node_remove_leftmost (node->right, &new_root); + new_root->left = node->left; + new_root->right = node->right; + new_root->balance = node->balance; + node = g_tree_node_restore_right_balance (new_root, old_balance); + } + + if (notify) + { + if (tree->key_destroy_func) + tree->key_destroy_func (garbage->key); + if (tree->value_destroy_func) + tree->value_destroy_func (garbage->value); + } + +#ifdef ENABLE_GC_FRIENDLY + garbage->left = NULL; + garbage->key = NULL; + garbage->value = NULL; +#endif /* ENABLE_GC_FRIENDLY */ + + G_LOCK (g_tree_global); + garbage->right = node_free_list; + node_free_list = garbage; + G_UNLOCK (g_tree_global); + } + else if (cmp < 0) + { + if (node->left) + { + old_balance = node->left->balance; + node->left = g_tree_node_remove (tree, node->left, key, notify); + node = g_tree_node_restore_left_balance (node, old_balance); + } + } + else if (cmp > 0) + { + if (node->right) + { + old_balance = node->right->balance; + node->right = g_tree_node_remove (tree, node->right, key, notify); + node = g_tree_node_restore_right_balance (node, old_balance); + } + } + + return node; +} + +static GTreeNode* +g_tree_node_balance (GTreeNode *node) +{ + if (node->balance < -1) + { + if (node->left->balance > 0) + node->left = g_tree_node_rotate_left (node->left); + node = g_tree_node_rotate_right (node); + } + else if (node->balance > 1) + { + if (node->right->balance < 0) + node->right = g_tree_node_rotate_right (node->right); + node = g_tree_node_rotate_left (node); + } + + return node; +} + +static GTreeNode* +g_tree_node_remove_leftmost (GTreeNode *node, + GTreeNode **leftmost) +{ + gint old_balance; + + if (!node->left) + { + *leftmost = node; + return node->right; + } + + old_balance = node->left->balance; + node->left = g_tree_node_remove_leftmost (node->left, leftmost); + return g_tree_node_restore_left_balance (node, old_balance); +} + +static GTreeNode* +g_tree_node_restore_left_balance (GTreeNode *node, + gint old_balance) +{ + if (!node->left) + node->balance += 1; + else if ((node->left->balance != old_balance) && + (node->left->balance == 0)) + node->balance += 1; + + if (node->balance > 1) + return g_tree_node_balance (node); + return node; +} + +static GTreeNode* +g_tree_node_restore_right_balance (GTreeNode *node, + gint old_balance) +{ + if (!node->right) + node->balance -= 1; + else if ((node->right->balance != old_balance) && + (node->right->balance == 0)) + node->balance -= 1; + + if (node->balance < -1) + return g_tree_node_balance (node); + return node; +} + +static GTreeNode * +g_tree_node_lookup (GTreeNode *node, + GCompareDataFunc compare, + gpointer compare_data, + gconstpointer key) +{ + gint cmp; + + if (!node) + return NULL; + + cmp = (* compare) (key, node->key, compare_data); + if (cmp == 0) + return node; + + if (cmp < 0) + { + if (node->left) + return g_tree_node_lookup (node->left, compare, compare_data, key); + } + else if (cmp > 0) + { + if (node->right) + return g_tree_node_lookup (node->right, compare, compare_data, key); + } + + return NULL; +} + +static gint +g_tree_node_count (GTreeNode *node) +{ + gint count; + + count = 1; + if (node->left) + count += g_tree_node_count (node->left); + if (node->right) + count += g_tree_node_count (node->right); + + return count; +} + +static gint +g_tree_node_pre_order (GTreeNode *node, + GTraverseFunc traverse_func, + gpointer data) +{ + if ((*traverse_func) (node->key, node->value, data)) + return TRUE; + if (node->left) + { + if (g_tree_node_pre_order (node->left, traverse_func, data)) + return TRUE; + } + if (node->right) + { + if (g_tree_node_pre_order (node->right, traverse_func, data)) + return TRUE; + } + + return FALSE; +} + +static gint +g_tree_node_in_order (GTreeNode *node, + GTraverseFunc traverse_func, + gpointer data) +{ + if (node->left) + { + if (g_tree_node_in_order (node->left, traverse_func, data)) + return TRUE; + } + if ((*traverse_func) (node->key, node->value, data)) + return TRUE; + if (node->right) + { + if (g_tree_node_in_order (node->right, traverse_func, data)) + return TRUE; + } + + return FALSE; +} + +static gint +g_tree_node_post_order (GTreeNode *node, + GTraverseFunc traverse_func, + gpointer data) +{ + if (node->left) + { + if (g_tree_node_post_order (node->left, traverse_func, data)) + return TRUE; + } + if (node->right) + { + if (g_tree_node_post_order (node->right, traverse_func, data)) + return TRUE; + } + if ((*traverse_func) (node->key, node->value, data)) + return TRUE; + + return FALSE; +} + +static gpointer +g_tree_node_search (GTreeNode *node, + GCompareFunc search_func, + gconstpointer data) +{ + gint dir; + + if (!node) + return NULL; + + do { + dir = (* search_func) (node->key, data); + if (dir == 0) + return node->value; + + if (dir < 0) + node = node->left; + else if (dir > 0) + node = node->right; + } while (node); + + return NULL; +} + +static gint +g_tree_node_height (GTreeNode *node) +{ + gint left_height; + gint right_height; + + if (node) + { + left_height = 0; + right_height = 0; + + if (node->left) + left_height = g_tree_node_height (node->left); + + if (node->right) + right_height = g_tree_node_height (node->right); + + return MAX (left_height, right_height) + 1; + } + + return 0; +} + +static GTreeNode* +g_tree_node_rotate_left (GTreeNode *node) +{ + GTreeNode *right; + gint a_bal; + gint b_bal; + + right = node->right; + + node->right = right->left; + right->left = node; + + a_bal = node->balance; + b_bal = right->balance; + + if (b_bal <= 0) + { + if (a_bal >= 1) + right->balance = b_bal - 1; + else + right->balance = a_bal + b_bal - 2; + node->balance = a_bal - 1; + } + else + { + if (a_bal <= b_bal) + right->balance = a_bal - 2; + else + right->balance = b_bal - 1; + node->balance = a_bal - b_bal - 1; + } + + return right; +} + +static GTreeNode* +g_tree_node_rotate_right (GTreeNode *node) +{ + GTreeNode *left; + gint a_bal; + gint b_bal; + + left = node->left; + + node->left = left->right; + left->right = node; + + a_bal = node->balance; + b_bal = left->balance; + + if (b_bal <= 0) + { + if (b_bal > a_bal) + left->balance = b_bal + 1; + else + left->balance = a_bal + 2; + node->balance = a_bal - b_bal + 1; + } + else + { + if (a_bal <= -1) + left->balance = b_bal + 1; + else + left->balance = a_bal + b_bal + 2; + node->balance = a_bal + 1; + } + + return left; +} + +static void +g_tree_node_check (GTreeNode *node) +{ + gint left_height; + gint right_height; + gint balance; + + if (node) + { + left_height = 0; + right_height = 0; + + if (node->left) + left_height = g_tree_node_height (node->left); + if (node->right) + right_height = g_tree_node_height (node->right); + + balance = right_height - left_height; + if (balance != node->balance) + g_log (g_log_domain_glib, G_LOG_LEVEL_INFO, + "g_tree_node_check: failed: %d ( %d )\n", + balance, node->balance); + + if (node->left) + g_tree_node_check (node->left); + if (node->right) + g_tree_node_check (node->right); + } +} diff --git a/graf2d/win32gdk/gdk/src/glib/gtree.h b/graf2d/win32gdk/gdk/src/glib/gtree.h index 3530a6374bea9..6742c4a1956ec 100644 --- a/graf2d/win32gdk/gdk/src/glib/gtree.h +++ b/graf2d/win32gdk/gdk/src/glib/gtree.h @@ -27,38 +27,54 @@ #ifndef __G_TREE_H__ #define __G_TREE_H__ -#include <gnode.h> +#include <glib/gnode.h> G_BEGIN_DECLS -typedef struct _GTree GTree; +typedef struct _GTree GTree; -typedef gint (*GTraverseFunc) (gpointer key, - gpointer value, - gpointer data); +typedef gint (*GTraverseFunc) (gpointer key, + gpointer value, + gpointer data); /* Balanced binary trees */ -GTree* g_tree_new (GCompareFunc key_compare_func); -GTree* g_tree_new_with_data (GCompareFuncData key_compare_func, - gpointer user_data); -void g_tree_destroy (GTree *tree); -void g_tree_insert (GTree *tree, - gpointer key, - gpointer value); -void g_tree_remove (GTree *tree, - gconstpointer key); -gpointer g_tree_lookup (GTree *tree, - gconstpointer key); -void g_tree_traverse (GTree *tree, - GTraverseFunc traverse_func, - GTraverseType traverse_type, - gpointer data); -gpointer g_tree_search (GTree *tree, - GCompareFunc search_func, - gconstpointer data); -gint g_tree_height (GTree *tree); -gint g_tree_nnodes (GTree *tree); +GTree* g_tree_new (GCompareFunc key_compare_func); +GTree* g_tree_new_with_data (GCompareDataFunc key_compare_func, + gpointer key_compare_data); +GTree* g_tree_new_full (GCompareDataFunc key_compare_func, + gpointer key_compare_data, + GDestroyNotify key_destroy_func, + GDestroyNotify value_destroy_func); +void g_tree_destroy (GTree *tree); +void g_tree_insert (GTree *tree, + gpointer key, + gpointer value); +void g_tree_replace (GTree *tree, + gpointer key, + gpointer value); +void g_tree_remove (GTree *tree, + gconstpointer key); +void g_tree_steal (GTree *tree, + gconstpointer key); +gpointer g_tree_lookup (GTree *tree, + gconstpointer key); +gboolean g_tree_lookup_extended (GTree *tree, + gconstpointer lookup_key, + gpointer *orig_key, + gpointer *value); +void g_tree_foreach (GTree *tree, + GTraverseFunc func, + gpointer user_data); +void g_tree_traverse (GTree *tree, + GTraverseFunc traverse_func, + GTraverseType traverse_type, + gpointer user_data); +gpointer g_tree_search (GTree *tree, + GCompareFunc search_func, + gconstpointer user_data); +gint g_tree_height (GTree *tree); +gint g_tree_nnodes (GTree *tree); diff --git a/graf2d/win32gdk/gdk/src/glib/gtypes.h b/graf2d/win32gdk/gdk/src/glib/gtypes.h new file mode 100644 index 0000000000000..27597b700667b --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gtypes.h @@ -0,0 +1,350 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +#ifndef __G_TYPES_H__ +#define __G_TYPES_H__ + +#include <glibconfig.h> + +G_BEGIN_DECLS + +/* Provide type definitions for commonly used types. + * These are useful because a "gint8" can be adjusted + * to be 1 byte (8 bits) on all platforms. Similarly and + * more importantly, "gint32" can be adjusted to be + * 4 bytes (32 bits) on all platforms. + */ + +typedef char gchar; +typedef short gshort; +typedef long glong; +typedef int gint; +typedef gint gboolean; + +typedef unsigned char guchar; +typedef unsigned short gushort; +typedef unsigned long gulong; +typedef unsigned int guint; + +typedef float gfloat; +typedef double gdouble; + +/* HAVE_LONG_DOUBLE doesn't work correctly on all platforms. + * Since gldouble isn't used anywhere, just disable it for now */ + +#if 0 +#ifdef HAVE_LONG_DOUBLE +typedef long double gldouble; +#else /* HAVE_LONG_DOUBLE */ +typedef double gldouble; +#endif /* HAVE_LONG_DOUBLE */ +#endif /* 0 */ + +typedef void* gpointer; +typedef const void *gconstpointer; + +typedef gint (*GCompareFunc) (gconstpointer a, + gconstpointer b); +typedef gint (*GCompareDataFunc) (gconstpointer a, + gconstpointer b, + gpointer user_data); +typedef gboolean (*GEqualFunc) (gconstpointer a, + gconstpointer b); +typedef void (*GDestroyNotify) (gpointer data); +typedef void (*GFunc) (gpointer data, + gpointer user_data); +typedef guint (*GHashFunc) (gconstpointer key); +typedef void (*GHFunc) (gpointer key, + gpointer value, + gpointer user_data); +typedef void (*GFreeFunc) (gpointer data); + +/* Define some mathematical constants that aren't available + * symbolically in some strict ISO C implementations. + */ +#define G_E 2.7182818284590452354E0 +#define G_LN2 6.9314718055994530942E-1 +#define G_LN10 2.3025850929940456840E0 +#define G_PI 3.14159265358979323846E0 +#define G_PI_2 1.57079632679489661923E0 +#define G_PI_4 0.78539816339744830962E0 +#define G_SQRT2 1.4142135623730950488E0 + +/* Portable endian checks and conversions + * + * glibconfig.h defines G_BYTE_ORDER which expands to one of + * the below macros. + */ +#define G_LITTLE_ENDIAN 1234 +#define G_BIG_ENDIAN 4321 +#define G_PDP_ENDIAN 3412 /* unused, need specific PDP check */ + + +/* Basic bit swapping functions + */ +#define GUINT16_SWAP_LE_BE_CONSTANT(val) ((guint16) ( \ + (((guint16) (val) & (guint16) 0x00ffU) << 8) | \ + (((guint16) (val) & (guint16) 0xff00U) >> 8))) +#define GUINT32_SWAP_LE_BE_CONSTANT(val) ((guint32) ( \ + (((guint32) (val) & (guint32) 0x000000ffU) << 24) | \ + (((guint32) (val) & (guint32) 0x0000ff00U) << 8) | \ + (((guint32) (val) & (guint32) 0x00ff0000U) >> 8) | \ + (((guint32) (val) & (guint32) 0xff000000U) >> 24))) + +/* Intel specific stuff for speed + */ +#if defined (__i386__) && defined (__GNUC__) && __GNUC__ >= 2 +# define GUINT16_SWAP_LE_BE_X86(val) \ + (G_GNUC_EXTENSION \ + ({ register guint16 __v; \ + if (__builtin_constant_p (val)) \ + __v = GUINT16_SWAP_LE_BE_CONSTANT (val); \ + else \ + __asm__ __const__ ("rorw $8, %w0" \ + : "=r" (__v) \ + : "0" ((guint16) (val))); \ + __v; })) +# define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_X86 (val)) +# if !defined(__i486__) && !defined(__i586__) \ + && !defined(__pentium__) && !defined(__i686__) && !defined(__pentiumpro__) +# define GUINT32_SWAP_LE_BE_X86(val) \ + (G_GNUC_EXTENSION \ + ({ register guint32 __v; \ + if (__builtin_constant_p (val)) \ + __v = GUINT32_SWAP_LE_BE_CONSTANT (val); \ + else \ + __asm__ __const__ ("rorw $8, %w0\n\t" \ + "rorl $16, %0\n\t" \ + "rorw $8, %w0" \ + : "=r" (__v) \ + : "0" ((guint32) (val))); \ + __v; })) +# else /* 486 and higher has bswap */ +# define GUINT32_SWAP_LE_BE_X86(val) \ + (G_GNUC_EXTENSION \ + ({ register guint32 __v; \ + if (__builtin_constant_p (val)) \ + __v = GUINT32_SWAP_LE_BE_CONSTANT (val); \ + else \ + __asm__ __const__ ("bswap %0" \ + : "=r" (__v) \ + : "0" ((guint32) (val))); \ + __v; })) +# endif /* processor specific 32-bit stuff */ +# define GUINT32_SWAP_LE_BE(val) (GUINT32_SWAP_LE_BE_X86 (val)) +#else /* !__i386__ */ +# define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_CONSTANT (val)) +# define GUINT32_SWAP_LE_BE(val) (GUINT32_SWAP_LE_BE_CONSTANT (val)) +#endif /* __i386__ */ + +#ifdef G_HAVE_GINT64 +# define GUINT64_SWAP_LE_BE_CONSTANT(val) ((guint64) ( \ + (((guint64) (val) & \ + (guint64) G_GINT64_CONSTANT(0x00000000000000ffU)) << 56) | \ + (((guint64) (val) & \ + (guint64) G_GINT64_CONSTANT(0x000000000000ff00U)) << 40) | \ + (((guint64) (val) & \ + (guint64) G_GINT64_CONSTANT(0x0000000000ff0000U)) << 24) | \ + (((guint64) (val) & \ + (guint64) G_GINT64_CONSTANT(0x00000000ff000000U)) << 8) | \ + (((guint64) (val) & \ + (guint64) G_GINT64_CONSTANT(0x000000ff00000000U)) >> 8) | \ + (((guint64) (val) & \ + (guint64) G_GINT64_CONSTANT(0x0000ff0000000000U)) >> 24) | \ + (((guint64) (val) & \ + (guint64) G_GINT64_CONSTANT(0x00ff000000000000U)) >> 40) | \ + (((guint64) (val) & \ + (guint64) G_GINT64_CONSTANT(0xff00000000000000U)) >> 56))) +# if defined (__i386__) && defined (__GNUC__) && __GNUC__ >= 2 +# define GUINT64_SWAP_LE_BE_X86(val) \ + (__extension__ \ + ({ union { guint64 __ll; \ + guint32 __l[2]; } __r; \ + if (__builtin_constant_p (val)) \ + __r.__ll = GUINT64_SWAP_LE_BE_CONSTANT (val); \ + else \ + { \ + union { guint64 __ll; \ + guint32 __l[2]; } __w; \ + __w.__ll = ((guint64) val); \ + __r.__l[0] = GUINT32_SWAP_LE_BE (__w.__l[1]); \ + __r.__l[1] = GUINT32_SWAP_LE_BE (__w.__l[0]); \ + } \ + __r.__ll; })) +# define GUINT64_SWAP_LE_BE(val) (GUINT64_SWAP_LE_BE_X86 (val)) +# else /* !__i386__ */ +# define GUINT64_SWAP_LE_BE(val) (GUINT64_SWAP_LE_BE_CONSTANT(val)) +# endif +#endif + +#define GUINT16_SWAP_LE_PDP(val) ((guint16) (val)) +#define GUINT16_SWAP_BE_PDP(val) (GUINT16_SWAP_LE_BE (val)) +#define GUINT32_SWAP_LE_PDP(val) ((guint32) ( \ + (((guint32) (val) & (guint32) 0x0000ffffU) << 16) | \ + (((guint32) (val) & (guint32) 0xffff0000U) >> 16))) +#define GUINT32_SWAP_BE_PDP(val) ((guint32) ( \ + (((guint32) (val) & (guint32) 0x00ff00ffU) << 8) | \ + (((guint32) (val) & (guint32) 0xff00ff00U) >> 8))) + +/* The G*_TO_?E() macros are defined in glibconfig.h. + * The transformation is symmetric, so the FROM just maps to the TO. + */ +#define GINT16_FROM_LE(val) (GINT16_TO_LE (val)) +#define GUINT16_FROM_LE(val) (GUINT16_TO_LE (val)) +#define GINT16_FROM_BE(val) (GINT16_TO_BE (val)) +#define GUINT16_FROM_BE(val) (GUINT16_TO_BE (val)) +#define GINT32_FROM_LE(val) (GINT32_TO_LE (val)) +#define GUINT32_FROM_LE(val) (GUINT32_TO_LE (val)) +#define GINT32_FROM_BE(val) (GINT32_TO_BE (val)) +#define GUINT32_FROM_BE(val) (GUINT32_TO_BE (val)) + +#ifdef G_HAVE_GINT64 +#define GINT64_FROM_LE(val) (GINT64_TO_LE (val)) +#define GUINT64_FROM_LE(val) (GUINT64_TO_LE (val)) +#define GINT64_FROM_BE(val) (GINT64_TO_BE (val)) +#define GUINT64_FROM_BE(val) (GUINT64_TO_BE (val)) +#endif + +#define GLONG_FROM_LE(val) (GLONG_TO_LE (val)) +#define GULONG_FROM_LE(val) (GULONG_TO_LE (val)) +#define GLONG_FROM_BE(val) (GLONG_TO_BE (val)) +#define GULONG_FROM_BE(val) (GULONG_TO_BE (val)) + +#define GINT_FROM_LE(val) (GINT_TO_LE (val)) +#define GUINT_FROM_LE(val) (GUINT_TO_LE (val)) +#define GINT_FROM_BE(val) (GINT_TO_BE (val)) +#define GUINT_FROM_BE(val) (GUINT_TO_BE (val)) + + +/* Portable versions of host-network order stuff + */ +#define g_ntohl(val) (GUINT32_FROM_BE (val)) +#define g_ntohs(val) (GUINT16_FROM_BE (val)) +#define g_htonl(val) (GUINT32_TO_BE (val)) +#define g_htons(val) (GUINT16_TO_BE (val)) + +/* IEEE Standard 754 Single Precision Storage Format (gfloat): + * + * 31 30 23 22 0 + * +--------+---------------+---------------+ + * | s 1bit | e[30:23] 8bit | f[22:0] 23bit | + * +--------+---------------+---------------+ + * B0------------------->B1------->B2-->B3--> + * + * IEEE Standard 754 Double Precision Storage Format (gdouble): + * + * 63 62 52 51 32 31 0 + * +--------+----------------+----------------+ +---------------+ + * | s 1bit | e[62:52] 11bit | f[51:32] 20bit | | f[31:0] 32bit | + * +--------+----------------+----------------+ +---------------+ + * B0--------------->B1---------->B2--->B3----> B4->B5->B6->B7-> + */ +/* subtract from biased_exponent to form base2 exponent (normal numbers) */ +typedef union _GDoubleIEEE754 GDoubleIEEE754; +typedef union _GFloatIEEE754 GFloatIEEE754; +#define G_IEEE754_FLOAT_BIAS (127) +#define G_IEEE754_DOUBLE_BIAS (1023) +/* multiply with base2 exponent to get base10 exponent (nomal numbers) */ +#define G_LOG_2_BASE_10 (0.30102999566398119521) +#if G_BYTE_ORDER == G_LITTLE_ENDIAN +union _GFloatIEEE754 +{ + gfloat v_float; + struct { + guint mantissa : 23; + guint biased_exponent : 8; + guint sign : 1; + } mpn; +}; +union _GDoubleIEEE754 +{ + gdouble v_double; + struct { + guint mantissa_low : 32; + guint mantissa_high : 20; + guint biased_exponent : 11; + guint sign : 1; + } mpn; +}; +#elif G_BYTE_ORDER == G_BIG_ENDIAN +union _GFloatIEEE754 +{ + gfloat v_float; + struct { + guint sign : 1; + guint biased_exponent : 8; + guint mantissa : 23; + } mpn; +}; +union _GDoubleIEEE754 +{ + gdouble v_double; + struct { + guint sign : 1; + guint biased_exponent : 11; + guint mantissa_high : 20; + guint mantissa_low : 32; + } mpn; +}; +#else /* !G_LITTLE_ENDIAN && !G_BIG_ENDIAN */ +#error unknown ENDIAN type +#endif /* !G_LITTLE_ENDIAN && !G_BIG_ENDIAN */ + +typedef struct _GTimeVal GTimeVal; + +struct _GTimeVal +{ + glong tv_sec; + glong tv_usec; +}; + +G_END_DECLS + +/* We prefix variable declarations so they can + * properly get exported in windows dlls. + */ +#ifndef GLIB_VAR +# ifdef G_PLATFORM_WIN32 +# ifdef GLIB_STATIC_COMPILATION +# define GLIB_VAR extern +# else /* !GLIB_STATIC_COMPILATION */ +# ifdef GLIB_COMPILATION +# ifdef DLL_EXPORT +# define GLIB_VAR __declspec(dllexport) +# else /* !DLL_EXPORT */ +# define GLIB_VAR extern +# endif /* !DLL_EXPORT */ +# else /* !GLIB_COMPILATION */ +# define GLIB_VAR extern __declspec(dllimport) +# endif /* !GLIB_COMPILATION */ +# endif /* !GLIB_STATIC_COMPILATION */ +# else /* !G_PLATFORM_WIN32 */ +# define GLIB_VAR extern +# endif /* !G_PLATFORM_WIN32 */ +#endif /* GLIB_VAR */ + +#endif /* __G_TYPES_H__ */ + diff --git a/graf2d/win32gdk/gdk/src/glib/gunibreak.c b/graf2d/win32gdk/gdk/src/glib/gunibreak.c new file mode 100644 index 0000000000000..5bcb946c98ede --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gunibreak.c @@ -0,0 +1,55 @@ +/* gunibreak.c - line break properties + * + * Copyright 2000 Red Hat, Inc. + * + * The Gnome Library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2 of the + * License, or (at your option) any later version. + * + * The Gnome Library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with the Gnome Library; see the file COPYING.LIB. If not, + * write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "glib.h" +#include "gunibreak.h" + +#include <config.h> + +#include <stdlib.h> + + +/* We cheat a bit and cast type values to (char *). We detect these + using the &0xff trick. */ +#define TPROP(Page, Char) \ + (((GPOINTER_TO_INT(break_property_table[Page]) & 0xff) == GPOINTER_TO_INT(break_property_table[Page])) \ + ? GPOINTER_TO_INT(break_property_table[Page]) \ + : (break_property_table[Page][Char])) + +#define PROP(Char) (((Char) > (G_UNICODE_LAST_CHAR)) ? G_UNICODE_UNASSIGNED : TPROP ((Char) >> 8, (Char) & 0xff)) + +/** + * g_unichar_break_type: + * @c: a Unicode character + * + * Determines the break type of @c. @c should be a Unicode character + * (to derive a character from UTF-8 encoded text, use + * g_utf8_get_char()). The break type is used to find word and line + * breaks ("text boundaries"), Pango implements the Unicode boundary + * resolution algorithms and normally you would use a function such + * as pango_break() instead of caring about break types yourself. + * + * Return value: the break type of @c + **/ +GUnicodeBreakType +g_unichar_break_type (gunichar c) +{ + return PROP (c); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gunibreak.h b/graf2d/win32gdk/gdk/src/glib/gunibreak.h index 34912b3ad512e..c8294a0785728 100644 --- a/graf2d/win32gdk/gdk/src/glib/gunibreak.h +++ b/graf2d/win32gdk/gdk/src/glib/gunibreak.h @@ -4,7 +4,7 @@ #ifndef BREAKTABLES_H #define BREAKTABLES_H -#define G_UNICODE_DATA_VERSION "3.0.1" +#define G_UNICODE_DATA_VERSION "3.1" #define G_UNICODE_LAST_CHAR 0xffff @@ -96,7 +96,7 @@ static char page0[256] = { G_UNICODE_BREAK_AFTER, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_POSTFIX, G_UNICODE_BREAK_PREFIX, G_UNICODE_BREAK_AMBIGUOUS, - G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_AFTER, + G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_BEFORE, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_AMBIGUOUS, @@ -508,11 +508,11 @@ static char page3[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN }; static char page4[256] = { @@ -3064,7 +3064,7 @@ static char page32[256] = { G_UNICODE_BREAK_COMBINING_MARK, G_UNICODE_BREAK_AFTER, G_UNICODE_BREAK_NON_BREAKING_GLUE, G_UNICODE_BREAK_AFTER, G_UNICODE_BREAK_AFTER, G_UNICODE_BREAK_BEFORE_AND_AFTER, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_AMBIGUOUS, + G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_QUOTATION, G_UNICODE_BREAK_QUOTATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_QUOTATION, G_UNICODE_BREAK_QUOTATION, @@ -3751,7 +3751,7 @@ static char page37[256] = { G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_AMBIGUOUS, - G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_AMBIGUOUS, @@ -4746,229 +4746,209 @@ static char page51[256] = { G_UNICODE_BREAK_UNKNOWN }; -static char page52[256] = { - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC +static char page77[256] = { + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN }; -static char page77[256] = { - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_IDEOGRAPHIC, +static char page159[256] = { + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, @@ -4993,254 +4973,12 @@ static char page77[256] = { G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN -}; - -static char page78[256] = { - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC -}; - -static char page159[256] = { - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN }; static char page164[256] = { @@ -5365,97 +5103,234 @@ static char page164[256] = { G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN }; -static char page172[256] = { - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, +static char page215[256] = { + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN +}; + +static char page250[256] = { + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN +}; + +static char page251[256] = { + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_COMBINING_MARK, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, @@ -5466,7 +5341,14 @@ static char page172[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, @@ -5493,10 +5375,6 @@ static char page172[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC -}; - -static char page215[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, @@ -5525,6 +5403,17 @@ static char page215[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, @@ -5547,6 +5436,10 @@ static char page215[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC +}; + +static char page253[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, @@ -5578,105 +5471,13 @@ static char page215[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN -}; - -static char page216[256] = { - G_UNICODE_BREAK_SURROGATE, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, @@ -5708,6 +5509,8 @@ static char page216[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, @@ -5734,24 +5537,82 @@ static char page216[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN }; -static char page219[256] = { - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, +static char page254[256] = { + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_COMBINING_MARK, G_UNICODE_BREAK_COMBINING_MARK, + G_UNICODE_BREAK_COMBINING_MARK, G_UNICODE_BREAK_COMBINING_MARK, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_OPEN_PUNCTUATION, + G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, + G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, + G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, + G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, + G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, + G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, + G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, + G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_CLOSE_PUNCTUATION, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_CLOSE_PUNCTUATION, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_NON_STARTER, + G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_EXCLAMATION, + G_UNICODE_BREAK_EXCLAMATION, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_CLOSE_PUNCTUATION, + G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_CLOSE_PUNCTUATION, + G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_CLOSE_PUNCTUATION, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_PREFIX, G_UNICODE_BREAK_POSTFIX, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, @@ -5807,8 +5668,6 @@ static char page219[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_SURROGATE, - G_UNICODE_BREAK_SURROGATE, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, @@ -5821,6 +5680,68 @@ static char page219[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_NON_BREAKING_GLUE +}; + +static char page255[256] = { + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_EXCLAMATION, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_PREFIX, G_UNICODE_BREAK_POSTFIX, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_CLOSE_PUNCTUATION, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_NON_STARTER, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_EXCLAMATION, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_OPEN_PUNCTUATION, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_CLOSE_PUNCTUATION, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_OPEN_PUNCTUATION, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_CLOSE_PUNCTUATION, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_CLOSE_PUNCTUATION, + G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_CLOSE_PUNCTUATION, + G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_NON_STARTER, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_NON_STARTER, + G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_NON_STARTER, + G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_NON_STARTER, + G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_NON_STARTER, + G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_NON_STARTER, + G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, @@ -5843,6 +5764,7 @@ static char page219[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, @@ -5858,1138 +5780,37 @@ static char page219[256] = { G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_POSTFIX, + G_UNICODE_BREAK_PREFIX, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, + G_UNICODE_BREAK_PREFIX, G_UNICODE_BREAK_PREFIX, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_SURROGATE -}; - -static char page220[256] = { - G_UNICODE_BREAK_SURROGATE, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC -}; - -static char page223[256] = { - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_SURROGATE -}; - -static char page224[256] = { - G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC -}; - -static char page248[256] = { - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_AMBIGUOUS -}; - -static char page250[256] = { - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN -}; - -static char page251[256] = { - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_COMBINING_MARK, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC -}; - -static char page253[256] = { - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_CLOSE_PUNCTUATION, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN -}; - -static char page254[256] = { - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_COMBINING_MARK, G_UNICODE_BREAK_COMBINING_MARK, - G_UNICODE_BREAK_COMBINING_MARK, G_UNICODE_BREAK_COMBINING_MARK, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_OPEN_PUNCTUATION, - G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, - G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, - G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, - G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, - G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, - G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, - G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_OPEN_PUNCTUATION, - G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_CLOSE_PUNCTUATION, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_CLOSE_PUNCTUATION, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_NON_STARTER, - G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_EXCLAMATION, - G_UNICODE_BREAK_EXCLAMATION, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_CLOSE_PUNCTUATION, - G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_CLOSE_PUNCTUATION, - G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_CLOSE_PUNCTUATION, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_PREFIX, G_UNICODE_BREAK_POSTFIX, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_NON_BREAKING_GLUE -}; - -static char page255[256] = { - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_EXCLAMATION, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_PREFIX, G_UNICODE_BREAK_POSTFIX, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_CLOSE_PUNCTUATION, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_NON_STARTER, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_EXCLAMATION, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_OPEN_PUNCTUATION, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_CLOSE_PUNCTUATION, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_OPEN_PUNCTUATION, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_CLOSE_PUNCTUATION, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_CLOSE_PUNCTUATION, - G_UNICODE_BREAK_OPEN_PUNCTUATION, G_UNICODE_BREAK_CLOSE_PUNCTUATION, - G_UNICODE_BREAK_CLOSE_PUNCTUATION, G_UNICODE_BREAK_NON_STARTER, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_NON_STARTER, - G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_NON_STARTER, - G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_NON_STARTER, - G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_NON_STARTER, - G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_NON_STARTER, - G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_NON_STARTER, G_UNICODE_BREAK_NON_STARTER, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_POSTFIX, - G_UNICODE_BREAK_PREFIX, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_IDEOGRAPHIC, G_UNICODE_BREAK_IDEOGRAPHIC, - G_UNICODE_BREAK_PREFIX, G_UNICODE_BREAK_PREFIX, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_ALPHABETIC, - G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_COMBINING_MARK, G_UNICODE_BREAK_COMBINING_MARK, - G_UNICODE_BREAK_COMBINING_MARK, G_UNICODE_BREAK_CONTINGENT, - G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_UNKNOWN, - G_UNICODE_BREAK_UNKNOWN + G_UNICODE_BREAK_ALPHABETIC, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_COMBINING_MARK, G_UNICODE_BREAK_COMBINING_MARK, + G_UNICODE_BREAK_COMBINING_MARK, G_UNICODE_BREAK_CONTINGENT, + G_UNICODE_BREAK_AMBIGUOUS, G_UNICODE_BREAK_UNKNOWN, + G_UNICODE_BREAK_UNKNOWN }; static char *break_property_table[256] = { @@ -7023,141 +5844,218 @@ static char *break_property_table[256] = { (char *) G_UNICODE_BREAK_UNKNOWN, (char *) G_UNICODE_BREAK_UNKNOWN, (char *) G_UNICODE_BREAK_UNKNOWN, - page30, - page31, - page32, - page33, - page34, - page35, - page36, - page37, - page38, - page39, - (char *) G_UNICODE_BREAK_ALPHABETIC, + page30, + page31, + page32, + page33, + page34, + page35, + page36, + page37, + page38, + page39, + (char *) G_UNICODE_BREAK_ALPHABETIC, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + page46, + page47, + page48, + page49, + page50, + page51, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + page77, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + page159, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + page164, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, (char *) G_UNICODE_BREAK_UNKNOWN, (char *) G_UNICODE_BREAK_UNKNOWN, (char *) G_UNICODE_BREAK_UNKNOWN, (char *) G_UNICODE_BREAK_UNKNOWN, (char *) G_UNICODE_BREAK_UNKNOWN, - page46, - page47, - page48, - page49, - page50, - page51, - page52, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - page77, - page78, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - page159, (char *) G_UNICODE_BREAK_IDEOGRAPHIC, (char *) G_UNICODE_BREAK_IDEOGRAPHIC, (char *) G_UNICODE_BREAK_IDEOGRAPHIC, (char *) G_UNICODE_BREAK_IDEOGRAPHIC, - page164, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + (char *) G_UNICODE_BREAK_IDEOGRAPHIC, + page215, + (char *) G_UNICODE_BREAK_SURROGATE, + (char *) G_UNICODE_BREAK_SURROGATE, + (char *) G_UNICODE_BREAK_SURROGATE, + (char *) G_UNICODE_BREAK_SURROGATE, + (char *) G_UNICODE_BREAK_SURROGATE, + (char *) G_UNICODE_BREAK_SURROGATE, + (char *) G_UNICODE_BREAK_SURROGATE, + (char *) G_UNICODE_BREAK_SURROGATE, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, + (char *) G_UNICODE_BREAK_UNKNOWN, (char *) G_UNICODE_BREAK_UNKNOWN, (char *) G_UNICODE_BREAK_UNKNOWN, (char *) G_UNICODE_BREAK_UNKNOWN, @@ -7165,83 +6063,6 @@ static char *break_property_table[256] = { (char *) G_UNICODE_BREAK_UNKNOWN, (char *) G_UNICODE_BREAK_UNKNOWN, (char *) G_UNICODE_BREAK_UNKNOWN, - page172, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - page215, - page216, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - page219, - page220, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - page223, - page224, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - (char *) G_UNICODE_BREAK_ALPHABETIC, - page248, (char *) G_UNICODE_BREAK_IDEOGRAPHIC, page250, page251, diff --git a/graf2d/win32gdk/gdk/src/glib/gunichartables.h b/graf2d/win32gdk/gdk/src/glib/gunichartables.h index bcbbb18c8d7a1..d71700e705d63 100644 --- a/graf2d/win32gdk/gdk/src/glib/gunichartables.h +++ b/graf2d/win32gdk/gdk/src/glib/gunichartables.h @@ -4,7 +4,7 @@ #ifndef CHARTABLES_H #define CHARTABLES_H -#define G_UNICODE_DATA_VERSION "3.0.1" +#define G_UNICODE_DATA_VERSION "3.1" #define G_UNICODE_LAST_CHAR 0xffff @@ -487,11 +487,11 @@ static char page3[256] = { G_UNICODE_LOWERCASE_LETTER, G_UNICODE_UPPERCASE_LETTER, G_UNICODE_LOWERCASE_LETTER, G_UNICODE_LOWERCASE_LETTER, G_UNICODE_LOWERCASE_LETTER, G_UNICODE_LOWERCASE_LETTER, + G_UNICODE_LOWERCASE_LETTER, G_UNICODE_UPPERCASE_LETTER, G_UNICODE_LOWERCASE_LETTER, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, - G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, - G_UNICODE_UNASSIGNED + G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED }; static char page4[256] = { @@ -2142,7 +2142,7 @@ static char page22[256] = { G_UNICODE_OTHER_LETTER, G_UNICODE_OTHER_LETTER, G_UNICODE_OTHER_LETTER, G_UNICODE_OTHER_LETTER, G_UNICODE_OTHER_PUNCTUATION, G_UNICODE_OTHER_PUNCTUATION, G_UNICODE_OTHER_PUNCTUATION, - G_UNICODE_OTHER_NUMBER, G_UNICODE_OTHER_NUMBER, G_UNICODE_OTHER_NUMBER, + G_UNICODE_LETTER_NUMBER, G_UNICODE_LETTER_NUMBER, G_UNICODE_LETTER_NUMBER, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, G_UNICODE_UNASSIGNED, @@ -4982,7 +4982,7 @@ static unsigned short attrpage0[256] = { 0x0000, 0x0000, 0x0000, 0x00e0, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, 0x00f0, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x0000, - 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x00fd, 0x00fe, 0x0000, 0x00c0, + 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x00fd, 0x00fe, 0xd800, 0x00c0, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x00c7, 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, 0x00d0, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x0000, 0x00d8, 0x00d9, 0x00da, 0x00db, @@ -4998,7 +4998,7 @@ static unsigned short attrpage1[256] = { 0x012c, 0x012f, 0x012e, 0x0069, 0x0049, 0x0133, 0x0132, 0x0135, 0x0134, 0x0137, 0x0136, 0x0000, 0x013a, 0x0139, 0x013c, 0x013b, 0x013e, 0x013d, 0x0140, 0x013f, 0x0142, 0x0141, 0x0144, 0x0143, 0x0146, 0x0145, 0x0148, - 0x0147, 0x0000, 0x014b, 0x014a, 0x014d, 0x014c, 0x014f, 0x014e, 0x0151, + 0x0147, 0xd80e, 0x014b, 0x014a, 0x014d, 0x014c, 0x014f, 0x014e, 0x0151, 0x0150, 0x0153, 0x0152, 0x0155, 0x0154, 0x0157, 0x0156, 0x0159, 0x0158, 0x015b, 0x015a, 0x015d, 0x015c, 0x015f, 0x015e, 0x0161, 0x0160, 0x0163, 0x0162, 0x0165, 0x0164, 0x0167, 0x0166, 0x0169, 0x0168, 0x016b, 0x016a, @@ -5016,7 +5016,7 @@ static unsigned short attrpage1[256] = { 0x01d0, 0x01cf, 0x01d2, 0x01d1, 0x01d4, 0x01d3, 0x01d6, 0x01d5, 0x01d8, 0x01d7, 0x01da, 0x01d9, 0x01dc, 0x01db, 0x018e, 0x01df, 0x01de, 0x01e1, 0x01e0, 0x01e3, 0x01e2, 0x01e5, 0x01e4, 0x01e7, 0x01e6, 0x01e9, 0x01e8, - 0x01eb, 0x01ea, 0x01ed, 0x01ec, 0x01ef, 0x01ee, 0x0000, 0x01f3, 0x0000, + 0x01eb, 0x01ea, 0x01ed, 0x01ec, 0x01ef, 0x01ee, 0xd811, 0x01f3, 0x0000, 0x01f1, 0x01f5, 0x01f4, 0x0195, 0x01bf, 0x01f9, 0x01f8, 0x01fb, 0x01fa, 0x01fd, 0x01fc, 0x01ff, 0x01fe }; @@ -5070,10 +5070,10 @@ static unsigned short attrpage3[256] = { 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x03ac, 0x0000, 0x03ad, 0x03ae, 0x03af, 0x0000, 0x03cc, 0x0000, 0x03cd, 0x03ce, - 0x0000, 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, 0x03b8, + 0xd80f, 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, 0x03b8, 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, 0x03c0, 0x03c1, 0x0000, 0x03c3, 0x03c4, 0x03c5, 0x03c6, 0x03c7, 0x03c8, 0x03c9, 0x03ca, - 0x03cb, 0x0386, 0x0388, 0x0389, 0x038a, 0x0000, 0x0391, 0x0392, 0x0393, + 0x03cb, 0x0386, 0x0388, 0x0389, 0x038a, 0xd810, 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, 0x0398, 0x0399, 0x039a, 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, 0x03a0, 0x03a1, 0x03a3, 0x03a3, 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, 0x03aa, 0x03ab, 0x038c, 0x038e, 0x038f, @@ -5081,7 +5081,7 @@ static unsigned short attrpage3[256] = { 0x0000, 0x0000, 0x03db, 0x03da, 0x03dd, 0x03dc, 0x03df, 0x03de, 0x03e1, 0x03e0, 0x03e3, 0x03e2, 0x03e5, 0x03e4, 0x03e7, 0x03e6, 0x03e9, 0x03e8, 0x03eb, 0x03ea, 0x03ed, 0x03ec, 0x03ef, 0x03ee, 0x039a, 0x03a1, 0x03a3, - 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x03b8, 0x0395, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 }; @@ -5133,7 +5133,7 @@ static unsigned short attrpage5[256] = { 0x053c, 0x053d, 0x053e, 0x053f, 0x0540, 0x0541, 0x0542, 0x0543, 0x0544, 0x0545, 0x0546, 0x0547, 0x0548, 0x0549, 0x054a, 0x054b, 0x054c, 0x054d, 0x054e, 0x054f, 0x0550, 0x0551, 0x0552, 0x0553, 0x0554, 0x0555, 0x0556, - 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0xd808, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, @@ -5550,8 +5550,8 @@ static unsigned short attrpage30[256] = { 0x1e74, 0x1e77, 0x1e76, 0x1e79, 0x1e78, 0x1e7b, 0x1e7a, 0x1e7d, 0x1e7c, 0x1e7f, 0x1e7e, 0x1e81, 0x1e80, 0x1e83, 0x1e82, 0x1e85, 0x1e84, 0x1e87, 0x1e86, 0x1e89, 0x1e88, 0x1e8b, 0x1e8a, 0x1e8d, 0x1e8c, 0x1e8f, 0x1e8e, - 0x1e91, 0x1e90, 0x1e93, 0x1e92, 0x1e95, 0x1e94, 0x0000, 0x0000, 0x0000, - 0x0000, 0x0000, 0x1e60, 0x0000, 0x0000, 0x0000, 0x0000, 0x1ea1, 0x1ea0, + 0x1e91, 0x1e90, 0x1e93, 0x1e92, 0x1e95, 0x1e94, 0xd812, 0xd813, 0xd814, + 0xd815, 0xd816, 0x1e60, 0x0000, 0x0000, 0x0000, 0x0000, 0x1ea1, 0x1ea0, 0x1ea3, 0x1ea2, 0x1ea5, 0x1ea4, 0x1ea7, 0x1ea6, 0x1ea9, 0x1ea8, 0x1eab, 0x1eaa, 0x1ead, 0x1eac, 0x1eaf, 0x1eae, 0x1eb1, 0x1eb0, 0x1eb3, 0x1eb2, 0x1eb5, 0x1eb4, 0x1eb7, 0x1eb6, 0x1eb9, 0x1eb8, 0x1ebb, 0x1eba, 0x1ebd, @@ -5574,27 +5574,27 @@ static unsigned short attrpage31[256] = { 0x1f25, 0x1f26, 0x1f27, 0x1f38, 0x1f39, 0x1f3a, 0x1f3b, 0x1f3c, 0x1f3d, 0x1f3e, 0x1f3f, 0x1f30, 0x1f31, 0x1f32, 0x1f33, 0x1f34, 0x1f35, 0x1f36, 0x1f37, 0x1f48, 0x1f49, 0x1f4a, 0x1f4b, 0x1f4c, 0x1f4d, 0x0000, 0x0000, - 0x1f40, 0x1f41, 0x1f42, 0x1f43, 0x1f44, 0x1f45, 0x0000, 0x0000, 0x0000, - 0x1f59, 0x0000, 0x1f5b, 0x0000, 0x1f5d, 0x0000, 0x1f5f, 0x0000, 0x1f51, + 0x1f40, 0x1f41, 0x1f42, 0x1f43, 0x1f44, 0x1f45, 0x0000, 0x0000, 0xd817, + 0x1f59, 0xd818, 0x1f5b, 0xd819, 0x1f5d, 0xd81a, 0x1f5f, 0x0000, 0x1f51, 0x0000, 0x1f53, 0x0000, 0x1f55, 0x0000, 0x1f57, 0x1f68, 0x1f69, 0x1f6a, 0x1f6b, 0x1f6c, 0x1f6d, 0x1f6e, 0x1f6f, 0x1f60, 0x1f61, 0x1f62, 0x1f63, 0x1f64, 0x1f65, 0x1f66, 0x1f67, 0x1fba, 0x1fbb, 0x1fc8, 0x1fc9, 0x1fca, 0x1fcb, 0x1fda, 0x1fdb, 0x1ff8, 0x1ff9, 0x1fea, 0x1feb, 0x1ffa, 0x1ffb, - 0x0000, 0x0000, 0x1f88, 0x1f89, 0x1f8a, 0x1f8b, 0x1f8c, 0x1f8d, 0x1f8e, - 0x1f8f, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, - 0x1f98, 0x1f99, 0x1f9a, 0x1f9b, 0x1f9c, 0x1f9d, 0x1f9e, 0x1f9f, 0x0000, - 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x1fa8, 0x1fa9, - 0x1faa, 0x1fab, 0x1fac, 0x1fad, 0x1fae, 0x1faf, 0x0000, 0x0000, 0x0000, - 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x1fb8, 0x1fb9, 0x0000, 0x1fbc, - 0x0000, 0x0000, 0x0000, 0x0000, 0x1fb0, 0x1fb1, 0x1f70, 0x1f71, 0x0000, - 0x0000, 0x0399, 0x0000, 0x0000, 0x0000, 0x0000, 0x1fcc, 0x0000, 0x0000, - 0x0000, 0x0000, 0x1f72, 0x1f73, 0x1f74, 0x1f75, 0x0000, 0x0000, 0x0000, - 0x0000, 0x1fd8, 0x1fd9, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0xd827, 0xd828, 0xd829, 0xd82a, 0xd82b, 0xd82c, 0xd82d, + 0xd82e, 0xd82f, 0xd830, 0xd831, 0xd832, 0xd833, 0xd834, 0xd835, 0xd836, + 0xd837, 0xd838, 0xd839, 0xd83a, 0xd83b, 0xd83c, 0xd83d, 0xd83e, 0xd83f, + 0xd840, 0xd841, 0xd842, 0xd843, 0xd844, 0xd845, 0xd846, 0xd847, 0xd848, + 0xd849, 0xd84a, 0xd84b, 0xd84c, 0xd84d, 0xd84e, 0xd84f, 0xd850, 0xd851, + 0xd852, 0xd853, 0xd854, 0xd855, 0xd856, 0x1fb8, 0x1fb9, 0xd85d, 0xd857, + 0xd85e, 0x0000, 0xd81b, 0xd863, 0x1fb0, 0x1fb1, 0x1f70, 0x1f71, 0xd858, + 0x0000, 0x0399, 0x0000, 0x0000, 0x0000, 0xd85f, 0xd859, 0xd860, 0x0000, + 0xd81c, 0xd864, 0x1f72, 0x1f73, 0x1f74, 0x1f75, 0xd85a, 0x0000, 0x0000, + 0x0000, 0x1fd8, 0x1fd9, 0xd81d, 0xd81e, 0x0000, 0x0000, 0xd81f, 0xd820, 0x1fd0, 0x1fd1, 0x1f76, 0x1f77, 0x0000, 0x0000, 0x0000, 0x0000, 0x1fe8, - 0x1fe9, 0x0000, 0x0000, 0x0000, 0x1fec, 0x0000, 0x0000, 0x1fe0, 0x1fe1, - 0x1f7a, 0x1f7b, 0x1fe5, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, - 0x1ffc, 0x0000, 0x0000, 0x0000, 0x0000, 0x1f78, 0x1f79, 0x1f7c, 0x1f7d, - 0x0000, 0x0000, 0x0000, 0x0000 + 0x1fe9, 0xd821, 0xd822, 0xd823, 0x1fec, 0xd824, 0xd825, 0x1fe0, 0x1fe1, + 0x1f7a, 0x1f7b, 0x1fe5, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xd861, + 0xd85b, 0xd862, 0x0000, 0xd826, 0xd865, 0x1f78, 0x1f79, 0x1f7c, 0x1f7d, + 0xd85c, 0x0000, 0x0000, 0x0000 }; static unsigned short attrpage33[256] = { @@ -5629,6 +5629,38 @@ static unsigned short attrpage33[256] = { 0x0000, 0x0000, 0x0000, 0x0000 }; +static unsigned short attrpage251[256] = { + 0xd801, 0xd802, 0xd803, 0xd804, 0xd805, 0xd806, 0xd807, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0xd809, 0xd80a, 0xd80b, 0xd80c, 0xd80d, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000 +}; + static unsigned short attrpage255[256] = { 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, @@ -5913,7 +5945,7 @@ static unsigned short *attr_table[256] = { 0x0000, 0x0000, 0x0000, - 0x0000, + attrpage251, 0x0000, 0x0000, 0x0000, @@ -5954,4 +5986,284 @@ static unsigned short title_table[][3] = { { 0x1ffc, 0x0000, 0x1ff3 } }; + +/* Table of special cases for case conversion; each record contains + * First, the best single character mapping to lowercase if Lu, + * and to uppercase if Ll, followed by the output mapping for the two cases + * other than the case of the codepoint, in the order [Ll],[Lu],[Lt], + * separated and terminated by a double NUL. + */ +static guchar special_case_table[][18] = { + "\x00\x00\x00\x53\x00\x53\x00\x00\x00\x53\x00\x73\0", + "\x00\x00\x00\x46\x00\x46\x00\x00\x00\x46\x00\x66\0", + "\x00\x00\x00\x46\x00\x49\x00\x00\x00\x46\x00\x69\0", + "\x00\x00\x00\x46\x00\x4c\x00\x00\x00\x46\x00\x6c\0", + "\x00\x00\x00\x46\x00\x46\x00\x49\x00\x00\x00\x46\x00\x66\x00\x69\0", + "\x00\x00\x00\x46\x00\x46\x00\x4c\x00\x00\x00\x46\x00\x66\x00\x6c\0", + "\x00\x00\x00\x53\x00\x54\x00\x00\x00\x53\x00\x74\0", + "\x00\x00\x00\x53\x00\x54\x00\x00\x00\x53\x00\x74\0", + "\x00\x00\x05\x35\x05\x52\x00\x00\x05\x35\x05\x82\0", + "\x00\x00\x05\x44\x05\x46\x00\x00\x05\x44\x05\x76\0", + "\x00\x00\x05\x44\x05\x35\x00\x00\x05\x44\x05\x65\0", + "\x00\x00\x05\x44\x05\x3b\x00\x00\x05\x44\x05\x6b\0", + "\x00\x00\x05\x4e\x05\x46\x00\x00\x05\x4e\x05\x76\0", + "\x00\x00\x05\x44\x05\x3d\x00\x00\x05\x44\x05\x6d\0", + "\x00\x00\x02\xbc\x00\x4e\x00\x00\x02\xbc\x00\x4e\0", + "\x00\x00\x03\x99\x03\x08\x03\x01\x00\x00\x03\x99\x03\x08\x03\x01\0", + "\x00\x00\x03\xa5\x03\x08\x03\x01\x00\x00\x03\xa5\x03\x08\x03\x01\0", + "\x00\x00\x00\x4a\x03\x0c\x00\x00\x00\x4a\x03\x0c\0", + "\x00\x00\x00\x48\x03\x31\x00\x00\x00\x48\x03\x31\0", + "\x00\x00\x00\x54\x03\x08\x00\x00\x00\x54\x03\x08\0", + "\x00\x00\x00\x57\x03\x0a\x00\x00\x00\x57\x03\x0a\0", + "\x00\x00\x00\x59\x03\x0a\x00\x00\x00\x59\x03\x0a\0", + "\x00\x00\x00\x41\x02\xbe\x00\x00\x00\x41\x02\xbe\0", + "\x00\x00\x03\xa5\x03\x13\x00\x00\x03\xa5\x03\x13\0", + "\x00\x00\x03\xa5\x03\x13\x03\x00\x00\x00\x03\xa5\x03\x13\x03\x00\0", + "\x00\x00\x03\xa5\x03\x13\x03\x01\x00\x00\x03\xa5\x03\x13\x03\x01\0", + "\x00\x00\x03\xa5\x03\x13\x03\x42\x00\x00\x03\xa5\x03\x13\x03\x42\0", + "\x00\x00\x03\x91\x03\x42\x00\x00\x03\x91\x03\x42\0", + "\x00\x00\x03\x97\x03\x42\x00\x00\x03\x97\x03\x42\0", + "\x00\x00\x03\x99\x03\x08\x03\x00\x00\x00\x03\x99\x03\x08\x03\x00\0", + "\x00\x00\x03\x99\x03\x08\x03\x01\x00\x00\x03\x99\x03\x08\x03\x01\0", + "\x00\x00\x03\x99\x03\x42\x00\x00\x03\x99\x03\x42\0", + "\x00\x00\x03\x99\x03\x08\x03\x42\x00\x00\x03\x99\x03\x08\x03\x42\0", + "\x00\x00\x03\xa5\x03\x08\x03\x00\x00\x00\x03\xa5\x03\x08\x03\x00\0", + "\x00\x00\x03\xa5\x03\x08\x03\x01\x00\x00\x03\xa5\x03\x08\x03\x01\0", + "\x00\x00\x03\xa1\x03\x13\x00\x00\x03\xa1\x03\x13\0", + "\x00\x00\x03\xa5\x03\x42\x00\x00\x03\xa5\x03\x42\0", + "\x00\x00\x03\xa5\x03\x08\x03\x42\x00\x00\x03\xa5\x03\x08\x03\x42\0", + "\x00\x00\x03\xa9\x03\x42\x00\x00\x03\xa9\x03\x42\0", + "\x1f\x88\x1f\x08\x03\x99\x00\x00\x1f\x88\0", + "\x1f\x89\x1f\x09\x03\x99\x00\x00\x1f\x89\0", + "\x1f\x8a\x1f\x0a\x03\x99\x00\x00\x1f\x8a\0", + "\x1f\x8b\x1f\x0b\x03\x99\x00\x00\x1f\x8b\0", + "\x1f\x8c\x1f\x0c\x03\x99\x00\x00\x1f\x8c\0", + "\x1f\x8d\x1f\x0d\x03\x99\x00\x00\x1f\x8d\0", + "\x1f\x8e\x1f\x0e\x03\x99\x00\x00\x1f\x8e\0", + "\x1f\x8f\x1f\x0f\x03\x99\x00\x00\x1f\x8f\0", + "\x1f\x80\x00\x00\x1f\x08\x03\x99\0", + "\x1f\x81\x00\x00\x1f\x09\x03\x99\0", + "\x1f\x82\x00\x00\x1f\x0a\x03\x99\0", + "\x1f\x83\x00\x00\x1f\x0b\x03\x99\0", + "\x1f\x84\x00\x00\x1f\x0c\x03\x99\0", + "\x1f\x85\x00\x00\x1f\x0d\x03\x99\0", + "\x1f\x86\x00\x00\x1f\x0e\x03\x99\0", + "\x1f\x87\x00\x00\x1f\x0f\x03\x99\0", + "\x1f\x98\x1f\x28\x03\x99\x00\x00\x1f\x98\0", + "\x1f\x99\x1f\x29\x03\x99\x00\x00\x1f\x99\0", + "\x1f\x9a\x1f\x2a\x03\x99\x00\x00\x1f\x9a\0", + "\x1f\x9b\x1f\x2b\x03\x99\x00\x00\x1f\x9b\0", + "\x1f\x9c\x1f\x2c\x03\x99\x00\x00\x1f\x9c\0", + "\x1f\x9d\x1f\x2d\x03\x99\x00\x00\x1f\x9d\0", + "\x1f\x9e\x1f\x2e\x03\x99\x00\x00\x1f\x9e\0", + "\x1f\x9f\x1f\x2f\x03\x99\x00\x00\x1f\x9f\0", + "\x1f\x90\x00\x00\x1f\x28\x03\x99\0", + "\x1f\x91\x00\x00\x1f\x29\x03\x99\0", + "\x1f\x92\x00\x00\x1f\x2a\x03\x99\0", + "\x1f\x93\x00\x00\x1f\x2b\x03\x99\0", + "\x1f\x94\x00\x00\x1f\x2c\x03\x99\0", + "\x1f\x95\x00\x00\x1f\x2d\x03\x99\0", + "\x1f\x96\x00\x00\x1f\x2e\x03\x99\0", + "\x1f\x97\x00\x00\x1f\x2f\x03\x99\0", + "\x1f\xa8\x1f\x68\x03\x99\x00\x00\x1f\xa8\0", + "\x1f\xa9\x1f\x69\x03\x99\x00\x00\x1f\xa9\0", + "\x1f\xaa\x1f\x6a\x03\x99\x00\x00\x1f\xaa\0", + "\x1f\xab\x1f\x6b\x03\x99\x00\x00\x1f\xab\0", + "\x1f\xac\x1f\x6c\x03\x99\x00\x00\x1f\xac\0", + "\x1f\xad\x1f\x6d\x03\x99\x00\x00\x1f\xad\0", + "\x1f\xae\x1f\x6e\x03\x99\x00\x00\x1f\xae\0", + "\x1f\xaf\x1f\x6f\x03\x99\x00\x00\x1f\xaf\0", + "\x1f\xa0\x00\x00\x1f\x68\x03\x99\0", + "\x1f\xa1\x00\x00\x1f\x69\x03\x99\0", + "\x1f\xa2\x00\x00\x1f\x6a\x03\x99\0", + "\x1f\xa3\x00\x00\x1f\x6b\x03\x99\0", + "\x1f\xa4\x00\x00\x1f\x6c\x03\x99\0", + "\x1f\xa5\x00\x00\x1f\x6d\x03\x99\0", + "\x1f\xa6\x00\x00\x1f\x6e\x03\x99\0", + "\x1f\xa7\x00\x00\x1f\x6f\x03\x99\0", + "\x1f\xbc\x03\x91\x03\x99\x00\x00\x1f\xbc\0", + "\x1f\xb3\x00\x00\x03\x91\x03\x99\0", + "\x1f\xcc\x03\x97\x03\x99\x00\x00\x1f\xcc\0", + "\x1f\xc3\x00\x00\x03\x97\x03\x99\0", + "\x1f\xfc\x03\xa9\x03\x99\x00\x00\x1f\xfc\0", + "\x1f\xf3\x00\x00\x03\xa9\x03\x99\0", + "\x00\x00\x1f\xba\x03\x99\x00\x00\x1f\xba\x03\x45\0", + "\x00\x00\x03\x86\x03\x99\x00\x00\x03\x86\x03\x45\0", + "\x00\x00\x1f\xca\x03\x99\x00\x00\x1f\xca\x03\x45\0", + "\x00\x00\x03\x89\x03\x99\x00\x00\x03\x89\x03\x45\0", + "\x00\x00\x1f\xfa\x03\x99\x00\x00\x1f\xfa\x03\x45\0", + "\x00\x00\x03\x8f\x03\x99\x00\x00\x03\x8f\x03\x45\0", + "\x00\x00\x03\x91\x03\x42\x03\x99\x00\x00\x03\x91\x03\x42\x03\x45\0", + "\x00\x00\x03\x97\x03\x42\x03\x99\x00\x00\x03\x97\x03\x42\x03\x45\0", + "\x00\x00\x03\xa9\x03\x42\x03\x99\x00\x00\x03\xa9\x03\x42\x03\x45\0", +}; + + +/* Table of casefolding cases that can't be derived by lowercasing + */ +static struct { + guint16 ch; + gchar data[7]; +} casefold_table[] = { +{ 0xb5, "μ" }, +{ 0xdf, "ss" }, +{ 0x131, "i" }, +{ 0x149, "ʼn" }, +{ 0x17f, "s" }, +{ 0x1f0, "ǰ" }, +{ 0x345, "ι" }, +{ 0x390, "ΐ" }, +{ 0x3b0, "ΰ" }, +{ 0x3c2, "σ" }, +{ 0x3d0, "β" }, +{ 0x3d1, "θ" }, +{ 0x3d5, "φ" }, +{ 0x3d6, "π" }, +{ 0x3f0, "κ" }, +{ 0x3f1, "ρ" }, +{ 0x3f2, "σ" }, +{ 0x3f5, "ε" }, +{ 0x587, "եւ" }, +{ 0x1e96, "ẖ" }, +{ 0x1e97, "ẗ" }, +{ 0x1e98, "ẘ" }, +{ 0x1e99, "ẙ" }, +{ 0x1e9a, "aʾ" }, +{ 0x1e9b, "ṡ" }, +{ 0x1f50, "ὐ" }, +{ 0x1f52, "ὒ" }, +{ 0x1f54, "ὔ" }, +{ 0x1f56, "ὖ" }, +{ 0x1f80, "ἀι" }, +{ 0x1f81, "ἁι" }, +{ 0x1f82, "ἂι" }, +{ 0x1f83, "ἃι" }, +{ 0x1f84, "ἄι" }, +{ 0x1f85, "ἅι" }, +{ 0x1f86, "ἆι" }, +{ 0x1f87, "ἇι" }, +{ 0x1f88, "ἀι" }, +{ 0x1f89, "ἁι" }, +{ 0x1f8a, "ἂι" }, +{ 0x1f8b, "ἃι" }, +{ 0x1f8c, "ἄι" }, +{ 0x1f8d, "ἅι" }, +{ 0x1f8e, "ἆι" }, +{ 0x1f8f, "ἇι" }, +{ 0x1f90, "ἠι" }, +{ 0x1f91, "ἡι" }, +{ 0x1f92, "ἢι" }, +{ 0x1f93, "ἣι" }, +{ 0x1f94, "ἤι" }, +{ 0x1f95, "ἥι" }, +{ 0x1f96, "ἦι" }, +{ 0x1f97, "ἧι" }, +{ 0x1f98, "ἠι" }, +{ 0x1f99, "ἡι" }, +{ 0x1f9a, "ἢι" }, +{ 0x1f9b, "ἣι" }, +{ 0x1f9c, "ἤι" }, +{ 0x1f9d, "ἥι" }, +{ 0x1f9e, "ἦι" }, +{ 0x1f9f, "ἧι" }, +{ 0x1fa0, "ὠι" }, +{ 0x1fa1, "ὡι" }, +{ 0x1fa2, "ὢι" }, +{ 0x1fa3, "ὣι" }, +{ 0x1fa4, "ὤι" }, +{ 0x1fa5, "ὥι" }, +{ 0x1fa6, "ὦι" }, +{ 0x1fa7, "ὧι" }, +{ 0x1fa8, "ὠι" }, +{ 0x1fa9, "ὡι" }, +{ 0x1faa, "ὢι" }, +{ 0x1fab, "ὣι" }, +{ 0x1fac, "ὤι" }, +{ 0x1fad, "ὥι" }, +{ 0x1fae, "ὦι" }, +{ 0x1faf, "ὧι" }, +{ 0x1fb2, "ὰι" }, +{ 0x1fb3, "αι" }, +{ 0x1fb4, "άι" }, +{ 0x1fb6, "ᾶ" }, +{ 0x1fb7, "ᾶι" }, +{ 0x1fbc, "αι" }, +{ 0x1fbe, "ι" }, +{ 0x1fc2, "ὴι" }, +{ 0x1fc3, "ηι" }, +{ 0x1fc4, "ήι" }, +{ 0x1fc6, "ῆ" }, +{ 0x1fc7, "ῆι" }, +{ 0x1fcc, "ηι" }, +{ 0x1fd2, "ῒ" }, +{ 0x1fd3, "ΐ" }, +{ 0x1fd6, "ῖ" }, +{ 0x1fd7, "ῗ" }, +{ 0x1fe2, "ῢ" }, +{ 0x1fe3, "ΰ" }, +{ 0x1fe4, "ῤ" }, +{ 0x1fe6, "ῦ" }, +{ 0x1fe7, "ῧ" }, +{ 0x1ff2, "ὼι" }, +{ 0x1ff3, "ωι" }, +{ 0x1ff4, "ώι" }, +{ 0x1ff6, "ῶ" }, +{ 0x1ff7, "ῶι" }, +{ 0x1ffc, "ωι" }, +{ 0x2160, "ⅰ" }, +{ 0x2161, "ⅱ" }, +{ 0x2162, "ⅲ" }, +{ 0x2163, "ⅳ" }, +{ 0x2164, "ⅴ" }, +{ 0x2165, "ⅵ" }, +{ 0x2166, "ⅶ" }, +{ 0x2167, "ⅷ" }, +{ 0x2168, "ⅸ" }, +{ 0x2169, "ⅹ" }, +{ 0x216a, "ⅺ" }, +{ 0x216b, "ⅻ" }, +{ 0x216c, "ⅼ" }, +{ 0x216d, "ⅽ" }, +{ 0x216e, "ⅾ" }, +{ 0x216f, "ⅿ" }, +{ 0x24b6, "ⓐ" }, +{ 0x24b7, "ⓑ" }, +{ 0x24b8, "ⓒ" }, +{ 0x24b9, "ⓓ" }, +{ 0x24ba, "ⓔ" }, +{ 0x24bb, "ⓕ" }, +{ 0x24bc, "ⓖ" }, +{ 0x24bd, "ⓗ" }, +{ 0x24be, "ⓘ" }, +{ 0x24bf, "ⓙ" }, +{ 0x24c0, "ⓚ" }, +{ 0x24c1, "ⓛ" }, +{ 0x24c2, "ⓜ" }, +{ 0x24c3, "ⓝ" }, +{ 0x24c4, "ⓞ" }, +{ 0x24c5, "ⓟ" }, +{ 0x24c6, "ⓠ" }, +{ 0x24c7, "ⓡ" }, +{ 0x24c8, "ⓢ" }, +{ 0x24c9, "ⓣ" }, +{ 0x24ca, "ⓤ" }, +{ 0x24cb, "ⓥ" }, +{ 0x24cc, "ⓦ" }, +{ 0x24cd, "ⓧ" }, +{ 0x24ce, "ⓨ" }, +{ 0x24cf, "ⓩ" }, +{ 0xfb00, "ff" }, +{ 0xfb01, "fi" }, +{ 0xfb02, "fl" }, +{ 0xfb03, "ffi" }, +{ 0xfb04, "ffl" }, +{ 0xfb05, "st" }, +{ 0xfb06, "st" }, +{ 0xfb13, "մն" }, +{ 0xfb14, "մե" }, +{ 0xfb15, "մի" }, +{ 0xfb16, "վն" }, +{ 0xfb17, "մխ" }, +}; + #endif /* CHARTABLES_H */ diff --git a/graf2d/win32gdk/gdk/src/glib/gunicode.h b/graf2d/win32gdk/gdk/src/glib/gunicode.h index e730485bf712a..f93f3b1d8af64 100644 --- a/graf2d/win32gdk/gdk/src/glib/gunicode.h +++ b/graf2d/win32gdk/gdk/src/glib/gunicode.h @@ -22,8 +22,8 @@ #ifndef __G_UNICODE_H__ #define __G_UNICODE_H__ -#include <stddef.h> /* For size_t */ -#include <g_types.h> +#include <glib/gerror.h> +#include <glib/gtypes.h> G_BEGIN_DECLS @@ -109,7 +109,7 @@ typedef enum * in case the locale's charset will be changed later using setlocale() * or in some other way. */ -gboolean g_get_charset (char **charset); +gboolean g_get_charset (G_CONST_RETURN char **charset); /* These are all analogs of the <ctype.h> functions. */ @@ -151,89 +151,130 @@ GUnicodeBreakType g_unichar_break_type (gunichar c) G_GNUC_CONST; decomposed characters in the string according to their combining classes. See the Unicode manual for more information. */ void g_unicode_canonical_ordering (gunichar *string, - size_t len); + gsize len); /* Compute canonical decomposition of a character. Returns g_malloc()d string of Unicode characters. RESULT_LEN is set to the resulting length of the string. */ gunichar *g_unicode_canonical_decomposition (gunichar ch, - size_t *result_len); + gsize *result_len); /* Array of skip-bytes-per-initial character. - * We prefix variable declarations so they can - * properly get exported in windows dlls. */ -#ifndef GLIB_VAR -# ifdef G_OS_WIN32 -# ifdef GLIB_COMPILATION -# define GLIB_VAR __declspec(dllexport) -# else /* !GLIB_COMPILATION */ -# define GLIB_VAR extern __declspec(dllimport) -# endif /* !GLIB_COMPILATION */ -# else /* !G_OS_WIN32 */ -# define GLIB_VAR extern -# endif /* !G_OS_WIN32 */ -#endif /* !GLIB_VAR */ - -GLIB_VAR char g_utf8_skip[256]; +GLIB_VAR const gchar * const g_utf8_skip; #define g_utf8_next_char(p) (char *)((p) + g_utf8_skip[*(guchar *)(p)]) -gunichar g_utf8_get_char (const gchar *p); -gchar * g_utf8_offset_to_pointer (const gchar *str, - gint offset); -gint g_utf8_pointer_to_offset (const gchar *str, +gunichar g_utf8_get_char (const gchar *p); +gunichar g_utf8_get_char_validated (const gchar *p, + gssize max_len); + +gchar* g_utf8_offset_to_pointer (const gchar *str, + glong offset); +glong g_utf8_pointer_to_offset (const gchar *str, const gchar *pos); -gchar * g_utf8_prev_char (const gchar *p); -gchar * g_utf8_find_next_char (const gchar *p, +gchar* g_utf8_prev_char (const gchar *p); +gchar* g_utf8_find_next_char (const gchar *p, const gchar *end); -gchar * g_utf8_find_prev_char (const gchar *str, +gchar* g_utf8_find_prev_char (const gchar *str, const gchar *p); -gint g_utf8_strlen (const gchar *p, - gint max); +glong g_utf8_strlen (const gchar *p, + gssize max); /* Copies n characters from src to dest */ -gchar *g_utf8_strncpy (gchar *dest, +gchar* g_utf8_strncpy (gchar *dest, const gchar *src, - size_t n); + gsize n); /* Find the UTF-8 character corresponding to ch, in string p. These functions are equivalants to strchr and strrchr */ - -gchar *g_utf8_strchr (const gchar *p, +gchar* g_utf8_strchr (const gchar *p, + gssize len, gunichar c); -gchar *g_utf8_strrchr (const gchar *p, +gchar* g_utf8_strrchr (const gchar *p, + gssize len, gunichar c); -gunichar2 *g_utf8_to_utf16 (const gchar *str, - gint len); -gunichar * g_utf8_to_ucs4 (const gchar *str, - gint len); -gunichar * g_utf16_to_ucs4 (const gunichar2 *str, - gint len); -gchar * g_utf16_to_utf8 (const gunichar2 *str, - gint len); -gunichar * g_ucs4_to_utf16 (const gunichar *str, - gint len); -gchar * g_ucs4_to_utf8 (const gunichar *str, - gint len); +gunichar2 *g_utf8_to_utf16 (const gchar *str, + glong len, + glong *items_read, + glong *items_written, + GError **error); +gunichar * g_utf8_to_ucs4 (const gchar *str, + glong len, + glong *items_read, + glong *items_written, + GError **error); +gunichar * g_utf8_to_ucs4_fast (const gchar *str, + glong len, + glong *items_written); +gunichar * g_utf16_to_ucs4 (const gunichar2 *str, + glong len, + glong *items_read, + glong *items_written, + GError **error); +gchar* g_utf16_to_utf8 (const gunichar2 *str, + glong len, + glong *items_read, + glong *items_written, + GError **error); +gunichar2 *g_ucs4_to_utf16 (const gunichar *str, + glong len, + glong *items_read, + glong *items_written, + GError **error); +gchar* g_ucs4_to_utf8 (const gunichar *str, + glong len, + glong *items_read, + glong *items_written, + GError **error); /* Convert a single character into UTF-8. outbuf must have at * least 6 bytes of space. Returns the number of bytes in the * result. */ gint g_unichar_to_utf8 (gunichar c, - char *outbuf); + gchar *outbuf); /* Validate a UTF8 string, return TRUE if valid, put pointer to * first invalid char in **end */ gboolean g_utf8_validate (const gchar *str, - gint max_len, + gssize max_len, const gchar **end); +/* Validate a Unicode character */ +gboolean g_unichar_validate (gunichar ch); + +gchar *g_utf8_strup (const gchar *str, + gssize len); +gchar *g_utf8_strdown (const gchar *str, + gssize len); +gchar *g_utf8_casefold (const gchar *str, + gssize len); + +typedef enum { + G_NORMALIZE_DEFAULT, + G_NORMALIZE_NFD = G_NORMALIZE_DEFAULT, + G_NORMALIZE_DEFAULT_COMPOSE, + G_NORMALIZE_NFC = G_NORMALIZE_DEFAULT_COMPOSE, + G_NORMALIZE_ALL, + G_NORMALIZE_NFKD = G_NORMALIZE_ALL, + G_NORMALIZE_ALL_COMPOSE, + G_NORMALIZE_NFKC = G_NORMALIZE_ALL_COMPOSE +} GNormalizeMode; + +gchar *g_utf8_normalize (const gchar *str, + gssize len, + GNormalizeMode mode); + +gint g_utf8_collate (const gchar *str1, + const gchar *str2); +gchar *g_utf8_collate_key (const gchar *str, + gssize len); + G_END_DECLS #endif /* __G_UNICODE_H__ */ diff --git a/graf2d/win32gdk/gdk/src/glib/gunicollate.c b/graf2d/win32gdk/gdk/src/glib/gunicollate.c new file mode 100644 index 0000000000000..41cbe812e86d2 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gunicollate.c @@ -0,0 +1,235 @@ +/* gunicollate.c - Collation + * + * Copyright 2001 Red Hat, Inc. + * + * The Gnome Library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2 of the + * License, or (at your option) any later version. + * + * The Gnome Library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with the Gnome Library; see the file COPYING.LIB. If not, + * write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include <locale.h> +#include <string.h> +#ifdef __STDC_ISO_10646__ +#include <wchar.h> +#endif + +#include "glib.h" + +extern gunichar *_g_utf8_normalize_wc (const gchar *str, + gssize max_len, + GNormalizeMode mode); + +/** + * g_utf8_collate: + * @str1: a UTF-8 encoded string + * @str2: a UTF-8 encoded string + * + * Compares two strings for ordering using the linguistically + * correct rules for the current locale. When sorting a large + * number of strings, it will be significantly faster to + * obtain collation keys with g_utf8_collate_key() and + * compare the keys with <function>strcmp()</function> when + * sorting instead of sorting the original strings. + * + * Return value: -1 if @str1 compares before @str2, 0 if they + * compare equal, 1 if @str1 compares after @str2. + **/ +gint +g_utf8_collate (const gchar *str1, + const gchar *str2) +{ + gint result; + +#ifdef __STDC_ISO_10646__ + + gunichar *str1_norm = _g_utf8_normalize_wc (str1, -1, G_NORMALIZE_ALL_COMPOSE); + gunichar *str2_norm = _g_utf8_normalize_wc (str2, -1, G_NORMALIZE_ALL_COMPOSE); + + result = wcscoll ((wchar_t *)str1_norm, (wchar_t *)str2_norm); + + g_free (str1_norm); + g_free (str2_norm); + +#else /* !__STDC_ISO_10646__ */ + + const gchar *charset; + gchar *str1_norm = g_utf8_normalize (str1, -1, G_NORMALIZE_ALL_COMPOSE); + gchar *str2_norm = g_utf8_normalize (str2, -1, G_NORMALIZE_ALL_COMPOSE); + + if (g_get_charset (&charset)) + { + result = strcoll (str1_norm, str2_norm); + } + else + { + gchar *str1_locale = g_convert (str1_norm, -1, "UTF-8", charset, NULL, NULL, NULL); + gchar *str2_locale = g_convert (str2_norm, -1, "UTF-8", charset, NULL, NULL, NULL); + + if (str1_locale && str2_locale) + result = strcoll (str1_locale, str2_locale); + else if (str1_locale) + result = -1; + else if (str2_locale) + result = 1; + else + result = strcmp (str1_norm, str2_norm); + + g_free (str1_locale); + g_free (str2_locale); + } + + g_free (str1_norm); + g_free (str2_norm); + +#endif /* __STDC_ISO_10646__ */ + + return result; +} + +#ifdef __STDC_ISO_10646__ +/* We need UTF-8 encoding of numbers to encode the weights if + * we are using wcsxfrm. However, we aren't encoding Unicode + * characters, so we can't simply use g_unichar_to_utf8. + * + * The following routine is taken (with modification) from GNU + * libc's strxfrm routine: + * + * Copyright (C) 1995-1999,2000,2001 Free Software Foundation, Inc. + * Written by Ulrich Drepper <drepper@cygnus.com>, 1995. + */ +static inline int +utf8_encode (char *buf, wchar_t val) +{ + int retval; + + if (val < 0x80) + { + if (buf) + *buf++ = (char) val; + retval = 1; + } + else + { + int step; + + for (step = 2; step < 6; ++step) + if ((val & (~(guint32)0 << (5 * step + 1))) == 0) + break; + retval = step; + + if (buf) + { + *buf = (unsigned char) (~0xff >> step); + --step; + do + { + buf[step] = 0x80 | (val & 0x3f); + val >>= 6; + } + while (--step > 0); + *buf |= val; + } + } + + return retval; +} +#endif /* __STDC_ISO_10646__ */ + +/** + * g_utf8_collate_key: + * @str: a UTF-8 encoded string. + * @len: length of @str, in bytes, or -1 if @str is nul-terminated. + * + * Converts a string into a collation key that can be compared + * with other collation keys using <function>strcmp()</function>. + * The results of comparing the collation keys of two strings + * with <function>strcmp()</function> will always be the same as + * comparing the two original keys with g_utf8_collate(). + * + * Return value: a newly allocated string. This string should + * be freed with g_free() when you are done with it. + **/ +gchar * +g_utf8_collate_key (const gchar *str, + gssize len) +{ + gchar *result; + size_t xfrm_len; + +#ifdef __STDC_ISO_10646__ + + gunichar *str_norm = _g_utf8_normalize_wc (str, len, G_NORMALIZE_ALL_COMPOSE); + wchar_t *result_wc; + size_t i; + size_t result_len = 0; + + setlocale (LC_COLLATE, ""); + + xfrm_len = wcsxfrm (NULL, (wchar_t *)str_norm, 0); + result_wc = g_new (wchar_t, xfrm_len + 1); + wcsxfrm (result_wc, (wchar_t *)str_norm, xfrm_len + 1); + + for (i=0; i < xfrm_len; i++) + result_len += utf8_encode (NULL, result_wc[i]); + + result = g_malloc (result_len + 1); + result_len = 0; + for (i=0; i < xfrm_len; i++) + result_len += utf8_encode (result + result_len, result_wc[i]); + + result[result_len] = '\0'; + + g_free (result_wc); + g_free (str_norm); + + return result; +#else /* !__STDC_ISO_10646__ */ + + const gchar *charset; + gchar *str_norm = g_utf8_normalize (str, len, G_NORMALIZE_ALL_COMPOSE); + + if (g_get_charset (&charset)) + { + xfrm_len = strxfrm (NULL, str_norm, 0); + result = g_malloc (xfrm_len + 1); + strxfrm (result, str_norm, xfrm_len + 1); + } + else + { + gchar *str_locale = g_convert (str_norm, -1, "UTF-8", charset, NULL, NULL, NULL); + + if (str_locale) + { + xfrm_len = strxfrm (NULL, str_locale, 0); + result = g_malloc (xfrm_len + 2); + result[0] = 'A'; + strxfrm (result + 1, str_locale, xfrm_len + 1); + + g_free (str_locale); + } + else + { + xfrm_len = strlen (str_norm); + result = g_malloc (xfrm_len + 2); + result[0] = 'B'; + memcpy (result + 1, str_norm, xfrm_len); + result[xfrm_len+1] = '\0'; + } + } + + g_free (str_norm); +#endif /* __STDC_ISO_10646__ */ + + return result; +} diff --git a/graf2d/win32gdk/gdk/src/glib/gunicomp.h b/graf2d/win32gdk/gdk/src/glib/gunicomp.h new file mode 100644 index 0000000000000..f2414ca568ed6 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gunicomp.h @@ -0,0 +1,667 @@ +#define COMPOSE_FIRST_START 1 +#define COMPOSE_FIRST_SINGLE_START 147 +#define COMPOSE_SECOND_START 357 +#define COMPOSE_SECOND_SINGLE_START 388 + +static gushort compose_page0[256] = { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 147, 148, 149, 0, 0, 1, 2, 3, 4, 5, 150, 6, + 7, 8, 151, 9, 10, 11, 12, 13, 14, 0, 15, 16, 17, 18, 19, 20, 21, 22, 23, 0, + 0, 0, 0, 0, 0, 24, 25, 26, 27, 28, 152, 29, 30, 31, 32, 33, 34, 35, 36, 37, + 38, 0, 39, 40, 41, 42, 43, 44, 45, 46, 47, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 49, 0, 153, 154, 50, 155, 0, 0, 51, 0, 0, 0, + 0, 156, 0, 0, 0, 0, 52, 53, 157, 0, 158, 0, 0, 0, 54, 0, 0, 0, 0, 0, 55, 0, + 159, 160, 56, 161, 0, 0, 57, 0, 0, 0, 0, 162, 0, 0, 0, 0, 58, 59, 163, 0, + 164, 0, 0, 0, 60, 0, 0, 0 +}; + +static gushort compose_page1[256] = { + 0, 0, 61, 62, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 63, 64, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 65, 66, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 165, 166, 0, 0, 0, 0, + 167, 168, 0, 0, 0, 0, 0, 0, 169, 170, 171, 172, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 173, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 67, 68, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 69, 70, 0, 0, 0, 0, 0, 0, 174, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 175, 176, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 +}; + +static gushort compose_page2[256] = { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 177, 178, 179, 180, 0, 0, 0, 0, 181, + 182, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 183, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 +}; + +static gushort compose_page3[256] = { + 357, 358, 359, 360, 361, 0, 362, 363, 364, 365, 366, 367, 368, 0, 0, 369, + 0, 370, 0, 371, 372, 0, 0, 0, 0, 0, 0, 373, 0, 0, 0, 0, 0, 0, 0, 374, 375, + 376, 377, 378, 379, 0, 0, 0, 0, 380, 381, 0, 382, 383, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 384, 0, 0, 385, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 71, 0, 0, 0, 72, 0, 73, 0, 74, 0, + 0, 0, 0, 0, 75, 0, 184, 0, 0, 0, 76, 0, 0, 0, 77, 0, 0, 185, 0, 186, 0, 0, + 78, 0, 0, 0, 79, 0, 80, 0, 81, 0, 0, 0, 0, 0, 82, 0, 83, 0, 0, 0, 84, 0, 0, + 0, 85, 86, 87, 0, 0, 187, 0, 0, 0, 88, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0 +}; + +static gushort compose_page4[256] = { + 0, 0, 0, 0, 0, 0, 188, 0, 0, 0, 0, 0, 0, 0, 0, 0, 89, 0, 0, 189, 0, 90, 91, + 190, 92, 0, 191, 0, 0, 0, 192, 0, 0, 0, 0, 93, 0, 0, 0, 193, 0, 0, 0, 194, + 0, 195, 0, 0, 94, 0, 0, 196, 0, 95, 96, 197, 97, 0, 198, 0, 0, 0, 199, 0, + 0, 0, 0, 98, 0, 0, 0, 200, 0, 0, 0, 201, 0, 202, 0, 0, 0, 0, 0, 0, 0, 0, + 203, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 204, 205, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 206, 207, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 208, 209, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 +}; + +static gushort compose_page6[256] = { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 99, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 210, 0, + 211, 0, 0, 0, 0, 0, 0, 0, 0, 388, 389, 390, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 212, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 213, 0, 0, 214, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 +}; + +static gushort compose_page9[256] = { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 215, 0, 0, 0, 0, 0, 0, 0, 216, + 0, 0, 217, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 391, 0, 0, 0, 0, 0, 0, + 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 392, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 +}; + +static gushort compose_page11[256] = { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 393, 0, 0, 0, 0, 0, 0, 0, 0, 101, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 394, 395, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 218, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 396, 0, 0, 0, 0, 0, + 0, 0, 102, 219, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 397, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 +}; + +static gushort compose_page12[256] = { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 220, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 221, 0, 0, 398, 0, 0, 0, + 103, 0, 0, 0, 222, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 399, 400, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 +}; + +static gushort compose_page13[256] = { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 401, 0, 0, 0, 0, 0, 0, 0, 104, 223, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 402, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 403, 0, 0, 0, 0, 404, 0, 0, 0, 0, 0, 0, 0, 0, 0, 105, 0, 0, + 224, 0, 0, 405, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 +}; + +static gushort compose_page16[256] = { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 225, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0 +}; + +static gushort compose_page30[256] = { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 226, 227, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 228, 229, 0, 0, 0, 0, 0, 0, + 230, 231, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 106, 107, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 232, 233, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 234, 235, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 +}; + +static gushort compose_page31[256] = { + 108, 109, 236, 237, 238, 239, 240, 241, 110, 111, 242, 243, 244, 245, 246, + 247, 112, 113, 0, 0, 0, 0, 0, 0, 114, 115, 0, 0, 0, 0, 0, 0, 116, 117, 248, + 249, 250, 251, 252, 253, 118, 119, 254, 255, 256, 257, 258, 259, 120, 121, + 0, 0, 0, 0, 0, 0, 122, 123, 0, 0, 0, 0, 0, 0, 124, 125, 0, 0, 0, 0, 0, 0, + 126, 127, 0, 0, 0, 0, 0, 0, 128, 129, 0, 0, 0, 0, 0, 0, 0, 130, 0, 0, 0, 0, + 0, 0, 131, 132, 260, 261, 262, 263, 264, 265, 133, 134, 266, 267, 268, 269, + 270, 271, 272, 0, 0, 0, 273, 0, 0, 0, 0, 0, 0, 0, 274, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 275, 0, 0, 0, 0, 0, 0, 0, 0, 135, 0, 0, 0, 0, 0, 0, 276, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 277, 0, 0, 0, 0, 0, 0, 0, + 136, 0 +}; + +static gushort compose_page33[256] = { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 278, 0, 279, 0, + 280, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 281, 0, 282, 0, 283, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 +}; + +static gushort compose_page34[256] = { + 0, 0, 0, 284, 0, 0, 0, 0, 285, 0, 0, 286, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 287, 0, 288, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 289, 0, 0, 0, 0, 0, 0, 290, 0, 291, + 0, 0, 292, 0, 0, 0, 0, 293, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 294, 0, 0, 295, 296, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 297, 298, + 0, 0, 299, 300, 0, 0, 301, 302, 303, 304, 0, 0, 0, 0, 305, 306, 0, 0, 307, + 308, 0, 0, 0, 0, 0, 0, 0, 0, 0, 309, 310, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 311, 0, 0, 0, 0, 0, 312, 313, 0, 314, 0, 0, 0, 0, 0, 0, 315, + 316, 317, 318, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0 +}; + +static gushort compose_page48[256] = { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 319, 0, 0, 0, + 0, 320, 0, 321, 0, 322, 0, 323, 0, 324, 0, 325, 0, 326, 0, 327, 0, 328, 0, + 329, 0, 330, 0, 331, 0, 0, 332, 0, 333, 0, 334, 0, 0, 0, 0, 0, 0, 137, 0, + 0, 138, 0, 0, 139, 0, 0, 140, 0, 0, 141, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 386, 387, 0, 0, 335, + 0, 0, 0, 0, 0, 0, 0, 0, 336, 0, 0, 0, 0, 337, 0, 338, 0, 339, 0, 340, 0, + 341, 0, 342, 0, 343, 0, 344, 0, 345, 0, 346, 0, 347, 0, 348, 0, 0, 349, 0, + 350, 0, 351, 0, 0, 0, 0, 0, 0, 142, 0, 0, 143, 0, 0, 144, 0, 0, 145, 0, 0, + 146, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 352, 353, + 354, 355, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 356, 0, 0 +}; + +static unsigned short *compose_table[256] = { + compose_page0, + compose_page1, + compose_page2, + compose_page3, + compose_page4, + (gushort *) 0, + compose_page6, + (gushort *) 0, + (gushort *) 0, + compose_page9, + (gushort *) 0, + compose_page11, + compose_page12, + compose_page13, + (gushort *) 0, + (gushort *) 0, + compose_page16, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + compose_page30, + compose_page31, + (gushort *) 0, + compose_page33, + compose_page34, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + (gushort *) 0, + compose_page48 +}; + +static gushort compose_first_single[][2] = { + { 0x0338, 0x226e }, + { 0x0338, 0x2260 }, + { 0x0338, 0x226f }, + { 0x0307, 0x1e1e }, + { 0x0302, 0x0134 }, + { 0x0307, 0x1e1f }, + { 0x0304, 0x01de }, + { 0x0301, 0x01fa }, + { 0x0301, 0x1e08 }, + { 0x0301, 0x1e2e }, + { 0x0304, 0x022a }, + { 0x0301, 0x01fe }, + { 0x0304, 0x01df }, + { 0x0301, 0x01fb }, + { 0x0301, 0x1e09 }, + { 0x0301, 0x1e2f }, + { 0x0304, 0x022b }, + { 0x0301, 0x01ff }, + { 0x0307, 0x1e64 }, + { 0x0307, 0x1e65 }, + { 0x0307, 0x1e66 }, + { 0x0307, 0x1e67 }, + { 0x0301, 0x1e78 }, + { 0x0301, 0x1e79 }, + { 0x0308, 0x1e7a }, + { 0x0308, 0x1e7b }, + { 0x0307, 0x1e9b }, + { 0x030c, 0x01ee }, + { 0x0304, 0x01ec }, + { 0x0304, 0x01ed }, + { 0x0304, 0x01e0 }, + { 0x0304, 0x01e1 }, + { 0x0306, 0x1e1c }, + { 0x0306, 0x1e1d }, + { 0x0304, 0x0230 }, + { 0x0304, 0x0231 }, + { 0x030c, 0x01ef }, + { 0x0314, 0x1fec }, + { 0x0345, 0x1fb4 }, + { 0x0345, 0x1fc4 }, + { 0x0345, 0x1ff4 }, + { 0x0308, 0x0407 }, + { 0x0301, 0x0403 }, + { 0x0308, 0x04de }, + { 0x0301, 0x040c }, + { 0x0308, 0x04e6 }, + { 0x0308, 0x04f4 }, + { 0x0308, 0x04f8 }, + { 0x0308, 0x04ec }, + { 0x0301, 0x0453 }, + { 0x0308, 0x04df }, + { 0x0301, 0x045c }, + { 0x0308, 0x04e7 }, + { 0x0308, 0x04f5 }, + { 0x0308, 0x04f9 }, + { 0x0308, 0x04ed }, + { 0x0308, 0x0457 }, + { 0x030f, 0x0476 }, + { 0x030f, 0x0477 }, + { 0x0308, 0x04da }, + { 0x0308, 0x04db }, + { 0x0308, 0x04ea }, + { 0x0308, 0x04eb }, + { 0x0654, 0x0624 }, + { 0x0654, 0x0626 }, + { 0x0654, 0x06c2 }, + { 0x0654, 0x06d3 }, + { 0x0654, 0x06c0 }, + { 0x093c, 0x0929 }, + { 0x093c, 0x0931 }, + { 0x093c, 0x0934 }, + { 0x0bd7, 0x0b94 }, + { 0x0bbe, 0x0bcb }, + { 0x0c56, 0x0c48 }, + { 0x0cd5, 0x0cc0 }, + { 0x0cd5, 0x0ccb }, + { 0x0d3e, 0x0d4b }, + { 0x0dca, 0x0ddd }, + { 0x102e, 0x1026 }, + { 0x0304, 0x1e38 }, + { 0x0304, 0x1e39 }, + { 0x0304, 0x1e5c }, + { 0x0304, 0x1e5d }, + { 0x0307, 0x1e68 }, + { 0x0307, 0x1e69 }, + { 0x0302, 0x1ec6 }, + { 0x0302, 0x1ec7 }, + { 0x0302, 0x1ed8 }, + { 0x0302, 0x1ed9 }, + { 0x0345, 0x1f82 }, + { 0x0345, 0x1f83 }, + { 0x0345, 0x1f84 }, + { 0x0345, 0x1f85 }, + { 0x0345, 0x1f86 }, + { 0x0345, 0x1f87 }, + { 0x0345, 0x1f8a }, + { 0x0345, 0x1f8b }, + { 0x0345, 0x1f8c }, + { 0x0345, 0x1f8d }, + { 0x0345, 0x1f8e }, + { 0x0345, 0x1f8f }, + { 0x0345, 0x1f92 }, + { 0x0345, 0x1f93 }, + { 0x0345, 0x1f94 }, + { 0x0345, 0x1f95 }, + { 0x0345, 0x1f96 }, + { 0x0345, 0x1f97 }, + { 0x0345, 0x1f9a }, + { 0x0345, 0x1f9b }, + { 0x0345, 0x1f9c }, + { 0x0345, 0x1f9d }, + { 0x0345, 0x1f9e }, + { 0x0345, 0x1f9f }, + { 0x0345, 0x1fa2 }, + { 0x0345, 0x1fa3 }, + { 0x0345, 0x1fa4 }, + { 0x0345, 0x1fa5 }, + { 0x0345, 0x1fa6 }, + { 0x0345, 0x1fa7 }, + { 0x0345, 0x1faa }, + { 0x0345, 0x1fab }, + { 0x0345, 0x1fac }, + { 0x0345, 0x1fad }, + { 0x0345, 0x1fae }, + { 0x0345, 0x1faf }, + { 0x0345, 0x1fb2 }, + { 0x0345, 0x1fc2 }, + { 0x0345, 0x1ff2 }, + { 0x0345, 0x1fb7 }, + { 0x0345, 0x1fc7 }, + { 0x0345, 0x1ff7 }, + { 0x0338, 0x219a }, + { 0x0338, 0x219b }, + { 0x0338, 0x21ae }, + { 0x0338, 0x21cd }, + { 0x0338, 0x21cf }, + { 0x0338, 0x21ce }, + { 0x0338, 0x2204 }, + { 0x0338, 0x2209 }, + { 0x0338, 0x220c }, + { 0x0338, 0x2224 }, + { 0x0338, 0x2226 }, + { 0x0338, 0x2241 }, + { 0x0338, 0x2244 }, + { 0x0338, 0x2247 }, + { 0x0338, 0x2249 }, + { 0x0338, 0x226d }, + { 0x0338, 0x2262 }, + { 0x0338, 0x2270 }, + { 0x0338, 0x2271 }, + { 0x0338, 0x2274 }, + { 0x0338, 0x2275 }, + { 0x0338, 0x2278 }, + { 0x0338, 0x2279 }, + { 0x0338, 0x2280 }, + { 0x0338, 0x2281 }, + { 0x0338, 0x22e0 }, + { 0x0338, 0x22e1 }, + { 0x0338, 0x2284 }, + { 0x0338, 0x2285 }, + { 0x0338, 0x2288 }, + { 0x0338, 0x2289 }, + { 0x0338, 0x22e2 }, + { 0x0338, 0x22e3 }, + { 0x0338, 0x22ac }, + { 0x0338, 0x22ad }, + { 0x0338, 0x22ae }, + { 0x0338, 0x22af }, + { 0x0338, 0x22ea }, + { 0x0338, 0x22eb }, + { 0x0338, 0x22ec }, + { 0x0338, 0x22ed }, + { 0x3099, 0x3094 }, + { 0x3099, 0x304c }, + { 0x3099, 0x304e }, + { 0x3099, 0x3050 }, + { 0x3099, 0x3052 }, + { 0x3099, 0x3054 }, + { 0x3099, 0x3056 }, + { 0x3099, 0x3058 }, + { 0x3099, 0x305a }, + { 0x3099, 0x305c }, + { 0x3099, 0x305e }, + { 0x3099, 0x3060 }, + { 0x3099, 0x3062 }, + { 0x3099, 0x3065 }, + { 0x3099, 0x3067 }, + { 0x3099, 0x3069 }, + { 0x3099, 0x309e }, + { 0x3099, 0x30f4 }, + { 0x3099, 0x30ac }, + { 0x3099, 0x30ae }, + { 0x3099, 0x30b0 }, + { 0x3099, 0x30b2 }, + { 0x3099, 0x30b4 }, + { 0x3099, 0x30b6 }, + { 0x3099, 0x30b8 }, + { 0x3099, 0x30ba }, + { 0x3099, 0x30bc }, + { 0x3099, 0x30be }, + { 0x3099, 0x30c0 }, + { 0x3099, 0x30c2 }, + { 0x3099, 0x30c5 }, + { 0x3099, 0x30c7 }, + { 0x3099, 0x30c9 }, + { 0x3099, 0x30f7 }, + { 0x3099, 0x30f8 }, + { 0x3099, 0x30f9 }, + { 0x3099, 0x30fa }, + { 0x3099, 0x30fe } +}; +static gushort compose_second_single[][2] = { + { 0x0627, 0x0622 }, + { 0x0627, 0x0623 }, + { 0x0627, 0x0625 }, + { 0x09c7, 0x09cb }, + { 0x09c7, 0x09cc }, + { 0x0b47, 0x0b4b }, + { 0x0b47, 0x0b48 }, + { 0x0b47, 0x0b4c }, + { 0x0bc6, 0x0bca }, + { 0x0bc6, 0x0bcc }, + { 0x0cc6, 0x0cca }, + { 0x0cc6, 0x0cc7 }, + { 0x0cc6, 0x0cc8 }, + { 0x0d46, 0x0d4a }, + { 0x0d46, 0x0d4c }, + { 0x0dd9, 0x0dda }, + { 0x0dd9, 0x0ddc }, + { 0x0dd9, 0x0dde } +}; +static gushort compose_array[146][31] = { + { 0x00c0, 0x00c1, 0x00c2, 0x00c3, 0x0100, 0x0102, 0x0226, 0x00c4, 0x1ea2, 0x00c5, 0, 0x01cd, 0x0200, 0x0202, 0, 0, 0, 0x1ea0, 0, 0x1e00, 0, 0, 0x0104, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0x1e02, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1e04, 0, 0, 0, 0, 0, 0, 0, 0, 0x1e06, 0, 0, 0, 0 }, + { 0, 0x0106, 0x0108, 0, 0, 0, 0x010a, 0, 0, 0, 0, 0x010c, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x00c7, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0x1e0a, 0, 0, 0, 0, 0x010e, 0, 0, 0, 0, 0, 0x1e0c, 0, 0, 0, 0x1e10, 0, 0x1e12, 0, 0, 0x1e0e, 0, 0, 0, 0 }, + { 0x00c8, 0x00c9, 0x00ca, 0x1ebc, 0x0112, 0x0114, 0x0116, 0x00cb, 0x1eba, 0, 0, 0x011a, 0x0204, 0x0206, 0, 0, 0, 0x1eb8, 0, 0, 0, 0x0228, 0x0118, 0x1e18, 0, 0x1e1a, 0, 0, 0, 0, 0 }, + { 0, 0x01f4, 0x011c, 0, 0x1e20, 0x011e, 0x0120, 0, 0, 0, 0, 0x01e6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x0122, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0x0124, 0, 0, 0, 0x1e22, 0x1e26, 0, 0, 0, 0x021e, 0, 0, 0, 0, 0, 0x1e24, 0, 0, 0, 0x1e28, 0, 0, 0x1e2a, 0, 0, 0, 0, 0, 0 }, + { 0x00cc, 0x00cd, 0x00ce, 0x0128, 0x012a, 0x012c, 0x0130, 0x00cf, 0x1ec8, 0, 0, 0x01cf, 0x0208, 0x020a, 0, 0, 0, 0x1eca, 0, 0, 0, 0, 0x012e, 0, 0, 0x1e2c, 0, 0, 0, 0, 0 }, + { 0, 0x1e30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x01e8, 0, 0, 0, 0, 0, 0x1e32, 0, 0, 0, 0x0136, 0, 0, 0, 0, 0x1e34, 0, 0, 0, 0 }, + { 0, 0x0139, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x013d, 0, 0, 0, 0, 0, 0x1e36, 0, 0, 0, 0x013b, 0, 0x1e3c, 0, 0, 0x1e3a, 0, 0, 0, 0 }, + { 0, 0x1e3e, 0, 0, 0, 0, 0x1e40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1e42, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x01f8, 0x0143, 0, 0x00d1, 0, 0, 0x1e44, 0, 0, 0, 0, 0x0147, 0, 0, 0, 0, 0, 0x1e46, 0, 0, 0, 0x0145, 0, 0x1e4a, 0, 0, 0x1e48, 0, 0, 0, 0 }, + { 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x014c, 0x014e, 0x022e, 0x00d6, 0x1ece, 0, 0x0150, 0x01d1, 0x020c, 0x020e, 0, 0, 0x01a0, 0x1ecc, 0, 0, 0, 0, 0x01ea, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0x1e54, 0, 0, 0, 0, 0x1e56, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0x0154, 0, 0, 0, 0, 0x1e58, 0, 0, 0, 0, 0x0158, 0x0210, 0x0212, 0, 0, 0, 0x1e5a, 0, 0, 0, 0x0156, 0, 0, 0, 0, 0x1e5e, 0, 0, 0, 0 }, + { 0, 0x015a, 0x015c, 0, 0, 0, 0x1e60, 0, 0, 0, 0, 0x0160, 0, 0, 0, 0, 0, 0x1e62, 0, 0, 0x0218, 0x015e, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0x1e6a, 0, 0, 0, 0, 0x0164, 0, 0, 0, 0, 0, 0x1e6c, 0, 0, 0x021a, 0x0162, 0, 0x1e70, 0, 0, 0x1e6e, 0, 0, 0, 0 }, + { 0x00d9, 0x00da, 0x00db, 0x0168, 0x016a, 0x016c, 0, 0x00dc, 0x1ee6, 0x016e, 0x0170, 0x01d3, 0x0214, 0x0216, 0, 0, 0x01af, 0x1ee4, 0x1e72, 0, 0, 0, 0x0172, 0x1e76, 0, 0x1e74, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0x1e7c, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1e7e, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1e80, 0x1e82, 0x0174, 0, 0, 0, 0x1e86, 0x1e84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1e88, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0x1e8a, 0x1e8c, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1ef2, 0x00dd, 0x0176, 0x1ef8, 0x0232, 0, 0x1e8e, 0x0178, 0x1ef6, 0, 0, 0, 0, 0, 0, 0, 0, 0x1ef4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0x0179, 0x1e90, 0, 0, 0, 0x017b, 0, 0, 0, 0, 0x017d, 0, 0, 0, 0, 0, 0x1e92, 0, 0, 0, 0, 0, 0, 0, 0, 0x1e94, 0, 0, 0, 0 }, + { 0x00e0, 0x00e1, 0x00e2, 0x00e3, 0x0101, 0x0103, 0x0227, 0x00e4, 0x1ea3, 0x00e5, 0, 0x01ce, 0x0201, 0x0203, 0, 0, 0, 0x1ea1, 0, 0x1e01, 0, 0, 0x0105, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0x1e03, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1e05, 0, 0, 0, 0, 0, 0, 0, 0, 0x1e07, 0, 0, 0, 0 }, + { 0, 0x0107, 0x0109, 0, 0, 0, 0x010b, 0, 0, 0, 0, 0x010d, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x00e7, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0x1e0b, 0, 0, 0, 0, 0x010f, 0, 0, 0, 0, 0, 0x1e0d, 0, 0, 0, 0x1e11, 0, 0x1e13, 0, 0, 0x1e0f, 0, 0, 0, 0 }, + { 0x00e8, 0x00e9, 0x00ea, 0x1ebd, 0x0113, 0x0115, 0x0117, 0x00eb, 0x1ebb, 0, 0, 0x011b, 0x0205, 0x0207, 0, 0, 0, 0x1eb9, 0, 0, 0, 0x0229, 0x0119, 0x1e19, 0, 0x1e1b, 0, 0, 0, 0, 0 }, + { 0, 0x01f5, 0x011d, 0, 0x1e21, 0x011f, 0x0121, 0, 0, 0, 0, 0x01e7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x0123, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0x0125, 0, 0, 0, 0x1e23, 0x1e27, 0, 0, 0, 0x021f, 0, 0, 0, 0, 0, 0x1e25, 0, 0, 0, 0x1e29, 0, 0, 0x1e2b, 0, 0x1e96, 0, 0, 0, 0 }, + { 0x00ec, 0x00ed, 0x00ee, 0x0129, 0x012b, 0x012d, 0, 0x00ef, 0x1ec9, 0, 0, 0x01d0, 0x0209, 0x020b, 0, 0, 0, 0x1ecb, 0, 0, 0, 0, 0x012f, 0, 0, 0x1e2d, 0, 0, 0, 0, 0 }, + { 0, 0, 0x0135, 0, 0, 0, 0, 0, 0, 0, 0, 0x01f0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0x1e31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x01e9, 0, 0, 0, 0, 0, 0x1e33, 0, 0, 0, 0x0137, 0, 0, 0, 0, 0x1e35, 0, 0, 0, 0 }, + { 0, 0x013a, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x013e, 0, 0, 0, 0, 0, 0x1e37, 0, 0, 0, 0x013c, 0, 0x1e3d, 0, 0, 0x1e3b, 0, 0, 0, 0 }, + { 0, 0x1e3f, 0, 0, 0, 0, 0x1e41, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1e43, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x01f9, 0x0144, 0, 0x00f1, 0, 0, 0x1e45, 0, 0, 0, 0, 0x0148, 0, 0, 0, 0, 0, 0x1e47, 0, 0, 0, 0x0146, 0, 0x1e4b, 0, 0, 0x1e49, 0, 0, 0, 0 }, + { 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x014d, 0x014f, 0x022f, 0x00f6, 0x1ecf, 0, 0x0151, 0x01d2, 0x020d, 0x020f, 0, 0, 0x01a1, 0x1ecd, 0, 0, 0, 0, 0x01eb, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0x1e55, 0, 0, 0, 0, 0x1e57, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0x0155, 0, 0, 0, 0, 0x1e59, 0, 0, 0, 0, 0x0159, 0x0211, 0x0213, 0, 0, 0, 0x1e5b, 0, 0, 0, 0x0157, 0, 0, 0, 0, 0x1e5f, 0, 0, 0, 0 }, + { 0, 0x015b, 0x015d, 0, 0, 0, 0x1e61, 0, 0, 0, 0, 0x0161, 0, 0, 0, 0, 0, 0x1e63, 0, 0, 0x0219, 0x015f, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0x1e6b, 0x1e97, 0, 0, 0, 0x0165, 0, 0, 0, 0, 0, 0x1e6d, 0, 0, 0x021b, 0x0163, 0, 0x1e71, 0, 0, 0x1e6f, 0, 0, 0, 0 }, + { 0x00f9, 0x00fa, 0x00fb, 0x0169, 0x016b, 0x016d, 0, 0x00fc, 0x1ee7, 0x016f, 0x0171, 0x01d4, 0x0215, 0x0217, 0, 0, 0x01b0, 0x1ee5, 0x1e73, 0, 0, 0, 0x0173, 0x1e77, 0, 0x1e75, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0x1e7d, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1e7f, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1e81, 0x1e83, 0x0175, 0, 0, 0, 0x1e87, 0x1e85, 0, 0x1e98, 0, 0, 0, 0, 0, 0, 0, 0x1e89, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0x1e8b, 0x1e8d, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1ef3, 0x00fd, 0x0177, 0x1ef9, 0x0233, 0, 0x1e8f, 0x00ff, 0x1ef7, 0x1e99, 0, 0, 0, 0, 0, 0, 0, 0x1ef5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0x017a, 0x1e91, 0, 0, 0, 0x017c, 0, 0, 0, 0, 0x017e, 0, 0, 0, 0, 0, 0x1e93, 0, 0, 0, 0, 0, 0, 0, 0, 0x1e95, 0, 0, 0, 0 }, + { 0x1fed, 0x0385, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1fc1, 0, 0, 0 }, + { 0x1ea6, 0x1ea4, 0, 0x1eaa, 0, 0, 0, 0, 0x1ea8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0x01fc, 0, 0, 0x01e2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1ec0, 0x1ebe, 0, 0x1ec4, 0, 0, 0, 0, 0x1ec2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1ed2, 0x1ed0, 0, 0x1ed6, 0, 0, 0, 0, 0x1ed4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0x1e4c, 0, 0, 0x022c, 0, 0, 0x1e4e, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x01db, 0x01d7, 0, 0, 0x01d5, 0, 0, 0, 0, 0, 0, 0x01d9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1ea7, 0x1ea5, 0, 0x1eab, 0, 0, 0, 0, 0x1ea9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0x01fd, 0, 0, 0x01e3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1ec1, 0x1ebf, 0, 0x1ec5, 0, 0, 0, 0, 0x1ec3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1ed3, 0x1ed1, 0, 0x1ed7, 0, 0, 0, 0, 0x1ed5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0x1e4d, 0, 0, 0x022d, 0, 0, 0x1e4f, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x01dc, 0x01d8, 0, 0, 0x01d6, 0, 0, 0, 0, 0, 0, 0x01da, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1eb0, 0x1eae, 0, 0x1eb4, 0, 0, 0, 0, 0x1eb2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1eb1, 0x1eaf, 0, 0x1eb5, 0, 0, 0, 0, 0x1eb3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1e14, 0x1e16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1e15, 0x1e17, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1e50, 0x1e52, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1e51, 0x1e53, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1edc, 0x1eda, 0, 0x1ee0, 0, 0, 0, 0, 0x1ede, 0, 0, 0, 0, 0, 0, 0, 0, 0x1ee2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1edd, 0x1edb, 0, 0x1ee1, 0, 0, 0, 0, 0x1edf, 0, 0, 0, 0, 0, 0, 0, 0, 0x1ee3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1eea, 0x1ee8, 0, 0x1eee, 0, 0, 0, 0, 0x1eec, 0, 0, 0, 0, 0, 0, 0, 0, 0x1ef0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1eeb, 0x1ee9, 0, 0x1eef, 0, 0, 0, 0, 0x1eed, 0, 0, 0, 0, 0, 0, 0, 0, 0x1ef1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1fba, 0x0386, 0, 0, 0x1fb9, 0x1fb8, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f08, 0x1f09, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1fbc, 0, 0 }, + { 0x1fc8, 0x0388, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f18, 0x1f19, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1fca, 0x0389, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f28, 0x1f29, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1fcc, 0, 0 }, + { 0x1fda, 0x038a, 0, 0, 0x1fd9, 0x1fd8, 0, 0x03aa, 0, 0, 0, 0, 0, 0, 0x1f38, 0x1f39, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1ff8, 0x038c, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f48, 0x1f49, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1fea, 0x038e, 0, 0, 0x1fe9, 0x1fe8, 0, 0x03ab, 0, 0, 0, 0, 0, 0, 0, 0x1f59, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1ffa, 0x038f, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f68, 0x1f69, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1ffc, 0, 0 }, + { 0x1f70, 0x03ac, 0, 0, 0x1fb1, 0x1fb0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f00, 0x1f01, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1fb6, 0x1fb3, 0, 0 }, + { 0x1f72, 0x03ad, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f10, 0x1f11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1f74, 0x03ae, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f20, 0x1f21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1fc6, 0x1fc3, 0, 0 }, + { 0x1f76, 0x03af, 0, 0, 0x1fd1, 0x1fd0, 0, 0x03ca, 0, 0, 0, 0, 0, 0, 0x1f30, 0x1f31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1fd6, 0, 0, 0 }, + { 0x1f78, 0x03cc, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f40, 0x1f41, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1fe4, 0x1fe5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1f7a, 0x03cd, 0, 0, 0x1fe1, 0x1fe0, 0, 0x03cb, 0, 0, 0, 0, 0, 0, 0x1f50, 0x1f51, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1fe6, 0, 0, 0 }, + { 0x1f7c, 0x03ce, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f60, 0x1f61, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1ff6, 0x1ff3, 0, 0 }, + { 0x1fd2, 0x0390, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1fd7, 0, 0, 0 }, + { 0x1fe2, 0x03b0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1fe7, 0, 0, 0 }, + { 0, 0x03d3, 0, 0, 0, 0, 0, 0x03d4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0x04d0, 0, 0x04d2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x0400, 0, 0, 0, 0, 0x04d6, 0, 0x0401, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0x04c1, 0, 0x04dc, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x040d, 0, 0, 0, 0x04e2, 0x0419, 0, 0x04e4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0x04ee, 0x040e, 0, 0x04f0, 0, 0, 0x04f2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0x04d1, 0, 0x04d3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x0450, 0, 0, 0, 0, 0x04d7, 0, 0x0451, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0x04c2, 0, 0x04dd, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x045d, 0, 0, 0, 0x04e3, 0x0439, 0, 0x04e5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0x04ef, 0x045e, 0, 0x04f1, 0, 0, 0x04f3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0x1eac, 0, 0, 0x1eb6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0, 0, 0x1ead, 0, 0, 0x1eb7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1f02, 0x1f04, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f06, 0x1f80, 0, 0 }, + { 0x1f03, 0x1f05, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f07, 0x1f81, 0, 0 }, + { 0x1f0a, 0x1f0c, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f0e, 0x1f88, 0, 0 }, + { 0x1f0b, 0x1f0d, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f0f, 0x1f89, 0, 0 }, + { 0x1f12, 0x1f14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1f13, 0x1f15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1f1a, 0x1f1c, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1f1b, 0x1f1d, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1f22, 0x1f24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f26, 0x1f90, 0, 0 }, + { 0x1f23, 0x1f25, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f27, 0x1f91, 0, 0 }, + { 0x1f2a, 0x1f2c, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f2e, 0x1f98, 0, 0 }, + { 0x1f2b, 0x1f2d, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f2f, 0x1f99, 0, 0 }, + { 0x1f32, 0x1f34, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f36, 0, 0, 0 }, + { 0x1f33, 0x1f35, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f37, 0, 0, 0 }, + { 0x1f3a, 0x1f3c, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f3e, 0, 0, 0 }, + { 0x1f3b, 0x1f3d, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f3f, 0, 0, 0 }, + { 0x1f42, 0x1f44, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1f43, 0x1f45, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1f4a, 0x1f4c, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1f4b, 0x1f4d, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }, + { 0x1f52, 0x1f54, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f56, 0, 0, 0 }, + { 0x1f53, 0x1f55, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f57, 0, 0, 0 }, + { 0x1f5b, 0x1f5d, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f5f, 0, 0, 0 }, + { 0x1f62, 0x1f64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f66, 0x1fa0, 0, 0 }, + { 0x1f63, 0x1f65, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f67, 0x1fa1, 0, 0 }, + { 0x1f6a, 0x1f6c, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f6e, 0x1fa8, 0, 0 }, + { 0x1f6b, 0x1f6d, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1f6f, 0x1fa9, 0, 0 }, + { 0x1fcd, 0x1fce, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1fcf, 0, 0, 0 }, + { 0x1fdd, 0x1fde, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x1fdf, 0, 0, 0 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x3070, 0x3071 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x3073, 0x3074 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x3076, 0x3077 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x3079, 0x307a }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x307c, 0x307d }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x30d0, 0x30d1 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x30d3, 0x30d4 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x30d6, 0x30d7 }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x30d9, 0x30da }, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x30dc, 0x30dd } +}; diff --git a/graf2d/win32gdk/gdk/src/glib/gunidecomp.c b/graf2d/win32gdk/gdk/src/glib/gunidecomp.c new file mode 100644 index 0000000000000..47590eeee5acf --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gunidecomp.c @@ -0,0 +1,413 @@ +/* decomp.c - Character decomposition. + * + * Copyright (C) 1999, 2000 Tom Tromey + * Copyright 2000 Red Hat, Inc. + * + * The Gnome Library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2 of the + * License, or (at your option) any later version. + * + * The Gnome Library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with the Gnome Library; see the file COPYING.LIB. If not, + * write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "glib.h" +#include "gunidecomp.h" +#include "gunicomp.h" + +#include <config.h> + +#include <stdlib.h> + +/* We cheat a bit and cast type values to (char *). We detect these + using the &0xff trick. */ +#define CC(Page, Char) \ + ((((GPOINTER_TO_INT(combining_class_table[Page])) & 0xff) \ + == GPOINTER_TO_INT(combining_class_table[Page])) \ + ? GPOINTER_TO_INT(combining_class_table[Page]) \ + : (combining_class_table[Page][Char])) + +#define COMBINING_CLASS(Char) \ + (((Char) > (G_UNICODE_LAST_CHAR)) ? 0 : CC((Char) >> 8, (Char) & 0xff)) + +/** + * g_unicode_canonical_ordering: + * @string: a UCS-4 encoded string. + * @len: the maximum length of @string to use. + * + * Computes the canonical ordering of a string in-place. + * This rearranges decomposed characters in the string + * according to their combining classes. See the Unicode + * manual for more information. + **/ +void +g_unicode_canonical_ordering (gunichar *string, + gsize len) +{ + gsize i; + int swap = 1; + + while (swap) + { + int last; + swap = 0; + last = COMBINING_CLASS (string[0]); + for (i = 0; i < len - 1; ++i) + { + int next = COMBINING_CLASS (string[i + 1]); + if (next != 0 && last > next) + { + gsize j; + /* Percolate item leftward through string. */ + for (j = i; j > 0; --j) + { + gunichar t; + if (COMBINING_CLASS (string[j]) <= next) + break; + t = string[j + 1]; + string[j + 1] = string[j]; + string[j] = t; + swap = 1; + } + /* We're re-entering the loop looking at the old + character again. */ + next = last; + } + last = next; + } + } +} + +static guchar * +find_decomposition (gunichar ch, + gboolean compat) +{ + int start = 0; + int end = G_N_ELEMENTS (decomp_table); + + if (ch >= decomp_table[start].ch && + ch <= decomp_table[end - 1].ch) + { + while (TRUE) + { + int half = (start + end) / 2; + if (ch == decomp_table[half].ch) + { + int offset; + + if (compat) + { + offset = decomp_table[half].compat_offset; + if (offset == 0xff) + offset = decomp_table[half].canon_offset; + } + else + { + offset = decomp_table[half].canon_offset; + if (offset == 0xff) + return NULL; + } + + return decomp_table[half].expansion + offset; + } + else if (half == start) + break; + else if (ch > decomp_table[half].ch) + start = half; + else + end = half; + } + } + + return NULL; +} + +/** + * g_unicode_canonical_decomposition: + * @ch: a Unicode character. + * @result_len: location to store the length of the return value. + * + * Computes the canonical decomposition of a Unicode character. + * + * Return value: a newly allocated string of Unicode characters. + * @result_len is set to the resulting length of the string. + **/ +gunichar * +g_unicode_canonical_decomposition (gunichar ch, + gsize *result_len) +{ + guchar *decomp = find_decomposition (ch, FALSE); + gunichar *r; + + if (decomp) + { + /* Found it. */ + int i, len; + /* We store as a double-nul terminated string. */ + for (len = 0; (decomp[len] || decomp[len + 1]); + len += 2) + ; + + /* We've counted twice as many bytes as there are + characters. */ + *result_len = len / 2; + r = malloc (len / 2 * sizeof (gunichar)); + + for (i = 0; i < len; i += 2) + { + r[i / 2] = (decomp[i] << 8 | decomp[i + 1]); + } + } + else + { + /* Not in our table. */ + r = malloc (sizeof (gunichar)); + *r = ch; + *result_len = 1; + } + + /* Supposedly following the Unicode 2.1.9 table means that the + decompositions come out in canonical order. I haven't tested + this, but we rely on it here. */ + return r; +} + +#define CI(Page, Char) \ + ((((GPOINTER_TO_INT(compose_table[Page])) & 0xff) \ + == GPOINTER_TO_INT(compose_table[Page])) \ + ? GPOINTER_TO_INT(compose_table[Page]) \ + : (compose_table[Page][Char])) + +#define COMPOSE_INDEX(Char) \ + (((Char) > (G_UNICODE_LAST_CHAR)) ? 0 : CI((Char) >> 8, (Char) & 0xff)) + +gboolean +combine (gunichar a, + gunichar b, + gunichar *result) +{ + gushort index_a, index_b; + + index_a = COMPOSE_INDEX(a); + if (index_a >= COMPOSE_FIRST_SINGLE_START && index_a < COMPOSE_SECOND_START) + { + if (b == compose_first_single[index_a - COMPOSE_FIRST_SINGLE_START][0]) + { + *result = compose_first_single[index_a - COMPOSE_FIRST_SINGLE_START][1]; + return TRUE; + } + else + return FALSE; + } + + index_b = COMPOSE_INDEX(b); + if (index_b >= COMPOSE_SECOND_SINGLE_START) + { + if (a == compose_second_single[index_b - COMPOSE_SECOND_SINGLE_START][0]) + { + *result = compose_second_single[index_b - COMPOSE_SECOND_SINGLE_START][1]; + return TRUE; + } + else + return FALSE; + } + + if (index_a >= COMPOSE_FIRST_START && index_a < COMPOSE_FIRST_SINGLE_START && + index_b >= COMPOSE_SECOND_START && index_a < COMPOSE_SECOND_SINGLE_START) + { + gunichar res = compose_array[index_a - COMPOSE_FIRST_START][index_b - COMPOSE_SECOND_START]; + + if (res) + { + *result = res; + return TRUE; + } + } + + return FALSE; +} + +gunichar * +_g_utf8_normalize_wc (const gchar *str, + gssize max_len, + GNormalizeMode mode) +{ + gsize n_wc; + gunichar *wc_buffer; + const char *p; + gsize last_start; + gboolean do_compat = (mode == G_NORMALIZE_NFKC || + mode == G_NORMALIZE_NFKD); + gboolean do_compose = (mode == G_NORMALIZE_NFC || + mode == G_NORMALIZE_NFKC); + + n_wc = 0; + p = str; + while ((max_len < 0 || p < str + max_len) && *p) + { + gunichar wc = g_utf8_get_char (p); + + guchar *decomp = find_decomposition (wc, do_compat); + + if (decomp) + { + int len; + /* We store as a double-nul terminated string. */ + for (len = 0; (decomp[len] || decomp[len + 1]); + len += 2) + ; + n_wc += len / 2; + } + else + n_wc++; + + p = g_utf8_next_char (p); + } + + wc_buffer = g_new (gunichar, n_wc + 1); + + last_start = 0; + n_wc = 0; + p = str; + while ((max_len < 0 || p < str + max_len) && *p) + { + gunichar wc = g_utf8_get_char (p); + guchar *decomp; + int cc; + gsize old_n_wc = n_wc; + + decomp = find_decomposition (wc, do_compat); + + if (decomp) + { + int len; + /* We store as a double-nul terminated string. */ + for (len = 0; (decomp[len] || decomp[len + 1]); + len += 2) + wc_buffer[n_wc++] = (decomp[len] << 8 | decomp[len + 1]); + } + else + wc_buffer[n_wc++] = wc; + + if (n_wc > 0) + { + cc = COMBINING_CLASS (wc_buffer[old_n_wc]); + + if (cc == 0) + { + g_unicode_canonical_ordering (wc_buffer + last_start, n_wc - last_start); + last_start = old_n_wc; + } + } + + p = g_utf8_next_char (p); + } + + if (n_wc > 0) + { + g_unicode_canonical_ordering (wc_buffer + last_start, n_wc - last_start); + last_start = n_wc; + } + + wc_buffer[n_wc] = 0; + + /* All decomposed and reordered */ + + + if (do_compose && n_wc > 0) + { + gsize i, j; + int last_cc = 0; + last_start = 0; + + for (i = 0; i < n_wc; i++) + { + int cc = COMBINING_CLASS (wc_buffer[i]); + + if (i > 0 && + (last_cc == 0 || last_cc != cc) && + combine (wc_buffer[last_start], wc_buffer[i], + &wc_buffer[last_start])) + { + for (j = i + 1; j < n_wc; j++) + wc_buffer[j-1] = wc_buffer[j]; + n_wc--; + i--; + + if (i == last_start) + last_cc = 0; + else + last_cc = COMBINING_CLASS (wc_buffer[i-1]); + + continue; + } + + if (cc == 0) + last_start = i; + + last_cc = cc; + } + } + + wc_buffer[n_wc] = 0; + + return wc_buffer; +} + +/** + * g_utf8_normalize: + * @str: a UTF-8 encoded string. + * @len: length of @str, in bytes, or -1 if @str is nul-terminated. + * @mode: the type of normalization to perform. + * + * Converts a string into canonical form, standardizing + * such issues as whether a character with an accent + * is represented as a base character and combining + * accent or as a single precomposed character. You + * should generally call g_utf8_normalize() before + * comparing two Unicode strings. + * + * The normalization mode %G_NORMALIZE_DEFAULT only + * standardizes differences that do not affect the + * text content, such as the above-mentioned accent + * representation. %G_NORMALIZE_ALL also standardizes + * the "compatibility" characters in Unicode, such + * as SUPERSCRIPT THREE to the standard forms + * (in this case DIGIT THREE). Formatting information + * may be lost but for most text operations such + * characters should be considered the same. + * For example, g_utf8_collate() normalizes + * with %G_NORMALIZE_ALL as its first step. + * + * %G_NORMALIZE_DEFAULT_COMPOSE and %G_NORMALIZE_ALL_COMPOSE + * are like %G_NORMALIZE_DEFAULT and %G_NORMALIZE_ALL, + * but returned a result with composed forms rather + * than a maximally decomposed form. This is often + * useful if you intend to convert the string to + * a legacy encoding or pass it to a system with + * less capable Unicode handling. + * + * Return value: a newly allocated string, that is the + * normalized form of @str. + **/ +gchar * +g_utf8_normalize (const gchar *str, + gssize len, + GNormalizeMode mode) +{ + gunichar *result_wc = _g_utf8_normalize_wc (str, len, mode); + gchar *result; + + result = g_ucs4_to_utf8 (result_wc, -1, NULL, NULL, NULL); + g_free (result_wc); + + return result; +} diff --git a/graf2d/win32gdk/gdk/src/glib/gunidecomp.h b/graf2d/win32gdk/gdk/src/glib/gunidecomp.h index b497759791851..983ee553fdfef 100644 --- a/graf2d/win32gdk/gdk/src/glib/gunidecomp.h +++ b/graf2d/win32gdk/gdk/src/glib/gunidecomp.h @@ -536,1322 +536,3498 @@ static unsigned char *combining_class_table[256] = { typedef struct { unsigned short ch; + unsigned char canon_offset; + unsigned char compat_offset; unsigned char *expansion; } decomposition; static decomposition decomp_table[] = { - { 0x00c0, "\x00\x41\x03\x00\0" }, - { 0x00c1, "\x00\x41\x03\x01\0" }, - { 0x00c2, "\x00\x41\x03\x02\0" }, - { 0x00c3, "\x00\x41\x03\x03\0" }, - { 0x00c4, "\x00\x41\x03\x08\0" }, - { 0x00c5, "\x00\x41\x03\x0a\0" }, - { 0x00c7, "\x00\x43\x03\x27\0" }, - { 0x00c8, "\x00\x45\x03\x00\0" }, - { 0x00c9, "\x00\x45\x03\x01\0" }, - { 0x00ca, "\x00\x45\x03\x02\0" }, - { 0x00cb, "\x00\x45\x03\x08\0" }, - { 0x00cc, "\x00\x49\x03\x00\0" }, - { 0x00cd, "\x00\x49\x03\x01\0" }, - { 0x00ce, "\x00\x49\x03\x02\0" }, - { 0x00cf, "\x00\x49\x03\x08\0" }, - { 0x00d1, "\x00\x4e\x03\x03\0" }, - { 0x00d2, "\x00\x4f\x03\x00\0" }, - { 0x00d3, "\x00\x4f\x03\x01\0" }, - { 0x00d4, "\x00\x4f\x03\x02\0" }, - { 0x00d5, "\x00\x4f\x03\x03\0" }, - { 0x00d6, "\x00\x4f\x03\x08\0" }, - { 0x00d9, "\x00\x55\x03\x00\0" }, - { 0x00da, "\x00\x55\x03\x01\0" }, - { 0x00db, "\x00\x55\x03\x02\0" }, - { 0x00dc, "\x00\x55\x03\x08\0" }, - { 0x00dd, "\x00\x59\x03\x01\0" }, - { 0x00e0, "\x00\x61\x03\x00\0" }, - { 0x00e1, "\x00\x61\x03\x01\0" }, - { 0x00e2, "\x00\x61\x03\x02\0" }, - { 0x00e3, "\x00\x61\x03\x03\0" }, - { 0x00e4, "\x00\x61\x03\x08\0" }, - { 0x00e5, "\x00\x61\x03\x0a\0" }, - { 0x00e7, "\x00\x63\x03\x27\0" }, - { 0x00e8, "\x00\x65\x03\x00\0" }, - { 0x00e9, "\x00\x65\x03\x01\0" }, - { 0x00ea, "\x00\x65\x03\x02\0" }, - { 0x00eb, "\x00\x65\x03\x08\0" }, - { 0x00ec, "\x00\x69\x03\x00\0" }, - { 0x00ed, "\x00\x69\x03\x01\0" }, - { 0x00ee, "\x00\x69\x03\x02\0" }, - { 0x00ef, "\x00\x69\x03\x08\0" }, - { 0x00f1, "\x00\x6e\x03\x03\0" }, - { 0x00f2, "\x00\x6f\x03\x00\0" }, - { 0x00f3, "\x00\x6f\x03\x01\0" }, - { 0x00f4, "\x00\x6f\x03\x02\0" }, - { 0x00f5, "\x00\x6f\x03\x03\0" }, - { 0x00f6, "\x00\x6f\x03\x08\0" }, - { 0x00f9, "\x00\x75\x03\x00\0" }, - { 0x00fa, "\x00\x75\x03\x01\0" }, - { 0x00fb, "\x00\x75\x03\x02\0" }, - { 0x00fc, "\x00\x75\x03\x08\0" }, - { 0x00fd, "\x00\x79\x03\x01\0" }, - { 0x00ff, "\x00\x79\x03\x08\0" }, - { 0x0100, "\x00\x41\x03\x04\0" }, - { 0x0101, "\x00\x61\x03\x04\0" }, - { 0x0102, "\x00\x41\x03\x06\0" }, - { 0x0103, "\x00\x61\x03\x06\0" }, - { 0x0104, "\x00\x41\x03\x28\0" }, - { 0x0105, "\x00\x61\x03\x28\0" }, - { 0x0106, "\x00\x43\x03\x01\0" }, - { 0x0107, "\x00\x63\x03\x01\0" }, - { 0x0108, "\x00\x43\x03\x02\0" }, - { 0x0109, "\x00\x63\x03\x02\0" }, - { 0x010a, "\x00\x43\x03\x07\0" }, - { 0x010b, "\x00\x63\x03\x07\0" }, - { 0x010c, "\x00\x43\x03\x0c\0" }, - { 0x010d, "\x00\x63\x03\x0c\0" }, - { 0x010e, "\x00\x44\x03\x0c\0" }, - { 0x010f, "\x00\x64\x03\x0c\0" }, - { 0x0112, "\x00\x45\x03\x04\0" }, - { 0x0113, "\x00\x65\x03\x04\0" }, - { 0x0114, "\x00\x45\x03\x06\0" }, - { 0x0115, "\x00\x65\x03\x06\0" }, - { 0x0116, "\x00\x45\x03\x07\0" }, - { 0x0117, "\x00\x65\x03\x07\0" }, - { 0x0118, "\x00\x45\x03\x28\0" }, - { 0x0119, "\x00\x65\x03\x28\0" }, - { 0x011a, "\x00\x45\x03\x0c\0" }, - { 0x011b, "\x00\x65\x03\x0c\0" }, - { 0x011c, "\x00\x47\x03\x02\0" }, - { 0x011d, "\x00\x67\x03\x02\0" }, - { 0x011e, "\x00\x47\x03\x06\0" }, - { 0x011f, "\x00\x67\x03\x06\0" }, - { 0x0120, "\x00\x47\x03\x07\0" }, - { 0x0121, "\x00\x67\x03\x07\0" }, - { 0x0122, "\x00\x47\x03\x27\0" }, - { 0x0123, "\x00\x67\x03\x27\0" }, - { 0x0124, "\x00\x48\x03\x02\0" }, - { 0x0125, "\x00\x68\x03\x02\0" }, - { 0x0128, "\x00\x49\x03\x03\0" }, - { 0x0129, "\x00\x69\x03\x03\0" }, - { 0x012a, "\x00\x49\x03\x04\0" }, - { 0x012b, "\x00\x69\x03\x04\0" }, - { 0x012c, "\x00\x49\x03\x06\0" }, - { 0x012d, "\x00\x69\x03\x06\0" }, - { 0x012e, "\x00\x49\x03\x28\0" }, - { 0x012f, "\x00\x69\x03\x28\0" }, - { 0x0130, "\x00\x49\x03\x07\0" }, - { 0x0134, "\x00\x4a\x03\x02\0" }, - { 0x0135, "\x00\x6a\x03\x02\0" }, - { 0x0136, "\x00\x4b\x03\x27\0" }, - { 0x0137, "\x00\x6b\x03\x27\0" }, - { 0x0139, "\x00\x4c\x03\x01\0" }, - { 0x013a, "\x00\x6c\x03\x01\0" }, - { 0x013b, "\x00\x4c\x03\x27\0" }, - { 0x013c, "\x00\x6c\x03\x27\0" }, - { 0x013d, "\x00\x4c\x03\x0c\0" }, - { 0x013e, "\x00\x6c\x03\x0c\0" }, - { 0x0143, "\x00\x4e\x03\x01\0" }, - { 0x0144, "\x00\x6e\x03\x01\0" }, - { 0x0145, "\x00\x4e\x03\x27\0" }, - { 0x0146, "\x00\x6e\x03\x27\0" }, - { 0x0147, "\x00\x4e\x03\x0c\0" }, - { 0x0148, "\x00\x6e\x03\x0c\0" }, - { 0x014c, "\x00\x4f\x03\x04\0" }, - { 0x014d, "\x00\x6f\x03\x04\0" }, - { 0x014e, "\x00\x4f\x03\x06\0" }, - { 0x014f, "\x00\x6f\x03\x06\0" }, - { 0x0150, "\x00\x4f\x03\x0b\0" }, - { 0x0151, "\x00\x6f\x03\x0b\0" }, - { 0x0154, "\x00\x52\x03\x01\0" }, - { 0x0155, "\x00\x72\x03\x01\0" }, - { 0x0156, "\x00\x52\x03\x27\0" }, - { 0x0157, "\x00\x72\x03\x27\0" }, - { 0x0158, "\x00\x52\x03\x0c\0" }, - { 0x0159, "\x00\x72\x03\x0c\0" }, - { 0x015a, "\x00\x53\x03\x01\0" }, - { 0x015b, "\x00\x73\x03\x01\0" }, - { 0x015c, "\x00\x53\x03\x02\0" }, - { 0x015d, "\x00\x73\x03\x02\0" }, - { 0x015e, "\x00\x53\x03\x27\0" }, - { 0x015f, "\x00\x73\x03\x27\0" }, - { 0x0160, "\x00\x53\x03\x0c\0" }, - { 0x0161, "\x00\x73\x03\x0c\0" }, - { 0x0162, "\x00\x54\x03\x27\0" }, - { 0x0163, "\x00\x74\x03\x27\0" }, - { 0x0164, "\x00\x54\x03\x0c\0" }, - { 0x0165, "\x00\x74\x03\x0c\0" }, - { 0x0168, "\x00\x55\x03\x03\0" }, - { 0x0169, "\x00\x75\x03\x03\0" }, - { 0x016a, "\x00\x55\x03\x04\0" }, - { 0x016b, "\x00\x75\x03\x04\0" }, - { 0x016c, "\x00\x55\x03\x06\0" }, - { 0x016d, "\x00\x75\x03\x06\0" }, - { 0x016e, "\x00\x55\x03\x0a\0" }, - { 0x016f, "\x00\x75\x03\x0a\0" }, - { 0x0170, "\x00\x55\x03\x0b\0" }, - { 0x0171, "\x00\x75\x03\x0b\0" }, - { 0x0172, "\x00\x55\x03\x28\0" }, - { 0x0173, "\x00\x75\x03\x28\0" }, - { 0x0174, "\x00\x57\x03\x02\0" }, - { 0x0175, "\x00\x77\x03\x02\0" }, - { 0x0176, "\x00\x59\x03\x02\0" }, - { 0x0177, "\x00\x79\x03\x02\0" }, - { 0x0178, "\x00\x59\x03\x08\0" }, - { 0x0179, "\x00\x5a\x03\x01\0" }, - { 0x017a, "\x00\x7a\x03\x01\0" }, - { 0x017b, "\x00\x5a\x03\x07\0" }, - { 0x017c, "\x00\x7a\x03\x07\0" }, - { 0x017d, "\x00\x5a\x03\x0c\0" }, - { 0x017e, "\x00\x7a\x03\x0c\0" }, - { 0x01a0, "\x00\x4f\x03\x1b\0" }, - { 0x01a1, "\x00\x6f\x03\x1b\0" }, - { 0x01af, "\x00\x55\x03\x1b\0" }, - { 0x01b0, "\x00\x75\x03\x1b\0" }, - { 0x01cd, "\x00\x41\x03\x0c\0" }, - { 0x01ce, "\x00\x61\x03\x0c\0" }, - { 0x01cf, "\x00\x49\x03\x0c\0" }, - { 0x01d0, "\x00\x69\x03\x0c\0" }, - { 0x01d1, "\x00\x4f\x03\x0c\0" }, - { 0x01d2, "\x00\x6f\x03\x0c\0" }, - { 0x01d3, "\x00\x55\x03\x0c\0" }, - { 0x01d4, "\x00\x75\x03\x0c\0" }, - { 0x01d5, "\x00\x55\x03\x08\x03\x04\0" }, - { 0x01d6, "\x00\x75\x03\x08\x03\x04\0" }, - { 0x01d7, "\x00\x55\x03\x08\x03\x01\0" }, - { 0x01d8, "\x00\x75\x03\x08\x03\x01\0" }, - { 0x01d9, "\x00\x55\x03\x08\x03\x0c\0" }, - { 0x01da, "\x00\x75\x03\x08\x03\x0c\0" }, - { 0x01db, "\x00\x55\x03\x08\x03\x00\0" }, - { 0x01dc, "\x00\x75\x03\x08\x03\x00\0" }, - { 0x01de, "\x00\x41\x03\x08\x03\x04\0" }, - { 0x01df, "\x00\x61\x03\x08\x03\x04\0" }, - { 0x01e0, "\x00\x41\x03\x07\x03\x04\0" }, - { 0x01e1, "\x00\x61\x03\x07\x03\x04\0" }, - { 0x01e2, "\x00\xc6\x03\x04\0" }, - { 0x01e3, "\x00\xe6\x03\x04\0" }, - { 0x01e6, "\x00\x47\x03\x0c\0" }, - { 0x01e7, "\x00\x67\x03\x0c\0" }, - { 0x01e8, "\x00\x4b\x03\x0c\0" }, - { 0x01e9, "\x00\x6b\x03\x0c\0" }, - { 0x01ea, "\x00\x4f\x03\x28\0" }, - { 0x01eb, "\x00\x6f\x03\x28\0" }, - { 0x01ec, "\x00\x4f\x03\x28\x03\x04\0" }, - { 0x01ed, "\x00\x6f\x03\x28\x03\x04\0" }, - { 0x01ee, "\x01\xb7\x03\x0c\0" }, - { 0x01ef, "\x02\x92\x03\x0c\0" }, - { 0x01f0, "\x00\x6a\x03\x0c\0" }, - { 0x01f4, "\x00\x47\x03\x01\0" }, - { 0x01f5, "\x00\x67\x03\x01\0" }, - { 0x01f8, "\x00\x4e\x03\x00\0" }, - { 0x01f9, "\x00\x6e\x03\x00\0" }, - { 0x01fa, "\x00\x41\x03\x0a\x03\x01\0" }, - { 0x01fb, "\x00\x61\x03\x0a\x03\x01\0" }, - { 0x01fc, "\x00\xc6\x03\x01\0" }, - { 0x01fd, "\x00\xe6\x03\x01\0" }, - { 0x01fe, "\x00\xd8\x03\x01\0" }, - { 0x01ff, "\x00\xf8\x03\x01\0" }, - { 0x0200, "\x00\x41\x03\x0f\0" }, - { 0x0201, "\x00\x61\x03\x0f\0" }, - { 0x0202, "\x00\x41\x03\x11\0" }, - { 0x0203, "\x00\x61\x03\x11\0" }, - { 0x0204, "\x00\x45\x03\x0f\0" }, - { 0x0205, "\x00\x65\x03\x0f\0" }, - { 0x0206, "\x00\x45\x03\x11\0" }, - { 0x0207, "\x00\x65\x03\x11\0" }, - { 0x0208, "\x00\x49\x03\x0f\0" }, - { 0x0209, "\x00\x69\x03\x0f\0" }, - { 0x020a, "\x00\x49\x03\x11\0" }, - { 0x020b, "\x00\x69\x03\x11\0" }, - { 0x020c, "\x00\x4f\x03\x0f\0" }, - { 0x020d, "\x00\x6f\x03\x0f\0" }, - { 0x020e, "\x00\x4f\x03\x11\0" }, - { 0x020f, "\x00\x6f\x03\x11\0" }, - { 0x0210, "\x00\x52\x03\x0f\0" }, - { 0x0211, "\x00\x72\x03\x0f\0" }, - { 0x0212, "\x00\x52\x03\x11\0" }, - { 0x0213, "\x00\x72\x03\x11\0" }, - { 0x0214, "\x00\x55\x03\x0f\0" }, - { 0x0215, "\x00\x75\x03\x0f\0" }, - { 0x0216, "\x00\x55\x03\x11\0" }, - { 0x0217, "\x00\x75\x03\x11\0" }, - { 0x0218, "\x00\x53\x03\x26\0" }, - { 0x0219, "\x00\x73\x03\x26\0" }, - { 0x021a, "\x00\x54\x03\x26\0" }, - { 0x021b, "\x00\x74\x03\x26\0" }, - { 0x021e, "\x00\x48\x03\x0c\0" }, - { 0x021f, "\x00\x68\x03\x0c\0" }, - { 0x0226, "\x00\x41\x03\x07\0" }, - { 0x0227, "\x00\x61\x03\x07\0" }, - { 0x0228, "\x00\x45\x03\x27\0" }, - { 0x0229, "\x00\x65\x03\x27\0" }, - { 0x022a, "\x00\x4f\x03\x08\x03\x04\0" }, - { 0x022b, "\x00\x6f\x03\x08\x03\x04\0" }, - { 0x022c, "\x00\x4f\x03\x03\x03\x04\0" }, - { 0x022d, "\x00\x6f\x03\x03\x03\x04\0" }, - { 0x022e, "\x00\x4f\x03\x07\0" }, - { 0x022f, "\x00\x6f\x03\x07\0" }, - { 0x0230, "\x00\x4f\x03\x07\x03\x04\0" }, - { 0x0231, "\x00\x6f\x03\x07\x03\x04\0" }, - { 0x0232, "\x00\x59\x03\x04\0" }, - { 0x0233, "\x00\x79\x03\x04\0" }, - { 0x0340, "\x03\x00\0" }, - { 0x0341, "\x03\x01\0" }, - { 0x0343, "\x03\x13\0" }, - { 0x0344, "\x03\x08\x03\x01\0" }, - { 0x0374, "\x02\xb9\0" }, - { 0x037e, "\x00\x3b\0" }, - { 0x0385, "\x00\xa8\x03\x01\0" }, - { 0x0386, "\x03\x91\x03\x01\0" }, - { 0x0387, "\x00\xb7\0" }, - { 0x0388, "\x03\x95\x03\x01\0" }, - { 0x0389, "\x03\x97\x03\x01\0" }, - { 0x038a, "\x03\x99\x03\x01\0" }, - { 0x038c, "\x03\x9f\x03\x01\0" }, - { 0x038e, "\x03\xa5\x03\x01\0" }, - { 0x038f, "\x03\xa9\x03\x01\0" }, - { 0x0390, "\x03\xb9\x03\x08\x03\x01\0" }, - { 0x03aa, "\x03\x99\x03\x08\0" }, - { 0x03ab, "\x03\xa5\x03\x08\0" }, - { 0x03ac, "\x03\xb1\x03\x01\0" }, - { 0x03ad, "\x03\xb5\x03\x01\0" }, - { 0x03ae, "\x03\xb7\x03\x01\0" }, - { 0x03af, "\x03\xb9\x03\x01\0" }, - { 0x03b0, "\x03\xc5\x03\x08\x03\x01\0" }, - { 0x03ca, "\x03\xb9\x03\x08\0" }, - { 0x03cb, "\x03\xc5\x03\x08\0" }, - { 0x03cc, "\x03\xbf\x03\x01\0" }, - { 0x03cd, "\x03\xc5\x03\x01\0" }, - { 0x03ce, "\x03\xc9\x03\x01\0" }, - { 0x03d3, "\x03\xd2\x03\x01\0" }, - { 0x03d4, "\x03\xd2\x03\x08\0" }, - { 0x0400, "\x04\x15\x03\x00\0" }, - { 0x0401, "\x04\x15\x03\x08\0" }, - { 0x0403, "\x04\x13\x03\x01\0" }, - { 0x0407, "\x04\x06\x03\x08\0" }, - { 0x040c, "\x04\x1a\x03\x01\0" }, - { 0x040d, "\x04\x18\x03\x00\0" }, - { 0x040e, "\x04\x23\x03\x06\0" }, - { 0x0419, "\x04\x18\x03\x06\0" }, - { 0x0439, "\x04\x38\x03\x06\0" }, - { 0x0450, "\x04\x35\x03\x00\0" }, - { 0x0451, "\x04\x35\x03\x08\0" }, - { 0x0453, "\x04\x33\x03\x01\0" }, - { 0x0457, "\x04\x56\x03\x08\0" }, - { 0x045c, "\x04\x3a\x03\x01\0" }, - { 0x045d, "\x04\x38\x03\x00\0" }, - { 0x045e, "\x04\x43\x03\x06\0" }, - { 0x0476, "\x04\x74\x03\x0f\0" }, - { 0x0477, "\x04\x75\x03\x0f\0" }, - { 0x04c1, "\x04\x16\x03\x06\0" }, - { 0x04c2, "\x04\x36\x03\x06\0" }, - { 0x04d0, "\x04\x10\x03\x06\0" }, - { 0x04d1, "\x04\x30\x03\x06\0" }, - { 0x04d2, "\x04\x10\x03\x08\0" }, - { 0x04d3, "\x04\x30\x03\x08\0" }, - { 0x04d6, "\x04\x15\x03\x06\0" }, - { 0x04d7, "\x04\x35\x03\x06\0" }, - { 0x04da, "\x04\xd8\x03\x08\0" }, - { 0x04db, "\x04\xd9\x03\x08\0" }, - { 0x04dc, "\x04\x16\x03\x08\0" }, - { 0x04dd, "\x04\x36\x03\x08\0" }, - { 0x04de, "\x04\x17\x03\x08\0" }, - { 0x04df, "\x04\x37\x03\x08\0" }, - { 0x04e2, "\x04\x18\x03\x04\0" }, - { 0x04e3, "\x04\x38\x03\x04\0" }, - { 0x04e4, "\x04\x18\x03\x08\0" }, - { 0x04e5, "\x04\x38\x03\x08\0" }, - { 0x04e6, "\x04\x1e\x03\x08\0" }, - { 0x04e7, "\x04\x3e\x03\x08\0" }, - { 0x04ea, "\x04\xe8\x03\x08\0" }, - { 0x04eb, "\x04\xe9\x03\x08\0" }, - { 0x04ec, "\x04\x2d\x03\x08\0" }, - { 0x04ed, "\x04\x4d\x03\x08\0" }, - { 0x04ee, "\x04\x23\x03\x04\0" }, - { 0x04ef, "\x04\x43\x03\x04\0" }, - { 0x04f0, "\x04\x23\x03\x08\0" }, - { 0x04f1, "\x04\x43\x03\x08\0" }, - { 0x04f2, "\x04\x23\x03\x0b\0" }, - { 0x04f3, "\x04\x43\x03\x0b\0" }, - { 0x04f4, "\x04\x27\x03\x08\0" }, - { 0x04f5, "\x04\x47\x03\x08\0" }, - { 0x04f8, "\x04\x2b\x03\x08\0" }, - { 0x04f9, "\x04\x4b\x03\x08\0" }, - { 0x0622, "\x06\x27\x06\x53\0" }, - { 0x0623, "\x06\x27\x06\x54\0" }, - { 0x0624, "\x06\x48\x06\x54\0" }, - { 0x0625, "\x06\x27\x06\x55\0" }, - { 0x0626, "\x06\x4a\x06\x54\0" }, - { 0x06c0, "\x06\xd5\x06\x54\0" }, - { 0x06c2, "\x06\xc1\x06\x54\0" }, - { 0x06d3, "\x06\xd2\x06\x54\0" }, - { 0x0929, "\x09\x28\x09\x3c\0" }, - { 0x0931, "\x09\x30\x09\x3c\0" }, - { 0x0934, "\x09\x33\x09\x3c\0" }, - { 0x0958, "\x09\x15\x09\x3c\0" }, - { 0x0959, "\x09\x16\x09\x3c\0" }, - { 0x095a, "\x09\x17\x09\x3c\0" }, - { 0x095b, "\x09\x1c\x09\x3c\0" }, - { 0x095c, "\x09\x21\x09\x3c\0" }, - { 0x095d, "\x09\x22\x09\x3c\0" }, - { 0x095e, "\x09\x2b\x09\x3c\0" }, - { 0x095f, "\x09\x2f\x09\x3c\0" }, - { 0x09cb, "\x09\xc7\x09\xbe\0" }, - { 0x09cc, "\x09\xc7\x09\xd7\0" }, - { 0x09dc, "\x09\xa1\x09\xbc\0" }, - { 0x09dd, "\x09\xa2\x09\xbc\0" }, - { 0x09df, "\x09\xaf\x09\xbc\0" }, - { 0x0a33, "\x0a\x32\x0a\x3c\0" }, - { 0x0a36, "\x0a\x38\x0a\x3c\0" }, - { 0x0a59, "\x0a\x16\x0a\x3c\0" }, - { 0x0a5a, "\x0a\x17\x0a\x3c\0" }, - { 0x0a5b, "\x0a\x1c\x0a\x3c\0" }, - { 0x0a5e, "\x0a\x2b\x0a\x3c\0" }, - { 0x0b48, "\x0b\x47\x0b\x56\0" }, - { 0x0b4b, "\x0b\x47\x0b\x3e\0" }, - { 0x0b4c, "\x0b\x47\x0b\x57\0" }, - { 0x0b5c, "\x0b\x21\x0b\x3c\0" }, - { 0x0b5d, "\x0b\x22\x0b\x3c\0" }, - { 0x0b94, "\x0b\x92\x0b\xd7\0" }, - { 0x0bca, "\x0b\xc6\x0b\xbe\0" }, - { 0x0bcb, "\x0b\xc7\x0b\xbe\0" }, - { 0x0bcc, "\x0b\xc6\x0b\xd7\0" }, - { 0x0c48, "\x0c\x46\x0c\x56\0" }, - { 0x0cc0, "\x0c\xbf\x0c\xd5\0" }, - { 0x0cc7, "\x0c\xc6\x0c\xd5\0" }, - { 0x0cc8, "\x0c\xc6\x0c\xd6\0" }, - { 0x0cca, "\x0c\xc6\x0c\xc2\0" }, - { 0x0ccb, "\x0c\xc6\x0c\xc2\x0c\xd5\0" }, - { 0x0d4a, "\x0d\x46\x0d\x3e\0" }, - { 0x0d4b, "\x0d\x47\x0d\x3e\0" }, - { 0x0d4c, "\x0d\x46\x0d\x57\0" }, - { 0x0dda, "\x0d\xd9\x0d\xca\0" }, - { 0x0ddc, "\x0d\xd9\x0d\xcf\0" }, - { 0x0ddd, "\x0d\xd9\x0d\xcf\x0d\xca\0" }, - { 0x0dde, "\x0d\xd9\x0d\xdf\0" }, - { 0x0f43, "\x0f\x42\x0f\xb7\0" }, - { 0x0f4d, "\x0f\x4c\x0f\xb7\0" }, - { 0x0f52, "\x0f\x51\x0f\xb7\0" }, - { 0x0f57, "\x0f\x56\x0f\xb7\0" }, - { 0x0f5c, "\x0f\x5b\x0f\xb7\0" }, - { 0x0f69, "\x0f\x40\x0f\xb5\0" }, - { 0x0f73, "\x0f\x71\x0f\x72\0" }, - { 0x0f75, "\x0f\x71\x0f\x74\0" }, - { 0x0f76, "\x0f\xb2\x0f\x80\0" }, - { 0x0f78, "\x0f\xb3\x0f\x80\0" }, - { 0x0f81, "\x0f\x71\x0f\x80\0" }, - { 0x0f93, "\x0f\x92\x0f\xb7\0" }, - { 0x0f9d, "\x0f\x9c\x0f\xb7\0" }, - { 0x0fa2, "\x0f\xa1\x0f\xb7\0" }, - { 0x0fa7, "\x0f\xa6\x0f\xb7\0" }, - { 0x0fac, "\x0f\xab\x0f\xb7\0" }, - { 0x0fb9, "\x0f\x90\x0f\xb5\0" }, - { 0x1026, "\x10\x25\x10\x2e\0" }, - { 0x1e00, "\x00\x41\x03\x25\0" }, - { 0x1e01, "\x00\x61\x03\x25\0" }, - { 0x1e02, "\x00\x42\x03\x07\0" }, - { 0x1e03, "\x00\x62\x03\x07\0" }, - { 0x1e04, "\x00\x42\x03\x23\0" }, - { 0x1e05, "\x00\x62\x03\x23\0" }, - { 0x1e06, "\x00\x42\x03\x31\0" }, - { 0x1e07, "\x00\x62\x03\x31\0" }, - { 0x1e08, "\x00\x43\x03\x27\x03\x01\0" }, - { 0x1e09, "\x00\x63\x03\x27\x03\x01\0" }, - { 0x1e0a, "\x00\x44\x03\x07\0" }, - { 0x1e0b, "\x00\x64\x03\x07\0" }, - { 0x1e0c, "\x00\x44\x03\x23\0" }, - { 0x1e0d, "\x00\x64\x03\x23\0" }, - { 0x1e0e, "\x00\x44\x03\x31\0" }, - { 0x1e0f, "\x00\x64\x03\x31\0" }, - { 0x1e10, "\x00\x44\x03\x27\0" }, - { 0x1e11, "\x00\x64\x03\x27\0" }, - { 0x1e12, "\x00\x44\x03\x2d\0" }, - { 0x1e13, "\x00\x64\x03\x2d\0" }, - { 0x1e14, "\x00\x45\x03\x04\x03\x00\0" }, - { 0x1e15, "\x00\x65\x03\x04\x03\x00\0" }, - { 0x1e16, "\x00\x45\x03\x04\x03\x01\0" }, - { 0x1e17, "\x00\x65\x03\x04\x03\x01\0" }, - { 0x1e18, "\x00\x45\x03\x2d\0" }, - { 0x1e19, "\x00\x65\x03\x2d\0" }, - { 0x1e1a, "\x00\x45\x03\x30\0" }, - { 0x1e1b, "\x00\x65\x03\x30\0" }, - { 0x1e1c, "\x00\x45\x03\x27\x03\x06\0" }, - { 0x1e1d, "\x00\x65\x03\x27\x03\x06\0" }, - { 0x1e1e, "\x00\x46\x03\x07\0" }, - { 0x1e1f, "\x00\x66\x03\x07\0" }, - { 0x1e20, "\x00\x47\x03\x04\0" }, - { 0x1e21, "\x00\x67\x03\x04\0" }, - { 0x1e22, "\x00\x48\x03\x07\0" }, - { 0x1e23, "\x00\x68\x03\x07\0" }, - { 0x1e24, "\x00\x48\x03\x23\0" }, - { 0x1e25, "\x00\x68\x03\x23\0" }, - { 0x1e26, "\x00\x48\x03\x08\0" }, - { 0x1e27, "\x00\x68\x03\x08\0" }, - { 0x1e28, "\x00\x48\x03\x27\0" }, - { 0x1e29, "\x00\x68\x03\x27\0" }, - { 0x1e2a, "\x00\x48\x03\x2e\0" }, - { 0x1e2b, "\x00\x68\x03\x2e\0" }, - { 0x1e2c, "\x00\x49\x03\x30\0" }, - { 0x1e2d, "\x00\x69\x03\x30\0" }, - { 0x1e2e, "\x00\x49\x03\x08\x03\x01\0" }, - { 0x1e2f, "\x00\x69\x03\x08\x03\x01\0" }, - { 0x1e30, "\x00\x4b\x03\x01\0" }, - { 0x1e31, "\x00\x6b\x03\x01\0" }, - { 0x1e32, "\x00\x4b\x03\x23\0" }, - { 0x1e33, "\x00\x6b\x03\x23\0" }, - { 0x1e34, "\x00\x4b\x03\x31\0" }, - { 0x1e35, "\x00\x6b\x03\x31\0" }, - { 0x1e36, "\x00\x4c\x03\x23\0" }, - { 0x1e37, "\x00\x6c\x03\x23\0" }, - { 0x1e38, "\x00\x4c\x03\x23\x03\x04\0" }, - { 0x1e39, "\x00\x6c\x03\x23\x03\x04\0" }, - { 0x1e3a, "\x00\x4c\x03\x31\0" }, - { 0x1e3b, "\x00\x6c\x03\x31\0" }, - { 0x1e3c, "\x00\x4c\x03\x2d\0" }, - { 0x1e3d, "\x00\x6c\x03\x2d\0" }, - { 0x1e3e, "\x00\x4d\x03\x01\0" }, - { 0x1e3f, "\x00\x6d\x03\x01\0" }, - { 0x1e40, "\x00\x4d\x03\x07\0" }, - { 0x1e41, "\x00\x6d\x03\x07\0" }, - { 0x1e42, "\x00\x4d\x03\x23\0" }, - { 0x1e43, "\x00\x6d\x03\x23\0" }, - { 0x1e44, "\x00\x4e\x03\x07\0" }, - { 0x1e45, "\x00\x6e\x03\x07\0" }, - { 0x1e46, "\x00\x4e\x03\x23\0" }, - { 0x1e47, "\x00\x6e\x03\x23\0" }, - { 0x1e48, "\x00\x4e\x03\x31\0" }, - { 0x1e49, "\x00\x6e\x03\x31\0" }, - { 0x1e4a, "\x00\x4e\x03\x2d\0" }, - { 0x1e4b, "\x00\x6e\x03\x2d\0" }, - { 0x1e4c, "\x00\x4f\x03\x03\x03\x01\0" }, - { 0x1e4d, "\x00\x6f\x03\x03\x03\x01\0" }, - { 0x1e4e, "\x00\x4f\x03\x03\x03\x08\0" }, - { 0x1e4f, "\x00\x6f\x03\x03\x03\x08\0" }, - { 0x1e50, "\x00\x4f\x03\x04\x03\x00\0" }, - { 0x1e51, "\x00\x6f\x03\x04\x03\x00\0" }, - { 0x1e52, "\x00\x4f\x03\x04\x03\x01\0" }, - { 0x1e53, "\x00\x6f\x03\x04\x03\x01\0" }, - { 0x1e54, "\x00\x50\x03\x01\0" }, - { 0x1e55, "\x00\x70\x03\x01\0" }, - { 0x1e56, "\x00\x50\x03\x07\0" }, - { 0x1e57, "\x00\x70\x03\x07\0" }, - { 0x1e58, "\x00\x52\x03\x07\0" }, - { 0x1e59, "\x00\x72\x03\x07\0" }, - { 0x1e5a, "\x00\x52\x03\x23\0" }, - { 0x1e5b, "\x00\x72\x03\x23\0" }, - { 0x1e5c, "\x00\x52\x03\x23\x03\x04\0" }, - { 0x1e5d, "\x00\x72\x03\x23\x03\x04\0" }, - { 0x1e5e, "\x00\x52\x03\x31\0" }, - { 0x1e5f, "\x00\x72\x03\x31\0" }, - { 0x1e60, "\x00\x53\x03\x07\0" }, - { 0x1e61, "\x00\x73\x03\x07\0" }, - { 0x1e62, "\x00\x53\x03\x23\0" }, - { 0x1e63, "\x00\x73\x03\x23\0" }, - { 0x1e64, "\x00\x53\x03\x01\x03\x07\0" }, - { 0x1e65, "\x00\x73\x03\x01\x03\x07\0" }, - { 0x1e66, "\x00\x53\x03\x0c\x03\x07\0" }, - { 0x1e67, "\x00\x73\x03\x0c\x03\x07\0" }, - { 0x1e68, "\x00\x53\x03\x23\x03\x07\0" }, - { 0x1e69, "\x00\x73\x03\x23\x03\x07\0" }, - { 0x1e6a, "\x00\x54\x03\x07\0" }, - { 0x1e6b, "\x00\x74\x03\x07\0" }, - { 0x1e6c, "\x00\x54\x03\x23\0" }, - { 0x1e6d, "\x00\x74\x03\x23\0" }, - { 0x1e6e, "\x00\x54\x03\x31\0" }, - { 0x1e6f, "\x00\x74\x03\x31\0" }, - { 0x1e70, "\x00\x54\x03\x2d\0" }, - { 0x1e71, "\x00\x74\x03\x2d\0" }, - { 0x1e72, "\x00\x55\x03\x24\0" }, - { 0x1e73, "\x00\x75\x03\x24\0" }, - { 0x1e74, "\x00\x55\x03\x30\0" }, - { 0x1e75, "\x00\x75\x03\x30\0" }, - { 0x1e76, "\x00\x55\x03\x2d\0" }, - { 0x1e77, "\x00\x75\x03\x2d\0" }, - { 0x1e78, "\x00\x55\x03\x03\x03\x01\0" }, - { 0x1e79, "\x00\x75\x03\x03\x03\x01\0" }, - { 0x1e7a, "\x00\x55\x03\x04\x03\x08\0" }, - { 0x1e7b, "\x00\x75\x03\x04\x03\x08\0" }, - { 0x1e7c, "\x00\x56\x03\x03\0" }, - { 0x1e7d, "\x00\x76\x03\x03\0" }, - { 0x1e7e, "\x00\x56\x03\x23\0" }, - { 0x1e7f, "\x00\x76\x03\x23\0" }, - { 0x1e80, "\x00\x57\x03\x00\0" }, - { 0x1e81, "\x00\x77\x03\x00\0" }, - { 0x1e82, "\x00\x57\x03\x01\0" }, - { 0x1e83, "\x00\x77\x03\x01\0" }, - { 0x1e84, "\x00\x57\x03\x08\0" }, - { 0x1e85, "\x00\x77\x03\x08\0" }, - { 0x1e86, "\x00\x57\x03\x07\0" }, - { 0x1e87, "\x00\x77\x03\x07\0" }, - { 0x1e88, "\x00\x57\x03\x23\0" }, - { 0x1e89, "\x00\x77\x03\x23\0" }, - { 0x1e8a, "\x00\x58\x03\x07\0" }, - { 0x1e8b, "\x00\x78\x03\x07\0" }, - { 0x1e8c, "\x00\x58\x03\x08\0" }, - { 0x1e8d, "\x00\x78\x03\x08\0" }, - { 0x1e8e, "\x00\x59\x03\x07\0" }, - { 0x1e8f, "\x00\x79\x03\x07\0" }, - { 0x1e90, "\x00\x5a\x03\x02\0" }, - { 0x1e91, "\x00\x7a\x03\x02\0" }, - { 0x1e92, "\x00\x5a\x03\x23\0" }, - { 0x1e93, "\x00\x7a\x03\x23\0" }, - { 0x1e94, "\x00\x5a\x03\x31\0" }, - { 0x1e95, "\x00\x7a\x03\x31\0" }, - { 0x1e96, "\x00\x68\x03\x31\0" }, - { 0x1e97, "\x00\x74\x03\x08\0" }, - { 0x1e98, "\x00\x77\x03\x0a\0" }, - { 0x1e99, "\x00\x79\x03\x0a\0" }, - { 0x1e9b, "\x01\x7f\x03\x07\0" }, - { 0x1ea0, "\x00\x41\x03\x23\0" }, - { 0x1ea1, "\x00\x61\x03\x23\0" }, - { 0x1ea2, "\x00\x41\x03\x09\0" }, - { 0x1ea3, "\x00\x61\x03\x09\0" }, - { 0x1ea4, "\x00\x41\x03\x02\x03\x01\0" }, - { 0x1ea5, "\x00\x61\x03\x02\x03\x01\0" }, - { 0x1ea6, "\x00\x41\x03\x02\x03\x00\0" }, - { 0x1ea7, "\x00\x61\x03\x02\x03\x00\0" }, - { 0x1ea8, "\x00\x41\x03\x02\x03\x09\0" }, - { 0x1ea9, "\x00\x61\x03\x02\x03\x09\0" }, - { 0x1eaa, "\x00\x41\x03\x02\x03\x03\0" }, - { 0x1eab, "\x00\x61\x03\x02\x03\x03\0" }, - { 0x1eac, "\x00\x41\x03\x23\x03\x02\0" }, - { 0x1ead, "\x00\x61\x03\x23\x03\x02\0" }, - { 0x1eae, "\x00\x41\x03\x06\x03\x01\0" }, - { 0x1eaf, "\x00\x61\x03\x06\x03\x01\0" }, - { 0x1eb0, "\x00\x41\x03\x06\x03\x00\0" }, - { 0x1eb1, "\x00\x61\x03\x06\x03\x00\0" }, - { 0x1eb2, "\x00\x41\x03\x06\x03\x09\0" }, - { 0x1eb3, "\x00\x61\x03\x06\x03\x09\0" }, - { 0x1eb4, "\x00\x41\x03\x06\x03\x03\0" }, - { 0x1eb5, "\x00\x61\x03\x06\x03\x03\0" }, - { 0x1eb6, "\x00\x41\x03\x23\x03\x06\0" }, - { 0x1eb7, "\x00\x61\x03\x23\x03\x06\0" }, - { 0x1eb8, "\x00\x45\x03\x23\0" }, - { 0x1eb9, "\x00\x65\x03\x23\0" }, - { 0x1eba, "\x00\x45\x03\x09\0" }, - { 0x1ebb, "\x00\x65\x03\x09\0" }, - { 0x1ebc, "\x00\x45\x03\x03\0" }, - { 0x1ebd, "\x00\x65\x03\x03\0" }, - { 0x1ebe, "\x00\x45\x03\x02\x03\x01\0" }, - { 0x1ebf, "\x00\x65\x03\x02\x03\x01\0" }, - { 0x1ec0, "\x00\x45\x03\x02\x03\x00\0" }, - { 0x1ec1, "\x00\x65\x03\x02\x03\x00\0" }, - { 0x1ec2, "\x00\x45\x03\x02\x03\x09\0" }, - { 0x1ec3, "\x00\x65\x03\x02\x03\x09\0" }, - { 0x1ec4, "\x00\x45\x03\x02\x03\x03\0" }, - { 0x1ec5, "\x00\x65\x03\x02\x03\x03\0" }, - { 0x1ec6, "\x00\x45\x03\x23\x03\x02\0" }, - { 0x1ec7, "\x00\x65\x03\x23\x03\x02\0" }, - { 0x1ec8, "\x00\x49\x03\x09\0" }, - { 0x1ec9, "\x00\x69\x03\x09\0" }, - { 0x1eca, "\x00\x49\x03\x23\0" }, - { 0x1ecb, "\x00\x69\x03\x23\0" }, - { 0x1ecc, "\x00\x4f\x03\x23\0" }, - { 0x1ecd, "\x00\x6f\x03\x23\0" }, - { 0x1ece, "\x00\x4f\x03\x09\0" }, - { 0x1ecf, "\x00\x6f\x03\x09\0" }, - { 0x1ed0, "\x00\x4f\x03\x02\x03\x01\0" }, - { 0x1ed1, "\x00\x6f\x03\x02\x03\x01\0" }, - { 0x1ed2, "\x00\x4f\x03\x02\x03\x00\0" }, - { 0x1ed3, "\x00\x6f\x03\x02\x03\x00\0" }, - { 0x1ed4, "\x00\x4f\x03\x02\x03\x09\0" }, - { 0x1ed5, "\x00\x6f\x03\x02\x03\x09\0" }, - { 0x1ed6, "\x00\x4f\x03\x02\x03\x03\0" }, - { 0x1ed7, "\x00\x6f\x03\x02\x03\x03\0" }, - { 0x1ed8, "\x00\x4f\x03\x23\x03\x02\0" }, - { 0x1ed9, "\x00\x6f\x03\x23\x03\x02\0" }, - { 0x1eda, "\x00\x4f\x03\x1b\x03\x01\0" }, - { 0x1edb, "\x00\x6f\x03\x1b\x03\x01\0" }, - { 0x1edc, "\x00\x4f\x03\x1b\x03\x00\0" }, - { 0x1edd, "\x00\x6f\x03\x1b\x03\x00\0" }, - { 0x1ede, "\x00\x4f\x03\x1b\x03\x09\0" }, - { 0x1edf, "\x00\x6f\x03\x1b\x03\x09\0" }, - { 0x1ee0, "\x00\x4f\x03\x1b\x03\x03\0" }, - { 0x1ee1, "\x00\x6f\x03\x1b\x03\x03\0" }, - { 0x1ee2, "\x00\x4f\x03\x1b\x03\x23\0" }, - { 0x1ee3, "\x00\x6f\x03\x1b\x03\x23\0" }, - { 0x1ee4, "\x00\x55\x03\x23\0" }, - { 0x1ee5, "\x00\x75\x03\x23\0" }, - { 0x1ee6, "\x00\x55\x03\x09\0" }, - { 0x1ee7, "\x00\x75\x03\x09\0" }, - { 0x1ee8, "\x00\x55\x03\x1b\x03\x01\0" }, - { 0x1ee9, "\x00\x75\x03\x1b\x03\x01\0" }, - { 0x1eea, "\x00\x55\x03\x1b\x03\x00\0" }, - { 0x1eeb, "\x00\x75\x03\x1b\x03\x00\0" }, - { 0x1eec, "\x00\x55\x03\x1b\x03\x09\0" }, - { 0x1eed, "\x00\x75\x03\x1b\x03\x09\0" }, - { 0x1eee, "\x00\x55\x03\x1b\x03\x03\0" }, - { 0x1eef, "\x00\x75\x03\x1b\x03\x03\0" }, - { 0x1ef0, "\x00\x55\x03\x1b\x03\x23\0" }, - { 0x1ef1, "\x00\x75\x03\x1b\x03\x23\0" }, - { 0x1ef2, "\x00\x59\x03\x00\0" }, - { 0x1ef3, "\x00\x79\x03\x00\0" }, - { 0x1ef4, "\x00\x59\x03\x23\0" }, - { 0x1ef5, "\x00\x79\x03\x23\0" }, - { 0x1ef6, "\x00\x59\x03\x09\0" }, - { 0x1ef7, "\x00\x79\x03\x09\0" }, - { 0x1ef8, "\x00\x59\x03\x03\0" }, - { 0x1ef9, "\x00\x79\x03\x03\0" }, - { 0x1f00, "\x03\xb1\x03\x13\0" }, - { 0x1f01, "\x03\xb1\x03\x14\0" }, - { 0x1f02, "\x03\xb1\x03\x13\x03\x00\0" }, - { 0x1f03, "\x03\xb1\x03\x14\x03\x00\0" }, - { 0x1f04, "\x03\xb1\x03\x13\x03\x01\0" }, - { 0x1f05, "\x03\xb1\x03\x14\x03\x01\0" }, - { 0x1f06, "\x03\xb1\x03\x13\x03\x42\0" }, - { 0x1f07, "\x03\xb1\x03\x14\x03\x42\0" }, - { 0x1f08, "\x03\x91\x03\x13\0" }, - { 0x1f09, "\x03\x91\x03\x14\0" }, - { 0x1f0a, "\x03\x91\x03\x13\x03\x00\0" }, - { 0x1f0b, "\x03\x91\x03\x14\x03\x00\0" }, - { 0x1f0c, "\x03\x91\x03\x13\x03\x01\0" }, - { 0x1f0d, "\x03\x91\x03\x14\x03\x01\0" }, - { 0x1f0e, "\x03\x91\x03\x13\x03\x42\0" }, - { 0x1f0f, "\x03\x91\x03\x14\x03\x42\0" }, - { 0x1f10, "\x03\xb5\x03\x13\0" }, - { 0x1f11, "\x03\xb5\x03\x14\0" }, - { 0x1f12, "\x03\xb5\x03\x13\x03\x00\0" }, - { 0x1f13, "\x03\xb5\x03\x14\x03\x00\0" }, - { 0x1f14, "\x03\xb5\x03\x13\x03\x01\0" }, - { 0x1f15, "\x03\xb5\x03\x14\x03\x01\0" }, - { 0x1f18, "\x03\x95\x03\x13\0" }, - { 0x1f19, "\x03\x95\x03\x14\0" }, - { 0x1f1a, "\x03\x95\x03\x13\x03\x00\0" }, - { 0x1f1b, "\x03\x95\x03\x14\x03\x00\0" }, - { 0x1f1c, "\x03\x95\x03\x13\x03\x01\0" }, - { 0x1f1d, "\x03\x95\x03\x14\x03\x01\0" }, - { 0x1f20, "\x03\xb7\x03\x13\0" }, - { 0x1f21, "\x03\xb7\x03\x14\0" }, - { 0x1f22, "\x03\xb7\x03\x13\x03\x00\0" }, - { 0x1f23, "\x03\xb7\x03\x14\x03\x00\0" }, - { 0x1f24, "\x03\xb7\x03\x13\x03\x01\0" }, - { 0x1f25, "\x03\xb7\x03\x14\x03\x01\0" }, - { 0x1f26, "\x03\xb7\x03\x13\x03\x42\0" }, - { 0x1f27, "\x03\xb7\x03\x14\x03\x42\0" }, - { 0x1f28, "\x03\x97\x03\x13\0" }, - { 0x1f29, "\x03\x97\x03\x14\0" }, - { 0x1f2a, "\x03\x97\x03\x13\x03\x00\0" }, - { 0x1f2b, "\x03\x97\x03\x14\x03\x00\0" }, - { 0x1f2c, "\x03\x97\x03\x13\x03\x01\0" }, - { 0x1f2d, "\x03\x97\x03\x14\x03\x01\0" }, - { 0x1f2e, "\x03\x97\x03\x13\x03\x42\0" }, - { 0x1f2f, "\x03\x97\x03\x14\x03\x42\0" }, - { 0x1f30, "\x03\xb9\x03\x13\0" }, - { 0x1f31, "\x03\xb9\x03\x14\0" }, - { 0x1f32, "\x03\xb9\x03\x13\x03\x00\0" }, - { 0x1f33, "\x03\xb9\x03\x14\x03\x00\0" }, - { 0x1f34, "\x03\xb9\x03\x13\x03\x01\0" }, - { 0x1f35, "\x03\xb9\x03\x14\x03\x01\0" }, - { 0x1f36, "\x03\xb9\x03\x13\x03\x42\0" }, - { 0x1f37, "\x03\xb9\x03\x14\x03\x42\0" }, - { 0x1f38, "\x03\x99\x03\x13\0" }, - { 0x1f39, "\x03\x99\x03\x14\0" }, - { 0x1f3a, "\x03\x99\x03\x13\x03\x00\0" }, - { 0x1f3b, "\x03\x99\x03\x14\x03\x00\0" }, - { 0x1f3c, "\x03\x99\x03\x13\x03\x01\0" }, - { 0x1f3d, "\x03\x99\x03\x14\x03\x01\0" }, - { 0x1f3e, "\x03\x99\x03\x13\x03\x42\0" }, - { 0x1f3f, "\x03\x99\x03\x14\x03\x42\0" }, - { 0x1f40, "\x03\xbf\x03\x13\0" }, - { 0x1f41, "\x03\xbf\x03\x14\0" }, - { 0x1f42, "\x03\xbf\x03\x13\x03\x00\0" }, - { 0x1f43, "\x03\xbf\x03\x14\x03\x00\0" }, - { 0x1f44, "\x03\xbf\x03\x13\x03\x01\0" }, - { 0x1f45, "\x03\xbf\x03\x14\x03\x01\0" }, - { 0x1f48, "\x03\x9f\x03\x13\0" }, - { 0x1f49, "\x03\x9f\x03\x14\0" }, - { 0x1f4a, "\x03\x9f\x03\x13\x03\x00\0" }, - { 0x1f4b, "\x03\x9f\x03\x14\x03\x00\0" }, - { 0x1f4c, "\x03\x9f\x03\x13\x03\x01\0" }, - { 0x1f4d, "\x03\x9f\x03\x14\x03\x01\0" }, - { 0x1f50, "\x03\xc5\x03\x13\0" }, - { 0x1f51, "\x03\xc5\x03\x14\0" }, - { 0x1f52, "\x03\xc5\x03\x13\x03\x00\0" }, - { 0x1f53, "\x03\xc5\x03\x14\x03\x00\0" }, - { 0x1f54, "\x03\xc5\x03\x13\x03\x01\0" }, - { 0x1f55, "\x03\xc5\x03\x14\x03\x01\0" }, - { 0x1f56, "\x03\xc5\x03\x13\x03\x42\0" }, - { 0x1f57, "\x03\xc5\x03\x14\x03\x42\0" }, - { 0x1f59, "\x03\xa5\x03\x14\0" }, - { 0x1f5b, "\x03\xa5\x03\x14\x03\x00\0" }, - { 0x1f5d, "\x03\xa5\x03\x14\x03\x01\0" }, - { 0x1f5f, "\x03\xa5\x03\x14\x03\x42\0" }, - { 0x1f60, "\x03\xc9\x03\x13\0" }, - { 0x1f61, "\x03\xc9\x03\x14\0" }, - { 0x1f62, "\x03\xc9\x03\x13\x03\x00\0" }, - { 0x1f63, "\x03\xc9\x03\x14\x03\x00\0" }, - { 0x1f64, "\x03\xc9\x03\x13\x03\x01\0" }, - { 0x1f65, "\x03\xc9\x03\x14\x03\x01\0" }, - { 0x1f66, "\x03\xc9\x03\x13\x03\x42\0" }, - { 0x1f67, "\x03\xc9\x03\x14\x03\x42\0" }, - { 0x1f68, "\x03\xa9\x03\x13\0" }, - { 0x1f69, "\x03\xa9\x03\x14\0" }, - { 0x1f6a, "\x03\xa9\x03\x13\x03\x00\0" }, - { 0x1f6b, "\x03\xa9\x03\x14\x03\x00\0" }, - { 0x1f6c, "\x03\xa9\x03\x13\x03\x01\0" }, - { 0x1f6d, "\x03\xa9\x03\x14\x03\x01\0" }, - { 0x1f6e, "\x03\xa9\x03\x13\x03\x42\0" }, - { 0x1f6f, "\x03\xa9\x03\x14\x03\x42\0" }, - { 0x1f70, "\x03\xb1\x03\x00\0" }, - { 0x1f71, "\x03\xb1\x03\x01\0" }, - { 0x1f72, "\x03\xb5\x03\x00\0" }, - { 0x1f73, "\x03\xb5\x03\x01\0" }, - { 0x1f74, "\x03\xb7\x03\x00\0" }, - { 0x1f75, "\x03\xb7\x03\x01\0" }, - { 0x1f76, "\x03\xb9\x03\x00\0" }, - { 0x1f77, "\x03\xb9\x03\x01\0" }, - { 0x1f78, "\x03\xbf\x03\x00\0" }, - { 0x1f79, "\x03\xbf\x03\x01\0" }, - { 0x1f7a, "\x03\xc5\x03\x00\0" }, - { 0x1f7b, "\x03\xc5\x03\x01\0" }, - { 0x1f7c, "\x03\xc9\x03\x00\0" }, - { 0x1f7d, "\x03\xc9\x03\x01\0" }, - { 0x1f80, "\x03\xb1\x03\x13\x03\x45\0" }, - { 0x1f81, "\x03\xb1\x03\x14\x03\x45\0" }, - { 0x1f82, "\x03\xb1\x03\x13\x03\x00\x03\x45\0" }, - { 0x1f83, "\x03\xb1\x03\x14\x03\x00\x03\x45\0" }, - { 0x1f84, "\x03\xb1\x03\x13\x03\x01\x03\x45\0" }, - { 0x1f85, "\x03\xb1\x03\x14\x03\x01\x03\x45\0" }, - { 0x1f86, "\x03\xb1\x03\x13\x03\x42\x03\x45\0" }, - { 0x1f87, "\x03\xb1\x03\x14\x03\x42\x03\x45\0" }, - { 0x1f88, "\x03\x91\x03\x13\x03\x45\0" }, - { 0x1f89, "\x03\x91\x03\x14\x03\x45\0" }, - { 0x1f8a, "\x03\x91\x03\x13\x03\x00\x03\x45\0" }, - { 0x1f8b, "\x03\x91\x03\x14\x03\x00\x03\x45\0" }, - { 0x1f8c, "\x03\x91\x03\x13\x03\x01\x03\x45\0" }, - { 0x1f8d, "\x03\x91\x03\x14\x03\x01\x03\x45\0" }, - { 0x1f8e, "\x03\x91\x03\x13\x03\x42\x03\x45\0" }, - { 0x1f8f, "\x03\x91\x03\x14\x03\x42\x03\x45\0" }, - { 0x1f90, "\x03\xb7\x03\x13\x03\x45\0" }, - { 0x1f91, "\x03\xb7\x03\x14\x03\x45\0" }, - { 0x1f92, "\x03\xb7\x03\x13\x03\x00\x03\x45\0" }, - { 0x1f93, "\x03\xb7\x03\x14\x03\x00\x03\x45\0" }, - { 0x1f94, "\x03\xb7\x03\x13\x03\x01\x03\x45\0" }, - { 0x1f95, "\x03\xb7\x03\x14\x03\x01\x03\x45\0" }, - { 0x1f96, "\x03\xb7\x03\x13\x03\x42\x03\x45\0" }, - { 0x1f97, "\x03\xb7\x03\x14\x03\x42\x03\x45\0" }, - { 0x1f98, "\x03\x97\x03\x13\x03\x45\0" }, - { 0x1f99, "\x03\x97\x03\x14\x03\x45\0" }, - { 0x1f9a, "\x03\x97\x03\x13\x03\x00\x03\x45\0" }, - { 0x1f9b, "\x03\x97\x03\x14\x03\x00\x03\x45\0" }, - { 0x1f9c, "\x03\x97\x03\x13\x03\x01\x03\x45\0" }, - { 0x1f9d, "\x03\x97\x03\x14\x03\x01\x03\x45\0" }, - { 0x1f9e, "\x03\x97\x03\x13\x03\x42\x03\x45\0" }, - { 0x1f9f, "\x03\x97\x03\x14\x03\x42\x03\x45\0" }, - { 0x1fa0, "\x03\xc9\x03\x13\x03\x45\0" }, - { 0x1fa1, "\x03\xc9\x03\x14\x03\x45\0" }, - { 0x1fa2, "\x03\xc9\x03\x13\x03\x00\x03\x45\0" }, - { 0x1fa3, "\x03\xc9\x03\x14\x03\x00\x03\x45\0" }, - { 0x1fa4, "\x03\xc9\x03\x13\x03\x01\x03\x45\0" }, - { 0x1fa5, "\x03\xc9\x03\x14\x03\x01\x03\x45\0" }, - { 0x1fa6, "\x03\xc9\x03\x13\x03\x42\x03\x45\0" }, - { 0x1fa7, "\x03\xc9\x03\x14\x03\x42\x03\x45\0" }, - { 0x1fa8, "\x03\xa9\x03\x13\x03\x45\0" }, - { 0x1fa9, "\x03\xa9\x03\x14\x03\x45\0" }, - { 0x1faa, "\x03\xa9\x03\x13\x03\x00\x03\x45\0" }, - { 0x1fab, "\x03\xa9\x03\x14\x03\x00\x03\x45\0" }, - { 0x1fac, "\x03\xa9\x03\x13\x03\x01\x03\x45\0" }, - { 0x1fad, "\x03\xa9\x03\x14\x03\x01\x03\x45\0" }, - { 0x1fae, "\x03\xa9\x03\x13\x03\x42\x03\x45\0" }, - { 0x1faf, "\x03\xa9\x03\x14\x03\x42\x03\x45\0" }, - { 0x1fb0, "\x03\xb1\x03\x06\0" }, - { 0x1fb1, "\x03\xb1\x03\x04\0" }, - { 0x1fb2, "\x03\xb1\x03\x00\x03\x45\0" }, - { 0x1fb3, "\x03\xb1\x03\x45\0" }, - { 0x1fb4, "\x03\xb1\x03\x01\x03\x45\0" }, - { 0x1fb6, "\x03\xb1\x03\x42\0" }, - { 0x1fb7, "\x03\xb1\x03\x42\x03\x45\0" }, - { 0x1fb8, "\x03\x91\x03\x06\0" }, - { 0x1fb9, "\x03\x91\x03\x04\0" }, - { 0x1fba, "\x03\x91\x03\x00\0" }, - { 0x1fbb, "\x03\x91\x03\x01\0" }, - { 0x1fbc, "\x03\x91\x03\x45\0" }, - { 0x1fbe, "\x03\xb9\0" }, - { 0x1fc1, "\x00\xa8\x03\x42\0" }, - { 0x1fc2, "\x03\xb7\x03\x00\x03\x45\0" }, - { 0x1fc3, "\x03\xb7\x03\x45\0" }, - { 0x1fc4, "\x03\xb7\x03\x01\x03\x45\0" }, - { 0x1fc6, "\x03\xb7\x03\x42\0" }, - { 0x1fc7, "\x03\xb7\x03\x42\x03\x45\0" }, - { 0x1fc8, "\x03\x95\x03\x00\0" }, - { 0x1fc9, "\x03\x95\x03\x01\0" }, - { 0x1fca, "\x03\x97\x03\x00\0" }, - { 0x1fcb, "\x03\x97\x03\x01\0" }, - { 0x1fcc, "\x03\x97\x03\x45\0" }, - { 0x1fcd, "\x1f\xbf\x03\x00\0" }, - { 0x1fce, "\x1f\xbf\x03\x01\0" }, - { 0x1fcf, "\x1f\xbf\x03\x42\0" }, - { 0x1fd0, "\x03\xb9\x03\x06\0" }, - { 0x1fd1, "\x03\xb9\x03\x04\0" }, - { 0x1fd2, "\x03\xb9\x03\x08\x03\x00\0" }, - { 0x1fd3, "\x03\xb9\x03\x08\x03\x01\0" }, - { 0x1fd6, "\x03\xb9\x03\x42\0" }, - { 0x1fd7, "\x03\xb9\x03\x08\x03\x42\0" }, - { 0x1fd8, "\x03\x99\x03\x06\0" }, - { 0x1fd9, "\x03\x99\x03\x04\0" }, - { 0x1fda, "\x03\x99\x03\x00\0" }, - { 0x1fdb, "\x03\x99\x03\x01\0" }, - { 0x1fdd, "\x1f\xfe\x03\x00\0" }, - { 0x1fde, "\x1f\xfe\x03\x01\0" }, - { 0x1fdf, "\x1f\xfe\x03\x42\0" }, - { 0x1fe0, "\x03\xc5\x03\x06\0" }, - { 0x1fe1, "\x03\xc5\x03\x04\0" }, - { 0x1fe2, "\x03\xc5\x03\x08\x03\x00\0" }, - { 0x1fe3, "\x03\xc5\x03\x08\x03\x01\0" }, - { 0x1fe4, "\x03\xc1\x03\x13\0" }, - { 0x1fe5, "\x03\xc1\x03\x14\0" }, - { 0x1fe6, "\x03\xc5\x03\x42\0" }, - { 0x1fe7, "\x03\xc5\x03\x08\x03\x42\0" }, - { 0x1fe8, "\x03\xa5\x03\x06\0" }, - { 0x1fe9, "\x03\xa5\x03\x04\0" }, - { 0x1fea, "\x03\xa5\x03\x00\0" }, - { 0x1feb, "\x03\xa5\x03\x01\0" }, - { 0x1fec, "\x03\xa1\x03\x14\0" }, - { 0x1fed, "\x00\xa8\x03\x00\0" }, - { 0x1fee, "\x00\xa8\x03\x01\0" }, - { 0x1fef, "\x00\x60\0" }, - { 0x1ff2, "\x03\xc9\x03\x00\x03\x45\0" }, - { 0x1ff3, "\x03\xc9\x03\x45\0" }, - { 0x1ff4, "\x03\xc9\x03\x01\x03\x45\0" }, - { 0x1ff6, "\x03\xc9\x03\x42\0" }, - { 0x1ff7, "\x03\xc9\x03\x42\x03\x45\0" }, - { 0x1ff8, "\x03\x9f\x03\x00\0" }, - { 0x1ff9, "\x03\x9f\x03\x01\0" }, - { 0x1ffa, "\x03\xa9\x03\x00\0" }, - { 0x1ffb, "\x03\xa9\x03\x01\0" }, - { 0x1ffc, "\x03\xa9\x03\x45\0" }, - { 0x1ffd, "\x00\xb4\0" }, - { 0x2000, "\x20\x02\0" }, - { 0x2001, "\x20\x03\0" }, - { 0x2126, "\x03\xa9\0" }, - { 0x212a, "\x00\x4b\0" }, - { 0x212b, "\x00\x41\x03\x0a\0" }, - { 0x219a, "\x21\x90\x03\x38\0" }, - { 0x219b, "\x21\x92\x03\x38\0" }, - { 0x21ae, "\x21\x94\x03\x38\0" }, - { 0x21cd, "\x21\xd0\x03\x38\0" }, - { 0x21ce, "\x21\xd4\x03\x38\0" }, - { 0x21cf, "\x21\xd2\x03\x38\0" }, - { 0x2204, "\x22\x03\x03\x38\0" }, - { 0x2209, "\x22\x08\x03\x38\0" }, - { 0x220c, "\x22\x0b\x03\x38\0" }, - { 0x2224, "\x22\x23\x03\x38\0" }, - { 0x2226, "\x22\x25\x03\x38\0" }, - { 0x2241, "\x22\x3c\x03\x38\0" }, - { 0x2244, "\x22\x43\x03\x38\0" }, - { 0x2247, "\x22\x45\x03\x38\0" }, - { 0x2249, "\x22\x48\x03\x38\0" }, - { 0x2260, "\x00\x3d\x03\x38\0" }, - { 0x2262, "\x22\x61\x03\x38\0" }, - { 0x226d, "\x22\x4d\x03\x38\0" }, - { 0x226e, "\x00\x3c\x03\x38\0" }, - { 0x226f, "\x00\x3e\x03\x38\0" }, - { 0x2270, "\x22\x64\x03\x38\0" }, - { 0x2271, "\x22\x65\x03\x38\0" }, - { 0x2274, "\x22\x72\x03\x38\0" }, - { 0x2275, "\x22\x73\x03\x38\0" }, - { 0x2278, "\x22\x76\x03\x38\0" }, - { 0x2279, "\x22\x77\x03\x38\0" }, - { 0x2280, "\x22\x7a\x03\x38\0" }, - { 0x2281, "\x22\x7b\x03\x38\0" }, - { 0x2284, "\x22\x82\x03\x38\0" }, - { 0x2285, "\x22\x83\x03\x38\0" }, - { 0x2288, "\x22\x86\x03\x38\0" }, - { 0x2289, "\x22\x87\x03\x38\0" }, - { 0x22ac, "\x22\xa2\x03\x38\0" }, - { 0x22ad, "\x22\xa8\x03\x38\0" }, - { 0x22ae, "\x22\xa9\x03\x38\0" }, - { 0x22af, "\x22\xab\x03\x38\0" }, - { 0x22e0, "\x22\x7c\x03\x38\0" }, - { 0x22e1, "\x22\x7d\x03\x38\0" }, - { 0x22e2, "\x22\x91\x03\x38\0" }, - { 0x22e3, "\x22\x92\x03\x38\0" }, - { 0x22ea, "\x22\xb2\x03\x38\0" }, - { 0x22eb, "\x22\xb3\x03\x38\0" }, - { 0x22ec, "\x22\xb4\x03\x38\0" }, - { 0x22ed, "\x22\xb5\x03\x38\0" }, - { 0x2329, "\x30\x08\0" }, - { 0x232a, "\x30\x09\0" }, - { 0x304c, "\x30\x4b\x30\x99\0" }, - { 0x304e, "\x30\x4d\x30\x99\0" }, - { 0x3050, "\x30\x4f\x30\x99\0" }, - { 0x3052, "\x30\x51\x30\x99\0" }, - { 0x3054, "\x30\x53\x30\x99\0" }, - { 0x3056, "\x30\x55\x30\x99\0" }, - { 0x3058, "\x30\x57\x30\x99\0" }, - { 0x305a, "\x30\x59\x30\x99\0" }, - { 0x305c, "\x30\x5b\x30\x99\0" }, - { 0x305e, "\x30\x5d\x30\x99\0" }, - { 0x3060, "\x30\x5f\x30\x99\0" }, - { 0x3062, "\x30\x61\x30\x99\0" }, - { 0x3065, "\x30\x64\x30\x99\0" }, - { 0x3067, "\x30\x66\x30\x99\0" }, - { 0x3069, "\x30\x68\x30\x99\0" }, - { 0x3070, "\x30\x6f\x30\x99\0" }, - { 0x3071, "\x30\x6f\x30\x9a\0" }, - { 0x3073, "\x30\x72\x30\x99\0" }, - { 0x3074, "\x30\x72\x30\x9a\0" }, - { 0x3076, "\x30\x75\x30\x99\0" }, - { 0x3077, "\x30\x75\x30\x9a\0" }, - { 0x3079, "\x30\x78\x30\x99\0" }, - { 0x307a, "\x30\x78\x30\x9a\0" }, - { 0x307c, "\x30\x7b\x30\x99\0" }, - { 0x307d, "\x30\x7b\x30\x9a\0" }, - { 0x3094, "\x30\x46\x30\x99\0" }, - { 0x309e, "\x30\x9d\x30\x99\0" }, - { 0x30ac, "\x30\xab\x30\x99\0" }, - { 0x30ae, "\x30\xad\x30\x99\0" }, - { 0x30b0, "\x30\xaf\x30\x99\0" }, - { 0x30b2, "\x30\xb1\x30\x99\0" }, - { 0x30b4, "\x30\xb3\x30\x99\0" }, - { 0x30b6, "\x30\xb5\x30\x99\0" }, - { 0x30b8, "\x30\xb7\x30\x99\0" }, - { 0x30ba, "\x30\xb9\x30\x99\0" }, - { 0x30bc, "\x30\xbb\x30\x99\0" }, - { 0x30be, "\x30\xbd\x30\x99\0" }, - { 0x30c0, "\x30\xbf\x30\x99\0" }, - { 0x30c2, "\x30\xc1\x30\x99\0" }, - { 0x30c5, "\x30\xc4\x30\x99\0" }, - { 0x30c7, "\x30\xc6\x30\x99\0" }, - { 0x30c9, "\x30\xc8\x30\x99\0" }, - { 0x30d0, "\x30\xcf\x30\x99\0" }, - { 0x30d1, "\x30\xcf\x30\x9a\0" }, - { 0x30d3, "\x30\xd2\x30\x99\0" }, - { 0x30d4, "\x30\xd2\x30\x9a\0" }, - { 0x30d6, "\x30\xd5\x30\x99\0" }, - { 0x30d7, "\x30\xd5\x30\x9a\0" }, - { 0x30d9, "\x30\xd8\x30\x99\0" }, - { 0x30da, "\x30\xd8\x30\x9a\0" }, - { 0x30dc, "\x30\xdb\x30\x99\0" }, - { 0x30dd, "\x30\xdb\x30\x9a\0" }, - { 0x30f4, "\x30\xa6\x30\x99\0" }, - { 0x30f7, "\x30\xef\x30\x99\0" }, - { 0x30f8, "\x30\xf0\x30\x99\0" }, - { 0x30f9, "\x30\xf1\x30\x99\0" }, - { 0x30fa, "\x30\xf2\x30\x99\0" }, - { 0x30fe, "\x30\xfd\x30\x99\0" }, - { 0xf900, "\x8c\x48\0" }, - { 0xf901, "\x66\xf4\0" }, - { 0xf902, "\x8e\xca\0" }, - { 0xf903, "\x8c\xc8\0" }, - { 0xf904, "\x6e\xd1\0" }, - { 0xf905, "\x4e\x32\0" }, - { 0xf906, "\x53\xe5\0" }, - { 0xf907, "\x9f\x9c\0" }, - { 0xf908, "\x9f\x9c\0" }, - { 0xf909, "\x59\x51\0" }, - { 0xf90a, "\x91\xd1\0" }, - { 0xf90b, "\x55\x87\0" }, - { 0xf90c, "\x59\x48\0" }, - { 0xf90d, "\x61\xf6\0" }, - { 0xf90e, "\x76\x69\0" }, - { 0xf90f, "\x7f\x85\0" }, - { 0xf910, "\x86\x3f\0" }, - { 0xf911, "\x87\xba\0" }, - { 0xf912, "\x88\xf8\0" }, - { 0xf913, "\x90\x8f\0" }, - { 0xf914, "\x6a\x02\0" }, - { 0xf915, "\x6d\x1b\0" }, - { 0xf916, "\x70\xd9\0" }, - { 0xf917, "\x73\xde\0" }, - { 0xf918, "\x84\x3d\0" }, - { 0xf919, "\x91\x6a\0" }, - { 0xf91a, "\x99\xf1\0" }, - { 0xf91b, "\x4e\x82\0" }, - { 0xf91c, "\x53\x75\0" }, - { 0xf91d, "\x6b\x04\0" }, - { 0xf91e, "\x72\x1b\0" }, - { 0xf91f, "\x86\x2d\0" }, - { 0xf920, "\x9e\x1e\0" }, - { 0xf921, "\x5d\x50\0" }, - { 0xf922, "\x6f\xeb\0" }, - { 0xf923, "\x85\xcd\0" }, - { 0xf924, "\x89\x64\0" }, - { 0xf925, "\x62\xc9\0" }, - { 0xf926, "\x81\xd8\0" }, - { 0xf927, "\x88\x1f\0" }, - { 0xf928, "\x5e\xca\0" }, - { 0xf929, "\x67\x17\0" }, - { 0xf92a, "\x6d\x6a\0" }, - { 0xf92b, "\x72\xfc\0" }, - { 0xf92c, "\x90\xce\0" }, - { 0xf92d, "\x4f\x86\0" }, - { 0xf92e, "\x51\xb7\0" }, - { 0xf92f, "\x52\xde\0" }, - { 0xf930, "\x64\xc4\0" }, - { 0xf931, "\x6a\xd3\0" }, - { 0xf932, "\x72\x10\0" }, - { 0xf933, "\x76\xe7\0" }, - { 0xf934, "\x80\x01\0" }, - { 0xf935, "\x86\x06\0" }, - { 0xf936, "\x86\x5c\0" }, - { 0xf937, "\x8d\xef\0" }, - { 0xf938, "\x97\x32\0" }, - { 0xf939, "\x9b\x6f\0" }, - { 0xf93a, "\x9d\xfa\0" }, - { 0xf93b, "\x78\x8c\0" }, - { 0xf93c, "\x79\x7f\0" }, - { 0xf93d, "\x7d\xa0\0" }, - { 0xf93e, "\x83\xc9\0" }, - { 0xf93f, "\x93\x04\0" }, - { 0xf940, "\x9e\x7f\0" }, - { 0xf941, "\x8a\xd6\0" }, - { 0xf942, "\x58\xdf\0" }, - { 0xf943, "\x5f\x04\0" }, - { 0xf944, "\x7c\x60\0" }, - { 0xf945, "\x80\x7e\0" }, - { 0xf946, "\x72\x62\0" }, - { 0xf947, "\x78\xca\0" }, - { 0xf948, "\x8c\xc2\0" }, - { 0xf949, "\x96\xf7\0" }, - { 0xf94a, "\x58\xd8\0" }, - { 0xf94b, "\x5c\x62\0" }, - { 0xf94c, "\x6a\x13\0" }, - { 0xf94d, "\x6d\xda\0" }, - { 0xf94e, "\x6f\x0f\0" }, - { 0xf94f, "\x7d\x2f\0" }, - { 0xf950, "\x7e\x37\0" }, - { 0xf951, "\x96\xfb\0" }, - { 0xf952, "\x52\xd2\0" }, - { 0xf953, "\x80\x8b\0" }, - { 0xf954, "\x51\xdc\0" }, - { 0xf955, "\x51\xcc\0" }, - { 0xf956, "\x7a\x1c\0" }, - { 0xf957, "\x7d\xbe\0" }, - { 0xf958, "\x83\xf1\0" }, - { 0xf959, "\x96\x75\0" }, - { 0xf95a, "\x8b\x80\0" }, - { 0xf95b, "\x62\xcf\0" }, - { 0xf95c, "\x6a\x02\0" }, - { 0xf95d, "\x8a\xfe\0" }, - { 0xf95e, "\x4e\x39\0" }, - { 0xf95f, "\x5b\xe7\0" }, - { 0xf960, "\x60\x12\0" }, - { 0xf961, "\x73\x87\0" }, - { 0xf962, "\x75\x70\0" }, - { 0xf963, "\x53\x17\0" }, - { 0xf964, "\x78\xfb\0" }, - { 0xf965, "\x4f\xbf\0" }, - { 0xf966, "\x5f\xa9\0" }, - { 0xf967, "\x4e\x0d\0" }, - { 0xf968, "\x6c\xcc\0" }, - { 0xf969, "\x65\x78\0" }, - { 0xf96a, "\x7d\x22\0" }, - { 0xf96b, "\x53\xc3\0" }, - { 0xf96c, "\x58\x5e\0" }, - { 0xf96d, "\x77\x01\0" }, - { 0xf96e, "\x84\x49\0" }, - { 0xf96f, "\x8a\xaa\0" }, - { 0xf970, "\x6b\xba\0" }, - { 0xf971, "\x8f\xb0\0" }, - { 0xf972, "\x6c\x88\0" }, - { 0xf973, "\x62\xfe\0" }, - { 0xf974, "\x82\xe5\0" }, - { 0xf975, "\x63\xa0\0" }, - { 0xf976, "\x75\x65\0" }, - { 0xf977, "\x4e\xae\0" }, - { 0xf978, "\x51\x69\0" }, - { 0xf979, "\x51\xc9\0" }, - { 0xf97a, "\x68\x81\0" }, - { 0xf97b, "\x7c\xe7\0" }, - { 0xf97c, "\x82\x6f\0" }, - { 0xf97d, "\x8a\xd2\0" }, - { 0xf97e, "\x91\xcf\0" }, - { 0xf97f, "\x52\xf5\0" }, - { 0xf980, "\x54\x42\0" }, - { 0xf981, "\x59\x73\0" }, - { 0xf982, "\x5e\xec\0" }, - { 0xf983, "\x65\xc5\0" }, - { 0xf984, "\x6f\xfe\0" }, - { 0xf985, "\x79\x2a\0" }, - { 0xf986, "\x95\xad\0" }, - { 0xf987, "\x9a\x6a\0" }, - { 0xf988, "\x9e\x97\0" }, - { 0xf989, "\x9e\xce\0" }, - { 0xf98a, "\x52\x9b\0" }, - { 0xf98b, "\x66\xc6\0" }, - { 0xf98c, "\x6b\x77\0" }, - { 0xf98d, "\x8f\x62\0" }, - { 0xf98e, "\x5e\x74\0" }, - { 0xf98f, "\x61\x90\0" }, - { 0xf990, "\x62\x00\0" }, - { 0xf991, "\x64\x9a\0" }, - { 0xf992, "\x6f\x23\0" }, - { 0xf993, "\x71\x49\0" }, - { 0xf994, "\x74\x89\0" }, - { 0xf995, "\x79\xca\0" }, - { 0xf996, "\x7d\xf4\0" }, - { 0xf997, "\x80\x6f\0" }, - { 0xf998, "\x8f\x26\0" }, - { 0xf999, "\x84\xee\0" }, - { 0xf99a, "\x90\x23\0" }, - { 0xf99b, "\x93\x4a\0" }, - { 0xf99c, "\x52\x17\0" }, - { 0xf99d, "\x52\xa3\0" }, - { 0xf99e, "\x54\xbd\0" }, - { 0xf99f, "\x70\xc8\0" }, - { 0xf9a0, "\x88\xc2\0" }, - { 0xf9a1, "\x8a\xaa\0" }, - { 0xf9a2, "\x5e\xc9\0" }, - { 0xf9a3, "\x5f\xf5\0" }, - { 0xf9a4, "\x63\x7b\0" }, - { 0xf9a5, "\x6b\xae\0" }, - { 0xf9a6, "\x7c\x3e\0" }, - { 0xf9a7, "\x73\x75\0" }, - { 0xf9a8, "\x4e\xe4\0" }, - { 0xf9a9, "\x56\xf9\0" }, - { 0xf9aa, "\x5b\xe7\0" }, - { 0xf9ab, "\x5d\xba\0" }, - { 0xf9ac, "\x60\x1c\0" }, - { 0xf9ad, "\x73\xb2\0" }, - { 0xf9ae, "\x74\x69\0" }, - { 0xf9af, "\x7f\x9a\0" }, - { 0xf9b0, "\x80\x46\0" }, - { 0xf9b1, "\x92\x34\0" }, - { 0xf9b2, "\x96\xf6\0" }, - { 0xf9b3, "\x97\x48\0" }, - { 0xf9b4, "\x98\x18\0" }, - { 0xf9b5, "\x4f\x8b\0" }, - { 0xf9b6, "\x79\xae\0" }, - { 0xf9b7, "\x91\xb4\0" }, - { 0xf9b8, "\x96\xb8\0" }, - { 0xf9b9, "\x60\xe1\0" }, - { 0xf9ba, "\x4e\x86\0" }, - { 0xf9bb, "\x50\xda\0" }, - { 0xf9bc, "\x5b\xee\0" }, - { 0xf9bd, "\x5c\x3f\0" }, - { 0xf9be, "\x65\x99\0" }, - { 0xf9bf, "\x6a\x02\0" }, - { 0xf9c0, "\x71\xce\0" }, - { 0xf9c1, "\x76\x42\0" }, - { 0xf9c2, "\x84\xfc\0" }, - { 0xf9c3, "\x90\x7c\0" }, - { 0xf9c4, "\x9f\x8d\0" }, - { 0xf9c5, "\x66\x88\0" }, - { 0xf9c6, "\x96\x2e\0" }, - { 0xf9c7, "\x52\x89\0" }, - { 0xf9c8, "\x67\x7b\0" }, - { 0xf9c9, "\x67\xf3\0" }, - { 0xf9ca, "\x6d\x41\0" }, - { 0xf9cb, "\x6e\x9c\0" }, - { 0xf9cc, "\x74\x09\0" }, - { 0xf9cd, "\x75\x59\0" }, - { 0xf9ce, "\x78\x6b\0" }, - { 0xf9cf, "\x7d\x10\0" }, - { 0xf9d0, "\x98\x5e\0" }, - { 0xf9d1, "\x51\x6d\0" }, - { 0xf9d2, "\x62\x2e\0" }, - { 0xf9d3, "\x96\x78\0" }, - { 0xf9d4, "\x50\x2b\0" }, - { 0xf9d5, "\x5d\x19\0" }, - { 0xf9d6, "\x6d\xea\0" }, - { 0xf9d7, "\x8f\x2a\0" }, - { 0xf9d8, "\x5f\x8b\0" }, - { 0xf9d9, "\x61\x44\0" }, - { 0xf9da, "\x68\x17\0" }, - { 0xf9db, "\x73\x87\0" }, - { 0xf9dc, "\x96\x86\0" }, - { 0xf9dd, "\x52\x29\0" }, - { 0xf9de, "\x54\x0f\0" }, - { 0xf9df, "\x5c\x65\0" }, - { 0xf9e0, "\x66\x13\0" }, - { 0xf9e1, "\x67\x4e\0" }, - { 0xf9e2, "\x68\xa8\0" }, - { 0xf9e3, "\x6c\xe5\0" }, - { 0xf9e4, "\x74\x06\0" }, - { 0xf9e5, "\x75\xe2\0" }, - { 0xf9e6, "\x7f\x79\0" }, - { 0xf9e7, "\x88\xcf\0" }, - { 0xf9e8, "\x88\xe1\0" }, - { 0xf9e9, "\x91\xcc\0" }, - { 0xf9ea, "\x96\xe2\0" }, - { 0xf9eb, "\x53\x3f\0" }, - { 0xf9ec, "\x6e\xba\0" }, - { 0xf9ed, "\x54\x1d\0" }, - { 0xf9ee, "\x71\xd0\0" }, - { 0xf9ef, "\x74\x98\0" }, - { 0xf9f0, "\x85\xfa\0" }, - { 0xf9f1, "\x96\xa3\0" }, - { 0xf9f2, "\x9c\x57\0" }, - { 0xf9f3, "\x9e\x9f\0" }, - { 0xf9f4, "\x67\x97\0" }, - { 0xf9f5, "\x6d\xcb\0" }, - { 0xf9f6, "\x81\xe8\0" }, - { 0xf9f7, "\x7a\xcb\0" }, - { 0xf9f8, "\x7b\x20\0" }, - { 0xf9f9, "\x7c\x92\0" }, - { 0xf9fa, "\x72\xc0\0" }, - { 0xf9fb, "\x70\x99\0" }, - { 0xf9fc, "\x8b\x58\0" }, - { 0xf9fd, "\x4e\xc0\0" }, - { 0xf9fe, "\x83\x36\0" }, - { 0xf9ff, "\x52\x3a\0" }, - { 0xfa00, "\x52\x07\0" }, - { 0xfa01, "\x5e\xa6\0" }, - { 0xfa02, "\x62\xd3\0" }, - { 0xfa03, "\x7c\xd6\0" }, - { 0xfa04, "\x5b\x85\0" }, - { 0xfa05, "\x6d\x1e\0" }, - { 0xfa06, "\x66\xb4\0" }, - { 0xfa07, "\x8f\x3b\0" }, - { 0xfa08, "\x88\x4c\0" }, - { 0xfa09, "\x96\x4d\0" }, - { 0xfa0a, "\x89\x8b\0" }, - { 0xfa0b, "\x5e\xd3\0" }, - { 0xfa0c, "\x51\x40\0" }, - { 0xfa0d, "\x55\xc0\0" }, - { 0xfa10, "\x58\x5a\0" }, - { 0xfa12, "\x66\x74\0" }, - { 0xfa15, "\x51\xde\0" }, - { 0xfa16, "\x73\x2a\0" }, - { 0xfa17, "\x76\xca\0" }, - { 0xfa18, "\x79\x3c\0" }, - { 0xfa19, "\x79\x5e\0" }, - { 0xfa1a, "\x79\x65\0" }, - { 0xfa1b, "\x79\x8f\0" }, - { 0xfa1c, "\x97\x56\0" }, - { 0xfa1d, "\x7c\xbe\0" }, - { 0xfa1e, "\x7f\xbd\0" }, - { 0xfa20, "\x86\x12\0" }, - { 0xfa22, "\x8a\xf8\0" }, - { 0xfa25, "\x90\x38\0" }, - { 0xfa26, "\x90\xfd\0" }, - { 0xfa2a, "\x98\xef\0" }, - { 0xfa2b, "\x98\xfc\0" }, - { 0xfa2c, "\x99\x28\0" }, - { 0xfa2d, "\x9d\xb4\0" }, - { 0xfb1d, "\x05\xd9\x05\xb4\0" }, - { 0xfb1f, "\x05\xf2\x05\xb7\0" }, - { 0xfb2a, "\x05\xe9\x05\xc1\0" }, - { 0xfb2b, "\x05\xe9\x05\xc2\0" }, - { 0xfb2c, "\x05\xe9\x05\xbc\x05\xc1\0" }, - { 0xfb2d, "\x05\xe9\x05\xbc\x05\xc2\0" }, - { 0xfb2e, "\x05\xd0\x05\xb7\0" }, - { 0xfb2f, "\x05\xd0\x05\xb8\0" }, - { 0xfb30, "\x05\xd0\x05\xbc\0" }, - { 0xfb31, "\x05\xd1\x05\xbc\0" }, - { 0xfb32, "\x05\xd2\x05\xbc\0" }, - { 0xfb33, "\x05\xd3\x05\xbc\0" }, - { 0xfb34, "\x05\xd4\x05\xbc\0" }, - { 0xfb35, "\x05\xd5\x05\xbc\0" }, - { 0xfb36, "\x05\xd6\x05\xbc\0" }, - { 0xfb38, "\x05\xd8\x05\xbc\0" }, - { 0xfb39, "\x05\xd9\x05\xbc\0" }, - { 0xfb3a, "\x05\xda\x05\xbc\0" }, - { 0xfb3b, "\x05\xdb\x05\xbc\0" }, - { 0xfb3c, "\x05\xdc\x05\xbc\0" }, - { 0xfb3e, "\x05\xde\x05\xbc\0" }, - { 0xfb40, "\x05\xe0\x05\xbc\0" }, - { 0xfb41, "\x05\xe1\x05\xbc\0" }, - { 0xfb43, "\x05\xe3\x05\xbc\0" }, - { 0xfb44, "\x05\xe4\x05\xbc\0" }, - { 0xfb46, "\x05\xe6\x05\xbc\0" }, - { 0xfb47, "\x05\xe7\x05\xbc\0" }, - { 0xfb48, "\x05\xe8\x05\xbc\0" }, - { 0xfb49, "\x05\xe9\x05\xbc\0" }, - { 0xfb4a, "\x05\xea\x05\xbc\0" }, - { 0xfb4b, "\x05\xd5\x05\xb9\0" }, - { 0xfb4c, "\x05\xd1\x05\xbf\0" }, - { 0xfb4d, "\x05\xdb\x05\xbf\0" }, - { 0xfb4e, "\x05\xe4\x05\xbf\0" } + { 0x00a0, 255, 0, "\x00\x20\0" }, + { 0x00a8, 255, 0, "\x00\x20\x03\x08\0" }, + { 0x00aa, 255, 0, "\x00\x61\0" }, + { 0x00af, 255, 0, "\x00\x20\x03\x04\0" }, + { 0x00b2, 255, 0, "\x00\x32\0" }, + { 0x00b3, 255, 0, "\x00\x33\0" }, + { 0x00b4, 255, 0, "\x00\x20\x03\x01\0" }, + { 0x00b5, 255, 0, "\x03\xbc\0" }, + { 0x00b8, 255, 0, "\x00\x20\x03\x27\0" }, + { 0x00b9, 255, 0, "\x00\x31\0" }, + { 0x00ba, 255, 0, "\x00\x6f\0" }, + { 0x00bc, 255, 0, "\x00\x31\x20\x44\x00\x34\0" }, + { 0x00bd, 255, 0, "\x00\x31\x20\x44\x00\x32\0" }, + { 0x00be, 255, 0, "\x00\x33\x20\x44\x00\x34\0" }, + { 0x00c0, 0, 255, "\x00\x41\x03\x00\0" }, + { 0x00c1, 0, 255, "\x00\x41\x03\x01\0" }, + { 0x00c2, 0, 255, "\x00\x41\x03\x02\0" }, + { 0x00c3, 0, 255, "\x00\x41\x03\x03\0" }, + { 0x00c4, 0, 255, "\x00\x41\x03\x08\0" }, + { 0x00c5, 0, 255, "\x00\x41\x03\x0a\0" }, + { 0x00c7, 0, 255, "\x00\x43\x03\x27\0" }, + { 0x00c8, 0, 255, "\x00\x45\x03\x00\0" }, + { 0x00c9, 0, 255, "\x00\x45\x03\x01\0" }, + { 0x00ca, 0, 255, "\x00\x45\x03\x02\0" }, + { 0x00cb, 0, 255, "\x00\x45\x03\x08\0" }, + { 0x00cc, 0, 255, "\x00\x49\x03\x00\0" }, + { 0x00cd, 0, 255, "\x00\x49\x03\x01\0" }, + { 0x00ce, 0, 255, "\x00\x49\x03\x02\0" }, + { 0x00cf, 0, 255, "\x00\x49\x03\x08\0" }, + { 0x00d1, 0, 255, "\x00\x4e\x03\x03\0" }, + { 0x00d2, 0, 255, "\x00\x4f\x03\x00\0" }, + { 0x00d3, 0, 255, "\x00\x4f\x03\x01\0" }, + { 0x00d4, 0, 255, "\x00\x4f\x03\x02\0" }, + { 0x00d5, 0, 255, "\x00\x4f\x03\x03\0" }, + { 0x00d6, 0, 255, "\x00\x4f\x03\x08\0" }, + { 0x00d9, 0, 255, "\x00\x55\x03\x00\0" }, + { 0x00da, 0, 255, "\x00\x55\x03\x01\0" }, + { 0x00db, 0, 255, "\x00\x55\x03\x02\0" }, + { 0x00dc, 0, 255, "\x00\x55\x03\x08\0" }, + { 0x00dd, 0, 255, "\x00\x59\x03\x01\0" }, + { 0x00e0, 0, 255, "\x00\x61\x03\x00\0" }, + { 0x00e1, 0, 255, "\x00\x61\x03\x01\0" }, + { 0x00e2, 0, 255, "\x00\x61\x03\x02\0" }, + { 0x00e3, 0, 255, "\x00\x61\x03\x03\0" }, + { 0x00e4, 0, 255, "\x00\x61\x03\x08\0" }, + { 0x00e5, 0, 255, "\x00\x61\x03\x0a\0" }, + { 0x00e7, 0, 255, "\x00\x63\x03\x27\0" }, + { 0x00e8, 0, 255, "\x00\x65\x03\x00\0" }, + { 0x00e9, 0, 255, "\x00\x65\x03\x01\0" }, + { 0x00ea, 0, 255, "\x00\x65\x03\x02\0" }, + { 0x00eb, 0, 255, "\x00\x65\x03\x08\0" }, + { 0x00ec, 0, 255, "\x00\x69\x03\x00\0" }, + { 0x00ed, 0, 255, "\x00\x69\x03\x01\0" }, + { 0x00ee, 0, 255, "\x00\x69\x03\x02\0" }, + { 0x00ef, 0, 255, "\x00\x69\x03\x08\0" }, + { 0x00f1, 0, 255, "\x00\x6e\x03\x03\0" }, + { 0x00f2, 0, 255, "\x00\x6f\x03\x00\0" }, + { 0x00f3, 0, 255, "\x00\x6f\x03\x01\0" }, + { 0x00f4, 0, 255, "\x00\x6f\x03\x02\0" }, + { 0x00f5, 0, 255, "\x00\x6f\x03\x03\0" }, + { 0x00f6, 0, 255, "\x00\x6f\x03\x08\0" }, + { 0x00f9, 0, 255, "\x00\x75\x03\x00\0" }, + { 0x00fa, 0, 255, "\x00\x75\x03\x01\0" }, + { 0x00fb, 0, 255, "\x00\x75\x03\x02\0" }, + { 0x00fc, 0, 255, "\x00\x75\x03\x08\0" }, + { 0x00fd, 0, 255, "\x00\x79\x03\x01\0" }, + { 0x00ff, 0, 255, "\x00\x79\x03\x08\0" }, + { 0x0100, 0, 255, "\x00\x41\x03\x04\0" }, + { 0x0101, 0, 255, "\x00\x61\x03\x04\0" }, + { 0x0102, 0, 255, "\x00\x41\x03\x06\0" }, + { 0x0103, 0, 255, "\x00\x61\x03\x06\0" }, + { 0x0104, 0, 255, "\x00\x41\x03\x28\0" }, + { 0x0105, 0, 255, "\x00\x61\x03\x28\0" }, + { 0x0106, 0, 255, "\x00\x43\x03\x01\0" }, + { 0x0107, 0, 255, "\x00\x63\x03\x01\0" }, + { 0x0108, 0, 255, "\x00\x43\x03\x02\0" }, + { 0x0109, 0, 255, "\x00\x63\x03\x02\0" }, + { 0x010a, 0, 255, "\x00\x43\x03\x07\0" }, + { 0x010b, 0, 255, "\x00\x63\x03\x07\0" }, + { 0x010c, 0, 255, "\x00\x43\x03\x0c\0" }, + { 0x010d, 0, 255, "\x00\x63\x03\x0c\0" }, + { 0x010e, 0, 255, "\x00\x44\x03\x0c\0" }, + { 0x010f, 0, 255, "\x00\x64\x03\x0c\0" }, + { 0x0112, 0, 255, "\x00\x45\x03\x04\0" }, + { 0x0113, 0, 255, "\x00\x65\x03\x04\0" }, + { 0x0114, 0, 255, "\x00\x45\x03\x06\0" }, + { 0x0115, 0, 255, "\x00\x65\x03\x06\0" }, + { 0x0116, 0, 255, "\x00\x45\x03\x07\0" }, + { 0x0117, 0, 255, "\x00\x65\x03\x07\0" }, + { 0x0118, 0, 255, "\x00\x45\x03\x28\0" }, + { 0x0119, 0, 255, "\x00\x65\x03\x28\0" }, + { 0x011a, 0, 255, "\x00\x45\x03\x0c\0" }, + { 0x011b, 0, 255, "\x00\x65\x03\x0c\0" }, + { 0x011c, 0, 255, "\x00\x47\x03\x02\0" }, + { 0x011d, 0, 255, "\x00\x67\x03\x02\0" }, + { 0x011e, 0, 255, "\x00\x47\x03\x06\0" }, + { 0x011f, 0, 255, "\x00\x67\x03\x06\0" }, + { 0x0120, 0, 255, "\x00\x47\x03\x07\0" }, + { 0x0121, 0, 255, "\x00\x67\x03\x07\0" }, + { 0x0122, 0, 255, "\x00\x47\x03\x27\0" }, + { 0x0123, 0, 255, "\x00\x67\x03\x27\0" }, + { 0x0124, 0, 255, "\x00\x48\x03\x02\0" }, + { 0x0125, 0, 255, "\x00\x68\x03\x02\0" }, + { 0x0128, 0, 255, "\x00\x49\x03\x03\0" }, + { 0x0129, 0, 255, "\x00\x69\x03\x03\0" }, + { 0x012a, 0, 255, "\x00\x49\x03\x04\0" }, + { 0x012b, 0, 255, "\x00\x69\x03\x04\0" }, + { 0x012c, 0, 255, "\x00\x49\x03\x06\0" }, + { 0x012d, 0, 255, "\x00\x69\x03\x06\0" }, + { 0x012e, 0, 255, "\x00\x49\x03\x28\0" }, + { 0x012f, 0, 255, "\x00\x69\x03\x28\0" }, + { 0x0130, 0, 255, "\x00\x49\x03\x07\0" }, + { 0x0132, 255, 0, "\x00\x49\x00\x4a\0" }, + { 0x0133, 255, 0, "\x00\x69\x00\x6a\0" }, + { 0x0134, 0, 255, "\x00\x4a\x03\x02\0" }, + { 0x0135, 0, 255, "\x00\x6a\x03\x02\0" }, + { 0x0136, 0, 255, "\x00\x4b\x03\x27\0" }, + { 0x0137, 0, 255, "\x00\x6b\x03\x27\0" }, + { 0x0139, 0, 255, "\x00\x4c\x03\x01\0" }, + { 0x013a, 0, 255, "\x00\x6c\x03\x01\0" }, + { 0x013b, 0, 255, "\x00\x4c\x03\x27\0" }, + { 0x013c, 0, 255, "\x00\x6c\x03\x27\0" }, + { 0x013d, 0, 255, "\x00\x4c\x03\x0c\0" }, + { 0x013e, 0, 255, "\x00\x6c\x03\x0c\0" }, + { 0x013f, 255, 0, "\x00\x4c\x00\xb7\0" }, + { 0x0140, 255, 0, "\x00\x6c\x00\xb7\0" }, + { 0x0143, 0, 255, "\x00\x4e\x03\x01\0" }, + { 0x0144, 0, 255, "\x00\x6e\x03\x01\0" }, + { 0x0145, 0, 255, "\x00\x4e\x03\x27\0" }, + { 0x0146, 0, 255, "\x00\x6e\x03\x27\0" }, + { 0x0147, 0, 255, "\x00\x4e\x03\x0c\0" }, + { 0x0148, 0, 255, "\x00\x6e\x03\x0c\0" }, + { 0x0149, 255, 0, "\x02\xbc\x00\x6e\0" }, + { 0x014c, 0, 255, "\x00\x4f\x03\x04\0" }, + { 0x014d, 0, 255, "\x00\x6f\x03\x04\0" }, + { 0x014e, 0, 255, "\x00\x4f\x03\x06\0" }, + { 0x014f, 0, 255, "\x00\x6f\x03\x06\0" }, + { 0x0150, 0, 255, "\x00\x4f\x03\x0b\0" }, + { 0x0151, 0, 255, "\x00\x6f\x03\x0b\0" }, + { 0x0154, 0, 255, "\x00\x52\x03\x01\0" }, + { 0x0155, 0, 255, "\x00\x72\x03\x01\0" }, + { 0x0156, 0, 255, "\x00\x52\x03\x27\0" }, + { 0x0157, 0, 255, "\x00\x72\x03\x27\0" }, + { 0x0158, 0, 255, "\x00\x52\x03\x0c\0" }, + { 0x0159, 0, 255, "\x00\x72\x03\x0c\0" }, + { 0x015a, 0, 255, "\x00\x53\x03\x01\0" }, + { 0x015b, 0, 255, "\x00\x73\x03\x01\0" }, + { 0x015c, 0, 255, "\x00\x53\x03\x02\0" }, + { 0x015d, 0, 255, "\x00\x73\x03\x02\0" }, + { 0x015e, 0, 255, "\x00\x53\x03\x27\0" }, + { 0x015f, 0, 255, "\x00\x73\x03\x27\0" }, + { 0x0160, 0, 255, "\x00\x53\x03\x0c\0" }, + { 0x0161, 0, 255, "\x00\x73\x03\x0c\0" }, + { 0x0162, 0, 255, "\x00\x54\x03\x27\0" }, + { 0x0163, 0, 255, "\x00\x74\x03\x27\0" }, + { 0x0164, 0, 255, "\x00\x54\x03\x0c\0" }, + { 0x0165, 0, 255, "\x00\x74\x03\x0c\0" }, + { 0x0168, 0, 255, "\x00\x55\x03\x03\0" }, + { 0x0169, 0, 255, "\x00\x75\x03\x03\0" }, + { 0x016a, 0, 255, "\x00\x55\x03\x04\0" }, + { 0x016b, 0, 255, "\x00\x75\x03\x04\0" }, + { 0x016c, 0, 255, "\x00\x55\x03\x06\0" }, + { 0x016d, 0, 255, "\x00\x75\x03\x06\0" }, + { 0x016e, 0, 255, "\x00\x55\x03\x0a\0" }, + { 0x016f, 0, 255, "\x00\x75\x03\x0a\0" }, + { 0x0170, 0, 255, "\x00\x55\x03\x0b\0" }, + { 0x0171, 0, 255, "\x00\x75\x03\x0b\0" }, + { 0x0172, 0, 255, "\x00\x55\x03\x28\0" }, + { 0x0173, 0, 255, "\x00\x75\x03\x28\0" }, + { 0x0174, 0, 255, "\x00\x57\x03\x02\0" }, + { 0x0175, 0, 255, "\x00\x77\x03\x02\0" }, + { 0x0176, 0, 255, "\x00\x59\x03\x02\0" }, + { 0x0177, 0, 255, "\x00\x79\x03\x02\0" }, + { 0x0178, 0, 255, "\x00\x59\x03\x08\0" }, + { 0x0179, 0, 255, "\x00\x5a\x03\x01\0" }, + { 0x017a, 0, 255, "\x00\x7a\x03\x01\0" }, + { 0x017b, 0, 255, "\x00\x5a\x03\x07\0" }, + { 0x017c, 0, 255, "\x00\x7a\x03\x07\0" }, + { 0x017d, 0, 255, "\x00\x5a\x03\x0c\0" }, + { 0x017e, 0, 255, "\x00\x7a\x03\x0c\0" }, + { 0x017f, 255, 0, "\x00\x73\0" }, + { 0x01a0, 0, 255, "\x00\x4f\x03\x1b\0" }, + { 0x01a1, 0, 255, "\x00\x6f\x03\x1b\0" }, + { 0x01af, 0, 255, "\x00\x55\x03\x1b\0" }, + { 0x01b0, 0, 255, "\x00\x75\x03\x1b\0" }, + { 0x01c4, 255, 0, "\x00\x44\x00\x5a\x03\x0c\0" }, + { 0x01c5, 255, 0, "\x00\x44\x00\x7a\x03\x0c\0" }, + { 0x01c6, 255, 0, "\x00\x64\x00\x7a\x03\x0c\0" }, + { 0x01c7, 255, 0, "\x00\x4c\x00\x4a\0" }, + { 0x01c8, 255, 0, "\x00\x4c\x00\x6a\0" }, + { 0x01c9, 255, 0, "\x00\x6c\x00\x6a\0" }, + { 0x01ca, 255, 0, "\x00\x4e\x00\x4a\0" }, + { 0x01cb, 255, 0, "\x00\x4e\x00\x6a\0" }, + { 0x01cc, 255, 0, "\x00\x6e\x00\x6a\0" }, + { 0x01cd, 0, 255, "\x00\x41\x03\x0c\0" }, + { 0x01ce, 0, 255, "\x00\x61\x03\x0c\0" }, + { 0x01cf, 0, 255, "\x00\x49\x03\x0c\0" }, + { 0x01d0, 0, 255, "\x00\x69\x03\x0c\0" }, + { 0x01d1, 0, 255, "\x00\x4f\x03\x0c\0" }, + { 0x01d2, 0, 255, "\x00\x6f\x03\x0c\0" }, + { 0x01d3, 0, 255, "\x00\x55\x03\x0c\0" }, + { 0x01d4, 0, 255, "\x00\x75\x03\x0c\0" }, + { 0x01d5, 0, 255, "\x00\x55\x03\x08\x03\x04\0" }, + { 0x01d6, 0, 255, "\x00\x75\x03\x08\x03\x04\0" }, + { 0x01d7, 0, 255, "\x00\x55\x03\x08\x03\x01\0" }, + { 0x01d8, 0, 255, "\x00\x75\x03\x08\x03\x01\0" }, + { 0x01d9, 0, 255, "\x00\x55\x03\x08\x03\x0c\0" }, + { 0x01da, 0, 255, "\x00\x75\x03\x08\x03\x0c\0" }, + { 0x01db, 0, 255, "\x00\x55\x03\x08\x03\x00\0" }, + { 0x01dc, 0, 255, "\x00\x75\x03\x08\x03\x00\0" }, + { 0x01de, 0, 255, "\x00\x41\x03\x08\x03\x04\0" }, + { 0x01df, 0, 255, "\x00\x61\x03\x08\x03\x04\0" }, + { 0x01e0, 0, 255, "\x00\x41\x03\x07\x03\x04\0" }, + { 0x01e1, 0, 255, "\x00\x61\x03\x07\x03\x04\0" }, + { 0x01e2, 0, 255, "\x00\xc6\x03\x04\0" }, + { 0x01e3, 0, 255, "\x00\xe6\x03\x04\0" }, + { 0x01e6, 0, 255, "\x00\x47\x03\x0c\0" }, + { 0x01e7, 0, 255, "\x00\x67\x03\x0c\0" }, + { 0x01e8, 0, 255, "\x00\x4b\x03\x0c\0" }, + { 0x01e9, 0, 255, "\x00\x6b\x03\x0c\0" }, + { 0x01ea, 0, 255, "\x00\x4f\x03\x28\0" }, + { 0x01eb, 0, 255, "\x00\x6f\x03\x28\0" }, + { 0x01ec, 0, 255, "\x00\x4f\x03\x28\x03\x04\0" }, + { 0x01ed, 0, 255, "\x00\x6f\x03\x28\x03\x04\0" }, + { 0x01ee, 0, 255, "\x01\xb7\x03\x0c\0" }, + { 0x01ef, 0, 255, "\x02\x92\x03\x0c\0" }, + { 0x01f0, 0, 255, "\x00\x6a\x03\x0c\0" }, + { 0x01f1, 255, 0, "\x00\x44\x00\x5a\0" }, + { 0x01f2, 255, 0, "\x00\x44\x00\x7a\0" }, + { 0x01f3, 255, 0, "\x00\x64\x00\x7a\0" }, + { 0x01f4, 0, 255, "\x00\x47\x03\x01\0" }, + { 0x01f5, 0, 255, "\x00\x67\x03\x01\0" }, + { 0x01f8, 0, 255, "\x00\x4e\x03\x00\0" }, + { 0x01f9, 0, 255, "\x00\x6e\x03\x00\0" }, + { 0x01fa, 0, 255, "\x00\x41\x03\x0a\x03\x01\0" }, + { 0x01fb, 0, 255, "\x00\x61\x03\x0a\x03\x01\0" }, + { 0x01fc, 0, 255, "\x00\xc6\x03\x01\0" }, + { 0x01fd, 0, 255, "\x00\xe6\x03\x01\0" }, + { 0x01fe, 0, 255, "\x00\xd8\x03\x01\0" }, + { 0x01ff, 0, 255, "\x00\xf8\x03\x01\0" }, + { 0x0200, 0, 255, "\x00\x41\x03\x0f\0" }, + { 0x0201, 0, 255, "\x00\x61\x03\x0f\0" }, + { 0x0202, 0, 255, "\x00\x41\x03\x11\0" }, + { 0x0203, 0, 255, "\x00\x61\x03\x11\0" }, + { 0x0204, 0, 255, "\x00\x45\x03\x0f\0" }, + { 0x0205, 0, 255, "\x00\x65\x03\x0f\0" }, + { 0x0206, 0, 255, "\x00\x45\x03\x11\0" }, + { 0x0207, 0, 255, "\x00\x65\x03\x11\0" }, + { 0x0208, 0, 255, "\x00\x49\x03\x0f\0" }, + { 0x0209, 0, 255, "\x00\x69\x03\x0f\0" }, + { 0x020a, 0, 255, "\x00\x49\x03\x11\0" }, + { 0x020b, 0, 255, "\x00\x69\x03\x11\0" }, + { 0x020c, 0, 255, "\x00\x4f\x03\x0f\0" }, + { 0x020d, 0, 255, "\x00\x6f\x03\x0f\0" }, + { 0x020e, 0, 255, "\x00\x4f\x03\x11\0" }, + { 0x020f, 0, 255, "\x00\x6f\x03\x11\0" }, + { 0x0210, 0, 255, "\x00\x52\x03\x0f\0" }, + { 0x0211, 0, 255, "\x00\x72\x03\x0f\0" }, + { 0x0212, 0, 255, "\x00\x52\x03\x11\0" }, + { 0x0213, 0, 255, "\x00\x72\x03\x11\0" }, + { 0x0214, 0, 255, "\x00\x55\x03\x0f\0" }, + { 0x0215, 0, 255, "\x00\x75\x03\x0f\0" }, + { 0x0216, 0, 255, "\x00\x55\x03\x11\0" }, + { 0x0217, 0, 255, "\x00\x75\x03\x11\0" }, + { 0x0218, 0, 255, "\x00\x53\x03\x26\0" }, + { 0x0219, 0, 255, "\x00\x73\x03\x26\0" }, + { 0x021a, 0, 255, "\x00\x54\x03\x26\0" }, + { 0x021b, 0, 255, "\x00\x74\x03\x26\0" }, + { 0x021e, 0, 255, "\x00\x48\x03\x0c\0" }, + { 0x021f, 0, 255, "\x00\x68\x03\x0c\0" }, + { 0x0226, 0, 255, "\x00\x41\x03\x07\0" }, + { 0x0227, 0, 255, "\x00\x61\x03\x07\0" }, + { 0x0228, 0, 255, "\x00\x45\x03\x27\0" }, + { 0x0229, 0, 255, "\x00\x65\x03\x27\0" }, + { 0x022a, 0, 255, "\x00\x4f\x03\x08\x03\x04\0" }, + { 0x022b, 0, 255, "\x00\x6f\x03\x08\x03\x04\0" }, + { 0x022c, 0, 255, "\x00\x4f\x03\x03\x03\x04\0" }, + { 0x022d, 0, 255, "\x00\x6f\x03\x03\x03\x04\0" }, + { 0x022e, 0, 255, "\x00\x4f\x03\x07\0" }, + { 0x022f, 0, 255, "\x00\x6f\x03\x07\0" }, + { 0x0230, 0, 255, "\x00\x4f\x03\x07\x03\x04\0" }, + { 0x0231, 0, 255, "\x00\x6f\x03\x07\x03\x04\0" }, + { 0x0232, 0, 255, "\x00\x59\x03\x04\0" }, + { 0x0233, 0, 255, "\x00\x79\x03\x04\0" }, + { 0x02b0, 255, 0, "\x00\x68\0" }, + { 0x02b1, 255, 0, "\x02\x66\0" }, + { 0x02b2, 255, 0, "\x00\x6a\0" }, + { 0x02b3, 255, 0, "\x00\x72\0" }, + { 0x02b4, 255, 0, "\x02\x79\0" }, + { 0x02b5, 255, 0, "\x02\x7b\0" }, + { 0x02b6, 255, 0, "\x02\x81\0" }, + { 0x02b7, 255, 0, "\x00\x77\0" }, + { 0x02b8, 255, 0, "\x00\x79\0" }, + { 0x02d8, 255, 0, "\x00\x20\x03\x06\0" }, + { 0x02d9, 255, 0, "\x00\x20\x03\x07\0" }, + { 0x02da, 255, 0, "\x00\x20\x03\x0a\0" }, + { 0x02db, 255, 0, "\x00\x20\x03\x28\0" }, + { 0x02dc, 255, 0, "\x00\x20\x03\x03\0" }, + { 0x02dd, 255, 0, "\x00\x20\x03\x0b\0" }, + { 0x02e0, 255, 0, "\x02\x63\0" }, + { 0x02e1, 255, 0, "\x00\x6c\0" }, + { 0x02e2, 255, 0, "\x00\x73\0" }, + { 0x02e3, 255, 0, "\x00\x78\0" }, + { 0x02e4, 255, 0, "\x02\x95\0" }, + { 0x0340, 0, 255, "\x03\x00\0" }, + { 0x0341, 0, 255, "\x03\x01\0" }, + { 0x0343, 0, 255, "\x03\x13\0" }, + { 0x0344, 0, 255, "\x03\x08\x03\x01\0" }, + { 0x0374, 0, 255, "\x02\xb9\0" }, + { 0x037a, 255, 0, "\x00\x20\x03\x45\0" }, + { 0x037e, 0, 255, "\x00\x3b\0" }, + { 0x0384, 255, 0, "\x00\x20\x03\x01\0" }, + { 0x0385, 0, 6, "\x00\xa8\x03\x01\x00\x00\x00\x20\x03\x08\x03\x01\0" }, + { 0x0386, 0, 255, "\x03\x91\x03\x01\0" }, + { 0x0387, 0, 255, "\x00\xb7\0" }, + { 0x0388, 0, 255, "\x03\x95\x03\x01\0" }, + { 0x0389, 0, 255, "\x03\x97\x03\x01\0" }, + { 0x038a, 0, 255, "\x03\x99\x03\x01\0" }, + { 0x038c, 0, 255, "\x03\x9f\x03\x01\0" }, + { 0x038e, 0, 255, "\x03\xa5\x03\x01\0" }, + { 0x038f, 0, 255, "\x03\xa9\x03\x01\0" }, + { 0x0390, 0, 255, "\x03\xb9\x03\x08\x03\x01\0" }, + { 0x03aa, 0, 255, "\x03\x99\x03\x08\0" }, + { 0x03ab, 0, 255, "\x03\xa5\x03\x08\0" }, + { 0x03ac, 0, 255, "\x03\xb1\x03\x01\0" }, + { 0x03ad, 0, 255, "\x03\xb5\x03\x01\0" }, + { 0x03ae, 0, 255, "\x03\xb7\x03\x01\0" }, + { 0x03af, 0, 255, "\x03\xb9\x03\x01\0" }, + { 0x03b0, 0, 255, "\x03\xc5\x03\x08\x03\x01\0" }, + { 0x03ca, 0, 255, "\x03\xb9\x03\x08\0" }, + { 0x03cb, 0, 255, "\x03\xc5\x03\x08\0" }, + { 0x03cc, 0, 255, "\x03\xbf\x03\x01\0" }, + { 0x03cd, 0, 255, "\x03\xc5\x03\x01\0" }, + { 0x03ce, 0, 255, "\x03\xc9\x03\x01\0" }, + { 0x03d0, 255, 0, "\x03\xb2\0" }, + { 0x03d1, 255, 0, "\x03\xb8\0" }, + { 0x03d2, 255, 0, "\x03\xa5\0" }, + { 0x03d3, 0, 6, "\x03\xd2\x03\x01\x00\x00\x03\xa5\x03\x01\0" }, + { 0x03d4, 0, 6, "\x03\xd2\x03\x08\x00\x00\x03\xa5\x03\x08\0" }, + { 0x03d5, 255, 0, "\x03\xc6\0" }, + { 0x03d6, 255, 0, "\x03\xc0\0" }, + { 0x03f0, 255, 0, "\x03\xba\0" }, + { 0x03f1, 255, 0, "\x03\xc1\0" }, + { 0x03f2, 255, 0, "\x03\xc2\0" }, + { 0x03f4, 255, 0, "\x03\x98\0" }, + { 0x03f5, 255, 0, "\x03\xb5\0" }, + { 0x0400, 0, 255, "\x04\x15\x03\x00\0" }, + { 0x0401, 0, 255, "\x04\x15\x03\x08\0" }, + { 0x0403, 0, 255, "\x04\x13\x03\x01\0" }, + { 0x0407, 0, 255, "\x04\x06\x03\x08\0" }, + { 0x040c, 0, 255, "\x04\x1a\x03\x01\0" }, + { 0x040d, 0, 255, "\x04\x18\x03\x00\0" }, + { 0x040e, 0, 255, "\x04\x23\x03\x06\0" }, + { 0x0419, 0, 255, "\x04\x18\x03\x06\0" }, + { 0x0439, 0, 255, "\x04\x38\x03\x06\0" }, + { 0x0450, 0, 255, "\x04\x35\x03\x00\0" }, + { 0x0451, 0, 255, "\x04\x35\x03\x08\0" }, + { 0x0453, 0, 255, "\x04\x33\x03\x01\0" }, + { 0x0457, 0, 255, "\x04\x56\x03\x08\0" }, + { 0x045c, 0, 255, "\x04\x3a\x03\x01\0" }, + { 0x045d, 0, 255, "\x04\x38\x03\x00\0" }, + { 0x045e, 0, 255, "\x04\x43\x03\x06\0" }, + { 0x0476, 0, 255, "\x04\x74\x03\x0f\0" }, + { 0x0477, 0, 255, "\x04\x75\x03\x0f\0" }, + { 0x04c1, 0, 255, "\x04\x16\x03\x06\0" }, + { 0x04c2, 0, 255, "\x04\x36\x03\x06\0" }, + { 0x04d0, 0, 255, "\x04\x10\x03\x06\0" }, + { 0x04d1, 0, 255, "\x04\x30\x03\x06\0" }, + { 0x04d2, 0, 255, "\x04\x10\x03\x08\0" }, + { 0x04d3, 0, 255, "\x04\x30\x03\x08\0" }, + { 0x04d6, 0, 255, "\x04\x15\x03\x06\0" }, + { 0x04d7, 0, 255, "\x04\x35\x03\x06\0" }, + { 0x04da, 0, 255, "\x04\xd8\x03\x08\0" }, + { 0x04db, 0, 255, "\x04\xd9\x03\x08\0" }, + { 0x04dc, 0, 255, "\x04\x16\x03\x08\0" }, + { 0x04dd, 0, 255, "\x04\x36\x03\x08\0" }, + { 0x04de, 0, 255, "\x04\x17\x03\x08\0" }, + { 0x04df, 0, 255, "\x04\x37\x03\x08\0" }, + { 0x04e2, 0, 255, "\x04\x18\x03\x04\0" }, + { 0x04e3, 0, 255, "\x04\x38\x03\x04\0" }, + { 0x04e4, 0, 255, "\x04\x18\x03\x08\0" }, + { 0x04e5, 0, 255, "\x04\x38\x03\x08\0" }, + { 0x04e6, 0, 255, "\x04\x1e\x03\x08\0" }, + { 0x04e7, 0, 255, "\x04\x3e\x03\x08\0" }, + { 0x04ea, 0, 255, "\x04\xe8\x03\x08\0" }, + { 0x04eb, 0, 255, "\x04\xe9\x03\x08\0" }, + { 0x04ec, 0, 255, "\x04\x2d\x03\x08\0" }, + { 0x04ed, 0, 255, "\x04\x4d\x03\x08\0" }, + { 0x04ee, 0, 255, "\x04\x23\x03\x04\0" }, + { 0x04ef, 0, 255, "\x04\x43\x03\x04\0" }, + { 0x04f0, 0, 255, "\x04\x23\x03\x08\0" }, + { 0x04f1, 0, 255, "\x04\x43\x03\x08\0" }, + { 0x04f2, 0, 255, "\x04\x23\x03\x0b\0" }, + { 0x04f3, 0, 255, "\x04\x43\x03\x0b\0" }, + { 0x04f4, 0, 255, "\x04\x27\x03\x08\0" }, + { 0x04f5, 0, 255, "\x04\x47\x03\x08\0" }, + { 0x04f8, 0, 255, "\x04\x2b\x03\x08\0" }, + { 0x04f9, 0, 255, "\x04\x4b\x03\x08\0" }, + { 0x0587, 255, 0, "\x05\x65\x05\x82\0" }, + { 0x0622, 0, 255, "\x06\x27\x06\x53\0" }, + { 0x0623, 0, 255, "\x06\x27\x06\x54\0" }, + { 0x0624, 0, 255, "\x06\x48\x06\x54\0" }, + { 0x0625, 0, 255, "\x06\x27\x06\x55\0" }, + { 0x0626, 0, 255, "\x06\x4a\x06\x54\0" }, + { 0x0675, 255, 0, "\x06\x27\x06\x74\0" }, + { 0x0676, 255, 0, "\x06\x48\x06\x74\0" }, + { 0x0677, 255, 0, "\x06\xc7\x06\x74\0" }, + { 0x0678, 255, 0, "\x06\x4a\x06\x74\0" }, + { 0x06c0, 0, 255, "\x06\xd5\x06\x54\0" }, + { 0x06c2, 0, 255, "\x06\xc1\x06\x54\0" }, + { 0x06d3, 0, 255, "\x06\xd2\x06\x54\0" }, + { 0x0929, 0, 255, "\x09\x28\x09\x3c\0" }, + { 0x0931, 0, 255, "\x09\x30\x09\x3c\0" }, + { 0x0934, 0, 255, "\x09\x33\x09\x3c\0" }, + { 0x0958, 0, 255, "\x09\x15\x09\x3c\0" }, + { 0x0959, 0, 255, "\x09\x16\x09\x3c\0" }, + { 0x095a, 0, 255, "\x09\x17\x09\x3c\0" }, + { 0x095b, 0, 255, "\x09\x1c\x09\x3c\0" }, + { 0x095c, 0, 255, "\x09\x21\x09\x3c\0" }, + { 0x095d, 0, 255, "\x09\x22\x09\x3c\0" }, + { 0x095e, 0, 255, "\x09\x2b\x09\x3c\0" }, + { 0x095f, 0, 255, "\x09\x2f\x09\x3c\0" }, + { 0x09cb, 0, 255, "\x09\xc7\x09\xbe\0" }, + { 0x09cc, 0, 255, "\x09\xc7\x09\xd7\0" }, + { 0x09dc, 0, 255, "\x09\xa1\x09\xbc\0" }, + { 0x09dd, 0, 255, "\x09\xa2\x09\xbc\0" }, + { 0x09df, 0, 255, "\x09\xaf\x09\xbc\0" }, + { 0x0a33, 0, 255, "\x0a\x32\x0a\x3c\0" }, + { 0x0a36, 0, 255, "\x0a\x38\x0a\x3c\0" }, + { 0x0a59, 0, 255, "\x0a\x16\x0a\x3c\0" }, + { 0x0a5a, 0, 255, "\x0a\x17\x0a\x3c\0" }, + { 0x0a5b, 0, 255, "\x0a\x1c\x0a\x3c\0" }, + { 0x0a5e, 0, 255, "\x0a\x2b\x0a\x3c\0" }, + { 0x0b48, 0, 255, "\x0b\x47\x0b\x56\0" }, + { 0x0b4b, 0, 255, "\x0b\x47\x0b\x3e\0" }, + { 0x0b4c, 0, 255, "\x0b\x47\x0b\x57\0" }, + { 0x0b5c, 0, 255, "\x0b\x21\x0b\x3c\0" }, + { 0x0b5d, 0, 255, "\x0b\x22\x0b\x3c\0" }, + { 0x0b94, 0, 255, "\x0b\x92\x0b\xd7\0" }, + { 0x0bca, 0, 255, "\x0b\xc6\x0b\xbe\0" }, + { 0x0bcb, 0, 255, "\x0b\xc7\x0b\xbe\0" }, + { 0x0bcc, 0, 255, "\x0b\xc6\x0b\xd7\0" }, + { 0x0c48, 0, 255, "\x0c\x46\x0c\x56\0" }, + { 0x0cc0, 0, 255, "\x0c\xbf\x0c\xd5\0" }, + { 0x0cc7, 0, 255, "\x0c\xc6\x0c\xd5\0" }, + { 0x0cc8, 0, 255, "\x0c\xc6\x0c\xd6\0" }, + { 0x0cca, 0, 255, "\x0c\xc6\x0c\xc2\0" }, + { 0x0ccb, 0, 255, "\x0c\xc6\x0c\xc2\x0c\xd5\0" }, + { 0x0d4a, 0, 255, "\x0d\x46\x0d\x3e\0" }, + { 0x0d4b, 0, 255, "\x0d\x47\x0d\x3e\0" }, + { 0x0d4c, 0, 255, "\x0d\x46\x0d\x57\0" }, + { 0x0dda, 0, 255, "\x0d\xd9\x0d\xca\0" }, + { 0x0ddc, 0, 255, "\x0d\xd9\x0d\xcf\0" }, + { 0x0ddd, 0, 255, "\x0d\xd9\x0d\xcf\x0d\xca\0" }, + { 0x0dde, 0, 255, "\x0d\xd9\x0d\xdf\0" }, + { 0x0e33, 255, 0, "\x0e\x4d\x0e\x32\0" }, + { 0x0eb3, 255, 0, "\x0e\xcd\x0e\xb2\0" }, + { 0x0edc, 255, 0, "\x0e\xab\x0e\x99\0" }, + { 0x0edd, 255, 0, "\x0e\xab\x0e\xa1\0" }, + { 0x0f0c, 255, 0, "\x0f\x0b\0" }, + { 0x0f43, 0, 255, "\x0f\x42\x0f\xb7\0" }, + { 0x0f4d, 0, 255, "\x0f\x4c\x0f\xb7\0" }, + { 0x0f52, 0, 255, "\x0f\x51\x0f\xb7\0" }, + { 0x0f57, 0, 255, "\x0f\x56\x0f\xb7\0" }, + { 0x0f5c, 0, 255, "\x0f\x5b\x0f\xb7\0" }, + { 0x0f69, 0, 255, "\x0f\x40\x0f\xb5\0" }, + { 0x0f73, 0, 255, "\x0f\x71\x0f\x72\0" }, + { 0x0f75, 0, 255, "\x0f\x71\x0f\x74\0" }, + { 0x0f76, 0, 255, "\x0f\xb2\x0f\x80\0" }, + { 0x0f77, 255, 0, "\x0f\xb2\x0f\x71\x0f\x80\0" }, + { 0x0f78, 0, 255, "\x0f\xb3\x0f\x80\0" }, + { 0x0f79, 255, 0, "\x0f\xb3\x0f\x71\x0f\x80\0" }, + { 0x0f81, 0, 255, "\x0f\x71\x0f\x80\0" }, + { 0x0f93, 0, 255, "\x0f\x92\x0f\xb7\0" }, + { 0x0f9d, 0, 255, "\x0f\x9c\x0f\xb7\0" }, + { 0x0fa2, 0, 255, "\x0f\xa1\x0f\xb7\0" }, + { 0x0fa7, 0, 255, "\x0f\xa6\x0f\xb7\0" }, + { 0x0fac, 0, 255, "\x0f\xab\x0f\xb7\0" }, + { 0x0fb9, 0, 255, "\x0f\x90\x0f\xb5\0" }, + { 0x1026, 0, 255, "\x10\x25\x10\x2e\0" }, + { 0x1e00, 0, 255, "\x00\x41\x03\x25\0" }, + { 0x1e01, 0, 255, "\x00\x61\x03\x25\0" }, + { 0x1e02, 0, 255, "\x00\x42\x03\x07\0" }, + { 0x1e03, 0, 255, "\x00\x62\x03\x07\0" }, + { 0x1e04, 0, 255, "\x00\x42\x03\x23\0" }, + { 0x1e05, 0, 255, "\x00\x62\x03\x23\0" }, + { 0x1e06, 0, 255, "\x00\x42\x03\x31\0" }, + { 0x1e07, 0, 255, "\x00\x62\x03\x31\0" }, + { 0x1e08, 0, 255, "\x00\x43\x03\x27\x03\x01\0" }, + { 0x1e09, 0, 255, "\x00\x63\x03\x27\x03\x01\0" }, + { 0x1e0a, 0, 255, "\x00\x44\x03\x07\0" }, + { 0x1e0b, 0, 255, "\x00\x64\x03\x07\0" }, + { 0x1e0c, 0, 255, "\x00\x44\x03\x23\0" }, + { 0x1e0d, 0, 255, "\x00\x64\x03\x23\0" }, + { 0x1e0e, 0, 255, "\x00\x44\x03\x31\0" }, + { 0x1e0f, 0, 255, "\x00\x64\x03\x31\0" }, + { 0x1e10, 0, 255, "\x00\x44\x03\x27\0" }, + { 0x1e11, 0, 255, "\x00\x64\x03\x27\0" }, + { 0x1e12, 0, 255, "\x00\x44\x03\x2d\0" }, + { 0x1e13, 0, 255, "\x00\x64\x03\x2d\0" }, + { 0x1e14, 0, 255, "\x00\x45\x03\x04\x03\x00\0" }, + { 0x1e15, 0, 255, "\x00\x65\x03\x04\x03\x00\0" }, + { 0x1e16, 0, 255, "\x00\x45\x03\x04\x03\x01\0" }, + { 0x1e17, 0, 255, "\x00\x65\x03\x04\x03\x01\0" }, + { 0x1e18, 0, 255, "\x00\x45\x03\x2d\0" }, + { 0x1e19, 0, 255, "\x00\x65\x03\x2d\0" }, + { 0x1e1a, 0, 255, "\x00\x45\x03\x30\0" }, + { 0x1e1b, 0, 255, "\x00\x65\x03\x30\0" }, + { 0x1e1c, 0, 255, "\x00\x45\x03\x27\x03\x06\0" }, + { 0x1e1d, 0, 255, "\x00\x65\x03\x27\x03\x06\0" }, + { 0x1e1e, 0, 255, "\x00\x46\x03\x07\0" }, + { 0x1e1f, 0, 255, "\x00\x66\x03\x07\0" }, + { 0x1e20, 0, 255, "\x00\x47\x03\x04\0" }, + { 0x1e21, 0, 255, "\x00\x67\x03\x04\0" }, + { 0x1e22, 0, 255, "\x00\x48\x03\x07\0" }, + { 0x1e23, 0, 255, "\x00\x68\x03\x07\0" }, + { 0x1e24, 0, 255, "\x00\x48\x03\x23\0" }, + { 0x1e25, 0, 255, "\x00\x68\x03\x23\0" }, + { 0x1e26, 0, 255, "\x00\x48\x03\x08\0" }, + { 0x1e27, 0, 255, "\x00\x68\x03\x08\0" }, + { 0x1e28, 0, 255, "\x00\x48\x03\x27\0" }, + { 0x1e29, 0, 255, "\x00\x68\x03\x27\0" }, + { 0x1e2a, 0, 255, "\x00\x48\x03\x2e\0" }, + { 0x1e2b, 0, 255, "\x00\x68\x03\x2e\0" }, + { 0x1e2c, 0, 255, "\x00\x49\x03\x30\0" }, + { 0x1e2d, 0, 255, "\x00\x69\x03\x30\0" }, + { 0x1e2e, 0, 255, "\x00\x49\x03\x08\x03\x01\0" }, + { 0x1e2f, 0, 255, "\x00\x69\x03\x08\x03\x01\0" }, + { 0x1e30, 0, 255, "\x00\x4b\x03\x01\0" }, + { 0x1e31, 0, 255, "\x00\x6b\x03\x01\0" }, + { 0x1e32, 0, 255, "\x00\x4b\x03\x23\0" }, + { 0x1e33, 0, 255, "\x00\x6b\x03\x23\0" }, + { 0x1e34, 0, 255, "\x00\x4b\x03\x31\0" }, + { 0x1e35, 0, 255, "\x00\x6b\x03\x31\0" }, + { 0x1e36, 0, 255, "\x00\x4c\x03\x23\0" }, + { 0x1e37, 0, 255, "\x00\x6c\x03\x23\0" }, + { 0x1e38, 0, 255, "\x00\x4c\x03\x23\x03\x04\0" }, + { 0x1e39, 0, 255, "\x00\x6c\x03\x23\x03\x04\0" }, + { 0x1e3a, 0, 255, "\x00\x4c\x03\x31\0" }, + { 0x1e3b, 0, 255, "\x00\x6c\x03\x31\0" }, + { 0x1e3c, 0, 255, "\x00\x4c\x03\x2d\0" }, + { 0x1e3d, 0, 255, "\x00\x6c\x03\x2d\0" }, + { 0x1e3e, 0, 255, "\x00\x4d\x03\x01\0" }, + { 0x1e3f, 0, 255, "\x00\x6d\x03\x01\0" }, + { 0x1e40, 0, 255, "\x00\x4d\x03\x07\0" }, + { 0x1e41, 0, 255, "\x00\x6d\x03\x07\0" }, + { 0x1e42, 0, 255, "\x00\x4d\x03\x23\0" }, + { 0x1e43, 0, 255, "\x00\x6d\x03\x23\0" }, + { 0x1e44, 0, 255, "\x00\x4e\x03\x07\0" }, + { 0x1e45, 0, 255, "\x00\x6e\x03\x07\0" }, + { 0x1e46, 0, 255, "\x00\x4e\x03\x23\0" }, + { 0x1e47, 0, 255, "\x00\x6e\x03\x23\0" }, + { 0x1e48, 0, 255, "\x00\x4e\x03\x31\0" }, + { 0x1e49, 0, 255, "\x00\x6e\x03\x31\0" }, + { 0x1e4a, 0, 255, "\x00\x4e\x03\x2d\0" }, + { 0x1e4b, 0, 255, "\x00\x6e\x03\x2d\0" }, + { 0x1e4c, 0, 255, "\x00\x4f\x03\x03\x03\x01\0" }, + { 0x1e4d, 0, 255, "\x00\x6f\x03\x03\x03\x01\0" }, + { 0x1e4e, 0, 255, "\x00\x4f\x03\x03\x03\x08\0" }, + { 0x1e4f, 0, 255, "\x00\x6f\x03\x03\x03\x08\0" }, + { 0x1e50, 0, 255, "\x00\x4f\x03\x04\x03\x00\0" }, + { 0x1e51, 0, 255, "\x00\x6f\x03\x04\x03\x00\0" }, + { 0x1e52, 0, 255, "\x00\x4f\x03\x04\x03\x01\0" }, + { 0x1e53, 0, 255, "\x00\x6f\x03\x04\x03\x01\0" }, + { 0x1e54, 0, 255, "\x00\x50\x03\x01\0" }, + { 0x1e55, 0, 255, "\x00\x70\x03\x01\0" }, + { 0x1e56, 0, 255, "\x00\x50\x03\x07\0" }, + { 0x1e57, 0, 255, "\x00\x70\x03\x07\0" }, + { 0x1e58, 0, 255, "\x00\x52\x03\x07\0" }, + { 0x1e59, 0, 255, "\x00\x72\x03\x07\0" }, + { 0x1e5a, 0, 255, "\x00\x52\x03\x23\0" }, + { 0x1e5b, 0, 255, "\x00\x72\x03\x23\0" }, + { 0x1e5c, 0, 255, "\x00\x52\x03\x23\x03\x04\0" }, + { 0x1e5d, 0, 255, "\x00\x72\x03\x23\x03\x04\0" }, + { 0x1e5e, 0, 255, "\x00\x52\x03\x31\0" }, + { 0x1e5f, 0, 255, "\x00\x72\x03\x31\0" }, + { 0x1e60, 0, 255, "\x00\x53\x03\x07\0" }, + { 0x1e61, 0, 255, "\x00\x73\x03\x07\0" }, + { 0x1e62, 0, 255, "\x00\x53\x03\x23\0" }, + { 0x1e63, 0, 255, "\x00\x73\x03\x23\0" }, + { 0x1e64, 0, 255, "\x00\x53\x03\x01\x03\x07\0" }, + { 0x1e65, 0, 255, "\x00\x73\x03\x01\x03\x07\0" }, + { 0x1e66, 0, 255, "\x00\x53\x03\x0c\x03\x07\0" }, + { 0x1e67, 0, 255, "\x00\x73\x03\x0c\x03\x07\0" }, + { 0x1e68, 0, 255, "\x00\x53\x03\x23\x03\x07\0" }, + { 0x1e69, 0, 255, "\x00\x73\x03\x23\x03\x07\0" }, + { 0x1e6a, 0, 255, "\x00\x54\x03\x07\0" }, + { 0x1e6b, 0, 255, "\x00\x74\x03\x07\0" }, + { 0x1e6c, 0, 255, "\x00\x54\x03\x23\0" }, + { 0x1e6d, 0, 255, "\x00\x74\x03\x23\0" }, + { 0x1e6e, 0, 255, "\x00\x54\x03\x31\0" }, + { 0x1e6f, 0, 255, "\x00\x74\x03\x31\0" }, + { 0x1e70, 0, 255, "\x00\x54\x03\x2d\0" }, + { 0x1e71, 0, 255, "\x00\x74\x03\x2d\0" }, + { 0x1e72, 0, 255, "\x00\x55\x03\x24\0" }, + { 0x1e73, 0, 255, "\x00\x75\x03\x24\0" }, + { 0x1e74, 0, 255, "\x00\x55\x03\x30\0" }, + { 0x1e75, 0, 255, "\x00\x75\x03\x30\0" }, + { 0x1e76, 0, 255, "\x00\x55\x03\x2d\0" }, + { 0x1e77, 0, 255, "\x00\x75\x03\x2d\0" }, + { 0x1e78, 0, 255, "\x00\x55\x03\x03\x03\x01\0" }, + { 0x1e79, 0, 255, "\x00\x75\x03\x03\x03\x01\0" }, + { 0x1e7a, 0, 255, "\x00\x55\x03\x04\x03\x08\0" }, + { 0x1e7b, 0, 255, "\x00\x75\x03\x04\x03\x08\0" }, + { 0x1e7c, 0, 255, "\x00\x56\x03\x03\0" }, + { 0x1e7d, 0, 255, "\x00\x76\x03\x03\0" }, + { 0x1e7e, 0, 255, "\x00\x56\x03\x23\0" }, + { 0x1e7f, 0, 255, "\x00\x76\x03\x23\0" }, + { 0x1e80, 0, 255, "\x00\x57\x03\x00\0" }, + { 0x1e81, 0, 255, "\x00\x77\x03\x00\0" }, + { 0x1e82, 0, 255, "\x00\x57\x03\x01\0" }, + { 0x1e83, 0, 255, "\x00\x77\x03\x01\0" }, + { 0x1e84, 0, 255, "\x00\x57\x03\x08\0" }, + { 0x1e85, 0, 255, "\x00\x77\x03\x08\0" }, + { 0x1e86, 0, 255, "\x00\x57\x03\x07\0" }, + { 0x1e87, 0, 255, "\x00\x77\x03\x07\0" }, + { 0x1e88, 0, 255, "\x00\x57\x03\x23\0" }, + { 0x1e89, 0, 255, "\x00\x77\x03\x23\0" }, + { 0x1e8a, 0, 255, "\x00\x58\x03\x07\0" }, + { 0x1e8b, 0, 255, "\x00\x78\x03\x07\0" }, + { 0x1e8c, 0, 255, "\x00\x58\x03\x08\0" }, + { 0x1e8d, 0, 255, "\x00\x78\x03\x08\0" }, + { 0x1e8e, 0, 255, "\x00\x59\x03\x07\0" }, + { 0x1e8f, 0, 255, "\x00\x79\x03\x07\0" }, + { 0x1e90, 0, 255, "\x00\x5a\x03\x02\0" }, + { 0x1e91, 0, 255, "\x00\x7a\x03\x02\0" }, + { 0x1e92, 0, 255, "\x00\x5a\x03\x23\0" }, + { 0x1e93, 0, 255, "\x00\x7a\x03\x23\0" }, + { 0x1e94, 0, 255, "\x00\x5a\x03\x31\0" }, + { 0x1e95, 0, 255, "\x00\x7a\x03\x31\0" }, + { 0x1e96, 0, 255, "\x00\x68\x03\x31\0" }, + { 0x1e97, 0, 255, "\x00\x74\x03\x08\0" }, + { 0x1e98, 0, 255, "\x00\x77\x03\x0a\0" }, + { 0x1e99, 0, 255, "\x00\x79\x03\x0a\0" }, + { 0x1e9a, 255, 0, "\x00\x61\x02\xbe\0" }, + { 0x1e9b, 0, 6, "\x01\x7f\x03\x07\x00\x00\x00\x73\x03\x07\0" }, + { 0x1ea0, 0, 255, "\x00\x41\x03\x23\0" }, + { 0x1ea1, 0, 255, "\x00\x61\x03\x23\0" }, + { 0x1ea2, 0, 255, "\x00\x41\x03\x09\0" }, + { 0x1ea3, 0, 255, "\x00\x61\x03\x09\0" }, + { 0x1ea4, 0, 255, "\x00\x41\x03\x02\x03\x01\0" }, + { 0x1ea5, 0, 255, "\x00\x61\x03\x02\x03\x01\0" }, + { 0x1ea6, 0, 255, "\x00\x41\x03\x02\x03\x00\0" }, + { 0x1ea7, 0, 255, "\x00\x61\x03\x02\x03\x00\0" }, + { 0x1ea8, 0, 255, "\x00\x41\x03\x02\x03\x09\0" }, + { 0x1ea9, 0, 255, "\x00\x61\x03\x02\x03\x09\0" }, + { 0x1eaa, 0, 255, "\x00\x41\x03\x02\x03\x03\0" }, + { 0x1eab, 0, 255, "\x00\x61\x03\x02\x03\x03\0" }, + { 0x1eac, 0, 255, "\x00\x41\x03\x23\x03\x02\0" }, + { 0x1ead, 0, 255, "\x00\x61\x03\x23\x03\x02\0" }, + { 0x1eae, 0, 255, "\x00\x41\x03\x06\x03\x01\0" }, + { 0x1eaf, 0, 255, "\x00\x61\x03\x06\x03\x01\0" }, + { 0x1eb0, 0, 255, "\x00\x41\x03\x06\x03\x00\0" }, + { 0x1eb1, 0, 255, "\x00\x61\x03\x06\x03\x00\0" }, + { 0x1eb2, 0, 255, "\x00\x41\x03\x06\x03\x09\0" }, + { 0x1eb3, 0, 255, "\x00\x61\x03\x06\x03\x09\0" }, + { 0x1eb4, 0, 255, "\x00\x41\x03\x06\x03\x03\0" }, + { 0x1eb5, 0, 255, "\x00\x61\x03\x06\x03\x03\0" }, + { 0x1eb6, 0, 255, "\x00\x41\x03\x23\x03\x06\0" }, + { 0x1eb7, 0, 255, "\x00\x61\x03\x23\x03\x06\0" }, + { 0x1eb8, 0, 255, "\x00\x45\x03\x23\0" }, + { 0x1eb9, 0, 255, "\x00\x65\x03\x23\0" }, + { 0x1eba, 0, 255, "\x00\x45\x03\x09\0" }, + { 0x1ebb, 0, 255, "\x00\x65\x03\x09\0" }, + { 0x1ebc, 0, 255, "\x00\x45\x03\x03\0" }, + { 0x1ebd, 0, 255, "\x00\x65\x03\x03\0" }, + { 0x1ebe, 0, 255, "\x00\x45\x03\x02\x03\x01\0" }, + { 0x1ebf, 0, 255, "\x00\x65\x03\x02\x03\x01\0" }, + { 0x1ec0, 0, 255, "\x00\x45\x03\x02\x03\x00\0" }, + { 0x1ec1, 0, 255, "\x00\x65\x03\x02\x03\x00\0" }, + { 0x1ec2, 0, 255, "\x00\x45\x03\x02\x03\x09\0" }, + { 0x1ec3, 0, 255, "\x00\x65\x03\x02\x03\x09\0" }, + { 0x1ec4, 0, 255, "\x00\x45\x03\x02\x03\x03\0" }, + { 0x1ec5, 0, 255, "\x00\x65\x03\x02\x03\x03\0" }, + { 0x1ec6, 0, 255, "\x00\x45\x03\x23\x03\x02\0" }, + { 0x1ec7, 0, 255, "\x00\x65\x03\x23\x03\x02\0" }, + { 0x1ec8, 0, 255, "\x00\x49\x03\x09\0" }, + { 0x1ec9, 0, 255, "\x00\x69\x03\x09\0" }, + { 0x1eca, 0, 255, "\x00\x49\x03\x23\0" }, + { 0x1ecb, 0, 255, "\x00\x69\x03\x23\0" }, + { 0x1ecc, 0, 255, "\x00\x4f\x03\x23\0" }, + { 0x1ecd, 0, 255, "\x00\x6f\x03\x23\0" }, + { 0x1ece, 0, 255, "\x00\x4f\x03\x09\0" }, + { 0x1ecf, 0, 255, "\x00\x6f\x03\x09\0" }, + { 0x1ed0, 0, 255, "\x00\x4f\x03\x02\x03\x01\0" }, + { 0x1ed1, 0, 255, "\x00\x6f\x03\x02\x03\x01\0" }, + { 0x1ed2, 0, 255, "\x00\x4f\x03\x02\x03\x00\0" }, + { 0x1ed3, 0, 255, "\x00\x6f\x03\x02\x03\x00\0" }, + { 0x1ed4, 0, 255, "\x00\x4f\x03\x02\x03\x09\0" }, + { 0x1ed5, 0, 255, "\x00\x6f\x03\x02\x03\x09\0" }, + { 0x1ed6, 0, 255, "\x00\x4f\x03\x02\x03\x03\0" }, + { 0x1ed7, 0, 255, "\x00\x6f\x03\x02\x03\x03\0" }, + { 0x1ed8, 0, 255, "\x00\x4f\x03\x23\x03\x02\0" }, + { 0x1ed9, 0, 255, "\x00\x6f\x03\x23\x03\x02\0" }, + { 0x1eda, 0, 255, "\x00\x4f\x03\x1b\x03\x01\0" }, + { 0x1edb, 0, 255, "\x00\x6f\x03\x1b\x03\x01\0" }, + { 0x1edc, 0, 255, "\x00\x4f\x03\x1b\x03\x00\0" }, + { 0x1edd, 0, 255, "\x00\x6f\x03\x1b\x03\x00\0" }, + { 0x1ede, 0, 255, "\x00\x4f\x03\x1b\x03\x09\0" }, + { 0x1edf, 0, 255, "\x00\x6f\x03\x1b\x03\x09\0" }, + { 0x1ee0, 0, 255, "\x00\x4f\x03\x1b\x03\x03\0" }, + { 0x1ee1, 0, 255, "\x00\x6f\x03\x1b\x03\x03\0" }, + { 0x1ee2, 0, 255, "\x00\x4f\x03\x1b\x03\x23\0" }, + { 0x1ee3, 0, 255, "\x00\x6f\x03\x1b\x03\x23\0" }, + { 0x1ee4, 0, 255, "\x00\x55\x03\x23\0" }, + { 0x1ee5, 0, 255, "\x00\x75\x03\x23\0" }, + { 0x1ee6, 0, 255, "\x00\x55\x03\x09\0" }, + { 0x1ee7, 0, 255, "\x00\x75\x03\x09\0" }, + { 0x1ee8, 0, 255, "\x00\x55\x03\x1b\x03\x01\0" }, + { 0x1ee9, 0, 255, "\x00\x75\x03\x1b\x03\x01\0" }, + { 0x1eea, 0, 255, "\x00\x55\x03\x1b\x03\x00\0" }, + { 0x1eeb, 0, 255, "\x00\x75\x03\x1b\x03\x00\0" }, + { 0x1eec, 0, 255, "\x00\x55\x03\x1b\x03\x09\0" }, + { 0x1eed, 0, 255, "\x00\x75\x03\x1b\x03\x09\0" }, + { 0x1eee, 0, 255, "\x00\x55\x03\x1b\x03\x03\0" }, + { 0x1eef, 0, 255, "\x00\x75\x03\x1b\x03\x03\0" }, + { 0x1ef0, 0, 255, "\x00\x55\x03\x1b\x03\x23\0" }, + { 0x1ef1, 0, 255, "\x00\x75\x03\x1b\x03\x23\0" }, + { 0x1ef2, 0, 255, "\x00\x59\x03\x00\0" }, + { 0x1ef3, 0, 255, "\x00\x79\x03\x00\0" }, + { 0x1ef4, 0, 255, "\x00\x59\x03\x23\0" }, + { 0x1ef5, 0, 255, "\x00\x79\x03\x23\0" }, + { 0x1ef6, 0, 255, "\x00\x59\x03\x09\0" }, + { 0x1ef7, 0, 255, "\x00\x79\x03\x09\0" }, + { 0x1ef8, 0, 255, "\x00\x59\x03\x03\0" }, + { 0x1ef9, 0, 255, "\x00\x79\x03\x03\0" }, + { 0x1f00, 0, 255, "\x03\xb1\x03\x13\0" }, + { 0x1f01, 0, 255, "\x03\xb1\x03\x14\0" }, + { 0x1f02, 0, 255, "\x03\xb1\x03\x13\x03\x00\0" }, + { 0x1f03, 0, 255, "\x03\xb1\x03\x14\x03\x00\0" }, + { 0x1f04, 0, 255, "\x03\xb1\x03\x13\x03\x01\0" }, + { 0x1f05, 0, 255, "\x03\xb1\x03\x14\x03\x01\0" }, + { 0x1f06, 0, 255, "\x03\xb1\x03\x13\x03\x42\0" }, + { 0x1f07, 0, 255, "\x03\xb1\x03\x14\x03\x42\0" }, + { 0x1f08, 0, 255, "\x03\x91\x03\x13\0" }, + { 0x1f09, 0, 255, "\x03\x91\x03\x14\0" }, + { 0x1f0a, 0, 255, "\x03\x91\x03\x13\x03\x00\0" }, + { 0x1f0b, 0, 255, "\x03\x91\x03\x14\x03\x00\0" }, + { 0x1f0c, 0, 255, "\x03\x91\x03\x13\x03\x01\0" }, + { 0x1f0d, 0, 255, "\x03\x91\x03\x14\x03\x01\0" }, + { 0x1f0e, 0, 255, "\x03\x91\x03\x13\x03\x42\0" }, + { 0x1f0f, 0, 255, "\x03\x91\x03\x14\x03\x42\0" }, + { 0x1f10, 0, 255, "\x03\xb5\x03\x13\0" }, + { 0x1f11, 0, 255, "\x03\xb5\x03\x14\0" }, + { 0x1f12, 0, 255, "\x03\xb5\x03\x13\x03\x00\0" }, + { 0x1f13, 0, 255, "\x03\xb5\x03\x14\x03\x00\0" }, + { 0x1f14, 0, 255, "\x03\xb5\x03\x13\x03\x01\0" }, + { 0x1f15, 0, 255, "\x03\xb5\x03\x14\x03\x01\0" }, + { 0x1f18, 0, 255, "\x03\x95\x03\x13\0" }, + { 0x1f19, 0, 255, "\x03\x95\x03\x14\0" }, + { 0x1f1a, 0, 255, "\x03\x95\x03\x13\x03\x00\0" }, + { 0x1f1b, 0, 255, "\x03\x95\x03\x14\x03\x00\0" }, + { 0x1f1c, 0, 255, "\x03\x95\x03\x13\x03\x01\0" }, + { 0x1f1d, 0, 255, "\x03\x95\x03\x14\x03\x01\0" }, + { 0x1f20, 0, 255, "\x03\xb7\x03\x13\0" }, + { 0x1f21, 0, 255, "\x03\xb7\x03\x14\0" }, + { 0x1f22, 0, 255, "\x03\xb7\x03\x13\x03\x00\0" }, + { 0x1f23, 0, 255, "\x03\xb7\x03\x14\x03\x00\0" }, + { 0x1f24, 0, 255, "\x03\xb7\x03\x13\x03\x01\0" }, + { 0x1f25, 0, 255, "\x03\xb7\x03\x14\x03\x01\0" }, + { 0x1f26, 0, 255, "\x03\xb7\x03\x13\x03\x42\0" }, + { 0x1f27, 0, 255, "\x03\xb7\x03\x14\x03\x42\0" }, + { 0x1f28, 0, 255, "\x03\x97\x03\x13\0" }, + { 0x1f29, 0, 255, "\x03\x97\x03\x14\0" }, + { 0x1f2a, 0, 255, "\x03\x97\x03\x13\x03\x00\0" }, + { 0x1f2b, 0, 255, "\x03\x97\x03\x14\x03\x00\0" }, + { 0x1f2c, 0, 255, "\x03\x97\x03\x13\x03\x01\0" }, + { 0x1f2d, 0, 255, "\x03\x97\x03\x14\x03\x01\0" }, + { 0x1f2e, 0, 255, "\x03\x97\x03\x13\x03\x42\0" }, + { 0x1f2f, 0, 255, "\x03\x97\x03\x14\x03\x42\0" }, + { 0x1f30, 0, 255, "\x03\xb9\x03\x13\0" }, + { 0x1f31, 0, 255, "\x03\xb9\x03\x14\0" }, + { 0x1f32, 0, 255, "\x03\xb9\x03\x13\x03\x00\0" }, + { 0x1f33, 0, 255, "\x03\xb9\x03\x14\x03\x00\0" }, + { 0x1f34, 0, 255, "\x03\xb9\x03\x13\x03\x01\0" }, + { 0x1f35, 0, 255, "\x03\xb9\x03\x14\x03\x01\0" }, + { 0x1f36, 0, 255, "\x03\xb9\x03\x13\x03\x42\0" }, + { 0x1f37, 0, 255, "\x03\xb9\x03\x14\x03\x42\0" }, + { 0x1f38, 0, 255, "\x03\x99\x03\x13\0" }, + { 0x1f39, 0, 255, "\x03\x99\x03\x14\0" }, + { 0x1f3a, 0, 255, "\x03\x99\x03\x13\x03\x00\0" }, + { 0x1f3b, 0, 255, "\x03\x99\x03\x14\x03\x00\0" }, + { 0x1f3c, 0, 255, "\x03\x99\x03\x13\x03\x01\0" }, + { 0x1f3d, 0, 255, "\x03\x99\x03\x14\x03\x01\0" }, + { 0x1f3e, 0, 255, "\x03\x99\x03\x13\x03\x42\0" }, + { 0x1f3f, 0, 255, "\x03\x99\x03\x14\x03\x42\0" }, + { 0x1f40, 0, 255, "\x03\xbf\x03\x13\0" }, + { 0x1f41, 0, 255, "\x03\xbf\x03\x14\0" }, + { 0x1f42, 0, 255, "\x03\xbf\x03\x13\x03\x00\0" }, + { 0x1f43, 0, 255, "\x03\xbf\x03\x14\x03\x00\0" }, + { 0x1f44, 0, 255, "\x03\xbf\x03\x13\x03\x01\0" }, + { 0x1f45, 0, 255, "\x03\xbf\x03\x14\x03\x01\0" }, + { 0x1f48, 0, 255, "\x03\x9f\x03\x13\0" }, + { 0x1f49, 0, 255, "\x03\x9f\x03\x14\0" }, + { 0x1f4a, 0, 255, "\x03\x9f\x03\x13\x03\x00\0" }, + { 0x1f4b, 0, 255, "\x03\x9f\x03\x14\x03\x00\0" }, + { 0x1f4c, 0, 255, "\x03\x9f\x03\x13\x03\x01\0" }, + { 0x1f4d, 0, 255, "\x03\x9f\x03\x14\x03\x01\0" }, + { 0x1f50, 0, 255, "\x03\xc5\x03\x13\0" }, + { 0x1f51, 0, 255, "\x03\xc5\x03\x14\0" }, + { 0x1f52, 0, 255, "\x03\xc5\x03\x13\x03\x00\0" }, + { 0x1f53, 0, 255, "\x03\xc5\x03\x14\x03\x00\0" }, + { 0x1f54, 0, 255, "\x03\xc5\x03\x13\x03\x01\0" }, + { 0x1f55, 0, 255, "\x03\xc5\x03\x14\x03\x01\0" }, + { 0x1f56, 0, 255, "\x03\xc5\x03\x13\x03\x42\0" }, + { 0x1f57, 0, 255, "\x03\xc5\x03\x14\x03\x42\0" }, + { 0x1f59, 0, 255, "\x03\xa5\x03\x14\0" }, + { 0x1f5b, 0, 255, "\x03\xa5\x03\x14\x03\x00\0" }, + { 0x1f5d, 0, 255, "\x03\xa5\x03\x14\x03\x01\0" }, + { 0x1f5f, 0, 255, "\x03\xa5\x03\x14\x03\x42\0" }, + { 0x1f60, 0, 255, "\x03\xc9\x03\x13\0" }, + { 0x1f61, 0, 255, "\x03\xc9\x03\x14\0" }, + { 0x1f62, 0, 255, "\x03\xc9\x03\x13\x03\x00\0" }, + { 0x1f63, 0, 255, "\x03\xc9\x03\x14\x03\x00\0" }, + { 0x1f64, 0, 255, "\x03\xc9\x03\x13\x03\x01\0" }, + { 0x1f65, 0, 255, "\x03\xc9\x03\x14\x03\x01\0" }, + { 0x1f66, 0, 255, "\x03\xc9\x03\x13\x03\x42\0" }, + { 0x1f67, 0, 255, "\x03\xc9\x03\x14\x03\x42\0" }, + { 0x1f68, 0, 255, "\x03\xa9\x03\x13\0" }, + { 0x1f69, 0, 255, "\x03\xa9\x03\x14\0" }, + { 0x1f6a, 0, 255, "\x03\xa9\x03\x13\x03\x00\0" }, + { 0x1f6b, 0, 255, "\x03\xa9\x03\x14\x03\x00\0" }, + { 0x1f6c, 0, 255, "\x03\xa9\x03\x13\x03\x01\0" }, + { 0x1f6d, 0, 255, "\x03\xa9\x03\x14\x03\x01\0" }, + { 0x1f6e, 0, 255, "\x03\xa9\x03\x13\x03\x42\0" }, + { 0x1f6f, 0, 255, "\x03\xa9\x03\x14\x03\x42\0" }, + { 0x1f70, 0, 255, "\x03\xb1\x03\x00\0" }, + { 0x1f71, 0, 255, "\x03\xb1\x03\x01\0" }, + { 0x1f72, 0, 255, "\x03\xb5\x03\x00\0" }, + { 0x1f73, 0, 255, "\x03\xb5\x03\x01\0" }, + { 0x1f74, 0, 255, "\x03\xb7\x03\x00\0" }, + { 0x1f75, 0, 255, "\x03\xb7\x03\x01\0" }, + { 0x1f76, 0, 255, "\x03\xb9\x03\x00\0" }, + { 0x1f77, 0, 255, "\x03\xb9\x03\x01\0" }, + { 0x1f78, 0, 255, "\x03\xbf\x03\x00\0" }, + { 0x1f79, 0, 255, "\x03\xbf\x03\x01\0" }, + { 0x1f7a, 0, 255, "\x03\xc5\x03\x00\0" }, + { 0x1f7b, 0, 255, "\x03\xc5\x03\x01\0" }, + { 0x1f7c, 0, 255, "\x03\xc9\x03\x00\0" }, + { 0x1f7d, 0, 255, "\x03\xc9\x03\x01\0" }, + { 0x1f80, 0, 255, "\x03\xb1\x03\x13\x03\x45\0" }, + { 0x1f81, 0, 255, "\x03\xb1\x03\x14\x03\x45\0" }, + { 0x1f82, 0, 255, "\x03\xb1\x03\x13\x03\x00\x03\x45\0" }, + { 0x1f83, 0, 255, "\x03\xb1\x03\x14\x03\x00\x03\x45\0" }, + { 0x1f84, 0, 255, "\x03\xb1\x03\x13\x03\x01\x03\x45\0" }, + { 0x1f85, 0, 255, "\x03\xb1\x03\x14\x03\x01\x03\x45\0" }, + { 0x1f86, 0, 255, "\x03\xb1\x03\x13\x03\x42\x03\x45\0" }, + { 0x1f87, 0, 255, "\x03\xb1\x03\x14\x03\x42\x03\x45\0" }, + { 0x1f88, 0, 255, "\x03\x91\x03\x13\x03\x45\0" }, + { 0x1f89, 0, 255, "\x03\x91\x03\x14\x03\x45\0" }, + { 0x1f8a, 0, 255, "\x03\x91\x03\x13\x03\x00\x03\x45\0" }, + { 0x1f8b, 0, 255, "\x03\x91\x03\x14\x03\x00\x03\x45\0" }, + { 0x1f8c, 0, 255, "\x03\x91\x03\x13\x03\x01\x03\x45\0" }, + { 0x1f8d, 0, 255, "\x03\x91\x03\x14\x03\x01\x03\x45\0" }, + { 0x1f8e, 0, 255, "\x03\x91\x03\x13\x03\x42\x03\x45\0" }, + { 0x1f8f, 0, 255, "\x03\x91\x03\x14\x03\x42\x03\x45\0" }, + { 0x1f90, 0, 255, "\x03\xb7\x03\x13\x03\x45\0" }, + { 0x1f91, 0, 255, "\x03\xb7\x03\x14\x03\x45\0" }, + { 0x1f92, 0, 255, "\x03\xb7\x03\x13\x03\x00\x03\x45\0" }, + { 0x1f93, 0, 255, "\x03\xb7\x03\x14\x03\x00\x03\x45\0" }, + { 0x1f94, 0, 255, "\x03\xb7\x03\x13\x03\x01\x03\x45\0" }, + { 0x1f95, 0, 255, "\x03\xb7\x03\x14\x03\x01\x03\x45\0" }, + { 0x1f96, 0, 255, "\x03\xb7\x03\x13\x03\x42\x03\x45\0" }, + { 0x1f97, 0, 255, "\x03\xb7\x03\x14\x03\x42\x03\x45\0" }, + { 0x1f98, 0, 255, "\x03\x97\x03\x13\x03\x45\0" }, + { 0x1f99, 0, 255, "\x03\x97\x03\x14\x03\x45\0" }, + { 0x1f9a, 0, 255, "\x03\x97\x03\x13\x03\x00\x03\x45\0" }, + { 0x1f9b, 0, 255, "\x03\x97\x03\x14\x03\x00\x03\x45\0" }, + { 0x1f9c, 0, 255, "\x03\x97\x03\x13\x03\x01\x03\x45\0" }, + { 0x1f9d, 0, 255, "\x03\x97\x03\x14\x03\x01\x03\x45\0" }, + { 0x1f9e, 0, 255, "\x03\x97\x03\x13\x03\x42\x03\x45\0" }, + { 0x1f9f, 0, 255, "\x03\x97\x03\x14\x03\x42\x03\x45\0" }, + { 0x1fa0, 0, 255, "\x03\xc9\x03\x13\x03\x45\0" }, + { 0x1fa1, 0, 255, "\x03\xc9\x03\x14\x03\x45\0" }, + { 0x1fa2, 0, 255, "\x03\xc9\x03\x13\x03\x00\x03\x45\0" }, + { 0x1fa3, 0, 255, "\x03\xc9\x03\x14\x03\x00\x03\x45\0" }, + { 0x1fa4, 0, 255, "\x03\xc9\x03\x13\x03\x01\x03\x45\0" }, + { 0x1fa5, 0, 255, "\x03\xc9\x03\x14\x03\x01\x03\x45\0" }, + { 0x1fa6, 0, 255, "\x03\xc9\x03\x13\x03\x42\x03\x45\0" }, + { 0x1fa7, 0, 255, "\x03\xc9\x03\x14\x03\x42\x03\x45\0" }, + { 0x1fa8, 0, 255, "\x03\xa9\x03\x13\x03\x45\0" }, + { 0x1fa9, 0, 255, "\x03\xa9\x03\x14\x03\x45\0" }, + { 0x1faa, 0, 255, "\x03\xa9\x03\x13\x03\x00\x03\x45\0" }, + { 0x1fab, 0, 255, "\x03\xa9\x03\x14\x03\x00\x03\x45\0" }, + { 0x1fac, 0, 255, "\x03\xa9\x03\x13\x03\x01\x03\x45\0" }, + { 0x1fad, 0, 255, "\x03\xa9\x03\x14\x03\x01\x03\x45\0" }, + { 0x1fae, 0, 255, "\x03\xa9\x03\x13\x03\x42\x03\x45\0" }, + { 0x1faf, 0, 255, "\x03\xa9\x03\x14\x03\x42\x03\x45\0" }, + { 0x1fb0, 0, 255, "\x03\xb1\x03\x06\0" }, + { 0x1fb1, 0, 255, "\x03\xb1\x03\x04\0" }, + { 0x1fb2, 0, 255, "\x03\xb1\x03\x00\x03\x45\0" }, + { 0x1fb3, 0, 255, "\x03\xb1\x03\x45\0" }, + { 0x1fb4, 0, 255, "\x03\xb1\x03\x01\x03\x45\0" }, + { 0x1fb6, 0, 255, "\x03\xb1\x03\x42\0" }, + { 0x1fb7, 0, 255, "\x03\xb1\x03\x42\x03\x45\0" }, + { 0x1fb8, 0, 255, "\x03\x91\x03\x06\0" }, + { 0x1fb9, 0, 255, "\x03\x91\x03\x04\0" }, + { 0x1fba, 0, 255, "\x03\x91\x03\x00\0" }, + { 0x1fbb, 0, 255, "\x03\x91\x03\x01\0" }, + { 0x1fbc, 0, 255, "\x03\x91\x03\x45\0" }, + { 0x1fbd, 255, 0, "\x00\x20\x03\x13\0" }, + { 0x1fbe, 0, 255, "\x03\xb9\0" }, + { 0x1fbf, 255, 0, "\x00\x20\x03\x13\0" }, + { 0x1fc0, 255, 0, "\x00\x20\x03\x42\0" }, + { 0x1fc1, 0, 6, "\x00\xa8\x03\x42\x00\x00\x00\x20\x03\x08\x03\x42\0" }, + { 0x1fc2, 0, 255, "\x03\xb7\x03\x00\x03\x45\0" }, + { 0x1fc3, 0, 255, "\x03\xb7\x03\x45\0" }, + { 0x1fc4, 0, 255, "\x03\xb7\x03\x01\x03\x45\0" }, + { 0x1fc6, 0, 255, "\x03\xb7\x03\x42\0" }, + { 0x1fc7, 0, 255, "\x03\xb7\x03\x42\x03\x45\0" }, + { 0x1fc8, 0, 255, "\x03\x95\x03\x00\0" }, + { 0x1fc9, 0, 255, "\x03\x95\x03\x01\0" }, + { 0x1fca, 0, 255, "\x03\x97\x03\x00\0" }, + { 0x1fcb, 0, 255, "\x03\x97\x03\x01\0" }, + { 0x1fcc, 0, 255, "\x03\x97\x03\x45\0" }, + { 0x1fcd, 0, 6, "\x1f\xbf\x03\x00\x00\x00\x00\x20\x03\x13\x03\x00\0" }, + { 0x1fce, 0, 6, "\x1f\xbf\x03\x01\x00\x00\x00\x20\x03\x13\x03\x01\0" }, + { 0x1fcf, 0, 6, "\x1f\xbf\x03\x42\x00\x00\x00\x20\x03\x13\x03\x42\0" }, + { 0x1fd0, 0, 255, "\x03\xb9\x03\x06\0" }, + { 0x1fd1, 0, 255, "\x03\xb9\x03\x04\0" }, + { 0x1fd2, 0, 255, "\x03\xb9\x03\x08\x03\x00\0" }, + { 0x1fd3, 0, 255, "\x03\xb9\x03\x08\x03\x01\0" }, + { 0x1fd6, 0, 255, "\x03\xb9\x03\x42\0" }, + { 0x1fd7, 0, 255, "\x03\xb9\x03\x08\x03\x42\0" }, + { 0x1fd8, 0, 255, "\x03\x99\x03\x06\0" }, + { 0x1fd9, 0, 255, "\x03\x99\x03\x04\0" }, + { 0x1fda, 0, 255, "\x03\x99\x03\x00\0" }, + { 0x1fdb, 0, 255, "\x03\x99\x03\x01\0" }, + { 0x1fdd, 0, 6, "\x1f\xfe\x03\x00\x00\x00\x00\x20\x03\x14\x03\x00\0" }, + { 0x1fde, 0, 6, "\x1f\xfe\x03\x01\x00\x00\x00\x20\x03\x14\x03\x01\0" }, + { 0x1fdf, 0, 6, "\x1f\xfe\x03\x42\x00\x00\x00\x20\x03\x14\x03\x42\0" }, + { 0x1fe0, 0, 255, "\x03\xc5\x03\x06\0" }, + { 0x1fe1, 0, 255, "\x03\xc5\x03\x04\0" }, + { 0x1fe2, 0, 255, "\x03\xc5\x03\x08\x03\x00\0" }, + { 0x1fe3, 0, 255, "\x03\xc5\x03\x08\x03\x01\0" }, + { 0x1fe4, 0, 255, "\x03\xc1\x03\x13\0" }, + { 0x1fe5, 0, 255, "\x03\xc1\x03\x14\0" }, + { 0x1fe6, 0, 255, "\x03\xc5\x03\x42\0" }, + { 0x1fe7, 0, 255, "\x03\xc5\x03\x08\x03\x42\0" }, + { 0x1fe8, 0, 255, "\x03\xa5\x03\x06\0" }, + { 0x1fe9, 0, 255, "\x03\xa5\x03\x04\0" }, + { 0x1fea, 0, 255, "\x03\xa5\x03\x00\0" }, + { 0x1feb, 0, 255, "\x03\xa5\x03\x01\0" }, + { 0x1fec, 0, 255, "\x03\xa1\x03\x14\0" }, + { 0x1fed, 0, 6, "\x00\xa8\x03\x00\x00\x00\x00\x20\x03\x08\x03\x00\0" }, + { 0x1fee, 0, 6, "\x00\xa8\x03\x01\x00\x00\x00\x20\x03\x08\x03\x01\0" }, + { 0x1fef, 0, 255, "\x00\x60\0" }, + { 0x1ff2, 0, 255, "\x03\xc9\x03\x00\x03\x45\0" }, + { 0x1ff3, 0, 255, "\x03\xc9\x03\x45\0" }, + { 0x1ff4, 0, 255, "\x03\xc9\x03\x01\x03\x45\0" }, + { 0x1ff6, 0, 255, "\x03\xc9\x03\x42\0" }, + { 0x1ff7, 0, 255, "\x03\xc9\x03\x42\x03\x45\0" }, + { 0x1ff8, 0, 255, "\x03\x9f\x03\x00\0" }, + { 0x1ff9, 0, 255, "\x03\x9f\x03\x01\0" }, + { 0x1ffa, 0, 255, "\x03\xa9\x03\x00\0" }, + { 0x1ffb, 0, 255, "\x03\xa9\x03\x01\0" }, + { 0x1ffc, 0, 255, "\x03\xa9\x03\x45\0" }, + { 0x1ffd, 0, 4, "\x00\xb4\x00\x00\x00\x20\x03\x01\0" }, + { 0x1ffe, 255, 0, "\x00\x20\x03\x14\0" }, + { 0x2000, 0, 4, "\x20\x02\x00\x00\x00\x20\0" }, + { 0x2001, 0, 4, "\x20\x03\x00\x00\x00\x20\0" }, + { 0x2002, 255, 0, "\x00\x20\0" }, + { 0x2003, 255, 0, "\x00\x20\0" }, + { 0x2004, 255, 0, "\x00\x20\0" }, + { 0x2005, 255, 0, "\x00\x20\0" }, + { 0x2006, 255, 0, "\x00\x20\0" }, + { 0x2007, 255, 0, "\x00\x20\0" }, + { 0x2008, 255, 0, "\x00\x20\0" }, + { 0x2009, 255, 0, "\x00\x20\0" }, + { 0x200a, 255, 0, "\x00\x20\0" }, + { 0x2011, 255, 0, "\x20\x10\0" }, + { 0x2017, 255, 0, "\x00\x20\x03\x33\0" }, + { 0x2024, 255, 0, "\x00\x2e\0" }, + { 0x2025, 255, 0, "\x00\x2e\x00\x2e\0" }, + { 0x2026, 255, 0, "\x00\x2e\x00\x2e\x00\x2e\0" }, + { 0x202f, 255, 0, "\x00\x20\0" }, + { 0x2033, 255, 0, "\x20\x32\x20\x32\0" }, + { 0x2034, 255, 0, "\x20\x32\x20\x32\x20\x32\0" }, + { 0x2036, 255, 0, "\x20\x35\x20\x35\0" }, + { 0x2037, 255, 0, "\x20\x35\x20\x35\x20\x35\0" }, + { 0x203c, 255, 0, "\x00\x21\x00\x21\0" }, + { 0x203e, 255, 0, "\x00\x20\x03\x05\0" }, + { 0x2048, 255, 0, "\x00\x3f\x00\x21\0" }, + { 0x2049, 255, 0, "\x00\x21\x00\x3f\0" }, + { 0x2070, 255, 0, "\x00\x30\0" }, + { 0x2074, 255, 0, "\x00\x34\0" }, + { 0x2075, 255, 0, "\x00\x35\0" }, + { 0x2076, 255, 0, "\x00\x36\0" }, + { 0x2077, 255, 0, "\x00\x37\0" }, + { 0x2078, 255, 0, "\x00\x38\0" }, + { 0x2079, 255, 0, "\x00\x39\0" }, + { 0x207a, 255, 0, "\x00\x2b\0" }, + { 0x207b, 255, 0, "\x22\x12\0" }, + { 0x207c, 255, 0, "\x00\x3d\0" }, + { 0x207d, 255, 0, "\x00\x28\0" }, + { 0x207e, 255, 0, "\x00\x29\0" }, + { 0x207f, 255, 0, "\x00\x6e\0" }, + { 0x2080, 255, 0, "\x00\x30\0" }, + { 0x2081, 255, 0, "\x00\x31\0" }, + { 0x2082, 255, 0, "\x00\x32\0" }, + { 0x2083, 255, 0, "\x00\x33\0" }, + { 0x2084, 255, 0, "\x00\x34\0" }, + { 0x2085, 255, 0, "\x00\x35\0" }, + { 0x2086, 255, 0, "\x00\x36\0" }, + { 0x2087, 255, 0, "\x00\x37\0" }, + { 0x2088, 255, 0, "\x00\x38\0" }, + { 0x2089, 255, 0, "\x00\x39\0" }, + { 0x208a, 255, 0, "\x00\x2b\0" }, + { 0x208b, 255, 0, "\x22\x12\0" }, + { 0x208c, 255, 0, "\x00\x3d\0" }, + { 0x208d, 255, 0, "\x00\x28\0" }, + { 0x208e, 255, 0, "\x00\x29\0" }, + { 0x20a8, 255, 0, "\x00\x52\x00\x73\0" }, + { 0x2100, 255, 0, "\x00\x61\x00\x2f\x00\x63\0" }, + { 0x2101, 255, 0, "\x00\x61\x00\x2f\x00\x73\0" }, + { 0x2102, 255, 0, "\x00\x43\0" }, + { 0x2103, 255, 0, "\x00\xb0\x00\x43\0" }, + { 0x2105, 255, 0, "\x00\x63\x00\x2f\x00\x6f\0" }, + { 0x2106, 255, 0, "\x00\x63\x00\x2f\x00\x75\0" }, + { 0x2107, 255, 0, "\x01\x90\0" }, + { 0x2109, 255, 0, "\x00\xb0\x00\x46\0" }, + { 0x210a, 255, 0, "\x00\x67\0" }, + { 0x210b, 255, 0, "\x00\x48\0" }, + { 0x210c, 255, 0, "\x00\x48\0" }, + { 0x210d, 255, 0, "\x00\x48\0" }, + { 0x210e, 255, 0, "\x00\x68\0" }, + { 0x210f, 255, 0, "\x01\x27\0" }, + { 0x2110, 255, 0, "\x00\x49\0" }, + { 0x2111, 255, 0, "\x00\x49\0" }, + { 0x2112, 255, 0, "\x00\x4c\0" }, + { 0x2113, 255, 0, "\x00\x6c\0" }, + { 0x2115, 255, 0, "\x00\x4e\0" }, + { 0x2116, 255, 0, "\x00\x4e\x00\x6f\0" }, + { 0x2119, 255, 0, "\x00\x50\0" }, + { 0x211a, 255, 0, "\x00\x51\0" }, + { 0x211b, 255, 0, "\x00\x52\0" }, + { 0x211c, 255, 0, "\x00\x52\0" }, + { 0x211d, 255, 0, "\x00\x52\0" }, + { 0x2120, 255, 0, "\x00\x53\x00\x4d\0" }, + { 0x2121, 255, 0, "\x00\x54\x00\x45\x00\x4c\0" }, + { 0x2122, 255, 0, "\x00\x54\x00\x4d\0" }, + { 0x2124, 255, 0, "\x00\x5a\0" }, + { 0x2126, 0, 255, "\x03\xa9\0" }, + { 0x2128, 255, 0, "\x00\x5a\0" }, + { 0x212a, 0, 255, "\x00\x4b\0" }, + { 0x212b, 0, 255, "\x00\x41\x03\x0a\0" }, + { 0x212c, 255, 0, "\x00\x42\0" }, + { 0x212d, 255, 0, "\x00\x43\0" }, + { 0x212f, 255, 0, "\x00\x65\0" }, + { 0x2130, 255, 0, "\x00\x45\0" }, + { 0x2131, 255, 0, "\x00\x46\0" }, + { 0x2133, 255, 0, "\x00\x4d\0" }, + { 0x2134, 255, 0, "\x00\x6f\0" }, + { 0x2135, 255, 0, "\x05\xd0\0" }, + { 0x2136, 255, 0, "\x05\xd1\0" }, + { 0x2137, 255, 0, "\x05\xd2\0" }, + { 0x2138, 255, 0, "\x05\xd3\0" }, + { 0x2139, 255, 0, "\x00\x69\0" }, + { 0x2153, 255, 0, "\x00\x31\x20\x44\x00\x33\0" }, + { 0x2154, 255, 0, "\x00\x32\x20\x44\x00\x33\0" }, + { 0x2155, 255, 0, "\x00\x31\x20\x44\x00\x35\0" }, + { 0x2156, 255, 0, "\x00\x32\x20\x44\x00\x35\0" }, + { 0x2157, 255, 0, "\x00\x33\x20\x44\x00\x35\0" }, + { 0x2158, 255, 0, "\x00\x34\x20\x44\x00\x35\0" }, + { 0x2159, 255, 0, "\x00\x31\x20\x44\x00\x36\0" }, + { 0x215a, 255, 0, "\x00\x35\x20\x44\x00\x36\0" }, + { 0x215b, 255, 0, "\x00\x31\x20\x44\x00\x38\0" }, + { 0x215c, 255, 0, "\x00\x33\x20\x44\x00\x38\0" }, + { 0x215d, 255, 0, "\x00\x35\x20\x44\x00\x38\0" }, + { 0x215e, 255, 0, "\x00\x37\x20\x44\x00\x38\0" }, + { 0x215f, 255, 0, "\x00\x31\x20\x44\0" }, + { 0x2160, 255, 0, "\x00\x49\0" }, + { 0x2161, 255, 0, "\x00\x49\x00\x49\0" }, + { 0x2162, 255, 0, "\x00\x49\x00\x49\x00\x49\0" }, + { 0x2163, 255, 0, "\x00\x49\x00\x56\0" }, + { 0x2164, 255, 0, "\x00\x56\0" }, + { 0x2165, 255, 0, "\x00\x56\x00\x49\0" }, + { 0x2166, 255, 0, "\x00\x56\x00\x49\x00\x49\0" }, + { 0x2167, 255, 0, "\x00\x56\x00\x49\x00\x49\x00\x49\0" }, + { 0x2168, 255, 0, "\x00\x49\x00\x58\0" }, + { 0x2169, 255, 0, "\x00\x58\0" }, + { 0x216a, 255, 0, "\x00\x58\x00\x49\0" }, + { 0x216b, 255, 0, "\x00\x58\x00\x49\x00\x49\0" }, + { 0x216c, 255, 0, "\x00\x4c\0" }, + { 0x216d, 255, 0, "\x00\x43\0" }, + { 0x216e, 255, 0, "\x00\x44\0" }, + { 0x216f, 255, 0, "\x00\x4d\0" }, + { 0x2170, 255, 0, "\x00\x69\0" }, + { 0x2171, 255, 0, "\x00\x69\x00\x69\0" }, + { 0x2172, 255, 0, "\x00\x69\x00\x69\x00\x69\0" }, + { 0x2173, 255, 0, "\x00\x69\x00\x76\0" }, + { 0x2174, 255, 0, "\x00\x76\0" }, + { 0x2175, 255, 0, "\x00\x76\x00\x69\0" }, + { 0x2176, 255, 0, "\x00\x76\x00\x69\x00\x69\0" }, + { 0x2177, 255, 0, "\x00\x76\x00\x69\x00\x69\x00\x69\0" }, + { 0x2178, 255, 0, "\x00\x69\x00\x78\0" }, + { 0x2179, 255, 0, "\x00\x78\0" }, + { 0x217a, 255, 0, "\x00\x78\x00\x69\0" }, + { 0x217b, 255, 0, "\x00\x78\x00\x69\x00\x69\0" }, + { 0x217c, 255, 0, "\x00\x6c\0" }, + { 0x217d, 255, 0, "\x00\x63\0" }, + { 0x217e, 255, 0, "\x00\x64\0" }, + { 0x217f, 255, 0, "\x00\x6d\0" }, + { 0x219a, 0, 255, "\x21\x90\x03\x38\0" }, + { 0x219b, 0, 255, "\x21\x92\x03\x38\0" }, + { 0x21ae, 0, 255, "\x21\x94\x03\x38\0" }, + { 0x21cd, 0, 255, "\x21\xd0\x03\x38\0" }, + { 0x21ce, 0, 255, "\x21\xd4\x03\x38\0" }, + { 0x21cf, 0, 255, "\x21\xd2\x03\x38\0" }, + { 0x2204, 0, 255, "\x22\x03\x03\x38\0" }, + { 0x2209, 0, 255, "\x22\x08\x03\x38\0" }, + { 0x220c, 0, 255, "\x22\x0b\x03\x38\0" }, + { 0x2224, 0, 255, "\x22\x23\x03\x38\0" }, + { 0x2226, 0, 255, "\x22\x25\x03\x38\0" }, + { 0x222c, 255, 0, "\x22\x2b\x22\x2b\0" }, + { 0x222d, 255, 0, "\x22\x2b\x22\x2b\x22\x2b\0" }, + { 0x222f, 255, 0, "\x22\x2e\x22\x2e\0" }, + { 0x2230, 255, 0, "\x22\x2e\x22\x2e\x22\x2e\0" }, + { 0x2241, 0, 255, "\x22\x3c\x03\x38\0" }, + { 0x2244, 0, 255, "\x22\x43\x03\x38\0" }, + { 0x2247, 0, 255, "\x22\x45\x03\x38\0" }, + { 0x2249, 0, 255, "\x22\x48\x03\x38\0" }, + { 0x2260, 0, 255, "\x00\x3d\x03\x38\0" }, + { 0x2262, 0, 255, "\x22\x61\x03\x38\0" }, + { 0x226d, 0, 255, "\x22\x4d\x03\x38\0" }, + { 0x226e, 0, 255, "\x00\x3c\x03\x38\0" }, + { 0x226f, 0, 255, "\x00\x3e\x03\x38\0" }, + { 0x2270, 0, 255, "\x22\x64\x03\x38\0" }, + { 0x2271, 0, 255, "\x22\x65\x03\x38\0" }, + { 0x2274, 0, 255, "\x22\x72\x03\x38\0" }, + { 0x2275, 0, 255, "\x22\x73\x03\x38\0" }, + { 0x2278, 0, 255, "\x22\x76\x03\x38\0" }, + { 0x2279, 0, 255, "\x22\x77\x03\x38\0" }, + { 0x2280, 0, 255, "\x22\x7a\x03\x38\0" }, + { 0x2281, 0, 255, "\x22\x7b\x03\x38\0" }, + { 0x2284, 0, 255, "\x22\x82\x03\x38\0" }, + { 0x2285, 0, 255, "\x22\x83\x03\x38\0" }, + { 0x2288, 0, 255, "\x22\x86\x03\x38\0" }, + { 0x2289, 0, 255, "\x22\x87\x03\x38\0" }, + { 0x22ac, 0, 255, "\x22\xa2\x03\x38\0" }, + { 0x22ad, 0, 255, "\x22\xa8\x03\x38\0" }, + { 0x22ae, 0, 255, "\x22\xa9\x03\x38\0" }, + { 0x22af, 0, 255, "\x22\xab\x03\x38\0" }, + { 0x22e0, 0, 255, "\x22\x7c\x03\x38\0" }, + { 0x22e1, 0, 255, "\x22\x7d\x03\x38\0" }, + { 0x22e2, 0, 255, "\x22\x91\x03\x38\0" }, + { 0x22e3, 0, 255, "\x22\x92\x03\x38\0" }, + { 0x22ea, 0, 255, "\x22\xb2\x03\x38\0" }, + { 0x22eb, 0, 255, "\x22\xb3\x03\x38\0" }, + { 0x22ec, 0, 255, "\x22\xb4\x03\x38\0" }, + { 0x22ed, 0, 255, "\x22\xb5\x03\x38\0" }, + { 0x2329, 0, 255, "\x30\x08\0" }, + { 0x232a, 0, 255, "\x30\x09\0" }, + { 0x2460, 255, 0, "\x00\x31\0" }, + { 0x2461, 255, 0, "\x00\x32\0" }, + { 0x2462, 255, 0, "\x00\x33\0" }, + { 0x2463, 255, 0, "\x00\x34\0" }, + { 0x2464, 255, 0, "\x00\x35\0" }, + { 0x2465, 255, 0, "\x00\x36\0" }, + { 0x2466, 255, 0, "\x00\x37\0" }, + { 0x2467, 255, 0, "\x00\x38\0" }, + { 0x2468, 255, 0, "\x00\x39\0" }, + { 0x2469, 255, 0, "\x00\x31\x00\x30\0" }, + { 0x246a, 255, 0, "\x00\x31\x00\x31\0" }, + { 0x246b, 255, 0, "\x00\x31\x00\x32\0" }, + { 0x246c, 255, 0, "\x00\x31\x00\x33\0" }, + { 0x246d, 255, 0, "\x00\x31\x00\x34\0" }, + { 0x246e, 255, 0, "\x00\x31\x00\x35\0" }, + { 0x246f, 255, 0, "\x00\x31\x00\x36\0" }, + { 0x2470, 255, 0, "\x00\x31\x00\x37\0" }, + { 0x2471, 255, 0, "\x00\x31\x00\x38\0" }, + { 0x2472, 255, 0, "\x00\x31\x00\x39\0" }, + { 0x2473, 255, 0, "\x00\x32\x00\x30\0" }, + { 0x2474, 255, 0, "\x00\x28\x00\x31\x00\x29\0" }, + { 0x2475, 255, 0, "\x00\x28\x00\x32\x00\x29\0" }, + { 0x2476, 255, 0, "\x00\x28\x00\x33\x00\x29\0" }, + { 0x2477, 255, 0, "\x00\x28\x00\x34\x00\x29\0" }, + { 0x2478, 255, 0, "\x00\x28\x00\x35\x00\x29\0" }, + { 0x2479, 255, 0, "\x00\x28\x00\x36\x00\x29\0" }, + { 0x247a, 255, 0, "\x00\x28\x00\x37\x00\x29\0" }, + { 0x247b, 255, 0, "\x00\x28\x00\x38\x00\x29\0" }, + { 0x247c, 255, 0, "\x00\x28\x00\x39\x00\x29\0" }, + { 0x247d, 255, 0, "\x00\x28\x00\x31\x00\x30\x00\x29\0" }, + { 0x247e, 255, 0, "\x00\x28\x00\x31\x00\x31\x00\x29\0" }, + { 0x247f, 255, 0, "\x00\x28\x00\x31\x00\x32\x00\x29\0" }, + { 0x2480, 255, 0, "\x00\x28\x00\x31\x00\x33\x00\x29\0" }, + { 0x2481, 255, 0, "\x00\x28\x00\x31\x00\x34\x00\x29\0" }, + { 0x2482, 255, 0, "\x00\x28\x00\x31\x00\x35\x00\x29\0" }, + { 0x2483, 255, 0, "\x00\x28\x00\x31\x00\x36\x00\x29\0" }, + { 0x2484, 255, 0, "\x00\x28\x00\x31\x00\x37\x00\x29\0" }, + { 0x2485, 255, 0, "\x00\x28\x00\x31\x00\x38\x00\x29\0" }, + { 0x2486, 255, 0, "\x00\x28\x00\x31\x00\x39\x00\x29\0" }, + { 0x2487, 255, 0, "\x00\x28\x00\x32\x00\x30\x00\x29\0" }, + { 0x2488, 255, 0, "\x00\x31\x00\x2e\0" }, + { 0x2489, 255, 0, "\x00\x32\x00\x2e\0" }, + { 0x248a, 255, 0, "\x00\x33\x00\x2e\0" }, + { 0x248b, 255, 0, "\x00\x34\x00\x2e\0" }, + { 0x248c, 255, 0, "\x00\x35\x00\x2e\0" }, + { 0x248d, 255, 0, "\x00\x36\x00\x2e\0" }, + { 0x248e, 255, 0, "\x00\x37\x00\x2e\0" }, + { 0x248f, 255, 0, "\x00\x38\x00\x2e\0" }, + { 0x2490, 255, 0, "\x00\x39\x00\x2e\0" }, + { 0x2491, 255, 0, "\x00\x31\x00\x30\x00\x2e\0" }, + { 0x2492, 255, 0, "\x00\x31\x00\x31\x00\x2e\0" }, + { 0x2493, 255, 0, "\x00\x31\x00\x32\x00\x2e\0" }, + { 0x2494, 255, 0, "\x00\x31\x00\x33\x00\x2e\0" }, + { 0x2495, 255, 0, "\x00\x31\x00\x34\x00\x2e\0" }, + { 0x2496, 255, 0, "\x00\x31\x00\x35\x00\x2e\0" }, + { 0x2497, 255, 0, "\x00\x31\x00\x36\x00\x2e\0" }, + { 0x2498, 255, 0, "\x00\x31\x00\x37\x00\x2e\0" }, + { 0x2499, 255, 0, "\x00\x31\x00\x38\x00\x2e\0" }, + { 0x249a, 255, 0, "\x00\x31\x00\x39\x00\x2e\0" }, + { 0x249b, 255, 0, "\x00\x32\x00\x30\x00\x2e\0" }, + { 0x249c, 255, 0, "\x00\x28\x00\x61\x00\x29\0" }, + { 0x249d, 255, 0, "\x00\x28\x00\x62\x00\x29\0" }, + { 0x249e, 255, 0, "\x00\x28\x00\x63\x00\x29\0" }, + { 0x249f, 255, 0, "\x00\x28\x00\x64\x00\x29\0" }, + { 0x24a0, 255, 0, "\x00\x28\x00\x65\x00\x29\0" }, + { 0x24a1, 255, 0, "\x00\x28\x00\x66\x00\x29\0" }, + { 0x24a2, 255, 0, "\x00\x28\x00\x67\x00\x29\0" }, + { 0x24a3, 255, 0, "\x00\x28\x00\x68\x00\x29\0" }, + { 0x24a4, 255, 0, "\x00\x28\x00\x69\x00\x29\0" }, + { 0x24a5, 255, 0, "\x00\x28\x00\x6a\x00\x29\0" }, + { 0x24a6, 255, 0, "\x00\x28\x00\x6b\x00\x29\0" }, + { 0x24a7, 255, 0, "\x00\x28\x00\x6c\x00\x29\0" }, + { 0x24a8, 255, 0, "\x00\x28\x00\x6d\x00\x29\0" }, + { 0x24a9, 255, 0, "\x00\x28\x00\x6e\x00\x29\0" }, + { 0x24aa, 255, 0, "\x00\x28\x00\x6f\x00\x29\0" }, + { 0x24ab, 255, 0, "\x00\x28\x00\x70\x00\x29\0" }, + { 0x24ac, 255, 0, "\x00\x28\x00\x71\x00\x29\0" }, + { 0x24ad, 255, 0, "\x00\x28\x00\x72\x00\x29\0" }, + { 0x24ae, 255, 0, "\x00\x28\x00\x73\x00\x29\0" }, + { 0x24af, 255, 0, "\x00\x28\x00\x74\x00\x29\0" }, + { 0x24b0, 255, 0, "\x00\x28\x00\x75\x00\x29\0" }, + { 0x24b1, 255, 0, "\x00\x28\x00\x76\x00\x29\0" }, + { 0x24b2, 255, 0, "\x00\x28\x00\x77\x00\x29\0" }, + { 0x24b3, 255, 0, "\x00\x28\x00\x78\x00\x29\0" }, + { 0x24b4, 255, 0, "\x00\x28\x00\x79\x00\x29\0" }, + { 0x24b5, 255, 0, "\x00\x28\x00\x7a\x00\x29\0" }, + { 0x24b6, 255, 0, "\x00\x41\0" }, + { 0x24b7, 255, 0, "\x00\x42\0" }, + { 0x24b8, 255, 0, "\x00\x43\0" }, + { 0x24b9, 255, 0, "\x00\x44\0" }, + { 0x24ba, 255, 0, "\x00\x45\0" }, + { 0x24bb, 255, 0, "\x00\x46\0" }, + { 0x24bc, 255, 0, "\x00\x47\0" }, + { 0x24bd, 255, 0, "\x00\x48\0" }, + { 0x24be, 255, 0, "\x00\x49\0" }, + { 0x24bf, 255, 0, "\x00\x4a\0" }, + { 0x24c0, 255, 0, "\x00\x4b\0" }, + { 0x24c1, 255, 0, "\x00\x4c\0" }, + { 0x24c2, 255, 0, "\x00\x4d\0" }, + { 0x24c3, 255, 0, "\x00\x4e\0" }, + { 0x24c4, 255, 0, "\x00\x4f\0" }, + { 0x24c5, 255, 0, "\x00\x50\0" }, + { 0x24c6, 255, 0, "\x00\x51\0" }, + { 0x24c7, 255, 0, "\x00\x52\0" }, + { 0x24c8, 255, 0, "\x00\x53\0" }, + { 0x24c9, 255, 0, "\x00\x54\0" }, + { 0x24ca, 255, 0, "\x00\x55\0" }, + { 0x24cb, 255, 0, "\x00\x56\0" }, + { 0x24cc, 255, 0, "\x00\x57\0" }, + { 0x24cd, 255, 0, "\x00\x58\0" }, + { 0x24ce, 255, 0, "\x00\x59\0" }, + { 0x24cf, 255, 0, "\x00\x5a\0" }, + { 0x24d0, 255, 0, "\x00\x61\0" }, + { 0x24d1, 255, 0, "\x00\x62\0" }, + { 0x24d2, 255, 0, "\x00\x63\0" }, + { 0x24d3, 255, 0, "\x00\x64\0" }, + { 0x24d4, 255, 0, "\x00\x65\0" }, + { 0x24d5, 255, 0, "\x00\x66\0" }, + { 0x24d6, 255, 0, "\x00\x67\0" }, + { 0x24d7, 255, 0, "\x00\x68\0" }, + { 0x24d8, 255, 0, "\x00\x69\0" }, + { 0x24d9, 255, 0, "\x00\x6a\0" }, + { 0x24da, 255, 0, "\x00\x6b\0" }, + { 0x24db, 255, 0, "\x00\x6c\0" }, + { 0x24dc, 255, 0, "\x00\x6d\0" }, + { 0x24dd, 255, 0, "\x00\x6e\0" }, + { 0x24de, 255, 0, "\x00\x6f\0" }, + { 0x24df, 255, 0, "\x00\x70\0" }, + { 0x24e0, 255, 0, "\x00\x71\0" }, + { 0x24e1, 255, 0, "\x00\x72\0" }, + { 0x24e2, 255, 0, "\x00\x73\0" }, + { 0x24e3, 255, 0, "\x00\x74\0" }, + { 0x24e4, 255, 0, "\x00\x75\0" }, + { 0x24e5, 255, 0, "\x00\x76\0" }, + { 0x24e6, 255, 0, "\x00\x77\0" }, + { 0x24e7, 255, 0, "\x00\x78\0" }, + { 0x24e8, 255, 0, "\x00\x79\0" }, + { 0x24e9, 255, 0, "\x00\x7a\0" }, + { 0x24ea, 255, 0, "\x00\x30\0" }, + { 0x2e9f, 255, 0, "\x6b\xcd\0" }, + { 0x2ef3, 255, 0, "\x9f\x9f\0" }, + { 0x2f00, 255, 0, "\x4e\x00\0" }, + { 0x2f01, 255, 0, "\x4e\x28\0" }, + { 0x2f02, 255, 0, "\x4e\x36\0" }, + { 0x2f03, 255, 0, "\x4e\x3f\0" }, + { 0x2f04, 255, 0, "\x4e\x59\0" }, + { 0x2f05, 255, 0, "\x4e\x85\0" }, + { 0x2f06, 255, 0, "\x4e\x8c\0" }, + { 0x2f07, 255, 0, "\x4e\xa0\0" }, + { 0x2f08, 255, 0, "\x4e\xba\0" }, + { 0x2f09, 255, 0, "\x51\x3f\0" }, + { 0x2f0a, 255, 0, "\x51\x65\0" }, + { 0x2f0b, 255, 0, "\x51\x6b\0" }, + { 0x2f0c, 255, 0, "\x51\x82\0" }, + { 0x2f0d, 255, 0, "\x51\x96\0" }, + { 0x2f0e, 255, 0, "\x51\xab\0" }, + { 0x2f0f, 255, 0, "\x51\xe0\0" }, + { 0x2f10, 255, 0, "\x51\xf5\0" }, + { 0x2f11, 255, 0, "\x52\x00\0" }, + { 0x2f12, 255, 0, "\x52\x9b\0" }, + { 0x2f13, 255, 0, "\x52\xf9\0" }, + { 0x2f14, 255, 0, "\x53\x15\0" }, + { 0x2f15, 255, 0, "\x53\x1a\0" }, + { 0x2f16, 255, 0, "\x53\x38\0" }, + { 0x2f17, 255, 0, "\x53\x41\0" }, + { 0x2f18, 255, 0, "\x53\x5c\0" }, + { 0x2f19, 255, 0, "\x53\x69\0" }, + { 0x2f1a, 255, 0, "\x53\x82\0" }, + { 0x2f1b, 255, 0, "\x53\xb6\0" }, + { 0x2f1c, 255, 0, "\x53\xc8\0" }, + { 0x2f1d, 255, 0, "\x53\xe3\0" }, + { 0x2f1e, 255, 0, "\x56\xd7\0" }, + { 0x2f1f, 255, 0, "\x57\x1f\0" }, + { 0x2f20, 255, 0, "\x58\xeb\0" }, + { 0x2f21, 255, 0, "\x59\x02\0" }, + { 0x2f22, 255, 0, "\x59\x0a\0" }, + { 0x2f23, 255, 0, "\x59\x15\0" }, + { 0x2f24, 255, 0, "\x59\x27\0" }, + { 0x2f25, 255, 0, "\x59\x73\0" }, + { 0x2f26, 255, 0, "\x5b\x50\0" }, + { 0x2f27, 255, 0, "\x5b\x80\0" }, + { 0x2f28, 255, 0, "\x5b\xf8\0" }, + { 0x2f29, 255, 0, "\x5c\x0f\0" }, + { 0x2f2a, 255, 0, "\x5c\x22\0" }, + { 0x2f2b, 255, 0, "\x5c\x38\0" }, + { 0x2f2c, 255, 0, "\x5c\x6e\0" }, + { 0x2f2d, 255, 0, "\x5c\x71\0" }, + { 0x2f2e, 255, 0, "\x5d\xdb\0" }, + { 0x2f2f, 255, 0, "\x5d\xe5\0" }, + { 0x2f30, 255, 0, "\x5d\xf1\0" }, + { 0x2f31, 255, 0, "\x5d\xfe\0" }, + { 0x2f32, 255, 0, "\x5e\x72\0" }, + { 0x2f33, 255, 0, "\x5e\x7a\0" }, + { 0x2f34, 255, 0, "\x5e\x7f\0" }, + { 0x2f35, 255, 0, "\x5e\xf4\0" }, + { 0x2f36, 255, 0, "\x5e\xfe\0" }, + { 0x2f37, 255, 0, "\x5f\x0b\0" }, + { 0x2f38, 255, 0, "\x5f\x13\0" }, + { 0x2f39, 255, 0, "\x5f\x50\0" }, + { 0x2f3a, 255, 0, "\x5f\x61\0" }, + { 0x2f3b, 255, 0, "\x5f\x73\0" }, + { 0x2f3c, 255, 0, "\x5f\xc3\0" }, + { 0x2f3d, 255, 0, "\x62\x08\0" }, + { 0x2f3e, 255, 0, "\x62\x36\0" }, + { 0x2f3f, 255, 0, "\x62\x4b\0" }, + { 0x2f40, 255, 0, "\x65\x2f\0" }, + { 0x2f41, 255, 0, "\x65\x34\0" }, + { 0x2f42, 255, 0, "\x65\x87\0" }, + { 0x2f43, 255, 0, "\x65\x97\0" }, + { 0x2f44, 255, 0, "\x65\xa4\0" }, + { 0x2f45, 255, 0, "\x65\xb9\0" }, + { 0x2f46, 255, 0, "\x65\xe0\0" }, + { 0x2f47, 255, 0, "\x65\xe5\0" }, + { 0x2f48, 255, 0, "\x66\xf0\0" }, + { 0x2f49, 255, 0, "\x67\x08\0" }, + { 0x2f4a, 255, 0, "\x67\x28\0" }, + { 0x2f4b, 255, 0, "\x6b\x20\0" }, + { 0x2f4c, 255, 0, "\x6b\x62\0" }, + { 0x2f4d, 255, 0, "\x6b\x79\0" }, + { 0x2f4e, 255, 0, "\x6b\xb3\0" }, + { 0x2f4f, 255, 0, "\x6b\xcb\0" }, + { 0x2f50, 255, 0, "\x6b\xd4\0" }, + { 0x2f51, 255, 0, "\x6b\xdb\0" }, + { 0x2f52, 255, 0, "\x6c\x0f\0" }, + { 0x2f53, 255, 0, "\x6c\x14\0" }, + { 0x2f54, 255, 0, "\x6c\x34\0" }, + { 0x2f55, 255, 0, "\x70\x6b\0" }, + { 0x2f56, 255, 0, "\x72\x2a\0" }, + { 0x2f57, 255, 0, "\x72\x36\0" }, + { 0x2f58, 255, 0, "\x72\x3b\0" }, + { 0x2f59, 255, 0, "\x72\x3f\0" }, + { 0x2f5a, 255, 0, "\x72\x47\0" }, + { 0x2f5b, 255, 0, "\x72\x59\0" }, + { 0x2f5c, 255, 0, "\x72\x5b\0" }, + { 0x2f5d, 255, 0, "\x72\xac\0" }, + { 0x2f5e, 255, 0, "\x73\x84\0" }, + { 0x2f5f, 255, 0, "\x73\x89\0" }, + { 0x2f60, 255, 0, "\x74\xdc\0" }, + { 0x2f61, 255, 0, "\x74\xe6\0" }, + { 0x2f62, 255, 0, "\x75\x18\0" }, + { 0x2f63, 255, 0, "\x75\x1f\0" }, + { 0x2f64, 255, 0, "\x75\x28\0" }, + { 0x2f65, 255, 0, "\x75\x30\0" }, + { 0x2f66, 255, 0, "\x75\x8b\0" }, + { 0x2f67, 255, 0, "\x75\x92\0" }, + { 0x2f68, 255, 0, "\x76\x76\0" }, + { 0x2f69, 255, 0, "\x76\x7d\0" }, + { 0x2f6a, 255, 0, "\x76\xae\0" }, + { 0x2f6b, 255, 0, "\x76\xbf\0" }, + { 0x2f6c, 255, 0, "\x76\xee\0" }, + { 0x2f6d, 255, 0, "\x77\xdb\0" }, + { 0x2f6e, 255, 0, "\x77\xe2\0" }, + { 0x2f6f, 255, 0, "\x77\xf3\0" }, + { 0x2f70, 255, 0, "\x79\x3a\0" }, + { 0x2f71, 255, 0, "\x79\xb8\0" }, + { 0x2f72, 255, 0, "\x79\xbe\0" }, + { 0x2f73, 255, 0, "\x7a\x74\0" }, + { 0x2f74, 255, 0, "\x7a\xcb\0" }, + { 0x2f75, 255, 0, "\x7a\xf9\0" }, + { 0x2f76, 255, 0, "\x7c\x73\0" }, + { 0x2f77, 255, 0, "\x7c\xf8\0" }, + { 0x2f78, 255, 0, "\x7f\x36\0" }, + { 0x2f79, 255, 0, "\x7f\x51\0" }, + { 0x2f7a, 255, 0, "\x7f\x8a\0" }, + { 0x2f7b, 255, 0, "\x7f\xbd\0" }, + { 0x2f7c, 255, 0, "\x80\x01\0" }, + { 0x2f7d, 255, 0, "\x80\x0c\0" }, + { 0x2f7e, 255, 0, "\x80\x12\0" }, + { 0x2f7f, 255, 0, "\x80\x33\0" }, + { 0x2f80, 255, 0, "\x80\x7f\0" }, + { 0x2f81, 255, 0, "\x80\x89\0" }, + { 0x2f82, 255, 0, "\x81\xe3\0" }, + { 0x2f83, 255, 0, "\x81\xea\0" }, + { 0x2f84, 255, 0, "\x81\xf3\0" }, + { 0x2f85, 255, 0, "\x81\xfc\0" }, + { 0x2f86, 255, 0, "\x82\x0c\0" }, + { 0x2f87, 255, 0, "\x82\x1b\0" }, + { 0x2f88, 255, 0, "\x82\x1f\0" }, + { 0x2f89, 255, 0, "\x82\x6e\0" }, + { 0x2f8a, 255, 0, "\x82\x72\0" }, + { 0x2f8b, 255, 0, "\x82\x78\0" }, + { 0x2f8c, 255, 0, "\x86\x4d\0" }, + { 0x2f8d, 255, 0, "\x86\x6b\0" }, + { 0x2f8e, 255, 0, "\x88\x40\0" }, + { 0x2f8f, 255, 0, "\x88\x4c\0" }, + { 0x2f90, 255, 0, "\x88\x63\0" }, + { 0x2f91, 255, 0, "\x89\x7e\0" }, + { 0x2f92, 255, 0, "\x89\x8b\0" }, + { 0x2f93, 255, 0, "\x89\xd2\0" }, + { 0x2f94, 255, 0, "\x8a\x00\0" }, + { 0x2f95, 255, 0, "\x8c\x37\0" }, + { 0x2f96, 255, 0, "\x8c\x46\0" }, + { 0x2f97, 255, 0, "\x8c\x55\0" }, + { 0x2f98, 255, 0, "\x8c\x78\0" }, + { 0x2f99, 255, 0, "\x8c\x9d\0" }, + { 0x2f9a, 255, 0, "\x8d\x64\0" }, + { 0x2f9b, 255, 0, "\x8d\x70\0" }, + { 0x2f9c, 255, 0, "\x8d\xb3\0" }, + { 0x2f9d, 255, 0, "\x8e\xab\0" }, + { 0x2f9e, 255, 0, "\x8e\xca\0" }, + { 0x2f9f, 255, 0, "\x8f\x9b\0" }, + { 0x2fa0, 255, 0, "\x8f\xb0\0" }, + { 0x2fa1, 255, 0, "\x8f\xb5\0" }, + { 0x2fa2, 255, 0, "\x90\x91\0" }, + { 0x2fa3, 255, 0, "\x91\x49\0" }, + { 0x2fa4, 255, 0, "\x91\xc6\0" }, + { 0x2fa5, 255, 0, "\x91\xcc\0" }, + { 0x2fa6, 255, 0, "\x91\xd1\0" }, + { 0x2fa7, 255, 0, "\x95\x77\0" }, + { 0x2fa8, 255, 0, "\x95\x80\0" }, + { 0x2fa9, 255, 0, "\x96\x1c\0" }, + { 0x2faa, 255, 0, "\x96\xb6\0" }, + { 0x2fab, 255, 0, "\x96\xb9\0" }, + { 0x2fac, 255, 0, "\x96\xe8\0" }, + { 0x2fad, 255, 0, "\x97\x51\0" }, + { 0x2fae, 255, 0, "\x97\x5e\0" }, + { 0x2faf, 255, 0, "\x97\x62\0" }, + { 0x2fb0, 255, 0, "\x97\x69\0" }, + { 0x2fb1, 255, 0, "\x97\xcb\0" }, + { 0x2fb2, 255, 0, "\x97\xed\0" }, + { 0x2fb3, 255, 0, "\x97\xf3\0" }, + { 0x2fb4, 255, 0, "\x98\x01\0" }, + { 0x2fb5, 255, 0, "\x98\xa8\0" }, + { 0x2fb6, 255, 0, "\x98\xdb\0" }, + { 0x2fb7, 255, 0, "\x98\xdf\0" }, + { 0x2fb8, 255, 0, "\x99\x96\0" }, + { 0x2fb9, 255, 0, "\x99\x99\0" }, + { 0x2fba, 255, 0, "\x99\xac\0" }, + { 0x2fbb, 255, 0, "\x9a\xa8\0" }, + { 0x2fbc, 255, 0, "\x9a\xd8\0" }, + { 0x2fbd, 255, 0, "\x9a\xdf\0" }, + { 0x2fbe, 255, 0, "\x9b\x25\0" }, + { 0x2fbf, 255, 0, "\x9b\x2f\0" }, + { 0x2fc0, 255, 0, "\x9b\x32\0" }, + { 0x2fc1, 255, 0, "\x9b\x3c\0" }, + { 0x2fc2, 255, 0, "\x9b\x5a\0" }, + { 0x2fc3, 255, 0, "\x9c\xe5\0" }, + { 0x2fc4, 255, 0, "\x9e\x75\0" }, + { 0x2fc5, 255, 0, "\x9e\x7f\0" }, + { 0x2fc6, 255, 0, "\x9e\xa5\0" }, + { 0x2fc7, 255, 0, "\x9e\xbb\0" }, + { 0x2fc8, 255, 0, "\x9e\xc3\0" }, + { 0x2fc9, 255, 0, "\x9e\xcd\0" }, + { 0x2fca, 255, 0, "\x9e\xd1\0" }, + { 0x2fcb, 255, 0, "\x9e\xf9\0" }, + { 0x2fcc, 255, 0, "\x9e\xfd\0" }, + { 0x2fcd, 255, 0, "\x9f\x0e\0" }, + { 0x2fce, 255, 0, "\x9f\x13\0" }, + { 0x2fcf, 255, 0, "\x9f\x20\0" }, + { 0x2fd0, 255, 0, "\x9f\x3b\0" }, + { 0x2fd1, 255, 0, "\x9f\x4a\0" }, + { 0x2fd2, 255, 0, "\x9f\x52\0" }, + { 0x2fd3, 255, 0, "\x9f\x8d\0" }, + { 0x2fd4, 255, 0, "\x9f\x9c\0" }, + { 0x2fd5, 255, 0, "\x9f\xa0\0" }, + { 0x3000, 255, 0, "\x00\x20\0" }, + { 0x3036, 255, 0, "\x30\x12\0" }, + { 0x3038, 255, 0, "\x53\x41\0" }, + { 0x3039, 255, 0, "\x53\x44\0" }, + { 0x303a, 255, 0, "\x53\x45\0" }, + { 0x304c, 0, 255, "\x30\x4b\x30\x99\0" }, + { 0x304e, 0, 255, "\x30\x4d\x30\x99\0" }, + { 0x3050, 0, 255, "\x30\x4f\x30\x99\0" }, + { 0x3052, 0, 255, "\x30\x51\x30\x99\0" }, + { 0x3054, 0, 255, "\x30\x53\x30\x99\0" }, + { 0x3056, 0, 255, "\x30\x55\x30\x99\0" }, + { 0x3058, 0, 255, "\x30\x57\x30\x99\0" }, + { 0x305a, 0, 255, "\x30\x59\x30\x99\0" }, + { 0x305c, 0, 255, "\x30\x5b\x30\x99\0" }, + { 0x305e, 0, 255, "\x30\x5d\x30\x99\0" }, + { 0x3060, 0, 255, "\x30\x5f\x30\x99\0" }, + { 0x3062, 0, 255, "\x30\x61\x30\x99\0" }, + { 0x3065, 0, 255, "\x30\x64\x30\x99\0" }, + { 0x3067, 0, 255, "\x30\x66\x30\x99\0" }, + { 0x3069, 0, 255, "\x30\x68\x30\x99\0" }, + { 0x3070, 0, 255, "\x30\x6f\x30\x99\0" }, + { 0x3071, 0, 255, "\x30\x6f\x30\x9a\0" }, + { 0x3073, 0, 255, "\x30\x72\x30\x99\0" }, + { 0x3074, 0, 255, "\x30\x72\x30\x9a\0" }, + { 0x3076, 0, 255, "\x30\x75\x30\x99\0" }, + { 0x3077, 0, 255, "\x30\x75\x30\x9a\0" }, + { 0x3079, 0, 255, "\x30\x78\x30\x99\0" }, + { 0x307a, 0, 255, "\x30\x78\x30\x9a\0" }, + { 0x307c, 0, 255, "\x30\x7b\x30\x99\0" }, + { 0x307d, 0, 255, "\x30\x7b\x30\x9a\0" }, + { 0x3094, 0, 255, "\x30\x46\x30\x99\0" }, + { 0x309b, 255, 0, "\x00\x20\x30\x99\0" }, + { 0x309c, 255, 0, "\x00\x20\x30\x9a\0" }, + { 0x309e, 0, 255, "\x30\x9d\x30\x99\0" }, + { 0x30ac, 0, 255, "\x30\xab\x30\x99\0" }, + { 0x30ae, 0, 255, "\x30\xad\x30\x99\0" }, + { 0x30b0, 0, 255, "\x30\xaf\x30\x99\0" }, + { 0x30b2, 0, 255, "\x30\xb1\x30\x99\0" }, + { 0x30b4, 0, 255, "\x30\xb3\x30\x99\0" }, + { 0x30b6, 0, 255, "\x30\xb5\x30\x99\0" }, + { 0x30b8, 0, 255, "\x30\xb7\x30\x99\0" }, + { 0x30ba, 0, 255, "\x30\xb9\x30\x99\0" }, + { 0x30bc, 0, 255, "\x30\xbb\x30\x99\0" }, + { 0x30be, 0, 255, "\x30\xbd\x30\x99\0" }, + { 0x30c0, 0, 255, "\x30\xbf\x30\x99\0" }, + { 0x30c2, 0, 255, "\x30\xc1\x30\x99\0" }, + { 0x30c5, 0, 255, "\x30\xc4\x30\x99\0" }, + { 0x30c7, 0, 255, "\x30\xc6\x30\x99\0" }, + { 0x30c9, 0, 255, "\x30\xc8\x30\x99\0" }, + { 0x30d0, 0, 255, "\x30\xcf\x30\x99\0" }, + { 0x30d1, 0, 255, "\x30\xcf\x30\x9a\0" }, + { 0x30d3, 0, 255, "\x30\xd2\x30\x99\0" }, + { 0x30d4, 0, 255, "\x30\xd2\x30\x9a\0" }, + { 0x30d6, 0, 255, "\x30\xd5\x30\x99\0" }, + { 0x30d7, 0, 255, "\x30\xd5\x30\x9a\0" }, + { 0x30d9, 0, 255, "\x30\xd8\x30\x99\0" }, + { 0x30da, 0, 255, "\x30\xd8\x30\x9a\0" }, + { 0x30dc, 0, 255, "\x30\xdb\x30\x99\0" }, + { 0x30dd, 0, 255, "\x30\xdb\x30\x9a\0" }, + { 0x30f4, 0, 255, "\x30\xa6\x30\x99\0" }, + { 0x30f7, 0, 255, "\x30\xef\x30\x99\0" }, + { 0x30f8, 0, 255, "\x30\xf0\x30\x99\0" }, + { 0x30f9, 0, 255, "\x30\xf1\x30\x99\0" }, + { 0x30fa, 0, 255, "\x30\xf2\x30\x99\0" }, + { 0x30fe, 0, 255, "\x30\xfd\x30\x99\0" }, + { 0x3131, 255, 0, "\x11\x00\0" }, + { 0x3132, 255, 0, "\x11\x01\0" }, + { 0x3133, 255, 0, "\x11\xaa\0" }, + { 0x3134, 255, 0, "\x11\x02\0" }, + { 0x3135, 255, 0, "\x11\xac\0" }, + { 0x3136, 255, 0, "\x11\xad\0" }, + { 0x3137, 255, 0, "\x11\x03\0" }, + { 0x3138, 255, 0, "\x11\x04\0" }, + { 0x3139, 255, 0, "\x11\x05\0" }, + { 0x313a, 255, 0, "\x11\xb0\0" }, + { 0x313b, 255, 0, "\x11\xb1\0" }, + { 0x313c, 255, 0, "\x11\xb2\0" }, + { 0x313d, 255, 0, "\x11\xb3\0" }, + { 0x313e, 255, 0, "\x11\xb4\0" }, + { 0x313f, 255, 0, "\x11\xb5\0" }, + { 0x3140, 255, 0, "\x11\x1a\0" }, + { 0x3141, 255, 0, "\x11\x06\0" }, + { 0x3142, 255, 0, "\x11\x07\0" }, + { 0x3143, 255, 0, "\x11\x08\0" }, + { 0x3144, 255, 0, "\x11\x21\0" }, + { 0x3145, 255, 0, "\x11\x09\0" }, + { 0x3146, 255, 0, "\x11\x0a\0" }, + { 0x3147, 255, 0, "\x11\x0b\0" }, + { 0x3148, 255, 0, "\x11\x0c\0" }, + { 0x3149, 255, 0, "\x11\x0d\0" }, + { 0x314a, 255, 0, "\x11\x0e\0" }, + { 0x314b, 255, 0, "\x11\x0f\0" }, + { 0x314c, 255, 0, "\x11\x10\0" }, + { 0x314d, 255, 0, "\x11\x11\0" }, + { 0x314e, 255, 0, "\x11\x12\0" }, + { 0x314f, 255, 0, "\x11\x61\0" }, + { 0x3150, 255, 0, "\x11\x62\0" }, + { 0x3151, 255, 0, "\x11\x63\0" }, + { 0x3152, 255, 0, "\x11\x64\0" }, + { 0x3153, 255, 0, "\x11\x65\0" }, + { 0x3154, 255, 0, "\x11\x66\0" }, + { 0x3155, 255, 0, "\x11\x67\0" }, + { 0x3156, 255, 0, "\x11\x68\0" }, + { 0x3157, 255, 0, "\x11\x69\0" }, + { 0x3158, 255, 0, "\x11\x6a\0" }, + { 0x3159, 255, 0, "\x11\x6b\0" }, + { 0x315a, 255, 0, "\x11\x6c\0" }, + { 0x315b, 255, 0, "\x11\x6d\0" }, + { 0x315c, 255, 0, "\x11\x6e\0" }, + { 0x315d, 255, 0, "\x11\x6f\0" }, + { 0x315e, 255, 0, "\x11\x70\0" }, + { 0x315f, 255, 0, "\x11\x71\0" }, + { 0x3160, 255, 0, "\x11\x72\0" }, + { 0x3161, 255, 0, "\x11\x73\0" }, + { 0x3162, 255, 0, "\x11\x74\0" }, + { 0x3163, 255, 0, "\x11\x75\0" }, + { 0x3164, 255, 0, "\x11\x60\0" }, + { 0x3165, 255, 0, "\x11\x14\0" }, + { 0x3166, 255, 0, "\x11\x15\0" }, + { 0x3167, 255, 0, "\x11\xc7\0" }, + { 0x3168, 255, 0, "\x11\xc8\0" }, + { 0x3169, 255, 0, "\x11\xcc\0" }, + { 0x316a, 255, 0, "\x11\xce\0" }, + { 0x316b, 255, 0, "\x11\xd3\0" }, + { 0x316c, 255, 0, "\x11\xd7\0" }, + { 0x316d, 255, 0, "\x11\xd9\0" }, + { 0x316e, 255, 0, "\x11\x1c\0" }, + { 0x316f, 255, 0, "\x11\xdd\0" }, + { 0x3170, 255, 0, "\x11\xdf\0" }, + { 0x3171, 255, 0, "\x11\x1d\0" }, + { 0x3172, 255, 0, "\x11\x1e\0" }, + { 0x3173, 255, 0, "\x11\x20\0" }, + { 0x3174, 255, 0, "\x11\x22\0" }, + { 0x3175, 255, 0, "\x11\x23\0" }, + { 0x3176, 255, 0, "\x11\x27\0" }, + { 0x3177, 255, 0, "\x11\x29\0" }, + { 0x3178, 255, 0, "\x11\x2b\0" }, + { 0x3179, 255, 0, "\x11\x2c\0" }, + { 0x317a, 255, 0, "\x11\x2d\0" }, + { 0x317b, 255, 0, "\x11\x2e\0" }, + { 0x317c, 255, 0, "\x11\x2f\0" }, + { 0x317d, 255, 0, "\x11\x32\0" }, + { 0x317e, 255, 0, "\x11\x36\0" }, + { 0x317f, 255, 0, "\x11\x40\0" }, + { 0x3180, 255, 0, "\x11\x47\0" }, + { 0x3181, 255, 0, "\x11\x4c\0" }, + { 0x3182, 255, 0, "\x11\xf1\0" }, + { 0x3183, 255, 0, "\x11\xf2\0" }, + { 0x3184, 255, 0, "\x11\x57\0" }, + { 0x3185, 255, 0, "\x11\x58\0" }, + { 0x3186, 255, 0, "\x11\x59\0" }, + { 0x3187, 255, 0, "\x11\x84\0" }, + { 0x3188, 255, 0, "\x11\x85\0" }, + { 0x3189, 255, 0, "\x11\x88\0" }, + { 0x318a, 255, 0, "\x11\x91\0" }, + { 0x318b, 255, 0, "\x11\x92\0" }, + { 0x318c, 255, 0, "\x11\x94\0" }, + { 0x318d, 255, 0, "\x11\x9e\0" }, + { 0x318e, 255, 0, "\x11\xa1\0" }, + { 0x3192, 255, 0, "\x4e\x00\0" }, + { 0x3193, 255, 0, "\x4e\x8c\0" }, + { 0x3194, 255, 0, "\x4e\x09\0" }, + { 0x3195, 255, 0, "\x56\xdb\0" }, + { 0x3196, 255, 0, "\x4e\x0a\0" }, + { 0x3197, 255, 0, "\x4e\x2d\0" }, + { 0x3198, 255, 0, "\x4e\x0b\0" }, + { 0x3199, 255, 0, "\x75\x32\0" }, + { 0x319a, 255, 0, "\x4e\x59\0" }, + { 0x319b, 255, 0, "\x4e\x19\0" }, + { 0x319c, 255, 0, "\x4e\x01\0" }, + { 0x319d, 255, 0, "\x59\x29\0" }, + { 0x319e, 255, 0, "\x57\x30\0" }, + { 0x319f, 255, 0, "\x4e\xba\0" }, + { 0x3200, 255, 0, "\x00\x28\x11\x00\x00\x29\0" }, + { 0x3201, 255, 0, "\x00\x28\x11\x02\x00\x29\0" }, + { 0x3202, 255, 0, "\x00\x28\x11\x03\x00\x29\0" }, + { 0x3203, 255, 0, "\x00\x28\x11\x05\x00\x29\0" }, + { 0x3204, 255, 0, "\x00\x28\x11\x06\x00\x29\0" }, + { 0x3205, 255, 0, "\x00\x28\x11\x07\x00\x29\0" }, + { 0x3206, 255, 0, "\x00\x28\x11\x09\x00\x29\0" }, + { 0x3207, 255, 0, "\x00\x28\x11\x0b\x00\x29\0" }, + { 0x3208, 255, 0, "\x00\x28\x11\x0c\x00\x29\0" }, + { 0x3209, 255, 0, "\x00\x28\x11\x0e\x00\x29\0" }, + { 0x320a, 255, 0, "\x00\x28\x11\x0f\x00\x29\0" }, + { 0x320b, 255, 0, "\x00\x28\x11\x10\x00\x29\0" }, + { 0x320c, 255, 0, "\x00\x28\x11\x11\x00\x29\0" }, + { 0x320d, 255, 0, "\x00\x28\x11\x12\x00\x29\0" }, + { 0x320e, 255, 0, "\x00\x28\x11\x00\x11\x61\x00\x29\0" }, + { 0x320f, 255, 0, "\x00\x28\x11\x02\x11\x61\x00\x29\0" }, + { 0x3210, 255, 0, "\x00\x28\x11\x03\x11\x61\x00\x29\0" }, + { 0x3211, 255, 0, "\x00\x28\x11\x05\x11\x61\x00\x29\0" }, + { 0x3212, 255, 0, "\x00\x28\x11\x06\x11\x61\x00\x29\0" }, + { 0x3213, 255, 0, "\x00\x28\x11\x07\x11\x61\x00\x29\0" }, + { 0x3214, 255, 0, "\x00\x28\x11\x09\x11\x61\x00\x29\0" }, + { 0x3215, 255, 0, "\x00\x28\x11\x0b\x11\x61\x00\x29\0" }, + { 0x3216, 255, 0, "\x00\x28\x11\x0c\x11\x61\x00\x29\0" }, + { 0x3217, 255, 0, "\x00\x28\x11\x0e\x11\x61\x00\x29\0" }, + { 0x3218, 255, 0, "\x00\x28\x11\x0f\x11\x61\x00\x29\0" }, + { 0x3219, 255, 0, "\x00\x28\x11\x10\x11\x61\x00\x29\0" }, + { 0x321a, 255, 0, "\x00\x28\x11\x11\x11\x61\x00\x29\0" }, + { 0x321b, 255, 0, "\x00\x28\x11\x12\x11\x61\x00\x29\0" }, + { 0x321c, 255, 0, "\x00\x28\x11\x0c\x11\x6e\x00\x29\0" }, + { 0x3220, 255, 0, "\x00\x28\x4e\x00\x00\x29\0" }, + { 0x3221, 255, 0, "\x00\x28\x4e\x8c\x00\x29\0" }, + { 0x3222, 255, 0, "\x00\x28\x4e\x09\x00\x29\0" }, + { 0x3223, 255, 0, "\x00\x28\x56\xdb\x00\x29\0" }, + { 0x3224, 255, 0, "\x00\x28\x4e\x94\x00\x29\0" }, + { 0x3225, 255, 0, "\x00\x28\x51\x6d\x00\x29\0" }, + { 0x3226, 255, 0, "\x00\x28\x4e\x03\x00\x29\0" }, + { 0x3227, 255, 0, "\x00\x28\x51\x6b\x00\x29\0" }, + { 0x3228, 255, 0, "\x00\x28\x4e\x5d\x00\x29\0" }, + { 0x3229, 255, 0, "\x00\x28\x53\x41\x00\x29\0" }, + { 0x322a, 255, 0, "\x00\x28\x67\x08\x00\x29\0" }, + { 0x322b, 255, 0, "\x00\x28\x70\x6b\x00\x29\0" }, + { 0x322c, 255, 0, "\x00\x28\x6c\x34\x00\x29\0" }, + { 0x322d, 255, 0, "\x00\x28\x67\x28\x00\x29\0" }, + { 0x322e, 255, 0, "\x00\x28\x91\xd1\x00\x29\0" }, + { 0x322f, 255, 0, "\x00\x28\x57\x1f\x00\x29\0" }, + { 0x3230, 255, 0, "\x00\x28\x65\xe5\x00\x29\0" }, + { 0x3231, 255, 0, "\x00\x28\x68\x2a\x00\x29\0" }, + { 0x3232, 255, 0, "\x00\x28\x67\x09\x00\x29\0" }, + { 0x3233, 255, 0, "\x00\x28\x79\x3e\x00\x29\0" }, + { 0x3234, 255, 0, "\x00\x28\x54\x0d\x00\x29\0" }, + { 0x3235, 255, 0, "\x00\x28\x72\x79\x00\x29\0" }, + { 0x3236, 255, 0, "\x00\x28\x8c\xa1\x00\x29\0" }, + { 0x3237, 255, 0, "\x00\x28\x79\x5d\x00\x29\0" }, + { 0x3238, 255, 0, "\x00\x28\x52\xb4\x00\x29\0" }, + { 0x3239, 255, 0, "\x00\x28\x4e\xe3\x00\x29\0" }, + { 0x323a, 255, 0, "\x00\x28\x54\x7c\x00\x29\0" }, + { 0x323b, 255, 0, "\x00\x28\x5b\x66\x00\x29\0" }, + { 0x323c, 255, 0, "\x00\x28\x76\xe3\x00\x29\0" }, + { 0x323d, 255, 0, "\x00\x28\x4f\x01\x00\x29\0" }, + { 0x323e, 255, 0, "\x00\x28\x8c\xc7\x00\x29\0" }, + { 0x323f, 255, 0, "\x00\x28\x53\x54\x00\x29\0" }, + { 0x3240, 255, 0, "\x00\x28\x79\x6d\x00\x29\0" }, + { 0x3241, 255, 0, "\x00\x28\x4f\x11\x00\x29\0" }, + { 0x3242, 255, 0, "\x00\x28\x81\xea\x00\x29\0" }, + { 0x3243, 255, 0, "\x00\x28\x81\xf3\x00\x29\0" }, + { 0x3260, 255, 0, "\x11\x00\0" }, + { 0x3261, 255, 0, "\x11\x02\0" }, + { 0x3262, 255, 0, "\x11\x03\0" }, + { 0x3263, 255, 0, "\x11\x05\0" }, + { 0x3264, 255, 0, "\x11\x06\0" }, + { 0x3265, 255, 0, "\x11\x07\0" }, + { 0x3266, 255, 0, "\x11\x09\0" }, + { 0x3267, 255, 0, "\x11\x0b\0" }, + { 0x3268, 255, 0, "\x11\x0c\0" }, + { 0x3269, 255, 0, "\x11\x0e\0" }, + { 0x326a, 255, 0, "\x11\x0f\0" }, + { 0x326b, 255, 0, "\x11\x10\0" }, + { 0x326c, 255, 0, "\x11\x11\0" }, + { 0x326d, 255, 0, "\x11\x12\0" }, + { 0x326e, 255, 0, "\x11\x00\x11\x61\0" }, + { 0x326f, 255, 0, "\x11\x02\x11\x61\0" }, + { 0x3270, 255, 0, "\x11\x03\x11\x61\0" }, + { 0x3271, 255, 0, "\x11\x05\x11\x61\0" }, + { 0x3272, 255, 0, "\x11\x06\x11\x61\0" }, + { 0x3273, 255, 0, "\x11\x07\x11\x61\0" }, + { 0x3274, 255, 0, "\x11\x09\x11\x61\0" }, + { 0x3275, 255, 0, "\x11\x0b\x11\x61\0" }, + { 0x3276, 255, 0, "\x11\x0c\x11\x61\0" }, + { 0x3277, 255, 0, "\x11\x0e\x11\x61\0" }, + { 0x3278, 255, 0, "\x11\x0f\x11\x61\0" }, + { 0x3279, 255, 0, "\x11\x10\x11\x61\0" }, + { 0x327a, 255, 0, "\x11\x11\x11\x61\0" }, + { 0x327b, 255, 0, "\x11\x12\x11\x61\0" }, + { 0x3280, 255, 0, "\x4e\x00\0" }, + { 0x3281, 255, 0, "\x4e\x8c\0" }, + { 0x3282, 255, 0, "\x4e\x09\0" }, + { 0x3283, 255, 0, "\x56\xdb\0" }, + { 0x3284, 255, 0, "\x4e\x94\0" }, + { 0x3285, 255, 0, "\x51\x6d\0" }, + { 0x3286, 255, 0, "\x4e\x03\0" }, + { 0x3287, 255, 0, "\x51\x6b\0" }, + { 0x3288, 255, 0, "\x4e\x5d\0" }, + { 0x3289, 255, 0, "\x53\x41\0" }, + { 0x328a, 255, 0, "\x67\x08\0" }, + { 0x328b, 255, 0, "\x70\x6b\0" }, + { 0x328c, 255, 0, "\x6c\x34\0" }, + { 0x328d, 255, 0, "\x67\x28\0" }, + { 0x328e, 255, 0, "\x91\xd1\0" }, + { 0x328f, 255, 0, "\x57\x1f\0" }, + { 0x3290, 255, 0, "\x65\xe5\0" }, + { 0x3291, 255, 0, "\x68\x2a\0" }, + { 0x3292, 255, 0, "\x67\x09\0" }, + { 0x3293, 255, 0, "\x79\x3e\0" }, + { 0x3294, 255, 0, "\x54\x0d\0" }, + { 0x3295, 255, 0, "\x72\x79\0" }, + { 0x3296, 255, 0, "\x8c\xa1\0" }, + { 0x3297, 255, 0, "\x79\x5d\0" }, + { 0x3298, 255, 0, "\x52\xb4\0" }, + { 0x3299, 255, 0, "\x79\xd8\0" }, + { 0x329a, 255, 0, "\x75\x37\0" }, + { 0x329b, 255, 0, "\x59\x73\0" }, + { 0x329c, 255, 0, "\x90\x69\0" }, + { 0x329d, 255, 0, "\x51\x2a\0" }, + { 0x329e, 255, 0, "\x53\x70\0" }, + { 0x329f, 255, 0, "\x6c\xe8\0" }, + { 0x32a0, 255, 0, "\x98\x05\0" }, + { 0x32a1, 255, 0, "\x4f\x11\0" }, + { 0x32a2, 255, 0, "\x51\x99\0" }, + { 0x32a3, 255, 0, "\x6b\x63\0" }, + { 0x32a4, 255, 0, "\x4e\x0a\0" }, + { 0x32a5, 255, 0, "\x4e\x2d\0" }, + { 0x32a6, 255, 0, "\x4e\x0b\0" }, + { 0x32a7, 255, 0, "\x5d\xe6\0" }, + { 0x32a8, 255, 0, "\x53\xf3\0" }, + { 0x32a9, 255, 0, "\x53\x3b\0" }, + { 0x32aa, 255, 0, "\x5b\x97\0" }, + { 0x32ab, 255, 0, "\x5b\x66\0" }, + { 0x32ac, 255, 0, "\x76\xe3\0" }, + { 0x32ad, 255, 0, "\x4f\x01\0" }, + { 0x32ae, 255, 0, "\x8c\xc7\0" }, + { 0x32af, 255, 0, "\x53\x54\0" }, + { 0x32b0, 255, 0, "\x59\x1c\0" }, + { 0x32c0, 255, 0, "\x00\x31\x67\x08\0" }, + { 0x32c1, 255, 0, "\x00\x32\x67\x08\0" }, + { 0x32c2, 255, 0, "\x00\x33\x67\x08\0" }, + { 0x32c3, 255, 0, "\x00\x34\x67\x08\0" }, + { 0x32c4, 255, 0, "\x00\x35\x67\x08\0" }, + { 0x32c5, 255, 0, "\x00\x36\x67\x08\0" }, + { 0x32c6, 255, 0, "\x00\x37\x67\x08\0" }, + { 0x32c7, 255, 0, "\x00\x38\x67\x08\0" }, + { 0x32c8, 255, 0, "\x00\x39\x67\x08\0" }, + { 0x32c9, 255, 0, "\x00\x31\x00\x30\x67\x08\0" }, + { 0x32ca, 255, 0, "\x00\x31\x00\x31\x67\x08\0" }, + { 0x32cb, 255, 0, "\x00\x31\x00\x32\x67\x08\0" }, + { 0x32d0, 255, 0, "\x30\xa2\0" }, + { 0x32d1, 255, 0, "\x30\xa4\0" }, + { 0x32d2, 255, 0, "\x30\xa6\0" }, + { 0x32d3, 255, 0, "\x30\xa8\0" }, + { 0x32d4, 255, 0, "\x30\xaa\0" }, + { 0x32d5, 255, 0, "\x30\xab\0" }, + { 0x32d6, 255, 0, "\x30\xad\0" }, + { 0x32d7, 255, 0, "\x30\xaf\0" }, + { 0x32d8, 255, 0, "\x30\xb1\0" }, + { 0x32d9, 255, 0, "\x30\xb3\0" }, + { 0x32da, 255, 0, "\x30\xb5\0" }, + { 0x32db, 255, 0, "\x30\xb7\0" }, + { 0x32dc, 255, 0, "\x30\xb9\0" }, + { 0x32dd, 255, 0, "\x30\xbb\0" }, + { 0x32de, 255, 0, "\x30\xbd\0" }, + { 0x32df, 255, 0, "\x30\xbf\0" }, + { 0x32e0, 255, 0, "\x30\xc1\0" }, + { 0x32e1, 255, 0, "\x30\xc4\0" }, + { 0x32e2, 255, 0, "\x30\xc6\0" }, + { 0x32e3, 255, 0, "\x30\xc8\0" }, + { 0x32e4, 255, 0, "\x30\xca\0" }, + { 0x32e5, 255, 0, "\x30\xcb\0" }, + { 0x32e6, 255, 0, "\x30\xcc\0" }, + { 0x32e7, 255, 0, "\x30\xcd\0" }, + { 0x32e8, 255, 0, "\x30\xce\0" }, + { 0x32e9, 255, 0, "\x30\xcf\0" }, + { 0x32ea, 255, 0, "\x30\xd2\0" }, + { 0x32eb, 255, 0, "\x30\xd5\0" }, + { 0x32ec, 255, 0, "\x30\xd8\0" }, + { 0x32ed, 255, 0, "\x30\xdb\0" }, + { 0x32ee, 255, 0, "\x30\xde\0" }, + { 0x32ef, 255, 0, "\x30\xdf\0" }, + { 0x32f0, 255, 0, "\x30\xe0\0" }, + { 0x32f1, 255, 0, "\x30\xe1\0" }, + { 0x32f2, 255, 0, "\x30\xe2\0" }, + { 0x32f3, 255, 0, "\x30\xe4\0" }, + { 0x32f4, 255, 0, "\x30\xe6\0" }, + { 0x32f5, 255, 0, "\x30\xe8\0" }, + { 0x32f6, 255, 0, "\x30\xe9\0" }, + { 0x32f7, 255, 0, "\x30\xea\0" }, + { 0x32f8, 255, 0, "\x30\xeb\0" }, + { 0x32f9, 255, 0, "\x30\xec\0" }, + { 0x32fa, 255, 0, "\x30\xed\0" }, + { 0x32fb, 255, 0, "\x30\xef\0" }, + { 0x32fc, 255, 0, "\x30\xf0\0" }, + { 0x32fd, 255, 0, "\x30\xf1\0" }, + { 0x32fe, 255, 0, "\x30\xf2\0" }, + { 0x3300, 255, 0, "\x30\xa2\x30\xcf\x30\x9a\x30\xfc\x30\xc8\0" }, + { 0x3301, 255, 0, "\x30\xa2\x30\xeb\x30\xd5\x30\xa1\0" }, + { 0x3302, 255, 0, "\x30\xa2\x30\xf3\x30\xd8\x30\x9a\x30\xa2\0" }, + { 0x3303, 255, 0, "\x30\xa2\x30\xfc\x30\xeb\0" }, + { 0x3304, 255, 0, "\x30\xa4\x30\xcb\x30\xf3\x30\xaf\x30\x99\0" }, + { 0x3305, 255, 0, "\x30\xa4\x30\xf3\x30\xc1\0" }, + { 0x3306, 255, 0, "\x30\xa6\x30\xa9\x30\xf3\0" }, + { 0x3307, 255, 0, "\x30\xa8\x30\xb9\x30\xaf\x30\xfc\x30\xc8\x30\x99\0" }, + { 0x3308, 255, 0, "\x30\xa8\x30\xfc\x30\xab\x30\xfc\0" }, + { 0x3309, 255, 0, "\x30\xaa\x30\xf3\x30\xb9\0" }, + { 0x330a, 255, 0, "\x30\xaa\x30\xfc\x30\xe0\0" }, + { 0x330b, 255, 0, "\x30\xab\x30\xa4\x30\xea\0" }, + { 0x330c, 255, 0, "\x30\xab\x30\xe9\x30\xc3\x30\xc8\0" }, + { 0x330d, 255, 0, "\x30\xab\x30\xed\x30\xea\x30\xfc\0" }, + { 0x330e, 255, 0, "\x30\xab\x30\x99\x30\xed\x30\xf3\0" }, + { 0x330f, 255, 0, "\x30\xab\x30\x99\x30\xf3\x30\xde\0" }, + { 0x3310, 255, 0, "\x30\xad\x30\x99\x30\xab\x30\x99\0" }, + { 0x3311, 255, 0, "\x30\xad\x30\x99\x30\xcb\x30\xfc\0" }, + { 0x3312, 255, 0, "\x30\xad\x30\xe5\x30\xea\x30\xfc\0" }, + { 0x3313, 255, 0, "\x30\xad\x30\x99\x30\xeb\x30\xbf\x30\x99\x30\xfc\0" }, + { 0x3314, 255, 0, "\x30\xad\x30\xed\0" }, + { 0x3315, 255, 0, "\x30\xad\x30\xed\x30\xaf\x30\x99\x30\xe9\x30\xe0\0" }, + { 0x3316, 255, 0, "\x30\xad\x30\xed\x30\xe1\x30\xfc\x30\xc8\x30\xeb\0" }, + { 0x3317, 255, 0, "\x30\xad\x30\xed\x30\xef\x30\xc3\x30\xc8\0" }, + { 0x3318, 255, 0, "\x30\xaf\x30\x99\x30\xe9\x30\xe0\0" }, + { 0x3319, 255, 0, "\x30\xaf\x30\x99\x30\xe9\x30\xe0\x30\xc8\x30\xf3\0" }, + { 0x331a, 255, 0, "\x30\xaf\x30\xeb\x30\xbb\x30\x99\x30\xa4\x30\xed\0" }, + { 0x331b, 255, 0, "\x30\xaf\x30\xed\x30\xfc\x30\xcd\0" }, + { 0x331c, 255, 0, "\x30\xb1\x30\xfc\x30\xb9\0" }, + { 0x331d, 255, 0, "\x30\xb3\x30\xeb\x30\xca\0" }, + { 0x331e, 255, 0, "\x30\xb3\x30\xfc\x30\xdb\x30\x9a\0" }, + { 0x331f, 255, 0, "\x30\xb5\x30\xa4\x30\xaf\x30\xeb\0" }, + { 0x3320, 255, 0, "\x30\xb5\x30\xf3\x30\xc1\x30\xfc\x30\xe0\0" }, + { 0x3321, 255, 0, "\x30\xb7\x30\xea\x30\xf3\x30\xaf\x30\x99\0" }, + { 0x3322, 255, 0, "\x30\xbb\x30\xf3\x30\xc1\0" }, + { 0x3323, 255, 0, "\x30\xbb\x30\xf3\x30\xc8\0" }, + { 0x3324, 255, 0, "\x30\xbf\x30\x99\x30\xfc\x30\xb9\0" }, + { 0x3325, 255, 0, "\x30\xc6\x30\x99\x30\xb7\0" }, + { 0x3326, 255, 0, "\x30\xc8\x30\x99\x30\xeb\0" }, + { 0x3327, 255, 0, "\x30\xc8\x30\xf3\0" }, + { 0x3328, 255, 0, "\x30\xca\x30\xce\0" }, + { 0x3329, 255, 0, "\x30\xce\x30\xc3\x30\xc8\0" }, + { 0x332a, 255, 0, "\x30\xcf\x30\xa4\x30\xc4\0" }, + { 0x332b, 255, 0, "\x30\xcf\x30\x9a\x30\xfc\x30\xbb\x30\xf3\x30\xc8\0" }, + { 0x332c, 255, 0, "\x30\xcf\x30\x9a\x30\xfc\x30\xc4\0" }, + { 0x332d, 255, 0, "\x30\xcf\x30\x99\x30\xfc\x30\xec\x30\xeb\0" }, + { 0x332e, 255, 0, "\x30\xd2\x30\x9a\x30\xa2\x30\xb9\x30\xc8\x30\xeb\0" }, + { 0x332f, 255, 0, "\x30\xd2\x30\x9a\x30\xaf\x30\xeb\0" }, + { 0x3330, 255, 0, "\x30\xd2\x30\x9a\x30\xb3\0" }, + { 0x3331, 255, 0, "\x30\xd2\x30\x99\x30\xeb\0" }, + { 0x3332, 255, 0, "\x30\xd5\x30\xa1\x30\xe9\x30\xc3\x30\xc8\x30\x99\0" }, + { 0x3333, 255, 0, "\x30\xd5\x30\xa3\x30\xfc\x30\xc8\0" }, + { 0x3334, 255, 0, "\x30\xd5\x30\x99\x30\xc3\x30\xb7\x30\xa7\x30\xeb\0" }, + { 0x3335, 255, 0, "\x30\xd5\x30\xe9\x30\xf3\0" }, + { 0x3336, 255, 0, "\x30\xd8\x30\xaf\x30\xbf\x30\xfc\x30\xeb\0" }, + { 0x3337, 255, 0, "\x30\xd8\x30\x9a\x30\xbd\0" }, + { 0x3338, 255, 0, "\x30\xd8\x30\x9a\x30\xcb\x30\xd2\0" }, + { 0x3339, 255, 0, "\x30\xd8\x30\xeb\x30\xc4\0" }, + { 0x333a, 255, 0, "\x30\xd8\x30\x9a\x30\xf3\x30\xb9\0" }, + { 0x333b, 255, 0, "\x30\xd8\x30\x9a\x30\xfc\x30\xb7\x30\x99\0" }, + { 0x333c, 255, 0, "\x30\xd8\x30\x99\x30\xfc\x30\xbf\0" }, + { 0x333d, 255, 0, "\x30\xdb\x30\x9a\x30\xa4\x30\xf3\x30\xc8\0" }, + { 0x333e, 255, 0, "\x30\xdb\x30\x99\x30\xeb\x30\xc8\0" }, + { 0x333f, 255, 0, "\x30\xdb\x30\xf3\0" }, + { 0x3340, 255, 0, "\x30\xdb\x30\x9a\x30\xf3\x30\xc8\x30\x99\0" }, + { 0x3341, 255, 0, "\x30\xdb\x30\xfc\x30\xeb\0" }, + { 0x3342, 255, 0, "\x30\xdb\x30\xfc\x30\xf3\0" }, + { 0x3343, 255, 0, "\x30\xde\x30\xa4\x30\xaf\x30\xed\0" }, + { 0x3344, 255, 0, "\x30\xde\x30\xa4\x30\xeb\0" }, + { 0x3345, 255, 0, "\x30\xde\x30\xc3\x30\xcf\0" }, + { 0x3346, 255, 0, "\x30\xde\x30\xeb\x30\xaf\0" }, + { 0x3347, 255, 0, "\x30\xde\x30\xf3\x30\xb7\x30\xe7\x30\xf3\0" }, + { 0x3348, 255, 0, "\x30\xdf\x30\xaf\x30\xed\x30\xf3\0" }, + { 0x3349, 255, 0, "\x30\xdf\x30\xea\0" }, + { 0x334a, 255, 0, "\x30\xdf\x30\xea\x30\xcf\x30\x99\x30\xfc\x30\xeb\0" }, + { 0x334b, 255, 0, "\x30\xe1\x30\xab\x30\x99\0" }, + { 0x334c, 255, 0, "\x30\xe1\x30\xab\x30\x99\x30\xc8\x30\xf3\0" }, + { 0x334d, 255, 0, "\x30\xe1\x30\xfc\x30\xc8\x30\xeb\0" }, + { 0x334e, 255, 0, "\x30\xe4\x30\xfc\x30\xc8\x30\x99\0" }, + { 0x334f, 255, 0, "\x30\xe4\x30\xfc\x30\xeb\0" }, + { 0x3350, 255, 0, "\x30\xe6\x30\xa2\x30\xf3\0" }, + { 0x3351, 255, 0, "\x30\xea\x30\xc3\x30\xc8\x30\xeb\0" }, + { 0x3352, 255, 0, "\x30\xea\x30\xe9\0" }, + { 0x3353, 255, 0, "\x30\xeb\x30\xd2\x30\x9a\x30\xfc\0" }, + { 0x3354, 255, 0, "\x30\xeb\x30\xfc\x30\xd5\x30\x99\x30\xeb\0" }, + { 0x3355, 255, 0, "\x30\xec\x30\xe0\0" }, + { 0x3356, 255, 0, "\x30\xec\x30\xf3\x30\xc8\x30\xb1\x30\x99\x30\xf3\0" }, + { 0x3357, 255, 0, "\x30\xef\x30\xc3\x30\xc8\0" }, + { 0x3358, 255, 0, "\x00\x30\x70\xb9\0" }, + { 0x3359, 255, 0, "\x00\x31\x70\xb9\0" }, + { 0x335a, 255, 0, "\x00\x32\x70\xb9\0" }, + { 0x335b, 255, 0, "\x00\x33\x70\xb9\0" }, + { 0x335c, 255, 0, "\x00\x34\x70\xb9\0" }, + { 0x335d, 255, 0, "\x00\x35\x70\xb9\0" }, + { 0x335e, 255, 0, "\x00\x36\x70\xb9\0" }, + { 0x335f, 255, 0, "\x00\x37\x70\xb9\0" }, + { 0x3360, 255, 0, "\x00\x38\x70\xb9\0" }, + { 0x3361, 255, 0, "\x00\x39\x70\xb9\0" }, + { 0x3362, 255, 0, "\x00\x31\x00\x30\x70\xb9\0" }, + { 0x3363, 255, 0, "\x00\x31\x00\x31\x70\xb9\0" }, + { 0x3364, 255, 0, "\x00\x31\x00\x32\x70\xb9\0" }, + { 0x3365, 255, 0, "\x00\x31\x00\x33\x70\xb9\0" }, + { 0x3366, 255, 0, "\x00\x31\x00\x34\x70\xb9\0" }, + { 0x3367, 255, 0, "\x00\x31\x00\x35\x70\xb9\0" }, + { 0x3368, 255, 0, "\x00\x31\x00\x36\x70\xb9\0" }, + { 0x3369, 255, 0, "\x00\x31\x00\x37\x70\xb9\0" }, + { 0x336a, 255, 0, "\x00\x31\x00\x38\x70\xb9\0" }, + { 0x336b, 255, 0, "\x00\x31\x00\x39\x70\xb9\0" }, + { 0x336c, 255, 0, "\x00\x32\x00\x30\x70\xb9\0" }, + { 0x336d, 255, 0, "\x00\x32\x00\x31\x70\xb9\0" }, + { 0x336e, 255, 0, "\x00\x32\x00\x32\x70\xb9\0" }, + { 0x336f, 255, 0, "\x00\x32\x00\x33\x70\xb9\0" }, + { 0x3370, 255, 0, "\x00\x32\x00\x34\x70\xb9\0" }, + { 0x3371, 255, 0, "\x00\x68\x00\x50\x00\x61\0" }, + { 0x3372, 255, 0, "\x00\x64\x00\x61\0" }, + { 0x3373, 255, 0, "\x00\x41\x00\x55\0" }, + { 0x3374, 255, 0, "\x00\x62\x00\x61\x00\x72\0" }, + { 0x3375, 255, 0, "\x00\x6f\x00\x56\0" }, + { 0x3376, 255, 0, "\x00\x70\x00\x63\0" }, + { 0x337b, 255, 0, "\x5e\x73\x62\x10\0" }, + { 0x337c, 255, 0, "\x66\x2d\x54\x8c\0" }, + { 0x337d, 255, 0, "\x59\x27\x6b\x63\0" }, + { 0x337e, 255, 0, "\x66\x0e\x6c\xbb\0" }, + { 0x337f, 255, 0, "\x68\x2a\x5f\x0f\x4f\x1a\x79\x3e\0" }, + { 0x3380, 255, 0, "\x00\x70\x00\x41\0" }, + { 0x3381, 255, 0, "\x00\x6e\x00\x41\0" }, + { 0x3382, 255, 0, "\x03\xbc\x00\x41\0" }, + { 0x3383, 255, 0, "\x00\x6d\x00\x41\0" }, + { 0x3384, 255, 0, "\x00\x6b\x00\x41\0" }, + { 0x3385, 255, 0, "\x00\x4b\x00\x42\0" }, + { 0x3386, 255, 0, "\x00\x4d\x00\x42\0" }, + { 0x3387, 255, 0, "\x00\x47\x00\x42\0" }, + { 0x3388, 255, 0, "\x00\x63\x00\x61\x00\x6c\0" }, + { 0x3389, 255, 0, "\x00\x6b\x00\x63\x00\x61\x00\x6c\0" }, + { 0x338a, 255, 0, "\x00\x70\x00\x46\0" }, + { 0x338b, 255, 0, "\x00\x6e\x00\x46\0" }, + { 0x338c, 255, 0, "\x03\xbc\x00\x46\0" }, + { 0x338d, 255, 0, "\x03\xbc\x00\x67\0" }, + { 0x338e, 255, 0, "\x00\x6d\x00\x67\0" }, + { 0x338f, 255, 0, "\x00\x6b\x00\x67\0" }, + { 0x3390, 255, 0, "\x00\x48\x00\x7a\0" }, + { 0x3391, 255, 0, "\x00\x6b\x00\x48\x00\x7a\0" }, + { 0x3392, 255, 0, "\x00\x4d\x00\x48\x00\x7a\0" }, + { 0x3393, 255, 0, "\x00\x47\x00\x48\x00\x7a\0" }, + { 0x3394, 255, 0, "\x00\x54\x00\x48\x00\x7a\0" }, + { 0x3395, 255, 0, "\x03\xbc\x00\x6c\0" }, + { 0x3396, 255, 0, "\x00\x6d\x00\x6c\0" }, + { 0x3397, 255, 0, "\x00\x64\x00\x6c\0" }, + { 0x3398, 255, 0, "\x00\x6b\x00\x6c\0" }, + { 0x3399, 255, 0, "\x00\x66\x00\x6d\0" }, + { 0x339a, 255, 0, "\x00\x6e\x00\x6d\0" }, + { 0x339b, 255, 0, "\x03\xbc\x00\x6d\0" }, + { 0x339c, 255, 0, "\x00\x6d\x00\x6d\0" }, + { 0x339d, 255, 0, "\x00\x63\x00\x6d\0" }, + { 0x339e, 255, 0, "\x00\x6b\x00\x6d\0" }, + { 0x339f, 255, 0, "\x00\x6d\x00\x6d\x00\x32\0" }, + { 0x33a0, 255, 0, "\x00\x63\x00\x6d\x00\x32\0" }, + { 0x33a1, 255, 0, "\x00\x6d\x00\x32\0" }, + { 0x33a2, 255, 0, "\x00\x6b\x00\x6d\x00\x32\0" }, + { 0x33a3, 255, 0, "\x00\x6d\x00\x6d\x00\x33\0" }, + { 0x33a4, 255, 0, "\x00\x63\x00\x6d\x00\x33\0" }, + { 0x33a5, 255, 0, "\x00\x6d\x00\x33\0" }, + { 0x33a6, 255, 0, "\x00\x6b\x00\x6d\x00\x33\0" }, + { 0x33a7, 255, 0, "\x00\x6d\x22\x15\x00\x73\0" }, + { 0x33a8, 255, 0, "\x00\x6d\x22\x15\x00\x73\x00\x32\0" }, + { 0x33a9, 255, 0, "\x00\x50\x00\x61\0" }, + { 0x33aa, 255, 0, "\x00\x6b\x00\x50\x00\x61\0" }, + { 0x33ab, 255, 0, "\x00\x4d\x00\x50\x00\x61\0" }, + { 0x33ac, 255, 0, "\x00\x47\x00\x50\x00\x61\0" }, + { 0x33ad, 255, 0, "\x00\x72\x00\x61\x00\x64\0" }, + { 0x33ae, 255, 0, "\x00\x72\x00\x61\x00\x64\x22\x15\x00\x73\0" }, + { 0x33af, 255, 0, "\x00\x72\x00\x61\x00\x64\x22\x15\x00\x73\x00\x32\0" }, + { 0x33b0, 255, 0, "\x00\x70\x00\x73\0" }, + { 0x33b1, 255, 0, "\x00\x6e\x00\x73\0" }, + { 0x33b2, 255, 0, "\x03\xbc\x00\x73\0" }, + { 0x33b3, 255, 0, "\x00\x6d\x00\x73\0" }, + { 0x33b4, 255, 0, "\x00\x70\x00\x56\0" }, + { 0x33b5, 255, 0, "\x00\x6e\x00\x56\0" }, + { 0x33b6, 255, 0, "\x03\xbc\x00\x56\0" }, + { 0x33b7, 255, 0, "\x00\x6d\x00\x56\0" }, + { 0x33b8, 255, 0, "\x00\x6b\x00\x56\0" }, + { 0x33b9, 255, 0, "\x00\x4d\x00\x56\0" }, + { 0x33ba, 255, 0, "\x00\x70\x00\x57\0" }, + { 0x33bb, 255, 0, "\x00\x6e\x00\x57\0" }, + { 0x33bc, 255, 0, "\x03\xbc\x00\x57\0" }, + { 0x33bd, 255, 0, "\x00\x6d\x00\x57\0" }, + { 0x33be, 255, 0, "\x00\x6b\x00\x57\0" }, + { 0x33bf, 255, 0, "\x00\x4d\x00\x57\0" }, + { 0x33c0, 255, 0, "\x00\x6b\x03\xa9\0" }, + { 0x33c1, 255, 0, "\x00\x4d\x03\xa9\0" }, + { 0x33c2, 255, 0, "\x00\x61\x00\x2e\x00\x6d\x00\x2e\0" }, + { 0x33c3, 255, 0, "\x00\x42\x00\x71\0" }, + { 0x33c4, 255, 0, "\x00\x63\x00\x63\0" }, + { 0x33c5, 255, 0, "\x00\x63\x00\x64\0" }, + { 0x33c6, 255, 0, "\x00\x43\x22\x15\x00\x6b\x00\x67\0" }, + { 0x33c7, 255, 0, "\x00\x43\x00\x6f\x00\x2e\0" }, + { 0x33c8, 255, 0, "\x00\x64\x00\x42\0" }, + { 0x33c9, 255, 0, "\x00\x47\x00\x79\0" }, + { 0x33ca, 255, 0, "\x00\x68\x00\x61\0" }, + { 0x33cb, 255, 0, "\x00\x48\x00\x50\0" }, + { 0x33cc, 255, 0, "\x00\x69\x00\x6e\0" }, + { 0x33cd, 255, 0, "\x00\x4b\x00\x4b\0" }, + { 0x33ce, 255, 0, "\x00\x4b\x00\x4d\0" }, + { 0x33cf, 255, 0, "\x00\x6b\x00\x74\0" }, + { 0x33d0, 255, 0, "\x00\x6c\x00\x6d\0" }, + { 0x33d1, 255, 0, "\x00\x6c\x00\x6e\0" }, + { 0x33d2, 255, 0, "\x00\x6c\x00\x6f\x00\x67\0" }, + { 0x33d3, 255, 0, "\x00\x6c\x00\x78\0" }, + { 0x33d4, 255, 0, "\x00\x6d\x00\x62\0" }, + { 0x33d5, 255, 0, "\x00\x6d\x00\x69\x00\x6c\0" }, + { 0x33d6, 255, 0, "\x00\x6d\x00\x6f\x00\x6c\0" }, + { 0x33d7, 255, 0, "\x00\x50\x00\x48\0" }, + { 0x33d8, 255, 0, "\x00\x70\x00\x2e\x00\x6d\x00\x2e\0" }, + { 0x33d9, 255, 0, "\x00\x50\x00\x50\x00\x4d\0" }, + { 0x33da, 255, 0, "\x00\x50\x00\x52\0" }, + { 0x33db, 255, 0, "\x00\x73\x00\x72\0" }, + { 0x33dc, 255, 0, "\x00\x53\x00\x76\0" }, + { 0x33dd, 255, 0, "\x00\x57\x00\x62\0" }, + { 0x33e0, 255, 0, "\x00\x31\x65\xe5\0" }, + { 0x33e1, 255, 0, "\x00\x32\x65\xe5\0" }, + { 0x33e2, 255, 0, "\x00\x33\x65\xe5\0" }, + { 0x33e3, 255, 0, "\x00\x34\x65\xe5\0" }, + { 0x33e4, 255, 0, "\x00\x35\x65\xe5\0" }, + { 0x33e5, 255, 0, "\x00\x36\x65\xe5\0" }, + { 0x33e6, 255, 0, "\x00\x37\x65\xe5\0" }, + { 0x33e7, 255, 0, "\x00\x38\x65\xe5\0" }, + { 0x33e8, 255, 0, "\x00\x39\x65\xe5\0" }, + { 0x33e9, 255, 0, "\x00\x31\x00\x30\x65\xe5\0" }, + { 0x33ea, 255, 0, "\x00\x31\x00\x31\x65\xe5\0" }, + { 0x33eb, 255, 0, "\x00\x31\x00\x32\x65\xe5\0" }, + { 0x33ec, 255, 0, "\x00\x31\x00\x33\x65\xe5\0" }, + { 0x33ed, 255, 0, "\x00\x31\x00\x34\x65\xe5\0" }, + { 0x33ee, 255, 0, "\x00\x31\x00\x35\x65\xe5\0" }, + { 0x33ef, 255, 0, "\x00\x31\x00\x36\x65\xe5\0" }, + { 0x33f0, 255, 0, "\x00\x31\x00\x37\x65\xe5\0" }, + { 0x33f1, 255, 0, "\x00\x31\x00\x38\x65\xe5\0" }, + { 0x33f2, 255, 0, "\x00\x31\x00\x39\x65\xe5\0" }, + { 0x33f3, 255, 0, "\x00\x32\x00\x30\x65\xe5\0" }, + { 0x33f4, 255, 0, "\x00\x32\x00\x31\x65\xe5\0" }, + { 0x33f5, 255, 0, "\x00\x32\x00\x32\x65\xe5\0" }, + { 0x33f6, 255, 0, "\x00\x32\x00\x33\x65\xe5\0" }, + { 0x33f7, 255, 0, "\x00\x32\x00\x34\x65\xe5\0" }, + { 0x33f8, 255, 0, "\x00\x32\x00\x35\x65\xe5\0" }, + { 0x33f9, 255, 0, "\x00\x32\x00\x36\x65\xe5\0" }, + { 0x33fa, 255, 0, "\x00\x32\x00\x37\x65\xe5\0" }, + { 0x33fb, 255, 0, "\x00\x32\x00\x38\x65\xe5\0" }, + { 0x33fc, 255, 0, "\x00\x32\x00\x39\x65\xe5\0" }, + { 0x33fd, 255, 0, "\x00\x33\x00\x30\x65\xe5\0" }, + { 0x33fe, 255, 0, "\x00\x33\x00\x31\x65\xe5\0" }, + { 0xf900, 0, 255, "\x8c\x48\0" }, + { 0xf901, 0, 255, "\x66\xf4\0" }, + { 0xf902, 0, 255, "\x8e\xca\0" }, + { 0xf903, 0, 255, "\x8c\xc8\0" }, + { 0xf904, 0, 255, "\x6e\xd1\0" }, + { 0xf905, 0, 255, "\x4e\x32\0" }, + { 0xf906, 0, 255, "\x53\xe5\0" }, + { 0xf907, 0, 255, "\x9f\x9c\0" }, + { 0xf908, 0, 255, "\x9f\x9c\0" }, + { 0xf909, 0, 255, "\x59\x51\0" }, + { 0xf90a, 0, 255, "\x91\xd1\0" }, + { 0xf90b, 0, 255, "\x55\x87\0" }, + { 0xf90c, 0, 255, "\x59\x48\0" }, + { 0xf90d, 0, 255, "\x61\xf6\0" }, + { 0xf90e, 0, 255, "\x76\x69\0" }, + { 0xf90f, 0, 255, "\x7f\x85\0" }, + { 0xf910, 0, 255, "\x86\x3f\0" }, + { 0xf911, 0, 255, "\x87\xba\0" }, + { 0xf912, 0, 255, "\x88\xf8\0" }, + { 0xf913, 0, 255, "\x90\x8f\0" }, + { 0xf914, 0, 255, "\x6a\x02\0" }, + { 0xf915, 0, 255, "\x6d\x1b\0" }, + { 0xf916, 0, 255, "\x70\xd9\0" }, + { 0xf917, 0, 255, "\x73\xde\0" }, + { 0xf918, 0, 255, "\x84\x3d\0" }, + { 0xf919, 0, 255, "\x91\x6a\0" }, + { 0xf91a, 0, 255, "\x99\xf1\0" }, + { 0xf91b, 0, 255, "\x4e\x82\0" }, + { 0xf91c, 0, 255, "\x53\x75\0" }, + { 0xf91d, 0, 255, "\x6b\x04\0" }, + { 0xf91e, 0, 255, "\x72\x1b\0" }, + { 0xf91f, 0, 255, "\x86\x2d\0" }, + { 0xf920, 0, 255, "\x9e\x1e\0" }, + { 0xf921, 0, 255, "\x5d\x50\0" }, + { 0xf922, 0, 255, "\x6f\xeb\0" }, + { 0xf923, 0, 255, "\x85\xcd\0" }, + { 0xf924, 0, 255, "\x89\x64\0" }, + { 0xf925, 0, 255, "\x62\xc9\0" }, + { 0xf926, 0, 255, "\x81\xd8\0" }, + { 0xf927, 0, 255, "\x88\x1f\0" }, + { 0xf928, 0, 255, "\x5e\xca\0" }, + { 0xf929, 0, 255, "\x67\x17\0" }, + { 0xf92a, 0, 255, "\x6d\x6a\0" }, + { 0xf92b, 0, 255, "\x72\xfc\0" }, + { 0xf92c, 0, 255, "\x90\xce\0" }, + { 0xf92d, 0, 255, "\x4f\x86\0" }, + { 0xf92e, 0, 255, "\x51\xb7\0" }, + { 0xf92f, 0, 255, "\x52\xde\0" }, + { 0xf930, 0, 255, "\x64\xc4\0" }, + { 0xf931, 0, 255, "\x6a\xd3\0" }, + { 0xf932, 0, 255, "\x72\x10\0" }, + { 0xf933, 0, 255, "\x76\xe7\0" }, + { 0xf934, 0, 255, "\x80\x01\0" }, + { 0xf935, 0, 255, "\x86\x06\0" }, + { 0xf936, 0, 255, "\x86\x5c\0" }, + { 0xf937, 0, 255, "\x8d\xef\0" }, + { 0xf938, 0, 255, "\x97\x32\0" }, + { 0xf939, 0, 255, "\x9b\x6f\0" }, + { 0xf93a, 0, 255, "\x9d\xfa\0" }, + { 0xf93b, 0, 255, "\x78\x8c\0" }, + { 0xf93c, 0, 255, "\x79\x7f\0" }, + { 0xf93d, 0, 255, "\x7d\xa0\0" }, + { 0xf93e, 0, 255, "\x83\xc9\0" }, + { 0xf93f, 0, 255, "\x93\x04\0" }, + { 0xf940, 0, 255, "\x9e\x7f\0" }, + { 0xf941, 0, 255, "\x8a\xd6\0" }, + { 0xf942, 0, 255, "\x58\xdf\0" }, + { 0xf943, 0, 255, "\x5f\x04\0" }, + { 0xf944, 0, 255, "\x7c\x60\0" }, + { 0xf945, 0, 255, "\x80\x7e\0" }, + { 0xf946, 0, 255, "\x72\x62\0" }, + { 0xf947, 0, 255, "\x78\xca\0" }, + { 0xf948, 0, 255, "\x8c\xc2\0" }, + { 0xf949, 0, 255, "\x96\xf7\0" }, + { 0xf94a, 0, 255, "\x58\xd8\0" }, + { 0xf94b, 0, 255, "\x5c\x62\0" }, + { 0xf94c, 0, 255, "\x6a\x13\0" }, + { 0xf94d, 0, 255, "\x6d\xda\0" }, + { 0xf94e, 0, 255, "\x6f\x0f\0" }, + { 0xf94f, 0, 255, "\x7d\x2f\0" }, + { 0xf950, 0, 255, "\x7e\x37\0" }, + { 0xf951, 0, 255, "\x96\xfb\0" }, + { 0xf952, 0, 255, "\x52\xd2\0" }, + { 0xf953, 0, 255, "\x80\x8b\0" }, + { 0xf954, 0, 255, "\x51\xdc\0" }, + { 0xf955, 0, 255, "\x51\xcc\0" }, + { 0xf956, 0, 255, "\x7a\x1c\0" }, + { 0xf957, 0, 255, "\x7d\xbe\0" }, + { 0xf958, 0, 255, "\x83\xf1\0" }, + { 0xf959, 0, 255, "\x96\x75\0" }, + { 0xf95a, 0, 255, "\x8b\x80\0" }, + { 0xf95b, 0, 255, "\x62\xcf\0" }, + { 0xf95c, 0, 255, "\x6a\x02\0" }, + { 0xf95d, 0, 255, "\x8a\xfe\0" }, + { 0xf95e, 0, 255, "\x4e\x39\0" }, + { 0xf95f, 0, 255, "\x5b\xe7\0" }, + { 0xf960, 0, 255, "\x60\x12\0" }, + { 0xf961, 0, 255, "\x73\x87\0" }, + { 0xf962, 0, 255, "\x75\x70\0" }, + { 0xf963, 0, 255, "\x53\x17\0" }, + { 0xf964, 0, 255, "\x78\xfb\0" }, + { 0xf965, 0, 255, "\x4f\xbf\0" }, + { 0xf966, 0, 255, "\x5f\xa9\0" }, + { 0xf967, 0, 255, "\x4e\x0d\0" }, + { 0xf968, 0, 255, "\x6c\xcc\0" }, + { 0xf969, 0, 255, "\x65\x78\0" }, + { 0xf96a, 0, 255, "\x7d\x22\0" }, + { 0xf96b, 0, 255, "\x53\xc3\0" }, + { 0xf96c, 0, 255, "\x58\x5e\0" }, + { 0xf96d, 0, 255, "\x77\x01\0" }, + { 0xf96e, 0, 255, "\x84\x49\0" }, + { 0xf96f, 0, 255, "\x8a\xaa\0" }, + { 0xf970, 0, 255, "\x6b\xba\0" }, + { 0xf971, 0, 255, "\x8f\xb0\0" }, + { 0xf972, 0, 255, "\x6c\x88\0" }, + { 0xf973, 0, 255, "\x62\xfe\0" }, + { 0xf974, 0, 255, "\x82\xe5\0" }, + { 0xf975, 0, 255, "\x63\xa0\0" }, + { 0xf976, 0, 255, "\x75\x65\0" }, + { 0xf977, 0, 255, "\x4e\xae\0" }, + { 0xf978, 0, 255, "\x51\x69\0" }, + { 0xf979, 0, 255, "\x51\xc9\0" }, + { 0xf97a, 0, 255, "\x68\x81\0" }, + { 0xf97b, 0, 255, "\x7c\xe7\0" }, + { 0xf97c, 0, 255, "\x82\x6f\0" }, + { 0xf97d, 0, 255, "\x8a\xd2\0" }, + { 0xf97e, 0, 255, "\x91\xcf\0" }, + { 0xf97f, 0, 255, "\x52\xf5\0" }, + { 0xf980, 0, 255, "\x54\x42\0" }, + { 0xf981, 0, 255, "\x59\x73\0" }, + { 0xf982, 0, 255, "\x5e\xec\0" }, + { 0xf983, 0, 255, "\x65\xc5\0" }, + { 0xf984, 0, 255, "\x6f\xfe\0" }, + { 0xf985, 0, 255, "\x79\x2a\0" }, + { 0xf986, 0, 255, "\x95\xad\0" }, + { 0xf987, 0, 255, "\x9a\x6a\0" }, + { 0xf988, 0, 255, "\x9e\x97\0" }, + { 0xf989, 0, 255, "\x9e\xce\0" }, + { 0xf98a, 0, 255, "\x52\x9b\0" }, + { 0xf98b, 0, 255, "\x66\xc6\0" }, + { 0xf98c, 0, 255, "\x6b\x77\0" }, + { 0xf98d, 0, 255, "\x8f\x62\0" }, + { 0xf98e, 0, 255, "\x5e\x74\0" }, + { 0xf98f, 0, 255, "\x61\x90\0" }, + { 0xf990, 0, 255, "\x62\x00\0" }, + { 0xf991, 0, 255, "\x64\x9a\0" }, + { 0xf992, 0, 255, "\x6f\x23\0" }, + { 0xf993, 0, 255, "\x71\x49\0" }, + { 0xf994, 0, 255, "\x74\x89\0" }, + { 0xf995, 0, 255, "\x79\xca\0" }, + { 0xf996, 0, 255, "\x7d\xf4\0" }, + { 0xf997, 0, 255, "\x80\x6f\0" }, + { 0xf998, 0, 255, "\x8f\x26\0" }, + { 0xf999, 0, 255, "\x84\xee\0" }, + { 0xf99a, 0, 255, "\x90\x23\0" }, + { 0xf99b, 0, 255, "\x93\x4a\0" }, + { 0xf99c, 0, 255, "\x52\x17\0" }, + { 0xf99d, 0, 255, "\x52\xa3\0" }, + { 0xf99e, 0, 255, "\x54\xbd\0" }, + { 0xf99f, 0, 255, "\x70\xc8\0" }, + { 0xf9a0, 0, 255, "\x88\xc2\0" }, + { 0xf9a1, 0, 255, "\x8a\xaa\0" }, + { 0xf9a2, 0, 255, "\x5e\xc9\0" }, + { 0xf9a3, 0, 255, "\x5f\xf5\0" }, + { 0xf9a4, 0, 255, "\x63\x7b\0" }, + { 0xf9a5, 0, 255, "\x6b\xae\0" }, + { 0xf9a6, 0, 255, "\x7c\x3e\0" }, + { 0xf9a7, 0, 255, "\x73\x75\0" }, + { 0xf9a8, 0, 255, "\x4e\xe4\0" }, + { 0xf9a9, 0, 255, "\x56\xf9\0" }, + { 0xf9aa, 0, 255, "\x5b\xe7\0" }, + { 0xf9ab, 0, 255, "\x5d\xba\0" }, + { 0xf9ac, 0, 255, "\x60\x1c\0" }, + { 0xf9ad, 0, 255, "\x73\xb2\0" }, + { 0xf9ae, 0, 255, "\x74\x69\0" }, + { 0xf9af, 0, 255, "\x7f\x9a\0" }, + { 0xf9b0, 0, 255, "\x80\x46\0" }, + { 0xf9b1, 0, 255, "\x92\x34\0" }, + { 0xf9b2, 0, 255, "\x96\xf6\0" }, + { 0xf9b3, 0, 255, "\x97\x48\0" }, + { 0xf9b4, 0, 255, "\x98\x18\0" }, + { 0xf9b5, 0, 255, "\x4f\x8b\0" }, + { 0xf9b6, 0, 255, "\x79\xae\0" }, + { 0xf9b7, 0, 255, "\x91\xb4\0" }, + { 0xf9b8, 0, 255, "\x96\xb8\0" }, + { 0xf9b9, 0, 255, "\x60\xe1\0" }, + { 0xf9ba, 0, 255, "\x4e\x86\0" }, + { 0xf9bb, 0, 255, "\x50\xda\0" }, + { 0xf9bc, 0, 255, "\x5b\xee\0" }, + { 0xf9bd, 0, 255, "\x5c\x3f\0" }, + { 0xf9be, 0, 255, "\x65\x99\0" }, + { 0xf9bf, 0, 255, "\x6a\x02\0" }, + { 0xf9c0, 0, 255, "\x71\xce\0" }, + { 0xf9c1, 0, 255, "\x76\x42\0" }, + { 0xf9c2, 0, 255, "\x84\xfc\0" }, + { 0xf9c3, 0, 255, "\x90\x7c\0" }, + { 0xf9c4, 0, 255, "\x9f\x8d\0" }, + { 0xf9c5, 0, 255, "\x66\x88\0" }, + { 0xf9c6, 0, 255, "\x96\x2e\0" }, + { 0xf9c7, 0, 255, "\x52\x89\0" }, + { 0xf9c8, 0, 255, "\x67\x7b\0" }, + { 0xf9c9, 0, 255, "\x67\xf3\0" }, + { 0xf9ca, 0, 255, "\x6d\x41\0" }, + { 0xf9cb, 0, 255, "\x6e\x9c\0" }, + { 0xf9cc, 0, 255, "\x74\x09\0" }, + { 0xf9cd, 0, 255, "\x75\x59\0" }, + { 0xf9ce, 0, 255, "\x78\x6b\0" }, + { 0xf9cf, 0, 255, "\x7d\x10\0" }, + { 0xf9d0, 0, 255, "\x98\x5e\0" }, + { 0xf9d1, 0, 255, "\x51\x6d\0" }, + { 0xf9d2, 0, 255, "\x62\x2e\0" }, + { 0xf9d3, 0, 255, "\x96\x78\0" }, + { 0xf9d4, 0, 255, "\x50\x2b\0" }, + { 0xf9d5, 0, 255, "\x5d\x19\0" }, + { 0xf9d6, 0, 255, "\x6d\xea\0" }, + { 0xf9d7, 0, 255, "\x8f\x2a\0" }, + { 0xf9d8, 0, 255, "\x5f\x8b\0" }, + { 0xf9d9, 0, 255, "\x61\x44\0" }, + { 0xf9da, 0, 255, "\x68\x17\0" }, + { 0xf9db, 0, 255, "\x73\x87\0" }, + { 0xf9dc, 0, 255, "\x96\x86\0" }, + { 0xf9dd, 0, 255, "\x52\x29\0" }, + { 0xf9de, 0, 255, "\x54\x0f\0" }, + { 0xf9df, 0, 255, "\x5c\x65\0" }, + { 0xf9e0, 0, 255, "\x66\x13\0" }, + { 0xf9e1, 0, 255, "\x67\x4e\0" }, + { 0xf9e2, 0, 255, "\x68\xa8\0" }, + { 0xf9e3, 0, 255, "\x6c\xe5\0" }, + { 0xf9e4, 0, 255, "\x74\x06\0" }, + { 0xf9e5, 0, 255, "\x75\xe2\0" }, + { 0xf9e6, 0, 255, "\x7f\x79\0" }, + { 0xf9e7, 0, 255, "\x88\xcf\0" }, + { 0xf9e8, 0, 255, "\x88\xe1\0" }, + { 0xf9e9, 0, 255, "\x91\xcc\0" }, + { 0xf9ea, 0, 255, "\x96\xe2\0" }, + { 0xf9eb, 0, 255, "\x53\x3f\0" }, + { 0xf9ec, 0, 255, "\x6e\xba\0" }, + { 0xf9ed, 0, 255, "\x54\x1d\0" }, + { 0xf9ee, 0, 255, "\x71\xd0\0" }, + { 0xf9ef, 0, 255, "\x74\x98\0" }, + { 0xf9f0, 0, 255, "\x85\xfa\0" }, + { 0xf9f1, 0, 255, "\x96\xa3\0" }, + { 0xf9f2, 0, 255, "\x9c\x57\0" }, + { 0xf9f3, 0, 255, "\x9e\x9f\0" }, + { 0xf9f4, 0, 255, "\x67\x97\0" }, + { 0xf9f5, 0, 255, "\x6d\xcb\0" }, + { 0xf9f6, 0, 255, "\x81\xe8\0" }, + { 0xf9f7, 0, 255, "\x7a\xcb\0" }, + { 0xf9f8, 0, 255, "\x7b\x20\0" }, + { 0xf9f9, 0, 255, "\x7c\x92\0" }, + { 0xf9fa, 0, 255, "\x72\xc0\0" }, + { 0xf9fb, 0, 255, "\x70\x99\0" }, + { 0xf9fc, 0, 255, "\x8b\x58\0" }, + { 0xf9fd, 0, 255, "\x4e\xc0\0" }, + { 0xf9fe, 0, 255, "\x83\x36\0" }, + { 0xf9ff, 0, 255, "\x52\x3a\0" }, + { 0xfa00, 0, 255, "\x52\x07\0" }, + { 0xfa01, 0, 255, "\x5e\xa6\0" }, + { 0xfa02, 0, 255, "\x62\xd3\0" }, + { 0xfa03, 0, 255, "\x7c\xd6\0" }, + { 0xfa04, 0, 255, "\x5b\x85\0" }, + { 0xfa05, 0, 255, "\x6d\x1e\0" }, + { 0xfa06, 0, 255, "\x66\xb4\0" }, + { 0xfa07, 0, 255, "\x8f\x3b\0" }, + { 0xfa08, 0, 255, "\x88\x4c\0" }, + { 0xfa09, 0, 255, "\x96\x4d\0" }, + { 0xfa0a, 0, 255, "\x89\x8b\0" }, + { 0xfa0b, 0, 255, "\x5e\xd3\0" }, + { 0xfa0c, 0, 255, "\x51\x40\0" }, + { 0xfa0d, 0, 255, "\x55\xc0\0" }, + { 0xfa10, 0, 255, "\x58\x5a\0" }, + { 0xfa12, 0, 255, "\x66\x74\0" }, + { 0xfa15, 0, 255, "\x51\xde\0" }, + { 0xfa16, 0, 255, "\x73\x2a\0" }, + { 0xfa17, 0, 255, "\x76\xca\0" }, + { 0xfa18, 0, 255, "\x79\x3c\0" }, + { 0xfa19, 0, 255, "\x79\x5e\0" }, + { 0xfa1a, 0, 255, "\x79\x65\0" }, + { 0xfa1b, 0, 255, "\x79\x8f\0" }, + { 0xfa1c, 0, 255, "\x97\x56\0" }, + { 0xfa1d, 0, 255, "\x7c\xbe\0" }, + { 0xfa1e, 0, 255, "\x7f\xbd\0" }, + { 0xfa20, 0, 255, "\x86\x12\0" }, + { 0xfa22, 0, 255, "\x8a\xf8\0" }, + { 0xfa25, 0, 255, "\x90\x38\0" }, + { 0xfa26, 0, 255, "\x90\xfd\0" }, + { 0xfa2a, 0, 255, "\x98\xef\0" }, + { 0xfa2b, 0, 255, "\x98\xfc\0" }, + { 0xfa2c, 0, 255, "\x99\x28\0" }, + { 0xfa2d, 0, 255, "\x9d\xb4\0" }, + { 0xfb00, 255, 0, "\x00\x66\x00\x66\0" }, + { 0xfb01, 255, 0, "\x00\x66\x00\x69\0" }, + { 0xfb02, 255, 0, "\x00\x66\x00\x6c\0" }, + { 0xfb03, 255, 0, "\x00\x66\x00\x66\x00\x69\0" }, + { 0xfb04, 255, 0, "\x00\x66\x00\x66\x00\x6c\0" }, + { 0xfb05, 255, 0, "\x00\x73\x00\x74\0" }, + { 0xfb06, 255, 0, "\x00\x73\x00\x74\0" }, + { 0xfb13, 255, 0, "\x05\x74\x05\x76\0" }, + { 0xfb14, 255, 0, "\x05\x74\x05\x65\0" }, + { 0xfb15, 255, 0, "\x05\x74\x05\x6b\0" }, + { 0xfb16, 255, 0, "\x05\x7e\x05\x76\0" }, + { 0xfb17, 255, 0, "\x05\x74\x05\x6d\0" }, + { 0xfb1d, 0, 255, "\x05\xd9\x05\xb4\0" }, + { 0xfb1f, 0, 255, "\x05\xf2\x05\xb7\0" }, + { 0xfb20, 255, 0, "\x05\xe2\0" }, + { 0xfb21, 255, 0, "\x05\xd0\0" }, + { 0xfb22, 255, 0, "\x05\xd3\0" }, + { 0xfb23, 255, 0, "\x05\xd4\0" }, + { 0xfb24, 255, 0, "\x05\xdb\0" }, + { 0xfb25, 255, 0, "\x05\xdc\0" }, + { 0xfb26, 255, 0, "\x05\xdd\0" }, + { 0xfb27, 255, 0, "\x05\xe8\0" }, + { 0xfb28, 255, 0, "\x05\xea\0" }, + { 0xfb29, 255, 0, "\x00\x2b\0" }, + { 0xfb2a, 0, 255, "\x05\xe9\x05\xc1\0" }, + { 0xfb2b, 0, 255, "\x05\xe9\x05\xc2\0" }, + { 0xfb2c, 0, 255, "\x05\xe9\x05\xbc\x05\xc1\0" }, + { 0xfb2d, 0, 255, "\x05\xe9\x05\xbc\x05\xc2\0" }, + { 0xfb2e, 0, 255, "\x05\xd0\x05\xb7\0" }, + { 0xfb2f, 0, 255, "\x05\xd0\x05\xb8\0" }, + { 0xfb30, 0, 255, "\x05\xd0\x05\xbc\0" }, + { 0xfb31, 0, 255, "\x05\xd1\x05\xbc\0" }, + { 0xfb32, 0, 255, "\x05\xd2\x05\xbc\0" }, + { 0xfb33, 0, 255, "\x05\xd3\x05\xbc\0" }, + { 0xfb34, 0, 255, "\x05\xd4\x05\xbc\0" }, + { 0xfb35, 0, 255, "\x05\xd5\x05\xbc\0" }, + { 0xfb36, 0, 255, "\x05\xd6\x05\xbc\0" }, + { 0xfb38, 0, 255, "\x05\xd8\x05\xbc\0" }, + { 0xfb39, 0, 255, "\x05\xd9\x05\xbc\0" }, + { 0xfb3a, 0, 255, "\x05\xda\x05\xbc\0" }, + { 0xfb3b, 0, 255, "\x05\xdb\x05\xbc\0" }, + { 0xfb3c, 0, 255, "\x05\xdc\x05\xbc\0" }, + { 0xfb3e, 0, 255, "\x05\xde\x05\xbc\0" }, + { 0xfb40, 0, 255, "\x05\xe0\x05\xbc\0" }, + { 0xfb41, 0, 255, "\x05\xe1\x05\xbc\0" }, + { 0xfb43, 0, 255, "\x05\xe3\x05\xbc\0" }, + { 0xfb44, 0, 255, "\x05\xe4\x05\xbc\0" }, + { 0xfb46, 0, 255, "\x05\xe6\x05\xbc\0" }, + { 0xfb47, 0, 255, "\x05\xe7\x05\xbc\0" }, + { 0xfb48, 0, 255, "\x05\xe8\x05\xbc\0" }, + { 0xfb49, 0, 255, "\x05\xe9\x05\xbc\0" }, + { 0xfb4a, 0, 255, "\x05\xea\x05\xbc\0" }, + { 0xfb4b, 0, 255, "\x05\xd5\x05\xb9\0" }, + { 0xfb4c, 0, 255, "\x05\xd1\x05\xbf\0" }, + { 0xfb4d, 0, 255, "\x05\xdb\x05\xbf\0" }, + { 0xfb4e, 0, 255, "\x05\xe4\x05\xbf\0" }, + { 0xfb4f, 255, 0, "\x05\xd0\x05\xdc\0" }, + { 0xfb50, 255, 0, "\x06\x71\0" }, + { 0xfb51, 255, 0, "\x06\x71\0" }, + { 0xfb52, 255, 0, "\x06\x7b\0" }, + { 0xfb53, 255, 0, "\x06\x7b\0" }, + { 0xfb54, 255, 0, "\x06\x7b\0" }, + { 0xfb55, 255, 0, "\x06\x7b\0" }, + { 0xfb56, 255, 0, "\x06\x7e\0" }, + { 0xfb57, 255, 0, "\x06\x7e\0" }, + { 0xfb58, 255, 0, "\x06\x7e\0" }, + { 0xfb59, 255, 0, "\x06\x7e\0" }, + { 0xfb5a, 255, 0, "\x06\x80\0" }, + { 0xfb5b, 255, 0, "\x06\x80\0" }, + { 0xfb5c, 255, 0, "\x06\x80\0" }, + { 0xfb5d, 255, 0, "\x06\x80\0" }, + { 0xfb5e, 255, 0, "\x06\x7a\0" }, + { 0xfb5f, 255, 0, "\x06\x7a\0" }, + { 0xfb60, 255, 0, "\x06\x7a\0" }, + { 0xfb61, 255, 0, "\x06\x7a\0" }, + { 0xfb62, 255, 0, "\x06\x7f\0" }, + { 0xfb63, 255, 0, "\x06\x7f\0" }, + { 0xfb64, 255, 0, "\x06\x7f\0" }, + { 0xfb65, 255, 0, "\x06\x7f\0" }, + { 0xfb66, 255, 0, "\x06\x79\0" }, + { 0xfb67, 255, 0, "\x06\x79\0" }, + { 0xfb68, 255, 0, "\x06\x79\0" }, + { 0xfb69, 255, 0, "\x06\x79\0" }, + { 0xfb6a, 255, 0, "\x06\xa4\0" }, + { 0xfb6b, 255, 0, "\x06\xa4\0" }, + { 0xfb6c, 255, 0, "\x06\xa4\0" }, + { 0xfb6d, 255, 0, "\x06\xa4\0" }, + { 0xfb6e, 255, 0, "\x06\xa6\0" }, + { 0xfb6f, 255, 0, "\x06\xa6\0" }, + { 0xfb70, 255, 0, "\x06\xa6\0" }, + { 0xfb71, 255, 0, "\x06\xa6\0" }, + { 0xfb72, 255, 0, "\x06\x84\0" }, + { 0xfb73, 255, 0, "\x06\x84\0" }, + { 0xfb74, 255, 0, "\x06\x84\0" }, + { 0xfb75, 255, 0, "\x06\x84\0" }, + { 0xfb76, 255, 0, "\x06\x83\0" }, + { 0xfb77, 255, 0, "\x06\x83\0" }, + { 0xfb78, 255, 0, "\x06\x83\0" }, + { 0xfb79, 255, 0, "\x06\x83\0" }, + { 0xfb7a, 255, 0, "\x06\x86\0" }, + { 0xfb7b, 255, 0, "\x06\x86\0" }, + { 0xfb7c, 255, 0, "\x06\x86\0" }, + { 0xfb7d, 255, 0, "\x06\x86\0" }, + { 0xfb7e, 255, 0, "\x06\x87\0" }, + { 0xfb7f, 255, 0, "\x06\x87\0" }, + { 0xfb80, 255, 0, "\x06\x87\0" }, + { 0xfb81, 255, 0, "\x06\x87\0" }, + { 0xfb82, 255, 0, "\x06\x8d\0" }, + { 0xfb83, 255, 0, "\x06\x8d\0" }, + { 0xfb84, 255, 0, "\x06\x8c\0" }, + { 0xfb85, 255, 0, "\x06\x8c\0" }, + { 0xfb86, 255, 0, "\x06\x8e\0" }, + { 0xfb87, 255, 0, "\x06\x8e\0" }, + { 0xfb88, 255, 0, "\x06\x88\0" }, + { 0xfb89, 255, 0, "\x06\x88\0" }, + { 0xfb8a, 255, 0, "\x06\x98\0" }, + { 0xfb8b, 255, 0, "\x06\x98\0" }, + { 0xfb8c, 255, 0, "\x06\x91\0" }, + { 0xfb8d, 255, 0, "\x06\x91\0" }, + { 0xfb8e, 255, 0, "\x06\xa9\0" }, + { 0xfb8f, 255, 0, "\x06\xa9\0" }, + { 0xfb90, 255, 0, "\x06\xa9\0" }, + { 0xfb91, 255, 0, "\x06\xa9\0" }, + { 0xfb92, 255, 0, "\x06\xaf\0" }, + { 0xfb93, 255, 0, "\x06\xaf\0" }, + { 0xfb94, 255, 0, "\x06\xaf\0" }, + { 0xfb95, 255, 0, "\x06\xaf\0" }, + { 0xfb96, 255, 0, "\x06\xb3\0" }, + { 0xfb97, 255, 0, "\x06\xb3\0" }, + { 0xfb98, 255, 0, "\x06\xb3\0" }, + { 0xfb99, 255, 0, "\x06\xb3\0" }, + { 0xfb9a, 255, 0, "\x06\xb1\0" }, + { 0xfb9b, 255, 0, "\x06\xb1\0" }, + { 0xfb9c, 255, 0, "\x06\xb1\0" }, + { 0xfb9d, 255, 0, "\x06\xb1\0" }, + { 0xfb9e, 255, 0, "\x06\xba\0" }, + { 0xfb9f, 255, 0, "\x06\xba\0" }, + { 0xfba0, 255, 0, "\x06\xbb\0" }, + { 0xfba1, 255, 0, "\x06\xbb\0" }, + { 0xfba2, 255, 0, "\x06\xbb\0" }, + { 0xfba3, 255, 0, "\x06\xbb\0" }, + { 0xfba4, 255, 0, "\x06\xd5\x06\x54\0" }, + { 0xfba5, 255, 0, "\x06\xd5\x06\x54\0" }, + { 0xfba6, 255, 0, "\x06\xc1\0" }, + { 0xfba7, 255, 0, "\x06\xc1\0" }, + { 0xfba8, 255, 0, "\x06\xc1\0" }, + { 0xfba9, 255, 0, "\x06\xc1\0" }, + { 0xfbaa, 255, 0, "\x06\xbe\0" }, + { 0xfbab, 255, 0, "\x06\xbe\0" }, + { 0xfbac, 255, 0, "\x06\xbe\0" }, + { 0xfbad, 255, 0, "\x06\xbe\0" }, + { 0xfbae, 255, 0, "\x06\xd2\0" }, + { 0xfbaf, 255, 0, "\x06\xd2\0" }, + { 0xfbb0, 255, 0, "\x06\xd2\x06\x54\0" }, + { 0xfbb1, 255, 0, "\x06\xd2\x06\x54\0" }, + { 0xfbd3, 255, 0, "\x06\xad\0" }, + { 0xfbd4, 255, 0, "\x06\xad\0" }, + { 0xfbd5, 255, 0, "\x06\xad\0" }, + { 0xfbd6, 255, 0, "\x06\xad\0" }, + { 0xfbd7, 255, 0, "\x06\xc7\0" }, + { 0xfbd8, 255, 0, "\x06\xc7\0" }, + { 0xfbd9, 255, 0, "\x06\xc6\0" }, + { 0xfbda, 255, 0, "\x06\xc6\0" }, + { 0xfbdb, 255, 0, "\x06\xc8\0" }, + { 0xfbdc, 255, 0, "\x06\xc8\0" }, + { 0xfbdd, 255, 0, "\x06\xc7\x06\x74\0" }, + { 0xfbde, 255, 0, "\x06\xcb\0" }, + { 0xfbdf, 255, 0, "\x06\xcb\0" }, + { 0xfbe0, 255, 0, "\x06\xc5\0" }, + { 0xfbe1, 255, 0, "\x06\xc5\0" }, + { 0xfbe2, 255, 0, "\x06\xc9\0" }, + { 0xfbe3, 255, 0, "\x06\xc9\0" }, + { 0xfbe4, 255, 0, "\x06\xd0\0" }, + { 0xfbe5, 255, 0, "\x06\xd0\0" }, + { 0xfbe6, 255, 0, "\x06\xd0\0" }, + { 0xfbe7, 255, 0, "\x06\xd0\0" }, + { 0xfbe8, 255, 0, "\x06\x49\0" }, + { 0xfbe9, 255, 0, "\x06\x49\0" }, + { 0xfbea, 255, 0, "\x06\x4a\x06\x54\x06\x27\0" }, + { 0xfbeb, 255, 0, "\x06\x4a\x06\x54\x06\x27\0" }, + { 0xfbec, 255, 0, "\x06\x4a\x06\x54\x06\xd5\0" }, + { 0xfbed, 255, 0, "\x06\x4a\x06\x54\x06\xd5\0" }, + { 0xfbee, 255, 0, "\x06\x4a\x06\x54\x06\x48\0" }, + { 0xfbef, 255, 0, "\x06\x4a\x06\x54\x06\x48\0" }, + { 0xfbf0, 255, 0, "\x06\x4a\x06\x54\x06\xc7\0" }, + { 0xfbf1, 255, 0, "\x06\x4a\x06\x54\x06\xc7\0" }, + { 0xfbf2, 255, 0, "\x06\x4a\x06\x54\x06\xc6\0" }, + { 0xfbf3, 255, 0, "\x06\x4a\x06\x54\x06\xc6\0" }, + { 0xfbf4, 255, 0, "\x06\x4a\x06\x54\x06\xc8\0" }, + { 0xfbf5, 255, 0, "\x06\x4a\x06\x54\x06\xc8\0" }, + { 0xfbf6, 255, 0, "\x06\x4a\x06\x54\x06\xd0\0" }, + { 0xfbf7, 255, 0, "\x06\x4a\x06\x54\x06\xd0\0" }, + { 0xfbf8, 255, 0, "\x06\x4a\x06\x54\x06\xd0\0" }, + { 0xfbf9, 255, 0, "\x06\x4a\x06\x54\x06\x49\0" }, + { 0xfbfa, 255, 0, "\x06\x4a\x06\x54\x06\x49\0" }, + { 0xfbfb, 255, 0, "\x06\x4a\x06\x54\x06\x49\0" }, + { 0xfbfc, 255, 0, "\x06\xcc\0" }, + { 0xfbfd, 255, 0, "\x06\xcc\0" }, + { 0xfbfe, 255, 0, "\x06\xcc\0" }, + { 0xfbff, 255, 0, "\x06\xcc\0" }, + { 0xfc00, 255, 0, "\x06\x4a\x06\x54\x06\x2c\0" }, + { 0xfc01, 255, 0, "\x06\x4a\x06\x54\x06\x2d\0" }, + { 0xfc02, 255, 0, "\x06\x4a\x06\x54\x06\x45\0" }, + { 0xfc03, 255, 0, "\x06\x4a\x06\x54\x06\x49\0" }, + { 0xfc04, 255, 0, "\x06\x4a\x06\x54\x06\x4a\0" }, + { 0xfc05, 255, 0, "\x06\x28\x06\x2c\0" }, + { 0xfc06, 255, 0, "\x06\x28\x06\x2d\0" }, + { 0xfc07, 255, 0, "\x06\x28\x06\x2e\0" }, + { 0xfc08, 255, 0, "\x06\x28\x06\x45\0" }, + { 0xfc09, 255, 0, "\x06\x28\x06\x49\0" }, + { 0xfc0a, 255, 0, "\x06\x28\x06\x4a\0" }, + { 0xfc0b, 255, 0, "\x06\x2a\x06\x2c\0" }, + { 0xfc0c, 255, 0, "\x06\x2a\x06\x2d\0" }, + { 0xfc0d, 255, 0, "\x06\x2a\x06\x2e\0" }, + { 0xfc0e, 255, 0, "\x06\x2a\x06\x45\0" }, + { 0xfc0f, 255, 0, "\x06\x2a\x06\x49\0" }, + { 0xfc10, 255, 0, "\x06\x2a\x06\x4a\0" }, + { 0xfc11, 255, 0, "\x06\x2b\x06\x2c\0" }, + { 0xfc12, 255, 0, "\x06\x2b\x06\x45\0" }, + { 0xfc13, 255, 0, "\x06\x2b\x06\x49\0" }, + { 0xfc14, 255, 0, "\x06\x2b\x06\x4a\0" }, + { 0xfc15, 255, 0, "\x06\x2c\x06\x2d\0" }, + { 0xfc16, 255, 0, "\x06\x2c\x06\x45\0" }, + { 0xfc17, 255, 0, "\x06\x2d\x06\x2c\0" }, + { 0xfc18, 255, 0, "\x06\x2d\x06\x45\0" }, + { 0xfc19, 255, 0, "\x06\x2e\x06\x2c\0" }, + { 0xfc1a, 255, 0, "\x06\x2e\x06\x2d\0" }, + { 0xfc1b, 255, 0, "\x06\x2e\x06\x45\0" }, + { 0xfc1c, 255, 0, "\x06\x33\x06\x2c\0" }, + { 0xfc1d, 255, 0, "\x06\x33\x06\x2d\0" }, + { 0xfc1e, 255, 0, "\x06\x33\x06\x2e\0" }, + { 0xfc1f, 255, 0, "\x06\x33\x06\x45\0" }, + { 0xfc20, 255, 0, "\x06\x35\x06\x2d\0" }, + { 0xfc21, 255, 0, "\x06\x35\x06\x45\0" }, + { 0xfc22, 255, 0, "\x06\x36\x06\x2c\0" }, + { 0xfc23, 255, 0, "\x06\x36\x06\x2d\0" }, + { 0xfc24, 255, 0, "\x06\x36\x06\x2e\0" }, + { 0xfc25, 255, 0, "\x06\x36\x06\x45\0" }, + { 0xfc26, 255, 0, "\x06\x37\x06\x2d\0" }, + { 0xfc27, 255, 0, "\x06\x37\x06\x45\0" }, + { 0xfc28, 255, 0, "\x06\x38\x06\x45\0" }, + { 0xfc29, 255, 0, "\x06\x39\x06\x2c\0" }, + { 0xfc2a, 255, 0, "\x06\x39\x06\x45\0" }, + { 0xfc2b, 255, 0, "\x06\x3a\x06\x2c\0" }, + { 0xfc2c, 255, 0, "\x06\x3a\x06\x45\0" }, + { 0xfc2d, 255, 0, "\x06\x41\x06\x2c\0" }, + { 0xfc2e, 255, 0, "\x06\x41\x06\x2d\0" }, + { 0xfc2f, 255, 0, "\x06\x41\x06\x2e\0" }, + { 0xfc30, 255, 0, "\x06\x41\x06\x45\0" }, + { 0xfc31, 255, 0, "\x06\x41\x06\x49\0" }, + { 0xfc32, 255, 0, "\x06\x41\x06\x4a\0" }, + { 0xfc33, 255, 0, "\x06\x42\x06\x2d\0" }, + { 0xfc34, 255, 0, "\x06\x42\x06\x45\0" }, + { 0xfc35, 255, 0, "\x06\x42\x06\x49\0" }, + { 0xfc36, 255, 0, "\x06\x42\x06\x4a\0" }, + { 0xfc37, 255, 0, "\x06\x43\x06\x27\0" }, + { 0xfc38, 255, 0, "\x06\x43\x06\x2c\0" }, + { 0xfc39, 255, 0, "\x06\x43\x06\x2d\0" }, + { 0xfc3a, 255, 0, "\x06\x43\x06\x2e\0" }, + { 0xfc3b, 255, 0, "\x06\x43\x06\x44\0" }, + { 0xfc3c, 255, 0, "\x06\x43\x06\x45\0" }, + { 0xfc3d, 255, 0, "\x06\x43\x06\x49\0" }, + { 0xfc3e, 255, 0, "\x06\x43\x06\x4a\0" }, + { 0xfc3f, 255, 0, "\x06\x44\x06\x2c\0" }, + { 0xfc40, 255, 0, "\x06\x44\x06\x2d\0" }, + { 0xfc41, 255, 0, "\x06\x44\x06\x2e\0" }, + { 0xfc42, 255, 0, "\x06\x44\x06\x45\0" }, + { 0xfc43, 255, 0, "\x06\x44\x06\x49\0" }, + { 0xfc44, 255, 0, "\x06\x44\x06\x4a\0" }, + { 0xfc45, 255, 0, "\x06\x45\x06\x2c\0" }, + { 0xfc46, 255, 0, "\x06\x45\x06\x2d\0" }, + { 0xfc47, 255, 0, "\x06\x45\x06\x2e\0" }, + { 0xfc48, 255, 0, "\x06\x45\x06\x45\0" }, + { 0xfc49, 255, 0, "\x06\x45\x06\x49\0" }, + { 0xfc4a, 255, 0, "\x06\x45\x06\x4a\0" }, + { 0xfc4b, 255, 0, "\x06\x46\x06\x2c\0" }, + { 0xfc4c, 255, 0, "\x06\x46\x06\x2d\0" }, + { 0xfc4d, 255, 0, "\x06\x46\x06\x2e\0" }, + { 0xfc4e, 255, 0, "\x06\x46\x06\x45\0" }, + { 0xfc4f, 255, 0, "\x06\x46\x06\x49\0" }, + { 0xfc50, 255, 0, "\x06\x46\x06\x4a\0" }, + { 0xfc51, 255, 0, "\x06\x47\x06\x2c\0" }, + { 0xfc52, 255, 0, "\x06\x47\x06\x45\0" }, + { 0xfc53, 255, 0, "\x06\x47\x06\x49\0" }, + { 0xfc54, 255, 0, "\x06\x47\x06\x4a\0" }, + { 0xfc55, 255, 0, "\x06\x4a\x06\x2c\0" }, + { 0xfc56, 255, 0, "\x06\x4a\x06\x2d\0" }, + { 0xfc57, 255, 0, "\x06\x4a\x06\x2e\0" }, + { 0xfc58, 255, 0, "\x06\x4a\x06\x45\0" }, + { 0xfc59, 255, 0, "\x06\x4a\x06\x49\0" }, + { 0xfc5a, 255, 0, "\x06\x4a\x06\x4a\0" }, + { 0xfc5b, 255, 0, "\x06\x30\x06\x70\0" }, + { 0xfc5c, 255, 0, "\x06\x31\x06\x70\0" }, + { 0xfc5d, 255, 0, "\x06\x49\x06\x70\0" }, + { 0xfc5e, 255, 0, "\x00\x20\x06\x4c\x06\x51\0" }, + { 0xfc5f, 255, 0, "\x00\x20\x06\x4d\x06\x51\0" }, + { 0xfc60, 255, 0, "\x00\x20\x06\x4e\x06\x51\0" }, + { 0xfc61, 255, 0, "\x00\x20\x06\x4f\x06\x51\0" }, + { 0xfc62, 255, 0, "\x00\x20\x06\x50\x06\x51\0" }, + { 0xfc63, 255, 0, "\x00\x20\x06\x51\x06\x70\0" }, + { 0xfc64, 255, 0, "\x06\x4a\x06\x54\x06\x31\0" }, + { 0xfc65, 255, 0, "\x06\x4a\x06\x54\x06\x32\0" }, + { 0xfc66, 255, 0, "\x06\x4a\x06\x54\x06\x45\0" }, + { 0xfc67, 255, 0, "\x06\x4a\x06\x54\x06\x46\0" }, + { 0xfc68, 255, 0, "\x06\x4a\x06\x54\x06\x49\0" }, + { 0xfc69, 255, 0, "\x06\x4a\x06\x54\x06\x4a\0" }, + { 0xfc6a, 255, 0, "\x06\x28\x06\x31\0" }, + { 0xfc6b, 255, 0, "\x06\x28\x06\x32\0" }, + { 0xfc6c, 255, 0, "\x06\x28\x06\x45\0" }, + { 0xfc6d, 255, 0, "\x06\x28\x06\x46\0" }, + { 0xfc6e, 255, 0, "\x06\x28\x06\x49\0" }, + { 0xfc6f, 255, 0, "\x06\x28\x06\x4a\0" }, + { 0xfc70, 255, 0, "\x06\x2a\x06\x31\0" }, + { 0xfc71, 255, 0, "\x06\x2a\x06\x32\0" }, + { 0xfc72, 255, 0, "\x06\x2a\x06\x45\0" }, + { 0xfc73, 255, 0, "\x06\x2a\x06\x46\0" }, + { 0xfc74, 255, 0, "\x06\x2a\x06\x49\0" }, + { 0xfc75, 255, 0, "\x06\x2a\x06\x4a\0" }, + { 0xfc76, 255, 0, "\x06\x2b\x06\x31\0" }, + { 0xfc77, 255, 0, "\x06\x2b\x06\x32\0" }, + { 0xfc78, 255, 0, "\x06\x2b\x06\x45\0" }, + { 0xfc79, 255, 0, "\x06\x2b\x06\x46\0" }, + { 0xfc7a, 255, 0, "\x06\x2b\x06\x49\0" }, + { 0xfc7b, 255, 0, "\x06\x2b\x06\x4a\0" }, + { 0xfc7c, 255, 0, "\x06\x41\x06\x49\0" }, + { 0xfc7d, 255, 0, "\x06\x41\x06\x4a\0" }, + { 0xfc7e, 255, 0, "\x06\x42\x06\x49\0" }, + { 0xfc7f, 255, 0, "\x06\x42\x06\x4a\0" }, + { 0xfc80, 255, 0, "\x06\x43\x06\x27\0" }, + { 0xfc81, 255, 0, "\x06\x43\x06\x44\0" }, + { 0xfc82, 255, 0, "\x06\x43\x06\x45\0" }, + { 0xfc83, 255, 0, "\x06\x43\x06\x49\0" }, + { 0xfc84, 255, 0, "\x06\x43\x06\x4a\0" }, + { 0xfc85, 255, 0, "\x06\x44\x06\x45\0" }, + { 0xfc86, 255, 0, "\x06\x44\x06\x49\0" }, + { 0xfc87, 255, 0, "\x06\x44\x06\x4a\0" }, + { 0xfc88, 255, 0, "\x06\x45\x06\x27\0" }, + { 0xfc89, 255, 0, "\x06\x45\x06\x45\0" }, + { 0xfc8a, 255, 0, "\x06\x46\x06\x31\0" }, + { 0xfc8b, 255, 0, "\x06\x46\x06\x32\0" }, + { 0xfc8c, 255, 0, "\x06\x46\x06\x45\0" }, + { 0xfc8d, 255, 0, "\x06\x46\x06\x46\0" }, + { 0xfc8e, 255, 0, "\x06\x46\x06\x49\0" }, + { 0xfc8f, 255, 0, "\x06\x46\x06\x4a\0" }, + { 0xfc90, 255, 0, "\x06\x49\x06\x70\0" }, + { 0xfc91, 255, 0, "\x06\x4a\x06\x31\0" }, + { 0xfc92, 255, 0, "\x06\x4a\x06\x32\0" }, + { 0xfc93, 255, 0, "\x06\x4a\x06\x45\0" }, + { 0xfc94, 255, 0, "\x06\x4a\x06\x46\0" }, + { 0xfc95, 255, 0, "\x06\x4a\x06\x49\0" }, + { 0xfc96, 255, 0, "\x06\x4a\x06\x4a\0" }, + { 0xfc97, 255, 0, "\x06\x4a\x06\x54\x06\x2c\0" }, + { 0xfc98, 255, 0, "\x06\x4a\x06\x54\x06\x2d\0" }, + { 0xfc99, 255, 0, "\x06\x4a\x06\x54\x06\x2e\0" }, + { 0xfc9a, 255, 0, "\x06\x4a\x06\x54\x06\x45\0" }, + { 0xfc9b, 255, 0, "\x06\x4a\x06\x54\x06\x47\0" }, + { 0xfc9c, 255, 0, "\x06\x28\x06\x2c\0" }, + { 0xfc9d, 255, 0, "\x06\x28\x06\x2d\0" }, + { 0xfc9e, 255, 0, "\x06\x28\x06\x2e\0" }, + { 0xfc9f, 255, 0, "\x06\x28\x06\x45\0" }, + { 0xfca0, 255, 0, "\x06\x28\x06\x47\0" }, + { 0xfca1, 255, 0, "\x06\x2a\x06\x2c\0" }, + { 0xfca2, 255, 0, "\x06\x2a\x06\x2d\0" }, + { 0xfca3, 255, 0, "\x06\x2a\x06\x2e\0" }, + { 0xfca4, 255, 0, "\x06\x2a\x06\x45\0" }, + { 0xfca5, 255, 0, "\x06\x2a\x06\x47\0" }, + { 0xfca6, 255, 0, "\x06\x2b\x06\x45\0" }, + { 0xfca7, 255, 0, "\x06\x2c\x06\x2d\0" }, + { 0xfca8, 255, 0, "\x06\x2c\x06\x45\0" }, + { 0xfca9, 255, 0, "\x06\x2d\x06\x2c\0" }, + { 0xfcaa, 255, 0, "\x06\x2d\x06\x45\0" }, + { 0xfcab, 255, 0, "\x06\x2e\x06\x2c\0" }, + { 0xfcac, 255, 0, "\x06\x2e\x06\x45\0" }, + { 0xfcad, 255, 0, "\x06\x33\x06\x2c\0" }, + { 0xfcae, 255, 0, "\x06\x33\x06\x2d\0" }, + { 0xfcaf, 255, 0, "\x06\x33\x06\x2e\0" }, + { 0xfcb0, 255, 0, "\x06\x33\x06\x45\0" }, + { 0xfcb1, 255, 0, "\x06\x35\x06\x2d\0" }, + { 0xfcb2, 255, 0, "\x06\x35\x06\x2e\0" }, + { 0xfcb3, 255, 0, "\x06\x35\x06\x45\0" }, + { 0xfcb4, 255, 0, "\x06\x36\x06\x2c\0" }, + { 0xfcb5, 255, 0, "\x06\x36\x06\x2d\0" }, + { 0xfcb6, 255, 0, "\x06\x36\x06\x2e\0" }, + { 0xfcb7, 255, 0, "\x06\x36\x06\x45\0" }, + { 0xfcb8, 255, 0, "\x06\x37\x06\x2d\0" }, + { 0xfcb9, 255, 0, "\x06\x38\x06\x45\0" }, + { 0xfcba, 255, 0, "\x06\x39\x06\x2c\0" }, + { 0xfcbb, 255, 0, "\x06\x39\x06\x45\0" }, + { 0xfcbc, 255, 0, "\x06\x3a\x06\x2c\0" }, + { 0xfcbd, 255, 0, "\x06\x3a\x06\x45\0" }, + { 0xfcbe, 255, 0, "\x06\x41\x06\x2c\0" }, + { 0xfcbf, 255, 0, "\x06\x41\x06\x2d\0" }, + { 0xfcc0, 255, 0, "\x06\x41\x06\x2e\0" }, + { 0xfcc1, 255, 0, "\x06\x41\x06\x45\0" }, + { 0xfcc2, 255, 0, "\x06\x42\x06\x2d\0" }, + { 0xfcc3, 255, 0, "\x06\x42\x06\x45\0" }, + { 0xfcc4, 255, 0, "\x06\x43\x06\x2c\0" }, + { 0xfcc5, 255, 0, "\x06\x43\x06\x2d\0" }, + { 0xfcc6, 255, 0, "\x06\x43\x06\x2e\0" }, + { 0xfcc7, 255, 0, "\x06\x43\x06\x44\0" }, + { 0xfcc8, 255, 0, "\x06\x43\x06\x45\0" }, + { 0xfcc9, 255, 0, "\x06\x44\x06\x2c\0" }, + { 0xfcca, 255, 0, "\x06\x44\x06\x2d\0" }, + { 0xfccb, 255, 0, "\x06\x44\x06\x2e\0" }, + { 0xfccc, 255, 0, "\x06\x44\x06\x45\0" }, + { 0xfccd, 255, 0, "\x06\x44\x06\x47\0" }, + { 0xfcce, 255, 0, "\x06\x45\x06\x2c\0" }, + { 0xfccf, 255, 0, "\x06\x45\x06\x2d\0" }, + { 0xfcd0, 255, 0, "\x06\x45\x06\x2e\0" }, + { 0xfcd1, 255, 0, "\x06\x45\x06\x45\0" }, + { 0xfcd2, 255, 0, "\x06\x46\x06\x2c\0" }, + { 0xfcd3, 255, 0, "\x06\x46\x06\x2d\0" }, + { 0xfcd4, 255, 0, "\x06\x46\x06\x2e\0" }, + { 0xfcd5, 255, 0, "\x06\x46\x06\x45\0" }, + { 0xfcd6, 255, 0, "\x06\x46\x06\x47\0" }, + { 0xfcd7, 255, 0, "\x06\x47\x06\x2c\0" }, + { 0xfcd8, 255, 0, "\x06\x47\x06\x45\0" }, + { 0xfcd9, 255, 0, "\x06\x47\x06\x70\0" }, + { 0xfcda, 255, 0, "\x06\x4a\x06\x2c\0" }, + { 0xfcdb, 255, 0, "\x06\x4a\x06\x2d\0" }, + { 0xfcdc, 255, 0, "\x06\x4a\x06\x2e\0" }, + { 0xfcdd, 255, 0, "\x06\x4a\x06\x45\0" }, + { 0xfcde, 255, 0, "\x06\x4a\x06\x47\0" }, + { 0xfcdf, 255, 0, "\x06\x4a\x06\x54\x06\x45\0" }, + { 0xfce0, 255, 0, "\x06\x4a\x06\x54\x06\x47\0" }, + { 0xfce1, 255, 0, "\x06\x28\x06\x45\0" }, + { 0xfce2, 255, 0, "\x06\x28\x06\x47\0" }, + { 0xfce3, 255, 0, "\x06\x2a\x06\x45\0" }, + { 0xfce4, 255, 0, "\x06\x2a\x06\x47\0" }, + { 0xfce5, 255, 0, "\x06\x2b\x06\x45\0" }, + { 0xfce6, 255, 0, "\x06\x2b\x06\x47\0" }, + { 0xfce7, 255, 0, "\x06\x33\x06\x45\0" }, + { 0xfce8, 255, 0, "\x06\x33\x06\x47\0" }, + { 0xfce9, 255, 0, "\x06\x34\x06\x45\0" }, + { 0xfcea, 255, 0, "\x06\x34\x06\x47\0" }, + { 0xfceb, 255, 0, "\x06\x43\x06\x44\0" }, + { 0xfcec, 255, 0, "\x06\x43\x06\x45\0" }, + { 0xfced, 255, 0, "\x06\x44\x06\x45\0" }, + { 0xfcee, 255, 0, "\x06\x46\x06\x45\0" }, + { 0xfcef, 255, 0, "\x06\x46\x06\x47\0" }, + { 0xfcf0, 255, 0, "\x06\x4a\x06\x45\0" }, + { 0xfcf1, 255, 0, "\x06\x4a\x06\x47\0" }, + { 0xfcf2, 255, 0, "\x06\x40\x06\x4e\x06\x51\0" }, + { 0xfcf3, 255, 0, "\x06\x40\x06\x4f\x06\x51\0" }, + { 0xfcf4, 255, 0, "\x06\x40\x06\x50\x06\x51\0" }, + { 0xfcf5, 255, 0, "\x06\x37\x06\x49\0" }, + { 0xfcf6, 255, 0, "\x06\x37\x06\x4a\0" }, + { 0xfcf7, 255, 0, "\x06\x39\x06\x49\0" }, + { 0xfcf8, 255, 0, "\x06\x39\x06\x4a\0" }, + { 0xfcf9, 255, 0, "\x06\x3a\x06\x49\0" }, + { 0xfcfa, 255, 0, "\x06\x3a\x06\x4a\0" }, + { 0xfcfb, 255, 0, "\x06\x33\x06\x49\0" }, + { 0xfcfc, 255, 0, "\x06\x33\x06\x4a\0" }, + { 0xfcfd, 255, 0, "\x06\x34\x06\x49\0" }, + { 0xfcfe, 255, 0, "\x06\x34\x06\x4a\0" }, + { 0xfcff, 255, 0, "\x06\x2d\x06\x49\0" }, + { 0xfd00, 255, 0, "\x06\x2d\x06\x4a\0" }, + { 0xfd01, 255, 0, "\x06\x2c\x06\x49\0" }, + { 0xfd02, 255, 0, "\x06\x2c\x06\x4a\0" }, + { 0xfd03, 255, 0, "\x06\x2e\x06\x49\0" }, + { 0xfd04, 255, 0, "\x06\x2e\x06\x4a\0" }, + { 0xfd05, 255, 0, "\x06\x35\x06\x49\0" }, + { 0xfd06, 255, 0, "\x06\x35\x06\x4a\0" }, + { 0xfd07, 255, 0, "\x06\x36\x06\x49\0" }, + { 0xfd08, 255, 0, "\x06\x36\x06\x4a\0" }, + { 0xfd09, 255, 0, "\x06\x34\x06\x2c\0" }, + { 0xfd0a, 255, 0, "\x06\x34\x06\x2d\0" }, + { 0xfd0b, 255, 0, "\x06\x34\x06\x2e\0" }, + { 0xfd0c, 255, 0, "\x06\x34\x06\x45\0" }, + { 0xfd0d, 255, 0, "\x06\x34\x06\x31\0" }, + { 0xfd0e, 255, 0, "\x06\x33\x06\x31\0" }, + { 0xfd0f, 255, 0, "\x06\x35\x06\x31\0" }, + { 0xfd10, 255, 0, "\x06\x36\x06\x31\0" }, + { 0xfd11, 255, 0, "\x06\x37\x06\x49\0" }, + { 0xfd12, 255, 0, "\x06\x37\x06\x4a\0" }, + { 0xfd13, 255, 0, "\x06\x39\x06\x49\0" }, + { 0xfd14, 255, 0, "\x06\x39\x06\x4a\0" }, + { 0xfd15, 255, 0, "\x06\x3a\x06\x49\0" }, + { 0xfd16, 255, 0, "\x06\x3a\x06\x4a\0" }, + { 0xfd17, 255, 0, "\x06\x33\x06\x49\0" }, + { 0xfd18, 255, 0, "\x06\x33\x06\x4a\0" }, + { 0xfd19, 255, 0, "\x06\x34\x06\x49\0" }, + { 0xfd1a, 255, 0, "\x06\x34\x06\x4a\0" }, + { 0xfd1b, 255, 0, "\x06\x2d\x06\x49\0" }, + { 0xfd1c, 255, 0, "\x06\x2d\x06\x4a\0" }, + { 0xfd1d, 255, 0, "\x06\x2c\x06\x49\0" }, + { 0xfd1e, 255, 0, "\x06\x2c\x06\x4a\0" }, + { 0xfd1f, 255, 0, "\x06\x2e\x06\x49\0" }, + { 0xfd20, 255, 0, "\x06\x2e\x06\x4a\0" }, + { 0xfd21, 255, 0, "\x06\x35\x06\x49\0" }, + { 0xfd22, 255, 0, "\x06\x35\x06\x4a\0" }, + { 0xfd23, 255, 0, "\x06\x36\x06\x49\0" }, + { 0xfd24, 255, 0, "\x06\x36\x06\x4a\0" }, + { 0xfd25, 255, 0, "\x06\x34\x06\x2c\0" }, + { 0xfd26, 255, 0, "\x06\x34\x06\x2d\0" }, + { 0xfd27, 255, 0, "\x06\x34\x06\x2e\0" }, + { 0xfd28, 255, 0, "\x06\x34\x06\x45\0" }, + { 0xfd29, 255, 0, "\x06\x34\x06\x31\0" }, + { 0xfd2a, 255, 0, "\x06\x33\x06\x31\0" }, + { 0xfd2b, 255, 0, "\x06\x35\x06\x31\0" }, + { 0xfd2c, 255, 0, "\x06\x36\x06\x31\0" }, + { 0xfd2d, 255, 0, "\x06\x34\x06\x2c\0" }, + { 0xfd2e, 255, 0, "\x06\x34\x06\x2d\0" }, + { 0xfd2f, 255, 0, "\x06\x34\x06\x2e\0" }, + { 0xfd30, 255, 0, "\x06\x34\x06\x45\0" }, + { 0xfd31, 255, 0, "\x06\x33\x06\x47\0" }, + { 0xfd32, 255, 0, "\x06\x34\x06\x47\0" }, + { 0xfd33, 255, 0, "\x06\x37\x06\x45\0" }, + { 0xfd34, 255, 0, "\x06\x33\x06\x2c\0" }, + { 0xfd35, 255, 0, "\x06\x33\x06\x2d\0" }, + { 0xfd36, 255, 0, "\x06\x33\x06\x2e\0" }, + { 0xfd37, 255, 0, "\x06\x34\x06\x2c\0" }, + { 0xfd38, 255, 0, "\x06\x34\x06\x2d\0" }, + { 0xfd39, 255, 0, "\x06\x34\x06\x2e\0" }, + { 0xfd3a, 255, 0, "\x06\x37\x06\x45\0" }, + { 0xfd3b, 255, 0, "\x06\x38\x06\x45\0" }, + { 0xfd3c, 255, 0, "\x06\x27\x06\x4b\0" }, + { 0xfd3d, 255, 0, "\x06\x27\x06\x4b\0" }, + { 0xfd50, 255, 0, "\x06\x2a\x06\x2c\x06\x45\0" }, + { 0xfd51, 255, 0, "\x06\x2a\x06\x2d\x06\x2c\0" }, + { 0xfd52, 255, 0, "\x06\x2a\x06\x2d\x06\x2c\0" }, + { 0xfd53, 255, 0, "\x06\x2a\x06\x2d\x06\x45\0" }, + { 0xfd54, 255, 0, "\x06\x2a\x06\x2e\x06\x45\0" }, + { 0xfd55, 255, 0, "\x06\x2a\x06\x45\x06\x2c\0" }, + { 0xfd56, 255, 0, "\x06\x2a\x06\x45\x06\x2d\0" }, + { 0xfd57, 255, 0, "\x06\x2a\x06\x45\x06\x2e\0" }, + { 0xfd58, 255, 0, "\x06\x2c\x06\x45\x06\x2d\0" }, + { 0xfd59, 255, 0, "\x06\x2c\x06\x45\x06\x2d\0" }, + { 0xfd5a, 255, 0, "\x06\x2d\x06\x45\x06\x4a\0" }, + { 0xfd5b, 255, 0, "\x06\x2d\x06\x45\x06\x49\0" }, + { 0xfd5c, 255, 0, "\x06\x33\x06\x2d\x06\x2c\0" }, + { 0xfd5d, 255, 0, "\x06\x33\x06\x2c\x06\x2d\0" }, + { 0xfd5e, 255, 0, "\x06\x33\x06\x2c\x06\x49\0" }, + { 0xfd5f, 255, 0, "\x06\x33\x06\x45\x06\x2d\0" }, + { 0xfd60, 255, 0, "\x06\x33\x06\x45\x06\x2d\0" }, + { 0xfd61, 255, 0, "\x06\x33\x06\x45\x06\x2c\0" }, + { 0xfd62, 255, 0, "\x06\x33\x06\x45\x06\x45\0" }, + { 0xfd63, 255, 0, "\x06\x33\x06\x45\x06\x45\0" }, + { 0xfd64, 255, 0, "\x06\x35\x06\x2d\x06\x2d\0" }, + { 0xfd65, 255, 0, "\x06\x35\x06\x2d\x06\x2d\0" }, + { 0xfd66, 255, 0, "\x06\x35\x06\x45\x06\x45\0" }, + { 0xfd67, 255, 0, "\x06\x34\x06\x2d\x06\x45\0" }, + { 0xfd68, 255, 0, "\x06\x34\x06\x2d\x06\x45\0" }, + { 0xfd69, 255, 0, "\x06\x34\x06\x2c\x06\x4a\0" }, + { 0xfd6a, 255, 0, "\x06\x34\x06\x45\x06\x2e\0" }, + { 0xfd6b, 255, 0, "\x06\x34\x06\x45\x06\x2e\0" }, + { 0xfd6c, 255, 0, "\x06\x34\x06\x45\x06\x45\0" }, + { 0xfd6d, 255, 0, "\x06\x34\x06\x45\x06\x45\0" }, + { 0xfd6e, 255, 0, "\x06\x36\x06\x2d\x06\x49\0" }, + { 0xfd6f, 255, 0, "\x06\x36\x06\x2e\x06\x45\0" }, + { 0xfd70, 255, 0, "\x06\x36\x06\x2e\x06\x45\0" }, + { 0xfd71, 255, 0, "\x06\x37\x06\x45\x06\x2d\0" }, + { 0xfd72, 255, 0, "\x06\x37\x06\x45\x06\x2d\0" }, + { 0xfd73, 255, 0, "\x06\x37\x06\x45\x06\x45\0" }, + { 0xfd74, 255, 0, "\x06\x37\x06\x45\x06\x4a\0" }, + { 0xfd75, 255, 0, "\x06\x39\x06\x2c\x06\x45\0" }, + { 0xfd76, 255, 0, "\x06\x39\x06\x45\x06\x45\0" }, + { 0xfd77, 255, 0, "\x06\x39\x06\x45\x06\x45\0" }, + { 0xfd78, 255, 0, "\x06\x39\x06\x45\x06\x49\0" }, + { 0xfd79, 255, 0, "\x06\x3a\x06\x45\x06\x45\0" }, + { 0xfd7a, 255, 0, "\x06\x3a\x06\x45\x06\x4a\0" }, + { 0xfd7b, 255, 0, "\x06\x3a\x06\x45\x06\x49\0" }, + { 0xfd7c, 255, 0, "\x06\x41\x06\x2e\x06\x45\0" }, + { 0xfd7d, 255, 0, "\x06\x41\x06\x2e\x06\x45\0" }, + { 0xfd7e, 255, 0, "\x06\x42\x06\x45\x06\x2d\0" }, + { 0xfd7f, 255, 0, "\x06\x42\x06\x45\x06\x45\0" }, + { 0xfd80, 255, 0, "\x06\x44\x06\x2d\x06\x45\0" }, + { 0xfd81, 255, 0, "\x06\x44\x06\x2d\x06\x4a\0" }, + { 0xfd82, 255, 0, "\x06\x44\x06\x2d\x06\x49\0" }, + { 0xfd83, 255, 0, "\x06\x44\x06\x2c\x06\x2c\0" }, + { 0xfd84, 255, 0, "\x06\x44\x06\x2c\x06\x2c\0" }, + { 0xfd85, 255, 0, "\x06\x44\x06\x2e\x06\x45\0" }, + { 0xfd86, 255, 0, "\x06\x44\x06\x2e\x06\x45\0" }, + { 0xfd87, 255, 0, "\x06\x44\x06\x45\x06\x2d\0" }, + { 0xfd88, 255, 0, "\x06\x44\x06\x45\x06\x2d\0" }, + { 0xfd89, 255, 0, "\x06\x45\x06\x2d\x06\x2c\0" }, + { 0xfd8a, 255, 0, "\x06\x45\x06\x2d\x06\x45\0" }, + { 0xfd8b, 255, 0, "\x06\x45\x06\x2d\x06\x4a\0" }, + { 0xfd8c, 255, 0, "\x06\x45\x06\x2c\x06\x2d\0" }, + { 0xfd8d, 255, 0, "\x06\x45\x06\x2c\x06\x45\0" }, + { 0xfd8e, 255, 0, "\x06\x45\x06\x2e\x06\x2c\0" }, + { 0xfd8f, 255, 0, "\x06\x45\x06\x2e\x06\x45\0" }, + { 0xfd92, 255, 0, "\x06\x45\x06\x2c\x06\x2e\0" }, + { 0xfd93, 255, 0, "\x06\x47\x06\x45\x06\x2c\0" }, + { 0xfd94, 255, 0, "\x06\x47\x06\x45\x06\x45\0" }, + { 0xfd95, 255, 0, "\x06\x46\x06\x2d\x06\x45\0" }, + { 0xfd96, 255, 0, "\x06\x46\x06\x2d\x06\x49\0" }, + { 0xfd97, 255, 0, "\x06\x46\x06\x2c\x06\x45\0" }, + { 0xfd98, 255, 0, "\x06\x46\x06\x2c\x06\x45\0" }, + { 0xfd99, 255, 0, "\x06\x46\x06\x2c\x06\x49\0" }, + { 0xfd9a, 255, 0, "\x06\x46\x06\x45\x06\x4a\0" }, + { 0xfd9b, 255, 0, "\x06\x46\x06\x45\x06\x49\0" }, + { 0xfd9c, 255, 0, "\x06\x4a\x06\x45\x06\x45\0" }, + { 0xfd9d, 255, 0, "\x06\x4a\x06\x45\x06\x45\0" }, + { 0xfd9e, 255, 0, "\x06\x28\x06\x2e\x06\x4a\0" }, + { 0xfd9f, 255, 0, "\x06\x2a\x06\x2c\x06\x4a\0" }, + { 0xfda0, 255, 0, "\x06\x2a\x06\x2c\x06\x49\0" }, + { 0xfda1, 255, 0, "\x06\x2a\x06\x2e\x06\x4a\0" }, + { 0xfda2, 255, 0, "\x06\x2a\x06\x2e\x06\x49\0" }, + { 0xfda3, 255, 0, "\x06\x2a\x06\x45\x06\x4a\0" }, + { 0xfda4, 255, 0, "\x06\x2a\x06\x45\x06\x49\0" }, + { 0xfda5, 255, 0, "\x06\x2c\x06\x45\x06\x4a\0" }, + { 0xfda6, 255, 0, "\x06\x2c\x06\x2d\x06\x49\0" }, + { 0xfda7, 255, 0, "\x06\x2c\x06\x45\x06\x49\0" }, + { 0xfda8, 255, 0, "\x06\x33\x06\x2e\x06\x49\0" }, + { 0xfda9, 255, 0, "\x06\x35\x06\x2d\x06\x4a\0" }, + { 0xfdaa, 255, 0, "\x06\x34\x06\x2d\x06\x4a\0" }, + { 0xfdab, 255, 0, "\x06\x36\x06\x2d\x06\x4a\0" }, + { 0xfdac, 255, 0, "\x06\x44\x06\x2c\x06\x4a\0" }, + { 0xfdad, 255, 0, "\x06\x44\x06\x45\x06\x4a\0" }, + { 0xfdae, 255, 0, "\x06\x4a\x06\x2d\x06\x4a\0" }, + { 0xfdaf, 255, 0, "\x06\x4a\x06\x2c\x06\x4a\0" }, + { 0xfdb0, 255, 0, "\x06\x4a\x06\x45\x06\x4a\0" }, + { 0xfdb1, 255, 0, "\x06\x45\x06\x45\x06\x4a\0" }, + { 0xfdb2, 255, 0, "\x06\x42\x06\x45\x06\x4a\0" }, + { 0xfdb3, 255, 0, "\x06\x46\x06\x2d\x06\x4a\0" }, + { 0xfdb4, 255, 0, "\x06\x42\x06\x45\x06\x2d\0" }, + { 0xfdb5, 255, 0, "\x06\x44\x06\x2d\x06\x45\0" }, + { 0xfdb6, 255, 0, "\x06\x39\x06\x45\x06\x4a\0" }, + { 0xfdb7, 255, 0, "\x06\x43\x06\x45\x06\x4a\0" }, + { 0xfdb8, 255, 0, "\x06\x46\x06\x2c\x06\x2d\0" }, + { 0xfdb9, 255, 0, "\x06\x45\x06\x2e\x06\x4a\0" }, + { 0xfdba, 255, 0, "\x06\x44\x06\x2c\x06\x45\0" }, + { 0xfdbb, 255, 0, "\x06\x43\x06\x45\x06\x45\0" }, + { 0xfdbc, 255, 0, "\x06\x44\x06\x2c\x06\x45\0" }, + { 0xfdbd, 255, 0, "\x06\x46\x06\x2c\x06\x2d\0" }, + { 0xfdbe, 255, 0, "\x06\x2c\x06\x2d\x06\x4a\0" }, + { 0xfdbf, 255, 0, "\x06\x2d\x06\x2c\x06\x4a\0" }, + { 0xfdc0, 255, 0, "\x06\x45\x06\x2c\x06\x4a\0" }, + { 0xfdc1, 255, 0, "\x06\x41\x06\x45\x06\x4a\0" }, + { 0xfdc2, 255, 0, "\x06\x28\x06\x2d\x06\x4a\0" }, + { 0xfdc3, 255, 0, "\x06\x43\x06\x45\x06\x45\0" }, + { 0xfdc4, 255, 0, "\x06\x39\x06\x2c\x06\x45\0" }, + { 0xfdc5, 255, 0, "\x06\x35\x06\x45\x06\x45\0" }, + { 0xfdc6, 255, 0, "\x06\x33\x06\x2e\x06\x4a\0" }, + { 0xfdc7, 255, 0, "\x06\x46\x06\x2c\x06\x4a\0" }, + { 0xfdf0, 255, 0, "\x06\x35\x06\x44\x06\xd2\0" }, + { 0xfdf1, 255, 0, "\x06\x42\x06\x44\x06\xd2\0" }, + { 0xfdf2, 255, 0, "\x06\x27\x06\x44\x06\x44\x06\x47\0" }, + { 0xfdf3, 255, 0, "\x06\x27\x06\x43\x06\x28\x06\x31\0" }, + { 0xfdf4, 255, 0, "\x06\x45\x06\x2d\x06\x45\x06\x2f\0" }, + { 0xfdf5, 255, 0, "\x06\x35\x06\x44\x06\x39\x06\x45\0" }, + { 0xfdf6, 255, 0, "\x06\x31\x06\x33\x06\x48\x06\x44\0" }, + { 0xfdf7, 255, 0, "\x06\x39\x06\x44\x06\x4a\x06\x47\0" }, + { 0xfdf8, 255, 0, "\x06\x48\x06\x33\x06\x44\x06\x45\0" }, + { 0xfdf9, 255, 0, "\x06\x35\x06\x44\x06\x49\0" }, + { 0xfdfa, 255, 0, "\x06\x35\x06\x44\x06\x49\x00\x20\x06\x27\x06\x44\x06\x44\x06\x47\x00\x20\x06\x39\x06\x44\x06\x4a\x06\x47\x00\x20\x06\x48\x06\x33\x06\x44\x06\x45\0" }, + { 0xfdfb, 255, 0, "\x06\x2c\x06\x44\x00\x20\x06\x2c\x06\x44\x06\x27\x06\x44\x06\x47\0" }, + { 0xfe30, 255, 0, "\x00\x2e\x00\x2e\0" }, + { 0xfe31, 255, 0, "\x20\x14\0" }, + { 0xfe32, 255, 0, "\x20\x13\0" }, + { 0xfe33, 255, 0, "\x00\x5f\0" }, + { 0xfe34, 255, 0, "\x00\x5f\0" }, + { 0xfe35, 255, 0, "\x00\x28\0" }, + { 0xfe36, 255, 0, "\x00\x29\0" }, + { 0xfe37, 255, 0, "\x00\x7b\0" }, + { 0xfe38, 255, 0, "\x00\x7d\0" }, + { 0xfe39, 255, 0, "\x30\x14\0" }, + { 0xfe3a, 255, 0, "\x30\x15\0" }, + { 0xfe3b, 255, 0, "\x30\x10\0" }, + { 0xfe3c, 255, 0, "\x30\x11\0" }, + { 0xfe3d, 255, 0, "\x30\x0a\0" }, + { 0xfe3e, 255, 0, "\x30\x0b\0" }, + { 0xfe3f, 255, 0, "\x30\x08\0" }, + { 0xfe40, 255, 0, "\x30\x09\0" }, + { 0xfe41, 255, 0, "\x30\x0c\0" }, + { 0xfe42, 255, 0, "\x30\x0d\0" }, + { 0xfe43, 255, 0, "\x30\x0e\0" }, + { 0xfe44, 255, 0, "\x30\x0f\0" }, + { 0xfe49, 255, 0, "\x00\x20\x03\x05\0" }, + { 0xfe4a, 255, 0, "\x00\x20\x03\x05\0" }, + { 0xfe4b, 255, 0, "\x00\x20\x03\x05\0" }, + { 0xfe4c, 255, 0, "\x00\x20\x03\x05\0" }, + { 0xfe4d, 255, 0, "\x00\x5f\0" }, + { 0xfe4e, 255, 0, "\x00\x5f\0" }, + { 0xfe4f, 255, 0, "\x00\x5f\0" }, + { 0xfe50, 255, 0, "\x00\x2c\0" }, + { 0xfe51, 255, 0, "\x30\x01\0" }, + { 0xfe52, 255, 0, "\x00\x2e\0" }, + { 0xfe54, 255, 0, "\x00\x3b\0" }, + { 0xfe55, 255, 0, "\x00\x3a\0" }, + { 0xfe56, 255, 0, "\x00\x3f\0" }, + { 0xfe57, 255, 0, "\x00\x21\0" }, + { 0xfe58, 255, 0, "\x20\x14\0" }, + { 0xfe59, 255, 0, "\x00\x28\0" }, + { 0xfe5a, 255, 0, "\x00\x29\0" }, + { 0xfe5b, 255, 0, "\x00\x7b\0" }, + { 0xfe5c, 255, 0, "\x00\x7d\0" }, + { 0xfe5d, 255, 0, "\x30\x14\0" }, + { 0xfe5e, 255, 0, "\x30\x15\0" }, + { 0xfe5f, 255, 0, "\x00\x23\0" }, + { 0xfe60, 255, 0, "\x00\x26\0" }, + { 0xfe61, 255, 0, "\x00\x2a\0" }, + { 0xfe62, 255, 0, "\x00\x2b\0" }, + { 0xfe63, 255, 0, "\x00\x2d\0" }, + { 0xfe64, 255, 0, "\x00\x3c\0" }, + { 0xfe65, 255, 0, "\x00\x3e\0" }, + { 0xfe66, 255, 0, "\x00\x3d\0" }, + { 0xfe68, 255, 0, "\x00\x5c\0" }, + { 0xfe69, 255, 0, "\x00\x24\0" }, + { 0xfe6a, 255, 0, "\x00\x25\0" }, + { 0xfe6b, 255, 0, "\x00\x40\0" }, + { 0xfe70, 255, 0, "\x00\x20\x06\x4b\0" }, + { 0xfe71, 255, 0, "\x06\x40\x06\x4b\0" }, + { 0xfe72, 255, 0, "\x00\x20\x06\x4c\0" }, + { 0xfe74, 255, 0, "\x00\x20\x06\x4d\0" }, + { 0xfe76, 255, 0, "\x00\x20\x06\x4e\0" }, + { 0xfe77, 255, 0, "\x06\x40\x06\x4e\0" }, + { 0xfe78, 255, 0, "\x00\x20\x06\x4f\0" }, + { 0xfe79, 255, 0, "\x06\x40\x06\x4f\0" }, + { 0xfe7a, 255, 0, "\x00\x20\x06\x50\0" }, + { 0xfe7b, 255, 0, "\x06\x40\x06\x50\0" }, + { 0xfe7c, 255, 0, "\x00\x20\x06\x51\0" }, + { 0xfe7d, 255, 0, "\x06\x40\x06\x51\0" }, + { 0xfe7e, 255, 0, "\x00\x20\x06\x52\0" }, + { 0xfe7f, 255, 0, "\x06\x40\x06\x52\0" }, + { 0xfe80, 255, 0, "\x06\x21\0" }, + { 0xfe81, 255, 0, "\x06\x27\x06\x53\0" }, + { 0xfe82, 255, 0, "\x06\x27\x06\x53\0" }, + { 0xfe83, 255, 0, "\x06\x27\x06\x54\0" }, + { 0xfe84, 255, 0, "\x06\x27\x06\x54\0" }, + { 0xfe85, 255, 0, "\x06\x48\x06\x54\0" }, + { 0xfe86, 255, 0, "\x06\x48\x06\x54\0" }, + { 0xfe87, 255, 0, "\x06\x27\x06\x55\0" }, + { 0xfe88, 255, 0, "\x06\x27\x06\x55\0" }, + { 0xfe89, 255, 0, "\x06\x4a\x06\x54\0" }, + { 0xfe8a, 255, 0, "\x06\x4a\x06\x54\0" }, + { 0xfe8b, 255, 0, "\x06\x4a\x06\x54\0" }, + { 0xfe8c, 255, 0, "\x06\x4a\x06\x54\0" }, + { 0xfe8d, 255, 0, "\x06\x27\0" }, + { 0xfe8e, 255, 0, "\x06\x27\0" }, + { 0xfe8f, 255, 0, "\x06\x28\0" }, + { 0xfe90, 255, 0, "\x06\x28\0" }, + { 0xfe91, 255, 0, "\x06\x28\0" }, + { 0xfe92, 255, 0, "\x06\x28\0" }, + { 0xfe93, 255, 0, "\x06\x29\0" }, + { 0xfe94, 255, 0, "\x06\x29\0" }, + { 0xfe95, 255, 0, "\x06\x2a\0" }, + { 0xfe96, 255, 0, "\x06\x2a\0" }, + { 0xfe97, 255, 0, "\x06\x2a\0" }, + { 0xfe98, 255, 0, "\x06\x2a\0" }, + { 0xfe99, 255, 0, "\x06\x2b\0" }, + { 0xfe9a, 255, 0, "\x06\x2b\0" }, + { 0xfe9b, 255, 0, "\x06\x2b\0" }, + { 0xfe9c, 255, 0, "\x06\x2b\0" }, + { 0xfe9d, 255, 0, "\x06\x2c\0" }, + { 0xfe9e, 255, 0, "\x06\x2c\0" }, + { 0xfe9f, 255, 0, "\x06\x2c\0" }, + { 0xfea0, 255, 0, "\x06\x2c\0" }, + { 0xfea1, 255, 0, "\x06\x2d\0" }, + { 0xfea2, 255, 0, "\x06\x2d\0" }, + { 0xfea3, 255, 0, "\x06\x2d\0" }, + { 0xfea4, 255, 0, "\x06\x2d\0" }, + { 0xfea5, 255, 0, "\x06\x2e\0" }, + { 0xfea6, 255, 0, "\x06\x2e\0" }, + { 0xfea7, 255, 0, "\x06\x2e\0" }, + { 0xfea8, 255, 0, "\x06\x2e\0" }, + { 0xfea9, 255, 0, "\x06\x2f\0" }, + { 0xfeaa, 255, 0, "\x06\x2f\0" }, + { 0xfeab, 255, 0, "\x06\x30\0" }, + { 0xfeac, 255, 0, "\x06\x30\0" }, + { 0xfead, 255, 0, "\x06\x31\0" }, + { 0xfeae, 255, 0, "\x06\x31\0" }, + { 0xfeaf, 255, 0, "\x06\x32\0" }, + { 0xfeb0, 255, 0, "\x06\x32\0" }, + { 0xfeb1, 255, 0, "\x06\x33\0" }, + { 0xfeb2, 255, 0, "\x06\x33\0" }, + { 0xfeb3, 255, 0, "\x06\x33\0" }, + { 0xfeb4, 255, 0, "\x06\x33\0" }, + { 0xfeb5, 255, 0, "\x06\x34\0" }, + { 0xfeb6, 255, 0, "\x06\x34\0" }, + { 0xfeb7, 255, 0, "\x06\x34\0" }, + { 0xfeb8, 255, 0, "\x06\x34\0" }, + { 0xfeb9, 255, 0, "\x06\x35\0" }, + { 0xfeba, 255, 0, "\x06\x35\0" }, + { 0xfebb, 255, 0, "\x06\x35\0" }, + { 0xfebc, 255, 0, "\x06\x35\0" }, + { 0xfebd, 255, 0, "\x06\x36\0" }, + { 0xfebe, 255, 0, "\x06\x36\0" }, + { 0xfebf, 255, 0, "\x06\x36\0" }, + { 0xfec0, 255, 0, "\x06\x36\0" }, + { 0xfec1, 255, 0, "\x06\x37\0" }, + { 0xfec2, 255, 0, "\x06\x37\0" }, + { 0xfec3, 255, 0, "\x06\x37\0" }, + { 0xfec4, 255, 0, "\x06\x37\0" }, + { 0xfec5, 255, 0, "\x06\x38\0" }, + { 0xfec6, 255, 0, "\x06\x38\0" }, + { 0xfec7, 255, 0, "\x06\x38\0" }, + { 0xfec8, 255, 0, "\x06\x38\0" }, + { 0xfec9, 255, 0, "\x06\x39\0" }, + { 0xfeca, 255, 0, "\x06\x39\0" }, + { 0xfecb, 255, 0, "\x06\x39\0" }, + { 0xfecc, 255, 0, "\x06\x39\0" }, + { 0xfecd, 255, 0, "\x06\x3a\0" }, + { 0xfece, 255, 0, "\x06\x3a\0" }, + { 0xfecf, 255, 0, "\x06\x3a\0" }, + { 0xfed0, 255, 0, "\x06\x3a\0" }, + { 0xfed1, 255, 0, "\x06\x41\0" }, + { 0xfed2, 255, 0, "\x06\x41\0" }, + { 0xfed3, 255, 0, "\x06\x41\0" }, + { 0xfed4, 255, 0, "\x06\x41\0" }, + { 0xfed5, 255, 0, "\x06\x42\0" }, + { 0xfed6, 255, 0, "\x06\x42\0" }, + { 0xfed7, 255, 0, "\x06\x42\0" }, + { 0xfed8, 255, 0, "\x06\x42\0" }, + { 0xfed9, 255, 0, "\x06\x43\0" }, + { 0xfeda, 255, 0, "\x06\x43\0" }, + { 0xfedb, 255, 0, "\x06\x43\0" }, + { 0xfedc, 255, 0, "\x06\x43\0" }, + { 0xfedd, 255, 0, "\x06\x44\0" }, + { 0xfede, 255, 0, "\x06\x44\0" }, + { 0xfedf, 255, 0, "\x06\x44\0" }, + { 0xfee0, 255, 0, "\x06\x44\0" }, + { 0xfee1, 255, 0, "\x06\x45\0" }, + { 0xfee2, 255, 0, "\x06\x45\0" }, + { 0xfee3, 255, 0, "\x06\x45\0" }, + { 0xfee4, 255, 0, "\x06\x45\0" }, + { 0xfee5, 255, 0, "\x06\x46\0" }, + { 0xfee6, 255, 0, "\x06\x46\0" }, + { 0xfee7, 255, 0, "\x06\x46\0" }, + { 0xfee8, 255, 0, "\x06\x46\0" }, + { 0xfee9, 255, 0, "\x06\x47\0" }, + { 0xfeea, 255, 0, "\x06\x47\0" }, + { 0xfeeb, 255, 0, "\x06\x47\0" }, + { 0xfeec, 255, 0, "\x06\x47\0" }, + { 0xfeed, 255, 0, "\x06\x48\0" }, + { 0xfeee, 255, 0, "\x06\x48\0" }, + { 0xfeef, 255, 0, "\x06\x49\0" }, + { 0xfef0, 255, 0, "\x06\x49\0" }, + { 0xfef1, 255, 0, "\x06\x4a\0" }, + { 0xfef2, 255, 0, "\x06\x4a\0" }, + { 0xfef3, 255, 0, "\x06\x4a\0" }, + { 0xfef4, 255, 0, "\x06\x4a\0" }, + { 0xfef5, 255, 0, "\x06\x44\x06\x27\x06\x53\0" }, + { 0xfef6, 255, 0, "\x06\x44\x06\x27\x06\x53\0" }, + { 0xfef7, 255, 0, "\x06\x44\x06\x27\x06\x54\0" }, + { 0xfef8, 255, 0, "\x06\x44\x06\x27\x06\x54\0" }, + { 0xfef9, 255, 0, "\x06\x44\x06\x27\x06\x55\0" }, + { 0xfefa, 255, 0, "\x06\x44\x06\x27\x06\x55\0" }, + { 0xfefb, 255, 0, "\x06\x44\x06\x27\0" }, + { 0xfefc, 255, 0, "\x06\x44\x06\x27\0" }, + { 0xff01, 255, 0, "\x00\x21\0" }, + { 0xff02, 255, 0, "\x00\x22\0" }, + { 0xff03, 255, 0, "\x00\x23\0" }, + { 0xff04, 255, 0, "\x00\x24\0" }, + { 0xff05, 255, 0, "\x00\x25\0" }, + { 0xff06, 255, 0, "\x00\x26\0" }, + { 0xff07, 255, 0, "\x00\x27\0" }, + { 0xff08, 255, 0, "\x00\x28\0" }, + { 0xff09, 255, 0, "\x00\x29\0" }, + { 0xff0a, 255, 0, "\x00\x2a\0" }, + { 0xff0b, 255, 0, "\x00\x2b\0" }, + { 0xff0c, 255, 0, "\x00\x2c\0" }, + { 0xff0d, 255, 0, "\x00\x2d\0" }, + { 0xff0e, 255, 0, "\x00\x2e\0" }, + { 0xff0f, 255, 0, "\x00\x2f\0" }, + { 0xff10, 255, 0, "\x00\x30\0" }, + { 0xff11, 255, 0, "\x00\x31\0" }, + { 0xff12, 255, 0, "\x00\x32\0" }, + { 0xff13, 255, 0, "\x00\x33\0" }, + { 0xff14, 255, 0, "\x00\x34\0" }, + { 0xff15, 255, 0, "\x00\x35\0" }, + { 0xff16, 255, 0, "\x00\x36\0" }, + { 0xff17, 255, 0, "\x00\x37\0" }, + { 0xff18, 255, 0, "\x00\x38\0" }, + { 0xff19, 255, 0, "\x00\x39\0" }, + { 0xff1a, 255, 0, "\x00\x3a\0" }, + { 0xff1b, 255, 0, "\x00\x3b\0" }, + { 0xff1c, 255, 0, "\x00\x3c\0" }, + { 0xff1d, 255, 0, "\x00\x3d\0" }, + { 0xff1e, 255, 0, "\x00\x3e\0" }, + { 0xff1f, 255, 0, "\x00\x3f\0" }, + { 0xff20, 255, 0, "\x00\x40\0" }, + { 0xff21, 255, 0, "\x00\x41\0" }, + { 0xff22, 255, 0, "\x00\x42\0" }, + { 0xff23, 255, 0, "\x00\x43\0" }, + { 0xff24, 255, 0, "\x00\x44\0" }, + { 0xff25, 255, 0, "\x00\x45\0" }, + { 0xff26, 255, 0, "\x00\x46\0" }, + { 0xff27, 255, 0, "\x00\x47\0" }, + { 0xff28, 255, 0, "\x00\x48\0" }, + { 0xff29, 255, 0, "\x00\x49\0" }, + { 0xff2a, 255, 0, "\x00\x4a\0" }, + { 0xff2b, 255, 0, "\x00\x4b\0" }, + { 0xff2c, 255, 0, "\x00\x4c\0" }, + { 0xff2d, 255, 0, "\x00\x4d\0" }, + { 0xff2e, 255, 0, "\x00\x4e\0" }, + { 0xff2f, 255, 0, "\x00\x4f\0" }, + { 0xff30, 255, 0, "\x00\x50\0" }, + { 0xff31, 255, 0, "\x00\x51\0" }, + { 0xff32, 255, 0, "\x00\x52\0" }, + { 0xff33, 255, 0, "\x00\x53\0" }, + { 0xff34, 255, 0, "\x00\x54\0" }, + { 0xff35, 255, 0, "\x00\x55\0" }, + { 0xff36, 255, 0, "\x00\x56\0" }, + { 0xff37, 255, 0, "\x00\x57\0" }, + { 0xff38, 255, 0, "\x00\x58\0" }, + { 0xff39, 255, 0, "\x00\x59\0" }, + { 0xff3a, 255, 0, "\x00\x5a\0" }, + { 0xff3b, 255, 0, "\x00\x5b\0" }, + { 0xff3c, 255, 0, "\x00\x5c\0" }, + { 0xff3d, 255, 0, "\x00\x5d\0" }, + { 0xff3e, 255, 0, "\x00\x5e\0" }, + { 0xff3f, 255, 0, "\x00\x5f\0" }, + { 0xff40, 255, 0, "\x00\x60\0" }, + { 0xff41, 255, 0, "\x00\x61\0" }, + { 0xff42, 255, 0, "\x00\x62\0" }, + { 0xff43, 255, 0, "\x00\x63\0" }, + { 0xff44, 255, 0, "\x00\x64\0" }, + { 0xff45, 255, 0, "\x00\x65\0" }, + { 0xff46, 255, 0, "\x00\x66\0" }, + { 0xff47, 255, 0, "\x00\x67\0" }, + { 0xff48, 255, 0, "\x00\x68\0" }, + { 0xff49, 255, 0, "\x00\x69\0" }, + { 0xff4a, 255, 0, "\x00\x6a\0" }, + { 0xff4b, 255, 0, "\x00\x6b\0" }, + { 0xff4c, 255, 0, "\x00\x6c\0" }, + { 0xff4d, 255, 0, "\x00\x6d\0" }, + { 0xff4e, 255, 0, "\x00\x6e\0" }, + { 0xff4f, 255, 0, "\x00\x6f\0" }, + { 0xff50, 255, 0, "\x00\x70\0" }, + { 0xff51, 255, 0, "\x00\x71\0" }, + { 0xff52, 255, 0, "\x00\x72\0" }, + { 0xff53, 255, 0, "\x00\x73\0" }, + { 0xff54, 255, 0, "\x00\x74\0" }, + { 0xff55, 255, 0, "\x00\x75\0" }, + { 0xff56, 255, 0, "\x00\x76\0" }, + { 0xff57, 255, 0, "\x00\x77\0" }, + { 0xff58, 255, 0, "\x00\x78\0" }, + { 0xff59, 255, 0, "\x00\x79\0" }, + { 0xff5a, 255, 0, "\x00\x7a\0" }, + { 0xff5b, 255, 0, "\x00\x7b\0" }, + { 0xff5c, 255, 0, "\x00\x7c\0" }, + { 0xff5d, 255, 0, "\x00\x7d\0" }, + { 0xff5e, 255, 0, "\x00\x7e\0" }, + { 0xff61, 255, 0, "\x30\x02\0" }, + { 0xff62, 255, 0, "\x30\x0c\0" }, + { 0xff63, 255, 0, "\x30\x0d\0" }, + { 0xff64, 255, 0, "\x30\x01\0" }, + { 0xff65, 255, 0, "\x30\xfb\0" }, + { 0xff66, 255, 0, "\x30\xf2\0" }, + { 0xff67, 255, 0, "\x30\xa1\0" }, + { 0xff68, 255, 0, "\x30\xa3\0" }, + { 0xff69, 255, 0, "\x30\xa5\0" }, + { 0xff6a, 255, 0, "\x30\xa7\0" }, + { 0xff6b, 255, 0, "\x30\xa9\0" }, + { 0xff6c, 255, 0, "\x30\xe3\0" }, + { 0xff6d, 255, 0, "\x30\xe5\0" }, + { 0xff6e, 255, 0, "\x30\xe7\0" }, + { 0xff6f, 255, 0, "\x30\xc3\0" }, + { 0xff70, 255, 0, "\x30\xfc\0" }, + { 0xff71, 255, 0, "\x30\xa2\0" }, + { 0xff72, 255, 0, "\x30\xa4\0" }, + { 0xff73, 255, 0, "\x30\xa6\0" }, + { 0xff74, 255, 0, "\x30\xa8\0" }, + { 0xff75, 255, 0, "\x30\xaa\0" }, + { 0xff76, 255, 0, "\x30\xab\0" }, + { 0xff77, 255, 0, "\x30\xad\0" }, + { 0xff78, 255, 0, "\x30\xaf\0" }, + { 0xff79, 255, 0, "\x30\xb1\0" }, + { 0xff7a, 255, 0, "\x30\xb3\0" }, + { 0xff7b, 255, 0, "\x30\xb5\0" }, + { 0xff7c, 255, 0, "\x30\xb7\0" }, + { 0xff7d, 255, 0, "\x30\xb9\0" }, + { 0xff7e, 255, 0, "\x30\xbb\0" }, + { 0xff7f, 255, 0, "\x30\xbd\0" }, + { 0xff80, 255, 0, "\x30\xbf\0" }, + { 0xff81, 255, 0, "\x30\xc1\0" }, + { 0xff82, 255, 0, "\x30\xc4\0" }, + { 0xff83, 255, 0, "\x30\xc6\0" }, + { 0xff84, 255, 0, "\x30\xc8\0" }, + { 0xff85, 255, 0, "\x30\xca\0" }, + { 0xff86, 255, 0, "\x30\xcb\0" }, + { 0xff87, 255, 0, "\x30\xcc\0" }, + { 0xff88, 255, 0, "\x30\xcd\0" }, + { 0xff89, 255, 0, "\x30\xce\0" }, + { 0xff8a, 255, 0, "\x30\xcf\0" }, + { 0xff8b, 255, 0, "\x30\xd2\0" }, + { 0xff8c, 255, 0, "\x30\xd5\0" }, + { 0xff8d, 255, 0, "\x30\xd8\0" }, + { 0xff8e, 255, 0, "\x30\xdb\0" }, + { 0xff8f, 255, 0, "\x30\xde\0" }, + { 0xff90, 255, 0, "\x30\xdf\0" }, + { 0xff91, 255, 0, "\x30\xe0\0" }, + { 0xff92, 255, 0, "\x30\xe1\0" }, + { 0xff93, 255, 0, "\x30\xe2\0" }, + { 0xff94, 255, 0, "\x30\xe4\0" }, + { 0xff95, 255, 0, "\x30\xe6\0" }, + { 0xff96, 255, 0, "\x30\xe8\0" }, + { 0xff97, 255, 0, "\x30\xe9\0" }, + { 0xff98, 255, 0, "\x30\xea\0" }, + { 0xff99, 255, 0, "\x30\xeb\0" }, + { 0xff9a, 255, 0, "\x30\xec\0" }, + { 0xff9b, 255, 0, "\x30\xed\0" }, + { 0xff9c, 255, 0, "\x30\xef\0" }, + { 0xff9d, 255, 0, "\x30\xf3\0" }, + { 0xff9e, 255, 0, "\x30\x99\0" }, + { 0xff9f, 255, 0, "\x30\x9a\0" }, + { 0xffa0, 255, 0, "\x11\x60\0" }, + { 0xffa1, 255, 0, "\x11\x00\0" }, + { 0xffa2, 255, 0, "\x11\x01\0" }, + { 0xffa3, 255, 0, "\x11\xaa\0" }, + { 0xffa4, 255, 0, "\x11\x02\0" }, + { 0xffa5, 255, 0, "\x11\xac\0" }, + { 0xffa6, 255, 0, "\x11\xad\0" }, + { 0xffa7, 255, 0, "\x11\x03\0" }, + { 0xffa8, 255, 0, "\x11\x04\0" }, + { 0xffa9, 255, 0, "\x11\x05\0" }, + { 0xffaa, 255, 0, "\x11\xb0\0" }, + { 0xffab, 255, 0, "\x11\xb1\0" }, + { 0xffac, 255, 0, "\x11\xb2\0" }, + { 0xffad, 255, 0, "\x11\xb3\0" }, + { 0xffae, 255, 0, "\x11\xb4\0" }, + { 0xffaf, 255, 0, "\x11\xb5\0" }, + { 0xffb0, 255, 0, "\x11\x1a\0" }, + { 0xffb1, 255, 0, "\x11\x06\0" }, + { 0xffb2, 255, 0, "\x11\x07\0" }, + { 0xffb3, 255, 0, "\x11\x08\0" }, + { 0xffb4, 255, 0, "\x11\x21\0" }, + { 0xffb5, 255, 0, "\x11\x09\0" }, + { 0xffb6, 255, 0, "\x11\x0a\0" }, + { 0xffb7, 255, 0, "\x11\x0b\0" }, + { 0xffb8, 255, 0, "\x11\x0c\0" }, + { 0xffb9, 255, 0, "\x11\x0d\0" }, + { 0xffba, 255, 0, "\x11\x0e\0" }, + { 0xffbb, 255, 0, "\x11\x0f\0" }, + { 0xffbc, 255, 0, "\x11\x10\0" }, + { 0xffbd, 255, 0, "\x11\x11\0" }, + { 0xffbe, 255, 0, "\x11\x12\0" }, + { 0xffc2, 255, 0, "\x11\x61\0" }, + { 0xffc3, 255, 0, "\x11\x62\0" }, + { 0xffc4, 255, 0, "\x11\x63\0" }, + { 0xffc5, 255, 0, "\x11\x64\0" }, + { 0xffc6, 255, 0, "\x11\x65\0" }, + { 0xffc7, 255, 0, "\x11\x66\0" }, + { 0xffca, 255, 0, "\x11\x67\0" }, + { 0xffcb, 255, 0, "\x11\x68\0" }, + { 0xffcc, 255, 0, "\x11\x69\0" }, + { 0xffcd, 255, 0, "\x11\x6a\0" }, + { 0xffce, 255, 0, "\x11\x6b\0" }, + { 0xffcf, 255, 0, "\x11\x6c\0" }, + { 0xffd2, 255, 0, "\x11\x6d\0" }, + { 0xffd3, 255, 0, "\x11\x6e\0" }, + { 0xffd4, 255, 0, "\x11\x6f\0" }, + { 0xffd5, 255, 0, "\x11\x70\0" }, + { 0xffd6, 255, 0, "\x11\x71\0" }, + { 0xffd7, 255, 0, "\x11\x72\0" }, + { 0xffda, 255, 0, "\x11\x73\0" }, + { 0xffdb, 255, 0, "\x11\x74\0" }, + { 0xffdc, 255, 0, "\x11\x75\0" }, + { 0xffe0, 255, 0, "\x00\xa2\0" }, + { 0xffe1, 255, 0, "\x00\xa3\0" }, + { 0xffe2, 255, 0, "\x00\xac\0" }, + { 0xffe3, 255, 0, "\x00\x20\x03\x04\0" }, + { 0xffe4, 255, 0, "\x00\xa6\0" }, + { 0xffe5, 255, 0, "\x00\xa5\0" }, + { 0xffe6, 255, 0, "\x20\xa9\0" }, + { 0xffe8, 255, 0, "\x25\x02\0" }, + { 0xffe9, 255, 0, "\x21\x90\0" }, + { 0xffea, 255, 0, "\x21\x91\0" }, + { 0xffeb, 255, 0, "\x21\x92\0" }, + { 0xffec, 255, 0, "\x21\x93\0" }, + { 0xffed, 255, 0, "\x25\xa0\0" }, + { 0xffee, 255, 0, "\x25\xcb\0" } }; #endif /* DECOMP_H */ diff --git a/graf2d/win32gdk/gdk/src/glib/guniprop.c b/graf2d/win32gdk/gdk/src/glib/guniprop.c new file mode 100644 index 0000000000000..fc2fe84d9a9cd --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/guniprop.c @@ -0,0 +1,912 @@ +/* guniprop.c - Unicode character properties. + * + * Copyright (C) 1999 Tom Tromey + * Copyright (C) 2000 Red Hat, Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include "glib.h" +#include "gunichartables.h" + +#include <config.h> + +#include <stddef.h> +#include <string.h> +#include <locale.h> + +#define ATTTABLE(Page, Char) \ + ((attr_table[Page] == 0) ? 0 : (attr_table[Page][Char])) + +/* We cheat a bit and cast type values to (char *). We detect these + using the &0xff trick. */ +#define TTYPE(Page, Char) \ + (((GPOINTER_TO_INT(type_table[Page]) & 0xff) == GPOINTER_TO_INT(type_table[Page])) \ + ? GPOINTER_TO_INT(type_table[Page]) \ + : (type_table[Page][Char])) + +#define TYPE(Char) (((Char) > (G_UNICODE_LAST_CHAR)) ? G_UNICODE_UNASSIGNED : TTYPE ((Char) >> 8, (Char) & 0xff)) + +#define ISDIGIT(Type) ((Type) == G_UNICODE_DECIMAL_NUMBER \ + || (Type) == G_UNICODE_LETTER_NUMBER \ + || (Type) == G_UNICODE_OTHER_NUMBER) + +#define ISALPHA(Type) ((Type) == G_UNICODE_LOWERCASE_LETTER \ + || (Type) == G_UNICODE_UPPERCASE_LETTER \ + || (Type) == G_UNICODE_TITLECASE_LETTER \ + || (Type) == G_UNICODE_MODIFIER_LETTER \ + || (Type) == G_UNICODE_OTHER_LETTER) + +#define ISMARK(Type) ((Type) == G_UNICODE_NON_SPACING_MARK || \ + (Type) == G_UNICODE_COMBINING_MARK || \ + (Type) == G_UNICODE_ENCLOSING_MARK) + + +/** + * g_unichar_isalnum: + * @c: a Unicode character + * + * Determines whether a character is alphanumeric. + * Given some UTF-8 text, obtain a character value + * with g_utf8_get_char(). + * + * Return value: %TRUE if @c is an alphanumeric character + **/ +gboolean +g_unichar_isalnum (gunichar c) +{ + int t = TYPE (c); + return ISDIGIT (t) || ISALPHA (t); +} + +/** + * g_unichar_isalpha: + * @c: a Unicode character + * + * Determines whether a character is alphabetic (i.e. a letter). + * Given some UTF-8 text, obtain a character value with + * g_utf8_get_char(). + * + * Return value: %TRUE if @c is an alphabetic character + **/ +gboolean +g_unichar_isalpha (gunichar c) +{ + int t = TYPE (c); + return ISALPHA (t); +} + + +/** + * g_unichar_iscntrl: + * @c: a Unicode character + * + * Determines whether a character is a control character. + * Given some UTF-8 text, obtain a character value with + * g_utf8_get_char(). + * + * Return value: %TRUE if @c is a control character + **/ +gboolean +g_unichar_iscntrl (gunichar c) +{ + return TYPE (c) == G_UNICODE_CONTROL; +} + +/** + * g_unichar_isdigit: + * @c: a Unicode character + * + * Determines whether a character is numeric (i.e. a digit). This + * covers ASCII 0-9 and also digits in other languages/scripts. Given + * some UTF-8 text, obtain a character value with g_utf8_get_char(). + * + * Return value: %TRUE if @c is a digit + **/ +gboolean +g_unichar_isdigit (gunichar c) +{ + return TYPE (c) == G_UNICODE_DECIMAL_NUMBER; +} + + +/** + * g_unichar_isgraph: + * @c: a Unicode character + * + * Determines whether a character is printable and not a space + * (returns %FALSE for control characters, format characters, and + * spaces). g_unichar_isprint() is similar, but returns %TRUE for + * spaces. Given some UTF-8 text, obtain a character value with + * g_utf8_get_char(). + * + * Return value: %TRUE if @c is printable unless it's a space + **/ +gboolean +g_unichar_isgraph (gunichar c) +{ + int t = TYPE (c); + return (t != G_UNICODE_CONTROL + && t != G_UNICODE_FORMAT + && t != G_UNICODE_UNASSIGNED + && t != G_UNICODE_PRIVATE_USE + && t != G_UNICODE_SURROGATE + && t != G_UNICODE_SPACE_SEPARATOR); +} + +/** + * g_unichar_islower: + * @c: a Unicode character + * + * Determines whether a character is a lowercase letter. + * Given some UTF-8 text, obtain a character value with + * g_utf8_get_char(). + * + * Return value: %TRUE if @c is a lowercase letter + **/ +gboolean +g_unichar_islower (gunichar c) +{ + return TYPE (c) == G_UNICODE_LOWERCASE_LETTER; +} + + +/** + * g_unichar_isprint: + * @c: a Unicode character + * + * Determines whether a character is printable. + * Unlike g_unichar_isgraph(), returns %TRUE for spaces. + * Given some UTF-8 text, obtain a character value with + * g_utf8_get_char(). + * + * Return value: %TRUE if @c is printable + **/ +gboolean +g_unichar_isprint (gunichar c) +{ + int t = TYPE (c); + return (t != G_UNICODE_CONTROL + && t != G_UNICODE_FORMAT + && t != G_UNICODE_UNASSIGNED + && t != G_UNICODE_PRIVATE_USE + && t != G_UNICODE_SURROGATE); +} + +/** + * g_unichar_ispunct: + * @c: a Unicode character + * + * Determines whether a character is punctuation or a symbol. + * Given some UTF-8 text, obtain a character value with + * g_utf8_get_char(). + * + * Return value: %TRUE if @c is a punctuation or symbol character + **/ +gboolean +g_unichar_ispunct (gunichar c) +{ + int t = TYPE (c); + return (t == G_UNICODE_CONNECT_PUNCTUATION || t == G_UNICODE_DASH_PUNCTUATION + || t == G_UNICODE_CLOSE_PUNCTUATION || t == G_UNICODE_FINAL_PUNCTUATION + || t == G_UNICODE_INITIAL_PUNCTUATION || t == G_UNICODE_OTHER_PUNCTUATION + || t == G_UNICODE_OPEN_PUNCTUATION || t == G_UNICODE_CURRENCY_SYMBOL + || t == G_UNICODE_MODIFIER_SYMBOL || t == G_UNICODE_MATH_SYMBOL + || t == G_UNICODE_OTHER_SYMBOL); +} + +/** + * g_unichar_isspace: + * @c: a Unicode character + * + * Determines whether a character is a space, tab, or line separator + * (newline, carriage return, etc.). Given some UTF-8 text, obtain a + * character value with g_utf8_get_char(). + * + * (Note: don't use this to do word breaking; you have to use + * Pango or equivalent to get word breaking right, the algorithm + * is fairly complex.) + * + * Return value: %TRUE if @c is a punctuation character + **/ +gboolean +g_unichar_isspace (gunichar c) +{ + switch (c) + { + /* special-case these since Unicode thinks they are not spaces */ + case '\t': + case '\n': + case '\r': + case '\f': + return TRUE; + break; + + default: + { + int t = TYPE (c); + return (t == G_UNICODE_SPACE_SEPARATOR || t == G_UNICODE_LINE_SEPARATOR + || t == G_UNICODE_PARAGRAPH_SEPARATOR); + } + break; + } +} + +/** + * g_unichar_isupper: + * @c: a Unicode character + * + * Determines if a character is uppercase. + * + * Return value: %TRUE if @c is an uppercase character + **/ +gboolean +g_unichar_isupper (gunichar c) +{ + return TYPE (c) == G_UNICODE_UPPERCASE_LETTER; +} + +/** + * g_unichar_istitle: + * @c: a Unicode character + * + * Determines if a character is titlecase. Some characters in + * Unicode which are composites, such as the DZ digraph + * have three case variants instead of just two. The titlecase + * form is used at the beginning of a word where only the + * first letter is capitalized. The titlecase form of the DZ + * digraph is U+01F2 LATIN CAPITAL LETTTER D WITH SMALL LETTER Z. + * + * Return value: %TRUE if the character is titlecase + **/ +gboolean +g_unichar_istitle (gunichar c) +{ + unsigned int i; + for (i = 0; i < G_N_ELEMENTS (title_table); ++i) + if (title_table[i][0] == c) + return 1; + return 0; +} + +/** + * g_unichar_isxdigit: + * @c: a Unicode character. + * + * Determines if a character is a hexidecimal digit. + * + * Return value: %TRUE if the character is a hexadecimal digit + **/ +gboolean +g_unichar_isxdigit (gunichar c) +{ + int t = TYPE (c); + return ((c >= 'a' && c <= 'f') + || (c >= 'A' && c <= 'F') + || ISDIGIT (t)); +} + +/** + * g_unichar_isdefined: + * @c: a Unicode character + * + * Determines if a given character is assigned in the Unicode + * standard. + * + * Return value: %TRUE if the character has an assigned value + **/ +gboolean +g_unichar_isdefined (gunichar c) +{ + int t = TYPE (c); + return t != G_UNICODE_UNASSIGNED; +} + +/** + * g_unichar_iswide: + * @c: a Unicode character + * + * Determines if a character is typically rendered in a double-width + * cell. + * + * Return value: %TRUE if the character is wide + **/ +/* This function stolen from Markus Kuhn <Markus.Kuhn@cl.cam.ac.uk>. */ +gboolean +g_unichar_iswide (gunichar c) +{ + if (c < 0x1100) + return 0; + + return ((c >= 0x1100 && c <= 0x115f) /* Hangul Jamo */ + || (c >= 0x2e80 && c <= 0xa4cf && (c & ~0x0011) != 0x300a && + c != 0x303f) /* CJK ... Yi */ + || (c >= 0xac00 && c <= 0xd7a3) /* Hangul Syllables */ + || (c >= 0xf900 && c <= 0xfaff) /* CJK Compatibility Ideographs */ + || (c >= 0xfe30 && c <= 0xfe6f) /* CJK Compatibility Forms */ + || (c >= 0xff00 && c <= 0xff5f) /* Fullwidth Forms */ + || (c >= 0xffe0 && c <= 0xffe6)); +} + +/** + * g_unichar_toupper: + * @c: a Unicode character + * + * Converts a character to uppercase. + * + * Return value: the result of converting @c to uppercase. + * If @c is not an lowercase or titlecase character, + * @c is returned unchanged. + **/ +gunichar +g_unichar_toupper (gunichar c) +{ + int t = TYPE (c); + if (t == G_UNICODE_LOWERCASE_LETTER) + { + gunichar val = ATTTABLE (c >> 8, c & 0xff); + if (val >= 0xd800 && val < 0xdc00) + { + guchar *p = special_case_table[val - 0xd800]; + return p[0] * 256 + p[1]; + } + else + return val; + } + else if (t == G_UNICODE_TITLECASE_LETTER) + { + unsigned int i; + for (i = 0; i < G_N_ELEMENTS (title_table); ++i) + { + if (title_table[i][0] == c) + return title_table[i][1]; + } + } + return c; +} + +/** + * g_unichar_tolower: + * @c: a Unicode character. + * + * Converts a character to lower case. + * + * Return value: the result of converting @c to lower case. + * If @c is not an upperlower or titlecase character, + * @c is returned unchanged. + **/ +gunichar +g_unichar_tolower (gunichar c) +{ + int t = TYPE (c); + if (t == G_UNICODE_UPPERCASE_LETTER) + { + gunichar val = ATTTABLE (c >> 8, c & 0xff); + if (val >= 0xd800 && val < 0xdc00) + { + guchar *p = special_case_table[val - 0xd800]; + return p[0] * 256 + p[1]; + } + else + return val; + } + else if (t == G_UNICODE_TITLECASE_LETTER) + { + unsigned int i; + for (i = 0; i < G_N_ELEMENTS (title_table); ++i) + { + if (title_table[i][0] == c) + return title_table[i][2]; + } + } + return c; +} + +/** + * g_unichar_totitle: + * @c: a Unicode character + * + * Converts a character to the titlecase. + * + * Return value: the result of converting @c to titlecase. + * If @c is not an uppercase or lowercase character, + * @c is returned unchanged. + **/ +gunichar +g_unichar_totitle (gunichar c) +{ + unsigned int i; + for (i = 0; i < G_N_ELEMENTS (title_table); ++i) + { + if (title_table[i][0] == c || title_table[i][1] == c + || title_table[i][2] == c) + return title_table[i][0]; + } + return (TYPE (c) == G_UNICODE_LOWERCASE_LETTER + ? ATTTABLE (c >> 8, c & 0xff) + : c); +} + +/** + * g_unichar_digit_value: + * @c: a Unicode character + * + * Determines the numeric value of a character as a decimal + * digit. + * + * Return value: If @c is a decimal digit (according to + * g_unichar_isdigit()), its numeric value. Otherwise, -1. + **/ +int +g_unichar_digit_value (gunichar c) +{ + if (TYPE (c) == G_UNICODE_DECIMAL_NUMBER) + return ATTTABLE (c >> 8, c & 0xff); + return -1; +} + +/** + * g_unichar_xdigit_value: + * @c: a Unicode character + * + * Determines the numeric value of a character as a hexidecimal + * digit. + * + * Return value: If @c is a hex digit (according to + * g_unichar_isxdigit()), its numeric value. Otherwise, -1. + **/ +int +g_unichar_xdigit_value (gunichar c) +{ + if (c >= 'A' && c <= 'F') + return c - 'A' + 10; + if (c >= 'a' && c <= 'f') + return c - 'a' + 10; + if (TYPE (c) == G_UNICODE_DECIMAL_NUMBER) + return ATTTABLE (c >> 8, c & 0xff); + return -1; +} + +/** + * g_unichar_type: + * @c: a Unicode character + * + * Classifies a Unicode character by type. + * + * Return value: the type of the character. + **/ +GUnicodeType +g_unichar_type (gunichar c) +{ + return TYPE (c); +} + +/* + * Case mapping functions + */ + +typedef enum { + LOCALE_NORMAL, + LOCALE_TURKIC, + LOCALE_LITHUANIAN +} LocaleType; + +static LocaleType +get_locale_type (void) +{ + const char *locale = setlocale (LC_CTYPE, NULL); + + switch (locale[0]) + { + case 'a': + if (locale[1] == 'z') + return LOCALE_TURKIC; + break; + case 'l': + if (locale[1] == 't') + return LOCALE_LITHUANIAN; + break; + case 't': + if (locale[1] == 'r') + return LOCALE_TURKIC; + break; + } + + return LOCALE_NORMAL; +} + +static int +output_marks (const char **p_inout, + char *out_buffer, + int len, + gboolean remove_dot) +{ + const char *p = *p_inout; + + while (*p) + { + gunichar c = g_utf8_get_char (p); + int t = TYPE(c); + + if (ISMARK(t)) + { + if (!remove_dot || c != 0x307 /* COMBINING DOT ABOVE */) + len += g_unichar_to_utf8 (c, out_buffer ? out_buffer + len : NULL); + p = g_utf8_next_char (p); + } + else + break; + } + + *p_inout = p; + return len; +} + +static gsize +output_special_case (gchar *out_buffer, + gsize len, + int index, + int type, + int which) +{ + guchar *p = special_case_table[index]; + + if (type != G_UNICODE_TITLECASE_LETTER) + p += 2; /* +2 to skip over "best single match" */ + + if (which == 1) + { + while (p[0] && p[1]) + p += 2; + p += 2; + } + + while (TRUE) + { + gunichar ch = p[0] * 256 + p[1]; + if (!ch) + break; + + len += g_unichar_to_utf8 (ch, out_buffer ? out_buffer + len : NULL); + p += 2; + } + + return len; +} + +static gsize +real_toupper (const gchar *str, + gssize max_len, + gchar *out_buffer, + LocaleType locale_type) +{ + const gchar *p = str; + const char *last = NULL; + gsize len = 0; + gboolean last_was_i = FALSE; + + while ((max_len < 0 || p < str + max_len) && *p) + { + gunichar c = g_utf8_get_char (p); + int t = TYPE (c); + gunichar val; + + last = p; + p = g_utf8_next_char (p); + + if (locale_type == LOCALE_LITHUANIAN) + { + if (c == 'i') + last_was_i = TRUE; + else + { + if (last_was_i) + { + /* Nasty, need to remove any dot above. Though + * I think only E WITH DOT ABOVE occurs in practice + * which could simplify this considerably. + */ + gsize decomp_len, i; + gunichar *decomp; + + decomp = g_unicode_canonical_decomposition (c, &decomp_len); + for (i=0; i < decomp_len; i++) + { + if (decomp[i] != 0x307 /* COMBINING DOT ABOVE */) + len += g_unichar_to_utf8 (g_unichar_toupper (decomp[i]), out_buffer ? out_buffer + len : NULL); + } + g_free (decomp); + + len = output_marks (&p, out_buffer, len, TRUE); + + continue; + } + + if (!ISMARK(t)) + last_was_i = FALSE; + } + } + + if (locale_type == LOCALE_TURKIC && c == 'i') + { + /* i => LATIN CAPITAL LETTER I WITH DOT ABOVE */ + len += g_unichar_to_utf8 (0x130, out_buffer ? out_buffer + len : NULL); + } + else if (c == 0x0345) /* COMBINING GREEK YPOGEGRAMMENI */ + { + /* Nasty, need to move it after other combining marks .. this would go away if + * we normalized first. + */ + len = output_marks (&p, out_buffer, len, FALSE); + + /* And output as GREEK CAPITAL LETTER IOTA */ + len += g_unichar_to_utf8 (0x399, out_buffer ? out_buffer + len : NULL); + } + else if (t == G_UNICODE_LOWERCASE_LETTER || t == G_UNICODE_TITLECASE_LETTER) + { + val = ATTTABLE (c >> 8, c & 0xff); + + if (val >= 0xd800 && val < 0xdc00) + { + len += output_special_case (out_buffer, len, val - 0xd800, t, + t == G_UNICODE_LOWERCASE_LETTER ? 0 : 1); + } + else + { + if (t == G_UNICODE_TITLECASE_LETTER) + { + unsigned int i; + for (i = 0; i < G_N_ELEMENTS (title_table); ++i) + { + if (title_table[i][0] == c) + val = title_table[i][1]; + } + } + + len += g_unichar_to_utf8 (val, out_buffer ? out_buffer + len : NULL); + } + } + else + { + gsize char_len = g_utf8_skip[*(guchar *)last]; + + if (out_buffer) + memcpy (out_buffer + len, last, char_len); + + len += char_len; + } + + } + + return len; +} + +/** + * g_utf8_strup: + * @str: a UTF-8 encoded string + * @len: length of @str, in bytes, or -1 if @str is nul-terminated. + * + * Converts all Unicode characters in the string that have a case + * to uppercase. The exact manner that this is done depends + * on the current locale, and may result in the number of + * characters in the string increasing. (For instance, the + * German ess-zet will be changed to SS.) + * + * Return value: a newly allocated string, with all characters + * converted to uppercase. + **/ +gchar * +g_utf8_strup (const gchar *str, + gssize len) +{ + gsize result_len; + LocaleType locale_type; + gchar *result; + + g_return_val_if_fail (str != NULL, NULL); + + locale_type = get_locale_type (); + + /* + * We use a two pass approach to keep memory management simple + */ + result_len = real_toupper (str, len, NULL, locale_type); + result = g_malloc (result_len + 1); + real_toupper (str, len, result, locale_type); + result[result_len] = '\0'; + + return result; +} + +static gsize +real_tolower (const gchar *str, + gssize max_len, + gchar *out_buffer, + LocaleType locale_type) +{ + const gchar *p = str; + const char *last = NULL; + gsize len = 0; + + while ((max_len < 0 || p < str + max_len) && *p) + { + gunichar c = g_utf8_get_char (p); + int t = TYPE (c); + gunichar val; + + last = p; + p = g_utf8_next_char (p); + + if (locale_type == LOCALE_TURKIC && c == 'I') + { + /* I => LATIN SMALL LETTER DOTLESS I */ + len += g_unichar_to_utf8 (0x131, out_buffer ? out_buffer + len : NULL); + } + else if (c == 0x03A3) /* GREEK CAPITAL LETTER SIGMA */ + { + gunichar next_c = g_utf8_get_char (p); + int next_t = TYPE(next_c); + + /* SIGMA mapps differently depending on whether it is + * final or not. The following simplified test would + * fail in the case of combining marks following the + * sigma, but I don't think that occurs in real text. + * The test here matches that in ICU. + */ + if (ISALPHA(next_t)) /* Lu,Ll,Lt,Lm,Lo */ + val = 0x3c3; /* GREEK SMALL SIGMA */ + else + val = 0x3c2; /* GREEK SMALL FINAL SIGMA */ + + len += g_unichar_to_utf8 (val, out_buffer ? out_buffer + len : NULL); + } + else if (t == G_UNICODE_UPPERCASE_LETTER || t == G_UNICODE_TITLECASE_LETTER) + { + val = ATTTABLE (c >> 8, c & 0xff); + + if (val >= 0xd800 && val < 0xdc00) + { + len += output_special_case (out_buffer, len, val - 0xd800, t, 0); + } + else + { + if (t == G_UNICODE_TITLECASE_LETTER) + { + unsigned int i; + for (i = 0; i < G_N_ELEMENTS (title_table); ++i) + { + if (title_table[i][0] == c) + val = title_table[i][2]; + } + } + + len += g_unichar_to_utf8 (val, out_buffer ? out_buffer + len : NULL); + } + } + else + { + gsize char_len = g_utf8_skip[*(guchar *)last]; + + if (out_buffer) + memcpy (out_buffer + len, last, char_len); + + len += char_len; + } + + } + + return len; +} + +/** + * g_utf8_strdown: + * @str: a UTF-8 encoded string + * @len: length of @str, in bytes, or -1 if @str is nul-terminated. + * + * Converts all Unicode characters in the string that have a case + * to lowercase. The exact manner that this is done depends + * on the current locale, and may result in the number of + * characters in the string changing. + * + * Return value: a newly allocated string, with all characters + * converted to lowercase. + **/ +gchar * +g_utf8_strdown (const gchar *str, + gssize len) +{ + gsize result_len; + LocaleType locale_type; + gchar *result; + + g_return_val_if_fail (str != NULL, NULL); + + locale_type = get_locale_type (); + + /* + * We use a two pass approach to keep memory management simple + */ + result_len = real_tolower (str, len, NULL, locale_type); + result = g_malloc (result_len + 1); + real_tolower (str, len, result, locale_type); + result[result_len] = '\0'; + + return result; +} + +/** + * g_utf8_casefold: + * @str: a UTF-8 encoded string + * @len: length of @str, in bytes, or -1 if @str is nul-terminated. + * + * Converts a string into a form that is independent of case. The + * result will not correspond to any particular case, but can be + * compared for equality or ordered with the results of calling + * g_utf8_casefold() on other strings. + * + * Note that calling g_utf8_casefold() followed by g_utf8_collate() is + * only an approximation to the correct linguistic case insensitive + * ordering, though it is a fairly good one. Getting this exactly + * right would require a more sophisticated collation function that + * takes case sensitivity into account. GLib does not currently + * provide such a function. + * + * Return value: a newly allocated string, that is a + * case independent form of @str. + **/ +gchar * +g_utf8_casefold (const gchar *str, + gssize len) +{ + GString *result = g_string_new (NULL); + const char *p; + + p = str; + while ((len < 0 || p < str + len) && *p) + { + gunichar ch = g_utf8_get_char (p); + + int start = 0; + int end = G_N_ELEMENTS (casefold_table); + + if (ch >= casefold_table[start].ch && + ch <= casefold_table[end - 1].ch) + { + while (TRUE) + { + int half = (start + end) / 2; + if (ch == casefold_table[half].ch) + { + g_string_append (result, casefold_table[half].data); + goto next; + } + else if (half == start) + break; + else if (ch > casefold_table[half].ch) + start = half; + else + end = half; + } + } + + g_string_append_unichar (result, g_unichar_tolower (ch)); + + next: + p = g_utf8_next_char (p); + } + + return g_string_free (result, FALSE); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gutf8.c b/graf2d/win32gdk/gdk/src/glib/gutf8.c new file mode 100644 index 0000000000000..ab4217bb92c6d --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gutf8.c @@ -0,0 +1,1523 @@ +/* gutf8.c - Operations on UTF-8 strings. + * + * Copyright (C) 1999 Tom Tromey + * Copyright (C) 2000 Red Hat, Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include <config.h> + +#include <stdlib.h> +#ifdef HAVE_CODESET +#include <langinfo.h> +#endif +#include <string.h> + +#include "glib.h" + +#ifdef G_PLATFORM_WIN32 +#include <stdio.h> +#define STRICT +#include <windows.h> +#undef STRICT +#endif + +#include "glibintl.h" + +#define UTF8_COMPUTE(Char, Mask, Len) \ + if (Char < 128) \ + { \ + Len = 1; \ + Mask = 0x7f; \ + } \ + else if ((Char & 0xe0) == 0xc0) \ + { \ + Len = 2; \ + Mask = 0x1f; \ + } \ + else if ((Char & 0xf0) == 0xe0) \ + { \ + Len = 3; \ + Mask = 0x0f; \ + } \ + else if ((Char & 0xf8) == 0xf0) \ + { \ + Len = 4; \ + Mask = 0x07; \ + } \ + else if ((Char & 0xfc) == 0xf8) \ + { \ + Len = 5; \ + Mask = 0x03; \ + } \ + else if ((Char & 0xfe) == 0xfc) \ + { \ + Len = 6; \ + Mask = 0x01; \ + } \ + else \ + Len = -1; + +#define UTF8_LENGTH(Char) \ + ((Char) < 0x80 ? 1 : \ + ((Char) < 0x800 ? 2 : \ + ((Char) < 0x10000 ? 3 : \ + ((Char) < 0x200000 ? 4 : \ + ((Char) < 0x4000000 ? 5 : 6))))) + + +#define UTF8_GET(Result, Chars, Count, Mask, Len) \ + (Result) = (Chars)[0] & (Mask); \ + for ((Count) = 1; (Count) < (Len); ++(Count)) \ + { \ + if (((Chars)[(Count)] & 0xc0) != 0x80) \ + { \ + (Result) = -1; \ + break; \ + } \ + (Result) <<= 6; \ + (Result) |= ((Chars)[(Count)] & 0x3f); \ + } + +#define UNICODE_VALID(Char) \ + ((Char) < 0x110000 && \ + ((Char) < 0xD800 || (Char) >= 0xE000) && \ + (Char) != 0xFFFE && (Char) != 0xFFFF) + + +static const gchar utf8_skip_data[256] = { + 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, + 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, + 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, + 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, + 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, + 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, + 2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2, + 3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,5,5,5,5,6,6,0,0 +}; + +const gchar * const g_utf8_skip = utf8_skip_data; + +/** + * g_utf8_find_prev_char: + * @str: pointer to the beginning of a UTF-8 encoded string + * @p: pointer to some position within @str + * + * Given a position @p with a UTF-8 encoded string @str, find the start + * of the previous UTF-8 character starting before @p. Returns %NULL if no + * UTF-8 characters are present in @p before @str. + * + * @p does not have to be at the beginning of a UTF-8 character. No check + * is made to see if the character found is actually valid other than + * it starts with an appropriate byte. + * + * Return value: a pointer to the found character or %NULL. + **/ +gchar * +g_utf8_find_prev_char (const char *str, + const char *p) +{ + for (--p; p >= str; --p) + { + if ((*p & 0xc0) != 0x80) + return (gchar *)p; + } + return NULL; +} + +/** + * g_utf8_find_next_char: + * @p: a pointer to a position within a UTF-8 encoded string + * @end: a pointer to the end of the string, or %NULL to indicate + * that the string is nul-terminated, in which case + * the returned value will be + * + * Finds the start of the next UTF-8 character in the string after @p. + * + * @p does not have to be at the beginning of a UTF-8 character. No check + * is made to see if the character found is actually valid other than + * it starts with an appropriate byte. + * + * Return value: a pointer to the found character or %NULL + **/ +gchar * +g_utf8_find_next_char (const gchar *p, + const gchar *end) +{ + if (*p) + { + if (end) + for (++p; p < end && (*p & 0xc0) == 0x80; ++p) + ; + else + for (++p; (*p & 0xc0) == 0x80; ++p) + ; + } + return (p == end) ? NULL : (gchar *)p; +} + +/** + * g_utf8_prev_char: + * @p: a pointer to a position within a UTF-8 encoded string + * + * Finds the previous UTF-8 character in the string before @p. + * + * @p does not have to be at the beginning of a UTF-8 character. No check + * is made to see if the character found is actually valid other than + * it starts with an appropriate byte. If @p might be the first + * character of the string, you must use g_utf8_find_prev_char() instead. + * + * Return value: a pointer to the found character. + **/ +gchar * +g_utf8_prev_char (const gchar *p) +{ + while (TRUE) + { + p--; + if ((*p & 0xc0) != 0x80) + return (gchar *)p; + } +} + +/** + * g_utf8_strlen: + * @p: pointer to the start of a UTF-8 encoded string. + * @max: the maximum number of bytes to examine. If @max + * is less than 0, then the string is assumed to be + * nul-terminated. + * + * Returns the length of the string in characters. + * + * Return value: the length of the string in characters + **/ +glong +g_utf8_strlen (const gchar *p, + gssize max) +{ + glong len = 0; + const gchar *start = p; + + if (max < 0) + { + while (*p) + { + p = g_utf8_next_char (p); + ++len; + } + } + else + { + if (max == 0 || !*p) + return 0; + + p = g_utf8_next_char (p); + + while (p - start < max && *p) + { + ++len; + p = g_utf8_next_char (p); + } + + /* only do the last len increment if we got a complete + * char (don't count partial chars) + */ + if (p - start == max) + ++len; + } + + return len; +} + +/** + * g_utf8_get_char: + * @p: a pointer to Unicode character encoded as UTF-8 + * + * Converts a sequence of bytes encoded as UTF-8 to a Unicode character. + * If @p does not point to a valid UTF-8 encoded character, results are + * undefined. If you are not sure that the bytes are complete + * valid Unicode characters, you should use g_utf8_get_char_validated() + * instead. + * + * Return value: the resulting character + **/ +gunichar +g_utf8_get_char (const gchar *p) +{ + int i, mask = 0, len; + gunichar result; + unsigned char c = (unsigned char) *p; + + UTF8_COMPUTE (c, mask, len); + if (len == -1) + return (gunichar)-1; + UTF8_GET (result, p, i, mask, len); + + return result; +} + +/** + * g_utf8_offset_to_pointer: + * @str: a UTF-8 encoded string + * @offset: a character offset within @str + * + * Converts from an integer character offset to a pointer to a position + * within the string. + * + * Return value: the resulting pointer + **/ +gchar * +g_utf8_offset_to_pointer (const gchar *str, + glong offset) +{ + const gchar *s = str; + while (offset--) + s = g_utf8_next_char (s); + + return (gchar *)s; +} + +/** + * g_utf8_pointer_to_offset: + * @str: a UTF-8 encoded string + * @pos: a pointer to a position within @str + * + * Converts from a pointer to position within a string to a integer + * character offset. + * + * Return value: the resulting character offset + **/ +glong +g_utf8_pointer_to_offset (const gchar *str, + const gchar *pos) +{ + const gchar *s = str; + glong offset = 0; + + while (s < pos) + { + s = g_utf8_next_char (s); + offset++; + } + + return offset; +} + + +/** + * g_utf8_strncpy: + * @dest: buffer to fill with characters from @src + * @src: UTF-8 encoded string + * @n: character count + * + * Like the standard C <function>strncpy()</function> function, but + * copies a given number of characters instead of a given number of + * bytes. The @src string must be valid UTF-8 encoded text. + * (Use g_utf8_validate() on all text before trying to use UTF-8 + * utility functions with it.) + * + * Return value: @dest + **/ +gchar * +g_utf8_strncpy (gchar *dest, + const gchar *src, + gsize n) +{ + const gchar *s = src; + while (n && *s) + { + s = g_utf8_next_char(s); + n--; + } + strncpy(dest, src, s - src); + dest[s - src] = 0; + return dest; +} + +static gboolean +g_utf8_get_charset_internal (char **a) +{ + char *charset = getenv("CHARSET"); + + if (charset && a && ! *a) + *a = charset; + + if (charset && strstr (charset, "UTF-8")) + return TRUE; + +#ifdef HAVE_CODESET + charset = nl_langinfo(CODESET); + if (charset) + { + if (a && ! *a) + *a = charset; + if (strcmp (charset, "UTF-8") == 0) + return TRUE; + } +#endif + +#if 0 /* #ifdef _NL_CTYPE_CODESET_NAME */ + charset = nl_langinfo (_NL_CTYPE_CODESET_NAME); + if (charset) + { + if (a && ! *a) + *a = charset; + if (strcmp (charset, "UTF-8") == 0) + return TRUE; + } +#endif + +#ifdef G_PLATFORM_WIN32 + if (a && ! *a) + { + static char codepage[10]; + + sprintf (codepage, "CP%d", GetACP ()); + *a = codepage; + /* What about codepage 1200? Is that UTF-8? */ + return FALSE; + } +#else + if (a && ! *a) + *a = "US-ASCII"; +#endif + + /* Assume this for compatibility at present. */ + return FALSE; +} + +static int utf8_locale_cache = -1; +static char *utf8_charset_cache = NULL; + +/** + * g_get_charset: + * @charset: return location for character set name + * + * Obtains the character set for the current locale; you might use + * this character set as an argument to g_convert(), to convert from + * the current locale's encoding to some other encoding. (Frequently + * g_locale_to_utf8() and g_locale_from_utf8() are nice shortcuts, + * though.) + * + * The return value is %TRUE if the locale's encoding is UTF-8, in that + * case you can perhaps avoid calling g_convert(). + * + * The string returned in @charset is not allocated, and should not be + * freed. + * + * Return value: %TRUE if the returned charset is UTF-8 + **/ +gboolean +g_get_charset (G_CONST_RETURN char **charset) +{ + if (utf8_locale_cache != -1) + { + if (charset) + *charset = utf8_charset_cache; + return utf8_locale_cache; + } + utf8_locale_cache = g_utf8_get_charset_internal (&utf8_charset_cache); + if (charset) + *charset = utf8_charset_cache; + return utf8_locale_cache; +} + +/* unicode_strchr */ + +/** + * g_unichar_to_utf8: + * @c: a ISO10646 character code + * @outbuf: output buffer, must have at least 6 bytes of space. + * If %NULL, the length will be computed and returned + * and nothing will be written to @outbuf. + * + * Converts a single character to UTF-8. + * + * Return value: number of bytes written + **/ +int +g_unichar_to_utf8 (gunichar c, + gchar *outbuf) +{ + guint len = 0; + int first; + int i; + + if (c < 0x80) + { + first = 0; + len = 1; + } + else if (c < 0x800) + { + first = 0xc0; + len = 2; + } + else if (c < 0x10000) + { + first = 0xe0; + len = 3; + } + else if (c < 0x200000) + { + first = 0xf0; + len = 4; + } + else if (c < 0x4000000) + { + first = 0xf8; + len = 5; + } + else + { + first = 0xfc; + len = 6; + } + + if (outbuf) + { + for (i = len - 1; i > 0; --i) + { + outbuf[i] = (c & 0x3f) | 0x80; + c >>= 6; + } + outbuf[0] = c | first; + } + + return len; +} + +/** + * g_utf8_strchr: + * @p: a nul-terminated UTF-8 encoded string + * @len: the maximum length of @p + * @c: a ISO10646 character + * + * Finds the leftmost occurrence of the given ISO10646 character + * in a UTF-8 encoded string, while limiting the search to @len bytes. + * If @len is -1, allow unbounded search. + * + * Return value: %NULL if the string does not contain the character, + * otherwise, a pointer to the start of the leftmost occurrence of + * the character in the string. + **/ +gchar * +g_utf8_strchr (const char *p, + gssize len, + gunichar c) +{ + gchar ch[10]; + + gint charlen = g_unichar_to_utf8 (c, ch); + ch[charlen] = '\0'; + + return g_strstr_len (p, len, ch); +} + + +/** + * g_utf8_strrchr: + * @p: a nul-terminated UTF-8 encoded string + * @len: the maximum length of @p + * @c: a ISO10646 character + * + * Find the rightmost occurrence of the given ISO10646 character + * in a UTF-8 encoded string, while limiting the search to @len bytes. + * If @len is -1, allow unbounded search. + * + * Return value: %NULL if the string does not contain the character, + * otherwise, a pointer to the start of the rightmost occurrence of the + * character in the string. + **/ +gchar * +g_utf8_strrchr (const char *p, + gssize len, + gunichar c) +{ + gchar ch[10]; + + gint charlen = g_unichar_to_utf8 (c, ch); + ch[charlen] = '\0'; + + return g_strrstr_len (p, len, ch); +} + + +/* Like g_utf8_get_char, but take a maximum length + * and return (gunichar)-2 on incomplete trailing character + */ +static inline gunichar +g_utf8_get_char_extended (const gchar *p, + gssize max_len) +{ + guint i, len; + gunichar wc = (guchar) *p; + + if (wc < 0x80) + { + return wc; + } + else if (wc < 0xc0) + { + return (gunichar)-1; + } + else if (wc < 0xe0) + { + len = 2; + wc &= 0x1f; + } + else if (wc < 0xf0) + { + len = 3; + wc &= 0x0f; + } + else if (wc < 0xf8) + { + len = 4; + wc &= 0x07; + } + else if (wc < 0xfc) + { + len = 5; + wc &= 0x03; + } + else if (wc < 0xfe) + { + len = 6; + wc &= 0x01; + } + else + { + return (gunichar)-1; + } + + if (max_len >= 0 && len > max_len) + { + for (i = 1; i < max_len; i++) + { + if ((((guchar *)p)[i] & 0xc0) != 0x80) + return (gunichar)-1; + } + return (gunichar)-2; + } + + for (i = 1; i < len; ++i) + { + gunichar ch = ((guchar *)p)[i]; + + if ((ch & 0xc0) != 0x80) + { + if (ch) + return (gunichar)-1; + else + return (gunichar)-2; + } + + wc <<= 6; + wc |= (ch & 0x3f); + } + + if (UTF8_LENGTH(wc) != len) + return (gunichar)-1; + + return wc; +} + +/** + * g_utf8_get_char_validated: + * @p: a pointer to Unicode character encoded as UTF-8 + * @max_len: the maximum number of bytes to read, or -1, for no maximum. + * + * Convert a sequence of bytes encoded as UTF-8 to a Unicode character. + * This function checks for incomplete characters, for invalid characters + * such as characters that are out of the range of Unicode, and for + * overlong encodings of valid characters. + * + * Return value: the resulting character. If @p points to a partial + * sequence at the end of a string that could begin a valid character, + * returns (gunichar)-2; otherwise, if @p does not point to a valid + * UTF-8 encoded Unicode character, returns (gunichar)-1. + **/ +gunichar +g_utf8_get_char_validated (const gchar *p, + gssize max_len) +{ + gunichar result = g_utf8_get_char_extended (p, max_len); + + if (result & 0x80000000) + return result; + else if (!UNICODE_VALID (result)) + return (gunichar)-1; + else + return result; +} + +/** + * g_utf8_to_ucs4_fast: + * @str: a UTF-8 encoded string + * @len: the maximum length of @str to use. If @len < 0, then + * the string is nul-terminated. + * @items_written: location to store the number of characters in the + * result, or %NULL. + * + * Convert a string from UTF-8 to a 32-bit fixed width + * representation as UCS-4, assuming valid UTF-8 input. + * This function is roughly twice as fast as g_utf8_to_ucs4() + * but does no error checking on the input. + * + * Return value: a pointer to a newly allocated UCS-4 string. + * This value must be freed with g_free(). + **/ +gunichar * +g_utf8_to_ucs4_fast (const gchar *str, + glong len, + glong *items_written) +{ + gint j, charlen; + gunichar *result; + gint n_chars, i; + const gchar *p; + + g_return_val_if_fail (str != NULL, NULL); + + p = str; + n_chars = 0; + if (len < 0) + { + while (*p) + { + p = g_utf8_next_char (p); + ++n_chars; + } + } + else + { + while (p < str + len && *p) + { + p = g_utf8_next_char (p); + ++n_chars; + } + } + + result = g_new (gunichar, n_chars + 1); + + p = str; + for (i=0; i < n_chars; i++) + { + gunichar wc = ((unsigned char *)p)[0]; + + if (wc < 0x80) + { + result[i] = wc; + p++; + } + else + { + if (wc < 0xe0) + { + charlen = 2; + wc &= 0x1f; + } + else if (wc < 0xf0) + { + charlen = 3; + wc &= 0x0f; + } + else if (wc < 0xf8) + { + charlen = 4; + wc &= 0x07; + } + else if (wc < 0xfc) + { + charlen = 5; + wc &= 0x03; + } + else + { + charlen = 6; + wc &= 0x01; + } + + for (j = 1; j < charlen; j++) + { + wc <<= 6; + wc |= ((unsigned char *)p)[j] & 0x3f; + } + + result[i] = wc; + p += charlen; + } + } + result[i] = 0; + + if (items_written) + *items_written = i; + + return result; +} + +/** + * g_utf8_to_ucs4: + * @str: a UTF-8 encoded string + * @len: the maximum length of @str to use. If @len < 0, then + * the string is nul-terminated. + * @items_read: location to store number of bytes read, or %NULL. + * If %NULL, then %G_CONVERT_ERROR_PARTIAL_INPUT will be + * returned in case @str contains a trailing partial + * character. If an error occurs then the index of the + * invalid input is stored here. + * @items_written: location to store number of characters written or %NULL. + * The value here stored does not include the trailing 0 + * character. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError other than + * %G_CONVERT_ERROR_NO_CONVERSION may occur. + * + * Convert a string from UTF-8 to a 32-bit fixed width + * representation as UCS-4. A trailing 0 will be added to the + * string after the converted text. + * + * Return value: a pointer to a newly allocated UCS-4 string. + * This value must be freed with g_free(). If an + * error occurs, %NULL will be returned and + * @error set. + **/ +gunichar * +g_utf8_to_ucs4 (const gchar *str, + glong len, + glong *items_read, + glong *items_written, + GError **error) +{ + gunichar *result = NULL; + gint n_chars, i; + const gchar *in; + + in = str; + n_chars = 0; + while ((len < 0 || str + len - in > 0) && *in) + { + gunichar wc = g_utf8_get_char_extended (in, str + len - in); + if (wc & 0x80000000) + { + if (wc == (gunichar)-2) + { + if (items_read) + break; + else + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_PARTIAL_INPUT, + _("Partial character sequence at end of input")); + } + else + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid byte sequence in conversion input")); + + goto err_out; + } + + n_chars++; + + in = g_utf8_next_char (in); + } + + result = g_new (gunichar, n_chars + 1); + + in = str; + for (i=0; i < n_chars; i++) + { + result[i] = g_utf8_get_char (in); + in = g_utf8_next_char (in); + } + result[i] = 0; + + if (items_written) + *items_written = n_chars; + + err_out: + if (items_read) + *items_read = in - str; + + return result; +} + +/** + * g_ucs4_to_utf8: + * @str: a UCS-4 encoded string + * @len: the maximum length of @str to use. If @len < 0, then + * the string is terminated with a 0 character. + * @items_read: location to store number of characters read read, or %NULL. + * @items_written: location to store number of bytes written or %NULL. + * The value here stored does not include the trailing 0 + * byte. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError other than + * %G_CONVERT_ERROR_NO_CONVERSION may occur. + * + * Convert a string from a 32-bit fixed width representation as UCS-4. + * to UTF-8. The result will be terminated with a 0 byte. + * + * Return value: a pointer to a newly allocated UTF-8 string. + * This value must be freed with g_free(). If an + * error occurs, %NULL will be returned and + * @error set. + **/ +gchar * +g_ucs4_to_utf8 (const gunichar *str, + glong len, + glong *items_read, + glong *items_written, + GError **error) +{ + gint result_length; + gchar *result = NULL; + gchar *p; + gint i; + + result_length = 0; + for (i = 0; len < 0 || i < len ; i++) + { + if (!str[i]) + break; + + if (str[i] >= 0x80000000) + { + if (items_read) + *items_read = i; + + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Character out of range for UTF-8")); + goto err_out; + } + + result_length += UTF8_LENGTH (str[i]); + } + + result = g_malloc (result_length + 1); + p = result; + + i = 0; + while (p < result + result_length) + p += g_unichar_to_utf8 (str[i++], p); + + *p = '\0'; + + if (items_written) + *items_written = p - result; + + err_out: + if (items_read) + *items_read = i; + + return result; +} + +#define SURROGATE_VALUE(h,l) (((h) - 0xd800) * 0x400 + (l) - 0xdc00 + 0x10000) + +/** + * g_utf16_to_utf8: + * @str: a UTF-16 encoded string + * @len: the maximum length of @str to use. If @len < 0, then + * the string is terminated with a 0 character. + * @items_read: location to store number of words read, or %NULL. + * If %NULL, then %G_CONVERT_ERROR_PARTIAL_INPUT will be + * returned in case @str contains a trailing partial + * character. If an error occurs then the index of the + * invalid input is stored here. + * @items_written: location to store number of bytes written, or %NULL. + * The value stored here does not include the trailing + * 0 byte. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError other than + * %G_CONVERT_ERROR_NO_CONVERSION may occur. + * + * Convert a string from UTF-16 to UTF-8. The result will be + * terminated with a 0 byte. + * + * Return value: a pointer to a newly allocated UTF-8 string. + * This value must be freed with g_free(). If an + * error occurs, %NULL will be returned and + * @error set. + **/ +gchar * +g_utf16_to_utf8 (const gunichar2 *str, + glong len, + glong *items_read, + glong *items_written, + GError **error) +{ + /* This function and g_utf16_to_ucs4 are almost exactly identical - The lines that differ + * are marked. + */ + const gunichar2 *in; + gchar *out; + gchar *result = NULL; + gint n_bytes; + gunichar high_surrogate; + + g_return_val_if_fail (str != 0, NULL); + + n_bytes = 0; + in = str; + high_surrogate = 0; + while ((len < 0 || in - str < len) && *in) + { + gunichar2 c = *in; + gunichar wc; + + if (c >= 0xdc00 && c < 0xe000) /* low surrogate */ + { + if (high_surrogate) + { + wc = SURROGATE_VALUE (high_surrogate, c); + high_surrogate = 0; + } + else + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid sequence in conversion input")); + goto err_out; + } + } + else + { + if (high_surrogate) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid sequence in conversion input")); + goto err_out; + } + + if (c >= 0xd800 && c < 0xdc00) /* high surrogate */ + { + high_surrogate = c; + goto next1; + } + else + wc = c; + } + + /********** DIFFERENT for UTF8/UCS4 **********/ + n_bytes += UTF8_LENGTH (wc); + + next1: + in++; + } + + if (high_surrogate && !items_read) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_PARTIAL_INPUT, + _("Partial character sequence at end of input")); + goto err_out; + } + + /* At this point, everything is valid, and we just need to convert + */ + /********** DIFFERENT for UTF8/UCS4 **********/ + result = g_malloc (n_bytes + 1); + + high_surrogate = 0; + out = result; + in = str; + while (out < result + n_bytes) + { + gunichar2 c = *in; + gunichar wc; + + if (c >= 0xdc00 && c < 0xe000) /* low surrogate */ + { + wc = SURROGATE_VALUE (high_surrogate, c); + high_surrogate = 0; + } + else if (c >= 0xd800 && c < 0xdc00) /* high surrogate */ + { + high_surrogate = c; + goto next2; + } + else + wc = c; + + /********** DIFFERENT for UTF8/UCS4 **********/ + out += g_unichar_to_utf8 (wc, out); + + next2: + in++; + } + + /********** DIFFERENT for UTF8/UCS4 **********/ + *out = '\0'; + + if (items_written) + /********** DIFFERENT for UTF8/UCS4 **********/ + *items_written = out - result; + + err_out: + if (items_read) + *items_read = in - str; + + return result; +} + +/** + * g_utf16_to_ucs4: + * @str: a UTF-16 encoded string + * @len: the maximum length of @str to use. If @len < 0, then + * the string is terminated with a 0 character. + * @items_read: location to store number of words read, or %NULL. + * If %NULL, then %G_CONVERT_ERROR_PARTIAL_INPUT will be + * returned in case @str contains a trailing partial + * character. If an error occurs then the index of the + * invalid input is stored here. + * @items_written: location to store number of characters written, or %NULL. + * The value stored here does not include the trailing + * 0 character. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError other than + * %G_CONVERT_ERROR_NO_CONVERSION may occur. + * + * Convert a string from UTF-16 to UCS-4. The result will be + * terminated with a 0 character. + * + * Return value: a pointer to a newly allocated UCS-4 string. + * This value must be freed with g_free(). If an + * error occurs, %NULL will be returned and + * @error set. + **/ +gunichar * +g_utf16_to_ucs4 (const gunichar2 *str, + glong len, + glong *items_read, + glong *items_written, + GError **error) +{ + const gunichar2 *in; + gchar *out; + gchar *result = NULL; + gint n_bytes; + gunichar high_surrogate; + + g_return_val_if_fail (str != 0, NULL); + + n_bytes = 0; + in = str; + high_surrogate = 0; + while ((len < 0 || in - str < len) && *in) + { + gunichar2 c = *in; + gunichar wc; + + if (c >= 0xdc00 && c < 0xe000) /* low surrogate */ + { + if (high_surrogate) + { + wc = SURROGATE_VALUE (high_surrogate, c); + high_surrogate = 0; + } + else + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid sequence in conversion input")); + goto err_out; + } + } + else + { + if (high_surrogate) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid sequence in conversion input")); + goto err_out; + } + + if (c >= 0xd800 && c < 0xdc00) /* high surrogate */ + { + high_surrogate = c; + goto next1; + } + else + wc = c; + } + + /********** DIFFERENT for UTF8/UCS4 **********/ + n_bytes += sizeof (gunichar); + + next1: + in++; + } + + if (high_surrogate && !items_read) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_PARTIAL_INPUT, + _("Partial character sequence at end of input")); + goto err_out; + } + + /* At this point, everything is valid, and we just need to convert + */ + /********** DIFFERENT for UTF8/UCS4 **********/ + result = g_malloc (n_bytes + 4); + + high_surrogate = 0; + out = result; + in = str; + while (out < result + n_bytes) + { + gunichar2 c = *in; + gunichar wc; + + if (c >= 0xdc00 && c < 0xe000) /* low surrogate */ + { + wc = SURROGATE_VALUE (high_surrogate, c); + high_surrogate = 0; + } + else if (c >= 0xd800 && c < 0xdc00) /* high surrogate */ + { + high_surrogate = c; + goto next2; + } + else + wc = c; + + /********** DIFFERENT for UTF8/UCS4 **********/ + *(gunichar *)out = wc; + out += sizeof (gunichar); + + next2: + in++; + } + + /********** DIFFERENT for UTF8/UCS4 **********/ + *(gunichar *)out = 0; + + if (items_written) + /********** DIFFERENT for UTF8/UCS4 **********/ + *items_written = (out - result) / sizeof (gunichar); + + err_out: + if (items_read) + *items_read = in - str; + + return (gunichar *)result; +} + +/** + * g_utf8_to_utf16: + * @str: a UTF-8 encoded string + * @len: the maximum length of @str to use. If @len < 0, then + * the string is nul-terminated. + + * @items_read: location to store number of bytes read, or %NULL. + * If %NULL, then %G_CONVERT_ERROR_PARTIAL_INPUT will be + * returned in case @str contains a trailing partial + * character. If an error occurs then the index of the + * invalid input is stored here. + * @items_written: location to store number of words written, or %NULL. + * The value stored here does not include the trailing + * 0 word. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError other than + * %G_CONVERT_ERROR_NO_CONVERSION may occur. + * + * Convert a string from UTF-8 to UTF-16. A 0 word will be + * added to the result after the converted text. + * + * Return value: a pointer to a newly allocated UTF-16 string. + * This value must be freed with g_free(). If an + * error occurs, %NULL will be returned and + * @error set. + **/ +gunichar2 * +g_utf8_to_utf16 (const gchar *str, + glong len, + glong *items_read, + glong *items_written, + GError **error) +{ + gunichar2 *result = NULL; + gint n16; + const gchar *in; + gint i; + + g_return_val_if_fail (str != NULL, NULL); + + in = str; + n16 = 0; + while ((len < 0 || str + len - in > 0) && *in) + { + gunichar wc = g_utf8_get_char_extended (in, str + len - in); + if (wc & 0x80000000) + { + if (wc == (gunichar)-2) + { + if (items_read) + break; + else + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_PARTIAL_INPUT, + _("Partial character sequence at end of input")); + } + else + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid byte sequence in conversion input")); + + goto err_out; + } + + if (wc < 0xd800) + n16 += 1; + else if (wc < 0xe000) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid sequence in conversion input")); + + goto err_out; + } + else if (wc < 0x10000) + n16 += 1; + else if (wc < 0x110000) + n16 += 2; + else + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Character out of range for UTF-16")); + + goto err_out; + } + + in = g_utf8_next_char (in); + } + + result = g_new (gunichar2, n16 + 1); + + in = str; + for (i = 0; i < n16;) + { + gunichar wc = g_utf8_get_char (in); + + if (wc < 0x10000) + { + result[i++] = wc; + } + else + { + result[i++] = (wc - 0x10000) / 0x400 + 0xd800; + result[i++] = (wc - 0x10000) % 0x400 + 0xdc00; + } + + in = g_utf8_next_char (in); + } + + result[i] = 0; + + if (items_written) + *items_written = n16; + + err_out: + if (items_read) + *items_read = in - str; + + return result; +} + +/** + * g_ucs4_to_utf16: + * @str: a UCS-4 encoded string + * @len: the maximum length of @str to use. If @len < 0, then + * the string is terminated with a 0 character. + * @items_read: location to store number of bytes read, or %NULL. + * If an error occurs then the index of the invalid input + * is stored here. + * @items_written: location to store number of words written, or %NULL. + * The value stored here does not include the trailing + * 0 word. + * @error: location to store the error occuring, or %NULL to ignore + * errors. Any of the errors in #GConvertError other than + * %G_CONVERT_ERROR_NO_CONVERSION may occur. + * + * Convert a string from UCS-4 to UTF-16. A 0 word will be + * added to the result after the converted text. + * + * Return value: a pointer to a newly allocated UTF-16 string. + * This value must be freed with g_free(). If an + * error occurs, %NULL will be returned and + * @error set. + **/ +gunichar2 * +g_ucs4_to_utf16 (const gunichar *str, + glong len, + glong *items_read, + glong *items_written, + GError **error) +{ + gunichar2 *result = NULL; + gint n16; + gint i, j; + + n16 = 0; + i = 0; + while ((len < 0 || i < len) && str[i]) + { + gunichar wc = str[i]; + + if (wc < 0xd800) + n16 += 1; + else if (wc < 0xe000) + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Invalid sequence in conversion input")); + + goto err_out; + } + else if (wc < 0x10000) + n16 += 1; + else if (wc < 0x110000) + n16 += 2; + else + { + g_set_error (error, G_CONVERT_ERROR, G_CONVERT_ERROR_ILLEGAL_SEQUENCE, + _("Character out of range for UTF-16")); + + goto err_out; + } + + i++; + } + + result = g_new (gunichar2, n16 + 1); + + for (i = 0, j = 0; j < n16; i++) + { + gunichar wc = str[i]; + + if (wc < 0x10000) + { + result[j++] = wc; + } + else + { + result[j++] = (wc - 0x10000) / 0x400 + 0xd800; + result[j++] = (wc - 0x10000) % 0x400 + 0xdc00; + } + } + result[j] = 0; + + if (items_written) + *items_written = n16; + + err_out: + if (items_read) + *items_read = i; + + return result; +} + +/** + * g_utf8_validate: + * @str: a pointer to character data + * @max_len: max bytes to validate, or -1 to go until nul + * @end: return location for end of valid data + * + * Validates UTF-8 encoded text. @str is the text to validate; + * if @str is nul-terminated, then @max_len can be -1, otherwise + * @max_len should be the number of bytes to validate. + * If @end is non-%NULL, then the end of the valid range + * will be stored there (i.e. the address of the first invalid byte + * if some bytes were invalid, or the end of the text being validated + * otherwise). + * + * Returns %TRUE if all of @str was valid. Many GLib and GTK+ + * routines <emphasis>require</emphasis> valid UTF-8 as input; + * so data read from a file or the network should be checked + * with g_utf8_validate() before doing anything else with it. + * + * Return value: %TRUE if the text was valid UTF-8 + **/ +gboolean +g_utf8_validate (const gchar *str, + gssize max_len, + const gchar **end) +{ + + const gchar *p; + + g_return_val_if_fail (str != NULL, FALSE); + + if (end) + *end = str; + + p = str; + + while ((max_len < 0 || (p - str) < max_len) && *p) + { + int i, mask = 0, len; + gunichar result; + unsigned char c = (unsigned char) *p; + + UTF8_COMPUTE (c, mask, len); + + if (len == -1) + break; + + /* check that the expected number of bytes exists in str */ + if (max_len >= 0 && + ((max_len - (p - str)) < len)) + break; + + UTF8_GET (result, p, i, mask, len); + + if (UTF8_LENGTH (result) != len) /* Check for overlong UTF-8 */ + break; + + if (result == (gunichar)-1) + break; + + if (!UNICODE_VALID (result)) + break; + + p += len; + } + + if (end) + *end = p; + + /* See that we covered the entire length if a length was + * passed in, or that we ended on a nul if not + */ + if (max_len >= 0 && + p != (str + max_len)) + return FALSE; + else if (max_len < 0 && + *p != '\0') + return FALSE; + else + return TRUE; +} + +/** + * g_unichar_validate: + * @ch: a Unicode character + * + * Checks whether @ch is a valid Unicode character. Some possible + * integer values of @ch will not be valid. 0 is considered a valid + * character, though it's normally a string terminator. + * + * Return value: %TRUE if @ch is a valid Unicode character + **/ +gboolean +g_unichar_validate (gunichar ch) +{ + return UNICODE_VALID (ch); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gutils.c b/graf2d/win32gdk/gdk/src/glib/gutils.c new file mode 100644 index 0000000000000..53dc57755a91e --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gutils.c @@ -0,0 +1,1136 @@ +/* GLIB - Library of useful routines for C programming +* Copyright (C) 1995-1998 Peter Mattis, Spencer Kimball and Josh MacDonald +* +* This library is free software; you can redistribute it and/or +* modify it under the terms of the GNU Lesser General Public +* License as published by the Free Software Foundation; either +* version 2 of the License, or (at your option) any later version. +* +* This library is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +* Lesser General Public License for more details. +* +* You should have received a copy of the GNU Lesser General Public +* License along with this library; if not, write to the +* Free Software Foundation, Inc., 59 Temple Place - Suite 330, +* Boston, MA 02111-1307, USA. +*/ + +/* +* Modified by the GLib Team and others 1997-2000. See the AUTHORS +* file for a list of people on the GLib Team. See the ChangeLog +* files for a list of changes. These files are distributed with +* GLib at ftp://ftp.gtk.org/pub/gtk/. +*/ + +/* +* MT safe for the unix part, FIXME: make the win32 part MT safe as well. +*/ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#ifdef HAVE_UNISTD_H +#include <unistd.h> +#endif +#include <stdarg.h> +#include <stdlib.h> +#include <stdio.h> +#include <string.h> +#include <errno.h> +#ifdef HAVE_PWD_H +#include <pwd.h> +#endif +#include <sys/types.h> +#ifdef HAVE_SYS_PARAM_H +#include <sys/param.h> +#endif + +/* implement gutils's inline functions +*/ +#define G_IMPLEMENT_INLINES 1 +#define __G_UTILS_C__ +#include "glib.h" + +#ifdef MAXPATHLEN +#define G_PATH_LENGTH MAXPATHLEN +#elif defined (PATH_MAX) +#define G_PATH_LENGTH PATH_MAX +#elif defined (_PC_PATH_MAX) +#define G_PATH_LENGTH sysconf(_PC_PATH_MAX) +#else +#define G_PATH_LENGTH 2048 +#endif + +#ifdef G_PLATFORM_WIN32 +# define STRICT /* Strict typing, please */ +# include <windows.h> +# undef STRICT +# include <ctype.h> +#endif /* G_PLATFORM_WIN32 */ + +#ifdef G_OS_WIN32 +# include <direct.h> +#endif + +#ifdef HAVE_CODESET +#include <langinfo.h> +#endif + +const guint glib_major_version = GLIB_MAJOR_VERSION; +const guint glib_minor_version = GLIB_MINOR_VERSION; +const guint glib_micro_version = GLIB_MICRO_VERSION; +const guint glib_interface_age = 2; // GTW - no idea, didn't seem to be set anywhere! Not set or used by ROOT. +const guint glib_binary_age = 2; // GTW - no idea, doesn't seem to be set or used by ROOT. + +// Have it, but defines wrong. Scary! GTW +#if 0 +#if !defined (HAVE_MEMMOVE) && !defined (HAVE_WORKING_BCOPY) +void + g_memmove (gpointer dest, gconstpointer src, gulong len) +{ + gchar* destptr = dest; + const gchar* srcptr = src; + if (src + len < dest || dest + len < src) + { + bcopy (src, dest, len); + return; + } + else if (dest <= src) + { + while (len--) + *(destptr++) = *(srcptr++); + } + else + { + destptr += len; + srcptr += len; + while (len--) + *(--destptr) = *(--srcptr); + } +} +#endif /* !HAVE_MEMMOVE && !HAVE_WORKING_BCOPY */ +#endif + +void + g_atexit (GVoidFunc func) +{ + gint result; + const gchar *error = NULL; + + /* keep this in sync with glib.h */ + +#ifdef G_NATIVE_ATEXIT + result = ATEXIT (func); + if (result) + error = g_strerror (errno); +#elif defined (HAVE_ATEXIT) +# ifdef NeXT /* @#%@! NeXTStep */ + result = !atexit ((void (*)(void)) func); + if (result) + error = g_strerror (errno); +# else + result = atexit ((void (*)(void)) func); + if (result) + error = g_strerror (errno); +# endif /* NeXT */ +#elif defined (HAVE_ON_EXIT) + result = on_exit ((void (*)(int, void *)) func, NULL); + if (result) + error = g_strerror (errno); +#else + result = 0; + error = "no implementation"; +#endif /* G_NATIVE_ATEXIT */ + + if (error) + g_error ("Could not register atexit() function: %s", error); +} + +/* Based on execvp() from GNU Libc. +* Some of this code is cut-and-pasted into gspawn.c +*/ + +static gchar* + my_strchrnul (const gchar *str, gchar c) +{ + gchar *p = (gchar*)str; + while (*p && (*p != c)) + ++p; + + return p; +} + +#ifdef G_OS_WIN32 + +gchar *inner_find_program_in_path (const gchar *program); + +gchar* + g_find_program_in_path (const gchar *program) +{ + const gchar *last_dot = strrchr (program, '.'); + + if (last_dot == NULL || strchr (last_dot, '\\') != NULL) + { + const gint program_length = strlen (program); + const gchar *pathext = getenv ("PATHEXT"); + const gchar *p; + gchar *decorated_program; + gchar *retval; + + if (pathext == NULL) + pathext = ".com;.exe;.bat"; + + p = pathext; + do + { + pathext = p; + p = my_strchrnul (pathext, ';'); + + decorated_program = g_malloc (program_length + (p-pathext) + 1); + memcpy (decorated_program, program, program_length); + memcpy (decorated_program+program_length, pathext, p-pathext); + decorated_program [program_length + (p-pathext)] = '\0'; + + retval = inner_find_program_in_path (decorated_program); + g_free (decorated_program); + + if (retval != NULL) + return retval; + } while (*p++ != '\0'); + return NULL; + } + else + return inner_find_program_in_path (program); +} + +#define g_find_program_in_path inner_find_program_in_path +#endif + +/** +* g_find_program_in_path: +* @program: a program name +* +* Locates the first executable named @program in the user's path, in the +* same way that execvp() would locate it. Returns an allocated string +* with the absolute path name, or NULL if the program is not found in +* the path. If @program is already an absolute path, returns a copy of +* @program if @program exists and is executable, and NULL otherwise. +* +* On Windows, if @program does not have a file type suffix, tries to +* append the suffixes in the PATHEXT environment variable (if that +* doesn't exists, the suffixes .com, .exe, and .bat) in turn, and +* then look for the resulting file name in the same way as +* CreateProcess() would. This means first in the directory where the +* program was loaded from, then in the current directory, then in the +* Windows 32-bit system directory, then in the Windows directory, and +* finally in the directories in the PATH environment variable. If +* the program is found, the return value contains the full name +* including the type suffix. +* +* Return value: absolute path, or NULL +**/ +gchar* + g_find_program_in_path (const gchar *program) +{ + const gchar *path, *p; + gchar *name, *freeme; +#ifdef G_OS_WIN32 + gchar *path_tmp; +#endif + size_t len; + size_t pathlen; + + g_return_val_if_fail (program != NULL, NULL); + + /* If it is an absolute path, or a relative path including subdirectories, + * don't look in PATH. + */ + if (g_path_is_absolute (program) + || strchr (program, G_DIR_SEPARATOR) != NULL) + { + if (g_file_test (program, G_FILE_TEST_IS_EXECUTABLE)) + return g_strdup (program); + else + return NULL; + } + + path = g_getenv ("PATH"); +#ifdef G_OS_UNIX + if (path == NULL) + { + /* There is no `PATH' in the environment. The default + * search path in GNU libc is the current directory followed by + * the path `confstr' returns for `_CS_PATH'. + */ + + /* In GLib we put . last, for security, and don't use the + * unportable confstr(); UNIX98 does not actually specify + * what to search if PATH is unset. POSIX may, dunno. + */ + + path = "/bin:/usr/bin:."; + } +#else + { + gchar *tmp; + gchar moddir[MAXPATHLEN], sysdir[MAXPATHLEN], windir[MAXPATHLEN]; + + GetModuleFileName (NULL, moddir, sizeof (moddir)); + tmp = g_path_get_dirname (moddir); + GetSystemDirectory (sysdir, sizeof (sysdir)); + GetWindowsDirectory (windir, sizeof (windir)); + path_tmp = g_strconcat (tmp, ";.;", sysdir, ";", windir, + (path != NULL ? ";" : NULL), + (path != NULL ? path : NULL), + NULL); + g_free (tmp); + path = path_tmp; + } +#endif + + len = strlen (program) + 1; + pathlen = strlen (path); + freeme = name = g_malloc (pathlen + len + 1); + + /* Copy the file name at the top, including '\0' */ + memcpy (name + pathlen + 1, program, len); + name = name + pathlen; + /* And add the slash before the filename */ + *name = G_DIR_SEPARATOR; + + p = path; + do + { + char *startp; + + path = p; + p = my_strchrnul (path, G_SEARCHPATH_SEPARATOR); + + if (p == path) + /* Two adjacent colons, or a colon at the beginning or the end + * of `PATH' means to search the current directory. + */ + startp = name + 1; + else + startp = memcpy (name - (p - path), path, p - path); + + if (g_file_test (startp, G_FILE_TEST_IS_EXECUTABLE)) + { + gchar *ret; + ret = g_strdup (startp); + g_free (freeme); +#ifdef G_OS_WIN32 + g_free (path_tmp); +#endif + return ret; + } + } + while (*p++ != '\0'); + + g_free (freeme); +#ifdef G_OS_WIN32 + g_free (path_tmp); +#endif + + return NULL; +} + +gint + g_snprintf (gchar *str, + gulong n, + gchar const *fmt, + ...) +{ +#ifdef HAVE_VSNPRINTF + va_list args; + gint retval; + + g_return_val_if_fail (str != NULL, 0); + g_return_val_if_fail (n > 0, 0); + g_return_val_if_fail (fmt != NULL, 0); + + va_start (args, fmt); + retval = vsnprintf (str, n, fmt, args); + va_end (args); + + if (retval < 0) + { + str[n-1] = '\0'; + retval = strlen (str); + } + + return retval; +#else /* !HAVE_VSNPRINTF */ + gchar *printed; + va_list args; + + g_return_val_if_fail (str != NULL, 0); + g_return_val_if_fail (n > 0, 0); + g_return_val_if_fail (fmt != NULL, 0); + + va_start (args, fmt); + printed = g_strdup_vprintf (fmt, args); + va_end (args); + + strncpy (str, printed, n); + str[n-1] = '\0'; + + g_free (printed); + + return strlen (str); +#endif /* !HAVE_VSNPRINTF */ +} + +gint + g_vsnprintf (gchar *str, + gulong n, + gchar const *fmt, + va_list args) +{ +#ifdef HAVE_VSNPRINTF + gint retval; + + g_return_val_if_fail (str != NULL, 0); + g_return_val_if_fail (n > 0, 0); + g_return_val_if_fail (fmt != NULL, 0); + + retval = vsnprintf (str, n, fmt, args); + + if (retval < 0) + { + str[n-1] = '\0'; + retval = strlen (str); + } + + return retval; +#else /* !HAVE_VSNPRINTF */ + gchar *printed; + + g_return_val_if_fail (str != NULL, 0); + g_return_val_if_fail (n > 0, 0); + g_return_val_if_fail (fmt != NULL, 0); + + printed = g_strdup_vprintf (fmt, args); + strncpy (str, printed, n); + str[n-1] = '\0'; + + g_free (printed); + + return strlen (str); +#endif /* !HAVE_VSNPRINTF */ +} + +guint + g_parse_debug_string (const gchar *string, + const GDebugKey *keys, + guint nkeys) +{ + guint i; + guint result = 0; + + g_return_val_if_fail (string != NULL, 0); + + if (!g_ascii_strcasecmp (string, "all")) + { + for (i=0; i<nkeys; i++) + result |= keys[i].value; + } + else + { + const gchar *p = string; + const gchar *q; + gboolean done = FALSE; + + while (*p && !done) + { + q = strchr (p, ':'); + if (!q) + { + q = p + strlen(p); + done = TRUE; + } + + for (i=0; i<nkeys; i++) + if (g_ascii_strncasecmp(keys[i].key, p, q - p) == 0 && + keys[i].key[q - p] == '\0') + result |= keys[i].value; + + p = q + 1; + } + } + + return result; +} + +G_CONST_RETURN gchar* + g_basename (const gchar *file_name) +{ + register gchar *base; + + g_return_val_if_fail (file_name != NULL, NULL); + + base = strrchr (file_name, G_DIR_SEPARATOR); + if (base) + return base + 1; + +#ifdef G_OS_WIN32 + if (g_ascii_isalpha (file_name[0]) && file_name[1] == ':') + return (gchar*) file_name + 2; +#endif /* G_OS_WIN32 */ + + return (gchar*) file_name; +} + +gchar* + g_path_get_basename (const gchar *file_name) +{ + register gssize base; + register gssize last_nonslash; + gsize len; + gchar *retval; + + g_return_val_if_fail (file_name != NULL, NULL); + + if (file_name[0] == '\0') + /* empty string */ + return g_strdup ("."); + + last_nonslash = strlen (file_name) - 1; + + while (last_nonslash >= 0 && file_name [last_nonslash] == G_DIR_SEPARATOR) + last_nonslash--; + + if (last_nonslash == -1) + /* string only containing slashes */ + return g_strdup (G_DIR_SEPARATOR_S); + +#ifdef G_OS_WIN32 + if (last_nonslash == 1 && g_ascii_isalpha (file_name[0]) && file_name[1] == ':') + /* string only containing slashes and a drive */ + return g_strdup (G_DIR_SEPARATOR_S); +#endif /* G_OS_WIN32 */ + + base = last_nonslash; + + while (base >=0 && file_name [base] != G_DIR_SEPARATOR) + base--; + +#ifdef G_OS_WIN32 + if (base == -1 && g_ascii_isalpha (file_name[0]) && file_name[1] == ':') + base = 1; +#endif /* G_OS_WIN32 */ + + len = last_nonslash - base; + retval = g_malloc (len + 1); + memcpy (retval, file_name + base + 1, len); + retval [len] = '\0'; + return retval; +} + +gboolean + g_path_is_absolute (const gchar *file_name) +{ + g_return_val_if_fail (file_name != NULL, FALSE); + + if (file_name[0] == G_DIR_SEPARATOR +#ifdef G_OS_WIN32 + || file_name[0] == '/' +#endif + ) + return TRUE; + +#ifdef G_OS_WIN32 + /* Recognize drive letter on native Windows */ + if (g_ascii_isalpha (file_name[0]) && file_name[1] == ':' && (file_name[2] == G_DIR_SEPARATOR || file_name[2] == '/')) + return TRUE; +#endif /* G_OS_WIN32 */ + + return FALSE; +} + +G_CONST_RETURN gchar* + g_path_skip_root (const gchar *file_name) +{ + g_return_val_if_fail (file_name != NULL, NULL); + +#ifdef G_PLATFORM_WIN32 + /* Skip \\server\share (Win32) or //server/share (Cygwin) */ + if (file_name[0] == G_DIR_SEPARATOR && + file_name[1] == G_DIR_SEPARATOR && + file_name[2]) + { + gchar *p; + + if ((p = strchr (file_name + 2, G_DIR_SEPARATOR)) > file_name + 2 && + p[1]) + { + file_name = p + 1; + + while (file_name[0] && file_name[0] != G_DIR_SEPARATOR) + file_name++; + + /* Possibly skip a backslash after the share name */ + if (file_name[0] == G_DIR_SEPARATOR) + file_name++; + + return (gchar *)file_name; + } + } +#endif + + /* Skip initial slashes */ + if (file_name[0] == G_DIR_SEPARATOR) + { + while (file_name[0] == G_DIR_SEPARATOR) + file_name++; + return (gchar *)file_name; + } + +#ifdef G_OS_WIN32 + /* Skip X:\ */ + if (g_ascii_isalpha (file_name[0]) && file_name[1] == ':' && file_name[2] == G_DIR_SEPARATOR) + return (gchar *)file_name + 3; +#endif + + return NULL; +} + +gchar* + g_path_get_dirname (const gchar *file_name) +{ + register gchar *base; + register gsize len; + + g_return_val_if_fail (file_name != NULL, NULL); + + base = strrchr (file_name, G_DIR_SEPARATOR); + if (!base) + return g_strdup ("."); + while (base > file_name && *base == G_DIR_SEPARATOR) + base--; + len = (guint) 1 + base - file_name; + + base = g_new (gchar, len + 1); + g_memmove (base, file_name, len); + base[len] = 0; + + return base; +} + +gchar* + g_get_current_dir (void) +{ + gchar *buffer = NULL; + gchar *dir = NULL; + static gulong max_len = 0; + + if (max_len == 0) + max_len = (G_PATH_LENGTH == -1) ? 2048 : G_PATH_LENGTH; + + /* We don't use getcwd(3) on SUNOS, because, it does a popen("pwd") + * and, if that wasn't bad enough, hangs in doing so. + */ +#if (defined (sun) && !defined (__SVR4)) || !defined(HAVE_GETCWD) + buffer = g_new (gchar, max_len + 1); + *buffer = 0; + dir = getwd (buffer); +#else /* !sun || !HAVE_GETCWD */ + while (max_len < G_MAXULONG / 2) + { + buffer = g_new (gchar, max_len + 1); + *buffer = 0; + dir = getcwd (buffer, max_len); + + if (dir || errno != ERANGE) + break; + + g_free (buffer); + max_len *= 2; + } +#endif /* !sun || !HAVE_GETCWD */ + + if (!dir || !*buffer) + { + /* hm, should we g_error() out here? + * this can happen if e.g. "./" has mode \0000 + */ + buffer[0] = G_DIR_SEPARATOR; + buffer[1] = 0; + } + + dir = g_strdup (buffer); + g_free (buffer); + + return dir; +} + +G_CONST_RETURN gchar* + g_getenv (const gchar *variable) +{ +#ifndef G_OS_WIN32 + g_return_val_if_fail (variable != NULL, NULL); + + return getenv (variable); +#else + G_LOCK_DEFINE_STATIC (getenv); + struct env_struct + { + gchar *key; + gchar *value; + } *env; + static GArray *environs = NULL; + gchar *system_env; + guint length, i; + gchar dummy[2]; + + g_return_val_if_fail (variable != NULL, NULL); + + G_LOCK (getenv); + + if (!environs) + environs = g_array_new (FALSE, FALSE, sizeof (struct env_struct)); + + /* First we try to find the envinronment variable inside the already + * found ones. + */ + + for (i = 0; i < environs->len; i++) + { + env = &g_array_index (environs, struct env_struct, i); + if (strcmp (env->key, variable) == 0) + { + g_assert (env->value); + G_UNLOCK (getenv); + return env->value; + } + } + + /* If not found, we ask the system */ + + system_env = getenv (variable); + if (!system_env) + { + G_UNLOCK (getenv); + return NULL; + } + + /* On Windows NT, it is relatively typical that environment variables + * contain references to other environment variables. Handle that by + * calling ExpandEnvironmentStrings. + */ + + g_array_set_size (environs, environs->len + 1); + + env = &g_array_index (environs, struct env_struct, environs->len - 1); + + /* First check how much space we need */ + length = ExpandEnvironmentStrings (system_env, dummy, 2); + + /* Then allocate that much, and actualy do the expansion and insert + * the new found pair into our buffer + */ + + env->value = g_malloc (length); + env->key = g_strdup (variable); + + ExpandEnvironmentStrings (system_env, env->value, length); + + G_UNLOCK (getenv); + return env->value; +#endif +} + + +G_LOCK_DEFINE_STATIC (g_utils_global); + +static gchar *g_tmp_dir = NULL; +static gchar *g_user_name = NULL; +static gchar *g_real_name = NULL; +static gchar *g_home_dir = NULL; + +/* HOLDS: g_utils_global_lock */ +static void + g_get_any_init (void) +{ + if (!g_tmp_dir) + { + g_tmp_dir = g_strdup (g_getenv ("TMPDIR")); + if (!g_tmp_dir) + g_tmp_dir = g_strdup (g_getenv ("TMP")); + if (!g_tmp_dir) + g_tmp_dir = g_strdup (g_getenv ("TEMP")); + +#ifdef P_tmpdir + if (!g_tmp_dir) + { + gsize k; + g_tmp_dir = g_strdup (P_tmpdir); + k = strlen (g_tmp_dir); + if (k > 1 && g_tmp_dir[k - 1] == G_DIR_SEPARATOR) + g_tmp_dir[k - 1] = '\0'; + } +#endif + + if (!g_tmp_dir) + { +#ifndef G_OS_WIN32 + g_tmp_dir = g_strdup ("/tmp"); +#else /* G_OS_WIN32 */ + g_tmp_dir = g_strdup ("C:\\"); +#endif /* G_OS_WIN32 */ + } + + if (!g_home_dir) + g_home_dir = g_strdup (g_getenv ("HOME")); + +#ifdef G_OS_WIN32 + /* In case HOME is Unix-style (it happens), convert it to + * Windows style. + */ + if (g_home_dir) + { + gchar *p; + while ((p = strchr (g_home_dir, '/')) != NULL) + *p = '\\'; + } + + if (!g_home_dir) + { + /* USERPROFILE is probably the closest equivalent to $HOME? */ + if (getenv ("USERPROFILE") != NULL) + g_home_dir = g_strdup (g_getenv ("USERPROFILE")); + } + + if (!g_home_dir) + { + /* At least at some time, HOMEDRIVE and HOMEPATH were used + * to point to the home directory, I think. But on Windows + * 2000 HOMEDRIVE seems to be equal to SYSTEMDRIVE, and + * HOMEPATH is its root "\"? + */ + if (getenv ("HOMEDRIVE") != NULL && getenv ("HOMEPATH") != NULL) + { + gchar *homedrive, *homepath; + + homedrive = g_strdup (g_getenv ("HOMEDRIVE")); + homepath = g_strdup (g_getenv ("HOMEPATH")); + + g_home_dir = g_strconcat (homedrive, homepath, NULL); + g_free (homedrive); + g_free (homepath); + } + } +#endif /* G_OS_WIN32 */ + +#ifdef HAVE_PWD_H + { + struct passwd *pw = NULL; + gpointer buffer = NULL; + gint error; + +# if defined (HAVE_POSIX_GETPWUID_R) || defined (HAVE_NONPOSIX_GETPWUID_R) + struct passwd pwd; +# ifdef _SC_GETPW_R_SIZE_MAX + /* This reurns the maximum length */ + glong bufsize = sysconf (_SC_GETPW_R_SIZE_MAX); + + if (bufsize < 0) + bufsize = 64; +# else /* _SC_GETPW_R_SIZE_MAX */ + glong bufsize = 64; +# endif /* _SC_GETPW_R_SIZE_MAX */ + + do + { + g_free (buffer); + buffer = g_malloc (bufsize); + errno = 0; + +# ifdef HAVE_POSIX_GETPWUID_R + error = getpwuid_r (getuid (), &pwd, buffer, bufsize, &pw); + error = error < 0 ? errno : error; +# else /* HAVE_NONPOSIX_GETPWUID_R */ +# ifdef _AIX + error = getpwuid_r (getuid (), &pwd, buffer, bufsize); + pw = error == 0 ? &pwd : NULL; +# else /* !_AIX */ + pw = getpwuid_r (getuid (), &pwd, buffer, bufsize); + error = pw ? 0 : errno; +# endif /* !_AIX */ +# endif /* HAVE_NONPOSIX_GETPWUID_R */ + + if (!pw) + { + /* we bail out prematurely if the user id can't be found + * (should be pretty rare case actually), or if the buffer + * should be sufficiently big and lookups are still not + * successfull. + */ + if (error == 0 || error == ENOENT) + { + g_warning ("getpwuid_r(): failed due to unknown user id (%lu)", + (gulong) getuid ()); + break; + } + if (bufsize > 32 * 1024) + { + g_warning ("getpwuid_r(): failed due to: %s.", + g_strerror (error)); + break; + } + + bufsize *= 2; + } + } + while (!pw); +# endif /* HAVE_POSIX_GETPWUID_R || HAVE_NONPOSIX_GETPWUID_R */ + + if (!pw) + { + setpwent (); + pw = getpwuid (getuid ()); + endpwent (); + } + if (pw) + { + g_user_name = g_strdup (pw->pw_name); + g_real_name = g_strdup (pw->pw_gecos); + if (!g_home_dir) + g_home_dir = g_strdup (pw->pw_dir); + } + g_free (buffer); + } + +#else /* !HAVE_PWD_H */ + +# ifdef G_OS_WIN32 + { + guint len = 17; + gchar buffer[17]; + + if (GetUserName ((LPTSTR) buffer, (LPDWORD) &len)) + { + g_user_name = g_strdup (buffer); + g_real_name = g_strdup (buffer); + } + } +# endif /* G_OS_WIN32 */ + +#endif /* !HAVE_PWD_H */ + +#ifdef __EMX__ + /* change '\\' in %HOME% to '/' */ + g_strdelimit (g_home_dir, "\\",'/'); +#endif + if (!g_user_name) + g_user_name = g_strdup ("somebody"); + if (!g_real_name) + g_real_name = g_strdup ("Unknown"); + else + { + gchar *p; + + for (p = g_real_name; *p; p++) + if (*p == ',') + { + *p = 0; + p = g_strdup (g_real_name); + g_free (g_real_name); + g_real_name = p; + break; + } + } + } +} + +G_CONST_RETURN gchar* + g_get_user_name (void) +{ + G_LOCK (g_utils_global); + if (!g_tmp_dir) + g_get_any_init (); + G_UNLOCK (g_utils_global); + + return g_user_name; +} + +G_CONST_RETURN gchar* + g_get_real_name (void) +{ + G_LOCK (g_utils_global); + if (!g_tmp_dir) + g_get_any_init (); + G_UNLOCK (g_utils_global); + + return g_real_name; +} + +/* Return the home directory of the user. If there is a HOME +* environment variable, its value is returned, otherwise use some +* system-dependent way of finding it out. If no home directory can be +* deduced, return NULL. +*/ + +G_CONST_RETURN gchar* + g_get_home_dir (void) +{ + G_LOCK (g_utils_global); + if (!g_tmp_dir) + g_get_any_init (); + G_UNLOCK (g_utils_global); + + return g_home_dir; +} + +/* Return a directory to be used to store temporary files. This is the +* value of the TMPDIR, TMP or TEMP environment variables (they are +* checked in that order). If none of those exist, use P_tmpdir from +* stdio.h. If that isn't defined, return "/tmp" on POSIXly systems, +* and C:\ on Windows. +*/ + +G_CONST_RETURN gchar* + g_get_tmp_dir (void) +{ + G_LOCK (g_utils_global); + if (!g_tmp_dir) + g_get_any_init (); + G_UNLOCK (g_utils_global); + + return g_tmp_dir; +} + +static gchar *g_prgname = NULL; + +gchar* + g_get_prgname (void) +{ + gchar* retval; + + G_LOCK (g_utils_global); + retval = g_prgname; + G_UNLOCK (g_utils_global); + + return retval; +} + +void + g_set_prgname (const gchar *prgname) +{ + gchar *c; + + G_LOCK (g_utils_global); + c = g_prgname; + g_prgname = g_strdup (prgname); + g_free (c); + G_UNLOCK (g_utils_global); +} + +guint + g_direct_hash (gconstpointer v) +{ + return GPOINTER_TO_UINT (v); +} + +gboolean + g_direct_equal (gconstpointer v1, + gconstpointer v2) +{ + return v1 == v2; +} + +gboolean + g_int_equal (gconstpointer v1, + gconstpointer v2) +{ + return *((const gint*) v1) == *((const gint*) v2); +} + +guint + g_int_hash (gconstpointer v) +{ + return *(const gint*) v; +} + +/** +* g_nullify_pointer: +* @nullify_location: the memory address of the pointer. +* +* Set the pointer at the specified location to %NULL. +**/ +void + g_nullify_pointer (gpointer *nullify_location) +{ + g_return_if_fail (nullify_location != NULL); + + *nullify_location = NULL; +} + +/** +* g_get_codeset: +* +* Get the codeset for the current locale. +* +* Return value: a newly allocated string containing the name +* of the codeset. This string must be freed with g_free(). +**/ +gchar * + g_get_codeset (void) +{ +#ifdef HAVE_CODESET + char *result = nl_langinfo (CODESET); + return g_strdup (result); +#else +#ifdef G_PLATFORM_WIN32 + return g_strdup_printf ("CP%d", GetACP ()); +#else + /* FIXME: Do something more intelligent based on setlocale (LC_CTYPE, NULL) + */ + return g_strdup ("ISO-8859-1"); +#endif +#endif +} + +#ifdef ENABLE_NLS + +#include <libintl.h> + + +#ifdef G_OS_WIN32 + +/* On Windows we don't want any hard-coded path names */ + +#undef GLIB_LOCALE_DIR +/* It's OK to leak the g_win32_get_...() and g_strdup_printf() results +* below, as this macro is called only once. */ +#define GLIB_LOCALE_DIR \ + g_win32_get_package_installation_subdirectory \ + (GETTEXT_PACKAGE, \ + g_strdup_printf ("libglib-%d.%d-%d.dll", \ + GLIB_MAJOR_VERSION, \ + GLIB_MINOR_VERSION, \ + GLIB_MICRO_VERSION - GLIB_BINARY_AGE), \ + "share\\locale") + +#endif /* !G_OS_WIN32 */ + +G_CONST_RETURN gchar * + _glib_gettext (const gchar *str) +{ + static gboolean _glib_gettext_initialized = FALSE; + + if (!_glib_gettext_initialized) + { + bindtextdomain(GETTEXT_PACKAGE, GLIB_LOCALE_DIR); + _glib_gettext_initialized = TRUE; + } + + return dgettext (GETTEXT_PACKAGE, str); +} + +#endif /* ENABLE_NLS */ + + diff --git a/graf2d/win32gdk/gdk/src/glib/gutils.h b/graf2d/win32gdk/gdk/src/glib/gutils.h index 25f9796f8b113..f449483843a4c 100644 --- a/graf2d/win32gdk/gdk/src/glib/gutils.h +++ b/graf2d/win32gdk/gdk/src/glib/gutils.h @@ -27,7 +27,7 @@ #ifndef __G_UTILS_H__ #define __G_UTILS_H__ -#include <g_types.h> +#include <glib/gtypes.h> #include <stdarg.h> G_BEGIN_DECLS @@ -113,12 +113,12 @@ G_BEGIN_DECLS /* Retrive static string info */ -gchar* g_get_user_name (void); -gchar* g_get_real_name (void); -gchar* g_get_home_dir (void); -gchar* g_get_tmp_dir (void); -gchar* g_get_prgname (void); -void g_set_prgname (const gchar *prgname); +G_CONST_RETURN gchar* g_get_user_name (void); +G_CONST_RETURN gchar* g_get_real_name (void); +G_CONST_RETURN gchar* g_get_home_dir (void); +G_CONST_RETURN gchar* g_get_tmp_dir (void); +gchar* g_get_prgname (void); +void g_set_prgname (const gchar *prgname); typedef struct _GDebugKey GDebugKey; @@ -130,40 +130,51 @@ struct _GDebugKey /* Miscellaneous utility functions */ -guint g_parse_debug_string (const gchar *string, - GDebugKey *keys, - guint nkeys); -gint g_snprintf (gchar *string, - gulong n, - gchar const *format, - ...) G_GNUC_PRINTF (3, 4); -gint g_vsnprintf (gchar *string, - gulong n, - gchar const *format, - va_list args); +guint g_parse_debug_string (const gchar *string, + const GDebugKey *keys, + guint nkeys); + +gint g_snprintf (gchar *string, + gulong n, + gchar const *format, + ...) G_GNUC_PRINTF (3, 4); +gint g_vsnprintf (gchar *string, + gulong n, + gchar const *format, + va_list args); + /* Check if a file name is an absolute path */ -gboolean g_path_is_absolute (const gchar *file_name); +gboolean g_path_is_absolute (const gchar *file_name); + /* In case of absolute paths, skip the root part */ -gchar* g_path_skip_root (gchar *file_name); +G_CONST_RETURN gchar* g_path_skip_root (const gchar *file_name); + +#ifndef G_DISABLE_DEPRECATED /* These two functions are deprecated and will be removed in the next * major release of GLib. Use g_path_get_dirname/g_path_get_basename * instead. Whatch out! The string returned by g_path_get_basename * must be g_freed, while the string returned by g_basename must not.*/ -gchar* g_basename (const gchar *file_name); -gchar* g_dirname (const gchar *file_name); +G_CONST_RETURN gchar* g_basename (const gchar *file_name); +#define g_dirname g_path_get_dirname + +#endif /* G_DISABLE_DEPRECATED */ /* The returned strings are newly allocated with g_malloc() */ -gchar* g_get_current_dir (void); -gchar* g_path_get_basename (const gchar *file_name); -gchar* g_path_get_dirname (const gchar *file_name); +gchar* g_get_current_dir (void); +gchar* g_path_get_basename (const gchar *file_name); +gchar* g_path_get_dirname (const gchar *file_name); + + +/* Set the pointer at the specified location to NULL */ +void g_nullify_pointer (gpointer *nullify_location); /* Get the codeset for the current locale */ /* gchar * g_get_codeset (void); */ /* return the environment string for the variable. The returned memory * must not be freed. */ -gchar* g_getenv (const gchar *variable); +G_CONST_RETURN gchar* g_getenv (const gchar *variable); /* we try to provide a usefull equivalent for ATEXIT if it is @@ -188,11 +199,11 @@ gchar* g_find_program_in_path (const gchar *program); /* Bit tests */ -G_INLINE_FUNC gint g_bit_nth_lsf (guint32 mask, +G_INLINE_FUNC gint g_bit_nth_lsf (gulong mask, gint nth_bit); -G_INLINE_FUNC gint g_bit_nth_msf (guint32 mask, +G_INLINE_FUNC gint g_bit_nth_msf (gulong mask, gint nth_bit); -G_INLINE_FUNC guint g_bit_storage (guint number); +G_INLINE_FUNC guint g_bit_storage (gulong number); /* Trash Stacks * elements need to be >= sizeof (gpointer) @@ -213,35 +224,35 @@ G_INLINE_FUNC guint g_trash_stack_height (GTrashStack **stack_p); */ #if defined (G_CAN_INLINE) || defined (__G_UTILS_C__) G_INLINE_FUNC gint -g_bit_nth_lsf (guint32 mask, - gint nth_bit) +g_bit_nth_lsf (gulong mask, + gint nth_bit) { do { nth_bit++; - if (mask & (1 << (guint) nth_bit)) + if (mask & (1 << (gulong) nth_bit)) return nth_bit; } while (nth_bit < 32); return -1; } G_INLINE_FUNC gint -g_bit_nth_msf (guint32 mask, - gint nth_bit) +g_bit_nth_msf (gulong mask, + gint nth_bit) { if (nth_bit < 0) - nth_bit = 32; + nth_bit = GLIB_SIZEOF_LONG * 8; do { nth_bit--; - if (mask & (1 << (guint) nth_bit)) + if (mask & (1 << (gulong) nth_bit)) return nth_bit; } while (nth_bit > 0); return -1; } G_INLINE_FUNC guint -g_bit_storage (guint number) +g_bit_storage (gulong number) { register guint n_bits = 0; @@ -305,16 +316,6 @@ g_trash_stack_height (GTrashStack **stack_p) * we prefix variable declarations so they can * properly get exported in windows dlls. */ -#ifdef G_OS_WIN32 -# ifdef GLIB_COMPILATION -# define GLIB_VAR __declspec(dllexport) -# else /* !GLIB_COMPILATION */ -# define GLIB_VAR extern __declspec(dllimport) -# endif /* !GLIB_COMPILATION */ -#else /* !G_OS_WIN32 */ -# define GLIB_VAR extern -#endif /* !G_OS_WIN32 */ - GLIB_VAR const guint glib_major_version; GLIB_VAR const guint glib_minor_version; GLIB_VAR const guint glib_micro_version; diff --git a/graf2d/win32gdk/gdk/src/glib/gwin32.c b/graf2d/win32gdk/gdk/src/glib/gwin32.c new file mode 100644 index 0000000000000..42e2b5ec606c8 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/gwin32.c @@ -0,0 +1,837 @@ +/* GLIB - Library of useful routines for C programming + * Copyright (C) 1995-1998 Peter Mattis, Spencer Kimball and Josh MacDonald + * Copyright (C) 1998-1999 Tor Lillqvist + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +/* + * Modified by the GLib Team and others 1997-2000. See the AUTHORS + * file for a list of people on the GLib Team. See the ChangeLog + * files for a list of changes. These files are distributed with + * GLib at ftp://ftp.gtk.org/pub/gtk/. + */ + +/* + * MT safe for the unix part, FIXME: make the win32 part MT safe as well. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include "glibconfig.h" + +#include <stdlib.h> +#include <stdio.h> +#include <string.h> +#include <errno.h> + +#define STRICT /* Strict typing, please */ +#include <windows.h> +#undef STRICT +#ifndef G_WITH_CYGWIN +#include <direct.h> +#endif +#include <errno.h> +#include <ctype.h> +#ifdef _MSC_VER +# include <io.h> +#endif /* _MSC_VER */ + +#include "glib.h" + +#ifdef G_WITH_CYGWIN +#include <sys/cygwin.h> +#endif + +#ifndef G_WITH_CYGWIN + +gint +g_win32_ftruncate (gint fd, + guint size) +{ + HANDLE hfile; + guint curpos; + + g_return_val_if_fail (fd >= 0, -1); + + hfile = (HANDLE) _get_osfhandle (fd); + curpos = SetFilePointer (hfile, 0, NULL, FILE_CURRENT); + if (curpos == 0xFFFFFFFF + || SetFilePointer (hfile, size, NULL, FILE_BEGIN) == 0xFFFFFFFF + || !SetEndOfFile (hfile)) + { + gint error = GetLastError (); + + switch (error) + { + case ERROR_INVALID_HANDLE: + errno = EBADF; + break; + default: + errno = EIO; + break; + } + + return -1; + } + + return 0; +} + +DIR* +g_win32_opendir (const char *dirname) +{ + DIR *result; + gchar *mask; + guint k; + + g_return_val_if_fail (dirname != NULL, NULL); + + result = g_new0 (DIR, 1); + result->find_file_data = g_new0 (WIN32_FIND_DATA, 1); + result->dir_name = g_strdup (dirname); + + k = strlen (result->dir_name); + if (k && result->dir_name[k - 1] == '\\') + { + result->dir_name[k - 1] = '\0'; + } + mask = g_strdup_printf ("%s\\*", result->dir_name); + + result->find_file_handle = (guint) FindFirstFile (mask, + (LPWIN32_FIND_DATA) result->find_file_data); + g_free (mask); + + if (result->find_file_handle == (guint) INVALID_HANDLE_VALUE) + { + int error = GetLastError (); + + g_free (result->dir_name); + g_free (result->find_file_data); + g_free (result); + switch (error) + { + default: + errno = EIO; + return NULL; + } + } + result->just_opened = TRUE; + + return result; +} + +struct dirent* +g_win32_readdir (DIR *dir) +{ + gchar *basename; + + g_return_val_if_fail (dir != NULL, NULL); + + if (dir->just_opened) + dir->just_opened = FALSE; + else + { + if (!FindNextFile ((HANDLE) dir->find_file_handle, + (LPWIN32_FIND_DATA) dir->find_file_data)) + { + int error = GetLastError (); + + switch (error) + { + case ERROR_NO_MORE_FILES: + return NULL; + default: + errno = EIO; + return NULL; + } + } + } + + basename = g_path_get_basename (((LPWIN32_FIND_DATA) dir->find_file_data)->cFileName); + + strcpy (dir->readdir_result.d_name, basename); + + g_free (basename); + + return &dir->readdir_result; +} + +void +g_win32_rewinddir (DIR *dir) +{ + gchar *mask; + + g_return_if_fail (dir != NULL); + + if (!FindClose ((HANDLE) dir->find_file_handle)) + g_warning ("gwin_rewinddir(): FindClose() failed\n"); + + mask = g_strdup_printf ("%s\\*", dir->dir_name); + dir->find_file_handle = (guint) FindFirstFile (mask, + (LPWIN32_FIND_DATA) dir->find_file_data); + g_free (mask); + + if (dir->find_file_handle == (guint) INVALID_HANDLE_VALUE) + { + int error = GetLastError (); + + switch (error) + { + default: + errno = EIO; + return; + } + } + dir->just_opened = TRUE; +} + +gint +g_win32_closedir (DIR *dir) +{ + g_return_val_if_fail (dir != NULL, -1); + + if (!FindClose ((HANDLE) dir->find_file_handle)) + { + int error = GetLastError (); + + switch (error) + { + default: + errno = EIO; return -1; + } + } + + g_free (dir->dir_name); + g_free (dir->find_file_data); + g_free (dir); + + return 0; +} +#endif + +/* msvc 5.0 headers don't have latest language and sublanguage codes */ +#ifndef LANG_ARMENIAN +#define LANG_ARMENIAN 0x2b +#endif +#ifndef LANG_ASSAMESE +#define LANG_ASSAMESE 0x4d +#endif +#ifndef LANG_AZERI +#define LANG_AZERI 0x2c +#endif +#ifndef LANG_BENGALI +#define LANG_BENGALI 0x45 +#endif +#ifndef LANG_GEORGIAN +#define LANG_GEORGIAN 0x37 +#endif +#ifndef LANG_GUJARATI +#define LANG_GUJARATI 0x47 +#endif +#ifndef LANG_HINDI +#define LANG_HINDI 0x39 +#endif +#ifndef LANG_KANNADA +#define LANG_KANNADA 0x4b +#endif +#ifndef LANG_KASHMIRI +#define LANG_KASHMIRI 0x60 +#endif +#ifndef LANG_KAZAK +#define LANG_KAZAK 0x3f +#endif +#ifndef LANG_KONKANI +#define LANG_KONKANI 0x57 +#endif +#ifndef LANG_MACEDONIAN +#define LANG_MACEDONIAN 0x2f +#endif +#ifndef LANG_MALAY +#define LANG_MALAY 0x3e +#endif +#ifndef LANG_MALAYALAM +#define LANG_MALAYALAM 0x4c +#endif +#ifndef LANG_MANIPURI +#define LANG_MANIPURI 0x58 +#endif +#ifndef LANG_MARATHI +#define LANG_MARATHI 0x4e +#endif +#ifndef LANG_NEPALI +#define LANG_NEPALI 0x61 +#endif +#ifndef LANG_ORIYA +#define LANG_ORIYA 0x48 +#endif +#ifndef LANG_PUNJABI +#define LANG_PUNJABI 0x46 +#endif +#ifndef LANG_SANSKRIT +#define LANG_SANSKRIT 0x4f +#endif +#ifndef LANG_SINDHI +#define LANG_SINDHI 0x59 +#endif +#ifndef LANG_SWAHILI +#define LANG_SWAHILI 0x41 +#endif +#ifndef LANG_TAMIL +#define LANG_TAMIL 0x49 +#endif +#ifndef LANG_TATAR +#define LANG_TATAR 0x44 +#endif +#ifndef LANG_TELUGU +#define LANG_TELUGU 0x4a +#endif +#ifndef LANG_URDU +#define LANG_URDU 0x20 +#endif +#ifndef LANG_UZBEK +#define LANG_UZBEK 0x43 +#endif + +#ifndef SUBLANG_CHINESE_MACAU +#define SUBLANG_CHINESE_MACAU 0x05 +#endif +#ifndef SUBLANG_ENGLISH_ZIMBABWE +#define SUBLANG_ENGLISH_ZIMBABWE 0x0c +#endif +#ifndef SUBLANG_ENGLISH_PHILIPPINES +#define SUBLANG_ENGLISH_PHILIPPINES 0x0d +#endif +#ifndef SUBLANG_FRENCH_MONACO +#define SUBLANG_FRENCH_MONACO 0x06 +#endif +#ifndef SUBLANG_KASHMIRI_INDIA +#define SUBLANG_KASHMIRI_INDIA 0x02 +#endif +#ifndef SUBLANG_MALAY_BRUNEI_DARUSSALAM +#define SUBLANG_MALAY_BRUNEI_DARUSSALAM 0x02 +#endif +#ifndef SUBLANG_NEPALI_INDIA +#define SUBLANG_NEPALI_INDIA 0x02 +#endif +#ifndef SUBLANG_URDU_PAKISTAN +#define SUBLANG_URDU_PAKISTAN 0x01 +#endif +#ifndef SUBLANG_URDU_INDIA +#define SUBLANG_URDU_INDIA 0x02 +#endif +#ifndef SUBLANG_UZBEK_CYRILLIC +#define SUBLANG_UZBEK_CYRILLIC 0x02 +#endif + +/** + * g_win32_getlocale: + * + * The setlocale in the Microsoft C library uses locale names of the + * form "English_United States.1252" etc. We want the Unixish standard + * form "en", "zh_TW" etc. This function gets the current thread + * locale from Windows and returns it as a string of the above form + * for use in forming file names etc. The returned string should be + * deallocated with g_free(). + * + * Returns: allocated locale name + */ + +gchar * +g_win32_getlocale (void) +{ + LCID lcid; + gchar *ev; + gint primary, sub; + gchar *l = NULL, *sl = NULL; + gchar bfr[20]; + + if ((ev = getenv ("LC_ALL")) != NULL + || (ev = getenv ("LC_CTYPE")) != NULL + || (ev = getenv ("LANG")) != NULL) + return g_strdup (ev); + + lcid = GetThreadLocale (); + primary = PRIMARYLANGID (LANGIDFROMLCID (lcid)); + sub = SUBLANGID (LANGIDFROMLCID (lcid)); + switch (primary) + { + case LANG_AFRIKAANS: l = "af"; break; + case LANG_ALBANIAN: l = "sq"; break; + case LANG_ARABIC: + l = "ar"; + switch (sub) + { + case SUBLANG_ARABIC_SAUDI_ARABIA: sl = "SA"; break; + case SUBLANG_ARABIC_IRAQ: sl = "IQ"; break; + case SUBLANG_ARABIC_EGYPT: sl = "EG"; break; + case SUBLANG_ARABIC_LIBYA: sl = "LY"; break; + case SUBLANG_ARABIC_ALGERIA: sl = "DZ"; break; + case SUBLANG_ARABIC_MOROCCO: sl = "MA"; break; + case SUBLANG_ARABIC_TUNISIA: sl = "TN"; break; + case SUBLANG_ARABIC_OMAN: sl = "OM"; break; + case SUBLANG_ARABIC_YEMEN: sl = "YE"; break; + case SUBLANG_ARABIC_SYRIA: sl = "SY"; break; + case SUBLANG_ARABIC_JORDAN: sl = "JO"; break; + case SUBLANG_ARABIC_LEBANON: sl = "LB"; break; + case SUBLANG_ARABIC_KUWAIT: sl = "KW"; break; + case SUBLANG_ARABIC_UAE: sl = "AE"; break; + case SUBLANG_ARABIC_BAHRAIN: sl = "BH"; break; + case SUBLANG_ARABIC_QATAR: sl = "QA"; break; + } + break; + case LANG_ARMENIAN: l = "hy"; break; + case LANG_ASSAMESE: l = "as"; break; + case LANG_AZERI: l = "az"; break; + case LANG_BASQUE: l = "eu"; break; + case LANG_BELARUSIAN: l = "be"; break; + case LANG_BENGALI: l = "bn"; break; + case LANG_BULGARIAN: l = "bg"; break; + case LANG_CATALAN: l = "ca"; break; + case LANG_CHINESE: + l = "zh"; + switch (sub) + { + case SUBLANG_CHINESE_TRADITIONAL: sl = "TW"; break; + case SUBLANG_CHINESE_SIMPLIFIED: sl = "CH"; break; + case SUBLANG_CHINESE_HONGKONG: sl = "HK"; break; + case SUBLANG_CHINESE_SINGAPORE: sl = "SG"; break; + case SUBLANG_CHINESE_MACAU: sl = "MO"; break; + } + break; + case LANG_CROATIAN: /* LANG_CROATIAN == LANG_SERBIAN + * What used to be called Serbo-Croatian + * should really now be two separate + * languages because of political reasons. + * (Says tml, who knows nothing about Serbian + * or Croatian.) + * (I can feel those flames coming already.) + */ + switch (sub) + { + case SUBLANG_SERBIAN_LATIN: l = "sp"; break; + case SUBLANG_SERBIAN_CYRILLIC: l = "sr"; break; + default: l = "hr"; /* ??? */ + } + break; + case LANG_CZECH: l = "cs"; break; + case LANG_DANISH: l = "da"; break; + case LANG_DUTCH: + l = "nl"; + switch (sub) + { + case SUBLANG_DUTCH_BELGIAN: sl = "BE"; break; + } + break; + case LANG_ENGLISH: + l = "en"; + switch (sub) + { + /* SUBLANG_ENGLISH_US == SUBLANG_DEFAULT. Heh. I thought + * English was the language spoken in England. + * Oh well. + */ + case SUBLANG_ENGLISH_UK: sl = "GB"; break; + case SUBLANG_ENGLISH_AUS: sl = "AU"; break; + case SUBLANG_ENGLISH_CAN: sl = "CA"; break; + case SUBLANG_ENGLISH_NZ: sl = "NZ"; break; + case SUBLANG_ENGLISH_EIRE: sl = "IE"; break; + case SUBLANG_ENGLISH_SOUTH_AFRICA: sl = "ZA"; break; + case SUBLANG_ENGLISH_JAMAICA: sl = "JM"; break; + case SUBLANG_ENGLISH_CARIBBEAN: sl = "@caribbean"; break; /* ??? */ + case SUBLANG_ENGLISH_BELIZE: sl = "BZ"; break; + case SUBLANG_ENGLISH_TRINIDAD: sl = "TT"; break; + case SUBLANG_ENGLISH_ZIMBABWE: sl = "ZW"; break; + case SUBLANG_ENGLISH_PHILIPPINES: sl = "PH"; break; + } + break; + case LANG_ESTONIAN: l = "et"; break; + case LANG_FAEROESE: l = "fo"; break; + case LANG_FARSI: l = "fa"; break; + case LANG_FINNISH: l = "fi"; break; + case LANG_FRENCH: + l = "fr"; + switch (sub) + { + case SUBLANG_FRENCH_BELGIAN: sl = "BE"; break; + case SUBLANG_FRENCH_CANADIAN: sl = "CA"; break; + case SUBLANG_FRENCH_SWISS: sl = "CH"; break; + case SUBLANG_FRENCH_LUXEMBOURG: sl = "LU"; break; + case SUBLANG_FRENCH_MONACO: sl = "MC"; break; + } + break; + case LANG_GEORGIAN: l = "ka"; break; + case LANG_GERMAN: + l = "de"; + switch (sub) + { + case SUBLANG_GERMAN_SWISS: sl = "CH"; break; + case SUBLANG_GERMAN_AUSTRIAN: sl = "AT"; break; + case SUBLANG_GERMAN_LUXEMBOURG: sl = "LU"; break; + case SUBLANG_GERMAN_LIECHTENSTEIN: sl = "LI"; break; + } + break; + case LANG_GREEK: l = "el"; break; + case LANG_GUJARATI: l = "gu"; break; + case LANG_HEBREW: l = "he"; break; + case LANG_HINDI: l = "hi"; break; + case LANG_HUNGARIAN: l = "hu"; break; + case LANG_ICELANDIC: l = "is"; break; + case LANG_INDONESIAN: l = "id"; break; + case LANG_ITALIAN: + l = "it"; + switch (sub) + { + case SUBLANG_ITALIAN_SWISS: sl = "CH"; break; + } + break; + case LANG_JAPANESE: l = "ja"; break; + case LANG_KANNADA: l = "kn"; break; + case LANG_KASHMIRI: + l = "ks"; + switch (sub) + { + case SUBLANG_KASHMIRI_INDIA: sl = "IN"; break; + } + break; + case LANG_KAZAK: l = "kk"; break; + case LANG_KONKANI: l = "kok"; break; /* ??? */ + case LANG_KOREAN: l = "ko"; break; + case LANG_LATVIAN: l = "lv"; break; + case LANG_LITHUANIAN: l = "lt"; break; + case LANG_MACEDONIAN: l = "mk"; break; + case LANG_MALAY: + l = "ms"; + switch (sub) + { + case SUBLANG_MALAY_BRUNEI_DARUSSALAM: sl = "BN"; break; + } + break; + case LANG_MALAYALAM: l = "ml"; break; + case LANG_MANIPURI: l = "mni"; break; + case LANG_MARATHI: l = "mr"; break; + case LANG_NEPALI: + l = "ne"; + switch (sub) + { + case SUBLANG_NEPALI_INDIA: sl = "IN"; break; + } + break; + case LANG_NORWEGIAN: + l = "no"; + switch (sub) + { + /* SUBLANG_NORWEGIAN_BOKMAL == SUBLANG_DEFAULT */ + case SUBLANG_NORWEGIAN_NYNORSK: l = "nn"; break; + } + break; + case LANG_ORIYA: l = "or"; break; + case LANG_POLISH: l = "pl"; break; + case LANG_PORTUGUESE: + l = "pt"; + switch (sub) + { + /* Hmm. SUBLANG_PORTUGUESE_BRAZILIAN == SUBLANG_DEFAULT */ + case SUBLANG_PORTUGUESE_BRAZILIAN: sl = "BR"; break; + } + break; + case LANG_PUNJABI: l = "pa"; break; + case LANG_ROMANIAN: l = "ro"; break; + case LANG_RUSSIAN: l = "ru"; break; + case LANG_SANSKRIT: l = "sa"; break; + case LANG_SINDHI: l = "sd"; break; + case LANG_SLOVAK: l = "sk"; break; + case LANG_SLOVENIAN: l = "sl"; break; + case LANG_SPANISH: + l = "es"; + switch (sub) + { + case SUBLANG_SPANISH_MEXICAN: sl = "MX"; break; + case SUBLANG_SPANISH_MODERN: sl = "@modern"; break; /* ??? */ + case SUBLANG_SPANISH_GUATEMALA: sl = "GT"; break; + case SUBLANG_SPANISH_COSTA_RICA: sl = "CR"; break; + case SUBLANG_SPANISH_PANAMA: sl = "PA"; break; + case SUBLANG_SPANISH_DOMINICAN_REPUBLIC: sl = "DO"; break; + case SUBLANG_SPANISH_VENEZUELA: sl = "VE"; break; + case SUBLANG_SPANISH_COLOMBIA: sl = "CO"; break; + case SUBLANG_SPANISH_PERU: sl = "PE"; break; + case SUBLANG_SPANISH_ARGENTINA: sl = "AR"; break; + case SUBLANG_SPANISH_ECUADOR: sl = "EC"; break; + case SUBLANG_SPANISH_CHILE: sl = "CL"; break; + case SUBLANG_SPANISH_URUGUAY: sl = "UY"; break; + case SUBLANG_SPANISH_PARAGUAY: sl = "PY"; break; + case SUBLANG_SPANISH_BOLIVIA: sl = "BO"; break; + case SUBLANG_SPANISH_EL_SALVADOR: sl = "SV"; break; + case SUBLANG_SPANISH_HONDURAS: sl = "HN"; break; + case SUBLANG_SPANISH_NICARAGUA: sl = "NI"; break; + case SUBLANG_SPANISH_PUERTO_RICO: sl = "PR"; break; + } + break; + case LANG_SWAHILI: l = "sw"; break; + case LANG_SWEDISH: + l = "sv"; + switch (sub) + { + case SUBLANG_SWEDISH_FINLAND: sl = "FI"; break; + } + break; + case LANG_TAMIL: l = "ta"; break; + case LANG_TATAR: l = "tt"; break; + case LANG_TELUGU: l = "te"; break; + case LANG_THAI: l = "th"; break; + case LANG_TURKISH: l = "tr"; break; + case LANG_UKRAINIAN: l = "uk"; break; + case LANG_URDU: + l = "ur"; + switch (sub) + { + case SUBLANG_URDU_PAKISTAN: sl = "PK"; break; + case SUBLANG_URDU_INDIA: sl = "IN"; break; + } + break; + case LANG_UZBEK: + l = "uz"; + switch (sub) + { + case SUBLANG_UZBEK_CYRILLIC: sl = "@cyrillic"; break; + } + break; + case LANG_VIETNAMESE: l = "vi"; break; + default: l = "xx"; break; + } + strcpy (bfr, l); + if (sl != NULL) + { + if (sl[0] != '@') + strcat (bfr, "_"); + strcat (bfr, sl); + } + + return g_strdup (bfr); +} + +/** + * g_win32_error_message: + * @error: error code + * + * Translate a Win32 error code (as returned by GetLastError()) into + * the corresponding message. The message is either language neutral, + * or in the thread's language, or the user's language, the system's + * langauge, or US English (see docs for FormatMessage). The returned + * string should be deallocated with g_free(). + * + * Returns: allocated error message + */ +gchar * +g_win32_error_message (gint error) +{ + gchar *msg; + gchar *retval; + int nbytes; + + FormatMessage (FORMAT_MESSAGE_ALLOCATE_BUFFER + |FORMAT_MESSAGE_IGNORE_INSERTS + |FORMAT_MESSAGE_FROM_SYSTEM, + NULL, error, 0, + (LPTSTR) &msg, 0, NULL); + nbytes = strlen (msg); + + if (nbytes > 2 && msg[nbytes-1] == '\n' && msg[nbytes-2] == '\r') + msg[nbytes-2] = '\0'; + + retval = g_strdup (msg); + + if (msg != NULL) + LocalFree (msg); + + return retval; +} + +static gchar * +get_package_directory_from_module (gchar *module_name) +{ + static GHashTable *module_dirs = NULL; + HMODULE hmodule = NULL; + gchar *fn; + gchar *p; + gchar *result; + + if (module_dirs == NULL) + module_dirs = g_hash_table_new (g_str_hash, g_str_equal); + + result = g_hash_table_lookup (module_dirs, module_name ? module_name : ""); + + if (result) + return g_strdup (result); + + if (module_name) + { + hmodule = GetModuleHandle (module_name); + if (!hmodule) + return NULL; + } + + fn = g_malloc (MAX_PATH); + if (!GetModuleFileName (hmodule, fn, MAX_PATH)) + return NULL; + +#ifdef G_WITH_CYGWIN + /* In Cygwin we need to have POSIX paths */ + { + gchar tmp[MAX_PATH]; + + cygwin_conv_to_posix_path(fn, tmp); + g_free(fn); + fn = g_strdup(tmp); + } +#endif + + if ((p = strrchr (fn, G_DIR_SEPARATOR)) != NULL) + *p = '\0'; + + p = strrchr (fn, G_DIR_SEPARATOR); + if (p && (g_ascii_strcasecmp (p + 1, "bin") == 0 || + g_ascii_strcasecmp (p + 1, "lib") == 0)) + *p = '\0'; + + g_hash_table_insert (module_dirs, module_name ? module_name : "", fn); + + return g_strdup (fn); +} + +/** + * g_win32_get_package_installation_directory: + * @package: An identifier for a software package, or NULL + * @dll_name: The name of a DLL that a package provides, or NULL + * + * Try to determine the installation directory for a software package. + * Typically used by GNU software packages. + * + * @package should be a short identifier for the package. Typically it + * is the same identifier as used for GETTEXT_PACKAGE in software + * configured accoring to GNU standards. The function first looks in + * the Windows Registry for the value #InstallationDirectory in the + * key #HKLM\Software\@package, and if that value exists and is a + * string, returns that. + * + * If @package is NULL, or the above value isn't found in the + * Registry, but @dll_name is non-NULL, it should name a DLL loaded + * into the current process. Typically that would be the name of the + * DLL calling this function, looking for its installation + * directory. The function then asks Windows what directory that DLL + * was loaded from. If that directory's last component is "bin" or + * "lib", the parent directory is returned, otherwise the directory + * itself. If that DLL isn't loaded, the function proceeds as if + * @dll_name was NULL. + * + * If both @package and @dll_name are NULL, the directory from where + * the main executable of the process was loaded is uses instead in + * the same way as above. + * + * The return value should be freed with g_free() when not needed any longer. */ + +gchar * +g_win32_get_package_installation_directory (gchar *package, + gchar *dll_name) +{ + static GHashTable *package_dirs = NULL; + gchar *result = NULL; + gchar *key; + HKEY reg_key = NULL; + DWORD type; + DWORD nbytes; + + if (package != NULL) + { + if (package_dirs == NULL) + package_dirs = g_hash_table_new (g_str_hash, g_str_equal); + + result = g_hash_table_lookup (package_dirs, package); + + if (result && result[0]) + return g_strdup (result); + + key = g_strconcat ("Software\\", package, NULL); + + nbytes = 0; + if ((RegOpenKeyEx (HKEY_CURRENT_USER, key, 0, + KEY_QUERY_VALUE, ®_key) == ERROR_SUCCESS + && RegQueryValueEx (reg_key, "InstallationDirectory", 0, + &type, NULL, &nbytes) == ERROR_SUCCESS) + || + ((RegOpenKeyEx (HKEY_LOCAL_MACHINE, key, 0, + KEY_QUERY_VALUE, ®_key) == ERROR_SUCCESS + && RegQueryValueEx (reg_key, "InstallationDirectory", 0, + &type, NULL, &nbytes) == ERROR_SUCCESS) + && type == REG_SZ)) + { + result = g_malloc (nbytes + 1); + RegQueryValueEx (reg_key, "InstallationDirectory", 0, + &type, result, &nbytes); + result[nbytes] = '\0'; + } + + if (reg_key != NULL) + RegCloseKey (reg_key); + + g_free (key); + + } + if (result) + { + g_hash_table_insert (package_dirs, package, result); + return g_strdup (result); + } + + if (dll_name != NULL) + result = get_package_directory_from_module (dll_name); + + if (result == NULL) + result = get_package_directory_from_module (NULL); + + return result; +} + +/** + * g_win32_get_package_installation_subdirectory: + * @package: An identifier for a software package, or NULL + * @dll_name: The name of a DLL that a package provides, or NULL + * @subdir: A subdirectory of the package installation directory. + * + * Returns a string containg the path of the subdirectory @subdir in + * the return value from calling + * g_win32_get_package_installation_directory() with the @package and + * @dll_name parameters. The return value should be freed with + * g_free() when no longer needed. + */ + +gchar * +g_win32_get_package_installation_subdirectory (gchar *package, + gchar *dll_name, + gchar *subdir) +{ + gchar *prefix; + gchar *sep; + + prefix = g_win32_get_package_installation_directory (package, dll_name); + + sep = (prefix[strlen (prefix) - 1] == G_DIR_SEPARATOR ? + "" : G_DIR_SEPARATOR_S); + + return g_strconcat (prefix, sep, subdir, NULL); +} diff --git a/graf2d/win32gdk/gdk/src/glib/gwin32.h b/graf2d/win32gdk/gdk/src/glib/gwin32.h index 2fb7e04556fda..a71d774481d4c 100644 --- a/graf2d/win32gdk/gdk/src/glib/gwin32.h +++ b/graf2d/win32gdk/gdk/src/glib/gwin32.h @@ -27,21 +27,25 @@ #ifndef __G_WIN32_H__ #define __G_WIN32_H__ -#include <g_types.h> +#include <glib/gtypes.h> -#ifdef G_OS_WIN32 +#ifdef G_PLATFORM_WIN32 /* Windows emulation stubs for common Unix functions */ G_BEGIN_DECLS +#ifndef MAXPATHLEN #define MAXPATHLEN 1024 +#endif #ifdef _MSC_VER typedef int pid_t; #endif +#ifdef G_OS_WIN32 + /* * To get prototypes for the following POSIXish functions, you have to * include the indicated non-POSIX headers. The functions are defined @@ -89,29 +93,38 @@ struct DIR typedef struct DIR DIR; /* emulation functions */ -extern int g_win32_ftruncate (gint f, +gint g_win32_ftruncate (gint f, guint size); DIR* g_win32_opendir (const gchar *dirname); struct dirent* g_win32_readdir (DIR *dir); void g_win32_rewinddir (DIR *dir); gint g_win32_closedir (DIR *dir); +#endif /* G_OS_WIN32 */ + /* The MS setlocale uses locale names of the form "English_United * States.1252" etc. We want the Unixish standard form "en", "zh_TW" * etc. This function gets the current thread locale from Windows and * returns it as a string of the above form for use in forming file * names etc. The returned string should be deallocated with g_free(). */ -gchar * g_win32_getlocale (void); +gchar* g_win32_getlocale (void); /* Translate a Win32 error code (as returned by GetLastError()) into * the corresponding message. The returned string should be deallocated * with g_free(). */ -gchar * g_win32_error_message (gint error); +gchar* g_win32_error_message (gint error); + +gchar* g_win32_get_package_installation_directory (gchar *package, + gchar *dll_name); + +gchar* g_win32_get_package_installation_subdirectory (gchar *package, + gchar *dll_name, + gchar *subdir); G_END_DECLS -#endif /* G_OS_WIN32 */ +#endif /* G_PLATFORM_WIN32 */ #endif /* __G_WIN32_H__ */ diff --git a/graf2d/win32gdk/gdk/src/glib/makefile.msc b/graf2d/win32gdk/gdk/src/glib/makefile.msc new file mode 100644 index 0000000000000..69e46b80d4954 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/glib/makefile.msc @@ -0,0 +1,133 @@ +## Makefile for building the glib dlls with Microsoft C +## Use: nmake -f makefile.msc + +## +## Adapted for the ROOT project +## + +################################################################ + +# +# Figure out if we are going to debug qualifiers or not +# + +!IFNDEF DEBUG +# Full optimization: +OPTIMIZE = -O2 -MD +!ELSE +# Debugging: +OPTIMIZE = -Z7 -MDd +LINKDEBUG = /debug +!ENDIF + +# +# Override all options if something is passed in from outside (i.e. the ROOT build system) +# + +# cl -? describes the options +#CC = cl -G5 -GF $(OPTIMIZE) -W3 -nologo +!if "$(NMCXXFLAGS)" == "" +CC = cl -GR $(OPTIMIZE) -W3 -nologo +!else +CC = cl -nologo $(NMCXXFLAGS) +!endif + +LDFLAGS = /link $(LINKDEBUG) + +GLIB_VER=1.3 + +# Check if nmake version is 8.xx or 9.xx +!if ([nmake /? 2>&1 | findstr /c:"Version 8\." > nul ] == 0) || \ + ([nmake /? 2>&1 | findstr /c:"Version 9\." > nul ] == 0) +MT_DLL = mt -nologo -manifest $@.manifest -outputresource:$@;2 +CLEAN_MT = -@erase /q $@.manifest >nul 2>&1 +!else +MT_DLL = +CLEAN_MT = +!endif + +CFLAGS = -I. -I.. -I..\iconv -I..\.. -DG_LOG_DOMAIN=g_log_domain_glib -DG_ENABLE_DEBUG -DGLIB_COMPILATION -DHAVE_CONFIG_H -DUSE_LIBICONV +# You could add this if you wanted... -DG_ENABLE_DEBUG +###################### + +all : \ + config.h \ + glibconfig.h \ + glib-$(GLIB_VER).dll \ + +glib_OBJECTS = \ + garray.obj \ + gasyncqueue.obj \ + gbacktrace.obj \ + gcache.obj \ + gcompletion.obj \ + gconvert.obj \ + gdataset.obj \ + gdate.obj \ + gerror.obj \ + gfileutils.obj \ + ghash.obj \ + ghook.obj \ + giochannel.obj \ + giowin32.obj \ + glist.obj \ + gmain.obj \ + gmarkup.obj \ + gmem.obj \ + gmessages.obj \ + gnode.obj \ + gprimes.obj \ + gqsort.obj \ + gqueue.obj \ + gpattern.obj \ + grand.obj \ + grel.obj \ + gscanner.obj \ + gshell.obj \ + gslist.obj \ + gspawn-win32.obj \ + gstrfuncs.obj \ + gstring.obj \ + gbsearcharray.obj \ + gthread.obj \ + gthreadpool.obj \ + gtimer.obj \ + gtree.obj \ + gunibreak.obj \ + gunicollate.obj \ + gunidecomp.obj \ + guniprop.obj \ + gutf8.obj \ + gutils.obj \ + gwin32.obj + +glibconfig.h: glibconfig.h.win32 + copy glibconfig.h.win32 glibconfig.h + +config.h: config.h.win32 + copy config.h.win32 config.h + +################ glib + +glib-$(GLIB_VER).dll : $(glib_OBJECTS) glib.def + cd + $(CC) $(CFLAGS) -LD -Feglib-$(GLIB_VER).dll $(glib_OBJECTS) $(LIBICONV_LIBS) $(INTL_LIBS) user32.lib advapi32.lib wsock32.lib $(LDFLAGS) ..\iconv\iconv-1.3.lib /def:glib.def + $(MT_DLL) + $(CLEAN_MT) + +.c.obj : + $(CC) $(CFLAGS) -c -DGDK_COMPILATION -DG_LOG_DOMAIN=\"Gdk\" $< + +################ other stuff + +clean:: + del config.h + del glibconfig.h + -@erase /q *.dll >nul 2>&1 + -@erase /q *.obj >nul 2>&1 + -@erase /q *.lib >nul 2>&1 + -@erase /q *.err >nul 2>&1 + -@erase /q *.res >nul 2>&1 + -@erase /q *.exp >nul 2>&1 + -@erase /q *.pdb >nul 2>&1 + -@erase /q *.ilk >nul 2>&1 \ No newline at end of file diff --git a/graf2d/win32gdk/gdk/src/iconv/aliases.h b/graf2d/win32gdk/gdk/src/iconv/aliases.h new file mode 100644 index 0000000000000..f9cc41df1e081 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/aliases.h @@ -0,0 +1,1714 @@ +/* ANSI-C code produced by gperf version 3.0.4 */ +/* Command-line: gperf -m 10 lib/aliases.gperf */ +/* Computed positions: -k'1,3-11,$' */ + +#if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ + && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ + && (')' == 41) && ('*' == 42) && ('+' == 43) && (',' == 44) \ + && ('-' == 45) && ('.' == 46) && ('/' == 47) && ('0' == 48) \ + && ('1' == 49) && ('2' == 50) && ('3' == 51) && ('4' == 52) \ + && ('5' == 53) && ('6' == 54) && ('7' == 55) && ('8' == 56) \ + && ('9' == 57) && (':' == 58) && (';' == 59) && ('<' == 60) \ + && ('=' == 61) && ('>' == 62) && ('?' == 63) && ('A' == 65) \ + && ('B' == 66) && ('C' == 67) && ('D' == 68) && ('E' == 69) \ + && ('F' == 70) && ('G' == 71) && ('H' == 72) && ('I' == 73) \ + && ('J' == 74) && ('K' == 75) && ('L' == 76) && ('M' == 77) \ + && ('N' == 78) && ('O' == 79) && ('P' == 80) && ('Q' == 81) \ + && ('R' == 82) && ('S' == 83) && ('T' == 84) && ('U' == 85) \ + && ('V' == 86) && ('W' == 87) && ('X' == 88) && ('Y' == 89) \ + && ('Z' == 90) && ('[' == 91) && ('\\' == 92) && (']' == 93) \ + && ('^' == 94) && ('_' == 95) && ('a' == 97) && ('b' == 98) \ + && ('c' == 99) && ('d' == 100) && ('e' == 101) && ('f' == 102) \ + && ('g' == 103) && ('h' == 104) && ('i' == 105) && ('j' == 106) \ + && ('k' == 107) && ('l' == 108) && ('m' == 109) && ('n' == 110) \ + && ('o' == 111) && ('p' == 112) && ('q' == 113) && ('r' == 114) \ + && ('s' == 115) && ('t' == 116) && ('u' == 117) && ('v' == 118) \ + && ('w' == 119) && ('x' == 120) && ('y' == 121) && ('z' == 122) \ + && ('{' == 123) && ('|' == 124) && ('}' == 125) && ('~' == 126)) +/* The character set is not based on ISO-646. */ +#error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gnu-gperf@gnu.org>." +#endif + +#line 1 "lib/aliases.gperf" +struct alias { int name; unsigned int encoding_index; }; + +#define TOTAL_KEYWORDS 346 +#define MIN_WORD_LENGTH 2 +#define MAX_WORD_LENGTH 45 +#define MIN_HASH_VALUE 7 +#define MAX_HASH_VALUE 935 +/* maximum key range = 929, duplicates = 0 */ + +#ifdef __GNUC__ +__inline +#else +#ifdef __cplusplus +inline +#endif +#endif +static unsigned int +aliases_hash (register const char *str, register unsigned int len) +{ + static const unsigned short asso_values[] = + { + 936, 936, 936, 936, 936, 936, 936, 936, 936, 936, + 936, 936, 936, 936, 936, 936, 936, 936, 936, 936, + 936, 936, 936, 936, 936, 936, 936, 936, 936, 936, + 936, 936, 936, 936, 936, 936, 936, 936, 936, 936, + 936, 936, 936, 936, 936, 16, 62, 936, 73, 0, + 5, 2, 47, 4, 1, 168, 8, 12, 357, 936, + 936, 936, 936, 936, 936, 112, 123, 3, 14, 34, + 71, 142, 147, 0, 258, 79, 39, 122, 4, 0, + 109, 936, 76, 1, 54, 147, 114, 180, 102, 3, + 10, 936, 936, 936, 936, 34, 936, 936, 936, 936, + 936, 936, 936, 936, 936, 936, 936, 936, 936, 936, + 936, 936, 936, 936, 936, 936, 936, 936, 936, 936, + 936, 936, 936, 936, 936, 936, 936, 936 + }; + register int hval = len; + + switch (hval) + { + default: + hval += asso_values[(unsigned char)str[10]]; + /*FALLTHROUGH*/ + case 10: + hval += asso_values[(unsigned char)str[9]]; + /*FALLTHROUGH*/ + case 9: + hval += asso_values[(unsigned char)str[8]]; + /*FALLTHROUGH*/ + case 8: + hval += asso_values[(unsigned char)str[7]]; + /*FALLTHROUGH*/ + case 7: + hval += asso_values[(unsigned char)str[6]]; + /*FALLTHROUGH*/ + case 6: + hval += asso_values[(unsigned char)str[5]]; + /*FALLTHROUGH*/ + case 5: + hval += asso_values[(unsigned char)str[4]]; + /*FALLTHROUGH*/ + case 4: + hval += asso_values[(unsigned char)str[3]]; + /*FALLTHROUGH*/ + case 3: + hval += asso_values[(unsigned char)str[2]]; + /*FALLTHROUGH*/ + case 2: + case 1: + hval += asso_values[(unsigned char)str[0]]; + break; + } + return hval + asso_values[(unsigned char)str[len - 1]]; +} + +struct stringpool_t + { + char stringpool_str7[sizeof("SJIS")]; + char stringpool_str9[sizeof("CN")]; + char stringpool_str11[sizeof("CP1131")]; + char stringpool_str12[sizeof("CP1361")]; + char stringpool_str13[sizeof("866")]; + char stringpool_str15[sizeof("CP1133")]; + char stringpool_str18[sizeof("CP1251")]; + char stringpool_str19[sizeof("CP866")]; + char stringpool_str20[sizeof("CP1256")]; + char stringpool_str21[sizeof("862")]; + char stringpool_str22[sizeof("CP1253")]; + char stringpool_str24[sizeof("CP936")]; + char stringpool_str26[sizeof("CP1255")]; + char stringpool_str27[sizeof("CP862")]; + char stringpool_str28[sizeof("CP1252")]; + char stringpool_str30[sizeof("C99")]; + char stringpool_str32[sizeof("CP932")]; + char stringpool_str34[sizeof("CP1258")]; + char stringpool_str40[sizeof("CP819")]; + char stringpool_str41[sizeof("L1")]; + char stringpool_str42[sizeof("L6")]; + char stringpool_str43[sizeof("L3")]; + char stringpool_str45[sizeof("L5")]; + char stringpool_str46[sizeof("L2")]; + char stringpool_str49[sizeof("L8")]; + char stringpool_str53[sizeof("EUCCN")]; + char stringpool_str57[sizeof("ISO8859-1")]; + char stringpool_str58[sizeof("ISO8859-11")]; + char stringpool_str59[sizeof("ISO8859-6")]; + char stringpool_str60[sizeof("ISO8859-16")]; + char stringpool_str61[sizeof("ISO8859-3")]; + char stringpool_str62[sizeof("ISO8859-13")]; + char stringpool_str65[sizeof("ISO8859-5")]; + char stringpool_str66[sizeof("ISO8859-15")]; + char stringpool_str67[sizeof("ISO8859-2")]; + char stringpool_str70[sizeof("EUC-CN")]; + char stringpool_str73[sizeof("ISO8859-8")]; + char stringpool_str74[sizeof("ISO-8859-1")]; + char stringpool_str75[sizeof("ISO-8859-11")]; + char stringpool_str76[sizeof("ISO-8859-6")]; + char stringpool_str77[sizeof("ISO-8859-16")]; + char stringpool_str78[sizeof("ISO-8859-3")]; + char stringpool_str79[sizeof("ISO-8859-13")]; + char stringpool_str81[sizeof("ISO8859-9")]; + char stringpool_str82[sizeof("ISO-8859-5")]; + char stringpool_str83[sizeof("ISO-8859-15")]; + char stringpool_str84[sizeof("ISO-8859-2")]; + char stringpool_str85[sizeof("ISO646-CN")]; + char stringpool_str86[sizeof("R8")]; + char stringpool_str88[sizeof("L4")]; + char stringpool_str90[sizeof("ISO-8859-8")]; + char stringpool_str91[sizeof("CP949")]; + char stringpool_str92[sizeof("ISO_8859-1")]; + char stringpool_str93[sizeof("ISO_8859-11")]; + char stringpool_str94[sizeof("ISO_8859-6")]; + char stringpool_str95[sizeof("ISO_8859-16")]; + char stringpool_str96[sizeof("ISO_8859-3")]; + char stringpool_str97[sizeof("ISO_8859-13")]; + char stringpool_str98[sizeof("ISO-8859-9")]; + char stringpool_str99[sizeof("ISO_8859-16:2001")]; + char stringpool_str100[sizeof("ISO_8859-5")]; + char stringpool_str101[sizeof("ISO_8859-15")]; + char stringpool_str102[sizeof("ISO_8859-2")]; + char stringpool_str103[sizeof("LATIN1")]; + char stringpool_str105[sizeof("LATIN6")]; + char stringpool_str106[sizeof("CP154")]; + char stringpool_str107[sizeof("LATIN3")]; + char stringpool_str108[sizeof("ISO_8859-8")]; + char stringpool_str110[sizeof("ISO_8859-15:1998")]; + char stringpool_str111[sizeof("LATIN5")]; + char stringpool_str112[sizeof("CP1254")]; + char stringpool_str113[sizeof("LATIN2")]; + char stringpool_str114[sizeof("CSISO2022CN")]; + char stringpool_str116[sizeof("ISO_8859-9")]; + char stringpool_str117[sizeof("CHINESE")]; + char stringpool_str118[sizeof("ISO-IR-6")]; + char stringpool_str119[sizeof("LATIN8")]; + char stringpool_str120[sizeof("ASCII")]; + char stringpool_str121[sizeof("ISO-IR-166")]; + char stringpool_str122[sizeof("X0212")]; + char stringpool_str124[sizeof("VISCII")]; + char stringpool_str125[sizeof("ISO-IR-126")]; + char stringpool_str126[sizeof("CSASCII")]; + char stringpool_str127[sizeof("ISO-IR-165")]; + char stringpool_str129[sizeof("CSVISCII")]; + char stringpool_str130[sizeof("ISO-IR-226")]; + char stringpool_str131[sizeof("MAC")]; + char stringpool_str136[sizeof("ISO-IR-138")]; + char stringpool_str137[sizeof("ISO-IR-58")]; + char stringpool_str139[sizeof("IBM866")]; + char stringpool_str142[sizeof("ISO-2022-CN")]; + char stringpool_str143[sizeof("MS936")]; + char stringpool_str144[sizeof("LATIN-9")]; + char stringpool_str146[sizeof("ISO-IR-159")]; + char stringpool_str147[sizeof("IBM862")]; + char stringpool_str150[sizeof("US")]; + char stringpool_str151[sizeof("ISO8859-4")]; + char stringpool_str152[sizeof("ISO8859-14")]; + char stringpool_str153[sizeof("ISO_8859-14:1998")]; + char stringpool_str154[sizeof("ISO-IR-199")]; + char stringpool_str156[sizeof("UHC")]; + char stringpool_str157[sizeof("850")]; + char stringpool_str159[sizeof("HZ")]; + char stringpool_str160[sizeof("IBM819")]; + char stringpool_str162[sizeof("ISO-CELTIC")]; + char stringpool_str163[sizeof("ELOT_928")]; + char stringpool_str164[sizeof("CP1250")]; + char stringpool_str165[sizeof("GB2312")]; + char stringpool_str166[sizeof("CP850")]; + char stringpool_str168[sizeof("ISO-8859-4")]; + char stringpool_str169[sizeof("ISO-8859-14")]; + char stringpool_str170[sizeof("CP950")]; + char stringpool_str171[sizeof("CYRILLIC")]; + char stringpool_str176[sizeof("ISO_8859-10:1992")]; + char stringpool_str179[sizeof("UCS-2")]; + char stringpool_str180[sizeof("TCVN")]; + char stringpool_str181[sizeof("ISO-IR-148")]; + char stringpool_str185[sizeof("X0201")]; + char stringpool_str186[sizeof("ISO_8859-4")]; + char stringpool_str187[sizeof("ISO_8859-14")]; + char stringpool_str188[sizeof("L10")]; + char stringpool_str189[sizeof("ISO-IR-149")]; + char stringpool_str191[sizeof("ISO-IR-101")]; + char stringpool_str196[sizeof("ISO-2022-CN-EXT")]; + char stringpool_str197[sizeof("LATIN4")]; + char stringpool_str200[sizeof("ISO-IR-203")]; + char stringpool_str201[sizeof("X0208")]; + char stringpool_str202[sizeof("KSC_5601")]; + char stringpool_str204[sizeof("ISO8859-10")]; + char stringpool_str207[sizeof("VISCII1.1-1")]; + char stringpool_str209[sizeof("L7")]; + char stringpool_str211[sizeof("ISO-IR-14")]; + char stringpool_str212[sizeof("PT154")]; + char stringpool_str213[sizeof("TIS620")]; + char stringpool_str215[sizeof("ISO-IR-109")]; + char stringpool_str216[sizeof("CSUNICODE11")]; + char stringpool_str217[sizeof("KOI8-T")]; + char stringpool_str218[sizeof("RK1048")]; + char stringpool_str221[sizeof("ISO-8859-10")]; + char stringpool_str222[sizeof("TIS620.2533-1")]; + char stringpool_str223[sizeof("ISO646-US")]; + char stringpool_str224[sizeof("CSISOLATIN1")]; + char stringpool_str226[sizeof("CSISOLATIN6")]; + char stringpool_str228[sizeof("CSISOLATIN3")]; + char stringpool_str230[sizeof("TIS-620")]; + char stringpool_str232[sizeof("CSISOLATIN5")]; + char stringpool_str234[sizeof("CSISOLATIN2")]; + char stringpool_str235[sizeof("TIS620.2529-1")]; + char stringpool_str236[sizeof("CSKZ1048")]; + char stringpool_str237[sizeof("CSISOLATINCYRILLIC")]; + char stringpool_str238[sizeof("KZ-1048")]; + char stringpool_str239[sizeof("ISO_8859-10")]; + char stringpool_str241[sizeof("UNICODE-1-1")]; + char stringpool_str242[sizeof("UTF-16")]; + char stringpool_str245[sizeof("MS-EE")]; + char stringpool_str248[sizeof("CSUNICODE")]; + char stringpool_str249[sizeof("CSKOI8R")]; + char stringpool_str250[sizeof("LATIN10")]; + char stringpool_str252[sizeof("UTF-32")]; + char stringpool_str254[sizeof("CSUCS4")]; + char stringpool_str255[sizeof("UTF-8")]; + char stringpool_str259[sizeof("ISO-IR-144")]; + char stringpool_str261[sizeof("KOI8-R")]; + char stringpool_str262[sizeof("MS-ANSI")]; + char stringpool_str263[sizeof("UCS-4")]; + char stringpool_str264[sizeof("ISO-IR-110")]; + char stringpool_str266[sizeof("IBM-CP1133")]; + char stringpool_str267[sizeof("CSIBM866")]; + char stringpool_str270[sizeof("KS_C_5601-1989")]; + char stringpool_str271[sizeof("CHAR")]; + char stringpool_str273[sizeof("EUCKR")]; + char stringpool_str277[sizeof("BIG5")]; + char stringpool_str278[sizeof("CP874")]; + char stringpool_str279[sizeof("ARMSCII-8")]; + char stringpool_str282[sizeof("CSBIG5")]; + char stringpool_str283[sizeof("UCS-2LE")]; + char stringpool_str286[sizeof("IBM850")]; + char stringpool_str287[sizeof("US-ASCII")]; + char stringpool_str290[sizeof("EUC-KR")]; + char stringpool_str293[sizeof("CSGB2312")]; + char stringpool_str294[sizeof("BIG-5")]; + char stringpool_str295[sizeof("TIS620.2533-0")]; + char stringpool_str299[sizeof("CN-BIG5")]; + char stringpool_str302[sizeof("MACCYRILLIC")]; + char stringpool_str303[sizeof("GBK")]; + char stringpool_str304[sizeof("TIS620-0")]; + char stringpool_str305[sizeof("MS-CYRL")]; + char stringpool_str307[sizeof("CYRILLIC-ASIAN")]; + char stringpool_str308[sizeof("ECMA-118")]; + char stringpool_str310[sizeof("ISO-IR-179")]; + char stringpool_str311[sizeof("GREEK8")]; + char stringpool_str315[sizeof("KOREAN")]; + char stringpool_str318[sizeof("CSISOLATIN4")]; + char stringpool_str321[sizeof("ISO-10646-UCS-2")]; + char stringpool_str325[sizeof("UCS-4LE")]; + char stringpool_str326[sizeof("PTCP154")]; + char stringpool_str330[sizeof("CSISO14JISC6220RO")]; + char stringpool_str334[sizeof("CSISO2022KR")]; + char stringpool_str336[sizeof("ROMAN8")]; + char stringpool_str337[sizeof("ISO-IR-100")]; + char stringpool_str340[sizeof("JIS_C6226-1983")]; + char stringpool_str344[sizeof("CSISOLATINARABIC")]; + char stringpool_str347[sizeof("CP367")]; + char stringpool_str350[sizeof("UTF-16LE")]; + char stringpool_str351[sizeof("ISO_646.IRV:1991")]; + char stringpool_str354[sizeof("CP1257")]; + char stringpool_str355[sizeof("MACICELAND")]; + char stringpool_str356[sizeof("UTF-32LE")]; + char stringpool_str357[sizeof("CSKSC56011987")]; + char stringpool_str359[sizeof("ARABIC")]; + char stringpool_str362[sizeof("ISO-2022-KR")]; + char stringpool_str363[sizeof("ISO-10646-UCS-4")]; + char stringpool_str367[sizeof("UCS-2BE")]; + char stringpool_str368[sizeof("GB_2312-80")]; + char stringpool_str369[sizeof("JP")]; + char stringpool_str371[sizeof("MULELAO-1")]; + char stringpool_str372[sizeof("CSISO159JISX02121990")]; + char stringpool_str373[sizeof("GREEK")]; + char stringpool_str375[sizeof("TCVN5712-1")]; + char stringpool_str376[sizeof("CSISO58GB231280")]; + char stringpool_str378[sizeof("GB18030")]; + char stringpool_str379[sizeof("TCVN-5712")]; + char stringpool_str384[sizeof("GB_1988-80")]; + char stringpool_str385[sizeof("CSPTCP154")]; + char stringpool_str386[sizeof("ECMA-114")]; + char stringpool_str388[sizeof("CSUNICODE11UTF7")]; + char stringpool_str391[sizeof("ANSI_X3.4-1986")]; + char stringpool_str392[sizeof("UNICODELITTLE")]; + char stringpool_str393[sizeof("ISO8859-7")]; + char stringpool_str395[sizeof("CN-GB-ISOIR165")]; + char stringpool_str396[sizeof("STRK1048-2002")]; + char stringpool_str398[sizeof("ANSI_X3.4-1968")]; + char stringpool_str403[sizeof("KOI8-U")]; + char stringpool_str406[sizeof("UCS-2-INTERNAL")]; + char stringpool_str409[sizeof("UCS-4BE")]; + char stringpool_str410[sizeof("ISO-8859-7")]; + char stringpool_str411[sizeof("SHIFT-JIS")]; + char stringpool_str412[sizeof("CN-GB")]; + char stringpool_str413[sizeof("JIS_C6220-1969-RO")]; + char stringpool_str415[sizeof("UNICODE-1-1-UTF-7")]; + char stringpool_str416[sizeof("WINDOWS-1251")]; + char stringpool_str417[sizeof("WINDOWS-1256")]; + char stringpool_str418[sizeof("WINDOWS-1253")]; + char stringpool_str420[sizeof("WINDOWS-1255")]; + char stringpool_str421[sizeof("WINDOWS-1252")]; + char stringpool_str422[sizeof("WINDOWS-936")]; + char stringpool_str424[sizeof("WINDOWS-1258")]; + char stringpool_str425[sizeof("CSEUCKR")]; + char stringpool_str426[sizeof("KS_C_5601-1987")]; + char stringpool_str428[sizeof("ISO_8859-7")]; + char stringpool_str429[sizeof("SHIFT_JIS")]; + char stringpool_str433[sizeof("JIS0208")]; + char stringpool_str434[sizeof("UTF-16BE")]; + char stringpool_str439[sizeof("LATIN7")]; + char stringpool_str440[sizeof("UTF-32BE")]; + char stringpool_str445[sizeof("MACTHAI")]; + char stringpool_str448[sizeof("UCS-4-INTERNAL")]; + char stringpool_str449[sizeof("CSISOLATINGREEK")]; + char stringpool_str451[sizeof("MACROMAN")]; + char stringpool_str452[sizeof("EXTENDED_UNIX_CODE_PACKED_FORMAT_FOR_JAPANESE")]; + char stringpool_str456[sizeof("EUCTW")]; + char stringpool_str457[sizeof("ISO-IR-57")]; + char stringpool_str458[sizeof("ISO-IR-157")]; + char stringpool_str459[sizeof("ISO-IR-127")]; + char stringpool_str461[sizeof("ISO-IR-87")]; + char stringpool_str463[sizeof("WINDOWS-1254")]; + char stringpool_str464[sizeof("ISO_8859-3:1988")]; + char stringpool_str466[sizeof("ISO_8859-5:1988")]; + char stringpool_str467[sizeof("IBM367")]; + char stringpool_str470[sizeof("ISO_8859-8:1988")]; + char stringpool_str471[sizeof("HZ-GB-2312")]; + char stringpool_str473[sizeof("EUC-TW")]; + char stringpool_str474[sizeof("CSISO57GB1988")]; + char stringpool_str475[sizeof("NEXTSTEP")]; + char stringpool_str476[sizeof("CSISO2022JP2")]; + char stringpool_str478[sizeof("ISO_8859-9:1989")]; + char stringpool_str480[sizeof("KOI8-RU")]; + char stringpool_str487[sizeof("MACINTOSH")]; + char stringpool_str489[sizeof("WINDOWS-1250")]; + char stringpool_str492[sizeof("JIS_X0212")]; + char stringpool_str500[sizeof("ISO-2022-JP-1")]; + char stringpool_str501[sizeof("MACCROATIAN")]; + char stringpool_str502[sizeof("HP-ROMAN8")]; + char stringpool_str505[sizeof("ISO-2022-JP-2")]; + char stringpool_str509[sizeof("ISO_8859-4:1988")]; + char stringpool_str510[sizeof("BIG5HKSCS")]; + char stringpool_str515[sizeof("ASMO-708")]; + char stringpool_str518[sizeof("EUCJP")]; + char stringpool_str525[sizeof("BIGFIVE")]; + char stringpool_str527[sizeof("BIG5-HKSCS")]; + char stringpool_str531[sizeof("MACCENTRALEUROPE")]; + char stringpool_str532[sizeof("CSPC862LATINHEBREW")]; + char stringpool_str535[sizeof("EUC-JP")]; + char stringpool_str542[sizeof("BIG-FIVE")]; + char stringpool_str546[sizeof("CSSHIFTJIS")]; + char stringpool_str550[sizeof("ISO646-JP")]; + char stringpool_str554[sizeof("JISX0201-1976")]; + char stringpool_str555[sizeof("JIS_X0201")]; + char stringpool_str556[sizeof("CSISOLATINHEBREW")]; + char stringpool_str563[sizeof("MACARABIC")]; + char stringpool_str564[sizeof("CSISO87JISX0208")]; + char stringpool_str571[sizeof("JIS_X0208")]; + char stringpool_str575[sizeof("UTF-7")]; + char stringpool_str577[sizeof("MACGREEK")]; + char stringpool_str579[sizeof("CSISO2022JP")]; + char stringpool_str580[sizeof("MS-TURK")]; + char stringpool_str581[sizeof("JIS_X0212-1990")]; + char stringpool_str584[sizeof("WINDOWS-1257")]; + char stringpool_str586[sizeof("JIS_X0208-1983")]; + char stringpool_str590[sizeof("MS-GREEK")]; + char stringpool_str599[sizeof("CSHPROMAN8")]; + char stringpool_str600[sizeof("JAVA")]; + char stringpool_str601[sizeof("MS-HEBR")]; + char stringpool_str604[sizeof("CSMACINTOSH")]; + char stringpool_str607[sizeof("ISO-2022-JP")]; + char stringpool_str608[sizeof("CSEUCTW")]; + char stringpool_str614[sizeof("GEORGIAN-PS")]; + char stringpool_str615[sizeof("UNICODEBIG")]; + char stringpool_str617[sizeof("MS_KANJI")]; + char stringpool_str620[sizeof("CSPC850MULTILINGUAL")]; + char stringpool_str621[sizeof("MACUKRAINE")]; + char stringpool_str622[sizeof("ISO_8859-1:1987")]; + char stringpool_str623[sizeof("ISO_8859-6:1987")]; + char stringpool_str624[sizeof("ISO_8859-7:2003")]; + char stringpool_str626[sizeof("GEORGIAN-ACADEMY")]; + char stringpool_str627[sizeof("ISO_8859-2:1987")]; + char stringpool_str629[sizeof("JIS_X0212.1990-0")]; + char stringpool_str657[sizeof("JIS_X0208-1990")]; + char stringpool_str664[sizeof("WCHAR_T")]; + char stringpool_str673[sizeof("MACROMANIA")]; + char stringpool_str676[sizeof("WINDOWS-874")]; + char stringpool_str689[sizeof("CSEUCPKDFMTJAPANESE")]; + char stringpool_str691[sizeof("MS-ARAB")]; + char stringpool_str723[sizeof("UCS-2-SWAPPED")]; + char stringpool_str739[sizeof("TCVN5712-1:1993")]; + char stringpool_str746[sizeof("HEBREW")]; + char stringpool_str765[sizeof("UCS-4-SWAPPED")]; + char stringpool_str768[sizeof("JOHAB")]; + char stringpool_str786[sizeof("MACTURKISH")]; + char stringpool_str790[sizeof("ISO_8859-7:1987")]; + char stringpool_str842[sizeof("WINBALTRIM")]; + char stringpool_str888[sizeof("BIG5-HKSCS:2001")]; + char stringpool_str898[sizeof("CSHALFWIDTHKATAKANA")]; + char stringpool_str900[sizeof("BIG5-HKSCS:1999")]; + char stringpool_str908[sizeof("MACHEBREW")]; + char stringpool_str935[sizeof("BIG5-HKSCS:2004")]; + }; +static const struct stringpool_t stringpool_contents = + { + "SJIS", + "CN", + "CP1131", + "CP1361", + "866", + "CP1133", + "CP1251", + "CP866", + "CP1256", + "862", + "CP1253", + "CP936", + "CP1255", + "CP862", + "CP1252", + "C99", + "CP932", + "CP1258", + "CP819", + "L1", + "L6", + "L3", + "L5", + "L2", + "L8", + "EUCCN", + "ISO8859-1", + "ISO8859-11", + "ISO8859-6", + "ISO8859-16", + "ISO8859-3", + "ISO8859-13", + "ISO8859-5", + "ISO8859-15", + "ISO8859-2", + "EUC-CN", + "ISO8859-8", + "ISO-8859-1", + "ISO-8859-11", + "ISO-8859-6", + "ISO-8859-16", + "ISO-8859-3", + "ISO-8859-13", + "ISO8859-9", + "ISO-8859-5", + "ISO-8859-15", + "ISO-8859-2", + "ISO646-CN", + "R8", + "L4", + "ISO-8859-8", + "CP949", + "ISO_8859-1", + "ISO_8859-11", + "ISO_8859-6", + "ISO_8859-16", + "ISO_8859-3", + "ISO_8859-13", + "ISO-8859-9", + "ISO_8859-16:2001", + "ISO_8859-5", + "ISO_8859-15", + "ISO_8859-2", + "LATIN1", + "LATIN6", + "CP154", + "LATIN3", + "ISO_8859-8", + "ISO_8859-15:1998", + "LATIN5", + "CP1254", + "LATIN2", + "CSISO2022CN", + "ISO_8859-9", + "CHINESE", + "ISO-IR-6", + "LATIN8", + "ASCII", + "ISO-IR-166", + "X0212", + "VISCII", + "ISO-IR-126", + "CSASCII", + "ISO-IR-165", + "CSVISCII", + "ISO-IR-226", + "MAC", + "ISO-IR-138", + "ISO-IR-58", + "IBM866", + "ISO-2022-CN", + "MS936", + "LATIN-9", + "ISO-IR-159", + "IBM862", + "US", + "ISO8859-4", + "ISO8859-14", + "ISO_8859-14:1998", + "ISO-IR-199", + "UHC", + "850", + "HZ", + "IBM819", + "ISO-CELTIC", + "ELOT_928", + "CP1250", + "GB2312", + "CP850", + "ISO-8859-4", + "ISO-8859-14", + "CP950", + "CYRILLIC", + "ISO_8859-10:1992", + "UCS-2", + "TCVN", + "ISO-IR-148", + "X0201", + "ISO_8859-4", + "ISO_8859-14", + "L10", + "ISO-IR-149", + "ISO-IR-101", + "ISO-2022-CN-EXT", + "LATIN4", + "ISO-IR-203", + "X0208", + "KSC_5601", + "ISO8859-10", + "VISCII1.1-1", + "L7", + "ISO-IR-14", + "PT154", + "TIS620", + "ISO-IR-109", + "CSUNICODE11", + "KOI8-T", + "RK1048", + "ISO-8859-10", + "TIS620.2533-1", + "ISO646-US", + "CSISOLATIN1", + "CSISOLATIN6", + "CSISOLATIN3", + "TIS-620", + "CSISOLATIN5", + "CSISOLATIN2", + "TIS620.2529-1", + "CSKZ1048", + "CSISOLATINCYRILLIC", + "KZ-1048", + "ISO_8859-10", + "UNICODE-1-1", + "UTF-16", + "MS-EE", + "CSUNICODE", + "CSKOI8R", + "LATIN10", + "UTF-32", + "CSUCS4", + "UTF-8", + "ISO-IR-144", + "KOI8-R", + "MS-ANSI", + "UCS-4", + "ISO-IR-110", + "IBM-CP1133", + "CSIBM866", + "KS_C_5601-1989", + "CHAR", + "EUCKR", + "BIG5", + "CP874", + "ARMSCII-8", + "CSBIG5", + "UCS-2LE", + "IBM850", + "US-ASCII", + "EUC-KR", + "CSGB2312", + "BIG-5", + "TIS620.2533-0", + "CN-BIG5", + "MACCYRILLIC", + "GBK", + "TIS620-0", + "MS-CYRL", + "CYRILLIC-ASIAN", + "ECMA-118", + "ISO-IR-179", + "GREEK8", + "KOREAN", + "CSISOLATIN4", + "ISO-10646-UCS-2", + "UCS-4LE", + "PTCP154", + "CSISO14JISC6220RO", + "CSISO2022KR", + "ROMAN8", + "ISO-IR-100", + "JIS_C6226-1983", + "CSISOLATINARABIC", + "CP367", + "UTF-16LE", + "ISO_646.IRV:1991", + "CP1257", + "MACICELAND", + "UTF-32LE", + "CSKSC56011987", + "ARABIC", + "ISO-2022-KR", + "ISO-10646-UCS-4", + "UCS-2BE", + "GB_2312-80", + "JP", + "MULELAO-1", + "CSISO159JISX02121990", + "GREEK", + "TCVN5712-1", + "CSISO58GB231280", + "GB18030", + "TCVN-5712", + "GB_1988-80", + "CSPTCP154", + "ECMA-114", + "CSUNICODE11UTF7", + "ANSI_X3.4-1986", + "UNICODELITTLE", + "ISO8859-7", + "CN-GB-ISOIR165", + "STRK1048-2002", + "ANSI_X3.4-1968", + "KOI8-U", + "UCS-2-INTERNAL", + "UCS-4BE", + "ISO-8859-7", + "SHIFT-JIS", + "CN-GB", + "JIS_C6220-1969-RO", + "UNICODE-1-1-UTF-7", + "WINDOWS-1251", + "WINDOWS-1256", + "WINDOWS-1253", + "WINDOWS-1255", + "WINDOWS-1252", + "WINDOWS-936", + "WINDOWS-1258", + "CSEUCKR", + "KS_C_5601-1987", + "ISO_8859-7", + "SHIFT_JIS", + "JIS0208", + "UTF-16BE", + "LATIN7", + "UTF-32BE", + "MACTHAI", + "UCS-4-INTERNAL", + "CSISOLATINGREEK", + "MACROMAN", + "EXTENDED_UNIX_CODE_PACKED_FORMAT_FOR_JAPANESE", + "EUCTW", + "ISO-IR-57", + "ISO-IR-157", + "ISO-IR-127", + "ISO-IR-87", + "WINDOWS-1254", + "ISO_8859-3:1988", + "ISO_8859-5:1988", + "IBM367", + "ISO_8859-8:1988", + "HZ-GB-2312", + "EUC-TW", + "CSISO57GB1988", + "NEXTSTEP", + "CSISO2022JP2", + "ISO_8859-9:1989", + "KOI8-RU", + "MACINTOSH", + "WINDOWS-1250", + "JIS_X0212", + "ISO-2022-JP-1", + "MACCROATIAN", + "HP-ROMAN8", + "ISO-2022-JP-2", + "ISO_8859-4:1988", + "BIG5HKSCS", + "ASMO-708", + "EUCJP", + "BIGFIVE", + "BIG5-HKSCS", + "MACCENTRALEUROPE", + "CSPC862LATINHEBREW", + "EUC-JP", + "BIG-FIVE", + "CSSHIFTJIS", + "ISO646-JP", + "JISX0201-1976", + "JIS_X0201", + "CSISOLATINHEBREW", + "MACARABIC", + "CSISO87JISX0208", + "JIS_X0208", + "UTF-7", + "MACGREEK", + "CSISO2022JP", + "MS-TURK", + "JIS_X0212-1990", + "WINDOWS-1257", + "JIS_X0208-1983", + "MS-GREEK", + "CSHPROMAN8", + "JAVA", + "MS-HEBR", + "CSMACINTOSH", + "ISO-2022-JP", + "CSEUCTW", + "GEORGIAN-PS", + "UNICODEBIG", + "MS_KANJI", + "CSPC850MULTILINGUAL", + "MACUKRAINE", + "ISO_8859-1:1987", + "ISO_8859-6:1987", + "ISO_8859-7:2003", + "GEORGIAN-ACADEMY", + "ISO_8859-2:1987", + "JIS_X0212.1990-0", + "JIS_X0208-1990", + "WCHAR_T", + "MACROMANIA", + "WINDOWS-874", + "CSEUCPKDFMTJAPANESE", + "MS-ARAB", + "UCS-2-SWAPPED", + "TCVN5712-1:1993", + "HEBREW", + "UCS-4-SWAPPED", + "JOHAB", + "MACTURKISH", + "ISO_8859-7:1987", + "WINBALTRIM", + "BIG5-HKSCS:2001", + "CSHALFWIDTHKATAKANA", + "BIG5-HKSCS:1999", + "MACHEBREW", + "BIG5-HKSCS:2004" + }; +#define stringpool ((const char *) &stringpool_contents) + +static const struct alias aliases[] = + { + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 308 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str7, ei_sjis}, + {-1}, +#line 288 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str9, ei_iso646_cn}, + {-1}, +#line 209 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str11, ei_cp1131}, +#line 353 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str12, ei_johab}, +#line 207 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str13, ei_cp866}, + {-1}, +#line 244 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str15, ei_cp1133}, + {-1}, {-1}, +#line 174 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str18, ei_cp1251}, +#line 205 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str19, ei_cp866}, +#line 189 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str20, ei_cp1256}, +#line 203 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str21, ei_cp862}, +#line 180 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str22, ei_cp1253}, + {-1}, +#line 323 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str24, ei_cp936}, + {-1}, +#line 186 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str26, ei_cp1255}, +#line 201 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str27, ei_cp862}, +#line 177 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str28, ei_cp1252}, + {-1}, +#line 51 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str30, ei_c99}, + {-1}, +#line 311 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str32, ei_cp932}, + {-1}, +#line 195 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str34, ei_cp1258}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 57 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str40, ei_iso8859_1}, +#line 60 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str41, ei_iso8859_1}, +#line 134 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str42, ei_iso8859_10}, +#line 76 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str43, ei_iso8859_3}, + {-1}, +#line 126 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str45, ei_iso8859_9}, +#line 68 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str46, ei_iso8859_2}, + {-1}, {-1}, +#line 151 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str49, ei_iso8859_14}, + {-1}, {-1}, {-1}, +#line 318 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str53, ei_euc_cn}, + {-1}, {-1}, {-1}, +#line 62 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str57, ei_iso8859_1}, +#line 139 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str58, ei_iso8859_11}, +#line 102 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str59, ei_iso8859_6}, +#line 166 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str60, ei_iso8859_16}, +#line 78 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str61, ei_iso8859_3}, +#line 145 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str62, ei_iso8859_13}, + {-1}, {-1}, +#line 93 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str65, ei_iso8859_5}, +#line 159 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str66, ei_iso8859_15}, +#line 70 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str67, ei_iso8859_2}, + {-1}, {-1}, +#line 317 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str70, ei_euc_cn}, + {-1}, {-1}, +#line 120 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str73, ei_iso8859_8}, +#line 53 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str74, ei_iso8859_1}, +#line 137 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str75, ei_iso8859_11}, +#line 94 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str76, ei_iso8859_6}, +#line 160 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str77, ei_iso8859_16}, +#line 71 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str78, ei_iso8859_3}, +#line 140 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str79, ei_iso8859_13}, + {-1}, +#line 128 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str81, ei_iso8859_9}, +#line 87 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str82, ei_iso8859_5}, +#line 154 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str83, ei_iso8859_15}, +#line 63 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str84, ei_iso8859_2}, +#line 286 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str85, ei_iso646_cn}, +#line 227 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str86, ei_hp_roman8}, + {-1}, +#line 84 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str88, ei_iso8859_4}, + {-1}, +#line 114 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str90, ei_iso8859_8}, +#line 350 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str91, ei_cp949}, +#line 54 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str92, ei_iso8859_1}, +#line 138 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str93, ei_iso8859_11}, +#line 95 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str94, ei_iso8859_6}, +#line 161 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str95, ei_iso8859_16}, +#line 72 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str96, ei_iso8859_3}, +#line 141 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str97, ei_iso8859_13}, +#line 121 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str98, ei_iso8859_9}, +#line 162 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str99, ei_iso8859_16}, +#line 88 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str100, ei_iso8859_5}, +#line 155 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str101, ei_iso8859_15}, +#line 64 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str102, ei_iso8859_2}, +#line 59 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str103, ei_iso8859_1}, + {-1}, +#line 133 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str105, ei_iso8859_10}, +#line 236 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str106, ei_pt154}, +#line 75 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str107, ei_iso8859_3}, +#line 115 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str108, ei_iso8859_8}, + {-1}, +#line 156 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str110, ei_iso8859_15}, +#line 125 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str111, ei_iso8859_9}, +#line 183 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str112, ei_cp1254}, +#line 67 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str113, ei_iso8859_2}, +#line 328 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str114, ei_iso2022_cn}, + {-1}, +#line 122 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str116, ei_iso8859_9}, +#line 293 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str117, ei_gb2312}, +#line 16 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str118, ei_ascii}, +#line 150 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str119, ei_iso8859_14}, +#line 13 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str120, ei_ascii}, +#line 252 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str121, ei_tis620}, +#line 282 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str122, ei_jisx0212}, + {-1}, +#line 255 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str124, ei_viscii}, +#line 107 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str125, ei_iso8859_7}, +#line 22 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str126, ei_ascii}, +#line 294 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str127, ei_isoir165}, + {-1}, +#line 257 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str129, ei_viscii}, +#line 163 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str130, ei_iso8859_16}, +#line 212 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str131, ei_mac_roman}, + {-1}, {-1}, {-1}, {-1}, +#line 117 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str136, ei_iso8859_8}, +#line 291 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str137, ei_gb2312}, + {-1}, +#line 206 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str139, ei_cp866}, + {-1}, {-1}, +#line 327 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str142, ei_iso2022_cn}, +#line 324 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str143, ei_cp936}, +#line 158 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str144, ei_iso8859_15}, + {-1}, +#line 283 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str146, ei_jisx0212}, +#line 202 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str147, ei_cp862}, + {-1}, {-1}, +#line 21 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str150, ei_ascii}, +#line 86 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str151, ei_iso8859_4}, +#line 153 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str152, ei_iso8859_14}, +#line 148 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str153, ei_iso8859_14}, +#line 149 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str154, ei_iso8859_14}, + {-1}, +#line 351 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str156, ei_cp949}, +#line 199 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str157, ei_cp850}, + {-1}, +#line 330 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str159, ei_hz}, +#line 58 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str160, ei_iso8859_1}, + {-1}, +#line 152 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str162, ei_iso8859_14}, +#line 109 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str163, ei_iso8859_7}, +#line 171 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str164, ei_cp1250}, +#line 319 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str165, ei_euc_cn}, +#line 197 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str166, ei_cp850}, + {-1}, +#line 79 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str168, ei_iso8859_4}, +#line 146 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str169, ei_iso8859_14}, +#line 341 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str170, ei_cp950}, +#line 91 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str171, ei_iso8859_5}, + {-1}, {-1}, {-1}, {-1}, +#line 131 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str176, ei_iso8859_10}, + {-1}, {-1}, +#line 24 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str179, ei_ucs2}, +#line 258 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str180, ei_tcvn}, +#line 124 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str181, ei_iso8859_9}, + {-1}, {-1}, {-1}, +#line 269 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str185, ei_jisx0201}, +#line 80 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str186, ei_iso8859_4}, +#line 147 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str187, ei_iso8859_14}, +#line 165 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str188, ei_iso8859_16}, +#line 299 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str189, ei_ksc5601}, + {-1}, +#line 66 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str191, ei_iso8859_2}, + {-1}, {-1}, {-1}, {-1}, +#line 329 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str196, ei_iso2022_cn_ext}, +#line 83 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str197, ei_iso8859_4}, + {-1}, {-1}, +#line 157 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str200, ei_iso8859_15}, +#line 275 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str201, ei_jisx0208}, +#line 296 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str202, ei_ksc5601}, + {-1}, +#line 136 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str204, ei_iso8859_10}, + {-1}, {-1}, +#line 256 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str207, ei_viscii}, + {-1}, +#line 144 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str209, ei_iso8859_13}, + {-1}, +#line 264 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str211, ei_iso646_jp}, +#line 234 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str212, ei_pt154}, +#line 247 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str213, ei_tis620}, + {-1}, +#line 74 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str215, ei_iso8859_3}, +#line 30 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str216, ei_ucs2be}, +#line 233 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str217, ei_koi8_t}, +#line 239 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str218, ei_rk1048}, + {-1}, {-1}, +#line 129 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str221, ei_iso8859_10}, +#line 251 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str222, ei_tis620}, +#line 14 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str223, ei_ascii}, +#line 61 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str224, ei_iso8859_1}, + {-1}, +#line 135 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str226, ei_iso8859_10}, + {-1}, +#line 77 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str228, ei_iso8859_3}, + {-1}, +#line 246 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str230, ei_tis620}, + {-1}, +#line 127 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str232, ei_iso8859_9}, + {-1}, +#line 69 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str234, ei_iso8859_2}, +#line 249 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str235, ei_tis620}, +#line 242 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str236, ei_rk1048}, +#line 92 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str237, ei_iso8859_5}, +#line 241 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str238, ei_rk1048}, +#line 130 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str239, ei_iso8859_10}, + {-1}, +#line 29 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str241, ei_ucs2be}, +#line 38 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str242, ei_utf16}, + {-1}, {-1}, +#line 173 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str245, ei_cp1250}, + {-1}, {-1}, +#line 26 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str248, ei_ucs2}, +#line 168 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str249, ei_koi8_r}, +#line 164 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str250, ei_iso8859_16}, + {-1}, +#line 41 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str252, ei_utf32}, + {-1}, +#line 35 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str254, ei_ucs4}, +#line 23 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str255, ei_utf8}, + {-1}, {-1}, {-1}, +#line 90 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str259, ei_iso8859_5}, + {-1}, +#line 167 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str261, ei_koi8_r}, +#line 179 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str262, ei_cp1252}, +#line 33 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str263, ei_ucs4}, +#line 82 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str264, ei_iso8859_4}, + {-1}, +#line 245 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str266, ei_cp1133}, +#line 208 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str267, ei_cp866}, + {-1}, {-1}, +#line 298 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str270, ei_ksc5601}, +#line 356 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str271, ei_local_char}, + {-1}, +#line 348 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str273, ei_euc_kr}, + {-1}, {-1}, {-1}, +#line 335 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str277, ei_ces_big5}, +#line 253 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str278, ei_cp874}, +#line 230 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str279, ei_armscii_8}, + {-1}, {-1}, +#line 340 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str282, ei_ces_big5}, +#line 31 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str283, ei_ucs2le}, + {-1}, {-1}, +#line 198 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str286, ei_cp850}, +#line 12 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str287, ei_ascii}, + {-1}, {-1}, +#line 347 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str290, ei_euc_kr}, + {-1}, {-1}, +#line 321 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str293, ei_euc_cn}, +#line 336 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str294, ei_ces_big5}, +#line 250 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str295, ei_tis620}, + {-1}, {-1}, {-1}, +#line 339 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str299, ei_ces_big5}, + {-1}, {-1}, +#line 218 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str302, ei_mac_cyrillic}, +#line 322 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str303, ei_ces_gbk}, +#line 248 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str304, ei_tis620}, +#line 176 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str305, ei_cp1251}, + {-1}, +#line 237 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str307, ei_pt154}, +#line 108 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str308, ei_iso8859_7}, + {-1}, +#line 142 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str310, ei_iso8859_13}, +#line 110 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str311, ei_iso8859_7}, + {-1}, {-1}, {-1}, +#line 301 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str315, ei_ksc5601}, + {-1}, {-1}, +#line 85 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str318, ei_iso8859_4}, + {-1}, {-1}, +#line 25 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str321, ei_ucs2}, + {-1}, {-1}, {-1}, +#line 37 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str325, ei_ucs4le}, +#line 235 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str326, ei_pt154}, + {-1}, {-1}, {-1}, +#line 266 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str330, ei_iso646_jp}, + {-1}, {-1}, {-1}, +#line 355 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str334, ei_iso2022_kr}, + {-1}, +#line 226 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str336, ei_hp_roman8}, +#line 56 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str337, ei_iso8859_1}, + {-1}, {-1}, +#line 277 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str340, ei_jisx0208}, + {-1}, {-1}, {-1}, +#line 101 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str344, ei_iso8859_6}, + {-1}, {-1}, +#line 19 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str347, ei_ascii}, + {-1}, {-1}, +#line 40 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str350, ei_utf16le}, +#line 15 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str351, ei_ascii}, + {-1}, {-1}, +#line 192 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str354, ei_cp1257}, +#line 215 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str355, ei_mac_iceland}, +#line 43 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str356, ei_utf32le}, +#line 300 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str357, ei_ksc5601}, + {-1}, +#line 100 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str359, ei_iso8859_6}, + {-1}, {-1}, +#line 354 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str362, ei_iso2022_kr}, +#line 34 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str363, ei_ucs4}, + {-1}, {-1}, {-1}, +#line 27 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str367, ei_ucs2be}, +#line 290 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str368, ei_gb2312}, +#line 265 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str369, ei_iso646_jp}, + {-1}, +#line 243 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str371, ei_mulelao}, +#line 284 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str372, ei_jisx0212}, +#line 111 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str373, ei_iso8859_7}, + {-1}, +#line 260 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str375, ei_tcvn}, +#line 292 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str376, ei_gb2312}, + {-1}, +#line 326 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str378, ei_gb18030}, +#line 259 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str379, ei_tcvn}, + {-1}, {-1}, {-1}, {-1}, +#line 285 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str384, ei_iso646_cn}, +#line 238 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str385, ei_pt154}, +#line 98 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str386, ei_iso8859_6}, + {-1}, +#line 46 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str388, ei_utf7}, + {-1}, {-1}, +#line 18 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str391, ei_ascii}, +#line 32 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str392, ei_ucs2le}, +#line 113 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str393, ei_iso8859_7}, + {-1}, +#line 295 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str395, ei_isoir165}, +#line 240 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str396, ei_rk1048}, + {-1}, +#line 17 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str398, ei_ascii}, + {-1}, {-1}, {-1}, {-1}, +#line 169 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str403, ei_koi8_u}, + {-1}, {-1}, +#line 47 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str406, ei_ucs2internal}, + {-1}, {-1}, +#line 36 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str409, ei_ucs4be}, +#line 103 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str410, ei_iso8859_7}, +#line 307 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str411, ei_sjis}, +#line 320 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str412, ei_euc_cn}, +#line 262 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str413, ei_iso646_jp}, + {-1}, +#line 45 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str415, ei_utf7}, +#line 175 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str416, ei_cp1251}, +#line 190 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str417, ei_cp1256}, +#line 181 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str418, ei_cp1253}, + {-1}, +#line 187 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str420, ei_cp1255}, +#line 178 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str421, ei_cp1252}, +#line 325 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str422, ei_cp936}, + {-1}, +#line 196 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str424, ei_cp1258}, +#line 349 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str425, ei_euc_kr}, +#line 297 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str426, ei_ksc5601}, + {-1}, +#line 104 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str428, ei_iso8859_7}, +#line 306 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str429, ei_sjis}, + {-1}, {-1}, {-1}, +#line 274 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str433, ei_jisx0208}, +#line 39 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str434, ei_utf16be}, + {-1}, {-1}, {-1}, {-1}, +#line 143 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str439, ei_iso8859_13}, +#line 42 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str440, ei_utf32be}, + {-1}, {-1}, {-1}, {-1}, +#line 224 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str445, ei_mac_thai}, + {-1}, {-1}, +#line 49 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str448, ei_ucs4internal}, +#line 112 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str449, ei_iso8859_7}, + {-1}, +#line 210 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str451, ei_mac_roman}, +#line 304 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str452, ei_euc_jp}, + {-1}, {-1}, {-1}, +#line 333 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str456, ei_euc_tw}, +#line 287 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str457, ei_iso646_cn}, +#line 132 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str458, ei_iso8859_10}, +#line 97 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str459, ei_iso8859_6}, + {-1}, +#line 276 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str461, ei_jisx0208}, + {-1}, +#line 184 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str463, ei_cp1254}, +#line 73 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str464, ei_iso8859_3}, + {-1}, +#line 89 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str466, ei_iso8859_5}, +#line 20 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str467, ei_ascii}, + {-1}, {-1}, +#line 116 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str470, ei_iso8859_8}, +#line 331 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str471, ei_hz}, + {-1}, +#line 332 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str473, ei_euc_tw}, +#line 289 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str474, ei_iso646_cn}, +#line 229 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str475, ei_nextstep}, +#line 316 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str476, ei_iso2022_jp2}, + {-1}, +#line 123 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str478, ei_iso8859_9}, + {-1}, +#line 170 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str480, ei_koi8_ru}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 211 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str487, ei_mac_roman}, + {-1}, +#line 172 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str489, ei_cp1250}, + {-1}, {-1}, +#line 279 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str492, ei_jisx0212}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 314 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str500, ei_iso2022_jp1}, +#line 216 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str501, ei_mac_croatian}, +#line 225 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str502, ei_hp_roman8}, + {-1}, {-1}, +#line 315 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str505, ei_iso2022_jp2}, + {-1}, {-1}, {-1}, +#line 81 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str509, ei_iso8859_4}, +#line 345 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str510, ei_big5hkscs2004}, + {-1}, {-1}, {-1}, {-1}, +#line 99 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str515, ei_iso8859_6}, + {-1}, {-1}, +#line 303 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str518, ei_euc_jp}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 338 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str525, ei_ces_big5}, + {-1}, +#line 344 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str527, ei_big5hkscs2004}, + {-1}, {-1}, {-1}, +#line 214 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str531, ei_mac_centraleurope}, +#line 204 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str532, ei_cp862}, + {-1}, {-1}, +#line 302 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str535, ei_euc_jp}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 337 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str542, ei_ces_big5}, + {-1}, {-1}, {-1}, +#line 310 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str546, ei_sjis}, + {-1}, {-1}, {-1}, +#line 263 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str550, ei_iso646_jp}, + {-1}, {-1}, {-1}, +#line 268 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str554, ei_jisx0201}, +#line 267 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str555, ei_jisx0201}, +#line 119 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str556, ei_iso8859_8}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 223 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str563, ei_mac_arabic}, +#line 278 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str564, ei_jisx0208}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 271 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str571, ei_jisx0208}, + {-1}, {-1}, {-1}, +#line 44 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str575, ei_utf7}, + {-1}, +#line 220 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str577, ei_mac_greek}, + {-1}, +#line 313 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str579, ei_iso2022_jp}, +#line 185 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str580, ei_cp1254}, +#line 281 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str581, ei_jisx0212}, + {-1}, {-1}, +#line 193 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str584, ei_cp1257}, + {-1}, +#line 272 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str586, ei_jisx0208}, + {-1}, {-1}, {-1}, +#line 182 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str590, ei_cp1253}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 228 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str599, ei_hp_roman8}, +#line 52 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str600, ei_java}, +#line 188 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str601, ei_cp1255}, + {-1}, {-1}, +#line 213 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str604, ei_mac_roman}, + {-1}, {-1}, +#line 312 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str607, ei_iso2022_jp}, +#line 334 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str608, ei_euc_tw}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 232 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str614, ei_georgian_ps}, +#line 28 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str615, ei_ucs2be}, + {-1}, +#line 309 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str617, ei_sjis}, + {-1}, {-1}, +#line 200 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str620, ei_cp850}, +#line 219 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str621, ei_mac_ukraine}, +#line 55 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str622, ei_iso8859_1}, +#line 96 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str623, ei_iso8859_6}, +#line 106 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str624, ei_iso8859_7}, + {-1}, +#line 231 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str626, ei_georgian_academy}, +#line 65 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str627, ei_iso8859_2}, + {-1}, +#line 280 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str629, ei_jisx0212}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 273 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str657, ei_jisx0208}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 357 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str664, ei_local_wchar_t}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 217 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str673, ei_mac_romania}, + {-1}, {-1}, +#line 254 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str676, ei_cp874}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, +#line 305 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str689, ei_euc_jp}, + {-1}, +#line 191 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str691, ei_cp1256}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, +#line 48 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str723, ei_ucs2swapped}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 261 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str739, ei_tcvn}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 118 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str746, ei_iso8859_8}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 50 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str765, ei_ucs4swapped}, + {-1}, {-1}, +#line 352 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str768, ei_johab}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 221 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str786, ei_mac_turkish}, + {-1}, {-1}, {-1}, +#line 105 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str790, ei_iso8859_7}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 194 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str842, ei_cp1257}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 343 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str888, ei_big5hkscs2001}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 270 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str898, ei_jisx0201}, + {-1}, +#line 342 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str900, ei_big5hkscs1999}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 222 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str908, ei_mac_hebrew}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 346 "lib/aliases.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str935, ei_big5hkscs2004} + }; + +#ifdef __GNUC__ +__inline +#if defined __GNUC_STDC_INLINE__ || defined __GNUC_GNU_INLINE__ +__attribute__ ((__gnu_inline__)) +#endif +#endif +const struct alias * +aliases_lookup (register const char *str, register unsigned int len) +{ + if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) + { + register int key = aliases_hash (str, len); + + if (key <= MAX_HASH_VALUE && key >= 0) + { + register int o = aliases[key].name; + if (o >= 0) + { + register const char *s = o + stringpool; + + if (*str == *s && !strcmp (str + 1, s + 1)) + return &aliases[key]; + } + } + } + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/aliases2.h b/graf2d/win32gdk/gdk/src/iconv/aliases2.h new file mode 100644 index 0000000000000..7f2dc449bf198 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/aliases2.h @@ -0,0 +1,40 @@ +/* + * Copyright (C) 1999-2003, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +#ifdef USE_AIX +# if defined _AIX +# include "aliases_aix_sysaix.h" +# else +# include "aliases_aix.h" +# endif +#endif +#ifdef USE_OSF1 +# if defined __osf__ +# include "aliases_osf1_sysosf1.h" +# else +# include "aliases_osf1.h" +# endif +#endif +#ifdef USE_DOS +# include "aliases_dos.h" +#endif +#ifdef USE_EXTRA +# include "aliases_extra.h" +#endif diff --git a/graf2d/win32gdk/gdk/src/iconv/aliases_aix.h b/graf2d/win32gdk/gdk/src/iconv/aliases_aix.h new file mode 100644 index 0000000000000..5cbc77fdf6c53 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/aliases_aix.h @@ -0,0 +1,18 @@ + S(aix_0, "CP856", ei_cp856 ) + S(aix_1, "CP922", ei_cp922 ) + S(aix_2, "CP943", ei_cp943 ) + S(aix_3, "CP1046", ei_cp1046 ) + S(aix_4, "CP1124", ei_cp1124 ) + S(aix_5, "CP1129", ei_cp1129 ) + S(aix_6, "CP1161", ei_cp1161 ) + S(aix_7, "IBM1161", ei_cp1161 ) + S(aix_8, "IBM-1161", ei_cp1161 ) + S(aix_9, "CSIBM1161", ei_cp1161 ) + S(aix_10, "CP1162", ei_cp1162 ) + S(aix_11, "IBM1162", ei_cp1162 ) + S(aix_12, "IBM-1162", ei_cp1162 ) + S(aix_13, "CSIBM1162", ei_cp1162 ) + S(aix_14, "CP1163", ei_cp1163 ) + S(aix_15, "IBM1163", ei_cp1163 ) + S(aix_16, "IBM-1163", ei_cp1163 ) + S(aix_17, "CSIBM1163", ei_cp1163 ) diff --git a/graf2d/win32gdk/gdk/src/iconv/aliases_aix_sysaix.h b/graf2d/win32gdk/gdk/src/iconv/aliases_aix_sysaix.h new file mode 100644 index 0000000000000..b7dc5841ebd28 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/aliases_aix_sysaix.h @@ -0,0 +1,24 @@ + S(aix_0, "CP856", ei_cp856 ) + S(aix_1, "IBM-856", ei_cp856 ) + S(aix_2, "CP922", ei_cp922 ) + S(aix_3, "IBM-922", ei_cp922 ) + S(aix_4, "CP943", ei_cp943 ) + S(aix_5, "IBM-943", ei_cp943 ) + S(aix_6, "CP1046", ei_cp1046 ) + S(aix_7, "IBM-1046", ei_cp1046 ) + S(aix_8, "CP1124", ei_cp1124 ) + S(aix_9, "IBM-1124", ei_cp1124 ) + S(aix_10, "CP1129", ei_cp1129 ) + S(aix_11, "IBM-1129", ei_cp1129 ) + S(aix_12, "CP1161", ei_cp1161 ) + S(aix_13, "IBM1161", ei_cp1161 ) + S(aix_14, "IBM-1161", ei_cp1161 ) + S(aix_15, "CSIBM1161", ei_cp1161 ) + S(aix_16, "CP1162", ei_cp1162 ) + S(aix_17, "IBM1162", ei_cp1162 ) + S(aix_18, "IBM-1162", ei_cp1162 ) + S(aix_19, "CSIBM1162", ei_cp1162 ) + S(aix_20, "CP1163", ei_cp1163 ) + S(aix_21, "IBM1163", ei_cp1163 ) + S(aix_22, "IBM-1163", ei_cp1163 ) + S(aix_23, "CSIBM1163", ei_cp1163 ) diff --git a/graf2d/win32gdk/gdk/src/iconv/aliases_dos.h b/graf2d/win32gdk/gdk/src/iconv/aliases_dos.h new file mode 100644 index 0000000000000..1dd4fcba01aec --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/aliases_dos.h @@ -0,0 +1,48 @@ + S(dos_0, "CP437", ei_cp437 ) + S(dos_1, "IBM437", ei_cp437 ) + S(dos_2, "437", ei_cp437 ) + S(dos_3, "CSPC8CODEPAGE437", ei_cp437 ) + S(dos_4, "CP737", ei_cp737 ) + S(dos_5, "CP775", ei_cp775 ) + S(dos_6, "IBM775", ei_cp775 ) + S(dos_7, "CSPC775BALTIC", ei_cp775 ) + S(dos_8, "CP852", ei_cp852 ) + S(dos_9, "IBM852", ei_cp852 ) + S(dos_10, "852", ei_cp852 ) + S(dos_11, "CSPCP852", ei_cp852 ) + S(dos_12, "CP853", ei_cp853 ) + S(dos_13, "CP855", ei_cp855 ) + S(dos_14, "IBM855", ei_cp855 ) + S(dos_15, "855", ei_cp855 ) + S(dos_16, "CSIBM855", ei_cp855 ) + S(dos_17, "CP857", ei_cp857 ) + S(dos_18, "IBM857", ei_cp857 ) + S(dos_19, "857", ei_cp857 ) + S(dos_20, "CSIBM857", ei_cp857 ) + S(dos_21, "CP858", ei_cp858 ) + S(dos_22, "CP860", ei_cp860 ) + S(dos_23, "IBM860", ei_cp860 ) + S(dos_24, "860", ei_cp860 ) + S(dos_25, "CSIBM860", ei_cp860 ) + S(dos_26, "CP861", ei_cp861 ) + S(dos_27, "IBM861", ei_cp861 ) + S(dos_28, "861", ei_cp861 ) + S(dos_29, "CP-IS", ei_cp861 ) + S(dos_30, "CSIBM861", ei_cp861 ) + S(dos_31, "CP863", ei_cp863 ) + S(dos_32, "IBM863", ei_cp863 ) + S(dos_33, "863", ei_cp863 ) + S(dos_34, "CSIBM863", ei_cp863 ) + S(dos_35, "CP864", ei_cp864 ) + S(dos_36, "IBM864", ei_cp864 ) + S(dos_37, "CSIBM864", ei_cp864 ) + S(dos_38, "CP865", ei_cp865 ) + S(dos_39, "IBM865", ei_cp865 ) + S(dos_40, "865", ei_cp865 ) + S(dos_41, "CSIBM865", ei_cp865 ) + S(dos_42, "CP869", ei_cp869 ) + S(dos_43, "IBM869", ei_cp869 ) + S(dos_44, "869", ei_cp869 ) + S(dos_45, "CP-GR", ei_cp869 ) + S(dos_46, "CSIBM869", ei_cp869 ) + S(dos_47, "CP1125", ei_cp1125 ) diff --git a/graf2d/win32gdk/gdk/src/iconv/aliases_extra.h b/graf2d/win32gdk/gdk/src/iconv/aliases_extra.h new file mode 100644 index 0000000000000..9a54e16a0731f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/aliases_extra.h @@ -0,0 +1,12 @@ + S(extra_0, "EUC-JISX0213", ei_euc_jisx0213 ) + S(extra_1, "EUC-JIS-2004", ei_euc_jisx0213 ) + S(extra_2, "SHIFT_JISX0213", ei_shift_jisx0213 ) + S(extra_3, "SHIFT_JIS-2004", ei_shift_jisx0213 ) + S(extra_4, "ISO-2022-JP-3", ei_iso2022_jp3 ) + S(extra_5, "ISO-2022-JP-2004", ei_iso2022_jp3 ) + S(extra_6, "BIG5-2003", ei_big5_2003 ) + S(extra_7, "TDS565", ei_tds565 ) + S(extra_8, "ISO-IR-230", ei_tds565 ) + S(extra_9, "ATARIST", ei_atarist ) + S(extra_10, "ATARI", ei_atarist ) + S(extra_11, "RISCOS-LATIN1", ei_riscos1 ) diff --git a/graf2d/win32gdk/gdk/src/iconv/aliases_osf1.h b/graf2d/win32gdk/gdk/src/iconv/aliases_osf1.h new file mode 100644 index 0000000000000..9e4f6854ebcf6 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/aliases_osf1.h @@ -0,0 +1,2 @@ + S(osf1_0, "DEC-KANJI", ei_dec_kanji ) + S(osf1_1, "DEC-HANYU", ei_dec_hanyu ) diff --git a/graf2d/win32gdk/gdk/src/iconv/aliases_osf1_sysosf1.h b/graf2d/win32gdk/gdk/src/iconv/aliases_osf1_sysosf1.h new file mode 100644 index 0000000000000..b1f802d284465 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/aliases_osf1_sysosf1.h @@ -0,0 +1,4 @@ + S(osf1_0, "DEC-KANJI", ei_dec_kanji ) + S(osf1_1, "DECKANJI", ei_dec_kanji ) + S(osf1_2, "DEC-HANYU", ei_dec_hanyu ) + S(osf1_3, "DECHANYU", ei_dec_hanyu ) diff --git a/graf2d/win32gdk/gdk/src/iconv/aliases_sysaix.h b/graf2d/win32gdk/gdk/src/iconv/aliases_sysaix.h new file mode 100644 index 0000000000000..ee5d6a0289f2c --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/aliases_sysaix.h @@ -0,0 +1,1765 @@ +/* ANSI-C code produced by gperf version 3.0.4 */ +/* Command-line: gperf -m 10 lib/aliases_sysaix.gperf */ +/* Computed positions: -k'1,3-11,$' */ + +#if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ + && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ + && (')' == 41) && ('*' == 42) && ('+' == 43) && (',' == 44) \ + && ('-' == 45) && ('.' == 46) && ('/' == 47) && ('0' == 48) \ + && ('1' == 49) && ('2' == 50) && ('3' == 51) && ('4' == 52) \ + && ('5' == 53) && ('6' == 54) && ('7' == 55) && ('8' == 56) \ + && ('9' == 57) && (':' == 58) && (';' == 59) && ('<' == 60) \ + && ('=' == 61) && ('>' == 62) && ('?' == 63) && ('A' == 65) \ + && ('B' == 66) && ('C' == 67) && ('D' == 68) && ('E' == 69) \ + && ('F' == 70) && ('G' == 71) && ('H' == 72) && ('I' == 73) \ + && ('J' == 74) && ('K' == 75) && ('L' == 76) && ('M' == 77) \ + && ('N' == 78) && ('O' == 79) && ('P' == 80) && ('Q' == 81) \ + && ('R' == 82) && ('S' == 83) && ('T' == 84) && ('U' == 85) \ + && ('V' == 86) && ('W' == 87) && ('X' == 88) && ('Y' == 89) \ + && ('Z' == 90) && ('[' == 91) && ('\\' == 92) && (']' == 93) \ + && ('^' == 94) && ('_' == 95) && ('a' == 97) && ('b' == 98) \ + && ('c' == 99) && ('d' == 100) && ('e' == 101) && ('f' == 102) \ + && ('g' == 103) && ('h' == 104) && ('i' == 105) && ('j' == 106) \ + && ('k' == 107) && ('l' == 108) && ('m' == 109) && ('n' == 110) \ + && ('o' == 111) && ('p' == 112) && ('q' == 113) && ('r' == 114) \ + && ('s' == 115) && ('t' == 116) && ('u' == 117) && ('v' == 118) \ + && ('w' == 119) && ('x' == 120) && ('y' == 121) && ('z' == 122) \ + && ('{' == 123) && ('|' == 124) && ('}' == 125) && ('~' == 126)) +/* The character set is not based on ISO-646. */ +#error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gnu-gperf@gnu.org>." +#endif + +#line 1 "lib/aliases_sysaix.gperf" +struct alias { int name; unsigned int encoding_index; }; + +#define TOTAL_KEYWORDS 355 +#define MIN_WORD_LENGTH 2 +#define MAX_WORD_LENGTH 45 +#define MIN_HASH_VALUE 13 +#define MAX_HASH_VALUE 989 +/* maximum key range = 977, duplicates = 0 */ + +#ifdef __GNUC__ +__inline +#else +#ifdef __cplusplus +inline +#endif +#endif +static unsigned int +aliases_hash (register const char *str, register unsigned int len) +{ + static const unsigned short asso_values[] = + { + 990, 990, 990, 990, 990, 990, 990, 990, 990, 990, + 990, 990, 990, 990, 990, 990, 990, 990, 990, 990, + 990, 990, 990, 990, 990, 990, 990, 990, 990, 990, + 990, 990, 990, 990, 990, 990, 990, 990, 990, 990, + 990, 990, 990, 990, 990, 13, 112, 990, 73, 4, + 7, 6, 55, 8, 5, 171, 10, 23, 255, 990, + 990, 990, 990, 990, 990, 147, 128, 4, 9, 125, + 130, 5, 75, 4, 402, 69, 7, 125, 18, 4, + 44, 990, 76, 4, 25, 195, 191, 161, 120, 22, + 15, 990, 990, 990, 990, 27, 990, 990, 990, 990, + 990, 990, 990, 990, 990, 990, 990, 990, 990, 990, + 990, 990, 990, 990, 990, 990, 990, 990, 990, 990, + 990, 990, 990, 990, 990, 990, 990, 990 + }; + register int hval = len; + + switch (hval) + { + default: + hval += asso_values[(unsigned char)str[10]]; + /*FALLTHROUGH*/ + case 10: + hval += asso_values[(unsigned char)str[9]]; + /*FALLTHROUGH*/ + case 9: + hval += asso_values[(unsigned char)str[8]]; + /*FALLTHROUGH*/ + case 8: + hval += asso_values[(unsigned char)str[7]]; + /*FALLTHROUGH*/ + case 7: + hval += asso_values[(unsigned char)str[6]]; + /*FALLTHROUGH*/ + case 6: + hval += asso_values[(unsigned char)str[5]]; + /*FALLTHROUGH*/ + case 5: + hval += asso_values[(unsigned char)str[4]]; + /*FALLTHROUGH*/ + case 4: + hval += asso_values[(unsigned char)str[3]]; + /*FALLTHROUGH*/ + case 3: + hval += asso_values[(unsigned char)str[2]]; + /*FALLTHROUGH*/ + case 2: + case 1: + hval += asso_values[(unsigned char)str[0]]; + break; + } + return hval + asso_values[(unsigned char)str[len - 1]]; +} + +struct stringpool_t + { + char stringpool_str13[sizeof("L1")]; + char stringpool_str14[sizeof("L6")]; + char stringpool_str15[sizeof("L3")]; + char stringpool_str16[sizeof("L2")]; + char stringpool_str17[sizeof("L5")]; + char stringpool_str19[sizeof("L8")]; + char stringpool_str20[sizeof("SJIS")]; + char stringpool_str23[sizeof("866")]; + char stringpool_str24[sizeof("CN")]; + char stringpool_str27[sizeof("862")]; + char stringpool_str32[sizeof("CP1131")]; + char stringpool_str33[sizeof("CP1361")]; + char stringpool_str34[sizeof("CP866")]; + char stringpool_str36[sizeof("CP1133")]; + char stringpool_str37[sizeof("CP1251")]; + char stringpool_str38[sizeof("CP862")]; + char stringpool_str39[sizeof("CP1256")]; + char stringpool_str41[sizeof("CP1253")]; + char stringpool_str42[sizeof("GB2312")]; + char stringpool_str43[sizeof("CP1252")]; + char stringpool_str45[sizeof("CP1255")]; + char stringpool_str48[sizeof("CP936")]; + char stringpool_str49[sizeof("CP1258")]; + char stringpool_str52[sizeof("CP932")]; + char stringpool_str53[sizeof("C99")]; + char stringpool_str64[sizeof("L4")]; + char stringpool_str68[sizeof("LATIN1")]; + char stringpool_str69[sizeof("CP819")]; + char stringpool_str70[sizeof("LATIN6")]; + char stringpool_str72[sizeof("LATIN3")]; + char stringpool_str74[sizeof("LATIN2")]; + char stringpool_str76[sizeof("LATIN5")]; + char stringpool_str80[sizeof("LATIN8")]; + char stringpool_str88[sizeof("R8")]; + char stringpool_str89[sizeof("ISO8859-1")]; + char stringpool_str91[sizeof("ISO8859-6")]; + char stringpool_str92[sizeof("HZ")]; + char stringpool_str93[sizeof("ISO8859-3")]; + char stringpool_str94[sizeof("ISO8859-11")]; + char stringpool_str95[sizeof("ISO8859-2")]; + char stringpool_str96[sizeof("ISO8859-16")]; + char stringpool_str97[sizeof("ISO8859-5")]; + char stringpool_str98[sizeof("ISO8859-13")]; + char stringpool_str101[sizeof("ISO8859-8")]; + char stringpool_str102[sizeof("ISO8859-15")]; + char stringpool_str103[sizeof("ISO-8859-1")]; + char stringpool_str105[sizeof("ISO-8859-6")]; + char stringpool_str107[sizeof("ISO-8859-3")]; + char stringpool_str108[sizeof("ISO-8859-11")]; + char stringpool_str109[sizeof("ISO-8859-2")]; + char stringpool_str110[sizeof("ISO-8859-16")]; + char stringpool_str111[sizeof("ISO-8859-5")]; + char stringpool_str112[sizeof("ISO-8859-13")]; + char stringpool_str115[sizeof("ISO-8859-8")]; + char stringpool_str116[sizeof("ISO-8859-15")]; + char stringpool_str117[sizeof("ISO_8859-1")]; + char stringpool_str118[sizeof("CYRILLIC")]; + char stringpool_str119[sizeof("ISO_8859-6")]; + char stringpool_str120[sizeof("LATIN-9")]; + char stringpool_str121[sizeof("ISO_8859-3")]; + char stringpool_str122[sizeof("ISO_8859-11")]; + char stringpool_str123[sizeof("ISO_8859-2")]; + char stringpool_str124[sizeof("ISO_8859-16")]; + char stringpool_str125[sizeof("ISO_8859-5")]; + char stringpool_str126[sizeof("ISO_8859-13")]; + char stringpool_str127[sizeof("ISO8859-9")]; + char stringpool_str128[sizeof("ISO_8859-16:2001")]; + char stringpool_str129[sizeof("ISO_8859-8")]; + char stringpool_str130[sizeof("ISO_8859-15")]; + char stringpool_str131[sizeof("CP154")]; + char stringpool_str132[sizeof("ISO-IR-6")]; + char stringpool_str133[sizeof("CP949")]; + char stringpool_str135[sizeof("ISO646-CN")]; + char stringpool_str136[sizeof("MAC")]; + char stringpool_str137[sizeof("ISO_8859-15:1998")]; + char stringpool_str139[sizeof("CP1254")]; + char stringpool_str141[sizeof("ISO-8859-9")]; + char stringpool_str143[sizeof("ISO-IR-166")]; + char stringpool_str145[sizeof("ISO-IR-126")]; + char stringpool_str146[sizeof("GBK")]; + char stringpool_str148[sizeof("ISO-IR-226")]; + char stringpool_str149[sizeof("ISO-IR-165")]; + char stringpool_str150[sizeof("X0212")]; + char stringpool_str151[sizeof("ISO-IR-58")]; + char stringpool_str152[sizeof("KOI8-T")]; + char stringpool_str153[sizeof("BIG5")]; + char stringpool_str154[sizeof("ISO-IR-138")]; + char stringpool_str155[sizeof("ISO_8859-9")]; + char stringpool_str156[sizeof("L10")]; + char stringpool_str159[sizeof("850")]; + char stringpool_str160[sizeof("IBM866")]; + char stringpool_str161[sizeof("CSISO2022CN")]; + char stringpool_str163[sizeof("CSBIG5")]; + char stringpool_str164[sizeof("IBM862")]; + char stringpool_str167[sizeof("BIG-5")]; + char stringpool_str168[sizeof("ASCII")]; + char stringpool_str169[sizeof("MS936")]; + char stringpool_str170[sizeof("LATIN4")]; + char stringpool_str171[sizeof("PT154")]; + char stringpool_str172[sizeof("IBM-1131")]; + char stringpool_str173[sizeof("CP850")]; + char stringpool_str174[sizeof("EUCCN")]; + char stringpool_str175[sizeof("CP1250")]; + char stringpool_str176[sizeof("CSGB2312")]; + char stringpool_str177[sizeof("CN-BIG5")]; + char stringpool_str178[sizeof("CSASCII")]; + char stringpool_str179[sizeof("ISO-2022-CN")]; + char stringpool_str180[sizeof("L7")]; + char stringpool_str182[sizeof("ISO-IR-159")]; + char stringpool_str183[sizeof("IBM-1252")]; + char stringpool_str184[sizeof("ISO_8859-14:1998")]; + char stringpool_str186[sizeof("CP950")]; + char stringpool_str187[sizeof("IBM-921")]; + char stringpool_str188[sizeof("EUC-CN")]; + char stringpool_str190[sizeof("ISO-2022-CN-EXT")]; + char stringpool_str191[sizeof("ISO8859-4")]; + char stringpool_str192[sizeof("IBM-932")]; + char stringpool_str193[sizeof("TIS620")]; + char stringpool_str195[sizeof("IBM819")]; + char stringpool_str196[sizeof("ISO8859-14")]; + char stringpool_str197[sizeof("ISO-IR-199")]; + char stringpool_str199[sizeof("ISO_8859-10:1992")]; + char stringpool_str201[sizeof("US")]; + char stringpool_str202[sizeof("KSC_5601")]; + char stringpool_str203[sizeof("ISO-IR-148")]; + char stringpool_str204[sizeof("ISO-CELTIC")]; + char stringpool_str205[sizeof("ISO-8859-4")]; + char stringpool_str206[sizeof("UHC")]; + char stringpool_str207[sizeof("TIS-620")]; + char stringpool_str209[sizeof("ISO-IR-101")]; + char stringpool_str210[sizeof("ISO-8859-14")]; + char stringpool_str211[sizeof("LATIN10")]; + char stringpool_str213[sizeof("X0201")]; + char stringpool_str216[sizeof("ISO-IR-203")]; + char stringpool_str217[sizeof("VISCII")]; + char stringpool_str219[sizeof("ISO_8859-4")]; + char stringpool_str221[sizeof("PTCP154")]; + char stringpool_str224[sizeof("ISO_8859-14")]; + char stringpool_str225[sizeof("X0208")]; + char stringpool_str226[sizeof("IBM-CP1133")]; + char stringpool_str227[sizeof("CSVISCII")]; + char stringpool_str229[sizeof("ISO-IR-149")]; + char stringpool_str231[sizeof("UCS-2")]; + char stringpool_str232[sizeof("ISO8859-10")]; + char stringpool_str234[sizeof("RK1048")]; + char stringpool_str235[sizeof("GB_2312-80")]; + char stringpool_str236[sizeof("CSISOLATIN1")]; + char stringpool_str237[sizeof("ISO-IR-14")]; + char stringpool_str238[sizeof("CSISOLATIN6")]; + char stringpool_str239[sizeof("ELOT_928")]; + char stringpool_str240[sizeof("CSISOLATIN3")]; + char stringpool_str241[sizeof("KZ-1048")]; + char stringpool_str242[sizeof("CSISOLATIN2")]; + char stringpool_str243[sizeof("CSISOLATINCYRILLIC")]; + char stringpool_str244[sizeof("CSISOLATIN5")]; + char stringpool_str246[sizeof("ISO-8859-10")]; + char stringpool_str247[sizeof("ISO-IR-109")]; + char stringpool_str248[sizeof("CSKZ1048")]; + char stringpool_str250[sizeof("CSKOI8R")]; + char stringpool_str251[sizeof("GB18030")]; + char stringpool_str252[sizeof("CSPTCP154")]; + char stringpool_str254[sizeof("KOI8-R")]; + char stringpool_str256[sizeof("TCVN")]; + char stringpool_str258[sizeof("GB_1988-80")]; + char stringpool_str260[sizeof("ISO_8859-10")]; + char stringpool_str261[sizeof("MS-CYRL")]; + char stringpool_str268[sizeof("CSISO58GB231280")]; + char stringpool_str270[sizeof("TIS620.2533-1")]; + char stringpool_str271[sizeof("KS_C_5601-1989")]; + char stringpool_str272[sizeof("MACCYRILLIC")]; + char stringpool_str275[sizeof("HZ-GB-2312")]; + char stringpool_str277[sizeof("CN-GB-ISOIR165")]; + char stringpool_str278[sizeof("ISO-IR-110")]; + char stringpool_str281[sizeof("TIS620-0")]; + char stringpool_str283[sizeof("CN-GB")]; + char stringpool_str288[sizeof("TIS620.2529-1")]; + char stringpool_str293[sizeof("ISO-IR-144")]; + char stringpool_str294[sizeof("CSIBM866")]; + char stringpool_str298[sizeof("ISO646-US")]; + char stringpool_str299[sizeof("IBM850")]; + char stringpool_str300[sizeof("CP874")]; + char stringpool_str302[sizeof("CYRILLIC-ASIAN")]; + char stringpool_str306[sizeof("CSISOLATINGREEK")]; + char stringpool_str307[sizeof("CHAR")]; + char stringpool_str310[sizeof("BIG5HKSCS")]; + char stringpool_str313[sizeof("IBM-850")]; + char stringpool_str322[sizeof("MS-ANSI")]; + char stringpool_str323[sizeof("CSUCS4")]; + char stringpool_str324[sizeof("BIG5-HKSCS")]; + char stringpool_str327[sizeof("UCS-4")]; + char stringpool_str330[sizeof("ARMSCII-8")]; + char stringpool_str335[sizeof("GEORGIAN-PS")]; + char stringpool_str338[sizeof("CSISOLATIN4")]; + char stringpool_str339[sizeof("TIS620.2533-0")]; + char stringpool_str342[sizeof("CSISO2022KR")]; + char stringpool_str343[sizeof("MACINTOSH")]; + char stringpool_str345[sizeof("ISO-IR-179")]; + char stringpool_str347[sizeof("ISO-IR-100")]; + char stringpool_str350[sizeof("GREEK8")]; + char stringpool_str355[sizeof("EUCKR")]; + char stringpool_str358[sizeof("UTF-16")]; + char stringpool_str359[sizeof("VISCII1.1-1")]; + char stringpool_str360[sizeof("ISO-2022-KR")]; + char stringpool_str362[sizeof("CP367")]; + char stringpool_str363[sizeof("UTF-8")]; + char stringpool_str364[sizeof("UTF-32")]; + char stringpool_str369[sizeof("EUC-KR")]; + char stringpool_str371[sizeof("CP1257")]; + char stringpool_str378[sizeof("CSISO57GB1988")]; + char stringpool_str382[sizeof("CSKSC56011987")]; + char stringpool_str383[sizeof("US-ASCII")]; + char stringpool_str384[sizeof("CSISOLATINARABIC")]; + char stringpool_str385[sizeof("ISO_8859-3:1988")]; + char stringpool_str386[sizeof("CSUNICODE11")]; + char stringpool_str387[sizeof("ISO_8859-5:1988")]; + char stringpool_str389[sizeof("ISO_8859-8:1988")]; + char stringpool_str390[sizeof("UNICODE-1-1")]; + char stringpool_str391[sizeof("MACTHAI")]; + char stringpool_str392[sizeof("ROMAN8")]; + char stringpool_str393[sizeof("ISO-10646-UCS-2")]; + char stringpool_str398[sizeof("GREEK")]; + char stringpool_str402[sizeof("LATIN7")]; + char stringpool_str404[sizeof("STRK1048-2002")]; + char stringpool_str405[sizeof("WINDOWS-1251")]; + char stringpool_str406[sizeof("WINDOWS-1256")]; + char stringpool_str407[sizeof("WINDOWS-1253")]; + char stringpool_str408[sizeof("WINDOWS-1252")]; + char stringpool_str409[sizeof("WINDOWS-1255")]; + char stringpool_str411[sizeof("WINDOWS-1258")]; + char stringpool_str412[sizeof("CHINESE")]; + char stringpool_str413[sizeof("NEXTSTEP")]; + char stringpool_str415[sizeof("ISO_8859-9:1989")]; + char stringpool_str419[sizeof("KS_C_5601-1987")]; + char stringpool_str420[sizeof("WINDOWS-936")]; + char stringpool_str423[sizeof("ISO8859-7")]; + char stringpool_str434[sizeof("ISO_8859-4:1988")]; + char stringpool_str436[sizeof("CSPC862LATINHEBREW")]; + char stringpool_str437[sizeof("ISO-8859-7")]; + char stringpool_str440[sizeof("ARABIC")]; + char stringpool_str441[sizeof("ISO-10646-UCS-4")]; + char stringpool_str445[sizeof("MULELAO-1")]; + char stringpool_str446[sizeof("ECMA-118")]; + char stringpool_str448[sizeof("JP")]; + char stringpool_str451[sizeof("ISO_8859-7")]; + char stringpool_str453[sizeof("TCVN-5712")]; + char stringpool_str455[sizeof("TCVN5712-1")]; + char stringpool_str456[sizeof("WINDOWS-1254")]; + char stringpool_str459[sizeof("KOREAN")]; + char stringpool_str461[sizeof("GEORGIAN-ACADEMY")]; + char stringpool_str462[sizeof("MACICELAND")]; + char stringpool_str469[sizeof("CSISOLATINHEBREW")]; + char stringpool_str473[sizeof("ISO-IR-57")]; + char stringpool_str474[sizeof("WINDOWS-1250")]; + char stringpool_str475[sizeof("ISO-IR-87")]; + char stringpool_str477[sizeof("ISO-IR-127")]; + char stringpool_str478[sizeof("ISO-IR-157")]; + char stringpool_str481[sizeof("EUCTW")]; + char stringpool_str483[sizeof("UCS-2LE")]; + char stringpool_str487[sizeof("HP-ROMAN8")]; + char stringpool_str488[sizeof("IBM367")]; + char stringpool_str492[sizeof("KOI8-U")]; + char stringpool_str493[sizeof("UNICODEBIG")]; + char stringpool_str495[sizeof("EUC-TW")]; + char stringpool_str496[sizeof("CSMACINTOSH")]; + char stringpool_str497[sizeof("CSUNICODE")]; + char stringpool_str498[sizeof("JIS_C6226-1983")]; + char stringpool_str501[sizeof("UCS-2-INTERNAL")]; + char stringpool_str503[sizeof("ISO_646.IRV:1991")]; + char stringpool_str510[sizeof("CSISO14JISC6220RO")]; + char stringpool_str511[sizeof("ANSI_X3.4-1986")]; + char stringpool_str515[sizeof("IBM-EUCCN")]; + char stringpool_str516[sizeof("ANSI_X3.4-1968")]; + char stringpool_str518[sizeof("MS-EE")]; + char stringpool_str521[sizeof("CSPC850MULTILINGUAL")]; + char stringpool_str523[sizeof("CSHPROMAN8")]; + char stringpool_str525[sizeof("MACROMAN")]; + char stringpool_str531[sizeof("UCS-4LE")]; + char stringpool_str536[sizeof("ECMA-114")]; + char stringpool_str540[sizeof("UNICODELITTLE")]; + char stringpool_str543[sizeof("WCHAR_T")]; + char stringpool_str544[sizeof("ISO_8859-1:1987")]; + char stringpool_str545[sizeof("ISO_8859-6:1987")]; + char stringpool_str546[sizeof("ISO_8859-7:2003")]; + char stringpool_str547[sizeof("ISO_8859-2:1987")]; + char stringpool_str549[sizeof("UCS-4-INTERNAL")]; + char stringpool_str554[sizeof("CSISO159JISX02121990")]; + char stringpool_str556[sizeof("CSEUCKR")]; + char stringpool_str557[sizeof("CSUNICODE11UTF7")]; + char stringpool_str561[sizeof("ASMO-708")]; + char stringpool_str563[sizeof("UNICODE-1-1-UTF-7")]; + char stringpool_str567[sizeof("JIS_C6220-1969-RO")]; + char stringpool_str569[sizeof("KOI8-RU")]; + char stringpool_str572[sizeof("WINDOWS-1257")]; + char stringpool_str575[sizeof("CSISO2022JP2")]; + char stringpool_str579[sizeof("MS-TURK")]; + char stringpool_str583[sizeof("MACCROATIAN")]; + char stringpool_str584[sizeof("BIG5-HKSCS:2001")]; + char stringpool_str585[sizeof("ISO646-JP")]; + char stringpool_str586[sizeof("JIS0208")]; + char stringpool_str591[sizeof("ISO-2022-JP-1")]; + char stringpool_str594[sizeof("ISO-2022-JP-2")]; + char stringpool_str599[sizeof("SHIFT-JIS")]; + char stringpool_str603[sizeof("BIG5-HKSCS:1999")]; + char stringpool_str604[sizeof("UCS-2BE")]; + char stringpool_str606[sizeof("MACGREEK")]; + char stringpool_str611[sizeof("CSISO2022JP")]; + char stringpool_str612[sizeof("UTF-16LE")]; + char stringpool_str613[sizeof("SHIFT_JIS")]; + char stringpool_str615[sizeof("MS-GREEK")]; + char stringpool_str616[sizeof("UTF-32LE")]; + char stringpool_str624[sizeof("EUCJP")]; + char stringpool_str625[sizeof("MS-HEBR")]; + char stringpool_str629[sizeof("ISO-2022-JP")]; + char stringpool_str635[sizeof("BIG5-HKSCS:2004")]; + char stringpool_str638[sizeof("EUC-JP")]; + char stringpool_str648[sizeof("MACARABIC")]; + char stringpool_str652[sizeof("UCS-4BE")]; + char stringpool_str654[sizeof("UCS-2-SWAPPED")]; + char stringpool_str660[sizeof("JIS_X0212")]; + char stringpool_str662[sizeof("MACTURKISH")]; + char stringpool_str666[sizeof("CSSHIFTJIS")]; + char stringpool_str672[sizeof("WINDOWS-874")]; + char stringpool_str682[sizeof("CSEUCTW")]; + char stringpool_str685[sizeof("UTF-7")]; + char stringpool_str696[sizeof("IBM-EUCKR")]; + char stringpool_str702[sizeof("UCS-4-SWAPPED")]; + char stringpool_str711[sizeof("ISO_8859-7:1987")]; + char stringpool_str715[sizeof("BIGFIVE")]; + char stringpool_str717[sizeof("TCVN5712-1:1993")]; + char stringpool_str723[sizeof("JIS_X0201")]; + char stringpool_str729[sizeof("BIG-FIVE")]; + char stringpool_str732[sizeof("HEBREW")]; + char stringpool_str733[sizeof("UTF-16BE")]; + char stringpool_str735[sizeof("JIS_X0208")]; + char stringpool_str737[sizeof("UTF-32BE")]; + char stringpool_str741[sizeof("JISX0201-1976")]; + char stringpool_str748[sizeof("JIS_X0212-1990")]; + char stringpool_str752[sizeof("CSISO87JISX0208")]; + char stringpool_str753[sizeof("JIS_X0208-1983")]; + char stringpool_str771[sizeof("MS-ARAB")]; + char stringpool_str797[sizeof("MACCENTRALEUROPE")]; + char stringpool_str803[sizeof("CSHALFWIDTHKATAKANA")]; + char stringpool_str804[sizeof("MS_KANJI")]; + char stringpool_str807[sizeof("MACROMANIA")]; + char stringpool_str820[sizeof("JIS_X0208-1990")]; + char stringpool_str822[sizeof("IBM-EUCTW")]; + char stringpool_str826[sizeof("WINBALTRIM")]; + char stringpool_str846[sizeof("EXTENDED_UNIX_CODE_PACKED_FORMAT_FOR_JAPANESE")]; + char stringpool_str849[sizeof("JIS_X0212.1990-0")]; + char stringpool_str874[sizeof("CSEUCPKDFMTJAPANESE")]; + char stringpool_str885[sizeof("JOHAB")]; + char stringpool_str891[sizeof("JAVA")]; + char stringpool_str898[sizeof("MACUKRAINE")]; + char stringpool_str965[sizeof("IBM-EUCJP")]; + char stringpool_str989[sizeof("MACHEBREW")]; + }; +static const struct stringpool_t stringpool_contents = + { + "L1", + "L6", + "L3", + "L2", + "L5", + "L8", + "SJIS", + "866", + "CN", + "862", + "CP1131", + "CP1361", + "CP866", + "CP1133", + "CP1251", + "CP862", + "CP1256", + "CP1253", + "GB2312", + "CP1252", + "CP1255", + "CP936", + "CP1258", + "CP932", + "C99", + "L4", + "LATIN1", + "CP819", + "LATIN6", + "LATIN3", + "LATIN2", + "LATIN5", + "LATIN8", + "R8", + "ISO8859-1", + "ISO8859-6", + "HZ", + "ISO8859-3", + "ISO8859-11", + "ISO8859-2", + "ISO8859-16", + "ISO8859-5", + "ISO8859-13", + "ISO8859-8", + "ISO8859-15", + "ISO-8859-1", + "ISO-8859-6", + "ISO-8859-3", + "ISO-8859-11", + "ISO-8859-2", + "ISO-8859-16", + "ISO-8859-5", + "ISO-8859-13", + "ISO-8859-8", + "ISO-8859-15", + "ISO_8859-1", + "CYRILLIC", + "ISO_8859-6", + "LATIN-9", + "ISO_8859-3", + "ISO_8859-11", + "ISO_8859-2", + "ISO_8859-16", + "ISO_8859-5", + "ISO_8859-13", + "ISO8859-9", + "ISO_8859-16:2001", + "ISO_8859-8", + "ISO_8859-15", + "CP154", + "ISO-IR-6", + "CP949", + "ISO646-CN", + "MAC", + "ISO_8859-15:1998", + "CP1254", + "ISO-8859-9", + "ISO-IR-166", + "ISO-IR-126", + "GBK", + "ISO-IR-226", + "ISO-IR-165", + "X0212", + "ISO-IR-58", + "KOI8-T", + "BIG5", + "ISO-IR-138", + "ISO_8859-9", + "L10", + "850", + "IBM866", + "CSISO2022CN", + "CSBIG5", + "IBM862", + "BIG-5", + "ASCII", + "MS936", + "LATIN4", + "PT154", + "IBM-1131", + "CP850", + "EUCCN", + "CP1250", + "CSGB2312", + "CN-BIG5", + "CSASCII", + "ISO-2022-CN", + "L7", + "ISO-IR-159", + "IBM-1252", + "ISO_8859-14:1998", + "CP950", + "IBM-921", + "EUC-CN", + "ISO-2022-CN-EXT", + "ISO8859-4", + "IBM-932", + "TIS620", + "IBM819", + "ISO8859-14", + "ISO-IR-199", + "ISO_8859-10:1992", + "US", + "KSC_5601", + "ISO-IR-148", + "ISO-CELTIC", + "ISO-8859-4", + "UHC", + "TIS-620", + "ISO-IR-101", + "ISO-8859-14", + "LATIN10", + "X0201", + "ISO-IR-203", + "VISCII", + "ISO_8859-4", + "PTCP154", + "ISO_8859-14", + "X0208", + "IBM-CP1133", + "CSVISCII", + "ISO-IR-149", + "UCS-2", + "ISO8859-10", + "RK1048", + "GB_2312-80", + "CSISOLATIN1", + "ISO-IR-14", + "CSISOLATIN6", + "ELOT_928", + "CSISOLATIN3", + "KZ-1048", + "CSISOLATIN2", + "CSISOLATINCYRILLIC", + "CSISOLATIN5", + "ISO-8859-10", + "ISO-IR-109", + "CSKZ1048", + "CSKOI8R", + "GB18030", + "CSPTCP154", + "KOI8-R", + "TCVN", + "GB_1988-80", + "ISO_8859-10", + "MS-CYRL", + "CSISO58GB231280", + "TIS620.2533-1", + "KS_C_5601-1989", + "MACCYRILLIC", + "HZ-GB-2312", + "CN-GB-ISOIR165", + "ISO-IR-110", + "TIS620-0", + "CN-GB", + "TIS620.2529-1", + "ISO-IR-144", + "CSIBM866", + "ISO646-US", + "IBM850", + "CP874", + "CYRILLIC-ASIAN", + "CSISOLATINGREEK", + "CHAR", + "BIG5HKSCS", + "IBM-850", + "MS-ANSI", + "CSUCS4", + "BIG5-HKSCS", + "UCS-4", + "ARMSCII-8", + "GEORGIAN-PS", + "CSISOLATIN4", + "TIS620.2533-0", + "CSISO2022KR", + "MACINTOSH", + "ISO-IR-179", + "ISO-IR-100", + "GREEK8", + "EUCKR", + "UTF-16", + "VISCII1.1-1", + "ISO-2022-KR", + "CP367", + "UTF-8", + "UTF-32", + "EUC-KR", + "CP1257", + "CSISO57GB1988", + "CSKSC56011987", + "US-ASCII", + "CSISOLATINARABIC", + "ISO_8859-3:1988", + "CSUNICODE11", + "ISO_8859-5:1988", + "ISO_8859-8:1988", + "UNICODE-1-1", + "MACTHAI", + "ROMAN8", + "ISO-10646-UCS-2", + "GREEK", + "LATIN7", + "STRK1048-2002", + "WINDOWS-1251", + "WINDOWS-1256", + "WINDOWS-1253", + "WINDOWS-1252", + "WINDOWS-1255", + "WINDOWS-1258", + "CHINESE", + "NEXTSTEP", + "ISO_8859-9:1989", + "KS_C_5601-1987", + "WINDOWS-936", + "ISO8859-7", + "ISO_8859-4:1988", + "CSPC862LATINHEBREW", + "ISO-8859-7", + "ARABIC", + "ISO-10646-UCS-4", + "MULELAO-1", + "ECMA-118", + "JP", + "ISO_8859-7", + "TCVN-5712", + "TCVN5712-1", + "WINDOWS-1254", + "KOREAN", + "GEORGIAN-ACADEMY", + "MACICELAND", + "CSISOLATINHEBREW", + "ISO-IR-57", + "WINDOWS-1250", + "ISO-IR-87", + "ISO-IR-127", + "ISO-IR-157", + "EUCTW", + "UCS-2LE", + "HP-ROMAN8", + "IBM367", + "KOI8-U", + "UNICODEBIG", + "EUC-TW", + "CSMACINTOSH", + "CSUNICODE", + "JIS_C6226-1983", + "UCS-2-INTERNAL", + "ISO_646.IRV:1991", + "CSISO14JISC6220RO", + "ANSI_X3.4-1986", + "IBM-EUCCN", + "ANSI_X3.4-1968", + "MS-EE", + "CSPC850MULTILINGUAL", + "CSHPROMAN8", + "MACROMAN", + "UCS-4LE", + "ECMA-114", + "UNICODELITTLE", + "WCHAR_T", + "ISO_8859-1:1987", + "ISO_8859-6:1987", + "ISO_8859-7:2003", + "ISO_8859-2:1987", + "UCS-4-INTERNAL", + "CSISO159JISX02121990", + "CSEUCKR", + "CSUNICODE11UTF7", + "ASMO-708", + "UNICODE-1-1-UTF-7", + "JIS_C6220-1969-RO", + "KOI8-RU", + "WINDOWS-1257", + "CSISO2022JP2", + "MS-TURK", + "MACCROATIAN", + "BIG5-HKSCS:2001", + "ISO646-JP", + "JIS0208", + "ISO-2022-JP-1", + "ISO-2022-JP-2", + "SHIFT-JIS", + "BIG5-HKSCS:1999", + "UCS-2BE", + "MACGREEK", + "CSISO2022JP", + "UTF-16LE", + "SHIFT_JIS", + "MS-GREEK", + "UTF-32LE", + "EUCJP", + "MS-HEBR", + "ISO-2022-JP", + "BIG5-HKSCS:2004", + "EUC-JP", + "MACARABIC", + "UCS-4BE", + "UCS-2-SWAPPED", + "JIS_X0212", + "MACTURKISH", + "CSSHIFTJIS", + "WINDOWS-874", + "CSEUCTW", + "UTF-7", + "IBM-EUCKR", + "UCS-4-SWAPPED", + "ISO_8859-7:1987", + "BIGFIVE", + "TCVN5712-1:1993", + "JIS_X0201", + "BIG-FIVE", + "HEBREW", + "UTF-16BE", + "JIS_X0208", + "UTF-32BE", + "JISX0201-1976", + "JIS_X0212-1990", + "CSISO87JISX0208", + "JIS_X0208-1983", + "MS-ARAB", + "MACCENTRALEUROPE", + "CSHALFWIDTHKATAKANA", + "MS_KANJI", + "MACROMANIA", + "JIS_X0208-1990", + "IBM-EUCTW", + "WINBALTRIM", + "EXTENDED_UNIX_CODE_PACKED_FORMAT_FOR_JAPANESE", + "JIS_X0212.1990-0", + "CSEUCPKDFMTJAPANESE", + "JOHAB", + "JAVA", + "MACUKRAINE", + "IBM-EUCJP", + "MACHEBREW" + }; +#define stringpool ((const char *) &stringpool_contents) + +static const struct alias aliases[] = + { + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, +#line 60 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str13, ei_iso8859_1}, +#line 134 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str14, ei_iso8859_10}, +#line 76 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str15, ei_iso8859_3}, +#line 68 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str16, ei_iso8859_2}, +#line 126 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str17, ei_iso8859_9}, + {-1}, +#line 152 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str19, ei_iso8859_14}, +#line 313 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str20, ei_sjis}, + {-1}, {-1}, +#line 210 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str23, ei_cp866}, +#line 292 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str24, ei_iso646_cn}, + {-1}, {-1}, +#line 206 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str27, ei_cp862}, + {-1}, {-1}, {-1}, {-1}, +#line 212 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str32, ei_cp1131}, +#line 362 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str33, ei_johab}, +#line 208 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str34, ei_cp866}, + {-1}, +#line 248 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str36, ei_cp1133}, +#line 175 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str37, ei_cp1251}, +#line 204 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str38, ei_cp862}, +#line 191 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str39, ei_cp1256}, + {-1}, +#line 182 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str41, ei_cp1253}, +#line 325 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str42, ei_euc_cn}, +#line 178 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str43, ei_cp1252}, + {-1}, +#line 188 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str45, ei_cp1255}, + {-1}, {-1}, +#line 330 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str48, ei_cp936}, +#line 197 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str49, ei_cp1258}, + {-1}, {-1}, +#line 316 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str52, ei_cp932}, +#line 51 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str53, ei_c99}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, +#line 84 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str64, ei_iso8859_4}, + {-1}, {-1}, {-1}, +#line 59 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str68, ei_iso8859_1}, +#line 57 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str69, ei_iso8859_1}, +#line 133 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str70, ei_iso8859_10}, + {-1}, +#line 75 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str72, ei_iso8859_3}, + {-1}, +#line 67 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str74, ei_iso8859_2}, + {-1}, +#line 125 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str76, ei_iso8859_9}, + {-1}, {-1}, {-1}, +#line 151 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str80, ei_iso8859_14}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 231 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str88, ei_hp_roman8}, +#line 62 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str89, ei_iso8859_1}, + {-1}, +#line 102 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str91, ei_iso8859_6}, +#line 337 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str92, ei_hz}, +#line 78 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str93, ei_iso8859_3}, +#line 139 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str94, ei_iso8859_11}, +#line 70 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str95, ei_iso8859_2}, +#line 167 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str96, ei_iso8859_16}, +#line 93 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str97, ei_iso8859_5}, +#line 145 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str98, ei_iso8859_13}, + {-1}, {-1}, +#line 120 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str101, ei_iso8859_8}, +#line 160 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str102, ei_iso8859_15}, +#line 53 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str103, ei_iso8859_1}, + {-1}, +#line 94 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str105, ei_iso8859_6}, + {-1}, +#line 71 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str107, ei_iso8859_3}, +#line 137 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str108, ei_iso8859_11}, +#line 63 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str109, ei_iso8859_2}, +#line 161 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str110, ei_iso8859_16}, +#line 87 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str111, ei_iso8859_5}, +#line 140 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str112, ei_iso8859_13}, + {-1}, {-1}, +#line 114 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str115, ei_iso8859_8}, +#line 155 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str116, ei_iso8859_15}, +#line 54 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str117, ei_iso8859_1}, +#line 91 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str118, ei_iso8859_5}, +#line 95 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str119, ei_iso8859_6}, +#line 159 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str120, ei_iso8859_15}, +#line 72 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str121, ei_iso8859_3}, +#line 138 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str122, ei_iso8859_11}, +#line 64 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str123, ei_iso8859_2}, +#line 162 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str124, ei_iso8859_16}, +#line 88 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str125, ei_iso8859_5}, +#line 141 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str126, ei_iso8859_13}, +#line 128 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str127, ei_iso8859_9}, +#line 163 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str128, ei_iso8859_16}, +#line 115 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str129, ei_iso8859_8}, +#line 156 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str130, ei_iso8859_15}, +#line 240 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str131, ei_pt154}, +#line 16 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str132, ei_ascii}, +#line 359 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str133, ei_cp949}, + {-1}, +#line 290 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str135, ei_iso646_cn}, +#line 216 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str136, ei_mac_roman}, +#line 157 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str137, ei_iso8859_15}, + {-1}, +#line 185 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str139, ei_cp1254}, + {-1}, +#line 121 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str141, ei_iso8859_9}, + {-1}, +#line 256 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str143, ei_tis620}, + {-1}, +#line 107 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str145, ei_iso8859_7}, +#line 329 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str146, ei_ces_gbk}, + {-1}, +#line 164 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str148, ei_iso8859_16}, +#line 298 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str149, ei_isoir165}, +#line 286 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str150, ei_jisx0212}, +#line 295 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str151, ei_gb2312}, +#line 237 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str152, ei_koi8_t}, +#line 343 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str153, ei_ces_big5}, +#line 117 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str154, ei_iso8859_8}, +#line 122 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str155, ei_iso8859_9}, +#line 166 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str156, ei_iso8859_16}, + {-1}, {-1}, +#line 201 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str159, ei_cp850}, +#line 209 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str160, ei_cp866}, +#line 335 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str161, ei_iso2022_cn}, + {-1}, +#line 348 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str163, ei_ces_big5}, +#line 205 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str164, ei_cp862}, + {-1}, {-1}, +#line 344 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str167, ei_ces_big5}, +#line 13 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str168, ei_ascii}, +#line 331 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str169, ei_cp936}, +#line 83 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str170, ei_iso8859_4}, +#line 238 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str171, ei_pt154}, +#line 213 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str172, ei_cp1131}, +#line 199 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str173, ei_cp850}, +#line 324 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str174, ei_euc_cn}, +#line 172 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str175, ei_cp1250}, +#line 327 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str176, ei_euc_cn}, +#line 347 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str177, ei_ces_big5}, +#line 22 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str178, ei_ascii}, +#line 334 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str179, ei_iso2022_cn}, +#line 144 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str180, ei_iso8859_13}, + {-1}, +#line 287 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str182, ei_jisx0212}, +#line 181 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str183, ei_cp1252}, +#line 149 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str184, ei_iso8859_14}, + {-1}, +#line 349 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str186, ei_cp950}, +#line 146 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str187, ei_iso8859_13}, +#line 323 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str188, ei_euc_cn}, + {-1}, +#line 336 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str190, ei_iso2022_cn_ext}, +#line 86 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str191, ei_iso8859_4}, +#line 317 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str192, ei_cp932}, +#line 251 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str193, ei_tis620}, + {-1}, +#line 58 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str195, ei_iso8859_1}, +#line 154 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str196, ei_iso8859_14}, +#line 150 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str197, ei_iso8859_14}, + {-1}, +#line 131 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str199, ei_iso8859_10}, + {-1}, +#line 21 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str201, ei_ascii}, +#line 300 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str202, ei_ksc5601}, +#line 124 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str203, ei_iso8859_9}, +#line 153 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str204, ei_iso8859_14}, +#line 79 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str205, ei_iso8859_4}, +#line 360 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str206, ei_cp949}, +#line 250 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str207, ei_tis620}, + {-1}, +#line 66 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str209, ei_iso8859_2}, +#line 147 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str210, ei_iso8859_14}, +#line 165 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str211, ei_iso8859_16}, + {-1}, +#line 273 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str213, ei_jisx0201}, + {-1}, {-1}, +#line 158 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str216, ei_iso8859_15}, +#line 259 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str217, ei_viscii}, + {-1}, +#line 80 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str219, ei_iso8859_4}, + {-1}, +#line 239 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str221, ei_pt154}, + {-1}, {-1}, +#line 148 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str224, ei_iso8859_14}, +#line 279 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str225, ei_jisx0208}, +#line 249 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str226, ei_cp1133}, +#line 261 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str227, ei_viscii}, + {-1}, +#line 303 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str229, ei_ksc5601}, + {-1}, +#line 24 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str231, ei_ucs2}, +#line 136 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str232, ei_iso8859_10}, + {-1}, +#line 243 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str234, ei_rk1048}, +#line 294 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str235, ei_gb2312}, +#line 61 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str236, ei_iso8859_1}, +#line 268 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str237, ei_iso646_jp}, +#line 135 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str238, ei_iso8859_10}, +#line 109 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str239, ei_iso8859_7}, +#line 77 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str240, ei_iso8859_3}, +#line 245 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str241, ei_rk1048}, +#line 69 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str242, ei_iso8859_2}, +#line 92 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str243, ei_iso8859_5}, +#line 127 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str244, ei_iso8859_9}, + {-1}, +#line 129 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str246, ei_iso8859_10}, +#line 74 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str247, ei_iso8859_3}, +#line 246 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str248, ei_rk1048}, + {-1}, +#line 169 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str250, ei_koi8_r}, +#line 333 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str251, ei_gb18030}, +#line 242 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str252, ei_pt154}, + {-1}, +#line 168 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str254, ei_koi8_r}, + {-1}, +#line 262 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str256, ei_tcvn}, + {-1}, +#line 289 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str258, ei_iso646_cn}, + {-1}, +#line 130 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str260, ei_iso8859_10}, +#line 177 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str261, ei_cp1251}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 296 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str268, ei_gb2312}, + {-1}, +#line 255 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str270, ei_tis620}, +#line 302 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str271, ei_ksc5601}, +#line 222 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str272, ei_mac_cyrillic}, + {-1}, {-1}, +#line 338 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str275, ei_hz}, + {-1}, +#line 299 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str277, ei_isoir165}, +#line 82 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str278, ei_iso8859_4}, + {-1}, {-1}, +#line 252 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str281, ei_tis620}, + {-1}, +#line 326 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str283, ei_euc_cn}, + {-1}, {-1}, {-1}, {-1}, +#line 253 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str288, ei_tis620}, + {-1}, {-1}, {-1}, {-1}, +#line 90 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str293, ei_iso8859_5}, +#line 211 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str294, ei_cp866}, + {-1}, {-1}, {-1}, +#line 14 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str298, ei_ascii}, +#line 200 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str299, ei_cp850}, +#line 257 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str300, ei_cp874}, + {-1}, +#line 241 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str302, ei_pt154}, + {-1}, {-1}, {-1}, +#line 112 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str306, ei_iso8859_7}, +#line 365 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str307, ei_local_char}, + {-1}, {-1}, +#line 353 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str310, ei_big5hkscs2004}, + {-1}, {-1}, +#line 203 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str313, ei_cp850}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 180 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str322, ei_cp1252}, +#line 35 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str323, ei_ucs4}, +#line 352 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str324, ei_big5hkscs2004}, + {-1}, {-1}, +#line 33 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str327, ei_ucs4}, + {-1}, {-1}, +#line 234 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str330, ei_armscii_8}, + {-1}, {-1}, {-1}, {-1}, +#line 236 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str335, ei_georgian_ps}, + {-1}, {-1}, +#line 85 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str338, ei_iso8859_4}, +#line 254 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str339, ei_tis620}, + {-1}, {-1}, +#line 364 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str342, ei_iso2022_kr}, +#line 215 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str343, ei_mac_roman}, + {-1}, +#line 142 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str345, ei_iso8859_13}, + {-1}, +#line 56 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str347, ei_iso8859_1}, + {-1}, {-1}, +#line 110 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str350, ei_iso8859_7}, + {-1}, {-1}, {-1}, {-1}, +#line 356 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str355, ei_euc_kr}, + {-1}, {-1}, +#line 38 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str358, ei_utf16}, +#line 260 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str359, ei_viscii}, +#line 363 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str360, ei_iso2022_kr}, + {-1}, +#line 19 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str362, ei_ascii}, +#line 23 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str363, ei_utf8}, +#line 41 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str364, ei_utf32}, + {-1}, {-1}, {-1}, {-1}, +#line 355 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str369, ei_euc_kr}, + {-1}, +#line 194 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str371, ei_cp1257}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 293 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str378, ei_iso646_cn}, + {-1}, {-1}, {-1}, +#line 304 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str382, ei_ksc5601}, +#line 12 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str383, ei_ascii}, +#line 101 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str384, ei_iso8859_6}, +#line 73 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str385, ei_iso8859_3}, +#line 30 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str386, ei_ucs2be}, +#line 89 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str387, ei_iso8859_5}, + {-1}, +#line 116 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str389, ei_iso8859_8}, +#line 29 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str390, ei_ucs2be}, +#line 228 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str391, ei_mac_thai}, +#line 230 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str392, ei_hp_roman8}, +#line 25 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str393, ei_ucs2}, + {-1}, {-1}, {-1}, {-1}, +#line 111 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str398, ei_iso8859_7}, + {-1}, {-1}, {-1}, +#line 143 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str402, ei_iso8859_13}, + {-1}, +#line 244 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str404, ei_rk1048}, +#line 176 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str405, ei_cp1251}, +#line 192 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str406, ei_cp1256}, +#line 183 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str407, ei_cp1253}, +#line 179 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str408, ei_cp1252}, +#line 189 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str409, ei_cp1255}, + {-1}, +#line 198 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str411, ei_cp1258}, +#line 297 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str412, ei_gb2312}, +#line 233 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str413, ei_nextstep}, + {-1}, +#line 123 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str415, ei_iso8859_9}, + {-1}, {-1}, {-1}, +#line 301 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str419, ei_ksc5601}, +#line 332 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str420, ei_cp936}, + {-1}, {-1}, +#line 113 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str423, ei_iso8859_7}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, +#line 81 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str434, ei_iso8859_4}, + {-1}, +#line 207 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str436, ei_cp862}, +#line 103 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str437, ei_iso8859_7}, + {-1}, {-1}, +#line 100 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str440, ei_iso8859_6}, +#line 34 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str441, ei_ucs4}, + {-1}, {-1}, {-1}, +#line 247 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str445, ei_mulelao}, +#line 108 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str446, ei_iso8859_7}, + {-1}, +#line 269 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str448, ei_iso646_jp}, + {-1}, {-1}, +#line 104 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str451, ei_iso8859_7}, + {-1}, +#line 263 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str453, ei_tcvn}, + {-1}, +#line 264 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str455, ei_tcvn}, +#line 186 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str456, ei_cp1254}, + {-1}, {-1}, +#line 305 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str459, ei_ksc5601}, + {-1}, +#line 235 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str461, ei_georgian_academy}, +#line 219 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str462, ei_mac_iceland}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 119 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str469, ei_iso8859_8}, + {-1}, {-1}, {-1}, +#line 291 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str473, ei_iso646_cn}, +#line 173 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str474, ei_cp1250}, +#line 280 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str475, ei_jisx0208}, + {-1}, +#line 97 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str477, ei_iso8859_6}, +#line 132 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str478, ei_iso8859_10}, + {-1}, {-1}, +#line 340 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str481, ei_euc_tw}, + {-1}, +#line 31 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str483, ei_ucs2le}, + {-1}, {-1}, {-1}, +#line 229 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str487, ei_hp_roman8}, +#line 20 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str488, ei_ascii}, + {-1}, {-1}, {-1}, +#line 170 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str492, ei_koi8_u}, +#line 28 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str493, ei_ucs2be}, + {-1}, +#line 339 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str495, ei_euc_tw}, +#line 217 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str496, ei_mac_roman}, +#line 26 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str497, ei_ucs2}, +#line 281 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str498, ei_jisx0208}, + {-1}, {-1}, +#line 47 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str501, ei_ucs2internal}, + {-1}, +#line 15 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str503, ei_ascii}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 270 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str510, ei_iso646_jp}, +#line 18 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str511, ei_ascii}, + {-1}, {-1}, {-1}, +#line 328 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str515, ei_euc_cn}, +#line 17 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str516, ei_ascii}, + {-1}, +#line 174 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str518, ei_cp1250}, + {-1}, {-1}, +#line 202 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str521, ei_cp850}, + {-1}, +#line 232 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str523, ei_hp_roman8}, + {-1}, +#line 214 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str525, ei_mac_roman}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 37 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str531, ei_ucs4le}, + {-1}, {-1}, {-1}, {-1}, +#line 98 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str536, ei_iso8859_6}, + {-1}, {-1}, {-1}, +#line 32 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str540, ei_ucs2le}, + {-1}, {-1}, +#line 366 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str543, ei_local_wchar_t}, +#line 55 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str544, ei_iso8859_1}, +#line 96 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str545, ei_iso8859_6}, +#line 106 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str546, ei_iso8859_7}, +#line 65 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str547, ei_iso8859_2}, + {-1}, +#line 49 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str549, ei_ucs4internal}, + {-1}, {-1}, {-1}, {-1}, +#line 288 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str554, ei_jisx0212}, + {-1}, +#line 357 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str556, ei_euc_kr}, +#line 46 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str557, ei_utf7}, + {-1}, {-1}, {-1}, +#line 99 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str561, ei_iso8859_6}, + {-1}, +#line 45 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str563, ei_utf7}, + {-1}, {-1}, {-1}, +#line 266 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str567, ei_iso646_jp}, + {-1}, +#line 171 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str569, ei_koi8_ru}, + {-1}, {-1}, +#line 195 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str572, ei_cp1257}, + {-1}, {-1}, +#line 322 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str575, ei_iso2022_jp2}, + {-1}, {-1}, {-1}, +#line 187 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str579, ei_cp1254}, + {-1}, {-1}, {-1}, +#line 220 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str583, ei_mac_croatian}, +#line 351 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str584, ei_big5hkscs2001}, +#line 267 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str585, ei_iso646_jp}, +#line 278 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str586, ei_jisx0208}, + {-1}, {-1}, {-1}, {-1}, +#line 320 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str591, ei_iso2022_jp1}, + {-1}, {-1}, +#line 321 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str594, ei_iso2022_jp2}, + {-1}, {-1}, {-1}, {-1}, +#line 312 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str599, ei_sjis}, + {-1}, {-1}, {-1}, +#line 350 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str603, ei_big5hkscs1999}, +#line 27 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str604, ei_ucs2be}, + {-1}, +#line 224 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str606, ei_mac_greek}, + {-1}, {-1}, {-1}, {-1}, +#line 319 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str611, ei_iso2022_jp}, +#line 40 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str612, ei_utf16le}, +#line 311 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str613, ei_sjis}, + {-1}, +#line 184 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str615, ei_cp1253}, +#line 43 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str616, ei_utf32le}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 307 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str624, ei_euc_jp}, +#line 190 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str625, ei_cp1255}, + {-1}, {-1}, {-1}, +#line 318 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str629, ei_iso2022_jp}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 354 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str635, ei_big5hkscs2004}, + {-1}, {-1}, +#line 306 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str638, ei_euc_jp}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 227 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str648, ei_mac_arabic}, + {-1}, {-1}, {-1}, +#line 36 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str652, ei_ucs4be}, + {-1}, +#line 48 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str654, ei_ucs2swapped}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 283 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str660, ei_jisx0212}, + {-1}, +#line 225 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str662, ei_mac_turkish}, + {-1}, {-1}, {-1}, +#line 315 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str666, ei_sjis}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 258 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str672, ei_cp874}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 341 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str682, ei_euc_tw}, + {-1}, {-1}, +#line 44 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str685, ei_utf7}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, +#line 358 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str696, ei_euc_kr}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 50 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str702, ei_ucs4swapped}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 105 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str711, ei_iso8859_7}, + {-1}, {-1}, {-1}, +#line 346 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str715, ei_ces_big5}, + {-1}, +#line 265 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str717, ei_tcvn}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 271 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str723, ei_jisx0201}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 345 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str729, ei_ces_big5}, + {-1}, {-1}, +#line 118 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str732, ei_iso8859_8}, +#line 39 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str733, ei_utf16be}, + {-1}, +#line 275 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str735, ei_jisx0208}, + {-1}, +#line 42 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str737, ei_utf32be}, + {-1}, {-1}, {-1}, +#line 272 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str741, ei_jisx0201}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 285 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str748, ei_jisx0212}, + {-1}, {-1}, {-1}, +#line 282 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str752, ei_jisx0208}, +#line 276 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str753, ei_jisx0208}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 193 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str771, ei_cp1256}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 218 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str797, ei_mac_centraleurope}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 274 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str803, ei_jisx0201}, +#line 314 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str804, ei_sjis}, + {-1}, {-1}, +#line 221 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str807, ei_mac_romania}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, +#line 277 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str820, ei_jisx0208}, + {-1}, +#line 342 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str822, ei_euc_tw}, + {-1}, {-1}, {-1}, +#line 196 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str826, ei_cp1257}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, +#line 308 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str846, ei_euc_jp}, + {-1}, {-1}, +#line 284 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str849, ei_jisx0212}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 309 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str874, ei_euc_jp}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, +#line 361 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str885, ei_johab}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 52 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str891, ei_java}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 223 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str898, ei_mac_ukraine}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, +#line 310 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str965, ei_euc_jp}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 226 "lib/aliases_sysaix.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str989, ei_mac_hebrew} + }; + +#ifdef __GNUC__ +__inline +#if defined __GNUC_STDC_INLINE__ || defined __GNUC_GNU_INLINE__ +__attribute__ ((__gnu_inline__)) +#endif +#endif +const struct alias * +aliases_lookup (register const char *str, register unsigned int len) +{ + if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) + { + register int key = aliases_hash (str, len); + + if (key <= MAX_HASH_VALUE && key >= 0) + { + register int o = aliases[key].name; + if (o >= 0) + { + register const char *s = o + stringpool; + + if (*str == *s && !strcmp (str + 1, s + 1)) + return &aliases[key]; + } + } + } + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/aliases_syshpux.h b/graf2d/win32gdk/gdk/src/iconv/aliases_syshpux.h new file mode 100644 index 0000000000000..5f76df3b24e81 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/aliases_syshpux.h @@ -0,0 +1,1769 @@ +/* ANSI-C code produced by gperf version 3.0.4 */ +/* Command-line: gperf -m 10 lib/aliases_syshpux.gperf */ +/* Computed positions: -k'1,3-11,$' */ + +#if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ + && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ + && (')' == 41) && ('*' == 42) && ('+' == 43) && (',' == 44) \ + && ('-' == 45) && ('.' == 46) && ('/' == 47) && ('0' == 48) \ + && ('1' == 49) && ('2' == 50) && ('3' == 51) && ('4' == 52) \ + && ('5' == 53) && ('6' == 54) && ('7' == 55) && ('8' == 56) \ + && ('9' == 57) && (':' == 58) && (';' == 59) && ('<' == 60) \ + && ('=' == 61) && ('>' == 62) && ('?' == 63) && ('A' == 65) \ + && ('B' == 66) && ('C' == 67) && ('D' == 68) && ('E' == 69) \ + && ('F' == 70) && ('G' == 71) && ('H' == 72) && ('I' == 73) \ + && ('J' == 74) && ('K' == 75) && ('L' == 76) && ('M' == 77) \ + && ('N' == 78) && ('O' == 79) && ('P' == 80) && ('Q' == 81) \ + && ('R' == 82) && ('S' == 83) && ('T' == 84) && ('U' == 85) \ + && ('V' == 86) && ('W' == 87) && ('X' == 88) && ('Y' == 89) \ + && ('Z' == 90) && ('[' == 91) && ('\\' == 92) && (']' == 93) \ + && ('^' == 94) && ('_' == 95) && ('a' == 97) && ('b' == 98) \ + && ('c' == 99) && ('d' == 100) && ('e' == 101) && ('f' == 102) \ + && ('g' == 103) && ('h' == 104) && ('i' == 105) && ('j' == 106) \ + && ('k' == 107) && ('l' == 108) && ('m' == 109) && ('n' == 110) \ + && ('o' == 111) && ('p' == 112) && ('q' == 113) && ('r' == 114) \ + && ('s' == 115) && ('t' == 116) && ('u' == 117) && ('v' == 118) \ + && ('w' == 119) && ('x' == 120) && ('y' == 121) && ('z' == 122) \ + && ('{' == 123) && ('|' == 124) && ('}' == 125) && ('~' == 126)) +/* The character set is not based on ISO-646. */ +#error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gnu-gperf@gnu.org>." +#endif + +#line 1 "lib/aliases_syshpux.gperf" +struct alias { int name; unsigned int encoding_index; }; + +#define TOTAL_KEYWORDS 356 +#define MIN_WORD_LENGTH 2 +#define MAX_WORD_LENGTH 45 +#define MIN_HASH_VALUE 9 +#define MAX_HASH_VALUE 1038 +/* maximum key range = 1030, duplicates = 0 */ + +#ifdef __GNUC__ +__inline +#else +#ifdef __cplusplus +inline +#endif +#endif +static unsigned int +aliases_hash (register const char *str, register unsigned int len) +{ + static const unsigned short asso_values[] = + { + 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, + 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, + 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, + 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, + 1039, 1039, 1039, 1039, 1039, 0, 112, 1039, 57, 2, + 0, 20, 51, 8, 5, 49, 13, 16, 335, 1039, + 1039, 1039, 1039, 1039, 1039, 13, 149, 1, 6, 10, + 55, 139, 10, 0, 328, 86, 210, 147, 6, 0, + 73, 1039, 120, 6, 17, 282, 238, 172, 274, 2, + 0, 1039, 1039, 1039, 1039, 34, 1039, 1039, 1039, 1039, + 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, + 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039, + 1039, 1039, 1039, 1039, 1039, 1039, 1039, 1039 + }; + register int hval = len; + + switch (hval) + { + default: + hval += asso_values[(unsigned char)str[10]]; + /*FALLTHROUGH*/ + case 10: + hval += asso_values[(unsigned char)str[9]]; + /*FALLTHROUGH*/ + case 9: + hval += asso_values[(unsigned char)str[8]]; + /*FALLTHROUGH*/ + case 8: + hval += asso_values[(unsigned char)str[7]]; + /*FALLTHROUGH*/ + case 7: + hval += asso_values[(unsigned char)str[6]]; + /*FALLTHROUGH*/ + case 6: + hval += asso_values[(unsigned char)str[5]]; + /*FALLTHROUGH*/ + case 5: + hval += asso_values[(unsigned char)str[4]]; + /*FALLTHROUGH*/ + case 4: + hval += asso_values[(unsigned char)str[3]]; + /*FALLTHROUGH*/ + case 3: + hval += asso_values[(unsigned char)str[2]]; + /*FALLTHROUGH*/ + case 2: + case 1: + hval += asso_values[(unsigned char)str[0]]; + break; + } + return hval + asso_values[(unsigned char)str[len - 1]]; +} + +struct stringpool_t + { + char stringpool_str9[sizeof("CN")]; + char stringpool_str12[sizeof("HZ")]; + char stringpool_str16[sizeof("862")]; + char stringpool_str17[sizeof("CP1252")]; + char stringpool_str19[sizeof("ASCII")]; + char stringpool_str21[sizeof("CP1251")]; + char stringpool_str22[sizeof("SJIS")]; + char stringpool_str24[sizeof("CP862")]; + char stringpool_str26[sizeof("866")]; + char stringpool_str27[sizeof("CP1256")]; + char stringpool_str28[sizeof("CSASCII")]; + char stringpool_str29[sizeof("EUCCN")]; + char stringpool_str30[sizeof("EUC-CN")]; + char stringpool_str33[sizeof("CP1255")]; + char stringpool_str34[sizeof("CP866")]; + char stringpool_str35[sizeof("CP1131")]; + char stringpool_str36[sizeof("C99")]; + char stringpool_str38[sizeof("CP1361")]; + char stringpool_str39[sizeof("HP15CN")]; + char stringpool_str42[sizeof("CP932")]; + char stringpool_str43[sizeof("CP1258")]; + char stringpool_str50[sizeof("CHINESE")]; + char stringpool_str52[sizeof("CP936")]; + char stringpool_str53[sizeof("CP819")]; + char stringpool_str57[sizeof("CP1253")]; + char stringpool_str58[sizeof("ISO88592")]; + char stringpool_str59[sizeof("ISO8859-2")]; + char stringpool_str60[sizeof("ISO-8859-2")]; + char stringpool_str62[sizeof("ISO88591")]; + char stringpool_str63[sizeof("ISO8859-1")]; + char stringpool_str64[sizeof("ISO-8859-1")]; + char stringpool_str66[sizeof("ISO8859-11")]; + char stringpool_str67[sizeof("ISO-8859-11")]; + char stringpool_str68[sizeof("ISO88596")]; + char stringpool_str69[sizeof("ISO8859-6")]; + char stringpool_str70[sizeof("ISO-8859-6")]; + char stringpool_str71[sizeof("CP1133")]; + char stringpool_str72[sizeof("ISO8859-16")]; + char stringpool_str73[sizeof("ISO-8859-16")]; + char stringpool_str74[sizeof("ISO88595")]; + char stringpool_str75[sizeof("ISO8859-5")]; + char stringpool_str76[sizeof("ISO-8859-5")]; + char stringpool_str77[sizeof("ISO885915")]; + char stringpool_str78[sizeof("ISO8859-15")]; + char stringpool_str79[sizeof("ISO-8859-15")]; + char stringpool_str81[sizeof("ISO-2022-CN")]; + char stringpool_str83[sizeof("ISO646-CN")]; + char stringpool_str84[sizeof("ISO88598")]; + char stringpool_str85[sizeof("ISO8859-8")]; + char stringpool_str86[sizeof("ISO-8859-8")]; + char stringpool_str88[sizeof("CSISO2022CN")]; + char stringpool_str90[sizeof("ISO88599")]; + char stringpool_str91[sizeof("ISO8859-9")]; + char stringpool_str92[sizeof("ISO-8859-9")]; + char stringpool_str94[sizeof("ISO_8859-2")]; + char stringpool_str96[sizeof("ISO-2022-CN-EXT")]; + char stringpool_str98[sizeof("ISO_8859-1")]; + char stringpool_str99[sizeof("ISO8859-3")]; + char stringpool_str100[sizeof("ISO-8859-3")]; + char stringpool_str101[sizeof("ISO_8859-11")]; + char stringpool_str102[sizeof("ISO8859-13")]; + char stringpool_str103[sizeof("ISO-8859-13")]; + char stringpool_str104[sizeof("ISO_8859-6")]; + char stringpool_str105[sizeof("CP949")]; + char stringpool_str107[sizeof("ISO_8859-16")]; + char stringpool_str109[sizeof("ISO_8859-16:2001")]; + char stringpool_str110[sizeof("ISO_8859-5")]; + char stringpool_str111[sizeof("ELOT_928")]; + char stringpool_str113[sizeof("ISO_8859-15")]; + char stringpool_str115[sizeof("CP1257")]; + char stringpool_str118[sizeof("CP154")]; + char stringpool_str119[sizeof("CP1254")]; + char stringpool_str120[sizeof("ISO_8859-8")]; + char stringpool_str123[sizeof("ISO_8859-15:1998")]; + char stringpool_str126[sizeof("ISO_8859-9")]; + char stringpool_str129[sizeof("CP367")]; + char stringpool_str130[sizeof("850")]; + char stringpool_str131[sizeof("CP1250")]; + char stringpool_str134[sizeof("ISO_8859-3")]; + char stringpool_str135[sizeof("R8")]; + char stringpool_str137[sizeof("ISO_8859-13")]; + char stringpool_str138[sizeof("ISO-IR-6")]; + char stringpool_str139[sizeof("KOI8-T")]; + char stringpool_str140[sizeof("ISO-IR-226")]; + char stringpool_str141[sizeof("CP850")]; + char stringpool_str142[sizeof("ISO-IR-126")]; + char stringpool_str144[sizeof("CP950")]; + char stringpool_str147[sizeof("ISO-IR-166")]; + char stringpool_str148[sizeof("TIS620")]; + char stringpool_str149[sizeof("TIS-620")]; + char stringpool_str152[sizeof("MAC")]; + char stringpool_str153[sizeof("ISO-IR-165")]; + char stringpool_str156[sizeof("ISO88597")]; + char stringpool_str157[sizeof("ISO8859-7")]; + char stringpool_str158[sizeof("ISO-8859-7")]; + char stringpool_str159[sizeof("ISO_8859-10:1992")]; + char stringpool_str161[sizeof("ISO8859-4")]; + char stringpool_str162[sizeof("ISO-8859-4")]; + char stringpool_str163[sizeof("ISO-IR-58")]; + char stringpool_str164[sizeof("ISO8859-14")]; + char stringpool_str165[sizeof("ISO-8859-14")]; + char stringpool_str166[sizeof("ISO_8859-14:1998")]; + char stringpool_str167[sizeof("GB2312")]; + char stringpool_str170[sizeof("CP874")]; + char stringpool_str171[sizeof("IBM862")]; + char stringpool_str172[sizeof("ISO-IR-159")]; + char stringpool_str176[sizeof("ISO8859-10")]; + char stringpool_str177[sizeof("ISO-8859-10")]; + char stringpool_str178[sizeof("ISO-IR-138")]; + char stringpool_str179[sizeof("MS-ANSI")]; + char stringpool_str180[sizeof("ISO-IR-199")]; + char stringpool_str181[sizeof("IBM866")]; + char stringpool_str182[sizeof("MS-EE")]; + char stringpool_str183[sizeof("ARABIC")]; + char stringpool_str190[sizeof("PT154")]; + char stringpool_str192[sizeof("ISO_8859-7")]; + char stringpool_str193[sizeof("ISO-IR-101")]; + char stringpool_str195[sizeof("MACTHAI")]; + char stringpool_str196[sizeof("ISO_8859-4")]; + char stringpool_str198[sizeof("MS936")]; + char stringpool_str199[sizeof("ISO_8859-14")]; + char stringpool_str200[sizeof("IBM819")]; + char stringpool_str202[sizeof("ARMSCII-8")]; + char stringpool_str203[sizeof("KSC_5601")]; + char stringpool_str206[sizeof("MACINTOSH")]; + char stringpool_str207[sizeof("TIS620-0")]; + char stringpool_str208[sizeof("ECMA-118")]; + char stringpool_str209[sizeof("ISO-IR-148")]; + char stringpool_str211[sizeof("ISO_8859-10")]; + char stringpool_str212[sizeof("L2")]; + char stringpool_str213[sizeof("ISO-IR-179")]; + char stringpool_str214[sizeof("L1")]; + char stringpool_str215[sizeof("ISO-IR-149")]; + char stringpool_str217[sizeof("L6")]; + char stringpool_str220[sizeof("L5")]; + char stringpool_str221[sizeof("ISO-IR-109")]; + char stringpool_str222[sizeof("CSMACINTOSH")]; + char stringpool_str225[sizeof("L8")]; + char stringpool_str227[sizeof("ISO-IR-203")]; + char stringpool_str229[sizeof("KZ-1048")]; + char stringpool_str230[sizeof("ISO-IR-127")]; + char stringpool_str231[sizeof("CSKZ1048")]; + char stringpool_str232[sizeof("L3")]; + char stringpool_str233[sizeof("ISO-IR-14")]; + char stringpool_str235[sizeof("ISO-IR-57")]; + char stringpool_str236[sizeof("TIS620.2529-1")]; + char stringpool_str238[sizeof("ISO-IR-157")]; + char stringpool_str239[sizeof("LATIN2")]; + char stringpool_str240[sizeof("ISO-IR-87")]; + char stringpool_str243[sizeof("LATIN1")]; + char stringpool_str246[sizeof("CSKSC56011987")]; + char stringpool_str247[sizeof("KOREAN")]; + char stringpool_str248[sizeof("ISO-IR-110")]; + char stringpool_str249[sizeof("LATIN6")]; + char stringpool_str250[sizeof("ISO-CELTIC")]; + char stringpool_str251[sizeof("VISCII")]; + char stringpool_str254[sizeof("CSVISCII")]; + char stringpool_str255[sizeof("LATIN5")]; + char stringpool_str258[sizeof("CHAR")]; + char stringpool_str259[sizeof("KS_C_5601-1989")]; + char stringpool_str260[sizeof("TIS620.2533-1")]; + char stringpool_str261[sizeof("L7")]; + char stringpool_str262[sizeof("RK1048")]; + char stringpool_str263[sizeof("L4")]; + char stringpool_str264[sizeof("CSISOLATIN2")]; + char stringpool_str265[sizeof("LATIN8")]; + char stringpool_str266[sizeof("PTCP154")]; + char stringpool_str268[sizeof("CSISOLATIN1")]; + char stringpool_str271[sizeof("TCVN")]; + char stringpool_str272[sizeof("LATIN-9")]; + char stringpool_str273[sizeof("CSISOLATINCYRILLIC")]; + char stringpool_str274[sizeof("CSISOLATIN6")]; + char stringpool_str276[sizeof("IBM367")]; + char stringpool_str277[sizeof("GREEK8")]; + char stringpool_str279[sizeof("LATIN3")]; + char stringpool_str280[sizeof("CSISOLATIN5")]; + char stringpool_str281[sizeof("X0212")]; + char stringpool_str283[sizeof("CSISOLATINARABIC")]; + char stringpool_str284[sizeof("ECMA-114")]; + char stringpool_str285[sizeof("ISO-IR-144")]; + char stringpool_str286[sizeof("CSPTCP154")]; + char stringpool_str287[sizeof("UHC")]; + char stringpool_str288[sizeof("IBM850")]; + char stringpool_str290[sizeof("US")]; + char stringpool_str292[sizeof("KS_C_5601-1987")]; + char stringpool_str293[sizeof("UCS-2")]; + char stringpool_str295[sizeof("IBM-CP1133")]; + char stringpool_str300[sizeof("ASMO-708")]; + char stringpool_str303[sizeof("ISO-IR-100")]; + char stringpool_str304[sizeof("CSISOLATIN3")]; + char stringpool_str308[sizeof("BIG5")]; + char stringpool_str309[sizeof("BIG-5")]; + char stringpool_str310[sizeof("US-ASCII")]; + char stringpool_str311[sizeof("CSBIG5")]; + char stringpool_str312[sizeof("CN-BIG5")]; + char stringpool_str314[sizeof("GBK")]; + char stringpool_str315[sizeof("TIS620.2533-0")]; + char stringpool_str316[sizeof("UNICODE-1-1")]; + char stringpool_str318[sizeof("ROMAN8")]; + char stringpool_str319[sizeof("CSGB2312")]; + char stringpool_str323[sizeof("CSUNICODE11")]; + char stringpool_str325[sizeof("CSUNICODE")]; + char stringpool_str327[sizeof("L10")]; + char stringpool_str329[sizeof("TCVN-5712")]; + char stringpool_str330[sizeof("HZ-GB-2312")]; + char stringpool_str331[sizeof("HP-ROMAN8")]; + char stringpool_str332[sizeof("GB_2312-80")]; + char stringpool_str333[sizeof("CSIBM866")]; + char stringpool_str334[sizeof("TCVN5712-1")]; + char stringpool_str335[sizeof("MACCROATIAN")]; + char stringpool_str336[sizeof("GREEK")]; + char stringpool_str337[sizeof("LATIN7")]; + char stringpool_str340[sizeof("X0201")]; + char stringpool_str341[sizeof("LATIN4")]; + char stringpool_str342[sizeof("EUCKR")]; + char stringpool_str343[sizeof("EUC-KR")]; + char stringpool_str345[sizeof("KOI8-R")]; + char stringpool_str347[sizeof("CSKOI8R")]; + char stringpool_str352[sizeof("GB18030")]; + char stringpool_str354[sizeof("GB_1988-80")]; + char stringpool_str355[sizeof("UTF-16")]; + char stringpool_str356[sizeof("LATIN10")]; + char stringpool_str362[sizeof("X0208")]; + char stringpool_str363[sizeof("UTF-32")]; + char stringpool_str364[sizeof("ISO646-US")]; + char stringpool_str366[sizeof("CSISOLATIN4")]; + char stringpool_str367[sizeof("UTF8")]; + char stringpool_str368[sizeof("UTF-8")]; + char stringpool_str369[sizeof("UNICODE-1-1-UTF-7")]; + char stringpool_str374[sizeof("CSUNICODE11UTF7")]; + char stringpool_str376[sizeof("VISCII1.1-1")]; + char stringpool_str377[sizeof("EUCTW")]; + char stringpool_str378[sizeof("EUC-TW")]; + char stringpool_str384[sizeof("WINDOWS-1252")]; + char stringpool_str386[sizeof("WINDOWS-1251")]; + char stringpool_str389[sizeof("WINDOWS-1256")]; + char stringpool_str390[sizeof("WCHAR_T")]; + char stringpool_str392[sizeof("WINDOWS-1255")]; + char stringpool_str394[sizeof("ISO-2022-KR")]; + char stringpool_str395[sizeof("UCS-4")]; + char stringpool_str396[sizeof("CSISO57GB1988")]; + char stringpool_str397[sizeof("WINDOWS-1258")]; + char stringpool_str398[sizeof("CSUCS4")]; + char stringpool_str401[sizeof("CSISO2022KR")]; + char stringpool_str403[sizeof("JP")]; + char stringpool_str404[sizeof("WINDOWS-1253")]; + char stringpool_str405[sizeof("STRK1048-2002")]; + char stringpool_str406[sizeof("CSHPROMAN8")]; + char stringpool_str408[sizeof("CSISO58GB231280")]; + char stringpool_str410[sizeof("MACICELAND")]; + char stringpool_str412[sizeof("CSISO14JISC6220RO")]; + char stringpool_str415[sizeof("JIS_C6226-1983")]; + char stringpool_str417[sizeof("ISO-10646-UCS-2")]; + char stringpool_str419[sizeof("WINDOWS-936")]; + char stringpool_str420[sizeof("BIG5HKSCS")]; + char stringpool_str421[sizeof("BIG5-HKSCS")]; + char stringpool_str427[sizeof("SHIFT-JIS")]; + char stringpool_str433[sizeof("WINDOWS-1257")]; + char stringpool_str435[sizeof("WINDOWS-1254")]; + char stringpool_str437[sizeof("CN-GB-ISOIR165")]; + char stringpool_str439[sizeof("CSSHIFTJIS")]; + char stringpool_str440[sizeof("UTF-7")]; + char stringpool_str441[sizeof("WINDOWS-1250")]; + char stringpool_str442[sizeof("EXTENDED_UNIX_CODE_PACKED_FORMAT_FOR_JAPANESE")]; + char stringpool_str443[sizeof("CN-GB")]; + char stringpool_str444[sizeof("CSISO159JISX02121990")]; + char stringpool_str448[sizeof("MACROMAN")]; + char stringpool_str449[sizeof("GEORGIAN-ACADEMY")]; + char stringpool_str450[sizeof("JIS_C6220-1969-RO")]; + char stringpool_str451[sizeof("CSISOLATINHEBREW")]; + char stringpool_str454[sizeof("MACARABIC")]; + char stringpool_str455[sizeof("ISO_8859-5:1988")]; + char stringpool_str460[sizeof("ISO_8859-8:1988")]; + char stringpool_str461[sizeof("SHIFT_JIS")]; + char stringpool_str464[sizeof("UCS-2BE")]; + char stringpool_str466[sizeof("ISO_8859-9:1989")]; + char stringpool_str467[sizeof("ISO_8859-3:1988")]; + char stringpool_str468[sizeof("ISO-10646-UCS-4")]; + char stringpool_str470[sizeof("MACROMANIA")]; + char stringpool_str471[sizeof("ISO-2022-JP-2")]; + char stringpool_str473[sizeof("ISO-2022-JP-1")]; + char stringpool_str477[sizeof("CSISO2022JP2")]; + char stringpool_str481[sizeof("JIS0208")]; + char stringpool_str483[sizeof("ISO_8859-2:1987")]; + char stringpool_str484[sizeof("NEXTSTEP")]; + char stringpool_str485[sizeof("ISO_8859-1:1987")]; + char stringpool_str488[sizeof("ISO_8859-6:1987")]; + char stringpool_str490[sizeof("EUCJP")]; + char stringpool_str491[sizeof("EUC-JP")]; + char stringpool_str493[sizeof("CSISOLATINGREEK")]; + char stringpool_str498[sizeof("ISO_8859-4:1988")]; + char stringpool_str503[sizeof("ISO_8859-7:2003")]; + char stringpool_str513[sizeof("GEORGIAN-PS")]; + char stringpool_str515[sizeof("UCS-4BE")]; + char stringpool_str521[sizeof("UTF-16BE")]; + char stringpool_str523[sizeof("CSPC862LATINHEBREW")]; + char stringpool_str525[sizeof("UCS-2LE")]; + char stringpool_str526[sizeof("CSHALFWIDTHKATAKANA")]; + char stringpool_str531[sizeof("ANSI_X3.4-1986")]; + char stringpool_str532[sizeof("ISO_8859-7:1987")]; + char stringpool_str534[sizeof("UTF-32BE")]; + char stringpool_str537[sizeof("WINDOWS-874")]; + char stringpool_str539[sizeof("ANSI_X3.4-1968")]; + char stringpool_str542[sizeof("ISO-2022-JP")]; + char stringpool_str544[sizeof("ISO646-JP")]; + char stringpool_str549[sizeof("CSISO2022JP")]; + char stringpool_str551[sizeof("CYRILLIC")]; + char stringpool_str561[sizeof("MACCENTRALEUROPE")]; + char stringpool_str563[sizeof("MS-HEBR")]; + char stringpool_str566[sizeof("UNICODELITTLE")]; + char stringpool_str576[sizeof("UCS-4LE")]; + char stringpool_str581[sizeof("CYRILLIC-ASIAN")]; + char stringpool_str582[sizeof("UTF-16LE")]; + char stringpool_str583[sizeof("ISO_646.IRV:1991")]; + char stringpool_str595[sizeof("UTF-32LE")]; + char stringpool_str596[sizeof("JAVA")]; + char stringpool_str598[sizeof("MS-ARAB")]; + char stringpool_str603[sizeof("MULELAO-1")]; + char stringpool_str606[sizeof("MS-GREEK")]; + char stringpool_str607[sizeof("MACGREEK")]; + char stringpool_str608[sizeof("BIGFIVE")]; + char stringpool_str609[sizeof("BIG-FIVE")]; + char stringpool_str622[sizeof("MS_KANJI")]; + char stringpool_str627[sizeof("CSEUCKR")]; + char stringpool_str639[sizeof("HEBREW")]; + char stringpool_str644[sizeof("UCS-2-SWAPPED")]; + char stringpool_str654[sizeof("JOHAB")]; + char stringpool_str662[sizeof("CSEUCTW")]; + char stringpool_str665[sizeof("UCS-2-INTERNAL")]; + char stringpool_str669[sizeof("KOI8-U")]; + char stringpool_str685[sizeof("MACUKRAINE")]; + char stringpool_str689[sizeof("MACTURKISH")]; + char stringpool_str692[sizeof("TCVN5712-1:1993")]; + char stringpool_str695[sizeof("UCS-4-SWAPPED")]; + char stringpool_str697[sizeof("MS-CYRL")]; + char stringpool_str704[sizeof("MACCYRILLIC")]; + char stringpool_str705[sizeof("CSISO87JISX0208")]; + char stringpool_str707[sizeof("CSEUCPKDFMTJAPANESE")]; + char stringpool_str710[sizeof("JIS_X0212")]; + char stringpool_str716[sizeof("UCS-4-INTERNAL")]; + char stringpool_str736[sizeof("UNICODEBIG")]; + char stringpool_str745[sizeof("MS-TURK")]; + char stringpool_str757[sizeof("BIG5-HKSCS:2001")]; + char stringpool_str760[sizeof("JISX0201-1976")]; + char stringpool_str769[sizeof("JIS_X0201")]; + char stringpool_str771[sizeof("BIG5-HKSCS:1999")]; + char stringpool_str774[sizeof("JIS_X0212-1990")]; + char stringpool_str790[sizeof("KOI8-RU")]; + char stringpool_str791[sizeof("JIS_X0208")]; + char stringpool_str800[sizeof("MACHEBREW")]; + char stringpool_str805[sizeof("JIS_X0208-1983")]; + char stringpool_str806[sizeof("BIG5-HKSCS:2004")]; + char stringpool_str842[sizeof("JIS_X0208-1990")]; + char stringpool_str888[sizeof("JIS_X0212.1990-0")]; + char stringpool_str991[sizeof("WINBALTRIM")]; + char stringpool_str1038[sizeof("CSPC850MULTILINGUAL")]; + }; +static const struct stringpool_t stringpool_contents = + { + "CN", + "HZ", + "862", + "CP1252", + "ASCII", + "CP1251", + "SJIS", + "CP862", + "866", + "CP1256", + "CSASCII", + "EUCCN", + "EUC-CN", + "CP1255", + "CP866", + "CP1131", + "C99", + "CP1361", + "HP15CN", + "CP932", + "CP1258", + "CHINESE", + "CP936", + "CP819", + "CP1253", + "ISO88592", + "ISO8859-2", + "ISO-8859-2", + "ISO88591", + "ISO8859-1", + "ISO-8859-1", + "ISO8859-11", + "ISO-8859-11", + "ISO88596", + "ISO8859-6", + "ISO-8859-6", + "CP1133", + "ISO8859-16", + "ISO-8859-16", + "ISO88595", + "ISO8859-5", + "ISO-8859-5", + "ISO885915", + "ISO8859-15", + "ISO-8859-15", + "ISO-2022-CN", + "ISO646-CN", + "ISO88598", + "ISO8859-8", + "ISO-8859-8", + "CSISO2022CN", + "ISO88599", + "ISO8859-9", + "ISO-8859-9", + "ISO_8859-2", + "ISO-2022-CN-EXT", + "ISO_8859-1", + "ISO8859-3", + "ISO-8859-3", + "ISO_8859-11", + "ISO8859-13", + "ISO-8859-13", + "ISO_8859-6", + "CP949", + "ISO_8859-16", + "ISO_8859-16:2001", + "ISO_8859-5", + "ELOT_928", + "ISO_8859-15", + "CP1257", + "CP154", + "CP1254", + "ISO_8859-8", + "ISO_8859-15:1998", + "ISO_8859-9", + "CP367", + "850", + "CP1250", + "ISO_8859-3", + "R8", + "ISO_8859-13", + "ISO-IR-6", + "KOI8-T", + "ISO-IR-226", + "CP850", + "ISO-IR-126", + "CP950", + "ISO-IR-166", + "TIS620", + "TIS-620", + "MAC", + "ISO-IR-165", + "ISO88597", + "ISO8859-7", + "ISO-8859-7", + "ISO_8859-10:1992", + "ISO8859-4", + "ISO-8859-4", + "ISO-IR-58", + "ISO8859-14", + "ISO-8859-14", + "ISO_8859-14:1998", + "GB2312", + "CP874", + "IBM862", + "ISO-IR-159", + "ISO8859-10", + "ISO-8859-10", + "ISO-IR-138", + "MS-ANSI", + "ISO-IR-199", + "IBM866", + "MS-EE", + "ARABIC", + "PT154", + "ISO_8859-7", + "ISO-IR-101", + "MACTHAI", + "ISO_8859-4", + "MS936", + "ISO_8859-14", + "IBM819", + "ARMSCII-8", + "KSC_5601", + "MACINTOSH", + "TIS620-0", + "ECMA-118", + "ISO-IR-148", + "ISO_8859-10", + "L2", + "ISO-IR-179", + "L1", + "ISO-IR-149", + "L6", + "L5", + "ISO-IR-109", + "CSMACINTOSH", + "L8", + "ISO-IR-203", + "KZ-1048", + "ISO-IR-127", + "CSKZ1048", + "L3", + "ISO-IR-14", + "ISO-IR-57", + "TIS620.2529-1", + "ISO-IR-157", + "LATIN2", + "ISO-IR-87", + "LATIN1", + "CSKSC56011987", + "KOREAN", + "ISO-IR-110", + "LATIN6", + "ISO-CELTIC", + "VISCII", + "CSVISCII", + "LATIN5", + "CHAR", + "KS_C_5601-1989", + "TIS620.2533-1", + "L7", + "RK1048", + "L4", + "CSISOLATIN2", + "LATIN8", + "PTCP154", + "CSISOLATIN1", + "TCVN", + "LATIN-9", + "CSISOLATINCYRILLIC", + "CSISOLATIN6", + "IBM367", + "GREEK8", + "LATIN3", + "CSISOLATIN5", + "X0212", + "CSISOLATINARABIC", + "ECMA-114", + "ISO-IR-144", + "CSPTCP154", + "UHC", + "IBM850", + "US", + "KS_C_5601-1987", + "UCS-2", + "IBM-CP1133", + "ASMO-708", + "ISO-IR-100", + "CSISOLATIN3", + "BIG5", + "BIG-5", + "US-ASCII", + "CSBIG5", + "CN-BIG5", + "GBK", + "TIS620.2533-0", + "UNICODE-1-1", + "ROMAN8", + "CSGB2312", + "CSUNICODE11", + "CSUNICODE", + "L10", + "TCVN-5712", + "HZ-GB-2312", + "HP-ROMAN8", + "GB_2312-80", + "CSIBM866", + "TCVN5712-1", + "MACCROATIAN", + "GREEK", + "LATIN7", + "X0201", + "LATIN4", + "EUCKR", + "EUC-KR", + "KOI8-R", + "CSKOI8R", + "GB18030", + "GB_1988-80", + "UTF-16", + "LATIN10", + "X0208", + "UTF-32", + "ISO646-US", + "CSISOLATIN4", + "UTF8", + "UTF-8", + "UNICODE-1-1-UTF-7", + "CSUNICODE11UTF7", + "VISCII1.1-1", + "EUCTW", + "EUC-TW", + "WINDOWS-1252", + "WINDOWS-1251", + "WINDOWS-1256", + "WCHAR_T", + "WINDOWS-1255", + "ISO-2022-KR", + "UCS-4", + "CSISO57GB1988", + "WINDOWS-1258", + "CSUCS4", + "CSISO2022KR", + "JP", + "WINDOWS-1253", + "STRK1048-2002", + "CSHPROMAN8", + "CSISO58GB231280", + "MACICELAND", + "CSISO14JISC6220RO", + "JIS_C6226-1983", + "ISO-10646-UCS-2", + "WINDOWS-936", + "BIG5HKSCS", + "BIG5-HKSCS", + "SHIFT-JIS", + "WINDOWS-1257", + "WINDOWS-1254", + "CN-GB-ISOIR165", + "CSSHIFTJIS", + "UTF-7", + "WINDOWS-1250", + "EXTENDED_UNIX_CODE_PACKED_FORMAT_FOR_JAPANESE", + "CN-GB", + "CSISO159JISX02121990", + "MACROMAN", + "GEORGIAN-ACADEMY", + "JIS_C6220-1969-RO", + "CSISOLATINHEBREW", + "MACARABIC", + "ISO_8859-5:1988", + "ISO_8859-8:1988", + "SHIFT_JIS", + "UCS-2BE", + "ISO_8859-9:1989", + "ISO_8859-3:1988", + "ISO-10646-UCS-4", + "MACROMANIA", + "ISO-2022-JP-2", + "ISO-2022-JP-1", + "CSISO2022JP2", + "JIS0208", + "ISO_8859-2:1987", + "NEXTSTEP", + "ISO_8859-1:1987", + "ISO_8859-6:1987", + "EUCJP", + "EUC-JP", + "CSISOLATINGREEK", + "ISO_8859-4:1988", + "ISO_8859-7:2003", + "GEORGIAN-PS", + "UCS-4BE", + "UTF-16BE", + "CSPC862LATINHEBREW", + "UCS-2LE", + "CSHALFWIDTHKATAKANA", + "ANSI_X3.4-1986", + "ISO_8859-7:1987", + "UTF-32BE", + "WINDOWS-874", + "ANSI_X3.4-1968", + "ISO-2022-JP", + "ISO646-JP", + "CSISO2022JP", + "CYRILLIC", + "MACCENTRALEUROPE", + "MS-HEBR", + "UNICODELITTLE", + "UCS-4LE", + "CYRILLIC-ASIAN", + "UTF-16LE", + "ISO_646.IRV:1991", + "UTF-32LE", + "JAVA", + "MS-ARAB", + "MULELAO-1", + "MS-GREEK", + "MACGREEK", + "BIGFIVE", + "BIG-FIVE", + "MS_KANJI", + "CSEUCKR", + "HEBREW", + "UCS-2-SWAPPED", + "JOHAB", + "CSEUCTW", + "UCS-2-INTERNAL", + "KOI8-U", + "MACUKRAINE", + "MACTURKISH", + "TCVN5712-1:1993", + "UCS-4-SWAPPED", + "MS-CYRL", + "MACCYRILLIC", + "CSISO87JISX0208", + "CSEUCPKDFMTJAPANESE", + "JIS_X0212", + "UCS-4-INTERNAL", + "UNICODEBIG", + "MS-TURK", + "BIG5-HKSCS:2001", + "JISX0201-1976", + "JIS_X0201", + "BIG5-HKSCS:1999", + "JIS_X0212-1990", + "KOI8-RU", + "JIS_X0208", + "MACHEBREW", + "JIS_X0208-1983", + "BIG5-HKSCS:2004", + "JIS_X0208-1990", + "JIS_X0212.1990-0", + "WINBALTRIM", + "CSPC850MULTILINGUAL" + }; +#define stringpool ((const char *) &stringpool_contents) + +static const struct alias aliases[] = + { + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 297 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str9, ei_iso646_cn}, + {-1}, {-1}, +#line 340 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str12, ei_hz}, + {-1}, {-1}, {-1}, +#line 212 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str16, ei_cp862}, +#line 186 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str17, ei_cp1252}, + {-1}, +#line 13 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str19, ei_ascii}, + {-1}, +#line 183 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str21, ei_cp1251}, +#line 317 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str22, ei_sjis}, + {-1}, +#line 210 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str24, ei_cp862}, + {-1}, +#line 216 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str26, ei_cp866}, +#line 198 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str27, ei_cp1256}, +#line 22 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str28, ei_ascii}, +#line 327 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str29, ei_euc_cn}, +#line 326 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str30, ei_euc_cn}, + {-1}, {-1}, +#line 195 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str33, ei_cp1255}, +#line 214 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str34, ei_cp866}, +#line 218 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str35, ei_cp1131}, +#line 52 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str36, ei_c99}, + {-1}, +#line 363 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str38, ei_johab}, +#line 331 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str39, ei_euc_cn}, + {-1}, {-1}, +#line 320 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str42, ei_cp932}, +#line 204 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str43, ei_cp1258}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 302 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str50, ei_gb2312}, + {-1}, +#line 333 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str52, ei_cp936}, +#line 58 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str53, ei_iso8859_1}, + {-1}, {-1}, {-1}, +#line 189 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str57, ei_cp1253}, +#line 73 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str58, ei_iso8859_2}, +#line 72 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str59, ei_iso8859_2}, +#line 65 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str60, ei_iso8859_2}, + {-1}, +#line 64 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str62, ei_iso8859_1}, +#line 63 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str63, ei_iso8859_1}, +#line 54 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str64, ei_iso8859_1}, + {-1}, +#line 147 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str66, ei_iso8859_11}, +#line 145 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str67, ei_iso8859_11}, +#line 107 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str68, ei_iso8859_6}, +#line 106 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str69, ei_iso8859_6}, +#line 98 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str70, ei_iso8859_6}, +#line 253 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str71, ei_cp1133}, +#line 175 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str72, ei_iso8859_16}, +#line 169 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str73, ei_iso8859_16}, +#line 97 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str74, ei_iso8859_5}, +#line 96 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str75, ei_iso8859_5}, +#line 90 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str76, ei_iso8859_5}, +#line 168 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str77, ei_iso8859_15}, +#line 167 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str78, ei_iso8859_15}, +#line 162 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str79, ei_iso8859_15}, + {-1}, +#line 337 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str81, ei_iso2022_cn}, + {-1}, +#line 295 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str83, ei_iso646_cn}, +#line 127 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str84, ei_iso8859_8}, +#line 126 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str85, ei_iso8859_8}, +#line 120 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str86, ei_iso8859_8}, + {-1}, +#line 338 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str88, ei_iso2022_cn}, + {-1}, +#line 136 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str90, ei_iso8859_9}, +#line 135 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str91, ei_iso8859_9}, +#line 128 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str92, ei_iso8859_9}, + {-1}, +#line 66 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str94, ei_iso8859_2}, + {-1}, +#line 339 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str96, ei_iso2022_cn_ext}, + {-1}, +#line 55 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str98, ei_iso8859_1}, +#line 81 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str99, ei_iso8859_3}, +#line 74 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str100, ei_iso8859_3}, +#line 146 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str101, ei_iso8859_11}, +#line 153 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str102, ei_iso8859_13}, +#line 148 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str103, ei_iso8859_13}, +#line 99 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str104, ei_iso8859_6}, +#line 360 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str105, ei_cp949}, + {-1}, +#line 170 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str107, ei_iso8859_16}, + {-1}, +#line 171 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str109, ei_iso8859_16}, +#line 91 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str110, ei_iso8859_5}, +#line 114 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str111, ei_iso8859_7}, + {-1}, +#line 163 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str113, ei_iso8859_15}, + {-1}, +#line 201 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str115, ei_cp1257}, + {-1}, {-1}, +#line 245 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str118, ei_pt154}, +#line 192 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str119, ei_cp1254}, +#line 121 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str120, ei_iso8859_8}, + {-1}, {-1}, +#line 164 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str123, ei_iso8859_15}, + {-1}, {-1}, +#line 129 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str126, ei_iso8859_9}, + {-1}, {-1}, +#line 19 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str129, ei_ascii}, +#line 208 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str130, ei_cp850}, +#line 180 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str131, ei_cp1250}, + {-1}, {-1}, +#line 75 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str134, ei_iso8859_3}, +#line 236 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str135, ei_hp_roman8}, + {-1}, +#line 149 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str137, ei_iso8859_13}, +#line 16 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str138, ei_ascii}, +#line 242 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str139, ei_koi8_t}, +#line 172 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str140, ei_iso8859_16}, +#line 206 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str141, ei_cp850}, +#line 112 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str142, ei_iso8859_7}, + {-1}, +#line 351 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str144, ei_cp950}, + {-1}, {-1}, +#line 261 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str147, ei_tis620}, +#line 256 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str148, ei_tis620}, +#line 255 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str149, ei_tis620}, + {-1}, {-1}, +#line 221 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str152, ei_mac_roman}, +#line 303 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str153, ei_isoir165}, + {-1}, {-1}, +#line 119 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str156, ei_iso8859_7}, +#line 118 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str157, ei_iso8859_7}, +#line 108 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str158, ei_iso8859_7}, +#line 139 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str159, ei_iso8859_10}, + {-1}, +#line 89 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str161, ei_iso8859_4}, +#line 82 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str162, ei_iso8859_4}, +#line 300 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str163, ei_gb2312}, +#line 161 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str164, ei_iso8859_14}, +#line 154 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str165, ei_iso8859_14}, +#line 156 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str166, ei_iso8859_14}, +#line 328 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str167, ei_euc_cn}, + {-1}, {-1}, +#line 262 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str170, ei_cp874}, +#line 211 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str171, ei_cp862}, +#line 292 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str172, ei_jisx0212}, + {-1}, {-1}, {-1}, +#line 144 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str176, ei_iso8859_10}, +#line 137 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str177, ei_iso8859_10}, +#line 123 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str178, ei_iso8859_8}, +#line 188 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str179, ei_cp1252}, +#line 157 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str180, ei_iso8859_14}, +#line 215 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str181, ei_cp866}, +#line 182 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str182, ei_cp1250}, +#line 104 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str183, ei_iso8859_6}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 243 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str190, ei_pt154}, + {-1}, +#line 109 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str192, ei_iso8859_7}, +#line 68 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str193, ei_iso8859_2}, + {-1}, +#line 233 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str195, ei_mac_thai}, +#line 83 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str196, ei_iso8859_4}, + {-1}, +#line 334 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str198, ei_cp936}, +#line 155 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str199, ei_iso8859_14}, +#line 59 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str200, ei_iso8859_1}, + {-1}, +#line 239 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str202, ei_armscii_8}, +#line 305 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str203, ei_ksc5601}, + {-1}, {-1}, +#line 220 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str206, ei_mac_roman}, +#line 257 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str207, ei_tis620}, +#line 113 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str208, ei_iso8859_7}, +#line 131 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str209, ei_iso8859_9}, + {-1}, +#line 138 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str211, ei_iso8859_10}, +#line 70 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str212, ei_iso8859_2}, +#line 150 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str213, ei_iso8859_13}, +#line 61 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str214, ei_iso8859_1}, +#line 308 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str215, ei_ksc5601}, + {-1}, +#line 142 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str217, ei_iso8859_10}, + {-1}, {-1}, +#line 133 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str220, ei_iso8859_9}, +#line 77 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str221, ei_iso8859_3}, +#line 222 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str222, ei_mac_roman}, + {-1}, {-1}, +#line 159 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str225, ei_iso8859_14}, + {-1}, +#line 165 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str227, ei_iso8859_15}, + {-1}, +#line 250 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str229, ei_rk1048}, +#line 101 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str230, ei_iso8859_6}, +#line 251 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str231, ei_rk1048}, +#line 79 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str232, ei_iso8859_3}, +#line 273 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str233, ei_iso646_jp}, + {-1}, +#line 296 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str235, ei_iso646_cn}, +#line 258 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str236, ei_tis620}, + {-1}, +#line 140 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str238, ei_iso8859_10}, +#line 69 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str239, ei_iso8859_2}, +#line 285 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str240, ei_jisx0208}, + {-1}, {-1}, +#line 60 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str243, ei_iso8859_1}, + {-1}, {-1}, +#line 309 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str246, ei_ksc5601}, +#line 310 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str247, ei_ksc5601}, +#line 85 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str248, ei_iso8859_4}, +#line 141 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str249, ei_iso8859_10}, +#line 160 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str250, ei_iso8859_14}, +#line 264 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str251, ei_viscii}, + {-1}, {-1}, +#line 266 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str254, ei_viscii}, +#line 132 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str255, ei_iso8859_9}, + {-1}, {-1}, +#line 366 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str258, ei_local_char}, +#line 307 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str259, ei_ksc5601}, +#line 260 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str260, ei_tis620}, +#line 152 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str261, ei_iso8859_13}, +#line 248 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str262, ei_rk1048}, +#line 87 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str263, ei_iso8859_4}, +#line 71 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str264, ei_iso8859_2}, +#line 158 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str265, ei_iso8859_14}, +#line 244 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str266, ei_pt154}, + {-1}, +#line 62 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str268, ei_iso8859_1}, + {-1}, {-1}, +#line 267 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str271, ei_tcvn}, +#line 166 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str272, ei_iso8859_15}, +#line 95 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str273, ei_iso8859_5}, +#line 143 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str274, ei_iso8859_10}, + {-1}, +#line 20 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str276, ei_ascii}, +#line 115 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str277, ei_iso8859_7}, + {-1}, +#line 78 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str279, ei_iso8859_3}, +#line 134 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str280, ei_iso8859_9}, +#line 291 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str281, ei_jisx0212}, + {-1}, +#line 105 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str283, ei_iso8859_6}, +#line 102 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str284, ei_iso8859_6}, +#line 93 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str285, ei_iso8859_5}, +#line 247 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str286, ei_pt154}, +#line 361 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str287, ei_cp949}, +#line 207 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str288, ei_cp850}, + {-1}, +#line 21 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str290, ei_ascii}, + {-1}, +#line 306 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str292, ei_ksc5601}, +#line 25 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str293, ei_ucs2}, + {-1}, +#line 254 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str295, ei_cp1133}, + {-1}, {-1}, {-1}, {-1}, +#line 103 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str300, ei_iso8859_6}, + {-1}, {-1}, +#line 57 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str303, ei_iso8859_1}, +#line 80 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str304, ei_iso8859_3}, + {-1}, {-1}, {-1}, +#line 345 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str308, ei_ces_big5}, +#line 346 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str309, ei_ces_big5}, +#line 12 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str310, ei_ascii}, +#line 350 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str311, ei_ces_big5}, +#line 349 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str312, ei_ces_big5}, + {-1}, +#line 332 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str314, ei_ces_gbk}, +#line 259 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str315, ei_tis620}, +#line 30 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str316, ei_ucs2be}, + {-1}, +#line 235 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str318, ei_hp_roman8}, +#line 330 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str319, ei_euc_cn}, + {-1}, {-1}, {-1}, +#line 31 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str323, ei_ucs2be}, + {-1}, +#line 27 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str325, ei_ucs2}, + {-1}, +#line 174 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str327, ei_iso8859_16}, + {-1}, +#line 268 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str329, ei_tcvn}, +#line 341 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str330, ei_hz}, +#line 234 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str331, ei_hp_roman8}, +#line 299 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str332, ei_gb2312}, +#line 217 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str333, ei_cp866}, +#line 269 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str334, ei_tcvn}, +#line 225 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str335, ei_mac_croatian}, +#line 116 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str336, ei_iso8859_7}, +#line 151 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str337, ei_iso8859_13}, + {-1}, {-1}, +#line 278 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str340, ei_jisx0201}, +#line 86 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str341, ei_iso8859_4}, +#line 358 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str342, ei_euc_kr}, +#line 357 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str343, ei_euc_kr}, + {-1}, +#line 176 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str345, ei_koi8_r}, + {-1}, +#line 177 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str347, ei_koi8_r}, + {-1}, {-1}, {-1}, {-1}, +#line 336 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str352, ei_gb18030}, + {-1}, +#line 294 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str354, ei_iso646_cn}, +#line 39 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str355, ei_utf16}, +#line 173 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str356, ei_iso8859_16}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 284 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str362, ei_jisx0208}, +#line 42 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str363, ei_utf32}, +#line 14 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str364, ei_ascii}, + {-1}, +#line 88 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str366, ei_iso8859_4}, +#line 24 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str367, ei_utf8}, +#line 23 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str368, ei_utf8}, +#line 46 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str369, ei_utf7}, + {-1}, {-1}, {-1}, {-1}, +#line 47 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str374, ei_utf7}, + {-1}, +#line 265 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str376, ei_viscii}, +#line 343 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str377, ei_euc_tw}, +#line 342 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str378, ei_euc_tw}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 187 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str384, ei_cp1252}, + {-1}, +#line 184 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str386, ei_cp1251}, + {-1}, {-1}, +#line 199 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str389, ei_cp1256}, +#line 367 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str390, ei_local_wchar_t}, + {-1}, +#line 196 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str392, ei_cp1255}, + {-1}, +#line 364 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str394, ei_iso2022_kr}, +#line 34 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str395, ei_ucs4}, +#line 298 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str396, ei_iso646_cn}, +#line 205 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str397, ei_cp1258}, +#line 36 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str398, ei_ucs4}, + {-1}, {-1}, +#line 365 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str401, ei_iso2022_kr}, + {-1}, +#line 274 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str403, ei_iso646_jp}, +#line 190 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str404, ei_cp1253}, +#line 249 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str405, ei_rk1048}, +#line 237 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str406, ei_hp_roman8}, + {-1}, +#line 301 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str408, ei_gb2312}, + {-1}, +#line 224 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str410, ei_mac_iceland}, + {-1}, +#line 275 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str412, ei_iso646_jp}, + {-1}, {-1}, +#line 286 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str415, ei_jisx0208}, + {-1}, +#line 26 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str417, ei_ucs2}, + {-1}, +#line 335 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str419, ei_cp936}, +#line 355 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str420, ei_big5hkscs2004}, +#line 354 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str421, ei_big5hkscs2004}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 316 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str427, ei_sjis}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 202 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str433, ei_cp1257}, + {-1}, +#line 193 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str435, ei_cp1254}, + {-1}, +#line 304 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str437, ei_isoir165}, + {-1}, +#line 319 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str439, ei_sjis}, +#line 45 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str440, ei_utf7}, +#line 181 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str441, ei_cp1250}, +#line 313 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str442, ei_euc_jp}, +#line 329 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str443, ei_euc_cn}, +#line 293 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str444, ei_jisx0212}, + {-1}, {-1}, {-1}, +#line 219 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str448, ei_mac_roman}, +#line 240 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str449, ei_georgian_academy}, +#line 271 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str450, ei_iso646_jp}, +#line 125 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str451, ei_iso8859_8}, + {-1}, {-1}, +#line 232 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str454, ei_mac_arabic}, +#line 92 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str455, ei_iso8859_5}, + {-1}, {-1}, {-1}, {-1}, +#line 122 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str460, ei_iso8859_8}, +#line 315 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str461, ei_sjis}, + {-1}, {-1}, +#line 28 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str464, ei_ucs2be}, + {-1}, +#line 130 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str466, ei_iso8859_9}, +#line 76 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str467, ei_iso8859_3}, +#line 35 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str468, ei_ucs4}, + {-1}, +#line 226 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str470, ei_mac_romania}, +#line 324 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str471, ei_iso2022_jp2}, + {-1}, +#line 323 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str473, ei_iso2022_jp1}, + {-1}, {-1}, {-1}, +#line 325 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str477, ei_iso2022_jp2}, + {-1}, {-1}, {-1}, +#line 283 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str481, ei_jisx0208}, + {-1}, +#line 67 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str483, ei_iso8859_2}, +#line 238 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str484, ei_nextstep}, +#line 56 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str485, ei_iso8859_1}, + {-1}, {-1}, +#line 100 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str488, ei_iso8859_6}, + {-1}, +#line 312 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str490, ei_euc_jp}, +#line 311 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str491, ei_euc_jp}, + {-1}, +#line 117 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str493, ei_iso8859_7}, + {-1}, {-1}, {-1}, {-1}, +#line 84 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str498, ei_iso8859_4}, + {-1}, {-1}, {-1}, {-1}, +#line 111 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str503, ei_iso8859_7}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 241 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str513, ei_georgian_ps}, + {-1}, +#line 37 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str515, ei_ucs4be}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 40 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str521, ei_utf16be}, + {-1}, +#line 213 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str523, ei_cp862}, + {-1}, +#line 32 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str525, ei_ucs2le}, +#line 279 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str526, ei_jisx0201}, + {-1}, {-1}, {-1}, {-1}, +#line 18 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str531, ei_ascii}, +#line 110 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str532, ei_iso8859_7}, + {-1}, +#line 43 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str534, ei_utf32be}, + {-1}, {-1}, +#line 263 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str537, ei_cp874}, + {-1}, +#line 17 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str539, ei_ascii}, + {-1}, {-1}, +#line 321 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str542, ei_iso2022_jp}, + {-1}, +#line 272 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str544, ei_iso646_jp}, + {-1}, {-1}, {-1}, {-1}, +#line 322 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str549, ei_iso2022_jp}, + {-1}, +#line 94 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str551, ei_iso8859_5}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 223 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str561, ei_mac_centraleurope}, + {-1}, +#line 197 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str563, ei_cp1255}, + {-1}, {-1}, +#line 33 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str566, ei_ucs2le}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 38 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str576, ei_ucs4le}, + {-1}, {-1}, {-1}, {-1}, +#line 246 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str581, ei_pt154}, +#line 41 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str582, ei_utf16le}, +#line 15 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str583, ei_ascii}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, +#line 44 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str595, ei_utf32le}, +#line 53 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str596, ei_java}, + {-1}, +#line 200 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str598, ei_cp1256}, + {-1}, {-1}, {-1}, {-1}, +#line 252 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str603, ei_mulelao}, + {-1}, {-1}, +#line 191 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str606, ei_cp1253}, +#line 229 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str607, ei_mac_greek}, +#line 348 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str608, ei_ces_big5}, +#line 347 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str609, ei_ces_big5}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, +#line 318 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str622, ei_sjis}, + {-1}, {-1}, {-1}, {-1}, +#line 359 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str627, ei_euc_kr}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, +#line 124 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str639, ei_iso8859_8}, + {-1}, {-1}, {-1}, {-1}, +#line 49 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str644, ei_ucs2swapped}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 362 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str654, ei_johab}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 344 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str662, ei_euc_tw}, + {-1}, {-1}, +#line 48 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str665, ei_ucs2internal}, + {-1}, {-1}, {-1}, +#line 178 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str669, ei_koi8_u}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 228 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str685, ei_mac_ukraine}, + {-1}, {-1}, {-1}, +#line 230 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str689, ei_mac_turkish}, + {-1}, {-1}, +#line 270 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str692, ei_tcvn}, + {-1}, {-1}, +#line 51 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str695, ei_ucs4swapped}, + {-1}, +#line 185 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str697, ei_cp1251}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 227 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str704, ei_mac_cyrillic}, +#line 287 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str705, ei_jisx0208}, + {-1}, +#line 314 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str707, ei_euc_jp}, + {-1}, {-1}, +#line 288 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str710, ei_jisx0212}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 50 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str716, ei_ucs4internal}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, +#line 29 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str736, ei_ucs2be}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 194 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str745, ei_cp1254}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, +#line 353 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str757, ei_big5hkscs2001}, + {-1}, {-1}, +#line 277 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str760, ei_jisx0201}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 276 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str769, ei_jisx0201}, + {-1}, +#line 352 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str771, ei_big5hkscs1999}, + {-1}, {-1}, +#line 290 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str774, ei_jisx0212}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 179 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str790, ei_koi8_ru}, +#line 280 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str791, ei_jisx0208}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 231 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str800, ei_mac_hebrew}, + {-1}, {-1}, {-1}, {-1}, +#line 281 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str805, ei_jisx0208}, +#line 356 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str806, ei_big5hkscs2004}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 282 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str842, ei_jisx0208}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 289 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str888, ei_jisx0212}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, +#line 203 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str991, ei_cp1257}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, +#line 209 "lib/aliases_syshpux.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str1038, ei_cp850} + }; + +#ifdef __GNUC__ +__inline +#if defined __GNUC_STDC_INLINE__ || defined __GNUC_GNU_INLINE__ +__attribute__ ((__gnu_inline__)) +#endif +#endif +const struct alias * +aliases_lookup (register const char *str, register unsigned int len) +{ + if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) + { + register int key = aliases_hash (str, len); + + if (key <= MAX_HASH_VALUE && key >= 0) + { + register int o = aliases[key].name; + if (o >= 0) + { + register const char *s = o + stringpool; + + if (*str == *s && !strcmp (str + 1, s + 1)) + return &aliases[key]; + } + } + } + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/aliases_sysosf1.h b/graf2d/win32gdk/gdk/src/iconv/aliases_sysosf1.h new file mode 100644 index 0000000000000..36587e1a8a3a8 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/aliases_sysosf1.h @@ -0,0 +1,1735 @@ +/* ANSI-C code produced by gperf version 3.0.4 */ +/* Command-line: gperf -m 10 lib/aliases_sysosf1.gperf */ +/* Computed positions: -k'1,3-11,$' */ + +#if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ + && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ + && (')' == 41) && ('*' == 42) && ('+' == 43) && (',' == 44) \ + && ('-' == 45) && ('.' == 46) && ('/' == 47) && ('0' == 48) \ + && ('1' == 49) && ('2' == 50) && ('3' == 51) && ('4' == 52) \ + && ('5' == 53) && ('6' == 54) && ('7' == 55) && ('8' == 56) \ + && ('9' == 57) && (':' == 58) && (';' == 59) && ('<' == 60) \ + && ('=' == 61) && ('>' == 62) && ('?' == 63) && ('A' == 65) \ + && ('B' == 66) && ('C' == 67) && ('D' == 68) && ('E' == 69) \ + && ('F' == 70) && ('G' == 71) && ('H' == 72) && ('I' == 73) \ + && ('J' == 74) && ('K' == 75) && ('L' == 76) && ('M' == 77) \ + && ('N' == 78) && ('O' == 79) && ('P' == 80) && ('Q' == 81) \ + && ('R' == 82) && ('S' == 83) && ('T' == 84) && ('U' == 85) \ + && ('V' == 86) && ('W' == 87) && ('X' == 88) && ('Y' == 89) \ + && ('Z' == 90) && ('[' == 91) && ('\\' == 92) && (']' == 93) \ + && ('^' == 94) && ('_' == 95) && ('a' == 97) && ('b' == 98) \ + && ('c' == 99) && ('d' == 100) && ('e' == 101) && ('f' == 102) \ + && ('g' == 103) && ('h' == 104) && ('i' == 105) && ('j' == 106) \ + && ('k' == 107) && ('l' == 108) && ('m' == 109) && ('n' == 110) \ + && ('o' == 111) && ('p' == 112) && ('q' == 113) && ('r' == 114) \ + && ('s' == 115) && ('t' == 116) && ('u' == 117) && ('v' == 118) \ + && ('w' == 119) && ('x' == 120) && ('y' == 121) && ('z' == 122) \ + && ('{' == 123) && ('|' == 124) && ('}' == 125) && ('~' == 126)) +/* The character set is not based on ISO-646. */ +#error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gnu-gperf@gnu.org>." +#endif + +#line 1 "lib/aliases_sysosf1.gperf" +struct alias { int name; unsigned int encoding_index; }; + +#define TOTAL_KEYWORDS 351 +#define MIN_WORD_LENGTH 2 +#define MAX_WORD_LENGTH 45 +#define MIN_HASH_VALUE 13 +#define MAX_HASH_VALUE 939 +/* maximum key range = 927, duplicates = 0 */ + +#ifdef __GNUC__ +__inline +#else +#ifdef __cplusplus +inline +#endif +#endif +static unsigned int +aliases_hash (register const char *str, register unsigned int len) +{ + static const unsigned short asso_values[] = + { + 940, 940, 940, 940, 940, 940, 940, 940, 940, 940, + 940, 940, 940, 940, 940, 940, 940, 940, 940, 940, + 940, 940, 940, 940, 940, 940, 940, 940, 940, 940, + 940, 940, 940, 940, 940, 940, 940, 940, 940, 940, + 940, 940, 940, 940, 940, 13, 80, 940, 73, 4, + 7, 6, 55, 8, 5, 156, 10, 23, 354, 940, + 940, 940, 940, 940, 940, 115, 165, 4, 6, 104, + 89, 13, 53, 4, 304, 95, 7, 150, 18, 4, + 75, 940, 76, 50, 25, 141, 173, 137, 120, 6, + 5, 940, 940, 940, 940, 27, 940, 940, 940, 940, + 940, 940, 940, 940, 940, 940, 940, 940, 940, 940, + 940, 940, 940, 940, 940, 940, 940, 940, 940, 940, + 940, 940, 940, 940, 940, 940, 940, 940 + }; + register int hval = len; + + switch (hval) + { + default: + hval += asso_values[(unsigned char)str[10]]; + /*FALLTHROUGH*/ + case 10: + hval += asso_values[(unsigned char)str[9]]; + /*FALLTHROUGH*/ + case 9: + hval += asso_values[(unsigned char)str[8]]; + /*FALLTHROUGH*/ + case 8: + hval += asso_values[(unsigned char)str[7]]; + /*FALLTHROUGH*/ + case 7: + hval += asso_values[(unsigned char)str[6]]; + /*FALLTHROUGH*/ + case 6: + hval += asso_values[(unsigned char)str[5]]; + /*FALLTHROUGH*/ + case 5: + hval += asso_values[(unsigned char)str[4]]; + /*FALLTHROUGH*/ + case 4: + hval += asso_values[(unsigned char)str[3]]; + /*FALLTHROUGH*/ + case 3: + hval += asso_values[(unsigned char)str[2]]; + /*FALLTHROUGH*/ + case 2: + case 1: + hval += asso_values[(unsigned char)str[0]]; + break; + } + return hval + asso_values[(unsigned char)str[len - 1]]; +} + +struct stringpool_t + { + char stringpool_str13[sizeof("L1")]; + char stringpool_str14[sizeof("L6")]; + char stringpool_str15[sizeof("L3")]; + char stringpool_str16[sizeof("L2")]; + char stringpool_str17[sizeof("L5")]; + char stringpool_str19[sizeof("L8")]; + char stringpool_str23[sizeof("866")]; + char stringpool_str24[sizeof("CN")]; + char stringpool_str27[sizeof("862")]; + char stringpool_str32[sizeof("CP1131")]; + char stringpool_str33[sizeof("CP1361")]; + char stringpool_str34[sizeof("CP866")]; + char stringpool_str36[sizeof("CP1133")]; + char stringpool_str37[sizeof("CP1251")]; + char stringpool_str38[sizeof("CP862")]; + char stringpool_str39[sizeof("CP1256")]; + char stringpool_str41[sizeof("CP1253")]; + char stringpool_str43[sizeof("CP1252")]; + char stringpool_str45[sizeof("CP1255")]; + char stringpool_str48[sizeof("CP936")]; + char stringpool_str49[sizeof("CP1258")]; + char stringpool_str50[sizeof("GB2312")]; + char stringpool_str52[sizeof("CP932")]; + char stringpool_str53[sizeof("C99")]; + char stringpool_str60[sizeof("HZ")]; + char stringpool_str64[sizeof("L4")]; + char stringpool_str68[sizeof("LATIN1")]; + char stringpool_str69[sizeof("CP819")]; + char stringpool_str70[sizeof("LATIN6")]; + char stringpool_str72[sizeof("LATIN3")]; + char stringpool_str74[sizeof("LATIN2")]; + char stringpool_str76[sizeof("LATIN5")]; + char stringpool_str80[sizeof("LATIN8")]; + char stringpool_str88[sizeof("R8")]; + char stringpool_str89[sizeof("ISO8859-1")]; + char stringpool_str91[sizeof("ISO8859-6")]; + char stringpool_str93[sizeof("ISO8859-3")]; + char stringpool_str94[sizeof("ISO8859-11")]; + char stringpool_str95[sizeof("ISO8859-2")]; + char stringpool_str96[sizeof("ISO8859-16")]; + char stringpool_str97[sizeof("ISO8859-5")]; + char stringpool_str98[sizeof("ISO8859-13")]; + char stringpool_str101[sizeof("ISO8859-8")]; + char stringpool_str102[sizeof("ISO8859-15")]; + char stringpool_str103[sizeof("ISO-8859-1")]; + char stringpool_str105[sizeof("ISO-8859-6")]; + char stringpool_str107[sizeof("ISO-8859-3")]; + char stringpool_str108[sizeof("ISO-8859-11")]; + char stringpool_str109[sizeof("ISO-8859-2")]; + char stringpool_str110[sizeof("ISO-8859-16")]; + char stringpool_str111[sizeof("ISO-8859-5")]; + char stringpool_str112[sizeof("ISO-8859-13")]; + char stringpool_str115[sizeof("ISO-8859-8")]; + char stringpool_str116[sizeof("ISO-8859-15")]; + char stringpool_str117[sizeof("ISO_8859-1")]; + char stringpool_str118[sizeof("CYRILLIC")]; + char stringpool_str119[sizeof("ISO_8859-6")]; + char stringpool_str120[sizeof("LATIN-9")]; + char stringpool_str121[sizeof("ISO_8859-3")]; + char stringpool_str122[sizeof("ISO_8859-11")]; + char stringpool_str123[sizeof("ISO_8859-2")]; + char stringpool_str124[sizeof("ISO_8859-16")]; + char stringpool_str125[sizeof("ISO_8859-5")]; + char stringpool_str126[sizeof("ISO_8859-13")]; + char stringpool_str127[sizeof("ISO8859-9")]; + char stringpool_str128[sizeof("ISO_8859-16:2001")]; + char stringpool_str129[sizeof("ISO_8859-8")]; + char stringpool_str130[sizeof("ISO_8859-15")]; + char stringpool_str131[sizeof("CP154")]; + char stringpool_str132[sizeof("ISO-IR-6")]; + char stringpool_str133[sizeof("CP949")]; + char stringpool_str135[sizeof("ISO646-CN")]; + char stringpool_str136[sizeof("ASCII")]; + char stringpool_str137[sizeof("ISO_8859-15:1998")]; + char stringpool_str139[sizeof("CP1254")]; + char stringpool_str141[sizeof("ISO-8859-9")]; + char stringpool_str143[sizeof("ISO-IR-166")]; + char stringpool_str145[sizeof("ISO-IR-126")]; + char stringpool_str148[sizeof("ISO-IR-226")]; + char stringpool_str149[sizeof("ISO-IR-165")]; + char stringpool_str150[sizeof("X0212")]; + char stringpool_str151[sizeof("ISO-IR-58")]; + char stringpool_str152[sizeof("UHC")]; + char stringpool_str153[sizeof("EUCCN")]; + char stringpool_str154[sizeof("ISO-IR-138")]; + char stringpool_str155[sizeof("ISO_8859-9")]; + char stringpool_str156[sizeof("L10")]; + char stringpool_str158[sizeof("SJIS")]; + char stringpool_str159[sizeof("850")]; + char stringpool_str161[sizeof("MAC")]; + char stringpool_str164[sizeof("TACTIS")]; + char stringpool_str165[sizeof("L7")]; + char stringpool_str167[sizeof("EUC-CN")]; + char stringpool_str170[sizeof("LATIN4")]; + char stringpool_str173[sizeof("CP850")]; + char stringpool_str175[sizeof("CP1250")]; + char stringpool_str178[sizeof("KOI8-T")]; + char stringpool_str179[sizeof("ISO-2022-CN")]; + char stringpool_str182[sizeof("ISO-IR-159")]; + char stringpool_str183[sizeof("ISO-CELTIC")]; + char stringpool_str184[sizeof("ISO_8859-14:1998")]; + char stringpool_str185[sizeof("IBM866")]; + char stringpool_str186[sizeof("CP950")]; + char stringpool_str189[sizeof("IBM862")]; + char stringpool_str190[sizeof("ISO-2022-CN-EXT")]; + char stringpool_str191[sizeof("ISO8859-4")]; + char stringpool_str192[sizeof("CSASCII")]; + char stringpool_str193[sizeof("US")]; + char stringpool_str194[sizeof("MS936")]; + char stringpool_str196[sizeof("ISO8859-14")]; + char stringpool_str197[sizeof("ISO-IR-199")]; + char stringpool_str198[sizeof("BIG5")]; + char stringpool_str199[sizeof("ISO_8859-10:1992")]; + char stringpool_str200[sizeof("KSC5601")]; + char stringpool_str202[sizeof("PT154")]; + char stringpool_str203[sizeof("ISO-IR-148")]; + char stringpool_str205[sizeof("ISO-8859-4")]; + char stringpool_str206[sizeof("GBK")]; + char stringpool_str207[sizeof("CSISO2022CN")]; + char stringpool_str208[sizeof("CSBIG5")]; + char stringpool_str209[sizeof("ISO-IR-101")]; + char stringpool_str210[sizeof("ISO-8859-14")]; + char stringpool_str211[sizeof("LATIN10")]; + char stringpool_str212[sizeof("BIG-5")]; + char stringpool_str213[sizeof("X0201")]; + char stringpool_str216[sizeof("ISO-IR-203")]; + char stringpool_str217[sizeof("DECHANZI")]; + char stringpool_str218[sizeof("ELOT_928")]; + char stringpool_str219[sizeof("ISO_8859-4")]; + char stringpool_str220[sizeof("IBM819")]; + char stringpool_str221[sizeof("CSGB2312")]; + char stringpool_str222[sizeof("CN-BIG5")]; + char stringpool_str223[sizeof("UCS-2")]; + char stringpool_str224[sizeof("ISO_8859-14")]; + char stringpool_str225[sizeof("X0208")]; + char stringpool_str228[sizeof("KSC_5601")]; + char stringpool_str229[sizeof("ISO-IR-149")]; + char stringpool_str232[sizeof("ISO8859-10")]; + char stringpool_str234[sizeof("RK1048")]; + char stringpool_str237[sizeof("ISO-IR-14")]; + char stringpool_str238[sizeof("TCVN")]; + char stringpool_str239[sizeof("TIS620")]; + char stringpool_str243[sizeof("GB_2312-80")]; + char stringpool_str245[sizeof("VISCII")]; + char stringpool_str246[sizeof("ISO-8859-10")]; + char stringpool_str247[sizeof("ISO-IR-109")]; + char stringpool_str250[sizeof("CSISOLATIN1")]; + char stringpool_str252[sizeof("CSISOLATIN6")]; + char stringpool_str253[sizeof("TIS-620")]; + char stringpool_str254[sizeof("CSISOLATIN3")]; + char stringpool_str255[sizeof("CSVISCII")]; + char stringpool_str256[sizeof("CSISOLATIN2")]; + char stringpool_str257[sizeof("CSISOLATINCYRILLIC")]; + char stringpool_str258[sizeof("CSISOLATIN5")]; + char stringpool_str259[sizeof("GB18030")]; + char stringpool_str260[sizeof("ISO_8859-10")]; + char stringpool_str263[sizeof("UTF-16")]; + char stringpool_str264[sizeof("CSKZ1048")]; + char stringpool_str266[sizeof("GB_1988-80")]; + char stringpool_str267[sizeof("KZ-1048")]; + char stringpool_str268[sizeof("UTF-8")]; + char stringpool_str269[sizeof("UTF-32")]; + char stringpool_str270[sizeof("MS-CYRL")]; + char stringpool_str275[sizeof("CHAR")]; + char stringpool_str276[sizeof("CSKOI8R")]; + char stringpool_str278[sizeof("ISO-IR-110")]; + char stringpool_str280[sizeof("KOI8-R")]; + char stringpool_str281[sizeof("MACCYRILLIC")]; + char stringpool_str282[sizeof("IBM-CP1133")]; + char stringpool_str283[sizeof("PTCP154")]; + char stringpool_str284[sizeof("TIS620.2533-1")]; + char stringpool_str285[sizeof("CP874")]; + char stringpool_str293[sizeof("ISO-IR-144")]; + char stringpool_str297[sizeof("KS_C_5601-1989")]; + char stringpool_str298[sizeof("HZ-GB-2312")]; + char stringpool_str302[sizeof("TIS620.2529-1")]; + char stringpool_str308[sizeof("CSUNICODE11")]; + char stringpool_str312[sizeof("UNICODE-1-1")]; + char stringpool_str314[sizeof("CSPTCP154")]; + char stringpool_str315[sizeof("CSUCS4")]; + char stringpool_str316[sizeof("CYRILLIC-ASIAN")]; + char stringpool_str319[sizeof("UCS-4")]; + char stringpool_str324[sizeof("IBM850")]; + char stringpool_str327[sizeof("TIS620-0")]; + char stringpool_str330[sizeof("ISO-IR-179")]; + char stringpool_str332[sizeof("CP367")]; + char stringpool_str336[sizeof("ISO646-US")]; + char stringpool_str339[sizeof("ISO-10646-UCS-2")]; + char stringpool_str341[sizeof("CP1257")]; + char stringpool_str342[sizeof("GREEK8")]; + char stringpool_str343[sizeof("US-ASCII")]; + char stringpool_str347[sizeof("ISO-IR-100")]; + char stringpool_str352[sizeof("CSISOLATIN4")]; + char stringpool_str353[sizeof("TIS620.2533-0")]; + char stringpool_str354[sizeof("CSISOLATINGREEK")]; + char stringpool_str355[sizeof("VISCII1.1-1")]; + char stringpool_str356[sizeof("CSIBM866")]; + char stringpool_str359[sizeof("CSISO58GB231280")]; + char stringpool_str360[sizeof("EUCKR")]; + char stringpool_str361[sizeof("MS-ANSI")]; + char stringpool_str362[sizeof("MACTHAI")]; + char stringpool_str365[sizeof("CN-GB")]; + char stringpool_str366[sizeof("CSISOLATINARABIC")]; + char stringpool_str368[sizeof("CN-GB-ISOIR165")]; + char stringpool_str369[sizeof("ARMSCII-8")]; + char stringpool_str370[sizeof("MACINTOSH")]; + char stringpool_str372[sizeof("LATIN7")]; + char stringpool_str374[sizeof("EUC-KR")]; + char stringpool_str381[sizeof("JP")]; + char stringpool_str385[sizeof("ROMAN8")]; + char stringpool_str386[sizeof("ISO-2022-KR")]; + char stringpool_str387[sizeof("ISO-10646-UCS-4")]; + char stringpool_str393[sizeof("ISO8859-7")]; + char stringpool_str395[sizeof("CHINESE")]; + char stringpool_str397[sizeof("GEORGIAN-ACADEMY")]; + char stringpool_str398[sizeof("CSUNICODE")]; + char stringpool_str400[sizeof("WINDOWS-1251")]; + char stringpool_str401[sizeof("WINDOWS-1256")]; + char stringpool_str402[sizeof("WINDOWS-1253")]; + char stringpool_str403[sizeof("WINDOWS-1252")]; + char stringpool_str404[sizeof("WINDOWS-1255")]; + char stringpool_str406[sizeof("WINDOWS-1258")]; + char stringpool_str407[sizeof("ISO-8859-7")]; + char stringpool_str410[sizeof("KOI8-U")]; + char stringpool_str411[sizeof("CSPC862LATINHEBREW")]; + char stringpool_str412[sizeof("EUCTW")]; + char stringpool_str413[sizeof("ARABIC")]; + char stringpool_str414[sizeof("CSISO2022KR")]; + char stringpool_str415[sizeof("WINDOWS-936")]; + char stringpool_str416[sizeof("GREEK")]; + char stringpool_str417[sizeof("MULELAO-1")]; + char stringpool_str418[sizeof("ECMA-118")]; + char stringpool_str420[sizeof("TCVN-5712")]; + char stringpool_str421[sizeof("ISO_8859-7")]; + char stringpool_str422[sizeof("TCVN5712-1")]; + char stringpool_str426[sizeof("EUC-TW")]; + char stringpool_str428[sizeof("MACICELAND")]; + char stringpool_str430[sizeof("KS_C_5601-1987")]; + char stringpool_str432[sizeof("KOREAN")]; + char stringpool_str433[sizeof("UCS-2LE")]; + char stringpool_str437[sizeof("CSISOLATINHEBREW")]; + char stringpool_str439[sizeof("CSKSC56011987")]; + char stringpool_str441[sizeof("UNICODELITTLE")]; + char stringpool_str442[sizeof("GEORGIAN-PS")]; + char stringpool_str443[sizeof("ISO-IR-57")]; + char stringpool_str445[sizeof("ISO-IR-87")]; + char stringpool_str446[sizeof("JIS_C6226-1983")]; + char stringpool_str447[sizeof("ISO-IR-127")]; + char stringpool_str448[sizeof("ISO-IR-157")]; + char stringpool_str449[sizeof("DECKOREAN")]; + char stringpool_str451[sizeof("WINDOWS-1254")]; + char stringpool_str453[sizeof("ISO_646.IRV:1991")]; + char stringpool_str454[sizeof("CSISO57GB1988")]; + char stringpool_str458[sizeof("HP-ROMAN8")]; + char stringpool_str464[sizeof("CSUNICODE11UTF7")]; + char stringpool_str465[sizeof("WCHAR_T")]; + char stringpool_str468[sizeof("UNICODEBIG")]; + char stringpool_str469[sizeof("WINDOWS-1250")]; + char stringpool_str470[sizeof("UNICODE-1-1-UTF-7")]; + char stringpool_str472[sizeof("UCS-2-INTERNAL")]; + char stringpool_str475[sizeof("UTF-16LE")]; + char stringpool_str476[sizeof("STRK1048-2002")]; + char stringpool_str479[sizeof("UTF-32LE")]; + char stringpool_str480[sizeof("MS-EE")]; + char stringpool_str481[sizeof("UCS-4LE")]; + char stringpool_str483[sizeof("IBM367")]; + char stringpool_str484[sizeof("ISO_8859-3:1988")]; + char stringpool_str486[sizeof("ISO_8859-5:1988")]; + char stringpool_str487[sizeof("KOI8-RU")]; + char stringpool_str488[sizeof("ISO_8859-8:1988")]; + char stringpool_str491[sizeof("CSMACINTOSH")]; + char stringpool_str493[sizeof("ANSI_X3.4-1986")]; + char stringpool_str497[sizeof("BIG5HKSCS")]; + char stringpool_str498[sizeof("ANSI_X3.4-1968")]; + char stringpool_str500[sizeof("NEXTSTEP")]; + char stringpool_str504[sizeof("CSISO14JISC6220RO")]; + char stringpool_str507[sizeof("CSEUCKR")]; + char stringpool_str508[sizeof("ECMA-114")]; + char stringpool_str511[sizeof("BIG5-HKSCS")]; + char stringpool_str514[sizeof("ISO_8859-9:1989")]; + char stringpool_str515[sizeof("JIS_C6220-1969-RO")]; + char stringpool_str520[sizeof("UCS-4-INTERNAL")]; + char stringpool_str523[sizeof("CSPC850MULTILINGUAL")]; + char stringpool_str524[sizeof("ISO-2022-JP-1")]; + char stringpool_str525[sizeof("CSHPROMAN8")]; + char stringpool_str527[sizeof("ISO-2022-JP-2")]; + char stringpool_str533[sizeof("ISO_8859-4:1988")]; + char stringpool_str534[sizeof("JIS0208")]; + char stringpool_str539[sizeof("ASMO-708")]; + char stringpool_str543[sizeof("MACROMAN")]; + char stringpool_str544[sizeof("MACCROATIAN")]; + char stringpool_str548[sizeof("CSISO159JISX02121990")]; + char stringpool_str549[sizeof("ISO646-JP")]; + char stringpool_str552[sizeof("WINDOWS-1257")]; + char stringpool_str554[sizeof("CSISO2022JP2")]; + char stringpool_str559[sizeof("CSEUCTW")]; + char stringpool_str560[sizeof("UTF-7")]; + char stringpool_str567[sizeof("EUCJP")]; + char stringpool_str581[sizeof("EUC-JP")]; + char stringpool_str591[sizeof("UCS-2BE")]; + char stringpool_str593[sizeof("ISO-2022-JP")]; + char stringpool_str598[sizeof("SHIFT-JIS")]; + char stringpool_str602[sizeof("MS-TURK")]; + char stringpool_str608[sizeof("JIS_X0212")]; + char stringpool_str612[sizeof("SHIFT_JIS")]; + char stringpool_str621[sizeof("CSISO2022JP")]; + char stringpool_str627[sizeof("CSHALFWIDTHKATAKANA")]; + char stringpool_str628[sizeof("ISO_8859-1:1987")]; + char stringpool_str629[sizeof("ISO_8859-6:1987")]; + char stringpool_str630[sizeof("ISO_8859-7:2003")]; + char stringpool_str631[sizeof("ISO_8859-2:1987")]; + char stringpool_str633[sizeof("UTF-16BE")]; + char stringpool_str637[sizeof("UTF-32BE")]; + char stringpool_str639[sizeof("UCS-4BE")]; + char stringpool_str643[sizeof("CSSHIFTJIS")]; + char stringpool_str644[sizeof("MS-HEBR")]; + char stringpool_str646[sizeof("MACARABIC")]; + char stringpool_str649[sizeof("MACGREEK")]; + char stringpool_str652[sizeof("WINDOWS-874")]; + char stringpool_str658[sizeof("MS-GREEK")]; + char stringpool_str659[sizeof("BIGFIVE")]; + char stringpool_str661[sizeof("MACTURKISH")]; + char stringpool_str671[sizeof("JIS_X0201")]; + char stringpool_str673[sizeof("BIG-FIVE")]; + char stringpool_str678[sizeof("HEBREW")]; + char stringpool_str683[sizeof("JIS_X0208")]; + char stringpool_str689[sizeof("JISX0201-1976")]; + char stringpool_str695[sizeof("UCS-2-SWAPPED")]; + char stringpool_str696[sizeof("JIS_X0212-1990")]; + char stringpool_str701[sizeof("JIS_X0208-1983")]; + char stringpool_str702[sizeof("EXTENDED_UNIX_CODE_PACKED_FORMAT_FOR_JAPANESE")]; + char stringpool_str707[sizeof("SDECKANJI")]; + char stringpool_str711[sizeof("JAVA")]; + char stringpool_str725[sizeof("MS_KANJI")]; + char stringpool_str727[sizeof("MACCENTRALEUROPE")]; + char stringpool_str731[sizeof("CSISO87JISX0208")]; + char stringpool_str743[sizeof("UCS-4-SWAPPED")]; + char stringpool_str761[sizeof("MACROMANIA")]; + char stringpool_str765[sizeof("JIS_X0212.1990-0")]; + char stringpool_str768[sizeof("JIS_X0208-1990")]; + char stringpool_str780[sizeof("ISO_8859-7:1987")]; + char stringpool_str783[sizeof("TCVN5712-1:1993")]; + char stringpool_str806[sizeof("MS-ARAB")]; + char stringpool_str807[sizeof("JOHAB")]; + char stringpool_str816[sizeof("CSEUCPKDFMTJAPANESE")]; + char stringpool_str821[sizeof("MACUKRAINE")]; + char stringpool_str824[sizeof("BIG5-HKSCS:2001")]; + char stringpool_str843[sizeof("BIG5-HKSCS:1999")]; + char stringpool_str857[sizeof("WINBALTRIM")]; + char stringpool_str875[sizeof("BIG5-HKSCS:2004")]; + char stringpool_str939[sizeof("MACHEBREW")]; + }; +static const struct stringpool_t stringpool_contents = + { + "L1", + "L6", + "L3", + "L2", + "L5", + "L8", + "866", + "CN", + "862", + "CP1131", + "CP1361", + "CP866", + "CP1133", + "CP1251", + "CP862", + "CP1256", + "CP1253", + "CP1252", + "CP1255", + "CP936", + "CP1258", + "GB2312", + "CP932", + "C99", + "HZ", + "L4", + "LATIN1", + "CP819", + "LATIN6", + "LATIN3", + "LATIN2", + "LATIN5", + "LATIN8", + "R8", + "ISO8859-1", + "ISO8859-6", + "ISO8859-3", + "ISO8859-11", + "ISO8859-2", + "ISO8859-16", + "ISO8859-5", + "ISO8859-13", + "ISO8859-8", + "ISO8859-15", + "ISO-8859-1", + "ISO-8859-6", + "ISO-8859-3", + "ISO-8859-11", + "ISO-8859-2", + "ISO-8859-16", + "ISO-8859-5", + "ISO-8859-13", + "ISO-8859-8", + "ISO-8859-15", + "ISO_8859-1", + "CYRILLIC", + "ISO_8859-6", + "LATIN-9", + "ISO_8859-3", + "ISO_8859-11", + "ISO_8859-2", + "ISO_8859-16", + "ISO_8859-5", + "ISO_8859-13", + "ISO8859-9", + "ISO_8859-16:2001", + "ISO_8859-8", + "ISO_8859-15", + "CP154", + "ISO-IR-6", + "CP949", + "ISO646-CN", + "ASCII", + "ISO_8859-15:1998", + "CP1254", + "ISO-8859-9", + "ISO-IR-166", + "ISO-IR-126", + "ISO-IR-226", + "ISO-IR-165", + "X0212", + "ISO-IR-58", + "UHC", + "EUCCN", + "ISO-IR-138", + "ISO_8859-9", + "L10", + "SJIS", + "850", + "MAC", + "TACTIS", + "L7", + "EUC-CN", + "LATIN4", + "CP850", + "CP1250", + "KOI8-T", + "ISO-2022-CN", + "ISO-IR-159", + "ISO-CELTIC", + "ISO_8859-14:1998", + "IBM866", + "CP950", + "IBM862", + "ISO-2022-CN-EXT", + "ISO8859-4", + "CSASCII", + "US", + "MS936", + "ISO8859-14", + "ISO-IR-199", + "BIG5", + "ISO_8859-10:1992", + "KSC5601", + "PT154", + "ISO-IR-148", + "ISO-8859-4", + "GBK", + "CSISO2022CN", + "CSBIG5", + "ISO-IR-101", + "ISO-8859-14", + "LATIN10", + "BIG-5", + "X0201", + "ISO-IR-203", + "DECHANZI", + "ELOT_928", + "ISO_8859-4", + "IBM819", + "CSGB2312", + "CN-BIG5", + "UCS-2", + "ISO_8859-14", + "X0208", + "KSC_5601", + "ISO-IR-149", + "ISO8859-10", + "RK1048", + "ISO-IR-14", + "TCVN", + "TIS620", + "GB_2312-80", + "VISCII", + "ISO-8859-10", + "ISO-IR-109", + "CSISOLATIN1", + "CSISOLATIN6", + "TIS-620", + "CSISOLATIN3", + "CSVISCII", + "CSISOLATIN2", + "CSISOLATINCYRILLIC", + "CSISOLATIN5", + "GB18030", + "ISO_8859-10", + "UTF-16", + "CSKZ1048", + "GB_1988-80", + "KZ-1048", + "UTF-8", + "UTF-32", + "MS-CYRL", + "CHAR", + "CSKOI8R", + "ISO-IR-110", + "KOI8-R", + "MACCYRILLIC", + "IBM-CP1133", + "PTCP154", + "TIS620.2533-1", + "CP874", + "ISO-IR-144", + "KS_C_5601-1989", + "HZ-GB-2312", + "TIS620.2529-1", + "CSUNICODE11", + "UNICODE-1-1", + "CSPTCP154", + "CSUCS4", + "CYRILLIC-ASIAN", + "UCS-4", + "IBM850", + "TIS620-0", + "ISO-IR-179", + "CP367", + "ISO646-US", + "ISO-10646-UCS-2", + "CP1257", + "GREEK8", + "US-ASCII", + "ISO-IR-100", + "CSISOLATIN4", + "TIS620.2533-0", + "CSISOLATINGREEK", + "VISCII1.1-1", + "CSIBM866", + "CSISO58GB231280", + "EUCKR", + "MS-ANSI", + "MACTHAI", + "CN-GB", + "CSISOLATINARABIC", + "CN-GB-ISOIR165", + "ARMSCII-8", + "MACINTOSH", + "LATIN7", + "EUC-KR", + "JP", + "ROMAN8", + "ISO-2022-KR", + "ISO-10646-UCS-4", + "ISO8859-7", + "CHINESE", + "GEORGIAN-ACADEMY", + "CSUNICODE", + "WINDOWS-1251", + "WINDOWS-1256", + "WINDOWS-1253", + "WINDOWS-1252", + "WINDOWS-1255", + "WINDOWS-1258", + "ISO-8859-7", + "KOI8-U", + "CSPC862LATINHEBREW", + "EUCTW", + "ARABIC", + "CSISO2022KR", + "WINDOWS-936", + "GREEK", + "MULELAO-1", + "ECMA-118", + "TCVN-5712", + "ISO_8859-7", + "TCVN5712-1", + "EUC-TW", + "MACICELAND", + "KS_C_5601-1987", + "KOREAN", + "UCS-2LE", + "CSISOLATINHEBREW", + "CSKSC56011987", + "UNICODELITTLE", + "GEORGIAN-PS", + "ISO-IR-57", + "ISO-IR-87", + "JIS_C6226-1983", + "ISO-IR-127", + "ISO-IR-157", + "DECKOREAN", + "WINDOWS-1254", + "ISO_646.IRV:1991", + "CSISO57GB1988", + "HP-ROMAN8", + "CSUNICODE11UTF7", + "WCHAR_T", + "UNICODEBIG", + "WINDOWS-1250", + "UNICODE-1-1-UTF-7", + "UCS-2-INTERNAL", + "UTF-16LE", + "STRK1048-2002", + "UTF-32LE", + "MS-EE", + "UCS-4LE", + "IBM367", + "ISO_8859-3:1988", + "ISO_8859-5:1988", + "KOI8-RU", + "ISO_8859-8:1988", + "CSMACINTOSH", + "ANSI_X3.4-1986", + "BIG5HKSCS", + "ANSI_X3.4-1968", + "NEXTSTEP", + "CSISO14JISC6220RO", + "CSEUCKR", + "ECMA-114", + "BIG5-HKSCS", + "ISO_8859-9:1989", + "JIS_C6220-1969-RO", + "UCS-4-INTERNAL", + "CSPC850MULTILINGUAL", + "ISO-2022-JP-1", + "CSHPROMAN8", + "ISO-2022-JP-2", + "ISO_8859-4:1988", + "JIS0208", + "ASMO-708", + "MACROMAN", + "MACCROATIAN", + "CSISO159JISX02121990", + "ISO646-JP", + "WINDOWS-1257", + "CSISO2022JP2", + "CSEUCTW", + "UTF-7", + "EUCJP", + "EUC-JP", + "UCS-2BE", + "ISO-2022-JP", + "SHIFT-JIS", + "MS-TURK", + "JIS_X0212", + "SHIFT_JIS", + "CSISO2022JP", + "CSHALFWIDTHKATAKANA", + "ISO_8859-1:1987", + "ISO_8859-6:1987", + "ISO_8859-7:2003", + "ISO_8859-2:1987", + "UTF-16BE", + "UTF-32BE", + "UCS-4BE", + "CSSHIFTJIS", + "MS-HEBR", + "MACARABIC", + "MACGREEK", + "WINDOWS-874", + "MS-GREEK", + "BIGFIVE", + "MACTURKISH", + "JIS_X0201", + "BIG-FIVE", + "HEBREW", + "JIS_X0208", + "JISX0201-1976", + "UCS-2-SWAPPED", + "JIS_X0212-1990", + "JIS_X0208-1983", + "EXTENDED_UNIX_CODE_PACKED_FORMAT_FOR_JAPANESE", + "SDECKANJI", + "JAVA", + "MS_KANJI", + "MACCENTRALEUROPE", + "CSISO87JISX0208", + "UCS-4-SWAPPED", + "MACROMANIA", + "JIS_X0212.1990-0", + "JIS_X0208-1990", + "ISO_8859-7:1987", + "TCVN5712-1:1993", + "MS-ARAB", + "JOHAB", + "CSEUCPKDFMTJAPANESE", + "MACUKRAINE", + "BIG5-HKSCS:2001", + "BIG5-HKSCS:1999", + "WINBALTRIM", + "BIG5-HKSCS:2004", + "MACHEBREW" + }; +#define stringpool ((const char *) &stringpool_contents) + +static const struct alias aliases[] = + { + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, +#line 60 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str13, ei_iso8859_1}, +#line 134 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str14, ei_iso8859_10}, +#line 76 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str15, ei_iso8859_3}, +#line 68 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str16, ei_iso8859_2}, +#line 126 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str17, ei_iso8859_9}, + {-1}, +#line 151 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str19, ei_iso8859_14}, + {-1}, {-1}, {-1}, +#line 207 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str23, ei_cp866}, +#line 289 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str24, ei_iso646_cn}, + {-1}, {-1}, +#line 203 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str27, ei_cp862}, + {-1}, {-1}, {-1}, {-1}, +#line 209 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str32, ei_cp1131}, +#line 358 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str33, ei_johab}, +#line 205 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str34, ei_cp866}, + {-1}, +#line 244 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str36, ei_cp1133}, +#line 174 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str37, ei_cp1251}, +#line 201 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str38, ei_cp862}, +#line 189 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str39, ei_cp1256}, + {-1}, +#line 180 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str41, ei_cp1253}, + {-1}, +#line 177 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str43, ei_cp1252}, + {-1}, +#line 186 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str45, ei_cp1255}, + {-1}, {-1}, +#line 326 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str48, ei_cp936}, +#line 195 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str49, ei_cp1258}, +#line 321 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str50, ei_euc_cn}, + {-1}, +#line 313 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str52, ei_cp932}, +#line 51 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str53, ei_c99}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 333 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str60, ei_hz}, + {-1}, {-1}, {-1}, +#line 84 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str64, ei_iso8859_4}, + {-1}, {-1}, {-1}, +#line 59 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str68, ei_iso8859_1}, +#line 57 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str69, ei_iso8859_1}, +#line 133 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str70, ei_iso8859_10}, + {-1}, +#line 75 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str72, ei_iso8859_3}, + {-1}, +#line 67 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str74, ei_iso8859_2}, + {-1}, +#line 125 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str76, ei_iso8859_9}, + {-1}, {-1}, {-1}, +#line 150 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str80, ei_iso8859_14}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 227 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str88, ei_hp_roman8}, +#line 62 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str89, ei_iso8859_1}, + {-1}, +#line 102 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str91, ei_iso8859_6}, + {-1}, +#line 78 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str93, ei_iso8859_3}, +#line 139 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str94, ei_iso8859_11}, +#line 70 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str95, ei_iso8859_2}, +#line 166 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str96, ei_iso8859_16}, +#line 93 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str97, ei_iso8859_5}, +#line 145 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str98, ei_iso8859_13}, + {-1}, {-1}, +#line 120 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str101, ei_iso8859_8}, +#line 159 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str102, ei_iso8859_15}, +#line 53 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str103, ei_iso8859_1}, + {-1}, +#line 94 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str105, ei_iso8859_6}, + {-1}, +#line 71 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str107, ei_iso8859_3}, +#line 137 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str108, ei_iso8859_11}, +#line 63 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str109, ei_iso8859_2}, +#line 160 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str110, ei_iso8859_16}, +#line 87 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str111, ei_iso8859_5}, +#line 140 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str112, ei_iso8859_13}, + {-1}, {-1}, +#line 114 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str115, ei_iso8859_8}, +#line 154 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str116, ei_iso8859_15}, +#line 54 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str117, ei_iso8859_1}, +#line 91 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str118, ei_iso8859_5}, +#line 95 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str119, ei_iso8859_6}, +#line 158 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str120, ei_iso8859_15}, +#line 72 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str121, ei_iso8859_3}, +#line 138 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str122, ei_iso8859_11}, +#line 64 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str123, ei_iso8859_2}, +#line 161 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str124, ei_iso8859_16}, +#line 88 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str125, ei_iso8859_5}, +#line 141 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str126, ei_iso8859_13}, +#line 128 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str127, ei_iso8859_9}, +#line 162 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str128, ei_iso8859_16}, +#line 115 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str129, ei_iso8859_8}, +#line 155 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str130, ei_iso8859_15}, +#line 236 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str131, ei_pt154}, +#line 16 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str132, ei_ascii}, +#line 354 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str133, ei_cp949}, + {-1}, +#line 287 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str135, ei_iso646_cn}, +#line 13 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str136, ei_ascii}, +#line 156 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str137, ei_iso8859_15}, + {-1}, +#line 183 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str139, ei_cp1254}, + {-1}, +#line 121 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str141, ei_iso8859_9}, + {-1}, +#line 252 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str143, ei_tis620}, + {-1}, +#line 107 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str145, ei_iso8859_7}, + {-1}, {-1}, +#line 163 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str148, ei_iso8859_16}, +#line 295 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str149, ei_isoir165}, +#line 283 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str150, ei_jisx0212}, +#line 292 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str151, ei_gb2312}, +#line 355 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str152, ei_cp949}, +#line 320 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str153, ei_euc_cn}, +#line 117 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str154, ei_iso8859_8}, +#line 122 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str155, ei_iso8859_9}, +#line 165 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str156, ei_iso8859_16}, + {-1}, +#line 310 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str158, ei_sjis}, +#line 199 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str159, ei_cp850}, + {-1}, +#line 212 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str161, ei_mac_roman}, + {-1}, {-1}, +#line 253 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str164, ei_tis620}, +#line 144 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str165, ei_iso8859_13}, + {-1}, +#line 319 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str167, ei_euc_cn}, + {-1}, {-1}, +#line 83 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str170, ei_iso8859_4}, + {-1}, {-1}, +#line 197 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str173, ei_cp850}, + {-1}, +#line 171 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str175, ei_cp1250}, + {-1}, {-1}, +#line 233 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str178, ei_koi8_t}, +#line 330 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str179, ei_iso2022_cn}, + {-1}, {-1}, +#line 284 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str182, ei_jisx0212}, +#line 152 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str183, ei_iso8859_14}, +#line 148 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str184, ei_iso8859_14}, +#line 206 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str185, ei_cp866}, +#line 344 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str186, ei_cp950}, + {-1}, {-1}, +#line 202 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str189, ei_cp862}, +#line 332 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str190, ei_iso2022_cn_ext}, +#line 86 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str191, ei_iso8859_4}, +#line 22 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str192, ei_ascii}, +#line 21 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str193, ei_ascii}, +#line 327 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str194, ei_cp936}, + {-1}, +#line 153 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str196, ei_iso8859_14}, +#line 149 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str197, ei_iso8859_14}, +#line 338 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str198, ei_ces_big5}, +#line 131 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str199, ei_iso8859_10}, +#line 356 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str200, ei_cp949}, + {-1}, +#line 234 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str202, ei_pt154}, +#line 124 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str203, ei_iso8859_9}, + {-1}, +#line 79 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str205, ei_iso8859_4}, +#line 325 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str206, ei_ces_gbk}, +#line 331 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str207, ei_iso2022_cn}, +#line 343 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str208, ei_ces_big5}, +#line 66 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str209, ei_iso8859_2}, +#line 146 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str210, ei_iso8859_14}, +#line 164 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str211, ei_iso8859_16}, +#line 339 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str212, ei_ces_big5}, +#line 270 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str213, ei_jisx0201}, + {-1}, {-1}, +#line 157 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str216, ei_iso8859_15}, +#line 324 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str217, ei_euc_cn}, +#line 109 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str218, ei_iso8859_7}, +#line 80 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str219, ei_iso8859_4}, +#line 58 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str220, ei_iso8859_1}, +#line 323 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str221, ei_euc_cn}, +#line 342 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str222, ei_ces_big5}, +#line 24 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str223, ei_ucs2}, +#line 147 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str224, ei_iso8859_14}, +#line 276 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str225, ei_jisx0208}, + {-1}, {-1}, +#line 297 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str228, ei_ksc5601}, +#line 300 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str229, ei_ksc5601}, + {-1}, {-1}, +#line 136 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str232, ei_iso8859_10}, + {-1}, +#line 239 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str234, ei_rk1048}, + {-1}, {-1}, +#line 265 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str237, ei_iso646_jp}, +#line 259 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str238, ei_tcvn}, +#line 247 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str239, ei_tis620}, + {-1}, {-1}, {-1}, +#line 291 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str243, ei_gb2312}, + {-1}, +#line 256 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str245, ei_viscii}, +#line 129 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str246, ei_iso8859_10}, +#line 74 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str247, ei_iso8859_3}, + {-1}, {-1}, +#line 61 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str250, ei_iso8859_1}, + {-1}, +#line 135 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str252, ei_iso8859_10}, +#line 246 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str253, ei_tis620}, +#line 77 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str254, ei_iso8859_3}, +#line 258 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str255, ei_viscii}, +#line 69 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str256, ei_iso8859_2}, +#line 92 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str257, ei_iso8859_5}, +#line 127 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str258, ei_iso8859_9}, +#line 329 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str259, ei_gb18030}, +#line 130 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str260, ei_iso8859_10}, + {-1}, {-1}, +#line 38 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str263, ei_utf16}, +#line 242 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str264, ei_rk1048}, + {-1}, +#line 286 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str266, ei_iso646_cn}, +#line 241 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str267, ei_rk1048}, +#line 23 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str268, ei_utf8}, +#line 41 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str269, ei_utf32}, +#line 176 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str270, ei_cp1251}, + {-1}, {-1}, {-1}, {-1}, +#line 361 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str275, ei_local_char}, +#line 168 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str276, ei_koi8_r}, + {-1}, +#line 82 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str278, ei_iso8859_4}, + {-1}, +#line 167 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str280, ei_koi8_r}, +#line 218 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str281, ei_mac_cyrillic}, +#line 245 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str282, ei_cp1133}, +#line 235 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str283, ei_pt154}, +#line 251 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str284, ei_tis620}, +#line 254 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str285, ei_cp874}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 90 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str293, ei_iso8859_5}, + {-1}, {-1}, {-1}, +#line 299 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str297, ei_ksc5601}, +#line 334 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str298, ei_hz}, + {-1}, {-1}, {-1}, +#line 249 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str302, ei_tis620}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 30 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str308, ei_ucs2be}, + {-1}, {-1}, {-1}, +#line 29 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str312, ei_ucs2be}, + {-1}, +#line 238 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str314, ei_pt154}, +#line 35 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str315, ei_ucs4}, +#line 237 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str316, ei_pt154}, + {-1}, {-1}, +#line 33 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str319, ei_ucs4}, + {-1}, {-1}, {-1}, {-1}, +#line 198 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str324, ei_cp850}, + {-1}, {-1}, +#line 248 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str327, ei_tis620}, + {-1}, {-1}, +#line 142 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str330, ei_iso8859_13}, + {-1}, +#line 19 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str332, ei_ascii}, + {-1}, {-1}, {-1}, +#line 14 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str336, ei_ascii}, + {-1}, {-1}, +#line 25 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str339, ei_ucs2}, + {-1}, +#line 192 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str341, ei_cp1257}, +#line 110 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str342, ei_iso8859_7}, +#line 12 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str343, ei_ascii}, + {-1}, {-1}, {-1}, +#line 56 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str347, ei_iso8859_1}, + {-1}, {-1}, {-1}, {-1}, +#line 85 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str352, ei_iso8859_4}, +#line 250 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str353, ei_tis620}, +#line 112 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str354, ei_iso8859_7}, +#line 257 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str355, ei_viscii}, +#line 208 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str356, ei_cp866}, + {-1}, {-1}, +#line 293 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str359, ei_gb2312}, +#line 351 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str360, ei_euc_kr}, +#line 179 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str361, ei_cp1252}, +#line 224 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str362, ei_mac_thai}, + {-1}, {-1}, +#line 322 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str365, ei_euc_cn}, +#line 101 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str366, ei_iso8859_6}, + {-1}, +#line 296 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str368, ei_isoir165}, +#line 230 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str369, ei_armscii_8}, +#line 211 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str370, ei_mac_roman}, + {-1}, +#line 143 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str372, ei_iso8859_13}, + {-1}, +#line 350 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str374, ei_euc_kr}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 266 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str381, ei_iso646_jp}, + {-1}, {-1}, {-1}, +#line 226 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str385, ei_hp_roman8}, +#line 359 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str386, ei_iso2022_kr}, +#line 34 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str387, ei_ucs4}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 113 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str393, ei_iso8859_7}, + {-1}, +#line 294 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str395, ei_gb2312}, + {-1}, +#line 231 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str397, ei_georgian_academy}, +#line 26 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str398, ei_ucs2}, + {-1}, +#line 175 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str400, ei_cp1251}, +#line 190 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str401, ei_cp1256}, +#line 181 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str402, ei_cp1253}, +#line 178 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str403, ei_cp1252}, +#line 187 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str404, ei_cp1255}, + {-1}, +#line 196 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str406, ei_cp1258}, +#line 103 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str407, ei_iso8859_7}, + {-1}, {-1}, +#line 169 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str410, ei_koi8_u}, +#line 204 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str411, ei_cp862}, +#line 336 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str412, ei_euc_tw}, +#line 100 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str413, ei_iso8859_6}, +#line 360 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str414, ei_iso2022_kr}, +#line 328 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str415, ei_cp936}, +#line 111 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str416, ei_iso8859_7}, +#line 243 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str417, ei_mulelao}, +#line 108 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str418, ei_iso8859_7}, + {-1}, +#line 260 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str420, ei_tcvn}, +#line 104 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str421, ei_iso8859_7}, +#line 261 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str422, ei_tcvn}, + {-1}, {-1}, {-1}, +#line 335 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str426, ei_euc_tw}, + {-1}, +#line 215 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str428, ei_mac_iceland}, + {-1}, +#line 298 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str430, ei_ksc5601}, + {-1}, +#line 302 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str432, ei_ksc5601}, +#line 31 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str433, ei_ucs2le}, + {-1}, {-1}, {-1}, +#line 119 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str437, ei_iso8859_8}, + {-1}, +#line 301 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str439, ei_ksc5601}, + {-1}, +#line 32 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str441, ei_ucs2le}, +#line 232 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str442, ei_georgian_ps}, +#line 288 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str443, ei_iso646_cn}, + {-1}, +#line 277 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str445, ei_jisx0208}, +#line 278 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str446, ei_jisx0208}, +#line 97 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str447, ei_iso8859_6}, +#line 132 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str448, ei_iso8859_10}, +#line 353 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str449, ei_euc_kr}, + {-1}, +#line 184 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str451, ei_cp1254}, + {-1}, +#line 15 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str453, ei_ascii}, +#line 290 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str454, ei_iso646_cn}, + {-1}, {-1}, {-1}, +#line 225 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str458, ei_hp_roman8}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 46 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str464, ei_utf7}, +#line 362 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str465, ei_local_wchar_t}, + {-1}, {-1}, +#line 28 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str468, ei_ucs2be}, +#line 172 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str469, ei_cp1250}, +#line 45 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str470, ei_utf7}, + {-1}, +#line 47 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str472, ei_ucs2internal}, + {-1}, {-1}, +#line 40 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str475, ei_utf16le}, +#line 240 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str476, ei_rk1048}, + {-1}, {-1}, +#line 43 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str479, ei_utf32le}, +#line 173 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str480, ei_cp1250}, +#line 37 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str481, ei_ucs4le}, + {-1}, +#line 20 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str483, ei_ascii}, +#line 73 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str484, ei_iso8859_3}, + {-1}, +#line 89 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str486, ei_iso8859_5}, +#line 170 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str487, ei_koi8_ru}, +#line 116 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str488, ei_iso8859_8}, + {-1}, {-1}, +#line 213 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str491, ei_mac_roman}, + {-1}, +#line 18 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str493, ei_ascii}, + {-1}, {-1}, {-1}, +#line 348 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str497, ei_big5hkscs2004}, +#line 17 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str498, ei_ascii}, + {-1}, +#line 229 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str500, ei_nextstep}, + {-1}, {-1}, {-1}, +#line 267 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str504, ei_iso646_jp}, + {-1}, {-1}, +#line 352 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str507, ei_euc_kr}, +#line 98 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str508, ei_iso8859_6}, + {-1}, {-1}, +#line 347 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str511, ei_big5hkscs2004}, + {-1}, {-1}, +#line 123 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str514, ei_iso8859_9}, +#line 263 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str515, ei_iso646_jp}, + {-1}, {-1}, {-1}, {-1}, +#line 49 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str520, ei_ucs4internal}, + {-1}, {-1}, +#line 200 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str523, ei_cp850}, +#line 316 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str524, ei_iso2022_jp1}, +#line 228 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str525, ei_hp_roman8}, + {-1}, +#line 317 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str527, ei_iso2022_jp2}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 81 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str533, ei_iso8859_4}, +#line 275 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str534, ei_jisx0208}, + {-1}, {-1}, {-1}, {-1}, +#line 99 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str539, ei_iso8859_6}, + {-1}, {-1}, {-1}, +#line 210 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str543, ei_mac_roman}, +#line 216 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str544, ei_mac_croatian}, + {-1}, {-1}, {-1}, +#line 285 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str548, ei_jisx0212}, +#line 264 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str549, ei_iso646_jp}, + {-1}, {-1}, +#line 193 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str552, ei_cp1257}, + {-1}, +#line 318 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str554, ei_iso2022_jp2}, + {-1}, {-1}, {-1}, {-1}, +#line 337 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str559, ei_euc_tw}, +#line 44 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str560, ei_utf7}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 304 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str567, ei_euc_jp}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, +#line 303 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str581, ei_euc_jp}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 27 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str591, ei_ucs2be}, + {-1}, +#line 314 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str593, ei_iso2022_jp}, + {-1}, {-1}, {-1}, {-1}, +#line 309 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str598, ei_sjis}, + {-1}, {-1}, {-1}, +#line 185 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str602, ei_cp1254}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 280 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str608, ei_jisx0212}, + {-1}, {-1}, {-1}, +#line 308 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str612, ei_sjis}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 315 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str621, ei_iso2022_jp}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 271 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str627, ei_jisx0201}, +#line 55 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str628, ei_iso8859_1}, +#line 96 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str629, ei_iso8859_6}, +#line 106 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str630, ei_iso8859_7}, +#line 65 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str631, ei_iso8859_2}, + {-1}, +#line 39 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str633, ei_utf16be}, + {-1}, {-1}, {-1}, +#line 42 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str637, ei_utf32be}, + {-1}, +#line 36 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str639, ei_ucs4be}, + {-1}, {-1}, {-1}, +#line 312 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str643, ei_sjis}, +#line 188 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str644, ei_cp1255}, + {-1}, +#line 223 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str646, ei_mac_arabic}, + {-1}, {-1}, +#line 220 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str649, ei_mac_greek}, + {-1}, {-1}, +#line 255 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str652, ei_cp874}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 182 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str658, ei_cp1253}, +#line 341 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str659, ei_ces_big5}, + {-1}, +#line 221 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str661, ei_mac_turkish}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 268 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str671, ei_jisx0201}, + {-1}, +#line 340 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str673, ei_ces_big5}, + {-1}, {-1}, {-1}, {-1}, +#line 118 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str678, ei_iso8859_8}, + {-1}, {-1}, {-1}, {-1}, +#line 272 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str683, ei_jisx0208}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 269 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str689, ei_jisx0201}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 48 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str695, ei_ucs2swapped}, +#line 282 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str696, ei_jisx0212}, + {-1}, {-1}, {-1}, {-1}, +#line 273 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str701, ei_jisx0208}, +#line 305 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str702, ei_euc_jp}, + {-1}, {-1}, {-1}, {-1}, +#line 307 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str707, ei_euc_jp}, + {-1}, {-1}, {-1}, +#line 52 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str711, ei_java}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, +#line 311 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str725, ei_sjis}, + {-1}, +#line 214 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str727, ei_mac_centraleurope}, + {-1}, {-1}, {-1}, +#line 279 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str731, ei_jisx0208}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, +#line 50 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str743, ei_ucs4swapped}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 217 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str761, ei_mac_romania}, + {-1}, {-1}, {-1}, +#line 281 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str765, ei_jisx0212}, + {-1}, {-1}, +#line 274 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str768, ei_jisx0208}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, +#line 105 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str780, ei_iso8859_7}, + {-1}, {-1}, +#line 262 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str783, ei_tcvn}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, +#line 191 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str806, ei_cp1256}, +#line 357 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str807, ei_johab}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 306 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str816, ei_euc_jp}, + {-1}, {-1}, {-1}, {-1}, +#line 219 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str821, ei_mac_ukraine}, + {-1}, {-1}, +#line 346 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str824, ei_big5hkscs2001}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 345 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str843, ei_big5hkscs1999}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, +#line 194 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str857, ei_cp1257}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 349 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str875, ei_big5hkscs2004}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 222 "lib/aliases_sysosf1.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str939, ei_mac_hebrew} + }; + +#ifdef __GNUC__ +__inline +#if defined __GNUC_STDC_INLINE__ || defined __GNUC_GNU_INLINE__ +__attribute__ ((__gnu_inline__)) +#endif +#endif +const struct alias * +aliases_lookup (register const char *str, register unsigned int len) +{ + if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) + { + register int key = aliases_hash (str, len); + + if (key <= MAX_HASH_VALUE && key >= 0) + { + register int o = aliases[key].name; + if (o >= 0) + { + register const char *s = o + stringpool; + + if (*str == *s && !strcmp (str + 1, s + 1)) + return &aliases[key]; + } + } + } + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/aliases_syssolaris.h b/graf2d/win32gdk/gdk/src/iconv/aliases_syssolaris.h new file mode 100644 index 0000000000000..286bdbfa50141 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/aliases_syssolaris.h @@ -0,0 +1,1753 @@ +/* ANSI-C code produced by gperf version 3.0.4 */ +/* Command-line: gperf -m 10 lib/aliases_syssolaris.gperf */ +/* Computed positions: -k'1,3-11,$' */ + +#if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ + && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ + && (')' == 41) && ('*' == 42) && ('+' == 43) && (',' == 44) \ + && ('-' == 45) && ('.' == 46) && ('/' == 47) && ('0' == 48) \ + && ('1' == 49) && ('2' == 50) && ('3' == 51) && ('4' == 52) \ + && ('5' == 53) && ('6' == 54) && ('7' == 55) && ('8' == 56) \ + && ('9' == 57) && (':' == 58) && (';' == 59) && ('<' == 60) \ + && ('=' == 61) && ('>' == 62) && ('?' == 63) && ('A' == 65) \ + && ('B' == 66) && ('C' == 67) && ('D' == 68) && ('E' == 69) \ + && ('F' == 70) && ('G' == 71) && ('H' == 72) && ('I' == 73) \ + && ('J' == 74) && ('K' == 75) && ('L' == 76) && ('M' == 77) \ + && ('N' == 78) && ('O' == 79) && ('P' == 80) && ('Q' == 81) \ + && ('R' == 82) && ('S' == 83) && ('T' == 84) && ('U' == 85) \ + && ('V' == 86) && ('W' == 87) && ('X' == 88) && ('Y' == 89) \ + && ('Z' == 90) && ('[' == 91) && ('\\' == 92) && (']' == 93) \ + && ('^' == 94) && ('_' == 95) && ('a' == 97) && ('b' == 98) \ + && ('c' == 99) && ('d' == 100) && ('e' == 101) && ('f' == 102) \ + && ('g' == 103) && ('h' == 104) && ('i' == 105) && ('j' == 106) \ + && ('k' == 107) && ('l' == 108) && ('m' == 109) && ('n' == 110) \ + && ('o' == 111) && ('p' == 112) && ('q' == 113) && ('r' == 114) \ + && ('s' == 115) && ('t' == 116) && ('u' == 117) && ('v' == 118) \ + && ('w' == 119) && ('x' == 120) && ('y' == 121) && ('z' == 122) \ + && ('{' == 123) && ('|' == 124) && ('}' == 125) && ('~' == 126)) +/* The character set is not based on ISO-646. */ +#error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gnu-gperf@gnu.org>." +#endif + +#line 1 "lib/aliases_syssolaris.gperf" +struct alias { int name; unsigned int encoding_index; }; + +#define TOTAL_KEYWORDS 353 +#define MIN_WORD_LENGTH 2 +#define MAX_WORD_LENGTH 45 +#define MIN_HASH_VALUE 8 +#define MAX_HASH_VALUE 1003 +/* maximum key range = 996, duplicates = 0 */ + +#ifdef __GNUC__ +__inline +#else +#ifdef __cplusplus +inline +#endif +#endif +static unsigned int +aliases_hash (register const char *str, register unsigned int len) +{ + static const unsigned short asso_values[] = + { + 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, + 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, + 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, + 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, + 1004, 1004, 1004, 1004, 1004, 2, 112, 1004, 27, 4, + 34, 57, 16, 22, 11, 168, 3, 10, 254, 1004, + 1004, 1004, 1004, 1004, 1004, 21, 126, 7, 10, 37, + 40, 119, 81, 62, 332, 197, 9, 169, 4, 2, + 8, 1004, 3, 34, 104, 205, 191, 192, 195, 36, + 16, 1004, 1004, 1004, 1004, 3, 1004, 1004, 1004, 1004, + 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, + 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004, + 1004, 1004, 1004, 1004, 1004, 1004, 1004, 1004 + }; + register int hval = len; + + switch (hval) + { + default: + hval += asso_values[(unsigned char)str[10]]; + /*FALLTHROUGH*/ + case 10: + hval += asso_values[(unsigned char)str[9]]; + /*FALLTHROUGH*/ + case 9: + hval += asso_values[(unsigned char)str[8]]; + /*FALLTHROUGH*/ + case 8: + hval += asso_values[(unsigned char)str[7]]; + /*FALLTHROUGH*/ + case 7: + hval += asso_values[(unsigned char)str[6]]; + /*FALLTHROUGH*/ + case 6: + hval += asso_values[(unsigned char)str[5]]; + /*FALLTHROUGH*/ + case 5: + hval += asso_values[(unsigned char)str[4]]; + /*FALLTHROUGH*/ + case 4: + hval += asso_values[(unsigned char)str[3]]; + /*FALLTHROUGH*/ + case 3: + hval += asso_values[(unsigned char)str[2]]; + /*FALLTHROUGH*/ + case 2: + case 1: + hval += asso_values[(unsigned char)str[0]]; + break; + } + return hval + asso_values[(unsigned char)str[len - 1]]; +} + +struct stringpool_t + { + char stringpool_str8[sizeof("R8")]; + char stringpool_str13[sizeof("CN")]; + char stringpool_str14[sizeof("L8")]; + char stringpool_str15[sizeof("L1")]; + char stringpool_str22[sizeof("L6")]; + char stringpool_str27[sizeof("L4")]; + char stringpool_str28[sizeof("866")]; + char stringpool_str30[sizeof("C99")]; + char stringpool_str33[sizeof("L5")]; + char stringpool_str36[sizeof("646")]; + char stringpool_str38[sizeof("CHAR")]; + char stringpool_str39[sizeof("CP819")]; + char stringpool_str45[sizeof("L2")]; + char stringpool_str48[sizeof("CP866")]; + char stringpool_str58[sizeof("CP949")]; + char stringpool_str60[sizeof("850")]; + char stringpool_str61[sizeof("5601")]; + char stringpool_str62[sizeof("RK1048")]; + char stringpool_str64[sizeof("EUCCN")]; + char stringpool_str66[sizeof("L10")]; + char stringpool_str67[sizeof("EUC-CN")]; + char stringpool_str68[sizeof("L3")]; + char stringpool_str70[sizeof("CP154")]; + char stringpool_str71[sizeof("PT154")]; + char stringpool_str74[sizeof("862")]; + char stringpool_str79[sizeof("CP1258")]; + char stringpool_str81[sizeof("CP1251")]; + char stringpool_str86[sizeof("CP1131")]; + char stringpool_str88[sizeof("PTCP154")]; + char stringpool_str91[sizeof("CP850")]; + char stringpool_str93[sizeof("CP1361")]; + char stringpool_str94[sizeof("CP862")]; + char stringpool_str95[sizeof("CP1256")]; + char stringpool_str98[sizeof("CP950")]; + char stringpool_str99[sizeof("HZ")]; + char stringpool_str101[sizeof("CP936")]; + char stringpool_str105[sizeof("CP1254")]; + char stringpool_str117[sizeof("CP1255")]; + char stringpool_str119[sizeof("ISO8859-8")]; + char stringpool_str121[sizeof("ISO8859-1")]; + char stringpool_str122[sizeof("ISO-8859-8")]; + char stringpool_str123[sizeof("ISO_8859-8")]; + char stringpool_str124[sizeof("ISO-8859-1")]; + char stringpool_str125[sizeof("ISO_8859-1")]; + char stringpool_str126[sizeof("ISO8859-11")]; + char stringpool_str127[sizeof("CP1250")]; + char stringpool_str128[sizeof("ISO646-CN")]; + char stringpool_str129[sizeof("ISO-8859-11")]; + char stringpool_str130[sizeof("ISO_8859-11")]; + char stringpool_str133[sizeof("ISO8859-9")]; + char stringpool_str135[sizeof("ISO8859-6")]; + char stringpool_str136[sizeof("ISO-8859-9")]; + char stringpool_str137[sizeof("ISO_8859-9")]; + char stringpool_str138[sizeof("ISO-8859-6")]; + char stringpool_str139[sizeof("ISO_8859-6")]; + char stringpool_str140[sizeof("ISO8859-16")]; + char stringpool_str141[sizeof("CP1252")]; + char stringpool_str142[sizeof("ISO_8859-16:2001")]; + char stringpool_str143[sizeof("ISO-8859-16")]; + char stringpool_str144[sizeof("ISO_8859-16")]; + char stringpool_str145[sizeof("ISO8859-4")]; + char stringpool_str146[sizeof("ISO_8859-14:1998")]; + char stringpool_str147[sizeof("CP932")]; + char stringpool_str148[sizeof("ISO-8859-4")]; + char stringpool_str149[sizeof("ISO_8859-4")]; + char stringpool_str150[sizeof("ISO8859-14")]; + char stringpool_str152[sizeof("ISO_8859-15:1998")]; + char stringpool_str153[sizeof("ISO-8859-14")]; + char stringpool_str154[sizeof("ISO_8859-14")]; + char stringpool_str157[sizeof("ISO8859-5")]; + char stringpool_str160[sizeof("ISO-8859-5")]; + char stringpool_str161[sizeof("ISO_8859-5")]; + char stringpool_str162[sizeof("ISO8859-15")]; + char stringpool_str163[sizeof("ISO-IR-6")]; + char stringpool_str165[sizeof("ISO-8859-15")]; + char stringpool_str166[sizeof("ISO_8859-15")]; + char stringpool_str168[sizeof("SJIS")]; + char stringpool_str169[sizeof("ISO-IR-148")]; + char stringpool_str170[sizeof("ISO-IR-58")]; + char stringpool_str172[sizeof("ISO8859-10")]; + char stringpool_str174[sizeof("CYRILLIC")]; + char stringpool_str175[sizeof("ISO-8859-10")]; + char stringpool_str176[sizeof("ISO_8859-10")]; + char stringpool_str177[sizeof("ISO-IR-199")]; + char stringpool_str178[sizeof("ISO-IR-14")]; + char stringpool_str179[sizeof("L7")]; + char stringpool_str180[sizeof("ISO-IR-166")]; + char stringpool_str181[sizeof("ISO8859-2")]; + char stringpool_str182[sizeof("ISO-IR-101")]; + char stringpool_str183[sizeof("ISO-IR-149")]; + char stringpool_str184[sizeof("ISO-8859-2")]; + char stringpool_str185[sizeof("ISO_8859-2")]; + char stringpool_str186[sizeof("MAC")]; + char stringpool_str187[sizeof("CP1253")]; + char stringpool_str188[sizeof("ISO_8859-10:1992")]; + char stringpool_str189[sizeof("ISO-IR-159")]; + char stringpool_str191[sizeof("LATIN8")]; + char stringpool_str192[sizeof("CP1133")]; + char stringpool_str193[sizeof("LATIN1")]; + char stringpool_str194[sizeof("ISO-IR-109")]; + char stringpool_str195[sizeof("ISO-IR-144")]; + char stringpool_str196[sizeof("ANSI-1251")]; + char stringpool_str198[sizeof("CNS11643")]; + char stringpool_str201[sizeof("CSPTCP154")]; + char stringpool_str202[sizeof("ISO-IR-165")]; + char stringpool_str203[sizeof("ISO-IR-126")]; + char stringpool_str204[sizeof("ELOT_928")]; + char stringpool_str205[sizeof("ISO-IR-110")]; + char stringpool_str207[sizeof("LATIN6")]; + char stringpool_str208[sizeof("LATIN-9")]; + char stringpool_str209[sizeof("ROMAN8")]; + char stringpool_str210[sizeof("ISO-IR-138")]; + char stringpool_str211[sizeof("GB_1988-80")]; + char stringpool_str215[sizeof("CP874")]; + char stringpool_str217[sizeof("LATIN4")]; + char stringpool_str219[sizeof("ASCII")]; + char stringpool_str222[sizeof("UHC")]; + char stringpool_str223[sizeof("ISO-2022-CN")]; + char stringpool_str225[sizeof("CHINESE")]; + char stringpool_str227[sizeof("ISO8859-3")]; + char stringpool_str228[sizeof("ISO-IR-100")]; + char stringpool_str229[sizeof("LATIN5")]; + char stringpool_str230[sizeof("ISO-8859-3")]; + char stringpool_str231[sizeof("ISO_8859-3")]; + char stringpool_str232[sizeof("ISO8859-13")]; + char stringpool_str233[sizeof("ISO-IR-226")]; + char stringpool_str234[sizeof("CYRILLIC-ASIAN")]; + char stringpool_str235[sizeof("ISO-8859-13")]; + char stringpool_str236[sizeof("ISO_8859-13")]; + char stringpool_str241[sizeof("US")]; + char stringpool_str242[sizeof("MS-CYRL")]; + char stringpool_str243[sizeof("TIS620")]; + char stringpool_str244[sizeof("LATIN10")]; + char stringpool_str246[sizeof("TIS-620")]; + char stringpool_str250[sizeof("ARABIC")]; + char stringpool_str251[sizeof("ECMA-118")]; + char stringpool_str252[sizeof("EUCKR")]; + char stringpool_str253[sizeof("LATIN2")]; + char stringpool_str255[sizeof("EUC-KR")]; + char stringpool_str258[sizeof("UTF-8")]; + char stringpool_str259[sizeof("KZ-1048")]; + char stringpool_str260[sizeof("CSISO2022CN")]; + char stringpool_str262[sizeof("CSASCII")]; + char stringpool_str263[sizeof("MS936")]; + char stringpool_str264[sizeof("IBM819")]; + char stringpool_str266[sizeof("MULELAO-1")]; + char stringpool_str267[sizeof("X0208")]; + char stringpool_str269[sizeof("X0201")]; + char stringpool_str271[sizeof("GB18030")]; + char stringpool_str272[sizeof("KOREAN")]; + char stringpool_str273[sizeof("IBM866")]; + char stringpool_str274[sizeof("TIS620-0")]; + char stringpool_str276[sizeof("KOI8-R")]; + char stringpool_str277[sizeof("ECMA-114")]; + char stringpool_str278[sizeof("UCS-4")]; + char stringpool_str279[sizeof("UTF-16")]; + char stringpool_str281[sizeof("CSKZ1048")]; + char stringpool_str283[sizeof("KSC_5601")]; + char stringpool_str284[sizeof("CSKOI8R")]; + char stringpool_str287[sizeof("MS-EE")]; + char stringpool_str288[sizeof("GB2312")]; + char stringpool_str291[sizeof("CSUCS4")]; + char stringpool_str293[sizeof("BIG5")]; + char stringpool_str296[sizeof("BIG-5")]; + char stringpool_str297[sizeof("HP-ROMAN8")]; + char stringpool_str299[sizeof("LATIN3")]; + char stringpool_str304[sizeof("KS_C_5601-1989")]; + char stringpool_str306[sizeof("X0212")]; + char stringpool_str307[sizeof("TCVN")]; + char stringpool_str309[sizeof("ISO-CELTIC")]; + char stringpool_str311[sizeof("CSHPROMAN8")]; + char stringpool_str314[sizeof("UCS-2")]; + char stringpool_str316[sizeof("IBM850")]; + char stringpool_str318[sizeof("ISO-IR-203")]; + char stringpool_str319[sizeof("IBM862")]; + char stringpool_str320[sizeof("GB_2312-80")]; + char stringpool_str324[sizeof("CSISOLATIN1")]; + char stringpool_str327[sizeof("ISO-2022-CN-EXT")]; + char stringpool_str335[sizeof("ISO-IR-179")]; + char stringpool_str337[sizeof("CSISOLATINCYRILLIC")]; + char stringpool_str338[sizeof("CSISOLATIN6")]; + char stringpool_str342[sizeof("JP")]; + char stringpool_str346[sizeof("MACICELAND")]; + char stringpool_str347[sizeof("UCS-4LE")]; + char stringpool_str348[sizeof("CSISOLATIN4")]; + char stringpool_str349[sizeof("CSISOLATINARABIC")]; + char stringpool_str350[sizeof("UNICODE-1-1")]; + char stringpool_str353[sizeof("UTF-16LE")]; + char stringpool_str357[sizeof("CSUNICODE11")]; + char stringpool_str360[sizeof("CSISOLATIN5")]; + char stringpool_str361[sizeof("MS-ANSI")]; + char stringpool_str364[sizeof("CSBIG5")]; + char stringpool_str365[sizeof("UCS-2LE")]; + char stringpool_str367[sizeof("CN-BIG5")]; + char stringpool_str372[sizeof("ARMSCII-8")]; + char stringpool_str373[sizeof("ISO-10646-UCS-4")]; + char stringpool_str378[sizeof("UTF-32")]; + char stringpool_str380[sizeof("CSUNICODE")]; + char stringpool_str382[sizeof("ISO_8859-8:1988")]; + char stringpool_str384[sizeof("CSISOLATIN2")]; + char stringpool_str385[sizeof("CN-GB")]; + char stringpool_str386[sizeof("ISO646-US")]; + char stringpool_str387[sizeof("MACROMAN")]; + char stringpool_str389[sizeof("MACCYRILLIC")]; + char stringpool_str391[sizeof("ISO-10646-UCS-2")]; + char stringpool_str394[sizeof("STRK1048-2002")]; + char stringpool_str395[sizeof("ISO_8859-4:1988")]; + char stringpool_str396[sizeof("ISO_8859-9:1989")]; + char stringpool_str397[sizeof("EUCJP")]; + char stringpool_str400[sizeof("EUC-JP")]; + char stringpool_str401[sizeof("ISO_8859-5:1988")]; + char stringpool_str402[sizeof("GREEK8")]; + char stringpool_str403[sizeof("ASMO-708")]; + char stringpool_str405[sizeof("PCK")]; + char stringpool_str408[sizeof("CSIBM866")]; + char stringpool_str409[sizeof("CP1257")]; + char stringpool_str411[sizeof("ISO-2022-KR")]; + char stringpool_str412[sizeof("GEORGIAN-ACADEMY")]; + char stringpool_str415[sizeof("MACCROATIAN")]; + char stringpool_str416[sizeof("CP367")]; + char stringpool_str419[sizeof("GEORGIAN-PS")]; + char stringpool_str423[sizeof("CSGB2312")]; + char stringpool_str424[sizeof("VISCII")]; + char stringpool_str428[sizeof("MS-HEBR")]; + char stringpool_str429[sizeof("UTF-32LE")]; + char stringpool_str430[sizeof("CSISOLATIN3")]; + char stringpool_str432[sizeof("MACARABIC")]; + char stringpool_str436[sizeof("ISO_8859-3:1988")]; + char stringpool_str437[sizeof("IBM-CP1133")]; + char stringpool_str439[sizeof("TIS620.2529-1")]; + char stringpool_str448[sizeof("CSISO2022KR")]; + char stringpool_str449[sizeof("ISO8859-7")]; + char stringpool_str451[sizeof("MACCENTRALEUROPE")]; + char stringpool_str452[sizeof("ISO-8859-7")]; + char stringpool_str453[sizeof("ISO_8859-7")]; + char stringpool_str455[sizeof("CN-GB-ISOIR165")]; + char stringpool_str461[sizeof("ISO646-JP")]; + char stringpool_str462[sizeof("KS_C_5601-1987")]; + char stringpool_str463[sizeof("US-ASCII")]; + char stringpool_str464[sizeof("UCS-4BE")]; + char stringpool_str466[sizeof("CSEUCKR")]; + char stringpool_str467[sizeof("JIS0208")]; + char stringpool_str470[sizeof("UTF-16BE")]; + char stringpool_str475[sizeof("MS-ARAB")]; + char stringpool_str476[sizeof("CSPC862LATINHEBREW")]; + char stringpool_str478[sizeof("KOI8-T")]; + char stringpool_str481[sizeof("ISO-IR-87")]; + char stringpool_str482[sizeof("UCS-2BE")]; + char stringpool_str489[sizeof("MACROMANIA")]; + char stringpool_str492[sizeof("UCS-4-INTERNAL")]; + char stringpool_str493[sizeof("ISO_646.IRV:1991")]; + char stringpool_str495[sizeof("CSVISCII")]; + char stringpool_str497[sizeof("VISCII1.1-1")]; + char stringpool_str500[sizeof("ISO-IR-57")]; + char stringpool_str502[sizeof("NEXTSTEP")]; + char stringpool_str503[sizeof("HZ-GB-2312")]; + char stringpool_str504[sizeof("CSKSC56011987")]; + char stringpool_str505[sizeof("ISO-IR-157")]; + char stringpool_str507[sizeof("JIS_C6220-1969-RO")]; + char stringpool_str508[sizeof("CSISO58GB231280")]; + char stringpool_str509[sizeof("TIS620.2533-1")]; + char stringpool_str510[sizeof("UCS-2-INTERNAL")]; + char stringpool_str511[sizeof("WINDOWS-1258")]; + char stringpool_str512[sizeof("WINDOWS-1251")]; + char stringpool_str513[sizeof("MACTHAI")]; + char stringpool_str515[sizeof("WCHAR_T")]; + char stringpool_str516[sizeof("GBK")]; + char stringpool_str517[sizeof("ISO-IR-127")]; + char stringpool_str519[sizeof("WINDOWS-1256")]; + char stringpool_str520[sizeof("UNICODE-1-1-UTF-7")]; + char stringpool_str521[sizeof("LATIN7")]; + char stringpool_str523[sizeof("ANSI_X3.4-1968")]; + char stringpool_str524[sizeof("WINDOWS-1254")]; + char stringpool_str525[sizeof("CSUNICODE11UTF7")]; + char stringpool_str530[sizeof("WINDOWS-1255")]; + char stringpool_str531[sizeof("ANSI_X3.4-1986")]; + char stringpool_str532[sizeof("TIS620.2533-0")]; + char stringpool_str533[sizeof("EXTENDED_UNIX_CODE_PACKED_FORMAT_FOR_JAPANESE")]; + char stringpool_str535[sizeof("WINDOWS-1250")]; + char stringpool_str536[sizeof("WINDOWS-936")]; + char stringpool_str537[sizeof("EUCTW")]; + char stringpool_str540[sizeof("EUC-TW")]; + char stringpool_str542[sizeof("WINDOWS-1252")]; + char stringpool_str543[sizeof("JIS_C6226-1983")]; + char stringpool_str545[sizeof("UCS-4-SWAPPED")]; + char stringpool_str546[sizeof("UTF-32BE")]; + char stringpool_str547[sizeof("TCVN5712-1")]; + char stringpool_str548[sizeof("ISO_8859-1:1987")]; + char stringpool_str553[sizeof("MACINTOSH")]; + char stringpool_str554[sizeof("ISO-2022-JP-1")]; + char stringpool_str555[sizeof("ISO_8859-6:1987")]; + char stringpool_str556[sizeof("ISO-2022-JP")]; + char stringpool_str560[sizeof("TIS620.2533")]; + char stringpool_str563[sizeof("UCS-2-SWAPPED")]; + char stringpool_str565[sizeof("WINDOWS-1253")]; + char stringpool_str569[sizeof("JAVA")]; + char stringpool_str570[sizeof("CSISO57GB1988")]; + char stringpool_str572[sizeof("TCVN-5712")]; + char stringpool_str578[sizeof("ISO_8859-2:1987")]; + char stringpool_str579[sizeof("CSISO14JISC6220RO")]; + char stringpool_str583[sizeof("CSMACINTOSH")]; + char stringpool_str584[sizeof("ISO-2022-JP-2")]; + char stringpool_str588[sizeof("UTF-7")]; + char stringpool_str589[sizeof("CSPC850MULTILINGUAL")]; + char stringpool_str592[sizeof("GREEK")]; + char stringpool_str593[sizeof("CSISO2022JP")]; + char stringpool_str594[sizeof("CSISOLATINHEBREW")]; + char stringpool_str601[sizeof("ISO_8859-7:2003")]; + char stringpool_str616[sizeof("CSISO159JISX02121990")]; + char stringpool_str619[sizeof("BIGFIVE")]; + char stringpool_str620[sizeof("CSISO2022JP2")]; + char stringpool_str622[sizeof("BIG-FIVE")]; + char stringpool_str636[sizeof("CSISOLATINGREEK")]; + char stringpool_str637[sizeof("HEBREW")]; + char stringpool_str641[sizeof("IBM367")]; + char stringpool_str647[sizeof("CSHALFWIDTHKATAKANA")]; + char stringpool_str650[sizeof("WINDOWS-874")]; + char stringpool_str652[sizeof("UNICODELITTLE")]; + char stringpool_str663[sizeof("BIG5HKSCS")]; + char stringpool_str666[sizeof("BIG5-HKSCS")]; + char stringpool_str667[sizeof("JIS_X0208")]; + char stringpool_str669[sizeof("JIS_X0201")]; + char stringpool_str676[sizeof("WINDOWS-1257")]; + char stringpool_str680[sizeof("KOI8-U")]; + char stringpool_str684[sizeof("KOI8-RU")]; + char stringpool_str691[sizeof("JOHAB")]; + char stringpool_str693[sizeof("JISX0201-1976")]; + char stringpool_str702[sizeof("JIS_X0208-1990")]; + char stringpool_str706[sizeof("JIS_X0212")]; + char stringpool_str710[sizeof("JIS_X0212-1990")]; + char stringpool_str712[sizeof("ISO_8859-7:1987")]; + char stringpool_str713[sizeof("SHIFT-JIS")]; + char stringpool_str714[sizeof("SHIFT_JIS")]; + char stringpool_str732[sizeof("JIS_X0208-1983")]; + char stringpool_str751[sizeof("CSEUCTW")]; + char stringpool_str752[sizeof("MACUKRAINE")]; + char stringpool_str759[sizeof("UNICODEBIG")]; + char stringpool_str769[sizeof("MS-GREEK")]; + char stringpool_str774[sizeof("MACGREEK")]; + char stringpool_str800[sizeof("CSSHIFTJIS")]; + char stringpool_str822[sizeof("JIS_X0212.1990-0")]; + char stringpool_str840[sizeof("CSEUCPKDFMTJAPANESE")]; + char stringpool_str853[sizeof("MACHEBREW")]; + char stringpool_str858[sizeof("MS_KANJI")]; + char stringpool_str859[sizeof("TCVN5712-1:1993")]; + char stringpool_str869[sizeof("WINBALTRIM")]; + char stringpool_str884[sizeof("MS-TURK")]; + char stringpool_str895[sizeof("BIG5-HKSCS:2001")]; + char stringpool_str901[sizeof("BIG5-HKSCS:1999")]; + char stringpool_str907[sizeof("BIG5-HKSCS:2004")]; + char stringpool_str917[sizeof("CSISO87JISX0208")]; + char stringpool_str953[sizeof("MACTURKISH")]; + char stringpool_str1003[sizeof("KO_KR.JOHAP92")]; + }; +static const struct stringpool_t stringpool_contents = + { + "R8", + "CN", + "L8", + "L1", + "L6", + "L4", + "866", + "C99", + "L5", + "646", + "CHAR", + "CP819", + "L2", + "CP866", + "CP949", + "850", + "5601", + "RK1048", + "EUCCN", + "L10", + "EUC-CN", + "L3", + "CP154", + "PT154", + "862", + "CP1258", + "CP1251", + "CP1131", + "PTCP154", + "CP850", + "CP1361", + "CP862", + "CP1256", + "CP950", + "HZ", + "CP936", + "CP1254", + "CP1255", + "ISO8859-8", + "ISO8859-1", + "ISO-8859-8", + "ISO_8859-8", + "ISO-8859-1", + "ISO_8859-1", + "ISO8859-11", + "CP1250", + "ISO646-CN", + "ISO-8859-11", + "ISO_8859-11", + "ISO8859-9", + "ISO8859-6", + "ISO-8859-9", + "ISO_8859-9", + "ISO-8859-6", + "ISO_8859-6", + "ISO8859-16", + "CP1252", + "ISO_8859-16:2001", + "ISO-8859-16", + "ISO_8859-16", + "ISO8859-4", + "ISO_8859-14:1998", + "CP932", + "ISO-8859-4", + "ISO_8859-4", + "ISO8859-14", + "ISO_8859-15:1998", + "ISO-8859-14", + "ISO_8859-14", + "ISO8859-5", + "ISO-8859-5", + "ISO_8859-5", + "ISO8859-15", + "ISO-IR-6", + "ISO-8859-15", + "ISO_8859-15", + "SJIS", + "ISO-IR-148", + "ISO-IR-58", + "ISO8859-10", + "CYRILLIC", + "ISO-8859-10", + "ISO_8859-10", + "ISO-IR-199", + "ISO-IR-14", + "L7", + "ISO-IR-166", + "ISO8859-2", + "ISO-IR-101", + "ISO-IR-149", + "ISO-8859-2", + "ISO_8859-2", + "MAC", + "CP1253", + "ISO_8859-10:1992", + "ISO-IR-159", + "LATIN8", + "CP1133", + "LATIN1", + "ISO-IR-109", + "ISO-IR-144", + "ANSI-1251", + "CNS11643", + "CSPTCP154", + "ISO-IR-165", + "ISO-IR-126", + "ELOT_928", + "ISO-IR-110", + "LATIN6", + "LATIN-9", + "ROMAN8", + "ISO-IR-138", + "GB_1988-80", + "CP874", + "LATIN4", + "ASCII", + "UHC", + "ISO-2022-CN", + "CHINESE", + "ISO8859-3", + "ISO-IR-100", + "LATIN5", + "ISO-8859-3", + "ISO_8859-3", + "ISO8859-13", + "ISO-IR-226", + "CYRILLIC-ASIAN", + "ISO-8859-13", + "ISO_8859-13", + "US", + "MS-CYRL", + "TIS620", + "LATIN10", + "TIS-620", + "ARABIC", + "ECMA-118", + "EUCKR", + "LATIN2", + "EUC-KR", + "UTF-8", + "KZ-1048", + "CSISO2022CN", + "CSASCII", + "MS936", + "IBM819", + "MULELAO-1", + "X0208", + "X0201", + "GB18030", + "KOREAN", + "IBM866", + "TIS620-0", + "KOI8-R", + "ECMA-114", + "UCS-4", + "UTF-16", + "CSKZ1048", + "KSC_5601", + "CSKOI8R", + "MS-EE", + "GB2312", + "CSUCS4", + "BIG5", + "BIG-5", + "HP-ROMAN8", + "LATIN3", + "KS_C_5601-1989", + "X0212", + "TCVN", + "ISO-CELTIC", + "CSHPROMAN8", + "UCS-2", + "IBM850", + "ISO-IR-203", + "IBM862", + "GB_2312-80", + "CSISOLATIN1", + "ISO-2022-CN-EXT", + "ISO-IR-179", + "CSISOLATINCYRILLIC", + "CSISOLATIN6", + "JP", + "MACICELAND", + "UCS-4LE", + "CSISOLATIN4", + "CSISOLATINARABIC", + "UNICODE-1-1", + "UTF-16LE", + "CSUNICODE11", + "CSISOLATIN5", + "MS-ANSI", + "CSBIG5", + "UCS-2LE", + "CN-BIG5", + "ARMSCII-8", + "ISO-10646-UCS-4", + "UTF-32", + "CSUNICODE", + "ISO_8859-8:1988", + "CSISOLATIN2", + "CN-GB", + "ISO646-US", + "MACROMAN", + "MACCYRILLIC", + "ISO-10646-UCS-2", + "STRK1048-2002", + "ISO_8859-4:1988", + "ISO_8859-9:1989", + "EUCJP", + "EUC-JP", + "ISO_8859-5:1988", + "GREEK8", + "ASMO-708", + "PCK", + "CSIBM866", + "CP1257", + "ISO-2022-KR", + "GEORGIAN-ACADEMY", + "MACCROATIAN", + "CP367", + "GEORGIAN-PS", + "CSGB2312", + "VISCII", + "MS-HEBR", + "UTF-32LE", + "CSISOLATIN3", + "MACARABIC", + "ISO_8859-3:1988", + "IBM-CP1133", + "TIS620.2529-1", + "CSISO2022KR", + "ISO8859-7", + "MACCENTRALEUROPE", + "ISO-8859-7", + "ISO_8859-7", + "CN-GB-ISOIR165", + "ISO646-JP", + "KS_C_5601-1987", + "US-ASCII", + "UCS-4BE", + "CSEUCKR", + "JIS0208", + "UTF-16BE", + "MS-ARAB", + "CSPC862LATINHEBREW", + "KOI8-T", + "ISO-IR-87", + "UCS-2BE", + "MACROMANIA", + "UCS-4-INTERNAL", + "ISO_646.IRV:1991", + "CSVISCII", + "VISCII1.1-1", + "ISO-IR-57", + "NEXTSTEP", + "HZ-GB-2312", + "CSKSC56011987", + "ISO-IR-157", + "JIS_C6220-1969-RO", + "CSISO58GB231280", + "TIS620.2533-1", + "UCS-2-INTERNAL", + "WINDOWS-1258", + "WINDOWS-1251", + "MACTHAI", + "WCHAR_T", + "GBK", + "ISO-IR-127", + "WINDOWS-1256", + "UNICODE-1-1-UTF-7", + "LATIN7", + "ANSI_X3.4-1968", + "WINDOWS-1254", + "CSUNICODE11UTF7", + "WINDOWS-1255", + "ANSI_X3.4-1986", + "TIS620.2533-0", + "EXTENDED_UNIX_CODE_PACKED_FORMAT_FOR_JAPANESE", + "WINDOWS-1250", + "WINDOWS-936", + "EUCTW", + "EUC-TW", + "WINDOWS-1252", + "JIS_C6226-1983", + "UCS-4-SWAPPED", + "UTF-32BE", + "TCVN5712-1", + "ISO_8859-1:1987", + "MACINTOSH", + "ISO-2022-JP-1", + "ISO_8859-6:1987", + "ISO-2022-JP", + "TIS620.2533", + "UCS-2-SWAPPED", + "WINDOWS-1253", + "JAVA", + "CSISO57GB1988", + "TCVN-5712", + "ISO_8859-2:1987", + "CSISO14JISC6220RO", + "CSMACINTOSH", + "ISO-2022-JP-2", + "UTF-7", + "CSPC850MULTILINGUAL", + "GREEK", + "CSISO2022JP", + "CSISOLATINHEBREW", + "ISO_8859-7:2003", + "CSISO159JISX02121990", + "BIGFIVE", + "CSISO2022JP2", + "BIG-FIVE", + "CSISOLATINGREEK", + "HEBREW", + "IBM367", + "CSHALFWIDTHKATAKANA", + "WINDOWS-874", + "UNICODELITTLE", + "BIG5HKSCS", + "BIG5-HKSCS", + "JIS_X0208", + "JIS_X0201", + "WINDOWS-1257", + "KOI8-U", + "KOI8-RU", + "JOHAB", + "JISX0201-1976", + "JIS_X0208-1990", + "JIS_X0212", + "JIS_X0212-1990", + "ISO_8859-7:1987", + "SHIFT-JIS", + "SHIFT_JIS", + "JIS_X0208-1983", + "CSEUCTW", + "MACUKRAINE", + "UNICODEBIG", + "MS-GREEK", + "MACGREEK", + "CSSHIFTJIS", + "JIS_X0212.1990-0", + "CSEUCPKDFMTJAPANESE", + "MACHEBREW", + "MS_KANJI", + "TCVN5712-1:1993", + "WINBALTRIM", + "MS-TURK", + "BIG5-HKSCS:2001", + "BIG5-HKSCS:1999", + "BIG5-HKSCS:2004", + "CSISO87JISX0208", + "MACTURKISH", + "KO_KR.JOHAP92" + }; +#define stringpool ((const char *) &stringpool_contents) + +static const struct alias aliases[] = + { + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 229 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str8, ei_hp_roman8}, + {-1}, {-1}, {-1}, {-1}, +#line 291 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str13, ei_iso646_cn}, +#line 152 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str14, ei_iso8859_14}, +#line 61 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str15, ei_iso8859_1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 135 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str22, ei_iso8859_10}, + {-1}, {-1}, {-1}, {-1}, +#line 85 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str27, ei_iso8859_4}, +#line 209 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str28, ei_cp866}, + {-1}, +#line 52 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str30, ei_c99}, + {-1}, {-1}, +#line 127 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str33, ei_iso8859_9}, + {-1}, {-1}, +#line 23 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str36, ei_ascii}, + {-1}, +#line 363 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str38, ei_local_char}, +#line 58 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str39, ei_iso8859_1}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 69 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str45, ei_iso8859_2}, + {-1}, {-1}, +#line 207 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str48, ei_cp866}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 356 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str58, ei_cp949}, + {-1}, +#line 201 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str60, ei_cp850}, +#line 355 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str61, ei_euc_kr}, +#line 241 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str62, ei_rk1048}, + {-1}, +#line 322 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str64, ei_euc_cn}, + {-1}, +#line 166 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str66, ei_iso8859_16}, +#line 321 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str67, ei_euc_cn}, +#line 77 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str68, ei_iso8859_3}, + {-1}, +#line 238 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str70, ei_pt154}, +#line 236 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str71, ei_pt154}, + {-1}, {-1}, +#line 205 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str74, ei_cp862}, + {-1}, {-1}, {-1}, {-1}, +#line 197 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str79, ei_cp1258}, + {-1}, +#line 175 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str81, ei_cp1251}, + {-1}, {-1}, {-1}, {-1}, +#line 211 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str86, ei_cp1131}, + {-1}, +#line 237 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str88, ei_pt154}, + {-1}, {-1}, +#line 199 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str91, ei_cp850}, + {-1}, +#line 359 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str93, ei_johab}, +#line 203 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str94, ei_cp862}, +#line 191 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str95, ei_cp1256}, + {-1}, {-1}, +#line 346 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str98, ei_cp950}, +#line 334 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str99, ei_hz}, + {-1}, +#line 327 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str101, ei_cp936}, + {-1}, {-1}, {-1}, +#line 185 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str105, ei_cp1254}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, +#line 188 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str117, ei_cp1255}, + {-1}, +#line 121 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str119, ei_iso8859_8}, + {-1}, +#line 63 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str121, ei_iso8859_1}, +#line 115 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str122, ei_iso8859_8}, +#line 116 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str123, ei_iso8859_8}, +#line 54 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str124, ei_iso8859_1}, +#line 55 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str125, ei_iso8859_1}, +#line 140 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str126, ei_iso8859_11}, +#line 172 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str127, ei_cp1250}, +#line 289 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str128, ei_iso646_cn}, +#line 138 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str129, ei_iso8859_11}, +#line 139 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str130, ei_iso8859_11}, + {-1}, {-1}, +#line 129 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str133, ei_iso8859_9}, + {-1}, +#line 103 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str135, ei_iso8859_6}, +#line 122 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str136, ei_iso8859_9}, +#line 123 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str137, ei_iso8859_9}, +#line 95 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str138, ei_iso8859_6}, +#line 96 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str139, ei_iso8859_6}, +#line 167 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str140, ei_iso8859_16}, +#line 179 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str141, ei_cp1252}, +#line 163 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str142, ei_iso8859_16}, +#line 161 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str143, ei_iso8859_16}, +#line 162 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str144, ei_iso8859_16}, +#line 87 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str145, ei_iso8859_4}, +#line 149 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str146, ei_iso8859_14}, +#line 315 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str147, ei_cp932}, +#line 80 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str148, ei_iso8859_4}, +#line 81 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str149, ei_iso8859_4}, +#line 154 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str150, ei_iso8859_14}, + {-1}, +#line 157 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str152, ei_iso8859_15}, +#line 147 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str153, ei_iso8859_14}, +#line 148 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str154, ei_iso8859_14}, + {-1}, {-1}, +#line 94 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str157, ei_iso8859_5}, + {-1}, {-1}, +#line 88 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str160, ei_iso8859_5}, +#line 89 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str161, ei_iso8859_5}, +#line 160 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str162, ei_iso8859_15}, +#line 16 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str163, ei_ascii}, + {-1}, +#line 155 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str165, ei_iso8859_15}, +#line 156 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str166, ei_iso8859_15}, + {-1}, +#line 311 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str168, ei_sjis}, +#line 125 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str169, ei_iso8859_9}, +#line 294 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str170, ei_gb2312}, + {-1}, +#line 137 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str172, ei_iso8859_10}, + {-1}, +#line 92 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str174, ei_iso8859_5}, +#line 130 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str175, ei_iso8859_10}, +#line 131 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str176, ei_iso8859_10}, +#line 150 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str177, ei_iso8859_14}, +#line 267 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str178, ei_iso646_jp}, +#line 145 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str179, ei_iso8859_13}, +#line 254 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str180, ei_tis620}, +#line 71 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str181, ei_iso8859_2}, +#line 67 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str182, ei_iso8859_2}, +#line 302 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str183, ei_ksc5601}, +#line 64 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str184, ei_iso8859_2}, +#line 65 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str185, ei_iso8859_2}, +#line 214 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str186, ei_mac_roman}, +#line 182 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str187, ei_cp1253}, +#line 132 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str188, ei_iso8859_10}, +#line 286 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str189, ei_jisx0212}, + {-1}, +#line 151 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str191, ei_iso8859_14}, +#line 246 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str192, ei_cp1133}, +#line 60 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str193, ei_iso8859_1}, +#line 75 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str194, ei_iso8859_3}, +#line 91 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str195, ei_iso8859_5}, +#line 178 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str196, ei_cp1251}, + {-1}, +#line 339 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str198, ei_euc_tw}, + {-1}, {-1}, +#line 240 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str201, ei_pt154}, +#line 297 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str202, ei_isoir165}, +#line 108 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str203, ei_iso8859_7}, +#line 110 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str204, ei_iso8859_7}, +#line 83 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str205, ei_iso8859_4}, + {-1}, +#line 134 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str207, ei_iso8859_10}, +#line 159 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str208, ei_iso8859_15}, +#line 228 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str209, ei_hp_roman8}, +#line 118 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str210, ei_iso8859_8}, +#line 288 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str211, ei_iso646_cn}, + {-1}, {-1}, {-1}, +#line 256 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str215, ei_cp874}, + {-1}, +#line 84 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str217, ei_iso8859_4}, + {-1}, +#line 13 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str219, ei_ascii}, + {-1}, {-1}, +#line 357 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str222, ei_cp949}, +#line 331 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str223, ei_iso2022_cn}, + {-1}, +#line 296 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str225, ei_gb2312}, + {-1}, +#line 79 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str227, ei_iso8859_3}, +#line 57 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str228, ei_iso8859_1}, +#line 126 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str229, ei_iso8859_9}, +#line 72 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str230, ei_iso8859_3}, +#line 73 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str231, ei_iso8859_3}, +#line 146 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str232, ei_iso8859_13}, +#line 164 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str233, ei_iso8859_16}, +#line 239 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str234, ei_pt154}, +#line 141 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str235, ei_iso8859_13}, +#line 142 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str236, ei_iso8859_13}, + {-1}, {-1}, {-1}, {-1}, +#line 21 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str241, ei_ascii}, +#line 177 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str242, ei_cp1251}, +#line 249 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str243, ei_tis620}, +#line 165 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str244, ei_iso8859_16}, + {-1}, +#line 248 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str246, ei_tis620}, + {-1}, {-1}, {-1}, +#line 101 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str250, ei_iso8859_6}, +#line 109 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str251, ei_iso8859_7}, +#line 353 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str252, ei_euc_kr}, +#line 68 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str253, ei_iso8859_2}, + {-1}, +#line 352 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str255, ei_euc_kr}, + {-1}, {-1}, +#line 24 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str258, ei_utf8}, +#line 243 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str259, ei_rk1048}, +#line 332 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str260, ei_iso2022_cn}, + {-1}, +#line 22 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str262, ei_ascii}, +#line 328 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str263, ei_cp936}, +#line 59 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str264, ei_iso8859_1}, + {-1}, +#line 245 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str266, ei_mulelao}, +#line 278 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str267, ei_jisx0208}, + {-1}, +#line 272 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str269, ei_jisx0201}, + {-1}, +#line 330 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str271, ei_gb18030}, +#line 304 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str272, ei_ksc5601}, +#line 208 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str273, ei_cp866}, +#line 250 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str274, ei_tis620}, + {-1}, +#line 168 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str276, ei_koi8_r}, +#line 99 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str277, ei_iso8859_6}, +#line 34 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str278, ei_ucs4}, +#line 39 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str279, ei_utf16}, + {-1}, +#line 244 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str281, ei_rk1048}, + {-1}, +#line 299 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str283, ei_ksc5601}, +#line 169 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str284, ei_koi8_r}, + {-1}, {-1}, +#line 174 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str287, ei_cp1250}, +#line 323 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str288, ei_euc_cn}, + {-1}, {-1}, +#line 36 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str291, ei_ucs4}, + {-1}, +#line 340 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str293, ei_ces_big5}, + {-1}, {-1}, +#line 341 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str296, ei_ces_big5}, +#line 227 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str297, ei_hp_roman8}, + {-1}, +#line 76 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str299, ei_iso8859_3}, + {-1}, {-1}, {-1}, {-1}, +#line 301 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str304, ei_ksc5601}, + {-1}, +#line 285 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str306, ei_jisx0212}, +#line 261 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str307, ei_tcvn}, + {-1}, +#line 153 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str309, ei_iso8859_14}, + {-1}, +#line 230 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str311, ei_hp_roman8}, + {-1}, {-1}, +#line 25 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str314, ei_ucs2}, + {-1}, +#line 200 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str316, ei_cp850}, + {-1}, +#line 158 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str318, ei_iso8859_15}, +#line 204 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str319, ei_cp862}, +#line 293 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str320, ei_gb2312}, + {-1}, {-1}, {-1}, +#line 62 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str324, ei_iso8859_1}, + {-1}, {-1}, +#line 333 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str327, ei_iso2022_cn_ext}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 143 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str335, ei_iso8859_13}, + {-1}, +#line 93 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str337, ei_iso8859_5}, +#line 136 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str338, ei_iso8859_10}, + {-1}, {-1}, {-1}, +#line 268 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str342, ei_iso646_jp}, + {-1}, {-1}, {-1}, +#line 217 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str346, ei_mac_iceland}, +#line 38 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str347, ei_ucs4le}, +#line 86 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str348, ei_iso8859_4}, +#line 102 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str349, ei_iso8859_6}, +#line 30 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str350, ei_ucs2be}, + {-1}, {-1}, +#line 41 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str353, ei_utf16le}, + {-1}, {-1}, {-1}, +#line 31 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str357, ei_ucs2be}, + {-1}, {-1}, +#line 128 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str360, ei_iso8859_9}, +#line 181 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str361, ei_cp1252}, + {-1}, {-1}, +#line 345 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str364, ei_ces_big5}, +#line 32 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str365, ei_ucs2le}, + {-1}, +#line 344 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str367, ei_ces_big5}, + {-1}, {-1}, {-1}, {-1}, +#line 232 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str372, ei_armscii_8}, +#line 35 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str373, ei_ucs4}, + {-1}, {-1}, {-1}, {-1}, +#line 42 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str378, ei_utf32}, + {-1}, +#line 27 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str380, ei_ucs2}, + {-1}, +#line 117 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str382, ei_iso8859_8}, + {-1}, +#line 70 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str384, ei_iso8859_2}, +#line 324 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str385, ei_euc_cn}, +#line 14 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str386, ei_ascii}, +#line 212 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str387, ei_mac_roman}, + {-1}, +#line 220 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str389, ei_mac_cyrillic}, + {-1}, +#line 26 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str391, ei_ucs2}, + {-1}, {-1}, +#line 242 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str394, ei_rk1048}, +#line 82 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str395, ei_iso8859_4}, +#line 124 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str396, ei_iso8859_9}, +#line 306 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str397, ei_euc_jp}, + {-1}, {-1}, +#line 305 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str400, ei_euc_jp}, +#line 90 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str401, ei_iso8859_5}, +#line 111 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str402, ei_iso8859_7}, +#line 100 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str403, ei_iso8859_6}, + {-1}, +#line 314 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str405, ei_sjis}, + {-1}, {-1}, +#line 210 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str408, ei_cp866}, +#line 194 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str409, ei_cp1257}, + {-1}, +#line 361 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str411, ei_iso2022_kr}, +#line 233 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str412, ei_georgian_academy}, + {-1}, {-1}, +#line 218 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str415, ei_mac_croatian}, +#line 19 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str416, ei_ascii}, + {-1}, {-1}, +#line 234 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str419, ei_georgian_ps}, + {-1}, {-1}, {-1}, +#line 325 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str423, ei_euc_cn}, +#line 258 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str424, ei_viscii}, + {-1}, {-1}, {-1}, +#line 190 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str428, ei_cp1255}, +#line 44 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str429, ei_utf32le}, +#line 78 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str430, ei_iso8859_3}, + {-1}, +#line 225 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str432, ei_mac_arabic}, + {-1}, {-1}, {-1}, +#line 74 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str436, ei_iso8859_3}, +#line 247 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str437, ei_cp1133}, + {-1}, +#line 251 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str439, ei_tis620}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 362 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str448, ei_iso2022_kr}, +#line 114 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str449, ei_iso8859_7}, + {-1}, +#line 216 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str451, ei_mac_centraleurope}, +#line 104 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str452, ei_iso8859_7}, +#line 105 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str453, ei_iso8859_7}, + {-1}, +#line 298 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str455, ei_isoir165}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 266 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str461, ei_iso646_jp}, +#line 300 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str462, ei_ksc5601}, +#line 12 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str463, ei_ascii}, +#line 37 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str464, ei_ucs4be}, + {-1}, +#line 354 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str466, ei_euc_kr}, +#line 277 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str467, ei_jisx0208}, + {-1}, {-1}, +#line 40 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str470, ei_utf16be}, + {-1}, {-1}, {-1}, {-1}, +#line 193 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str475, ei_cp1256}, +#line 206 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str476, ei_cp862}, + {-1}, +#line 235 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str478, ei_koi8_t}, + {-1}, {-1}, +#line 279 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str481, ei_jisx0208}, +#line 28 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str482, ei_ucs2be}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 219 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str489, ei_mac_romania}, + {-1}, {-1}, +#line 50 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str492, ei_ucs4internal}, +#line 15 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str493, ei_ascii}, + {-1}, +#line 260 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str495, ei_viscii}, + {-1}, +#line 259 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str497, ei_viscii}, + {-1}, {-1}, +#line 290 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str500, ei_iso646_cn}, + {-1}, +#line 231 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str502, ei_nextstep}, +#line 335 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str503, ei_hz}, +#line 303 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str504, ei_ksc5601}, +#line 133 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str505, ei_iso8859_10}, + {-1}, +#line 265 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str507, ei_iso646_jp}, +#line 295 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str508, ei_gb2312}, +#line 253 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str509, ei_tis620}, +#line 48 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str510, ei_ucs2internal}, +#line 198 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str511, ei_cp1258}, +#line 176 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str512, ei_cp1251}, +#line 226 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str513, ei_mac_thai}, + {-1}, +#line 364 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str515, ei_local_wchar_t}, +#line 326 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str516, ei_ces_gbk}, +#line 98 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str517, ei_iso8859_6}, + {-1}, +#line 192 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str519, ei_cp1256}, +#line 46 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str520, ei_utf7}, +#line 144 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str521, ei_iso8859_13}, + {-1}, +#line 17 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str523, ei_ascii}, +#line 186 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str524, ei_cp1254}, +#line 47 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str525, ei_utf7}, + {-1}, {-1}, {-1}, {-1}, +#line 189 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str530, ei_cp1255}, +#line 18 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str531, ei_ascii}, +#line 252 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str532, ei_tis620}, +#line 307 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str533, ei_euc_jp}, + {-1}, +#line 173 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str535, ei_cp1250}, +#line 329 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str536, ei_cp936}, +#line 337 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str537, ei_euc_tw}, + {-1}, {-1}, +#line 336 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str540, ei_euc_tw}, + {-1}, +#line 180 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str542, ei_cp1252}, +#line 280 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str543, ei_jisx0208}, + {-1}, +#line 51 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str545, ei_ucs4swapped}, +#line 43 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str546, ei_utf32be}, +#line 263 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str547, ei_tcvn}, +#line 56 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str548, ei_iso8859_1}, + {-1}, {-1}, {-1}, {-1}, +#line 213 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str553, ei_mac_roman}, +#line 318 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str554, ei_iso2022_jp1}, +#line 97 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str555, ei_iso8859_6}, +#line 316 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str556, ei_iso2022_jp}, + {-1}, {-1}, {-1}, +#line 255 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str560, ei_tis620}, + {-1}, {-1}, +#line 49 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str563, ei_ucs2swapped}, + {-1}, +#line 183 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str565, ei_cp1253}, + {-1}, {-1}, {-1}, +#line 53 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str569, ei_java}, +#line 292 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str570, ei_iso646_cn}, + {-1}, +#line 262 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str572, ei_tcvn}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 66 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str578, ei_iso8859_2}, +#line 269 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str579, ei_iso646_jp}, + {-1}, {-1}, {-1}, +#line 215 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str583, ei_mac_roman}, +#line 319 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str584, ei_iso2022_jp2}, + {-1}, {-1}, {-1}, +#line 45 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str588, ei_utf7}, +#line 202 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str589, ei_cp850}, + {-1}, {-1}, +#line 112 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str592, ei_iso8859_7}, +#line 317 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str593, ei_iso2022_jp}, +#line 120 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str594, ei_iso8859_8}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 107 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str601, ei_iso8859_7}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 287 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str616, ei_jisx0212}, + {-1}, {-1}, +#line 343 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str619, ei_ces_big5}, +#line 320 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str620, ei_iso2022_jp2}, + {-1}, +#line 342 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str622, ei_ces_big5}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, +#line 113 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str636, ei_iso8859_7}, +#line 119 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str637, ei_iso8859_8}, + {-1}, {-1}, {-1}, +#line 20 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str641, ei_ascii}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 273 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str647, ei_jisx0201}, + {-1}, {-1}, +#line 257 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str650, ei_cp874}, + {-1}, +#line 33 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str652, ei_ucs2le}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, +#line 350 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str663, ei_big5hkscs2004}, + {-1}, {-1}, +#line 349 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str666, ei_big5hkscs2004}, +#line 274 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str667, ei_jisx0208}, + {-1}, +#line 270 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str669, ei_jisx0201}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 195 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str676, ei_cp1257}, + {-1}, {-1}, {-1}, +#line 170 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str680, ei_koi8_u}, + {-1}, {-1}, {-1}, +#line 171 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str684, ei_koi8_ru}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 358 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str691, ei_johab}, + {-1}, +#line 271 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str693, ei_jisx0201}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 276 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str702, ei_jisx0208}, + {-1}, {-1}, {-1}, +#line 282 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str706, ei_jisx0212}, + {-1}, {-1}, {-1}, +#line 284 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str710, ei_jisx0212}, + {-1}, +#line 106 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str712, ei_iso8859_7}, +#line 310 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str713, ei_sjis}, +#line 309 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str714, ei_sjis}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 275 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str732, ei_jisx0208}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 338 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str751, ei_euc_tw}, +#line 221 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str752, ei_mac_ukraine}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 29 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str759, ei_ucs2be}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 184 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str769, ei_cp1253}, + {-1}, {-1}, {-1}, {-1}, +#line 222 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str774, ei_mac_greek}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 313 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str800, ei_sjis}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, +#line 283 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str822, ei_jisx0212}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 308 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str840, ei_euc_jp}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, +#line 224 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str853, ei_mac_hebrew}, + {-1}, {-1}, {-1}, {-1}, +#line 312 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str858, ei_sjis}, +#line 264 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str859, ei_tcvn}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 196 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str869, ei_cp1257}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 187 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str884, ei_cp1254}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, +#line 348 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str895, ei_big5hkscs2001}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 347 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str901, ei_big5hkscs1999}, + {-1}, {-1}, {-1}, {-1}, {-1}, +#line 351 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str907, ei_big5hkscs2004}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 281 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str917, ei_jisx0208}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, +#line 223 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str953, ei_mac_turkish}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, + {-1}, {-1}, {-1}, {-1}, +#line 360 "lib/aliases_syssolaris.gperf" + {(int)(long)&((struct stringpool_t *)0)->stringpool_str1003, ei_johab} + }; + +#ifdef __GNUC__ +__inline +#if defined __GNUC_STDC_INLINE__ || defined __GNUC_GNU_INLINE__ +__attribute__ ((__gnu_inline__)) +#endif +#endif +const struct alias * +aliases_lookup (register const char *str, register unsigned int len) +{ + if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) + { + register int key = aliases_hash (str, len); + + if (key <= MAX_HASH_VALUE && key >= 0) + { + register int o = aliases[key].name; + if (o >= 0) + { + register const char *s = o + stringpool; + + if (*str == *s && !strcmp (str + 1, s + 1)) + return &aliases[key]; + } + } + } + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/armscii_8.h b/graf2d/win32gdk/gdk/src/iconv/armscii_8.h new file mode 100644 index 0000000000000..8d1613ff98c15 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/armscii_8.h @@ -0,0 +1,116 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ARMSCII-8 + */ + +static const unsigned short armscii_8_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0xfffd, 0x0587, 0x0589, 0x0029, 0x0028, 0x00bb, 0x00ab, + 0x2014, 0x002e, 0x055d, 0x002c, 0x002d, 0x058a, 0x2026, 0x055c, + /* 0xb0 */ + 0x055b, 0x055e, 0x0531, 0x0561, 0x0532, 0x0562, 0x0533, 0x0563, + 0x0534, 0x0564, 0x0535, 0x0565, 0x0536, 0x0566, 0x0537, 0x0567, + /* 0xc0 */ + 0x0538, 0x0568, 0x0539, 0x0569, 0x053a, 0x056a, 0x053b, 0x056b, + 0x053c, 0x056c, 0x053d, 0x056d, 0x053e, 0x056e, 0x053f, 0x056f, + /* 0xd0 */ + 0x0540, 0x0570, 0x0541, 0x0571, 0x0542, 0x0572, 0x0543, 0x0573, + 0x0544, 0x0574, 0x0545, 0x0575, 0x0546, 0x0576, 0x0547, 0x0577, + /* 0xe0 */ + 0x0548, 0x0578, 0x0549, 0x0579, 0x054a, 0x057a, 0x054b, 0x057b, + 0x054c, 0x057c, 0x054d, 0x057d, 0x054e, 0x057e, 0x054f, 0x057f, + /* 0xf0 */ + 0x0550, 0x0580, 0x0551, 0x0581, 0x0552, 0x0582, 0x0553, 0x0583, + 0x0554, 0x0584, 0x0555, 0x0585, 0x0556, 0x0586, 0x055a, 0xfffd, +}; + +static int +armscii_8_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = armscii_8_2uni[c-0xa0]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char armscii_8_page00[8] = { + 0xa5, 0xa4, 0x2a, 0x2b, 0xab, 0xac, 0xa9, 0x2f, /* 0x28-0x2f */ +}; +static const unsigned char armscii_8_page00_1[32] = { + 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0xa7, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xa6, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ +}; +static const unsigned char armscii_8_page05[96] = { + 0x00, 0xb2, 0xb4, 0xb6, 0xb8, 0xba, 0xbc, 0xbe, /* 0x30-0x37 */ + 0xc0, 0xc2, 0xc4, 0xc6, 0xc8, 0xca, 0xcc, 0xce, /* 0x38-0x3f */ + 0xd0, 0xd2, 0xd4, 0xd6, 0xd8, 0xda, 0xdc, 0xde, /* 0x40-0x47 */ + 0xe0, 0xe2, 0xe4, 0xe6, 0xe8, 0xea, 0xec, 0xee, /* 0x48-0x4f */ + 0xf0, 0xf2, 0xf4, 0xf6, 0xf8, 0xfa, 0xfc, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0xfe, 0xb0, 0xaf, 0xaa, 0xb1, 0x00, /* 0x58-0x5f */ + 0x00, 0xb3, 0xb5, 0xb7, 0xb9, 0xbb, 0xbd, 0xbf, /* 0x60-0x67 */ + 0xc1, 0xc3, 0xc5, 0xc7, 0xc9, 0xcb, 0xcd, 0xcf, /* 0x68-0x6f */ + 0xd1, 0xd3, 0xd5, 0xd7, 0xd9, 0xdb, 0xdd, 0xdf, /* 0x70-0x77 */ + 0xe1, 0xe3, 0xe5, 0xe7, 0xe9, 0xeb, 0xed, 0xef, /* 0x78-0x7f */ + 0xf1, 0xf3, 0xf5, 0xf7, 0xf9, 0xfb, 0xfd, 0xa2, /* 0x80-0x87 */ + 0x00, 0xa3, 0xad, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ +}; +static const unsigned char armscii_8_page20[24] = { + 0x00, 0x00, 0x00, 0x00, 0xa8, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xae, 0x00, /* 0x20-0x27 */ +}; + +static int +armscii_8_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0028) { + *r = wc; + return 1; + } + else if (wc >= 0x0028 && wc < 0x0030) + c = armscii_8_page00[wc-0x0028]; + else if (wc >= 0x0030 && wc < 0x00a0) + c = wc; + else if (wc >= 0x00a0 && wc < 0x00c0) + c = armscii_8_page00_1[wc-0x00a0]; + else if (wc >= 0x0530 && wc < 0x0590) + c = armscii_8_page05[wc-0x0530]; + else if (wc >= 0x2010 && wc < 0x2028) + c = armscii_8_page20[wc-0x2010]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/ascii.h b/graf2d/win32gdk/gdk/src/iconv/ascii.h new file mode 100644 index 0000000000000..fa49e3bf94f3a --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ascii.h @@ -0,0 +1,44 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ASCII + */ + +static int +ascii_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + return RET_ILSEQ; +} + +static int +ascii_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x0080) { + *r = wc; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/atarist.h b/graf2d/win32gdk/gdk/src/iconv/atarist.h new file mode 100644 index 0000000000000..90f18cc1470f3 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/atarist.h @@ -0,0 +1,158 @@ +/* + * Copyright (C) 1999-2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * Atari ST + */ + +static const unsigned short atarist_2uni[128] = { + /* 0x80 */ + 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x00e0, 0x00e5, 0x00e7, + 0x00ea, 0x00eb, 0x00e8, 0x00ef, 0x00ee, 0x00ec, 0x00c4, 0x00c5, + /* 0x90 */ + 0x00c9, 0x00e6, 0x00c6, 0x00f4, 0x00f6, 0x00f2, 0x00fb, 0x00f9, + 0x00ff, 0x00d6, 0x00dc, 0x00a2, 0x00a3, 0x00a5, 0x00df, 0x0192, + /* 0xa0 */ + 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x00aa, 0x00ba, + 0x00bf, 0x2310, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x00e3, 0x00f5, 0x00d8, 0x00f8, 0x0153, 0x0152, 0x00c0, 0x00c3, + 0x00d5, 0x00a8, 0x00b4, 0x2020, 0x00b6, 0x00a9, 0x00ae, 0x2122, + /* 0xc0 */ + 0x0133, 0x0132, 0x05d0, 0x05d1, 0x05d2, 0x05d3, 0x05d4, 0x05d5, + 0x05d6, 0x05d7, 0x05d8, 0x05d9, 0x05db, 0x05dc, 0x05de, 0x05e0, + /* 0xd0 */ + 0x05e1, 0x05e2, 0x05e4, 0x05e6, 0x05e7, 0x05e8, 0x05e9, 0x05ea, + 0x05df, 0x05da, 0x05dd, 0x05e3, 0x05e5, 0x00a7, 0x2227, 0x221e, + /* 0xe0 */ + 0x03b1, 0x03b2, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, + 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x222e, 0x03c6, 0x2208, 0x2229, + /* 0xf0 */ + 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, + 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x00b3, 0x00af, +}; + +static int +atarist_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) atarist_2uni[c-0x80]; + return 1; +} + +static const unsigned char atarist_page00[96] = { + 0x00, 0xad, 0x9b, 0x9c, 0x00, 0x9d, 0x00, 0xdd, /* 0xa0-0xa7 */ + 0xb9, 0xbd, 0xa6, 0xae, 0xaa, 0x00, 0xbe, 0xff, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0xfd, 0xfe, 0xba, 0xe6, 0xbc, 0xfa, /* 0xb0-0xb7 */ + 0x00, 0x00, 0xa7, 0xaf, 0xac, 0xab, 0x00, 0xa8, /* 0xb8-0xbf */ + 0xb6, 0x00, 0x00, 0xb7, 0x8e, 0x8f, 0x92, 0x80, /* 0xc0-0xc7 */ + 0x00, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0xa5, 0x00, 0x00, 0x00, 0xb8, 0x99, 0x00, /* 0xd0-0xd7 */ + 0xb2, 0x00, 0x00, 0x00, 0x9a, 0x00, 0x00, 0x9e, /* 0xd8-0xdf */ + 0x85, 0xa0, 0x83, 0xb0, 0x84, 0x86, 0x91, 0x87, /* 0xe0-0xe7 */ + 0x8a, 0x82, 0x88, 0x89, 0x8d, 0xa1, 0x8c, 0x8b, /* 0xe8-0xef */ + 0x00, 0xa4, 0x95, 0xa2, 0x93, 0xb1, 0x94, 0xf6, /* 0xf0-0xf7 */ + 0xb3, 0x97, 0xa3, 0x96, 0x81, 0x00, 0x00, 0x98, /* 0xf8-0xff */ +}; +static const unsigned char atarist_page01[104] = { + 0x00, 0x00, 0xc1, 0xc0, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0xb5, 0xb4, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x9f, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char atarist_page03[56] = { + 0x00, 0x00, 0x00, 0xe2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0xe9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x00, 0x00, 0x00, 0xe4, 0x00, 0x00, 0xe8, 0x00, /* 0xa0-0xa7 */ + 0x00, 0xea, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0xe0, 0xe1, 0x00, 0xeb, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0xe3, 0x00, 0x00, 0xe5, 0xe7, 0x00, 0xed, 0x00, /* 0xc0-0xc7 */ +}; +static const unsigned char atarist_page05[32] = { + 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, 0xc8, 0xc9, /* 0xd0-0xd7 */ + 0xca, 0xcb, 0xd9, 0xcc, 0xcd, 0xda, 0xce, 0xd8, /* 0xd8-0xdf */ + 0xcf, 0xd0, 0xd1, 0xdb, 0xd2, 0xdc, 0xd3, 0xd4, /* 0xe0-0xe7 */ + 0xd5, 0xd6, 0xd7, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ +}; +static const unsigned char atarist_page22[96] = { + 0xee, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0xf9, 0xfb, 0x00, 0x00, 0x00, 0xdf, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xde, /* 0x20-0x27 */ + 0x00, 0xef, 0x00, 0x00, 0x00, 0x00, 0xec, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xf7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0xf0, 0x00, 0x00, 0xf3, 0xf2, 0x00, 0x00, /* 0x60-0x67 */ +}; +static const unsigned char atarist_page23[24] = { + 0xa9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0xf4, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; + +static int +atarist_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = atarist_page00[wc-0x00a0]; + else if (wc >= 0x0130 && wc < 0x0198) + c = atarist_page01[wc-0x0130]; + else if (wc >= 0x0390 && wc < 0x03c8) + c = atarist_page03[wc-0x0390]; + else if (wc >= 0x05d0 && wc < 0x05f0) + c = atarist_page05[wc-0x05d0]; + else if (wc == 0x2020) + c = 0xbb; + else if (wc == 0x207f) + c = 0xfc; + else if (wc == 0x2122) + c = 0xbf; + else if (wc >= 0x2208 && wc < 0x2268) + c = atarist_page22[wc-0x2208]; + else if (wc >= 0x2310 && wc < 0x2328) + c = atarist_page23[wc-0x2310]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/big5.h b/graf2d/win32gdk/gdk/src/iconv/big5.h new file mode 100644 index 0000000000000..de10a99ae9a53 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/big5.h @@ -0,0 +1,4160 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * BIG5 + */ + +static const unsigned short big5_2uni_pagea1[6121] = { + /* 0xa1 */ + 0x3000, 0xff0c, 0x3001, 0x3002, 0xff0e, 0x2022, 0xff1b, 0xff1a, + 0xff1f, 0xff01, 0xfe30, 0x2026, 0x2025, 0xfe50, 0xff64, 0xfe52, + 0x00b7, 0xfe54, 0xfe55, 0xfe56, 0xfe57, 0xff5c, 0x2013, 0xfe31, + 0x2014, 0xfe33, 0xfffd, 0xfe34, 0xfe4f, 0xff08, 0xff09, 0xfe35, + 0xfe36, 0xff5b, 0xff5d, 0xfe37, 0xfe38, 0x3014, 0x3015, 0xfe39, + 0xfe3a, 0x3010, 0x3011, 0xfe3b, 0xfe3c, 0x300a, 0x300b, 0xfe3d, + 0xfe3e, 0x3008, 0x3009, 0xfe3f, 0xfe40, 0x300c, 0x300d, 0xfe41, + 0xfe42, 0x300e, 0x300f, 0xfe43, 0xfe44, 0xfe59, 0xfe5a, 0xfe5b, + 0xfe5c, 0xfe5d, 0xfe5e, 0x2018, 0x2019, 0x201c, 0x201d, 0x301d, + 0x301e, 0x2035, 0x2032, 0xff03, 0xff06, 0xff0a, 0x203b, 0x00a7, + 0x3003, 0x25cb, 0x25cf, 0x25b3, 0x25b2, 0x25ce, 0x2606, 0x2605, + 0x25c7, 0x25c6, 0x25a1, 0x25a0, 0x25bd, 0x25bc, 0x32a3, 0x2105, + 0x203e, 0xfffd, 0xff3f, 0xfffd, 0xfe49, 0xfe4a, 0xfe4d, 0xfe4e, + 0xfe4b, 0xfe4c, 0xfe5f, 0xfe60, 0xfe61, 0xff0b, 0xff0d, 0x00d7, + 0x00f7, 0x00b1, 0x221a, 0xff1c, 0xff1e, 0xff1d, 0x2266, 0x2267, + 0x2260, 0x221e, 0x2252, 0x2261, 0xfe62, 0xfe63, 0xfe64, 0xfe65, + 0xfe66, 0x223c, 0x2229, 0x222a, 0x22a5, 0x2220, 0x221f, 0x22bf, + 0x33d2, 0x33d1, 0x222b, 0x222e, 0x2235, 0x2234, 0x2640, 0x2642, + 0x2641, 0x2609, 0x2191, 0x2193, 0x2190, 0x2192, 0x2196, 0x2197, + 0x2199, 0x2198, 0x2225, 0x2223, 0xfffd, + /* 0xa2 */ + 0xfffd, 0xff0f, 0xff3c, 0xff04, 0x00a5, 0x3012, 0x00a2, 0x00a3, + 0xff05, 0xff20, 0x2103, 0x2109, 0xfe69, 0xfe6a, 0xfe6b, 0x33d5, + 0x339c, 0x339d, 0x339e, 0x33ce, 0x33a1, 0x338e, 0x338f, 0x33c4, + 0x00b0, 0x5159, 0x515b, 0x515e, 0x515d, 0x5161, 0x5163, 0x55e7, + 0x74e9, 0x7cce, 0x2581, 0x2582, 0x2583, 0x2584, 0x2585, 0x2586, + 0x2587, 0x2588, 0x258f, 0x258e, 0x258d, 0x258c, 0x258b, 0x258a, + 0x2589, 0x253c, 0x2534, 0x252c, 0x2524, 0x251c, 0x2594, 0x2500, + 0x2502, 0x2595, 0x250c, 0x2510, 0x2514, 0x2518, 0x256d, 0x256e, + 0x2570, 0x256f, 0x2550, 0x255e, 0x256a, 0x2561, 0x25e2, 0x25e3, + 0x25e5, 0x25e4, 0x2571, 0x2572, 0x2573, 0xff10, 0xff11, 0xff12, + 0xff13, 0xff14, 0xff15, 0xff16, 0xff17, 0xff18, 0xff19, 0x2160, + 0x2161, 0x2162, 0x2163, 0x2164, 0x2165, 0x2166, 0x2167, 0x2168, + 0x2169, 0x3021, 0x3022, 0x3023, 0x3024, 0x3025, 0x3026, 0x3027, + 0x3028, 0x3029, 0xfffd, 0x5344, 0xfffd, 0xff21, 0xff22, 0xff23, + 0xff24, 0xff25, 0xff26, 0xff27, 0xff28, 0xff29, 0xff2a, 0xff2b, + 0xff2c, 0xff2d, 0xff2e, 0xff2f, 0xff30, 0xff31, 0xff32, 0xff33, + 0xff34, 0xff35, 0xff36, 0xff37, 0xff38, 0xff39, 0xff3a, 0xff41, + 0xff42, 0xff43, 0xff44, 0xff45, 0xff46, 0xff47, 0xff48, 0xff49, + 0xff4a, 0xff4b, 0xff4c, 0xff4d, 0xff4e, 0xff4f, 0xff50, 0xff51, + 0xff52, 0xff53, 0xff54, 0xff55, 0xff56, + /* 0xa3 */ + 0xff57, 0xff58, 0xff59, 0xff5a, 0x0391, 0x0392, 0x0393, 0x0394, + 0x0395, 0x0396, 0x0397, 0x0398, 0x0399, 0x039a, 0x039b, 0x039c, + 0x039d, 0x039e, 0x039f, 0x03a0, 0x03a1, 0x03a3, 0x03a4, 0x03a5, + 0x03a6, 0x03a7, 0x03a8, 0x03a9, 0x03b1, 0x03b2, 0x03b3, 0x03b4, + 0x03b5, 0x03b6, 0x03b7, 0x03b8, 0x03b9, 0x03ba, 0x03bb, 0x03bc, + 0x03bd, 0x03be, 0x03bf, 0x03c0, 0x03c1, 0x03c3, 0x03c4, 0x03c5, + 0x03c6, 0x03c7, 0x03c8, 0x03c9, 0x3105, 0x3106, 0x3107, 0x3108, + 0x3109, 0x310a, 0x310b, 0x310c, 0x310d, 0x310e, 0x310f, 0x3110, + 0x3111, 0x3112, 0x3113, 0x3114, 0x3115, 0x3116, 0x3117, 0x3118, + 0x3119, 0x311a, 0x311b, 0x311c, 0x311d, 0x311e, 0x311f, 0x3120, + 0x3121, 0x3122, 0x3123, 0x3124, 0x3125, 0x3126, 0x3127, 0x3128, + 0x3129, 0x02d9, 0x02c9, 0x02ca, 0x02c7, 0x02cb, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xa4 */ + 0x4e00, 0x4e59, 0x4e01, 0x4e03, 0x4e43, 0x4e5d, 0x4e86, 0x4e8c, + 0x4eba, 0x513f, 0x5165, 0x516b, 0x51e0, 0x5200, 0x5201, 0x529b, + 0x5315, 0x5341, 0x535c, 0x53c8, 0x4e09, 0x4e0b, 0x4e08, 0x4e0a, + 0x4e2b, 0x4e38, 0x51e1, 0x4e45, 0x4e48, 0x4e5f, 0x4e5e, 0x4e8e, + 0x4ea1, 0x5140, 0x5203, 0x52fa, 0x5343, 0x53c9, 0x53e3, 0x571f, + 0x58eb, 0x5915, 0x5927, 0x5973, 0x5b50, 0x5b51, 0x5b53, 0x5bf8, + 0x5c0f, 0x5c22, 0x5c38, 0x5c71, 0x5ddd, 0x5de5, 0x5df1, 0x5df2, + 0x5df3, 0x5dfe, 0x5e72, 0x5efe, 0x5f0b, 0x5f13, 0x624d, 0x4e11, + 0x4e10, 0x4e0d, 0x4e2d, 0x4e30, 0x4e39, 0x4e4b, 0x5c39, 0x4e88, + 0x4e91, 0x4e95, 0x4e92, 0x4e94, 0x4ea2, 0x4ec1, 0x4ec0, 0x4ec3, + 0x4ec6, 0x4ec7, 0x4ecd, 0x4eca, 0x4ecb, 0x4ec4, 0x5143, 0x5141, + 0x5167, 0x516d, 0x516e, 0x516c, 0x5197, 0x51f6, 0x5206, 0x5207, + 0x5208, 0x52fb, 0x52fe, 0x52ff, 0x5316, 0x5339, 0x5348, 0x5347, + 0x5345, 0x535e, 0x5384, 0x53cb, 0x53ca, 0x53cd, 0x58ec, 0x5929, + 0x592b, 0x592a, 0x592d, 0x5b54, 0x5c11, 0x5c24, 0x5c3a, 0x5c6f, + 0x5df4, 0x5e7b, 0x5eff, 0x5f14, 0x5f15, 0x5fc3, 0x6208, 0x6236, + 0x624b, 0x624e, 0x652f, 0x6587, 0x6597, 0x65a4, 0x65b9, 0x65e5, + 0x66f0, 0x6708, 0x6728, 0x6b20, 0x6b62, 0x6b79, 0x6bcb, 0x6bd4, + 0x6bdb, 0x6c0f, 0x6c34, 0x706b, 0x722a, 0x7236, 0x723b, 0x7247, + 0x7259, 0x725b, 0x72ac, 0x738b, 0x4e19, + /* 0xa5 */ + 0x4e16, 0x4e15, 0x4e14, 0x4e18, 0x4e3b, 0x4e4d, 0x4e4f, 0x4e4e, + 0x4ee5, 0x4ed8, 0x4ed4, 0x4ed5, 0x4ed6, 0x4ed7, 0x4ee3, 0x4ee4, + 0x4ed9, 0x4ede, 0x5145, 0x5144, 0x5189, 0x518a, 0x51ac, 0x51f9, + 0x51fa, 0x51f8, 0x520a, 0x52a0, 0x529f, 0x5305, 0x5306, 0x5317, + 0x531d, 0x4edf, 0x534a, 0x5349, 0x5361, 0x5360, 0x536f, 0x536e, + 0x53bb, 0x53ef, 0x53e4, 0x53f3, 0x53ec, 0x53ee, 0x53e9, 0x53e8, + 0x53fc, 0x53f8, 0x53f5, 0x53eb, 0x53e6, 0x53ea, 0x53f2, 0x53f1, + 0x53f0, 0x53e5, 0x53ed, 0x53fb, 0x56db, 0x56da, 0x5916, 0x592e, + 0x5931, 0x5974, 0x5976, 0x5b55, 0x5b83, 0x5c3c, 0x5de8, 0x5de7, + 0x5de6, 0x5e02, 0x5e03, 0x5e73, 0x5e7c, 0x5f01, 0x5f18, 0x5f17, + 0x5fc5, 0x620a, 0x6253, 0x6254, 0x6252, 0x6251, 0x65a5, 0x65e6, + 0x672e, 0x672c, 0x672a, 0x672b, 0x672d, 0x6b63, 0x6bcd, 0x6c11, + 0x6c10, 0x6c38, 0x6c41, 0x6c40, 0x6c3e, 0x72af, 0x7384, 0x7389, + 0x74dc, 0x74e6, 0x7518, 0x751f, 0x7528, 0x7529, 0x7530, 0x7531, + 0x7532, 0x7533, 0x758b, 0x767d, 0x76ae, 0x76bf, 0x76ee, 0x77db, + 0x77e2, 0x77f3, 0x793a, 0x79be, 0x7a74, 0x7acb, 0x4e1e, 0x4e1f, + 0x4e52, 0x4e53, 0x4e69, 0x4e99, 0x4ea4, 0x4ea6, 0x4ea5, 0x4eff, + 0x4f09, 0x4f19, 0x4f0a, 0x4f15, 0x4f0d, 0x4f10, 0x4f11, 0x4f0f, + 0x4ef2, 0x4ef6, 0x4efb, 0x4ef0, 0x4ef3, 0x4efd, 0x4f01, 0x4f0b, + 0x5149, 0x5147, 0x5146, 0x5148, 0x5168, + /* 0xa6 */ + 0x5171, 0x518d, 0x51b0, 0x5217, 0x5211, 0x5212, 0x520e, 0x5216, + 0x52a3, 0x5308, 0x5321, 0x5320, 0x5370, 0x5371, 0x5409, 0x540f, + 0x540c, 0x540a, 0x5410, 0x5401, 0x540b, 0x5404, 0x5411, 0x540d, + 0x5408, 0x5403, 0x540e, 0x5406, 0x5412, 0x56e0, 0x56de, 0x56dd, + 0x5733, 0x5730, 0x5728, 0x572d, 0x572c, 0x572f, 0x5729, 0x5919, + 0x591a, 0x5937, 0x5938, 0x5984, 0x5978, 0x5983, 0x597d, 0x5979, + 0x5982, 0x5981, 0x5b57, 0x5b58, 0x5b87, 0x5b88, 0x5b85, 0x5b89, + 0x5bfa, 0x5c16, 0x5c79, 0x5dde, 0x5e06, 0x5e76, 0x5e74, 0x5f0f, + 0x5f1b, 0x5fd9, 0x5fd6, 0x620e, 0x620c, 0x620d, 0x6210, 0x6263, + 0x625b, 0x6258, 0x6536, 0x65e9, 0x65e8, 0x65ec, 0x65ed, 0x66f2, + 0x66f3, 0x6709, 0x673d, 0x6734, 0x6731, 0x6735, 0x6b21, 0x6b64, + 0x6b7b, 0x6c16, 0x6c5d, 0x6c57, 0x6c59, 0x6c5f, 0x6c60, 0x6c50, + 0x6c55, 0x6c61, 0x6c5b, 0x6c4d, 0x6c4e, 0x7070, 0x725f, 0x725d, + 0x767e, 0x7af9, 0x7c73, 0x7cf8, 0x7f36, 0x7f8a, 0x7fbd, 0x8001, + 0x8003, 0x800c, 0x8012, 0x8033, 0x807f, 0x8089, 0x808b, 0x808c, + 0x81e3, 0x81ea, 0x81f3, 0x81fc, 0x820c, 0x821b, 0x821f, 0x826e, + 0x8272, 0x827e, 0x866b, 0x8840, 0x884c, 0x8863, 0x897f, 0x9621, + 0x4e32, 0x4ea8, 0x4f4d, 0x4f4f, 0x4f47, 0x4f57, 0x4f5e, 0x4f34, + 0x4f5b, 0x4f55, 0x4f30, 0x4f50, 0x4f51, 0x4f3d, 0x4f3a, 0x4f38, + 0x4f43, 0x4f54, 0x4f3c, 0x4f46, 0x4f63, + /* 0xa7 */ + 0x4f5c, 0x4f60, 0x4f2f, 0x4f4e, 0x4f36, 0x4f59, 0x4f5d, 0x4f48, + 0x4f5a, 0x514c, 0x514b, 0x514d, 0x5175, 0x51b6, 0x51b7, 0x5225, + 0x5224, 0x5229, 0x522a, 0x5228, 0x52ab, 0x52a9, 0x52aa, 0x52ac, + 0x5323, 0x5373, 0x5375, 0x541d, 0x542d, 0x541e, 0x543e, 0x5426, + 0x544e, 0x5427, 0x5446, 0x5443, 0x5433, 0x5448, 0x5442, 0x541b, + 0x5429, 0x544a, 0x5439, 0x543b, 0x5438, 0x542e, 0x5435, 0x5436, + 0x5420, 0x543c, 0x5440, 0x5431, 0x542b, 0x541f, 0x542c, 0x56ea, + 0x56f0, 0x56e4, 0x56eb, 0x574a, 0x5751, 0x5740, 0x574d, 0x5747, + 0x574e, 0x573e, 0x5750, 0x574f, 0x573b, 0x58ef, 0x593e, 0x599d, + 0x5992, 0x59a8, 0x599e, 0x59a3, 0x5999, 0x5996, 0x598d, 0x59a4, + 0x5993, 0x598a, 0x59a5, 0x5b5d, 0x5b5c, 0x5b5a, 0x5b5b, 0x5b8c, + 0x5b8b, 0x5b8f, 0x5c2c, 0x5c40, 0x5c41, 0x5c3f, 0x5c3e, 0x5c90, + 0x5c91, 0x5c94, 0x5c8c, 0x5deb, 0x5e0c, 0x5e8f, 0x5e87, 0x5e8a, + 0x5ef7, 0x5f04, 0x5f1f, 0x5f64, 0x5f62, 0x5f77, 0x5f79, 0x5fd8, + 0x5fcc, 0x5fd7, 0x5fcd, 0x5ff1, 0x5feb, 0x5ff8, 0x5fea, 0x6212, + 0x6211, 0x6284, 0x6297, 0x6296, 0x6280, 0x6276, 0x6289, 0x626d, + 0x628a, 0x627c, 0x627e, 0x6279, 0x6273, 0x6292, 0x626f, 0x6298, + 0x626e, 0x6295, 0x6293, 0x6291, 0x6286, 0x6539, 0x653b, 0x6538, + 0x65f1, 0x66f4, 0x675f, 0x674e, 0x674f, 0x6750, 0x6751, 0x675c, + 0x6756, 0x675e, 0x6749, 0x6746, 0x6760, + /* 0xa8 */ + 0x6753, 0x6757, 0x6b65, 0x6bcf, 0x6c42, 0x6c5e, 0x6c99, 0x6c81, + 0x6c88, 0x6c89, 0x6c85, 0x6c9b, 0x6c6a, 0x6c7a, 0x6c90, 0x6c70, + 0x6c8c, 0x6c68, 0x6c96, 0x6c92, 0x6c7d, 0x6c83, 0x6c72, 0x6c7e, + 0x6c74, 0x6c86, 0x6c76, 0x6c8d, 0x6c94, 0x6c98, 0x6c82, 0x7076, + 0x707c, 0x707d, 0x7078, 0x7262, 0x7261, 0x7260, 0x72c4, 0x72c2, + 0x7396, 0x752c, 0x752b, 0x7537, 0x7538, 0x7682, 0x76ef, 0x77e3, + 0x79c1, 0x79c0, 0x79bf, 0x7a76, 0x7cfb, 0x7f55, 0x8096, 0x8093, + 0x809d, 0x8098, 0x809b, 0x809a, 0x80b2, 0x826f, 0x8292, 0x828b, + 0x828d, 0x898b, 0x89d2, 0x8a00, 0x8c37, 0x8c46, 0x8c55, 0x8c9d, + 0x8d64, 0x8d70, 0x8db3, 0x8eab, 0x8eca, 0x8f9b, 0x8fb0, 0x8fc2, + 0x8fc6, 0x8fc5, 0x8fc4, 0x5de1, 0x9091, 0x90a2, 0x90aa, 0x90a6, + 0x90a3, 0x9149, 0x91c6, 0x91cc, 0x9632, 0x962e, 0x9631, 0x962a, + 0x962c, 0x4e26, 0x4e56, 0x4e73, 0x4e8b, 0x4e9b, 0x4e9e, 0x4eab, + 0x4eac, 0x4f6f, 0x4f9d, 0x4f8d, 0x4f73, 0x4f7f, 0x4f6c, 0x4f9b, + 0x4f8b, 0x4f86, 0x4f83, 0x4f70, 0x4f75, 0x4f88, 0x4f69, 0x4f7b, + 0x4f96, 0x4f7e, 0x4f8f, 0x4f91, 0x4f7a, 0x5154, 0x5152, 0x5155, + 0x5169, 0x5177, 0x5176, 0x5178, 0x51bd, 0x51fd, 0x523b, 0x5238, + 0x5237, 0x523a, 0x5230, 0x522e, 0x5236, 0x5241, 0x52be, 0x52bb, + 0x5352, 0x5354, 0x5353, 0x5351, 0x5366, 0x5377, 0x5378, 0x5379, + 0x53d6, 0x53d4, 0x53d7, 0x5473, 0x5475, + /* 0xa9 */ + 0x5496, 0x5478, 0x5495, 0x5480, 0x547b, 0x5477, 0x5484, 0x5492, + 0x5486, 0x547c, 0x5490, 0x5471, 0x5476, 0x548c, 0x549a, 0x5462, + 0x5468, 0x548b, 0x547d, 0x548e, 0x56fa, 0x5783, 0x5777, 0x576a, + 0x5769, 0x5761, 0x5766, 0x5764, 0x577c, 0x591c, 0x5949, 0x5947, + 0x5948, 0x5944, 0x5954, 0x59be, 0x59bb, 0x59d4, 0x59b9, 0x59ae, + 0x59d1, 0x59c6, 0x59d0, 0x59cd, 0x59cb, 0x59d3, 0x59ca, 0x59af, + 0x59b3, 0x59d2, 0x59c5, 0x5b5f, 0x5b64, 0x5b63, 0x5b97, 0x5b9a, + 0x5b98, 0x5b9c, 0x5b99, 0x5b9b, 0x5c1a, 0x5c48, 0x5c45, 0x5c46, + 0x5cb7, 0x5ca1, 0x5cb8, 0x5ca9, 0x5cab, 0x5cb1, 0x5cb3, 0x5e18, + 0x5e1a, 0x5e16, 0x5e15, 0x5e1b, 0x5e11, 0x5e78, 0x5e9a, 0x5e97, + 0x5e9c, 0x5e95, 0x5e96, 0x5ef6, 0x5f26, 0x5f27, 0x5f29, 0x5f80, + 0x5f81, 0x5f7f, 0x5f7c, 0x5fdd, 0x5fe0, 0x5ffd, 0x5ff5, 0x5fff, + 0x600f, 0x6014, 0x602f, 0x6035, 0x6016, 0x602a, 0x6015, 0x6021, + 0x6027, 0x6029, 0x602b, 0x601b, 0x6216, 0x6215, 0x623f, 0x623e, + 0x6240, 0x627f, 0x62c9, 0x62cc, 0x62c4, 0x62bf, 0x62c2, 0x62b9, + 0x62d2, 0x62db, 0x62ab, 0x62d3, 0x62d4, 0x62cb, 0x62c8, 0x62a8, + 0x62bd, 0x62bc, 0x62d0, 0x62d9, 0x62c7, 0x62cd, 0x62b5, 0x62da, + 0x62b1, 0x62d8, 0x62d6, 0x62d7, 0x62c6, 0x62ac, 0x62ce, 0x653e, + 0x65a7, 0x65bc, 0x65fa, 0x6614, 0x6613, 0x660c, 0x6606, 0x6602, + 0x660e, 0x6600, 0x660f, 0x6615, 0x660a, + /* 0xaa */ + 0x6607, 0x670d, 0x670b, 0x676d, 0x678b, 0x6795, 0x6771, 0x679c, + 0x6773, 0x6777, 0x6787, 0x679d, 0x6797, 0x676f, 0x6770, 0x677f, + 0x6789, 0x677e, 0x6790, 0x6775, 0x679a, 0x6793, 0x677c, 0x676a, + 0x6772, 0x6b23, 0x6b66, 0x6b67, 0x6b7f, 0x6c13, 0x6c1b, 0x6ce3, + 0x6ce8, 0x6cf3, 0x6cb1, 0x6ccc, 0x6ce5, 0x6cb3, 0x6cbd, 0x6cbe, + 0x6cbc, 0x6ce2, 0x6cab, 0x6cd5, 0x6cd3, 0x6cb8, 0x6cc4, 0x6cb9, + 0x6cc1, 0x6cae, 0x6cd7, 0x6cc5, 0x6cf1, 0x6cbf, 0x6cbb, 0x6ce1, + 0x6cdb, 0x6cca, 0x6cac, 0x6cef, 0x6cdc, 0x6cd6, 0x6ce0, 0x7095, + 0x708e, 0x7092, 0x708a, 0x7099, 0x722c, 0x722d, 0x7238, 0x7248, + 0x7267, 0x7269, 0x72c0, 0x72ce, 0x72d9, 0x72d7, 0x72d0, 0x73a9, + 0x73a8, 0x739f, 0x73ab, 0x73a5, 0x753d, 0x759d, 0x7599, 0x759a, + 0x7684, 0x76c2, 0x76f2, 0x76f4, 0x77e5, 0x77fd, 0x793e, 0x7940, + 0x7941, 0x79c9, 0x79c8, 0x7a7a, 0x7a79, 0x7afa, 0x7cfe, 0x7f54, + 0x7f8c, 0x7f8b, 0x8005, 0x80ba, 0x80a5, 0x80a2, 0x80b1, 0x80a1, + 0x80ab, 0x80a9, 0x80b4, 0x80aa, 0x80af, 0x81e5, 0x81fe, 0x820d, + 0x82b3, 0x829d, 0x8299, 0x82ad, 0x82bd, 0x829f, 0x82b9, 0x82b1, + 0x82ac, 0x82a5, 0x82af, 0x82b8, 0x82a3, 0x82b0, 0x82be, 0x82b7, + 0x864e, 0x8671, 0x521d, 0x8868, 0x8ecb, 0x8fce, 0x8fd4, 0x8fd1, + 0x90b5, 0x90b8, 0x90b1, 0x90b6, 0x91c7, 0x91d1, 0x9577, 0x9580, + 0x961c, 0x9640, 0x963f, 0x963b, 0x9644, + /* 0xab */ + 0x9642, 0x96b9, 0x96e8, 0x9752, 0x975e, 0x4e9f, 0x4ead, 0x4eae, + 0x4fe1, 0x4fb5, 0x4faf, 0x4fbf, 0x4fe0, 0x4fd1, 0x4fcf, 0x4fdd, + 0x4fc3, 0x4fb6, 0x4fd8, 0x4fdf, 0x4fca, 0x4fd7, 0x4fae, 0x4fd0, + 0x4fc4, 0x4fc2, 0x4fda, 0x4fce, 0x4fde, 0x4fb7, 0x5157, 0x5192, + 0x5191, 0x51a0, 0x524e, 0x5243, 0x524a, 0x524d, 0x524c, 0x524b, + 0x5247, 0x52c7, 0x52c9, 0x52c3, 0x52c1, 0x530d, 0x5357, 0x537b, + 0x539a, 0x53db, 0x54ac, 0x54c0, 0x54a8, 0x54ce, 0x54c9, 0x54b8, + 0x54a6, 0x54b3, 0x54c7, 0x54c2, 0x54bd, 0x54aa, 0x54c1, 0x54c4, + 0x54c8, 0x54af, 0x54ab, 0x54b1, 0x54bb, 0x54a9, 0x54a7, 0x54bf, + 0x56ff, 0x5782, 0x578b, 0x57a0, 0x57a3, 0x57a2, 0x57ce, 0x57ae, + 0x5793, 0x5955, 0x5951, 0x594f, 0x594e, 0x5950, 0x59dc, 0x59d8, + 0x59ff, 0x59e3, 0x59e8, 0x5a03, 0x59e5, 0x59ea, 0x59da, 0x59e6, + 0x5a01, 0x59fb, 0x5b69, 0x5ba3, 0x5ba6, 0x5ba4, 0x5ba2, 0x5ba5, + 0x5c01, 0x5c4e, 0x5c4f, 0x5c4d, 0x5c4b, 0x5cd9, 0x5cd2, 0x5df7, + 0x5e1d, 0x5e25, 0x5e1f, 0x5e7d, 0x5ea0, 0x5ea6, 0x5efa, 0x5f08, + 0x5f2d, 0x5f65, 0x5f88, 0x5f85, 0x5f8a, 0x5f8b, 0x5f87, 0x5f8c, + 0x5f89, 0x6012, 0x601d, 0x6020, 0x6025, 0x600e, 0x6028, 0x604d, + 0x6070, 0x6068, 0x6062, 0x6046, 0x6043, 0x606c, 0x606b, 0x606a, + 0x6064, 0x6241, 0x62dc, 0x6316, 0x6309, 0x62fc, 0x62ed, 0x6301, + 0x62ee, 0x62fd, 0x6307, 0x62f1, 0x62f7, + /* 0xac */ + 0x62ef, 0x62ec, 0x62fe, 0x62f4, 0x6311, 0x6302, 0x653f, 0x6545, + 0x65ab, 0x65bd, 0x65e2, 0x6625, 0x662d, 0x6620, 0x6627, 0x662f, + 0x661f, 0x6628, 0x6631, 0x6624, 0x66f7, 0x67ff, 0x67d3, 0x67f1, + 0x67d4, 0x67d0, 0x67ec, 0x67b6, 0x67af, 0x67f5, 0x67e9, 0x67ef, + 0x67c4, 0x67d1, 0x67b4, 0x67da, 0x67e5, 0x67b8, 0x67cf, 0x67de, + 0x67f3, 0x67b0, 0x67d9, 0x67e2, 0x67dd, 0x67d2, 0x6b6a, 0x6b83, + 0x6b86, 0x6bb5, 0x6bd2, 0x6bd7, 0x6c1f, 0x6cc9, 0x6d0b, 0x6d32, + 0x6d2a, 0x6d41, 0x6d25, 0x6d0c, 0x6d31, 0x6d1e, 0x6d17, 0x6d3b, + 0x6d3d, 0x6d3e, 0x6d36, 0x6d1b, 0x6cf5, 0x6d39, 0x6d27, 0x6d38, + 0x6d29, 0x6d2e, 0x6d35, 0x6d0e, 0x6d2b, 0x70ab, 0x70ba, 0x70b3, + 0x70ac, 0x70af, 0x70ad, 0x70b8, 0x70ae, 0x70a4, 0x7230, 0x7272, + 0x726f, 0x7274, 0x72e9, 0x72e0, 0x72e1, 0x73b7, 0x73ca, 0x73bb, + 0x73b2, 0x73cd, 0x73c0, 0x73b3, 0x751a, 0x752d, 0x754f, 0x754c, + 0x754e, 0x754b, 0x75ab, 0x75a4, 0x75a5, 0x75a2, 0x75a3, 0x7678, + 0x7686, 0x7687, 0x7688, 0x76c8, 0x76c6, 0x76c3, 0x76c5, 0x7701, + 0x76f9, 0x76f8, 0x7709, 0x770b, 0x76fe, 0x76fc, 0x7707, 0x77dc, + 0x7802, 0x7814, 0x780c, 0x780d, 0x7946, 0x7949, 0x7948, 0x7947, + 0x79b9, 0x79ba, 0x79d1, 0x79d2, 0x79cb, 0x7a7f, 0x7a81, 0x7aff, + 0x7afd, 0x7c7d, 0x7d02, 0x7d05, 0x7d00, 0x7d09, 0x7d07, 0x7d04, + 0x7d06, 0x7f38, 0x7f8e, 0x7fbf, 0x8004, + /* 0xad */ + 0x8010, 0x800d, 0x8011, 0x8036, 0x80d6, 0x80e5, 0x80da, 0x80c3, + 0x80c4, 0x80cc, 0x80e1, 0x80db, 0x80ce, 0x80de, 0x80e4, 0x80dd, + 0x81f4, 0x8222, 0x82e7, 0x8303, 0x8305, 0x82e3, 0x82db, 0x82e6, + 0x8304, 0x82e5, 0x8302, 0x8309, 0x82d2, 0x82d7, 0x82f1, 0x8301, + 0x82dc, 0x82d4, 0x82d1, 0x82de, 0x82d3, 0x82df, 0x82ef, 0x8306, + 0x8650, 0x8679, 0x867b, 0x867a, 0x884d, 0x886b, 0x8981, 0x89d4, + 0x8a08, 0x8a02, 0x8a03, 0x8c9e, 0x8ca0, 0x8d74, 0x8d73, 0x8db4, + 0x8ecd, 0x8ecc, 0x8ff0, 0x8fe6, 0x8fe2, 0x8fea, 0x8fe5, 0x8fed, + 0x8feb, 0x8fe4, 0x8fe8, 0x90ca, 0x90ce, 0x90c1, 0x90c3, 0x914b, + 0x914a, 0x91cd, 0x9582, 0x9650, 0x964b, 0x964c, 0x964d, 0x9762, + 0x9769, 0x97cb, 0x97ed, 0x97f3, 0x9801, 0x98a8, 0x98db, 0x98df, + 0x9996, 0x9999, 0x4e58, 0x4eb3, 0x500c, 0x500d, 0x5023, 0x4fef, + 0x5026, 0x5025, 0x4ff8, 0x5029, 0x5016, 0x5006, 0x503c, 0x501f, + 0x501a, 0x5012, 0x5011, 0x4ffa, 0x5000, 0x5014, 0x5028, 0x4ff1, + 0x5021, 0x500b, 0x5019, 0x5018, 0x4ff3, 0x4fee, 0x502d, 0x502a, + 0x4ffe, 0x502b, 0x5009, 0x517c, 0x51a4, 0x51a5, 0x51a2, 0x51cd, + 0x51cc, 0x51c6, 0x51cb, 0x5256, 0x525c, 0x5254, 0x525b, 0x525d, + 0x532a, 0x537f, 0x539f, 0x539d, 0x53df, 0x54e8, 0x5510, 0x5501, + 0x5537, 0x54fc, 0x54e5, 0x54f2, 0x5506, 0x54fa, 0x5514, 0x54e9, + 0x54ed, 0x54e1, 0x5509, 0x54ee, 0x54ea, + /* 0xae */ + 0x54e6, 0x5527, 0x5507, 0x54fd, 0x550f, 0x5703, 0x5704, 0x57c2, + 0x57d4, 0x57cb, 0x57c3, 0x5809, 0x590f, 0x5957, 0x5958, 0x595a, + 0x5a11, 0x5a18, 0x5a1c, 0x5a1f, 0x5a1b, 0x5a13, 0x59ec, 0x5a20, + 0x5a23, 0x5a29, 0x5a25, 0x5a0c, 0x5a09, 0x5b6b, 0x5c58, 0x5bb0, + 0x5bb3, 0x5bb6, 0x5bb4, 0x5bae, 0x5bb5, 0x5bb9, 0x5bb8, 0x5c04, + 0x5c51, 0x5c55, 0x5c50, 0x5ced, 0x5cfd, 0x5cfb, 0x5cea, 0x5ce8, + 0x5cf0, 0x5cf6, 0x5d01, 0x5cf4, 0x5dee, 0x5e2d, 0x5e2b, 0x5eab, + 0x5ead, 0x5ea7, 0x5f31, 0x5f92, 0x5f91, 0x5f90, 0x6059, 0x6063, + 0x6065, 0x6050, 0x6055, 0x606d, 0x6069, 0x606f, 0x6084, 0x609f, + 0x609a, 0x608d, 0x6094, 0x608c, 0x6085, 0x6096, 0x6247, 0x62f3, + 0x6308, 0x62ff, 0x634e, 0x633e, 0x632f, 0x6355, 0x6342, 0x6346, + 0x634f, 0x6349, 0x633a, 0x6350, 0x633d, 0x632a, 0x632b, 0x6328, + 0x634d, 0x634c, 0x6548, 0x6549, 0x6599, 0x65c1, 0x65c5, 0x6642, + 0x6649, 0x664f, 0x6643, 0x6652, 0x664c, 0x6645, 0x6641, 0x66f8, + 0x6714, 0x6715, 0x6717, 0x6821, 0x6838, 0x6848, 0x6846, 0x6853, + 0x6839, 0x6842, 0x6854, 0x6829, 0x68b3, 0x6817, 0x684c, 0x6851, + 0x683d, 0x67f4, 0x6850, 0x6840, 0x683c, 0x6843, 0x682a, 0x6845, + 0x6813, 0x6818, 0x6841, 0x6b8a, 0x6b89, 0x6bb7, 0x6c23, 0x6c27, + 0x6c28, 0x6c26, 0x6c24, 0x6cf0, 0x6d6a, 0x6d95, 0x6d88, 0x6d87, + 0x6d66, 0x6d78, 0x6d77, 0x6d59, 0x6d93, + /* 0xaf */ + 0x6d6c, 0x6d89, 0x6d6e, 0x6d5a, 0x6d74, 0x6d69, 0x6d8c, 0x6d8a, + 0x6d79, 0x6d85, 0x6d65, 0x6d94, 0x70ca, 0x70d8, 0x70e4, 0x70d9, + 0x70c8, 0x70cf, 0x7239, 0x7279, 0x72fc, 0x72f9, 0x72fd, 0x72f8, + 0x72f7, 0x7386, 0x73ed, 0x7409, 0x73ee, 0x73e0, 0x73ea, 0x73de, + 0x7554, 0x755d, 0x755c, 0x755a, 0x7559, 0x75be, 0x75c5, 0x75c7, + 0x75b2, 0x75b3, 0x75bd, 0x75bc, 0x75b9, 0x75c2, 0x75b8, 0x768b, + 0x76b0, 0x76ca, 0x76cd, 0x76ce, 0x7729, 0x771f, 0x7720, 0x7728, + 0x77e9, 0x7830, 0x7827, 0x7838, 0x781d, 0x7834, 0x7837, 0x7825, + 0x782d, 0x7820, 0x781f, 0x7832, 0x7955, 0x7950, 0x7960, 0x795f, + 0x7956, 0x795e, 0x795d, 0x7957, 0x795a, 0x79e4, 0x79e3, 0x79e7, + 0x79df, 0x79e6, 0x79e9, 0x79d8, 0x7a84, 0x7a88, 0x7ad9, 0x7b06, + 0x7b11, 0x7c89, 0x7d21, 0x7d17, 0x7d0b, 0x7d0a, 0x7d20, 0x7d22, + 0x7d14, 0x7d10, 0x7d15, 0x7d1a, 0x7d1c, 0x7d0d, 0x7d19, 0x7d1b, + 0x7f3a, 0x7f5f, 0x7f94, 0x7fc5, 0x7fc1, 0x8006, 0x8018, 0x8015, + 0x8019, 0x8017, 0x803d, 0x803f, 0x80f1, 0x8102, 0x80f0, 0x8105, + 0x80ed, 0x80f4, 0x8106, 0x80f8, 0x80f3, 0x8108, 0x80fd, 0x810a, + 0x80fc, 0x80ef, 0x81ed, 0x81ec, 0x8200, 0x8210, 0x822a, 0x822b, + 0x8228, 0x822c, 0x82bb, 0x832b, 0x8352, 0x8354, 0x834a, 0x8338, + 0x8350, 0x8349, 0x8335, 0x8334, 0x834f, 0x8332, 0x8339, 0x8336, + 0x8317, 0x8340, 0x8331, 0x8328, 0x8343, + /* 0xb0 */ + 0x8654, 0x868a, 0x86aa, 0x8693, 0x86a4, 0x86a9, 0x868c, 0x86a3, + 0x869c, 0x8870, 0x8877, 0x8881, 0x8882, 0x887d, 0x8879, 0x8a18, + 0x8a10, 0x8a0e, 0x8a0c, 0x8a15, 0x8a0a, 0x8a17, 0x8a13, 0x8a16, + 0x8a0f, 0x8a11, 0x8c48, 0x8c7a, 0x8c79, 0x8ca1, 0x8ca2, 0x8d77, + 0x8eac, 0x8ed2, 0x8ed4, 0x8ecf, 0x8fb1, 0x9001, 0x9006, 0x8ff7, + 0x9000, 0x8ffa, 0x8ff4, 0x9003, 0x8ffd, 0x9005, 0x8ff8, 0x9095, + 0x90e1, 0x90dd, 0x90e2, 0x9152, 0x914d, 0x914c, 0x91d8, 0x91dd, + 0x91d7, 0x91dc, 0x91d9, 0x9583, 0x9662, 0x9663, 0x9661, 0x965b, + 0x965d, 0x9664, 0x9658, 0x965e, 0x96bb, 0x98e2, 0x99ac, 0x9aa8, + 0x9ad8, 0x9b25, 0x9b32, 0x9b3c, 0x4e7e, 0x507a, 0x507d, 0x505c, + 0x5047, 0x5043, 0x504c, 0x505a, 0x5049, 0x5065, 0x5076, 0x504e, + 0x5055, 0x5075, 0x5074, 0x5077, 0x504f, 0x500f, 0x506f, 0x506d, + 0x515c, 0x5195, 0x51f0, 0x526a, 0x526f, 0x52d2, 0x52d9, 0x52d8, + 0x52d5, 0x5310, 0x530f, 0x5319, 0x533f, 0x5340, 0x533e, 0x53c3, + 0x66fc, 0x5546, 0x556a, 0x5566, 0x5544, 0x555e, 0x5561, 0x5543, + 0x554a, 0x5531, 0x5556, 0x554f, 0x5555, 0x552f, 0x5564, 0x5538, + 0x552e, 0x555c, 0x552c, 0x5563, 0x5533, 0x5541, 0x5557, 0x5708, + 0x570b, 0x5709, 0x57df, 0x5805, 0x580a, 0x5806, 0x57e0, 0x57e4, + 0x57fa, 0x5802, 0x5835, 0x57f7, 0x57f9, 0x5920, 0x5962, 0x5a36, + 0x5a41, 0x5a49, 0x5a66, 0x5a6a, 0x5a40, + /* 0xb1 */ + 0x5a3c, 0x5a62, 0x5a5a, 0x5a46, 0x5a4a, 0x5b70, 0x5bc7, 0x5bc5, + 0x5bc4, 0x5bc2, 0x5bbf, 0x5bc6, 0x5c09, 0x5c08, 0x5c07, 0x5c60, + 0x5c5c, 0x5c5d, 0x5d07, 0x5d06, 0x5d0e, 0x5d1b, 0x5d16, 0x5d22, + 0x5d11, 0x5d29, 0x5d14, 0x5d19, 0x5d24, 0x5d27, 0x5d17, 0x5de2, + 0x5e38, 0x5e36, 0x5e33, 0x5e37, 0x5eb7, 0x5eb8, 0x5eb6, 0x5eb5, + 0x5ebe, 0x5f35, 0x5f37, 0x5f57, 0x5f6c, 0x5f69, 0x5f6b, 0x5f97, + 0x5f99, 0x5f9e, 0x5f98, 0x5fa1, 0x5fa0, 0x5f9c, 0x607f, 0x60a3, + 0x6089, 0x60a0, 0x60a8, 0x60cb, 0x60b4, 0x60e6, 0x60bd, 0x60c5, + 0x60bb, 0x60b5, 0x60dc, 0x60bc, 0x60d8, 0x60d5, 0x60c6, 0x60df, + 0x60b8, 0x60da, 0x60c7, 0x621a, 0x621b, 0x6248, 0x63a0, 0x63a7, + 0x6372, 0x6396, 0x63a2, 0x63a5, 0x6377, 0x6367, 0x6398, 0x63aa, + 0x6371, 0x63a9, 0x6389, 0x6383, 0x639b, 0x636b, 0x63a8, 0x6384, + 0x6388, 0x6399, 0x63a1, 0x63ac, 0x6392, 0x638f, 0x6380, 0x637b, + 0x6369, 0x6368, 0x637a, 0x655d, 0x6556, 0x6551, 0x6559, 0x6557, + 0x555f, 0x654f, 0x6558, 0x6555, 0x6554, 0x659c, 0x659b, 0x65ac, + 0x65cf, 0x65cb, 0x65cc, 0x65ce, 0x665d, 0x665a, 0x6664, 0x6668, + 0x6666, 0x665e, 0x66f9, 0x52d7, 0x671b, 0x6881, 0x68af, 0x68a2, + 0x6893, 0x68b5, 0x687f, 0x6876, 0x68b1, 0x68a7, 0x6897, 0x68b0, + 0x6883, 0x68c4, 0x68ad, 0x6886, 0x6885, 0x6894, 0x689d, 0x68a8, + 0x689f, 0x68a1, 0x6882, 0x6b32, 0x6bba, + /* 0xb2 */ + 0x6beb, 0x6bec, 0x6c2b, 0x6d8e, 0x6dbc, 0x6df3, 0x6dd9, 0x6db2, + 0x6de1, 0x6dcc, 0x6de4, 0x6dfb, 0x6dfa, 0x6e05, 0x6dc7, 0x6dcb, + 0x6daf, 0x6dd1, 0x6dae, 0x6dde, 0x6df9, 0x6db8, 0x6df7, 0x6df5, + 0x6dc5, 0x6dd2, 0x6e1a, 0x6db5, 0x6dda, 0x6deb, 0x6dd8, 0x6dea, + 0x6df1, 0x6dee, 0x6de8, 0x6dc6, 0x6dc4, 0x6daa, 0x6dec, 0x6dbf, + 0x6de6, 0x70f9, 0x7109, 0x710a, 0x70fd, 0x70ef, 0x723d, 0x727d, + 0x7281, 0x731c, 0x731b, 0x7316, 0x7313, 0x7319, 0x7387, 0x7405, + 0x740a, 0x7403, 0x7406, 0x73fe, 0x740d, 0x74e0, 0x74f6, 0x74f7, + 0x751c, 0x7522, 0x7565, 0x7566, 0x7562, 0x7570, 0x758f, 0x75d4, + 0x75d5, 0x75b5, 0x75ca, 0x75cd, 0x768e, 0x76d4, 0x76d2, 0x76db, + 0x7737, 0x773e, 0x773c, 0x7736, 0x7738, 0x773a, 0x786b, 0x7843, + 0x784e, 0x7965, 0x7968, 0x796d, 0x79fb, 0x7a92, 0x7a95, 0x7b20, + 0x7b28, 0x7b1b, 0x7b2c, 0x7b26, 0x7b19, 0x7b1e, 0x7b2e, 0x7c92, + 0x7c97, 0x7c95, 0x7d46, 0x7d43, 0x7d71, 0x7d2e, 0x7d39, 0x7d3c, + 0x7d40, 0x7d30, 0x7d33, 0x7d44, 0x7d2f, 0x7d42, 0x7d32, 0x7d31, + 0x7f3d, 0x7f9e, 0x7f9a, 0x7fcc, 0x7fce, 0x7fd2, 0x801c, 0x804a, + 0x8046, 0x812f, 0x8116, 0x8123, 0x812b, 0x8129, 0x8130, 0x8124, + 0x8202, 0x8235, 0x8237, 0x8236, 0x8239, 0x838e, 0x839e, 0x8398, + 0x8378, 0x83a2, 0x8396, 0x83bd, 0x83ab, 0x8392, 0x838a, 0x8393, + 0x8389, 0x83a0, 0x8377, 0x837b, 0x837c, + /* 0xb3 */ + 0x8386, 0x83a7, 0x8655, 0x5f6a, 0x86c7, 0x86c0, 0x86b6, 0x86c4, + 0x86b5, 0x86c6, 0x86cb, 0x86b1, 0x86af, 0x86c9, 0x8853, 0x889e, + 0x8888, 0x88ab, 0x8892, 0x8896, 0x888d, 0x888b, 0x8993, 0x898f, + 0x8a2a, 0x8a1d, 0x8a23, 0x8a25, 0x8a31, 0x8a2d, 0x8a1f, 0x8a1b, + 0x8a22, 0x8c49, 0x8c5a, 0x8ca9, 0x8cac, 0x8cab, 0x8ca8, 0x8caa, + 0x8ca7, 0x8d67, 0x8d66, 0x8dbe, 0x8dba, 0x8edb, 0x8edf, 0x9019, + 0x900d, 0x901a, 0x9017, 0x9023, 0x901f, 0x901d, 0x9010, 0x9015, + 0x901e, 0x9020, 0x900f, 0x9022, 0x9016, 0x901b, 0x9014, 0x90e8, + 0x90ed, 0x90fd, 0x9157, 0x91ce, 0x91f5, 0x91e6, 0x91e3, 0x91e7, + 0x91ed, 0x91e9, 0x9589, 0x966a, 0x9675, 0x9673, 0x9678, 0x9670, + 0x9674, 0x9676, 0x9677, 0x966c, 0x96c0, 0x96ea, 0x96e9, 0x7ae0, + 0x7adf, 0x9802, 0x9803, 0x9b5a, 0x9ce5, 0x9e75, 0x9e7f, 0x9ea5, + 0x9ebb, 0x50a2, 0x508d, 0x5085, 0x5099, 0x5091, 0x5080, 0x5096, + 0x5098, 0x509a, 0x6700, 0x51f1, 0x5272, 0x5274, 0x5275, 0x5269, + 0x52de, 0x52dd, 0x52db, 0x535a, 0x53a5, 0x557b, 0x5580, 0x55a7, + 0x557c, 0x558a, 0x559d, 0x5598, 0x5582, 0x559c, 0x55aa, 0x5594, + 0x5587, 0x558b, 0x5583, 0x55b3, 0x55ae, 0x559f, 0x553e, 0x55b2, + 0x559a, 0x55bb, 0x55ac, 0x55b1, 0x557e, 0x5589, 0x55ab, 0x5599, + 0x570d, 0x582f, 0x582a, 0x5834, 0x5824, 0x5830, 0x5831, 0x5821, + 0x581d, 0x5820, 0x58f9, 0x58fa, 0x5960, + /* 0xb4 */ + 0x5a77, 0x5a9a, 0x5a7f, 0x5a92, 0x5a9b, 0x5aa7, 0x5b73, 0x5b71, + 0x5bd2, 0x5bcc, 0x5bd3, 0x5bd0, 0x5c0a, 0x5c0b, 0x5c31, 0x5d4c, + 0x5d50, 0x5d34, 0x5d47, 0x5dfd, 0x5e45, 0x5e3d, 0x5e40, 0x5e43, + 0x5e7e, 0x5eca, 0x5ec1, 0x5ec2, 0x5ec4, 0x5f3c, 0x5f6d, 0x5fa9, + 0x5faa, 0x5fa8, 0x60d1, 0x60e1, 0x60b2, 0x60b6, 0x60e0, 0x611c, + 0x6123, 0x60fa, 0x6115, 0x60f0, 0x60fb, 0x60f4, 0x6168, 0x60f1, + 0x610e, 0x60f6, 0x6109, 0x6100, 0x6112, 0x621f, 0x6249, 0x63a3, + 0x638c, 0x63cf, 0x63c0, 0x63e9, 0x63c9, 0x63c6, 0x63cd, 0x63d2, + 0x63e3, 0x63d0, 0x63e1, 0x63d6, 0x63ed, 0x63ee, 0x6376, 0x63f4, + 0x63ea, 0x63db, 0x6452, 0x63da, 0x63f9, 0x655e, 0x6566, 0x6562, + 0x6563, 0x6591, 0x6590, 0x65af, 0x666e, 0x6670, 0x6674, 0x6676, + 0x666f, 0x6691, 0x667a, 0x667e, 0x6677, 0x66fe, 0x66ff, 0x671f, + 0x671d, 0x68fa, 0x68d5, 0x68e0, 0x68d8, 0x68d7, 0x6905, 0x68df, + 0x68f5, 0x68ee, 0x68e7, 0x68f9, 0x68d2, 0x68f2, 0x68e3, 0x68cb, + 0x68cd, 0x690d, 0x6912, 0x690e, 0x68c9, 0x68da, 0x696e, 0x68fb, + 0x6b3e, 0x6b3a, 0x6b3d, 0x6b98, 0x6b96, 0x6bbc, 0x6bef, 0x6c2e, + 0x6c2f, 0x6c2c, 0x6e2f, 0x6e38, 0x6e54, 0x6e21, 0x6e32, 0x6e67, + 0x6e4a, 0x6e20, 0x6e25, 0x6e23, 0x6e1b, 0x6e5b, 0x6e58, 0x6e24, + 0x6e56, 0x6e6e, 0x6e2d, 0x6e26, 0x6e6f, 0x6e34, 0x6e4d, 0x6e3a, + 0x6e2c, 0x6e43, 0x6e1d, 0x6e3e, 0x6ecb, + /* 0xb5 */ + 0x6e89, 0x6e19, 0x6e4e, 0x6e63, 0x6e44, 0x6e72, 0x6e69, 0x6e5f, + 0x7119, 0x711a, 0x7126, 0x7130, 0x7121, 0x7136, 0x716e, 0x711c, + 0x724c, 0x7284, 0x7280, 0x7336, 0x7325, 0x7334, 0x7329, 0x743a, + 0x742a, 0x7433, 0x7422, 0x7425, 0x7435, 0x7436, 0x7434, 0x742f, + 0x741b, 0x7426, 0x7428, 0x7525, 0x7526, 0x756b, 0x756a, 0x75e2, + 0x75db, 0x75e3, 0x75d9, 0x75d8, 0x75de, 0x75e0, 0x767b, 0x767c, + 0x7696, 0x7693, 0x76b4, 0x76dc, 0x774f, 0x77ed, 0x785d, 0x786c, + 0x786f, 0x7a0d, 0x7a08, 0x7a0b, 0x7a05, 0x7a00, 0x7a98, 0x7a97, + 0x7a96, 0x7ae5, 0x7ae3, 0x7b49, 0x7b56, 0x7b46, 0x7b50, 0x7b52, + 0x7b54, 0x7b4d, 0x7b4b, 0x7b4f, 0x7b51, 0x7c9f, 0x7ca5, 0x7d5e, + 0x7d50, 0x7d68, 0x7d55, 0x7d2b, 0x7d6e, 0x7d72, 0x7d61, 0x7d66, + 0x7d62, 0x7d70, 0x7d73, 0x5584, 0x7fd4, 0x7fd5, 0x800b, 0x8052, + 0x8085, 0x8155, 0x8154, 0x814b, 0x8151, 0x814e, 0x8139, 0x8146, + 0x813e, 0x814c, 0x8153, 0x8174, 0x8212, 0x821c, 0x83e9, 0x8403, + 0x83f8, 0x840d, 0x83e0, 0x83c5, 0x840b, 0x83c1, 0x83ef, 0x83f1, + 0x83f4, 0x8457, 0x840a, 0x83f0, 0x840c, 0x83cc, 0x83fd, 0x83f2, + 0x83ca, 0x8438, 0x840e, 0x8404, 0x83dc, 0x8407, 0x83d4, 0x83df, + 0x865b, 0x86df, 0x86d9, 0x86ed, 0x86d4, 0x86db, 0x86e4, 0x86d0, + 0x86de, 0x8857, 0x88c1, 0x88c2, 0x88b1, 0x8983, 0x8996, 0x8a3b, + 0x8a60, 0x8a55, 0x8a5e, 0x8a3c, 0x8a41, + /* 0xb6 */ + 0x8a54, 0x8a5b, 0x8a50, 0x8a46, 0x8a34, 0x8a3a, 0x8a36, 0x8a56, + 0x8c61, 0x8c82, 0x8caf, 0x8cbc, 0x8cb3, 0x8cbd, 0x8cc1, 0x8cbb, + 0x8cc0, 0x8cb4, 0x8cb7, 0x8cb6, 0x8cbf, 0x8cb8, 0x8d8a, 0x8d85, + 0x8d81, 0x8dce, 0x8ddd, 0x8dcb, 0x8dda, 0x8dd1, 0x8dcc, 0x8ddb, + 0x8dc6, 0x8efb, 0x8ef8, 0x8efc, 0x8f9c, 0x902e, 0x9035, 0x9031, + 0x9038, 0x9032, 0x9036, 0x9102, 0x90f5, 0x9109, 0x90fe, 0x9163, + 0x9165, 0x91cf, 0x9214, 0x9215, 0x9223, 0x9209, 0x921e, 0x920d, + 0x9210, 0x9207, 0x9211, 0x9594, 0x958f, 0x958b, 0x9591, 0x9593, + 0x9592, 0x958e, 0x968a, 0x968e, 0x968b, 0x967d, 0x9685, 0x9686, + 0x968d, 0x9672, 0x9684, 0x96c1, 0x96c5, 0x96c4, 0x96c6, 0x96c7, + 0x96ef, 0x96f2, 0x97cc, 0x9805, 0x9806, 0x9808, 0x98e7, 0x98ea, + 0x98ef, 0x98e9, 0x98f2, 0x98ed, 0x99ae, 0x99ad, 0x9ec3, 0x9ecd, + 0x9ed1, 0x4e82, 0x50ad, 0x50b5, 0x50b2, 0x50b3, 0x50c5, 0x50be, + 0x50ac, 0x50b7, 0x50bb, 0x50af, 0x50c7, 0x527f, 0x5277, 0x527d, + 0x52df, 0x52e6, 0x52e4, 0x52e2, 0x52e3, 0x532f, 0x55df, 0x55e8, + 0x55d3, 0x55e6, 0x55ce, 0x55dc, 0x55c7, 0x55d1, 0x55e3, 0x55e4, + 0x55ef, 0x55da, 0x55e1, 0x55c5, 0x55c6, 0x55e5, 0x55c9, 0x5712, + 0x5713, 0x585e, 0x5851, 0x5858, 0x5857, 0x585a, 0x5854, 0x586b, + 0x584c, 0x586d, 0x584a, 0x5862, 0x5852, 0x584b, 0x5967, 0x5ac1, + 0x5ac9, 0x5acc, 0x5abe, 0x5abd, 0x5abc, + /* 0xb7 */ + 0x5ab3, 0x5ac2, 0x5ab2, 0x5d69, 0x5d6f, 0x5e4c, 0x5e79, 0x5ec9, + 0x5ec8, 0x5f12, 0x5f59, 0x5fac, 0x5fae, 0x611a, 0x610f, 0x6148, + 0x611f, 0x60f3, 0x611b, 0x60f9, 0x6101, 0x6108, 0x614e, 0x614c, + 0x6144, 0x614d, 0x613e, 0x6134, 0x6127, 0x610d, 0x6106, 0x6137, + 0x6221, 0x6222, 0x6413, 0x643e, 0x641e, 0x642a, 0x642d, 0x643d, + 0x642c, 0x640f, 0x641c, 0x6414, 0x640d, 0x6436, 0x6416, 0x6417, + 0x6406, 0x656c, 0x659f, 0x65b0, 0x6697, 0x6689, 0x6687, 0x6688, + 0x6696, 0x6684, 0x6698, 0x668d, 0x6703, 0x6994, 0x696d, 0x695a, + 0x6977, 0x6960, 0x6954, 0x6975, 0x6930, 0x6982, 0x694a, 0x6968, + 0x696b, 0x695e, 0x6953, 0x6979, 0x6986, 0x695d, 0x6963, 0x695b, + 0x6b47, 0x6b72, 0x6bc0, 0x6bbf, 0x6bd3, 0x6bfd, 0x6ea2, 0x6eaf, + 0x6ed3, 0x6eb6, 0x6ec2, 0x6e90, 0x6e9d, 0x6ec7, 0x6ec5, 0x6ea5, + 0x6e98, 0x6ebc, 0x6eba, 0x6eab, 0x6ed1, 0x6e96, 0x6e9c, 0x6ec4, + 0x6ed4, 0x6eaa, 0x6ea7, 0x6eb4, 0x714e, 0x7159, 0x7169, 0x7164, + 0x7149, 0x7167, 0x715c, 0x716c, 0x7166, 0x714c, 0x7165, 0x715e, + 0x7146, 0x7168, 0x7156, 0x723a, 0x7252, 0x7337, 0x7345, 0x733f, + 0x733e, 0x746f, 0x745a, 0x7455, 0x745f, 0x745e, 0x7441, 0x743f, + 0x7459, 0x745b, 0x745c, 0x7576, 0x7578, 0x7600, 0x75f0, 0x7601, + 0x75f2, 0x75f1, 0x75fa, 0x75ff, 0x75f4, 0x75f3, 0x76de, 0x76df, + 0x775b, 0x776b, 0x7766, 0x775e, 0x7763, + /* 0xb8 */ + 0x7779, 0x776a, 0x776c, 0x775c, 0x7765, 0x7768, 0x7762, 0x77ee, + 0x788e, 0x78b0, 0x7897, 0x7898, 0x788c, 0x7889, 0x787c, 0x7891, + 0x7893, 0x787f, 0x797a, 0x797f, 0x7981, 0x842c, 0x79bd, 0x7a1c, + 0x7a1a, 0x7a20, 0x7a14, 0x7a1f, 0x7a1e, 0x7a9f, 0x7aa0, 0x7b77, + 0x7bc0, 0x7b60, 0x7b6e, 0x7b67, 0x7cb1, 0x7cb3, 0x7cb5, 0x7d93, + 0x7d79, 0x7d91, 0x7d81, 0x7d8f, 0x7d5b, 0x7f6e, 0x7f69, 0x7f6a, + 0x7f72, 0x7fa9, 0x7fa8, 0x7fa4, 0x8056, 0x8058, 0x8086, 0x8084, + 0x8171, 0x8170, 0x8178, 0x8165, 0x816e, 0x8173, 0x816b, 0x8179, + 0x817a, 0x8166, 0x8205, 0x8247, 0x8482, 0x8477, 0x843d, 0x8431, + 0x8475, 0x8466, 0x846b, 0x8449, 0x846c, 0x845b, 0x843c, 0x8435, + 0x8461, 0x8463, 0x8469, 0x846d, 0x8446, 0x865e, 0x865c, 0x865f, + 0x86f9, 0x8713, 0x8708, 0x8707, 0x8700, 0x86fe, 0x86fb, 0x8702, + 0x8703, 0x8706, 0x870a, 0x8859, 0x88df, 0x88d4, 0x88d9, 0x88dc, + 0x88d8, 0x88dd, 0x88e1, 0x88ca, 0x88d5, 0x88d2, 0x899c, 0x89e3, + 0x8a6b, 0x8a72, 0x8a73, 0x8a66, 0x8a69, 0x8a70, 0x8a87, 0x8a7c, + 0x8a63, 0x8aa0, 0x8a71, 0x8a85, 0x8a6d, 0x8a62, 0x8a6e, 0x8a6c, + 0x8a79, 0x8a7b, 0x8a3e, 0x8a68, 0x8c62, 0x8c8a, 0x8c89, 0x8cca, + 0x8cc7, 0x8cc8, 0x8cc4, 0x8cb2, 0x8cc3, 0x8cc2, 0x8cc5, 0x8de1, + 0x8ddf, 0x8de8, 0x8def, 0x8df3, 0x8dfa, 0x8dea, 0x8de4, 0x8de6, + 0x8eb2, 0x8f03, 0x8f09, 0x8efe, 0x8f0a, + /* 0xb9 */ + 0x8f9f, 0x8fb2, 0x904b, 0x904a, 0x9053, 0x9042, 0x9054, 0x903c, + 0x9055, 0x9050, 0x9047, 0x904f, 0x904e, 0x904d, 0x9051, 0x903e, + 0x9041, 0x9112, 0x9117, 0x916c, 0x916a, 0x9169, 0x91c9, 0x9237, + 0x9257, 0x9238, 0x923d, 0x9240, 0x923e, 0x925b, 0x924b, 0x9264, + 0x9251, 0x9234, 0x9249, 0x924d, 0x9245, 0x9239, 0x923f, 0x925a, + 0x9598, 0x9698, 0x9694, 0x9695, 0x96cd, 0x96cb, 0x96c9, 0x96ca, + 0x96f7, 0x96fb, 0x96f9, 0x96f6, 0x9756, 0x9774, 0x9776, 0x9810, + 0x9811, 0x9813, 0x980a, 0x9812, 0x980c, 0x98fc, 0x98f4, 0x98fd, + 0x98fe, 0x99b3, 0x99b1, 0x99b4, 0x9ae1, 0x9ce9, 0x9e82, 0x9f0e, + 0x9f13, 0x9f20, 0x50e7, 0x50ee, 0x50e5, 0x50d6, 0x50ed, 0x50da, + 0x50d5, 0x50cf, 0x50d1, 0x50f1, 0x50ce, 0x50e9, 0x5162, 0x51f3, + 0x5283, 0x5282, 0x5331, 0x53ad, 0x55fe, 0x5600, 0x561b, 0x5617, + 0x55fd, 0x5614, 0x5606, 0x5609, 0x560d, 0x560e, 0x55f7, 0x5616, + 0x561f, 0x5608, 0x5610, 0x55f6, 0x5718, 0x5716, 0x5875, 0x587e, + 0x5883, 0x5893, 0x588a, 0x5879, 0x5885, 0x587d, 0x58fd, 0x5925, + 0x5922, 0x5924, 0x596a, 0x5969, 0x5ae1, 0x5ae6, 0x5ae9, 0x5ad7, + 0x5ad6, 0x5ad8, 0x5ae3, 0x5b75, 0x5bde, 0x5be7, 0x5be1, 0x5be5, + 0x5be6, 0x5be8, 0x5be2, 0x5be4, 0x5bdf, 0x5c0d, 0x5c62, 0x5d84, + 0x5d87, 0x5e5b, 0x5e63, 0x5e55, 0x5e57, 0x5e54, 0x5ed3, 0x5ed6, + 0x5f0a, 0x5f46, 0x5f70, 0x5fb9, 0x6147, + /* 0xba */ + 0x613f, 0x614b, 0x6177, 0x6162, 0x6163, 0x615f, 0x615a, 0x6158, + 0x6175, 0x622a, 0x6487, 0x6458, 0x6454, 0x64a4, 0x6478, 0x645f, + 0x647a, 0x6451, 0x6467, 0x6434, 0x646d, 0x647b, 0x6572, 0x65a1, + 0x65d7, 0x65d6, 0x66a2, 0x66a8, 0x669d, 0x699c, 0x69a8, 0x6995, + 0x69c1, 0x69ae, 0x69d3, 0x69cb, 0x699b, 0x69b7, 0x69bb, 0x69ab, + 0x69b4, 0x69d0, 0x69cd, 0x69ad, 0x69cc, 0x69a6, 0x69c3, 0x69a3, + 0x6b49, 0x6b4c, 0x6c33, 0x6f33, 0x6f14, 0x6efe, 0x6f13, 0x6ef4, + 0x6f29, 0x6f3e, 0x6f20, 0x6f2c, 0x6f0f, 0x6f02, 0x6f22, 0x6eff, + 0x6eef, 0x6f06, 0x6f31, 0x6f38, 0x6f32, 0x6f23, 0x6f15, 0x6f2b, + 0x6f2f, 0x6f88, 0x6f2a, 0x6eec, 0x6f01, 0x6ef2, 0x6ecc, 0x6ef7, + 0x7194, 0x7199, 0x717d, 0x718a, 0x7184, 0x7192, 0x723e, 0x7292, + 0x7296, 0x7344, 0x7350, 0x7464, 0x7463, 0x746a, 0x7470, 0x746d, + 0x7504, 0x7591, 0x7627, 0x760d, 0x760b, 0x7609, 0x7613, 0x76e1, + 0x76e3, 0x7784, 0x777d, 0x777f, 0x7761, 0x78c1, 0x789f, 0x78a7, + 0x78b3, 0x78a9, 0x78a3, 0x798e, 0x798f, 0x798d, 0x7a2e, 0x7a31, + 0x7aaa, 0x7aa9, 0x7aed, 0x7aef, 0x7ba1, 0x7b95, 0x7b8b, 0x7b75, + 0x7b97, 0x7b9d, 0x7b94, 0x7b8f, 0x7bb8, 0x7b87, 0x7b84, 0x7cb9, + 0x7cbd, 0x7cbe, 0x7dbb, 0x7db0, 0x7d9c, 0x7dbd, 0x7dbe, 0x7da0, + 0x7dca, 0x7db4, 0x7db2, 0x7db1, 0x7dba, 0x7da2, 0x7dbf, 0x7db5, + 0x7db8, 0x7dad, 0x7dd2, 0x7dc7, 0x7dac, + /* 0xbb */ + 0x7f70, 0x7fe0, 0x7fe1, 0x7fdf, 0x805e, 0x805a, 0x8087, 0x8150, + 0x8180, 0x818f, 0x8188, 0x818a, 0x817f, 0x8182, 0x81e7, 0x81fa, + 0x8207, 0x8214, 0x821e, 0x824b, 0x84c9, 0x84bf, 0x84c6, 0x84c4, + 0x8499, 0x849e, 0x84b2, 0x849c, 0x84cb, 0x84b8, 0x84c0, 0x84d3, + 0x8490, 0x84bc, 0x84d1, 0x84ca, 0x873f, 0x871c, 0x873b, 0x8722, + 0x8725, 0x8734, 0x8718, 0x8755, 0x8737, 0x8729, 0x88f3, 0x8902, + 0x88f4, 0x88f9, 0x88f8, 0x88fd, 0x88e8, 0x891a, 0x88ef, 0x8aa6, + 0x8a8c, 0x8a9e, 0x8aa3, 0x8a8d, 0x8aa1, 0x8a93, 0x8aa4, 0x8aaa, + 0x8aa5, 0x8aa8, 0x8a98, 0x8a91, 0x8a9a, 0x8aa7, 0x8c6a, 0x8c8d, + 0x8c8c, 0x8cd3, 0x8cd1, 0x8cd2, 0x8d6b, 0x8d99, 0x8d95, 0x8dfc, + 0x8f14, 0x8f12, 0x8f15, 0x8f13, 0x8fa3, 0x9060, 0x9058, 0x905c, + 0x9063, 0x9059, 0x905e, 0x9062, 0x905d, 0x905b, 0x9119, 0x9118, + 0x911e, 0x9175, 0x9178, 0x9177, 0x9174, 0x9278, 0x9280, 0x9285, + 0x9298, 0x9296, 0x927b, 0x9293, 0x929c, 0x92a8, 0x927c, 0x9291, + 0x95a1, 0x95a8, 0x95a9, 0x95a3, 0x95a5, 0x95a4, 0x9699, 0x969c, + 0x969b, 0x96cc, 0x96d2, 0x9700, 0x977c, 0x9785, 0x97f6, 0x9817, + 0x9818, 0x98af, 0x98b1, 0x9903, 0x9905, 0x990c, 0x9909, 0x99c1, + 0x9aaf, 0x9ab0, 0x9ae6, 0x9b41, 0x9b42, 0x9cf4, 0x9cf6, 0x9cf3, + 0x9ebc, 0x9f3b, 0x9f4a, 0x5104, 0x5100, 0x50fb, 0x50f5, 0x50f9, + 0x5102, 0x5108, 0x5109, 0x5105, 0x51dc, + /* 0xbc */ + 0x5287, 0x5288, 0x5289, 0x528d, 0x528a, 0x52f0, 0x53b2, 0x562e, + 0x563b, 0x5639, 0x5632, 0x563f, 0x5634, 0x5629, 0x5653, 0x564e, + 0x5657, 0x5674, 0x5636, 0x562f, 0x5630, 0x5880, 0x589f, 0x589e, + 0x58b3, 0x589c, 0x58ae, 0x58a9, 0x58a6, 0x596d, 0x5b09, 0x5afb, + 0x5b0b, 0x5af5, 0x5b0c, 0x5b08, 0x5bee, 0x5bec, 0x5be9, 0x5beb, + 0x5c64, 0x5c65, 0x5d9d, 0x5d94, 0x5e62, 0x5e5f, 0x5e61, 0x5ee2, + 0x5eda, 0x5edf, 0x5edd, 0x5ee3, 0x5ee0, 0x5f48, 0x5f71, 0x5fb7, + 0x5fb5, 0x6176, 0x6167, 0x616e, 0x615d, 0x6155, 0x6182, 0x617c, + 0x6170, 0x616b, 0x617e, 0x61a7, 0x6190, 0x61ab, 0x618e, 0x61ac, + 0x619a, 0x61a4, 0x6194, 0x61ae, 0x622e, 0x6469, 0x646f, 0x6479, + 0x649e, 0x64b2, 0x6488, 0x6490, 0x64b0, 0x64a5, 0x6493, 0x6495, + 0x64a9, 0x6492, 0x64ae, 0x64ad, 0x64ab, 0x649a, 0x64ac, 0x6499, + 0x64a2, 0x64b3, 0x6575, 0x6577, 0x6578, 0x66ae, 0x66ab, 0x66b4, + 0x66b1, 0x6a23, 0x6a1f, 0x69e8, 0x6a01, 0x6a1e, 0x6a19, 0x69fd, + 0x6a21, 0x6a13, 0x6a0a, 0x69f3, 0x6a02, 0x6a05, 0x69ed, 0x6a11, + 0x6b50, 0x6b4e, 0x6ba4, 0x6bc5, 0x6bc6, 0x6f3f, 0x6f7c, 0x6f84, + 0x6f51, 0x6f66, 0x6f54, 0x6f86, 0x6f6d, 0x6f5b, 0x6f78, 0x6f6e, + 0x6f8e, 0x6f7a, 0x6f70, 0x6f64, 0x6f97, 0x6f58, 0x6ed5, 0x6f6f, + 0x6f60, 0x6f5f, 0x719f, 0x71ac, 0x71b1, 0x71a8, 0x7256, 0x729b, + 0x734e, 0x7357, 0x7469, 0x748b, 0x7483, + /* 0xbd */ + 0x747e, 0x7480, 0x757f, 0x7620, 0x7629, 0x761f, 0x7624, 0x7626, + 0x7621, 0x7622, 0x769a, 0x76ba, 0x76e4, 0x778e, 0x7787, 0x778c, + 0x7791, 0x778b, 0x78cb, 0x78c5, 0x78ba, 0x78ca, 0x78be, 0x78d5, + 0x78bc, 0x78d0, 0x7a3f, 0x7a3c, 0x7a40, 0x7a3d, 0x7a37, 0x7a3b, + 0x7aaf, 0x7aae, 0x7bad, 0x7bb1, 0x7bc4, 0x7bb4, 0x7bc6, 0x7bc7, + 0x7bc1, 0x7ba0, 0x7bcc, 0x7cca, 0x7de0, 0x7df4, 0x7def, 0x7dfb, + 0x7dd8, 0x7dec, 0x7ddd, 0x7de8, 0x7de3, 0x7dda, 0x7dde, 0x7de9, + 0x7d9e, 0x7dd9, 0x7df2, 0x7df9, 0x7f75, 0x7f77, 0x7faf, 0x7fe9, + 0x8026, 0x819b, 0x819c, 0x819d, 0x81a0, 0x819a, 0x8198, 0x8517, + 0x853d, 0x851a, 0x84ee, 0x852c, 0x852d, 0x8513, 0x8511, 0x8523, + 0x8521, 0x8514, 0x84ec, 0x8525, 0x84ff, 0x8506, 0x8782, 0x8774, + 0x8776, 0x8760, 0x8766, 0x8778, 0x8768, 0x8759, 0x8757, 0x874c, + 0x8753, 0x885b, 0x885d, 0x8910, 0x8907, 0x8912, 0x8913, 0x8915, + 0x890a, 0x8abc, 0x8ad2, 0x8ac7, 0x8ac4, 0x8a95, 0x8acb, 0x8af8, + 0x8ab2, 0x8ac9, 0x8ac2, 0x8abf, 0x8ab0, 0x8ad6, 0x8acd, 0x8ab6, + 0x8ab9, 0x8adb, 0x8c4c, 0x8c4e, 0x8c6c, 0x8ce0, 0x8cde, 0x8ce6, + 0x8ce4, 0x8cec, 0x8ced, 0x8ce2, 0x8ce3, 0x8cdc, 0x8cea, 0x8ce1, + 0x8d6d, 0x8d9f, 0x8da3, 0x8e2b, 0x8e10, 0x8e1d, 0x8e22, 0x8e0f, + 0x8e29, 0x8e1f, 0x8e21, 0x8e1e, 0x8eba, 0x8f1d, 0x8f1b, 0x8f1f, + 0x8f29, 0x8f26, 0x8f2a, 0x8f1c, 0x8f1e, + /* 0xbe */ + 0x8f25, 0x9069, 0x906e, 0x9068, 0x906d, 0x9077, 0x9130, 0x912d, + 0x9127, 0x9131, 0x9187, 0x9189, 0x918b, 0x9183, 0x92c5, 0x92bb, + 0x92b7, 0x92ea, 0x92ac, 0x92e4, 0x92c1, 0x92b3, 0x92bc, 0x92d2, + 0x92c7, 0x92f0, 0x92b2, 0x95ad, 0x95b1, 0x9704, 0x9706, 0x9707, + 0x9709, 0x9760, 0x978d, 0x978b, 0x978f, 0x9821, 0x982b, 0x981c, + 0x98b3, 0x990a, 0x9913, 0x9912, 0x9918, 0x99dd, 0x99d0, 0x99df, + 0x99db, 0x99d1, 0x99d5, 0x99d2, 0x99d9, 0x9ab7, 0x9aee, 0x9aef, + 0x9b27, 0x9b45, 0x9b44, 0x9b77, 0x9b6f, 0x9d06, 0x9d09, 0x9d03, + 0x9ea9, 0x9ebe, 0x9ece, 0x58a8, 0x9f52, 0x5112, 0x5118, 0x5114, + 0x5110, 0x5115, 0x5180, 0x51aa, 0x51dd, 0x5291, 0x5293, 0x52f3, + 0x5659, 0x566b, 0x5679, 0x5669, 0x5664, 0x5678, 0x566a, 0x5668, + 0x5665, 0x5671, 0x566f, 0x566c, 0x5662, 0x5676, 0x58c1, 0x58be, + 0x58c7, 0x58c5, 0x596e, 0x5b1d, 0x5b34, 0x5b78, 0x5bf0, 0x5c0e, + 0x5f4a, 0x61b2, 0x6191, 0x61a9, 0x618a, 0x61cd, 0x61b6, 0x61be, + 0x61ca, 0x61c8, 0x6230, 0x64c5, 0x64c1, 0x64cb, 0x64bb, 0x64bc, + 0x64da, 0x64c4, 0x64c7, 0x64c2, 0x64cd, 0x64bf, 0x64d2, 0x64d4, + 0x64be, 0x6574, 0x66c6, 0x66c9, 0x66b9, 0x66c4, 0x66c7, 0x66b8, + 0x6a3d, 0x6a38, 0x6a3a, 0x6a59, 0x6a6b, 0x6a58, 0x6a39, 0x6a44, + 0x6a62, 0x6a61, 0x6a4b, 0x6a47, 0x6a35, 0x6a5f, 0x6a48, 0x6b59, + 0x6b77, 0x6c05, 0x6fc2, 0x6fb1, 0x6fa1, + /* 0xbf */ + 0x6fc3, 0x6fa4, 0x6fc1, 0x6fa7, 0x6fb3, 0x6fc0, 0x6fb9, 0x6fb6, + 0x6fa6, 0x6fa0, 0x6fb4, 0x71be, 0x71c9, 0x71d0, 0x71d2, 0x71c8, + 0x71d5, 0x71b9, 0x71ce, 0x71d9, 0x71dc, 0x71c3, 0x71c4, 0x7368, + 0x749c, 0x74a3, 0x7498, 0x749f, 0x749e, 0x74e2, 0x750c, 0x750d, + 0x7634, 0x7638, 0x763a, 0x76e7, 0x76e5, 0x77a0, 0x779e, 0x779f, + 0x77a5, 0x78e8, 0x78da, 0x78ec, 0x78e7, 0x79a6, 0x7a4d, 0x7a4e, + 0x7a46, 0x7a4c, 0x7a4b, 0x7aba, 0x7bd9, 0x7c11, 0x7bc9, 0x7be4, + 0x7bdb, 0x7be1, 0x7be9, 0x7be6, 0x7cd5, 0x7cd6, 0x7e0a, 0x7e11, + 0x7e08, 0x7e1b, 0x7e23, 0x7e1e, 0x7e1d, 0x7e09, 0x7e10, 0x7f79, + 0x7fb2, 0x7ff0, 0x7ff1, 0x7fee, 0x8028, 0x81b3, 0x81a9, 0x81a8, + 0x81fb, 0x8208, 0x8258, 0x8259, 0x854a, 0x8559, 0x8548, 0x8568, + 0x8569, 0x8543, 0x8549, 0x856d, 0x856a, 0x855e, 0x8783, 0x879f, + 0x879e, 0x87a2, 0x878d, 0x8861, 0x892a, 0x8932, 0x8925, 0x892b, + 0x8921, 0x89aa, 0x89a6, 0x8ae6, 0x8afa, 0x8aeb, 0x8af1, 0x8b00, + 0x8adc, 0x8ae7, 0x8aee, 0x8afe, 0x8b01, 0x8b02, 0x8af7, 0x8aed, + 0x8af3, 0x8af6, 0x8afc, 0x8c6b, 0x8c6d, 0x8c93, 0x8cf4, 0x8e44, + 0x8e31, 0x8e34, 0x8e42, 0x8e39, 0x8e35, 0x8f3b, 0x8f2f, 0x8f38, + 0x8f33, 0x8fa8, 0x8fa6, 0x9075, 0x9074, 0x9078, 0x9072, 0x907c, + 0x907a, 0x9134, 0x9192, 0x9320, 0x9336, 0x92f8, 0x9333, 0x932f, + 0x9322, 0x92fc, 0x932b, 0x9304, 0x931a, + /* 0xc0 */ + 0x9310, 0x9326, 0x9321, 0x9315, 0x932e, 0x9319, 0x95bb, 0x96a7, + 0x96a8, 0x96aa, 0x96d5, 0x970e, 0x9711, 0x9716, 0x970d, 0x9713, + 0x970f, 0x975b, 0x975c, 0x9766, 0x9798, 0x9830, 0x9838, 0x983b, + 0x9837, 0x982d, 0x9839, 0x9824, 0x9910, 0x9928, 0x991e, 0x991b, + 0x9921, 0x991a, 0x99ed, 0x99e2, 0x99f1, 0x9ab8, 0x9abc, 0x9afb, + 0x9aed, 0x9b28, 0x9b91, 0x9d15, 0x9d23, 0x9d26, 0x9d28, 0x9d12, + 0x9d1b, 0x9ed8, 0x9ed4, 0x9f8d, 0x9f9c, 0x512a, 0x511f, 0x5121, + 0x5132, 0x52f5, 0x568e, 0x5680, 0x5690, 0x5685, 0x5687, 0x568f, + 0x58d5, 0x58d3, 0x58d1, 0x58ce, 0x5b30, 0x5b2a, 0x5b24, 0x5b7a, + 0x5c37, 0x5c68, 0x5dbc, 0x5dba, 0x5dbd, 0x5db8, 0x5e6b, 0x5f4c, + 0x5fbd, 0x61c9, 0x61c2, 0x61c7, 0x61e6, 0x61cb, 0x6232, 0x6234, + 0x64ce, 0x64ca, 0x64d8, 0x64e0, 0x64f0, 0x64e6, 0x64ec, 0x64f1, + 0x64e2, 0x64ed, 0x6582, 0x6583, 0x66d9, 0x66d6, 0x6a80, 0x6a94, + 0x6a84, 0x6aa2, 0x6a9c, 0x6adb, 0x6aa3, 0x6a7e, 0x6a97, 0x6a90, + 0x6aa0, 0x6b5c, 0x6bae, 0x6bda, 0x6c08, 0x6fd8, 0x6ff1, 0x6fdf, + 0x6fe0, 0x6fdb, 0x6fe4, 0x6feb, 0x6fef, 0x6f80, 0x6fec, 0x6fe1, + 0x6fe9, 0x6fd5, 0x6fee, 0x6ff0, 0x71e7, 0x71df, 0x71ee, 0x71e6, + 0x71e5, 0x71ed, 0x71ec, 0x71f4, 0x71e0, 0x7235, 0x7246, 0x7370, + 0x7372, 0x74a9, 0x74b0, 0x74a6, 0x74a8, 0x7646, 0x7642, 0x764c, + 0x76ea, 0x77b3, 0x77aa, 0x77b0, 0x77ac, + /* 0xc1 */ + 0x77a7, 0x77ad, 0x77ef, 0x78f7, 0x78fa, 0x78f4, 0x78ef, 0x7901, + 0x79a7, 0x79aa, 0x7a57, 0x7abf, 0x7c07, 0x7c0d, 0x7bfe, 0x7bf7, + 0x7c0c, 0x7be0, 0x7ce0, 0x7cdc, 0x7cde, 0x7ce2, 0x7cdf, 0x7cd9, + 0x7cdd, 0x7e2e, 0x7e3e, 0x7e46, 0x7e37, 0x7e32, 0x7e43, 0x7e2b, + 0x7e3d, 0x7e31, 0x7e45, 0x7e41, 0x7e34, 0x7e39, 0x7e48, 0x7e35, + 0x7e3f, 0x7e2f, 0x7f44, 0x7ff3, 0x7ffc, 0x8071, 0x8072, 0x8070, + 0x806f, 0x8073, 0x81c6, 0x81c3, 0x81ba, 0x81c2, 0x81c0, 0x81bf, + 0x81bd, 0x81c9, 0x81be, 0x81e8, 0x8209, 0x8271, 0x85aa, 0x8584, + 0x857e, 0x859c, 0x8591, 0x8594, 0x85af, 0x859b, 0x8587, 0x85a8, + 0x858a, 0x8667, 0x87c0, 0x87d1, 0x87b3, 0x87d2, 0x87c6, 0x87ab, + 0x87bb, 0x87ba, 0x87c8, 0x87cb, 0x893b, 0x8936, 0x8944, 0x8938, + 0x893d, 0x89ac, 0x8b0e, 0x8b17, 0x8b19, 0x8b1b, 0x8b0a, 0x8b20, + 0x8b1d, 0x8b04, 0x8b10, 0x8c41, 0x8c3f, 0x8c73, 0x8cfa, 0x8cfd, + 0x8cfc, 0x8cf8, 0x8cfb, 0x8da8, 0x8e49, 0x8e4b, 0x8e48, 0x8e4a, + 0x8f44, 0x8f3e, 0x8f42, 0x8f45, 0x8f3f, 0x907f, 0x907d, 0x9084, + 0x9081, 0x9082, 0x9080, 0x9139, 0x91a3, 0x919e, 0x919c, 0x934d, + 0x9382, 0x9328, 0x9375, 0x934a, 0x9365, 0x934b, 0x9318, 0x937e, + 0x936c, 0x935b, 0x9370, 0x935a, 0x9354, 0x95ca, 0x95cb, 0x95cc, + 0x95c8, 0x95c6, 0x96b1, 0x96b8, 0x96d6, 0x971c, 0x971e, 0x97a0, + 0x97d3, 0x9846, 0x98b6, 0x9935, 0x9a01, + /* 0xc2 */ + 0x99ff, 0x9bae, 0x9bab, 0x9baa, 0x9bad, 0x9d3b, 0x9d3f, 0x9e8b, + 0x9ecf, 0x9ede, 0x9edc, 0x9edd, 0x9edb, 0x9f3e, 0x9f4b, 0x53e2, + 0x5695, 0x56ae, 0x58d9, 0x58d8, 0x5b38, 0x5f5d, 0x61e3, 0x6233, + 0x64f4, 0x64f2, 0x64fe, 0x6506, 0x64fa, 0x64fb, 0x64f7, 0x65b7, + 0x66dc, 0x6726, 0x6ab3, 0x6aac, 0x6ac3, 0x6abb, 0x6ab8, 0x6ac2, + 0x6aae, 0x6aaf, 0x6b5f, 0x6b78, 0x6baf, 0x7009, 0x700b, 0x6ffe, + 0x7006, 0x6ffa, 0x7011, 0x700f, 0x71fb, 0x71fc, 0x71fe, 0x71f8, + 0x7377, 0x7375, 0x74a7, 0x74bf, 0x7515, 0x7656, 0x7658, 0x7652, + 0x77bd, 0x77bf, 0x77bb, 0x77bc, 0x790e, 0x79ae, 0x7a61, 0x7a62, + 0x7a60, 0x7ac4, 0x7ac5, 0x7c2b, 0x7c27, 0x7c2a, 0x7c1e, 0x7c23, + 0x7c21, 0x7ce7, 0x7e54, 0x7e55, 0x7e5e, 0x7e5a, 0x7e61, 0x7e52, + 0x7e59, 0x7f48, 0x7ff9, 0x7ffb, 0x8077, 0x8076, 0x81cd, 0x81cf, + 0x820a, 0x85cf, 0x85a9, 0x85cd, 0x85d0, 0x85c9, 0x85b0, 0x85ba, + 0x85b9, 0x85a6, 0x87ef, 0x87ec, 0x87f2, 0x87e0, 0x8986, 0x89b2, + 0x89f4, 0x8b28, 0x8b39, 0x8b2c, 0x8b2b, 0x8c50, 0x8d05, 0x8e59, + 0x8e63, 0x8e66, 0x8e64, 0x8e5f, 0x8e55, 0x8ec0, 0x8f49, 0x8f4d, + 0x9087, 0x9083, 0x9088, 0x91ab, 0x91ac, 0x91d0, 0x9394, 0x938a, + 0x9396, 0x93a2, 0x93b3, 0x93ae, 0x93ac, 0x93b0, 0x9398, 0x939a, + 0x9397, 0x95d4, 0x95d6, 0x95d0, 0x95d5, 0x96e2, 0x96dc, 0x96d9, + 0x96db, 0x96de, 0x9724, 0x97a3, 0x97a6, + /* 0xc3 */ + 0x97ad, 0x97f9, 0x984d, 0x984f, 0x984c, 0x984e, 0x9853, 0x98ba, + 0x993e, 0x993f, 0x993d, 0x992e, 0x99a5, 0x9a0e, 0x9ac1, 0x9b03, + 0x9b06, 0x9b4f, 0x9b4e, 0x9b4d, 0x9bca, 0x9bc9, 0x9bfd, 0x9bc8, + 0x9bc0, 0x9d51, 0x9d5d, 0x9d60, 0x9ee0, 0x9f15, 0x9f2c, 0x5133, + 0x56a5, 0x58de, 0x58df, 0x58e2, 0x5bf5, 0x9f90, 0x5eec, 0x61f2, + 0x61f7, 0x61f6, 0x61f5, 0x6500, 0x650f, 0x66e0, 0x66dd, 0x6ae5, + 0x6add, 0x6ada, 0x6ad3, 0x701b, 0x701f, 0x7028, 0x701a, 0x701d, + 0x7015, 0x7018, 0x7206, 0x720d, 0x7258, 0x72a2, 0x7378, 0x737a, + 0x74bd, 0x74ca, 0x74e3, 0x7587, 0x7586, 0x765f, 0x7661, 0x77c7, + 0x7919, 0x79b1, 0x7a6b, 0x7a69, 0x7c3e, 0x7c3f, 0x7c38, 0x7c3d, + 0x7c37, 0x7c40, 0x7e6b, 0x7e6d, 0x7e79, 0x7e69, 0x7e6a, 0x7f85, + 0x7e73, 0x7fb6, 0x7fb9, 0x7fb8, 0x81d8, 0x85e9, 0x85dd, 0x85ea, + 0x85d5, 0x85e4, 0x85e5, 0x85f7, 0x87fb, 0x8805, 0x880d, 0x87f9, + 0x87fe, 0x8960, 0x895f, 0x8956, 0x895e, 0x8b41, 0x8b5c, 0x8b58, + 0x8b49, 0x8b5a, 0x8b4e, 0x8b4f, 0x8b46, 0x8b59, 0x8d08, 0x8d0a, + 0x8e7c, 0x8e72, 0x8e87, 0x8e76, 0x8e6c, 0x8e7a, 0x8e74, 0x8f54, + 0x8f4e, 0x8fad, 0x908a, 0x908b, 0x91b1, 0x91ae, 0x93e1, 0x93d1, + 0x93df, 0x93c3, 0x93c8, 0x93dc, 0x93dd, 0x93d6, 0x93e2, 0x93cd, + 0x93d8, 0x93e4, 0x93d7, 0x93e8, 0x95dc, 0x96b4, 0x96e3, 0x972a, + 0x9727, 0x9761, 0x97dc, 0x97fb, 0x985e, + /* 0xc4 */ + 0x9858, 0x985b, 0x98bc, 0x9945, 0x9949, 0x9a16, 0x9a19, 0x9b0d, + 0x9be8, 0x9be7, 0x9bd6, 0x9bdb, 0x9d89, 0x9d61, 0x9d72, 0x9d6a, + 0x9d6c, 0x9e92, 0x9e97, 0x9e93, 0x9eb4, 0x52f8, 0x56a8, 0x56b7, + 0x56b6, 0x56b4, 0x56bc, 0x58e4, 0x5b40, 0x5b43, 0x5b7d, 0x5bf6, + 0x5dc9, 0x61f8, 0x61fa, 0x6518, 0x6514, 0x6519, 0x66e6, 0x6727, + 0x6aec, 0x703e, 0x7030, 0x7032, 0x7210, 0x737b, 0x74cf, 0x7662, + 0x7665, 0x7926, 0x792a, 0x792c, 0x792b, 0x7ac7, 0x7af6, 0x7c4c, + 0x7c43, 0x7c4d, 0x7cef, 0x7cf0, 0x8fae, 0x7e7d, 0x7e7c, 0x7e82, + 0x7f4c, 0x8000, 0x81da, 0x8266, 0x85fb, 0x85f9, 0x8611, 0x85fa, + 0x8606, 0x860b, 0x8607, 0x860a, 0x8814, 0x8815, 0x8964, 0x89ba, + 0x89f8, 0x8b70, 0x8b6c, 0x8b66, 0x8b6f, 0x8b5f, 0x8b6b, 0x8d0f, + 0x8d0d, 0x8e89, 0x8e81, 0x8e85, 0x8e82, 0x91b4, 0x91cb, 0x9418, + 0x9403, 0x93fd, 0x95e1, 0x9730, 0x98c4, 0x9952, 0x9951, 0x99a8, + 0x9a2b, 0x9a30, 0x9a37, 0x9a35, 0x9c13, 0x9c0d, 0x9e79, 0x9eb5, + 0x9ee8, 0x9f2f, 0x9f5f, 0x9f63, 0x9f61, 0x5137, 0x5138, 0x56c1, + 0x56c0, 0x56c2, 0x5914, 0x5c6c, 0x5dcd, 0x61fc, 0x61fe, 0x651d, + 0x651c, 0x6595, 0x66e9, 0x6afb, 0x6b04, 0x6afa, 0x6bb2, 0x704c, + 0x721b, 0x72a7, 0x74d6, 0x74d4, 0x7669, 0x77d3, 0x7c50, 0x7e8f, + 0x7e8c, 0x7fbc, 0x8617, 0x862d, 0x861a, 0x8823, 0x8822, 0x8821, + 0x881f, 0x896a, 0x896c, 0x89bd, 0x8b74, + /* 0xc5 */ + 0x8b77, 0x8b7d, 0x8d13, 0x8e8a, 0x8e8d, 0x8e8b, 0x8f5f, 0x8faf, + 0x91ba, 0x942e, 0x9433, 0x9435, 0x943a, 0x9438, 0x9432, 0x942b, + 0x95e2, 0x9738, 0x9739, 0x9732, 0x97ff, 0x9867, 0x9865, 0x9957, + 0x9a45, 0x9a43, 0x9a40, 0x9a3e, 0x9acf, 0x9b54, 0x9b51, 0x9c2d, + 0x9c25, 0x9daf, 0x9db4, 0x9dc2, 0x9db8, 0x9e9d, 0x9eef, 0x9f19, + 0x9f5c, 0x9f66, 0x9f67, 0x513c, 0x513b, 0x56c8, 0x56ca, 0x56c9, + 0x5b7f, 0x5dd4, 0x5dd2, 0x5f4e, 0x61ff, 0x6524, 0x6b0a, 0x6b61, + 0x7051, 0x7058, 0x7380, 0x74e4, 0x758a, 0x766e, 0x766c, 0x79b3, + 0x7c60, 0x7c5f, 0x807e, 0x807d, 0x81df, 0x8972, 0x896f, 0x89fc, + 0x8b80, 0x8d16, 0x8d17, 0x8e91, 0x8e93, 0x8f61, 0x9148, 0x9444, + 0x9451, 0x9452, 0x973d, 0x973e, 0x97c3, 0x97c1, 0x986b, 0x9955, + 0x9a55, 0x9a4d, 0x9ad2, 0x9b1a, 0x9c49, 0x9c31, 0x9c3e, 0x9c3b, + 0x9dd3, 0x9dd7, 0x9f34, 0x9f6c, 0x9f6a, 0x9f94, 0x56cc, 0x5dd6, + 0x6200, 0x6523, 0x652b, 0x652a, 0x66ec, 0x6b10, 0x74da, 0x7aca, + 0x7c64, 0x7c63, 0x7c65, 0x7e93, 0x7e96, 0x7e94, 0x81e2, 0x8638, + 0x863f, 0x8831, 0x8b8a, 0x9090, 0x908f, 0x9463, 0x9460, 0x9464, + 0x9768, 0x986f, 0x995c, 0x9a5a, 0x9a5b, 0x9a57, 0x9ad3, 0x9ad4, + 0x9ad1, 0x9c54, 0x9c57, 0x9c56, 0x9de5, 0x9e9f, 0x9ef4, 0x56d1, + 0x58e9, 0x652c, 0x705e, 0x7671, 0x7672, 0x77d7, 0x7f50, 0x7f88, + 0x8836, 0x8839, 0x8862, 0x8b93, 0x8b92, + /* 0xc6 */ + 0x8b96, 0x8277, 0x8d1b, 0x91c0, 0x946a, 0x9742, 0x9748, 0x9744, + 0x97c6, 0x9870, 0x9a5f, 0x9b22, 0x9b58, 0x9c5f, 0x9df9, 0x9dfa, + 0x9e7c, 0x9e7d, 0x9f07, 0x9f77, 0x9f72, 0x5ef3, 0x6b16, 0x7063, + 0x7c6c, 0x7c6e, 0x883b, 0x89c0, 0x8ea1, 0x91c1, 0x9472, 0x9470, + 0x9871, 0x995e, 0x9ad6, 0x9b23, 0x9ecc, 0x7064, 0x77da, 0x8b9a, + 0x9477, 0x97c9, 0x9a62, 0x9a65, 0x7e9c, 0x8b9c, 0x8eaa, 0x91c5, + 0x947d, 0x947e, 0x947c, 0x9c77, 0x9c78, 0x9ef7, 0x8c54, 0x947f, + 0x9e1a, 0x7228, 0x9a6a, 0x9b31, 0x9e1b, 0x9e1e, 0x7c72, 0x30fe, + 0x309d, 0x309e, 0x3005, 0x3041, 0x3042, 0x3043, 0x3044, 0x3045, + 0x3046, 0x3047, 0x3048, 0x3049, 0x304a, 0x304b, 0x304c, 0x304d, + 0x304e, 0x304f, 0x3050, 0x3051, 0x3052, 0x3053, 0x3054, 0x3055, + 0x3056, 0x3057, 0x3058, 0x3059, 0x305a, 0x305b, 0x305c, 0x305d, + 0x305e, 0x305f, 0x3060, 0x3061, 0x3062, 0x3063, 0x3064, 0x3065, + 0x3066, 0x3067, 0x3068, 0x3069, 0x306a, 0x306b, 0x306c, 0x306d, + 0x306e, 0x306f, 0x3070, 0x3071, 0x3072, 0x3073, 0x3074, 0x3075, + 0x3076, 0x3077, 0x3078, 0x3079, 0x307a, 0x307b, 0x307c, 0x307d, + 0x307e, 0x307f, 0x3080, 0x3081, 0x3082, 0x3083, 0x3084, 0x3085, + 0x3086, 0x3087, 0x3088, 0x3089, 0x308a, 0x308b, 0x308c, 0x308d, + 0x308e, 0x308f, 0x3090, 0x3091, 0x3092, 0x3093, 0x30a1, 0x30a2, + 0x30a3, 0x30a4, 0x30a5, 0x30a6, 0x30a7, + /* 0xc7 */ + 0x30a8, 0x30a9, 0x30aa, 0x30ab, 0x30ac, 0x30ad, 0x30ae, 0x30af, + 0x30b0, 0x30b1, 0x30b2, 0x30b3, 0x30b4, 0x30b5, 0x30b6, 0x30b7, + 0x30b8, 0x30b9, 0x30ba, 0x30bb, 0x30bc, 0x30bd, 0x30be, 0x30bf, + 0x30c0, 0x30c1, 0x30c2, 0x30c3, 0x30c4, 0x30c5, 0x30c6, 0x30c7, + 0x30c8, 0x30c9, 0x30ca, 0x30cb, 0x30cc, 0x30cd, 0x30ce, 0x30cf, + 0x30d0, 0x30d1, 0x30d2, 0x30d3, 0x30d4, 0x30d5, 0x30d6, 0x30d7, + 0x30d8, 0x30d9, 0x30da, 0x30db, 0x30dc, 0x30dd, 0x30de, 0x30df, + 0x30e0, 0x30e1, 0x30e2, 0x30e3, 0x30e4, 0x30e5, 0x30e6, 0x30e7, + 0x30e8, 0x30e9, 0x30ea, 0x30eb, 0x30ec, 0x30ed, 0x30ee, 0x30ef, + 0x30f0, 0x30f1, 0x30f2, 0x30f3, 0x30f4, 0x30f5, 0x30f6, 0x0414, + 0x0415, 0x0401, 0x0416, 0x0417, 0x0418, 0x0419, 0x041a, 0x041b, + 0x041c, 0x0423, 0x0424, 0x0425, 0x0426, 0x0427, 0x0428, 0x0429, + 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, 0x042f, 0x0430, 0x0431, + 0x0432, 0x0433, 0x0434, 0x0435, 0x0451, 0x0436, 0x0437, 0x0438, + 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, 0x0440, + 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, 0x0448, + 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x044f, 0x2460, + 0x2461, 0x2462, 0x2463, 0x2464, 0x2465, 0x2466, 0x2467, 0x2468, + 0x2469, 0x2474, 0x2475, 0x2476, 0x2477, 0x2478, 0x2479, 0x247a, + 0x247b, 0x247c, 0x247d, +}; +static const unsigned short big5_2uni_pagec9[7652] = { + /* 0xc9 */ + 0x4e42, 0x4e5c, 0x51f5, 0x531a, 0x5382, 0x4e07, 0x4e0c, 0x4e47, + 0x4e8d, 0x56d7, 0xfa0c, 0x5c6e, 0x5f73, 0x4e0f, 0x5187, 0x4e0e, + 0x4e2e, 0x4e93, 0x4ec2, 0x4ec9, 0x4ec8, 0x5198, 0x52fc, 0x536c, + 0x53b9, 0x5720, 0x5903, 0x592c, 0x5c10, 0x5dff, 0x65e1, 0x6bb3, + 0x6bcc, 0x6c14, 0x723f, 0x4e31, 0x4e3c, 0x4ee8, 0x4edc, 0x4ee9, + 0x4ee1, 0x4edd, 0x4eda, 0x520c, 0x531c, 0x534c, 0x5722, 0x5723, + 0x5917, 0x592f, 0x5b81, 0x5b84, 0x5c12, 0x5c3b, 0x5c74, 0x5c73, + 0x5e04, 0x5e80, 0x5e82, 0x5fc9, 0x6209, 0x6250, 0x6c15, 0x6c36, + 0x6c43, 0x6c3f, 0x6c3b, 0x72ae, 0x72b0, 0x738a, 0x79b8, 0x808a, + 0x961e, 0x4f0e, 0x4f18, 0x4f2c, 0x4ef5, 0x4f14, 0x4ef1, 0x4f00, + 0x4ef7, 0x4f08, 0x4f1d, 0x4f02, 0x4f05, 0x4f22, 0x4f13, 0x4f04, + 0x4ef4, 0x4f12, 0x51b1, 0x5213, 0x5209, 0x5210, 0x52a6, 0x5322, + 0x531f, 0x534d, 0x538a, 0x5407, 0x56e1, 0x56df, 0x572e, 0x572a, + 0x5734, 0x593c, 0x5980, 0x597c, 0x5985, 0x597b, 0x597e, 0x5977, + 0x597f, 0x5b56, 0x5c15, 0x5c25, 0x5c7c, 0x5c7a, 0x5c7b, 0x5c7e, + 0x5ddf, 0x5e75, 0x5e84, 0x5f02, 0x5f1a, 0x5f74, 0x5fd5, 0x5fd4, + 0x5fcf, 0x625c, 0x625e, 0x6264, 0x6261, 0x6266, 0x6262, 0x6259, + 0x6260, 0x625a, 0x6265, 0x65ef, 0x65ee, 0x673e, 0x6739, 0x6738, + 0x673b, 0x673a, 0x673f, 0x673c, 0x6733, 0x6c18, 0x6c46, 0x6c52, + 0x6c5c, 0x6c4f, 0x6c4a, 0x6c54, 0x6c4b, + /* 0xca */ + 0x6c4c, 0x7071, 0x725e, 0x72b4, 0x72b5, 0x738e, 0x752a, 0x767f, + 0x7a75, 0x7f51, 0x8278, 0x827c, 0x8280, 0x827d, 0x827f, 0x864d, + 0x897e, 0x9099, 0x9097, 0x9098, 0x909b, 0x9094, 0x9622, 0x9624, + 0x9620, 0x9623, 0x4f56, 0x4f3b, 0x4f62, 0x4f49, 0x4f53, 0x4f64, + 0x4f3e, 0x4f67, 0x4f52, 0x4f5f, 0x4f41, 0x4f58, 0x4f2d, 0x4f33, + 0x4f3f, 0x4f61, 0x518f, 0x51b9, 0x521c, 0x521e, 0x5221, 0x52ad, + 0x52ae, 0x5309, 0x5363, 0x5372, 0x538e, 0x538f, 0x5430, 0x5437, + 0x542a, 0x5454, 0x5445, 0x5419, 0x541c, 0x5425, 0x5418, 0x543d, + 0x544f, 0x5441, 0x5428, 0x5424, 0x5447, 0x56ee, 0x56e7, 0x56e5, + 0x5741, 0x5745, 0x574c, 0x5749, 0x574b, 0x5752, 0x5906, 0x5940, + 0x59a6, 0x5998, 0x59a0, 0x5997, 0x598e, 0x59a2, 0x5990, 0x598f, + 0x59a7, 0x59a1, 0x5b8e, 0x5b92, 0x5c28, 0x5c2a, 0x5c8d, 0x5c8f, + 0x5c88, 0x5c8b, 0x5c89, 0x5c92, 0x5c8a, 0x5c86, 0x5c93, 0x5c95, + 0x5de0, 0x5e0a, 0x5e0e, 0x5e8b, 0x5e89, 0x5e8c, 0x5e88, 0x5e8d, + 0x5f05, 0x5f1d, 0x5f78, 0x5f76, 0x5fd2, 0x5fd1, 0x5fd0, 0x5fed, + 0x5fe8, 0x5fee, 0x5ff3, 0x5fe1, 0x5fe4, 0x5fe3, 0x5ffa, 0x5fef, + 0x5ff7, 0x5ffb, 0x6000, 0x5ff4, 0x623a, 0x6283, 0x628c, 0x628e, + 0x628f, 0x6294, 0x6287, 0x6271, 0x627b, 0x627a, 0x6270, 0x6281, + 0x6288, 0x6277, 0x627d, 0x6272, 0x6274, 0x6537, 0x65f0, 0x65f4, + 0x65f3, 0x65f2, 0x65f5, 0x6745, 0x6747, + /* 0xcb */ + 0x6759, 0x6755, 0x674c, 0x6748, 0x675d, 0x674d, 0x675a, 0x674b, + 0x6bd0, 0x6c19, 0x6c1a, 0x6c78, 0x6c67, 0x6c6b, 0x6c84, 0x6c8b, + 0x6c8f, 0x6c71, 0x6c6f, 0x6c69, 0x6c9a, 0x6c6d, 0x6c87, 0x6c95, + 0x6c9c, 0x6c66, 0x6c73, 0x6c65, 0x6c7b, 0x6c8e, 0x7074, 0x707a, + 0x7263, 0x72bf, 0x72bd, 0x72c3, 0x72c6, 0x72c1, 0x72ba, 0x72c5, + 0x7395, 0x7397, 0x7393, 0x7394, 0x7392, 0x753a, 0x7539, 0x7594, + 0x7595, 0x7681, 0x793d, 0x8034, 0x8095, 0x8099, 0x8090, 0x8092, + 0x809c, 0x8290, 0x828f, 0x8285, 0x828e, 0x8291, 0x8293, 0x828a, + 0x8283, 0x8284, 0x8c78, 0x8fc9, 0x8fbf, 0x909f, 0x90a1, 0x90a5, + 0x909e, 0x90a7, 0x90a0, 0x9630, 0x9628, 0x962f, 0x962d, 0x4e33, + 0x4f98, 0x4f7c, 0x4f85, 0x4f7d, 0x4f80, 0x4f87, 0x4f76, 0x4f74, + 0x4f89, 0x4f84, 0x4f77, 0x4f4c, 0x4f97, 0x4f6a, 0x4f9a, 0x4f79, + 0x4f81, 0x4f78, 0x4f90, 0x4f9c, 0x4f94, 0x4f9e, 0x4f92, 0x4f82, + 0x4f95, 0x4f6b, 0x4f6e, 0x519e, 0x51bc, 0x51be, 0x5235, 0x5232, + 0x5233, 0x5246, 0x5231, 0x52bc, 0x530a, 0x530b, 0x533c, 0x5392, + 0x5394, 0x5487, 0x547f, 0x5481, 0x5491, 0x5482, 0x5488, 0x546b, + 0x547a, 0x547e, 0x5465, 0x546c, 0x5474, 0x5466, 0x548d, 0x546f, + 0x5461, 0x5460, 0x5498, 0x5463, 0x5467, 0x5464, 0x56f7, 0x56f9, + 0x576f, 0x5772, 0x576d, 0x576b, 0x5771, 0x5770, 0x5776, 0x5780, + 0x5775, 0x577b, 0x5773, 0x5774, 0x5762, + /* 0xcc */ + 0x5768, 0x577d, 0x590c, 0x5945, 0x59b5, 0x59ba, 0x59cf, 0x59ce, + 0x59b2, 0x59cc, 0x59c1, 0x59b6, 0x59bc, 0x59c3, 0x59d6, 0x59b1, + 0x59bd, 0x59c0, 0x59c8, 0x59b4, 0x59c7, 0x5b62, 0x5b65, 0x5b93, + 0x5b95, 0x5c44, 0x5c47, 0x5cae, 0x5ca4, 0x5ca0, 0x5cb5, 0x5caf, + 0x5ca8, 0x5cac, 0x5c9f, 0x5ca3, 0x5cad, 0x5ca2, 0x5caa, 0x5ca7, + 0x5c9d, 0x5ca5, 0x5cb6, 0x5cb0, 0x5ca6, 0x5e17, 0x5e14, 0x5e19, + 0x5f28, 0x5f22, 0x5f23, 0x5f24, 0x5f54, 0x5f82, 0x5f7e, 0x5f7d, + 0x5fde, 0x5fe5, 0x602d, 0x6026, 0x6019, 0x6032, 0x600b, 0x6034, + 0x600a, 0x6017, 0x6033, 0x601a, 0x601e, 0x602c, 0x6022, 0x600d, + 0x6010, 0x602e, 0x6013, 0x6011, 0x600c, 0x6009, 0x601c, 0x6214, + 0x623d, 0x62ad, 0x62b4, 0x62d1, 0x62be, 0x62aa, 0x62b6, 0x62ca, + 0x62ae, 0x62b3, 0x62af, 0x62bb, 0x62a9, 0x62b0, 0x62b8, 0x653d, + 0x65a8, 0x65bb, 0x6609, 0x65fc, 0x6604, 0x6612, 0x6608, 0x65fb, + 0x6603, 0x660b, 0x660d, 0x6605, 0x65fd, 0x6611, 0x6610, 0x66f6, + 0x670a, 0x6785, 0x676c, 0x678e, 0x6792, 0x6776, 0x677b, 0x6798, + 0x6786, 0x6784, 0x6774, 0x678d, 0x678c, 0x677a, 0x679f, 0x6791, + 0x6799, 0x6783, 0x677d, 0x6781, 0x6778, 0x6779, 0x6794, 0x6b25, + 0x6b80, 0x6b7e, 0x6bde, 0x6c1d, 0x6c93, 0x6cec, 0x6ceb, 0x6cee, + 0x6cd9, 0x6cb6, 0x6cd4, 0x6cad, 0x6ce7, 0x6cb7, 0x6cd0, 0x6cc2, + 0x6cba, 0x6cc3, 0x6cc6, 0x6ced, 0x6cf2, + /* 0xcd */ + 0x6cd2, 0x6cdd, 0x6cb4, 0x6c8a, 0x6c9d, 0x6c80, 0x6cde, 0x6cc0, + 0x6d30, 0x6ccd, 0x6cc7, 0x6cb0, 0x6cf9, 0x6ccf, 0x6ce9, 0x6cd1, + 0x7094, 0x7098, 0x7085, 0x7093, 0x7086, 0x7084, 0x7091, 0x7096, + 0x7082, 0x709a, 0x7083, 0x726a, 0x72d6, 0x72cb, 0x72d8, 0x72c9, + 0x72dc, 0x72d2, 0x72d4, 0x72da, 0x72cc, 0x72d1, 0x73a4, 0x73a1, + 0x73ad, 0x73a6, 0x73a2, 0x73a0, 0x73ac, 0x739d, 0x74dd, 0x74e8, + 0x753f, 0x7540, 0x753e, 0x758c, 0x7598, 0x76af, 0x76f3, 0x76f1, + 0x76f0, 0x76f5, 0x77f8, 0x77fc, 0x77f9, 0x77fb, 0x77fa, 0x77f7, + 0x7942, 0x793f, 0x79c5, 0x7a78, 0x7a7b, 0x7afb, 0x7c75, 0x7cfd, + 0x8035, 0x808f, 0x80ae, 0x80a3, 0x80b8, 0x80b5, 0x80ad, 0x8220, + 0x82a0, 0x82c0, 0x82ab, 0x829a, 0x8298, 0x829b, 0x82b5, 0x82a7, + 0x82ae, 0x82bc, 0x829e, 0x82ba, 0x82b4, 0x82a8, 0x82a1, 0x82a9, + 0x82c2, 0x82a4, 0x82c3, 0x82b6, 0x82a2, 0x8670, 0x866f, 0x866d, + 0x866e, 0x8c56, 0x8fd2, 0x8fcb, 0x8fd3, 0x8fcd, 0x8fd6, 0x8fd5, + 0x8fd7, 0x90b2, 0x90b4, 0x90af, 0x90b3, 0x90b0, 0x9639, 0x963d, + 0x963c, 0x963a, 0x9643, 0x4fcd, 0x4fc5, 0x4fd3, 0x4fb2, 0x4fc9, + 0x4fcb, 0x4fc1, 0x4fd4, 0x4fdc, 0x4fd9, 0x4fbb, 0x4fb3, 0x4fdb, + 0x4fc7, 0x4fd6, 0x4fba, 0x4fc0, 0x4fb9, 0x4fec, 0x5244, 0x5249, + 0x52c0, 0x52c2, 0x533d, 0x537c, 0x5397, 0x5396, 0x5399, 0x5398, + 0x54ba, 0x54a1, 0x54ad, 0x54a5, 0x54cf, + /* 0xce */ + 0x54c3, 0x830d, 0x54b7, 0x54ae, 0x54d6, 0x54b6, 0x54c5, 0x54c6, + 0x54a0, 0x5470, 0x54bc, 0x54a2, 0x54be, 0x5472, 0x54de, 0x54b0, + 0x57b5, 0x579e, 0x579f, 0x57a4, 0x578c, 0x5797, 0x579d, 0x579b, + 0x5794, 0x5798, 0x578f, 0x5799, 0x57a5, 0x579a, 0x5795, 0x58f4, + 0x590d, 0x5953, 0x59e1, 0x59de, 0x59ee, 0x5a00, 0x59f1, 0x59dd, + 0x59fa, 0x59fd, 0x59fc, 0x59f6, 0x59e4, 0x59f2, 0x59f7, 0x59db, + 0x59e9, 0x59f3, 0x59f5, 0x59e0, 0x59fe, 0x59f4, 0x59ed, 0x5ba8, + 0x5c4c, 0x5cd0, 0x5cd8, 0x5ccc, 0x5cd7, 0x5ccb, 0x5cdb, 0x5cde, + 0x5cda, 0x5cc9, 0x5cc7, 0x5cca, 0x5cd6, 0x5cd3, 0x5cd4, 0x5ccf, + 0x5cc8, 0x5cc6, 0x5cce, 0x5cdf, 0x5cf8, 0x5df9, 0x5e21, 0x5e22, + 0x5e23, 0x5e20, 0x5e24, 0x5eb0, 0x5ea4, 0x5ea2, 0x5e9b, 0x5ea3, + 0x5ea5, 0x5f07, 0x5f2e, 0x5f56, 0x5f86, 0x6037, 0x6039, 0x6054, + 0x6072, 0x605e, 0x6045, 0x6053, 0x6047, 0x6049, 0x605b, 0x604c, + 0x6040, 0x6042, 0x605f, 0x6024, 0x6044, 0x6058, 0x6066, 0x606e, + 0x6242, 0x6243, 0x62cf, 0x630d, 0x630b, 0x62f5, 0x630e, 0x6303, + 0x62eb, 0x62f9, 0x630f, 0x630c, 0x62f8, 0x62f6, 0x6300, 0x6313, + 0x6314, 0x62fa, 0x6315, 0x62fb, 0x62f0, 0x6541, 0x6543, 0x65aa, + 0x65bf, 0x6636, 0x6621, 0x6632, 0x6635, 0x661c, 0x6626, 0x6622, + 0x6633, 0x662b, 0x663a, 0x661d, 0x6634, 0x6639, 0x662e, 0x670f, + 0x6710, 0x67c1, 0x67f2, 0x67c8, 0x67ba, + /* 0xcf */ + 0x67dc, 0x67bb, 0x67f8, 0x67d8, 0x67c0, 0x67b7, 0x67c5, 0x67eb, + 0x67e4, 0x67df, 0x67b5, 0x67cd, 0x67b3, 0x67f7, 0x67f6, 0x67ee, + 0x67e3, 0x67c2, 0x67b9, 0x67ce, 0x67e7, 0x67f0, 0x67b2, 0x67fc, + 0x67c6, 0x67ed, 0x67cc, 0x67ae, 0x67e6, 0x67db, 0x67fa, 0x67c9, + 0x67ca, 0x67c3, 0x67ea, 0x67cb, 0x6b28, 0x6b82, 0x6b84, 0x6bb6, + 0x6bd6, 0x6bd8, 0x6be0, 0x6c20, 0x6c21, 0x6d28, 0x6d34, 0x6d2d, + 0x6d1f, 0x6d3c, 0x6d3f, 0x6d12, 0x6d0a, 0x6cda, 0x6d33, 0x6d04, + 0x6d19, 0x6d3a, 0x6d1a, 0x6d11, 0x6d00, 0x6d1d, 0x6d42, 0x6d01, + 0x6d18, 0x6d37, 0x6d03, 0x6d0f, 0x6d40, 0x6d07, 0x6d20, 0x6d2c, + 0x6d08, 0x6d22, 0x6d09, 0x6d10, 0x70b7, 0x709f, 0x70be, 0x70b1, + 0x70b0, 0x70a1, 0x70b4, 0x70b5, 0x70a9, 0x7241, 0x7249, 0x724a, + 0x726c, 0x7270, 0x7273, 0x726e, 0x72ca, 0x72e4, 0x72e8, 0x72eb, + 0x72df, 0x72ea, 0x72e6, 0x72e3, 0x7385, 0x73cc, 0x73c2, 0x73c8, + 0x73c5, 0x73b9, 0x73b6, 0x73b5, 0x73b4, 0x73eb, 0x73bf, 0x73c7, + 0x73be, 0x73c3, 0x73c6, 0x73b8, 0x73cb, 0x74ec, 0x74ee, 0x752e, + 0x7547, 0x7548, 0x75a7, 0x75aa, 0x7679, 0x76c4, 0x7708, 0x7703, + 0x7704, 0x7705, 0x770a, 0x76f7, 0x76fb, 0x76fa, 0x77e7, 0x77e8, + 0x7806, 0x7811, 0x7812, 0x7805, 0x7810, 0x780f, 0x780e, 0x7809, + 0x7803, 0x7813, 0x794a, 0x794c, 0x794b, 0x7945, 0x7944, 0x79d5, + 0x79cd, 0x79cf, 0x79d6, 0x79ce, 0x7a80, + /* 0xd0 */ + 0x7a7e, 0x7ad1, 0x7b00, 0x7b01, 0x7c7a, 0x7c78, 0x7c79, 0x7c7f, + 0x7c80, 0x7c81, 0x7d03, 0x7d08, 0x7d01, 0x7f58, 0x7f91, 0x7f8d, + 0x7fbe, 0x8007, 0x800e, 0x800f, 0x8014, 0x8037, 0x80d8, 0x80c7, + 0x80e0, 0x80d1, 0x80c8, 0x80c2, 0x80d0, 0x80c5, 0x80e3, 0x80d9, + 0x80dc, 0x80ca, 0x80d5, 0x80c9, 0x80cf, 0x80d7, 0x80e6, 0x80cd, + 0x81ff, 0x8221, 0x8294, 0x82d9, 0x82fe, 0x82f9, 0x8307, 0x82e8, + 0x8300, 0x82d5, 0x833a, 0x82eb, 0x82d6, 0x82f4, 0x82ec, 0x82e1, + 0x82f2, 0x82f5, 0x830c, 0x82fb, 0x82f6, 0x82f0, 0x82ea, 0x82e4, + 0x82e0, 0x82fa, 0x82f3, 0x82ed, 0x8677, 0x8674, 0x867c, 0x8673, + 0x8841, 0x884e, 0x8867, 0x886a, 0x8869, 0x89d3, 0x8a04, 0x8a07, + 0x8d72, 0x8fe3, 0x8fe1, 0x8fee, 0x8fe0, 0x90f1, 0x90bd, 0x90bf, + 0x90d5, 0x90c5, 0x90be, 0x90c7, 0x90cb, 0x90c8, 0x91d4, 0x91d3, + 0x9654, 0x964f, 0x9651, 0x9653, 0x964a, 0x964e, 0x501e, 0x5005, + 0x5007, 0x5013, 0x5022, 0x5030, 0x501b, 0x4ff5, 0x4ff4, 0x5033, + 0x5037, 0x502c, 0x4ff6, 0x4ff7, 0x5017, 0x501c, 0x5020, 0x5027, + 0x5035, 0x502f, 0x5031, 0x500e, 0x515a, 0x5194, 0x5193, 0x51ca, + 0x51c4, 0x51c5, 0x51c8, 0x51ce, 0x5261, 0x525a, 0x5252, 0x525e, + 0x525f, 0x5255, 0x5262, 0x52cd, 0x530e, 0x539e, 0x5526, 0x54e2, + 0x5517, 0x5512, 0x54e7, 0x54f3, 0x54e4, 0x551a, 0x54ff, 0x5504, + 0x5508, 0x54eb, 0x5511, 0x5505, 0x54f1, + /* 0xd1 */ + 0x550a, 0x54fb, 0x54f7, 0x54f8, 0x54e0, 0x550e, 0x5503, 0x550b, + 0x5701, 0x5702, 0x57cc, 0x5832, 0x57d5, 0x57d2, 0x57ba, 0x57c6, + 0x57bd, 0x57bc, 0x57b8, 0x57b6, 0x57bf, 0x57c7, 0x57d0, 0x57b9, + 0x57c1, 0x590e, 0x594a, 0x5a19, 0x5a16, 0x5a2d, 0x5a2e, 0x5a15, + 0x5a0f, 0x5a17, 0x5a0a, 0x5a1e, 0x5a33, 0x5b6c, 0x5ba7, 0x5bad, + 0x5bac, 0x5c03, 0x5c56, 0x5c54, 0x5cec, 0x5cff, 0x5cee, 0x5cf1, + 0x5cf7, 0x5d00, 0x5cf9, 0x5e29, 0x5e28, 0x5ea8, 0x5eae, 0x5eaa, + 0x5eac, 0x5f33, 0x5f30, 0x5f67, 0x605d, 0x605a, 0x6067, 0x6041, + 0x60a2, 0x6088, 0x6080, 0x6092, 0x6081, 0x609d, 0x6083, 0x6095, + 0x609b, 0x6097, 0x6087, 0x609c, 0x608e, 0x6219, 0x6246, 0x62f2, + 0x6310, 0x6356, 0x632c, 0x6344, 0x6345, 0x6336, 0x6343, 0x63e4, + 0x6339, 0x634b, 0x634a, 0x633c, 0x6329, 0x6341, 0x6334, 0x6358, + 0x6354, 0x6359, 0x632d, 0x6347, 0x6333, 0x635a, 0x6351, 0x6338, + 0x6357, 0x6340, 0x6348, 0x654a, 0x6546, 0x65c6, 0x65c3, 0x65c4, + 0x65c2, 0x664a, 0x665f, 0x6647, 0x6651, 0x6712, 0x6713, 0x681f, + 0x681a, 0x6849, 0x6832, 0x6833, 0x683b, 0x684b, 0x684f, 0x6816, + 0x6831, 0x681c, 0x6835, 0x682b, 0x682d, 0x682f, 0x684e, 0x6844, + 0x6834, 0x681d, 0x6812, 0x6814, 0x6826, 0x6828, 0x682e, 0x684d, + 0x683a, 0x6825, 0x6820, 0x6b2c, 0x6b2f, 0x6b2d, 0x6b31, 0x6b34, + 0x6b6d, 0x8082, 0x6b88, 0x6be6, 0x6be4, + /* 0xd2 */ + 0x6be8, 0x6be3, 0x6be2, 0x6be7, 0x6c25, 0x6d7a, 0x6d63, 0x6d64, + 0x6d76, 0x6d0d, 0x6d61, 0x6d92, 0x6d58, 0x6d62, 0x6d6d, 0x6d6f, + 0x6d91, 0x6d8d, 0x6def, 0x6d7f, 0x6d86, 0x6d5e, 0x6d67, 0x6d60, + 0x6d97, 0x6d70, 0x6d7c, 0x6d5f, 0x6d82, 0x6d98, 0x6d2f, 0x6d68, + 0x6d8b, 0x6d7e, 0x6d80, 0x6d84, 0x6d16, 0x6d83, 0x6d7b, 0x6d7d, + 0x6d75, 0x6d90, 0x70dc, 0x70d3, 0x70d1, 0x70dd, 0x70cb, 0x7f39, + 0x70e2, 0x70d7, 0x70d2, 0x70de, 0x70e0, 0x70d4, 0x70cd, 0x70c5, + 0x70c6, 0x70c7, 0x70da, 0x70ce, 0x70e1, 0x7242, 0x7278, 0x7277, + 0x7276, 0x7300, 0x72fa, 0x72f4, 0x72fe, 0x72f6, 0x72f3, 0x72fb, + 0x7301, 0x73d3, 0x73d9, 0x73e5, 0x73d6, 0x73bc, 0x73e7, 0x73e3, + 0x73e9, 0x73dc, 0x73d2, 0x73db, 0x73d4, 0x73dd, 0x73da, 0x73d7, + 0x73d8, 0x73e8, 0x74de, 0x74df, 0x74f4, 0x74f5, 0x7521, 0x755b, + 0x755f, 0x75b0, 0x75c1, 0x75bb, 0x75c4, 0x75c0, 0x75bf, 0x75b6, + 0x75ba, 0x768a, 0x76c9, 0x771d, 0x771b, 0x7710, 0x7713, 0x7712, + 0x7723, 0x7711, 0x7715, 0x7719, 0x771a, 0x7722, 0x7727, 0x7823, + 0x782c, 0x7822, 0x7835, 0x782f, 0x7828, 0x782e, 0x782b, 0x7821, + 0x7829, 0x7833, 0x782a, 0x7831, 0x7954, 0x795b, 0x794f, 0x795c, + 0x7953, 0x7952, 0x7951, 0x79eb, 0x79ec, 0x79e0, 0x79ee, 0x79ed, + 0x79ea, 0x79dc, 0x79de, 0x79dd, 0x7a86, 0x7a89, 0x7a85, 0x7a8b, + 0x7a8c, 0x7a8a, 0x7a87, 0x7ad8, 0x7b10, + /* 0xd3 */ + 0x7b04, 0x7b13, 0x7b05, 0x7b0f, 0x7b08, 0x7b0a, 0x7b0e, 0x7b09, + 0x7b12, 0x7c84, 0x7c91, 0x7c8a, 0x7c8c, 0x7c88, 0x7c8d, 0x7c85, + 0x7d1e, 0x7d1d, 0x7d11, 0x7d0e, 0x7d18, 0x7d16, 0x7d13, 0x7d1f, + 0x7d12, 0x7d0f, 0x7d0c, 0x7f5c, 0x7f61, 0x7f5e, 0x7f60, 0x7f5d, + 0x7f5b, 0x7f96, 0x7f92, 0x7fc3, 0x7fc2, 0x7fc0, 0x8016, 0x803e, + 0x8039, 0x80fa, 0x80f2, 0x80f9, 0x80f5, 0x8101, 0x80fb, 0x8100, + 0x8201, 0x822f, 0x8225, 0x8333, 0x832d, 0x8344, 0x8319, 0x8351, + 0x8325, 0x8356, 0x833f, 0x8341, 0x8326, 0x831c, 0x8322, 0x8342, + 0x834e, 0x831b, 0x832a, 0x8308, 0x833c, 0x834d, 0x8316, 0x8324, + 0x8320, 0x8337, 0x832f, 0x8329, 0x8347, 0x8345, 0x834c, 0x8353, + 0x831e, 0x832c, 0x834b, 0x8327, 0x8348, 0x8653, 0x8652, 0x86a2, + 0x86a8, 0x8696, 0x868d, 0x8691, 0x869e, 0x8687, 0x8697, 0x8686, + 0x868b, 0x869a, 0x8685, 0x86a5, 0x8699, 0x86a1, 0x86a7, 0x8695, + 0x8698, 0x868e, 0x869d, 0x8690, 0x8694, 0x8843, 0x8844, 0x886d, + 0x8875, 0x8876, 0x8872, 0x8880, 0x8871, 0x887f, 0x886f, 0x8883, + 0x887e, 0x8874, 0x887c, 0x8a12, 0x8c47, 0x8c57, 0x8c7b, 0x8ca4, + 0x8ca3, 0x8d76, 0x8d78, 0x8db5, 0x8db7, 0x8db6, 0x8ed1, 0x8ed3, + 0x8ffe, 0x8ff5, 0x9002, 0x8fff, 0x8ffb, 0x9004, 0x8ffc, 0x8ff6, + 0x90d6, 0x90e0, 0x90d9, 0x90da, 0x90e3, 0x90df, 0x90e5, 0x90d8, + 0x90db, 0x90d7, 0x90dc, 0x90e4, 0x9150, + /* 0xd4 */ + 0x914e, 0x914f, 0x91d5, 0x91e2, 0x91da, 0x965c, 0x965f, 0x96bc, + 0x98e3, 0x9adf, 0x9b2f, 0x4e7f, 0x5070, 0x506a, 0x5061, 0x505e, + 0x5060, 0x5053, 0x504b, 0x505d, 0x5072, 0x5048, 0x504d, 0x5041, + 0x505b, 0x504a, 0x5062, 0x5015, 0x5045, 0x505f, 0x5069, 0x506b, + 0x5063, 0x5064, 0x5046, 0x5040, 0x506e, 0x5073, 0x5057, 0x5051, + 0x51d0, 0x526b, 0x526d, 0x526c, 0x526e, 0x52d6, 0x52d3, 0x532d, + 0x539c, 0x5575, 0x5576, 0x553c, 0x554d, 0x5550, 0x5534, 0x552a, + 0x5551, 0x5562, 0x5536, 0x5535, 0x5530, 0x5552, 0x5545, 0x550c, + 0x5532, 0x5565, 0x554e, 0x5539, 0x5548, 0x552d, 0x553b, 0x5540, + 0x554b, 0x570a, 0x5707, 0x57fb, 0x5814, 0x57e2, 0x57f6, 0x57dc, + 0x57f4, 0x5800, 0x57ed, 0x57fd, 0x5808, 0x57f8, 0x580b, 0x57f3, + 0x57cf, 0x5807, 0x57ee, 0x57e3, 0x57f2, 0x57e5, 0x57ec, 0x57e1, + 0x580e, 0x57fc, 0x5810, 0x57e7, 0x5801, 0x580c, 0x57f1, 0x57e9, + 0x57f0, 0x580d, 0x5804, 0x595c, 0x5a60, 0x5a58, 0x5a55, 0x5a67, + 0x5a5e, 0x5a38, 0x5a35, 0x5a6d, 0x5a50, 0x5a5f, 0x5a65, 0x5a6c, + 0x5a53, 0x5a64, 0x5a57, 0x5a43, 0x5a5d, 0x5a52, 0x5a44, 0x5a5b, + 0x5a48, 0x5a8e, 0x5a3e, 0x5a4d, 0x5a39, 0x5a4c, 0x5a70, 0x5a69, + 0x5a47, 0x5a51, 0x5a56, 0x5a42, 0x5a5c, 0x5b72, 0x5b6e, 0x5bc1, + 0x5bc0, 0x5c59, 0x5d1e, 0x5d0b, 0x5d1d, 0x5d1a, 0x5d20, 0x5d0c, + 0x5d28, 0x5d0d, 0x5d26, 0x5d25, 0x5d0f, + /* 0xd5 */ + 0x5d30, 0x5d12, 0x5d23, 0x5d1f, 0x5d2e, 0x5e3e, 0x5e34, 0x5eb1, + 0x5eb4, 0x5eb9, 0x5eb2, 0x5eb3, 0x5f36, 0x5f38, 0x5f9b, 0x5f96, + 0x5f9f, 0x608a, 0x6090, 0x6086, 0x60be, 0x60b0, 0x60ba, 0x60d3, + 0x60d4, 0x60cf, 0x60e4, 0x60d9, 0x60dd, 0x60c8, 0x60b1, 0x60db, + 0x60b7, 0x60ca, 0x60bf, 0x60c3, 0x60cd, 0x60c0, 0x6332, 0x6365, + 0x638a, 0x6382, 0x637d, 0x63bd, 0x639e, 0x63ad, 0x639d, 0x6397, + 0x63ab, 0x638e, 0x636f, 0x6387, 0x6390, 0x636e, 0x63af, 0x6375, + 0x639c, 0x636d, 0x63ae, 0x637c, 0x63a4, 0x633b, 0x639f, 0x6378, + 0x6385, 0x6381, 0x6391, 0x638d, 0x6370, 0x6553, 0x65cd, 0x6665, + 0x6661, 0x665b, 0x6659, 0x665c, 0x6662, 0x6718, 0x6879, 0x6887, + 0x6890, 0x689c, 0x686d, 0x686e, 0x68ae, 0x68ab, 0x6956, 0x686f, + 0x68a3, 0x68ac, 0x68a9, 0x6875, 0x6874, 0x68b2, 0x688f, 0x6877, + 0x6892, 0x687c, 0x686b, 0x6872, 0x68aa, 0x6880, 0x6871, 0x687e, + 0x689b, 0x6896, 0x688b, 0x68a0, 0x6889, 0x68a4, 0x6878, 0x687b, + 0x6891, 0x688c, 0x688a, 0x687d, 0x6b36, 0x6b33, 0x6b37, 0x6b38, + 0x6b91, 0x6b8f, 0x6b8d, 0x6b8e, 0x6b8c, 0x6c2a, 0x6dc0, 0x6dab, + 0x6db4, 0x6db3, 0x6e74, 0x6dac, 0x6de9, 0x6de2, 0x6db7, 0x6df6, + 0x6dd4, 0x6e00, 0x6dc8, 0x6de0, 0x6ddf, 0x6dd6, 0x6dbe, 0x6de5, + 0x6ddc, 0x6ddd, 0x6ddb, 0x6df4, 0x6dca, 0x6dbd, 0x6ded, 0x6df0, + 0x6dba, 0x6dd5, 0x6dc2, 0x6dcf, 0x6dc9, + /* 0xd6 */ + 0x6dd0, 0x6df2, 0x6dd3, 0x6dfd, 0x6dd7, 0x6dcd, 0x6de3, 0x6dbb, + 0x70fa, 0x710d, 0x70f7, 0x7117, 0x70f4, 0x710c, 0x70f0, 0x7104, + 0x70f3, 0x7110, 0x70fc, 0x70ff, 0x7106, 0x7113, 0x7100, 0x70f8, + 0x70f6, 0x710b, 0x7102, 0x710e, 0x727e, 0x727b, 0x727c, 0x727f, + 0x731d, 0x7317, 0x7307, 0x7311, 0x7318, 0x730a, 0x7308, 0x72ff, + 0x730f, 0x731e, 0x7388, 0x73f6, 0x73f8, 0x73f5, 0x7404, 0x7401, + 0x73fd, 0x7407, 0x7400, 0x73fa, 0x73fc, 0x73ff, 0x740c, 0x740b, + 0x73f4, 0x7408, 0x7564, 0x7563, 0x75ce, 0x75d2, 0x75cf, 0x75cb, + 0x75cc, 0x75d1, 0x75d0, 0x768f, 0x7689, 0x76d3, 0x7739, 0x772f, + 0x772d, 0x7731, 0x7732, 0x7734, 0x7733, 0x773d, 0x7725, 0x773b, + 0x7735, 0x7848, 0x7852, 0x7849, 0x784d, 0x784a, 0x784c, 0x7826, + 0x7845, 0x7850, 0x7964, 0x7967, 0x7969, 0x796a, 0x7963, 0x796b, + 0x7961, 0x79bb, 0x79fa, 0x79f8, 0x79f6, 0x79f7, 0x7a8f, 0x7a94, + 0x7a90, 0x7b35, 0x7b47, 0x7b34, 0x7b25, 0x7b30, 0x7b22, 0x7b24, + 0x7b33, 0x7b18, 0x7b2a, 0x7b1d, 0x7b31, 0x7b2b, 0x7b2d, 0x7b2f, + 0x7b32, 0x7b38, 0x7b1a, 0x7b23, 0x7c94, 0x7c98, 0x7c96, 0x7ca3, + 0x7d35, 0x7d3d, 0x7d38, 0x7d36, 0x7d3a, 0x7d45, 0x7d2c, 0x7d29, + 0x7d41, 0x7d47, 0x7d3e, 0x7d3f, 0x7d4a, 0x7d3b, 0x7d28, 0x7f63, + 0x7f95, 0x7f9c, 0x7f9d, 0x7f9b, 0x7fca, 0x7fcb, 0x7fcd, 0x7fd0, + 0x7fd1, 0x7fc7, 0x7fcf, 0x7fc9, 0x801f, + /* 0xd7 */ + 0x801e, 0x801b, 0x8047, 0x8043, 0x8048, 0x8118, 0x8125, 0x8119, + 0x811b, 0x812d, 0x811f, 0x812c, 0x811e, 0x8121, 0x8115, 0x8127, + 0x811d, 0x8122, 0x8211, 0x8238, 0x8233, 0x823a, 0x8234, 0x8232, + 0x8274, 0x8390, 0x83a3, 0x83a8, 0x838d, 0x837a, 0x8373, 0x83a4, + 0x8374, 0x838f, 0x8381, 0x8395, 0x8399, 0x8375, 0x8394, 0x83a9, + 0x837d, 0x8383, 0x838c, 0x839d, 0x839b, 0x83aa, 0x838b, 0x837e, + 0x83a5, 0x83af, 0x8388, 0x8397, 0x83b0, 0x837f, 0x83a6, 0x8387, + 0x83ae, 0x8376, 0x839a, 0x8659, 0x8656, 0x86bf, 0x86b7, 0x86c2, + 0x86c1, 0x86c5, 0x86ba, 0x86b0, 0x86c8, 0x86b9, 0x86b3, 0x86b8, + 0x86cc, 0x86b4, 0x86bb, 0x86bc, 0x86c3, 0x86bd, 0x86be, 0x8852, + 0x8889, 0x8895, 0x88a8, 0x88a2, 0x88aa, 0x889a, 0x8891, 0x88a1, + 0x889f, 0x8898, 0x88a7, 0x8899, 0x889b, 0x8897, 0x88a4, 0x88ac, + 0x888c, 0x8893, 0x888e, 0x8982, 0x89d6, 0x89d9, 0x89d5, 0x8a30, + 0x8a27, 0x8a2c, 0x8a1e, 0x8c39, 0x8c3b, 0x8c5c, 0x8c5d, 0x8c7d, + 0x8ca5, 0x8d7d, 0x8d7b, 0x8d79, 0x8dbc, 0x8dc2, 0x8db9, 0x8dbf, + 0x8dc1, 0x8ed8, 0x8ede, 0x8edd, 0x8edc, 0x8ed7, 0x8ee0, 0x8ee1, + 0x9024, 0x900b, 0x9011, 0x901c, 0x900c, 0x9021, 0x90ef, 0x90ea, + 0x90f0, 0x90f4, 0x90f2, 0x90f3, 0x90d4, 0x90eb, 0x90ec, 0x90e9, + 0x9156, 0x9158, 0x915a, 0x9153, 0x9155, 0x91ec, 0x91f4, 0x91f1, + 0x91f3, 0x91f8, 0x91e4, 0x91f9, 0x91ea, + /* 0xd8 */ + 0x91eb, 0x91f7, 0x91e8, 0x91ee, 0x957a, 0x9586, 0x9588, 0x967c, + 0x966d, 0x966b, 0x9671, 0x966f, 0x96bf, 0x976a, 0x9804, 0x98e5, + 0x9997, 0x509b, 0x5095, 0x5094, 0x509e, 0x508b, 0x50a3, 0x5083, + 0x508c, 0x508e, 0x509d, 0x5068, 0x509c, 0x5092, 0x5082, 0x5087, + 0x515f, 0x51d4, 0x5312, 0x5311, 0x53a4, 0x53a7, 0x5591, 0x55a8, + 0x55a5, 0x55ad, 0x5577, 0x5645, 0x55a2, 0x5593, 0x5588, 0x558f, + 0x55b5, 0x5581, 0x55a3, 0x5592, 0x55a4, 0x557d, 0x558c, 0x55a6, + 0x557f, 0x5595, 0x55a1, 0x558e, 0x570c, 0x5829, 0x5837, 0x5819, + 0x581e, 0x5827, 0x5823, 0x5828, 0x57f5, 0x5848, 0x5825, 0x581c, + 0x581b, 0x5833, 0x583f, 0x5836, 0x582e, 0x5839, 0x5838, 0x582d, + 0x582c, 0x583b, 0x5961, 0x5aaf, 0x5a94, 0x5a9f, 0x5a7a, 0x5aa2, + 0x5a9e, 0x5a78, 0x5aa6, 0x5a7c, 0x5aa5, 0x5aac, 0x5a95, 0x5aae, + 0x5a37, 0x5a84, 0x5a8a, 0x5a97, 0x5a83, 0x5a8b, 0x5aa9, 0x5a7b, + 0x5a7d, 0x5a8c, 0x5a9c, 0x5a8f, 0x5a93, 0x5a9d, 0x5bea, 0x5bcd, + 0x5bcb, 0x5bd4, 0x5bd1, 0x5bca, 0x5bce, 0x5c0c, 0x5c30, 0x5d37, + 0x5d43, 0x5d6b, 0x5d41, 0x5d4b, 0x5d3f, 0x5d35, 0x5d51, 0x5d4e, + 0x5d55, 0x5d33, 0x5d3a, 0x5d52, 0x5d3d, 0x5d31, 0x5d59, 0x5d42, + 0x5d39, 0x5d49, 0x5d38, 0x5d3c, 0x5d32, 0x5d36, 0x5d40, 0x5d45, + 0x5e44, 0x5e41, 0x5f58, 0x5fa6, 0x5fa5, 0x5fab, 0x60c9, 0x60b9, + 0x60cc, 0x60e2, 0x60ce, 0x60c4, 0x6114, + /* 0xd9 */ + 0x60f2, 0x610a, 0x6116, 0x6105, 0x60f5, 0x6113, 0x60f8, 0x60fc, + 0x60fe, 0x60c1, 0x6103, 0x6118, 0x611d, 0x6110, 0x60ff, 0x6104, + 0x610b, 0x624a, 0x6394, 0x63b1, 0x63b0, 0x63ce, 0x63e5, 0x63e8, + 0x63ef, 0x63c3, 0x649d, 0x63f3, 0x63ca, 0x63e0, 0x63f6, 0x63d5, + 0x63f2, 0x63f5, 0x6461, 0x63df, 0x63be, 0x63dd, 0x63dc, 0x63c4, + 0x63d8, 0x63d3, 0x63c2, 0x63c7, 0x63cc, 0x63cb, 0x63c8, 0x63f0, + 0x63d7, 0x63d9, 0x6532, 0x6567, 0x656a, 0x6564, 0x655c, 0x6568, + 0x6565, 0x658c, 0x659d, 0x659e, 0x65ae, 0x65d0, 0x65d2, 0x667c, + 0x666c, 0x667b, 0x6680, 0x6671, 0x6679, 0x666a, 0x6672, 0x6701, + 0x690c, 0x68d3, 0x6904, 0x68dc, 0x692a, 0x68ec, 0x68ea, 0x68f1, + 0x690f, 0x68d6, 0x68f7, 0x68eb, 0x68e4, 0x68f6, 0x6913, 0x6910, + 0x68f3, 0x68e1, 0x6907, 0x68cc, 0x6908, 0x6970, 0x68b4, 0x6911, + 0x68ef, 0x68c6, 0x6914, 0x68f8, 0x68d0, 0x68fd, 0x68fc, 0x68e8, + 0x690b, 0x690a, 0x6917, 0x68ce, 0x68c8, 0x68dd, 0x68de, 0x68e6, + 0x68f4, 0x68d1, 0x6906, 0x68d4, 0x68e9, 0x6915, 0x6925, 0x68c7, + 0x6b39, 0x6b3b, 0x6b3f, 0x6b3c, 0x6b94, 0x6b97, 0x6b99, 0x6b95, + 0x6bbd, 0x6bf0, 0x6bf2, 0x6bf3, 0x6c30, 0x6dfc, 0x6e46, 0x6e47, + 0x6e1f, 0x6e49, 0x6e88, 0x6e3c, 0x6e3d, 0x6e45, 0x6e62, 0x6e2b, + 0x6e3f, 0x6e41, 0x6e5d, 0x6e73, 0x6e1c, 0x6e33, 0x6e4b, 0x6e40, + 0x6e51, 0x6e3b, 0x6e03, 0x6e2e, 0x6e5e, + /* 0xda */ + 0x6e68, 0x6e5c, 0x6e61, 0x6e31, 0x6e28, 0x6e60, 0x6e71, 0x6e6b, + 0x6e39, 0x6e22, 0x6e30, 0x6e53, 0x6e65, 0x6e27, 0x6e78, 0x6e64, + 0x6e77, 0x6e55, 0x6e79, 0x6e52, 0x6e66, 0x6e35, 0x6e36, 0x6e5a, + 0x7120, 0x711e, 0x712f, 0x70fb, 0x712e, 0x7131, 0x7123, 0x7125, + 0x7122, 0x7132, 0x711f, 0x7128, 0x713a, 0x711b, 0x724b, 0x725a, + 0x7288, 0x7289, 0x7286, 0x7285, 0x728b, 0x7312, 0x730b, 0x7330, + 0x7322, 0x7331, 0x7333, 0x7327, 0x7332, 0x732d, 0x7326, 0x7323, + 0x7335, 0x730c, 0x742e, 0x742c, 0x7430, 0x742b, 0x7416, 0x741a, + 0x7421, 0x742d, 0x7431, 0x7424, 0x7423, 0x741d, 0x7429, 0x7420, + 0x7432, 0x74fb, 0x752f, 0x756f, 0x756c, 0x75e7, 0x75da, 0x75e1, + 0x75e6, 0x75dd, 0x75df, 0x75e4, 0x75d7, 0x7695, 0x7692, 0x76da, + 0x7746, 0x7747, 0x7744, 0x774d, 0x7745, 0x774a, 0x774e, 0x774b, + 0x774c, 0x77de, 0x77ec, 0x7860, 0x7864, 0x7865, 0x785c, 0x786d, + 0x7871, 0x786a, 0x786e, 0x7870, 0x7869, 0x7868, 0x785e, 0x7862, + 0x7974, 0x7973, 0x7972, 0x7970, 0x7a02, 0x7a0a, 0x7a03, 0x7a0c, + 0x7a04, 0x7a99, 0x7ae6, 0x7ae4, 0x7b4a, 0x7b3b, 0x7b44, 0x7b48, + 0x7b4c, 0x7b4e, 0x7b40, 0x7b58, 0x7b45, 0x7ca2, 0x7c9e, 0x7ca8, + 0x7ca1, 0x7d58, 0x7d6f, 0x7d63, 0x7d53, 0x7d56, 0x7d67, 0x7d6a, + 0x7d4f, 0x7d6d, 0x7d5c, 0x7d6b, 0x7d52, 0x7d54, 0x7d69, 0x7d51, + 0x7d5f, 0x7d4e, 0x7f3e, 0x7f3f, 0x7f65, + /* 0xdb */ + 0x7f66, 0x7fa2, 0x7fa0, 0x7fa1, 0x7fd7, 0x8051, 0x804f, 0x8050, + 0x80fe, 0x80d4, 0x8143, 0x814a, 0x8152, 0x814f, 0x8147, 0x813d, + 0x814d, 0x813a, 0x81e6, 0x81ee, 0x81f7, 0x81f8, 0x81f9, 0x8204, + 0x823c, 0x823d, 0x823f, 0x8275, 0x833b, 0x83cf, 0x83f9, 0x8423, + 0x83c0, 0x83e8, 0x8412, 0x83e7, 0x83e4, 0x83fc, 0x83f6, 0x8410, + 0x83c6, 0x83c8, 0x83eb, 0x83e3, 0x83bf, 0x8401, 0x83dd, 0x83e5, + 0x83d8, 0x83ff, 0x83e1, 0x83cb, 0x83ce, 0x83d6, 0x83f5, 0x83c9, + 0x8409, 0x840f, 0x83de, 0x8411, 0x8406, 0x83c2, 0x83f3, 0x83d5, + 0x83fa, 0x83c7, 0x83d1, 0x83ea, 0x8413, 0x83c3, 0x83ec, 0x83ee, + 0x83c4, 0x83fb, 0x83d7, 0x83e2, 0x841b, 0x83db, 0x83fe, 0x86d8, + 0x86e2, 0x86e6, 0x86d3, 0x86e3, 0x86da, 0x86ea, 0x86dd, 0x86eb, + 0x86dc, 0x86ec, 0x86e9, 0x86d7, 0x86e8, 0x86d1, 0x8848, 0x8856, + 0x8855, 0x88ba, 0x88d7, 0x88b9, 0x88b8, 0x88c0, 0x88be, 0x88b6, + 0x88bc, 0x88b7, 0x88bd, 0x88b2, 0x8901, 0x88c9, 0x8995, 0x8998, + 0x8997, 0x89dd, 0x89da, 0x89db, 0x8a4e, 0x8a4d, 0x8a39, 0x8a59, + 0x8a40, 0x8a57, 0x8a58, 0x8a44, 0x8a45, 0x8a52, 0x8a48, 0x8a51, + 0x8a4a, 0x8a4c, 0x8a4f, 0x8c5f, 0x8c81, 0x8c80, 0x8cba, 0x8cbe, + 0x8cb0, 0x8cb9, 0x8cb5, 0x8d84, 0x8d80, 0x8d89, 0x8dd8, 0x8dd3, + 0x8dcd, 0x8dc7, 0x8dd6, 0x8ddc, 0x8dcf, 0x8dd5, 0x8dd9, 0x8dc8, + 0x8dd7, 0x8dc5, 0x8eef, 0x8ef7, 0x8efa, + /* 0xdc */ + 0x8ef9, 0x8ee6, 0x8eee, 0x8ee5, 0x8ef5, 0x8ee7, 0x8ee8, 0x8ef6, + 0x8eeb, 0x8ef1, 0x8eec, 0x8ef4, 0x8ee9, 0x902d, 0x9034, 0x902f, + 0x9106, 0x912c, 0x9104, 0x90ff, 0x90fc, 0x9108, 0x90f9, 0x90fb, + 0x9101, 0x9100, 0x9107, 0x9105, 0x9103, 0x9161, 0x9164, 0x915f, + 0x9162, 0x9160, 0x9201, 0x920a, 0x9225, 0x9203, 0x921a, 0x9226, + 0x920f, 0x920c, 0x9200, 0x9212, 0x91ff, 0x91fd, 0x9206, 0x9204, + 0x9227, 0x9202, 0x921c, 0x9224, 0x9219, 0x9217, 0x9205, 0x9216, + 0x957b, 0x958d, 0x958c, 0x9590, 0x9687, 0x967e, 0x9688, 0x9689, + 0x9683, 0x9680, 0x96c2, 0x96c8, 0x96c3, 0x96f1, 0x96f0, 0x976c, + 0x9770, 0x976e, 0x9807, 0x98a9, 0x98eb, 0x9ce6, 0x9ef9, 0x4e83, + 0x4e84, 0x4eb6, 0x50bd, 0x50bf, 0x50c6, 0x50ae, 0x50c4, 0x50ca, + 0x50b4, 0x50c8, 0x50c2, 0x50b0, 0x50c1, 0x50ba, 0x50b1, 0x50cb, + 0x50c9, 0x50b6, 0x50b8, 0x51d7, 0x527a, 0x5278, 0x527b, 0x527c, + 0x55c3, 0x55db, 0x55cc, 0x55d0, 0x55cb, 0x55ca, 0x55dd, 0x55c0, + 0x55d4, 0x55c4, 0x55e9, 0x55bf, 0x55d2, 0x558d, 0x55cf, 0x55d5, + 0x55e2, 0x55d6, 0x55c8, 0x55f2, 0x55cd, 0x55d9, 0x55c2, 0x5714, + 0x5853, 0x5868, 0x5864, 0x584f, 0x584d, 0x5849, 0x586f, 0x5855, + 0x584e, 0x585d, 0x5859, 0x5865, 0x585b, 0x583d, 0x5863, 0x5871, + 0x58fc, 0x5ac7, 0x5ac4, 0x5acb, 0x5aba, 0x5ab8, 0x5ab1, 0x5ab5, + 0x5ab0, 0x5abf, 0x5ac8, 0x5abb, 0x5ac6, + /* 0xdd */ + 0x5ab7, 0x5ac0, 0x5aca, 0x5ab4, 0x5ab6, 0x5acd, 0x5ab9, 0x5a90, + 0x5bd6, 0x5bd8, 0x5bd9, 0x5c1f, 0x5c33, 0x5d71, 0x5d63, 0x5d4a, + 0x5d65, 0x5d72, 0x5d6c, 0x5d5e, 0x5d68, 0x5d67, 0x5d62, 0x5df0, + 0x5e4f, 0x5e4e, 0x5e4a, 0x5e4d, 0x5e4b, 0x5ec5, 0x5ecc, 0x5ec6, + 0x5ecb, 0x5ec7, 0x5f40, 0x5faf, 0x5fad, 0x60f7, 0x6149, 0x614a, + 0x612b, 0x6145, 0x6136, 0x6132, 0x612e, 0x6146, 0x612f, 0x614f, + 0x6129, 0x6140, 0x6220, 0x9168, 0x6223, 0x6225, 0x6224, 0x63c5, + 0x63f1, 0x63eb, 0x6410, 0x6412, 0x6409, 0x6420, 0x6424, 0x6433, + 0x6443, 0x641f, 0x6415, 0x6418, 0x6439, 0x6437, 0x6422, 0x6423, + 0x640c, 0x6426, 0x6430, 0x6428, 0x6441, 0x6435, 0x642f, 0x640a, + 0x641a, 0x6440, 0x6425, 0x6427, 0x640b, 0x63e7, 0x641b, 0x642e, + 0x6421, 0x640e, 0x656f, 0x6592, 0x65d3, 0x6686, 0x668c, 0x6695, + 0x6690, 0x668b, 0x668a, 0x6699, 0x6694, 0x6678, 0x6720, 0x6966, + 0x695f, 0x6938, 0x694e, 0x6962, 0x6971, 0x693f, 0x6945, 0x696a, + 0x6939, 0x6942, 0x6957, 0x6959, 0x697a, 0x6948, 0x6949, 0x6935, + 0x696c, 0x6933, 0x693d, 0x6965, 0x68f0, 0x6978, 0x6934, 0x6969, + 0x6940, 0x696f, 0x6944, 0x6976, 0x6958, 0x6941, 0x6974, 0x694c, + 0x693b, 0x694b, 0x6937, 0x695c, 0x694f, 0x6951, 0x6932, 0x6952, + 0x692f, 0x697b, 0x693c, 0x6b46, 0x6b45, 0x6b43, 0x6b42, 0x6b48, + 0x6b41, 0x6b9b, 0xfa0d, 0x6bfb, 0x6bfc, + /* 0xde */ + 0x6bf9, 0x6bf7, 0x6bf8, 0x6e9b, 0x6ed6, 0x6ec8, 0x6e8f, 0x6ec0, + 0x6e9f, 0x6e93, 0x6e94, 0x6ea0, 0x6eb1, 0x6eb9, 0x6ec6, 0x6ed2, + 0x6ebd, 0x6ec1, 0x6e9e, 0x6ec9, 0x6eb7, 0x6eb0, 0x6ecd, 0x6ea6, + 0x6ecf, 0x6eb2, 0x6ebe, 0x6ec3, 0x6edc, 0x6ed8, 0x6e99, 0x6e92, + 0x6e8e, 0x6e8d, 0x6ea4, 0x6ea1, 0x6ebf, 0x6eb3, 0x6ed0, 0x6eca, + 0x6e97, 0x6eae, 0x6ea3, 0x7147, 0x7154, 0x7152, 0x7163, 0x7160, + 0x7141, 0x715d, 0x7162, 0x7172, 0x7178, 0x716a, 0x7161, 0x7142, + 0x7158, 0x7143, 0x714b, 0x7170, 0x715f, 0x7150, 0x7153, 0x7144, + 0x714d, 0x715a, 0x724f, 0x728d, 0x728c, 0x7291, 0x7290, 0x728e, + 0x733c, 0x7342, 0x733b, 0x733a, 0x7340, 0x734a, 0x7349, 0x7444, + 0x744a, 0x744b, 0x7452, 0x7451, 0x7457, 0x7440, 0x744f, 0x7450, + 0x744e, 0x7442, 0x7446, 0x744d, 0x7454, 0x74e1, 0x74ff, 0x74fe, + 0x74fd, 0x751d, 0x7579, 0x7577, 0x6983, 0x75ef, 0x760f, 0x7603, + 0x75f7, 0x75fe, 0x75fc, 0x75f9, 0x75f8, 0x7610, 0x75fb, 0x75f6, + 0x75ed, 0x75f5, 0x75fd, 0x7699, 0x76b5, 0x76dd, 0x7755, 0x775f, + 0x7760, 0x7752, 0x7756, 0x775a, 0x7769, 0x7767, 0x7754, 0x7759, + 0x776d, 0x77e0, 0x7887, 0x789a, 0x7894, 0x788f, 0x7884, 0x7895, + 0x7885, 0x7886, 0x78a1, 0x7883, 0x7879, 0x7899, 0x7880, 0x7896, + 0x787b, 0x797c, 0x7982, 0x797d, 0x7979, 0x7a11, 0x7a18, 0x7a19, + 0x7a12, 0x7a17, 0x7a15, 0x7a22, 0x7a13, + /* 0xdf */ + 0x7a1b, 0x7a10, 0x7aa3, 0x7aa2, 0x7a9e, 0x7aeb, 0x7b66, 0x7b64, + 0x7b6d, 0x7b74, 0x7b69, 0x7b72, 0x7b65, 0x7b73, 0x7b71, 0x7b70, + 0x7b61, 0x7b78, 0x7b76, 0x7b63, 0x7cb2, 0x7cb4, 0x7caf, 0x7d88, + 0x7d86, 0x7d80, 0x7d8d, 0x7d7f, 0x7d85, 0x7d7a, 0x7d8e, 0x7d7b, + 0x7d83, 0x7d7c, 0x7d8c, 0x7d94, 0x7d84, 0x7d7d, 0x7d92, 0x7f6d, + 0x7f6b, 0x7f67, 0x7f68, 0x7f6c, 0x7fa6, 0x7fa5, 0x7fa7, 0x7fdb, + 0x7fdc, 0x8021, 0x8164, 0x8160, 0x8177, 0x815c, 0x8169, 0x815b, + 0x8162, 0x8172, 0x6721, 0x815e, 0x8176, 0x8167, 0x816f, 0x8144, + 0x8161, 0x821d, 0x8249, 0x8244, 0x8240, 0x8242, 0x8245, 0x84f1, + 0x843f, 0x8456, 0x8476, 0x8479, 0x848f, 0x848d, 0x8465, 0x8451, + 0x8440, 0x8486, 0x8467, 0x8430, 0x844d, 0x847d, 0x845a, 0x8459, + 0x8474, 0x8473, 0x845d, 0x8507, 0x845e, 0x8437, 0x843a, 0x8434, + 0x847a, 0x8443, 0x8478, 0x8432, 0x8445, 0x8429, 0x83d9, 0x844b, + 0x842f, 0x8442, 0x842d, 0x845f, 0x8470, 0x8439, 0x844e, 0x844c, + 0x8452, 0x846f, 0x84c5, 0x848e, 0x843b, 0x8447, 0x8436, 0x8433, + 0x8468, 0x847e, 0x8444, 0x842b, 0x8460, 0x8454, 0x846e, 0x8450, + 0x870b, 0x8704, 0x86f7, 0x870c, 0x86fa, 0x86d6, 0x86f5, 0x874d, + 0x86f8, 0x870e, 0x8709, 0x8701, 0x86f6, 0x870d, 0x8705, 0x88d6, + 0x88cb, 0x88cd, 0x88ce, 0x88de, 0x88db, 0x88da, 0x88cc, 0x88d0, + 0x8985, 0x899b, 0x89df, 0x89e5, 0x89e4, + /* 0xe0 */ + 0x89e1, 0x89e0, 0x89e2, 0x89dc, 0x89e6, 0x8a76, 0x8a86, 0x8a7f, + 0x8a61, 0x8a3f, 0x8a77, 0x8a82, 0x8a84, 0x8a75, 0x8a83, 0x8a81, + 0x8a74, 0x8a7a, 0x8c3c, 0x8c4b, 0x8c4a, 0x8c65, 0x8c64, 0x8c66, + 0x8c86, 0x8c84, 0x8c85, 0x8ccc, 0x8d68, 0x8d69, 0x8d91, 0x8d8c, + 0x8d8e, 0x8d8f, 0x8d8d, 0x8d93, 0x8d94, 0x8d90, 0x8d92, 0x8df0, + 0x8de0, 0x8dec, 0x8df1, 0x8dee, 0x8dd0, 0x8de9, 0x8de3, 0x8de2, + 0x8de7, 0x8df2, 0x8deb, 0x8df4, 0x8f06, 0x8eff, 0x8f01, 0x8f00, + 0x8f05, 0x8f07, 0x8f08, 0x8f02, 0x8f0b, 0x9052, 0x903f, 0x9044, + 0x9049, 0x903d, 0x9110, 0x910d, 0x910f, 0x9111, 0x9116, 0x9114, + 0x910b, 0x910e, 0x916e, 0x916f, 0x9248, 0x9252, 0x9230, 0x923a, + 0x9266, 0x9233, 0x9265, 0x925e, 0x9283, 0x922e, 0x924a, 0x9246, + 0x926d, 0x926c, 0x924f, 0x9260, 0x9267, 0x926f, 0x9236, 0x9261, + 0x9270, 0x9231, 0x9254, 0x9263, 0x9250, 0x9272, 0x924e, 0x9253, + 0x924c, 0x9256, 0x9232, 0x959f, 0x959c, 0x959e, 0x959b, 0x9692, + 0x9693, 0x9691, 0x9697, 0x96ce, 0x96fa, 0x96fd, 0x96f8, 0x96f5, + 0x9773, 0x9777, 0x9778, 0x9772, 0x980f, 0x980d, 0x980e, 0x98ac, + 0x98f6, 0x98f9, 0x99af, 0x99b2, 0x99b0, 0x99b5, 0x9aad, 0x9aab, + 0x9b5b, 0x9cea, 0x9ced, 0x9ce7, 0x9e80, 0x9efd, 0x50e6, 0x50d4, + 0x50d7, 0x50e8, 0x50f3, 0x50db, 0x50ea, 0x50dd, 0x50e4, 0x50d3, + 0x50ec, 0x50f0, 0x50ef, 0x50e3, 0x50e0, + /* 0xe1 */ + 0x51d8, 0x5280, 0x5281, 0x52e9, 0x52eb, 0x5330, 0x53ac, 0x5627, + 0x5615, 0x560c, 0x5612, 0x55fc, 0x560f, 0x561c, 0x5601, 0x5613, + 0x5602, 0x55fa, 0x561d, 0x5604, 0x55ff, 0x55f9, 0x5889, 0x587c, + 0x5890, 0x5898, 0x5886, 0x5881, 0x587f, 0x5874, 0x588b, 0x587a, + 0x5887, 0x5891, 0x588e, 0x5876, 0x5882, 0x5888, 0x587b, 0x5894, + 0x588f, 0x58fe, 0x596b, 0x5adc, 0x5aee, 0x5ae5, 0x5ad5, 0x5aea, + 0x5ada, 0x5aed, 0x5aeb, 0x5af3, 0x5ae2, 0x5ae0, 0x5adb, 0x5aec, + 0x5ade, 0x5add, 0x5ad9, 0x5ae8, 0x5adf, 0x5b77, 0x5be0, 0x5be3, + 0x5c63, 0x5d82, 0x5d80, 0x5d7d, 0x5d86, 0x5d7a, 0x5d81, 0x5d77, + 0x5d8a, 0x5d89, 0x5d88, 0x5d7e, 0x5d7c, 0x5d8d, 0x5d79, 0x5d7f, + 0x5e58, 0x5e59, 0x5e53, 0x5ed8, 0x5ed1, 0x5ed7, 0x5ece, 0x5edc, + 0x5ed5, 0x5ed9, 0x5ed2, 0x5ed4, 0x5f44, 0x5f43, 0x5f6f, 0x5fb6, + 0x612c, 0x6128, 0x6141, 0x615e, 0x6171, 0x6173, 0x6152, 0x6153, + 0x6172, 0x616c, 0x6180, 0x6174, 0x6154, 0x617a, 0x615b, 0x6165, + 0x613b, 0x616a, 0x6161, 0x6156, 0x6229, 0x6227, 0x622b, 0x642b, + 0x644d, 0x645b, 0x645d, 0x6474, 0x6476, 0x6472, 0x6473, 0x647d, + 0x6475, 0x6466, 0x64a6, 0x644e, 0x6482, 0x645e, 0x645c, 0x644b, + 0x6453, 0x6460, 0x6450, 0x647f, 0x643f, 0x646c, 0x646b, 0x6459, + 0x6465, 0x6477, 0x6573, 0x65a0, 0x66a1, 0x66a0, 0x669f, 0x6705, + 0x6704, 0x6722, 0x69b1, 0x69b6, 0x69c9, + /* 0xe2 */ + 0x69a0, 0x69ce, 0x6996, 0x69b0, 0x69ac, 0x69bc, 0x6991, 0x6999, + 0x698e, 0x69a7, 0x698d, 0x69a9, 0x69be, 0x69af, 0x69bf, 0x69c4, + 0x69bd, 0x69a4, 0x69d4, 0x69b9, 0x69ca, 0x699a, 0x69cf, 0x69b3, + 0x6993, 0x69aa, 0x69a1, 0x699e, 0x69d9, 0x6997, 0x6990, 0x69c2, + 0x69b5, 0x69a5, 0x69c6, 0x6b4a, 0x6b4d, 0x6b4b, 0x6b9e, 0x6b9f, + 0x6ba0, 0x6bc3, 0x6bc4, 0x6bfe, 0x6ece, 0x6ef5, 0x6ef1, 0x6f03, + 0x6f25, 0x6ef8, 0x6f37, 0x6efb, 0x6f2e, 0x6f09, 0x6f4e, 0x6f19, + 0x6f1a, 0x6f27, 0x6f18, 0x6f3b, 0x6f12, 0x6eed, 0x6f0a, 0x6f36, + 0x6f73, 0x6ef9, 0x6eee, 0x6f2d, 0x6f40, 0x6f30, 0x6f3c, 0x6f35, + 0x6eeb, 0x6f07, 0x6f0e, 0x6f43, 0x6f05, 0x6efd, 0x6ef6, 0x6f39, + 0x6f1c, 0x6efc, 0x6f3a, 0x6f1f, 0x6f0d, 0x6f1e, 0x6f08, 0x6f21, + 0x7187, 0x7190, 0x7189, 0x7180, 0x7185, 0x7182, 0x718f, 0x717b, + 0x7186, 0x7181, 0x7197, 0x7244, 0x7253, 0x7297, 0x7295, 0x7293, + 0x7343, 0x734d, 0x7351, 0x734c, 0x7462, 0x7473, 0x7471, 0x7475, + 0x7472, 0x7467, 0x746e, 0x7500, 0x7502, 0x7503, 0x757d, 0x7590, + 0x7616, 0x7608, 0x760c, 0x7615, 0x7611, 0x760a, 0x7614, 0x76b8, + 0x7781, 0x777c, 0x7785, 0x7782, 0x776e, 0x7780, 0x776f, 0x777e, + 0x7783, 0x78b2, 0x78aa, 0x78b4, 0x78ad, 0x78a8, 0x787e, 0x78ab, + 0x789e, 0x78a5, 0x78a0, 0x78ac, 0x78a2, 0x78a4, 0x7998, 0x798a, + 0x798b, 0x7996, 0x7995, 0x7994, 0x7993, + /* 0xe3 */ + 0x7997, 0x7988, 0x7992, 0x7990, 0x7a2b, 0x7a4a, 0x7a30, 0x7a2f, + 0x7a28, 0x7a26, 0x7aa8, 0x7aab, 0x7aac, 0x7aee, 0x7b88, 0x7b9c, + 0x7b8a, 0x7b91, 0x7b90, 0x7b96, 0x7b8d, 0x7b8c, 0x7b9b, 0x7b8e, + 0x7b85, 0x7b98, 0x5284, 0x7b99, 0x7ba4, 0x7b82, 0x7cbb, 0x7cbf, + 0x7cbc, 0x7cba, 0x7da7, 0x7db7, 0x7dc2, 0x7da3, 0x7daa, 0x7dc1, + 0x7dc0, 0x7dc5, 0x7d9d, 0x7dce, 0x7dc4, 0x7dc6, 0x7dcb, 0x7dcc, + 0x7daf, 0x7db9, 0x7d96, 0x7dbc, 0x7d9f, 0x7da6, 0x7dae, 0x7da9, + 0x7da1, 0x7dc9, 0x7f73, 0x7fe2, 0x7fe3, 0x7fe5, 0x7fde, 0x8024, + 0x805d, 0x805c, 0x8189, 0x8186, 0x8183, 0x8187, 0x818d, 0x818c, + 0x818b, 0x8215, 0x8497, 0x84a4, 0x84a1, 0x849f, 0x84ba, 0x84ce, + 0x84c2, 0x84ac, 0x84ae, 0x84ab, 0x84b9, 0x84b4, 0x84c1, 0x84cd, + 0x84aa, 0x849a, 0x84b1, 0x84d0, 0x849d, 0x84a7, 0x84bb, 0x84a2, + 0x8494, 0x84c7, 0x84cc, 0x849b, 0x84a9, 0x84af, 0x84a8, 0x84d6, + 0x8498, 0x84b6, 0x84cf, 0x84a0, 0x84d7, 0x84d4, 0x84d2, 0x84db, + 0x84b0, 0x8491, 0x8661, 0x8733, 0x8723, 0x8728, 0x876b, 0x8740, + 0x872e, 0x871e, 0x8721, 0x8719, 0x871b, 0x8743, 0x872c, 0x8741, + 0x873e, 0x8746, 0x8720, 0x8732, 0x872a, 0x872d, 0x873c, 0x8712, + 0x873a, 0x8731, 0x8735, 0x8742, 0x8726, 0x8727, 0x8738, 0x8724, + 0x871a, 0x8730, 0x8711, 0x88f7, 0x88e7, 0x88f1, 0x88f2, 0x88fa, + 0x88fe, 0x88ee, 0x88fc, 0x88f6, 0x88fb, + /* 0xe4 */ + 0x88f0, 0x88ec, 0x88eb, 0x899d, 0x89a1, 0x899f, 0x899e, 0x89e9, + 0x89eb, 0x89e8, 0x8aab, 0x8a99, 0x8a8b, 0x8a92, 0x8a8f, 0x8a96, + 0x8c3d, 0x8c68, 0x8c69, 0x8cd5, 0x8ccf, 0x8cd7, 0x8d96, 0x8e09, + 0x8e02, 0x8dff, 0x8e0d, 0x8dfd, 0x8e0a, 0x8e03, 0x8e07, 0x8e06, + 0x8e05, 0x8dfe, 0x8e00, 0x8e04, 0x8f10, 0x8f11, 0x8f0e, 0x8f0d, + 0x9123, 0x911c, 0x9120, 0x9122, 0x911f, 0x911d, 0x911a, 0x9124, + 0x9121, 0x911b, 0x917a, 0x9172, 0x9179, 0x9173, 0x92a5, 0x92a4, + 0x9276, 0x929b, 0x927a, 0x92a0, 0x9294, 0x92aa, 0x928d, 0x92a6, + 0x929a, 0x92ab, 0x9279, 0x9297, 0x927f, 0x92a3, 0x92ee, 0x928e, + 0x9282, 0x9295, 0x92a2, 0x927d, 0x9288, 0x92a1, 0x928a, 0x9286, + 0x928c, 0x9299, 0x92a7, 0x927e, 0x9287, 0x92a9, 0x929d, 0x928b, + 0x922d, 0x969e, 0x96a1, 0x96ff, 0x9758, 0x977d, 0x977a, 0x977e, + 0x9783, 0x9780, 0x9782, 0x977b, 0x9784, 0x9781, 0x977f, 0x97ce, + 0x97cd, 0x9816, 0x98ad, 0x98ae, 0x9902, 0x9900, 0x9907, 0x999d, + 0x999c, 0x99c3, 0x99b9, 0x99bb, 0x99ba, 0x99c2, 0x99bd, 0x99c7, + 0x9ab1, 0x9ae3, 0x9ae7, 0x9b3e, 0x9b3f, 0x9b60, 0x9b61, 0x9b5f, + 0x9cf1, 0x9cf2, 0x9cf5, 0x9ea7, 0x50ff, 0x5103, 0x5130, 0x50f8, + 0x5106, 0x5107, 0x50f6, 0x50fe, 0x510b, 0x510c, 0x50fd, 0x510a, + 0x528b, 0x528c, 0x52f1, 0x52ef, 0x5648, 0x5642, 0x564c, 0x5635, + 0x5641, 0x564a, 0x5649, 0x5646, 0x5658, + /* 0xe5 */ + 0x565a, 0x5640, 0x5633, 0x563d, 0x562c, 0x563e, 0x5638, 0x562a, + 0x563a, 0x571a, 0x58ab, 0x589d, 0x58b1, 0x58a0, 0x58a3, 0x58af, + 0x58ac, 0x58a5, 0x58a1, 0x58ff, 0x5aff, 0x5af4, 0x5afd, 0x5af7, + 0x5af6, 0x5b03, 0x5af8, 0x5b02, 0x5af9, 0x5b01, 0x5b07, 0x5b05, + 0x5b0f, 0x5c67, 0x5d99, 0x5d97, 0x5d9f, 0x5d92, 0x5da2, 0x5d93, + 0x5d95, 0x5da0, 0x5d9c, 0x5da1, 0x5d9a, 0x5d9e, 0x5e69, 0x5e5d, + 0x5e60, 0x5e5c, 0x7df3, 0x5edb, 0x5ede, 0x5ee1, 0x5f49, 0x5fb2, + 0x618b, 0x6183, 0x6179, 0x61b1, 0x61b0, 0x61a2, 0x6189, 0x619b, + 0x6193, 0x61af, 0x61ad, 0x619f, 0x6192, 0x61aa, 0x61a1, 0x618d, + 0x6166, 0x61b3, 0x622d, 0x646e, 0x6470, 0x6496, 0x64a0, 0x6485, + 0x6497, 0x649c, 0x648f, 0x648b, 0x648a, 0x648c, 0x64a3, 0x649f, + 0x6468, 0x64b1, 0x6498, 0x6576, 0x657a, 0x6579, 0x657b, 0x65b2, + 0x65b3, 0x66b5, 0x66b0, 0x66a9, 0x66b2, 0x66b7, 0x66aa, 0x66af, + 0x6a00, 0x6a06, 0x6a17, 0x69e5, 0x69f8, 0x6a15, 0x69f1, 0x69e4, + 0x6a20, 0x69ff, 0x69ec, 0x69e2, 0x6a1b, 0x6a1d, 0x69fe, 0x6a27, + 0x69f2, 0x69ee, 0x6a14, 0x69f7, 0x69e7, 0x6a40, 0x6a08, 0x69e6, + 0x69fb, 0x6a0d, 0x69fc, 0x69eb, 0x6a09, 0x6a04, 0x6a18, 0x6a25, + 0x6a0f, 0x69f6, 0x6a26, 0x6a07, 0x69f4, 0x6a16, 0x6b51, 0x6ba5, + 0x6ba3, 0x6ba2, 0x6ba6, 0x6c01, 0x6c00, 0x6bff, 0x6c02, 0x6f41, + 0x6f26, 0x6f7e, 0x6f87, 0x6fc6, 0x6f92, + /* 0xe6 */ + 0x6f8d, 0x6f89, 0x6f8c, 0x6f62, 0x6f4f, 0x6f85, 0x6f5a, 0x6f96, + 0x6f76, 0x6f6c, 0x6f82, 0x6f55, 0x6f72, 0x6f52, 0x6f50, 0x6f57, + 0x6f94, 0x6f93, 0x6f5d, 0x6f00, 0x6f61, 0x6f6b, 0x6f7d, 0x6f67, + 0x6f90, 0x6f53, 0x6f8b, 0x6f69, 0x6f7f, 0x6f95, 0x6f63, 0x6f77, + 0x6f6a, 0x6f7b, 0x71b2, 0x71af, 0x719b, 0x71b0, 0x71a0, 0x719a, + 0x71a9, 0x71b5, 0x719d, 0x71a5, 0x719e, 0x71a4, 0x71a1, 0x71aa, + 0x719c, 0x71a7, 0x71b3, 0x7298, 0x729a, 0x7358, 0x7352, 0x735e, + 0x735f, 0x7360, 0x735d, 0x735b, 0x7361, 0x735a, 0x7359, 0x7362, + 0x7487, 0x7489, 0x748a, 0x7486, 0x7481, 0x747d, 0x7485, 0x7488, + 0x747c, 0x7479, 0x7508, 0x7507, 0x757e, 0x7625, 0x761e, 0x7619, + 0x761d, 0x761c, 0x7623, 0x761a, 0x7628, 0x761b, 0x769c, 0x769d, + 0x769e, 0x769b, 0x778d, 0x778f, 0x7789, 0x7788, 0x78cd, 0x78bb, + 0x78cf, 0x78cc, 0x78d1, 0x78ce, 0x78d4, 0x78c8, 0x78c3, 0x78c4, + 0x78c9, 0x799a, 0x79a1, 0x79a0, 0x799c, 0x79a2, 0x799b, 0x6b76, + 0x7a39, 0x7ab2, 0x7ab4, 0x7ab3, 0x7bb7, 0x7bcb, 0x7bbe, 0x7bac, + 0x7bce, 0x7baf, 0x7bb9, 0x7bca, 0x7bb5, 0x7cc5, 0x7cc8, 0x7ccc, + 0x7ccb, 0x7df7, 0x7ddb, 0x7dea, 0x7de7, 0x7dd7, 0x7de1, 0x7e03, + 0x7dfa, 0x7de6, 0x7df6, 0x7df1, 0x7df0, 0x7dee, 0x7ddf, 0x7f76, + 0x7fac, 0x7fb0, 0x7fad, 0x7fed, 0x7feb, 0x7fea, 0x7fec, 0x7fe6, + 0x7fe8, 0x8064, 0x8067, 0x81a3, 0x819f, + /* 0xe7 */ + 0x819e, 0x8195, 0x81a2, 0x8199, 0x8197, 0x8216, 0x824f, 0x8253, + 0x8252, 0x8250, 0x824e, 0x8251, 0x8524, 0x853b, 0x850f, 0x8500, + 0x8529, 0x850e, 0x8509, 0x850d, 0x851f, 0x850a, 0x8527, 0x851c, + 0x84fb, 0x852b, 0x84fa, 0x8508, 0x850c, 0x84f4, 0x852a, 0x84f2, + 0x8515, 0x84f7, 0x84eb, 0x84f3, 0x84fc, 0x8512, 0x84ea, 0x84e9, + 0x8516, 0x84fe, 0x8528, 0x851d, 0x852e, 0x8502, 0x84fd, 0x851e, + 0x84f6, 0x8531, 0x8526, 0x84e7, 0x84e8, 0x84f0, 0x84ef, 0x84f9, + 0x8518, 0x8520, 0x8530, 0x850b, 0x8519, 0x852f, 0x8662, 0x8756, + 0x8763, 0x8764, 0x8777, 0x87e1, 0x8773, 0x8758, 0x8754, 0x875b, + 0x8752, 0x8761, 0x875a, 0x8751, 0x875e, 0x876d, 0x876a, 0x8750, + 0x874e, 0x875f, 0x875d, 0x876f, 0x876c, 0x877a, 0x876e, 0x875c, + 0x8765, 0x874f, 0x877b, 0x8775, 0x8762, 0x8767, 0x8769, 0x885a, + 0x8905, 0x890c, 0x8914, 0x890b, 0x8917, 0x8918, 0x8919, 0x8906, + 0x8916, 0x8911, 0x890e, 0x8909, 0x89a2, 0x89a4, 0x89a3, 0x89ed, + 0x89f0, 0x89ec, 0x8acf, 0x8ac6, 0x8ab8, 0x8ad3, 0x8ad1, 0x8ad4, + 0x8ad5, 0x8abb, 0x8ad7, 0x8abe, 0x8ac0, 0x8ac5, 0x8ad8, 0x8ac3, + 0x8aba, 0x8abd, 0x8ad9, 0x8c3e, 0x8c4d, 0x8c8f, 0x8ce5, 0x8cdf, + 0x8cd9, 0x8ce8, 0x8cda, 0x8cdd, 0x8ce7, 0x8da0, 0x8d9c, 0x8da1, + 0x8d9b, 0x8e20, 0x8e23, 0x8e25, 0x8e24, 0x8e2e, 0x8e15, 0x8e1b, + 0x8e16, 0x8e11, 0x8e19, 0x8e26, 0x8e27, + /* 0xe8 */ + 0x8e14, 0x8e12, 0x8e18, 0x8e13, 0x8e1c, 0x8e17, 0x8e1a, 0x8f2c, + 0x8f24, 0x8f18, 0x8f1a, 0x8f20, 0x8f23, 0x8f16, 0x8f17, 0x9073, + 0x9070, 0x906f, 0x9067, 0x906b, 0x912f, 0x912b, 0x9129, 0x912a, + 0x9132, 0x9126, 0x912e, 0x9185, 0x9186, 0x918a, 0x9181, 0x9182, + 0x9184, 0x9180, 0x92d0, 0x92c3, 0x92c4, 0x92c0, 0x92d9, 0x92b6, + 0x92cf, 0x92f1, 0x92df, 0x92d8, 0x92e9, 0x92d7, 0x92dd, 0x92cc, + 0x92ef, 0x92c2, 0x92e8, 0x92ca, 0x92c8, 0x92ce, 0x92e6, 0x92cd, + 0x92d5, 0x92c9, 0x92e0, 0x92de, 0x92e7, 0x92d1, 0x92d3, 0x92b5, + 0x92e1, 0x92c6, 0x92b4, 0x957c, 0x95ac, 0x95ab, 0x95ae, 0x95b0, + 0x96a4, 0x96a2, 0x96d3, 0x9705, 0x9708, 0x9702, 0x975a, 0x978a, + 0x978e, 0x9788, 0x97d0, 0x97cf, 0x981e, 0x981d, 0x9826, 0x9829, + 0x9828, 0x9820, 0x981b, 0x9827, 0x98b2, 0x9908, 0x98fa, 0x9911, + 0x9914, 0x9916, 0x9917, 0x9915, 0x99dc, 0x99cd, 0x99cf, 0x99d3, + 0x99d4, 0x99ce, 0x99c9, 0x99d6, 0x99d8, 0x99cb, 0x99d7, 0x99cc, + 0x9ab3, 0x9aec, 0x9aeb, 0x9af3, 0x9af2, 0x9af1, 0x9b46, 0x9b43, + 0x9b67, 0x9b74, 0x9b71, 0x9b66, 0x9b76, 0x9b75, 0x9b70, 0x9b68, + 0x9b64, 0x9b6c, 0x9cfc, 0x9cfa, 0x9cfd, 0x9cff, 0x9cf7, 0x9d07, + 0x9d00, 0x9cf9, 0x9cfb, 0x9d08, 0x9d05, 0x9d04, 0x9e83, 0x9ed3, + 0x9f0f, 0x9f10, 0x511c, 0x5113, 0x5117, 0x511a, 0x5111, 0x51de, + 0x5334, 0x53e1, 0x5670, 0x5660, 0x566e, + /* 0xe9 */ + 0x5673, 0x5666, 0x5663, 0x566d, 0x5672, 0x565e, 0x5677, 0x571c, + 0x571b, 0x58c8, 0x58bd, 0x58c9, 0x58bf, 0x58ba, 0x58c2, 0x58bc, + 0x58c6, 0x5b17, 0x5b19, 0x5b1b, 0x5b21, 0x5b14, 0x5b13, 0x5b10, + 0x5b16, 0x5b28, 0x5b1a, 0x5b20, 0x5b1e, 0x5bef, 0x5dac, 0x5db1, + 0x5da9, 0x5da7, 0x5db5, 0x5db0, 0x5dae, 0x5daa, 0x5da8, 0x5db2, + 0x5dad, 0x5daf, 0x5db4, 0x5e67, 0x5e68, 0x5e66, 0x5e6f, 0x5ee9, + 0x5ee7, 0x5ee6, 0x5ee8, 0x5ee5, 0x5f4b, 0x5fbc, 0x619d, 0x61a8, + 0x6196, 0x61c5, 0x61b4, 0x61c6, 0x61c1, 0x61cc, 0x61ba, 0x61bf, + 0x61b8, 0x618c, 0x64d7, 0x64d6, 0x64d0, 0x64cf, 0x64c9, 0x64bd, + 0x6489, 0x64c3, 0x64db, 0x64f3, 0x64d9, 0x6533, 0x657f, 0x657c, + 0x65a2, 0x66c8, 0x66be, 0x66c0, 0x66ca, 0x66cb, 0x66cf, 0x66bd, + 0x66bb, 0x66ba, 0x66cc, 0x6723, 0x6a34, 0x6a66, 0x6a49, 0x6a67, + 0x6a32, 0x6a68, 0x6a3e, 0x6a5d, 0x6a6d, 0x6a76, 0x6a5b, 0x6a51, + 0x6a28, 0x6a5a, 0x6a3b, 0x6a3f, 0x6a41, 0x6a6a, 0x6a64, 0x6a50, + 0x6a4f, 0x6a54, 0x6a6f, 0x6a69, 0x6a60, 0x6a3c, 0x6a5e, 0x6a56, + 0x6a55, 0x6a4d, 0x6a4e, 0x6a46, 0x6b55, 0x6b54, 0x6b56, 0x6ba7, + 0x6baa, 0x6bab, 0x6bc8, 0x6bc7, 0x6c04, 0x6c03, 0x6c06, 0x6fad, + 0x6fcb, 0x6fa3, 0x6fc7, 0x6fbc, 0x6fce, 0x6fc8, 0x6f5e, 0x6fc4, + 0x6fbd, 0x6f9e, 0x6fca, 0x6fa8, 0x7004, 0x6fa5, 0x6fae, 0x6fba, + 0x6fac, 0x6faa, 0x6fcf, 0x6fbf, 0x6fb8, + /* 0xea */ + 0x6fa2, 0x6fc9, 0x6fab, 0x6fcd, 0x6faf, 0x6fb2, 0x6fb0, 0x71c5, + 0x71c2, 0x71bf, 0x71b8, 0x71d6, 0x71c0, 0x71c1, 0x71cb, 0x71d4, + 0x71ca, 0x71c7, 0x71cf, 0x71bd, 0x71d8, 0x71bc, 0x71c6, 0x71da, + 0x71db, 0x729d, 0x729e, 0x7369, 0x7366, 0x7367, 0x736c, 0x7365, + 0x736b, 0x736a, 0x747f, 0x749a, 0x74a0, 0x7494, 0x7492, 0x7495, + 0x74a1, 0x750b, 0x7580, 0x762f, 0x762d, 0x7631, 0x763d, 0x7633, + 0x763c, 0x7635, 0x7632, 0x7630, 0x76bb, 0x76e6, 0x779a, 0x779d, + 0x77a1, 0x779c, 0x779b, 0x77a2, 0x77a3, 0x7795, 0x7799, 0x7797, + 0x78dd, 0x78e9, 0x78e5, 0x78ea, 0x78de, 0x78e3, 0x78db, 0x78e1, + 0x78e2, 0x78ed, 0x78df, 0x78e0, 0x79a4, 0x7a44, 0x7a48, 0x7a47, + 0x7ab6, 0x7ab8, 0x7ab5, 0x7ab1, 0x7ab7, 0x7bde, 0x7be3, 0x7be7, + 0x7bdd, 0x7bd5, 0x7be5, 0x7bda, 0x7be8, 0x7bf9, 0x7bd4, 0x7bea, + 0x7be2, 0x7bdc, 0x7beb, 0x7bd8, 0x7bdf, 0x7cd2, 0x7cd4, 0x7cd7, + 0x7cd0, 0x7cd1, 0x7e12, 0x7e21, 0x7e17, 0x7e0c, 0x7e1f, 0x7e20, + 0x7e13, 0x7e0e, 0x7e1c, 0x7e15, 0x7e1a, 0x7e22, 0x7e0b, 0x7e0f, + 0x7e16, 0x7e0d, 0x7e14, 0x7e25, 0x7e24, 0x7f43, 0x7f7b, 0x7f7c, + 0x7f7a, 0x7fb1, 0x7fef, 0x802a, 0x8029, 0x806c, 0x81b1, 0x81a6, + 0x81ae, 0x81b9, 0x81b5, 0x81ab, 0x81b0, 0x81ac, 0x81b4, 0x81b2, + 0x81b7, 0x81a7, 0x81f2, 0x8255, 0x8256, 0x8257, 0x8556, 0x8545, + 0x856b, 0x854d, 0x8553, 0x8561, 0x8558, + /* 0xeb */ + 0x8540, 0x8546, 0x8564, 0x8541, 0x8562, 0x8544, 0x8551, 0x8547, + 0x8563, 0x853e, 0x855b, 0x8571, 0x854e, 0x856e, 0x8575, 0x8555, + 0x8567, 0x8560, 0x858c, 0x8566, 0x855d, 0x8554, 0x8565, 0x856c, + 0x8663, 0x8665, 0x8664, 0x879b, 0x878f, 0x8797, 0x8793, 0x8792, + 0x8788, 0x8781, 0x8796, 0x8798, 0x8779, 0x8787, 0x87a3, 0x8785, + 0x8790, 0x8791, 0x879d, 0x8784, 0x8794, 0x879c, 0x879a, 0x8789, + 0x891e, 0x8926, 0x8930, 0x892d, 0x892e, 0x8927, 0x8931, 0x8922, + 0x8929, 0x8923, 0x892f, 0x892c, 0x891f, 0x89f1, 0x8ae0, 0x8ae2, + 0x8af2, 0x8af4, 0x8af5, 0x8add, 0x8b14, 0x8ae4, 0x8adf, 0x8af0, + 0x8ac8, 0x8ade, 0x8ae1, 0x8ae8, 0x8aff, 0x8aef, 0x8afb, 0x8c91, + 0x8c92, 0x8c90, 0x8cf5, 0x8cee, 0x8cf1, 0x8cf0, 0x8cf3, 0x8d6c, + 0x8d6e, 0x8da5, 0x8da7, 0x8e33, 0x8e3e, 0x8e38, 0x8e40, 0x8e45, + 0x8e36, 0x8e3c, 0x8e3d, 0x8e41, 0x8e30, 0x8e3f, 0x8ebd, 0x8f36, + 0x8f2e, 0x8f35, 0x8f32, 0x8f39, 0x8f37, 0x8f34, 0x9076, 0x9079, + 0x907b, 0x9086, 0x90fa, 0x9133, 0x9135, 0x9136, 0x9193, 0x9190, + 0x9191, 0x918d, 0x918f, 0x9327, 0x931e, 0x9308, 0x931f, 0x9306, + 0x930f, 0x937a, 0x9338, 0x933c, 0x931b, 0x9323, 0x9312, 0x9301, + 0x9346, 0x932d, 0x930e, 0x930d, 0x92cb, 0x931d, 0x92fa, 0x9325, + 0x9313, 0x92f9, 0x92f7, 0x9334, 0x9302, 0x9324, 0x92ff, 0x9329, + 0x9339, 0x9335, 0x932a, 0x9314, 0x930c, + /* 0xec */ + 0x930b, 0x92fe, 0x9309, 0x9300, 0x92fb, 0x9316, 0x95bc, 0x95cd, + 0x95be, 0x95b9, 0x95ba, 0x95b6, 0x95bf, 0x95b5, 0x95bd, 0x96a9, + 0x96d4, 0x970b, 0x9712, 0x9710, 0x9799, 0x9797, 0x9794, 0x97f0, + 0x97f8, 0x9835, 0x982f, 0x9832, 0x9924, 0x991f, 0x9927, 0x9929, + 0x999e, 0x99ee, 0x99ec, 0x99e5, 0x99e4, 0x99f0, 0x99e3, 0x99ea, + 0x99e9, 0x99e7, 0x9ab9, 0x9abf, 0x9ab4, 0x9abb, 0x9af6, 0x9afa, + 0x9af9, 0x9af7, 0x9b33, 0x9b80, 0x9b85, 0x9b87, 0x9b7c, 0x9b7e, + 0x9b7b, 0x9b82, 0x9b93, 0x9b92, 0x9b90, 0x9b7a, 0x9b95, 0x9b7d, + 0x9b88, 0x9d25, 0x9d17, 0x9d20, 0x9d1e, 0x9d14, 0x9d29, 0x9d1d, + 0x9d18, 0x9d22, 0x9d10, 0x9d19, 0x9d1f, 0x9e88, 0x9e86, 0x9e87, + 0x9eae, 0x9ead, 0x9ed5, 0x9ed6, 0x9efa, 0x9f12, 0x9f3d, 0x5126, + 0x5125, 0x5122, 0x5124, 0x5120, 0x5129, 0x52f4, 0x5693, 0x568c, + 0x568d, 0x5686, 0x5684, 0x5683, 0x567e, 0x5682, 0x567f, 0x5681, + 0x58d6, 0x58d4, 0x58cf, 0x58d2, 0x5b2d, 0x5b25, 0x5b32, 0x5b23, + 0x5b2c, 0x5b27, 0x5b26, 0x5b2f, 0x5b2e, 0x5b7b, 0x5bf1, 0x5bf2, + 0x5db7, 0x5e6c, 0x5e6a, 0x5fbe, 0x5fbb, 0x61c3, 0x61b5, 0x61bc, + 0x61e7, 0x61e0, 0x61e5, 0x61e4, 0x61e8, 0x61de, 0x64ef, 0x64e9, + 0x64e3, 0x64eb, 0x64e4, 0x64e8, 0x6581, 0x6580, 0x65b6, 0x65da, + 0x66d2, 0x6a8d, 0x6a96, 0x6a81, 0x6aa5, 0x6a89, 0x6a9f, 0x6a9b, + 0x6aa1, 0x6a9e, 0x6a87, 0x6a93, 0x6a8e, + /* 0xed */ + 0x6a95, 0x6a83, 0x6aa8, 0x6aa4, 0x6a91, 0x6a7f, 0x6aa6, 0x6a9a, + 0x6a85, 0x6a8c, 0x6a92, 0x6b5b, 0x6bad, 0x6c09, 0x6fcc, 0x6fa9, + 0x6ff4, 0x6fd4, 0x6fe3, 0x6fdc, 0x6fed, 0x6fe7, 0x6fe6, 0x6fde, + 0x6ff2, 0x6fdd, 0x6fe2, 0x6fe8, 0x71e1, 0x71f1, 0x71e8, 0x71f2, + 0x71e4, 0x71f0, 0x71e2, 0x7373, 0x736e, 0x736f, 0x7497, 0x74b2, + 0x74ab, 0x7490, 0x74aa, 0x74ad, 0x74b1, 0x74a5, 0x74af, 0x7510, + 0x7511, 0x7512, 0x750f, 0x7584, 0x7643, 0x7648, 0x7649, 0x7647, + 0x76a4, 0x76e9, 0x77b5, 0x77ab, 0x77b2, 0x77b7, 0x77b6, 0x77b4, + 0x77b1, 0x77a8, 0x77f0, 0x78f3, 0x78fd, 0x7902, 0x78fb, 0x78fc, + 0x78f2, 0x7905, 0x78f9, 0x78fe, 0x7904, 0x79ab, 0x79a8, 0x7a5c, + 0x7a5b, 0x7a56, 0x7a58, 0x7a54, 0x7a5a, 0x7abe, 0x7ac0, 0x7ac1, + 0x7c05, 0x7c0f, 0x7bf2, 0x7c00, 0x7bff, 0x7bfb, 0x7c0e, 0x7bf4, + 0x7c0b, 0x7bf3, 0x7c02, 0x7c09, 0x7c03, 0x7c01, 0x7bf8, 0x7bfd, + 0x7c06, 0x7bf0, 0x7bf1, 0x7c10, 0x7c0a, 0x7ce8, 0x7e2d, 0x7e3c, + 0x7e42, 0x7e33, 0x9848, 0x7e38, 0x7e2a, 0x7e49, 0x7e40, 0x7e47, + 0x7e29, 0x7e4c, 0x7e30, 0x7e3b, 0x7e36, 0x7e44, 0x7e3a, 0x7f45, + 0x7f7f, 0x7f7e, 0x7f7d, 0x7ff4, 0x7ff2, 0x802c, 0x81bb, 0x81c4, + 0x81cc, 0x81ca, 0x81c5, 0x81c7, 0x81bc, 0x81e9, 0x825b, 0x825a, + 0x825c, 0x8583, 0x8580, 0x858f, 0x85a7, 0x8595, 0x85a0, 0x858b, + 0x85a3, 0x857b, 0x85a4, 0x859a, 0x859e, + /* 0xee */ + 0x8577, 0x857c, 0x8589, 0x85a1, 0x857a, 0x8578, 0x8557, 0x858e, + 0x8596, 0x8586, 0x858d, 0x8599, 0x859d, 0x8581, 0x85a2, 0x8582, + 0x8588, 0x8585, 0x8579, 0x8576, 0x8598, 0x8590, 0x859f, 0x8668, + 0x87be, 0x87aa, 0x87ad, 0x87c5, 0x87b0, 0x87ac, 0x87b9, 0x87b5, + 0x87bc, 0x87ae, 0x87c9, 0x87c3, 0x87c2, 0x87cc, 0x87b7, 0x87af, + 0x87c4, 0x87ca, 0x87b4, 0x87b6, 0x87bf, 0x87b8, 0x87bd, 0x87de, + 0x87b2, 0x8935, 0x8933, 0x893c, 0x893e, 0x8941, 0x8952, 0x8937, + 0x8942, 0x89ad, 0x89af, 0x89ae, 0x89f2, 0x89f3, 0x8b1e, 0x8b18, + 0x8b16, 0x8b11, 0x8b05, 0x8b0b, 0x8b22, 0x8b0f, 0x8b12, 0x8b15, + 0x8b07, 0x8b0d, 0x8b08, 0x8b06, 0x8b1c, 0x8b13, 0x8b1a, 0x8c4f, + 0x8c70, 0x8c72, 0x8c71, 0x8c6f, 0x8c95, 0x8c94, 0x8cf9, 0x8d6f, + 0x8e4e, 0x8e4d, 0x8e53, 0x8e50, 0x8e4c, 0x8e47, 0x8f43, 0x8f40, + 0x9085, 0x907e, 0x9138, 0x919a, 0x91a2, 0x919b, 0x9199, 0x919f, + 0x91a1, 0x919d, 0x91a0, 0x93a1, 0x9383, 0x93af, 0x9364, 0x9356, + 0x9347, 0x937c, 0x9358, 0x935c, 0x9376, 0x9349, 0x9350, 0x9351, + 0x9360, 0x936d, 0x938f, 0x934c, 0x936a, 0x9379, 0x9357, 0x9355, + 0x9352, 0x934f, 0x9371, 0x9377, 0x937b, 0x9361, 0x935e, 0x9363, + 0x9367, 0x9380, 0x934e, 0x9359, 0x95c7, 0x95c0, 0x95c9, 0x95c3, + 0x95c5, 0x95b7, 0x96ae, 0x96b0, 0x96ac, 0x9720, 0x971f, 0x9718, + 0x971d, 0x9719, 0x979a, 0x97a1, 0x979c, + /* 0xef */ + 0x979e, 0x979d, 0x97d5, 0x97d4, 0x97f1, 0x9841, 0x9844, 0x984a, + 0x9849, 0x9845, 0x9843, 0x9925, 0x992b, 0x992c, 0x992a, 0x9933, + 0x9932, 0x992f, 0x992d, 0x9931, 0x9930, 0x9998, 0x99a3, 0x99a1, + 0x9a02, 0x99fa, 0x99f4, 0x99f7, 0x99f9, 0x99f8, 0x99f6, 0x99fb, + 0x99fd, 0x99fe, 0x99fc, 0x9a03, 0x9abe, 0x9afe, 0x9afd, 0x9b01, + 0x9afc, 0x9b48, 0x9b9a, 0x9ba8, 0x9b9e, 0x9b9b, 0x9ba6, 0x9ba1, + 0x9ba5, 0x9ba4, 0x9b86, 0x9ba2, 0x9ba0, 0x9baf, 0x9d33, 0x9d41, + 0x9d67, 0x9d36, 0x9d2e, 0x9d2f, 0x9d31, 0x9d38, 0x9d30, 0x9d45, + 0x9d42, 0x9d43, 0x9d3e, 0x9d37, 0x9d40, 0x9d3d, 0x7ff5, 0x9d2d, + 0x9e8a, 0x9e89, 0x9e8d, 0x9eb0, 0x9ec8, 0x9eda, 0x9efb, 0x9eff, + 0x9f24, 0x9f23, 0x9f22, 0x9f54, 0x9fa0, 0x5131, 0x512d, 0x512e, + 0x5698, 0x569c, 0x5697, 0x569a, 0x569d, 0x5699, 0x5970, 0x5b3c, + 0x5c69, 0x5c6a, 0x5dc0, 0x5e6d, 0x5e6e, 0x61d8, 0x61df, 0x61ed, + 0x61ee, 0x61f1, 0x61ea, 0x61f0, 0x61eb, 0x61d6, 0x61e9, 0x64ff, + 0x6504, 0x64fd, 0x64f8, 0x6501, 0x6503, 0x64fc, 0x6594, 0x65db, + 0x66da, 0x66db, 0x66d8, 0x6ac5, 0x6ab9, 0x6abd, 0x6ae1, 0x6ac6, + 0x6aba, 0x6ab6, 0x6ab7, 0x6ac7, 0x6ab4, 0x6aad, 0x6b5e, 0x6bc9, + 0x6c0b, 0x7007, 0x700c, 0x700d, 0x7001, 0x7005, 0x7014, 0x700e, + 0x6fff, 0x7000, 0x6ffb, 0x7026, 0x6ffc, 0x6ff7, 0x700a, 0x7201, + 0x71ff, 0x71f9, 0x7203, 0x71fd, 0x7376, + /* 0xf0 */ + 0x74b8, 0x74c0, 0x74b5, 0x74c1, 0x74be, 0x74b6, 0x74bb, 0x74c2, + 0x7514, 0x7513, 0x765c, 0x7664, 0x7659, 0x7650, 0x7653, 0x7657, + 0x765a, 0x76a6, 0x76bd, 0x76ec, 0x77c2, 0x77ba, 0x78ff, 0x790c, + 0x7913, 0x7914, 0x7909, 0x7910, 0x7912, 0x7911, 0x79ad, 0x79ac, + 0x7a5f, 0x7c1c, 0x7c29, 0x7c19, 0x7c20, 0x7c1f, 0x7c2d, 0x7c1d, + 0x7c26, 0x7c28, 0x7c22, 0x7c25, 0x7c30, 0x7e5c, 0x7e50, 0x7e56, + 0x7e63, 0x7e58, 0x7e62, 0x7e5f, 0x7e51, 0x7e60, 0x7e57, 0x7e53, + 0x7fb5, 0x7fb3, 0x7ff7, 0x7ff8, 0x8075, 0x81d1, 0x81d2, 0x81d0, + 0x825f, 0x825e, 0x85b4, 0x85c6, 0x85c0, 0x85c3, 0x85c2, 0x85b3, + 0x85b5, 0x85bd, 0x85c7, 0x85c4, 0x85bf, 0x85cb, 0x85ce, 0x85c8, + 0x85c5, 0x85b1, 0x85b6, 0x85d2, 0x8624, 0x85b8, 0x85b7, 0x85be, + 0x8669, 0x87e7, 0x87e6, 0x87e2, 0x87db, 0x87eb, 0x87ea, 0x87e5, + 0x87df, 0x87f3, 0x87e4, 0x87d4, 0x87dc, 0x87d3, 0x87ed, 0x87d8, + 0x87e3, 0x87a4, 0x87d7, 0x87d9, 0x8801, 0x87f4, 0x87e8, 0x87dd, + 0x8953, 0x894b, 0x894f, 0x894c, 0x8946, 0x8950, 0x8951, 0x8949, + 0x8b2a, 0x8b27, 0x8b23, 0x8b33, 0x8b30, 0x8b35, 0x8b47, 0x8b2f, + 0x8b3c, 0x8b3e, 0x8b31, 0x8b25, 0x8b37, 0x8b26, 0x8b36, 0x8b2e, + 0x8b24, 0x8b3b, 0x8b3d, 0x8b3a, 0x8c42, 0x8c75, 0x8c99, 0x8c98, + 0x8c97, 0x8cfe, 0x8d04, 0x8d02, 0x8d00, 0x8e5c, 0x8e62, 0x8e60, + 0x8e57, 0x8e56, 0x8e5e, 0x8e65, 0x8e67, + /* 0xf1 */ + 0x8e5b, 0x8e5a, 0x8e61, 0x8e5d, 0x8e69, 0x8e54, 0x8f46, 0x8f47, + 0x8f48, 0x8f4b, 0x9128, 0x913a, 0x913b, 0x913e, 0x91a8, 0x91a5, + 0x91a7, 0x91af, 0x91aa, 0x93b5, 0x938c, 0x9392, 0x93b7, 0x939b, + 0x939d, 0x9389, 0x93a7, 0x938e, 0x93aa, 0x939e, 0x93a6, 0x9395, + 0x9388, 0x9399, 0x939f, 0x938d, 0x93b1, 0x9391, 0x93b2, 0x93a4, + 0x93a8, 0x93b4, 0x93a3, 0x93a5, 0x95d2, 0x95d3, 0x95d1, 0x96b3, + 0x96d7, 0x96da, 0x5dc2, 0x96df, 0x96d8, 0x96dd, 0x9723, 0x9722, + 0x9725, 0x97ac, 0x97ae, 0x97a8, 0x97ab, 0x97a4, 0x97aa, 0x97a2, + 0x97a5, 0x97d7, 0x97d9, 0x97d6, 0x97d8, 0x97fa, 0x9850, 0x9851, + 0x9852, 0x98b8, 0x9941, 0x993c, 0x993a, 0x9a0f, 0x9a0b, 0x9a09, + 0x9a0d, 0x9a04, 0x9a11, 0x9a0a, 0x9a05, 0x9a07, 0x9a06, 0x9ac0, + 0x9adc, 0x9b08, 0x9b04, 0x9b05, 0x9b29, 0x9b35, 0x9b4a, 0x9b4c, + 0x9b4b, 0x9bc7, 0x9bc6, 0x9bc3, 0x9bbf, 0x9bc1, 0x9bb5, 0x9bb8, + 0x9bd3, 0x9bb6, 0x9bc4, 0x9bb9, 0x9bbd, 0x9d5c, 0x9d53, 0x9d4f, + 0x9d4a, 0x9d5b, 0x9d4b, 0x9d59, 0x9d56, 0x9d4c, 0x9d57, 0x9d52, + 0x9d54, 0x9d5f, 0x9d58, 0x9d5a, 0x9e8e, 0x9e8c, 0x9edf, 0x9f01, + 0x9f00, 0x9f16, 0x9f25, 0x9f2b, 0x9f2a, 0x9f29, 0x9f28, 0x9f4c, + 0x9f55, 0x5134, 0x5135, 0x5296, 0x52f7, 0x53b4, 0x56ab, 0x56ad, + 0x56a6, 0x56a7, 0x56aa, 0x56ac, 0x58da, 0x58dd, 0x58db, 0x5912, + 0x5b3d, 0x5b3e, 0x5b3f, 0x5dc3, 0x5e70, + /* 0xf2 */ + 0x5fbf, 0x61fb, 0x6507, 0x6510, 0x650d, 0x6509, 0x650c, 0x650e, + 0x6584, 0x65de, 0x65dd, 0x66de, 0x6ae7, 0x6ae0, 0x6acc, 0x6ad1, + 0x6ad9, 0x6acb, 0x6adf, 0x6adc, 0x6ad0, 0x6aeb, 0x6acf, 0x6acd, + 0x6ade, 0x6b60, 0x6bb0, 0x6c0c, 0x7019, 0x7027, 0x7020, 0x7016, + 0x702b, 0x7021, 0x7022, 0x7023, 0x7029, 0x7017, 0x7024, 0x701c, + 0x702a, 0x720c, 0x720a, 0x7207, 0x7202, 0x7205, 0x72a5, 0x72a6, + 0x72a4, 0x72a3, 0x72a1, 0x74cb, 0x74c5, 0x74b7, 0x74c3, 0x7516, + 0x7660, 0x77c9, 0x77ca, 0x77c4, 0x77f1, 0x791d, 0x791b, 0x7921, + 0x791c, 0x7917, 0x791e, 0x79b0, 0x7a67, 0x7a68, 0x7c33, 0x7c3c, + 0x7c39, 0x7c2c, 0x7c3b, 0x7cec, 0x7cea, 0x7e76, 0x7e75, 0x7e78, + 0x7e70, 0x7e77, 0x7e6f, 0x7e7a, 0x7e72, 0x7e74, 0x7e68, 0x7f4b, + 0x7f4a, 0x7f83, 0x7f86, 0x7fb7, 0x7ffd, 0x7ffe, 0x8078, 0x81d7, + 0x81d5, 0x8264, 0x8261, 0x8263, 0x85eb, 0x85f1, 0x85ed, 0x85d9, + 0x85e1, 0x85e8, 0x85da, 0x85d7, 0x85ec, 0x85f2, 0x85f8, 0x85d8, + 0x85df, 0x85e3, 0x85dc, 0x85d1, 0x85f0, 0x85e6, 0x85ef, 0x85de, + 0x85e2, 0x8800, 0x87fa, 0x8803, 0x87f6, 0x87f7, 0x8809, 0x880c, + 0x880b, 0x8806, 0x87fc, 0x8808, 0x87ff, 0x880a, 0x8802, 0x8962, + 0x895a, 0x895b, 0x8957, 0x8961, 0x895c, 0x8958, 0x895d, 0x8959, + 0x8988, 0x89b7, 0x89b6, 0x89f6, 0x8b50, 0x8b48, 0x8b4a, 0x8b40, + 0x8b53, 0x8b56, 0x8b54, 0x8b4b, 0x8b55, + /* 0xf3 */ + 0x8b51, 0x8b42, 0x8b52, 0x8b57, 0x8c43, 0x8c77, 0x8c76, 0x8c9a, + 0x8d06, 0x8d07, 0x8d09, 0x8dac, 0x8daa, 0x8dad, 0x8dab, 0x8e6d, + 0x8e78, 0x8e73, 0x8e6a, 0x8e6f, 0x8e7b, 0x8ec2, 0x8f52, 0x8f51, + 0x8f4f, 0x8f50, 0x8f53, 0x8fb4, 0x9140, 0x913f, 0x91b0, 0x91ad, + 0x93de, 0x93c7, 0x93cf, 0x93c2, 0x93da, 0x93d0, 0x93f9, 0x93ec, + 0x93cc, 0x93d9, 0x93a9, 0x93e6, 0x93ca, 0x93d4, 0x93ee, 0x93e3, + 0x93d5, 0x93c4, 0x93ce, 0x93c0, 0x93d2, 0x93e7, 0x957d, 0x95da, + 0x95db, 0x96e1, 0x9729, 0x972b, 0x972c, 0x9728, 0x9726, 0x97b3, + 0x97b7, 0x97b6, 0x97dd, 0x97de, 0x97df, 0x985c, 0x9859, 0x985d, + 0x9857, 0x98bf, 0x98bd, 0x98bb, 0x98be, 0x9948, 0x9947, 0x9943, + 0x99a6, 0x99a7, 0x9a1a, 0x9a15, 0x9a25, 0x9a1d, 0x9a24, 0x9a1b, + 0x9a22, 0x9a20, 0x9a27, 0x9a23, 0x9a1e, 0x9a1c, 0x9a14, 0x9ac2, + 0x9b0b, 0x9b0a, 0x9b0e, 0x9b0c, 0x9b37, 0x9bea, 0x9beb, 0x9be0, + 0x9bde, 0x9be4, 0x9be6, 0x9be2, 0x9bf0, 0x9bd4, 0x9bd7, 0x9bec, + 0x9bdc, 0x9bd9, 0x9be5, 0x9bd5, 0x9be1, 0x9bda, 0x9d77, 0x9d81, + 0x9d8a, 0x9d84, 0x9d88, 0x9d71, 0x9d80, 0x9d78, 0x9d86, 0x9d8b, + 0x9d8c, 0x9d7d, 0x9d6b, 0x9d74, 0x9d75, 0x9d70, 0x9d69, 0x9d85, + 0x9d73, 0x9d7b, 0x9d82, 0x9d6f, 0x9d79, 0x9d7f, 0x9d87, 0x9d68, + 0x9e94, 0x9e91, 0x9ec0, 0x9efc, 0x9f2d, 0x9f40, 0x9f41, 0x9f4d, + 0x9f56, 0x9f57, 0x9f58, 0x5337, 0x56b2, + /* 0xf4 */ + 0x56b5, 0x56b3, 0x58e3, 0x5b45, 0x5dc6, 0x5dc7, 0x5eee, 0x5eef, + 0x5fc0, 0x5fc1, 0x61f9, 0x6517, 0x6516, 0x6515, 0x6513, 0x65df, + 0x66e8, 0x66e3, 0x66e4, 0x6af3, 0x6af0, 0x6aea, 0x6ae8, 0x6af9, + 0x6af1, 0x6aee, 0x6aef, 0x703c, 0x7035, 0x702f, 0x7037, 0x7034, + 0x7031, 0x7042, 0x7038, 0x703f, 0x703a, 0x7039, 0x7040, 0x703b, + 0x7033, 0x7041, 0x7213, 0x7214, 0x72a8, 0x737d, 0x737c, 0x74ba, + 0x76ab, 0x76aa, 0x76be, 0x76ed, 0x77cc, 0x77ce, 0x77cf, 0x77cd, + 0x77f2, 0x7925, 0x7923, 0x7927, 0x7928, 0x7924, 0x7929, 0x79b2, + 0x7a6e, 0x7a6c, 0x7a6d, 0x7af7, 0x7c49, 0x7c48, 0x7c4a, 0x7c47, + 0x7c45, 0x7cee, 0x7e7b, 0x7e7e, 0x7e81, 0x7e80, 0x7fba, 0x7fff, + 0x8079, 0x81db, 0x81d9, 0x820b, 0x8268, 0x8269, 0x8622, 0x85ff, + 0x8601, 0x85fe, 0x861b, 0x8600, 0x85f6, 0x8604, 0x8609, 0x8605, + 0x860c, 0x85fd, 0x8819, 0x8810, 0x8811, 0x8817, 0x8813, 0x8816, + 0x8963, 0x8966, 0x89b9, 0x89f7, 0x8b60, 0x8b6a, 0x8b5d, 0x8b68, + 0x8b63, 0x8b65, 0x8b67, 0x8b6d, 0x8dae, 0x8e86, 0x8e88, 0x8e84, + 0x8f59, 0x8f56, 0x8f57, 0x8f55, 0x8f58, 0x8f5a, 0x908d, 0x9143, + 0x9141, 0x91b7, 0x91b5, 0x91b2, 0x91b3, 0x940b, 0x9413, 0x93fb, + 0x9420, 0x940f, 0x9414, 0x93fe, 0x9415, 0x9410, 0x9428, 0x9419, + 0x940d, 0x93f5, 0x9400, 0x93f7, 0x9407, 0x940e, 0x9416, 0x9412, + 0x93fa, 0x9409, 0x93f8, 0x940a, 0x93ff, + /* 0xf5 */ + 0x93fc, 0x940c, 0x93f6, 0x9411, 0x9406, 0x95de, 0x95e0, 0x95df, + 0x972e, 0x972f, 0x97b9, 0x97bb, 0x97fd, 0x97fe, 0x9860, 0x9862, + 0x9863, 0x985f, 0x98c1, 0x98c2, 0x9950, 0x994e, 0x9959, 0x994c, + 0x994b, 0x9953, 0x9a32, 0x9a34, 0x9a31, 0x9a2c, 0x9a2a, 0x9a36, + 0x9a29, 0x9a2e, 0x9a38, 0x9a2d, 0x9ac7, 0x9aca, 0x9ac6, 0x9b10, + 0x9b12, 0x9b11, 0x9c0b, 0x9c08, 0x9bf7, 0x9c05, 0x9c12, 0x9bf8, + 0x9c40, 0x9c07, 0x9c0e, 0x9c06, 0x9c17, 0x9c14, 0x9c09, 0x9d9f, + 0x9d99, 0x9da4, 0x9d9d, 0x9d92, 0x9d98, 0x9d90, 0x9d9b, 0x9da0, + 0x9d94, 0x9d9c, 0x9daa, 0x9d97, 0x9da1, 0x9d9a, 0x9da2, 0x9da8, + 0x9d9e, 0x9da3, 0x9dbf, 0x9da9, 0x9d96, 0x9da6, 0x9da7, 0x9e99, + 0x9e9b, 0x9e9a, 0x9ee5, 0x9ee4, 0x9ee7, 0x9ee6, 0x9f30, 0x9f2e, + 0x9f5b, 0x9f60, 0x9f5e, 0x9f5d, 0x9f59, 0x9f91, 0x513a, 0x5139, + 0x5298, 0x5297, 0x56c3, 0x56bd, 0x56be, 0x5b48, 0x5b47, 0x5dcb, + 0x5dcf, 0x5ef1, 0x61fd, 0x651b, 0x6b02, 0x6afc, 0x6b03, 0x6af8, + 0x6b00, 0x7043, 0x7044, 0x704a, 0x7048, 0x7049, 0x7045, 0x7046, + 0x721d, 0x721a, 0x7219, 0x737e, 0x7517, 0x766a, 0x77d0, 0x792d, + 0x7931, 0x792f, 0x7c54, 0x7c53, 0x7cf2, 0x7e8a, 0x7e87, 0x7e88, + 0x7e8b, 0x7e86, 0x7e8d, 0x7f4d, 0x7fbb, 0x8030, 0x81dd, 0x8618, + 0x862a, 0x8626, 0x861f, 0x8623, 0x861c, 0x8619, 0x8627, 0x862e, + 0x8621, 0x8620, 0x8629, 0x861e, 0x8625, + /* 0xf6 */ + 0x8829, 0x881d, 0x881b, 0x8820, 0x8824, 0x881c, 0x882b, 0x884a, + 0x896d, 0x8969, 0x896e, 0x896b, 0x89fa, 0x8b79, 0x8b78, 0x8b45, + 0x8b7a, 0x8b7b, 0x8d10, 0x8d14, 0x8daf, 0x8e8e, 0x8e8c, 0x8f5e, + 0x8f5b, 0x8f5d, 0x9146, 0x9144, 0x9145, 0x91b9, 0x943f, 0x943b, + 0x9436, 0x9429, 0x943d, 0x943c, 0x9430, 0x9439, 0x942a, 0x9437, + 0x942c, 0x9440, 0x9431, 0x95e5, 0x95e4, 0x95e3, 0x9735, 0x973a, + 0x97bf, 0x97e1, 0x9864, 0x98c9, 0x98c6, 0x98c0, 0x9958, 0x9956, + 0x9a39, 0x9a3d, 0x9a46, 0x9a44, 0x9a42, 0x9a41, 0x9a3a, 0x9a3f, + 0x9acd, 0x9b15, 0x9b17, 0x9b18, 0x9b16, 0x9b3a, 0x9b52, 0x9c2b, + 0x9c1d, 0x9c1c, 0x9c2c, 0x9c23, 0x9c28, 0x9c29, 0x9c24, 0x9c21, + 0x9db7, 0x9db6, 0x9dbc, 0x9dc1, 0x9dc7, 0x9dca, 0x9dcf, 0x9dbe, + 0x9dc5, 0x9dc3, 0x9dbb, 0x9db5, 0x9dce, 0x9db9, 0x9dba, 0x9dac, + 0x9dc8, 0x9db1, 0x9dad, 0x9dcc, 0x9db3, 0x9dcd, 0x9db2, 0x9e7a, + 0x9e9c, 0x9eeb, 0x9eee, 0x9eed, 0x9f1b, 0x9f18, 0x9f1a, 0x9f31, + 0x9f4e, 0x9f65, 0x9f64, 0x9f92, 0x4eb9, 0x56c6, 0x56c5, 0x56cb, + 0x5971, 0x5b4b, 0x5b4c, 0x5dd5, 0x5dd1, 0x5ef2, 0x6521, 0x6520, + 0x6526, 0x6522, 0x6b0b, 0x6b08, 0x6b09, 0x6c0d, 0x7055, 0x7056, + 0x7057, 0x7052, 0x721e, 0x721f, 0x72a9, 0x737f, 0x74d8, 0x74d5, + 0x74d9, 0x74d7, 0x766d, 0x76ad, 0x7935, 0x79b4, 0x7a70, 0x7a71, + 0x7c57, 0x7c5c, 0x7c59, 0x7c5b, 0x7c5a, + /* 0xf7 */ + 0x7cf4, 0x7cf1, 0x7e91, 0x7f4f, 0x7f87, 0x81de, 0x826b, 0x8634, + 0x8635, 0x8633, 0x862c, 0x8632, 0x8636, 0x882c, 0x8828, 0x8826, + 0x882a, 0x8825, 0x8971, 0x89bf, 0x89be, 0x89fb, 0x8b7e, 0x8b84, + 0x8b82, 0x8b86, 0x8b85, 0x8b7f, 0x8d15, 0x8e95, 0x8e94, 0x8e9a, + 0x8e92, 0x8e90, 0x8e96, 0x8e97, 0x8f60, 0x8f62, 0x9147, 0x944c, + 0x9450, 0x944a, 0x944b, 0x944f, 0x9447, 0x9445, 0x9448, 0x9449, + 0x9446, 0x973f, 0x97e3, 0x986a, 0x9869, 0x98cb, 0x9954, 0x995b, + 0x9a4e, 0x9a53, 0x9a54, 0x9a4c, 0x9a4f, 0x9a48, 0x9a4a, 0x9a49, + 0x9a52, 0x9a50, 0x9ad0, 0x9b19, 0x9b2b, 0x9b3b, 0x9b56, 0x9b55, + 0x9c46, 0x9c48, 0x9c3f, 0x9c44, 0x9c39, 0x9c33, 0x9c41, 0x9c3c, + 0x9c37, 0x9c34, 0x9c32, 0x9c3d, 0x9c36, 0x9ddb, 0x9dd2, 0x9dde, + 0x9dda, 0x9dcb, 0x9dd0, 0x9ddc, 0x9dd1, 0x9ddf, 0x9de9, 0x9dd9, + 0x9dd8, 0x9dd6, 0x9df5, 0x9dd5, 0x9ddd, 0x9eb6, 0x9ef0, 0x9f35, + 0x9f33, 0x9f32, 0x9f42, 0x9f6b, 0x9f95, 0x9fa2, 0x513d, 0x5299, + 0x58e8, 0x58e7, 0x5972, 0x5b4d, 0x5dd8, 0x882f, 0x5f4f, 0x6201, + 0x6203, 0x6204, 0x6529, 0x6525, 0x6596, 0x66eb, 0x6b11, 0x6b12, + 0x6b0f, 0x6bca, 0x705b, 0x705a, 0x7222, 0x7382, 0x7381, 0x7383, + 0x7670, 0x77d4, 0x7c67, 0x7c66, 0x7e95, 0x826c, 0x863a, 0x8640, + 0x8639, 0x863c, 0x8631, 0x863b, 0x863e, 0x8830, 0x8832, 0x882e, + 0x8833, 0x8976, 0x8974, 0x8973, 0x89fe, + /* 0xf8 */ + 0x8b8c, 0x8b8e, 0x8b8b, 0x8b88, 0x8c45, 0x8d19, 0x8e98, 0x8f64, + 0x8f63, 0x91bc, 0x9462, 0x9455, 0x945d, 0x9457, 0x945e, 0x97c4, + 0x97c5, 0x9800, 0x9a56, 0x9a59, 0x9b1e, 0x9b1f, 0x9b20, 0x9c52, + 0x9c58, 0x9c50, 0x9c4a, 0x9c4d, 0x9c4b, 0x9c55, 0x9c59, 0x9c4c, + 0x9c4e, 0x9dfb, 0x9df7, 0x9def, 0x9de3, 0x9deb, 0x9df8, 0x9de4, + 0x9df6, 0x9de1, 0x9dee, 0x9de6, 0x9df2, 0x9df0, 0x9de2, 0x9dec, + 0x9df4, 0x9df3, 0x9de8, 0x9ded, 0x9ec2, 0x9ed0, 0x9ef2, 0x9ef3, + 0x9f06, 0x9f1c, 0x9f38, 0x9f37, 0x9f36, 0x9f43, 0x9f4f, 0x9f71, + 0x9f70, 0x9f6e, 0x9f6f, 0x56d3, 0x56cd, 0x5b4e, 0x5c6d, 0x652d, + 0x66ed, 0x66ee, 0x6b13, 0x705f, 0x7061, 0x705d, 0x7060, 0x7223, + 0x74db, 0x74e5, 0x77d5, 0x7938, 0x79b7, 0x79b6, 0x7c6a, 0x7e97, + 0x7f89, 0x826d, 0x8643, 0x8838, 0x8837, 0x8835, 0x884b, 0x8b94, + 0x8b95, 0x8e9e, 0x8e9f, 0x8ea0, 0x8e9d, 0x91be, 0x91bd, 0x91c2, + 0x946b, 0x9468, 0x9469, 0x96e5, 0x9746, 0x9743, 0x9747, 0x97c7, + 0x97e5, 0x9a5e, 0x9ad5, 0x9b59, 0x9c63, 0x9c67, 0x9c66, 0x9c62, + 0x9c5e, 0x9c60, 0x9e02, 0x9dfe, 0x9e07, 0x9e03, 0x9e06, 0x9e05, + 0x9e00, 0x9e01, 0x9e09, 0x9dff, 0x9dfd, 0x9e04, 0x9ea0, 0x9f1e, + 0x9f46, 0x9f74, 0x9f75, 0x9f76, 0x56d4, 0x652e, 0x65b8, 0x6b18, + 0x6b19, 0x6b17, 0x6b1a, 0x7062, 0x7226, 0x72aa, 0x77d8, 0x77d9, + 0x7939, 0x7c69, 0x7c6b, 0x7cf6, 0x7e9a, + /* 0xf9 */ + 0x7e98, 0x7e9b, 0x7e99, 0x81e0, 0x81e1, 0x8646, 0x8647, 0x8648, + 0x8979, 0x897a, 0x897c, 0x897b, 0x89ff, 0x8b98, 0x8b99, 0x8ea5, + 0x8ea4, 0x8ea3, 0x946e, 0x946d, 0x946f, 0x9471, 0x9473, 0x9749, + 0x9872, 0x995f, 0x9c68, 0x9c6e, 0x9c6d, 0x9e0b, 0x9e0d, 0x9e10, + 0x9e0f, 0x9e12, 0x9e11, 0x9ea1, 0x9ef5, 0x9f09, 0x9f47, 0x9f78, + 0x9f7b, 0x9f7a, 0x9f79, 0x571e, 0x7066, 0x7c6f, 0x883c, 0x8db2, + 0x8ea6, 0x91c3, 0x9474, 0x9478, 0x9476, 0x9475, 0x9a60, 0x9c74, + 0x9c73, 0x9c71, 0x9c75, 0x9e14, 0x9e13, 0x9ef6, 0x9f0a, 0x9fa4, + 0x7068, 0x7065, 0x7cf7, 0x866a, 0x883e, 0x883d, 0x883f, 0x8b9e, + 0x8c9c, 0x8ea9, 0x8ec9, 0x974b, 0x9873, 0x9874, 0x98cc, 0x9961, + 0x99ab, 0x9a64, 0x9a66, 0x9a67, 0x9b24, 0x9e15, 0x9e17, 0x9f48, + 0x6207, 0x6b1e, 0x7227, 0x864c, 0x8ea8, 0x9482, 0x9480, 0x9481, + 0x9a69, 0x9a68, 0x9b2e, 0x9e19, 0x7229, 0x864b, 0x8b9f, 0x9483, + 0x9c79, 0x9eb7, 0x7675, 0x9a6b, 0x9c7a, 0x9e1d, 0x7069, 0x706a, + 0x9ea4, 0x9f7e, 0x9f49, 0x9f98, +}; + +static int +big5_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0xa1 && c1 <= 0xc7) || (c1 >= 0xc9 && c1 <= 0xf9)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0xa1 && c2 < 0xff)) { + unsigned int i = 157 * (c1 - 0xa1) + (c2 - (c2 >= 0xa1 ? 0x62 : 0x40)); + unsigned short wc = 0xfffd; + if (i < 6280) { + if (i < 6121) + wc = big5_2uni_pagea1[i]; + } else { + if (i < 13932) + wc = big5_2uni_pagec9[i-6280]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short big5_2charset[13703] = { + 0xa246, 0xa247, 0xa244, 0xa1b1, 0xa258, 0xa1d3, 0xa150, 0xa1d1, + 0xa1d2, 0xa3be, 0xa3bc, 0xa3bd, 0xa3bf, 0xa3bb, 0xa344, 0xa345, + 0xa346, 0xa347, 0xa348, 0xa349, 0xa34a, 0xa34b, 0xa34c, 0xa34d, + 0xa34e, 0xa34f, 0xa350, 0xa351, 0xa352, 0xa353, 0xa354, 0xa355, + 0xa356, 0xa357, 0xa358, 0xa359, 0xa35a, 0xa35b, 0xa35c, 0xa35d, + 0xa35e, 0xa35f, 0xa360, 0xa361, 0xa362, 0xa363, 0xa364, 0xa365, + 0xa366, 0xa367, 0xa368, 0xa369, 0xa36a, 0xa36b, 0xa36c, 0xa36d, + 0xa36e, 0xa36f, 0xa370, 0xa371, 0xa372, 0xa373, 0xc7b3, 0xc7b1, + 0xc7b2, 0xc7b4, 0xc7b5, 0xc7b6, 0xc7b7, 0xc7b8, 0xc7b9, 0xc7ba, + 0xc7bb, 0xc7bc, 0xc7bd, 0xc7be, 0xc7bf, 0xc7c0, 0xc7c1, 0xc7c2, + 0xc7c3, 0xc7c4, 0xc7c5, 0xc7c6, 0xc7c7, 0xc7c8, 0xc7c9, 0xc7ca, + 0xc7cb, 0xc7cc, 0xc7cd, 0xc7cf, 0xc7d0, 0xc7d1, 0xc7d2, 0xc7d3, + 0xc7d4, 0xc7d5, 0xc7d6, 0xc7d7, 0xc7d8, 0xc7d9, 0xc7da, 0xc7db, + 0xc7dc, 0xc7dd, 0xc7de, 0xc7df, 0xc7e0, 0xc7e1, 0xc7e2, 0xc7e3, + 0xc7e4, 0xc7e5, 0xc7e6, 0xc7e7, 0xc7e8, 0xc7ce, 0xa156, 0xa158, + 0xa1a5, 0xa1a6, 0xa1a7, 0xa1a8, 0xa145, 0xa14c, 0xa14b, 0xa1ac, + 0xa1ab, 0xa1b0, 0xa1c2, 0xa24a, 0xa1c1, 0xa24b, 0xa2b9, 0xa2ba, + 0xa2bb, 0xa2bc, 0xa2bd, 0xa2be, 0xa2bf, 0xa2c0, 0xa2c1, 0xa2c2, + 0xa1f6, 0xa1f4, 0xa1f7, 0xa1f5, 0xa1f8, 0xa1f9, 0xa1fb, 0xa1fa, + 0xa1d4, 0xa1db, 0xa1e8, 0xa1e7, 0xa1fd, 0xa1fc, 0xa1e4, 0xa1e5, + 0xa1ec, 0xa1ed, 0xa1ef, 0xa1ee, 0xa1e3, 0xa1dc, 0xa1da, 0xa1dd, + 0xa1d8, 0xa1d9, 0xa1e6, 0xa1e9, 0xc7e9, 0xc7ea, 0xc7eb, 0xc7ec, + 0xc7ed, 0xc7ee, 0xc7ef, 0xc7f0, 0xc7f1, 0xc7f2, 0xc7f3, 0xc7f4, + 0xc7f5, 0xc7f6, 0xc7f7, 0xc7f8, 0xc7f9, 0xc7fa, 0xc7fb, 0xc7fc, + 0xa277, 0xa278, 0xa27a, 0xa27b, 0xa27c, 0xa27d, 0xa275, 0xa274, + 0xa273, 0xa272, 0xa271, 0xa2a4, 0xa2a5, 0xa2a7, 0xa2a6, 0xa27e, + 0xa2a1, 0xa2a3, 0xa2a2, 0xa2ac, 0xa2ad, 0xa2ae, 0xa262, 0xa263, + 0xa264, 0xa265, 0xa266, 0xa267, 0xa268, 0xa269, 0xa270, 0xa26f, + 0xa26e, 0xa26d, 0xa26c, 0xa26b, 0xa26a, 0xa276, 0xa279, 0xa1bd, + 0xa1bc, 0xa1b6, 0xa1b5, 0xa1bf, 0xa1be, 0xa1bb, 0xa1ba, 0xa1b3, + 0xa1b7, 0xa1b4, 0xa2a8, 0xa2a9, 0xa2ab, 0xa2aa, 0xa1b9, 0xa1b8, + 0xa1f3, 0xa1f0, 0xa1f2, 0xa1f1, 0xa140, 0xa142, 0xa143, 0xa1b2, + 0xc6a4, 0xa171, 0xa172, 0xa16d, 0xa16e, 0xa175, 0xa176, 0xa179, + 0xa17a, 0xa169, 0xa16a, 0xa245, 0xa165, 0xa166, 0xa1a9, 0xa1aa, + 0xa2c3, 0xa2c4, 0xa2c5, 0xa2c6, 0xa2c7, 0xa2c8, 0xa2c9, 0xa2ca, + 0xa2cb, 0xc6a5, 0xc6a6, 0xc6a7, 0xc6a8, 0xc6a9, 0xc6aa, 0xc6ab, + 0xc6ac, 0xc6ad, 0xc6ae, 0xc6af, 0xc6b0, 0xc6b1, 0xc6b2, 0xc6b3, + 0xc6b4, 0xc6b5, 0xc6b6, 0xc6b7, 0xc6b8, 0xc6b9, 0xc6ba, 0xc6bb, + 0xc6bc, 0xc6bd, 0xc6be, 0xc6bf, 0xc6c0, 0xc6c1, 0xc6c2, 0xc6c3, + 0xc6c4, 0xc6c5, 0xc6c6, 0xc6c7, 0xc6c8, 0xc6c9, 0xc6ca, 0xc6cb, + 0xc6cc, 0xc6cd, 0xc6ce, 0xc6cf, 0xc6d0, 0xc6d1, 0xc6d2, 0xc6d3, + 0xc6d4, 0xc6d5, 0xc6d6, 0xc6d7, 0xc6d8, 0xc6d9, 0xc6da, 0xc6db, + 0xc6dc, 0xc6dd, 0xc6de, 0xc6df, 0xc6e0, 0xc6e1, 0xc6e2, 0xc6e3, + 0xc6e4, 0xc6e5, 0xc6e6, 0xc6e7, 0xc6e8, 0xc6e9, 0xc6ea, 0xc6eb, + 0xc6ec, 0xc6ed, 0xc6ee, 0xc6ef, 0xc6f0, 0xc6f1, 0xc6f2, 0xc6f3, + 0xc6f4, 0xc6f5, 0xc6f6, 0xc6f7, 0xc6a2, 0xc6a3, 0xc6f8, 0xc6f9, + 0xc6fa, 0xc6fb, 0xc6fc, 0xc6fd, 0xc6fe, 0xc740, 0xc741, 0xc742, + 0xc743, 0xc744, 0xc745, 0xc746, 0xc747, 0xc748, 0xc749, 0xc74a, + 0xc74b, 0xc74c, 0xc74d, 0xc74e, 0xc74f, 0xc750, 0xc751, 0xc752, + 0xc753, 0xc754, 0xc755, 0xc756, 0xc757, 0xc758, 0xc759, 0xc75a, + 0xc75b, 0xc75c, 0xc75d, 0xc75e, 0xc75f, 0xc760, 0xc761, 0xc762, + 0xc763, 0xc764, 0xc765, 0xc766, 0xc767, 0xc768, 0xc769, 0xc76a, + 0xc76b, 0xc76c, 0xc76d, 0xc76e, 0xc76f, 0xc770, 0xc771, 0xc772, + 0xc773, 0xc774, 0xc775, 0xc776, 0xc777, 0xc778, 0xc779, 0xc77a, + 0xc77b, 0xc77c, 0xc77d, 0xc77e, 0xc7a1, 0xc7a2, 0xc7a3, 0xc7a4, + 0xc7a5, 0xc7a6, 0xc7a7, 0xc7a8, 0xc7a9, 0xc7aa, 0xc7ab, 0xc7ac, + 0xc7ad, 0xc7ae, 0xc7af, 0xc7b0, 0xc6a1, 0xa374, 0xa375, 0xa376, + 0xa377, 0xa378, 0xa379, 0xa37a, 0xa37b, 0xa37c, 0xa37d, 0xa37e, + 0xa3a1, 0xa3a2, 0xa3a3, 0xa3a4, 0xa3a5, 0xa3a6, 0xa3a7, 0xa3a8, + 0xa3a9, 0xa3aa, 0xa3ab, 0xa3ac, 0xa3ad, 0xa3ae, 0xa3af, 0xa3b0, + 0xa3b1, 0xa3b2, 0xa3b3, 0xa3b4, 0xa3b5, 0xa3b6, 0xa3b7, 0xa3b8, + 0xa3b9, 0xa3ba, 0xa1c0, 0xa255, 0xa256, 0xa250, 0xa251, 0xa252, + 0xa254, 0xa257, 0xa253, 0xa1eb, 0xa1ea, 0xa24f, 0xa440, 0xa442, + 0xa443, 0xc945, 0xa456, 0xa454, 0xa457, 0xa455, 0xc946, 0xa4a3, + 0xc94f, 0xc94d, 0xa4a2, 0xa4a1, 0xa542, 0xa541, 0xa540, 0xa543, + 0xa4fe, 0xa5e0, 0xa5e1, 0xa8c3, 0xa458, 0xa4a4, 0xc950, 0xa4a5, + 0xc963, 0xa6ea, 0xcbb1, 0xa459, 0xa4a6, 0xa544, 0xc964, 0xc940, + 0xa444, 0xa45b, 0xc947, 0xa45c, 0xa4a7, 0xa545, 0xa547, 0xa546, + 0xa5e2, 0xa5e3, 0xa8c4, 0xadbc, 0xa441, 0xc941, 0xa445, 0xa45e, + 0xa45d, 0xa5e4, 0xa8c5, 0xb0ae, 0xd44b, 0xb6c3, 0xdcb1, 0xdcb2, + 0xa446, 0xa4a9, 0xa8c6, 0xa447, 0xc948, 0xa45f, 0xa4aa, 0xa4ac, + 0xc951, 0xa4ad, 0xa4ab, 0xa5e5, 0xa8c7, 0xa8c8, 0xab45, 0xa460, + 0xa4ae, 0xa5e6, 0xa5e8, 0xa5e7, 0xa6eb, 0xa8c9, 0xa8ca, 0xab46, + 0xab47, 0xadbd, 0xdcb3, 0xf6d6, 0xa448, 0xa4b0, 0xa4af, 0xc952, + 0xa4b1, 0xa4b7, 0xa4b2, 0xa4b3, 0xc954, 0xc953, 0xa4b5, 0xa4b6, + 0xa4b4, 0xa54a, 0xa54b, 0xa54c, 0xa54d, 0xa549, 0xa550, 0xc96a, + 0xc966, 0xc969, 0xa551, 0xa561, 0xc968, 0xa54e, 0xa54f, 0xa548, + 0xc965, 0xc967, 0xa5f5, 0xc9b0, 0xa5f2, 0xa5f6, 0xc9ba, 0xc9ae, + 0xa5f3, 0xc9b2, 0xa5f4, 0xa5f7, 0xa5e9, 0xc9b1, 0xa5f8, 0xc9b5, + 0xc9b9, 0xc9b6, 0xc9b3, 0xa5ea, 0xa5ec, 0xa5f9, 0xa5ee, 0xc9ab, + 0xa5f1, 0xa5ef, 0xa5f0, 0xc9bb, 0xc9b8, 0xc9af, 0xa5ed, 0xc9ac, + 0xa5eb, 0xc9b4, 0xc9b7, 0xc9ad, 0xca66, 0xa742, 0xa6f4, 0xca67, + 0xa6f1, 0xa744, 0xa6f9, 0xa6f8, 0xca5b, 0xa6fc, 0xa6f7, 0xca60, + 0xca68, 0xca64, 0xa6fa, 0xa6fd, 0xa6ee, 0xa747, 0xca5d, 0xcbbd, + 0xa6ec, 0xa743, 0xa6ed, 0xa6f5, 0xa6f6, 0xca62, 0xca5e, 0xa6fb, + 0xa6f3, 0xca5a, 0xa6ef, 0xca65, 0xa745, 0xa748, 0xa6f2, 0xa740, + 0xa746, 0xa6f0, 0xca63, 0xa741, 0xca69, 0xca5c, 0xa6fe, 0xca5f, + 0xca61, 0xa8d8, 0xcbbf, 0xcbcb, 0xa8d0, 0xcbcc, 0xa8cb, 0xa8d5, + 0xa8ce, 0xcbb9, 0xa8d6, 0xcbb8, 0xcbbc, 0xcbc3, 0xcbc1, 0xa8de, + 0xa8d9, 0xcbb3, 0xcbb5, 0xa8db, 0xa8cf, 0xcbb6, 0xcbc2, 0xcbc9, + 0xa8d4, 0xcbbb, 0xcbb4, 0xa8d3, 0xcbb7, 0xa8d7, 0xcbba, 0xa8d2, + 0xa8cd, 0xa8dc, 0xcbc4, 0xa8dd, 0xcbc8, 0xcbc6, 0xcbca, 0xa8da, + 0xcbbe, 0xcbb2, 0xcbc0, 0xa8d1, 0xcbc5, 0xa8cc, 0xcbc7, 0xab56, + 0xab4a, 0xcde0, 0xcde8, 0xab49, 0xab51, 0xab5d, 0xcdee, 0xcdec, + 0xcde7, 0xab4b, 0xcded, 0xcde3, 0xab59, 0xab50, 0xab58, 0xcdde, + 0xcdea, 0xcde1, 0xab54, 0xcde2, 0xcddd, 0xab5b, 0xab4e, 0xab57, + 0xab4d, 0xcddf, 0xcde4, 0xcdeb, 0xab55, 0xab52, 0xcde6, 0xab5a, + 0xcde9, 0xcde5, 0xab4f, 0xab5c, 0xab53, 0xab4c, 0xab48, 0xcdef, + 0xadd7, 0xadc1, 0xadd1, 0xadd6, 0xd0d0, 0xd0cf, 0xd0d4, 0xd0d5, + 0xadc4, 0xadcd, 0xadda, 0xadce, 0xd0c9, 0xadc7, 0xd0ca, 0xaddc, + 0xadd3, 0xadbe, 0xadbf, 0xd0dd, 0xb0bf, 0xadcc, 0xadcb, 0xd0cb, + 0xadcf, 0xd45b, 0xadc6, 0xd0d6, 0xadd5, 0xadd4, 0xadca, 0xd0ce, + 0xd0d7, 0xd0c8, 0xadc9, 0xd0d8, 0xadd2, 0xd0cc, 0xadc0, 0xadc3, + 0xadc2, 0xd0d9, 0xadd0, 0xadc5, 0xadd9, 0xaddb, 0xd0d3, 0xadd8, + 0xd0db, 0xd0cd, 0xd0dc, 0xd0d1, 0xd0da, 0xd0d2, 0xadc8, 0xd463, + 0xd457, 0xb0b3, 0xd45c, 0xd462, 0xb0b2, 0xd455, 0xb0b6, 0xd459, + 0xd452, 0xb0b4, 0xd456, 0xb0b9, 0xb0be, 0xd467, 0xd451, 0xb0ba, + 0xd466, 0xb0b5, 0xd458, 0xb0b1, 0xd453, 0xd44f, 0xd45d, 0xd450, + 0xd44e, 0xd45a, 0xd460, 0xd461, 0xb0b7, 0xd85b, 0xd45e, 0xd44d, + 0xd45f, 0xb0c1, 0xd464, 0xb0c0, 0xd44c, 0xd454, 0xd465, 0xb0bc, + 0xb0bb, 0xb0b8, 0xb0bd, 0xb0af, 0xb0b0, 0xb3c8, 0xd85e, 0xd857, + 0xb3c5, 0xd85f, 0xd855, 0xd858, 0xb3c4, 0xd859, 0xb3c7, 0xd85d, + 0xd853, 0xd852, 0xb3c9, 0xb3ca, 0xb3c6, 0xb3cb, 0xd851, 0xd85c, + 0xd85a, 0xd854, 0xb3c3, 0xd856, 0xb6ca, 0xb6c4, 0xdcb7, 0xb6cd, + 0xdcbd, 0xdcc0, 0xb6c6, 0xb6c7, 0xdcba, 0xb6c5, 0xdcc3, 0xb6cb, + 0xdcc4, 0xdcbf, 0xb6cc, 0xdcb4, 0xb6c9, 0xdcb5, 0xdcbe, 0xdcbc, + 0xdcb8, 0xb6c8, 0xdcb6, 0xb6ce, 0xdcbb, 0xdcc2, 0xdcb9, 0xdcc1, + 0xb9b6, 0xb9b3, 0xb9b4, 0xe0f9, 0xe0f1, 0xb9b2, 0xb9af, 0xe0f2, + 0xb9b1, 0xe0f5, 0xe0f7, 0xe0fe, 0xe0fd, 0xe0f8, 0xb9ae, 0xe0f0, + 0xb9ac, 0xe0f3, 0xb9b7, 0xe0f6, 0xe0fa, 0xb9b0, 0xb9ad, 0xe0fc, + 0xe0fb, 0xb9b5, 0xe0f4, 0xbbf8, 0xe4ec, 0xe4e9, 0xbbf9, 0xbbf7, + 0xe4f0, 0xe4ed, 0xe4e6, 0xbbf6, 0xbbfa, 0xe4e7, 0xbbf5, 0xbbfd, + 0xe4ea, 0xe4eb, 0xbbfb, 0xbbfc, 0xe4f1, 0xe4ee, 0xe4ef, 0xbeaa, + 0xe8f8, 0xbea7, 0xe8f5, 0xbea9, 0xbeab, 0xe8f6, 0xbea8, 0xe8f7, + 0xe8f4, 0xc076, 0xecbd, 0xc077, 0xecbb, 0xecbc, 0xecba, 0xecb9, + 0xecbe, 0xc075, 0xefb8, 0xefb9, 0xe4e8, 0xefb7, 0xc078, 0xc35f, + 0xf1eb, 0xf1ec, 0xc4d7, 0xc4d8, 0xf5c1, 0xf5c0, 0xc56c, 0xc56b, + 0xf7d0, 0xa449, 0xa461, 0xa4b9, 0xa4b8, 0xa553, 0xa552, 0xa5fc, + 0xa5fb, 0xa5fd, 0xa5fa, 0xa74a, 0xa749, 0xa74b, 0xa8e0, 0xa8df, + 0xa8e1, 0xab5e, 0xa259, 0xd0de, 0xa25a, 0xb0c2, 0xa25c, 0xa25b, + 0xd860, 0xa25d, 0xb9b8, 0xa25e, 0xa44a, 0xa4ba, 0xa5fe, 0xa8e2, + 0xa44b, 0xa4bd, 0xa4bb, 0xa4bc, 0xa640, 0xa74c, 0xa8e4, 0xa8e3, + 0xa8e5, 0xaddd, 0xbeac, 0xc94e, 0xa554, 0xa555, 0xa641, 0xca6a, + 0xab60, 0xab5f, 0xd0e0, 0xd0df, 0xb0c3, 0xa4be, 0xc955, 0xcbcd, + 0xab61, 0xade0, 0xadde, 0xaddf, 0xbead, 0xa556, 0xa642, 0xc9bc, + 0xa74d, 0xa74e, 0xca6b, 0xcbce, 0xa8e6, 0xcbcf, 0xd0e2, 0xd0e3, + 0xade3, 0xd0e4, 0xd0e1, 0xade4, 0xade2, 0xade1, 0xd0e5, 0xd468, + 0xd861, 0xdcc5, 0xe140, 0xbbfe, 0xbeae, 0xe8f9, 0xa44c, 0xa45a, + 0xb0c4, 0xb3cd, 0xb9b9, 0xc942, 0xa4bf, 0xa559, 0xa557, 0xa558, + 0xa8e7, 0xa44d, 0xa44e, 0xa462, 0xa4c0, 0xa4c1, 0xa4c2, 0xc9be, + 0xa55a, 0xc96b, 0xa646, 0xc9bf, 0xa644, 0xa645, 0xc9bd, 0xa647, + 0xa643, 0xca6c, 0xaaec, 0xca6d, 0xca6e, 0xa750, 0xa74f, 0xa753, + 0xa751, 0xa752, 0xa8ed, 0xa8ec, 0xcbd4, 0xcbd1, 0xcbd2, 0xcbd0, + 0xa8ee, 0xa8ea, 0xa8e9, 0xa8eb, 0xa8e8, 0xa8ef, 0xab63, 0xcdf0, + 0xcbd3, 0xab68, 0xcdf1, 0xab64, 0xab67, 0xab66, 0xab65, 0xab62, + 0xd0e8, 0xade7, 0xd0eb, 0xade5, 0xd0e7, 0xade8, 0xade6, 0xade9, + 0xd0e9, 0xd0ea, 0xd0e6, 0xd0ec, 0xb3d1, 0xb0c5, 0xd469, 0xd46b, + 0xd46a, 0xd46c, 0xb0c6, 0xb3ce, 0xb3cf, 0xb3d0, 0xb6d0, 0xdcc7, + 0xdcc6, 0xdcc8, 0xdcc9, 0xb6d1, 0xb6cf, 0xe141, 0xe142, 0xb9bb, + 0xb9ba, 0xe35a, 0xbc40, 0xbc41, 0xbc42, 0xbc44, 0xe4f2, 0xe4f3, + 0xbc43, 0xbeaf, 0xbeb0, 0xf1ed, 0xf5c3, 0xf5c2, 0xf7d1, 0xa44f, + 0xa55c, 0xa55b, 0xa648, 0xc9c0, 0xa755, 0xa756, 0xa754, 0xa757, + 0xca6f, 0xca70, 0xa8f1, 0xcbd5, 0xa8f0, 0xcdf2, 0xab6c, 0xcdf3, + 0xab6b, 0xab69, 0xab6a, 0xd0ed, 0xb0c7, 0xd46e, 0xb0ca, 0xd46d, + 0xb1e5, 0xb0c9, 0xb0c8, 0xb3d4, 0xb3d3, 0xb3d2, 0xb6d2, 0xb6d5, + 0xb6d6, 0xb6d4, 0xb6d3, 0xe143, 0xe144, 0xe4f5, 0xbc45, 0xe4f4, + 0xbeb1, 0xecbf, 0xc079, 0xf1ee, 0xc455, 0xa463, 0xa4c3, 0xc956, + 0xa4c4, 0xa4c5, 0xa55d, 0xa55e, 0xa649, 0xca71, 0xcbd6, 0xcbd7, + 0xab6d, 0xd0ee, 0xb0cc, 0xb0cb, 0xd863, 0xd862, 0xa450, 0xa4c6, + 0xa55f, 0xb0cd, 0xc943, 0xc96c, 0xa560, 0xc9c2, 0xa64b, 0xa64a, + 0xc9c1, 0xa758, 0xadea, 0xd46f, 0xb6d7, 0xe145, 0xb9bc, 0xe8fa, + 0xf3fd, 0xa4c7, 0xcbd8, 0xcdf4, 0xb0d0, 0xb0ce, 0xb0cf, 0xa451, + 0xa464, 0xa2cd, 0xa4ca, 0xa4c9, 0xa4c8, 0xa563, 0xa562, 0xc96d, + 0xc9c3, 0xa8f5, 0xa8f2, 0xa8f4, 0xa8f3, 0xab6e, 0xb3d5, 0xa452, + 0xa4cb, 0xa565, 0xa564, 0xca72, 0xa8f6, 0xc957, 0xa567, 0xa566, + 0xa64c, 0xa64d, 0xca73, 0xa759, 0xa75a, 0xa8f7, 0xa8f8, 0xa8f9, + 0xab6f, 0xcdf5, 0xadeb, 0xc944, 0xa4cc, 0xc9c4, 0xca74, 0xca75, + 0xcbd9, 0xcbda, 0xcdf7, 0xcdf6, 0xcdf9, 0xcdf8, 0xab70, 0xd470, + 0xaded, 0xd0ef, 0xadec, 0xd864, 0xb3d6, 0xd865, 0xe146, 0xb9bd, + 0xbc46, 0xf1ef, 0xc958, 0xa568, 0xb0d1, 0xa453, 0xa465, 0xa4ce, + 0xa4cd, 0xa4cf, 0xa8fb, 0xa8fa, 0xa8fc, 0xab71, 0xadee, 0xe8fb, + 0xc24f, 0xa466, 0xa56a, 0xa579, 0xa574, 0xa56f, 0xa56e, 0xa575, + 0xa573, 0xa56c, 0xa57a, 0xa56d, 0xa569, 0xa578, 0xa577, 0xa576, + 0xa56b, 0xa572, 0xa571, 0xa57b, 0xa570, 0xa653, 0xa659, 0xa655, + 0xa65b, 0xc9c5, 0xa658, 0xa64e, 0xa651, 0xa654, 0xa650, 0xa657, + 0xa65a, 0xa64f, 0xa652, 0xa656, 0xa65c, 0xca7e, 0xca7b, 0xa767, + 0xca7c, 0xa75b, 0xa75d, 0xa775, 0xa770, 0xcaa5, 0xca7d, 0xa75f, + 0xa761, 0xcaa4, 0xa768, 0xca78, 0xa774, 0xa776, 0xa75c, 0xa76d, + 0xca76, 0xa773, 0xa764, 0xa76e, 0xa76f, 0xca77, 0xa76c, 0xa76a, + 0xa76b, 0xa771, 0xcaa1, 0xa75e, 0xa772, 0xcaa3, 0xa766, 0xa763, + 0xca7a, 0xa762, 0xcaa6, 0xa765, 0xa769, 0xa760, 0xcaa2, 0xca79, + 0xcbeb, 0xcbea, 0xa94f, 0xcbed, 0xcbef, 0xcbe4, 0xcbe7, 0xcbee, + 0xa950, 0xcbe1, 0xcbe5, 0xcbe9, 0xce49, 0xa94b, 0xce4d, 0xa8fd, + 0xcbe6, 0xa8fe, 0xa94c, 0xa945, 0xa941, 0xcbe2, 0xa944, 0xa949, + 0xa952, 0xcbe3, 0xcbdc, 0xa943, 0xcbdd, 0xcbdf, 0xa946, 0xa948, + 0xcbdb, 0xcbe0, 0xa951, 0xa94d, 0xcbe8, 0xa953, 0xa94a, 0xcbde, + 0xa947, 0xa942, 0xa940, 0xcbec, 0xa94e, 0xce48, 0xcdfb, 0xce4b, + 0xcdfd, 0xab78, 0xaba8, 0xab74, 0xaba7, 0xab7d, 0xaba4, 0xab72, + 0xcdfc, 0xce43, 0xaba3, 0xce4f, 0xaba5, 0xab79, 0xce45, 0xce42, + 0xab77, 0xcdfa, 0xaba6, 0xce4a, 0xab7c, 0xce4c, 0xaba9, 0xab73, + 0xab7e, 0xab7b, 0xce40, 0xaba1, 0xce46, 0xce47, 0xab7a, 0xaba2, + 0xab76, 0xab75, 0xcdfe, 0xce44, 0xce4e, 0xd144, 0xadfb, 0xd0f1, + 0xd0f6, 0xadf4, 0xae40, 0xd0f4, 0xadef, 0xadf9, 0xadfe, 0xd0fb, + 0xadfa, 0xadfd, 0xd0fe, 0xadf5, 0xd0f5, 0xd142, 0xd143, 0xadf7, + 0xd141, 0xadf3, 0xae43, 0xd0f8, 0xadf1, 0xd146, 0xd0f9, 0xd0fd, + 0xadf6, 0xae42, 0xd0fa, 0xadfc, 0xd140, 0xd147, 0xd4a1, 0xd145, + 0xae44, 0xadf0, 0xd0fc, 0xd0f3, 0xadf8, 0xd0f2, 0xd0f7, 0xd0f0, + 0xae41, 0xd477, 0xb0e4, 0xd4a7, 0xb0e2, 0xb0df, 0xd47c, 0xb0db, + 0xd4a2, 0xb0e6, 0xd476, 0xd47b, 0xd47a, 0xadf2, 0xb0e1, 0xd4a5, + 0xd4a8, 0xd473, 0xb3e8, 0xd4a9, 0xb0e7, 0xb0d9, 0xb0d6, 0xd47e, + 0xb0d3, 0xd4a6, 0xb0da, 0xd4aa, 0xd474, 0xd4a4, 0xb0dd, 0xd475, + 0xd478, 0xd47d, 0xb0de, 0xb0dc, 0xb0e8, 0xb0e3, 0xb0d7, 0xb1d2, + 0xb0d8, 0xd479, 0xb0e5, 0xb0e0, 0xd4a3, 0xb0d5, 0xb0d4, 0xd471, + 0xd472, 0xd86a, 0xb3d7, 0xb3da, 0xd875, 0xb3ee, 0xd878, 0xb3d8, + 0xd871, 0xb3de, 0xb3e4, 0xb5bd, 0xb3e2, 0xd86e, 0xb3ef, 0xb3db, + 0xb3e3, 0xd876, 0xdcd7, 0xd87b, 0xd86f, 0xd866, 0xd873, 0xd86d, + 0xb3e1, 0xd879, 0xb3dd, 0xb3f1, 0xb3ea, 0xb3df, 0xb3dc, 0xb3e7, + 0xd87a, 0xd86c, 0xd872, 0xd874, 0xd868, 0xd877, 0xb3d9, 0xd867, + 0xb3e0, 0xb3f0, 0xb3ec, 0xd869, 0xb3e6, 0xb3ed, 0xb3e9, 0xb3e5, + 0xd870, 0xb3eb, 0xdcd5, 0xdcd1, 0xdce0, 0xdcca, 0xdcd3, 0xb6e5, + 0xb6e6, 0xb6de, 0xdcdc, 0xb6e8, 0xdccf, 0xdcce, 0xdccc, 0xdcde, + 0xb6dc, 0xdcd8, 0xdccd, 0xb6df, 0xdcd6, 0xb6da, 0xdcd2, 0xdcd9, + 0xdcdb, 0xdcdf, 0xb6e3, 0xdccb, 0xb6dd, 0xdcd0, 0xb6d8, 0xb6e4, + 0xdcda, 0xb6e0, 0xb6e1, 0xb6e7, 0xb6db, 0xa25f, 0xb6d9, 0xdcd4, + 0xb6e2, 0xdcdd, 0xb9cd, 0xb9c8, 0xe155, 0xe151, 0xe14b, 0xb9c2, + 0xb9be, 0xe154, 0xb9bf, 0xe14e, 0xe150, 0xe153, 0xb9c4, 0xb9cb, + 0xb9c5, 0xe149, 0xb9c6, 0xb9c7, 0xe14c, 0xb9cc, 0xe14a, 0xe14f, + 0xb9c3, 0xe148, 0xb9c9, 0xb9c1, 0xb9c0, 0xe14d, 0xe152, 0xb9ca, + 0xe147, 0xbc4d, 0xe547, 0xe544, 0xbc47, 0xbc53, 0xbc54, 0xbc4a, + 0xe542, 0xbc4c, 0xe4f9, 0xbc52, 0xe546, 0xbc49, 0xe548, 0xbc48, + 0xe543, 0xe545, 0xbc4b, 0xe541, 0xe4fa, 0xe4f7, 0xd86b, 0xe4fd, + 0xe4f6, 0xe4fc, 0xe4fb, 0xe4f8, 0xbc4f, 0xbc4e, 0xbc50, 0xe4fe, + 0xbeb2, 0xe540, 0xe945, 0xe8fd, 0xbebe, 0xe942, 0xbeb6, 0xbeba, + 0xe941, 0xbeb9, 0xbeb5, 0xbeb8, 0xbeb3, 0xbebd, 0xe943, 0xe8fe, + 0xbebc, 0xe8fc, 0xbebb, 0xe944, 0xe940, 0xbc51, 0xbebf, 0xe946, + 0xbeb7, 0xbeb4, 0xecc6, 0xecc8, 0xc07b, 0xecc9, 0xecc7, 0xecc5, + 0xecc4, 0xc07d, 0xecc3, 0xc07e, 0xecc1, 0xecc2, 0xc07a, 0xc0a1, + 0xc07c, 0xecc0, 0xc250, 0xefbc, 0xefba, 0xefbf, 0xefbd, 0xefbb, + 0xefbe, 0xc360, 0xf1f2, 0xf1f3, 0xc456, 0xf1f4, 0xf1f0, 0xf1f5, + 0xf1f1, 0xc251, 0xf3fe, 0xf441, 0xc459, 0xf440, 0xc458, 0xc457, + 0xc45a, 0xf5c5, 0xf5c6, 0xc4da, 0xc4d9, 0xc4db, 0xf5c4, 0xf6d8, + 0xf6d7, 0xc56d, 0xc56f, 0xc56e, 0xf6d9, 0xc5c8, 0xf8a6, 0xc5f1, + 0xf8a5, 0xf8ee, 0xc949, 0xa57d, 0xa57c, 0xa65f, 0xa65e, 0xc9c7, + 0xa65d, 0xc9c6, 0xa779, 0xcaa9, 0xcaa8, 0xa777, 0xa77a, 0xcaa7, + 0xa778, 0xcbf0, 0xcbf1, 0xa954, 0xabaa, 0xd148, 0xd149, 0xae45, + 0xae46, 0xd4ac, 0xb0e9, 0xb0eb, 0xd4ab, 0xb0ea, 0xd87c, 0xb3f2, + 0xb6e9, 0xb6ea, 0xdce1, 0xb9cf, 0xb9ce, 0xe549, 0xe948, 0xe947, + 0xf96b, 0xa467, 0xc959, 0xc96e, 0xc96f, 0xa662, 0xa666, 0xc9c9, + 0xa664, 0xa663, 0xc9c8, 0xa665, 0xa661, 0xa660, 0xc9ca, 0xa7a6, + 0xa7a3, 0xa77d, 0xcaaa, 0xcaab, 0xa7a1, 0xcaad, 0xa77b, 0xcaae, + 0xcaac, 0xa77e, 0xa7a2, 0xa7a5, 0xa7a4, 0xa77c, 0xcaaf, 0xa959, + 0xcbfe, 0xa95b, 0xa95a, 0xcc40, 0xa958, 0xa957, 0xcbf5, 0xcbf4, + 0xcbf2, 0xcbf7, 0xcbf6, 0xcbf3, 0xcbfc, 0xcbfd, 0xcbfa, 0xcbf8, + 0xa956, 0xcbfb, 0xa95c, 0xcc41, 0xcbf9, 0xabab, 0xa955, 0xabac, + 0xce54, 0xce5a, 0xabb2, 0xce58, 0xce5e, 0xce55, 0xce59, 0xce5b, + 0xce5d, 0xce57, 0xce56, 0xce51, 0xce52, 0xabad, 0xabaf, 0xabae, + 0xce53, 0xce5c, 0xabb1, 0xce50, 0xd153, 0xd152, 0xd157, 0xd14e, + 0xd151, 0xd150, 0xd154, 0xd158, 0xae47, 0xae4a, 0xd14f, 0xd155, + 0xae49, 0xd14a, 0xabb0, 0xd4ba, 0xd156, 0xd14d, 0xae48, 0xd14c, + 0xd4b1, 0xb0ec, 0xb0f0, 0xd4c1, 0xd4af, 0xd4bd, 0xb0f1, 0xd4bf, + 0xd4c5, 0xd4c9, 0xd4c0, 0xd4b4, 0xd4bc, 0xd4ca, 0xd4c8, 0xd4be, + 0xd4b9, 0xd4b2, 0xd8a6, 0xd4b0, 0xb0f5, 0xd4b7, 0xb0f6, 0xb0f2, + 0xd4ad, 0xd4c3, 0xd4b5, 0xd4b3, 0xd4c6, 0xb0f3, 0xd4cc, 0xb0ed, + 0xb0ef, 0xd4bb, 0xd4b6, 0xae4b, 0xb0ee, 0xd4b8, 0xd4c7, 0xd4cb, + 0xd4c2, 0xd4c4, 0xd4ae, 0xd8a1, 0xd8aa, 0xd8a9, 0xb3fa, 0xd8a2, + 0xb3fb, 0xb3f9, 0xd8a4, 0xb3f6, 0xd8a8, 0xd8a3, 0xd8a5, 0xd87d, + 0xb3f4, 0xd8b2, 0xd8b1, 0xd8ae, 0xb3f3, 0xb3f7, 0xb3f8, 0xd14b, + 0xd8ab, 0xb3f5, 0xb0f4, 0xd8ad, 0xd87e, 0xd8b0, 0xd8af, 0xd8b3, + 0xdcef, 0xd8ac, 0xd8a7, 0xdce7, 0xb6f4, 0xb6f7, 0xb6f2, 0xdce6, + 0xdcea, 0xdce5, 0xb6ec, 0xb6f6, 0xdce2, 0xb6f0, 0xdce9, 0xb6ee, + 0xb6ed, 0xdcec, 0xb6ef, 0xdcee, 0xdceb, 0xb6eb, 0xb6f5, 0xdcf0, + 0xdce4, 0xdced, 0xdce3, 0xb6f1, 0xb6f3, 0xdce8, 0xdcf1, 0xe15d, + 0xb9d0, 0xe163, 0xb9d5, 0xe15f, 0xe166, 0xe157, 0xb9d7, 0xb9d1, + 0xe15c, 0xbc55, 0xe15b, 0xe164, 0xb9d2, 0xb9d6, 0xe15a, 0xe160, + 0xe165, 0xe156, 0xb9d4, 0xe15e, 0xe162, 0xe168, 0xe158, 0xe161, + 0xb9d3, 0xe167, 0xe159, 0xbc59, 0xe54b, 0xbc57, 0xbc56, 0xe54d, + 0xe552, 0xe54e, 0xe551, 0xbc5c, 0xbea5, 0xbc5b, 0xe54a, 0xe550, + 0xbc5a, 0xe54f, 0xe54c, 0xbc58, 0xe94d, 0xe94f, 0xe94a, 0xbec1, + 0xe94c, 0xbec0, 0xe94e, 0xbec3, 0xe950, 0xbec2, 0xe949, 0xe94b, + 0xc0a5, 0xeccc, 0xc0a4, 0xeccd, 0xc0a3, 0xeccb, 0xc0a2, 0xecca, + 0xc253, 0xc252, 0xf1f6, 0xf1f8, 0xf1f7, 0xc361, 0xc362, 0xc363, + 0xf442, 0xc45b, 0xf7d3, 0xf7d2, 0xc5f2, 0xa468, 0xa4d0, 0xa7a7, + 0xce5f, 0xb3fc, 0xb3fd, 0xdcf2, 0xb9d8, 0xe169, 0xe553, 0xc95a, + 0xcab0, 0xcc42, 0xce60, 0xd159, 0xae4c, 0xf1f9, 0xc4dc, 0xa469, + 0xa57e, 0xc970, 0xa667, 0xa668, 0xa95d, 0xb0f7, 0xb9da, 0xb9db, + 0xb9d9, 0xa46a, 0xa4d1, 0xa4d3, 0xa4d2, 0xc95b, 0xa4d4, 0xa5a1, + 0xc971, 0xa5a2, 0xa669, 0xa66a, 0xc9cb, 0xa7a8, 0xcab1, 0xa961, + 0xcc43, 0xa95f, 0xa960, 0xa95e, 0xd15a, 0xabb6, 0xabb5, 0xabb7, + 0xabb4, 0xce61, 0xa962, 0xabb3, 0xae4d, 0xae4e, 0xae4f, 0xd4cd, + 0xb3fe, 0xd8b4, 0xb0f8, 0xb6f8, 0xb9dd, 0xb9dc, 0xe16a, 0xbc5d, + 0xbec4, 0xefc0, 0xf6da, 0xf7d4, 0xa46b, 0xa5a3, 0xa5a4, 0xc9d1, + 0xa66c, 0xa66f, 0xc9cf, 0xc9cd, 0xa66e, 0xc9d0, 0xc9d2, 0xc9cc, + 0xa671, 0xa670, 0xa66d, 0xa66b, 0xc9ce, 0xa7b3, 0xa7b0, 0xcab6, + 0xcab9, 0xcab8, 0xa7aa, 0xa7b2, 0xa7af, 0xcab5, 0xcab3, 0xa7ae, + 0xa7a9, 0xa7ac, 0xcab4, 0xcabb, 0xcab7, 0xa7ad, 0xa7b1, 0xa7b4, + 0xcab2, 0xcaba, 0xa7ab, 0xa967, 0xa96f, 0xcc4f, 0xcc48, 0xa970, + 0xcc53, 0xcc44, 0xcc4b, 0xa966, 0xcc45, 0xa964, 0xcc4c, 0xcc50, + 0xa963, 0xcc51, 0xcc4a, 0xcc4d, 0xa972, 0xa969, 0xcc54, 0xcc52, + 0xa96e, 0xa96c, 0xcc49, 0xa96b, 0xcc47, 0xcc46, 0xa96a, 0xa968, + 0xa971, 0xa96d, 0xa965, 0xcc4e, 0xabb9, 0xabc0, 0xce6f, 0xabb8, + 0xce67, 0xce63, 0xce73, 0xce62, 0xabbb, 0xce6c, 0xabbe, 0xabc1, + 0xabbc, 0xce70, 0xabbf, 0xae56, 0xce76, 0xce64, 0xce66, 0xce6d, + 0xce71, 0xce75, 0xce72, 0xce6b, 0xce6e, 0xce68, 0xabc3, 0xce6a, + 0xce69, 0xce74, 0xabba, 0xce65, 0xabc2, 0xabbd, 0xae5c, 0xd162, + 0xae5b, 0xd160, 0xae50, 0xae55, 0xd15f, 0xd15c, 0xd161, 0xae51, + 0xd15b, 0xae54, 0xae52, 0xd163, 0xae53, 0xae57, 0xae58, 0xae5a, + 0xae59, 0xd15d, 0xd15e, 0xd164, 0xd4d4, 0xb0f9, 0xd8c2, 0xd4d3, + 0xd4e6, 0xb140, 0xd4e4, 0xb0fe, 0xb0fa, 0xd4ed, 0xd4dd, 0xd4e0, + 0xb143, 0xd4ea, 0xd4e2, 0xb0fb, 0xb144, 0xd4e7, 0xd4e5, 0xd4d6, + 0xd4eb, 0xd4df, 0xd4da, 0xd4d0, 0xd4ec, 0xd4dc, 0xd4cf, 0xb142, + 0xd4e1, 0xd4ee, 0xd4de, 0xd4d2, 0xd4d7, 0xd4ce, 0xb141, 0xd4db, + 0xd4d8, 0xb0fc, 0xd4d1, 0xd4e9, 0xb0fd, 0xd4d9, 0xd4d5, 0xd4e8, + 0xb440, 0xd8bb, 0xd8b8, 0xd8c9, 0xd8bd, 0xd8ca, 0xb442, 0xd8c6, + 0xd8c3, 0xd8c4, 0xd8c7, 0xd8cb, 0xd4e3, 0xd8cd, 0xdd47, 0xb443, + 0xd8ce, 0xd8b6, 0xd8c0, 0xd8c5, 0xb441, 0xb444, 0xd8cc, 0xd8cf, + 0xd8ba, 0xd8b7, 0xd8b9, 0xd8be, 0xd8bc, 0xb445, 0xd8c8, 0xd8bf, + 0xd8c1, 0xd8b5, 0xdcfa, 0xdcf8, 0xb742, 0xb740, 0xdd43, 0xdcf9, + 0xdd44, 0xdd40, 0xdcf7, 0xdd46, 0xdcf6, 0xdcfd, 0xb6fe, 0xb6fd, + 0xb6fc, 0xdcfb, 0xdd41, 0xb6f9, 0xb741, 0xdcf4, 0xdcfe, 0xdcf3, + 0xdcfc, 0xb6fa, 0xdd42, 0xdcf5, 0xb6fb, 0xdd45, 0xe16e, 0xb9e2, + 0xb9e1, 0xb9e3, 0xe17a, 0xe170, 0xe176, 0xe16b, 0xe179, 0xe178, + 0xe17c, 0xe175, 0xb9de, 0xe174, 0xb9e4, 0xe16d, 0xb9df, 0xe17b, + 0xb9e0, 0xe16f, 0xe172, 0xe177, 0xe171, 0xe16c, 0xe173, 0xe555, + 0xbc61, 0xe558, 0xe557, 0xe55a, 0xe55c, 0xbc5f, 0xe556, 0xe554, + 0xe55d, 0xe55b, 0xe559, 0xe55f, 0xe55e, 0xbc63, 0xbc5e, 0xbc60, + 0xbc62, 0xe560, 0xe957, 0xe956, 0xe955, 0xe958, 0xe951, 0xe952, + 0xe95a, 0xe953, 0xbec5, 0xe95c, 0xe95b, 0xe954, 0xecd1, 0xc0a8, + 0xeccf, 0xecd4, 0xecd3, 0xe959, 0xc0a7, 0xecd2, 0xecce, 0xecd6, + 0xecd5, 0xc0a6, 0xecd0, 0xbec6, 0xc254, 0xefc1, 0xf1fa, 0xf1fb, + 0xf1fc, 0xc45c, 0xc45d, 0xf443, 0xf5c8, 0xf5c7, 0xf6db, 0xf6dc, + 0xf7d5, 0xf8a7, 0xa46c, 0xa46d, 0xa46e, 0xa4d5, 0xa5a5, 0xc9d3, + 0xa672, 0xa673, 0xa7b7, 0xa7b8, 0xa7b6, 0xa7b5, 0xa973, 0xcc55, + 0xa975, 0xa974, 0xcc56, 0xabc4, 0xae5d, 0xd165, 0xd4f0, 0xb145, + 0xb447, 0xd4ef, 0xb446, 0xb9e5, 0xe17d, 0xbec7, 0xc0a9, 0xecd7, + 0xc45e, 0xc570, 0xc972, 0xa5a6, 0xc973, 0xa676, 0xa674, 0xa675, + 0xa677, 0xa7ba, 0xa7b9, 0xcabc, 0xa7bb, 0xcabd, 0xcc57, 0xcc58, + 0xa976, 0xa978, 0xa97a, 0xa977, 0xa97b, 0xa979, 0xabc8, 0xabc5, + 0xabc7, 0xabc9, 0xabc6, 0xd166, 0xce77, 0xd168, 0xd167, 0xae63, + 0xae5f, 0xae60, 0xae62, 0xae64, 0xae61, 0xae66, 0xae65, 0xb14a, + 0xd4f2, 0xd4f1, 0xb149, 0xb148, 0xb147, 0xb14b, 0xb146, 0xd8d5, + 0xd8d2, 0xb449, 0xd8d1, 0xd8d6, 0xb44b, 0xd8d4, 0xb448, 0xb44a, + 0xd8d3, 0xdd48, 0xdd49, 0xdd4a, 0xb9e6, 0xb9ee, 0xe17e, 0xb9e8, + 0xb9ec, 0xe1a1, 0xb9ed, 0xb9e9, 0xb9ea, 0xb9e7, 0xb9eb, 0xbc66, + 0xd8d0, 0xbc67, 0xbc65, 0xbc64, 0xe95d, 0xbec8, 0xecd8, 0xecd9, + 0xc364, 0xc45f, 0xa46f, 0xa678, 0xabca, 0xd169, 0xae67, 0xb14e, + 0xb14d, 0xb14c, 0xb44c, 0xb44d, 0xd8d7, 0xb9ef, 0xbec9, 0xa470, + 0xc95c, 0xa4d6, 0xc974, 0xc9d4, 0xa679, 0xa97c, 0xdd4b, 0xa471, + 0xa4d7, 0xc9d5, 0xcabe, 0xcabf, 0xa7bc, 0xd8d8, 0xb44e, 0xdd4c, + 0xc0aa, 0xa472, 0xa4a8, 0xa4d8, 0xc975, 0xa5a7, 0xa7c0, 0xa7bf, + 0xa7bd, 0xa7be, 0xcc59, 0xa97e, 0xa9a1, 0xcc5a, 0xa97d, 0xabce, + 0xce78, 0xabcd, 0xabcb, 0xabcc, 0xae6a, 0xae68, 0xd16b, 0xae69, + 0xd16a, 0xae5e, 0xd4f3, 0xb150, 0xb151, 0xb14f, 0xb9f0, 0xe1a2, + 0xbc68, 0xbc69, 0xe561, 0xc0ab, 0xefc2, 0xefc3, 0xc4dd, 0xf8a8, + 0xc94b, 0xa4d9, 0xa473, 0xc977, 0xc976, 0xa67a, 0xc9d7, 0xc9d8, + 0xc9d6, 0xc9d9, 0xcac7, 0xcac2, 0xcac4, 0xcac6, 0xcac3, 0xa7c4, + 0xcac0, 0xcac1, 0xa7c1, 0xa7c2, 0xcac5, 0xcac8, 0xa7c3, 0xcac9, + 0xcc68, 0xcc62, 0xcc5d, 0xa9a3, 0xcc65, 0xcc63, 0xcc5c, 0xcc69, + 0xcc6c, 0xcc67, 0xcc60, 0xa9a5, 0xcc66, 0xa9a6, 0xcc61, 0xcc64, + 0xcc5b, 0xcc5f, 0xcc6b, 0xa9a7, 0xa9a8, 0xcc5e, 0xcc6a, 0xa9a2, + 0xa9a4, 0xceab, 0xcea4, 0xceaa, 0xcea3, 0xcea5, 0xce7d, 0xce7b, + 0xceac, 0xcea9, 0xce79, 0xabd0, 0xcea7, 0xcea8, 0xcea6, 0xce7c, + 0xce7a, 0xabcf, 0xcea2, 0xce7e, 0xcea1, 0xcead, 0xae6f, 0xae6e, + 0xd16c, 0xae6b, 0xd16e, 0xae70, 0xd16f, 0xae73, 0xae71, 0xd170, + 0xceae, 0xd172, 0xae6d, 0xae6c, 0xd16d, 0xd171, 0xae72, 0xb153, + 0xb152, 0xd4f5, 0xd4f9, 0xd4fb, 0xb154, 0xd4fe, 0xb158, 0xd541, + 0xb15a, 0xb156, 0xb15e, 0xb15b, 0xd4f7, 0xb155, 0xd4f6, 0xd4f4, + 0xd543, 0xd4f8, 0xb157, 0xd542, 0xb15c, 0xd4fd, 0xd4fc, 0xb15d, + 0xd4fa, 0xb159, 0xd544, 0xd540, 0xd8e7, 0xd8ee, 0xd8e3, 0xb451, + 0xd8df, 0xd8ef, 0xd8d9, 0xd8ec, 0xd8ea, 0xd8e4, 0xd8ed, 0xd8e6, + 0xd8de, 0xd8f0, 0xd8dc, 0xd8e9, 0xd8da, 0xd8f1, 0xb452, 0xd8eb, + 0xdd4f, 0xd8dd, 0xb44f, 0xd8e1, 0xb450, 0xd8e0, 0xd8e5, 0xd8e2, + 0xd8e8, 0xdd53, 0xdd56, 0xdd4e, 0xdd50, 0xdd55, 0xdd54, 0xb743, + 0xd8db, 0xdd52, 0xb744, 0xdd4d, 0xdd51, 0xe1a9, 0xe1b0, 0xe1a7, + 0xe1ae, 0xe1a5, 0xe1ad, 0xe1b1, 0xe1a4, 0xe1a8, 0xe1a3, 0xb9f1, + 0xe1a6, 0xb9f2, 0xe1ac, 0xe1ab, 0xe1aa, 0xe1af, 0xe565, 0xe567, + 0xbc6b, 0xe568, 0xe563, 0xe562, 0xe56c, 0xe56a, 0xbc6a, 0xe56d, + 0xe564, 0xe569, 0xe56b, 0xe566, 0xe961, 0xe966, 0xe960, 0xe965, + 0xe95e, 0xe968, 0xe964, 0xe969, 0xe963, 0xe95f, 0xe967, 0xe96a, + 0xe962, 0xecda, 0xc0af, 0xc0ad, 0xc0ac, 0xc0ae, 0xefc4, 0xf172, + 0xf1fd, 0xf444, 0xf445, 0xc460, 0xf5c9, 0xc4de, 0xf5ca, 0xf6de, + 0xc572, 0xc571, 0xf6dd, 0xc5c9, 0xf7d6, 0xa474, 0xa67b, 0xc9da, + 0xcaca, 0xa8b5, 0xb15f, 0xa475, 0xa5aa, 0xa5a9, 0xa5a8, 0xa7c5, + 0xae74, 0xdd57, 0xa476, 0xa477, 0xa478, 0xa4da, 0xabd1, 0xceaf, + 0xb453, 0xa479, 0xc95d, 0xa5ab, 0xa5ac, 0xc978, 0xa67c, 0xcacb, + 0xa7c6, 0xcacc, 0xa9ae, 0xcc6e, 0xa9ac, 0xa9ab, 0xcc6d, 0xa9a9, + 0xcc6f, 0xa9aa, 0xa9ad, 0xabd2, 0xabd4, 0xceb3, 0xceb0, 0xceb1, + 0xceb2, 0xceb4, 0xabd3, 0xd174, 0xd173, 0xae76, 0xae75, 0xb162, + 0xd546, 0xb161, 0xb163, 0xb160, 0xb455, 0xd545, 0xb456, 0xd8f3, + 0xb457, 0xd8f2, 0xb454, 0xdd5a, 0xdd5c, 0xb745, 0xdd5b, 0xdd59, + 0xdd58, 0xe1b4, 0xb9f7, 0xb9f5, 0xb9f6, 0xe1b2, 0xe1b3, 0xb9f3, + 0xe571, 0xe56f, 0xbc6d, 0xe570, 0xbc6e, 0xbc6c, 0xb9f4, 0xe96d, + 0xe96b, 0xe96c, 0xe56e, 0xecdc, 0xc0b0, 0xecdb, 0xefc5, 0xefc6, + 0xe96e, 0xf1fe, 0xa47a, 0xa5ad, 0xa67e, 0xc9db, 0xa67d, 0xa9af, + 0xb746, 0xa4db, 0xa5ae, 0xabd5, 0xb458, 0xc979, 0xc97a, 0xc9dc, + 0xa7c8, 0xcad0, 0xcace, 0xa7c9, 0xcacd, 0xcacf, 0xcad1, 0xa7c7, + 0xa9b3, 0xa9b4, 0xa9b1, 0xa9b0, 0xceb8, 0xa9b2, 0xabd6, 0xceb7, + 0xceb9, 0xceb6, 0xceba, 0xabd7, 0xae79, 0xd175, 0xd177, 0xae77, + 0xd178, 0xae78, 0xd176, 0xceb5, 0xd547, 0xd54a, 0xd54b, 0xd548, + 0xb167, 0xb166, 0xb164, 0xb165, 0xd549, 0xb168, 0xb45a, 0xb45b, + 0xb45c, 0xdd5d, 0xdd5f, 0xdd61, 0xb748, 0xb747, 0xb459, 0xdd60, + 0xdd5e, 0xe1b8, 0xe1b6, 0xe1bc, 0xb9f8, 0xe1bd, 0xe1ba, 0xb9f9, + 0xe1b7, 0xe1b5, 0xe1bb, 0xbc70, 0xe573, 0xe1b9, 0xbc72, 0xe574, + 0xbc71, 0xbc74, 0xe575, 0xbc6f, 0xbc73, 0xe973, 0xe971, 0xe970, + 0xe972, 0xe96f, 0xc366, 0xf446, 0xf447, 0xf5cb, 0xf6df, 0xc655, + 0xa9b5, 0xa7ca, 0xabd8, 0xa47b, 0xa4dc, 0xa5af, 0xc9dd, 0xa7cb, + 0xcad2, 0xcebb, 0xabd9, 0xb9fa, 0xa47c, 0xa6a1, 0xb749, 0xa47d, + 0xa4dd, 0xa4de, 0xa5b1, 0xa5b0, 0xc9de, 0xa6a2, 0xcad3, 0xa7cc, + 0xcc71, 0xcc72, 0xcc73, 0xa9b6, 0xa9b7, 0xcc70, 0xa9b8, 0xabda, + 0xcebc, 0xd17a, 0xae7a, 0xd179, 0xb169, 0xd54c, 0xb16a, 0xd54d, + 0xb45d, 0xdd62, 0xe1bf, 0xe1be, 0xb9fb, 0xbc75, 0xe576, 0xbeca, + 0xe974, 0xc0b1, 0xc573, 0xf7d8, 0xcc74, 0xcebd, 0xb16b, 0xd8f4, + 0xb74a, 0xc255, 0xa7ce, 0xa7cd, 0xabdb, 0xd17b, 0xb16d, 0xb343, + 0xb16e, 0xb16c, 0xb45e, 0xe1c0, 0xb9fc, 0xbc76, 0xc94c, 0xc9df, + 0xcad5, 0xa7cf, 0xcad4, 0xa7d0, 0xa9bc, 0xcc77, 0xcc76, 0xa9bb, + 0xa9b9, 0xa9ba, 0xcc75, 0xabdd, 0xcebe, 0xabe0, 0xabdc, 0xabe2, + 0xabde, 0xabdf, 0xabe1, 0xae7d, 0xae7c, 0xae7b, 0xd54f, 0xb16f, + 0xb172, 0xb170, 0xd54e, 0xb175, 0xb171, 0xd550, 0xb174, 0xb173, + 0xd8f6, 0xd8f5, 0xb461, 0xb45f, 0xb460, 0xd8f7, 0xb74b, 0xdd64, + 0xb74c, 0xdd63, 0xe577, 0xbc78, 0xe1c1, 0xbc77, 0xb9fd, 0xecde, + 0xe975, 0xc0b2, 0xecdd, 0xf240, 0xf448, 0xf449, 0xa4df, 0xa5b2, + 0xc97b, 0xa7d2, 0xa7d4, 0xc9e2, 0xcad8, 0xcad7, 0xcad6, 0xc9e1, + 0xc9e0, 0xa6a4, 0xa7d3, 0xa7d1, 0xa6a3, 0xa9bd, 0xcc78, 0xa9be, + 0xcadd, 0xcadf, 0xcade, 0xcc79, 0xcada, 0xa7d8, 0xa7d6, 0xcad9, + 0xcadb, 0xcae1, 0xa7d5, 0xcadc, 0xcae5, 0xa9c0, 0xcae2, 0xa7d7, + 0xcae0, 0xcae3, 0xa9bf, 0xa9c1, 0xcae4, 0xccaf, 0xcca2, 0xcc7e, + 0xccae, 0xcca9, 0xabe7, 0xa9c2, 0xccaa, 0xccad, 0xabe3, 0xccac, + 0xa9c3, 0xa9c8, 0xa9c6, 0xcca3, 0xcc7c, 0xcca5, 0xa9cd, 0xccb0, + 0xabe4, 0xcca6, 0xabe5, 0xa9c9, 0xcca8, 0xcecd, 0xabe6, 0xcc7b, + 0xa9ca, 0xabe8, 0xa9cb, 0xa9c7, 0xa9cc, 0xcca7, 0xcc7a, 0xccab, + 0xa9c4, 0xcc7d, 0xcca4, 0xcca1, 0xa9c5, 0xcebf, 0xcec0, 0xceca, + 0xd1a1, 0xcecb, 0xabee, 0xcece, 0xcec4, 0xabed, 0xcec6, 0xcec7, + 0xcec9, 0xabe9, 0xaea3, 0xcec5, 0xcec1, 0xaea4, 0xcecf, 0xae7e, + 0xd17d, 0xcec8, 0xd17c, 0xcec3, 0xcecc, 0xabec, 0xaea1, 0xabf2, + 0xaea2, 0xced0, 0xd17e, 0xabeb, 0xaea6, 0xabf1, 0xabf0, 0xabef, + 0xaea5, 0xced1, 0xaea7, 0xabea, 0xcec2, 0xb176, 0xd1a4, 0xd1a6, + 0xd1a8, 0xaea8, 0xaeae, 0xd553, 0xd1ac, 0xd1a3, 0xb178, 0xd551, + 0xaead, 0xaeab, 0xd1ae, 0xd552, 0xd1a5, 0xaeac, 0xd1a9, 0xaeaf, + 0xd1ab, 0xaeaa, 0xd1aa, 0xd1ad, 0xd1a7, 0xaea9, 0xb179, 0xd1a2, + 0xb177, 0xb17a, 0xd555, 0xd55e, 0xb464, 0xb17c, 0xb1a3, 0xb465, + 0xd560, 0xb1aa, 0xd8f9, 0xd556, 0xb1a2, 0xb1a5, 0xb17e, 0xd554, + 0xd562, 0xd565, 0xd949, 0xd563, 0xd8fd, 0xb1a1, 0xb1a8, 0xb1ac, + 0xd55d, 0xd8f8, 0xd561, 0xb17b, 0xd8fa, 0xd564, 0xd8fc, 0xd559, + 0xb462, 0xd557, 0xd558, 0xb1a7, 0xb1a6, 0xd55b, 0xb1ab, 0xd55f, + 0xb1a4, 0xd55c, 0xb1a9, 0xb466, 0xb463, 0xd8fb, 0xd55a, 0xb17d, + 0xb46b, 0xb46f, 0xd940, 0xb751, 0xb46d, 0xd944, 0xb471, 0xdd65, + 0xd946, 0xb753, 0xb469, 0xb46c, 0xd947, 0xd948, 0xd94e, 0xb473, + 0xb754, 0xd94a, 0xd94f, 0xd943, 0xb75e, 0xb755, 0xb472, 0xd941, + 0xd950, 0xb75d, 0xb470, 0xb74e, 0xd94d, 0xb474, 0xd945, 0xd8fe, + 0xb46a, 0xd942, 0xd94b, 0xb74d, 0xb752, 0xb467, 0xd94c, 0xb750, + 0xb468, 0xb75c, 0xe1c3, 0xdd70, 0xdd68, 0xe1c2, 0xdd6c, 0xdd6e, + 0xdd6b, 0xb75b, 0xdd6a, 0xb75f, 0xe1d2, 0xb75a, 0xba40, 0xdd71, + 0xe1c4, 0xb758, 0xdd69, 0xdd6d, 0xb9fe, 0xb74f, 0xdd66, 0xdd67, + 0xba41, 0xb757, 0xb759, 0xb756, 0xdd6f, 0xe1c8, 0xe1c9, 0xe1ce, + 0xbc7d, 0xe1d5, 0xba47, 0xba46, 0xe1d0, 0xbc7c, 0xe1c5, 0xba45, + 0xe1d4, 0xba43, 0xba44, 0xe1d1, 0xe5aa, 0xbc7a, 0xb46e, 0xe1d3, + 0xbca3, 0xe1cb, 0xbc7b, 0xbca2, 0xe1c6, 0xe1ca, 0xe1c7, 0xe1cd, + 0xba48, 0xbc79, 0xba42, 0xe57a, 0xe1cf, 0xbca1, 0xbca4, 0xe1cc, + 0xbc7e, 0xe579, 0xe57e, 0xbece, 0xe578, 0xe9a3, 0xe5a9, 0xbca8, + 0xbca6, 0xbecc, 0xe5a6, 0xe5a2, 0xbcac, 0xe978, 0xbcaa, 0xe5a1, + 0xe976, 0xe5a5, 0xe5a8, 0xe57d, 0xbcab, 0xbca5, 0xe977, 0xbecd, + 0xe5a7, 0xbca7, 0xbca9, 0xe5a4, 0xbcad, 0xe5a3, 0xe57c, 0xe57b, + 0xbecb, 0xe5ab, 0xe97a, 0xece0, 0xbed0, 0xe9a2, 0xe97e, 0xece1, + 0xbed1, 0xe9a1, 0xe97c, 0xc0b4, 0xecdf, 0xe979, 0xe97b, 0xc0b5, + 0xbed3, 0xc0b3, 0xbed2, 0xc0b7, 0xe97d, 0xbecf, 0xefcf, 0xefc7, + 0xece7, 0xefc8, 0xece3, 0xc256, 0xece5, 0xece4, 0xc0b6, 0xece2, + 0xece6, 0xefd0, 0xefcc, 0xefce, 0xefc9, 0xefca, 0xefcd, 0xefcb, + 0xc367, 0xc36a, 0xc369, 0xc368, 0xc461, 0xf44a, 0xc462, 0xf241, + 0xc4df, 0xf5cc, 0xc4e0, 0xc574, 0xc5ca, 0xf7d9, 0xf7da, 0xf7db, + 0xf9ba, 0xa4e0, 0xc97c, 0xa5b3, 0xa6a6, 0xa6a7, 0xa6a5, 0xa6a8, + 0xa7da, 0xa7d9, 0xccb1, 0xa9cf, 0xa9ce, 0xd1af, 0xb1ad, 0xb1ae, + 0xb475, 0xdd72, 0xb760, 0xb761, 0xdd74, 0xdd76, 0xdd75, 0xe1d7, + 0xe1d6, 0xba49, 0xe1d8, 0xe5ac, 0xbcae, 0xbed4, 0xc0b8, 0xc257, + 0xc0b9, 0xa4e1, 0xcae6, 0xccb2, 0xa9d1, 0xa9d0, 0xa9d2, 0xabf3, + 0xced2, 0xced3, 0xd1b0, 0xaeb0, 0xb1af, 0xb476, 0xd951, 0xa4e2, + 0xa47e, 0xa4e3, 0xc97d, 0xa5b7, 0xa5b6, 0xa5b4, 0xa5b5, 0xa6ab, + 0xc9e9, 0xc9eb, 0xa6aa, 0xc9e3, 0xc9e4, 0xc9ea, 0xc9e6, 0xc9e8, + 0xa6a9, 0xc9e5, 0xc9ec, 0xc9e7, 0xa7e1, 0xa7ea, 0xa7e8, 0xcaf0, + 0xcaed, 0xcaf5, 0xa7e6, 0xcaf6, 0xa7df, 0xcaf3, 0xa7e5, 0xcaef, + 0xcaee, 0xa7e3, 0xcaf4, 0xa7e4, 0xa9d3, 0xa7de, 0xcaf1, 0xcae7, + 0xa7db, 0xa7ee, 0xcaec, 0xcaf2, 0xa7e0, 0xa7e2, 0xcae8, 0xcae9, + 0xcaea, 0xa7ed, 0xa7e7, 0xa7ec, 0xcaeb, 0xa7eb, 0xa7dd, 0xa7dc, + 0xa7e9, 0xa9e1, 0xccbe, 0xccb7, 0xa9dc, 0xa9ef, 0xccb3, 0xccba, + 0xccbc, 0xccbf, 0xa9ea, 0xccbb, 0xccb4, 0xa9e8, 0xccb8, 0xccc0, + 0xa9d9, 0xccbd, 0xa9e3, 0xa9e2, 0xccb6, 0xa9d7, 0xa9d8, 0xa9d6, + 0xa9ee, 0xa9e6, 0xa9e0, 0xa9d4, 0xccb9, 0xa9df, 0xa9d5, 0xa9e7, + 0xa9f0, 0xced4, 0xa9e4, 0xccb5, 0xa9da, 0xa9dd, 0xa9de, 0xa9ec, + 0xa9ed, 0xa9eb, 0xa9e5, 0xa9e9, 0xa9db, 0xabf4, 0xceda, 0xac41, + 0xabf8, 0xabfa, 0xac40, 0xcee6, 0xabfd, 0xd1b1, 0xaeb1, 0xac43, + 0xced7, 0xcedf, 0xabfe, 0xcede, 0xcedb, 0xcee3, 0xcee5, 0xabf7, + 0xabfb, 0xac42, 0xaeb3, 0xcee0, 0xabf9, 0xac45, 0xced9, 0xabfc, + 0xaeb2, 0xabf6, 0xced6, 0xcedd, 0xced5, 0xced8, 0xcedc, 0xd1b2, + 0xac44, 0xcee1, 0xcee2, 0xcee4, 0xabf5, 0xaec1, 0xd1be, 0xaebf, + 0xaec0, 0xd1b4, 0xd1c4, 0xaeb6, 0xd566, 0xd1c6, 0xd1c0, 0xd1b7, + 0xd1c9, 0xd1ba, 0xaebc, 0xd57d, 0xd1bd, 0xaebe, 0xaeb5, 0xd1cb, + 0xd1bf, 0xaeb8, 0xd1b8, 0xd1b5, 0xd1b6, 0xaeb9, 0xd1c5, 0xd1cc, + 0xaebb, 0xd1bc, 0xd1bb, 0xaec3, 0xaec2, 0xaeb4, 0xaeba, 0xaebd, + 0xd1c8, 0xd1c2, 0xaeb7, 0xd1b3, 0xd1ca, 0xd1c1, 0xd1c3, 0xd1c7, + 0xd567, 0xb1b7, 0xb1cb, 0xb1ca, 0xb1bf, 0xd579, 0xd575, 0xd572, + 0xd5a6, 0xb1ba, 0xb1b2, 0xd577, 0xb4a8, 0xb1b6, 0xd5a1, 0xb1cc, + 0xb1c9, 0xd57b, 0xd56a, 0xb1c8, 0xd5a3, 0xd569, 0xb1bd, 0xb1c1, + 0xd5a2, 0xd573, 0xb1c2, 0xb1bc, 0xd568, 0xb478, 0xd5a5, 0xd571, + 0xb1c7, 0xd574, 0xd5a4, 0xb1c6, 0xd952, 0xb1b3, 0xd56f, 0xb1b8, + 0xb1c3, 0xb1be, 0xd578, 0xd56e, 0xd56c, 0xd57e, 0xb1b0, 0xb1c4, + 0xb1b4, 0xb477, 0xd57c, 0xb1b5, 0xb1b1, 0xb1c0, 0xb1bb, 0xb1b9, + 0xd570, 0xb1c5, 0xd56d, 0xd57a, 0xd576, 0xd954, 0xd953, 0xd56b, + 0xd964, 0xb47a, 0xd96a, 0xd959, 0xd967, 0xdd77, 0xb47d, 0xd96b, + 0xd96e, 0xb47c, 0xd95c, 0xd96d, 0xd96c, 0xb47e, 0xd955, 0xb479, + 0xb4a3, 0xb4a1, 0xd969, 0xd95f, 0xb4a5, 0xd970, 0xd968, 0xd971, + 0xb4ad, 0xb4ab, 0xd966, 0xd965, 0xd963, 0xd95d, 0xb4a4, 0xb4a2, + 0xd1b9, 0xd956, 0xddb7, 0xd957, 0xb47b, 0xb4aa, 0xdd79, 0xb4a6, + 0xb4a7, 0xd958, 0xd96f, 0xdd78, 0xd960, 0xd95b, 0xb4a9, 0xd961, + 0xd95e, 0xb4ae, 0xb770, 0xdd7c, 0xddb1, 0xddb6, 0xddaa, 0xb76c, + 0xddbb, 0xb769, 0xdd7a, 0xdd7b, 0xb762, 0xb76b, 0xdda4, 0xb76e, + 0xb76f, 0xdda5, 0xddb2, 0xddb8, 0xb76a, 0xb764, 0xdda3, 0xdd7d, + 0xddba, 0xdda8, 0xdda9, 0xdd7e, 0xddb4, 0xddab, 0xddb5, 0xddad, + 0xb765, 0xe1d9, 0xb768, 0xb766, 0xddb9, 0xddb0, 0xddac, 0xdda1, + 0xba53, 0xddaf, 0xb76d, 0xdda7, 0xdda6, 0xb767, 0xb763, 0xe1ee, + 0xddb3, 0xddae, 0xdda2, 0xe1e9, 0xe1da, 0xe1e5, 0xe1ec, 0xba51, + 0xb4ac, 0xe1ea, 0xba4c, 0xba4b, 0xe1f1, 0xe1db, 0xe1e8, 0xe1dc, + 0xe1e7, 0xba4f, 0xe1eb, 0xd962, 0xe1f2, 0xe1e3, 0xba52, 0xe5ba, + 0xbcaf, 0xe1f0, 0xe1ef, 0xba54, 0xe5ad, 0xbcb0, 0xe5ae, 0xe1df, + 0xe1e0, 0xe1dd, 0xe1e2, 0xe1de, 0xe1f3, 0xba4e, 0xbcb1, 0xba50, + 0xba55, 0xe1e1, 0xe1ed, 0xe1e6, 0xe5b1, 0xba4a, 0xbcb4, 0xe9aa, + 0xe5b6, 0xe5b5, 0xe5b7, 0xe5b4, 0xbcb5, 0xbcbb, 0xbcb8, 0xbcb9, + 0xe5af, 0xe5b2, 0xe5bc, 0xbcc1, 0xbcbf, 0xe5b3, 0xd95a, 0xbcb2, + 0xe5b9, 0xe5b0, 0xbcc2, 0xe5b8, 0xba4d, 0xbcb7, 0xe1e4, 0xbcba, + 0xbcbe, 0xbcc0, 0xbcbd, 0xbcbc, 0xbcb6, 0xe5bb, 0xbcb3, 0xbcc3, + 0xbed8, 0xbed9, 0xe9a9, 0xbee2, 0xbedf, 0xbed6, 0xbedd, 0xe9ab, + 0xbedb, 0xbed5, 0xbedc, 0xe9a8, 0xc0bb, 0xbed7, 0xbede, 0xc0ba, + 0xe9a7, 0xe9a6, 0xbee0, 0xbee1, 0xe9a5, 0xe9a4, 0xc0bc, 0xe9ae, + 0xbeda, 0xe9ac, 0xc0bd, 0xc0c2, 0xecea, 0xecec, 0xc0bf, 0xeced, + 0xece9, 0xeceb, 0xc0c0, 0xc0c3, 0xece8, 0xc0be, 0xc0c1, 0xc259, + 0xe9ad, 0xc258, 0xc25e, 0xefd4, 0xc25c, 0xc25d, 0xefd7, 0xefd3, + 0xc25a, 0xefd1, 0xc36b, 0xefd5, 0xefd6, 0xefd2, 0xc25b, 0xf242, + 0xf245, 0xf246, 0xf244, 0xf247, 0xc36c, 0xf243, 0xf44e, 0xc464, + 0xf44d, 0xf44c, 0xf44b, 0xc463, 0xc465, 0xf5cd, 0xc4e2, 0xc4e1, + 0xf6e1, 0xf6e0, 0xf6e3, 0xc5cb, 0xc575, 0xf7dd, 0xf6e2, 0xf7dc, + 0xc5cd, 0xc5cc, 0xc5f3, 0xf8a9, 0xf8ef, 0xa4e4, 0xd972, 0xe9af, + 0xa6ac, 0xcaf7, 0xa7f1, 0xa7ef, 0xa7f0, 0xccc1, 0xa9f1, 0xac46, + 0xcee7, 0xcee8, 0xac47, 0xd1ce, 0xaec4, 0xaec5, 0xd1cd, 0xb1d3, + 0xb1cf, 0xd5a7, 0xb1d6, 0xb1d5, 0xb1ce, 0xb1d1, 0xb1d4, 0xb1d0, + 0xd976, 0xb1cd, 0xb4af, 0xb4b1, 0xb4b2, 0xd975, 0xd978, 0xb4b0, + 0xd973, 0xd977, 0xd974, 0xb771, 0xddbc, 0xba56, 0xe1f4, 0xbee3, + 0xbcc4, 0xe5bd, 0xbcc5, 0xbcc6, 0xe5bf, 0xe5be, 0xe5c0, 0xe9b1, + 0xe9b0, 0xecef, 0xecee, 0xc0c4, 0xc0c5, 0xf248, 0xa4e5, 0xd979, + 0xb4b4, 0xb4b3, 0xddbd, 0xefd8, 0xc4e3, 0xf7de, 0xa4e6, 0xaec6, + 0xb1d8, 0xb1d7, 0xd97a, 0xd97b, 0xb772, 0xe1f5, 0xba57, 0xe9b2, + 0xa4e7, 0xa5b8, 0xa9f2, 0xccc2, 0xcee9, 0xac48, 0xb1d9, 0xd97c, + 0xb4b5, 0xb773, 0xe5c1, 0xe5c2, 0xecf0, 0xc25f, 0xf8f0, 0xa4e8, + 0xccc3, 0xa9f3, 0xac49, 0xceea, 0xaec7, 0xd1d2, 0xd1d0, 0xd1d1, + 0xaec8, 0xd1cf, 0xb1db, 0xb1dc, 0xd5a8, 0xb1dd, 0xb1da, 0xd97d, + 0xd97e, 0xddbe, 0xba59, 0xba58, 0xecf1, 0xefd9, 0xf24a, 0xf249, + 0xf44f, 0xc95e, 0xac4a, 0xa4e9, 0xa5b9, 0xa6ae, 0xa6ad, 0xa6af, + 0xa6b0, 0xc9ee, 0xc9ed, 0xcaf8, 0xa7f2, 0xcafb, 0xcafa, 0xcaf9, + 0xcafc, 0xa9f4, 0xccc9, 0xccc5, 0xccce, 0xa9fb, 0xa9f9, 0xccca, + 0xccc6, 0xcccd, 0xa9f8, 0xaa40, 0xccc8, 0xccc4, 0xa9fe, 0xcccb, + 0xa9f7, 0xcccc, 0xa9fa, 0xa9fc, 0xccd0, 0xcccf, 0xccc7, 0xa9f6, + 0xa9f5, 0xa9fd, 0xceef, 0xcef5, 0xac50, 0xac4d, 0xceec, 0xcef1, + 0xac53, 0xac4b, 0xcef0, 0xac4e, 0xac51, 0xcef3, 0xac4c, 0xcef8, + 0xac4f, 0xac52, 0xceed, 0xcef2, 0xcef6, 0xceee, 0xceeb, 0xcef7, + 0xcef4, 0xaed0, 0xaec9, 0xaecc, 0xaecf, 0xd1d5, 0xaeca, 0xd1d3, + 0xaece, 0xaecb, 0xd1d6, 0xaecd, 0xd5ac, 0xb1df, 0xd5ab, 0xd5ad, + 0xb1de, 0xb1e3, 0xd1d4, 0xd5aa, 0xd5ae, 0xb1e0, 0xd5a9, 0xb1e2, + 0xb1e1, 0xd9a7, 0xd9a2, 0xb4b6, 0xb4ba, 0xb4b7, 0xd9a5, 0xd9a8, + 0xb4b8, 0xb4b9, 0xb4be, 0xddc7, 0xd9a6, 0xb4bc, 0xd9a3, 0xd9a1, + 0xb4bd, 0xd9a4, 0xb779, 0xddbf, 0xb776, 0xb777, 0xb775, 0xddc4, + 0xddc3, 0xddc0, 0xb77b, 0xddc2, 0xb4bb, 0xddc6, 0xddc1, 0xb778, + 0xb774, 0xb77a, 0xddc5, 0xba5c, 0xe1f8, 0xe1f7, 0xe1f6, 0xba5a, + 0xba5b, 0xe5c5, 0xe5c8, 0xbcc8, 0xbcc7, 0xe5c9, 0xe5c4, 0xbcca, + 0xe5c6, 0xbcc9, 0xe5c3, 0xe5c7, 0xbee9, 0xbee6, 0xe9bb, 0xe9ba, + 0xe9b9, 0xe9b4, 0xe9b5, 0xbee7, 0xbee4, 0xbee8, 0xe9b3, 0xbee5, + 0xe9b6, 0xe9b7, 0xe9bc, 0xe9b8, 0xecf2, 0xc0c7, 0xefdc, 0xc0c6, + 0xefda, 0xefdb, 0xc260, 0xc36e, 0xf24b, 0xc36d, 0xf451, 0xf452, + 0xc466, 0xf450, 0xc4e4, 0xf7df, 0xc5ce, 0xf8aa, 0xf8ab, 0xa4ea, + 0xa6b1, 0xa6b2, 0xa7f3, 0xccd1, 0xac54, 0xaed1, 0xb1e4, 0xb0d2, + 0xb4bf, 0xb4c0, 0xb3cc, 0xd9a9, 0xb77c, 0xe1fa, 0xe1f9, 0xa4eb, + 0xa6b3, 0xccd2, 0xaa42, 0xaa41, 0xcef9, 0xcefa, 0xd1d7, 0xd1d8, + 0xaed2, 0xaed3, 0xaed4, 0xd5af, 0xb1e6, 0xb4c2, 0xb4c1, 0xddc8, + 0xdf7a, 0xe1fb, 0xe9bd, 0xc261, 0xc467, 0xa4ec, 0xa5bc, 0xa5bd, + 0xa5bb, 0xa5be, 0xa5ba, 0xa6b6, 0xc9f6, 0xa6b5, 0xa6b7, 0xc9f1, + 0xc9f0, 0xc9f3, 0xc9f2, 0xc9f5, 0xa6b4, 0xc9ef, 0xc9f4, 0xcafd, + 0xa7fd, 0xcafe, 0xcb43, 0xa7fc, 0xcb47, 0xcb42, 0xcb45, 0xa7f5, + 0xa7f6, 0xa7f7, 0xa7f8, 0xa840, 0xcb41, 0xa7fa, 0xa841, 0xcb40, + 0xcb46, 0xa7f9, 0xcb44, 0xa7fb, 0xa7f4, 0xa7fe, 0xaa57, 0xccd4, + 0xaa43, 0xaa4d, 0xaa4e, 0xaa46, 0xaa58, 0xaa48, 0xccdc, 0xaa53, + 0xccd7, 0xaa49, 0xcce6, 0xcce7, 0xccdf, 0xccd8, 0xaa56, 0xcce4, + 0xaa51, 0xaa4f, 0xcce5, 0xcce3, 0xccdb, 0xccd3, 0xccda, 0xaa4a, + 0xaa50, 0xaa44, 0xccde, 0xccdd, 0xccd5, 0xaa52, 0xcce1, 0xccd6, + 0xaa55, 0xcce8, 0xaa45, 0xaa4c, 0xccd9, 0xcce2, 0xaa54, 0xaa47, + 0xaa4b, 0xcce0, 0xcf5b, 0xac5c, 0xac69, 0xcf56, 0xcf4c, 0xac62, + 0xcf4a, 0xac5b, 0xcf45, 0xac65, 0xcf52, 0xcefe, 0xcf41, 0xcf44, + 0xcefb, 0xcf51, 0xcf61, 0xac60, 0xcf46, 0xcf58, 0xcefd, 0xcf5f, + 0xcf60, 0xcf63, 0xcf5a, 0xcf4b, 0xcf53, 0xac66, 0xac59, 0xac61, + 0xac6d, 0xac56, 0xac58, 0xcf43, 0xac6a, 0xac63, 0xcf5d, 0xcf40, + 0xac6c, 0xac67, 0xcf49, 0xac6b, 0xcf50, 0xcf48, 0xac64, 0xcf5c, + 0xcf54, 0xac5e, 0xcf62, 0xcf47, 0xac5a, 0xcf59, 0xcf4f, 0xac5f, + 0xcf55, 0xac57, 0xcefc, 0xac68, 0xaee3, 0xac5d, 0xcf4e, 0xcf4d, + 0xcf42, 0xcf5e, 0xcf57, 0xac55, 0xd1ec, 0xaeea, 0xd1ed, 0xd1e1, + 0xaedf, 0xaeeb, 0xd1da, 0xd1e3, 0xd1eb, 0xd1d9, 0xd1f4, 0xaed5, + 0xd1f3, 0xd1ee, 0xd1ef, 0xaedd, 0xaee8, 0xd1e5, 0xd1e6, 0xd1f0, + 0xd1e7, 0xd1e2, 0xd1dc, 0xd1dd, 0xd1ea, 0xd1e4, 0xaed6, 0xaeda, + 0xd1f2, 0xd1de, 0xaee6, 0xaee2, 0xaee5, 0xaeec, 0xaedb, 0xaee7, + 0xd1e9, 0xaee9, 0xaed8, 0xaed7, 0xd1db, 0xd1df, 0xaee0, 0xd1f1, + 0xd1e8, 0xd1e0, 0xaee4, 0xaee1, 0xaed9, 0xaedc, 0xd5c4, 0xd5b4, + 0xd5b5, 0xd5b9, 0xd5c8, 0xd5c5, 0xd5be, 0xd5bd, 0xb1ed, 0xd5c1, + 0xd5d0, 0xd5b0, 0xd5d1, 0xd5c3, 0xd5d5, 0xd5c9, 0xb1ec, 0xd5c7, + 0xb1e7, 0xb1fc, 0xb1f2, 0xb1f6, 0xb1f5, 0xd5b1, 0xd5ce, 0xd5d4, + 0xd5cc, 0xd5d3, 0xd5c0, 0xd5b2, 0xd5d2, 0xd5c2, 0xb1ea, 0xb1f7, + 0xd5cb, 0xb1f0, 0xd5ca, 0xd5b3, 0xb1f8, 0xb1fa, 0xd5cd, 0xb1fb, + 0xb1e9, 0xd5ba, 0xd5cf, 0xb1ef, 0xb1f9, 0xd5bc, 0xd5c6, 0xd5b7, + 0xd5bb, 0xb1f4, 0xd5b6, 0xb1e8, 0xb1f1, 0xb1ee, 0xd5bf, 0xaede, + 0xd9c0, 0xb1eb, 0xb1f3, 0xd9c3, 0xd9d9, 0xd9ce, 0xb4d6, 0xb4d1, + 0xd9bd, 0xb4d2, 0xd9cd, 0xd9c6, 0xd9d3, 0xb4ce, 0xd9ab, 0xd9d5, + 0xb4c4, 0xd9b3, 0xb4c7, 0xb4c6, 0xb4d7, 0xd9ad, 0xd9cf, 0xd9d0, + 0xb4c9, 0xb4c5, 0xd9bb, 0xb4d0, 0xd9b6, 0xd9d1, 0xb4cc, 0xd9c9, + 0xd9d6, 0xd9b0, 0xd9b5, 0xd9af, 0xb4cb, 0xd9c2, 0xddde, 0xd9b1, + 0xb4cf, 0xd9ba, 0xd9d2, 0xb4ca, 0xd9b7, 0xd9b4, 0xd9c5, 0xb4cd, + 0xb4c3, 0xb4d9, 0xd9c8, 0xd9c7, 0xd9ac, 0xb4c8, 0xd9d4, 0xd9bc, + 0xd9be, 0xd9cb, 0xd9ca, 0xd9aa, 0xb4d3, 0xb4d5, 0xd9b2, 0xd9b9, + 0xd9c1, 0xb4d4, 0xd9b8, 0xd9c4, 0xd9d7, 0xd9cc, 0xd9d8, 0xd9ae, + 0xddf2, 0xb7a6, 0xddf0, 0xdddb, 0xdde0, 0xddd9, 0xddec, 0xddcb, + 0xddd2, 0xddea, 0xddf4, 0xdddc, 0xddcf, 0xdde2, 0xdde7, 0xddd3, + 0xdde4, 0xddd0, 0xddd7, 0xddd8, 0xb7a8, 0xddeb, 0xdde9, 0xddcc, + 0xddee, 0xddef, 0xddf1, 0xb7ac, 0xb7a4, 0xd5b8, 0xddd4, 0xdde6, + 0xddd5, 0xb7a1, 0xb7b1, 0xdded, 0xb7af, 0xb7ab, 0xddca, 0xb7a3, + 0xddcd, 0xb7b0, 0xdddd, 0xddc9, 0xb7a9, 0xdde1, 0xddd1, 0xb7aa, + 0xddda, 0xb77e, 0xb4d8, 0xdde3, 0xd9bf, 0xddce, 0xdde8, 0xb7a5, + 0xdde5, 0xb7a2, 0xdddf, 0xb7ad, 0xddd6, 0xddf3, 0xb7a7, 0xdec6, + 0xb7ae, 0xe24a, 0xe248, 0xe25e, 0xe246, 0xe258, 0xb77d, 0xba5f, + 0xe242, 0xe25d, 0xe247, 0xe255, 0xba64, 0xba5d, 0xe25b, 0xe240, + 0xe25a, 0xba6f, 0xe251, 0xe261, 0xba6d, 0xe249, 0xba5e, 0xe24b, + 0xe259, 0xba67, 0xe244, 0xba6b, 0xba61, 0xe24d, 0xe243, 0xe1fc, + 0xe257, 0xba68, 0xe260, 0xe1fd, 0xba65, 0xe253, 0xba66, 0xe245, + 0xe250, 0xe24c, 0xe24e, 0xba60, 0xe25f, 0xba6e, 0xe24f, 0xe262, + 0xe1fe, 0xe254, 0xba63, 0xba6c, 0xba6a, 0xe241, 0xe256, 0xba69, + 0xba62, 0xe252, 0xe25c, 0xe5d5, 0xe5d1, 0xe5cd, 0xe5e1, 0xe5de, + 0xbccd, 0xe5e5, 0xe5d4, 0xbcd8, 0xe5db, 0xe5d0, 0xe5da, 0xbcd5, + 0xe5ee, 0xe5eb, 0xe5dd, 0xe5ce, 0xe5e2, 0xe5e4, 0xbcd1, 0xe5d8, + 0xe5d3, 0xe5ca, 0xbcce, 0xbcd6, 0xe5e7, 0xbcd7, 0xe5cb, 0xe5ed, + 0xe5e0, 0xe5e6, 0xbcd4, 0xe5e3, 0xe5ea, 0xbcd9, 0xbcd3, 0xe5dc, + 0xe5cf, 0xe5ef, 0xe5cc, 0xe5e8, 0xbcd0, 0xe5d6, 0xe5d7, 0xbccf, + 0xbccc, 0xe5d2, 0xbcd2, 0xbccb, 0xe5e9, 0xe5ec, 0xe5d9, 0xe9ca, + 0xe9c2, 0xe9be, 0xbef6, 0xbeeb, 0xbef0, 0xbeec, 0xe9cc, 0xe9d7, + 0xbeea, 0xe9c4, 0xe9cd, 0xe5df, 0xe9ce, 0xbef1, 0xe9dd, 0xbef5, + 0xbef8, 0xe9c0, 0xbef4, 0xe9db, 0xe9dc, 0xe9d2, 0xe9d1, 0xe9c9, + 0xe9d3, 0xe9da, 0xe9d9, 0xbeef, 0xbeed, 0xe9cb, 0xe9c8, 0xe9c5, + 0xe9d8, 0xbef7, 0xe9d6, 0xbef3, 0xbef2, 0xe9d0, 0xe9bf, 0xe9c1, + 0xe9c3, 0xe9d5, 0xe9cf, 0xbeee, 0xe9c6, 0xe9d4, 0xe9c7, 0xc0cf, + 0xed45, 0xc0c8, 0xecf5, 0xed41, 0xc0ca, 0xed48, 0xecfc, 0xecf7, + 0xed49, 0xecf3, 0xecfe, 0xc0d1, 0xed44, 0xed4a, 0xecfd, 0xc0c9, + 0xed40, 0xecf4, 0xc0d0, 0xed47, 0xecf9, 0xc0cc, 0xecfb, 0xecf8, + 0xc0d2, 0xecfa, 0xc0cb, 0xc0ce, 0xed43, 0xecf6, 0xed46, 0xed42, + 0xc263, 0xefe7, 0xc268, 0xc269, 0xc262, 0xefe6, 0xefe3, 0xefe4, + 0xc266, 0xefde, 0xefe2, 0xc265, 0xefdf, 0xc267, 0xc264, 0xefdd, + 0xefe1, 0xefe5, 0xf251, 0xf24e, 0xf257, 0xf256, 0xf254, 0xf24f, + 0xc372, 0xf250, 0xc371, 0xc0cd, 0xf253, 0xc370, 0xf258, 0xf252, + 0xf24d, 0xefe0, 0xc36f, 0xf24c, 0xf456, 0xf455, 0xf255, 0xc468, + 0xf459, 0xf45a, 0xf454, 0xf458, 0xf453, 0xf5d1, 0xf457, 0xc4e7, + 0xc4e5, 0xf5cf, 0xf5d2, 0xf5ce, 0xf5d0, 0xc4e6, 0xf6e5, 0xf6e6, + 0xc576, 0xf6e4, 0xf7e2, 0xc5cf, 0xf7e0, 0xf7e1, 0xf8ac, 0xc656, + 0xf8f3, 0xf8f1, 0xf8f2, 0xf8f4, 0xf9bb, 0xa4ed, 0xa6b8, 0xaa59, + 0xcce9, 0xcf64, 0xd1f5, 0xd1f7, 0xd1f6, 0xd1f8, 0xb1fd, 0xd5d7, + 0xd1f9, 0xd5d6, 0xd5d8, 0xd5d9, 0xd9da, 0xb4db, 0xd9db, 0xd9dd, + 0xb4dc, 0xb4da, 0xd9dc, 0xddfa, 0xddf8, 0xddf7, 0xddf6, 0xddf5, + 0xb7b2, 0xddf9, 0xba70, 0xe263, 0xe265, 0xba71, 0xe264, 0xbcdb, + 0xbcda, 0xe5f0, 0xe9df, 0xe9de, 0xe9e0, 0xbef9, 0xed4b, 0xc0d3, + 0xefe8, 0xc26a, 0xf259, 0xc577, 0xa4ee, 0xa5bf, 0xa6b9, 0xa842, + 0xaa5a, 0xaa5b, 0xac6e, 0xd1fa, 0xb7b3, 0xe6d1, 0xbefa, 0xc26b, + 0xa4ef, 0xa6ba, 0xcceb, 0xaa5c, 0xccea, 0xcf65, 0xac6f, 0xcf66, + 0xac70, 0xd1fc, 0xaeee, 0xaeed, 0xd5de, 0xd5dc, 0xd5dd, 0xd5db, + 0xd5da, 0xd9de, 0xd9e1, 0xb4de, 0xd9df, 0xb4dd, 0xd9e0, 0xddfb, + 0xe266, 0xe267, 0xe268, 0xe5f3, 0xe5f2, 0xbcdc, 0xe5f1, 0xe5f4, + 0xe9e1, 0xe9e2, 0xe9e3, 0xed4c, 0xc0d4, 0xc26c, 0xf25a, 0xc4e8, + 0xc95f, 0xac71, 0xcf67, 0xaeef, 0xb1fe, 0xb4df, 0xd9e2, 0xb7b5, + 0xb7b4, 0xe269, 0xe26a, 0xbcdd, 0xbcde, 0xe9e5, 0xe9e4, 0xefe9, + 0xf7e3, 0xa4f0, 0xc960, 0xa5c0, 0xa843, 0xcb48, 0xac72, 0xb7b6, + 0xa4f1, 0xcf68, 0xac73, 0xcf69, 0xc0d5, 0xa4f2, 0xccec, 0xcf6a, + 0xd242, 0xd241, 0xd1fe, 0xd1fd, 0xd243, 0xd240, 0xb240, 0xb241, + 0xb4e0, 0xd9e3, 0xd9e4, 0xd9e5, 0xde41, 0xde42, 0xde40, 0xddfd, + 0xddfe, 0xb7b7, 0xe26b, 0xe5f7, 0xe5f6, 0xe5f5, 0xe5f8, 0xe9e7, + 0xe9e6, 0xbefb, 0xe9e8, 0xc0d6, 0xed4d, 0xefea, 0xf25b, 0xf6e7, + 0xa4f3, 0xa5c2, 0xa5c1, 0xaa5d, 0xc961, 0xc97e, 0xa6bb, 0xc9f7, + 0xcb49, 0xcb4a, 0xaa5e, 0xcced, 0xac74, 0xcf6b, 0xcf6c, 0xaef0, + 0xaef4, 0xd244, 0xaef3, 0xaef1, 0xaef2, 0xd5df, 0xb242, 0xb4e3, + 0xb4e1, 0xb4e2, 0xd9e6, 0xba72, 0xa4f4, 0xc9a1, 0xa5c3, 0xc9a4, + 0xa5c6, 0xc9a3, 0xa5c5, 0xa5c4, 0xa844, 0xc9a2, 0xc9f8, 0xc9fc, + 0xc9fe, 0xca40, 0xa6c5, 0xa6c6, 0xc9fb, 0xa6c1, 0xc9f9, 0xc9fd, + 0xa6c2, 0xa6bd, 0xa6be, 0xa6c4, 0xc9fa, 0xa6bc, 0xa845, 0xa6bf, + 0xa6c0, 0xa6c3, 0xcb5b, 0xcb59, 0xcb4c, 0xa851, 0xcb53, 0xa84c, + 0xcb4d, 0xcb55, 0xcb52, 0xa84f, 0xcb51, 0xa856, 0xcb5a, 0xa858, + 0xa85a, 0xcb4b, 0xa84d, 0xcb5c, 0xa854, 0xa857, 0xcd45, 0xa847, + 0xa85e, 0xa855, 0xcb4e, 0xa84a, 0xa859, 0xcb56, 0xa848, 0xa849, + 0xcd43, 0xcb4f, 0xa850, 0xa85b, 0xcb5d, 0xcb50, 0xa84e, 0xa853, + 0xccee, 0xa85c, 0xcb57, 0xa852, 0xa85d, 0xa846, 0xcb54, 0xa84b, + 0xcb58, 0xcd44, 0xaa6a, 0xaa7a, 0xccf5, 0xaa71, 0xcd4b, 0xaa62, + 0xaa65, 0xcd42, 0xccf3, 0xccf7, 0xaa6d, 0xaa6f, 0xccfa, 0xaa76, + 0xaa68, 0xaa66, 0xaa67, 0xaa75, 0xcd47, 0xaa70, 0xccf9, 0xccfb, + 0xaa6e, 0xaa73, 0xccfc, 0xcd4a, 0xac75, 0xaa79, 0xaa63, 0xcd49, + 0xcd4d, 0xccf8, 0xcd4f, 0xcd40, 0xaa6c, 0xccf4, 0xaa6b, 0xaa7d, + 0xaa72, 0xccf2, 0xcf75, 0xaa78, 0xaa7c, 0xcd41, 0xcd46, 0xaa7e, + 0xaa77, 0xaa69, 0xaa5f, 0xaa64, 0xccf6, 0xaa60, 0xcd4e, 0xccf0, + 0xccef, 0xccfd, 0xccf1, 0xaa7b, 0xaef5, 0xaa74, 0xccfe, 0xaa61, + 0xaca6, 0xcd4c, 0xcf7c, 0xcfa1, 0xcfa4, 0xcf77, 0xcfa7, 0xcfaa, + 0xcfac, 0xcf74, 0xac76, 0xac7b, 0xd249, 0xacad, 0xcfa5, 0xcfad, + 0xcf7b, 0xcf73, 0xd264, 0xac7e, 0xcfa2, 0xcf78, 0xcf7a, 0xaca5, + 0xcf7d, 0xac7d, 0xcf70, 0xcfa8, 0xcfab, 0xac7a, 0xaca8, 0xcf6d, + 0xacaa, 0xac78, 0xacae, 0xcfa9, 0xcf6f, 0xacab, 0xd25e, 0xcd48, + 0xac7c, 0xac77, 0xcf76, 0xcf6e, 0xacac, 0xaca4, 0xcfa3, 0xaca9, + 0xaca7, 0xcf79, 0xaca1, 0xcf71, 0xaca2, 0xaca3, 0xcf72, 0xcfa6, + 0xac79, 0xcf7e, 0xd24c, 0xaefd, 0xaf43, 0xd255, 0xd25b, 0xd257, + 0xd24a, 0xd24d, 0xd246, 0xd247, 0xaf4a, 0xaefa, 0xd256, 0xd25f, + 0xaf45, 0xaef6, 0xaf40, 0xd24e, 0xaf42, 0xd24f, 0xd259, 0xaf44, + 0xd268, 0xd248, 0xaefc, 0xaefb, 0xaf48, 0xd245, 0xd266, 0xd25a, + 0xd267, 0xd261, 0xd253, 0xd262, 0xd25c, 0xd265, 0xd263, 0xaf49, + 0xd254, 0xaef9, 0xaef8, 0xaf41, 0xaf47, 0xd260, 0xaf46, 0xd251, + 0xb243, 0xd269, 0xd250, 0xd24b, 0xaefe, 0xaf4b, 0xaef7, 0xd258, + 0xd25d, 0xb265, 0xd5e1, 0xd5e5, 0xb252, 0xb250, 0xb247, 0xd5e3, + 0xd5e2, 0xb25b, 0xd5e8, 0xb255, 0xd5fa, 0xd647, 0xb244, 0xd5f7, + 0xd5f0, 0xb267, 0xd5e0, 0xd5fc, 0xb264, 0xb258, 0xb263, 0xb24e, + 0xd5ec, 0xd5fe, 0xd5f6, 0xb24f, 0xb249, 0xd645, 0xd5fd, 0xd640, + 0xb251, 0xb259, 0xd642, 0xd5ea, 0xd5fb, 0xd5ef, 0xd644, 0xb25e, + 0xb246, 0xb25c, 0xd5f4, 0xd5f2, 0xd5f3, 0xb253, 0xd5ee, 0xd5ed, + 0xb248, 0xd5e7, 0xd646, 0xb24a, 0xd5f1, 0xb268, 0xb262, 0xd5e6, + 0xb25f, 0xb25d, 0xb266, 0xd5f8, 0xb261, 0xd252, 0xd5f9, 0xb260, + 0xd641, 0xb245, 0xd5f5, 0xb257, 0xd5e9, 0xb256, 0xb254, 0xb24c, + 0xb24b, 0xd9e7, 0xd643, 0xd5eb, 0xd9fc, 0xb24d, 0xb541, 0xb25a, + 0xb4ee, 0xd9f6, 0xb4fc, 0xd9ea, 0xb4eb, 0xb4e7, 0xda49, 0xb4ed, + 0xb4f1, 0xb4ec, 0xb4f5, 0xda4d, 0xda44, 0xd9f1, 0xb4fa, 0xb4f4, + 0xd9fd, 0xb4e4, 0xda4a, 0xda43, 0xb4e8, 0xd9f7, 0xb4f7, 0xda55, + 0xda56, 0xb4e5, 0xda48, 0xb4f9, 0xd9fb, 0xd9ed, 0xd9ee, 0xb4fd, + 0xd9f2, 0xd9f9, 0xd9f3, 0xb4fb, 0xb544, 0xd9ef, 0xd9e8, 0xd9e9, + 0xd9eb, 0xb4ea, 0xd9f8, 0xb4f8, 0xb542, 0xd9fa, 0xda53, 0xda4b, + 0xb4e6, 0xda51, 0xb4f2, 0xb4f0, 0xda57, 0xb4ef, 0xda41, 0xd9f4, + 0xd9fe, 0xb547, 0xda45, 0xda42, 0xd9f0, 0xb543, 0xda4f, 0xda4c, + 0xda54, 0xb4e9, 0xda40, 0xb546, 0xda47, 0xb4f3, 0xb4f6, 0xda46, + 0xb545, 0xd9f5, 0xd5e4, 0xda50, 0xda4e, 0xda52, 0xd9ec, 0xb540, + 0xde61, 0xde60, 0xde46, 0xb7bd, 0xde5f, 0xde49, 0xde4a, 0xb7c7, + 0xde68, 0xb7c2, 0xde5e, 0xde43, 0xb7c8, 0xb7be, 0xde52, 0xde48, + 0xde4b, 0xde63, 0xb7b8, 0xde6a, 0xde62, 0xb7c1, 0xde57, 0xb7cc, + 0xb7cb, 0xb7c5, 0xde69, 0xb7b9, 0xde55, 0xde4c, 0xde59, 0xde65, + 0xb7cd, 0xb7bb, 0xde54, 0xde4d, 0xb7c4, 0xb7c3, 0xde50, 0xde5a, + 0xde64, 0xde47, 0xde51, 0xb7bc, 0xde5b, 0xb7c9, 0xb7c0, 0xde4e, + 0xb7bf, 0xde45, 0xde53, 0xde67, 0xb4fe, 0xbab0, 0xde56, 0xe26c, + 0xde58, 0xde66, 0xb7c6, 0xde4f, 0xb7ba, 0xb7ca, 0xbcf0, 0xde44, + 0xde5d, 0xde5c, 0xe2aa, 0xbaad, 0xe27d, 0xe2a4, 0xbaa2, 0xe26e, + 0xbaaf, 0xba77, 0xe26d, 0xe2b0, 0xbab1, 0xe271, 0xe2a3, 0xe273, + 0xe2b3, 0xe2af, 0xba75, 0xbaa1, 0xe653, 0xbaae, 0xba7d, 0xe26f, + 0xe2ae, 0xbaa3, 0xe2ab, 0xe2b8, 0xe275, 0xe27e, 0xe2b6, 0xe2ac, + 0xba7c, 0xe27c, 0xba76, 0xba74, 0xbaa8, 0xe27a, 0xe277, 0xe278, + 0xe2b2, 0xe2b7, 0xe2b5, 0xba7a, 0xe2b9, 0xba7e, 0xbaa7, 0xe270, + 0xe5fa, 0xe279, 0xba78, 0xbaac, 0xbaa9, 0xba7b, 0xe2a5, 0xe274, + 0xbaaa, 0xe2a7, 0xbaa4, 0xbaa6, 0xba73, 0xe2a9, 0xe2a1, 0xe272, + 0xbaa5, 0xe2b1, 0xe2b4, 0xe27b, 0xe2a8, 0xba79, 0xbcdf, 0xe2a6, + 0xe5f9, 0xe2ad, 0xe276, 0xe644, 0xe64e, 0xbce2, 0xe64d, 0xe659, + 0xbce4, 0xe64b, 0xe64f, 0xbcef, 0xe646, 0xbce7, 0xe652, 0xe9f0, + 0xbcf3, 0xbcf2, 0xe654, 0xe643, 0xe65e, 0xbced, 0xbce3, 0xe657, + 0xe65b, 0xe660, 0xe655, 0xe649, 0xbce6, 0xbce9, 0xbcf1, 0xbcec, + 0xe64c, 0xe2a2, 0xe648, 0xe65f, 0xbce8, 0xbceb, 0xe661, 0xbce0, + 0xe656, 0xe5fb, 0xe65c, 0xc0df, 0xe64a, 0xbce1, 0xe645, 0xbce5, + 0xe5fc, 0xbaab, 0xe641, 0xe65a, 0xe642, 0xe640, 0xbcea, 0xe658, + 0xe5fe, 0xe651, 0xe650, 0xe65d, 0xe647, 0xbcee, 0xe9f3, 0xbf49, + 0xbefe, 0xea40, 0xe9eb, 0xbf41, 0xe9f7, 0xbf48, 0xbf43, 0xe9f5, + 0xed4f, 0xe9fb, 0xea42, 0xe9fa, 0xe9e9, 0xe9f8, 0xea44, 0xea46, + 0xbefd, 0xea45, 0xbf44, 0xbf4a, 0xbf47, 0xe9fe, 0xbf46, 0xe9f9, + 0xe9ed, 0xe9f2, 0xe9fd, 0xbf45, 0xbf42, 0xbefc, 0xbf40, 0xe9f1, + 0xe5fd, 0xe9ec, 0xe9ef, 0xea41, 0xe9f4, 0xe9ea, 0xed4e, 0xea43, + 0xe9ee, 0xe9fc, 0xed51, 0xc0e3, 0xc0d7, 0xc0db, 0xed53, 0xed59, + 0xed57, 0xc0d9, 0xc0da, 0xc0e1, 0xed5a, 0xed52, 0xc0dc, 0xed56, + 0xed55, 0xed5b, 0xc0e2, 0xc0dd, 0xc0e0, 0xed54, 0xc0e4, 0xc0de, + 0xc0e5, 0xc0d8, 0xed58, 0xed50, 0xeff7, 0xc271, 0xeff4, 0xeff6, + 0xc26f, 0xeff2, 0xeff3, 0xefee, 0xe9f6, 0xefef, 0xc270, 0xefeb, + 0xc26d, 0xeff8, 0xc26e, 0xefec, 0xefed, 0xeff1, 0xc273, 0xc272, + 0xeff0, 0xc378, 0xf25f, 0xf265, 0xc379, 0xf25c, 0xc376, 0xc373, + 0xf267, 0xc377, 0xc374, 0xf25e, 0xf261, 0xf262, 0xf263, 0xf266, + 0xeff5, 0xf25d, 0xc375, 0xf264, 0xf268, 0xf260, 0xf45d, 0xc46a, + 0xf460, 0xc46b, 0xf468, 0xf45f, 0xf45c, 0xf45e, 0xf462, 0xf465, + 0xf464, 0xf467, 0xf45b, 0xc469, 0xf463, 0xf466, 0xf469, 0xf461, + 0xf5d3, 0xf5d4, 0xf5d8, 0xf5d9, 0xf5d6, 0xf5d7, 0xf5d5, 0xc4e9, + 0xc578, 0xf6eb, 0xf6e8, 0xf6e9, 0xf6ea, 0xc579, 0xf7e5, 0xf7e4, + 0xf8af, 0xc5f4, 0xf8ad, 0xf8b0, 0xf8ae, 0xf8f5, 0xc657, 0xc665, + 0xf9a3, 0xf96c, 0xf9a2, 0xf9d0, 0xf9d1, 0xa4f5, 0xa6c7, 0xca41, + 0xcb5e, 0xa85f, 0xa862, 0xcb5f, 0xa860, 0xa861, 0xcd58, 0xcd5a, + 0xcd55, 0xcd52, 0xcd54, 0xaaa4, 0xaaa2, 0xcd56, 0xaaa3, 0xcd53, + 0xcd50, 0xaaa1, 0xcd57, 0xcd51, 0xaaa5, 0xcd59, 0xcfaf, 0xcfb3, + 0xacb7, 0xcfb6, 0xacaf, 0xacb2, 0xacb4, 0xacb6, 0xacb3, 0xcfb2, + 0xcfb1, 0xacb1, 0xcfb4, 0xcfb5, 0xcfae, 0xacb5, 0xacb0, 0xcfb0, + 0xd277, 0xd278, 0xd279, 0xaf50, 0xaf4c, 0xd26e, 0xd276, 0xd27b, + 0xaf51, 0xd26c, 0xd272, 0xd26b, 0xd275, 0xd271, 0xaf4d, 0xaf4f, + 0xd27a, 0xd26a, 0xd26d, 0xd273, 0xd274, 0xd27c, 0xd270, 0xaf4e, + 0xb26d, 0xd64e, 0xd650, 0xd64c, 0xd658, 0xd64a, 0xd657, 0xb269, + 0xd648, 0xda5b, 0xd652, 0xb26c, 0xd653, 0xd656, 0xd65a, 0xd64f, + 0xd654, 0xb26a, 0xb26b, 0xd659, 0xd64d, 0xd649, 0xd65b, 0xd651, + 0xd655, 0xd64b, 0xb548, 0xb549, 0xda65, 0xb54f, 0xda59, 0xda62, + 0xda58, 0xb54c, 0xda60, 0xda5e, 0xda5f, 0xb54a, 0xda63, 0xda5c, + 0xda5a, 0xb54b, 0xda5d, 0xda61, 0xb54d, 0xda64, 0xde70, 0xde77, + 0xde79, 0xdea1, 0xb7da, 0xde6b, 0xb7d2, 0xde7a, 0xb7d7, 0xdea2, + 0xb7ce, 0xde7d, 0xde6d, 0xde7e, 0xde6c, 0xb7dc, 0xde78, 0xb7cf, + 0xdea3, 0xb7d4, 0xde71, 0xb7d9, 0xde7c, 0xde6f, 0xde76, 0xde72, + 0xde6e, 0xb7d1, 0xb7d8, 0xb7d6, 0xb7d3, 0xb7db, 0xb7d0, 0xde75, + 0xb7d5, 0xb54e, 0xde7b, 0xde73, 0xde74, 0xe2c1, 0xbab4, 0xe2bd, + 0xe2c3, 0xe2bf, 0xbab6, 0xe2be, 0xe2c2, 0xe2ba, 0xe2bc, 0xbab5, + 0xe2c0, 0xe2bb, 0xbab7, 0xbab2, 0xe2c4, 0xbab3, 0xe667, 0xe664, + 0xe670, 0xe66a, 0xe66c, 0xbcf4, 0xe666, 0xe66e, 0xe66d, 0xe66b, + 0xe671, 0xbcf7, 0xe668, 0xe66f, 0xbcf5, 0xe663, 0xe665, 0xbcf6, + 0xe662, 0xe672, 0xe669, 0xea4a, 0xbf51, 0xea55, 0xea53, 0xbf4b, + 0xea49, 0xea4c, 0xea4d, 0xea48, 0xbf55, 0xbf56, 0xea47, 0xea56, + 0xea51, 0xbf4f, 0xbf4c, 0xea50, 0xea4e, 0xbf52, 0xea52, 0xbf4d, + 0xbf4e, 0xea4f, 0xbf50, 0xea4b, 0xea54, 0xbf53, 0xea57, 0xea58, + 0xbf54, 0xc0e7, 0xc0ee, 0xed5c, 0xed62, 0xed60, 0xc0ea, 0xc0e9, + 0xc0e6, 0xed5e, 0xc0ec, 0xc0eb, 0xc0e8, 0xed61, 0xed5d, 0xed5f, + 0xc0ed, 0xc277, 0xeffb, 0xc274, 0xc275, 0xeffd, 0xc276, 0xeffa, + 0xeff9, 0xf26c, 0xeffc, 0xf26d, 0xc37a, 0xf26b, 0xf26a, 0xf269, + 0xc37b, 0xc46c, 0xf46a, 0xf46b, 0xf5dc, 0xf5db, 0xc4ea, 0xf5da, + 0xf6ec, 0xf6ed, 0xf7e6, 0xf8b1, 0xf8f6, 0xf9bc, 0xc679, 0xf9c6, + 0xa4f6, 0xaaa6, 0xaaa7, 0xacb8, 0xc0ef, 0xa4f7, 0xaaa8, 0xaf52, + 0xb7dd, 0xa4f8, 0xb26e, 0xbab8, 0xc962, 0xcfb7, 0xd27d, 0xe2c5, + 0xc0f0, 0xa4f9, 0xaaa9, 0xcfb8, 0xcfb9, 0xda66, 0xb550, 0xdea4, + 0xb7de, 0xe2c6, 0xbcf8, 0xc37c, 0xa4fa, 0xda67, 0xa4fb, 0xa6c9, + 0xca42, 0xa6c8, 0xa865, 0xa864, 0xa863, 0xcb60, 0xaaaa, 0xaaab, + 0xcd5b, 0xcfba, 0xcfbd, 0xacba, 0xcfbb, 0xacb9, 0xcfbc, 0xacbb, + 0xd2a2, 0xd2a1, 0xd27e, 0xaf53, 0xd65d, 0xd65e, 0xb26f, 0xd65c, + 0xd65f, 0xb552, 0xb270, 0xb551, 0xda6b, 0xda6a, 0xda68, 0xda69, + 0xda6c, 0xdea6, 0xdea5, 0xdea9, 0xdea8, 0xdea7, 0xbab9, 0xe2c9, + 0xe2c8, 0xbaba, 0xe2c7, 0xe673, 0xe674, 0xbcf9, 0xea59, 0xea5a, + 0xf272, 0xc37d, 0xf271, 0xf270, 0xf26e, 0xf26f, 0xc4eb, 0xf46c, + 0xf6ee, 0xf8f7, 0xa4fc, 0xc9a5, 0xa5c7, 0xc9a6, 0xca43, 0xca44, + 0xcb66, 0xcb62, 0xcb61, 0xaaac, 0xcb65, 0xa867, 0xcb63, 0xa866, + 0xcb67, 0xcb64, 0xcd5f, 0xcfbe, 0xcd5d, 0xcd64, 0xaaad, 0xaab0, + 0xcd65, 0xcd61, 0xcd62, 0xcd5c, 0xaaaf, 0xcd5e, 0xaaae, 0xcd63, + 0xcd60, 0xcfc2, 0xacbd, 0xacbe, 0xcfc5, 0xcfbf, 0xcfc4, 0xcfc0, + 0xacbc, 0xcfc3, 0xcfc1, 0xd2a8, 0xd2a5, 0xd2a7, 0xaf58, 0xaf57, + 0xaf55, 0xd2a4, 0xd2a9, 0xaf54, 0xaf56, 0xd2a6, 0xd667, 0xd2a3, + 0xd2aa, 0xd662, 0xd666, 0xd665, 0xda6e, 0xda79, 0xd668, 0xd663, + 0xda6d, 0xb274, 0xb273, 0xd661, 0xd664, 0xb275, 0xb272, 0xb271, + 0xd660, 0xd669, 0xda70, 0xda77, 0xb554, 0xda76, 0xda73, 0xb556, + 0xda75, 0xda6f, 0xda71, 0xda74, 0xda72, 0xb555, 0xda78, 0xb553, + 0xb7df, 0xdead, 0xdeac, 0xdeaa, 0xb7e2, 0xb7e1, 0xdeae, 0xdeab, + 0xe2ca, 0xbabb, 0xb7e0, 0xdeb0, 0xdeaf, 0xe2cd, 0xe2cb, 0xbcfa, + 0xbabc, 0xe2cc, 0xe676, 0xbcfb, 0xe675, 0xe67e, 0xe67d, 0xe67b, + 0xe67a, 0xe677, 0xe678, 0xe679, 0xe67c, 0xe6a1, 0xea5f, 0xea5c, + 0xea5d, 0xbf57, 0xea5b, 0xea61, 0xea60, 0xea5e, 0xed64, 0xed65, + 0xc0f1, 0xc0f2, 0xed63, 0xc279, 0xeffe, 0xc278, 0xc37e, 0xc3a1, + 0xc46d, 0xf46e, 0xf46d, 0xf5dd, 0xf6ef, 0xc57a, 0xf7e8, 0xf7e7, + 0xf7e9, 0xa5c8, 0xcfc6, 0xaf59, 0xb276, 0xd66a, 0xa5c9, 0xc9a7, + 0xa4fd, 0xca45, 0xcb6c, 0xcb6a, 0xcb6b, 0xcb68, 0xa868, 0xcb69, + 0xcd6d, 0xaab3, 0xcd6b, 0xcd67, 0xcd6a, 0xcd66, 0xaab5, 0xcd69, + 0xaab2, 0xaab1, 0xaab4, 0xcd6c, 0xcd68, 0xacc2, 0xacc5, 0xcfce, + 0xcfcd, 0xcfcc, 0xacbf, 0xcfd5, 0xcfcb, 0xacc1, 0xd2af, 0xcfd2, + 0xcfd0, 0xacc4, 0xcfc8, 0xcfd3, 0xcfca, 0xcfd4, 0xcfd1, 0xcfc9, + 0xacc0, 0xcfd6, 0xcfc7, 0xacc3, 0xd2b4, 0xd2ab, 0xd2b6, 0xd2ae, + 0xd2b9, 0xd2ba, 0xd2ac, 0xd2b8, 0xd2b5, 0xd2b3, 0xd2b7, 0xaf5f, + 0xaf5d, 0xd2b1, 0xd2ad, 0xd2b0, 0xd2bb, 0xd2b2, 0xaf5e, 0xcfcf, + 0xaf5a, 0xaf5c, 0xd678, 0xd66d, 0xd66b, 0xd66c, 0xd673, 0xd674, + 0xd670, 0xb27b, 0xd675, 0xd672, 0xd66f, 0xb279, 0xd66e, 0xb277, + 0xb27a, 0xd671, 0xd679, 0xaf5b, 0xb278, 0xd677, 0xd676, 0xb27c, + 0xda7e, 0xdaa1, 0xb560, 0xdaa7, 0xdaa9, 0xdaa2, 0xb55a, 0xdaa6, + 0xdaa5, 0xb55b, 0xb561, 0xb562, 0xdaa8, 0xb558, 0xda7d, 0xda7b, + 0xdaa3, 0xda7a, 0xb55f, 0xda7c, 0xdaa4, 0xdaaa, 0xb559, 0xb55e, + 0xb55c, 0xb55d, 0xb557, 0xb7e9, 0xdeb7, 0xb7e8, 0xdebb, 0xdeb1, + 0xdebc, 0xdeb2, 0xdeb3, 0xdebd, 0xdeba, 0xdeb8, 0xdeb9, 0xdeb5, + 0xdeb4, 0xdebe, 0xb7e5, 0xdeb6, 0xb7ea, 0xb7e4, 0xb7eb, 0xb7ec, + 0xb7e7, 0xb7e6, 0xe2ce, 0xbabe, 0xbabd, 0xe2d3, 0xbcfc, 0xbabf, + 0xbac1, 0xe2d4, 0xb7e3, 0xbac0, 0xe2d0, 0xe2d2, 0xe2cf, 0xe2d1, + 0xe6ab, 0xe6aa, 0xe6a7, 0xbd40, 0xea62, 0xbd41, 0xe6a6, 0xbcfe, + 0xe6a8, 0xe6a5, 0xe6a2, 0xe6a9, 0xe6a3, 0xe6a4, 0xbcfd, 0xed69, + 0xea66, 0xea65, 0xea67, 0xed66, 0xbf5a, 0xea63, 0xbf58, 0xbf5c, + 0xbf5b, 0xea64, 0xea68, 0xbf59, 0xed6d, 0xc0f5, 0xc27a, 0xc0f6, + 0xc0f3, 0xed6a, 0xed68, 0xed6b, 0xed6e, 0xc0f4, 0xed6c, 0xed67, + 0xf042, 0xf045, 0xf275, 0xf040, 0xf46f, 0xf046, 0xc3a2, 0xf044, + 0xc27b, 0xf041, 0xf043, 0xf047, 0xf276, 0xf274, 0xc3a3, 0xf273, + 0xc46e, 0xc4ed, 0xf6f1, 0xc4ec, 0xf6f3, 0xf6f0, 0xf6f2, 0xc5d0, + 0xf8b2, 0xa5ca, 0xcd6e, 0xd2bc, 0xd2bd, 0xb27d, 0xdebf, 0xbf5d, + 0xc3a4, 0xc57b, 0xf8b3, 0xa5cb, 0xcd6f, 0xa260, 0xcfd7, 0xcfd8, + 0xd2be, 0xd2bf, 0xb27e, 0xb2a1, 0xdaab, 0xdec2, 0xdec1, 0xdec0, + 0xe2d5, 0xe2d6, 0xe2d7, 0xbac2, 0xe6ad, 0xe6ac, 0xea69, 0xbf5e, + 0xbf5f, 0xed72, 0xed6f, 0xed70, 0xed71, 0xf049, 0xf048, 0xc27c, + 0xf277, 0xf5de, 0xa5cc, 0xacc6, 0xb2a2, 0xdec3, 0xa5cd, 0xd2c0, + 0xb2a3, 0xb563, 0xb564, 0xa5ce, 0xa5cf, 0xca46, 0xa86a, 0xa869, + 0xacc7, 0xcfd9, 0xdaac, 0xa5d0, 0xa5d1, 0xa5d2, 0xa5d3, 0xa86b, + 0xa86c, 0xcb6e, 0xcb6d, 0xaab6, 0xcd72, 0xcd70, 0xcd71, 0xcfda, + 0xcfdb, 0xaccb, 0xacc9, 0xacca, 0xacc8, 0xaf60, 0xaf64, 0xaf63, + 0xd2c1, 0xaf62, 0xaf61, 0xd2c2, 0xb2a6, 0xd67b, 0xd67a, 0xb2a4, + 0xb2a5, 0xb566, 0xb565, 0xdaae, 0xdaad, 0xb2a7, 0xb7ed, 0xdec5, + 0xb7ee, 0xdec4, 0xe2d8, 0xe6ae, 0xbd42, 0xea6a, 0xed73, 0xc3a6, + 0xc3a5, 0xc57c, 0xa5d4, 0xcd73, 0xb2a8, 0xe2d9, 0xbac3, 0xcb6f, + 0xcb70, 0xcd74, 0xaab8, 0xaab9, 0xaab7, 0xaccf, 0xacd0, 0xaccd, + 0xacce, 0xcfdc, 0xcfdd, 0xaccc, 0xd2c3, 0xaf68, 0xaf69, 0xb2ab, + 0xd2c9, 0xaf6e, 0xaf6c, 0xd2ca, 0xd2c5, 0xaf6b, 0xaf6a, 0xaf65, + 0xd2c8, 0xd2c7, 0xd2c4, 0xaf6d, 0xd2c6, 0xaf66, 0xaf67, 0xb2ac, + 0xd6a1, 0xd6a2, 0xb2ad, 0xd67c, 0xd67e, 0xd6a4, 0xd6a3, 0xd67d, + 0xb2a9, 0xb2aa, 0xdab6, 0xb56b, 0xb56a, 0xdab0, 0xb568, 0xdab3, + 0xb56c, 0xdab4, 0xb56d, 0xdab1, 0xb567, 0xb569, 0xdab5, 0xdab2, + 0xdaaf, 0xded2, 0xdec7, 0xb7f0, 0xb7f3, 0xb7f2, 0xb7f7, 0xb7f6, + 0xded3, 0xded1, 0xdeca, 0xdece, 0xdecd, 0xb7f4, 0xded0, 0xdecc, + 0xded4, 0xdecb, 0xb7f5, 0xb7ef, 0xb7f1, 0xdec9, 0xe2db, 0xbac7, + 0xe2df, 0xbac6, 0xe2dc, 0xbac5, 0xdec8, 0xdecf, 0xe2de, 0xbac8, + 0xe2e0, 0xe2dd, 0xe2da, 0xe6b1, 0xe6b5, 0xe6b7, 0xe6b3, 0xe6b2, + 0xe6b0, 0xbd45, 0xbd43, 0xbd48, 0xbd49, 0xe6b4, 0xbd46, 0xe6af, + 0xbd47, 0xbac4, 0xe6b6, 0xbd44, 0xea6c, 0xea6b, 0xea73, 0xea6d, + 0xea72, 0xea6f, 0xbf60, 0xea71, 0xbf61, 0xbf62, 0xea70, 0xea6e, + 0xc0f8, 0xed74, 0xc0f7, 0xed77, 0xed75, 0xed76, 0xc0f9, 0xf04d, + 0xc2a1, 0xf04e, 0xc27d, 0xf04f, 0xc27e, 0xf04c, 0xf050, 0xf04a, + 0xc3a7, 0xf278, 0xc3a8, 0xc46f, 0xf04b, 0xc470, 0xc4ee, 0xf5df, + 0xc57e, 0xf6f4, 0xc57d, 0xf7ea, 0xc5f5, 0xc5f6, 0xf9cc, 0xacd1, + 0xcfde, 0xb56e, 0xb56f, 0xa5d5, 0xa6ca, 0xca47, 0xcb71, 0xa86d, + 0xaaba, 0xacd2, 0xacd3, 0xacd4, 0xd6a6, 0xd2cb, 0xaf6f, 0xb2ae, + 0xd6a5, 0xdab8, 0xb571, 0xdab7, 0xb570, 0xded5, 0xbd4a, 0xe6bb, + 0xe6b8, 0xe6b9, 0xe6ba, 0xed78, 0xf051, 0xf471, 0xf470, 0xf6f5, + 0xa5d6, 0xcd75, 0xaf70, 0xb572, 0xded6, 0xe2e1, 0xbd4b, 0xea74, + 0xf052, 0xf472, 0xa5d7, 0xaabb, 0xacd7, 0xcfdf, 0xacd8, 0xacd6, + 0xacd5, 0xd2cc, 0xaf71, 0xaf72, 0xaf73, 0xb2b0, 0xd6a7, 0xb2af, + 0xdab9, 0xb2b1, 0xb573, 0xded7, 0xb7f8, 0xb7f9, 0xbac9, 0xbaca, + 0xbd4c, 0xbf64, 0xea75, 0xbf63, 0xed79, 0xc0fa, 0xf053, 0xf473, + 0xa5d8, 0xa86e, 0xcd78, 0xcd77, 0xaabc, 0xcd76, 0xaabd, 0xcd79, + 0xcfe5, 0xacdb, 0xacda, 0xcfe7, 0xcfe6, 0xacdf, 0xacde, 0xacd9, + 0xcfe1, 0xcfe2, 0xcfe3, 0xace0, 0xcfe0, 0xacdc, 0xcfe4, 0xacdd, + 0xd2cf, 0xd2d3, 0xd2d1, 0xd2d0, 0xd2d4, 0xd2d5, 0xd2d6, 0xd2ce, + 0xd2cd, 0xaf75, 0xaf76, 0xd2d7, 0xd2d2, 0xd6b0, 0xd2d8, 0xaf77, + 0xaf74, 0xd6aa, 0xd6a9, 0xd6ab, 0xd6ac, 0xd6ae, 0xd6ad, 0xd6b2, + 0xb2b5, 0xb2b2, 0xb2b6, 0xd6a8, 0xb2b7, 0xd6b1, 0xb2b4, 0xd6af, + 0xb2b3, 0xdabc, 0xdabe, 0xdaba, 0xdabb, 0xdabf, 0xdac1, 0xdac2, + 0xdabd, 0xdac0, 0xb574, 0xdedb, 0xdee0, 0xded8, 0xdedc, 0xdee1, + 0xdedd, 0xb7fa, 0xb843, 0xb7fd, 0xded9, 0xdeda, 0xbace, 0xb846, + 0xb7fe, 0xb844, 0xb7fc, 0xdedf, 0xb845, 0xdede, 0xb841, 0xb7fb, + 0xb842, 0xdee2, 0xe2e6, 0xe2e8, 0xb840, 0xe2e3, 0xbacc, 0xe2e9, + 0xbacd, 0xe2e7, 0xe2e2, 0xe2e5, 0xe2ea, 0xbacb, 0xe2e4, 0xbd4e, + 0xe6bf, 0xe6be, 0xbd51, 0xbd4f, 0xe6bc, 0xbd4d, 0xe6bd, 0xbd50, + 0xea7d, 0xeaa1, 0xea7e, 0xea76, 0xea7a, 0xea79, 0xea77, 0xbf66, + 0xbf67, 0xbf65, 0xea78, 0xea7b, 0xea7c, 0xbf68, 0xc140, 0xeda3, + 0xc0fc, 0xed7b, 0xc0fe, 0xc141, 0xc0fd, 0xeda2, 0xed7c, 0xc0fb, + 0xeda1, 0xed7a, 0xed7e, 0xed7d, 0xf055, 0xc2a4, 0xc2a5, 0xc2a2, + 0xc2a3, 0xf054, 0xf27b, 0xc3a9, 0xf279, 0xf27a, 0xf474, 0xf477, + 0xf475, 0xf476, 0xf5e0, 0xc4ef, 0xf7eb, 0xf8b4, 0xc5f7, 0xf8f8, + 0xf8f9, 0xc666, 0xa5d9, 0xace1, 0xdac3, 0xdee3, 0xa5da, 0xa86f, + 0xaabe, 0xcfe8, 0xcfe9, 0xaf78, 0xdac4, 0xb575, 0xb847, 0xc142, + 0xeda4, 0xf27c, 0xf478, 0xa5db, 0xcda1, 0xcd7a, 0xcd7c, 0xcd7e, + 0xcd7d, 0xcd7b, 0xaabf, 0xace2, 0xcff2, 0xcfed, 0xcfea, 0xcff1, + 0xace4, 0xace5, 0xcff0, 0xcfef, 0xcfee, 0xcfeb, 0xcfec, 0xcff3, + 0xace3, 0xaf7c, 0xafa4, 0xafa3, 0xd2e1, 0xd2db, 0xd2d9, 0xafa1, + 0xd6b9, 0xaf7a, 0xd2de, 0xd2e2, 0xd2e4, 0xd2e0, 0xd2da, 0xafa2, + 0xd2df, 0xd2dd, 0xaf79, 0xd2e5, 0xafa5, 0xd2e3, 0xaf7d, 0xd2dc, + 0xaf7e, 0xaf7b, 0xb2b9, 0xd6ba, 0xd6b3, 0xd6b5, 0xd6b7, 0xd6b8, + 0xd6b6, 0xb2ba, 0xd6bb, 0xd6b4, 0xdac8, 0xb576, 0xdad0, 0xdac5, + 0xdad1, 0xdac6, 0xdac7, 0xdacf, 0xdace, 0xdacb, 0xb2b8, 0xb577, + 0xdac9, 0xdacc, 0xb578, 0xdacd, 0xdaca, 0xdeee, 0xdef2, 0xb84e, + 0xe2f0, 0xb851, 0xdef0, 0xdeed, 0xdee8, 0xdeea, 0xdeeb, 0xdee4, + 0xb84d, 0xb84c, 0xb848, 0xdee7, 0xb84f, 0xb850, 0xdee6, 0xdee9, + 0xdef1, 0xb84a, 0xb84b, 0xdeef, 0xdee5, 0xe2f2, 0xbad0, 0xe2f4, + 0xdeec, 0xe2f6, 0xbad4, 0xe2f7, 0xe2f3, 0xbad1, 0xe2ef, 0xbad3, + 0xe2ec, 0xe2f1, 0xe2f5, 0xe2ee, 0xb849, 0xe2eb, 0xbad2, 0xe2ed, + 0xbd54, 0xe6c1, 0xbd58, 0xbd56, 0xbacf, 0xe6c8, 0xe6c9, 0xbd53, + 0xe6c7, 0xe6ca, 0xbd55, 0xbd52, 0xe6c3, 0xe6c0, 0xe6c5, 0xe6c2, + 0xbd59, 0xe6c4, 0xe6c6, 0xbd57, 0xbf6a, 0xeaa8, 0xeaa2, 0xeaa6, + 0xeaac, 0xeaad, 0xeaa9, 0xeaaa, 0xeaa7, 0xeaa4, 0xbf6c, 0xbf69, + 0xeaa3, 0xeaa5, 0xbf6b, 0xeaab, 0xc146, 0xedaa, 0xeda5, 0xc145, + 0xc143, 0xedac, 0xc144, 0xeda8, 0xeda9, 0xeda6, 0xedad, 0xf056, + 0xc147, 0xeda7, 0xedae, 0xedab, 0xf05a, 0xf057, 0xc2a6, 0xf05b, + 0xf05d, 0xf05c, 0xf058, 0xf059, 0xf2a3, 0xc3aa, 0xf27e, 0xf2a2, + 0xf27d, 0xf2a4, 0xf2a1, 0xf47a, 0xf47d, 0xf479, 0xc471, 0xf47b, + 0xf47c, 0xf47e, 0xc472, 0xc474, 0xc473, 0xf5e1, 0xf5e3, 0xf5e2, + 0xf6f6, 0xf8b5, 0xf8fa, 0xa5dc, 0xcb72, 0xaac0, 0xcda3, 0xaac1, + 0xaac2, 0xcda2, 0xcff8, 0xcff7, 0xace6, 0xace9, 0xace8, 0xace7, + 0xcff4, 0xcff6, 0xcff5, 0xd2e8, 0xafa7, 0xd2ec, 0xd2eb, 0xd2ea, + 0xd2e6, 0xafa6, 0xafaa, 0xafad, 0xafae, 0xd2e7, 0xd2e9, 0xafac, + 0xafab, 0xafa9, 0xafa8, 0xd6c2, 0xd6c0, 0xd6bc, 0xb2bb, 0xd6bd, + 0xb2bc, 0xd6be, 0xd6bf, 0xd6c1, 0xb2bd, 0xdad5, 0xdad4, 0xdad3, + 0xdad2, 0xdef6, 0xb852, 0xdef3, 0xdef5, 0xb853, 0xb854, 0xdef4, + 0xe341, 0xe2f9, 0xe2fa, 0xbad7, 0xbad5, 0xbad6, 0xe343, 0xe342, + 0xe2fe, 0xe2fd, 0xe2fc, 0xe2fb, 0xe340, 0xe2f8, 0xe6cb, 0xe6d0, + 0xe6ce, 0xe6cd, 0xe6cc, 0xe6cf, 0xeaae, 0xbf6d, 0xc148, 0xedb0, + 0xc149, 0xedaf, 0xf05f, 0xf05e, 0xc2a7, 0xf2a5, 0xc3ab, 0xf4a1, + 0xc5a1, 0xf6f7, 0xf8b7, 0xf8b6, 0xc9a8, 0xacea, 0xaceb, 0xd6c3, + 0xb856, 0xa5dd, 0xa872, 0xa871, 0xa870, 0xcda4, 0xaac4, 0xaac3, + 0xacee, 0xcffa, 0xcffd, 0xcffb, 0xacec, 0xaced, 0xcff9, 0xcffc, + 0xafb5, 0xd2f3, 0xd2f5, 0xd2f4, 0xafb2, 0xd2ef, 0xafb0, 0xafaf, + 0xafb3, 0xafb1, 0xafb4, 0xd2f2, 0xd2ed, 0xd2ee, 0xd2f1, 0xd2f0, + 0xd6c6, 0xd6c7, 0xd6c5, 0xd6c4, 0xb2be, 0xb57d, 0xdad6, 0xdad8, + 0xdada, 0xb57c, 0xb57a, 0xdad7, 0xb57b, 0xdad9, 0xb579, 0xdf41, + 0xdef7, 0xdefa, 0xdefe, 0xb85a, 0xdefc, 0xdefb, 0xdef8, 0xdef9, + 0xb858, 0xdf40, 0xb857, 0xb85c, 0xb85b, 0xb859, 0xdefd, 0xe349, + 0xe348, 0xe344, 0xbad8, 0xe347, 0xe346, 0xbad9, 0xbd5e, 0xe6d2, + 0xbd5f, 0xbd5b, 0xbd5d, 0xbd5a, 0xbd5c, 0xeaaf, 0xbf70, 0xeab1, + 0xeab0, 0xe345, 0xbf72, 0xbf71, 0xbf6e, 0xbf6f, 0xedb5, 0xedb3, + 0xc14a, 0xedb4, 0xedb6, 0xedb2, 0xedb1, 0xf060, 0xc2aa, 0xc2a8, + 0xc2a9, 0xf2a6, 0xf2a7, 0xc3ad, 0xc3ac, 0xf4a3, 0xf4a4, 0xf4a2, + 0xf6f8, 0xf6f9, 0xa5de, 0xca48, 0xa873, 0xcda5, 0xaac6, 0xaac5, + 0xcda6, 0xd040, 0xacef, 0xcffe, 0xacf0, 0xafb6, 0xd2f8, 0xd2f6, + 0xd2fc, 0xafb7, 0xd2f7, 0xd2fb, 0xd2f9, 0xd2fa, 0xd6c8, 0xd6ca, + 0xb2bf, 0xd6c9, 0xb2c0, 0xb5a2, 0xb5a1, 0xb57e, 0xdadb, 0xdf44, + 0xb85d, 0xb85e, 0xdf43, 0xdf42, 0xe34a, 0xbadb, 0xbada, 0xe34b, + 0xe34c, 0xbd61, 0xbd60, 0xeab5, 0xe6d3, 0xe6d5, 0xe6d4, 0xeab4, + 0xeab2, 0xeab6, 0xeab3, 0xbf73, 0xedb7, 0xc14b, 0xedb8, 0xedb9, + 0xc2ab, 0xc2ac, 0xc475, 0xc5d1, 0xa5df, 0xd041, 0xd2fd, 0xafb8, + 0xb3ba, 0xb3b9, 0xb5a4, 0xdadd, 0xb5a3, 0xdadc, 0xdf45, 0xbadc, + 0xe34d, 0xbadd, 0xc476, 0xf4a5, 0xa6cb, 0xaac7, 0xcda7, 0xacf2, + 0xacf1, 0xd042, 0xd043, 0xd340, 0xd342, 0xafb9, 0xd344, 0xd347, + 0xd345, 0xd346, 0xd343, 0xd2fe, 0xafba, 0xd348, 0xd341, 0xd6d3, + 0xb2c6, 0xd6dc, 0xb2c3, 0xd6d5, 0xb2c7, 0xb2c1, 0xd6d0, 0xd6dd, + 0xd6d1, 0xd6ce, 0xb2c5, 0xb2c2, 0xd6d4, 0xd6d7, 0xb2c4, 0xd6d8, + 0xb2c8, 0xd6d9, 0xd6cf, 0xd6d6, 0xd6da, 0xd6d2, 0xd6cd, 0xd6cb, + 0xd6db, 0xdadf, 0xdae4, 0xdae0, 0xdae6, 0xb5a7, 0xd6cc, 0xdae1, + 0xb5a5, 0xdade, 0xb5ac, 0xdae2, 0xb5ab, 0xdae3, 0xb5ad, 0xb5a8, + 0xb5ae, 0xb5a9, 0xb5aa, 0xb5a6, 0xdae5, 0xb861, 0xdf50, 0xdf53, + 0xdf47, 0xdf4c, 0xdf46, 0xb863, 0xdf4a, 0xdf48, 0xb862, 0xdf4f, + 0xdf4e, 0xdf4b, 0xdf4d, 0xdf49, 0xbae1, 0xdf52, 0xb85f, 0xdf51, + 0xe35d, 0xbae8, 0xe358, 0xbae7, 0xe34e, 0xe350, 0xbae0, 0xe355, + 0xe354, 0xe357, 0xbae5, 0xe352, 0xe351, 0xbae4, 0xbadf, 0xe353, + 0xbae2, 0xe359, 0xe35b, 0xe356, 0xe34f, 0xbae3, 0xbd69, 0xbade, + 0xe35c, 0xe6d9, 0xbd62, 0xe6db, 0xbd63, 0xbd65, 0xe6de, 0xe6d6, + 0xbae6, 0xe6dc, 0xe6d8, 0xb860, 0xbd68, 0xbd64, 0xbd66, 0xbd67, + 0xbf76, 0xe6dd, 0xe6d7, 0xbd6a, 0xe6da, 0xeac0, 0xeabb, 0xeac5, + 0xbf74, 0xeabd, 0xbf78, 0xeac3, 0xeaba, 0xeab7, 0xeac6, 0xc151, + 0xbf79, 0xeac2, 0xeab8, 0xbf77, 0xeabc, 0xbf7b, 0xeab9, 0xeabe, + 0xbf7a, 0xeac1, 0xeac4, 0xedcb, 0xedcc, 0xedbc, 0xedc3, 0xedc1, + 0xc14f, 0xedc8, 0xeabf, 0xedbf, 0xedc9, 0xc14e, 0xedbe, 0xedbd, + 0xedc7, 0xedc4, 0xedc6, 0xedba, 0xedca, 0xc14c, 0xedc5, 0xedce, + 0xedc2, 0xc150, 0xc14d, 0xedc0, 0xedbb, 0xedcd, 0xbf75, 0xf063, + 0xf061, 0xf067, 0xc2b0, 0xf065, 0xf064, 0xc2b2, 0xf06a, 0xc2b1, + 0xf06b, 0xf068, 0xc2ae, 0xf069, 0xf062, 0xc2af, 0xc2ad, 0xf2ab, + 0xf066, 0xf06c, 0xf2a8, 0xc3b2, 0xc3b0, 0xf2aa, 0xf2ac, 0xf2a9, + 0xc3b1, 0xc3ae, 0xc3af, 0xc3b3, 0xc478, 0xf4aa, 0xf4a9, 0xf4a7, + 0xf4a6, 0xf4a8, 0xc477, 0xc479, 0xc4f0, 0xf5e5, 0xf5e4, 0xf6fa, + 0xf6fc, 0xf6fe, 0xf6fd, 0xf6fb, 0xc5a3, 0xc5a2, 0xc5d3, 0xc5d2, + 0xc5d4, 0xf7ed, 0xf7ec, 0xf8fb, 0xf8b8, 0xf8fc, 0xc658, 0xc659, + 0xf96d, 0xc67e, 0xa6cc, 0xcda8, 0xd045, 0xd046, 0xd044, 0xacf3, + 0xd047, 0xd048, 0xd049, 0xd349, 0xd34f, 0xd34d, 0xafbb, 0xd34b, + 0xd34c, 0xd34e, 0xd34a, 0xb2c9, 0xd6de, 0xb2cb, 0xd6e0, 0xb2ca, + 0xd6df, 0xdae8, 0xb5af, 0xdaea, 0xdae7, 0xd6e1, 0xb5b0, 0xdae9, + 0xdf56, 0xb864, 0xdf54, 0xb865, 0xdf55, 0xb866, 0xbae9, 0xe361, + 0xe35e, 0xe360, 0xbaea, 0xbaeb, 0xe35f, 0xe6df, 0xe6e0, 0xbd6b, + 0xe6e2, 0xe6e1, 0xa261, 0xeaca, 0xeacb, 0xeac7, 0xeac8, 0xbf7c, + 0xbf7d, 0xeac9, 0xc157, 0xc153, 0xc158, 0xc154, 0xc156, 0xc152, + 0xc155, 0xc2b3, 0xedcf, 0xf2ae, 0xf2ad, 0xf4ab, 0xc47a, 0xc47b, + 0xf741, 0xf5e6, 0xf740, 0xf8fd, 0xf9a4, 0xa6cd, 0xa874, 0xcda9, + 0xaac8, 0xacf6, 0xd04c, 0xacf4, 0xd04a, 0xacf9, 0xacf5, 0xacfa, + 0xacf8, 0xd04b, 0xacf7, 0xafbf, 0xafbe, 0xd35a, 0xafc7, 0xd353, + 0xd359, 0xafc3, 0xd352, 0xd358, 0xd356, 0xafc2, 0xafc4, 0xd355, + 0xafbd, 0xd354, 0xafc8, 0xafc5, 0xafc9, 0xafc6, 0xd351, 0xd350, + 0xd357, 0xafc0, 0xafbc, 0xafc1, 0xd6f0, 0xd6e9, 0xb5b5, 0xd6e8, + 0xb2cf, 0xb2d6, 0xb2d3, 0xb2d9, 0xb2d8, 0xb2d4, 0xd6e2, 0xd6e5, + 0xd6e4, 0xb2d0, 0xd6e6, 0xd6ef, 0xb2d1, 0xd6e3, 0xd6ec, 0xd6ed, + 0xb2d2, 0xd6ea, 0xb2d7, 0xb2cd, 0xb2d5, 0xd6e7, 0xb2cc, 0xd6eb, + 0xd6ee, 0xdafb, 0xdaf2, 0xb5b2, 0xdaf9, 0xdaf6, 0xdaee, 0xdaf7, + 0xb5b4, 0xdaef, 0xdaeb, 0xb86c, 0xdaf4, 0xb5b1, 0xdafa, 0xb5b8, + 0xb5ba, 0xdaed, 0xb5b9, 0xdaf0, 0xb5b3, 0xdaf8, 0xdaf1, 0xdaf5, + 0xdaf3, 0xb5b6, 0xdaec, 0xb5bb, 0xb2ce, 0xb5b7, 0xb5bc, 0xb868, + 0xdf5d, 0xdf5f, 0xdf61, 0xdf65, 0xdf5b, 0xdf59, 0xb86a, 0xdf60, + 0xdf64, 0xdf5c, 0xdf58, 0xdf57, 0xdf62, 0xdf5a, 0xdf5e, 0xb86b, + 0xb869, 0xdf66, 0xb867, 0xdf63, 0xe372, 0xbaee, 0xe36a, 0xbd78, + 0xe374, 0xbaf1, 0xe378, 0xbaf7, 0xe365, 0xe375, 0xe362, 0xe377, + 0xe366, 0xbafe, 0xbafb, 0xe376, 0xe370, 0xbaed, 0xbaf5, 0xbaf4, + 0xbaf3, 0xbaf9, 0xe363, 0xbafa, 0xe371, 0xbaf6, 0xbaec, 0xe373, + 0xbaef, 0xbaf0, 0xbaf8, 0xe368, 0xe367, 0xe364, 0xe36c, 0xe369, + 0xe36d, 0xbafd, 0xe379, 0xbaf2, 0xe36e, 0xe36f, 0xe36b, 0xbafc, + 0xe6e7, 0xbd70, 0xbd79, 0xbd75, 0xe6e4, 0xbd72, 0xbd76, 0xe6f0, + 0xbd6c, 0xe6e8, 0xbd74, 0xe6eb, 0xe6e6, 0xbd73, 0xbd77, 0xe6e5, + 0xbd71, 0xe6ef, 0xbd6e, 0xe6ee, 0xe6ed, 0xbd7a, 0xe572, 0xbd6d, + 0xe6ec, 0xe6e3, 0xbd7b, 0xe6ea, 0xbd6f, 0xe6e9, 0xbfa2, 0xbfa7, + 0xbf7e, 0xead8, 0xeacf, 0xeadb, 0xead3, 0xead9, 0xbfa8, 0xbfa1, + 0xeacc, 0xead2, 0xeadc, 0xead5, 0xeada, 0xeace, 0xead6, 0xbfa3, + 0xead4, 0xbfa6, 0xbfa5, 0xead0, 0xead1, 0xeacd, 0xead7, 0xbfa4, + 0xeade, 0xeadd, 0xedda, 0xedd6, 0xc15f, 0xedd0, 0xc159, 0xc169, + 0xeddc, 0xc161, 0xc15d, 0xedd3, 0xc164, 0xc167, 0xedde, 0xc15c, + 0xedd5, 0xc165, 0xede0, 0xeddd, 0xedd1, 0xc160, 0xc15a, 0xc168, + 0xedd8, 0xc163, 0xedd2, 0xc15e, 0xeddf, 0xc162, 0xc15b, 0xedd9, + 0xc166, 0xedd7, 0xeddb, 0xf06e, 0xf074, 0xc2b9, 0xf077, 0xc2b4, + 0xc2b5, 0xf06f, 0xf076, 0xf071, 0xc2ba, 0xc2b7, 0xf06d, 0xc2b6, + 0xf073, 0xf075, 0xc2b8, 0xf072, 0xf070, 0xf2b8, 0xc3b7, 0xc3b8, + 0xc3b4, 0xc3b5, 0xf2b4, 0xf2b2, 0xf2b6, 0xc3ba, 0xf2b7, 0xf2b0, + 0xf2af, 0xf2b3, 0xf2b1, 0xc3b6, 0xf2b5, 0xf4ac, 0xc47e, 0xc47d, + 0xf4ad, 0xf4af, 0xf4ae, 0xc4a1, 0xf5eb, 0xf5e8, 0xf5e9, 0xf5e7, + 0xf5ea, 0xc4f2, 0xf5ec, 0xc4f1, 0xf742, 0xc5d5, 0xc5d7, 0xf7ee, + 0xc5d6, 0xf8b9, 0xf940, 0xf942, 0xf8fe, 0xf941, 0xc66c, 0xa6ce, + 0xacfb, 0xd26f, 0xafca, 0xb2da, 0xdafc, 0xdafd, 0xeadf, 0xc16a, + 0xede1, 0xc2bb, 0xf2ba, 0xf2b9, 0xc4a2, 0xf5ed, 0xf743, 0xc5f8, + 0xca49, 0xaac9, 0xa875, 0xd04d, 0xd360, 0xd35b, 0xd35f, 0xd35d, + 0xafcb, 0xd35e, 0xd35c, 0xd6f1, 0xdafe, 0xdb40, 0xdf69, 0xdf6a, + 0xb86e, 0xb86f, 0xdf68, 0xdf6b, 0xdf67, 0xb86d, 0xbb40, 0xb870, + 0xe37a, 0xbd7c, 0xe6f1, 0xbd7d, 0xbfa9, 0xeae2, 0xeae0, 0xeae1, + 0xede4, 0xede3, 0xede2, 0xf2bb, 0xc3b9, 0xf2bc, 0xf744, 0xc5f9, + 0xf8ba, 0xa6cf, 0xaacb, 0xaaca, 0xd04f, 0xacfc, 0xd04e, 0xd362, + 0xafcc, 0xd6f2, 0xd361, 0xb2dc, 0xd6f5, 0xd6f3, 0xd6f4, 0xb2db, + 0xdb42, 0xdb43, 0xdb41, 0xb873, 0xdf6d, 0xdf6c, 0xdf6e, 0xb872, + 0xb871, 0xe6f2, 0xe6f4, 0xbd7e, 0xe6f3, 0xeae3, 0xbfaa, 0xf079, + 0xf078, 0xc3bb, 0xf2bd, 0xc3bd, 0xc3bc, 0xf4b0, 0xf5ee, 0xc4f3, + 0xa6d0, 0xd050, 0xacfd, 0xd365, 0xafce, 0xd364, 0xd363, 0xafcd, + 0xd6fb, 0xd6fd, 0xd6f6, 0xd6f7, 0xb2dd, 0xd6f8, 0xb2de, 0xd6fc, + 0xd6f9, 0xd6fa, 0xb2df, 0xb5be, 0xb5bf, 0xdb44, 0xdf6f, 0xdf70, + 0xe37e, 0xbb43, 0xbb41, 0xbb42, 0xe37b, 0xe37c, 0xe37d, 0xe6f9, + 0xe6fa, 0xbda1, 0xe6f7, 0xe6f6, 0xe6f8, 0xe6f5, 0xbfad, 0xeae4, + 0xbfab, 0xbfac, 0xede6, 0xc16b, 0xede5, 0xefa8, 0xf07a, 0xf07b, + 0xc2bc, 0xc2bd, 0xc16c, 0xf2be, 0xf2bf, 0xf4b1, 0xc4a3, 0xa6d1, + 0xa6d2, 0xacfe, 0xaacc, 0xafcf, 0xd051, 0xb5c0, 0xa6d3, 0xad41, + 0xd052, 0xd053, 0xad40, 0xad42, 0xa6d4, 0xd054, 0xafd1, 0xd366, + 0xafd3, 0xafd0, 0xafd2, 0xd741, 0xb2e0, 0xd740, 0xd6fe, 0xdf71, + 0xe3a1, 0xbda2, 0xbfae, 0xeae6, 0xeae5, 0xede7, 0xf5ef, 0xa6d5, + 0xcb73, 0xcdaa, 0xad43, 0xd055, 0xd368, 0xafd4, 0xd367, 0xafd5, + 0xd743, 0xb2e2, 0xd742, 0xd744, 0xb2e1, 0xdb46, 0xdb47, 0xdb45, + 0xb5c1, 0xb874, 0xb875, 0xbb45, 0xe3a3, 0xe3a2, 0xbb44, 0xe6fb, + 0xe6fc, 0xeae7, 0xc170, 0xc16f, 0xc16d, 0xc16e, 0xc171, 0xf07c, + 0xc2bf, 0xc2be, 0xf2c0, 0xf4b2, 0xc5a5, 0xc5a4, 0xa6d6, 0xd1fb, + 0xb877, 0xb5c2, 0xb876, 0xbb46, 0xa6d7, 0xc9a9, 0xa6d8, 0xa6d9, + 0xcdab, 0xcb76, 0xcb77, 0xa877, 0xcb74, 0xa876, 0xa879, 0xcb75, + 0xa87b, 0xa87a, 0xcb78, 0xa878, 0xaad1, 0xaacf, 0xcdad, 0xaace, + 0xaad3, 0xaad5, 0xaad2, 0xcdb0, 0xcdac, 0xaad6, 0xaad0, 0xa87c, + 0xaad4, 0xcdaf, 0xcdae, 0xaacd, 0xd05b, 0xad47, 0xad48, 0xd05d, + 0xd057, 0xd05a, 0xd063, 0xd061, 0xad49, 0xd067, 0xad4c, 0xd064, + 0xd05c, 0xd059, 0xdb49, 0xd062, 0xad44, 0xd065, 0xd056, 0xd05f, + 0xad46, 0xad4b, 0xd060, 0xad4f, 0xad4d, 0xd058, 0xad4a, 0xd05e, + 0xad4e, 0xad45, 0xd066, 0xafda, 0xafe3, 0xafd8, 0xafd6, 0xd36a, + 0xafde, 0xafdb, 0xd36c, 0xafdd, 0xd36b, 0xd369, 0xd36e, 0xafe2, + 0xafe0, 0xdb48, 0xd36f, 0xd36d, 0xafd7, 0xafd9, 0xafdc, 0xafdf, + 0xafe1, 0xd74e, 0xb2e4, 0xd745, 0xd747, 0xd748, 0xd750, 0xd74c, + 0xd74a, 0xd74d, 0xd751, 0xb2e5, 0xb2e9, 0xd746, 0xd74f, 0xb2e7, + 0xb2e6, 0xd74b, 0xd749, 0xb2e3, 0xb2e8, 0xb5c8, 0xdb51, 0xdb4f, + 0xb5ca, 0xdb4a, 0xdfa1, 0xb5c9, 0xdb4e, 0xdb4b, 0xb5c5, 0xb5cb, + 0xdb50, 0xb5c7, 0xdb4d, 0xbb47, 0xb5c6, 0xdb4c, 0xb5cc, 0xb5c4, + 0xb5c3, 0xdf77, 0xdf75, 0xdf7b, 0xdf73, 0xdfa2, 0xdf78, 0xdf72, + 0xb87b, 0xb8a3, 0xdf7d, 0xdf76, 0xb87e, 0xb87c, 0xdf7e, 0xb879, + 0xb878, 0xdf79, 0xb87d, 0xb5cd, 0xdf7c, 0xdf74, 0xb87a, 0xb8a1, + 0xb8a2, 0xbb4c, 0xbb48, 0xbb4d, 0xe3a6, 0xe3a5, 0xe3a7, 0xbb4a, + 0xe3a4, 0xbb4b, 0xe3aa, 0xe3a9, 0xe3a8, 0xbb49, 0xe741, 0xe744, + 0xbda8, 0xe743, 0xbda7, 0xbda3, 0xbda4, 0xbda5, 0xe740, 0xe6fe, + 0xbda6, 0xe742, 0xe6fd, 0xeae9, 0xeaf3, 0xbfb1, 0xbfb0, 0xeaed, + 0xeaef, 0xeaea, 0xeaee, 0xeae8, 0xeaf1, 0xbfaf, 0xeaf0, 0xeaec, + 0xeaf2, 0xeaeb, 0xc174, 0xede8, 0xedee, 0xc178, 0xc17a, 0xc177, + 0xc176, 0xc175, 0xc173, 0xede9, 0xedec, 0xc172, 0xeded, 0xc179, + 0xedeb, 0xedea, 0xc2c0, 0xc2c1, 0xf0a1, 0xf07d, 0xf07e, 0xf2c2, + 0xf2c1, 0xc3be, 0xf4b4, 0xc4a4, 0xf4b3, 0xf5f0, 0xf745, 0xc5a6, + 0xf943, 0xf944, 0xc5d8, 0xa6da, 0xaad7, 0xdb52, 0xbb4e, 0xc17b, + 0xedef, 0xa6db, 0xafe5, 0xafe4, 0xdb53, 0xeaf4, 0xa6dc, 0xad50, + 0xdb54, 0xdb55, 0xdb56, 0xbb4f, 0xbfb2, 0xa6dd, 0xaad8, 0xd068, + 0xafe6, 0xd370, 0xb2ea, 0xdb57, 0xb8a4, 0xbb50, 0xbfb3, 0xc17c, + 0xc2c2, 0xf4b5, 0xa6de, 0xaad9, 0xafe7, 0xd752, 0xb5ce, 0xbb51, + 0xe3ab, 0xe745, 0xa6df, 0xb5cf, 0xdfa3, 0xbb52, 0xa6e0, 0xcdb1, + 0xd069, 0xad51, 0xd372, 0xafea, 0xafe8, 0xafe9, 0xafeb, 0xd371, + 0xd757, 0xd754, 0xd756, 0xb2eb, 0xb2ed, 0xb2ec, 0xd753, 0xb2ee, + 0xd755, 0xdb58, 0xdb59, 0xdb5a, 0xdfa6, 0xdfa7, 0xdfa5, 0xdfa8, + 0xb8a5, 0xdfa4, 0xbb53, 0xe74a, 0xe746, 0xe749, 0xe74b, 0xe748, + 0xe747, 0xeaf5, 0xeaf6, 0xeaf7, 0xbfb4, 0xbfb5, 0xedf1, 0xedf0, + 0xedf2, 0xf0a3, 0xf0a2, 0xf2c4, 0xf2c5, 0xf2c3, 0xc4a5, 0xf4b6, + 0xf4b7, 0xf746, 0xf7ef, 0xf8bb, 0xa6e1, 0xa87d, 0xc17d, 0xa6e2, + 0xd758, 0xdb5b, 0xc641, 0xca4a, 0xca4b, 0xca4d, 0xa6e3, 0xca4e, + 0xca4c, 0xcba2, 0xcba3, 0xcb7b, 0xcba1, 0xa8a1, 0xa8a2, 0xcb7c, + 0xcb7a, 0xcb79, 0xcb7d, 0xa87e, 0xcb7e, 0xd06a, 0xcdb6, 0xaadc, + 0xcdb5, 0xcdb7, 0xaadb, 0xcdbc, 0xaadf, 0xcdb2, 0xcdc0, 0xcdc6, + 0xaae6, 0xcdc3, 0xaae3, 0xcdb9, 0xcdbf, 0xcdc1, 0xcdb4, 0xaae2, + 0xaadd, 0xcdba, 0xaae4, 0xaae7, 0xaae1, 0xaada, 0xcdbe, 0xcdb8, + 0xcdc5, 0xaae9, 0xaae5, 0xaae0, 0xcdbd, 0xafec, 0xcdbb, 0xaade, + 0xaae8, 0xcdb3, 0xcdc2, 0xcdc4, 0xad62, 0xad5c, 0xad64, 0xad61, + 0xd071, 0xd074, 0xad5d, 0xd06b, 0xad56, 0xad60, 0xad63, 0xad65, + 0xd0a2, 0xd077, 0xad55, 0xd0a1, 0xad59, 0xad57, 0xad52, 0xd06f, + 0xd07e, 0xd073, 0xd076, 0xd0a5, 0xad66, 0xd07d, 0xad5e, 0xd078, + 0xd0a4, 0xd075, 0xd079, 0xd07c, 0xd06d, 0xd0a3, 0xd07b, 0xd06c, + 0xd070, 0xad5f, 0xad5a, 0xad53, 0xad58, 0xad54, 0xad67, 0xd06e, + 0xd3a5, 0xad5b, 0xd07a, 0xce41, 0xd3a8, 0xaffa, 0xd376, 0xd3a3, + 0xd37d, 0xd3b2, 0xd3aa, 0xd37e, 0xd3a9, 0xd378, 0xd37c, 0xd3b5, + 0xaffd, 0xd3ad, 0xd3a4, 0xafed, 0xd3b3, 0xd374, 0xd3ac, 0xaffc, + 0xaff7, 0xd373, 0xaff5, 0xaff4, 0xaff9, 0xd3ab, 0xaff1, 0xaff8, + 0xd072, 0xdb5c, 0xd3a6, 0xd37a, 0xaffb, 0xd37b, 0xd3a1, 0xaffe, + 0xd375, 0xd3af, 0xd3ae, 0xd3b6, 0xaff3, 0xaff0, 0xd3b4, 0xd3b0, + 0xd3a7, 0xd3a2, 0xaff6, 0xaff2, 0xd377, 0xafee, 0xd3b1, 0xafef, + 0xd379, 0xd75e, 0xd760, 0xd765, 0xd779, 0xb2fc, 0xb2f2, 0xd75d, + 0xb2fd, 0xb2fe, 0xd768, 0xd76f, 0xd775, 0xd762, 0xd769, 0xb340, + 0xd777, 0xd772, 0xb2fa, 0xb2f8, 0xd76e, 0xd76a, 0xd75c, 0xb2ef, + 0xd761, 0xd759, 0xb2f7, 0xb2f9, 0xd766, 0xd763, 0xb2f4, 0xd773, + 0xb2f1, 0xd764, 0xd77a, 0xd76c, 0xd76b, 0xb2f0, 0xb2fb, 0xb2f3, + 0xd75a, 0xd75f, 0xd770, 0xd776, 0xb341, 0xd75b, 0xd767, 0xd76d, + 0xb2f6, 0xd778, 0xd771, 0xd774, 0xb2f5, 0xdb6c, 0xdb60, 0xb5d7, + 0xdb7d, 0xdba7, 0xdbaa, 0xb5d5, 0xdb68, 0xdba3, 0xdb69, 0xdb77, + 0xb5e2, 0xdb73, 0xb5df, 0xdb74, 0xdb5d, 0xdba4, 0xb5e8, 0xdba1, + 0xdb75, 0xdbac, 0xdb70, 0xdfc8, 0xdbaf, 0xb5e6, 0xdb6e, 0xdb7a, + 0xb5e9, 0xb5d4, 0xdb72, 0xdbad, 0xdb6b, 0xdb64, 0xdb6f, 0xdb63, + 0xdb61, 0xb5d0, 0xdba5, 0xdb6a, 0xdba8, 0xdba9, 0xb5d8, 0xb5dd, + 0xb5d9, 0xb5e1, 0xdb7e, 0xb5da, 0xdb76, 0xdb66, 0xb5d2, 0xdb5e, + 0xdba2, 0xdbab, 0xdb65, 0xb5e0, 0xdbb0, 0xdb71, 0xdb6d, 0xb5d1, + 0xb5e5, 0xdb7c, 0xb5e7, 0xdb78, 0xb5dc, 0xb5d6, 0xb5de, 0xb5d3, + 0xb5e4, 0xdb79, 0xdb67, 0xdb7b, 0xdb62, 0xdba6, 0xdbae, 0xdb5f, + 0xdfc7, 0xdfdd, 0xb855, 0xdfcc, 0xdfca, 0xdfb5, 0xb8a9, 0xdfc5, + 0xdfd9, 0xdfc1, 0xb8b1, 0xdfd8, 0xdfbf, 0xb5e3, 0xdfcf, 0xdfc0, + 0xdfd6, 0xb8b0, 0xb8a8, 0xdfaa, 0xdfb2, 0xdfcb, 0xdfc3, 0xdfdc, + 0xdfc6, 0xb8b6, 0xdfd7, 0xb8ad, 0xdfc9, 0xdfd1, 0xdfb6, 0xdfd0, + 0xdfe1, 0xdfb1, 0xdfd2, 0xdfdf, 0xdfab, 0xb5db, 0xdfb9, 0xdfb8, + 0xb8af, 0xdfbc, 0xdfbe, 0xdfcd, 0xdfde, 0xb8b2, 0xb8b3, 0xdfb0, + 0xb8ab, 0xdfb4, 0xdfda, 0xb8b4, 0xb8ac, 0xb8ae, 0xb8b5, 0xdfe0, + 0xdfd3, 0xdfce, 0xdfbb, 0xdfba, 0xb8aa, 0xdfac, 0xb8a7, 0xdfc4, + 0xdfad, 0xdfc2, 0xdfb7, 0xdfdb, 0xb8a6, 0xdfb3, 0xdfaf, 0xdfd5, + 0xdfae, 0xbb60, 0xe3d3, 0xe3c2, 0xe3ac, 0xe3ca, 0xbb58, 0xe3bb, + 0xe3c5, 0xbb5b, 0xe3be, 0xbb59, 0xe3af, 0xe3cd, 0xe3ae, 0xe3c1, + 0xe3ad, 0xe3bf, 0xe3c8, 0xe3c6, 0xe3ba, 0xe3b5, 0xe3b3, 0xe3b4, + 0xe3c7, 0xe3d2, 0xe3bc, 0xbb5a, 0xe3b7, 0xe3cb, 0xbb5d, 0xe3b6, + 0xe3b0, 0xe3c0, 0xbb61, 0xbb55, 0xbb5e, 0xe3b8, 0xe3b2, 0xbb57, + 0xdfd4, 0xbb56, 0xe3c3, 0xbb54, 0xbb63, 0xbb5c, 0xe3c4, 0xe3b9, + 0xe3b1, 0xe3cc, 0xe3bd, 0xbb62, 0xe3d0, 0xbb5f, 0xe3cf, 0xe3c9, + 0xe3ce, 0xe3d1, 0xe773, 0xe774, 0xe767, 0xe766, 0xe762, 0xbdb4, + 0xbdac, 0xe776, 0xe775, 0xdfa9, 0xe75f, 0xe763, 0xe75d, 0xe770, + 0xe761, 0xe777, 0xe75a, 0xe758, 0xe764, 0xe76e, 0xe769, 0xbdb6, + 0xe74f, 0xe76d, 0xbdb7, 0xdfbd, 0xe75b, 0xe752, 0xe755, 0xe77b, + 0xe75c, 0xe753, 0xe751, 0xe74e, 0xbdb0, 0xe765, 0xbdaf, 0xbdb3, + 0xe760, 0xe768, 0xbda9, 0xe778, 0xe77c, 0xbdab, 0xe757, 0xe76b, + 0xe76f, 0xe754, 0xe779, 0xbdb2, 0xbdb1, 0xe74c, 0xbdb5, 0xe772, + 0xe756, 0xe76a, 0xe750, 0xe75e, 0xe759, 0xbdad, 0xbdae, 0xe76c, + 0xe77d, 0xe77a, 0xe771, 0xe74d, 0xbdaa, 0xeb49, 0xeb40, 0xeb43, + 0xbfbb, 0xeb45, 0xeaf9, 0xeb41, 0xeb47, 0xbfb8, 0xbfbc, 0xbfb6, + 0xeafb, 0xeb4c, 0xeb46, 0xeafc, 0xeb55, 0xeb4f, 0xeaf8, 0xee46, + 0xeafe, 0xbfb7, 0xeb4a, 0xeb54, 0xbfbf, 0xeb51, 0xeafd, 0xeb44, + 0xeb48, 0xeb42, 0xeb56, 0xeb53, 0xeb50, 0xbfb9, 0xbfba, 0xbfbe, + 0xeafa, 0xeb57, 0xbfbd, 0xeb4d, 0xeb4b, 0xeb4e, 0xee53, 0xee40, + 0xee45, 0xee52, 0xee44, 0xedfb, 0xee41, 0xc1a2, 0xedf4, 0xee4d, + 0xee4f, 0xedf3, 0xc1a1, 0xee51, 0xee49, 0xc1a8, 0xee50, 0xee42, + 0xc1aa, 0xedf9, 0xeb52, 0xee4a, 0xee47, 0xedf5, 0xee55, 0xc1a4, + 0xc1a5, 0xedf7, 0xee48, 0xee54, 0xee4b, 0xedfd, 0xc1a7, 0xc1a3, + 0xee4c, 0xedfe, 0xee56, 0xedf8, 0xee43, 0xee4e, 0xedfa, 0xedfc, + 0xc2cb, 0xedf6, 0xc1a9, 0xc2c4, 0xc17e, 0xc1a6, 0xc2c8, 0xf0b3, + 0xf0a9, 0xf0a4, 0xf0aa, 0xf0b4, 0xf0b8, 0xf0b7, 0xc2ca, 0xc2c9, + 0xf0ab, 0xf0b9, 0xf0ae, 0xf0a6, 0xf0a8, 0xf0a7, 0xf0ad, 0xf0b2, + 0xf0a5, 0xf0ac, 0xf0b1, 0xc2c7, 0xf0af, 0xc2c5, 0xf0b0, 0xc2c3, + 0xc2c6, 0xf2d5, 0xf0b5, 0xc3c2, 0xf2cd, 0xf2d1, 0xf2c9, 0xf2cc, + 0xf2d4, 0xc3c0, 0xf2d9, 0xf2d2, 0xf2ca, 0xf2da, 0xf2d3, 0xc3c3, + 0xc3c4, 0xf2d7, 0xf2cb, 0xc3bf, 0xc3c1, 0xf2c6, 0xf2ce, 0xf2c8, + 0xf2d8, 0xf2d6, 0xf2c7, 0xf2cf, 0xf4be, 0xc3c5, 0xf2d0, 0xc4a7, + 0xc4a9, 0xc4a6, 0xf4c3, 0xf4bb, 0xf4b9, 0xf4bd, 0xf4ba, 0xf4bf, + 0xf4c1, 0xc4aa, 0xc4ac, 0xf4c0, 0xc4ad, 0xc4ab, 0xf4c2, 0xc4a8, + 0xc4f4, 0xf5f1, 0xf5f7, 0xc4f6, 0xf4bc, 0xf5f6, 0xf5fd, 0xf5f4, + 0xf5fb, 0xf5fa, 0xf4b8, 0xf5f5, 0xf0b6, 0xf5fe, 0xf5f3, 0xf5f8, + 0xf5fc, 0xf5f2, 0xf74a, 0xc4f5, 0xf5f9, 0xf7f4, 0xf74b, 0xf749, + 0xf747, 0xf748, 0xf74c, 0xc5d9, 0xf7f2, 0xf7f0, 0xf7f5, 0xf7f3, + 0xf7f6, 0xc5da, 0xf7f1, 0xf8bc, 0xf945, 0xf946, 0xf947, 0xf9c7, + 0xf9bd, 0xca4f, 0xaaea, 0xad68, 0xd3b8, 0xd3b7, 0xb040, 0xb342, + 0xd77c, 0xd77b, 0xb5ea, 0xb8b8, 0xb8b7, 0xb8b9, 0xe3d4, 0xe77e, + 0xeb58, 0xeb5a, 0xeb59, 0xc1ab, 0xee57, 0xf0ba, 0xf9a5, 0xa6e4, + 0xcdc9, 0xcdca, 0xcdc8, 0xcdc7, 0xaaeb, 0xd0a9, 0xd0a7, 0xd0a6, + 0xad69, 0xad6b, 0xad6a, 0xd0a8, 0xd3c4, 0xd3c1, 0xd3bf, 0xb041, + 0xd3c2, 0xb046, 0xd3bc, 0xd3cb, 0xd3cd, 0xd3bd, 0xb043, 0xd3ce, + 0xd3c9, 0xd3bb, 0xd3c0, 0xd3ca, 0xd3c6, 0xd3c3, 0xb048, 0xd3cc, + 0xd3be, 0xd3c7, 0xd3b9, 0xb047, 0xb044, 0xd3c5, 0xd3c8, 0xd3ba, + 0xb045, 0xb042, 0xb34c, 0xd7a5, 0xb34b, 0xd7a8, 0xd7ab, 0xb348, + 0xb346, 0xd77e, 0xd7a9, 0xd7a7, 0xd7a4, 0xd7ac, 0xd7ad, 0xd7af, + 0xd7b0, 0xd77d, 0xb345, 0xd7a2, 0xd7a1, 0xd7ae, 0xb347, 0xd7a3, + 0xb349, 0xb344, 0xd7a6, 0xb34d, 0xb34a, 0xd7aa, 0xb5f1, 0xdbbf, + 0xdbb4, 0xb5ee, 0xdfe7, 0xdbbd, 0xdbb1, 0xb5ec, 0xdbb6, 0xb5ef, + 0xdbba, 0xdbb8, 0xb5f2, 0xb5eb, 0xdbb2, 0xdbb5, 0xb5f0, 0xdbb3, + 0xdbbe, 0xdbbc, 0xdbb7, 0xdbb9, 0xdbbb, 0xb5ed, 0xdfe8, 0xdfee, + 0xdfe4, 0xdfea, 0xb8ba, 0xdfe6, 0xb8c0, 0xb8bf, 0xb8be, 0xdfed, + 0xb8c1, 0xb8c2, 0xdfe3, 0xdff0, 0xb8c3, 0xb8bd, 0xb8bc, 0xdfec, + 0xb8c4, 0xdfe2, 0xdfe5, 0xdfef, 0xdfeb, 0xe3f4, 0xe3e9, 0xb8bb, + 0xbb6a, 0xe3dd, 0xe3f2, 0xe3de, 0xbb65, 0xe3db, 0xe3e4, 0xe3dc, + 0xbb67, 0xe3d6, 0xe3f1, 0xbb68, 0xe3ee, 0xe3ef, 0xe3d7, 0xbb6d, + 0xe3e6, 0xe3e0, 0xe3e7, 0xe3da, 0xe3f3, 0xe3eb, 0xe3e5, 0xe3d5, + 0xbb69, 0xe3ec, 0xbb6c, 0xe3f0, 0xe3ea, 0xbb66, 0xe3e8, 0xe3e2, + 0xbb64, 0xe3d9, 0xe3e1, 0xe3ed, 0xe3df, 0xe3e3, 0xbdc1, 0xdfe9, + 0xe7b2, 0xe7bb, 0xe7b1, 0xe7ad, 0xe7aa, 0xbdc2, 0xe7a8, 0xbb6b, + 0xe7a1, 0xbdc0, 0xe7a7, 0xbdbf, 0xe7ac, 0xe7a9, 0xe7b9, 0xe7b4, + 0xe7ae, 0xe7b3, 0xbdbb, 0xe7ab, 0xe7be, 0xe7a2, 0xe7a3, 0xe7ba, + 0xbdbc, 0xe7bf, 0xbdbe, 0xe7c0, 0xe7b0, 0xe3d8, 0xe7b6, 0xe7af, + 0xe7b8, 0xe7b5, 0xe7a6, 0xbdb9, 0xe7bd, 0xbdba, 0xe7a4, 0xbdbd, + 0xeb64, 0xe7b7, 0xe7bc, 0xeb61, 0xbdb8, 0xbfc0, 0xeb6b, 0xeb67, + 0xeb65, 0xeb60, 0xeb6f, 0xbfc4, 0xeb5c, 0xeb68, 0xeb69, 0xeb5f, + 0xeb5e, 0xeb6c, 0xeb62, 0xeb5d, 0xeb63, 0xeb6e, 0xeb5b, 0xeb6d, + 0xeb6a, 0xbfc2, 0xbfc1, 0xbfc3, 0xeb66, 0xf0cb, 0xee59, 0xc1b1, + 0xee5d, 0xee5a, 0xee61, 0xee67, 0xee5c, 0xee70, 0xc1ae, 0xee6a, + 0xee5f, 0xee6b, 0xee66, 0xee6d, 0xee5e, 0xc1b3, 0xc1b2, 0xee60, + 0xee6e, 0xee58, 0xee6c, 0xc1ac, 0xee64, 0xee63, 0xee68, 0xee5b, + 0xc1b0, 0xc1b4, 0xee62, 0xee69, 0xc1b5, 0xee65, 0xc1ad, 0xc1af, + 0xf0c7, 0xf0c5, 0xf0cc, 0xf0c9, 0xf0cd, 0xf0be, 0xf0c6, 0xf0d1, + 0xee6f, 0xf0c2, 0xc2cf, 0xe7a5, 0xf0bd, 0xf0ca, 0xf0c4, 0xf0c1, + 0xf0bc, 0xf0bb, 0xf0d0, 0xf0c0, 0xf0bf, 0xc2cd, 0xf0c8, 0xc2cc, + 0xc2ce, 0xf0c3, 0xf0cf, 0xf2de, 0xf2df, 0xc3c9, 0xf2dc, 0xc3c6, + 0xf2e4, 0xc3ca, 0xf2e6, 0xf2db, 0xf0ce, 0xf2e8, 0xf2dd, 0xc3c7, + 0xf2e3, 0xf2e5, 0xf2e0, 0xf2e7, 0xf2e2, 0xf2e1, 0xc3c8, 0xf4c5, + 0xf4c6, 0xf4c8, 0xc4ae, 0xc4af, 0xf4c9, 0xf4c7, 0xf4c4, 0xf642, + 0xf645, 0xf641, 0xc4fa, 0xf643, 0xc4f9, 0xc4f8, 0xc4f7, 0xf644, + 0xf751, 0xf74f, 0xf74e, 0xf640, 0xf750, 0xf646, 0xf74d, 0xf7f9, + 0xf7d7, 0xf7f7, 0xc5db, 0xf7f8, 0xf7fa, 0xf8bf, 0xc5fa, 0xf8be, + 0xf8bd, 0xc5fb, 0xc65a, 0xf96e, 0xf9a7, 0xf9a6, 0xf9a8, 0xa6e5, + 0xd0aa, 0xd3cf, 0xd3d0, 0xdbc0, 0xf647, 0xf8c0, 0xa6e6, 0xad6c, + 0xd0ab, 0xd7b1, 0xb34e, 0xdbc2, 0xdbc1, 0xb5f3, 0xb8c5, 0xe7c1, + 0xbdc3, 0xbdc4, 0xbfc5, 0xc5fc, 0xa6e7, 0xd0ac, 0xaaed, 0xd0ae, + 0xd0ad, 0xad6d, 0xd3d1, 0xd3d8, 0xb049, 0xd3d6, 0xd3d4, 0xd3db, + 0xd3d2, 0xd3d3, 0xb04a, 0xb04e, 0xd3dc, 0xb04d, 0xd3da, 0xd3d7, + 0xd3d5, 0xb04b, 0xb04c, 0xd3d9, 0xb350, 0xd7b2, 0xb355, 0xd7c2, + 0xb354, 0xd7c4, 0xd7b8, 0xb352, 0xd7c3, 0xd7b3, 0xb353, 0xd7bf, + 0xd7bb, 0xd7bd, 0xd7b7, 0xd7be, 0xb34f, 0xd7ba, 0xd7b9, 0xd7b5, + 0xd7c0, 0xd7bc, 0xd7b4, 0xd7b6, 0xb351, 0xd7c1, 0xb5f6, 0xdbcd, + 0xdbc9, 0xdbcb, 0xdbc6, 0xdbc5, 0xdbc3, 0xdbca, 0xdbcc, 0xdbc8, + 0xdbc7, 0xb5f4, 0xb5f5, 0xdbcf, 0xb8cd, 0xdff2, 0xdff8, 0xdff3, + 0xdff4, 0xdff9, 0xb8cf, 0xb8c7, 0xb8ce, 0xdff1, 0xdbc4, 0xb8ca, + 0xb8c8, 0xdff7, 0xdff6, 0xb8c9, 0xb8cb, 0xdff5, 0xb8c6, 0xb8cc, + 0xe3f6, 0xbb74, 0xe442, 0xe441, 0xe3fb, 0xbb76, 0xe440, 0xe3f7, + 0xe3f8, 0xbb6e, 0xbb70, 0xe3fd, 0xe3f5, 0xbb72, 0xbb71, 0xe3f9, + 0xe3fe, 0xe3fc, 0xbb73, 0xe3fa, 0xdbce, 0xbb6f, 0xe7c2, 0xe7c9, + 0xbdc6, 0xe7cd, 0xbdca, 0xe7c5, 0xe7c3, 0xe7cc, 0xbdc5, 0xe7cb, + 0xbdc7, 0xbdc8, 0xe7c4, 0xbdc9, 0xe7ca, 0xe7c6, 0xe7c7, 0xe7c8, + 0xbb75, 0xeb70, 0xeb7c, 0xbfca, 0xeb77, 0xeb79, 0xbfc8, 0xeb71, + 0xeb75, 0xeb78, 0xbfc6, 0xbfc9, 0xeb7b, 0xeb73, 0xeb74, 0xeb7a, + 0xeb72, 0xeb76, 0xbfc7, 0xee72, 0xee71, 0xc1b7, 0xee77, 0xc1b9, + 0xc1b6, 0xee73, 0xc1ba, 0xee74, 0xee75, 0xee78, 0xc1b8, 0xf0d6, + 0xf0d9, 0xf0d3, 0xf0d5, 0xf0d4, 0xf0d7, 0xf0d8, 0xee76, 0xf0d2, + 0xc3cd, 0xf2ec, 0xf2ef, 0xf2f1, 0xf2ea, 0xf2eb, 0xf2ee, 0xf2f0, + 0xc3ce, 0xc3cc, 0xc3cb, 0xf2ed, 0xf2e9, 0xf4ca, 0xc4b0, 0xf4cb, + 0xf649, 0xc4fb, 0xf64b, 0xc4fc, 0xf648, 0xf64a, 0xc5a8, 0xf752, + 0xc5a7, 0xf7fd, 0xf7fc, 0xf7fb, 0xf948, 0xf949, 0xf94b, 0xf94a, + 0xca50, 0xa6e8, 0xad6e, 0xd7c5, 0xb5f7, 0xdffa, 0xc2d0, 0xf2f2, + 0xa8a3, 0xb357, 0xb356, 0xdbd0, 0xb5f8, 0xdbd2, 0xdbd1, 0xdffb, + 0xb8d0, 0xe443, 0xe446, 0xe445, 0xe444, 0xe7ce, 0xe7d0, 0xe7cf, + 0xbfcc, 0xbfcb, 0xc1bb, 0xee79, 0xee7b, 0xee7a, 0xc2d1, 0xf2f4, + 0xf2f3, 0xf4cc, 0xc4b1, 0xc4fd, 0xf754, 0xf753, 0xc65b, 0xa8a4, + 0xd0af, 0xad6f, 0xd7c8, 0xd7c6, 0xd7c7, 0xdbd4, 0xdbd5, 0xe043, + 0xdbd3, 0xdffc, 0xe041, 0xe040, 0xe042, 0xb8d1, 0xdffe, 0xdffd, + 0xe044, 0xe449, 0xe447, 0xe448, 0xe7d3, 0xe7d1, 0xe7d2, 0xeb7d, + 0xee7c, 0xee7d, 0xc2d2, 0xf2f5, 0xf4cd, 0xc4b2, 0xf64c, 0xf755, + 0xc5a9, 0xf7fe, 0xf94c, 0xa8a5, 0xad71, 0xad72, 0xd0b0, 0xd0b1, + 0xad70, 0xb054, 0xb052, 0xb051, 0xb058, 0xb050, 0xb059, 0xd3dd, + 0xb056, 0xb053, 0xb057, 0xb055, 0xb04f, 0xb35f, 0xb359, 0xd7cc, + 0xb35e, 0xb360, 0xb35a, 0xb35b, 0xd7ca, 0xb358, 0xd7cb, 0xb35d, + 0xd7c9, 0xb35c, 0xb644, 0xb646, 0xdbd8, 0xb645, 0xb5f9, 0xb5fd, + 0xb8e4, 0xe049, 0xdbda, 0xb5fe, 0xdbdd, 0xdbde, 0xb643, 0xdbe0, + 0xdbe2, 0xdbe3, 0xdbd7, 0xdbd6, 0xdbe4, 0xb642, 0xdbe1, 0xdbdf, + 0xb640, 0xb5fb, 0xb647, 0xdbdb, 0xdbdc, 0xdbd9, 0xb641, 0xb5fc, + 0xb5fa, 0xe048, 0xb8df, 0xb8da, 0xb8d5, 0xb8e5, 0xb8d6, 0xb8d2, + 0xb8e1, 0xb8de, 0xb8e0, 0xb8d7, 0xb8dc, 0xb8d3, 0xb8d4, 0xe050, + 0xe04d, 0xe045, 0xe04a, 0xb8e2, 0xe051, 0xb8e3, 0xb8d9, 0xe047, + 0xe04f, 0xe04b, 0xe04e, 0xe04c, 0xb8dd, 0xe046, 0xb8d8, 0xe44c, + 0xbb78, 0xbb7b, 0xe44e, 0xbba5, 0xe44d, 0xbb7d, 0xbdcf, 0xe44f, + 0xbba4, 0xe44b, 0xbba6, 0xbb79, 0xb8db, 0xbb7c, 0xbb7a, 0xbb7e, + 0xbba2, 0xbb77, 0xbba7, 0xbba3, 0xbba1, 0xe44a, 0xbdd6, 0xbdd2, + 0xbdd9, 0xe7d6, 0xbdda, 0xe7e2, 0xe7db, 0xbdcb, 0xe7e3, 0xe7dd, + 0xbdd5, 0xe7de, 0xbdd4, 0xe7e1, 0xbdce, 0xe7df, 0xe7d5, 0xbdcd, + 0xebaa, 0xbdd3, 0xbdd0, 0xbdd8, 0xe7d4, 0xe7d8, 0xbdcc, 0xe7d7, + 0xe7d9, 0xe7da, 0xbdd7, 0xe7dc, 0xe7e0, 0xe7e4, 0xbddb, 0xbfd2, + 0xeba5, 0xebab, 0xeba8, 0xeb7e, 0xebac, 0xeba1, 0xeba7, 0xbfcd, + 0xbfd3, 0xebad, 0xbfcf, 0xbfd9, 0xbfd4, 0xebaf, 0xeba9, 0xbfd0, + 0xeba2, 0xbfda, 0xeba3, 0xeba4, 0xbfdb, 0xbfd8, 0xbdd1, 0xbfce, + 0xebb0, 0xbfdc, 0xbfd5, 0xebae, 0xbfd1, 0xbfd6, 0xbfd7, 0xc1c3, + 0xeea4, 0xeead, 0xeeaa, 0xeeac, 0xc1c0, 0xeea5, 0xeeab, 0xc1bc, + 0xeea7, 0xc1c4, 0xeea3, 0xeea8, 0xeeaf, 0xeba6, 0xeea9, 0xeea2, + 0xc1bd, 0xeea1, 0xc1be, 0xeeb0, 0xc1bf, 0xeeae, 0xc1c2, 0xee7e, + 0xc1c1, 0xeea6, 0xf0dc, 0xf0ea, 0xf0e5, 0xf0e7, 0xf0db, 0xc2d3, + 0xf0da, 0xc2d6, 0xc2d5, 0xf0e9, 0xf0e1, 0xf0de, 0xf0e4, 0xf0dd, + 0xf0df, 0xf0e8, 0xf0e6, 0xc2d4, 0xf0ed, 0xf0eb, 0xf0e2, 0xf0ec, + 0xf0e3, 0xf2f9, 0xc3cf, 0xf341, 0xf64f, 0xc3d6, 0xf0e0, 0xf2f7, + 0xc3d2, 0xf2f8, 0xf2fd, 0xc3d4, 0xc3d5, 0xf2f6, 0xf340, 0xf342, + 0xf2fa, 0xf2fc, 0xf2fe, 0xf2fb, 0xf343, 0xc3d1, 0xc3d7, 0xc3d3, + 0xc3d0, 0xf4d0, 0xc4b7, 0xf4ce, 0xf4d2, 0xf4d3, 0xc4b5, 0xf4d4, + 0xf4d1, 0xf4cf, 0xc4b8, 0xc4b4, 0xf4d5, 0xc4b6, 0xc4b3, 0xc4fe, + 0xc540, 0xf64e, 0xf64d, 0xf650, 0xf651, 0xc541, 0xf756, 0xf75b, + 0xc5aa, 0xf758, 0xf757, 0xf75a, 0xf759, 0xf843, 0xc5dc, 0xf842, + 0xf840, 0xf841, 0xc5fe, 0xc5fd, 0xf8c1, 0xf8c2, 0xc640, 0xf94d, + 0xf94e, 0xc667, 0xc66d, 0xf9a9, 0xf9c8, 0xa8a6, 0xd7cd, 0xd7ce, + 0xe052, 0xe450, 0xe7e5, 0xc1c6, 0xc1c5, 0xf0ee, 0xf344, 0xf844, + 0xa8a7, 0xd3de, 0xb05a, 0xb361, 0xe054, 0xe053, 0xbddc, 0xe7e6, + 0xbddd, 0xeeb1, 0xc2d7, 0xc676, 0xa8a8, 0xcdcb, 0xd3df, 0xb362, + 0xd7cf, 0xd7d0, 0xdbe5, 0xb648, 0xb8e6, 0xe056, 0xe055, 0xe057, + 0xe451, 0xe452, 0xbba8, 0xbfdd, 0xbdde, 0xbfde, 0xeeb5, 0xeeb2, + 0xeeb4, 0xeeb3, 0xc1c7, 0xf0ef, 0xf346, 0xf345, 0xcba4, 0xb05c, + 0xb05b, 0xd3e0, 0xd7d1, 0xdbe7, 0xdbe6, 0xb649, 0xe059, 0xe05a, + 0xe058, 0xb8e8, 0xb8e7, 0xbbaa, 0xbba9, 0xe7e7, 0xebb3, 0xebb1, + 0xebb2, 0xbfdf, 0xeeb7, 0xeeb6, 0xf0f2, 0xf0f1, 0xf0f0, 0xf347, + 0xf9aa, 0xa8a9, 0xad73, 0xad74, 0xb05d, 0xb05e, 0xd3e2, 0xd3e1, + 0xd7d2, 0xb368, 0xb366, 0xb363, 0xb367, 0xb365, 0xb364, 0xb64a, + 0xdbea, 0xb8ed, 0xb64c, 0xb651, 0xdbec, 0xb653, 0xb652, 0xb655, + 0xdbeb, 0xdbe8, 0xb64f, 0xb64b, 0xb64d, 0xdbe9, 0xb654, 0xb650, + 0xb64e, 0xb8ef, 0xb8ee, 0xb8ec, 0xb8f0, 0xb8ea, 0xb8eb, 0xb8e9, + 0xe05b, 0xe454, 0xbbac, 0xbbad, 0xbbab, 0xe453, 0xe455, 0xe7ea, + 0xe7ec, 0xbde7, 0xe7ed, 0xbde0, 0xe7e9, 0xbddf, 0xbde9, 0xbde5, + 0xbde6, 0xbde2, 0xe7e8, 0xbde1, 0xe7ee, 0xe7eb, 0xbde8, 0xbde3, + 0xbde4, 0xebb5, 0xebb7, 0xebb6, 0xebb8, 0xbfe0, 0xebb4, 0xc1cb, + 0xeeb8, 0xc1c8, 0xc1cc, 0xc1ca, 0xc1c9, 0xf0f3, 0xf0f6, 0xf0f5, + 0xf0f4, 0xc2d8, 0xf348, 0xf349, 0xc3d8, 0xf34a, 0xc3d9, 0xc4ba, + 0xc4b9, 0xf652, 0xc542, 0xf653, 0xf75c, 0xc5ab, 0xc5ac, 0xf845, + 0xc642, 0xa8aa, 0xb36a, 0xb369, 0xe05c, 0xe05d, 0xbbae, 0xebb9, + 0xbdea, 0xebba, 0xeeb9, 0xa8ab, 0xd0b2, 0xad76, 0xad75, 0xd3e3, + 0xb05f, 0xd3e4, 0xd7d5, 0xd7d4, 0xd7d3, 0xdbee, 0xb658, 0xdbed, + 0xb657, 0xdbef, 0xb656, 0xe05f, 0xe062, 0xe060, 0xe061, 0xe065, + 0xe05e, 0xe066, 0xe063, 0xe064, 0xbbb0, 0xe456, 0xbbaf, 0xe7f2, + 0xe7f0, 0xbdeb, 0xe7ef, 0xe7f1, 0xbdec, 0xebbb, 0xebbc, 0xc1cd, + 0xf34c, 0xf34e, 0xf34b, 0xf34d, 0xf4d6, 0xf654, 0xf96f, 0xa8ac, + 0xad77, 0xd3e5, 0xd3e7, 0xd3e6, 0xd7d8, 0xb36c, 0xd7d6, 0xb36b, + 0xd7d9, 0xd7da, 0xd7d7, 0xdbfb, 0xb660, 0xdbf3, 0xdbf9, 0xb65b, + 0xb65e, 0xdbf2, 0xb659, 0xdbf6, 0xe06c, 0xb65d, 0xdbf1, 0xdbf7, + 0xdbf4, 0xdbfa, 0xdbf0, 0xdbf8, 0xb65c, 0xb65f, 0xdbf5, 0xb65a, + 0xb8f2, 0xe068, 0xb8f1, 0xe06f, 0xe06e, 0xb8f8, 0xb8f9, 0xe070, + 0xb8f3, 0xe06d, 0xb8f7, 0xe072, 0xe069, 0xe06b, 0xb8f4, 0xe067, + 0xe06a, 0xe071, 0xb8f5, 0xe073, 0xb8f6, 0xbbb1, 0xe45b, 0xe461, + 0xe459, 0xe462, 0xe458, 0xe45d, 0xe463, 0xe460, 0xe45f, 0xe45e, + 0xe457, 0xe45c, 0xe45a, 0xbdf1, 0xbdee, 0xe7fb, 0xe841, 0xe843, + 0xe840, 0xe7f8, 0xe7fa, 0xe845, 0xe842, 0xe7fc, 0xe846, 0xe7f9, + 0xe844, 0xbdef, 0xbdf5, 0xbdf3, 0xe7f3, 0xbdf4, 0xbdf0, 0xe7f4, + 0xe7f6, 0xe7f5, 0xe7fd, 0xe7fe, 0xbdf2, 0xbded, 0xe7f7, 0xebc6, + 0xbfe2, 0xebbd, 0xbfe3, 0xbfe6, 0xebc2, 0xebbf, 0xbfe5, 0xebc3, + 0xebc4, 0xebbe, 0xebc7, 0xebc0, 0xebc5, 0xbfe4, 0xbfe1, 0xebc1, + 0xeebf, 0xc1d0, 0xc1ce, 0xc1d1, 0xc1cf, 0xeebe, 0xeebb, 0xeeba, + 0xeebd, 0xeebc, 0xf145, 0xc2de, 0xf0fb, 0xf0fa, 0xc2d9, 0xf141, + 0xf140, 0xf0f7, 0xf143, 0xf0fc, 0xc2dd, 0xf0f9, 0xf142, 0xf0f8, + 0xc2da, 0xc2dc, 0xf0fd, 0xc2db, 0xf0fe, 0xf144, 0xf352, 0xc3de, + 0xf34f, 0xf353, 0xc3db, 0xf351, 0xc3e0, 0xc3dd, 0xf350, 0xc3df, + 0xf354, 0xc3da, 0xc4bc, 0xc4be, 0xf4d9, 0xc4bd, 0xf4d7, 0xc3dc, + 0xf4d8, 0xc4bb, 0xc543, 0xc545, 0xf656, 0xc544, 0xf655, 0xf761, + 0xc5ad, 0xf760, 0xc5ae, 0xf75e, 0xf75d, 0xf762, 0xf763, 0xf846, + 0xf75f, 0xf8c6, 0xf8c3, 0xf8c4, 0xf8c5, 0xc65c, 0xf951, 0xf950, + 0xf94f, 0xf970, 0xf9be, 0xf9ab, 0xc66e, 0xa8ad, 0xb060, 0xb8fa, + 0xbdf6, 0xebc8, 0xc2df, 0xf355, 0xf9ac, 0xa8ae, 0xaaee, 0xad79, + 0xad78, 0xb063, 0xd3e8, 0xb061, 0xd3e9, 0xb062, 0xd7df, 0xd7db, + 0xb36d, 0xd7de, 0xd7dd, 0xd7dc, 0xb36e, 0xd7e0, 0xd7e1, 0xdc43, + 0xdc41, 0xdc45, 0xdc46, 0xdc4c, 0xdc48, 0xdc4a, 0xdc42, 0xdbfc, + 0xdc49, 0xdc4b, 0xdc44, 0xdc47, 0xdbfd, 0xb662, 0xdc40, 0xdbfe, + 0xb661, 0xb663, 0xb8fd, 0xe075, 0xe077, 0xe076, 0xe07b, 0xb8fb, + 0xe078, 0xe074, 0xe079, 0xe07a, 0xb8fc, 0xb8fe, 0xe07c, 0xe467, + 0xe466, 0xe464, 0xe465, 0xbbb3, 0xbbb5, 0xbbb2, 0xbbb4, 0xe84d, + 0xe84e, 0xe849, 0xe84a, 0xbdf8, 0xbdfd, 0xbdf7, 0xbdfe, 0xbdf9, + 0xe84b, 0xe84c, 0xe848, 0xbe40, 0xbdfb, 0xbdfa, 0xbdfc, 0xe847, + 0xebca, 0xbfe8, 0xebcc, 0xbfea, 0xebcf, 0xebcb, 0xebc9, 0xebce, + 0xbfe9, 0xebcd, 0xbfe7, 0xc1d3, 0xc1d6, 0xeec1, 0xc1d4, 0xeec0, + 0xc1d2, 0xc1d5, 0xf146, 0xf147, 0xf148, 0xc2e0, 0xf149, 0xc2e1, + 0xc3e2, 0xf358, 0xf359, 0xf357, 0xf356, 0xf35a, 0xc3e1, 0xf4dd, + 0xf4db, 0xf4dc, 0xf4de, 0xf4da, 0xf4df, 0xf658, 0xf659, 0xf657, + 0xc546, 0xf764, 0xc5af, 0xf765, 0xf848, 0xf847, 0xa8af, 0xb664, + 0xb940, 0xbbb6, 0xbfec, 0xbfeb, 0xc3e3, 0xc47c, 0xc547, 0xa8b0, + 0xb064, 0xb941, 0xf35b, 0xcba6, 0xa8b1, 0xa8b4, 0xa8b3, 0xa8b2, + 0xcba5, 0xcdcd, 0xcdcf, 0xaaef, 0xaaf1, 0xcdcc, 0xcdce, 0xaaf0, + 0xcdd1, 0xcdd0, 0xcdd2, 0xd0b6, 0xd0b4, 0xad7c, 0xd0b3, 0xada3, + 0xad7e, 0xad7b, 0xada4, 0xad7d, 0xada2, 0xada1, 0xd0b5, 0xad7a, + 0xb06a, 0xd3eb, 0xd3f1, 0xb067, 0xb06e, 0xb069, 0xd3ee, 0xd3f0, + 0xb06c, 0xd3ea, 0xd3ed, 0xb068, 0xb065, 0xd3ec, 0xb06b, 0xd3ef, + 0xb06d, 0xb066, 0xd7e3, 0xd7e6, 0xb370, 0xb37a, 0xb376, 0xd7e4, + 0xb37e, 0xb377, 0xb37c, 0xb372, 0xb36f, 0xb371, 0xb37d, 0xd7e5, + 0xb375, 0xb378, 0xb374, 0xb379, 0xd7e7, 0xb37b, 0xb373, 0xd7e2, + 0xdc4d, 0xb665, 0xdc4f, 0xb667, 0xb669, 0xdc4e, 0xb666, 0xb66a, + 0xb668, 0xb947, 0xe0a3, 0xb94f, 0xe07e, 0xb950, 0xb945, 0xe0a1, + 0xb94a, 0xe0a2, 0xb943, 0xb942, 0xb94d, 0xb94c, 0xb94b, 0xb949, + 0xb94e, 0xe07d, 0xb944, 0xb946, 0xb948, 0xbbb8, 0xbbbb, 0xbbbf, + 0xbbb9, 0xbbbe, 0xbbbc, 0xbbb7, 0xbbbd, 0xbbba, 0xe852, 0xbe43, + 0xbe41, 0xe853, 0xbe44, 0xbe42, 0xe851, 0xe850, 0xbff0, 0xe84f, + 0xbfee, 0xbfed, 0xebd0, 0xbe45, 0xbfef, 0xebd1, 0xbff2, 0xebd2, + 0xbff1, 0xc1d8, 0xeec3, 0xc1d7, 0xc1dc, 0xc1da, 0xc1db, 0xc2e3, + 0xc1d9, 0xeec2, 0xebd3, 0xc2e2, 0xc2e4, 0xc3e4, 0xc3e5, 0xf4e0, + 0xc5de, 0xc5dd, 0xa8b6, 0xca55, 0xb06f, 0xca52, 0xca53, 0xca51, + 0xca54, 0xcbaa, 0xcba7, 0xcbac, 0xcba8, 0xa8b7, 0xa8ba, 0xcba9, + 0xa8b9, 0xcbab, 0xa8b8, 0xcdd5, 0xcdd7, 0xaaf4, 0xcdd3, 0xcdd6, + 0xcdd4, 0xaaf2, 0xaaf5, 0xaaf3, 0xd0b8, 0xd0bc, 0xd0b9, 0xada7, + 0xada8, 0xd0bb, 0xd0bd, 0xd0bf, 0xada5, 0xd0be, 0xada6, 0xd7ee, + 0xd0ba, 0xd3f2, 0xd3fb, 0xd3f9, 0xd3f4, 0xd3f5, 0xd3fa, 0xd3fc, + 0xb071, 0xd3f7, 0xd3f3, 0xb070, 0xb072, 0xd3f6, 0xd3fd, 0xd3f8, + 0xb3a1, 0xd7f1, 0xd7e9, 0xd7ef, 0xd7f0, 0xb3a2, 0xd7e8, 0xd7ea, + 0xd0b7, 0xd7ec, 0xd7ed, 0xd7eb, 0xb66c, 0xdc56, 0xebd4, 0xdc57, + 0xdc54, 0xb3a3, 0xb66e, 0xdc53, 0xdc59, 0xdc58, 0xb66b, 0xdc5c, + 0xdc52, 0xdc5b, 0xdc50, 0xdc5a, 0xdc55, 0xb66d, 0xe0aa, 0xe0a5, + 0xe0ab, 0xe0a6, 0xe0a4, 0xe0a7, 0xb951, 0xe0a9, 0xe0a8, 0xb952, + 0xbbc1, 0xbbc0, 0xe46e, 0xe471, 0xe469, 0xe46d, 0xbbc2, 0xe46c, + 0xe46a, 0xe470, 0xe46b, 0xe468, 0xe46f, 0xe859, 0xbe48, 0xf14a, + 0xe856, 0xe857, 0xe855, 0xdc51, 0xbe47, 0xe85a, 0xe854, 0xbe46, + 0xbe49, 0xe858, 0xebd5, 0xbff3, 0xebd6, 0xebd7, 0xeec4, 0xc1dd, + 0xf14b, 0xf14c, 0xf14d, 0xf35d, 0xf35c, 0xf4e2, 0xf4e1, 0xf65b, + 0xf65c, 0xf65a, 0xf766, 0xc5b0, 0xa8bb, 0xadaa, 0xada9, 0xb075, + 0xb074, 0xd440, 0xd441, 0xd3fe, 0xb073, 0xd7f5, 0xd7f6, 0xd7f2, + 0xb3a4, 0xd7f3, 0xd7f4, 0xdc5f, 0xdc61, 0xdc5d, 0xdc60, 0xb66f, + 0xdc5e, 0xb670, 0xdd73, 0xb955, 0xb954, 0xb953, 0xe0ac, 0xe0ad, + 0xe473, 0xe475, 0xbbc6, 0xbbc3, 0xbbc5, 0xbbc4, 0xe474, 0xe472, + 0xe861, 0xe85e, 0xe85f, 0xbe4d, 0xe860, 0xe85b, 0xe85c, 0xbe4a, + 0xbe4b, 0xe85d, 0xbe4c, 0xebdb, 0xebdc, 0xebd9, 0xebda, 0xbff4, + 0xebd8, 0xeec8, 0xeec5, 0xeec7, 0xc1e0, 0xeecb, 0xc1df, 0xeec9, + 0xeecc, 0xeeca, 0xeec6, 0xc1de, 0xf14f, 0xf150, 0xf14e, 0xf152, + 0xc2e5, 0xc2e6, 0xf35f, 0xc3e7, 0xf151, 0xf35e, 0xc3e6, 0xf4e5, + 0xf4e6, 0xc4bf, 0xf4e4, 0xf4e3, 0xf65d, 0xc548, 0xf849, 0xf8c8, + 0xf8c7, 0xc643, 0xc65d, 0xf8c9, 0xf971, 0xc66f, 0xa8bc, 0xaaf6, + 0xb956, 0xc4c0, 0xa8bd, 0xadab, 0xb3a5, 0xb671, 0xc2e7, 0xaaf7, + 0xd0c1, 0xd0c0, 0xd442, 0xb078, 0xb076, 0xb07a, 0xd444, 0xb079, + 0xb077, 0xd443, 0xb3a8, 0xd7fc, 0xb3a7, 0xb3a9, 0xd842, 0xb3ab, + 0xd7fe, 0xd840, 0xd7f7, 0xb3aa, 0xd843, 0xd7f9, 0xd7fa, 0xd7f8, + 0xb3a6, 0xd841, 0xd7fb, 0xd7fd, 0xdc6d, 0xdc6c, 0xdc6a, 0xdc62, + 0xdc71, 0xdc65, 0xdc6f, 0xdc76, 0xdc6e, 0xb679, 0xb675, 0xdc63, + 0xdc69, 0xb677, 0xdc68, 0xb678, 0xb67a, 0xdc6b, 0xb672, 0xb673, + 0xdc77, 0xdc75, 0xdc74, 0xdc66, 0xdc72, 0xb676, 0xb674, 0xdc73, + 0xdc64, 0xdc67, 0xdc70, 0xe4ba, 0xe0b7, 0xe0b0, 0xe0c3, 0xe0cc, + 0xe0b3, 0xb961, 0xe0c0, 0xb957, 0xb959, 0xb965, 0xe0b1, 0xb95a, + 0xb95c, 0xb966, 0xb95b, 0xb964, 0xe0b9, 0xe0ae, 0xb962, 0xe0b8, + 0xb95e, 0xe0ca, 0xb963, 0xe0c8, 0xe0bc, 0xe0c6, 0xb960, 0xe0af, + 0xe0c9, 0xe0c4, 0xe0cb, 0xb958, 0xb967, 0xb95d, 0xe0b5, 0xe0bd, + 0xe0c1, 0xe0c5, 0xb95f, 0xe0b4, 0xe0b2, 0xe0be, 0xe0bb, 0xe0ba, + 0xe0bf, 0xe0c2, 0xe0c7, 0xe478, 0xbbc7, 0xe4a4, 0xe47a, 0xbbcc, + 0xbbd0, 0xe4ad, 0xe4b5, 0xe4a6, 0xbbc8, 0xe4aa, 0xe0b6, 0xbbc9, + 0xe4b1, 0xe4b6, 0xe4ae, 0xe4b0, 0xe4b9, 0xe4b2, 0xe47e, 0xe4a9, + 0xbbd1, 0xbbcd, 0xe47c, 0xe4ab, 0xbbcb, 0xe4a5, 0xbbca, 0xe4b3, + 0xe4a2, 0xe479, 0xbbce, 0xe4b8, 0xe47b, 0xe4af, 0xe4ac, 0xe4a7, + 0xe477, 0xe476, 0xe4a1, 0xe4b4, 0xbbcf, 0xe4b7, 0xe47d, 0xe4a3, + 0xbe52, 0xbe5a, 0xbe55, 0xe8a4, 0xe8a1, 0xe867, 0xbe50, 0xbe4f, + 0xbe56, 0xe865, 0xbe54, 0xe871, 0xe863, 0xe864, 0xbe4e, 0xe8a3, + 0xbe58, 0xe874, 0xe879, 0xe873, 0xebee, 0xe86f, 0xe877, 0xe875, + 0xe868, 0xe862, 0xe87d, 0xbe57, 0xe87e, 0xe878, 0xe86d, 0xe86b, + 0xe866, 0xe86e, 0xe87b, 0xe86a, 0xe87a, 0xe8a2, 0xbe53, 0xe876, + 0xe87c, 0xe872, 0xe86c, 0xbe51, 0xe4a8, 0xe870, 0xbe59, 0xe869, + 0xebf4, 0xbff7, 0xebf3, 0xebf0, 0xec44, 0xbffb, 0xec41, 0xebf8, + 0xec43, 0xebe9, 0xebf6, 0xbffd, 0xebe1, 0xebdf, 0xec42, 0xec40, + 0xebfe, 0xebed, 0xebec, 0xebe2, 0xc040, 0xebe8, 0xebf2, 0xebfd, + 0xc043, 0xec45, 0xc1e8, 0xc045, 0xbffe, 0xebe6, 0xebef, 0xebde, + 0xebe0, 0xbff5, 0xc042, 0xbffa, 0xebe7, 0xebf7, 0xebf1, 0xc041, + 0xebdd, 0xc1e3, 0xebf9, 0xebfc, 0xbffc, 0xebeb, 0xc044, 0xbff9, + 0xbff8, 0xebf5, 0xebfb, 0xbff6, 0xebe4, 0xebfa, 0xebe5, 0xebea, + 0xeed2, 0xeed7, 0xc1e5, 0xc1e7, 0xeedd, 0xc1e1, 0xeeec, 0xeee3, + 0xeed8, 0xeed9, 0xeee2, 0xc1ee, 0xeee1, 0xeed1, 0xeee0, 0xeed4, + 0xeeed, 0xc1ed, 0xc1eb, 0xeed5, 0xeee8, 0xeeda, 0xeee7, 0xeee9, + 0xeed0, 0xc1e6, 0xeeea, 0xeede, 0xc1ea, 0xeedb, 0xc1ec, 0xeee4, + 0xc1e4, 0xeed6, 0xeee5, 0xeedf, 0xebe3, 0xeee6, 0xeed3, 0xc1e9, + 0xeeeb, 0xc1e2, 0xeece, 0xf160, 0xf159, 0xc2e9, 0xf154, 0xf163, + 0xf15b, 0xeedc, 0xf165, 0xf155, 0xc2e8, 0xf15f, 0xc2ea, 0xc2f2, + 0xc2f0, 0xf161, 0xc2f1, 0xf157, 0xf158, 0xf15d, 0xf162, 0xeecd, + 0xc2eb, 0xf16a, 0xf167, 0xf16b, 0xf15e, 0xf15a, 0xf168, 0xf36a, + 0xf15c, 0xc2ee, 0xc2ed, 0xeecf, 0xc2ef, 0xf164, 0xf166, 0xc2ec, + 0xf169, 0xf153, 0xf156, 0xf373, 0xf363, 0xc3eb, 0xf371, 0xf361, + 0xc3ec, 0xf36c, 0xf368, 0xc3f1, 0xf372, 0xf362, 0xf365, 0xc3e9, + 0xf374, 0xf36d, 0xf370, 0xc3ef, 0xc3f4, 0xc3f2, 0xf369, 0xf364, + 0xc3ed, 0xc3ee, 0xf360, 0xc3ea, 0xc3e8, 0xc3f0, 0xf36f, 0xc3f3, + 0xf36b, 0xf375, 0xc3f5, 0xf367, 0xf36e, 0xf4f3, 0xf542, 0xf4f5, + 0xf4fc, 0xf366, 0xf4fa, 0xf4e9, 0xf540, 0xc4c3, 0xf4ed, 0xf4fe, + 0xf4f4, 0xc4c2, 0xf544, 0xf4f6, 0xf4fb, 0xf4fd, 0xf4e7, 0xf541, + 0xf4f2, 0xf4f7, 0xf4eb, 0xf4ef, 0xf543, 0xf4f9, 0xf4e8, 0xf4ec, + 0xf4ee, 0xf4f8, 0xc4c1, 0xf4f1, 0xf4ea, 0xf4f0, 0xf661, 0xf666, + 0xc54f, 0xf668, 0xc549, 0xf664, 0xf66a, 0xc54e, 0xc54a, 0xc54b, + 0xf660, 0xf667, 0xc54d, 0xf665, 0xc54c, 0xf65f, 0xf663, 0xf662, + 0xf65e, 0xf669, 0xc5b1, 0xf76d, 0xf770, 0xf76c, 0xf76e, 0xf76f, + 0xf769, 0xf76a, 0xf767, 0xf76b, 0xf768, 0xc5b2, 0xc5b3, 0xf84b, + 0xf84d, 0xf84c, 0xf84e, 0xc5e0, 0xf84a, 0xc5df, 0xc5e1, 0xf8cb, + 0xf8cc, 0xc644, 0xf8ca, 0xf953, 0xf952, 0xf954, 0xc65f, 0xf955, + 0xc65e, 0xf956, 0xf972, 0xf975, 0xf974, 0xc668, 0xf973, 0xc672, + 0xc670, 0xc671, 0xc677, 0xf9c0, 0xf9c1, 0xf9bf, 0xf9c9, 0xaaf8, + 0xd844, 0xdc78, 0xe8a5, 0xf376, 0xaaf9, 0xadac, 0xb07b, 0xd845, + 0xd846, 0xb3ac, 0xb67d, 0xdc7a, 0xdc79, 0xb6a3, 0xb67c, 0xdc7b, + 0xb67e, 0xb6a2, 0xb6a1, 0xb67b, 0xb968, 0xe0d0, 0xe0ce, 0xe0cf, + 0xe0cd, 0xbbd2, 0xbbd5, 0xbbd7, 0xbbd6, 0xbbd3, 0xbbd4, 0xe8a7, + 0xe8a6, 0xbe5b, 0xe8a8, 0xe8a9, 0xbe5c, 0xec4d, 0xec4b, 0xeef3, + 0xec49, 0xec4a, 0xc046, 0xec46, 0xec4e, 0xec48, 0xec4c, 0xeeef, + 0xeef1, 0xeef2, 0xc1f3, 0xeeee, 0xc1f2, 0xeef0, 0xc1ef, 0xc1f0, + 0xc1f1, 0xec47, 0xc2f5, 0xf16e, 0xf16c, 0xf16d, 0xc2f3, 0xc2f6, + 0xc2f4, 0xf377, 0xf378, 0xc3f6, 0xf545, 0xf547, 0xf546, 0xc4c4, + 0xc550, 0xf66d, 0xf66c, 0xf66b, 0xaafa, 0xc9aa, 0xca58, 0xa6e9, + 0xca56, 0xca59, 0xca57, 0xcbae, 0xa8c1, 0xa8c2, 0xcbb0, 0xa8bf, + 0xcbaf, 0xcbad, 0xa8c0, 0xa8be, 0xcdd8, 0xcddb, 0xaafd, 0xcdda, + 0xcdd9, 0xaafc, 0xaafb, 0xab40, 0xcddc, 0xaafe, 0xd0c6, 0xadae, + 0xadaf, 0xadb0, 0xd0c7, 0xd0c3, 0xadad, 0xd0c4, 0xd0c5, 0xd0c2, + 0xb0a4, 0xb0a1, 0xd445, 0xb0a2, 0xb0a5, 0xd446, 0xb07e, 0xb07c, + 0xb07d, 0xb0a3, 0xb3ad, 0xd849, 0xb3b5, 0xd848, 0xd84b, 0xb3b1, + 0xd84a, 0xb6ab, 0xb3af, 0xb3b2, 0xb3ae, 0xb3b3, 0xb3b4, 0xb3b0, + 0xd847, 0xb6a7, 0xdc7d, 0xdca3, 0xdca2, 0xb6ac, 0xb6a8, 0xb6a9, + 0xdc7c, 0xdc7e, 0xdca1, 0xb6a4, 0xb6a6, 0xb6aa, 0xb6a5, 0xe0d3, + 0xe0d1, 0xe0d2, 0xb96a, 0xb96b, 0xe0d4, 0xb969, 0xbbd8, 0xbbda, + 0xbbd9, 0xe4bb, 0xe4bc, 0xe8ab, 0xe8aa, 0xc047, 0xc048, 0xec4f, + 0xc049, 0xeef6, 0xeef4, 0xeef5, 0xc1f4, 0xf16f, 0xc3f7, 0xc1f5, + 0xab41, 0xb0a6, 0xd447, 0xd84c, 0xb3b6, 0xb6ad, 0xdca4, 0xdca6, + 0xb6af, 0xb6ae, 0xb6b0, 0xb6b1, 0xdca5, 0xb96e, 0xb96f, 0xb96d, + 0xbbdb, 0xb96c, 0xe0d5, 0xbbdc, 0xe8ac, 0xec50, 0xc04a, 0xc1f6, + 0xf170, 0xf174, 0xc2f9, 0xf171, 0xc2fa, 0xc2f8, 0xf175, 0xc2fb, + 0xf173, 0xf379, 0xc2f7, 0xc3f8, 0xf8cd, 0xab42, 0xb3b8, 0xb3b7, + 0xb6b2, 0xdca8, 0xdca7, 0xb6b3, 0xe0d9, 0xb973, 0xb970, 0xe0d8, + 0xb972, 0xe0d6, 0xb971, 0xe0d7, 0xe4bd, 0xbbdd, 0xe8af, 0xbe5d, + 0xe8ad, 0xbe5e, 0xbe5f, 0xe8ae, 0xbe60, 0xec51, 0xc04e, 0xc04b, + 0xc050, 0xec53, 0xc04c, 0xec52, 0xc04f, 0xc04d, 0xeef9, 0xeefb, + 0xc1f7, 0xeefa, 0xc1f8, 0xeef8, 0xeef7, 0xf177, 0xf176, 0xc2fc, + 0xf178, 0xf37e, 0xc3fa, 0xf37d, 0xf37a, 0xc3f9, 0xf37b, 0xf37c, + 0xf548, 0xf549, 0xc4c5, 0xc553, 0xf66e, 0xc551, 0xc552, 0xf66f, + 0xc5b4, 0xc5b5, 0xf771, 0xc645, 0xf8cf, 0xc647, 0xf8ce, 0xf8d0, + 0xc646, 0xf957, 0xf9ad, 0xab43, 0xb974, 0xe4be, 0xe8b0, 0xc051, + 0xc052, 0xab44, 0xbe61, 0xc3fb, 0xadb1, 0xc053, 0xc5e2, 0xadb2, + 0xd84d, 0xdca9, 0xdcab, 0xdcaa, 0xe0dd, 0xe0da, 0xb975, 0xb976, + 0xe0db, 0xe0dc, 0xe4c0, 0xe4c5, 0xbbde, 0xe4bf, 0xe4c1, 0xe4c8, + 0xe4c3, 0xe4c7, 0xe4c4, 0xe4c2, 0xe4c6, 0xbbdf, 0xe8b3, 0xe8b1, + 0xbe63, 0xbe62, 0xe8b2, 0xbe64, 0xec56, 0xec55, 0xc054, 0xec54, + 0xeefc, 0xeefe, 0xef41, 0xef40, 0xc1f9, 0xeefd, 0xf1a1, 0xc2fd, + 0xf17d, 0xf1a2, 0xc2fe, 0xf17b, 0xf17e, 0xf17c, 0xf179, 0xc340, + 0xf17a, 0xf3a1, 0xf3a3, 0xf3a2, 0xf54a, 0xf54b, 0xf670, 0xc5b7, + 0xc5b6, 0xf84f, 0xf850, 0xc648, 0xf8d1, 0xc669, 0xadb3, 0xb6b4, + 0xe4ca, 0xe4c9, 0xe8b5, 0xe8b4, 0xc1fa, 0xef43, 0xef42, 0xf1a5, + 0xf1a3, 0xf1a6, 0xf1a4, 0xc3fc, 0xf3a4, 0xf3a5, 0xf3a6, 0xf671, + 0xf772, 0xf8d2, 0xadb4, 0xec57, 0xef44, 0xadb5, 0xbbe0, 0xec58, + 0xc341, 0xf1a7, 0xc3fd, 0xf54c, 0xf54d, 0xc554, 0xf851, 0xadb6, + 0xb3bb, 0xb3bc, 0xd84e, 0xb6b5, 0xb6b6, 0xdcac, 0xb6b7, 0xb97a, + 0xb97c, 0xe0df, 0xe0e0, 0xe0de, 0xb977, 0xb978, 0xb97b, 0xb979, + 0xe4cb, 0xbbe1, 0xbbe2, 0xe8bc, 0xbe67, 0xe8b7, 0xe8b6, 0xe8bb, + 0xbe65, 0xc05b, 0xe8b8, 0xe8bd, 0xe8ba, 0xe8b9, 0xbe66, 0xc059, + 0xec5a, 0xc055, 0xec5b, 0xec59, 0xc058, 0xc056, 0xc05a, 0xc057, + 0xef45, 0xef4a, 0xef46, 0xef49, 0xc1fb, 0xedd4, 0xef48, 0xef47, + 0xc344, 0xc342, 0xc345, 0xc343, 0xf1a8, 0xf1a9, 0xf1aa, 0xc346, + 0xf3aa, 0xc440, 0xf3a8, 0xc441, 0xf3a7, 0xf3a9, 0xc3fe, 0xf551, + 0xf54e, 0xf54f, 0xf550, 0xf672, 0xc556, 0xc555, 0xf774, 0xf773, + 0xc5b8, 0xc5e3, 0xc649, 0xc660, 0xf958, 0xf9ae, 0xf9af, 0xadb7, + 0xdcad, 0xe0e1, 0xe4cc, 0xe4cd, 0xbbe3, 0xbbe4, 0xe8be, 0xbe68, + 0xc1fc, 0xf1ab, 0xc347, 0xf3ad, 0xc442, 0xf3ac, 0xf3ae, 0xf3ab, + 0xf675, 0xf552, 0xf553, 0xc4c6, 0xf674, 0xf673, 0xf775, 0xf9b0, + 0xadb8, 0xadb9, 0xb0a7, 0xd448, 0xd84f, 0xb6b8, 0xb6bb, 0xb6b9, + 0xdcae, 0xb6bd, 0xb6ba, 0xb6bc, 0xb97e, 0xe0e2, 0xe0e3, 0xe8c0, + 0xb97d, 0xb9a1, 0xb9a2, 0xe4cf, 0xe4ce, 0xbbe5, 0xbbe6, 0xe4d0, + 0xe8bf, 0xbbe8, 0xbe69, 0xbbe7, 0xc05c, 0xe8c1, 0xbe6b, 0xbe6a, + 0xe8c2, 0xe8c5, 0xe8c3, 0xe8c4, 0xbe6c, 0xc061, 0xc05f, 0xc05e, + 0xec5d, 0xc060, 0xec5c, 0xef4b, 0xec5e, 0xc05d, 0xec5f, 0xef4e, + 0xef4c, 0xef4d, 0xef52, 0xc34b, 0xef51, 0xef54, 0xef53, 0xef50, + 0xef4f, 0xc1fd, 0xf1ae, 0xf1ad, 0xc34a, 0xc348, 0xc349, 0xf1ac, + 0xf3b1, 0xc443, 0xf3b0, 0xf3af, 0xc444, 0xf558, 0xf557, 0xf555, + 0xf554, 0xc4c8, 0xc4c7, 0xf559, 0xf776, 0xc5b9, 0xf677, 0xc557, + 0xf676, 0xf556, 0xf777, 0xc5e4, 0xc661, 0xf959, 0xf9b1, 0xadba, + 0xd850, 0xef55, 0xadbb, 0xe4d2, 0xe4d1, 0xec60, 0xef57, 0xef56, + 0xc34c, 0xf3b2, 0xf3b3, 0xc4c9, 0xf9b2, 0xb0a8, 0xb6bf, 0xb6be, + 0xe0e4, 0xe0e6, 0xb9a4, 0xe0e5, 0xb9a3, 0xb9a5, 0xe0e7, 0xe4d4, + 0xe4d6, 0xe4d5, 0xe4d8, 0xbbe9, 0xe4d7, 0xe4d3, 0xe4d9, 0xe8cc, + 0xe8cf, 0xe8d1, 0xe8c7, 0xe8cb, 0xe8c8, 0xbe6e, 0xbe71, 0xbe73, + 0xe8c9, 0xe8ca, 0xbe72, 0xe8cd, 0xe8d0, 0xe8ce, 0xbe74, 0xbe70, + 0xe8c6, 0xbe6d, 0xbe6f, 0xc063, 0xec66, 0xec64, 0xec63, 0xec69, + 0xec68, 0xec67, 0xec62, 0xc062, 0xec61, 0xec65, 0xc064, 0xef5a, + 0xef5e, 0xef5b, 0xef5d, 0xef5c, 0xef59, 0xef5f, 0xef62, 0xef60, + 0xef61, 0xc240, 0xc1fe, 0xef58, 0xef63, 0xf1b3, 0xf1b6, 0xf1b8, + 0xf1b7, 0xf1b1, 0xf1b5, 0xf1b0, 0xf1b2, 0xc34d, 0xf1af, 0xf1b4, + 0xf3c0, 0xf3b5, 0xc445, 0xc446, 0xf3b4, 0xf3b9, 0xf3bf, 0xf3b7, + 0xf3be, 0xf3bb, 0xf3ba, 0xf3bd, 0xf3b8, 0xf3b6, 0xf3bc, 0xf560, + 0xf55e, 0xc4ca, 0xf55d, 0xf563, 0xf561, 0xc4cb, 0xf55c, 0xf55a, + 0xf55b, 0xc4cd, 0xf55f, 0xc4cc, 0xf562, 0xf678, 0xf67e, 0xf679, + 0xc55b, 0xf6a1, 0xc55a, 0xf67d, 0xf67c, 0xc559, 0xf67b, 0xc558, + 0xf67a, 0xf77d, 0xf7a1, 0xf77e, 0xf77b, 0xc5bb, 0xf778, 0xf77c, + 0xf7a3, 0xf7a2, 0xf779, 0xf77a, 0xc5ba, 0xf852, 0xc5e7, 0xf853, + 0xc5e5, 0xc5e6, 0xf8d3, 0xc64a, 0xf976, 0xc66a, 0xf9b3, 0xc66b, + 0xf9b4, 0xf9b5, 0xf9c3, 0xf9c2, 0xc67a, 0xf9cd, 0xb0a9, 0xe0e9, + 0xe0e8, 0xbbea, 0xbbeb, 0xe4da, 0xe8d2, 0xec6c, 0xbe75, 0xc065, + 0xec6a, 0xec6d, 0xc066, 0xef64, 0xec6b, 0xf1b9, 0xc34e, 0xf3c1, + 0xf566, 0xf564, 0xf565, 0xf6a2, 0xc55c, 0xf7a4, 0xc5ea, 0xc5bc, + 0xc5e8, 0xc5e9, 0xf8d4, 0xc662, 0xb0aa, 0xf1ba, 0xd449, 0xb9a6, + 0xe4db, 0xbbec, 0xe4dc, 0xe8d4, 0xe8d3, 0xc068, 0xbe76, 0xbe77, + 0xe8d7, 0xe8d6, 0xe8d5, 0xec6e, 0xec71, 0xec70, 0xec6f, 0xc067, + 0xef68, 0xef66, 0xef65, 0xef67, 0xc34f, 0xf1bc, 0xf1bd, 0xc350, + 0xf1bb, 0xf3c3, 0xf3c2, 0xf3c5, 0xc447, 0xf3c4, 0xf567, 0xf569, + 0xf568, 0xf6a3, 0xf6a6, 0xf6a4, 0xf6a5, 0xf7a5, 0xc5bd, 0xf854, + 0xf855, 0xf856, 0xc64b, 0xc663, 0xf9b6, 0xb0ab, 0xbe78, 0xc069, + 0xf1be, 0xf7a6, 0xf9c4, 0xd44a, 0xc67b, 0xb0ac, 0xec72, 0xf1bf, + 0xf3c6, 0xf6a7, 0xf7a7, 0xb0ad, 0xe4dd, 0xe4de, 0xbbed, 0xbbee, + 0xe8d9, 0xbe7a, 0xbe79, 0xe8d8, 0xef69, 0xf1c0, 0xf1c2, 0xf1c1, + 0xc353, 0xc352, 0xc351, 0xc55e, 0xf6a8, 0xc55d, 0xf7a9, 0xf7a8, + 0xc64c, 0xf8d5, 0xb3bd, 0xe0ea, 0xe4e1, 0xe4df, 0xe4e0, 0xe8e2, + 0xe8dd, 0xe8da, 0xe8e1, 0xe8e3, 0xbe7c, 0xe8e0, 0xe8dc, 0xe8db, + 0xe8df, 0xe8de, 0xbe7b, 0xec7d, 0xec78, 0xec76, 0xeca1, 0xec77, + 0xec73, 0xec79, 0xec74, 0xef72, 0xec75, 0xeca2, 0xec7c, 0xc06a, + 0xec7b, 0xec7a, 0xec7e, 0xef6a, 0xef6d, 0xef6c, 0xef74, 0xef6f, + 0xef73, 0xef71, 0xef70, 0xef6e, 0xef6b, 0xc243, 0xc242, 0xc244, + 0xc241, 0xef75, 0xf1c8, 0xf1cb, 0xf1c9, 0xf1cd, 0xf1ce, 0xf1c6, + 0xc358, 0xf1c7, 0xf1c5, 0xf1cc, 0xf1c4, 0xf1c3, 0xc357, 0xc355, + 0xc354, 0xf1ca, 0xf3cf, 0xf3d5, 0xc44a, 0xf3d0, 0xf3d3, 0xf3d7, + 0xc44b, 0xf3d2, 0xf3ca, 0xf3c9, 0xf3d6, 0xf3cd, 0xf3cb, 0xf3d4, + 0xf3cc, 0xc449, 0xc448, 0xf3c7, 0xf3c8, 0xf3d1, 0xf3ce, 0xf56c, + 0xf56f, 0xc356, 0xf56d, 0xf573, 0xf571, 0xf56b, 0xf576, 0xf56a, + 0xc4cf, 0xf572, 0xf56e, 0xc4ce, 0xf575, 0xf574, 0xf6ab, 0xf6aa, + 0xf6b1, 0xf6ad, 0xf6b0, 0xc560, 0xf6ae, 0xf6af, 0xf6a9, 0xf6ac, + 0xc55f, 0xc5bf, 0xf7b4, 0xf7af, 0xf7b3, 0xf7b6, 0xf7b2, 0xf7ae, + 0xc5c1, 0xf7b1, 0xf7b5, 0xc5c0, 0xf7ac, 0xf570, 0xf7b0, 0xf7ad, + 0xf7aa, 0xf7ab, 0xc5be, 0xf85a, 0xf85c, 0xf85f, 0xf85b, 0xf860, + 0xf859, 0xf857, 0xc5eb, 0xf85d, 0xc5ed, 0xc5ec, 0xf858, 0xf85e, + 0xf8da, 0xc64d, 0xf8db, 0xf8d9, 0xf8d6, 0xf8d8, 0xf8d7, 0xf95a, + 0xf95c, 0xf95b, 0xf979, 0xf978, 0xf977, 0xf97a, 0xc673, 0xc674, + 0xf9ca, 0xf9ce, 0xb3be, 0xdcaf, 0xe0ed, 0xb9a7, 0xe0eb, 0xe0ec, + 0xe4e2, 0xe4e3, 0xbbf1, 0xbbef, 0xe4e4, 0xbbf0, 0xe8e8, 0xe8eb, + 0xe8e5, 0xe8ec, 0xe8e4, 0xe8e6, 0xe8e7, 0xe8ea, 0xbea1, 0xe8ef, + 0xe8ee, 0xbe7d, 0xe8e9, 0xe8ed, 0xbe7e, 0xecac, 0xc06f, 0xeca7, + 0xc06b, 0xeca4, 0xecaa, 0xecad, 0xc070, 0xeca9, 0xeca6, 0xecae, + 0xeca5, 0xecab, 0xc06c, 0xeca3, 0xc06d, 0xc06e, 0xeca8, 0xefa9, + 0xef7a, 0xef7b, 0xef7e, 0xef7c, 0xef76, 0xef79, 0xefa5, 0xef7d, + 0xc245, 0xefa7, 0xefa4, 0xc246, 0xefa6, 0xef77, 0xefa2, 0xefa3, + 0xefa1, 0xf1d2, 0xf1d4, 0xf1d7, 0xf1d1, 0xc359, 0xf1d9, 0xf1d0, + 0xf1da, 0xf1d6, 0xf1d8, 0xf1dc, 0xf1d5, 0xf1dd, 0xf1d3, 0xf1cf, + 0xc35a, 0xf1db, 0xc35b, 0xc44d, 0xef78, 0xf3f1, 0xf3e8, 0xc44f, + 0xf3e4, 0xc450, 0xf3ed, 0xf3e7, 0xf3dd, 0xc44e, 0xf3ea, 0xf3e5, + 0xf3e6, 0xf3d8, 0xf3df, 0xf3ee, 0xf3eb, 0xf3e3, 0xf3ef, 0xf3de, + 0xf3d9, 0xf3ec, 0xf3db, 0xf3e9, 0xf3e0, 0xf3f0, 0xf3dc, 0xc44c, + 0xf3da, 0xf3e1, 0xf3e2, 0xf57d, 0xf57b, 0xf5a2, 0xf5ae, 0xf5a5, + 0xf57c, 0xf578, 0xf5a7, 0xf57e, 0xf5a3, 0xf57a, 0xf5aa, 0xf577, + 0xf5a1, 0xf5a6, 0xf5a8, 0xf5ab, 0xf579, 0xf5af, 0xf5b0, 0xf5a9, + 0xf5ad, 0xf5a4, 0xf6c1, 0xf6c4, 0xc561, 0xf6c3, 0xf6c8, 0xf6c6, + 0xc562, 0xf6bd, 0xf6b3, 0xf6b2, 0xc564, 0xf6bf, 0xf6c0, 0xf6bc, + 0xf6b4, 0xf6b9, 0xf5ac, 0xf6b5, 0xc563, 0xf6bb, 0xf6ba, 0xf6b6, + 0xf6c2, 0xf6b7, 0xf7bb, 0xf6c5, 0xf6c7, 0xf6be, 0xf6b8, 0xf7bc, + 0xf7be, 0xf7b8, 0xc5c2, 0xf7c5, 0xf7c3, 0xc5c3, 0xf7c2, 0xf7c1, + 0xf7ba, 0xf7b7, 0xf7bd, 0xf7c6, 0xf7b9, 0xf7bf, 0xf869, 0xf86e, + 0xf864, 0xf867, 0xc5ee, 0xf86b, 0xf872, 0xf7c0, 0xf865, 0xf86f, + 0xf873, 0xf86a, 0xf863, 0xf86d, 0xf86c, 0xf871, 0xf870, 0xf7c4, + 0xf868, 0xf862, 0xf866, 0xc64e, 0xc64f, 0xf861, 0xf8e6, 0xf8dd, + 0xf8e5, 0xf8e2, 0xf8e3, 0xf8dc, 0xf8df, 0xf8e7, 0xf8e1, 0xf8e0, + 0xf8de, 0xf8e4, 0xf95d, 0xf95e, 0xf960, 0xf95f, 0xf962, 0xf961, + 0xf97c, 0xf97b, 0xf9b7, 0xf9b8, 0xf9c5, 0xc678, 0xc67c, 0xf9cf, + 0xc67d, 0xb3bf, 0xc4d0, 0xf6c9, 0xc650, 0xc651, 0xb3c0, 0xe0ee, + 0xb9a8, 0xe8f0, 0xecb0, 0xecb1, 0xecaf, 0xefab, 0xefaa, 0xc247, + 0xf1df, 0xefac, 0xf1de, 0xf3f3, 0xc451, 0xc453, 0xf3f2, 0xc452, + 0xf5b1, 0xf5b3, 0xf5b2, 0xf6ca, 0xc565, 0xc5ef, 0xf8e8, 0xf963, + 0xf9d2, 0xb3c1, 0xe4e5, 0xbea2, 0xecb3, 0xecb2, 0xefad, 0xc454, + 0xc4d1, 0xf7c7, 0xf9cb, 0xb3c2, 0xbbf2, 0xbea3, 0xf3f4, 0xf874, + 0xb6c0, 0xefae, 0xc664, 0xb6c1, 0xbea4, 0xc248, 0xf875, 0xb6c2, + 0xe8f1, 0xc072, 0xecb4, 0xecb5, 0xc071, 0xefaf, 0xc24c, 0xc24a, + 0xc24b, 0xc249, 0xf1e0, 0xc35c, 0xf5b5, 0xf5b4, 0xf5b7, 0xf5b6, + 0xc4d2, 0xf6cb, 0xf6cd, 0xf6cc, 0xc566, 0xf7c8, 0xf876, 0xf877, + 0xc5f0, 0xf964, 0xf97d, 0xc675, 0xdcb0, 0xecb6, 0xefb0, 0xf3f5, + 0xe0ef, 0xefb1, 0xf1e2, 0xf1e1, 0xf878, 0xc652, 0xf965, 0xf97e, + 0xb9a9, 0xe8f2, 0xe8f3, 0xecb7, 0xb9aa, 0xc35d, 0xf1e3, 0xf6cf, + 0xc567, 0xf6d0, 0xf6ce, 0xf879, 0xf8e9, 0xb9ab, 0xefb4, 0xefb3, + 0xefb2, 0xf1e4, 0xf1e8, 0xf1e7, 0xf1e6, 0xf1e5, 0xc35e, 0xf3f6, + 0xf5b9, 0xc4d3, 0xf5b8, 0xf6d1, 0xf7cb, 0xf7ca, 0xc5c4, 0xf7c9, + 0xf87c, 0xf87b, 0xf87a, 0xbbf3, 0xecb8, 0xc24d, 0xf3f7, 0xf3f8, + 0xf7cc, 0xf87d, 0xf8ea, 0xf966, 0xf9b9, 0xf9d4, 0xbbf4, 0xc24e, + 0xf1e9, 0xf3f9, 0xf6d2, 0xf87e, 0xbea6, 0xefb5, 0xf1ea, 0xf3fa, + 0xf3fb, 0xf3fc, 0xf5be, 0xf5ba, 0xc568, 0xf5bd, 0xf5bc, 0xc4d4, + 0xf5bb, 0xc4d6, 0xc4d5, 0xf6d4, 0xf6d3, 0xc569, 0xc56a, 0xc5c6, + 0xf7cd, 0xc5c5, 0xf8a3, 0xf8a4, 0xf8a2, 0xf8a1, 0xc654, 0xf8eb, + 0xf8ec, 0xf8ed, 0xc653, 0xf967, 0xf96a, 0xf969, 0xf968, 0xf9d3, + 0xc073, 0xc365, 0xf5bf, 0xf6d5, 0xc5c7, 0xf7ce, 0xf9d5, 0xc074, + 0xefb6, 0xf7cf, 0xf9a1, 0xc94a, 0xddfc, 0xa14a, 0xa157, 0xa159, + 0xa15b, 0xa15f, 0xa160, 0xa163, 0xa164, 0xa167, 0xa168, 0xa16b, + 0xa16c, 0xa16f, 0xa170, 0xa173, 0xa174, 0xa177, 0xa178, 0xa17b, + 0xa17c, 0xa1c6, 0xa1c7, 0xa1ca, 0xa1cb, 0xa1c8, 0xa1c9, 0xa15c, + 0xa14d, 0xa14f, 0xa151, 0xa152, 0xa153, 0xa154, 0xa17d, 0xa17e, + 0xa1a1, 0xa1a2, 0xa1a3, 0xa1a4, 0xa1cc, 0xa1cd, 0xa1ce, 0xa1de, + 0xa1df, 0xa1e0, 0xa1e1, 0xa1e2, 0xa24c, 0xa24d, 0xa24e, 0xa149, + 0xa1ad, 0xa243, 0xa248, 0xa1ae, 0xa15d, 0xa15e, 0xa1af, 0xa1cf, + 0xa141, 0xa1d0, 0xa144, 0xa241, 0xa2af, 0xa2b0, 0xa2b1, 0xa2b2, + 0xa2b3, 0xa2b4, 0xa2b5, 0xa2b6, 0xa2b7, 0xa2b8, 0xa147, 0xa146, + 0xa1d5, 0xa1d7, 0xa1d6, 0xa148, 0xa249, 0xa2cf, 0xa2d0, 0xa2d1, + 0xa2d2, 0xa2d3, 0xa2d4, 0xa2d5, 0xa2d6, 0xa2d7, 0xa2d8, 0xa2d9, + 0xa2da, 0xa2db, 0xa2dc, 0xa2dd, 0xa2de, 0xa2df, 0xa2e0, 0xa2e1, + 0xa2e2, 0xa2e3, 0xa2e4, 0xa2e5, 0xa2e6, 0xa2e7, 0xa2e8, 0xa242, + 0xa1c4, 0xa2e9, 0xa2ea, 0xa2eb, 0xa2ec, 0xa2ed, 0xa2ee, 0xa2ef, + 0xa2f0, 0xa2f1, 0xa2f2, 0xa2f3, 0xa2f4, 0xa2f5, 0xa2f6, 0xa2f7, + 0xa2f8, 0xa2f9, 0xa2fa, 0xa2fb, 0xa2fc, 0xa2fd, 0xa2fe, 0xa340, + 0xa341, 0xa342, 0xa343, 0xa161, 0xa155, 0xa162, 0xa14e, +}; + +static const Summary16 big5_uni2indx_page00[16] = { + /* 0x0000 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x00ac }, { 4, 0x0083 }, + { 7, 0x0000 }, { 7, 0x0080 }, { 8, 0x0000 }, { 8, 0x0080 }, +}; +static const Summary16 big5_uni2indx_page02[38] = { + /* 0x0200 */ + { 9, 0x0000 }, { 9, 0x0000 }, { 9, 0x0000 }, { 9, 0x0000 }, + { 9, 0x0000 }, { 9, 0x0000 }, { 9, 0x0000 }, { 9, 0x0000 }, + { 9, 0x0000 }, { 9, 0x0000 }, { 9, 0x0000 }, { 9, 0x0000 }, + { 9, 0x0e80 }, { 13, 0x0200 }, { 14, 0x0000 }, { 14, 0x0000 }, + /* 0x0300 */ + { 14, 0x0000 }, { 14, 0x0000 }, { 14, 0x0000 }, { 14, 0x0000 }, + { 14, 0x0000 }, { 14, 0x0000 }, { 14, 0x0000 }, { 14, 0x0000 }, + { 14, 0x0000 }, { 14, 0xfffe }, { 29, 0x03fb }, { 38, 0xfffe }, + { 53, 0x03fb }, { 62, 0x0000 }, { 62, 0x0000 }, { 62, 0x0000 }, + /* 0x0400 */ + { 62, 0x0002 }, { 63, 0x1ff0 }, { 72, 0xfff8 }, { 85, 0xffff }, + { 101, 0xffff }, { 117, 0x0002 }, +}; +static const Summary16 big5_uni2indx_page20[44] = { + /* 0x2000 */ + { 118, 0x0000 }, { 118, 0x3318 }, { 124, 0x0064 }, { 127, 0x4824 }, + { 131, 0x0000 }, { 131, 0x0000 }, { 131, 0x0000 }, { 131, 0x0000 }, + { 131, 0x0000 }, { 131, 0x0000 }, { 131, 0x0000 }, { 131, 0x0000 }, + { 131, 0x0000 }, { 131, 0x0000 }, { 131, 0x0000 }, { 131, 0x0000 }, + /* 0x2100 */ + { 131, 0x0228 }, { 134, 0x0000 }, { 134, 0x0000 }, { 134, 0x0000 }, + { 134, 0x0000 }, { 134, 0x0000 }, { 134, 0x03ff }, { 144, 0x0000 }, + { 144, 0x0000 }, { 144, 0x03cf }, { 152, 0x0000 }, { 152, 0x0000 }, + { 152, 0x0000 }, { 152, 0x0000 }, { 152, 0x0000 }, { 152, 0x0000 }, + /* 0x2200 */ + { 152, 0x0000 }, { 152, 0xc400 }, { 155, 0x4e29 }, { 162, 0x1030 }, + { 165, 0x0000 }, { 165, 0x0004 }, { 166, 0x00c3 }, { 170, 0x0000 }, + { 170, 0x0000 }, { 170, 0x0000 }, { 170, 0x0020 }, { 171, 0x8000 }, +}; +static const Summary16 big5_uni2indx_page24[37] = { + /* 0x2400 */ + { 172, 0x0000 }, { 172, 0x0000 }, { 172, 0x0000 }, { 172, 0x0000 }, + { 172, 0x0000 }, { 172, 0x0000 }, { 172, 0x03ff }, { 182, 0x3ff0 }, + { 192, 0x0000 }, { 192, 0x0000 }, { 192, 0x0000 }, { 192, 0x0000 }, + { 192, 0x0000 }, { 192, 0x0000 }, { 192, 0x0000 }, { 192, 0x0000 }, + /* 0x2500 */ + { 192, 0x1005 }, { 195, 0x1111 }, { 199, 0x1010 }, { 201, 0x1010 }, + { 203, 0x0000 }, { 203, 0x4001 }, { 205, 0xe402 }, { 210, 0x000f }, + { 214, 0xfffe }, { 229, 0x0030 }, { 231, 0x0003 }, { 233, 0x300c }, + { 237, 0xc8c0 }, { 242, 0x0000 }, { 242, 0x003c }, { 246, 0x0000 }, + /* 0x2600 */ + { 246, 0x0260 }, { 249, 0x0000 }, { 249, 0x0000 }, { 249, 0x0000 }, + { 249, 0x0007 }, +}; +static const Summary16 big5_uni2indx_page30[62] = { + /* 0x3000 */ + { 252, 0xff2f }, { 265, 0x6037 }, { 272, 0x03fe }, { 281, 0x0000 }, + { 281, 0xfffe }, { 296, 0xffff }, { 312, 0xffff }, { 328, 0xffff }, + { 344, 0xffff }, { 360, 0x600f }, { 366, 0xfffe }, { 381, 0xffff }, + { 397, 0xffff }, { 413, 0xffff }, { 429, 0xffff }, { 445, 0x407f }, + /* 0x3100 */ + { 453, 0xffe0 }, { 464, 0xffff }, { 480, 0x03ff }, { 490, 0x0000 }, + { 490, 0x0000 }, { 490, 0x0000 }, { 490, 0x0000 }, { 490, 0x0000 }, + { 490, 0x0000 }, { 490, 0x0000 }, { 490, 0x0000 }, { 490, 0x0000 }, + { 490, 0x0000 }, { 490, 0x0000 }, { 490, 0x0000 }, { 490, 0x0000 }, + /* 0x3200 */ + { 490, 0x0000 }, { 490, 0x0000 }, { 490, 0x0000 }, { 490, 0x0000 }, + { 490, 0x0000 }, { 490, 0x0000 }, { 490, 0x0000 }, { 490, 0x0000 }, + { 490, 0x0000 }, { 490, 0x0000 }, { 490, 0x0008 }, { 491, 0x0000 }, + { 491, 0x0000 }, { 491, 0x0000 }, { 491, 0x0000 }, { 491, 0x0000 }, + /* 0x3300 */ + { 491, 0x0000 }, { 491, 0x0000 }, { 491, 0x0000 }, { 491, 0x0000 }, + { 491, 0x0000 }, { 491, 0x0000 }, { 491, 0x0000 }, { 491, 0x0000 }, + { 491, 0xc000 }, { 493, 0x7000 }, { 496, 0x0002 }, { 497, 0x0000 }, + { 497, 0x4010 }, { 499, 0x0026 }, +}; +static const Summary16 big5_uni2indx_page4e[1307] = { + /* 0x4e00 */ + { 502, 0xff8b }, { 514, 0xc373 }, { 523, 0x6840 }, { 527, 0x1b0f }, + { 535, 0xe9ac }, { 544, 0xf34c }, { 553, 0x0200 }, { 554, 0xc008 }, + { 557, 0x795c }, { 566, 0xca3e }, { 575, 0x7976 }, { 585, 0x0648 }, + { 589, 0x2fdf }, { 601, 0xf7f0 }, { 612, 0x033a }, { 618, 0xa8ff }, + /* 0x4f00 */ + { 629, 0xef37 }, { 641, 0x233f }, { 650, 0xb004 }, { 654, 0xfd59 }, + { 665, 0xf3ca }, { 675, 0xffff }, { 691, 0xde9f }, { 703, 0xfff9 }, + { 717, 0xabff }, { 730, 0x7df7 }, { 743, 0xc000 }, { 745, 0x8eec }, + { 754, 0xeebf }, { 767, 0xffdb }, { 781, 0xd003 }, { 786, 0x45fa }, + /* 0x5000 */ + { 795, 0xfae1 }, { 805, 0xdffe }, { 819, 0xbfef }, { 833, 0x10ab }, + { 839, 0xffeb }, { 853, 0xfcaa }, { 863, 0xef3f }, { 876, 0x24fd }, + { 885, 0x78ad }, { 894, 0x7f76 }, { 906, 0xf00c }, { 912, 0xedff }, + { 926, 0xcff6 }, { 938, 0x2cfa }, { 947, 0xf7f9 }, { 960, 0xeb6b }, + /* 0x5100 */ + { 971, 0x1ffd }, { 983, 0x95bf }, { 994, 0x6677 }, { 1004, 0xbfbf }, + { 1018, 0x3bfb }, { 1030, 0xfeb4 }, { 1041, 0x7bae }, { 1052, 0x11e2 }, + { 1058, 0xa681 }, { 1064, 0x41be }, { 1072, 0x1435 }, { 1078, 0x72c3 }, + { 1086, 0x7d70 }, { 1095, 0x7191 }, { 1102, 0x0003 }, { 1104, 0x276b }, + /* 0x5200 */ + { 1113, 0x57cb }, { 1123, 0x70cf }, { 1132, 0x4732 }, { 1139, 0x0def }, + { 1149, 0x7eda }, { 1160, 0xfc74 }, { 1170, 0xfe06 }, { 1179, 0xbdb4 }, + { 1189, 0x3f9f }, { 1201, 0x8bca }, { 1209, 0x7e49 }, { 1218, 0x5800 }, + { 1221, 0x228f }, { 1228, 0xebec }, { 1239, 0x8a5c }, { 1246, 0xddbb }, + /* 0x5300 */ + { 1258, 0xef60 }, { 1267, 0xb6e7 }, { 1278, 0xa40f }, { 1285, 0xf293 }, + { 1294, 0x37bb }, { 1305, 0x549e }, { 1313, 0xd04b }, { 1320, 0x9baf }, + { 1331, 0xc414 }, { 1336, 0xf7d4 }, { 1347, 0x30b0 }, { 1352, 0x0a14 }, + { 1356, 0x2f08 }, { 1362, 0x88d0 }, { 1367, 0xff7e }, { 1381, 0x192f }, + /* 0x5400 */ + { 1389, 0xffda }, { 1402, 0xfb07 }, { 1412, 0x7ff1 }, { 1424, 0x7beb }, + { 1436, 0xc5ef }, { 1447, 0x0010 }, { 1448, 0x99ff }, { 1460, 0xfdff }, + { 1475, 0x79d7 }, { 1486, 0x0567 }, { 1493, 0xffe7 }, { 1507, 0xfdcb }, + { 1519, 0xc3ff }, { 1531, 0x4040 }, { 1533, 0x6ff7 }, { 1546, 0xbd8e }, + /* 0x5500 */ + { 1556, 0xdffa }, { 1569, 0x0497 }, { 1575, 0xf4c0 }, { 1582, 0x5bff }, + { 1595, 0xed7b }, { 1607, 0xd0e7 }, { 1616, 0x047e }, { 1623, 0xf8e0 }, + { 1631, 0xff9f }, { 1645, 0xb73e }, { 1656, 0x7dfe }, { 1669, 0x882e }, + { 1675, 0xfffd }, { 1690, 0xbe7f }, { 1703, 0x83fe }, { 1713, 0xf6c4 }, + /* 0x5600 */ + { 1722, 0xf357 }, { 1733, 0xb8fd }, { 1744, 0xd680 }, { 1750, 0xef7d }, + { 1763, 0x5767 }, { 1773, 0x4788 }, { 1779, 0xff7d }, { 1793, 0xc3df }, + { 1804, 0xf0ff }, { 1816, 0x37a9 }, { 1825, 0x7de0 }, { 1834, 0x70fc }, + { 1843, 0x3f6f }, { 1855, 0xec9a }, { 1864, 0x4cb3 }, { 1872, 0x8681 }, + /* 0x5700 */ + { 1877, 0x3f9e }, { 1888, 0xdd5c }, { 1898, 0xf70d }, { 1908, 0x4819 }, + { 1913, 0xfea3 }, { 1924, 0x0007 }, { 1927, 0xaf56 }, { 1937, 0x38ff }, + { 1948, 0x980d }, { 1954, 0xefb8 }, { 1965, 0x403d }, { 1971, 0xb760 }, + { 1979, 0xd8ce }, { 1988, 0x9035 }, { 1994, 0x72bf }, { 2005, 0x3fff }, + /* 0x5800 */ + { 2019, 0x7ff7 }, { 2033, 0x7a11 }, { 2040, 0xf7bb }, { 2053, 0xabff }, + { 2066, 0xff00 }, { 2074, 0x6fbe }, { 2086, 0xa93c }, { 2094, 0xfe72 }, + { 2105, 0xcfef }, { 2118, 0xf11b }, { 2127, 0xdb6b }, { 2138, 0xf40a }, + { 2145, 0xc3e6 }, { 2154, 0xef7e }, { 2167, 0x9b9c }, { 2176, 0xf610 }, + /* 0x5900 */ + { 2183, 0xf048 }, { 2189, 0x16f4 }, { 2197, 0xfeb5 }, { 2209, 0x5182 }, + { 2214, 0xc7b1 }, { 2223, 0x15bb }, { 2232, 0x6e87 }, { 2241, 0xfbdf }, + { 2255, 0xe43f }, { 2265, 0x63cd }, { 2274, 0xc1ff }, { 2285, 0x7e7e }, + { 2297, 0xfdeb }, { 2310, 0x7d5f }, { 2322, 0x777b }, { 2334, 0xfcfe }, + /* 0x5a00 */ + { 2347, 0x960b }, { 2354, 0xdbea }, { 2365, 0x6229 }, { 2371, 0x53e8 }, + { 2379, 0x37df }, { 2391, 0xfdef }, { 2405, 0x36f5 }, { 2415, 0xbd81 }, + { 2423, 0xdc18 }, { 2430, 0xfcbd }, { 2442, 0xd2e4 }, { 2450, 0xffff }, + { 2466, 0x3fd7 }, { 2478, 0xffe0 }, { 2489, 0x7f6f }, { 2502, 0xabf8 }, + /* 0x5b00 */ + { 2512, 0x9bae }, { 2522, 0x6ed9 }, { 2532, 0xf5fb }, { 2545, 0xf115 }, + { 2553, 0x79a9 }, { 2562, 0xbdfb }, { 2575, 0x5a3c }, { 2583, 0xadaf }, + { 2594, 0xdbba }, { 2605, 0x1fac }, { 2614, 0x71fc }, { 2624, 0x8379 }, + { 2632, 0x7cf7 }, { 2644, 0xc35f }, { 2654, 0xdfff }, { 2669, 0x0567 }, + /* 0x5c00 */ + { 2676, 0xff9a }, { 2688, 0x8467 }, { 2695, 0x1534 }, { 2701, 0xdf8b }, + { 2712, 0xf9f3 }, { 2724, 0x3373 }, { 2733, 0xf7bd }, { 2746, 0x5e1a }, + { 2754, 0xbf40 }, { 2762, 0xa03f }, { 2770, 0xffff }, { 2786, 0x01eb }, + { 2793, 0xdfc0 }, { 2802, 0xcfdd }, { 2814, 0x7500 }, { 2819, 0xabd3 }, + /* 0x5d00 */ + { 2829, 0xf8c3 }, { 2838, 0xeed6 }, { 2849, 0x43fd }, { 2859, 0xb7ff }, + { 2873, 0x5eaf }, { 2884, 0x4227 }, { 2890, 0x9bac }, { 2899, 0xf686 }, + { 2908, 0x27d7 }, { 2918, 0xf6bc }, { 2929, 0xf787 }, { 2940, 0x35b7 }, + { 2950, 0xaacd }, { 2959, 0xe176 }, { 2968, 0x49e7 }, { 2977, 0xe29f }, + /* 0x5e00 */ + { 2987, 0x545c }, { 2994, 0xaff2 }, { 3005, 0x2b3f }, { 3015, 0x61d8 }, + { 3022, 0xfc3b }, { 3033, 0xbbb8 }, { 3043, 0xffcf }, { 3057, 0x7b7d }, + { 3069, 0xbf95 }, { 3080, 0x1ce0 }, { 3086, 0x7dfd }, { 3099, 0x43ff }, + { 3110, 0x5ff6 }, { 3122, 0xfffe }, { 3137, 0xd3ef }, { 3149, 0xc4ce }, + /* 0x5f00 */ + { 3157, 0x8db6 }, { 3166, 0xadbc }, { 3176, 0x63dc }, { 3185, 0x11eb }, + { 3193, 0xdf59 }, { 3204, 0x23d0 }, { 3210, 0xbeb4 }, { 3220, 0xf3db }, + { 3232, 0x1fe7 }, { 3243, 0xdbc7 }, { 3254, 0xff63 }, { 3266, 0xfae4 }, + { 3276, 0xb22b }, { 3284, 0x63f7 }, { 3295, 0xed3b }, { 3306, 0xadba }, + /* 0x6000 */ + { 3316, 0xfe01 }, { 3324, 0x7eff }, { 3338, 0xfff7 }, { 3353, 0x02bc }, + { 3359, 0x32ff }, { 3370, 0xef39 }, { 3381, 0xfffc }, { 3395, 0x8005 }, + { 3398, 0x77fb }, { 3411, 0xbcf5 }, { 3422, 0x010d }, { 3426, 0xfff7 }, + { 3441, 0xfffb }, { 3456, 0xbf3a }, { 3467, 0x0057 }, { 3472, 0xdfff }, + /* 0x6100 */ + { 3487, 0xef7b }, { 3500, 0xbd7d }, { 3512, 0xdb88 }, { 3520, 0xc8d4 }, + { 3527, 0xfff3 }, { 3541, 0xed7c }, { 3552, 0x5dee }, { 3563, 0x56ff }, + { 3575, 0x7e0d }, { 3584, 0xac5f }, { 3594, 0xff96 }, { 3606, 0xd57f }, + { 3618, 0x3fee }, { 3630, 0xc140 }, { 3634, 0x6ff9 }, { 3646, 0xffe7 }, + /* 0x6200 */ + { 3660, 0x779b }, { 3671, 0x8e77 }, { 3681, 0x6ebf }, { 3693, 0xe45d }, + { 3702, 0x6fcf }, { 3714, 0x5f1f }, { 3725, 0xe07f }, { 3735, 0xfedf }, + { 3749, 0xd7db }, { 3761, 0x01fe }, { 3769, 0xff00 }, { 3777, 0xfb7b }, + { 3790, 0xffd4 }, { 3802, 0x1fdf }, { 3814, 0xf800 }, { 3819, 0xffff }, + /* 0x6300 */ + { 3835, 0xfb8f }, { 3847, 0x007b }, { 3853, 0xbf00 }, { 3860, 0x7f5c }, + { 3871, 0xffff }, { 3887, 0x07f3 }, { 3896, 0xeba0 }, { 3904, 0x3de7 }, + { 3915, 0xf7bf }, { 3929, 0xfbd7 }, { 3942, 0xffbf }, { 3957, 0x6003 }, + { 3961, 0xfffd }, { 3976, 0xbfed }, { 3989, 0xefbb }, { 4002, 0x027f }, + /* 0x6400 */ + { 4010, 0xfe40 }, { 4018, 0xddfd }, { 4031, 0xfdff }, { 4046, 0xe2f9 }, + { 4056, 0x680b }, { 4062, 0xfb1f }, { 4074, 0xfbe3 }, { 4086, 0xaffd }, + { 4099, 0x9fa4 }, { 4108, 0xf7ed }, { 4121, 0x7a7d }, { 4132, 0xf80f }, + { 4141, 0xeebe }, { 4153, 0x0fd5 }, { 4162, 0xbb5d }, { 4173, 0xfd9f }, + /* 0x6500 */ + { 4186, 0xf2db }, { 4197, 0x3bf9 }, { 4208, 0xfe7f }, { 4222, 0xebcc }, + { 4232, 0x876a }, { 4240, 0x73fa }, { 4251, 0x95fc }, { 4261, 0x9ffc }, + { 4273, 0x109f }, { 4280, 0xfaf7 }, { 4293, 0xddb7 }, { 4305, 0xbbcd }, + { 4316, 0xf87e }, { 4327, 0xeccd }, { 4337, 0xf366 }, { 4347, 0x3c3f }, + /* 0x6600 */ + { 4357, 0xfffd }, { 4372, 0xb03f }, { 4381, 0xe9f7 }, { 4393, 0x067e }, + { 4401, 0x96ae }, { 4410, 0xfe06 }, { 4419, 0xd576 }, { 4429, 0x5fd7 }, + { 4441, 0x3fd1 }, { 4451, 0xa3f3 }, { 4461, 0xcf07 }, { 4470, 0x6fb7 }, + { 4482, 0x9fd1 }, { 4492, 0x7f44 }, { 4501, 0x7b59 }, { 4511, 0xd3dd }, + /* 0x6700 */ + { 4522, 0xaf3b }, { 4533, 0xa9bd }, { 4543, 0x7dcf }, { 4555, 0xff3a }, + { 4567, 0xfbe0 }, { 4577, 0xf6eb }, { 4589, 0xb401 }, { 4594, 0xffff }, + { 4610, 0x7afa }, { 4621, 0xb7bf }, { 4634, 0xc000 }, { 4636, 0x0ffd }, + { 4647, 0xff7f }, { 4662, 0xff1f }, { 4675, 0xfefc }, { 4688, 0x95ff }, + /* 0x6800 */ + { 4700, 0x0000 }, { 4700, 0xb5dc }, { 4710, 0xef63 }, { 4721, 0x3f3e }, + { 4732, 0xfb7f }, { 4746, 0x001b }, { 4750, 0xe800 }, { 4754, 0xfbf6 }, + { 4767, 0x9eef }, { 4779, 0xb8df }, { 4790, 0xff9f }, { 4804, 0x003f }, + { 4810, 0x7bd0 }, { 4819, 0xf5ff }, { 4833, 0xdfdb }, { 4846, 0x3fff }, + /* 0x6900 */ + { 4860, 0xfdf0 }, { 4871, 0x00bf }, { 4878, 0x8420 }, { 4881, 0xbbbd }, + { 4893, 0xdf37 }, { 4905, 0xffde }, { 4919, 0xff6d }, { 4932, 0x0ff3 }, + { 4942, 0x604c }, { 4947, 0x5efb }, { 4959, 0xfffb }, { 4974, 0xfafb }, + { 4987, 0xfe5e }, { 4999, 0x0219 }, { 5003, 0x79f4 }, { 5013, 0xf9de }, + /* 0x6a00 */ + { 5025, 0xa7f7 }, { 5037, 0xebfa }, { 5049, 0x01eb }, { 5056, 0xff34 }, + { 5067, 0xebd3 }, { 5078, 0xef73 }, { 5090, 0xafd7 }, { 5102, 0xc040 }, + { 5105, 0x72bb }, { 5115, 0xdcff }, { 5128, 0xf17f }, { 5140, 0x2fd8 }, + { 5149, 0xb8ec }, { 5158, 0xfe0b }, { 5168, 0xdda3 }, { 5178, 0x1f0b }, + /* 0x6b00 */ + { 5186, 0x8f1d }, { 5195, 0x47cf }, { 5205, 0xb12b }, { 5213, 0xffde }, + { 5227, 0x7fee }, { 5240, 0xda73 }, { 5250, 0x24ff }, { 5260, 0xcbc4 }, + { 5268, 0xf75d }, { 5280, 0xcbf2 }, { 5290, 0xecfd }, { 5302, 0xb4ed }, + { 5312, 0xbff9 }, { 5325, 0x4ddd }, { 5335, 0x99dd }, { 5345, 0xfb8d }, + /* 0x6c00 */ + { 5356, 0xbb7f }, { 5369, 0xaf7b }, { 5381, 0xddfb }, { 5394, 0xc959 }, + { 5402, 0xfc4f }, { 5413, 0xfab5 }, { 5424, 0xafe3 }, { 5435, 0x6d5f }, + { 5446, 0xffff }, { 5462, 0x3f7d }, { 5474, 0x7800 }, { 5478, 0xffdb }, + { 5492, 0xb6ff }, { 5505, 0x7eff }, { 5519, 0xfbaf }, { 5532, 0x022f }, + /* 0x6d00 */ + { 5538, 0xff9b }, { 5551, 0xefc7 }, { 5563, 0xffa5 }, { 5575, 0xffff }, + { 5591, 0x0007 }, { 5594, 0xc700 }, { 5599, 0xf7ff }, { 5614, 0xfff1 }, + { 5627, 0x7ffd }, { 5641, 0x01bf }, { 5649, 0xdc00 }, { 5654, 0xfdbc }, + { 5666, 0xbff5 }, { 5679, 0xffff }, { 5695, 0xff7f }, { 5710, 0x3eff }, + /* 0x6e00 */ + { 5723, 0x0029 }, { 5726, 0xbe00 }, { 5732, 0xf9ff }, { 5746, 0xff7f }, + { 5761, 0x6efb }, { 5773, 0xfd7e }, { 5786, 0xcbff }, { 5799, 0x039e }, + { 5806, 0xe300 }, { 5811, 0xfbdd }, { 5824, 0xccff }, { 5836, 0xf6df }, + { 5849, 0xffff }, { 5865, 0x117f }, { 5874, 0xf800 }, { 5879, 0xfbf6 }, + /* 0x6f00 */ + { 5892, 0xe7ef }, { 5905, 0xd73c }, { 5915, 0xfeef }, { 5929, 0xdfef }, + { 5943, 0xc00b }, { 5948, 0xedbf }, { 5961, 0xfedf }, { 5975, 0xfdcd }, + { 5987, 0x7bf5 }, { 5999, 0x40fd }, { 6007, 0xffff }, { 6023, 0xb75f }, + { 6035, 0xffdf }, { 6050, 0xf930 }, { 6058, 0xfbdf }, { 6072, 0xdc97 }, + /* 0x7000 */ + { 6082, 0xfef3 }, { 6095, 0xbff2 }, { 6107, 0x8fdf }, { 6119, 0xdfbf }, + { 6133, 0x177f }, { 6144, 0xede6 }, { 6155, 0x0f7f }, { 6166, 0x3553 }, + { 6174, 0x447c }, { 6181, 0x877e }, { 6191, 0xfa12 }, { 6199, 0x45bb }, + { 6208, 0xede0 }, { 6217, 0x779e }, { 6228, 0x8017 }, { 6233, 0xbfd9 }, + /* 0x7100 */ + { 6245, 0x7e55 }, { 6255, 0xde89 }, { 6264, 0xc16f }, { 6273, 0x0447 }, + { 6278, 0x7ade }, { 6289, 0xf75d }, { 6301, 0x57ff }, { 6314, 0x2905 }, + { 6319, 0x86f7 }, { 6329, 0xfe95 }, { 6340, 0x97b3 }, { 6350, 0xf32f }, + { 6361, 0xcfff }, { 6375, 0x9f75 }, { 6386, 0x71f7 }, { 6397, 0xfb17 }, + /* 0x7200 */ + { 6408, 0x34ee }, { 6417, 0xee19 }, { 6426, 0x37cc }, { 6435, 0xef61 }, + { 6445, 0x9fd6 }, { 6456, 0xef4c }, { 6466, 0xd68f }, { 6476, 0xfbdd }, + { 6489, 0x7b73 }, { 6500, 0x6def }, { 6512, 0xd7fe }, { 6525, 0xa431 }, + { 6531, 0x5e7f }, { 6543, 0x97d7 }, { 6554, 0x0f5b }, { 6563, 0xffd8 }, + /* 0x7300 */ + { 6575, 0x9d83 }, { 6583, 0x7bce }, { 6594, 0x22ec }, { 6601, 0xdcff }, + { 6614, 0x763d }, { 6624, 0xef87 }, { 6635, 0xdfe7 }, { 6648, 0xfded }, + { 6661, 0x4fff }, { 6674, 0xa0fc }, { 6682, 0x3b77 }, { 6693, 0xdbfc }, + { 6705, 0x3ded }, { 6716, 0x7fdc }, { 6728, 0x6fa9 }, { 6738, 0xf570 }, + /* 0x7400 */ + { 6747, 0x3ffb }, { 6760, 0x2c40 }, { 6764, 0xff7f }, { 6779, 0x847f }, + { 6788, 0xec57 }, { 6798, 0xdeb7 }, { 6810, 0xe69c }, { 6819, 0xf22f }, + { 6829, 0x0feb }, { 6839, 0xd5b5 }, { 6849, 0xafeb }, { 6861, 0xede7 }, + { 6873, 0x8c2f }, { 6881, 0xfff0 }, { 6893, 0x537f }, { 6904, 0xe8f0 }, + /* 0x7500 */ + { 6912, 0xb99d }, { 6922, 0xb5ff }, { 6935, 0xff66 }, { 6947, 0xe78f }, + { 6958, 0xd981 }, { 6965, 0xbe10 }, { 6972, 0x9c7c }, { 6981, 0xe3c1 }, + { 6989, 0x9cd1 }, { 6997, 0x2733 }, { 7005, 0x0cbc }, { 7012, 0xff6d }, + { 7025, 0xfcb7 }, { 7037, 0xefb7 }, { 7050, 0xa0df }, { 7059, 0xffff }, + /* 0x7600 */ + { 7075, 0xbf0b }, { 7085, 0xfe7b }, { 7098, 0xa3ff }, { 7110, 0x353f }, + { 7120, 0x13cc }, { 7127, 0x97cd }, { 7137, 0x7637 }, { 7147, 0xfb27 }, + { 7158, 0xcfd6 }, { 7169, 0x7e6c }, { 7179, 0xec50 }, { 7186, 0xed31 }, + { 7195, 0x677c }, { 7205, 0xfc1c }, { 7214, 0xf6fa }, { 7226, 0x5fbf }, + /* 0x7700 */ + { 7239, 0x0fba }, { 7248, 0xae2f }, { 7258, 0xa3ad }, { 7267, 0x7ffe }, + { 7281, 0xfcf0 }, { 7291, 0xde74 }, { 7301, 0xffef }, { 7316, 0xf200 }, + { 7321, 0xfbbf }, { 7335, 0xfea2 }, { 7345, 0x3daf }, { 7356, 0xbcff }, + { 7369, 0xf694 }, { 7378, 0x5fb9 }, { 7389, 0xf3ad }, { 7400, 0x3f8f }, + /* 0x7800 */ + { 7411, 0xf26c }, { 7420, 0xa01f }, { 7427, 0xffef }, { 7442, 0x01bf }, + { 7450, 0x7728 }, { 7458, 0x7005 }, { 7463, 0xff35 }, { 7475, 0xda03 }, + { 7482, 0xd2f9 }, { 7492, 0xc7fa }, { 7503, 0x3fbf }, { 7516, 0x5c1d }, + { 7524, 0xff3a }, { 7536, 0xec33 }, { 7545, 0xb7af }, { 7557, 0xfe9c }, + /* 0x7900 */ + { 7568, 0x5236 }, { 7575, 0x7a9f }, { 7586, 0xbffa }, { 7599, 0xe722 }, + { 7607, 0x9ff7 }, { 7620, 0xfcff }, { 7634, 0x2fbb }, { 7645, 0xb61d }, + { 7654, 0xed06 }, { 7662, 0x1dfd }, { 7673, 0x7dd7 }, { 7685, 0xefdf }, + { 7699, 0xeb23 }, { 7708, 0xf166 }, { 7717, 0x7ed9 }, { 7728, 0x0dc0 }, + /* 0x7a00 */ + { 7733, 0x3d3d }, { 7743, 0xdfbf }, { 7757, 0xc945 }, { 7764, 0xba83 }, + { 7772, 0x7dd1 }, { 7782, 0x9dd0 }, { 7790, 0x7b87 }, { 7800, 0xcf73 }, + { 7811, 0x9ff3 }, { 7823, 0xc3f5 }, { 7833, 0xdf0d }, { 7843, 0xc5fe }, + { 7854, 0x0cb3 }, { 7861, 0x8302 }, { 7865, 0xe879 }, { 7874, 0xaec0 }, + /* 0x7b00 */ + { 7881, 0xc773 }, { 7891, 0x6f0f }, { 7901, 0xfd7d }, { 7914, 0x093f }, + { 7922, 0xfff1 }, { 7935, 0x0157 }, { 7941, 0x62fb }, { 7951, 0x01ff }, + { 7960, 0xfdb4 }, { 7971, 0x3bf3 }, { 7982, 0xb013 }, { 7988, 0x43b2 }, + { 7995, 0x5ed3 }, { 8005, 0xff30 }, { 8015, 0x0fff }, { 8027, 0xeb9f }, + /* 0x7c00 */ + { 8039, 0xfeef }, { 8053, 0xf203 }, { 8060, 0x3fef }, { 8073, 0xfb89 }, + { 8083, 0x37a9 }, { 8092, 0x9e99 }, { 8101, 0xdef9 }, { 8113, 0xa72c }, + { 8121, 0x3733 }, { 8130, 0xc1f6 }, { 8139, 0x812e }, { 8145, 0xfe3e }, + { 8157, 0x5d20 }, { 8163, 0xf2f7 }, { 8175, 0xd585 }, { 8183, 0x69d7 }, + /* 0x7d00 */ + { 8193, 0xffff }, { 8209, 0xffff }, { 8225, 0xdb07 }, { 8234, 0xff6f }, + { 8248, 0xc4ff }, { 8259, 0xd97f }, { 8271, 0xefce }, { 8283, 0xbe0f }, + { 8293, 0xf17b }, { 8304, 0xf05e }, { 8313, 0xf6cf }, { 8325, 0xffb7 }, + { 8339, 0x5ef7 }, { 8351, 0xef84 }, { 8360, 0xd7cb }, { 8371, 0x0edf }, + /* 0x7e00 */ + { 8381, 0xff08 }, { 8390, 0xfcff }, { 8404, 0xee3f }, { 8416, 0xffff }, + { 8432, 0x13ff }, { 8443, 0xd7ff }, { 8457, 0xaf0f }, { 8467, 0x7ffd }, + { 8481, 0xbdc7 }, { 8492, 0x1ffa }, { 8503, 0x0000 }, { 8503, 0x0000 }, + { 8503, 0x0000 }, { 8503, 0x0000 }, { 8503, 0x0000 }, { 8503, 0x0000 }, + /* 0x7f00 */ + { 8503, 0x0000 }, { 8503, 0x0000 }, { 8503, 0x0000 }, { 8503, 0xe740 }, + { 8510, 0xbd38 }, { 8519, 0xf933 }, { 8529, 0x7feb }, { 8542, 0xfeed }, + { 8555, 0x7fe8 }, { 8566, 0x7c76 }, { 8576, 0xb3f7 }, { 8588, 0xffef }, + { 8603, 0xfeaf }, { 8616, 0xd8b7 }, { 8626, 0xff6f }, { 8640, 0xfbbf }, + /* 0x8000 */ + { 8654, 0xf8fb }, { 8666, 0xdbf7 }, { 8679, 0x1752 }, { 8686, 0xe2f9 }, + { 8696, 0x85c8 }, { 8702, 0x7547 }, { 8711, 0x9090 }, { 8715, 0xe3ef }, + { 8727, 0x9ef4 }, { 8737, 0x3f6d }, { 8748, 0xee2e }, { 8758, 0x0536 }, + { 8764, 0xf7bc }, { 8776, 0x7ff3 }, { 8789, 0xa07b }, { 8797, 0x7f3f }, + /* 0x8100 */ + { 8810, 0x0567 }, { 8817, 0xeb60 }, { 8825, 0xbabe }, { 8836, 0x6601 }, + { 8841, 0xfcd8 }, { 8851, 0x583f }, { 8860, 0xcaf7 }, { 8871, 0x87df }, + { 8882, 0xbfcd }, { 8894, 0xffa0 }, { 8904, 0x5bcd }, { 8914, 0xfebf }, + { 8928, 0xb6fd }, { 8940, 0xefa7 }, { 8952, 0x77ef }, { 8965, 0xdf9c }, + /* 0x8200 */ + { 8976, 0x3fb7 }, { 8988, 0xf877 }, { 8999, 0x9d27 }, { 9008, 0xb7fc }, + { 9020, 0xcab5 }, { 9029, 0xdfef }, { 9043, 0xfb5a }, { 9054, 0xf1b6 }, + { 9064, 0xec39 }, { 9073, 0xef1f }, { 9085, 0xfbbf }, { 9099, 0x7ffb }, + { 9113, 0x000d }, { 9116, 0xdafe }, { 9128, 0xbdfb }, { 9141, 0x4e7f }, + /* 0x8300 */ + { 9152, 0x33ff }, { 9164, 0x5ac0 }, { 9170, 0xbff5 }, { 9183, 0x9ffe }, + { 9196, 0xffbf }, { 9211, 0x005f }, { 9217, 0x0000 }, { 9217, 0xfdf8 }, + { 9229, 0xffca }, { 9241, 0x6ffd }, { 9254, 0xcffd }, { 9267, 0xa001 }, + { 9270, 0xdfff }, { 9285, 0xfbf2 }, { 9297, 0xdfbf }, { 9311, 0xff7f }, + /* 0x8400 */ + { 9326, 0xfeda }, { 9338, 0x080f }, { 9343, 0xba08 }, { 9349, 0xbfff }, + { 9364, 0x7afd }, { 9376, 0xeed7 }, { 9388, 0xfbeb }, { 9401, 0x67f9 }, + { 9412, 0xe044 }, { 9417, 0xff93 }, { 9429, 0xdf97 }, { 9441, 0x9f57 }, + { 9452, 0xfef7 }, { 9466, 0x08df }, { 9474, 0xdf80 }, { 9482, 0xfedf }, + /* 0x8500 */ + { 9496, 0xffc5 }, { 9508, 0xf7fe }, { 9522, 0xfffb }, { 9537, 0x6803 }, + { 9542, 0x67fb }, { 9554, 0x6bfa }, { 9565, 0x7fff }, { 9580, 0x5fe2 }, + { 9590, 0xffff }, { 9606, 0xff73 }, { 9619, 0x87df }, { 9630, 0xe7fb }, + { 9643, 0xebfd }, { 9656, 0xf7a7 }, { 9668, 0xbf7e }, { 9681, 0xefc7 }, + /* 0x8600 */ + { 9693, 0x1ef3 }, { 9703, 0xdf82 }, { 9712, 0x76ff }, { 9725, 0xdf7e }, + { 9738, 0x79c9 }, { 9747, 0xda7d }, { 9758, 0xefbe }, { 9771, 0x1e9b }, + { 9780, 0x7ce0 }, { 9788, 0x77fb }, { 9801, 0x87be }, { 9811, 0xfffb }, + { 9826, 0x1bff }, { 9838, 0xffdb }, { 9852, 0x3f5c }, { 9862, 0x4fe0 }, + /* 0x8700 */ + { 9870, 0x7fff }, { 9885, 0x5f0e }, { 9894, 0x77ff }, { 9908, 0xddbf }, + { 9921, 0xf04f }, { 9930, 0xffff }, { 9946, 0xffff }, { 9962, 0x0ff8 }, + { 9971, 0xa3be }, { 9981, 0xfddf }, { 9995, 0xfc1c }, { 10004, 0xfffd }, + { 10019, 0x1f7d }, { 10030, 0xfb9e }, { 10042, 0xbdff }, { 10056, 0xdedc }, + /* 0x8800 */ + { 10067, 0x3f6f }, { 10079, 0xbafb }, { 10091, 0xdf7f }, { 10105, 0xfbef }, + { 10119, 0x7d1b }, { 10129, 0x2eec }, { 10138, 0xaf8e }, { 10148, 0xf2f7 }, + { 10160, 0x7b0f }, { 10170, 0xcfee }, { 10182, 0x1d96 }, { 10190, 0x77c6 }, + { 10200, 0x7e07 }, { 10209, 0xfff5 }, { 10223, 0xd982 }, { 10230, 0x7fdf }, + /* 0x8900 */ + { 10244, 0x5ee6 }, { 10254, 0xc7ff }, { 10267, 0xfeee }, { 10280, 0x79ef }, + { 10292, 0x9a56 }, { 10300, 0xffcf }, { 10314, 0xfe5f }, { 10327, 0xde5e }, + { 10338, 0x896e }, { 10346, 0xf9e8 }, { 10356, 0xf45e }, { 10366, 0xe6c4 }, + { 10374, 0x0001 }, { 10375, 0xbe7c }, { 10386, 0x3b7f }, { 10398, 0xdddf }, + /* 0x8a00 */ + { 10411, 0xd59d }, { 10421, 0xe9ef }, { 10433, 0x34ac }, { 10440, 0xde53 }, + { 10450, 0xf573 }, { 10461, 0x4bf7 }, { 10472, 0x7b4f }, { 10483, 0x9eff }, + { 10496, 0xb8fe }, { 10507, 0x476e }, { 10516, 0x0dfb }, { 10526, 0xff45 }, + { 10537, 0xabfd }, { 10549, 0xfbfe }, { 10563, 0xe9d7 }, { 10574, 0xddff }, + /* 0x8b00 */ + { 10588, 0xedf7 }, { 10601, 0x7fff }, { 10616, 0xddfd }, { 10629, 0x7eeb }, + { 10641, 0xcfe7 }, { 10653, 0xb7ff }, { 10667, 0xbde9 }, { 10678, 0xef91 }, + { 10688, 0x5d75 }, { 10698, 0xd77c }, { 10709, 0x0000 }, { 10709, 0x0000 }, + { 10709, 0x0000 }, { 10709, 0x0000 }, { 10709, 0x0000 }, { 10709, 0x0000 }, + /* 0x8c00 */ + { 10709, 0x0000 }, { 10709, 0x0000 }, { 10709, 0x0000 }, { 10709, 0xfa80 }, + { 10716, 0xffee }, { 10730, 0xb4f1 }, { 10739, 0xbf76 }, { 10751, 0x2fef }, + { 10763, 0xb677 }, { 10774, 0x77bf }, { 10787, 0x9fbf }, { 10800, 0xfffd }, + { 10815, 0x95bf }, { 10826, 0xf6ae }, { 10837, 0x75ff }, { 10850, 0x7f3b }, + /* 0x8d00 */ + { 10862, 0xa7f5 }, { 10873, 0x0af9 }, { 10881, 0x0000 }, { 10881, 0x0000 }, + { 10881, 0x0000 }, { 10881, 0x0000 }, { 10881, 0xfbd0 }, { 10891, 0x2bdd }, + { 10901, 0xf633 }, { 10911, 0x9a7f }, { 10922, 0xfdab }, { 10934, 0xd6fc }, + { 10945, 0xf9e6 }, { 10956, 0xbfeb }, { 10969, 0xdfdf }, { 10983, 0xf41f }, + /* 0x8e00 */ + { 10993, 0xa6fd }, { 11004, 0xffff }, { 11020, 0x4aff }, { 11031, 0xf37b }, + { 11043, 0x7fb7 }, { 11056, 0xfef9 }, { 11069, 0xb6ff }, { 11082, 0x1d5c }, + { 11090, 0x7ff6 }, { 11103, 0xe5ff }, { 11116, 0x1f7b }, { 11127, 0x2404 }, + { 11130, 0xbe05 }, { 11138, 0xf99e }, { 11149, 0xdbe3 }, { 11160, 0xdff2 }, + /* 0x8f00 */ + { 11172, 0x6fef }, { 11185, 0xfdff }, { 11200, 0xd679 }, { 11210, 0xcbfc }, + { 11221, 0xebfd }, { 11234, 0xefff }, { 11249, 0x001f }, { 11254, 0x0000 }, + { 11254, 0x0000 }, { 11254, 0x9800 }, { 11257, 0xe148 }, { 11263, 0x8017 }, + { 11268, 0x6a74 }, { 11276, 0x00fe }, { 11283, 0x6d7f }, { 11295, 0xfdf1 }, + /* 0x9000 */ + { 11307, 0xb87f }, { 11318, 0xfef3 }, { 11331, 0xe01f }, { 11339, 0xf176 }, + { 11349, 0xee96 }, { 11359, 0x7b3f }, { 11371, 0xeb8d }, { 11381, 0xfffd }, + { 11396, 0xadff }, { 11409, 0xcbb3 }, { 11419, 0x84ef }, { 11428, 0xe17f }, + { 11439, 0x4daa }, { 11447, 0xbff0 }, { 11458, 0xbf3f }, { 11471, 0xfe3f }, + /* 0x9100 */ + { 11484, 0xebff }, { 11498, 0xffd7 }, { 11512, 0xffdf }, { 11527, 0xcf7f }, + { 11540, 0xfffb }, { 11555, 0x85ed }, { 11564, 0xd73f }, { 11576, 0x07bc }, + { 11584, 0xaeff }, { 11597, 0xfe0f }, { 11608, 0xfdaf }, { 11621, 0x76bf }, + { 11633, 0xfaef }, { 11646, 0x37bb }, { 11657, 0x7fdc }, { 11669, 0xa3ba }, + /* 0x9200 */ + { 11678, 0xb6ff }, { 11691, 0x56f7 }, { 11702, 0x60f8 }, { 11709, 0xe7df }, + { 11722, 0xff61 }, { 11733, 0x4cdf }, { 11743, 0xb0fb }, { 11753, 0xff45 }, + { 11764, 0x7ded }, { 11776, 0x3ffa }, { 11788, 0x1fff }, { 11801, 0x18fc }, + { 11809, 0xffff }, { 11825, 0xe3af }, { 11836, 0xc7d3 }, { 11846, 0xdf83 }, + /* 0x9300 */ + { 11856, 0xfb57 }, { 11868, 0xef7d }, { 11881, 0xefff }, { 11896, 0x1378 }, + { 11903, 0xfec0 }, { 11912, 0x5ff7 }, { 11925, 0x34bb }, { 11934, 0x5ee3 }, + { 11944, 0xf70d }, { 11954, 0xeff6 }, { 11967, 0xd7fe }, { 11980, 0x00bf }, + { 11987, 0xf59d }, { 11998, 0xf7f7 }, { 12012, 0x51de }, { 12021, 0xffe0 }, + /* 0x9400 */ + { 12032, 0xfec9 }, { 12043, 0x037f }, { 12052, 0x5f01 }, { 12059, 0xbfef }, + { 12073, 0x9ff1 }, { 12084, 0x60a7 }, { 12091, 0xef1d }, { 12102, 0xf1ff }, + { 12115, 0x000f }, { 12119, 0x0000 }, { 12119, 0x0000 }, { 12119, 0x0000 }, + { 12119, 0x0000 }, { 12119, 0x0000 }, { 12119, 0x0000 }, { 12119, 0x0000 }, + /* 0x9500 */ + { 12119, 0x0000 }, { 12119, 0x0000 }, { 12119, 0x0000 }, { 12119, 0x0000 }, + { 12119, 0x0000 }, { 12119, 0x0000 }, { 12119, 0x0000 }, { 12119, 0x3c80 }, + { 12124, 0xfb4d }, { 12135, 0xd91f }, { 12145, 0x7b3a }, { 12155, 0xfee3 }, + { 12167, 0x3fe9 }, { 12178, 0xdc7f }, { 12190, 0x003f }, { 12196, 0x0000 }, + /* 0x9600 */ + { 12196, 0x0000 }, { 12196, 0x5000 }, { 12198, 0xf51f }, { 12209, 0xbe07 }, + { 12218, 0xfc1d }, { 12228, 0xf91b }, { 12238, 0xbc1e }, { 12247, 0x71ff }, + { 12259, 0x6ff9 }, { 12271, 0x5bbe }, { 12282, 0x5796 }, { 12291, 0x9b1b }, + { 12300, 0x7fff }, { 12315, 0xfffc }, { 12329, 0x872e }, { 12337, 0xafe7 }, + /* 0x9700 */ + { 12349, 0xebf5 }, { 12361, 0xf34f }, { 12372, 0xdffd }, { 12386, 0xe725 }, + { 12395, 0x0bdc }, { 12403, 0x5d44 }, { 12410, 0x5747 }, { 12419, 0xfddd }, + { 12432, 0xed3f }, { 12444, 0x7790 }, { 12452, 0x7d7f }, { 12465, 0x8ac8 }, + { 12471, 0xfafa }, { 12483, 0xf3f9 }, { 12495, 0x202a }, { 12499, 0xef4b }, + /* 0x9800 */ + { 12510, 0xf5ff }, { 12524, 0x79cf }, { 12535, 0xabd3 }, { 12545, 0x0ba5 }, + { 12552, 0xf77a }, { 12564, 0xfb8f }, { 12576, 0x8ebd }, { 12586, 0x001f }, + { 12591, 0x0000 }, { 12591, 0x0000 }, { 12591, 0xf300 }, { 12597, 0xfd4e }, + { 12608, 0x1a57 }, { 12616, 0x8800 }, { 12618, 0xaeac }, { 12627, 0x7654 }, + /* 0x9900 */ + { 12635, 0x17ad }, { 12644, 0xcdff }, { 12657, 0xffb2 }, { 12669, 0xf42f }, + { 12679, 0x5baa }, { 12688, 0xdbff }, { 12702, 0x0002 }, { 12703, 0x0000 }, + { 12703, 0x0000 }, { 12703, 0x73c0 }, { 12710, 0xf9ea }, { 12721, 0x2e3f }, + { 12731, 0xfa8e }, { 12741, 0xbbff }, { 12755, 0x76bc }, { 12765, 0xffd3 }, + /* 0x9a00 */ + { 12778, 0xeefe }, { 12791, 0x7e72 }, { 12801, 0x7ebd }, { 12813, 0xe7f7 }, + { 12826, 0xf77f }, { 12840, 0xcefd }, { 12852, 0x0ff5 }, { 12862, 0x0000 }, + { 12862, 0x0000 }, { 12862, 0x0000 }, { 12862, 0xa900 }, { 12866, 0xdb9b }, + { 12877, 0xa4c7 }, { 12885, 0x917f }, { 12895, 0xf8ca }, { 12904, 0x7ece }, + /* 0x9b00 */ + { 12915, 0x7d7a }, { 12926, 0xc7e7 }, { 12937, 0xcbbd }, { 12948, 0xdcae }, + { 12958, 0xfd7e }, { 12971, 0x8f76 }, { 12981, 0x91d3 }, { 12989, 0x7cf3 }, + { 13000, 0x01e5 }, { 13006, 0x4c2f }, { 13014, 0xed77 }, { 13026, 0xa360 }, + { 13032, 0x07db }, { 13041, 0x5ef8 }, { 13051, 0x1df7 }, { 13062, 0x2181 }, + /* 0x9c00 */ + { 13066, 0x6be0 }, { 13074, 0x309c }, { 13080, 0x3b3a }, { 13089, 0xfade }, + { 13101, 0x7f53 }, { 13112, 0xc3f5 }, { 13122, 0x61cd }, { 13130, 0x07ba }, + { 13138, 0x0000 }, { 13138, 0x0000 }, { 13138, 0x0000 }, { 13138, 0x0000 }, + { 13138, 0x0000 }, { 13138, 0x0000 }, { 13138, 0x26e0 }, { 13144, 0xbefe }, + /* 0x9d00 */ + { 13157, 0x03f9 }, { 13165, 0xebb5 }, { 13176, 0xe36d }, { 13186, 0xe9cb }, + { 13196, 0x9c2f }, { 13205, 0xbfde }, { 13218, 0x9f83 }, { 13227, 0xabbf }, + { 13239, 0x1ff7 }, { 13251, 0xffd5 }, { 13264, 0xb7df }, { 13277, 0xdffe }, + { 13291, 0xfdae }, { 13303, 0xffef }, { 13318, 0xfb7e }, { 13331, 0xeffd }, + /* 0x9e00 */ + { 13345, 0xaaff }, { 13357, 0x6ebf }, { 13369, 0x0000 }, { 13369, 0x0000 }, + { 13369, 0x0000 }, { 13369, 0x0000 }, { 13369, 0x0000 }, { 13369, 0xb620 }, + { 13375, 0x7fcd }, { 13387, 0xbe9e }, { 13398, 0x62b3 }, { 13406, 0x58f1 }, + { 13414, 0xf10d }, { 13422, 0xfd7b }, { 13435, 0xe9f1 }, { 13445, 0xbefd }, + /* 0x9f00 */ + { 13458, 0xc6c3 }, { 13466, 0x5f6d }, { 13477, 0xff3d }, { 13490, 0x69ff }, + { 13502, 0xffcf }, { 13516, 0xfbf4 }, { 13528, 0xdcfb }, { 13540, 0x4ff7 }, + { 13552, 0x2000 }, { 13553, 0x1137 }, { 13560, 0x0015 }, +}; +static const Summary16 big5_uni2indx_pagefa[1] = { + /* 0xfa00 */ + { 13563, 0x3000 }, +}; +static const Summary16 big5_uni2indx_pagefe[23] = { + /* 0xfe00 */ + { 13565, 0x0000 }, { 13565, 0x0000 }, { 13565, 0x0000 }, { 13565, 0xfffb }, + { 13580, 0xfe1f }, { 13592, 0xfef5 }, { 13605, 0x0e7f }, { 13615, 0x0000 }, + { 13615, 0x0000 }, { 13615, 0x0000 }, { 13615, 0x0000 }, { 13615, 0x0000 }, + { 13615, 0x0000 }, { 13615, 0x0000 }, { 13615, 0x0000 }, { 13615, 0x0000 }, + /* 0xff00 */ + { 13615, 0xff7a }, { 13628, 0xffff }, { 13644, 0xffff }, { 13660, 0x97ff }, + { 13673, 0xfffe }, { 13688, 0x3fff }, { 13702, 0x0010 }, +}; + +static int +big5_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc >= 0x0000 && wc < 0x0100) + summary = &big5_uni2indx_page00[(wc>>4)]; + else if (wc >= 0x0200 && wc < 0x0460) + summary = &big5_uni2indx_page02[(wc>>4)-0x020]; + else if (wc >= 0x2000 && wc < 0x22c0) + summary = &big5_uni2indx_page20[(wc>>4)-0x200]; + else if (wc >= 0x2400 && wc < 0x2650) + summary = &big5_uni2indx_page24[(wc>>4)-0x240]; + else if (wc >= 0x3000 && wc < 0x33e0) + summary = &big5_uni2indx_page30[(wc>>4)-0x300]; + else if (wc >= 0x4e00 && wc < 0x9fb0) + summary = &big5_uni2indx_page4e[(wc>>4)-0x4e0]; + else if (wc >= 0xfa00 && wc < 0xfa10) + summary = &big5_uni2indx_pagefa[(wc>>4)-0xfa0]; + else if (wc >= 0xfe00 && wc < 0xff70) + summary = &big5_uni2indx_pagefe[(wc>>4)-0xfe0]; + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = big5_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/big5_2003.h b/graf2d/win32gdk/gdk/src/iconv/big5_2003.h new file mode 100644 index 0000000000000..b532ce6ee83ab --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/big5_2003.h @@ -0,0 +1,476 @@ +/* + * Copyright (C) 1999-2001, 2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * BIG5-2003 + */ + +/* + * BIG5-2003 is a slightly extended and slightly modified version of BIG5. + * It is actually nearer to Microsoft CP950 than to BIG5. The differences + * between EASTASIA/OTHER/BIG5.TXT found on ftp.unicode.org and BIG5-2003.TXT + * are as follows: + * + * 1. Some characters in the symbols area (0xA140..0xA2CE) are defined + * differently: + * + * code BIG5.TXT BIG5-2003.TXT + * 0xA145 0x2022 # BULLET 0x2027 # HYPHENATION POINT + * 0xA14E 0xFF64 # HALFWIDTH IDEOGRAPHIC COMMA + * 0xFE51 # SMALL IDEOGRAPHIC COMMA + * 0xA156 0x2013 # EN DASH 0x2015 # HORIZONTAL BAR + * 0xA15A --- 0x2574 # BOX DRAWINGS LIGHT LEFT + * 0xA1C3 --- 0xFFE3 # FULLWIDTH MACRON + * 0xA1C5 --- 0x02CD # MODIFIER LETTER LOW MACRON + * 0xA1E3 0x223C # TILDE OPERATOR 0xFF5E # FULLWIDTH TILDE + * 0xA1F2 0x2641 # EARTH 0x2295 # CIRCLED PLUS + * 0xA1F3 0x2609 # SUN 0x2299 # CIRCLED DOT OPERATOR + * 0xA1FE --- 0xFF0F # FULLWIDTH SOLIDUS + * 0xA240 --- 0xFF3C # FULLWIDTH REVERSE SOLIDUS + * 0xA241 0xFF0F # FULLWIDTH SOLIDUS 0x2215 # DIVISION SLASH + * 0xA242 0xFF3C # FULLWIDTH REVERSE SOLIDUS + * 0xFE68 # SMALL REVERSE SOLIDUS + * 0xA244 0x00A5 # YEN SIGN 0xFFE5 # FULLWIDTH YEN SIGN + * 0xA246 0x00A2 # CENT SIGN 0xFFE0 # FULLWIDTH CENT SIGN + * 0xA247 0x00A3 # POUND SIGN 0xFFE1 # FULLWIDTH POUND SIGN + * 0xA2A4 0x2550 # BOX DRAWINGS DOUBLE HORIZONTAL + * 0x2501 # BOX DRAWINGS HEAVY HORIZONTAL + * 0xA2A5 0x255E # BOX DRAWINGS VERTICAL SINGLE AND RIGHT DOUBLE + * 0x251D # BOX DRAWINGS VERTICAL LIGHT AND RIGHT HEAVY + * 0xA2A6 0x256A # BOX DRAWINGS VERTICAL SINGLE AND HORIZONTAL DOUBLE + * 0x253F # BOX DRAWINGS VERTICAL LIGHT AND HORIZONTAL HEAVY + * 0xA2A7 0x2561 # BOX DRAWINGS VERTICAL SINGLE AND LEFT DOUBLE + * 0x2525 # BOX DRAWINGS VERTICAL LIGHT AND LEFT HEAVY + * 0xA2CC --- 0x3038 # HANGZHOU NUMERAL TEN + * 0xA2CD 0x5344 0x3039 # HANGZHOU NUMERAL TWENTY + * 0xA2CE --- 0x303A # HANGZHOU NUMERAL THIRTY + * + * 2. A control symbols area is added: + * + * code + * 0xA3C0..0xA3E0 U+2400..U+2421 + * + * 3. The Euro sign is added: + * + * code + * 0xA3E1 0x20AC # EURO SIGN + * + * 4. Some characters in the main area are defined differently: + * + * code BIG5.TXT BIG5-2003.TXT + * 0xC255 0x5F5D 0x5F5E + * + * 5. The area 0xC6A1..0xC7FE is organized differently: + * + * code + * 0xC6A1..0xC6BE numerals (was in BIG5.TXT at 0xC7E9..0xC7FC) + * 0xC6BF..0xC6D7 radicals + * 0xC6D8..0xC6E6 rarely used symbols + * 0xC6E7..0xC77A hiragana (U+3041..U+3093, was in BIG5.TXT at 0xC6A5..0xC6F7) + * 0xC77B..0xC7F2 katakana (U+30A1..U+30F6, was in BIG5.TXT at 0xC6F8..0xC7B0) + * + * 6. Some characters are added at 0xF9D6..0xF9DC. + * + * 7. Box drawing characters are added at 0xF9DD..0xF9FE. + * + * Note: 4 of these characters are mapped in a non-inversible way, because + * Unicode does not yet include the corresponding characters: + * + * code Unicode approximation + * 0xF9FA BOX DRAWINGS DOUBLE ARC DOWN AND RIGHT 0x2554 + * 0xF9FB BOX DRAWINGS DOUBLE ARC DOWN AND LEFT 0x2557 + * 0xF9FC BOX DRAWINGS DOUBLE ARC UP AND RIGHT 0x255A + * 0xF9FD BOX DRAWINGS DOUBLE ARC UP AND LEFT 0x255D + * + * 8. Private area mappings are added: + * + * code Unicode + * 0x{81..8D}{40..7E,A1..FE} U+EEB8..U+F6B0 + * 0x{8E..A0}{40..7E,A1..FE} U+E311..U+EEB7 + * 0x{FA..FE}{40..7E,A1..FE} U+E000..U+E310 + * + * These mappings are not contained in the BSMI Big5-2003 standard. However, + * they were contained in a draft of it. + */ + +static const unsigned short big5_2003_2uni_pagea1[314] = { + /* 0xa1 */ + 0x3000, 0xff0c, 0x3001, 0x3002, 0xff0e, 0x2027, 0xff1b, 0xff1a, + 0xff1f, 0xff01, 0xfe30, 0x2026, 0x2025, 0xfe50, 0xfe51, 0xfe52, + 0x00b7, 0xfe54, 0xfe55, 0xfe56, 0xfe57, 0xff5c, 0x2015, 0xfe31, + 0x2014, 0xfe33, 0x2574, 0xfe34, 0xfe4f, 0xff08, 0xff09, 0xfe35, + 0xfe36, 0xff5b, 0xff5d, 0xfe37, 0xfe38, 0x3014, 0x3015, 0xfe39, + 0xfe3a, 0x3010, 0x3011, 0xfe3b, 0xfe3c, 0x300a, 0x300b, 0xfe3d, + 0xfe3e, 0x3008, 0x3009, 0xfe3f, 0xfe40, 0x300c, 0x300d, 0xfe41, + 0xfe42, 0x300e, 0x300f, 0xfe43, 0xfe44, 0xfe59, 0xfe5a, 0xfe5b, + 0xfe5c, 0xfe5d, 0xfe5e, 0x2018, 0x2019, 0x201c, 0x201d, 0x301d, + 0x301e, 0x2035, 0x2032, 0xff03, 0xff06, 0xff0a, 0x203b, 0x00a7, + 0x3003, 0x25cb, 0x25cf, 0x25b3, 0x25b2, 0x25ce, 0x2606, 0x2605, + 0x25c7, 0x25c6, 0x25a1, 0x25a0, 0x25bd, 0x25bc, 0x32a3, 0x2105, + 0x203e, 0xffe3, 0xff3f, 0x02cd, 0xfe49, 0xfe4a, 0xfe4d, 0xfe4e, + 0xfe4b, 0xfe4c, 0xfe5f, 0xfe60, 0xfe61, 0xff0b, 0xff0d, 0x00d7, + 0x00f7, 0x00b1, 0x221a, 0xff1c, 0xff1e, 0xff1d, 0x2266, 0x2267, + 0x2260, 0x221e, 0x2252, 0x2261, 0xfe62, 0xfe63, 0xfe64, 0xfe65, + 0xfe66, 0xff5e, 0x2229, 0x222a, 0x22a5, 0x2220, 0x221f, 0x22bf, + 0x33d2, 0x33d1, 0x222b, 0x222e, 0x2235, 0x2234, 0x2640, 0x2642, + 0x2295, 0x2299, 0x2191, 0x2193, 0x2190, 0x2192, 0x2196, 0x2197, + 0x2199, 0x2198, 0x2225, 0x2223, 0xff0f, + /* 0xa2 */ + 0xff3c, 0x2215, 0xfe68, 0xff04, 0xffe5, 0x3012, 0xffe0, 0xffe1, + 0xff05, 0xff20, 0x2103, 0x2109, 0xfe69, 0xfe6a, 0xfe6b, 0x33d5, + 0x339c, 0x339d, 0x339e, 0x33ce, 0x33a1, 0x338e, 0x338f, 0x33c4, + 0x00b0, 0x5159, 0x515b, 0x515e, 0x515d, 0x5161, 0x5163, 0x55e7, + 0x74e9, 0x7cce, 0x2581, 0x2582, 0x2583, 0x2584, 0x2585, 0x2586, + 0x2587, 0x2588, 0x258f, 0x258e, 0x258d, 0x258c, 0x258b, 0x258a, + 0x2589, 0x253c, 0x2534, 0x252c, 0x2524, 0x251c, 0x2594, 0x2500, + 0x2502, 0x2595, 0x250c, 0x2510, 0x2514, 0x2518, 0x256d, 0x256e, + 0x2570, 0x256f, 0x2501, 0x251d, 0x253f, 0x2525, 0x25e2, 0x25e3, + 0x25e5, 0x25e4, 0x2571, 0x2572, 0x2573, 0xff10, 0xff11, 0xff12, + 0xff13, 0xff14, 0xff15, 0xff16, 0xff17, 0xff18, 0xff19, 0x2160, + 0x2161, 0x2162, 0x2163, 0x2164, 0x2165, 0x2166, 0x2167, 0x2168, + 0x2169, 0x3021, 0x3022, 0x3023, 0x3024, 0x3025, 0x3026, 0x3027, + 0x3028, 0x3029, 0x3038, 0x3039, 0x303a, 0xff21, 0xff22, 0xff23, + 0xff24, 0xff25, 0xff26, 0xff27, 0xff28, 0xff29, 0xff2a, 0xff2b, + 0xff2c, 0xff2d, 0xff2e, 0xff2f, 0xff30, 0xff31, 0xff32, 0xff33, + 0xff34, 0xff35, 0xff36, 0xff37, 0xff38, 0xff39, 0xff3a, 0xff41, + 0xff42, 0xff43, 0xff44, 0xff45, 0xff46, 0xff47, 0xff48, 0xff49, + 0xff4a, 0xff4b, 0xff4c, 0xff4d, 0xff4e, 0xff4f, 0xff50, 0xff51, + 0xff52, 0xff53, 0xff54, 0xff55, 0xff56, +}; + +static const unsigned short big5_2003_2uni_pagec6[70] = { + /* 0xc6a1 */ + 0x2460, 0x2461, 0x2462, 0x2463, 0x2464, 0x2465, 0x2466, 0x2467, + 0x2468, 0x2469, 0x2474, 0x2475, 0x2476, 0x2477, 0x2478, 0x2479, + 0x247a, 0x247b, 0x247c, 0x247d, 0x2170, 0x2171, 0x2172, 0x2173, + 0x2174, 0x2175, 0x2176, 0x2177, 0x2178, 0x2179, 0x2f02, 0x2f03, + 0x2f05, 0x2f07, 0x2f0c, 0x2f0d, 0x2f0e, 0x2f13, 0x2f16, 0x2f19, + 0x2f1b, 0x2f22, 0x2f27, 0x2f2e, 0x2f33, 0x2f34, 0x2f35, 0x2f39, + 0x2f3a, 0x2f41, 0x2f46, 0x2f67, 0x2f68, 0x2fa1, 0x2faa, 0x00a8, + 0xff3e, 0x30fd, 0x30fe, 0x309d, 0x309e, 0xfffd, 0xfffd, 0x3005, + 0x3006, 0x3007, 0x30fc, 0xff3b, 0xff3d, 0x273d, +}; + +static const unsigned short big5_2003_2uni_pagef9[41] = { + /* 0xf9d6 */ + 0x7881, 0x92b9, 0x88cf, 0x58bb, 0x6052, 0x7ca7, 0x5afa, + /* 0xf9dd */ + 0x2554, 0x2566, 0x2557, 0x2560, 0x256c, 0x2563, 0x255a, 0x2569, + 0x255d, 0x2552, 0x2564, 0x2555, 0x255e, 0x256a, 0x2561, 0x2558, + 0x2567, 0x255b, 0x2553, 0x2565, 0x2556, 0x255f, 0x256b, 0x2562, + 0x2559, 0x2568, 0x255c, 0x2551, 0x2550, + 0x2554, 0x2557, 0x255a, 0x255d, /* not invertible */ + 0x2593, +}; + +static int +big5_2003_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + /* Code set 0 (ASCII) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (BIG5 extended) */ + if (c >= 0x81 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0xa1 && c2 < 0xff)) { + if (c >= 0xa1) { + if (c < 0xa3) { + unsigned int i = 157 * (c - 0xa1) + (c2 - (c2 >= 0xa1 ? 0x62 : 0x40)); + unsigned short wc = big5_2003_2uni_pagea1[i]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + if (!((c == 0xc6 && c2 >= 0xa1) || c == 0xc7)) { + if (!(c == 0xc2 && c2 == 0x55)) { + int ret = big5_mbtowc(conv,pwc,s,2); + if (ret != RET_ILSEQ) + return ret; + if (c == 0xa3) { + if (c2 >= 0xc0 && c2 <= 0xe1) { + *pwc = (c2 == 0xe1 ? 0x20ac : c2 == 0xe0 ? 0x2421 : 0x2340 + c2); + return 2; + } + } else if (c == 0xf9) { + if (c2 >= 0xd6) { + *pwc = big5_2003_2uni_pagef9[c2-0xd6]; + return 2; + } + } else if (c >= 0xfa) { + *pwc = 0xe000 + 157 * (c - 0xfa) + (c2 - (c2 >= 0xa1 ? 0x62 : 0x40)); + return 2; + } + } else { + /* c == 0xc2 && c2 == 0x55. */ + *pwc = 0x5f5e; + return 2; + } + } else { + /* (c == 0xc6 && c2 >= 0xa1) || c == 0xc7. */ + unsigned int i = 157 * (c - 0xc6) + (c2 - (c2 >= 0xa1 ? 0x62 : 0x40)); + if (i < 133) { + /* 63 <= i < 133. */ + unsigned short wc = big5_2003_2uni_pagec6[i-63]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } else if (i < 216) { + /* 133 <= i < 216. Hiragana. */ + *pwc = 0x3041 - 133 + i; + return 2; + } else if (i < 302) { + /* 216 <= i < 302. Katakana. */ + *pwc = 0x30a1 - 216 + i; + return 2; + } + } + } else { + /* 0x81 <= c < 0xa1. */ + *pwc = (c >= 0x8e ? 0xdb18 : 0xeeb8) + 157 * (c - 0x81) + + (c2 - (c2 >= 0xa1 ? 0x62 : 0x40)); + return 2; + } + } + } + } + return RET_ILSEQ; +} + +static const unsigned char big5_2003_2charset_page25[29] = { + /* 0x2550 */ + 0xf9, 0xf8, 0xe6, 0xef, 0xdd, 0xe8, 0xf1, 0xdf, + 0xec, 0xf5, 0xe3, 0xee, 0xf7, 0xe5, 0xe9, 0xf2, + 0xe0, 0xeb, 0xf4, 0xe2, 0xe7, 0xf0, 0xde, 0xed, + 0xf6, 0xe4, 0xea, 0xf3, 0xe1, +}; + +static int +big5_2003_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Code set 0 (ASCII) */ + ret = ascii_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + /* Code set 1 (BIG5 extended) */ + switch (wc >> 8) { + case 0x00: + if (wc == 0x00a8) { buf[0] = 0xc6; buf[1] = 0xd8; ret = 2; break; } + if (wc == 0x00a2 || wc == 0x00a3 || wc == 0x00a5) + return RET_ILUNI; + break; + case 0x02: + if (wc == 0x02cd) { buf[0] = 0xa1; buf[1] = 0xc5; ret = 2; break; } + break; + case 0x04: + return RET_ILUNI; + case 0x20: + if (wc == 0x2015) { buf[0] = 0xa1; buf[1] = 0x56; ret = 2; break; } + if (wc == 0x2027) { buf[0] = 0xa1; buf[1] = 0x45; ret = 2; break; } + if (wc == 0x20ac) { buf[0] = 0xa3; buf[1] = 0xe1; ret = 2; break; } + if (wc == 0x2013 || wc == 0x2022) + return RET_ILUNI; + break; + case 0x21: + if (wc >= 0x2170 && wc <= 0x2179) { + buf[0] = 0xc6; buf[1] = wc - 0x20bb; ret = 2; + break; + } + break; + case 0x22: + if (wc == 0x2215) { buf[0] = 0xa2; buf[1] = 0x41; ret = 2; break; } + if (wc == 0x2295) { buf[0] = 0xa1; buf[1] = 0xf2; ret = 2; break; } + if (wc == 0x2299) { buf[0] = 0xa1; buf[1] = 0xf3; ret = 2; break; } + if (wc == 0x223c) + return RET_ILUNI; + break; + case 0x24: + if (wc <= 0x241f) { buf[0] = 0xa3; buf[1] = wc - 0x2340; ret = 2; break; } + if (wc == 0x2421) { buf[0] = 0xa3; buf[1] = 0xe0; ret = 2; break; } + if (wc >= 0x2460 && wc <= 0x2469) { + buf[0] = 0xc6; buf[1] = wc - 0x23bf; ret = 2; + break; + } + if (wc >= 0x2474 && wc <= 0x247d) { + buf[0] = 0xc6; buf[1] = wc - 0x23c9; ret = 2; + break; + } + break; + case 0x25: + if (wc == 0x2501) { buf[0] = 0xa2; buf[1] = 0xa4; ret = 2; break; } + if (wc == 0x251d) { buf[0] = 0xa2; buf[1] = 0xa5; ret = 2; break; } + if (wc == 0x2525) { buf[0] = 0xa2; buf[1] = 0xa7; ret = 2; break; } + if (wc == 0x253f) { buf[0] = 0xa2; buf[1] = 0xa6; ret = 2; break; } + if (wc >= 0x2550 && wc <= 0x256c) { + buf[0] = 0xf9; buf[1] = big5_2003_2charset_page25[wc-0x2550]; ret = 2; + break; + } + if (wc == 0x2574) { buf[0] = 0xa1; buf[1] = 0x5a; ret = 2; break; } + if (wc == 0x2593) { buf[0] = 0xf9; buf[1] = 0xfe; ret = 2; break; } + break; + case 0x26: + if (wc == 0x2609 || wc == 0x2641) + return RET_ILUNI; + break; + case 0x27: + if (wc == 0x273d) { buf[0] = 0xc6; buf[1] = 0xe6; ret = 2; break; } + break; + case 0x2f: + if (wc == 0x2f02) { buf[0] = 0xc6; buf[1] = 0xbf; ret = 2; break; } + if (wc == 0x2f03) { buf[0] = 0xc6; buf[1] = 0xc0; ret = 2; break; } + if (wc == 0x2f05) { buf[0] = 0xc6; buf[1] = 0xc1; ret = 2; break; } + if (wc == 0x2f07) { buf[0] = 0xc6; buf[1] = 0xc2; ret = 2; break; } + if (wc == 0x2f0c) { buf[0] = 0xc6; buf[1] = 0xc3; ret = 2; break; } + if (wc == 0x2f0d) { buf[0] = 0xc6; buf[1] = 0xc4; ret = 2; break; } + if (wc == 0x2f0e) { buf[0] = 0xc6; buf[1] = 0xc5; ret = 2; break; } + if (wc == 0x2f13) { buf[0] = 0xc6; buf[1] = 0xc6; ret = 2; break; } + if (wc == 0x2f16) { buf[0] = 0xc6; buf[1] = 0xc7; ret = 2; break; } + if (wc == 0x2f19) { buf[0] = 0xc6; buf[1] = 0xc8; ret = 2; break; } + if (wc == 0x2f1b) { buf[0] = 0xc6; buf[1] = 0xc9; ret = 2; break; } + if (wc == 0x2f22) { buf[0] = 0xc6; buf[1] = 0xca; ret = 2; break; } + if (wc == 0x2f27) { buf[0] = 0xc6; buf[1] = 0xcb; ret = 2; break; } + if (wc == 0x2f2e) { buf[0] = 0xc6; buf[1] = 0xcc; ret = 2; break; } + if (wc == 0x2f33) { buf[0] = 0xc6; buf[1] = 0xcd; ret = 2; break; } + if (wc == 0x2f34) { buf[0] = 0xc6; buf[1] = 0xce; ret = 2; break; } + if (wc == 0x2f35) { buf[0] = 0xc6; buf[1] = 0xcf; ret = 2; break; } + if (wc == 0x2f39) { buf[0] = 0xc6; buf[1] = 0xd0; ret = 2; break; } + if (wc == 0x2f3a) { buf[0] = 0xc6; buf[1] = 0xd1; ret = 2; break; } + if (wc == 0x2f41) { buf[0] = 0xc6; buf[1] = 0xd2; ret = 2; break; } + if (wc == 0x2f46) { buf[0] = 0xc6; buf[1] = 0xd3; ret = 2; break; } + if (wc == 0x2f67) { buf[0] = 0xc6; buf[1] = 0xd4; ret = 2; break; } + if (wc == 0x2f68) { buf[0] = 0xc6; buf[1] = 0xd5; ret = 2; break; } + if (wc == 0x2fa1) { buf[0] = 0xc6; buf[1] = 0xd6; ret = 2; break; } + if (wc == 0x2faa) { buf[0] = 0xc6; buf[1] = 0xd7; ret = 2; break; } + break; + case 0x30: + if (wc >= 0x3005 && wc <= 0x3007) { + buf[0] = 0xc6; buf[1] = wc - 0x2f25; ret = 2; + break; + } + if (wc >= 0x3038 && wc <= 0x303a) { + buf[0] = 0xa2; buf[1] = wc - 0x2f6c; ret = 2; + break; + } + if (wc >= 0x3041 && wc <= 0x3093) { + if (wc < 0x3059) { + buf[0] = 0xc6; buf[1] = wc - 0x2f5a; + } else { + buf[0] = 0xc7; buf[1] = wc - 0x3019; + } + ret = 2; + break; + } + if (wc == 0x309d) { buf[0] = 0xc6; buf[1] = 0xdc; ret = 2; break; } + if (wc == 0x309e) { buf[0] = 0xc6; buf[1] = 0xdd; ret = 2; break; } + if (wc >= 0x30a1 && wc <= 0x30f6) { + buf[0] = 0xc7; buf[1] = wc - (wc < 0x30a5 ? 0x3026 : 0x3004); ret = 2; + break; + } + if (wc == 0x30fc) { buf[0] = 0xc6; buf[1] = 0xe3; ret = 2; break; } + if (wc == 0x30fd) { buf[0] = 0xc6; buf[1] = 0xda; ret = 2; break; } + if (wc == 0x30fe) { buf[0] = 0xc6; buf[1] = 0xdb; ret = 2; break; } + break; + case 0x53: + if (wc == 0x5344) + return RET_ILUNI; + break; + case 0x58: + if (wc == 0x58bb) { buf[0] = 0xf9; buf[1] = 0xd9; ret = 2; break; } + break; + case 0x5a: + if (wc == 0x5afa) { buf[0] = 0xf9; buf[1] = 0xdc; ret = 2; break; } + break; + case 0x5f: + if (wc == 0x5f5e) { buf[0] = 0xc2; buf[1] = 0x55; ret = 2; break; } + if (wc == 0x5f5d) + return RET_ILUNI; + break; + case 0x60: + if (wc == 0x6052) { buf[0] = 0xf9; buf[1] = 0xda; ret = 2; break; } + break; + case 0x78: + if (wc == 0x7881) { buf[0] = 0xf9; buf[1] = 0xd6; ret = 2; break; } + break; + case 0x7c: + if (wc == 0x7ca7) { buf[0] = 0xf9; buf[1] = 0xdb; ret = 2; break; } + break; + case 0x88: + if (wc == 0x88cf) { buf[0] = 0xf9; buf[1] = 0xd8; ret = 2; break; } + break; + case 0x92: + if (wc == 0x92b9) { buf[0] = 0xf9; buf[1] = 0xd7; ret = 2; break; } + break; + case 0xe0: case 0xe1: case 0xe2: case 0xe3: case 0xe4: case 0xe5: + case 0xe6: case 0xe7: case 0xe8: case 0xe9: case 0xea: case 0xeb: + case 0xec: case 0xed: case 0xee: case 0xef: case 0xf0: case 0xf1: + case 0xf2: case 0xf3: case 0xf4: case 0xf5: case 0xf6: + { + unsigned int i = wc - 0xe000; + if (i < 5809) { + unsigned int c1 = i / 157; + unsigned int c2 = i % 157; + buf[0] = c1 + (c1 < 5 ? 0xfa : c1 < 24 ? 0x89 : 0x69); + buf[1] = c2 + (c2 < 0x3f ? 0x40 : 0x62); + ret = 2; + break; + } + } + break; + case 0xfe: + if (wc == 0xfe51) { buf[0] = 0xa1; buf[1] = 0x4e; ret = 2; break; } + if (wc == 0xfe68) { buf[0] = 0xa2; buf[1] = 0x42; ret = 2; break; } + break; + case 0xff: + if (wc == 0xff0f) { buf[0] = 0xa1; buf[1] = 0xfe; ret = 2; break; } + if (wc == 0xff3b) { buf[0] = 0xc6; buf[1] = 0xe4; ret = 2; break; } + if (wc == 0xff3c) { buf[0] = 0xa2; buf[1] = 0x40; ret = 2; break; } + if (wc == 0xff3d) { buf[0] = 0xc6; buf[1] = 0xe5; ret = 2; break; } + if (wc == 0xff3e) { buf[0] = 0xc6; buf[1] = 0xd9; ret = 2; break; } + if (wc == 0xff5e) { buf[0] = 0xa1; buf[1] = 0xe3; ret = 2; break; } + if (wc == 0xffe0) { buf[0] = 0xa2; buf[1] = 0x46; ret = 2; break; } + if (wc == 0xffe1) { buf[0] = 0xa2; buf[1] = 0x47; ret = 2; break; } + if (wc == 0xffe3) { buf[0] = 0xa1; buf[1] = 0xc3; ret = 2; break; } + if (wc == 0xffe5) { buf[0] = 0xa2; buf[1] = 0x44; ret = 2; break; } + if (wc == 0xff64) + return RET_ILUNI; + break; + } + if (ret == RET_ILUNI) + ret = big5_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]; + r[1] = buf[1]; + return 2; + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/big5hkscs1999.h b/graf2d/win32gdk/gdk/src/iconv/big5hkscs1999.h new file mode 100644 index 0000000000000..9e0d1b0c4e465 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/big5hkscs1999.h @@ -0,0 +1,197 @@ +/* + * Copyright (C) 1999-2002, 2006 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * BIG5-HKSCS:1999 + */ + +/* + * BIG5-HKSCS:1999 can be downloaded from + * http://www.info.gov.hk/digital21/eng/hkscs/download.html + * http://www.info.gov.hk/digital21/eng/hkscs/index.html + * + * It extends BIG5 (without the rows 0xC6..0xC7) through the ranges + * + * 0x{88..8D}{40..7E,A1..FE} 641 characters + * 0x{8E..A0}{40..7E,A1..FE} 2898 characters + * 0x{C6..C8}{40..7E,A1..FE} 359 characters + * 0xF9{D6..FE} 41 characters + * 0x{FA..FE}{40..7E,A1..FE} 763 characters + * + * Note that some HKSCS characters are not contained in Unicode 3.2 + * and are therefore best represented as sequences of Unicode characters: + * 0x8862 U+00CA U+0304 LATIN CAPITAL LETTER E WITH CIRCUMFLEX AND MACRON + * 0x8864 U+00CA U+030C LATIN CAPITAL LETTER E WITH CIRCUMFLEX AND CARON + * 0x88A3 U+00EA U+0304 LATIN SMALL LETTER E WITH CIRCUMFLEX AND MACRON + * 0x88A5 U+00EA U+030C LATIN SMALL LETTER E WITH CIRCUMFLEX AND CARON + */ + +#include "hkscs1999.h" +#include "flushwc.h" + +static int +big5hkscs1999_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + ucs4_t last_wc = conv->istate; + if (last_wc) { + /* Output the buffered character. */ + conv->istate = 0; + *pwc = last_wc; + return 0; /* Don't advance the input pointer. */ + } else { + unsigned char c = *s; + /* Code set 0 (ASCII) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (BIG5 extended) */ + if (c >= 0xa1 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0xa1 && c2 < 0xff)) { + if (!((c == 0xc6 && c2 >= 0xa1) || c == 0xc7)) { + int ret = big5_mbtowc(conv,pwc,s,2); + if (ret != RET_ILSEQ) + return ret; + } + } + } + } + { + int ret = hkscs1999_mbtowc(conv,pwc,s,n); + if (ret != RET_ILSEQ) + return ret; + } + if (c == 0x88) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c2 == 0x62 || c2 == 0x64 || c2 == 0xa3 || c2 == 0xa5) { + /* It's a composed character. */ + ucs4_t wc1 = ((c2 >> 3) << 2) + 0x009a; /* = 0x00ca or 0x00ea */ + ucs4_t wc2 = ((c2 & 6) << 2) + 0x02fc; /* = 0x0304 or 0x030c */ + /* We cannot output two Unicode characters at once. So, + output the first character and buffer the second one. */ + *pwc = wc1; + conv->istate = wc2; + return 2; + } + } + } + return RET_ILSEQ; + } +} + +#define big5hkscs1999_flushwc normal_flushwc + +static int +big5hkscs1999_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + int count = 0; + unsigned char last = conv->ostate; + + if (last) { + /* last is = 0x66 or = 0xa7. */ + if (wc == 0x0304 || wc == 0x030c) { + /* Output the combined character. */ + if (n >= 2) { + r[0] = 0x88; + r[1] = last + ((wc & 24) >> 2) - 4; /* = 0x62 or 0x64 or 0xa3 or 0xa5 */ + conv->ostate = 0; + return 2; + } else + return RET_TOOSMALL; + } + + /* Output the buffered character. */ + if (n < 2) + return RET_TOOSMALL; + r[0] = 0x88; + r[1] = last; + r += 2; + count = 2; + } + + /* Code set 0 (ASCII) */ + if (wc < 0x0080) { + /* Plain ASCII character. */ + if (n > count) { + r[0] = (unsigned char) wc; + conv->ostate = 0; + return count+1; + } else + return RET_TOOSMALL; + } else { + unsigned char buf[2]; + int ret; + + /* Code set 1 (BIG5 extended) */ + ret = big5_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (!((buf[0] == 0xc6 && buf[1] >= 0xa1) || buf[0] == 0xc7)) { + if (n >= count+2) { + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = 0; + return count+2; + } else + return RET_TOOSMALL; + } + } + ret = hkscs1999_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if ((wc & ~0x0020) == 0x00ca) { + /* A possible first character of a multi-character sequence. We have to + buffer it. */ + if (!(buf[0] == 0x88 && (buf[1] == 0x66 || buf[1] == 0xa7))) abort(); + conv->ostate = buf[1]; /* = 0x66 or = 0xa7 */ + return count+0; + } + if (n >= count+2) { + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = 0; + return count+2; + } else + return RET_TOOSMALL; + } + return RET_ILUNI; + } +} + +static int +big5hkscs1999_reset (conv_t conv, unsigned char *r, int n) +{ + unsigned char last = conv->ostate; + + if (last) { + if (n < 2) + return RET_TOOSMALL; + r[0] = 0x88; + r[1] = last; + /* conv->ostate = 0; will be done by the caller */ + return 2; + } else + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/big5hkscs2001.h b/graf2d/win32gdk/gdk/src/iconv/big5hkscs2001.h new file mode 100644 index 0000000000000..2d378c480668a --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/big5hkscs2001.h @@ -0,0 +1,215 @@ +/* + * Copyright (C) 1999-2002, 2006 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * BIG5-HKSCS:2001 + */ + +/* + * BIG5-HKSCS:2001 can be downloaded from + * http://www.info.gov.hk/digital21/eng/hkscs/download.html + * http://www.info.gov.hk/digital21/eng/hkscs/index.html + * + * It extends BIG5-HKSCS:1999 through 116 characters. + * + * It extends BIG5 (without the rows 0xC6..0xC7) through the ranges + * + * 0x{88..8D}{40..7E,A1..FE} 757 characters + * 0x{8E..A0}{40..7E,A1..FE} 2898 characters + * 0x{C6..C8}{40..7E,A1..FE} 359 characters + * 0xF9{D6..FE} 41 characters + * 0x{FA..FE}{40..7E,A1..FE} 763 characters + * + * Note that some HKSCS characters are not contained in Unicode 3.2 + * and are therefore best represented as sequences of Unicode characters: + * 0x8862 U+00CA U+0304 LATIN CAPITAL LETTER E WITH CIRCUMFLEX AND MACRON + * 0x8864 U+00CA U+030C LATIN CAPITAL LETTER E WITH CIRCUMFLEX AND CARON + * 0x88A3 U+00EA U+0304 LATIN SMALL LETTER E WITH CIRCUMFLEX AND MACRON + * 0x88A5 U+00EA U+030C LATIN SMALL LETTER E WITH CIRCUMFLEX AND CARON + */ + +#include "hkscs2001.h" +#include "flushwc.h" + +static int +big5hkscs2001_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + ucs4_t last_wc = conv->istate; + if (last_wc) { + /* Output the buffered character. */ + conv->istate = 0; + *pwc = last_wc; + return 0; /* Don't advance the input pointer. */ + } else { + unsigned char c = *s; + /* Code set 0 (ASCII) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (BIG5 extended) */ + if (c >= 0xa1 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0xa1 && c2 < 0xff)) { + if (!((c == 0xc6 && c2 >= 0xa1) || c == 0xc7)) { + int ret = big5_mbtowc(conv,pwc,s,2); + if (ret != RET_ILSEQ) + return ret; + } + } + } + } + { + int ret = hkscs1999_mbtowc(conv,pwc,s,n); + if (ret != RET_ILSEQ) + return ret; + } + { + int ret = hkscs2001_mbtowc(conv,pwc,s,n); + if (ret != RET_ILSEQ) + return ret; + } + if (c == 0x88) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c2 == 0x62 || c2 == 0x64 || c2 == 0xa3 || c2 == 0xa5) { + /* It's a composed character. */ + ucs4_t wc1 = ((c2 >> 3) << 2) + 0x009a; /* = 0x00ca or 0x00ea */ + ucs4_t wc2 = ((c2 & 6) << 2) + 0x02fc; /* = 0x0304 or 0x030c */ + /* We cannot output two Unicode characters at once. So, + output the first character and buffer the second one. */ + *pwc = wc1; + conv->istate = wc2; + return 2; + } + } + } + return RET_ILSEQ; + } +} + +#define big5hkscs2001_flushwc normal_flushwc + +static int +big5hkscs2001_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + int count = 0; + unsigned char last = conv->ostate; + + if (last) { + /* last is = 0x66 or = 0xa7. */ + if (wc == 0x0304 || wc == 0x030c) { + /* Output the combined character. */ + if (n >= 2) { + r[0] = 0x88; + r[1] = last + ((wc & 24) >> 2) - 4; /* = 0x62 or 0x64 or 0xa3 or 0xa5 */ + conv->ostate = 0; + return 2; + } else + return RET_TOOSMALL; + } + + /* Output the buffered character. */ + if (n < 2) + return RET_TOOSMALL; + r[0] = 0x88; + r[1] = last; + r += 2; + count = 2; + } + + /* Code set 0 (ASCII) */ + if (wc < 0x0080) { + /* Plain ASCII character. */ + if (n > count) { + r[0] = (unsigned char) wc; + conv->ostate = 0; + return count+1; + } else + return RET_TOOSMALL; + } else { + unsigned char buf[2]; + int ret; + + /* Code set 1 (BIG5 extended) */ + ret = big5_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (!((buf[0] == 0xc6 && buf[1] >= 0xa1) || buf[0] == 0xc7)) { + if (n >= count+2) { + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = 0; + return count+2; + } else + return RET_TOOSMALL; + } + } + ret = hkscs1999_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if ((wc & ~0x0020) == 0x00ca) { + /* A possible first character of a multi-character sequence. We have to + buffer it. */ + if (!(buf[0] == 0x88 && (buf[1] == 0x66 || buf[1] == 0xa7))) abort(); + conv->ostate = buf[1]; /* = 0x66 or = 0xa7 */ + return count+0; + } + if (n >= count+2) { + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = 0; + return count+2; + } else + return RET_TOOSMALL; + } + ret = hkscs2001_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n >= count+2) { + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = 0; + return count+2; + } else + return RET_TOOSMALL; + } + return RET_ILUNI; + } +} + +static int +big5hkscs2001_reset (conv_t conv, unsigned char *r, int n) +{ + unsigned char last = conv->ostate; + + if (last) { + if (n < 2) + return RET_TOOSMALL; + r[0] = 0x88; + r[1] = last; + /* conv->ostate = 0; will be done by the caller */ + return 2; + } else + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/big5hkscs2004.h b/graf2d/win32gdk/gdk/src/iconv/big5hkscs2004.h new file mode 100644 index 0000000000000..3c57f66b18d27 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/big5hkscs2004.h @@ -0,0 +1,231 @@ +/* + * Copyright (C) 1999-2002, 2006 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * BIG5-HKSCS:2004 + */ + +/* + * BIG5-HKSCS:2004 can be downloaded from + * http://www.info.gov.hk/digital21/eng/hkscs/download.html + * http://www.info.gov.hk/digital21/eng/hkscs/index.html + * + * It extends BIG5-HKSCS:2001 through 123 characters. + * + * It extends BIG5 (without the rows 0xC6..0xC7) through the ranges + * + * 0x{87..8D}{40..7E,A1..FE} 880 characters + * 0x{8E..A0}{40..7E,A1..FE} 2898 characters + * 0x{C6..C8}{40..7E,A1..FE} 359 characters + * 0xF9{D6..FE} 41 characters + * 0x{FA..FE}{40..7E,A1..FE} 763 characters + * + * Note that some HKSCS characters are not contained in Unicode 3.2 + * and are therefore best represented as sequences of Unicode characters: + * 0x8862 U+00CA U+0304 LATIN CAPITAL LETTER E WITH CIRCUMFLEX AND MACRON + * 0x8864 U+00CA U+030C LATIN CAPITAL LETTER E WITH CIRCUMFLEX AND CARON + * 0x88A3 U+00EA U+0304 LATIN SMALL LETTER E WITH CIRCUMFLEX AND MACRON + * 0x88A5 U+00EA U+030C LATIN SMALL LETTER E WITH CIRCUMFLEX AND CARON + */ + +#include "hkscs2004.h" +#include "flushwc.h" + +static int +big5hkscs2004_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + ucs4_t last_wc = conv->istate; + if (last_wc) { + /* Output the buffered character. */ + conv->istate = 0; + *pwc = last_wc; + return 0; /* Don't advance the input pointer. */ + } else { + unsigned char c = *s; + /* Code set 0 (ASCII) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (BIG5 extended) */ + if (c >= 0xa1 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0xa1 && c2 < 0xff)) { + if (!((c == 0xc6 && c2 >= 0xa1) || c == 0xc7)) { + int ret = big5_mbtowc(conv,pwc,s,2); + if (ret != RET_ILSEQ) + return ret; + } + } + } + } + { + int ret = hkscs1999_mbtowc(conv,pwc,s,n); + if (ret != RET_ILSEQ) + return ret; + } + { + int ret = hkscs2001_mbtowc(conv,pwc,s,n); + if (ret != RET_ILSEQ) + return ret; + } + { + int ret = hkscs2004_mbtowc(conv,pwc,s,n); + if (ret != RET_ILSEQ) + return ret; + } + if (c == 0x88) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c2 == 0x62 || c2 == 0x64 || c2 == 0xa3 || c2 == 0xa5) { + /* It's a composed character. */ + ucs4_t wc1 = ((c2 >> 3) << 2) + 0x009a; /* = 0x00ca or 0x00ea */ + ucs4_t wc2 = ((c2 & 6) << 2) + 0x02fc; /* = 0x0304 or 0x030c */ + /* We cannot output two Unicode characters at once. So, + output the first character and buffer the second one. */ + *pwc = wc1; + conv->istate = wc2; + return 2; + } + } + } + return RET_ILSEQ; + } +} + +#define big5hkscs2004_flushwc normal_flushwc + +static int +big5hkscs2004_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + int count = 0; + unsigned char last = conv->ostate; + + if (last) { + /* last is = 0x66 or = 0xa7. */ + if (wc == 0x0304 || wc == 0x030c) { + /* Output the combined character. */ + if (n >= 2) { + r[0] = 0x88; + r[1] = last + ((wc & 24) >> 2) - 4; /* = 0x62 or 0x64 or 0xa3 or 0xa5 */ + conv->ostate = 0; + return 2; + } else + return RET_TOOSMALL; + } + + /* Output the buffered character. */ + if (n < 2) + return RET_TOOSMALL; + r[0] = 0x88; + r[1] = last; + r += 2; + count = 2; + } + + /* Code set 0 (ASCII) */ + if (wc < 0x0080) { + /* Plain ASCII character. */ + if (n > count) { + r[0] = (unsigned char) wc; + conv->ostate = 0; + return count+1; + } else + return RET_TOOSMALL; + } else { + unsigned char buf[2]; + int ret; + + /* Code set 1 (BIG5 extended) */ + ret = big5_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (!((buf[0] == 0xc6 && buf[1] >= 0xa1) || buf[0] == 0xc7)) { + if (n >= count+2) { + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = 0; + return count+2; + } else + return RET_TOOSMALL; + } + } + ret = hkscs1999_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if ((wc & ~0x0020) == 0x00ca) { + /* A possible first character of a multi-character sequence. We have to + buffer it. */ + if (!(buf[0] == 0x88 && (buf[1] == 0x66 || buf[1] == 0xa7))) abort(); + conv->ostate = buf[1]; /* = 0x66 or = 0xa7 */ + return count+0; + } + if (n >= count+2) { + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = 0; + return count+2; + } else + return RET_TOOSMALL; + } + ret = hkscs2001_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n >= count+2) { + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = 0; + return count+2; + } else + return RET_TOOSMALL; + } + ret = hkscs2004_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n >= count+2) { + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = 0; + return count+2; + } else + return RET_TOOSMALL; + } + return RET_ILUNI; + } +} + +static int +big5hkscs2004_reset (conv_t conv, unsigned char *r, int n) +{ + unsigned char last = conv->ostate; + + if (last) { + if (n < 2) + return RET_TOOSMALL; + r[0] = 0x88; + r[1] = last; + /* conv->ostate = 0; will be done by the caller */ + return 2; + } else + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/c99.h b/graf2d/win32gdk/gdk/src/iconv/c99.h new file mode 100644 index 0000000000000..52a73c354da26 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/c99.h @@ -0,0 +1,125 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * C99 + * This is ASCII with \uXXXX and \UXXXXXXXX escape sequences, denoting Unicode + * characters. See ISO/IEC 9899:1999, section 6.4.3. + * The treatment of control characters in the range U+0080..U+009F is not + * specified; we pass them through unmodified. + */ + +static int +c99_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c; + ucs4_t wc; + int i; + + c = s[0]; + if (c < 0xa0) { + if (c != '\\') { + *pwc = c; + return 1; + } + if (n < 2) + return RET_TOOFEW(0); + c = s[1]; + if (c == 'u') { + wc = 0; + for (i = 2; i < 6; i++) { + if (n <= i) + return RET_TOOFEW(0); + c = s[i]; + if (c >= '0' && c <= '9') + c -= '0'; + else if (c >= 'A' && c <= 'Z') + c -= 'A'-10; + else if (c >= 'a' && c <= 'z') + c -= 'a'-10; + else + goto simply_backslash; + wc |= (ucs4_t) c << (4 * (5-i)); + } + if ((wc >= 0x00a0 && !(wc >= 0xd800 && wc < 0xe000)) + || wc == 0x0024 || wc == 0x0040 || wc == 0x0060) { + *pwc = wc; + return 6; + } + } else if (c == 'U') { + wc = 0; + for (i = 2; i < 10; i++) { + if (n <= i) + return RET_TOOFEW(0); + c = s[i]; + if (c >= '0' && c <= '9') + c -= '0'; + else if (c >= 'A' && c <= 'Z') + c -= 'A'-10; + else if (c >= 'a' && c <= 'z') + c -= 'a'-10; + else + goto simply_backslash; + wc |= (ucs4_t) c << (4 * (9-i)); + } + if ((wc >= 0x00a0 && !(wc >= 0xd800 && wc < 0xe000)) + || wc == 0x0024 || wc == 0x0040 || wc == 0x0060) { + *pwc = wc; + return 10; + } + } else + goto simply_backslash; + } + return RET_ILSEQ; +simply_backslash: + *pwc = '\\'; + return 1; +} + +static int +c99_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0xa0) { + *r = wc; + return 1; + } else { + int result; + unsigned char u; + if (wc < 0x10000) { + result = 6; + u = 'u'; + } else { + result = 10; + u = 'U'; + } + if (n >= result) { + int count; + r[0] = '\\'; + r[1] = u; + r += 2; + for (count = result-3; count >= 0; count--) { + unsigned int i = (wc >> (4*count)) & 0x0f; + *r++ = (i < 10 ? '0'+i : 'a'-10+i); + } + return result; + } else + return RET_TOOSMALL; + } +} diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical.h b/graf2d/win32gdk/gdk/src/iconv/canonical.h new file mode 100644 index 0000000000000..136cf7556d248 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical.h @@ -0,0 +1,109 @@ + (int)(long)&((struct stringpool_t *)0)->stringpool_str287, + (int)(long)&((struct stringpool_t *)0)->stringpool_str255, + (int)(long)&((struct stringpool_t *)0)->stringpool_str179, + (int)(long)&((struct stringpool_t *)0)->stringpool_str367, + (int)(long)&((struct stringpool_t *)0)->stringpool_str283, + (int)(long)&((struct stringpool_t *)0)->stringpool_str263, + (int)(long)&((struct stringpool_t *)0)->stringpool_str409, + (int)(long)&((struct stringpool_t *)0)->stringpool_str325, + (int)(long)&((struct stringpool_t *)0)->stringpool_str242, + (int)(long)&((struct stringpool_t *)0)->stringpool_str434, + (int)(long)&((struct stringpool_t *)0)->stringpool_str350, + (int)(long)&((struct stringpool_t *)0)->stringpool_str252, + (int)(long)&((struct stringpool_t *)0)->stringpool_str440, + (int)(long)&((struct stringpool_t *)0)->stringpool_str356, + (int)(long)&((struct stringpool_t *)0)->stringpool_str575, + (int)(long)&((struct stringpool_t *)0)->stringpool_str406, + (int)(long)&((struct stringpool_t *)0)->stringpool_str723, + (int)(long)&((struct stringpool_t *)0)->stringpool_str448, + (int)(long)&((struct stringpool_t *)0)->stringpool_str765, + (int)(long)&((struct stringpool_t *)0)->stringpool_str30, + (int)(long)&((struct stringpool_t *)0)->stringpool_str600, + (int)(long)&((struct stringpool_t *)0)->stringpool_str74, + (int)(long)&((struct stringpool_t *)0)->stringpool_str84, + (int)(long)&((struct stringpool_t *)0)->stringpool_str78, + (int)(long)&((struct stringpool_t *)0)->stringpool_str168, + (int)(long)&((struct stringpool_t *)0)->stringpool_str82, + (int)(long)&((struct stringpool_t *)0)->stringpool_str76, + (int)(long)&((struct stringpool_t *)0)->stringpool_str410, + (int)(long)&((struct stringpool_t *)0)->stringpool_str90, + (int)(long)&((struct stringpool_t *)0)->stringpool_str98, + (int)(long)&((struct stringpool_t *)0)->stringpool_str221, + (int)(long)&((struct stringpool_t *)0)->stringpool_str75, + (int)(long)&((struct stringpool_t *)0)->stringpool_str79, + (int)(long)&((struct stringpool_t *)0)->stringpool_str169, + (int)(long)&((struct stringpool_t *)0)->stringpool_str83, + (int)(long)&((struct stringpool_t *)0)->stringpool_str77, + (int)(long)&((struct stringpool_t *)0)->stringpool_str261, + (int)(long)&((struct stringpool_t *)0)->stringpool_str403, + (int)(long)&((struct stringpool_t *)0)->stringpool_str480, + (int)(long)&((struct stringpool_t *)0)->stringpool_str164, + (int)(long)&((struct stringpool_t *)0)->stringpool_str18, + (int)(long)&((struct stringpool_t *)0)->stringpool_str28, + (int)(long)&((struct stringpool_t *)0)->stringpool_str22, + (int)(long)&((struct stringpool_t *)0)->stringpool_str112, + (int)(long)&((struct stringpool_t *)0)->stringpool_str26, + (int)(long)&((struct stringpool_t *)0)->stringpool_str20, + (int)(long)&((struct stringpool_t *)0)->stringpool_str354, + (int)(long)&((struct stringpool_t *)0)->stringpool_str34, + (int)(long)&((struct stringpool_t *)0)->stringpool_str166, + (int)(long)&((struct stringpool_t *)0)->stringpool_str27, + (int)(long)&((struct stringpool_t *)0)->stringpool_str19, + (int)(long)&((struct stringpool_t *)0)->stringpool_str11, + (int)(long)&((struct stringpool_t *)0)->stringpool_str451, + (int)(long)&((struct stringpool_t *)0)->stringpool_str531, + (int)(long)&((struct stringpool_t *)0)->stringpool_str355, + (int)(long)&((struct stringpool_t *)0)->stringpool_str501, + (int)(long)&((struct stringpool_t *)0)->stringpool_str673, + (int)(long)&((struct stringpool_t *)0)->stringpool_str302, + (int)(long)&((struct stringpool_t *)0)->stringpool_str621, + (int)(long)&((struct stringpool_t *)0)->stringpool_str577, + (int)(long)&((struct stringpool_t *)0)->stringpool_str786, + (int)(long)&((struct stringpool_t *)0)->stringpool_str908, + (int)(long)&((struct stringpool_t *)0)->stringpool_str563, + (int)(long)&((struct stringpool_t *)0)->stringpool_str445, + (int)(long)&((struct stringpool_t *)0)->stringpool_str502, + (int)(long)&((struct stringpool_t *)0)->stringpool_str475, + (int)(long)&((struct stringpool_t *)0)->stringpool_str279, + (int)(long)&((struct stringpool_t *)0)->stringpool_str626, + (int)(long)&((struct stringpool_t *)0)->stringpool_str614, + (int)(long)&((struct stringpool_t *)0)->stringpool_str217, + (int)(long)&((struct stringpool_t *)0)->stringpool_str212, + (int)(long)&((struct stringpool_t *)0)->stringpool_str218, + (int)(long)&((struct stringpool_t *)0)->stringpool_str371, + (int)(long)&((struct stringpool_t *)0)->stringpool_str15, + (int)(long)&((struct stringpool_t *)0)->stringpool_str230, + (int)(long)&((struct stringpool_t *)0)->stringpool_str278, + (int)(long)&((struct stringpool_t *)0)->stringpool_str124, + (int)(long)&((struct stringpool_t *)0)->stringpool_str180, + (int)(long)&((struct stringpool_t *)0)->stringpool_str413, + (int)(long)&((struct stringpool_t *)0)->stringpool_str555, + (int)(long)&((struct stringpool_t *)0)->stringpool_str571, + (int)(long)&((struct stringpool_t *)0)->stringpool_str492, + (int)(long)&((struct stringpool_t *)0)->stringpool_str384, + (int)(long)&((struct stringpool_t *)0)->stringpool_str368, + (int)(long)&((struct stringpool_t *)0)->stringpool_str127, + (int)(long)&((struct stringpool_t *)0)->stringpool_str202, + (int)(long)&((struct stringpool_t *)0)->stringpool_str535, + (int)(long)&((struct stringpool_t *)0)->stringpool_str429, + (int)(long)&((struct stringpool_t *)0)->stringpool_str32, + (int)(long)&((struct stringpool_t *)0)->stringpool_str607, + (int)(long)&((struct stringpool_t *)0)->stringpool_str500, + (int)(long)&((struct stringpool_t *)0)->stringpool_str505, + (int)(long)&((struct stringpool_t *)0)->stringpool_str70, + (int)(long)&((struct stringpool_t *)0)->stringpool_str303, + (int)(long)&((struct stringpool_t *)0)->stringpool_str24, + (int)(long)&((struct stringpool_t *)0)->stringpool_str378, + (int)(long)&((struct stringpool_t *)0)->stringpool_str142, + (int)(long)&((struct stringpool_t *)0)->stringpool_str196, + (int)(long)&((struct stringpool_t *)0)->stringpool_str159, + (int)(long)&((struct stringpool_t *)0)->stringpool_str473, + (int)(long)&((struct stringpool_t *)0)->stringpool_str277, + (int)(long)&((struct stringpool_t *)0)->stringpool_str170, + (int)(long)&((struct stringpool_t *)0)->stringpool_str900, + (int)(long)&((struct stringpool_t *)0)->stringpool_str888, + (int)(long)&((struct stringpool_t *)0)->stringpool_str527, + (int)(long)&((struct stringpool_t *)0)->stringpool_str290, + (int)(long)&((struct stringpool_t *)0)->stringpool_str91, + (int)(long)&((struct stringpool_t *)0)->stringpool_str768, + (int)(long)&((struct stringpool_t *)0)->stringpool_str362, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_aix.h b/graf2d/win32gdk/gdk/src/iconv/canonical_aix.h new file mode 100644 index 0000000000000..6149bc1bf5a42 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_aix.h @@ -0,0 +1,9 @@ + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_0, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_1, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_2, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_3, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_4, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_5, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_6, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_10, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_14, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_aix_sysaix.h b/graf2d/win32gdk/gdk/src/iconv/canonical_aix_sysaix.h new file mode 100644 index 0000000000000..8b58d1fa8c94f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_aix_sysaix.h @@ -0,0 +1,9 @@ + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_0, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_2, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_4, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_6, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_8, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_10, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_12, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_16, + (int)(long)&((struct stringpool2_t *)0)->stringpool_aix_20, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_dos.h b/graf2d/win32gdk/gdk/src/iconv/canonical_dos.h new file mode 100644 index 0000000000000..aa82651cd4a71 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_dos.h @@ -0,0 +1,15 @@ + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_0, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_4, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_5, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_8, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_12, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_13, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_17, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_21, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_22, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_26, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_31, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_35, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_38, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_42, + (int)(long)&((struct stringpool2_t *)0)->stringpool_dos_47, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_extra.h b/graf2d/win32gdk/gdk/src/iconv/canonical_extra.h new file mode 100644 index 0000000000000..29678a084eca6 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_extra.h @@ -0,0 +1,7 @@ + (int)(long)&((struct stringpool2_t *)0)->stringpool_extra_0, + (int)(long)&((struct stringpool2_t *)0)->stringpool_extra_2, + (int)(long)&((struct stringpool2_t *)0)->stringpool_extra_4, + (int)(long)&((struct stringpool2_t *)0)->stringpool_extra_6, + (int)(long)&((struct stringpool2_t *)0)->stringpool_extra_7, + (int)(long)&((struct stringpool2_t *)0)->stringpool_extra_9, + (int)(long)&((struct stringpool2_t *)0)->stringpool_extra_11, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_local.h b/graf2d/win32gdk/gdk/src/iconv/canonical_local.h new file mode 100644 index 0000000000000..a2209a820c251 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_local.h @@ -0,0 +1,2 @@ + (int)(long)&((struct stringpool_t *)0)->stringpool_str271, + (int)(long)&((struct stringpool_t *)0)->stringpool_str664, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_local_sysaix.h b/graf2d/win32gdk/gdk/src/iconv/canonical_local_sysaix.h new file mode 100644 index 0000000000000..0d4b27ba57010 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_local_sysaix.h @@ -0,0 +1,2 @@ + (int)(long)&((struct stringpool_t *)0)->stringpool_str307, + (int)(long)&((struct stringpool_t *)0)->stringpool_str543, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_local_syshpux.h b/graf2d/win32gdk/gdk/src/iconv/canonical_local_syshpux.h new file mode 100644 index 0000000000000..8e969231a6be9 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_local_syshpux.h @@ -0,0 +1,2 @@ + (int)(long)&((struct stringpool_t *)0)->stringpool_str258, + (int)(long)&((struct stringpool_t *)0)->stringpool_str390, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_local_sysosf1.h b/graf2d/win32gdk/gdk/src/iconv/canonical_local_sysosf1.h new file mode 100644 index 0000000000000..e1f886c0d9e5f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_local_sysosf1.h @@ -0,0 +1,2 @@ + (int)(long)&((struct stringpool_t *)0)->stringpool_str275, + (int)(long)&((struct stringpool_t *)0)->stringpool_str465, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_local_syssolaris.h b/graf2d/win32gdk/gdk/src/iconv/canonical_local_syssolaris.h new file mode 100644 index 0000000000000..ce73d70655d10 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_local_syssolaris.h @@ -0,0 +1,2 @@ + (int)(long)&((struct stringpool_t *)0)->stringpool_str38, + (int)(long)&((struct stringpool_t *)0)->stringpool_str515, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_osf1.h b/graf2d/win32gdk/gdk/src/iconv/canonical_osf1.h new file mode 100644 index 0000000000000..0e134ac31744d --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_osf1.h @@ -0,0 +1,2 @@ + (int)(long)&((struct stringpool2_t *)0)->stringpool_osf1_0, + (int)(long)&((struct stringpool2_t *)0)->stringpool_osf1_1, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_osf1_sysosf1.h b/graf2d/win32gdk/gdk/src/iconv/canonical_osf1_sysosf1.h new file mode 100644 index 0000000000000..15c27690892d7 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_osf1_sysosf1.h @@ -0,0 +1,2 @@ + (int)(long)&((struct stringpool2_t *)0)->stringpool_osf1_0, + (int)(long)&((struct stringpool2_t *)0)->stringpool_osf1_2, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_sysaix.h b/graf2d/win32gdk/gdk/src/iconv/canonical_sysaix.h new file mode 100644 index 0000000000000..73f0e5d309175 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_sysaix.h @@ -0,0 +1,109 @@ + (int)(long)&((struct stringpool_t *)0)->stringpool_str383, + (int)(long)&((struct stringpool_t *)0)->stringpool_str363, + (int)(long)&((struct stringpool_t *)0)->stringpool_str231, + (int)(long)&((struct stringpool_t *)0)->stringpool_str604, + (int)(long)&((struct stringpool_t *)0)->stringpool_str483, + (int)(long)&((struct stringpool_t *)0)->stringpool_str327, + (int)(long)&((struct stringpool_t *)0)->stringpool_str652, + (int)(long)&((struct stringpool_t *)0)->stringpool_str531, + (int)(long)&((struct stringpool_t *)0)->stringpool_str358, + (int)(long)&((struct stringpool_t *)0)->stringpool_str733, + (int)(long)&((struct stringpool_t *)0)->stringpool_str612, + (int)(long)&((struct stringpool_t *)0)->stringpool_str364, + (int)(long)&((struct stringpool_t *)0)->stringpool_str737, + (int)(long)&((struct stringpool_t *)0)->stringpool_str616, + (int)(long)&((struct stringpool_t *)0)->stringpool_str685, + (int)(long)&((struct stringpool_t *)0)->stringpool_str501, + (int)(long)&((struct stringpool_t *)0)->stringpool_str654, + (int)(long)&((struct stringpool_t *)0)->stringpool_str549, + (int)(long)&((struct stringpool_t *)0)->stringpool_str702, + (int)(long)&((struct stringpool_t *)0)->stringpool_str53, + (int)(long)&((struct stringpool_t *)0)->stringpool_str891, + (int)(long)&((struct stringpool_t *)0)->stringpool_str103, + (int)(long)&((struct stringpool_t *)0)->stringpool_str109, + (int)(long)&((struct stringpool_t *)0)->stringpool_str107, + (int)(long)&((struct stringpool_t *)0)->stringpool_str205, + (int)(long)&((struct stringpool_t *)0)->stringpool_str111, + (int)(long)&((struct stringpool_t *)0)->stringpool_str105, + (int)(long)&((struct stringpool_t *)0)->stringpool_str437, + (int)(long)&((struct stringpool_t *)0)->stringpool_str115, + (int)(long)&((struct stringpool_t *)0)->stringpool_str141, + (int)(long)&((struct stringpool_t *)0)->stringpool_str246, + (int)(long)&((struct stringpool_t *)0)->stringpool_str108, + (int)(long)&((struct stringpool_t *)0)->stringpool_str112, + (int)(long)&((struct stringpool_t *)0)->stringpool_str210, + (int)(long)&((struct stringpool_t *)0)->stringpool_str116, + (int)(long)&((struct stringpool_t *)0)->stringpool_str110, + (int)(long)&((struct stringpool_t *)0)->stringpool_str254, + (int)(long)&((struct stringpool_t *)0)->stringpool_str492, + (int)(long)&((struct stringpool_t *)0)->stringpool_str569, + (int)(long)&((struct stringpool_t *)0)->stringpool_str175, + (int)(long)&((struct stringpool_t *)0)->stringpool_str37, + (int)(long)&((struct stringpool_t *)0)->stringpool_str43, + (int)(long)&((struct stringpool_t *)0)->stringpool_str41, + (int)(long)&((struct stringpool_t *)0)->stringpool_str139, + (int)(long)&((struct stringpool_t *)0)->stringpool_str45, + (int)(long)&((struct stringpool_t *)0)->stringpool_str39, + (int)(long)&((struct stringpool_t *)0)->stringpool_str371, + (int)(long)&((struct stringpool_t *)0)->stringpool_str49, + (int)(long)&((struct stringpool_t *)0)->stringpool_str173, + (int)(long)&((struct stringpool_t *)0)->stringpool_str38, + (int)(long)&((struct stringpool_t *)0)->stringpool_str34, + (int)(long)&((struct stringpool_t *)0)->stringpool_str32, + (int)(long)&((struct stringpool_t *)0)->stringpool_str525, + (int)(long)&((struct stringpool_t *)0)->stringpool_str797, + (int)(long)&((struct stringpool_t *)0)->stringpool_str462, + (int)(long)&((struct stringpool_t *)0)->stringpool_str583, + (int)(long)&((struct stringpool_t *)0)->stringpool_str807, + (int)(long)&((struct stringpool_t *)0)->stringpool_str272, + (int)(long)&((struct stringpool_t *)0)->stringpool_str898, + (int)(long)&((struct stringpool_t *)0)->stringpool_str606, + (int)(long)&((struct stringpool_t *)0)->stringpool_str662, + (int)(long)&((struct stringpool_t *)0)->stringpool_str989, + (int)(long)&((struct stringpool_t *)0)->stringpool_str648, + (int)(long)&((struct stringpool_t *)0)->stringpool_str391, + (int)(long)&((struct stringpool_t *)0)->stringpool_str487, + (int)(long)&((struct stringpool_t *)0)->stringpool_str413, + (int)(long)&((struct stringpool_t *)0)->stringpool_str330, + (int)(long)&((struct stringpool_t *)0)->stringpool_str461, + (int)(long)&((struct stringpool_t *)0)->stringpool_str335, + (int)(long)&((struct stringpool_t *)0)->stringpool_str152, + (int)(long)&((struct stringpool_t *)0)->stringpool_str171, + (int)(long)&((struct stringpool_t *)0)->stringpool_str234, + (int)(long)&((struct stringpool_t *)0)->stringpool_str445, + (int)(long)&((struct stringpool_t *)0)->stringpool_str36, + (int)(long)&((struct stringpool_t *)0)->stringpool_str207, + (int)(long)&((struct stringpool_t *)0)->stringpool_str300, + (int)(long)&((struct stringpool_t *)0)->stringpool_str217, + (int)(long)&((struct stringpool_t *)0)->stringpool_str256, + (int)(long)&((struct stringpool_t *)0)->stringpool_str567, + (int)(long)&((struct stringpool_t *)0)->stringpool_str723, + (int)(long)&((struct stringpool_t *)0)->stringpool_str735, + (int)(long)&((struct stringpool_t *)0)->stringpool_str660, + (int)(long)&((struct stringpool_t *)0)->stringpool_str258, + (int)(long)&((struct stringpool_t *)0)->stringpool_str235, + (int)(long)&((struct stringpool_t *)0)->stringpool_str149, + (int)(long)&((struct stringpool_t *)0)->stringpool_str202, + (int)(long)&((struct stringpool_t *)0)->stringpool_str638, + (int)(long)&((struct stringpool_t *)0)->stringpool_str613, + (int)(long)&((struct stringpool_t *)0)->stringpool_str52, + (int)(long)&((struct stringpool_t *)0)->stringpool_str629, + (int)(long)&((struct stringpool_t *)0)->stringpool_str591, + (int)(long)&((struct stringpool_t *)0)->stringpool_str594, + (int)(long)&((struct stringpool_t *)0)->stringpool_str188, + (int)(long)&((struct stringpool_t *)0)->stringpool_str146, + (int)(long)&((struct stringpool_t *)0)->stringpool_str48, + (int)(long)&((struct stringpool_t *)0)->stringpool_str251, + (int)(long)&((struct stringpool_t *)0)->stringpool_str179, + (int)(long)&((struct stringpool_t *)0)->stringpool_str190, + (int)(long)&((struct stringpool_t *)0)->stringpool_str92, + (int)(long)&((struct stringpool_t *)0)->stringpool_str495, + (int)(long)&((struct stringpool_t *)0)->stringpool_str153, + (int)(long)&((struct stringpool_t *)0)->stringpool_str186, + (int)(long)&((struct stringpool_t *)0)->stringpool_str603, + (int)(long)&((struct stringpool_t *)0)->stringpool_str584, + (int)(long)&((struct stringpool_t *)0)->stringpool_str324, + (int)(long)&((struct stringpool_t *)0)->stringpool_str369, + (int)(long)&((struct stringpool_t *)0)->stringpool_str133, + (int)(long)&((struct stringpool_t *)0)->stringpool_str885, + (int)(long)&((struct stringpool_t *)0)->stringpool_str360, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_syshpux.h b/graf2d/win32gdk/gdk/src/iconv/canonical_syshpux.h new file mode 100644 index 0000000000000..53ed782e316cb --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_syshpux.h @@ -0,0 +1,109 @@ + (int)(long)&((struct stringpool_t *)0)->stringpool_str310, + (int)(long)&((struct stringpool_t *)0)->stringpool_str368, + (int)(long)&((struct stringpool_t *)0)->stringpool_str293, + (int)(long)&((struct stringpool_t *)0)->stringpool_str464, + (int)(long)&((struct stringpool_t *)0)->stringpool_str525, + (int)(long)&((struct stringpool_t *)0)->stringpool_str395, + (int)(long)&((struct stringpool_t *)0)->stringpool_str515, + (int)(long)&((struct stringpool_t *)0)->stringpool_str576, + (int)(long)&((struct stringpool_t *)0)->stringpool_str355, + (int)(long)&((struct stringpool_t *)0)->stringpool_str521, + (int)(long)&((struct stringpool_t *)0)->stringpool_str582, + (int)(long)&((struct stringpool_t *)0)->stringpool_str363, + (int)(long)&((struct stringpool_t *)0)->stringpool_str534, + (int)(long)&((struct stringpool_t *)0)->stringpool_str595, + (int)(long)&((struct stringpool_t *)0)->stringpool_str440, + (int)(long)&((struct stringpool_t *)0)->stringpool_str665, + (int)(long)&((struct stringpool_t *)0)->stringpool_str644, + (int)(long)&((struct stringpool_t *)0)->stringpool_str716, + (int)(long)&((struct stringpool_t *)0)->stringpool_str695, + (int)(long)&((struct stringpool_t *)0)->stringpool_str36, + (int)(long)&((struct stringpool_t *)0)->stringpool_str596, + (int)(long)&((struct stringpool_t *)0)->stringpool_str64, + (int)(long)&((struct stringpool_t *)0)->stringpool_str60, + (int)(long)&((struct stringpool_t *)0)->stringpool_str100, + (int)(long)&((struct stringpool_t *)0)->stringpool_str162, + (int)(long)&((struct stringpool_t *)0)->stringpool_str76, + (int)(long)&((struct stringpool_t *)0)->stringpool_str70, + (int)(long)&((struct stringpool_t *)0)->stringpool_str158, + (int)(long)&((struct stringpool_t *)0)->stringpool_str86, + (int)(long)&((struct stringpool_t *)0)->stringpool_str92, + (int)(long)&((struct stringpool_t *)0)->stringpool_str177, + (int)(long)&((struct stringpool_t *)0)->stringpool_str67, + (int)(long)&((struct stringpool_t *)0)->stringpool_str103, + (int)(long)&((struct stringpool_t *)0)->stringpool_str165, + (int)(long)&((struct stringpool_t *)0)->stringpool_str79, + (int)(long)&((struct stringpool_t *)0)->stringpool_str73, + (int)(long)&((struct stringpool_t *)0)->stringpool_str345, + (int)(long)&((struct stringpool_t *)0)->stringpool_str669, + (int)(long)&((struct stringpool_t *)0)->stringpool_str790, + (int)(long)&((struct stringpool_t *)0)->stringpool_str131, + (int)(long)&((struct stringpool_t *)0)->stringpool_str21, + (int)(long)&((struct stringpool_t *)0)->stringpool_str17, + (int)(long)&((struct stringpool_t *)0)->stringpool_str57, + (int)(long)&((struct stringpool_t *)0)->stringpool_str119, + (int)(long)&((struct stringpool_t *)0)->stringpool_str33, + (int)(long)&((struct stringpool_t *)0)->stringpool_str27, + (int)(long)&((struct stringpool_t *)0)->stringpool_str115, + (int)(long)&((struct stringpool_t *)0)->stringpool_str43, + (int)(long)&((struct stringpool_t *)0)->stringpool_str141, + (int)(long)&((struct stringpool_t *)0)->stringpool_str24, + (int)(long)&((struct stringpool_t *)0)->stringpool_str34, + (int)(long)&((struct stringpool_t *)0)->stringpool_str35, + (int)(long)&((struct stringpool_t *)0)->stringpool_str448, + (int)(long)&((struct stringpool_t *)0)->stringpool_str561, + (int)(long)&((struct stringpool_t *)0)->stringpool_str410, + (int)(long)&((struct stringpool_t *)0)->stringpool_str335, + (int)(long)&((struct stringpool_t *)0)->stringpool_str470, + (int)(long)&((struct stringpool_t *)0)->stringpool_str704, + (int)(long)&((struct stringpool_t *)0)->stringpool_str685, + (int)(long)&((struct stringpool_t *)0)->stringpool_str607, + (int)(long)&((struct stringpool_t *)0)->stringpool_str689, + (int)(long)&((struct stringpool_t *)0)->stringpool_str800, + (int)(long)&((struct stringpool_t *)0)->stringpool_str454, + (int)(long)&((struct stringpool_t *)0)->stringpool_str195, + (int)(long)&((struct stringpool_t *)0)->stringpool_str331, + (int)(long)&((struct stringpool_t *)0)->stringpool_str484, + (int)(long)&((struct stringpool_t *)0)->stringpool_str202, + (int)(long)&((struct stringpool_t *)0)->stringpool_str449, + (int)(long)&((struct stringpool_t *)0)->stringpool_str513, + (int)(long)&((struct stringpool_t *)0)->stringpool_str139, + (int)(long)&((struct stringpool_t *)0)->stringpool_str190, + (int)(long)&((struct stringpool_t *)0)->stringpool_str262, + (int)(long)&((struct stringpool_t *)0)->stringpool_str603, + (int)(long)&((struct stringpool_t *)0)->stringpool_str71, + (int)(long)&((struct stringpool_t *)0)->stringpool_str149, + (int)(long)&((struct stringpool_t *)0)->stringpool_str170, + (int)(long)&((struct stringpool_t *)0)->stringpool_str251, + (int)(long)&((struct stringpool_t *)0)->stringpool_str271, + (int)(long)&((struct stringpool_t *)0)->stringpool_str450, + (int)(long)&((struct stringpool_t *)0)->stringpool_str769, + (int)(long)&((struct stringpool_t *)0)->stringpool_str791, + (int)(long)&((struct stringpool_t *)0)->stringpool_str710, + (int)(long)&((struct stringpool_t *)0)->stringpool_str354, + (int)(long)&((struct stringpool_t *)0)->stringpool_str332, + (int)(long)&((struct stringpool_t *)0)->stringpool_str153, + (int)(long)&((struct stringpool_t *)0)->stringpool_str203, + (int)(long)&((struct stringpool_t *)0)->stringpool_str491, + (int)(long)&((struct stringpool_t *)0)->stringpool_str461, + (int)(long)&((struct stringpool_t *)0)->stringpool_str42, + (int)(long)&((struct stringpool_t *)0)->stringpool_str542, + (int)(long)&((struct stringpool_t *)0)->stringpool_str473, + (int)(long)&((struct stringpool_t *)0)->stringpool_str471, + (int)(long)&((struct stringpool_t *)0)->stringpool_str30, + (int)(long)&((struct stringpool_t *)0)->stringpool_str314, + (int)(long)&((struct stringpool_t *)0)->stringpool_str52, + (int)(long)&((struct stringpool_t *)0)->stringpool_str352, + (int)(long)&((struct stringpool_t *)0)->stringpool_str81, + (int)(long)&((struct stringpool_t *)0)->stringpool_str96, + (int)(long)&((struct stringpool_t *)0)->stringpool_str12, + (int)(long)&((struct stringpool_t *)0)->stringpool_str378, + (int)(long)&((struct stringpool_t *)0)->stringpool_str308, + (int)(long)&((struct stringpool_t *)0)->stringpool_str144, + (int)(long)&((struct stringpool_t *)0)->stringpool_str771, + (int)(long)&((struct stringpool_t *)0)->stringpool_str757, + (int)(long)&((struct stringpool_t *)0)->stringpool_str421, + (int)(long)&((struct stringpool_t *)0)->stringpool_str343, + (int)(long)&((struct stringpool_t *)0)->stringpool_str105, + (int)(long)&((struct stringpool_t *)0)->stringpool_str654, + (int)(long)&((struct stringpool_t *)0)->stringpool_str394, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_sysosf1.h b/graf2d/win32gdk/gdk/src/iconv/canonical_sysosf1.h new file mode 100644 index 0000000000000..62f642e93e778 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_sysosf1.h @@ -0,0 +1,109 @@ + (int)(long)&((struct stringpool_t *)0)->stringpool_str343, + (int)(long)&((struct stringpool_t *)0)->stringpool_str268, + (int)(long)&((struct stringpool_t *)0)->stringpool_str223, + (int)(long)&((struct stringpool_t *)0)->stringpool_str591, + (int)(long)&((struct stringpool_t *)0)->stringpool_str433, + (int)(long)&((struct stringpool_t *)0)->stringpool_str319, + (int)(long)&((struct stringpool_t *)0)->stringpool_str639, + (int)(long)&((struct stringpool_t *)0)->stringpool_str481, + (int)(long)&((struct stringpool_t *)0)->stringpool_str263, + (int)(long)&((struct stringpool_t *)0)->stringpool_str633, + (int)(long)&((struct stringpool_t *)0)->stringpool_str475, + (int)(long)&((struct stringpool_t *)0)->stringpool_str269, + (int)(long)&((struct stringpool_t *)0)->stringpool_str637, + (int)(long)&((struct stringpool_t *)0)->stringpool_str479, + (int)(long)&((struct stringpool_t *)0)->stringpool_str560, + (int)(long)&((struct stringpool_t *)0)->stringpool_str472, + (int)(long)&((struct stringpool_t *)0)->stringpool_str695, + (int)(long)&((struct stringpool_t *)0)->stringpool_str520, + (int)(long)&((struct stringpool_t *)0)->stringpool_str743, + (int)(long)&((struct stringpool_t *)0)->stringpool_str53, + (int)(long)&((struct stringpool_t *)0)->stringpool_str711, + (int)(long)&((struct stringpool_t *)0)->stringpool_str103, + (int)(long)&((struct stringpool_t *)0)->stringpool_str109, + (int)(long)&((struct stringpool_t *)0)->stringpool_str107, + (int)(long)&((struct stringpool_t *)0)->stringpool_str205, + (int)(long)&((struct stringpool_t *)0)->stringpool_str111, + (int)(long)&((struct stringpool_t *)0)->stringpool_str105, + (int)(long)&((struct stringpool_t *)0)->stringpool_str407, + (int)(long)&((struct stringpool_t *)0)->stringpool_str115, + (int)(long)&((struct stringpool_t *)0)->stringpool_str141, + (int)(long)&((struct stringpool_t *)0)->stringpool_str246, + (int)(long)&((struct stringpool_t *)0)->stringpool_str108, + (int)(long)&((struct stringpool_t *)0)->stringpool_str112, + (int)(long)&((struct stringpool_t *)0)->stringpool_str210, + (int)(long)&((struct stringpool_t *)0)->stringpool_str116, + (int)(long)&((struct stringpool_t *)0)->stringpool_str110, + (int)(long)&((struct stringpool_t *)0)->stringpool_str280, + (int)(long)&((struct stringpool_t *)0)->stringpool_str410, + (int)(long)&((struct stringpool_t *)0)->stringpool_str487, + (int)(long)&((struct stringpool_t *)0)->stringpool_str175, + (int)(long)&((struct stringpool_t *)0)->stringpool_str37, + (int)(long)&((struct stringpool_t *)0)->stringpool_str43, + (int)(long)&((struct stringpool_t *)0)->stringpool_str41, + (int)(long)&((struct stringpool_t *)0)->stringpool_str139, + (int)(long)&((struct stringpool_t *)0)->stringpool_str45, + (int)(long)&((struct stringpool_t *)0)->stringpool_str39, + (int)(long)&((struct stringpool_t *)0)->stringpool_str341, + (int)(long)&((struct stringpool_t *)0)->stringpool_str49, + (int)(long)&((struct stringpool_t *)0)->stringpool_str173, + (int)(long)&((struct stringpool_t *)0)->stringpool_str38, + (int)(long)&((struct stringpool_t *)0)->stringpool_str34, + (int)(long)&((struct stringpool_t *)0)->stringpool_str32, + (int)(long)&((struct stringpool_t *)0)->stringpool_str543, + (int)(long)&((struct stringpool_t *)0)->stringpool_str727, + (int)(long)&((struct stringpool_t *)0)->stringpool_str428, + (int)(long)&((struct stringpool_t *)0)->stringpool_str544, + (int)(long)&((struct stringpool_t *)0)->stringpool_str761, + (int)(long)&((struct stringpool_t *)0)->stringpool_str281, + (int)(long)&((struct stringpool_t *)0)->stringpool_str821, + (int)(long)&((struct stringpool_t *)0)->stringpool_str649, + (int)(long)&((struct stringpool_t *)0)->stringpool_str661, + (int)(long)&((struct stringpool_t *)0)->stringpool_str939, + (int)(long)&((struct stringpool_t *)0)->stringpool_str646, + (int)(long)&((struct stringpool_t *)0)->stringpool_str362, + (int)(long)&((struct stringpool_t *)0)->stringpool_str458, + (int)(long)&((struct stringpool_t *)0)->stringpool_str500, + (int)(long)&((struct stringpool_t *)0)->stringpool_str369, + (int)(long)&((struct stringpool_t *)0)->stringpool_str397, + (int)(long)&((struct stringpool_t *)0)->stringpool_str442, + (int)(long)&((struct stringpool_t *)0)->stringpool_str178, + (int)(long)&((struct stringpool_t *)0)->stringpool_str202, + (int)(long)&((struct stringpool_t *)0)->stringpool_str234, + (int)(long)&((struct stringpool_t *)0)->stringpool_str417, + (int)(long)&((struct stringpool_t *)0)->stringpool_str36, + (int)(long)&((struct stringpool_t *)0)->stringpool_str253, + (int)(long)&((struct stringpool_t *)0)->stringpool_str285, + (int)(long)&((struct stringpool_t *)0)->stringpool_str245, + (int)(long)&((struct stringpool_t *)0)->stringpool_str238, + (int)(long)&((struct stringpool_t *)0)->stringpool_str515, + (int)(long)&((struct stringpool_t *)0)->stringpool_str671, + (int)(long)&((struct stringpool_t *)0)->stringpool_str683, + (int)(long)&((struct stringpool_t *)0)->stringpool_str608, + (int)(long)&((struct stringpool_t *)0)->stringpool_str266, + (int)(long)&((struct stringpool_t *)0)->stringpool_str243, + (int)(long)&((struct stringpool_t *)0)->stringpool_str149, + (int)(long)&((struct stringpool_t *)0)->stringpool_str228, + (int)(long)&((struct stringpool_t *)0)->stringpool_str581, + (int)(long)&((struct stringpool_t *)0)->stringpool_str612, + (int)(long)&((struct stringpool_t *)0)->stringpool_str52, + (int)(long)&((struct stringpool_t *)0)->stringpool_str593, + (int)(long)&((struct stringpool_t *)0)->stringpool_str524, + (int)(long)&((struct stringpool_t *)0)->stringpool_str527, + (int)(long)&((struct stringpool_t *)0)->stringpool_str167, + (int)(long)&((struct stringpool_t *)0)->stringpool_str206, + (int)(long)&((struct stringpool_t *)0)->stringpool_str48, + (int)(long)&((struct stringpool_t *)0)->stringpool_str259, + (int)(long)&((struct stringpool_t *)0)->stringpool_str179, + (int)(long)&((struct stringpool_t *)0)->stringpool_str190, + (int)(long)&((struct stringpool_t *)0)->stringpool_str60, + (int)(long)&((struct stringpool_t *)0)->stringpool_str426, + (int)(long)&((struct stringpool_t *)0)->stringpool_str198, + (int)(long)&((struct stringpool_t *)0)->stringpool_str186, + (int)(long)&((struct stringpool_t *)0)->stringpool_str843, + (int)(long)&((struct stringpool_t *)0)->stringpool_str824, + (int)(long)&((struct stringpool_t *)0)->stringpool_str511, + (int)(long)&((struct stringpool_t *)0)->stringpool_str374, + (int)(long)&((struct stringpool_t *)0)->stringpool_str133, + (int)(long)&((struct stringpool_t *)0)->stringpool_str807, + (int)(long)&((struct stringpool_t *)0)->stringpool_str386, diff --git a/graf2d/win32gdk/gdk/src/iconv/canonical_syssolaris.h b/graf2d/win32gdk/gdk/src/iconv/canonical_syssolaris.h new file mode 100644 index 0000000000000..6e8c4abb7ead4 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/canonical_syssolaris.h @@ -0,0 +1,109 @@ + (int)(long)&((struct stringpool_t *)0)->stringpool_str463, + (int)(long)&((struct stringpool_t *)0)->stringpool_str258, + (int)(long)&((struct stringpool_t *)0)->stringpool_str314, + (int)(long)&((struct stringpool_t *)0)->stringpool_str482, + (int)(long)&((struct stringpool_t *)0)->stringpool_str365, + (int)(long)&((struct stringpool_t *)0)->stringpool_str278, + (int)(long)&((struct stringpool_t *)0)->stringpool_str464, + (int)(long)&((struct stringpool_t *)0)->stringpool_str347, + (int)(long)&((struct stringpool_t *)0)->stringpool_str279, + (int)(long)&((struct stringpool_t *)0)->stringpool_str470, + (int)(long)&((struct stringpool_t *)0)->stringpool_str353, + (int)(long)&((struct stringpool_t *)0)->stringpool_str378, + (int)(long)&((struct stringpool_t *)0)->stringpool_str546, + (int)(long)&((struct stringpool_t *)0)->stringpool_str429, + (int)(long)&((struct stringpool_t *)0)->stringpool_str588, + (int)(long)&((struct stringpool_t *)0)->stringpool_str510, + (int)(long)&((struct stringpool_t *)0)->stringpool_str563, + (int)(long)&((struct stringpool_t *)0)->stringpool_str492, + (int)(long)&((struct stringpool_t *)0)->stringpool_str545, + (int)(long)&((struct stringpool_t *)0)->stringpool_str30, + (int)(long)&((struct stringpool_t *)0)->stringpool_str569, + (int)(long)&((struct stringpool_t *)0)->stringpool_str124, + (int)(long)&((struct stringpool_t *)0)->stringpool_str184, + (int)(long)&((struct stringpool_t *)0)->stringpool_str230, + (int)(long)&((struct stringpool_t *)0)->stringpool_str148, + (int)(long)&((struct stringpool_t *)0)->stringpool_str160, + (int)(long)&((struct stringpool_t *)0)->stringpool_str138, + (int)(long)&((struct stringpool_t *)0)->stringpool_str452, + (int)(long)&((struct stringpool_t *)0)->stringpool_str122, + (int)(long)&((struct stringpool_t *)0)->stringpool_str136, + (int)(long)&((struct stringpool_t *)0)->stringpool_str175, + (int)(long)&((struct stringpool_t *)0)->stringpool_str129, + (int)(long)&((struct stringpool_t *)0)->stringpool_str235, + (int)(long)&((struct stringpool_t *)0)->stringpool_str153, + (int)(long)&((struct stringpool_t *)0)->stringpool_str165, + (int)(long)&((struct stringpool_t *)0)->stringpool_str143, + (int)(long)&((struct stringpool_t *)0)->stringpool_str276, + (int)(long)&((struct stringpool_t *)0)->stringpool_str680, + (int)(long)&((struct stringpool_t *)0)->stringpool_str684, + (int)(long)&((struct stringpool_t *)0)->stringpool_str127, + (int)(long)&((struct stringpool_t *)0)->stringpool_str81, + (int)(long)&((struct stringpool_t *)0)->stringpool_str141, + (int)(long)&((struct stringpool_t *)0)->stringpool_str187, + (int)(long)&((struct stringpool_t *)0)->stringpool_str105, + (int)(long)&((struct stringpool_t *)0)->stringpool_str117, + (int)(long)&((struct stringpool_t *)0)->stringpool_str95, + (int)(long)&((struct stringpool_t *)0)->stringpool_str409, + (int)(long)&((struct stringpool_t *)0)->stringpool_str79, + (int)(long)&((struct stringpool_t *)0)->stringpool_str91, + (int)(long)&((struct stringpool_t *)0)->stringpool_str94, + (int)(long)&((struct stringpool_t *)0)->stringpool_str48, + (int)(long)&((struct stringpool_t *)0)->stringpool_str86, + (int)(long)&((struct stringpool_t *)0)->stringpool_str387, + (int)(long)&((struct stringpool_t *)0)->stringpool_str451, + (int)(long)&((struct stringpool_t *)0)->stringpool_str346, + (int)(long)&((struct stringpool_t *)0)->stringpool_str415, + (int)(long)&((struct stringpool_t *)0)->stringpool_str489, + (int)(long)&((struct stringpool_t *)0)->stringpool_str389, + (int)(long)&((struct stringpool_t *)0)->stringpool_str752, + (int)(long)&((struct stringpool_t *)0)->stringpool_str774, + (int)(long)&((struct stringpool_t *)0)->stringpool_str953, + (int)(long)&((struct stringpool_t *)0)->stringpool_str853, + (int)(long)&((struct stringpool_t *)0)->stringpool_str432, + (int)(long)&((struct stringpool_t *)0)->stringpool_str513, + (int)(long)&((struct stringpool_t *)0)->stringpool_str297, + (int)(long)&((struct stringpool_t *)0)->stringpool_str502, + (int)(long)&((struct stringpool_t *)0)->stringpool_str372, + (int)(long)&((struct stringpool_t *)0)->stringpool_str412, + (int)(long)&((struct stringpool_t *)0)->stringpool_str419, + (int)(long)&((struct stringpool_t *)0)->stringpool_str478, + (int)(long)&((struct stringpool_t *)0)->stringpool_str71, + (int)(long)&((struct stringpool_t *)0)->stringpool_str62, + (int)(long)&((struct stringpool_t *)0)->stringpool_str266, + (int)(long)&((struct stringpool_t *)0)->stringpool_str192, + (int)(long)&((struct stringpool_t *)0)->stringpool_str246, + (int)(long)&((struct stringpool_t *)0)->stringpool_str215, + (int)(long)&((struct stringpool_t *)0)->stringpool_str424, + (int)(long)&((struct stringpool_t *)0)->stringpool_str307, + (int)(long)&((struct stringpool_t *)0)->stringpool_str507, + (int)(long)&((struct stringpool_t *)0)->stringpool_str669, + (int)(long)&((struct stringpool_t *)0)->stringpool_str667, + (int)(long)&((struct stringpool_t *)0)->stringpool_str706, + (int)(long)&((struct stringpool_t *)0)->stringpool_str211, + (int)(long)&((struct stringpool_t *)0)->stringpool_str320, + (int)(long)&((struct stringpool_t *)0)->stringpool_str202, + (int)(long)&((struct stringpool_t *)0)->stringpool_str283, + (int)(long)&((struct stringpool_t *)0)->stringpool_str400, + (int)(long)&((struct stringpool_t *)0)->stringpool_str714, + (int)(long)&((struct stringpool_t *)0)->stringpool_str147, + (int)(long)&((struct stringpool_t *)0)->stringpool_str556, + (int)(long)&((struct stringpool_t *)0)->stringpool_str554, + (int)(long)&((struct stringpool_t *)0)->stringpool_str584, + (int)(long)&((struct stringpool_t *)0)->stringpool_str67, + (int)(long)&((struct stringpool_t *)0)->stringpool_str516, + (int)(long)&((struct stringpool_t *)0)->stringpool_str101, + (int)(long)&((struct stringpool_t *)0)->stringpool_str271, + (int)(long)&((struct stringpool_t *)0)->stringpool_str223, + (int)(long)&((struct stringpool_t *)0)->stringpool_str327, + (int)(long)&((struct stringpool_t *)0)->stringpool_str99, + (int)(long)&((struct stringpool_t *)0)->stringpool_str540, + (int)(long)&((struct stringpool_t *)0)->stringpool_str293, + (int)(long)&((struct stringpool_t *)0)->stringpool_str98, + (int)(long)&((struct stringpool_t *)0)->stringpool_str901, + (int)(long)&((struct stringpool_t *)0)->stringpool_str895, + (int)(long)&((struct stringpool_t *)0)->stringpool_str666, + (int)(long)&((struct stringpool_t *)0)->stringpool_str255, + (int)(long)&((struct stringpool_t *)0)->stringpool_str58, + (int)(long)&((struct stringpool_t *)0)->stringpool_str691, + (int)(long)&((struct stringpool_t *)0)->stringpool_str411, diff --git a/graf2d/win32gdk/gdk/src/iconv/ces_big5.h b/graf2d/win32gdk/gdk/src/iconv/ces_big5.h new file mode 100644 index 0000000000000..2f87735bcd395 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ces_big5.h @@ -0,0 +1,70 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * BIG-5 + */ + +static int +ces_big5_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + /* Code set 0 (ASCII) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (BIG5) */ + if (c >= 0xa1 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0xa1 && c2 < 0xff)) + return big5_mbtowc(conv,pwc,s,2); + else + return RET_ILSEQ; + } + } + return RET_ILSEQ; +} + +static int +ces_big5_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Code set 0 (ASCII) */ + ret = ascii_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + /* Code set 1 (BIG5) */ + ret = big5_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]; + r[1] = buf[1]; + return 2; + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/ces_gbk.h b/graf2d/win32gdk/gdk/src/iconv/ces_gbk.h new file mode 100644 index 0000000000000..69e61f7dc50f2 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ces_gbk.h @@ -0,0 +1,65 @@ +/* + * Copyright (C) 1999-2001, 2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GBK + */ + +static int +ces_gbk_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + + /* Code set 0 (ASCII or GB 1988-89) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (GBK) */ + if (c >= 0x81 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + return gbk_mbtowc(conv,pwc,s,2); + } + return RET_ILSEQ; +} + +static int +ces_gbk_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Code set 0 (ASCII or GB 1988-89) */ + ret = ascii_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + /* Code set 1 (GBK) */ + ret = gbk_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]; + r[1] = buf[1]; + return 2; + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cjk_variants.h b/graf2d/win32gdk/gdk/src/iconv/cjk_variants.h new file mode 100644 index 0000000000000..23cb4b3263c70 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cjk_variants.h @@ -0,0 +1,4241 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CJK variants table + */ + +static const unsigned short cjk_variants[12038] = { + 0x9e44, 0x1e2a, 0x200b, 0xcb87, 0xaf0c, 0x9e0a, 0x9e0b, 0xd42c, + 0x23c1, 0xaf0e, 0x9e04, 0x9e05, 0xa176, 0xd207, 0x2303, 0xa304, + 0x1e12, 0x619c, 0xeb57, 0x9e11, 0x2c02, 0xac08, 0x1e17, 0xa34b, + 0x1e16, 0xa34b, 0x1e20, 0xa775, 0xb96d, 0x23e2, 0x3a37, 0x3b09, + 0xd5c2, 0xb771, 0x4cf8, 0xcd72, 0x1e22, 0xa3be, 0x1e18, 0xa775, + 0x1e24, 0xa169, 0x1e1f, 0xa3be, 0xe149, 0x1e21, 0xa169, 0x23b3, + 0xa6b4, 0x20a1, 0x2e76, 0xcadd, 0xa5aa, 0x00f6, 0x200b, 0xcb87, + 0x3792, 0x3860, 0xb90f, 0xc23f, 0x5c4a, 0x5c50, 0x673b, 0x674a, + 0x68a8, 0xe8ce, 0x9e33, 0x9e32, 0xd1e8, 0x40ba, 0xc232, 0x2a6f, + 0xee97, 0x3319, 0x34e7, 0xd209, 0xa3ca, 0x2208, 0xd2c5, 0x2efc, + 0xdffa, 0x0006, 0x9e94, 0x1e46, 0xe579, 0x1e45, 0xe579, 0x2c1b, + 0x2e7a, 0x2e85, 0x6ebc, 0xeebd, 0xcfa9, 0xc0cf, 0x397d, 0xba02, + 0x1f17, 0x3500, 0x473e, 0xd846, 0xa5ac, 0x564e, 0xd65d, 0x1e58, + 0xb909, 0x1e57, 0xb909, 0x6690, 0x66a0, 0xe6b1, 0xcfd2, 0x60f7, + 0x6109, 0x610a, 0xe115, 0xb6f8, 0x2158, 0xa9cb, 0xdcb7, 0x1e82, + 0xe1e0, 0x1e7e, 0x1e81, 0xbf27, 0x1e79, 0x1e81, 0x2e72, 0xbf27, + 0x6f9c, 0xef9f, 0x1e79, 0x1e7e, 0xbf27, 0x1e71, 0xe1e0, 0x36b8, + 0xc7ad, 0xdc6b, 0xc22d, 0x1e8b, 0xa3d3, 0x1e8a, 0xa3d3, 0xaf0d, + 0x1e8f, 0x1e90, 0xb5bc, 0x1e8e, 0x1e90, 0x35bc, 0xd667, 0x1e8e, + 0x9e8f, 0x1f1d, 0xe6f2, 0x9e44, 0xa6db, 0x2c81, 0x2d57, 0x3b72, + 0xbb73, 0x9e99, 0x9e98, 0x1e9c, 0x9e9e, 0x1e9a, 0x9e9e, 0x3589, + 0x358a, 0x6f4a, 0xef50, 0x1e9a, 0x9e9c, 0xc10f, 0x1ebe, 0xa166, + 0x4522, 0xc523, 0x4546, 0x4552, 0x455d, 0xc55e, 0x9eaf, 0x9eb0, + 0x9eab, 0x9eac, 0xa91c, 0xd9aa, 0xd93b, 0xa6b2, 0x9ebb, 0x9eba, + 0x1ea1, 0xa166, 0xa104, 0xafce, 0x20cd, 0x22a8, 0xa2d5, 0x1ed8, + 0xa0c5, 0xa0d5, 0xdb8e, 0xa0df, 0x21ab, 0x21b0, 0xbc37, 0x2f93, + 0xaf9e, 0x9f5b, 0x1f1e, 0xa098, 0x1f96, 0x2d18, 0xad19, 0x1efa, + 0xa009, 0x9ec5, 0x20ca, 0xa0f2, 0xa40c, 0x9eed, 0xaf74, 0x214f, + 0x6577, 0x6578, 0xe57f, 0xa100, 0xa011, 0x9ede, 0x2047, 0xa3cd, + 0x1fa1, 0xa0f9, 0x1ed3, 0xa009, 0x9fc7, 0x2f6c, 0xb58c, 0x9f4e, + 0x2023, 0x2f77, 0x2fac, 0x4706, 0xeae3, 0x20a0, 0xc26b, 0xae11, + 0x1e51, 0x473e, 0xd846, 0xa12a, 0xa925, 0xb703, 0xa0b4, 0xa005, + 0x1e91, 0x1f20, 0xa0b3, 0x1ed0, 0x2098, 0xce56, 0xa049, 0x1f1d, + 0xa0b3, 0x9fe5, 0x9fd4, 0xa0b7, 0xa000, 0xa02b, 0xa096, 0x207d, + 0xa0de, 0x1f47, 0xcada, 0xa2aa, 0x1f32, 0x1f60, 0xa11e, 0x1f31, + 0x1f60, 0xa11e, 0x9f90, 0xd0c4, 0x9f40, 0x9f3c, 0xb014, 0x9f2b, + 0xae03, 0x9efe, 0x4b28, 0x5eb0, 0x5ec6, 0x6ab5, 0xead4, 0xa360, + 0x6918, 0xe980, 0x1ecf, 0x2f7f, 0xeaf4, 0xa05a, 0x9fab, 0x1f31, + 0x1f32, 0x211e, 0xa9b3, 0xa0ad, 0xa0c9, 0xaf8a, 0x3cd5, 0xc04b, + 0x2002, 0xae76, 0xaf88, 0xa058, 0x29b7, 0xa9ea, 0xb765, 0x6625, + 0x6634, 0x6670, 0xe682, 0xb549, 0x9f35, 0x9ed1, 0x5350, 0xd5a6, + 0x9fe0, 0x1ef7, 0xa0f9, 0x9fb6, 0xa0e5, 0x2075, 0xe049, 0xa074, + 0xa0d1, 0xa108, 0xa115, 0x9f5e, 0xa102, 0x2118, 0xac3d, 0xc7e6, + 0x9fa3, 0xac40, 0xc537, 0x9fe3, 0xccfb, 0x9efc, 0xa101, 0xdf14, + 0xc23c, 0x1f23, 0xb093, 0xa16a, 0xcae2, 0x9fa0, 0xda2b, 0x9fee, + 0x9fc1, 0x9f21, 0xa114, 0xa13c, 0xa006, 0xa137, 0xa008, 0x2039, + 0xa109, 0x1fe2, 0xd129, 0xa036, 0x209a, 0xb548, 0x2079, 0x2099, + 0x20c3, 0xa907, 0x4ca5, 0xeb3b, 0x30de, 0xbb23, 0x9f25, 0x1f75, + 0xae76, 0x207a, 0x24b1, 0xa592, 0x9f1c, 0x9fe9, 0x9feb, 0x1ed3, + 0x9efa, 0xa06c, 0x00f6, 0x1e2a, 0xcb87, 0xd146, 0xa010, 0xa00f, + 0x9eec, 0xae78, 0xa0b9, 0x2fa3, 0xd5c9, 0x1eff, 0xc706, 0xa03c, + 0x22b5, 0xa2cc, 0x9f26, 0xa25a, 0x9ff1, 0x1fed, 0xa109, 0xa0b5, + 0xa024, 0xa0be, 0xd2f1, 0xdcf0, 0x9eee, 0x9f1f, 0x5d0b, 0x5d17, + 0xdd5d, 0x9f83, 0xa0c0, 0x9f5c, 0xafa4, 0xe03c, 0x200a, 0xa0af, + 0x9fa7, 0x1fa6, 0xe049, 0xa078, 0xa077, 0x1ffb, 0x2099, 0x20c3, + 0xa907, 0x2003, 0x24b1, 0xa592, 0xa0c2, 0x1f2a, 0xa0de, 0xa0e8, + 0xa11f, 0x4f75, 0x69e1, 0xea82, 0xafac, 0xb770, 0x9f27, 0x1ed0, + 0x1f1e, 0xce56, 0x1ffb, 0x2079, 0x20c3, 0xa907, 0x1ff2, 0xb548, + 0xafad, 0x1f10, 0xc26b, 0x1e26, 0x2e76, 0xcadd, 0xabb6, 0xa10e, + 0xa13b, 0xa110, 0xa132, 0xa13a, 0x9f63, 0xa06c, 0x1f1d, 0x9f20, + 0x9f1b, 0xa03a, 0x9f24, 0xa01e, 0xa03e, 0xa059, 0xa07b, 0x1ffb, + 0x2079, 0x2099, 0xa907, 0xafb1, 0x9ec5, 0x9f65, 0x9ed9, 0x1ec2, + 0x22a8, 0xa2d5, 0x9fa8, 0x9ec6, 0xb55e, 0xc67b, 0x1f2a, 0xa07d, + 0x9ec9, 0xa0ed, 0x9fa5, 0xa07e, 0xa0f4, 0x3076, 0x30aa, 0xb0e1, + 0xa0e3, 0xe6c7, 0x9ed9, 0xa0e9, 0x1ef7, 0x9fa1, 0x9eea, 0x9fca, + 0x9fac, 0x9ebf, 0x9fa9, 0x1fed, 0xa039, 0xa0a4, 0xa0a7, 0x9fe6, + 0x9faa, 0x1fad, 0xac3d, 0x1f31, 0x1f32, 0x9f60, 0xa07f, 0xa139, + 0x9f18, 0xa0a8, 0x9fea, 0xa127, 0xa0a9, 0xa0a5, 0x9fe8, 0x2150, + 0xa152, 0xcc2a, 0xa1f6, 0x406e, 0xc097, 0x214c, 0xa151, 0x224b, + 0x22ca, 0xac05, 0x214a, 0xa151, 0xa154, 0x1ee7, 0x6577, 0x6578, + 0xe57f, 0x213f, 0xa152, 0x214a, 0xa14c, 0x213f, 0xa150, 0xa14e, + 0xa157, 0xa156, 0x1e68, 0xa9cb, 0xeee8, 0xa160, 0xa15c, 0xb5f7, + 0x1ea1, 0x9ebe, 0xa185, 0x1e21, 0x9e24, 0x9fde, 0xd62d, 0x2929, + 0x6754, 0xe75d, 0x24b2, 0x4b11, 0x65a2, 0x65d7, 0xe5dc, 0xd208, + 0x9e0c, 0x530a, 0xd332, 0x4faa, 0xe90a, 0x4363, 0xc378, 0xa180, + 0xa17e, 0xa6c5, 0xa18b, 0xae3d, 0xa189, 0xa167, 0x2706, 0x270e, + 0xa713, 0xaca1, 0xa184, 0x218c, 0xcb27, 0xa182, 0x218a, 0xcb27, + 0x226e, 0xa3e7, 0xa6e7, 0xa192, 0xd0c4, 0xa190, 0xab82, 0x21a9, + 0xabeb, 0xdecd, 0xdfb2, 0x2b90, 0xab9c, 0xa85a, 0xb700, 0xabc3, + 0x2bbc, 0xabc7, 0xabcc, 0x2199, 0xabeb, 0x2e42, 0xcf83, 0x1ecc, + 0x21b0, 0xbc37, 0x3638, 0xef15, 0xe9ae, 0x1ecc, 0x21ab, 0xbc37, + 0xa1b4, 0x3c96, 0xd85d, 0xbc7a, 0xa1b1, 0xbcc1, 0xbcef, 0xa1cd, + 0xbd0c, 0x21c8, 0xbde8, 0xbd7c, 0xbd82, 0x3053, 0x30bd, 0xbdd2, + 0xbdb8, 0x21d6, 0xbe96, 0xa1c0, 0xbdbc, 0xa1bb, 0xbe1b, 0xbe4a, + 0xc69a, 0xb817, 0x21c6, 0xbe96, 0x21dc, 0xbf9f, 0x21db, 0xbf9f, + 0x4108, 0x4155, 0x4188, 0xc199, 0x2e7e, 0xb73a, 0x21e2, 0xa1e3, + 0x21e1, 0xa1e3, 0x21e1, 0xa1e2, 0xecf3, 0xac45, 0x2904, 0xd655, + 0x21ec, 0x21ee, 0x68a8, 0x68cc, 0xe8ce, 0xece7, 0x21e8, 0x21ee, + 0x68a8, 0x68cc, 0xe8ce, 0x21f4, 0x317f, 0xb191, 0x21e8, 0x21ec, + 0x68a8, 0x68cc, 0xe8ce, 0xa1f1, 0xa1ef, 0x2c32, 0x2c34, 0x2c36, + 0x2c37, 0xeb50, 0xbac8, 0x21ed, 0x317f, 0xb191, 0xa147, 0x2757, + 0x284a, 0xa8a4, 0x2c80, 0xef63, 0x3483, 0xb4ca, 0xa1fe, 0xa1fd, + 0xe47f, 0x2202, 0xe1d6, 0x2200, 0xe1d6, 0xa204, 0xa203, 0x221b, + 0xa275, 0x1e42, 0xd2c5, 0xb81e, 0xd2bb, 0x2283, 0x2290, 0xc53b, + 0xa6ed, 0xb289, 0xa289, 0xa247, 0xa25b, 0x2205, 0x2231, 0x224f, + 0x2259, 0xa275, 0xa22a, 0xa22b, 0x2227, 0x223c, 0xa2ab, 0x2226, + 0x223c, 0xa2ab, 0x624b, 0x6464, 0xe4c7, 0xa220, 0x2225, 0xaf46, + 0x2257, 0x2277, 0x63df, 0xe4f2, 0xa244, 0xe8b3, 0x221b, 0x224f, + 0x2259, 0xa275, 0xa241, 0xd8fd, 0xa24e, 0xa23e, 0x2226, 0x2227, + 0xa2ab, 0xa28a, 0xa23a, 0xa28c, 0xa274, 0xa234, 0x2264, 0xa291, + 0xeb00, 0xa22d, 0xa219, 0x214b, 0x22ca, 0xac05, 0xbe82, 0xbb6c, + 0xa239, 0x221b, 0x2231, 0x2259, 0xa275, 0x226e, 0xa3e7, 0x2263, + 0x2271, 0x228d, 0x228e, 0x2292, 0x2294, 0x61f0, 0xe1fc, 0x222c, + 0x2277, 0x63df, 0xe4f2, 0x221b, 0x2231, 0x224f, 0xa275, 0xa033, + 0xa21a, 0xa265, 0x2251, 0x2271, 0x228d, 0x228e, 0x2292, 0x2294, + 0x61f0, 0xe1fc, 0x2242, 0xa291, 0xa25d, 0x65b9, 0xe609, 0xa287, + 0xa270, 0x218e, 0x2250, 0xa3e7, 0xa269, 0x2251, 0x2263, 0x228d, + 0x228e, 0x2292, 0x2294, 0x61f0, 0xe1fc, 0xb72d, 0xa240, 0x2205, + 0x221b, 0x2231, 0x224f, 0xa259, 0x222c, 0x2257, 0x63df, 0xe4f2, + 0xb22e, 0xa2e6, 0x2212, 0x2290, 0xc53b, 0xcb9a, 0xa267, 0xa218, + 0xa23d, 0xa23f, 0x2251, 0x2263, 0x2271, 0x228e, 0x2292, 0x2294, + 0x61f0, 0xe1fc, 0x2251, 0x2263, 0x2271, 0x228d, 0x2292, 0x2294, + 0x61f0, 0xe1fc, 0x2212, 0x2283, 0xc53b, 0x2242, 0xa264, 0x2251, + 0x2263, 0x2271, 0x228d, 0x228e, 0x2294, 0x61f0, 0xe1fc, 0x2251, + 0x2263, 0x2271, 0x228d, 0x228e, 0x2292, 0x61f0, 0xe1fc, 0x5cad, + 0xdcea, 0x22e7, 0xa2f8, 0xdfa6, 0x4cfc, 0xccff, 0xa2d9, 0xa2f1, + 0x1ec2, 0x20cd, 0xa2d5, 0x9f2e, 0x2226, 0x2227, 0xa23c, 0xa2f5, + 0xa2c1, 0x22b4, 0x22de, 0xb1a5, 0x22b3, 0x22de, 0xb1a5, 0x2026, + 0xa2cc, 0xb548, 0xa2e2, 0xa2b2, 0xb54f, 0x22d1, 0xb555, 0xa2c8, + 0xa2c7, 0x214b, 0x224b, 0xac05, 0x22db, 0x22f2, 0xa2f3, 0x2026, + 0xa2b5, 0x22c5, 0x2f95, 0x2fa0, 0xb555, 0x1ec2, 0x20cd, 0xa2a8, + 0x22d7, 0xb702, 0x22d6, 0xb702, 0xa2a1, 0xa2e9, 0x22cb, 0x22f2, + 0xa2f3, 0xd0dc, 0x22b3, 0x22b4, 0xb1a5, 0xb22e, 0xa2bf, 0xb1c3, + 0xa27f, 0x229d, 0xa2f8, 0xa2da, 0xa2a2, 0x22cb, 0x22db, 0xa2f3, + 0x22cb, 0x22db, 0xa2f2, 0xa2b1, 0x229d, 0xa2e7, 0xa300, 0xa2fb, + 0x1e10, 0xa304, 0x1e10, 0xa303, 0xeead, 0x2fe9, 0x3031, 0xb0a4, + 0xb3ac, 0x5133, 0xd166, 0xa338, 0x37e9, 0xb7fe, 0x2e00, 0xdfca, + 0xa320, 0xa31e, 0xa329, 0xa32d, 0xcbcb, 0x5535, 0xd5cf, 0xa321, + 0xa326, 0xa331, 0x3c47, 0xbed9, 0xa32e, 0x2333, 0x2941, 0xa969, + 0x2332, 0x2941, 0xa969, 0xa31a, 0xa340, 0x3bc9, 0xe1ab, 0xa33a, + 0xe7c6, 0xa352, 0x3607, 0x36fb, 0x6629, 0xe65e, 0xd294, 0x1e16, + 0x9e17, 0xa350, 0x2d0b, 0x53ef, 0xd550, 0x2354, 0x23f6, 0xb5ea, + 0xa34d, 0xa346, 0x384c, 0xb9d5, 0x234f, 0x23f6, 0xb5ea, 0x2358, + 0xa5ae, 0x28f2, 0xdce3, 0x2355, 0xa5ae, 0xb13d, 0xc387, 0x53d4, + 0xd514, 0x9f54, 0xc6e7, 0x2365, 0x2877, 0x3ef7, 0x3f9b, 0x4002, + 0x597f, 0xee75, 0x2364, 0xd97f, 0xd1e5, 0x585b, 0xd85e, 0xadf5, + 0x2918, 0xb23c, 0xae01, 0x237d, 0xc68d, 0xa37b, 0x2dfb, 0xb372, + 0xcf37, 0x3064, 0xdcc9, 0xa374, 0x2373, 0xc68d, 0x2388, 0x23b0, + 0xaee0, 0xb239, 0x2ef0, 0xaef3, 0x23a4, 0x23af, 0x36a6, 0x36c6, + 0x3b74, 0xbb77, 0xc8d4, 0xa382, 0xa3b2, 0x2727, 0xa8d3, 0xa3ad, + 0xa399, 0xc825, 0xef8e, 0xad16, 0x23a0, 0xaec1, 0x28e5, 0x2edb, + 0x613d, 0xe1d0, 0xa38d, 0xa795, 0xaef3, 0xa3a1, 0x2395, 0xaec1, + 0xa39f, 0xaec2, 0xa3b4, 0x2386, 0xb6c6, 0xaec8, 0xaeda, 0x2ecf, + 0xaed0, 0xa38c, 0xaedd, 0x2386, 0x36a6, 0x36c6, 0x3b74, 0xbb77, + 0x2382, 0xaee0, 0xa389, 0x1e25, 0xa6b4, 0xa3a3, 0xbe90, 0xc9c1, + 0xd0b1, 0x60bb, 0x6130, 0xe6a3, 0xa3bb, 0xa3ba, 0x1e1f, 0x9e22, + 0x470c, 0xce23, 0x1e09, 0xaf0e, 0x23c3, 0x23c4, 0xa3c5, 0x23c2, + 0x23c4, 0xa3c5, 0x23c2, 0x23c3, 0xa3c5, 0x23c2, 0x23c3, 0xa3c4, + 0xe749, 0xe746, 0xa3f9, 0xb268, 0x9e41, 0xe6d9, 0x1eee, 0x23db, + 0xc08d, 0xb536, 0xa92c, 0xc2ae, 0x467a, 0x467c, 0x6aea, 0xeaee, + 0x1e8a, 0x9e8b, 0xcdb4, 0x2909, 0xdb8a, 0x354d, 0xb558, 0x23cd, + 0xc08d, 0xac09, 0x4573, 0x4582, 0x4589, 0xc58a, 0x28e1, 0xc77f, + 0x1e1b, 0x3a37, 0x3b09, 0xd5c2, 0x218e, 0x2250, 0xa26e, 0x49d6, + 0x5879, 0xe6bb, 0xa44c, 0x276e, 0x37b1, 0x3aaf, 0x51fa, 0xe8b1, + 0x234f, 0x2354, 0x35ea, 0xd449, 0xd65f, 0x23c8, 0x2606, 0xbb4e, + 0xa630, 0x24a9, 0xa4f6, 0x4c72, 0xefa5, 0x25ab, 0xa644, 0xe5a4, + 0xaf14, 0x1edd, 0xd855, 0xaf8c, 0x26ae, 0xb6cf, 0xa687, 0xa442, + 0xa5ce, 0xb061, 0xa451, 0x252b, 0x2656, 0xda21, 0xa678, 0x5074, + 0xd07d, 0x2518, 0x2553, 0x2554, 0x255f, 0x5aec, 0xe5d9, 0x2434, + 0xa449, 0x2433, 0xa449, 0xa450, 0xd117, 0xa44d, 0xa44a, 0xa415, + 0x3282, 0xc2c2, 0x2433, 0xa434, 0xa43f, 0xa3eb, 0xa43d, 0xa436, + 0xa41e, 0xa638, 0xa6c8, 0xa614, 0xa6a6, 0xa504, 0x24e1, 0x5c9f, + 0xdd20, 0x24bc, 0xa58e, 0xa4fa, 0xa5c6, 0xa5da, 0xda46, 0xe031, + 0xa5dc, 0x2492, 0xda4b, 0xda4d, 0x2611, 0x5656, 0xdb3c, 0xa4e3, + 0x248c, 0x30d2, 0xefa2, 0x248a, 0x30d2, 0xefa2, 0xda60, 0x246a, + 0xda4b, 0xa6a8, 0xa680, 0xa4a4, 0xa65d, 0xa49c, 0x2400, 0xa4f6, + 0xef69, 0x2580, 0xd849, 0x2003, 0x207a, 0xa592, 0x2173, 0xcb11, + 0x618e, 0xee79, 0x2459, 0xa58e, 0xa6a5, 0x65a7, 0xeb28, 0xe7ff, + 0x2516, 0x255e, 0x45d6, 0xc602, 0xa660, 0xa635, 0xa5f6, 0xa666, + 0x2629, 0xdb41, 0xa672, 0xa68c, 0xa665, 0xa5b2, 0x2458, 0x5c9f, + 0xdd20, 0xa485, 0xda36, 0x2560, 0x2586, 0x269e, 0x27d1, 0xb08a, + 0x2400, 0xa4a9, 0xa45a, 0x5a98, 0xdbf1, 0xa457, 0xd123, 0xd39e, + 0xa57a, 0xa523, 0x24d1, 0x255e, 0x45d6, 0xc602, 0x242f, 0x2553, + 0x2554, 0x255f, 0x5aec, 0xe5d9, 0xa61c, 0xa5ca, 0xa62e, 0xa5e9, + 0xa515, 0xa59a, 0xa59e, 0xa41f, 0xdaaf, 0xaff5, 0xa60a, 0xdb2a, + 0xe5ee, 0x242f, 0x2518, 0x2554, 0x255f, 0x5aec, 0xe5d9, 0x242f, + 0x2518, 0x2553, 0x255f, 0x5aec, 0xe5d9, 0xa649, 0xa649, 0x24d1, + 0x2516, 0x45d6, 0xc602, 0x242f, 0x2518, 0x2553, 0x2554, 0x5aec, + 0xe5d9, 0x24f2, 0x2586, 0x269e, 0x27d1, 0xb08a, 0x5854, 0x5858, + 0xe29c, 0xa616, 0xa5c7, 0xa6c0, 0x265b, 0x2699, 0x26d3, 0xef67, + 0xa613, 0x26c9, 0xcf57, 0xa63d, 0xa62f, 0xa510, 0x24af, 0xd849, + 0x6927, 0xe935, 0xdb71, 0x24f2, 0x2560, 0x269e, 0x27d1, 0xb08a, + 0x2459, 0xa4bc, 0x267e, 0xc616, 0x2003, 0x207a, 0xa4b1, 0xa524, + 0x3198, 0x3199, 0xbb56, 0xa527, 0xa5bb, 0x9e27, 0x2403, 0xa644, + 0x9e54, 0x2355, 0xa358, 0x25b7, 0xa674, 0x68df, 0x68e0, 0xe963, + 0xa4df, 0x41df, 0xd425, 0x25af, 0xa674, 0xa5a9, 0xa60d, 0xa6b3, + 0xef45, 0xa45b, 0xa56c, 0xa51d, 0xa417, 0xa45c, 0xa469, 0xe16a, + 0xab60, 0xa637, 0xa522, 0xa6c1, 0xa66f, 0xa4d4, 0xdb30, 0x23f9, + 0xbb4e, 0xa540, 0xa5bd, 0x247c, 0xdb3c, 0xa56f, 0xa455, 0xa567, + 0x2690, 0x2c1d, 0xc51e, 0xa653, 0xa51b, 0xa6b6, 0xa62f, 0x24d7, + 0xdb41, 0xa520, 0x2578, 0xa628, 0xa3fd, 0xa6d1, 0xa4d3, 0xa5e5, + 0xa452, 0xa574, 0xb076, 0xdb50, 0x2403, 0xa5ab, 0xa655, 0x2556, + 0xa557, 0xa668, 0xa618, 0xa645, 0x241f, 0xda21, 0x256e, 0xa699, + 0xa695, 0xa49d, 0xa4d2, 0xdb6b, 0xa4dd, 0xa4d5, 0xa650, 0xdb5f, + 0xa5f3, 0xa4d9, 0x25af, 0xa5b7, 0x585c, 0x585f, 0xe053, 0xa428, + 0xaf53, 0xa591, 0xa49b, 0xa413, 0xa4dc, 0xa694, 0x2617, 0x2c1d, + 0xc51e, 0xa68f, 0xa65c, 0x256e, 0x265b, 0x26d3, 0xef67, 0x24f2, + 0x2560, 0x2586, 0x27d1, 0xb08a, 0xbd4f, 0xa6ca, 0xa6c2, 0xa4bd, + 0xa456, 0xa499, 0xa411, 0x9eb8, 0xa5be, 0x1e25, 0xa3b3, 0xa624, + 0xa6c2, 0xa56d, 0xa5eb, 0x26a3, 0xa6bb, 0xa181, 0xa453, 0x2570, + 0xcf57, 0xa6a2, 0xd2cf, 0xd271, 0xa631, 0x256e, 0x2699, 0xef67, + 0x26f2, 0x26f4, 0xa70d, 0x26de, 0x26ec, 0x2efb, 0x2efd, 0x5ff4, + 0xe025, 0xa6e0, 0x9e96, 0x26d8, 0x26ec, 0x2efb, 0x2efd, 0x5ff4, + 0xe025, 0xe856, 0xa6d9, 0x26e3, 0x2718, 0xccf0, 0x26e2, 0x2718, + 0xccf0, 0x3df5, 0x3e0a, 0xbe15, 0xa18f, 0xa6f1, 0x26d8, 0x26de, + 0x2efb, 0x2efd, 0x5ff4, 0xe025, 0x2213, 0x2712, 0xd597, 0x26f6, + 0x26fb, 0x26fd, 0x2700, 0xa70b, 0xc74f, 0xa6ea, 0x26d7, 0x26f4, + 0xa70d, 0x26fe, 0x2716, 0xa717, 0x26d7, 0x26f2, 0xa70d, 0xa707, + 0x26ef, 0x26fb, 0x26fd, 0x2700, 0xa70b, 0xb5e5, 0x26ef, 0x26f6, + 0x26fd, 0x2700, 0xa70b, 0x26ef, 0x26f6, 0x26fb, 0x2700, 0xa70b, + 0x26f3, 0x2716, 0xa717, 0x26ef, 0x26f6, 0x26fb, 0x26fd, 0xa70b, + 0xa711, 0x2186, 0x270e, 0xa713, 0xa6f5, 0xa70f, 0x26ef, 0x26f6, + 0x26fb, 0x26fd, 0xa700, 0x26d7, 0x26f2, 0xa6f4, 0x2186, 0x2706, + 0xa713, 0xa708, 0xa703, 0x26ed, 0xd597, 0x2186, 0x2706, 0xa70e, + 0x26f3, 0x26fe, 0xa717, 0x26f3, 0x26fe, 0xa716, 0x26e2, 0xa6e3, + 0x383e, 0xbb12, 0xa721, 0xa71f, 0x453a, 0xc53c, 0xd056, 0x238b, + 0xa8d3, 0xb257, 0xb747, 0xc3ea, 0x2754, 0x27ca, 0xadb3, 0xa8d9, + 0x2834, 0xa872, 0x3b7e, 0x3b7f, 0x3b81, 0xbca1, 0xe62f, 0x2c85, + 0xe62a, 0x276f, 0x28ca, 0x28de, 0xe62b, 0xaea7, 0xe62c, 0xa78b, + 0x2730, 0x27ca, 0xadb3, 0x21f7, 0x284a, 0xa8a4, 0xade0, 0xa805, + 0x28b0, 0x28b5, 0x28c7, 0x28dc, 0x4f48, 0xcf4e, 0xa8e2, 0x27bb, + 0xa8e9, 0x2862, 0xe696, 0x28b3, 0xe6ab, 0x289c, 0xc908, 0xa802, + 0xa803, 0xb1bb, 0xa88c, 0x6640, 0xe641, 0xbce5, 0x23f0, 0xd1fa, + 0x274f, 0xe62b, 0xa7a7, 0xa787, 0x1e18, 0x9e20, 0xa7a2, 0xa8a2, + 0xa7c0, 0xa8df, 0xa8e0, 0xa8da, 0xa773, 0xa753, 0x2841, 0xa8d8, + 0xc561, 0xe67b, 0xa39a, 0xa806, 0x282f, 0x2c27, 0xac2d, 0xa79c, + 0xa79b, 0xa8a2, 0xa778, 0xa8be, 0xa770, 0xab88, 0x280a, 0xd056, + 0xa88a, 0xa7e1, 0xa8b6, 0xa8cb, 0xa84f, 0xa816, 0x275d, 0xa8e9, + 0xa782, 0xc86e, 0xe656, 0x2730, 0x2754, 0xadb3, 0x24f2, 0x2560, + 0x2586, 0x269e, 0xb08a, 0xa7d3, 0xa7d2, 0xa852, 0x2864, 0xa8ce, + 0xa81d, 0x28c4, 0xe1ce, 0x2824, 0xe684, 0xa7ad, 0xc897, 0xb267, + 0x2d0e, 0x2d5c, 0xc895, 0xb383, 0xa763, 0xa764, 0xa75a, 0xa796, + 0xd3eb, 0xa7a9, 0xa879, 0x28ae, 0xa8af, 0xa7b4, 0xe67b, 0xa7da, + 0x27de, 0xe684, 0x6636, 0xe68e, 0x279a, 0x2c27, 0xac2d, 0x2895, + 0xe681, 0xb2a5, 0x273a, 0xa872, 0x454c, 0xc54d, 0x2792, 0xa8d8, + 0xa8ea, 0x21f7, 0x2757, 0xa8a4, 0xd314, 0xc57b, 0xa7b2, 0xa851, + 0xa850, 0xa7d8, 0xa896, 0xbd82, 0xa8a7, 0xa1a2, 0xd46c, 0xa86b, + 0xa75e, 0x27d9, 0xa8ce, 0xe663, 0x46d0, 0xee7d, 0xa861, 0x273a, + 0xa834, 0xac18, 0x2364, 0xee75, 0x2811, 0xa8cd, 0x450e, 0x4816, + 0xc8da, 0xc245, 0xa7ab, 0xa767, 0x2830, 0xe681, 0xa854, 0xa89e, + 0x28bb, 0xc246, 0x2760, 0xc908, 0xa897, 0x277a, 0xa7a1, 0x21f7, + 0x2757, 0xa84a, 0xa859, 0x2815, 0xa8af, 0x2815, 0xa8ae, 0x275b, + 0x28b5, 0x28dc, 0x4f48, 0xcf4e, 0x275f, 0xe6ab, 0x275b, 0x28b0, + 0x28dc, 0x4f48, 0xcf4e, 0xa7af, 0xde87, 0xa899, 0xa7a6, 0x27dc, + 0xe1ce, 0xa75b, 0x274f, 0xa8de, 0xa7b1, 0xa8e4, 0xa879, 0x27d9, + 0xa864, 0xc4bd, 0x238b, 0xa727, 0x2792, 0xa841, 0xa739, 0xa786, + 0x275b, 0x28b0, 0x28b5, 0x4f48, 0xcf4e, 0x274f, 0xa8ca, 0xa784, + 0xa785, 0x23e1, 0xc77f, 0xa75c, 0xa8cc, 0x2398, 0x2edb, 0xe13d, + 0x275d, 0xa7bb, 0xa846, 0x28ef, 0xa8f5, 0x28ee, 0xa8f5, 0xd072, + 0xa8f9, 0x2356, 0xdce3, 0x3bbb, 0xbbbc, 0x28ee, 0xa8ef, 0x28f7, + 0xa8fa, 0x28f6, 0xa8fa, 0xa8fc, 0xa8f1, 0x28f6, 0xa8f7, 0x2a7f, + 0xd05f, 0xa8f8, 0x2900, 0xabff, 0x28fd, 0xabff, 0xa90a, 0x21e6, + 0xd655, 0xe64d, 0x1ffb, 0x2079, 0x2099, 0xa0c3, 0x23d8, 0xdb8a, + 0xa902, 0x2fa9, 0x5907, 0xd986, 0xa913, 0xa90f, 0xd641, 0x236f, + 0xb23c, 0xa91b, 0xa91a, 0x9eb1, 0xa920, 0xa91f, 0x2923, 0xb8a6, + 0x2922, 0xb8a6, 0x9f19, 0x2172, 0x6754, 0xe75d, 0xa3cf, 0xbb80, + 0x372c, 0xb94d, 0xbcf0, 0xe82d, 0xbbd4, 0xda87, 0xa93e, 0xa96a, + 0xa939, 0x2332, 0x2333, 0xa969, 0xa950, 0xcad2, 0xb7f0, 0xa96e, + 0xeede, 0xa942, 0x4287, 0xe029, 0x2968, 0x296c, 0xc34e, 0xaf09, + 0xc55a, 0x2967, 0xadb4, 0x2965, 0xadb4, 0x2956, 0x296c, 0xc34e, + 0x2332, 0x2333, 0xa941, 0xa93a, 0x2956, 0x2968, 0xc34e, 0xa94b, + 0x29b3, 0xab2d, 0x29e6, 0xa9e7, 0x299d, 0x2a24, 0x4ca7, 0xccda, + 0x2a66, 0xaa8d, 0xaabd, 0xa9d9, 0x29f8, 0xd505, 0xa9ac, 0xc945, + 0xc385, 0xaab8, 0x2986, 0x2a24, 0x4ca7, 0xccda, 0xaaf5, 0xaad7, + 0x2aaf, 0xab00, 0xa992, 0x1f60, 0x2976, 0xab2d, 0x1f84, 0xa9ea, + 0x2a3f, 0xaa40, 0xaa12, 0xa9ca, 0xa9c9, 0x1e68, 0xa158, 0xa9d7, + 0xaa8e, 0xaa30, 0xa9cd, 0xa98a, 0xd591, 0xaa1f, 0x2978, 0xa9e7, + 0x2978, 0xa9e6, 0x1f84, 0xa9b7, 0xa9ec, 0xa9eb, 0xaae6, 0x298d, + 0xd505, 0xaa63, 0xaa41, 0xaa6d, 0xab08, 0xab0c, 0xab4c, 0xa9c6, + 0x2b22, 0xab43, 0x2a2f, 0xaa31, 0xa9e2, 0x2986, 0x299d, 0x4ca7, + 0xccda, 0xab2a, 0xab09, 0x2a1b, 0xaa31, 0xa9d2, 0x2a1b, 0xaa2f, + 0xaaa7, 0x2afa, 0xaafb, 0x29b8, 0xaa40, 0x29b8, 0x2a3f, 0xaa50, + 0xaa04, 0xaa40, 0xa9fb, 0x2987, 0xaa8d, 0xbdeb, 0xaa05, 0x1e3d, + 0xee97, 0xaaff, 0x2b30, 0x2b46, 0xab7e, 0xab0b, 0xab38, 0x28fb, + 0xd05f, 0x2987, 0xaa66, 0xa9d0, 0xaa32, 0xaabc, 0xab03, 0x29ab, + 0xab00, 0xa99b, 0xaaaa, 0xa988, 0x3127, 0xd06d, 0x2b1d, 0xd885, + 0xab32, 0xab21, 0xab2a, 0xa9aa, 0xa9ee, 0xab19, 0xa9a9, 0x3194, + 0xc644, 0x2a34, 0xaafb, 0x2a34, 0xaafa, 0xaa73, 0x29ab, 0xaaaf, + 0xaaad, 0xaa06, 0xaa2d, 0xaa75, 0xaa07, 0xaaf1, 0x2acb, 0xd885, + 0xaad2, 0x2a18, 0xab43, 0xab37, 0x2a26, 0xaad4, 0x2976, 0xa9b3, + 0x2a74, 0x2b46, 0xab7e, 0xaad0, 0xab24, 0xaa76, 0xb1d2, 0x2a18, + 0xab22, 0x2a74, 0x2b30, 0xab7e, 0xaa08, 0xab53, 0xab52, 0xab6b, + 0xa5e3, 0x2b78, 0x3569, 0x3585, 0x3586, 0xb588, 0xab7f, 0xab59, + 0x2b66, 0x3569, 0x3585, 0x3586, 0xb588, 0xab7d, 0xab7c, 0x2a74, + 0x2b30, 0xab46, 0xab6a, 0x2bcd, 0x2bd5, 0x2bd7, 0x2bdc, 0x2be7, + 0xc52f, 0xa197, 0x4260, 0x5675, 0xd6c7, 0xca79, 0xa7a8, 0xca81, + 0xd089, 0x219d, 0xab9c, 0x219d, 0xab90, 0x2bda, 0x2bf3, 0x2bf6, + 0xc3e4, 0x2b9f, 0xabe6, 0x2b9e, 0xabe6, 0xabf5, 0x2bb7, 0xabe9, + 0xac4e, 0xb1b2, 0xabae, 0xabab, 0x5b8c, 0xe1bc, 0xa0a2, 0x2ba1, + 0xabe9, 0xabc6, 0x21a6, 0xabc7, 0x2bdb, 0xabec, 0x5cd3, 0xdcd4, + 0xe1c7, 0xa1a4, 0xabbb, 0x21a6, 0xabbc, 0x6751, 0xe752, 0x66ba, + 0x674d, 0x674e, 0x674f, 0x6db4, 0x6e16, 0xee64, 0xa1a8, 0x2b81, + 0x2bd5, 0x2bd7, 0x2bdc, 0x2be7, 0xc52f, 0xaebd, 0x2b81, 0x2bcd, + 0x2bd7, 0x2bdc, 0x2be7, 0xc52f, 0x2b81, 0x2bcd, 0x2bd5, 0x2bdc, + 0x2be7, 0xc52f, 0x2b9d, 0x2bf3, 0x2bf6, 0xc3e4, 0x2bbd, 0xabec, + 0x2b81, 0x2bcd, 0x2bd5, 0x2bd7, 0x2be7, 0xc52f, 0xabe2, 0xda67, + 0x4aad, 0xcab6, 0xabdd, 0x2b9e, 0xab9f, 0x2b81, 0x2bcd, 0x2bd5, + 0x2bd7, 0x2bdc, 0xc52f, 0x2ba1, 0xabb7, 0x2199, 0xa1a9, 0x2bbd, + 0xabdb, 0x2b9d, 0x2bda, 0x2bf6, 0xc3e4, 0xaba0, 0x2b9d, 0x2bda, + 0x2bf3, 0xc3e4, 0x2bfe, 0xac0d, 0xac0b, 0xac0e, 0x2bf9, 0xac0d, + 0x28fd, 0xa900, 0x1e13, 0xac08, 0x214b, 0x224b, 0xa2ca, 0xac07, + 0xac06, 0x1e13, 0xac02, 0xa3de, 0xabfb, 0x2bf9, 0xabfe, 0xabfc, + 0x2c13, 0x2c14, 0xc23e, 0x2c12, 0x2c14, 0xc23e, 0x2c12, 0x2c13, + 0xc23e, 0xa875, 0xac1a, 0xac19, 0x1e48, 0x2e85, 0x6ebc, 0xeebd, + 0x2617, 0x2690, 0xc51e, 0xc1ce, 0x2c20, 0x5d7b, 0x6bae, 0x6c7b, + 0xec9c, 0x2c1f, 0x5d7b, 0x6bae, 0x6c7b, 0xec9c, 0x2c23, 0x2c24, + 0xb023, 0xac22, 0x2c22, 0xb023, 0xac26, 0xac25, 0x279a, 0x282f, + 0xac2d, 0xac2b, 0xac29, 0xeb40, 0x279a, 0x282f, 0xac27, 0x21f2, + 0x2c34, 0x2c36, 0x2c37, 0xeb50, 0x21f2, 0x2c32, 0x2c36, 0x2c37, + 0xeb50, 0x21f2, 0x2c32, 0x2c34, 0x2c37, 0xeb50, 0x21f2, 0x2c32, + 0x2c34, 0x2c36, 0xeb50, 0xac4d, 0x1fad, 0x2118, 0xc6e1, 0x1fb7, + 0xddfc, 0xac64, 0xac53, 0xa1e5, 0xac4a, 0xac46, 0x6ce5, 0xee1f, + 0xac38, 0xaba9, 0x2c5b, 0xae48, 0xac43, 0x2c4f, 0xae48, 0xac6c, + 0xac62, 0xac61, 0xac42, 0xac68, 0xac66, 0xac5e, 0xadbc, 0xa1fa, + 0x1e97, 0x2d57, 0x3b72, 0xbb73, 0xdc48, 0x2742, 0xe62a, 0xdc3a, + 0xad87, 0xad17, 0xacf4, 0xad50, 0x2cf6, 0x2d8b, 0x2d8c, 0x2db9, + 0x6666, 0x669d, 0xe6af, 0xa188, 0x2d52, 0x2d53, 0x2dcc, 0x2dd6, + 0x2dd7, 0xc89e, 0xadba, 0xadbd, 0xad87, 0xad2c, 0xadcb, 0xada8, + 0xada7, 0xacdd, 0xacd2, 0xacfd, 0xada2, 0xada0, 0xad22, 0xadd2, + 0xace9, 0xace8, 0xacf0, 0xacef, 0xac98, 0x2d58, 0x2db8, 0xadc6, + 0x2c9b, 0x2d8b, 0x2d8c, 0x2db9, 0x6666, 0x669d, 0xe6af, 0xace1, + 0xad97, 0xad0d, 0xadae, 0xad08, 0xad07, 0x234e, 0xd3ef, 0xad03, + 0x27fc, 0x2d5c, 0xc895, 0xa393, 0xac97, 0x1ed1, 0xad19, 0x1ed1, + 0xad18, 0xace5, 0xacbd, 0x2d83, 0xad84, 0xcbcf, 0xac9a, 0x2ca9, + 0x2d53, 0xc89e, 0x2ca9, 0x2d52, 0xc89e, 0x1e97, 0x2c81, 0x3b72, + 0xbb73, 0x2cf5, 0x2db8, 0xadc6, 0xad94, 0x27fc, 0x2d0e, 0xc895, + 0xad81, 0x3e13, 0xbeaa, 0xad73, 0xad6f, 0xad5d, 0xad2d, 0xad2d, + 0x2c96, 0xacb4, 0x2c9b, 0x2cf6, 0x2d8c, 0x2db9, 0x6666, 0x669d, + 0xe6af, 0x2c9b, 0x2cf6, 0x2d8b, 0x2db9, 0x6666, 0x669d, 0xe6af, + 0xad5a, 0xad02, 0xace4, 0xace3, 0xacc4, 0xacc3, 0xad04, 0xe6df, + 0x2730, 0x2754, 0xa7ca, 0x2965, 0xa967, 0x2cf5, 0x2d58, 0xadc6, + 0x2c9b, 0x2cf6, 0x2d8b, 0x2d8c, 0x6666, 0x669d, 0xe6af, 0xacad, + 0xac7f, 0xacb3, 0x2dd3, 0xadd4, 0x2cf5, 0x2d58, 0xadb8, 0xacbf, + 0x2ca9, 0x2dd6, 0xadd7, 0xace6, 0xadc5, 0xadc5, 0x2ca9, 0x2dcc, + 0xadd7, 0x2ca9, 0x2dcc, 0xadd6, 0xaddd, 0xaddb, 0xa759, 0xade3, + 0xade2, 0xe78f, 0xadf0, 0xadef, 0xa36e, 0xd856, 0xadfd, 0x2377, + 0xb372, 0xadfa, 0x67cd, 0xe7e8, 0x231d, 0xdfca, 0x2370, 0x2e63, + 0xae64, 0x9f48, 0xae25, 0xae2b, 0xcd19, 0xae43, 0xae33, 0x9f16, + 0xd88b, 0xcd48, 0xcc3e, 0xcb92, 0x2e5f, 0xb5d8, 0xae05, 0x2e2f, + 0xae36, 0xae40, 0xae08, 0xd4c6, 0x2e47, 0x2e5a, 0xae6b, 0x2e26, + 0xae36, 0x2f52, 0x3b78, 0xc688, 0xae6c, 0xae10, 0x2e26, 0xae2f, + 0xae58, 0xae57, 0xa183, 0xae27, 0x21aa, 0xcf83, 0xae0f, 0x2e2e, + 0x2e5a, 0xae6b, 0x2c4f, 0xac5b, 0xce28, 0xae3c, 0xae3b, 0x2e2e, + 0x2e47, 0xae6b, 0x2e1c, 0xb5d8, 0xb5d9, 0x2e01, 0xae64, 0x2e01, + 0xae63, 0x2e2e, 0x2e47, 0xae5a, 0xae31, 0x1e7e, 0x2e79, 0xb9a6, + 0xc9ca, 0x1e26, 0x1f75, 0x2002, 0x20a1, 0x2e77, 0xcadd, 0xae76, + 0xa016, 0x2e72, 0xb9a6, 0x9e48, 0xa1e0, 0x2e83, 0x2eb5, 0xaee3, + 0x2ef0, 0xaef3, 0x2e7f, 0xaee3, 0x5358, 0xd38a, 0x1e48, 0x2c1b, + 0x6ebc, 0xeebd, 0xb176, 0xc240, 0xaeec, 0xaee1, 0xaeab, 0x2fdc, + 0xb1c9, 0xaedf, 0xef90, 0x2ec3, 0xaee2, 0xa750, 0xae93, 0x2e7f, + 0x53f4, 0x544a, 0xd4ed, 0xaebb, 0x377e, 0x3780, 0x37a9, 0x37d7, + 0xb8a5, 0xaeb6, 0xaece, 0xabd3, 0xaedf, 0x2395, 0xa3a0, 0xa3a2, + 0x2e9f, 0xaee2, 0xa3a6, 0xaebc, 0x23a9, 0xaed0, 0x23a9, 0xaecf, + 0xa3a8, 0x2398, 0x28e5, 0xe13d, 0xa3ae, 0x2e99, 0xaebf, 0x2382, + 0xa3b0, 0xae91, 0x2e9f, 0xaec3, 0x2e7f, 0xae83, 0xaeea, 0xaee9, + 0xae90, 0x2385, 0x2e81, 0xaef3, 0x2385, 0x239b, 0x2e81, 0xaef0, + 0xdfea, 0x26d8, 0x26de, 0x26ec, 0x2efd, 0x5ff4, 0xe025, 0x1e43, + 0xdffa, 0x26d8, 0x26de, 0x26ec, 0x2efb, 0x5ff4, 0xe025, 0xe58b, + 0x44e3, 0x598d, 0x5fa1, 0x5fa7, 0x5fa8, 0x5fa9, 0xdfaf, 0xc570, + 0xb8c4, 0x330a, 0xb335, 0xa958, 0x9e00, 0x9e8c, 0x1e09, 0xa3c1, + 0x5cae, 0x5cb3, 0xdd30, 0xaf12, 0xaf11, 0xa40a, 0xaf35, 0x2f4c, + 0xc030, 0xcd43, 0xaf33, 0xaf4e, 0xaf2a, 0xaf20, 0xaf3a, 0x2f3e, + 0xaf48, 0xaf37, 0xaf3c, 0xaf3b, 0x2f39, 0xaf48, 0xa22b, 0x2f39, + 0xaf3e, 0xaf25, 0xaf2f, 0xaf51, 0xaf50, 0x2e30, 0x3b78, 0xc688, + 0x2679, 0xc576, 0xaf55, 0x2f54, 0x6304, 0xe332, 0xcbf2, 0x2f5a, + 0xbc47, 0x2f59, 0xbc47, 0x2f5c, 0x2f5d, 0xaf5e, 0x2f5b, 0x2f5d, + 0xaf5e, 0x2f5b, 0x2f5c, 0xaf5e, 0x2f5b, 0x2f5c, 0xaf5d, 0xaf60, + 0x2f5f, 0xd4a6, 0xaf66, 0xaf65, 0xaf72, 0xcdb5, 0xe6d5, 0x1efd, + 0xb58c, 0xaf68, 0x9ee2, 0x1eff, 0x2fac, 0xeae3, 0xafb9, 0x1f5b, + 0xeaf4, 0x2f83, 0xdfec, 0x2fb0, 0x2fb4, 0xafb5, 0xaf80, 0x2f91, + 0x5ff3, 0xe015, 0xc2e5, 0x9f77, 0x9f6a, 0xa40e, 0xe65f, 0x2f84, + 0x5ff3, 0xe015, 0x1ece, 0xaf9e, 0x22d1, 0xafa0, 0x1ece, 0xaf93, + 0x22d1, 0xaf95, 0xc9a6, 0x201f, 0xd5c9, 0xa065, 0x290d, 0xd986, + 0x1eff, 0x208d, 0xaf77, 0xa09c, 0xaf81, 0xa0c4, 0x2fb7, 0x3074, + 0xb0b3, 0x2f81, 0xafb5, 0x2f81, 0xafb4, 0x2fb3, 0x3074, 0xb0b3, + 0xaf7b, 0xafc4, 0xafc3, 0xb1b6, 0x9ec1, 0x31f4, 0xb1fa, 0xda8c, + 0xb07e, 0x2e94, 0xb1c9, 0xb09f, 0xb025, 0xb182, 0x2306, 0x3031, + 0xb0a4, 0xb0b4, 0xa538, 0xb13e, 0x31d0, 0xb1f7, 0xb14b, 0xb16b, + 0xb1ae, 0xb16a, 0xb0b5, 0xb134, 0x9f42, 0xb091, 0xb190, 0xb056, + 0x2c22, 0xac24, 0xafe3, 0xb060, 0x2306, 0x2fe9, 0xb0a4, 0x30e3, + 0x3374, 0x4dcf, 0x4deb, 0xce3d, 0xb1df, 0xb1cc, 0xb052, 0xb200, + 0xb046, 0x21c4, 0xb0bd, 0xb01d, 0xb02a, 0x241d, 0xb08b, 0x2379, + 0xdcc9, 0xd03b, 0xb119, 0x3085, 0xb0a6, 0xb1c7, 0x2fb3, 0x2fb7, + 0xb0b3, 0xb0e0, 0x20eb, 0x2641, 0x30aa, 0xb0e1, 0xb15f, 0xb1e8, + 0xb137, 0xb0fb, 0x30a9, 0xb0f1, 0xb0f2, 0xafd9, 0x30e5, 0xb142, + 0x3111, 0xb139, 0x3071, 0xb0a6, 0x24f2, 0x2560, 0x2586, 0x269e, + 0xa7d1, 0xb061, 0xc302, 0xb016, 0x9fd4, 0x3102, 0xda96, 0xdbef, + 0xafe2, 0xb0ca, 0x2306, 0x2fe9, 0xb031, 0x3071, 0xb085, 0x307c, + 0xb0f1, 0x20eb, 0x3076, 0xb0e1, 0xb164, 0xb1f8, 0xb173, 0xb1ab, + 0x2fb3, 0x2fb7, 0xb074, 0xaff0, 0xb005, 0xe5f7, 0x21c4, 0xb053, + 0x30a2, 0xea5a, 0x248a, 0x248c, 0xefa2, 0x1ffd, 0xbb23, 0xb075, + 0x20eb, 0x3076, 0xb0aa, 0xb03b, 0x307f, 0xb142, 0xb1fc, 0xb158, + 0xb1f2, 0xb18a, 0xb11c, 0x3159, 0xb15a, 0xb19a, 0xb163, 0x307c, + 0xb0a9, 0xb07d, 0xd822, 0xb07b, 0xd90a, 0x3096, 0xda96, 0x4609, + 0xc652, 0x3080, 0xb139, 0xb06a, 0xc231, 0xb0ec, 0xb14d, 0xb181, + 0xb1a4, 0xb192, 0x2abf, 0xd06d, 0xb1fc, 0xb006, 0xb07a, 0x3080, + 0xb111, 0xb14e, 0xa35a, 0xaffe, 0xe858, 0x307f, 0xb0e5, 0xb817, + 0xbbb7, 0xb001, 0xb120, 0x313c, 0x361a, 0xc718, 0x3174, 0xb1fe, + 0xb0e8, 0x30ed, 0xb15a, 0x30ed, 0xb159, 0x3078, 0xb185, 0xb0ef, + 0xb0ab, 0xb004, 0xb002, 0xb196, 0xd651, 0xb0ad, 0xb151, 0xae86, + 0x317d, 0xb21a, 0x317c, 0xb21a, 0xbb32, 0x21ed, 0x21f4, 0xb191, + 0xb121, 0xafe7, 0xb15f, 0xb1a9, 0xb0eb, 0xb01c, 0x21ed, 0x21f4, + 0xb17f, 0xb126, 0x2af6, 0xc644, 0x316d, 0xb197, 0xb196, 0x259c, + 0x3199, 0xbb56, 0x259c, 0x3198, 0xbb56, 0xb0ee, 0xb124, 0x22b3, + 0x22b4, 0xa2de, 0xb187, 0xb0af, 0xb003, 0xabaa, 0xafc6, 0xa766, + 0xa2e4, 0xb073, 0x2e94, 0xafdc, 0xb03f, 0xb1d4, 0x3000, 0xb1f7, + 0xb1e3, 0x2b3e, 0xb1f6, 0xb1cd, 0xb1f5, 0xd499, 0xb03c, 0xb1d1, + 0xb1e7, 0xb1e6, 0xb079, 0xb0e9, 0x2fcf, 0xb1ff, 0xb1dc, 0xb1d2, + 0x3000, 0xb1d0, 0xb0ac, 0xafcf, 0x30e7, 0xb133, 0xbb22, 0xb151, + 0xb1f4, 0xb04b, 0xb207, 0xb206, 0xb214, 0x322f, 0xb232, 0xb20b, + 0xb227, 0x3226, 0xb230, 0x317c, 0xb17d, 0xb21e, 0x5ca1, 0xdd22, + 0xb21b, 0x3218, 0xb230, 0xb217, 0xb22c, 0xb229, 0x2279, 0xa2e0, + 0x320f, 0xb232, 0x3218, 0xb226, 0x320f, 0xb22f, 0x3237, 0xb238, + 0x3236, 0xb238, 0x3236, 0xb237, 0xa384, 0xb23e, 0x236f, 0xa918, + 0xb23b, 0xb24c, 0xb24b, 0xce94, 0x33e0, 0xcd2e, 0x34b2, 0xb4c8, + 0xb2c2, 0xa728, 0x5a17, 0xdbac, 0xb34d, 0xb268, 0xe1e6, 0xa7f7, + 0x23c9, 0xb260, 0x32e1, 0xb4f4, 0xb36b, 0xb383, 0xb3da, 0xb4a6, + 0xb4fe, 0xb5bc, 0x2448, 0xc2c2, 0xa214, 0xb4ab, 0xb2cb, 0xb2d4, + 0xb2d7, 0x32e9, 0xb4c7, 0xb476, 0xb473, 0xb384, 0xb436, 0xdb77, + 0xa831, 0xb4e1, 0x32de, 0x4274, 0xd9dd, 0xb255, 0xb4d4, 0xb49a, + 0xb29b, 0xb2ff, 0x37b4, 0xb7fa, 0xb428, 0xb29c, 0xb2d6, 0xb2d5, + 0xb29d, 0xb2dd, 0xb2dc, 0xb2b5, 0xb4ec, 0x336e, 0xb4da, 0x3269, + 0x3304, 0xb4f4, 0xb50f, 0xb3c0, 0xb4c1, 0xb514, 0xb4f0, 0x34a5, + 0xc67a, 0x329e, 0xb4c7, 0xb2cf, 0xb39b, 0x32e1, 0xb4f4, 0x2f04, + 0xb335, 0x1e3e, 0x34e7, 0xd209, 0xb46f, 0xb523, 0xb397, 0xb4be, + 0xb4bb, 0xb33e, 0xb493, 0xb4cb, 0xb49f, 0xb399, 0xb4e0, 0xb3ee, + 0xb48f, 0x2f04, 0xb30a, 0xb412, 0xdf13, 0xb31f, 0xb3d2, 0x3405, + 0x34b9, 0xb52a, 0x38b1, 0x4975, 0xcd91, 0xb25e, 0xb3d1, 0xd379, + 0xb41c, 0xb488, 0xb40d, 0xb4bf, 0xb3db, 0x3417, 0xb4e3, 0xd20d, + 0xb26a, 0x32e0, 0xb4da, 0x2377, 0xadfb, 0xb03b, 0x3816, 0xb8f2, + 0x27fd, 0xb26b, 0xb2a1, 0xb31c, 0xb323, 0xb302, 0xe1c7, 0xb4d1, + 0xa30a, 0xb3ed, 0xb4c4, 0xb451, 0xb4f2, 0xb4a3, 0xb47b, 0xb414, + 0xb45c, 0xc8b0, 0xb2e3, 0xb34f, 0xb33f, 0xb26c, 0xb362, 0xb24e, + 0xb3b2, 0xb325, 0xd0cc, 0x3416, 0xb447, 0xb52c, 0xb4b3, 0xb519, + 0xb4f1, 0xb45f, 0xce3d, 0x3341, 0x34b9, 0xb52a, 0xb784, 0xb35f, + 0xb337, 0xb3bb, 0x33fa, 0xb447, 0xb363, 0x335c, 0xd490, 0xb2d3, + 0xb498, 0xb528, 0xb2a2, 0x34d5, 0xb51c, 0xb9a8, 0x3444, 0xb51d, + 0x3442, 0xb51d, 0xb504, 0x34fa, 0xd96c, 0x33fa, 0xb416, 0xb4ef, + 0xb524, 0xb3b4, 0xb3bc, 0xb402, 0x4dcf, 0x4deb, 0xce3d, 0xb4f5, + 0xb31a, 0xb2a0, 0xb29f, 0xb3ba, 0x21fb, 0xb4ca, 0xb516, 0xb35e, + 0xb326, 0xb491, 0xb490, 0xb320, 0xb42d, 0xb2c8, 0xb322, 0xb4cd, + 0xb3b8, 0x32e8, 0xc67a, 0xb26f, 0x4d55, 0x4d76, 0xcedd, 0xb29a, + 0x3251, 0xb4c8, 0xb3ff, 0xb506, 0xb4f7, 0xb4fc, 0x3341, 0x3405, + 0xb52a, 0xb51b, 0xb31e, 0xb31d, 0xb361, 0xb2e5, 0xb3b3, 0x329e, + 0xb2e9, 0x3251, 0xb4b2, 0x21fb, 0xb483, 0xb321, 0xb4a1, 0xb3a5, + 0xb2c5, 0x343a, 0xb51c, 0x32e0, 0xb36e, 0xb4fb, 0xb324, 0xb2ac, + 0xb363, 0xb52c, 0x1e3e, 0x3319, 0xd209, 0xb2df, 0xb448, 0xb2e7, + 0xb401, 0xb3b7, 0x3269, 0x32e1, 0xb304, 0xb469, 0x34b7, 0xd96d, + 0xb446, 0xb4de, 0xb4b8, 0xb50a, 0xb270, 0x9e51, 0xb445, 0xb522, + 0xb4b5, 0xb51f, 0xb4fd, 0xb2e2, 0xb522, 0xb2e6, 0xb484, 0xb400, + 0xb4ba, 0x343a, 0xb4d5, 0x3442, 0xb444, 0xb508, 0x3505, 0xb512, + 0xb31b, 0xb44a, 0xb432, 0x3341, 0x3405, 0xb4b9, 0xc234, 0x33fd, + 0xb4e5, 0xb535, 0xb534, 0xa3ce, 0xd003, 0x4b27, 0x4b56, 0x4b5e, + 0xcba3, 0x1ff2, 0x209a, 0xa2b9, 0x9f8e, 0xb575, 0x23d9, 0xb558, + 0xb559, 0xa2c4, 0x22c5, 0xa2d1, 0x5d01, 0xdd25, 0x23d9, 0xb54d, + 0xb54e, 0x3582, 0xbb5b, 0xa0d8, 0x2b66, 0x2b78, 0x3585, 0x3586, + 0xb588, 0xb578, 0xb54c, 0xb5c9, 0xb570, 0x69c6, 0x69c8, 0x6a45, + 0xea71, 0xbb5d, 0x355b, 0xbb5b, 0xbbd9, 0x2b66, 0x2b78, 0x3569, + 0x3586, 0xb588, 0x2b66, 0x2b78, 0x3569, 0x3585, 0xb588, 0x2b66, + 0x2b78, 0x3569, 0x3585, 0xb586, 0x1e9d, 0x358a, 0x6f4a, 0xef50, + 0x1e9d, 0x3589, 0x6f4a, 0xef50, 0x358e, 0xef4b, 0x1efd, 0xaf6c, + 0xd9ba, 0x358b, 0xef4b, 0xb595, 0x359e, 0xd7a4, 0xb593, 0x65d8, + 0x6b25, 0x6b26, 0x6b2a, 0xeb2d, 0x3594, 0xd7a4, 0xe159, 0xb5ac, + 0xb5a9, 0xb5b7, 0xb5b5, 0xb5b2, 0xb5ad, 0x1e8e, 0x1e8f, 0xb275, + 0xb5d2, 0xb577, 0xb5c8, 0x4c31, 0xcc4f, 0x2e1c, 0xae5f, 0x2e61, + 0xb5db, 0xb5d9, 0xc121, 0xa6f8, 0xd20a, 0x234f, 0x2354, 0xa3f6, + 0x35f9, 0xb642, 0x2164, 0x363f, 0xb6e0, 0xb698, 0x35f6, 0xb642, + 0xb680, 0xb625, 0xb664, 0xb63b, 0x2347, 0xb6fb, 0xb626, 0xb719, + 0xb62c, 0xb6c7, 0xb14e, 0xc6a8, 0xb5fe, 0xb60a, 0xb60f, 0xc0a4, + 0xb630, 0xb62f, 0xa1ac, 0xb602, 0x365d, 0xb6f8, 0xb6e8, 0x6855, + 0xe86f, 0x35f7, 0xb6e0, 0x35f6, 0xb5f9, 0xb644, 0xb643, 0xb64b, + 0xb649, 0xb6ec, 0x3681, 0xb6c9, 0xb6c4, 0xb688, 0xb689, 0xb669, + 0x363c, 0xb6f8, 0xb660, 0xb65f, 0xb5ff, 0xb6df, 0xb65a, 0xb69c, + 0x3692, 0xc520, 0xb697, 0xb5fa, 0x3653, 0xb6c9, 0xb6ab, 0x4f6a, + 0xdfa0, 0xb655, 0xb656, 0xb674, 0x4156, 0xc157, 0x367b, 0x5af3, + 0x5c19, 0x65c7, 0xe68c, 0xb5f8, 0xb66e, 0xc545, 0x36ad, 0x36cd, + 0xc6a5, 0x2386, 0x23af, 0xb6c6, 0xb6d6, 0xb6c1, 0xb682, 0x36a4, + 0xc6a5, 0x1e86, 0xc7ad, 0xb6a8, 0xb654, 0x2386, 0x23a4, 0x23af, + 0xb6a6, 0xb619, 0x3653, 0xb681, 0x40a4, 0x4167, 0x41f3, 0xc7be, + 0xb6a4, 0xa411, 0xb6a7, 0xb668, 0x35f7, 0xb63f, 0xb63d, 0xb652, + 0x3d40, 0x4cac, 0x6eaf, 0x6eb4, 0xeeb9, 0xb6f5, 0xb6f3, 0x1e66, + 0x363c, 0xb65d, 0xb6fa, 0xb6f9, 0x2347, 0xb607, 0xb6fe, 0xb6fd, + 0xa1a3, 0x22d6, 0xa2d7, 0x9f1a, 0xd8e8, 0xb717, 0xb716, 0xb60e, + 0xb722, 0xb71f, 0xb71e, 0xb71b, 0xd0e7, 0x2932, 0xb94d, 0xa273, + 0xb72f, 0x372e, 0xd853, 0xc843, 0x3a38, 0xba8f, 0xb736, 0xb735, + 0x21e0, 0xba5f, 0xbbba, 0x594d, 0x66d1, 0xe6dc, 0x3a29, 0xbb0a, + 0xb87f, 0xa72c, 0x3766, 0x3919, 0xba86, 0xe0a8, 0xb9d3, 0xb89d, + 0xb803, 0x9f86, 0xb749, 0xb94a, 0xb9aa, 0x386e, 0xc6c3, 0xa091, + 0x9e1c, 0x2eba, 0x3780, 0x37a9, 0x37d7, 0x38a5, 0xeb06, 0xe5c6, + 0x2eba, 0x377e, 0x37a9, 0x37d7, 0xb8a5, 0xb975, 0x3406, 0xb9cb, + 0xb960, 0x1e2b, 0x3860, 0x390f, 0xb930, 0x5edb, 0x5ef6, 0xdf6d, + 0xd3d3, 0xba05, 0xb85d, 0xba1e, 0xb8d7, 0xbaea, 0xb80c, 0xb898, + 0xb8d6, 0x2eba, 0x377e, 0x3780, 0x37d7, 0xb8a5, 0x39cd, 0x6397, + 0xe453, 0xb953, 0xb89f, 0x23f0, 0x3aaf, 0xd01c, 0x32d0, 0xb7fa, + 0xb827, 0xd235, 0xb822, 0xb959, 0x2eba, 0x377e, 0x3780, 0x37a9, + 0xb8a5, 0xbac3, 0xbab8, 0xb7fb, 0x231b, 0xb7fe, 0xa948, 0x3801, + 0x387a, 0xba6e, 0xb805, 0xb7ff, 0x32d0, 0xb7b4, 0xb7e5, 0xba89, + 0x231b, 0xb7e9, 0xb7f9, 0xb894, 0x37f3, 0x387a, 0xba6e, 0x3764, + 0xbad4, 0x39ae, 0xd363, 0xb7f5, 0xba19, 0x385f, 0xb8e7, 0xbadb, + 0x39de, 0xbaf3, 0xb8df, 0x37a6, 0xbae8, 0x3aaa, 0xbadf, 0x3b04, + 0xbb17, 0xba39, 0x337f, 0xb8f2, 0x21d3, 0xb144, 0xa20a, 0xb7cf, + 0xb7bb, 0x3a43, 0xcb4f, 0x39d8, 0xba23, 0xd988, 0x271d, 0xbb12, + 0xb97f, 0x2353, 0xb9d5, 0xb852, 0xb851, 0xb90e, 0x3a31, 0xbafb, + 0xb7a1, 0x3808, 0xb8e7, 0x1e2b, 0x3792, 0xb90f, 0xba48, 0xb968, + 0xba94, 0xb9bf, 0x39d7, 0xba4b, 0xba3a, 0xba9c, 0xb9f3, 0xba01, + 0xba33, 0x376f, 0xc6c3, 0xba03, 0x37f3, 0x3801, 0xba6e, 0xbf06, + 0xb746, 0x3a11, 0xcc17, 0xb9f1, 0x3973, 0xb9d1, 0x4681, 0xc682, + 0xb800, 0xb7a7, 0xb761, 0xb7ad, 0x2eba, 0x377e, 0x3780, 0x37a9, + 0xb7d7, 0x2922, 0xa923, 0x3346, 0xcd91, 0xbaae, 0xb8f6, 0xb9e4, + 0x391c, 0xbaa2, 0xbb1e, 0xaf03, 0x38cb, 0x3ab1, 0x3ac0, 0xc881, + 0x38ca, 0x3ab1, 0x3ac0, 0xc881, 0xb936, 0xb7a8, 0xb7a3, 0xb80b, + 0xba0a, 0x3808, 0xb85f, 0xca1c, 0x337f, 0xb816, 0xb8be, 0xbac2, + 0xc897, 0xb9e8, 0x1e57, 0x9e58, 0xb858, 0x1e2b, 0x3792, 0xb860, + 0x47f4, 0xc887, 0xb95a, 0xb749, 0x38c0, 0xbaa2, 0xbadd, 0xb9e7, + 0xb9f6, 0xbb0f, 0xba3f, 0xba62, 0xb792, 0xd46e, 0xb8d5, 0xd45a, + 0xb768, 0x2932, 0xb72c, 0xb7ab, 0xba62, 0xb7d5, 0xb918, 0xb78f, + 0xb986, 0xb966, 0xb965, 0xb862, 0xc243, 0xba9d, 0x9e1a, 0x3885, + 0xb9d1, 0xb781, 0xba13, 0x1e50, 0xba02, 0xb842, 0xbb16, 0xb9b2, + 0xb961, 0xbaec, 0xbada, 0x3af8, 0xbb05, 0xc253, 0x2e72, 0xae79, + 0xb43e, 0xb769, 0x3804, 0xd363, 0xb985, 0xba4a, 0xe198, 0xb864, + 0xb9d9, 0x5028, 0xe392, 0xb784, 0xb7aa, 0x3885, 0xb973, 0xb760, + 0x39f9, 0xba70, 0x2353, 0xb84c, 0x3865, 0xba4b, 0x3837, 0xba23, + 0xb9c7, 0xba9f, 0x3abb, 0xce7f, 0xb80a, 0xbab3, 0xbae7, 0xb8bf, + 0xb920, 0xb901, 0xb884, 0xb868, 0xb922, 0xb9d4, 0xb869, 0x1e50, + 0xb97d, 0xb879, 0xb79e, 0xb8e5, 0xbad3, 0x3881, 0xcc17, 0xbac1, + 0xb97c, 0xb807, 0xb7a2, 0x3837, 0xb9d8, 0x3743, 0xbb0a, 0x3a6b, + 0xbace, 0x3aa3, 0xd262, 0x385c, 0xbafb, 0xb86a, 0x1e1b, 0x23e2, + 0x3b09, 0xd5c2, 0x3734, 0xba8f, 0xb811, 0xb866, 0xcf47, 0xb92b, + 0x3830, 0xcb4f, 0xb861, 0xb9b4, 0x3865, 0xb9d7, 0xb73a, 0x392d, + 0xb955, 0x3a2a, 0xbace, 0x37f3, 0x3801, 0xb87a, 0xb9d4, 0xbae5, + 0x3ad3, 0x5263, 0xd26a, 0xbade, 0xbaa9, 0xbafd, 0xb749, 0xb7fd, + 0x3734, 0xba38, 0xcc37, 0xb863, 0x3a98, 0xd617, 0xba97, 0xb867, + 0xb96b, 0xb9da, 0x38c0, 0xb91c, 0xba2f, 0xba81, 0x380e, 0xbadf, + 0xb8bc, 0x23f0, 0xb7b1, 0x38ca, 0x38cb, 0x3ac0, 0xc881, 0xb9df, + 0xb7e0, 0xb9db, 0x38ca, 0x38cb, 0x3ab1, 0xc881, 0xba12, 0xb8f9, + 0xb7dc, 0xa1f3, 0xd030, 0x3a2a, 0xba6b, 0x3a10, 0xba79, 0xb803, + 0xbb11, 0xb988, 0xb809, 0xb91f, 0xba7c, 0x380e, 0xbaaa, 0xba71, + 0xb9e0, 0xb80c, 0xb7a5, 0xb987, 0xb80a, 0xb989, 0xbb1e, 0x385c, + 0xba31, 0xba83, 0x380f, 0xbb17, 0xb989, 0x1e1b, 0x23e2, 0x3a37, + 0xd5c2, 0x3743, 0xba29, 0xb924, 0xbad5, 0x271d, 0xb83e, 0xb984, + 0x380f, 0xbb04, 0x60c1, 0x6b30, 0xeb31, 0x38c2, 0xbafa, 0x4f3a, + 0xcf3c, 0x31fd, 0x3b53, 0x3b61, 0xea69, 0x1ffd, 0x30de, 0xda22, + 0xbb5f, 0xbb50, 0xb17e, 0xbb3e, 0xbb58, 0xe4a6, 0xbb35, 0xdb0c, + 0x23f9, 0xa606, 0xbb27, 0x3b22, 0xbb61, 0x259c, 0x3198, 0xb199, + 0xbb3b, 0x355b, 0xb582, 0xb581, 0xbb24, 0x3b22, 0xbb53, 0x3b68, + 0xbb69, 0x3b65, 0xbb69, 0x3b65, 0xbb68, 0xa24d, 0x3e0b, 0x3f80, + 0xbf81, 0x6f52, 0xef7f, 0x1e97, 0x2c81, 0x2d57, 0xbb73, 0x1e97, + 0x2c81, 0x2d57, 0xbb72, 0x2386, 0x23af, 0xbb77, 0x2386, 0x23af, + 0xbb74, 0x2e30, 0x2f52, 0xc688, 0xbb7a, 0xbb79, 0x3bb1, 0xbbb2, + 0x273d, 0x3b7f, 0x3b81, 0xbca1, 0x273d, 0x3b7e, 0x3b81, 0xbca1, + 0xa92d, 0x273d, 0x3b7e, 0x3b7f, 0xbca1, 0xbba4, 0xbb98, 0xbb9e, + 0xbbae, 0xbb8b, 0xbbab, 0xbb92, 0xbbaf, 0xbb87, 0xbb9a, 0xbb93, + 0xbba1, 0x3b7c, 0xbbb2, 0x3b7c, 0xbbb1, 0xbbc6, 0xb147, 0xb740, + 0x28f3, 0xbbbc, 0x28f3, 0xbbbb, 0xbbc1, 0x3bc0, 0x41ec, 0xdb6d, + 0xdf42, 0xbbb4, 0x233b, 0xe1ab, 0xbbcf, 0xbbce, 0x50b2, 0xd8ac, + 0xa936, 0xc562, 0xbbd8, 0xbbd7, 0xb583, 0xbbee, 0xbc08, 0xc403, + 0xbbdf, 0xbbff, 0xbbf5, 0x4266, 0xc29b, 0xbc0c, 0x3be1, 0xbc0a, + 0xbc08, 0xbc07, 0x3c17, 0x3c23, 0xc081, 0x3c14, 0x3c23, 0xc081, + 0xe6f0, 0xbc2b, 0x3c14, 0x3c17, 0xc081, 0xbc2c, 0xbc22, 0xbc29, + 0xbc33, 0xbc32, 0x3c35, 0xbc3a, 0x3c34, 0xbc3a, 0x1ecc, 0x21ab, + 0xa1b0, 0x3c34, 0xbc35, 0x232f, 0x2f59, 0x2f5a, 0xbed9, 0xbf22, + 0xbcdb, 0x3c5a, 0xbc61, 0x3c59, 0xbc61, 0x3c59, 0xbc5a, 0xbe6f, + 0xbc74, 0xbc73, 0xbd36, 0xa1b3, 0xbef8, 0x3c89, 0xc00b, 0xbc88, + 0xbca1, 0xa1b2, 0xbdfb, 0xbe9d, 0x273d, 0x3b7e, 0x3b7f, 0x3b81, + 0xbc92, 0x3cfd, 0xbfa4, 0xc043, 0xbf1a, 0xc01d, 0xbdea, 0xbec4, + 0xbe22, 0xbf59, 0x3eec, 0xcc04, 0xe63b, 0xbcb2, 0xbcb1, 0xbfd4, + 0xe711, 0xa1b5, 0x1f71, 0xc04b, 0xbc4e, 0xbeaf, 0xbfd8, 0xa76d, + 0xda3b, 0x3d99, 0xbdda, 0xa1ba, 0xa933, 0xbfa9, 0x3edd, 0xc027, + 0xc018, 0xbffc, 0xc009, 0x3e8c, 0x3f51, 0xc67a, 0x3ca2, 0xbfa4, + 0xbd87, 0xbf54, 0xa1bd, 0xc051, 0xbf54, 0xbc79, 0xcaaa, 0xb6f2, + 0xbd79, 0xbde8, 0xbdfa, 0xbf3f, 0xbf86, 0xbe5e, 0xbeae, 0xbfc1, + 0xbe2c, 0xbfae, 0x3e08, 0xbfdf, 0x26a0, 0xc00f, 0xbefb, 0xbe3e, + 0xbef8, 0xbfc3, 0xbf6f, 0xbfdc, 0x3ee8, 0x3ff1, 0xbff5, 0xbfa3, + 0x3f82, 0x3f84, 0xc013, 0xbf94, 0xbd43, 0xa1c2, 0x21c3, 0xa857, + 0xbe7c, 0xbcfe, 0xbe09, 0xbe67, 0x5385, 0xd49e, 0x3cea, 0xbdda, + 0xbfe4, 0x3e0e, 0xc006, 0xbf87, 0xbdf6, 0xbf23, 0xbf7f, 0xbe26, + 0xbeb3, 0xbe19, 0xbecc, 0xbf64, 0x3f97, 0xc900, 0xbf32, 0x3e0b, + 0x3f80, 0x3f81, 0xbfc7, 0xbf04, 0xa1c5, 0xa1c9, 0xbfb1, 0xbe7d, + 0xc5f3, 0xa1c4, 0x3cea, 0xbd99, 0xbe0c, 0x21c0, 0xbd44, 0xbca6, + 0x2a6c, 0xbedb, 0xbe7b, 0x26e6, 0x3e0a, 0xbe15, 0xbd9e, 0xbe05, + 0xbd45, 0xbc97, 0xbdf8, 0xbe34, 0x3d4e, 0xbfdf, 0xbd89, 0x26e6, + 0x3df5, 0xbe15, 0x3b6e, 0x3da9, 0x3f80, 0xbf81, 0xbde5, 0xbf2c, + 0x3d9c, 0xc006, 0xbf38, 0xbfa0, 0x2d60, 0x3eaa, 0x5c3f, 0xdc40, + 0xbf01, 0x26e6, 0x3df5, 0xbe0a, 0xc00b, 0xbef2, 0xbda3, 0xa1cf, + 0xbca8, 0xbda1, 0xbeab, 0xbd4b, 0xbe07, 0x6030, 0xe04a, 0xbd51, + 0xa1d1, 0xbd48, 0xbd8c, 0xbc64, 0xbdf3, 0xbd85, 0xbdc4, 0xc063, + 0x3ebc, 0xbfd5, 0x3ee1, 0xbeff, 0xbfda, 0xa24c, 0xbf70, 0xbffa, + 0xbf0a, 0xbf11, 0x3cfc, 0x3f51, 0xc67a, 0xa3b5, 0x3fdb, 0xd499, + 0x21c6, 0xa1d6, 0xbf91, 0xbc9f, 0x2d60, 0x3e13, 0x5c3f, 0xdc40, + 0xbe29, 0xbd49, 0x3cdd, 0xe061, 0xbda2, 0x4194, 0xe394, 0x3e7f, + 0xbfd5, 0xbca7, 0xc06d, 0xbda4, 0xd365, 0xbf77, 0x232f, 0xbc47, + 0xbefe, 0xbdeb, 0x3cf7, 0xc027, 0xbeef, 0x404e, 0x4054, 0xc067, + 0xc044, 0x3e80, 0xbeff, 0xc005, 0xbffe, 0xbfeb, 0xc064, 0x3d5c, + 0x3ff1, 0xbff5, 0xc058, 0xbfa6, 0x3caa, 0xcc04, 0xbede, 0xbe17, + 0x2364, 0x3f9b, 0xc002, 0x3c7b, 0xbd52, 0xbd50, 0xbeda, 0x3e80, + 0xbee1, 0xbe14, 0xbdaf, 0xb87c, 0xbe87, 0xbe89, 0xc055, 0xbca4, + 0xbc49, 0xbd9f, 0x1e79, 0x1e7e, 0x9e81, 0xc1b3, 0xbe0d, 0xbf44, + 0xbda8, 0xbe10, 0xbd46, 0xe88d, 0xbf31, 0xc04c, 0xc020, 0xc01f, + 0xc032, 0xbff0, 0x3cfc, 0x3e8c, 0xc67a, 0x3d01, 0xbd2f, 0xbca9, + 0x3f5c, 0xbff3, 0x3f5b, 0xbff3, 0xbda6, 0xbd54, 0xbe83, 0xc026, + 0xbed7, 0xbda0, 0x3b6e, 0x3da9, 0x3e0b, 0xbf81, 0x3b6e, 0x3da9, + 0x3e0b, 0xbf80, 0x3d67, 0x3f84, 0xc013, 0x3d67, 0x3f82, 0xc013, + 0xbd47, 0xbd9d, 0xbe9c, 0xbd69, 0xbda7, 0xbfb3, 0x2364, 0x3ef7, + 0xc002, 0xc03e, 0x21db, 0xa1dc, 0xbe11, 0xbd63, 0x3ca2, 0xbcfd, + 0xbeea, 0xbcf6, 0xbd4d, 0xc032, 0xbdc0, 0xbf9a, 0xbd4a, 0xbd53, + 0xbda9, 0x4028, 0xc02c, 0xc015, 0xbcb5, 0x3e7f, 0xbebc, 0xbcde, + 0x3e81, 0xc02f, 0x3e95, 0xd499, 0xbd55, 0x3d4e, 0xbe08, 0xbd9b, + 0xbee5, 0xbf4d, 0x3d5c, 0x3ee8, 0xbff5, 0x3f5b, 0xbf5c, 0x3d5c, + 0x3ee8, 0xbff1, 0x65ca, 0xe614, 0xbe85, 0xbcfa, 0xbee4, 0x2364, + 0x3ef7, 0xbf9b, 0xbee2, 0x3d9c, 0xbe0e, 0xbcfb, 0x3c88, 0xbe16, + 0xbd4f, 0x3d67, 0x3f82, 0xbf84, 0xbfd2, 0xbcf8, 0xbca5, 0xbf47, + 0xbf46, 0xbf74, 0x3cf7, 0xbedd, 0x3fd1, 0xc02c, 0x3fd1, 0xc028, + 0xbfda, 0xaf25, 0x3f4b, 0xbfb0, 0xbf9c, 0xbca3, 0xbee0, 0x1f71, + 0xbcd5, 0xbf45, 0x3edf, 0xc054, 0xc05d, 0xbd12, 0x3edf, 0xc04e, + 0xbf13, 0xbee9, 0xc04f, 0xbe7e, 0xbee6, 0xbedf, 0xbec5, 0x2149, + 0xc097, 0xc1c8, 0x670a, 0x671b, 0xe748, 0x4ac3, 0xcac8, 0x40fe, + 0xdd64, 0x407e, 0xc0d6, 0x407d, 0xc0d6, 0xc1e6, 0xc16c, 0x3c14, + 0x3c17, 0xbc23, 0x4210, 0x6229, 0xe46a, 0x23cd, 0xa3db, 0xc08f, + 0xc08e, 0x2149, 0xc06e, 0xc152, 0xc197, 0x362d, 0x36cc, 0x4167, + 0x41f3, 0xc7be, 0x4832, 0x491f, 0xc92e, 0xc0f1, 0xcf39, 0xeede, + 0x1e3a, 0xc232, 0x4149, 0x632c, 0xe34a, 0xc1be, 0xc20d, 0x41d7, + 0x421b, 0xc224, 0xc0f4, 0xc16c, 0x9e4c, 0x407d, 0xc07e, 0xc1ed, + 0xc159, 0xc169, 0x413c, 0xc1d2, 0x41c1, 0xc217, 0xc1f4, 0xc1d9, + 0xc1fc, 0xc1b1, 0xc0af, 0xc0c3, 0xc1a2, 0x407b, 0xdd64, 0xe2b7, + 0x21de, 0x4155, 0x4188, 0xc199, 0xe2b2, 0x9e9f, 0x4130, 0xc1c4, + 0xc165, 0xc1dc, 0xc1fe, 0x41cc, 0xc1d3, 0xb5e0, 0xc133, 0xc162, + 0x4114, 0xc1c4, 0xc126, 0x40e7, 0xc1d2, 0xe35b, 0x40bc, 0x632c, + 0xe34a, 0xc16e, 0xc09c, 0x21de, 0x4108, 0x4188, 0xc199, 0xb696, + 0xb696, 0xc0df, 0x412d, 0xd315, 0xc115, 0x36cc, 0x40a4, 0x41f3, + 0xc7be, 0xc0e6, 0x4080, 0xc0ca, 0xc151, 0x417e, 0xc185, 0x4174, + 0xc185, 0x4174, 0xc17e, 0x21de, 0x4108, 0x4155, 0xc199, 0xc1fb, + 0xd367, 0x3eb6, 0xe394, 0xc09d, 0x21de, 0x4108, 0x4155, 0xc188, + 0xc0fd, 0xc0ed, 0xe88e, 0xbf2b, 0xc1ba, 0xc1b9, 0xc0bd, 0x40e8, + 0xc217, 0x4114, 0xc130, 0xc06f, 0x411a, 0xc1d3, 0xac1e, 0x48f7, + 0xcca6, 0x40e7, 0xc13c, 0x411a, 0xc1cc, 0xedf0, 0x40c2, 0x421b, + 0xc224, 0xc0eb, 0xc116, 0x25b6, 0xd425, 0xc07f, 0xbbc1, 0xc0db, + 0x36cc, 0x40a4, 0x4167, 0xc7be, 0xc0e9, 0xc18f, 0xc0ec, 0xc118, + 0xd000, 0xc0c1, 0xc089, 0x40e8, 0xc1c1, 0x40c2, 0x41d7, 0xc224, + 0x40c2, 0x41d7, 0xc21b, 0x9e89, 0xb11b, 0x1e3a, 0xc0ba, 0xb52b, + 0xc23a, 0xc237, 0x9fce, 0x2c12, 0x2c13, 0xac14, 0x9e2c, 0xae8a, + 0xb96a, 0xa889, 0xa899, 0xcb3a, 0xc258, 0x4255, 0x4a93, 0x4a97, + 0xcabb, 0xb99c, 0x424e, 0x4a93, 0x4a97, 0xcabb, 0xc24d, 0xc25c, + 0xc25b, 0xab83, 0x3c02, 0xc29b, 0x1f10, 0xa0a0, 0xb2b5, 0xc27d, + 0x42a0, 0xc2a7, 0xc275, 0xc282, 0xc281, 0xa954, 0xc2a2, 0xd366, + 0x3c02, 0xc266, 0x427a, 0xc2a7, 0xc28a, 0x427a, 0xc2a0, 0xc2ad, + 0xc2ac, 0xa3d0, 0xdc7a, 0x5c7b, 0xdc8b, 0xc2c0, 0xc377, 0xc341, + 0xc336, 0xc2b6, 0x2448, 0xb282, 0xc2fd, 0xdc7e, 0xc329, 0xc36e, + 0xc370, 0xdc89, 0xaf87, 0xc368, 0xc2f9, 0xc345, 0xc36a, 0xc319, + 0xc344, 0xc33b, 0x430d, 0xdc8d, 0xc2ed, 0xc2c8, 0xc318, 0xb08d, + 0xc36b, 0xd653, 0xdc8e, 0x42f8, 0xdc8d, 0x431f, 0xc375, 0xc37c, + 0xc2fe, 0xc2f0, 0x430e, 0xc375, 0xc380, 0xc33f, 0xc2cc, 0xdc6c, + 0xdc93, 0xd75f, 0xc37b, 0xdc92, 0xc366, 0xc371, 0xc2b9, 0xc2f2, + 0x4328, 0xd76f, 0xc2b8, 0xc2f1, 0xc2ee, 0xe3e1, 0x2956, 0x2968, + 0xa96c, 0xdc98, 0xee9e, 0xc359, 0xc358, 0x217d, 0xc378, 0xc332, + 0xc2ec, 0xc2ef, 0x4303, 0xc381, 0xc37a, 0xc2dd, 0xc2de, 0xc335, + 0xd3b7, 0x430e, 0xc31f, 0xc2b7, 0x217d, 0xc363, 0xc36d, 0xc32e, + 0xc315, 0xdc9b, 0xc321, 0xc36b, 0x583c, 0xdc9c, 0xa999, 0xa35b, + 0xc4a3, 0xc4b5, 0xc452, 0xc46a, 0x43cf, 0xc474, 0xcfeb, 0xc44b, + 0xc4b0, 0xc3fe, 0xc472, 0xc447, 0xc4bd, 0x4409, 0x4460, 0xc4a2, + 0xc3ce, 0xc3cd, 0x43a8, 0xc474, 0xc43a, 0xc4cf, 0x4434, 0xc439, + 0x2b9d, 0x2bda, 0x2bf3, 0xabf6, 0xa72d, 0xc4ab, 0x448e, 0xc4d4, + 0xc43f, 0xc894, 0xc3b0, 0xbbec, 0xc46f, 0x43cb, 0x4460, 0xc4a2, + 0x4483, 0xc4c8, 0xc4a1, 0xc489, 0x4411, 0xc463, 0x4410, 0xc463, + 0xe6d5, 0x43e1, 0xc439, 0x43e1, 0xc434, 0xc3d0, 0xc4ca, 0xc3f2, + 0xc3b3, 0xc3ae, 0xc39a, 0xc8af, 0x43cb, 0x4409, 0xc4a2, 0x4410, + 0xc411, 0xc476, 0xc4a1, 0xd3b9, 0xc39b, 0xc405, 0xc4cc, 0xc3b1, + 0x43a8, 0xc3cf, 0xc464, 0xc4a6, 0xc4b8, 0x440d, 0xc4c8, 0xc4bf, + 0xc40f, 0x43f1, 0xc4d4, 0x440e, 0xc468, 0x43cb, 0x4409, 0xc460, + 0xc391, 0xc477, 0xc3f0, 0xc3af, 0xc399, 0xc478, 0x28d0, 0xc3ba, + 0xc487, 0x440d, 0xc483, 0xc4da, 0xc43c, 0xc470, 0xc3d1, 0xc4da, + 0x43f1, 0xc48e, 0x44c9, 0xc4d2, 0xaf01, 0xcf38, 0xc515, 0xc50c, + 0x4501, 0xcf3e, 0xc506, 0x44f6, 0xcf3e, 0xc4f7, 0xc4ef, 0x287c, + 0x4816, 0xc8da, 0xc4ee, 0x4f42, 0xcf4c, 0x2617, 0x2690, 0xac1d, + 0xb674, 0x1ea7, 0xc523, 0x1ea7, 0xc522, 0x4a4c, 0x52cf, 0xd607, + 0x2b81, 0x2bcd, 0x2bd5, 0x2bd7, 0x2bdc, 0xabe7, 0xe6fb, 0x9fbd, + 0x2722, 0xc53c, 0x2212, 0x2283, 0x2290, 0x456b, 0xc575, 0x2722, + 0xc53a, 0xc54e, 0xc55d, 0x4559, 0xc571, 0xb6a2, 0x1ea9, 0x4552, + 0x455d, 0xc55e, 0xd015, 0x283a, 0xc54d, 0x283a, 0xc54c, 0xc53d, + 0xc560, 0x1ea9, 0x4546, 0x455d, 0xc55e, 0x4544, 0xc571, 0xa959, + 0x1ea9, 0x4542, 0x4546, 0x4552, 0xc55e, 0x1ea9, 0x4546, 0x4552, + 0xc55d, 0xc551, 0xa793, 0xbbd5, 0xc567, 0xc565, 0xc56a, 0xc568, + 0x453b, 0xc575, 0xaf02, 0x4544, 0xc559, 0x23e0, 0x4582, 0x4589, + 0xc58a, 0xc587, 0x453b, 0xc56b, 0xaf53, 0xc585, 0xa84d, 0x23e0, + 0x4573, 0x4589, 0xc58a, 0x457a, 0xc586, 0xc585, 0xc574, 0x23e0, + 0x4573, 0x4582, 0xc58a, 0x23e0, 0x4573, 0x4582, 0xc589, 0x458f, + 0xde08, 0x458e, 0xde08, 0xc664, 0xc642, 0xc627, 0xc658, 0xc60d, + 0xd0ac, 0xc667, 0xc632, 0xc621, 0xc60b, 0x46b0, 0xe764, 0xc5fe, + 0xc665, 0xc670, 0xc5d9, 0xc662, 0x24d1, 0x2516, 0x255e, 0xc602, + 0xc5c9, 0xc646, 0xc626, 0xc613, 0xc647, 0xd139, 0x45f3, 0xeebb, + 0x3dcb, 0x45f2, 0xeebb, 0xc661, 0xc5fa, 0xc5f9, 0xc5b4, 0x24d1, + 0x2516, 0x255e, 0xc5d6, 0xc649, 0xc62e, 0x3108, 0xc652, 0xc5af, + 0xc5a1, 0xc5ea, 0xa591, 0xc61e, 0xc63b, 0xc617, 0xc5ae, 0xc645, + 0xc5e9, 0xc59f, 0xc65f, 0xc671, 0xc606, 0xc5ad, 0xc63b, 0x4618, + 0xc63a, 0xc66e, 0xc66d, 0xc597, 0x2af6, 0xb194, 0xc624, 0xc5e8, + 0xc5eb, 0xc605, 0x3108, 0xc609, 0x4670, 0xd1c3, 0xc5a0, 0xc669, + 0xc62a, 0xc5f4, 0xc5d2, 0xc66c, 0xc596, 0xc5c7, 0xc5ac, 0xc65e, + 0xc672, 0xc663, 0xc63f, 0xc63e, 0xd1de, 0x45c8, 0x4655, 0xd1c3, + 0xc62b, 0xc66b, 0xc675, 0xc674, 0x23d1, 0x32e8, 0x34a5, 0x3cfc, + 0x3e8c, 0x3f51, 0x467c, 0x6166, 0x6197, 0xe1b1, 0xa0dc, 0x23d1, + 0xc67a, 0x388d, 0xc682, 0x388d, 0xc681, 0xdc8c, 0x2e30, 0x2f52, + 0xbb78, 0xc690, 0x2373, 0xa37d, 0xdccb, 0xc68b, 0xc69a, 0x21d2, + 0xc691, 0xc6a1, 0xc69e, 0x36a4, 0xb6ad, 0xb61f, 0x45b1, 0xe764, + 0xc6ba, 0x46b8, 0xc6b9, 0xef13, 0x46b2, 0xc6b9, 0x46b2, 0xc6b8, + 0xc6b1, 0xef13, 0xc6c8, 0x376f, 0xb86e, 0xc6cd, 0xc6c1, 0x4f3d, + 0x6262, 0xe4b5, 0xc897, 0xc6c7, 0xc6de, 0x2869, 0xee7d, 0x46e3, + 0xdb7c, 0x5462, 0xd4cb, 0xc6dc, 0xc6e4, 0xcc20, 0xc6d7, 0xc6cf, + 0xac3d, 0x46d1, 0xdb7c, 0xc6d8, 0xa362, 0x5361, 0xd62f, 0x1eff, + 0xa023, 0xc742, 0x23bf, 0xce23, 0xc798, 0x5996, 0xd9c6, 0xb14e, + 0xc71f, 0xc71e, 0xc726, 0xc725, 0xc72f, 0xc7d3, 0x472b, 0xc787, + 0xc760, 0x1e51, 0x1f17, 0xd846, 0xd457, 0xc75c, 0xc709, 0xa6f0, + 0xc75e, 0xc7bc, 0xc741, 0xc750, 0xc737, 0xc765, 0xc764, 0xd9a9, + 0x23e1, 0xa8e1, 0xc7c1, 0xc7b6, 0xc72f, 0xc79e, 0xcff3, 0xc70d, + 0xc792, 0xc7aa, 0xc7d2, 0xc7da, 0xc7a0, 0x1e86, 0xb6b8, 0xc7d9, + 0xc786, 0xc751, 0x36cc, 0x40a4, 0x4167, 0xc1f3, 0xc785, 0xd499, + 0xc7a2, 0xc72c, 0xc7b0, 0xc7a9, 0xcb36, 0x47e7, 0xda20, 0x9faf, + 0x47e4, 0xda20, 0xc7ef, 0xc7eb, 0x3917, 0x4887, 0xc8f8, 0xc8ef, + 0xc92c, 0x483f, 0x4926, 0x6271, 0x62db, 0xe45b, 0xc8ad, 0xc8bc, + 0xc8c7, 0xc88e, 0x287c, 0x450e, 0xc8da, 0xc868, 0xc86f, 0xc8b8, + 0xa38e, 0xc8aa, 0xc8d6, 0x40ae, 0x491f, 0xc92e, 0xc92a, 0xc931, + 0xc92b, 0x47ff, 0x4926, 0x6271, 0x62db, 0xe45b, 0xc90e, 0xc85c, + 0xb731, 0xc8a9, 0xc864, 0xc8fd, 0xc8d1, 0xc904, 0xc841, 0xc856, + 0xc817, 0xc912, 0x27c6, 0x48ba, 0xc8bb, 0xc81a, 0xc8e0, 0x6e78, + 0x6e7b, 0xee7c, 0x38ca, 0x38cb, 0x3ab1, 0xbac0, 0x3917, 0xc7f4, + 0xc919, 0xc815, 0xc3f7, 0x27fc, 0x2d0e, 0xad5c, 0x27e6, 0x3900, + 0xc6cc, 0xc8e7, 0xc8e3, 0x2ca9, 0x2d52, 0xad53, 0xe7a8, 0xc855, + 0xc827, 0xc800, 0xc459, 0x33bd, 0xde2b, 0x6e78, 0xee7c, 0xc81c, + 0x486e, 0xc8bb, 0x486e, 0xc8ba, 0xc801, 0xc920, 0xc812, 0xc859, + 0xe695, 0xa387, 0xc82c, 0x287c, 0x450e, 0xc816, 0xc875, 0xc89c, + 0xc89b, 0xc7f6, 0xc1d0, 0xc7f4, 0xeec4, 0xc857, 0xbda7, 0xc85a, + 0x6669, 0x667a, 0xe6aa, 0x2760, 0xa89c, 0xc840, 0xc86a, 0xc88d, + 0x40ae, 0x4832, 0xc92e, 0xc8c1, 0x47ff, 0x483f, 0x6271, 0x62db, + 0xe45b, 0xc83a, 0xc83e, 0xc7fe, 0x40ae, 0x4832, 0xc91f, 0xc83b, + 0xc93b, 0xc93a, 0xc9ae, 0xc9b4, 0xc9a9, 0xc9a1, 0xa996, 0xc995, + 0xc9d8, 0xc9b0, 0xc98e, 0xb346, 0xc9b1, 0xc98d, 0xc984, 0xca1f, + 0xc97f, 0xc9aa, 0xc978, 0xc96f, 0xc94e, 0xc943, 0xafa1, 0xc940, + 0xc985, 0xc93c, 0xc962, 0xc977, 0xc93f, 0xe6e2, 0xc9c3, 0xa3b6, + 0xc9bf, 0xca08, 0x527a, 0x52b8, 0x541f, 0x54fa, 0xd5dd, 0xcc7c, + 0xae74, 0x49cc, 0x4a50, 0x67a6, 0x67a7, 0xef9d, 0x49cb, 0x4a50, + 0xef9d, 0xca2e, 0xd018, 0x4a09, 0xccb3, 0xcc83, 0xa3ea, 0xe8eb, + 0xc955, 0xca4d, 0x4a31, 0xca6a, 0xca2d, 0xca62, 0xca60, 0x4a3e, + 0x4a3f, 0x55c1, 0xd5f3, 0xca0e, 0x4a5e, 0xca6d, 0xc9c6, 0x49d4, + 0xccb3, 0xca05, 0x4cba, 0xd5ad, 0x4a3a, 0xca49, 0xb8f1, 0xc980, + 0xca4c, 0xc9f8, 0xc9cd, 0x49f0, 0xca6a, 0xca3b, 0x4a4f, 0xca69, + 0x4a1a, 0xca49, 0xca32, 0x4a01, 0x4a3f, 0x55c1, 0xd5f3, 0x4a01, + 0x4a3e, 0x55c1, 0xd5f3, 0x4cd3, 0xdc37, 0xca57, 0x4c87, 0xcce0, + 0x4a1a, 0xca3a, 0x4526, 0x4a23, 0x52cf, 0xd607, 0xc9ef, 0x6834, + 0xe896, 0x4a33, 0xca69, 0x49cb, 0x49cc, 0xef9d, 0xca61, 0xca42, + 0x4a06, 0xca6d, 0xc9fe, 0xca51, 0xc9fd, 0xca70, 0x6839, 0x683a, + 0x683d, 0xe893, 0x4a33, 0xca4f, 0x49f0, 0xca31, 0xd3b7, 0x4a06, + 0xca5e, 0xca63, 0x4aae, 0xcac6, 0xab86, 0xe631, 0xab8a, 0xcaca, + 0xcab3, 0xcac5, 0xcab5, 0x4aaf, 0xcab0, 0x424e, 0x4255, 0x4a97, + 0xcabb, 0x424e, 0x4255, 0x4a93, 0xcabb, 0xcac4, 0xcaa9, 0xcaba, + 0xcac7, 0xca9d, 0xbd3c, 0xde30, 0x2be0, 0xcab6, 0x4a77, 0xcac6, + 0x4a91, 0xcab0, 0x4a91, 0xcaaf, 0xca8a, 0xca8e, 0x2be0, 0xcaad, + 0xcaa5, 0x424e, 0x4255, 0x4a93, 0xca97, 0x4076, 0xcac8, 0xca9c, + 0xca8d, 0x4a77, 0xcaae, 0xcaa6, 0x4076, 0xcac3, 0xca83, 0xa947, + 0x4aea, 0xdc4e, 0x9f2b, 0x6f8d, 0xef92, 0x1e26, 0x20a1, 0xae76, + 0x4af6, 0xcaf8, 0x9fdf, 0x5abc, 0xdc0a, 0x4ad6, 0xdc4e, 0x4ade, + 0xcaf8, 0x4ade, 0xcaf6, 0xcbea, 0xcbe4, 0x4b4d, 0xcbb0, 0x2173, + 0xa4b2, 0xcb46, 0xcb67, 0xcb8d, 0x218a, 0x218c, 0x3547, 0x4b56, + 0x4b5e, 0xcba3, 0x9f53, 0x4bc4, 0xd303, 0xc7e2, 0x424b, 0xcb8b, + 0x4bed, 0xcc60, 0xcc69, 0xcbb2, 0xcb14, 0xd9d4, 0x4b0b, 0xcbb0, + 0x3830, 0xba43, 0xcb7a, 0xcbc9, 0x3547, 0x4b27, 0x4b5e, 0xcba3, + 0xcc06, 0xcb82, 0xcbf3, 0xcbe9, 0xcc39, 0xcb8f, 0x3547, 0x4b27, + 0x4b56, 0xcba3, 0xcb15, 0xcbe0, 0xcc4c, 0xcb50, 0xcbd4, 0x4c3d, + 0x4c56, 0xcc64, 0xcbe0, 0xcc21, 0xcb59, 0xcbe6, 0x00f6, 0x1e2a, + 0xa00b, 0xcb3a, 0xcb1f, 0xcb5d, 0xae1a, 0xcc59, 0xa284, 0x3547, + 0x4b27, 0x4b56, 0xcb5e, 0x4c00, 0xd536, 0xcbcb, 0xcc5c, 0xcc6e, + 0xcc1e, 0xcc2b, 0xcbdb, 0x4b0b, 0xcb4d, 0xcb45, 0xd282, 0x4b35, + 0xd303, 0xd483, 0xcb51, 0x2327, 0xcba7, 0xad4c, 0xcc23, 0xcc0d, + 0xcb7c, 0xcc46, 0xcbac, 0x4b71, 0xcb7f, 0xcc12, 0xcb03, 0xcb86, + 0x4b5b, 0x4c01, 0xcc6d, 0xcafe, 0x4b3c, 0xcc60, 0xcc43, 0xcc5b, + 0xcc6c, 0xaf57, 0xcb5a, 0x4ba6, 0xd536, 0x4be9, 0xcc6d, 0x3caa, + 0xbeec, 0xcb58, 0xcbd3, 0x4c14, 0xd4d1, 0xcbe1, 0x4c11, 0xd4d1, + 0xcc6a, 0x3881, 0xba11, 0xcc2b, 0xcbaa, 0xc6d9, 0xcb80, 0xcbd1, + 0xa142, 0x4bab, 0xcc18, 0x35d7, 0xcc4f, 0xba90, 0xcb5c, 0xcb7e, + 0xae18, 0x4c52, 0xcc55, 0xcc5f, 0xcbee, 0xcbd7, 0xcb79, 0x35d7, + 0xcc31, 0xcc58, 0xcc40, 0x55ae, 0xd5ea, 0xcc40, 0x4b7e, 0xcc64, + 0x4c50, 0xd5e4, 0xcb93, 0xcbef, 0xcba8, 0xcc41, 0x4b3c, 0xcbed, + 0x4b7e, 0xcc56, 0xcb3e, 0xcc16, 0xcbf1, 0x4be9, 0xcc01, 0xcba9, + 0x2401, 0xefa5, 0xccf4, 0xe85e, 0xc9c8, 0xc9d5, 0x4a45, 0xcce0, + 0xccb9, 0xeea4, 0xeecf, 0x5083, 0xd085, 0xccf6, 0xccf2, 0xccb5, + 0x1ffc, 0xeb3b, 0xc1d0, 0x2986, 0x299d, 0x2a24, 0xccda, 0xccde, + 0x36f2, 0x6eaf, 0x6eb4, 0xeeb9, 0xcce7, 0x49d4, 0xca09, 0xcca4, + 0xcc8b, 0xca17, 0xccc9, 0xccdd, 0x6762, 0x6eaa, 0x6eab, 0x6eb5, + 0xeeba, 0xe931, 0xccbd, 0xe92c, 0x4a40, 0xdc37, 0xe93b, 0x2986, + 0x299d, 0x2a24, 0xcca7, 0xccc1, 0xccaa, 0x4a45, 0xcc87, 0xe94e, + 0xccae, 0x26e2, 0xa6e3, 0xcc9d, 0xcc74, 0xcc9c, 0x1e1d, 0x4cf9, + 0x4d72, 0xce9f, 0x4cf8, 0xce9f, 0xccfe, 0x1fc2, 0x4e18, 0x4e4b, + 0xce6b, 0x229f, 0xccff, 0x4cfa, 0xcea0, 0x229f, 0xccfc, 0xceaa, + 0xcea3, 0xcea6, 0xcea2, 0xcea1, 0xcea5, 0xcea8, 0xceab, 0xceb9, + 0xceb3, 0xcebd, 0xcebe, 0xceaf, 0xceb0, 0xcebc, 0xceb1, 0x4d8b, + 0xceae, 0x2e0b, 0xceb8, 0xcea7, 0xceb7, 0xcead, 0x4d4d, 0xceb4, + 0xceba, 0xcdb7, 0xcd2e, 0xcdca, 0x4da2, 0xcef8, 0x324e, 0xcd25, + 0x4e32, 0x4e8d, 0x4e9d, 0xcf27, 0xcec6, 0xcec2, 0xcec1, 0xcec5, + 0xcebb, 0xcecd, 0xcec0, 0xcecb, 0xced0, 0xcecc, 0xcec8, 0xaf26, + 0xcec4, 0xcd97, 0x4eca, 0xe77d, 0xae15, 0xcea9, 0x4d93, 0xcecf, + 0xcd1d, 0xced7, 0xcec1, 0xced3, 0x34a7, 0x4d76, 0xcedd, 0xce8a, + 0xcdea, 0x4e27, 0xcee6, 0x4ed4, 0xd8b4, 0xcede, 0xcedc, 0xceda, + 0x4dab, 0x4dda, 0x4ebf, 0xcf10, 0xd32f, 0xced9, 0xced2, 0xced6, + 0x4d82, 0xcedf, 0x1e1d, 0xccf8, 0xcedb, 0x4e6a, 0xced8, 0x34a7, + 0x4d55, 0xcedd, 0xce36, 0x4e6d, 0xd812, 0xcee2, 0xced1, 0x4d71, + 0xcedf, 0xcee1, 0xcee0, 0xcee8, 0xcee3, 0xcd18, 0xcee4, 0xcee5, + 0x3346, 0xb8b1, 0x4d4c, 0xcecf, 0xcd45, 0x4e7c, 0xcee7, 0x4e8c, + 0x4eed, 0xdce1, 0xcefc, 0xcf0d, 0x4dd1, 0xceff, 0x4d2c, 0xcef8, + 0xcefb, 0x4d64, 0x4dda, 0x4ebf, 0xcf10, 0xcef6, 0xcef4, 0xcef9, + 0xcefe, 0xceb2, 0xcf51, 0x4e43, 0xcef7, 0x23d5, 0xcf00, 0xaf69, + 0xcd23, 0xceb6, 0xcefa, 0xceee, 0xcefd, 0x4e5b, 0xcef0, 0xceeb, + 0xcef5, 0xcef2, 0xcf01, 0xcd27, 0xceef, 0xcde1, 0x303b, 0x3460, + 0x4deb, 0xce3d, 0xce41, 0x4da0, 0xceff, 0x4dd6, 0xceea, 0xcef1, + 0xce83, 0x4dd2, 0xceea, 0xcf03, 0xcf04, 0xcf02, 0x4d64, 0x4dab, + 0x4ebf, 0xcf10, 0xcef5, 0xcf09, 0xcf0e, 0xcf14, 0x4dcd, 0xcf17, + 0x4e01, 0xcf18, 0xd913, 0xcf0c, 0xcf16, 0xcf13, 0xcd5a, 0x303b, + 0x3460, 0x4dcf, 0xce3d, 0xcf05, 0xceac, 0xcf11, 0xcf08, 0xcec3, + 0xcf0f, 0xcf07, 0xd1f4, 0x4e15, 0xcf0a, 0x4de3, 0xcf18, 0x4e69, + 0xcef3, 0xd426, 0xcf19, 0xcf22, 0xcf12, 0xcec9, 0xcf23, 0x4dfc, + 0xcf0a, 0xcf1e, 0x4cfb, 0x4e4b, 0xce6b, 0xcf1a, 0xcf1c, 0xcf1f, + 0xcf1b, 0x23bf, 0xc70c, 0x4e31, 0xceb5, 0x4d5b, 0xcee6, 0xae4c, + 0xcf1d, 0xcf21, 0xcf29, 0x4e26, 0xceb5, 0x4d2f, 0x4e9d, 0xcf27, + 0xcea4, 0xcf26, 0x4d77, 0xe9bd, 0xcf15, 0xcf25, 0x303b, 0x3403, + 0x3460, 0x4dcf, 0xcdeb, 0xcee9, 0xcdd0, 0x4db3, 0xcef7, 0x4e70, + 0xcf2b, 0xcf2a, 0xce66, 0x4e8e, 0x4e96, 0xcea4, 0x4cfb, 0x4e18, + 0xce6b, 0x4e61, 0xcee3, 0xcf2f, 0xcec7, 0xcf2e, 0x1f1e, 0xa098, + 0xcffb, 0xcf2d, 0xcdbd, 0xced5, 0x4e4d, 0xcee3, 0xcf0b, 0xce82, + 0xce48, 0x4e04, 0xcef3, 0x4d75, 0xced8, 0x4cfb, 0x4e18, 0xce4b, + 0x4d78, 0x5327, 0xd812, 0x4f30, 0xe7c1, 0xcf33, 0x4e45, 0x4f2b, + 0xcf32, 0xcf34, 0xcece, 0x4d99, 0xcee7, 0xcf24, 0xcf31, 0xb9db, + 0xce64, 0xcdd5, 0xe8a3, 0xcf2c, 0x4e98, 0xcf35, 0x4d56, 0xcea9, + 0x4d9a, 0x4eed, 0xdce1, 0xcd2f, 0x4e4a, 0x4e96, 0xcea4, 0x4e92, + 0xcf20, 0x4e8f, 0xcf20, 0xcf28, 0xb24d, 0x4e4a, 0x4e8e, 0xcea4, + 0x4e89, 0xcf35, 0xcf06, 0x4d2f, 0x4e32, 0xcf27, 0x4cf8, 0xccf9, + 0xccfe, 0xcd06, 0xcd05, 0xcd02, 0x4e34, 0x4e4a, 0x4e8e, 0xce96, + 0xcd07, 0xcd04, 0xcd1a, 0xcd08, 0x4d4b, 0xce8a, 0xcd00, 0xcd09, + 0xcdef, 0xcd1c, 0xcd18, 0xcd14, 0xcd15, 0xcd17, 0xcdb1, 0xcd0d, + 0xcd1d, 0x4e26, 0xce31, 0xcdb8, 0xcd1b, 0xcd19, 0xcd0b, 0xcd21, + 0xcd35, 0xcd16, 0xcd10, 0xcd13, 0x4d64, 0x4dab, 0x4dda, 0xcf10, + 0xcd3a, 0x4d32, 0xcd4f, 0xcd31, 0xcdf4, 0xcd44, 0xcd33, 0xcd30, + 0xce54, 0xcd42, 0xce10, 0xcd46, 0xcd3c, 0xcd40, 0xcd39, 0xce79, + 0x4d4c, 0xcd93, 0xcd3f, 0xcd81, 0xcd68, 0xcd50, 0xcd5d, 0x4e5e, + 0xe076, 0xcd70, 0xcd4e, 0x4d75, 0xce6a, 0xcd66, 0xcd62, 0xcd73, + 0xcd61, 0x34a7, 0x4d55, 0xcd76, 0xcd5e, 0x4d71, 0xcd82, 0xcd86, + 0xcd83, 0xcd79, 0x4d89, 0x4e4d, 0xce61, 0xcd8c, 0xcd8f, 0x4d5b, + 0xce27, 0x4d99, 0xce7c, 0xcd88, 0xce3e, 0x4dd2, 0xcdd6, 0xcdbe, + 0x4d9a, 0xce8c, 0xcdba, 0xcdcb, 0xcdbd, 0xcdd4, 0xcdc4, 0x4e04, + 0xce69, 0xcdad, 0x4dbf, 0xcddc, 0xcdac, 0x4db3, 0xce43, 0x4d2c, + 0xcda2, 0xcdaf, 0xcdb9, 0xcda3, 0xcd9c, 0xcdbb, 0xcdb0, 0x4da0, + 0xcdd1, 0xcdb4, 0xcdc7, 0xcdd9, 0xcdd7, 0xcdd8, 0xcdec, 0xce9c, + 0xcdf9, 0xcdf2, 0xcddd, 0x4dfc, 0xce15, 0xce62, 0xcde6, 0xcd9e, + 0xcdde, 0xcdf6, 0x4d64, 0x4dab, 0x4dda, 0xcebf, 0xcdf1, 0xce0b, + 0xcde9, 0xcde0, 0xce37, 0xcde8, 0xcde1, 0x4de3, 0xce01, 0xce09, + 0xce1b, 0xce1f, 0xce1d, 0xce2b, 0xce17, 0xce1e, 0x4e8f, 0xce92, + 0xce2d, 0xce0a, 0xce11, 0xce7d, 0xce39, 0xce35, 0x4d2f, 0x4e32, + 0xce9d, 0xce93, 0xce2e, 0xce46, 0x4e45, 0xce70, 0xce88, 0xce5a, + 0xce55, 0xce52, 0x4e6e, 0xe7c1, 0xce7e, 0xce70, 0xce6f, 0xce73, + 0x4e89, 0xce98, 0x4f3b, 0x4f50, 0xe475, 0xa378, 0xc4e8, 0xc0b0, + 0x3b20, 0xcf3c, 0xcf36, 0x3b20, 0xcf3a, 0x46cb, 0x6262, 0xe4b5, + 0x44f6, 0xc501, 0x4516, 0xcf4c, 0xba3d, 0x275b, 0x28b0, 0x28b5, + 0x28dc, 0xcf4e, 0x4516, 0xcf42, 0x275b, 0x28b0, 0x28b5, 0x28dc, + 0xcf48, 0x4f36, 0xe475, 0x4db2, 0x4f52, 0xcf53, 0x4f51, 0xcf53, + 0x4f51, 0xcf52, 0x2570, 0x26c9, 0xcf85, 0x4f70, 0xcf78, 0xcf77, + 0x3683, 0xdfa0, 0x4f5a, 0xcf78, 0xcf86, 0x208c, 0x69e1, 0xea82, + 0xcf80, 0xcf62, 0x4f5a, 0xcf70, 0xcf76, 0x4f88, 0xd98a, 0x21aa, + 0xae42, 0xcf57, 0xcf74, 0x4f88, 0x5989, 0xd98a, 0x4f81, 0x4f87, + 0x5989, 0xd98a, 0xd288, 0xd288, 0xcf97, 0xcf91, 0xcf90, 0xcf8c, + 0xcfa5, 0xcfa8, 0xcfa4, 0xcfa3, 0xcf9f, 0xcfa1, 0x9e49, 0x217b, + 0xe90a, 0xcfb9, 0x4fb6, 0xd1bb, 0x4fb4, 0xd1bb, 0xcfae, 0x4fc5, + 0xcfe4, 0x4fc4, 0xcfe4, 0xcfe0, 0x9e60, 0xcff9, 0xcffd, 0xcfec, + 0xcfc6, 0x4fc4, 0xcfc5, 0xc3a9, 0xcfda, 0xcffa, 0xc796, 0xcfd8, + 0xcff1, 0x4e59, 0xe8dc, 0xcfd9, 0xc1ff, 0xb537, 0xd008, 0xd007, + 0xd00b, 0xd00a, 0xc54a, 0xc9d0, 0xb7b1, 0xe504, 0xd02e, 0xd5c9, + 0xd02c, 0x39c8, 0xe392, 0xd027, 0xd022, 0xbacc, 0xd073, 0xb065, + 0xd043, 0xdead, 0x504c, 0x5077, 0xdec4, 0xd076, 0xd03c, 0xd07e, + 0x5040, 0x5077, 0xdec4, 0xd079, 0x5068, 0xd06f, 0x2723, 0xa7a9, + 0xe5fb, 0x28fb, 0xaa7f, 0x5066, 0x506a, 0xd070, 0x5061, 0x506a, + 0xd070, 0x5054, 0xd06f, 0xd075, 0x5061, 0x5066, 0xd070, 0xd06f, + 0x2abf, 0xb127, 0xd06f, 0x5054, 0x5068, 0x506b, 0xd06e, 0x5061, + 0x5066, 0xd06a, 0xa8f0, 0xd038, 0x242c, 0xd07d, 0xd069, 0xd042, + 0x5040, 0x504c, 0xdec4, 0xd04d, 0x242c, 0xd074, 0xd04b, 0x4c9b, + 0xd085, 0x4c9b, 0xd083, 0xd088, 0xd087, 0xab8d, 0xd0af, 0x5178, + 0xd193, 0xd135, 0xd19a, 0xd0da, 0xc5a3, 0xeaaf, 0x508e, 0xd0bb, + 0xa3b7, 0x3bd3, 0xd8ac, 0xe91a, 0xd0af, 0xd14e, 0xd16b, 0xd139, + 0x5105, 0x5107, 0xd10b, 0x1f37, 0xa191, 0x51bb, 0xd1bd, 0xb3f9, + 0xd0a7, 0xa2dd, 0x585a, 0xeb0d, 0xb727, 0xd156, 0xd1da, 0x511b, + 0xde01, 0xd1d9, 0xd1a0, 0x5106, 0xd13a, 0x50c1, 0xd10b, 0x5103, + 0xd13a, 0xd0c1, 0xd109, 0xd108, 0x50c1, 0xd105, 0xd1be, 0x51d3, + 0x51df, 0xead2, 0xd1cd, 0x5133, 0xd166, 0xd1bf, 0xd1e0, 0xa43b, + 0x5173, 0xde0b, 0x50eb, 0xde01, 0xa507, 0x9fee, 0xd131, 0xd12b, + 0x2318, 0x5111, 0xd166, 0xd0a1, 0xd161, 0xd1c9, 0x45ee, 0xd0c0, + 0x5103, 0xd106, 0xd157, 0xa00e, 0x51c8, 0xd1d8, 0xe183, 0xd0be, + 0xd0e8, 0xd13e, 0xd195, 0xd1a3, 0xd136, 0x2318, 0x5111, 0xd133, + 0xd0bf, 0xef76, 0xe84b, 0x511a, 0xde0b, 0x50a0, 0xd193, 0xd1a9, + 0xd183, 0xea30, 0xeac8, 0xd190, 0xd17d, 0xd182, 0xd1cf, 0x50a0, + 0xd178, 0xd158, 0xd0a4, 0xd0f6, 0xd15f, 0xecd5, 0xd17b, 0xe94d, + 0x6ac4, 0xead3, 0x4fb4, 0x4fb6, 0x50c6, 0xd1bd, 0x50c6, 0xd1bb, + 0xd10d, 0xd113, 0xd1cb, 0x4655, 0xc670, 0x514a, 0xd1d8, 0xd138, + 0xd1c0, 0xd110, 0x5191, 0xead5, 0x510f, 0xd1df, 0x514a, 0xd1c8, + 0xd0ed, 0xd0ea, 0xd1e2, 0xc66f, 0x510f, 0xd1d3, 0xd114, 0xd1dc, + 0xa367, 0x9e34, 0xd1f0, 0xd1ed, 0xcdfb, 0x23f0, 0xa76e, 0xdf3f, + 0x9e0e, 0xa174, 0x1e3e, 0x3319, 0xb4e7, 0xb5e7, 0x3368, 0xd20e, + 0xd20d, 0xd213, 0xd210, 0x5217, 0x62ea, 0xe4fa, 0x5216, 0x62ea, + 0xe4fa, 0xe928, 0xd264, 0xd239, 0x523b, 0xd26b, 0xd266, 0xd259, + 0xb7c1, 0xd24a, 0xd229, 0x522e, 0xd26b, 0xd236, 0xd231, 0xba2f, + 0x3a79, 0xd26a, 0xd223, 0xd230, 0x3a79, 0xd263, 0x522e, 0xd23b, + 0xd271, 0x26cf, 0xd270, 0x5276, 0x5277, 0x5c53, 0xdc54, 0x5273, + 0x5277, 0x5c53, 0xdc54, 0x5273, 0x5276, 0x5c53, 0xdc54, 0xd279, + 0xd278, 0x49c7, 0x52b8, 0x541f, 0x54fa, 0xd5dd, 0xcbc0, 0x4f8a, + 0xcf8b, 0xd28c, 0xd28b, 0xa349, 0xd58c, 0xd56a, 0xd606, 0xd2b2, + 0xd2b1, 0x49c7, 0x527a, 0x541f, 0x54b7, 0x54fa, 0x5553, 0xd5dd, + 0xa20d, 0xd4ef, 0x1e42, 0xa208, 0xd466, 0xd5f6, 0xd3a7, 0xd407, + 0xd4bc, 0xd2e7, 0x26cc, 0x4526, 0x4a4c, 0x5607, 0xd613, 0xd351, + 0xd2e2, 0xd2e1, 0xd2ce, 0xa040, 0x55b2, 0xd60b, 0xd393, 0xd3f0, + 0x4b35, 0xcbc4, 0x2179, 0xd332, 0xd396, 0xd622, 0xd526, 0xa84b, + 0xc162, 0xd354, 0x4e6d, 0xd812, 0xcd65, 0xd438, 0x2179, 0xd30a, + 0xd34a, 0xd395, 0xd346, 0x1f9f, 0xd5a6, 0xd2d0, 0xd318, 0x2e84, + 0xd38a, 0xd598, 0xd3a2, 0xd558, 0xd4fd, 0xd434, 0xd54e, 0xd588, + 0x5415, 0xd5ba, 0x46ea, 0x5569, 0xd62f, 0x3804, 0xb9ae, 0xd477, + 0xbece, 0xc296, 0xc192, 0xd541, 0xd5ce, 0xd4c0, 0xd52d, 0xd552, + 0xd452, 0xd464, 0x546f, 0x55ac, 0xd5e5, 0xdc46, 0xb357, 0xd510, + 0x3d96, 0xd49e, 0x2e84, 0xd358, 0xd2fa, 0xd347, 0xd30e, 0xa50d, + 0xd35a, 0xd2cb, 0xd40a, 0xd4ee, 0xd494, 0xd435, 0xd3df, 0xd59f, + 0x4372, 0xca6b, 0xd555, 0xc469, 0x6d2c, 0x6daf, 0xee0e, 0x5493, + 0xd4f4, 0xd3be, 0xd3bd, 0xd458, 0xb79c, 0x235c, 0xd514, 0xd3b5, + 0xa807, 0x234e, 0x2d0b, 0xd550, 0xd2fd, 0xd506, 0x2eb5, 0x544a, + 0xd4ed, 0xd445, 0xd2cc, 0xd3b1, 0xd420, 0xd4f1, 0x5360, 0xd5ba, + 0xd600, 0xd63f, 0x49c7, 0x527a, 0x52b8, 0x54fa, 0xd5dd, 0xd40c, + 0x56cd, 0xd7a2, 0x25b6, 0xc1df, 0xce08, 0xd56d, 0xd5a9, 0x9e07, + 0x557f, 0x55fc, 0xd610, 0xd35d, 0xd3b4, 0xd330, 0xd55a, 0xd3f9, + 0xa3f6, 0x2eb5, 0x53f4, 0xd4ed, 0xd36d, 0xc740, 0xd3d1, 0xb939, + 0xd593, 0x46d6, 0xd4cb, 0xd36e, 0xd2c7, 0xd58a, 0xa85f, 0xb934, + 0xd36f, 0xd525, 0xd364, 0xd515, 0xcbc6, 0xd546, 0xd562, 0xd523, + 0xd51e, 0xb41c, 0x53bc, 0xd4f4, 0xd3b3, 0x31de, 0x3e95, 0x3fdb, + 0xc7c7, 0x3d96, 0xd385, 0xaf60, 0xd533, 0xd2b8, 0xd2cd, 0xd36a, + 0xae2d, 0x46d6, 0xd462, 0x4c11, 0xcc14, 0xd5cd, 0xd58a, 0xd63a, + 0xd577, 0xe3a3, 0xea40, 0x2eb5, 0x53f4, 0xd44a, 0xd3b2, 0xd2c1, + 0xd40d, 0x53bc, 0xd493, 0x49c7, 0x527a, 0x52b8, 0x541f, 0xd5dd, + 0xd35c, 0x298d, 0xa9f8, 0xd3f1, 0xd37b, 0xd84a, 0x235c, 0xd3d4, + 0xd482, 0xd48c, 0xd48b, 0xd471, 0xd311, 0xd36b, 0xd5bc, 0xd53b, + 0xd4a8, 0xeebb, 0x2328, 0xd5cf, 0x4ba6, 0xcc00, 0xd594, 0xd61e, + 0xd5fa, 0xd532, 0x55f9, 0xdb6a, 0xd368, 0xd487, 0x554b, 0xd602, + 0x554a, 0xd602, 0xd35e, 0x234e, 0xd3ef, 0xd36c, 0xd2b8, 0xd3b8, + 0xd35b, 0xd43c, 0xd489, 0xd361, 0xd29c, 0xd427, 0xd580, 0xd604, + 0x55f4, 0xd60a, 0xd4e3, 0x5431, 0x55fc, 0xd610, 0xd570, 0xd35f, + 0x546a, 0xd4df, 0xd297, 0xa9dc, 0xd460, 0xd537, 0x26ed, 0xa712, + 0xd359, 0xd3b6, 0x1f9f, 0xd350, 0xd428, 0x55b0, 0xd60d, 0x536f, + 0xd5e5, 0xca17, 0x4c54, 0xd5ea, 0xd5f7, 0x55ab, 0xd60d, 0x52f9, + 0xd60b, 0x5360, 0xd415, 0xd52f, 0x4a01, 0x4a3e, 0x4a3f, 0xd5f3, + 0x1e1b, 0x23e2, 0x3a37, 0xbb09, 0x201f, 0x2fa3, 0xd024, 0xd4dd, + 0xd369, 0x2328, 0xd535, 0xd61a, 0x49c7, 0x527a, 0x52b8, 0x541f, + 0xd4fa, 0x563d, 0xd646, 0xcc58, 0x536f, 0xd5ac, 0x4c54, 0xd5ae, + 0x4a01, 0x4a3e, 0x4a3f, 0xd5c1, 0x5574, 0xd60a, 0xd2c8, 0xd5af, + 0x553c, 0xdb6a, 0xd53a, 0x5431, 0x557f, 0xd610, 0xd41a, 0x554a, + 0xd54b, 0xd572, 0xd2a6, 0x4526, 0x4a4c, 0x52cf, 0xd613, 0x5574, + 0xd5f4, 0x52f9, 0xd5b2, 0x55ab, 0xd5b0, 0x6a65, 0xeaa5, 0x5431, + 0x557f, 0xd5fc, 0x52cf, 0xd607, 0xba97, 0xd5d3, 0xd539, 0xd30f, + 0xa170, 0x46ea, 0xd361, 0xd4e0, 0x55df, 0xd646, 0xd41d, 0xa914, + 0x55df, 0xd63d, 0x1e55, 0xd65d, 0xd65c, 0xb16e, 0xc307, 0x21e6, + 0xa904, 0xa47c, 0x565a, 0xd65b, 0x5657, 0xd65b, 0x5657, 0xd65a, + 0xd64f, 0x1e55, 0xd64e, 0xa3f7, 0xd666, 0xd665, 0x9e8f, 0x567a, + 0xd7f2, 0xd66f, 0xd7e3, 0xd66c, 0xd768, 0x2b83, 0xd6c7, 0xd66b, + 0xd771, 0xe6d6, 0xd766, 0xd806, 0xd755, 0xd7fb, 0xd79e, 0xd801, + 0x57a1, 0xd7c1, 0xd739, 0xd72f, 0x5745, 0x5836, 0xd83a, 0xd788, + 0xd6d4, 0xd814, 0xd6ba, 0xec8d, 0xd706, 0xd6d4, 0xd6a6, 0x2b83, + 0xd675, 0xd831, 0x5424, 0xd7a2, 0x5807, 0xd823, 0xd7f6, 0x5698, + 0x56b4, 0xd716, 0xef03, 0xd83b, 0xd7a7, 0xd7c4, 0xd6fa, 0xd7ef, + 0xd784, 0xd810, 0xd6f1, 0xd715, 0x5c9d, 0xdd1d, 0xd82d, 0xd6ac, + 0xd782, 0xd6fb, 0xd6d4, 0xd778, 0x574b, 0xd81f, 0xd68c, 0xd68b, + 0xeb4e, 0x5695, 0x5836, 0xd83a, 0x577f, 0xd805, 0xd7c8, 0xd7ec, + 0x5721, 0xd81f, 0xd80d, 0xd680, 0xc32c, 0xd815, 0xd67e, 0xd671, + 0xc33f, 0xd67b, 0xd717, 0xd7bb, 0xd811, 0x5747, 0xd805, 0xd7bf, + 0xd70b, 0xd6f3, 0xd696, 0xd78e, 0xd78d, 0xd7fb, 0x5827, 0xd839, + 0xd682, 0xd68a, 0x5424, 0xd6cd, 0x3594, 0xb59e, 0xd6ef, 0xd7ce, + 0xd77c, 0xd780, 0xd68a, 0xd6f0, 0xd7c7, 0xd7c6, 0xd748, 0xd7a8, + 0xd828, 0xd80e, 0xd66e, 0xd749, 0xd6f2, 0xd66b, 0xd6cf, 0xd821, + 0xd80f, 0x5681, 0xd798, 0xd683, 0x5747, 0xd77f, 0xd67f, 0x56ce, + 0xd823, 0xd74e, 0xd7d2, 0xd7f9, 0xd6f4, 0xd77e, 0x4d78, 0x4e6d, + 0xd327, 0xd69d, 0xd761, 0x5721, 0xd74b, 0xd7f8, 0xb0f7, 0x56ce, + 0xd807, 0x5799, 0xd839, 0xd7cf, 0xd702, 0xd6ca, 0x5695, 0x5745, + 0xd83a, 0x5799, 0xd827, 0x5695, 0x5745, 0xd836, 0xd6ee, 0x4383, + 0xdc9c, 0xd844, 0xd842, 0xe1c1, 0x1e51, 0x1f17, 0xc73e, 0x24af, + 0xa580, 0xd511, 0xb72f, 0x2563, 0x5858, 0xe29c, 0xa40c, 0xadf7, + 0x2563, 0x5854, 0xe29c, 0xd0e1, 0x236b, 0xd85e, 0x2675, 0x585f, + 0xe053, 0xa1b2, 0x236b, 0xd85b, 0x2675, 0x585c, 0xe053, 0xd864, + 0xd863, 0xd8dc, 0xe336, 0xd96f, 0xd89e, 0xa3ea, 0xd8b5, 0xd956, + 0x2acb, 0x2b1d, 0xd8ca, 0xd918, 0xae12, 0x596a, 0x67c8, 0xe7e4, + 0xd86e, 0x3bd3, 0xd0b2, 0xd972, 0xeef9, 0xd94f, 0x4d5d, 0xd8e4, + 0xd87d, 0xd8cc, 0xd8dd, 0xd960, 0xd90c, 0xd885, 0xd8b7, 0x58e1, + 0xe1cc, 0xd8e0, 0xd865, 0xd8c5, 0xd8d9, 0x58cf, 0xe1cc, 0xd933, + 0xd95d, 0x58b4, 0xd932, 0xd947, 0x5912, 0xd943, 0xb707, 0xd92b, + 0xd8f5, 0xd8f4, 0xa236, 0xa90d, 0xb0fc, 0xd8c8, 0xd90f, 0xd90e, + 0x58e6, 0xd943, 0xcde5, 0xd886, 0xd938, 0xd94c, 0xd8ed, 0xd8e4, + 0xd8e2, 0xd964, 0xd91b, 0x9eb5, 0x58e6, 0xd912, 0xd8e5, 0xd91d, + 0xb742, 0xd8af, 0xd974, 0xd884, 0xd8e3, 0xd8c6, 0xd934, 0xd89c, + 0xb446, 0xb4f7, 0xd86c, 0xd8ad, 0x5955, 0xd97d, 0xd974, 0x2364, + 0xa365, 0x290d, 0xafa9, 0xe738, 0xb838, 0x4f87, 0x4f88, 0xd98a, + 0x4f81, 0x4f87, 0x4f88, 0xd989, 0xd9c1, 0xaf01, 0xd9c3, 0xd9c4, + 0x599a, 0x59ba, 0xd9c9, 0x5994, 0xd9c5, 0x5993, 0xd9c5, 0x470e, + 0xd9c6, 0xd9c7, 0x5990, 0x59ba, 0xd9c9, 0xd9cb, 0xd9cd, 0xd9ce, + 0x59bd, 0xd9c8, 0xc779, 0x9eb2, 0xd9ca, 0xd9cf, 0xd9b7, 0xd9d0, + 0x59c0, 0xd9c2, 0xd9bc, 0x59b0, 0xd9d1, 0x358d, 0x5990, 0x599a, + 0xd9c9, 0xd9b6, 0x59a7, 0xd9c8, 0xd9cc, 0x59b3, 0xd9c2, 0xd98b, + 0x59b3, 0xd9c0, 0xd98e, 0xd98f, 0x5993, 0xd994, 0x470e, 0xd996, + 0xd998, 0x59a7, 0xd9bd, 0x5990, 0x599a, 0xd9ba, 0xd9ac, 0xd9a1, + 0xd9bf, 0xd9a5, 0xd9a6, 0xd9af, 0xd9b2, 0xd9b7, 0xcb4b, 0x59ef, + 0xd9f6, 0xb2b5, 0xd9f4, 0xd9e7, 0xd9f8, 0xd9e3, 0x59d7, 0xd9f6, + 0xd9de, 0x59d7, 0xd9ef, 0xd9e6, 0x59fd, 0xd9ff, 0x59f9, 0xd9ff, + 0x59f9, 0xd9fd, 0x5a01, 0xdba0, 0x5a00, 0xdba0, 0xdba2, 0xdba3, + 0xdba1, 0xdbaf, 0xdba7, 0xdba8, 0xdba6, 0xdbb1, 0xdbad, 0xdbaa, + 0xdbab, 0x3258, 0xdbac, 0xdbb0, 0xdabe, 0xdbb9, 0xdbb6, 0xdbbc, + 0x47e4, 0xc7e7, 0x241f, 0xa656, 0xbb23, 0xdbc0, 0xdbb7, 0xdbbb, + 0xdbbf, 0x9fe1, 0xdbbe, 0xdbb8, 0x5b6f, 0xdbd1, 0xdbc9, 0x24ec, + 0xdbc3, 0xdbca, 0xbce8, 0x5b49, 0xdbc1, 0xda6c, 0xdbc2, 0x2467, + 0xdbcb, 0x246a, 0xa492, 0xa46d, 0xdbb5, 0xdbc8, 0xdbd2, 0xdbcf, + 0xdbc4, 0xdbd0, 0xdbc7, 0xdbce, 0xdbc5, 0xdbcd, 0xdb8b, 0xa48f, + 0xdbe9, 0xdbe2, 0xdbe3, 0xdbd5, 0xabdf, 0xdbd7, 0xdbe7, 0x5a3d, + 0xdbdf, 0xdbe1, 0xdbe0, 0xdbd8, 0x5b6e, 0xdbdd, 0xdbe5, 0xdbe6, + 0xdbdc, 0xdbd9, 0xdbd6, 0xdbd4, 0xdbdb, 0xdbd3, 0xa938, 0xdb7d, + 0xdb04, 0xafd7, 0xdba4, 0xdbf3, 0xdbf6, 0xdbde, 0x3096, 0xb102, + 0x2500, 0xdbf1, 0xdbee, 0xdbed, 0xdbda, 0xdbeb, 0xdbec, 0xdbef, + 0xdbf0, 0xdbf5, 0xdbf2, 0x5aac, 0xdbf4, 0x5aaa, 0xdbf4, 0x5b80, + 0xdbfb, 0xa531, 0xdc01, 0xdbfe, 0xdc07, 0xdbfd, 0x4ae9, 0xdc0a, + 0xda1a, 0xdc03, 0xdc04, 0xdc06, 0xdc08, 0xdbff, 0xdbf7, 0x5aeb, + 0xdc0f, 0xdbe4, 0xdbf9, 0xdbfc, 0xdc05, 0xdbba, 0xdc02, 0xdc00, + 0xdc0d, 0xdc1e, 0xdc1d, 0x5afc, 0xdc16, 0x5b1a, 0xdc25, 0xdbe8, + 0x5b8d, 0xdc14, 0xdc1b, 0xdc10, 0xdb5c, 0x5acc, 0xdc0f, 0x242f, + 0x2518, 0x2553, 0x2554, 0x255f, 0xe5d9, 0xdc15, 0xdc18, 0xdbb3, + 0x3697, 0xdc19, 0xdc0c, 0x5bbd, 0xe8a8, 0xdbf8, 0xdc1a, 0x5ae0, + 0xdc16, 0xdbfa, 0xdc0b, 0xdc12, 0xdc13, 0xda8a, 0xdbcc, 0xdc0e, + 0xbb4c, 0xdc1c, 0xdc27, 0xdc11, 0xdc21, 0xdc24, 0xdc26, 0x5ae1, + 0xdc25, 0xdbb2, 0xdc22, 0x5b21, 0xdc23, 0x5b20, 0xdc23, 0xdc1f, + 0xa546, 0x5b81, 0xdc2a, 0xdc2c, 0x5b7e, 0xdc2b, 0xa5f9, 0xdbb4, + 0xdc28, 0x247c, 0xa611, 0xdc29, 0x24d7, 0xa629, 0x5a3c, 0xdbc1, + 0xdbb9, 0xdc32, 0xdba5, 0xa642, 0x5b5b, 0xdc2e, 0xdbc6, 0xdc2f, + 0xdc2d, 0x5b56, 0xdc2e, 0x5ae9, 0xdc31, 0xa66a, 0x553c, 0xd5f9, + 0x2661, 0xdc35, 0xbbc1, 0x5a71, 0xdbdd, 0x5a33, 0xdbd1, 0xdbae, + 0xa584, 0x5b93, 0xdba9, 0xdc34, 0xb2a4, 0xdbea, 0x46d1, 0xc6e3, + 0xda89, 0x5b2d, 0xdc2b, 0x5aad, 0xdbfb, 0x5b2b, 0xdc2a, 0x5b9a, + 0xdd5e, 0xdc09, 0x23d8, 0xa909, 0xda5f, 0x2bb4, 0xe1bc, 0x5ae4, + 0xdc14, 0x1ec7, 0x5b90, 0xe6e0, 0x5b8e, 0xe6e0, 0xdc17, 0x5b72, + 0xdba9, 0xdc30, 0xdc36, 0x5b83, 0xdd5e, 0xdc20, 0xdc33, 0x5a00, + 0xda01, 0xda08, 0xda02, 0xda03, 0xda8d, 0xdb4f, 0xda10, 0xda0c, + 0xda0e, 0x5b72, 0xdb93, 0xda15, 0xda16, 0x3258, 0xda17, 0xda13, + 0xdb70, 0xda0a, 0xda18, 0xda12, 0xdb1b, 0xdaf1, 0xdb33, 0xda4e, + 0xda1d, 0xda25, 0xda31, 0x5a1b, 0xdb4c, 0xdad6, 0xda29, 0xda1f, + 0x5af7, 0xe8a8, 0xda2d, 0xda2a, 0xda23, 0x5a3c, 0xdb49, 0xda41, + 0xda36, 0xda55, 0xda5b, 0xdb58, 0xda57, 0xda50, 0xda34, 0xda3a, + 0xda46, 0xdb05, 0xda5e, 0xda58, 0xda54, 0xda56, 0x5a33, 0xdb6f, + 0xda52, 0xda86, 0xda84, 0xda66, 0xda7f, 0xda69, 0xda70, 0xda7c, + 0xdaa0, 0xda85, 0xda75, 0x5a71, 0xdb6e, 0xda95, 0xda6c, 0xda6e, + 0xda6d, 0xda62, 0xda63, 0xdacd, 0xda72, 0xda73, 0xda6b, 0xdae2, + 0xda61, 0xdb78, 0xdaa1, 0xdaa3, 0xda9e, 0xda9a, 0x309e, 0xdaa4, + 0xdaa5, 0x2500, 0xda98, 0xdaa8, 0xda91, 0x5aaa, 0xdaac, 0xdaa6, + 0xda92, 0xdacb, 0xdaf8, 0xdacf, 0xdafe, 0x5aad, 0xdb80, 0xdad1, + 0xdab9, 0xdab2, 0xdac9, 0xdadb, 0xdab0, 0xdad7, 0xdabf, 0xdac2, + 0xdad2, 0xdac4, 0xdab6, 0xdac7, 0xdb85, 0x4ae9, 0xdabc, 0xdb00, + 0xdaf6, 0xdadc, 0xdb0a, 0x5acc, 0xdaeb, 0xdae7, 0xdb14, 0xdb01, + 0xdb02, 0x5ae4, 0xdb8d, 0xdaed, 0x5ae0, 0xdafc, 0xdb92, 0xdaee, + 0x3697, 0xdaf3, 0xdafa, 0xdae6, 0xdb0e, 0xdade, 0xdadd, 0xdb28, + 0xdb9c, 0xdb16, 0xdb1d, 0x5b20, 0xdb21, 0xdb17, 0x5ae1, 0xdb1a, + 0xdb19, 0xdb10, 0xdb39, 0xdb3e, 0x5b2b, 0xdb81, 0x5b2d, 0xdb7e, + 0xdb2c, 0xdb5a, 0x5b56, 0xdb5b, 0xdb59, 0xdb95, 0xdb5c, 0xdb4e, + 0xdb9e, 0xdb74, 0xdb6b, 0xdb96, 0x4a40, 0xccd3, 0xac88, 0x3e13, + 0x3eaa, 0xdc40, 0x3e13, 0x3eaa, 0xdc3f, 0xd373, 0xac82, 0x1e30, + 0x5c50, 0x673b, 0xe74a, 0x4ad6, 0xcaea, 0x1e30, 0x5c4a, 0x673b, + 0xe74a, 0x5273, 0x5276, 0x5277, 0xdc54, 0x5273, 0x5276, 0x5277, + 0xdc53, 0xdc5a, 0xdc58, 0xdc87, 0x9e88, 0xc32a, 0xdc76, 0xdc6e, + 0xc2b2, 0xc2b4, 0xdc94, 0xc2c9, 0xef26, 0xdc64, 0xc2e2, 0xc2b4, + 0xc683, 0x42f8, 0xc30d, 0xc30a, 0xc32f, 0xc32b, 0xdc7c, 0xc34f, + 0xc37e, 0x4383, 0xd83c, 0x56fd, 0xdd1d, 0xdd1e, 0x2458, 0x24e1, + 0xdd20, 0xdd1f, 0x321d, 0xdd22, 0xdd21, 0xdd2b, 0xdd27, 0xdd29, + 0xdd2a, 0xdd2f, 0xdd23, 0x2295, 0x5cea, 0xdd28, 0x2f10, 0x5cb3, + 0xdd30, 0xdd2e, 0xdd33, 0xdd40, 0x2f10, 0x5cae, 0xdd30, 0xdd35, + 0xdd2c, 0x9e70, 0xdd37, 0xdd36, 0xdd39, 0xdd34, 0xdd3b, 0xdd38, + 0xdd3a, 0xdd32, 0xdd42, 0xdd41, 0xdd3f, 0xdd45, 0xdd44, 0xdd3e, + 0x2379, 0xb064, 0xdd3c, 0xc68e, 0x5d13, 0xdd43, 0x5ce4, 0xdd31, + 0xdd48, 0xdd4a, 0x2bbe, 0xdcd4, 0x2bbe, 0xdcd3, 0xdd47, 0xdd4a, + 0xdd52, 0xdd49, 0x5d0a, 0xdd5e, 0xdd50, 0xdd4f, 0xdd54, 0x4d9a, + 0x4e8c, 0xdd53, 0x5d12, 0xdd24, 0x2356, 0xa8f2, 0x5cce, 0xdd31, + 0xdd4b, 0xdd55, 0x2295, 0x5cad, 0xdd28, 0xdd4d, 0xdd26, 0xdd4c, + 0xa046, 0x5d56, 0xe83c, 0xdd57, 0x5d4d, 0xef4e, 0xdd5a, 0xdd59, + 0xdd2d, 0xdd5b, 0xdd5c, 0x3557, 0xdd25, 0xdd3d, 0xdd58, 0xdd5f, + 0xdd60, 0x5cdb, 0xdd5e, 0x2050, 0x5d17, 0xdd5d, 0xdd61, 0xdd62, + 0xdd46, 0x5ce2, 0xdd24, 0x5ccd, 0xdd43, 0xdd51, 0xdd4e, 0x2050, + 0x5d0b, 0xdd5d, 0xdd63, 0xdd43, 0x56fd, 0xdc9d, 0xdc9e, 0xdca0, + 0x2458, 0x24e1, 0xdc9f, 0xdca2, 0x321d, 0xdca1, 0xdcac, 0x5ce2, + 0xdd12, 0x3557, 0xdd01, 0xdcec, 0xdca8, 0x5cad, 0xdcea, 0xdca9, + 0xdcaa, 0xdca7, 0xdcb6, 0xdcfc, 0xdcaf, 0xdcab, 0x2f10, 0x5cae, + 0xdcb3, 0x5cce, 0xdce4, 0xdcc1, 0xdcb0, 0xdcbc, 0xdcb4, 0xdcba, + 0xdcb8, 0xdcbf, 0xdcbb, 0xdcc0, 0xdcbd, 0xdcca, 0xdd04, 0xdcc8, + 0xdcc4, 0xdcb2, 0xdcc3, 0xdcc2, 0x5ccd, 0x5d13, 0xdd1c, 0xdcc7, + 0xdcc5, 0xdd10, 0xdcd5, 0xdcd1, 0xdcda, 0x5cd2, 0xdcd6, 0xdce6, + 0xdced, 0x5ceb, 0x5cf7, 0xef4e, 0xdd16, 0xdcde, 0xdcdc, 0xdd14, + 0xdcd9, 0xdce1, 0xdce0, 0xdce7, 0x5cf4, 0xe83c, 0xdcf5, 0xdd05, + 0xdcfb, 0xdcfa, 0xdcfd, 0xdcfe, 0x2050, 0x5d0b, 0xdd17, 0x5b83, + 0x5b9a, 0x5cdb, 0xdd0a, 0xdd07, 0xdd08, 0xdd0d, 0xdd0f, 0xdd1b, + 0x407b, 0xc0fe, 0xdd6c, 0xdd6a, 0xdd71, 0xdd70, 0xdd99, 0xdd95, + 0x2c1f, 0x2c20, 0x6bae, 0x6c7b, 0xec9c, 0xdfdf, 0xdd82, 0xdd81, + 0xdda8, 0xdda6, 0xdd76, 0xdd75, 0xdd91, 0xdd8b, 0xde7a, 0x5dc3, + 0xde8d, 0xddb2, 0xddb1, 0xde89, 0xde38, 0x5daf, 0xde8d, 0xde4c, + 0xde92, 0xdff9, 0xddfa, 0xde29, 0xde10, 0xde82, 0xde7a, 0xde55, + 0xde9a, 0xdde5, 0xde8b, 0xac40, 0x50eb, 0xd11b, 0x458e, 0xc58f, + 0xde34, 0x511a, 0xd173, 0xde8a, 0xddf5, 0xde64, 0xddf4, 0xde64, + 0xc8b0, 0xde93, 0xde91, 0xcaac, 0xde0a, 0xddbb, 0xde4f, 0x5e79, + 0xdea2, 0xddc4, 0xde44, 0xdea1, 0xde63, 0xddf8, 0xdff9, 0xde52, + 0x5e28, 0xde2a, 0x5e8a, 0xde95, 0x5e4b, 0xdea2, 0x5dac, 0xddf7, + 0xdea5, 0xddf6, 0xde84, 0xde83, 0xa8b8, 0xddb8, 0x5e0c, 0x5e70, + 0xde95, 0x5dfb, 0xe6ae, 0x5daf, 0xddc3, 0xdeaa, 0xde2f, 0xddde, + 0xde2c, 0x5e70, 0xde8a, 0xdeaa, 0xddf9, 0xdea6, 0xde51, 0x5e4b, + 0xde79, 0xde7f, 0xde9c, 0x5e8f, 0xde99, 0xdeb3, 0xd03d, 0xdec0, + 0x1f53, 0x5ec6, 0x6ab5, 0xead4, 0xdeb2, 0xdeb1, 0xdeac, 0xdeaf, + 0x5040, 0x504c, 0xd077, 0x1f53, 0x5eb0, 0x6ab5, 0xead4, 0xdf66, + 0xdf67, 0xdf68, 0xa19b, 0xdf6a, 0xdf69, 0xdf6b, 0x3799, 0x5ef6, + 0xdf6d, 0xdf6f, 0x5f49, 0xdf6c, 0x5f5f, 0xdf70, 0xdf77, 0xdf78, + 0x5f29, 0xdf88, 0xdf71, 0x3799, 0x5edb, 0xdf6d, 0xdf74, 0xdf75, + 0xdf7a, 0xdf72, 0xdf76, 0x5f15, 0xdf7b, 0xdf7c, 0xdf5c, 0xdf83, + 0xdf82, 0xdf81, 0xdf80, 0xdf7d, 0xdf7e, 0x5f1b, 0xdf86, 0xdf36, + 0x5f19, 0xdf84, 0xb33d, 0x1fcc, 0xdf85, 0x5efd, 0xdf7b, 0x5f12, + 0xdf84, 0x5f0c, 0xdf86, 0x5f3a, 0xdf8e, 0xdf89, 0xdf8b, 0xdf8d, + 0xdf57, 0xdf8a, 0xdf87, 0x5ef0, 0xdf88, 0xdf6e, 0xdf8c, 0xdf6f, + 0xdf91, 0xdf8f, 0xdf0f, 0xdf93, 0x5f1c, 0xdf8e, 0xdf90, 0xdf92, + 0xdf97, 0xd206, 0x67b1, 0x67dc, 0xe7ec, 0xbbc2, 0x5f96, 0xe38b, + 0xdf95, 0xdf98, 0x5ee2, 0xdf6c, 0xdf99, 0xdf7f, 0xdf9a, 0xdf21, + 0xdf00, 0x5ee3, 0xdf70, 0xdf94, 0xdf79, 0xdf73, 0xdeca, 0xdecb, + 0xdecc, 0xded2, 0xded1, 0xded4, 0x5ee2, 0xdf49, 0x3799, 0x5edb, + 0xdef6, 0xdf2a, 0x5edf, 0xdf2d, 0x5ee3, 0xdf5f, 0xdef2, 0xdefb, + 0xdf64, 0xdef8, 0xdef9, 0xdefc, 0xdee4, 0xdeeb, 0xdf62, 0xdefa, + 0x5efd, 0xdf15, 0xdefe, 0xdf09, 0xdf0a, 0xdf4e, 0xdf08, 0xdf07, + 0xdf05, 0xdf03, 0x5f12, 0xdf19, 0xdf14, 0x5f0c, 0xdf1b, 0xdf26, + 0x5ef0, 0xdf29, 0xdf1d, 0xdf25, 0xdf1e, 0xdf2c, 0xdf1f, 0x5f1c, + 0xdf3a, 0xdf33, 0xdf3b, 0xdf2f, 0xdf3c, 0xdf38, 0xdf61, 0xdf45, + 0xdf44, 0xdf3e, 0xdf46, 0xdf4d, 0xdf54, 0x5f9e, 0x5fa4, 0xdfad, + 0x5f9d, 0x5fa4, 0xdfad, 0xe5e2, 0x3683, 0xcf6a, 0x2f01, 0x5fa9, + 0xdfaf, 0x5f9d, 0x5f9e, 0xdfad, 0xa29e, 0x2f01, 0xdfa8, 0x2f01, + 0xdfa7, 0x2f01, 0x5fa1, 0xdfaf, 0xdfae, 0x5f9d, 0x5f9e, 0xdfa4, + 0xdfab, 0x2f01, 0x5fa1, 0xdfa9, 0xa19c, 0xdfb6, 0xdfb5, 0x5fba, + 0x6089, 0xe08a, 0x5fb9, 0x6089, 0xe08a, 0xe07c, 0x6039, 0xe054, + 0xe077, 0xdfc3, 0xdfc2, 0xdfe4, 0xe04e, 0xe081, 0x231d, 0xae00, + 0xe04b, 0xe084, 0xe019, 0xe032, 0xe060, 0xe055, 0xe023, 0x5d7f, + 0x6045, 0xe072, 0xdfc6, 0xe008, 0xe087, 0xaef8, 0xaf80, 0xe003, + 0x2f84, 0x2f91, 0xe015, 0x26d8, 0x26de, 0x26ec, 0x2efb, 0x2efd, + 0xe025, 0x5de1, 0xde5f, 0x1e43, 0xaefc, 0xe069, 0xdfef, 0xdfe5, + 0xe078, 0xe05c, 0xe052, 0x6013, 0xe05e, 0x6012, 0xe05e, 0x2f84, + 0x2f91, 0xdff3, 0xdfd9, 0xdfde, 0x26d8, 0x26de, 0x26ec, 0x2efb, + 0x2efd, 0xdff4, 0xe090, 0xa954, 0x3e38, 0xe04a, 0xa468, 0xdfdb, + 0x5fbe, 0xe054, 0xe060, 0xe08f, 0xa06a, 0xe06f, 0x5fdf, 0xe072, + 0x1fa6, 0xa075, 0x3e38, 0xe030, 0xdfd0, 0xdfc7, 0xe00e, 0x2675, + 0x585c, 0xd85f, 0x5fbe, 0xe039, 0xdfdd, 0xe07a, 0xe065, 0xe00a, + 0x6012, 0xe013, 0x5fdc, 0xe03a, 0xbeaf, 0xe059, 0xe002, 0xe041, + 0x5fdf, 0xe045, 0xced5, 0xdfc1, 0xe009, 0xe057, 0xdfbd, 0xdfc8, + 0xdfd8, 0xdfe9, 0x5fb9, 0x5fba, 0xe08a, 0x5fb9, 0x5fba, 0xe089, + 0xe03b, 0xe026, 0xe61d, 0xe127, 0xe13a, 0xe0ab, 0xb751, 0xe0a6, + 0xe114, 0xe0f5, 0xe112, 0xe134, 0x23b8, 0x6130, 0xe6a3, 0xe0cc, + 0x3b1d, 0x6b30, 0xeb31, 0xe0bd, 0x60d2, 0xe0de, 0xe0df, 0xe136, + 0xe12d, 0x60ce, 0xe0de, 0xe106, 0x60ce, 0xe0d2, 0xe0cf, 0xe148, + 0xe116, 0xe0f6, 0xe0ae, 0xe0e8, 0x1e61, 0x6109, 0x610a, 0xe115, + 0xe132, 0xe0d3, 0x1e61, 0x60f7, 0x610a, 0xe115, 0x1e61, 0x60f7, + 0x6109, 0xe115, 0xe0b9, 0xe0ac, 0x1e61, 0x60f7, 0x6109, 0xe10a, + 0xe0e7, 0xe093, 0xe0d1, 0x23b8, 0x60bb, 0xe6a3, 0xe0f8, 0xe0ba, + 0xe0d0, 0xe146, 0xe09d, 0xe147, 0x2398, 0x28e5, 0xaedb, 0xe147, + 0xe137, 0x613c, 0xe142, 0xe0e6, 0x9e23, 0xe194, 0xe189, 0xb59f, + 0x6196, 0xe19e, 0xe18b, 0x467a, 0x6197, 0xe1b1, 0x616c, 0xe1bb, + 0xa5e0, 0x6167, 0xe1bb, 0x61a4, 0xe1ac, 0xe1c5, 0xe1c3, 0x61b8, + 0xe1c0, 0xd14c, 0xe195, 0xe154, 0xe91f, 0xe162, 0x24b8, 0xee79, + 0xe14b, 0xe187, 0x615d, 0xe19e, 0x467a, 0x6166, 0xe1b1, 0xb9bc, + 0x1e11, 0xeb57, 0x615d, 0xe196, 0x6171, 0xe1ac, 0x233b, 0xbbc9, + 0x6171, 0xe1a4, 0x467a, 0x6166, 0xe197, 0x617f, 0xe1c0, 0x6167, + 0xe16c, 0x2bb4, 0xdb8c, 0x617f, 0xe1b8, 0xd845, 0xe17e, 0xe17d, + 0x2bc0, 0xb3a1, 0x61ca, 0xe1cb, 0x61c8, 0xe1cb, 0x61c8, 0xe1ca, + 0x58cf, 0xd8e1, 0x27dc, 0xa8c4, 0xa398, 0x61d2, 0xe485, 0x61d1, + 0xe485, 0x61da, 0x61fb, 0xe486, 0xe487, 0xe48c, 0x2200, 0xa202, + 0xe48a, 0xe489, 0xe48b, 0x61d3, 0xe1fb, 0xe1e1, 0xe488, 0x1e71, + 0x9e82, 0xe1dc, 0x621f, 0xe493, 0xe490, 0xb263, 0xe48f, 0xe492, + 0xe2e9, 0x2251, 0x2263, 0x2271, 0x228d, 0x228e, 0x2292, 0x2294, + 0xe1fc, 0xe497, 0xe48d, 0xe495, 0xe48e, 0x61d3, 0x61da, 0xe486, + 0x2251, 0x2263, 0x2271, 0x228d, 0x228e, 0x2292, 0x2294, 0xe1f0, + 0xe4af, 0xe4ab, 0xe498, 0xe4ad, 0xe4a5, 0x625b, 0xe4c5, 0xe49a, + 0xe4a0, 0xe49d, 0x6264, 0xe4a9, 0xe4a4, 0xe4a3, 0xe491, 0xe49e, + 0xe4ae, 0x629e, 0xe4a7, 0xe1e3, 0xe49f, 0xe499, 0xe4ac, 0xe49b, + 0xe4aa, 0xe3ba, 0x4089, 0xe46a, 0x6438, 0xe4ce, 0x6268, 0xe4cc, + 0xe4c8, 0xe4b6, 0xe4c3, 0xe4b4, 0xe4b9, 0xe4cd, 0xe4b0, 0xe4b8, + 0xe4c0, 0xe4bf, 0xe4be, 0x6295, 0x62e8, 0x6421, 0x6435, 0xe4c1, + 0xe49c, 0xe4bb, 0xe4ca, 0xe4ca, 0xe4c9, 0x2228, 0xe4c7, 0xe4cb, + 0xe4c2, 0xe4b7, 0xe4b3, 0xe4c6, 0x6206, 0xe4c5, 0xe4ba, 0xe348, + 0x46cb, 0x4f3d, 0xe4b5, 0x620e, 0xe4a9, 0xe4b2, 0x622e, 0xe4cc, + 0xe4bc, 0xe4bd, 0x47ff, 0x483f, 0x4926, 0x62db, 0xe45b, 0x6373, + 0x6451, 0x6452, 0xe46c, 0xe4cf, 0xe4f0, 0xe4d2, 0xe4ec, 0xe4ea, + 0xe4f6, 0xe4f3, 0xe4dc, 0xe4da, 0xe4e3, 0xe4e8, 0x6244, 0x62e8, + 0x6421, 0xe435, 0xe4e2, 0xe4ed, 0x6443, 0xe4eb, 0x62bd, 0xe4e6, + 0x2563, 0x5854, 0xd858, 0xe21e, 0xe4d1, 0xe4f7, 0xe4f1, 0xe4df, + 0xe4f5, 0xe4e5, 0xe4d5, 0xe4ef, 0xe4d0, 0x6322, 0xe4b1, 0xe47e, + 0xe4de, 0xc10a, 0x62ed, 0xe510, 0x4107, 0xe500, 0xe508, 0xe511, + 0xe509, 0xe29b, 0xe4dd, 0xe512, 0xe50c, 0xe4a1, 0xe4e4, 0xe4d7, + 0xe50b, 0xe4fb, 0x47ff, 0x483f, 0x4926, 0x6271, 0xe45b, 0xe50a, + 0x646f, 0xe513, 0x6381, 0xe4d8, 0xe504, 0xe503, 0xe514, 0x6244, + 0x6295, 0x6421, 0x6435, 0xe507, 0x61ef, 0xe4d3, 0x5216, 0x5217, + 0xe4fa, 0x62b3, 0xe510, 0xe4d6, 0xe506, 0xe502, 0xe4fd, 0x6444, + 0xe4f8, 0xe50d, 0xe52f, 0xe4a2, 0xe51e, 0x2f55, 0xe332, 0xe516, + 0xe52b, 0xe529, 0x641a, 0xe4d4, 0xe525, 0xe515, 0xe51f, 0xe524, + 0x637f, 0xe531, 0xe4ee, 0xe51b, 0xe52c, 0xe52d, 0xe51c, 0x62ad, + 0xe4b1, 0xe526, 0xe51a, 0xe520, 0xe521, 0x40bc, 0x4149, 0xe34a, + 0xe522, 0xe519, 0x2f55, 0xe304, 0xe530, 0xd868, 0xe486, 0xe4fc, + 0xe3e8, 0xe51d, 0xe528, 0xe52a, 0xe494, 0xe534, 0x6260, 0xe533, + 0x40bc, 0x4149, 0xe32c, 0xe505, 0xe540, 0xe537, 0xe4e1, 0xe496, + 0x4145, 0xe53b, 0xe4ff, 0x6445, 0xe53d, 0xe538, 0xe532, 0xe518, + 0xe539, 0x63d3, 0xe52a, 0xe53e, 0x6274, 0x6451, 0x6452, 0xe46c, + 0xe52e, 0xe536, 0xe517, 0x649f, 0xe53a, 0xe319, 0xe2e3, 0xe541, + 0xe53f, 0xe545, 0xe551, 0xdf44, 0x642e, 0xe570, 0x39c8, 0xd028, + 0x3eb6, 0xc194, 0x63c1, 0xe501, 0xb7aa, 0xe549, 0xe524, 0xe548, + 0x6543, 0xef12, 0xe4a8, 0xd4e5, 0x6402, 0xe54f, 0xe4e0, 0xe4e9, + 0xe53c, 0xe550, 0x63ae, 0xe547, 0x63ad, 0xe547, 0xe552, 0xe54d, + 0xe553, 0xe54c, 0xe228, 0xe54e, 0xe396, 0xe55e, 0xe55f, 0xe4fe, + 0xe546, 0xe559, 0xe560, 0xe55d, 0xe36f, 0xe4ff, 0xe535, 0xe557, + 0xe558, 0xe55b, 0x222c, 0x2257, 0x2277, 0xe4f2, 0x434d, 0xe55c, + 0xe556, 0xe542, 0x63fd, 0xe508, 0xe33e, 0xe55a, 0xe4e7, 0xe564, + 0xe56a, 0x63e5, 0xe508, 0x63a6, 0xe54f, 0xe4d9, 0xe4f4, 0xe563, + 0xe4f9, 0xe566, 0xe561, 0xe50f, 0xe49f, 0xe56b, 0x630f, 0xe4d4, + 0x6481, 0xe562, 0xe568, 0x6244, 0x6295, 0x62e8, 0x6435, 0xe4c1, + 0xe50e, 0xe50f, 0xe544, 0xe54c, 0x638c, 0xe570, 0xe56f, 0xe56d, + 0x6244, 0x6295, 0x62e8, 0x6421, 0xe4c1, 0xe56e, 0x622c, 0xe4ce, + 0xe4db, 0xe571, 0x629a, 0xe4eb, 0x62f3, 0xe4f8, 0xe360, 0xe56c, + 0xe554, 0x6274, 0x6373, 0x6452, 0xe46c, 0x6274, 0x6373, 0x6451, + 0xe46c, 0xb7aa, 0xe572, 0xe527, 0x647d, 0xe4bb, 0x47ff, 0x483f, + 0x4926, 0x6271, 0xe2db, 0x6909, 0xe95f, 0xe574, 0xe4c4, 0xe573, + 0xa228, 0xe565, 0x4089, 0xe229, 0x6274, 0x6373, 0x6451, 0xe452, + 0xe567, 0xe2df, 0xe4a5, 0xe575, 0xe576, 0x4f36, 0xcf50, 0xe54a, + 0xe569, 0xe523, 0x645a, 0xe4bb, 0xe2ae, 0xa1ff, 0x641d, 0xe562, + 0xe54b, 0x61d1, 0xe1d2, 0x61d3, 0x61fb, 0xe337, 0xe1d4, 0xe1dd, + 0xe1d8, 0xe1d7, 0xe1d9, 0xe1d5, 0xe1f7, 0xe1fa, 0xe1e7, 0xe1e4, + 0xe212, 0xe1e9, 0xe1e3, 0xe346, 0xe1f9, 0xe35a, 0xe1f5, 0xe203, + 0xe223, 0xe208, 0xe226, 0xe245, 0xe20d, 0xe214, 0x6221, 0x637e, + 0x6418, 0xe53a, 0xe209, 0xe2c7, 0xe2fc, 0xe211, 0xe210, 0x6205, + 0xe470, 0xbb3d, 0xe21e, 0xe3a2, 0x620e, 0xe264, 0xe227, 0xe201, + 0xe225, 0xe204, 0xe215, 0xe200, 0xe23a, 0x62ad, 0xe322, 0xe266, + 0xe257, 0xe237, 0x46cb, 0x4f3d, 0xe262, 0xe233, 0xe255, 0xe23d, + 0xe238, 0xe25e, 0x6246, 0x645a, 0xe47d, 0xe26c, 0xe26d, 0xe240, + 0xe23f, 0xe23e, 0x6244, 0x6421, 0xe435, 0xe251, 0xe234, 0xe460, + 0x6206, 0xe25b, 0xe25a, 0x2228, 0xe24b, 0xe230, 0xe249, 0x6247, + 0xe248, 0xe24d, 0x622e, 0xe268, 0xe239, 0x622c, 0xe438, 0xe276, + 0xe2ac, 0xe2a0, 0xe27a, 0xe2e9, 0x630f, 0xe41a, 0xe2aa, 0xe2ee, + 0xe2cf, 0xe2e3, 0xe403, 0xe28d, 0xe43a, 0xe285, 0xe2c1, 0xe2b1, + 0xe2a6, 0xe3a7, 0xe358, 0xe296, 0xe291, 0xe2cc, 0xe2a9, 0xe29b, + 0xe3f5, 0xe293, 0xe3a9, 0xe27f, 0x629a, 0xe443, 0xe27b, 0xe298, + 0xe31a, 0xe2ab, 0xe278, 0xe2a5, 0x222c, 0x2257, 0x2277, 0xe3df, + 0xe283, 0xe40b, 0xe2a8, 0xe280, 0xe2a3, 0x62f3, 0xe444, 0xe412, + 0x5216, 0x5217, 0xe2ea, 0xe2d9, 0xe338, 0xe2f1, 0xe3c8, 0x635e, + 0xe3d7, 0xe2b7, 0xe396, 0xe2f0, 0xe2e5, 0x5021, 0xe2e4, 0xe34b, + 0xe2ef, 0xe2e8, 0x62b9, 0x63e5, 0xe3fd, 0xe2bc, 0xe2dd, 0xe2d2, + 0xe2c5, 0xe2f6, 0xe426, 0x6417, 0xe427, 0x62b3, 0xe2ed, 0xe2bb, + 0xe2c3, 0xe2df, 0xe2e6, 0xe312, 0xe306, 0xe37a, 0xe369, 0xe32f, + 0xe328, 0xe31b, 0xe321, 0xe340, 0xe301, 0xe315, 0xe329, 0xe32b, + 0xe32e, 0xe47c, 0x6318, 0xe39a, 0xe310, 0xe326, 0xe455, 0xe341, + 0xe308, 0x6343, 0xe36f, 0xe307, 0xe31f, 0xe320, 0xe375, 0xe2f8, + 0xe333, 0xe319, 0xe365, 0xe348, 0xe347, 0xe3d8, 0xe376, 0xe354, + 0xe364, 0xe36c, 0x637e, 0xe49f, 0xe35b, 0xe3aa, 0xe360, 0xe370, + 0xe384, 0xe34d, 0xe382, 0xe3e4, 0xe3a1, 0xe428, 0xe387, 0xe3cc, + 0x63ad, 0xe3ae, 0xe39b, 0xe398, 0xe477, 0xe482, 0x63b8, 0xe42b, + 0xe3b3, 0xe3bf, 0x63a6, 0xe402, 0xe3ac, 0xe38a, 0xe3b0, 0xe3b5, + 0xe44c, 0xe3e2, 0xe3dc, 0xe3dd, 0xe3cd, 0xe3f0, 0xe3de, 0xe3e1, + 0xe3d1, 0xe3c3, 0xe3c7, 0xe3d0, 0xe414, 0x641d, 0xe481, 0xe410, + 0xe3f7, 0xe465, 0xe413, 0xe46d, 0xe420, 0xe479, 0xe3f9, 0xe419, + 0xe44a, 0xe433, 0xe436, 0xe432, 0x638c, 0xe42e, 0xe43f, 0xe454, + 0xe463, 0xe45e, 0xe471, 0xe472, 0x1ee7, 0x214f, 0x6578, 0xe57f, + 0x1ee7, 0x214f, 0x6577, 0xe57f, 0x1e45, 0x9e46, 0x1ee7, 0x214f, + 0x6577, 0xe578, 0xe5e8, 0xe5e9, 0xe5ea, 0xe5eb, 0x6589, 0xe5ed, + 0xe5ec, 0x6587, 0xe5ed, 0xaf00, 0xe5f6, 0xe5f3, 0x65a0, 0xe5f0, + 0x6592, 0xe5f2, 0x6591, 0xe5f2, 0xe5f4, 0xe5f5, 0xe5f8, 0x65f9, + 0xeb27, 0x658f, 0xe5f0, 0xe602, 0x2173, 0x65d7, 0xe5dc, 0xe601, + 0xa408, 0xe600, 0xa4c4, 0xe5fa, 0xe5fd, 0xe603, 0xe606, 0xe5fe, + 0x65b2, 0xe605, 0x65b1, 0xe605, 0x65c3, 0xe612, 0xe60a, 0x2266, + 0xe609, 0xe60e, 0xe60f, 0xe60d, 0xe608, 0xe60c, 0x65b4, 0xe612, + 0xb77f, 0xb697, 0xe5f1, 0x3ff6, 0xe614, 0xe615, 0xe611, 0xe607, + 0xe617, 0xe618, 0xe5ff, 0xe616, 0xe619, 0xe5ef, 0x2173, 0x65a2, + 0xe5dc, 0x3597, 0x6b25, 0x6b26, 0x6b2a, 0xeb2d, 0x242f, 0x2518, + 0x2553, 0x2554, 0x255f, 0xdaec, 0x2173, 0x65a2, 0xe5d7, 0xe61a, + 0xe613, 0xe610, 0xdf9f, 0xe61b, 0xe5fc, 0xe580, 0xe582, 0xe583, + 0xe586, 0xe588, 0x6587, 0xe589, 0xa54f, 0xe5d6, 0x658f, 0xe5a0, + 0xe5c8, 0x6591, 0xe592, 0xe58e, 0xe593, 0xe594, 0xe58c, 0xb0b6, + 0xe598, 0x6599, 0xeb27, 0xe5a8, 0xd05e, 0xe5e5, 0xe5a9, 0xe5ad, + 0xe5d3, 0xe5a5, 0xe5a3, 0xe5a1, 0xe5ab, 0xeb2e, 0x65b1, 0xe5b2, + 0xe5ac, 0xe5cd, 0xe5be, 0x2266, 0xe5b9, 0xe5b6, 0xeb29, 0xe5bf, + 0xe5bd, 0xe5bb, 0xe5bc, 0xe5e1, 0xe5cc, 0x65b4, 0xe5c3, 0xe5e0, + 0x3ff6, 0xe5ca, 0xe5cb, 0xe5d4, 0xe5d0, 0xe5d2, 0xe5d5, 0x65de, + 0xeb2b, 0xe5e4, 0xe61d, 0x6091, 0xe61c, 0xe68a, 0x1f8c, 0x6634, + 0x6670, 0xe682, 0x6633, 0xe67d, 0xe638, 0x2347, 0xe65e, 0x2742, + 0xac85, 0x274f, 0xa76f, 0xa751, 0xa740, 0xca7d, 0x6626, 0xe67d, + 0x1f8c, 0x6625, 0x6670, 0xe682, 0xe663, 0x2826, 0xe68e, 0xe628, + 0xbcae, 0x2768, 0xe641, 0x2768, 0xe640, 0xe69b, 0xe678, 0xe6b4, + 0xe673, 0xe658, 0xa905, 0x665c, 0x665d, 0xe67f, 0xa7c8, 0xe649, + 0x6655, 0xe67f, 0xe655, 0x2347, 0xe629, 0xaf8f, 0x2866, 0xe635, + 0xe677, 0x2c9b, 0x2cf6, 0x2d8b, 0x2d8c, 0x2db9, 0x669d, 0xe6af, + 0xe695, 0x4906, 0x667a, 0xe6aa, 0x1f8c, 0x6625, 0x6634, 0xe682, + 0xe648, 0xe665, 0xe646, 0x4906, 0x6669, 0xe6aa, 0x2794, 0xa819, + 0x6626, 0xe633, 0x6655, 0xe65c, 0x2830, 0xa895, 0x1f8c, 0x6625, + 0x6634, 0xe670, 0x27de, 0xa824, 0xe61f, 0xb697, 0x2826, 0xe636, + 0xe6a8, 0x1e5a, 0x66a0, 0xe6b1, 0x48d2, 0xe668, 0xa75e, 0xe69f, + 0xe645, 0x2c9b, 0x2cf6, 0x2d8b, 0x2d8c, 0x2db9, 0x6666, 0xe6af, + 0xe699, 0x1e5a, 0x6690, 0xe6b1, 0x23b8, 0x60bb, 0xe130, 0xe68f, + 0x4906, 0x6669, 0xe67a, 0x275f, 0xa8b3, 0xde8b, 0x2c9b, 0x2cf6, + 0x2d8b, 0x2d8c, 0x2db9, 0x6666, 0xe69d, 0x1e5a, 0x6690, 0xe6a0, + 0xea98, 0xe647, 0x66b7, 0xe6b8, 0x66b6, 0xe6b8, 0x66b6, 0xe6b7, + 0x2bc9, 0x674d, 0x674e, 0x674f, 0x6db4, 0x6e16, 0xee64, 0xa3ea, + 0xe6cb, 0xe6e3, 0x6ceb, 0xed08, 0x20f1, 0xecf8, 0xe6bd, 0xe6dd, + 0xe6db, 0x3742, 0xe6dc, 0x2f6b, 0x4431, 0xed70, 0xd67d, 0xa3cc, + 0xee1b, 0x66cf, 0xedb5, 0x3742, 0xe6d1, 0xe6cd, 0x6d8f, 0x6dc4, + 0xee21, 0xadb2, 0x5b8e, 0xdb90, 0xc9bb, 0xe6be, 0xbc1b, 0x9e91, + 0xe742, 0xe717, 0xe741, 0x671a, 0xe727, 0xc535, 0x671a, 0xe727, + 0xe73d, 0xeef4, 0x4075, 0x671b, 0xe748, 0xbcbe, 0xe6f6, 0x66fa, + 0x66fe, 0xe727, 0x4075, 0x670a, 0xe748, 0xe722, 0xe721, 0x66fa, + 0x66fe, 0xe71a, 0xe744, 0xd987, 0x1e30, 0x5c4a, 0x5c50, 0xe74a, + 0xe701, 0xe6f7, 0xe6f3, 0xe72d, 0xa3c7, 0x4075, 0x670a, 0xe71b, + 0xa3c6, 0x1e30, 0x5c4a, 0x5c50, 0xe73b, 0x2bc9, 0x66ba, 0x674e, + 0x674f, 0x6db4, 0x6e16, 0xee64, 0x2bc9, 0x66ba, 0x674d, 0x674f, + 0x6db4, 0x6e16, 0xee64, 0x2bc9, 0x66ba, 0x674d, 0x674e, 0x6db4, + 0x6e16, 0xee64, 0x2bc8, 0xe752, 0x2bc8, 0xe751, 0xe75a, 0x2172, + 0x2929, 0xe75d, 0xe75c, 0xe753, 0xe759, 0x2172, 0x2929, 0xe754, + 0x4cc6, 0x6763, 0x6eaa, 0x6eab, 0x6eb5, 0xeeba, 0xe762, 0x45b1, + 0xc6b0, 0xe768, 0xe82e, 0xe765, 0x676d, 0xe771, 0x676b, 0x6771, + 0xe7e7, 0x676b, 0x676d, 0xe7e7, 0xe7be, 0xcd46, 0x6789, 0xef17, + 0x6780, 0xef17, 0xe7b5, 0xe78d, 0xe78c, 0xade9, 0xe7c3, 0xe7bd, + 0xe7b9, 0x49cb, 0xe7a7, 0x49cb, 0xe7a6, 0xc89f, 0xe7c9, 0x5f41, + 0xe7dc, 0xe7dd, 0xe78b, 0xe79f, 0xe792, 0xe774, 0x4e6e, 0xcf30, + 0xe791, 0xa343, 0x589c, 0xe7e4, 0xe7af, 0xe7e6, 0xe7e7, 0x2dff, + 0xe7e8, 0xe7e9, 0xe7ea, 0x5f41, 0x67b1, 0xe7ec, 0xe7b2, 0xe7eb, + 0x589c, 0xe7c8, 0xe7cb, 0x676d, 0x6771, 0xe7cc, 0x2dff, 0xe7cd, + 0xe7d3, 0xe7d9, 0xe7de, 0x5f41, 0xe7dc, 0xe7ee, 0xe7ed, 0xe7f1, + 0xe7ef, 0x6f4f, 0xef51, 0xe7fb, 0xe7f5, 0xa4cd, 0xe875, 0xe876, + 0xe877, 0xe879, 0xe87a, 0xe878, 0xe87b, 0xe87c, 0xe882, 0xe880, + 0xe883, 0xe884, 0xe87d, 0xe881, 0xe87f, 0xe887, 0xe886, 0x6838, + 0xe888, 0xe88c, 0xe889, 0x6825, 0xe890, 0x6824, 0xe890, 0xe88f, + 0x6830, 0xe88a, 0xa934, 0x6767, 0xe892, 0x682c, 0xe88a, 0xe88b, + 0x4a4e, 0xe896, 0xe894, 0x681a, 0xe888, 0x4a68, 0x683a, 0x683d, + 0xe893, 0x4a68, 0x6839, 0x683d, 0xe893, 0xe891, 0x5cf4, 0xdd56, + 0x4a68, 0x6839, 0x683a, 0xe893, 0xeaed, 0xe897, 0xd16e, 0xe898, + 0xe89d, 0xe89a, 0x6854, 0xe89c, 0xe899, 0xe89b, 0x684f, 0xe89c, + 0x363e, 0xe86f, 0xa6df, 0xb13f, 0xe8a1, 0x685b, 0xe8a0, 0x685a, + 0xe8a0, 0xcc7b, 0xe89f, 0xe8a2, 0xe87e, 0xe8a4, 0xe8a5, 0x363e, + 0xe855, 0xe8a6, 0x6885, 0x6ad7, 0xee15, 0xe89e, 0xe8a7, 0xe801, + 0xe802, 0xe803, 0xe807, 0xe805, 0xe806, 0x6808, 0xeb1a, 0xe80a, + 0xe811, 0xe867, 0xe813, 0xe80e, 0xe812, 0xe80c, 0xe80f, 0xe810, + 0x6871, 0xead7, 0xe818, 0xe817, 0x681a, 0xe838, 0xe821, 0x682c, + 0xe830, 0xe832, 0xe81c, 0xbf41, 0xc1b2, 0xe826, 0x6824, 0xe825, + 0xe83b, 0xe82e, 0x4a68, 0x6839, 0x683a, 0xe83d, 0xe837, 0x4a4e, + 0xe834, 0xe846, 0xe84c, 0xe852, 0xe84e, 0xe853, 0x684f, 0xe854, + 0xe84d, 0xe873, 0xe862, 0x685a, 0xe85b, 0xe859, 0xe865, 0xce87, + 0xe86b, 0xe86c, 0xe870, 0xe874, 0x1e30, 0x21e8, 0x21ec, 0x21ee, + 0x5af7, 0x5bbd, 0x68cc, 0xe8ce, 0xe8d0, 0x68b7, 0x68c6, 0x68c8, + 0xe8d1, 0xe8d2, 0xa3f0, 0xa22e, 0xe8d3, 0x68ae, 0x68c6, 0xe8c8, + 0xe8d4, 0xe8cf, 0xe8d6, 0xe8d5, 0xe8d7, 0x68c4, 0xe8d8, 0x68c3, + 0xe8d8, 0x68ae, 0x68b7, 0x68c7, 0x68c8, 0xe8d9, 0xe8c6, 0x68ae, + 0x68b7, 0x68c6, 0xe8da, 0x21e8, 0x21ec, 0x21ee, 0x68a8, 0xe8ce, + 0x1e30, 0x21e8, 0x21ec, 0x21ee, 0x68a8, 0xe8cc, 0xe8ba, 0xe8ad, + 0xe8ae, 0xe8af, 0xe8b6, 0xe8b8, 0xe8bc, 0xe8bb, 0xe8c0, 0x68c3, + 0xe8c4, 0xe8c6, 0xe8c8, 0xe8de, 0xcffb, 0xe8db, 0x25b0, 0x68e0, + 0xe963, 0x25b0, 0x68df, 0xe963, 0xe910, 0xe965, 0xe964, 0xe966, + 0xe957, 0xe968, 0xe96a, 0x49d7, 0xe96b, 0xe90a, 0xe96c, 0x68f2, + 0xe96e, 0x68f0, 0xe96d, 0xe8ef, 0x68ee, 0xe96e, 0xe974, 0xe99d, + 0xe972, 0xe971, 0xe970, 0xe973, 0xe97a, 0xe978, 0x6920, 0xe97c, + 0x645c, 0x695f, 0xe977, 0x217b, 0x4faa, 0xe8ec, 0xe975, 0xe95c, + 0xe979, 0xe97b, 0xe8e1, 0xe97d, 0x6927, 0xe981, 0xe97f, 0xe982, + 0xe97e, 0x1f59, 0xe980, 0xd0b4, 0xe984, 0xe983, 0xe96f, 0xe18a, + 0x6905, 0xe97c, 0xe985, 0x2582, 0x6912, 0x6935, 0xe981, 0x5218, + 0xe986, 0xccca, 0xccc7, 0xe967, 0xe959, 0x2582, 0xe927, 0xe989, + 0xe987, 0xe967, 0xe98e, 0xccd5, 0xe969, 0xe988, 0xe98f, 0xe98a, + 0xe98c, 0xe98d, 0xe992, 0xe990, 0xe991, 0xe993, 0xe988, 0xe994, + 0xd1b3, 0xcce6, 0xe965, 0xe976, 0xe8e8, 0xe934, 0xe90d, 0xe98b, + 0x645c, 0x6909, 0xe977, 0xe995, 0x25b0, 0x68df, 0xe8e0, 0xe8e3, + 0x68e2, 0xe951, 0xe8e5, 0x6933, 0xe939, 0xe8e9, 0xe93c, 0xe8ea, + 0xe8eb, 0xe8ed, 0xe8ef, 0x68ee, 0xe8f2, 0xe91e, 0xe8fe, 0xe8fd, + 0xe8fc, 0xe8ff, 0xe8f4, 0xe90c, 0xe952, 0x6909, 0xe95f, 0xe904, + 0xe90e, 0xe903, 0xe90f, 0x6905, 0xe920, 0xe911, 0xe916, 0xe913, + 0x1f59, 0xe918, 0x6912, 0xe927, 0xe915, 0xe91c, 0xe91b, 0xe921, + 0xe928, 0xe937, 0x693d, 0xe94b, 0xe936, 0xe93f, 0xe95e, 0xe941, + 0xe943, 0xe93a, 0xe93e, 0xe948, 0xe949, 0xe945, 0xe94a, 0xe94c, + 0xe962, 0xe8f6, 0xe99f, 0xe99e, 0xea6c, 0xea6d, 0xa1af, 0x69c4, + 0xea6e, 0xea5d, 0xea70, 0xea6f, 0xea72, 0xce36, 0x6a62, 0xea74, + 0xea73, 0x69b1, 0xea6e, 0x6a5b, 0xea7f, 0x357a, 0x69c8, 0x6a45, + 0xea71, 0x357a, 0x69c6, 0x6a45, 0xea71, 0xea7b, 0xea7d, 0xea79, + 0xea75, 0xea7e, 0xea80, 0xea78, 0xea76, 0x69de, 0xea7c, 0x69dd, + 0xea7c, 0xea77, 0x208c, 0x4f75, 0xea82, 0xea88, 0xea87, 0xea73, + 0xea83, 0xea86, 0x6a2e, 0xea51, 0xea8e, 0xea8f, 0xea8b, 0xea8d, + 0xea93, 0xea92, 0xea91, 0xea90, 0x6a13, 0x6a57, 0xea8c, 0x6a37, + 0xea9a, 0x6a10, 0x6a57, 0xea8c, 0xea9b, 0xea97, 0xea99, 0xea52, + 0xea9e, 0xea98, 0x69f5, 0x6a51, 0xea9d, 0xd17e, 0xea7a, 0x6a12, + 0xea9a, 0xea9f, 0xea47, 0xeaa1, 0xd4e6, 0xea9c, 0xea96, 0xeaa0, + 0xeaa2, 0x357a, 0x69c6, 0x69c8, 0xea71, 0xea3a, 0xea85, 0xea95, + 0xea81, 0xeaa3, 0x69f5, 0x6a2e, 0xea9d, 0xea28, 0xea84, 0x6a10, + 0x6a13, 0xea8c, 0xb0ca, 0x69c5, 0xea7f, 0xe9b2, 0xeaa4, 0x69bf, + 0xea74, 0xeaa7, 0x560e, 0xeaa5, 0xeaa6, 0xbb22, 0xea8a, 0xea89, + 0xe9ac, 0xe9ad, 0x69b1, 0xe9c4, 0xe9b4, 0xe9b3, 0x357a, 0x69c6, + 0x69c8, 0xea45, 0xe9b9, 0x69c1, 0xe9ee, 0x69bf, 0xea62, 0xe9d4, + 0xe9db, 0xe9df, 0xe9d9, 0xe9d2, 0xea36, 0xe9d0, 0x69dd, 0xe9de, + 0xe9d1, 0xe9d5, 0x69c5, 0xea5b, 0xe9d8, 0xea4d, 0x208c, 0x4f75, + 0xe9e1, 0xe9f0, 0xea55, 0xea4a, 0xe9f1, 0xe9ed, 0xe9e2, 0xea6b, + 0xea6a, 0xea01, 0x6a10, 0x6a13, 0xea57, 0xea02, 0xe9f8, 0xe9ff, + 0xea0f, 0xea0e, 0xea0d, 0xea05, 0xea4c, 0xea42, 0xea19, 0x66b2, + 0xea2d, 0xea24, 0x6a12, 0xea37, 0xea16, 0xea41, 0x6a2e, 0xea51, + 0xea2b, 0xea38, 0xea43, 0xea3e, 0xea44, 0xea4f, 0xea5f, 0x560e, + 0xea65, 0xea66, 0xea64, 0xd0ae, 0x1f53, 0x5eb0, 0x5ec6, 0xead4, + 0xeca0, 0x51b8, 0xead3, 0xeacf, 0xd180, 0xead6, 0xead5, 0xeac5, + 0xd10f, 0x51b8, 0xeac4, 0x1f53, 0x5eb0, 0x5ec6, 0xeab5, 0x51cf, + 0xeacc, 0xeacb, 0x6871, 0x6885, 0xee15, 0xead9, 0xead8, 0x1eff, + 0xaf77, 0xeaf9, 0xeaef, 0x6b02, 0xeb22, 0x23d1, 0xeaee, 0xe83e, + 0x23d1, 0xeaea, 0xeae5, 0x1f5b, 0xaf7f, 0xeae4, 0xa243, 0x6ae9, + 0x6b13, 0xeb22, 0xb77e, 0xd0e1, 0x6b02, 0xeb22, 0xe87b, 0xeb23, + 0x6ae9, 0x6b02, 0xeb13, 0xeb1b, 0x3597, 0x65d8, 0x6b26, 0x6b2a, + 0xeb2d, 0x3597, 0x65d8, 0x6b25, 0x6b2a, 0xeb2d, 0x6599, 0xe5f9, + 0xa4c4, 0xe60b, 0x3597, 0x65d8, 0x6b25, 0x6b26, 0xeb2d, 0xe61a, + 0x3597, 0x65d8, 0x6b25, 0x6b26, 0xeb2a, 0xe604, 0x3b1d, 0x60c1, + 0xeb31, 0x3b1d, 0x60c1, 0xeb30, 0xeb39, 0xeb36, 0x1ffc, 0xcca5, + 0xac2c, 0xeb58, 0xeb4e, 0x573d, 0xeb49, 0x21f2, 0x2c32, 0x2c34, + 0x2c36, 0xac37, 0x1e11, 0xe19c, 0xeb47, 0xec7c, 0xec7d, 0xec7e, + 0xec6e, 0xebbb, 0xec80, 0xeeff, 0xec81, 0x6c78, 0xec88, 0xec24, + 0xec82, 0xec7f, 0xec84, 0xec85, 0xec86, 0x6bdb, 0xecb7, 0xec8c, + 0xec89, 0xec8f, 0xec87, 0xebf9, 0xec90, 0xec8d, 0xec8b, 0xec8a, + 0xec92, 0xec98, 0x6bd7, 0x6c76, 0xec9e, 0xec95, 0xec96, 0x6bb7, + 0xebf7, 0xec94, 0xec9b, 0xec91, 0x2c1f, 0x2c20, 0x5d7b, 0x6c7b, + 0xec9c, 0xec93, 0xecaa, 0x6ba7, 0xebf7, 0xec9d, 0xeb66, 0xebd8, + 0xeca7, 0xeca0, 0x6c00, 0xeca9, 0xeca4, 0x6bcb, 0xeca8, 0xebca, + 0xecac, 0xecbb, 0xecaf, 0xecad, 0x6b9d, 0xec76, 0xebbe, 0x6b89, + 0xecb7, 0xecb4, 0xecb1, 0xecb5, 0xecb2, 0xecb3, 0xecb8, 0xecae, + 0xecb0, 0xecb6, 0xecba, 0xec3a, 0x6ba7, 0x6bb7, 0xecc0, 0xeb8f, + 0xecab, 0xecca, 0x6bc7, 0xeca9, 0xecc8, 0xec97, 0xecc2, 0x6c28, + 0xecbd, 0xecc7, 0x6c0d, 0xecc5, 0x6c0c, 0xecc5, 0xecbe, 0x6c77, + 0xecc4, 0xecc6, 0xecc3, 0x6c2e, 0xecc1, 0xecd2, 0xecd1, 0xeccb, + 0xeca5, 0xeb73, 0x6c5e, 0xeccf, 0x6c08, 0xecce, 0xecd0, 0xeccd, + 0xec1b, 0xeca2, 0x6ccc, 0xef07, 0xecd3, 0xecd8, 0xeca6, 0xeca3, + 0x6bf5, 0xecb9, 0xecd7, 0xecdb, 0xecd4, 0xecc9, 0xecd9, 0xecd5, + 0x6cd6, 0x6f08, 0xef9e, 0xecdf, 0xecdd, 0xecdd, 0xecdc, 0xecde, + 0xec9f, 0xecbc, 0xec25, 0xec8e, 0xec99, 0xece3, 0xece1, 0xece2, + 0xecbf, 0xec9a, 0xeb63, 0xece0, 0x6b9d, 0x6bd7, 0xec9e, 0x6c10, + 0xecc4, 0x6b72, 0xec88, 0xeca1, 0x2c1f, 0x2c20, 0x5d7b, 0x6bae, + 0xec9c, 0xeb5a, 0xeb5b, 0xeb62, 0xeb77, 0xeb68, 0xeb6f, 0xeb74, + 0xeb7a, 0xeb81, 0xeb83, 0xeb8e, 0x6b72, 0xec78, 0xeb8b, 0xeb93, + 0xeb92, 0xeb8a, 0x56ab, 0xeb91, 0xec5f, 0xeb8d, 0xeb90, 0xebad, + 0xeb9a, 0xebb3, 0xebaa, 0xeb9e, 0xeba6, 0xec02, 0xeb9c, 0xec60, + 0xec6d, 0xebab, 0x2c1f, 0x2c20, 0x5d7b, 0x6bae, 0xec7b, 0xebba, + 0x6b9d, 0xec76, 0xec58, 0x6abe, 0xebc1, 0xec7a, 0xec31, 0xec39, + 0xebc9, 0xec23, 0xec37, 0xebc0, 0xebca, 0x6bc7, 0xec00, 0xebb6, + 0xebfd, 0xebd2, 0xebd6, 0xebea, 0xebd5, 0xebeb, 0xebe1, 0xebe4, + 0xebe7, 0xebdd, 0xebe2, 0xebf0, 0x6b89, 0xebdb, 0xebe8, 0xec3a, + 0xebf4, 0xebd4, 0xec5d, 0xec08, 0xec0f, 0xec68, 0xebf7, 0xec1b, + 0xec03, 0xec13, 0x6c10, 0xec77, 0x6c0c, 0xec0d, 0xec12, 0xec09, + 0xec01, 0xec42, 0xebff, 0xec20, 0x6c32, 0xef07, 0xec2d, 0xec28, + 0xec25, 0xec29, 0xec1f, 0xec1c, 0xec33, 0xec3e, 0x51a4, 0xec48, + 0x6c49, 0xef08, 0xec3b, 0xec35, 0xec45, 0xec3c, 0xec56, 0x6c53, + 0xec54, 0xec57, 0xec52, 0xec6f, 0xec64, 0xec67, 0xec63, 0x2c4c, + 0xee1f, 0x21eb, 0xecec, 0xee20, 0x66c1, 0xed08, 0xece7, 0xee24, + 0xa1e4, 0xee23, 0xee22, 0xe6c7, 0xee29, 0xee28, 0x66c1, 0xeceb, + 0x6d76, 0xee26, 0x6dd7, 0xee25, 0xee30, 0xee35, 0xee33, 0x6e1c, + 0xee32, 0xee2e, 0x6d44, 0xee31, 0xee2a, 0xee2f, 0xee2d, 0x53ba, + 0xedaf, 0xee38, 0xee39, 0xedc3, 0xee3b, 0xee3f, 0xedfa, 0xee3d, + 0xee3a, 0xee3c, 0xed1f, 0xee40, 0xee43, 0xee46, 0xee41, 0xedaa, + 0xee48, 0x6d5e, 0xee45, 0x6d5d, 0xee45, 0xee44, 0xee49, 0xee4c, + 0xee4f, 0xee50, 0xee4e, 0xe6d5, 0xee4a, 0x6d09, 0xee26, 0xee53, + 0x6da4, 0xee4d, 0x6dab, 0xee2b, 0xee51, 0xee52, 0x66de, 0x6dc4, + 0xee21, 0xee4b, 0xee59, 0xee55, 0xee57, 0xee56, 0xed7e, 0xee5b, + 0xee5c, 0xed59, 0x6d87, 0xee2b, 0xee27, 0x53ba, 0xed2c, 0xee5f, + 0x2bc9, 0x66ba, 0x674d, 0x674e, 0x674f, 0x6e16, 0xee64, 0xe6db, + 0xee60, 0xee61, 0xee58, 0xee63, 0xee5a, 0xee5a, 0xee62, 0xee5e, + 0xed33, 0x66de, 0x6d8f, 0xee21, 0xedcf, 0xedc9, 0xedc8, 0xee5d, + 0xedc6, 0xee67, 0xee65, 0x6d0e, 0xee25, 0xee37, 0xee68, 0xee36, + 0xee6a, 0xee54, 0xee69, 0xc1d5, 0xee6b, 0x6df4, 0xee47, 0x6df3, + 0xee47, 0xee6c, 0xee70, 0x6d3c, 0xee6d, 0xee34, 0xee0a, 0xee6f, + 0xedff, 0xee71, 0xd3ba, 0xee72, 0x6871, 0x6ad7, 0xee2c, 0x2bc9, + 0x66ba, 0x674d, 0x674e, 0x674f, 0x6db4, 0xee64, 0xee74, 0xee66, + 0x66da, 0xee73, 0xed1d, 0xee42, 0xee3e, 0x2c4c, 0xece5, 0xece9, + 0x66de, 0x6d8f, 0xedc4, 0xecf6, 0xecf4, 0xecf2, 0x6d0e, 0xedd7, + 0x6d09, 0xed76, 0xedac, 0xed07, 0xed06, 0xed23, 0x6d87, 0xedab, + 0xee15, 0xed28, 0xed1e, 0xed26, 0xed12, 0xed1f, 0xed1d, 0xed1b, + 0xedfd, 0xed15, 0xede5, 0xedd9, 0xed2f, 0xed30, 0xed42, 0xed34, + 0xed43, 0xed3f, 0xee1e, 0xed3b, 0xed50, 0xed53, 0xee1d, 0xed51, + 0xed60, 0x6d5d, 0xed5e, 0xed52, 0x6df3, 0xedf4, 0xed5c, 0xed61, + 0xed72, 0xed93, 0xed6a, 0xed7e, 0xed6f, 0xed6c, 0xed6e, 0xed89, + 0xed8a, 0xed77, 0xedeb, 0xed98, 0xeda1, 0xed9a, 0xedbb, 0xed96, + 0x6dbf, 0xedc0, 0xeda5, 0xeda9, 0xedca, 0xedc2, 0xedb2, 0xedb9, + 0xedba, 0xedc1, 0xedbc, 0x2bc9, 0x66ba, 0x674d, 0x674e, 0x674f, + 0x6db4, 0xee16, 0xedd6, 0xee1a, 0xedd3, 0xedda, 0xedef, 0xede6, + 0xedf2, 0xedf8, 0xedfa, 0xee07, 0xedf9, 0xee0c, 0xee0f, 0xee1b, + 0xee18, 0x2364, 0xa877, 0x4877, 0x48b1, 0xee7c, 0x24b8, 0xe18e, + 0xee7e, 0xc877, 0x4877, 0x48b1, 0xee78, 0x2869, 0xc6d0, 0xee7a, + 0xee85, 0xeea4, 0xee83, 0xee8f, 0xee87, 0x1e3d, 0xaa6f, 0xc350, + 0x4c97, 0xee84, 0xeea6, 0xeea5, 0x6eac, 0xeeb8, 0x4cc6, 0x6762, + 0x6eab, 0x6eb5, 0xeeba, 0x4cc6, 0x6762, 0x6eaa, 0x6eb5, 0xeeba, + 0x6ea9, 0xeeb8, 0xa305, 0x36f2, 0x4cac, 0x6eb4, 0xeeb9, 0x36f2, + 0x4cac, 0x6eaf, 0xeeb9, 0x4cc6, 0x6762, 0x6eaa, 0x6eab, 0xeeba, + 0x6ea9, 0xeeac, 0x36f2, 0x4cac, 0x6eaf, 0xeeb4, 0x4cc6, 0x6762, + 0x6eaa, 0x6eab, 0xeeb5, 0x45f2, 0x45f3, 0xd534, 0x1e48, 0x2c1b, + 0x2e85, 0xeebd, 0x1e48, 0x2c1b, 0x2e85, 0xeebc, 0xeec4, 0x48fa, + 0xeec3, 0xeecc, 0xeec9, 0xcc98, 0xeed2, 0xeed1, 0xeed9, 0xeed8, + 0xeef1, 0x294c, 0xc0b9, 0xeef6, 0xeeed, 0xa15a, 0xeef7, 0xeef2, + 0xeee4, 0xeedb, 0xeeea, 0xe709, 0xeee1, 0xeee9, 0xd8ae, 0xeefe, + 0xeefd, 0x6b6d, 0xef0b, 0xef0c, 0xd6d9, 0x6c32, 0xeccc, 0x6c49, + 0x6cd6, 0xef9e, 0xef0d, 0xeeff, 0xef02, 0xef09, 0xef11, 0xef0e, + 0xe3a1, 0x46b7, 0xc6bc, 0xa1ac, 0x6780, 0xe789, 0xef21, 0xef20, + 0xdc82, 0xef39, 0xef34, 0xa5c5, 0x1e9d, 0x3589, 0x358a, 0xef50, + 0x358b, 0xb58e, 0x5cf7, 0xdd4d, 0x67f2, 0xef51, 0x1e9d, 0x3589, + 0x358a, 0xef4a, 0x67f2, 0xef4f, 0x3b6f, 0xef7f, 0xef54, 0x6f53, + 0xef80, 0xef81, 0xef82, 0xef85, 0xef70, 0xef87, 0xef83, 0xef86, + 0x6f62, 0xef84, 0x6f61, 0xef84, 0xa1fa, 0xef88, 0x256e, 0x2699, + 0xa6d3, 0xa4ac, 0x6f71, 0xef8a, 0xef89, 0xef5a, 0xef6a, 0xef8b, + 0xd16d, 0xef8c, 0x3b6f, 0xef52, 0xef54, 0xef55, 0xef57, 0xef5f, + 0x6f61, 0xef62, 0xef59, 0xef60, 0xef5c, 0xef66, 0xef6c, 0xef6a, + 0xef72, 0xef77, 0x4adc, 0x6f92, 0xef99, 0xa390, 0xae9e, 0x4adc, + 0x6f8d, 0xef99, 0xef9a, 0xef9b, 0x6f8d, 0xef92, 0xef94, 0xef95, + 0x1e80, 0xef9f, 0x49cb, 0x49cc, 0xca50, 0x6c49, 0xef08, 0x1e80, + 0xef9c, 0x248a, 0x248c, 0xb0d2, 0x2401, 0xcc72, +}; + +static const short cjk_variants_indx[0x5200] = { + /* 0x4e00 */ + 4, -1, -1, -1, 5, 6, -1, 7, + -1, 8, 10, 11, 12, -1, 13, -1, + 14, 16, 19, 20, -1, -1, 22, 24, + 26, -1, 28, 29, 33, 34, -1, 36, + 38, 40, 42, 44, 45, 47, 49, 52, + -1, -1, 53, 56, 59, -1, -1, -1, + 60, -1, 66, 67, 68, -1, -1, -1, + -1, -1, 69, -1, -1, 71, 73, -1, + -1, 76, 77, 79, 81, 83, 85, -1, + 87, 92, -1, -1, 93, -1, -1, -1, + 94, 96, -1, -1, 100, 101, -1, 103, + 105, -1, 107, -1, -1, -1, -1, -1, + 110, 111, -1, -1, -1, -1, 115, -1, + 116, -1, -1, -1, -1, -1, -1, -1, + 118, 119, -1, -1, -1, -1, -1, -1, + -1, 121, -1, -1, -1, -1, 124, -1, + 128, 130, 133, -1, -1, -1, 135, -1, + 137, 138, 139, 141, 143, -1, 144, 147, + 151, 153, -1, -1, 155, -1, 156, 157, + 161, 162, 163, -1, 165, 167, 171, 173, + -1, 174, -1, -1, -1, -1, -1, 176, + -1, 178, -1, 182, 183, -1, -1, 184, + 185, 186, 187, -1, -1, 188, -1, -1, + 189, -1, 190, 191, -1, -1, 192, 194, + -1, 195, 196, -1, -1, 199, 201, 202, + -1, 203, -1, -1, 204, -1, 207, 209, + 210, 212, -1, 215, -1, -1, -1, -1, + 217, 218, -1, -1, -1, 220, 221, -1, + -1, -1, 222, -1, -1, -1, -1, 223, + -1, -1, 227, -1, 228, 229, 230, -1, + -1, -1, -1, -1, -1, -1, -1, 232, + -1, -1, 234, -1, 236, 237, 239, 240, + /* 0x4f00 */ + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 245, -1, -1, -1, -1, -1, 247, 248, + 251, 252, 253, 254, 255, 256, 259, 262, + 263, 265, -1, 266, 267, 268, 269, 270, + -1, -1, 271, 273, -1, -1, 275, -1, + -1, 276, 279, -1, -1, 282, -1, 283, + -1, -1, -1, -1, 284, -1, -1, -1, + 285, -1, 286, -1, -1, -1, -1, 287, + 288, -1, -1, -1, -1, -1, 289, -1, + -1, -1, -1, 290, 295, -1, -1, -1, + -1, 296, -1, 298, 301, -1, 302, -1, + 303, -1, -1, 307, -1, 308, -1, -1, + -1, -1, 309, -1, -1, -1, -1, -1, + -1, 310, -1, -1, -1, 312, -1, 314, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 315, 316, -1, 318, -1, + -1, -1, -1, -1, 319, -1, 323, -1, + 324, -1, -1, -1, -1, -1, 325, -1, + -1, -1, -1, -1, -1, -1, -1, 326, + 328, 329, -1, 331, -1, 332, 333, 335, + 336, 337, 338, 339, 340, 341, -1, 343, + -1, -1, -1, -1, -1, -1, 344, 345, + -1, -1, -1, -1, -1, 346, -1, -1, + -1, 347, 348, -1, -1, -1, -1, 349, + -1, -1, 350, -1, 351, -1, 352, -1, + -1, -1, -1, -1, 353, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 355, 356, + 357, 358, 359, 360, -1, 361, 362, -1, + 363, 364, 365, 366, -1, 367, 369, -1, + -1, 371, 372, -1, -1, -1, -1, -1, + -1, -1, -1, 374, 378, 380, -1, -1, + /* 0x5000 */ + 382, -1, 383, 385, -1, 388, 389, -1, + 390, 391, 393, 394, -1, -1, 397, 398, + 399, 400, -1, -1, -1, -1, 401, -1, + -1, -1, -1, -1, -1, -1, 402, 403, + -1, -1, -1, 405, 407, -1, 408, -1, + -1, -1, -1, 410, -1, -1, -1, -1, + -1, -1, -1, 411, -1, -1, 412, -1, + -1, 413, 415, -1, 416, -1, 417, -1, + 418, -1, -1, -1, -1, -1, 419, 420, + -1, 421, -1, -1, -1, -1, -1, -1, + 422, -1, -1, -1, -1, -1, -1, -1, + 425, 426, 427, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 428, -1, -1, + -1, -1, 429, -1, 430, -1, -1, -1, + -1, -1, -1, -1, 432, 433, -1, 435, + 436, 437, 441, 444, -1, 445, 447, 448, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 449, 452, -1, -1, + -1, 453, -1, -1, -1, -1, 454, -1, + 455, 458, 462, -1, 464, -1, -1, -1, + 465, 467, 470, -1, 471, 472, -1, 473, + 474, 475, -1, -1, -1, 476, -1, 477, + -1, -1, -1, 478, 480, 481, -1, 482, + -1, 483, -1, -1, -1, -1, 484, -1, + 485, -1, 486, 487, 491, 492, -1, -1, + -1, 493, 494, -1, -1, 495, -1, -1, + -1, 498, -1, -1, -1, 499, -1, -1, + 500, -1, -1, -1, 501, -1, 502, 504, + -1, -1, -1, 505, -1, 506, -1, -1, + 507, 508, -1, 509, -1, 512, -1, -1, + -1, 513, 514, -1, 515, -1, -1, -1, + -1, 516, -1, -1, -1, -1, -1, -1, + /* 0x5100 */ + 518, 519, 520, -1, 521, -1, -1, -1, + 522, 523, -1, -1, -1, -1, 525, -1, + 526, -1, -1, -1, 527, 528, -1, -1, + 529, -1, -1, -1, -1, -1, 531, 534, + -1, -1, -1, -1, -1, -1, -1, 535, + -1, -1, 536, -1, -1, -1, -1, -1, + -1, -1, 537, -1, -1, -1, -1, 538, + -1, 539, 540, 541, 542, -1, -1, 543, + -1, -1, 545, -1, -1, -1, -1, 546, + -1, 547, 549, 551, 554, -1, 556, 557, + 561, 563, 565, -1, 567, -1, 568, 569, + 570, -1, 572, -1, 573, -1, -1, -1, + 574, -1, -1, -1, 575, -1, 576, 578, + -1, 579, 581, -1, -1, -1, -1, -1, + 582, -1, 583, 586, 591, -1, 592, -1, + -1, 593, -1, 595, -1, 597, 599, -1, + 600, 601, 602, 603, 604, 605, 606, -1, + 609, 610, 611, 613, 614, -1, 616, 618, + 619, 620, 621, -1, -1, -1, -1, 622, + -1, 623, -1, 625, 626, 627, -1, -1, + -1, -1, 629, 630, 631, -1, 632, -1, + 634, 635, 637, 639, 642, -1, -1, 644, + 645, 648, 649, 651, 652, 653, -1, -1, + -1, -1, 654, 655, -1, 656, -1, -1, + 657, -1, 659, 660, 661, 664, 665, -1, + 667, 668, -1, -1, -1, 669, -1, 670, + -1, 671, 672, 673, -1, -1, 674, -1, + -1, -1, -1, 676, 678, -1, 680, -1, + 684, 686, 688, 690, 692, 693, 694, -1, + 696, -1, -1, 701, 702, 707, 710, 715, + -1, 716, 717, 722, 723, -1, 726, 727, + -1, -1, 730, 732, -1, 734, 735, 736, + /* 0x5200 */ + 737, -1, 739, 741, 742, 743, -1, -1, + 745, -1, 747, -1, -1, 748, -1, -1, + -1, -1, 749, 752, 753, -1, -1, -1, + 754, 755, 756, 757, -1, -1, -1, -1, + 762, -1, -1, -1, -1, 763, 764, 767, + 770, -1, 773, 774, 776, 780, 781, -1, + -1, 782, -1, -1, 786, -1, 787, -1, + -1, 788, 789, -1, 790, 793, 794, 795, + 796, 797, 798, 800, 801, -1, -1, 802, + -1, -1, -1, 803, 806, 807, 808, 809, + 813, 815, -1, -1, -1, -1, -1, 823, + -1, 827, 831, 832, -1, 833, -1, -1, + -1, -1, -1, 834, 842, 844, 845, 847, + -1, 848, -1, -1, -1, -1, 849, -1, + 852, 853, -1, 861, 862, 863, -1, 868, + -1, 872, -1, -1, -1, -1, -1, 873, + -1, -1, -1, 874, 877, -1, -1, 878, + -1, 879, 880, -1, 881, 882, 890, -1, + 898, 901, 903, -1, 911, 919, -1, -1, + -1, -1, -1, -1, -1, 921, 923, 924, + -1, 926, 927, -1, -1, -1, -1, -1, + 928, -1, 931, 932, -1, -1, -1, -1, + -1, 935, 936, 937, 940, 943, -1, -1, + -1, 945, -1, -1, -1, -1, -1, 946, + -1, 947, -1, -1, 948, 949, -1, 951, + 952, -1, 953, 956, 959, -1, -1, -1, + -1, 961, -1, -1, -1, 965, 968, 970, + -1, 972, 973, 974, -1, 977, 978, -1, + 981, -1, 982, -1, 983, -1, 984, 985, + -1, 987, -1, -1, -1, -1, -1, -1, + -1, 988, 989, 992, -1, 995, -1, -1, + 996, -1, -1, 998, -1, -1, -1, -1, + /* 0x5300 */ + 999, -1, -1, 1000, 1002, 1004, 1005, -1, + -1, -1, 1008, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 1009, -1, 1011, 1012, -1, 1014, 1016, -1, + 1017, 1018, -1, -1, -1, -1, 1019, 1020, + 1021, 1023, -1, -1, -1, 1024, 1025, 1026, + -1, 1028, 1029, 1032, -1, -1, -1, -1, + 1035, -1, 1036, 1037, -1, -1, -1, -1, + 1039, -1, -1, 1040, -1, -1, 1041, 1042, + -1, 1046, -1, 1047, -1, 1049, 1050, 1053, + 1056, -1, 1057, 1058, 1060, 1063, 1065, -1, + 1067, -1, 1069, 1070, 1071, -1, -1, -1, + 1073, -1, 1074, -1, 1075, 1082, -1, 1084, + -1, -1, -1, 1085, -1, -1, 1087, 1088, + 1090, -1, -1, 1091, 1093, -1, -1, 1094, + 1096, 1097, -1, 1099, -1, 1100, -1, -1, + -1, -1, 1102, -1, 1105, 1106, 1108, 1114, + 1115, 1116, -1, 1117, 1119, 1120, 1121, -1, + 1122, -1, -1, 1123, -1, 1124, -1, -1, + 1126, 1130, 1131, 1132, -1, -1, -1, 1133, + 1134, 1136, 1137, 1138, 1139, -1, 1141, -1, + 1142, 1143, -1, -1, -1, 1145, 1146, 1147, + 1152, -1, 1154, 1155, 1157, 1158, 1159, 1160, + 1161, -1, 1164, 1165, -1, -1, 1166, 1168, + -1, 1170, 1172, 1175, 1178, 1181, 1184, 1185, + 1186, 1187, 1188, -1, 1189, 1190, 1193, 1194, + 1195, 1196, -1, 1200, -1, 1202, -1, -1, + 1203, 1205, -1, 1207, -1, -1, 1209, -1, + 1210, 1214, 1216, -1, -1, -1, -1, 1220, + -1, -1, 1223, 1226, -1, -1, -1, -1, + 1227, -1, -1, -1, -1, -1, 1232, 1236, + -1, 1237, -1, -1, -1, 1240, -1, -1, + /* 0x5400 */ + 1241, 1243, -1, 1245, -1, -1, -1, -1, + 1247, -1, 1248, -1, 1249, -1, 1251, -1, + -1, 1252, -1, 1254, -1, 1255, -1, 1256, + -1, -1, -1, -1, -1, 1257, 1258, 1259, + -1, -1, -1, -1, -1, -1, -1, -1, + 1262, -1, -1, -1, 1263, -1, -1, 1265, + -1, -1, -1, 1271, 1273, -1, 1275, -1, + -1, -1, -1, 1276, -1, 1277, -1, 1278, + -1, -1, 1279, -1, -1, -1, -1, -1, + 1280, 1282, 1284, -1, 1285, 1286, -1, -1, + 1287, 1288, 1289, 1290, -1, 1291, 1292, 1293, + 1294, 1297, 1299, 1300, 1301, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 1302, + 1303, 1304, 1305, -1, -1, 1307, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1308, -1, -1, -1, + -1, -1, -1, -1, -1, 1311, -1, -1, + -1, -1, 1312, -1, 1315, -1, -1, 1318, + -1, -1, 1319, -1, -1, -1, -1, -1, + -1, 1321, -1, 1322, 1323, 1324, -1, -1, + -1, -1, -1, -1, 1325, -1, -1, -1, + -1, 1326, -1, -1, 1328, -1, -1, 1329, + -1, 1331, 1334, -1, -1, -1, -1, -1, + 1336, -1, -1, -1, 1338, 1340, -1, -1, + -1, -1, -1, -1, 1341, -1, -1, -1, + -1, -1, -1, -1, -1, 1343, -1, -1, + -1, 1344, 1348, 1349, 1350, 1351, -1, 1352, + -1, 1354, -1, -1, 1355, 1356, -1, 1357, + -1, 1358, -1, 1361, -1, -1, -1, -1, + -1, -1, -1, -1, 1362, -1, -1, -1, + -1, -1, 1363, -1, -1, -1, 1368, -1, + -1, -1, 1370, -1, -1, -1, -1, -1, + /* 0x5500 */ + 1371, -1, -1, -1, 1373, -1, -1, 1374, + -1, -1, -1, -1, -1, 1375, -1, -1, + 1376, -1, -1, -1, -1, 1377, 1378, -1, + 1382, -1, -1, 1388, -1, 1389, -1, -1, + 1390, -1, 1391, 1392, 1393, -1, -1, 1394, + -1, -1, -1, 1395, -1, -1, -1, -1, + -1, 1396, -1, -1, -1, -1, -1, -1, + 1397, -1, -1, -1, -1, -1, -1, -1, + 1398, -1, -1, -1, -1, -1, 1399, -1, + -1, -1, -1, -1, -1, -1, -1, 1400, + -1, -1, -1, 1401, 1407, -1, 1413, 1414, + -1, -1, -1, -1, -1, -1, 1415, 1419, + 1425, -1, -1, 1430, -1, -1, -1, 1433, + -1, -1, -1, -1, 1434, 1435, 1436, 1440, + 1441, -1, -1, -1, 1443, -1, -1, -1, + 1444, -1, 1445, -1, -1, -1, -1, -1, + 1446, -1, 1448, -1, 1450, -1, 1451, -1, + -1, -1, -1, -1, -1, -1, 1456, -1, + -1, 1458, 1460, -1, -1, -1, -1, -1, + -1, -1, 1463, -1, 1464, -1, 1467, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 1468, 1469, 1470, 1472, -1, 1473, 1475, + 1477, -1, 1480, -1, -1, -1, 1481, 1483, + -1, -1, -1, 1485, -1, 1486, 1487, -1, + -1, -1, -1, -1, -1, 1488, 1489, 1490, + -1, -1, 1491, -1, -1, -1, 1492, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 1493, -1, 1494, -1, -1, -1, + 1495, -1, -1, 1496, -1, 1497, -1, -1, + -1, 1498, -1, 1499, -1, -1, -1, -1, + -1, -1, -1, 1500, -1, -1, 1501, -1, + -1, 1502, -1, -1, -1, -1, -1, -1, + /* 0x5600 */ + -1, -1, -1, -1, -1, -1, 1503, -1, + -1, -1, 1505, -1, -1, 1506, -1, -1, + -1, 1507, -1, 1509, 1510, -1, 1511, 1512, + 1515, -1, -1, -1, 1516, -1, -1, -1, + -1, -1, -1, -1, 1517, -1, -1, -1, + 1518, 1519, -1, -1, -1, -1, 1521, 1522, + 1524, 1525, -1, -1, -1, 1526, -1, 1527, + 1528, -1, -1, -1, -1, 1529, -1, -1, + -1, 1530, 1531, -1, 1532, 1534, -1, -1, + -1, 1535, -1, -1, -1, -1, -1, -1, + 1537, -1, -1, 1538, -1, 1539, 1540, -1, + -1, -1, -1, 1542, 1544, 1545, -1, -1, + 1546, 1547, -1, -1, -1, 1548, 1549, -1, + 1550, -1, 1551, -1, -1, -1, -1, 1552, + -1, -1, 1553, -1, 1554, 1556, -1, -1, + 1559, 1560, -1, -1, -1, -1, 1561, -1, + 1562, -1, -1, -1, -1, -1, -1, 1563, + -1, -1, -1, -1, 1564, -1, -1, 1565, + 1566, -1, -1, -1, 1569, 1570, -1, -1, + -1, 1571, -1, -1, -1, -1, 1575, -1, + 1580, -1, 1581, 1582, -1, 1583, 1584, -1, + 1585, -1, -1, -1, -1, -1, 1586, -1, + -1, -1, 1587, 1588, 1589, -1, 1591, -1, + -1, -1, -1, 1592, -1, -1, -1, -1, + 1593, 1594, 1595, -1, -1, 1597, -1, -1, + 1598, 1599, 1601, -1, 1602, -1, -1, 1603, + -1, 1604, -1, 1605, -1, -1, -1, 1608, + 1611, 1617, -1, 1618, -1, -1, 1619, 1625, + 1626, -1, 1627, 1630, -1, -1, 1633, 1636, + -1, -1, 1637, -1, 1638, 1644, -1, 1647, + 1652, 1653, 1654, 1657, 1660, 1663, 1664, -1, + 1669, -1, -1, 1670, -1, 1675, 1680, -1, + /* 0x5700 */ + 1683, -1, -1, 1688, -1, -1, 1689, 1692, + 1693, -1, -1, 1694, -1, 1699, 1702, 1705, + -1, 1706, 1707, 1709, -1, -1, 1712, 1715, + 1718, -1, -1, -1, -1, 1720, -1, 1722, + -1, 1723, 1724, 1726, -1, -1, -1, 1727, + 1729, -1, -1, -1, 1730, 1731, -1, -1, + 1732, -1, -1, -1, -1, -1, -1, -1, + -1, 1735, 1736, -1, -1, 1738, -1, -1, + 1742, -1, 1743, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 1745, + 1749, 1750, -1, 1751, 1752, -1, -1, 1755, + -1, 1758, 1759, 1760, 1766, 1767, 1769, 1771, + 1773, -1, -1, 1775, 1776, -1, 1777, 1778, + 1779, -1, -1, -1, -1, 1781, 1782, 1784, + 1786, -1, -1, 1787, -1, 1788, -1, -1, + 1790, -1, 1791, -1, -1, -1, -1, -1, + -1, -1, 1792, -1, 1793, 1794, 1795, 1796, + -1, -1, -1, 1797, -1, -1, -1, -1, + -1, -1, 1798, 1800, 1801, 1802, 1803, -1, + -1, -1, 1804, 1807, 1808, -1, -1, -1, + -1, 1809, 1810, -1, -1, -1, 1811, 1812, + 1813, 1814, -1, 1816, -1, 1817, -1, 1818, + -1, 1819, 1820, -1, 1821, -1, -1, -1, + -1, -1, -1, 1822, -1, -1, -1, -1, + 1824, -1, -1, -1, -1, -1, 1825, -1, + 1826, -1, 1827, -1, -1, -1, -1, -1, + -1, 1830, 1835, 1836, -1, -1, -1, -1, + 1837, 1838, 1840, -1, 1841, -1, 1843, -1, + -1, 1845, -1, -1, -1, -1, 1846, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 1847, + -1, -1, -1, -1, 1848, 1851, -1, -1, + /* 0x5800 */ + -1, -1, 1852, 1853, -1, 1854, 1855, 1856, + -1, -1, 1857, -1, -1, -1, -1, -1, + -1, 1858, -1, -1, -1, 1859, 1861, -1, + -1, 1862, -1, -1, -1, 1863, -1, -1, + -1, -1, -1, -1, 1864, -1, 1866, -1, + -1, -1, -1, -1, -1, -1, -1, 1868, + 1871, 1873, -1, -1, 1874, -1, -1, -1, + -1, -1, 1876, -1, -1, -1, -1, -1, + -1, 1878, -1, -1, -1, -1, 1880, -1, + -1, -1, 1881, 1884, -1, 1885, -1, 1886, + 1887, 1888, 1889, -1, 1890, -1, -1, 1891, + -1, 1892, 1893, -1, -1, -1, -1, 1894, + -1, 1895, 1896, -1, 1897, -1, 1899, -1, + -1, 1900, -1, 1902, -1, -1, -1, -1, + -1, -1, 1903, -1, -1, 1905, -1, 1906, + -1, 1908, -1, -1, 1910, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 1913, 1914, -1, 1915, -1, -1, -1, + -1, -1, -1, -1, -1, 1916, 1918, 1919, + -1, 1920, -1, -1, 1922, -1, 1924, -1, + -1, -1, 1925, -1, 1927, -1, -1, 1930, + -1, -1, -1, -1, -1, -1, 1931, 1933, + 1935, -1, -1, 1940, -1, 1942, 1947, -1, + 1948, -1, -1, 1949, -1, -1, 1950, -1, + -1, -1, -1, -1, 1951, -1, -1, 1953, + -1, -1, 1954, 1956, 1957, 1958, 1959, -1, + 1961, -1, -1, 1962, -1, -1, -1, -1, + 1964, 1966, 1967, -1, 1968, -1, 1973, 1975, + 1976, 1977, 1979, -1, 1980, 1981, -1, -1, + -1, 1984, 1986, -1, -1, -1, 1987, 1989, + 1991, 1992, 1993, 1995, -1, 1997, 1999, 2001, + 2003, 2004, 2005, 2007, 2009, 2010, -1, -1, + /* 0x5900 */ + 2012, -1, 2014, -1, 2015, 2017, -1, 2018, + -1, 2022, 2024, -1, -1, 2025, -1, 2028, + -1, -1, -1, 2029, 2030, -1, -1, -1, + 2031, -1, 2033, 2034, 2035, -1, -1, 2036, + 2037, -1, 2038, 2040, -1, 2042, -1, -1, + -1, 2043, -1, -1, 2046, 2047, -1, -1, + -1, -1, 2048, 2050, 2051, -1, 2052, -1, + 2053, 2054, 2055, -1, -1, -1, 2056, -1, + -1, 2057, 2060, -1, -1, -1, -1, 2061, + 2062, -1, -1, 2063, 2064, -1, -1, -1, + 2065, -1, -1, -1, 2066, -1, 2068, -1, + 2071, 2072, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2073, -1, 2075, + 2077, 2080, 2083, -1, 2084, -1, 2087, -1, + -1, -1, -1, -1, -1, -1, 2088, -1, + 2090, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2092, 2096, + 2098, -1, 2099, -1, -1, 2100, -1, -1, + -1, -1, 2102, -1, -1, -1, 2103, -1, + -1, 2104, -1, 2105, -1, 2106, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2110, 2111, 2112, 2114, -1, -1, -1, + -1, -1, -1, 2115, -1, -1, -1, 2118, + 2120, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2122, -1, + -1, 2123, 2124, 2125, -1, 2127, -1, -1, + 2128, -1, 2129, -1, -1, -1, -1, 2130, + -1, 2131, -1, -1, 2132, -1, -1, -1, + -1, -1, 2133, -1, -1, -1, 2134, 2136, + -1, -1, 2138, 2140, 2141, -1, 2142, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 2143, -1, -1, 2145, -1, -1, -1, -1, + /* 0x5a00 */ + -1, -1, -1, -1, 2146, 2147, 2148, 2149, + 2150, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 2151, -1, -1, -1, -1, -1, + 2152, -1, -1, 2154, -1, -1, -1, 2156, + -1, -1, -1, -1, 2157, -1, 2161, -1, + -1, -1, -1, -1, -1, 2162, -1, 2163, + 2165, 2166, 2168, -1, 2169, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2171, + 2173, 2176, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 2177, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2178, -1, -1, 2179, -1, + -1, -1, -1, -1, 2181, 2182, -1, 2183, + -1, -1, -1, 2185, 2186, 2189, 2190, -1, + -1, -1, -1, -1, -1, -1, -1, 2191, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2193, 2195, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2196, + -1, -1, 2197, -1, -1, 2198, -1, 2199, + -1, -1, -1, -1, -1, -1, -1, -1, + 2201, -1, -1, -1, 2202, 2203, -1, 2204, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2206, -1, -1, -1, -1, + 2208, -1, 2209, -1, 2210, -1, -1, 2211, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2212, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2213, -1, -1, -1, 2214, 2215, -1, + -1, -1, 2217, 2219, -1, -1, -1, 2221, + /* 0x5b00 */ + 2222, -1, -1, 2224, -1, -1, -1, -1, + 2225, 2226, -1, 2227, 2228, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2229, -1, -1, -1, 2230, -1, -1, + -1, 2232, 2233, -1, 2235, -1, -1, -1, + -1, -1, 2236, -1, -1, 2238, -1, -1, + 2240, -1, 2243, -1, -1, -1, -1, 2244, + 2245, -1, -1, -1, -1, -1, 2246, -1, + -1, -1, -1, 2247, -1, -1, 2249, -1, + -1, -1, -1, -1, 2252, -1, -1, -1, + -1, -1, 2253, 2254, -1, -1, -1, -1, + -1, 2255, -1, -1, -1, -1, -1, -1, + 2256, -1, -1, -1, -1, -1, 2257, -1, + -1, -1, 2262, 2263, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 2264, -1, -1, -1, 2269, 2270, 2271, 2274, + -1, 2275, 2281, 2282, -1, -1, 2285, -1, + 2286, -1, 2287, -1, -1, 2288, -1, -1, + 2289, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2291, 2293, 2297, 2299, + 2301, 2302, -1, -1, -1, -1, -1, -1, + -1, 2304, 2305, 2306, -1, -1, 2307, -1, + -1, -1, -1, -1, 2308, -1, 2310, 2311, + -1, -1, -1, 2313, 2314, 2316, 2318, -1, + 2320, -1, -1, 2321, -1, -1, 2322, 2323, + 2325, 2327, -1, -1, 2334, 2335, -1, -1, + -1, -1, -1, 2341, -1, 2342, -1, 2348, + -1, -1, 2354, 2358, 2360, 2366, -1, 2367, + 2368, -1, 2370, -1, -1, -1, 2371, 2373, + -1, 2379, -1, 2381, 2383, -1, -1, -1, + -1, -1, -1, 2385, -1, 2389, 2390, -1, + -1, 2394, -1, 2396, 2397, -1, 2398, 2400, + /* 0x5c00 */ + -1, -1, 2402, -1, -1, 2404, 2407, 2408, + 2409, 2411, -1, 2412, -1, 2413, 2415, -1, + -1, -1, 2416, 2419, 2422, -1, -1, -1, + 2425, 2426, 2427, 2428, -1, 2432, 2435, 2436, + 2441, -1, 2446, 2449, 2450, 2452, 2453, 2454, + -1, 2457, -1, 2458, 2459, 2460, -1, -1, + -1, -1, 2463, -1, 2468, -1, 2473, 2478, + 2483, -1, -1, -1, -1, 2484, -1, -1, + 2487, -1, 2489, 2490, -1, 2491, 2492, -1, + -1, -1, 2493, -1, 2494, 2496, 2497, 2498, + -1, -1, -1, 2500, -1, -1, -1, -1, + -1, -1, -1, 2501, -1, -1, 2503, -1, + -1, 2504, 2505, -1, 2506, -1, 2507, -1, + 2508, -1, -1, -1, 2509, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2510, + 2511, 2512, 2516, -1, -1, 2517, -1, -1, + 2519, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2520, 2521, + 2522, -1, 2523, 2524, -1, -1, -1, -1, + -1, 2531, -1, -1, -1, -1, -1, -1, + -1, 2532, -1, -1, -1, 2538, -1, -1, + -1, -1, -1, 2539, 2540, -1, -1, -1, + -1, -1, -1, -1, -1, 2541, -1, 2542, + -1, -1, -1, 2543, 2544, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 2545, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2546, -1, -1, + -1, 2547, -1, 2548, 2549, 2550, 2551, -1, + 2552, 2553, -1, -1, -1, -1, -1, 2554, + 2555, -1, -1, -1, 2556, 2557, 2560, -1, + -1, -1, -1, -1, -1, 2567, -1, -1, + /* 0x5d00 */ + -1, -1, 2568, 2569, 2570, -1, -1, 2571, + 2572, -1, -1, 2573, -1, 2575, 2576, -1, + -1, -1, -1, -1, -1, -1, 2579, 2580, + 2581, 2583, -1, -1, -1, -1, -1, -1, + -1, -1, 2585, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2586, 2587, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2589, -1, -1, -1, + 2590, -1, 2591, 2594, -1, -1, -1, 2597, + 2601, -1, 2604, -1, 2605, 2608, -1, -1, + 2609, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2611, + -1, -1, -1, 2612, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2613, -1, 2614, 2615, -1, -1, 2616, + -1, -1, -1, 2618, 2625, -1, -1, -1, + -1, -1, -1, -1, 2632, -1, -1, 2633, + -1, -1, -1, -1, -1, -1, -1, -1, + 2634, -1, 2635, -1, -1, -1, -1, 2636, + 2637, -1, -1, -1, -1, -1, 2638, -1, + -1, -1, 2639, 2640, 2643, -1, -1, -1, + 2645, 2648, 2655, -1, 2656, 2657, -1, -1, + -1, -1, -1, -1, -1, 2658, 2660, -1, + -1, -1, -1, 2663, 2664, -1, -1, -1, + -1, -1, 2667, 2668, 2669, -1, 2670, 2673, + -1, -1, -1, 2676, -1, 2677, -1, -1, + 2678, -1, 2679, 2680, -1, -1, -1, -1, + -1, 2681, -1, -1, -1, -1, -1, 2682, + 2683, -1, -1, -1, -1, 2684, -1, 2685, + -1, -1, 2686, 2687, -1, 2689, -1, 2690, + /* 0x5e00 */ + 2692, 2694, -1, 2697, -1, 2698, -1, -1, + 2699, -1, -1, 2700, -1, -1, -1, 2701, + 2702, 2703, 2704, -1, -1, 2705, -1, -1, + 2706, -1, 2707, -1, 2708, -1, -1, -1, + -1, -1, -1, -1, -1, 2710, 2711, 2713, + -1, -1, -1, 2714, -1, 2715, 2716, 2719, + 2721, 2724, -1, 2725, -1, -1, 2726, -1, + -1, -1, -1, 2728, 2729, 2730, -1, -1, + 2731, -1, 2732, 2734, -1, -1, -1, 2735, + 2738, -1, -1, -1, 2740, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2741, + 2742, -1, 2743, -1, -1, -1, -1, 2746, + -1, 2748, -1, 2749, 2751, -1, -1, -1, + -1, -1, -1, 2753, 2756, -1, -1, -1, + -1, -1, 2757, -1, 2760, -1, 2761, 2767, + 2768, 2769, 2771, -1, -1, -1, 2772, 2773, + -1, 2776, -1, 2778, 2780, 2782, 2786, -1, + -1, -1, 2787, -1, -1, -1, -1, -1, + 2788, 2789, -1, 2790, 2791, -1, -1, -1, + -1, 2793, -1, -1, -1, -1, 2794, 2795, + -1, -1, -1, -1, -1, -1, -1, 2797, + -1, -1, -1, 2798, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2799, 2803, -1, + -1, -1, 2804, 2809, 2810, 2811, -1, 2812, + -1, 2813, 2815, 2816, -1, -1, -1, -1, + 2818, -1, -1, -1, -1, -1, 2819, 2820, + 2822, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 2824, 2825, -1, 2828, -1, 2829, + 2831, 2833, 2834, 2836, -1, -1, -1, -1, + -1, 2838, 2839, -1, 2840, -1, -1, -1, + 2841, -1, -1, 2844, -1, -1, -1, -1, + 2848, -1, -1, 2849, 2855, 2857, -1, -1, + /* 0x5f00 */ + 2863, 2864, 2871, 2872, 2873, -1, -1, -1, + -1, 2875, -1, -1, 2876, 2877, 2878, -1, + 2880, 2883, 2884, -1, 2885, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 2886, -1, -1, -1, -1, 2887, 2889, -1, + -1, -1, 2890, -1, -1, -1, -1, 2891, + -1, -1, -1, 2892, -1, 2893, -1, 2894, + -1, 2895, 2897, 2898, 2899, -1, 2900, -1, + -1, -1, -1, -1, -1, -1, 2902, -1, + 2903, -1, -1, -1, 2905, -1, 2906, -1, + 2907, 2908, 2909, 2912, 2914, 2915, -1, 2918, + -1, 2919, 2921, 2923, 2926, 2929, 2932, 2935, + 2936, -1, -1, -1, -1, 2938, 2939, -1, + 2940, 2941, -1, 2942, 2943, -1, -1, -1, + -1, -1, 2945, -1, 2946, -1, -1, 2947, + -1, -1, -1, 2950, -1, -1, -1, 2951, + 2953, 2955, -1, 2958, 2959, -1, -1, 2962, + 2963, -1, 2964, -1, 2965, -1, -1, 2966, + -1, 2967, -1, 2970, -1, 2972, -1, -1, + -1, -1, -1, -1, -1, -1, 2974, -1, + 2976, 2978, -1, 2979, 2981, -1, -1, -1, + -1, 2982, -1, -1, 2984, 2987, -1, -1, + 2988, 2989, -1, 2990, 2993, 2995, -1, 2997, + -1, 3000, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3001, 3002, -1, 3003, -1, + -1, -1, -1, -1, -1, -1, 3004, 3005, + -1, -1, -1, -1, -1, -1, -1, 3007, + -1, 3008, -1, -1, 3009, -1, -1, -1, + -1, -1, 3011, 3012, -1, -1, -1, 3013, + -1, 3014, -1, -1, -1, -1, -1, -1, + 3017, -1, -1, -1, -1, 3018, -1, -1, + -1, -1, -1, -1, -1, -1, 3019, -1, + /* 0x6000 */ + 3020, 3022, 3023, 3024, 3025, 3026, 3027, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3028, -1, 3029, -1, + -1, -1, -1, -1, 3030, 3031, -1, -1, + -1, -1, -1, 3032, -1, 3034, -1, -1, + -1, -1, 3035, -1, -1, -1, -1, -1, + -1, 3036, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3039, 3044, -1, -1, 3045, + -1, -1, -1, -1, -1, -1, 3046, -1, + -1, -1, -1, 3047, -1, -1, -1, -1, + -1, -1, 3048, 3049, -1, -1, 3051, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 3052, 3053, -1, -1, 3055, 3057, -1, -1, + -1, -1, 3058, -1, -1, -1, -1, -1, + -1, 3059, -1, 3061, 3062, 3065, 3066, -1, + 3070, 3071, 3072, 3073, 3074, 3076, 3077, 3078, + 3080, -1, -1, -1, -1, 3082, -1, -1, + -1, -1, 3084, 3089, -1, 3090, -1, -1, + -1, 3091, -1, 3092, -1, -1, 3093, -1, + -1, -1, -1, -1, -1, -1, 3095, 3096, + -1, -1, 3097, -1, 3098, -1, 3101, -1, + -1, 3103, 3105, 3108, 3109, 3110, -1, 3111, + -1, -1, -1, 3112, 3115, 3116, 3117, -1, + -1, -1, -1, -1, -1, 3118, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3120, -1, -1, -1, -1, -1, + -1, -1, 3122, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3125, -1, + 3127, 3128, -1, 3131, -1, 3132, -1, 3134, + 3135, 3136, -1, 3137, 3138, 3139, 3141, 3142, + -1, 3143, 3145, -1, -1, -1, -1, 3146, + -1, -1, -1, 3147, 3148, -1, -1, -1, + /* 0x6100 */ + -1, -1, 3149, -1, -1, -1, -1, -1, + 3151, -1, -1, -1, -1, -1, -1, -1, + -1, 3153, -1, -1, -1, -1, -1, -1, + -1, 3155, -1, 3156, 3157, -1, -1, -1, + 3158, 3159, -1, -1, 3160, -1, 3161, 3162, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3164, 3165, -1, -1, 3166, + -1, 3167, -1, -1, 3169, 3170, 3171, 3172, + -1, -1, 3173, -1, 3175, -1, -1, 3176, + -1, -1, -1, 3177, -1, 3178, 3179, -1, + -1, 3182, -1, -1, -1, -1, -1, -1, + 3184, 3185, 3187, -1, -1, -1, -1, 3189, + -1, -1, -1, 3191, 3192, -1, -1, -1, + -1, -1, 3193, 3194, -1, 3195, 3196, -1, + -1, -1, -1, 3197, 3198, -1, 3199, -1, + -1, -1, -1, -1, 3200, 3202, 3204, 3205, + -1, 3208, 3209, -1, -1, 3210, -1, 3211, + -1, -1, 3212, -1, -1, -1, -1, -1, + 3213, 3214, 3217, -1, 3218, -1, 3220, 3222, + 3223, 3226, 3229, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3230, 3231, -1, -1, + -1, 3234, -1, 3235, -1, -1, 3236, -1, + -1, -1, 3237, -1, -1, -1, 3238, -1, + -1, -1, -1, 3239, -1, -1, -1, -1, + -1, -1, -1, 3240, -1, -1, -1, 3241, + -1, 3242, -1, -1, 3244, 3245, -1, -1, + 3246, 3248, 3249, -1, 3251, -1, -1, -1, + -1, -1, -1, -1, 3252, -1, 3253, 3254, + -1, -1, -1, 3255, -1, -1, 3256, 3257, + 3258, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3259, -1, 3260, 3262, 3263, 3264, + 3266, -1, 3267, -1, 3268, 3270, 3271, 3272, + /* 0x6200 */ + 3273, -1, -1, -1, -1, -1, 3274, 3275, + -1, -1, -1, 3276, -1, -1, -1, 3277, + -1, -1, -1, -1, 3279, -1, -1, 3280, + 3281, -1, 3283, 3285, -1, 3286, 3288, -1, + -1, -1, -1, -1, -1, -1, 3289, 3291, + -1, 3292, -1, -1, 3293, -1, 3294, 3296, + 3298, -1, 3300, -1, -1, -1, 3302, 3304, + 3306, 3308, -1, 3309, 3310, -1, 3312, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3313, 3314, 3315, 3316, -1, + -1, 3318, -1, -1, -1, 3320, -1, 3321, + 3322, -1, -1, -1, -1, -1, 3324, -1, + 3325, -1, -1, 3326, -1, -1, -1, 3327, + 3328, 3330, 3332, 3333, 3334, -1, -1, 3335, + 3336, -1, -1, -1, -1, 3337, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3338, -1, -1, -1, -1, -1, + -1, 3340, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3341, 3342, 3343, 3344, 3345, 3347, + 3348, 3349, 3350, -1, 3351, 3352, -1, -1, + -1, -1, -1, -1, 3353, -1, -1, -1, + -1, -1, -1, -1, -1, 3354, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3357, -1, -1, 3358, -1, -1, + 3359, -1, -1, 3360, -1, -1, -1, 3361, + 3362, -1, -1, 3364, 3365, 3366, 3367, 3368, + -1, -1, -1, -1, 3369, 3370, 3371, 3372, + 3373, 3375, 3378, 3379, -1, 3380, 3381, 3382, + 3383, 3385, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3387, + /* 0x6300 */ + -1, -1, 3388, -1, 3389, -1, -1, -1, + -1, -1, 3391, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3393, 3396, 3397, 3398, 3399, 3400, 3401, + 3402, 3403, 3404, 3405, 3406, 3407, 3408, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3409, -1, 3411, + -1, -1, -1, -1, -1, 3412, 3413, 3414, + -1, 3415, -1, -1, -1, -1, 3418, -1, + -1, -1, -1, -1, -1, 3421, -1, 3422, + -1, -1, -1, -1, -1, -1, -1, 3423, + -1, -1, -1, -1, 3424, -1, 3425, 3426, + -1, 3427, 3428, 3429, -1, -1, -1, -1, + 3431, -1, -1, 3432, -1, -1, 3433, -1, + -1, -1, 3435, -1, 3437, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3438, + -1, -1, -1, 3440, 3442, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3443, + -1, 3444, -1, 3445, -1, -1, -1, -1, + -1, 3446, -1, -1, -1, 3447, -1, -1, + -1, -1, -1, -1, 3448, -1, -1, -1, + -1, -1, 3449, 3450, 3451, -1, -1, 3452, + 3453, -1, 3454, 3455, 3456, 3457, -1, -1, + 3458, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3459, 3460, -1, -1, -1, -1, -1, + -1, -1, 3461, 3462, -1, -1, -1, -1, + 3463, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3464, 3465, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3466, 3467, -1, -1, 3469, -1, 3470, + /* 0x6400 */ + 3471, 3472, 3473, 3474, -1, 3475, 3478, -1, + -1, -1, -1, -1, -1, 3479, -1, -1, + -1, -1, 3480, -1, 3481, -1, 3482, 3484, + -1, -1, -1, -1, 3485, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 3487, -1, -1, -1, -1, 3488, -1, -1, + -1, -1, 3489, -1, -1, -1, 3490, -1, + -1, -1, 3491, -1, -1, -1, 3493, -1, + -1, -1, 3494, -1, 3496, 3498, 3499, 3501, + 3503, -1, 3504, -1, -1, -1, -1, -1, + -1, 3505, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3506, -1, -1, 3507, + 3508, -1, -1, -1, -1, -1, -1, -1, + -1, 3511, -1, -1, -1, -1, -1, 3512, + -1, -1, -1, 3513, -1, -1, 3514, -1, + -1, -1, -1, 3515, -1, -1, -1, -1, + -1, -1, -1, 3516, 3518, -1, -1, -1, + 3519, -1, -1, -1, -1, -1, -1, 3520, + 3521, 3522, -1, 3523, -1, -1, -1, -1, + 3524, -1, 3525, -1, -1, -1, -1, 3526, + -1, 3527, -1, 3528, -1, 3529, 3531, 3532, + -1, -1, -1, 3535, -1, -1, -1, -1, + -1, -1, 3536, 3538, -1, 3539, -1, 3540, + 3541, 3542, 3545, 3546, -1, -1, 3547, 3548, + -1, 3549, -1, -1, 3550, -1, -1, 3551, + 3553, -1, 3555, 3557, -1, 3558, -1, -1, + -1, 3559, -1, -1, 3560, 3561, -1, -1, + -1, -1, 3563, -1, -1, -1, 3565, -1, + 3566, 3567, -1, 3568, -1, 3569, -1, 3570, + -1, -1, -1, -1, 3573, -1, -1, 3574, + 3575, 3576, 3577, -1, 3578, 3581, -1, 3582, + -1, -1, 3584, 3585, 3586, 3587, 3588, -1, + /* 0x6500 */ + 3589, -1, -1, -1, 3590, 3591, 3592, -1, + 3593, -1, 3594, -1, -1, -1, -1, 3595, + -1, -1, 3596, -1, 3597, -1, 3598, -1, + -1, 3599, -1, 3600, 3601, 3603, -1, 3605, + -1, -1, 3606, 3608, 3609, -1, -1, -1, + 3610, -1, 3611, 3614, 3615, -1, -1, -1, + -1, -1, -1, -1, 3617, 3618, 3619, 3620, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3621, + 3625, 3628, -1, -1, 3629, 3630, 3632, 3633, + -1, -1, -1, -1, -1, 3634, -1, 3636, + 3638, 3640, -1, 3641, -1, -1, 3643, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3644, -1, -1, -1, -1, -1, -1, + 3649, -1, -1, -1, -1, 3650, -1, 3651, + 3652, -1, 3653, -1, -1, -1, -1, -1, + -1, 3657, 3658, 3660, -1, 3661, 3666, -1, + 3671, 3676, 3680, 3684, 3686, 3688, 3689, -1, + -1, -1, -1, 3691, 3692, 3694, -1, 3695, + -1, -1, -1, -1, -1, -1, 3700, 3702, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3703, -1, -1, 3704, 3705, -1, -1, + -1, -1, 3706, -1, -1, 3707, -1, 3708, + -1, -1, -1, -1, 3709, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 3712, 3713, -1, -1, -1, -1, -1, -1, + -1, -1, 3714, -1, -1, -1, -1, 3715, + 3717, 3719, -1, 3721, -1, -1, -1, -1, + 3722, -1, -1, -1, -1, 3723, -1, 3724, + -1, -1, 3725, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3728, 3730, + 3733, 3734, 3736, -1, -1, -1, 3737, 3738, + /* 0x6600 */ + -1, -1, 3739, -1, -1, -1, -1, 3740, + -1, -1, 3742, -1, -1, -1, 3743, 3744, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3745, 3746, -1, -1, -1, -1, 3747, + -1, -1, -1, -1, -1, 3748, 3749, -1, + -1, -1, -1, -1, 3750, 3751, -1, 3752, + 3753, -1, -1, -1, -1, -1, -1, -1, + 3754, -1, -1, 3755, 3756, 3758, 3759, 3761, + -1, -1, 3763, 3765, 3766, -1, -1, -1, + -1, 3767, -1, 3768, -1, -1, -1, -1, + -1, -1, 3769, 3770, 3772, 3773, 3774, -1, + -1, -1, 3775, -1, -1, 3776, -1, 3778, + 3779, -1, -1, -1, 3780, -1, -1, -1, + 3781, 3782, -1, -1, -1, -1, 3783, -1, + -1, -1, -1, -1, 3784, -1, -1, -1, + -1, -1, -1, 3786, -1, -1, -1, -1, + 3787, 3788, 3790, 3791, -1, -1, -1, -1, + 3793, 3794, -1, -1, -1, -1, -1, -1, + -1, -1, 3795, -1, -1, -1, 3796, 3798, + 3803, -1, -1, -1, 3804, -1, -1, -1, + -1, -1, 3805, -1, 3806, -1, 3809, 3812, + 3813, -1, -1, 3814, -1, 3815, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 3817, -1, -1, -1, -1, -1, -1, -1, + -1, 3819, -1, -1, 3820, -1, 3821, 3825, + -1, 3826, -1, -1, 3828, 3832, -1, 3833, + -1, -1, -1, -1, -1, -1, 3834, -1, + -1, -1, -1, -1, -1, -1, -1, 3835, + 3836, -1, -1, -1, -1, -1, -1, -1, + 3838, -1, -1, -1, 3839, -1, -1, -1, + -1, -1, 3840, 3845, -1, 3846, -1, -1, + 3847, 3850, 3851, 3852, -1, 3854, 3855, -1, + /* 0x6700 */ + 3856, -1, 3857, 3859, -1, -1, -1, 3860, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3861, 3862, + -1, 3863, -1, 3864, -1, -1, 3865, 3866, + -1, -1, 3867, -1, -1, -1, -1, 3868, + -1, -1, -1, -1, 3869, 3871, 3872, 3873, + -1, 3875, -1, -1, 3876, 3878, 3879, -1, + -1, -1, 3880, -1, -1, -1, -1, -1, + 3882, -1, 3883, 3886, -1, -1, 3888, 3889, + -1, 3890, -1, -1, -1, -1, -1, -1, + -1, 3893, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 3894, 3895, -1, -1, 3896, 3897, 3898, -1, + 3899, 3900, -1, -1, -1, -1, -1, 3901, + 3903, 3904, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3905, 3911, + 3912, 3917, -1, -1, 3918, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3920, + -1, -1, 3921, -1, -1, -1, -1, -1, + -1, 3925, -1, -1, 3928, -1, 3929, -1, + -1, 3930, 3931, 3932, -1, 3933, 3934, 3935, + 3936, 3937, 3942, 3945, -1, 3946, -1, -1, + -1, 3947, -1, -1, 3950, -1, -1, -1, + -1, -1, -1, 3952, -1, -1, -1, -1, + -1, 3953, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3954, + -1, -1, -1, -1, -1, 3955, -1, 3956, + -1, -1, -1, -1, 3961, -1, -1, -1, + 3962, -1, -1, -1, -1, 3963, -1, -1, + -1, 3964, -1, -1, -1, -1, -1, -1, + 3966, -1, -1, 3967, -1, 3970, -1, -1, + -1, 3971, 3972, 3974, -1, 3975, 3976, 3978, + /* 0x6800 */ + 3979, 3980, -1, 3983, 3985, 3987, -1, 3988, + 3989, 3991, 3992, 3994, 3995, -1, 3997, 3999, + -1, 4001, -1, -1, -1, -1, 4002, 4004, + -1, -1, -1, -1, -1, -1, 4006, -1, + -1, -1, 4007, -1, -1, -1, -1, 4008, + -1, -1, -1, -1, -1, -1, -1, -1, + 4009, -1, -1, -1, -1, -1, -1, 4011, + 4013, -1, -1, -1, -1, -1, 4014, -1, + -1, -1, 4016, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4017, -1, -1, -1, + -1, 4019, 4020, -1, -1, -1, -1, -1, + 4021, -1, -1, -1, 4022, 4024, -1, 4025, + 4027, 4030, 4031, 4032, 4033, 4034, 4036, 4037, + 4038, 4039, 4040, -1, -1, -1, 4041, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4043, 4044, -1, 4047, -1, -1, 4048, + -1, 4049, -1, -1, 4051, 4052, -1, -1, + -1, -1, -1, -1, -1, 4054, -1, -1, + -1, -1, -1, -1, 4056, -1, -1, -1, + 4057, -1, -1, -1, -1, 4058, -1, 4059, + -1, -1, -1, -1, -1, 4060, 4065, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4067, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4069, -1, 4070, 4071, + 4072, -1, 4074, -1, 4075, -1, -1, -1, + -1, -1, 4076, 4080, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 4084, 4085, 4086, + -1, -1, -1, -1, -1, -1, -1, 4087, + -1, -1, -1, -1, -1, 4088, -1, 4089, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4091, 4092, -1, -1, -1, 4094, -1, + -1, 4095, -1, -1, -1, -1, -1, -1, + /* 0x6900 */ + 4096, 4097, -1, -1, -1, -1, -1, -1, + -1, 4098, -1, -1, -1, -1, 4100, 4101, + -1, -1, -1, -1, -1, -1, -1, 4104, + 4106, 4107, -1, -1, 4108, -1, -1, 4110, + 4111, -1, 4112, -1, 4113, -1, -1, -1, + -1, -1, -1, 4114, -1, 4115, -1, -1, + 4116, -1, -1, -1, 4117, -1, 4118, -1, + -1, 4119, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4120, -1, -1, 4121, -1, -1, + -1, -1, -1, 4123, -1, 4124, -1, -1, + -1, 4125, 4126, -1, -1, -1, -1, -1, + 4127, 4128, -1, -1, -1, 4129, 4130, -1, + 4131, -1, 4132, 4133, -1, 4134, -1, -1, + -1, -1, -1, 4135, -1, 4137, -1, -1, + -1, -1, -1, -1, 4138, 4139, -1, 4141, + -1, -1, -1, -1, 4142, 4143, 4144, 4145, + 4146, 4147, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4149, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4150, -1, + 4152, -1, 4153, -1, -1, -1, 4154, -1, + -1, -1, 4156, -1, 4157, -1, -1, -1, + -1, -1, -1, -1, 4158, -1, -1, 4159, + -1, -1, -1, -1, -1, -1, -1, 4160, + 4161, -1, -1, 4163, -1, 4164, -1, -1, + -1, 4165, -1, 4167, 4168, 4170, -1, 4172, + 4174, 4176, 4177, 4178, -1, -1, 4180, 4181, + 4182, -1, -1, -1, 4183, -1, -1, 4184, + 4185, -1, -1, -1, -1, -1, -1, -1, + -1, 4186, -1, 4187, -1, -1, 4188, -1, + -1, 4189, -1, -1, -1, -1, -1, -1, + /* 0x6a00 */ + -1, 4190, 4191, 4193, -1, 4194, -1, -1, + -1, -1, 4195, -1, -1, -1, -1, -1, + 4196, 4197, 4199, 4200, -1, -1, -1, -1, + -1, 4201, -1, -1, -1, -1, 4202, -1, + -1, -1, -1, 4203, -1, -1, -1, -1, + -1, 4205, 4207, -1, -1, -1, -1, 4209, + -1, 4211, -1, 4213, -1, -1, -1, 4214, + 4218, 4220, 4221, -1, -1, 4222, -1, 4223, + -1, -1, -1, 4224, -1, -1, -1, -1, + 4226, -1, 4227, 4228, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 4230, + -1, -1, 4231, -1, -1, -1, -1, -1, + -1, -1, -1, 4233, -1, -1, 4235, -1, + 4238, 4239, -1, -1, -1, -1, -1, -1, + -1, 4240, -1, -1, 4243, -1, -1, -1, + -1, 4244, -1, 4245, -1, -1, 4246, -1, + -1, 4247, -1, -1, -1, -1, -1, 4248, + 4250, -1, -1, -1, 4251, -1, -1, 4252, + 4254, -1, -1, -1, 4255, 4256, -1, 4257, + -1, -1, 4258, 4260, -1, -1, -1, -1, + -1, 4261, 4262, -1, -1, -1, 4264, 4265, + -1, 4267, -1, 4271, -1, -1, -1, -1, + 4272, -1, -1, 4273, -1, -1, -1, -1, + 4274, 4278, 4279, 4280, -1, -1, -1, -1, + 4281, -1, -1, -1, 4282, -1, 4283, -1, + -1, -1, -1, 4285, 4287, 4288, -1, -1, + -1, -1, 4289, 4290, -1, 4291, 4292, 4293, + -1, -1, -1, -1, -1, 4295, -1, 4296, + 4297, -1, 4298, -1, 4299, -1, -1, -1, + -1, -1, -1, 4300, -1, -1, -1, -1, + 4301, -1, 4302, 4303, -1, 4305, -1, -1, + /* 0x6b00 */ + -1, -1, -1, -1, 4306, 4308, -1, -1, + -1, 4309, 4313, -1, -1, -1, -1, 4315, + -1, 4316, 4317, -1, -1, -1, 4319, 4320, + -1, -1, -1, -1, -1, 4322, 4325, -1, + 4327, -1, 4329, 4333, 4336, -1, -1, 4337, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4338, -1, -1, 4339, -1, -1, + -1, -1, -1, 4340, -1, 4341, 4342, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4343, -1, 4344, -1, + 4346, -1, -1, 4347, -1, -1, 4349, -1, + 4352, -1, -1, 4353, -1, 4355, -1, 4356, + -1, 4357, -1, -1, -1, 4359, -1, -1, + 4361, 4363, -1, -1, 4365, -1, 4366, 4369, + -1, -1, 4371, 4375, 4379, -1, -1, 4382, + 4385, 4388, 4389, -1, 4390, -1, 4392, 4396, + 4400, 4401, -1, -1, -1, -1, -1, 4405, + -1, -1, -1, 4406, -1, -1, -1, -1, + -1, -1, 4407, 4408, -1, -1, -1, -1, + 4409, -1, 4410, -1, -1, -1, 4411, -1, + -1, 4412, -1, -1, 4413, -1, -1, -1, + -1, -1, -1, 4414, -1, -1, 4415, 4416, + -1, 4417, 4419, -1, 4421, -1, -1, 4422, + -1, -1, 4423, 4424, 4426, -1, -1, -1, + 4428, 4429, 4432, -1, -1, -1, 4433, -1, + -1, 4434, -1, -1, -1, -1, 4436, 4437, + -1, -1, -1, 4438, 4440, 4441, -1, 4442, + 4443, 4444, -1, -1, -1, -1, -1, 4445, + -1, 4446, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4447, -1, 4448, -1, + -1, -1, -1, -1, -1, 4449, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 4450, + /* 0x6c00 */ + -1, -1, 4451, -1, -1, -1, -1, 4453, + 4454, -1, 4456, -1, 4457, -1, -1, -1, + -1, -1, -1, -1, 4458, -1, -1, 4461, + -1, -1, -1, 4464, -1, -1, -1, -1, + -1, -1, 4465, 4466, -1, -1, -1, -1, + -1, 4469, -1, 4470, 4471, -1, -1, -1, + -1, -1, 4472, 4473, 4474, 4476, -1, 4478, + -1, -1, 4481, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 4483, + -1, 4487, -1, -1, -1, -1, 4488, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4489, 4491, -1, -1, -1, -1, -1, + -1, 4493, -1, -1, 4495, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4496, 4497, -1, -1, -1, + -1, 4498, 4499, 4500, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 4501, 4503, -1, -1, -1, -1, -1, -1, + -1, -1, 4504, -1, -1, -1, 4505, 4506, + -1, -1, -1, -1, -1, -1, -1, 4507, + -1, 4508, 4513, 4515, 4516, 4517, 4518, 4519, + 4520, 4521, 4522, -1, -1, -1, 4524, -1, + -1, 4525, 4526, -1, -1, 4527, -1, -1, + -1, -1, -1, -1, -1, -1, 4528, -1, + -1, 4529, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 4530, -1, -1, + -1, -1, -1, 4532, -1, 4533, 4534, -1, + -1, -1, -1, -1, -1, 4535, -1, -1, + 4536, -1, 4537, -1, -1, -1, -1, 4539, + 4540, -1, -1, -1, -1, -1, 4541, 4542, + 4544, -1, 4545, 4546, 4547, 4550, 4552, -1, + /* 0x6d00 */ + -1, 4553, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4554, -1, -1, -1, + -1, -1, 4555, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 4556, + -1, -1, -1, -1, -1, -1, 4557, -1, + -1, -1, -1, -1, 4558, -1, -1, -1, + 4559, -1, -1, 4560, 4561, 4562, 4563, 4564, + 4565, 4566, 4567, 4568, -1, 4569, 4570, 4572, + 4574, 4575, 4576, 4577, 4578, 4579, -1, -1, + -1, -1, -1, -1, 4580, -1, -1, -1, + -1, -1, -1, 4583, -1, -1, -1, 4584, + -1, 4587, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4588, -1, -1, 4589, -1, -1, -1, + -1, -1, 4590, -1, -1, 4592, -1, 4593, + -1, 4594, -1, -1, 4595, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4596, -1, + -1, 4598, -1, 4600, 4601, 4603, 4604, 4605, + 4606, 4607, 4608, 4609, 4610, -1, 4611, 4612, + 4614, 4615, -1, -1, -1, -1, -1, 4619, + -1, -1, -1, -1, -1, -1, -1, -1, + 4620, -1, -1, -1, 4621, -1, -1, -1, + 4622, -1, -1, -1, 4623, -1, -1, -1, + -1, -1, -1, 4624, -1, -1, -1, -1, + -1, -1, 4625, -1, -1, -1, -1, -1, + -1, -1, 4626, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 4628, -1, -1, + 4629, -1, 4631, 4632, -1, -1, -1, -1, + -1, -1, -1, 4634, -1, 4635, 4638, -1, + 4639, -1, 4640, 4641, -1, -1, -1, -1, + /* 0x6e00 */ + -1, -1, -1, -1, -1, 4642, -1, 4643, + 4644, 4646, 4647, 4650, 4654, 4655, 4656, -1, + 4658, 4659, -1, 4660, 4664, 4665, 4668, 4669, + -1, 4670, -1, 4671, -1, -1, -1, -1, + -1, -1, 4672, -1, -1, -1, 4673, -1, + -1, 4674, -1, -1, 4675, -1, -1, -1, + -1, -1, -1, -1, 4676, -1, -1, -1, + 4677, -1, -1, -1, -1, -1, 4679, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4680, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4681, -1, + -1, -1, -1, -1, -1, -1, -1, 4682, + -1, -1, -1, -1, -1, -1, -1, 4683, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4684, 4685, 4686, 4687, 4688, + 4690, 4692, 4693, 4694, -1, 4695, -1, 4696, + -1, 4697, -1, -1, 4698, -1, -1, -1, + 4701, -1, -1, -1, -1, 4702, 4704, -1, + -1, -1, -1, -1, 4706, 4707, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4708, 4712, -1, -1, 4713, 4714, + -1, -1, -1, 4716, -1, -1, 4717, -1, + -1, -1, -1, -1, 4719, -1, -1, -1, + -1, -1, -1, -1, 4721, 4722, -1, -1, + -1, -1, -1, -1, 4723, -1, 4724, -1, + -1, -1, -1, -1, -1, -1, -1, 4725, + -1, 4726, 4728, 4729, -1, 4730, 4732, 4733, + 4736, 4737, 4739, -1, 4740, 4741, 4742, -1, + 4743, 4746, 4747, -1, 4748, -1, -1, 4750, + -1, -1, 4751, -1, -1, -1, -1, 4752, + 4755, -1, -1, 4757, -1, -1, 4758, 4759, + /* 0x6f00 */ + -1, 4761, -1, -1, 4762, -1, 4763, -1, + -1, -1, 4764, -1, -1, -1, -1, -1, + -1, 4765, -1, 4766, -1, -1, -1, -1, + -1, -1, 4767, -1, -1, -1, -1, -1, + -1, -1, 4768, 4769, -1, -1, -1, 4770, + -1, -1, -1, 4773, 4774, -1, -1, -1, + -1, 4775, 4776, -1, -1, -1, -1, -1, + 4777, -1, -1, -1, -1, -1, -1, 4778, + -1, 4779, -1, -1, 4780, 4781, 4782, 4783, + -1, -1, -1, 4784, -1, 4785, -1, -1, + -1, 4786, -1, -1, 4789, -1, -1, -1, + -1, 4791, -1, 4792, 4794, -1, -1, -1, + -1, -1, -1, -1, 4796, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 4797, + 4798, -1, -1, -1, 4799, -1, -1, 4800, + -1, -1, -1, -1, -1, -1, -1, 4801, + 4802, 4806, 4810, -1, 4813, -1, 4816, 4817, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4818, -1, -1, 4819, -1, -1, 4820, + -1, -1, 4821, 4822, 4825, -1, -1, 4826, + 4828, -1, -1, 4829, 4830, -1, 4832, -1, + -1, 4833, -1, -1, -1, -1, 4834, -1, + 4835, 4836, -1, 4837, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4838, -1, 4839, -1, -1, -1, 4840, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4841, 4843, -1, 4844, 4845, -1, -1, + 4847, -1, 4848, 4850, 4852, -1, -1, 4853, + -1, -1, -1, -1, 4855, -1, -1, -1, + -1, -1, -1, 4856, -1, -1, -1, -1, + 4857, 4858, -1, 4861, -1, 4863, 4866, -1, + -1, -1, 4868, -1, 4869, -1, 4870, -1, + /* 0x7000 */ + -1, -1, 4871, -1, -1, 4874, 4875, -1, + -1, 4877, -1, 4878, -1, -1, -1, 4880, + -1, -1, -1, 4881, -1, 4884, -1, -1, + 4885, -1, -1, -1, -1, 4886, -1, 4887, + 4888, -1, -1, -1, -1, -1, 4889, 4890, + 4892, -1, -1, -1, 4894, -1, -1, 4896, + 4897, -1, 4898, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4900, -1, + -1, -1, -1, 4901, 4902, -1, -1, -1, + -1, -1, -1, 4903, 4905, -1, 4906, 4908, + -1, 4909, -1, -1, 4910, 4912, -1, -1, + 4913, -1, -1, -1, -1, 4914, -1, -1, + -1, -1, -1, 4915, 4916, -1, -1, 4917, + -1, -1, -1, -1, -1, 4918, 4919, 4921, + -1, -1, -1, -1, -1, 4922, 4925, -1, + -1, -1, -1, 4927, -1, 4929, 4931, 4933, + 4934, 4935, -1, -1, -1, -1, -1, -1, + -1, 4938, -1, -1, -1, 4941, 4943, 4944, + -1, -1, -1, -1, -1, -1, -1, 4945, + -1, -1, -1, -1, 4947, 4948, -1, -1, + -1, -1, -1, -1, 4949, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4954, 4957, + 4958, -1, -1, -1, -1, -1, -1, -1, + -1, 4959, 4960, -1, 4962, 4965, -1, -1, + -1, 4966, 4967, 4970, -1, -1, -1, -1, + -1, -1, 4971, -1, -1, -1, -1, 4972, + -1, -1, -1, -1, -1, -1, 4973, -1, + -1, -1, -1, 4975, -1, -1, -1, 4976, + -1, -1, -1, -1, -1, -1, 4977, 4978, + 4980, 4982, -1, 4983, 4984, 4985, -1, -1, + -1, 4986, -1, -1, 4987, -1, -1, -1, + -1, -1, -1, -1, -1, 4988, 4989, -1, + /* 0x7100 */ + -1, -1, -1, -1, -1, -1, -1, 4991, + 4992, -1, 4996, -1, -1, -1, -1, 4997, + -1, -1, -1, -1, 4998, 5000, 5001, -1, + 5002, -1, 5003, -1, -1, -1, -1, -1, + -1, 5005, -1, -1, -1, -1, 5006, -1, + -1, -1, -1, -1, -1, 5007, -1, -1, + 5008, -1, -1, 5010, -1, -1, -1, -1, + -1, -1, -1, -1, 5011, -1, -1, -1, + -1, -1, -1, -1, -1, 5013, -1, -1, + -1, 5014, -1, -1, -1, -1, -1, -1, + -1, 5017, 5018, -1, -1, 5019, 5023, 5024, + -1, 5025, -1, -1, -1, -1, -1, -1, + -1, -1, 5026, -1, -1, 5028, -1, 5029, + -1, 5033, -1, -1, 5034, -1, 5036, -1, + -1, -1, -1, -1, 5037, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 5039, -1, + -1, -1, -1, -1, -1, 5041, -1, -1, + 5043, -1, -1, -1, -1, -1, -1, 5047, + -1, -1, 5048, -1, 5049, -1, -1, 5051, + -1, 5052, -1, -1, -1, -1, -1, -1, + -1, -1, 5056, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 5057, 5058, 5059, -1, -1, -1, -1, + -1, 5060, 5061, -1, -1, -1, 5062, -1, + -1, 5063, -1, -1, 5065, -1, -1, -1, + 5067, -1, -1, -1, 5068, -1, 5070, -1, + 5071, -1, 5073, 5075, -1, 5077, -1, 5078, + -1, 5081, -1, -1, 5082, -1, -1, 5083, + -1, -1, -1, -1, -1, -1, 5085, -1, + -1, -1, -1, -1, 5086, 5087, -1, -1, + -1, -1, -1, 5088, 5092, -1, -1, -1, + -1, -1, -1, 5093, 5094, -1, 5095, 5096, + /* 0x7200 */ + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 5097, -1, -1, + 5098, -1, -1, -1, -1, -1, -1, 5099, + -1, -1, -1, 5101, -1, -1, -1, -1, + -1, -1, -1, -1, 5104, -1, -1, -1, + -1, -1, -1, -1, -1, 5107, -1, -1, + -1, 5108, 5109, -1, 5111, -1, -1, 5112, + -1, -1, 5113, -1, 5114, -1, 5115, 5118, + 5119, -1, -1, 5120, -1, 5121, 5122, -1, + -1, -1, -1, 5123, -1, 5124, 5125, -1, + -1, -1, -1, 5129, -1, 5130, -1, -1, + 5134, -1, -1, 5135, 5136, -1, -1, -1, + 5137, -1, -1, -1, -1, -1, 5138, -1, + -1, -1, -1, 5140, -1, -1, -1, -1, + -1, -1, -1, -1, 5142, 5143, -1, -1, + -1, -1, 5144, -1, -1, 5146, -1, -1, + -1, 5147, 5148, -1, -1, -1, -1, 5149, + -1, -1, 5150, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 5151, -1, + -1, -1, -1, 5152, -1, -1, -1, -1, + 5154, -1, 5156, -1, -1, -1, -1, 5157, + -1, -1, -1, -1, 5159, 5160, 5161, -1, + -1, -1, 5162, -1, 5163, -1, 5165, 5166, + 5167, 5168, -1, -1, -1, -1, -1, -1, + 5169, -1, 5170, -1, -1, -1, -1, -1, + 5172, 5173, -1, -1, 5174, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 5175, 5176, -1, + -1, -1, 5177, -1, -1, 5178, -1, -1, + -1, -1, -1, -1, 5179, 5180, 5181, 5182, + 5183, 5184, 5185, -1, -1, -1, -1, -1, + 5186, 5188, -1, -1, -1, 5189, 5190, -1, + /* 0x7300 */ + -1, -1, 5191, 5192, -1, -1, -1, 5193, + -1, -1, 5194, -1, -1, 5195, 5197, -1, + -1, -1, -1, -1, -1, 5199, -1, -1, + 5200, 5201, -1, -1, -1, -1, -1, 5202, + -1, 5204, -1, -1, -1, -1, -1, -1, + 5205, 5206, 5207, 5208, 5209, -1, 5210, 5211, + -1, -1, 5212, -1, -1, 5213, 5214, -1, + -1, -1, -1, 5215, -1, -1, -1, 5216, + -1, 5218, -1, -1, 5219, 5220, -1, -1, + -1, -1, -1, -1, -1, 5221, 5222, 5225, + 5226, -1, -1, -1, -1, -1, -1, -1, + 5227, 5228, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 5229, -1, -1, 5231, -1, + 5232, -1, 5233, 5234, -1, 5236, 5237, -1, + 5238, 5239, 5240, -1, -1, 5241, -1, 5243, + 5244, -1, 5246, 5247, 5248, -1, 5249, -1, + 5250, 5251, -1, 5252, -1, 5254, -1, 5255, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 5256, -1, -1, -1, -1, -1, -1, + -1, 5257, 5258, 5259, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 5260, 5262, -1, -1, -1, -1, 5263, 5264, + 5265, 5266, -1, 5267, -1, -1, -1, -1, + -1, -1, 5268, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 5269, -1, 5272, 5273, 5274, + 5276, 5277, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 5278, -1, -1, 5280, -1, -1, -1, + -1, -1, 5284, -1, -1, -1, -1, -1, + 5285, 5286, 5288, -1, -1, -1, -1, 5289, + -1, -1, -1, -1, -1, -1, 5290, -1, + /* 0x7400 */ + -1, -1, -1, 5291, -1, 5292, -1, -1, + -1, 5293, -1, -1, -1, 5296, 5298, 5299, + 5300, 5302, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 5304, -1, -1, 5305, -1, -1, -1, + -1, 5307, 5309, -1, 5310, -1, -1, 5311, + -1, -1, -1, -1, -1, -1, -1, 5312, + -1, -1, -1, 5313, -1, -1, -1, -1, + -1, -1, 5314, -1, -1, -1, -1, -1, + -1, 5315, -1, -1, -1, -1, -1, -1, + 5316, -1, -1, 5319, 5321, -1, -1, -1, + 5322, 5323, 5324, -1, -1, -1, -1, 5325, + 5326, -1, 5327, -1, 5328, -1, 5330, 5331, + 5332, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 5333, -1, -1, -1, 5335, + -1, 5336, -1, -1, -1, -1, 5337, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 5339, 5341, 5344, -1, -1, 5345, -1, + -1, -1, -1, 5346, -1, -1, -1, -1, + 5347, -1, -1, -1, -1, 5348, -1, -1, + 5349, -1, -1, -1, -1, 5350, -1, 5352, + -1, -1, -1, -1, -1, -1, -1, -1, + 5353, 5355, 5356, -1, 5357, -1, -1, 5358, + -1, -1, 5359, -1, 5360, -1, -1, -1, + -1, -1, 5362, -1, -1, -1, -1, -1, + -1, -1, -1, 5364, -1, -1, -1, -1, + 5365, -1, -1, -1, -1, -1, 5366, 5367, + -1, -1, -1, -1, -1, -1, 5368, 5370, + -1, -1, -1, -1, -1, -1, -1, -1, + /* 0x7500 */ + -1, 5371, -1, -1, -1, -1, 5373, -1, + -1, -1, -1, -1, 5374, -1, 5375, -1, + -1, -1, -1, -1, -1, 5378, 5379, -1, + -1, -1, -1, -1, -1, -1, 5381, -1, + 5384, -1, 5385, 5387, -1, -1, 5389, -1, + -1, -1, -1, -1, -1, -1, -1, 5392, + -1, -1, -1, -1, -1, 5398, -1, 5399, + -1, -1, 5400, 5402, 5407, 5409, -1, -1, + -1, -1, 5410, -1, 5411, 5413, 5414, -1, + -1, -1, 5418, -1, 5419, 5421, 5423, -1, + -1, 5424, 5425, -1, -1, -1, -1, -1, + -1, 5429, 5431, -1, -1, 5432, 5437, -1, + 5441, 5442, 5443, -1, -1, 5444, -1, 5445, + 5446, -1, 5447, 5448, -1, -1, -1, -1, + 5450, 5451, -1, 5453, 5457, 5458, 5460, -1, + -1, -1, 5461, 5462, -1, -1, -1, -1, + -1, -1, 5463, -1, -1, 5467, 5469, 5470, + -1, 5471, 5475, -1, -1, -1, 5479, 5481, + -1, -1, -1, -1, -1, -1, 5483, 5484, + -1, -1, -1, -1, -1, -1, -1, 5485, + 5486, 5487, -1, 5488, -1, -1, -1, -1, + -1, -1, -1, -1, 5489, 5490, 5491, 5492, + -1, 5493, -1, -1, 5495, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 5496, + 5497, 5498, -1, -1, -1, -1, -1, -1, + -1, -1, 5499, -1, -1, -1, 5500, -1, + -1, 5504, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 5505, 5506, 5507, 5508, -1, -1, 5509, -1, + -1, -1, 5510, 5512, 5515, -1, -1, -1, + -1, 5516, 5517, -1, -1, -1, 5518, -1, + /* 0x7600 */ + -1, -1, 5519, -1, -1, 5523, 5524, -1, + -1, 5525, -1, 5527, -1, 5528, -1, -1, + -1, -1, -1, 5529, -1, -1, 5530, 5531, + 5532, -1, -1, -1, -1, -1, 5533, -1, + -1, 5534, -1, -1, 5535, -1, 5536, 5537, + -1, -1, 5538, 5539, -1, -1, 5540, -1, + -1, -1, 5541, -1, -1, -1, -1, -1, + -1, -1, 5542, 5543, -1, -1, 5545, 5546, + -1, -1, 5547, -1, 5548, 5550, 5551, 5552, + -1, 5553, -1, -1, -1, -1, -1, -1, + -1, -1, 5554, -1, -1, 5556, -1, -1, + 5558, -1, -1, -1, -1, -1, 5559, 5560, + -1, 5561, 5562, 5563, 5564, 5565, -1, 5566, + -1, 5567, -1, 5568, 5569, 5570, 5571, 5572, + 5573, 5576, 5577, -1, 5578, 5579, -1, -1, + -1, -1, 5580, 5590, 5591, -1, -1, -1, + -1, 5593, 5595, 5597, -1, -1, -1, -1, + 5598, -1, -1, 5601, -1, 5602, 5604, -1, + 5605, 5606, -1, -1, -1, -1, -1, -1, + -1, -1, 5607, -1, -1, -1, 5609, -1, + -1, 5610, -1, -1, -1, 5611, -1, -1, + 5613, -1, -1, -1, -1, -1, -1, -1, + 5614, 5616, 5617, -1, -1, -1, -1, 5619, + 5620, 5622, 5624, -1, 5625, -1, -1, -1, + -1, 5626, -1, 5627, -1, -1, -1, 5629, + 5630, -1, -1, 5631, 5634, 5635, -1, 5636, + 5637, 5639, -1, -1, -1, -1, 5641, 5643, + 5644, 5645, -1, -1, 5646, -1, 5647, -1, + -1, 5648, -1, 5649, 5651, -1, -1, 5652, + -1, -1, 5653, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + /* 0x7700 */ + -1, -1, -1, -1, -1, -1, 5655, -1, + -1, 5657, -1, -1, 5658, 5660, 5661, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 5663, -1, -1, -1, -1, -1, 5664, 5665, + -1, -1, -1, -1, -1, 5666, 5667, -1, + -1, -1, -1, 5668, 5669, -1, -1, 5670, + -1, -1, -1, -1, -1, -1, -1, 5672, + -1, -1, -1, -1, -1, -1, 5673, -1, + 5676, 5677, 5678, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 5679, + 5680, 5681, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 5682, -1, 5683, -1, + 5684, -1, -1, -1, 5685, 5686, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 5687, -1, -1, -1, -1, -1, 5688, + -1, -1, -1, -1, -1, 5690, 5691, 5692, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 5693, -1, -1, -1, 5694, -1, + 5695, -1, -1, -1, -1, -1, 5696, -1, + 5697, -1, 5698, -1, -1, -1, -1, -1, + -1, 5699, 5700, -1, -1, 5701, -1, -1, + 5703, -1, -1, -1, -1, -1, 5704, -1, + -1, -1, -1, -1, 5705, -1, 5706, -1, + -1, 5710, -1, -1, -1, -1, -1, 5711, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 5712, 5713, -1, -1, -1, -1, + -1, 5714, 5715, -1, -1, -1, -1, -1, + -1, -1, 5716, -1, 5717, -1, 5719, 5720, + -1, -1, -1, 5722, -1, -1, -1, 5723, + -1, -1, -1, -1, 5724, -1, 5727, -1, + -1, -1, -1, -1, -1, -1, 5728, 5729, + /* 0x7800 */ + 5734, 5735, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 5736, -1, -1, 5737, 5738, 5741, + -1, -1, 5742, -1, 5743, -1, -1, -1, + -1, -1, -1, -1, -1, 5744, -1, 5745, + -1, -1, -1, -1, 5746, -1, -1, -1, + -1, -1, 5747, -1, -1, -1, -1, -1, + -1, -1, 5750, 5751, -1, -1, 5752, 5753, + 5758, 5759, -1, 5760, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 5761, 5762, 5763, + -1, 5764, 5765, -1, 5766, -1, -1, -1, + -1, -1, -1, -1, 5767, -1, -1, -1, + 5768, -1, 5769, -1, -1, -1, 5770, 5773, + -1, -1, -1, -1, -1, 5774, -1, 5775, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 5778, -1, -1, -1, -1, -1, 5782, + -1, -1, -1, -1, -1, 5784, 5785, -1, + -1, -1, -1, -1, 5786, 5787, -1, 5790, + -1, -1, -1, 5793, 5794, -1, 5795, 5798, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 5799, 5800, -1, -1, 5801, -1, 5802, + 5803, 5805, -1, -1, -1, -1, -1, -1, + 5807, -1, 5808, 5810, 5812, -1, -1, -1, + -1, 5813, -1, -1, -1, -1, -1, 5814, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 5815, 5816, -1, 5817, -1, 5818, -1, + -1, -1, 5819, -1, -1, -1, -1, -1, + 5822, -1, -1, 5823, -1, -1, -1, 5824, + -1, -1, -1, -1, -1, -1, -1, 5825, + -1, -1, -1, -1, -1, -1, -1, 5826, + 5827, -1, 5828, -1, -1, 5829, -1, -1, + /* 0x7900 */ + 5830, -1, -1, -1, 5831, -1, 5832, -1, + 5835, -1, -1, -1, -1, -1, 5837, -1, + -1, -1, 5838, -1, -1, -1, -1, -1, + -1, 5839, -1, -1, -1, -1, -1, 5840, + 5843, -1, -1, -1, -1, -1, 5844, -1, + -1, -1, 5849, 5850, 5851, -1, 5852, -1, + -1, 5855, -1, -1, -1, -1, -1, -1, + -1, -1, 5856, 5857, 5858, -1, -1, 5859, + 5860, -1, -1, 5861, -1, 5862, -1, -1, + -1, -1, -1, -1, -1, -1, 5863, -1, + -1, -1, -1, -1, -1, 5864, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 5865, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 5866, + -1, -1, -1, -1, -1, 5867, -1, 5868, + 5869, -1, -1, -1, -1, -1, -1, 5870, + 5871, -1, -1, -1, 5872, 5873, -1, -1, + -1, -1, -1, -1, -1, 5874, 5875, -1, + -1, -1, -1, -1, -1, 5876, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 5877, -1, -1, -1, -1, 5878, -1, + -1, 5879, 5880, -1, -1, -1, 5881, -1, + 5882, 5883, -1, -1, 5884, -1, -1, -1, + -1, -1, -1, 5885, -1, -1, -1, 5886, + -1, 5887, -1, 5888, -1, -1, 5889, 5890, + 5895, -1, 5896, 5897, 5902, 5905, -1, -1, + 5906, -1, -1, -1, 5907, 5909, 5910, 5911, + 5912, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 5913, + 5914, -1, -1, -1, -1, -1, -1, -1, + 5916, -1, -1, -1, -1, 5917, 5918, -1, + /* 0x7a00 */ + -1, 5919, -1, -1, -1, 5923, 5924, -1, + 5926, 5927, -1, -1, -1, -1, 5929, -1, + -1, -1, -1, -1, -1, -1, -1, 5930, + -1, -1, 5932, -1, 5934, -1, -1, 5935, + -1, -1, -1, 5936, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 5937, 5938, -1, + -1, 5939, 5941, 5942, -1, -1, -1, -1, + -1, -1, 5944, 5946, -1, -1, 5947, 5951, + 5955, -1, 5957, -1, -1, 5958, -1, -1, + -1, 5960, -1, -1, 5962, 5966, 5967, 5969, + 5971, 5974, -1, -1, -1, -1, -1, 5975, + -1, -1, -1, -1, -1, -1, 5976, -1, + 5978, 5979, 5980, 5981, -1, -1, -1, -1, + 5982, 5986, 5988, 5990, -1, 5991, -1, -1, + 5993, -1, -1, -1, -1, -1, -1, 5994, + -1, 5996, -1, -1, -1, 5997, -1, -1, + -1, 5998, -1, 5999, -1, -1, -1, -1, + -1, -1, 6000, -1, -1, 6001, 6002, -1, + -1, 6003, -1, 6005, -1, -1, -1, 6009, + -1, -1, -1, -1, 6013, 6014, -1, -1, + -1, -1, -1, -1, -1, 6015, 6016, -1, + -1, 6017, 6018, -1, 6019, 6020, 6022, 6024, + 6026, -1, -1, 6028, -1, 6029, 6030, -1, + -1, -1, 6032, 6033, -1, -1, -1, -1, + -1, -1, -1, 6037, 6039, 6040, 6041, 6043, + 6044, -1, 6046, -1, -1, -1, -1, -1, + -1, -1, 6047, -1, -1, -1, 6048, -1, + -1, -1, 6050, -1, 6051, 6053, 6056, -1, + -1, -1, 6058, -1, -1, -1, -1, -1, + -1, 6059, 6061, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 6063, -1, + 6065, -1, -1, -1, -1, -1, 6067, -1, + /* 0x7b00 */ + -1, -1, -1, 6068, -1, -1, -1, -1, + -1, -1, -1, 6069, -1, -1, -1, -1, + -1, 6071, -1, -1, 6073, 6074, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 6075, + -1, -1, -1, -1, -1, -1, -1, 6076, + 6082, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 6083, 6085, -1, + -1, -1, 6086, -1, 6088, -1, 6090, -1, + -1, -1, -1, -1, -1, 6091, 6092, -1, + -1, -1, -1, 6093, -1, 6094, -1, 6096, + 6098, 6099, -1, -1, -1, -1, 6100, -1, + 6104, 6105, 6106, 6107, 6108, 6109, 6110, -1, + -1, -1, -1, -1, -1, -1, -1, 6114, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 6115, -1, -1, -1, -1, -1, -1, + -1, 6116, 6117, -1, 6118, -1, 6119, 6122, + 6123, -1, 6124, -1, -1, -1, 6125, 6126, + -1, -1, -1, 6129, -1, 6130, -1, 6131, + -1, -1, 6132, 6133, -1, -1, -1, -1, + -1, -1, 6134, -1, -1, -1, -1, -1, + -1, -1, -1, 6135, -1, -1, 6139, 6141, + 6142, 6143, 6144, 6145, 6146, -1, -1, -1, + 6147, -1, 6149, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 6150, -1, -1, -1, 6151, -1, 6153, -1, + -1, 6154, -1, 6155, -1, -1, -1, 6157, + -1, 6158, -1, 6159, 6160, -1, -1, 6161, + -1, -1, -1, 6162, -1, -1, -1, -1, + 6163, 6165, -1, -1, 6166, -1, 6167, -1, + -1, 6168, 6171, -1, -1, 6172, 6174, 6175, + -1, 6176, 6177, 6178, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + /* 0x7c00 */ + 6179, 6181, -1, -1, 6183, -1, 6185, -1, + -1, -1, -1, -1, -1, 6186, -1, -1, + -1, 6187, 6189, -1, 6190, -1, 6192, 6193, + 6195, -1, -1, -1, -1, -1, 6196, -1, + 6197, 6198, -1, 6199, -1, -1, -1, -1, + -1, -1, 6200, 6201, -1, -1, -1, -1, + -1, 6203, -1, -1, -1, -1, -1, 6205, + -1, 6206, -1, -1, -1, 6207, 6208, -1, + 6209, 6211, -1, 6212, -1, -1, 6213, -1, + -1, -1, -1, -1, 6214, -1, -1, 6215, + 6217, -1, 6218, -1, 6219, 6221, 6222, -1, + 6224, 6226, -1, 6227, 6228, -1, -1, 6229, + 6230, -1, -1, -1, 6232, -1, -1, -1, + -1, 6234, 6235, -1, 6236, 6237, 6239, -1, + -1, -1, 6240, -1, 6242, -1, -1, -1, + -1, -1, -1, 6243, 6244, -1, -1, -1, + -1, -1, -1, 6245, -1, -1, -1, 6246, + -1, -1, -1, 6248, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 6249, + 6250, -1, -1, 6251, 6253, 6254, -1, -1, + -1, -1, -1, -1, 6255, 6256, 6258, 6259, + -1, -1, 6263, -1, 6264, -1, 6268, -1, + -1, -1, -1, 6269, -1, 6271, -1, -1, + -1, 6272, 6273, -1, -1, 6274, -1, -1, + -1, 6275, -1, -1, -1, -1, 6276, 6281, + -1, 6282, 6283, -1, -1, -1, -1, -1, + -1, -1, -1, 6284, -1, 6286, -1, -1, + -1, -1, 6287, -1, -1, 6291, 6292, -1, + 6293, -1, -1, -1, -1, -1, 6295, 6296, + -1, -1, -1, -1, -1, -1, -1, -1, + 6297, -1, 6299, -1, 6300, -1, 6301, -1, + 6302, 6306, 6308, 6309, 6313, -1, 6315, 6317, + /* 0x7d00 */ + 6319, -1, 6320, -1, 6321, 6322, 6323, 6324, + 6325, 6326, -1, 6327, -1, 6328, -1, -1, + 6329, -1, -1, 6330, 6331, 6332, 6333, 6334, + 6335, 6337, 6339, 6340, 6341, 6342, -1, -1, + -1, 6344, -1, 6345, -1, 6346, -1, 6347, + -1, -1, -1, -1, 6348, -1, 6350, 6352, + 6356, 6357, 6358, 6359, -1, 6360, -1, -1, + -1, 6361, 6362, -1, 6363, -1, -1, 6364, + 6365, -1, 6366, 6367, 6368, 6369, 6370, -1, + 6372, -1, -1, 6373, 6374, 6376, 6377, 6378, + 6379, -1, -1, -1, -1, 6380, 6383, -1, + -1, -1, 6384, 6385, -1, 6387, 6389, -1, + -1, 6390, 6391, -1, 6392, 6396, 6397, -1, + 6398, -1, -1, -1, -1, -1, -1, -1, + 6399, 6400, 6402, 6404, -1, 6405, 6407, 6410, + 6411, 6413, -1, -1, -1, -1, -1, -1, + -1, 6414, 6415, 6417, -1, -1, 6418, -1, + 6419, 6420, -1, 6421, 6422, -1, -1, 6423, + -1, 6424, -1, 6426, -1, -1, -1, 6428, + -1, 6429, 6431, -1, 6434, -1, 6435, -1, + 6436, -1, 6438, 6440, -1, -1, -1, -1, + -1, -1, -1, 6441, 6445, 6446, -1, 6447, + 6448, 6449, 6450, 6451, 6453, 6455, -1, 6456, + 6457, 6458, 6459, 6460, -1, 6461, 6463, 6464, + -1, -1, -1, -1, 6465, -1, -1, 6466, + -1, -1, 6467, 6468, -1, 6469, -1, 6470, + 6474, 6475, 6477, -1, 6479, 6480, 6481, 6483, + 6484, 6485, 6486, -1, 6490, 6491, 6492, -1, + 6493, 6494, -1, 6496, -1, 6498, 6499, -1, + 6500, 6501, 6502, 6503, 6507, -1, -1, 6508, + -1, 6509, 6510, -1, 6511, -1, 6512, -1, + -1, 6513, -1, 6514, 6515, -1, -1, -1, + /* 0x7e00 */ + -1, 6517, -1, -1, 6519, -1, -1, -1, + 6521, 6522, 6523, 6524, -1, -1, -1, -1, + 6525, 6526, -1, -1, -1, 6527, -1, 6529, + 6530, -1, -1, 6533, -1, 6534, 6535, 6536, + -1, -1, -1, 6537, -1, -1, 6539, 6541, + 6543, -1, -1, 6544, -1, 6545, 6546, -1, + -1, 6547, 6549, -1, 6552, 6553, 6554, 6556, + -1, 6557, -1, -1, -1, 6558, 6563, -1, + -1, 6564, -1, 6565, -1, 6567, 6569, -1, + 6570, -1, 6571, 6574, -1, 6577, -1, -1, + -1, -1, 6579, -1, 6580, 6581, 6582, -1, + -1, 6584, 6585, 6586, -1, -1, 6587, -1, + -1, 6588, 6590, -1, 6591, -1, 6592, -1, + -1, 6593, 6595, 6597, -1, 6600, 6603, 6605, + 6606, -1, -1, 6609, -1, -1, -1, -1, + -1, 6610, -1, -1, 6611, 6613, 6614, 6615, + -1, -1, 6616, 6617, -1, -1, -1, 6618, + 6619, 6620, 6622, -1, 6624, 6627, 6628, 6631, + -1, -1, 6633, 6635, 6636, -1, 6637, -1, + 6640, -1, -1, -1, 6642, 6643, -1, 6646, + 6648, 6649, 6650, 6651, 6652, 6656, 6657, 6658, + 6659, 6660, 6662, 6663, 6664, 6665, 6666, 6667, + 6668, 6669, 6670, 6671, 6672, 6673, 6675, 6676, + 6677, 6678, 6679, 6680, 6681, 6682, 6683, 6684, + 6688, 6689, 6691, 6692, 6693, 6694, 6695, 6696, + 6697, 6698, 6699, 6700, 6701, 6702, 6703, 6704, + 6706, 6707, 6708, 6709, 6710, 6711, 6713, 6714, + 6715, 6717, 6718, 6719, 6720, 6721, 6724, 6725, + 6727, 6728, 6729, 6730, 6733, 6734, 6735, 6737, + 6739, 6740, 6741, 6743, -1, 6744, 6746, 6747, + 6748, 6749, 6750, 6751, 6753, 6754, 6756, 6757, + 6759, 6761, 6762, 6763, 6764, 6765, 6766, 6767, + /* 0x7f00 */ + 6769, 6770, 6771, 6772, 6773, 6774, 6775, 6776, + 6777, 6778, 6779, 6781, 6782, 6783, 6784, 6785, + 6786, 6790, 6791, 6792, 6793, 6794, 6795, 6796, + 6797, 6799, 6800, 6801, 6802, 6803, 6804, 6805, + 6806, 6808, 6809, 6810, 6811, 6812, 6813, 6814, + 6817, 6818, 6819, 6820, 6822, 6823, 6824, 6825, + 6826, 6828, 6829, 6830, 6831, 6832, 6834, 6837, + 6838, 6839, 6840, 6842, 6843, 6845, 6848, -1, + -1, -1, 6850, -1, -1, -1, -1, 6852, + 6853, -1, -1, -1, 6858, -1, 6860, -1, + 6865, 6867, 6870, 6872, -1, -1, -1, 6874, + -1, -1, 6877, -1, -1, -1, -1, -1, + -1, -1, 6879, -1, -1, -1, -1, -1, + -1, -1, 6880, -1, -1, -1, -1, -1, + 6882, -1, -1, -1, 6884, 6885, 6888, 6889, + 6890, -1, -1, -1, -1, -1, -1, -1, + 6892, 6893, -1, 6895, -1, 6897, 6898, 6899, + 6902, -1, 6906, 6907, 6908, -1, -1, -1, + 6909, 6910, -1, -1, -1, -1, -1, 6911, + -1, -1, -1, -1, -1, -1, -1, 6912, + -1, 6913, -1, 6914, 6915, 6916, -1, -1, + 6917, 6918, 6919, -1, -1, -1, 6921, -1, + -1, -1, -1, -1, 6922, -1, 6924, -1, + -1, 6926, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 6927, 6929, 6931, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 6932, -1, -1, -1, -1, -1, + 6933, 6934, 6935, -1, -1, -1, -1, -1, + 6936, -1, -1, -1, 6937, -1, -1, -1, + -1, -1, -1, 6939, 6940, -1, -1, -1, + -1, 6941, -1, 6942, -1, -1, -1, -1, + -1, 6943, 6944, 6945, -1, 6947, -1, -1, + /* 0x8000 */ + 6948, -1, -1, 6949, -1, -1, -1, 6950, + 6951, -1, 6952, 6953, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 6954, -1, -1, + 6955, -1, -1, -1, 6956, -1, -1, -1, + -1, 6957, 6958, -1, 6959, -1, -1, 6960, + 6961, -1, -1, -1, 6963, -1, 6964, -1, + 6965, -1, -1, -1, -1, -1, -1, -1, + 6966, -1, -1, 6967, 6968, 6969, -1, -1, + 6970, -1, 6973, 6974, -1, -1, -1, -1, + -1, -1, -1, 6975, 6976, 6979, -1, -1, + -1, -1, -1, -1, 6980, -1, 6982, -1, + -1, -1, -1, -1, -1, -1, 6984, 6985, + -1, 6987, -1, -1, -1, -1, 6990, -1, + 6993, 6995, 6996, 6999, -1, 7000, 7002, 7003, + 7007, -1, 7010, 7011, 7012, 7014, 7015, 7016, + -1, 7019, -1, -1, -1, 7020, 7022, -1, + -1, -1, -1, 7023, -1, 7025, -1, 7027, + 7028, 7029, -1, -1, -1, -1, 7030, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 7031, 7033, -1, -1, 7034, -1, -1, 7035, + -1, -1, -1, -1, 7036, -1, 7037, 7038, + -1, 7040, 7041, -1, 7043, -1, -1, -1, + -1, -1, -1, 7044, -1, -1, 7045, 7046, + 7047, 7048, -1, -1, 7051, -1, 7053, -1, + -1, -1, -1, -1, 7055, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 7056, -1, 7057, -1, -1, -1, + -1, 7058, -1, -1, -1, -1, -1, 7060, + 7061, -1, 7062, 7063, -1, 7065, -1, -1, + -1, -1, -1, -1, -1, -1, 7066, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + /* 0x8100 */ + -1, -1, -1, 7067, -1, 7069, 7071, 7073, + 7074, 7075, -1, 7076, -1, 7078, -1, 7079, + 7082, 7083, -1, 7085, 7086, -1, -1, 7087, + -1, -1, 7088, 7090, -1, -1, -1, -1, + -1, -1, -1, 7092, -1, -1, -1, -1, + -1, 7093, -1, 7094, -1, -1, -1, -1, + -1, 7095, -1, 7096, -1, 7099, 7100, -1, + 7101, 7102, 7104, -1, -1, -1, 7106, -1, + -1, -1, -1, -1, -1, -1, 7107, -1, + -1, -1, 7108, -1, 7110, -1, 7111, -1, + -1, -1, -1, -1, -1, -1, 7112, 7113, + 7114, -1, -1, -1, -1, -1, -1, 7115, + -1, 7116, -1, -1, -1, -1, 7117, -1, + -1, -1, -1, 7120, -1, 7121, 7122, -1, + -1, -1, -1, 7123, -1, -1, -1, -1, + 7125, -1, -1, 7127, -1, 7128, 7129, -1, + 7130, -1, 7131, 7132, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 7133, 7134, -1, 7135, -1, 7137, -1, -1, + -1, -1, 7138, -1, -1, -1, -1, -1, + 7139, -1, -1, 7140, 7141, -1, -1, -1, + -1, 7142, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 7143, -1, -1, -1, -1, + 7144, -1, -1, 7146, -1, 7150, 7152, 7153, + 7154, -1, -1, 7155, -1, -1, -1, -1, + 7157, 7159, -1, 7160, -1, 7161, -1, 7162, + -1, -1, -1, 7164, -1, -1, -1, -1, + 7166, 7168, 7169, -1, 7170, -1, 7171, 7172, + 7174, -1, 7175, -1, -1, 7176, -1, -1, + 7177, -1, -1, -1, -1, 7178, -1, -1, + 7179, -1, -1, -1, 7180, -1, -1, -1, + -1, -1, 7181, -1, -1, -1, -1, -1, + /* 0x8200 */ + -1, -1, -1, -1, -1, -1, 7183, 7184, + 7185, 7186, 7189, -1, -1, 7190, 7192, -1, + 7193, -1, -1, 7194, -1, -1, 7195, 7198, + 7201, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 7202, -1, -1, -1, -1, + -1, 7203, -1, -1, -1, -1, 7204, -1, + 7206, 7207, -1, -1, -1, 7208, 7209, -1, + -1, 7210, -1, 7211, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 7213, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 7214, -1, -1, -1, -1, -1, -1, + -1, -1, 7215, 7216, 7218, -1, 7219, -1, + -1, -1, 7220, 7222, -1, -1, -1, -1, + 7224, 7225, -1, 7227, -1, -1, 7231, 7235, + 7239, 7240, 7241, -1, -1, -1, -1, -1, + -1, -1, 7246, -1, -1, -1, -1, -1, + 7247, -1, -1, 7249, 7250, -1, -1, -1, + -1, -1, -1, -1, 7251, -1, -1, 7252, + -1, -1, -1, -1, 7253, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 7254, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 7255, 7256, -1, -1, -1, -1, -1, + 7257, -1, -1, 7264, -1, -1, -1, -1, + -1, 7265, -1, -1, -1, 7266, -1, 7268, + 7269, -1, -1, 7270, 7271, 7272, 7273, 7274, + 7279, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 7280, 7281, -1, -1, -1, -1, 7282, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 7283, -1, -1, -1, -1, -1, -1, + -1, 7284, 7286, -1, -1, 7287, -1, -1, + /* 0x8300 */ + -1, -1, -1, 7288, -1, -1, -1, -1, + -1, -1, 7290, -1, -1, -1, 7292, 7293, + -1, 7294, -1, -1, 7295, 7296, -1, -1, + 7297, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 7298, + -1, -1, -1, -1, -1, -1, -1, 7300, + 7301, -1, 7302, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 7304, 7305, + -1, -1, 7306, -1, -1, -1, -1, -1, + 7307, 7309, -1, -1, 7310, -1, -1, -1, + 7311, 7313, 7314, 7315, 7316, 7317, 7318, 7319, + 7320, 7322, -1, 7325, 7327, 7328, 7329, 7330, + 7331, 7332, 7333, 7334, 7335, 7336, 7337, 7338, + -1, -1, -1, 7341, -1, -1, -1, -1, + -1, 7342, -1, 7343, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 7344, -1, -1, + -1, -1, 7346, -1, -1, -1, -1, -1, + -1, -1, -1, 7348, -1, 7349, 7350, -1, + -1, -1, -1, -1, -1, -1, 7351, -1, + -1, -1, 7352, -1, -1, -1, -1, 7353, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 7354, 7355, 7356, 7357, 7358, 7359, 7360, + 7362, 7363, 7364, -1, 7367, 7369, 7370, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 7371, -1, 7372, 7373, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 7375, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 7376, -1, -1, -1, 7377, + 7380, 7381, -1, -1, 7382, -1, -1, -1, + -1, 7385, -1, -1, -1, -1, -1, -1, + /* 0x8400 */ + -1, -1, -1, -1, -1, -1, -1, 7386, + -1, -1, 7387, -1, 7388, 7389, -1, -1, + -1, -1, -1, -1, -1, 7390, -1, -1, + -1, -1, 7392, -1, -1, 7393, -1, 7394, + 7399, -1, -1, -1, 7400, 7402, 7404, 7405, + 7406, -1, -1, -1, 7407, -1, -1, -1, + -1, 7408, -1, -1, 7411, 7412, -1, -1, + 7413, -1, -1, -1, 7414, -1, -1, -1, + -1, -1, -1, -1, -1, 7415, -1, -1, + -1, 7416, 7417, -1, -1, -1, -1, -1, + -1, -1, 7420, -1, -1, -1, -1, 7421, + 7422, -1, 7423, -1, -1, -1, -1, -1, + 7424, -1, 7425, -1, 7427, -1, 7428, -1, + -1, -1, 7429, -1, 7430, -1, 7431, 7432, + -1, 7433, -1, -1, -1, -1, -1, 7434, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 7435, 7436, -1, -1, -1, 7437, + -1, 7438, -1, 7439, 7440, -1, -1, -1, + 7441, -1, -1, 7442, 7444, -1, -1, -1, + -1, 7445, -1, -1, -1, -1, 7449, -1, + -1, -1, -1, -1, -1, -1, 7451, -1, + 7452, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 7453, + -1, -1, -1, -1, 7454, -1, -1, -1, + 7455, -1, -1, -1, -1, -1, 7456, -1, + -1, -1, -1, 7457, -1, -1, -1, -1, + -1, 7459, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 7461, -1, 7462, + 7463, -1, -1, 7464, -1, 7465, 7466, -1, + -1, -1, -1, -1, -1, 7467, 7470, 7471, + -1, 7472, -1, -1, 7473, -1, -1, -1, + -1, -1, 7475, -1, -1, 7480, -1, -1, + /* 0x8500 */ + -1, -1, -1, -1, -1, 7481, 7483, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 7484, 7485, -1, -1, 7486, 7488, -1, -1, + -1, -1, -1, -1, -1, -1, 7489, -1, + -1, -1, -1, 7490, -1, 7491, 7492, -1, + -1, -1, -1, -1, -1, 7493, -1, 7494, + -1, -1, 7495, 7496, 7497, 7498, 7500, 7502, + -1, 7503, 7504, 7505, 7506, -1, -1, -1, + -1, 7508, -1, -1, -1, -1, 7509, -1, + -1, -1, 7510, 7512, -1, -1, 7514, -1, + 7515, -1, 7517, 7518, -1, 7519, -1, -1, + 7520, -1, 7521, -1, -1, -1, -1, -1, + -1, -1, 7522, -1, -1, -1, -1, -1, + -1, 7523, 7524, -1, -1, 7525, -1, -1, + 7526, -1, 7527, -1, 7528, -1, -1, 7530, + -1, -1, -1, -1, -1, -1, -1, 7531, + 7534, -1, -1, -1, -1, -1, -1, -1, + 7535, -1, 7536, -1, 7538, -1, -1, -1, + -1, 7539, -1, 7540, 7541, -1, -1, 7542, + 7544, -1, -1, -1, -1, -1, -1, 7545, + -1, -1, -1, -1, -1, -1, 7546, -1, + -1, 7548, -1, 7549, 7551, 7553, 7554, 7556, + 7557, -1, 7559, -1, -1, -1, -1, -1, + -1, -1, 7561, -1, 7563, -1, -1, -1, + -1, 7564, 7568, -1, -1, -1, -1, -1, + -1, 7572, -1, -1, -1, 7575, 7576, 7577, + -1, -1, -1, 7579, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 7580, -1, 7585, + -1, -1, -1, -1, 7587, 7588, -1, -1, + -1, -1, 7590, -1, -1, -1, -1, -1, + -1, -1, -1, 7592, 7596, -1, 7598, 7599, + -1, 7600, 7602, -1, 7603, -1, -1, -1, + /* 0x8600 */ + 7606, -1, 7607, -1, 7609, -1, 7610, 7611, + -1, -1, 7615, 7617, -1, 7619, 7621, -1, + 7623, -1, -1, 7626, -1, -1, -1, 7628, + -1, -1, 7629, -1, -1, -1, 7630, -1, + -1, -1, 7631, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 7632, -1, 7633, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 7635, -1, -1, 7636, -1, 7638, + -1, 7639, -1, -1, -1, -1, 7640, -1, + -1, -1, -1, -1, -1, -1, 7642, 7644, + -1, 7645, -1, 7646, -1, 7647, 7649, 7650, + -1, -1, 7652, 7654, 7656, 7657, -1, 7659, + -1, -1, -1, -1, -1, 7660, 7661, 7662, + -1, -1, -1, 7663, 7665, -1, 7666, 7667, + -1, 7668, -1, -1, -1, 7669, -1, -1, + -1, -1, 7671, 7672, -1, 7673, 7674, 7675, + 7676, 7677, 7678, 7679, -1, -1, -1, -1, + -1, -1, 7680, 7682, 7683, -1, -1, -1, + -1, -1, -1, -1, -1, 7684, 7687, -1, + 7688, -1, -1, -1, -1, 7689, -1, -1, + -1, -1, -1, -1, -1, -1, 7690, -1, + -1, -1, -1, 7691, 7692, -1, -1, -1, + -1, -1, -1, -1, 7693, -1, -1, -1, + -1, -1, 7694, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 7695, + -1, -1, 7697, -1, -1, 7698, 7700, 7702, + -1, -1, -1, -1, 7703, -1, -1, -1, + -1, 7706, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 7707, 7708, + 7709, 7710, 7711, 7712, 7713, -1, -1, -1, + -1, -1, 7714, 7715, -1, 7716, -1, -1, + /* 0x8700 */ + -1, -1, 7718, -1, -1, -1, 7719, -1, + -1, -1, -1, 7720, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 7721, 7722, 7723, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 7724, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 7726, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 7727, -1, -1, -1, 7728, -1, -1, + -1, -1, -1, -1, -1, 7729, -1, 7732, + 7734, 7735, -1, 7736, -1, -1, 7738, -1, + -1, -1, -1, -1, -1, 7739, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 7740, + -1, 7741, -1, -1, -1, -1, 7742, -1, + 7743, -1, -1, -1, -1, -1, -1, 7744, + -1, 7745, -1, -1, -1, -1, -1, -1, + 7746, -1, -1, -1, 7747, -1, 7748, 7749, + 7751, -1, 7752, -1, 7753, -1, -1, -1, + 7754, -1, -1, -1, -1, 7755, 7756, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 7757, 7758, -1, -1, -1, -1, 7760, -1, + -1, 7761, 7762, -1, 7764, -1, -1, 7766, + 7767, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 7768, -1, -1, -1, 7769, + -1, 7770, -1, -1, 7771, -1, 7772, 7773, + 7774, -1, -1, -1, -1, -1, 7775, 7776, + -1, -1, 7777, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 7778, -1, -1, -1, -1, + -1, -1, -1, -1, 7779, -1, -1, 7780, + -1, -1, 7781, -1, -1, -1, 7782, -1, + 7783, 7784, -1, 7785, -1, -1, -1, -1, + /* 0x8800 */ + -1, 7787, -1, -1, -1, 7788, 7790, 7791, + -1, -1, -1, -1, -1, 7793, 7794, 7795, + 7796, 7797, 7798, -1, 7801, 7802, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 7803, + -1, 7805, 7806, 7807, -1, -1, -1, 7809, + 7811, -1, -1, -1, -1, 7812, -1, -1, + -1, 7813, -1, -1, -1, -1, 7814, -1, + -1, 7817, 7819, 7822, 7823, -1, -1, -1, + -1, -1, 7825, -1, 7826, 7827, 7828, -1, + -1, 7831, 7833, -1, -1, -1, -1, -1, + -1, -1, -1, 7834, 7835, 7838, 7839, -1, + 7840, -1, 7843, 7844, 7846, 7849, 7850, 7852, + -1, -1, -1, 7855, 7856, 7857, -1, -1, + 7858, -1, -1, -1, 7859, -1, 7860, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 7861, -1, -1, -1, 7862, -1, -1, + -1, -1, -1, -1, 7863, 7864, 7867, -1, + -1, -1, -1, 7868, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 7869, -1, 7872, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 7873, 7875, 7876, 7877, + -1, -1, -1, -1, 7878, 7880, -1, 7881, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 7882, 7883, -1, + 7884, -1, 7885, -1, 7886, -1, -1, 7887, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 7889, -1, -1, 7890, 7891, -1, -1, + 7892, 7893, 7895, 7896, 7897, 7899, 7900, -1, + 7902, -1, -1, -1, -1, 7903, -1, -1, + -1, -1, -1, -1, 7904, 7905, -1, -1, + -1, -1, -1, -1, -1, 7906, -1, -1, + /* 0x8900 */ + -1, -1, -1, -1, -1, -1, -1, 7907, + -1, -1, 7908, -1, 7909, -1, 7910, 7911, + -1, -1, 7912, 7914, -1, -1, -1, -1, + 7915, -1, -1, 7916, -1, 7917, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 7918, -1, -1, -1, -1, + -1, -1, 7919, 7920, 7921, -1, -1, -1, + 7922, -1, -1, 7923, -1, -1, -1, -1, + -1, -1, -1, 7924, -1, -1, -1, 7926, + -1, -1, -1, -1, 7927, 7928, -1, 7929, + -1, -1, -1, -1, -1, 7930, 7931, -1, + -1, -1, -1, -1, -1, 7932, -1, -1, + 7933, -1, -1, -1, 7934, -1, -1, -1, + -1, -1, 7935, -1, 7936, 7937, -1, 7938, + -1, -1, 7939, -1, 7940, -1, -1, -1, + -1, -1, -1, -1, -1, 7942, -1, 7943, + -1, -1, -1, -1, -1, -1, 7945, 7947, + 7948, 7949, 7952, 7956, -1, 7957, 7958, 7959, + 7960, -1, -1, 7963, 7965, -1, 7967, -1, + 7969, -1, 7970, -1, -1, -1, -1, -1, + -1, 7973, -1, -1, -1, 7974, 7975, 7976, + -1, 7978, 7979, -1, 7980, -1, -1, 7981, + 7982, -1, 7983, 7984, -1, -1, 7986, 7987, + -1, -1, 7989, -1, 7993, 7994, -1, 7996, + 7997, 7999, 8000, 8002, 8003, 8004, 8006, 8008, + 8009, 8011, 8014, 8015, 8016, 8017, 8018, 8019, + 8020, 8021, -1, -1, 8022, -1, -1, 8023, + -1, -1, -1, -1, -1, 8025, 8026, -1, + -1, -1, -1, 8027, -1, -1, 8028, 8029, + -1, -1, -1, -1, -1, -1, -1, 8030, + -1, -1, -1, -1, 8032, -1, 8033, -1, + 8035, 8036, -1, -1, -1, 8038, -1, 8040, + /* 0x8a00 */ + 8042, 8044, 8046, 8047, -1, -1, -1, -1, + 8048, -1, 8049, -1, 8050, -1, 8051, -1, + 8052, -1, 8053, 8054, -1, 8055, 8056, 8057, + 8059, -1, 8060, 8061, -1, 8062, -1, 8063, + 8064, 8066, 8068, 8069, -1, 8070, -1, -1, + -1, 8071, 8072, 8073, -1, 8074, -1, -1, + -1, 8075, -1, 8076, 8078, -1, 8079, -1, + -1, -1, 8081, 8082, 8083, 8085, -1, -1, + -1, 8086, -1, -1, -1, -1, 8087, -1, + -1, -1, -1, 8089, -1, 8091, 8092, -1, + 8093, -1, 8094, -1, 8095, 8096, 8097, 8098, + 8099, -1, -1, 8100, -1, -1, 8101, 8102, + 8103, 8104, 8105, 8106, -1, -1, 8107, 8108, + -1, 8109, -1, 8110, 8111, 8113, 8114, -1, + 8115, 8116, 8118, 8119, -1, 8120, -1, -1, + -1, -1, -1, -1, 8121, -1, -1, 8122, + -1, -1, -1, -1, 8123, 8124, 8125, 8126, + -1, 8127, 8128, -1, 8129, 8130, -1, -1, + -1, 8131, 8132, -1, -1, 8133, 8134, -1, + 8136, -1, 8138, -1, -1, -1, 8139, -1, + 8140, 8141, -1, 8142, 8143, 8144, 8145, -1, + 8146, -1, 8147, -1, 8149, 8151, -1, 8153, + 8154, -1, 8155, -1, -1, -1, 8156, -1, + -1, 8157, -1, -1, 8158, -1, 8160, 8161, + -1, -1, 8162, -1, 8163, -1, -1, 8164, + -1, 8165, -1, 8166, 8167, 8169, -1, 8170, + -1, 8171, 8172, -1, -1, -1, 8173, 8174, + -1, -1, -1, 8175, 8176, 8177, 8178, -1, + 8179, 8181, 8183, -1, 8184, -1, 8186, 8187, + -1, 8188, -1, 8189, 8191, 8197, 8198, -1, + -1, 8199, -1, 8200, -1, -1, 8202, 8203, + 8205, -1, 8206, -1, 8207, -1, 8209, -1, + /* 0x8b00 */ + 8210, 8211, 8212, -1, 8213, 8214, -1, -1, + -1, -1, 8215, -1, 8216, -1, 8217, -1, + 8218, -1, -1, -1, 8219, -1, 8220, 8221, + -1, 8222, 8223, 8225, -1, 8226, -1, -1, + 8227, 8229, -1, -1, -1, -1, -1, -1, + 8231, -1, 8232, 8233, 8235, 8236, -1, -1, + 8238, -1, -1, 8239, -1, -1, -1, -1, + -1, 8240, -1, -1, 8241, -1, 8243, -1, + -1, 8244, -1, -1, -1, -1, -1, -1, + -1, 8246, -1, -1, 8248, -1, 8249, 8250, + 8251, -1, -1, -1, -1, -1, 8252, -1, + 8254, 8255, 8256, 8257, 8259, -1, -1, 8261, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 8262, 8264, -1, 8266, 8267, 8269, + 8271, 8272, 8273, -1, 8275, -1, -1, 8276, + 8277, -1, -1, -1, 8278, 8280, 8281, -1, + 8283, 8285, -1, 8287, -1, 8289, -1, -1, + -1, -1, 8290, 8292, 8293, 8295, 8297, -1, + 8300, -1, 8302, 8303, -1, 8305, 8306, -1, + -1, -1, 8307, -1, 8309, -1, 8310, -1, + 8311, 8313, 8314, 8315, 8316, 8317, 8318, 8319, + 8320, 8321, 8323, 8324, 8325, 8327, 8328, 8329, + 8330, 8331, 8332, 8333, 8334, 8335, 8336, 8337, + 8338, 8339, 8341, 8342, 8343, 8344, 8346, 8347, + 8348, 8349, 8351, 8352, 8353, 8354, 8355, 8356, + 8357, 8358, 8359, 8360, 8361, 8362, 8363, 8364, + 8365, 8366, 8368, 8369, 8370, 8371, 8372, 8373, + 8374, 8375, 8376, 8377, 8378, 8379, 8381, 8382, + 8383, 8384, 8385, 8386, 8387, 8388, 8389, 8390, + 8391, 8392, 8393, 8394, 8395, 8396, 8397, 8398, + 8400, 8401, 8403, 8404, 8405, 8407, 8408, 8409, + 8410, 8411, 8412, 8413, 8415, 8416, 8417, 8418, + /* 0x8c00 */ + 8419, 8420, 8421, 8422, 8423, 8424, 8425, 8426, + 8427, 8428, 8429, 8431, 8432, 8433, 8434, 8435, + 8437, 8438, 8439, 8440, 8441, 8443, 8444, 8446, + 8447, 8448, 8450, 8451, 8452, 8453, 8454, 8455, + 8456, 8457, 8458, 8459, 8461, 8462, 8464, 8465, + 8466, 8467, 8468, 8470, 8472, 8473, 8474, 8476, + 8477, 8478, 8479, 8480, 8481, 8482, 8483, 8484, + -1, -1, 8486, -1, -1, -1, -1, 8487, + 8490, -1, -1, -1, -1, -1, 8493, -1, + 8494, -1, 8495, -1, -1, -1, 8499, -1, + 8501, -1, -1, 8505, 8509, -1, -1, -1, + 8513, -1, 8514, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 8515, -1, -1, -1, + -1, -1, -1, 8516, 8517, -1, 8518, -1, + -1, -1, -1, -1, -1, -1, 8519, -1, + -1, -1, 8520, 8521, 8522, -1, 8523, -1, + -1, -1, 8524, -1, -1, -1, -1, 8525, + -1, 8526, -1, 8527, 8528, 8529, 8531, -1, + -1, -1, 8532, 8533, 8534, -1, -1, -1, + 8535, -1, -1, 8536, 8537, 8539, 8541, 8542, + 8545, 8546, 8548, -1, -1, -1, -1, 8549, + 8550, 8551, 8552, 8553, 8554, 8555, 8558, 8561, + 8562, -1, 8563, 8564, 8567, -1, 8568, 8569, + 8570, -1, 8571, 8572, 8573, 8574, -1, 8575, + 8576, 8577, 8578, 8579, 8580, 8581, -1, 8582, + 8583, 8584, 8586, 8587, -1, 8588, 8590, -1, + -1, 8592, 8593, 8594, 8596, 8598, 8599, -1, + -1, 8600, 8601, 8602, 8604, -1, 8605, -1, + 8606, 8607, 8610, 8612, 8614, -1, 8616, 8617, + -1, -1, 8618, 8621, 8622, 8623, -1, -1, + 8624, -1, -1, -1, 8625, 8627, -1, 8628, + -1, -1, 8630, 8631, 8632, 8633, 8634, -1, + /* 0x8d00 */ + -1, 8635, -1, -1, 8637, 8638, -1, 8639, + 8640, -1, 8641, 8643, -1, 8646, -1, 8647, + 8648, -1, 8649, 8651, 8653, -1, 8654, 8655, + -1, -1, -1, 8658, 8659, 8660, 8662, 8663, + 8664, 8667, 8668, 8670, 8671, 8673, 8675, 8676, + 8677, 8679, 8680, 8681, 8682, 8683, 8684, 8685, + 8686, 8689, 8691, 8692, 8693, 8694, 8695, 8696, + 8697, 8698, 8699, 8700, 8701, 8702, 8703, 8704, + 8705, 8706, 8707, 8708, 8711, 8712, 8713, 8714, + 8715, 8716, 8717, 8719, 8720, 8721, 8724, 8725, + 8726, 8727, 8728, 8729, 8730, 8731, 8732, 8734, + 8735, 8736, 8737, 8738, 8739, 8740, 8743, 8747, + 8748, 8749, 8750, 8751, 8752, -1, -1, -1, + -1, -1, 8754, -1, 8755, -1, -1, -1, + 8756, 8757, -1, -1, -1, 8758, 8759, -1, + -1, -1, -1, 8760, -1, -1, -1, 8765, + -1, 8766, 8767, -1, -1, -1, -1, -1, + -1, -1, -1, 8768, -1, -1, -1, -1, + -1, 8769, -1, -1, -1, 8770, -1, -1, + -1, 8771, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 8772, -1, + 8773, -1, -1, -1, 8774, -1, -1, 8775, + -1, 8777, 8778, -1, -1, -1, -1, -1, + 8779, -1, -1, 8780, -1, -1, -1, -1, + -1, -1, -1, 8781, 8783, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 8784, -1, + -1, 8785, -1, -1, -1, 8786, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 8787, 8788, 8789, 8790, + 8791, 8792, 8793, 8794, 8795, -1, -1, -1, + /* 0x8e00 */ + -1, 8796, -1, -1, -1, -1, -1, -1, + 8798, -1, 8800, 8801, 8803, -1, -1, -1, + 8804, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 8805, 8806, 8807, 8808, 8809, -1, -1, 8810, + 8811, -1, -1, -1, 8812, -1, -1, -1, + 8813, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 8814, -1, -1, -1, + -1, -1, -1, 8815, 8817, -1, -1, 8818, + -1, 8819, 8820, -1, -1, 8821, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 8822, + -1, -1, -1, 8823, 8824, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 8826, -1, -1, -1, -1, -1, -1, -1, + -1, 8828, 8830, -1, -1, -1, -1, 8832, + -1, -1, 8833, 8834, 8835, -1, -1, 8836, + -1, 8837, 8838, 8841, -1, 8843, -1, 8845, + -1, 8846, 8847, 8848, -1, 8849, -1, -1, + -1, 8851, 8852, -1, 8853, -1, -1, -1, + -1, 8854, 8855, -1, -1, 8857, 8858, -1, + -1, -1, 8859, -1, 8861, 8862, -1, 8863, + 8864, 8868, 8869, 8870, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 8871, -1, -1, -1, 8872, -1, 8875, -1, + -1, -1, 8879, 8880, 8881, 8882, -1, -1, + -1, 8883, 8884, -1, 8885, -1, -1, -1, + -1, -1, -1, 8886, -1, -1, -1, 8889, + -1, -1, 8890, 8892, 8894, -1, -1, -1, + -1, -1, -1, 8895, -1, -1, -1, -1, + 8896, -1, 8898, -1, -1, -1, 8899, -1, + 8902, 8903, 8904, 8905, 8906, 8907, 8909, -1, + /* 0x8f00 */ + 8910, -1, -1, 8911, -1, 8912, -1, 8913, + 8914, 8915, 8916, -1, 8917, -1, -1, 8919, + -1, -1, 8920, 8922, 8923, 8925, -1, -1, + -1, 8927, -1, 8929, 8931, 8933, 8934, 8935, + -1, 8936, -1, -1, -1, 8937, 8938, -1, + -1, 8939, 8941, -1, 8942, 8943, -1, 8944, + -1, -1, -1, 8945, -1, -1, 8946, -1, + 8947, -1, 8948, 8950, 8951, -1, 8952, 8953, + -1, 8954, 8957, -1, 8958, 8960, 8961, -1, + -1, 8962, -1, -1, -1, 8964, 8965, -1, + -1, -1, -1, -1, 8966, -1, -1, 8967, + -1, -1, -1, -1, 8968, -1, -1, 8969, + -1, 8971, 8972, -1, 8973, -1, 8974, 8975, + 8976, 8977, 8978, 8979, 8980, 8982, 8985, 8986, + 8988, 8990, 8991, 8992, 8993, 8994, 8995, 8996, + 8997, 8998, 8999, 9000, 9002, 9003, 9004, 9005, + 9006, 9007, 9008, 9009, 9010, 9012, 9013, 9015, + 9016, 9018, 9019, 9020, 9021, 9022, 9023, 9025, + 9026, 9027, 9028, 9029, 9030, 9031, 9032, 9033, + 9034, 9035, 9036, -1, -1, 9037, 9040, 9043, + 9044, 9046, -1, -1, 9049, -1, 9052, 9053, + 9055, 9057, -1, 9060, -1, 9061, 9064, 9065, + -1, -1, 9068, -1, -1, 9069, 9070, -1, + -1, 9071, 9074, -1, -1, 9077, 9078, -1, + -1, 9080, 9081, 9082, -1, -1, 9083, 9084, + 9085, -1, 9086, -1, -1, -1, -1, -1, + 9088, -1, -1, -1, -1, -1, -1, -1, + 9089, 9090, -1, 9091, 9092, 9093, 9094, 9095, + -1, -1, -1, -1, 9098, 9099, -1, -1, + -1, 9100, 9101, -1, 9102, -1, -1, 9103, + -1, -1, -1, 9104, 9107, -1, -1, -1, + -1, 9113, 9115, -1, -1, -1, -1, -1, + /* 0x9000 */ + -1, -1, 9117, 9118, -1, -1, -1, -1, + 9119, 9120, 9121, -1, -1, -1, 9122, -1, + -1, -1, 9123, 9125, -1, 9127, -1, -1, + -1, 9130, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 9131, -1, 9132, 9138, -1, + -1, 9139, -1, -1, -1, -1, -1, -1, + 9140, 9142, 9143, -1, -1, -1, -1, -1, + -1, 9144, 9146, 9147, 9148, -1, -1, -1, + -1, 9149, -1, -1, -1, 9150, -1, -1, + -1, 9152, 9154, 9156, -1, -1, 9157, -1, + -1, -1, 9158, 9159, 9162, 9164, -1, 9165, + -1, 9166, -1, -1, 9167, -1, 9168, -1, + 9170, 9172, -1, -1, -1, 9173, -1, -1, + -1, 9174, -1, -1, -1, -1, -1, 9175, + -1, -1, 9176, -1, -1, -1, 9178, 9179, + 9180, -1, 9181, -1, 9182, -1, -1, -1, + -1, 9183, -1, -1, 9184, -1, -1, 9185, + -1, 9186, 9189, -1, -1, -1, -1, 9192, + 9193, 9194, -1, 9195, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 9196, -1, -1, + -1, -1, -1, -1, -1, -1, 9197, -1, + 9198, -1, -1, 9199, 9200, -1, 9201, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 9202, 9203, 9204, -1, 9207, -1, -1, + -1, 9208, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 9211, -1, 9212, 9214, + 9215, 9216, 9217, 9219, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 9220, 9222, + -1, -1, -1, -1, -1, -1, 9223, 9224, + 9225, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 9226, 9227, 9228, + 9232, -1, -1, -1, -1, -1, -1, -1, + /* 0x9100 */ + -1, -1, -1, -1, -1, -1, 9233, -1, + -1, 9234, 9238, -1, -1, -1, -1, -1, + -1, -1, 9242, -1, 9243, 9244, 9248, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 9249, + -1, -1, -1, -1, -1, 9250, -1, -1, + 9251, -1, 9254, -1, 9255, -1, 9256, 9257, + -1, -1, 9258, -1, 9259, 9260, -1, -1, + -1, -1, 9263, -1, -1, -1, 9264, 9265, + 9267, 9268, -1, 9269, -1, -1, -1, -1, + -1, -1, -1, -1, 9270, -1, -1, -1, + -1, 9271, -1, -1, -1, 9272, -1, -1, + -1, -1, 9274, -1, -1, -1, 9275, 9278, + -1, -1, 9280, -1, 9281, -1, -1, -1, + -1, 9283, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 9285, 9286, 9287, + -1, -1, -1, 9289, -1, -1, -1, 9290, + -1, 9291, 9292, 9293, -1, -1, 9294, -1, + -1, -1, -1, -1, 9296, 9297, 9298, 9300, + 9303, -1, -1, -1, 9304, -1, 9306, -1, + -1, -1, -1, -1, 9308, -1, -1, -1, + -1, -1, -1, 9310, 9312, -1, -1, -1, + -1, 9314, -1, -1, -1, -1, -1, -1, + 9317, -1, -1, 9319, 9321, -1, -1, -1, + 9323, 9325, -1, 9326, -1, 9327, -1, 9328, + 9330, -1, 9332, 9334, 9336, -1, 9338, -1, + 9340, 9341, 9343, 9345, 9348, 9349, 9350, 9352, + 9353, 9354, 9355, -1, 9357, 9358, -1, -1, + 9359, 9361, -1, 9362, 9364, -1, 9365, 9366, + -1, 9367, -1, -1, -1, -1, -1, 9368, + 9369, -1, -1, -1, -1, 9377, -1, 9378, + -1, 9379, 9380, 9381, 9384, -1, -1, -1, + /* 0x9200 */ + 9392, 9393, -1, 9394, 9395, 9396, 9397, -1, + 9399, 9400, -1, -1, -1, 9401, 9402, -1, + 9404, 9405, 9406, -1, 9407, 9408, -1, -1, + -1, -1, -1, -1, -1, -1, 9409, 9411, + -1, 9412, -1, 9413, -1, 9414, 9415, 9416, + 9417, 9418, -1, -1, 9420, -1, 9422, -1, + 9424, -1, -1, 9425, 9426, -1, -1, 9427, + 9428, 9429, 9430, -1, -1, 9431, 9432, 9433, + 9434, -1, -1, -1, 9435, 9440, 9441, 9442, + 9443, 9444, -1, 9445, -1, 9447, -1, -1, + -1, 9448, -1, -1, -1, 9449, -1, 9450, + -1, -1, 9451, 9452, -1, -1, 9454, -1, + 9455, -1, 9456, -1, 9459, -1, 9461, -1, + 9462, -1, -1, -1, 9464, 9465, -1, -1, + -1, 9466, -1, -1, 9471, -1, 9475, -1, + 9476, -1, 9477, 9478, -1, -1, -1, 9479, + 9480, -1, -1, 9481, -1, 9482, -1, -1, + -1, -1, -1, -1, -1, 9483, -1, -1, + -1, 9484, -1, 9485, -1, 9486, 9490, -1, + 9491, -1, 9492, 9494, 9496, -1, 9499, -1, + 9500, -1, -1, 9501, -1, 9502, 9503, -1, + 9504, 9505, 9506, 9507, 9508, 9509, 9511, -1, + -1, 9512, 9513, 9514, -1, -1, -1, 9516, + -1, 9518, -1, 9519, 9520, 9521, -1, -1, + -1, 9522, -1, 9523, -1, 9524, -1, 9525, + -1, -1, -1, -1, 9526, -1, -1, 9527, + -1, -1, 9528, -1, -1, -1, -1, -1, + -1, 9529, -1, 9530, -1, 9535, -1, 9536, + -1, -1, -1, 9538, 9540, 9541, 9542, -1, + 9543, 9548, 9550, -1, -1, 9553, 9555, 9556, + 9557, 9558, -1, 9559, -1, -1, 9561, -1, + 9562, -1, -1, -1, 9563, -1, -1, -1, + /* 0x9300 */ + -1, 9564, -1, -1, 9565, -1, 9567, 9568, + 9569, -1, -1, -1, -1, -1, -1, 9570, + 9572, -1, 9573, -1, -1, 9574, -1, -1, + 9575, 9576, 9578, 9579, -1, -1, -1, 9580, + 9581, 9582, 9583, -1, -1, -1, 9585, -1, + 9586, 9587, -1, 9588, 9589, -1, 9592, 9593, + -1, -1, 9594, 9596, -1, -1, 9597, 9598, + 9599, -1, -1, -1, -1, -1, 9600, -1, + 9601, 9602, -1, 9603, -1, -1, 9604, 9605, + 9606, -1, 9608, 9611, -1, 9612, -1, -1, + -1, -1, -1, -1, 9613, -1, -1, -1, + 9614, -1, 9615, 9616, -1, -1, 9618, -1, + 9619, -1, -1, -1, 9621, 9622, -1, -1, + -1, 9623, -1, -1, 9624, -1, -1, 9625, + 9627, -1, -1, 9628, -1, 9632, 9633, -1, + -1, -1, 9634, -1, -1, -1, 9635, 9637, + -1, 9638, 9639, -1, 9640, -1, -1, 9641, + -1, -1, 9642, 9643, 9644, -1, -1, -1, + -1, -1, 9646, -1, 9648, -1, 9650, 9652, + 9653, -1, 9654, 9655, -1, -1, -1, -1, + -1, 9656, 9658, 9659, -1, -1, 9660, 9662, + -1, 9663, 9664, -1, 9665, 9666, 9668, -1, + 9670, -1, -1, 9671, -1, 9672, -1, -1, + 9673, -1, 9674, -1, -1, -1, -1, 9675, + -1, 9676, -1, 9677, -1, -1, -1, 9678, + 9679, -1, -1, -1, 9680, 9681, -1, -1, + 9682, 9683, -1, 9684, -1, -1, -1, 9685, + 9686, -1, -1, -1, 9687, 9688, 9689, 9690, + -1, 9694, 9696, -1, 9697, 9698, -1, -1, + 9700, -1, -1, -1, -1, -1, -1, -1, + 9701, -1, -1, -1, -1, 9702, -1, 9703, + -1, 9704, -1, -1, -1, 9705, -1, -1, + /* 0x9400 */ + -1, -1, 9707, 9709, -1, -1, -1, -1, + -1, -1, -1, 9710, -1, -1, -1, -1, + 9711, -1, 9712, 9713, 9714, -1, -1, 9715, + 9716, 9717, 9718, -1, -1, 9720, -1, -1, + 9722, 9723, -1, -1, -1, -1, 9728, 9729, + 9730, -1, -1, 9731, -1, -1, 9732, -1, + -1, -1, 9734, 9735, -1, 9736, 9741, -1, + 9742, -1, 9744, -1, -1, -1, -1, 9745, + -1, -1, -1, 9746, 9748, 9750, -1, -1, + -1, -1, 9751, -1, 9752, -1, -1, -1, + -1, 9753, 9757, 9761, 9762, 9763, -1, -1, + -1, -1, 9764, 9766, 9771, -1, 9773, -1, + 9774, -1, -1, 9775, 9776, 9777, -1, -1, + -1, -1, 9778, -1, 9780, 9784, -1, 9785, + 9786, 9787, 9788, -1, -1, 9789, -1, 9791, + -1, 9792, -1, -1, 9793, 9794, 9796, 9797, + -1, 9798, 9800, -1, -1, 9801, 9803, 9806, + 9807, 9808, 9809, 9810, 9811, 9812, 9813, 9814, + 9815, 9816, 9817, 9818, 9819, 9820, 9821, 9822, + 9823, 9824, 9825, 9826, 9827, 9828, 9829, 9830, + 9834, 9835, 9836, 9837, 9838, 9839, 9841, 9842, + 9843, 9844, 9846, 9847, 9848, 9849, 9850, 9851, + 9852, 9853, 9855, 9856, 9857, 9858, 9861, 9862, + 9863, 9864, 9865, 9866, 9869, 9870, 9871, 9872, + 9873, 9874, 9877, 9878, 9879, 9880, 9882, 9883, + 9885, 9886, 9887, 9889, 9890, 9892, 9893, 9895, + 9896, 9897, 9898, 9899, 9900, 9902, 9903, 9904, + 9905, 9906, 9907, 9908, 9909, 9910, 9911, 9912, + 9913, 9914, 9915, 9916, 9917, 9918, 9919, 9920, + 9921, 9922, 9923, 9924, 9926, 9927, 9928, 9929, + 9930, 9931, 9932, 9936, 9937, 9938, 9939, 9940, + 9941, 9943, 9944, 9947, 9948, 9949, 9950, 9951, + /* 0x9500 */ + 9953, 9954, 9955, 9956, 9957, 9959, 9960, 9961, + 9962, 9965, 9966, 9967, 9968, 9969, 9970, 9971, + 9973, 9975, 9976, 9977, 9978, 9979, 9980, 9981, + 9982, 9983, 9984, 9985, 9986, 9987, 9988, 9989, + 9990, 9991, 9992, 9993, 9994, 9996, 9997, 9998, + 9999, 10000, 10001, 10003, 10004, 10005, 10006, 10007, + 10008, 10009, 10010, 10011, 10012, 10013, 10014, 10015, + 10016, 10017, 10018, 10020, 10021, 10022, 10023, 10024, + 10025, 10026, 10027, 10028, 10029, 10030, 10031, 10032, + 10034, 10035, 10036, 10037, 10038, 10040, 10041, 10042, + 10044, 10045, 10046, 10047, 10048, -1, 10049, 10050, + 10051, 10052, 10053, 10054, 10055, 10056, 10057, 10058, + 10059, 10060, 10061, 10063, 10064, 10065, 10066, 10067, + 10068, 10069, 10070, 10071, 10072, 10073, 10074, 10075, + 10076, 10078, 10079, 10080, 10081, 10082, 10083, 10084, + 10088, 10092, -1, -1, -1, -1, -1, 10094, + 10098, -1, 10099, 10100, -1, -1, 10101, 10102, + 10104, 10105, -1, 10107, 10108, -1, 10109, 10110, + -1, 10112, 10114, 10116, 10117, -1, -1, -1, + 10118, 10119, -1, -1, -1, -1, -1, -1, + 10121, 10123, 10124, 10127, 10128, 10129, -1, 10130, + 10131, 10132, -1, 10133, 10134, 10135, -1, -1, + -1, 10136, 10138, -1, 10140, -1, 10142, -1, + -1, 10143, -1, 10145, 10146, 10147, 10148, 10149, + -1, -1, -1, 10150, -1, -1, 10152, 10153, + 10154, -1, 10155, 10157, 10158, 10159, -1, -1, + 10160, -1, 10161, 10162, 10163, 10164, 10165, 10166, + 10169, 10174, -1, -1, 10180, -1, 10183, -1, + 10184, 10185, 10186, -1, 10187, 10188, -1, -1, + 10189, 10190, 10191, 10192, 10193, 10194, 10196, 10197, + 10198, 10200, 10201, 10203, 10204, 10205, 10206, 10207, + 10208, 10209, 10211, 10212, 10213, 10214, 10215, 10216, + /* 0x9600 */ + 10217, 10218, 10219, 10220, 10221, 10222, 10224, 10225, + 10226, 10227, 10229, 10230, 10231, 10232, 10233, 10234, + 10235, 10236, 10237, 10239, 10240, 10242, 10243, 10244, + 10245, 10246, 10247, 10249, 10250, 10251, -1, 10253, + -1, -1, -1, -1, -1, 10254, 10258, -1, + 10260, 10261, 10263, 10265, 10267, -1, -1, 10268, + -1, 10269, -1, 10270, 10272, 10276, 10277, -1, + 10279, -1, -1, 10280, -1, -1, -1, -1, + 10281, 10283, -1, -1, -1, 10285, 10286, 10287, + 10288, 10289, -1, -1, -1, 10290, -1, -1, + -1, -1, -1, -1, -1, 10291, 10294, -1, + 10295, -1, -1, -1, 10296, 10298, 10299, 10301, + -1, -1, -1, 10302, -1, 10304, 10305, -1, + 10312, 10313, -1, -1, -1, -1, -1, -1, + 10316, -1, -1, 10320, -1, -1, -1, 10321, + 10322, -1, 10323, 10326, -1, 10328, -1, 10330, + -1, 10332, 10334, -1, 10338, -1, -1, -1, + -1, -1, 10340, -1, 10341, -1, 10342, 10344, + 10345, -1, -1, -1, -1, 10348, 10350, -1, + -1, 10351, -1, 10352, -1, 10353, -1, 10360, + 10361, -1, -1, 10364, -1, -1, -1, -1, + 10367, -1, 10368, 10371, -1, -1, 10373, 10374, + -1, 10381, 10384, -1, 10385, -1, 10386, 10388, + 10390, -1, 10392, 10399, -1, 10400, 10401, -1, + -1, 10402, -1, -1, -1, -1, -1, 10404, + -1, -1, -1, 10406, -1, 10407, -1, 10408, + -1, 10409, -1, -1, -1, 10411, 10414, -1, + -1, 10415, 10416, 10417, 10419, 10421, 10422, 10425, + 10426, -1, 10428, 10429, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 10430, -1, 10431, 10432, -1, -1, 10433, 10434, + -1, -1, 10435, 10437, -1, -1, 10438, -1, + /* 0x9700 */ + -1, 10440, -1, -1, -1, -1, -1, -1, + -1, 10441, 10442, -1, -1, -1, -1, -1, + -1, 10445, -1, -1, -1, -1, -1, 10446, + -1, -1, 10447, 10450, -1, -1, -1, -1, + -1, 10453, 10454, -1, -1, -1, -1, 10455, + -1, -1, -1, -1, -1, 10458, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 10459, -1, -1, 10460, -1, 10464, -1, -1, + -1, 10465, 10466, -1, 10467, -1, 10468, -1, + 10469, 10472, 10473, -1, -1, 10477, 10484, 10491, + -1, 10498, 10500, 10502, 10503, -1, -1, -1, + -1, 10506, 10507, -1, 10508, 10509, -1, -1, + -1, -1, 10512, 10518, 10519, 10521, -1, 10522, + 10523, -1, -1, 10524, -1, 10526, -1, -1, + -1, 10529, -1, -1, 10532, -1, -1, -1, + -1, -1, -1, -1, -1, 10533, -1, -1, + 10534, -1, -1, -1, -1, -1, -1, -1, + -1, 10536, -1, 10538, 10539, 10540, -1, 10541, + -1, 10542, 10543, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 10544, + -1, -1, -1, -1, -1, -1, 10545, 10547, + 10549, -1, -1, -1, -1, -1, -1, 10550, + -1, 10551, 10553, -1, -1, 10554, -1, -1, + -1, 10555, -1, -1, -1, 10556, 10557, -1, + -1, 10558, -1, 10560, -1, -1, 10561, -1, + 10562, 10564, -1, 10565, 10566, 10567, -1, -1, + -1, -1, -1, 10569, -1, -1, -1, -1, + -1, 10570, -1, -1, 10571, 10574, 10575, -1, + -1, -1, -1, -1, 10576, -1, 10578, 10579, + 10582, 10584, 10585, 10586, 10587, 10589, 10590, 10591, + -1, 10592, 10593, -1, -1, 10595, -1, -1, + -1, -1, -1, 10596, -1, -1, -1, 10597, + /* 0x9800 */ + -1, 10598, 10599, 10600, -1, 10601, 10602, 10603, + 10604, -1, 10605, -1, 10606, -1, 10607, 10608, + 10609, 10610, 10611, 10612, -1, -1, -1, 10613, + 10614, -1, 10615, -1, 10617, -1, -1, -1, + -1, 10618, -1, -1, 10619, 10621, 10623, -1, + -1, -1, -1, -1, 10624, 10626, 10627, -1, + 10629, -1, 10631, -1, 10632, -1, -1, 10634, + 10635, 10637, 10641, 10645, 10646, 10648, 10652, -1, + -1, -1, -1, -1, -1, -1, 10653, -1, + -1, -1, -1, 10654, 10655, 10656, 10657, 10658, + -1, -1, 10660, 10661, 10662, 10664, 10666, -1, + 10667, 10668, 10669, 10671, -1, -1, 10673, -1, + -1, -1, 10674, -1, -1, 10675, -1, 10676, + -1, -1, -1, 10677, 10678, -1, -1, 10679, + 10681, 10682, -1, 10685, 10686, 10687, 10688, 10689, + 10690, 10691, 10692, 10693, 10695, 10696, 10697, 10698, + 10699, 10700, 10701, 10702, 10703, 10704, 10706, 10707, + 10708, 10710, 10711, 10713, 10714, 10715, 10716, 10717, + 10718, 10720, 10721, 10722, 10726, -1, 10727, 10729, + 10730, 10731, 10732, 10733, 10734, 10736, 10737, 10738, + 10739, 10741, 10742, 10743, 10744, 10745, 10746, 10747, + 10748, -1, -1, -1, -1, 10756, 10757, 10761, + -1, 10762, -1, 10763, -1, -1, 10764, 10765, + 10768, -1, 10769, 10770, 10771, -1, -1, -1, + 10772, -1, -1, 10773, 10775, -1, 10777, 10782, + 10783, -1, -1, -1, 10787, -1, 10792, 10798, + 10799, 10800, 10801, 10802, 10803, 10804, 10805, 10806, + 10807, 10809, 10810, 10811, 10812, -1, 10813, 10814, + 10817, 10820, 10821, 10822, -1, 10823, -1, -1, + 10824, 10825, 10826, 10827, 10829, 10830, 10831, 10833, + 10835, -1, 10836, -1, 10838, -1, 10839, -1, + -1, -1, -1, -1, 10840, 10841, 10842, 10843, + /* 0x9900 */ + -1, -1, -1, 10844, 10845, 10846, -1, -1, + -1, 10848, 10851, -1, 10854, 10855, 10856, 10857, + 10858, 10859, 10860, 10862, -1, 10863, 10864, -1, + 10865, -1, 10867, 10868, 10869, -1, 10870, 10871, + 10872, 10874, -1, -1, -1, -1, -1, 10875, + 10879, -1, -1, -1, 10881, -1, -1, -1, + -1, 10882, -1, 10883, 10884, 10885, 10887, 10888, + -1, 10889, 10890, 10891, 10892, 10893, 10894, 10895, + -1, 10896, -1, 10897, -1, 10898, -1, -1, + 10899, 10900, 10901, 10902, 10903, 10904, 10905, -1, + -1, 10906, 10907, -1, -1, -1, -1, 10908, + -1, 10909, -1, -1, 10910, -1, 10911, 10912, + -1, -1, 10915, 10916, 10919, 10920, 10922, 10923, + 10925, 10926, 10927, 10928, 10929, 10930, 10931, 10933, + 10934, 10935, 10936, 10937, 10938, 10939, 10940, 10941, + 10943, 10944, 10945, 10946, 10947, 10949, 10950, 10951, + 10952, 10954, 10956, 10957, 10958, 10959, 10960, 10961, + 10962, 10964, 10965, 10966, 10967, 10968, 10969, 10970, + 10971, 10972, 10973, 10974, 10975, 10976, -1, -1, + -1, -1, -1, -1, -1, 10977, 10978, 10979, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 10980, 10981, 10982, -1, + -1, 10983, 10985, 10986, 10987, -1, -1, -1, + -1, 10988, -1, -1, -1, 10989, -1, 10990, + -1, 10992, -1, -1, 10993, 10995, 10997, -1, + 11001, -1, -1, -1, -1, -1, -1, -1, + 11005, 11006, 11007, -1, 11008, 11009, -1, -1, + 11010, 11011, -1, 11012, -1, 11013, 11015, 11017, + -1, 11018, 11021, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 11022, 11023, -1, + 11024, 11025, -1, -1, -1, 11026, -1, -1, + 11028, -1, -1, -1, -1, -1, -1, 11029, + /* 0x9a00 */ + -1, 11030, 11031, -1, -1, 11032, -1, -1, + -1, -1, -1, -1, -1, 11033, 11034, 11035, + 11036, -1, 11039, 11041, -1, -1, 11044, -1, + -1, 11045, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 11046, -1, -1, -1, + 11047, -1, -1, 11048, -1, 11049, 11050, -1, + 11053, -1, -1, -1, -1, -1, 11054, 11055, + 11057, -1, 11058, -1, -1, -1, 11059, -1, + 11060, 11061, 11062, 11063, 11064, 11065, -1, 11069, + -1, -1, 11070, -1, 11071, 11072, -1, 11073, + -1, 11074, 11077, -1, -1, 11078, -1, 11079, + -1, -1, 11082, 11083, -1, 11085, -1, 11086, + -1, -1, 11087, -1, 11089, 11090, 11092, -1, + -1, 11093, 11094, 11095, 11096, 11097, 11098, 11100, + 11101, 11102, 11106, 11107, 11109, 11111, 11112, 11113, + 11114, 11115, 11116, 11117, 11118, 11120, 11121, 11122, + 11124, 11125, 11126, 11129, 11130, 11131, 11132, 11133, + 11134, 11135, 11136, 11137, 11138, 11141, 11142, 11143, + 11144, 11145, 11146, 11147, -1, 11148, 11149, 11150, + 11151, 11153, 11154, 11156, 11157, 11158, 11160, 11161, + 11162, 11163, 11164, 11165, 11166, 11167, 11169, 11170, + -1, -1, -1, -1, -1, -1, -1, 11171, + -1, -1, -1, -1, -1, 11172, -1, -1, + -1, -1, -1, -1, -1, -1, 11176, -1, + -1, -1, -1, -1, 11177, 11179, -1, -1, + 11180, -1, -1, 11181, 11182, -1, -1, 11183, + -1, -1, 11184, 11185, 11187, 11191, 11193, 11194, + 11197, 11198, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 11199, 11201, 11202, -1, -1, + -1, 11203, 11205, -1, -1, 11207, 11208, 11210, + -1, -1, -1, -1, 11211, -1, -1, -1, + -1, 11213, -1, -1, -1, -1, -1, -1, + /* 0x9b00 */ + 11214, -1, 11215, -1, -1, -1, 11218, -1, + -1, -1, -1, -1, -1, 11219, -1, -1, + -1, -1, -1, 11220, -1, -1, -1, -1, + -1, -1, 11222, 11223, -1, -1, -1, -1, + -1, -1, 11224, 11227, -1, 11228, 11233, 11238, + 11240, 11241, 11242, 11247, -1, 11248, 11253, -1, + 11254, 11257, -1, -1, -1, -1, 11260, -1, + -1, 11261, -1, 11262, -1, -1, -1, -1, + 11264, -1, -1, -1, -1, -1, -1, 11265, + -1, 11266, -1, -1, -1, -1, 11267, -1, + 11269, -1, -1, -1, -1, -1, -1, 11274, + 11276, -1, 11277, 11278, -1, -1, -1, -1, + -1, -1, 11279, 11280, -1, -1, 11281, -1, + 11282, -1, -1, -1, -1, 11283, -1, 11284, + -1, -1, 11285, 11287, 11288, -1, -1, 11289, + -1, -1, 11290, -1, -1, -1, -1, -1, + -1, 11291, -1, 11292, -1, -1, -1, -1, + -1, 11293, 11295, 11296, -1, 11297, 11298, 11299, + 11300, 11301, 11302, 11303, -1, -1, -1, -1, + -1, -1, 11304, -1, 11305, 11306, 11309, -1, + -1, -1, -1, -1, -1, -1, 11310, 11311, + -1, -1, 11313, 11314, -1, 11315, 11316, -1, + -1, -1, -1, 11321, -1, -1, 11322, 11323, + -1, -1, 11325, 11326, -1, -1, 11327, -1, + 11328, 11329, -1, -1, -1, -1, -1, 11330, + -1, 11332, 11333, 11335, -1, -1, -1, -1, + -1, -1, 11336, -1, 11337, 11338, 11339, 11340, + 11342, -1, -1, 11343, -1, 11345, -1, -1, + -1, 11346, 11347, -1, 11348, -1, -1, 11349, + 11350, -1, 11351, 11352, -1, -1, -1, -1, + 11353, -1, -1, -1, 11354, 11355, -1, 11356, + -1, 11359, -1, -1, -1, 11360, -1, 11361, + /* 0x9c00 */ + 11362, 11364, 11365, 11366, -1, -1, -1, -1, + 11367, 11369, -1, -1, 11370, 11372, -1, 11374, + 11375, -1, 11377, 11378, -1, -1, -1, -1, + -1, -1, -1, 11379, 11381, -1, -1, 11382, + 11383, -1, -1, 11384, 11385, 11386, -1, -1, + 11388, 11390, -1, -1, -1, 11391, 11392, -1, + -1, 11393, 11394, 11396, -1, 11397, -1, 11398, + -1, 11399, 11400, 11402, 11403, -1, 11404, -1, + -1, -1, 11405, -1, -1, 11406, -1, -1, + 11407, 11408, -1, -1, -1, -1, -1, -1, + -1, -1, 11411, 11412, 11413, -1, 11414, 11415, + 11416, -1, -1, -1, -1, 11417, 11418, 11419, + 11420, -1, -1, 11421, 11422, -1, -1, 11423, + 11424, -1, -1, -1, -1, 11425, 11426, 11427, + -1, -1, -1, -1, -1, -1, 11428, 11431, + 11433, -1, 11435, 11436, 11441, 11442, 11443, 11444, + 11445, 11446, 11447, -1, 11448, 11449, 11450, 11451, + 11452, 11454, 11455, 11456, 11457, 11458, 11460, 11461, + 11462, 11463, 11464, 11465, 11466, 11467, 11468, 11469, + 11470, 11471, 11472, 11473, 11474, 11479, 11480, 11482, + 11483, 11485, 11486, 11487, 11488, 11489, 11490, 11491, + 11492, 11493, 11495, 11496, 11497, 11498, 11499, 11500, + 11501, 11502, 11503, 11504, 11505, 11506, 11507, 11508, + 11510, 11511, 11512, 11513, 11514, 11515, 11516, 11517, + 11518, 11519, 11520, 11521, 11522, 11524, 11526, 11527, + 11528, 11529, 11530, 11531, 11532, 11534, 11535, 11536, + 11537, 11538, 11539, 11540, 11541, 11542, 11544, 11546, + 11547, 11548, -1, 11549, 11550, 11551, 11553, 11554, + 11555, 11556, 11557, 11558, -1, 11559, -1, 11561, + -1, 11563, -1, 11564, 11566, -1, -1, -1, + -1, -1, 11567, 11568, 11569, -1, 11570, -1, + 11571, -1, -1, -1, -1, -1, -1, -1, + /* 0x9d00 */ + -1, -1, -1, -1, -1, -1, 11572, 11573, + 11574, 11576, -1, -1, -1, -1, 11578, -1, + -1, -1, 11580, -1, -1, 11581, -1, -1, + -1, -1, -1, 11582, -1, 11583, 11585, 11586, + -1, -1, -1, 11588, -1, -1, 11589, -1, + 11590, -1, -1, -1, 11591, -1, -1, 11593, + 11594, -1, -1, 11595, 11596, -1, -1, -1, + -1, -1, -1, 11597, 11598, -1, -1, 11599, + -1, -1, 11600, 11601, 11602, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 11603, 11604, 11605, 11606, -1, -1, -1, -1, + -1, 11607, -1, -1, 11608, 11609, 11611, -1, + 11613, 11614, -1, -1, -1, -1, -1, -1, + -1, -1, 11615, -1, 11616, -1, 11617, 11618, + 11619, -1, 11620, -1, -1, -1, 11621, 11623, + -1, -1, -1, -1, -1, -1, 11624, -1, + -1, -1, -1, -1, -1, -1, -1, 11626, + -1, 11628, 11629, -1, -1, -1, -1, 11630, + -1, -1, -1, 11633, -1, -1, 11634, -1, + 11635, -1, 11636, -1, -1, -1, -1, -1, + -1, 11637, -1, -1, 11638, 11639, -1, -1, + -1, 11640, 11641, 11642, 11644, -1, -1, 11645, + -1, -1, 11647, -1, 11648, 11655, -1, -1, + -1, 11656, 11657, 11658, 11659, -1, -1, 11660, + 11661, 11662, 11663, 11664, 11665, -1, 11668, -1, + 11669, 11670, 11671, -1, -1, -1, -1, 11672, + -1, -1, -1, 11673, -1, -1, 11674, 11675, + -1, 11677, 11678, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 11679, 11680, -1, + -1, -1, -1, 11681, -1, -1, -1, 11682, + 11683, -1, 11684, 11685, 11687, -1, -1, -1, + 11689, 11690, 11691, -1, -1, 11693, -1, 11694, + /* 0x9e00 */ + -1, -1, -1, -1, -1, -1, -1, 11695, + -1, -1, 11696, -1, 11697, -1, 11698, 11699, + -1, -1, -1, -1, -1, 11700, 11703, -1, + 11710, -1, 11711, 11712, 11714, 11715, 11716, 11717, + 11719, 11720, 11723, 11724, 11725, 11726, 11728, 11730, + 11731, 11732, 11733, 11734, 11736, 11737, 11738, 11739, + 11740, 11741, 11742, 11743, 11744, 11745, 11746, 11747, + 11748, 11749, 11750, 11751, 11752, 11753, 11754, 11755, + 11756, 11757, 11758, 11759, 11760, 11761, 11763, 11764, + 11766, 11767, 11768, 11769, 11770, 11771, 11772, 11773, + 11774, 11775, 11776, 11777, 11778, 11779, 11780, 11781, + 11782, 11783, 11784, 11786, 11787, 11788, 11789, 11790, + 11791, 11792, 11793, 11794, 11795, 11802, 11803, 11804, + 11805, 11806, 11807, 11808, 11809, 11810, -1, 11811, + 11812, 11813, 11814, 11815, 11816, 11817, -1, -1, + 11819, 11822, 11824, 11825, 11826, 11829, 11831, -1, + -1, -1, -1, 11832, 11833, 11834, -1, 11835, + -1, -1, -1, -1, -1, -1, -1, 11836, + -1, -1, -1, -1, -1, -1, -1, 11837, + -1, -1, -1, -1, -1, -1, 11839, -1, + -1, -1, -1, -1, 11840, 11842, 11843, -1, + -1, 11844, 11846, 11851, 11856, 11858, -1, 11859, + -1, -1, -1, -1, 11863, 11867, -1, -1, + 11872, 11874, 11878, 11883, 11886, 11890, -1, -1, + -1, -1, -1, 11894, 11895, -1, -1, -1, + -1, 11897, -1, -1, 11898, -1, -1, 11899, + -1, 11900, 11901, -1, -1, -1, -1, -1, + 11902, 11903, -1, 11904, -1, -1, 11905, -1, + -1, 11907, -1, -1, 11908, -1, -1, -1, + 11909, 11910, 11911, -1, -1, 11912, -1, -1, + -1, 11913, 11914, -1, 11915, -1, 11916, 11917, + -1, 11918, -1, -1, -1, 11919, 11920, 11921, + /* 0x9f00 */ + -1, -1, 11923, 11924, -1, -1, -1, 11925, + 11927, 11930, -1, 11931, 11932, 11933, 11934, -1, + -1, 11935, 11936, 11937, -1, 11939, -1, 11940, + -1, -1, -1, -1, -1, -1, -1, -1, + 11942, 11943, -1, -1, -1, -1, 11944, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 11945, -1, -1, -1, + -1, 11946, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 11947, -1, -1, + -1, -1, 11948, 11952, -1, -1, 11954, 11956, + 11958, 11962, 11964, 11966, 11967, 11969, -1, 11970, + -1, 11971, 11972, -1, 11973, -1, -1, 11974, + 11975, 11976, 11978, 11980, -1, -1, 11981, 11982, + -1, 11985, 11986, -1, 11988, -1, -1, -1, + 11989, 11990, 11991, -1, -1, -1, 11992, 11993, + -1, -1, -1, -1, -1, -1, -1, 11994, + 11996, 11997, 11998, 11999, 12000, 12002, 12003, 12004, + 12005, 12006, 12007, 12008, 12009, 12010, 12013, -1, + 12014, -1, 12015, -1, 12018, 12019, -1, -1, + -1, 12020, 12022, 12023, 12024, 12026, 12029, 12031, + -1, -1, 12033, -1, -1, 12036, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, +}; + diff --git a/graf2d/win32gdk/gdk/src/iconv/cns11643.h b/graf2d/win32gdk/gdk/src/iconv/cns11643.h new file mode 100644 index 0000000000000..5b166412545e6 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cns11643.h @@ -0,0 +1,41 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CNS 11643-1992 + */ + +/* ISO-2022-CN and EUC-TW use CNS 11643-1992 planes 1 to 7. We also + * have a table for the older plane 15. We use a trick to keep the + * Unicode -> CNS 11643 table as small as possible (see cns11643_inv.h). + */ + +#include "cns11643_1.h" +#include "cns11643_2.h" +#include "cns11643_3.h" +#include "cns11643_4.h" +#include "cns11643_5.h" +#include "cns11643_6.h" +#include "cns11643_7.h" +#include "cns11643_15.h" +#include "cns11643_inv.h" + +/* Returns the plane number (1,...,7,15) in r[0], the two bytes in r[1],r[2]. */ +#define cns11643_wctomb cns11643_inv_wctomb diff --git a/graf2d/win32gdk/gdk/src/iconv/cns11643_1.h b/graf2d/win32gdk/gdk/src/iconv/cns11643_1.h new file mode 100644 index 0000000000000..24abb5ccbd40b --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cns11643_1.h @@ -0,0 +1,893 @@ +/* + * Copyright (C) 1999-2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CNS 11643-1992 plane 1 + */ + +static const unsigned short cns11643_1_2uni_page21[500] = { + /* 0x21 */ + 0x3000, 0xff0c, 0x3001, 0x3002, 0xff0e, 0x30fb, 0xff1b, 0xff1a, + 0xff1f, 0xff01, 0xfe30, 0x2026, 0x2025, 0xfe50, 0xfe51, 0xfe52, + 0x00b7, 0xfe54, 0xfe55, 0xfe56, 0xfe57, 0xfe31, 0x2014, 0xfe32, + 0x2013, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xff08, 0xff09, 0xfe35, + 0xfe36, 0xff5b, 0xff5d, 0xfe37, 0xfe38, 0x3014, 0x3015, 0xfe39, + 0xfe3a, 0x3010, 0x3011, 0xfe3b, 0xfe3c, 0x300a, 0x300b, 0xfe3d, + 0xfe3e, 0x3008, 0x3009, 0xfe3f, 0xfe40, 0x300c, 0x300d, 0xfe41, + 0xfe42, 0x300e, 0x300f, 0xfe43, 0xfe44, 0xfe59, 0xfe5a, 0xfe5b, + 0xfe5c, 0xfe5d, 0xfe5e, 0x2018, 0x2019, 0x201c, 0x201d, 0x301d, + 0x301e, 0x2032, 0x2035, 0xff03, 0xff06, 0xff0a, 0x203b, 0x00a7, + 0x3003, 0x25cb, 0x25cf, 0x25b3, 0x25b2, 0x25ce, 0x2606, 0x2605, + 0x25c7, 0x25c6, 0x25a1, 0x25a0, 0x25bd, 0x25bc, + /* 0x22 */ + 0x32a3, 0x2105, 0x203e, 0xfffd, 0xff3f, 0xfffd, 0xfe49, 0xfe4a, + 0xfe4d, 0xfe4e, 0xfe4b, 0xfe4c, 0xfe5f, 0xfe60, 0xfe61, 0xff0b, + 0xff0d, 0x00d7, 0x00f7, 0x00b1, 0x221a, 0xff1c, 0xff1e, 0xff1d, + 0x2266, 0x2267, 0x2260, 0x221e, 0x2252, 0x2261, 0xfe62, 0xfe63, + 0xfe64, 0xfe66, 0xfe65, 0x223c, 0x2229, 0x222a, 0x22a5, 0x2220, + 0x221f, 0x22bf, 0x33d2, 0x33d1, 0x222b, 0x222e, 0x2235, 0x2234, + 0x2640, 0x2642, 0x2641, 0x2609, 0x2191, 0x2193, 0x2192, 0x2190, + 0x2196, 0x2197, 0x2199, 0x2198, 0x2016, 0xff5c, 0xff0f, 0xff3c, + 0x2215, 0xfe68, 0xff04, 0xffe5, 0x3012, 0xffe0, 0xffe1, 0xff05, + 0xff20, 0x2103, 0x2109, 0xfe69, 0xfe6a, 0xfe6b, 0x33d5, 0x339c, + 0x339d, 0x339e, 0x33ce, 0x33a1, 0x338e, 0x338f, 0x33c4, 0x00b0, + 0x5159, 0x515b, 0x515e, 0x515d, 0x5161, 0x5163, + /* 0x23 */ + 0x55e7, 0x74e9, 0x7cce, 0x2581, 0x2582, 0x2583, 0x2584, 0x2585, + 0x2586, 0x2587, 0x2588, 0x258f, 0x258e, 0x258d, 0x258c, 0x258b, + 0x258a, 0x2589, 0x253c, 0x2534, 0x252c, 0x2524, 0x251c, 0x2594, + 0x2500, 0x2502, 0x2595, 0x250c, 0x2510, 0x2514, 0x2518, 0x256d, + 0x256e, 0x2570, 0x256f, 0x2550, 0x255e, 0x256a, 0x2561, 0x25e2, + 0x25e3, 0x25e5, 0x25e4, 0x2571, 0x2572, 0x2573, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x24 */ + 0xff10, 0xff11, 0xff12, 0xff13, 0xff14, 0xff15, 0xff16, 0xff17, + 0xff18, 0xff19, 0x2160, 0x2161, 0x2162, 0x2163, 0x2164, 0x2165, + 0x2166, 0x2167, 0x2168, 0x2169, 0x3021, 0x3022, 0x3023, 0x3024, + 0x3025, 0x3026, 0x3027, 0x3028, 0x3029, 0xfffd, 0x5344, 0xfffd, + 0xff21, 0xff22, 0xff23, 0xff24, 0xff25, 0xff26, 0xff27, 0xff28, + 0xff29, 0xff2a, 0xff2b, 0xff2c, 0xff2d, 0xff2e, 0xff2f, 0xff30, + 0xff31, 0xff32, 0xff33, 0xff34, 0xff35, 0xff36, 0xff37, 0xff38, + 0xff39, 0xff3a, 0xff41, 0xff42, 0xff43, 0xff44, 0xff45, 0xff46, + 0xff47, 0xff48, 0xff49, 0xff4a, 0xff4b, 0xff4c, 0xff4d, 0xff4e, + 0xff4f, 0xff50, 0xff51, 0xff52, 0xff53, 0xff54, 0xff55, 0xff56, + 0xff57, 0xff58, 0xff59, 0xff5a, 0x0391, 0x0392, 0x0393, 0x0394, + 0x0395, 0x0396, 0x0397, 0x0398, 0x0399, 0x039a, + /* 0x25 */ + 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, 0x03a0, 0x03a1, 0x03a3, + 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, 0x03b1, 0x03b2, + 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, 0x03b8, 0x03b9, 0x03ba, + 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, 0x03c0, 0x03c1, 0x03c3, + 0x03c4, 0x03c5, 0x03c6, 0x03c7, 0x03c8, 0x03c9, 0x3105, 0x3106, + 0x3107, 0x3108, 0x3109, 0x310a, 0x310b, 0x310c, 0x310d, 0x310e, + 0x310f, 0x3110, 0x3111, 0x3112, 0x3113, 0x3114, 0x3115, 0x3116, + 0x3117, 0x3118, 0x3119, 0x311a, 0x311b, 0x311c, 0x311d, 0x311e, + 0x311f, 0x3120, 0x3121, 0x3122, 0x3123, 0x3124, 0x3125, 0x3126, + 0x3127, 0x3128, 0x3129, 0x02d9, 0x02c9, 0x02ca, 0x02c7, 0x02cb, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x26 */ + 0x2460, 0x2461, 0x2462, 0x2463, 0x2464, 0x2465, 0x2466, 0x2467, + 0x2468, 0x2469, 0x2474, 0x2475, 0x2476, 0x2477, 0x2478, 0x2479, + 0x247a, 0x247b, 0x247c, 0x247d, 0x2170, 0x2171, 0x2172, 0x2173, + 0x2174, 0x2175, 0x2176, 0x2177, 0x2178, 0x2179, +}; +static const unsigned short cns11643_1_2uni_page42[34] = { + /* 0x42 */ + 0x2400, 0x2401, 0x2402, 0x2403, 0x2404, 0x2405, 0x2406, 0x2407, + 0x2408, 0x2409, 0x240a, 0x240b, 0x240c, 0x240d, 0x240e, 0x240f, + 0x2410, 0x2411, 0x2412, 0x2413, 0x2414, 0x2415, 0x2416, 0x2417, + 0x2418, 0x2419, 0x241a, 0x241b, 0x241c, 0x241d, 0x241e, 0x241f, + 0x2421, 0x20ac, +}; +static const unsigned short cns11643_1_2uni_page44[5401] = { + /* 0x44 */ + 0x4e00, 0x4e59, 0x4e01, 0x4e03, 0x4e43, 0x4e5d, 0x4e86, 0x4e8c, + 0x4eba, 0x513f, 0x5165, 0x516b, 0x51e0, 0x5200, 0x5201, 0x529b, + 0x5315, 0x5341, 0x535c, 0x53c8, 0x4e09, 0x4e0b, 0x4e08, 0x4e0a, + 0x4e2b, 0x4e38, 0x51e1, 0x4e45, 0x4e48, 0x4e5f, 0x4e5e, 0x4e8e, + 0x4ea1, 0x5140, 0x5203, 0x52fa, 0x5343, 0x53c9, 0x53e3, 0x571f, + 0x58eb, 0x5915, 0x5927, 0x5973, 0x5b50, 0x5b51, 0x5b53, 0x5bf8, + 0x5c0f, 0x5c22, 0x5c38, 0x5c71, 0x5ddd, 0x5de5, 0x5df1, 0x5df2, + 0x5df3, 0x5dfe, 0x5e72, 0x5efe, 0x5f0b, 0x5f13, 0x624d, 0x4e11, + 0x4e10, 0x4e0d, 0x4e2d, 0x4e30, 0x4e39, 0x4e4b, 0x5c39, 0x4e88, + 0x4e91, 0x4e95, 0x4e92, 0x4e94, 0x4ea2, 0x4ec1, 0x4ec0, 0x4ec3, + 0x4ec6, 0x4ec7, 0x4ecd, 0x4eca, 0x4ecb, 0x4ec4, 0x5143, 0x5141, + 0x5167, 0x516d, 0x516e, 0x516c, 0x5197, 0x51f6, + /* 0x45 */ + 0x5206, 0x5207, 0x5208, 0x52fb, 0x52fe, 0x52ff, 0x5316, 0x5339, + 0x5348, 0x5347, 0x5345, 0x535e, 0x5384, 0x53cb, 0x53ca, 0x53cd, + 0x58ec, 0x5929, 0x592b, 0x592a, 0x592d, 0x5b54, 0x5c11, 0x5c24, + 0x5c3a, 0x5c6f, 0x5df4, 0x5e7b, 0x5eff, 0x5f14, 0x5f15, 0x5fc3, + 0x6208, 0x6236, 0x624b, 0x624e, 0x652f, 0x6587, 0x6597, 0x65a4, + 0x65b9, 0x65e5, 0x66f0, 0x6708, 0x6728, 0x6b20, 0x6b62, 0x6b79, + 0x6bcb, 0x6bd4, 0x6bdb, 0x6c0f, 0x6c34, 0x706b, 0x722a, 0x7236, + 0x723b, 0x7247, 0x7259, 0x725b, 0x72ac, 0x738b, 0x4e19, 0x4e16, + 0x4e15, 0x4e14, 0x4e18, 0x4e3b, 0x4e4d, 0x4e4f, 0x4e4e, 0x4ee5, + 0x4ed8, 0x4ed4, 0x4ed5, 0x4ed6, 0x4ed7, 0x4ee3, 0x4ee4, 0x4ed9, + 0x4ede, 0x5145, 0x5144, 0x5189, 0x518a, 0x51ac, 0x51f9, 0x51fa, + 0x51f8, 0x520a, 0x52a0, 0x529f, 0x5305, 0x5306, + /* 0x46 */ + 0x5317, 0x531d, 0x4edf, 0x534a, 0x5349, 0x5361, 0x5360, 0x536f, + 0x536e, 0x53bb, 0x53ef, 0x53e4, 0x53f3, 0x53ec, 0x53ee, 0x53e9, + 0x53e8, 0x53fc, 0x53f8, 0x53f5, 0x53eb, 0x53e6, 0x53ea, 0x53f2, + 0x53f1, 0x53f0, 0x53e5, 0x53ed, 0x53fb, 0x56db, 0x56da, 0x5916, + 0x592e, 0x5931, 0x5974, 0x5976, 0x5b55, 0x5b83, 0x5c3c, 0x5de8, + 0x5de7, 0x5de6, 0x5e02, 0x5e03, 0x5e73, 0x5e7c, 0x5f01, 0x5f18, + 0x5f17, 0x5fc5, 0x620a, 0x6253, 0x6254, 0x6252, 0x6251, 0x65a5, + 0x65e6, 0x672e, 0x672c, 0x672a, 0x672b, 0x672d, 0x6b63, 0x6bcd, + 0x6c11, 0x6c10, 0x6c38, 0x6c41, 0x6c40, 0x6c3e, 0x72af, 0x7384, + 0x7389, 0x74dc, 0x74e6, 0x7518, 0x751f, 0x7528, 0x7529, 0x7530, + 0x7531, 0x7532, 0x7533, 0x758b, 0x767d, 0x76ae, 0x76bf, 0x76ee, + 0x77db, 0x77e2, 0x77f3, 0x793a, 0x79be, 0x7a74, + /* 0x47 */ + 0x7acb, 0x4e1e, 0x4e1f, 0x4e52, 0x4e53, 0x4e69, 0x4e99, 0x4ea4, + 0x4ea6, 0x4ea5, 0x4eff, 0x4f09, 0x4f19, 0x4f0a, 0x4f15, 0x4f0d, + 0x4f10, 0x4f11, 0x4f0f, 0x4ef2, 0x4ef6, 0x4efb, 0x4ef0, 0x4ef3, + 0x4efd, 0x4f01, 0x4f0b, 0x5149, 0x5147, 0x5146, 0x5148, 0x5168, + 0x5171, 0x518d, 0x51b0, 0x5217, 0x5211, 0x5212, 0x520e, 0x5216, + 0x52a3, 0x5308, 0x5321, 0x5320, 0x5370, 0x5371, 0x5409, 0x540f, + 0x540c, 0x540a, 0x5410, 0x5401, 0x540b, 0x5404, 0x5411, 0x540d, + 0x5408, 0x5403, 0x540e, 0x5406, 0x5412, 0x56e0, 0x56de, 0x56dd, + 0x5733, 0x5730, 0x5728, 0x572d, 0x572c, 0x572f, 0x5729, 0x5919, + 0x591a, 0x5937, 0x5938, 0x5984, 0x5978, 0x5983, 0x597d, 0x5979, + 0x5982, 0x5981, 0x5b57, 0x5b58, 0x5b87, 0x5b88, 0x5b85, 0x5b89, + 0x5bfa, 0x5c16, 0x5c79, 0x5dde, 0x5e06, 0x5e76, + /* 0x48 */ + 0x5e74, 0x5f0f, 0x5f1b, 0x5fd9, 0x5fd6, 0x620e, 0x620c, 0x620d, + 0x6210, 0x6263, 0x625b, 0x6258, 0x6536, 0x65e9, 0x65e8, 0x65ec, + 0x65ed, 0x66f2, 0x66f3, 0x6709, 0x673d, 0x6734, 0x6731, 0x6735, + 0x6b21, 0x6b64, 0x6b7b, 0x6c16, 0x6c5d, 0x6c57, 0x6c59, 0x6c5f, + 0x6c60, 0x6c50, 0x6c55, 0x6c61, 0x6c5b, 0x6c4d, 0x6c4e, 0x7070, + 0x725f, 0x725d, 0x767e, 0x7af9, 0x7c73, 0x7cf8, 0x7f36, 0x7f8a, + 0x7fbd, 0x8001, 0x8003, 0x800c, 0x8012, 0x8033, 0x807f, 0x8089, + 0x808b, 0x808c, 0x81e3, 0x81ea, 0x81f3, 0x81fc, 0x820c, 0x821b, + 0x821f, 0x826e, 0x8272, 0x827e, 0x866b, 0x8840, 0x884c, 0x8863, + 0x897f, 0x9621, 0x4e32, 0x4ea8, 0x4f4d, 0x4f4f, 0x4f47, 0x4f57, + 0x4f5e, 0x4f34, 0x4f5b, 0x4f55, 0x4f30, 0x4f50, 0x4f51, 0x4f3d, + 0x4f3a, 0x4f38, 0x4f43, 0x4f54, 0x4f3c, 0x4f46, + /* 0x49 */ + 0x4f63, 0x4f5c, 0x4f60, 0x4f2f, 0x4f4e, 0x4f36, 0x4f59, 0x4f5d, + 0x4f48, 0x4f5a, 0x514c, 0x514b, 0x514d, 0x5175, 0x51b6, 0x51b7, + 0x5225, 0x5224, 0x5229, 0x522a, 0x5228, 0x52ab, 0x52a9, 0x52aa, + 0x52ac, 0x5323, 0x5373, 0x5375, 0x541d, 0x542d, 0x541e, 0x543e, + 0x5426, 0x544e, 0x5427, 0x5446, 0x5443, 0x5433, 0x5448, 0x5442, + 0x541b, 0x5429, 0x544a, 0x5439, 0x543b, 0x5438, 0x542e, 0x5435, + 0x5436, 0x5420, 0x543c, 0x5440, 0x5431, 0x542b, 0x541f, 0x542c, + 0x56ea, 0x56f0, 0x56e4, 0x56eb, 0x574a, 0x5751, 0x5740, 0x574d, + 0x5747, 0x574e, 0x573e, 0x5750, 0x574f, 0x573b, 0x58ef, 0x593e, + 0x599d, 0x5992, 0x59a8, 0x599e, 0x59a3, 0x5999, 0x5996, 0x598d, + 0x59a4, 0x5993, 0x598a, 0x59a5, 0x5b5d, 0x5b5c, 0x5b5a, 0x5b5b, + 0x5b8c, 0x5b8b, 0x5b8f, 0x5c2c, 0x5c40, 0x5c41, + /* 0x4a */ + 0x5c3f, 0x5c3e, 0x5c90, 0x5c91, 0x5c94, 0x5c8c, 0x5deb, 0x5e0c, + 0x5e8f, 0x5e87, 0x5e8a, 0x5ef7, 0x5f04, 0x5f1f, 0x5f64, 0x5f62, + 0x5f77, 0x5f79, 0x5fd8, 0x5fcc, 0x5fd7, 0x5fcd, 0x5ff1, 0x5feb, + 0x5ff8, 0x5fea, 0x6212, 0x6211, 0x6284, 0x6297, 0x6296, 0x6280, + 0x6276, 0x6289, 0x626d, 0x628a, 0x627c, 0x627e, 0x6279, 0x6273, + 0x6292, 0x626f, 0x6298, 0x626e, 0x6295, 0x6293, 0x6291, 0x6286, + 0x6539, 0x653b, 0x6538, 0x65f1, 0x66f4, 0x675f, 0x674e, 0x674f, + 0x6750, 0x6751, 0x675c, 0x6756, 0x675e, 0x6749, 0x6746, 0x6760, + 0x6753, 0x6757, 0x6b65, 0x6bcf, 0x6c42, 0x6c5e, 0x6c99, 0x6c81, + 0x6c88, 0x6c89, 0x6c85, 0x6c9b, 0x6c6a, 0x6c7a, 0x6c90, 0x6c70, + 0x6c8c, 0x6c68, 0x6c96, 0x6c92, 0x6c7d, 0x6c83, 0x6c72, 0x6c7e, + 0x6c74, 0x6c86, 0x6c76, 0x6c8d, 0x6c94, 0x6c98, + /* 0x4b */ + 0x6c82, 0x7076, 0x707c, 0x707d, 0x7078, 0x7262, 0x7261, 0x7260, + 0x72c4, 0x72c2, 0x7396, 0x752c, 0x752b, 0x7537, 0x7538, 0x7682, + 0x76ef, 0x77e3, 0x79c1, 0x79c0, 0x79bf, 0x7a76, 0x7cfb, 0x7f55, + 0x8096, 0x8093, 0x809d, 0x8098, 0x809b, 0x809a, 0x80b2, 0x826f, + 0x8292, 0x828b, 0x828d, 0x898b, 0x89d2, 0x8a00, 0x8c37, 0x8c46, + 0x8c55, 0x8c9d, 0x8d64, 0x8d70, 0x8db3, 0x8eab, 0x8eca, 0x8f9b, + 0x8fb0, 0x8fc2, 0x8fc6, 0x8fc5, 0x8fc4, 0x5de1, 0x9091, 0x90a2, + 0x90aa, 0x90a6, 0x90a3, 0x9149, 0x91c6, 0x91cc, 0x9632, 0x962e, + 0x9631, 0x962a, 0x962c, 0x4e26, 0x4e56, 0x4e73, 0x4e8b, 0x4e9b, + 0x4e9e, 0x4eab, 0x4eac, 0x4f6f, 0x4f9d, 0x4f8d, 0x4f73, 0x4f7f, + 0x4f6c, 0x4f9b, 0x4f8b, 0x4f86, 0x4f83, 0x4f70, 0x4f75, 0x4f88, + 0x4f69, 0x4f7b, 0x4f96, 0x4f7e, 0x4f8f, 0x4f91, + /* 0x4c */ + 0x4f7a, 0x5154, 0x5152, 0x5155, 0x5169, 0x5177, 0x5176, 0x5178, + 0x51bd, 0x51fd, 0x523b, 0x5238, 0x5237, 0x523a, 0x5230, 0x522e, + 0x5236, 0x5241, 0x52be, 0x52bb, 0x5352, 0x5354, 0x5353, 0x5351, + 0x5366, 0x5377, 0x5378, 0x5379, 0x53d6, 0x53d4, 0x53d7, 0x5473, + 0x5475, 0x5496, 0x5478, 0x5495, 0x5480, 0x547b, 0x5477, 0x5484, + 0x5492, 0x5486, 0x547c, 0x5490, 0x5471, 0x5476, 0x548c, 0x549a, + 0x5462, 0x5468, 0x548b, 0x547d, 0x548e, 0x56fa, 0x5783, 0x5777, + 0x576a, 0x5769, 0x5761, 0x5766, 0x5764, 0x577c, 0x591c, 0x5949, + 0x5947, 0x5948, 0x5944, 0x5954, 0x59be, 0x59bb, 0x59d4, 0x59b9, + 0x59ae, 0x59d1, 0x59c6, 0x59d0, 0x59cd, 0x59cb, 0x59d3, 0x59ca, + 0x59af, 0x59b3, 0x59d2, 0x59c5, 0x5b5f, 0x5b64, 0x5b63, 0x5b97, + 0x5b9a, 0x5b98, 0x5b9c, 0x5b99, 0x5b9b, 0x5c1a, + /* 0x4d */ + 0x5c48, 0x5c45, 0x5c46, 0x5cb7, 0x5ca1, 0x5cb8, 0x5ca9, 0x5cab, + 0x5cb1, 0x5cb3, 0x5e18, 0x5e1a, 0x5e16, 0x5e15, 0x5e1b, 0x5e11, + 0x5e78, 0x5e9a, 0x5e97, 0x5e9c, 0x5e95, 0x5e96, 0x5ef6, 0x5f26, + 0x5f27, 0x5f29, 0x5f80, 0x5f81, 0x5f7f, 0x5f7c, 0x5fdd, 0x5fe0, + 0x5ffd, 0x5ff5, 0x5fff, 0x600f, 0x6014, 0x602f, 0x6035, 0x6016, + 0x602a, 0x6015, 0x6021, 0x6027, 0x6029, 0x602b, 0x601b, 0x6216, + 0x6215, 0x623f, 0x623e, 0x6240, 0x627f, 0x62c9, 0x62cc, 0x62c4, + 0x62bf, 0x62c2, 0x62b9, 0x62d2, 0x62db, 0x62ab, 0x62d3, 0x62d4, + 0x62cb, 0x62c8, 0x62a8, 0x62bd, 0x62bc, 0x62d0, 0x62d9, 0x62c7, + 0x62cd, 0x62b5, 0x62da, 0x62b1, 0x62d8, 0x62d6, 0x62d7, 0x62c6, + 0x62ac, 0x62ce, 0x653e, 0x65a7, 0x65bc, 0x65fa, 0x6614, 0x6613, + 0x660c, 0x6606, 0x6602, 0x660e, 0x6600, 0x660f, + /* 0x4e */ + 0x6615, 0x660a, 0x6607, 0x670d, 0x670b, 0x676d, 0x678b, 0x6795, + 0x6771, 0x679c, 0x6773, 0x6777, 0x6787, 0x679d, 0x6797, 0x676f, + 0x6770, 0x677f, 0x6789, 0x677e, 0x6790, 0x6775, 0x679a, 0x6793, + 0x677c, 0x676a, 0x6772, 0x6b23, 0x6b66, 0x6b67, 0x6b7f, 0x6c13, + 0x6c1b, 0x6ce3, 0x6ce8, 0x6cf3, 0x6cb1, 0x6ccc, 0x6ce5, 0x6cb3, + 0x6cbd, 0x6cbe, 0x6cbc, 0x6ce2, 0x6cab, 0x6cd5, 0x6cd3, 0x6cb8, + 0x6cc4, 0x6cb9, 0x6cc1, 0x6cae, 0x6cd7, 0x6cc5, 0x6cf1, 0x6cbf, + 0x6cbb, 0x6ce1, 0x6cdb, 0x6cca, 0x6cac, 0x6cef, 0x6cdc, 0x6cd6, + 0x6ce0, 0x7095, 0x708e, 0x7092, 0x708a, 0x7099, 0x722c, 0x722d, + 0x7238, 0x7248, 0x7267, 0x7269, 0x72c0, 0x72ce, 0x72d9, 0x72d7, + 0x72d0, 0x73a9, 0x73a8, 0x739f, 0x73ab, 0x73a5, 0x753d, 0x759d, + 0x7599, 0x759a, 0x7684, 0x76c2, 0x76f2, 0x76f4, + /* 0x4f */ + 0x77e5, 0x77fd, 0x793e, 0x7940, 0x7941, 0x79c9, 0x79c8, 0x7a7a, + 0x7a79, 0x7afa, 0x7cfe, 0x7f54, 0x7f8c, 0x7f8b, 0x8005, 0x80ba, + 0x80a5, 0x80a2, 0x80b1, 0x80a1, 0x80ab, 0x80a9, 0x80b4, 0x80aa, + 0x80af, 0x81e5, 0x81fe, 0x820d, 0x82b3, 0x829d, 0x8299, 0x82ad, + 0x82bd, 0x829f, 0x82b9, 0x82b1, 0x82ac, 0x82a5, 0x82af, 0x82b8, + 0x82a3, 0x82b0, 0x82be, 0x82b7, 0x864e, 0x8671, 0x521d, 0x8868, + 0x8ecb, 0x8fce, 0x8fd4, 0x8fd1, 0x90b5, 0x90b8, 0x90b1, 0x90b6, + 0x91c7, 0x91d1, 0x9577, 0x9580, 0x961c, 0x9640, 0x963f, 0x963b, + 0x9644, 0x9642, 0x96b9, 0x96e8, 0x9752, 0x975e, 0x4e9f, 0x4ead, + 0x4eae, 0x4fe1, 0x4fb5, 0x4faf, 0x4fbf, 0x4fe0, 0x4fd1, 0x4fcf, + 0x4fdd, 0x4fc3, 0x4fb6, 0x4fd8, 0x4fdf, 0x4fca, 0x4fd7, 0x4fae, + 0x4fd0, 0x4fc4, 0x4fc2, 0x4fda, 0x4fce, 0x4fde, + /* 0x50 */ + 0x4fb7, 0x5157, 0x5192, 0x5191, 0x51a0, 0x524e, 0x5243, 0x524a, + 0x524d, 0x524c, 0x524b, 0x5247, 0x52c7, 0x52c9, 0x52c3, 0x52c1, + 0x530d, 0x5357, 0x537b, 0x539a, 0x53db, 0x54ac, 0x54c0, 0x54a8, + 0x54ce, 0x54c9, 0x54b8, 0x54a6, 0x54b3, 0x54c7, 0x54c2, 0x54bd, + 0x54aa, 0x54c1, 0x54c4, 0x54c8, 0x54af, 0x54ab, 0x54b1, 0x54bb, + 0x54a9, 0x54a7, 0x54bf, 0x56ff, 0x5782, 0x578b, 0x57a0, 0x57a3, + 0x57a2, 0x57ce, 0x57ae, 0x5793, 0x5955, 0x5951, 0x594f, 0x594e, + 0x5950, 0x59dc, 0x59d8, 0x59ff, 0x59e3, 0x59e8, 0x5a03, 0x59e5, + 0x59ea, 0x59da, 0x59e6, 0x5a01, 0x59fb, 0x5b69, 0x5ba3, 0x5ba6, + 0x5ba4, 0x5ba2, 0x5ba5, 0x5c01, 0x5c4e, 0x5c4f, 0x5c4d, 0x5c4b, + 0x5cd9, 0x5cd2, 0x5df7, 0x5e1d, 0x5e25, 0x5e1f, 0x5e7d, 0x5ea0, + 0x5ea6, 0x5efa, 0x5f08, 0x5f2d, 0x5f65, 0x5f88, + /* 0x51 */ + 0x5f85, 0x5f8a, 0x5f8b, 0x5f87, 0x5f8c, 0x5f89, 0x6012, 0x601d, + 0x6020, 0x6025, 0x600e, 0x6028, 0x604d, 0x6070, 0x6068, 0x6062, + 0x6046, 0x6043, 0x606c, 0x606b, 0x606a, 0x6064, 0x6241, 0x62dc, + 0x6316, 0x6309, 0x62fc, 0x62ed, 0x6301, 0x62ee, 0x62fd, 0x6307, + 0x62f1, 0x62f7, 0x62ef, 0x62ec, 0x62fe, 0x62f4, 0x6311, 0x6302, + 0x653f, 0x6545, 0x65ab, 0x65bd, 0x65e2, 0x6625, 0x662d, 0x6620, + 0x6627, 0x662f, 0x661f, 0x6628, 0x6631, 0x6624, 0x66f7, 0x67ff, + 0x67d3, 0x67f1, 0x67d4, 0x67d0, 0x67ec, 0x67b6, 0x67af, 0x67f5, + 0x67e9, 0x67ef, 0x67c4, 0x67d1, 0x67b4, 0x67da, 0x67e5, 0x67b8, + 0x67cf, 0x67de, 0x67f3, 0x67b0, 0x67d9, 0x67e2, 0x67dd, 0x67d2, + 0x6b6a, 0x6b83, 0x6b86, 0x6bb5, 0x6bd2, 0x6bd7, 0x6c1f, 0x6cc9, + 0x6d0b, 0x6d32, 0x6d2a, 0x6d41, 0x6d25, 0x6d0c, + /* 0x52 */ + 0x6d31, 0x6d1e, 0x6d17, 0x6d3b, 0x6d3d, 0x6d3e, 0x6d36, 0x6d1b, + 0x6cf5, 0x6d39, 0x6d27, 0x6d38, 0x6d29, 0x6d2e, 0x6d35, 0x6d0e, + 0x6d2b, 0x70ab, 0x70ba, 0x70b3, 0x70ac, 0x70af, 0x70ad, 0x70b8, + 0x70ae, 0x70a4, 0x7230, 0x7272, 0x726f, 0x7274, 0x72e9, 0x72e0, + 0x72e1, 0x73b7, 0x73ca, 0x73bb, 0x73b2, 0x73cd, 0x73c0, 0x73b3, + 0x751a, 0x752d, 0x754f, 0x754c, 0x754e, 0x754b, 0x75ab, 0x75a4, + 0x75a5, 0x75a2, 0x75a3, 0x7678, 0x7686, 0x7687, 0x7688, 0x76c8, + 0x76c6, 0x76c3, 0x76c5, 0x7701, 0x76f9, 0x76f8, 0x7709, 0x770b, + 0x76fe, 0x76fc, 0x7707, 0x77dc, 0x7802, 0x7814, 0x780c, 0x780d, + 0x7946, 0x7949, 0x7948, 0x7947, 0x79b9, 0x79ba, 0x79d1, 0x79d2, + 0x79cb, 0x7a7f, 0x7a81, 0x7aff, 0x7afd, 0x7c7d, 0x7d02, 0x7d05, + 0x7d00, 0x7d09, 0x7d07, 0x7d04, 0x7d06, 0x7f38, + /* 0x53 */ + 0x7f8e, 0x7fbf, 0x8010, 0x800d, 0x8011, 0x8036, 0x80d6, 0x80e5, + 0x80da, 0x80c3, 0x80c4, 0x80cc, 0x80e1, 0x80db, 0x80ce, 0x80de, + 0x80e4, 0x80dd, 0x81f4, 0x8222, 0x82e7, 0x8303, 0x8305, 0x82e3, + 0x82db, 0x82e6, 0x8304, 0x82e5, 0x8302, 0x8309, 0x82d2, 0x82d7, + 0x82f1, 0x8301, 0x82dc, 0x82d4, 0x82d1, 0x82de, 0x82d3, 0x82df, + 0x82ef, 0x8306, 0x8650, 0x8679, 0x867b, 0x867a, 0x884d, 0x886b, + 0x8981, 0x89d4, 0x8a08, 0x8a02, 0x8a03, 0x8c9e, 0x8ca0, 0x8d74, + 0x8d73, 0x8db4, 0x8ecd, 0x8ecc, 0x8ff0, 0x8fe6, 0x8fe2, 0x8fea, + 0x8fe5, 0x8fed, 0x8feb, 0x8fe4, 0x8fe8, 0x90ca, 0x90ce, 0x90c1, + 0x90c3, 0x914b, 0x914a, 0x91cd, 0x9582, 0x9650, 0x964b, 0x964c, + 0x964d, 0x9762, 0x9769, 0x97cb, 0x97ed, 0x97f3, 0x9801, 0x98a8, + 0x98db, 0x98df, 0x9996, 0x9999, 0x4e58, 0x4eb3, + /* 0x54 */ + 0x500c, 0x500d, 0x5023, 0x4fef, 0x5026, 0x5025, 0x4ff8, 0x5029, + 0x5016, 0x5006, 0x503c, 0x501f, 0x501a, 0x5012, 0x5011, 0x4ffa, + 0x5000, 0x5014, 0x5028, 0x4ff1, 0x5021, 0x500b, 0x5019, 0x5018, + 0x4ff3, 0x4fee, 0x502d, 0x502a, 0x4ffe, 0x502b, 0x5009, 0x517c, + 0x51a4, 0x51a5, 0x51a2, 0x51cd, 0x51cc, 0x51c6, 0x51cb, 0x5256, + 0x525c, 0x5254, 0x525b, 0x525d, 0x532a, 0x537f, 0x539f, 0x539d, + 0x53df, 0x54e8, 0x5510, 0x5501, 0x5537, 0x54fc, 0x54e5, 0x54f2, + 0x5506, 0x54fa, 0x5514, 0x54e9, 0x54ed, 0x54e1, 0x5509, 0x54ee, + 0x54ea, 0x54e6, 0x5527, 0x5507, 0x54fd, 0x550f, 0x5703, 0x5704, + 0x57c2, 0x57d4, 0x57cb, 0x57c3, 0x5809, 0x590f, 0x5957, 0x5958, + 0x595a, 0x5a11, 0x5a18, 0x5a1c, 0x5a1f, 0x5a1b, 0x5a13, 0x59ec, + 0x5a20, 0x5a23, 0x5a29, 0x5a25, 0x5a0c, 0x5a09, + /* 0x55 */ + 0x5b6b, 0x5c58, 0x5bb0, 0x5bb3, 0x5bb6, 0x5bb4, 0x5bae, 0x5bb5, + 0x5bb9, 0x5bb8, 0x5c04, 0x5c51, 0x5c55, 0x5c50, 0x5ced, 0x5cfd, + 0x5cfb, 0x5cea, 0x5ce8, 0x5cf0, 0x5cf6, 0x5d01, 0x5cf4, 0x5dee, + 0x5e2d, 0x5e2b, 0x5eab, 0x5ead, 0x5ea7, 0x5f31, 0x5f92, 0x5f91, + 0x5f90, 0x6059, 0x6063, 0x6065, 0x6050, 0x6055, 0x606d, 0x6069, + 0x606f, 0x6084, 0x609f, 0x609a, 0x608d, 0x6094, 0x608c, 0x6085, + 0x6096, 0x6247, 0x62f3, 0x6308, 0x62ff, 0x634e, 0x633e, 0x632f, + 0x6355, 0x6342, 0x6346, 0x634f, 0x6349, 0x633a, 0x6350, 0x633d, + 0x632a, 0x632b, 0x6328, 0x634d, 0x634c, 0x6548, 0x6549, 0x6599, + 0x65c1, 0x65c5, 0x6642, 0x6649, 0x664f, 0x6643, 0x6652, 0x664c, + 0x6645, 0x6641, 0x66f8, 0x6714, 0x6715, 0x6717, 0x6821, 0x6838, + 0x6848, 0x6846, 0x6853, 0x6839, 0x6842, 0x6854, + /* 0x56 */ + 0x6829, 0x68b3, 0x6817, 0x684c, 0x6851, 0x683d, 0x67f4, 0x6850, + 0x6840, 0x683c, 0x6843, 0x682a, 0x6845, 0x6813, 0x6818, 0x6841, + 0x6b8a, 0x6b89, 0x6bb7, 0x6c23, 0x6c27, 0x6c28, 0x6c26, 0x6c24, + 0x6cf0, 0x6d6a, 0x6d95, 0x6d88, 0x6d87, 0x6d66, 0x6d78, 0x6d77, + 0x6d59, 0x6d93, 0x6d6c, 0x6d89, 0x6d6e, 0x6d5a, 0x6d74, 0x6d69, + 0x6d8c, 0x6d8a, 0x6d79, 0x6d85, 0x6d65, 0x6d94, 0x70ca, 0x70d8, + 0x70e4, 0x70d9, 0x70c8, 0x70cf, 0x7239, 0x7279, 0x72fc, 0x72f9, + 0x72fd, 0x72f8, 0x72f7, 0x7386, 0x73ed, 0x7409, 0x73ee, 0x73e0, + 0x73ea, 0x73de, 0x7554, 0x755d, 0x755c, 0x755a, 0x7559, 0x75be, + 0x75c5, 0x75c7, 0x75b2, 0x75b3, 0x75bd, 0x75bc, 0x75b9, 0x75c2, + 0x75b8, 0x768b, 0x76b0, 0x76ca, 0x76cd, 0x76ce, 0x7729, 0x771f, + 0x7720, 0x7728, 0x77e9, 0x7830, 0x7827, 0x7838, + /* 0x57 */ + 0x781d, 0x7834, 0x7837, 0x7825, 0x782d, 0x7820, 0x781f, 0x7832, + 0x7955, 0x7950, 0x7960, 0x795f, 0x7956, 0x795e, 0x795d, 0x7957, + 0x795a, 0x79e4, 0x79e3, 0x79e7, 0x79df, 0x79e6, 0x79e9, 0x79d8, + 0x7a84, 0x7a88, 0x7ad9, 0x7b06, 0x7b11, 0x7c89, 0x7d21, 0x7d17, + 0x7d0b, 0x7d0a, 0x7d20, 0x7d22, 0x7d14, 0x7d10, 0x7d15, 0x7d1a, + 0x7d1c, 0x7d0d, 0x7d19, 0x7d1b, 0x7f3a, 0x7f5f, 0x7f94, 0x7fc5, + 0x7fc1, 0x8006, 0x8004, 0x8018, 0x8015, 0x8019, 0x8017, 0x803d, + 0x803f, 0x80f1, 0x8102, 0x80f0, 0x8105, 0x80ed, 0x80f4, 0x8106, + 0x80f8, 0x80f3, 0x8108, 0x80fd, 0x810a, 0x80fc, 0x80ef, 0x81ed, + 0x81ec, 0x8200, 0x8210, 0x822a, 0x822b, 0x8228, 0x822c, 0x82bb, + 0x832b, 0x8352, 0x8354, 0x834a, 0x8338, 0x8350, 0x8349, 0x8335, + 0x8334, 0x834f, 0x8332, 0x8339, 0x8336, 0x8317, + /* 0x58 */ + 0x8340, 0x8331, 0x8328, 0x8343, 0x8654, 0x868a, 0x86aa, 0x8693, + 0x86a4, 0x86a9, 0x868c, 0x86a3, 0x869c, 0x8870, 0x8877, 0x8881, + 0x8882, 0x887d, 0x8879, 0x8a18, 0x8a10, 0x8a0e, 0x8a0c, 0x8a15, + 0x8a0a, 0x8a17, 0x8a13, 0x8a16, 0x8a0f, 0x8a11, 0x8c48, 0x8c7a, + 0x8c79, 0x8ca1, 0x8ca2, 0x8d77, 0x8eac, 0x8ed2, 0x8ed4, 0x8ecf, + 0x8fb1, 0x9001, 0x9006, 0x8ff7, 0x9000, 0x8ffa, 0x8ff4, 0x9003, + 0x8ffd, 0x9005, 0x8ff8, 0x9095, 0x90e1, 0x90dd, 0x90e2, 0x9152, + 0x914d, 0x914c, 0x91d8, 0x91dd, 0x91d7, 0x91dc, 0x91d9, 0x9583, + 0x9662, 0x9663, 0x9661, 0x965b, 0x965d, 0x9664, 0x9658, 0x965e, + 0x96bb, 0x98e2, 0x99ac, 0x9aa8, 0x9ad8, 0x9b25, 0x9b32, 0x9b3c, + 0x4e7e, 0x507a, 0x507d, 0x505c, 0x5047, 0x5043, 0x504c, 0x505a, + 0x5049, 0x5065, 0x5076, 0x504e, 0x5055, 0x5075, + /* 0x59 */ + 0x5074, 0x5077, 0x504f, 0x500f, 0x506f, 0x506d, 0x515c, 0x5195, + 0x51f0, 0x526a, 0x526f, 0x52d2, 0x52d9, 0x52d8, 0x52d5, 0x5310, + 0x530f, 0x5319, 0x533f, 0x5340, 0x533e, 0x53c3, 0x66fc, 0x5546, + 0x556a, 0x5566, 0x5544, 0x555e, 0x5561, 0x5543, 0x554a, 0x5531, + 0x5556, 0x554f, 0x5555, 0x552f, 0x5564, 0x5538, 0x552e, 0x555c, + 0x552c, 0x5563, 0x5533, 0x5541, 0x5557, 0x5708, 0x570b, 0x5709, + 0x57df, 0x5805, 0x580a, 0x5806, 0x57e0, 0x57e4, 0x57fa, 0x5802, + 0x5835, 0x57f7, 0x57f9, 0x5920, 0x5962, 0x5a36, 0x5a41, 0x5a49, + 0x5a66, 0x5a6a, 0x5a40, 0x5a3c, 0x5a62, 0x5a5a, 0x5a46, 0x5a4a, + 0x5b70, 0x5bc7, 0x5bc5, 0x5bc4, 0x5bc2, 0x5bbf, 0x5bc6, 0x5c09, + 0x5c08, 0x5c07, 0x5c60, 0x5c5c, 0x5c5d, 0x5d07, 0x5d06, 0x5d0e, + 0x5d1b, 0x5d16, 0x5d22, 0x5d11, 0x5d29, 0x5d14, + /* 0x5a */ + 0x5d19, 0x5d24, 0x5d27, 0x5d17, 0x5de2, 0x5e38, 0x5e36, 0x5e33, + 0x5e37, 0x5eb7, 0x5eb8, 0x5eb6, 0x5eb5, 0x5ebe, 0x5f35, 0x5f37, + 0x5f57, 0x5f6c, 0x5f69, 0x5f6b, 0x5f97, 0x5f99, 0x5f9e, 0x5f98, + 0x5fa1, 0x5fa0, 0x5f9c, 0x607f, 0x60a3, 0x6089, 0x60a0, 0x60a8, + 0x60cb, 0x60b4, 0x60e6, 0x60bd, 0x60c5, 0x60bb, 0x60b5, 0x60dc, + 0x60bc, 0x60d8, 0x60d5, 0x60c6, 0x60df, 0x60b8, 0x60da, 0x60c7, + 0x621a, 0x621b, 0x6248, 0x63a0, 0x63a7, 0x6372, 0x6396, 0x63a2, + 0x63a5, 0x6377, 0x6367, 0x6398, 0x63aa, 0x6371, 0x63a9, 0x6389, + 0x6383, 0x639b, 0x636b, 0x63a8, 0x6384, 0x6388, 0x6399, 0x63a1, + 0x63ac, 0x6392, 0x638f, 0x6380, 0x637b, 0x6369, 0x6368, 0x637a, + 0x655d, 0x6556, 0x6551, 0x6559, 0x6557, 0x555f, 0x654f, 0x6558, + 0x6555, 0x6554, 0x659c, 0x659b, 0x65ac, 0x65cf, + /* 0x5b */ + 0x65cb, 0x65cc, 0x65ce, 0x665d, 0x665a, 0x6664, 0x6668, 0x6666, + 0x665e, 0x66f9, 0x52d7, 0x671b, 0x6881, 0x68af, 0x68a2, 0x6893, + 0x68b5, 0x687f, 0x6876, 0x68b1, 0x68a7, 0x6897, 0x68b0, 0x6883, + 0x68c4, 0x68ad, 0x6886, 0x6885, 0x6894, 0x689d, 0x68a8, 0x689f, + 0x68a1, 0x6882, 0x6b32, 0x6bba, 0x6beb, 0x6bec, 0x6c2b, 0x6d8e, + 0x6dbc, 0x6df3, 0x6dd9, 0x6db2, 0x6de1, 0x6dcc, 0x6de4, 0x6dfb, + 0x6dfa, 0x6e05, 0x6dc7, 0x6dcb, 0x6daf, 0x6dd1, 0x6dae, 0x6dde, + 0x6df9, 0x6db8, 0x6df7, 0x6df5, 0x6dc5, 0x6dd2, 0x6e1a, 0x6db5, + 0x6dda, 0x6deb, 0x6dd8, 0x6dea, 0x6df1, 0x6dee, 0x6de8, 0x6dc6, + 0x6dc4, 0x6daa, 0x6dec, 0x6dbf, 0x6de6, 0x70f9, 0x7109, 0x710a, + 0x70fd, 0x70ef, 0x723d, 0x727d, 0x7281, 0x731c, 0x731b, 0x7316, + 0x7313, 0x7319, 0x7387, 0x7405, 0x740a, 0x7403, + /* 0x5c */ + 0x7406, 0x73fe, 0x740d, 0x74e0, 0x74f6, 0x74f7, 0x751c, 0x7522, + 0x7565, 0x7566, 0x7562, 0x7570, 0x758f, 0x75d4, 0x75d5, 0x75b5, + 0x75ca, 0x75cd, 0x768e, 0x76d4, 0x76d2, 0x76db, 0x7737, 0x773e, + 0x773c, 0x7736, 0x7738, 0x773a, 0x786b, 0x7843, 0x784e, 0x7965, + 0x7968, 0x796d, 0x79fb, 0x7a92, 0x7a95, 0x7b20, 0x7b28, 0x7b1b, + 0x7b2c, 0x7b26, 0x7b19, 0x7b1e, 0x7b2e, 0x7c92, 0x7c97, 0x7c95, + 0x7d46, 0x7d43, 0x7d71, 0x7d2e, 0x7d39, 0x7d3c, 0x7d40, 0x7d30, + 0x7d33, 0x7d44, 0x7d2f, 0x7d42, 0x7d32, 0x7d31, 0x7f3d, 0x7f9e, + 0x7f9a, 0x7fcc, 0x7fce, 0x7fd2, 0x801c, 0x804a, 0x8046, 0x812f, + 0x8116, 0x8123, 0x812b, 0x8129, 0x8130, 0x8124, 0x8202, 0x8235, + 0x8237, 0x8236, 0x8239, 0x838e, 0x839e, 0x8398, 0x8378, 0x83a2, + 0x8396, 0x83bd, 0x83ab, 0x8392, 0x838a, 0x8393, + /* 0x5d */ + 0x8389, 0x83a0, 0x8377, 0x837b, 0x837c, 0x8386, 0x83a7, 0x8655, + 0x5f6a, 0x86c7, 0x86c0, 0x86b6, 0x86c4, 0x86b5, 0x86c6, 0x86cb, + 0x86b1, 0x86af, 0x86c9, 0x8853, 0x889e, 0x8888, 0x88ab, 0x8892, + 0x8896, 0x888d, 0x888b, 0x8993, 0x898f, 0x8a2a, 0x8a1d, 0x8a23, + 0x8a25, 0x8a31, 0x8a2d, 0x8a1f, 0x8a1b, 0x8a22, 0x8c49, 0x8c5a, + 0x8ca9, 0x8cac, 0x8cab, 0x8ca8, 0x8caa, 0x8ca7, 0x8d67, 0x8d66, + 0x8dbe, 0x8dba, 0x8edb, 0x8edf, 0x9019, 0x900d, 0x901a, 0x9017, + 0x9023, 0x901f, 0x901d, 0x9010, 0x9015, 0x901e, 0x9020, 0x900f, + 0x9022, 0x9016, 0x901b, 0x9014, 0x90e8, 0x90ed, 0x90fd, 0x9157, + 0x91ce, 0x91f5, 0x91e6, 0x91e3, 0x91e7, 0x91ed, 0x91e9, 0x9589, + 0x966a, 0x9675, 0x9673, 0x9678, 0x9670, 0x9674, 0x9676, 0x9677, + 0x966c, 0x96c0, 0x96ea, 0x96e9, 0x7ae0, 0x7adf, + /* 0x5e */ + 0x9802, 0x9803, 0x9b5a, 0x9ce5, 0x9e75, 0x9e7f, 0x9ea5, 0x9ebb, + 0x50a2, 0x508d, 0x5085, 0x5099, 0x5091, 0x5080, 0x5096, 0x5098, + 0x509a, 0x6700, 0x51f1, 0x5272, 0x5274, 0x5275, 0x5269, 0x52de, + 0x52dd, 0x52db, 0x535a, 0x53a5, 0x557b, 0x5580, 0x55a7, 0x557c, + 0x558a, 0x559d, 0x5598, 0x5582, 0x559c, 0x55aa, 0x5594, 0x5587, + 0x558b, 0x5583, 0x55b3, 0x55ae, 0x559f, 0x553e, 0x55b2, 0x559a, + 0x55bb, 0x55ac, 0x55b1, 0x557e, 0x5589, 0x55ab, 0x5599, 0x570d, + 0x582f, 0x582a, 0x5834, 0x5824, 0x5830, 0x5831, 0x5821, 0x581d, + 0x5820, 0x58f9, 0x58fa, 0x5960, 0x5a77, 0x5a9a, 0x5a7f, 0x5a92, + 0x5a9b, 0x5aa7, 0x5b73, 0x5b71, 0x5bd2, 0x5bcc, 0x5bd3, 0x5bd0, + 0x5c0a, 0x5c0b, 0x5c31, 0x5d4c, 0x5d50, 0x5d34, 0x5d47, 0x5dfd, + 0x5e45, 0x5e3d, 0x5e40, 0x5e43, 0x5e7e, 0x5eca, + /* 0x5f */ + 0x5ec1, 0x5ec2, 0x5ec4, 0x5f3c, 0x5f6d, 0x5fa9, 0x5faa, 0x5fa8, + 0x60d1, 0x60e1, 0x60b2, 0x60b6, 0x60e0, 0x611c, 0x6123, 0x60fa, + 0x6115, 0x60f0, 0x60fb, 0x60f4, 0x6168, 0x60f1, 0x610e, 0x60f6, + 0x6109, 0x6100, 0x6112, 0x621f, 0x6249, 0x63a3, 0x638c, 0x63cf, + 0x63c0, 0x63e9, 0x63c9, 0x63c6, 0x63cd, 0x63d2, 0x63e3, 0x63d0, + 0x63e1, 0x63d6, 0x63ed, 0x63ee, 0x6376, 0x63f4, 0x63ea, 0x63db, + 0x6452, 0x63da, 0x63f9, 0x655e, 0x6566, 0x6562, 0x6563, 0x6591, + 0x6590, 0x65af, 0x666e, 0x6670, 0x6674, 0x6676, 0x666f, 0x6691, + 0x667a, 0x667e, 0x6677, 0x66fe, 0x66ff, 0x671f, 0x671d, 0x68fa, + 0x68d5, 0x68e0, 0x68d8, 0x68d7, 0x6905, 0x68df, 0x68f5, 0x68ee, + 0x68e7, 0x68f9, 0x68d2, 0x68f2, 0x68e3, 0x68cb, 0x68cd, 0x690d, + 0x6912, 0x690e, 0x68c9, 0x68da, 0x696e, 0x68fb, + /* 0x60 */ + 0x6b3e, 0x6b3a, 0x6b3d, 0x6b98, 0x6b96, 0x6bbc, 0x6bef, 0x6c2e, + 0x6c2f, 0x6c2c, 0x6e2f, 0x6e38, 0x6e54, 0x6e21, 0x6e32, 0x6e67, + 0x6e4a, 0x6e20, 0x6e25, 0x6e23, 0x6e1b, 0x6e5b, 0x6e58, 0x6e24, + 0x6e56, 0x6e6e, 0x6e2d, 0x6e26, 0x6e6f, 0x6e34, 0x6e4d, 0x6e3a, + 0x6e2c, 0x6e43, 0x6e1d, 0x6e3e, 0x6ecb, 0x6e89, 0x6e19, 0x6e4e, + 0x6e63, 0x6e44, 0x6e72, 0x6e69, 0x6e5f, 0x7119, 0x711a, 0x7126, + 0x7130, 0x7121, 0x7136, 0x716e, 0x711c, 0x724c, 0x7284, 0x7280, + 0x7336, 0x7325, 0x7334, 0x7329, 0x743a, 0x742a, 0x7433, 0x7422, + 0x7425, 0x7435, 0x7436, 0x7434, 0x742f, 0x741b, 0x7426, 0x7428, + 0x7525, 0x7526, 0x756b, 0x756a, 0x75e2, 0x75db, 0x75e3, 0x75d9, + 0x75d8, 0x75de, 0x75e0, 0x767b, 0x767c, 0x7696, 0x7693, 0x76b4, + 0x76dc, 0x774f, 0x77ed, 0x785d, 0x786c, 0x786f, + /* 0x61 */ + 0x7a0d, 0x7a08, 0x7a0b, 0x7a05, 0x7a00, 0x7a98, 0x7a97, 0x7a96, + 0x7ae5, 0x7ae3, 0x7b49, 0x7b56, 0x7b46, 0x7b50, 0x7b52, 0x7b54, + 0x7b4d, 0x7b4b, 0x7b4f, 0x7b51, 0x7c9f, 0x7ca5, 0x7d5e, 0x7d50, + 0x7d68, 0x7d55, 0x7d2b, 0x7d6e, 0x7d72, 0x7d61, 0x7d66, 0x7d62, + 0x7d70, 0x7d73, 0x5584, 0x7fd4, 0x7fd5, 0x800b, 0x8052, 0x8085, + 0x8155, 0x8154, 0x814b, 0x8151, 0x814e, 0x8139, 0x8146, 0x813e, + 0x814c, 0x8153, 0x8174, 0x8212, 0x821c, 0x83e9, 0x8403, 0x83f8, + 0x840d, 0x83e0, 0x83c5, 0x840b, 0x83c1, 0x83ef, 0x83f1, 0x83f4, + 0x8457, 0x840a, 0x83f0, 0x840c, 0x83cc, 0x83fd, 0x83f2, 0x83ca, + 0x8438, 0x840e, 0x8404, 0x83dc, 0x8407, 0x83d4, 0x83df, 0x865b, + 0x86df, 0x86d9, 0x86ed, 0x86d4, 0x86db, 0x86e4, 0x86d0, 0x86de, + 0x8857, 0x88c1, 0x88c2, 0x88b1, 0x8983, 0x8996, + /* 0x62 */ + 0x8a3b, 0x8a60, 0x8a55, 0x8a5e, 0x8a3c, 0x8a41, 0x8a54, 0x8a5b, + 0x8a50, 0x8a46, 0x8a34, 0x8a3a, 0x8a36, 0x8a56, 0x8c61, 0x8c82, + 0x8caf, 0x8cbc, 0x8cb3, 0x8cbd, 0x8cc1, 0x8cbb, 0x8cc0, 0x8cb4, + 0x8cb7, 0x8cb6, 0x8cbf, 0x8cb8, 0x8d8a, 0x8d85, 0x8d81, 0x8dce, + 0x8ddd, 0x8dcb, 0x8dda, 0x8dd1, 0x8dcc, 0x8ddb, 0x8dc6, 0x8efb, + 0x8ef8, 0x8efc, 0x8f9c, 0x902e, 0x9035, 0x9031, 0x9038, 0x9032, + 0x9036, 0x9102, 0x90f5, 0x9109, 0x90fe, 0x9163, 0x9165, 0x91cf, + 0x9214, 0x9215, 0x9223, 0x9209, 0x921e, 0x920d, 0x9210, 0x9207, + 0x9211, 0x9594, 0x958f, 0x958b, 0x9591, 0x9593, 0x9592, 0x958e, + 0x968a, 0x968e, 0x968b, 0x967d, 0x9685, 0x9686, 0x968d, 0x9672, + 0x9684, 0x96c1, 0x96c5, 0x96c4, 0x96c6, 0x96c7, 0x96ef, 0x96f2, + 0x97cc, 0x9805, 0x9806, 0x9808, 0x98e7, 0x98ea, + /* 0x63 */ + 0x98ef, 0x98e9, 0x98f2, 0x98ed, 0x99ae, 0x99ad, 0x9ec3, 0x9ecd, + 0x9ed1, 0x4e82, 0x50ad, 0x50b5, 0x50b2, 0x50b3, 0x50c5, 0x50be, + 0x50ac, 0x50b7, 0x50bb, 0x50af, 0x50c7, 0x527f, 0x5277, 0x527d, + 0x52df, 0x52e6, 0x52e4, 0x52e2, 0x52e3, 0x532f, 0x55df, 0x55e8, + 0x55d3, 0x55e6, 0x55ce, 0x55dc, 0x55c7, 0x55d1, 0x55e3, 0x55e4, + 0x55ef, 0x55da, 0x55e1, 0x55c5, 0x55c6, 0x55e5, 0x55c9, 0x5712, + 0x5713, 0x585e, 0x5851, 0x5858, 0x5857, 0x585a, 0x5854, 0x586b, + 0x584c, 0x586d, 0x584a, 0x5862, 0x5852, 0x584b, 0x5967, 0x5ac1, + 0x5ac9, 0x5acc, 0x5abe, 0x5abd, 0x5abc, 0x5ab3, 0x5ac2, 0x5ab2, + 0x5d69, 0x5d6f, 0x5e4c, 0x5e79, 0x5ec9, 0x5ec8, 0x5f12, 0x5f59, + 0x5fac, 0x5fae, 0x611a, 0x610f, 0x6148, 0x611f, 0x60f3, 0x611b, + 0x60f9, 0x6101, 0x6108, 0x614e, 0x614c, 0x6144, + /* 0x64 */ + 0x614d, 0x613e, 0x6134, 0x6127, 0x610d, 0x6106, 0x6137, 0x6221, + 0x6222, 0x6413, 0x643e, 0x641e, 0x642a, 0x642d, 0x643d, 0x642c, + 0x640f, 0x641c, 0x6414, 0x640d, 0x6436, 0x6416, 0x6417, 0x6406, + 0x656c, 0x659f, 0x65b0, 0x6697, 0x6689, 0x6687, 0x6688, 0x6696, + 0x6684, 0x6698, 0x668d, 0x6703, 0x6994, 0x696d, 0x695a, 0x6977, + 0x6960, 0x6954, 0x6975, 0x6930, 0x6982, 0x694a, 0x6968, 0x696b, + 0x695e, 0x6953, 0x6979, 0x6986, 0x695d, 0x6963, 0x695b, 0x6b47, + 0x6b72, 0x6bc0, 0x6bbf, 0x6bd3, 0x6bfd, 0x6ea2, 0x6eaf, 0x6ed3, + 0x6eb6, 0x6ec2, 0x6e90, 0x6e9d, 0x6ec7, 0x6ec5, 0x6ea5, 0x6e98, + 0x6ebc, 0x6eba, 0x6eab, 0x6ed1, 0x6e96, 0x6e9c, 0x6ec4, 0x6ed4, + 0x6eaa, 0x6ea7, 0x6eb4, 0x714e, 0x7159, 0x7169, 0x7164, 0x7149, + 0x7167, 0x715c, 0x716c, 0x7166, 0x714c, 0x7165, + /* 0x65 */ + 0x715e, 0x7146, 0x7168, 0x7156, 0x723a, 0x7252, 0x7337, 0x7345, + 0x733f, 0x733e, 0x746f, 0x745a, 0x7455, 0x745f, 0x745e, 0x7441, + 0x743f, 0x7459, 0x745b, 0x745c, 0x7576, 0x7578, 0x7600, 0x75f0, + 0x7601, 0x75f2, 0x75f1, 0x75fa, 0x75ff, 0x75f4, 0x75f3, 0x76de, + 0x76df, 0x775b, 0x776b, 0x7766, 0x775e, 0x7763, 0x7779, 0x776a, + 0x776c, 0x775c, 0x7765, 0x7768, 0x7762, 0x77ee, 0x788e, 0x78b0, + 0x7897, 0x7898, 0x788c, 0x7889, 0x787c, 0x7891, 0x7893, 0x787f, + 0x797a, 0x797f, 0x7981, 0x842c, 0x79bd, 0x7a1c, 0x7a1a, 0x7a20, + 0x7a14, 0x7a1f, 0x7a1e, 0x7a9f, 0x7aa0, 0x7b77, 0x7bc0, 0x7b60, + 0x7b6e, 0x7b67, 0x7cb1, 0x7cb3, 0x7cb5, 0x7d93, 0x7d79, 0x7d91, + 0x7d81, 0x7d8f, 0x7d5b, 0x7f6e, 0x7f69, 0x7f6a, 0x7f72, 0x7fa9, + 0x7fa8, 0x7fa4, 0x8056, 0x8058, 0x8086, 0x8084, + /* 0x66 */ + 0x8171, 0x8170, 0x8178, 0x8165, 0x816e, 0x8173, 0x816b, 0x8179, + 0x817a, 0x8166, 0x8205, 0x8247, 0x8482, 0x8477, 0x843d, 0x8431, + 0x8475, 0x8466, 0x846b, 0x8449, 0x846c, 0x845b, 0x843c, 0x8435, + 0x8461, 0x8463, 0x8469, 0x846d, 0x8446, 0x865e, 0x865c, 0x865f, + 0x86f9, 0x8713, 0x8708, 0x8707, 0x8700, 0x86fe, 0x86fb, 0x8702, + 0x8703, 0x8706, 0x870a, 0x8859, 0x88df, 0x88d4, 0x88d9, 0x88dc, + 0x88d8, 0x88dd, 0x88e1, 0x88ca, 0x88d5, 0x88d2, 0x899c, 0x89e3, + 0x8a6b, 0x8a72, 0x8a73, 0x8a66, 0x8a69, 0x8a70, 0x8a87, 0x8a7c, + 0x8a63, 0x8aa0, 0x8a71, 0x8a85, 0x8a6d, 0x8a62, 0x8a6e, 0x8a6c, + 0x8a79, 0x8a7b, 0x8a3e, 0x8a68, 0x8c62, 0x8c8a, 0x8c89, 0x8cca, + 0x8cc7, 0x8cc8, 0x8cc4, 0x8cb2, 0x8cc3, 0x8cc2, 0x8cc5, 0x8de1, + 0x8ddf, 0x8de8, 0x8def, 0x8df3, 0x8dfa, 0x8dea, + /* 0x67 */ + 0x8de4, 0x8de6, 0x8eb2, 0x8f03, 0x8f09, 0x8efe, 0x8f0a, 0x8f9f, + 0x8fb2, 0x904b, 0x904a, 0x9053, 0x9042, 0x9054, 0x903c, 0x9055, + 0x9050, 0x9047, 0x904f, 0x904e, 0x904d, 0x9051, 0x903e, 0x9041, + 0x9112, 0x9117, 0x916c, 0x916a, 0x9169, 0x91c9, 0x9237, 0x9257, + 0x9238, 0x923d, 0x9240, 0x923e, 0x925b, 0x924b, 0x9264, 0x9251, + 0x9234, 0x9249, 0x924d, 0x9245, 0x9239, 0x923f, 0x925a, 0x9598, + 0x9698, 0x9694, 0x9695, 0x96cd, 0x96cb, 0x96c9, 0x96ca, 0x96f7, + 0x96fb, 0x96f9, 0x96f6, 0x9756, 0x9774, 0x9776, 0x9810, 0x9811, + 0x9813, 0x980a, 0x9812, 0x980c, 0x98fc, 0x98f4, 0x98fd, 0x98fe, + 0x99b3, 0x99b1, 0x99b4, 0x9ae1, 0x9ce9, 0x9e82, 0x9f0e, 0x9f13, + 0x9f20, 0x50e7, 0x50ee, 0x50e5, 0x50d6, 0x50ed, 0x50da, 0x50d5, + 0x50cf, 0x50d1, 0x50f1, 0x50ce, 0x50e9, 0x5162, + /* 0x68 */ + 0x51f3, 0x5283, 0x5282, 0x5331, 0x53ad, 0x55fe, 0x5600, 0x561b, + 0x5617, 0x55fd, 0x5614, 0x5606, 0x5609, 0x560d, 0x560e, 0x55f7, + 0x5616, 0x561f, 0x5608, 0x5610, 0x55f6, 0x5718, 0x5716, 0x5875, + 0x587e, 0x5883, 0x5893, 0x588a, 0x5879, 0x5885, 0x587d, 0x58fd, + 0x5925, 0x5922, 0x5924, 0x596a, 0x5969, 0x5ae1, 0x5ae6, 0x5ae9, + 0x5ad7, 0x5ad6, 0x5ad8, 0x5ae3, 0x5b75, 0x5bde, 0x5be7, 0x5be1, + 0x5be5, 0x5be6, 0x5be8, 0x5be2, 0x5be4, 0x5bdf, 0x5c0d, 0x5c62, + 0x5d84, 0x5d87, 0x5e5b, 0x5e63, 0x5e55, 0x5e57, 0x5e54, 0x5ed3, + 0x5ed6, 0x5f0a, 0x5f46, 0x5f70, 0x5fb9, 0x6147, 0x613f, 0x614b, + 0x6177, 0x6162, 0x6163, 0x615f, 0x615a, 0x6158, 0x6175, 0x622a, + 0x6487, 0x6458, 0x6454, 0x64a4, 0x6478, 0x645f, 0x647a, 0x6451, + 0x6467, 0x6434, 0x646d, 0x647b, 0x6572, 0x65a1, + /* 0x69 */ + 0x65d7, 0x65d6, 0x66a2, 0x66a8, 0x669d, 0x699c, 0x69a8, 0x6995, + 0x69c1, 0x69ae, 0x69d3, 0x69cb, 0x699b, 0x69b7, 0x69bb, 0x69ab, + 0x69b4, 0x69d0, 0x69cd, 0x69ad, 0x69cc, 0x69a6, 0x69c3, 0x69a3, + 0x6b49, 0x6b4c, 0x6c33, 0x6f33, 0x6f14, 0x6efe, 0x6f13, 0x6ef4, + 0x6f29, 0x6f3e, 0x6f20, 0x6f2c, 0x6f0f, 0x6f02, 0x6f22, 0x6eff, + 0x6eef, 0x6f06, 0x6f31, 0x6f38, 0x6f32, 0x6f23, 0x6f15, 0x6f2b, + 0x6f2f, 0x6f88, 0x6f2a, 0x6eec, 0x6f01, 0x6ef2, 0x6ecc, 0x6ef7, + 0x7194, 0x7199, 0x717d, 0x718a, 0x7184, 0x7192, 0x723e, 0x7292, + 0x7296, 0x7344, 0x7350, 0x7464, 0x7463, 0x746a, 0x7470, 0x746d, + 0x7504, 0x7591, 0x7627, 0x760d, 0x760b, 0x7609, 0x7613, 0x76e1, + 0x76e3, 0x7784, 0x777d, 0x777f, 0x7761, 0x78c1, 0x789f, 0x78a7, + 0x78b3, 0x78a9, 0x78a3, 0x798e, 0x798f, 0x798d, + /* 0x6a */ + 0x7a2e, 0x7a31, 0x7aaa, 0x7aa9, 0x7aed, 0x7aef, 0x7ba1, 0x7b95, + 0x7b8b, 0x7b75, 0x7b97, 0x7b9d, 0x7b94, 0x7b8f, 0x7bb8, 0x7b87, + 0x7b84, 0x7cb9, 0x7cbd, 0x7cbe, 0x7dbb, 0x7db0, 0x7d9c, 0x7dbd, + 0x7dbe, 0x7da0, 0x7dca, 0x7db4, 0x7db2, 0x7db1, 0x7dba, 0x7da2, + 0x7dbf, 0x7db5, 0x7db8, 0x7dad, 0x7dd2, 0x7dc7, 0x7dac, 0x7f70, + 0x7fe0, 0x7fe1, 0x7fdf, 0x805e, 0x805a, 0x8087, 0x8150, 0x8180, + 0x818f, 0x8188, 0x818a, 0x817f, 0x8182, 0x81e7, 0x81fa, 0x8207, + 0x8214, 0x821e, 0x824b, 0x84c9, 0x84bf, 0x84c6, 0x84c4, 0x8499, + 0x849e, 0x84b2, 0x849c, 0x84cb, 0x84b8, 0x84c0, 0x84d3, 0x8490, + 0x84bc, 0x84d1, 0x84ca, 0x873f, 0x871c, 0x873b, 0x8722, 0x8725, + 0x8734, 0x8718, 0x8755, 0x8737, 0x8729, 0x88f3, 0x8902, 0x88f4, + 0x88f9, 0x88f8, 0x88fd, 0x88e8, 0x891a, 0x88ef, + /* 0x6b */ + 0x8aa6, 0x8a8c, 0x8a9e, 0x8aa3, 0x8a8d, 0x8aa1, 0x8a93, 0x8aa4, + 0x8aaa, 0x8aa5, 0x8aa8, 0x8a98, 0x8a91, 0x8a9a, 0x8aa7, 0x8c6a, + 0x8c8d, 0x8c8c, 0x8cd3, 0x8cd1, 0x8cd2, 0x8d6b, 0x8d99, 0x8d95, + 0x8dfc, 0x8f14, 0x8f12, 0x8f15, 0x8f13, 0x8fa3, 0x9060, 0x9058, + 0x905c, 0x9063, 0x9059, 0x905e, 0x9062, 0x905d, 0x905b, 0x9119, + 0x9118, 0x911e, 0x9175, 0x9178, 0x9177, 0x9174, 0x9278, 0x92ac, + 0x9280, 0x9285, 0x9298, 0x9296, 0x927b, 0x9293, 0x929c, 0x92a8, + 0x927c, 0x9291, 0x95a1, 0x95a8, 0x95a9, 0x95a3, 0x95a5, 0x95a4, + 0x9699, 0x969c, 0x969b, 0x96cc, 0x96d2, 0x9700, 0x977c, 0x9785, + 0x97f6, 0x9817, 0x9818, 0x98af, 0x98b1, 0x9903, 0x9905, 0x990c, + 0x9909, 0x99c1, 0x9aaf, 0x9ab0, 0x9ae6, 0x9b41, 0x9b42, 0x9cf4, + 0x9cf6, 0x9cf3, 0x9ebc, 0x9f3b, 0x9f4a, 0x5104, + /* 0x6c */ + 0x5100, 0x50fb, 0x50f5, 0x50f9, 0x5102, 0x5108, 0x5109, 0x5105, + 0x51dc, 0x5287, 0x5288, 0x5289, 0x528d, 0x528a, 0x52f0, 0x53b2, + 0x562e, 0x563b, 0x5639, 0x5632, 0x563f, 0x5634, 0x5629, 0x5653, + 0x564e, 0x5657, 0x5674, 0x5636, 0x562f, 0x5630, 0x5880, 0x589f, + 0x589e, 0x58b3, 0x589c, 0x58ae, 0x58a9, 0x58a6, 0x596d, 0x5b09, + 0x5afb, 0x5b0b, 0x5af5, 0x5b0c, 0x5b08, 0x5bee, 0x5bec, 0x5be9, + 0x5beb, 0x5c64, 0x5c65, 0x5d9d, 0x5d94, 0x5e62, 0x5e5f, 0x5e61, + 0x5ee2, 0x5eda, 0x5edf, 0x5edd, 0x5ee3, 0x5ee0, 0x5f48, 0x5f71, + 0x5fb7, 0x5fb5, 0x6176, 0x6167, 0x616e, 0x615d, 0x6155, 0x6182, + 0x617c, 0x6170, 0x616b, 0x617e, 0x61a7, 0x6190, 0x61ab, 0x618e, + 0x61ac, 0x619a, 0x61a4, 0x6194, 0x61ae, 0x622e, 0x6469, 0x646f, + 0x6479, 0x649e, 0x64b2, 0x6488, 0x6490, 0x64b0, + /* 0x6d */ + 0x64a5, 0x6493, 0x6495, 0x64a9, 0x6492, 0x64ae, 0x64ad, 0x64ab, + 0x649a, 0x64ac, 0x6499, 0x64a2, 0x64b3, 0x6575, 0x6577, 0x6578, + 0x66ae, 0x66ab, 0x66b4, 0x66b1, 0x6a23, 0x6a1f, 0x69e8, 0x6a01, + 0x6a1e, 0x6a19, 0x69fd, 0x6a21, 0x6a13, 0x6a0a, 0x69f3, 0x6a02, + 0x6a05, 0x69ed, 0x6a11, 0x6b50, 0x6b4e, 0x6ba4, 0x6bc5, 0x6bc6, + 0x6f3f, 0x6f7c, 0x6f84, 0x6f51, 0x6f66, 0x6f54, 0x6f86, 0x6f6d, + 0x6f5b, 0x6f78, 0x6f6e, 0x6f8e, 0x6f7a, 0x6f70, 0x6f64, 0x6f97, + 0x6f58, 0x6ed5, 0x6f6f, 0x6f60, 0x6f5f, 0x719f, 0x71ac, 0x71b1, + 0x71a8, 0x7256, 0x729b, 0x734e, 0x7357, 0x7469, 0x748b, 0x7483, + 0x747e, 0x7480, 0x757f, 0x7620, 0x7629, 0x761f, 0x7624, 0x7626, + 0x7621, 0x7622, 0x769a, 0x76ba, 0x76e4, 0x778e, 0x7787, 0x778c, + 0x7791, 0x778b, 0x78cb, 0x78c5, 0x78ba, 0x78ca, + /* 0x6e */ + 0x78be, 0x78d5, 0x78bc, 0x78d0, 0x7a3f, 0x7a3c, 0x7a40, 0x7a3d, + 0x7a37, 0x7a3b, 0x7aaf, 0x7aae, 0x7bad, 0x7bb1, 0x7bc4, 0x7bb4, + 0x7bc6, 0x7bc7, 0x7bc1, 0x7ba0, 0x7bcc, 0x7cca, 0x7de0, 0x7df4, + 0x7def, 0x7dfb, 0x7dd8, 0x7dec, 0x7ddd, 0x7de8, 0x7de3, 0x7dda, + 0x7dde, 0x7de9, 0x7d9e, 0x7dd9, 0x7df2, 0x7df9, 0x7f75, 0x7f77, + 0x7faf, 0x7fe9, 0x8026, 0x819b, 0x819c, 0x819d, 0x81a0, 0x819a, + 0x8198, 0x8517, 0x853d, 0x851a, 0x84ee, 0x852c, 0x852d, 0x8513, + 0x8511, 0x8523, 0x8521, 0x8514, 0x84ec, 0x8525, 0x84ff, 0x8506, + 0x8782, 0x8774, 0x8776, 0x8760, 0x8766, 0x8778, 0x8768, 0x8759, + 0x8757, 0x874c, 0x8753, 0x885b, 0x885d, 0x8910, 0x8907, 0x8912, + 0x8913, 0x8915, 0x890a, 0x8abc, 0x8ad2, 0x8ac7, 0x8ac4, 0x8a95, + 0x8acb, 0x8af8, 0x8ab2, 0x8ac9, 0x8ac2, 0x8abf, + /* 0x6f */ + 0x8ab0, 0x8ad6, 0x8acd, 0x8ab6, 0x8ab9, 0x8adb, 0x8c4c, 0x8c4e, + 0x8c6c, 0x8ce0, 0x8cde, 0x8ce6, 0x8ce4, 0x8cec, 0x8ced, 0x8ce2, + 0x8ce3, 0x8cdc, 0x8cea, 0x8ce1, 0x8d6d, 0x8d9f, 0x8da3, 0x8e2b, + 0x8e10, 0x8e1d, 0x8e22, 0x8e0f, 0x8e29, 0x8e1f, 0x8e21, 0x8e1e, + 0x8eba, 0x8f1d, 0x8f1b, 0x8f1f, 0x8f29, 0x8f26, 0x8f2a, 0x8f1c, + 0x8f1e, 0x8f25, 0x9069, 0x906e, 0x9068, 0x906d, 0x9077, 0x9130, + 0x912d, 0x9127, 0x9131, 0x9187, 0x9189, 0x918b, 0x9183, 0x92c5, + 0x92bb, 0x92b7, 0x92ea, 0x92e4, 0x92c1, 0x92b3, 0x92bc, 0x92d2, + 0x92c7, 0x92f0, 0x92b2, 0x95ad, 0x95b1, 0x9704, 0x9706, 0x9707, + 0x9709, 0x9760, 0x978d, 0x978b, 0x978f, 0x9821, 0x982b, 0x981c, + 0x98b3, 0x990a, 0x9913, 0x9912, 0x9918, 0x99dd, 0x99d0, 0x99df, + 0x99db, 0x99d1, 0x99d5, 0x99d2, 0x99d9, 0x9ab7, + /* 0x70 */ + 0x9aee, 0x9aef, 0x9b27, 0x9b45, 0x9b44, 0x9b77, 0x9b6f, 0x9d06, + 0x9d09, 0x9d03, 0x9ea9, 0x9ebe, 0x9ece, 0x58a8, 0x9f52, 0x5112, + 0x5118, 0x5114, 0x5110, 0x5115, 0x5180, 0x51aa, 0x51dd, 0x5291, + 0x5293, 0x52f3, 0x5659, 0x566b, 0x5679, 0x5669, 0x5664, 0x5678, + 0x566a, 0x5668, 0x5665, 0x5671, 0x566f, 0x566c, 0x5662, 0x5676, + 0x58c1, 0x58be, 0x58c7, 0x58c5, 0x596e, 0x5b1d, 0x5b34, 0x5b78, + 0x5bf0, 0x5c0e, 0x5f4a, 0x61b2, 0x6191, 0x61a9, 0x618a, 0x61cd, + 0x61b6, 0x61be, 0x61ca, 0x61c8, 0x6230, 0x64c5, 0x64c1, 0x64cb, + 0x64bb, 0x64bc, 0x64da, 0x64c4, 0x64c7, 0x64c2, 0x64cd, 0x64bf, + 0x64d2, 0x64d4, 0x64be, 0x6574, 0x66c6, 0x66c9, 0x66b9, 0x66c4, + 0x66c7, 0x66b8, 0x6a3d, 0x6a38, 0x6a3a, 0x6a59, 0x6a6b, 0x6a58, + 0x6a39, 0x6a44, 0x6a62, 0x6a61, 0x6a4b, 0x6a47, + /* 0x71 */ + 0x6a35, 0x6a5f, 0x6a48, 0x6b59, 0x6b77, 0x6c05, 0x6fc2, 0x6fb1, + 0x6fa1, 0x6fc3, 0x6fa4, 0x6fc1, 0x6fa7, 0x6fb3, 0x6fc0, 0x6fb9, + 0x6fb6, 0x6fa6, 0x6fa0, 0x6fb4, 0x71be, 0x71c9, 0x71d0, 0x71d2, + 0x71c8, 0x71d5, 0x71b9, 0x71ce, 0x71d9, 0x71dc, 0x71c3, 0x71c4, + 0x7368, 0x749c, 0x74a3, 0x7498, 0x749f, 0x749e, 0x74e2, 0x750c, + 0x750d, 0x7634, 0x7638, 0x763a, 0x76e7, 0x76e5, 0x77a0, 0x779e, + 0x779f, 0x77a5, 0x78e8, 0x78da, 0x78ec, 0x78e7, 0x79a6, 0x7a4d, + 0x7a4e, 0x7a46, 0x7a4c, 0x7a4b, 0x7aba, 0x7bd9, 0x7c11, 0x7bc9, + 0x7be4, 0x7bdb, 0x7be1, 0x7be9, 0x7be6, 0x7cd5, 0x7cd6, 0x7e0a, + 0x7e11, 0x7e08, 0x7e1b, 0x7e23, 0x7e1e, 0x7e1d, 0x7e09, 0x7e10, + 0x7f79, 0x7fb2, 0x7ff0, 0x7ff1, 0x7fee, 0x8028, 0x81b3, 0x81a9, + 0x81a8, 0x81fb, 0x8208, 0x8258, 0x8259, 0x854a, + /* 0x72 */ + 0x8559, 0x8548, 0x8568, 0x8569, 0x8543, 0x8549, 0x856d, 0x856a, + 0x855e, 0x8783, 0x879f, 0x879e, 0x87a2, 0x878d, 0x8861, 0x892a, + 0x8932, 0x8925, 0x892b, 0x8921, 0x89aa, 0x89a6, 0x8ae6, 0x8afa, + 0x8aeb, 0x8af1, 0x8b00, 0x8adc, 0x8ae7, 0x8aee, 0x8afe, 0x8b01, + 0x8b02, 0x8af7, 0x8aed, 0x8af3, 0x8af6, 0x8afc, 0x8c6b, 0x8c6d, + 0x8c93, 0x8cf4, 0x8e44, 0x8e31, 0x8e34, 0x8e42, 0x8e39, 0x8e35, + 0x8f3b, 0x8f2f, 0x8f38, 0x8f33, 0x8fa8, 0x8fa6, 0x9075, 0x9074, + 0x9078, 0x9072, 0x907c, 0x907a, 0x9134, 0x9192, 0x9320, 0x9336, + 0x92f8, 0x9333, 0x932f, 0x9322, 0x92fc, 0x932b, 0x9304, 0x931a, + 0x9310, 0x9326, 0x9321, 0x9315, 0x932e, 0x9319, 0x95bb, 0x96a7, + 0x96a8, 0x96aa, 0x96d5, 0x970e, 0x9711, 0x9716, 0x970d, 0x9713, + 0x970f, 0x975b, 0x975c, 0x9766, 0x9798, 0x9830, + /* 0x73 */ + 0x9838, 0x983b, 0x9837, 0x982d, 0x9839, 0x9824, 0x9910, 0x9928, + 0x991e, 0x991b, 0x9921, 0x991a, 0x99ed, 0x99e2, 0x99f1, 0x9ab8, + 0x9abc, 0x9afb, 0x9aed, 0x9b28, 0x9b91, 0x9d15, 0x9d23, 0x9d26, + 0x9d28, 0x9d12, 0x9d1b, 0x9ed8, 0x9ed4, 0x9f8d, 0x9f9c, 0x512a, + 0x511f, 0x5121, 0x5132, 0x52f5, 0x568e, 0x5680, 0x5690, 0x5685, + 0x5687, 0x568f, 0x58d5, 0x58d3, 0x58d1, 0x58ce, 0x5b30, 0x5b2a, + 0x5b24, 0x5b7a, 0x5c37, 0x5c68, 0x5dbc, 0x5dba, 0x5dbd, 0x5db8, + 0x5e6b, 0x5f4c, 0x5fbd, 0x61c9, 0x61c2, 0x61c7, 0x61e6, 0x61cb, + 0x6232, 0x6234, 0x64ce, 0x64ca, 0x64d8, 0x64e0, 0x64f0, 0x64e6, + 0x64ec, 0x64f1, 0x64e2, 0x64ed, 0x6582, 0x6583, 0x66d9, 0x66d6, + 0x6a80, 0x6a94, 0x6a84, 0x6aa2, 0x6a9c, 0x6adb, 0x6aa3, 0x6a7e, + 0x6a97, 0x6a90, 0x6aa0, 0x6b5c, 0x6bae, 0x6bda, + /* 0x74 */ + 0x6c08, 0x6fd8, 0x6ff1, 0x6fdf, 0x6fe0, 0x6fdb, 0x6fe4, 0x6feb, + 0x6fef, 0x6f80, 0x6fec, 0x6fe1, 0x6fe9, 0x6fd5, 0x6fee, 0x6ff0, + 0x71e7, 0x71df, 0x71ee, 0x71e6, 0x71e5, 0x71ed, 0x71ec, 0x71f4, + 0x71e0, 0x7235, 0x7246, 0x7370, 0x7372, 0x74a9, 0x74b0, 0x74a6, + 0x74a8, 0x7646, 0x7642, 0x764c, 0x76ea, 0x77b3, 0x77aa, 0x77b0, + 0x77ac, 0x77a7, 0x77ad, 0x77ef, 0x78f7, 0x78fa, 0x78f4, 0x78ef, + 0x7901, 0x79a7, 0x79aa, 0x7a57, 0x7abf, 0x7c07, 0x7c0d, 0x7bfe, + 0x7bf7, 0x7c0c, 0x7be0, 0x7ce0, 0x7cdc, 0x7cde, 0x7ce2, 0x7cdf, + 0x7cd9, 0x7cdd, 0x7e2e, 0x7e3e, 0x7e46, 0x7e37, 0x7e32, 0x7e43, + 0x7e2b, 0x7e3d, 0x7e31, 0x7e45, 0x7e41, 0x7e34, 0x7e39, 0x7e48, + 0x7e35, 0x7e3f, 0x7e2f, 0x7f44, 0x7ff3, 0x7ffc, 0x8071, 0x8072, + 0x8070, 0x806f, 0x8073, 0x81c6, 0x81c3, 0x81ba, + /* 0x75 */ + 0x81c2, 0x81c0, 0x81bf, 0x81bd, 0x81c9, 0x81be, 0x81e8, 0x8209, + 0x8271, 0x85aa, 0x8584, 0x857e, 0x859c, 0x8591, 0x8594, 0x85af, + 0x859b, 0x8587, 0x85a8, 0x858a, 0x85a6, 0x8667, 0x87c0, 0x87d1, + 0x87b3, 0x87d2, 0x87c6, 0x87ab, 0x87bb, 0x87ba, 0x87c8, 0x87cb, + 0x893b, 0x8936, 0x8944, 0x8938, 0x893d, 0x89ac, 0x8b0e, 0x8b17, + 0x8b19, 0x8b1b, 0x8b0a, 0x8b20, 0x8b1d, 0x8b04, 0x8b10, 0x8c41, + 0x8c3f, 0x8c73, 0x8cfa, 0x8cfd, 0x8cfc, 0x8cf8, 0x8cfb, 0x8da8, + 0x8e49, 0x8e4b, 0x8e48, 0x8e4a, 0x8f44, 0x8f3e, 0x8f42, 0x8f45, + 0x8f3f, 0x907f, 0x907d, 0x9084, 0x9081, 0x9082, 0x9080, 0x9139, + 0x91a3, 0x919e, 0x919c, 0x934d, 0x9382, 0x9328, 0x9375, 0x934a, + 0x9365, 0x934b, 0x9318, 0x937e, 0x936c, 0x935b, 0x9370, 0x935a, + 0x9354, 0x95ca, 0x95cb, 0x95cc, 0x95c8, 0x95c6, + /* 0x76 */ + 0x96b1, 0x96b8, 0x96d6, 0x971c, 0x971e, 0x97a0, 0x97d3, 0x9846, + 0x98b6, 0x9935, 0x9a01, 0x99ff, 0x9bae, 0x9bab, 0x9baa, 0x9bad, + 0x9d3b, 0x9d3f, 0x9e8b, 0x9ecf, 0x9ede, 0x9edc, 0x9edd, 0x9edb, + 0x9f3e, 0x9f4b, 0x53e2, 0x5695, 0x56ae, 0x58d9, 0x58d8, 0x5b38, + 0x5f5e, 0x61e3, 0x6233, 0x64f4, 0x64f2, 0x64fe, 0x6506, 0x64fa, + 0x64fb, 0x64f7, 0x65b7, 0x66dc, 0x6726, 0x6ab3, 0x6aac, 0x6ac3, + 0x6abb, 0x6ab8, 0x6ac2, 0x6aae, 0x6aaf, 0x6b5f, 0x6b78, 0x6baf, + 0x7009, 0x700b, 0x6ffe, 0x7006, 0x6ffa, 0x7011, 0x700f, 0x71fb, + 0x71fc, 0x71fe, 0x71f8, 0x7377, 0x7375, 0x74a7, 0x74bf, 0x7515, + 0x7656, 0x7658, 0x7652, 0x77bd, 0x77bf, 0x77bb, 0x77bc, 0x790e, + 0x79ae, 0x7a61, 0x7a62, 0x7a60, 0x7ac4, 0x7ac5, 0x7c2b, 0x7c27, + 0x7c2a, 0x7c1e, 0x7c23, 0x7c21, 0x7ce7, 0x7e54, + /* 0x77 */ + 0x7e55, 0x7e5e, 0x7e5a, 0x7e61, 0x7e52, 0x7e59, 0x7f48, 0x7ff9, + 0x7ffb, 0x8077, 0x8076, 0x81cd, 0x81cf, 0x820a, 0x85cf, 0x85a9, + 0x85cd, 0x85d0, 0x85c9, 0x85b0, 0x85ba, 0x85b9, 0x87ef, 0x87ec, + 0x87f2, 0x87e0, 0x8986, 0x89b2, 0x89f4, 0x8b28, 0x8b39, 0x8b2c, + 0x8b2b, 0x8c50, 0x8d05, 0x8e59, 0x8e63, 0x8e66, 0x8e64, 0x8e5f, + 0x8e55, 0x8ec0, 0x8f49, 0x8f4d, 0x9087, 0x9083, 0x9088, 0x91ab, + 0x91ac, 0x91d0, 0x9394, 0x938a, 0x9396, 0x93a2, 0x93b3, 0x93ae, + 0x93ac, 0x93b0, 0x9398, 0x939a, 0x9397, 0x95d4, 0x95d6, 0x95d0, + 0x95d5, 0x96e2, 0x96dc, 0x96d9, 0x96db, 0x96de, 0x9724, 0x97a3, + 0x97a6, 0x97ad, 0x97f9, 0x984d, 0x984f, 0x984c, 0x984e, 0x9853, + 0x98ba, 0x993e, 0x993f, 0x993d, 0x992e, 0x99a5, 0x9a0e, 0x9ac1, + 0x9b03, 0x9b06, 0x9b4f, 0x9b4e, 0x9b4d, 0x9bca, + /* 0x78 */ + 0x9bc9, 0x9bfd, 0x9bc8, 0x9bc0, 0x9d51, 0x9d5d, 0x9d60, 0x9ee0, + 0x9f15, 0x9f2c, 0x5133, 0x56a5, 0x56a8, 0x58de, 0x58df, 0x58e2, + 0x5bf5, 0x9f90, 0x5eec, 0x61f2, 0x61f7, 0x61f6, 0x61f5, 0x6500, + 0x650f, 0x66e0, 0x66dd, 0x6ae5, 0x6add, 0x6ada, 0x6ad3, 0x701b, + 0x701f, 0x7028, 0x701a, 0x701d, 0x7015, 0x7018, 0x7206, 0x720d, + 0x7258, 0x72a2, 0x7378, 0x737a, 0x74bd, 0x74ca, 0x74e3, 0x7587, + 0x7586, 0x765f, 0x7661, 0x77c7, 0x7919, 0x79b1, 0x7a6b, 0x7a69, + 0x7c3e, 0x7c3f, 0x7c38, 0x7c3d, 0x7c37, 0x7c40, 0x7e6b, 0x7e6d, + 0x7e79, 0x7e69, 0x7e6a, 0x7e73, 0x7f85, 0x7fb6, 0x7fb9, 0x7fb8, + 0x81d8, 0x85e9, 0x85dd, 0x85ea, 0x85d5, 0x85e4, 0x85e5, 0x85f7, + 0x87fb, 0x8805, 0x880d, 0x87f9, 0x87fe, 0x8960, 0x895f, 0x8956, + 0x895e, 0x8b41, 0x8b5c, 0x8b58, 0x8b49, 0x8b5a, + /* 0x79 */ + 0x8b4e, 0x8b4f, 0x8b46, 0x8b59, 0x8d08, 0x8d0a, 0x8e7c, 0x8e72, + 0x8e87, 0x8e76, 0x8e6c, 0x8e7a, 0x8e74, 0x8f54, 0x8f4e, 0x8fad, + 0x908a, 0x908b, 0x91b1, 0x91ae, 0x93e1, 0x93d1, 0x93df, 0x93c3, + 0x93c8, 0x93dc, 0x93dd, 0x93d6, 0x93e2, 0x93cd, 0x93d8, 0x93e4, + 0x93d7, 0x93e8, 0x95dc, 0x96b4, 0x96e3, 0x972a, 0x9727, 0x9761, + 0x97dc, 0x97fb, 0x985e, 0x9858, 0x985b, 0x98bc, 0x9945, 0x9949, + 0x9a16, 0x9a19, 0x9b0d, 0x9be8, 0x9be7, 0x9bd6, 0x9bdb, 0x9d89, + 0x9d61, 0x9d72, 0x9d6a, 0x9d6c, 0x9e92, 0x9e97, 0x9e93, 0x9eb4, + 0x52f8, 0x56b7, 0x56b6, 0x56b4, 0x56bc, 0x58e4, 0x5b40, 0x5b43, + 0x5b7d, 0x5bf6, 0x5dc9, 0x61f8, 0x61fa, 0x6518, 0x6514, 0x6519, + 0x66e6, 0x6727, 0x6aec, 0x703e, 0x7030, 0x7032, 0x7210, 0x737b, + 0x74cf, 0x7662, 0x7665, 0x7926, 0x792a, 0x792c, + /* 0x7a */ + 0x792b, 0x7ac7, 0x7af6, 0x7c4c, 0x7c43, 0x7c4d, 0x7cef, 0x7cf0, + 0x8fae, 0x7e7d, 0x7e7c, 0x7e82, 0x7f4c, 0x8000, 0x81da, 0x8266, + 0x85fb, 0x85f9, 0x8611, 0x85fa, 0x8606, 0x860b, 0x8607, 0x860a, + 0x8814, 0x8815, 0x8964, 0x89ba, 0x89f8, 0x8b70, 0x8b6c, 0x8b66, + 0x8b6f, 0x8b5f, 0x8b6b, 0x8d0f, 0x8d0d, 0x8e89, 0x8e81, 0x8e85, + 0x8e82, 0x91b4, 0x91cb, 0x9418, 0x9403, 0x93fd, 0x95e1, 0x9730, + 0x98c4, 0x9952, 0x9951, 0x99a8, 0x9a2b, 0x9a30, 0x9a37, 0x9a35, + 0x9c13, 0x9c0d, 0x9e79, 0x9eb5, 0x9ee8, 0x9f2f, 0x9f5f, 0x9f63, + 0x9f61, 0x5137, 0x5138, 0x56c1, 0x56c0, 0x56c2, 0x5914, 0x5c6c, + 0x5dcd, 0x61fc, 0x61fe, 0x651d, 0x651c, 0x6595, 0x66e9, 0x6afb, + 0x6b04, 0x6afa, 0x6bb2, 0x704c, 0x721b, 0x72a7, 0x74d6, 0x74d4, + 0x7669, 0x77d3, 0x7c50, 0x7e8f, 0x7e8c, 0x7fbc, + /* 0x7b */ + 0x8617, 0x862d, 0x861a, 0x8823, 0x8822, 0x8821, 0x881f, 0x896a, + 0x896c, 0x89bd, 0x8b74, 0x8b77, 0x8b7d, 0x8d13, 0x8e8a, 0x8e8d, + 0x8e8b, 0x8f5f, 0x8faf, 0x91ba, 0x942e, 0x9433, 0x9435, 0x943a, + 0x9438, 0x9432, 0x942b, 0x95e2, 0x9738, 0x9739, 0x9732, 0x97ff, + 0x9867, 0x9865, 0x9957, 0x9a45, 0x9a43, 0x9a40, 0x9a3e, 0x9acf, + 0x9b54, 0x9b51, 0x9c2d, 0x9c25, 0x9daf, 0x9db4, 0x9dc2, 0x9db8, + 0x9e9d, 0x9eef, 0x9f19, 0x9f5c, 0x9f66, 0x9f67, 0x513c, 0x513b, + 0x56c8, 0x56ca, 0x56c9, 0x5b7f, 0x5dd4, 0x5dd2, 0x5f4e, 0x61ff, + 0x6524, 0x6b0a, 0x6b61, 0x7051, 0x7058, 0x7380, 0x74e4, 0x758a, + 0x766e, 0x766c, 0x79b3, 0x7c60, 0x7c5f, 0x807e, 0x807d, 0x81df, + 0x8972, 0x896f, 0x89fc, 0x8b80, 0x8d16, 0x8d17, 0x8e91, 0x8e93, + 0x8f61, 0x9148, 0x9444, 0x9451, 0x9452, 0x973d, + /* 0x7c */ + 0x973e, 0x97c3, 0x97c1, 0x986b, 0x9955, 0x9a55, 0x9a4d, 0x9ad2, + 0x9b1a, 0x9c49, 0x9c31, 0x9c3e, 0x9c3b, 0x9dd3, 0x9dd7, 0x9f34, + 0x9f6c, 0x9f6a, 0x9f94, 0x56cc, 0x5dd6, 0x6200, 0x6523, 0x652b, + 0x652a, 0x66ec, 0x6b10, 0x74da, 0x7aca, 0x7c64, 0x7c63, 0x7c65, + 0x7e93, 0x7e96, 0x7e94, 0x81e2, 0x8638, 0x863f, 0x8831, 0x8b8a, + 0x9090, 0x908f, 0x9463, 0x9460, 0x9464, 0x9768, 0x986f, 0x995c, + 0x9a5a, 0x9a5b, 0x9a57, 0x9ad3, 0x9ad4, 0x9ad1, 0x9c54, 0x9c57, + 0x9c56, 0x9de5, 0x9e9f, 0x9ef4, 0x56d1, 0x58e9, 0x652c, 0x705e, + 0x7671, 0x7672, 0x77d7, 0x7f50, 0x7f88, 0x8836, 0x8839, 0x8862, + 0x8b93, 0x8b92, 0x8b96, 0x8277, 0x8d1b, 0x91c0, 0x946a, 0x9742, + 0x9748, 0x9744, 0x97c6, 0x9870, 0x9a5f, 0x9b22, 0x9b58, 0x9c5f, + 0x9df9, 0x9dfa, 0x9e7c, 0x9e7d, 0x9f07, 0x9f77, + /* 0x7d */ + 0x9f72, 0x5ef3, 0x6b16, 0x7063, 0x7c6c, 0x7c6e, 0x883b, 0x89c0, + 0x8ea1, 0x91c1, 0x9472, 0x9470, 0x9871, 0x995e, 0x9ad6, 0x9b23, + 0x9ecc, 0x7064, 0x77da, 0x8b9a, 0x9477, 0x97c9, 0x9a62, 0x9a65, + 0x7e9c, 0x8b9c, 0x8eaa, 0x91c5, 0x947d, 0x947e, 0x947c, 0x9c77, + 0x9c78, 0x9ef7, 0x8c54, 0x947f, 0x9e1a, 0x7228, 0x9a6a, 0x9b31, + 0x9e1b, 0x9e1e, 0x7c72, +}; + +static int +cns11643_1_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x21 && c1 <= 0x27) || (c1 == 0x42) || (c1 >= 0x44 && c1 <= 0x7d)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + unsigned short wc = 0xfffd; + if (i < 3102) { + if (i < 500) + wc = cns11643_1_2uni_page21[i]; + else if (i == 571) + wc = 0x4ea0; + else if (i == 578) + wc = 0x51ab; + else if (i == 583) + wc = 0x52f9; + } else if (i < 3290) { + if (i < 3136) + wc = cns11643_1_2uni_page42[i-3102]; + } else { + if (i < 8691) + wc = cns11643_1_2uni_page44[i-3290]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + diff --git a/graf2d/win32gdk/gdk/src/iconv/cns11643_15.h b/graf2d/win32gdk/gdk/src/iconv/cns11643_15.h new file mode 100644 index 0000000000000..cfe0ba69bcc5a --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cns11643_15.h @@ -0,0 +1,1083 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CNS 11643-1992 plane 15 + */ + +static const unsigned short cns11643_15_2uni_page21[7169] = { + /* 0x21 */ + 0x5302, 0x538c, 0x53d4, 0x54a5, 0x5392, 0x5393, 0x53d8, 0x53d9, + 0x54a7, 0x592b, 0x592c, 0x592d, 0x5930, 0x592e, 0x59ab, 0x1a01, + 0x5c2d, 0x5c6d, 0xfa34, 0x5d0f, 0x52fd, 0x5e9d, 0x64a2, 0x68d4, + 0x6e56, 0x6ec3, 0x7314, 0x52fd, 0x9a1a, 0x530f, 0x5310, 0x539a, + 0x539b, 0x52fd, 0x54ac, 0x0036, 0x5397, 0x5846, 0x0e4f, 0x5876, + 0x5877, 0x58ae, 0x593a, 0x597d, 0x6ec5, 0x5ea8, 0x52fd, 0x1afa, + 0x6541, 0x6542, 0x68d8, 0x68d9, 0x69aa, 0x69ab, 0x6c42, 0x6c41, + 0x5099, 0x6ec6, 0x52fd, 0x7035, 0x7036, 0x7037, 0xfa83, 0xb64d, + 0x52fd, 0x74b5, 0x7617, 0x7782, 0x86b6, 0x2d49, 0x8f72, 0x985c, + 0x98a8, 0x45b7, 0x68e3, 0x0006, 0x52fd, 0x53e6, 0x5444, 0x5445, + 0x1729, 0x003e, 0x54c4, 0x54c5, 0x54c6, 0x54c7, 0x54c8, 0x54c9, + 0x54ca, 0x54d4, 0x587d, 0xb572, 0x58b2, 0x58b4, + /* 0x22 */ + 0x5982, 0x59c7, 0x59c8, 0x52fd, 0x5b3c, 0x5b3d, 0x5b3e, 0x5b3f, + 0xfa24, 0x5bd3, 0x5447, 0x1a4e, 0x5d3d, 0x5de2, 0x5eb8, 0x5eb9, + 0x5ec2, 0x5eba, 0x5ec6, 0x5ebb, 0x64ad, 0x654c, 0x654d, 0x52fd, + 0x69b2, 0x69b3, 0x69b4, 0x69b5, 0x6cc3, 0x6cc4, 0x6cc5, 0x6cc6, + 0x6cc7, 0x52fd, 0x6ece, 0x6f30, 0x7047, 0x7048, 0x2281, 0x735c, + 0x52fd, 0x735f, 0x7618, 0x7619, 0x767e, 0x2410, 0x78b0, 0x7d75, + 0x2568, 0x7d76, 0x8341, 0x8442, 0x52fd, 0x86bd, 0x2842, 0x2840, + 0x18ea, 0x8e1e, 0x8e1f, 0x8f87, 0x2d62, 0x8f78, 0x9488, 0x9489, + 0x948a, 0x9917, 0x9915, 0x52fd, 0x52fd, 0x3291, 0xa3e5, 0xa909, + 0xaa3b, 0xaa4f, 0x52fd, 0xb92e, 0xb92f, 0xbdff, 0xbdfd, 0xbdfe, + 0x45bb, 0x45bc, 0x52fd, 0x5323, 0x53ea, 0x542a, 0x5449, 0x544a, + 0x544b, 0x54df, 0x54e0, 0x54e1, 0x54e2, 0x58c1, + /* 0x23 */ + 0x54e3, 0x54e4, 0x54e5, 0x58c0, 0x54e6, 0x54f7, 0x52fd, 0x54e7, + 0x54e8, 0x54e9, 0x54ea, 0x54eb, 0x580e, 0x5880, 0x5881, 0x58ba, + 0x58bb, 0x58bc, 0x58bd, 0x593f, 0x5940, 0x5988, 0xfa1f, 0x5b46, + 0x52fd, 0x5b47, 0x5b48, 0x5c36, 0x5c72, 0x5c96, 0x5d47, 0x5de7, + 0x5e34, 0x5e35, 0x5e36, 0x5e37, 0x5ee3, 0x5ee4, 0x5ee5, 0x5eeb, + 0x0175, 0x5ee6, 0x5ee7, 0x5ee8, 0x52fd, 0x52fd, 0x64b9, 0x1de8, + 0x64ba, 0x1e5b, 0x6563, 0x6564, 0x52fd, 0x6565, 0x52fd, 0x6566, + 0x657c, 0x6567, 0xfa5a, 0x6859, 0x68e9, 0x68ea, 0x68eb, 0x68ec, + 0x68ed, 0x68ee, 0x68ef, 0x69bf, 0x69cb, 0x69c3, 0x69d5, 0x69c4, + 0x69c5, 0x69d3, 0x69c6, 0x69c7, 0x69c8, 0x69c9, 0x69ca, 0x6c4a, + 0x52fd, 0x6cd1, 0x6e61, 0x6f37, 0x52fd, 0x7064, 0x7066, 0x2299, + 0x7067, 0x7068, 0x7069, 0x2297, 0x7073, 0x706a, + /* 0x24 */ + 0x706b, 0x2862, 0x52fd, 0x7372, 0x043c, 0x74b9, 0x761c, 0x7636, + 0x76bc, 0x76be, 0x76bf, 0x76c0, 0x7787, 0x78dc, 0x78dd, 0x78f5, + 0x78de, 0x78df, 0xfa9e, 0x78e0, 0x78e1, 0x78e2, 0x7d2c, 0x7d2d, + 0x25a4, 0x7da9, 0x7d9c, 0x7d9d, 0x7d9e, 0x7d9f, 0x7da0, 0x7da1, + 0x7da2, 0x52fd, 0x7da3, 0x7da4, 0x7da7, 0x8342, 0x8393, 0x8451, + 0x52fd, 0x8452, 0x8444, 0x8453, 0x8622, 0x86c6, 0x86c7, 0x86c9, + 0xfadd, 0x86ca, 0x2866, 0x86c8, 0x8e24, 0x8e25, 0x8e26, 0x52fd, + 0x8e27, 0x8e28, 0x52fd, 0x8f58, 0xfafb, 0x8fa7, 0x8f88, 0x8f89, + 0x8fa5, 0x8fa8, 0x8fa9, 0x8faa, 0x8fab, 0x8fac, 0x8fad, 0x2da3, + 0x8f79, 0x52fd, 0x9494, 0x9495, 0x9496, 0x09a5, 0x52fd, 0x9497, + 0x307f, 0x9498, 0x984e, 0x984f, 0x9919, 0x52fd, 0x9a41, 0xfb2a, + 0x9bf7, 0x9f04, 0x9f19, 0x9f17, 0xa340, 0xa3ec, + /* 0x25 */ + 0xa71b, 0xa71c, 0x36f6, 0xa90e, 0xaa52, 0xadd8, 0xb126, 0xb574, + 0x52fd, 0xb575, 0xbcc6, 0xbe0b, 0xbe0c, 0xbe0d, 0xbe0e, 0xbe0f, + 0xbe10, 0x45c8, 0xd759, 0xd75a, 0xd983, 0xd984, 0xd985, 0x52fd, + 0x4af5, 0xe120, 0xe121, 0xe122, 0xe123, 0xe124, 0xe129, 0x53f4, + 0x52fd, 0x688f, 0x5451, 0x17ab, 0x5517, 0x5518, 0x555b, 0x5519, + 0x551a, 0x0053, 0x551b, 0x551c, 0x551d, 0x551e, 0x551f, 0x5520, + 0x5521, 0x578b, 0x5788, 0x222d, 0x5885, 0xb587, 0x58c7, 0x594c, + 0x594d, 0x59fc, 0x59fd, 0x59fe, 0x59ff, 0x52fd, 0x52fd, 0x5b56, + 0x5b57, 0x5b58, 0x5b59, 0x5bdc, 0x5bdd, 0x5c73, 0x5c9d, 0x5ca1, + 0x5c9e, 0x5c9f, 0x5ca0, 0x5ce6, 0x5d51, 0x5d52, 0x5e3d, 0x5f22, + 0x1b9c, 0x5f23, 0x5f24, 0x5f25, 0x5f26, 0x5f27, 0x5f28, 0x5f29, + 0x5f2a, 0x5f2b, 0x52fd, 0x5f40, 0x5f2c, 0x5f2d, + /* 0x26 */ + 0x5f2e, 0x5f2f, 0x5f30, 0x64d0, 0x65a8, 0x6594, 0x6595, 0x6596, + 0x6597, 0x6598, 0x659c, 0x659b, 0x52fd, 0x65a1, 0x65a0, 0x6599, + 0x659a, 0x65a7, 0x1e88, 0x6864, 0x52fd, 0x6900, 0x6901, 0x52fd, + 0x52fd, 0x69e5, 0x69e9, 0x69fb, 0x69fc, 0x69ea, 0x69eb, 0x69ec, + 0x69ed, 0x69ee, 0x69ef, 0x69fa, 0x69f0, 0x69f1, 0x69f2, 0x69f3, + 0x69f4, 0x6c52, 0x6c53, 0x6c54, 0x6c55, 0x6c58, 0x6c56, 0x52fd, + 0x6cdd, 0x6cde, 0x6ce3, 0x6cdf, 0x6ce0, 0x6e22, 0x6e23, 0x6e68, + 0x6edf, 0x00ac, 0x6f44, 0x7094, 0x7095, 0x7096, 0x7097, 0x7098, + 0x7099, 0xfa79, 0x709a, 0x709b, 0x709d, 0x709e, 0x709f, 0x70a0, + 0x72f3, 0x72f2, 0x731f, 0x7388, 0x748f, 0x7490, 0x52fd, 0x74fd, + 0x74fe, 0x74ff, 0x7500, 0x7501, 0x791a, 0x52fd, 0x78e3, 0x78e4, + 0x78e5, 0x78e6, 0x78e7, 0x78eb, 0x78e8, 0x78e9, + /* 0x27 */ + 0x78ea, 0x791d, 0x7ca4, 0x7ca3, 0x7dd4, 0x7dc6, 0x7dc7, 0x7dc8, + 0x7dc9, 0x7dca, 0x7dcb, 0x7dcc, 0x7dcd, 0x05de, 0x7dce, 0x25c3, + 0x81b8, 0x81b9, 0x81ba, 0x836e, 0x83db, 0x83dc, 0x8468, 0x8469, + 0x846a, 0x846b, 0x846c, 0x846d, 0x846e, 0x2719, 0x8624, 0x8625, + 0x52fd, 0x8700, 0x86e5, 0x86f9, 0x86e7, 0x86e8, 0x86e9, 0x86fe, + 0x86ea, 0x86eb, 0x86ec, 0x0749, 0x86ed, 0x28a1, 0x86ee, 0x28a6, + 0x86ef, 0x52fd, 0x8717, 0x86f0, 0x86f1, 0x8b94, 0x8c5b, 0x8c5c, + 0x8c5d, 0x8e2f, 0x0891, 0x8e30, 0x8e31, 0x8e32, 0x8e33, 0x8fcc, + 0x8fcd, 0x8fce, 0x8fae, 0x8faf, 0x8fb0, 0x08d3, 0x8fcf, 0x8fd0, + 0x8fd1, 0x8fd2, 0x8fd3, 0x52fd, 0x8fd4, 0x09a9, 0x94a6, 0x94a7, + 0x94a8, 0x94b0, 0x94a9, 0x94aa, 0x94ab, 0x94ac, 0x94ad, 0x97fb, + 0x97fc, 0x52fd, 0x992d, 0x992e, 0x9950, 0x992f, + /* 0x28 */ + 0x9930, 0x9a65, 0x9be6, 0x9c0c, 0x9c02, 0x9c03, 0x9c04, 0x9c05, + 0x9c06, 0x52fd, 0x9ec0, 0x9f24, 0x9f25, 0xa016, 0xa032, 0xa720, + 0xa721, 0xa722, 0xa723, 0x36fe, 0xa725, 0xa919, 0xa924, 0xa91a, + 0xa91b, 0xa91c, 0xa91d, 0xfb52, 0xa91e, 0xaa5a, 0xaa5b, 0xaa5c, + 0xaa5d, 0xaa5e, 0xac31, 0x52fd, 0xb129, 0x52fd, 0xb288, 0xb289, + 0xb589, 0x3d57, 0xb656, 0xb7d1, 0xb7e6, 0xb832, 0xb833, 0xb952, + 0xb953, 0x0ed5, 0xb954, 0xb955, 0x52fd, 0x52fd, 0xbe29, 0xbe2a, + 0xbe2b, 0xbe2c, 0xbe2d, 0xfb92, 0xbe2e, 0xbe2f, 0xbe30, 0xbe31, + 0xbe32, 0xbe33, 0x3ec5, 0xbe34, 0xc49b, 0xc523, 0xc524, 0x52fd, + 0xc525, 0xc527, 0xc916, 0xcfa0, 0xd76f, 0x45df, 0xd770, 0xd771, + 0x45dc, 0x138c, 0xd772, 0xd773, 0xd774, 0xd99c, 0xd9aa, 0xd99d, + 0xd99e, 0x0c99, 0xd9ab, 0xd99f, 0xe135, 0xe138, + /* 0x29 */ + 0xf68d, 0x5335, 0x5336, 0xadee, 0x53b4, 0xf9c9, 0x5432, 0x5455, + 0x5544, 0x5545, 0x5546, 0x5547, 0x17e4, 0x5548, 0x5549, 0x52fd, + 0x554a, 0x554b, 0x554c, 0x554d, 0x554e, 0x554f, 0x5550, 0x5551, + 0xb599, 0x58d1, 0x52fd, 0x58d2, 0x58d3, 0x58d4, 0x58d5, 0x5a21, + 0x5a22, 0x5a23, 0x5b68, 0x5b69, 0x5b6a, 0x5be2, 0x5c45, 0x5cec, + 0x5ced, 0x5cee, 0x5cef, 0x52fd, 0x5d62, 0x5d63, 0x5df4, 0x536f, + 0x5e44, 0x5e45, 0x5f79, 0x1c1b, 0x5f7a, 0x5f7b, 0x5f7c, 0x5f7d, + 0x5f7e, 0x5f7f, 0x5f80, 0x0188, 0x52fd, 0x5f81, 0x5f82, 0x5f83, + 0x5f84, 0x5f85, 0x5f86, 0x5f87, 0x5f8f, 0x5f88, 0x5f89, 0x65c5, + 0x65c6, 0x1eaa, 0x65c7, 0x65c8, 0x65c9, 0x65ca, 0x65cb, 0x65cc, + 0x1eab, 0x65cd, 0x65ce, 0x65e3, 0x65cf, 0x65d0, 0x65d1, 0x65d2, + 0x65d3, 0x65c4, 0x65d4, 0x65d5, 0x65d6, 0x6820, + /* 0x2a */ + 0x6821, 0x691a, 0x6912, 0x6914, 0x6915, 0x6916, 0x6919, 0x6917, + 0x6918, 0x02c9, 0xfa61, 0x52fd, 0x6a12, 0x6a13, 0x6a14, 0x6a15, + 0x6a16, 0x6a17, 0x6a18, 0x6a19, 0x6c61, 0x6c62, 0x6c63, 0x6cf5, + 0x21a9, 0x6cf6, 0x6cf7, 0x6cf8, 0x6e29, 0x0517, 0x6f5d, 0x6f57, + 0x6f58, 0x6f59, 0x6f5a, 0x6f5b, 0x70bb, 0x70d1, 0x70bc, 0x70bd, + 0xbbdf, 0x70d0, 0x70be, 0x70bf, 0x70c0, 0x70c1, 0x70c2, 0x70c3, + 0x70c4, 0xbe6c, 0x73a1, 0x73a2, 0x73a3, 0x7493, 0x750d, 0x750f, + 0x750e, 0x7510, 0x7511, 0x7512, 0xfa95, 0x77e5, 0x792f, 0x52fd, + 0x7957, 0x7930, 0x7968, 0x792b, 0x7931, 0x7958, 0xfaa2, 0x7932, + 0x7959, 0x52fd, 0x795a, 0x7933, 0x795b, 0x795c, 0x795d, 0x791e, + 0x7cae, 0x7caf, 0x7d3b, 0x7d3c, 0x7d3d, 0x7e07, 0x7e08, 0x7e09, + 0x7e0a, 0x7e0b, 0x7e0c, 0x7e0d, 0x7e0e, 0x7e0f, + /* 0x2b */ + 0x7e10, 0x7e22, 0x7e11, 0x7e12, 0x7e13, 0x7e14, 0x7e15, 0x7e16, + 0x7e17, 0x7e18, 0xfab8, 0x52fd, 0x8346, 0x8347, 0x8348, 0x83e1, + 0x8481, 0x8483, 0x5f75, 0x52fd, 0x8485, 0x8486, 0x862a, 0xfad1, + 0x862b, 0x866b, 0x8718, 0x8719, 0x871a, 0x52fd, 0x871b, 0x871c, + 0x871d, 0x871e, 0x871f, 0x8720, 0x8721, 0x8722, 0x8723, 0x2911, + 0x8724, 0x8725, 0x8726, 0x8727, 0x8728, 0x8729, 0x872a, 0x8cef, + 0x8e49, 0x8e4a, 0x8e4b, 0x8e4c, 0x8e4d, 0x8e4e, 0x8e4f, 0x8e50, + 0x8e51, 0x8e52, 0x8e53, 0x8e54, 0x8e5a, 0x8e55, 0x8f5f, 0x9002, + 0x9003, 0x9004, 0x9005, 0x8fd5, 0x9006, 0x9007, 0x8fd6, 0x9008, + 0x9009, 0x900a, 0x900b, 0x8fd7, 0x900c, 0x900d, 0x94c8, 0x94c9, + 0x94ca, 0x94cb, 0x94cc, 0x94cd, 0x94ce, 0x94cf, 0x94d0, 0x94d1, + 0x94d2, 0x3451, 0x94d3, 0x94d4, 0x94d5, 0x94d6, + /* 0x2c */ + 0x94d7, 0x94e2, 0x94d8, 0x9804, 0x9805, 0x9806, 0x52fd, 0x9943, + 0x9944, 0x9a84, 0x9a8f, 0x9a85, 0x9a86, 0x9c2f, 0x9c1a, 0x9c1b, + 0x9c1c, 0x0abd, 0x9c1d, 0x9c1e, 0x9c1f, 0x9c20, 0x9c21, 0x9c22, + 0xfb2c, 0x9c23, 0x9c24, 0x9c0e, 0x9c25, 0x9c2b, 0x9c2c, 0x9c0b, + 0x9dee, 0x52fd, 0x9ec3, 0x9ed8, 0x9ed9, 0x9f38, 0x9f39, 0x9f3a, + 0x9f3b, 0x3453, 0x9f3c, 0x9f3d, 0x9f3e, 0x9f3f, 0x9f40, 0xa048, + 0xa04c, 0xa228, 0xa251, 0xa252, 0xa34c, 0xa423, 0xfb45, 0xa424, + 0xa731, 0xa732, 0xa733, 0x3718, 0xa734, 0xa735, 0xa736, 0xa740, + 0xa737, 0x52fd, 0xa738, 0xa73d, 0xa938, 0xa939, 0xa93a, 0xa93b, + 0xa93c, 0xa94c, 0xaa73, 0xaa74, 0x0d33, 0xaa75, 0xaa76, 0xaa79, + 0xac41, 0xac42, 0xac43, 0xad5b, 0x52fd, 0x39d7, 0x8ba6, 0xad5c, + 0xade5, 0xade6, 0xade7, 0xade8, 0xaded, 0xb130, + /* 0x2d */ + 0x3b7e, 0xb131, 0xb294, 0xb651, 0xb6fd, 0xb6fe, 0xb7e9, 0x52fd, + 0xb9b3, 0xb984, 0xb994, 0x52fd, 0xb99c, 0x52fd, 0xb985, 0xbc00, + 0xbc37, 0xbc57, 0xbe54, 0xbe68, 0xbe55, 0xbe5c, 0xbe56, 0xbe57, + 0xbe58, 0xbe59, 0xbe5a, 0xbe5b, 0xc534, 0x407e, 0xc535, 0x52fd, + 0xc539, 0xc536, 0xc537, 0xc538, 0xc8e5, 0xc959, 0x52fd, 0xc93a, + 0xc93b, 0xd028, 0xd189, 0x52fd, 0xd18a, 0xd18b, 0xd18c, 0xd18d, + 0xd2bc, 0xd5a3, 0x1344, 0xd5a4, 0xd793, 0xd794, 0xd795, 0xd796, + 0xd797, 0xd9b9, 0xe14f, 0xe150, 0xe151, 0xe376, 0x52fd, 0x53fb, + 0x5383, 0x5438, 0x545d, 0x5571, 0x52fd, 0x5577, 0x5578, 0xfa07, + 0x55c3, 0x5579, 0x557a, 0x557b, 0x557c, 0x5572, 0x557d, 0x55a0, + 0x557e, 0x557f, 0x5580, 0x5581, 0x5582, 0x5583, 0x559e, 0x5584, + 0x5585, 0x5586, 0x5587, 0x5588, 0x5793, 0x5794, + /* 0x2e */ + 0x5795, 0x57ef, 0x57f0, 0x52fd, 0x588d, 0x588f, 0x5890, 0x5891, + 0x5892, 0x58de, 0x58e1, 0x5953, 0x1966, 0x5a4a, 0x5a4b, 0x5a4c, + 0x5a51, 0x5a4d, 0x5a48, 0x5b74, 0x5b75, 0x5c20, 0x5c21, 0x5ca5, + 0x5ca6, 0x5d73, 0x5d74, 0x5e50, 0x5e51, 0x5e52, 0x5e53, 0x5fdb, + 0x5fdc, 0x1c20, 0x5fdd, 0x5fde, 0x5fff, 0x52fd, 0x52fd, 0x5fdf, + 0x5fe0, 0x1c21, 0x5fe1, 0x5fe2, 0x5fe3, 0x5fe4, 0x5fe5, 0x5fe6, + 0x5fe7, 0x5fe8, 0x5fe9, 0x5fea, 0x6607, 0x6608, 0x6609, 0x660a, + 0x660b, 0x660c, 0x660d, 0x1ed7, 0x661a, 0x660e, 0x660f, 0x6610, + 0x661c, 0x6827, 0x6866, 0x6898, 0x6899, 0x6933, 0x6924, 0x6925, + 0x6926, 0x52fd, 0x02e1, 0x6a3e, 0xfa64, 0x6a3f, 0x6a57, 0x6a40, + 0x6a41, 0x6a58, 0x6a42, 0x6a43, 0x6a44, 0x6a45, 0x6a46, 0x02e2, + 0x6a47, 0x6c6b, 0x6c6c, 0x6d10, 0x6d11, 0x21be, + /* 0x2f */ + 0x6e75, 0x6eef, 0x6f6a, 0x6f6b, 0x52fd, 0x6f6c, 0x6f6d, 0x6f6e, + 0x70ef, 0x70f0, 0x70f1, 0x70f2, 0x70f3, 0x70f4, 0x70f5, 0x70ff, + 0x70f6, 0x7102, 0x70f7, 0x7322, 0x73c4, 0x73c3, 0x7528, 0x047c, + 0x7620, 0x7625, 0x7622, 0x7623, 0x76eb, 0x04e3, 0x77f9, 0x77fa, + 0x7999, 0x799a, 0x799b, 0x7963, 0x52fd, 0x795e, 0x795f, 0x7960, + 0x799c, 0x7961, 0x799d, 0x7e54, 0x7e55, 0x7e56, 0x7e57, 0x7e58, + 0x7e59, 0x7e5a, 0x7e19, 0x7e6a, 0x7e5b, 0x7e5c, 0x7e5d, 0x7e66, + 0x52fd, 0x7e5e, 0x7e5f, 0x7e1a, 0x7e60, 0x7e61, 0x52fd, 0x7e62, + 0x7e1b, 0x7e63, 0xb710, 0xb711, 0x834c, 0x839b, 0x83eb, 0x83ec, + 0x83ed, 0x83ee, 0x84a3, 0x84a8, 0x84a6, 0x06ec, 0x862f, 0x8630, + 0x8631, 0x8632, 0x8633, 0x874f, 0x8751, 0x8752, 0x877d, 0x8753, + 0x8754, 0x8755, 0x8756, 0x8757, 0x8758, 0x8759, + /* 0x30 */ + 0x875a, 0x875b, 0x875c, 0x2957, 0x875d, 0x875e, 0x875f, 0x876f, + 0x8760, 0x8761, 0x8762, 0x8763, 0x8772, 0x8764, 0x52fd, 0x876e, + 0x8bb5, 0x8e65, 0x8e66, 0x8e67, 0x8e68, 0x8e69, 0x8e6a, 0x8e6b, + 0x8e6c, 0x900e, 0x9043, 0x52fd, 0x900f, 0x9044, 0x9045, 0x9046, + 0x9047, 0x9048, 0x9049, 0x9010, 0x904a, 0x904b, 0x904c, 0x904d, + 0x08df, 0x904e, 0x904f, 0x9050, 0x9051, 0x9052, 0x9053, 0x9054, + 0x9055, 0x9056, 0x9057, 0x9058, 0x9059, 0x905a, 0x901d, 0x905b, + 0x905c, 0x905d, 0xfb06, 0x52fd, 0x94fe, 0x94ff, 0x9500, 0x9501, + 0x9502, 0x9503, 0x9504, 0x9505, 0x9506, 0x9507, 0x9518, 0x9508, + 0x9509, 0x94f3, 0x950a, 0x950b, 0x951b, 0x950c, 0x950d, 0x950e, + 0x950f, 0x9510, 0x980f, 0x9861, 0x9879, 0x9ac1, 0x9aac, 0x9aad, + 0x9c43, 0x9c44, 0x9c45, 0x9c46, 0x9c47, 0x9c48, + /* 0x31 */ + 0x9c49, 0x9c64, 0x9c4a, 0x9c4b, 0x9c4c, 0x9c4d, 0x0ac7, 0xfb2d, + 0x9e39, 0x9f57, 0x9f58, 0x9f59, 0x9f5f, 0x9f5a, 0xa06a, 0xa22b, + 0xa25d, 0xa25e, 0xa25f, 0x52fd, 0xa260, 0xa261, 0xa358, 0xa359, + 0xa44a, 0xa44b, 0xa44c, 0xa44d, 0xa44e, 0xa757, 0xa6b3, 0xa6b4, + 0xa76e, 0xa75b, 0xa75c, 0x52fd, 0xa75d, 0xa75e, 0x52fd, 0xa76c, + 0xa93d, 0xa954, 0xa93e, 0xa955, 0xa956, 0xa93f, 0xa957, 0xa958, + 0xa959, 0xa95a, 0xa95b, 0xa95c, 0xaa88, 0xaa89, 0x52fd, 0xac58, + 0xac59, 0xac5a, 0x52fd, 0xad67, 0xad68, 0xad69, 0xad6a, 0x52fd, + 0xad6b, 0xad6c, 0xadfe, 0xadff, 0xae00, 0xae01, 0xae02, 0xae03, + 0xae04, 0xae05, 0xb139, 0xb13a, 0xb13b, 0xb13c, 0x52fd, 0x52fd, + 0xb2b2, 0xb2b3, 0xb2b4, 0xb2b5, 0xb2b6, 0xb2b7, 0xb2b8, 0x3d3c, + 0xb5a2, 0xb661, 0xb662, 0xb714, 0x52fd, 0xb7eb, + /* 0x32 */ + 0xb842, 0xb848, 0x52fd, 0xb843, 0xb84e, 0xb844, 0xb845, 0xb9b4, + 0xb9b5, 0x52fd, 0x52fd, 0x52fd, 0xb9b6, 0x52fd, 0xbbe1, 0xbc05, + 0x52fd, 0x3e73, 0xbe9a, 0x52fd, 0xbe9b, 0xbe9c, 0xbe9d, 0xbe9e, + 0xbe9f, 0xfb9a, 0xbea0, 0xbea1, 0xbea2, 0xbeb5, 0xbea3, 0xbea4, + 0x52fd, 0xbea5, 0xbea6, 0xbea7, 0xbea8, 0xbeaf, 0xbea9, 0xbeaa, + 0xbeab, 0xbeac, 0xbead, 0xbeb3, 0x52fd, 0xc4a0, 0xc556, 0xc934, + 0x1127, 0xc93c, 0xcb0c, 0x52fd, 0xcf3e, 0xcfa3, 0xd030, 0xd031, + 0xd197, 0xd198, 0xd199, 0xd19a, 0xd19b, 0xd5b2, 0xd5ab, 0xd5ac, + 0xd9fc, 0xd9e8, 0xd9e9, 0xd9ea, 0xdaf1, 0xdc3f, 0xdfce, 0xe16d, + 0xe16e, 0xe16f, 0xe170, 0xe171, 0xe172, 0xe173, 0x4bbe, 0xe378, + 0xeb3a, 0x5467, 0x27fa, 0x5464, 0x5465, 0x5607, 0x55c4, 0x55c5, + 0x55c6, 0x55c7, 0x55c8, 0x55c9, 0x55e5, 0x55ca, + /* 0x33 */ + 0x55cb, 0x52fd, 0x55cc, 0x55cd, 0x55ce, 0x55cf, 0x55d0, 0x5797, + 0x579a, 0x579b, 0x58ea, 0x58ec, 0x58ed, 0x58f7, 0x58ee, 0x58ef, + 0x595b, 0x595c, 0x595d, 0x5a6d, 0x5a6e, 0x52fd, 0x5a6f, 0x5b81, + 0x5b82, 0x5c4f, 0x5cad, 0xda0a, 0x5d7e, 0x5e69, 0x6054, 0x6055, + 0x6056, 0x6057, 0x01ab, 0x6058, 0x6059, 0x605a, 0x605b, 0x605c, + 0x605d, 0x52fd, 0x52fd, 0x605e, 0x605f, 0x663b, 0x6636, 0x663c, + 0x663d, 0x663e, 0x663f, 0x6640, 0x6641, 0x6642, 0x024b, 0x6643, + 0x6644, 0x6645, 0x6637, 0x52fd, 0x52fd, 0x6646, 0x6647, 0x6648, + 0x6649, 0x682d, 0x68a5, 0x693d, 0x693f, 0x6c6e, 0x6ae7, 0x6a75, + 0x6a76, 0x6a77, 0x6a78, 0x6a79, 0x6a7a, 0x6a7b, 0x6a7c, 0x6a8e, + 0x6a7d, 0x6a7e, 0x2072, 0x6a7f, 0x6a80, 0x6a81, 0x6a82, 0x6a83, + 0x6a84, 0x6a85, 0x6a86, 0x6a87, 0x6a88, 0x6a89, + /* 0x34 */ + 0x6a8a, 0x6a8b, 0x6a8c, 0x6c6f, 0x6c70, 0x6c71, 0x6c72, 0x6d2a, + 0x6d2b, 0x6d2c, 0x6d2d, 0x6d2e, 0x6d2f, 0x6d30, 0x6d31, 0x6e83, + 0x6f84, 0x6f85, 0x6f93, 0x52fd, 0x6f86, 0x6f87, 0x6f88, 0x6f89, + 0x6f8a, 0x6f8b, 0x7136, 0x7138, 0x7139, 0x713a, 0x03e2, 0x713b, + 0x713c, 0x713d, 0x713e, 0x713f, 0x52fd, 0x7140, 0x7141, 0x7142, + 0x73de, 0x73df, 0x73e0, 0x73e1, 0x754a, 0x754b, 0x754c, 0x754d, + 0x754e, 0x754f, 0x7550, 0x7627, 0x76f9, 0x76fa, 0x76fb, 0x7798, + 0x7799, 0x779a, 0x52fd, 0x781e, 0x799e, 0x79f7, 0x799f, 0x79a0, + 0x79f0, 0x79f8, 0x79f9, 0x79a1, 0x79a2, 0x79a3, 0x79a4, 0x79a5, + 0x79fa, 0x79fb, 0x79fc, 0x79fd, 0x79fe, 0x7a1f, 0x79ff, 0x7a00, + 0x7a8c, 0x7a01, 0x7cc2, 0x7cc3, 0x52fd, 0x7cd3, 0x7d4e, 0x7eaf, + 0x7eb0, 0x7eb1, 0x7eb2, 0x7eb3, 0x7ec6, 0x7eb4, + /* 0x35 */ + 0x52fd, 0x7eb5, 0x7eb6, 0x7eb7, 0x7eb8, 0x7eb9, 0x7eba, 0x7ebb, + 0x7ebc, 0x7ebd, 0x7ebe, 0x7ebf, 0x7ec1, 0x7ec0, 0x7ec2, 0x7ec3, + 0x8251, 0x8252, 0x8253, 0x8254, 0x8255, 0x835a, 0x8350, 0x8351, + 0x8378, 0x83f8, 0x83f9, 0x84c6, 0x84cb, 0x84cc, 0x84cd, 0x84ce, + 0x84cf, 0x84d0, 0x84d1, 0x84d2, 0x84d3, 0x84d4, 0x84d5, 0x52fd, + 0x8637, 0x8638, 0x8673, 0x8790, 0x8791, 0x87bf, 0x8792, 0x8793, + 0x8794, 0x8795, 0x8796, 0x8797, 0x8798, 0x8799, 0x29bd, 0x879a, + 0x879b, 0x879c, 0x879d, 0x879e, 0x879f, 0x87a0, 0x87a1, 0x87a2, + 0x87a3, 0x87a4, 0x87a5, 0x52fd, 0x87a6, 0x87a7, 0x8bbf, 0x8bc0, + 0x8bc1, 0x8bc2, 0x8bc3, 0x8bc4, 0x8bc5, 0x8bc6, 0x8c75, 0x8d43, + 0x8d12, 0x8d9f, 0x8d91, 0xfaf6, 0x8d92, 0x8d93, 0x8d94, 0x8e7e, + 0x8e7f, 0x8e80, 0x8e81, 0x8e82, 0x8f4c, 0x8f63, + /* 0x36 */ + 0x90c0, 0x90c1, 0x90c2, 0x953a, 0x90c3, 0x90c4, 0x90c5, 0x90c6, + 0x2e15, 0x90c7, 0x52fd, 0x90c8, 0x9073, 0x90c9, 0x90ca, 0x90cb, + 0x90cc, 0x90cd, 0x090e, 0x52fd, 0x52fd, 0x90ce, 0x90cf, 0x90d0, + 0x90d1, 0x90d2, 0x90d3, 0x90d4, 0x90d5, 0x953b, 0x953c, 0x953d, + 0x953e, 0x52fd, 0x953f, 0x9540, 0x9541, 0x9542, 0x9543, 0x09c1, + 0x9544, 0x9545, 0x9559, 0x9546, 0x9547, 0x9548, 0x52fd, 0x9549, + 0x9813, 0x9882, 0x9883, 0x9966, 0x9967, 0x9c65, 0x3313, 0x9c66, + 0x0ad9, 0x9c75, 0x9c74, 0x9c67, 0x9c6d, 0x9c76, 0x9c68, 0x9c69, + 0x9c6a, 0x9c6b, 0x9c4f, 0x9c6c, 0x9df8, 0x9e45, 0x33f8, 0x9e46, + 0x9ee4, 0x9f85, 0x9f6f, 0x9f70, 0xa082, 0xa083, 0xa084, 0xa08b, + 0xa22d, 0xa268, 0xa269, 0xa277, 0xa264, 0xa26a, 0x52fd, 0xa2f2, + 0xa2e2, 0xa363, 0xa364, 0xa365, 0xa366, 0x3a3d, + /* 0x37 */ + 0xa367, 0xa368, 0x35d8, 0x52fd, 0xa472, 0xa47d, 0xa669, 0xa784, + 0xa786, 0xa787, 0xa788, 0xa79e, 0x52fd, 0xa789, 0xa78a, 0xa796, + 0xa78b, 0xa78c, 0xa78d, 0xa979, 0xa983, 0xa97a, 0xa95d, 0xa97b, + 0x52fd, 0xaa9f, 0x0d48, 0xaaa0, 0xaaa1, 0xaaa2, 0x38fc, 0xac6a, + 0xac6b, 0xac6c, 0xac6d, 0xac6e, 0xad78, 0x52fd, 0xad79, 0xad7c, + 0xae21, 0xae22, 0xae23, 0xae24, 0x3a39, 0xae25, 0xae26, 0xb151, + 0xb152, 0xb156, 0x52fd, 0x3c4b, 0xb2e1, 0x52fd, 0x52fd, 0xb2d6, + 0xb2d7, 0xb2d8, 0xb2d9, 0xb5b5, 0xb66c, 0xb66f, 0xb670, 0xb7bc, + 0xb7bd, 0xb7ed, 0xb85b, 0xb85c, 0xb85d, 0xb85e, 0xb986, 0xb987, + 0xb9ed, 0x52fd, 0xb9ee, 0x52fd, 0xbc0e, 0xbc0f, 0x52fd, 0xbd2d, + 0xbd2a, 0xbd2e, 0xbdcc, 0xbef9, 0xbefa, 0xbefb, 0xbefc, 0x3fb9, + 0xbefd, 0xbf1b, 0xbefe, 0xbeff, 0xbf00, 0xbf01, + /* 0x38 */ + 0xbf02, 0xbf03, 0xbf21, 0xbf04, 0xbf05, 0xbf06, 0xbf07, 0xbf08, + 0xbf09, 0xbf0a, 0xbf0b, 0xbf0c, 0xbf0d, 0xbf0e, 0xbf0f, 0xbf10, + 0xbf11, 0xbf12, 0xbf13, 0xbf14, 0xbf15, 0xc57b, 0xc57c, 0xc57d, + 0xc57e, 0x40cf, 0xc57f, 0xc580, 0xc566, 0xc581, 0xc582, 0xc583, + 0xc8b2, 0x52fd, 0xc97f, 0xc972, 0xc95a, 0xcaeb, 0xcb15, 0x52fd, + 0xcb16, 0xfbca, 0xcb17, 0x52fd, 0xcbc5, 0xcbc6, 0xcbc7, 0xcc88, + 0xcc89, 0x52fd, 0xcc8a, 0xcc8b, 0xcc8c, 0xcc8d, 0xcedf, 0x52fd, + 0xd03b, 0xd03c, 0xd03d, 0xd03e, 0xd03f, 0xd040, 0xd041, 0xd042, + 0xd15c, 0xd1af, 0xd1a9, 0xd1aa, 0xd1ab, 0xd1ac, 0xd1b5, 0xd1ad, + 0xd1ae, 0xd2e2, 0xd524, 0x44ae, 0xd5c4, 0x52fd, 0xd7ea, 0xd7d3, + 0xd7d4, 0xd7d5, 0xd986, 0x52fd, 0xd987, 0xd9fd, 0xdb05, 0xdc49, + 0xdf5f, 0xdfd3, 0xdfd5, 0xe18a, 0xe18b, 0xe18c, + /* 0x39 */ + 0xe18d, 0xe18e, 0xe18f, 0xe190, 0xe191, 0xe192, 0xe193, 0xe37d, + 0xe37e, 0x4beb, 0x52fd, 0x52fd, 0xe4ec, 0xe55b, 0xef87, 0xef86, + 0x52fd, 0x5346, 0x5347, 0x5402, 0x546d, 0x546e, 0x546f, 0x560d, + 0x560e, 0x560f, 0x5610, 0x5611, 0x5612, 0x5613, 0x5614, 0x579f, + 0x57a0, 0x57a1, 0x57a3, 0x5821, 0x5822, 0x867c, 0x5895, 0x5896, + 0x5961, 0x5967, 0x5a91, 0x5a92, 0x5a93, 0x5a94, 0x5b8a, 0x5b8b, + 0x5bf7, 0x5c24, 0x5cb0, 0x5cb1, 0x5d8e, 0x5e04, 0x5e6a, 0x5e6b, + 0x5e6c, 0x5e6d, 0x60e8, 0x610c, 0x60e9, 0x60ea, 0x610d, 0x52fd, + 0x60eb, 0x60ec, 0x60ed, 0x60ee, 0x60ef, 0x60f0, 0x60f1, 0x60f2, + 0x6116, 0x60f3, 0x6104, 0x611d, 0x60f4, 0x60f5, 0x60f6, 0x60f7, + 0x1cb0, 0x6502, 0x6503, 0x6504, 0x669a, 0x667c, 0x66c5, 0x667d, + 0x667e, 0x667f, 0x6680, 0x6681, 0x1f40, 0x1f42, + /* 0x3a */ + 0x6682, 0x6683, 0x6684, 0x6685, 0x6686, 0x6687, 0x68ae, 0x694d, + 0x6ab0, 0x6adc, 0x6ab6, 0x6ab7, 0x6ab8, 0x6ab9, 0x6aba, 0x6abb, + 0x6adb, 0x6abc, 0x6abd, 0x6abe, 0x52fd, 0x6abf, 0x6ac0, 0x6ac1, + 0x6ac2, 0x6ac3, 0x6ace, 0x0301, 0x6ad9, 0x6ac4, 0x6ac5, 0x6ada, + 0x6ac6, 0x6ac7, 0x6ac8, 0x6ac9, 0x6aca, 0x6c7e, 0x6c7b, 0x6d4e, + 0x6d4f, 0x6d50, 0x6d51, 0x6d52, 0x6d53, 0x6d54, 0x6d55, 0x6e8f, + 0x6efc, 0x6fa6, 0x6fa7, 0x6fa8, 0x7023, 0x718b, 0x52fd, 0x718c, + 0x718d, 0x718e, 0x718f, 0x71a4, 0x5899, 0x7324, 0x7346, 0x7347, + 0x7348, 0x73fd, 0x73fe, 0x52fd, 0x756e, 0x757c, 0x756f, 0x7570, + 0x7571, 0x7572, 0x7629, 0x762a, 0x765f, 0x77a2, 0x7830, 0x782b, + 0x7a61, 0x7a02, 0x7a03, 0x7a04, 0x7a05, 0x7a06, 0x7a07, 0x52fd, + 0x7a08, 0x7a09, 0x7a62, 0x7a0a, 0x7a0b, 0x7a0c, + /* 0x3b */ + 0x7a0d, 0x7a0e, 0x7a63, 0x7a27, 0x7a0f, 0x52fd, 0x7a1b, 0x7a64, + 0x7a10, 0x7a11, 0x7a81, 0x7a12, 0x7a65, 0x7a13, 0x7cce, 0x7f29, + 0x7ec4, 0x7f2a, 0x52fd, 0x7f2b, 0x7f2c, 0x7f2d, 0x7f2e, 0x7f2f, + 0x7f30, 0x7f31, 0x7f32, 0x7f33, 0x7f34, 0x52fd, 0x7f35, 0x7f36, + 0x7ee3, 0x7f37, 0x7f38, 0x7f39, 0x7f3a, 0x7f3b, 0x7f4d, 0x7f3c, + 0x7f3d, 0x7f3e, 0x52fd, 0x81d0, 0x81d1, 0x8355, 0x8402, 0x8404, + 0x84fc, 0x8507, 0x84fd, 0x84fe, 0x52fd, 0x84ff, 0x8500, 0x8508, + 0x8501, 0x8502, 0x8535, 0x8503, 0x8504, 0x52fd, 0x863b, 0x8689, + 0x8681, 0x8682, 0xba33, 0x87eb, 0x87ec, 0x52fd, 0x87ed, 0x87ee, + 0x87ef, 0x52fd, 0x87f0, 0x87f1, 0x87f2, 0x2a2b, 0x87f3, 0x2a16, + 0x87f4, 0x87f5, 0x534b, 0x87f6, 0x87f7, 0x87f8, 0x87f9, 0x87fa, + 0x87fb, 0x87fc, 0x87fd, 0x87fe, 0x87ff, 0x8800, + /* 0x3c */ + 0x2a1b, 0x8801, 0x8802, 0x8803, 0x8804, 0x8805, 0x8806, 0x8807, + 0x2a27, 0x8808, 0x8809, 0x880a, 0x880b, 0x880c, 0x880d, 0x8bd7, + 0x8bd8, 0x8d29, 0x8d9c, 0x8df8, 0x8e98, 0x8ea4, 0x8e99, 0x8e9a, + 0x8e9b, 0x8e97, 0x8e9c, 0x2cf5, 0x8e9d, 0x52fd, 0x8e9e, 0x8e9f, + 0x8f65, 0x90d6, 0x0920, 0x9132, 0x9133, 0x9134, 0x2e82, 0x9135, + 0x9136, 0x9137, 0x90d7, 0x52fd, 0x90d8, 0x9138, 0x9139, 0x913a, + 0x913b, 0x913c, 0x913d, 0x913e, 0x913f, 0x9140, 0x90d9, 0x9141, + 0x9142, 0x0921, 0x9143, 0x9144, 0x2e7a, 0x957c, 0x957d, 0x957e, + 0x957f, 0x9580, 0x9581, 0x9582, 0x52fd, 0x9583, 0x9584, 0x9585, + 0x9586, 0x95a5, 0x9587, 0x9588, 0x9589, 0x958a, 0x958b, 0x958c, + 0x958d, 0x958e, 0x52fd, 0x52fd, 0x958f, 0x52fd, 0x9590, 0x9591, + 0x9592, 0x9593, 0x9594, 0x9595, 0x52fd, 0x3129, + /* 0x3d */ + 0x9596, 0x9856, 0x9857, 0x98e1, 0x990e, 0x990f, 0x997a, 0x997b, + 0x998b, 0x9af2, 0x9af3, 0x9c93, 0x9c94, 0x9c95, 0x9c96, 0x9c97, + 0x9cad, 0x9c98, 0x9cab, 0x9c7b, 0x9c99, 0x9c9a, 0x9c9b, 0x9c85, + 0x9c9c, 0x9c9d, 0x0ada, 0x52fd, 0x9cac, 0x9c79, 0x9c9e, 0x9ca4, + 0x9dfd, 0x9eeb, 0x9eea, 0x9f8f, 0x9f90, 0x9f86, 0x9f87, 0x9f88, + 0xa0ac, 0xa0ad, 0xa2ec, 0xa373, 0xa374, 0x52fd, 0xa4aa, 0xa4ab, + 0xa4ac, 0xa6d1, 0xa6d7, 0xa7b9, 0xa7ba, 0xa7bb, 0xa7bc, 0xa98e, + 0xa98f, 0xa990, 0xa97c, 0xa991, 0xa992, 0xa993, 0xa994, 0xfb54, + 0xa99a, 0xa995, 0xa996, 0xa997, 0xaabd, 0xaac7, 0xaabe, 0x52fd, + 0xaabf, 0x52fd, 0xac93, 0x6d5e, 0xad86, 0xad87, 0xad88, 0xad89, + 0xae41, 0xae42, 0xae43, 0xae44, 0xae45, 0xae46, 0xae4a, 0xae47, + 0xae48, 0xae49, 0xb16b, 0xb166, 0x52fd, 0xb167, + /* 0x3e */ + 0x3bab, 0xb168, 0x3bac, 0x52fd, 0xb2fd, 0xb2fe, 0xb2ff, 0xb300, + 0xb301, 0xb302, 0xb303, 0xb304, 0xb305, 0xb306, 0xb533, 0xb5c2, + 0xb5d0, 0xfb74, 0xb695, 0xb696, 0xb735, 0xb736, 0xb867, 0xb868, + 0xb869, 0xb86a, 0xb872, 0xb86b, 0xb86c, 0xb86d, 0xb86e, 0xb86f, + 0xba22, 0x52fd, 0x52fd, 0xba23, 0xba41, 0xba24, 0xba25, 0xba26, + 0xba27, 0xba28, 0xba29, 0xb9b7, 0x52fd, 0x52fd, 0x52fd, 0xbcda, + 0xbdcf, 0xbdda, 0xbf89, 0xbfb7, 0xbf8a, 0xbf8b, 0xc05e, 0xbf8c, + 0x52fd, 0xbf8d, 0xbf8e, 0xbf8f, 0xbf90, 0xbf91, 0xbf92, 0xbf93, + 0xbf94, 0xbfb6, 0xbf95, 0xbf96, 0xbf97, 0x3ff7, 0x52fd, 0xbf98, + 0xbf99, 0xbf9a, 0x0fea, 0x52fd, 0xbf9b, 0xbfbd, 0xbf9c, 0xbf9d, + 0xbf9e, 0xbf9f, 0xbfc0, 0xbfa0, 0xbfa1, 0xbfa2, 0xbfa3, 0xbfa4, + 0xbfa5, 0xbfa6, 0xbfa7, 0xbfa8, 0xbfa9, 0xbfaa, + /* 0x3f */ + 0x52fd, 0xc4b4, 0xc4b5, 0xc4b6, 0xc5b9, 0xc5ba, 0xc5bb, 0xc591, + 0xc5bc, 0xc8ee, 0xc8ef, 0xc996, 0xc997, 0xc973, 0xc998, 0xc999, + 0xcaed, 0xcaee, 0xcbde, 0xccb0, 0xccb1, 0xccb2, 0xccb3, 0xccb4, + 0xccb5, 0xccb6, 0xfbce, 0xccb7, 0xcee3, 0xcfb9, 0xd055, 0xd07e, + 0xd056, 0xd057, 0xd058, 0xd059, 0xd05a, 0x52fd, 0xd1c4, 0xd1c5, + 0xd1c6, 0xd1c7, 0xd1c8, 0xd1c9, 0xd1ee, 0xd1cf, 0xd1ca, 0xd1cb, + 0xd1cc, 0xd309, 0xfbda, 0xd303, 0xd52f, 0xd530, 0xd531, 0xd532, + 0xd80e, 0xd80f, 0xd810, 0xd811, 0xd812, 0x52fd, 0xd813, 0xd814, + 0xd815, 0xd7ff, 0xda1f, 0xda20, 0xda21, 0xda2d, 0x52fd, 0xdb1b, + 0xdb1c, 0xdb1d, 0xdb1e, 0xdc53, 0xdc54, 0xdc55, 0xdc56, 0xdc64, + 0xdc59, 0xdc57, 0x52fd, 0xdc58, 0xdf6b, 0x1489, 0x52fd, 0xdfe7, + 0xdfe8, 0xdfe9, 0xdfea, 0xdfeb, 0xdfec, 0x4a96, + /* 0x40 */ + 0xdfed, 0xe1b1, 0xe1b4, 0x52fd, 0xe38a, 0xe38d, 0xe38c, 0xe4f2, + 0xe4f3, 0x52fd, 0x7408, 0xe717, 0x15b2, 0xe89f, 0xe9a0, 0x52fd, + 0xeb6d, 0x837d, 0xf290, 0xf8c4, 0x534c, 0x5474, 0x5475, 0x5476, + 0x5649, 0x564a, 0x564b, 0x564c, 0x564d, 0x564e, 0x564f, 0x5650, + 0x5651, 0x5652, 0x5653, 0x5654, 0x5655, 0x5656, 0x57a4, 0x57a9, + 0x582a, 0x582b, 0x5ab3, 0x5ac1, 0x5b98, 0x5bfb, 0x5bfc, 0x5cbc, + 0x5d96, 0x5e0a, 0x52fd, 0x61a2, 0x52fd, 0x6181, 0x6182, 0x6183, + 0x6184, 0x6185, 0x6186, 0x6187, 0x6188, 0x6189, 0x618a, 0x618b, + 0x618c, 0x1cf1, 0x618d, 0x61d1, 0x6514, 0x66c9, 0x66ca, 0x66cb, + 0xedfd, 0x66cc, 0x66cd, 0x66ce, 0x66cf, 0x66d0, 0x66d1, 0x66d2, + 0x66d3, 0x66d4, 0x66d5, 0x6871, 0x534d, 0x6962, 0x6b0e, 0x6afe, + 0x6aff, 0x6b00, 0x52fd, 0x6b01, 0x6b02, 0x6b03, + /* 0x41 */ + 0x6b15, 0x6b04, 0x6b05, 0x52fd, 0x6c87, 0x6c89, 0x6d6e, 0x6d6f, + 0x6d70, 0x6d71, 0xfa6e, 0x6d72, 0x6d73, 0x6d74, 0x6e9d, 0x6fb8, + 0x6fb9, 0x6fba, 0x71c2, 0x71c3, 0x71d5, 0x71c4, 0x71c0, 0x71c5, + 0x71c6, 0x758a, 0x758b, 0x758c, 0x7664, 0xae8c, 0x2441, 0x770d, + 0x77a8, 0x783b, 0x783c, 0x783d, 0x783e, 0x783f, 0x7840, 0x7a66, + 0x7acb, 0x7ab7, 0x7ab8, 0x7ab9, 0x7aba, 0x7a67, 0x7abb, 0x7a68, + 0x7a69, 0x7a6a, 0x7abc, 0x52fd, 0x7cdb, 0x7f81, 0x7f82, 0x7f83, + 0x7f84, 0x7f85, 0x7f86, 0x7f87, 0x7f88, 0x7f89, 0xfabf, 0x7f8a, + 0x7f8b, 0x52fd, 0x7f8c, 0x7f8d, 0x7f8e, 0x7f8f, 0x7f90, 0x7fa1, + 0x7f91, 0x81d6, 0x829f, 0x8358, 0x8385, 0x840b, 0x840c, 0x8537, + 0x8538, 0xface, 0x8539, 0x853a, 0x853b, 0x853c, 0x853d, 0x853e, + 0x8540, 0x8541, 0x8542, 0x52fd, 0x8543, 0x868a, + /* 0x42 */ + 0x868b, 0x8890, 0x8859, 0x885b, 0x885c, 0x885d, 0x885e, 0x2a8a, + 0x885f, 0x8860, 0x8861, 0x8862, 0x8863, 0x8864, 0x8893, 0x8865, + 0x8866, 0x8867, 0x8868, 0x8869, 0x886a, 0x886b, 0x8895, 0x886c, + 0x886d, 0x886e, 0x886f, 0x2a8c, 0x8870, 0x8871, 0x8872, 0x8873, + 0x8874, 0x8875, 0x8876, 0x8877, 0x8878, 0x8879, 0x2a80, 0x887a, + 0x2a7f, 0x887b, 0x88a9, 0x887c, 0x8bf1, 0x8beb, 0x8c8a, 0x8d3d, + 0x8da6, 0x8da7, 0x8eba, 0x52fd, 0x8ebb, 0x8ebc, 0x8ebd, 0x9191, + 0x9192, 0x9193, 0x9194, 0x9195, 0x9196, 0x9197, 0x90da, 0x9198, + 0x9199, 0x919a, 0x52fd, 0x52fd, 0x919b, 0x919c, 0x919d, 0x919e, + 0x919f, 0x91a0, 0x91bf, 0x91a1, 0x91a2, 0x91a3, 0x91a4, 0x91a5, + 0x91a6, 0x91a7, 0x915b, 0xfb0d, 0x91a8, 0x95cb, 0x52fd, 0x09da, + 0x95cc, 0x964f, 0x95cd, 0x95ce, 0x95cf, 0x964e, + /* 0x43 */ + 0x95d0, 0x95d1, 0x95d2, 0x52fd, 0x95d3, 0x95d4, 0x95d5, 0x95d6, + 0x95d7, 0x95d8, 0x95d9, 0x95fa, 0x95da, 0x95db, 0xfb1c, 0x95dc, + 0x52fd, 0x52fd, 0x95dd, 0x95de, 0x95df, 0x95e0, 0x95e1, 0x95e2, + 0x95e3, 0x95e4, 0x95e5, 0x09db, 0x95e6, 0x95e7, 0x988e, 0x9998, + 0x9999, 0x52fd, 0x9b0a, 0x52fd, 0x9b26, 0x9b27, 0x9cbd, 0x9cdf, + 0x0ae2, 0x9cbe, 0x9cde, 0x9cbf, 0x9cc0, 0x9cc1, 0x9cc2, 0x9c9f, + 0x9cc3, 0x9cc4, 0x9cc5, 0x9cc6, 0x9cc7, 0x0ae3, 0x9cc8, 0x9cc9, + 0x9ce3, 0x9cca, 0x9ccb, 0x9ccc, 0x9ccd, 0x9cce, 0x9ccf, 0x9cd0, + 0x9cd1, 0x9cd2, 0x9cd3, 0xfb2f, 0x9cd4, 0x9e04, 0x9e65, 0x9eee, + 0x9fa0, 0x9fa1, 0xa0dd, 0xa0de, 0xa283, 0xa2fa, 0xa37f, 0xa380, + 0xa4e8, 0xa4e9, 0xa4ea, 0x88a6, 0xa6e1, 0x52fd, 0xa7db, 0xa7dc, + 0xa7dd, 0xa7de, 0xa7df, 0xa7e0, 0xa7e1, 0xa7e2, + /* 0x44 */ + 0xa7e3, 0xa7e4, 0xa7e5, 0xa7e6, 0x379c, 0xa7e7, 0xa9b0, 0xa998, + 0xa9b1, 0xa999, 0xa9b2, 0xa9b3, 0xa9b4, 0xa9b5, 0xa9b6, 0xa9b7, + 0xa9b8, 0xa9b9, 0xaae2, 0xaae3, 0xaae4, 0xaae5, 0xaae6, 0xaae7, + 0xaae8, 0xaae9, 0xacad, 0xaccf, 0xacae, 0xacaf, 0xacb0, 0xacb1, + 0xad92, 0xad93, 0xad94, 0xae79, 0x3a7b, 0xae7a, 0xae7b, 0xae7c, + 0xae7d, 0xae7e, 0xae7f, 0xae80, 0xae81, 0xae82, 0xae83, 0xae84, + 0xb197, 0xb184, 0xb185, 0xb189, 0xb186, 0xb187, 0xb32c, 0xb32d, + 0xb32e, 0xb32f, 0xb330, 0xb331, 0xb332, 0xb333, 0xb334, 0xb335, + 0xb336, 0xb337, 0xb5d2, 0xb744, 0xb800, 0xb883, 0xb884, 0xfb86, + 0xba7a, 0xba7b, 0xba7c, 0xba7d, 0xba7e, 0x52fd, 0xba7f, 0xba87, + 0xba80, 0xbd43, 0xc034, 0x1249, 0xc035, 0xc036, 0xc037, 0xc038, + 0xc039, 0xc03a, 0xc03b, 0xc03c, 0xc03d, 0xc03e, + /* 0x45 */ + 0xc03f, 0xc040, 0xc041, 0xc042, 0xc043, 0xc044, 0xc045, 0xc046, + 0xc047, 0xc048, 0xc049, 0xc04a, 0x52fd, 0xc04b, 0xc04c, 0xc04d, + 0xc04e, 0xc5e7, 0xc5e8, 0xc5e9, 0xc5ea, 0xc5eb, 0xc5ec, 0xc5ed, + 0xc5ee, 0xc8f7, 0xc99a, 0xc9cd, 0xfbc8, 0xc9a3, 0xc9ce, 0xcb31, + 0xcb32, 0xcb33, 0xcce4, 0x52fd, 0xcce5, 0xcce6, 0xcfc8, 0xd074, + 0xd075, 0xd076, 0xd077, 0xd078, 0xd079, 0xd07a, 0xd161, 0xd1df, + 0xd1e0, 0xd1e1, 0xd1e2, 0xd1e3, 0xd1e4, 0xd1e5, 0xd1e6, 0x12f3, + 0xd331, 0xd53d, 0xd53e, 0xd53f, 0xd5f4, 0xd5f5, 0xd5f6, 0x52fd, + 0xd717, 0xd841, 0xd842, 0xd843, 0xd844, 0xd845, 0xd846, 0xd847, + 0xd848, 0xd849, 0xd84a, 0xd84b, 0x46d2, 0xd9ba, 0xda44, 0xdc2a, + 0xdc6d, 0x4774, 0xfbe7, 0xdc7e, 0xdc6e, 0xdc6f, 0xdc70, 0xdc71, + 0xdc76, 0xdf79, 0x4aa0, 0x52fd, 0xe004, 0xdff8, + /* 0x46 */ + 0xe005, 0xe1da, 0xe1db, 0xe1dc, 0xe1dd, 0xe1de, 0xe1df, 0xe1e0, + 0xe1e1, 0xe3c5, 0xe39a, 0xe39b, 0xe39c, 0xe4d8, 0xe4d9, 0xe4da, + 0xe56e, 0x1557, 0xe76b, 0xd083, 0x52fd, 0xe9d6, 0xe9bd, 0x52fd, + 0x852e, 0xedfc, 0xf053, 0xf0b7, 0xf58c, 0xf68e, 0xf5ff, 0x5376, + 0x5406, 0x547e, 0x5684, 0x5685, 0x5686, 0x5687, 0x5688, 0x56a7, + 0x5689, 0x568a, 0x568b, 0x568c, 0x568d, 0x568e, 0x568f, 0x56a3, + 0x5690, 0x5691, 0x5692, 0x5693, 0x56ac, 0x5694, 0x5695, 0x5696, + 0x57aa, 0x57ab, 0x589e, 0x18a9, 0x5908, 0x5909, 0x5968, 0x5969, + 0x596a, 0x599a, 0x5ad9, 0x5ada, 0x5adb, 0x5ba8, 0x5c01, 0x5c28, + 0x5c77, 0x5cbd, 0x5cbe, 0x6260, 0x5da0, 0x5da2, 0x5e0f, 0x5e85, + 0x61fe, 0x61ff, 0x6200, 0x6201, 0x6216, 0x6202, 0x6203, 0x6204, + 0x6205, 0x6206, 0x6207, 0x6208, 0x6222, 0x6209, + /* 0x47 */ + 0x620a, 0x620b, 0x620c, 0x6214, 0x6229, 0x616e, 0x620d, 0x620e, + 0x620f, 0x6210, 0x6211, 0x6212, 0x6213, 0x651b, 0x651c, 0x651d, + 0x6713, 0x66ff, 0x6700, 0x6701, 0x6702, 0x6703, 0x6704, 0x670a, + 0x6705, 0x6706, 0x6707, 0x6708, 0x683a, 0x6873, 0x696f, 0x6970, + 0x6971, 0x5352, 0x52fd, 0x6d9a, 0x6b60, 0xfa69, 0x6b2b, 0x6b24, + 0x6b2c, 0x6b2d, 0x6b2e, 0x6b2f, 0x6b30, 0x6b31, 0x6b32, 0x6b33, + 0x6b34, 0x6b35, 0x6b45, 0x6b36, 0x6c92, 0x6c93, 0x6d88, 0x6d89, + 0x6d8a, 0x6d8b, 0x6e3f, 0x52fd, 0x6fca, 0x71f6, 0x71f7, 0x71f8, + 0x71f9, 0x742b, 0x52fd, 0x74a4, 0x74ce, 0x52fd, 0x759e, 0x759f, + 0x75a0, 0x75a1, 0x75a2, 0x75a3, 0x75a4, 0x75a5, 0x75a6, 0x7718, + 0x7860, 0x7861, 0x7862, 0x7863, 0x7864, 0x7abd, 0x7abe, 0x7b0b, + 0x7abf, 0x7ac0, 0x52fd, 0x7b0c, 0x7a8d, 0x7b0d, + /* 0x48 */ + 0x7b0e, 0x7b5e, 0x7b0f, 0x7b10, 0x7ac1, 0x7b11, 0x52fd, 0x7ac2, + 0x7cea, 0x7ceb, 0x7fe3, 0x7fe4, 0x7fe5, 0x7fe6, 0x7fe7, 0x7f92, + 0x804a, 0x52fd, 0x7fe8, 0x7fe9, 0x7fea, 0x8001, 0x7feb, 0x7fec, + 0x7fef, 0x7fed, 0x7fee, 0x7ff0, 0x7ff1, 0x7ff2, 0x7ff3, 0x7ff4, + 0x7ff5, 0x7ff6, 0x7ff7, 0x7ff8, 0x7ff9, 0x7ffe, 0x7ffa, 0x7ffb, + 0x7ffc, 0x8563, 0x8564, 0x8565, 0x8566, 0x8567, 0x8568, 0x890b, + 0x890d, 0x07bc, 0x890e, 0x890f, 0x07a4, 0x8914, 0x88d4, 0x88d5, + 0x88d6, 0x88d7, 0x88d8, 0x88d9, 0x88da, 0x88db, 0x88dc, 0x88dd, + 0x88de, 0x88df, 0x88e0, 0x88e1, 0x88e2, 0x88e3, 0x88e4, 0x88e5, + 0x88e6, 0x88e7, 0x88e8, 0x88e9, 0x88ea, 0x88eb, 0x88ec, 0x89ec, + 0x88ed, 0x88ee, 0x88ef, 0x8900, 0x88f0, 0x8c04, 0x52fd, 0x8c05, + 0xfaf3, 0x8db5, 0xfaf9, 0x8ed6, 0x8ed7, 0x8ed8, + /* 0x49 */ + 0x8ed9, 0x91a9, 0x9200, 0x9201, 0x9202, 0x9203, 0x9204, 0x9205, + 0x9206, 0x923f, 0x9207, 0x9208, 0x9209, 0x920a, 0x91b6, 0x920b, + 0x920c, 0x52fd, 0x52fd, 0x920d, 0x52fd, 0x920e, 0x920f, 0x9210, + 0x9211, 0x9212, 0x9235, 0x9213, 0x9214, 0x91aa, 0x52fd, 0x92c1, + 0x9215, 0x9216, 0x9217, 0x961e, 0x961f, 0x9620, 0x9621, 0x52fd, + 0x9622, 0x9623, 0x3195, 0x9624, 0x9625, 0x9626, 0x9627, 0x9628, + 0x9629, 0x962a, 0x962b, 0x9607, 0x962c, 0x962d, 0x962e, 0x09e8, + 0x52fd, 0x962f, 0x9630, 0x9648, 0x9631, 0x9632, 0x3198, 0x9633, + 0x52fd, 0x9634, 0x9635, 0x9636, 0x9859, 0x9891, 0x98e7, 0x99b8, + 0x99b9, 0x99ba, 0x99bb, 0x99c8, 0x9b4d, 0x9b89, 0x9b50, 0x9b28, + 0x9cfb, 0x9cfc, 0x9cfd, 0x9cfe, 0x9cff, 0x3378, 0x9d00, 0x9d01, + 0x9d02, 0x9ce4, 0x9ce5, 0x9d03, 0x9d04, 0x9d05, + /* 0x4a */ + 0x9d06, 0x9d07, 0x9d13, 0x9d08, 0x9d09, 0x9ce6, 0x9d0a, 0x9d0b, + 0x9d0c, 0x9e0b, 0x9ef4, 0x9f0a, 0x9fb1, 0xa11d, 0xfb3b, 0xa28b, + 0xa28c, 0xa28f, 0xa28d, 0xa28e, 0xa306, 0xa386, 0xa522, 0xa523, + 0xa524, 0xa525, 0xa526, 0xa527, 0xa528, 0xa6f1, 0x37b9, 0xa823, + 0xa812, 0x52fd, 0xa813, 0xa814, 0xa815, 0xa816, 0xa817, 0xa818, + 0xa819, 0xa84b, 0xa81a, 0xa81b, 0xa81c, 0x52fd, 0xa81d, 0xa81e, + 0xa81f, 0xa820, 0xa9ca, 0x75ac, 0xa9cb, 0xa9cc, 0xa9cd, 0xa9ce, + 0x52fd, 0xa9cf, 0xab10, 0xab11, 0xab12, 0xab13, 0xab14, 0xab0f, + 0xab15, 0xab16, 0xab17, 0x3933, 0xab18, 0xacc6, 0xad9f, 0xada0, + 0xada4, 0xada1, 0xaeb5, 0xaeb6, 0xaeb7, 0xaeb8, 0xaeb9, 0xaeba, + 0xaed0, 0xaec6, 0xaebb, 0xaebc, 0xaebd, 0xaebe, 0xaebf, 0xaec0, + 0xaec1, 0xaec2, 0xfb60, 0xb1a7, 0xb1a8, 0xb1a9, + /* 0x4b */ + 0xb1aa, 0xb1ab, 0xb1ac, 0xb1bc, 0xb1ad, 0xb1ae, 0x3bc0, 0xb1af, + 0xb1b0, 0xb1b1, 0x3bc1, 0xb1b4, 0xb1b2, 0xb366, 0xb367, 0xb368, + 0xb369, 0xb36a, 0xb36b, 0xb36c, 0xb36d, 0xb36e, 0xb36f, 0x52fd, + 0xb53e, 0xb53f, 0xb540, 0xb5e8, 0xb752, 0xb753, 0xb754, 0xb755, + 0xb891, 0xb892, 0xb893, 0xb894, 0xb895, 0xb896, 0xb897, 0xb898, + 0x52fd, 0xb899, 0xb89a, 0xb89b, 0xbab7, 0xbab8, 0xbab9, 0x52fd, + 0xbaba, 0xbabb, 0xbabd, 0x52fd, 0xbabc, 0xfb88, 0xfb87, 0xbbeb, + 0xbbec, 0xbc16, 0xbc44, 0xbce3, 0xbd58, 0xbd53, 0xbd54, 0xbde0, + 0xc0b1, 0xc0b2, 0xc0b3, 0xc0ea, 0x52fd, 0xc0b4, 0xc0f0, 0xc0b5, + 0xc0b6, 0xc0b7, 0xc0b8, 0xc0b9, 0xc0ba, 0xc0bb, 0xc0bc, 0xc0bd, + 0xc0be, 0xc0bf, 0xc0c0, 0xc0c1, 0xc0c2, 0xc0c3, 0x52fd, 0xc0c4, + 0xc0c5, 0xc0c6, 0xc0fc, 0xc0c7, 0xc0c8, 0xc0c9, + /* 0x4c */ + 0xc0ca, 0xc0cb, 0xc0cc, 0xc184, 0xc0cd, 0xc0ce, 0xc0cf, 0xc0d0, + 0xc0d1, 0xc0d2, 0xc4ca, 0xc4cb, 0xc636, 0xc637, 0xc69f, 0xc638, + 0xc639, 0xc63a, 0x4144, 0xc9be, 0xc9f0, 0xc9bf, 0xc9c0, 0xcaf7, + 0xcaf8, 0xcafa, 0xcb43, 0xcb44, 0xcd0f, 0xcd10, 0xcd11, 0xcd12, + 0x43ad, 0xcd13, 0xcd14, 0xcd15, 0xcd16, 0x52fd, 0x52fd, 0xcfd3, + 0xcfd7, 0x52fd, 0xd0b0, 0xd098, 0xd090, 0xd091, 0xd092, 0xd097, + 0xd093, 0xd164, 0xd201, 0xd202, 0xd203, 0xd204, 0xd205, 0xd206, + 0xd207, 0xd35a, 0xd35b, 0xd54e, 0xd54f, 0xd550, 0xd619, 0xd61a, + 0xd61b, 0x52fd, 0xd61c, 0x52fd, 0xd719, 0xd71a, 0x1386, 0xdc8a, + 0xd86e, 0xd86f, 0x4664, 0xd870, 0xd871, 0xd872, 0xd873, 0xd874, + 0xd875, 0xd876, 0xdb3a, 0xdb3b, 0xdb3c, 0xdb5a, 0xdb3d, 0xdb42, + 0xdc8b, 0xdca0, 0xdc8c, 0xdc8d, 0xdc8e, 0xdcab, + /* 0x4d */ + 0xdc8f, 0x4777, 0xdc90, 0xdc91, 0xdc92, 0xdcaa, 0x47af, 0xdc93, + 0xdc94, 0xdc9e, 0xdca8, 0x52fd, 0x52fd, 0xe200, 0xe201, 0xe202, + 0xe203, 0xe204, 0xe205, 0xe2c4, 0xe2c5, 0x52fd, 0xe3ae, 0xe3b2, + 0x52fd, 0x52fd, 0xe4f7, 0xe513, 0xe69e, 0xe785, 0xa680, 0xe7c8, + 0xeb41, 0xeb81, 0xeb82, 0xeb83, 0xeb84, 0xedc4, 0xedc5, 0xedc6, + 0xef95, 0xef96, 0xef97, 0xf058, 0xf059, 0x52fd, 0xf2a9, 0xf2aa, + 0xf2ab, 0xf58e, 0xf603, 0xf6b3, 0x5e82, 0x5353, 0x5483, 0x5484, + 0x5485, 0x56cc, 0x56cd, 0x56ce, 0x56cf, 0x56d0, 0x52fd, 0x56d1, + 0x56d2, 0x56da, 0x57b3, 0x57b4, 0x52fd, 0x5913, 0x590e, 0x596b, + 0x5c03, 0x5c61, 0x5cc1, 0x5cc2, 0x5db5, 0x5440, 0x6298, 0x6299, + 0x629a, 0x629b, 0x629c, 0x629d, 0x629e, 0x629f, 0x62ee, 0x62a0, + 0x62a1, 0x6286, 0x6525, 0x6734, 0x6735, 0x6751, + /* 0x4e */ + 0x672d, 0x9662, 0x6754, 0x6752, 0x026d, 0x6736, 0x6737, 0x6738, + 0x6739, 0x673a, 0x673b, 0x6768, 0x673c, 0x026e, 0x6877, 0x8596, + 0x697e, 0x697f, 0x6b69, 0x6b6a, 0x6b6b, 0x6b6c, 0x6b6d, 0x6b6e, + 0x6b6f, 0x6b5d, 0x6b70, 0x6b85, 0x6b71, 0x6b72, 0x6b73, 0x6b74, + 0x6b75, 0x6b76, 0x6b84, 0x6b77, 0x6b83, 0x6c9a, 0x6da7, 0x6da8, + 0x6da9, 0x6daa, 0x6dab, 0x6dac, 0x6db7, 0x6dad, 0x6dae, 0x52fd, + 0x6e45, 0x6fd3, 0x6fd4, 0x6fd5, 0x6fd6, 0x6fd7, 0x7226, 0x7227, + 0x7228, 0x52fd, 0x7229, 0x722a, 0x7305, 0x2364, 0x74d0, 0x75b7, + 0x52fd, 0x75b8, 0x75b9, 0x7722, 0x7723, 0x7873, 0x7874, 0x7b8f, + 0x7b12, 0x7b13, 0x7b14, 0x7b15, 0x7b16, 0x7b17, 0x7b18, 0x7b61, + 0x7b66, 0x7b67, 0x7b19, 0x7b68, 0x7b1a, 0x7b69, 0x7d04, 0x7d05, + 0x52fd, 0x7d06, 0x7cfd, 0x8050, 0x8051, 0x8052, + /* 0x4f */ + 0x8053, 0x8054, 0x8055, 0x8063, 0xfac4, 0x8056, 0x8057, 0x8058, + 0x8059, 0x805a, 0x805b, 0x52fd, 0x805c, 0x805d, 0x805e, 0x805f, + 0x82d7, 0x52fd, 0x8360, 0x8361, 0x8417, 0x8439, 0x858f, 0x85c8, + 0x8590, 0x8591, 0x8698, 0x8699, 0x8944, 0x8945, 0x8946, 0x8959, + 0x89ee, 0x2b2b, 0x8947, 0x8948, 0x52fd, 0x8949, 0x894a, 0x894b, + 0x894c, 0x894d, 0x894e, 0x894f, 0x8950, 0x8951, 0x8952, 0x8953, + 0x8954, 0x8955, 0x8956, 0x8c15, 0x8c9a, 0x8d58, 0x8dfc, 0x8dfd, + 0x9286, 0x9287, 0x9288, 0x9289, 0x928a, 0x928b, 0x928c, 0x52fd, + 0x931f, 0x928d, 0x928e, 0x928f, 0x9290, 0x9291, 0x9292, 0x9293, + 0xfb11, 0x9294, 0x9295, 0x91ca, 0x9218, 0x52fd, 0x9296, 0x9297, + 0x9298, 0x9299, 0x929a, 0x929b, 0x929c, 0x929d, 0x929e, 0x929f, + 0x2f46, 0x52fd, 0x92a0, 0x92a1, 0x2f9a, 0x92b7, + /* 0x50 */ + 0x52fd, 0x9696, 0x9668, 0x9669, 0x968c, 0x966a, 0x966b, 0x966c, + 0x966d, 0x966e, 0x966f, 0x967f, 0x9684, 0x9670, 0x9671, 0x9685, + 0x9672, 0x9673, 0x9674, 0x9675, 0x9676, 0x52fd, 0x9677, 0x9678, + 0x9679, 0x967a, 0x967b, 0x967c, 0xfb1e, 0x9894, 0x99d5, 0x9b29, + 0x9d2b, 0x9d2c, 0x9d2d, 0x9d2e, 0x9d2f, 0x9d30, 0x9d3e, 0x9d31, + 0x9d32, 0x9d33, 0x9d34, 0x9d35, 0x9e11, 0x0b53, 0x9fc0, 0xa142, + 0xa143, 0xa144, 0xa145, 0xa146, 0xa38c, 0xa38d, 0xa38e, 0xa38f, + 0xa390, 0xa391, 0xa563, 0xa564, 0xa565, 0x52fd, 0xfb4a, 0x52fd, + 0xa6f6, 0xa836, 0xa837, 0xa82c, 0xa838, 0xa839, 0x52fd, 0xa83a, + 0xa9e3, 0xa9e2, 0xa9f5, 0xab47, 0x52fd, 0xab48, 0xab49, 0xab4a, + 0xab4b, 0xab4c, 0xada8, 0xada9, 0xadaa, 0x52fd, 0xaf0b, 0xaf06, + 0xaf73, 0xaf0c, 0xaf0d, 0xaf0e, 0xaf0f, 0xaf10, + /* 0x51 */ + 0x52fd, 0xaf11, 0xfb62, 0xaf12, 0xaf14, 0xaf15, 0xaf16, 0x52fd, + 0xaf13, 0xaf17, 0xb1d9, 0xb1da, 0xb1db, 0x52fd, 0xb1dc, 0xb3a6, + 0xb3a7, 0xb3a8, 0xb3a9, 0xb3aa, 0xb3ab, 0x52fd, 0xfb6d, 0xb3ac, + 0xb3ad, 0xb3ae, 0x52fd, 0x52fd, 0xb3af, 0xb3b0, 0xb3b1, 0xb544, + 0xb545, 0xb5f7, 0xb5f8, 0xb76b, 0xb76c, 0xb761, 0xb812, 0xb8af, + 0xb8b0, 0xb8b1, 0xb8b2, 0xb8b3, 0xb8b4, 0xb8b5, 0xb8b6, 0xb922, + 0xbaea, 0xbaeb, 0xbaec, 0xbaed, 0x0f3d, 0xbbed, 0xbc1b, 0xbc47, + 0xbce8, 0xbdd0, 0xbde7, 0xbde8, 0xbde9, 0xc14e, 0xc14f, 0xc150, + 0xc172, 0xc151, 0xc152, 0xfba7, 0x1026, 0xc153, 0xc154, 0xc155, + 0xc156, 0xc157, 0xc177, 0xc158, 0xc159, 0xc15a, 0xc15b, 0xc15c, + 0xc16e, 0xc15d, 0x1027, 0x52fd, 0xc15e, 0x1028, 0xc15f, 0x52fd, + 0xc4d7, 0xc689, 0xc68a, 0x52fd, 0xfbbe, 0xc68b, + /* 0x52 */ + 0xc68c, 0xc68d, 0xc68e, 0xfbbc, 0xc68f, 0x52fd, 0xc69a, 0xc690, + 0xc691, 0xc692, 0xc693, 0xca12, 0xc9f1, 0x52fd, 0xcafe, 0xcafb, + 0xcb57, 0xcd49, 0xcd4a, 0xcd4b, 0xcd4c, 0x52fd, 0xcd4d, 0xcd59, + 0xcd4e, 0xcd4f, 0xcef4, 0xcf65, 0xd0a6, 0xd0a7, 0xd0a8, 0xd222, + 0xd223, 0xd38b, 0xd38c, 0xd38d, 0xd38e, 0xd558, 0x52fd, 0xd559, + 0xd63b, 0xd63c, 0xd63d, 0xd63e, 0xd748, 0xd894, 0xd895, 0xd896, + 0xd897, 0xd898, 0xda7d, 0xd9fe, 0xda7e, 0xda7f, 0x52fd, 0xdb5b, + 0xdb5c, 0xdce4, 0xdcc1, 0xdcfd, 0xdcc2, 0xdcd6, 0xdcc3, 0xdcc4, + 0x52fd, 0xdcdc, 0xdcc5, 0xdcc6, 0xdcc7, 0xdce1, 0xdcc8, 0xdcc9, + 0xdcca, 0xdccb, 0x47f2, 0xdccc, 0xdccd, 0xe035, 0xe036, 0xe047, + 0xe037, 0xe21b, 0xe21c, 0xe21d, 0xe21e, 0xe21f, 0xe220, 0xe27b, + 0xe27a, 0xe2fe, 0xe3c6, 0xe3c7, 0xe3c8, 0xe3c9, + /* 0x53 */ + 0xe3ca, 0x52fd, 0xe7a0, 0xe7a1, 0xe8cc, 0xe8cd, 0xe9f1, 0xe9d7, + 0xeb42, 0xeb46, 0xeba3, 0xeba5, 0xeba6, 0xedcb, 0xedcc, 0xee26, + 0xee27, 0xee28, 0xee29, 0xefae, 0xefaf, 0xefb0, 0xf073, 0x52fd, + 0xf07c, 0xf074, 0x52fd, 0xf280, 0xf075, 0x4c79, 0x52fd, 0xf2cf, + 0x52fd, 0xf68f, 0x5970, 0x5385, 0x5697, 0x56f6, 0x56f7, 0x56f8, + 0x56fa, 0x56fb, 0x57ba, 0x57bb, 0x57bc, 0x57bd, 0x5834, 0x5835, + 0x58a2, 0x5914, 0x5911, 0x596e, 0x596f, 0x5b08, 0x5bb8, 0x5d09, + 0x5dbd, 0x5dbe, 0x5e88, 0x62fe, 0x1d7a, 0x62ff, 0x6300, 0x6301, + 0x6302, 0x6303, 0x6304, 0x6305, 0x6306, 0x52fd, 0x6307, 0x6308, + 0x6309, 0x630a, 0x630b, 0x630c, 0x630d, 0x630e, 0x630f, 0x52fd, + 0x52fd, 0x52fd, 0x652c, 0x676b, 0x52fd, 0x676c, 0x6787, 0x676d, + 0x6878, 0x698b, 0x6ba4, 0x6ba5, 0x6ba6, 0x6ba7, + /* 0x54 */ + 0x6bbe, 0x6ba8, 0x6ba9, 0x6baa, 0x6b8d, 0x6bab, 0x6bac, 0x6bbf, + 0x52fd, 0x032c, 0x6bad, 0x6bae, 0x6ca4, 0x6ca5, 0x6dc7, 0x6dc8, + 0x6dc9, 0xd0bc, 0x6dca, 0x6dcb, 0x6dcc, 0x6dcd, 0x6dce, 0x6f19, + 0x6fe6, 0x724c, 0x724d, 0x724e, 0x7306, 0x52fd, 0x75cd, 0x75ce, + 0x75cf, 0x75d0, 0x245c, 0x7881, 0x7882, 0x5833, 0x7b6a, 0x7b6b, + 0x7bb2, 0x7b6c, 0x7b6d, 0x7bcc, 0x7bae, 0x7bb3, 0x7b91, 0x52fd, + 0x7b6e, 0x7bb4, 0x7b6f, 0x80c9, 0x80a7, 0x80a8, 0x80a9, 0x80aa, + 0x80ab, 0x80ac, 0x80ad, 0x80ae, 0x80af, 0x80b0, 0x8060, 0x80b1, + 0x81e1, 0x82e3, 0x82f6, 0x26d9, 0x85af, 0x85b0, 0x85b1, 0x85ba, + 0x85b2, 0x85b3, 0x864c, 0x52fd, 0x86a0, 0x86a1, 0x89b0, 0x89b1, + 0x89b2, 0x89b3, 0x89b4, 0xfaeb, 0x89b5, 0x89b6, 0x89b7, 0x89b8, + 0x89b9, 0x89ba, 0x2b72, 0x89bb, 0x89bc, 0x89bd, + /* 0x55 */ + 0x89be, 0x89bf, 0x89df, 0x89c0, 0x89c1, 0x89c2, 0x89c3, 0x89c4, + 0x2b78, 0x52fd, 0x89c5, 0x89c6, 0x89c7, 0x89c8, 0x89c9, 0x89ca, + 0x8a3c, 0x89cb, 0x89cc, 0x89cd, 0x89ce, 0x89cf, 0x89d0, 0x89d1, + 0x2c5a, 0x8c1d, 0x8c1e, 0x8d64, 0x8d65, 0x8dc5, 0x8dc6, 0x8dc7, + 0x8dff, 0x8eff, 0x8f00, 0x8f01, 0x8f02, 0x92f5, 0x935c, 0x92f6, + 0x92f7, 0x92b0, 0x92f8, 0x92f9, 0x935d, 0x9350, 0x92fa, 0x92fb, + 0x92a2, 0x92fc, 0x92fd, 0x92fe, 0x92ff, 0xfb13, 0x9300, 0xfb1f, + 0x96c1, 0x96c2, 0x96c3, 0x96c4, 0x96c5, 0x96c6, 0x96c7, 0x96c8, + 0x96c9, 0x96ca, 0x96cb, 0xe3ef, 0x96d7, 0x96cc, 0x96cd, 0x96ce, + 0x9722, 0x96cf, 0x96d0, 0x52fd, 0x96d1, 0x96d2, 0x96e9, 0x96d3, + 0x96d4, 0x96d5, 0x9838, 0x633b, 0x9b7d, 0x586f, 0x9ba1, 0x9d53, + 0x9d54, 0x0afb, 0x9d55, 0x9d3c, 0x9d56, 0x52fd, + /* 0x56 */ + 0x9d66, 0x0afc, 0x9d57, 0x9d58, 0x9d59, 0x9d5a, 0x9d5b, 0x9d67, + 0x9d5c, 0x52fd, 0x52fd, 0x9d6a, 0x9d5d, 0x9d3d, 0x9d5e, 0x9d65, + 0x9fe1, 0x9fcd, 0xf311, 0xa16f, 0xa170, 0xa31a, 0xa39a, 0xa39b, + 0xa39c, 0xa39e, 0xa39f, 0xfb3f, 0xa58e, 0x52fd, 0xa6fd, 0x52fd, + 0xa85e, 0xa85f, 0xa860, 0xa865, 0xa867, 0xa868, 0xa869, 0x52fd, + 0xa86a, 0xa88f, 0xa86b, 0xa86c, 0xa86d, 0xa9f7, 0xa9f8, 0xa9f9, + 0xa9e4, 0xa9fa, 0xabb1, 0xab75, 0xab76, 0xacff, 0xad00, 0xad01, + 0xad02, 0xad03, 0xadae, 0xadad, 0xaf51, 0xaf52, 0x52fd, 0xaf53, + 0xaf54, 0xaf55, 0xaf56, 0xaf57, 0xaf58, 0xaf59, 0xaf5a, 0xaf5b, + 0xaf5c, 0xaf5d, 0xaf5e, 0xaf5f, 0xaf60, 0xaf61, 0xaf62, 0xaf63, + 0xaf64, 0xaf4c, 0xaf66, 0xb1f1, 0xb1f2, 0xb3f2, 0xb3f3, 0xb3f4, + 0xb3f5, 0xb3f6, 0xb3f7, 0xb3f8, 0xb3f9, 0xb3fa, + /* 0x57 */ + 0xb54c, 0xb54b, 0xb61b, 0xb6ce, 0xb6b3, 0xb77f, 0xfb79, 0xfb7c, + 0xb81a, 0xb8c4, 0xb8c5, 0xb8c6, 0xb8c7, 0xb8c8, 0xb8c9, 0x52fd, + 0xbb19, 0xbb1c, 0xbb1a, 0xbc4c, 0xbc8e, 0xbd7e, 0xc1eb, 0xc1ec, + 0xc1ed, 0xc1ee, 0xc1ef, 0xc1f0, 0xc1f1, 0xc1d8, 0xc1d9, 0xc1da, + 0xc1db, 0xc1f2, 0xc1f3, 0xc1f4, 0xc207, 0x52fd, 0xfbac, 0x52fd, + 0xc1f5, 0xc215, 0x52fd, 0xc1f6, 0xc1f7, 0xc1f8, 0xc1f9, 0xc1fa, + 0xc1fb, 0xc1fc, 0xc1fd, 0xc1fe, 0xc2a7, 0xc1ff, 0xc200, 0xc201, + 0xc202, 0xc203, 0xc204, 0xc205, 0xc4e9, 0xc4ea, 0xc4eb, 0xc6de, + 0xc6df, 0x52fd, 0xc6e0, 0xc6e1, 0xc6e2, 0xc6e3, 0xca3e, 0xca3f, + 0xca40, 0xca41, 0xcb71, 0xcb72, 0xcb73, 0xcd88, 0xcd89, 0xcd8a, + 0xcd8b, 0xcd8c, 0xcd8d, 0xcd8e, 0xcd8f, 0xcd90, 0xcd91, 0xcd92, + 0x52fd, 0xcff1, 0xd0be, 0xd0bf, 0xd0c0, 0xd0c1, + /* 0x58 */ + 0xd0c2, 0xd0c3, 0xd16e, 0xd237, 0xd257, 0xd238, 0xd239, 0xd23a, + 0xd23b, 0xd23c, 0xd23d, 0xd23e, 0xd227, 0xd23f, 0x52fd, 0x52fd, + 0xd3c0, 0xd3c1, 0x44be, 0xd567, 0x52fd, 0xd568, 0xd658, 0xd665, + 0xd659, 0xd65a, 0xd724, 0xd8cd, 0xd8ce, 0xd8cf, 0xd8d2, 0xda9f, + 0xda22, 0xdb7d, 0xdb7e, 0xdcff, 0xdd25, 0xdd00, 0xdd01, 0x483b, + 0xdd02, 0xdd03, 0xdd04, 0x5128, 0xdd05, 0xdd06, 0xdd07, 0xdd16, + 0xdd08, 0xdd17, 0xdd09, 0xdd0a, 0x4840, 0xdd0b, 0xdd0c, 0xdd29, + 0x483a, 0xdd0d, 0x52fd, 0xdd0e, 0xdd10, 0xdd11, 0xdd1d, 0xdd12, + 0xdd13, 0x52fd, 0xdd14, 0xdd15, 0xdf8d, 0xe054, 0xe055, 0xe056, + 0xe233, 0xe234, 0xe235, 0xe236, 0xe2fa, 0xe3e3, 0xe3e6, 0xe3ed, + 0xe3e7, 0xe3e8, 0xe3e9, 0xe3ea, 0xe3eb, 0xe527, 0xe520, 0xfbf8, + 0xe72a, 0xe7c9, 0x52fd, 0xe7ca, 0xe7cb, 0xe7d9, + /* 0x59 */ + 0xe7cc, 0xe7cd, 0xe7ce, 0x52fd, 0xe8e1, 0xea1b, 0xea1c, 0xea1d, + 0xea1e, 0xeb47, 0xebd1, 0xebc9, 0xedd0, 0xedd1, 0xee3f, 0xee40, + 0xee41, 0xfc09, 0xee42, 0xefc4, 0xf09b, 0xf092, 0xf093, 0x4c96, + 0xf094, 0xf095, 0x52fd, 0x52fd, 0xf2f3, 0xf2f4, 0xf2f5, 0xf2f6, + 0xf560, 0xf59e, 0xf5a0, 0xf5a1, 0xf61c, 0xf69f, 0x5356, 0x5712, + 0x571f, 0x5715, 0x5716, 0x5717, 0xfa0c, 0x5718, 0x57c2, 0x57c3, + 0x57c4, 0x58a1, 0x591b, 0x591c, 0x5971, 0x5b13, 0x5e17, 0x5e8f, + 0x635f, 0x6360, 0x63ac, 0x52fd, 0x52fd, 0x6361, 0x6362, 0x6363, + 0x6364, 0x6365, 0x52fd, 0x6799, 0x679a, 0x679b, 0x679c, 0x679d, + 0x679e, 0x679f, 0x67a0, 0x6bda, 0x6bdb, 0x6bdc, 0x6bdd, 0x6bde, + 0x6bdf, 0x6dd5, 0x6dd6, 0x6dd7, 0x6dd8, 0x6de0, 0x6eb4, 0x52fd, + 0x726e, 0x726f, 0x7270, 0x7463, 0x52fd, 0x75d5, + /* 0x5a */ + 0x75d6, 0x75d7, 0x75d8, 0x7730, 0x7bb5, 0x7bb6, 0x7bc1, 0x7bf7, + 0x05a0, 0x7bcb, 0x7be8, 0x52fd, 0x7be9, 0x7bb7, 0x7d15, 0x80e6, + 0x80e7, 0x80e8, 0x80e9, 0x80ea, 0x80eb, 0xfaca, 0x830b, 0x830c, + 0x8364, 0x85d4, 0x85d5, 0x85d6, 0x85d8, 0x86a5, 0x535b, 0x8a0f, + 0x8a10, 0x52fd, 0x8a11, 0x8a12, 0x8a13, 0x8a14, 0x8a15, 0x8a16, + 0x8a17, 0x8a18, 0x8a19, 0x8a1a, 0x8a2f, 0x8a1b, 0x8a1c, 0x8a3f, + 0x8a1d, 0x8a1e, 0x8a2c, 0x8a1f, 0x8c24, 0x8ca4, 0x8ca5, 0xb551, + 0x8dfe, 0x8f11, 0x8f12, 0x8f13, 0x8f54, 0x935e, 0x9321, 0x933f, + 0x9340, 0x9341, 0x9342, 0x9343, 0x9344, 0x9320, 0x9345, 0x52fd, + 0x9346, 0x93b0, 0x9347, 0x9357, 0x9301, 0x93b1, 0x935a, 0x9348, + 0x9704, 0x9705, 0x31f5, 0x974f, 0x9750, 0x9706, 0x9707, 0x9708, + 0x9709, 0x970a, 0x970b, 0x970c, 0x970d, 0x970e, + /* 0x5b */ + 0x970f, 0x9710, 0x9711, 0x9833, 0x9834, 0x9835, 0x98fc, 0x98fd, + 0x9bb0, 0x9bb1, 0x9bb2, 0x9bb3, 0x0b01, 0x9d7b, 0x9d7c, 0x9d7d, + 0x9d7e, 0x9d7f, 0x9d80, 0x9d81, 0x9d82, 0x9ef9, 0x9fda, 0xa1a1, + 0x52fd, 0x52fd, 0xa3ad, 0xa3ae, 0x52fd, 0xa5c8, 0xa5c9, 0xa5ca, + 0xa882, 0xa883, 0xa884, 0xa885, 0xa886, 0xa887, 0xa888, 0xa889, + 0xa88a, 0x52fd, 0xaa07, 0xaa08, 0xaa01, 0xaa09, 0xaa02, 0xaa0a, + 0xaa0b, 0xaa0c, 0xaba7, 0xab98, 0xab99, 0xab9a, 0xab9b, 0xab9c, + 0x3950, 0xab9d, 0xad1a, 0xadb2, 0xafb0, 0xafb1, 0x3b14, 0xafb2, + 0xafb3, 0xafb4, 0xafb5, 0xafb6, 0xafc0, 0xafb7, 0xafb8, 0xafb9, + 0xafba, 0xb01d, 0xb20c, 0xb20d, 0xb20e, 0xb235, 0xb20f, 0xb210, + 0xb211, 0xb212, 0xb422, 0xb423, 0xb424, 0x52fd, 0xb425, 0xb426, + 0xb427, 0xb428, 0xb429, 0xb42a, 0xb42b, 0xb42c, + /* 0x5c */ + 0xb42d, 0xb42e, 0xb552, 0xb553, 0xb619, 0xb6bf, 0xb78b, 0xb78c, + 0xb823, 0xb824, 0xb8f1, 0xb8d8, 0xfb7f, 0xbb4e, 0xbb4f, 0xbb55, + 0xbb50, 0xbb51, 0xbb52, 0xbb53, 0xbb02, 0xbb54, 0xbbf1, 0xbc24, + 0xbdd1, 0xc27c, 0xc27d, 0xc27e, 0xc27f, 0xc280, 0xc29f, 0xc281, + 0xc282, 0xc283, 0xc284, 0xc285, 0xc286, 0xc287, 0xc288, 0xc29b, + 0xc289, 0xc28a, 0xc28b, 0xc28c, 0x52fd, 0xc2a1, 0xc28d, 0xc28e, + 0xc4f3, 0xc4f4, 0xc4f5, 0xc724, 0xc725, 0xc726, 0xc727, 0xc728, + 0xc729, 0xc72a, 0x52fd, 0xc72b, 0xc8cd, 0xc901, 0x788d, 0xca70, + 0xcb80, 0xcb81, 0xcdc0, 0xcdc1, 0xcdc2, 0xcdc3, 0xcdc4, 0xcdc5, + 0xcdc6, 0xcdc7, 0xcdc8, 0xcffe, 0x52fd, 0xd0d9, 0xd0dc, 0xd0da, + 0xd175, 0xd258, 0xd259, 0xd25a, 0xd25b, 0xd25c, 0xd3ec, 0x131a, + 0xd3f3, 0xd572, 0xd573, 0xd682, 0xd683, 0xd72a, + /* 0x5d */ + 0xd72b, 0xd72c, 0xd72d, 0xd8f6, 0xd900, 0xd8f7, 0xd8f8, 0xd8f9, + 0x52fd, 0xdb94, 0xdb95, 0xdb96, 0xdc1b, 0xdd86, 0xdd4c, 0xdd4d, + 0xdd83, 0x52fd, 0xdd82, 0xdd4e, 0xdd4f, 0xdd50, 0xdd51, 0xdd81, + 0x4887, 0xdd52, 0xdd53, 0xdd54, 0xdd55, 0x52fd, 0xdd56, 0xdd57, + 0x4885, 0xdd58, 0xdd5b, 0xdd5c, 0xdd5d, 0xdd5e, 0xdd5f, 0xdd60, + 0xdd61, 0xdd7c, 0xdd62, 0x143c, 0x52fd, 0xdd63, 0xdd64, 0xe073, + 0xe245, 0xe246, 0xe247, 0xe24c, 0xe312, 0x52fd, 0xe313, 0xe439, + 0xe403, 0xe40d, 0xe530, 0xe5d5, 0xe6c0, 0xe7f2, 0xe7f3, 0xe7f4, + 0xe7f5, 0xe7f6, 0xe7f7, 0xe8fa, 0xe8fb, 0xea45, 0xea46, 0xeb49, + 0xebe7, 0xebe8, 0xedd8, 0xedd9, 0xee55, 0xee56, 0xee57, 0xefda, + 0xefdb, 0xefdc, 0xf0b8, 0xf0b9, 0xf0ba, 0x4cb1, 0xf0bb, 0xf289, + 0xf0bc, 0xf330, 0xf331, 0xf332, 0xf333, 0x52fd, + /* 0x5e */ + 0xf334, 0xf335, 0xf336, 0x4e47, 0xf337, 0xf5b2, 0xf690, 0xf626, + 0xf6a2, 0xf738, 0x52fd, 0x572e, 0x52fd, 0x572f, 0x5730, 0x572a, + 0x572b, 0x57c9, 0x5837, 0x5920, 0x5972, 0x5b1f, 0x5c65, 0x5cca, + 0x5dc0, 0x5dc1, 0x5dc2, 0x63b7, 0x63b8, 0x63b9, 0x63ba, 0x63bb, + 0x52fd, 0x52fd, 0x63bc, 0x63bd, 0x63be, 0x63f2, 0x67b5, 0x67b7, + 0x67b8, 0x63df, 0x67b9, 0x67d5, 0x67ba, 0x67bb, 0x684a, 0x6bf2, + 0x6bf3, 0x6bf4, 0x6bfa, 0x6bf5, 0x6c02, 0x6de2, 0x6de3, 0x728e, + 0x728b, 0x75e4, 0x75eb, 0x75e5, 0x7735, 0x7893, 0x7bea, 0x7beb, + 0x52fd, 0x7bec, 0x7bed, 0x7c17, 0x7bee, 0x7bef, 0x7bf0, 0x810e, + 0x810f, 0x8110, 0x8119, 0x8118, 0x8111, 0x8112, 0x8113, 0xfac7, + 0x8114, 0x8115, 0x066b, 0x8116, 0x8365, 0x85ea, 0x85eb, 0x85ec, + 0x85ed, 0x52fd, 0x85ee, 0x86ac, 0x8ac2, 0x8a69, + /* 0x5f */ + 0x8a81, 0x8a6a, 0x8a6b, 0x8a6c, 0x8a6d, 0x8a6e, 0x8a6f, 0x8a70, + 0x07f4, 0x8a71, 0x8a72, 0x8a73, 0x8a8c, 0x8a74, 0x8a75, 0x8a76, + 0x8f24, 0x8f2a, 0x938e, 0x93af, 0x938f, 0x9390, 0x9391, 0x52fd, + 0x9392, 0x9393, 0x9394, 0x9395, 0x9396, 0x9397, 0x9398, 0x9399, + 0x939a, 0x939b, 0x939c, 0x9739, 0x973b, 0x973a, 0x973c, 0x973d, + 0x973e, 0x973f, 0x9770, 0x9740, 0x9741, 0x9bc0, 0x9bc1, 0x9da4, + 0x9d97, 0x9da5, 0x9d98, 0x9d99, 0x9d9a, 0x52fd, 0x9d9b, 0x9da6, + 0x9d9c, 0x9d9d, 0x9d9e, 0x9d9f, 0xddce, 0x9dc8, 0x9da0, 0x9e19, + 0x9f0d, 0xa3bf, 0xa5e9, 0xa5ea, 0xa8a2, 0xa8a3, 0xa8a4, 0xa8a5, + 0xa8a6, 0xaa15, 0xaa17, 0xabbf, 0xabc0, 0xabc1, 0xabc2, 0xabc3, + 0xabc4, 0xabc5, 0x6c0d, 0xad23, 0xadbe, 0xb003, 0xb004, 0xb005, + 0xb006, 0xb007, 0xb008, 0xb009, 0xb00a, 0xb00b, + /* 0x60 */ + 0xb00c, 0xb020, 0xb00d, 0xb00e, 0xb00f, 0x52fd, 0xb226, 0xb227, + 0xb228, 0xb45d, 0xb45e, 0xb45f, 0xb460, 0xb461, 0xb462, 0xb463, + 0xb464, 0xb465, 0xb557, 0xb6cf, 0xb6d0, 0xb799, 0xb79a, 0xb8ea, + 0xb8eb, 0xb8ec, 0xbb7e, 0xbb7f, 0xbb80, 0x52fd, 0x52fd, 0xbb81, + 0xbb82, 0xbbf3, 0xbc25, 0xbc9f, 0xbca0, 0xbcf3, 0xbd00, 0xc2eb, + 0xc2ec, 0xc2ed, 0xc2ee, 0xc2ef, 0x52fd, 0x105c, 0xc2f0, 0xc2f1, + 0xc2f2, 0xc2f3, 0xc2f4, 0xc2f5, 0xc2f9, 0xc2fa, 0xc2fb, 0xc2fc, + 0xc2fd, 0xc2fe, 0xc2ff, 0xc300, 0xfbae, 0xc301, 0xc302, 0xc503, + 0xc786, 0xc779, 0x52fd, 0xc77a, 0xc77b, 0xc77c, 0xc784, 0xc77d, + 0xc77e, 0xc77f, 0xca86, 0xca87, 0xcb00, 0xcb01, 0xcb88, 0xcb89, + 0xcb8a, 0xcdf5, 0x52fd, 0xce25, 0xcdf6, 0xd0eb, 0xd0ec, 0xd0ed, + 0xd0ee, 0x1287, 0xd0ef, 0xd0f0, 0xd26c, 0xd421, + /* 0x61 */ + 0xd422, 0xd423, 0xd424, 0xd425, 0xd426, 0xd57b, 0xd57c, 0xd691, + 0xd692, 0xd693, 0xd90e, 0xd90f, 0xd910, 0xdbb3, 0xdc36, 0xddc6, + 0xdda1, 0xdda2, 0x48b9, 0xdda3, 0xddcc, 0xdda4, 0xdda5, 0xdda6, + 0xddcb, 0xdda7, 0x52fd, 0xdda8, 0xdda9, 0xddaa, 0x52fd, 0xddab, + 0xddac, 0xddad, 0x48bf, 0xddae, 0xddaf, 0xddb0, 0xe08c, 0xe08d, + 0xe08e, 0xfbf1, 0xe092, 0xe08f, 0xe252, 0xe253, 0xe254, 0xe255, + 0xe429, 0x52fd, 0xe5f3, 0xe5f4, 0xe80d, 0xe80e, 0xe80f, 0xe810, + 0xe914, 0xea71, 0xea72, 0xec0f, 0xec04, 0xec06, 0x52fd, 0xec07, + 0xeddc, 0xeddd, 0xee6d, 0xee79, 0xee6e, 0x52fd, 0xefec, 0xf0dd, + 0xf0de, 0xf0df, 0xf0e0, 0xf0e1, 0xf0e2, 0xf0e3, 0xf0e4, 0xf13a, + 0xf0e5, 0x4ccf, 0xf0e6, 0xf36b, 0xf36c, 0x974e, 0x4e64, 0xf5bd, + 0xf5be, 0xf5bf, 0xf634, 0x4fbf, 0xf812, 0x5740, + /* 0x62 */ + 0x5741, 0x6402, 0x6403, 0x6404, 0x6405, 0x6406, 0x67d7, 0x67cc, + 0x6998, 0x6c06, 0x6c07, 0x6caf, 0x6cb0, 0x6dea, 0x6df2, 0x72a2, + 0x72a3, 0x72a4, 0x7476, 0x75f5, 0x75f6, 0x75f7, 0x52fd, 0x7c3b, + 0x7c25, 0x7c3a, 0x7c3c, 0x7c3d, 0x7c3e, 0x8137, 0x8138, 0x8139, + 0x813a, 0x813b, 0x813c, 0x813d, 0x813e, 0x813f, 0x814b, 0x52fd, + 0x8140, 0x8322, 0x8367, 0x83d3, 0x85fa, 0x52fd, 0x8abc, 0x52fd, + 0x52fd, 0x8aa5, 0x0807, 0x8ab6, 0x52fd, 0x8aa6, 0x8abb, 0x8aa7, + 0x8aa8, 0x8aa9, 0x8aaa, 0x8aab, 0x8aac, 0x8abf, 0x8aad, 0x8aae, + 0x8aaf, 0x8c2e, 0x8e00, 0x939d, 0x939e, 0x93cb, 0x93cc, 0x93cd, + 0x93ce, 0x93cf, 0x52fd, 0x939f, 0x93d0, 0x93d1, 0x93d2, 0x93d3, + 0x93d4, 0x52fd, 0x52fd, 0x975d, 0x975e, 0x975f, 0x9760, 0x0b05, + 0x9dba, 0x9dbc, 0x0b06, 0x9db5, 0x9dbd, 0x9db6, + /* 0x63 */ + 0x9db7, 0x9db8, 0x9da8, 0xfb32, 0x9efe, 0x9efc, 0xa1e1, 0xa3c4, + 0xa3c5, 0xa614, 0xa8ae, 0xa8af, 0xa8b0, 0xa8b1, 0xa8b9, 0xabe7, + 0xb046, 0x52fd, 0xb047, 0xb048, 0xb049, 0xb01e, 0xb01f, 0xb04a, + 0xb04b, 0xb04c, 0xb04d, 0xb04e, 0x52fd, 0xb246, 0xb24b, 0xb490, + 0xb491, 0x52fd, 0xb492, 0xb493, 0xb494, 0xb55b, 0xb8f2, 0xb8f8, + 0xb8f9, 0xbb94, 0xbba4, 0xbb97, 0xbb98, 0xbc29, 0xbcae, 0xbdaf, + 0xc359, 0xc35a, 0x52fd, 0xc35b, 0xc35c, 0xc35d, 0xc35e, 0xc35f, + 0xc360, 0xc361, 0xc2aa, 0xc362, 0xc363, 0xc364, 0xc365, 0xc366, + 0xc367, 0xc368, 0xc369, 0xc36a, 0xc36b, 0xc36c, 0xc36d, 0xc36e, + 0xc36f, 0x52fd, 0xc7b2, 0xc7b3, 0xc7b4, 0x10f9, 0xc7b5, 0xc7b6, + 0xc7b7, 0xc7b8, 0xc7b9, 0xc7ba, 0xc7bb, 0xca88, 0x42b8, 0xce19, + 0xce1a, 0xce1b, 0xcf16, 0xd10c, 0xd10d, 0xd10e, + /* 0x64 */ + 0xd10f, 0x52fd, 0xd283, 0xd284, 0xd285, 0xd583, 0xd584, 0xd6b0, + 0x52fd, 0xd926, 0xd927, 0xd936, 0xd928, 0xd929, 0x52fd, 0x52fd, + 0xdde7, 0xdde8, 0xdde9, 0x1453, 0xddea, 0xddeb, 0x52fd, 0xddec, + 0xdded, 0xddee, 0xddef, 0xddf0, 0xddf1, 0xde0c, 0xddf2, 0xddf3, + 0xddf4, 0xddf5, 0xddf6, 0xddf7, 0xddf8, 0xe0a3, 0xe0a4, 0xe0a5, + 0xe0a6, 0xe0a7, 0x52fd, 0xe25c, 0x52fd, 0xe44b, 0xe4e1, 0xe615, + 0x52fd, 0xe616, 0xe617, 0xe82c, 0xe82d, 0xe922, 0xe923, 0xea96, + 0xea97, 0x52fd, 0xec2e, 0xec30, 0xec31, 0x52fd, 0xeddf, 0xee8b, + 0xee8c, 0x52fd, 0xee8d, 0xeffc, 0xeffd, 0xeffe, 0xefff, 0xf117, + 0xf12d, 0xf118, 0x4cf3, 0xf119, 0x52fd, 0xf112, 0xf11a, 0xf11b, + 0xf11c, 0x1669, 0x52fd, 0xf397, 0x16e5, 0xf398, 0xf399, 0x52fd, + 0xf6c4, 0x574f, 0x57cd, 0x5dc7, 0x641c, 0x641d, + /* 0x65 */ + 0x641e, 0x67e7, 0x67e9, 0x67ea, 0x67eb, 0x6c15, 0x6ff1, 0x6ff2, + 0x72b6, 0x78a0, 0x7c4a, 0x7d20, 0x8160, 0x8161, 0x8141, 0x8162, + 0x8603, 0x8604, 0x8ad9, 0x8ada, 0x8adb, 0x8adc, 0x8add, 0x52fd, + 0x8ade, 0x8adf, 0x8ae0, 0x8ae1, 0x8ae2, 0x0812, 0x8ae3, 0x52fd, + 0x8f31, 0x9405, 0x9406, 0x9407, 0x9772, 0x978a, 0x978b, 0x9788, + 0x52fd, 0x978c, 0x978d, 0x978e, 0x978f, 0x9790, 0x9842, 0x9843, + 0x52fd, 0x9dc1, 0x9dc2, 0x9dc3, 0x9dc4, 0xa3cb, 0xa622, 0x52fd, + 0x52fd, 0xa8c3, 0xa8c4, 0xa8c5, 0xa8c6, 0xaa1e, 0xaa25, 0xabf3, + 0xabf4, 0x52fd, 0xabf5, 0xad38, 0xad48, 0xadca, 0x3b4f, 0xb07a, + 0xb07b, 0xb255, 0xb256, 0xb4b1, 0xb4b2, 0xb4b3, 0x52fd, 0xb4b4, + 0xb4b5, 0xb7a4, 0xb900, 0xb901, 0xb902, 0xbbac, 0x52fd, 0xbcb3, + 0xc3b6, 0xc3b7, 0xc3b8, 0xc3b9, 0xc3ba, 0xc3bb, + /* 0x66 */ + 0xc3bc, 0xc3bd, 0xc3be, 0xc3bf, 0xc3c0, 0xc3c1, 0xc3c2, 0xc3c3, + 0xc3c4, 0xc3c5, 0xc3c6, 0xc3c7, 0xc7e3, 0xc7e4, 0xc7e5, 0xc7e6, + 0xc7e7, 0x52fd, 0xcab5, 0xcaa1, 0xcb95, 0xce3b, 0xce3c, 0xce3d, + 0xce3e, 0xcf14, 0xd120, 0xd121, 0xd122, 0xd123, 0xd124, 0xd296, + 0xd297, 0xd298, 0xd494, 0xd495, 0xd496, 0xd497, 0xd498, 0xd58f, + 0xd590, 0xd6bc, 0xd73b, 0xd93d, 0x52fd, 0xdbdf, 0xdc1e, 0xde23, + 0xde24, 0xde49, 0xde25, 0xde26, 0xde27, 0xde28, 0x4925, 0xde29, + 0xde2a, 0xde2e, 0xde2f, 0xde4e, 0xde30, 0xfbeb, 0xde31, 0xde32, + 0xde33, 0xde34, 0xde35, 0xde36, 0x52fd, 0xde37, 0xde50, 0xde38, + 0x52fd, 0xde39, 0xde3a, 0xde3b, 0xde3c, 0xde3d, 0xde3e, 0xe0b8, + 0xe0b9, 0xe262, 0xe263, 0xe341, 0xe46d, 0x52fd, 0xe652, 0xe637, + 0xe6db, 0xe83f, 0xe934, 0xeb5b, 0xec46, 0xec5a, + /* 0x67 */ + 0xec5b, 0xede1, 0xede2, 0xede3, 0xede4, 0xeea7, 0xeea8, 0xeea9, + 0xf00f, 0xf02b, 0xf156, 0xf157, 0xf158, 0xf15e, 0xf159, 0xf15a, + 0xf15b, 0xf15c, 0x52fd, 0xf168, 0x52fd, 0xf42c, 0xf3e2, 0xf3f3, + 0xf5d2, 0xf656, 0xf6ce, 0xf761, 0xf99b, 0xf9b4, 0x575c, 0xfa10, + 0x57d2, 0x5871, 0x5973, 0x5b2c, 0x5e94, 0x52fd, 0x643f, 0x6440, + 0x67f9, 0x67fa, 0x67fd, 0x67fb, 0x6c1c, 0x6c1d, 0x6dff, 0x6e00, + 0x6ff7, 0x9ffe, 0x52fd, 0x77b6, 0x7c54, 0x8177, 0x8179, 0x817a, + 0x817b, 0x8369, 0x8b02, 0x8b03, 0x8b04, 0x8b05, 0x8b06, 0x8b07, + 0x8b08, 0x8b09, 0x8b0a, 0x8b0b, 0x8b35, 0x52fd, 0x8f39, 0x941e, + 0x941f, 0x9420, 0x9421, 0x52fd, 0x9422, 0x9423, 0x9424, 0x942c, + 0x97b3, 0x97b5, 0x97b6, 0x97b7, 0x97b8, 0x9dd0, 0x9ffa, 0xa207, + 0xa2bd, 0xa3d7, 0xa3d2, 0xa8db, 0xa8d6, 0x575d, + /* 0x68 */ + 0xad43, 0xadcf, 0xb0a3, 0xb0a4, 0xb0a5, 0xb0a6, 0xb0a7, 0xb0a8, + 0xb0a9, 0xb25d, 0xb25e, 0xb4c9, 0xb4ca, 0xb4cb, 0xb4cc, 0xb906, + 0xb907, 0x52fd, 0xbbc5, 0xbbf5, 0xbcb4, 0xbcb8, 0xbcb5, 0xc3fd, + 0x1077, 0xc3fe, 0xc3ff, 0xc400, 0xc401, 0xc402, 0xc403, 0xc409, + 0xc404, 0xc405, 0xc406, 0xc407, 0xc811, 0xc812, 0xc813, 0xc814, + 0xc815, 0x4277, 0xcb98, 0xcb99, 0xd13c, 0xd12d, 0xd12e, 0x52fd, + 0xd4bb, 0xd4bc, 0x1378, 0xd73d, 0xd947, 0xd948, 0xd949, 0xd94a, + 0xdae1, 0xdae7, 0xdbeb, 0xdc20, 0xdc38, 0xde62, 0xde67, 0xde68, + 0xde69, 0xde6a, 0xde6b, 0xde6d, 0xde6e, 0xde6f, 0xde70, 0xde71, + 0xde72, 0xde8f, 0xde73, 0xde74, 0xde75, 0xde76, 0xde77, 0xe0c9, + 0xe0ca, 0x4ae6, 0xe0cb, 0xe0cc, 0xe0cd, 0xe351, 0x52fd, 0x52fd, + 0xe545, 0xe859, 0xe85a, 0xe85b, 0xe940, 0xeacf, + /* 0x69 */ + 0xeb5e, 0xec7b, 0xed93, 0xeebc, 0xf016, 0xf030, 0x52fd, 0xf18d, + 0xf18e, 0x4d2f, 0xf18f, 0xf190, 0xf191, 0xf192, 0xf193, 0xf194, + 0xf195, 0xf196, 0xf423, 0xf414, 0xf5db, 0xf70a, 0xf8ce, 0x5766, + 0x5768, 0x5767, 0x57d3, 0x6463, 0x6804, 0x699e, 0x6c26, 0x6c2a, + 0x7c6c, 0x7c64, 0x818f, 0x8190, 0x8334, 0x860e, 0x8b25, 0x8b26, + 0x8b27, 0x52fd, 0x8b28, 0x2c0c, 0x52fd, 0x8b29, 0x8b2a, 0x8b2b, + 0x8b2c, 0x8f3e, 0x9442, 0x9443, 0x9433, 0x97c1, 0x97c2, 0x97c3, + 0x9dd6, 0x9dd7, 0xa8e1, 0xa8e2, 0xaa2b, 0xadd1, 0xb0cc, 0xb0cd, + 0xb0ce, 0xb0cf, 0xb4de, 0xb4df, 0xb4e0, 0xb4e1, 0xbbf6, 0xc42c, + 0x52fd, 0xc454, 0xc42d, 0xc42e, 0xc841, 0xc842, 0xcac7, 0xcba0, + 0xcba1, 0xce70, 0xce71, 0xce72, 0x52fd, 0xd134, 0xd135, 0xd136, + 0xd2a6, 0xd4cc, 0x52fd, 0xd599, 0xdbf4, 0xde9b, + /* 0x6a */ + 0xde9e, 0xde9f, 0xdea0, 0xdea1, 0xdea2, 0xdea3, 0xdea4, 0xdea5, + 0xdea6, 0xdea7, 0xdea8, 0xe0db, 0xe0dc, 0xe0dd, 0xe0d7, 0xe0de, + 0xe0df, 0xe359, 0xe746, 0xe865, 0xe949, 0x52fd, 0xeadd, 0xec95, + 0xec96, 0xec97, 0xeed4, 0xeed6, 0xf026, 0x4d47, 0x1688, 0xf1c8, + 0xf1c5, 0xf1c6, 0xf1c7, 0xf451, 0xf452, 0xf453, 0xf454, 0xf455, + 0xf5de, 0x52fd, 0x576d, 0x57d5, 0x6472, 0x74ae, 0x760f, 0x7c6b, + 0x7c6d, 0x7c6e, 0x7c78, 0x8198, 0x8199, 0x819a, 0x8b44, 0x8b5c, + 0x8b45, 0x8e01, 0x9458, 0x9459, 0x945a, 0x52fd, 0x97d9, 0x97d6, + 0x9dda, 0x9ddf, 0x9ddb, 0xa003, 0xa8ef, 0x3836, 0xaa33, 0xadd2, + 0xb0e1, 0xb26f, 0xb564, 0xb90e, 0xc450, 0xc451, 0xc452, 0xc856, + 0xc857, 0xc858, 0x52fd, 0xce81, 0xce82, 0xcf1d, 0xcf1e, 0xd143, + 0xd2aa, 0xdbfd, 0x52fd, 0xdec6, 0xdec7, 0xded9, + /* 0x6b */ + 0xded7, 0x52fd, 0xdec8, 0xdec9, 0xdeca, 0xdecb, 0xdeda, 0x52fd, + 0xdecc, 0xdecd, 0xdece, 0xdecf, 0xded0, 0xded1, 0xdebc, 0xe0e1, + 0xe0e2, 0xe0e3, 0xe4a9, 0xe54e, 0xe877, 0x52fd, 0x52fd, 0xecac, + 0xecad, 0xedb6, 0xeee5, 0xf1f8, 0xf1ea, 0xf28d, 0xf1eb, 0xf495, + 0x576e, 0x57d8, 0x6483, 0x69a3, 0x6c30, 0x6e0f, 0x7c79, 0x7c7a, + 0x81a7, 0x81a8, 0x81a9, 0x81aa, 0x8619, 0x8b50, 0x8b51, 0x8b52, + 0x2c15, 0x8b68, 0x8b53, 0x8b54, 0x9be2, 0x9ddc, 0xac15, 0xac16, + 0xad4f, 0xb0f5, 0xb0f6, 0xb0f7, 0xb4f4, 0xb7cc, 0xb90f, 0xc466, + 0xc467, 0x52fd, 0xc468, 0xcba4, 0xce8b, 0xce8c, 0xd4fa, 0xdee6, + 0xdeed, 0xdeee, 0xdeef, 0xdef0, 0xdefe, 0xe0e7, 0xe0e8, 0xe4b3, + 0xe4e4, 0xe883, 0xedec, 0x52fd, 0xf216, 0x52fd, 0x52fd, 0xf217, + 0xf4c3, 0xf4ac, 0xf5ed, 0x52fd, 0x52fd, 0xf8b4, + /* 0x6c */ + 0x52fd, 0x648a, 0x648b, 0x6c34, 0x6e14, 0x72df, 0x77bb, 0x7c7f, + 0x7c81, 0x81ad, 0x81ae, 0x8b62, 0x8b6e, 0x52fd, 0x946e, 0x52fd, + 0x9a17, 0x9de6, 0x9f10, 0xac19, 0x52fd, 0xb910, 0xbdf2, 0xc476, + 0xc477, 0xce95, 0xce96, 0xdf00, 0xdf01, 0xdf31, 0xfbed, 0xdf1c, + 0xe36d, 0xeef4, 0xeef5, 0xf03d, 0xf232, 0xf233, 0xf5f4, 0x52fd, + 0x5773, 0x6c37, 0x52fd, 0x8b71, 0xb10f, 0x52fd, 0xb10e, 0xb911, + 0xc485, 0xdf14, 0xdf15, 0xdf16, 0xdf17, 0xdf18, 0xdf19, 0xdf1a, + 0xe4c3, 0xf242, 0xf243, 0xf244, 0xf248, 0xf4fb, 0x69a5, 0x6cb8, + 0x81b2, 0x833d, 0x8b72, 0x97e7, 0x97e8, 0xa659, 0xaa3a, 0xb114, + 0xb4ff, 0xbcc0, 0xc48d, 0x1084, 0xc48e, 0x52fd, 0xdf22, 0x52fd, + 0x52fd, 0xef04, 0xef29, 0xf251, 0xf266, 0xf50e, 0xfc13, 0x52fd, + 0x649b, 0x649c, 0x7616, 0x7c86, 0x7c87, 0x52fd, + /* 0x6d */ + 0xdf2c, 0xdf30, 0xdf28, 0xe95f, 0x52fd, 0x947e, 0xb119, 0xd50a, + 0xdf36, 0xe0fc, 0xf26d, 0xf26e, 0xf9c6, 0x1ab5, 0x8b7b, 0xb506, + 0xc89f, 0xf532, 0xd50d, 0x7c8b, 0xdf3b, 0x52fd, 0xf53d, 0xdf3c, + 0xdf3d, +}; + +static const ucs4_t cns11643_15_2uni_upages[253] = { + 0x03400, 0x03500, 0x03600, 0x03700, 0x03800, 0x03900, 0x03a00, 0x03b00, + 0x03c00, 0x03d00, 0x03e00, 0x03f00, 0x04000, 0x04100, 0x04300, 0x04400, + 0x04500, 0x04600, 0x04700, 0x04800, 0x04900, 0x04a00, 0x04c00, 0x04f00, + 0x05100, 0x05200, 0x05300, 0x05400, 0x05500, 0x05600, 0x05700, 0x05800, + 0x05a00, 0x05b00, 0x05c00, 0x05e00, 0x05f00, 0x06200, 0x06500, 0x06600, + 0x06700, 0x06800, 0x06900, 0x06a00, 0x06b00, 0x06c00, 0x06e00, 0x06f00, + 0x07000, 0x07100, 0x07300, 0x07400, 0x07500, 0x07600, 0x07700, 0x07800, + 0x07900, 0x07a00, 0x07b00, 0x07c00, 0x07d00, 0x07f00, 0x08200, 0x08300, + 0x08600, 0x08700, 0x08900, 0x08a00, 0x08e00, 0x08f00, 0x09000, 0x09200, + 0x09300, 0x09400, 0x09500, 0x09600, 0x09b00, 0x09c00, 0x09d00, 0x09e00, + 0x09f00, 0x0fa00, 0x0ff00, 0x20000, 0x20100, 0x20200, 0x20300, 0x20400, + 0x20500, 0x20600, 0x20700, 0x20800, 0x20900, 0x20a00, 0x20b00, 0x20c00, + 0x20d00, 0x20e00, 0x20f00, 0x21000, 0x21100, 0x21200, 0x21300, 0x21400, + 0x21500, 0x21600, 0x21700, 0x21800, 0x21900, 0x21a00, 0x21b00, 0x21c00, + 0x21d00, 0x21e00, 0x21f00, 0x22000, 0x22100, 0x22200, 0x22300, 0x22400, + 0x22500, 0x22600, 0x22700, 0x22800, 0x22900, 0x22a00, 0x22b00, 0x22c00, + 0x22d00, 0x22e00, 0x22f00, 0x23000, 0x23100, 0x23200, 0x23300, 0x23400, + 0x23500, 0x23600, 0x23700, 0x23800, 0x23900, 0x23a00, 0x23b00, 0x23c00, + 0x23d00, 0x23e00, 0x23f00, 0x24000, 0x24100, 0x24200, 0x24300, 0x24400, + 0x24500, 0x24600, 0x24700, 0x24800, 0x24900, 0x24a00, 0x24b00, 0x24c00, + 0x24d00, 0x24e00, 0x24f00, 0x25000, 0x25100, 0x25200, 0x25300, 0x25400, + 0x25500, 0x25600, 0x25700, 0x25800, 0x25900, 0x25a00, 0x25b00, 0x25c00, + 0x25d00, 0x25e00, 0x25f00, 0x26000, 0x26100, 0x26200, 0x26300, 0x26400, + 0x26500, 0x26600, 0x26700, 0x26800, 0x26900, 0x26a00, 0x26b00, 0x26c00, + 0x26d00, 0x26e00, 0x26f00, 0x27000, 0x27100, 0x27200, 0x27300, 0x27400, + 0x27500, 0x27600, 0x27700, 0x27800, 0x27900, 0x27a00, 0x27b00, 0x27c00, + 0x27d00, 0x27e00, 0x27f00, 0x28000, 0x28100, 0x28200, 0x28300, 0x28400, + 0x28500, 0x28600, 0x28700, 0x28800, 0x28900, 0x28a00, 0x28b00, 0x28c00, + 0x28d00, 0x28e00, 0x28f00, 0x29000, 0x29100, 0x29200, 0x29300, 0x29400, + 0x29500, 0x29600, 0x29700, 0x29800, 0x29900, 0x29a00, 0x29b00, 0x29c00, + 0x29d00, 0x29e00, 0x29f00, 0x2a000, 0x2a100, 0x2a200, 0x2a300, 0x2a400, + 0x2a500, 0x2a600, 0x2f800, 0x2f900, 0x2fa00, +}; + +static int +cns11643_15_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x21 && c1 <= 0x6d)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + ucs4_t wc = 0xfffd; + unsigned short swc; + { + if (i < 7169) + swc = cns11643_15_2uni_page21[i], + wc = cns11643_15_2uni_upages[swc>>8] | (swc & 0xff); + } + if (wc != 0xfffd) { + *pwc = wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + diff --git a/graf2d/win32gdk/gdk/src/iconv/cns11643_2.h b/graf2d/win32gdk/gdk/src/iconv/cns11643_2.h new file mode 100644 index 0000000000000..7a73c60fa738e --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cns11643_2.h @@ -0,0 +1,1112 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CNS 11643-1992 plane 2 + */ + +static const unsigned short cns11643_2_2uni_page21[7650] = { + /* 0x21 */ + 0x4e42, 0x4e5c, 0x51f5, 0x531a, 0x5382, 0x4e07, 0x4e0c, 0x4e47, + 0x4e8d, 0x56d7, 0x5c6e, 0x5f73, 0x4e0f, 0x5187, 0x4e0e, 0x4e2e, + 0x4e93, 0x4ec2, 0x4ec9, 0x4ec8, 0x5198, 0x52fc, 0x536c, 0x53b9, + 0x5720, 0x5903, 0x592c, 0x5c10, 0x5dff, 0x65e1, 0x6bb3, 0x6bcc, + 0x6c14, 0x723f, 0x4e31, 0x4e3c, 0x4ee8, 0x4edc, 0x4ee9, 0x4ee1, + 0x4edd, 0x4eda, 0x520c, 0x5209, 0x531c, 0x534c, 0x5722, 0x5723, + 0x5917, 0x592f, 0x5b81, 0x5b84, 0x5c12, 0x5c3b, 0x5c74, 0x5c73, + 0x5e04, 0x5e80, 0x5e82, 0x5fc9, 0x6209, 0x6250, 0x6c15, 0x6c36, + 0x6c43, 0x6c3f, 0x6c3b, 0x72ae, 0x72b0, 0x738a, 0x79b8, 0x808a, + 0x961e, 0x4f0e, 0x4f18, 0x4f2c, 0x4ef5, 0x4f14, 0x4ef1, 0x4f00, + 0x4ef7, 0x4f08, 0x4f1d, 0x4f02, 0x4f05, 0x4f22, 0x4f13, 0x4f04, + 0x4ef4, 0x4f12, 0x51b1, 0x5213, 0x5210, 0x52a6, + /* 0x22 */ + 0x5322, 0x531f, 0x534d, 0x538a, 0x5407, 0x56e1, 0x56df, 0x572e, + 0x572a, 0x5734, 0x593c, 0x5980, 0x597c, 0x5985, 0x597b, 0x597e, + 0x5977, 0x597f, 0x5b56, 0x5c15, 0x5c25, 0x5c7c, 0x5c7a, 0x5c7b, + 0x5c7e, 0x5ddf, 0x5e75, 0x5e84, 0x5f02, 0x5f1a, 0x5f74, 0x5fd5, + 0x5fd4, 0x5fcf, 0x625c, 0x625e, 0x6264, 0x6261, 0x6266, 0x6262, + 0x6259, 0x6260, 0x625a, 0x6265, 0x6537, 0x65ef, 0x65ee, 0x673e, + 0x6739, 0x6738, 0x673b, 0x673a, 0x673f, 0x673c, 0x6733, 0x6c18, + 0x6c46, 0x6c52, 0x6c5c, 0x6c4f, 0x6c4a, 0x6c54, 0x6c4b, 0x6c4c, + 0x7071, 0x725e, 0x72b4, 0x72b5, 0x738e, 0x752a, 0x767f, 0x7a75, + 0x7f51, 0x8278, 0x827c, 0x8280, 0x827d, 0x827f, 0x864d, 0x897e, + 0x9099, 0x9097, 0x9098, 0x909b, 0x9094, 0x9622, 0x9624, 0x9620, + 0x9623, 0x4f56, 0x4f3b, 0x4f62, 0x4f49, 0x4f53, + /* 0x23 */ + 0x4f64, 0x4f3e, 0x4f67, 0x4f52, 0x4f5f, 0x4f41, 0x4f58, 0x4f2d, + 0x4f33, 0x4f3f, 0x4f61, 0x518f, 0x51b9, 0x521c, 0x521e, 0x5221, + 0x52ad, 0x52ae, 0x5309, 0x5363, 0x5372, 0x538e, 0x538f, 0x5430, + 0x5437, 0x542a, 0x5454, 0x5445, 0x5419, 0x541c, 0x5425, 0x5418, + 0x543d, 0x544f, 0x5441, 0x5428, 0x5424, 0x5447, 0x56ee, 0x56e7, + 0x56e5, 0x5741, 0x5745, 0x574c, 0x5749, 0x574b, 0x5752, 0x5906, + 0x5940, 0x59a6, 0x5998, 0x59a0, 0x5997, 0x598e, 0x59a2, 0x5990, + 0x598f, 0x59a7, 0x59a1, 0x5b8e, 0x5b92, 0x5c28, 0x5c2a, 0x5c8d, + 0x5c8f, 0x5c88, 0x5c8b, 0x5c89, 0x5c92, 0x5c8a, 0x5c86, 0x5c93, + 0x5c95, 0x5de0, 0x5e0a, 0x5e0e, 0x5e8b, 0x5e89, 0x5e8c, 0x5e88, + 0x5e8d, 0x5f05, 0x5f1d, 0x5f78, 0x5f76, 0x5fd2, 0x5fd1, 0x5fd0, + 0x5fed, 0x5fe8, 0x5fee, 0x5ff3, 0x5fe1, 0x5fe4, + /* 0x24 */ + 0x5fe3, 0x5ffa, 0x5fef, 0x5ff7, 0x5ffb, 0x6000, 0x5ff4, 0x623a, + 0x6283, 0x628c, 0x628e, 0x628f, 0x6294, 0x6287, 0x6271, 0x627b, + 0x627a, 0x6270, 0x6281, 0x6288, 0x6277, 0x627d, 0x6272, 0x6274, + 0x65f0, 0x65f4, 0x65f3, 0x65f2, 0x65f5, 0x6745, 0x6747, 0x6759, + 0x6755, 0x674c, 0x6748, 0x675d, 0x674d, 0x675a, 0x674b, 0x6bd0, + 0x6c19, 0x6c1a, 0x6c78, 0x6c67, 0x6c6b, 0x6c84, 0x6c8b, 0x6c8f, + 0x6c71, 0x6c6f, 0x6c69, 0x6c9a, 0x6c6d, 0x6c87, 0x6c95, 0x6c9c, + 0x6c66, 0x6c73, 0x6c65, 0x6c7b, 0x6c8e, 0x7074, 0x707a, 0x7263, + 0x72bf, 0x72bd, 0x72c3, 0x72c6, 0x72c1, 0x72ba, 0x72c5, 0x7395, + 0x7397, 0x7393, 0x7394, 0x7392, 0x753a, 0x7539, 0x7594, 0x7595, + 0x7681, 0x793d, 0x8034, 0x8095, 0x8099, 0x8090, 0x8092, 0x809c, + 0x8290, 0x828f, 0x8285, 0x828e, 0x8291, 0x8293, + /* 0x25 */ + 0x828a, 0x8283, 0x8284, 0x8c78, 0x8fc9, 0x8fbf, 0x909f, 0x90a1, + 0x90a5, 0x909e, 0x90a7, 0x90a0, 0x9630, 0x9628, 0x962f, 0x962d, + 0x4e33, 0x4f98, 0x4f7c, 0x4f85, 0x4f7d, 0x4f80, 0x4f87, 0x4f76, + 0x4f74, 0x4f89, 0x4f84, 0x4f77, 0x4f4c, 0x4f97, 0x4f6a, 0x4f9a, + 0x4f79, 0x4f81, 0x4f78, 0x4f90, 0x4f9c, 0x4f94, 0x4f9e, 0x4f92, + 0x4f82, 0x4f95, 0x4f6b, 0x4f6e, 0x519e, 0x51bc, 0x51be, 0x5235, + 0x5232, 0x5233, 0x5246, 0x5231, 0x52bc, 0x530a, 0x530b, 0x533c, + 0x5392, 0x5394, 0x5487, 0x547f, 0x5481, 0x5491, 0x5482, 0x5488, + 0x546b, 0x547a, 0x547e, 0x5465, 0x546c, 0x5474, 0x5466, 0x548d, + 0x546f, 0x5461, 0x5460, 0x5498, 0x5463, 0x5467, 0x5464, 0x56f7, + 0x56f9, 0x576f, 0x5772, 0x576d, 0x576b, 0x5771, 0x5770, 0x5776, + 0x5780, 0x5775, 0x577b, 0x5773, 0x5774, 0x5762, + /* 0x26 */ + 0x5768, 0x577d, 0x590c, 0x5945, 0x59b5, 0x59ba, 0x59cf, 0x59ce, + 0x59b2, 0x59cc, 0x59c1, 0x59b6, 0x59bc, 0x59c3, 0x59d6, 0x59b1, + 0x59bd, 0x59c0, 0x59c8, 0x59b4, 0x59c7, 0x5b62, 0x5b65, 0x5b93, + 0x5b95, 0x5c44, 0x5c47, 0x5cae, 0x5ca4, 0x5ca0, 0x5cb5, 0x5caf, + 0x5ca8, 0x5cac, 0x5c9f, 0x5ca3, 0x5cad, 0x5ca2, 0x5caa, 0x5ca7, + 0x5c9d, 0x5ca5, 0x5cb6, 0x5cb0, 0x5ca6, 0x5e17, 0x5e14, 0x5e19, + 0x5f28, 0x5f22, 0x5f23, 0x5f24, 0x5f54, 0x5f82, 0x5f7e, 0x5f7d, + 0x5fde, 0x5fe5, 0x602d, 0x6026, 0x6019, 0x6032, 0x600b, 0x6034, + 0x600a, 0x6017, 0x6033, 0x601a, 0x601e, 0x602c, 0x6022, 0x600d, + 0x6010, 0x602e, 0x6013, 0x6011, 0x600c, 0x6009, 0x601c, 0x6214, + 0x623d, 0x62ad, 0x62b4, 0x62d1, 0x62be, 0x62aa, 0x62b6, 0x62ca, + 0x62ae, 0x62b3, 0x62af, 0x62bb, 0x62a9, 0x62b0, + /* 0x27 */ + 0x62b8, 0x653d, 0x65a8, 0x65bb, 0x6609, 0x65fc, 0x6604, 0x6612, + 0x6608, 0x65fb, 0x6603, 0x660b, 0x660d, 0x6605, 0x65fd, 0x6611, + 0x6610, 0x66f6, 0x670a, 0x6785, 0x676c, 0x678e, 0x6792, 0x6776, + 0x677b, 0x6798, 0x6786, 0x6784, 0x6774, 0x678d, 0x678c, 0x677a, + 0x679f, 0x6791, 0x6799, 0x6783, 0x677d, 0x6781, 0x6778, 0x6779, + 0x6794, 0x6b25, 0x6b80, 0x6b7e, 0x6bde, 0x6c1d, 0x6c93, 0x6cec, + 0x6ceb, 0x6cee, 0x6cd9, 0x6cb6, 0x6cd4, 0x6cad, 0x6ce7, 0x6cb7, + 0x6cd0, 0x6cc2, 0x6cba, 0x6cc3, 0x6cc6, 0x6ced, 0x6cf2, 0x6cd2, + 0x6cdd, 0x6cb4, 0x6c8a, 0x6c9d, 0x6c80, 0x6cde, 0x6cc0, 0x6d30, + 0x6ccd, 0x6cc7, 0x6cb0, 0x6cf9, 0x6ccf, 0x6ce9, 0x6cd1, 0x7094, + 0x7098, 0x7085, 0x7093, 0x7086, 0x7084, 0x7091, 0x7096, 0x7082, + 0x709a, 0x7083, 0x726a, 0x72d6, 0x72cb, 0x72d8, + /* 0x28 */ + 0x72c9, 0x72dc, 0x72d2, 0x72d4, 0x72da, 0x72cc, 0x72d1, 0x73a4, + 0x73a1, 0x73ad, 0x73a6, 0x73a2, 0x73a0, 0x73ac, 0x739d, 0x74dd, + 0x74e8, 0x753f, 0x7540, 0x753e, 0x758c, 0x7598, 0x76af, 0x76f3, + 0x76f1, 0x76f0, 0x76f5, 0x77f8, 0x77fc, 0x77f9, 0x77fb, 0x77fa, + 0x77f7, 0x7942, 0x793f, 0x79c5, 0x7a78, 0x7a7b, 0x7afb, 0x7c75, + 0x7cfd, 0x8035, 0x808f, 0x80ae, 0x80a3, 0x80b8, 0x80b5, 0x80ad, + 0x8220, 0x82a0, 0x82c0, 0x82ab, 0x829a, 0x8298, 0x829b, 0x82b5, + 0x82a7, 0x82ae, 0x82bc, 0x829e, 0x82ba, 0x82b4, 0x82a8, 0x82a1, + 0x82a9, 0x82c2, 0x82a4, 0x82c3, 0x82b6, 0x82a2, 0x8670, 0x866f, + 0x866d, 0x866e, 0x8c56, 0x8fd2, 0x8fcb, 0x8fd3, 0x8fcd, 0x8fd6, + 0x8fd5, 0x8fd7, 0x90b2, 0x90b4, 0x90af, 0x90b3, 0x90b0, 0x9639, + 0x963d, 0x963c, 0x963a, 0x9643, 0x4fcd, 0x4fc5, + /* 0x29 */ + 0x4fd3, 0x4fb2, 0x4fc9, 0x4fcb, 0x4fc1, 0x4fd4, 0x4fdc, 0x4fd9, + 0x4fbb, 0x4fb3, 0x4fdb, 0x4fc7, 0x4fd6, 0x4fba, 0x4fc0, 0x4fb9, + 0x4fec, 0x5244, 0x5249, 0x52c0, 0x52c2, 0x533d, 0x537c, 0x5397, + 0x5396, 0x5399, 0x5398, 0x54ba, 0x54a1, 0x54ad, 0x54a5, 0x54cf, + 0x54c3, 0x830d, 0x54b7, 0x54ae, 0x54d6, 0x54b6, 0x54c5, 0x54c6, + 0x54a0, 0x5470, 0x54bc, 0x54a2, 0x54be, 0x5472, 0x54de, 0x54b0, + 0x57b5, 0x579e, 0x579f, 0x57a4, 0x578c, 0x5797, 0x579d, 0x579b, + 0x5794, 0x5798, 0x578f, 0x5799, 0x57a5, 0x579a, 0x5795, 0x58f4, + 0x590d, 0x5953, 0x59e1, 0x59de, 0x59ee, 0x5a00, 0x59f1, 0x59dd, + 0x59fa, 0x59fd, 0x59fc, 0x59f6, 0x59e4, 0x59f2, 0x59f7, 0x59db, + 0x59e9, 0x59f3, 0x59f5, 0x59e0, 0x59fe, 0x59f4, 0x59ed, 0x5ba8, + 0x5c4c, 0x5cd0, 0x5cd8, 0x5ccc, 0x5cd7, 0x5ccb, + /* 0x2a */ + 0x5cdb, 0x5cde, 0x5cda, 0x5cc9, 0x5cc7, 0x5cca, 0x5cd6, 0x5cd3, + 0x5cd4, 0x5ccf, 0x5cc8, 0x5cc6, 0x5cce, 0x5cdf, 0x5cf8, 0x5df9, + 0x5e21, 0x5e22, 0x5e23, 0x5e20, 0x5e24, 0x5eb0, 0x5ea4, 0x5ea2, + 0x5e9b, 0x5ea3, 0x5ea5, 0x5f07, 0x5f2e, 0x5f56, 0x5f86, 0x6037, + 0x6039, 0x6054, 0x6072, 0x605e, 0x6045, 0x6053, 0x6047, 0x6049, + 0x605b, 0x604c, 0x6040, 0x6042, 0x605f, 0x6024, 0x6044, 0x6058, + 0x6066, 0x606e, 0x6242, 0x6243, 0x62cf, 0x630d, 0x630b, 0x62f5, + 0x630e, 0x6303, 0x62eb, 0x62f9, 0x630f, 0x630c, 0x62f8, 0x62f6, + 0x6300, 0x6313, 0x6314, 0x62fa, 0x6315, 0x62fb, 0x62f0, 0x6541, + 0x6543, 0x65aa, 0x65bf, 0x6636, 0x6621, 0x6632, 0x6635, 0x661c, + 0x6626, 0x6622, 0x6633, 0x662b, 0x663a, 0x661d, 0x6634, 0x6639, + 0x662e, 0x670f, 0x6710, 0x67c1, 0x67f2, 0x67c8, + /* 0x2b */ + 0x67ba, 0x67dc, 0x67bb, 0x67f8, 0x67d8, 0x67c0, 0x67b7, 0x67c5, + 0x67eb, 0x67e4, 0x67df, 0x67b5, 0x67cd, 0x67b3, 0x67f7, 0x67f6, + 0x67ee, 0x67e3, 0x67c2, 0x67b9, 0x67ce, 0x67e7, 0x67f0, 0x67b2, + 0x67fc, 0x67c6, 0x67ed, 0x67cc, 0x67ae, 0x67e6, 0x67db, 0x67fa, + 0x67c9, 0x67ca, 0x67c3, 0x67ea, 0x67cb, 0x6b28, 0x6b82, 0x6b84, + 0x6bb6, 0x6bd6, 0x6bd8, 0x6be0, 0x6c20, 0x6c21, 0x6d28, 0x6d34, + 0x6d2d, 0x6d1f, 0x6d3c, 0x6d3f, 0x6d12, 0x6d0a, 0x6cda, 0x6d33, + 0x6d04, 0x6d19, 0x6d3a, 0x6d1a, 0x6d11, 0x6d00, 0x6d1d, 0x6d42, + 0x6d01, 0x6d18, 0x6d37, 0x6d03, 0x6d0f, 0x6d40, 0x6d07, 0x6d20, + 0x6d2c, 0x6d08, 0x6d22, 0x6d09, 0x6d10, 0x70b7, 0x709f, 0x70be, + 0x70b1, 0x70b0, 0x70a1, 0x70b4, 0x70b5, 0x70a9, 0x7241, 0x7249, + 0x724a, 0x726c, 0x7270, 0x7273, 0x726e, 0x72ca, + /* 0x2c */ + 0x72e4, 0x72e8, 0x72eb, 0x72df, 0x72ea, 0x72e6, 0x72e3, 0x7385, + 0x73cc, 0x73c2, 0x73c8, 0x73c5, 0x73b9, 0x73b6, 0x73b5, 0x73b4, + 0x73eb, 0x73bf, 0x73c7, 0x73be, 0x73c3, 0x73c6, 0x73b8, 0x73cb, + 0x74ec, 0x74ee, 0x752e, 0x7547, 0x7548, 0x75a7, 0x75aa, 0x7679, + 0x76c4, 0x7708, 0x7703, 0x7704, 0x7705, 0x770a, 0x76f7, 0x76fb, + 0x76fa, 0x77e7, 0x77e8, 0x7806, 0x7811, 0x7812, 0x7805, 0x7810, + 0x780f, 0x780e, 0x7809, 0x7803, 0x7813, 0x794a, 0x794c, 0x794b, + 0x7945, 0x7944, 0x79d5, 0x79cd, 0x79cf, 0x79d6, 0x79ce, 0x7a80, + 0x7a7e, 0x7ad1, 0x7b00, 0x7b01, 0x7c7a, 0x7c78, 0x7c79, 0x7c7f, + 0x7c80, 0x7c81, 0x7d03, 0x7d08, 0x7d01, 0x7f58, 0x7f91, 0x7f8d, + 0x7fbe, 0x8007, 0x800e, 0x800f, 0x8014, 0x8037, 0x80d8, 0x80c7, + 0x80e0, 0x80d1, 0x80c8, 0x80c2, 0x80d0, 0x80c5, + /* 0x2d */ + 0x80e3, 0x80d9, 0x80dc, 0x80ca, 0x80d5, 0x80c9, 0x80cf, 0x80d7, + 0x80e6, 0x80cd, 0x81ff, 0x8221, 0x8294, 0x82d9, 0x82fe, 0x82f9, + 0x8307, 0x82e8, 0x8300, 0x82d5, 0x833a, 0x82eb, 0x82d6, 0x82f4, + 0x82ec, 0x82e1, 0x82f2, 0x82f5, 0x830c, 0x82fb, 0x82f6, 0x82f0, + 0x82ea, 0x82e4, 0x82e0, 0x82fa, 0x82f3, 0x82ed, 0x8677, 0x8674, + 0x867c, 0x8673, 0x8841, 0x884e, 0x8867, 0x886a, 0x8869, 0x89d3, + 0x8a04, 0x8a07, 0x8d72, 0x8fe3, 0x8fe1, 0x8fee, 0x8fe0, 0x90f1, + 0x90bd, 0x90bf, 0x90d5, 0x90c5, 0x90be, 0x90c7, 0x90cb, 0x90c8, + 0x91d4, 0x91d3, 0x9654, 0x964f, 0x9651, 0x9653, 0x964a, 0x964e, + 0x501e, 0x5005, 0x5007, 0x5013, 0x5022, 0x5030, 0x501b, 0x4ff5, + 0x4ff4, 0x5033, 0x5037, 0x502c, 0x4ff6, 0x4ff7, 0x5017, 0x501c, + 0x5020, 0x5027, 0x5035, 0x502f, 0x5031, 0x500e, + /* 0x2e */ + 0x515a, 0x5194, 0x5193, 0x51ca, 0x51c4, 0x51c5, 0x51c8, 0x51ce, + 0x5261, 0x525a, 0x5252, 0x525e, 0x525f, 0x5255, 0x5262, 0x52cd, + 0x530e, 0x539e, 0x5526, 0x54e2, 0x5517, 0x5512, 0x54e7, 0x54f3, + 0x54e4, 0x551a, 0x54ff, 0x5504, 0x5508, 0x54eb, 0x5511, 0x5505, + 0x54f1, 0x550a, 0x54fb, 0x54f7, 0x54f8, 0x54e0, 0x550e, 0x5503, + 0x550b, 0x5701, 0x5702, 0x57cc, 0x5832, 0x57d5, 0x57d2, 0x57ba, + 0x57c6, 0x57bd, 0x57bc, 0x57b8, 0x57b6, 0x57bf, 0x57c7, 0x57d0, + 0x57b9, 0x57c1, 0x590e, 0x594a, 0x5a19, 0x5a16, 0x5a2d, 0x5a2e, + 0x5a15, 0x5a0f, 0x5a17, 0x5a0a, 0x5a1e, 0x5a33, 0x5b6c, 0x5ba7, + 0x5bad, 0x5bac, 0x5c03, 0x5c56, 0x5c54, 0x5cec, 0x5cff, 0x5cee, + 0x5cf1, 0x5cf7, 0x5d00, 0x5cf9, 0x5e29, 0x5e28, 0x5ea8, 0x5eae, + 0x5eaa, 0x5eac, 0x5f33, 0x5f30, 0x5f67, 0x605d, + /* 0x2f */ + 0x605a, 0x6067, 0x6041, 0x60a2, 0x6088, 0x6080, 0x6092, 0x6081, + 0x609d, 0x6083, 0x6095, 0x609b, 0x6097, 0x6087, 0x609c, 0x608e, + 0x6219, 0x6246, 0x62f2, 0x6310, 0x6356, 0x632c, 0x6344, 0x6345, + 0x6336, 0x6343, 0x63e4, 0x6339, 0x634b, 0x634a, 0x633c, 0x6329, + 0x6341, 0x6334, 0x6358, 0x6354, 0x6359, 0x632d, 0x6347, 0x6333, + 0x635a, 0x6351, 0x6338, 0x6357, 0x6340, 0x6348, 0x654a, 0x6546, + 0x65c6, 0x65c3, 0x65c4, 0x65c2, 0x664a, 0x665f, 0x6647, 0x6651, + 0x6712, 0x6713, 0x681f, 0x681a, 0x6849, 0x6832, 0x6833, 0x683b, + 0x684b, 0x684f, 0x6816, 0x6831, 0x681c, 0x6835, 0x682b, 0x682d, + 0x682f, 0x684e, 0x6844, 0x6834, 0x681d, 0x6812, 0x6814, 0x6826, + 0x6828, 0x682e, 0x684d, 0x683a, 0x6825, 0x6820, 0x6b2c, 0x6b2f, + 0x6b2d, 0x6b31, 0x6b34, 0x6b6d, 0x8082, 0x6b88, + /* 0x30 */ + 0x6be6, 0x6be4, 0x6be8, 0x6be3, 0x6be2, 0x6be7, 0x6c25, 0x6d7a, + 0x6d63, 0x6d64, 0x6d76, 0x6d0d, 0x6d61, 0x6d92, 0x6d58, 0x6d62, + 0x6d6d, 0x6d6f, 0x6d91, 0x6d8d, 0x6def, 0x6d7f, 0x6d86, 0x6d5e, + 0x6d67, 0x6d60, 0x6d97, 0x6d70, 0x6d7c, 0x6d5f, 0x6d82, 0x6d98, + 0x6d2f, 0x6d68, 0x6d8b, 0x6d7e, 0x6d80, 0x6d84, 0x6d16, 0x6d83, + 0x6d7b, 0x6d7d, 0x6d75, 0x6d90, 0x70dc, 0x70d3, 0x70d1, 0x70dd, + 0x70cb, 0x7f39, 0x70e2, 0x70d7, 0x70d2, 0x70de, 0x70e0, 0x70d4, + 0x70cd, 0x70c5, 0x70c6, 0x70c7, 0x70da, 0x70ce, 0x70e1, 0x7242, + 0x7278, 0x7277, 0x7276, 0x7300, 0x72fa, 0x72f4, 0x72fe, 0x72f6, + 0x72f3, 0x72fb, 0x7301, 0x73d3, 0x73d9, 0x73e5, 0x73d6, 0x73bc, + 0x73e7, 0x73e3, 0x73e9, 0x73dc, 0x73d2, 0x73db, 0x73d4, 0x73dd, + 0x73da, 0x73d7, 0x73d8, 0x73e8, 0x74de, 0x74df, + /* 0x31 */ + 0x74f4, 0x74f5, 0x7521, 0x755b, 0x755f, 0x75b0, 0x75c1, 0x75bb, + 0x75c4, 0x75c0, 0x75bf, 0x75b6, 0x75ba, 0x768a, 0x76c9, 0x771d, + 0x771b, 0x7710, 0x7713, 0x7712, 0x7723, 0x7711, 0x7715, 0x7719, + 0x771a, 0x7722, 0x7727, 0x7823, 0x782c, 0x7822, 0x7835, 0x782f, + 0x7828, 0x782e, 0x782b, 0x7821, 0x7829, 0x7833, 0x782a, 0x7831, + 0x7954, 0x795b, 0x794f, 0x795c, 0x7953, 0x7952, 0x7951, 0x79eb, + 0x79ec, 0x79e0, 0x79ee, 0x79ed, 0x79ea, 0x79dc, 0x79de, 0x79dd, + 0x7a86, 0x7a89, 0x7a85, 0x7a8b, 0x7a8c, 0x7a8a, 0x7a87, 0x7ad8, + 0x7b10, 0x7b04, 0x7b13, 0x7b05, 0x7b0f, 0x7b08, 0x7b0a, 0x7b0e, + 0x7b09, 0x7b12, 0x7c84, 0x7c91, 0x7c8a, 0x7c8c, 0x7c88, 0x7c8d, + 0x7c85, 0x7d1e, 0x7d1d, 0x7d11, 0x7d0e, 0x7d18, 0x7d16, 0x7d13, + 0x7d1f, 0x7d12, 0x7d0f, 0x7d0c, 0x7f5c, 0x7f61, + /* 0x32 */ + 0x7f5e, 0x7f60, 0x7f5d, 0x7f5b, 0x7f96, 0x7f92, 0x7fc3, 0x7fc2, + 0x7fc0, 0x8016, 0x803e, 0x8039, 0x80fa, 0x80f2, 0x80f9, 0x80f5, + 0x8101, 0x80fb, 0x8100, 0x8201, 0x822f, 0x8225, 0x8333, 0x832d, + 0x8344, 0x8319, 0x8351, 0x8325, 0x8356, 0x833f, 0x8341, 0x8326, + 0x831c, 0x8322, 0x8342, 0x834e, 0x831b, 0x832a, 0x8308, 0x833c, + 0x834d, 0x8316, 0x8324, 0x8320, 0x8337, 0x832f, 0x8329, 0x8347, + 0x8345, 0x834c, 0x8353, 0x831e, 0x832c, 0x834b, 0x8327, 0x8348, + 0x8653, 0x8652, 0x86a2, 0x86a8, 0x8696, 0x868d, 0x8691, 0x869e, + 0x8687, 0x8697, 0x8686, 0x868b, 0x869a, 0x8685, 0x86a5, 0x8699, + 0x86a1, 0x86a7, 0x8695, 0x8698, 0x868e, 0x869d, 0x8690, 0x8694, + 0x8843, 0x8844, 0x886d, 0x8875, 0x8876, 0x8872, 0x8880, 0x8871, + 0x887f, 0x886f, 0x8883, 0x887e, 0x8874, 0x887c, + /* 0x33 */ + 0x8a12, 0x8c47, 0x8c57, 0x8c7b, 0x8ca4, 0x8ca3, 0x8d76, 0x8d78, + 0x8db5, 0x8db7, 0x8db6, 0x8ed1, 0x8ed3, 0x8ffe, 0x8ff5, 0x9002, + 0x8fff, 0x8ffb, 0x9004, 0x8ffc, 0x8ff6, 0x90d6, 0x90e0, 0x90d9, + 0x90da, 0x90e3, 0x90df, 0x90e5, 0x90d8, 0x90db, 0x90d7, 0x90dc, + 0x90e4, 0x9150, 0x914e, 0x914f, 0x91d5, 0x91e2, 0x91da, 0x965c, + 0x965f, 0x96bc, 0x98e3, 0x9adf, 0x9b2f, 0x4e7f, 0x5070, 0x506a, + 0x5061, 0x505e, 0x5060, 0x5053, 0x504b, 0x505d, 0x5072, 0x5048, + 0x504d, 0x5041, 0x505b, 0x504a, 0x5062, 0x5015, 0x5045, 0x505f, + 0x5069, 0x506b, 0x5063, 0x5064, 0x5046, 0x5040, 0x506e, 0x5073, + 0x5057, 0x5051, 0x51d0, 0x526b, 0x526d, 0x526c, 0x526e, 0x52d6, + 0x52d3, 0x532d, 0x539c, 0x5575, 0x5576, 0x553c, 0x554d, 0x5550, + 0x5534, 0x552a, 0x5551, 0x5562, 0x5536, 0x5535, + /* 0x34 */ + 0x5530, 0x5552, 0x5545, 0x550c, 0x5532, 0x5565, 0x554e, 0x5539, + 0x5548, 0x552d, 0x553b, 0x5540, 0x554b, 0x570a, 0x5707, 0x57fb, + 0x5814, 0x57e2, 0x57f6, 0x57dc, 0x57f4, 0x5800, 0x57ed, 0x57fd, + 0x5808, 0x57f8, 0x580b, 0x57f3, 0x57cf, 0x5807, 0x57ee, 0x57e3, + 0x57f2, 0x57e5, 0x57ec, 0x57e1, 0x580e, 0x57fc, 0x5810, 0x57e7, + 0x5801, 0x580c, 0x57f1, 0x57e9, 0x57f0, 0x580d, 0x5804, 0x595c, + 0x5a60, 0x5a58, 0x5a55, 0x5a67, 0x5a5e, 0x5a38, 0x5a35, 0x5a6d, + 0x5a50, 0x5a5f, 0x5a65, 0x5a6c, 0x5a53, 0x5a64, 0x5a57, 0x5a43, + 0x5a5d, 0x5a52, 0x5a44, 0x5a5b, 0x5a48, 0x5a8e, 0x5a3e, 0x5a4d, + 0x5a39, 0x5a4c, 0x5a70, 0x5a69, 0x5a47, 0x5a51, 0x5a56, 0x5a42, + 0x5a5c, 0x5b72, 0x5b6e, 0x5bc1, 0x5bc0, 0x5c59, 0x5d1e, 0x5d0b, + 0x5d1d, 0x5d1a, 0x5d20, 0x5d0c, 0x5d28, 0x5d0d, + /* 0x35 */ + 0x5d26, 0x5d25, 0x5d0f, 0x5d30, 0x5d12, 0x5d23, 0x5d1f, 0x5d2e, + 0x5e3e, 0x5e34, 0x5eb1, 0x5eb4, 0x5eb9, 0x5eb2, 0x5eb3, 0x5f36, + 0x5f38, 0x5f9b, 0x5f96, 0x5f9f, 0x608a, 0x6090, 0x6086, 0x60be, + 0x60b0, 0x60ba, 0x60d3, 0x60d4, 0x60cf, 0x60e4, 0x60d9, 0x60dd, + 0x60c8, 0x60b1, 0x60db, 0x60b7, 0x60ca, 0x60bf, 0x60c3, 0x60cd, + 0x60c0, 0x6332, 0x6365, 0x638a, 0x6382, 0x637d, 0x63bd, 0x639e, + 0x63ad, 0x639d, 0x6397, 0x63ab, 0x638e, 0x636f, 0x6387, 0x6390, + 0x636e, 0x63af, 0x6375, 0x639c, 0x636d, 0x63ae, 0x637c, 0x63a4, + 0x633b, 0x639f, 0x6378, 0x6385, 0x6381, 0x6391, 0x638d, 0x6370, + 0x6553, 0x65cd, 0x6665, 0x6661, 0x665b, 0x6659, 0x665c, 0x6662, + 0x6718, 0x6879, 0x6887, 0x6890, 0x689c, 0x686d, 0x686e, 0x68ae, + 0x68ab, 0x6956, 0x686f, 0x68a3, 0x68ac, 0x68a9, + /* 0x36 */ + 0x6875, 0x6874, 0x68b2, 0x688f, 0x6877, 0x6892, 0x687c, 0x686b, + 0x6872, 0x68aa, 0x6880, 0x6871, 0x687e, 0x689b, 0x6896, 0x688b, + 0x68a0, 0x6889, 0x68a4, 0x6878, 0x687b, 0x6891, 0x688c, 0x688a, + 0x687d, 0x6b36, 0x6b33, 0x6b37, 0x6b38, 0x6b91, 0x6b8f, 0x6b8d, + 0x6b8e, 0x6b8c, 0x6c2a, 0x6dc0, 0x6dab, 0x6db4, 0x6db3, 0x6e74, + 0x6dac, 0x6de9, 0x6de2, 0x6db7, 0x6df6, 0x6dd4, 0x6e00, 0x6dc8, + 0x6de0, 0x6ddf, 0x6dd6, 0x6dbe, 0x6de5, 0x6ddc, 0x6ddd, 0x6ddb, + 0x6df4, 0x6dca, 0x6dbd, 0x6ded, 0x6df0, 0x6dba, 0x6dd5, 0x6dc2, + 0x6dcf, 0x6dc9, 0x6dd0, 0x6df2, 0x6dd3, 0x6dfd, 0x6dd7, 0x6dcd, + 0x6de3, 0x6dbb, 0x70fa, 0x710d, 0x70f7, 0x7117, 0x70f4, 0x710c, + 0x70f0, 0x7104, 0x70f3, 0x7110, 0x70fc, 0x70ff, 0x7106, 0x7113, + 0x7100, 0x70f8, 0x70f6, 0x710b, 0x7102, 0x710e, + /* 0x37 */ + 0x727e, 0x727b, 0x727c, 0x727f, 0x731d, 0x7317, 0x7307, 0x7311, + 0x7318, 0x730a, 0x7308, 0x72ff, 0x730f, 0x731e, 0x7388, 0x73f6, + 0x73f8, 0x73f5, 0x7404, 0x7401, 0x73fd, 0x7407, 0x7400, 0x73fa, + 0x73fc, 0x73ff, 0x740c, 0x740b, 0x73f4, 0x7408, 0x7564, 0x7563, + 0x75ce, 0x75d2, 0x75cf, 0x75cb, 0x75cc, 0x75d1, 0x75d0, 0x768f, + 0x7689, 0x76d3, 0x7739, 0x772f, 0x772d, 0x7731, 0x7732, 0x7734, + 0x7733, 0x773d, 0x7725, 0x773b, 0x7735, 0x7848, 0x7852, 0x7849, + 0x784d, 0x784a, 0x784c, 0x7826, 0x7845, 0x7850, 0x7964, 0x7967, + 0x7969, 0x796a, 0x7963, 0x796b, 0x7961, 0x79bb, 0x79fa, 0x79f8, + 0x79f6, 0x79f7, 0x7a8f, 0x7a94, 0x7a90, 0x7b35, 0x7b3b, 0x7b34, + 0x7b25, 0x7b30, 0x7b22, 0x7b24, 0x7b33, 0x7b18, 0x7b2a, 0x7b1d, + 0x7b31, 0x7b2b, 0x7b2d, 0x7b2f, 0x7b32, 0x7b38, + /* 0x38 */ + 0x7b1a, 0x7b23, 0x7c94, 0x7c98, 0x7c96, 0x7ca3, 0x7d35, 0x7d3d, + 0x7d38, 0x7d36, 0x7d3a, 0x7d45, 0x7d2c, 0x7d29, 0x7d41, 0x7d47, + 0x7d3e, 0x7d3f, 0x7d4a, 0x7d3b, 0x7d28, 0x7f63, 0x7f95, 0x7f9c, + 0x7f9d, 0x7f9b, 0x7fca, 0x7fcb, 0x7fcd, 0x7fd0, 0x7fd1, 0x7fc7, + 0x7fcf, 0x7fc9, 0x801f, 0x801e, 0x801b, 0x8047, 0x8043, 0x8048, + 0x8118, 0x8125, 0x8119, 0x811b, 0x812d, 0x811f, 0x812c, 0x811e, + 0x8121, 0x8115, 0x8127, 0x811d, 0x8122, 0x8211, 0x8238, 0x8233, + 0x823a, 0x8234, 0x8232, 0x8274, 0x8390, 0x83a3, 0x83a8, 0x838d, + 0x837a, 0x8373, 0x83a4, 0x8374, 0x838f, 0x8381, 0x8395, 0x8399, + 0x8375, 0x8394, 0x83a9, 0x837d, 0x8383, 0x838c, 0x839d, 0x839b, + 0x83aa, 0x838b, 0x837e, 0x83a5, 0x83af, 0x8388, 0x8397, 0x83b0, + 0x837f, 0x83a6, 0x8387, 0x83ae, 0x8376, 0x8659, + /* 0x39 */ + 0x8656, 0x86bf, 0x86b7, 0x86c2, 0x86c1, 0x86c5, 0x86ba, 0x86b0, + 0x86c8, 0x86b9, 0x86b3, 0x86b8, 0x86cc, 0x86b4, 0x86bb, 0x86bc, + 0x86c3, 0x86bd, 0x86be, 0x8852, 0x8889, 0x8895, 0x88a8, 0x88a2, + 0x88aa, 0x889a, 0x8891, 0x88a1, 0x889f, 0x8898, 0x88a7, 0x8899, + 0x889b, 0x8897, 0x88a4, 0x88ac, 0x888c, 0x8893, 0x888e, 0x8982, + 0x89d6, 0x89d9, 0x89d5, 0x8a30, 0x8a27, 0x8a2c, 0x8a1e, 0x8c39, + 0x8c3b, 0x8c5c, 0x8c5d, 0x8c7d, 0x8ca5, 0x8d7d, 0x8d7b, 0x8d79, + 0x8dbc, 0x8dc2, 0x8db9, 0x8dbf, 0x8dc1, 0x8ed8, 0x8ede, 0x8edd, + 0x8edc, 0x8ed7, 0x8ee0, 0x8ee1, 0x9024, 0x900b, 0x9011, 0x901c, + 0x900c, 0x9021, 0x90ef, 0x90ea, 0x90f0, 0x90f4, 0x90f2, 0x90f3, + 0x90d4, 0x90eb, 0x90ec, 0x90e9, 0x9156, 0x9158, 0x915a, 0x9153, + 0x9155, 0x91ec, 0x91f4, 0x91f1, 0x91f3, 0x91f8, + /* 0x3a */ + 0x91e4, 0x91f9, 0x91ea, 0x91eb, 0x91f7, 0x91e8, 0x91ee, 0x957a, + 0x9586, 0x9588, 0x967c, 0x966d, 0x966b, 0x9671, 0x966f, 0x96bf, + 0x976a, 0x9804, 0x98e5, 0x9997, 0x509b, 0x5095, 0x5094, 0x509e, + 0x508b, 0x50a3, 0x5083, 0x508c, 0x508e, 0x509d, 0x5068, 0x509c, + 0x5092, 0x5082, 0x5087, 0x515f, 0x51d4, 0x5312, 0x5311, 0x53a4, + 0x53a7, 0x5591, 0x55a8, 0x55a5, 0x55ad, 0x5577, 0x5645, 0x55a2, + 0x5593, 0x5588, 0x558f, 0x55b5, 0x5581, 0x55a3, 0x5592, 0x55a4, + 0x557d, 0x558c, 0x55a6, 0x557f, 0x5595, 0x55a1, 0x558e, 0x570c, + 0x5829, 0x5837, 0x5819, 0x581e, 0x5827, 0x5823, 0x5828, 0x57f5, + 0x5848, 0x5825, 0x581c, 0x581b, 0x5833, 0x583f, 0x5836, 0x582e, + 0x5839, 0x5838, 0x582d, 0x582c, 0x583b, 0x5961, 0x5aaf, 0x5a94, + 0x5a9f, 0x5a7a, 0x5aa2, 0x5a9e, 0x5a78, 0x5aa6, + /* 0x3b */ + 0x5a7c, 0x5aa5, 0x5aac, 0x5a95, 0x5aae, 0x5a37, 0x5a84, 0x5a8a, + 0x5a97, 0x5a83, 0x5a8b, 0x5aa9, 0x5a7b, 0x5a7d, 0x5a8c, 0x5a9c, + 0x5a8f, 0x5a93, 0x5a9d, 0x5bea, 0x5bcd, 0x5bcb, 0x5bd4, 0x5bd1, + 0x5bca, 0x5bce, 0x5c0c, 0x5c30, 0x5d37, 0x5d43, 0x5d6b, 0x5d41, + 0x5d4b, 0x5d3f, 0x5d35, 0x5d51, 0x5d4e, 0x5d55, 0x5d33, 0x5d3a, + 0x5d52, 0x5d3d, 0x5d31, 0x5d59, 0x5d42, 0x5d39, 0x5d49, 0x5d38, + 0x5d3c, 0x5d32, 0x5d36, 0x5d40, 0x5d45, 0x5e44, 0x5e41, 0x5f58, + 0x5fa6, 0x5fa5, 0x5fab, 0x60c9, 0x60b9, 0x60cc, 0x60e2, 0x60ce, + 0x60c4, 0x6114, 0x60f2, 0x610a, 0x6116, 0x6105, 0x60f5, 0x6113, + 0x60f8, 0x60fc, 0x60fe, 0x60c1, 0x6103, 0x6118, 0x611d, 0x6110, + 0x60ff, 0x6104, 0x610b, 0x624a, 0x6394, 0x63b1, 0x63b0, 0x63ce, + 0x63e5, 0x63e8, 0x63ef, 0x63c3, 0x649d, 0x63f3, + /* 0x3c */ + 0x63ca, 0x63e0, 0x63f6, 0x63d5, 0x63f2, 0x63f5, 0x6461, 0x63df, + 0x63be, 0x63dd, 0x63dc, 0x63c4, 0x63d8, 0x63d3, 0x63c2, 0x63c7, + 0x63cc, 0x63cb, 0x63c8, 0x63f0, 0x63d7, 0x63d9, 0x6532, 0x6567, + 0x656a, 0x6564, 0x655c, 0x6568, 0x6565, 0x658c, 0x659d, 0x659e, + 0x65ae, 0x65d0, 0x65d2, 0x667c, 0x666c, 0x667b, 0x6680, 0x6671, + 0x6679, 0x666a, 0x6672, 0x6701, 0x690c, 0x68d3, 0x6904, 0x68dc, + 0x692a, 0x68ec, 0x68ea, 0x68f1, 0x690f, 0x68d6, 0x68f7, 0x68eb, + 0x68e4, 0x68f6, 0x6913, 0x6910, 0x68f3, 0x68e1, 0x6907, 0x68cc, + 0x6908, 0x6970, 0x68b4, 0x6911, 0x68ef, 0x68c6, 0x6914, 0x68f8, + 0x68d0, 0x68fd, 0x68fc, 0x68e8, 0x690b, 0x690a, 0x6917, 0x68ce, + 0x68c8, 0x68dd, 0x68de, 0x68e6, 0x68f4, 0x68d1, 0x6906, 0x68d4, + 0x68e9, 0x6915, 0x6925, 0x68c7, 0x6b39, 0x6b3b, + /* 0x3d */ + 0x6b3f, 0x6b3c, 0x6b94, 0x6b97, 0x6b99, 0x6b95, 0x6bbd, 0x6bf0, + 0x6bf2, 0x6bf3, 0x6c30, 0x6dfc, 0x6e46, 0x6e47, 0x6e1f, 0x6e49, + 0x6e88, 0x6e3c, 0x6e3d, 0x6e45, 0x6e62, 0x6e2b, 0x6e3f, 0x6e41, + 0x6e5d, 0x6e73, 0x6e1c, 0x6e33, 0x6e4b, 0x6e40, 0x6e51, 0x6e3b, + 0x6e03, 0x6e2e, 0x6e5e, 0x6e68, 0x6e5c, 0x6e61, 0x6e31, 0x6e28, + 0x6e60, 0x6e71, 0x6e6b, 0x6e39, 0x6e22, 0x6e30, 0x6e53, 0x6e65, + 0x6e27, 0x6e78, 0x6e64, 0x6e77, 0x6e55, 0x6e79, 0x6e52, 0x6e66, + 0x6e35, 0x6e36, 0x6e5a, 0x7120, 0x711e, 0x712f, 0x70fb, 0x712e, + 0x7131, 0x7123, 0x7125, 0x7122, 0x7132, 0x711f, 0x7128, 0x713a, + 0x711b, 0x724b, 0x725a, 0x7288, 0x7289, 0x7286, 0x7285, 0x728b, + 0x7312, 0x730b, 0x7330, 0x7322, 0x7331, 0x7333, 0x7327, 0x7332, + 0x732d, 0x7326, 0x7323, 0x7335, 0x730c, 0x742e, + /* 0x3e */ + 0x742c, 0x7430, 0x742b, 0x7416, 0x741a, 0x7421, 0x742d, 0x7431, + 0x7424, 0x7423, 0x741d, 0x7429, 0x7420, 0x7432, 0x74fb, 0x752f, + 0x756f, 0x756c, 0x75e7, 0x75da, 0x75e1, 0x75e6, 0x75dd, 0x75df, + 0x75e4, 0x75d7, 0x7695, 0x7692, 0x76da, 0x7746, 0x7747, 0x7744, + 0x774d, 0x7745, 0x774a, 0x774e, 0x774b, 0x774c, 0x77de, 0x77ec, + 0x7860, 0x7864, 0x7865, 0x785c, 0x786d, 0x7871, 0x786a, 0x786e, + 0x7870, 0x7869, 0x7868, 0x785e, 0x7862, 0x7974, 0x7973, 0x7972, + 0x7970, 0x7a02, 0x7a0a, 0x7a03, 0x7a0c, 0x7a04, 0x7a99, 0x7ae6, + 0x7ae4, 0x7b4a, 0x7b47, 0x7b44, 0x7b48, 0x7b4c, 0x7b4e, 0x7b40, + 0x7b58, 0x7b45, 0x7ca2, 0x7c9e, 0x7ca8, 0x7ca1, 0x7d58, 0x7d6f, + 0x7d63, 0x7d53, 0x7d56, 0x7d67, 0x7d6a, 0x7d4f, 0x7d6d, 0x7d5c, + 0x7d6b, 0x7d52, 0x7d54, 0x7d69, 0x7d51, 0x7d5f, + /* 0x3f */ + 0x7d4e, 0x7f3e, 0x7f3f, 0x7f65, 0x7f66, 0x7fa2, 0x7fa0, 0x7fa1, + 0x7fd7, 0x8051, 0x804f, 0x8050, 0x80fe, 0x80d4, 0x8143, 0x814a, + 0x8152, 0x814f, 0x8147, 0x813d, 0x814d, 0x813a, 0x81e6, 0x81ee, + 0x81f7, 0x81f8, 0x81f9, 0x8204, 0x823c, 0x823d, 0x823f, 0x8275, + 0x833b, 0x83cf, 0x83f9, 0x8423, 0x83c0, 0x83e8, 0x8412, 0x83e7, + 0x83e4, 0x83fc, 0x83f6, 0x8410, 0x83c6, 0x83c8, 0x83eb, 0x83e3, + 0x83bf, 0x8401, 0x83dd, 0x83e5, 0x83d8, 0x83ff, 0x83e1, 0x83cb, + 0x83ce, 0x83d6, 0x83f5, 0x83c9, 0x8409, 0x840f, 0x83de, 0x8411, + 0x8406, 0x83c2, 0x83f3, 0x83d5, 0x83fa, 0x83c7, 0x83d1, 0x83ea, + 0x8413, 0x839a, 0x83c3, 0x83ec, 0x83ee, 0x83c4, 0x83fb, 0x83d7, + 0x83e2, 0x841b, 0x83db, 0x83fe, 0x86d8, 0x86e2, 0x86e6, 0x86d3, + 0x86e3, 0x86da, 0x86ea, 0x86dd, 0x86eb, 0x86dc, + /* 0x40 */ + 0x86ec, 0x86e9, 0x86d7, 0x86e8, 0x86d1, 0x8848, 0x8856, 0x8855, + 0x88ba, 0x88d7, 0x88b9, 0x88b8, 0x88c0, 0x88be, 0x88b6, 0x88bc, + 0x88b7, 0x88bd, 0x88b2, 0x8901, 0x88c9, 0x8995, 0x8998, 0x8997, + 0x89dd, 0x89da, 0x89db, 0x8a4e, 0x8a4d, 0x8a39, 0x8a59, 0x8a40, + 0x8a57, 0x8a58, 0x8a44, 0x8a45, 0x8a52, 0x8a48, 0x8a51, 0x8a4a, + 0x8a4c, 0x8a4f, 0x8c5f, 0x8c81, 0x8c80, 0x8cba, 0x8cbe, 0x8cb0, + 0x8cb9, 0x8cb5, 0x8d84, 0x8d80, 0x8d89, 0x8dd8, 0x8dd3, 0x8dcd, + 0x8dc7, 0x8dd6, 0x8ddc, 0x8dcf, 0x8dd5, 0x8dd9, 0x8dc8, 0x8dd7, + 0x8dc5, 0x8eef, 0x8ef7, 0x8efa, 0x8ef9, 0x8ee6, 0x8eee, 0x8ee5, + 0x8ef5, 0x8ee7, 0x8ee8, 0x8ef6, 0x8eeb, 0x8ef1, 0x8eec, 0x8ef4, + 0x8ee9, 0x902d, 0x9034, 0x902f, 0x9106, 0x912c, 0x9104, 0x90ff, + 0x90fc, 0x9108, 0x90f9, 0x90fb, 0x9101, 0x9100, + /* 0x41 */ + 0x9107, 0x9105, 0x9103, 0x9161, 0x9164, 0x915f, 0x9162, 0x9160, + 0x9201, 0x920a, 0x9225, 0x9203, 0x921a, 0x9226, 0x920f, 0x920c, + 0x9200, 0x9212, 0x91ff, 0x91fd, 0x9206, 0x9204, 0x9227, 0x9202, + 0x921c, 0x9224, 0x9219, 0x9217, 0x9205, 0x9216, 0x957b, 0x958d, + 0x958c, 0x9590, 0x9687, 0x967e, 0x9688, 0x9689, 0x9683, 0x9680, + 0x96c2, 0x96c8, 0x96c3, 0x96f1, 0x96f0, 0x976c, 0x9770, 0x976e, + 0x9807, 0x98a9, 0x98eb, 0x9ce6, 0x9ef9, 0x4e83, 0x4e84, 0x4eb6, + 0x50bd, 0x50bf, 0x50c6, 0x50ae, 0x50c4, 0x50ca, 0x50b4, 0x50c8, + 0x50c2, 0x50b0, 0x50c1, 0x50ba, 0x50b1, 0x50cb, 0x50c9, 0x50b6, + 0x50b8, 0x51d7, 0x527a, 0x5278, 0x527b, 0x527c, 0x55c3, 0x55db, + 0x55cc, 0x55d0, 0x55cb, 0x55ca, 0x55dd, 0x55c0, 0x55d4, 0x55c4, + 0x55e9, 0x55bf, 0x55d2, 0x558d, 0x55cf, 0x55d5, + /* 0x42 */ + 0x55e2, 0x55d6, 0x55c8, 0x55f2, 0x55cd, 0x55d9, 0x55c2, 0x5714, + 0x5853, 0x5868, 0x5864, 0x584f, 0x584d, 0x5849, 0x586f, 0x5855, + 0x584e, 0x585d, 0x5859, 0x5865, 0x585b, 0x583d, 0x5863, 0x5871, + 0x58fc, 0x5ac7, 0x5ac4, 0x5acb, 0x5aba, 0x5ab8, 0x5ab1, 0x5ab5, + 0x5ab0, 0x5abf, 0x5ac8, 0x5abb, 0x5ac6, 0x5ab7, 0x5ac0, 0x5aca, + 0x5ab4, 0x5ab6, 0x5acd, 0x5ab9, 0x5a90, 0x5bd6, 0x5bd8, 0x5bd9, + 0x5c1f, 0x5c33, 0x5d71, 0x5d63, 0x5d4a, 0x5d65, 0x5d72, 0x5d6c, + 0x5d5e, 0x5d68, 0x5d67, 0x5d62, 0x5df0, 0x5e4f, 0x5e4e, 0x5e4a, + 0x5e4d, 0x5e4b, 0x5ec5, 0x5ecc, 0x5ec6, 0x5ecb, 0x5ec7, 0x5f40, + 0x5faf, 0x5fad, 0x60f7, 0x6149, 0x614a, 0x612b, 0x6145, 0x6136, + 0x6132, 0x612e, 0x6146, 0x612f, 0x614f, 0x6129, 0x6140, 0x6220, + 0x9168, 0x6223, 0x6225, 0x6224, 0x63c5, 0x63f1, + /* 0x43 */ + 0x63eb, 0x6410, 0x6412, 0x6409, 0x6420, 0x6424, 0x6433, 0x6443, + 0x641f, 0x6415, 0x6418, 0x6439, 0x6437, 0x6422, 0x6423, 0x640c, + 0x6426, 0x6430, 0x6428, 0x6441, 0x6435, 0x642f, 0x640a, 0x641a, + 0x6440, 0x6425, 0x6427, 0x640b, 0x63e7, 0x641b, 0x642e, 0x6421, + 0x640e, 0x656f, 0x6592, 0x65d3, 0x6686, 0x668c, 0x6695, 0x6690, + 0x668b, 0x668a, 0x6699, 0x6694, 0x6678, 0x6720, 0x6966, 0x695f, + 0x6938, 0x694e, 0x6962, 0x6971, 0x693f, 0x6945, 0x696a, 0x6939, + 0x6942, 0x6957, 0x6959, 0x697a, 0x6948, 0x6949, 0x6935, 0x696c, + 0x6933, 0x693d, 0x6965, 0x68f0, 0x6978, 0x6934, 0x6969, 0x6940, + 0x696f, 0x6944, 0x6976, 0x6958, 0x6941, 0x6974, 0x694c, 0x693b, + 0x694b, 0x6937, 0x695c, 0x694f, 0x6951, 0x6932, 0x6952, 0x692f, + 0x697b, 0x693c, 0x6b46, 0x6b45, 0x6b43, 0x6b42, + /* 0x44 */ + 0x6b48, 0x6b41, 0x6b9b, 0x6bfb, 0x6bfc, 0x6bf9, 0x6bf7, 0x6bf8, + 0x6e9b, 0x6ed6, 0x6ec8, 0x6e8f, 0x6ec0, 0x6e9f, 0x6e93, 0x6e94, + 0x6ea0, 0x6eb1, 0x6eb9, 0x6ec6, 0x6ed2, 0x6ebd, 0x6ec1, 0x6e9e, + 0x6ec9, 0x6eb7, 0x6eb0, 0x6ecd, 0x6ea6, 0x6ecf, 0x6eb2, 0x6ebe, + 0x6ec3, 0x6edc, 0x6ed8, 0x6e99, 0x6e92, 0x6e8e, 0x6e8d, 0x6ea4, + 0x6ea1, 0x6ebf, 0x6eb3, 0x6ed0, 0x6eca, 0x6e97, 0x6eae, 0x6ea3, + 0x7147, 0x7154, 0x7152, 0x7163, 0x7160, 0x7141, 0x715d, 0x7162, + 0x7172, 0x7178, 0x716a, 0x7161, 0x7142, 0x7158, 0x7143, 0x714b, + 0x7170, 0x715f, 0x7150, 0x7153, 0x7144, 0x714d, 0x715a, 0x724f, + 0x728d, 0x728c, 0x7291, 0x7290, 0x728e, 0x733c, 0x7342, 0x733b, + 0x733a, 0x7340, 0x734a, 0x7349, 0x7444, 0x744a, 0x744b, 0x7452, + 0x7451, 0x7457, 0x7440, 0x744f, 0x7450, 0x744e, + /* 0x45 */ + 0x7442, 0x7446, 0x744d, 0x7454, 0x74e1, 0x74ff, 0x74fe, 0x74fd, + 0x751d, 0x7579, 0x7577, 0x6983, 0x75ef, 0x760f, 0x7603, 0x75f7, + 0x75fe, 0x75fc, 0x75f9, 0x75f8, 0x7610, 0x75fb, 0x75f6, 0x75ed, + 0x75f5, 0x75fd, 0x7699, 0x76b5, 0x76dd, 0x7755, 0x775f, 0x7760, + 0x7752, 0x7756, 0x775a, 0x7769, 0x7767, 0x7754, 0x7759, 0x776d, + 0x77e0, 0x7887, 0x789a, 0x7894, 0x788f, 0x7884, 0x7895, 0x7885, + 0x7886, 0x78a1, 0x7883, 0x7879, 0x7899, 0x7880, 0x7896, 0x787b, + 0x797c, 0x7982, 0x797d, 0x7979, 0x7a11, 0x7a18, 0x7a19, 0x7a12, + 0x7a17, 0x7a15, 0x7a22, 0x7a13, 0x7a1b, 0x7a10, 0x7aa3, 0x7aa2, + 0x7a9e, 0x7aeb, 0x7b66, 0x7b64, 0x7b6d, 0x7b74, 0x7b69, 0x7b72, + 0x7b65, 0x7b73, 0x7b71, 0x7b70, 0x7b61, 0x7b78, 0x7b76, 0x7b63, + 0x7cb2, 0x7cb4, 0x7caf, 0x7d88, 0x7d86, 0x7d80, + /* 0x46 */ + 0x7d8d, 0x7d7f, 0x7d85, 0x7d7a, 0x7d8e, 0x7d7b, 0x7d83, 0x7d7c, + 0x7d8c, 0x7d94, 0x7d84, 0x7d7d, 0x7d92, 0x7f6d, 0x7f6b, 0x7f67, + 0x7f68, 0x7f6c, 0x7fa6, 0x7fa5, 0x7fa7, 0x7fdb, 0x7fdc, 0x8021, + 0x8164, 0x8160, 0x8177, 0x815c, 0x8169, 0x815b, 0x8162, 0x8172, + 0x6721, 0x815e, 0x8176, 0x8167, 0x816f, 0x8144, 0x8161, 0x821d, + 0x8249, 0x8244, 0x8240, 0x8242, 0x8245, 0x84f1, 0x843f, 0x8456, + 0x8476, 0x8479, 0x848f, 0x848d, 0x8465, 0x8451, 0x8440, 0x8486, + 0x8467, 0x8430, 0x844d, 0x847d, 0x845a, 0x8459, 0x8474, 0x8473, + 0x845d, 0x8507, 0x845e, 0x8437, 0x843a, 0x8434, 0x847a, 0x8443, + 0x8478, 0x8432, 0x8445, 0x8429, 0x83d9, 0x844b, 0x842f, 0x8442, + 0x842d, 0x845f, 0x8470, 0x8439, 0x844e, 0x844c, 0x8452, 0x846f, + 0x84c5, 0x848e, 0x843b, 0x8447, 0x8436, 0x8433, + /* 0x47 */ + 0x8468, 0x847e, 0x8444, 0x842b, 0x8460, 0x8454, 0x846e, 0x8450, + 0x870b, 0x8704, 0x86f7, 0x870c, 0x86fa, 0x86d6, 0x86f5, 0x874d, + 0x86f8, 0x870e, 0x8709, 0x8701, 0x86f6, 0x870d, 0x8705, 0x88d6, + 0x88cb, 0x88cd, 0x88ce, 0x88de, 0x88db, 0x88da, 0x88cc, 0x88d0, + 0x8985, 0x899b, 0x89df, 0x89e5, 0x89e4, 0x89e1, 0x89e0, 0x89e2, + 0x89dc, 0x89e6, 0x8a76, 0x8a86, 0x8a7f, 0x8a61, 0x8a3f, 0x8a77, + 0x8a82, 0x8a84, 0x8a75, 0x8a83, 0x8a81, 0x8a74, 0x8a7a, 0x8c3c, + 0x8c4b, 0x8c4a, 0x8c65, 0x8c64, 0x8c66, 0x8c86, 0x8c84, 0x8c85, + 0x8ccc, 0x8d68, 0x8d69, 0x8d91, 0x8d8c, 0x8d8e, 0x8d8f, 0x8d8d, + 0x8d93, 0x8d94, 0x8d90, 0x8d92, 0x8df0, 0x8de0, 0x8dec, 0x8df1, + 0x8dee, 0x8dd0, 0x8de9, 0x8de3, 0x8de2, 0x8de7, 0x8df2, 0x8deb, + 0x8df4, 0x8f06, 0x8eff, 0x8f01, 0x8f00, 0x8f05, + /* 0x48 */ + 0x8f07, 0x8f08, 0x8f02, 0x8f0b, 0x9052, 0x903f, 0x9044, 0x9049, + 0x903d, 0x9110, 0x910d, 0x910f, 0x9111, 0x9116, 0x9114, 0x910b, + 0x910e, 0x916e, 0x916f, 0x9248, 0x9252, 0x9230, 0x923a, 0x9266, + 0x9233, 0x9265, 0x925e, 0x9283, 0x922e, 0x924a, 0x9246, 0x926d, + 0x926c, 0x924f, 0x9260, 0x9267, 0x926f, 0x9236, 0x9261, 0x9270, + 0x9231, 0x9254, 0x9263, 0x9250, 0x9272, 0x924e, 0x9253, 0x924c, + 0x9256, 0x9232, 0x959f, 0x959c, 0x959e, 0x959b, 0x9692, 0x9693, + 0x9691, 0x9697, 0x96ce, 0x96fa, 0x96fd, 0x96f8, 0x96f5, 0x9773, + 0x9777, 0x9778, 0x9772, 0x980f, 0x980d, 0x980e, 0x98ac, 0x98f6, + 0x98f9, 0x99af, 0x99b2, 0x99b0, 0x99b5, 0x9aad, 0x9aab, 0x9b5b, + 0x9cea, 0x9ced, 0x9ce7, 0x9e80, 0x9efd, 0x50e6, 0x50d4, 0x50d7, + 0x50e8, 0x50f3, 0x50db, 0x50ea, 0x50dd, 0x50e4, + /* 0x49 */ + 0x50d3, 0x50ec, 0x50f0, 0x50ef, 0x50e3, 0x50e0, 0x51d8, 0x5280, + 0x5281, 0x52e9, 0x52eb, 0x5330, 0x53ac, 0x5627, 0x5615, 0x560c, + 0x5612, 0x55fc, 0x560f, 0x561c, 0x5601, 0x5613, 0x5602, 0x55fa, + 0x561d, 0x5604, 0x55ff, 0x55f9, 0x5889, 0x587c, 0x5890, 0x5898, + 0x5886, 0x5881, 0x587f, 0x5874, 0x588b, 0x587a, 0x5887, 0x5891, + 0x588e, 0x5876, 0x5882, 0x5888, 0x587b, 0x5894, 0x588f, 0x58fe, + 0x596b, 0x5adc, 0x5aee, 0x5ae5, 0x5ad5, 0x5aea, 0x5ada, 0x5aed, + 0x5aeb, 0x5af3, 0x5ae2, 0x5ae0, 0x5adb, 0x5aec, 0x5ade, 0x5add, + 0x5ad9, 0x5ae8, 0x5adf, 0x5b77, 0x5be0, 0x5be3, 0x5c63, 0x5d82, + 0x5d80, 0x5d7d, 0x5d86, 0x5d7a, 0x5d81, 0x5d77, 0x5d8a, 0x5d89, + 0x5d88, 0x5d7e, 0x5d7c, 0x5d8d, 0x5d79, 0x5d7f, 0x5e58, 0x5e59, + 0x5e53, 0x5ed8, 0x5ed1, 0x5ed7, 0x5ece, 0x5edc, + /* 0x4a */ + 0x5ed5, 0x5ed9, 0x5ed2, 0x5ed4, 0x5f44, 0x5f43, 0x5f6f, 0x5fb6, + 0x612c, 0x6128, 0x6141, 0x615e, 0x6171, 0x6173, 0x6152, 0x6153, + 0x6172, 0x616c, 0x6180, 0x6174, 0x6154, 0x617a, 0x615b, 0x6165, + 0x613b, 0x616a, 0x6161, 0x6156, 0x6229, 0x6227, 0x622b, 0x642b, + 0x644d, 0x645b, 0x645d, 0x6474, 0x6476, 0x6472, 0x6473, 0x647d, + 0x6475, 0x6466, 0x64a6, 0x644e, 0x6482, 0x645e, 0x645c, 0x644b, + 0x6453, 0x6460, 0x6450, 0x647f, 0x643f, 0x646c, 0x646b, 0x6459, + 0x6465, 0x6477, 0x6573, 0x65a0, 0x66a1, 0x66a0, 0x669f, 0x6705, + 0x6704, 0x6722, 0x69b1, 0x69b6, 0x69c9, 0x69a0, 0x69ce, 0x6996, + 0x69b0, 0x69ac, 0x69bc, 0x6991, 0x6999, 0x698e, 0x69a7, 0x698d, + 0x69a9, 0x69be, 0x69af, 0x69bf, 0x69c4, 0x69bd, 0x69a4, 0x69d4, + 0x69b9, 0x69ca, 0x699a, 0x69cf, 0x69b3, 0x6993, + /* 0x4b */ + 0x69aa, 0x69a1, 0x699e, 0x69d9, 0x6997, 0x6990, 0x69c2, 0x69b5, + 0x69a5, 0x69c6, 0x6b4a, 0x6b4d, 0x6b4b, 0x6b9e, 0x6b9f, 0x6ba0, + 0x6bc3, 0x6bc4, 0x6bfe, 0x6ece, 0x6ef5, 0x6ef1, 0x6f03, 0x6f25, + 0x6ef8, 0x6f37, 0x6efb, 0x6f2e, 0x6f09, 0x6f4e, 0x6f19, 0x6f1a, + 0x6f27, 0x6f18, 0x6f3b, 0x6f12, 0x6eed, 0x6f0a, 0x6f36, 0x6f73, + 0x6ef9, 0x6eee, 0x6f2d, 0x6f40, 0x6f30, 0x6f3c, 0x6f35, 0x6eeb, + 0x6f07, 0x6f0e, 0x6f43, 0x6f05, 0x6efd, 0x6ef6, 0x6f39, 0x6f1c, + 0x6efc, 0x6f3a, 0x6f1f, 0x6f0d, 0x6f1e, 0x6f08, 0x6f21, 0x7187, + 0x7190, 0x7189, 0x7180, 0x7185, 0x7182, 0x718f, 0x717b, 0x7186, + 0x7181, 0x7197, 0x7244, 0x7253, 0x7297, 0x7295, 0x7293, 0x7343, + 0x734d, 0x7351, 0x734c, 0x7462, 0x7473, 0x7471, 0x7475, 0x7472, + 0x7467, 0x746e, 0x7500, 0x7502, 0x7503, 0x757d, + /* 0x4c */ + 0x7590, 0x7616, 0x7608, 0x760c, 0x7615, 0x7611, 0x760a, 0x7614, + 0x76b8, 0x7781, 0x777c, 0x7785, 0x7782, 0x776e, 0x7780, 0x776f, + 0x777e, 0x7783, 0x78b2, 0x78aa, 0x78b4, 0x78ad, 0x78a8, 0x787e, + 0x78ab, 0x789e, 0x78a5, 0x78a0, 0x78ac, 0x78a2, 0x78a4, 0x7998, + 0x798a, 0x798b, 0x7996, 0x7995, 0x7994, 0x7993, 0x7997, 0x7988, + 0x7992, 0x7990, 0x7a2b, 0x7a4a, 0x7a30, 0x7a2f, 0x7a28, 0x7a26, + 0x7aa8, 0x7aab, 0x7aac, 0x7aee, 0x7b88, 0x7b9c, 0x7b8a, 0x7b91, + 0x7b90, 0x7b96, 0x7b8d, 0x7b8c, 0x7b9b, 0x7b8e, 0x7b85, 0x7b98, + 0x5284, 0x7b99, 0x7ba4, 0x7b82, 0x7cbb, 0x7cbf, 0x7cbc, 0x7cba, + 0x7da7, 0x7db7, 0x7dc2, 0x7da3, 0x7daa, 0x7dc1, 0x7dc0, 0x7dc5, + 0x7d9d, 0x7dce, 0x7dc4, 0x7dc6, 0x7dcb, 0x7dcc, 0x7daf, 0x7db9, + 0x7d96, 0x7dbc, 0x7d9f, 0x7da6, 0x7dae, 0x7da9, + /* 0x4d */ + 0x7da1, 0x7dc9, 0x7f73, 0x7fe2, 0x7fe3, 0x7fe5, 0x7fde, 0x8024, + 0x805d, 0x805c, 0x8189, 0x8186, 0x8183, 0x8187, 0x818d, 0x818c, + 0x818b, 0x8215, 0x8497, 0x84a4, 0x84a1, 0x849f, 0x84ba, 0x84ce, + 0x84c2, 0x84ac, 0x84ae, 0x84ab, 0x84b9, 0x84b4, 0x84c1, 0x84cd, + 0x84aa, 0x849a, 0x84b1, 0x84d0, 0x849d, 0x84a7, 0x84bb, 0x84a2, + 0x8494, 0x84c7, 0x84cc, 0x849b, 0x84a9, 0x84af, 0x84a8, 0x84d6, + 0x8498, 0x84b6, 0x84cf, 0x84a0, 0x84d7, 0x84d4, 0x84d2, 0x84db, + 0x84b0, 0x8491, 0x8661, 0x8733, 0x8723, 0x8728, 0x876b, 0x8740, + 0x872e, 0x871e, 0x8721, 0x8719, 0x871b, 0x8743, 0x872c, 0x8741, + 0x873e, 0x8746, 0x8720, 0x8732, 0x872a, 0x872d, 0x873c, 0x8712, + 0x873a, 0x8731, 0x8735, 0x8742, 0x8726, 0x8727, 0x8738, 0x8724, + 0x871a, 0x8730, 0x8711, 0x88f7, 0x88e7, 0x88f1, + /* 0x4e */ + 0x88f2, 0x88fa, 0x88fe, 0x88ee, 0x88fc, 0x88f6, 0x88fb, 0x88f0, + 0x88ec, 0x88eb, 0x899d, 0x89a1, 0x899f, 0x899e, 0x89e9, 0x89eb, + 0x89e8, 0x8aab, 0x8a99, 0x8a8b, 0x8a92, 0x8a8f, 0x8a96, 0x8c3d, + 0x8c68, 0x8c69, 0x8cd5, 0x8ccf, 0x8cd7, 0x8d96, 0x8e09, 0x8e02, + 0x8dff, 0x8e0d, 0x8dfd, 0x8e0a, 0x8e03, 0x8e07, 0x8e06, 0x8e05, + 0x8dfe, 0x8e00, 0x8e04, 0x8f10, 0x8f11, 0x8f0e, 0x8f0d, 0x9123, + 0x911c, 0x9120, 0x9122, 0x911f, 0x911d, 0x911a, 0x9124, 0x9121, + 0x911b, 0x917a, 0x9172, 0x9179, 0x9173, 0x92a5, 0x92a4, 0x9276, + 0x929b, 0x927a, 0x92a0, 0x9294, 0x92aa, 0x928d, 0x92a6, 0x929a, + 0x92ab, 0x9279, 0x9297, 0x927f, 0x92a3, 0x92ee, 0x928e, 0x9282, + 0x9295, 0x92a2, 0x927d, 0x9288, 0x92a1, 0x928a, 0x9286, 0x928c, + 0x9299, 0x92a7, 0x927e, 0x9287, 0x92a9, 0x929d, + /* 0x4f */ + 0x928b, 0x922d, 0x969e, 0x96a1, 0x96ff, 0x9758, 0x977d, 0x977a, + 0x977e, 0x9783, 0x9780, 0x9782, 0x977b, 0x9784, 0x9781, 0x977f, + 0x97ce, 0x97cd, 0x9816, 0x98ad, 0x98ae, 0x9902, 0x9900, 0x9907, + 0x999d, 0x999c, 0x99c3, 0x99b9, 0x99bb, 0x99ba, 0x99c2, 0x99bd, + 0x99c7, 0x9ab1, 0x9ae3, 0x9ae7, 0x9b3e, 0x9b3f, 0x9b60, 0x9b61, + 0x9b5f, 0x9cf1, 0x9cf2, 0x9cf5, 0x9ea7, 0x50ff, 0x5103, 0x5130, + 0x50f8, 0x5106, 0x5107, 0x50f6, 0x50fe, 0x510b, 0x510c, 0x50fd, + 0x510a, 0x528b, 0x528c, 0x52f1, 0x52ef, 0x5648, 0x5642, 0x564c, + 0x5635, 0x5641, 0x564a, 0x5649, 0x5646, 0x5658, 0x565a, 0x5640, + 0x5633, 0x563d, 0x562c, 0x563e, 0x5638, 0x562a, 0x563a, 0x571a, + 0x58ab, 0x589d, 0x58b1, 0x58a0, 0x58a3, 0x58af, 0x58ac, 0x58a5, + 0x58a1, 0x58ff, 0x5aff, 0x5af4, 0x5afd, 0x5af7, + /* 0x50 */ + 0x5af6, 0x5b03, 0x5af8, 0x5b02, 0x5af9, 0x5b01, 0x5b07, 0x5b05, + 0x5b0f, 0x5c67, 0x5d99, 0x5d97, 0x5d9f, 0x5d92, 0x5da2, 0x5d93, + 0x5d95, 0x5da0, 0x5d9c, 0x5da1, 0x5d9a, 0x5d9e, 0x5e69, 0x5e5d, + 0x5e60, 0x5e5c, 0x7df3, 0x5edb, 0x5ede, 0x5ee1, 0x5f49, 0x5fb2, + 0x618b, 0x6183, 0x6179, 0x61b1, 0x61b0, 0x61a2, 0x6189, 0x619b, + 0x6193, 0x61af, 0x61ad, 0x619f, 0x6192, 0x61aa, 0x61a1, 0x618d, + 0x6166, 0x61b3, 0x622d, 0x646e, 0x6470, 0x6496, 0x64a0, 0x6485, + 0x6497, 0x649c, 0x648f, 0x648b, 0x648a, 0x648c, 0x64a3, 0x649f, + 0x6468, 0x64b1, 0x6498, 0x6576, 0x657a, 0x6579, 0x657b, 0x65b2, + 0x65b3, 0x66b5, 0x66b0, 0x66a9, 0x66b2, 0x66b7, 0x66aa, 0x66af, + 0x6a00, 0x6a06, 0x6a17, 0x69e5, 0x69f8, 0x6a15, 0x69f1, 0x69e4, + 0x6a20, 0x69ff, 0x69ec, 0x69e2, 0x6a1b, 0x6a1d, + /* 0x51 */ + 0x69fe, 0x6a27, 0x69f2, 0x69ee, 0x6a14, 0x69f7, 0x69e7, 0x6a40, + 0x6a08, 0x69e6, 0x69fb, 0x6a0d, 0x69fc, 0x69eb, 0x6a09, 0x6a04, + 0x6a18, 0x6a25, 0x6a0f, 0x69f6, 0x6a26, 0x6a07, 0x69f4, 0x6a16, + 0x6b51, 0x6ba5, 0x6ba3, 0x6ba2, 0x6ba6, 0x6c01, 0x6c00, 0x6bff, + 0x6c02, 0x6f41, 0x6f26, 0x6f7e, 0x6f87, 0x6fc6, 0x6f92, 0x6f8d, + 0x6f89, 0x6f8c, 0x6f62, 0x6f4f, 0x6f85, 0x6f5a, 0x6f96, 0x6f76, + 0x6f6c, 0x6f82, 0x6f55, 0x6f72, 0x6f52, 0x6f50, 0x6f57, 0x6f94, + 0x6f93, 0x6f5d, 0x6f00, 0x6f61, 0x6f6b, 0x6f7d, 0x6f67, 0x6f90, + 0x6f53, 0x6f8b, 0x6f69, 0x6f7f, 0x6f95, 0x6f63, 0x6f77, 0x6f6a, + 0x6f7b, 0x71b2, 0x71af, 0x719b, 0x71b0, 0x71a0, 0x719a, 0x71a9, + 0x71b5, 0x719d, 0x71a5, 0x719e, 0x71a4, 0x71a1, 0x71aa, 0x719c, + 0x71a7, 0x71b3, 0x7298, 0x729a, 0x7358, 0x7352, + /* 0x52 */ + 0x735e, 0x735f, 0x7360, 0x735d, 0x735b, 0x7361, 0x735a, 0x7359, + 0x7362, 0x7487, 0x7489, 0x748a, 0x7486, 0x7481, 0x747d, 0x7485, + 0x7488, 0x747c, 0x7479, 0x7508, 0x7507, 0x757e, 0x7625, 0x761e, + 0x7619, 0x761d, 0x761c, 0x7623, 0x761a, 0x7628, 0x761b, 0x769c, + 0x769d, 0x769e, 0x769b, 0x778d, 0x778f, 0x7789, 0x7788, 0x78cd, + 0x78bb, 0x78cf, 0x78cc, 0x78d1, 0x78ce, 0x78d4, 0x78c8, 0x78c3, + 0x78c4, 0x78c9, 0x799a, 0x79a1, 0x79a0, 0x799c, 0x79a2, 0x799b, + 0x6b76, 0x7a39, 0x7ab2, 0x7ab4, 0x7ab3, 0x7bb7, 0x7bcb, 0x7bbe, + 0x7bac, 0x7bce, 0x7baf, 0x7bb9, 0x7bca, 0x7bb5, 0x7cc5, 0x7cc8, + 0x7ccc, 0x7ccb, 0x7df7, 0x7ddb, 0x7dea, 0x7de7, 0x7dd7, 0x7de1, + 0x7e03, 0x7dfa, 0x7de6, 0x7df6, 0x7df1, 0x7df0, 0x7dee, 0x7ddf, + 0x7f76, 0x7fac, 0x7fb0, 0x7fad, 0x7fed, 0x7feb, + /* 0x53 */ + 0x7fea, 0x7fec, 0x7fe6, 0x7fe8, 0x8064, 0x8067, 0x81a3, 0x819f, + 0x819e, 0x8195, 0x81a2, 0x8199, 0x8197, 0x8216, 0x824f, 0x8253, + 0x8252, 0x8250, 0x824e, 0x8251, 0x8524, 0x853b, 0x850f, 0x8500, + 0x8529, 0x850e, 0x8509, 0x850d, 0x851f, 0x850a, 0x8527, 0x851c, + 0x84fb, 0x852b, 0x84fa, 0x8508, 0x850c, 0x84f4, 0x852a, 0x84f2, + 0x8515, 0x84f7, 0x84eb, 0x84f3, 0x84fc, 0x8512, 0x84ea, 0x84e9, + 0x8516, 0x84fe, 0x8528, 0x851d, 0x852e, 0x8502, 0x84fd, 0x851e, + 0x84f6, 0x8531, 0x8526, 0x84e7, 0x84e8, 0x84f0, 0x84ef, 0x84f9, + 0x8518, 0x8520, 0x8530, 0x850b, 0x8519, 0x852f, 0x8662, 0x8756, + 0x8763, 0x8764, 0x8777, 0x87e1, 0x8773, 0x8758, 0x8754, 0x875b, + 0x8752, 0x8761, 0x875a, 0x8751, 0x875e, 0x876d, 0x876a, 0x8750, + 0x874e, 0x875f, 0x875d, 0x876f, 0x876c, 0x877a, + /* 0x54 */ + 0x876e, 0x875c, 0x8765, 0x874f, 0x877b, 0x8775, 0x8762, 0x8767, + 0x8769, 0x885a, 0x8905, 0x890c, 0x8914, 0x890b, 0x8917, 0x8918, + 0x8919, 0x8906, 0x8916, 0x8911, 0x890e, 0x8909, 0x89a2, 0x89a4, + 0x89a3, 0x89ed, 0x89f0, 0x89ec, 0x8acf, 0x8ac6, 0x8ab8, 0x8ad3, + 0x8ad1, 0x8ad4, 0x8ad5, 0x8abb, 0x8ad7, 0x8abe, 0x8ac0, 0x8ac5, + 0x8ad8, 0x8ac3, 0x8aba, 0x8abd, 0x8ad9, 0x8c3e, 0x8c4d, 0x8c8f, + 0x8ce5, 0x8cdf, 0x8cd9, 0x8ce8, 0x8cda, 0x8cdd, 0x8ce7, 0x8da0, + 0x8d9c, 0x8da1, 0x8d9b, 0x8e20, 0x8e23, 0x8e25, 0x8e24, 0x8e2e, + 0x8e15, 0x8e1b, 0x8e16, 0x8e11, 0x8e19, 0x8e26, 0x8e27, 0x8e14, + 0x8e12, 0x8e18, 0x8e13, 0x8e1c, 0x8e17, 0x8e1a, 0x8f2c, 0x8f24, + 0x8f18, 0x8f1a, 0x8f20, 0x8f23, 0x8f16, 0x8f17, 0x9073, 0x9070, + 0x906f, 0x9067, 0x906b, 0x912f, 0x912b, 0x9129, + /* 0x55 */ + 0x912a, 0x9132, 0x9126, 0x912e, 0x9185, 0x9186, 0x918a, 0x9181, + 0x9182, 0x9184, 0x9180, 0x92d0, 0x92c3, 0x92c4, 0x92c0, 0x92d9, + 0x92b6, 0x92cf, 0x92f1, 0x92df, 0x92d8, 0x92e9, 0x92d7, 0x92dd, + 0x92cc, 0x92ef, 0x92c2, 0x92e8, 0x92ca, 0x92c8, 0x92ce, 0x92e6, + 0x92cd, 0x92d5, 0x92c9, 0x92e0, 0x92de, 0x92e7, 0x92d1, 0x92d3, + 0x92b5, 0x92e1, 0x9325, 0x92c6, 0x92b4, 0x957c, 0x95ac, 0x95ab, + 0x95ae, 0x95b0, 0x96a4, 0x96a2, 0x96d3, 0x9705, 0x9708, 0x9702, + 0x975a, 0x978a, 0x978e, 0x9788, 0x97d0, 0x97cf, 0x981e, 0x981d, + 0x9826, 0x9829, 0x9828, 0x9820, 0x981b, 0x9827, 0x98b2, 0x9908, + 0x98fa, 0x9911, 0x9914, 0x9916, 0x9917, 0x9915, 0x99dc, 0x99cd, + 0x99cf, 0x99d3, 0x99d4, 0x99ce, 0x99c9, 0x99d6, 0x99d8, 0x99cb, + 0x99d7, 0x99cc, 0x9ab3, 0x9aec, 0x9aeb, 0x9af3, + /* 0x56 */ + 0x9af2, 0x9af1, 0x9b46, 0x9b43, 0x9b67, 0x9b74, 0x9b71, 0x9b66, + 0x9b76, 0x9b75, 0x9b70, 0x9b68, 0x9b64, 0x9b6c, 0x9cfc, 0x9cfa, + 0x9cfd, 0x9cff, 0x9cf7, 0x9d07, 0x9d00, 0x9cf9, 0x9cfb, 0x9d08, + 0x9d05, 0x9d04, 0x9e83, 0x9ed3, 0x9f0f, 0x9f10, 0x511c, 0x5113, + 0x5117, 0x511a, 0x5111, 0x51de, 0x5334, 0x53e1, 0x5670, 0x5660, + 0x566e, 0x5673, 0x5666, 0x5663, 0x566d, 0x5672, 0x565e, 0x5677, + 0x571c, 0x571b, 0x58c8, 0x58bd, 0x58c9, 0x58bf, 0x58ba, 0x58c2, + 0x58bc, 0x58c6, 0x5b17, 0x5b19, 0x5b1b, 0x5b21, 0x5b14, 0x5b13, + 0x5b10, 0x5b16, 0x5b28, 0x5b1a, 0x5b20, 0x5b1e, 0x5bef, 0x5dac, + 0x5db1, 0x5da9, 0x5da7, 0x5db5, 0x5db0, 0x5dae, 0x5daa, 0x5da8, + 0x5db2, 0x5dad, 0x5daf, 0x5db4, 0x5e67, 0x5e68, 0x5e66, 0x5e6f, + 0x5ee9, 0x5ee7, 0x5ee6, 0x5ee8, 0x5ee5, 0x5f4b, + /* 0x57 */ + 0x5fbc, 0x5fbb, 0x619d, 0x61a8, 0x6196, 0x61c5, 0x61b4, 0x61c6, + 0x61c1, 0x61cc, 0x61ba, 0x61bf, 0x61b8, 0x618c, 0x64d7, 0x64d6, + 0x64d0, 0x64cf, 0x64c9, 0x64bd, 0x6489, 0x64c3, 0x64db, 0x64f3, + 0x64d9, 0x6533, 0x657f, 0x657c, 0x65a2, 0x66c8, 0x66be, 0x66c0, + 0x66ca, 0x66cb, 0x66cf, 0x66bd, 0x66bb, 0x66ba, 0x66cc, 0x6723, + 0x6a34, 0x6a66, 0x6a49, 0x6a67, 0x6a32, 0x6a68, 0x6a3e, 0x6a5d, + 0x6a6d, 0x6a76, 0x6a5b, 0x6a51, 0x6a28, 0x6a5a, 0x6a3b, 0x6a3f, + 0x6a41, 0x6a6a, 0x6a64, 0x6a50, 0x6a4f, 0x6a54, 0x6a6f, 0x6a69, + 0x6a60, 0x6a3c, 0x6a5e, 0x6a56, 0x6a55, 0x6a4d, 0x6a4e, 0x6a46, + 0x6b55, 0x6b54, 0x6b56, 0x6ba7, 0x6baa, 0x6bab, 0x6bc8, 0x6bc7, + 0x6c04, 0x6c03, 0x6c06, 0x6fad, 0x6fcb, 0x6fa3, 0x6fc7, 0x6fbc, + 0x6fce, 0x6fc8, 0x6f5e, 0x6fc4, 0x6fbd, 0x6f9e, + /* 0x58 */ + 0x6fca, 0x6fa8, 0x7004, 0x6fa5, 0x6fae, 0x6fba, 0x6fac, 0x6faa, + 0x6fcf, 0x6fbf, 0x6fb8, 0x6fa2, 0x6fc9, 0x6fab, 0x6fcd, 0x6faf, + 0x6fb2, 0x6fb0, 0x71c5, 0x71c2, 0x71bf, 0x71b8, 0x71d6, 0x71c0, + 0x71c1, 0x71cb, 0x71d4, 0x71ca, 0x71c7, 0x71cf, 0x71bd, 0x71d8, + 0x71bc, 0x71c6, 0x71da, 0x71db, 0x729d, 0x729e, 0x7369, 0x7366, + 0x7367, 0x736c, 0x7365, 0x736b, 0x736a, 0x747f, 0x749a, 0x74a0, + 0x7494, 0x7492, 0x7495, 0x74a1, 0x750b, 0x7580, 0x762f, 0x762d, + 0x7631, 0x763d, 0x7633, 0x763c, 0x7635, 0x7632, 0x7630, 0x76bb, + 0x76e6, 0x779a, 0x779d, 0x77a1, 0x779c, 0x779b, 0x77a2, 0x77a3, + 0x7795, 0x7799, 0x7797, 0x78dd, 0x78e9, 0x78e5, 0x78ea, 0x78de, + 0x78e3, 0x78db, 0x78e1, 0x78e2, 0x78ed, 0x78df, 0x78e0, 0x79a4, + 0x7a44, 0x7a48, 0x7a47, 0x7ab6, 0x7ab8, 0x7ab5, + /* 0x59 */ + 0x7ab1, 0x7ab7, 0x7bde, 0x7be3, 0x7be7, 0x7bdd, 0x7bd5, 0x7be5, + 0x7bda, 0x7be8, 0x7bf9, 0x7bd4, 0x7bea, 0x7be2, 0x7bdc, 0x7beb, + 0x7bd8, 0x7bdf, 0x7cd2, 0x7cd4, 0x7cd7, 0x7cd0, 0x7cd1, 0x7e12, + 0x7e21, 0x7e17, 0x7e0c, 0x7e1f, 0x7e20, 0x7e13, 0x7e0e, 0x7e1c, + 0x7e15, 0x7e1a, 0x7e22, 0x7e0b, 0x7e0f, 0x7e16, 0x7e0d, 0x7e14, + 0x7e25, 0x7e24, 0x7f43, 0x7f7b, 0x7f7c, 0x7f7a, 0x7fb1, 0x7fef, + 0x802a, 0x8029, 0x806c, 0x81b1, 0x81a6, 0x81ae, 0x81b9, 0x81b5, + 0x81ab, 0x81b0, 0x81ac, 0x81b4, 0x81b2, 0x81b7, 0x81a7, 0x81f2, + 0x8255, 0x8256, 0x8257, 0x8556, 0x8545, 0x856b, 0x854d, 0x8553, + 0x8561, 0x8558, 0x8540, 0x8546, 0x8564, 0x8541, 0x8562, 0x8544, + 0x8551, 0x8547, 0x8563, 0x853e, 0x855b, 0x8571, 0x854e, 0x856e, + 0x8575, 0x8555, 0x8567, 0x8560, 0x858c, 0x8566, + /* 0x5a */ + 0x855d, 0x8554, 0x8565, 0x856c, 0x8663, 0x8665, 0x8664, 0x87a4, + 0x879b, 0x878f, 0x8797, 0x8793, 0x8792, 0x8788, 0x8781, 0x8796, + 0x8798, 0x8779, 0x8787, 0x87a3, 0x8785, 0x8790, 0x8791, 0x879d, + 0x8784, 0x8794, 0x879c, 0x879a, 0x8789, 0x891e, 0x8926, 0x8930, + 0x892d, 0x892e, 0x8927, 0x8931, 0x8922, 0x8929, 0x8923, 0x892f, + 0x892c, 0x891f, 0x89f1, 0x8ae0, 0x8ae2, 0x8af2, 0x8af4, 0x8af5, + 0x8add, 0x8b14, 0x8ae4, 0x8adf, 0x8af0, 0x8ac8, 0x8ade, 0x8ae1, + 0x8ae8, 0x8aff, 0x8aef, 0x8afb, 0x8c91, 0x8c92, 0x8c90, 0x8cf5, + 0x8cee, 0x8cf1, 0x8cf0, 0x8cf3, 0x8d6c, 0x8d6e, 0x8da5, 0x8da7, + 0x8e33, 0x8e3e, 0x8e38, 0x8e40, 0x8e45, 0x8e36, 0x8e3c, 0x8e3d, + 0x8e41, 0x8e30, 0x8e3f, 0x8ebd, 0x8f36, 0x8f2e, 0x8f35, 0x8f32, + 0x8f39, 0x8f37, 0x8f34, 0x9076, 0x9079, 0x907b, + /* 0x5b */ + 0x9086, 0x90fa, 0x9133, 0x9135, 0x9136, 0x9193, 0x9190, 0x9191, + 0x918d, 0x918f, 0x9327, 0x931e, 0x9308, 0x931f, 0x9306, 0x930f, + 0x937a, 0x9338, 0x933c, 0x931b, 0x9323, 0x9312, 0x9301, 0x9346, + 0x932d, 0x930e, 0x930d, 0x92cb, 0x931d, 0x92fa, 0x9313, 0x92f9, + 0x92f7, 0x9334, 0x9302, 0x9324, 0x92ff, 0x9329, 0x9339, 0x9335, + 0x932a, 0x9314, 0x930c, 0x930b, 0x92fe, 0x9309, 0x9300, 0x92fb, + 0x9316, 0x95bc, 0x95cd, 0x95be, 0x95b9, 0x95ba, 0x95b6, 0x95bf, + 0x95b5, 0x95bd, 0x96a9, 0x96d4, 0x970b, 0x9712, 0x9710, 0x9799, + 0x9797, 0x9794, 0x97f0, 0x97f8, 0x9835, 0x982f, 0x9832, 0x9924, + 0x991f, 0x9927, 0x9929, 0x999e, 0x99ee, 0x99ec, 0x99e5, 0x99e4, + 0x99f0, 0x99e3, 0x99ea, 0x99e9, 0x99e7, 0x9ab9, 0x9abf, 0x9ab4, + 0x9abb, 0x9af6, 0x9afa, 0x9af9, 0x9af7, 0x9b33, + /* 0x5c */ + 0x9b80, 0x9b85, 0x9b87, 0x9b7c, 0x9b7e, 0x9b7b, 0x9b82, 0x9b93, + 0x9b92, 0x9b90, 0x9b7a, 0x9b95, 0x9b7d, 0x9b88, 0x9d25, 0x9d17, + 0x9d20, 0x9d1e, 0x9d14, 0x9d29, 0x9d1d, 0x9d18, 0x9d22, 0x9d10, + 0x9d19, 0x9d1f, 0x9e88, 0x9e86, 0x9e87, 0x9eae, 0x9ead, 0x9ed5, + 0x9ed6, 0x9efa, 0x9f12, 0x9f3d, 0x5126, 0x5125, 0x5122, 0x5124, + 0x5120, 0x5129, 0x52f4, 0x5693, 0x568c, 0x568d, 0x5686, 0x5684, + 0x5683, 0x567e, 0x5682, 0x567f, 0x5681, 0x58d6, 0x58d4, 0x58cf, + 0x58d2, 0x5b2d, 0x5b25, 0x5b32, 0x5b23, 0x5b2c, 0x5b27, 0x5b26, + 0x5b2f, 0x5b2e, 0x5b7b, 0x5bf1, 0x5bf2, 0x5db7, 0x5e6c, 0x5e6a, + 0x5fbe, 0x61c3, 0x61b5, 0x61bc, 0x61e7, 0x61e0, 0x61e5, 0x61e4, + 0x61e8, 0x61de, 0x64ef, 0x64e9, 0x64e3, 0x64eb, 0x64e4, 0x64e8, + 0x6581, 0x6580, 0x65b6, 0x65da, 0x66d2, 0x6a8d, + /* 0x5d */ + 0x6a96, 0x6a81, 0x6aa5, 0x6a89, 0x6a9f, 0x6a9b, 0x6aa1, 0x6a9e, + 0x6a87, 0x6a93, 0x6a8e, 0x6a95, 0x6a83, 0x6aa8, 0x6aa4, 0x6a91, + 0x6a7f, 0x6aa6, 0x6a9a, 0x6a85, 0x6a8c, 0x6a92, 0x6b5b, 0x6bad, + 0x6c09, 0x6fcc, 0x6fa9, 0x6ff4, 0x6fd4, 0x6fe3, 0x6fdc, 0x6fed, + 0x6fe7, 0x6fe6, 0x6fde, 0x6ff2, 0x6fdd, 0x6fe2, 0x6fe8, 0x71e1, + 0x71f1, 0x71e8, 0x71f2, 0x71e4, 0x71f0, 0x71e2, 0x7373, 0x736e, + 0x736f, 0x7497, 0x74b2, 0x74ab, 0x7490, 0x74aa, 0x74ad, 0x74b1, + 0x74a5, 0x74af, 0x7510, 0x7511, 0x7512, 0x750f, 0x7584, 0x7643, + 0x7648, 0x7649, 0x7647, 0x76a4, 0x76e9, 0x77b5, 0x77ab, 0x77b2, + 0x77b7, 0x77b6, 0x77b4, 0x77b1, 0x77a8, 0x77f0, 0x78f3, 0x78fd, + 0x7902, 0x78fb, 0x78fc, 0x78ff, 0x78f2, 0x7905, 0x78f9, 0x78fe, + 0x7904, 0x79ab, 0x79a8, 0x7a5c, 0x7a5b, 0x7a56, + /* 0x5e */ + 0x7a58, 0x7a54, 0x7a5a, 0x7abe, 0x7ac0, 0x7ac1, 0x7c05, 0x7c0f, + 0x7bf2, 0x7c00, 0x7bff, 0x7bfb, 0x7c0e, 0x7bf4, 0x7c0b, 0x7bf3, + 0x7c02, 0x7c09, 0x7c03, 0x7c01, 0x7bf8, 0x7bfd, 0x7c06, 0x7bf0, + 0x7bf1, 0x7c10, 0x7c0a, 0x7ce8, 0x7e2d, 0x7e3c, 0x7e42, 0x7e33, + 0x9848, 0x7e38, 0x7e2a, 0x7e49, 0x7e40, 0x7e47, 0x7e29, 0x7e4c, + 0x7e30, 0x7e3b, 0x7e36, 0x7e44, 0x7e3a, 0x7f45, 0x7f7f, 0x7f7e, + 0x7f7d, 0x7ff4, 0x7ff2, 0x802c, 0x81bb, 0x81c4, 0x81cc, 0x81ca, + 0x81c5, 0x81c7, 0x81bc, 0x81e9, 0x825b, 0x825a, 0x825c, 0x8583, + 0x8580, 0x858f, 0x85a7, 0x8595, 0x85a0, 0x858b, 0x85a3, 0x857b, + 0x85a4, 0x859a, 0x859e, 0x8577, 0x857c, 0x8589, 0x85a1, 0x857a, + 0x8578, 0x8557, 0x858e, 0x8596, 0x8586, 0x858d, 0x8599, 0x859d, + 0x8581, 0x85a2, 0x8582, 0x8588, 0x8585, 0x8579, + /* 0x5f */ + 0x8576, 0x8598, 0x8590, 0x859f, 0x8668, 0x87be, 0x87aa, 0x87ad, + 0x87c5, 0x87b0, 0x87ac, 0x87b9, 0x87b5, 0x87bc, 0x87ae, 0x87c9, + 0x87c3, 0x87c2, 0x87cc, 0x87b7, 0x87af, 0x87c4, 0x87ca, 0x87b4, + 0x87b6, 0x87bf, 0x87b8, 0x87bd, 0x87de, 0x87b2, 0x8935, 0x8933, + 0x893c, 0x893e, 0x8941, 0x8952, 0x8937, 0x8942, 0x89ad, 0x89af, + 0x89ae, 0x89f2, 0x89f3, 0x8b1e, 0x8b18, 0x8b16, 0x8b11, 0x8b05, + 0x8b0b, 0x8b22, 0x8b0f, 0x8b12, 0x8b15, 0x8b07, 0x8b0d, 0x8b08, + 0x8b06, 0x8b1c, 0x8b13, 0x8b1a, 0x8c4f, 0x8c70, 0x8c72, 0x8c71, + 0x8c6f, 0x8c95, 0x8c94, 0x8cf9, 0x8d6f, 0x8e4e, 0x8e4d, 0x8e53, + 0x8e50, 0x8e4c, 0x8e47, 0x8f43, 0x8f40, 0x9085, 0x907e, 0x9138, + 0x919a, 0x91a2, 0x919b, 0x9199, 0x919f, 0x91a1, 0x919d, 0x91a0, + 0x93a1, 0x9383, 0x93af, 0x9364, 0x9356, 0x9347, + /* 0x60 */ + 0x937c, 0x9358, 0x935c, 0x9376, 0x9349, 0x9350, 0x9351, 0x9360, + 0x936d, 0x938f, 0x934c, 0x936a, 0x9379, 0x9357, 0x9355, 0x9352, + 0x934f, 0x9371, 0x9377, 0x937b, 0x9361, 0x935e, 0x9363, 0x9367, + 0x934e, 0x9359, 0x95c7, 0x95c0, 0x95c9, 0x95c3, 0x95c5, 0x95b7, + 0x96ae, 0x96b0, 0x96ac, 0x9720, 0x971f, 0x9718, 0x971d, 0x9719, + 0x979a, 0x97a1, 0x979c, 0x979e, 0x979d, 0x97d5, 0x97d4, 0x97f1, + 0x9841, 0x9844, 0x984a, 0x9849, 0x9845, 0x9843, 0x9925, 0x992b, + 0x992c, 0x992a, 0x9933, 0x9932, 0x992f, 0x992d, 0x9931, 0x9930, + 0x9998, 0x99a3, 0x99a1, 0x9a02, 0x99fa, 0x99f4, 0x99f7, 0x99f9, + 0x99f8, 0x99f6, 0x99fb, 0x99fd, 0x99fe, 0x99fc, 0x9a03, 0x9abe, + 0x9afe, 0x9afd, 0x9b01, 0x9afc, 0x9b48, 0x9b9a, 0x9ba8, 0x9b9e, + 0x9b9b, 0x9ba6, 0x9ba1, 0x9ba5, 0x9ba4, 0x9b86, + /* 0x61 */ + 0x9ba2, 0x9ba0, 0x9baf, 0x9d33, 0x9d41, 0x9d67, 0x9d36, 0x9d2e, + 0x9d2f, 0x9d31, 0x9d38, 0x9d30, 0x9d45, 0x9d42, 0x9d43, 0x9d3e, + 0x9d37, 0x9d40, 0x9d3d, 0x7ff5, 0x9d2d, 0x9e8a, 0x9e89, 0x9e8d, + 0x9eb0, 0x9ec8, 0x9eda, 0x9efb, 0x9eff, 0x9f24, 0x9f23, 0x9f22, + 0x9f54, 0x9fa0, 0x5131, 0x512d, 0x512e, 0x5698, 0x569c, 0x5697, + 0x569a, 0x569d, 0x5699, 0x5970, 0x5b3c, 0x5c69, 0x5c6a, 0x5dc0, + 0x5e6d, 0x5e6e, 0x61d8, 0x61df, 0x61ed, 0x61ee, 0x61f1, 0x61ea, + 0x61f0, 0x61eb, 0x61d6, 0x61e9, 0x64ff, 0x6504, 0x64fd, 0x64f8, + 0x6501, 0x6503, 0x64fc, 0x6594, 0x65db, 0x66da, 0x66db, 0x66d8, + 0x6ac5, 0x6ab9, 0x6abd, 0x6ae1, 0x6ac6, 0x6aba, 0x6ab6, 0x6ab7, + 0x6ac7, 0x6ab4, 0x6aad, 0x6b5e, 0x6bc9, 0x6c0b, 0x7007, 0x700c, + 0x700d, 0x7001, 0x7005, 0x7014, 0x700e, 0x6fff, + /* 0x62 */ + 0x7000, 0x6ffb, 0x7026, 0x6ffc, 0x6ff7, 0x700a, 0x7201, 0x71ff, + 0x71f9, 0x7203, 0x71fd, 0x7376, 0x74b8, 0x74c0, 0x74b5, 0x74c1, + 0x74be, 0x74b6, 0x74bb, 0x74c2, 0x7514, 0x7513, 0x765c, 0x7664, + 0x7659, 0x7650, 0x7653, 0x7657, 0x765a, 0x76a6, 0x76bd, 0x76ec, + 0x77c2, 0x77ba, 0x790c, 0x7913, 0x7914, 0x7909, 0x7910, 0x7912, + 0x7911, 0x79ad, 0x79ac, 0x7a5f, 0x7c1c, 0x7c29, 0x7c19, 0x7c20, + 0x7c1f, 0x7c2d, 0x7c1d, 0x7c26, 0x7c28, 0x7c22, 0x7c25, 0x7c30, + 0x7e5c, 0x7e50, 0x7e56, 0x7e63, 0x7e58, 0x7e62, 0x7e5f, 0x7e51, + 0x7e60, 0x7e57, 0x7e53, 0x7fb5, 0x7fb3, 0x7ff7, 0x7ff8, 0x8075, + 0x81d1, 0x81d2, 0x81d0, 0x825f, 0x825e, 0x85b4, 0x85c6, 0x85c0, + 0x85c3, 0x85c2, 0x85b3, 0x85b5, 0x85bd, 0x85c7, 0x85c4, 0x85bf, + 0x85cb, 0x85ce, 0x85c8, 0x85c5, 0x85b1, 0x85b6, + /* 0x63 */ + 0x85d2, 0x8624, 0x85b8, 0x85b7, 0x85be, 0x8669, 0x87e7, 0x87e6, + 0x87e2, 0x87db, 0x87eb, 0x87ea, 0x87e5, 0x87df, 0x87f3, 0x87e4, + 0x87d4, 0x87dc, 0x87d3, 0x87ed, 0x87d8, 0x87e3, 0x87d7, 0x87d9, + 0x8801, 0x87f4, 0x87e8, 0x87dd, 0x8953, 0x894b, 0x894f, 0x894c, + 0x8946, 0x8950, 0x8951, 0x8949, 0x8b2a, 0x8b27, 0x8b23, 0x8b33, + 0x8b30, 0x8b35, 0x8b47, 0x8b2f, 0x8b3c, 0x8b3e, 0x8b31, 0x8b25, + 0x8b37, 0x8b26, 0x8b36, 0x8b2e, 0x8b24, 0x8b3b, 0x8b3d, 0x8b3a, + 0x8c42, 0x8c75, 0x8c99, 0x8c98, 0x8c97, 0x8cfe, 0x8d04, 0x8d02, + 0x8d00, 0x8e5c, 0x8e62, 0x8e60, 0x8e57, 0x8e56, 0x8e5e, 0x8e65, + 0x8e67, 0x8e5b, 0x8e5a, 0x8e61, 0x8e5d, 0x8e69, 0x8e54, 0x8f46, + 0x8f47, 0x8f48, 0x8f4b, 0x9128, 0x913a, 0x913b, 0x913e, 0x91a8, + 0x91a5, 0x91a7, 0x91af, 0x91aa, 0x93b5, 0x938c, + /* 0x64 */ + 0x9392, 0x93b7, 0x939b, 0x939d, 0x9389, 0x93a7, 0x938e, 0x93aa, + 0x939e, 0x93a6, 0x9395, 0x9388, 0x9399, 0x939f, 0x9380, 0x938d, + 0x93b1, 0x9391, 0x93b2, 0x93a4, 0x93a8, 0x93b4, 0x93a3, 0x95d2, + 0x95d3, 0x95d1, 0x96b3, 0x96d7, 0x96da, 0x5dc2, 0x96df, 0x96d8, + 0x96dd, 0x9723, 0x9722, 0x9725, 0x97ac, 0x97ae, 0x97a8, 0x97ab, + 0x97a4, 0x97aa, 0x97a2, 0x97a5, 0x97d7, 0x97d9, 0x97d6, 0x97d8, + 0x97fa, 0x9850, 0x9851, 0x9852, 0x98b8, 0x9941, 0x993c, 0x993a, + 0x9a0f, 0x9a0b, 0x9a09, 0x9a0d, 0x9a04, 0x9a11, 0x9a0a, 0x9a05, + 0x9a07, 0x9a06, 0x9ac0, 0x9adc, 0x9b08, 0x9b04, 0x9b05, 0x9b29, + 0x9b35, 0x9b4a, 0x9b4c, 0x9b4b, 0x9bc7, 0x9bc6, 0x9bc3, 0x9bbf, + 0x9bc1, 0x9bb5, 0x9bb8, 0x9bd3, 0x9bb6, 0x9bc4, 0x9bb9, 0x9bbd, + 0x9d5c, 0x9d53, 0x9d4f, 0x9d4a, 0x9d5b, 0x9d4b, + /* 0x65 */ + 0x9d59, 0x9d56, 0x9d4c, 0x9d57, 0x9d52, 0x9d54, 0x9d5f, 0x9d58, + 0x9d5a, 0x9e8e, 0x9e8c, 0x9edf, 0x9f01, 0x9f00, 0x9f16, 0x9f25, + 0x9f2b, 0x9f2a, 0x9f29, 0x9f28, 0x9f4c, 0x9f55, 0x5134, 0x5135, + 0x5296, 0x52f7, 0x53b4, 0x56ab, 0x56ad, 0x56a6, 0x56a7, 0x56aa, + 0x56ac, 0x58da, 0x58dd, 0x58db, 0x5912, 0x5b3d, 0x5b3e, 0x5b3f, + 0x5dc3, 0x5e70, 0x5fbf, 0x61fb, 0x6507, 0x6510, 0x650d, 0x6509, + 0x650c, 0x650e, 0x6584, 0x65de, 0x65dd, 0x66de, 0x6ae7, 0x6ae0, + 0x6acc, 0x6ad1, 0x6ad9, 0x6acb, 0x6adf, 0x6adc, 0x6ad0, 0x6aeb, + 0x6acf, 0x6acd, 0x6ade, 0x6b60, 0x6bb0, 0x6c0c, 0x7019, 0x7027, + 0x7020, 0x7016, 0x702b, 0x7021, 0x7022, 0x7023, 0x7029, 0x7017, + 0x7024, 0x701c, 0x720c, 0x720a, 0x7207, 0x7202, 0x7205, 0x72a5, + 0x72a6, 0x72a4, 0x72a3, 0x72a1, 0x74cb, 0x74c5, + /* 0x66 */ + 0x74b7, 0x74c3, 0x7516, 0x7660, 0x77c9, 0x77ca, 0x77c4, 0x77f1, + 0x791d, 0x791b, 0x7921, 0x791c, 0x7917, 0x791e, 0x79b0, 0x7a67, + 0x7a68, 0x7c33, 0x7c3c, 0x7c39, 0x7c2c, 0x7c3b, 0x7cec, 0x7cea, + 0x7e76, 0x7e75, 0x7e78, 0x7e70, 0x7e77, 0x7e6f, 0x7e7a, 0x7e72, + 0x7e74, 0x7e68, 0x7f4b, 0x7f4a, 0x7f83, 0x7f86, 0x7fb7, 0x7ffd, + 0x7ffe, 0x8078, 0x81d7, 0x81d5, 0x820b, 0x8264, 0x8261, 0x8263, + 0x85eb, 0x85f1, 0x85ed, 0x85d9, 0x85e1, 0x85e8, 0x85da, 0x85d7, + 0x85ec, 0x85f2, 0x85f8, 0x85d8, 0x85df, 0x85e3, 0x85dc, 0x85d1, + 0x85f0, 0x85e6, 0x85ef, 0x85de, 0x85e2, 0x8800, 0x87fa, 0x8803, + 0x87f6, 0x87f7, 0x8809, 0x880c, 0x880b, 0x8806, 0x87fc, 0x8808, + 0x87ff, 0x880a, 0x8802, 0x8962, 0x895a, 0x895b, 0x8957, 0x8961, + 0x895c, 0x8958, 0x895d, 0x8959, 0x8988, 0x89b7, + /* 0x67 */ + 0x89b6, 0x89f6, 0x8b50, 0x8b48, 0x8b4a, 0x8b40, 0x8b53, 0x8b56, + 0x8b54, 0x8b4b, 0x8b55, 0x8b51, 0x8b42, 0x8b52, 0x8b57, 0x8c43, + 0x8c77, 0x8c76, 0x8c9a, 0x8d06, 0x8d07, 0x8d09, 0x8dac, 0x8daa, + 0x8dad, 0x8dab, 0x8e6d, 0x8e78, 0x8e73, 0x8e6a, 0x8e6f, 0x8e7b, + 0x8ec2, 0x8f52, 0x8f51, 0x8f4f, 0x8f50, 0x8f53, 0x8fb4, 0x9140, + 0x913f, 0x91b0, 0x91ad, 0x93de, 0x93c7, 0x93cf, 0x93c2, 0x93da, + 0x93d0, 0x93f9, 0x93ec, 0x93cc, 0x93d9, 0x93a9, 0x93e6, 0x93ca, + 0x93d4, 0x93ee, 0x93e3, 0x93d5, 0x93c4, 0x93ce, 0x93c0, 0x93d2, + 0x93a5, 0x93e7, 0x957d, 0x95da, 0x95db, 0x96e1, 0x9729, 0x972b, + 0x972c, 0x9728, 0x9726, 0x97b3, 0x97b7, 0x97b6, 0x97dd, 0x97de, + 0x97df, 0x985c, 0x9859, 0x985d, 0x9857, 0x98bf, 0x98bd, 0x98bb, + 0x98be, 0x9948, 0x9947, 0x9943, 0x99a6, 0x99a7, + /* 0x68 */ + 0x9a1a, 0x9a15, 0x9a25, 0x9a1d, 0x9a24, 0x9a1b, 0x9a22, 0x9a20, + 0x9a27, 0x9a23, 0x9a1e, 0x9a1c, 0x9a14, 0x9ac2, 0x9b0b, 0x9b0a, + 0x9b0e, 0x9b0c, 0x9b37, 0x9bea, 0x9beb, 0x9be0, 0x9bde, 0x9be4, + 0x9be6, 0x9be2, 0x9bf0, 0x9bd4, 0x9bd7, 0x9bec, 0x9bdc, 0x9bd9, + 0x9be5, 0x9bd5, 0x9be1, 0x9bda, 0x9d77, 0x9d81, 0x9d8a, 0x9d84, + 0x9d88, 0x9d71, 0x9d80, 0x9d78, 0x9d86, 0x9d8b, 0x9d8c, 0x9d7d, + 0x9d6b, 0x9d74, 0x9d75, 0x9d70, 0x9d69, 0x9d85, 0x9d73, 0x9d7b, + 0x9d82, 0x9d6f, 0x9d79, 0x9d7f, 0x9d87, 0x9d68, 0x9e94, 0x9e91, + 0x9ec0, 0x9efc, 0x9f2d, 0x9f40, 0x9f41, 0x9f4d, 0x9f56, 0x9f57, + 0x9f58, 0x5337, 0x56b2, 0x56b5, 0x56b3, 0x58e3, 0x5b45, 0x5dc6, + 0x5dc7, 0x5eee, 0x5eef, 0x5fc0, 0x5fc1, 0x61f9, 0x6517, 0x6516, + 0x6515, 0x6513, 0x65df, 0x66e8, 0x66e3, 0x66e4, + /* 0x69 */ + 0x6af3, 0x6af0, 0x6aea, 0x6ae8, 0x6af9, 0x6af1, 0x6aee, 0x6aef, + 0x703c, 0x7035, 0x702f, 0x7037, 0x7034, 0x7031, 0x7042, 0x7038, + 0x703f, 0x703a, 0x7039, 0x702a, 0x7040, 0x703b, 0x7033, 0x7041, + 0x7213, 0x7214, 0x72a8, 0x737d, 0x737c, 0x74ba, 0x76ab, 0x76aa, + 0x76be, 0x76ed, 0x77cc, 0x77ce, 0x77cf, 0x77cd, 0x77f2, 0x7925, + 0x7923, 0x7927, 0x7928, 0x7924, 0x7929, 0x79b2, 0x7a6e, 0x7a6c, + 0x7a6d, 0x7af7, 0x7c49, 0x7c48, 0x7c4a, 0x7c47, 0x7c45, 0x7cee, + 0x7e7b, 0x7e7e, 0x7e81, 0x7e80, 0x7fba, 0x7fff, 0x8079, 0x81db, + 0x81d9, 0x8268, 0x8269, 0x8622, 0x85ff, 0x8601, 0x85fe, 0x861b, + 0x8600, 0x85f6, 0x8604, 0x8609, 0x8605, 0x860c, 0x85fd, 0x8819, + 0x8810, 0x8811, 0x8817, 0x8813, 0x8816, 0x8963, 0x8966, 0x89b9, + 0x89f7, 0x8b60, 0x8b6a, 0x8b5d, 0x8b68, 0x8b63, + /* 0x6a */ + 0x8b65, 0x8b67, 0x8b6d, 0x8dae, 0x8e86, 0x8e88, 0x8e84, 0x8f59, + 0x8f56, 0x8f57, 0x8f55, 0x8f58, 0x8f5a, 0x908d, 0x9143, 0x9141, + 0x91b7, 0x91b5, 0x91b2, 0x91b3, 0x940b, 0x9413, 0x93fb, 0x9420, + 0x940f, 0x9414, 0x93fe, 0x9415, 0x9410, 0x9428, 0x9419, 0x940d, + 0x93f5, 0x9400, 0x93f7, 0x9407, 0x940e, 0x9416, 0x9412, 0x93fa, + 0x9409, 0x93f8, 0x943c, 0x940a, 0x93ff, 0x93fc, 0x940c, 0x93f6, + 0x9411, 0x9406, 0x95de, 0x95e0, 0x95df, 0x972e, 0x972f, 0x97b9, + 0x97bb, 0x97fd, 0x97fe, 0x9860, 0x9862, 0x9863, 0x985f, 0x98c1, + 0x98c2, 0x9950, 0x994e, 0x9959, 0x994c, 0x994b, 0x9953, 0x9a32, + 0x9a34, 0x9a31, 0x9a2c, 0x9a2a, 0x9a36, 0x9a29, 0x9a2e, 0x9a38, + 0x9a2d, 0x9ac7, 0x9aca, 0x9ac6, 0x9b10, 0x9b12, 0x9b11, 0x9c0b, + 0x9c08, 0x9bf7, 0x9c05, 0x9c12, 0x9bf8, 0x9c40, + /* 0x6b */ + 0x9c07, 0x9c0e, 0x9c06, 0x9c17, 0x9c14, 0x9c09, 0x9d9f, 0x9d99, + 0x9da4, 0x9d9d, 0x9d92, 0x9d98, 0x9d90, 0x9d9b, 0x9da0, 0x9d94, + 0x9d9c, 0x9daa, 0x9d97, 0x9da1, 0x9d9a, 0x9da2, 0x9da8, 0x9d9e, + 0x9da3, 0x9dbf, 0x9da9, 0x9d96, 0x9da6, 0x9da7, 0x9e99, 0x9e9b, + 0x9e9a, 0x9ee5, 0x9ee4, 0x9ee7, 0x9ee6, 0x9f30, 0x9f2e, 0x9f5b, + 0x9f60, 0x9f5e, 0x9f5d, 0x9f59, 0x9f91, 0x513a, 0x5139, 0x5298, + 0x5297, 0x56c3, 0x56bd, 0x56be, 0x5b48, 0x5b47, 0x5dcb, 0x5dcf, + 0x5ef1, 0x61fd, 0x651b, 0x6b02, 0x6afc, 0x6b03, 0x6af8, 0x6b00, + 0x7043, 0x7044, 0x704a, 0x7048, 0x7049, 0x7045, 0x7046, 0x721d, + 0x721a, 0x7219, 0x737e, 0x7517, 0x766a, 0x77d0, 0x792d, 0x7931, + 0x792f, 0x7c54, 0x7c53, 0x7cf2, 0x7e8a, 0x7e87, 0x7e88, 0x7e8b, + 0x7e86, 0x7e8d, 0x7f4d, 0x7fbb, 0x8030, 0x81dd, + /* 0x6c */ + 0x8618, 0x862a, 0x8626, 0x861f, 0x8623, 0x861c, 0x8619, 0x8627, + 0x862e, 0x8621, 0x8620, 0x8629, 0x861e, 0x8625, 0x8829, 0x881d, + 0x881b, 0x8820, 0x8824, 0x881c, 0x882b, 0x884a, 0x896d, 0x8969, + 0x896e, 0x896b, 0x89fa, 0x8b79, 0x8b78, 0x8b45, 0x8b7a, 0x8b7b, + 0x8d10, 0x8d14, 0x8daf, 0x8e8e, 0x8e8c, 0x8f5e, 0x8f5b, 0x8f5d, + 0x9146, 0x9144, 0x9145, 0x91b9, 0x943f, 0x943b, 0x9436, 0x9429, + 0x943d, 0x9430, 0x9439, 0x942a, 0x9437, 0x942c, 0x9440, 0x9431, + 0x95e5, 0x95e4, 0x95e3, 0x9735, 0x973a, 0x97bf, 0x97e1, 0x9864, + 0x98c9, 0x98c6, 0x98c0, 0x9958, 0x9956, 0x9a39, 0x9a3d, 0x9a46, + 0x9a44, 0x9a42, 0x9a41, 0x9a3a, 0x9a3f, 0x9acd, 0x9b15, 0x9b17, + 0x9b18, 0x9b16, 0x9b3a, 0x9b52, 0x9c2b, 0x9c1d, 0x9c1c, 0x9c2c, + 0x9c23, 0x9c28, 0x9c29, 0x9c24, 0x9c21, 0x9db7, + /* 0x6d */ + 0x9db6, 0x9dbc, 0x9dc1, 0x9dc7, 0x9dca, 0x9dcf, 0x9dbe, 0x9dc5, + 0x9dc3, 0x9dbb, 0x9db5, 0x9dce, 0x9db9, 0x9dba, 0x9dac, 0x9dc8, + 0x9db1, 0x9dad, 0x9dcc, 0x9db3, 0x9dcd, 0x9db2, 0x9e7a, 0x9e9c, + 0x9eeb, 0x9eee, 0x9eed, 0x9f1b, 0x9f18, 0x9f1a, 0x9f31, 0x9f4e, + 0x9f65, 0x9f64, 0x9f92, 0x4eb9, 0x56c6, 0x56c5, 0x56cb, 0x5971, + 0x5b4b, 0x5b4c, 0x5dd5, 0x5dd1, 0x5ef2, 0x6521, 0x6520, 0x6526, + 0x6522, 0x6b0b, 0x6b08, 0x6b09, 0x6c0d, 0x7055, 0x7056, 0x7057, + 0x7052, 0x721e, 0x721f, 0x72a9, 0x737f, 0x74d8, 0x74d5, 0x74d9, + 0x74d7, 0x766d, 0x76ad, 0x7935, 0x79b4, 0x7a70, 0x7a71, 0x7c57, + 0x7c5c, 0x7c59, 0x7c5b, 0x7c5a, 0x7cf4, 0x7cf1, 0x7e91, 0x7f4f, + 0x7f87, 0x81de, 0x826b, 0x8634, 0x8635, 0x8633, 0x862c, 0x8632, + 0x8636, 0x882c, 0x8828, 0x8826, 0x882a, 0x8825, + /* 0x6e */ + 0x8971, 0x89bf, 0x89be, 0x89fb, 0x8b7e, 0x8b84, 0x8b82, 0x8b86, + 0x8b85, 0x8b7f, 0x8d15, 0x8e95, 0x8e94, 0x8e9a, 0x8e92, 0x8e90, + 0x8e96, 0x8e97, 0x8f60, 0x8f62, 0x9147, 0x944c, 0x9450, 0x944a, + 0x944b, 0x944f, 0x9447, 0x9445, 0x9448, 0x9449, 0x9446, 0x973f, + 0x97e3, 0x986a, 0x9869, 0x98cb, 0x9954, 0x995b, 0x9a4e, 0x9a53, + 0x9a54, 0x9a4c, 0x9a4f, 0x9a48, 0x9a4a, 0x9a49, 0x9a52, 0x9a50, + 0x9ad0, 0x9b19, 0x9b2b, 0x9b3b, 0x9b56, 0x9b55, 0x9c46, 0x9c48, + 0x9c3f, 0x9c44, 0x9c39, 0x9c33, 0x9c41, 0x9c3c, 0x9c37, 0x9c34, + 0x9c32, 0x9c3d, 0x9c36, 0x9ddb, 0x9dd2, 0x9dde, 0x9dda, 0x9dcb, + 0x9dd0, 0x9ddc, 0x9dd1, 0x9ddf, 0x9de9, 0x9dd9, 0x9dd8, 0x9dd6, + 0x9df5, 0x9dd5, 0x9ddd, 0x9eb6, 0x9ef0, 0x9f35, 0x9f33, 0x9f32, + 0x9f42, 0x9f6b, 0x9f95, 0x9fa2, 0x513d, 0x5299, + /* 0x6f */ + 0x58e8, 0x58e7, 0x5972, 0x5b4d, 0x5dd8, 0x882f, 0x5f4f, 0x6201, + 0x6203, 0x6204, 0x6529, 0x6525, 0x6596, 0x66eb, 0x6b11, 0x6b12, + 0x6b0f, 0x6bca, 0x705b, 0x705a, 0x7222, 0x7382, 0x7381, 0x7383, + 0x7670, 0x77d4, 0x7c67, 0x7c66, 0x7e95, 0x826c, 0x863a, 0x8640, + 0x8639, 0x863c, 0x8631, 0x863b, 0x863e, 0x8830, 0x8832, 0x882e, + 0x8833, 0x8976, 0x8974, 0x8973, 0x89fe, 0x8b8c, 0x8b8e, 0x8b8b, + 0x8b88, 0x8c45, 0x8d19, 0x8e98, 0x8f64, 0x8f63, 0x91bc, 0x9462, + 0x9455, 0x945d, 0x9457, 0x945e, 0x97c4, 0x97c5, 0x9800, 0x9a56, + 0x9a59, 0x9b1e, 0x9b1f, 0x9b20, 0x9c52, 0x9c58, 0x9c50, 0x9c4a, + 0x9c4d, 0x9c4b, 0x9c55, 0x9c59, 0x9c4c, 0x9c4e, 0x9dfb, 0x9df7, + 0x9def, 0x9de3, 0x9deb, 0x9df8, 0x9de4, 0x9df6, 0x9de1, 0x9dee, + 0x9de6, 0x9df2, 0x9df0, 0x9de2, 0x9dec, 0x9df4, + /* 0x70 */ + 0x9df3, 0x9de8, 0x9ded, 0x9ec2, 0x9ed0, 0x9ef2, 0x9ef3, 0x9f06, + 0x9f1c, 0x9f38, 0x9f37, 0x9f36, 0x9f43, 0x9f4f, 0x9f71, 0x9f70, + 0x9f6e, 0x9f6f, 0x56d3, 0x56cd, 0x5b4e, 0x5c6d, 0x652d, 0x66ed, + 0x66ee, 0x6b13, 0x705f, 0x7061, 0x705d, 0x7060, 0x7223, 0x74db, + 0x74e5, 0x77d5, 0x7938, 0x79b7, 0x79b6, 0x7c6a, 0x7e97, 0x7f89, + 0x826d, 0x8643, 0x8838, 0x8837, 0x8835, 0x884b, 0x8b94, 0x8b95, + 0x8e9e, 0x8e9f, 0x8ea0, 0x8e9d, 0x91be, 0x91bd, 0x91c2, 0x946b, + 0x9468, 0x9469, 0x96e5, 0x9746, 0x9743, 0x9747, 0x97c7, 0x97e5, + 0x9a5e, 0x9ad5, 0x9b59, 0x9c63, 0x9c67, 0x9c66, 0x9c62, 0x9c5e, + 0x9c60, 0x9e02, 0x9dfe, 0x9e07, 0x9e03, 0x9e06, 0x9e05, 0x9e00, + 0x9e01, 0x9e09, 0x9dff, 0x9dfd, 0x9e04, 0x9ea0, 0x9f1e, 0x9f46, + 0x9f74, 0x9f75, 0x9f76, 0x56d4, 0x652e, 0x65b8, + /* 0x71 */ + 0x6b18, 0x6b19, 0x6b17, 0x6b1a, 0x7062, 0x7226, 0x72aa, 0x77d8, + 0x77d9, 0x7939, 0x7c69, 0x7c6b, 0x7cf6, 0x7e9a, 0x7e98, 0x7e9b, + 0x7e99, 0x81e0, 0x81e1, 0x8646, 0x8647, 0x8648, 0x8979, 0x897a, + 0x897c, 0x897b, 0x89ff, 0x8b98, 0x8b99, 0x8ea5, 0x8ea4, 0x8ea3, + 0x946e, 0x946d, 0x946f, 0x9471, 0x9473, 0x9749, 0x9872, 0x995f, + 0x9c68, 0x9c6e, 0x9c6d, 0x9e0b, 0x9e0d, 0x9e10, 0x9e0f, 0x9e12, + 0x9e11, 0x9ea1, 0x9ef5, 0x9f09, 0x9f47, 0x9f78, 0x9f7b, 0x9f7a, + 0x9f79, 0x571e, 0x7066, 0x7c6f, 0x883c, 0x8db2, 0x8ea6, 0x91c3, + 0x9474, 0x9478, 0x9476, 0x9475, 0x9a60, 0x9b2e, 0x9c74, 0x9c73, + 0x9c71, 0x9c75, 0x9e14, 0x9e13, 0x9ef6, 0x9f0a, 0x9fa4, 0x7068, + 0x7065, 0x7cf7, 0x866a, 0x883e, 0x883d, 0x883f, 0x8b9e, 0x8c9c, + 0x8ea9, 0x8ec9, 0x974b, 0x9873, 0x9874, 0x98cc, + /* 0x72 */ + 0x9961, 0x99ab, 0x9a64, 0x9a66, 0x9a67, 0x9b24, 0x9e15, 0x9e17, + 0x9f48, 0x6207, 0x6b1e, 0x7227, 0x864c, 0x8ea8, 0x9482, 0x9480, + 0x9481, 0x9a69, 0x9a68, 0x9e19, 0x864b, 0x8b9f, 0x9483, 0x9c79, + 0x9eb7, 0x7675, 0x9a6b, 0x9c7a, 0x9e1d, 0x7069, 0x706a, 0x7229, + 0x9ea4, 0x9f7e, 0x9f49, 0x9f98, +}; + +static int +cns11643_2_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x21 && c1 <= 0x72)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + unsigned short wc = 0xfffd; + { + if (i < 7650) + wc = cns11643_2_2uni_page21[i]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + diff --git a/graf2d/win32gdk/gdk/src/iconv/cns11643_3.h b/graf2d/win32gdk/gdk/src/iconv/cns11643_3.h new file mode 100644 index 0000000000000..e2630131bbc1a --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cns11643_3.h @@ -0,0 +1,974 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CNS 11643-1992 plane 3 + */ + +static const unsigned short cns11643_3_2uni_page21[6148] = { + /* 0x21 */ + 0x1a28, 0x1a36, 0x1a3f, 0x1a85, 0x1a05, 0x1a04, 0x1d82, 0x1d96, + 0x1f38, 0x1f69, 0x1fb6, 0x1a2a, 0x1a87, 0x1a49, 0x1de2, 0x1a46, + 0x1a8f, 0x1abc, 0x1abe, 0x1d66, 0x1de3, 0x1e04, 0x1e9c, 0x1f44, + 0x2502, 0x250a, 0x2780, 0x29db, 0x2a7a, 0x2a7f, 0x2af4, 0x2b50, + 0x2b51, 0x2b61, 0x621d, 0x6d0b, 0x1a63, 0x1a62, 0x1aa3, 0x1d85, + 0x1ac5, 0x1acf, 0x1ace, 0x1acc, 0x1d84, 0x1d86, 0x8517, 0x00c5, + 0x1de4, 0x1e05, 0x1e9e, 0x1e9d, 0x1efd, 0x1f00, 0x1f3a, 0x0139, + 0x1f46, 0x1f5d, 0x1f86, 0x1fb7, 0x0155, 0x1fcc, 0x015b, 0x1fce, + 0x2321, 0x03a2, 0x2a00, 0x2b0c, 0x2e37, 0x2e38, 0x3134, 0x3135, + 0x31e0, 0x0a26, 0x3f8d, 0x1a97, 0x1ae0, 0x0032, 0x6ea9, 0x1ae7, + 0x0033, 0x1ae6, 0x0034, 0x02a2, 0x0031, 0x00b0, 0x22d8, 0x1d8b, + 0x1d8c, 0x1d99, 0x1de5, 0x8550, 0x1e0b, 0x00dc, + /* 0x22 */ + 0x021e, 0x1f04, 0x1f03, 0x1f07, 0x852a, 0x1f1e, 0x1f5f, 0x1f6d, + 0x1f89, 0x1fba, 0x1fd0, 0x0165, 0x1ff6, 0x1ff7, 0x1ff9, 0x0164, + 0x1ff4, 0x021d, 0x0226, 0x2324, 0x2504, 0x2518, 0x2532, 0x2530, + 0x2534, 0x028e, 0x2575, 0x034a, 0x2782, 0x27f9, 0x2814, 0x038b, + 0x03a6, 0x03a4, 0x03a5, 0x03a7, 0x042f, 0x0432, 0x2a81, 0x2a83, + 0x2b0d, 0x2b52, 0x04d4, 0x2bca, 0x2bc7, 0x2e39, 0x05c5, 0x2e4f, + 0x31e7, 0x332f, 0x377a, 0x3839, 0x08ba, 0x08b9, 0x3837, 0x3844, + 0x3845, 0x3f8c, 0x4192, 0x4276, 0x5c93, 0x5c92, 0x14b3, 0x15ba, + 0x1a21, 0x1a20, 0x1a22, 0x1a68, 0x1a89, 0x1a98, 0x1af9, 0x1aef, + 0x003b, 0x003c, 0x1af8, 0x1b06, 0x1b03, 0x1afc, 0x1aee, 0x1b16, + 0x0039, 0x1b28, 0x1b1c, 0x1b07, 0x1b1a, 0x1afa, 0x1b17, 0x1d4a, + 0x00b2, 0x1d72, 0x8515, 0x1db4, 0x1db3, 0x1db2, + /* 0x23 */ + 0x00c7, 0x1de8, 0x002b, 0x1e14, 0x1e0f, 0x1e15, 0x1e18, 0x1ea8, + 0x852c, 0x1f4b, 0x1f4f, 0x013b, 0x1f50, 0x0144, 0x1f8b, 0x0142, + 0x1fbe, 0x015c, 0x1fd2, 0x2016, 0x1fff, 0x0167, 0x2000, 0x0166, + 0x2005, 0x2013, 0x2015, 0x853b, 0x021f, 0x22e3, 0x2335, 0x2336, + 0x2331, 0x2332, 0x24ee, 0x2505, 0x1a54, 0x028f, 0x2536, 0x0290, + 0x02a8, 0x02a4, 0x257a, 0x02a3, 0x2586, 0x033d, 0x034c, 0x2786, + 0x2b53, 0x2818, 0x038c, 0x283d, 0x2878, 0x03a8, 0x03ad, 0x03af, + 0x7746, 0x2880, 0x0429, 0x2a08, 0x0436, 0x0471, 0x0470, 0x046f, + 0x2af5, 0x2b0e, 0x04a9, 0x04aa, 0x04fb, 0x2bd3, 0x2bda, 0x04fc, + 0x2bdb, 0x05ae, 0x2e0f, 0x2e5d, 0x2e5f, 0x2e67, 0x2e57, 0x6b50, + 0x06c3, 0x31eb, 0x31ea, 0x0730, 0x3337, 0x0741, 0x3332, 0x3336, + 0x3722, 0x37ce, 0x088c, 0x3858, 0x3851, 0x3877, + /* 0x24 */ + 0x383c, 0x08bb, 0x385a, 0x7c86, 0x3853, 0x3c6f, 0x3c72, 0x3c6e, + 0x8535, 0x09a1, 0x3c73, 0x3eb1, 0x3eb2, 0x0aa8, 0x3f8f, 0x0aaa, + 0x0aab, 0x0c96, 0x453c, 0x0dc2, 0x4c8d, 0x4c8e, 0x1093, 0x4e7b, + 0x1094, 0x5971, 0x5bb9, 0x5c96, 0x5c9a, 0x15bb, 0x1a24, 0x1a71, + 0x851b, 0x1a9c, 0x1b45, 0x1b4a, 0x1b39, 0x1b37, 0x0043, 0x1b32, + 0x1b42, 0x0042, 0x1b44, 0x1b4b, 0x0044, 0x1b40, 0x1b35, 0x1b31, + 0x1d51, 0x850e, 0x1d50, 0x1d4e, 0x00b3, 0x00b7, 0x1d9d, 0x00c8, + 0x1db5, 0x1db8, 0x1dec, 0x1e23, 0x1e27, 0x1e26, 0x1e1f, 0x1e2b, + 0x1e20, 0x1eb4, 0x1eb3, 0x0118, 0x1f25, 0x1f3b, 0x1f74, 0x0147, + 0x0146, 0x0145, 0x016b, 0x0169, 0x204d, 0x0172, 0x0171, 0x203a, + 0x016c, 0x016f, 0x2044, 0x204c, 0x2023, 0x201a, 0x2032, 0x204b, + 0x2021, 0x0173, 0x2034, 0x2049, 0x2050, 0x2022, + /* 0x25 */ + 0x203f, 0x2051, 0x205a, 0x202f, 0x0176, 0x22e9, 0x22f2, 0x22f3, + 0x22ef, 0x22ed, 0x22ec, 0x22e6, 0x2348, 0x0227, 0x2344, 0x233f, + 0x233c, 0x2353, 0x2356, 0x0230, 0x235f, 0x2343, 0x2358, 0x2357, + 0x0229, 0x022a, 0x022f, 0x2346, 0x022c, 0x233d, 0x022d, 0x2342, + 0x2354, 0x2355, 0x24f1, 0x24f2, 0x24f0, 0x250b, 0x6aa6, 0x22f1, + 0x253d, 0x0293, 0x2594, 0x258c, 0x02ad, 0x259c, 0x02ac, 0x02ab, + 0x259f, 0x02a9, 0x259b, 0x02ae, 0x2589, 0x259a, 0x02aa, 0x3188, + 0x034e, 0x278d, 0x0350, 0x27fe, 0x27ff, 0x27fd, 0x282b, 0x03b2, + 0x2884, 0x288e, 0x289c, 0x03b5, 0x03b6, 0x2885, 0x29f5, 0x2a09, + 0x0439, 0x043b, 0x2a0b, 0x0472, 0x2a92, 0x2a90, 0x2b03, 0x04ac, + 0x2b1e, 0x2b63, 0x0508, 0x2be7, 0x2bfe, 0x2be6, 0x2bdc, 0x2bce, + 0x0503, 0x2bfc, 0x2bdf, 0x2bec, 0x2bf6, 0x79d7, + /* 0x26 */ + 0x2bf2, 0x2bf0, 0x2bf9, 0x050b, 0x2e13, 0x05af, 0x85b2, 0x2e3b, + 0x2e3c, 0x2e82, 0x05ce, 0x05cb, 0x05cc, 0x2e78, 0x2e8b, 0x05cd, + 0x2e9e, 0x2ea5, 0x2e9b, 0x2e9c, 0x2e99, 0x2e8d, 0x2e85, 0x2e9d, + 0x2e75, 0x0680, 0x06af, 0x06d3, 0x31f6, 0x06d5, 0x06d4, 0x06d7, + 0x32f5, 0x335b, 0x0742, 0x3354, 0x3352, 0x0744, 0x3358, 0x3344, + 0x334a, 0x3361, 0x08c6, 0x387f, 0x3891, 0x389e, 0x08c0, 0x386e, + 0x387c, 0x389f, 0x3875, 0x08be, 0x3856, 0x38a2, 0x3879, 0x08ca, + 0x38a1, 0x08c4, 0x38aa, 0x38a0, 0x08c2, 0x3c79, 0x3c77, 0x3c7e, + 0x09a4, 0x3c75, 0x3c7b, 0x3e64, 0x0a29, 0x3ebb, 0x3ebc, 0x3ec7, + 0x3eb9, 0x3ebe, 0x3eb6, 0x0a60, 0x0a5e, 0x3f98, 0x0aad, 0x0aae, + 0x0aac, 0x0b57, 0x4193, 0x4280, 0x0bdd, 0x4283, 0x42c0, 0x42c1, + 0x0c0e, 0x0c97, 0x43f4, 0x43f5, 0x0d27, 0x46cc, + /* 0x27 */ + 0x46cd, 0x48fa, 0x4c9f, 0x4c91, 0x4c97, 0x4c94, 0x1095, 0x4e86, + 0x4e8c, 0x868f, 0x4e95, 0x1098, 0x526c, 0x119d, 0x5bb5, 0x5bbe, + 0x5bc7, 0x148a, 0x5bc1, 0x5ca9, 0x5ca4, 0x14b5, 0x14b6, 0x14b7, + 0x5ca8, 0x6227, 0x6226, 0x622b, 0x6233, 0x6234, 0x6229, 0x1a3d, + 0x0028, 0x1a9d, 0x1b93, 0x1b8a, 0x004d, 0x0049, 0x1b6d, 0x1b8e, + 0x1ba0, 0x1ba2, 0x1ba1, 0x1b9f, 0x1ba3, 0x6f09, 0x1b72, 0x0051, + 0x1b8c, 0x1d56, 0x850f, 0x8511, 0x1d90, 0x00cb, 0x00ca, 0x00cc, + 0x1ded, 0x1dfe, 0x1e2f, 0x71ec, 0x1e3c, 0x1e34, 0x1e39, 0x1eb9, + 0x1eb5, 0x1ebf, 0x1f55, 0x013d, 0x1f76, 0x1f7a, 0x1f93, 0x0148, + 0x1fc1, 0x1fc2, 0x1fd5, 0x2085, 0x0178, 0x205f, 0x2093, 0x2089, + 0x2079, 0x6afe, 0x208f, 0x2069, 0x206d, 0x017a, 0x2094, 0x206a, + 0x208a, 0x0177, 0x22fd, 0x22fb, 0x22f8, 0x0221, + /* 0x28 */ + 0x22fc, 0x22f6, 0x2365, 0x2381, 0x2363, 0x2367, 0x0231, 0x236e, + 0x2378, 0x237f, 0x0233, 0x0234, 0x24f3, 0x254b, 0x254c, 0x02c1, + 0x02b0, 0x02b4, 0x25ad, 0x02b8, 0x25c4, 0x02bc, 0x25c2, 0x25b0, + 0x02bf, 0x02b5, 0x02b1, 0x02bd, 0x25bf, 0x02bb, 0x25c9, 0x25b8, + 0x25ac, 0x02b3, 0x02b6, 0x02ba, 0x25b7, 0x25d7, 0x02b7, 0x2760, + 0x0340, 0x2796, 0x279e, 0x2794, 0x279f, 0x279d, 0x0352, 0x2800, + 0x2819, 0x0390, 0x0391, 0x2849, 0x284a, 0x03be, 0x28bb, 0x28c1, + 0x03c0, 0x03c1, 0x03b9, 0x28b9, 0x289e, 0x28b4, 0x28ba, 0x29f6, + 0x2a13, 0x2a12, 0x2a77, 0x0479, 0x2a98, 0x047b, 0x2a99, 0x2a9d, + 0x2af8, 0x04a0, 0x2af9, 0x0029, 0x2b06, 0x2b21, 0x04ae, 0x2b25, + 0x2b55, 0x04cd, 0x04cb, 0x04d9, 0x2b84, 0x2b83, 0x2c30, 0x2c07, + 0x050c, 0x2c36, 0x0501, 0x0505, 0x0502, 0x2be9, + /* 0x29 */ + 0x2c3d, 0x2c08, 0x0513, 0x0511, 0x2eba, 0x2eb2, 0x05e4, 0x2eb7, + 0x2ee4, 0x2ea7, 0x05da, 0x05d5, 0x05d3, 0x2ed5, 0x2ee1, 0x2edd, + 0x2ea6, 0x2ec1, 0x2ec5, 0x2ec0, 0x2edf, 0x2ee0, 0x2ede, 0x05d6, + 0x3189, 0x06b4, 0x31a6, 0x31ba, 0x06d9, 0x31ff, 0x06d8, 0x3217, + 0x3218, 0x3201, 0x31fe, 0x0733, 0x330c, 0x0748, 0x336b, 0x3396, + 0x3382, 0x338a, 0x0747, 0x33a3, 0x074b, 0x33a2, 0x338f, 0x074a, + 0x33f9, 0x3380, 0x3726, 0x3727, 0x3768, 0x3769, 0x085a, 0x3781, + 0x37b4, 0x37d1, 0x088e, 0x08b4, 0x381c, 0x08cd, 0x08cc, 0x08cf, + 0x08cb, 0x08ce, 0x3897, 0x386c, 0x38df, 0x08d2, 0x38ea, 0x08d1, + 0x38e4, 0x38d8, 0x38b2, 0x38ce, 0x38c8, 0x09a6, 0x3c8b, 0x3c88, + 0x3c90, 0x3c8f, 0x09aa, 0x3c87, 0x3c89, 0x3c8d, 0x3c81, 0x09a8, + 0x3c8c, 0x0a13, 0x0a1a, 0x3e40, 0x0a1d, 0x0a1e, + /* 0x2a */ + 0x3e65, 0x3e66, 0x3e68, 0x0a65, 0x0a66, 0x3ecd, 0x3ed3, 0x3edb, + 0x0a64, 0x3ecf, 0x3fa7, 0x3fa3, 0x3f9e, 0x0ab0, 0x3faf, 0x0ab3, + 0x0ab5, 0x3faa, 0x3f9c, 0x0b19, 0x4142, 0x4144, 0x413b, 0x4141, + 0x783f, 0x419b, 0x419e, 0x0b75, 0x45c4, 0x45c3, 0x45c6, 0x0d2b, + 0x0d2c, 0x45c7, 0x0d2d, 0x45ca, 0x802e, 0x0dc3, 0x46cf, 0x4876, + 0x4874, 0x48ff, 0x48fc, 0x00ba, 0x0f50, 0x4b59, 0x4ca8, 0x0fd3, + 0x0fd0, 0x4cb0, 0x0fdc, 0x4cb3, 0x0fd2, 0x4ca4, 0x4cb6, 0x4ca7, + 0x4cac, 0x0fdb, 0x4ca6, 0x1f67, 0x4e0e, 0x4ec4, 0x4f3e, 0x4e9c, + 0x10a5, 0x109f, 0x109a, 0x109c, 0x10a2, 0x4eaa, 0x109b, 0x4ec9, + 0x10a3, 0x109d, 0x4ea6, 0x4eb2, 0x1188, 0x121a, 0x148d, 0x5bcc, + 0x5bd9, 0x5bca, 0x5bd8, 0x5bcf, 0x5cb7, 0x14b8, 0x5cad, 0x5cb9, + 0x6237, 0x15c3, 0x6241, 0x623e, 0x62b6, 0x6351, + /* 0x2b */ + 0x6363, 0x1a57, 0x1a79, 0x1ab2, 0x1ab0, 0x1aaf, 0x1ab1, 0x1bd2, + 0x1bd5, 0x005d, 0x1bbe, 0x1bb8, 0x1bb0, 0x1bb1, 0x1bc8, 0x005a, + 0x0057, 0x1bc6, 0x1bcc, 0x1be5, 0x1be3, 0x1bb4, 0x1d6a, 0x00b8, + 0x1d9f, 0x00c2, 0x1dc1, 0x00cf, 0x1dc2, 0x1dc3, 0x1e45, 0x1e48, + 0x00e7, 0x00e9, 0x1e4f, 0x1052, 0x00e8, 0x1ec5, 0x1eca, 0x1ec4, + 0x1f27, 0x1f58, 0x1f7d, 0x014a, 0x1fdd, 0x1fdc, 0x1fda, 0x1fd9, + 0x20b9, 0x0180, 0x20d0, 0x20b4, 0x20ca, 0x0187, 0x20a3, 0x20da, + 0x20a4, 0x0184, 0x20b2, 0x209e, 0x209f, 0x20b5, 0x0182, 0x0181, + 0x20cd, 0x0183, 0x20cc, 0x0222, 0x2300, 0x23ac, 0x2391, 0x238e, + 0x238d, 0x2392, 0x23a1, 0x2390, 0x23a6, 0x23a8, 0x023b, 0x239c, + 0x2396, 0x23a7, 0x023a, 0x0238, 0x0239, 0x0236, 0x24f5, 0x0285, + 0x2509, 0x2508, 0x0854, 0x2552, 0x029a, 0x02c4, + /* 0x2c */ + 0x25df, 0x02c5, 0x25eb, 0x25ef, 0x25f0, 0x25d5, 0x260d, 0x2604, + 0x25f9, 0x2602, 0x25f8, 0x25e2, 0x25d9, 0x25e7, 0x276a, 0x0354, + 0x0355, 0x27ab, 0x0356, 0x281b, 0x282f, 0x0396, 0x323c, 0x0395, + 0x0394, 0x03c4, 0x28d1, 0x28dc, 0x28e6, 0x28e1, 0x28cd, 0x857a, + 0x28e2, 0x28dd, 0x28e5, 0x29fb, 0x29fa, 0x2a1e, 0x0444, 0x2aa1, + 0x047d, 0x047e, 0x2afc, 0x2afb, 0x2b2f, 0x04b2, 0x04b6, 0x2b66, + 0x8599, 0x04dc, 0x04df, 0x2c5c, 0x0528, 0x2c4e, 0x2c51, 0x0519, + 0x0510, 0x2c23, 0x2c31, 0x2c7c, 0x2c52, 0x052c, 0x2c60, 0x2c4a, + 0x2c61, 0x051b, 0x2e18, 0x05c2, 0x05ef, 0x05e3, 0x05e5, 0x05ea, + 0x05e6, 0x05ee, 0x2f1f, 0x2f17, 0x2eea, 0x2f21, 0x2f04, 0x2f05, + 0x05e8, 0x3131, 0x3144, 0x3140, 0x0685, 0x3142, 0x31be, 0x06e0, + 0x3229, 0x321b, 0x06dd, 0x3223, 0x322c, 0x321a, + /* 0x2d */ + 0x3230, 0x323b, 0x321e, 0x3237, 0x3238, 0x06e1, 0x330e, 0x0751, + 0x0755, 0x33e8, 0x33d6, 0x0752, 0x33c7, 0x33bc, 0x3452, 0x33bf, + 0x33d5, 0x33fe, 0x4f63, 0x33fb, 0x85df, 0x33b1, 0x3401, 0x3405, + 0x3400, 0x33d7, 0x0c9e, 0x372a, 0x376b, 0x0852, 0x085e, 0x0860, + 0x085f, 0x37e1, 0x0892, 0x08d6, 0x3923, 0x38ff, 0x3914, 0x3905, + 0x3913, 0x3906, 0x3921, 0x08de, 0x3915, 0x38af, 0x38f4, 0x3902, + 0x3945, 0x85fe, 0x3926, 0x08d9, 0x3944, 0x08dd, 0x3924, 0x3ca5, + 0x09ac, 0x3ca3, 0x09b0, 0x3ca2, 0x3cbb, 0x3ca0, 0x3caa, 0x09af, + 0x09ae, 0x3ca8, 0x3cb6, 0x3cb2, 0x3ca7, 0x09ad, 0x09ab, 0x3cb9, + 0x3e2e, 0x0a16, 0x3e3c, 0x0a30, 0x3e6d, 0x0a33, 0x0a31, 0x3ee7, + 0x3eed, 0x0a6e, 0x3eec, 0x3ee5, 0x3ee2, 0x0ab1, 0x3fc4, 0x3fbd, + 0x3fcf, 0x3fc9, 0x3fc1, 0x3fd0, 0x0ab7, 0x3fce, + /* 0x2e */ + 0x40ed, 0x40eb, 0x0b1a, 0x40ef, 0x4149, 0x4150, 0x4146, 0x414a, + 0x0b59, 0x414d, 0x41a6, 0x0b7a, 0x0b78, 0x0b7b, 0x41a8, 0x0bde, + 0x0bec, 0x42c7, 0x42ff, 0x0c1e, 0x42fd, 0x43e6, 0x440a, 0x0c9b, + 0x4404, 0x440b, 0x4407, 0x0c9d, 0x4415, 0x4408, 0x0cfd, 0x45d3, + 0x45d4, 0x45d0, 0x45d7, 0x467c, 0x0d94, 0x0d93, 0x467d, 0x4683, + 0x4682, 0x0dc6, 0x46d4, 0x46d5, 0x46d3, 0x46d0, 0x46d2, 0x46fe, + 0x46fc, 0x4877, 0x487c, 0x487b, 0x0eb8, 0x866a, 0x0eb7, 0x0eb9, + 0x0f53, 0x7f33, 0x0f52, 0x0f51, 0x4b8f, 0x4cd3, 0x0fe3, 0x4ccb, + 0x4cd2, 0x0fe2, 0x4d09, 0x4ce2, 0x4cdf, 0x4cc6, 0x1063, 0x4e24, + 0x4ef7, 0x4ed8, 0x4edd, 0x10aa, 0x10a6, 0x4ef8, 0x4efc, 0x10a8, + 0x10a9, 0x4ee9, 0x10ab, 0x4eee, 0x10ac, 0x4ed0, 0x4f0e, 0x4ee2, + 0x4f0b, 0x4efd, 0x1d79, 0x5276, 0x119e, 0x5278, + /* 0x2f */ + 0x119f, 0x11a0, 0x5275, 0x527d, 0x120f, 0x5442, 0x5466, 0x121c, + 0x558c, 0x5605, 0x12ae, 0x5606, 0x12b0, 0x589f, 0x13d4, 0x5bf1, + 0x5be7, 0x5be9, 0x5bef, 0x5cc2, 0x5cbc, 0x14bb, 0x5cc6, 0x5cc0, + 0x14c1, 0x14c2, 0x5ccd, 0x5cc9, 0x14be, 0x5cc4, 0x14e5, 0x6181, + 0x15c6, 0x68ec, 0x1c32, 0x1bf9, 0x1c1d, 0x1bff, 0x1c04, 0x1bf0, + 0x1c03, 0x122e, 0x1c02, 0x1bfc, 0x1bf2, 0x1c24, 0x1c08, 0x1c36, + 0x1c2e, 0x0065, 0x1c10, 0x1c38, 0x1c39, 0x1bfd, 0x1c56, 0x1bfb, + 0x1da3, 0x1da6, 0x1da1, 0x00d1, 0x00d0, 0x1dc7, 0x1dc9, 0x1e60, + 0x1e64, 0x1e59, 0x1e65, 0x1e67, 0x1e57, 0x1e63, 0x00ee, 0x1e53, + 0x00ef, 0x1ecf, 0x011e, 0x1ece, 0x1ed0, 0x1ed1, 0x1ecc, 0x014b, + 0x014d, 0x0156, 0x210d, 0x20f4, 0x0192, 0x2113, 0x20ef, 0x20f5, + 0x20f9, 0x2102, 0x2100, 0x0193, 0x0190, 0x2118, + /* 0x30 */ + 0x20f0, 0x20f6, 0x8541, 0x0197, 0x2119, 0x0223, 0x2305, 0x23c9, + 0x023f, 0x23b7, 0x23cd, 0x0243, 0x0242, 0x0244, 0x23be, 0x23bb, + 0x0245, 0x23db, 0x23c8, 0x23c4, 0x23c5, 0x23d1, 0x23ca, 0x23c0, + 0x02d9, 0x02de, 0x2621, 0x262a, 0x02cf, 0x261d, 0x02cd, 0x260b, + 0x02dd, 0x02ce, 0x02d3, 0x02d6, 0x2622, 0x02dc, 0x02d1, 0x2624, + 0x02d0, 0x2614, 0x2631, 0x02d5, 0x262f, 0x261a, 0x2612, 0x02d4, + 0x02db, 0x2626, 0x762e, 0x0343, 0x27bc, 0x27bb, 0x27b7, 0x2805, + 0x2806, 0x2852, 0x2853, 0x03cd, 0x03d1, 0x28fa, 0x28eb, 0x03ca, + 0x28f3, 0x28f5, 0x28e9, 0x28ef, 0x03d4, 0x2a2a, 0x2a30, 0x2a2e, + 0x2a2c, 0x2a2f, 0x2aaf, 0x2aa9, 0x0486, 0x2afd, 0x2b32, 0x2b8e, + 0x2b93, 0x2b8f, 0x2c4f, 0x2c99, 0x0533, 0x2c7e, 0x0537, 0x2c74, + 0x2c4b, 0x2c73, 0x2c75, 0x052a, 0x051f, 0x2c56, + /* 0x31 */ + 0x2ca9, 0x2c8b, 0x2ca6, 0x0539, 0x2c93, 0x2cae, 0x2c9e, 0x2ca7, + 0x2e45, 0x05f2, 0x05f8, 0x2f2e, 0x05f7, 0x2f52, 0x2f30, 0x2f5b, + 0x05f4, 0x2f19, 0x2f1b, 0x05f1, 0x2f31, 0x2f5d, 0x2f37, 0x2f35, + 0x2f53, 0x05f5, 0x2f5c, 0x2f3f, 0x314b, 0x0687, 0x0f69, 0x318b, + 0x06b6, 0x319a, 0x3250, 0x3246, 0x324e, 0x3240, 0x06e9, 0x324b, + 0x3248, 0x06eb, 0x3260, 0x3244, 0x324d, 0x0734, 0x3437, 0x3424, + 0x0762, 0x075c, 0x341b, 0x3436, 0x0760, 0x342c, 0x3419, 0x3456, + 0x3447, 0x343e, 0x341e, 0x85e1, 0x3415, 0x3422, 0x3427, 0x3459, + 0x3458, 0x3455, 0x3430, 0x3423, 0x372e, 0x372b, 0x3730, 0x376c, + 0x0861, 0x378b, 0x087f, 0x37e9, 0x37ea, 0x37e5, 0x396b, 0x08e5, + 0x08e6, 0x3973, 0x3957, 0x08e9, 0x08f3, 0x395d, 0x3956, 0x398f, + 0x395b, 0x391c, 0x399a, 0x399b, 0x3999, 0x08ee, + /* 0x32 */ + 0x3981, 0x3971, 0x08ed, 0x08ec, 0x3972, 0x395c, 0x3996, 0x3cc4, + 0x3cdb, 0x3ccc, 0x3cd0, 0x3ce3, 0x3cdf, 0x09b3, 0x3cd6, 0x3cee, + 0x3cd5, 0x09b5, 0x0a27, 0x0a35, 0x0a36, 0x3e7a, 0x0a71, 0x3ef5, + 0x3f02, 0x0ab8, 0x0ac2, 0x3fe2, 0x3fec, 0x3fd5, 0x3ff9, 0x3fdf, + 0x3fe6, 0x0ac8, 0x0ac0, 0x0ac1, 0x0ac4, 0x3fe4, 0x3fe1, 0x40f3, + 0x0b1f, 0x0b1c, 0x0b1d, 0x0b4d, 0x4156, 0x4155, 0x4158, 0x4157, + 0x415e, 0x41c3, 0x0b87, 0x0b82, 0x41b4, 0x0b7d, 0x41b1, 0x0bdf, + 0x0c00, 0x42cb, 0x42cc, 0x432a, 0x0c20, 0x4316, 0x430f, 0x0c22, + 0x0c24, 0x433f, 0x432b, 0x430e, 0x4324, 0x0c21, 0x4321, 0x4318, + 0x43dd, 0x0ca4, 0x0ca5, 0x4424, 0x4436, 0x0d01, 0x4558, 0x4559, + 0x0d03, 0x4562, 0x45da, 0x45d9, 0x0d37, 0x45e1, 0x45e5, 0x45e8, + 0x45db, 0x0d38, 0x45e2, 0x45f0, 0x0d99, 0x0d98, + /* 0x33 */ + 0x0d97, 0x0dc9, 0x46da, 0x46dd, 0x0dc7, 0x46db, 0x46dc, 0x0dd9, + 0x0ddb, 0x470d, 0x470b, 0x4714, 0x488e, 0x4886, 0x0e7b, 0x4887, + 0x4883, 0x488b, 0x0e7c, 0x0ebd, 0x0ebc, 0x0ec3, 0x4924, 0x0ec1, + 0x0ebf, 0x0ec4, 0x4925, 0x4b62, 0x4b93, 0x4b99, 0x4b97, 0x0f7e, + 0x0f7f, 0x4bc4, 0x4bc6, 0x4c0a, 0x0fb4, 0x0fb3, 0x4c40, 0x4c3c, + 0x4c3b, 0x4cf6, 0x4cff, 0x4cee, 0x4d04, 0x4d03, 0x4d07, 0x8683, + 0x0fe6, 0x4cf7, 0x1059, 0x105a, 0x4e2d, 0x1064, 0x4e27, 0x4e29, + 0x4f1f, 0x4f57, 0x10b4, 0x10b9, 0x10b7, 0x10b5, 0x4f21, 0x10c1, + 0x10b1, 0x4f18, 0x4f58, 0x10b3, 0x10ba, 0x118c, 0x118b, 0x118d, + 0x5284, 0x529f, 0x529b, 0x5289, 0x52a6, 0x5292, 0x528f, 0x52a0, + 0x544f, 0x5478, 0x547a, 0x546e, 0x547b, 0x5484, 0x5473, 0x1278, + 0x1277, 0x560d, 0x560b, 0x5619, 0x12b2, 0x13d6, + /* 0x34 */ + 0x5ad0, 0x1445, 0x1492, 0x1495, 0x5bf9, 0x5c09, 0x5c08, 0x14c6, + 0x5cde, 0x5d51, 0x14e7, 0x14e8, 0x5ddb, 0x5ddf, 0x5dde, 0x5dd6, + 0x5de0, 0x6185, 0x6260, 0x6259, 0x15cb, 0x6256, 0x15cd, 0x15f1, + 0x62bd, 0x1722, 0x0021, 0x1c42, 0x1c59, 0x006f, 0x1c44, 0x1c66, + 0x1c52, 0x1c54, 0x1c71, 0x1c50, 0x1c7b, 0x1c7c, 0x1c58, 0x0070, + 0x0064, 0x1c79, 0x1c6c, 0x1c78, 0x1da8, 0x1dd1, 0x1dcf, 0x1e68, + 0x1e76, 0x1ed4, 0x012d, 0x1fa0, 0x1fc4, 0x0158, 0x2158, 0x214c, + 0x2168, 0x01a6, 0x2149, 0x01a4, 0x019f, 0x215d, 0x2129, 0x73ae, + 0x2154, 0x2153, 0x01a3, 0x215a, 0x01a0, 0x213a, 0x213f, 0x212b, + 0x23ea, 0x024a, 0x23ef, 0x0247, 0x0248, 0x23dd, 0x23fe, 0x8555, + 0x23de, 0x23e6, 0x0249, 0x23e8, 0x23ff, 0x2403, 0x24f7, 0x34a6, + 0x251f, 0x029e, 0x255b, 0x255d, 0x255e, 0x7537, + /* 0x35 */ + 0x02e8, 0x262b, 0x02ec, 0x263b, 0x02ed, 0x02e6, 0x2661, 0x263a, + 0x266e, 0x264b, 0x266b, 0x02eb, 0x02e7, 0x2645, 0x264e, 0x2668, + 0x263d, 0x2671, 0x263f, 0x266f, 0x2675, 0x02e9, 0x2673, 0x262c, + 0x2659, 0x2654, 0x264f, 0x2663, 0x035c, 0x035d, 0x27c8, 0x0360, + 0x27c3, 0x035b, 0x285b, 0x2861, 0x0399, 0x2921, 0x290a, 0x2909, + 0x03d8, 0x292c, 0x2908, 0x03da, 0x03dd, 0x292a, 0x2915, 0x03e0, + 0x2910, 0x2913, 0x03e5, 0x292f, 0x2918, 0x03d7, 0x29e3, 0x2a39, + 0x2a35, 0x2a3a, 0x2a32, 0x044e, 0x048c, 0x0488, 0x858d, 0x2abb, + 0x2aba, 0x2b34, 0x2b39, 0x04ce, 0x859c, 0x04e5, 0x04e6, 0x2c98, + 0x0532, 0x2cd0, 0x0540, 0x0547, 0x054c, 0x2cd7, 0x2caa, 0x0535, + 0x2ca1, 0x2ca4, 0x0530, 0x2cee, 0x0543, 0x2ce7, 0x054d, 0x2ce8, + 0x2cde, 0x05b7, 0x05f3, 0x2f7e, 0x2f8b, 0x0602, + /* 0x36 */ + 0x060b, 0x2f79, 0x2f86, 0x2f93, 0x0604, 0x2f73, 0x2f6a, 0x85ba, + 0x2f6c, 0x0608, 0x2f7f, 0x05fc, 0x2fb2, 0x2fba, 0x05ff, 0x0600, + 0x2f66, 0x2f74, 0x068b, 0x315a, 0x068d, 0x314e, 0x314d, 0x318d, + 0x318e, 0x31ad, 0x06ca, 0x31c7, 0x31ca, 0x06cb, 0x31c9, 0x85cb, + 0x31e3, 0x3257, 0x06f3, 0x3263, 0x3267, 0x331a, 0x3319, 0x3316, + 0x0736, 0x076a, 0x349e, 0x34b6, 0x3498, 0x3473, 0x076b, 0x349a, + 0x348e, 0x34b7, 0x34db, 0x34a5, 0x346c, 0x34c1, 0x3484, 0x0771, + 0x0768, 0x3495, 0x347a, 0x3499, 0x0772, 0x34b8, 0x34b9, 0x3470, + 0x082e, 0x3735, 0x0862, 0x3790, 0x37bb, 0x37ed, 0x0898, 0x08b5, + 0x08eb, 0x39c1, 0x39c3, 0x39ce, 0x08fb, 0x08f8, 0x39ad, 0x3a04, + 0x08f5, 0x39b9, 0x0908, 0x39e7, 0x8607, 0x3a08, 0x3a06, 0x090a, + 0x3a0a, 0x39b0, 0x0906, 0x39f8, 0x3a0c, 0x08fd, + /* 0x37 */ + 0x39b1, 0x08fa, 0x3a02, 0x3a07, 0x3a09, 0x3a01, 0x3a17, 0x39ff, + 0x3a12, 0x09ba, 0x09b9, 0x3d03, 0x3d07, 0x3d01, 0x3cf5, 0x3cf1, + 0x3d08, 0x3cf2, 0x3d0f, 0x09bb, 0x3cfe, 0x0a18, 0x0a40, 0x0a3d, + 0x3f1a, 0x3f10, 0x3f0e, 0x4002, 0x3ff3, 0x0acd, 0x0ac9, 0x3ffb, + 0x0acb, 0x0aca, 0x0ace, 0x411b, 0x4123, 0x4161, 0x4168, 0x0b5e, + 0x4167, 0x41d3, 0x0b91, 0x0b8c, 0x4290, 0x0be1, 0x0c02, 0x42d5, + 0x42d7, 0x42d6, 0x4330, 0x0c2b, 0x4326, 0x0c2a, 0x4340, 0x0a14, + 0x431e, 0x0cad, 0x0ca3, 0x0cab, 0x4447, 0x0caf, 0x444b, 0x4451, + 0x444f, 0x4442, 0x4446, 0x0d04, 0x456e, 0x456c, 0x45f2, 0x0d44, + 0x45f1, 0x45f5, 0x45f3, 0x45f9, 0x0d3d, 0x0d47, 0x0d9c, 0x469a, + 0x4693, 0x4691, 0x46e1, 0x0de0, 0x0de4, 0x4721, 0x471c, 0x4716, + 0x4717, 0x4736, 0x471f, 0x0e80, 0x4893, 0x4899, + /* 0x38 */ + 0x489a, 0x489c, 0x0eca, 0x4949, 0x0ed4, 0x4934, 0x4937, 0x0ed2, + 0x492d, 0x0ecb, 0x494c, 0x0ece, 0x0ed3, 0x4948, 0x0f44, 0x0f48, + 0x4b3b, 0x0f45, 0x0f81, 0x0f86, 0x0f85, 0x4c08, 0x4c1a, 0x0fa3, + 0x4c1d, 0x0fb5, 0x4c49, 0x4c45, 0x4c44, 0x489b, 0x0ffa, 0x0ff9, + 0x4d2a, 0x4d2e, 0x0ffb, 0x0ff2, 0x4d31, 0x0fef, 0x4d1a, 0x4d34, + 0x4d17, 0x105b, 0x1066, 0x10ce, 0x4f1d, 0x4f71, 0x4f84, 0x4f80, + 0x4f72, 0x4fa1, 0x01b4, 0x4f79, 0x4f91, 0x10c8, 0x4f9f, 0x4fad, + 0x10d1, 0x10c5, 0x4f23, 0x10d2, 0x4f85, 0x4f9c, 0x4fb7, 0x5258, + 0x525a, 0x118f, 0x5257, 0x52b2, 0x11a7, 0x52ae, 0x11a5, 0x11a4, + 0x1211, 0x5445, 0x549c, 0x5494, 0x54a3, 0x548f, 0x54a5, 0x54a9, + 0x54a6, 0x548a, 0x54a0, 0x5490, 0x5592, 0x5591, 0x5594, 0x12b5, + 0x5626, 0x5632, 0x5628, 0x12b4, 0x12bd, 0x561c, + /* 0x39 */ + 0x12bb, 0x562b, 0x5620, 0x12b9, 0x5629, 0x12c2, 0x12be, 0x12ba, + 0x5621, 0x583a, 0x06b7, 0x585b, 0x5858, 0x587c, 0x1358, 0x58a6, + 0x58ae, 0x58ad, 0x5965, 0x139b, 0x597e, 0x139c, 0x597c, 0x597f, + 0x597a, 0x59bd, 0x13da, 0x13de, 0x59c0, 0x59bb, 0x5aad, 0x5aaf, + 0x5ad6, 0x144d, 0x1446, 0x1447, 0x144b, 0x144c, 0x5ad9, 0x1448, + 0x1499, 0x5c12, 0x5c0e, 0x5c25, 0x149b, 0x5c13, 0x5cee, 0x14ce, + 0x5cab, 0x5cf7, 0x14eb, 0x5d59, 0x5d54, 0x5df2, 0x5df0, 0x5de5, + 0x5df6, 0x151c, 0x158c, 0x6187, 0x15d1, 0x625a, 0x15d6, 0x15d3, + 0x626e, 0x15d4, 0x15d0, 0x15d5, 0x6279, 0x160b, 0x64e1, 0x64e6, + 0x17c6, 0x6ac4, 0x6ad2, 0x1a80, 0x0024, 0x1a81, 0x1c8f, 0x1c97, + 0x1c88, 0x1c89, 0x0074, 0x007a, 0x1c81, 0x1d60, 0x7064, 0x00c3, + 0x2a42, 0x1dd3, 0x00d4, 0x00d5, 0x1dd2, 0x1dd6, + /* 0x3a */ + 0x1e73, 0x00fb, 0x1e70, 0x00f7, 0x0132, 0x8533, 0x1fa8, 0x1fa6, + 0x1fc5, 0x2197, 0x21de, 0x01ba, 0x01bf, 0x2196, 0x21b4, 0x01c7, + 0x2185, 0x01b7, 0x219b, 0x21a0, 0x01b9, 0x2159, 0x01c3, 0x2186, + 0x01bd, 0x01d0, 0x21af, 0x217a, 0x01c1, 0x01be, 0x01cd, 0x219e, + 0x01cb, 0x21a9, 0x230f, 0x230e, 0x241a, 0x024f, 0x241f, 0x0253, + 0x243c, 0x2418, 0x243e, 0x2426, 0x0255, 0x243a, 0x7464, 0x2422, + 0x0251, 0x24fb, 0x2563, 0x2564, 0x029f, 0x26a8, 0x26a3, 0x2682, + 0x2688, 0x26a1, 0x2685, 0x2698, 0x02fe, 0x2699, 0x02fb, 0x2689, + 0x2681, 0x2696, 0x2680, 0x02f1, 0x02f5, 0x2691, 0x02ef, 0x0304, + 0x0303, 0x02f4, 0x26cf, 0x02f3, 0x0302, 0x02f7, 0x02fa, 0x02fd, + 0x02ee, 0x2687, 0x26a0, 0x02f0, 0x2679, 0x02f2, 0x2686, 0x26ab, + 0x26aa, 0x26a4, 0x268d, 0x267e, 0x0344, 0x27d5, + /* 0x3b */ + 0x0362, 0x0377, 0x09c9, 0x281e, 0x285f, 0x285e, 0x2944, 0x293e, + 0x03e8, 0x2948, 0x291c, 0x03ef, 0x295b, 0x294d, 0x03e6, 0x03ed, + 0x2957, 0x03e7, 0x2953, 0x294f, 0x03eb, 0x293b, 0x2946, 0x042d, + 0x0455, 0x2a46, 0x2a47, 0x0453, 0x2a48, 0x2ac0, 0x2abd, 0x2abf, + 0x0490, 0x2b11, 0x04be, 0x2b3e, 0x2b3b, 0x04bd, 0x2b3a, 0x04cf, + 0x04d0, 0x04ec, 0x2ba7, 0x054b, 0x2cea, 0x0548, 0x2d07, 0x2d22, + 0x2d0c, 0x0555, 0x0551, 0x2cb3, 0x2cd6, 0x2cd2, 0x054e, 0x2ce3, + 0x2ce5, 0x2ce9, 0x056b, 0x055e, 0x2d11, 0x2cfd, 0x0560, 0x0567, + 0x2d1e, 0x2d20, 0x2d21, 0x2e1e, 0x05b8, 0x2fe2, 0x2fde, 0x2fe6, + 0x0614, 0x060f, 0x0607, 0x0613, 0x2ff8, 0x0617, 0x2ffe, 0x2fc1, + 0x2fbf, 0x2ff7, 0x2fd1, 0x315f, 0x3160, 0x3161, 0x069a, 0x06b8, + 0x31d1, 0x06f7, 0x06f8, 0x327d, 0x326b, 0x327f, + /* 0x3c */ + 0x06fd, 0x06f5, 0x3273, 0x3281, 0x326d, 0x3269, 0x06fa, 0x0738, + 0x331e, 0x34ed, 0x0787, 0x0780, 0x0788, 0x0779, 0x3503, 0x077c, + 0x34fe, 0x34e5, 0x351e, 0x3502, 0x0783, 0x0785, 0x3509, 0x34ca, + 0x3500, 0x85e5, 0x3501, 0x3518, 0x34e2, 0x34cf, 0x077b, 0x352e, + 0x34c5, 0x34ff, 0x0786, 0x351c, 0x34c3, 0x0834, 0x376f, 0x0855, + 0x376e, 0x0868, 0x37be, 0x089c, 0x37f4, 0x382d, 0x08fc, 0x39b6, + 0x3a75, 0x3a1e, 0x091a, 0x3a18, 0x0917, 0x3a48, 0x091b, 0x3a4f, + 0x0913, 0x3a42, 0x3a6a, 0x3a70, 0x39fe, 0x0905, 0x0907, 0x3a6d, + 0x091c, 0x3a7b, 0x3a7e, 0x3a59, 0x0911, 0x3a57, 0x0916, 0x3a80, + 0x3a50, 0x0915, 0x3a29, 0x3a76, 0x3a2a, 0x3a4c, 0x3d2a, 0x09cb, + 0x3d35, 0x3d2c, 0x3d37, 0x3d1d, 0x09c5, 0x09c2, 0x3d38, 0x09cd, + 0x3d34, 0x3d2b, 0x3d33, 0x3d27, 0x3d24, 0x09ca, + /* 0x3d */ + 0x3d2d, 0x3e32, 0x3e83, 0x3e82, 0x3e87, 0x3f06, 0x3f24, 0x3f38, + 0x3f2a, 0x3f2c, 0x3f2b, 0x0a83, 0x3f2f, 0x3f28, 0x4017, 0x0ad6, + 0x0ad5, 0x4019, 0x4038, 0x0ad1, 0x401f, 0x4014, 0x403c, 0x3ff7, + 0x401c, 0x4015, 0x4018, 0x4039, 0x40f9, 0x4124, 0x8634, 0x0b52, + 0x0b5f, 0x416e, 0x416d, 0x4171, 0x418e, 0x0b95, 0x41e5, 0x0b9d, + 0x0b98, 0x0b9e, 0x0b96, 0x4294, 0x42b3, 0x0c03, 0x42d9, 0x0c2f, + 0x4348, 0x4349, 0x4343, 0x0c31, 0x0c33, 0x4342, 0x43df, 0x0cb4, + 0x4463, 0x4476, 0x0cb0, 0x445f, 0x4466, 0x4566, 0x4571, 0x0d08, + 0x0d07, 0x4576, 0x4584, 0x4575, 0x45ff, 0x4607, 0x0d4e, 0x460e, + 0x4609, 0x0d50, 0x0d52, 0x0da1, 0x0da3, 0x0da5, 0x0dcc, 0x46e7, + 0x46e2, 0x4755, 0x0def, 0x0dea, 0x4743, 0x4757, 0x476c, 0x4742, + 0x4753, 0x0ded, 0x4741, 0x0e85, 0x0e84, 0x48a7, + /* 0x3e */ + 0x48a0, 0x48a6, 0x48a4, 0x4974, 0x0edb, 0x4959, 0x0ed9, 0x4960, + 0x4957, 0x496c, 0x497e, 0x4964, 0x0ed7, 0x495a, 0x495d, 0x0eda, + 0x0ede, 0x0ed8, 0x4976, 0x494d, 0x4975, 0x0ed5, 0x4bd3, 0x4bd6, + 0x0f9c, 0x0f9d, 0x4c60, 0x4c4e, 0x4d45, 0x4d3b, 0x0ffe, 0x4d48, + 0x4d42, 0x4d49, 0x4d40, 0x4d14, 0x4d41, 0x1007, 0x4def, 0x4df6, + 0x4e03, 0x106a, 0x4fed, 0x10e7, 0x4fda, 0x5018, 0x4fd2, 0x5008, + 0x10e2, 0x5000, 0x10df, 0x10e1, 0x10e5, 0x5017, 0x4f46, 0x5014, + 0x4fd3, 0x5005, 0x501f, 0x5002, 0x5016, 0x4fcd, 0x4fe6, 0x1191, + 0x525d, 0x52d5, 0x52e1, 0x11b4, 0x11b0, 0x11b5, 0x11ae, 0x52ee, + 0x5447, 0x5446, 0x122d, 0x122c, 0x54bb, 0x122b, 0x54bf, 0x54b4, + 0x1229, 0x54b5, 0x127f, 0x559a, 0x5643, 0x12c9, 0x12cb, 0x565a, + 0x12c5, 0x12c6, 0x12ca, 0x5635, 0x5638, 0x5642, + /* 0x3f */ + 0x5649, 0x565d, 0x564b, 0x563d, 0x12d2, 0x12d0, 0x132d, 0x1335, + 0x5860, 0x585e, 0x587f, 0x587e, 0x5883, 0x136c, 0x58b1, 0x5987, + 0x139d, 0x13a0, 0x5988, 0x5983, 0x13a2, 0x139f, 0x5986, 0x598b, + 0x5982, 0x59ca, 0x59d2, 0x13eb, 0x13e2, 0x59d4, 0x59c9, 0x5ab0, + 0x1436, 0x1432, 0x1450, 0x5af2, 0x5ae4, 0x5af3, 0x5aea, 0x144f, + 0x5afd, 0x1452, 0x5b9d, 0x5c2b, 0x5c2a, 0x149e, 0x5c28, 0x5c29, + 0x5c2c, 0x14a0, 0x149c, 0x5c3a, 0x5c30, 0x5c37, 0x5c3b, 0x14d1, + 0x5d0a, 0x14ef, 0x14f0, 0x14f1, 0x5dfe, 0x5e20, 0x151d, 0x5e0b, + 0x151f, 0x5e18, 0x5e22, 0x151e, 0x5e1b, 0x5e08, 0x1520, 0x5e0e, + 0x5e13, 0x158e, 0x1591, 0x6195, 0x83dd, 0x1590, 0x15d7, 0x628c, + 0x627b, 0x627f, 0x6281, 0x15d9, 0x6282, 0x15f4, 0x15f6, 0x0160, + 0x15f5, 0x15f3, 0x62ee, 0x62ed, 0x160c, 0x62ec, + /* 0x40 */ + 0x635f, 0x636f, 0x1651, 0x636d, 0x16a6, 0x16a7, 0x16a8, 0x1727, + 0x1724, 0x1725, 0x64f0, 0x172a, 0x1774, 0x17c7, 0x66a9, 0x17e7, + 0x17ed, 0x66e0, 0x1ab7, 0x002e, 0x007b, 0x1ccc, 0x1cbc, 0x007c, + 0x1caa, 0x1cb9, 0x007d, 0x1cab, 0x1cc3, 0x1ccd, 0x1d7e, 0x1e7e, + 0x1e79, 0x00fd, 0x8523, 0x1ee1, 0x1ee0, 0x1ee7, 0x1f80, 0x1fab, + 0x1faa, 0x1fa9, 0x1fe0, 0x21ea, 0x01da, 0x21d7, 0x01d6, 0x01db, + 0x21c1, 0x2315, 0x025b, 0x246c, 0x025c, 0x245c, 0x2450, 0x2461, + 0x246a, 0x2469, 0x2456, 0x2460, 0x2466, 0x245f, 0x2523, 0x2566, + 0x2568, 0x0306, 0x030b, 0x26ce, 0x030d, 0x26c5, 0x26c3, 0x030a, + 0x0313, 0x26d0, 0x0310, 0x0312, 0x0309, 0x0308, 0x0311, 0x030f, + 0x2774, 0x2776, 0x27dc, 0x27d7, 0x27da, 0x27db, 0x0367, 0x2820, + 0x296d, 0x2966, 0x03f6, 0x2964, 0x296e, 0x857e, + /* 0x41 */ + 0x2960, 0x2b42, 0x2b5a, 0x2b6e, 0x0564, 0x056c, 0x2d30, 0x2d3a, + 0x2d2a, 0x2d43, 0x2d19, 0x2d31, 0x056d, 0x2d3d, 0x057a, 0x0575, + 0x060d, 0x3008, 0x3032, 0x3038, 0x061e, 0x3031, 0x061b, 0x3019, + 0x062a, 0x3011, 0x061f, 0x0622, 0x3029, 0x301d, 0x0625, 0x0627, + 0x0629, 0x303c, 0x0624, 0x3046, 0x3047, 0x0628, 0x0626, 0x303a, + 0x3007, 0x0623, 0x316b, 0x069f, 0x3170, 0x316d, 0x06b1, 0x31e4, + 0x3293, 0x0703, 0x0707, 0x070c, 0x0706, 0x328f, 0x0704, 0x0709, + 0x3292, 0x0705, 0x328e, 0x0708, 0x3546, 0x0796, 0x079c, 0x079f, + 0x079b, 0x0798, 0x0799, 0x0794, 0x3531, 0x078d, 0x07a3, 0x353e, + 0x0793, 0x357c, 0x3543, 0x0792, 0x3573, 0x85e8, 0x3555, 0x078e, + 0x078c, 0x3585, 0x354d, 0x3550, 0x3547, 0x3567, 0x3536, 0x3564, + 0x3561, 0x079a, 0x357d, 0x3744, 0x3740, 0x3771, + /* 0x42 */ + 0x3773, 0x379c, 0x086a, 0x086d, 0x0884, 0x37c1, 0x08a0, 0x37fa, + 0x3831, 0x3832, 0x091d, 0x0926, 0x3ab8, 0x3aa8, 0x0933, 0x3a91, + 0x3abb, 0x0938, 0x3a9a, 0x0930, 0x0928, 0x3aa9, 0x0927, 0x092a, + 0x3ab5, 0x3a6c, 0x3ae8, 0x0931, 0x3add, 0x3ada, 0x3ae6, 0x3aac, + 0x0934, 0x092e, 0x093b, 0x3ad9, 0x3ae3, 0x3ae9, 0x3adb, 0x0929, + 0x3d6f, 0x09d2, 0x09d8, 0x3d48, 0x09cf, 0x3d4a, 0x3d6b, 0x09d9, + 0x3d4f, 0x3d57, 0x3d74, 0x09ce, 0x09d3, 0x09d0, 0x3d45, 0x3d51, + 0x3d6d, 0x07a1, 0x3e51, 0x3e50, 0x3e4e, 0x0a47, 0x3f41, 0x0a8b, + 0x3f2e, 0x3f46, 0x0ad4, 0x4027, 0x0ade, 0x4048, 0x4053, 0x403d, + 0x0adf, 0x405d, 0x4056, 0x0ad7, 0x401e, 0x4047, 0x4043, 0x4058, + 0x4049, 0x0ae1, 0x404c, 0x4045, 0x403e, 0x0b2f, 0x4101, 0x411e, + 0x0b62, 0x0b63, 0x417a, 0x41ee, 0x4202, 0x4297, + /* 0x43 */ + 0x4298, 0x0be2, 0x0c04, 0x0c43, 0x435d, 0x4364, 0x4353, 0x4358, + 0x4482, 0x4490, 0x448a, 0x0cbe, 0x447a, 0x447d, 0x0cba, 0x448b, + 0x4478, 0x0cbc, 0x864e, 0x448d, 0x4488, 0x4492, 0x4481, 0x457e, + 0x4583, 0x0d0d, 0x0d0e, 0x0d11, 0x4580, 0x0d0f, 0x0d12, 0x0d55, + 0x460f, 0x0d59, 0x0d5b, 0x461d, 0x0d57, 0x46a1, 0x46a4, 0x0dce, + 0x46e9, 0x46ea, 0x0dfe, 0x4762, 0x476b, 0x0dfc, 0x475e, 0x0df5, + 0x4779, 0x0df9, 0x0dfa, 0x476f, 0x4768, 0x0e88, 0x0e89, 0x48ae, + 0x0e8a, 0x0e87, 0x0e8b, 0x48b0, 0x0ee6, 0x4990, 0x0eed, 0x498a, + 0x0ee5, 0x498b, 0x4999, 0x4995, 0x0ee0, 0x4987, 0x4978, 0x4997, + 0x4989, 0x4998, 0x0ee1, 0x0f5b, 0x0f5c, 0x4ba3, 0x0f8f, 0x0f8b, + 0x0f8d, 0x4bdd, 0x4c57, 0x0fb9, 0x4d63, 0x4d6a, 0x4d6c, 0x100f, + 0x1019, 0x1013, 0x4d5d, 0x4d75, 0x1018, 0x4d5f, + /* 0x44 */ + 0x1016, 0x4d7d, 0x4d6d, 0x1053, 0x868d, 0x4e41, 0x504f, 0x5084, + 0x10f6, 0x507f, 0x10f5, 0x5048, 0x502a, 0x507b, 0x5072, 0x5064, + 0x502e, 0x505c, 0x5053, 0x10f7, 0x5041, 0x50c8, 0x10f0, 0x5062, + 0x5080, 0x503e, 0x5083, 0x5071, 0x10f9, 0x504a, 0x5055, 0x5058, + 0x1192, 0x1195, 0x1196, 0x52fc, 0x52fd, 0x5315, 0x11b9, 0x5316, + 0x52ff, 0x11bd, 0x11b8, 0x1212, 0x5458, 0x54cf, 0x54e0, 0x1280, + 0x1281, 0x129a, 0x1298, 0x55e7, 0x566a, 0x5680, 0x12d4, 0x566f, + 0x5665, 0x12da, 0x5678, 0x567d, 0x5688, 0x12d6, 0x12db, 0x5664, + 0x567e, 0x12dc, 0x5667, 0x5863, 0x5888, 0x1371, 0x58cd, 0x1372, + 0x58c9, 0x13a8, 0x59ed, 0x13f0, 0x86db, 0x13f1, 0x13fd, 0x1438, + 0x1437, 0x1439, 0x5ab1, 0x1455, 0x1453, 0x5b04, 0x5b9e, 0x5ba0, + 0x5c43, 0x5c46, 0x5c48, 0x5c45, 0x5c40, 0x5c4c, + /* 0x45 */ + 0x14d5, 0x14bd, 0x5d0c, 0x5d13, 0x5d15, 0x14f5, 0x5d6b, 0x5d67, + 0x5e5d, 0x5e55, 0x5e35, 0x1521, 0x5e59, 0x5e2f, 0x5e3c, 0x5e8f, + 0x5e5c, 0x5e6a, 0x5e62, 0x5e5f, 0x5e6b, 0x5e6e, 0x5e3b, 0x5e44, + 0x5e41, 0x619a, 0x1592, 0x6199, 0x15de, 0x15db, 0x15da, 0x628f, + 0x15df, 0x6296, 0x15f9, 0x15f8, 0x15fa, 0x62f4, 0x62fc, 0x160e, + 0x6355, 0x1643, 0x6379, 0x1656, 0x1653, 0x169e, 0x63ee, 0x63f5, + 0x16a9, 0x640b, 0x16fa, 0x64f3, 0x1731, 0x1730, 0x64f7, 0x64ff, + 0x64f5, 0x1732, 0x64ec, 0x64f1, 0x1729, 0x172e, 0x659a, 0x1776, + 0x66e2, 0x673d, 0x675d, 0x68e8, 0x18a5, 0x68eb, 0x68ef, 0x68ee, + 0x6a81, 0x6b14, 0x1cd0, 0x1cd9, 0x1cdc, 0x1cd8, 0x008c, 0x1ce1, + 0x1ceb, 0x008b, 0x0089, 0x1cf4, 0x1ce2, 0x1cde, 0x008d, 0x0086, + 0x00d7, 0x1df4, 0x0104, 0x0107, 0x0103, 0x1eed, + /* 0x46 */ + 0x1eea, 0x0122, 0x1f32, 0x0151, 0x1fae, 0x1fb0, 0x0161, 0x21fb, + 0x2203, 0x220b, 0x01e9, 0x2207, 0x01e5, 0x21f8, 0x01e4, 0x2228, + 0x221e, 0x01e3, 0x2218, 0x2211, 0x2251, 0x2205, 0x2317, 0x2492, + 0x0265, 0x248c, 0x0263, 0x2478, 0x2484, 0x2473, 0x24ad, 0x2497, + 0x2495, 0x2477, 0x2472, 0x2496, 0x248d, 0x2510, 0x028c, 0x256c, + 0x031a, 0x26e7, 0x0315, 0x26e4, 0x0320, 0x0321, 0x26ef, 0x2226, + 0x031c, 0x031b, 0x26f0, 0x297b, 0x03fe, 0x2983, 0x0404, 0x0401, + 0x298b, 0x298c, 0x0400, 0x2978, 0x2a52, 0x046d, 0x0493, 0x2ad0, + 0x2acf, 0x04a1, 0x2bb3, 0x2bb4, 0x0576, 0x0579, 0x0572, 0x2d7b, + 0x0583, 0x2d6f, 0x2d81, 0x2d3c, 0x2d42, 0x2d38, 0x2d33, 0x85a6, + 0x2d60, 0x2d69, 0x2d7d, 0x2d86, 0x2e2c, 0x2e28, 0x0638, 0x304c, + 0x0630, 0x3057, 0x307c, 0x0634, 0x063a, 0x3055, + /* 0x47 */ + 0x3062, 0x3071, 0x306a, 0x3056, 0x303b, 0x3081, 0x0635, 0x304f, + 0x307e, 0x3064, 0x063f, 0x0640, 0x0632, 0x0631, 0x0636, 0x3171, + 0x7aba, 0x070f, 0x32a5, 0x329a, 0x329c, 0x0710, 0x32a6, 0x070d, + 0x32a4, 0x358f, 0x35c5, 0x35c8, 0x3592, 0x35b2, 0x07a9, 0x07b4, + 0x07ac, 0x35e3, 0x35c0, 0x35d6, 0x35d1, 0x359f, 0x35a2, 0x35d2, + 0x07b8, 0x07ae, 0x7bf3, 0x35e1, 0x35d5, 0x359d, 0x07b3, 0x07ba, + 0x3598, 0x083f, 0x3774, 0x37a1, 0x093c, 0x3af0, 0x3af3, 0x0942, + 0x0940, 0x3b1b, 0x3b0c, 0x3b1d, 0x3b34, 0x3b28, 0x3b17, 0x093e, + 0x3b44, 0x3b42, 0x3b04, 0x3b11, 0x3afa, 0x3b4a, 0x3d91, 0x3d8e, + 0x09e1, 0x3d8b, 0x3d8d, 0x3d7f, 0x3d8c, 0x3d7e, 0x3d7c, 0x3d83, + 0x09e6, 0x3d88, 0x09e0, 0x0a15, 0x3e94, 0x0a93, 0x3f55, 0x3f53, + 0x3f4f, 0x3f54, 0x406c, 0x4065, 0x4066, 0x4061, + /* 0x48 */ + 0x406b, 0x4068, 0x4076, 0x0ae7, 0x4060, 0x7e0f, 0x4074, 0x4106, + 0x420e, 0x0bad, 0x4207, 0x0bae, 0x0be3, 0x42b9, 0x0bf5, 0x42b7, + 0x42e2, 0x0c06, 0x4374, 0x4377, 0x4376, 0x4375, 0x0c4f, 0x4378, + 0x4371, 0x0c54, 0x437a, 0x3d5b, 0x437b, 0x44a6, 0x44ae, 0x44b8, + 0x0ccb, 0x0ce3, 0x0cc9, 0x44b1, 0x44af, 0x0d13, 0x4589, 0x4587, + 0x0d15, 0x0d61, 0x4629, 0x0d66, 0x462a, 0x0d64, 0x462d, 0x462c, + 0x0d60, 0x4632, 0x0d63, 0x46ec, 0x46f0, 0x4781, 0x479e, 0x4783, + 0x0e0a, 0x4792, 0x0e04, 0x47a3, 0x479f, 0x4793, 0x0e07, 0x4786, + 0x48b8, 0x48b7, 0x0e8d, 0x0e8f, 0x0e90, 0x0e92, 0x0eec, 0x49c8, + 0x49b6, 0x866c, 0x49d1, 0x0ee7, 0x49a8, 0x49ab, 0x0ef2, 0x49b3, + 0x49cd, 0x0eee, 0x49cf, 0x49a4, 0x0eef, 0x0f4c, 0x4b41, 0x4b6f, + 0x4b71, 0x0f5e, 0x0f5f, 0x0f76, 0x0f74, 0x0f72, + /* 0x49 */ + 0x0f90, 0x4c23, 0x4c5b, 0x0fbe, 0x4c61, 0x4c5f, 0x4d81, 0x1026, + 0x1025, 0x4d84, 0x4e13, 0x1074, 0x4e4a, 0x4e4c, 0x10fd, 0x1105, + 0x1101, 0x50bd, 0x5095, 0x1109, 0x5092, 0x50c3, 0x110c, 0x5096, + 0x50a5, 0x50b5, 0x50b3, 0x50a3, 0x50e4, 0x50d8, 0x50d5, 0x110d, + 0x50b7, 0x50ad, 0x50da, 0x5093, 0x5336, 0x11c0, 0x11c5, 0x11c9, + 0x533d, 0x532b, 0x5347, 0x5339, 0x11d5, 0x5345, 0x531d, 0x1241, + 0x54ff, 0x54ea, 0x1233, 0x54f5, 0x123a, 0x5500, 0x54ed, 0x5503, + 0x54e9, 0x1240, 0x1242, 0x55ea, 0x12e8, 0x569b, 0x568e, 0x56a2, + 0x12e4, 0x569c, 0x5694, 0x5690, 0x56a9, 0x56ac, 0x12e7, 0x569f, + 0x12e6, 0x12e1, 0x569d, 0x1339, 0x5867, 0x135c, 0x1375, 0x58d0, + 0x58d6, 0x58d4, 0x5998, 0x599a, 0x5997, 0x13ae, 0x13b0, 0x13fa, + 0x5a0b, 0x5a08, 0x5a01, 0x5ab4, 0x5ab3, 0x145b, + /* 0x4a */ + 0x5ba1, 0x5ba2, 0x14a5, 0x5c5a, 0x14a2, 0x5c61, 0x5c5f, 0x14db, + 0x14da, 0x5d25, 0x5d7b, 0x5d76, 0x5d7c, 0x1524, 0x5e89, 0x5ef6, + 0x5eb1, 0x5ead, 0x5e92, 0x5e81, 0x5e84, 0x1526, 0x5eae, 0x5e90, + 0x5e9e, 0x1598, 0x1596, 0x159a, 0x61a2, 0x61a7, 0x1597, 0x15e1, + 0x15e0, 0x15e3, 0x15e2, 0x62a0, 0x629d, 0x629f, 0x62d0, 0x15fb, + 0x62d1, 0x1612, 0x1614, 0x6359, 0x1645, 0x6364, 0x165c, 0x165d, + 0x16b8, 0x6419, 0x16ba, 0x6414, 0x6415, 0x641a, 0x1703, 0x1735, + 0x1736, 0x1739, 0x6506, 0x172d, 0x64f8, 0x6501, 0x177a, 0x65be, + 0x65bc, 0x65b7, 0x65b6, 0x65c0, 0x1778, 0x65b8, 0x177b, 0x177c, + 0x177e, 0x65c4, 0x177d, 0x65bf, 0x17c9, 0x66da, 0x66e4, 0x66e9, + 0x66e8, 0x66ea, 0x66e5, 0x17f3, 0x6726, 0x181a, 0x1819, 0x6740, + 0x181f, 0x18a6, 0x18a7, 0x18a8, 0x18ab, 0x18a9, + /* 0x4b */ + 0x192e, 0x6abd, 0x195e, 0x0095, 0x0093, 0x0092, 0x1d0e, 0x0096, + 0x1cf7, 0x0097, 0x1cfc, 0x1d0d, 0x1d01, 0x1dda, 0x1dd9, 0x1ddb, + 0x1e86, 0x1e8e, 0x1eee, 0x1f33, 0x1fb1, 0x01f5, 0x2247, 0x222d, + 0x2254, 0x01ea, 0x224b, 0x2252, 0x2231, 0x2244, 0x2256, 0x2250, + 0x222b, 0x01f3, 0x224d, 0x2237, 0x224f, 0x24a2, 0x24b7, 0x0269, + 0x24b2, 0x026b, 0x24aa, 0x24b5, 0x24b0, 0x026c, 0x24b4, 0x24a4, + 0x24a7, 0x0268, 0x2526, 0x26fe, 0x0328, 0x2704, 0x0326, 0x26fc, + 0x0325, 0x2706, 0x270a, 0x26fa, 0x270d, 0x2700, 0x270e, 0x036b, + 0x040f, 0x0408, 0x2991, 0x040c, 0x298f, 0x2990, 0x2998, 0x29a4, + 0x299b, 0x29a3, 0x2996, 0x29e4, 0x2a5a, 0x0460, 0x0462, 0x2a5e, + 0x0498, 0x2bb8, 0x2d57, 0x2d5c, 0x2da6, 0x2d95, 0x2d88, 0x058a, + 0x2da3, 0x2d8f, 0x0584, 0x2d64, 0x057f, 0x2d59, + /* 0x4c */ + 0x2d78, 0x0582, 0x2d85, 0x2d87, 0x2d9e, 0x0596, 0x0589, 0x2d98, + 0x2d9c, 0x058d, 0x05bc, 0x2e2f, 0x3080, 0x309b, 0x308e, 0x308d, + 0x3094, 0x30c6, 0x0644, 0x30a8, 0x3083, 0x063c, 0x30b9, 0x3086, + 0x30b4, 0x30af, 0x3091, 0x064e, 0x30aa, 0x30a1, 0x30a7, 0x32b6, + 0x32b3, 0x0714, 0x32bc, 0x32ac, 0x0715, 0x32ad, 0x360e, 0x07ce, + 0x361c, 0x361a, 0x07e0, 0x07c2, 0x360b, 0x07bf, 0x35ef, 0x360c, + 0x35f0, 0x3622, 0x07c4, 0x35d8, 0x07cf, 0x3612, 0x35fa, 0x07c8, + 0x362a, 0x07cc, 0x3610, 0x07cd, 0x07c7, 0x3629, 0x35f9, 0x35ea, + 0x362c, 0x3624, 0x18b7, 0x35e9, 0x3752, 0x374f, 0x3753, 0x0843, + 0x08b6, 0x3b10, 0x3b65, 0x3b75, 0x0951, 0x094a, 0x094d, 0x0956, + 0x3bd0, 0x0953, 0x3b5c, 0x3b3d, 0x3b71, 0x0959, 0x3b91, 0x3b0b, + 0x3b79, 0x3b81, 0x3b8f, 0x094e, 0x3b59, 0x3b74, + /* 0x4d */ + 0x09ee, 0x3dae, 0x09ec, 0x3da3, 0x3dad, 0x09eb, 0x09ef, 0x3dab, + 0x3da6, 0x3da2, 0x09ed, 0x1ef2, 0x3e57, 0x3e55, 0x3e99, 0x3f4b, + 0x407a, 0x0af2, 0x0aef, 0x0af1, 0x408c, 0x4084, 0x0aed, 0x0af0, + 0x4082, 0x4093, 0x407b, 0x0aee, 0x4109, 0x181b, 0x0b50, 0x0b66, + 0x0284, 0x0bb8, 0x0bf6, 0x438a, 0x0c57, 0x4390, 0x0c5e, 0x44c6, + 0x44d3, 0x44c0, 0x44d2, 0x44c7, 0x44c2, 0x0d19, 0x459f, 0x459d, + 0x459e, 0x0d70, 0x4641, 0x0d6e, 0x4638, 0x463a, 0x4642, 0x0d72, + 0x0d76, 0x463e, 0x46b0, 0x47ae, 0x47b3, 0x0e12, 0x0e1f, 0x47bf, + 0x0e11, 0x0e16, 0x47cd, 0x0e19, 0x47b2, 0x0e24, 0x0e14, 0x0e25, + 0x0e95, 0x0e96, 0x0e93, 0x0e94, 0x48c4, 0x48cd, 0x48c2, 0x48c6, + 0x48c3, 0x48c9, 0x48c7, 0x0ea0, 0x49f8, 0x0efb, 0x49ed, 0x49e2, + 0x0efc, 0x0f00, 0x0ef8, 0x49dc, 0x4a02, 0x4a01, + /* 0x4e */ + 0x0ef9, 0x49d6, 0x0f04, 0x49e4, 0x49fe, 0x0f03, 0x4a00, 0x49fc, + 0x49fd, 0x0ef3, 0x49f5, 0x49ff, 0x0efa, 0x49eb, 0x49e5, 0x4b78, + 0x4bae, 0x4be7, 0x0fbf, 0x4c65, 0x4c6a, 0x4c66, 0x4c68, 0x4c6b, + 0x4d94, 0x4da1, 0x4d92, 0x4d96, 0x4d93, 0x1079, 0x1110, 0x5101, + 0x1114, 0x50f8, 0x110e, 0x50f5, 0x111a, 0x5104, 0x1119, 0x1121, + 0x1123, 0x111f, 0x511b, 0x5103, 0x5133, 0x5134, 0x50ed, 0x1125, + 0x112b, 0x5135, 0x1116, 0x5105, 0x1122, 0x111b, 0x11ce, 0x11cf, + 0x537d, 0x11cb, 0x11d1, 0x11cc, 0x5371, 0x1217, 0x545c, 0x54e6, + 0x550f, 0x551b, 0x1251, 0x55a9, 0x55a5, 0x55ee, 0x56b1, 0x12ed, + 0x56cc, 0x56ce, 0x12f4, 0x56b7, 0x12f1, 0x56b5, 0x56e9, 0x56b4, + 0x12f8, 0x56b3, 0x56c1, 0x56af, 0x56ca, 0x56d0, 0x132f, 0x135e, + 0x135d, 0x588e, 0x1376, 0x1377, 0x58e9, 0x58db, + /* 0x4f */ + 0x137e, 0x58eb, 0x59a4, 0x13b6, 0x59a2, 0x599d, 0x13b3, 0x13fc, + 0x1403, 0x1400, 0x5a2a, 0x5a28, 0x140a, 0x1402, 0x5ab8, 0x5ab6, + 0x5ab9, 0x5ab7, 0x5b22, 0x5b2b, 0x5b27, 0x5b19, 0x5ba4, 0x1487, + 0x5bb3, 0x14a6, 0x5c71, 0x5c6a, 0x14a9, 0x14de, 0x5d88, 0x5d8c, + 0x5ebf, 0x5eb8, 0x5ebe, 0x5edc, 0x5ee5, 0x152e, 0x152d, 0x5ed4, + 0x5ed6, 0x1530, 0x5eda, 0x5eed, 0x5ef3, 0x5edb, 0x152b, 0x5eb9, + 0x5ee2, 0x5eeb, 0x61af, 0x159e, 0x61b2, 0x61b3, 0x159f, 0x15e5, + 0x15e4, 0x62a3, 0x62a5, 0x15fd, 0x15fc, 0x1617, 0x1619, 0x630a, + 0x1618, 0x6387, 0x6389, 0x638c, 0x63ef, 0x642a, 0x6422, 0x16bf, + 0x641f, 0x173c, 0x6519, 0x176b, 0x65ca, 0x65da, 0x1783, 0x1781, + 0x1780, 0x65de, 0x65c8, 0x65e0, 0x17ca, 0x66b6, 0x66b5, 0x17ce, + 0x66f4, 0x17f6, 0x676b, 0x6769, 0x6772, 0x6763, + /* 0x50 */ + 0x1839, 0x690d, 0x18ae, 0x6901, 0x690c, 0x18b5, 0x68f8, 0x18b3, + 0x18b4, 0x68fe, 0x6902, 0x6a84, 0x1922, 0x6aab, 0x6aaa, 0x1d1d, + 0x1d16, 0x0099, 0x1d2b, 0x1d1e, 0x1d1b, 0x1e90, 0x1e94, 0x1f14, + 0x7289, 0x0202, 0x2267, 0x0201, 0x227b, 0x02a1, 0x225f, 0x2261, + 0x01fd, 0x0273, 0x0274, 0x0270, 0x0276, 0x0275, 0x0272, 0x24c3, + 0x24ca, 0x24bb, 0x24c0, 0x24c4, 0x2501, 0x271f, 0x2718, 0x2711, + 0x2715, 0x0329, 0x2712, 0x271c, 0x032a, 0x2722, 0x2779, 0x29a6, + 0x0416, 0x29b3, 0x29ab, 0x2aea, 0x0499, 0x2b5b, 0x04d3, 0x04f5, + 0x2db7, 0x2dce, 0x2db9, 0x2dbd, 0x2dcf, 0x2dc0, 0x2d99, 0x2d97, + 0x0594, 0x2dbb, 0x2dd0, 0x2dc4, 0x2e31, 0x0656, 0x30d3, 0x30c0, + 0x0659, 0x0658, 0x0655, 0x0652, 0x30dc, 0x30d1, 0x30c8, 0x0657, + 0x30d5, 0x32c3, 0x071b, 0x071c, 0x32bf, 0x32c5, + /* 0x51 */ + 0x0719, 0x32cd, 0x32c1, 0x3306, 0x073f, 0x3324, 0x3663, 0x3642, + 0x3652, 0x07db, 0x3643, 0x3633, 0x07e2, 0x366c, 0x3657, 0x07d7, + 0x364c, 0x366e, 0x07de, 0x07e5, 0x07e4, 0x07e6, 0x07d6, 0x3637, + 0x07df, 0x3671, 0x364a, 0x3636, 0x07dc, 0x3653, 0x07da, 0x3645, + 0x3670, 0x07d3, 0x07d0, 0x365c, 0x3758, 0x3757, 0x0886, 0x0887, + 0x08ad, 0x08b7, 0x0958, 0x096a, 0x3bbb, 0x0962, 0x0961, 0x3bbe, + 0x0969, 0x096c, 0x0965, 0x3bb5, 0x3bd3, 0x3b9f, 0x0966, 0x3bb7, + 0x3bf5, 0x3db7, 0x09f5, 0x3dbb, 0x09f4, 0x3dd1, 0x09f7, 0x3dba, + 0x09f8, 0x3db6, 0x3dcc, 0x09fb, 0x09fc, 0x3dd3, 0x409b, 0x0af5, + 0x0af8, 0x4096, 0x40a2, 0x409d, 0x410a, 0x410e, 0x0b3c, 0x4181, + 0x422c, 0x4237, 0x4236, 0x423b, 0x0bc5, 0x42a1, 0x0c62, 0x0c63, + 0x4398, 0x0c67, 0x4396, 0x0c66, 0x0cd9, 0x0cdb, + /* 0x52 */ + 0x44d6, 0x44eb, 0x0cd8, 0x44dc, 0x0d1b, 0x45a5, 0x45a9, 0x6434, + 0x4653, 0x4645, 0x0d79, 0x464f, 0x0d7d, 0x46bd, 0x46bb, 0x46f1, + 0x0e2c, 0x0e37, 0x47ec, 0x47ed, 0x0e30, 0x0e9a, 0x48d3, 0x1600, + 0x48e1, 0x0f05, 0x4a19, 0x0f07, 0x0f09, 0x0f0a, 0x4a27, 0x4a26, + 0x0f79, 0x0fc2, 0x4c6e, 0x4daf, 0x1038, 0x1037, 0x4dad, 0x1021, + 0x4daa, 0x4e18, 0x105e, 0x113d, 0x1137, 0x1140, 0x516f, 0x514c, + 0x111d, 0x5142, 0x1133, 0x515c, 0x5170, 0x515f, 0x1135, 0x515a, + 0x514b, 0x513f, 0x538a, 0x11d8, 0x538b, 0x53a1, 0x538e, 0x11dc, + 0x11de, 0x5399, 0x545e, 0x545f, 0x5524, 0x55a7, 0x56ea, 0x56fd, + 0x56f9, 0x56e3, 0x56e5, 0x12fa, 0x12fb, 0x56ec, 0x133d, 0x133b, + 0x133f, 0x135f, 0x58f2, 0x137f, 0x58ef, 0x1384, 0x59a6, 0x13bc, + 0x1414, 0x140f, 0x5a3b, 0x5a43, 0x140e, 0x5a32, + /* 0x53 */ + 0x5b31, 0x5b30, 0x1460, 0x5b2d, 0x5b3c, 0x5ba7, 0x5ba5, 0x14ab, + 0x14ac, 0x14aa, 0x5d37, 0x5d95, 0x5d8e, 0x1504, 0x5d96, 0x1508, + 0x5f45, 0x5f0a, 0x1533, 0x1534, 0x5efd, 0x5f17, 0x5f1c, 0x5f07, + 0x5f31, 0x5f32, 0x5f2c, 0x5f30, 0x5f03, 0x5f05, 0x15a2, 0x61c2, + 0x15a4, 0x61b8, 0x15a5, 0x61c1, 0x15a7, 0x15a6, 0x15e7, 0x62ab, + 0x62b7, 0x15ff, 0x15fe, 0x6315, 0x6314, 0x161d, 0x161c, 0x630c, + 0x6317, 0x1667, 0x6393, 0x1694, 0x63d2, 0x16c5, 0x16c8, 0x6436, + 0x6431, 0x6433, 0x643c, 0x642e, 0x643a, 0x16c9, 0x643d, 0x16c7, + 0x64b5, 0x6522, 0x6523, 0x6520, 0x651c, 0x651d, 0x176c, 0x65a0, + 0x178a, 0x65ef, 0x65e8, 0x65eb, 0x1788, 0x1787, 0x1786, 0x65e1, + 0x65e6, 0x17cf, 0x17d0, 0x66f8, 0x66f5, 0x181c, 0x1823, 0x6783, + 0x6794, 0x6784, 0x1849, 0x678b, 0x678f, 0x1843, + /* 0x54 */ + 0x678c, 0x1848, 0x6789, 0x1847, 0x678e, 0x1846, 0x183f, 0x1844, + 0x6924, 0x690f, 0x18be, 0x6913, 0x690a, 0x18c2, 0x18ba, 0x18bc, + 0x18c6, 0x692a, 0x691a, 0x18c8, 0x6927, 0x6916, 0x6921, 0x1923, + 0x6a85, 0x6aac, 0x6ac6, 0x6ac5, 0x6ad7, 0x6b53, 0x009d, 0x1d28, + 0x1d27, 0x1ddf, 0x0124, 0x1f35, 0x1fb3, 0x0207, 0x228a, 0x227d, + 0x2289, 0x0279, 0x24cd, 0x24d0, 0x0278, 0x272b, 0x2733, 0x2729, + 0x2735, 0x2731, 0x2737, 0x2836, 0x29be, 0x0419, 0x29b9, 0x041c, + 0x29bb, 0x0418, 0x2de2, 0x2ddb, 0x2ddd, 0x2ddc, 0x2dda, 0x85af, + 0x2dd9, 0x05bd, 0x065d, 0x30df, 0x065a, 0x065e, 0x30e1, 0x065c, + 0x30ee, 0x065b, 0x31b5, 0x32d4, 0x32d5, 0x0721, 0x32d0, 0x32d1, + 0x32ce, 0x32d7, 0x0720, 0x0732, 0x367d, 0x368a, 0x07f2, 0x36a7, + 0x07f5, 0x3699, 0x3682, 0x3688, 0x07ee, 0x07ec, + /* 0x55 */ + 0x3686, 0x07ea, 0x3698, 0x369d, 0x07ed, 0x07f3, 0x368f, 0x07f6, + 0x36aa, 0x0848, 0x375d, 0x0849, 0x380a, 0x0975, 0x3bd7, 0x3bd6, + 0x3be5, 0x096f, 0x097b, 0x0973, 0x3bd9, 0x3bda, 0x3bea, 0x0970, + 0x3bf6, 0x7d39, 0x0978, 0x3de3, 0x09fe, 0x3de9, 0x0a00, 0x3deb, + 0x3def, 0x3df3, 0x3dea, 0x0a01, 0x8621, 0x0a55, 0x0a56, 0x0a9d, + 0x3f71, 0x0af9, 0x40ae, 0x0aff, 0x40b3, 0x0afd, 0x40ac, 0x0b43, + 0x0b41, 0x4183, 0x4245, 0x424e, 0x4244, 0x42a3, 0x42a5, 0x43a6, + 0x43a4, 0x0c6f, 0x43a9, 0x43af, 0x0c8a, 0x0ce5, 0x0ce6, 0x44f0, + 0x44f8, 0x44f1, 0x0d7f, 0x4649, 0x0db5, 0x0db6, 0x0dbb, 0x46c2, + 0x46f2, 0x46f3, 0x47fa, 0x0e40, 0x47f6, 0x47fc, 0x4818, 0x4808, + 0x4812, 0x0e9d, 0x0e9c, 0x48db, 0x48da, 0x0f0f, 0x0f11, 0x0f0d, + 0x4a2c, 0x4a4d, 0x0f14, 0x0f13, 0x4b46, 0x4bf6, + /* 0x56 */ + 0x4c2b, 0x4c74, 0x4db8, 0x4dc8, 0x1082, 0x1083, 0x114d, 0x5192, + 0x5193, 0x114f, 0x517f, 0x51ab, 0x5197, 0x114c, 0x1151, 0x51ac, + 0x11ee, 0x11e8, 0x18cb, 0x53ce, 0x11eb, 0x53cd, 0x11e2, 0x11e6, + 0x53c1, 0x53b1, 0x53c7, 0x11ec, 0x5540, 0x1259, 0x553f, 0x5539, + 0x125d, 0x5543, 0x1257, 0x125b, 0x1256, 0x55ab, 0x12fe, 0x571f, + 0x5709, 0x570c, 0x1300, 0x1301, 0x5840, 0x1342, 0x5896, 0x1360, + 0x58f6, 0x58f7, 0x141d, 0x5a46, 0x5a4f, 0x143e, 0x1469, 0x1465, + 0x5b3d, 0x5b41, 0x5f66, 0x5f78, 0x5f5d, 0x5f69, 0x5f74, 0x5f7d, + 0x5f6e, 0x5f72, 0x5f73, 0x5f62, 0x5f48, 0x5f53, 0x5f5f, 0x5f68, + 0x1538, 0x5f7f, 0x5f6b, 0x15ae, 0x61c4, 0x15ad, 0x62af, 0x62ad, + 0x62b2, 0x1602, 0x161f, 0x631a, 0x631b, 0x1622, 0x1620, 0x86f5, + 0x166c, 0x639b, 0x639f, 0x1668, 0x166d, 0x166e, + /* 0x57 */ + 0x16a0, 0x16ce, 0x16d0, 0x16d1, 0x16cb, 0x6440, 0x16d2, 0x6447, + 0x16d3, 0x64b7, 0x1720, 0x174e, 0x174b, 0x1772, 0x1770, 0x65a2, + 0x1792, 0x178f, 0x6600, 0x65f3, 0x1790, 0x8437, 0x65f5, 0x17d9, + 0x17d5, 0x66bd, 0x6700, 0x6702, 0x17fa, 0x6734, 0x6749, 0x679f, + 0x184b, 0x67a3, 0x67cd, 0x6799, 0x679d, 0x18d0, 0x18ce, 0x6939, + 0x18cf, 0x6944, 0x18c4, 0x18cc, 0x6935, 0x18d2, 0x1935, 0x6aaf, + 0x0a03, 0x1d2f, 0x009e, 0x00af, 0x6b8e, 0x020c, 0x229f, 0x229b, + 0x229e, 0x2296, 0x2294, 0x22a0, 0x027c, 0x273b, 0x0330, 0x0331, + 0x273a, 0x29c1, 0x2b4d, 0x2b5d, 0x2df3, 0x05a1, 0x059e, 0x0668, + 0x0661, 0x30f6, 0x30e5, 0x30ea, 0x30e7, 0x3105, 0x0665, 0x30f9, + 0x0666, 0x066a, 0x06ab, 0x36ab, 0x36ed, 0x36b2, 0x36b0, 0x36b5, + 0x36be, 0x36c1, 0x36c8, 0x07f9, 0x36c0, 0x36bc, + /* 0x58 */ + 0x36b1, 0x36c4, 0x36bf, 0x0858, 0x088a, 0x3c08, 0x3c03, 0x3bfd, + 0x3c10, 0x3c02, 0x3c13, 0x0a04, 0x3dfa, 0x3e00, 0x40b9, 0x40bc, + 0x0b02, 0x425b, 0x4251, 0x424f, 0x42eb, 0x43b8, 0x0c79, 0x43b9, + 0x43c1, 0x43c0, 0x43be, 0x450b, 0x0ceb, 0x4507, 0x450a, 0x4508, + 0x0ce9, 0x450d, 0x4506, 0x4515, 0x45af, 0x0d20, 0x0d21, 0x0d81, + 0x46f5, 0x0e4d, 0x0e59, 0x482e, 0x0e58, 0x481b, 0x81d1, 0x481a, + 0x4824, 0x0ea5, 0x0ea9, 0x48e6, 0x48e3, 0x0f1a, 0x0f19, 0x4a5d, + 0x4a4f, 0x4a66, 0x4a5b, 0x4b47, 0x4bb4, 0x0f96, 0x0f98, 0x0f97, + 0x4bfa, 0x4c2e, 0x82df, 0x0fc8, 0x4dce, 0x1043, 0x1045, 0x4e19, + 0x1152, 0x1157, 0x51cc, 0x51b2, 0x1155, 0x51bb, 0x51c1, 0x1156, + 0x1158, 0x11f2, 0x53e9, 0x53ee, 0x53f0, 0x53d6, 0x540e, 0x53da, + 0x5548, 0x554a, 0x554e, 0x554d, 0x55b1, 0x55b0, + /* 0x59 */ + 0x55b3, 0x1307, 0x5738, 0x5732, 0x1308, 0x572d, 0x130a, 0x5734, + 0x0f1b, 0x5729, 0x5874, 0x1361, 0x1362, 0x5903, 0x13c2, 0x13c6, + 0x59a9, 0x5a58, 0x141e, 0x1425, 0x5abf, 0x5ac1, 0x5b4a, 0x5bac, + 0x14b0, 0x5c89, 0x5d3d, 0x5d3c, 0x5da9, 0x5fa0, 0x153d, 0x5f90, + 0x153e, 0x5f93, 0x5f8b, 0x5fad, 0x5fbb, 0x5fb8, 0x1546, 0x1545, + 0x5f9c, 0x61d8, 0x61d7, 0x1603, 0x1626, 0x1627, 0x635d, 0x63a9, + 0x63da, 0x1698, 0x16ad, 0x16d5, 0x16da, 0x6454, 0x16d9, 0x6455, + 0x644b, 0x16dd, 0x643f, 0x64b9, 0x1715, 0x1716, 0x1717, 0x1721, + 0x6538, 0x6536, 0x6540, 0x174c, 0x653b, 0x6539, 0x65a4, 0x1796, + 0x1798, 0x6608, 0x660c, 0x179b, 0x6610, 0x17ff, 0x6707, 0x1825, + 0x67d2, 0x184f, 0x67c2, 0x67bb, 0x67cc, 0x67cb, 0x1856, 0x1854, + 0x694d, 0x6963, 0x694e, 0x18d8, 0x6950, 0x6955, + /* 0x5a */ + 0x18d7, 0x695e, 0x1926, 0x6a90, 0x6ab2, 0x6ab1, 0x1938, 0x6aca, + 0x6b02, 0x6b27, 0x6b26, 0x198a, 0x22af, 0x24e0, 0x24dc, 0x0334, + 0x2739, 0x0335, 0x856a, 0x277c, 0x27f3, 0x8570, 0x03a1, 0x286b, + 0x29c4, 0x310b, 0x3108, 0x310a, 0x066c, 0x066d, 0x31dc, 0x0729, + 0x072a, 0x32e1, 0x32df, 0x36ce, 0x36d4, 0x36e3, 0x36d7, 0x36e2, + 0x0800, 0x0808, 0x0806, 0x0805, 0x36d8, 0x36d5, 0x36d2, 0x08b1, + 0x0988, 0x3c1e, 0x3c2c, 0x3c25, 0x3bf3, 0x3e04, 0x3e08, 0x3e15, + 0x0a09, 0x40c4, 0x40c9, 0x40c7, 0x40c8, 0x42a9, 0x43c6, 0x43c5, + 0x4518, 0x451a, 0x4520, 0x0d22, 0x4666, 0x4664, 0x466a, 0x0dd5, + 0x0e61, 0x0e5d, 0x0e62, 0x0e4f, 0x0e60, 0x4835, 0x4834, 0x0eaa, + 0x0f22, 0x4a6c, 0x0f21, 0x4a6e, 0x4a71, 0x1046, 0x4dd4, 0x4dd6, + 0x4e1a, 0x4e62, 0x4e65, 0x4e76, 0x51db, 0x51d6, + /* 0x5b */ + 0x1162, 0x51e7, 0x1160, 0x1164, 0x51f4, 0x86b6, 0x53fd, 0x53d5, + 0x5407, 0x11f6, 0x540f, 0x53f8, 0x86c1, 0x1219, 0x5587, 0x1291, + 0x55b5, 0x55f5, 0x130d, 0x573f, 0x5743, 0x574c, 0x1365, 0x590b, + 0x5a6b, 0x5a68, 0x5a70, 0x5a75, 0x5a77, 0x143f, 0x5ac3, 0x154b, + 0x5fe9, 0x5fea, 0x5fcb, 0x5fc5, 0x5fc6, 0x1548, 0x5fed, 0x5fd3, + 0x1552, 0x5fe5, 0x154a, 0x1551, 0x5fdb, 0x5feb, 0x5fe0, 0x5fc1, + 0x1550, 0x154c, 0x61dd, 0x15ee, 0x1604, 0x1606, 0x162d, 0x162e, + 0x162f, 0x167b, 0x1678, 0x1677, 0x63b2, 0x63b4, 0x63b1, 0x63b5, + 0x63f2, 0x16a2, 0x16a1, 0x16e3, 0x6456, 0x171a, 0x1719, 0x1757, + 0x6544, 0x179e, 0x6626, 0x661f, 0x6618, 0x6621, 0x6617, 0x17dd, + 0x6709, 0x1805, 0x1828, 0x67c5, 0x67df, 0x1860, 0x67e3, 0x1866, + 0x67e9, 0x67ee, 0x1867, 0x1868, 0x6966, 0x697a, + /* 0x5c */ + 0x18de, 0x696e, 0x6991, 0x6983, 0x6976, 0x697e, 0x696d, 0x18e1, + 0x6a95, 0x6ae3, 0x1969, 0x1977, 0x6b03, 0x6b04, 0x8719, 0x6b17, + 0x00a6, 0x1d36, 0x00a5, 0x1f36, 0x0214, 0x2742, 0x0336, 0x0338, + 0x2744, 0x2746, 0x277e, 0x29ca, 0x29c8, 0x29cc, 0x2af0, 0x0670, + 0x3185, 0x32e5, 0x32e7, 0x072b, 0x0811, 0x080a, 0x36f4, 0x080d, + 0x36e9, 0x0816, 0x0810, 0x0809, 0x080e, 0x087a, 0x3c3d, 0x098c, + 0x3c36, 0x0991, 0x3e16, 0x0a0a, 0x3e12, 0x3e0f, 0x3e17, 0x3e11, + 0x3e0b, 0x0a08, 0x0a0b, 0x40cd, 0x40d0, 0x40cc, 0x40ce, 0x40d1, + 0x0b07, 0x4189, 0x0cf2, 0x466f, 0x484b, 0x4844, 0x4855, 0x0eae, + 0x0f24, 0x0f26, 0x0f27, 0x4a7f, 0x5771, 0x0f99, 0x4c2f, 0x4c7a, + 0x4c7b, 0x4c7c, 0x115f, 0x116a, 0x1171, 0x51fc, 0x5210, 0x5202, + 0x116c, 0x116f, 0x51ee, 0x5203, 0x1168, 0x520d, + /* 0x5d */ + 0x5213, 0x5208, 0x520f, 0x5418, 0x5412, 0x1201, 0x1268, 0x5567, + 0x5565, 0x55bb, 0x5769, 0x5762, 0x1313, 0x576e, 0x1316, 0x5761, + 0x1318, 0x5764, 0x574d, 0x5851, 0x1389, 0x13c8, 0x5a83, 0x5ac6, + 0x1484, 0x601f, 0x1554, 0x6004, 0x6017, 0x6008, 0x6005, 0x1556, + 0x5ff3, 0x601e, 0x6002, 0x601a, 0x601b, 0x6027, 0x601c, 0x155a, + 0x62b5, 0x1605, 0x1607, 0x6333, 0x1631, 0x6334, 0x6331, 0x63b8, + 0x63ba, 0x16a3, 0x63fc, 0x16eb, 0x171c, 0x64c3, 0x175a, 0x654d, + 0x175b, 0x662f, 0x17a6, 0x17aa, 0x17a5, 0x66c9, 0x17e1, 0x66c8, + 0x66c4, 0x672a, 0x6738, 0x6750, 0x182a, 0x680a, 0x67fb, 0x6804, + 0x67fc, 0x67fe, 0x1872, 0x186f, 0x1873, 0x6802, 0x67f6, 0x681b, + 0x67f9, 0x6815, 0x6810, 0x67ff, 0x6800, 0x680c, 0x186b, 0x18e6, + 0x6995, 0x69a5, 0x18e9, 0x18ec, 0x18e8, 0x18f0, + /* 0x5e */ + 0x6a98, 0x6ac1, 0x198c, 0x6b5a, 0x1d64, 0x22bb, 0x0215, 0x24e6, + 0x2749, 0x27f7, 0x0371, 0x0426, 0x29d0, 0x04c6, 0x2bc2, 0x05a8, + 0x3111, 0x0673, 0x36ff, 0x36fe, 0x36fd, 0x0815, 0x3701, 0x0998, + 0x0997, 0x3c4b, 0x3c4d, 0x3c47, 0x40d3, 0x4268, 0x4267, 0x0bd7, + 0x0c80, 0x43d1, 0x4530, 0x4532, 0x452e, 0x0d88, 0x6b9d, 0x46c9, + 0x46c8, 0x0e69, 0x4856, 0x4851, 0x0e6b, 0x0f29, 0x0f28, 0x4a85, + 0x4a89, 0x4a8e, 0x4a84, 0x105f, 0x4e6a, 0x522b, 0x522f, 0x5228, + 0x1174, 0x5216, 0x5215, 0x521d, 0x541a, 0x1202, 0x126a, 0x1294, + 0x55bc, 0x5775, 0x577c, 0x138a, 0x5911, 0x5912, 0x5b5c, 0x5dbb, + 0x1564, 0x5ff4, 0x155e, 0x1561, 0x602d, 0x1565, 0x1566, 0x62e4, + 0x6337, 0x6336, 0x6367, 0x63be, 0x63bd, 0x63e2, 0x6468, 0x6466, + 0x64c8, 0x64ca, 0x64c7, 0x64dc, 0x175f, 0x654f, + /* 0x5f */ + 0x65a9, 0x663c, 0x17af, 0x663b, 0x66ce, 0x180d, 0x6714, 0x6753, + 0x187c, 0x682e, 0x187a, 0x681f, 0x1876, 0x1879, 0x187d, 0x1877, + 0x69b0, 0x69bd, 0x18f6, 0x18f1, 0x69ae, 0x69c4, 0x6a7b, 0x0c0b, + 0x1929, 0x6a9e, 0x196f, 0x6b05, 0x199a, 0x6b69, 0x6ba1, 0x22c7, + 0x231d, 0x274a, 0x29d3, 0x0469, 0x2b72, 0x2e02, 0x05ab, 0x2e35, + 0x3127, 0x311e, 0x311f, 0x072c, 0x072d, 0x3707, 0x3706, 0x0817, + 0x099a, 0x3c54, 0x3e1c, 0x3e20, 0x46f8, 0x0e6e, 0x485d, 0x4858, + 0x0f2c, 0x4a92, 0x4b4e, 0x0fca, 0x1178, 0x1206, 0x5427, 0x1207, + 0x5781, 0x5783, 0x1320, 0x5844, 0x1353, 0x13ce, 0x147a, 0x1479, + 0x6042, 0x604d, 0x6054, 0x604e, 0x156b, 0x6043, 0x1567, 0x156d, + 0x633c, 0x6340, 0x63c0, 0x1685, 0x16b0, 0x16f3, 0x1763, 0x655a, + 0x6651, 0x17b6, 0x66dd, 0x1882, 0x187f, 0x6838, + /* 0x60 */ + 0x1886, 0x6845, 0x683a, 0x1884, 0x6835, 0x18fc, 0x18fd, 0x18fa, + 0x6af1, 0x1987, 0x6b93, 0x1e9a, 0x021a, 0x0219, 0x5241, 0x29d7, + 0x0675, 0x3128, 0x081a, 0x081b, 0x0819, 0x3c53, 0x3c59, 0x099c, + 0x3e21, 0x0a10, 0x426f, 0x4537, 0x45b5, 0x4862, 0x485e, 0x48f5, + 0x117b, 0x117c, 0x523d, 0x1208, 0x542d, 0x5589, 0x578d, 0x5787, + 0x5790, 0x591a, 0x5a99, 0x1441, 0x14e3, 0x1572, 0x605f, 0x1573, + 0x1568, 0x6056, 0x6061, 0x605b, 0x605a, 0x605c, 0x6065, 0x1635, + 0x6341, 0x1688, 0x169d, 0x646e, 0x646c, 0x646d, 0x0e75, 0x65aa, + 0x665c, 0x6658, 0x66de, 0x188f, 0x684f, 0x6851, 0x188e, 0x6853, + 0x1905, 0x1904, 0x18ff, 0x69fc, 0x6b39, 0x199e, 0x1d3e, 0x0154, + 0x22d2, 0x0281, 0x274f, 0x3714, 0x0cfa, 0x4672, 0x4673, 0x0f32, + 0x1270, 0x126e, 0x5791, 0x86d6, 0x147c, 0x5dbf, + /* 0x61 */ + 0x1575, 0x606c, 0x1574, 0x1577, 0x62e6, 0x6345, 0x1637, 0x63c8, + 0x63e4, 0x655d, 0x17ba, 0x6721, 0x1811, 0x672c, 0x6757, 0x1892, + 0x1899, 0x685d, 0x6861, 0x6865, 0x6a08, 0x190a, 0x192a, 0x192b, + 0x1944, 0x1979, 0x6b45, 0x00aa, 0x0348, 0x2e05, 0x32ef, 0x371b, + 0x371d, 0x3e25, 0x3e24, 0x486d, 0x0eb4, 0x5242, 0x5249, 0x120d, + 0x5578, 0x558a, 0x5797, 0x1354, 0x589b, 0x591c, 0x1430, 0x5aa2, + 0x1609, 0x1638, 0x1636, 0x168b, 0x16f7, 0x1766, 0x17bd, 0x181e, + 0x686c, 0x1896, 0x686f, 0x190d, 0x6a0e, 0x1973, 0x6b08, 0x6b1d, + 0x6ba3, 0x033b, 0x033c, 0x2b60, 0x371c, 0x09a0, 0x0cfb, 0x6cfd, + 0x48f3, 0x1181, 0x579b, 0x5aa7, 0x5dc4, 0x1578, 0x607a, 0x168d, + 0x1773, 0x6661, 0x6663, 0x66d7, 0x6876, 0x19a6, 0x6ba5, 0x05ad, + 0x3c67, 0x0a11, 0x3eab, 0x524a, 0x557d, 0x579d, + /* 0x62 */ + 0x5853, 0x5b65, 0x607b, 0x1639, 0x64cd, 0x64dd, 0x17bf, 0x6730, + 0x6a16, 0x190f, 0x19a7, 0x19b5, 0x0bdc, 0x1431, 0x62e7, 0x6a18, + 0x6aa2, 0x19a8, 0x6b7c, 0x0d25, 0x4a9e, 0x6084, 0x17c1, 0x6a1c, + 0x0d90, 0x4871, 0x63ca, 0x1296, 0x147f, 0x1910, 0x6aa3, 0x160a, + 0x687b, 0x6b97, 0x1912, 0x163a, 0x6350, 0x163b, +}; +static const unsigned short cns11643_3_2uni_page64[292] = { + /* 0x64 */ + 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, + 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, + 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, + 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, + 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x6cfd, 0x1b66, + 0x1b68, 0x1be7, 0x1c3f, 0x6cfd, 0x1ca6, 0x1d0f, 0x1e3e, 0x1f24, + 0x1f65, 0x1f9b, 0x1d7f, 0x20cb, 0x2173, 0x2171, 0x216b, 0x21f4, + 0x2222, 0x2220, 0x2292, 0x22ba, 0x2291, 0x22b0, 0x2359, 0x238a, + 0x240f, 0x2412, 0x2413, 0x2447, 0x249b, 0x2500, 0x254d, 0x26d1, + 0x26d3, 0x2767, 0x2857, 0x2877, 0x28d5, 0x2975, 0x298e, 0x29a5, + 0x29b6, 0x29bf, 0x2a65, 0x2acd, 0x2aed, 0x2b94, 0x2b9a, 0x2bba, + 0x2d25, 0x2d50, 0x2ea3, 0x2f60, 0x2f64, 0x2fb6, + /* 0x65 */ + 0x3003, 0x30b6, 0x311a, 0x4625, 0x2821, 0x32e2, 0x3302, 0x33a4, + 0x33ac, 0x3410, 0x3406, 0x345e, 0x345a, 0x352c, 0x3529, 0x362d, + 0x3677, 0x367a, 0x36ca, 0x36e6, 0x36f5, 0x370d, 0x370e, 0x37dc, + 0x37dd, 0x37f6, 0x381e, 0x3863, 0x39a5, 0x3a0f, 0x3a8a, 0x3a84, + 0x3a8b, 0x3a7c, 0x3b4c, 0x3b48, 0x3b49, 0x3b9d, 0x3b99, 0x3bf8, + 0x3c2e, 0x3c2d, 0x3c5c, 0x45cc, 0x3cbf, 0x3cea, 0x3ce5, 0x3d11, + 0x3d12, 0x3d3f, 0x3d39, 0x3d3b, 0x3d3d, 0x3d77, 0x3d75, 0x3d76, + 0x3d71, 0x3d96, 0x3d93, 0x3db4, 0x3ddd, 0x3dde, 0x3e0e, 0x2511, + 0x3e18, 0x3f47, 0x3f48, 0x3fef, 0x4012, 0x403b, 0x40a4, 0x408d, + 0x40b4, 0x4273, 0x4277, 0x42bc, 0x4419, 0x441b, 0x443d, 0x4453, + 0x4454, 0x4458, 0x44b7, 0x44d8, 0x44ee, 0x4522, 0x454d, 0x4586, + 0x4599, 0x45a3, 0x45bc, 0x46a7, 0x4737, 0x4759, + /* 0x66 */ + 0x47d0, 0x482f, 0x4832, 0x4842, 0x484e, 0x4868, 0x48a9, 0x48ed, + 0x49d0, 0x4a07, 0x49d3, 0x4a64, 0x4b40, 0x6cfd, 0x4c41, 0x4c63, + 0x4cbb, 0x3311, 0x3325, 0x4e48, 0x4f10, 0x4f62, 0x4f12, 0x5021, + 0x501e, 0x50e2, 0x50de, 0x50e1, 0x5173, 0x51d4, 0x51f5, 0x5237, + 0x5245, 0x5272, 0x534a, 0x53a9, 0x53a5, 0x53f5, 0x5434, 0x5450, + 0x5487, 0x5554, 0x5584, 0x5703, 0x5852, 0x58d8, 0x590c, 0x5918, + 0x59b0, 0x5abc, 0x5ad5, 0x5baa, 0x5c9c, 0x6cfd, 0x5d5c, 0x5e2b, + 0x5e21, 0x5e73, 0x5ef4, 0x5ef5, 0x5f3f, 0x5f42, 0x5f86, 0x5fbe, + 0x5fbc, 0x5fbd, 0x5ff1, 0x5ff2, 0x5fef, 0x6022, 0x6023, 0x6024, + 0x6067, 0x6066, 0x6197, 0x61ce, 0x61e7, 0x633b, 0x634d, 0x64e4, + 0x6542, 0x671d, 0x6798, 0x6cfd, 0x6949, 0x3049, 0x2a71, 0x2a85, + 0x2dd3, 0x650e, 0x4c02, 0x441e, 0x6cfd, 0x6cfd, + /* 0x67 */ + 0x2128, 0x2172, 0x21ba, 0x21f0, 0x21ee, 0x22b8, 0x22b9, 0x22c4, + 0x4c53, 0x5eb0, +}; + +static const ucs4_t cns11643_3_2uni_upages[136] = { + 0x03400, 0x03500, 0x03600, 0x03700, 0x03800, 0x03900, 0x03a00, 0x03b00, + 0x03c00, 0x03d00, 0x03e00, 0x03f00, 0x04000, 0x04100, 0x04200, 0x04300, + 0x04400, 0x04500, 0x04600, 0x04700, 0x04800, 0x04900, 0x04a00, 0x04b00, + 0x04c00, 0x04d00, 0x04e00, 0x04f00, 0x05000, 0x05100, 0x05200, 0x05300, + 0x05400, 0x05500, 0x05600, 0x05700, 0x05800, 0x05900, 0x05a00, 0x05b00, + 0x05c00, 0x05d00, 0x05e00, 0x05f00, 0x06000, 0x06100, 0x06200, 0x06300, + 0x06400, 0x06500, 0x06600, 0x06700, 0x06800, 0x06900, 0x06a00, 0x06b00, + 0x06c00, 0x06d00, 0x06e00, 0x06f00, 0x07000, 0x07100, 0x07200, 0x07300, + 0x07400, 0x07500, 0x07600, 0x07700, 0x07800, 0x07900, 0x07a00, 0x07b00, + 0x07c00, 0x07d00, 0x07e00, 0x07f00, 0x08000, 0x08100, 0x08200, 0x08300, + 0x08400, 0x08500, 0x08600, 0x08700, 0x08800, 0x08900, 0x08a00, 0x08b00, + 0x08c00, 0x08d00, 0x08e00, 0x08f00, 0x09000, 0x09100, 0x09200, 0x09300, + 0x09400, 0x09500, 0x09600, 0x09700, 0x09800, 0x09900, 0x09a00, 0x09b00, + 0x09c00, 0x09d00, 0x09e00, 0x09f00, 0x0ff00, 0x20000, 0x20100, 0x20200, + 0x20500, 0x20600, 0x20b00, 0x20d00, 0x21300, 0x21600, 0x21700, 0x21d00, + 0x22300, 0x22500, 0x23000, 0x23500, 0x23c00, 0x24000, 0x24a00, 0x25100, + 0x25900, 0x25c00, 0x26500, 0x28c00, 0x29900, 0x2f800, 0x2f900, 0x2fa00, +}; + +static int +cns11643_3_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x21 && c1 <= 0x62) || (c1 >= 0x64 && c1 <= 0x67)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + ucs4_t wc = 0xfffd; + unsigned short swc; + if (i < 6298) { + if (i < 6148) + swc = cns11643_3_2uni_page21[i], + wc = cns11643_3_2uni_upages[swc>>8] | (swc & 0xff); + } else { + if (i < 6590) + swc = cns11643_3_2uni_page64[i-6298], + wc = cns11643_3_2uni_upages[swc>>8] | (swc & 0xff); + } + if (wc != 0xfffd) { + *pwc = wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + diff --git a/graf2d/win32gdk/gdk/src/iconv/cns11643_4.h b/graf2d/win32gdk/gdk/src/iconv/cns11643_4.h new file mode 100644 index 0000000000000..e7259920b5468 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cns11643_4.h @@ -0,0 +1,61 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CNS 11643-1992 plane 4 + */ + +/* + * The table has been split into two parts. Each part's entries fit it 16 bits. + * But the combined table would need 17 bits per entry. + */ +#include "cns11643_4a.h" +#include "cns11643_4b.h" + +static int +cns11643_4_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x21 && c1 <= 0x6e)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + ucs4_t wc = 0xfffd; + unsigned short swc; + { + if (i < 2914) + swc = cns11643_4a_2uni_page21[i], + wc = cns11643_4a_2uni_upages[swc>>8] | (swc & 0xff); + else if (i < 7298) + swc = cns11643_4b_2uni_page40[i-2914], + wc = cns11643_4b_2uni_upages[swc>>8] | (swc & 0xff); + } + if (wc != 0xfffd) { + *pwc = wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cns11643_4a.h b/graf2d/win32gdk/gdk/src/iconv/cns11643_4a.h new file mode 100644 index 0000000000000..ee81576a7afa2 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cns11643_4a.h @@ -0,0 +1,460 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CNS 11643-1992 plane 4 part a + */ + +static const unsigned short cns11643_4a_2uni_page21[2914] = { + /* 0x21 */ + 0x5a86, 0x1840, 0x1841, 0x185a, 0x75e8, 0x1802, 0x1829, 0x5b0e, + 0x6027, 0x1c02, 0x013e, 0x27dc, 0x5f3c, 0x6075, 0xd128, 0x1d42, + 0x1d6a, 0x2552, 0x6f3c, 0xd175, 0xd178, 0x29c4, 0x2c4c, 0x39ad, + 0x1812, 0x182f, 0x1896, 0x18d0, 0x1b42, 0x1b83, 0xd119, 0x60a5, + 0x60aa, 0x630f, 0x640e, 0x1d83, 0x1db8, 0x659c, 0x659b, 0x6a3c, + 0x2328, 0x71c2, 0x2623, 0x2801, 0x2900, 0x87b4, 0x08b8, 0x376c, + 0x392b, 0x1b88, 0x4879, 0x51b6, 0x1817, 0x5a65, 0x000c, 0x5bb2, + 0x0030, 0x18e2, 0x18db, 0x5e77, 0x5f42, 0x1bad, 0x6033, 0x1bf7, + 0x00da, 0x60af, 0x6236, 0x0113, 0x1d1b, 0x1d88, 0x1d87, 0x6522, + 0x1dcf, 0x1dfd, 0x0163, 0x1de7, 0x20dc, 0x69a3, 0x20d9, 0x2125, + 0x2127, 0x2333, 0x2613, 0x7225, 0x7224, 0x2675, 0x7652, 0x7789, + 0x7abf, 0x05c4, 0x05c3, 0x2ff1, 0x87b5, 0xa24c, + /* 0x22 */ + 0x4552, 0xc714, 0xc712, 0x0001, 0x5aa3, 0x5aa2, 0x1851, 0x186a, + 0x5bb6, 0x190c, 0x5bb5, 0x5bb4, 0x18fe, 0x191b, 0x5bc2, 0x5bb8, + 0x003a, 0x5e79, 0x00ab, 0x1b73, 0x5f08, 0x1b8e, 0x5f7a, 0x5fb6, + 0x60bd, 0x60b7, 0x60bc, 0x00dd, 0x60c4, 0x60c9, 0x1ca5, 0x0115, + 0x1ca7, 0x1ca4, 0x6330, 0x6383, 0x6385, 0x6412, 0x6434, 0x1dbd, + 0x64e4, 0x64de, 0x652a, 0x1e02, 0x65af, 0x65b4, 0x65b3, 0x65b1, + 0x212b, 0x231b, 0x2335, 0x6cde, 0x02a7, 0x02a5, 0x6db8, 0x6db0, + 0x02a6, 0x6fc2, 0x59fd, 0x2617, 0x037c, 0x722a, 0x2670, 0x267d, + 0x03a9, 0x75e9, 0x27e9, 0x7657, 0x0434, 0x0435, 0x77b6, 0x77d7, + 0x77de, 0x04a8, 0x2919, 0x291c, 0x2975, 0x7ac2, 0x7bab, 0x04ff, + 0x29c8, 0x7e8f, 0x05c7, 0x05c6, 0x05c8, 0x7f6d, 0x82b5, 0x06d0, + 0x06d1, 0x87c0, 0x87bf, 0x0859, 0x8bb9, 0x8d1c, + /* 0x23 */ + 0x3412, 0x08bd, 0x8e80, 0x9184, 0x9185, 0x0a28, 0x39b3, 0x9524, + 0x0aa9, 0x3a90, 0x3c36, 0xaa4c, 0x0fcc, 0xb1f6, 0x4881, 0x51b8, + 0xc370, 0x14b4, 0xc375, 0xc717, 0x1823, 0x0016, 0x002c, 0x5bf1, + 0x192e, 0x5bda, 0x1b4f, 0x5fb9, 0x1bba, 0x00df, 0x00e0, 0x1c22, + 0x60ce, 0x60d2, 0x60d0, 0x0117, 0x6243, 0x1caf, 0x1cb0, 0x1cb1, + 0x624d, 0x6334, 0x012f, 0x63d9, 0x1d64, 0x6418, 0x1dd3, 0x6538, + 0x016a, 0x65d7, 0x0170, 0x016d, 0x65dc, 0x65cb, 0x65d6, 0x65d8, + 0x016e, 0x65d1, 0xd13e, 0xd13c, 0x65d2, 0x022b, 0x0228, 0x6a59, + 0x59fd, 0x233f, 0x6ce5, 0x6ce6, 0x0292, 0x6ce8, 0x238b, 0x6dbd, + 0x2391, 0x2395, 0x6dbe, 0x6f49, 0x033f, 0x6fcd, 0x258a, 0x034f, + 0x0374, 0x715e, 0x71d0, 0x037d, 0x7306, 0x03b7, 0x03a3, 0x03b0, + 0x03b1, 0x2687, 0x03ab, 0x737c, 0x7371, 0x75ef, + /* 0x24 */ + 0x043a, 0x0437, 0x280d, 0x0438, 0x0440, 0x778d, 0x77b7, 0x288e, + 0x049f, 0x7933, 0x797f, 0x297a, 0x7bf2, 0x0504, 0x0509, 0x0506, + 0x04fd, 0x050a, 0x0507, 0x7f2a, 0x7f8b, 0x05ca, 0x7f83, 0x7f8a, + 0x2c90, 0x05c9, 0x7f8e, 0x2c9a, 0x82b6, 0x2e3c, 0x2e3a, 0x067f, + 0x2e98, 0x84d8, 0x06d2, 0x8556, 0x87d2, 0x3065, 0xd1db, 0x0743, + 0x87c2, 0x8a87, 0x8a81, 0x8bc2, 0x8bbc, 0x8d23, 0x08c1, 0x8e93, + 0x08c5, 0x09a3, 0x918d, 0x918e, 0x0a2a, 0x0a5f, 0x953b, 0x954d, + 0x0a5d, 0x9534, 0x9531, 0x96f2, 0x96f0, 0x0b17, 0x9a15, 0x9b28, + 0x0b71, 0x0b72, 0x9c25, 0x9de7, 0x0c0f, 0x9de9, 0xa017, 0x40c2, + 0x0d91, 0xa96c, 0xa980, 0xaa4b, 0x0fb2, 0x0fcf, 0x0fce, 0x469e, + 0xafde, 0xaffb, 0x47eb, 0xb051, 0x4889, 0x1096, 0xb201, 0xb202, + 0x4896, 0xb205, 0x4887, 0xb203, 0x1097, 0xc151, + /* 0x25 */ + 0x51c0, 0x148b, 0x51c3, 0xc153, 0xc37a, 0xc378, 0xc376, 0xc379, + 0xc38f, 0xc37c, 0x5578, 0xc71b, 0xc71c, 0x5625, 0x8f92, 0x1875, + 0x1874, 0x5b2e, 0x5b2c, 0x002d, 0x5c0c, 0x1999, 0x5c0b, 0x0050, + 0x004b, 0x5c05, 0x004f, 0x004c, 0xd105, 0x1971, 0x1b53, 0x1bbf, + 0x5fc2, 0x5fc3, 0x1bc0, 0x6048, 0x1bee, 0x6046, 0x00e4, 0x00e3, + 0x60ea, 0x00e1, 0x60eb, 0x00e2, 0x60ee, 0x1c3d, 0x0119, 0x1cbd, + 0x1d0c, 0x62d8, 0x9a1e, 0x63df, 0x63de, 0x0141, 0x4537, 0x644f, + 0x1dc0, 0x015e, 0x660d, 0x6608, 0x0179, 0x6609, 0x1e6e, 0x1e83, + 0x6612, 0x6665, 0x1e5e, 0x1e5d, 0x217e, 0x2179, 0x6a89, 0x217a, + 0x216c, 0x6a84, 0x6a9e, 0x6a8b, 0x0232, 0x2187, 0x6c62, 0x231d, + 0x0294, 0x2346, 0x0297, 0x6cf9, 0x2343, 0x6cf7, 0x0296, 0x0298, + 0x6d06, 0x6ddd, 0x02b2, 0x6dd9, 0x6ddf, 0x6de2, + /* 0x26 */ + 0x02b9, 0x2561, 0x2566, 0x5af1, 0x2590, 0x0375, 0x037f, 0x037e, + 0x2629, 0x038f, 0x723f, 0x723e, 0x730b, 0x03bd, 0x26b2, 0x7383, + 0x03bb, 0x03bc, 0x7386, 0x26c0, 0x767c, 0x043d, 0x043e, 0x0474, + 0x77f7, 0x047a, 0x0476, 0x0478, 0x0475, 0x77fb, 0x793b, 0x04af, + 0x04b0, 0x04c7, 0x04cc, 0x7bf9, 0x7bca, 0x0516, 0x7bff, 0x0512, + 0x051d, 0x7c09, 0x7c03, 0x0515, 0x050f, 0x0514, 0x2a1f, 0x29e2, + 0x7c10, 0x7e9a, 0x7e9f, 0x05b0, 0x05bf, 0x05c0, 0x7f87, 0x05d2, + 0x05d9, 0x82b7, 0x067a, 0x8308, 0x82f9, 0x0681, 0x0682, 0x82f4, + 0x2f16, 0x2ef9, 0x06da, 0xad57, 0x3088, 0x87d6, 0x309b, 0xd1de, + 0x306e, 0x309e, 0x87d4, 0x0822, 0x081f, 0x8a90, 0x8a8d, 0x0821, + 0x3324, 0x8b60, 0x8bce, 0x8bcf, 0x085c, 0x337d, 0x8bd1, 0x087d, + 0x088d, 0x088f, 0x34e6, 0x8eca, 0x34cb, 0x08d0, + /* 0x27 */ + 0x8eb7, 0x08d8, 0x8eb2, 0x8ebb, 0x8eb9, 0x34b5, 0x09a7, 0x919e, + 0x3797, 0x91b2, 0x379b, 0x0a12, 0x936f, 0x93ac, 0x0a2f, 0x9423, + 0x396b, 0x0a2e, 0x0a2c, 0x0a5c, 0x956c, 0x39d5, 0x9532, 0x955e, + 0x0a62, 0x0a67, 0x0ab4, 0x96fb, 0x9929, 0x99bd, 0x9a1f, 0x3c43, + 0x7941, 0x9a1d, 0x3c9c, 0x9b31, 0x9b2f, 0x0bea, 0x9d43, 0x0bfb, + 0x9d41, 0x0c14, 0x9df5, 0x0c13, 0x0c12, 0x0c10, 0x0c11, 0x9df2, + 0x0c86, 0x3ee4, 0x0c98, 0xa01e, 0xa254, 0x0d2a, 0xa256, 0xa329, + 0xa327, 0xa328, 0x41ce, 0x0eb5, 0xa979, 0xa97e, 0xabb6, 0xabb7, + 0x4613, 0x0fd6, 0x0fd8, 0x46b7, 0x0fd9, 0x0fd4, 0x0fd7, 0xd281, + 0x46b9, 0x59fd, 0xad4d, 0x47e4, 0x47fd, 0x480f, 0x1060, 0xb109, + 0xb108, 0x109e, 0x10a1, 0xb21e, 0xb21a, 0xb223, 0xb215, 0xb219, + 0xb216, 0x48bf, 0x48ca, 0xb214, 0xb218, 0x48c1, + /* 0x28 */ + 0x10a0, 0xb51f, 0xb6dd, 0xb6df, 0xc169, 0x51d0, 0x59fd, 0xc16c, + 0x14b9, 0xc393, 0x52ae, 0xc395, 0xc394, 0xc391, 0xc397, 0xc730, + 0x15c1, 0x15c2, 0x5638, 0xd318, 0x001c, 0x5c31, 0x005e, 0x19bc, + 0x0059, 0x005c, 0x5c36, 0x005f, 0x19e9, 0x19bd, 0x19e2, 0x1b58, + 0x5fc9, 0x5fca, 0x00ce, 0x6118, 0x6112, 0x6119, 0x6110, 0x6116, + 0x1cc6, 0x625f, 0x1cc8, 0x62df, 0x6317, 0x1d28, 0x633c, 0x1d29, + 0x63ea, 0x63e9, 0x641c, 0x6458, 0x6464, 0x64f3, 0x015f, 0x6697, + 0x0185, 0x665a, 0x6659, 0x0186, 0x668e, 0x21b4, 0x6abc, 0x21a9, + 0x0287, 0x6d0d, 0x6cfc, 0x6d0c, 0x6e07, 0x6e0a, 0x02ca, 0x6e02, + 0x02c3, 0x6e26, 0x6e08, 0x6e1d, 0x02c2, 0x2568, 0x6f4e, 0x0341, + 0x6fed, 0x6fee, 0x6fef, 0x0380, 0x0381, 0x7250, 0x724c, 0x0393, + 0x0392, 0x724f, 0x03c5, 0x73d4, 0x59fd, 0x73b0, + /* 0x29 */ + 0x0446, 0x0441, 0x0445, 0x0442, 0x043f, 0x76a5, 0x7809, 0x0482, + 0x0481, 0x047f, 0x04a5, 0x292b, 0x04b3, 0x04b5, 0x79f3, 0x79d7, + 0x298d, 0x04da, 0x7adc, 0x04db, 0x050d, 0x2a18, 0x050e, 0x7c0b, + 0x051e, 0x0525, 0x0526, 0x051c, 0x0521, 0x2a57, 0x2a48, 0x0527, + 0x051a, 0x7c3a, 0x7c0d, 0x7c11, 0x2a38, 0x7c20, 0x7c01, 0x0524, + 0x7c37, 0xd1a3, 0x2a71, 0x7eaa, 0x05c1, 0x05e1, 0x7fe7, 0x7fe8, + 0x2d12, 0x05eb, 0x7ff5, 0x05e2, 0x05d7, 0x05e9, 0x8035, 0x7fe6, + 0x2d0a, 0x7ff8, 0x2d23, 0x7ff1, 0x0684, 0x8314, 0x8315, 0x8309, + 0x06b5, 0x06bc, 0x06dc, 0x06de, 0x06df, 0x857b, 0x2f2a, 0x857e, + 0x8766, 0x8767, 0x880a, 0x0754, 0x30e0, 0x30be, 0x0753, 0x0824, + 0x0825, 0x3329, 0x0828, 0x0827, 0x8a9c, 0x8b62, 0x8be1, 0x8bde, + 0x8bdf, 0x8be9, 0x088b, 0x8ee4, 0x8ef7, 0x08dc, + /* 0x2a */ + 0x3543, 0x8eea, 0x8ef6, 0x8f12, 0xd201, 0x37a6, 0x09b2, 0x37c0, + 0x91d9, 0x392f, 0x935f, 0x0a1b, 0x9373, 0x0a32, 0x3971, 0x943f, + 0x9578, 0x0a6b, 0x957d, 0x0a6c, 0x0a6d, 0x9712, 0x0ab9, 0x0aba, + 0x0b09, 0x0b0a, 0x992f, 0x3bea, 0x0b1b, 0x9930, 0x99db, 0x3c20, + 0x0b58, 0x9a29, 0x0b5a, 0xd236, 0x9b40, 0x0b77, 0x9b3d, 0x9b3e, + 0x0b79, 0x3ca9, 0x9b38, 0x3d85, 0x9c48, 0x0beb, 0x9cd0, 0x0bfd, + 0x0bfc, 0x3e06, 0x0c15, 0x0c18, 0x3df6, 0x0c16, 0x0c17, 0x0c19, + 0x3e00, 0x0c1b, 0x9e0e, 0x9e09, 0x3e02, 0x9e07, 0x0c87, 0x9f5f, + 0x9f60, 0x0c9c, 0xa02a, 0x0c9a, 0xa029, 0x0cff, 0x0cfe, 0xa14d, + 0x0d31, 0x0d2e, 0x0d30, 0x0d32, 0xa26c, 0x59fd, 0x0d2f, 0xa267, + 0x0d95, 0x0d96, 0xa339, 0xa334, 0xa459, 0x0dc5, 0x0e7a, 0xa923, + 0x0f42, 0xa982, 0x0f54, 0xa983, 0xa9a8, 0xaa55, + /* 0x2b */ + 0xaaf9, 0xaaf8, 0xaafc, 0xaafa, 0x4609, 0xd27a, 0x0f9f, 0x0fa0, + 0x0fa2, 0x0fe0, 0xad74, 0x0fe1, 0xad6b, 0xad71, 0x0fdf, 0xad76, + 0xb10e, 0x1062, 0x1061, 0xb110, 0xb10f, 0x10a7, 0xb238, 0xb239, + 0xb23a, 0x48da, 0xb237, 0xb23e, 0x490a, 0x1189, 0xb49c, 0xb52a, + 0xb53a, 0xb52b, 0xb528, 0xb6aa, 0xb70f, 0x121d, 0xb710, 0xb8e6, + 0x132a, 0xbd25, 0xbe8e, 0x13d3, 0x1442, 0x1443, 0xc18b, 0x1491, + 0xc18c, 0xc19a, 0x1490, 0x14bf, 0xc3b3, 0x14bc, 0xc3b2, 0x14c0, + 0x15c7, 0x15c5, 0x5655, 0xc744, 0x5652, 0x1835, 0x5b58, 0x5ca7, + 0x1a34, 0x1a01, 0x5c63, 0x1a0a, 0x0066, 0x5c6a, 0x5c65, 0x5c6b, + 0x00ad, 0x5eed, 0x5fd9, 0x613b, 0x6132, 0x1c58, 0x6135, 0x6131, + 0x613e, 0x6143, 0x6136, 0x626d, 0x011d, 0x62e4, 0x0131, 0x1d2b, + 0x63f4, 0x014c, 0x6469, 0x646b, 0x0195, 0x0191, + /* 0x2c */ + 0x0194, 0x66bf, 0x66c3, 0x66ae, 0x018f, 0x1eec, 0x66b1, 0x1f15, + 0x1efe, 0x66bb, 0x66af, 0x66b0, 0x1ee3, 0x1f16, 0x0240, 0x6aef, + 0x0241, 0x6aed, 0x21d3, 0x6af0, 0x6c93, 0x6d34, 0x6d2b, 0x2359, + 0x2427, 0x02d8, 0x02d2, 0x02da, 0x2428, 0x2410, 0x02d7, 0x240e, + 0x0342, 0x0357, 0x7004, 0x7003, 0x7002, 0x25af, 0x7005, 0x25ba, + 0x25b1, 0x7000, 0x7174, 0x0378, 0x0382, 0x0397, 0x7265, 0x7263, + 0x03c9, 0x73d7, 0x03c8, 0x03d6, 0x03cc, 0x73e8, 0x03d0, 0x73db, + 0x73d8, 0x03ce, 0x03c7, 0x26fc, 0x7409, 0x03cf, 0x03cb, 0x26f2, + 0x26fe, 0x73e5, 0x73e7, 0x27f8, 0x763f, 0x0447, 0x76c0, 0x0448, + 0x76b9, 0x76ba, 0x0483, 0x0485, 0x0484, 0x7820, 0x794f, 0x292c, + 0x04b8, 0x04bc, 0x7a91, 0x7a90, 0x7aee, 0x7af3, 0x7aec, 0x7af1, + 0x7aeb, 0x7af2, 0x7af4, 0x7aed, 0x7c41, 0x7c48, + /* 0x2d */ + 0x7c45, 0x0531, 0x0534, 0x0536, 0x2a82, 0x7c7f, 0x7c8b, 0x0523, + 0x7c3b, 0x7c4e, 0x053a, 0x2a91, 0x2a8f, 0x7c7c, 0x05b4, 0x05b5, + 0x05ed, 0x05ec, 0x05d8, 0x7ff0, 0x8036, 0x803f, 0x8043, 0x8031, + 0x8034, 0x8046, 0x05f6, 0x05e7, 0x802f, 0x82c3, 0x067c, 0x067b, + 0x8336, 0x0688, 0x2e47, 0x2e4c, 0x8321, 0xd1c8, 0x2e8a, 0x8473, + 0x06be, 0x84e6, 0x06e7, 0x06e5, 0x06ee, 0x30e1, 0x314a, 0x883f, + 0x0759, 0x075e, 0x886b, 0x075a, 0x313f, 0x0761, 0x0758, 0x075b, + 0x30bd, 0x8871, 0x075f, 0xd1e2, 0x082a, 0x082d, 0x8ab0, 0x0823, + 0x082b, 0x082c, 0x8bf3, 0x087e, 0xd1f5, 0x0893, 0x0899, 0x8d61, + 0x8d5f, 0x08b3, 0x08e7, 0x08ea, 0x8f28, 0x8f1e, 0x8f29, 0xd202, + 0x8eeb, 0x8f66, 0x09b4, 0x91f6, 0x37c9, 0x0a17, 0x9360, 0x9377, + 0x93bb, 0x0a21, 0x93bc, 0x0a38, 0x0a37, 0x0a74, + /* 0x2e */ + 0x0a73, 0x0a75, 0x95a2, 0x95b2, 0x959e, 0x0a76, 0x0a78, 0x973a, + 0x9738, 0x3aba, 0x0b0c, 0x0b20, 0x0b1e, 0x9a4d, 0x0b5b, 0x9a5e, + 0x0b5c, 0x9b17, 0x0b83, 0x3cc6, 0x0b80, 0x0b81, 0x0b7e, 0x0b88, + 0x0b85, 0x0b89, 0x0b7f, 0x0b8e, 0x9b64, 0x9b67, 0x0b84, 0x3cb7, + 0x3d8c, 0x9c59, 0x3d8d, 0x9cda, 0x0bee, 0x0bed, 0x0bfe, 0x9d51, + 0x0bff, 0x9d55, 0x9e3b, 0x9e34, 0x0c23, 0x9e37, 0x3e17, 0x9e31, + 0x3e1c, 0x0c1f, 0x9e3f, 0x9e59, 0x3e14, 0x9f61, 0x0c8f, 0x0c90, + 0xa058, 0xa062, 0xa050, 0x0ca0, 0xa051, 0x0ca6, 0x0c9f, 0xa046, + 0x0ca7, 0x0ca1, 0xa12d, 0x0d02, 0x0d36, 0xa348, 0xa351, 0xa34a, + 0xa34f, 0xa350, 0xa349, 0xa463, 0x0dc8, 0xa466, 0xa460, 0x0dd8, + 0x420c, 0x0ddd, 0x0ddc, 0xa4f1, 0x0dd7, 0xa507, 0x0dda, 0x0eba, + 0xa79b, 0xa7a3, 0xa79d, 0x0ebe, 0x0ec2, 0x0ebb, + /* 0x2f */ + 0x0ec0, 0xa7a9, 0xa7a7, 0xa7a4, 0x4423, 0xa7ba, 0x77c1, 0xa926, + 0x0f43, 0x0f55, 0xa994, 0xa993, 0x0f57, 0x0f68, 0x4598, 0x4590, + 0xab07, 0xab0d, 0xab02, 0xab0c, 0xab09, 0xab08, 0xab13, 0x0fa1, + 0xabd2, 0x463a, 0xac3e, 0xac3c, 0xad67, 0xad9e, 0x0fea, 0xadad, + 0x0fe7, 0xadd9, 0xad42, 0xada3, 0xada0, 0x0fe8, 0x0fe9, 0xad7c, + 0xb004, 0x1054, 0xb058, 0xb060, 0xb0c9, 0xb0c8, 0x4826, 0x1065, + 0xb11c, 0xb11a, 0x108a, 0xb274, 0x10b0, 0xb26e, 0xb26f, 0xb279, + 0x10bc, 0x492e, 0xb277, 0x4955, 0x491a, 0x10b8, 0x493d, 0xb27c, + 0x10b2, 0xb270, 0x4930, 0x10bd, 0xb27a, 0xb282, 0x118a, 0x4b51, + 0x11a1, 0xb544, 0x11a2, 0xb543, 0x4b88, 0xb545, 0x1215, 0xb725, + 0xb71f, 0x1220, 0x1273, 0xb8e8, 0x4d8e, 0x4d8d, 0xb909, 0xb9b7, + 0xb9b9, 0xba64, 0xba63, 0x4e09, 0x4e14, 0x12b1, + /* 0x30 */ + 0xba62, 0xba65, 0x132b, 0xbbac, 0x1345, 0xbd2a, 0x1397, 0x1398, + 0xbe96, 0x13d5, 0xbfc2, 0xd2de, 0x1493, 0x1496, 0x5207, 0x1494, + 0xc1aa, 0xc1b0, 0x14c7, 0x14c5, 0xc3d4, 0xc3cd, 0xc3d6, 0x14c4, + 0xc4f0, 0x5579, 0x5584, 0x15ce, 0x15ca, 0x15cc, 0x5657, 0x15c9, + 0x56ba, 0x59fd, 0xd04b, 0x5b62, 0x006e, 0x5cb7, 0x1a67, 0x5cac, + 0x5cab, 0x0071, 0x5cc1, 0x00bb, 0x00d3, 0x5fe8, 0x6169, 0x615d, + 0x615f, 0x00f3, 0x00ed, 0x00f5, 0x6164, 0x6162, 0x00f1, 0x00f2, + 0x00f6, 0x0120, 0x62f9, 0x0128, 0x62ee, 0x1d18, 0x1d2c, 0x1d59, + 0x63ab, 0x63ac, 0x63aa, 0x1d68, 0x1d7e, 0x6486, 0x647a, 0x1da1, + 0x6728, 0x01a1, 0x1f5b, 0x01aa, 0x01a9, 0x6731, 0x01b5, 0x01a5, + 0x01a8, 0x1f42, 0x01a7, 0x1f47, 0x672d, 0xd143, 0x1f3d, 0x672b, + 0x6732, 0x1f60, 0x21eb, 0x6b29, 0x6b26, 0x6b53, + /* 0x31 */ + 0x024d, 0x6b33, 0x6b34, 0x6c9d, 0x029c, 0x235f, 0x6d41, 0x02ea, + 0x02e5, 0x6e91, 0x6e69, 0x256f, 0x7022, 0x035e, 0x7034, 0xd16d, + 0x712e, 0x0386, 0x0384, 0x71f4, 0x265a, 0x7428, 0x03d9, 0x741c, + 0x03de, 0x7411, 0x7424, 0x7415, 0x03db, 0x7416, 0x7454, 0x7423, + 0x75ff, 0x0431, 0x76cf, 0x76d0, 0x044b, 0x76ce, 0x0449, 0x044a, + 0x044c, 0x77c7, 0x785c, 0x048a, 0x7836, 0x0489, 0x048b, 0x7843, + 0x04bb, 0x29a2, 0x299d, 0x04e4, 0x7b2a, 0x7b01, 0x29a3, 0x7b0b, + 0x7b0f, 0x053b, 0x052e, 0x053e, 0x0546, 0x0553, 0x7cdf, 0x0544, + 0x7cd2, 0x053f, 0x0542, 0x054f, 0x7ccd, 0x0552, 0x054a, 0x2ac2, + 0x7cdb, 0x055a, 0x2aa5, 0x0549, 0x7ccf, 0x2c1c, 0x7ec0, 0x2c1d, + 0x0603, 0x8081, 0x8082, 0x808a, 0x80a8, 0x808c, 0x2d95, 0x2d9a, + 0x0601, 0x0606, 0x05fb, 0x05f9, 0x808e, 0x0605, + /* 0x32 */ + 0x05fa, 0x808b, 0x2da6, 0x8096, 0x05fe, 0x80cc, 0x067d, 0x068c, + 0x834f, 0x834a, 0x2e50, 0x068e, 0x834b, 0x833d, 0x2e52, 0x8344, + 0x8349, 0x849e, 0x84f3, 0x2ec8, 0x84f5, 0x06f0, 0x06f2, 0x85b3, + 0x2f58, 0x06f1, 0x06e6, 0x85e5, 0x85b6, 0xd1d8, 0x3188, 0x8886, + 0x076f, 0x076d, 0x0769, 0x88b6, 0x8885, 0x076e, 0x88ab, 0x082f, + 0x0830, 0x0863, 0x8c0d, 0x8c8b, 0x8c8c, 0x33b8, 0x0880, 0x33b9, + 0x089a, 0x0894, 0x0896, 0x0895, 0x0897, 0x8d72, 0x08f4, 0x08fe, + 0x8f8f, 0x0901, 0x8f79, 0x0902, 0x8f77, 0x08f9, 0x8f90, 0x8f88, + 0x8f80, 0x8f9e, 0x08f6, 0x08f7, 0x8f82, 0x8f34, 0x8f89, 0x08ff, + 0x8f85, 0x8f7e, 0x8f7a, 0x8fa6, 0x360b, 0x8fb5, 0x91f4, 0x09bf, + 0x09bc, 0x3805, 0x9229, 0x9226, 0x922a, 0x09be, 0x09c0, 0x937e, + 0x0a3b, 0x0a39, 0x945b, 0x9461, 0x9460, 0x0a3c, + /* 0x33 */ + 0x959b, 0x3a14, 0x3a04, 0x95c3, 0x0a7d, 0x95cd, 0x0a7f, 0x0a7a, + 0x0a7c, 0x3a05, 0x0a7e, 0x3a15, 0x3a0d, 0x0a80, 0x0abf, 0x0ac3, + 0x9754, 0x9759, 0x0acc, 0x0b0e, 0x0b0d, 0x98f5, 0x0b26, 0x0b24, + 0x0b25, 0x0b23, 0x0b21, 0x0b29, 0x9a69, 0x9a65, 0x0b8f, 0x0b8d, + 0x9b7c, 0x0b8b, 0x0b92, 0x9b80, 0x0b90, 0x9c65, 0x0bef, 0x0bf0, + 0x9cdf, 0x9d60, 0x0c01, 0x9d5e, 0x0c2e, 0x0c2d, 0x3e2e, 0x0c28, + 0x0c29, 0x0c2c, 0x9e8f, 0x9e61, 0x9e5a, 0x3e41, 0x0c88, 0x9f67, + 0x0c92, 0x0c91, 0x3eea, 0x9fbb, 0x3f44, 0x0ca9, 0x0cac, 0x0cae, + 0x0caa, 0x0d06, 0x0d05, 0x0d4a, 0x0d3e, 0x0d3c, 0x0d3b, 0xa29b, + 0x0d42, 0x0d41, 0x0d43, 0xa2a9, 0x0d45, 0xa366, 0x0d9a, 0x0d9b, + 0x0d9f, 0x0d9e, 0xa472, 0xa476, 0xa514, 0x0dde, 0x0de2, 0x0de6, + 0xa50f, 0x4229, 0x0de3, 0x4227, 0x0ddf, 0xa641, + /* 0x34 */ + 0xa646, 0x439d, 0xa64b, 0xa643, 0x0e7e, 0x0ec9, 0x0ecc, 0xa7c6, + 0x0ed1, 0xa7c7, 0x0ed0, 0xa7ce, 0x0ecf, 0x0ec8, 0xa7c9, 0x0ecd, + 0xa7cb, 0xa7c5, 0x0f49, 0x0f47, 0x0f58, 0x0f6b, 0x0f6c, 0x0f6a, + 0xaa69, 0x0f80, 0x0f82, 0x0f84, 0x45c8, 0x0f83, 0xab1e, 0xabba, + 0x0fb6, 0xac52, 0xac51, 0xac53, 0xad9f, 0xaddb, 0x4726, 0x0ff1, + 0xade3, 0x0ff6, 0x0ff3, 0x0ff0, 0x471c, 0xadd7, 0xade9, 0x4728, + 0x0ff5, 0x0ff4, 0x0ff7, 0xadde, 0xaddc, 0xb03c, 0xd28b, 0x1055, + 0xb122, 0xb132, 0xb123, 0x108b, 0x10cb, 0x10c2, 0xb2d4, 0xb2c8, + 0xb2bc, 0x10ca, 0x10cc, 0xb2cd, 0x10c7, 0x10c9, 0x4970, 0xb2be, + 0x10c6, 0xb340, 0xb2d6, 0x10c3, 0x4982, 0xb2bd, 0x49ac, 0xb2ba, + 0x10c4, 0xb2c0, 0xd29b, 0xd29d, 0xb2c1, 0xb4a6, 0xb4a5, 0xb4a8, + 0x11a9, 0x4bad, 0x11a8, 0x11a6, 0xb55f, 0xb570, + /* 0x35 */ + 0xb56a, 0xb565, 0xb567, 0xb56f, 0xb587, 0x4bca, 0x4c51, 0xb73d, + 0xb743, 0x1222, 0xb740, 0x1226, 0x1224, 0x1225, 0x4c9d, 0x122a, + 0x1274, 0xb918, 0x1279, 0x4d90, 0x127a, 0xb919, 0xb9c1, 0x4dd8, + 0x4dd7, 0x1297, 0xb9bc, 0xb9c8, 0x4e2e, 0xba71, 0x12bc, 0xba6e, + 0x12b3, 0xba78, 0x12bf, 0x12b7, 0xd2cd, 0xba7a, 0xbbb1, 0xbbaf, + 0xbbb0, 0x1334, 0x1346, 0x1348, 0x4f59, 0xbca8, 0xbca6, 0x1356, + 0x1367, 0xbd48, 0xbd45, 0x1368, 0x1399, 0x139a, 0xbea0, 0xbea4, + 0x13d8, 0xbfd4, 0x13db, 0x13dc, 0x13dd, 0x13d7, 0xbfd2, 0xc022, + 0x1449, 0x144a, 0x50da, 0xc0b7, 0xc0cc, 0x5233, 0xc1e6, 0x5218, + 0x149a, 0xc1c8, 0x14cd, 0x14ca, 0xc3f4, 0x14cb, 0xc3ed, 0x14cf, + 0xc37e, 0xd2e3, 0x14cc, 0x14ea, 0x14ed, 0xc4f9, 0xc4fd, 0x14e9, + 0xc507, 0x151a, 0x53ef, 0x158d, 0x15d2, 0xc778, + /* 0x36 */ + 0xc77a, 0xc779, 0xc88a, 0x15f2, 0xc97b, 0xcad5, 0xcae9, 0x163d, + 0xcaeb, 0x163e, 0x16f8, 0x1723, 0x58d9, 0x18b4, 0x5b6c, 0x1aa0, + 0x1a90, 0x0075, 0x1a86, 0x1a84, 0x5cfa, 0x1a8a, 0x0076, 0x0073, + 0x1a9f, 0x1aa1, 0x5d18, 0x1a93, 0x00bd, 0x5ff6, 0x1bd5, 0x618a, + 0x6189, 0x00f9, 0x617f, 0x6188, 0x00fa, 0x6183, 0x6184, 0x6198, + 0x6163, 0x6187, 0x0121, 0xd127, 0x0129, 0x62f5, 0x6350, 0x0138, + 0x014e, 0x6487, 0x648a, 0x6565, 0x67b7, 0x67c1, 0x67c7, 0x01c8, + 0x01bc, 0x67c5, 0x67cb, 0x1f90, 0x67d1, 0x01bb, 0x01c2, 0x01c0, + 0x67b8, 0x67ca, 0x01ca, 0x67de, 0x01c9, 0x67ce, 0x01b8, 0x2110, + 0x2217, 0x6b68, 0x024e, 0x6b6b, 0x2244, 0x0250, 0x222b, 0x6b6a, + 0x2245, 0x6b66, 0x6b77, 0x6b96, 0x6b6e, 0xd156, 0x028a, 0x6d57, + 0x2365, 0x6d56, 0x6e9c, 0x6e9e, 0x02fc, 0x02f9, + /* 0x37 */ + 0x6ea1, 0x0363, 0x7042, 0x25cf, 0x7046, 0x703e, 0x7133, 0x0387, + 0x0388, 0x71fa, 0x039a, 0x7297, 0x729b, 0x72aa, 0x2756, 0x7473, + 0x747c, 0x03e9, 0x7486, 0x03ea, 0x2754, 0x0450, 0x76f3, 0x76f0, + 0x0456, 0x0452, 0x044f, 0x0454, 0x0451, 0x76ec, 0x78af, 0x048e, + 0x048f, 0x7864, 0x7868, 0x795a, 0x293d, 0x7b1f, 0x7b25, 0x04ed, + 0x04eb, 0x29a4, 0x7cc6, 0x7cd6, 0x7cc3, 0x0562, 0x7d2c, 0x055d, + 0x7d2e, 0x7d5e, 0x7d33, 0x0561, 0x0565, 0x055c, 0x7d2d, 0x7d46, + 0x055f, 0x7cc1, 0x7d3a, 0x7ecc, 0x809d, 0x8083, 0x80f6, 0x2dec, + 0x0616, 0x060a, 0x80f8, 0x060e, 0x0612, 0x80fe, 0x80f3, 0x0611, + 0x80eb, 0x80fa, 0x0610, 0x8107, 0x80fc, 0x0609, 0x2dfa, 0x0615, + 0x2dd4, 0x8372, 0x8373, 0x8374, 0x0691, 0x0695, 0x0693, 0x0692, + 0x068f, 0x835f, 0x8360, 0x84aa, 0x8534, 0x06f6, + /* 0x38 */ + 0x85b4, 0x06fb, 0x85f0, 0x2f75, 0x06f9, 0x860d, 0x85f3, 0x860f, + 0x301c, 0x077d, 0x88c9, 0x077a, 0x077f, 0x88c5, 0x0778, 0x88d7, + 0x88cc, 0x31d9, 0x88e7, 0x0770, 0x0782, 0x88c1, 0x0784, 0x88e8, + 0x0833, 0x8acb, 0x0832, 0x0836, 0x8ac8, 0x8b7a, 0x0856, 0x8b79, + 0x8b7e, 0x0867, 0x8c1b, 0x0865, 0x0864, 0x0866, 0x8c1f, 0x8c19, + 0x0881, 0x0882, 0x0883, 0x089e, 0x8d89, 0x33f1, 0x089d, 0x8d8b, + 0x090f, 0x0912, 0x9009, 0x8ffe, 0x9000, 0x0910, 0x0918, 0x900b, + 0x0914, 0x0919, 0x3637, 0x59fd, 0x904a, 0x367d, 0x3686, 0x09c8, + 0x09c4, 0x09c6, 0x9279, 0x09c7, 0x09c3, 0x926c, 0x9299, 0xd21b, + 0x9262, 0x9314, 0x0a19, 0x0a1c, 0x93c8, 0x93d7, 0x940c, 0x0a41, + 0x9470, 0x0a42, 0x0a43, 0x9471, 0x95df, 0x95e4, 0x0a82, 0x95e7, + 0x0a81, 0x0a94, 0x0a84, 0x9790, 0x0ad2, 0x0b0f, + /* 0x39 */ + 0x0b22, 0x994c, 0x0b27, 0x0b2a, 0x3bfa, 0x0b28, 0x994f, 0x0b60, + 0x9a7d, 0x9a7e, 0x9a7c, 0x3c72, 0x9a8d, 0x9b19, 0x0b9b, 0x0b9c, + 0x9bc0, 0x0b93, 0x0b94, 0x3cdc, 0x0ba0, 0x0b99, 0x9bb6, 0x0ba1, + 0x9ba8, 0x0bf1, 0x9ceb, 0x9ce7, 0x9d6f, 0x9ec7, 0x0c36, 0x9e9f, + 0x0c37, 0x0c3f, 0x0c3c, 0x9ec4, 0x0c34, 0x0c39, 0x0c3b, 0x0c35, + 0x0c30, 0x0c32, 0x0c38, 0x0c3e, 0x0c3a, 0x9e9b, 0x9e97, 0x9ec5, + 0x9f6b, 0x9fce, 0x0cb6, 0x3f67, 0xa0b1, 0xa0ae, 0xa0b0, 0x0cb3, + 0x0d09, 0x4077, 0xa23e, 0xa2b5, 0xa2ba, 0x0d4c, 0xa2b2, 0xa2b4, + 0x0d53, 0x0d4d, 0x0d51, 0x0d4f, 0x419b, 0xa377, 0x0da2, 0xa386, + 0xa37b, 0x0dcd, 0xa47e, 0xa52e, 0x0de7, 0xa52f, 0x0df0, 0xa537, + 0x0de9, 0x0dec, 0xa532, 0x0de8, 0x0dee, 0x0e02, 0xa536, 0xa539, + 0xa535, 0xa65c, 0x0e82, 0x0e83, 0x0e86, 0xa67b, + /* 0x3a */ + 0xa661, 0xa7ee, 0xa7eb, 0xa7ef, 0xa820, 0x442a, 0x4465, 0x0f4a, + 0xa930, 0x0f5a, 0x4564, 0xa9be, 0x0f6e, 0xaa67, 0xaa7c, 0x0f70, + 0x0f6f, 0xab24, 0x0f8a, 0x0f87, 0x0f88, 0xab29, 0xabef, 0x4620, + 0x0fb7, 0x0ffd, 0x4720, 0xae0d, 0x1005, 0x473c, 0x1008, 0x1003, + 0x1002, 0x1004, 0x0739, 0x1009, 0x0fff, 0xae64, 0x473f, 0xae15, + 0x0ffc, 0x1001, 0x100a, 0x47f0, 0x47f5, 0x106b, 0x106c, 0xb135, + 0xb136, 0xb134, 0xb137, 0xb347, 0xb32b, 0x10de, 0xb341, 0xb343, + 0x10db, 0xb342, 0x10dd, 0x10e3, 0xb332, 0x10e0, 0x10d9, 0x10d8, + 0x10e4, 0xb344, 0xb34a, 0x10da, 0x10ef, 0xd2a0, 0x4a15, 0x49be, + 0xb354, 0xb36e, 0xb352, 0x10d7, 0x11b3, 0x11bb, 0x4be5, 0x11b2, + 0x4bd2, 0x11ad, 0xb592, 0x11af, 0xd2b8, 0x4be0, 0xb5bf, 0x1216, + 0x1228, 0x1223, 0x4cb3, 0xb741, 0xb769, 0xb765, + /* 0x3b */ + 0x1275, 0x127e, 0x127c, 0xb922, 0xb91d, 0xb9d2, 0xb9da, 0xb9db, + 0x12ce, 0x12cd, 0x12cf, 0x4e53, 0xbaa4, 0xba9e, 0x4e37, 0x4e47, + 0x4e5c, 0xba9d, 0x12c4, 0x12cc, 0x12c8, 0x12c7, 0xbaad, 0xbaa6, + 0xbaa7, 0xbbb3, 0xbbe0, 0xbc35, 0xbc37, 0x135a, 0x136a, 0xbd4a, + 0x136b, 0x136d, 0x136f, 0xbe5e, 0x139e, 0xbec0, 0x13a4, 0x13a3, + 0x13e4, 0x13e8, 0x13e9, 0x13e0, 0x13e3, 0xbff9, 0x13ea, 0x13e1, + 0x13ed, 0x1434, 0x1435, 0x1451, 0x50f0, 0xc1f0, 0x149d, 0xc1f3, + 0xc21b, 0xc1f2, 0xc1fb, 0xc41c, 0xc413, 0x14d0, 0xc40f, 0x14ee, + 0xc516, 0xc511, 0xc512, 0x14f2, 0xc50e, 0x541d, 0x1588, 0xc667, + 0xc6f2, 0xc6da, 0x158f, 0xc6dc, 0x15d8, 0xc894, 0xc89b, 0xc892, + 0xc89a, 0xc988, 0xc986, 0x163f, 0xcaef, 0x1652, 0x576b, 0xcb5e, + 0x1650, 0xcc58, 0x16b1, 0xcc56, 0xcc54, 0x16f9, + /* 0x3c */ + 0xcd9b, 0xce96, 0xcea4, 0x1726, 0x1728, 0xce9a, 0xcf12, 0x0080, + 0x1ac0, 0x0081, 0x5d6b, 0x007e, 0x007f, 0x5d37, 0x5d3c, 0xd10a, + 0x5ef7, 0x00be, 0x5f66, 0x00d6, 0x61a9, 0x61ae, 0x61ad, 0x61c8, + 0x61a5, 0x61b0, 0x6295, 0x1ce5, 0x6325, 0x0134, 0x6499, 0x1daf, + 0x6574, 0x6570, 0x656f, 0x6841, 0x6854, 0x01d5, 0x01d8, 0x6840, + 0x6838, 0x01d4, 0x1fd8, 0x01d9, 0x6852, 0x683a, 0x6857, 0xd14a, + 0x6859, 0x2111, 0x2267, 0x6bb4, 0x6bc0, 0x025d, 0x2243, 0x025e, + 0x0259, 0x6b75, 0x025a, 0x02a0, 0x6d60, 0x6d47, 0x0305, 0x6ef0, + 0x0307, 0x6eef, 0x030e, 0x030c, 0x6eec, 0x6f83, 0x0345, 0x6f84, + 0x6f8f, 0x0364, 0x7061, 0x0365, 0x7069, 0x25dd, 0x0366, 0x7062, + 0x0389, 0x03ec, 0x03f1, 0x2770, 0x276a, 0x03f0, 0x03f8, 0x2774, + 0x275f, 0x74ae, 0x2761, 0x2773, 0x74b2, 0x03f2, + /* 0x3d */ + 0x03f4, 0x770b, 0x0458, 0x7710, 0x770d, 0x045a, 0x0459, 0x0457, + 0x045b, 0x2850, 0x787f, 0x7881, 0x04a6, 0x04c2, 0x04c1, 0x293f, + 0x7a0b, 0x7b4e, 0x04ef, 0x29b0, 0x7dea, 0x7d45, 0x0568, 0x2b35, + 0x2b2d, 0x0573, 0x056e, 0x0574, 0x2b02, 0x0566, 0x7d28, 0x7d5d, + 0x7edc, 0x05b9, 0x2c26, 0x7ed4, 0x060c, 0x8164, 0x8168, 0x0620, + 0x8162, 0x061d, 0x8161, 0x061c, 0x8166, 0x0621, 0x061a, 0x0619, + 0x80f2, 0x8169, 0x8167, 0x067e, 0x839a, 0x839b, 0x8385, 0x839c, + 0x069d, 0x83a4, 0x069e, 0x069c, 0x2e6e, 0x8399, 0x8386, 0x8390, + 0x8481, 0x84ae, 0x2eb1, 0x2ed4, 0x06cd, 0x8538, 0x070b, 0x070a, + 0x2f85, 0x893b, 0x078f, 0x3272, 0x0795, 0x0790, 0x0791, 0x894c, + 0x323a, 0x07b9, 0x8947, 0x8935, 0x0797, 0x079e, 0x8933, 0x078b, + 0x8982, 0x8940, 0x083b, 0x083a, 0x083c, 0x083d, + /* 0x3e */ + 0x0839, 0x083e, 0x086b, 0x086c, 0x8c36, 0x8d0e, 0x08a2, 0x08a1, + 0x089f, 0x8dad, 0x8daa, 0x9017, 0x092d, 0x9067, 0x0936, 0x092b, + 0x9072, 0x0937, 0xd20a, 0x9061, 0x90b0, 0x36ad, 0x0925, 0x092f, + 0x092c, 0x906e, 0x9064, 0x0932, 0x908c, 0x9066, 0x3695, 0x906b, + 0x905f, 0x9074, 0x9065, 0x92bb, 0x92be, 0x09d5, 0x92b9, 0x09d4, + 0x09d6, 0x92ef, 0x09d1, 0x3943, 0x93da, 0x0a46, 0x398f, 0x9490, + 0x95e9, 0x0a8c, 0x0a8a, 0x0a88, 0x9611, 0x960d, 0x95ed, 0x9621, + 0x0add, 0x9781, 0x97b1, 0x9901, 0x0b2d, 0x995e, 0x9962, 0x0b2e, + 0x0b2c, 0x0b2b, 0x0b30, 0x995b, 0x0b4e, 0x9a96, 0x9a93, 0x0b64, + 0x0b61, 0x9a92, 0x3c75, 0xd239, 0x0b70, 0x0ba6, 0x0ba4, 0x9bc4, + 0x9bc7, 0x9bc3, 0x0ba8, 0x0ba2, 0x9bc8, 0x0ba7, 0x3cec, 0x0ba5, + 0x9bca, 0x0ba9, 0x9bc5, 0x9bcf, 0x9bdc, 0x9c7c, + /* 0x3f */ + 0x9d01, 0x0c3d, 0x9ed3, 0x9edc, 0x0c44, 0x0c45, 0x0c46, 0x9ed4, + 0x3e57, 0x9ecc, 0x0c47, 0x0c48, 0x0c42, 0x9ed6, 0x9edb, 0x0c41, + 0x9ed5, 0x9fd9, 0x0c94, 0x9fdd, 0x9fdc, 0x9fe0, 0xa0cc, 0x0cc0, + 0x0cb8, 0x0cc1, 0x0cc2, 0x0cbb, 0x0cbd, 0x0cbf, 0x0cb9, 0x0cb7, + 0xa0d2, 0x0cc7, 0xa0d3, 0x0d0c, 0x0d0b, 0x407b, 0x0d10, 0xa18d, + 0x0d5d, 0x4121, 0x0d5a, 0x0d58, 0x0d56, 0xa2d8, 0x0d54, 0x4116, + 0xa2bc, 0x0da8, 0x0da7, 0x0dcf, 0x0dd0, 0xa48a, 0x41e8, 0xa48b, + 0xa48d, 0x0dd1, 0x0deb, 0xa553, 0x0dfb, 0x426a, 0xa559, 0x0dfd, + 0x0df8, 0x0df7, 0x0e00, 0xa556, 0xa557, 0x0df6, 0x425f, 0xa673, + 0xa81b, 0x0edf, 0xa821, 0xa816, 0xa818, 0x0ee2, 0x0ee4, 0xa844, + 0x4482, 0xa826, 0x0ee3, 0xa936, 0x0f59, 0x0f71, 0x0f8e, 0x0f8c, + 0xab3a, 0x0fa4, 0xabf4, 0x4655, 0x1014, 0xae62, +}; + +static const ucs4_t cns11643_4a_2uni_upages[212] = { + 0x03400, 0x03500, 0x03600, 0x03700, 0x03800, 0x03900, 0x03a00, 0x03b00, + 0x03c00, 0x03d00, 0x03e00, 0x03f00, 0x04000, 0x04100, 0x04200, 0x04300, + 0x04400, 0x04500, 0x04600, 0x04700, 0x04800, 0x04900, 0x04a00, 0x04b00, + 0x04e00, 0x04f00, 0x05000, 0x05100, 0x05200, 0x05300, 0x05400, 0x05500, + 0x05600, 0x05700, 0x05800, 0x05900, 0x05a00, 0x05b00, 0x05c00, 0x05d00, + 0x05e00, 0x05f00, 0x06000, 0x06100, 0x06200, 0x06300, 0x06500, 0x06600, + 0x06700, 0x06800, 0x06900, 0x06b00, 0x06c00, 0x06d00, 0x06e00, 0x07000, + 0x07100, 0x07200, 0x07300, 0x07400, 0x07500, 0x07600, 0x07700, 0x07800, + 0x07900, 0x07a00, 0x07b00, 0x07c00, 0x07d00, 0x07f00, 0x08000, 0x08100, + 0x08200, 0x08300, 0x08400, 0x08600, 0x08800, 0x08900, 0x08a00, 0x08c00, + 0x08e00, 0x08f00, 0x09000, 0x09100, 0x09200, 0x09500, 0x09600, 0x09700, + 0x09a00, 0x0ff00, 0x20000, 0x20100, 0x20200, 0x20300, 0x20400, 0x20500, + 0x20600, 0x20700, 0x20800, 0x20900, 0x20a00, 0x20b00, 0x20c00, 0x20d00, + 0x20e00, 0x21100, 0x21200, 0x21300, 0x21500, 0x21600, 0x21700, 0x21900, + 0x21a00, 0x21b00, 0x21c00, 0x21d00, 0x21e00, 0x21f00, 0x22000, 0x22100, + 0x22200, 0x22300, 0x22400, 0x22500, 0x22600, 0x22700, 0x22900, 0x22a00, + 0x22b00, 0x22c00, 0x22e00, 0x22f00, 0x23000, 0x23100, 0x23200, 0x23300, + 0x23400, 0x23500, 0x23800, 0x23900, 0x23a00, 0x23b00, 0x23c00, 0x23d00, + 0x23e00, 0x24100, 0x24200, 0x24500, 0x24600, 0x24700, 0x24800, 0x24900, + 0x24a00, 0x24b00, 0x24c00, 0x24d00, 0x24f00, 0x25000, 0x25100, 0x25300, + 0x25400, 0x25600, 0x25700, 0x25900, 0x25a00, 0x25b00, 0x25e00, 0x25f00, + 0x26000, 0x26200, 0x26300, 0x26400, 0x26500, 0x26600, 0x26700, 0x26800, + 0x26900, 0x26a00, 0x26b00, 0x26c00, 0x27100, 0x27200, 0x27500, 0x27600, + 0x27700, 0x27800, 0x27900, 0x27b00, 0x27c00, 0x27d00, 0x27e00, 0x27f00, + 0x28200, 0x28400, 0x28500, 0x28600, 0x28700, 0x28800, 0x28c00, 0x28e00, + 0x28f00, 0x29000, 0x29100, 0x29200, 0x29400, 0x29500, 0x29600, 0x29a00, + 0x29d00, 0x2f800, 0x2f900, 0x2fa00, +}; + diff --git a/graf2d/win32gdk/gdk/src/iconv/cns11643_4b.h b/graf2d/win32gdk/gdk/src/iconv/cns11643_4b.h new file mode 100644 index 0000000000000..6a9823e1aaed4 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cns11643_4b.h @@ -0,0 +1,668 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CNS 11643-1992 plane 4 part b + */ + +static const unsigned short cns11643_4b_2uni_page40[4384] = { + /* 0x40 */ + 0xb65b, 0xb66a, 0x1011, 0xb668, 0x101b, 0x1012, 0x100e, 0x1015, + 0x3f68, 0x1010, 0xb681, 0x1017, 0x4046, 0x4043, 0x1070, 0x10ed, + 0xbae7, 0x10ee, 0xbae6, 0xbad1, 0xbb11, 0x4181, 0xbad0, 0xbad9, + 0xbb0a, 0x10f4, 0xbada, 0xbadd, 0xbac8, 0xbae2, 0xbae9, 0xbacb, + 0x417c, 0xbacc, 0xbac1, 0x416a, 0xbade, 0x4188, 0x10f2, 0x10f8, + 0x10f3, 0xbb51, 0xbb12, 0x10fa, 0xbae0, 0xbb2b, 0xf6b4, 0xc0d8, + 0xc0d1, 0x4410, 0xc0d2, 0xc0cd, 0x441f, 0x11b6, 0x11b7, 0xc13d, + 0x440f, 0xc0ca, 0x11ba, 0xc0cb, 0x11bc, 0xc0d7, 0xc3f4, 0x123b, + 0x45d3, 0x122f, 0xc487, 0xc48b, 0xc483, 0x1237, 0x1299, 0xc7c5, + 0xc7d2, 0xc7c6, 0xc7d3, 0x12d9, 0x12d8, 0x12d7, 0xc7f0, 0xc7cd, + 0xc7cc, 0xc7dc, 0xc7d6, 0x1336, 0xc9e6, 0xca41, 0xca3f, 0x4987, + 0xcac5, 0xcac0, 0xcac6, 0xcabe, 0xcabf, 0x49c6, + /* 0x41 */ + 0x1370, 0xcb63, 0xccd3, 0xccda, 0xccd5, 0x13a5, 0x13a6, 0x13a9, + 0x13ee, 0x1454, 0xd0ee, 0x1457, 0xd0fc, 0xd214, 0x14a1, 0xd323, + 0xd322, 0xd330, 0xd4b5, 0x14d3, 0xd538, 0x14d4, 0xd53f, 0x14d7, + 0x4dcc, 0x4e6d, 0x4e70, 0x14f7, 0x14f6, 0x14f9, 0x14f8, 0x4f58, + 0x4f42, 0x4f68, 0x4f69, 0xd768, 0xd767, 0x4f43, 0xd765, 0x4f47, + 0x158a, 0xda75, 0xdaf7, 0xdaf3, 0xdaf6, 0x1594, 0xdb00, 0x1593, + 0xdaff, 0xdaf5, 0x529d, 0x15dd, 0x15dc, 0x15f7, 0x53cf, 0xde92, + 0xe006, 0x1642, 0xe007, 0xe06b, 0x1654, 0xe06c, 0x1655, 0xe193, + 0x168f, 0xe194, 0x54f4, 0x16b4, 0x16b3, 0xe262, 0xe263, 0x5509, + 0xe25f, 0xe264, 0xe25b, 0xe259, 0x16fb, 0x16fd, 0xe3a4, 0xe3ac, + 0x55ab, 0x16fc, 0xe4b5, 0x172c, 0x172f, 0xe4ae, 0x172b, 0xe4c5, + 0x1733, 0x1734, 0x55fb, 0xe63b, 0x57ac, 0x57ae, + /* 0x42 */ + 0x57aa, 0x17e8, 0xe8bf, 0xea2b, 0xea84, 0xea80, 0xeb4d, 0xeb4f, + 0x585c, 0xeb4c, 0xed92, 0x195d, 0x1ad2, 0x0085, 0x0088, 0x5fae, + 0x5f79, 0x008e, 0x0084, 0x5f71, 0x1adf, 0x5fb3, 0x0083, 0x5f2c, + 0x5f77, 0x612f, 0x63c3, 0x0102, 0x63cd, 0x0106, 0x0105, 0x63c9, + 0x00fe, 0x0101, 0x0100, 0x63ce, 0x64a5, 0x64a0, 0x64fe, 0x6559, + 0x669a, 0x01e7, 0x1e19, 0x68e4, 0x68d7, 0x68dc, 0x01e6, 0x68e7, + 0x01ed, 0x01e2, 0x01eb, 0x68e5, 0x01e8, 0x01ec, 0x1e0a, 0x0224, + 0x1f9a, 0x6e14, 0x0262, 0x6df1, 0x0261, 0x0260, 0x0264, 0x028b, + 0x6fb6, 0x706e, 0x706c, 0x7081, 0x7142, 0x0319, 0x0316, 0x0318, + 0x0322, 0x711a, 0x031d, 0x0317, 0x031e, 0x7127, 0x7125, 0x7117, + 0x711c, 0x713d, 0x7120, 0x0369, 0x036a, 0x7381, 0x036c, 0x037a, + 0x038a, 0x7509, 0x75c6, 0x75c4, 0x039c, 0x75c5, + /* 0x43 */ + 0x03fd, 0x03f9, 0x76ef, 0x03ff, 0x76df, 0x76de, 0x76ee, 0x76f5, + 0x76ec, 0x03fc, 0x76dd, 0x2385, 0x03fb, 0x0402, 0x045f, 0x2456, + 0x045e, 0x045d, 0x045c, 0x7822, 0x2451, 0x0492, 0x7997, 0x7995, + 0x0494, 0x0495, 0x04d1, 0x7ba9, 0x04f1, 0x7c53, 0x25b1, 0x7c56, + 0x7c55, 0x0577, 0x056f, 0x7de3, 0x7de2, 0x0587, 0x057d, 0x057c, + 0x057e, 0x0585, 0x058b, 0x0586, 0x0580, 0x5dfd, 0x7da9, 0x0578, + 0xf5ab, 0x7e33, 0x7e0a, 0x05ba, 0x8059, 0x0633, 0x81bc, 0x062d, + 0x81c4, 0x81c7, 0x81c6, 0x0637, 0x275a, 0x2763, 0x81b8, 0x81da, + 0x062e, 0x81b7, 0x81c0, 0x063d, 0x81cd, 0x06a0, 0x84bc, 0x84ab, + 0x06a3, 0x8586, 0x299b, 0x875a, 0x29a3, 0x070e, 0x299e, 0x8843, + 0x07b6, 0x89ac, 0x07ab, 0x07ad, 0x07a6, 0x89be, 0x2ab8, 0x07aa, + 0x2aba, 0x07b1, 0x89ab, 0x07a8, 0x07af, 0x07b0, + /* 0x44 */ + 0x07a7, 0x07b2, 0x079d, 0x07a5, 0x07b5, 0x743e, 0x2ac7, 0x2ad7, + 0x8cf9, 0x0841, 0x8cf3, 0x8cf7, 0x2c70, 0x8e45, 0x8e48, 0x0872, + 0x2c9d, 0x086f, 0x0871, 0x8e44, 0x0885, 0x8eaf, 0x8eb1, 0x08a4, + 0x08a5, 0x08a6, 0x8fcf, 0x08a8, 0x8fcb, 0x8fcd, 0x08a3, 0x9050, + 0x91ec, 0x921a, 0x2d16, 0x2d24, 0x91d8, 0x0943, 0x91d0, 0x91d1, + 0x093d, 0x0945, 0x917b, 0x91d2, 0x0944, 0x91d4, 0x91e7, 0x91df, + 0x91de, 0x2d45, 0x91d9, 0x91cf, 0x950d, 0x09e3, 0x2f79, 0x5dfd, + 0x09df, 0x09e4, 0x2f7a, 0x09e5, 0x9538, 0x3054, 0x0a22, 0x0a4a, + 0x98a9, 0x0a49, 0x0a44, 0x0a4b, 0x0a87, 0x0a89, 0x0a92, 0x0a91, + 0x0a90, 0x0a8e, 0x993e, 0x9946, 0x9aed, 0xf630, 0x0b12, 0x0b10, + 0x0b11, 0x9c6c, 0x0b32, 0x0b34, 0x0b37, 0x0b33, 0x0b36, 0x0b35, + 0x0b65, 0x9dac, 0x337c, 0x337b, 0x9ec9, 0x3412, + /* 0x45 */ + 0x0bb0, 0x9f12, 0x0baf, 0x0baa, 0x9efd, 0x9f01, 0x9f11, 0x0bab, + 0x9f89, 0x9f05, 0x9efe, 0x9f0b, 0x9f20, 0x9f04, 0xa088, 0x0bf3, + 0xa102, 0x0bf4, 0xa103, 0x34b6, 0x34e0, 0x0c08, 0x0c4e, 0x0c55, + 0x0c4b, 0xa229, 0xa23b, 0x0c4d, 0x3573, 0xa206, 0x0c52, 0x3572, + 0x0c4c, 0x3570, 0x0c50, 0x0c53, 0xa203, 0x0c51, 0xa378, 0xa379, + 0xa37d, 0x0c89, 0xa37f, 0x0c95, 0x0ccc, 0x0cc8, 0x0cce, 0xa432, + 0x0cca, 0xa400, 0x369d, 0xa422, 0x0ccd, 0xa5a9, 0x0d5c, 0x0d67, + 0x0d69, 0x0d65, 0x0d62, 0xa704, 0x3827, 0x3835, 0xf659, 0x0daa, + 0xa8b8, 0xa99b, 0x0dd2, 0x39a2, 0x0e03, 0x0e0c, 0xaa92, 0x0e09, + 0x0e06, 0x0e05, 0x3989, 0xaa8f, 0x0e0b, 0x0e08, 0xaa98, 0x39a5, + 0xaaae, 0x0e8e, 0xad9d, 0x3ab6, 0x0ee8, 0xaf49, 0xaf50, 0xaf46, + 0x0eea, 0xaf4e, 0x3ba5, 0x3bc3, 0xaf55, 0x0ee9, + /* 0x46 */ + 0x0eeb, 0xaf64, 0x0ef0, 0xb138, 0x0f4b, 0x3dab, 0x0f73, 0x0f75, + 0x0f92, 0x0f91, 0x0f93, 0x3e25, 0x0fa7, 0x0fa6, 0x0fa8, 0x0faa, + 0xb3fe, 0x0fa9, 0x3e59, 0x0fbb, 0x0fbc, 0x0fba, 0x0fbd, 0x1027, + 0x3f85, 0xb6a6, 0x1024, 0x101e, 0x101f, 0x101d, 0x1020, 0x1023, + 0x1029, 0x1022, 0xb69c, 0xb699, 0x101c, 0x3f8e, 0x1028, 0xb6b5, + 0xb6a3, 0xb6a0, 0xb6a7, 0xb69b, 0xb8df, 0xb8e1, 0x1071, 0x1073, + 0x1072, 0xb94d, 0x1102, 0xbbf3, 0xbb6f, 0xbb69, 0x10fe, 0x41be, + 0xbb6b, 0xbb78, 0xbb87, 0x1108, 0xbb85, 0xbb82, 0xbb90, 0x1107, + 0x1104, 0xbb80, 0xbb67, 0x1100, 0x10fc, 0xbb61, 0x1144, 0xbb93, + 0x10f1, 0xbbf2, 0xbb86, 0x41a6, 0x1106, 0xbfcd, 0xbfc4, 0x11c6, + 0x11c3, 0x11c1, 0x11c2, 0xc10f, 0x11c4, 0x11c7, 0xc10d, 0x11bf, + 0x11d2, 0xc173, 0x11ca, 0xf6ba, 0xc10a, 0x442f, + /* 0x47 */ + 0xc108, 0xc113, 0x1213, 0xc3f8, 0x1230, 0x123e, 0x1239, 0xc4ab, + 0xc4a8, 0x123c, 0x123f, 0xc4a5, 0x1234, 0x123d, 0xc4c3, 0xc4a4, + 0x1238, 0xc4d4, 0xc4ba, 0xc5f1, 0x46a0, 0x1282, 0xc63f, 0x1283, + 0xc6ea, 0x129b, 0xc7f7, 0x12e0, 0x12dd, 0xc7fa, 0xc7f5, 0x12de, + 0xc7fe, 0x12e3, 0x12e5, 0xc800, 0x4797, 0x12e2, 0xc802, 0xc7fb, + 0xc807, 0x12df, 0xc81a, 0x132e, 0xc9b8, 0x1337, 0x1338, 0xc9e9, + 0xc9eb, 0xca50, 0xca4f, 0x498b, 0xcb86, 0x0162, 0xcb8e, 0x1394, + 0x1393, 0x13ab, 0x13ad, 0xccf0, 0xccfb, 0x13f5, 0x13f7, 0xce42, + 0x13f6, 0x13f8, 0xce85, 0x13fb, 0x13f9, 0x1458, 0x145a, 0xd105, + 0x1459, 0x4c0f, 0x1485, 0x14a4, 0x14d8, 0x14d9, 0xd54b, 0x14dd, + 0x14c8, 0xd563, 0x14fa, 0x14fb, 0x4f75, 0x1527, 0x4f9f, 0x152a, + 0x1525, 0xd799, 0x1528, 0xda81, 0xdb17, 0xdb10, + /* 0x48 */ + 0xdb12, 0x52a6, 0x1595, 0x539a, 0xdcfa, 0xdcf3, 0xdcf2, 0xdcf5, + 0xdcf6, 0xddbb, 0xddc2, 0xdea7, 0x160f, 0x1611, 0xdea8, 0xdea3, + 0x1610, 0xdeaa, 0x1615, 0x1613, 0x5457, 0xdfdc, 0x1647, 0x1646, + 0xe00f, 0x1659, 0x165b, 0xe079, 0x165e, 0xe07f, 0xe085, 0x165a, + 0x1691, 0x1692, 0x1690, 0x1693, 0xe21b, 0x54f7, 0x16be, 0xe277, + 0xe276, 0xe298, 0x16bc, 0x16bb, 0x16b7, 0x16b9, 0xe27a, 0x1701, + 0x16fe, 0xe3bc, 0xe3ba, 0x1702, 0xe3b6, 0x16ff, 0x55b0, 0xe3b4, + 0x1700, 0xe4cf, 0x1737, 0x173a, 0x176f, 0x1777, 0x1779, 0x56c6, + 0xe67b, 0x17c8, 0xe81c, 0xe821, 0xe81d, 0xe8c0, 0x17f2, 0xe8ff, + 0x17f1, 0x17f0, 0x5862, 0xeb56, 0x1834, 0xeda1, 0xeda2, 0xeda6, + 0xf056, 0xf057, 0x192c, 0x192d, 0xf101, 0xf1ed, 0xf71c, 0xf3f2, + 0x1afa, 0x5fb8, 0x0091, 0x5fc0, 0x0094, 0x5fb7, + /* 0x49 */ + 0x5fe1, 0x00c4, 0x010a, 0x63e8, 0x1c85, 0x64b2, 0x0152, 0x66ae, + 0x0159, 0x026f, 0x697e, 0x01f2, 0x01f4, 0x1e43, 0x6976, 0x01f1, + 0x1e3c, 0x6996, 0x026a, 0x6e20, 0x6e21, 0x6e23, 0x6e29, 0x7077, + 0x7151, 0x0324, 0x7156, 0x0323, 0x7188, 0x7159, 0x7155, 0x0327, + 0x7297, 0x7298, 0x036d, 0x21ed, 0x036e, 0x036f, 0x73a1, 0x73a3, + 0x2235, 0x039f, 0x040a, 0x0406, 0x040e, 0x770a, 0x040d, 0x0405, + 0x773d, 0x770c, 0x040b, 0x0410, 0x042e, 0x783d, 0x7839, 0x79b0, + 0x79b2, 0x79ae, 0x0496, 0x0497, 0x04c4, 0x2547, 0x04c5, 0x7b20, + 0x04d2, 0x7c6e, 0x7c6d, 0x7c6a, 0x0581, 0x7e32, 0x058e, 0x0590, + 0x058f, 0x7e39, 0x0591, 0x0595, 0x0593, 0x7da3, 0x266d, 0x7e7f, + 0x7e35, 0x7e3d, 0x7ff4, 0x7ff5, 0x063b, 0x0648, 0x8248, 0x8228, + 0x0646, 0x0647, 0x8227, 0x8232, 0x822c, 0x064c, + /* 0x4a */ + 0x822e, 0x064a, 0x0650, 0x0643, 0x8223, 0x8231, 0xf5c5, 0x0649, + 0x06a6, 0x06a5, 0x06a4, 0x84c9, 0x8589, 0x06b9, 0x85bb, 0x06ce, + 0x06cf, 0x0713, 0x8897, 0x8893, 0x8a28, 0x07c6, 0x07c5, 0x07ca, + 0x07d9, 0x07c1, 0x8a18, 0x8a3b, 0x2af5, 0x8a27, 0x8a24, 0x8a1b, + 0x8a31, 0x07cb, 0x8a26, 0x8aa3, 0x8a3f, 0x8a22, 0x8a19, 0x2b03, + 0x8a41, 0x8a2b, 0x2b65, 0x0842, 0x8d0c, 0x2c75, 0x0874, 0x0873, + 0x8e4e, 0x8eb9, 0x8efa, 0x8fe9, 0x8fe8, 0x8fe4, 0x2d8a, 0x2d56, + 0x0952, 0x925f, 0x925d, 0x9252, 0x0950, 0x9274, 0x094b, 0x9246, + 0x094c, 0x096d, 0x92aa, 0x2d98, 0x924a, 0x9259, 0x924b, 0x094f, + 0x2d68, 0x09f0, 0x9550, 0x3034, 0x3045, 0x0a4d, 0x0a4c, 0x98d0, + 0x0a4f, 0x0a4e, 0x0a50, 0x98cc, 0x315c, 0x0a96, 0x3156, 0x9964, + 0x9965, 0x0a97, 0x0a95, 0x0a98, 0x995c, 0x9b15, + /* 0x4b */ + 0x0aec, 0x0aeb, 0x0b13, 0x0b14, 0x0b38, 0x0b3a, 0x0b39, 0x9c79, + 0x0b68, 0x0b67, 0x9dc5, 0x9db8, 0x9f2c, 0x0bbe, 0x0bbc, 0x9f37, + 0x9f35, 0x9f31, 0x0bbb, 0x9f2f, 0x0bba, 0x9f2b, 0x0bb9, 0x0bb7, + 0x9f2d, 0x9f2a, 0x0bc1, 0xa095, 0x0bf7, 0xa23e, 0x0c60, 0xa247, + 0xa245, 0x0c59, 0x0c5c, 0x0c5a, 0x0c58, 0xa252, 0x0c5b, 0xa270, + 0xa250, 0xa258, 0xa251, 0xa23d, 0x0c5d, 0xa241, 0xa20c, 0xa23c, + 0xa386, 0xa383, 0xa389, 0xa3f3, 0x0cd4, 0x0cd3, 0x36bf, 0x0cd2, + 0x36bd, 0xa42d, 0x0cd7, 0x0cd1, 0x36e4, 0x0cd5, 0xa5c5, 0xf655, + 0x0d6d, 0x0d6f, 0x3834, 0x0d75, 0x0d6c, 0x0d74, 0xa743, 0x0d73, + 0xa737, 0xa745, 0x3836, 0x0dac, 0xa8e5, 0xa9a6, 0xaadb, 0x0e10, + 0xaada, 0xaae6, 0x39ba, 0x39bc, 0x0e0f, 0x39c8, 0x0e23, 0x39c3, + 0x0e1d, 0x39b6, 0x0e0e, 0xaaf8, 0xaae9, 0x0e15, + /* 0x4c */ + 0x39c2, 0x0e13, 0xaae8, 0xaaf6, 0x0e1b, 0x39c5, 0x0e22, 0x0e26, + 0xaae7, 0x39bd, 0x39b0, 0x0e21, 0x0e1c, 0x0e17, 0xaad5, 0x0e1a, + 0x39bb, 0xadd3, 0xadc7, 0xadd1, 0x0e99, 0xadc3, 0x0e97, 0xaf80, + 0xaf98, 0x0efd, 0xaf84, 0x0ef6, 0x0efe, 0x0ef5, 0x0eff, 0x0ef7, + 0xaf97, 0xaf83, 0xaf81, 0x0f01, 0x3c04, 0xaf8c, 0xb142, 0xb2ab, + 0x0f77, 0xb2a3, 0xb2a6, 0xb35c, 0xb369, 0xb367, 0x0fab, 0xb48b, + 0xb4a8, 0x0fc0, 0xb6d8, 0x1031, 0x102e, 0xf689, 0xb6dc, 0x102c, + 0xb6e0, 0xb6e5, 0x1032, 0x102f, 0x102b, 0x102d, 0x1033, 0xb818, + 0xb819, 0x3ff1, 0x1057, 0x105c, 0x107b, 0xb95f, 0xb95e, 0x107a, + 0xbc02, 0x4222, 0x1113, 0x111e, 0x1117, 0x1120, 0x112a, 0x1111, + 0x1115, 0x110f, 0x1118, 0x4238, 0xbc12, 0xbc36, 0x112c, 0x4232, + 0xf6a8, 0x4210, 0xbc23, 0xbc03, 0x111c, 0xbc00, + /* 0x4d */ + 0x1129, 0xbc46, 0xbc61, 0x1112, 0x424f, 0x1197, 0xc184, 0x4472, + 0xc16b, 0xc162, 0xc156, 0xc16a, 0xc152, 0xc155, 0x11d4, 0x11d0, + 0x447c, 0xc161, 0xf6bb, 0xc158, 0xc177, 0x11d3, 0x1214, 0xc4d7, + 0x1246, 0x1245, 0xc4de, 0x1243, 0xc4df, 0x460d, 0x1244, 0x1248, + 0xc4d1, 0x1247, 0xc4e2, 0xc4e1, 0xc4dd, 0x4608, 0x1249, 0x1285, + 0xc64b, 0x1284, 0xc64e, 0x129d, 0xc6fc, 0x129e, 0x12a0, 0xc6fa, + 0x129c, 0xc6fb, 0x129f, 0xc6fe, 0x12f7, 0x12ea, 0xc831, 0x12ef, + 0x12e9, 0x12f3, 0x12f0, 0x12eb, 0xc838, 0x12ec, 0x12f2, 0x12f5, + 0x12ee, 0xc83a, 0xc9bb, 0x133a, 0x134b, 0xca59, 0x134a, 0x134c, + 0xcadb, 0xcadf, 0xcae2, 0x1379, 0x137b, 0x1378, 0xcb9e, 0xcba1, + 0x13b5, 0xcd10, 0x13b4, 0x13b7, 0x4a9e, 0x1409, 0x13fe, 0x1408, + 0x1407, 0xce76, 0xce7f, 0xce7d, 0x1406, 0x1404, + /* 0x4e */ + 0x1405, 0x13ff, 0x140b, 0xce82, 0xd057, 0x143b, 0x145d, 0x145c, + 0x145f, 0x145e, 0x4c28, 0xd12e, 0x4c21, 0x1483, 0xd38b, 0xd38d, + 0x14a7, 0x4d66, 0x4d6c, 0xd390, 0x14a8, 0xd4ec, 0xd56f, 0xd56b, + 0xd571, 0xd578, 0x4df6, 0x14e0, 0x14df, 0x14fe, 0x14fc, 0x14ff, + 0x14fd, 0xd7ad, 0x152c, 0x4fec, 0x4fba, 0x4fe3, 0x4fbd, 0x159d, + 0xdb2f, 0x52b4, 0xdd78, 0x1640, 0xdff8, 0xe019, 0x165f, 0xe09b, + 0xe094, 0xe097, 0xe099, 0xe1a6, 0xe1a4, 0xe1a7, 0x54d1, 0xe295, + 0x16c0, 0x5523, 0xe290, 0x16c1, 0x16c6, 0xe29b, 0xe3c4, 0x1704, + 0x1705, 0xe3c6, 0x560b, 0x173e, 0x173d, 0x1740, 0x173f, 0xe4e3, + 0x1742, 0xe4df, 0xe4dd, 0xe4e7, 0x1784, 0x1782, 0x177f, 0x1785, + 0xe82d, 0xe82c, 0x17cc, 0x57b2, 0x17cb, 0x17cd, 0xe834, 0xe838, + 0x57db, 0xe91d, 0x17f5, 0xe91a, 0xe91b, 0xe914, + /* 0x4f */ + 0x57f0, 0xe917, 0xea21, 0x1820, 0x1821, 0xeaaa, 0xeaa1, 0x1837, + 0x183e, 0x5873, 0x183d, 0x586e, 0xeb63, 0xeb79, 0xeb60, 0x5865, + 0xeb62, 0x183c, 0xeb61, 0x1838, 0x586a, 0xeb70, 0x586d, 0xeb6a, + 0x183b, 0xedc8, 0x18b0, 0xedc5, 0xedbe, 0xedc2, 0x18ad, 0x18b2, + 0x18b8, 0x5a0b, 0xedc7, 0x18af, 0xedb0, 0xedca, 0x191a, 0x5b76, + 0x1920, 0x1921, 0x1930, 0x5ba8, 0x192f, 0xf10d, 0xf107, 0xf196, + 0xf1ef, 0x195f, 0x1960, 0xf21e, 0xf21d, 0x5c11, 0xf390, 0x5feb, + 0x008a, 0x1b19, 0x009c, 0x5fee, 0x009a, 0x5fef, 0x5fec, 0x63fa, + 0x010c, 0x010b, 0x010d, 0x1c92, 0x6504, 0x69d3, 0x01fe, 0x69d1, + 0x69fa, 0x01ff, 0x01fb, 0x01fc, 0x0209, 0x69c8, 0x0200, 0x69d5, + 0x1e75, 0x69cd, 0x69d2, 0x69fb, 0x6c2a, 0x6e88, 0x6e61, 0x0271, + 0x6e63, 0x6e62, 0x206f, 0x5e57, 0x71c8, 0x7198, + /* 0x50 */ + 0x032b, 0x73c1, 0x773f, 0x7741, 0x0414, 0x0411, 0x0412, 0x7852, + 0x0463, 0x785e, 0x046e, 0x049a, 0x79c7, 0x049b, 0x7a70, 0x7b27, + 0x04c8, 0x7b71, 0x7bb0, 0x04f6, 0x7e42, 0x7e43, 0x26a5, 0x058c, + 0x0597, 0x05a2, 0x26a0, 0x7e57, 0x7e9d, 0x8289, 0x828d, 0x828b, + 0x8280, 0x8292, 0x828a, 0x82c8, 0x0654, 0x828f, 0x8293, 0x8291, + 0x06a8, 0x84f2, 0x84de, 0x06a9, 0x85c8, 0x28b4, 0x28d8, 0x29c2, + 0x0718, 0x0717, 0x071d, 0x87a7, 0x87a1, 0x0731, 0x8a8c, 0x8a7f, + 0x07d8, 0x07d5, 0x8a7b, 0x8a95, 0x8a99, 0x07e1, 0x8a8e, 0x07d4, + 0x8ada, 0x8a8a, 0x8a9c, 0x07e3, 0x8a7e, 0x0844, 0x0845, 0x8d1a, + 0x8e55, 0x0876, 0x0875, 0x8e60, 0x2ca8, 0x0888, 0x08aa, 0x8ffb, + 0x08ab, 0x08ac, 0x8ffd, 0x0957, 0x2d83, 0x0960, 0x095d, 0x096b, + 0x92d0, 0x0963, 0x0967, 0x92c5, 0x095e, 0x92d2, + /* 0x51 */ + 0x9311, 0x2dc5, 0x2fcd, 0x09f9, 0x09f3, 0x95ad, 0x95a4, 0x95a9, + 0x95b0, 0x959d, 0x09f6, 0x9798, 0x309c, 0x0a51, 0x0a53, 0x0a52, + 0x9992, 0x0a9b, 0x998a, 0x0a9c, 0x998d, 0x9996, 0x0af7, 0x3299, + 0x328f, 0x3291, 0x9b45, 0x9b4b, 0x9c0f, 0x9c16, 0x0b3b, 0x9c8a, + 0x0b3e, 0x0b3d, 0x9dc9, 0x0b69, 0x9dc8, 0x9dca, 0x9f64, 0x0bc3, + 0x0bc4, 0x0bc7, 0x9f5d, 0x9f63, 0x3439, 0x0bc6, 0x342e, 0x0bc8, + 0x9f88, 0xa03a, 0xa039, 0x349f, 0x34a0, 0x0be6, 0x0bf8, 0xa117, + 0xa193, 0x0c07, 0xa195, 0x0c64, 0x0c68, 0xa276, 0x3594, 0x0c65, + 0x35ae, 0xa280, 0xa27b, 0x0c69, 0xa248, 0xa2a8, 0xa288, 0xa38b, + 0xa38a, 0xa38c, 0xa3fc, 0x0cda, 0x0ce0, 0x36e6, 0xa458, 0x0cde, + 0xa451, 0xa455, 0xa453, 0x0d1c, 0x0d1d, 0x0d1a, 0xa5dc, 0x0d7b, + 0x0d7a, 0x0d7c, 0xa75c, 0x0d78, 0x0d77, 0xa765, + /* 0x52 */ + 0xf65a, 0x0db1, 0xa8ee, 0x0db2, 0x0db0, 0xa8f0, 0x38bc, 0xa8f2, + 0x0e36, 0xab35, 0x0e2e, 0xab22, 0x39d6, 0xab20, 0x0e34, 0xab2d, + 0xab28, 0xab26, 0xab3c, 0x0e2a, 0xab38, 0x0e33, 0x0e2d, 0x0e2f, + 0x0e31, 0x0e2b, 0x0e32, 0xab2a, 0x0e35, 0xab1a, 0xab30, 0xaae3, + 0xab19, 0xade9, 0xade7, 0x3acf, 0xafd6, 0xafc4, 0x0f08, 0xaf87, + 0x0f06, 0xafc7, 0xafd9, 0x3c18, 0xafdf, 0x0f4d, 0x0f61, 0xb20a, + 0xb201, 0xb2b1, 0x0f78, 0xb2c1, 0x0f94, 0x0f95, 0xb376, 0xb40d, + 0xb40e, 0x0fc1, 0x0fc3, 0x3e6d, 0xb707, 0x1039, 0xb709, 0xb716, + 0x103a, 0x103b, 0x1035, 0x1036, 0xb70e, 0x103c, 0x3f90, 0xb706, + 0xb81e, 0xb84a, 0x1058, 0x107c, 0x107d, 0x108d, 0x108c, 0xbca6, + 0xbc91, 0x113b, 0x113f, 0xbcb8, 0xbc96, 0x1132, 0x112d, 0xbcc5, + 0x112f, 0x1139, 0x112e, 0x113a, 0xbd0a, 0x1136, + /* 0x53 */ + 0x1131, 0x113e, 0x1138, 0x4252, 0x1134, 0xbcb2, 0x1141, 0xbcb7, + 0xbcb4, 0xbc89, 0xbc8d, 0x1130, 0xbc87, 0xbcc2, 0xbc9c, 0xbc92, + 0x1143, 0xbcca, 0x4250, 0xbc8a, 0xbfe0, 0x1198, 0xbfe6, 0xbfe5, + 0x44a0, 0xc1a5, 0xc1b3, 0x4486, 0x11da, 0x11d7, 0xc1b5, 0xc1af, + 0x4495, 0xc1b0, 0xc1cc, 0x448c, 0xc1a2, 0xc1be, 0xc1c6, 0xc1ac, + 0xc1ae, 0x1218, 0x4560, 0xf6c3, 0xc508, 0xc505, 0x1252, 0x4628, + 0xc4fe, 0x124e, 0x4620, 0xc500, 0x124f, 0x1250, 0xc664, 0xc668, + 0x46a8, 0x1286, 0x1287, 0x1289, 0xc66a, 0xc669, 0xc70d, 0xc712, + 0x12a2, 0x12a3, 0xc70f, 0x12a1, 0xc867, 0xc879, 0xc872, 0xc866, + 0xc87c, 0x12f9, 0x12fd, 0xc868, 0xc885, 0xc876, 0xc874, 0xc871, + 0xc864, 0x133e, 0x133c, 0xc9f8, 0x134d, 0xca6c, 0x134e, 0xcaeb, + 0x1381, 0x1383, 0x1382, 0xcbb8, 0x1380, 0x1388, + /* 0x54 */ + 0xcd2d, 0xcd2e, 0xcd28, 0xcd29, 0xcd31, 0x13b9, 0xcd2f, 0xcd2a, + 0x4b3a, 0xcea4, 0xceb7, 0xcebf, 0x1411, 0x140d, 0x1410, 0x1413, + 0xd063, 0x143c, 0x1462, 0x1463, 0xd167, 0xd3be, 0xf6e0, 0xd595, + 0xd59c, 0x1503, 0x1506, 0x1502, 0x1501, 0xd671, 0xd672, 0x1505, + 0xd66f, 0x4e94, 0x5011, 0xd7f1, 0x5037, 0x1536, 0xd7e8, 0x1535, + 0x5043, 0xf6ea, 0x15a1, 0x15a3, 0xdb49, 0xdb64, 0x15a0, 0xdb48, + 0x15ea, 0x53a6, 0x15e8, 0xdd2c, 0xdde1, 0xddef, 0xdec0, 0x1621, + 0x161b, 0xded7, 0xded4, 0x1649, 0x1648, 0xe0ad, 0x5495, 0x1662, + 0x1661, 0x1664, 0x1660, 0x1663, 0xe0ae, 0xe0ac, 0x5496, 0x1666, + 0x16ac, 0x16ab, 0xe227, 0xe2ae, 0x16c3, 0xe2b0, 0x16c4, 0x5525, + 0xe2c0, 0xe2c4, 0x1708, 0x1709, 0x170a, 0x1706, 0x1707, 0x1741, + 0xe507, 0x1745, 0xe4fd, 0x1743, 0x1744, 0x5626, + /* 0x55 */ + 0x5634, 0x1747, 0xf704, 0xe61b, 0xe61c, 0x1771, 0xe6b2, 0xe6b4, + 0xe6b7, 0xe6b1, 0xe6b3, 0xe6ae, 0x178b, 0x17d4, 0x17d3, 0x17d1, + 0x57ba, 0x17d2, 0xe83f, 0xe936, 0x17f7, 0x17f8, 0xe931, 0xe93b, + 0xe935, 0xe93a, 0xe937, 0xea22, 0xea36, 0xea32, 0x1822, 0xeac0, + 0x1845, 0x1841, 0x5881, 0x1840, 0x588a, 0xeb85, 0x587f, 0x1842, + 0xeb89, 0x18c1, 0x18c5, 0xede1, 0x18bb, 0x18b9, 0x18bd, 0x18c9, + 0xee0a, 0x5a11, 0xee09, 0x18bf, 0x18c7, 0xede8, 0x18c3, 0x1924, + 0x1931, 0x1933, 0xf118, 0x1932, 0x1934, 0x1952, 0x1961, 0x5bd9, + 0x197a, 0x1982, 0x5c3c, 0xf3c5, 0x1b23, 0x600d, 0x600c, 0x6021, + 0x1b2c, 0x6216, 0x640e, 0x010f, 0x1c95, 0x6417, 0x0123, 0x0125, + 0x6a48, 0x0206, 0x0208, 0x1e88, 0x6a55, 0x6a49, 0x6a4c, 0x1e8b, + 0x6a4f, 0x6a3d, 0x027a, 0x0277, 0x6e8a, 0x6ea8, + /* 0x56 */ + 0x708a, 0x032e, 0x71cb, 0x032f, 0x71d5, 0x78d4, 0x041b, 0x0413, + 0x775c, 0x7775, 0x0466, 0x7861, 0x0465, 0x7096, 0x04f7, 0x7c8a, + 0x7ed0, 0x26e1, 0x26d7, 0x7e49, 0x7ecf, 0x059c, 0x82d6, 0x827f, + 0x0653, 0x82d2, 0x82cf, 0x8506, 0x8509, 0x06ba, 0x28a3, 0x0722, + 0x29d3, 0x8b06, 0x8af1, 0x8b04, 0x2b8b, 0x8afa, 0x8af4, 0x07eb, + 0x07dd, 0x8af9, 0x07ef, 0x8a8b, 0x8b03, 0x0847, 0x0846, 0x8da2, + 0x0878, 0x2cac, 0x0889, 0x900c, 0x900b, 0x0968, 0x0976, 0x0974, + 0x0979, 0x9324, 0x097a, 0x0977, 0xf614, 0x0971, 0x9325, 0x0972, + 0x95f6, 0x09ff, 0x95fb, 0x0a05, 0x9732, 0x97fb, 0x0a54, 0x98f2, + 0x98f3, 0x0a9e, 0x0a9f, 0x3174, 0x999c, 0x9b72, 0x0afa, 0x9b74, + 0x0b44, 0x0b3f, 0x0b40, 0x9c86, 0x0b42, 0x9c8e, 0x9c90, 0x0b51, + 0x9ccd, 0x9cf7, 0x9dd6, 0x9f84, 0x9f95, 0x9f8a, + /* 0x57 */ + 0x3440, 0x0bca, 0x9f97, 0x3441, 0x0bce, 0x0bc9, 0xa0a0, 0xa0a1, + 0xa122, 0xa1a6, 0xa1a4, 0x0c09, 0x34e8, 0x0c6c, 0x0c6e, 0x0c70, + 0x0c6d, 0x0c6b, 0x0c71, 0x0c72, 0xa2af, 0xa2b0, 0xa2bd, 0x0c8c, + 0x0ce4, 0xa476, 0x0ce1, 0xa47b, 0xa479, 0x36f6, 0x0ce7, 0x3700, + 0x0ce2, 0x0d1f, 0xa5ee, 0xa5f1, 0x0d7e, 0xa794, 0x0d80, 0x3859, + 0x3855, 0xa791, 0x0db9, 0x0db7, 0x0db8, 0xa910, 0x0dba, 0x38f4, + 0xa9af, 0x0dd3, 0x0e3f, 0x3a04, 0x0e45, 0x0e41, 0x3a15, 0x0e42, + 0x0e43, 0x0e3b, 0x0e38, 0xab7b, 0xab77, 0x0e3a, 0x39f5, 0xab80, + 0xabc6, 0x0e3c, 0xab7c, 0xab90, 0x0e3e, 0xaba3, 0xab7d, 0xabbd, + 0x0e9e, 0x0e9f, 0x0ea1, 0xae13, 0x0e9b, 0x0f12, 0xb011, 0xb044, + 0xb00d, 0x0f18, 0x0f0c, 0xb214, 0x0f62, 0xb2b8, 0x0f7a, 0xb2b7, + 0xb383, 0x0fae, 0x0faf, 0xb414, 0x0fad, 0xb41c, + /* 0x58 */ + 0x0fc4, 0x0fc7, 0x0fc6, 0x0fc5, 0xb4d4, 0xb4d5, 0x3fc1, 0x1040, + 0xb743, 0xb742, 0x103f, 0x1041, 0xf68a, 0xb741, 0xb84e, 0x107f, + 0xb987, 0x1086, 0x1081, 0x1080, 0x108e, 0x114a, 0xbd39, 0x1147, + 0xbd8f, 0xbd2a, 0x114b, 0x1146, 0x114e, 0x427d, 0xbd2b, 0x42a5, + 0xbd50, 0x1148, 0xbd6e, 0x1145, 0xbd3b, 0xbd53, 0xbd5f, 0xbd2f, + 0xbd30, 0xbd38, 0xbd4c, 0xbff1, 0x11db, 0x11e7, 0x11e4, 0xc207, + 0xc216, 0x11e1, 0xc214, 0x11e9, 0xc1fb, 0x11e5, 0x11e0, 0x11e3, + 0xc1f8, 0xc210, 0xc21d, 0xc1ff, 0xc20b, 0xc204, 0x11ea, 0xc1fe, + 0xc3ff, 0x463a, 0x1254, 0x1258, 0x125c, 0xc523, 0x1255, 0x128b, + 0x128c, 0x12a6, 0x12a5, 0xc72a, 0xc8a0, 0xc898, 0xc89c, 0x12ff, + 0xc89e, 0xc8a6, 0xc8b5, 0xc8b0, 0x1330, 0x1340, 0x1341, 0xcaf9, + 0xcaf5, 0x1386, 0xcbd2, 0x13bf, 0x13bd, 0xcd50, + /* 0x59 */ + 0xcd4e, 0xcd4b, 0xcd52, 0xcd4d, 0x13be, 0x1419, 0xcee4, 0x141c, + 0xceda, 0x141b, 0x1417, 0x1418, 0x4b51, 0xcedf, 0xcee8, 0x143d, + 0x146a, 0x1466, 0xd170, 0xd172, 0x1467, 0xd177, 0x1468, 0x14ad, + 0x14ae, 0xd3e6, 0xd5aa, 0x14d6, 0x1509, 0xd68c, 0x4e98, 0xd689, + 0x150c, 0x150a, 0xd832, 0x153b, 0x153a, 0x5084, 0x5081, 0xd87a, + 0x506f, 0xda9e, 0xdaa0, 0xdb70, 0x15af, 0x15aa, 0x15ab, 0xdb6e, + 0xdb66, 0x15b1, 0xdb65, 0x15ac, 0x15ec, 0xdd7f, 0xdde0, 0x1601, + 0xddff, 0xdef6, 0xdef7, 0xdef5, 0x1623, 0xdefc, 0x1624, 0x161e, + 0xdef9, 0x164a, 0x1665, 0x166a, 0xe0ca, 0xe0c3, 0xe0c6, 0x1669, + 0xe1b8, 0xe1bd, 0x1695, 0xe1bc, 0xe205, 0xe2e0, 0xe2e9, 0x5542, + 0xe2df, 0xe2ec, 0x16cc, 0xe2e5, 0xe2de, 0xf700, 0x16cf, 0xe2f0, + 0xe2e3, 0x170f, 0xe3ec, 0x170e, 0x170b, 0x1710, + /* 0x5a */ + 0x170d, 0x170c, 0xe3f2, 0xe3ef, 0xe3e9, 0xe4fb, 0x1746, 0x1748, + 0x5637, 0x1749, 0xe537, 0xe6de, 0x1791, 0x178e, 0xe6da, 0x17d8, + 0x17d6, 0xe84b, 0x17da, 0xe849, 0x17d7, 0xe8d5, 0x57ff, 0x17f9, + 0xe952, 0xe947, 0x17fc, 0xe948, 0xeacc, 0xead0, 0x58a9, 0x184a, + 0x58a7, 0x184e, 0x58b3, 0x58ac, 0x58b0, 0xeb86, 0xeba7, 0xeba3, + 0x589c, 0xebb6, 0xebad, 0xee13, 0x5a3c, 0x5a1c, 0x5a3a, 0x18d3, + 0x18cd, 0x18d1, 0xee17, 0xee22, 0x5a32, 0x5a34, 0xee49, 0xee26, + 0xf70c, 0xee3c, 0xee28, 0xf0a8, 0x5bc7, 0xf1fb, 0x1962, 0xf232, + 0xf2d6, 0xf348, 0x1983, 0x5c3f, 0xf3c6, 0x1992, 0x009f, 0x00a0, + 0x6025, 0x6026, 0x6024, 0x6033, 0x6170, 0x0127, 0x6790, 0x020b, + 0x6a95, 0x6aa1, 0x6a92, 0x6a8f, 0x6a9f, 0x6a96, 0x6a98, 0x6a9d, + 0x6aa0, 0x028d, 0x7097, 0x71eb, 0x0370, 0x7787, + /* 0x5b */ + 0x24eb, 0x7b32, 0x059a, 0x059f, 0x059d, 0x7ed8, 0x7efb, 0x7f06, + 0x059b, 0x7ed1, 0x26d5, 0xf5b0, 0x0660, 0x0664, 0x0669, 0x0663, + 0x0667, 0x0662, 0x82f6, 0x8304, 0x82fe, 0x2802, 0x82ff, 0x82f7, + 0x8518, 0x06ac, 0x8514, 0x85cd, 0x8620, 0x87de, 0x0726, 0x0723, + 0x0725, 0x8b45, 0x8b53, 0x07f8, 0x8b4b, 0x8b55, 0x8b41, 0x07f7, + 0x07fb, 0x07fa, 0x8b5c, 0x8b54, 0x8e71, 0x8ed0, 0x08b0, 0x08af, + 0x9053, 0x9329, 0x937e, 0x097e, 0x9379, 0x097d, 0x0980, 0x9370, + 0x936a, 0x097f, 0x0986, 0x9385, 0x9364, 0x2e12, 0x9378, 0x0981, + 0x9632, 0x9627, 0x962f, 0x0a24, 0x0a58, 0x0a57, 0x0aa0, 0x99ba, + 0x0afe, 0x9b71, 0x9b8c, 0x0b15, 0x9c1a, 0x0b47, 0x0b46, 0x9c98, + 0x9de4, 0x0b6b, 0x0b6c, 0x3385, 0x3454, 0x9fc2, 0x0bcc, 0x9fba, + 0x3455, 0x9fc8, 0x0bcb, 0x34a7, 0x34a8, 0x0bf9, + /* 0x5c */ + 0xa1b9, 0xa1b8, 0xa1a5, 0xa2e2, 0x0c78, 0x0c7a, 0x0c75, 0xa2d9, + 0x0c76, 0x0c77, 0xa2ac, 0xa2dd, 0x0cea, 0x0cee, 0x0ced, 0xa49d, + 0x0cec, 0x370f, 0xa611, 0xa603, 0x0d84, 0x0d85, 0x0d83, 0xa7ee, + 0x0dbc, 0x0dbd, 0x0dd4, 0xaba4, 0xabd8, 0xabdd, 0xabde, 0x0e55, + 0xabe7, 0x0e50, 0x0e4c, 0x0e48, 0xabd4, 0x0e53, 0xabce, 0x0e57, + 0x0e54, 0x0e4e, 0x0e4a, 0x0e51, 0xabf1, 0xabd3, 0x0e49, 0x0e4b, + 0x0e63, 0xabca, 0xabe9, 0x0ea7, 0x0ea6, 0x0ea4, 0xae1a, 0xae41, + 0xf668, 0x3ae4, 0x3ae5, 0xb03d, 0xb040, 0x3c65, 0x3c4e, 0x0f17, + 0xb043, 0x0f16, 0xb03f, 0xb03c, 0x0f63, 0xb221, 0xb220, 0x3d82, + 0xb2c6, 0x0f7b, 0x0f7c, 0xb2d1, 0xb2ca, 0xb38e, 0xb391, 0x0fb0, + 0x3e2d, 0xb4e3, 0xb788, 0x1042, 0xb770, 0x1044, 0xb89d, 0xb99d, + 0xb991, 0xb998, 0xb999, 0x1088, 0x108f, 0x1153, + /* 0x5d */ + 0x115b, 0xbdbf, 0x1159, 0xbdae, 0xbdb1, 0xbdcc, 0xbe04, 0x42ca, + 0xbe16, 0xbdcd, 0x1154, 0x42bc, 0xbde0, 0xbdcb, 0xbdd4, 0xbdc9, + 0xbfff, 0x1199, 0xbffd, 0xc257, 0xc252, 0xc250, 0xc245, 0xc24d, + 0x11f1, 0xc253, 0x11ef, 0xc282, 0xc244, 0xc3ce, 0xc3cf, 0xc3d2, + 0xc402, 0xc54f, 0xc558, 0x1262, 0xc543, 0x1263, 0xc552, 0x1260, + 0x1261, 0x125f, 0xc549, 0xc553, 0xc54d, 0x128d, 0xc684, 0x128e, + 0xc683, 0xc732, 0xc8e2, 0x1309, 0xc8e4, 0xc8d3, 0x1305, 0xc8d5, + 0xc8dd, 0x1303, 0x1306, 0xc8ec, 0xc8e6, 0xc8d2, 0xc8fa, 0xc8da, + 0x1331, 0xca06, 0xca04, 0x134f, 0xca7b, 0xcb04, 0xcb02, 0x1366, + 0x49ff, 0x13c4, 0xcd60, 0x13c3, 0x13c1, 0x13c5, 0xcf07, 0xcf05, + 0xcf0c, 0x1421, 0xcf5a, 0x141f, 0x1422, 0xcf1a, 0x1427, 0x1420, + 0xd18a, 0x146d, 0x146c, 0x146b, 0x146f, 0x1470, + /* 0x5e */ + 0xd18c, 0xd409, 0xd6a6, 0x4ea6, 0xd6ac, 0xd6a9, 0x1542, 0xd88b, + 0x50b6, 0xd88c, 0x1544, 0x1540, 0xd888, 0xd889, 0x153f, 0xd893, + 0x50ab, 0x158b, 0xdb83, 0xdd4f, 0x1625, 0x1628, 0xdf20, 0x5421, + 0xe036, 0xe0e2, 0x1675, 0x1672, 0xe0ee, 0x166f, 0xe0e7, 0xe0e9, + 0x1676, 0x1671, 0x54a7, 0xe0df, 0x1697, 0xe1c7, 0x16d7, 0xe309, + 0x16d6, 0xe301, 0x16d8, 0x16dc, 0x16db, 0x16d4, 0x553e, 0x1713, + 0x1711, 0x1714, 0xe405, 0xe40c, 0xe578, 0xe55d, 0x1751, 0x1750, + 0x1753, 0x1754, 0x1752, 0xe55e, 0xe560, 0xe567, 0x176d, 0xf705, + 0xe6f4, 0x1795, 0x1799, 0xe6f1, 0x179a, 0xe6fa, 0x1793, 0x1797, + 0xe6f8, 0xe6f9, 0xe709, 0xe6fd, 0xe6f7, 0x17dc, 0xe859, 0x17fd, + 0xe960, 0xe968, 0x17fe, 0x1800, 0x1802, 0x1801, 0x1803, 0xe96a, + 0xea14, 0xea3e, 0xeae4, 0x1827, 0x1826, 0x1824, + /* 0x5f */ + 0x184c, 0x58bc, 0x1850, 0x1855, 0x1853, 0x58b7, 0x1852, 0xebd2, + 0x1857, 0x58be, 0x1858, 0x18d6, 0xee58, 0xee50, 0x18d4, 0xee5c, + 0x18da, 0x18d9, 0xcf19, 0x5a62, 0x18d5, 0x18e4, 0xf70e, 0x18dc, + 0x191b, 0x5b8f, 0x1937, 0x1936, 0x194b, 0x5bcb, 0x1966, 0x1976, + 0xf2df, 0x197e, 0x197d, 0x197f, 0x1984, 0x198b, 0xf3d9, 0x1994, + 0x00a1, 0x0111, 0x6566, 0x0210, 0x1ea9, 0x6ae1, 0x6aef, 0x6ae8, + 0x6c33, 0x2013, 0x71fe, 0x0332, 0x21f4, 0x73ef, 0x73ec, 0x75ec, + 0x779c, 0x0420, 0x7799, 0x7870, 0x786e, 0x049d, 0x7b41, 0x26ec, + 0x26ef, 0x7f02, 0x7f01, 0x05a5, 0x801b, 0x8323, 0x8325, 0x8324, + 0x8326, 0x8333, 0x832f, 0x858f, 0x8856, 0x0802, 0x07fe, 0x0801, + 0x2bd6, 0x0803, 0x07ff, 0x8b99, 0x0804, 0xf5ed, 0x084a, 0x8ed9, + 0x0987, 0x93b7, 0x0984, 0x93b6, 0x0985, 0x3009, + /* 0x60 */ + 0x9654, 0x9657, 0x967a, 0x0a59, 0x3179, 0x9b8e, 0x32c6, 0x9b90, + 0x9bb9, 0x0b04, 0x0b49, 0x0b48, 0x9def, 0x0b6d, 0x0bd2, 0x0bd3, + 0x9fe2, 0x0bd1, 0x9fd6, 0x9fd8, 0x9fda, 0x9fde, 0x0be7, 0x0c0a, + 0x35c3, 0xa308, 0xa304, 0xa30a, 0xa30b, 0xa302, 0x0cf0, 0xa4aa, + 0xa4c1, 0x371f, 0xa7d7, 0xa7d9, 0x3865, 0xa7de, 0xa7da, 0x0dbe, + 0x0dbf, 0xa92a, 0x38c6, 0x3a3a, 0xac31, 0x3a36, 0xac2b, 0xac2c, + 0xac29, 0xac2e, 0x0e5e, 0xac27, 0xac28, 0x0e5b, 0xac5f, 0xac30, + 0xac24, 0x3aeb, 0x0eab, 0xae3a, 0x0eac, 0xae39, 0xae40, 0xb080, + 0xb084, 0x0f1f, 0x0f1d, 0xb075, 0xb076, 0x0f1c, 0xb07c, 0x0f1e, + 0xb078, 0xb09b, 0xb07e, 0xb15a, 0x0f64, 0xb22c, 0x3d84, 0xb39c, + 0xb747, 0xb78a, 0x1048, 0x1047, 0xb827, 0xbe4a, 0x115e, 0x1161, + 0xbe27, 0x42e0, 0x42f3, 0xbe2e, 0xbe26, 0xc008, + /* 0x61 */ + 0x11f7, 0xc2bd, 0xc296, 0x11f4, 0x11f8, 0x451e, 0xc2be, 0xc28e, + 0xc574, 0x1264, 0xc580, 0x1292, 0x128f, 0x1290, 0x46b4, 0x1293, + 0x12a8, 0xc73c, 0xc73d, 0x12a9, 0xc73a, 0xc742, 0x46f9, 0xc924, + 0xc906, 0x4844, 0x130e, 0xc915, 0x130f, 0xc902, 0xc90c, 0x130b, + 0xc908, 0xc90a, 0xc905, 0xc91c, 0x1310, 0x1351, 0xca82, 0x1350, + 0xca86, 0x1363, 0xcc03, 0xcd7b, 0x13c7, 0xcd7a, 0x4b71, 0x1424, + 0x1426, 0x4b6e, 0xcf80, 0x4b79, 0xcf58, 0x4bc4, 0x1474, 0x1473, + 0x1472, 0xd1aa, 0xd1ab, 0xd236, 0xd24a, 0x14b1, 0x4d8c, 0xd5d6, + 0x150e, 0x1511, 0x1510, 0x150f, 0x1512, 0x1549, 0x50c9, 0x154f, + 0x154d, 0xd903, 0xd8cf, 0x1555, 0xdb9f, 0xdba2, 0xde2a, 0xde2f, + 0xdf44, 0xdf40, 0x162c, 0x162b, 0xe111, 0xe10f, 0x1679, 0xe10d, + 0xe107, 0xe103, 0x167a, 0x54b0, 0x1699, 0x169a, + /* 0x62 */ + 0xe235, 0x16ae, 0x16af, 0xe304, 0x16e4, 0x16e1, 0x16de, 0x16e6, + 0x16df, 0xe326, 0x16e7, 0x16e2, 0x16e0, 0xe31e, 0x16e5, 0x555a, + 0xe40e, 0x1718, 0xe41d, 0xe41e, 0xe41f, 0x1756, 0xe588, 0x5646, + 0xe58d, 0xe591, 0xe580, 0x176e, 0xe654, 0xe655, 0x179d, 0x17a0, + 0x179c, 0xe725, 0xe71a, 0x17a1, 0x17a2, 0x179f, 0x17df, 0x17de, + 0x57c3, 0x17ea, 0xe988, 0x1806, 0xe97a, 0x1804, 0x580f, 0xe980, + 0xeb1e, 0xebfc, 0xec25, 0x185f, 0x58f4, 0x58fa, 0x185c, 0xec0b, + 0x185e, 0xec06, 0xec04, 0x58dd, 0x1859, 0xebf9, 0xec00, 0x1864, + 0x185d, 0x1862, 0xec02, 0x1865, 0xec07, 0x58ed, 0x185b, 0x58ef, + 0xeeb5, 0x18dd, 0xee87, 0x18df, 0xee93, 0xf70f, 0x18e2, 0xeebe, + 0xf066, 0x1927, 0xf0c7, 0xf0cf, 0x5b96, 0x193a, 0x193c, 0xf13d, + 0x1939, 0xf13c, 0xf147, 0x193d, 0x193b, 0x5bb3, + /* 0x63 */ + 0x194c, 0xf1c3, 0x1968, 0x5be2, 0xf31b, 0x1980, 0x1985, 0xf3c9, + 0x1995, 0xf3dd, 0x1996, 0xf493, 0x5c8f, 0x603d, 0x00a4, 0x0112, + 0x1eb1, 0x0225, 0x6ee6, 0x2141, 0x0337, 0x73f7, 0x77b0, 0x77ae, + 0x5dfd, 0x0468, 0x0467, 0x049e, 0x7c9f, 0x7c9e, 0x7f30, 0x05aa, + 0x7f4f, 0x05a9, 0x05a4, 0x7f27, 0x7f51, 0x0671, 0x066f, 0x8351, + 0x8354, 0x8356, 0x8527, 0x06ad, 0x8524, 0x2bf6, 0x080c, 0x2bf2, + 0x080b, 0x8bec, 0x8bc4, 0x080f, 0x0879, 0x93f8, 0x93f6, 0x93f7, + 0x93ed, 0x098d, 0x098f, 0x93f4, 0x93ef, 0x098e, 0x0a0c, 0x967f, + 0x96a2, 0x967e, 0x0aa6, 0x99c5, 0x0aa3, 0x0aa4, 0x0aa5, 0x3388, + 0x0b6e, 0x9ff1, 0x9ff2, 0x0bfa, 0xa12f, 0x0c7c, 0x0c7e, 0x0c7b, + 0x0c7d, 0xa323, 0xa329, 0x0c8d, 0x0cf4, 0x0cf3, 0xa61b, 0xa7eb, + 0x0d89, 0xa7ea, 0xa933, 0x0dc0, 0xac63, 0x0e65, + /* 0x64 */ + 0xac92, 0xac65, 0x0ead, 0x0f25, 0xb0a0, 0xf670, 0xb15e, 0x0fc9, + 0xb7aa, 0x104a, 0xb7a9, 0x4067, 0x1089, 0xbe9c, 0x1166, 0x1170, + 0xbe92, 0x116d, 0x1169, 0x1167, 0xbe86, 0x1172, 0x430e, 0x116e, + 0xbe83, 0x119c, 0x11fc, 0x11fd, 0x1204, 0x11ff, 0xf6c2, 0x11fe, + 0x1200, 0xc2ce, 0x1266, 0x1269, 0xc593, 0x12aa, 0x12ab, 0x1317, + 0xc92e, 0xc927, 0xc928, 0x1315, 0x485e, 0x1312, 0x4a0e, 0xcc18, + 0xcc16, 0xcd8d, 0x13ca, 0xcd8e, 0x13c9, 0x13cb, 0xcd90, 0xcd8f, + 0xcf81, 0x1429, 0x1428, 0xcf8a, 0xcf8c, 0xd08d, 0x1440, 0x1475, + 0x1476, 0xd1b2, 0x1488, 0xd5d9, 0x4eb6, 0x1557, 0x5101, 0xd90d, + 0x155f, 0xd913, 0x511d, 0x1558, 0x155b, 0xd91b, 0x512f, 0xdbac, + 0x15b3, 0xdbb3, 0x15ef, 0xdf5e, 0x1630, 0xdf60, 0xdf68, 0xdf63, + 0xdf69, 0xdf67, 0x1641, 0x164b, 0xe128, 0x167d, + /* 0x65 */ + 0xe12e, 0xe130, 0x167c, 0xe126, 0xe131, 0xe141, 0x54e0, 0xe1da, + 0x54db, 0xf6fa, 0xe20b, 0x5561, 0xe334, 0xe333, 0x16e8, 0x16ea, + 0x16e9, 0xe339, 0xe33b, 0xe340, 0xe430, 0x171b, 0xe432, 0xe437, + 0x1755, 0x564a, 0x1759, 0x1758, 0xe581, 0xe59f, 0xe5a7, 0x17a4, + 0x17a3, 0xe744, 0xe747, 0xe748, 0xe73d, 0x5733, 0x17a7, 0xe749, + 0x17e0, 0xe880, 0xe9a0, 0xe99d, 0x1808, 0x180a, 0x1809, 0xe99c, + 0xea47, 0xeb07, 0x1871, 0x590f, 0x186c, 0xec49, 0x5911, 0xec44, + 0x5903, 0x5901, 0x186e, 0xecdf, 0x5916, 0xec4c, 0x5dfd, 0xec4f, + 0x18e0, 0x18ee, 0xeec1, 0x18eb, 0xeeb9, 0xeecb, 0xeecf, 0xeec4, + 0x5a93, 0x18ea, 0x18ef, 0x18e7, 0xeeca, 0xeec3, 0xf0d0, 0xf151, + 0x1948, 0x1949, 0xf1a8, 0xf1c7, 0xf1c6, 0x194d, 0xf1ca, 0xf202, + 0x1955, 0xf25d, 0xf25a, 0x196a, 0x196c, 0xf259, + /* 0x66 */ + 0x196b, 0xf2cc, 0xf31c, 0xf3cc, 0x1998, 0x1999, 0x1997, 0xf3e8, + 0xf3ec, 0xf3ea, 0xf4ad, 0xf4b0, 0x605f, 0x6058, 0x6057, 0x1d5b, + 0x6793, 0x0216, 0x6b3b, 0x1ebf, 0x6b34, 0x6ef2, 0x0339, 0x73fd, + 0x751d, 0x0425, 0x23ce, 0x7a04, 0x7b48, 0x7f58, 0x834f, 0x0674, + 0x836e, 0x8372, 0x06ae, 0x852e, 0x8bfc, 0x8bf4, 0x9036, 0x940e, + 0x0992, 0x0994, 0x9414, 0x0995, 0x9419, 0x0a0d, 0x96a6, 0x0a25, + 0x9bc9, 0x9bc0, 0x9bcc, 0x9c1b, 0x9caa, 0x9ca8, 0xa003, 0x0bd5, + 0x0bd6, 0x34ac, 0x0be8, 0xa135, 0x0c7f, 0x35d2, 0x0cf5, 0x0cf6, + 0x0cf7, 0xa4d9, 0x0d24, 0x0d8d, 0x0d8a, 0xa93f, 0xa93d, 0x0e6c, + 0x0e66, 0x0e6a, 0xac8b, 0x0e67, 0x0e6d, 0x0e68, 0x3a52, 0xac68, + 0xac8a, 0xae58, 0xae57, 0xb0ce, 0xb0bc, 0xb0c0, 0xb0c1, 0xb0bf, + 0xb0ab, 0xb15f, 0x0f65, 0xb3a6, 0x0f9a, 0xb429, + /* 0x67 */ + 0x0fb1, 0x104b, 0x104d, 0x104c, 0x104e, 0xb7b8, 0x1173, 0x1175, + 0xbedd, 0xbed6, 0xf6b1, 0xbed5, 0xbee7, 0xbed8, 0xc2ec, 0x1203, + 0xc300, 0xc307, 0xc2fd, 0xc2f1, 0xc2ff, 0xc5aa, 0xc5b0, 0xc948, + 0x131e, 0xc953, 0x4873, 0xc94d, 0x1319, 0x131c, 0x131a, 0x131d, + 0x4876, 0xc943, 0xc950, 0x1343, 0x1352, 0xca8c, 0xcc27, 0x1395, + 0xcd99, 0x13cc, 0xcfb1, 0x142b, 0xcfb0, 0xcfaa, 0xcfac, 0x142a, + 0x4bc7, 0x1477, 0xd1c8, 0xd1ca, 0xd442, 0xd5e0, 0xd6e7, 0xd6e8, + 0xd6e6, 0x1513, 0x1514, 0x5134, 0xd95b, 0xd956, 0x155d, 0xd95a, + 0x1560, 0x513e, 0x1562, 0xdab8, 0xdbc5, 0x15b2, 0x15f0, 0xde48, + 0xdf7d, 0xdf7c, 0xdf81, 0xdf82, 0xdf62, 0x164c, 0xe145, 0x1682, + 0x54bc, 0x1681, 0x169b, 0xe1e3, 0x16a4, 0x16ee, 0x16ec, 0xe350, + 0x16ed, 0xe34f, 0x16f0, 0x16ef, 0xe439, 0x171d, + /* 0x68 */ + 0xe43a, 0x1760, 0x175e, 0x175d, 0xe5c1, 0xe74e, 0xe76e, 0x17b1, + 0x17ab, 0x17ac, 0x17ad, 0xe771, 0x17ae, 0xe88c, 0xe889, 0x17e2, + 0xe8e5, 0xe9b3, 0xe9b6, 0xe9b4, 0xea4d, 0x5839, 0xeb13, 0xec78, + 0x592a, 0x187b, 0x5926, 0x1878, 0x1875, 0x5927, 0xec72, 0x18f2, + 0x18f4, 0x18f3, 0x5ac0, 0x5ac9, 0xf075, 0xf0da, 0xf0d7, 0x193f, + 0x193e, 0x1940, 0x194e, 0x1957, 0x1959, 0x1958, 0xf716, 0xf269, + 0xf267, 0x196e, 0xf266, 0xf26f, 0xf271, 0x5bec, 0xf2cf, 0xf323, + 0x1981, 0x1986, 0xf3a5, 0x198f, 0xf3fe, 0xf3fb, 0xf3fd, 0x5c68, + 0x199b, 0x19b1, 0x19b3, 0x6b6d, 0x033a, 0x7405, 0x7520, 0x0427, + 0x77c8, 0x77c9, 0x046a, 0x05ac, 0x8627, 0x0818, 0x8c1e, 0x8d36, + 0x084c, 0x943d, 0x0996, 0x99d7, 0x0b4a, 0x9cad, 0x9e00, 0x0c81, + 0xa33a, 0x0c83, 0x0cf9, 0x0cf8, 0xa626, 0x0d8e, + /* 0x69 */ + 0x0d8f, 0x0dc1, 0xacb7, 0xacb6, 0xacc0, 0x0e70, 0xac9b, 0x0e71, + 0xb0d8, 0x0f2a, 0x0f2d, 0x0f7d, 0x3e32, 0x3e31, 0xb7c0, 0x104f, + 0xb7bf, 0xb9bf, 0x1090, 0xbf20, 0xbed0, 0xbf0e, 0x1179, 0xbf1d, + 0xbf1e, 0xbf15, 0xbf14, 0xc31e, 0xc32c, 0x1205, 0xc5b9, 0xc5b8, + 0xc5b6, 0xc69e, 0xc69c, 0xc74d, 0x46fd, 0xc96e, 0xc960, 0x1321, + 0xc964, 0xc962, 0xb0e5, 0x1332, 0xcda3, 0x13cd, 0x13cf, 0xd1d2, + 0xd1d5, 0x4d8e, 0x1516, 0x1515, 0x15b5, 0x1608, 0xde55, 0x1632, + 0xdf93, 0x1633, 0x1634, 0x163c, 0xe156, 0x54c2, 0xe1e9, 0x169c, + 0xe245, 0x16f4, 0x16f2, 0xe47c, 0x1762, 0xe5d3, 0x1761, 0x1764, + 0x17b5, 0x574b, 0x17b4, 0xe78e, 0xe897, 0x17e3, 0xe89b, 0xe899, + 0x581c, 0x180e, 0xe9cf, 0x581b, 0xea59, 0x182c, 0x182b, 0xeb20, + 0xeb23, 0xeb2a, 0x1885, 0x1881, 0x187e, 0x1883, + /* 0x6a */ + 0x1880, 0xecb0, 0x5942, 0xef2f, 0x5ad4, 0x18fb, 0x18f7, 0xef32, + 0xef43, 0xef3f, 0xef39, 0x18f8, 0xef30, 0xf0dd, 0xf1da, 0xf1db, + 0x195a, 0xf284, 0xf27f, 0xf272, 0xf280, 0xf2ee, 0x1978, 0xf32a, + 0xf322, 0xf371, 0xf3cd, 0x199d, 0x199c, 0xf40f, 0xf418, 0x606a, + 0x00a9, 0x00bf, 0x1ed0, 0x1ecf, 0x740c, 0x23da, 0x7ca6, 0x0677, + 0x0676, 0x8537, 0x06bb, 0x29ea, 0x8ee2, 0x099b, 0x96bc, 0x0a0f, + 0x0a5b, 0x9bd5, 0x0b4c, 0x0b6f, 0x0bd9, 0xa012, 0x0c82, 0xa34b, + 0xa341, 0xa3a1, 0xa4ec, 0x0e74, 0x0e72, 0xacd4, 0xacd8, 0xacd9, + 0x0e73, 0xacda, 0xae6c, 0xae6d, 0x0eb1, 0x0f2e, 0xb0e7, 0xb0eb, + 0xb0ec, 0xb162, 0x0f4e, 0xb42b, 0xb50d, 0xb7cd, 0xb9c3, 0xbf3f, + 0xbf3c, 0xbf3e, 0xbf3d, 0xbf3a, 0xbf38, 0xc344, 0xc345, 0x120b, + 0xc348, 0xc350, 0x126c, 0x4889, 0xc978, 0xc979, + /* 0x6b */ + 0x138b, 0xcc3e, 0x13d0, 0x142d, 0xd454, 0x14e4, 0x1571, 0xd9b9, + 0x5158, 0x156f, 0xde5f, 0x1687, 0x16a5, 0xe372, 0xe375, 0x171e, + 0x1765, 0x17b9, 0x17b7, 0x17b8, 0x17e4, 0xe8a3, 0xe8a5, 0xe9dc, + 0xe9dd, 0xea5a, 0x188c, 0x1889, 0x188a, 0xecdb, 0xecdc, 0x188b, + 0xefab, 0xef84, 0xef76, 0x1901, 0x18fe, 0x5ae7, 0x1903, 0x1906, + 0xef83, 0x5aea, 0x5af1, 0xf07f, 0x191d, 0x1943, 0xf173, 0xf1ad, + 0xf1b0, 0x194f, 0xf20f, 0xf20c, 0x195b, 0x1970, 0xf379, 0x1988, + 0xf377, 0xf37a, 0x1989, 0x5c44, 0xf432, 0xf427, 0xf42a, 0xf42c, + 0x5c6d, 0xf428, 0xf429, 0xf438, 0x642f, 0x6b7b, 0x740d, 0x23d9, + 0x77d6, 0x77d5, 0x83a1, 0x8c4c, 0x099e, 0x099f, 0x0aa7, 0x0b4b, + 0x0bdb, 0x0bda, 0xa0c0, 0x35d6, 0x0c8e, 0x0e76, 0xacf4, 0x0f30, + 0x0f2f, 0xb0f0, 0x0f66, 0xb23f, 0x117e, 0xc35d, + /* 0x6c */ + 0xc372, 0xc362, 0x453a, 0xc366, 0x4675, 0x126f, 0xc988, 0x13d1, + 0x142f, 0xcfe8, 0xcfe4, 0x14b2, 0x1518, 0x1517, 0xd6ff, 0x1576, + 0xdfaf, 0xdfae, 0x164f, 0x1689, 0xe1f2, 0xe248, 0xe381, 0xe37e, + 0x16f5, 0x171f, 0xe452, 0xe5ef, 0x575d, 0x17e5, 0xe8ad, 0xe9e6, + 0x1810, 0xe9ed, 0x180f, 0xe9e9, 0xea61, 0xea60, 0xeb33, 0x182f, + 0x1830, 0x5964, 0xed0b, 0xed08, 0x1893, 0x1894, 0xed07, 0x1907, + 0x1909, 0x1908, 0xefca, 0x190b, 0xefc6, 0x5b0a, 0xf084, 0xf0eb, + 0xf17d, 0x1950, 0x1971, 0xf29b, 0xf2a2, 0xf2a1, 0xf2a0, 0xf29c, + 0x197b, 0x197c, 0xf380, 0x5c73, 0xf440, 0x19a1, 0xf439, 0xf43c, + 0x19a0, 0x19a2, 0x64ca, 0x021b, 0x6b89, 0x0282, 0x853c, 0x8d40, + 0x9463, 0x9469, 0x0be9, 0xa353, 0x0c84, 0x35e1, 0xa817, 0xa81a, + 0xad00, 0x0eb3, 0x0f34, 0x0f33, 0x1180, 0xc36f, + /* 0x6d */ + 0xc6ab, 0x12ad, 0xc991, 0x1344, 0x1355, 0xcdb1, 0x13d2, 0xcfef, + 0xdbf1, 0xdbf2, 0xdfb7, 0xdfb5, 0x168a, 0xe386, 0xe45a, 0x1767, + 0xe7c6, 0xe7cb, 0x17e6, 0xe8b2, 0x1813, 0xe9f3, 0x582d, 0xed27, + 0x1897, 0x5b0c, 0xefd5, 0xefd8, 0x190c, 0xefec, 0xf087, 0xf0f2, + 0x1946, 0x195c, 0x1974, 0x1972, 0xf2ad, 0xf2b0, 0xf2fd, 0x5c1f, + 0xf387, 0xf44a, 0x19a4, 0x19a3, 0xf44e, 0xf449, 0xf451, 0xf44d, + 0x19b4, 0x6072, 0x0136, 0x7416, 0x8c6d, 0x8d41, 0x08b2, 0x9471, + 0x9474, 0x0b16, 0x3a70, 0x0e77, 0xae7c, 0x117f, 0xbf8a, 0xc756, + 0x147d, 0x5179, 0xd9fa, 0x544a, 0x168c, 0xe45b, 0x1768, 0x17be, + 0x1815, 0xeff5, 0xeff0, 0xf0f3, 0xf17f, 0xf213, 0x1975, 0x19a5, + 0x7419, 0x7f85, 0x83b0, 0x9477, 0xa4ff, 0x0e78, 0x0f35, 0x3c9d, + 0x1182, 0xbf87, 0x1183, 0xbf8b, 0x1271, 0xc99e, + /* 0x6e */ + 0x147e, 0x168e, 0xe38f, 0x5660, 0x1769, 0xe639, 0xe7d4, 0xe8f1, + 0xea02, 0xea6b, 0xeb40, 0x189a, 0x189b, 0xf010, 0xf2be, 0xf2b9, + 0x1990, 0xf464, 0x5c9e, 0x9be9, 0xbf90, 0x1186, 0x1185, 0xc01c, + 0x120e, 0xc392, 0xc6ae, 0xc9a3, 0x1519, 0xdfc9, 0x17c0, 0xe7d8, + 0xeb44, 0xf024, 0x5bf8, 0x5c3a, 0x5c7d, 0xf470, 0xf4d3, 0x0c0d, + 0x1816, 0xf2c3, 0x19a9, 0x19aa, 0x0c85, 0xad21, 0xb9ca, 0xc39c, + 0xea73, 0xf186, 0xf3c1, 0xea09, 0x5c96, 0xf4d5, 0x17c2, 0x1831, + 0x1911, 0x19ab, 0x189c, 0xdfd4, +}; + +static const ucs4_t cns11643_4b_2uni_upages[248] = { + 0x03400, 0x03500, 0x03600, 0x03700, 0x03800, 0x03900, 0x03a00, 0x03b00, + 0x03c00, 0x03d00, 0x03e00, 0x03f00, 0x04000, 0x04100, 0x04200, 0x04300, + 0x04400, 0x04500, 0x04600, 0x04700, 0x04800, 0x04900, 0x04a00, 0x04b00, + 0x04c00, 0x04d00, 0x05000, 0x05100, 0x05200, 0x05300, 0x05600, 0x05800, + 0x05900, 0x05b00, 0x05c00, 0x05d00, 0x05e00, 0x05f00, 0x06100, 0x06400, + 0x06500, 0x06600, 0x06900, 0x06a00, 0x06b00, 0x06f00, 0x07000, 0x07100, + 0x07200, 0x07300, 0x07400, 0x07500, 0x07600, 0x07700, 0x07800, 0x07900, + 0x07a00, 0x07b00, 0x07c00, 0x07d00, 0x07e00, 0x07f00, 0x08000, 0x08100, + 0x08200, 0x08400, 0x08500, 0x08600, 0x08700, 0x08800, 0x08900, 0x08a00, + 0x08b00, 0x08c00, 0x08d00, 0x08e00, 0x08f00, 0x09000, 0x09100, 0x09200, + 0x09300, 0x09400, 0x09500, 0x09600, 0x09700, 0x09800, 0x09900, 0x09a00, + 0x09b00, 0x09c00, 0x09d00, 0x09e00, 0x09f00, 0x0ff00, 0x20000, 0x20300, + 0x20400, 0x20500, 0x20600, 0x20700, 0x20800, 0x20900, 0x20a00, 0x20b00, + 0x20e00, 0x20f00, 0x21000, 0x21100, 0x21200, 0x21300, 0x21400, 0x21500, + 0x21600, 0x21800, 0x21900, 0x21a00, 0x21b00, 0x21c00, 0x21e00, 0x21f00, + 0x22100, 0x22200, 0x22300, 0x22400, 0x22500, 0x22700, 0x22800, 0x22900, + 0x22a00, 0x22c00, 0x22d00, 0x22e00, 0x22f00, 0x23000, 0x23100, 0x23200, + 0x23300, 0x23500, 0x23600, 0x23700, 0x23800, 0x23900, 0x23a00, 0x23b00, + 0x23c00, 0x23e00, 0x23f00, 0x24000, 0x24100, 0x24300, 0x24400, 0x24500, + 0x24600, 0x24800, 0x24900, 0x24a00, 0x24b00, 0x24c00, 0x24d00, 0x24e00, + 0x24f00, 0x25000, 0x25200, 0x25300, 0x25500, 0x25600, 0x25700, 0x25800, + 0x25900, 0x25a00, 0x25b00, 0x25c00, 0x25d00, 0x25e00, 0x25f00, 0x26000, + 0x26100, 0x26200, 0x26300, 0x26400, 0x26500, 0x26600, 0x26700, 0x26800, + 0x26900, 0x26a00, 0x26c00, 0x26d00, 0x26e00, 0x26f00, 0x27000, 0x27100, + 0x27200, 0x27300, 0x27400, 0x27500, 0x27600, 0x27700, 0x27800, 0x27900, + 0x27a00, 0x27b00, 0x27c00, 0x27d00, 0x27e00, 0x27f00, 0x28000, 0x28100, + 0x28200, 0x28300, 0x28400, 0x28500, 0x28600, 0x28700, 0x28800, 0x28900, + 0x28a00, 0x28b00, 0x28c00, 0x28d00, 0x28e00, 0x28f00, 0x29000, 0x29100, + 0x29200, 0x29300, 0x29400, 0x29500, 0x29600, 0x29700, 0x29800, 0x29900, + 0x29a00, 0x29b00, 0x29c00, 0x29d00, 0x29e00, 0x29f00, 0x2a000, 0x2a100, + 0x2a200, 0x2a300, 0x2a400, 0x2a500, 0x2a600, 0x2f800, 0x2f900, 0x2fa00, +}; + diff --git a/graf2d/win32gdk/gdk/src/iconv/cns11643_5.h b/graf2d/win32gdk/gdk/src/iconv/cns11643_5.h new file mode 100644 index 0000000000000..f0e5ebea91544 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cns11643_5.h @@ -0,0 +1,1278 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CNS 11643-1992 plane 5 + */ + +static const unsigned short cns11643_5_2uni_page21[8603] = { + /* 0x21 */ + 0x3bd1, 0x3bcb, 0x3bc9, 0x3c0c, 0x3b00, 0x3b87, 0x3c0d, 0x3c0f, + 0xe21d, 0x5e98, 0x3bd2, 0x3c11, 0x3b7e, 0x45d3, 0x5052, 0x57fe, + 0x60a9, 0x7442, 0x3b09, 0x3bd6, 0x3fdd, 0x3fdc, 0x4002, 0x4073, + 0x4176, 0x41a7, 0x41a8, 0x4333, 0x43cc, 0x450d, 0x452c, 0x461b, + 0x015a, 0x461d, 0x4699, 0x4d3e, 0x582d, 0x582f, 0x5e99, 0x6eb3, + 0x74b6, 0x761b, 0x7fef, 0x83e9, 0x3b14, 0x3b94, 0x3be1, 0x4006, + 0x404a, 0x4044, 0x4131, 0x417a, 0x41ad, 0x41ae, 0x41b1, 0x4338, + 0x4337, 0x447d, 0x447e, 0x452d, 0x4532, 0x4623, 0x4626, 0xe23a, + 0x46a0, 0x51a8, 0x543f, 0x54bc, 0x56c4, 0x583b, 0x5b19, 0x5b18, + 0x5cb3, 0x5eaa, 0x5fbe, 0x60ac, 0x6525, 0x6566, 0x656b, 0x7443, + 0x74b5, 0x75ec, 0x7776, 0x08bc, 0x8114, 0x50dc, 0x821c, 0x821d, + 0x9fd0, 0xa112, 0xa5f3, 0xc169, 0x15b9, 0xc911, + /* 0x22 */ + 0xc915, 0xc910, 0xc913, 0x3ba4, 0x3ba5, 0x3cd0, 0x3cba, 0x3ccb, + 0x407b, 0x4186, 0x41bb, 0x41ba, 0x41c3, 0x41b9, 0x41c0, 0x00de, + 0x4339, 0x433b, 0x4341, 0x43d1, 0x43cf, 0x43d2, 0x442e, 0x446e, + 0x448c, 0x4488, 0x4535, 0x0143, 0x453a, 0x453b, 0x4538, 0x4539, + 0x462e, 0x462c, 0x46c8, 0x46b5, 0x46ad, 0x46b0, 0x46ab, 0x4cb3, + 0x4ca9, 0x51bb, 0x51b9, 0x565a, 0x56cd, 0x572b, 0x5805, 0x03ac, + 0x03aa, 0x5851, 0x584b, 0x5aea, 0x5aed, 0x5b36, 0x5b62, 0x5b56, + 0x5b55, 0x5b64, 0x5b58, 0x1c07, 0x5cda, 0x5cd8, 0x5ead, 0x5eab, + 0x5fc0, 0x5fc3, 0x60b3, 0x60b7, 0x60ba, 0x1dcb, 0x04fe, 0x60c7, + 0x60b5, 0x648e, 0x6573, 0x656c, 0x6574, 0xe2b4, 0x6572, 0x6571, + 0x6582, 0x6570, 0x6c3f, 0x6eba, 0x6eb8, 0x74b7, 0x8223, 0x8221, + 0x822b, 0x8226, 0x8222, 0x8825, 0x8be4, 0x8f15, + /* 0x23 */ + 0x9fe4, 0xa133, 0xa12a, 0xa132, 0xa129, 0xa5fb, 0xb45b, 0xb45c, + 0xb728, 0xc16f, 0xc16d, 0xc16b, 0xc16e, 0xc916, 0x3b22, 0x3c16, + 0x3c48, 0x3cd8, 0x3d00, 0x0041, 0x3f80, 0x3fe4, 0x00b4, 0x3fe7, + 0x400c, 0x4053, 0x40b7, 0x45e8, 0x41d1, 0x41e5, 0x41d8, 0x41d6, + 0x41da, 0x41d9, 0x41d5, 0x41e6, 0x41d4, 0x41d3, 0x4344, 0x43d6, + 0x43d7, 0x4413, 0x3afd, 0x4470, 0x4492, 0x44db, 0x44da, 0x4541, + 0x4543, 0x4633, 0x46f6, 0x46d4, 0x46dd, 0x46d0, 0x4704, 0x46d9, + 0x46db, 0x4705, 0x46d3, 0x46e1, 0x4d80, 0x4d77, 0x4d81, 0x4d82, + 0x4d83, 0xe25c, 0x5061, 0x5060, 0x51d8, 0x51d6, 0x51d7, 0x8105, + 0x544d, 0x5448, 0x56d6, 0x56cf, 0x56d9, 0x56d8, 0x573d, 0x03b3, + 0x5854, 0x585b, 0x585c, 0x03b4, 0x5859, 0x5858, 0x585a, 0x5855, + 0x5856, 0x5882, 0x5af0, 0x5b1c, 0x5b6a, 0x5b69, + /* 0x24 */ + 0x5b71, 0x5b67, 0x5b6c, 0x5b6e, 0x5b79, 0x5c8b, 0x5cb8, 0x5ce7, + 0x5ce8, 0x5ce4, 0x5ce6, 0x5ce5, 0x5cf0, 0x5e83, 0x5eb7, 0x5ebb, + 0x5eb9, 0x5ec5, 0x5f53, 0x5fc4, 0x5fc6, 0x5fcb, 0x60c8, 0xe29f, + 0x60c9, 0x60db, 0x6494, 0x6595, 0x6588, 0x658d, 0x69ec, 0x69ee, + 0x69f1, 0x6c2e, 0x6c49, 0x6e5f, 0x6ed1, 0x6ecb, 0x7385, 0x081d, + 0x744a, 0x7447, 0x744b, 0x74bb, 0x74c4, 0x087c, 0x7602, 0x7782, + 0x7791, 0x778f, 0x7792, 0x7c8f, 0x7c91, 0x7cb4, 0x7c92, 0x7ff4, + 0x80aa, 0x8235, 0x8237, 0x823d, 0x823c, 0x822f, 0x8230, 0x83f8, + 0x83ef, 0x8626, 0x0b55, 0x8826, 0x8827, 0x8a41, 0x8ac6, 0x8ac7, + 0x8beb, 0x8be8, 0x8bea, 0x8f1a, 0x8f19, 0x0d26, 0x9423, 0x9424, + 0x9925, 0xa135, 0xa134, 0xa507, 0xad1d, 0xb2e1, 0xb6ab, 0xbf60, + 0xc177, 0xc17d, 0x15bc, 0xc91e, 0xc91a, 0xc91d, + /* 0x25 */ + 0x3b6b, 0x3c2d, 0x3c4c, 0x3d2a, 0x004a, 0x3d15, 0x3d2c, 0x3d06, + 0x3d08, 0x3d0a, 0x004e, 0x4056, 0x4084, 0x00c9, 0x40c6, 0x41f5, + 0x4209, 0x41f8, 0x41e8, 0x41fb, 0x41e9, 0x41f6, 0x1ab7, 0x1ab8, + 0x4352, 0x1ab6, 0x1aba, 0x4354, 0x4351, 0x4439, 0x443a, 0x4498, + 0x454e, 0x017b, 0x4736, 0x470c, 0x4710, 0x4732, 0x4711, 0x4718, + 0x471c, 0x471a, 0x4719, 0x470b, 0x470f, 0x471d, 0x4721, 0x4713, + 0x471b, 0x4715, 0x0220, 0x4cd1, 0x4cc8, 0x4d8d, 0x4db5, 0x0289, + 0x0295, 0x50f8, 0x51e0, 0x51e1, 0x02be, 0x51de, 0x51fe, 0x51dc, + 0x5201, 0x51fd, 0x5200, 0x54d7, 0x54d6, 0x54d9, 0x5665, 0x56d2, + 0x56dc, 0x56e1, 0x56de, 0x5742, 0x574b, 0x03c3, 0x588e, 0x5891, + 0x588b, 0x5890, 0x5888, 0x5889, 0x5884, 0x58aa, 0x5b8d, 0x5b8f, + 0x5b7d, 0x5b7f, 0x5b7b, 0x5b80, 0x5b7e, 0x5b83, + /* 0x26 */ + 0x5b81, 0x5b86, 0x5b8a, 0x5cbd, 0x5cbe, 0x0477, 0x5cf4, 0x5cf3, + 0x5d02, 0x5cf6, 0x5cf5, 0x5cf2, 0x5d04, 0x5e3d, 0x5ec6, 0x5f89, + 0x5fd4, 0x5fd6, 0x5fd2, 0x60fa, 0x6106, 0x610c, 0x610a, 0x610f, + 0x652f, 0x05d4, 0x65b7, 0x65be, 0x65bc, 0x65e2, 0x6a06, 0x69f7, + 0x6a07, 0x69f6, 0x7635, 0x6c5f, 0x6c65, 0x6c64, 0x6c61, 0x6c5a, + 0x6c5d, 0xe2d7, 0x6ed7, 0x6ed5, 0x6ede, 0x6ee1, 0x6ee0, 0x6ed9, + 0x074c, 0x6eda, 0x6edf, 0x6ef6, 0x6f03, 0x0820, 0x7393, 0x738b, + 0x7391, 0x7392, 0x738a, 0x7389, 0x738f, 0x7456, 0x7459, 0x74ca, + 0x74cc, 0x085b, 0x74d0, 0x74cd, 0x74d6, 0x74cb, 0x7583, 0x7582, + 0x7606, 0x762a, 0x762c, 0x762b, 0x7629, 0x77bd, 0x77b3, 0x77be, + 0x77c0, 0x77b5, 0x77b6, 0x7c9d, 0x7c9f, 0x8120, 0x0a2d, 0x811e, + 0x811c, 0x8132, 0x811f, 0x812b, 0x8121, 0x8126, + /* 0x27 */ + 0x8124, 0x811d, 0x8127, 0x825b, 0x8259, 0x8280, 0x8255, 0x8250, + 0x825a, 0x8256, 0x8263, 0x8252, 0x8258, 0x0a63, 0x8239, 0x83f9, + 0x8628, 0x0b18, 0x86bc, 0x86d6, 0x8705, 0x8720, 0x0b74, 0x8833, + 0x8a46, 0x8a42, 0x8a43, 0x8a47, 0x8acb, 0x8b42, 0x8b45, 0x8bfd, + 0x8bf4, 0x8bf9, 0x8bfa, 0x8e5e, 0x8f1d, 0x0d28, 0x9258, 0x9255, + 0x9557, 0x9558, 0x95d9, 0x95dc, 0x95db, 0x9927, 0x9a85, 0x9a87, + 0x9a8a, 0x9d8b, 0x9e4f, 0xa030, 0xa02f, 0xa168, 0xa149, 0x0fda, + 0xa148, 0xa13f, 0xa14b, 0xa15c, 0xa146, 0xa140, 0xa50d, 0xa61b, + 0xa61d, 0xa617, 0x10a4, 0xa622, 0xb0a7, 0xb108, 0xb306, 0xbf7d, + 0x148e, 0xbf63, 0xbf64, 0xbf7f, 0xbf6b, 0xbf7c, 0xbf68, 0xbf65, + 0xbf6a, 0xc198, 0xc199, 0xc1ae, 0xc92b, 0xc92d, 0xc931, 0xc92e, + 0xc92f, 0x3b6d, 0x3c31, 0x3d2d, 0x3d39, 0x3d38, + /* 0x28 */ + 0x005b, 0x3d3a, 0x3d35, 0x3d62, 0x3fea, 0x3feb, 0x4015, 0x40cc, + 0x40c8, 0x40cd, 0x40db, 0x40cb, 0x4211, 0x4226, 0x4362, 0x435e, + 0x4361, 0x4441, 0x443f, 0x4475, 0x7465, 0x4649, 0x44eb, 0x451a, + 0x4557, 0x476b, 0x47a9, 0x4754, 0x4762, 0x47aa, 0x4758, 0x4772, + 0x4763, 0x4773, 0x478b, 0x478c, 0x475c, 0x4751, 0x4716, 0x4760, + 0x4761, 0x475e, 0x475d, 0x4764, 0x4753, 0x475f, 0x475b, 0x476e, + 0x4755, 0x4752, 0x4768, 0x4cd2, 0x4cd6, 0x4cd3, 0x4db8, 0x4dbb, + 0x4deb, 0x4de8, 0x4db6, 0x4dea, 0x4de7, 0x4de9, 0x5091, 0x5110, + 0x510e, 0x510f, 0x520b, 0x5203, 0x522b, 0x5209, 0x5228, 0x522c, + 0x5225, 0x5227, 0x520f, 0x54e9, 0x54ec, 0x0353, 0x5627, 0x5673, + 0x56e2, 0x56e6, 0xe276, 0x5761, 0x5751, 0x5812, 0x580e, 0x58ad, + 0x58af, 0x58b1, 0x58d3, 0x5b94, 0x5b92, 0x5b90, + /* 0x29 */ + 0x5b9d, 0x5b93, 0x5b95, 0x5b98, 0x5b97, 0x0480, 0xe28a, 0x5d07, + 0x5d0b, 0x5d08, 0x5ed9, 0x5ed5, 0x5fd7, 0x5fdf, 0x04dd, 0x5fde, + 0x5fe3, 0x5fe2, 0x04de, 0x6147, 0x0522, 0x613d, 0x6138, 0x6544, + 0x653a, 0x65b8, 0x662a, 0x6600, 0x65f3, 0x65f2, 0x65eb, 0x65fa, + 0x65ed, 0x65ec, 0x65ff, 0x65fb, 0x1f06, 0x664e, 0x65ef, 0x65f7, + 0x6a10, 0x6a11, 0x6a0c, 0x6a0b, 0x6bdd, 0x6c30, 0x06db, 0x6c7a, + 0x6c77, 0x6e28, 0x6e27, 0x6e65, 0x6f0e, 0x6f0b, 0x6f41, 0x6f13, + 0x6f0f, 0x6f12, 0x6f30, 0x73a0, 0x73a3, 0x739e, 0x7397, 0x73a1, + 0x739d, 0x739b, 0x7463, 0x74e3, 0x74e4, 0x74e6, 0x74e7, 0x74dd, + 0x2185, 0x74ec, 0x74e5, 0x74f1, 0x763b, 0x7639, 0x763a, 0x763c, + 0x763d, 0x7647, 0x763f, 0x7644, 0x7748, 0x7749, 0x7760, 0x77e3, + 0x77e9, 0x77f0, 0x08da, 0x08db, 0x77f2, 0x77ed, + /* 0x2a */ + 0x77ec, 0x77e6, 0x7816, 0x08d7, 0x7cbc, 0x7cbe, 0x7cc0, 0x7ce0, + 0x8000, 0x8002, 0x7ffe, 0x805e, 0x80b3, 0x80b7, 0x813a, 0x8139, + 0x813e, 0x8138, 0x813d, 0x814f, 0x826e, 0x825f, 0x8281, 0x8282, + 0x8271, 0x827b, 0x8279, 0x8277, 0x8273, 0x826f, 0x8297, 0x827e, + 0x83fc, 0x8411, 0x8432, 0x8431, 0x8410, 0x85ec, 0x85eb, 0x862c, + 0x862d, 0x86da, 0x872e, 0x872c, 0x872a, 0x8733, 0x874b, 0x8818, + 0x8842, 0x883b, 0x883f, 0x8841, 0x8843, 0x883c, 0x8a4c, 0x8a4a, + 0x8a49, 0x8a56, 0x8acf, 0x8b47, 0x8b48, 0x8b46, 0x8c1b, 0x8c11, + 0x8c14, 0x8c1d, 0x8c17, 0x8c1e, 0x8c0b, 0x8c1c, 0x8c12, 0x8c16, + 0x8c0d, 0x8c15, 0x8c13, 0x8c18, 0x0c1a, 0x8eac, 0x8f44, 0x8f2c, + 0x8f45, 0x9266, 0x926e, 0x9265, 0x9268, 0x9284, 0x9438, 0x943b, + 0x943a, 0x943f, 0x95df, 0x95dd, 0x95de, 0x95e2, + /* 0x2b */ + 0x0dd6, 0x992c, 0x992f, 0x9a8f, 0x9a90, 0x9a8c, 0x9a93, 0x9d25, + 0x9d88, 0x9da7, 0x9ef7, 0x9fbb, 0xa038, 0xa039, 0xa037, 0xa114, + 0xa16e, 0xa17b, 0x0fde, 0xa16c, 0xa17f, 0xa178, 0xa17a, 0xa16f, + 0x0fe5, 0xa3fe, 0xa648, 0xa64b, 0xa641, 0xa649, 0xa63b, 0xad2d, + 0xb0e3, 0xb11a, 0xb10d, 0xb113, 0xb111, 0xb11c, 0x1272, 0xb3b5, + 0x12af, 0xb729, 0xb7a1, 0xb824, 0xbabb, 0xbda1, 0xbf83, 0xbf8d, + 0xbf87, 0xbf85, 0xbf8a, 0xbfa3, 0xbf89, 0xbf84, 0xbfa2, 0xc1b1, + 0xc1b0, 0xc1af, 0xc1b6, 0xc1c9, 0xc1ca, 0xc1c8, 0xc1b4, 0xc759, + 0xc7c9, 0xc941, 0xc94c, 0x15c4, 0xc945, 0xc95a, 0x3bb9, 0x3d94, + 0x3d6e, 0x3da2, 0x3d67, 0x0063, 0x3da3, 0x3d76, 0x3d6c, 0x3d64, + 0x3da5, 0x3d30, 0x3da6, 0x3d69, 0x3da4, 0x3f90, 0x405f, 0x4060, + 0x40da, 0x40d8, 0x40dd, 0x00ec, 0x4259, 0x425b, + /* 0x2c */ + 0x425a, 0x4239, 0x4234, 0x4244, 0x4233, 0x423c, 0x4258, 0x426a, + 0x436f, 0x4372, 0x4370, 0x4371, 0x436e, 0x43f0, 0x43eb, 0x4449, + 0x444c, 0x44f5, 0x4520, 0x456a, 0x4572, 0x464b, 0x465d, 0x4750, + 0x47f9, 0x47fa, 0x47fb, 0x4823, 0x47b7, 0x4822, 0x47b5, 0x47c4, + 0x47b4, 0x47ef, 0x0198, 0x47cd, 0x47f0, 0x47b8, 0x47cb, 0x47f1, + 0x47ba, 0x4803, 0x47f8, 0x47b6, 0x47bc, 0x47b3, 0x4821, 0x47f7, + 0x47c2, 0x47be, 0x47c9, 0x47bd, 0x47ce, 0x47b9, 0x47c7, 0x47ca, + 0x47cc, 0x4826, 0x4ce4, 0x4ce0, 0x4cf0, 0x4dec, 0x4e24, 0x4e18, + 0x4e2f, 0x4e25, 0x5028, 0x5022, 0x506a, 0x3c57, 0x5094, 0x5092, + 0x509c, 0x5122, 0x5130, 0x511d, 0x5123, 0x5235, 0x5233, 0x522f, + 0x524d, 0x5231, 0x525b, 0x525a, 0x5232, 0x525c, 0x5259, 0x525d, + 0x5469, 0x546d, 0x5d32, 0x0358, 0x550a, 0x5520, + /* 0x2d */ + 0x551f, 0x550d, 0x56e8, 0x56ec, 0x5777, 0x5770, 0x5771, 0x58f8, + 0x58d6, 0x58d9, 0x58de, 0x58d5, 0x58e1, 0x03d3, 0x58e2, 0x58dd, + 0x58e0, 0x590e, 0x5908, 0x58dc, 0x590a, 0x590c, 0x5bb4, 0x5bb1, + 0x5bb6, 0x5bbc, 0x5d1d, 0x5d24, 0x5d19, 0x5d1b, 0x5d22, 0x5d1a, + 0x5d1c, 0x5d21, 0x5ee6, 0x5ee4, 0x5ee7, 0x5eea, 0x04e2, 0xe29b, + 0x5ff0, 0x5ff5, 0x5fef, 0x6142, 0x616e, 0x613c, 0x6197, 0x618c, + 0x6181, 0x6171, 0x61ce, 0x61ba, 0x617a, 0x617e, 0x0554, 0x6172, + 0x61bb, 0x052f, 0x6173, 0x6182, 0x05b6, 0x64ba, 0x64b8, 0x654b, + 0x6548, 0x662b, 0x65f4, 0x662c, 0x6642, 0x6648, 0x6644, 0x6645, + 0x663c, 0x6637, 0x6633, 0x6641, 0x6632, 0x6687, 0x6a27, 0x6a23, + 0x6a2d, 0x6a1f, 0x6a2c, 0x6a28, 0x6b75, 0x6b74, 0x6be7, 0x6c32, + 0x6c31, 0x6c99, 0x6c96, 0x6c98, 0x6c9d, 0x6c92, + /* 0x2e */ + 0x6c94, 0x6c95, 0x6c97, 0xa1b9, 0x0735, 0x6f11, 0x6f3b, 0x6f79, + 0x6f42, 0x6f43, 0x075d, 0x6f78, 0x73ac, 0x0829, 0x73b1, 0x73b4, + 0x73b3, 0x73af, 0x73aa, 0x73b2, 0x7468, 0x74f2, 0x74fe, 0x74f8, + 0x74f9, 0x74ff, 0x74f5, 0x74f7, 0x74fd, 0x7500, 0x7588, 0x766e, + 0x765d, 0x7663, 0x7660, 0x7761, 0x7837, 0x7871, 0x7823, 0x7822, + 0x781f, 0x7825, 0x7cfd, 0x7d11, 0x7d23, 0x7cf0, 0x7cef, 0x800e, + 0x800c, 0x80ba, 0x0a1f, 0x8152, 0x8155, 0x8153, 0x8154, 0x8151, + 0x8158, 0x82b0, 0x829f, 0x0a72, 0x82a1, 0x829a, 0x82be, 0x82a0, + 0x8437, 0x0b0b, 0x85f1, 0x85f2, 0x8634, 0x8637, 0x8635, 0x5e8c, + 0x86df, 0x874c, 0x874e, 0x8764, 0x8763, 0x8736, 0x8858, 0x8868, + 0x885b, 0x885f, 0x8859, 0x8865, 0x8860, 0x885e, 0x8ad5, 0x8ad6, + 0x8b4e, 0x8b52, 0x8c35, 0x8c39, 0x8c58, 0x8c41, + /* 0x2f */ + 0x8c57, 0x8c38, 0x8c3d, 0x8c32, 0x8c44, 0xe344, 0x8e63, 0x8e62, + 0x8eb8, 0x8eb0, 0x8eb1, 0x8f4d, 0x8f63, 0x8f70, 0x8f4b, 0x8f4f, + 0x8f4e, 0x8f53, 0x8f47, 0x0ca2, 0x8f54, 0x8f52, 0x8f59, 0x8f7e, + 0x912b, 0x912e, 0x927f, 0x927e, 0x9281, 0x9283, 0x9447, 0x9454, + 0x944d, 0x944c, 0x944b, 0x9457, 0x9565, 0x9564, 0x9561, 0x9562, + 0x95f0, 0x95f3, 0x95f9, 0x95f4, 0x95f5, 0x95ef, 0x95f8, 0x95fc, + 0x95f7, 0x95fd, 0x9617, 0x9934, 0x9936, 0x9938, 0x9aaf, 0x9aae, + 0x9aac, 0x9aa2, 0x9d28, 0x69c2, 0x9d9c, 0x9db3, 0x9d90, 0x9f06, + 0x9f04, 0x9f0b, 0x9f05, 0xa040, 0xa04f, 0xa1ab, 0xa19d, 0xa1b8, + 0xa1b2, 0xa1d2, 0xa1cf, 0xa1a2, 0x0fec, 0xa1a5, 0xa1a9, 0xa1a7, + 0xa1d0, 0xa402, 0xa4cf, 0xa4d0, 0xa516, 0xa519, 0xa675, 0xa671, + 0xa691, 0xa672, 0xa68e, 0xa66d, 0xa688, 0xa673, + /* 0x30 */ + 0x10bb, 0xa681, 0xa676, 0xa67b, 0xa67f, 0xa690, 0xa678, 0xad4b, + 0xad48, 0xad5b, 0xad51, 0xad3d, 0xad40, 0xad46, 0xad4d, 0xad3b, + 0xad4a, 0xad41, 0xad3e, 0xad4e, 0xb0ac, 0xb0e6, 0xb0e9, 0xb129, + 0x1221, 0xb133, 0xb12e, 0xb11e, 0x121f, 0xe3c5, 0xb122, 0xb127, + 0xb2e7, 0xb30b, 0xb466, 0xb6ad, 0xb6ae, 0x3038, 0xb72b, 0xb72a, + 0xb82c, 0xb82d, 0x1391, 0x1396, 0xb98f, 0xb993, 0xbac6, 0xbac5, + 0xbd15, 0xbd13, 0xbdb1, 0xbda9, 0x31ce, 0xbfa8, 0xbfab, 0xbfbe, + 0xbfac, 0xbfa9, 0xbfa6, 0xbfc1, 0xc1cc, 0xc1d1, 0xc1d3, 0xc1e4, + 0xc1cb, 0xc1e1, 0xc1d2, 0xc1e3, 0xc1cf, 0xc1d0, 0xc1e5, 0xc20e, + 0xc7cc, 0xc7ca, 0xc7cb, 0xc95c, 0xc961, 0xc95d, 0xc959, 0xcb77, + 0xd184, 0x3b41, 0x3bfd, 0x3c1a, 0x3c63, 0x3db6, 0x3db2, 0x3de9, + 0x3de7, 0x3dd6, 0x3e30, 0x3dec, 0x3ddd, 0x3de8, + /* 0x31 */ + 0x3db0, 0x3db5, 0x3de1, 0x3f98, 0x3f99, 0x00bc, 0x4093, 0x40e5, + 0x00d8, 0x4260, 0x425e, 0x00f4, 0x437b, 0x43f1, 0x43f3, 0x457f, + 0xe238, 0x4657, 0x4658, 0x4839, 0x48a7, 0x4835, 0x4860, 0x4851, + 0x4862, 0x4842, 0x483c, 0x4843, 0x48ab, 0x48a9, 0x48b4, 0x4879, + 0x486a, 0x483b, 0x48aa, 0x4833, 0x4837, 0x4827, 0x48a8, 0x4870, + 0x482f, 0x4836, 0x48b5, 0x4830, 0x483a, 0x4838, 0x48b1, 0x48ac, + 0x482e, 0x4875, 0x48b0, 0x4cf7, 0x4d00, 0x4cf1, 0x4cf3, 0x4e60, + 0x4e61, 0x4e32, 0x4e2d, 0x4e4a, 0x4e2a, 0x5067, 0x50a2, 0x50a3, + 0x509e, 0x50a4, 0x5144, 0x5132, 0x529b, 0x5298, 0x5299, 0x529a, + 0x5266, 0x5262, 0x526b, 0x8062, 0x5267, 0x553b, 0x5523, 0x5529, + 0x567e, 0x56f3, 0x0385, 0x56f5, 0x0383, 0x5780, 0x577e, 0x577c, + 0x577f, 0x577d, 0x5781, 0x5925, 0x5929, 0x5917, + /* 0x32 */ + 0x5963, 0x5967, 0x5965, 0x592a, 0x5968, 0x5926, 0x5964, 0x591b, + 0x5962, 0x5969, 0x5afe, 0x5b44, 0x5b42, 0x5bb7, 0x5bd2, 0x5bd4, + 0x5bd7, 0x5bdc, 0x5bd1, 0x5bd5, 0x5bcd, 0x5bd8, 0x5c9a, 0x5d42, + 0x5d35, 0x5d58, 0x5d34, 0x5d3c, 0x5d3b, 0x5d3e, 0x5d3d, 0x5d5a, + 0x5d41, 0x5d38, 0x5d45, 0x5d33, 0x5e26, 0x04ba, 0x5ef7, 0x5eef, + 0x5ef0, 0x5eee, 0x5f9d, 0x6006, 0x6011, 0x6008, 0x6002, 0x600a, + 0x6007, 0x6191, 0x618e, 0x6185, 0x61e8, 0x6217, 0x61d4, 0x0569, + 0x61c4, 0x61d5, 0x0545, 0x61d8, 0x6180, 0x61de, 0x6242, 0x64c7, + 0x64bf, 0x668d, 0x6689, 0x6690, 0x669a, 0x66c8, 0x6692, 0x66a1, + 0x6684, 0x6a57, 0x6a47, 0x6a77, 0x6a3a, 0x6a50, 0x6a42, 0x6a43, + 0x6aa3, 0x6b77, 0x6cb2, 0x6ce2, 0x6cbd, 0x6e74, 0x6f82, 0x6fb8, + 0x076c, 0x6fba, 0x6fb9, 0x6fbb, 0x6f87, 0xe2e4, + /* 0x33 */ + 0x6f83, 0x6fb7, 0x3b43, 0x73ce, 0x73ba, 0x7473, 0x7509, 0x750a, + 0x750b, 0x7507, 0x7505, 0x750e, 0x7597, 0x7677, 0x767b, 0x767a, + 0x7674, 0x7679, 0x7886, 0x78f5, 0x78a5, 0x789d, 0x78be, 0x7896, + 0x78e1, 0x78a4, 0x78a1, 0x78f6, 0x0904, 0x788d, 0x788b, 0x7878, + 0x7898, 0x790a, 0x7d5d, 0x7d27, 0x7d5f, 0x80c0, 0x80c1, 0x816d, + 0x815e, 0x818a, 0x8162, 0x8164, 0x0a3a, 0x82c0, 0x82ca, 0x82d1, + 0x0a79, 0x82c7, 0x82ce, 0x2309, 0x82c5, 0x8436, 0x8457, 0x8477, + 0x85f6, 0x85f7, 0x8655, 0x8644, 0x863e, 0x8642, 0x8652, 0x86e1, + 0x8708, 0x8768, 0x8767, 0x0b5d, 0xe337, 0x887e, 0x8893, 0x8879, + 0x8881, 0x887d, 0x887b, 0x8894, 0x0b8a, 0x8a66, 0x8ad9, 0x8ae0, + 0xe33e, 0x8b5f, 0x8c5f, 0x8c5e, 0x8c68, 0x0c27, 0x8c88, 0x8c6a, + 0x8c6c, 0x8c66, 0x8c67, 0x8c89, 0x8c60, 0x8c85, + /* 0x34 */ + 0x3e2a, 0x8e68, 0x8eb9, 0x8eba, 0x8ebe, 0x8f6f, 0x8f80, 0x8f74, + 0x8f81, 0x8f7a, 0x8f9c, 0x8f73, 0x8f82, 0x8f7f, 0x8fa7, 0x8f79, + 0x8f78, 0x8f7d, 0x8fa8, 0x8f7c, 0x9168, 0x914e, 0x929e, 0x0d46, + 0x0d40, 0x9298, 0x0d3f, 0x9285, 0x929c, 0x92c5, 0x929a, 0x9468, + 0x9465, 0x9467, 0x9461, 0x9460, 0x0d9d, 0x0dcb, 0x957b, 0x0de1, + 0x9619, 0x960e, 0x9631, 0x9612, 0x9610, 0x9615, 0x963f, 0x961d, + 0x961e, 0x994d, 0x9948, 0x9945, 0x9942, 0x9949, 0x994a, 0x9947, + 0x0e7f, 0x994c, 0x9acd, 0x9ad5, 0x9ac4, 0x9aca, 0x9ac3, 0x0f46, + 0x9d29, 0x9db4, 0x9e6d, 0x9e66, 0x9e6a, 0x9f15, 0x9fd3, 0x9fec, + 0xa055, 0x101a, 0xa1d6, 0xa1d8, 0xa251, 0xa1e0, 0xa203, 0xa204, + 0xa1da, 0xa1ea, 0xa202, 0xa1d3, 0xa1e4, 0xa1e5, 0xa43b, 0xa466, + 0xa52c, 0xa521, 0xa526, 0xa5d4, 0xa5d5, 0xa5d9, + /* 0x35 */ + 0xa6d5, 0xa6eb, 0xa6c5, 0x10d3, 0xa727, 0xa6f0, 0xa6b9, 0xa718, + 0xa6ee, 0x10d0, 0xa6b7, 0xa6bb, 0xa6ef, 0xa6b8, 0xa6df, 0xa6da, + 0xa6e3, 0xa6c9, 0xa6ec, 0xaca4, 0x118e, 0xaca3, 0xad5e, 0xad61, + 0xad62, 0xad63, 0xad8e, 0xad69, 0xad6b, 0xad85, 0xad8d, 0xad64, + 0xad6d, 0xb14c, 0xb149, 0xb147, 0xb148, 0xb142, 0xb145, 0xb15b, + 0xb15d, 0xb146, 0xb313, 0xb31a, 0xb30e, 0xb30f, 0xb31b, 0xb312, + 0xb3c3, 0xb3be, 0xb3bd, 0xb479, 0xb47c, 0x12c3, 0x12b6, 0xb480, + 0xb475, 0xb49b, 0x2f2f, 0xb474, 0x12c0, 0x12b8, 0x5b41, 0x5f94, + 0xb730, 0xb7a7, 0xb7a5, 0xb7a4, 0xb83a, 0xb95b, 0xb99f, 0xb9a8, + 0xb9b3, 0xb9a1, 0xb9a7, 0xb9b2, 0xb99d, 0xb9a3, 0xb9a2, 0xbaef, + 0xbad9, 0x13d9, 0xbad5, 0xbadd, 0xbada, 0xbaee, 0xbad7, 0xbd1a, + 0xbd19, 0xbd18, 0xbdb3, 0xbdbf, 0xbdbb, 0xbdc0, + /* 0x36 */ + 0xbdb9, 0xbdb8, 0xbdd5, 0xbf11, 0xbf10, 0xbfc3, 0xbfc2, 0xbfe9, + 0xbfcd, 0xbfe5, 0xbfca, 0xbfc7, 0xbfe8, 0xc1f1, 0xc20c, 0xc1ef, + 0xc1ee, 0xc1f3, 0xc20d, 0xc1f6, 0xc1f0, 0x14ec, 0xc2f5, 0xc2f4, + 0xc2f8, 0xc2fe, 0xc411, 0xc422, 0xc442, 0xc75c, 0xc75a, 0xc75d, + 0xc7d1, 0xc7d0, 0xc975, 0xc97b, 0xca89, 0xcf4d, 0xd189, 0xd192, + 0xd18c, 0xd188, 0xd367, 0xd368, 0x3e21, 0x3df2, 0x3e09, 0x3df8, + 0x3df0, 0x3df3, 0x3df5, 0x3dfb, 0x3df7, 0x3def, 0x3e0b, 0x3fa2, + 0x40f5, 0x40f3, 0x40f4, 0x40f2, 0x4198, 0x4268, 0x4280, 0x4285, + 0x428e, 0x428f, 0x3df4, 0x4286, 0x42a4, 0x4386, 0x4389, 0x4387, + 0x4385, 0x1adc, 0x4388, 0x45ff, 0x4666, 0x01cc, 0x48c3, 0x01a2, + 0x48c4, 0x493b, 0x48e7, 0x48f8, 0x48fb, 0x01b6, 0x48be, 0x48c6, + 0x01c5, 0x01c6, 0x48fc, 0x48c0, 0x4933, 0x48c9, + /* 0x37 */ + 0x48fe, 0x48da, 0x48cc, 0x48bb, 0x48fd, 0x48df, 0x48cd, 0x48c2, + 0x48c8, 0x4932, 0x492d, 0x48d2, 0x4931, 0x48d3, 0x492e, 0x48cf, + 0x4cff, 0x4d09, 0x4cfc, 0x4e72, 0x4eaa, 0x4eab, 0x4ea7, 0x4e7b, + 0x4e76, 0x4ea8, 0x4eac, 0x0283, 0x1b21, 0x50aa, 0x4503, 0x50ac, + 0x50ad, 0x50ab, 0x5150, 0x5158, 0x52dd, 0x02f8, 0x52ae, 0x52a2, + 0x52ab, 0x52e3, 0x52af, 0x52e0, 0x52e4, 0x02f6, 0x52a7, 0x52aa, + 0x52e2, 0x52e1, 0x52df, 0x52ad, 0x52e5, 0x52d1, 0x52ac, 0x52d5, + 0x52a3, 0x529f, 0x5479, 0x5476, 0x5543, 0x553d, 0x5547, 0x5544, + 0x553f, 0x555b, 0x567f, 0x579a, 0x579c, 0x039b, 0x581e, 0x5988, + 0x596a, 0x5976, 0x5972, 0x5970, 0x597e, 0x596c, 0x596f, 0x5975, + 0x5977, 0x5978, 0x598a, 0x5979, 0x5994, 0x5b01, 0x5c05, 0x5bf1, + 0x5bee, 0x5bef, 0x5c04, 0x1c3f, 0x5bfa, 0x5c07, + /* 0x38 */ + 0x5bf4, 0x5bf5, 0x5c9c, 0x5d6d, 0x5d69, 0x5d66, 0x5d62, 0x5d46, + 0x048d, 0x5d65, 0x5d5d, 0x5d5e, 0x5d5f, 0x5e8e, 0x5f02, 0x5f06, + 0x5f04, 0x5f03, 0x5f62, 0x6027, 0x6021, 0x6020, 0x6024, 0x6029, + 0x6031, 0x6023, 0x6022, 0x61dc, 0x624d, 0x61e5, 0x61d3, 0x61ee, + 0x61e6, 0x0556, 0x6236, 0x6240, 0x633f, 0x623d, 0x6244, 0x055b, + 0x625f, 0x6229, 0x6249, 0x628a, 0x622a, 0x6287, 0x624c, 0x6231, + 0x6248, 0x622b, 0x623b, 0x6241, 0x61c9, 0x6234, 0x6253, 0x6235, + 0x6247, 0x6238, 0x64d1, 0x64d2, 0x6551, 0x6555, 0x6552, 0x6553, + 0x668f, 0x66f4, 0x6747, 0x670d, 0x671c, 0x66fb, 0x6719, 0x66f7, + 0x66f9, 0x66f5, 0x66e9, 0x670a, 0x66ee, 0x670b, 0x66fd, 0x6706, + 0x6702, 0x6716, 0x6718, 0x66f0, 0x69d4, 0x6a66, 0x6a6a, 0x6a75, + 0x6a76, 0x6a80, 0x6a6d, 0x0696, 0x6a69, 0x6a67, + /* 0x39 */ + 0x6a68, 0x6a5d, 0x6ba4, 0x6bfe, 0x6bfd, 0x6cec, 0x6ce9, 0x6d21, + 0x6ceb, 0x6ce7, 0x6cf2, 0x6d20, 0x6e7a, 0x702d, 0x702e, 0x6fca, + 0x702f, 0x6fc8, 0x077e, 0x6fcb, 0x6fc3, 0x6f84, 0x6fd2, 0x6fc6, + 0x0781, 0x6fcf, 0x6fd5, 0x6fd4, 0x6fdd, 0x702b, 0x70a3, 0x6fdb, + 0x702c, 0x7013, 0x0835, 0x73d1, 0x73cc, 0x73d5, 0x73c9, 0x73cf, + 0x73d2, 0x747b, 0x747c, 0x7523, 0x751d, 0x751c, 0x751e, 0x7522, + 0x7524, 0x7520, 0x7518, 0x7521, 0x7688, 0x768a, 0x7694, 0x768f, + 0x768e, 0x7690, 0x089b, 0x76a7, 0x7764, 0x0900, 0x7918, 0x7914, + 0x791d, 0x7905, 0x78ff, 0x791b, 0x791a, 0x7919, 0x7903, 0x790e, + 0x7947, 0x7904, 0x795a, 0x7907, 0x7920, 0x7d6a, 0x7d66, 0x7d7a, + 0x7d65, 0x7daf, 0x80cd, 0x80cf, 0x80d1, 0x80ce, 0x815f, 0x8177, + 0x8174, 0x8188, 0x8175, 0x8189, 0x8172, 0x82c6, + /* 0x3a */ + 0x82ea, 0x82e0, 0x8307, 0x82e6, 0x82e5, 0x82dd, 0x82e3, 0x82da, + 0x84ae, 0x847e, 0x847d, 0x847f, 0x0ad3, 0x84d9, 0x85fa, 0x85fb, + 0x864d, 0x8654, 0x8651, 0x8650, 0x8898, 0x8895, 0x889d, 0x88c1, + 0x889a, 0x889b, 0x0b9f, 0x889c, 0x88d7, 0x88a4, 0x8896, 0x88a0, + 0x8a31, 0x8ae9, 0x8b6e, 0x8c9a, 0x8ca5, 0x8c94, 0x8ca6, 0x8c99, + 0x8c8b, 0x8c98, 0x8c91, 0x8c8c, 0x8ca1, 0x8ca3, 0x8cc6, 0x8e6f, + 0x8e6d, 0x8e6a, 0x8e6c, 0x8e71, 0x8e6e, 0x8edf, 0x8fac, 0x8faa, + 0x0cb1, 0x8fb5, 0x8fad, 0x8fb2, 0x8fb3, 0x8fab, 0x8fb6, 0x8fc7, + 0x8fc6, 0x916c, 0x9170, 0x92b3, 0x0d4b, 0x948c, 0x9481, 0x9483, + 0x947d, 0x9485, 0x9490, 0x94a2, 0x948d, 0x948f, 0x947e, 0x948a, + 0x947f, 0x9476, 0x9487, 0x9478, 0x9580, 0x9582, 0x9581, 0x9583, + 0x965a, 0x9634, 0x962c, 0x962a, 0x9640, 0x962d, + /* 0x3b */ + 0x9633, 0x962b, 0x964b, 0x283f, 0x963c, 0x995a, 0x9977, 0x9960, + 0x9afa, 0x9af9, 0x9afc, 0x0ed6, 0x9af5, 0x9ae8, 0x9b09, 0x9ae7, + 0x9ae6, 0x9ae9, 0x9d32, 0x9d2c, 0x9dbd, 0x9dbc, 0x9e7a, 0x9e7e, + 0x9e79, 0x0f89, 0x9f23, 0x9f30, 0x9f28, 0x9fd4, 0xa5ce, 0x9ff1, + 0x9ff0, 0xa060, 0xa065, 0xa1a8, 0xa20a, 0xa21b, 0xa212, 0xa207, + 0xa24f, 0xa20e, 0xa252, 0xa216, 0x1000, 0xa253, 0xa254, 0xe384, + 0xa256, 0xa46d, 0xa472, 0xa52f, 0xa72a, 0x10dc, 0xa763, 0xa784, + 0xa7af, 0xa745, 0xa770, 0xa756, 0xa716, 0xa73d, 0xa738, 0xa76f, + 0xa777, 0xa72e, 0xa731, 0xa74c, 0xa75f, 0xa775, 0xa739, 0xa73a, + 0xa72c, 0xa72d, 0xa73f, 0xa72f, 0xa730, 0xa73e, 0x2ad0, 0x1190, + 0xacb2, 0xadb7, 0xad8f, 0x11b1, 0xad96, 0xad9e, 0xad97, 0xad95, + 0xada5, 0xad98, 0x2be7, 0xada3, 0xad9a, 0xadad, + /* 0x3c */ + 0xada6, 0xadb6, 0xad99, 0xadaf, 0xadac, 0x11aa, 0xad9f, 0xad94, + 0xb0eb, 0xb16f, 0xb16d, 0xb17e, 0xb16c, 0xb161, 0xb163, 0xb16b, + 0xb15e, 0xb13e, 0xb164, 0xb1ad, 0x127d, 0xb320, 0xb3d1, 0xb3d5, + 0xb4ae, 0xb4af, 0xb49f, 0xb4a8, 0xb4ca, 0xb6e1, 0xb739, 0xb738, + 0xb73b, 0xb7ad, 0xb7b5, 0xb7af, 0xb7b1, 0xb7ae, 0xb7b4, 0xb7b0, + 0xb84b, 0xb851, 0xb84c, 0x1369, 0xb860, 0xb9be, 0xb9b9, 0xb9b7, + 0xb9b6, 0x13a1, 0xb9bd, 0xb9b8, 0xb9c1, 0xbaf7, 0xbaf3, 0xbaf4, + 0xbafb, 0xbafd, 0xbaf5, 0x13e7, 0xbafa, 0xbb14, 0x13ec, 0xbaf2, + 0xbafc, 0xbb00, 0x13df, 0xbd2b, 0xbd29, 0xbd2e, 0x1433, 0xbdd7, + 0xbddb, 0xbdd9, 0xbdd8, 0xbde6, 0xbdd6, 0xbdd1, 0xbde7, 0xbdd0, + 0xbddc, 0xbfed, 0xc01a, 0xc019, 0xc016, 0xbfec, 0xbfef, 0xbfee, + 0xbff4, 0xc02f, 0xc230, 0xc219, 0xc218, 0xc211, + /* 0x3d */ + 0xc216, 0xc212, 0xc210, 0xc214, 0xc30c, 0xc30d, 0xc410, 0xc429, + 0xc428, 0xc765, 0xc766, 0xc7de, 0xc7df, 0xc7e0, 0xc7d9, 0xc7db, + 0xc7d8, 0xc7e3, 0xc7d7, 0xc9a6, 0xc9a7, 0xc9bf, 0xc9a8, 0xc99f, + 0xc9a1, 0xc9a2, 0xc9ad, 0xc9a3, 0xc9a0, 0xcb83, 0xcb85, 0xcb82, + 0xcb84, 0xccee, 0xcd5d, 0xce92, 0xcf55, 0xcf53, 0xe3fc, 0xcf51, + 0xcf52, 0xcf50, 0xd09d, 0xd187, 0xd197, 0xd19b, 0xd19d, 0xd369, + 0xd511, 0x17ee, 0xd77a, 0x1832, 0x6d44, 0x3bc6, 0x3e40, 0x3e2e, + 0x3e68, 0x3e2d, 0x3e34, 0x3e32, 0x3e69, 0x3e31, 0x3e6a, 0x3e3e, + 0x3e6f, 0x3e75, 0x3ff6, 0x4020, 0x4028, 0x4067, 0x40fb, 0x40fe, + 0x40fc, 0x40fd, 0x40ff, 0x40fa, 0x42ac, 0x42af, 0x42b1, 0x00fc, + 0x42bf, 0x42be, 0x42a7, 0x42aa, 0x4394, 0x4393, 0x4399, 0x012a, + 0x43fa, 0x4456, 0x4522, 0x4591, 0x4592, 0x4608, + /* 0x3e */ + 0x4606, 0x48d6, 0x4937, 0x494b, 0x49ce, 0x49d0, 0x4939, 0x4964, + 0x49cf, 0x4946, 0x4966, 0x4956, 0x4943, 0x494a, 0x4958, 0x4965, + 0x495a, 0x495b, 0x4955, 0x4950, 0x494c, 0x49cd, 0x4951, 0x4947, + 0x01d3, 0x4953, 0x4962, 0x49cc, 0x01d7, 0x497f, 0x494d, 0x4d0a, + 0x4d0c, 0x4d0f, 0x4ebb, 0x4eb9, 0x4eeb, 0x4eae, 0x4ec1, 0x4eea, + 0x4ebe, 0x4ebf, 0x4eba, 0x4eb7, 0x4eb3, 0x4ee9, 0x506e, 0x50af, + 0x50b3, 0x50b2, 0x5168, 0x5169, 0x516a, 0x52de, 0x52eb, 0x5311, + 0x52ed, 0x52e9, 0x52f7, 0x52f4, 0x52ea, 0x5312, 0x52e8, 0x5313, + 0x548e, 0x5486, 0x5563, 0x5565, 0x5699, 0x57c2, 0x57ae, 0x57b0, + 0x57ad, 0x59b4, 0x59d1, 0x59ad, 0x03f3, 0x59bd, 0x59b7, 0x59ab, + 0x59af, 0x59c1, 0x59b5, 0x5c0f, 0x5c0e, 0x5c1c, 0x5c13, 0x5c0a, + 0x5c1e, 0x5c14, 0x5c1a, 0x5ccb, 0x5d87, 0x5d93, + /* 0x3f */ + 0x0491, 0x5d84, 0x5d85, 0x5d92, 0x5d80, 0x5e2b, 0x5e63, 0x5f0a, + 0x04c0, 0x5f66, 0x6034, 0x6033, 0x604d, 0x6289, 0x6257, 0x1e17, + 0x624a, 0x0563, 0x6239, 0x623f, 0x6290, 0x628f, 0x62b2, 0x629f, + 0x6295, 0x62a1, 0x629c, 0x628e, 0x62a0, 0x62ae, 0x6296, 0x62ca, + 0x62ac, 0x0570, 0x62a6, 0x6297, 0x6293, 0x3eb6, 0x64d6, 0x64e0, + 0x64d8, 0x6556, 0x676e, 0x677e, 0x6774, 0x6777, 0x6780, 0x677a, + 0x676b, 0x675f, 0x6776, 0x67b0, 0x6763, 0x6a92, 0x6a82, 0x6a9d, + 0x6a94, 0x6a83, 0x6a8b, 0x6a84, 0x6b57, 0x6b84, 0x6bb5, 0x6c09, + 0x6ce6, 0x0702, 0x6d25, 0x6d51, 0x6e3e, 0xe2da, 0x6e85, 0x703f, + 0x7042, 0x7038, 0x703a, 0x704e, 0x7045, 0x7039, 0x7037, 0x7044, + 0xe2e7, 0x70a4, 0x703d, 0x7041, 0x73df, 0x73de, 0x73ca, 0x73e9, + 0x73e2, 0x73e0, 0x7489, 0x7487, 0x7532, 0x7533, + /* 0x40 */ + 0x75ac, 0x75f9, 0x760d, 0x76b9, 0x795e, 0x796a, 0x0935, 0x7981, + 0x7969, 0x79ac, 0x7980, 0x7975, 0x7971, 0x7976, 0x796f, 0x7db6, + 0x7e03, 0x7dbf, 0x7e01, 0x7db2, 0x7dc4, 0x80db, 0x80dc, 0x80d8, + 0xd172, 0x81b5, 0x81a8, 0x818f, 0x819e, 0x818e, 0x82de, 0x82e2, + 0x8320, 0x831d, 0x831a, 0x8319, 0x832b, 0x8318, 0x8310, 0x830e, + 0x8324, 0x831f, 0x8313, 0x8335, 0x8483, 0x0ae0, 0x84d7, 0x8602, + 0x8603, 0x865c, 0x865f, 0x86c7, 0x879a, 0x8797, 0x87a3, 0x88f7, + 0x88c6, 0x88cc, 0x88d6, 0x88cd, 0x88f9, 0x88d9, 0x88d8, 0x0b9a, + 0x88d1, 0x88ce, 0x88d5, 0x0ba3, 0x88d4, 0x88f8, 0x8a7a, 0x8a79, + 0x8a7f, 0x8af3, 0x8af5, 0x8af6, 0x8af4, 0x8af7, 0x0c05, 0x8b79, + 0x8c9c, 0x8cdf, 0x8cf5, 0x8cff, 0x8cd1, 0x8cda, 0x8ccf, 0x8ccd, + 0x8cde, 0x8cd8, 0x75ad, 0x8ce0, 0x8cfe, 0x8c9e, + /* 0x41 */ + 0x8e75, 0x8e73, 0x8e72, 0x8ed8, 0x8fd0, 0x8fd6, 0x8fd7, 0x8fca, + 0x8fcd, 0x918a, 0x9189, 0x918b, 0x92d3, 0x92da, 0x92ce, 0x92d2, + 0x0d5e, 0x92d4, 0x92d7, 0x92d5, 0x92fb, 0x92cd, 0x92fa, 0x92d6, + 0x0da6, 0x949b, 0x949e, 0x949d, 0x94a4, 0x949f, 0x94a5, 0x94a8, + 0x958f, 0x958c, 0x9595, 0x9660, 0x9655, 0x965c, 0x966f, 0x9651, + 0x9661, 0x96a7, 0x965e, 0x9662, 0x9654, 0x966e, 0x9652, 0x9658, + 0x966d, 0x965f, 0x966c, 0x9650, 0x965d, 0x968e, 0x9972, 0x9978, + 0x9975, 0x9976, 0x997c, 0x997e, 0x997d, 0x9b15, 0x9b14, 0x9b1d, + 0x9b1c, 0x9b23, 0x9b57, 0x9dc8, 0x0f5d, 0x9dc9, 0x9dc5, 0x9e87, + 0x9e8a, 0x9e94, 0x9f39, 0x9f40, 0x9f3e, 0x9f38, 0x9fd6, 0x0fb8, + 0xa077, 0xa078, 0xa07d, 0xa1dd, 0xa25e, 0xa277, 0xa2d4, 0xa266, + 0xa25f, 0xa273, 0xa272, 0xa297, 0xa25a, 0xa296, + /* 0x42 */ + 0xa25d, 0xa265, 0xa270, 0xa275, 0xa274, 0xa25c, 0xa260, 0x1034, + 0xa26d, 0xa441, 0xa53c, 0xa53e, 0x106f, 0xa549, 0xa6e4, 0xa80c, + 0xa815, 0xa80e, 0xa7d4, 0xa7c7, 0xa814, 0xa7db, 0xa85f, 0xa7ed, + 0xa809, 0xa7cf, 0xa7ff, 0xa81a, 0xa7f5, 0xa7ee, 0xa7e5, 0xa80d, + 0xa7df, 0xa7ec, 0xa7d7, 0xa82c, 0xa7cd, 0xa7e3, 0xa800, 0xa7eb, + 0xa7fd, 0xa80f, 0xa82d, 0xa850, 0xa7fe, 0xa7c4, 0xa7e1, 0xa7f9, + 0xacbb, 0xacbc, 0x1194, 0x1193, 0xacba, 0xadd0, 0xadd6, 0xadce, + 0xade1, 0xadd5, 0xadcf, 0xadd3, 0x2c14, 0xadd4, 0xb0b5, 0xb190, + 0xb1a1, 0xb181, 0xb185, 0xb16e, 0xb188, 0xb182, 0xb186, 0xb18f, + 0xb189, 0xb180, 0xb184, 0x2dd1, 0xb329, 0xb32b, 0xb32a, 0xb330, + 0xb3e2, 0xb3e3, 0xb3e1, 0xb4d5, 0xb4c4, 0xb4c9, 0xb4e0, 0xb4df, + 0xb4cb, 0xb4dd, 0xb4e8, 0xb4d4, 0xb51c, 0xb6b5, + /* 0x43 */ + 0xb6b6, 0xb6e5, 0xb745, 0xb749, 0xb740, 0xb746, 0xb744, 0xb74a, + 0xb7c9, 0xb7c4, 0xb7c2, 0xb868, 0x30cb, 0xb882, 0xb86b, 0xb867, + 0xb86c, 0xb86d, 0xb871, 0x1392, 0xb9d7, 0xb9d2, 0xb9d9, 0x13aa, + 0xb9bc, 0xb9dd, 0xb9d6, 0x13a7, 0xb9d8, 0xbb20, 0xbb16, 0xbb18, + 0xbb15, 0xbb19, 0xbb27, 0xbb50, 0xbb1d, 0xbb2c, 0xbb1c, 0xbb29, + 0xbb2b, 0xbb24, 0x13ef, 0xbb28, 0xbd39, 0xbdf2, 0xbdf0, 0x31ed, + 0xbded, 0xbdef, 0xbdea, 0xbe01, 0xbfbc, 0xc05c, 0xc05b, 0xc05a, + 0xc026, 0xc243, 0xc233, 0xc23a, 0xc237, 0xc236, 0xc23c, 0xc234, + 0xc24a, 0xc23b, 0xc235, 0xc23d, 0xc240, 0xc23e, 0xc217, 0xc326, + 0xc324, 0xc310, 0xc336, 0xc325, 0x1522, 0xc466, 0xc77f, 0xc77a, + 0xc7fb, 0xc7fd, 0xc7fc, 0xc7fa, 0xc9d6, 0xc9d2, 0xc9c8, 0xc9c2, + 0xc9c7, 0xc9cd, 0xc9c1, 0xc9c6, 0xc9cc, 0xcaa1, + /* 0x44 */ + 0xcb95, 0xcb94, 0xcb97, 0xcb96, 0xcb93, 0xcba1, 0xcd09, 0xcd08, + 0xcd67, 0xcd65, 0xcd62, 0xcd61, 0xce97, 0xcf01, 0xcf19, 0xcf18, + 0xcf5c, 0xcf67, 0xcf6c, 0x16b5, 0xe3fd, 0xcf66, 0xcf61, 0xcf6e, + 0xcf5d, 0xcf5a, 0xd0a2, 0xd0a9, 0xd0a5, 0xd0a6, 0xd0b2, 0xd0a3, + 0xd1ac, 0xd1aa, 0xd1af, 0xd1ab, 0xd1b1, 0xd1c6, 0xd1ad, 0xd1b9, + 0xd370, 0x1775, 0xd70c, 0xd781, 0xd783, 0xd77e, 0xd851, 0xda99, + 0xda94, 0xda95, 0xddfe, 0xdf18, 0x3c05, 0x3e72, 0x0082, 0x3e99, + 0x3fad, 0x4106, 0x42c2, 0x42cb, 0x42d5, 0x42d2, 0x42cc, 0x42d7, + 0x42c5, 0x42ca, 0x1aec, 0x43a2, 0x43a3, 0x43a1, 0x1ae8, 0x43a6, + 0x43a4, 0x43ff, 0x4400, 0x0135, 0x4506, 0x4525, 0x459f, 0x467f, + 0x49ea, 0x49eb, 0x49de, 0x4a18, 0x49e0, 0x49e8, 0x49df, 0x49f1, + 0x49ec, 0x4a1a, 0x49e6, 0x49e1, 0x4a5d, 0x3b77, + /* 0x45 */ + 0x4a1e, 0x01f0, 0x4a80, 0x4d17, 0x4f1d, 0x4ef7, 0x4eef, 0x4eee, + 0x4eed, 0x4ef5, 0x4f1e, 0x50bd, 0x92ff, 0x50be, 0x516d, 0x5176, + 0x534c, 0x5319, 0x5348, 0x531e, 0x534a, 0x5349, 0x5326, 0x5495, + 0x5585, 0x557e, 0x5597, 0x557d, 0x5642, 0x569e, 0x570c, 0x570b, + 0x570e, 0x57cf, 0x59d8, 0x59e0, 0x59e8, 0x59e9, 0x59e2, 0x59e1, + 0x59da, 0x59e3, 0x59d9, 0x59f0, 0x59e7, 0x59e4, 0x5c23, 0x5c31, + 0x5c33, 0x5c0c, 0xa4e0, 0x5c26, 0x5c24, 0x5c32, 0x5c27, 0x5c21, + 0x5c30, 0x5ca2, 0x5ccc, 0x5d96, 0xe28f, 0x5d98, 0x5d9c, 0x5d9b, + 0x5e6b, 0x5f12, 0x5f14, 0x605a, 0x6054, 0x6051, 0x605e, 0x6058, + 0x04f0, 0x6059, 0x629a, 0x62f2, 0x62ad, 0x6320, 0x62f1, 0x62f0, + 0x62f3, 0x62f4, 0x62e9, 0x62fe, 0x632e, 0x62e8, 0x62e7, 0x62ff, + 0x62f5, 0x64e5, 0x64e7, 0x64e6, 0x64e9, 0x6558, + /* 0x46 */ + 0x676c, 0x67d9, 0x063e, 0x67cb, 0x0639, 0x67be, 0x67b5, 0x67d1, + 0x67c2, 0x67b6, 0x67d3, 0xe2c2, 0x69da, 0x06a2, 0x6aae, 0x06a1, + 0x6aac, 0x6aa9, 0x6aba, 0x6aa7, 0x6ab3, 0x6abd, 0x6ab1, 0x6c0e, + 0x6c11, 0x6c0f, 0x6d52, 0x6d6a, 0x6d54, 0x6d55, 0x6d53, 0x6d57, + 0xe2d0, 0x6d5b, 0x6d58, 0x6d59, 0x073b, 0x70b8, 0x70b5, 0x70bf, + 0x70c1, 0x70bb, 0x07b7, 0x70c3, 0x70ad, 0x70a8, 0x70ae, 0x70aa, + 0x70d0, 0x70b1, 0x70bc, 0x70b7, 0x70b0, 0x70fa, 0x70fb, 0x70b9, + 0x7407, 0x73fc, 0x73ff, 0x73f2, 0x73f8, 0x73f4, 0x0857, 0x0870, + 0x75ae, 0x760f, 0x7610, 0xd5c1, 0x76c7, 0x76c6, 0x76ce, 0x08a7, + 0x76dc, 0x79d5, 0x79d3, 0x7a20, 0x79e2, 0x79f1, 0x79db, 0x79ea, + 0x79eb, 0x79e1, 0x79ff, 0x79d6, 0x79e0, 0x79d7, 0x79e5, 0x0954, + 0x7e1b, 0x7e10, 0x7e0f, 0x7e0e, 0x7e39, 0x7e0a, + /* 0x47 */ + 0x7e14, 0x7e0c, 0x8023, 0x805a, 0x80e2, 0x8193, 0x81b0, 0x81ab, + 0x81bd, 0x81b1, 0x818d, 0x81ad, 0x81aa, 0x81ac, 0x81bc, 0x81c9, + 0x8347, 0x8362, 0x8340, 0x8344, 0x833f, 0x8343, 0x833d, 0x8360, + 0x835f, 0x833a, 0x8342, 0x835e, 0x835d, 0x84bc, 0x84e0, 0x84ee, + 0x84eb, 0x850d, 0x8609, 0x860c, 0x8669, 0x8674, 0x8667, 0x0b31, + 0x2427, 0x87ad, 0x88ff, 0x8916, 0x8908, 0x8909, 0x8900, 0x88fc, + 0x8913, 0x8914, 0x890a, 0xd33e, 0x8929, 0x8917, 0x893b, 0x88fb, + 0x0bbf, 0x890e, 0x0be4, 0x8b08, 0x8d1b, 0x8d1a, 0x8d19, 0x8d02, + 0x0c4a, 0x8d17, 0x8d07, 0x8d13, 0x8d09, 0x8d0a, 0x8d12, 0x8daa, + 0x8d38, 0x8e7b, 0x8e7c, 0x8e7a, 0x8eea, 0x8eeb, 0x8eef, 0x8ef0, + 0x9009, 0x9002, 0x9001, 0x902b, 0x9007, 0x0ccf, 0x9028, 0x8ffb, + 0x902a, 0x8ffe, 0x9004, 0x9029, 0x900a, 0x268c, + /* 0x48 */ + 0x91c2, 0x2691, 0x91a6, 0x0d14, 0x6ac6, 0x5707, 0x930a, 0x92fd, + 0x9306, 0x930d, 0x9309, 0x930b, 0x9300, 0x9305, 0x933d, 0x94d5, + 0x94bf, 0x94ba, 0x94c7, 0x9598, 0x959a, 0x0e0d, 0x96a4, 0x969c, + 0x969d, 0x96a2, 0x9696, 0x9695, 0x96a5, 0x96aa, 0x96ad, 0x969a, + 0x96a3, 0x9697, 0x9690, 0x96af, 0x968d, 0x0e01, 0x96a8, 0x96ee, + 0x99a3, 0x9999, 0x99a1, 0x999c, 0x99a4, 0x99cb, 0x9b56, 0x9b48, + 0x9b59, 0x9b4a, 0x9b5c, 0x0ef1, 0x9b4f, 0x9b4d, 0x9b5d, 0x9d3a, + 0x9de3, 0x9de1, 0x9dde, 0x9e97, 0x9e9a, 0x9f48, 0x9f4a, 0x9f4c, + 0x9f4e, 0x9f4f, 0x9f4b, 0x9f4d, 0x9f47, 0x9f51, 0x9fda, 0x9ff9, + 0x9ffc, 0x9ffb, 0x9ffd, 0x9ff8, 0x9ffa, 0xa08a, 0xa08e, 0xa088, + 0xa089, 0xa08d, 0xa090, 0xe37e, 0xa21c, 0xa2ab, 0xa2a4, 0xa2a8, + 0xa2ad, 0xa29f, 0xa29a, 0xa2b0, 0xa2a5, 0xa2d5, + /* 0x49 */ + 0xa2a2, 0xa2b2, 0xa29d, 0xa2a1, 0xa415, 0xa442, 0xa473, 0xa484, + 0xa4dd, 0xa55c, 0xa54c, 0x1076, 0xa54b, 0xa767, 0xa8a8, 0xa87f, + 0xa88d, 0xa88b, 0xa8f7, 0xa8a9, 0xa8f4, 0xa89a, 0xa88c, 0xa895, + 0xa87e, 0xa877, 0x110a, 0x1103, 0xa871, 0xa8fd, 0xa888, 0xa899, + 0xa86d, 0xa8d4, 0xa891, 0xa87d, 0xa863, 0xa875, 0xa8f9, 0xa88e, + 0xa874, 0xa8d9, 0xa866, 0xa8fa, 0xa8f5, 0x2b60, 0xacc1, 0xacc9, + 0xae03, 0xae2c, 0xae34, 0xae17, 0xae09, 0xae04, 0xae06, 0xae1a, + 0xae0e, 0xae27, 0xae05, 0xae07, 0xae19, 0xae14, 0xae0c, 0xae1d, + 0xae22, 0xae23, 0xb0bb, 0xb0bc, 0xb0ba, 0xb1a9, 0xb1b5, 0xb1ac, + 0xb1aa, 0xb1af, 0xb1b7, 0x1235, 0x1236, 0xb33d, 0xb345, 0xb348, + 0xb33c, 0xb33e, 0xb3ec, 0xb3ed, 0xb3e9, 0xb50a, 0xb50b, 0xb4f8, + 0xb504, 0xb4f6, 0xb4f9, 0xb753, 0xb752, 0xb760, + /* 0x4a */ + 0xb763, 0xb7ce, 0xb7cd, 0xb7d0, 0xb7cc, 0xb887, 0xb88d, 0xb89d, + 0x1373, 0xb963, 0xb9f4, 0xb9f1, 0xb9ff, 0xb9f5, 0xb9fc, 0xb9f2, + 0xb9f6, 0x13b1, 0xb9fa, 0x13af, 0xbb2e, 0xbb45, 0xbb43, 0xbb51, + 0xbb4c, 0xbb73, 0xbb47, 0xbb4b, 0xbb4f, 0x13f4, 0xbb44, 0xbb4d, + 0xbb4e, 0xbb4a, 0xbb41, 0xbb52, 0xbb9f, 0xbb54, 0xbb59, 0xbba2, + 0xbd4b, 0xbd48, 0xbe0d, 0xbe1f, 0xbe08, 0xbe0e, 0xbe1d, 0xbe04, + 0xbf18, 0xbf1b, 0xc066, 0xc062, 0xc083, 0xc067, 0xc262, 0xc24f, + 0xc24e, 0xc267, 0xc253, 0xc24d, 0xc24c, 0xc268, 0xc251, 0x14dc, + 0xc258, 0xc25b, 0xc250, 0xc26a, 0xc339, 0xc338, 0xc482, 0xc484, + 0xc486, 0xc780, 0xc786, 0xc825, 0xc811, 0x1599, 0xc80e, 0xc815, + 0xc80f, 0xc818, 0xc80d, 0xc813, 0xc816, 0xc819, 0xca08, 0xc9f7, + 0xc9fb, 0xc9fc, 0xcab4, 0xcabe, 0xcac1, 0xcba6, + /* 0x4b */ + 0xcba5, 0xcba2, 0xcba4, 0xcd12, 0xcd0e, 0xcd7a, 0xcd78, 0xcd7d, + 0xcd7e, 0xcd81, 0xcd83, 0xcd80, 0xcd82, 0xce9b, 0xce99, 0xce9c, + 0xce9a, 0xcea1, 0xcf1a, 0xcf1c, 0xcf8a, 0xcf79, 0xcf73, 0xcf75, + 0xcf7c, 0xcf78, 0xcf60, 0xcf83, 0xcf70, 0x16b6, 0x16bd, 0xcf87, + 0xcf84, 0xcf7b, 0xcf7e, 0xcf74, 0xd0b9, 0xd0b8, 0xd0b7, 0xd0b5, + 0xd1cc, 0xd1ce, 0xd1d1, 0x3504, 0xd1cb, 0x359b, 0xd37e, 0xd37a, + 0xd377, 0xd38c, 0xd3e1, 0xd520, 0xd51e, 0xd5c2, 0xd60f, 0xd600, + 0x17f4, 0xd610, 0xd70d, 0xd70e, 0xd78e, 0xd78d, 0xd78a, 0xd78b, + 0xd78c, 0xd78f, 0xd857, 0x1835, 0xd855, 0xd85b, 0xdaac, 0xdaa7, + 0xdaa0, 0xda9e, 0x18aa, 0xdd8d, 0x191f, 0xde93, 0xde94, 0xde92, + 0x3c81, 0x3ed6, 0x3ec3, 0x3ee4, 0x3ee2, 0x3f09, 0x3ebf, 0x3ec8, + 0x3ec7, 0x3fb5, 0x3fb2, 0x410c, 0x410b, 0x410a, + /* 0x4c */ + 0x4105, 0x42d3, 0x42e6, 0x42e9, 0x42f0, 0x42ea, 0x42e7, 0x43b1, + 0x43b3, 0x43b4, 0x43b0, 0x445c, 0x445d, 0x445e, 0x44c0, 0x45af, + 0x0150, 0x4686, 0x4683, 0x4684, 0x4a5c, 0x4a70, 0x4a8c, 0x4a7b, + 0x4a66, 0x4a79, 0x4a63, 0x4ac5, 0x4a6b, 0x4a6d, 0x4a72, 0x4a69, + 0x4a75, 0x4a89, 0x4ac6, 0x4aa5, 0x3ee7, 0x4a6a, 0x4a97, 0x4f5a, + 0x4f5c, 0x4f59, 0x4f24, 0x4f25, 0x4f30, 0x4f58, 0x4f31, 0x5076, + 0x50c1, 0x5185, 0x517d, 0x5365, 0x5387, 0x5352, 0x5354, 0x538a, + 0x5350, 0x5386, 0x534f, 0x5368, 0x549d, 0x55a0, 0x55ba, 0x55bd, + 0x55b8, 0x56a6, 0x037b, 0x57de, 0x57d8, 0x57d1, 0x5a13, 0x0409, + 0x5a0e, 0x5a1b, 0x5a3a, 0x0407, 0x5a1c, 0x5a12, 0x5a16, 0x5a1a, + 0x4f48, 0x5c4b, 0x5c37, 0x5c36, 0x5c38, 0x5c3a, 0x5c49, 0x5c3c, + 0x5c4a, 0x5db1, 0x5dc2, 0x5db5, 0x5dc4, 0x5db6, + /* 0x4d */ + 0x5f1e, 0x5f1f, 0x5faf, 0x606b, 0x606f, 0x6292, 0x62e4, 0x632c, + 0x62ef, 0x1e84, 0x634f, 0x6352, 0x6350, 0x633a, 0x6337, 0x6347, + 0x6364, 0x6340, 0x633c, 0x6345, 0x6341, 0x64f3, 0x05bb, 0x67c1, + 0x67b4, 0x064b, 0x682a, 0x6822, 0x6829, 0x064d, 0x683e, 0x683c, + 0x6830, 0x6ac7, 0x6ad5, 0x6ad6, 0x6ad3, 0x6ace, 0x6ac8, 0x6b5c, + 0x6b5f, 0x6b62, 0x06c2, 0x6bbd, 0x6bbf, 0x6d5c, 0x6db6, 0x071a, + 0x6d9d, 0x6d7f, 0x0712, 0x6d94, 0x6d81, 0x6e47, 0x6e46, 0x073c, + 0x6e94, 0x7175, 0x711a, 0x712a, 0x7132, 0x7117, 0x7123, 0x7174, + 0x07c3, 0x7176, 0x712e, 0x7125, 0x7120, 0x7171, 0x7116, 0x7170, + 0x712c, 0x712f, 0x711f, 0x7164, 0x07c0, 0x7408, 0x7414, 0x740a, + 0x740b, 0x754f, 0x7559, 0x7554, 0x7551, 0x75b6, 0x76ec, 0x76ed, + 0x76ea, 0x79ee, 0x7a5a, 0x7a73, 0x7a65, 0x7a61, + /* 0x4e */ + 0x7a55, 0x7a6b, 0x7a64, 0x7a5b, 0x7a4c, 0x7a6f, 0x7a84, 0x7a70, + 0x7e5d, 0x7e57, 0x7e66, 0x7e53, 0x7e98, 0x7e97, 0x8028, 0x80eb, + 0x80ea, 0x80e8, 0x80ec, 0x80ef, 0x81d1, 0x81ca, 0x229f, 0x81cf, + 0x81cd, 0x81ce, 0x8370, 0x8367, 0x8373, 0x836d, 0x8376, 0x8379, + 0x836a, 0x838b, 0x8372, 0x8371, 0x836e, 0x837a, 0x8516, 0x8539, + 0x853b, 0x8610, 0x8696, 0x867b, 0x867c, 0x867d, 0x87be, 0x895c, + 0x8938, 0x8939, 0x892e, 0x8934, 0x8932, 0x895b, 0x8933, 0x893c, + 0x0be5, 0x8b0e, 0x8b0f, 0x8b10, 0x8b87, 0x8d5b, 0x8d53, 0x0c5f, + 0x8d5c, 0x8d3f, 0x8d59, 0x8d4a, 0x8d44, 0x8d4c, 0x8d40, 0x8d5f, + 0x8d5e, 0x8d4e, 0x8d54, 0x8d43, 0x8d87, 0x8e82, 0x8e85, 0x9031, + 0x9047, 0x902e, 0x902f, 0x9048, 0x9034, 0x0d18, 0x409f, 0x9332, + 0x9336, 0x9333, 0x9331, 0x9340, 0x9341, 0x94dd, + /* 0x4f */ + 0x94d2, 0x94d9, 0x0dad, 0x94df, 0x94db, 0x94d8, 0x94d3, 0x94de, + 0x94e0, 0x94d4, 0x94d7, 0x94da, 0x95a7, 0x96fe, 0x96dd, 0x9740, + 0x96e2, 0x0e1e, 0x96d6, 0x96de, 0x96ef, 0x0e27, 0x96eb, 0x96ea, + 0x96e4, 0x96d1, 0x0e18, 0x96ec, 0x96fa, 0x96d9, 0x96f3, 0x96e1, + 0x96dc, 0x96e5, 0x96df, 0x96d4, 0x0e20, 0x9705, 0x99d6, 0x99d5, + 0x99d0, 0x99c8, 0x99c4, 0x99c9, 0x99cd, 0x99d2, 0x99cc, 0x99ca, + 0x9ba0, 0x9b92, 0x0ef4, 0x0f02, 0x9b8b, 0x9ba1, 0x9b95, 0x9b88, + 0x9b86, 0x9b8d, 0x9b85, 0x9b91, 0x9b89, 0x9ba2, 0x9df0, 0x9df3, + 0x9df4, 0x9def, 0x9e06, 0x9ea2, 0x9f5e, 0x9f63, 0x9f60, 0x9f5b, + 0x9f7b, 0x9f58, 0x9f59, 0x9f5d, 0xa005, 0xa006, 0xa002, 0xa003, + 0xa004, 0xa0a2, 0xa0a7, 0xa0a6, 0xa0a4, 0xa0ac, 0xa0a9, 0xa2e7, + 0xa301, 0xa2df, 0xa2d9, 0xa2e3, 0xa30f, 0xa41a, + /* 0x50 */ + 0xa445, 0xa448, 0xa47b, 0xa485, 0xa486, 0xa4fe, 0xa4ff, 0xa564, + 0xa571, 0xa572, 0xa561, 0xa562, 0xa56c, 0xa560, 0xa55d, 0xa563, + 0xa567, 0xa901, 0xa92a, 0xa930, 0xa906, 0xa97d, 0xa922, 0xa9b9, + 0xa90a, 0xa910, 0xa88f, 0xa980, 0xa913, 0xa92e, 0xa918, 0xa917, + 0xa91a, 0xa914, 0xa947, 0xa963, 0xa938, 0x1124, 0xa97f, 0xa921, + 0xa937, 0xa931, 0xa91b, 0xa9a5, 0xaa6c, 0xacd3, 0xae88, 0xae6e, + 0xae5c, 0xae74, 0xae54, 0xae83, 0x2c70, 0xae65, 0xae60, 0xae70, + 0xae6f, 0xae6d, 0xae72, 0xae6c, 0xae76, 0xae75, 0xae59, 0xaec7, + 0xb0c1, 0xb0f9, 0xb1e3, 0xb1e7, 0xb1d6, 0xb1cf, 0xb1da, 0xb1e9, + 0xb1d2, 0xb355, 0xb34f, 0xb34d, 0xb351, 0xb356, 0xb3f9, 0xb3f8, + 0xb406, 0xb403, 0xb409, 0xb3f7, 0xb3f5, 0xb547, 0xb545, 0xb53e, + 0xb546, 0xb529, 0xb534, 0xb53f, 0xb544, 0xb535, + /* 0x51 */ + 0xb55a, 0xb52a, 0xb533, 0xb537, 0xb543, 0xb539, 0xb530, 0xb55d, + 0xb532, 0xb527, 0xb6bd, 0xb6ba, 0xb6bc, 0xb6f1, 0xb6f0, 0xb761, + 0xb75c, 0xb758, 0xb75d, 0xb7da, 0xb7d9, 0xb7dd, 0xb7dc, 0xb7de, + 0x137d, 0xb8a0, 0xb8a2, 0xba0f, 0xba13, 0xba12, 0xba11, 0xba14, + 0xba19, 0xba0e, 0xba17, 0xba21, 0xba20, 0xba16, 0xbb78, 0x3137, + 0xbb87, 0xbb79, 0xbb80, 0xbb77, 0xbb81, 0xbb46, 0xbb7a, 0xbb9c, + 0xbb83, 0xbb84, 0xbbad, 0xbb9d, 0xbb9e, 0xbd55, 0xbe36, 0xbe2b, + 0xbe27, 0xbe46, 0xbe2c, 0xbe45, 0xbe33, 0xbe2d, 0xbe34, 0xbe22, + 0x1464, 0xbf1f, 0xc0b3, 0xc08c, 0xc08f, 0xc0af, 0xc0ad, 0xc08e, + 0xc0ac, 0xc0b0, 0xc0b1, 0xc0ae, 0xc099, 0xc1eb, 0xc274, 0xc275, + 0xc28e, 0xc26d, 0xc270, 0xc28c, 0xc34f, 0xc351, 0xc358, 0xc34c, + 0xc34e, 0xc415, 0xc4be, 0xc4db, 0xc4b3, 0xc4ae, + /* 0x52 */ + 0xc787, 0xc78a, 0xc788, 0xc78b, 0xc78c, 0xc844, 0xc82d, 0xc82a, + 0xc831, 0xc82c, 0xc845, 0xc830, 0xc829, 0xc846, 0xc9f4, 0xca14, + 0xca10, 0xca0f, 0xca12, 0xca0b, 0xca0c, 0xca0a, 0xca13, 0xca0e, + 0xcad9, 0xcad0, 0x3403, 0xcbc1, 0xcbbf, 0xcbbd, 0xcbbc, 0xcbba, + 0xcbbb, 0xcbd1, 0xcbbe, 0xcbd0, 0xcbb9, 0xcd1a, 0xcd1c, 0xcd1b, + 0xcd91, 0xcd96, 0xcd9f, 0xcd9c, 0xcd9a, 0xcd9d, 0xcead, 0xcea5, + 0xceae, 0xcf03, 0xcf26, 0xcf20, 0xcf23, 0xcf24, 0xcf21, 0xcf28, + 0xcf25, 0xcf1e, 0xcf94, 0xcf93, 0xcf8f, 0xcf9a, 0xcfad, 0x16c2, + 0xd0ca, 0xd0c5, 0xd1bb, 0xd1e1, 0xd1ea, 0xd1e4, 0xd1ed, 0xd1e6, + 0xd1e0, 0xd1e8, 0xd1e5, 0xd31a, 0xd394, 0xd396, 0xd39e, 0xd395, + 0xd3a1, 0xd38e, 0xd39b, 0xd392, 0xd397, 0xd399, 0xd393, 0xd532, + 0xd52f, 0xd52e, 0xd533, 0xd61c, 0xd61e, 0xd611, + /* 0x53 */ + 0xd620, 0xd61f, 0xd619, 0xd616, 0xd7ac, 0xd7b9, 0xd7b3, 0xd7a6, + 0xd7a2, 0xd7a9, 0xd7a7, 0xd86c, 0xd86d, 0xd869, 0xd880, 0xd866, + 0xd865, 0xd871, 0xd86b, 0xdabd, 0xdac1, 0xdad3, 0xdab6, 0x18ac, + 0xdab9, 0xdad4, 0xdab7, 0xdadb, 0xdab8, 0xdac0, 0xdabc, 0xdad5, + 0xdabf, 0xdac3, 0xdac9, 0xdd58, 0xdd90, 0xdd95, 0xdd97, 0xde09, + 0xde08, 0xde06, 0xde05, 0xde10, 0xde97, 0xde95, 0xdeee, 0xdf1f, + 0xe41a, 0x564b, 0x3c8e, 0x3ee8, 0x3ef0, 0x3ef4, 0x3f06, 0x3eed, + 0x009b, 0x3ee9, 0x3f00, 0x3fb8, 0x406d, 0x4304, 0x4301, 0x4303, + 0x4302, 0x1af6, 0x0126, 0x4462, 0x45ba, 0x4613, 0x4ade, 0x4ad7, + 0x4ae4, 0x4ace, 0x4ae3, 0x4add, 0x4b3a, 0x4adb, 0x4ad6, 0x4ae0, + 0x4ad4, 0x4acb, 0x4ae1, 0x4ac9, 0x4adf, 0x4b3c, 0x4afc, 0x4acf, + 0x4f79, 0x4f76, 0x4f78, 0x5187, 0x539c, 0x53b1, + /* 0x54 */ + 0x53c1, 0x539a, 0x5392, 0x0daf, 0x53c2, 0x5396, 0x53c0, 0x5391, + 0x5395, 0x54a2, 0x55c3, 0x55c0, 0x55c2, 0x468a, 0x56b0, 0x5716, + 0x5a46, 0x5a4a, 0x5a3e, 0x5a45, 0x5a42, 0x0415, 0x5a5b, 0x5a44, + 0x5b04, 0x7b22, 0x5c55, 0x5c57, 0x5c51, 0x5c4e, 0x5c5a, 0x5dc6, + 0x5dc3, 0x049c, 0x5dc5, 0x5dcc, 0x5e71, 0x5f26, 0x5fb2, 0x607a, + 0x6084, 0x607b, 0x6374, 0x638c, 0x6351, 0x6348, 0x638d, 0x6392, + 0x6398, 0x6393, 0x63b0, 0x634e, 0x6396, 0x6397, 0x639c, 0x63ca, + 0x6833, 0x6883, 0x6884, 0x689a, 0x688c, 0x20cc, 0x6899, 0x69e0, + 0x6ae4, 0x6af8, 0x6aed, 0x6af3, 0x6af4, 0x6af5, 0x6afd, 0x6c19, + 0x6d9e, 0x6dc4, 0x6d9f, 0x6e9b, 0x6e9f, 0x6e9a, 0x71aa, 0x719d, + 0x7192, 0x71a2, 0x71af, 0x71eb, 0x71a0, 0x71a1, 0x7194, 0x7198, + 0x718f, 0x7187, 0x7184, 0x71a9, 0x717c, 0x7418, + /* 0x55 */ + 0x755f, 0x7562, 0x7561, 0x75c0, 0x7615, 0x76fc, 0x76f9, 0x7ac8, + 0x7ac9, 0x7ade, 0x7aca, 0x7ae2, 0x0964, 0x096e, 0x7b04, 0x7acc, + 0x7add, 0x7ae4, 0x7ad3, 0x7ac7, 0x7ac6, 0x095f, 0x7b37, 0x7ed8, + 0x7eee, 0x7eb2, 0x7ea3, 0x7eb3, 0x7eed, 0x7ef8, 0x8031, 0x805b, + 0x8066, 0x8069, 0x8096, 0x809b, 0x80f7, 0x80f3, 0x80f4, 0x80f5, + 0x81e2, 0x81e7, 0x81e5, 0x81e9, 0x81e6, 0x81e3, 0x8374, 0x837f, + 0x838f, 0x8390, 0x8397, 0x83a3, 0x838e, 0x8398, 0x838c, 0x8542, + 0x8544, 0x8569, 0x8543, 0x8568, 0x0af6, 0x868d, 0x8688, 0x868b, + 0x8689, 0x87cc, 0x881f, 0x8980, 0x895e, 0x8967, 0x8968, 0x8965, + 0x254a, 0x8974, 0x8969, 0x8961, 0x8962, 0x896c, 0x8993, 0x8986, + 0x8a9d, 0x8a9b, 0x8b1b, 0x8b16, 0x8b19, 0x8b14, 0x8b18, 0x8b15, + 0x8b99, 0x8b98, 0x8d5d, 0x8d89, 0x8d7a, 0x8d7d, + /* 0x56 */ + 0x8d4b, 0x0c73, 0x8d78, 0x8d7f, 0x8d77, 0x8d7e, 0x8d79, 0x8dab, + 0x8d7c, 0x8d74, 0x8d75, 0x8da7, 0x8e8d, 0x904e, 0x9066, 0x9061, + 0x904d, 0x904f, 0x0cdd, 0x9054, 0x907c, 0x91da, 0x91de, 0x91d8, + 0x91dd, 0x91df, 0x9366, 0x9362, 0x935f, 0x9364, 0x9363, 0x9360, + 0x9388, 0x936a, 0x9367, 0x9387, 0x933f, 0x936c, 0x936e, 0x93ad, + 0x94f1, 0x94f4, 0x94f6, 0x94f5, 0x94f8, 0x94fb, 0x94ec, 0x94ef, + 0x94ed, 0x27b9, 0x94f7, 0x94f9, 0x94fd, 0x95b1, 0x9736, 0x971b, + 0x9732, 0x9742, 0x974d, 0x971f, 0x9721, 0x971c, 0x9731, 0x972e, + 0x9747, 0x973b, 0x9741, 0x9718, 0x9739, 0x971d, 0x9727, 0x9723, + 0x28d7, 0x99ee, 0x99e8, 0x99e5, 0x99ef, 0x99e4, 0x99ec, 0x99f0, + 0x9bd7, 0x9bd8, 0x9bd4, 0x9bca, 0x9bd2, 0x9bcb, 0x9bd3, 0x9be6, + 0x9be2, 0x9d49, 0x9d48, 0x9dff, 0x9e09, 0x9eb0, + /* 0x57 */ + 0x9eaf, 0x9f7c, 0x9f78, 0x9f7a, 0x9f72, 0x9f79, 0x9f7e, 0xa00c, + 0xa00b, 0xa0cd, 0xa0be, 0xa0bc, 0xa0bf, 0xa0c0, 0xa0bd, 0xa338, + 0xa308, 0xa305, 0xa33b, 0xa310, 0xa30c, 0xa30d, 0xa304, 0xa33a, + 0xa313, 0xa337, 0xa339, 0xa41f, 0xa44b, 0xa4ee, 0xa575, 0xa578, + 0xa57c, 0xa574, 0xa576, 0xa5ea, 0xa5eb, 0xa8fb, 0xa919, 0xa9a7, + 0xa98c, 0xa9dc, 0xa998, 0xa9be, 0xa99e, 0xaa0f, 0xa99f, 0xa9dd, + 0xa993, 0xa9bb, 0xa9b6, 0xa990, 0xa9a1, 0xa9bd, 0xa9de, 0xa93a, + 0xaa22, 0xa997, 0xa994, 0xa9c3, 0xa98e, 0xa9a8, 0xa999, 0xa9ad, + 0xa99b, 0xa9a2, 0xaa21, 0xa9ac, 0xaa0e, 0xaa31, 0xace1, 0xacde, + 0xacdf, 0xacdc, 0xacdd, 0xacec, 0xace7, 0xae69, 0xaeb8, 0xaea1, + 0xaea8, 0xaeba, 0xaec2, 0xaea6, 0xaea4, 0xaea3, 0xaeab, 0xaebc, + 0xaeb7, 0xaebf, 0xaead, 0xaeb1, 0xaeca, 0xaec4, + /* 0x58 */ + 0xaeb9, 0xb0c8, 0xb0c6, 0xb0c7, 0xb20a, 0xb20d, 0xb1fb, 0xb203, + 0xb202, 0xb1fc, 0xb1f9, 0xb1f8, 0xb36e, 0xb363, 0xb362, 0xb361, + 0xb36b, 0x1288, 0xb36f, 0xb366, 0xb36c, 0xb40e, 0xb415, 0xb416, + 0xb410, 0xb417, 0xb411, 0xb56e, 0xb56c, 0xb587, 0xb583, 0xb563, + 0xb5dc, 0xb6c0, 0xb6f7, 0xb6fa, 0xb770, 0xb76a, 0xb768, 0xb769, + 0xb784, 0xb7ec, 0xb7e7, 0xb7ee, 0xb8ba, 0xb8b2, 0xb8b5, 0xb8cb, + 0x430b, 0xb8d0, 0xb96d, 0xb96c, 0x13bb, 0xba45, 0xba46, 0xba34, + 0xba2c, 0xba35, 0xba44, 0x13ba, 0xba76, 0xbbb1, 0xbbaa, 0xbba1, + 0xbbb2, 0x1412, 0xbba6, 0xbbb5, 0xbbb4, 0xbbb8, 0xbbaf, 0xbbb0, + 0xbba3, 0xbd62, 0xbd64, 0xbe56, 0xbe51, 0xbe4f, 0xbe68, 0xbe4c, + 0xbe50, 0x1461, 0xbe48, 0xbe4a, 0xbf21, 0xc0e3, 0xc0b9, 0xc0de, + 0xc0b7, 0xc0e1, 0xc0b6, 0xc0b5, 0xc0df, 0x14e1, + /* 0x59 */ + 0xc297, 0xc29a, 0xc29b, 0xc298, 0xc292, 0xc293, 0xc2d7, 0xc273, + 0xc36b, 0xc374, 0xc378, 0xc36d, 0xc418, 0xc4e9, 0xc4f5, 0xc4ea, + 0xc52e, 0xc4e7, 0xc4fe, 0xc4e5, 0xc536, 0xc4f0, 0xc4e6, 0xc52c, + 0xc789, 0xc795, 0xc793, 0xc84d, 0xc84a, 0xc84f, 0xc850, 0xc84b, + 0xca2a, 0xca2b, 0xca2f, 0xca2e, 0xca7c, 0xcaed, 0xcae2, 0xcbe0, + 0xcbdc, 0xcbda, 0xcbd6, 0xcbf4, 0xcbd9, 0xcbd5, 0xcd22, 0xcd21, + 0xcd24, 0xcd25, 0xcd26, 0xcd23, 0xcdaa, 0xcdaf, 0xcdb0, 0xcdab, + 0xceaf, 0xceb7, 0xceb5, 0xceb2, 0xceb3, 0xcf2b, 0xcfd8, 0xcfc2, + 0xcfaf, 0xcfbc, 0xcfb8, 0xcfbe, 0xcfb7, 0xcfb4, 0xcfbf, 0xcfb3, + 0xcfb1, 0xcfbb, 0xcfbd, 0xcfd6, 0xcfdd, 0xd0d8, 0xd0d3, 0xd0d5, + 0xd0e3, 0xd0e2, 0xd0d9, 0xd0de, 0xd0df, 0xd0da, 0xd0d4, 0xd1f3, + 0xd1e2, 0xd20d, 0xd201, 0xd205, 0xd21a, 0xd203, + /* 0x5a */ + 0xd21f, 0xd216, 0xd1fa, 0xd1fc, 0xd20a, 0x359f, 0xd3bc, 0xd3ca, + 0xd3b6, 0xd3c7, 0xd3bf, 0x1789, 0xd3b9, 0x178c, 0xd3b0, 0xd3b8, + 0xd3bd, 0xd391, 0xd3bb, 0xd3be, 0xd53e, 0xd53d, 0xd638, 0xd63d, + 0xd639, 0xd633, 0xd733, 0xd7bb, 0xd7c6, 0xd7c5, 0xd7c7, 0xd7cb, + 0xd7a8, 0xd7c8, 0xd7be, 0xd7c1, 0xd7bd, 0xd882, 0xd89e, 0xd881, + 0xd884, 0x368d, 0xd896, 0xd88e, 0xd888, 0xd887, 0xdae0, 0xdb0d, + 0xdadf, 0xdae4, 0xdae2, 0xdadd, 0xdaec, 0xdade, 0xdae7, 0xdaea, + 0xdae3, 0xdd5c, 0x3977, 0xdd5d, 0xdd9c, 0xde1d, 0xde9d, 0xde9e, + 0xde9b, 0xdeb5, 0xdeb9, 0xdeb6, 0xdef3, 0xdef2, 0xdef4, 0xdf26, + 0xdf27, 0xdf25, 0xe006, 0xe00b, 0xe03a, 0xe03c, 0x3f0a, 0x3f0b, + 0x3fbf, 0x3ffd, 0x4118, 0xccdf, 0x8e90, 0x419e, 0x42fc, 0x4310, + 0x430f, 0x430d, 0x43b9, 0x43b7, 0x43ba, 0x440a, + /* 0x5b */ + 0x4b41, 0x4b8b, 0x4b46, 0x4b53, 0x4be2, 0x4b3f, 0x4a7c, 0x4b4b, + 0x4b4e, 0x4b8a, 0x4b47, 0x4f93, 0xb8ce, 0x4f8c, 0x4faf, 0x4fc9, + 0x50c6, 0x50c8, 0x5191, 0x53cf, 0x53d4, 0x53ce, 0x55dd, 0x55d4, + 0x5a49, 0x5a63, 0x5a5d, 0x041a, 0x5a67, 0x5abb, 0x5a60, 0x5a80, + 0x5c5f, 0x5c60, 0x5dda, 0x5dd2, 0x5ddd, 0x608e, 0x6088, 0x606c, + 0x639e, 0x63c9, 0x63a4, 0x0598, 0x63d9, 0x63d2, 0x63da, 0x63dd, + 0x63ce, 0x63fc, 0x6514, 0x6560, 0x68d7, 0x68cb, 0x68cd, 0x68d5, + 0x69e7, 0x6b00, 0x6b0a, 0x6b0f, 0x6b02, 0x6b01, 0x6c1d, 0x6dca, + 0x6dcb, 0x6dcd, 0x6e4f, 0x6e9c, 0x7180, 0x720d, 0x7202, 0x07f1, + 0x7207, 0x71f7, 0x71f8, 0x71fd, 0x7224, 0x71fb, 0x7239, 0x723a, + 0x7422, 0x21a9, 0x756a, 0x756d, 0x7574, 0x770e, 0x7adf, 0x7b2b, + 0x7ae3, 0x7b26, 0x7b2a, 0x7b23, 0x7b35, 0x7b4a, + /* 0x5c */ + 0x7efd, 0x7f00, 0x7f1e, 0x7eff, 0x809e, 0x80fa, 0x81f1, 0x8395, + 0x83a8, 0x83a6, 0x856e, 0x8583, 0x856d, 0x868f, 0x0b6a, 0x87df, + 0x87d5, 0x87e0, 0x87d3, 0x87d8, 0x898c, 0x254b, 0x8994, 0x8996, + 0x8985, 0x898f, 0x89a9, 0x898e, 0x8990, 0x89b8, 0x89c3, 0x89bb, + 0x8aa5, 0x8aa2, 0x25a2, 0x8aa3, 0x8bb5, 0x8bac, 0x8ba8, 0x8dad, + 0x8db8, 0x8db4, 0x8dae, 0x8db6, 0x1085, 0x8dc1, 0x8dbf, 0x8e92, + 0x8f00, 0x8f01, 0x9075, 0x9072, 0x9078, 0x9070, 0x907e, 0x907d, + 0x907f, 0x91ef, 0x936d, 0x938e, 0x938f, 0x938a, 0x938d, 0x9395, + 0x938b, 0x938c, 0x93b0, 0x9393, 0x94fc, 0x9515, 0x950e, 0x9518, + 0x9511, 0x950d, 0x95bb, 0x95b3, 0x0e39, 0x97a1, 0x979a, 0x9784, + 0x97a0, 0x9786, 0x979d, 0x97aa, 0x9778, 0x978d, 0x978a, 0x97a6, + 0x977a, 0x9797, 0x9788, 0x978e, 0x0e3d, 0x0e44, + /* 0x5d */ + 0x9776, 0x9781, 0x9785, 0x9775, 0x97a8, 0x978f, 0x9791, 0x97a2, + 0x979c, 0x9789, 0x977f, 0x9796, 0x9779, 0x979f, 0x97a7, 0x0e46, + 0x9787, 0x979b, 0x97a5, 0x978b, 0x97c9, 0x99ff, 0x9a03, 0x9a00, + 0x9a02, 0x9a04, 0x9a05, 0x99e6, 0x9a1f, 0x9c14, 0x0f0e, 0x9c0c, + 0x9c0f, 0x9c19, 0x9c0b, 0x9c13, 0x9bd5, 0x0f10, 0x9c1c, 0x9d50, + 0x9d4e, 0x9e12, 0x9eb9, 0x9f85, 0x9f88, 0x9f90, 0xa013, 0xa0d0, + 0xa0d1, 0xa0d2, 0xa0d7, 0xa0d6, 0xa0e5, 0xa346, 0xa36b, 0xa345, + 0xa33f, 0xa33e, 0x103e, 0xa36a, 0xa368, 0xa34c, 0xa423, 0xa422, + 0xa497, 0xa491, 0x95b5, 0xa498, 0xa49c, 0xa589, 0x1084, 0xa58b, + 0xa58a, 0xa58d, 0xa58e, 0xa588, 0xaa4e, 0xaa44, 0xaa37, 0xaa75, + 0xaa54, 0xaa76, 0xaa34, 0xaa6b, 0xaa32, 0xaa57, 0xaa52, 0xaa45, + 0x1149, 0xa9b1, 0xaa4b, 0xaa47, 0xaa33, 0xaa40, + /* 0x5e */ + 0xaa3c, 0xaa43, 0xaa4f, 0xaa55, 0xaa41, 0xaab2, 0xaac0, 0xaf34, + 0xaef9, 0xaf19, 0xaf0d, 0xaefa, 0xaf1e, 0xaf1f, 0xaf0e, 0xaf40, + 0xaf08, 0x11df, 0xaf13, 0xaf4c, 0x11f0, 0xb0cc, 0xb0cb, 0xb224, + 0xb225, 0xb23d, 0xb220, 0xb227, 0xb226, 0xb21d, 0xb21e, 0xb232, + 0xb26c, 0xb259, 0x128a, 0xb37a, 0xb379, 0xb41b, 0xb42e, 0xb423, + 0xb420, 0xb41f, 0xb5b6, 0xb5b9, 0xb5a1, 0xb5a3, 0xb5a8, 0xb5af, + 0xb59a, 0xb599, 0xb5a2, 0xb59d, 0x1302, 0xb5ab, 0xb6c9, 0xb6fe, + 0xb700, 0xb6fc, 0xb707, 0xb775, 0xb772, 0xb773, 0xb774, 0xb7fa, + 0xb7fc, 0xb7f8, 0xb7f6, 0xb7fb, 0xb8cd, 0xb8d1, 0xb8cf, 0xb974, + 0xb972, 0xb973, 0xba54, 0xba51, 0x13c0, 0xba53, 0xba49, 0xba4c, + 0xba4a, 0xba4f, 0xba56, 0xbc00, 0xbbd5, 0xbbd7, 0xbbff, 0xbbd9, + 0xbbe3, 0xbbd3, 0x1415, 0xbbd8, 0xbbd4, 0xbbde, + /* 0x5f */ + 0xbd71, 0xbe74, 0xbe88, 0xbe7f, 0xbe6b, 0xbe87, 0xbe79, 0xbe78, + 0xbe89, 0xbe80, 0xbe76, 0xbf29, 0xbf28, 0xbf2f, 0xc0e5, 0xc104, + 0xc103, 0xc0f0, 0xc0e8, 0xc0ea, 0xc0f1, 0xc101, 0xc102, 0xc2a9, + 0xc2ab, 0xc2b7, 0xc2b6, 0x14e2, 0xc3a0, 0xc38e, 0xc386, 0xc387, + 0xc385, 0xc38b, 0xc388, 0xc390, 0xc41a, 0xc434, 0xc537, 0xc52f, + 0xc530, 0xc539, 0xc534, 0xc533, 0xc585, 0xc584, 0xc53a, 0xc79f, + 0xc869, 0xc86c, 0xc86a, 0xc867, 0xc86b, 0xca3f, 0xca40, 0xcb0b, + 0xcbd2, 0xcbf8, 0xcc01, 0xcbfa, 0xcc16, 0xe3f6, 0xcd2c, 0xcd2d, + 0xcd2f, 0xcd2e, 0xcdc1, 0xcdf5, 0xcdc4, 0xcdde, 0xcdcc, 0xcdd2, + 0xcdc2, 0xcdcd, 0xcdcf, 0xcddd, 0xcdc8, 0xceba, 0xcebe, 0xcebf, + 0xcf2e, 0xcf30, 0xcfe7, 0xcfee, 0xcfe8, 0xcfe6, 0xcfe2, 0xcfe4, + 0xcffb, 0xcffc, 0xcfea, 0xd0ed, 0xd0f6, 0xd0f3, + /* 0x60 */ + 0xd0f4, 0xd0f1, 0xd0f7, 0xd0f5, 0xd0ea, 0xd0eb, 0xd200, 0xd22c, + 0xd212, 0xd23d, 0xd233, 0x174d, 0xd230, 0xd240, 0xd231, 0xd257, + 0x174a, 0xd235, 0xd232, 0xd22d, 0xd236, 0xd238, 0xd262, 0xd25f, + 0xd28a, 0xd3d6, 0xd3d8, 0xd3dd, 0xd3e4, 0xd3e3, 0xd54d, 0xd5d7, + 0xd64a, 0xd64c, 0xd650, 0xd64b, 0xd64e, 0xd64f, 0xd739, 0xd7d2, + 0xd7cd, 0xd7d3, 0xd7e1, 0xd7ce, 0xd7d5, 0xd7dd, 0xd7d4, 0xd7cf, + 0xd8cb, 0xd8a6, 0xd8c2, 0xd8a5, 0xd8a9, 0xd8a2, 0xd8a4, 0xd8b0, + 0xd8cc, 0xd8af, 0xd8bf, 0xdb24, 0xdb1a, 0xdb14, 0xdb3a, 0xdb20, + 0xdb1b, 0xdb21, 0xdb25, 0xdb1e, 0xdb3f, 0xdb40, 0xdb18, 0xdb2c, + 0xdb15, 0xdb2d, 0xdb1f, 0xdb29, 0xdb4b, 0xddb3, 0xdda5, 0xdda7, + 0xddab, 0xdda6, 0xddaa, 0xde22, 0xde23, 0xdea1, 0xdea3, 0xdea0, + 0xdebd, 0xdeba, 0xdefa, 0xdef8, 0xdefc, 0xdef6, + /* 0x61 */ + 0xdf34, 0xdf43, 0x1963, 0xdfd4, 0xe00d, 0xe043, 0xe041, 0xe03d, + 0xe040, 0xe03e, 0xe03f, 0xe046, 0x1993, 0xe0d4, 0x3f35, 0x3f36, + 0x3f32, 0x3f3a, 0x3fc8, 0x4036, 0x411e, 0x411d, 0x411f, 0x431c, + 0x431d, 0x4320, 0x010e, 0x43c0, 0x4b9a, 0x4b93, 0x4bdd, 0x020a, + 0x4ba3, 0x4ba9, 0x4b9c, 0x4b9b, 0x020d, 0x4b97, 0x4fb1, 0x4fca, + 0x4fb3, 0x4fcd, 0x53ea, 0x53ee, 0x53ef, 0x55df, 0x5650, 0x56bb, + 0x5a88, 0x5a89, 0x5a8c, 0x5a85, 0x5a5e, 0x5a94, 0x5a95, 0x5c6b, + 0x5c6a, 0x5c69, 0x5de3, 0x5df1, 0x5f37, 0x5f33, 0x6091, 0x608f, + 0x6097, 0x63d4, 0x63de, 0x63d3, 0x63e0, 0x6443, 0x640b, 0x63ff, + 0x6404, 0x6407, 0x68f9, 0x68fa, 0x68fb, 0x68f8, 0x6b12, 0x6b10, + 0x6c1f, 0x6ddf, 0x6de3, 0x6e52, 0x6ea9, 0x7265, 0x7287, 0x7242, + 0x7252, 0x724c, 0x719f, 0x7201, 0x7248, 0x724f, + /* 0x62 */ + 0x727e, 0x724d, 0x7258, 0x7247, 0x725e, 0x7249, 0x724e, 0x725d, + 0x725a, 0x7286, 0x7251, 0x7429, 0x74a6, 0x74a7, 0x7570, 0x756f, + 0x75d3, 0x75d2, 0x7728, 0x771b, 0x771a, 0x771c, 0x7721, 0x7b32, + 0x7b66, 0x7b7d, 0x7b73, 0x7b7f, 0x7b65, 0x7b80, 0x7b61, 0x7b75, + 0x7b6e, 0x7b67, 0x7b71, 0x7b6c, 0x7b63, 0x7b62, 0x7b83, 0x7bb2, + 0x7b81, 0x7b6f, 0x7b6b, 0x7b82, 0x7b8a, 0x7f29, 0x7f30, 0x7f31, + 0x8097, 0x8100, 0x80ff, 0x83b6, 0x83b5, 0x83c3, 0x858d, 0x8618, + 0x869c, 0x869a, 0x8699, 0x89b7, 0x89c4, 0x89c6, 0x89c7, 0x89bc, + 0x89c0, 0x89c5, 0x89cd, 0x89c1, 0x89be, 0x8aa7, 0x8ab8, 0x8b23, + 0x0c74, 0x8de8, 0x8dde, 0x8de3, 0x8def, 0x8ddc, 0x8de4, 0x8de1, + 0x8de5, 0x8e95, 0x8e94, 0x8e93, 0x8e8e, 0x9098, 0x909c, 0x9099, + 0x90a0, 0x909e, 0x9204, 0x93d3, 0x93b4, 0x93bb, + /* 0x63 */ + 0x93b7, 0x93b8, 0x93bd, 0x93b6, 0x93b9, 0x93b5, 0x9522, 0x9521, + 0x95c3, 0x95bc, 0x97ff, 0x97e5, 0x97f7, 0x97d2, 0x9800, 0x97db, + 0x97f0, 0x97e2, 0x97cd, 0x0e56, 0x97e1, 0x97f2, 0x97dc, 0x97cc, + 0x97d6, 0x97f3, 0x97fa, 0x97f6, 0x97ec, 0x97ea, 0x97e3, 0x97d0, + 0x0e5a, 0x9795, 0x97d5, 0x97f4, 0x97cb, 0x97da, 0x97c8, 0x97df, + 0x97f5, 0x97cf, 0x97c7, 0x97d7, 0x9a24, 0x0ea3, 0x9a1c, 0x9a21, + 0x9a1e, 0x9a18, 0x9a1b, 0x0ea8, 0x9c46, 0x9c4b, 0x9c48, 0x9c47, + 0x9c67, 0x9c54, 0x9e15, 0x9e22, 0x9ec5, 0x9e29, 0x9ec7, 0x9f8d, + 0xa01b, 0xa020, 0xa0e2, 0xa0e7, 0xa0e8, 0xa0e1, 0xa372, 0xa37b, + 0xa374, 0xa371, 0xa379, 0xa375, 0xa390, 0xa377, 0xa37d, 0xa44f, + 0xa450, 0xa4a3, 0xa4a2, 0xa4f4, 0xa594, 0xa59a, 0xa59b, 0xa5a7, + 0xa597, 0xa595, 0xa592, 0xa59c, 0xa596, 0xaab6, + /* 0x64 */ + 0xaab8, 0xaab0, 0xab18, 0xaac5, 0xaab5, 0xaac2, 0xab06, 0xab19, + 0xaab9, 0xab15, 0xaad6, 0xaaac, 0x113c, 0xaac6, 0xaab3, 0xaac3, + 0xaaca, 0xaacf, 0xaabd, 0xaace, 0xab14, 0xaaba, 0xab1a, 0xaac1, + 0xaabb, 0x119b, 0x119a, 0xad01, 0xacfc, 0xaf5a, 0xaf54, 0xaf61, + 0xaf5c, 0xaf55, 0xaf4a, 0xaf4b, 0xaf51, 0xaf69, 0xaf6b, 0x2cf1, + 0xaf66, 0xaf58, 0xaf5d, 0xaf67, 0xaf56, 0xaf88, 0xaf64, 0xaf4e, + 0xb257, 0xb25a, 0xb251, 0xb24a, 0xb24b, 0x125e, 0xb247, 0xb26f, + 0xb26a, 0xb26b, 0xb246, 0xb26d, 0xb254, 0xb26e, 0xb24c, 0xb378, + 0xb386, 0xb382, 0x12a7, 0xb5e1, 0xb5e5, 0xb5db, 0xb5de, 0xb5d7, + 0xb703, 0xb77c, 0xb77e, 0xb805, 0xb807, 0xb8e6, 0xb8e1, 0xb8fb, + 0xb8e5, 0xb8e7, 0xb8df, 0xb8ff, 0xb976, 0xba63, 0xba66, 0xba65, + 0xba5e, 0xba64, 0xba6b, 0xba5f, 0xba67, 0xba68, + /* 0x65 */ + 0xbc08, 0xbc09, 0xbc17, 0xbc15, 0xbc1b, 0xbc0b, 0xbc28, 0xbc0e, + 0xbc18, 0xbc53, 0xbc45, 0xbc0d, 0xbc0a, 0xbc13, 0xbc4a, 0xbd79, + 0xbea1, 0xbe8d, 0xbea2, 0xbe90, 0x146e, 0xbf31, 0xbf30, 0xc11f, + 0xc119, 0xc10c, 0xc11e, 0xc11d, 0xc107, 0xc266, 0xc2c5, 0xc2ba, + 0xc2bd, 0xc2c2, 0xc2c3, 0xc2bf, 0x150d, 0xc3a1, 0xc3a2, 0xc3a8, + 0xc3a3, 0xc3aa, 0xc3af, 0xc3b9, 0xc437, 0xc58f, 0x1543, 0xc58e, + 0xc587, 0xc58a, 0xc592, 0xc597, 0xc59f, 0xc605, 0xc7a9, 0xc7a7, + 0xc88a, 0xc882, 0xc885, 0xc88b, 0xc889, 0xc881, 0xc880, 0xc887, + 0xc886, 0xca4d, 0xcb1c, 0xcb1f, 0xcc21, 0xcc1d, 0xcc22, 0xcbfe, + 0xcc1b, 0xcc3a, 0xcc37, 0xcc17, 0xcc38, 0xcc26, 0xcc18, 0xcd34, + 0xcd35, 0xcd32, 0x1673, 0xcde1, 0xcdfd, 0xcde3, 0xcde8, 0xcdf9, + 0xcdff, 0xcdfe, 0x1674, 0xcde0, 0xce00, 0x1670, + /* 0x66 */ + 0xcdec, 0xcde4, 0xcdef, 0xcdfa, 0xceca, 0xcf31, 0xcf32, 0xcf34, + 0xcf41, 0xd000, 0xd006, 0xd008, 0xd005, 0xd003, 0xd00b, 0xd002, + 0xd00a, 0xd0f0, 0xd113, 0xd10a, 0xd10f, 0xd111, 0xd108, 0xd10b, + 0xd112, 0xd10d, 0xd25b, 0xd263, 0xd261, 0xd268, 0xd25a, 0xd34e, + 0xd34d, 0xd350, 0xd3fc, 0xd412, 0xd3f5, 0xd41e, 0xd3f0, 0xd3f3, + 0xd3f2, 0xd401, 0xd3ef, 0xd3ee, 0xd416, 0xd3f6, 0xd3fb, 0xd41c, + 0x17db, 0xd55d, 0xd560, 0xd566, 0xd55f, 0xd561, 0xd55b, 0xd562, + 0xd557, 0xd669, 0xd66b, 0xd661, 0xd677, 0xd65f, 0xd663, 0xd662, + 0xd665, 0xd7ef, 0xd7e2, 0xd800, 0xd7e8, 0xd7f2, 0xd7e7, 0x1829, + 0xd7e5, 0xd8d5, 0xd8d0, 0xd8da, 0xd8d3, 0x1851, 0xd8d9, 0xd8cf, + 0xd8d6, 0xd8d8, 0xd8f5, 0xd8ce, 0xd8d7, 0xd8f4, 0xd8cd, 0xd901, + 0x36ba, 0xdb52, 0xdb55, 0xdb5a, 0xdb4d, 0xdb54, + /* 0x67 */ + 0xdb53, 0xdb5e, 0xdb67, 0xdb65, 0xdb4e, 0x18db, 0xdb4f, 0xdb61, + 0xdb6e, 0xdb51, 0xdb5b, 0xdd63, 0xddb7, 0xddb6, 0xddc3, 0xddbb, + 0xddb5, 0xde2e, 0xde30, 0xde33, 0xde31, 0xdea4, 0xdec1, 0xdebb, + 0xdebe, 0xdf00, 0xdeff, 0xdf40, 0x1965, 0xdf3f, 0xdf44, 0x1964, + 0x1967, 0xdfdb, 0xe00f, 0xe011, 0xe04e, 0xe04d, 0xe04b, 0xe04c, + 0xe095, 0x3f3b, 0x3f45, 0x3f44, 0x3f3e, 0x3f3c, 0x3f3f, 0x3fcc, + 0x3fce, 0x4122, 0x4123, 0x419f, 0x43c5, 0x43c4, 0x4be9, 0x4b99, + 0x0211, 0x4be6, 0x4be7, 0x4bf7, 0x4fd2, 0x0333, 0x53fd, 0x540c, + 0x540b, 0x57ed, 0x0421, 0x0422, 0x5a9b, 0x5b0a, 0x5c6f, 0x5c75, + 0x5df2, 0x5df8, 0x5f3e, 0x6424, 0x640e, 0x6416, 0x6418, 0x6410, + 0x6431, 0x6444, 0x05a6, 0x6429, 0x642f, 0x644b, 0x6436, 0x05a3, + 0x6934, 0x6900, 0x692b, 0x6b20, 0x6b21, 0x6b1e, + /* 0x68 */ + 0x6b1d, 0x6df5, 0x6df2, 0x6df6, 0x7290, 0x729d, 0x729c, 0x7292, + 0x7294, 0x72d1, 0x7293, 0x72b7, 0x7297, 0x72b0, 0x729f, 0x72c9, + 0x742d, 0x742c, 0x7577, 0x772c, 0x7bc0, 0x7bb9, 0x7f53, 0x8040, + 0x8202, 0x81fb, 0x0aa1, 0x858b, 0x85ae, 0x85ab, 0x86a1, 0xddcd, + 0x87ea, 0x89dd, 0x89dc, 0x89d9, 0x8aab, 0x8aac, 0x8aad, 0x8ab2, + 0x8b2c, 0x8b2b, 0x8bc2, 0x8e00, 0x8e0d, 0x8e06, 0x8dff, 0x8e03, + 0x8e01, 0x8e10, 0x8e0f, 0x8e05, 0x8e98, 0x8e97, 0x8e96, 0x8e99, + 0x90ac, 0x90ab, 0x9212, 0x93d8, 0x93df, 0x93d6, 0x952d, 0x9532, + 0x983f, 0x982f, 0x9826, 0x983a, 0x9839, 0x0e5f, 0x983b, 0x9835, + 0x982a, 0x9821, 0x9838, 0x9837, 0x9834, 0x0e5c, 0x9822, 0x9836, + 0x9844, 0x9a45, 0x9a3b, 0x9a36, 0x9a42, 0x9c7a, 0x9c86, 0x9c8b, + 0x9c7f, 0x9c81, 0x9e2a, 0x9ed5, 0x9f9f, 0x9f9d, + /* 0x69 */ + 0xa026, 0xa0f4, 0xa0f5, 0xa315, 0xa38e, 0xa38f, 0xa426, 0xa4a7, + 0xa4af, 0xa5ad, 0xa5ac, 0xa5ab, 0xa5aa, 0xab2f, 0xab21, 0xab23, + 0xaba3, 0xab49, 0xab3a, 0xab48, 0xab2d, 0xab25, 0xab29, 0xab32, + 0xab34, 0xab24, 0xab2c, 0xab4b, 0xab3b, 0xab20, 0xab28, 0xaf98, + 0x11f5, 0xaf97, 0x2d04, 0xaf9d, 0xafa8, 0xb0d5, 0xb277, 0xb278, + 0xb272, 0xb273, 0xb302, 0xb43b, 0xb5fe, 0xb60b, 0xb5ff, 0xb607, + 0x1311, 0x130c, 0xb630, 0xb6cd, 0xb6cf, 0xb710, 0xb70a, 0xb783, + 0xb815, 0xb80e, 0xb80c, 0xb902, 0xb8fe, 0xb905, 0xb915, 0xb908, + 0xba7f, 0xba77, 0xba7c, 0xba82, 0xba7e, 0xba78, 0xba7d, 0xba79, + 0xba81, 0xbc4b, 0xbc63, 0xbc64, 0xbc56, 0xbc54, 0xbc4e, 0xbc10, + 0xbc4f, 0xbc57, 0xbc5e, 0xbc51, 0xbc6a, 0xbc69, 0xbead, 0xbea4, + 0xbeac, 0xbea9, 0xbeae, 0x3f4c, 0xc150, 0xc135, + /* 0x6a */ + 0xc132, 0xc2d8, 0xc2d1, 0xc2cf, 0xc2be, 0xc3d5, 0xc3c1, 0xc3c6, + 0xc3c3, 0xc3c2, 0xc3c0, 0xc3c5, 0xc3c7, 0xc3bf, 0xc3c4, 0xc3d4, + 0xc590, 0xc5d2, 0x154e, 0xc5d4, 0xc7af, 0xc7ae, 0xc7b2, 0xc7ad, + 0xc89c, 0xc8a0, 0xc8b6, 0xca3d, 0xca56, 0xca82, 0xcb28, 0xcb2b, + 0xcc3c, 0xcc3e, 0xcc3f, 0xcc42, 0xcc3d, 0xcc41, 0xcc3b, 0xcc49, + 0xcc43, 0xcd39, 0xcd38, 0xce22, 0xce08, 0xce0c, 0xce06, 0xce13, + 0xce04, 0xce20, 0xce1d, 0xce05, 0xce0a, 0xced6, 0xced7, 0xcf36, + 0xcf37, 0xd023, 0xd022, 0xd020, 0xd01a, 0xd01d, 0xd11c, 0xd120, + 0xd177, 0xd27f, 0xd28b, 0xd27d, 0xd299, 0xd284, 0xd289, 0xd285, + 0xd283, 0xd286, 0xd29e, 0xd353, 0xd417, 0x1794, 0xd419, 0xd420, + 0xd41f, 0xd423, 0xd418, 0xd421, 0xd429, 0xd424, 0xd426, 0xd55e, + 0xd56f, 0xd56e, 0xd574, 0xd572, 0xd573, 0xd67d, + /* 0x6b */ + 0xd67e, 0xd685, 0xd67f, 0xd684, 0xd744, 0xd7f5, 0xd7f8, 0xd803, + 0xd7f6, 0xd928, 0x1863, 0xd939, 0xd8fb, 0xd90e, 0xd8fd, 0xd91f, + 0x1861, 0xd903, 0x36d8, 0xd910, 0x185a, 0xd90d, 0xd927, 0xd941, + 0xdb72, 0xdb78, 0xdb80, 0x18e3, 0xdb85, 0xdb7b, 0x387c, 0xdb7d, + 0xdb91, 0xdb88, 0xdbaa, 0xdb8d, 0xdb89, 0xdb95, 0xdb9b, 0xdb8c, + 0xdb9e, 0xdb7c, 0xdb86, 0xdb84, 0xdd68, 0xddc5, 0xddc4, 0xddc9, + 0xddc6, 0xde42, 0xde45, 0xde41, 0xde44, 0xdea6, 0xdec2, 0xdf42, + 0xdf49, 0xdf48, 0xdf4a, 0xdf4c, 0xdf4b, 0xe017, 0xe018, 0xe015, + 0xe052, 0xe054, 0xe053, 0xe09a, 0xe09b, 0xe0dc, 0xe0e4, 0xe191, + 0x19af, 0xe1ba, 0x3f51, 0x3f5b, 0x3fcf, 0x6e05, 0x4c13, 0x4c15, + 0x4c14, 0x4c23, 0x0213, 0x4c11, 0x4c12, 0x0280, 0x4ff0, 0x519b, + 0x5412, 0x5416, 0x5417, 0x54b5, 0x57f4, 0x5ab1, + /* 0x6c */ + 0x5c79, 0x5dff, 0x5dfc, 0x5dfb, 0x5f3f, 0x5f44, 0x609d, 0x6432, + 0x644c, 0x642b, 0x645a, 0x651f, 0x6901, 0x692d, 0x6927, 0x6959, + 0x695a, 0x694d, 0x6958, 0x6b23, 0x6b25, 0x6b2b, 0x6dff, 0x6eae, + 0x72cb, 0x72ca, 0x72d0, 0x72ce, 0x72cc, 0x72d8, 0x72c6, 0x72d2, + 0x72cf, 0x72c8, 0x7617, 0x19b0, 0x7bc4, 0xcd40, 0x7be9, 0x7bf2, + 0x7bfc, 0x7bea, 0x7beb, 0x7bfd, 0x7f78, 0x7f77, 0x7f73, 0x7f9e, + 0x7f79, 0x80a2, 0x8103, 0x8204, 0x8205, 0x83ce, 0x85bf, 0x89f6, + 0x89f7, 0x8b31, 0x8b30, 0x8bc9, 0x8bc7, 0x8e1c, 0x8e28, 0x8e1a, + 0x8e1e, 0x8e1b, 0x8e1f, 0x90bf, 0x90bb, 0x90bc, 0x90c0, 0x921a, + 0x93ef, 0x93ec, 0x93e9, 0x93f0, 0x93fe, 0x9534, 0x986a, 0x9895, + 0x986c, 0x9872, 0x9867, 0x9860, 0x986b, 0x985e, 0x986f, 0x9866, + 0x2946, 0x9862, 0x985d, 0x985c, 0xe365, 0x9a50, + /* 0x6d */ + 0x9c9f, 0x0f23, 0x9c9e, 0x9ca6, 0x9e35, 0x9e38, 0x9e36, 0x9e3a, + 0x9edc, 0xa37c, 0xa3ab, 0x1049, 0xa3a8, 0xa3a7, 0xa42b, 0xa42c, + 0xa428, 0x442b, 0xa4a9, 0xa4aa, 0xa4ab, 0xa4f8, 0xa5b1, 0xa5f0, + 0xa5ef, 0xaba8, 0xab8b, 0xab94, 0xab9e, 0xab8f, 0xab88, 0xab7e, + 0xab81, 0xab30, 0xab9b, 0xab82, 0xab90, 0xab85, 0xab7f, 0xaba9, + 0xabde, 0xad0d, 0x11fa, 0xafcf, 0xafcb, 0xafd8, 0xafdd, 0xafd3, + 0xafd0, 0xafd5, 0xafd6, 0xb0d6, 0xb292, 0xb295, 0xe0cb, 0xb28d, + 0xb29b, 0xb29d, 0xb28f, 0xb29e, 0xb2a6, 0xb396, 0xb392, 0xb616, + 0xb62a, 0xb629, 0xb62c, 0xb715, 0xb712, 0xb711, 0xb713, 0xb788, + 0xb78b, 0xb78a, 0xb787, 0xb817, 0xb816, 0xb81a, 0xb919, 0xb917, + 0xba91, 0xba94, 0xbc8b, 0xbc90, 0xbc8f, 0xbc86, 0xbc83, 0xbc8e, + 0xbc87, 0xbca8, 0xbc85, 0xbca6, 0xbc82, 0xbca7, + /* 0x6e */ + 0xbeb9, 0xbeb7, 0xbeb4, 0xbeb6, 0xbeb3, 0xbec6, 0xc13c, 0xc140, + 0xc138, 0xc291, 0xc2a6, 0xc2da, 0xc3da, 0xc3d8, 0xc3d9, 0xc3db, + 0xc3d7, 0xc616, 0xc612, 0xc61f, 0x1559, 0xc614, 0xc61a, 0xc610, + 0xc7b3, 0xc8ae, 0xc8c1, 0xc8b0, 0xc8af, 0xc8b1, 0xc8ad, 0xc8b2, + 0xc8c4, 0xcb3c, 0xcb3f, 0xcc61, 0xcc66, 0xcd3c, 0xcd3b, 0xce2c, + 0x167e, 0xce2a, 0xce3e, 0xce2f, 0xce32, 0xce27, 0xce29, 0xce40, + 0xcedf, 0xcede, 0xcf3c, 0xcf3b, 0xcf3e, 0xd021, 0xd046, 0xd03c, + 0xd036, 0xd038, 0xd035, 0xd131, 0xd136, 0xd12d, 0xd133, 0xd12f, + 0xd12e, 0xd135, 0xd2ac, 0xd2a9, 0xd2a6, 0x17a8, 0xd44c, 0xd443, + 0xd441, 0xd44f, 0xd442, 0xd451, 0x17a9, 0xd440, 0xd450, 0xd445, + 0xd44a, 0xd44b, 0xd583, 0xd582, 0xd581, 0xd5e0, 0xd698, 0xd69f, + 0xd69b, 0xd69a, 0xd699, 0xd696, 0xd6ae, 0xd69e, + /* 0x6f */ + 0xd809, 0xd80d, 0xd94e, 0xd94a, 0xd94d, 0xd940, 0xd93e, 0xd948, + 0xd942, 0xd962, 0xd945, 0xd951, 0xdbc6, 0xdbd0, 0xdbc0, 0xdbb7, + 0xdbc2, 0xdbbc, 0xdbc5, 0xdbdc, 0xdbdb, 0xdbd2, 0xdbc7, 0xdbb6, + 0xdbc9, 0xdbcc, 0xdbd1, 0xdbcd, 0xdbda, 0xdbba, 0xdbd3, 0xdbce, + 0xdbf6, 0xdbbd, 0xdbdd, 0xdbc8, 0xdc0d, 0xdc35, 0xdd71, 0xdd6e, + 0xdd6f, 0xddd6, 0xde4c, 0xde4f, 0xde54, 0xde53, 0xdec9, 0xdec8, + 0xdf03, 0x1954, 0xdf04, 0x1956, 0xdf57, 0xdf52, 0xdf53, 0x196d, + 0xdf56, 0xdf5c, 0xdf55, 0xe064, 0xe05d, 0xe05e, 0xe0a2, 0xe0a3, + 0x198e, 0xe0e7, 0xe0e6, 0xe198, 0xe1ac, 0xe1af, 0xe1ae, 0x3f59, + 0x40a9, 0x432a, 0x43c7, 0x4c41, 0x4c37, 0x4c35, 0x4c33, 0x4c39, + 0x4c32, 0x4fff, 0x5001, 0x4ff8, 0x541b, 0x5419, 0x56bf, 0x5abc, + 0x5abe, 0x5abd, 0x5c7d, 0x5f46, 0x5f47, 0x60a4, + /* 0x70 */ + 0x6521, 0x6562, 0x6986, 0x0672, 0x6b2f, 0x6b31, 0x0814, 0x72f8, + 0x72f5, 0x72f9, 0x72f2, 0x72fa, 0x72f3, 0x7314, 0x72fd, 0x730f, + 0x730e, 0x7301, 0x7437, 0x7435, 0x7434, 0x7431, 0x757a, 0x757b, + 0x7737, 0x7c2b, 0x7bfb, 0x7c16, 0x7c13, 0x0993, 0x7c11, 0x7c0f, + 0x7c1b, 0x7c38, 0x7fa4, 0x8209, 0x8207, 0x820b, 0x83d3, 0x83d1, + 0x83d8, 0x861d, 0x86a9, 0x86d0, 0xad15, 0x8a02, 0x8a05, 0x8a01, + 0x8a00, 0x8e2e, 0x8e30, 0x8e2f, 0x8e31, 0x90d2, 0x90d3, 0x9402, + 0x9540, 0x9542, 0x953b, 0x95ce, 0x9898, 0x988f, 0x9894, 0x9891, + 0x0e6f, 0x98ba, 0x9890, 0x9886, 0x989a, 0x988c, 0x9893, 0x9887, + 0x9888, 0x9897, 0x988d, 0x989c, 0x98bd, 0x9a3c, 0x9a59, 0x0eb0, + 0x9cd1, 0x9cbb, 0x9cbe, 0x9d5d, 0x9ee2, 0xa105, 0xa3ba, 0x012e, + 0xa3f4, 0xa4b2, 0xa4f9, 0xa5b7, 0xa5b6, 0xab89, + /* 0x71 */ + 0xabf9, 0xabd9, 0xabe8, 0xabd4, 0xabdb, 0xabe2, 0xabdf, 0xabd1, + 0xabe9, 0xabea, 0xad13, 0xad11, 0xaffa, 0xaff8, 0xaff4, 0xaffb, + 0xb00e, 0xb002, 0xb00f, 0xb290, 0xb2ad, 0xb2a9, 0xb448, 0xb65a, + 0xb64f, 0xb64e, 0xb655, 0xb654, 0xb64a, 0xb6d5, 0xb718, 0xb78d, + 0xb81d, 0xb819, 0xb926, 0xb928, 0xb92b, 0xb97d, 0xbaa0, 0xba9a, + 0xba9b, 0xbcb5, 0xbcad, 0xbcb2, 0xbd94, 0xbec9, 0xc14e, 0xc14f, + 0xc144, 0xc152, 0xc3e9, 0xc439, 0x1569, 0x337e, 0xc8c7, 0xc8d3, + 0xc8c6, 0xc8c3, 0x15b4, 0xc8d2, 0xca66, 0xcc7f, 0xcc80, 0xcc84, + 0xcc85, 0xcce3, 0x164d, 0xcd41, 0xcd44, 0xcd43, 0xce4e, 0xce4f, + 0x1683, 0xce49, 0xce4a, 0xce4b, 0xce43, 0xcee0, 0xcee5, 0xcee1, + 0xcee6, 0xcee2, 0xcf0c, 0xcf40, 0xd049, 0xd04a, 0xd054, 0xd04c, + 0xd055, 0xd056, 0xd13b, 0xd13d, 0xd2a4, 0xd2a8, + /* 0x72 */ + 0xd2c3, 0xd2bf, 0xd2c8, 0xd2c2, 0xd2ca, 0xd2cc, 0xd2c9, 0xd2be, + 0xd2cd, 0xd2c7, 0xd2c5, 0xd35d, 0x17b0, 0xd46c, 0xd46b, 0xd470, + 0xd46d, 0xd46f, 0xd489, 0xd484, 0xd58d, 0xd58a, 0xd58e, 0xd591, + 0xd6b5, 0xd6b1, 0xd6af, 0xd6b9, 0xd6b7, 0xd6b0, 0x180c, 0xd717, + 0x1818, 0xd74f, 0xd819, 0xd810, 0xd818, 0xd811, 0xd81c, 0xd812, + 0xd976, 0xd971, 0x3720, 0xd97a, 0xd97f, 0x3722, 0xd973, 0xd9ab, + 0x371e, 0xd977, 0xd974, 0xd97e, 0xd99b, 0xd984, 0xd97c, 0xdc29, + 0xdc2b, 0xdc0e, 0xdc00, 0xdc0b, 0xdbfe, 0xdbfa, 0xdc17, 0xdbff, + 0xdc0c, 0xdc0f, 0x18f5, 0xdc02, 0xdc01, 0xdbfc, 0xdc49, 0xdc06, + 0xdc12, 0xdc13, 0xdd78, 0xde5b, 0xde62, 0xde5f, 0xde5d, 0xdeab, + 0xded5, 0xded4, 0xded3, 0xdf07, 0xdf6c, 0xdf70, 0xdf6e, 0xdf68, + 0xdf6d, 0xdf77, 0xdf6a, 0xdfce, 0xdfec, 0xe069, + /* 0x73 */ + 0xe068, 0xe0a6, 0xe0a9, 0xe0aa, 0xe100, 0xe10d, 0xe0f8, 0xe0fc, + 0xe10a, 0xe0f7, 0xe101, 0xe1b6, 0xe1bb, 0xe1b7, 0xe1b9, 0xe1ca, + 0x3f69, 0x4125, 0x4c59, 0x5007, 0x5009, 0x5422, 0x5607, 0x5604, + 0x6e0f, 0x57f8, 0x5ac7, 0x5ad1, 0x5c7e, 0x5e08, 0x5f4a, 0xe298, + 0x5fb9, 0x6988, 0x6991, 0x6984, 0x6973, 0x6989, 0x6985, 0x6b33, + 0x6e13, 0x731d, 0x731f, 0x731c, 0x7320, 0x731a, 0x731b, 0x7439, + 0x74af, 0x75e5, 0x773c, 0x7c37, 0x7c3a, 0x7fbb, 0x0a0e, 0x8210, + 0x820d, 0x86af, 0x8711, 0x0bd8, 0x8a0d, 0x8a0c, 0x8a0b, 0x8bd4, + 0x8e3d, 0x8e3e, 0x8e3b, 0x8e43, 0x8e40, 0x8e46, 0x8f11, 0x90dd, + 0x90df, 0x90ea, 0x924a, 0x9406, 0x98c1, 0x98b9, 0x98c6, 0x98b8, + 0x98bb, 0x98c8, 0x98c5, 0x98bf, 0x98c7, 0x98c4, 0x9a65, 0x9a67, + 0x9cd7, 0x9cdb, 0x9cd4, 0x9cd6, 0x9ee8, 0xa10a, + /* 0x74 */ + 0xa5bd, 0xa5be, 0xac1a, 0xac0d, 0xac0f, 0xac1b, 0xac10, 0xac11, + 0xac13, 0xad18, 0xb020, 0xb01f, 0xb023, 0xb01d, 0xb037, 0xb025, + 0xb024, 0xb02a, 0xb027, 0xb033, 0xb028, 0xb034, 0xb2ba, 0x2e70, + 0xb39d, 0xb44c, 0xb65c, 0xb66a, 0xb65d, 0xb665, 0xb663, 0xb65e, + 0xb719, 0xb797, 0xb93f, 0xb933, 0xb932, 0xbaa1, 0xbaa5, 0xbaa4, + 0xbaa2, 0xbcc1, 0x142c, 0xbcc7, 0xbcc4, 0xbcc6, 0xbcc5, 0xbcd4, + 0xbcca, 0xc153, 0xc3f1, 0xc421, 0x156e, 0xc6b7, 0xc692, 0xc8d4, + 0xca44, 0xcc98, 0xcc9b, 0xcc91, 0xcc95, 0xcc9a, 0xcc92, 0xce53, + 0xce57, 0x1686, 0xce5c, 0xce5d, 0xce64, 0xceea, 0xceed, 0xcf42, + 0xcf43, 0xd064, 0xd061, 0xd060, 0xd17d, 0xd2d4, 0xd2d5, 0xd2d9, + 0xd487, 0xd499, 0xd48c, 0xd48a, 0xd48f, 0x17b3, 0xd48b, 0xd482, + 0xd49b, 0x17eb, 0xd6c8, 0xd6c4, 0xd6cc, 0xd6c7, + /* 0x75 */ + 0xd6c3, 0xd6c6, 0xd6cb, 0xd6ca, 0xd6c9, 0xd6cd, 0xd753, 0xd821, + 0xd829, 0xd81d, 0xd824, 0xd828, 0x3743, 0xd9b1, 0xd9b2, 0xd9b5, + 0xd9d6, 0xd9af, 0xd9ca, 0xd9b8, 0xe412, 0xe411, 0xdc45, 0xdc47, + 0xdc34, 0xdc6e, 0xdc42, 0xdc31, 0xdc2e, 0xdc56, 0xdc38, 0xdc37, + 0xdc4b, 0xdc2d, 0xdc33, 0xdc36, 0x38e0, 0xdc48, 0xdddc, 0x1942, + 0xde66, 0xde6d, 0xde63, 0xde64, 0x1941, 0xde67, 0xded9, 0xdf0b, + 0xdf7e, 0xdf8b, 0xe026, 0xe02c, 0xe029, 0xe06f, 0xe06b, 0xe06d, + 0xe06e, 0xe11c, 0xe111, 0xe110, 0xe124, 0xe112, 0xe115, 0xe117, + 0x19ac, 0x3f6f, 0x40ab, 0x432e, 0x43c9, 0x4696, 0x4c85, 0x51a0, + 0x542b, 0x5e0d, 0x6b36, 0x3afd, 0x072f, 0x072e, 0x6eb1, 0x734a, + 0x7337, 0x733c, 0x7338, 0x733a, 0x733e, 0x7349, 0x084d, 0x087b, + 0x7580, 0x757f, 0x75e3, 0x773f, 0x7c52, 0x7c4e, + /* 0x76 */ + 0x7c4a, 0x7c4b, 0x7fd5, 0x85d8, 0x8620, 0x86b3, 0x86b1, 0x86b0, + 0x8a17, 0x8bd9, 0x8e49, 0x8f13, 0x90ed, 0x90eb, 0x90ee, 0x940a, + 0x940b, 0x954a, 0x98d5, 0x98d7, 0x98de, 0x98dc, 0x98ee, 0x9a70, + 0x0eb2, 0x9cd9, 0x9ed7, 0xa3cb, 0xa3c7, 0xa4fc, 0xac3b, 0xac39, + 0xac4b, 0xac43, 0xac40, 0xac46, 0xb04d, 0xb043, 0xb047, 0xb04b, + 0xb055, 0xb052, 0xb65f, 0x1322, 0xb67c, 0xb67b, 0xbaa8, 0xbaa9, + 0xbcde, 0xbcd7, 0xbcdd, 0xbcd6, 0xbcd8, 0xbd9b, 0xbee0, 0xbee8, + 0xbee6, 0xc3f8, 0xc3fb, 0xc6bb, 0x3259, 0xc6b8, 0x1570, 0xc7c1, + 0xc7c0, 0xcca4, 0xccab, 0xcd4d, 0xce65, 0xce67, 0xce6a, 0xce66, + 0xce69, 0xd073, 0xd080, 0xd06f, 0xd071, 0xd2e4, 0xd2e6, 0xd2e7, + 0xd4a0, 0xd4a4, 0xd5a2, 0xd5a7, 0xd5a4, 0xd6de, 0xd6db, 0xd758, + 0xd75c, 0xd82f, 0xd82e, 0xd9dd, 0xd9e4, 0xd9d8, + /* 0x77 */ + 0xd9e7, 0xd9da, 0xd975, 0x1895, 0xdc79, 0xdc80, 0xdc7f, 0xdc7c, + 0xdc75, 0xdc7b, 0xdc82, 0x1900, 0xdc89, 0xdc74, 0xdc7d, 0xdc7a, + 0xdc86, 0xdca8, 0xdc72, 0x1902, 0xdc8b, 0xdc91, 0xdcb3, 0xdc81, + 0xdd82, 0xdde1, 0xdde3, 0xdde2, 0xde76, 0xde74, 0xde72, 0xde75, + 0xdf0e, 0xdf0d, 0xdf94, 0xdf92, 0xdf93, 0xdf91, 0xdf8f, 0xdf95, + 0xdfd0, 0xdff7, 0xe076, 0xe0af, 0x199f, 0xe126, 0xe125, 0xe12d, + 0xe1a0, 0xe1c3, 0x3fd7, 0x45cc, 0x4c79, 0x4c7a, 0x5015, 0x5adb, + 0x5c85, 0x6470, 0x647b, 0x69a5, 0x699f, 0x6e17, 0x6eb2, 0x7339, + 0x7340, 0x734e, 0x743e, 0x75e8, 0x75e7, 0x7c66, 0x7c61, 0x7fda, + 0x8214, 0x83df, 0x8a18, 0x8b39, 0x8b3a, 0x9230, 0x9232, 0x940e, + 0x954c, 0x98e8, 0x98f1, 0x98eb, 0x98ec, 0x9a74, 0x9a73, 0x9cf1, + 0x9e42, 0x9e3e, 0x9e41, 0xa02c, 0xa3d2, 0xa4bb, + /* 0x78 */ + 0xac58, 0xac57, 0xac56, 0xac5a, 0x117d, 0xb061, 0xb068, 0xb065, + 0xb05f, 0xb064, 0xb05e, 0xb05b, 0xb067, 0xb2c3, 0xb3a2, 0xb453, + 0xb67d, 0xb720, 0xbaae, 0xbaaf, 0xbab0, 0xbce7, 0xbce6, 0xbce9, + 0xbef1, 0xbeeb, 0xbeea, 0xbee9, 0xc163, 0xc402, 0xc3fe, 0xc6de, + 0xc7c2, 0xc8e6, 0xca5d, 0xccad, 0xce75, 0xce72, 0xce77, 0x16f6, + 0xd151, 0xd2e8, 0xd2ed, 0xd2ee, 0xd4b9, 0xd4a1, 0xd4b6, 0xd5ae, + 0xd6e8, 0x1812, 0xd71e, 0xd831, 0xd832, 0x1891, 0xda0e, 0xda12, + 0xda09, 0xda05, 0x1890, 0xda03, 0xda1f, 0xda0d, 0xda0c, 0xda04, + 0xda0a, 0xdcc2, 0xdcbf, 0xdcc9, 0xdcb2, 0xdcc1, 0xdcaf, 0xdcb4, + 0xdcb0, 0xdcb6, 0xdcb7, 0xdcbb, 0xdcb1, 0xddf0, 0xde78, 0xde7a, + 0xde79, 0xdee4, 0xdee6, 0xdf9f, 0xdf9d, 0xdf98, 0xdf99, 0xdff9, + 0xe030, 0xe082, 0xe081, 0xe0b3, 0xe07f, 0xe13a, + /* 0x79 */ + 0xe13e, 0xe148, 0x4c86, 0x5436, 0x5613, 0x5722, 0x5add, 0x60a7, + 0x647d, 0x0679, 0x6e1c, 0x7365, 0x7360, 0x7367, 0x084e, 0x761a, + 0x85e3, 0x9234, 0x9418, 0x9552, 0x98fc, 0x9a79, 0x9a78, 0x9a76, + 0x9cfa, 0x9cf8, 0xa02d, 0xa3d6, 0xa4bd, 0xa4bf, 0xa4be, 0xac44, + 0xac70, 0xac62, 0xac6e, 0xb06e, 0xb07c, 0xb074, 0xb078, 0xb070, + 0xb079, 0xb071, 0xb2cc, 0xb3a7, 0xb3a6, 0xb693, 0xb721, 0xb79c, + 0xbd9d, 0xbef4, 0xbef3, 0xc8f0, 0xccb8, 0xccb6, 0xccbd, 0xce73, + 0xce82, 0xd087, 0xd156, 0xd159, 0xd2f6, 0xd4c9, 0xd4c5, 0xd4c7, + 0xd4ca, 0xd4c2, 0xd4c4, 0xd6f2, 0xd6f0, 0xd83b, 0xd83a, 0xda26, + 0xda28, 0xda34, 0xda2d, 0xdcd7, 0xdcd2, 0xdcd6, 0xdcdc, 0xdcd3, + 0xdcd1, 0xdd86, 0x191e, 0xddef, 0xddee, 0xdee8, 0xdfac, 0xdfa9, + 0xdfaa, 0xdfab, 0xdffb, 0xe033, 0xe088, 0xe0b6, + /* 0x7a */ + 0xe0b7, 0xe0d0, 0xe0cf, 0xe14f, 0xe159, 0xe14c, 0x5618, 0x5ae0, + 0x7369, 0x7c73, 0x7c72, 0x85e8, 0x90fb, 0x941c, 0x9909, 0x990a, + 0x9908, 0x9a7d, 0x9a7f, 0x9d67, 0xac7a, 0xac7b, 0xb2d1, 0xe3cb, + 0xb69d, 0xb79d, 0xbcfc, 0xbcfb, 0xbcfd, 0xbef5, 0xbef6, 0xc70f, + 0xc71d, 0xccc7, 0xccc1, 0xccbf, 0xcd54, 0xce7f, 0xcef5, 0xd08a, + 0xd08c, 0xd15c, 0xd365, 0xd4cf, 0xd4d0, 0xd5b8, 0xd6fa, 0xd766, + 0xda40, 0xda41, 0x3772, 0xdcf7, 0xdcf3, 0xdcef, 0xdcf4, 0xdced, + 0xdcf2, 0xdcf1, 0xdcf9, 0xdfb4, 0xdffc, 0xe0bc, 0xe15e, 0xe15b, + 0xe15f, 0xe15d, 0xe1cf, 0xe1ce, 0x543a, 0x5ae1, 0x5e15, 0x5e14, + 0x7c78, 0x7c79, 0x7fe6, 0x86b8, 0x8a22, 0x90fe, 0xa3db, 0xa506, + 0xa5c8, 0xac89, 0xb086, 0xb3ad, 0xb699, 0xb6d8, 0xb723, 0xb823, + 0xbab5, 0xbef9, 0xc407, 0xc71e, 0xc8fb, 0xca72, + /* 0x7b */ + 0xca73, 0xce87, 0xcf49, 0xd15d, 0xd2f8, 0xd703, 0xda4e, 0xda4d, + 0xda50, 0xda55, 0xdd09, 0xdd07, 0xdd0c, 0xdd03, 0xdd06, 0xdd0b, + 0xdd0a, 0xdd89, 0xdfbb, 0xdfff, 0xe036, 0xe08b, 0xe166, 0xe169, + 0xe167, 0xe1c2, 0xe1d2, 0x5ae2, 0x0428, 0x6488, 0x6e5b, 0x7376, + 0x7c7d, 0x80a6, 0x8e5a, 0x9917, 0xa3dc, 0xac8f, 0xb094, 0xb095, + 0xbab6, 0xbd04, 0xc2ee, 0xce8a, 0xcef9, 0xd707, 0xd71f, 0xd72a, + 0xd845, 0xda5c, 0xda5b, 0xda61, 0xda5d, 0xdd18, 0xdd1f, 0xde83, + 0xdf16, 0xdf14, 0xdfbf, 0xdfc0, 0xe173, 0xe1c0, 0x5017, 0x6489, + 0x941e, 0x941f, 0x9554, 0x9918, 0x9d05, 0xac95, 0xb098, 0xb09b, + 0xb459, 0xbd08, 0xbf01, 0xccce, 0xcefa, 0xd5be, 0xd847, 0xda6a, + 0xda69, 0xda68, 0xda67, 0xdd25, 0xdd28, 0xdfc4, 0xe037, 0xe08d, + 0xe08c, 0x1991, 0xe320, 0x9922, 0x9a82, 0xb2d9, + /* 0x7c */ + 0xc738, 0xcefb, 0xd4e1, 0xd772, 0xd848, 0xda6c, 0xda70, 0xdd31, + 0xdd30, 0xe179, 0x9923, 0xa3f8, 0xd774, 0xda73, 0xdd34, 0xde87, + 0xdeb2, 0xe0c2, 0xe17d, 0x5ae5, 0xce8c, 0xda77, 0xda75, 0xdd38, + 0xdd3a, 0xe183, 0xe181, 0x7c80, 0xac99, 0x1187, 0xcf4a, 0xd84a, + 0xdd3c, 0xe1c8, 0x9104, 0xb3af, 0xe189, 0xddfa, 0xd161, 0xdd3f, + 0xac93, 0xdfc9, 0xb2de, 0xce91, 0xe18e, 0xe18d, 0xac98, 0xa4c5, + 0xe1a5, +}; + +static const ucs4_t cns11643_5_2uni_upages[229] = { + 0x03400, 0x03500, 0x03600, 0x03700, 0x03800, 0x03900, 0x03a00, 0x03b00, + 0x03c00, 0x03d00, 0x03e00, 0x03f00, 0x04000, 0x04100, 0x04200, 0x04300, + 0x04400, 0x04500, 0x04600, 0x04700, 0x04800, 0x04900, 0x04a00, 0x04b00, + 0x04c00, 0x04d00, 0x05200, 0x05900, 0x05e00, 0x05f00, 0x06100, 0x06300, + 0x06400, 0x06b00, 0x07200, 0x07300, 0x07500, 0x07600, 0x07900, 0x07a00, + 0x07b00, 0x07c00, 0x08300, 0x08600, 0x08700, 0x08800, 0x08900, 0x08a00, + 0x08c00, 0x08e00, 0x09400, 0x09500, 0x09700, 0x09900, 0x09b00, 0x09c00, + 0x09d00, 0x09e00, 0x0ff00, 0x20000, 0x20100, 0x20200, 0x20300, 0x20400, + 0x20500, 0x20600, 0x20700, 0x20800, 0x20900, 0x20a00, 0x20b00, 0x20c00, + 0x20d00, 0x20e00, 0x20f00, 0x21000, 0x21100, 0x21200, 0x21300, 0x21400, + 0x21500, 0x21600, 0x21700, 0x21800, 0x21900, 0x21a00, 0x21b00, 0x21c00, + 0x21d00, 0x21e00, 0x21f00, 0x22000, 0x22100, 0x22200, 0x22300, 0x22400, + 0x22500, 0x22600, 0x22700, 0x22800, 0x22900, 0x22a00, 0x22b00, 0x22c00, + 0x22d00, 0x22e00, 0x22f00, 0x23000, 0x23100, 0x23200, 0x23300, 0x23400, + 0x23500, 0x23600, 0x23700, 0x23800, 0x23900, 0x23a00, 0x23b00, 0x23c00, + 0x23d00, 0x23e00, 0x23f00, 0x24000, 0x24100, 0x24200, 0x24300, 0x24400, + 0x24500, 0x24600, 0x24700, 0x24800, 0x24900, 0x24a00, 0x24b00, 0x24c00, + 0x24d00, 0x24e00, 0x24f00, 0x25000, 0x25100, 0x25200, 0x25300, 0x25400, + 0x25500, 0x25600, 0x25700, 0x25800, 0x25900, 0x25a00, 0x25b00, 0x25c00, + 0x25d00, 0x25e00, 0x25f00, 0x26000, 0x26100, 0x26200, 0x26300, 0x26400, + 0x26500, 0x26600, 0x26700, 0x26800, 0x26900, 0x26a00, 0x26b00, 0x26c00, + 0x26d00, 0x26e00, 0x26f00, 0x27000, 0x27100, 0x27200, 0x27300, 0x27400, + 0x27500, 0x27600, 0x27700, 0x27800, 0x27900, 0x27a00, 0x27b00, 0x27c00, + 0x27d00, 0x27e00, 0x27f00, 0x28000, 0x28100, 0x28200, 0x28300, 0x28400, + 0x28500, 0x28600, 0x28700, 0x28800, 0x28900, 0x28a00, 0x28b00, 0x28c00, + 0x28d00, 0x28e00, 0x28f00, 0x29000, 0x29100, 0x29200, 0x29300, 0x29400, + 0x29500, 0x29600, 0x29700, 0x29800, 0x29900, 0x29a00, 0x29b00, 0x29c00, + 0x29d00, 0x29e00, 0x29f00, 0x2a000, 0x2a100, 0x2a200, 0x2a300, 0x2a400, + 0x2a500, 0x2a600, 0x2f800, 0x2f900, 0x2fa00, +}; + +static int +cns11643_5_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x21 && c1 <= 0x7c)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + ucs4_t wc = 0xfffd; + unsigned short swc; + { + if (i < 8603) + swc = cns11643_5_2uni_page21[i], + wc = cns11643_5_2uni_upages[swc>>8] | (swc & 0xff); + } + if (wc != 0xfffd) { + *pwc = wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + diff --git a/graf2d/win32gdk/gdk/src/iconv/cns11643_6.h b/graf2d/win32gdk/gdk/src/iconv/cns11643_6.h new file mode 100644 index 0000000000000..8493984351325 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cns11643_6.h @@ -0,0 +1,968 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CNS 11643-1992 plane 6 + */ + +static const unsigned short cns11643_6_2uni_page21[6388] = { + /* 0x21 */ + 0xc902, 0x3362, 0x0005, 0x3388, 0x33d0, 0x33cf, 0x341e, 0x341f, + 0x3420, 0x3c0e, 0x3c2c, 0x3361, 0x3304, 0x3305, 0x3303, 0x0004, + 0xc901, 0x337d, 0x338d, 0x34a3, 0x34a4, 0x37db, 0x3800, 0xc91e, + 0x39a3, 0x3b32, 0x013f, 0x3dd4, 0x3dd5, 0x4e23, 0x552c, 0x557a, + 0x3803, 0x3307, 0x3308, 0x338f, 0x339c, 0x33d5, 0x3412, 0x3413, + 0x3414, 0x3421, 0x34a8, 0x34a6, 0x3776, 0x3801, 0x383d, 0xc914, + 0x383e, 0x3929, 0x3977, 0x3978, 0x39a6, 0x39a9, 0x39ac, 0x3b34, + 0x3804, 0x3c7b, 0x3d10, 0x392f, 0x3dd7, 0x3e1c, 0x3e1f, 0x3e1a, + 0xc936, 0x3e1e, 0x3e9e, 0x3e9a, 0x43a0, 0x43a1, 0x47d2, 0x47d3, + 0x4bb9, 0x4d1d, 0x4d55, 0x4eff, 0x51e7, 0x042a, 0x5211, 0x5213, + 0x5212, 0x53af, 0x53b1, 0xc990, 0x552d, 0x557b, 0x559d, 0x559a, + 0x04a7, 0x559f, 0x55a0, 0x559c, 0x56bd, 0x04fa, + /* 0x22 */ + 0x57aa, 0x626c, 0x6291, 0x6d74, 0x756a, 0xca29, 0x8605, 0x8f6b, + 0x8f6a, 0x33e0, 0x3312, 0x0000, 0x337f, 0x33a0, 0x3399, 0x3395, + 0x339e, 0x33df, 0x33de, 0x34af, 0x34ad, 0x34b0, 0x37df, 0x3843, + 0x3841, 0x3848, 0x3875, 0xc91a, 0x3932, 0x397b, 0x3979, 0x39b3, + 0x00db, 0x3ea7, 0x39b2, 0x39b0, 0x39b4, 0xc929, 0x3bcd, 0x3bce, + 0xc92b, 0x3c10, 0x3c80, 0x3cd3, 0x3d30, 0x3398, 0x3d2f, 0x3d31, + 0x3dda, 0x3dd9, 0x3e27, 0x3e28, 0x3e21, 0x3e25, 0x3ea6, 0x3ea2, + 0x3ea1, 0x3ea4, 0xc939, 0x3eaa, 0x3ea5, 0x3ea3, 0x3364, 0x443f, + 0x4444, 0x471b, 0x4753, 0x4784, 0x4786, 0x47d5, 0xc960, 0x4b3e, + 0x4b40, 0x4dca, 0x4dc9, 0x4e26, 0x4f00, 0x4f31, 0x4f3c, 0x4f30, + 0x4f33, 0x4f32, 0x4f38, 0x5234, 0x5253, 0x5254, 0x53b4, 0x53b2, + 0x552f, 0x55a5, 0x55a7, 0x55a4, 0x55a8, 0x55a9, + /* 0x23 */ + 0x55a2, 0x55a3, 0x55a6, 0x5681, 0x5680, 0x57ad, 0x5c24, 0x5c65, + 0x5c68, 0x5c69, 0x633c, 0x633b, 0x655d, 0x6a44, 0x7182, 0x74f1, + 0x756b, 0x771b, 0x78eb, 0x7bba, 0x7bd3, 0x7d13, 0x8922, 0x97f4, + 0xab0f, 0xab10, 0x3807, 0xc10b, 0xc10a, 0x3319, 0x331a, 0x3318, + 0x3366, 0x3382, 0x33a8, 0x33e5, 0x33e7, 0x33e4, 0x3415, 0x3423, + 0x3424, 0x3443, 0x34c3, 0x34bc, 0x34bb, 0x0038, 0x34b7, 0x34b9, + 0x34cf, 0xc90d, 0x377a, 0x377b, 0x37e1, 0x37e0, 0x3809, 0x384d, + 0xc916, 0x384b, 0x3879, 0x38b1, 0x3936, 0x3935, 0x3937, 0x3938, + 0x397f, 0x3980, 0x3981, 0x9653, 0x397e, 0x39cd, 0x39bf, 0x39be, + 0x39c2, 0x39b8, 0x39c1, 0x2030, 0x3c31, 0x3c2f, 0x3c6f, 0x3c82, + 0x013a, 0x3c87, 0x3c86, 0x3c8d, 0x3c94, 0x3cd7, 0x3cd4, 0x3cd8, + 0x3d16, 0x3d14, 0x3d2e, 0x3d36, 0x3d37, 0x51ee, + /* 0x24 */ + 0x3de0, 0x3de5, 0x3ddf, 0x3e2b, 0x3e29, 0x3e2d, 0x3e2f, 0x3eb7, + 0x3ec9, 0x3ec1, 0x3eca, 0x3eb2, 0x3eac, 0x3eae, 0x43b2, 0x43a8, + 0x43b0, 0x43a7, 0xc951, 0x4452, 0x444a, 0x4756, 0x4755, 0x475f, + 0x475e, 0x4788, 0xc95d, 0x47dd, 0x47e2, 0x47e1, 0x47df, 0x47e0, + 0x48af, 0x48b1, 0x48ba, 0x4b45, 0x4b43, 0x4bbd, 0x4bc8, 0xc96c, + 0x4bbe, 0x4bbf, 0xc974, 0x4d59, 0x4e29, 0x4e2c, 0x4e2f, 0x4e2d, + 0x4e2e, 0x4f04, 0x4f02, 0x4f01, 0x4f40, 0x4f4a, 0x4f3f, 0x4f4f, + 0x4f41, 0x4f4e, 0x51eb, 0x51ec, 0x33ac, 0x525b, 0x5263, 0x525a, + 0x5259, 0x53dc, 0x53db, 0x53d9, 0x53e0, 0x53dd, 0x3320, 0x55b0, + 0x55b1, 0x55b2, 0x55b6, 0x5651, 0x5652, 0x5650, 0x5684, 0x04c9, + 0x5683, 0x57c3, 0x57b8, 0x57b9, 0x57b2, 0x5b90, 0x5c26, 0x5c29, + 0x5c6e, 0x6340, 0x633e, 0x6341, 0x655e, 0x65bb, + /* 0x25 */ + 0x65bc, 0x65b9, 0xc9ef, 0x6980, 0x084f, 0x6a45, 0x6aba, 0x6abd, + 0x6d56, 0x6d55, 0x6d75, 0x6d77, 0x6d81, 0xc9fa, 0x6d83, 0x6d8b, + 0x6d84, 0x7186, 0x7183, 0x718b, 0x756d, 0x7616, 0x7728, 0x78ea, + 0x7bd4, 0x7c03, 0x7d15, 0x7f3d, 0x7f3e, 0x8416, 0xca4c, 0x8606, + 0x874d, 0x8f22, 0x8f73, 0x8f6d, 0x8f6e, 0x91b1, 0x384e, 0x932d, + 0x0fcd, 0x95f9, 0x9652, 0x9800, 0x97fc, 0x97fa, 0x1092, 0x97f7, + 0x97f8, 0xca90, 0xcac4, 0xa627, 0xab11, 0x33ae, 0xad50, 0xad4f, + 0xad4d, 0xaf71, 0xcae2, 0xaf72, 0xb518, 0x3d44, 0x3321, 0x3367, + 0x33af, 0x33b0, 0x3329, 0x3417, 0x3422, 0xc903, 0x3325, 0x3428, + 0x34ff, 0x34d9, 0x34db, 0x34de, 0x34f2, 0x34fe, 0x34f4, 0x34dd, + 0x0045, 0xc904, 0x3501, 0x34dc, 0x377d, 0x3781, 0x377e, 0x377f, + 0x37e5, 0x380f, 0x00b5, 0x380a, 0x00b6, 0x380b, + /* 0x26 */ + 0x3851, 0x3852, 0x3850, 0x38b8, 0x393d, 0x393e, 0x393c, 0x3987, + 0x39d7, 0x39db, 0x39cf, 0x39e0, 0x3b4c, 0x3b42, 0x3bd4, 0x3c11, + 0x3c14, 0x3c15, 0x3c12, 0x3c33, 0x3c35, 0x0137, 0x3c71, 0x0130, + 0x3c91, 0x3c93, 0x3c95, 0x3cdc, 0x3d42, 0x3d40, 0x83a6, 0x3de6, + 0x448f, 0x3e32, 0xc937, 0x3e31, 0x3ef5, 0x3ecd, 0x3ede, 0x3ed5, + 0x3eda, 0x3eee, 0x3eec, 0x3ecf, 0x3ece, 0xc93d, 0x3ecc, 0x3ef3, + 0x43c1, 0x43c4, 0x43c6, 0x43b4, 0x43c3, 0x43b8, 0x43bb, 0x43b7, + 0x43bc, 0x43bf, 0x43c7, 0x43be, 0x4460, 0x445d, 0x4476, 0x446c, + 0x4475, 0x445b, 0x4471, 0x4473, 0x4461, 0x445a, 0x4462, 0x4472, + 0x445f, 0x4458, 0x471e, 0x4758, 0x478b, 0x478a, 0x47f4, 0x47f0, + 0x48d2, 0x48cd, 0x48ce, 0x48bc, 0x48d0, 0x4b46, 0x4b47, 0x033e, + 0x034d, 0x0351, 0x4bce, 0x4bcf, 0x4bcc, 0x4bcb, + /* 0x27 */ + 0xc972, 0x4d60, 0x4d5f, 0x4d5d, 0x4dd4, 0x4e3a, 0x4e38, 0x4e3c, + 0x4e36, 0x4f08, 0x4f7e, 0x4f5e, 0x4f6e, 0x4f53, 0x4f70, 0x4f57, + 0x4f5d, 0x4f63, 0x4f7a, 0x4f79, 0x4f93, 0xc981, 0x521d, 0x5268, + 0x5273, 0x5274, 0x5266, 0x526f, 0x5275, 0x527a, 0x5270, 0x526d, + 0x5265, 0x538a, 0x53ed, 0x53e9, 0x53e3, 0x53ef, 0x0473, 0x53ea, + 0x5531, 0xc991, 0x5538, 0x9820, 0x5535, 0x553a, 0x5581, 0x5580, + 0x55b8, 0x55c1, 0x55ba, 0x5688, 0x56cf, 0x56ca, 0x56c7, 0x56c5, + 0x56c8, 0x56d0, 0x56c9, 0x57bb, 0x57b6, 0x57bd, 0xc99d, 0x57b4, + 0x57c1, 0x57d1, 0x57d2, 0x57cc, 0x57d4, 0x57cb, 0x57ce, 0x57d5, + 0x57d8, 0x5b95, 0x5b93, 0x5b99, 0x5b96, 0x05be, 0x5c89, 0x5c94, + 0x5c91, 0x5c8f, 0x5c84, 0x5c97, 0x5c86, 0x5c85, 0x5c8c, 0x60f2, + 0x60ed, 0x60ef, 0x62d9, 0x6346, 0x6347, 0x634b, + /* 0x28 */ + 0x6350, 0x634a, 0x634e, 0x634c, 0x6348, 0x6563, 0x6561, 0x6562, + 0x6560, 0x65c3, 0x65c5, 0x65c1, 0x65d0, 0xc9dc, 0x6982, 0x081e, + 0x6986, 0x6984, 0x6a4c, 0x6a48, 0x6ab8, 0x6abf, 0x6ac1, 0x6ac6, + 0x6ac5, 0x6ac7, 0x6ac0, 0x6ac3, 0x6bed, 0x6c03, 0x6c22, 0x6c21, + 0x6d9f, 0x6d90, 0x6d9e, 0x08c8, 0x6da0, 0x6d94, 0x6d95, 0x6da1, + 0x08c3, 0x08c7, 0x719a, 0x7190, 0x74f2, 0x74f3, 0x756e, 0x75ab, + 0x75a9, 0x761a, 0x7618, 0x761b, 0x7760, 0x774c, 0x7742, 0x7733, + 0x773f, 0x773e, 0x7738, 0x7743, 0x7746, 0x7736, 0x78ee, 0x78f5, + 0x78f4, 0x0b56, 0x7c1b, 0x0140, 0x7d2b, 0x7d29, 0x7d2a, 0x7d2e, + 0x803f, 0x80e6, 0x83a7, 0x83a8, 0x8418, 0x8608, 0x8750, 0x8753, + 0x8a56, 0x8a55, 0x8f6f, 0x8f7f, 0x91b3, 0x933a, 0x9338, 0x9337, + 0x9336, 0x3854, 0xca80, 0x95dd, 0x95fc, 0x95fa, + /* 0x29 */ + 0x9633, 0x9804, 0x9807, 0x9808, 0x9806, 0x9809, 0xca91, 0xca93, + 0x9d1e, 0xcad2, 0xad0b, 0xad43, 0xad52, 0xad58, 0xad5e, 0xaf68, + 0xaf8d, 0xaf82, 0xaf7b, 0xb358, 0x15bd, 0xc900, 0x332c, 0x332e, + 0x480b, 0x332d, 0x3369, 0x33b2, 0x33b6, 0x33a9, 0x33ed, 0x3419, + 0x344f, 0x3516, 0x3503, 0x350e, 0x3504, 0x3507, 0x3510, 0x3527, + 0x3528, 0x350d, 0x3529, 0x350f, 0x3522, 0x3511, 0x3785, 0x3784, + 0x3783, 0x378a, 0x3786, 0x3810, 0x3858, 0x385a, 0x3a0c, 0x38c4, + 0x38c5, 0x3947, 0x3949, 0x394a, 0x394b, 0x53bb, 0x398d, 0x398b, + 0x3a07, 0x3a06, 0xc920, 0x39ef, 0x39f0, 0x39ed, 0x39f9, 0x3a02, + 0x39e7, 0x39f4, 0x39f7, 0x39f1, 0x3b53, 0x3b55, 0x011a, 0x3bda, + 0x3bd9, 0x012c, 0x3c38, 0x3c99, 0x3ca2, 0x3c9c, 0x3c9a, 0x3c9b, + 0x3ce5, 0x3ce3, 0x3ce1, 0x3ce0, 0x3ce2, 0x3ce4, + /* 0x2a */ + 0x32fd, 0x3ce8, 0xc92f, 0x3d13, 0x3d56, 0x3d4b, 0x3d4a, 0x3d4d, + 0x3d4c, 0x0149, 0x3dea, 0x3de9, 0x3deb, 0x3dec, 0x3e3a, 0x3e3c, + 0x3e39, 0x3e3b, 0x3f14, 0x3f0e, 0x3f35, 0x3f0a, 0x3f3f, 0x3f38, + 0x017c, 0x3f4e, 0x3f17, 0xc93f, 0x3f1e, 0x43b6, 0x43ce, 0x43ca, + 0x43cb, 0x43cc, 0x43c9, 0x44b4, 0x44ac, 0x4488, 0x4486, 0x448c, + 0x4493, 0x448a, 0x44a4, 0x4487, 0x44a5, 0x44a6, 0x4485, 0x44a3, + 0x448e, 0x471f, 0x4763, 0x478d, 0x47fa, 0x47fb, 0x4809, 0x47fe, + 0x47ff, 0x4802, 0x4804, 0x47fd, 0x4805, 0x48f9, 0x48f7, 0x48db, + 0x48da, 0x4b51, 0x4b50, 0x4b57, 0x4be2, 0x4bd8, 0x4bda, 0x4bdc, + 0x4d20, 0x4d1f, 0x4d69, 0x4ddd, 0x4e40, 0x4e41, 0x4e43, 0x4f0d, + 0x4f0c, 0x4f87, 0x4fa9, 0x4f92, 0x4f85, 0x03bf, 0x4f8c, 0x4fa2, + 0x4f8f, 0x4f8a, 0x03ba, 0x4f8d, 0x51f1, 0x5237, + /* 0x2b */ + 0x528b, 0x5287, 0x5282, 0x538e, 0x53bc, 0x53f8, 0x53fa, 0x53eb, + 0x53f9, 0x53fc, 0x5405, 0x551b, 0x551d, 0x551e, 0xc992, 0x553c, + 0x553e, 0x5584, 0x55c8, 0x55c9, 0x55d3, 0x55c7, 0x55d2, 0x5655, + 0xc996, 0x568c, 0x568a, 0x56d5, 0x56d3, 0x04d8, 0x56d8, 0x57d0, + 0x57ee, 0x57f1, 0x57fb, 0x57d3, 0x57ec, 0x57cd, 0x5815, 0x5826, + 0x580e, 0x5827, 0x582a, 0x5800, 0x5804, 0x5828, 0x5808, 0x5814, + 0x5b9b, 0x05b2, 0x5ba1, 0x5b9d, 0x5ba0, 0x5b9e, 0x5ba2, 0x5b9c, + 0x5c32, 0x5c34, 0x5c93, 0x5c96, 0x5c90, 0x5cb4, 0x5cb5, 0xc9b6, + 0x5cb6, 0x5cc2, 0xc9b5, 0x5cba, 0x5c92, 0x60fb, 0x6105, 0x60f3, + 0x60fe, 0x60fd, 0x755d, 0x60fa, 0x6243, 0x6295, 0x6294, 0x06c4, + 0x636f, 0x6373, 0x635c, 0x635b, 0x6366, 0x6374, 0x6363, 0x6367, + 0x6360, 0x6362, 0x6371, 0x6372, 0x635e, 0x6523, + /* 0x2c */ + 0x6526, 0x6564, 0xc9d6, 0x65f2, 0x6601, 0x65dd, 0x65dc, 0x65db, + 0x65f3, 0x65fd, 0x65d8, 0x65f8, 0x65fb, 0x6983, 0x698c, 0x698e, + 0x6a49, 0x6a54, 0x6a52, 0x6a4e, 0x6a58, 0x6a51, 0x6a55, 0x6a53, + 0x6a57, 0x6a50, 0x6a4f, 0x6a4d, 0x6ad2, 0x6ad3, 0x6ac9, 0x6ad4, + 0x6bef, 0xc9f8, 0x33b1, 0x6c05, 0x6c04, 0x6c2e, 0x6c2d, 0x6d45, + 0x6d5b, 0x6d5a, 0x6d59, 0x6d9d, 0x6d8e, 0x6dbc, 0x6ddd, 0x6dba, + 0xc9fd, 0x6dd8, 0x6dcb, 0x6dd9, 0x6dda, 0x6dc4, 0x6db8, 0x6dbf, + 0x6ddb, 0x6dc1, 0xc9fc, 0x6dc5, 0xca19, 0x71b1, 0x71af, 0xca18, + 0x74f7, 0x74f6, 0x74f8, 0x7550, 0x7551, 0x7571, 0x7570, 0x75b0, + 0x75af, 0x75ae, 0x75ad, 0x7625, 0x762c, 0x7622, 0x7633, 0x7634, + 0x0a2b, 0x773a, 0x7740, 0x7768, 0x0a61, 0x7764, 0x775c, 0x7757, + 0x7753, 0x774f, 0x7751, 0x7754, 0x7766, 0x23dd, + /* 0x2d */ + 0x0ab2, 0x790d, 0x7908, 0xca2b, 0x78fa, 0x7aea, 0x7b2a, 0x7bbb, + 0x7bd5, 0x7bd7, 0x4fa4, 0x33f0, 0x33b5, 0x7c06, 0x7c28, 0x7c22, + 0x7c21, 0x5656, 0x7c23, 0x43cd, 0x7d30, 0x7d34, 0x7fc9, 0x7fca, + 0x7fc8, 0xca3d, 0x8044, 0x80f3, 0xca41, 0x80f8, 0x80fc, 0x80f6, + 0x80fb, 0x80f7, 0x8100, 0x8102, 0xca40, 0xca4d, 0x8424, 0x860d, + 0x0d29, 0x8762, 0x8930, 0x892b, 0x892a, 0x0d92, 0x892d, 0x8ada, + 0x8c28, 0x8d86, 0x8f77, 0x8f7c, 0x9050, 0x904e, 0x90f2, 0x91b2, + 0x91ce, 0x91cf, 0x91e5, 0x6607, 0x9235, 0x9231, 0x9313, 0x932b, + 0x932c, 0x9345, 0x9360, 0x9341, 0x9358, 0x9347, 0x935b, 0x9350, + 0xca82, 0x935f, 0x934a, 0x9356, 0x9343, 0x9344, 0x9351, 0x95fd, + 0x9634, 0x9635, 0x9654, 0x9655, 0x970c, 0x970b, 0x970a, 0x97f9, + 0x9835, 0x9824, 0x9813, 0x981c, 0x9869, 0x9825, + /* 0x2e */ + 0x9821, 0xca95, 0xca96, 0xca98, 0x9d20, 0x9fa9, 0x9fa8, 0x9fde, + 0xa009, 0xa00a, 0xa00b, 0xa1e3, 0xa207, 0xa2b2, 0xa2b3, 0xa35d, + 0xa858, 0xa886, 0xa887, 0xa9b9, 0xa9b8, 0xad0c, 0xad44, 0xad66, + 0xad80, 0xad75, 0xad6d, 0xad7e, 0xad67, 0xad81, 0xad77, 0xafa8, + 0xafa2, 0xafa5, 0xaf9b, 0xb357, 0xb50f, 0xb532, 0xb52c, 0xb533, + 0xb8e7, 0x336e, 0x33b7, 0x33f6, 0x33f2, 0x33f3, 0x3817, 0x3430, + 0x3454, 0x3453, 0x3552, 0x353d, 0x353c, 0x3534, 0x3533, 0x3554, + 0x352f, 0x0058, 0x3555, 0x353f, 0x3537, 0x3556, 0x3561, 0x3558, + 0xc906, 0x353b, 0x3532, 0x352e, 0x353e, 0x333b, 0x378c, 0x378d, + 0x3813, 0x3816, 0x3812, 0x385b, 0x388a, 0x38d7, 0x38ce, 0x3950, + 0x3951, 0x394f, 0x398e, 0x398f, 0x39f2, 0xc921, 0x3a28, 0x3a1a, + 0x3a25, 0x3a1d, 0x3a14, 0x3a20, 0x3a1f, 0x3a1b, + /* 0x2f */ + 0x3a17, 0x3a15, 0x3a1c, 0x3a13, 0xc925, 0x3b60, 0x011c, 0x3b66, + 0x3be3, 0x3bde, 0x3be0, 0x3be1, 0x3c1a, 0x3c1b, 0x3c18, 0x3c1c, + 0x3c19, 0x3c42, 0x3c40, 0x3c3e, 0x3c44, 0x3c74, 0x3c43, 0xc92d, + 0x3cf2, 0x3d1b, 0x3d19, 0x3d1e, 0xc930, 0x3d5e, 0x3d66, 0x3d5d, + 0x3d5a, 0x3d5f, 0x3d60, 0x3d5b, 0x3d5c, 0x3d59, 0x3df0, 0x3df1, + 0x3e43, 0x3e40, 0x3e42, 0x3e41, 0x3e3f, 0x3f57, 0x3f69, 0x3f6f, + 0x3fab, 0x3f71, 0x3f93, 0x3f56, 0x3f90, 0x3f6d, 0x3f6c, 0x3f70, + 0x3f66, 0x3f67, 0x43d7, 0x43b5, 0x43db, 0x43d8, 0x43d5, 0x43d4, + 0x44ba, 0x44b7, 0x44be, 0x44b9, 0x0237, 0x44e0, 0x44dd, 0x44de, + 0x7918, 0x44d8, 0x44bd, 0x44db, 0x471d, 0x4725, 0x4921, 0x490c, + 0x4929, 0x492d, 0x491b, 0x490e, 0x491f, 0x4904, 0x491c, 0x4905, + 0x4906, 0x4920, 0x490d, 0x492a, 0x4923, 0x4911, + /* 0x30 */ + 0x4b5c, 0x4b66, 0x4b5b, 0x4b4f, 0x4b5e, 0x4b5d, 0x4bf1, 0x4bea, + 0x4bf4, 0x4beb, 0x4bf0, 0x4bfa, 0x4bfb, 0x4d28, 0x4d2c, 0x4d6b, + 0x4d2a, 0x4d6a, 0x4d6f, 0x4ddb, 0x4de0, 0x7fd1, 0x4de3, 0x4de5, + 0x4de7, 0x4e4d, 0x4e55, 0x4e54, 0x4e53, 0x4e52, 0x4e4e, 0x4e60, + 0x53c0, 0x4f0f, 0x4f11, 0x4f13, 0x4fc6, 0x4fb3, 0x4fc7, 0x4fd2, + 0x4fb8, 0x4fac, 0x4fae, 0x4fcf, 0x4fc5, 0xc97b, 0x4fcc, 0x4fab, + 0x4fc9, 0x4fb9, 0x51fb, 0x51f8, 0x51f7, 0x51f9, 0x5220, 0x523b, + 0x5239, 0x529e, 0x529a, 0x52aa, 0x52ab, 0x52af, 0x5296, 0x52a9, + 0x52a6, 0x5291, 0x0443, 0x52ae, 0x529f, 0x52ac, 0x52a0, 0x5392, + 0x5391, 0x53bf, 0x5417, 0x540a, 0x540c, 0x554a, 0x5546, 0x5534, + 0x5545, 0x5543, 0x5544, 0xc993, 0x5587, 0x5586, 0x558a, 0x55da, + 0x55d8, 0x04b4, 0x3818, 0x3434, 0x55d6, 0x55d4, + /* 0x31 */ + 0x5654, 0x5659, 0x565a, 0x5657, 0x04e0, 0x56dd, 0x56e9, 0x56e0, + 0x5805, 0x5812, 0x5813, 0x5807, 0x5816, 0x5823, 0x5802, 0xc9a1, + 0x584a, 0x5836, 0x5840, 0x5856, 0x5843, 0xc9a0, 0x584b, 0x5846, + 0x583e, 0x5849, 0x5ba7, 0x5bb6, 0x5ba6, 0x5ba8, 0x5bac, 0x5ba9, + 0x5bab, 0x5c38, 0x5c37, 0x5c39, 0x5c41, 0x5c3e, 0x5cc0, 0x5cbb, + 0x5cbf, 0x5cbd, 0x5cfe, 0x5d1e, 0x5cee, 0x5cfc, 0xc9b7, 0x5cf9, + 0x5d06, 0x5ce4, 0x5ce9, 0x5ce5, 0x5d03, 0x5cfd, 0x5d49, 0x60be, + 0x610a, 0x8626, 0x6118, 0x610d, 0x610f, 0x610e, 0x6120, 0x6271, + 0x6299, 0x62e2, 0x62df, 0x62de, 0x6378, 0x6379, 0x06e4, 0x637c, + 0x637d, 0x6384, 0x638b, 0x638a, 0xc9d2, 0x6389, 0x652c, 0x6529, + 0x656c, 0x2104, 0x6609, 0x6608, 0x660c, 0x660d, 0x6610, 0x0826, + 0x699f, 0x6998, 0x69a2, 0x699a, 0x6ad5, 0x6ae2, + /* 0x32 */ + 0x6af0, 0x6aea, 0x6aeb, 0x6aed, 0x6ae8, 0x6ae0, 0x6b85, 0x6b86, + 0x6bf0, 0x5046, 0x6c45, 0x6c38, 0x6c3e, 0x6c42, 0x6c40, 0x6d47, + 0x6d5c, 0x6d5e, 0x6db4, 0x6dc2, 0x6e14, 0x6de5, 0x6e15, 0x6e11, + 0xc9ff, 0x6dee, 0x6de7, 0x6df5, 0x6df4, 0x6de8, 0x6e01, 0x6def, + 0x6df1, 0xca00, 0x71db, 0x71bf, 0x71da, 0x71c7, 0x71dd, 0xca1a, + 0x71eb, 0x71e1, 0x71c1, 0x71bd, 0x7507, 0x74fd, 0x7501, 0x750a, + 0x7503, 0x7572, 0x7574, 0x7575, 0x75b2, 0x75b1, 0x75b4, 0x764c, + 0x7642, 0x7640, 0x7649, 0x763c, 0x764d, 0x764a, 0x763b, 0x7761, + 0x7774, 0xca26, 0x777f, 0x777a, 0x7788, 0x777c, 0x0a6f, 0x7770, + 0x790f, 0x7928, 0x7913, 0x792a, 0x7aed, 0x7aef, 0x7b2e, 0x7bc1, + 0x7bdd, 0x3e47, 0x7c2d, 0x7c2b, 0x7c35, 0x7c2f, 0x7c31, 0x7c34, + 0xca35, 0x7c30, 0x7d3a, 0x7d39, 0x7d37, 0x7d4b, + /* 0x33 */ + 0x7d54, 0x7d4d, 0x7d51, 0x7d47, 0x7f27, 0x7f50, 0x7f4d, 0x7f4e, + 0x7f54, 0x7fd2, 0x7fce, 0x804b, 0x8049, 0x8105, 0x810f, 0x8119, + 0xca43, 0x8106, 0x810c, 0x8129, 0x8104, 0x8108, 0x8125, 0x0c1c, + 0x8103, 0x8127, 0x8110, 0x810a, 0xca42, 0x985d, 0x83aa, 0x83ab, + 0x83a9, 0x8441, 0x843a, 0x843c, 0x842b, 0x8449, 0x8615, 0x0d00, + 0x8616, 0xca53, 0x8631, 0x6d4a, 0x873c, 0x877c, 0x876d, 0x876a, + 0x8763, 0x876b, 0x877b, 0x8764, 0x877a, 0x8769, 0x876f, 0x8937, + 0x8935, 0x893c, 0x8936, 0x893d, 0x893e, 0x8ae1, 0x8ae0, 0x8c2d, + 0x8c2b, 0x8d8d, 0x8d92, 0x0eb6, 0x8d8e, 0xca6b, 0x8d91, 0x8d96, + 0x8f7b, 0x8f78, 0x8f81, 0x8f96, 0x8fa3, 0x8f95, 0x8f97, 0x9054, + 0x9052, 0x90f5, 0x9100, 0x90fb, 0x90f4, 0x90f6, 0x91e8, 0x91ea, + 0x933e, 0x933d, 0x933b, 0x9380, 0x0fe4, 0x9388, + /* 0x34 */ + 0x9381, 0x9382, 0x93ce, 0x9383, 0x9377, 0x9379, 0x9373, 0x936d, + 0x9370, 0x938d, 0x9375, 0x938c, 0x936a, 0x9391, 0x9389, 0x938e, + 0x44dc, 0x95ff, 0x9659, 0x96c7, 0x9712, 0x9714, 0x9713, 0x97cb, + 0x9842, 0x10ad, 0x983d, 0x2aff, 0x9840, 0x9844, 0x9862, 0x9843, + 0x983f, 0x9845, 0x983c, 0xca97, 0x9846, 0x9847, 0xcab3, 0x9c9e, + 0x9c9d, 0x9d2c, 0x9d29, 0x9d2f, 0x9d2e, 0x9d30, 0x9fe1, 0x9fe2, + 0xa00e, 0xa019, 0xa012, 0xa2b4, 0xa5da, 0xa726, 0xa859, 0xa85a, + 0xa888, 0xa9c0, 0xa9ba, 0xaba0, 0xcadd, 0xaba2, 0xad86, 0x2fec, + 0xad9d, 0xad88, 0xad8f, 0xad8e, 0xad9b, 0xafc1, 0xafc3, 0xafc4, + 0xaf96, 0xafc7, 0xafc6, 0xafbf, 0x14c3, 0xb20f, 0xb555, 0xb542, + 0xb546, 0xb54b, 0xb543, 0xb553, 0xb548, 0xb549, 0xb54a, 0xb54e, + 0x7bde, 0x3991, 0xbb4b, 0xbd80, 0xbd81, 0xbd83, + /* 0x35 */ + 0x358a, 0xbd82, 0x5542, 0x3c22, 0x3370, 0x3371, 0x33bc, 0x4f18, + 0x33be, 0x33ba, 0x33f8, 0x3437, 0x3435, 0x3dfc, 0x3456, 0x3459, + 0x345e, 0x356d, 0x3591, 0x3592, 0x3568, 0x3566, 0x3573, 0x0067, + 0x3596, 0x358b, 0x358c, 0x3796, 0x37ee, 0x381c, 0x381a, 0x3819, + 0x381b, 0x385d, 0x385e, 0xc918, 0x38dc, 0x38e2, 0x3952, 0x3992, + 0x3a30, 0x3a52, 0x3a42, 0x3a41, 0x3a45, 0x3a37, 0x3a40, 0x3a3f, + 0x3a3d, 0x3a38, 0x3a3a, 0x3a49, 0x3b6b, 0x3b78, 0x3b79, 0xc926, + 0x3b6c, 0x3be9, 0x3be6, 0x3be5, 0x3bea, 0x3be7, 0x3be8, 0x3c1f, + 0x3c4b, 0x3c4a, 0x3c53, 0x3c76, 0x3ca3, 0x3ca4, 0x3cf6, 0x3cf3, + 0x3cf9, 0x3cf7, 0x3cfc, 0x3d1d, 0x3d6d, 0x3d71, 0x3d6c, 0x3d6e, + 0x3d70, 0x3d6f, 0x3d67, 0x3d68, 0x3dfa, 0x3df9, 0x3e4e, 0x19de, + 0x3e4d, 0x3e4f, 0x3e4a, 0x3e4c, 0x0196, 0xc942, + /* 0x36 */ + 0x3fee, 0x3fb2, 0x3fc0, 0x3fc1, 0x3ff4, 0x3fc8, 0x3fc5, 0x3fc6, + 0x3fad, 0x43e2, 0x43ea, 0x43e3, 0x43e1, 0x44f7, 0x4501, 0x4512, + 0x44f6, 0x44f1, 0x451f, 0x44ee, 0xc952, 0x44f3, 0x4515, 0x4516, + 0x4517, 0x44f8, 0x4519, 0x44f2, 0x44f4, 0x44f5, 0x4513, 0x4506, + 0x4726, 0x4724, 0x475a, 0x60c8, 0x4797, 0x4795, 0x479a, 0x481f, + 0x3dfb, 0x4829, 0x4820, 0xc962, 0xc963, 0x494c, 0x4930, 0x4938, + 0x493d, 0x4951, 0x494f, 0x494a, 0x4934, 0x4936, 0x1b30, 0x4b6a, + 0x4b68, 0x4c1c, 0x4c0e, 0x4c1e, 0x0359, 0x4c09, 0x4c08, 0x4c13, + 0x4c01, 0x4c0f, 0x4c14, 0x4c06, 0x4c07, 0x1cb2, 0xc973, 0x0376, + 0x4d79, 0x4dea, 0x4ded, 0x4de9, 0x4dee, 0x4e68, 0x4e64, 0x4e67, + 0x4e72, 0x4e62, 0x4e74, 0x4e79, 0x4f19, 0x4f17, 0x4f15, 0x4f16, + 0x4fe6, 0x8fa4, 0x4fee, 0x03d2, 0x4fdf, 0x4fe4, + /* 0x37 */ + 0x4fda, 0x4fea, 0x4fed, 0x4fe3, 0x4fe9, 0x51fd, 0x3957, 0x5221, + 0x52c6, 0x52b8, 0x52cb, 0xc985, 0x52bd, 0x52b5, 0x52bb, 0x52bf, + 0x52be, 0x52b2, 0x52c1, 0x52c2, 0x5399, 0x53c6, 0x542c, 0x542d, + 0x5425, 0x541e, 0x541f, 0x5423, 0x5550, 0x554e, 0x554d, 0x5552, + 0x55e9, 0x55ec, 0x55e8, 0x5658, 0x565c, 0x565b, 0x568f, 0x6a72, + 0x56f6, 0x5700, 0x56fc, 0x56f8, 0x56ea, 0x56fe, 0x56f7, 0x56fd, + 0x5870, 0x5862, 0x5844, 0x0520, 0x584d, 0x584c, 0x583f, 0x5866, + 0x5835, 0x0529, 0x5834, 0x588d, 0x5884, 0x0538, 0x5886, 0x5889, + 0x5887, 0x5883, 0x5875, 0x5879, 0x58af, 0x58b0, 0x5bb7, 0x5bbb, + 0x5bb9, 0x5c46, 0x5c47, 0x5c45, 0x5cea, 0x5cf6, 0x5d68, 0x5d39, + 0xc9b9, 0x5d3d, 0x5d3b, 0x5d4d, 0x5d30, 0x5d4a, 0x5d3e, 0x5d40, + 0x5d4c, 0x5d47, 0x5d38, 0x5d52, 0x5d3a, 0x5d53, + /* 0x38 */ + 0x60c4, 0x60c1, 0x611c, 0x611d, 0x612a, 0x611e, 0x612f, 0x6122, + 0x612e, 0x6125, 0x0689, 0x06b0, 0x624a, 0x624b, 0x6276, 0x06bf, + 0x62e8, 0x62ef, 0x62e9, 0x06c5, 0x62ea, 0xc9cc, 0x06ea, 0x639b, + 0x639e, 0x6393, 0x63a7, 0x639c, 0x63a0, 0x639a, 0x63ab, 0x63be, + 0x63a9, 0x652d, 0x656e, 0x6644, 0x663d, 0x663a, 0x6668, 0x663c, + 0x666a, 0xc9e0, 0x6638, 0x6665, 0x6639, 0x666d, 0x6636, 0xc9e3, + 0x663e, 0x667e, 0x6637, 0x6999, 0x69a9, 0x69ad, 0x69a7, 0x69a8, + 0x6a66, 0x6a69, 0x6a6d, 0x6a67, 0x6a6b, 0x6a6a, 0x6aee, 0x6b01, + 0x6b03, 0x6af4, 0x6afb, 0x0837, 0x6af6, 0x6afc, 0x6bf4, 0x6c08, + 0x6c0a, 0x6c09, 0x6c6d, 0x6c62, 0x6c41, 0x6c5e, 0x6c5c, 0x6df3, + 0x6e26, 0x08e4, 0x6e39, 0xca04, 0x6e6c, 0x6e2b, 0x6e2e, 0x6e3b, + 0x6e5e, 0x6efb, 0x6e27, 0x6e24, 0x6e69, 0x6e30, + /* 0x39 */ + 0xca05, 0x6e62, 0x6e38, 0x6e35, 0x6e2a, 0x6e2c, 0x6e68, 0x6e31, + 0x6e2f, 0x6e2d, 0x6e3a, 0x6e36, 0xca03, 0x6e21, 0x6e3c, 0x6e20, + 0x6e64, 0x6e3e, 0x08e8, 0x71f7, 0x7212, 0x71f1, 0x71f5, 0x7222, + 0x71f2, 0x71df, 0x7215, 0x7216, 0x757a, 0x7576, 0x75be, 0x0a20, + 0x75bd, 0x7609, 0x7608, 0x7657, 0x77a3, 0x77bf, 0x77b8, 0x77af, + 0x779c, 0x77a5, 0x7772, 0x7775, 0x779d, 0x7799, 0x77b9, 0x794e, + 0x7939, 0x793b, 0x7935, 0x793c, 0x7955, 0x7af0, 0x7af3, 0x7af4, + 0x7b3b, 0x7b3c, 0x7b3a, 0x7b36, 0x7c07, 0x3feb, 0x7c55, 0x7c50, + 0x7c4f, 0x7c52, 0x7c56, 0x33bd, 0x7c32, 0x7d63, 0x7d6b, 0x7d66, + 0x7d57, 0x7d5d, 0x0b86, 0x7d6d, 0x7d61, 0x7d69, 0x7d5a, 0x7d5c, + 0x7d62, 0x7f2a, 0x7f29, 0x7f58, 0x7f5a, 0x7fd7, 0x7fdb, 0x7fdc, + 0x7fdd, 0x7fd8, 0x8054, 0x805b, 0x805c, 0x8053, + /* 0x3a */ + 0x804f, 0x8056, 0x8050, 0x805a, 0x806b, 0x8136, 0x8153, 0x813a, + 0x813c, 0x813e, 0x8149, 0x8140, 0xca46, 0xca47, 0x8364, 0x8365, + 0x83b5, 0x83b6, 0x83b2, 0x8448, 0x844a, 0x8472, 0x8469, 0x845a, + 0x844c, 0x862c, 0x8630, 0x864b, 0x8649, 0x8642, 0x8644, 0x864a, + 0x864f, 0x8792, 0xca57, 0x8797, 0x8780, 0x8782, 0x8786, 0x8953, + 0x895e, 0x8952, 0x895b, 0x894e, 0x8a6d, 0x8a6e, 0x8afa, 0x8af6, + 0x8afb, 0x8c33, 0x8c3d, 0x8c37, 0x8c3e, 0x8c35, 0x8d9a, 0x8dab, + 0x8da6, 0x8db0, 0x8d99, 0x8da0, 0x8d9e, 0x8da8, 0x8da1, 0x8daa, + 0x8dad, 0x8dbb, 0x8d9c, 0x8da5, 0x33b3, 0x8f27, 0x8f8d, 0x8f8e, + 0x8f8f, 0x8f92, 0x0f56, 0x8f91, 0x8fad, 0x9057, 0x9058, 0x905e, + 0x905d, 0x905c, 0x905b, 0x0f67, 0x910a, 0x9103, 0x910e, 0x91b8, + 0x924d, 0x923f, 0x9247, 0x924b, 0x924a, 0x923d, + /* 0x3b */ + 0x2838, 0x9241, 0x924c, 0x2881, 0x9362, 0x9369, 0x9361, 0x0fd1, + 0x93aa, 0x93a6, 0x93ac, 0x93bd, 0x93bb, 0x93a4, 0x93ba, 0x939a, + 0x0feb, 0x93a1, 0x93c1, 0x95e0, 0x960a, 0x9603, 0x9606, 0x9639, + 0x963a, 0x9636, 0x965b, 0x965f, 0x965e, 0x9667, 0x9661, 0x9662, + 0x965d, 0x96ca, 0x96cc, 0x96ce, 0x9718, 0x971d, 0x971f, 0x9720, + 0x9717, 0x9715, 0x981f, 0x9827, 0x9826, 0x5010, 0x988b, 0x98ae, + 0x988a, 0xca99, 0x9892, 0x9889, 0x9887, 0x10b6, 0x988f, 0x9884, + 0x9883, 0x988c, 0x9893, 0x988d, 0x9898, 0x987d, 0x987e, 0x98d2, + 0x9880, 0x9899, 0x9cac, 0x9d50, 0x9d55, 0x9d42, 0x9d3f, 0x9d3c, + 0x11a3, 0x9d4c, 0x9d49, 0x9d57, 0x9d58, 0x9d4f, 0x9d5c, 0x9d47, + 0xcab7, 0x9fab, 0x1210, 0x9faf, 0x9fad, 0x9fe8, 0x9fe7, 0xa030, + 0xa026, 0xa02f, 0xa028, 0xa02b, 0xa01d, 0xa02d, + /* 0x3c */ + 0xa020, 0xa02a, 0xa02c, 0xa035, 0xa021, 0xa023, 0xa024, 0xa036, + 0xa037, 0xa1e9, 0xa2ba, 0xa2b8, 0xcacc, 0xa36d, 0xa36a, 0xa368, + 0xa369, 0xa36b, 0xa361, 0xa5dc, 0xa5db, 0xa62d, 0xa62c, 0xa6a2, + 0xa72b, 0xa732, 0xcad7, 0xa894, 0xa892, 0xa890, 0xa9c9, 0xa9c4, + 0xa9c1, 0xa9c3, 0xa9cd, 0xab14, 0xaba7, 0xabaf, 0xabaa, 0xad0d, + 0xad54, 0xad5b, 0xad61, 0xadae, 0xadb3, 0xadc0, 0xadc4, 0xadbf, + 0xadcb, 0xadad, 0xada7, 0xada4, 0xadbd, 0xadaf, 0xadb2, 0xada5, + 0xafe7, 0xafe0, 0xafce, 0xafde, 0xafd5, 0xafdf, 0xafd9, 0xb0f2, + 0xb223, 0xb240, 0x151b, 0xb23e, 0x1587, 0xb3cf, 0x3e54, 0xb55b, + 0xb558, 0xb562, 0xb55f, 0xb567, 0xb563, 0xb55e, 0xb560, 0xb685, + 0xb686, 0xb687, 0xb8e8, 0xb8e6, 0xbd71, 0xbd85, 0xcb02, 0xbd86, + 0xbe10, 0x3cf8, 0x33bf, 0x3e61, 0x33fe, 0x33fc, + /* 0x3d */ + 0x3439, 0x3461, 0x3460, 0x35e2, 0x35ea, 0x35e3, 0x35b4, 0x35ae, + 0x35be, 0x35b8, 0x35a8, 0x35aa, 0x35a9, 0x35b3, 0x35d5, 0x35ad, + 0x35b9, 0x35bb, 0x35b1, 0x35c2, 0xc908, 0x35eb, 0x35ba, 0x35d2, + 0x35d4, 0x37f1, 0x381d, 0xc912, 0x3862, 0x388c, 0x38e6, 0x38e7, + 0x395a, 0x3958, 0x3959, 0x3996, 0x3997, 0x3a61, 0x3a67, 0x3a71, + 0x3a65, 0x3a7d, 0x3a7e, 0x3b7d, 0x3b84, 0x3b7c, 0x3b7e, 0x3b7f, + 0x3b80, 0x3bef, 0x3bf4, 0x3c1e, 0x3c4e, 0x3cfb, 0x3cfa, 0x3cfd, + 0xc931, 0xc932, 0x3d79, 0x3d7c, 0x3d7d, 0x3d84, 0x3d7b, 0x3d78, + 0x0157, 0x3e5e, 0x3e5a, 0x3e5c, 0x3e59, 0x3e55, 0x3e63, 0x3e56, + 0x3e5f, 0x3e60, 0x3e5b, 0x404a, 0x4065, 0x40b3, 0x402c, 0x4077, + 0x403d, 0x4052, 0x4061, 0x402a, 0x403e, 0x4034, 0x4029, 0x40b2, + 0x40ad, 0x4040, 0x4053, 0xc944, 0x403f, 0x4041, + /* 0x3e */ + 0x4072, 0x43f6, 0x43f5, 0x43f4, 0x43f2, 0x43f9, 0x4527, 0x4554, + 0x4555, 0x452e, 0xc954, 0xc953, 0x452c, 0x4538, 0x4539, 0x4531, + 0x454f, 0x4573, 0x4530, 0x452b, 0x4551, 0x472c, 0x475b, 0x475c, + 0x4768, 0x476c, 0x476b, 0x4769, 0x479f, 0x4838, 0x483c, 0x483a, + 0x4835, 0x029d, 0x4839, 0x4836, 0x483b, 0x4960, 0x4961, 0x4963, + 0x4964, 0x4994, 0x4993, 0x495e, 0x4968, 0x496a, 0x4965, 0xc966, + 0x4990, 0x495f, 0x4972, 0xc965, 0x4c3c, 0x4c27, 0x4c24, 0x4c26, + 0x4c25, 0x035f, 0x4c28, 0x4c36, 0x4d31, 0x4d30, 0x4d34, 0x4d81, + 0x4d7d, 0x4d82, 0x4d80, 0x0379, 0x35d3, 0x4df2, 0x4e66, 0x4e8c, + 0x4e7b, 0x4e83, 0x0398, 0x4e8e, 0x4e7a, 0x4e92, 0x4e91, 0x4e82, + 0x4f1b, 0x4f1c, 0x5027, 0x5021, 0x03dc, 0x1d2b, 0x5043, 0x03df, + 0x5018, 0x507b, 0x501a, 0x504b, 0x504a, 0x504d, + /* 0x3f */ + 0x504f, 0x5019, 0x5035, 0x5013, 0x5052, 0x5014, 0x501e, 0x502c, + 0x5020, 0x5022, 0x5012, 0x501f, 0x5200, 0x5223, 0x5240, 0x5243, + 0x52e4, 0x52db, 0x52ea, 0x52dd, 0x52cc, 0x52d9, 0x52e8, 0x52f6, + 0x52e3, 0x52d3, 0x52da, 0x52d6, 0x52e7, 0x543a, 0x543f, 0x5440, + 0x5448, 0x5459, 0x5437, 0x5444, 0xc98c, 0xc98b, 0x5455, 0x5439, + 0x5554, 0x5555, 0x5556, 0x5557, 0x5558, 0x5559, 0x558d, 0x55f2, + 0x55f8, 0x55f5, 0x55f6, 0x55fc, 0x55fe, 0x55f1, 0x55fd, 0x565e, + 0x5696, 0x5697, 0x569c, 0x569b, 0x5695, 0xc99a, 0x571a, 0x5709, + 0x5704, 0x570e, 0x571c, 0x5718, 0x570d, 0x5710, 0x570c, 0x5703, + 0x587b, 0x58a6, 0x5877, 0x5888, 0x5874, 0x58da, 0x5876, 0x5878, + 0x588a, 0x588f, 0x587d, 0x5890, 0x58ed, 0x58d9, 0x58d0, 0x591a, + 0x58d7, 0x58e2, 0x58e1, 0x58c5, 0x58e0, 0x58ca, + /* 0x40 */ + 0x5925, 0x58cc, 0xc9b3, 0x5bc6, 0x5bc1, 0x5c4d, 0x5d4b, 0x5d64, + 0x5d95, 0x5d99, 0xc9bc, 0x5d94, 0x5da2, 0x5dae, 0x5d9e, 0x5da7, + 0x5d86, 0x05fd, 0x5da4, 0x5d91, 0x5d93, 0xc9bb, 0x5d88, 0x60cd, + 0x60ca, 0x613f, 0x6140, 0x6146, 0x6141, 0x6145, 0x6158, 0x613b, + 0x6148, 0x624e, 0x6252, 0x624f, 0x627b, 0x627a, 0x62a0, 0x629f, + 0x62fb, 0x62f7, 0x63b8, 0x63b9, 0x63bb, 0x63b7, 0x06f4, 0x63ba, + 0x06ef, 0x63da, 0x63b5, 0x63bf, 0x63bc, 0x63c0, 0xc9d3, 0xc9d9, + 0x6575, 0x6579, 0x6576, 0x6635, 0x6640, 0x66c0, 0x6681, 0x66ad, + 0x66af, 0x66ac, 0x668f, 0x66a8, 0x66aa, 0x66a9, 0x6688, 0x667f, + 0x6680, 0x66bc, 0x69ae, 0x69bb, 0x69bd, 0x0831, 0x6a78, 0x6a74, + 0x6b0c, 0x6b11, 0x6b08, 0x6b06, 0x6b10, 0x6b8f, 0x6b90, 0x6b8d, + 0x6b8e, 0x6b96, 0x6b95, 0x6c0b, 0x6c0c, 0x6c7c, + /* 0x41 */ + 0x6c73, 0x6c75, 0x6c76, 0x6c7d, 0x6c78, 0x6c71, 0x6d4b, 0x6d4e, + 0x6e33, 0x6e32, 0x0903, 0x6e91, 0x6ee7, 0x6ee9, 0x6ea2, 0x6e94, + 0x6e87, 0x6ea3, 0x6edd, 0x6e7b, 0x6e83, 0x6e81, 0x6edf, 0x6e7c, + 0x6ee4, 0x6ee2, 0x6e93, 0x6e7d, 0x6ebf, 0x6e9b, 0x6e8e, 0x6e9f, + 0x0909, 0x6e8c, 0x6e7f, 0x6e9c, 0x6e84, 0x6e42, 0x6ee6, 0x7251, + 0x724a, 0x7264, 0x7225, 0x722f, 0x722e, 0x722b, 0x7228, 0x7232, + 0x722d, 0x7231, 0x7239, 0x722c, 0x7261, 0x7511, 0x7510, 0x7512, + 0x7553, 0x7555, 0x757b, 0x7581, 0x757d, 0x757c, 0x75c2, 0x75c5, + 0xca22, 0x75c4, 0xca23, 0x766b, 0x7668, 0x0a3e, 0x765c, 0x765d, + 0x766a, 0xca24, 0x7c76, 0x7776, 0x0a77, 0x77c4, 0x77cb, 0x77c8, + 0x77d4, 0x77d5, 0x77c9, 0x77d7, 0x0a7b, 0x7978, 0x795a, 0x795b, + 0x795c, 0x7956, 0x7958, 0x7971, 0x96d4, 0x7b40, + /* 0x42 */ + 0xca33, 0x7b3f, 0x7b43, 0x7b41, 0x7be2, 0x7be0, 0x7be3, 0x7c66, + 0x7c73, 0x7c6c, 0x7c71, 0x7c6a, 0x7c6d, 0x7c6e, 0x7c6b, 0x7d8c, + 0x7d77, 0xca3a, 0x7d7f, 0x7d89, 0x7d7a, 0x7d85, 0x7d78, 0x7d8a, + 0x7d86, 0x7f2c, 0x7f67, 0x7f5b, 0x7fe5, 0x7fe1, 0x8061, 0x8069, + 0x806a, 0x8165, 0x816d, 0x8163, 0x8186, 0x815c, 0x8162, 0xca48, + 0x8179, 0x8169, 0x8170, 0x8176, 0x815d, 0x8187, 0x816e, 0x8171, + 0x817c, 0x8173, 0x815b, 0x816b, 0x83bf, 0x83c1, 0x83bd, 0x83c9, + 0x83bc, 0x83c2, 0x83c0, 0x8492, 0x84a9, 0x848f, 0x8476, 0x847b, + 0x8475, 0x84a4, 0x8664, 0x873d, 0x87af, 0x0d3a, 0xca58, 0x879d, + 0x8799, 0x87b1, 0x8963, 0x8962, 0x8964, 0x8969, 0x0da0, 0x8a75, + 0x8a73, 0x8a71, 0x8a74, 0x8b0c, 0x8b16, 0x0de5, 0x8b11, 0x8b1f, + 0x8b1a, 0x8b0d, 0x8b1b, 0x8b13, 0x8c4e, 0x8c55, + /* 0x43 */ + 0x8c50, 0x0e7d, 0x8dd2, 0x8dd3, 0x8dd1, 0x8df1, 0x8ddc, 0x8dc8, + 0x8dcc, 0x8dd0, 0x8dcf, 0x8ddf, 0x8f2b, 0x8f2e, 0x8f2d, 0x8f9d, + 0x8f9e, 0x8f9f, 0x8fa9, 0x8fa0, 0x8f98, 0x8fa1, 0x8fab, 0x8faf, + 0x906e, 0x905f, 0x905a, 0x0f6d, 0x9065, 0x9068, 0x9072, 0x9117, + 0x9116, 0x9118, 0x9119, 0x911a, 0x9122, 0x911b, 0x911c, 0x91be, + 0x91ee, 0x925a, 0x9250, 0x9258, 0x9254, 0x9257, 0x9256, 0x9315, + 0x939b, 0x9393, 0x9392, 0x9372, 0x9398, 0x9399, 0x93df, 0x0ff8, + 0x93d5, 0x2958, 0x93d4, 0x93f3, 0x93f4, 0x93e7, 0x93e1, 0x93e6, + 0x93eb, 0x93ec, 0x35db, 0x1050, 0x960d, 0x960c, 0x4d2f, 0x9668, + 0x9665, 0x966b, 0x9669, 0x96d1, 0x96d3, 0x9727, 0x9728, 0x1068, + 0x1067, 0x9724, 0x97d7, 0x98ca, 0x98c7, 0xca9e, 0x98d8, 0x98e1, + 0x98c6, 0x98f8, 0x98c3, 0x98f4, 0x9917, 0x98ea, + /* 0x44 */ + 0x98cb, 0x9886, 0x98c4, 0x98d9, 0x9919, 0x98c2, 0x98e2, 0x10cf, + 0x98de, 0x98ed, 0xca9c, 0x10cd, 0x991d, 0x98dd, 0x98db, 0x98e8, + 0x98e9, 0x98bf, 0x98e0, 0x98d1, 0x98dc, 0x98ce, 0x991e, 0x98cc, + 0x98f2, 0x98f3, 0xca9f, 0xcaa2, 0xcaa3, 0xcaa1, 0x9cab, 0x9caa, + 0x9ca7, 0x9ca9, 0x9d88, 0x9d75, 0x9d60, 0x9d6c, 0x9d73, 0x11ab, + 0x9d6e, 0x9d74, 0x9d76, 0x9d68, 0x9d77, 0x9d86, 0x9fea, 0xa051, + 0xa050, 0xa058, 0xa04d, 0xa04f, 0xa04e, 0xa05c, 0xa052, 0xa044, + 0xa04a, 0xa04b, 0xa1ea, 0xa210, 0xa211, 0xa2cd, 0xa2bf, 0xa2c4, + 0xa2d0, 0xa2ce, 0xa2c0, 0xa2c2, 0xa2cf, 0xa2c9, 0xa2bb, 0xa397, + 0xa392, 0xa36f, 0xa37e, 0xa39a, 0x12c1, 0xa386, 0xa373, 0x2d24, + 0xa377, 0xa38f, 0xa370, 0xa381, 0xa382, 0xa399, 0xa37d, 0xa37f, + 0xa37b, 0xa387, 0xa5b2, 0xa62f, 0xa634, 0xa62e, + /* 0x45 */ + 0xa632, 0x1347, 0xa6aa, 0x1357, 0xa6a9, 0xa738, 0xa736, 0xa737, + 0xa747, 0xa733, 0xa739, 0xa735, 0xa744, 0xa8a5, 0xa8a6, 0xa89e, + 0xa9e3, 0xa9df, 0xa9d3, 0xa9f1, 0xa9e4, 0xa9e0, 0xa9d6, 0x2ec3, + 0xa9e6, 0xa9d8, 0xa9de, 0xa9db, 0xa9dc, 0xab1b, 0xab1f, 0xab1d, + 0xab1c, 0xab1e, 0xab20, 0xab21, 0x144e, 0xabb6, 0xabbc, 0xabc6, + 0xabc7, 0xabba, 0xabbe, 0xabbd, 0xabb5, 0xabb4, 0xad0f, 0xad62, + 0xadeb, 0xadd9, 0xade4, 0xadd7, 0xadd8, 0xadd6, 0xadce, 0xaddd, + 0xade7, 0xadd2, 0xadc5, 0xadc9, 0xaddb, 0xaf92, 0xaf8a, 0xaf8b, + 0xaf89, 0xb008, 0xb003, 0xb006, 0xb005, 0xaff5, 0xb00b, 0xaffb, + 0xb0fc, 0xb101, 0xb102, 0xb0fa, 0xb108, 0xb0f7, 0xb100, 0xb0ff, + 0xb106, 0xb0f6, 0xb0fb, 0xb10a, 0xb225, 0xb243, 0xb244, 0xb364, + 0xb362, 0xb35e, 0xb35b, 0xb3d6, 0x3372, 0x33c2, + /* 0x46 */ + 0xb577, 0xb582, 0xb57c, 0xb57d, 0xb586, 0xb581, 0xb584, 0xb576, + 0xb583, 0xb57f, 0xb57e, 0xb688, 0xb68d, 0xb68b, 0xb691, 0xb68f, + 0xb77c, 0xb779, 0xb77a, 0xb8ea, 0xbb4c, 0xbc99, 0x35d1, 0xbd8b, + 0xbd8d, 0xbd8a, 0xbd8e, 0xbe11, 0x5456, 0xcb15, 0x3374, 0x33c3, + 0x33c4, 0x341b, 0x345f, 0x346a, 0x3469, 0x346b, 0x360c, 0x35f6, + 0x35ed, 0x3629, 0x35fe, 0x35f1, 0x3617, 0x35ff, 0x35ee, 0x35fd, + 0x361c, 0x35fc, 0x3600, 0x3620, 0x0077, 0x35f9, 0x3667, 0x3608, + 0x379e, 0x37f3, 0x3825, 0x3827, 0x381f, 0x3865, 0x3863, 0x3894, + 0x3897, 0x38f1, 0x395f, 0x3962, 0x18f2, 0x3960, 0xc922, 0x3a8c, + 0x3a82, 0x3a90, 0x3a8b, 0x3a8d, 0x3a81, 0x3a9d, 0x3b8e, 0x3b8f, + 0x3b92, 0x3c23, 0x3c52, 0xc92e, 0x3d00, 0x3d01, 0x3d02, 0x3d1f, + 0x3d8c, 0x3d89, 0x3d8b, 0x3d88, 0x3d8d, 0x3d8f, + /* 0x47 */ + 0x9085, 0x3e00, 0x3e05, 0x3e01, 0x3e68, 0x3e6e, 0x3e67, 0x3e75, + 0x1ab6, 0xc945, 0x40d7, 0xc946, 0x3348, 0x40d4, 0x40d8, 0xc947, + 0xc948, 0x40ba, 0xc949, 0x40db, 0x40bf, 0x4135, 0x40bc, 0x40d9, + 0x01c4, 0x40dd, 0x4100, 0x40d5, 0x4130, 0x40bd, 0x40dc, 0x43fd, + 0x43fe, 0x4407, 0x7517, 0x456f, 0x4569, 0x4570, 0x4567, 0x45a9, + 0x4595, 0x4590, 0x456c, 0x4597, 0x4571, 0x0252, 0x4574, 0x456d, + 0x458e, 0x472f, 0xc61b, 0x47a9, 0x484e, 0xc95f, 0x485a, 0x4848, + 0x4855, 0x484c, 0x4849, 0x484f, 0x484a, 0x49d6, 0x49a0, 0x49a9, + 0xc967, 0x499d, 0x49d4, 0x49a4, 0x49a8, 0x49a6, 0x49e6, 0x4b7d, + 0x4b77, 0x4b7a, 0x4c41, 0x4c49, 0x4c59, 0x4c45, 0x4c48, 0x4c40, + 0x4d8e, 0x4d95, 0x4d90, 0x4df7, 0x4df8, 0x4df6, 0x4dfb, 0x4e9e, + 0x4e9d, 0x4e99, 0xc977, 0x4ea3, 0x4ea9, 0x4e98, + /* 0x48 */ + 0x4ea0, 0x4e96, 0x4e94, 0x4e95, 0x4e9f, 0x4ea1, 0x4f21, 0x4f1d, + 0x4f1f, 0x506d, 0xc97c, 0x509a, 0x5092, 0x507a, 0x507d, 0x50a1, + 0x509d, 0x5099, 0x506b, 0x506e, 0xc97d, 0x5245, 0xc984, 0x52fb, + 0x52eb, 0x52f2, 0x52f9, 0xc986, 0x52f8, 0x52ed, 0x5301, 0x52f7, + 0x5306, 0x539b, 0x53ca, 0x046b, 0x1ec3, 0x546b, 0x546c, 0x5474, + 0x5467, 0x545b, 0x5460, 0x5476, 0x5463, 0x5461, 0x5528, 0x555b, + 0x555e, 0x5560, 0x555d, 0x555c, 0x55f4, 0x5600, 0x5608, 0x5607, + 0x5601, 0x5605, 0x5664, 0x5663, 0x569e, 0x56a0, 0x56a1, 0x569f, + 0x5726, 0x572d, 0x5728, 0x571d, 0x58ec, 0x58e3, 0x58eb, 0x5916, + 0x58c8, 0x931b, 0x58e9, 0x58e4, 0x5924, 0x58d1, 0x0541, 0x58dd, + 0x58c2, 0x58cb, 0x58c7, 0x58e7, 0x0550, 0x58ea, 0x594b, 0xc9a5, + 0x5960, 0x597d, 0x593e, 0xc9a4, 0x5952, 0x594e, + /* 0x49 */ + 0x593c, 0x5932, 0x5930, 0x5923, 0x5bca, 0x5bcb, 0x5bc9, 0x5bc8, + 0x5bcd, 0x5d98, 0x5da0, 0x5d9f, 0x5d9c, 0x5da3, 0x5d97, 0xc9be, + 0x5df1, 0x5e09, 0x5e03, 0x5dea, 0x5e45, 0x5ded, 0x5e05, 0x5e1a, + 0x5e15, 0x5e01, 0x5dec, 0x5e0e, 0x5e17, 0x5e42, 0x5e12, 0x5e10, + 0x5def, 0x5dff, 0x5e00, 0x5e0c, 0x5e0f, 0x5e04, 0x5e08, 0x5e14, + 0x5e43, 0xc9bd, 0x5e1b, 0x5e11, 0x5e13, 0x60cf, 0x60ce, 0x616f, + 0x616e, 0x617a, 0x6170, 0x6164, 0x615e, 0x616c, 0xc9c9, 0x615b, + 0x6161, 0x6165, 0x627f, 0x6280, 0x627c, 0x62a7, 0x62a6, 0x62a1, + 0x06c0, 0x62a8, 0x62a3, 0x62a2, 0x62ad, 0x62a5, 0x6301, 0x62ff, + 0x62fc, 0x6300, 0x6335, 0x63ee, 0x63ef, 0x63f6, 0x63e8, 0x63ea, + 0x63e3, 0x641f, 0x06fc, 0x63e4, 0x63fa, 0x63f1, 0x63fb, 0xc9d4, + 0x653d, 0x653c, 0x0079, 0x6578, 0x6577, 0x100b, + /* 0x4a */ + 0x66d1, 0x66c7, 0x66df, 0x66d0, 0x66e0, 0x66d6, 0x66d8, 0x6716, + 0x670e, 0x66d9, 0x670f, 0x6711, 0x66cd, 0x6689, 0x66ce, 0x6714, + 0x66da, 0x6712, 0x66d3, 0x66c2, 0x66e1, 0x66e9, 0x66ea, 0x66de, + 0x6715, 0x69d9, 0x69d6, 0x69cd, 0x69d0, 0x69d3, 0xc9f0, 0x6a82, + 0x6a85, 0x6a7f, 0x6a7d, 0x6a81, 0x6a83, 0x6a84, 0xada0, 0x6b28, + 0x6b0f, 0x6b17, 0x6b1a, 0x6b25, 0xc9f7, 0x6b9b, 0x6b99, 0x6c92, + 0x6c8c, 0x6c95, 0x6c8d, 0x6ca3, 0x6c93, 0x6c91, 0x6edb, 0x6e99, + 0x6e9a, 0x6f08, 0x6f4c, 0x6f0d, 0x6f01, 0x6f4e, 0x6f02, 0x6f4d, + 0x6f21, 0x6efc, 0xca09, 0x6e8a, 0xca08, 0x6e95, 0x6f11, 0x6f12, + 0x6f46, 0x6f1c, 0x6f49, 0x6f0c, 0x091e, 0x6f13, 0x6f16, 0x6efd, + 0x6f0f, 0x6f1f, 0x7230, 0x726e, 0x726b, 0x729b, 0x727b, 0x7263, + 0x7297, 0x726d, 0x729c, 0x7298, 0x726f, 0x7267, + /* 0x4b */ + 0x7269, 0x7515, 0x7563, 0x7586, 0x758a, 0x7587, 0x7588, 0x7585, + 0x7589, 0x75ca, 0x75c7, 0x75cb, 0x75cc, 0x75c9, 0x760d, 0x7683, + 0x7684, 0x7678, 0x7682, 0x7673, 0x7679, 0x768c, 0x77d0, 0x77cf, + 0x77d2, 0x77d9, 0x77cc, 0x77eb, 0x77fd, 0x77ec, 0x77e8, 0x77f8, + 0x77fa, 0xca27, 0x0a85, 0x77e1, 0x77fb, 0x78e7, 0xca2e, 0x79a5, + 0x7991, 0x79a6, 0x797c, 0x7992, 0x79a2, 0x79a0, 0x7afc, 0x7afe, + 0x7b57, 0x7b53, 0x7b58, 0x7be7, 0x7c8e, 0xca38, 0x7c83, 0x7c8b, + 0x7c84, 0x0b97, 0x7da2, 0x7db7, 0x7da9, 0x7da5, 0x7d9f, 0x7daa, + 0x7d97, 0x7da1, 0x7d9e, 0x7dab, 0x7d99, 0x7da3, 0x7f30, 0x7f32, + 0x7f2f, 0x7f70, 0x7f6c, 0x7f6f, 0x7fe8, 0x7fee, 0x7fea, 0x806d, + 0x8076, 0x8070, 0x8071, 0x806c, 0x81eb, 0x81b5, 0x8196, 0x8190, + 0x818d, 0xca49, 0x81a2, 0x81b0, 0x8192, 0x81a0, + /* 0x4c */ + 0x8193, 0x81c3, 0x818e, 0x81b6, 0x819d, 0x8195, 0x81b3, 0x81a4, + 0x8370, 0x83d4, 0x0c93, 0x83cf, 0x3470, 0x8494, 0x2561, 0x84c0, + 0x84b4, 0x84c1, 0x0cb2, 0x84bd, 0x84af, 0x8677, 0x8678, 0x866b, + 0x866d, 0x866e, 0x8672, 0x866f, 0x8671, 0x62ab, 0x868c, 0x873f, + 0x87b6, 0x87b7, 0x2606, 0x87bb, 0x87b8, 0x3a9c, 0x87b9, 0x2601, + 0x898b, 0x897a, 0x8984, 0x8988, 0x8991, 0x8979, 0x898e, 0x8980, + 0x8982, 0x897c, 0x0da4, 0x8a84, 0x8a7f, 0x0df2, 0x8b3b, 0x8b71, + 0x8b3d, 0x8b30, 0x0df1, 0x8b3e, 0x8b38, 0x8c5e, 0x8c64, 0x0e81, + 0x8c5d, 0x8c6d, 0x8c4f, 0x8c62, 0x8c5f, 0x8dec, 0x8df2, 0x8df4, + 0x8df7, 0x8df6, 0x8e07, 0x8ded, 0x8dea, 0x8df0, 0x8df8, 0x8df3, + 0x0edc, 0xca72, 0x8f31, 0x8f2f, 0x8fb6, 0x8fae, 0x8faa, 0x8fbf, + 0x8fcc, 0x8fc7, 0x9983, 0x9080, 0x907b, 0x907f, + /* 0x4d */ + 0x907d, 0x9083, 0xca78, 0x9146, 0x912d, 0x9125, 0x9126, 0x912c, + 0x9137, 0x9131, 0x9133, 0x9132, 0x9127, 0x912a, 0x912e, 0x912f, + 0x91c0, 0x9271, 0x9261, 0x9262, 0x9266, 0x9318, 0x93c5, 0x93c3, + 0x93c4, 0x93c2, 0x93ae, 0x9410, 0x9408, 0x941f, 0x943a, 0x943b, + 0x9436, 0x940c, 0x9406, 0x942a, 0x9457, 0x9450, 0x9420, 0xca85, + 0x942c, 0x9421, 0x940b, 0x9419, 0x9435, 0x9418, 0x940f, 0x9413, + 0x9455, 0x9439, 0x941a, 0x100c, 0x9417, 0x95e4, 0x95e9, 0x758b, + 0x9610, 0x9612, 0x963f, 0x966e, 0x7518, 0xca8c, 0x96d6, 0x96d5, + 0x96d7, 0x3e02, 0x106d, 0x9731, 0x9730, 0x973a, 0x9885, 0x986b, + 0x9948, 0x994b, 0x9937, 0x997b, 0x996c, 0x9985, 0x9965, 0x9936, + 0x9986, 0x9934, 0x9968, 0x995a, 0x9958, 0x9972, 0x996a, 0x98d3, + 0x993c, 0x9933, 0x993b, 0x994d, 0x994f, 0x997c, + /* 0x4e */ + 0x99b0, 0x995b, 0x9955, 0x9964, 0x996b, 0x9953, 0x10e6, 0x9957, + 0x995e, 0x996d, 0x9935, 0x9969, 0x9959, 0x9966, 0x9950, 0x9951, + 0x995c, 0x9a5d, 0x9987, 0x9978, 0x9949, 0x994e, 0x98f1, 0x9973, + 0x9988, 0x98cf, 0xcaa4, 0x9cb1, 0x9cb3, 0x9d9c, 0x9da4, 0x9d90, + 0x9db8, 0x9da0, 0x9d9d, 0x9da8, 0x9da9, 0xcab9, 0x9db1, 0x9d93, + 0x9d9b, 0x9da2, 0x9da1, 0x9db0, 0x9da7, 0x9fb3, 0x2b49, 0x9fb4, + 0x9ff1, 0x9fed, 0x9fec, 0xa068, 0xa075, 0xa06a, 0xa062, 0xa067, + 0xa060, 0xa077, 0xa05f, 0xa079, 0xa223, 0xa221, 0xa21c, 0x2c99, + 0xa21f, 0xa21e, 0xa2d6, 0xa2d3, 0xa2d9, 0xa2d7, 0xa2d4, 0xa2dc, + 0xa2d8, 0xa3a3, 0x12d1, 0xa3be, 0xa3a9, 0xa3a1, 0xa3a0, 0xa3ab, + 0xa3a2, 0xa3ba, 0xa3c2, 0xa39c, 0xa3bb, 0xa3aa, 0xa3ac, 0xa3a5, + 0xa3c1, 0x132c, 0xa5e2, 0xa636, 0xa63d, 0xa63a, + /* 0x4f */ + 0x5661, 0xa648, 0xa63c, 0xa6b7, 0xa6ac, 0xa6b3, 0xa6b6, 0xa6b2, + 0x136e, 0xa75d, 0xa749, 0xa74e, 0xa74f, 0xa74d, 0xa75c, 0xa85d, + 0xa8bb, 0xa8ce, 0xa8bf, 0xa8ba, 0xa8c3, 0x13e5, 0xaa06, 0xa9f8, + 0xa9fe, 0xaa13, 0xa9f6, 0x13e6, 0xab34, 0xab2d, 0xab2a, 0xab35, + 0xab2c, 0xabd4, 0xabda, 0xabd3, 0xabd2, 0xabce, 0xabcf, 0x149f, + 0xadfd, 0xae0b, 0xadfe, 0xadf8, 0xadf7, 0xae17, 0xadfa, 0xadf9, + 0xae00, 0xadf5, 0xadf1, 0xae03, 0xae05, 0xae1c, 0xafac, 0xaf9a, + 0xafad, 0xafa0, 0xb01b, 0xb025, 0xb024, 0xb026, 0xb027, 0xb028, + 0xb02a, 0xb01a, 0xb02e, 0xb015, 0xb115, 0xb114, 0xb117, 0xb118, + 0xb10f, 0xb113, 0xb10b, 0xb122, 0x457a, 0xb226, 0x301f, 0xb251, + 0xb24d, 0xb24e, 0xb24a, 0xb24b, 0xb24c, 0xb250, 0xb262, 0xb24f, + 0xb252, 0xb368, 0xb369, 0xb3e5, 0xb3f0, 0xb3e1, + /* 0x50 */ + 0xb3e2, 0xcaf2, 0xb5a5, 0xb5a9, 0xb5a4, 0xb5af, 0xb5ac, 0xb5ae, + 0xb5aa, 0xb695, 0xb699, 0xb693, 0xb69d, 0xb698, 0xb69c, 0xb697, + 0x160d, 0xb789, 0xb787, 0xb8d7, 0xb8ed, 0xb8f1, 0xb8f0, 0xb905, + 0xb903, 0xb904, 0xb95f, 0xbb57, 0xbc9c, 0xbca1, 0xbc9a, 0xbd8f, + 0xbd93, 0xbd9e, 0xbda3, 0xbd98, 0xbd99, 0xbd95, 0xbe6e, 0xbe6a, + 0xbff4, 0xbff7, 0xc179, 0xc38f, 0xc391, 0xc40b, 0xc802, 0x3384, + 0x3404, 0x3480, 0x362f, 0x363f, 0x363b, 0x3662, 0x3644, 0x3633, + 0x365f, 0x362b, 0xc909, 0x3639, 0x3636, 0x3648, 0x3635, 0x366c, + 0x3658, 0x363a, 0x37a8, 0x37f4, 0x3829, 0x389a, 0x3900, 0x3abb, + 0x3abd, 0x3ab7, 0x3ab2, 0x00f8, 0x3aa8, 0x3aab, 0x3aa6, 0x3abc, + 0x3b97, 0x3b96, 0x3bf8, 0x1913, 0x3c51, 0x0133, 0x3cb5, 0x3cb4, + 0x3cb6, 0x013c, 0x3cb7, 0x3d05, 0x3d23, 0x3d95, + /* 0x51 */ + 0x3d98, 0x014f, 0x3d94, 0x3d93, 0x3e07, 0x3e73, 0x3e71, 0x3e72, + 0x3e78, 0x415f, 0x416a, 0x4167, 0x416b, 0x4169, 0x418e, 0x4149, + 0x4180, 0x01dc, 0x4144, 0x418f, 0x4145, 0xc94c, 0x414f, 0x4163, + 0x4136, 0x4148, 0x415c, 0x4193, 0x4161, 0x4160, 0x414e, 0x415e, + 0x413f, 0x41a4, 0x1ae0, 0x4168, 0x440b, 0x4411, 0x440d, 0x440e, + 0x45c2, 0xc957, 0x45b0, 0x45c3, 0x45c8, 0x4565, 0x45d7, 0x45bd, + 0x45b8, 0x45b6, 0x45c7, 0x45bc, 0x45b1, 0x45af, 0xc95b, 0x4735, + 0x4730, 0x475d, 0x3e76, 0x476f, 0x47b0, 0xc95e, 0x47b4, 0x485c, + 0x485d, 0x4a08, 0x49ee, 0x4a0b, 0x49f2, 0x49fd, 0x49f1, 0x4a10, + 0xc968, 0x4a14, 0x4b8b, 0x4b8c, 0x4b85, 0x4c7a, 0x4c6c, 0x4c60, + 0x4c67, 0x4c66, 0x4c6a, 0x4c5f, 0x4c6d, 0x4c68, 0x4c64, 0x4d3a, + 0x4d3b, 0x4d39, 0x4e02, 0x4e04, 0x4e03, 0x4eb4, + /* 0x52 */ + 0x4eb3, 0x4ebb, 0x4eac, 0x4eb6, 0x4eb1, 0x4eaf, 0x4eb5, 0x4ebe, + 0x4eb2, 0x4f24, 0x50b6, 0x50b9, 0x50ac, 0x50b0, 0x50d7, 0x50bb, + 0x50fe, 0x50cb, 0xc97f, 0x03f5, 0x50b3, 0x50be, 0x50cd, 0x50bc, + 0x50ba, 0x50c7, 0x5316, 0x531b, 0x5317, 0x5315, 0x539f, 0xc98e, + 0x5482, 0x5483, 0x548e, 0x546a, 0x5489, 0x5494, 0x5486, 0x5490, + 0x5562, 0x5590, 0x560c, 0x560f, 0x04c3, 0x56a5, 0x56a7, 0x56a6, + 0x56a4, 0x5735, 0x5738, 0x5736, 0x5743, 0x5747, 0x5737, 0x5943, + 0x59a2, 0x5951, 0x5972, 0x596d, 0x592f, 0x5954, 0x596e, 0x5955, + 0x5937, 0x594f, 0x5950, 0x1f39, 0x599e, 0xc9a8, 0x59b3, 0x59a7, + 0x0571, 0x59f9, 0x5991, 0xc9a7, 0x59b6, 0x59dd, 0x5999, 0x5bdf, + 0x5bd5, 0x77f5, 0x5e28, 0x5e40, 0x5e71, 0x5e98, 0x5e95, 0x5e65, + 0x5e78, 0x5e7f, 0x5e60, 0x5e7c, 0x5e96, 0x5e6a, + /* 0x53 */ + 0x5e79, 0x5e73, 0x5e72, 0x5e7b, 0x5e70, 0x60d5, 0x60d7, 0x618f, + 0x6189, 0x619e, 0x6187, 0x61a0, 0x618d, 0x6188, 0x617f, 0x618c, + 0x6193, 0x6259, 0xbcb0, 0x62b1, 0x81f4, 0x62af, 0x62b2, 0x6308, + 0x630a, 0x6336, 0x6337, 0xc9cf, 0x0701, 0x6436, 0x6429, 0x644a, + 0x6426, 0x6428, 0x6424, 0x642a, 0x6448, 0x6544, 0x6584, 0x658c, + 0x66c4, 0x66dc, 0x6787, 0x6753, 0x677f, 0x6731, 0x6751, 0x674b, + 0x6752, 0x6780, 0x67a5, 0x6781, 0x6743, 0x6734, 0x6736, 0x6732, + 0x6748, 0x6749, 0x673c, 0x674d, 0x674a, 0xc9e6, 0x678a, 0x6746, + 0x673e, 0x6783, 0x6750, 0x67b4, 0x69f0, 0x69e4, 0x69e3, 0x69e5, + 0x69e6, 0x69e7, 0x69e1, 0x69ef, 0x69e8, 0x69dd, 0x6a03, 0x6a88, + 0x6b26, 0x6b16, 0x6b3b, 0x6b2f, 0x6b39, 0x6b34, 0xc9f4, 0x6b35, + 0x6b31, 0x6b38, 0x3e81, 0x6baa, 0x6ba3, 0x6ba4, + /* 0x54 */ + 0x6ba0, 0x6ba1, 0x6ba9, 0x6ba5, 0x6caf, 0x6cb1, 0x6cab, 0x6cae, + 0x6cb0, 0x6cb3, 0x6cac, 0x6ca9, 0x6cb2, 0x6ca8, 0x6cb4, 0x6cc2, + 0x6d4f, 0x6d66, 0x6f1e, 0x6f15, 0x6f10, 0x6f7f, 0x6f7e, 0x6f60, + 0x6fcc, 0x6fb2, 0x6f62, 0x6f8d, 0x6f8e, 0x6f77, 0x6f7c, 0x6f8f, + 0x6f5d, 0x6f6d, 0x6f63, 0x6faf, 0x6f90, 0x6f7d, 0x6f7a, 0x6f06, + 0xca0b, 0x6f68, 0x6fb4, 0x6f78, 0x6fb1, 0x22d7, 0xca0c, 0x0941, + 0x72e8, 0x72e9, 0x72c0, 0x09d7, 0x72ea, 0x72b7, 0x72ba, 0x72b5, + 0xca1d, 0x72b4, 0x72bc, 0x72c6, 0x72b8, 0x72bd, 0x72c2, 0x734d, + 0x72f0, 0x72c7, 0x72c1, 0x72c3, 0x72f1, 0x72ec, 0x09e2, 0x751c, + 0x7520, 0x7558, 0x7565, 0x7564, 0x758c, 0x758d, 0x75d9, 0x75e0, + 0x7610, 0x7694, 0x7692, 0x7696, 0x7695, 0x76bf, 0x76a0, 0x0a45, + 0x77f4, 0x77f6, 0x77dc, 0x243d, 0x7816, 0x7815, + /* 0x55 */ + 0x781c, 0x780f, 0x782c, 0x7814, 0x7825, 0x7817, 0x7812, 0x781e, + 0x7980, 0x79a8, 0x79af, 0x79d6, 0x79e2, 0x79b4, 0x79b3, 0x79b0, + 0x79b2, 0x79a1, 0x7b60, 0x7b66, 0x7b61, 0x7b4e, 0x7b5d, 0x7b63, + 0x7be6, 0x7bef, 0x7bec, 0x7c98, 0x7ca7, 0x7c94, 0x7c95, 0x7c91, + 0x7c9d, 0x7c99, 0x7c9b, 0x7c9c, 0x7d1d, 0x7d1c, 0x7dd0, 0x7de0, + 0x7dcb, 0x7ddb, 0x7dda, 0x7dc2, 0x7dd3, 0x7de5, 0x7f7d, 0x7f7b, + 0x7fff, 0x0bf2, 0x7ff9, 0x8077, 0x807c, 0x8078, 0x807b, 0x807a, + 0x81d2, 0x81cb, 0x81c9, 0x81ce, 0x81e4, 0x81ca, 0x81d0, 0x61a5, + 0x0c49, 0x81d9, 0x81ee, 0x81dd, 0x8200, 0x81e1, 0x83de, 0x83e2, + 0x83da, 0x84ce, 0xca4f, 0x84cf, 0x84da, 0x84d1, 0x84d4, 0x84ed, + 0x84cb, 0x84d5, 0x84f1, 0x869c, 0x8688, 0x8741, 0x87d0, 0x87f7, + 0x87cf, 0x87d1, 0x87db, 0x87de, 0x87f8, 0x87dc, + /* 0x56 */ + 0x87d9, 0x89a0, 0x89b2, 0x89a1, 0x89aa, 0x89a9, 0x0da9, 0x89a6, + 0x899c, 0x89b5, 0x89a7, 0x8a8e, 0x8a90, 0x8a91, 0x8b85, 0x8b5b, + 0x8b70, 0x8b64, 0x8b67, 0x8b63, 0x8b77, 0x8b68, 0x8b65, 0x8b6a, + 0x8b78, 0x8b66, 0x8c88, 0x8c9e, 0x8c74, 0x8c7a, 0x8c79, 0x8c8b, + 0x8c7f, 0x8e13, 0x8e1e, 0x8e17, 0x8e1a, 0x8e22, 0x8e43, 0x8e19, + 0x8e1f, 0x8e27, 0x8e12, 0x8e24, 0x8e25, 0x365e, 0x8f35, 0x8f34, + 0x8fd1, 0x8fc4, 0x8fca, 0x8fc6, 0x8fcb, 0x8fcd, 0x8fe2, 0x9089, + 0x908b, 0x9086, 0x9088, 0x908d, 0x913b, 0x913c, 0x913d, 0x91f5, + 0x9279, 0x9275, 0x9282, 0x927f, 0x9285, 0x9276, 0x927c, 0x927e, + 0x927b, 0x9280, 0x927a, 0x5748, 0x0fcb, 0x931d, 0x93f6, 0x93f7, + 0x93f9, 0x9463, 0x946c, 0x946e, 0x9414, 0x100d, 0x9467, 0x946f, + 0x9469, 0x9476, 0x9495, 0x9471, 0x9461, 0x9478, + /* 0x57 */ + 0x946b, 0x9485, 0x9484, 0x9614, 0x9676, 0x89b6, 0x9675, 0x9674, + 0x96e2, 0x973f, 0x9744, 0x973d, 0x9747, 0x9748, 0x97db, 0x97dc, + 0x97dd, 0x98e5, 0x98e6, 0x99c2, 0x9a2e, 0x9a1d, 0x99f8, 0x99f0, + 0x99f6, 0x99c5, 0x99c6, 0x99fc, 0x9a52, 0x9a2f, 0x9a10, 0x99f3, + 0x99d2, 0x99ea, 0x99dc, 0x9a1b, 0x99fb, 0x99c3, 0x9a16, 0x9a07, + 0x99c9, 0x99d8, 0x9a30, 0x9a13, 0x9a31, 0x99fa, 0x99f2, 0x9ae3, + 0x99d5, 0x9a01, 0x99f1, 0x9a1c, 0x99d6, 0x9a08, 0x9a0b, 0x9a17, + 0x9a20, 0x99ca, 0x9a32, 0x9a05, 0x99e4, 0x99ce, 0x9a33, 0x9a02, + 0x9a19, 0x9a1e, 0x99d3, 0x99f7, 0x99e8, 0x9a1f, 0x99f4, 0x9ad8, + 0x9cbf, 0x9cbe, 0x9cbd, 0x9ddc, 0x9ddd, 0x9dab, 0x9dc9, 0x9dc8, + 0x9ddf, 0x9dd9, 0x9ddb, 0x9dcc, 0x9de0, 0x9def, 0x9df3, 0x9dae, + 0x9e01, 0x9fb7, 0x9fb9, 0x9fb6, 0x9fb8, 0x9ff6, + /* 0x58 */ + 0x9ff3, 0x9ff5, 0x9ff2, 0xa091, 0xa09d, 0xa09b, 0xa092, 0xa08d, + 0xa09e, 0xa08c, 0x1231, 0xcac7, 0xa095, 0xcac6, 0xa08a, 0xa08e, + 0xa09c, 0xa1ef, 0xa22d, 0xa252, 0xa235, 0xa228, 0xa22e, 0xa2e5, + 0xa3ea, 0xa3f1, 0xa3eb, 0xa3d8, 0xa3d0, 0xa3f3, 0xa3db, 0xa3ce, + 0x12d5, 0xa3da, 0xa3d7, 0xa3e1, 0xa3f2, 0xa3c8, 0xa3d9, 0xa3de, + 0xa3d1, 0xa3e7, 0xa3cf, 0xa5b7, 0xa647, 0xa642, 0xa643, 0xcad3, + 0xa6c3, 0xa6c1, 0xa6c7, 0xa764, 0xa76a, 0xa766, 0xa750, 0xa76e, + 0xa765, 0x69ec, 0xa77f, 0xcad5, 0xa79a, 0xa769, 0xa772, 0xa76f, + 0xa77d, 0xa770, 0xa860, 0xa8c2, 0xa8e7, 0xa8d1, 0xa8eb, 0xa8d4, + 0xa8dc, 0xa8db, 0xaa37, 0xaa25, 0xaa1f, 0xaa1e, 0xaa21, 0xaa1b, + 0xaa17, 0xaa22, 0xaa2a, 0xaa1a, 0xaa2d, 0xaa23, 0xaa26, 0xaa36, + 0xa9ff, 0xab3a, 0xab40, 0xab42, 0xab38, 0xab3b, + /* 0x59 */ + 0xab3c, 0xab43, 0xabe8, 0x1456, 0xabf9, 0xabeb, 0xabf1, 0xabe9, + 0xabec, 0xad15, 0xad47, 0xad46, 0xad45, 0xae24, 0xae56, 0xae21, + 0xae27, 0xae4d, 0xae31, 0xae1e, 0xae2c, 0xae4f, 0xae2b, 0xae53, + 0xae51, 0xae54, 0xae29, 0xae50, 0xae1f, 0xae32, 0xae2a, 0xae1d, + 0xae28, 0xae2e, 0xae2d, 0xafbc, 0xafbb, 0xafbd, 0xcae4, 0xb047, + 0xb041, 0xcae5, 0xb049, 0x14f4, 0xb12e, 0xb127, 0xb26a, 0xb27b, + 0xb273, 0xb275, 0xb269, 0xb279, 0xb272, 0xb376, 0xb377, 0xb374, + 0xb373, 0xb402, 0xb3fe, 0xb401, 0xb3f9, 0xb3f4, 0xb5d3, 0xb5d5, + 0xb5d8, 0xb5c3, 0xb5ca, 0xb5d0, 0xb5cb, 0xb5ce, 0xb5c5, 0xb5e6, + 0xb5c4, 0xb5c0, 0xb5d4, 0xb5e8, 0xb676, 0xb6a2, 0xb6ae, 0xb6a8, + 0xb6a3, 0xb6a7, 0xb696, 0xb6a9, 0xb6a5, 0xb6af, 0xb6a4, 0xb6ab, + 0xb6aa, 0xb6a6, 0xb6a0, 0xb798, 0xb8db, 0xb8f6, + /* 0x5a */ + 0xb8f5, 0xb90c, 0xb90a, 0x3175, 0xb968, 0xb963, 0xb966, 0x1658, + 0xb964, 0xb96a, 0xb969, 0xba95, 0xbb02, 0xbb6a, 0xbb5e, 0xbb68, + 0xbb69, 0xbb65, 0xcafe, 0xbca7, 0xbcae, 0xbca8, 0xbcb3, 0xbd9c, + 0xbda9, 0xbdb6, 0xbdb3, 0xbdb2, 0xcb03, 0xbdb8, 0xbdc0, 0xbdbf, + 0xbdba, 0xbda8, 0xbe3c, 0xbe72, 0xbe71, 0xbe75, 0xbe73, 0xbf17, + 0xbf15, 0xbf16, 0xbf1b, 0xbffa, 0xbff9, 0xc12c, 0xc185, 0xc182, + 0xc17f, 0xc17d, 0xc188, 0x72f3, 0xc24e, 0xc250, 0xc393, 0xc397, + 0xc398, 0xc39b, 0xc39c, 0xc396, 0xc58b, 0xc5fd, 0xc5fc, 0xcb17, + 0x6a8b, 0x3408, 0x3407, 0x3673, 0x36a2, 0x36af, 0x3682, 0x367b, + 0x3674, 0x36b0, 0x3676, 0x36b9, 0x369e, 0x36b1, 0x36a1, 0x36b2, + 0x366e, 0xc90b, 0x0087, 0x3678, 0x367a, 0x3683, 0x369a, 0x37f8, + 0x3831, 0x3869, 0x3868, 0x389c, 0x3904, 0x3999, + /* 0x5b */ + 0x3ac7, 0x3ac6, 0x3adc, 0x3ac4, 0x3ad8, 0x3ad4, 0x3adf, 0x3ad1, + 0x3ad0, 0x3ad6, 0x3acf, 0x3bad, 0x3baf, 0x3ba7, 0x3bfd, 0x3c5b, + 0x3c5a, 0x3d07, 0x3d9d, 0x3d9b, 0x3dab, 0x3da4, 0x3d9c, 0x3d9e, + 0x3da5, 0x3daa, 0x3da6, 0x3e0e, 0x3e7e, 0x3e7c, 0x41ee, 0x41d5, + 0x41e9, 0x4142, 0x41e2, 0x4223, 0x41d9, 0x41d4, 0x41e3, 0x4215, + 0x41ef, 0x41f0, 0x41d6, 0x41dd, 0x41f6, 0x421c, 0x41d8, 0x41db, + 0x41da, 0x41ed, 0x4611, 0x4415, 0x4418, 0x441a, 0x441f, 0x4416, + 0xc94d, 0x4419, 0xc94b, 0x45f0, 0x4609, 0x461b, 0xa5e7, 0x45f6, + 0x45f4, 0x45b5, 0x4610, 0x45f2, 0x4615, 0x45f3, 0x45f8, 0x4739, + 0x473b, 0x4736, 0x460e, 0x4772, 0x4774, 0x47b9, 0x47b7, 0x47b8, + 0x4872, 0x486b, 0x4a1d, 0x4a37, 0x4a22, 0x4a43, 0x4a4d, 0x4a38, + 0x4a5b, 0x4a79, 0x4a1b, 0x49f3, 0x4b91, 0x4c7b, + /* 0x5c */ + 0x4c94, 0xc96f, 0x4c96, 0x4c7f, 0x4c8f, 0x4c84, 0x4c7c, 0x4c8e, + 0x4c90, 0x4c98, 0x4c83, 0x4c80, 0x4c93, 0x4c82, 0x32fd, 0x4d3d, + 0x4d41, 0x4da1, 0x4d9f, 0x4e0a, 0x4e0d, 0x4ec8, 0x4ec9, 0x4ec7, + 0x4ecd, 0x4f25, 0x50b1, 0x50dc, 0xc980, 0x50e5, 0x50f4, 0x50bf, + 0x50db, 0x50ea, 0x50f2, 0x03fa, 0x50f1, 0x50ed, 0x50e6, 0x5202, + 0xc982, 0x5325, 0x5318, 0x531f, 0x5320, 0x53cf, 0x549d, 0x5499, + 0x54a8, 0x5568, 0x5566, 0x5567, 0x5591, 0x5613, 0x5615, 0x561d, + 0x5616, 0x5619, 0x566b, 0x5668, 0x566a, 0x566d, 0x5669, 0x56aa, + 0x5757, 0x5752, 0x5750, 0x575f, 0x5767, 0x574f, 0x04f2, 0x575b, + 0x575c, 0x575d, 0x5a1f, 0x599d, 0x59b1, 0x59b0, 0x5994, 0x59c3, + 0x59af, 0x59a8, 0x59dc, 0x5998, 0x59c4, 0x59a4, 0x59ab, 0x59aa, + 0x59a5, 0x5a21, 0x59eb, 0x59e6, 0x59f7, 0x59f8, + /* 0x5d */ + 0x59fc, 0x59fa, 0x59e0, 0xc9aa, 0x59f6, 0xc9a9, 0x59e1, 0x5bec, + 0x5be2, 0x5be4, 0x5bf9, 0x5e6f, 0x6b4c, 0x5ebb, 0x5ee1, 0x5f00, + 0x5ed8, 0x062f, 0x5ed6, 0x5ee2, 0x5ec3, 0x5eb3, 0x5ed2, 0xc9c1, + 0x5ece, 0x5ed0, 0x5ed5, 0x5eb9, 0x5eba, 0x5ecf, 0x5ebd, 0x60db, + 0x61aa, 0x61ad, 0x61b8, 0x61b6, 0x61b5, 0x61af, 0x61b4, 0x61b7, + 0x61a8, 0x61b9, 0x61be, 0x6282, 0x62bc, 0x62b8, 0x62b6, 0x62b9, + 0x06c1, 0x6310, 0x6427, 0x6469, 0x6470, 0x6456, 0x646b, 0x647a, + 0x646c, 0x646d, 0xc9d5, 0x94c1, 0x658d, 0x6590, 0x67b6, 0x6810, + 0x6812, 0x67ba, 0x67bd, 0x6805, 0x67c2, 0x6807, 0x67f5, 0xc9e9, + 0x67af, 0x67f4, 0x67f7, 0x67f8, 0x6811, 0x69f6, 0x69f5, 0x69fb, + 0x6a01, 0x6a00, 0x6a02, 0x69fe, 0x69fa, 0x69fd, 0x0840, 0x6b37, + 0x6b49, 0x6b4b, 0x6b46, 0x6b47, 0x6bb3, 0x6bb2, + /* 0x5e */ + 0x6bb0, 0x6bb7, 0x6c11, 0x6ccc, 0x6cdf, 0x6cd3, 0x6cd5, 0x6cdb, + 0x6cc5, 0x6cc8, 0x6cc9, 0x6ce2, 0x6cca, 0x6cd1, 0x6cd2, 0x6cdd, + 0x6f6c, 0x6f73, 0x7021, 0x6ff0, 0x701f, 0x703b, 0x7022, 0x7023, + 0x6fe8, 0x6fdd, 0x093f, 0x701b, 0x6fed, 0xca0e, 0x6ff2, 0x0946, + 0x6fdc, 0x6fe9, 0x701d, 0x6fda, 0x6fe6, 0x7313, 0x7315, 0x7316, + 0x733c, 0x730b, 0x731c, 0x733a, 0x733d, 0x739a, 0x731d, 0x7309, + 0x7308, 0x733b, 0x7522, 0x7526, 0x7525, 0x7524, 0x369b, 0x758f, + 0x7590, 0x75e6, 0x75e3, 0x75e5, 0x7611, 0xca25, 0x76ae, 0x76be, + 0x76b4, 0x76b3, 0x76af, 0x7691, 0x76c2, 0x76b6, 0x76b2, 0x7857, + 0x783b, 0x7858, 0x7851, 0x7841, 0x7839, 0x0a8f, 0x7859, 0x7845, + 0x7861, 0x78e8, 0x79fa, 0x79ea, 0x79ef, 0x79f2, 0x79f0, 0x7b08, + 0x7b70, 0x7b6a, 0x7b73, 0x7b68, 0x7bc8, 0x7bf2, + /* 0x5f */ + 0x3e7b, 0x7cae, 0x7cab, 0x7cb5, 0x7caf, 0x7cb2, 0x7cb6, 0x7cb0, + 0x7d1e, 0x7e03, 0x7e06, 0x7e1f, 0x0bac, 0x7e0f, 0x7e02, 0x7e19, + 0x7e18, 0x7e22, 0x7e15, 0x7e07, 0x7e0d, 0x7e24, 0x7e0c, 0x7e1e, + 0x7f89, 0x7f8a, 0x800a, 0x800b, 0x8007, 0x8004, 0x8009, 0x8084, + 0x8083, 0x8218, 0x8214, 0x8205, 0x8216, 0x820e, 0x8211, 0x8208, + 0x820b, 0x8215, 0x8085, 0x8237, 0x822a, 0x820d, 0x820f, 0x837e, + 0x8376, 0x8377, 0x83ec, 0x84fc, 0x8508, 0x84ff, 0x8503, 0x8510, + 0x8505, 0x8506, 0x84fa, 0x86c7, 0x86c0, 0x86c3, 0x86a7, 0x86a8, + 0x86ab, 0x86c1, 0x86aa, 0x86c8, 0x8743, 0x8802, 0x880e, 0x8801, + 0x87fe, 0x8803, 0x0d68, 0x8822, 0x8821, 0x8807, 0x8808, 0x880c, + 0x89ca, 0x89bc, 0x89be, 0x89bd, 0xca5c, 0x89bb, 0x89b9, 0x0dab, + 0x89c5, 0x8a99, 0x8b6b, 0x8b93, 0x8b94, 0x8ba9, + /* 0x60 */ + 0x8ba0, 0x8ba6, 0xca61, 0x8bab, 0x8b9e, 0x8b9b, 0x8b91, 0x8b99, + 0x8cb6, 0x8cb8, 0x8c9a, 0x0e91, 0x8c98, 0x8c9b, 0x8cb3, 0x8ca2, + 0x54aa, 0x8ca0, 0x8c9f, 0x8e5b, 0x8e70, 0x8e54, 0x8e71, 0x8e65, + 0x8e51, 0x8e9d, 0x8e61, 0x8e5a, 0x8e74, 0x8e4c, 0x8e4b, 0x8e5e, + 0x8e58, 0x8e53, 0x8e52, 0x8f3b, 0x8f39, 0x8fd6, 0x8fe7, 0x8fd7, + 0x8fd8, 0x8fd9, 0x8fda, 0x8fdb, 0x8fdc, 0x8fe0, 0x8fe4, 0x8fdd, + 0x8ff5, 0x8ff1, 0x9098, 0x909d, 0x9099, 0x9150, 0x9149, 0x27e4, + 0x9162, 0x91d7, 0x9201, 0x91f7, 0xca7d, 0x928c, 0x929c, 0x2888, + 0x931f, 0x931e, 0x943d, 0x943f, 0x9411, 0x9459, 0x943e, 0x9458, + 0x9500, 0x949e, 0x94b6, 0x94aa, 0x94af, 0x94ac, 0x1030, 0x94c0, + 0x94a9, 0x3e10, 0x95ee, 0x9677, 0x9679, 0x967a, 0x967d, 0x967f, + 0x9683, 0x9678, 0x967e, 0x96e4, 0x96e6, 0x96e5, + /* 0x61 */ + 0x105d, 0x974e, 0x9759, 0x1075, 0xca8e, 0x974f, 0x974a, 0x97e3, + 0x97de, 0x97e2, 0x9974, 0x99ac, 0x9961, 0x9962, 0x9976, 0x997a, + 0x9979, 0x9960, 0x9a64, 0x9b81, 0x9adf, 0x9a84, 0x9a8a, 0x9a92, + 0x9a79, 0x9ade, 0x9a98, 0x9a6c, 0x9ae1, 0xcaa5, 0x9a7c, 0x9a72, + 0x9a81, 0x9ae0, 0x9a65, 0x10ff, 0x9a6a, 0x9a97, 0x9aaa, 0x9ad3, + 0x9aab, 0x9a6e, 0x9aac, 0x9a76, 0x9a7b, 0x9aad, 0xcaa6, 0x9a94, + 0x9ad7, 0x9a70, 0x9ad5, 0x9af1, 0x9a7a, 0x9a68, 0x9a96, 0x110b, + 0x9a73, 0x9aae, 0x9add, 0x9ada, 0x9aaf, 0x9ab0, 0x9adb, 0x9a62, + 0x9af8, 0x9cc2, 0x9cc7, 0x9cc8, 0x9cc5, 0x9cc3, 0x9cc6, 0x9dde, + 0x11c8, 0x9e11, 0x9e15, 0x9e28, 0x9e21, 0x9e2d, 0x9e51, 0x9e2b, + 0x9e16, 0x9e24, 0x9e35, 0x9e1f, 0x9e12, 0x9e10, 0x9e80, 0x9e3b, + 0x9e29, 0x9e2a, 0x9e1b, 0x9e18, 0x9e20, 0x9e3f, + /* 0x62 */ + 0x9e1c, 0x9e26, 0x9e0b, 0x9fbe, 0x9fc4, 0x9fbd, 0x9ffa, 0x9ffb, + 0xa0b1, 0xa0b2, 0xa0b0, 0xa0b9, 0xa0a6, 0xa0bd, 0xa0b6, 0xa0b8, + 0xa0b4, 0xa0b3, 0xa0a7, 0xa0ae, 0xa0bc, 0xa1f2, 0xa1f3, 0xa1f4, + 0xa23b, 0xa240, 0xa246, 0xa2f0, 0xa2ee, 0xa2e8, 0xa2f1, 0xa2eb, + 0xa2ef, 0xa3fc, 0xa420, 0xa409, 0xa406, 0xa403, 0xcacf, 0xa419, + 0xa424, 0xa41b, 0xa41d, 0xa3fd, 0xa41e, 0xa3f4, 0xa401, 0xa408, + 0xa405, 0xa423, 0xa3ff, 0xa5ea, 0xa64d, 0xa64e, 0xa656, 0xa657, + 0xa651, 0xa655, 0xa654, 0xa6cb, 0xa6d4, 0xa6d1, 0xa6cf, 0xa6d2, + 0xa6ca, 0xa6d6, 0xa78b, 0xa788, 0xa785, 0xa789, 0x4c9b, 0xa7bb, + 0xa78c, 0x1374, 0xa799, 0xa78a, 0xa8ec, 0xa8ef, 0xa8f9, 0xa909, + 0xa8f8, 0xa8f3, 0xa900, 0xa91d, 0x13ac, 0xa8fd, 0xaa48, 0xaa5c, + 0xaa55, 0xaa5e, 0xaa49, 0xaa63, 0xaa60, 0xaa53, + /* 0x63 */ + 0xaa62, 0xaa40, 0xab49, 0xab4a, 0xab4c, 0xab4d, 0xac0a, 0xac06, + 0xac2f, 0xac21, 0xac07, 0xac09, 0xac02, 0xac16, 0xac03, 0xac0b, + 0xac0f, 0xae60, 0xae68, 0xae5e, 0xae5d, 0xae63, 0xae5f, 0xae64, + 0xae78, 0xae61, 0xae69, 0xae65, 0xafda, 0xafe6, 0xafdb, 0xafdc, + 0xb039, 0xb057, 0xb055, 0xb065, 0xb061, 0xb054, 0xb145, 0xb141, + 0xb13e, 0xb137, 0xb212, 0xb213, 0xb22c, 0xb296, 0xcae9, 0xb29c, + 0xb29d, 0xb285, 0xcae8, 0xb29f, 0xb2a3, 0xb382, 0xb383, 0xcaee, + 0xb41d, 0xb414, 0xb41f, 0xb420, 0xb547, 0xb580, 0xb5c9, 0xb5f9, + 0xb606, 0xb5f0, 0xb5f8, 0xb5ef, 0xb5fd, 0xb5f1, 0xb5fe, 0xb6b8, + 0xb6c0, 0xb6c3, 0xb6b5, 0xb6b6, 0xb6c9, 0xcaf3, 0xb6bd, 0xb6ba, + 0xb6bf, 0xb6b3, 0xb6c6, 0xb6b2, 0xb6bc, 0xb6b7, 0xb6b9, 0xb6c8, + 0xb7b5, 0xb7b3, 0x1616, 0xb7ac, 0xb7a9, 0xb7ad, + /* 0x64 */ + 0xb911, 0xb90d, 0xb916, 0xb989, 0xb97c, 0xb98b, 0xb97b, 0xb988, + 0xb984, 0xba9d, 0xba98, 0xbb88, 0xbb86, 0xbb82, 0xbb8b, 0xcaff, + 0xbb71, 0xbb72, 0xbb81, 0xbb8c, 0xbb80, 0xbb89, 0xbcbb, 0xbcc1, + 0xbcbe, 0xcb01, 0xbcbd, 0xbdc1, 0xbdb4, 0xbdb7, 0xbdc8, 0x173b, + 0xbdd3, 0xbdd0, 0xbdb0, 0xbdca, 0xbdcd, 0xbe15, 0xbe19, 0xbe17, + 0xbe3f, 0xbe40, 0xbe44, 0xbe7c, 0xbe78, 0xbe79, 0xbe88, 0xcb06, + 0xbe89, 0xbe7d, 0xbf23, 0xbf24, 0xbf26, 0xbf22, 0xbf27, 0xbf1f, + 0xbfc9, 0xbfc3, 0xc00a, 0xc00b, 0xc004, 0x17ef, 0xc003, 0xc001, + 0xc009, 0xc10f, 0xc12e, 0xc12d, 0xc191, 0xc199, 0xc19e, 0xc190, + 0xc194, 0xc19d, 0xc198, 0xc19b, 0xc19c, 0xc19a, 0xc254, 0xc39d, + 0xc39f, 0xc3a3, 0xc3a4, 0xc3a5, 0xc602, 0xc717, 0xc71b, 0xc719, + 0xc7d1, 0x4737, +}; + +static const ucs4_t cns11643_6_2uni_upages[204] = { + 0x03400, 0x03500, 0x03600, 0x03700, 0x03800, 0x03900, 0x03a00, 0x03b00, + 0x03c00, 0x03d00, 0x03e00, 0x03f00, 0x04000, 0x04100, 0x04200, 0x04300, + 0x04400, 0x04500, 0x04600, 0x04700, 0x04800, 0x04900, 0x04a00, 0x04b00, + 0x05100, 0x05300, 0x05500, 0x05a00, 0x05b00, 0x05d00, 0x05e00, 0x06100, + 0x06500, 0x06800, 0x06e00, 0x07200, 0x07300, 0x07800, 0x07a00, 0x07f00, + 0x08000, 0x08100, 0x08200, 0x08800, 0x08900, 0x08a00, 0x08d00, 0x08f00, + 0x09200, 0x09700, 0x0ff00, 0x20000, 0x20100, 0x20200, 0x20300, 0x20400, + 0x20500, 0x20600, 0x20700, 0x20800, 0x20900, 0x20a00, 0x20b00, 0x20c00, + 0x20d00, 0x20e00, 0x20f00, 0x21100, 0x21200, 0x21300, 0x21400, 0x21500, + 0x21600, 0x21700, 0x21800, 0x21900, 0x21a00, 0x21b00, 0x21c00, 0x21d00, + 0x21e00, 0x21f00, 0x22000, 0x22100, 0x22200, 0x22300, 0x22400, 0x22500, + 0x22600, 0x22700, 0x22800, 0x22900, 0x22a00, 0x22b00, 0x22c00, 0x22d00, + 0x22e00, 0x22f00, 0x23000, 0x23100, 0x23200, 0x23300, 0x23400, 0x23500, + 0x23600, 0x23800, 0x23900, 0x23a00, 0x23b00, 0x23c00, 0x23d00, 0x23e00, + 0x23f00, 0x24100, 0x24200, 0x24300, 0x24400, 0x24500, 0x24600, 0x24700, + 0x24800, 0x24900, 0x24a00, 0x24b00, 0x24c00, 0x24d00, 0x24e00, 0x24f00, + 0x25000, 0x25100, 0x25200, 0x25300, 0x25400, 0x25500, 0x25600, 0x25700, + 0x25800, 0x25900, 0x25a00, 0x25b00, 0x25e00, 0x25f00, 0x26000, 0x26200, + 0x26300, 0x26400, 0x26500, 0x26600, 0x26700, 0x26800, 0x26900, 0x26a00, + 0x26b00, 0x26c00, 0x26d00, 0x26e00, 0x27100, 0x27200, 0x27300, 0x27500, + 0x27600, 0x27700, 0x27800, 0x27900, 0x27a00, 0x27b00, 0x27c00, 0x27d00, + 0x27e00, 0x27f00, 0x28000, 0x28200, 0x28300, 0x28400, 0x28500, 0x28600, + 0x28700, 0x28800, 0x28900, 0x28c00, 0x28d00, 0x28e00, 0x28f00, 0x29000, + 0x29100, 0x29200, 0x29300, 0x29400, 0x29500, 0x29600, 0x29800, 0x29a00, + 0x29b00, 0x29c00, 0x29d00, 0x29f00, 0x2a000, 0x2a200, 0x2a300, 0x2a400, + 0x2a500, 0x2f800, 0x2f900, 0x2fa00, +}; + +static int +cns11643_6_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x21 && c1 <= 0x64)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + ucs4_t wc = 0xfffd; + unsigned short swc; + { + if (i < 6388) + swc = cns11643_6_2uni_page21[i], + wc = cns11643_6_2uni_upages[swc>>8] | (swc & 0xff); + } + if (wc != 0xfffd) { + *pwc = wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + diff --git a/graf2d/win32gdk/gdk/src/iconv/cns11643_7.h b/graf2d/win32gdk/gdk/src/iconv/cns11643_7.h new file mode 100644 index 0000000000000..44532bc4e11ea --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cns11643_7.h @@ -0,0 +1,988 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CNS 11643-1992 plane 7 + */ + +static const unsigned short cns11643_7_2uni_page21[6539] = { + /* 0x21 */ + 0x2b55, 0x2c82, 0x2c89, 0x2c87, 0x2dbe, 0x2dbd, 0x2dca, 0x2dd4, + 0x2dbc, 0x2dc4, 0x2dc1, 0x2dc2, 0x2dd7, 0x2d70, 0x2dba, 0x2de3, + 0x2dbb, 0x2eb1, 0x2eb6, 0x2eb0, 0x2f6c, 0x300d, 0x3007, 0x31f1, + 0x31f5, 0x31ed, 0x31ef, 0x31eb, 0x31ec, 0x31ee, 0x3207, 0x33c4, + 0x3408, 0x34b3, 0x34ad, 0x34b0, 0x3511, 0x2c8a, 0x3683, 0x367a, + 0x3682, 0x3668, 0x3671, 0x36b0, 0x36af, 0x01f6, 0x366c, 0x366f, + 0x3662, 0x3665, 0x3681, 0x367f, 0x3664, 0x3673, 0x366e, 0x3667, + 0x3674, 0x367d, 0x3678, 0x3685, 0x36aa, 0x3688, 0x36a6, 0xc34e, + 0x368a, 0x3684, 0x1a55, 0x3924, 0x3922, 0x3923, 0x3a32, 0x3a5b, + 0x3a4f, 0x0267, 0x3a26, 0x3a3e, 0x3a42, 0x3a47, 0x3a22, 0x309b, + 0x3a4a, 0x3a1f, 0x3a49, 0x3a2b, 0x3a33, 0xc358, 0x3a2a, 0x3a28, + 0x3b3d, 0x3b3c, 0x3bbf, 0x3c79, 0x3c80, 0x3c7c, + /* 0x22 */ + 0x3c7a, 0x3c78, 0x3d82, 0x3d5c, 0x3d5a, 0x3d4b, 0x3d7c, 0x3d7f, + 0x3d1f, 0x3d89, 0x3d8b, 0x3d57, 0x3d7e, 0x3d7d, 0x3d53, 0x3f9f, + 0x3fbc, 0x3fa5, 0x3f86, 0x3fdc, 0x3fa4, 0x3fb6, 0x3fa2, 0x3fb4, + 0x4048, 0x4046, 0x40a7, 0x4114, 0x4112, 0x4111, 0x41e1, 0x41d0, + 0x4226, 0x4228, 0x4229, 0x432f, 0x430d, 0x4325, 0x4314, 0x433c, + 0x430b, 0x4311, 0x4330, 0x4318, 0x4319, 0x4336, 0x4317, 0x4310, + 0x4315, 0x4403, 0x4429, 0x444c, 0x453f, 0x453e, 0x4534, 0x4542, + 0x4535, 0x31f3, 0x45cd, 0x45d1, 0x45d2, 0x46ad, 0x46ba, 0x46c1, + 0x46bb, 0x46b4, 0x46bc, 0x476c, 0x4792, 0x4821, 0x4824, 0x5f19, + 0x48ad, 0x48ae, 0x48ab, 0x48ac, 0x4970, 0x4976, 0x4971, 0x4977, + 0x1c7f, 0x4aec, 0x4b1c, 0x4afb, 0x4aee, 0x4be2, 0x4afd, 0x4b1e, + 0x4b3b, 0x4b4a, 0xc3ae, 0x0592, 0x4b7d, 0x4b56, + /* 0x23 */ + 0x4b44, 0x4b4b, 0x4cfa, 0x4ce8, 0x4cf8, 0x4cff, 0x4cf7, 0x4cf6, + 0x4cfe, 0x4d07, 0x4d5d, 0x4ed4, 0xc3c3, 0x4ec8, 0x4ec5, 0xc3c0, + 0x4ec9, 0x4f4d, 0x4f20, 0x4f36, 0x4f35, 0x4f88, 0x4f25, 0x4f21, + 0x4f26, 0x0645, 0x4f3f, 0x4f3b, 0x4f24, 0x4f43, 0x4f4e, 0x4f4f, + 0x4f44, 0x4f40, 0x4f41, 0x4f39, 0x4f2b, 0x50dd, 0x50de, 0x51cd, + 0x51cb, 0x51db, 0x51d8, 0x51d9, 0x51d2, 0x51ca, 0x51d1, 0x51d4, + 0x51f9, 0x51d0, 0x525e, 0x525d, 0x528a, 0x5314, 0x5483, 0x5484, + 0x549b, 0x5482, 0x547d, 0x547c, 0x5499, 0x547e, 0x549a, 0x5495, + 0x547b, 0x5486, 0x5548, 0x5592, 0x56b2, 0x5742, 0x5772, 0x5715, + 0x5730, 0x5743, 0x575b, 0x571d, 0x5773, 0x572d, 0x07c9, 0x5721, + 0x571c, 0xc3ea, 0x5729, 0x571e, 0x5733, 0x5a10, 0x5a0e, 0xc3f1, + 0x5a0d, 0x5a11, 0x5a12, 0x5a17, 0x5a09, 0x5a0f, + /* 0x24 */ + 0x5a98, 0x5a94, 0x5a96, 0x5a99, 0x5a95, 0x5a97, 0x5b50, 0x5b52, + 0x5b4d, 0x5b57, 0x5b53, 0x5b56, 0x5bb8, 0x5c12, 0x5cf1, 0x5cf0, + 0x5cee, 0x5cef, 0x5ce5, 0x5ceb, 0x5ce7, 0x5cf2, 0x5ce6, 0x5cf7, + 0x5d09, 0x5d6b, 0x5d6a, 0x5e79, 0x5ecd, 0x5eef, 0x5ee4, 0x5ee3, + 0x5f6c, 0x5f67, 0x5f62, 0x5f58, 0x5f69, 0x5fab, 0x5f57, 0x5fad, + 0x5f54, 0x5fae, 0x5f76, 0x5f49, 0x5f45, 0x5f4f, 0xc40f, 0x5f50, + 0x5f7d, 0x5f44, 0x5f66, 0x5f48, 0x5fa3, 0x5f51, 0x5f53, 0xc410, + 0x5f60, 0x5f47, 0x5f5e, 0x5f85, 0x5fac, 0x5f6d, 0x5f75, 0x5fa8, + 0x0955, 0x5f43, 0x5f4e, 0x5f5c, 0x5f56, 0x5f6e, 0x5f63, 0x5f6a, + 0x6256, 0x6212, 0x625c, 0x6258, 0x6255, 0x627e, 0x62a8, 0x6211, + 0x6259, 0x625a, 0x6267, 0x6254, 0x625b, 0x62f0, 0x6429, 0x642c, + 0x642a, 0x6427, 0x6467, 0x6468, 0x6493, 0x6495, + /* 0x25 */ + 0x649a, 0x64ee, 0x64f1, 0x64ed, 0x64e9, 0x65cb, 0x65df, 0x65db, + 0x673c, 0x674e, 0x676c, 0x677b, 0x677c, 0x6783, 0x676b, 0x6766, + 0x6763, 0x67a0, 0x6785, 0x6768, 0x67a2, 0x68ec, 0x0ae8, 0x68e7, + 0x6910, 0x6918, 0x693a, 0x691a, 0x6938, 0x6941, 0x691b, 0x6914, + 0x691c, 0x691d, 0x6a12, 0x6a0d, 0x6a07, 0x6a7e, 0x6a7f, 0x34b9, + 0x6a80, 0x6a7a, 0x6af3, 0x6bb9, 0x6bbb, 0x6bba, 0x6bbd, 0x6bb7, + 0x6bbf, 0x6c21, 0x6d3a, 0x6d3d, 0x6d36, 0x6d49, 0x6d81, 0x0bb6, + 0x6d3f, 0x6d4d, 0x6d3e, 0x0bbd, 0x6d30, 0x6d4f, 0x6e37, 0x6e98, + 0x6e99, 0x6f11, 0x6f0d, 0x6f88, 0x6f8a, 0x701c, 0x7055, 0x7056, + 0x7062, 0x7057, 0x7042, 0x7010, 0x704d, 0x705a, 0x7066, 0x7046, + 0x4b7e, 0x704f, 0x80f9, 0x7187, 0x7184, 0x71f4, 0x71f5, 0x71f2, + 0x71f7, 0x7345, 0xc450, 0x7349, 0x7335, 0x72fd, + /* 0x26 */ + 0x7330, 0x7343, 0x7346, 0x0cd6, 0x7333, 0x74c6, 0xc456, 0x74d4, + 0x8dd8, 0x74e0, 0x36a7, 0x7544, 0x2d98, 0x7654, 0x763e, 0x7635, + 0x763a, 0x0d71, 0x7634, 0x7639, 0x7646, 0x765a, 0x765b, 0x763c, + 0x77dc, 0x77d6, 0x77d0, 0xc45e, 0x78ac, 0xc45d, 0x78a5, 0x79f4, + 0x7a24, 0x79e0, 0x79fd, 0x79f2, 0x79fc, 0x7a02, 0x79f1, 0x79ff, + 0x79d2, 0x79d8, 0x79d3, 0x79f9, 0xc463, 0x79ed, 0x79f7, 0x79f0, + 0x79d7, 0x7a09, 0x79f5, 0x7cc2, 0x7cc5, 0x7ccf, 0x0e98, 0x7cc1, + 0x7cc6, 0x7cd4, 0x7cce, 0x7e9b, 0x7e99, 0x7e8f, 0x7eb7, 0x7e82, + 0x7e93, 0x7eb4, 0x7ec1, 0x7e90, 0x7e9a, 0x7e94, 0x7e9c, 0x7eb5, + 0xc46f, 0xc46e, 0x7e9f, 0x7e8e, 0x7e9e, 0x803c, 0x8047, 0x8041, + 0x80eb, 0x80ec, 0x80ed, 0x80ee, 0x80df, 0x80f2, 0x810d, 0x810e, + 0x2c86, 0x81a9, 0x81a4, 0x81a5, 0x825f, 0x825a, + /* 0x27 */ + 0x8266, 0x8268, 0x826a, 0x8264, 0x8265, 0x82c1, 0x82d8, 0xc47b, + 0x82d9, 0x8309, 0x83aa, 0x83a3, 0x83b9, 0x77e2, 0x83a5, 0x83ab, + 0x8420, 0x8589, 0x858b, 0x85db, 0x85e4, 0x85ef, 0x85e2, 0x85e9, + 0x85f0, 0x85f3, 0x85dd, 0x861e, 0x871d, 0x8746, 0x877c, 0x8780, + 0x8781, 0x8782, 0x8787, 0x8788, 0x878a, 0x878c, 0x87e7, 0x87eb, + 0x87ea, 0x8868, 0x886b, 0x8869, 0x8866, 0x886a, 0x8865, 0x88e5, + 0x88e4, 0x88e6, 0x8918, 0x8a24, 0x8a48, 0x8a2f, 0x8a7e, 0x8989, + 0x8a1e, 0x8a49, 0x8a26, 0x8a09, 0x8a34, 0x8a2d, 0x8a4a, 0x8a15, + 0xc4a9, 0x8a33, 0x8a28, 0x8a27, 0x8a20, 0x8a2b, 0x8a29, 0x8a6a, + 0x8a0b, 0x8a0e, 0x8a1c, 0x89ff, 0xc4aa, 0x8a35, 0x8a11, 0x8a4b, + 0x8a4c, 0x8a1f, 0x8a0f, 0x8a39, 0x8a68, 0x8a1d, 0x8a08, 0x8a0c, + 0x8a0d, 0x8a62, 0x8aaf, 0x8a32, 0x8a2c, 0x8a64, + /* 0x28 */ + 0x8a04, 0x8a16, 0x8a4d, 0x8a07, 0x8aae, 0x8dd4, 0x8dd1, 0x8dd5, + 0x8dd0, 0x8f71, 0x8f5d, 0x8f5b, 0x8f7a, 0xc4bd, 0x8f7f, 0x8f79, + 0x8f67, 0x8f9e, 0x8f94, 0x8f64, 0x8f5e, 0x8f81, 0x8f5a, 0x8f57, + 0x8f7c, 0x8f98, 0x8f66, 0x8f7e, 0x8f82, 0x8f68, 0x8f5f, 0x8f63, + 0x8f97, 0x11cd, 0x8f53, 0x8f7b, 0x8f7d, 0x8f78, 0x9006, 0x91c0, + 0x91c2, 0x91c3, 0x92dc, 0x92e6, 0x92ec, 0x92f2, 0x92e8, 0x92eb, + 0x92ea, 0x92e5, 0x92e0, 0x92d0, 0x92d8, 0x92d5, 0x92d3, 0x92e4, + 0x92f3, 0x92db, 0x932f, 0x93f9, 0x945d, 0x945b, 0x944c, 0x9458, + 0x9460, 0x9453, 0x9450, 0x9507, 0x9508, 0x94f4, 0x94f6, 0x9504, + 0x94fd, 0x9505, 0x9628, 0x9656, 0x9642, 0x965c, 0x963d, 0x962f, + 0x962b, 0x9658, 0x9661, 0x962c, 0x9651, 0x9650, 0x963c, 0x9636, + 0x12f6, 0x9660, 0x965b, 0x962e, 0x9640, 0x965f, + /* 0x29 */ + 0x9626, 0x962d, 0x965e, 0x963b, 0x97ef, 0x97f3, 0x97ee, 0x97ed, + 0x985a, 0x9862, 0x985b, 0x985f, 0x985e, 0x9864, 0x98e0, 0x98e1, + 0x98e5, 0x99a5, 0x999b, 0x999f, 0x999c, 0x137a, 0x99aa, 0x99a4, + 0x99a3, 0x9a67, 0x9b26, 0x9b1a, 0x13b8, 0x9b1c, 0x9b15, 0x9b1b, + 0x9b18, 0x9b1e, 0x9b25, 0xc4dc, 0x9c7b, 0x9c75, 0x9c93, 0x9c8f, + 0x9c7c, 0x9c9b, 0x9c88, 0x9c91, 0x9c7e, 0x1401, 0x9c86, 0x9e5b, + 0x9e54, 0x9f35, 0x9f40, 0x9f37, 0x9f29, 0x9f26, 0x9f23, 0x9f30, + 0x9f20, 0x9f28, 0x9f32, 0x9f2a, 0x9f31, 0x9f24, 0x9f41, 0x9f42, + 0x9f43, 0x9f25, 0x9f38, 0xa01c, 0xa01d, 0xa01e, 0xa0f6, 0xa1a5, + 0xa189, 0xa19d, 0xa18a, 0xa187, 0xa1ab, 0xa186, 0xa19e, 0xa193, + 0xa1a1, 0xa188, 0xa1a3, 0xa19f, 0xa1a0, 0xa2ff, 0xa300, 0xa302, + 0xa2f8, 0xa2f7, 0xa301, 0xa387, 0xa389, 0xa376, + /* 0x2a */ + 0xa36e, 0xa377, 0xa382, 0xa385, 0xa383, 0xa384, 0xa457, 0xa44b, + 0xa456, 0xa45d, 0xa460, 0xa44d, 0xa455, 0xa454, 0xa453, 0xa450, + 0xa463, 0xa462, 0xa517, 0xa516, 0xa52d, 0xa5d9, 0xa5bf, 0x152f, + 0xa5b2, 0xa5ac, 0xa5b0, 0xa5cf, 0xa5b8, 0x1531, 0xa5d3, 0xa5b1, + 0xa5af, 0xa5ce, 0xa5b4, 0xa5b7, 0xa5d5, 0x159c, 0xa938, 0xa928, + 0xa93f, 0xa940, 0xa941, 0xa933, 0xa92b, 0xa92e, 0xab11, 0xab18, + 0xab17, 0xab19, 0xab16, 0x15e6, 0xab0d, 0xab26, 0xab79, 0xabd8, + 0xabf3, 0xabd7, 0xabcc, 0xabcf, 0xabcb, 0xabd1, 0xabce, 0xabd4, + 0xabd5, 0xabd3, 0xabd6, 0xabcd, 0xabda, 0xabd2, 0xabde, 0xaccc, + 0xacb8, 0xacb7, 0xacc2, 0xacc3, 0xadfa, 0xadf9, 0xae1f, 0xae1d, + 0x6282, 0xaea6, 0xae90, 0xae9e, 0xae98, 0xae93, 0xae92, 0xaea5, + 0xae95, 0xafa9, 0xafa8, 0xafaa, 0xafab, 0xafac, + /* 0x2b */ + 0xb01f, 0xb022, 0xb0aa, 0xb096, 0xb091, 0xb0ab, 0xb0a2, 0xb0a4, + 0xb09d, 0xb097, 0xb07d, 0xb09f, 0xb09c, 0xb099, 0xb0a6, 0xb092, + 0xb0a7, 0xb1c9, 0xb1c8, 0xb1c7, 0xb1cb, 0xb274, 0xb2c9, 0x1738, + 0xb2d2, 0xb2db, 0xb2eb, 0xb2e9, 0xb2ef, 0xb2ee, 0xb2f9, 0xb2de, + 0xb416, 0xb445, 0xb47f, 0xb498, 0xb49f, 0xb486, 0xb490, 0xb49a, + 0xb49d, 0xb48d, 0xb49c, 0xb4a0, 0xb4a7, 0xb48f, 0xb641, 0xb635, + 0xb637, 0xb630, 0xb63a, 0xb636, 0xc508, 0xb6ca, 0xb712, 0xb715, + 0xb722, 0xb713, 0xb718, 0xb721, 0xb810, 0xb820, 0xb82f, 0xb8a5, + 0xb8a3, 0xb8b6, 0xb8ab, 0xb968, 0xb967, 0xb96f, 0xb977, 0xb964, + 0xb978, 0x183a, 0xb976, 0xb96e, 0x18b1, 0xbbd0, 0xbbb3, 0xbbcb, + 0xbbd6, 0xbbb1, 0xbbb4, 0xbbd7, 0xbbc6, 0xbbba, 0xbbd1, 0xbbd2, + 0xbbb5, 0xbbc4, 0xbbcc, 0xbbbb, 0xbbb2, 0xbe5b, + /* 0x2c */ + 0xbe5a, 0xbe59, 0xbe99, 0xbe94, 0xbe96, 0xbe93, 0xbe91, 0xbe8f, + 0xbe98, 0xbf0c, 0xbf0a, 0xbf0e, 0xbf12, 0xbf11, 0xbf0b, 0xbf9a, + 0x1947, 0xbfb4, 0x1951, 0xc01c, 0xc020, 0xc021, 0xc0d3, 0xc0d2, + 0xc138, 0x2afd, 0x6bcf, 0x2c1d, 0x2c92, 0x2c8f, 0x2c8c, 0x2dea, + 0x2eb9, 0x2f6e, 0x2fa0, 0xaddd, 0x3012, 0x3017, 0x306d, 0x3205, + 0x31fb, 0x31fd, 0x3206, 0x3200, 0x31ff, 0x31fe, 0x32b6, 0x3305, + 0x3307, 0x34bc, 0x34bb, 0x358b, 0x3587, 0x97fb, 0x36e7, 0x36e6, + 0x36e2, 0xa1d3, 0x36d9, 0x36ca, 0x3712, 0x3710, 0x36dc, 0x36d0, + 0x368b, 0x3713, 0x4d10, 0x36da, 0xc34f, 0x36fd, 0x36e5, 0x36cc, + 0x3739, 0x36c7, 0x36d8, 0x3a60, 0x3a64, 0x3a86, 0x3a5e, 0x3a66, + 0x3a5f, 0x3a77, 0x3a82, 0x3a96, 0x3b3e, 0x3b79, 0x3b7a, 0x3c88, + 0x3c89, 0x3c8c, 0x62e0, 0x3c7b, 0x3c86, 0x3d94, + /* 0x2d */ + 0x3d97, 0x3db7, 0x3db5, 0x3db8, 0x3d93, 0x3db2, 0x3db4, 0x3d99, + 0x3dc3, 0x3d9d, 0x3d9b, 0x3da3, 0x0347, 0x3e9f, 0x3e9e, 0x3ea3, + 0x3ea0, 0x3ea1, 0x3fc5, 0x3fc6, 0x3fbe, 0x3fc4, 0x3fbf, 0x404c, + 0x404a, 0x40b1, 0x4115, 0x4117, 0x4110, 0x4118, 0x41e0, 0x41df, + 0x4227, 0x4343, 0x4348, 0x431d, 0x4350, 0x4358, 0x4347, 0x4354, + 0x4353, 0x4340, 0x4355, 0x0417, 0x435a, 0x4870, 0x455b, 0x454d, + 0x4556, 0x454f, 0xc387, 0x4559, 0xc388, 0x4554, 0x4553, 0x4550, + 0x46b3, 0x476e, 0x04a3, 0x476f, 0x4793, 0x4829, 0x4825, 0x4828, + 0x486f, 0x54b8, 0xc397, 0x48b3, 0x4979, 0x497e, 0x497c, 0x4983, + 0xc3ac, 0x4b00, 0x4b34, 0x4b65, 0x4b36, 0x4ba7, 0x4b59, 0x4b58, + 0x4b31, 0x4b62, 0x4b38, 0x4b73, 0x4b3e, 0x4b55, 0x4b54, 0x4b95, + 0xc3ad, 0x4ba5, 0x4b94, 0x4b9a, 0x4b9b, 0x4b99, + /* 0x2e */ + 0x4b9f, 0x4b53, 0x4d12, 0x4d0a, 0x4d09, 0x4d0c, 0x4d0b, 0x4d0e, + 0x4d0d, 0x4d08, 0x4f38, 0x4f3a, 0x4f37, 0x4f3d, 0x4f2d, 0x4f82, + 0x4f95, 0x4f87, 0x4f9d, 0x4fb5, 0x4f81, 0x4fc7, 0x4f9b, 0x4f98, + 0x4f94, 0x4f86, 0x4f90, 0x4f34, 0x4f8e, 0x4f85, 0x4fa6, 0x4f96, + 0x51ea, 0x51df, 0x54bd, 0x51f7, 0x51eb, 0x51e0, 0x51e8, 0x51e1, + 0x51e9, 0x51ee, 0x51e5, 0x51ec, 0x5263, 0x52c6, 0x52c2, 0x52c1, + 0x52c0, 0x52c3, 0x5318, 0x54ae, 0x54a3, 0x54c5, 0x54a0, 0x54b4, + 0x54a5, 0x071e, 0x54a4, 0x54a8, 0x54a6, 0x57a8, 0x578d, 0x5782, + 0x579e, 0x5789, 0x5783, 0x5791, 0x57a6, 0x579a, 0x5790, 0x5785, + 0x577d, 0xc3ec, 0x579b, 0x57a5, 0x57f0, 0x5796, 0x5788, 0x57d6, + 0x57d8, 0x5786, 0x57a4, 0x5797, 0x5a1c, 0x5a19, 0x5a9e, 0x5a9f, + 0x5a9d, 0x5a9c, 0x5b5d, 0x5b5e, 0x5b73, 0x5b63, + /* 0x2f */ + 0x5bbe, 0x5bc1, 0x5bbc, 0x5bbf, 0x5bbb, 0x5bbd, 0x5c13, 0x5c14, + 0x5cf8, 0x5cfa, 0x5d06, 0x5cfe, 0x5d51, 0x600b, 0x5ff1, 0x5fa9, + 0x5fd5, 0x5fdc, 0x5fcb, 0x5ff2, 0x605f, 0x5fdb, 0x5fd6, 0x5fd9, + 0x5fd1, 0x5fcf, 0x5fd8, 0x5fe0, 0x5fd4, 0x5ff3, 0x6005, 0x5fce, + 0x5ff4, 0xc412, 0x5fda, 0x600e, 0x6006, 0x5fd7, 0x5fcd, 0x6007, + 0x5fe1, 0x6008, 0x62be, 0x62ef, 0x62d9, 0x62da, 0x1fd7, 0x62a0, + 0x62df, 0x629e, 0x62bf, 0x62af, 0x62a7, 0x62aa, 0x62f4, 0x62ae, + 0x62b5, 0x62b8, 0x62db, 0x62c0, 0x62b7, 0x62a2, 0x62dd, 0x62a1, + 0x62a5, 0x62b4, 0x62a6, 0x62ab, 0x62ac, 0x629f, 0x62b1, 0x62fc, + 0x642e, 0x6430, 0x6499, 0x64f8, 0x64f6, 0x65f4, 0x65eb, 0x65e1, + 0x65e4, 0x6775, 0x6769, 0x0a9a, 0x6799, 0x679e, 0x6794, 0x6793, + 0x6791, 0x6919, 0x6917, 0x6949, 0x6947, 0x6948, + /* 0x30 */ + 0x6952, 0x6940, 0x6963, 0x6946, 0x695f, 0x6a0e, 0x6a85, 0x6a87, + 0x6acb, 0x6acc, 0x6ac9, 0x6bcb, 0x41e7, 0x6c20, 0x6d5f, 0x6d60, + 0x6d6a, 0x6d76, 0x6d73, 0x6d71, 0x6d66, 0x0bc2, 0x6d6b, 0x6d79, + 0x6d7b, 0x6e3c, 0x6e9e, 0x6e9c, 0x6f1c, 0x6f1e, 0x6f21, 0x6f96, + 0x6fa1, 0x6fb6, 0x6fa0, 0x6f94, 0x6f97, 0x7081, 0x7086, 0x70c0, + 0x708a, 0xc44b, 0x7085, 0x7095, 0x7049, 0x7082, 0x7084, 0x4b78, + 0x7090, 0x70b1, 0x71fe, 0x71fb, 0x7350, 0x7356, 0x735a, 0x734c, + 0x0cdc, 0x7357, 0x74e1, 0x74d9, 0x74db, 0x74f4, 0x7545, 0x7547, + 0x7674, 0x766b, 0x7668, 0x7669, 0x7679, 0xc45b, 0x7680, 0x7681, + 0x7661, 0x7670, 0x766f, 0x7673, 0x765d, 0x77fa, 0x0db3, 0x77f3, + 0x780a, 0x7817, 0xc45f, 0x78b0, 0x7a3e, 0x7a46, 0x7a4f, 0x7a44, + 0x7a69, 0x7a33, 0x7a2f, 0x7a4e, 0x7a3a, 0x7a2b, + /* 0x31 */ + 0x7aa9, 0x7a50, 0x7a45, 0x7a37, 0x7a25, 0x7a2c, 0x7a3f, 0x7a34, + 0x7a29, 0x7a1e, 0x7a3d, 0x7ced, 0xc466, 0x7cf3, 0x7cea, 0x7ceb, + 0x7ecc, 0x7ece, 0x7ed0, 0x7ee3, 0x7ee0, 0x7ed1, 0x7edc, 0x7edd, + 0x7ef0, 0x7edb, 0x7ee5, 0x7ef1, 0x7ec9, 0x7ee8, 0x7ee7, 0x7ec8, + 0x7ede, 0x7ecd, 0x7ec5, 0x7ec6, 0x7ee4, 0x7ec3, 0x80fb, 0x80fc, + 0x80fe, 0x8103, 0x8100, 0x80fd, 0x8105, 0x8113, 0x81a7, 0x81b4, + 0x8270, 0x8274, 0x8271, 0x8275, 0x827d, 0x8273, 0x82c4, 0x82c3, + 0x82de, 0x82dd, 0x8311, 0x830f, 0x8310, 0x83c3, 0x83c2, 0x83ca, + 0x83c1, 0x8423, 0x85b1, 0x8624, 0x8611, 0x8625, 0x860a, 0x861f, + 0x8620, 0x8614, 0x8628, 0x8603, 0x8612, 0x860b, 0x8617, 0x4d11, + 0x8749, 0x8789, 0x8790, 0x878f, 0x8796, 0x8795, 0x8793, 0x87ed, + 0x87f0, 0x62de, 0x8885, 0x8877, 0x887a, 0x8884, + /* 0x32 */ + 0x8879, 0x887d, 0x887b, 0x88ed, 0x88ec, 0x89f6, 0x899b, 0x8a9d, + 0x8b11, 0x8ac4, 0x8ac8, 0x8adf, 0x8abf, 0x8ab3, 0x8aba, 0x8b10, + 0x8b06, 0x8a88, 0x8a9a, 0x8ae0, 0x8acc, 0x8ab5, 0x8ae1, 0x8abc, + 0x8ac6, 0x8b0b, 0x8aa4, 0x8a95, 0x8aa3, 0x8ae2, 0x8acd, 0x8ae3, + 0x8aab, 0x8acb, 0x8a8f, 0xc4ab, 0x8aa9, 0x8b24, 0x8ae4, 0x8b12, + 0x8ae5, 0x8b67, 0x8aaa, 0x8aa0, 0x8ae6, 0x8ac1, 0x8ae7, 0x8b0d, + 0x8a86, 0x8ab0, 0x8a8b, 0x8ae8, 0x8ac9, 0x8b19, 0x8ac0, 0x8b0c, + 0x8ae9, 0x8aea, 0x8ded, 0x8de3, 0x8de4, 0x8de8, 0x8dd2, 0x8de2, + 0x2466, 0x8fcf, 0x8fd1, 0x8fc3, 0x8fc9, 0x8fea, 0x8fb4, 0x8fdc, + 0x8fbd, 0x8fe6, 0x8fc8, 0x8fec, 0x8fb2, 0x8fa9, 0x8fd3, 0x8fc0, + 0x8fe9, 0x8fd5, 0x11d9, 0x8fc5, 0x11dd, 0x8fcb, 0x8fd0, 0x8fd2, + 0x8fe4, 0x8fe8, 0x8fcd, 0x8fb6, 0x8faa, 0x8fd4, + /* 0x33 */ + 0xa049, 0x8fc1, 0x8fdd, 0x8fce, 0x91c9, 0x91ca, 0x92fd, 0x92d9, + 0x92ff, 0x9304, 0x92fa, 0x9306, 0x9315, 0x9311, 0x9307, 0x930b, + 0x93fc, 0x93fd, 0x946d, 0x9465, 0x9514, 0x9513, 0x950c, 0x950b, + 0x9518, 0x9522, 0x967d, 0x966f, 0x9675, 0x967b, 0x9680, 0x967f, + 0x9696, 0x966d, 0x966b, 0x9686, 0x9673, 0x9662, 0x9677, 0x9681, + 0x9669, 0x9682, 0x9697, 0x9684, 0x12fc, 0x9678, 0xc4d0, 0x967a, + 0x966a, 0x9665, 0x967e, 0x9694, 0x97c2, 0x97c1, 0x97f9, 0x9871, + 0x986b, 0x986d, 0x986f, 0x986e, 0x98f2, 0x98e8, 0x98ef, 0x98e9, + 0x98ea, 0x98ed, 0x98f3, 0x98e6, 0x99c9, 0x99b4, 0x99b3, 0x99b9, + 0x99ca, 0x99b1, 0x99b6, 0x99c7, 0x99c4, 0x99b7, 0x9a6f, 0x9b33, + 0x9b32, 0x9b1f, 0xc4d9, 0x9b2b, 0x9b30, 0x9b36, 0x9b42, 0x9b41, + 0xc4d8, 0x9ca5, 0x9cab, 0x9ca9, 0x9cb3, 0x9ca7, + /* 0x34 */ + 0x9ca0, 0x9cd2, 0x9ca8, 0x9cb6, 0x9cac, 0x9cae, 0x9ce6, 0x9e65, + 0x9f47, 0x9f63, 0x9f4d, 0x9f5f, 0x9f4b, 0x9f60, 0x9f49, 0x9f53, + 0xc4df, 0x263a, 0x9f57, 0x9f4e, 0x9f52, 0x9f54, 0xa020, 0xa022, + 0xa1c1, 0xa1d7, 0xa1d5, 0xa1c4, 0xa1d0, 0xa1bb, 0xa1e2, 0xa1cb, + 0xa1b8, 0xa1bf, 0xa1d8, 0xa1c0, 0xa1ba, 0xa1b4, 0xa1bc, 0xa1d4, + 0xa1ed, 0xa1c2, 0xa1d9, 0xa1cc, 0xa32f, 0xa323, 0xa396, 0xa38d, + 0xa39e, 0xa399, 0xa483, 0x1507, 0xa46a, 0xa469, 0xa475, 0xa46c, + 0xa480, 0xa46e, 0xa481, 0xa477, 0xa476, 0xa473, 0xa470, 0xa484, + 0xa519, 0xa5f2, 0x273d, 0xa5ec, 0xa5eb, 0xa5f6, 0xa5ef, 0xa5f4, + 0xa5ee, 0xa5f3, 0xa5ed, 0xa89b, 0xa898, 0xa894, 0x3a7a, 0xa89a, + 0xc4f0, 0xa94c, 0x15a8, 0xa957, 0xa951, 0xa962, 0xa952, 0xa95c, + 0xa953, 0xc4ef, 0xaa85, 0xab2d, 0xab3e, 0xab30, + /* 0x35 */ + 0xab7d, 0xabe6, 0xabf6, 0xabe4, 0xabe9, 0xabec, 0xabf2, 0xabe8, + 0xabe3, 0xabeb, 0xabf0, 0xabea, 0xabe7, 0xabfd, 0xabe5, 0xabee, + 0xabf5, 0xabf9, 0xabf1, 0xabf4, 0xc4f4, 0xac11, 0xacde, 0xacd8, + 0xacdd, 0xacdb, 0xacd3, 0xace1, 0xadde, 0xadfc, 0xae28, 0xaeb7, + 0xaeb8, 0xaec7, 0xaeb2, 0xaea9, 0xaeb9, 0xaebc, 0xaeb3, 0xaed1, + 0xafb0, 0xafb1, 0xafb6, 0xb004, 0xb02c, 0xb0c1, 0xb09e, 0xb0ba, + 0x16ca, 0xb0d1, 0xb0d3, 0xb0d4, 0xb0d5, 0xb0c5, 0xb0b6, 0xb0b2, + 0xb0b5, 0xb0c3, 0xb0b9, 0xb0c6, 0xb1d6, 0xb1e0, 0xb1db, 0xb1d7, + 0xb1dd, 0xb315, 0xb30c, 0xb30f, 0xb30e, 0xb2fe, 0xb304, 0xb30b, + 0xb302, 0xb2ff, 0xb308, 0xb310, 0xb317, 0xb313, 0xb306, 0xb309, + 0xb424, 0xb426, 0xb425, 0xb448, 0xb4b5, 0xb4d2, 0xb4d5, 0xb4c4, + 0xb4af, 0xb4ad, 0xb4c1, 0xb4c0, 0xb4cc, 0xb4cd, + /* 0x36 */ + 0xb4c3, 0xb4c8, 0xb4c5, 0xb4ba, 0xb4d0, 0xb4c2, 0xb4ce, 0x178d, + 0xb643, 0xb642, 0xb640, 0xb631, 0xb6cf, 0xb6ce, 0xb730, 0xb734, + 0xb732, 0xb743, 0xb73c, 0xb811, 0xb835, 0xb834, 0xb837, 0xb831, + 0xb8bf, 0xb8bc, 0xb8c2, 0xb8c9, 0xb983, 0xb98b, 0xb9a0, 0xb98d, + 0xb98c, 0xb99a, 0xb98a, 0xb991, 0xbbf1, 0xbc0f, 0xbc01, 0xbc07, + 0xbc0c, 0x18c0, 0xbbdc, 0xbbee, 0xbbf7, 0xbbf2, 0xbbf8, 0xbbeb, + 0x18ca, 0xbbe6, 0xbbed, 0xbbe9, 0xbc08, 0xbc00, 0xbbe5, 0xbbfc, + 0xbe61, 0xbe5e, 0xbe5f, 0x1925, 0xbe9b, 0xbf16, 0xbf15, 0xbf20, + 0xbf14, 0xbf1a, 0xbf17, 0xbf9c, 0x194a, 0xbff1, 0x1953, 0xbff0, + 0xc028, 0xc024, 0xc02a, 0xc02b, 0xc0d5, 0xc104, 0xc105, 0xc191, + 0xc192, 0xc2a6, 0x2c09, 0x2e22, 0x2e1a, 0x2e0e, 0x2e1b, 0x2e08, + 0x6fb3, 0xc31c, 0x309d, 0x3212, 0x321e, 0x32bb, + /* 0x37 */ + 0x32bf, 0x32bc, 0x3308, 0x3309, 0x3363, 0x33c8, 0x5828, 0x358e, + 0x358d, 0x3743, 0x374d, 0x376d, 0x3742, 0x3752, 0x3751, 0x3769, + 0x3750, 0x3756, 0x376c, 0x3744, 0x3745, 0x376b, 0x0205, 0x3768, + 0x3757, 0x392e, 0x3931, 0x392d, 0x3a8b, 0x3ab2, 0x3a8d, 0x3aa3, + 0x3aa4, 0x3a90, 0x3a89, 0x3a8e, 0x3a92, 0x3b7b, 0x3c90, 0x3c8f, + 0x3de9, 0x3dcd, 0x3dc5, 0x3dd0, 0x3dc9, 0x3dd1, 0x3dc7, 0x3dd2, + 0x3d5f, 0x3de1, 0x3dcc, 0x3dc6, 0x3de4, 0x3ea9, 0x3fd3, 0x3fda, + 0x3fd2, 0x3fdb, 0x404d, 0x404e, 0x411c, 0x41e8, 0x436c, 0x435f, + 0x4366, 0x4364, 0x4378, 0x4365, 0x436d, 0x4361, 0x437a, 0x4407, + 0x4566, 0x4568, 0x4562, 0x46d3, 0x46d4, 0x46d1, 0x46dc, 0x4773, + 0x4772, 0x482d, 0x482c, 0x482f, 0x4872, 0x48b4, 0x4989, 0x4bcd, + 0x4ba6, 0x4ba2, 0x4ba0, 0x4b46, 0x4ba1, 0x8657, + /* 0x38 */ + 0x4ba3, 0x4bb1, 0x4bdb, 0x4bf6, 0x4bdc, 0x4bd6, 0x4d13, 0x4f9c, + 0x4f97, 0x4fd8, 0x4fe4, 0x4fd4, 0x4fe5, 0x4fdb, 0x4fd0, 0x4fda, + 0x4fcc, 0x4fdc, 0x4fed, 0x4fd3, 0x4fd1, 0x4fce, 0x4fd9, 0x4fdd, + 0xc3c6, 0x50e6, 0x50e5, 0x50e9, 0x51ff, 0x51fe, 0x520e, 0x528c, + 0x52ca, 0x52cb, 0x531a, 0x54d7, 0x54cf, 0x54d0, 0x54c9, 0x54cc, + 0x54d3, 0x55a4, 0x55a3, 0x5781, 0x5826, 0x57f3, 0x5827, 0x57f2, + 0x57ff, 0x57f5, 0x57fc, 0x580e, 0x07f0, 0x57f6, 0x5800, 0x5823, + 0x5805, 0x5825, 0x5808, 0x5850, 0x5a25, 0x5a20, 0x5a23, 0x5a21, + 0x5aa1, 0x5b69, 0x5b6c, 0x5b68, 0x5b6b, 0x5bcc, 0x5bcd, 0x5d10, + 0x5d0d, 0x5d0a, 0x5d16, 0x5d14, 0x5d52, 0x6028, 0x602e, 0x602c, + 0x604d, 0x6049, 0x6031, 0x6030, 0x6033, 0x602d, 0x6036, 0x603e, + 0x602f, 0x6027, 0x6034, 0x604c, 0x62fe, 0x6312, + /* 0x39 */ + 0x631f, 0x6317, 0x62f5, 0x6315, 0x62f7, 0x0a02, 0x437d, 0x62fa, + 0x62f9, 0x634b, 0x649c, 0x649d, 0x0a23, 0x65f0, 0x65f6, 0x65ef, + 0x679d, 0x679a, 0x67a7, 0x67af, 0x67aa, 0x6964, 0x6986, 0x6975, + 0x6970, 0x6984, 0x696b, 0x6985, 0x696c, 0x6a17, 0x6a94, 0x6a93, + 0x6bd2, 0x6bd7, 0x6bd4, 0x6da6, 0x6da7, 0x6d9c, 0x6d8b, 0x6d8d, + 0x6d98, 0x6db9, 0x6d9b, 0x6d9d, 0x6d99, 0x6da8, 0x6d91, 0x6d87, + 0x6d9a, 0x6ea6, 0x6f1f, 0x6fa7, 0x6fb1, 0x6fb2, 0x6fb7, 0x70d0, + 0x70b3, 0x70b5, 0x70c4, 0x70c3, 0x70bc, 0x70b2, 0x70ba, 0x70bb, + 0x70c2, 0x70cd, 0x70be, 0x70b7, 0x718f, 0x7203, 0x7204, 0x7371, + 0x7377, 0x7374, 0x738b, 0x737a, 0xc451, 0x738c, 0x7373, 0x74ff, + 0x74fb, 0x74fd, 0x74f0, 0x74f3, 0x74fc, 0x74f2, 0x7692, 0x769e, + 0x76ae, 0x7696, 0x7814, 0x7812, 0x7813, 0x7816, + /* 0x3a */ + 0x780f, 0x78b6, 0x78bd, 0x7a8c, 0x7aae, 0x7aac, 0x7aab, 0x7a99, + 0x7a92, 0x7abb, 0x7a9e, 0x7a7e, 0x7aaf, 0x7abc, 0x7a98, 0x7d01, + 0x7d09, 0x7d06, 0xc467, 0x7d07, 0x7d08, 0x7ecf, 0x7f0e, 0x7f32, + 0x0f15, 0x7f12, 0x7f16, 0x7f17, 0x7f1b, 0x7f15, 0x7f31, 0x7f18, + 0x7f1a, 0x7f10, 0x7f0a, 0x7f09, 0x804f, 0xc473, 0x810f, 0x8110, + 0xc475, 0x8128, 0x8111, 0x8116, 0x8117, 0x8102, 0x81bb, 0x81ba, + 0x81c3, 0x81bc, 0x828a, 0x8284, 0x8286, 0x82e0, 0x8317, 0x8318, + 0x831e, 0x8315, 0x83d3, 0x83da, 0x83d9, 0x85e6, 0x85f4, 0x85e1, + 0x8669, 0x8640, 0x8658, 0x866c, 0x864d, 0x8721, 0x8799, 0x87f1, + 0x5f68, 0x8886, 0x8b5b, 0x8b5c, 0x8b77, 0x8b2c, 0xc4ad, 0x8b58, + 0x8b64, 0x8b61, 0x8b48, 0x8b97, 0x8b59, 0x8b29, 0x8b62, 0x8b2e, + 0x8b68, 0x8b90, 0x8b3a, 0x8b3d, 0x8b5e, 0x8b46, + /* 0x3b */ + 0x8b69, 0x8b65, 0x8b3e, 0x8b49, 0x8b56, 0x8be1, 0x8b78, 0x8b79, + 0x8b66, 0x8b4a, 0x8b35, 0x8b7a, 0x8b92, 0x8b60, 0x8b36, 0x8b51, + 0x8b42, 0x115d, 0x8b3f, 0x8b7b, 0x8b5d, 0x8b94, 0x8b6a, 0xc4b5, + 0x8df2, 0x8fbb, 0x901b, 0x901a, 0x9033, 0x9017, 0x900a, 0x9015, + 0x9012, 0x9001, 0x902d, 0x8ffd, 0x9023, 0x9005, 0x9011, 0x9000, + 0x901c, 0x9035, 0x902e, 0x9036, 0x34bf, 0x902f, 0x900c, 0x9009, + 0x9031, 0x8ffc, 0x900f, 0x9018, 0x9002, 0x9200, 0x931f, 0x9337, + 0x125a, 0x9338, 0x932b, 0x932e, 0x9321, 0x9330, 0x9329, 0x9331, + 0xc4c9, 0x9301, 0x932c, 0x9322, 0x93ff, 0x9477, 0x9467, 0x947f, + 0x947d, 0x947b, 0x947e, 0x951e, 0x951c, 0x9521, 0x9526, 0x9527, + 0x9529, 0x952c, 0x951d, 0x952b, 0x96bf, 0x96a4, 0x96aa, 0x96ae, + 0x969f, 0x96d0, 0x96b1, 0x96ad, 0x969b, 0x96b2, + /* 0x3c */ + 0x96a9, 0x96b3, 0x96b4, 0x96ba, 0x96a5, 0x96b7, 0x96ac, 0x96cb, + 0x96cf, 0x97c6, 0x9801, 0x97ff, 0x97fd, 0x9877, 0x9878, 0x9876, + 0x98f7, 0x99cc, 0x1385, 0x99d4, 0x99d7, 0x99d5, 0x99d6, 0x99d3, + 0x9b5d, 0x9b55, 0x9ce0, 0x9d48, 0x9cee, 0x9cdb, 0x9ce7, 0x9cd6, + 0x9ce5, 0x9ce1, 0x9cdd, 0x9ce2, 0x9e70, 0x9e66, 0x9e6f, 0x9e6e, + 0x9f81, 0x9f69, 0x9f6e, 0x9f6d, 0x9f6c, 0x9f84, 0x9f85, 0x9f71, + 0x9f73, 0x9f6a, 0x9f6f, 0x9f7b, 0xa16a, 0xa17c, 0xa17d, 0xa181, + 0xa1fa, 0xa205, 0xa1eb, 0xa1fb, 0xa1e9, 0xa1ef, 0xa1fc, 0xa1e7, + 0xc4e1, 0xa1ee, 0xa1fd, 0xa332, 0xa3a7, 0xa3b5, 0xa3b1, 0xa3b9, + 0xa3a8, 0xa3b3, 0xc4e6, 0xa48a, 0xa491, 0xa48d, 0xa499, 0x150b, + 0xa49a, 0xa49b, 0xa492, 0xa48f, 0xa4ab, 0x6bdb, 0x1539, 0xa675, + 0xa631, 0xa638, 0x1537, 0xa635, 0xa669, 0xa63b, + /* 0x3d */ + 0xa63d, 0xa66c, 0xa679, 0xa63c, 0xa63e, 0xa897, 0xa8a5, 0xa8a2, + 0xa89d, 0xa8a1, 0xa968, 0xa96f, 0xa96d, 0xa972, 0xa975, 0xa977, + 0xa979, 0xaab5, 0xaaea, 0xaaab, 0xab43, 0xab41, 0xab42, 0xac09, + 0xac08, 0xac06, 0xac01, 0xac03, 0xac00, 0xac04, 0xac0a, 0xac0e, + 0xac0d, 0xac07, 0xac0f, 0xac14, 0xac02, 0xac15, 0xac0c, 0xac10, + 0xac05, 0xacfd, 0xacff, 0xad04, 0xad00, 0xad09, 0xae2b, 0xc4f7, + 0xae31, 0xaedb, 0xaec5, 0xaed3, 0xaece, 0x166b, 0xaec9, 0xaebf, + 0xaecb, 0xaec0, 0xaed0, 0xaed4, 0xafc1, 0xafb9, 0xafbb, 0xafc3, + 0xafc9, 0xb007, 0xb02d, 0xb0f8, 0xb0e1, 0xb0fa, 0xb0ef, 0xb0fd, + 0x16cd, 0xb0eb, 0xb0f1, 0xb0ed, 0xb0fe, 0xb1f8, 0xb203, 0xb1ee, + 0xb1e8, 0xb201, 0xb2ec, 0xb322, 0xb314, 0xb334, 0xb32f, 0xb339, + 0xb341, 0xb33c, 0xb349, 0xb358, 0xb33a, 0xb342, + /* 0x3e */ + 0xb33f, 0xb422, 0xb423, 0xb44a, 0xb4dc, 0xb4d9, 0xb4db, 0xb4e2, + 0xc507, 0xb4df, 0xb4e0, 0xb4d7, 0xb64f, 0xb646, 0xb653, 0xb655, + 0xb64e, 0xb64a, 0xb64c, 0xb663, 0xb751, 0xb753, 0xb758, 0xb74d, + 0xb75a, 0xb749, 0xb75d, 0xb812, 0xb83c, 0xb8d1, 0xb8df, 0xb8d6, + 0xb8d8, 0xb8e0, 0xb8d9, 0xb9b1, 0xb9ac, 0xb9aa, 0xb9ee, 0xb9bd, + 0x184d, 0xb9c3, 0xb9a8, 0xb9ae, 0xb9ab, 0xbc1d, 0xbc27, 0xbc38, + 0xbc12, 0xbc48, 0xbc2b, 0xbc16, 0xbc19, 0xbc3d, 0xbc23, 0xbc2a, + 0xbe64, 0xbead, 0xbeac, 0xc514, 0xbeb1, 0xbeaf, 0xbf2c, 0xbf24, + 0xbf25, 0xbf28, 0xbff9, 0xbff7, 0xbffd, 0xbffe, 0xc039, 0xc033, + 0xc0d7, 0xc0d8, 0xc0e4, 0x3aa1, 0xc10e, 0xc13b, 0xc144, 0xc142, + 0xc194, 0xc193, 0xc1d5, 0xc2a7, 0x2e31, 0x2e23, 0x2e28, 0x2e27, + 0x2ec6, 0x2fa3, 0x3021, 0x321b, 0x0110, 0x32c1, + /* 0x3f */ + 0x32c3, 0x332a, 0x3369, 0x3427, 0x37b6, 0x37a7, 0x37a4, 0x37a6, + 0x3790, 0x379e, 0x3794, 0x37a8, 0x37a5, 0x37a2, 0x3791, 0x027b, + 0x3abc, 0x3abd, 0x3ab4, 0x3ab0, 0x3ae4, 0x3b45, 0x3b4b, 0x3b7e, + 0x3b7f, 0x3b7d, 0x3bc3, 0x3dfc, 0x3df7, 0x3df0, 0x3ded, 0x3df1, + 0x3df8, 0x3fe9, 0x41eb, 0x041d, 0x4390, 0x438d, 0x4386, 0x4391, + 0x438a, 0x4408, 0x4450, 0x46ea, 0x46e6, 0x46e2, 0x46e7, 0x46ed, + 0x46e1, 0x4834, 0x4876, 0x4875, 0x4873, 0x48b5, 0x4990, 0x4992, + 0x4be1, 0x4bdf, 0x4bd5, 0x4bf2, 0x4bfe, 0x4c13, 0x4c2e, 0x4d19, + 0x5008, 0x1df5, 0x5005, 0x5009, 0x5006, 0x5003, 0x4ffd, 0x4ffc, + 0x5002, 0x5042, 0x521a, 0x5211, 0x5215, 0x5216, 0x52cc, 0x52cf, + 0x52d0, 0x5322, 0x531e, 0x5321, 0x54e5, 0x0727, 0x5554, 0x54ef, + 0x5553, 0x5551, 0x55ad, 0x5867, 0x5868, 0x58a4, + /* 0x40 */ + 0x5877, 0x5889, 0x5844, 0x588b, 0x5879, 0x585b, 0x5843, 0x5857, + 0x584a, 0x587c, 0x5846, 0x587b, 0x5856, 0x5aa8, 0x5b76, 0x5b72, + 0x5bd6, 0x5bd8, 0x5bd1, 0x5d22, 0x5d20, 0x5d23, 0x5d1e, 0x5d6e, + 0x60a3, 0x6077, 0x60a6, 0x606d, 0x60a2, 0x607c, 0x6084, 0x6068, + 0x6074, 0x6086, 0x60a5, 0x607b, 0x607a, 0x6069, 0x6072, 0x6076, + 0x634a, 0x6337, 0x632a, 0x632d, 0x6346, 0x6328, 0x6326, 0x6342, + 0x632c, 0x6338, 0x632b, 0x6333, 0x6345, 0x6439, 0x65f9, 0x65fa, + 0x67b8, 0x67b7, 0x67bb, 0x67b9, 0x67b4, 0x696f, 0x6987, 0x698f, + 0x69a2, 0x69a3, 0xc431, 0x6a9b, 0x6a9d, 0x6ace, 0x0bcf, 0x6dbd, + 0x6dbf, 0x6d92, 0x0bcd, 0x6def, 0x6dc9, 0x6ea4, 0x6ea8, 0x6eaa, + 0x6f28, 0x6f24, 0x6f25, 0x6f26, 0x6fa9, 0x6fba, 0x6fbe, 0x6fbc, + 0x6fc0, 0x70f0, 0x70df, 0x70e0, 0x70ed, 0x70db, + /* 0x41 */ + 0x70fb, 0x70b9, 0x70da, 0x70eb, 0x70ec, 0x739a, 0x739f, 0x739b, + 0x7397, 0x73a1, 0x750f, 0x7505, 0x7548, 0x0d82, 0x76bc, 0x76ba, + 0x78bf, 0x7b01, 0x7ae8, 0x7aef, 0x7ae4, 0x7ae6, 0x7b02, 0x7aeb, + 0x7ae0, 0x7aed, 0x7ad9, 0xc464, 0x7b14, 0x7aee, 0x0e52, 0x7b13, + 0x7af9, 0x7af8, 0x7d25, 0xc469, 0x7d19, 0x7d20, 0x7d43, 0x7d3f, + 0x7f45, 0x7f4c, 0x7f49, 0x7f4f, 0x7f41, 0x7f3e, 0x7f4d, 0x7f52, + 0x7f4a, 0x7f4e, 0x7f73, 0x7f42, 0x7f51, 0x7f55, 0x7f50, 0x7f6c, + 0x2afd, 0x7f6a, 0x7f53, 0x7f68, 0x8055, 0x8056, 0x811c, 0x811d, + 0x2280, 0x811e, 0x8123, 0x811f, 0x81e1, 0x81cd, 0x81cb, 0x81cc, + 0x81c8, 0x81c9, 0x829b, 0x8294, 0x8292, 0x8296, 0x8293, 0x8295, + 0x828f, 0x831d, 0x8322, 0x8321, 0x83e9, 0x83ef, 0x83e0, 0x83e6, + 0x83e4, 0x8629, 0x862c, 0x8676, 0x8683, 0x8678, + /* 0x42 */ + 0x863c, 0x6343, 0x867a, 0x1051, 0x86f2, 0x879e, 0x879b, 0x879a, + 0x87f6, 0x87f5, 0x88a5, 0x8893, 0x88a4, 0x8a82, 0x8ac7, 0x8bb7, + 0x8c1d, 0x8be2, 0x8bd7, 0x8be3, 0x8be4, 0x8bbc, 0x8bd3, 0x115a, + 0x8b5a, 0x8bd2, 0x8b2d, 0xc4af, 0x8bc4, 0x8bd0, 0x8be5, 0x8c05, + 0x8c07, 0x8be6, 0x8c1b, 0x8be7, 0x8bd8, 0x8bbe, 0x8c17, 0x8bb4, + 0x8bd9, 0x8be8, 0x8bad, 0x8baf, 0x8bc8, 0x8be9, 0x8bea, 0x8dfe, + 0x8dfb, 0x8e00, 0x9072, 0x9070, 0x9046, 0x9059, 0x905e, 0x9048, + 0x904f, 0x9071, 0x9060, 0x905f, 0x906e, 0x9073, 0xc4c0, 0xc4bf, + 0x9047, 0x906d, 0x906f, 0x9081, 0x906c, 0x9078, 0x9083, 0x9049, + 0x9068, 0x9074, 0x9063, 0x906a, 0x8685, 0x9065, 0x9062, 0x90c8, + 0x91d0, 0x91d4, 0x91d1, 0x9203, 0x9342, 0x9363, 0x9356, 0x935b, + 0x9355, 0x9350, 0x932d, 0x9344, 0x9348, 0x9345, + /* 0x43 */ + 0x9382, 0x1265, 0x9362, 0x9485, 0x948d, 0x9536, 0x952f, 0x9531, + 0x9537, 0x96a7, 0x96d9, 0x96f0, 0x96f2, 0x96fd, 0x96e8, 0x96eb, + 0x96ee, 0x96e0, 0x96e9, 0x96ed, 0x96d6, 0x96f8, 0x96d4, 0x96df, + 0x96e7, 0x96d8, 0x96e3, 0x96ef, 0x970f, 0x97ca, 0x3b46, 0x9805, + 0x980c, 0x980d, 0x987f, 0x9880, 0x9881, 0x9901, 0x9903, 0x99f2, + 0x99e2, 0x99e3, 0x99de, 0x99e9, 0x99e8, 0x99e0, 0x9a01, 0x99f5, + 0x99e4, 0x2501, 0x9a77, 0x9b74, 0x9b6f, 0x9b62, 0x9b61, 0x9b6d, + 0x9b73, 0x9b6a, 0x9b69, 0x9d12, 0x9d2d, 0x9d14, 0x9d0f, 0x9d29, + 0x9d16, 0x9d03, 0x9d46, 0x9d5c, 0x9d11, 0x9d06, 0x9cdc, 0x9d2b, + 0x9d2a, 0x9d2c, 0x9d27, 0x9e7a, 0x9f9c, 0x9f99, 0x9f95, 0x9f8b, + 0x9f98, 0x9f96, 0xa032, 0xa1a4, 0xa1aa, 0xa21b, 0x14af, 0xa20d, + 0xa21c, 0xa20a, 0xa220, 0xa208, 0xa21a, 0xa213, + /* 0x44 */ + 0xa211, 0xa35d, 0xa35f, 0xa35e, 0xa360, 0xa3bb, 0xa3bc, 0xa3c1, + 0xa3c0, 0xa3c8, 0xa3ce, 0xa4a7, 0xa4b2, 0xa4b6, 0xa4a5, 0xa4ba, + 0xa4b5, 0xa4ad, 0xa4a4, 0xa4d3, 0xa4b0, 0xa4b1, 0xa51d, 0xa68d, + 0x1541, 0xa691, 0xa6b6, 0xa6b7, 0xa6bd, 0xa6bc, 0xa696, 0xa694, + 0xa6a0, 0xa8a8, 0xa8a6, 0xa984, 0xa996, 0xa988, 0xa99a, 0xaad1, + 0xaacf, 0xab50, 0xab51, 0xab4e, 0xab80, 0xab81, 0xac1b, 0xac17, + 0xac20, 0xac19, 0xac1a, 0xac21, 0xac1e, 0xac18, 0xac1d, 0x1629, + 0xad2d, 0xad24, 0xad27, 0xad2e, 0xad25, 0xad1c, 0xad19, 0x162a, + 0xad23, 0xad1f, 0xad1a, 0xad2b, 0xad1e, 0xade0, 0xae33, 0xaee6, + 0xaefc, 0xaee5, 0xaef8, 0xaef6, 0xaeea, 0xaef2, 0xaeed, 0xaeeb, + 0xaef0, 0xaef1, 0xafc6, 0xafc8, 0xafce, 0xafc5, 0x1696, 0xafcb, + 0xb113, 0xb114, 0xb107, 0xb10c, 0xb21a, 0x1712, + /* 0x45 */ + 0xb217, 0xb206, 0xb216, 0xb207, 0xb210, 0xb209, 0xb219, 0xb215, + 0xb36e, 0xb33b, 0xb33e, 0xb36c, 0xb365, 0xb364, 0xb359, 0xb37c, + 0xb370, 0xb379, 0xb42c, 0xb452, 0xb451, 0xb44c, 0xb500, 0xb510, + 0xb513, 0xb4ff, 0xb4fe, 0xb4ed, 0xb65a, 0xb658, 0xb65c, 0xb6da, + 0xb778, 0xb75e, 0xb767, 0xb764, 0xb813, 0xb823, 0xb841, 0xb83f, + 0xb840, 0xb8ed, 0xb8e3, 0xb8ea, 0xb8f0, 0xb8e6, 0xb8e9, 0xb8f1, + 0xb8ee, 0xb9d4, 0xb9d1, 0xb9dc, 0xb9ec, 0xbc69, 0xbc6d, 0xbc57, + 0xbc66, 0xbcf9, 0xbc4a, 0xbc60, 0xbc56, 0xbc59, 0xbc4c, 0xbc6a, + 0xbc62, 0xbc63, 0xbc70, 0xbc5f, 0xc50d, 0xbc64, 0xbc5d, 0xbc68, + 0xbc9f, 0xbeba, 0xbeb8, 0xbebc, 0xbeb9, 0xbeb4, 0xbf3b, 0xbf2d, + 0xbf38, 0xbf2f, 0xbf32, 0xc041, 0xc0cb, 0xc0de, 0xc0dd, 0xc0da, + 0xc0dc, 0xc110, 0xc14f, 0xc149, 0xc198, 0xc196, + /* 0x46 */ + 0xc197, 0xc1c7, 0x2c9c, 0xc1da, 0xc1d8, 0xc2a8, 0x2c0a, 0x2c9d, + 0x2ecb, 0x2f38, 0x2f39, 0x2fa6, 0x3223, 0x3222, 0x3221, 0x33ce, + 0x3592, 0x3591, 0x37ec, 0x37e0, 0x37ed, 0x3808, 0x37e5, 0x37ee, + 0x37e4, 0x37eb, 0x37e3, 0x37ea, 0x380a, 0xc359, 0x3ad1, 0x3ae3, + 0x3ad4, 0x3ad0, 0x3ad9, 0x027e, 0x1be1, 0x3ada, 0x3ad3, 0x3b4c, + 0x3b4d, 0x3b7c, 0x3b80, 0x3bcc, 0x3dff, 0x3e08, 0xc108, 0x3e01, + 0xc36b, 0x3e00, 0x3fed, 0x3ff3, 0x3fee, 0x3ff1, 0x3ff0, 0x3fde, + 0x4051, 0x4382, 0x43a9, 0x4398, 0x439d, 0x439a, 0x439e, 0x439f, + 0x43a6, 0x43a7, 0x4409, 0x442f, 0x4571, 0x456d, 0x4572, 0x46ef, + 0x46f0, 0x483b, 0x4839, 0x483c, 0x4838, 0x6afd, 0x483a, 0x4878, + 0x4879, 0x4877, 0x4998, 0x499c, 0x4999, 0x499a, 0x4c11, 0x4c0a, + 0x4bfd, 0x4c0f, 0x4c19, 0x4c03, 0x4c15, 0x4c0c, + /* 0x47 */ + 0x4c09, 0x4c12, 0x4c34, 0x4c2a, 0x4c08, 0x4c2d, 0x4c28, 0xc3b1, + 0x4c2c, 0x4c26, 0x4c33, 0x05a7, 0x4d1a, 0x4d1e, 0x5007, 0x502c, + 0x5032, 0x5028, 0x5031, 0x5029, 0x5030, 0x502a, 0x5044, 0x502e, + 0x52d1, 0x5324, 0x54f7, 0x54f4, 0x54f3, 0x54f8, 0x58b5, 0x5896, + 0x5898, 0x5895, 0x5891, 0x58b2, 0x589e, 0x5859, 0x58a3, 0x589a, + 0x589b, 0x0f20, 0x7f83, 0x5bda, 0x5bdf, 0x5c16, 0x5d1f, 0x5d2d, + 0x5d2e, 0x5d2b, 0x60b8, 0x60bb, 0x60bf, 0x60ba, 0x60d5, 0x60e3, + 0x60c1, 0x60be, 0x60bd, 0x60b4, 0x60c2, 0x60a1, 0x6087, 0x60d7, + 0x60ca, 0x60b5, 0x60da, 0x60d9, 0x60b3, 0x60d8, 0x6367, 0x6371, + 0x6362, 0x635c, 0x6368, 0x6352, 0x6356, 0x3809, 0x2e42, 0x64a0, + 0x6600, 0x65fe, 0x65ff, 0x67cb, 0xc428, 0x67ca, 0x67a9, 0x67c8, + 0x69b4, 0x69ac, 0x69aa, 0x69a9, 0x6b0e, 0x6be9, + /* 0x48 */ + 0x6bed, 0x6bf2, 0x6beb, 0x6bee, 0x6de8, 0x6ddb, 0x6dd7, 0x6de3, + 0x6de5, 0x6dee, 0x6dd5, 0x6eb3, 0x6f2d, 0x6fc1, 0x6fc3, 0x710c, + 0x710e, 0x7107, 0x7117, 0x7109, 0x7116, 0x719a, 0x719c, 0x73b4, + 0x73b7, 0x73b3, 0x3b4e, 0x7513, 0x7514, 0x76e6, 0x76dc, 0x76e8, + 0x76e5, 0x782e, 0x782c, 0x782b, 0x78cd, 0x7b3d, 0x7b32, 0x7b2d, + 0x7b45, 0x7b3e, 0x7b50, 0x7b25, 0x7b53, 0x7b23, 0x7d37, 0x7d38, + 0x7d47, 0x7d3d, 0x7d3e, 0x7d49, 0x7d4a, 0x7d1d, 0x21e9, 0x7fa5, + 0x7f8c, 0x7f8d, 0x7f89, 0x7f96, 0x7f85, 0x7f8f, 0x7f77, 0x7f8e, + 0x7f82, 0x7f8a, 0x7f88, 0x7f7b, 0x7f97, 0x7f7d, 0x7f79, 0x8059, + 0x8124, 0x812d, 0x812e, 0x812b, 0xc476, 0x81da, 0x81d8, 0x81d6, + 0x8287, 0x82a0, 0x8328, 0x8325, 0x831f, 0x83f3, 0x83f7, 0x83f6, + 0x862b, 0x865b, 0x8648, 0x23cb, 0x865c, 0x866d, + /* 0x49 */ + 0x869d, 0x8699, 0x868c, 0x8691, 0x869b, 0x869a, 0x869c, 0x8695, + 0x868d, 0x8696, 0x86a5, 0x872a, 0x87a1, 0x87a4, 0x87ad, 0x88a9, + 0x88ae, 0x88b0, 0x8c0d, 0x8b63, 0x8b71, 0x8c51, 0x8c54, 0x8c2a, + 0x8c44, 0x8c55, 0x8c99, 0x8c39, 0x8c3f, 0x8c3e, 0x8c4f, 0x8c4d, + 0x8c35, 0x8c40, 0x8c31, 0x8bd5, 0x8c2b, 0x8c33, 0x8c41, 0x8c56, + 0x8c4c, 0x8c46, 0x8c3c, 0x8c45, 0x8c43, 0x8c3d, 0x8c70, 0x8c57, + 0x8c38, 0x8c58, 0x1165, 0x8c37, 0x8e07, 0x8e06, 0x8e09, 0x90ab, + 0x9090, 0x9093, 0x90bc, 0x90a9, 0x909e, 0x90bf, 0x90aa, 0x9091, + 0x90a4, 0x909a, 0x90a7, 0x90a1, 0x909c, 0x90a2, 0x909b, 0x909f, + 0x9094, 0x908f, 0x8ef0, 0x9092, 0x9095, 0x90a5, 0x90a6, 0x9204, + 0x939c, 0x9379, 0x937a, 0x937e, 0x937b, 0x9371, 0x9381, 0x937f, + 0x937c, 0x937d, 0x9375, 0x9376, 0x948e, 0x948f, + /* 0x4a */ + 0x953e, 0x953f, 0x9540, 0x9541, 0x1304, 0x970d, 0x9717, 0x9710, + 0x970e, 0x96ea, 0x971d, 0x9703, 0x9722, 0x9704, 0x9700, 0x9720, + 0x9721, 0x9723, 0x9713, 0x9709, 0x9711, 0x97cb, 0x97ce, 0x97d0, + 0x97cc, 0x97d4, 0x3adb, 0x9809, 0x980b, 0x9885, 0x9906, 0x990d, + 0x1364, 0x9914, 0x990f, 0x9a09, 0x9a14, 0x9a0b, 0x99fc, 0x9a04, + 0x9a0a, 0x9a00, 0x99fd, 0x9a07, 0x9a06, 0x9a11, 0x9a79, 0x9a78, + 0x9b88, 0x9b80, 0x9b8b, 0x9d59, 0x9d61, 0x9d75, 0x1423, 0x9d55, + 0x9d5b, 0x9d5f, 0x9d52, 0x9d62, 0x9d72, 0x9d5d, 0x9d68, 0x9d71, + 0x9d65, 0x9d66, 0x9d67, 0x9d76, 0x9d4c, 0x9d60, 0x9d74, 0x9d50, + 0x9e8a, 0x9e81, 0x9e86, 0x9e7f, 0x9e80, 0x9fa5, 0x9fa7, 0x9fa8, + 0x9fa6, 0x9faf, 0x7f95, 0x9fb1, 0xa035, 0xa039, 0xa1c3, 0xa230, + 0xa22a, 0xa22b, 0xa22d, 0xa22e, 0xa22c, 0xa223, + /* 0x4b */ + 0xa221, 0xa222, 0xa36c, 0xa381, 0xa38f, 0xa380, 0xa3d0, 0xa3cd, + 0xa3d5, 0xa3d4, 0xa4d1, 0xa4be, 0xa4cb, 0xa4ce, 0xa4bd, 0xa4d0, + 0xa704, 0xa6d5, 0xa6d0, 0xa6d3, 0xa6fb, 0xa6d8, 0xa6d1, 0xa6fd, + 0xa6d9, 0xa6d6, 0xa6e6, 0xa6f9, 0xa9a1, 0xa99d, 0xa99e, 0x28d9, + 0xaaff, 0xab5f, 0xab57, 0xab60, 0xab59, 0xac2c, 0xac25, 0xac27, + 0xac30, 0xac24, 0xac26, 0xac2d, 0xac2e, 0xac29, 0xac31, 0xad45, + 0xad47, 0xad52, 0xad4a, 0xad50, 0xad46, 0xad4f, 0xad4e, 0xad53, + 0xaf21, 0xaf09, 0xaf1a, 0xaf1b, 0x7115, 0xaf10, 0xc4f9, 0xaf14, + 0xaf0e, 0xaf12, 0xaf0b, 0xafcf, 0xafd2, 0xafd0, 0xafd4, 0xafd3, + 0xafd1, 0x3518, 0xc4fb, 0xb009, 0xb11c, 0xb127, 0xb125, 0xb11b, + 0xb129, 0xb11f, 0xb130, 0xb124, 0xb128, 0xb119, 0xb12f, 0xb224, + 0xb221, 0xb225, 0xb226, 0xb227, 0xb276, 0xb366, + /* 0x4c */ + 0xb375, 0xb369, 0xb37e, 0xb38f, 0xb374, 0x8e10, 0xb3ad, 0xb42b, + 0xb42a, 0xb458, 0xb522, 0xb51d, 0xb52b, 0xb52c, 0xb52d, 0xb533, + 0xb51b, 0xb527, 0xb52a, 0xb528, 0xb53b, 0xb67e, 0xb671, 0xb679, + 0xb678, 0xb670, 0xb66d, 0xb67d, 0xb675, 0xb676, 0xb6de, 0xb766, + 0xb783, 0xb787, 0xb77b, 0xb789, 0xb786, 0xb782, 0xb77c, 0xb781, + 0xb843, 0xb845, 0xb8f7, 0xb8f9, 0xb8fa, 0xba05, 0xb9fe, 0xba0f, + 0xb9ff, 0xb9fa, 0xba09, 0xba20, 0xba0c, 0xba3c, 0xba22, 0xb9f8, + 0xba0a, 0xba08, 0xb9f7, 0xbc8e, 0xbc77, 0xbc8b, 0xbcb4, 0xbc8a, + 0xbc9a, 0xbc79, 0xbc83, 0xbc7f, 0xbca1, 0xbc8f, 0xbca3, 0xbc81, + 0xbc94, 0xbc7e, 0xbc82, 0xbc90, 0xbca5, 0xbcad, 0xbc9d, 0xbe67, + 0xbe69, 0xbecb, 0xbec8, 0xbed1, 0xbf40, 0xbf4b, 0xbf49, 0xbf46, + 0xbf3e, 0xbf43, 0xbf3f, 0xbfa5, 0xbfa7, 0xc04e, + /* 0x4d */ + 0xc04d, 0x499b, 0xc0e5, 0xc0e1, 0xc0e2, 0xc116, 0xc114, 0xc51b, + 0xc159, 0xc151, 0xc15f, 0xc14a, 0xc157, 0xc158, 0xc1ca, 0xc1db, + 0xc1de, 0xc1e0, 0xc1e1, 0xc1df, 0xc1e2, 0xc1e3, 0xc292, 0xc2bf, + 0xc2be, 0x2c0b, 0x2e52, 0x2e4e, 0x00b9, 0xc313, 0x2fa7, 0x3226, + 0x3227, 0x32c6, 0x330b, 0x336a, 0x3378, 0x381a, 0x3816, 0x3819, + 0x3817, 0x381b, 0x3818, 0x3820, 0x3937, 0x3aec, 0x3b81, 0xae3d, + 0x3e0f, 0x3ead, 0x3ffb, 0x4052, 0x43af, 0x43b7, 0x43b2, 0x4578, + 0x45ac, 0x4700, 0x46fe, 0x4702, 0x46fd, 0x4703, 0x4840, 0x4843, + 0x4842, 0x48b7, 0x49a2, 0x4c00, 0x4c35, 0x4c41, 0x4c05, 0x2e53, + 0x4c50, 0x4c4e, 0x4c53, 0x5053, 0x5050, 0x5057, 0x505f, 0x5055, + 0x50ea, 0x5226, 0xb430, 0x522a, 0x5228, 0x522c, 0x522d, 0x52d4, + 0x5507, 0x5558, 0x5559, 0x58c5, 0x58cd, 0x58c7, + /* 0x4e */ + 0x58e8, 0x084b, 0x5a32, 0xc297, 0x5bde, 0x5d32, 0x34c8, 0xc415, + 0x60f1, 0x60f0, 0x60ec, 0x6109, 0x60f9, 0x60f5, 0x60fe, 0x6374, + 0x6381, 0x637c, 0x6375, 0x6389, 0x6382, 0x6397, 0x6386, 0x637d, + 0x6393, 0x639c, 0x6376, 0x6380, 0x6445, 0x30a1, 0x6603, 0x67c9, + 0x67cd, 0x67d0, 0x69ad, 0x69c5, 0x6aa2, 0x6bec, 0x6bf6, 0x6bf3, + 0x6df3, 0x6dfa, 0x6df9, 0x6df5, 0x6df4, 0x6df8, 0x6eb6, 0x6eb4, + 0x6f32, 0x6fcd, 0x6fc8, 0x6fce, 0x6fca, 0x712a, 0x7121, 0x711d, + 0x73bd, 0x73be, 0x73c2, 0x0cf1, 0x73c9, 0x751f, 0x76f1, 0x76ed, + 0x76f2, 0x76e0, 0x76f7, 0x7830, 0x7837, 0x7831, 0x7836, 0x78c8, + 0x7b6d, 0x7b69, 0x7b7d, 0x7b61, 0x7b70, 0x7b71, 0x7b73, 0x7b76, + 0x7b75, 0x7b78, 0x7b79, 0x7b64, 0x7b6e, 0x7d51, 0x7d4f, 0x7d22, + 0x7faf, 0x7faa, 0x7fa3, 0x7f9d, 0x7f9c, 0x7fa1, + /* 0x4f */ + 0x7fb6, 0x7fac, 0x7fa2, 0x7fa7, 0x7fb0, 0x7fa9, 0x7fc3, 0x8131, + 0x8132, 0x8133, 0x8134, 0x8137, 0x813c, 0x81d9, 0x81dd, 0x81de, + 0x81df, 0x81e0, 0x82a5, 0x82aa, 0x82a2, 0x82a3, 0x8404, 0x8403, + 0x83fe, 0x8428, 0x86af, 0x86ad, 0x86a6, 0x87ac, 0x87a5, 0x87b0, + 0x87b1, 0x8801, 0x88b2, 0x88d2, 0x88f1, 0x8bd1, 0x8c47, 0x8cc9, + 0x8ca7, 0x8cc8, 0x8c95, 0x8c8e, 0x8c91, 0x8c7d, 0x8cee, 0x8c8d, + 0x8c8c, 0x8cb0, 0x8c96, 0x8c42, 0x8c7c, 0x8cb1, 0x8cb2, 0x8c84, + 0x8c9d, 0x8ca1, 0x8c98, 0x8cb3, 0x8c22, 0x8c7b, 0x8c8a, 0x8cce, + 0x8c80, 0x8c97, 0x8cb4, 0x8cb5, 0x8c9a, 0x8c9f, 0x8c93, 0x8e12, + 0x8e0b, 0x8e0e, 0x90a3, 0x90cc, 0x90dc, 0x90e1, 0x90de, 0x90d2, + 0x90db, 0x90d9, 0x90d7, 0x90d4, 0x90c9, 0x90eb, 0x90da, 0x90d1, + 0x9104, 0x90ca, 0x90e2, 0x91d7, 0x938c, 0x9399, + /* 0x50 */ + 0x93a2, 0x9396, 0x9394, 0x939f, 0x1267, 0x938e, 0x9403, 0x9494, + 0x9493, 0x9544, 0x972f, 0x9735, 0x972b, 0x9732, 0x972d, 0x9736, + 0x1314, 0x9731, 0x9712, 0x9733, 0x971f, 0x9734, 0x9740, 0x973f, + 0x9741, 0x97d3, 0x9889, 0x9918, 0x9910, 0x9a1a, 0x9a25, 0x9a1e, + 0x9b92, 0x9b95, 0x9b93, 0x9d84, 0x9d9a, 0x9d89, 0x9d8d, 0x9d88, + 0x9d91, 0x9d9b, 0x9d9c, 0xb148, 0x9e8e, 0x9e92, 0x9fc5, 0x9fc1, + 0x9fb8, 0x9fbe, 0x9fb5, 0x9fc7, 0xa03c, 0x1489, 0xa1ec, 0xa23f, + 0xa239, 0xa237, 0xa3a1, 0xa394, 0xa3a0, 0xa3de, 0xa3db, 0xa3df, + 0xa3dc, 0xa4d6, 0xa4dc, 0xa4dd, 0xa4e0, 0xa4e3, 0xa4e1, 0xa718, + 0xa719, 0xa753, 0xc4ec, 0xa744, 0xa70e, 0xa70f, 0xa747, 0xa717, + 0xa71d, 0xa711, 0xa8b4, 0xa8b6, 0xa9b7, 0xa9be, 0xa9c2, 0xa9b4, + 0xab31, 0xab15, 0xab83, 0xac3b, 0xac36, 0xac42, + /* 0x51 */ + 0xac50, 0xac40, 0xac34, 0xac38, 0xac3d, 0xac3e, 0xac35, 0xac3a, + 0xac46, 0xac37, 0xac39, 0xac45, 0xad77, 0xad5d, 0xad6a, 0xad76, + 0xad6b, 0xad6c, 0xad65, 0xad64, 0xad71, 0xad5f, 0xad72, 0xadfe, + 0xadff, 0xae3e, 0xaf2b, 0xaf36, 0xaf2d, 0xaf39, 0xaf3f, 0xaf3b, + 0xaf33, 0xaf42, 0xaf3a, 0xafd5, 0xafd8, 0xafd9, 0xb00d, 0xb00a, + 0xb039, 0xb03a, 0xb13d, 0xb145, 0xb13a, 0xb137, 0xb13e, 0xb142, + 0xb387, 0xb38c, 0xb382, 0xb36b, 0xb3a0, 0xb39a, 0xb390, 0xb38e, + 0xb3a1, 0xb3bd, 0xb3b2, 0xb3b5, 0xb3b7, 0xb3aa, 0xb3a2, 0xb3a5, + 0xb3ae, 0xb3ab, 0xb3bc, 0xb432, 0xb45a, 0xb564, 0xb55c, 0xb54d, + 0xb53f, 0xb53e, 0xb552, 0xb558, 0xb557, 0xb55e, 0xb553, 0xb554, + 0xb556, 0xab65, 0xb684, 0xb685, 0xb686, 0xb797, 0xb7a1, 0xb7a2, + 0x180b, 0xc50a, 0xb7a3, 0xb7a6, 0x1817, 0xb815, + /* 0x52 */ + 0xb824, 0xb84a, 0xb849, 0xb848, 0xb84b, 0xb90e, 0xb562, 0xb90b, + 0xb90a, 0xb908, 0xb906, 0xba43, 0xba47, 0xba3f, 0xba46, 0xba50, + 0x186d, 0xba4b, 0x1870, 0xba52, 0xbcd7, 0xbcbf, 0xbcd8, 0xbce0, + 0xbce7, 0xbcb8, 0xbcd5, 0xbcef, 0xbce6, 0xbce4, 0xbcd4, 0xbcd6, + 0xbcea, 0x18ed, 0xbcbb, 0xbce9, 0xc510, 0xbe6d, 0xbe70, 0xbe73, + 0xbe72, 0xbed4, 0xbece, 0xbed5, 0xbf5a, 0xbf58, 0xbf52, 0xbf50, + 0xbf55, 0xbf4e, 0xbf4d, 0xbfcb, 0xbfcc, 0xbfcd, 0xbfd1, 0xc058, + 0xc063, 0xc05e, 0xc054, 0xc05b, 0xc0e9, 0xc0e7, 0xc0e8, 0xc11d, + 0xc167, 0xc15a, 0xc15c, 0xc15b, 0xc161, 0xc1a1, 0x198d, 0xc1a4, + 0xc1e9, 0xc1ef, 0xc1e5, 0xc1f5, 0xc1eb, 0xc1ed, 0xc296, 0xc295, + 0xc2b3, 0xc2b5, 0xc2b1, 0x00a7, 0x2e4d, 0x3024, 0x322b, 0x33cf, + 0x34c9, 0x3836, 0x3831, 0x3854, 0x383a, 0x3838, + /* 0x53 */ + 0x3939, 0x3938, 0x3af4, 0x3af3, 0x3af6, 0x3afc, 0x3af5, 0x3af1, + 0x3c9c, 0x3e18, 0x3e1a, 0x3ffc, 0x3ffe, 0x4003, 0x4053, 0x422b, + 0x43c6, 0x43c1, 0x457b, 0x4706, 0x4849, 0x48b8, 0x49a3, 0x4c52, + 0x4c4d, 0x4c5f, 0x4c5e, 0x4c61, 0x4d23, 0x508c, 0x506f, 0x5075, + 0x5074, 0x5071, 0x5070, 0x506c, 0x5326, 0x5508, 0x1e07, 0x58f0, + 0x58ef, 0x58fb, 0x5910, 0x590c, 0x58f6, 0x58fe, 0x5b7c, 0x5be1, + 0x5d38, 0x5d6f, 0x6118, 0x6115, 0x611c, 0x6110, 0x6135, 0xc417, + 0x6117, 0x611d, 0x6126, 0x6128, 0x6129, 0x612a, 0x611a, 0xc416, + 0x4707, 0x63ab, 0x63ac, 0x63a1, 0x63ae, 0x63a3, 0x63a7, 0x6448, + 0x6504, 0x65fd, 0x0a5a, 0x6608, 0x67d2, 0x69c6, 0x69be, 0x6a1c, + 0x6aa6, 0x6aa7, 0x6aab, 0x6b00, 0x6bfb, 0x6bfc, 0x6bf9, 0x6c01, + 0x6e06, 0x6e04, 0xc43c, 0x6f34, 0x7136, 0x7132, + /* 0x54 */ + 0x7142, 0x712d, 0x7135, 0x73d8, 0x7523, 0x7520, 0x7701, 0x7700, + 0x7703, 0xc2bc, 0x783c, 0x7841, 0x7835, 0x78c9, 0x7b8e, 0x7b9e, + 0x7b99, 0x7bb4, 0x7baa, 0x7b9f, 0x7b96, 0x7b9d, 0x7bc3, 0x7b74, + 0x7bab, 0x0eaf, 0x7d63, 0x7d5b, 0x7d5a, 0x7fc5, 0x7fc4, 0x7fcf, + 0x7fc8, 0x7fa4, 0x7fbd, 0x7fd3, 0x8060, 0x813b, 0x81e3, 0x81e7, + 0x82a8, 0x82ac, 0x82a9, 0x832a, 0x8408, 0x8409, 0x86b9, 0x88c1, + 0x88c2, 0x88b8, 0x8ce1, 0x8ceb, 0x8ce5, 0x8cfa, 0x8ce4, 0x8d0b, + 0x8cd7, 0x8cef, 0x8ce0, 0x8cec, 0x8cfb, 0xc4b0, 0x8cd3, 0x8ce6, + 0x8cfc, 0x8ce3, 0x8ccf, 0x8cda, 0x8cdc, 0x8cd2, 0x8ca4, 0x116b, + 0x8e17, 0x8e16, 0x90f2, 0x90fc, 0x9118, 0x90f6, 0x90fe, 0x90f3, + 0x90f7, 0x9101, 0x90f9, 0x9106, 0x90f5, 0x9110, 0x90df, 0x9103, + 0x9108, 0x91d8, 0x9205, 0x9397, 0x93b3, 0x93ae, + /* 0x55 */ + 0x93af, 0x93a7, 0x93b1, 0x93a8, 0x93ac, 0x93ab, 0x9404, 0x949a, + 0x954a, 0x9742, 0x9758, 0x974b, 0x9745, 0x9749, 0x974c, 0x9759, + 0x9756, 0x131b, 0x9746, 0x9744, 0x975b, 0x9769, 0x988e, 0x988f, + 0x991e, 0x86bc, 0x9a2f, 0x9b9e, 0x9b9d, 0x9b9f, 0x9b9c, 0x9db4, + 0x9dae, 0x9dab, 0x9db3, 0x9daf, 0x9dc2, 0x9e93, 0x9e95, 0x9e96, + 0x9e97, 0x9fcf, 0x9fce, 0x9fcb, 0xa04b, 0xa246, 0xa243, 0xa245, + 0xa251, 0xa3ae, 0xa3af, 0xa3b0, 0xa3b8, 0xa3e2, 0xa3e3, 0xa3e6, + 0xa4ed, 0xa4ea, 0xa53a, 0xa759, 0xa784, 0xa75f, 0xa77c, 0xa75c, + 0xa758, 0xa755, 0xa75d, 0xa77e, 0xa780, 0xa783, 0xa757, 0x1563, + 0xa75e, 0xa8ba, 0xa9d5, 0xab58, 0xab68, 0xab67, 0xac4a, 0xac4c, + 0xac52, 0xac49, 0xac4e, 0xac47, 0xac4d, 0xac4b, 0xac4f, 0xad7e, + 0xad87, 0xad83, 0xad89, 0x69ca, 0xad86, 0xad88, + /* 0x56 */ + 0xae47, 0xae42, 0xae49, 0xae48, 0x1680, 0x1684, 0x167f, 0xaf44, + 0xaf51, 0xaf46, 0xaf47, 0xafe4, 0xb00f, 0xb03f, 0xb14b, 0xb157, + 0xb152, 0x16f1, 0xb151, 0xb158, 0xb15e, 0xb153, 0xb15d, 0xb14d, + 0xb23c, 0xb23f, 0xb246, 0xb23e, 0xb244, 0xb245, 0xb241, 0xb238, + 0xb242, 0xb243, 0xb27a, 0xb3a3, 0xb3ba, 0xb3c0, 0xb3c4, 0xb3c6, + 0xb3cb, 0xb461, 0xb57a, 0xb573, 0xb572, 0xb574, 0xb580, 0xb581, + 0x2947, 0xb695, 0xb68f, 0xb690, 0xb692, 0xb694, 0xb68b, 0xb6e6, + 0xb7b2, 0xb7b8, 0xb7bd, 0xb7be, 0xb7ce, 0xb7ba, 0xb816, 0xb826, + 0xb825, 0xb84c, 0xb850, 0xb84e, 0xb851, 0xb852, 0xb914, 0xb915, + 0xb91b, 0xba82, 0xba99, 0xba9a, 0xba7d, 0xba85, 0xba86, 0xba9c, + 0xba79, 0xba7b, 0xba80, 0xba83, 0xba81, 0xbd1e, 0xbd1b, 0xbd2a, + 0xbcfb, 0xbd05, 0xbd20, 0xbd11, 0xbd04, 0xbcfd, + /* 0x57 */ + 0xbd03, 0xbd10, 0xbd18, 0xbd0a, 0xbd4e, 0xbd09, 0xbd07, 0xbd1c, + 0x191c, 0xbe77, 0xbe76, 0xbed8, 0xbed9, 0xbf61, 0xbf5c, 0xbf5e, + 0xbf60, 0xbfaa, 0xbfd6, 0xbfd8, 0xc009, 0xc008, 0xc06b, 0xc065, + 0xc073, 0xc074, 0xc0ed, 0xc124, 0xc125, 0xc16a, 0xc1a7, 0xc1a8, + 0xc20b, 0xc1fa, 0xc1f9, 0xc1ff, 0xc204, 0xc1f6, 0xc205, 0xc299, + 0xc2ab, 0xc2bd, 0xc2b8, 0x00a8, 0x2e64, 0x2e5a, 0x2f72, 0x337a, + 0x3595, 0x385f, 0x3861, 0x385e, 0x385a, 0x385c, 0x385d, 0x386e, + 0x3857, 0x3858, 0x3b02, 0x3b0b, 0x3b08, 0x3b51, 0x3e25, 0x3e28, + 0x3e23, 0x3e21, 0x3e24, 0x3e29, 0x4006, 0x400a, 0x43ca, 0x43cc, + 0x43cb, 0x43cf, 0x457f, 0x457c, 0x45d6, 0x4709, 0x470b, 0x4776, + 0x487d, 0x49a5, 0x4c5b, 0x4c5c, 0x4c5d, 0x4c65, 0x506d, 0x5082, + 0x5083, 0x5087, 0x5095, 0x508a, 0x52d6, 0x5328, + /* 0x58 */ + 0x550d, 0x592e, 0xc3ee, 0x592d, 0x5921, 0x5919, 0x5a3b, 0x5a3c, + 0x5a3a, 0x5b7e, 0x5d3b, 0x6147, 0x6139, 0x6134, 0x6136, 0x6146, + 0x613b, 0x6141, 0x6145, 0x63c0, 0x63c4, 0x63ba, 0x63bd, 0x63be, + 0x64a3, 0x660c, 0x67d9, 0x69cd, 0x6aae, 0x6bff, 0x6c24, 0x6ebb, + 0x6ebc, 0x6f36, 0x6fd5, 0x6fd3, 0x6fd6, 0x713c, 0x713f, 0x73de, + 0x73e3, 0x7527, 0x7529, 0x0d8b, 0x7705, 0x7707, 0x770c, 0x78d0, + 0x7bbe, 0x7bbc, 0x7bd0, 0x7bc2, 0x7bb5, 0x7bc9, 0x7d66, 0x0f2b, + 0x7fd5, 0x7fe2, 0x7fdc, 0x7fe3, 0x7fda, 0x7fc2, 0x7fe8, 0x81e9, + 0x82af, 0x82ad, 0x82ae, 0x840b, 0x86c1, 0x87b6, 0x87b9, 0x88c0, + 0x8ca5, 0x8d28, 0x8d22, 0x8d29, 0x8d18, 0x8d1f, 0x8d1c, 0x8d12, + 0x8d2a, 0x117a, 0x8d21, 0x8d2b, 0x8d17, 0x8cf0, 0x8d16, 0x8d23, + 0x912b, 0x9126, 0x913d, 0x9122, 0x913a, 0x9131, + /* 0x59 */ + 0x9132, 0x9154, 0x9121, 0x9135, 0x1209, 0x912e, 0x9130, 0x912f, + 0x9136, 0x91da, 0x91d9, 0x93bb, 0x93bc, 0x93b7, 0x93c2, 0x93bd, + 0x93b2, 0x126d, 0x7144, 0x7bd1, 0x9752, 0x976b, 0x9767, 0x131f, + 0x9761, 0x976c, 0x9751, 0x9774, 0x9777, 0x976f, 0x976d, 0x9768, + 0xc4d1, 0x9784, 0x9890, 0x9892, 0x9893, 0x991f, 0x9a31, 0x9a38, + 0x9a39, 0x9a37, 0x9bab, 0x9dc3, 0x9dc8, 0x9dcb, 0x9dcf, 0x9e98, + 0x9fd4, 0x9fd3, 0x9fd8, 0x9fd9, 0x9fdd, 0x9fd1, 0x9fd6, 0xa03e, + 0xa258, 0xa257, 0xa255, 0xa3c4, 0xa3e4, 0xa4ee, 0xa4ef, 0xa4f3, + 0xa4f2, 0xa4f0, 0xa7ab, 0xa79a, 0xa7af, 0xa797, 0x156a, 0x156c, + 0xa7bf, 0xa794, 0xa793, 0xa8be, 0xa8bb, 0xa8bc, 0xa9d9, 0xab6c, + 0xac53, 0xac54, 0xac5b, 0xac58, 0xac56, 0xac57, 0xad9f, 0xad94, + 0xad96, 0xad97, 0xae4a, 0xae4b, 0xaf55, 0xaf5a, + /* 0x5a */ + 0xaf5e, 0xaf5f, 0xaf59, 0xaf5b, 0xaf58, 0xaf54, 0xafe8, 0xafeb, + 0xafec, 0xb013, 0xb166, 0xb16b, 0xb162, 0xb169, 0xb163, 0xb15f, + 0xb14e, 0xb248, 0xb24a, 0xb3e3, 0xb3db, 0xb3d8, 0xb3d6, 0xb586, + 0xb590, 0xb591, 0xb588, 0xb594, 0xb583, 0x17b2, 0xb59c, 0xb58d, + 0xb585, 0xb698, 0xb69a, 0xb69c, 0xb6e7, 0xb7c5, 0xb7d0, 0xb7d1, + 0xb819, 0xb827, 0x181d, 0xb854, 0xb92d, 0xb922, 0x182d, 0xb91f, + 0xbabd, 0xbaae, 0xbabb, 0xbaad, 0xbabc, 0xbab9, 0xbab4, 0xbacb, + 0xbab7, 0xbab3, 0xbaba, 0xbab6, 0xbacd, 0xbabe, 0xbac9, 0xc50b, + 0xbd5f, 0xbd3b, 0xbd61, 0xbd5c, 0xbd8a, 0xbd5a, 0xbd4d, 0xbd46, + 0xbd44, 0xbd3d, 0xbd40, 0xbd3c, 0xbd8c, 0xbd41, 0xbd4c, 0xbd3e, + 0xbd4a, 0xbe7c, 0xbe7a, 0xbf65, 0xbf6e, 0xbf69, 0xbf6a, 0xbf6f, + 0xbf6c, 0xbf70, 0xbf68, 0xbf6b, 0x1945, 0xbfac, + /* 0x5b */ + 0xbfde, 0xbfdd, 0xbfdc, 0x63c5, 0xc08c, 0xc083, 0xc082, 0xc088, + 0xc085, 0xc081, 0xc0f5, 0xc0ef, 0xc0f4, 0xc0f2, 0xc0f6, 0xc0f3, + 0xc0f0, 0xc0f1, 0xc12b, 0xc127, 0xc128, 0xc16c, 0xc1ae, 0xc20e, + 0xc21b, 0xc216, 0xc21f, 0xc222, 0xc220, 0xc221, 0xc214, 0xc213, + 0xc29d, 0xc29c, 0xc29e, 0xc29f, 0x2e6b, 0x32c8, 0x3878, 0x3876, + 0x3870, 0x3871, 0x3b0a, 0x3e2c, 0x4711, 0x487e, 0x4c57, 0x4c66, + 0x4c69, 0x4c67, 0x4c68, 0x4c71, 0x4c6f, 0xbfae, 0x508b, 0x5096, + 0x5235, 0x523a, 0x526b, 0x5516, 0x5943, 0x5946, 0x593f, 0x593b, + 0x593d, 0x5ab1, 0x5ab2, 0x5be4, 0x5d40, 0x615d, 0x6151, 0x614d, + 0x614c, 0x615b, 0x63d4, 0x63d2, 0x63ca, 0x63c8, 0x63d0, 0x63c9, + 0x6449, 0x64a4, 0x6612, 0x660f, 0x6611, 0x67db, 0x67dd, 0x67dc, + 0x69d4, 0x6a21, 0x6ab2, 0x6c04, 0x6c02, 0x6e11, + /* 0x5c */ + 0x6e16, 0x6e10, 0x6ebe, 0x8e1a, 0x714c, 0x714a, 0x73f2, 0x73f1, + 0x752a, 0x752c, 0x752f, 0x7531, 0x7711, 0x7712, 0x784b, 0x7bdb, + 0x7bd6, 0x7bdd, 0x7be2, 0x7be4, 0x7be0, 0x7bdf, 0x7be3, 0x7d6e, + 0x7d71, 0x7fe9, 0x7fea, 0x8063, 0x81eb, 0x81ea, 0x86bd, 0x86bb, + 0x86c6, 0x86cc, 0x86c8, 0x63cf, 0x86c9, 0x86ca, 0x86cf, 0x86d0, + 0x87ba, 0x87fb, 0x8803, 0x88c4, 0x8d49, 0x8d53, 0x8d36, 0x8d4a, + 0x8d41, 0x8d4e, 0x8d19, 0x8d4d, 0x8d45, 0x8d4c, 0x8d47, 0x8d48, + 0x8d4f, 0x8d37, 0x8d42, 0x914a, 0x9146, 0x120a, 0x9149, 0x914f, + 0x9151, 0x914c, 0x120c, 0x9206, 0x9551, 0x977a, 0x9783, 0x977e, + 0x977f, 0x9780, 0x6ab5, 0x9891, 0x9894, 0x9895, 0x9921, 0x9920, + 0x9a3d, 0x9a40, 0x9a46, 0x9a84, 0x9bac, 0x9bad, 0x142e, 0x9dda, + 0x9dd9, 0x9fe2, 0x9fe1, 0x9fe3, 0x9fe4, 0x9fde, + /* 0x5d */ + 0x9fdf, 0xa241, 0xa259, 0xa25c, 0xa25a, 0xa3e8, 0xa4f6, 0xa4fc, + 0xa4f7, 0xa4fa, 0xa4f9, 0xa7c4, 0xa7be, 0xa7d2, 0xa7bd, 0xa795, + 0xa7d4, 0xa9e4, 0xac61, 0xac62, 0xac63, 0xac64, 0xac60, 0xac5c, + 0xac5d, 0xac5e, 0xada5, 0xada6, 0xae4c, 0xaf68, 0xaf6e, 0xaf71, + 0xaf6b, 0xaf6f, 0xafee, 0xaff1, 0xaff0, 0xafef, 0xb015, 0xb014, + 0xab6e, 0xb047, 0xb17c, 0xb17a, 0xb174, 0xb176, 0xb16e, 0xb178, + 0xb16d, 0xb16c, 0xb24e, 0xb3d7, 0xb3ea, 0xb3e5, 0xb464, 0xb5b3, + 0xb5a3, 0xb5a5, 0xb5a7, 0xb5a2, 0xb59f, 0xb5a6, 0xb59e, 0xb5a8, + 0xb6a9, 0xb6a6, 0xb6aa, 0xb6ab, 0xb6a0, 0xb6a1, 0xb6a8, 0xb6e8, + 0xb6e9, 0xb6ea, 0xb7e4, 0xb7df, 0xb7e0, 0xb828, 0xb85d, 0xb85b, + 0xb856, 0xb857, 0xb85f, 0xb862, 0xbae1, 0xbae3, 0xbade, 0xbad9, + 0xbae8, 0xbaf2, 0xbaf6, 0xbae6, 0xbaf4, 0xbaf5, + /* 0x5e */ + 0xbae5, 0xbae2, 0x188d, 0xbd96, 0xbdaa, 0xbd97, 0xbd70, 0xbda1, + 0xbd9d, 0xbda9, 0xbd6f, 0xbd7e, 0xbd94, 0xbd9a, 0xbd73, 0xbd87, + 0xbd71, 0xbd77, 0xbd88, 0xbd8d, 0xbd85, 0xbd78, 0xbdad, 0xbe80, + 0xbe81, 0xbee5, 0xbee7, 0xbf7c, 0xbfaf, 0xbfe1, 0xc096, 0xc0a3, + 0xc090, 0xc0f8, 0xc12e, 0xc175, 0xc17e, 0xc17d, 0xc17b, 0xc178, + 0xc1b0, 0xc234, 0xc236, 0xc230, 0xc51d, 0xc22e, 0xc237, 0x34ce, + 0x3597, 0x3598, 0x387c, 0x387e, 0x387d, 0x387f, 0x3b0f, 0x3ca4, + 0x3e31, 0x3e2e, 0x3e2f, 0x3e32, 0x422c, 0x43d4, 0x43dc, 0x43d8, + 0x440e, 0x4583, 0x4584, 0x4712, 0x4c72, 0x4c7c, 0x4c7e, 0x50a6, + 0x50a0, 0x509e, 0x50a2, 0x532a, 0x5518, 0x594d, 0x5958, 0x595b, + 0x7714, 0xc3f2, 0x5be6, 0x6164, 0x6168, 0x6160, 0x6162, 0x63d7, + 0x644b, 0x67e0, 0x6a22, 0x6c05, 0x6e19, 0x6e1a, + /* 0x5f */ + 0x6ec3, 0x6fd8, 0x6fdc, 0x714f, 0x73f7, 0x73f4, 0x73f8, 0x7713, + 0x7850, 0x7bf0, 0x7be9, 0x7bef, 0x7bed, 0x7bea, 0x7bf8, 0x7c05, + 0x7bf2, 0x7d72, 0x0f31, 0x7ff9, 0x7ff3, 0x7ff6, 0x7ff2, 0x7ff7, + 0x8066, 0x8065, 0x8140, 0xc477, 0x86d1, 0x86d3, 0x8804, 0x8d59, + 0x8d60, 0x8d5b, 0x8d5d, 0x8d5e, 0x8d69, 0x8d5c, 0x8d61, 0x8d6a, + 0x8d5f, 0x914e, 0x915c, 0x9160, 0x9163, 0x91db, 0x93ca, 0x93c9, + 0x93c8, 0x94a5, 0x94a3, 0x978e, 0x9787, 0x9789, 0x9785, 0x9786, + 0x978f, 0x978a, 0x9790, 0x9898, 0x989b, 0x9a47, 0x9a49, 0x9a48, + 0x9de5, 0x9dea, 0x9ded, 0x9ff0, 0x9fef, 0x9ff2, 0x9fec, 0xa040, + 0xa260, 0xa25f, 0xa3eb, 0xa3ec, 0xa500, 0xa501, 0xa7e2, 0xa7df, + 0xa7e0, 0xa7e1, 0xa7e3, 0xa8c3, 0xa9eb, 0xa9ea, 0xab61, 0xab71, + 0xac6b, 0xac68, 0xac69, 0xac67, 0xadb0, 0xadb1, + /* 0x60 */ + 0xadb2, 0xae51, 0xaf74, 0xb17f, 0xb184, 0xb253, 0xb254, 0xb3f0, + 0xb3f4, 0xb3f1, 0xb437, 0xb5bf, 0x17bc, 0x17bb, 0xb5bd, 0xb5be, + 0xb5b7, 0xb5c0, 0xb5ba, 0xb5b8, 0xb5bc, 0xb5bb, 0xb6eb, 0xb7e7, + 0xb81d, 0xb81c, 0xb863, 0x484b, 0xb938, 0xb936, 0xb934, 0xb937, + 0xbb06, 0xbb1c, 0xbb02, 0xbb1d, 0xbb1e, 0xbae0, 0xbb11, 0xbb18, + 0xbb21, 0xbb20, 0xbb10, 0xbdbd, 0xbdae, 0xbdb5, 0xbdb8, 0xbdb9, + 0xbdbe, 0xbdc4, 0xbdbc, 0xbdba, 0xbe83, 0xbeea, 0xbeec, 0xbf7e, + 0xbf7b, 0xbfe5, 0xc0a7, 0xc09e, 0xc09a, 0xc12f, 0xc131, 0xc183, + 0xc1b5, 0xc246, 0xc241, 0xc243, 0xc23d, 0xc242, 0xc23b, 0xc247, + 0x336b, 0x33d0, 0x388e, 0x4011, 0xc371, 0xc389, 0x484c, 0x532b, + 0x594f, 0x595e, 0x5963, 0x596b, 0x5a3f, 0x5be9, 0x616d, 0x616b, + 0x616a, 0xbb2a, 0x63e0, 0x63dd, 0x63e1, 0x63de, + /* 0x61 */ + 0x63dc, 0x644d, 0x6616, 0x67e3, 0x69e5, 0x69e4, 0x6e1d, 0x754b, + 0xc2c1, 0x784e, 0x78d6, 0x7bfd, 0x7c07, 0x7bfe, 0x7c03, 0x7c0b, + 0x7bff, 0x7d7a, 0x7d77, 0x7ffb, 0x8143, 0x81ed, 0x87bc, 0x63df, + 0x8805, 0x88c6, 0x88c5, 0x8d74, 0x8d73, 0x8d72, 0x8d78, 0x9173, + 0x917a, 0x6e1c, 0x9176, 0x9175, 0x9177, 0x93cf, 0x93ce, 0x93cd, + 0x94a8, 0x9798, 0x9792, 0x9794, 0x989a, 0x9bb4, 0x9deb, 0x9df4, + 0x9df3, 0x9dee, 0x9df2, 0x9df0, 0xa264, 0xa805, 0xa7fb, 0xa7fc, + 0xa9f3, 0xac6c, 0xadba, 0xaf79, 0xaf7e, 0xaf78, 0xaff4, 0xb016, + 0xb257, 0xb5c8, 0xb5c3, 0xb5ce, 0xb6b3, 0xb6ed, 0xb6ee, 0xb7f1, + 0xb7f8, 0x1814, 0xb864, 0xb865, 0xbb35, 0xbb29, 0xbb2c, 0xbb31, + 0xbb2b, 0xbb2e, 0xbb25, 0xbdda, 0xbde0, 0xbdd4, 0xbde1, 0xbddd, + 0xbfe7, 0xc012, 0xc0ae, 0xc0af, 0xc186, 0xc185, + /* 0x62 */ + 0xc1d1, 0xc258, 0xc23f, 0xc252, 0xc24b, 0xc253, 0xc250, 0xc256, + 0xc257, 0xc2cd, 0xc2cb, 0x3231, 0x3230, 0x33d1, 0x021c, 0x3892, + 0x3890, 0x388f, 0x3893, 0x3891, 0x0372, 0x4713, 0x487f, 0x50ac, + 0x6170, 0x63e5, 0x6a23, 0x6a24, 0x6c08, 0x6c07, 0x6e1f, 0x6e20, + 0x6e21, 0x6fe1, 0x7154, 0x7157, 0x7155, 0x73fa, 0x7538, 0x8d86, + 0x7537, 0x7853, 0x7d7e, 0x7d7b, 0xc471, 0x7ffd, 0x7ffc, 0x8146, + 0x8732, 0x88c7, 0x8d71, 0x8d83, 0x8d6f, 0x8d7e, 0x8d7d, 0x8d81, + 0x8d7c, 0x918a, 0x917e, 0x9180, 0x917d, 0x917f, 0x9182, 0x93d4, + 0x93d0, 0x93d2, 0x9555, 0x979b, 0x979a, 0x9a4e, 0x9df1, 0x9ff8, + 0x9ffd, 0xa25e, 0xa266, 0xa505, 0xa80a, 0xa80b, 0xa80e, 0xa80d, + 0xa811, 0xa809, 0xa810, 0xa80c, 0xa812, 0xa8c4, 0xa9f7, 0xa9f8, + 0xab6a, 0xab6b, 0xadc0, 0xadc2, 0xaf85, 0xaf80, + /* 0x63 */ + 0xaf84, 0xaf81, 0xadc4, 0xb18b, 0xb18d, 0xb18e, 0xb6b7, 0xb6b9, + 0xb6ef, 0xb7fb, 0xb7ff, 0xb867, 0xb868, 0xb869, 0xb93f, 0xbb3c, + 0xbb4c, 0xbb3d, 0xbb3e, 0xbb3f, 0xbb3b, 0xbdff, 0x190e, 0xbdf6, + 0xbdee, 0xbdfc, 0xbdf8, 0xbe01, 0xbdfa, 0xbe88, 0xbf80, 0xc011, + 0xc0fe, 0xc100, 0xc135, 0x6f3c, 0xc1bd, 0xc1bb, 0xc25c, 0xc25a, + 0xc2d1, 0xc2d0, 0x340b, 0x5973, 0x3e39, 0x401a, 0x43e3, 0x4587, + 0x4777, 0x4778, 0x50b1, 0x596a, 0x5974, 0x5beb, 0x617b, 0x64a5, + 0x67e4, 0x6c0b, 0x6c0e, 0x6c0c, 0x7539, 0x7c10, 0x7c11, 0x7c16, + 0x7d81, 0x7d80, 0x7ffe, 0x8001, 0x8000, 0x8147, 0x81ef, 0x8d88, + 0x918b, 0x918d, 0x9187, 0x9185, 0x918f, 0x9184, 0x9188, 0x918e, + 0x918c, 0x93d7, 0x93d6, 0x979f, 0x4588, 0x9e03, 0x9ffe, 0xa3ef, + 0xa509, 0xa508, 0xa820, 0xa824, 0xa81f, 0xac70, + /* 0x64 */ + 0xae56, 0xaff7, 0xaff8, 0xaff6, 0xb190, 0xb25e, 0xb3f7, 0xb5d6, + 0xb5d5, 0xb6bb, 0xb6f0, 0xb801, 0xb86c, 0xb941, 0xb942, 0xbb4f, + 0xbb53, 0xbb58, 0xbe12, 0xbe04, 0xbe13, 0xbe05, 0xbe0d, 0xbf82, + 0xbf81, 0xc0b5, 0xc0ba, 0xc1be, 0xc265, 0xc263, 0xc26e, 0xc26a, + 0xc26c, 0xc2c4, 0x336c, 0x97a5, 0x4012, 0x484d, 0x551f, 0x5977, + 0x5978, 0x5d44, 0x617c, 0x63eb, 0x63ea, 0x63ec, 0x64a7, 0x6619, + 0x6e23, 0x2074, 0x7401, 0x7c1c, 0x8003, 0x8148, 0x86da, 0x8d91, + 0x8d92, 0x9196, 0x9197, 0x9191, 0x9193, 0x93d8, 0x93d5, 0x9557, + 0x9558, 0x97a2, 0x9e05, 0x9ffa, 0xa50c, 0xa50a, 0xa82e, 0xa829, + 0xa82f, 0xa8c5, 0xac72, 0xadc8, 0xae5a, 0xae59, 0xaf89, 0xaf88, + 0xb5db, 0xb5d9, 0xb5da, 0xb6bc, 0x17ec, 0xb806, 0xb805, 0xb86f, + 0xb86d, 0xb870, 0xbb60, 0xbb5e, 0xbb63, 0xbb5a, + /* 0x65 */ + 0xbb5f, 0xbe19, 0xbe1d, 0xbe1b, 0xbe22, 0xbe1c, 0xbe1e, 0xbef7, + 0xbf84, 0xc015, 0xc0b8, 0xc0c1, 0xc101, 0xc10a, 0xc1d2, 0xc275, + 0xc274, 0xc272, 0x34d0, 0x401b, 0x4410, 0x4779, 0x63ed, 0x6ab9, + 0x6e24, 0x6ec5, 0x7403, 0x814a, 0x86f7, 0x87c1, 0x87c2, 0x8d94, + 0x9199, 0x919a, 0x955a, 0x97a8, 0x9825, 0x989e, 0xa041, 0xa832, + 0xa833, 0xadcb, 0xadca, 0xadcc, 0xb193, 0xb5e0, 0xb871, 0xbb6b, + 0xbe2b, 0xbe29, 0xbe1a, 0xbe26, 0xbe27, 0xbe2a, 0xbef8, 0x6f3d, + 0xc276, 0x3b18, 0x597a, 0x617f, 0x0e79, 0x81f0, 0x8d9a, 0x8d96, + 0x919e, 0x919d, 0x91dc, 0x93da, 0x9e0b, 0xa002, 0xa042, 0xa267, + 0xaf8b, 0xb5e2, 0xbb71, 0xbe2f, 0xbe2e, 0xc0c6, 0xc18e, 0xc27b, + 0xc277, 0xc278, 0xc27c, 0x597c, 0x8007, 0x8d97, 0x97d9, 0xa50d, + 0xa50e, 0xb5e3, 0xb5e4, 0xb6f3, 0xb875, 0xbe37, + /* 0x66 */ + 0xbe35, 0xc18f, 0xc280, 0xc27f, 0xc2d4, 0x50b4, 0xbfec, 0xab75, + 0x6c10, 0x8069, 0x91a4, 0x93db, 0xadd1, 0xaf8d, 0xbb76, 0xbe39, + 0xc284, 0xc282, 0x34d2, 0x63ee, 0x6c11, 0x7d84, 0xab74, 0xaf8f, + 0xaf8e, 0xbe3b, 0x32cb, 0xc288, 0xc286, 0x555c, 0x71a4, 0xac75, + 0xc28b, 0x3b19, 0x989f, 0xb5e5, 0xbe40, 0x6c12, 0xbefb, 0xc28c, + 0x71a5, 0xb877, 0xb878, 0xc2d6, 0x93df, 0xadd2, 0x3b1a, 0x97a9, + 0xadd3, 0xc0ca, 0x87c4, 0x94b1, 0xb264, +}; + +static const ucs4_t cns11643_7_2uni_upages[198] = { + 0x03400, 0x03500, 0x03600, 0x03700, 0x03800, 0x03900, 0x03a00, 0x03b00, + 0x03c00, 0x03d00, 0x03e00, 0x03f00, 0x04000, 0x04100, 0x04200, 0x04300, + 0x04400, 0x04500, 0x04600, 0x04700, 0x04800, 0x04900, 0x04a00, 0x04b00, + 0x04c00, 0x04d00, 0x05600, 0x05800, 0x06100, 0x06400, 0x06700, 0x07100, + 0x07600, 0x07c00, 0x07f00, 0x08100, 0x08600, 0x08d00, 0x08f00, 0x09300, + 0x09500, 0x09a00, 0x0ff00, 0x20000, 0x20100, 0x20300, 0x20400, 0x20500, + 0x20600, 0x20700, 0x20800, 0x20900, 0x20a00, 0x20b00, 0x20f00, 0x21000, + 0x21100, 0x21200, 0x21400, 0x21500, 0x21600, 0x21800, 0x21900, 0x21a00, + 0x21b00, 0x21c00, 0x21d00, 0x21f00, 0x22000, 0x22100, 0x22200, 0x22300, + 0x22400, 0x22500, 0x22700, 0x22800, 0x22900, 0x22a00, 0x22c00, 0x22d00, + 0x22e00, 0x22f00, 0x23000, 0x23100, 0x23200, 0x23300, 0x23500, 0x23600, + 0x23700, 0x23800, 0x23900, 0x23a00, 0x23b00, 0x23c00, 0x23e00, 0x23f00, + 0x24000, 0x24100, 0x24300, 0x24400, 0x24500, 0x24600, 0x24700, 0x24800, + 0x24900, 0x24a00, 0x24b00, 0x24c00, 0x24d00, 0x24e00, 0x24f00, 0x25000, + 0x25200, 0x25300, 0x25400, 0x25500, 0x25600, 0x25700, 0x25800, 0x25900, + 0x25a00, 0x25b00, 0x25c00, 0x25d00, 0x25e00, 0x25f00, 0x26000, 0x26100, + 0x26200, 0x26300, 0x26400, 0x26500, 0x26600, 0x26700, 0x26800, 0x26900, + 0x26a00, 0x26d00, 0x26e00, 0x26f00, 0x27000, 0x27100, 0x27200, 0x27300, + 0x27400, 0x27500, 0x27600, 0x27700, 0x27800, 0x27900, 0x27a00, 0x27b00, + 0x27c00, 0x27d00, 0x27e00, 0x27f00, 0x28000, 0x28100, 0x28200, 0x28300, + 0x28400, 0x28500, 0x28600, 0x28700, 0x28800, 0x28900, 0x28a00, 0x28b00, + 0x28c00, 0x28d00, 0x28e00, 0x28f00, 0x29000, 0x29100, 0x29200, 0x29300, + 0x29400, 0x29500, 0x29600, 0x29700, 0x29800, 0x29900, 0x29a00, 0x29b00, + 0x29c00, 0x29d00, 0x29e00, 0x29f00, 0x2a000, 0x2a100, 0x2a200, 0x2a300, + 0x2a400, 0x2a500, 0x2a600, 0x2f800, 0x2f900, 0x2fa00, +}; + +static int +cns11643_7_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x21 && c1 <= 0x66)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + ucs4_t wc = 0xfffd; + unsigned short swc; + { + if (i < 6539) + swc = cns11643_7_2uni_page21[i], + wc = cns11643_7_2uni_upages[swc>>8] | (swc & 0xff); + } + if (wc != 0xfffd) { + *pwc = wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + diff --git a/graf2d/win32gdk/gdk/src/iconv/cns11643_inv.h b/graf2d/win32gdk/gdk/src/iconv/cns11643_inv.h new file mode 100644 index 0000000000000..3a7c379a15464 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cns11643_inv.h @@ -0,0 +1,15412 @@ +/* + * Copyright (C) 1999-2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CNS 11643-1992 planes 1-7, CNS 11643-1986 plane 15 + */ + +static const unsigned char cns11643_inv_2charset[3*55442] = { + 0x1,0x21,0x70, 0x1,0x22,0x78, 0x1,0x22,0x34, 0x1,0x21,0x31, + 0x1,0x22,0x32, 0x1,0x22,0x33, 0x1,0x25,0x6f, 0x1,0x25,0x6d, + 0x1,0x25,0x6e, 0x1,0x25,0x70, 0x1,0x25,0x6c, 0x1,0x24,0x75, + 0x1,0x24,0x76, 0x1,0x24,0x77, 0x1,0x24,0x78, 0x1,0x24,0x79, + 0x1,0x24,0x7a, 0x1,0x24,0x7b, 0x1,0x24,0x7c, 0x1,0x24,0x7d, + 0x1,0x24,0x7e, 0x1,0x25,0x21, 0x1,0x25,0x22, 0x1,0x25,0x23, + 0x1,0x25,0x24, 0x1,0x25,0x25, 0x1,0x25,0x26, 0x1,0x25,0x27, + 0x1,0x25,0x28, 0x1,0x25,0x29, 0x1,0x25,0x2a, 0x1,0x25,0x2b, + 0x1,0x25,0x2c, 0x1,0x25,0x2d, 0x1,0x25,0x2e, 0x1,0x25,0x2f, + 0x1,0x25,0x30, 0x1,0x25,0x31, 0x1,0x25,0x32, 0x1,0x25,0x33, + 0x1,0x25,0x34, 0x1,0x25,0x35, 0x1,0x25,0x36, 0x1,0x25,0x37, + 0x1,0x25,0x38, 0x1,0x25,0x39, 0x1,0x25,0x3a, 0x1,0x25,0x3b, + 0x1,0x25,0x3c, 0x1,0x25,0x3d, 0x1,0x25,0x3e, 0x1,0x25,0x3f, + 0x1,0x25,0x40, 0x1,0x25,0x41, 0x1,0x25,0x42, 0x1,0x25,0x43, + 0x1,0x25,0x44, 0x1,0x25,0x45, 0x1,0x25,0x46, 0x1,0x21,0x39, + 0x1,0x21,0x37, 0x1,0x22,0x5d, 0x1,0x21,0x64, 0x1,0x21,0x65, + 0x1,0x21,0x66, 0x1,0x21,0x67, 0x1,0x21,0x2d, 0x1,0x21,0x2c, + 0x1,0x21,0x6a, 0x1,0x21,0x6b, 0x1,0x21,0x6f, 0x1,0x22,0x23, + 0x1,0x42,0x42, 0x1,0x22,0x6a, 0x1,0x22,0x22, 0x1,0x22,0x6b, + 0x1,0x24,0x2b, 0x1,0x24,0x2c, 0x1,0x24,0x2d, 0x1,0x24,0x2e, + 0x1,0x24,0x2f, 0x1,0x24,0x30, 0x1,0x24,0x31, 0x1,0x24,0x32, + 0x1,0x24,0x33, 0x1,0x24,0x34, 0x1,0x26,0x35, 0x1,0x26,0x36, + 0x1,0x26,0x37, 0x1,0x26,0x38, 0x1,0x26,0x39, 0x1,0x26,0x3a, + 0x1,0x26,0x3b, 0x1,0x26,0x3c, 0x1,0x26,0x3d, 0x1,0x26,0x3e, + 0x1,0x22,0x58, 0x1,0x22,0x55, 0x1,0x22,0x57, 0x1,0x22,0x56, + 0x1,0x22,0x59, 0x1,0x22,0x5a, 0x1,0x22,0x5c, 0x1,0x22,0x5b, + 0x1,0x22,0x61, 0x1,0x22,0x35, 0x1,0x22,0x3c, 0x1,0x22,0x49, + 0x1,0x22,0x48, 0x1,0x22,0x45, 0x1,0x22,0x46, 0x1,0x22,0x4d, + 0x1,0x22,0x4e, 0x1,0x22,0x50, 0x1,0x22,0x4f, 0x1,0x22,0x44, + 0x1,0x22,0x3d, 0x1,0x22,0x3b, 0x1,0x22,0x3e, 0x1,0x22,0x39, + 0x1,0x22,0x3a, 0x1,0x22,0x47, 0x1,0x22,0x4a, 0x1,0x42,0x21, + 0x1,0x42,0x22, 0x1,0x42,0x23, 0x1,0x42,0x24, 0x1,0x42,0x25, + 0x1,0x42,0x26, 0x1,0x42,0x27, 0x1,0x42,0x28, 0x1,0x42,0x29, + 0x1,0x42,0x2a, 0x1,0x42,0x2b, 0x1,0x42,0x2c, 0x1,0x42,0x2d, + 0x1,0x42,0x2e, 0x1,0x42,0x2f, 0x1,0x42,0x30, 0x1,0x42,0x31, + 0x1,0x42,0x32, 0x1,0x42,0x33, 0x1,0x42,0x34, 0x1,0x42,0x35, + 0x1,0x42,0x36, 0x1,0x42,0x37, 0x1,0x42,0x38, 0x1,0x42,0x39, + 0x1,0x42,0x3a, 0x1,0x42,0x3b, 0x1,0x42,0x3c, 0x1,0x42,0x3d, + 0x1,0x42,0x3e, 0x1,0x42,0x3f, 0x1,0x42,0x40, 0x1,0x42,0x41, + 0x1,0x26,0x21, 0x1,0x26,0x22, 0x1,0x26,0x23, 0x1,0x26,0x24, + 0x1,0x26,0x25, 0x1,0x26,0x26, 0x1,0x26,0x27, 0x1,0x26,0x28, + 0x1,0x26,0x29, 0x1,0x26,0x2a, 0x1,0x26,0x2b, 0x1,0x26,0x2c, + 0x1,0x26,0x2d, 0x1,0x26,0x2e, 0x1,0x26,0x2f, 0x1,0x26,0x30, + 0x1,0x26,0x31, 0x1,0x26,0x32, 0x1,0x26,0x33, 0x1,0x26,0x34, + 0x1,0x23,0x39, 0x1,0x23,0x3a, 0x1,0x23,0x3c, 0x1,0x23,0x3d, + 0x1,0x23,0x3e, 0x1,0x23,0x3f, 0x1,0x23,0x37, 0x1,0x23,0x36, + 0x1,0x23,0x35, 0x1,0x23,0x34, 0x1,0x23,0x33, 0x1,0x23,0x44, + 0x1,0x23,0x45, 0x1,0x23,0x47, 0x1,0x23,0x46, 0x1,0x23,0x40, + 0x1,0x23,0x41, 0x1,0x23,0x43, 0x1,0x23,0x42, 0x1,0x23,0x4c, + 0x1,0x23,0x4d, 0x1,0x23,0x4e, 0x1,0x23,0x24, 0x1,0x23,0x25, + 0x1,0x23,0x26, 0x1,0x23,0x27, 0x1,0x23,0x28, 0x1,0x23,0x29, + 0x1,0x23,0x2a, 0x1,0x23,0x2b, 0x1,0x23,0x32, 0x1,0x23,0x31, + 0x1,0x23,0x30, 0x1,0x23,0x2f, 0x1,0x23,0x2e, 0x1,0x23,0x2d, + 0x1,0x23,0x2c, 0x1,0x23,0x38, 0x1,0x23,0x3b, 0x1,0x21,0x7c, + 0x1,0x21,0x7b, 0x1,0x21,0x75, 0x1,0x21,0x74, 0x1,0x21,0x7e, + 0x1,0x21,0x7d, 0x1,0x21,0x7a, 0x1,0x21,0x79, 0x1,0x21,0x72, + 0x1,0x21,0x76, 0x1,0x21,0x73, 0x1,0x23,0x48, 0x1,0x23,0x49, + 0x1,0x23,0x4b, 0x1,0x23,0x4a, 0x1,0x21,0x78, 0x1,0x21,0x77, + 0x1,0x22,0x54, 0x1,0x22,0x51, 0x1,0x22,0x53, 0x1,0x22,0x52, + 0x1,0x21,0x21, 0x1,0x21,0x23, 0x1,0x21,0x24, 0x1,0x21,0x71, + 0x1,0x21,0x52, 0x1,0x21,0x53, 0x1,0x21,0x4e, 0x1,0x21,0x4f, + 0x1,0x21,0x56, 0x1,0x21,0x57, 0x1,0x21,0x5a, 0x1,0x21,0x5b, + 0x1,0x21,0x4a, 0x1,0x21,0x4b, 0x1,0x22,0x65, 0x1,0x21,0x46, + 0x1,0x21,0x47, 0x1,0x21,0x68, 0x1,0x21,0x69, 0x1,0x24,0x35, + 0x1,0x24,0x36, 0x1,0x24,0x37, 0x1,0x24,0x38, 0x1,0x24,0x39, + 0x1,0x24,0x3a, 0x1,0x24,0x3b, 0x1,0x24,0x3c, 0x1,0x24,0x3d, + 0x1,0x21,0x26, 0x1,0x25,0x47, 0x1,0x25,0x48, 0x1,0x25,0x49, + 0x1,0x25,0x4a, 0x1,0x25,0x4b, 0x1,0x25,0x4c, 0x1,0x25,0x4d, + 0x1,0x25,0x4e, 0x1,0x25,0x4f, 0x1,0x25,0x50, 0x1,0x25,0x51, + 0x1,0x25,0x52, 0x1,0x25,0x53, 0x1,0x25,0x54, 0x1,0x25,0x55, + 0x1,0x25,0x56, 0x1,0x25,0x57, 0x1,0x25,0x58, 0x1,0x25,0x59, + 0x1,0x25,0x5a, 0x1,0x25,0x5b, 0x1,0x25,0x5c, 0x1,0x25,0x5d, + 0x1,0x25,0x5e, 0x1,0x25,0x5f, 0x1,0x25,0x60, 0x1,0x25,0x61, + 0x1,0x25,0x62, 0x1,0x25,0x63, 0x1,0x25,0x64, 0x1,0x25,0x65, + 0x1,0x25,0x66, 0x1,0x25,0x67, 0x1,0x25,0x68, 0x1,0x25,0x69, + 0x1,0x25,0x6a, 0x1,0x25,0x6b, 0x1,0x22,0x21, 0x1,0x22,0x75, + 0x1,0x22,0x76, 0x1,0x22,0x70, 0x1,0x22,0x71, 0x1,0x22,0x72, + 0x1,0x22,0x74, 0x1,0x22,0x77, 0x1,0x22,0x73, 0x1,0x22,0x4c, + 0x1,0x22,0x4b, 0x1,0x22,0x6f, 0x6,0x22,0x2c, 0x4,0x22,0x24, + 0x6,0x21,0x30, 0x6,0x21,0x23, 0xf,0x21,0x6c, 0x4,0x21,0x57, + 0x4,0x23,0x36, 0x4,0x28,0x35, 0x3,0x34,0x3b, 0x3,0x39,0x6d, + 0x3,0x27,0x41, 0x3,0x28,0x6c, 0x3,0x23,0x23, 0x4,0x23,0x37, + 0x4,0x25,0x34, 0x3,0x40,0x34, 0x4,0x21,0x59, 0x3,0x21,0x75, + 0x3,0x21,0x6e, 0x3,0x21,0x71, 0x3,0x21,0x73, 0xf,0x21,0x44, + 0x6,0x23,0x4e, 0x3,0x22,0x71, 0x4,0x22,0x31, 0x3,0x22,0x69, + 0x3,0x22,0x6a, 0xf,0x21,0x72, 0x5,0x23,0x34, 0x3,0x24,0x4a, + 0x3,0x24,0x47, 0x3,0x24,0x4d, 0x6,0x25,0x71, 0x3,0x27,0x46, + 0x5,0x25,0x25, 0x4,0x25,0x39, 0x4,0x25,0x3c, 0x3,0x27,0x45, + 0x5,0x25,0x2b, 0x4,0x25,0x3b, 0x4,0x25,0x38, 0x3,0x27,0x50, + 0xf,0x25,0x4a, 0x3,0x2b,0x31, 0x6,0x2e,0x5a, 0x4,0x28,0x39, + 0x3,0x2b,0x30, 0x5,0x28,0x21, 0x4,0x28,0x3a, 0x3,0x2b,0x2a, + 0x4,0x28,0x37, 0x4,0x28,0x3c, 0x5,0x2b,0x6c, 0x3,0x34,0x49, + 0x3,0x2f,0x52, 0x4,0x2b,0x65, 0x6,0x35,0x38, 0x4,0x30,0x45, + 0x3,0x34,0x3e, 0x3,0x34,0x48, 0x4,0x30,0x4a, 0x4,0x36,0x38, + 0x3,0x39,0x73, 0x4,0x36,0x32, 0x4,0x36,0x37, 0x6,0x46,0x55, + 0x6,0x49,0x7b, 0x3,0x39,0x74, 0x3,0x40,0x35, 0x3,0x40,0x38, + 0x3,0x40,0x3b, 0x4,0x3c,0x2c, 0x4,0x3c,0x2d, 0x4,0x3c,0x28, + 0x4,0x3c,0x2a, 0x5,0x44,0x57, 0x4,0x42,0x37, 0x4,0x42,0x33, + 0x4,0x42,0x2e, 0x3,0x45,0x78, 0x6,0x5a,0x73, 0x4,0x42,0x2f, + 0x3,0x45,0x73, 0x4,0x4f,0x59, 0x3,0x45,0x72, 0x3,0x45,0x6f, + 0x3,0x45,0x77, 0x4,0x42,0x32, 0x4,0x48,0x7b, 0x3,0x4b,0x26, + 0x3,0x4b,0x25, 0x4,0x48,0x7d, 0x3,0x4b,0x24, 0x3,0x4b,0x28, + 0x3,0x4b,0x2a, 0x3,0x50,0x32, 0x4,0x4f,0x5d, 0x5,0x53,0x59, + 0x4,0x4f,0x5b, 0x3,0x54,0x3f, 0x3,0x57,0x53, 0x4,0x5a,0x67, + 0x4,0x5a,0x68, 0x4,0x5f,0x49, 0x4,0x63,0x2f, 0x3,0x5c,0x33, + 0x3,0x5c,0x31, 0x7,0x52,0x74, 0x7,0x57,0x4c, 0x4,0x6a,0x41, + 0x3,0x61,0x3c, 0x4,0x22,0x33, 0xf,0x26,0x5a, 0x4,0x2b,0x69, + 0x3,0x57,0x54, 0x3,0x21,0x76, 0x3,0x22,0x79, 0x3,0x24,0x55, + 0x5,0x23,0x37, 0x6,0x25,0x7b, 0x6,0x25,0x7d, 0x3,0x24,0x56, + 0x3,0x2b,0x38, 0x7,0x4d,0x3d, 0x3,0x2a,0x4c, 0x4,0x30,0x4c, + 0x5,0x31,0x26, 0x4,0x36,0x3d, 0x4,0x3c,0x32, 0x4,0x6a,0x42, + 0x3,0x2b,0x3a, 0x3,0x39,0x78, 0x4,0x49,0x22, 0x3,0x21,0x50, + 0x3,0x23,0x21, 0x3,0x24,0x58, 0x5,0x25,0x2e, 0x3,0x27,0x57, + 0x3,0x27,0x56, 0x3,0x27,0x58, 0x4,0x28,0x43, 0x3,0x2b,0x3c, + 0x3,0x2f,0x5d, 0x3,0x2f,0x5c, 0x4,0x30,0x4d, 0x3,0x39,0x7b, + 0x3,0x39,0x7c, 0x4,0x3c,0x34, 0x3,0x45,0x79, 0x5,0x31,0x29, + 0x4,0x21,0x61, 0x6,0x22,0x41, 0x3,0x21,0x7e, 0x4,0x22,0x3c, + 0x5,0x22,0x30, 0x4,0x23,0x3e, 0x4,0x23,0x3f, 0x4,0x25,0x4a, + 0x4,0x25,0x4c, 0x4,0x25,0x48, 0x4,0x25,0x47, 0x3,0x2b,0x41, + 0x3,0x2b,0x45, 0x3,0x2b,0x42, 0x5,0x2b,0x7c, 0x4,0x30,0x53, + 0x3,0x2f,0x67, 0x3,0x2f,0x69, 0x4,0x30,0x57, 0x4,0x30,0x58, + 0x4,0x30,0x52, 0x5,0x31,0x2c, 0x4,0x30,0x54, 0x4,0x30,0x59, + 0x3,0x3a,0x24, 0x6,0x50,0x6c, 0x4,0x36,0x42, 0x4,0x36,0x45, + 0x3,0x3a,0x22, 0x5,0x3d,0x70, 0x3,0x40,0x42, 0x4,0x42,0x41, + 0x4,0x42,0x43, 0x4,0x42,0x42, 0x4,0x42,0x3c, 0x3,0x45,0x7d, + 0x3,0x45,0x7b, 0x4,0x42,0x3f, 0x4,0x42,0x3e, 0x3,0x45,0x7c, + 0x4,0x49,0x23, 0x4,0x4f,0x62, 0x4,0x4f,0x61, 0x4,0x4f,0x63, + 0x5,0x61,0x3b, 0x4,0x55,0x6c, 0x7,0x3e,0x7d, 0x4,0x5f,0x4a, + 0x4,0x63,0x30, 0x4,0x21,0x64, 0x4,0x22,0x40, 0x4,0x23,0x44, + 0x3,0x24,0x64, 0x4,0x25,0x4f, 0x6,0x29,0x6f, 0x6,0x2f,0x27, + 0x4,0x2b,0x75, 0x3,0x2f,0x6b, 0x4,0x30,0x5a, 0x4,0x36,0x4b, + 0x3,0x46,0x22, 0x4,0x55,0x6f, 0x3,0x54,0x43, 0x4,0x55,0x70, + 0x5,0x53,0x63, 0x4,0x5a,0x6e, 0x4,0x30,0x5c, 0x4,0x36,0x4d, + 0x5,0x3d,0x78, 0x6,0x29,0x72, 0x3,0x34,0x53, 0x5,0x70,0x78, + 0x4,0x23,0x4b, 0x6,0x26,0x38, 0x4,0x2b,0x77, 0x3,0x3a,0x25, + 0x6,0x50,0x76, 0x4,0x3c,0x3e, 0x5,0x44,0x6c, 0x4,0x6d,0x53, + 0x6,0x26,0x36, 0x4,0x36,0x50, 0x3,0x21,0x58, 0x6,0x23,0x71, + 0x3,0x23,0x2c, 0x6,0x50,0x7a, 0x3,0x27,0x64, 0x4,0x21,0x2b, + 0x6,0x21,0x3b, 0x6,0x28,0x64, 0x4,0x25,0x56, 0x3,0x23,0x30, + 0x5,0x22,0x3c, 0x3,0x23,0x2e, 0x3,0x24,0x6a, 0x3,0x24,0x69, + 0x3,0x24,0x68, 0x3,0x27,0x68, 0x6,0x2a,0x2a, 0x3,0x2b,0x4c, + 0x3,0x2f,0x70, 0x4,0x2b,0x7a, 0x3,0x2f,0x71, 0x4,0x36,0x51, + 0x6,0x51,0x22, 0x5,0x4c,0x31, 0x3,0x46,0x24, 0x4,0x49,0x27, + 0x3,0x60,0x70, 0x3,0x21,0x5d, 0x3,0x2f,0x72, 0x6,0x3d,0x61, + 0x3,0x34,0x56, 0x4,0x49,0x29, 0x5,0x21,0x41, 0x3,0x21,0x5f, + 0x3,0x23,0x32, 0x4,0x25,0x5a, 0x4,0x28,0x57, 0x3,0x3f,0x78, + 0x3,0x46,0x27, 0x4,0x47,0x56, 0x4,0x21,0x6b, 0x3,0x22,0x30, + 0x3,0x22,0x2c, 0x3,0x23,0x38, 0x3,0x23,0x36, 0x3,0x24,0x6c, + 0x4,0x23,0x51, 0x3,0x24,0x6b, 0x3,0x24,0x71, 0x4,0x23,0x54, + 0x4,0x23,0x59, 0x3,0x24,0x72, 0x4,0x23,0x53, 0x3,0x24,0x6f, + 0x3,0x24,0x6e, 0x3,0x24,0x7a, 0xf,0x23,0x49, 0x3,0x25,0x25, + 0x3,0x27,0x7a, 0x3,0x27,0x6d, 0x4,0x25,0x5d, 0x3,0x27,0x76, + 0x5,0x25,0x42, 0x6,0x2a,0x39, 0x3,0x2b,0x52, 0x3,0x2b,0x60, + 0x3,0x2b,0x5f, 0x3,0x2b,0x62, 0x3,0x2b,0x5a, 0x4,0x28,0x59, + 0x4,0x28,0x5c, 0x3,0x2b,0x56, 0xf,0x29,0x5c, 0x4,0x2c,0x25, + 0x3,0x2f,0x7d, 0x4,0x2b,0x7e, 0x3,0x2f,0x75, 0x3,0x2f,0x7c, + 0x4,0x2c,0x21, 0x4,0x2b,0x7d, 0x6,0x35,0x7d, 0x3,0x30,0x24, + 0x5,0x2c,0x43, 0x3,0x34,0x5d, 0x3,0x34,0x65, 0x4,0x30,0x6a, + 0x5,0x36,0x70, 0x3,0x34,0x63, 0x3,0x34,0x5c, 0x4,0x30,0x70, + 0x3,0x34,0x5a, 0x4,0x30,0x73, 0x4,0x30,0x71, 0x4,0x30,0x6d, + 0x4,0x30,0x6c, 0xf,0x33,0x43, 0x3,0x38,0x53, 0x4,0x30,0x6f, + 0x5,0x36,0x76, 0x3,0x3a,0x32, 0x4,0x36,0x67, 0x3,0x3a,0x35, + 0x3,0x3a,0x2c, 0x4,0x36,0x5e, 0x4,0x36,0x59, 0x3,0x3a,0x39, + 0x3,0x3a,0x3e, 0x3,0x3a,0x2d, 0x4,0x36,0x60, 0x3,0x3a,0x3d, + 0x4,0x36,0x5f, 0x3,0x3a,0x37, 0x6,0x47,0x39, 0x5,0x36,0x79, + 0x5,0x36,0x7a, 0x3,0x3a,0x30, 0x4,0x36,0x58, 0x4,0x36,0x65, + 0x4,0x36,0x63, 0x3,0x3a,0x41, 0x5,0x36,0x6e, 0x3,0x3a,0x3f, + 0x3,0x3a,0x3a, 0x5,0x3e,0x39, 0x4,0x3c,0x4a, 0x4,0x3c,0x46, + 0x3,0x40,0x4f, 0x5,0x3e,0x3d, 0x4,0x3c,0x47, 0x4,0x3c,0x4c, + 0x3,0x40,0x4d, 0x3,0x40,0x50, 0x6,0x51,0x32, 0x4,0x42,0x52, + 0x3,0x46,0x32, 0x3,0x46,0x2f, 0x3,0x46,0x2d, 0x4,0x42,0x4f, + 0x4,0x42,0x4a, 0x4,0x42,0x55, 0x3,0x46,0x2b, 0x3,0x4b,0x3a, + 0x4,0x42,0x53, 0x4,0x42,0x56, 0x4,0x42,0x51, 0x5,0x45,0x22, + 0x4,0x49,0x30, 0x4,0x49,0x2c, 0x3,0x4b,0x42, 0x4,0x49,0x2d, + 0x3,0x4b,0x36, 0x7,0x21,0x4e, 0x4,0x4f,0x6b, 0x4,0x4f,0x6c, + 0x3,0x50,0x41, 0x4,0x4f,0x67, 0x4,0x4f,0x6a, 0x4,0x4f,0x6f, + 0x3,0x50,0x3c, 0x3,0x50,0x3a, 0x7,0x37,0x37, 0x4,0x55,0x72, + 0x3,0x54,0x46, 0x4,0x55,0x73, 0x4,0x4f,0x6d, 0x5,0x61,0x40, + 0x4,0x5a,0x70, 0x3,0x57,0x56, 0x5,0x61,0x45, 0x4,0x5f,0x4c, + 0x5,0x67,0x59, 0x5,0x6b,0x73, 0x3,0x5c,0x35, 0x3,0x5e,0x27, + 0x4,0x66,0x32, 0x3,0x60,0x2e, 0x3,0x60,0x2d, 0x4,0x6c,0x6c, + 0x7,0x62,0x2f, 0x3,0x22,0x32, 0x3,0x22,0x21, 0x3,0x23,0x3d, + 0x5,0x25,0x53, 0x3,0x27,0x7e, 0x3,0x2b,0x64, 0x3,0x30,0x26, + 0x4,0x42,0x58, 0x4,0x63,0x32, 0x3,0x22,0x33, 0x3,0x25,0x2e, + 0x4,0x23,0x5f, 0x3,0x25,0x39, 0x3,0x25,0x3a, 0x4,0x23,0x5e, + 0x3,0x25,0x3d, 0x3,0x25,0x3f, 0x3,0x25,0x3b, 0x3,0x25,0x34, + 0x3,0x28,0x27, 0x4,0x25,0x6d, 0x3,0x28,0x2b, 0x3,0x28,0x2c, + 0x3,0x2b,0x76, 0x6,0x2f,0x65, 0x3,0x2b,0x74, 0x3,0x2b,0x75, + 0x3,0x2b,0x73, 0x3,0x2b,0x6f, 0x3,0x30,0x29, 0x4,0x2c,0x2f, + 0x4,0x2c,0x31, 0x3,0x30,0x2d, 0x3,0x30,0x2c, 0x3,0x30,0x2e, + 0x3,0x30,0x31, 0x3,0x34,0x6c, 0x3,0x34,0x6d, 0x3,0x34,0x73, + 0x3,0x34,0x6a, 0xf,0x33,0x57, 0x4,0x31,0x21, 0x4,0x36,0x6b, + 0x3,0x3a,0x46, 0x4,0x36,0x6e, 0x3,0x3a,0x51, 0x6,0x47,0x4e, + 0x3,0x3a,0x48, 0x3,0x3a,0x4d, 0x4,0x3c,0x59, 0x4,0x3c,0x5b, + 0x3,0x40,0x53, 0x3,0x40,0x55, 0x4,0x3c,0x56, 0x4,0x3c,0x58, + 0x4,0x42,0x5e, 0x4,0x42,0x5d, 0x4,0x42,0x5b, 0x3,0x46,0x3b, + 0x4,0x42,0x5f, 0x3,0x46,0x39, 0x7,0x21,0x6a, 0x3,0x4b,0x52, + 0x3,0x4b,0x48, 0x4,0x49,0x33, 0x3,0x4b,0x4a, 0x3,0x4b,0x4e, + 0xf,0x4e,0x25, 0xf,0x4e,0x2e, 0x4,0x49,0x2a, 0x3,0x50,0x44, + 0x4,0x4f,0x78, 0x3,0x50,0x47, 0x3,0x50,0x42, 0x3,0x50,0x43, + 0x3,0x50,0x46, 0x3,0x50,0x45, 0x4,0x55,0x7c, 0x3,0x54,0x4d, + 0x3,0x54,0x4a, 0x4,0x55,0x7b, 0x7,0x3f,0x30, 0x3,0x57,0x5d, + 0x7,0x46,0x44, 0x5,0x6b,0x76, 0x3,0x60,0x72, 0x4,0x6c,0x6e, + 0x5,0x37,0x3c, 0x3,0x4d,0x41, 0x3,0x2b,0x78, 0x4,0x28,0x61, + 0x5,0x25,0x58, 0x4,0x36,0x77, 0x4,0x42,0x60, 0x3,0x46,0x47, + 0x4,0x5a,0x7a, 0x3,0x22,0x3a, 0x3,0x23,0x46, 0x3,0x23,0x48, + 0x4,0x23,0x65, 0x3,0x25,0x4a, 0x4,0x25,0x71, 0x5,0x25,0x59, + 0x4,0x25,0x77, 0x4,0x25,0x73, 0x4,0x25,0x78, 0x3,0x2b,0x7d, + 0x4,0x31,0x25, 0x6,0x3e,0x42, 0x3,0x34,0x7a, 0x3,0x3a,0x55, + 0x4,0x3c,0x5c, 0x3,0x50,0x3e, 0x3,0x21,0x74, 0x3,0x23,0x4c, + 0x3,0x23,0x4a, 0x4,0x22,0x56, 0x4,0x22,0x59, 0x4,0x22,0x55, + 0x3,0x23,0x49, 0x3,0x25,0x52, 0x3,0x25,0x57, 0x3,0x25,0x50, + 0x3,0x25,0x4f, 0x3,0x25,0x4d, 0x3,0x25,0x54, 0x3,0x28,0x31, + 0x3,0x28,0x3b, 0x4,0x25,0x7b, 0x3,0x28,0x42, 0x3,0x28,0x32, + 0x3,0x28,0x3a, 0x3,0x28,0x43, 0x3,0x28,0x47, 0x3,0x28,0x34, + 0x4,0x26,0x21, 0x3,0x28,0x44, 0x3,0x28,0x3e, 0x3,0x28,0x36, + 0x3,0x28,0x3c, 0x5,0x25,0x5d, 0x3,0x28,0x39, 0x3,0x28,0x30, + 0x4,0x28,0x6d, 0x4,0x28,0x69, 0x3,0x2b,0x7e, 0x3,0x2c,0x22, + 0xf,0x2a,0x2a, 0x4,0x28,0x67, 0x3,0x30,0x3f, 0x3,0x30,0x42, + 0x3,0x30,0x3d, 0x3,0x30,0x49, 0x3,0x30,0x47, 0x4,0x2c,0x3b, + 0x3,0x30,0x43, 0x3,0x30,0x50, 0x3,0x30,0x4c, 0x3,0x30,0x44, + 0x4,0x2c,0x3f, 0x4,0x2c,0x3a, 0x3,0x30,0x39, 0x4,0x2c,0x3c, + 0x3,0x30,0x51, 0x3,0x30,0x46, 0x3,0x30,0x41, 0x3,0x30,0x3a, + 0xf,0x2e,0x6b, 0xf,0x2e,0x78, 0x4,0x31,0x29, 0x3,0x35,0x26, + 0x3,0x35,0x2d, 0x3,0x35,0x21, 0x3,0x35,0x36, 0x4,0x31,0x28, + 0x3,0x35,0x2c, 0x3,0x35,0x23, 0x3,0x35,0x25, 0x3,0x3a,0x71, + 0x3,0x3a,0x67, 0x3,0x3a,0x74, 0x3,0x3a,0x64, 0x3,0x3a,0x76, + 0x3,0x3a,0x6c, 0x3,0x3a,0x6a, 0x3,0x3a,0x65, 0x5,0x37,0x4e, + 0x3,0x3a,0x6e, 0x5,0x37,0x46, 0x4,0x36,0x7e, 0x3,0x3a,0x6f, + 0x3,0x3a,0x5f, 0x4,0x36,0x7d, 0x3,0x3a,0x70, 0x3,0x3a,0x5d, + 0xf,0x3a,0x3c, 0x3,0x3a,0x6d, 0x3,0x3a,0x69, 0x3,0x3a,0x68, + 0x4,0x3c,0x5f, 0x3,0x40,0x62, 0x4,0x3c,0x61, 0x3,0x40,0x6e, + 0x3,0x40,0x6d, 0x3,0x40,0x68, 0x3,0x40,0x63, 0x4,0x3c,0x64, + 0x3,0x40,0x65, 0x4,0x3c,0x63, 0x3,0x40,0x70, 0x3,0x40,0x6b, + 0x3,0x40,0x6f, 0x3,0x40,0x6c, 0x3,0x40,0x69, 0x3,0x46,0x4b, + 0x4,0x42,0x67, 0x4,0x42,0x6c, 0x4,0x42,0x68, 0x4,0x42,0x66, + 0x3,0x46,0x49, 0x3,0x46,0x52, 0x3,0x46,0x51, 0x4,0x42,0x6b, + 0x4,0x42,0x6d, 0x3,0x46,0x4d, 0x3,0x46,0x4e, 0x4,0x42,0x69, + 0x4,0x49,0x3c, 0x4,0x49,0x3a, 0x3,0x4b,0x59, 0x3,0x4b,0x57, + 0x4,0x49,0x40, 0x3,0x4b,0x55, 0x3,0x50,0x52, 0x3,0x50,0x55, + 0x4,0x50,0x21, 0xf,0x54,0x2a, 0x4,0x56,0x22, 0x4,0x56,0x24, + 0x3,0x57,0x5f, 0x3,0x57,0x60, 0x4,0x5f,0x54, 0x5,0x67,0x5e, + 0x3,0x5a,0x30, 0x3,0x5a,0x32, 0x3,0x5c,0x37, 0x4,0x63,0x35, + 0x3,0x5c,0x38, 0x4,0x66,0x37, 0x4,0x68,0x65, 0x3,0x61,0x62, + 0x3,0x61,0x63, 0x3,0x23,0x4e, 0x6,0x26,0x78, 0x4,0x23,0x6d, + 0x3,0x28,0x49, 0x4,0x28,0x70, 0x4,0x2c,0x41, 0x3,0x30,0x54, + 0x3,0x3a,0x7d, 0x4,0x3c,0x67, 0x7,0x2d,0x2d, 0x3,0x61,0x3d, + 0x3,0x22,0x3c, 0x3,0x23,0x4f, 0x6,0x26,0x79, 0x3,0x25,0x59, + 0x4,0x23,0x70, 0x3,0x25,0x5b, 0x6,0x26,0x7a, 0x3,0x28,0x4f, + 0x5,0x28,0x6e, 0x3,0x2c,0x30, 0x3,0x2c,0x31, 0x3,0x2c,0x33, + 0x4,0x2c,0x42, 0x5,0x2c,0x7c, 0x6,0x36,0x5d, 0x3,0x35,0x42, + 0x3,0x35,0x3d, 0x3,0x35,0x3e, 0x4,0x31,0x2e, 0x6,0x3e,0x5a, + 0x3,0x35,0x40, 0x3,0x3b,0x21, 0x4,0x37,0x22, 0x4,0x3c,0x6a, + 0x4,0x3c,0x6c, 0x4,0x3c,0x6f, 0x3,0x40,0x77, 0x4,0x42,0x74, + 0x4,0x42,0x75, 0x3,0x4b,0x60, 0x4,0x42,0x77, 0x4,0x49,0x43, + 0x4,0x49,0x45, 0x4,0x49,0x46, 0x4,0x5a,0x7d, 0x3,0x5e,0x2b, + 0x7,0x62,0x35, 0x4,0x23,0x71, 0x4,0x26,0x26, 0x6,0x36,0x68, + 0x3,0x3b,0x22, 0x4,0x2c,0x4c, 0x6,0x3e,0x64, 0x4,0x42,0x78, + 0x5,0x4c,0x63, 0x4,0x22,0x5d, 0x4,0x23,0x74, 0x4,0x26,0x28, + 0x4,0x26,0x27, 0x4,0x28,0x74, 0x4,0x28,0x75, 0x4,0x2c,0x4d, + 0x5,0x31,0x75, 0x4,0x31,0x33, 0x5,0x31,0x73, 0x4,0x31,0x32, + 0x4,0x37,0x28, 0x4,0x37,0x29, 0x4,0x3c,0x71, 0x4,0x42,0x79, + 0x3,0x22,0x40, 0x3,0x23,0x53, 0x4,0x26,0x2a, 0x3,0x28,0x52, + 0x3,0x28,0x53, 0x4,0x28,0x79, 0x4,0x28,0x78, 0x3,0x2c,0x39, + 0x3,0x2c,0x38, 0x3,0x2c,0x36, 0x4,0x2c,0x4e, 0x6,0x3e,0x6b, + 0x3,0x35,0x45, 0x4,0x37,0x2b, 0x5,0x37,0x66, 0x4,0x42,0x7d, + 0x4,0x49,0x4a, 0x3,0x5a,0x37, 0x3,0x21,0x62, 0x4,0x23,0x77, + 0x3,0x22,0x42, 0x3,0x22,0x43, 0x3,0x22,0x41, 0x3,0x22,0x44, + 0x3,0x23,0x56, 0x4,0x22,0x61, 0x5,0x22,0x51, 0x4,0x23,0x7b, + 0x5,0x22,0x50, 0x3,0x23,0x57, 0x3,0x23,0x58, 0x4,0x23,0x78, + 0x4,0x23,0x79, 0x3,0x25,0x60, 0x5,0x23,0x70, 0x5,0x23,0x74, + 0x3,0x25,0x64, 0x3,0x25,0x65, 0x4,0x23,0x76, 0x3,0x28,0x5b, + 0x6,0x2a,0x7b, 0x4,0x26,0x31, 0x4,0x26,0x32, 0x4,0x26,0x2e, + 0x3,0x28,0x56, 0x6,0x2a,0x76, 0x3,0x28,0x59, 0x3,0x28,0x5a, + 0x5,0x25,0x6e, 0x3,0x2c,0x3a, 0x4,0x28,0x7b, 0x4,0x2c,0x5b, + 0x4,0x2c,0x53, 0x4,0x2c,0x51, 0x3,0x30,0x60, 0x4,0x2c,0x5f, + 0x4,0x2c,0x55, 0x3,0x30,0x5c, 0x4,0x2c,0x5a, 0x4,0x2c,0x5e, + 0x4,0x2c,0x57, 0x3,0x30,0x5d, 0x6,0x36,0x7c, 0x5,0x2d,0x2e, + 0x3,0x30,0x65, 0x4,0x2c,0x54, 0x3,0x35,0x56, 0x3,0x35,0x49, + 0x4,0x31,0x37, 0x3,0x35,0x4c, 0x4,0x31,0x3d, 0x6,0x3e,0x75, + 0x3,0x35,0x4d, 0x4,0x31,0x39, 0x6,0x3e,0x78, 0x3,0x35,0x50, + 0xf,0x34,0x3f, 0x3,0x35,0x53, 0x3,0x3b,0x2f, 0x3,0x3b,0x32, + 0x3,0x3b,0x29, 0x4,0x37,0x32, 0x4,0x37,0x34, 0x3,0x3b,0x35, + 0x4,0x3c,0x72, 0x3,0x3b,0x30, 0x3,0x3b,0x2c, 0x4,0x3c,0x76, + 0x4,0x3c,0x73, 0x4,0x3c,0x7e, 0x5,0x3e,0x6d, 0x4,0x3d,0x21, + 0x6,0x52,0x34, 0x3,0x40,0x7b, 0x4,0x3c,0x77, 0x4,0x43,0x22, + 0x6,0x5c,0x44, 0x4,0x43,0x2d, 0x4,0x43,0x2a, 0x4,0x43,0x21, + 0x3,0x46,0x55, 0x4,0x43,0x24, 0x3,0x46,0x5b, 0x3,0x46,0x58, + 0x4,0x43,0x2e, 0x3,0x46,0x57, 0x4,0x49,0x50, 0x4,0x49,0x4c, + 0x5,0x4c,0x6c, 0x3,0x4b,0x62, 0x5,0x4c,0x68, 0x4,0x49,0x4b, + 0x4,0x49,0x53, 0x3,0x4b,0x64, 0x4,0x49,0x4f, 0x4,0x49,0x4d, + 0x3,0x4b,0x61, 0x4,0x49,0x54, 0x4,0x50,0x26, 0x4,0x50,0x27, + 0x4,0x56,0x28, 0x4,0x50,0x25, 0x5,0x54,0x36, 0x3,0x50,0x59, + 0x7,0x2d,0x4c, 0x3,0x54,0x5a, 0x3,0x54,0x56, 0x5,0x5b,0x3c, + 0x4,0x56,0x27, 0x3,0x54,0x58, 0x7,0x3f,0x44, 0x4,0x5f,0x5a, + 0x5,0x67,0x63, 0x5,0x67,0x64, 0x4,0x66,0x3a, 0x3,0x5e,0x2c, + 0x4,0x68,0x68, 0x5,0x7b,0x3d, 0x3,0x23,0x5b, 0x6,0x21,0x6e, + 0x3,0x3b,0x38, 0x4,0x49,0x55, 0x3,0x22,0x45, 0x4,0x31,0x42, + 0x3,0x22,0x46, 0x4,0x22,0x65, 0x4,0x22,0x66, 0x3,0x23,0x5d, + 0x4,0x24,0x22, 0x4,0x24,0x24, 0x3,0x25,0x69, 0x4,0x24,0x21, + 0x3,0x25,0x6a, 0xf,0x24,0x25, 0x4,0x26,0x36, 0x4,0x26,0x37, + 0x4,0x29,0x25, 0x4,0x24,0x25, 0x4,0x29,0x22, 0x4,0x29,0x24, + 0x6,0x30,0x63, 0x3,0x2c,0x47, 0x4,0x29,0x23, 0x4,0x29,0x21, + 0x4,0x2c,0x66, 0x4,0x2c,0x68, 0x4,0x31,0x47, 0x4,0x31,0x48, + 0x4,0x31,0x45, 0x4,0x31,0x49, 0x3,0x35,0x5c, 0x4,0x37,0x3b, + 0x4,0x37,0x36, 0x4,0x37,0x3d, 0x4,0x37,0x3a, 0x3,0x3b,0x3c, + 0x4,0x37,0x3c, 0x3,0x3b,0x39, 0x4,0x37,0x39, 0x4,0x3d,0x28, + 0x4,0x3d,0x23, 0x4,0x3d,0x27, 0x4,0x3d,0x26, 0x4,0x3d,0x29, + 0x4,0x43,0x33, 0x4,0x43,0x32, 0x4,0x43,0x31, 0x4,0x43,0x2f, + 0x3,0x4b,0x6e, 0x3,0x4b,0x6f, 0x4,0x50,0x29, 0x4,0x56,0x2d, + 0x4,0x56,0x2b, 0x4,0x63,0x3b, 0x4,0x63,0x3a, 0x3,0x5f,0x44, + 0x4,0x68,0x6b, 0x6,0x48,0x44, 0x3,0x46,0x5e, 0x4,0x50,0x2b, + 0x3,0x23,0x60, 0x3,0x23,0x5f, 0x3,0x23,0x5e, 0x3,0x25,0x6c, + 0x6,0x27,0x47, 0x4,0x26,0x38, 0x4,0x26,0x3d, 0x4,0x26,0x3b, + 0x5,0x26,0x26, 0x4,0x26,0x3c, 0x3,0x28,0x64, 0x4,0x26,0x3a, + 0x3,0x28,0x66, 0xf,0x2f,0x38, 0x3,0x2c,0x49, 0x3,0x2c,0x4a, + 0x4,0x29,0x2a, 0x5,0x29,0x26, 0x4,0x29,0x29, 0x4,0x29,0x28, + 0x4,0x2c,0x6b, 0x4,0x2c,0x6d, 0x4,0x2c,0x6c, 0x3,0x30,0x6d, + 0x3,0x35,0x5e, 0x4,0x31,0x4e, 0x4,0x31,0x4c, 0x4,0x31,0x4f, + 0x3,0x35,0x5d, 0x5,0x38,0x29, 0x4,0x37,0x40, 0x4,0x37,0x41, + 0x3,0x3b,0x41, 0x5,0x3f,0x21, 0x4,0x43,0x36, 0x3,0x46,0x5f, + 0x4,0x43,0x39, 0x4,0x43,0x3a, 0x4,0x49,0x5b, 0x4,0x49,0x5c, + 0x3,0x4b,0x71, 0x3,0x50,0x5d, 0x4,0x50,0x2c, 0x4,0x50,0x2e, + 0x5,0x54,0x42, 0x4,0x5f,0x5e, 0x4,0x63,0x3c, 0x4,0x24,0x29, + 0x3,0x28,0x6a, 0x3,0x46,0x62, 0x7,0x2d,0x5b, 0x4,0x29,0x2b, + 0x4,0x3d,0x2d, 0x6,0x21,0x79, 0x4,0x22,0x6a, 0x3,0x23,0x63, + 0x3,0x23,0x64, 0x3,0x25,0x70, 0x3,0x28,0x6f, 0x4,0x26,0x40, + 0x4,0x26,0x41, 0x3,0x2c,0x4e, 0x4,0x29,0x2d, 0x6,0x30,0x7a, + 0x4,0x29,0x2e, 0x3,0x2c,0x4f, 0x4,0x2c,0x71, 0x5,0x32,0x46, + 0x4,0x31,0x51, 0x4,0x2c,0x72, 0x3,0x3b,0x46, 0x3,0x3b,0x43, + 0x5,0x3f,0x29, 0x4,0x3d,0x2f, 0x4,0x3d,0x2e, 0x6,0x52,0x4d, + 0x4,0x49,0x5d, 0x4,0x49,0x5f, 0x3,0x5e,0x2e, 0x4,0x26,0x42, + 0x4,0x50,0x31, 0x6,0x24,0x70, 0x3,0x28,0x73, 0x4,0x26,0x43, + 0x3,0x28,0x72, 0x3,0x35,0x64, 0x3,0x3b,0x48, 0x3,0x3b,0x49, + 0x4,0x43,0x3b, 0x4,0x49,0x61, 0x3,0x50,0x5f, 0x3,0x22,0x4b, + 0x6,0x2b,0x3e, 0x3,0x28,0x74, 0x4,0x29,0x32, 0x4,0x29,0x34, + 0x3,0x2c,0x52, 0x5,0x29,0x2f, 0x5,0x29,0x33, 0x3,0x2c,0x53, + 0x6,0x31,0x25, 0x5,0x2d,0x47, 0xf,0x2f,0x3e, 0x4,0x31,0x54, + 0x3,0x35,0x66, 0x3,0x35,0x67, 0x4,0x37,0x49, 0x3,0x3b,0x4a, + 0x4,0x37,0x48, 0x4,0x3d,0x33, 0x5,0x45,0x69, 0x4,0x43,0x3d, + 0x6,0x5c,0x67, 0x3,0x50,0x60, 0x4,0x50,0x34, 0x4,0x56,0x2f, + 0x6,0x21,0x7e, 0x3,0x23,0x65, 0x3,0x23,0x68, 0x4,0x24,0x31, + 0x5,0x22,0x67, 0x4,0x22,0x70, 0x3,0x28,0x7b, 0x3,0x28,0x7d, + 0x3,0x25,0x79, 0x4,0x24,0x2e, 0x3,0x28,0x7c, 0x4,0x24,0x30, + 0x4,0x24,0x33, 0x3,0x25,0x73, 0x4,0x24,0x2f, 0x4,0x24,0x32, + 0x3,0x26,0x24, 0x3,0x28,0x79, 0x4,0x29,0x35, 0x4,0x29,0x37, + 0x4,0x26,0x4d, 0x3,0x2c,0x59, 0x3,0x29,0x24, 0x4,0x26,0x48, + 0x3,0x29,0x23, 0x4,0x26,0x4e, 0x4,0x26,0x4c, 0x4,0x26,0x46, + 0xf,0x2a,0x3e, 0x3,0x2c,0x58, 0x4,0x29,0x41, 0x3,0x2c,0x62, + 0x4,0x29,0x3c, 0x4,0x26,0x49, 0x4,0x29,0x39, 0x3,0x30,0x7d, + 0x6,0x37,0x54, 0x4,0x29,0x3d, 0x5,0x29,0x35, 0x4,0x2d,0x28, + 0x4,0x29,0x48, 0x4,0x29,0x3a, 0x4,0x29,0x3b, 0x4,0x29,0x40, + 0x3,0x2c,0x55, 0x6,0x37,0x5a, 0x3,0x30,0x7c, 0x3,0x2c,0x5e, + 0x4,0x31,0x5b, 0x5,0x2d,0x5a, 0x3,0x35,0x73, 0x4,0x2d,0x22, + 0x3,0x35,0x69, 0x3,0x30,0x75, 0x4,0x2d,0x23, 0x3,0x35,0x70, + 0x4,0x2d,0x24, 0x3,0x30,0x77, 0x6,0x37,0x5e, 0x3,0x31,0x24, + 0x4,0x2d,0x2b, 0x4,0x31,0x5a, 0x4,0x31,0x5c, 0x4,0x31,0x62, + 0x3,0x35,0x6b, 0x6,0x48,0x6f, 0x4,0x31,0x63, 0x3,0x35,0x75, + 0x4,0x31,0x60, 0x5,0x32,0x5b, 0x4,0x31,0x5d, 0x3,0x35,0x6c, + 0x3,0x3b,0x4e, 0x4,0x31,0x6c, 0x4,0x31,0x67, 0x3,0x3b,0x4c, + 0x3,0x35,0x6d, 0x3,0x35,0x77, 0x3,0x3b,0x57, 0x4,0x31,0x64, + 0x6,0x48,0x75, 0x3,0x3b,0x53, 0x4,0x31,0x66, 0x4,0x31,0x5e, + 0x5,0x2d,0x57, 0x3,0x3b,0x52, 0x5,0x38,0x42, 0x4,0x31,0x6a, + 0x5,0x38,0x48, 0x4,0x37,0x56, 0x4,0x37,0x50, 0x3,0x3b,0x5c, + 0x4,0x37,0x59, 0x3,0x3b,0x5f, 0x4,0x37,0x54, 0x4,0x37,0x4e, + 0x5,0x3f,0x32, 0x3,0x41,0x25, 0x4,0x37,0x55, 0x4,0x3d,0x3e, + 0x3,0x3b,0x60, 0x4,0x3d,0x37, 0x5,0x32,0x58, 0x3,0x3b,0x5b, + 0x3,0x41,0x26, 0x3,0x41,0x2d, 0x4,0x3d,0x3b, 0x4,0x43,0x43, + 0x5,0x3f,0x42, 0x6,0x52,0x69, 0x3,0x46,0x67, 0x4,0x3d,0x3a, + 0x4,0x3d,0x3c, 0x3,0x41,0x30, 0x3,0x46,0x65, 0x4,0x43,0x42, + 0x4,0x43,0x50, 0x3,0x46,0x66, 0x3,0x41,0x2f, 0x4,0x43,0x48, + 0x4,0x43,0x47, 0x4,0x43,0x49, 0x3,0x4b,0x7d, 0x4,0x43,0x4d, + 0x4,0x49,0x65, 0x3,0x4c,0x22, 0x3,0x46,0x69, 0x3,0x4b,0x7b, + 0x4,0x43,0x4a, 0x4,0x43,0x4c, 0x4,0x43,0x46, 0x3,0x4c,0x27, + 0x3,0x4b,0x78, 0x4,0x43,0x4b, 0x4,0x50,0x38, 0x3,0x4c,0x2a, + 0x4,0x49,0x67, 0x4,0x49,0x69, 0x4,0x49,0x68, 0x4,0x49,0x6b, + 0x7,0x22,0x7c, 0x4,0x49,0x6d, 0x3,0x50,0x69, 0x4,0x49,0x6c, + 0x3,0x4c,0x26, 0x4,0x50,0x39, 0x5,0x5b,0x4c, 0x4,0x5b,0x23, + 0x4,0x5b,0x29, 0x4,0x56,0x36, 0x4,0x5b,0x25, 0x3,0x57,0x67, + 0x4,0x5b,0x24, 0xf,0x5a,0x29, 0x3,0x57,0x66, 0x4,0x50,0x3a, + 0x5,0x67,0x78, 0x4,0x63,0x43, 0x4,0x5f,0x64, 0x5,0x67,0x73, + 0x7,0x47,0x2c, 0x3,0x5e,0x30, 0x4,0x63,0x42, 0x4,0x63,0x40, + 0x3,0x5f,0x47, 0x4,0x68,0x6c, 0x3,0x61,0x78, 0x3,0x23,0x6a, + 0x3,0x26,0x26, 0x4,0x26,0x54, 0x6,0x2b,0x52, 0x4,0x2d,0x2f, + 0x4,0x2d,0x30, 0x5,0x2d,0x5d, 0x3,0x35,0x7a, 0x3,0x3b,0x65, + 0x4,0x3d,0x42, 0x4,0x43,0x54, 0x5,0x4d,0x37, 0x3,0x4c,0x2b, + 0x3,0x54,0x62, 0x6,0x27,0x6e, 0x4,0x26,0x55, 0x4,0x26,0x56, + 0x4,0x29,0x4d, 0x3,0x2c,0x64, 0x4,0x21,0x7b, 0x4,0x21,0x7a, + 0x3,0x22,0x4f, 0x4,0x22,0x74, 0x4,0x22,0x73, 0x4,0x22,0x75, + 0x4,0x24,0x3a, 0x4,0x24,0x36, 0x3,0x26,0x2c, 0x3,0x26,0x2d, + 0x3,0x26,0x30, 0x3,0x26,0x2b, 0x4,0x26,0x58, 0x3,0x29,0x2d, + 0x5,0x26,0x3a, 0x3,0x29,0x2c, 0x3,0x29,0x38, 0x4,0x29,0x55, + 0x4,0x2d,0x33, 0x4,0x26,0x59, 0x3,0x29,0x2b, 0xf,0x27,0x2e, + 0x4,0x29,0x4e, 0x4,0x29,0x54, 0x3,0x2c,0x66, 0x3,0x29,0x27, + 0x3,0x2c,0x67, 0x3,0x2c,0x69, 0x4,0x2d,0x3c, 0x3,0x2c,0x71, + 0x4,0x29,0x56, 0x3,0x2c,0x68, 0x4,0x29,0x52, 0x4,0x2d,0x32, + 0x4,0x2d,0x31, 0x3,0x2c,0x6a, 0x3,0x2c,0x65, 0x3,0x31,0x34, + 0x3,0x31,0x2a, 0x3,0x35,0x7b, 0x3,0x31,0x31, 0x3,0x31,0x3a, + 0x4,0x2d,0x3b, 0x3,0x31,0x2d, 0x3,0x31,0x2b, 0x4,0x31,0x7c, + 0x4,0x32,0x21, 0x4,0x31,0x7b, 0x3,0x36,0x2c, 0x6,0x40,0x32, + 0x4,0x32,0x25, 0x3,0x36,0x2f, 0x3,0x36,0x30, 0x4,0x31,0x79, + 0x3,0x35,0x7e, 0x4,0x31,0x71, 0x3,0x36,0x25, 0x4,0x31,0x7e, + 0x4,0x31,0x7a, 0x3,0x3b,0x6b, 0x3,0x36,0x2a, 0x4,0x37,0x6e, + 0x4,0x37,0x62, 0x3,0x36,0x21, 0x4,0x3d,0x45, 0x3,0x41,0x31, + 0x4,0x37,0x64, 0x3,0x3b,0x6a, 0x4,0x37,0x6b, 0x4,0x37,0x68, + 0x4,0x37,0x65, 0x3,0x3b,0x6c, 0x3,0x3b,0x69, 0x4,0x37,0x70, + 0x4,0x37,0x61, 0x3,0x3b,0x6e, 0x4,0x3d,0x50, 0x4,0x3d,0x4f, + 0x3,0x41,0x37, 0x4,0x3d,0x4c, 0x4,0x3d,0x4a, 0x3,0x41,0x35, + 0x3,0x41,0x3b, 0x4,0x3d,0x48, 0x4,0x3d,0x4e, 0x3,0x41,0x3c, + 0x3,0x41,0x4a, 0x3,0x41,0x43, 0x3,0x41,0x3f, 0x3,0x41,0x47, + 0x3,0x41,0x40, 0x3,0x41,0x46, 0x3,0x41,0x41, 0x3,0x41,0x39, + 0x4,0x43,0x58, 0x4,0x43,0x61, 0x6,0x5d,0x32, 0x3,0x46,0x79, + 0x3,0x47,0x2e, 0x3,0x47,0x2d, 0x4,0x43,0x56, 0x3,0x46,0x7c, + 0x3,0x47,0x27, 0x3,0x47,0x2f, 0x4,0x43,0x5c, 0x3,0x46,0x77, + 0x5,0x46,0x25, 0x3,0x46,0x7d, 0x4,0x49,0x75, 0x3,0x4c,0x36, + 0x4,0x43,0x64, 0x5,0x46,0x23, 0x3,0x47,0x2b, 0x3,0x47,0x2c, + 0x4,0x4a,0x24, 0x3,0x4c,0x33, 0x7,0x23,0x3a, 0x4,0x49,0x79, + 0x4,0x49,0x7a, 0x4,0x49,0x76, 0x4,0x4a,0x28, 0x4,0x4a,0x22, + 0x5,0x4d,0x3a, 0x4,0x49,0x7e, 0x5,0x4d,0x3e, 0x3,0x4c,0x3c, + 0x4,0x4a,0x23, 0x3,0x50,0x74, 0x4,0x56,0x39, 0x4,0x50,0x45, + 0x3,0x50,0x73, 0x3,0x50,0x6e, 0x3,0x50,0x78, 0x3,0x50,0x72, + 0x3,0x50,0x71, 0x3,0x54,0x65, 0x3,0x54,0x6a, 0x3,0x54,0x68, + 0x3,0x54,0x63, 0x3,0x54,0x66, 0x4,0x5b,0x2d, 0x3,0x57,0x69, + 0x4,0x5b,0x32, 0x4,0x5b,0x30, 0x4,0x5b,0x2e, 0x3,0x57,0x6f, + 0x3,0x57,0x71, 0x4,0x5b,0x31, 0x3,0x57,0x68, 0x4,0x5b,0x2f, + 0x3,0x57,0x72, 0xf,0x5e,0x73, 0x3,0x5a,0x3d, 0x3,0x5a,0x3e, + 0x4,0x63,0x47, 0x3,0x5c,0x40, 0x4,0x63,0x46, 0x5,0x70,0x24, + 0x3,0x5e,0x32, 0x4,0x66,0x40, 0x3,0x60,0x31, 0x4,0x6a,0x49, + 0x4,0x6a,0x48, 0x5,0x79,0x2a, 0x4,0x26,0x5b, 0x4,0x2d,0x40, + 0x4,0x2d,0x3f, 0x4,0x32,0x27, 0x4,0x3d,0x54, 0x4,0x24,0x40, + 0x3,0x26,0x3a, 0x4,0x26,0x5e, 0x4,0x26,0x5f, 0x4,0x29,0x5d, + 0x3,0x2c,0x75, 0x3,0x31,0x3e, 0x4,0x2d,0x42, 0x6,0x38,0x2b, + 0x3,0x36,0x33, 0x4,0x32,0x28, 0x3,0x36,0x35, 0x4,0x32,0x2c, + 0x4,0x37,0x79, 0x4,0x37,0x75, 0x4,0x37,0x78, 0x4,0x37,0x77, + 0x4,0x37,0x76, 0x5,0x38,0x7c, 0x3,0x3b,0x77, 0x4,0x3d,0x5c, + 0x4,0x3d,0x59, 0x4,0x3d,0x5b, 0x3,0x41,0x4c, 0x4,0x43,0x66, + 0x5,0x46,0x30, 0x5,0x46,0x2e, 0x4,0x43,0x69, 0x4,0x4a,0x2b, + 0x4,0x4a,0x2a, 0x4,0x4a,0x29, 0x4,0x50,0x49, 0x4,0x50,0x4c, + 0x3,0x57,0x73, 0x4,0x5b,0x3a, 0x4,0x63,0x4c, 0x4,0x66,0x43, + 0x3,0x26,0x3b, 0x6,0x38,0x2c, 0x3,0x41,0x4f, 0x3,0x29,0x3a, + 0x4,0x29,0x61, 0x3,0x31,0x41, 0x3,0x39,0x2b, 0x3,0x3b,0x78, + 0x4,0x4a,0x2e, 0x4,0x56,0x3e, 0x4,0x6a,0x4b, 0x4,0x29,0x62, + 0x4,0x2d,0x49, 0x6,0x38,0x30, 0x6,0x49,0x61, 0x6,0x5d,0x51, + 0x5,0x4d,0x4b, 0x3,0x23,0x71, 0x6,0x2b,0x70, 0x6,0x38,0x34, + 0x3,0x36,0x3b, 0x3,0x36,0x3e, 0x4,0x3d,0x65, 0x4,0x4a,0x30, + 0x4,0x4a,0x31, 0x4,0x22,0x78, 0x4,0x22,0x79, 0x4,0x24,0x43, + 0x3,0x26,0x3c, 0x3,0x26,0x3f, 0x3,0x26,0x3e, 0x3,0x26,0x40, + 0x3,0x29,0x3f, 0x3,0x29,0x3d, 0x4,0x26,0x63, 0x5,0x29,0x4f, + 0x4,0x29,0x63, 0x3,0x2c,0x7b, 0x4,0x29,0x64, 0x4,0x29,0x65, + 0x3,0x2c,0x78, 0x3,0x2d,0x26, 0x6,0x31,0x67, 0x4,0x2d,0x4c, + 0x4,0x32,0x3b, 0x4,0x2d,0x4b, 0x3,0x31,0x47, 0x6,0x38,0x37, + 0x3,0x31,0x4a, 0xf,0x2f,0x6e, 0x4,0x2d,0x4d, 0x6,0x40,0x51, + 0x4,0x32,0x36, 0x4,0x32,0x3a, 0x4,0x32,0x37, 0x3,0x36,0x43, + 0x6,0x40,0x4f, 0x3,0x3c,0x22, 0x4,0x37,0x7e, 0x3,0x3b,0x7a, + 0x3,0x3b,0x7b, 0x4,0x38,0x25, 0x3,0x3c,0x27, 0x4,0x38,0x22, + 0x6,0x49,0x73, 0x3,0x3c,0x21, 0x6,0x53,0x3d, 0x5,0x3f,0x62, + 0x3,0x41,0x52, 0x3,0x41,0x57, 0x3,0x41,0x5a, 0x3,0x41,0x55, + 0x3,0x41,0x53, 0x3,0x41,0x5c, 0x3,0x41,0x58, 0x4,0x3d,0x68, + 0x4,0x3d,0x67, 0x3,0x41,0x54, 0x3,0x47,0x38, 0x4,0x43,0x6e, + 0x3,0x47,0x32, 0x3,0x47,0x36, 0x5,0x4d,0x53, 0x4,0x4a,0x32, + 0x3,0x4c,0x42, 0x3,0x4c,0x45, 0x4,0x50,0x52, 0x4,0x50,0x51, + 0x3,0x51,0x21, 0x5,0x4d,0x50, 0x3,0x50,0x7b, 0x3,0x50,0x7c, + 0x4,0x50,0x53, 0x7,0x2e,0x5a, 0x3,0x54,0x73, 0x3,0x54,0x6e, + 0x4,0x56,0x40, 0x4,0x5b,0x40, 0x4,0x5b,0x41, 0x4,0x5b,0x3f, + 0x7,0x3f,0x76, 0x3,0x5a,0x40, 0x3,0x5a,0x41, 0x3,0x5c,0x44, + 0x3,0x5f,0x4c, 0x3,0x5f,0x4d, 0x5,0x75,0x6e, 0x5,0x75,0x6d, + 0x3,0x23,0x74, 0x4,0x50,0x56, 0x3,0x54,0x74, 0x3,0x29,0x44, + 0x3,0x31,0x4e, 0x5,0x2e,0x25, 0x3,0x36,0x49, 0x3,0x3c,0x28, + 0x4,0x3a,0x43, 0x5,0x46,0x45, 0x5,0x4d,0x58, 0x3,0x51,0x25, + 0x3,0x23,0x76, 0x3,0x26,0x43, 0x4,0x24,0x48, 0x3,0x26,0x46, + 0x3,0x29,0x4b, 0x3,0x29,0x46, 0xf,0x27,0x4c, 0x3,0x29,0x50, + 0x3,0x29,0x4d, 0x5,0x26,0x51, 0x3,0x2d,0x28, 0x3,0x2d,0x2c, + 0x4,0x29,0x6f, 0x4,0x29,0x6c, 0x3,0x2d,0x29, 0x4,0x2d,0x57, + 0x4,0x2d,0x51, 0x4,0x2d,0x54, 0x4,0x2d,0x58, 0x3,0x31,0x52, + 0x5,0x2e,0x2b, 0x4,0x2d,0x52, 0x4,0x2d,0x5b, 0x3,0x31,0x55, + 0x4,0x2d,0x56, 0x3,0x31,0x51, 0x3,0x36,0x59, 0x4,0x32,0x43, + 0x3,0x36,0x4a, 0x3,0x36,0x4f, 0x5,0x32,0x79, 0x4,0x32,0x42, + 0x4,0x32,0x46, 0x4,0x32,0x41, 0x4,0x38,0x34, 0x3,0x36,0x58, + 0x3,0x36,0x5d, 0x4,0x38,0x2f, 0x3,0x3c,0x2e, 0x4,0x38,0x2c, + 0x3,0x3c,0x3f, 0x3,0x3c,0x30, 0x4,0x38,0x2a, 0x5,0x39,0x33, + 0x4,0x38,0x2d, 0x3,0x3c,0x2c, 0x5,0x39,0x39, 0x4,0x38,0x35, + 0x3,0x3c,0x35, 0x4,0x38,0x37, 0x3,0x3c,0x36, 0x3,0x3c,0x43, + 0x3,0x3c,0x2b, 0x3,0x3c,0x2d, 0x4,0x3d,0x78, 0x3,0x41,0x71, + 0x3,0x41,0x66, 0x3,0x41,0x70, 0x4,0x3d,0x6b, 0x4,0x3d,0x6e, + 0x4,0x3d,0x6f, 0x3,0x41,0x6c, 0x3,0x41,0x69, 0x3,0x41,0x64, + 0x4,0x3d,0x6d, 0x3,0x41,0x5e, 0x4,0x3d,0x75, 0x3,0x41,0x62, + 0x3,0x41,0x63, 0x3,0x41,0x7a, 0x3,0x41,0x61, 0x3,0x41,0x5f, + 0x4,0x44,0x23, 0x4,0x3d,0x76, 0x3,0x41,0x60, 0x3,0x42,0x5a, + 0x3,0x41,0x67, 0xf,0x48,0x55, 0x4,0x44,0x24, 0x4,0x43,0x75, + 0x4,0x44,0x21, 0x4,0x43,0x7c, 0x3,0x47,0x3f, 0x4,0x43,0x78, + 0x4,0x43,0x73, 0x3,0x47,0x41, 0x4,0x43,0x74, 0x3,0x47,0x4a, + 0x4,0x43,0x7d, 0x4,0x43,0x7e, 0x4,0x43,0x7a, 0x4,0x44,0x22, + 0x3,0x47,0x4f, 0x3,0x47,0x40, 0x4,0x44,0x25, 0x4,0x43,0x71, + 0x5,0x46,0x4b, 0x3,0x47,0x49, 0x4,0x3d,0x72, 0x3,0x47,0x50, + 0xf,0x48,0x52, 0x3,0x4c,0x4e, 0x5,0x4d,0x6d, 0x4,0x4a,0x3a, + 0x3,0x4c,0x4c, 0x5,0x4d,0x61, 0x3,0x4c,0x53, 0x4,0x4a,0x37, + 0x4,0x4a,0x36, 0x3,0x4c,0x5d, 0x3,0x4c,0x58, 0x7,0x23,0x6f, + 0x4,0x4a,0x38, 0x4,0x4a,0x42, 0x3,0x4c,0x5a, 0x3,0x4c,0x5c, + 0x3,0x4c,0x48, 0x3,0x4c,0x55, 0x3,0x51,0x43, 0x3,0x51,0x42, + 0x4,0x50,0x60, 0x4,0x50,0x5a, 0x3,0x51,0x37, 0x3,0x51,0x30, + 0x4,0x50,0x59, 0x4,0x4a,0x39, 0x3,0x51,0x3f, 0x3,0x51,0x2a, + 0x3,0x51,0x3d, 0x4,0x56,0x49, 0x3,0x51,0x33, 0x3,0x51,0x39, + 0x3,0x4c,0x4b, 0x4,0x50,0x5e, 0x3,0x51,0x2d, 0x4,0x50,0x64, + 0x3,0x51,0x35, 0x3,0x51,0x34, 0x3,0x51,0x36, 0x3,0x55,0x22, + 0x4,0x56,0x48, 0x3,0x54,0x7e, 0x3,0x55,0x25, 0x3,0x54,0x7d, + 0x4,0x56,0x4b, 0x7,0x38,0x55, 0x5,0x5b,0x68, 0x3,0x54,0x77, + 0x3,0x55,0x26, 0xf,0x5f,0x29, 0x3,0x54,0x79, 0x3,0x55,0x28, + 0x4,0x5b,0x48, 0x4,0x5b,0x44, 0x3,0x57,0x7c, 0x4,0x5b,0x4a, + 0x4,0x5b,0x49, 0x4,0x5f,0x6f, 0x4,0x5f,0x73, 0x3,0x5a,0x49, + 0x4,0x5f,0x70, 0x4,0x5f,0x6e, 0x4,0x5f,0x72, 0x4,0x5f,0x75, + 0x3,0x5a,0x4c, 0x3,0x5a,0x4b, 0xf,0x62,0x53, 0x3,0x5a,0x4a, + 0x3,0x5c,0x4c, 0x3,0x5c,0x46, 0x4,0x63,0x51, 0x4,0x63,0x4f, + 0x3,0x5c,0x48, 0x3,0x5c,0x4d, 0x4,0x63,0x54, 0x3,0x5c,0x4b, + 0x3,0x5c,0x45, 0xf,0x65,0x3e, 0x5,0x70,0x27, 0x3,0x5e,0x36, + 0x3,0x5c,0x4a, 0x3,0x5f,0x50, 0x4,0x68,0x6e, 0x3,0x60,0x35, + 0x3,0x60,0x33, 0x3,0x60,0x34, 0x5,0x24,0x48, 0x6,0x28,0x30, + 0x4,0x26,0x6d, 0x5,0x26,0x56, 0x4,0x26,0x70, 0x4,0x26,0x6c, + 0x4,0x2d,0x60, 0x4,0x29,0x70, 0x4,0x29,0x71, 0x6,0x31,0x78, + 0x4,0x29,0x74, 0x4,0x29,0x73, 0x5,0x2e,0x2e, 0x4,0x2d,0x5d, + 0x4,0x2d,0x61, 0x4,0x2d,0x62, 0x4,0x2d,0x5e, 0x3,0x36,0x61, + 0x4,0x32,0x48, 0x4,0x32,0x49, 0x6,0x40,0x6e, 0x4,0x38,0x3b, + 0x4,0x38,0x39, 0x3,0x3c,0x46, 0x5,0x39,0x43, 0x4,0x38,0x3c, + 0x6,0x38,0x64, 0x4,0x3e,0x21, 0x4,0x3d,0x7c, 0x4,0x3d,0x7b, + 0x4,0x3d,0x7d, 0x4,0x3d,0x7e, 0x4,0x3e,0x22, 0x3,0x47,0x52, + 0x6,0x5d,0x77, 0x4,0x44,0x2a, 0x4,0x4a,0x4c, 0x3,0x4c,0x68, + 0x4,0x50,0x66, 0x4,0x50,0x67, 0x4,0x56,0x4f, 0x4,0x56,0x4e, + 0x3,0x55,0x2a, 0x3,0x55,0x2c, 0x4,0x5f,0x77, 0x7,0x4e,0x22, + 0x4,0x68,0x71, 0x5,0x75,0x77, 0x5,0x79,0x2f, 0x6,0x25,0x25, + 0x3,0x2d,0x3e, 0x3,0x2b,0x7b, 0x3,0x3c,0x48, 0x4,0x38,0x3f, + 0x5,0x46,0x5f, 0x3,0x58,0x24, 0x4,0x22,0x7c, 0x3,0x29,0x57, + 0x5,0x26,0x62, 0x4,0x26,0x75, 0x3,0x2d,0x3f, 0x3,0x2d,0x41, + 0x3,0x2d,0x40, 0x3,0x31,0x69, 0x3,0x36,0x63, 0x4,0x32,0x4a, + 0x4,0x38,0x45, 0x4,0x38,0x44, 0x4,0x38,0x46, 0x4,0x38,0x42, + 0x3,0x3c,0x4a, 0x3,0x42,0x23, 0x4,0x3e,0x23, 0x4,0x3e,0x24, + 0x3,0x42,0x24, 0x4,0x44,0x32, 0x5,0x46,0x60, 0x4,0x44,0x33, + 0x4,0x44,0x30, 0x4,0x4a,0x50, 0x4,0x4a,0x4f, 0x4,0x50,0x6b, + 0x4,0x50,0x6a, 0x4,0x56,0x51, 0x4,0x63,0x55, 0x3,0x5c,0x4e, + 0x5,0x75,0x78, 0x5,0x24,0x4e, 0x4,0x26,0x78, 0x4,0x2d,0x64, + 0x3,0x31,0x6b, 0x4,0x32,0x4f, 0x4,0x38,0x49, 0x4,0x38,0x4a, + 0x4,0x38,0x4b, 0x3,0x42,0x25, 0x4,0x44,0x35, 0x3,0x51,0x47, + 0x3,0x51,0x48, 0x4,0x50,0x6e, 0x4,0x56,0x53, 0x3,0x58,0x25, + 0x4,0x29,0x7b, 0x3,0x23,0x7b, 0x4,0x26,0x79, 0x3,0x29,0x5b, + 0x4,0x26,0x7a, 0xf,0x27,0x5b, 0x3,0x2d,0x43, 0x4,0x2d,0x66, + 0x4,0x32,0x52, 0x4,0x32,0x54, 0x4,0x32,0x53, 0x4,0x32,0x55, + 0x3,0x36,0x67, 0x4,0x2d,0x67, 0x4,0x32,0x51, 0x5,0x39,0x5b, + 0x3,0x3c,0x4c, 0x4,0x38,0x4f, 0x4,0x38,0x4c, 0x4,0x3e,0x29, + 0x3,0x42,0x27, 0x4,0x3e,0x28, 0x4,0x3e,0x27, 0x4,0x44,0x3f, + 0x4,0x44,0x38, 0x4,0x44,0x39, 0x4,0x44,0x3a, 0x5,0x46,0x68, + 0x4,0x44,0x3c, 0x4,0x50,0x6f, 0x4,0x50,0x71, 0x4,0x50,0x72, + 0x3,0x51,0x49, 0x4,0x5b,0x50, 0x4,0x5b,0x4f, 0x3,0x5a,0x50, + 0x4,0x6d,0x57, 0x4,0x2d,0x6a, 0x3,0x29,0x5c, 0x3,0x36,0x68, + 0x3,0x4c,0x69, 0x3,0x51,0x4a, 0x4,0x21,0x4f, 0x3,0x22,0x56, + 0x3,0x22,0x55, 0x3,0x24,0x22, 0x5,0x21,0x74, 0x4,0x23,0x22, + 0x3,0x26,0x54, 0x3,0x26,0x4f, 0x4,0x24,0x4f, 0x3,0x26,0x5d, + 0x6,0x28,0x49, 0x3,0x26,0x5a, 0x4,0x24,0x51, 0x3,0x26,0x4b, + 0x6,0x28,0x4a, 0x6,0x28,0x44, 0x3,0x26,0x58, 0x3,0x29,0x61, + 0x3,0x29,0x5f, 0x3,0x29,0x5e, 0x3,0x29,0x62, 0x3,0x29,0x60, + 0x4,0x26,0x7e, 0x3,0x29,0x68, 0x3,0x29,0x66, 0xf,0x27,0x66, + 0x3,0x2d,0x44, 0x5,0x2a,0x24, 0x4,0x27,0x22, 0x3,0x2d,0x54, + 0x5,0x29,0x7b, 0x5,0x29,0x7c, 0x4,0x29,0x7e, 0x3,0x2d,0x56, + 0x3,0x2d,0x4c, 0xf,0x30,0x49, 0x6,0x38,0x72, 0x3,0x31,0x70, + 0x3,0x31,0x71, 0x4,0x2d,0x6b, 0x6,0x39,0x33, 0x3,0x31,0x74, + 0x4,0x2d,0x6c, 0x3,0x36,0x69, 0x3,0x32,0x24, 0x3,0x32,0x23, + 0x3,0x31,0x7e, 0x3,0x31,0x75, 0x4,0x32,0x57, 0x3,0x36,0x71, + 0x4,0x32,0x63, 0x4,0x32,0x64, 0x3,0x36,0x6e, 0x4,0x32,0x5e, + 0x3,0x37,0x22, 0x3,0x36,0x6d, 0x3,0x3c,0x4f, 0x3,0x36,0x7e, + 0x4,0x32,0x58, 0x4,0x32,0x68, 0x5,0x39,0x5e, 0x4,0x32,0x5a, + 0x4,0x32,0x5c, 0x6,0x41,0x2b, 0x5,0x33,0x3d, 0x3,0x3c,0x5e, + 0x3,0x36,0x7b, 0x3,0x3c,0x5f, 0x3,0x36,0x73, 0x6,0x41,0x41, + 0x3,0x36,0x78, 0xf,0x36,0x33, 0x4,0x38,0x51, 0x4,0x38,0x56, + 0x3,0x3c,0x65, 0x4,0x38,0x52, 0x3,0x3c,0x59, 0x4,0x38,0x59, + 0x3,0x3c,0x6a, 0x3,0x3c,0x67, 0x3,0x3c,0x55, 0x4,0x38,0x57, + 0x4,0x38,0x5a, 0x3,0x3c,0x53, 0x3,0x3c,0x57, 0x3,0x3c,0x61, + 0x3,0x42,0x2b, 0x6,0x4a,0x6d, 0xf,0x3c,0x43, 0xf,0x3c,0x5a, + 0x4,0x3e,0x37, 0x3,0x42,0x2c, 0x3,0x42,0x37, 0x3,0x42,0x35, + 0x3,0x42,0x48, 0x3,0x42,0x38, 0x4,0x3e,0x30, 0x4,0x3e,0x39, + 0x4,0x3e,0x2d, 0x3,0x42,0x42, 0x4,0x3e,0x38, 0x3,0x42,0x34, + 0x3,0x42,0x3c, 0x4,0x3e,0x3c, 0x3,0x42,0x2f, 0x3,0x42,0x41, + 0x5,0x40,0x27, 0x4,0x3e,0x2f, 0x4,0x3e,0x32, 0x3,0x42,0x32, + 0x3,0x42,0x43, 0x3,0x47,0x55, 0x4,0x44,0x49, 0x3,0x47,0x60, + 0x6,0x5e,0x3b, 0x3,0x47,0x59, 0x6,0x54,0x50, 0x3,0x47,0x58, + 0x4,0x44,0x46, 0x4,0x44,0x4d, 0x4,0x44,0x4a, 0x6,0x5e,0x40, + 0x3,0x4c,0x6e, 0x4,0x4a,0x5f, 0x4,0x4a,0x61, 0x3,0x4c,0x6f, + 0x3,0x4c,0x7c, 0x4,0x4a,0x68, 0x4,0x4a,0x5d, 0x3,0x4c,0x6d, + 0x4,0x4a,0x59, 0x3,0x4c,0x72, 0x5,0x46,0x78, 0x7,0x24,0x61, + 0x3,0x4c,0x70, 0x4,0x50,0x74, 0x3,0x51,0x4b, 0x3,0x4c,0x76, + 0x4,0x50,0x77, 0x4,0x50,0x7d, 0x5,0x55,0x36, 0x4,0x50,0x76, + 0x3,0x51,0x4f, 0x3,0x51,0x4e, 0x4,0x50,0x7a, 0x5,0x55,0x2d, + 0x3,0x51,0x53, 0x3,0x51,0x57, 0x4,0x50,0x7b, 0x4,0x56,0x56, + 0x3,0x51,0x51, 0x3,0x51,0x4c, 0x4,0x50,0x78, 0x3,0x51,0x52, + 0x4,0x4a,0x62, 0x5,0x55,0x2e, 0x3,0x55,0x32, 0x3,0x55,0x38, + 0x4,0x56,0x5e, 0x4,0x56,0x60, 0x3,0x55,0x34, 0x4,0x56,0x58, + 0x3,0x55,0x2e, 0x4,0x56,0x57, 0x4,0x56,0x5c, 0x3,0x55,0x3b, + 0x4,0x56,0x59, 0x4,0x56,0x5b, 0x3,0x55,0x33, 0x4,0x5b,0x56, + 0x4,0x5b,0x54, 0x4,0x5b,0x5a, 0x4,0x5b,0x57, 0x4,0x5b,0x60, + 0x4,0x5f,0x7b, 0x4,0x5f,0x7d, 0x4,0x5b,0x5b, 0x4,0x5f,0x79, + 0x3,0x5a,0x51, 0x3,0x5c,0x50, 0x4,0x63,0x5a, 0x4,0x63,0x5e, + 0x4,0x63,0x5b, 0x3,0x5c,0x52, 0x4,0x66,0x49, 0x5,0x70,0x3e, + 0x4,0x66,0x4a, 0x4,0x66,0x4c, 0x4,0x68,0x73, 0x3,0x5e,0x39, + 0x3,0x5e,0x38, 0x3,0x5f,0x51, 0x4,0x6a,0x4e, 0x3,0x60,0x38, + 0x4,0x6b,0x6d, 0x4,0x6b,0x6e, 0x3,0x61,0x66, 0x3,0x24,0x2a, + 0x4,0x24,0x52, 0x3,0x26,0x61, 0xf,0x24,0x6e, 0x3,0x29,0x6e, + 0x4,0x27,0x27, 0x3,0x29,0x78, 0xf,0x27,0x6e, 0x3,0x29,0x73, + 0x3,0x2d,0x67, 0x3,0x2d,0x59, 0x3,0x2d,0x66, 0x3,0x2d,0x61, + 0x3,0x2d,0x60, 0x3,0x2d,0x5b, 0x4,0x2a,0x27, 0x3,0x32,0x2e, + 0x4,0x2d,0x73, 0x3,0x32,0x32, 0x3,0x37,0x2b, 0x3,0x37,0x2a, + 0x3,0x37,0x34, 0x4,0x32,0x71, 0x4,0x32,0x76, 0x4,0x32,0x70, + 0x4,0x32,0x77, 0xf,0x36,0x48, 0x3,0x3c,0x76, 0x4,0x38,0x65, + 0x4,0x38,0x61, 0x3,0x3c,0x75, 0x4,0x38,0x62, 0x4,0x38,0x64, + 0x4,0x38,0x60, 0x3,0x3b,0x23, 0x3,0x3c,0x7e, 0x3,0x3c,0x70, + 0x3,0x3c,0x78, 0x3,0x42,0x54, 0x3,0x42,0x4d, 0x3,0x42,0x56, + 0x4,0x3e,0x4b, 0x3,0x42,0x4a, 0x3,0x42,0x55, 0x4,0x3e,0x48, + 0x4,0x3e,0x46, 0x4,0x3e,0x49, 0x6,0x54,0x54, 0x3,0x42,0x4b, + 0x3,0x42,0x50, 0xf,0x42,0x78, 0xf,0x43,0x3c, 0x4,0x44,0x59, + 0x3,0x47,0x73, 0x3,0x47,0x69, 0x6,0x54,0x67, 0x4,0x44,0x56, + 0x4,0x44,0x5a, 0x4,0x44,0x5c, 0x3,0x47,0x71, 0xf,0x49,0x58, + 0x3,0x4d,0x26, 0x3,0x4d,0x23, 0x3,0x4d,0x2b, 0x3,0x4d,0x21, + 0x3,0x4d,0x27, 0x4,0x4a,0x6a, 0x4,0x51,0x25, 0x3,0x51,0x5d, + 0x3,0x51,0x5b, 0x4,0x51,0x2b, 0x3,0x51,0x5f, 0x3,0x51,0x61, + 0x4,0x51,0x24, 0x3,0x51,0x64, 0x3,0x51,0x65, 0x3,0x55,0x3d, + 0x4,0x56,0x62, 0x3,0x55,0x3f, 0x3,0x55,0x44, 0x7,0x39,0x26, + 0x3,0x57,0x51, 0x3,0x58,0x2c, 0x4,0x56,0x64, 0x3,0x5c,0x5a, + 0x3,0x5a,0x59, 0x3,0x5c,0x54, 0x3,0x5c,0x5b, 0x4,0x63,0x5f, + 0x4,0x66,0x4e, 0x5,0x73,0x57, 0x4,0x6a,0x50, 0x3,0x60,0x3a, + 0x3,0x61,0x7a, 0x4,0x27,0x2c, 0x3,0x29,0x7a, 0x3,0x37,0x58, + 0x3,0x47,0x74, 0x3,0x2d,0x6a, 0x4,0x2d,0x76, 0x3,0x37,0x36, + 0x4,0x38,0x6b, 0x3,0x29,0x7b, 0x4,0x2a,0x2c, 0x4,0x38,0x6c, + 0x3,0x29,0x7d, 0x3,0x29,0x7e, 0x5,0x2e,0x53, 0x6,0x39,0x40, + 0x4,0x2d,0x7a, 0x4,0x44,0x5f, 0x7,0x39,0x2d, 0x4,0x5b,0x64, + 0x4,0x66,0x50, 0x3,0x21,0x6a, 0x3,0x32,0x33, 0x4,0x23,0x26, + 0x3,0x26,0x65, 0x4,0x24,0x55, 0x6,0x2c,0x71, 0x4,0x27,0x33, + 0x5,0x26,0x77, 0x4,0x27,0x32, 0x4,0x27,0x2f, 0x3,0x2d,0x6c, + 0x3,0x2d,0x6f, 0x4,0x2a,0x2e, 0x3,0x2d,0x6e, 0x3,0x32,0x34, + 0x3,0x32,0x35, 0x4,0x2d,0x7d, 0x4,0x2d,0x7c, 0x4,0x32,0x7a, + 0x5,0x33,0x4d, 0x4,0x32,0x79, 0x4,0x32,0x7e, 0x3,0x37,0x38, + 0x6,0x41,0x66, 0x3,0x37,0x37, 0x4,0x38,0x70, 0x4,0x38,0x72, + 0x4,0x38,0x73, 0x4,0x44,0x63, 0x6,0x54,0x78, 0x4,0x3e,0x4e, + 0x3,0x42,0x5e, 0x4,0x44,0x62, 0x4,0x44,0x60, 0x4,0x44,0x64, + 0x4,0x4a,0x6f, 0x4,0x4a,0x6e, 0x4,0x4a,0x72, 0x4,0x4a,0x71, + 0x4,0x4a,0x73, 0x4,0x51,0x2e, 0x4,0x51,0x30, 0x4,0x51,0x2f, + 0x4,0x56,0x67, 0x3,0x55,0x46, 0x3,0x55,0x47, 0x4,0x5b,0x66, + 0x4,0x5b,0x65, 0x4,0x60,0x24, 0x7,0x53,0x6b, 0x4,0x6a,0x51, + 0x4,0x27,0x34, 0x4,0x24,0x59, 0x3,0x26,0x6d, 0x4,0x24,0x56, + 0x3,0x26,0x6c, 0x6,0x2c,0x75, 0x4,0x27,0x39, 0x5,0x27,0x2e, + 0x3,0x2a,0x29, 0x3,0x2a,0x24, 0x3,0x2a,0x25, 0x4,0x27,0x3a, + 0x4,0x2a,0x32, 0x4,0x2a,0x34, 0x4,0x2a,0x35, 0x3,0x2d,0x72, + 0x6,0x32,0x67, 0x3,0x32,0x37, 0x5,0x2e,0x5c, 0x4,0x2e,0x21, + 0x4,0x2d,0x7e, 0x4,0x2e,0x22, 0x4,0x2e,0x26, 0x6,0x41,0x6d, + 0x4,0x2e,0x27, 0x5,0x33,0x51, 0x4,0x33,0x28, 0x6,0x41,0x75, + 0x4,0x33,0x29, 0x4,0x33,0x25, 0x4,0x33,0x2b, 0x4,0x33,0x27, + 0x4,0x33,0x2e, 0x4,0x38,0x79, 0x4,0x38,0x77, 0x3,0x3d,0x2c, + 0x4,0x38,0x7b, 0x6,0x4b,0x43, 0x4,0x44,0x65, 0x4,0x3e,0x54, + 0x4,0x44,0x66, 0x4,0x3e,0x53, 0x3,0x42,0x60, 0x4,0x3e,0x52, + 0x4,0x44,0x6a, 0x6,0x5e,0x6e, 0x4,0x44,0x69, 0x4,0x44,0x68, + 0x4,0x44,0x67, 0x3,0x47,0x76, 0x4,0x38,0x7a, 0x4,0x4a,0x7b, + 0x4,0x4a,0x76, 0x4,0x4a,0x7a, 0x4,0x4a,0x7c, 0x7,0x2f,0x74, + 0x4,0x51,0x32, 0x4,0x51,0x34, 0x3,0x55,0x48, 0x4,0x56,0x6a, + 0x4,0x56,0x6b, 0x4,0x5b,0x67, 0x5,0x68,0x3b, 0x4,0x63,0x65, + 0x4,0x63,0x66, 0x4,0x63,0x67, 0x4,0x63,0x63, 0x4,0x6b,0x6f, + 0x3,0x24,0x2e, 0x4,0x23,0x29, 0x3,0x24,0x30, 0x3,0x24,0x31, + 0x3,0x26,0x71, 0x3,0x26,0x6f, 0x3,0x26,0x70, 0x3,0x2a,0x2e, + 0x3,0x2d,0x76, 0x6,0x2d,0x21, 0x3,0x2a,0x30, 0x4,0x27,0x3b, + 0x3,0x2a,0x31, 0x3,0x2d,0x7d, 0x3,0x32,0x3a, 0x4,0x2a,0x37, + 0x4,0x2a,0x38, 0xf,0x2c,0x32, 0x4,0x33,0x2f, 0x3,0x32,0x43, + 0x3,0x32,0x44, 0x3,0x32,0x3b, 0x4,0x33,0x30, 0x3,0x32,0x45, + 0xf,0x31,0x27, 0x3,0x32,0x42, 0x3,0x37,0x3f, 0x3,0x37,0x42, + 0x3,0x37,0x41, 0x4,0x33,0x33, 0x3,0x37,0x3e, 0x3,0x37,0x43, + 0x3,0x3d,0x34, 0x4,0x38,0x7d, 0x5,0x3a,0x2d, 0x3,0x42,0x63, + 0x3,0x3d,0x31, 0x3,0x3d,0x30, 0x3,0x42,0x6c, 0xf,0x36,0x59, + 0xf,0x3d,0x3b, 0x4,0x3e,0x59, 0x3,0x42,0x65, 0x3,0x42,0x69, + 0x5,0x40,0x4e, 0x3,0x42,0x72, 0xf,0x43,0x49, 0xf,0x43,0x56, + 0x3,0x48,0x24, 0x7,0x25,0x37, 0x4,0x4b,0x22, 0x4,0x4b,0x21, + 0x3,0x4d,0x37, 0x3,0x4d,0x3c, 0x3,0x4d,0x33, 0x3,0x4d,0x38, + 0x3,0x4d,0x34, 0x3,0x4d,0x32, 0x3,0x51,0x68, 0x5,0x55,0x5d, + 0x4,0x51,0x37, 0x3,0x51,0x69, 0x3,0x55,0x4a, 0x4,0x56,0x6f, + 0xf,0x55,0x7a, 0xf,0x56,0x22, 0x3,0x55,0x4e, 0x4,0x5b,0x69, + 0x3,0x55,0x4c, 0xf,0x5b,0x2d, 0x3,0x58,0x31, 0x4,0x60,0x2a, + 0xf,0x62,0x78, 0xf,0x62,0x7b, 0x3,0x5c,0x61, 0x4,0x2a,0x39, + 0x4,0x2a,0x3a, 0x5,0x2e,0x62, 0x4,0x2e,0x2b, 0x4,0x33,0x35, + 0x4,0x33,0x34, 0x4,0x38,0x7e, 0x4,0x44,0x70, 0x4,0x44,0x71, + 0x4,0x44,0x6f, 0x4,0x4b,0x23, 0x4,0x4b,0x24, 0x4,0x5b,0x6c, + 0x4,0x6d,0x5a, 0x4,0x24,0x5e, 0x5,0x27,0x32, 0x3,0x2a,0x34, + 0x3,0x2e,0x23, 0x4,0x2a,0x3d, 0x3,0x32,0x4a, 0x3,0x32,0x4b, + 0x4,0x2e,0x2d, 0x3,0x32,0x49, 0x4,0x2e,0x2c, 0x4,0x33,0x3b, + 0x4,0x39,0x21, 0x4,0x33,0x3a, 0x4,0x33,0x38, 0x4,0x33,0x39, + 0x4,0x33,0x37, 0x4,0x39,0x23, 0x4,0x39,0x26, 0x4,0x33,0x3c, + 0x4,0x39,0x24, 0x4,0x3e,0x62, 0x4,0x3e,0x61, 0x4,0x3e,0x5d, + 0x4,0x3e,0x60, 0x3,0x42,0x76, 0x4,0x3e,0x63, 0x5,0x47,0x48, + 0x4,0x44,0x73, 0x4,0x44,0x76, 0x4,0x44,0x74, 0x4,0x44,0x78, + 0x4,0x44,0x77, 0x4,0x44,0x75, 0x4,0x4b,0x25, 0x4,0x4b,0x27, + 0x4,0x4b,0x26, 0x4,0x51,0x3f, 0x3,0x51,0x6f, 0x4,0x51,0x42, + 0x4,0x51,0x41, 0x4,0x56,0x72, 0x4,0x56,0x73, 0x3,0x55,0x51, + 0x4,0x56,0x75, 0x3,0x55,0x50, 0x4,0x56,0x71, 0x4,0x5b,0x6f, + 0x4,0x5b,0x6e, 0x4,0x60,0x2c, 0x4,0x60,0x2b, 0x4,0x68,0x75, + 0x4,0x6b,0x70, 0x4,0x6a,0x53, 0x3,0x32,0x4c, 0x4,0x3e,0x65, + 0x3,0x4d,0x3f, 0x4,0x56,0x78, 0x3,0x3d,0x40, 0xf,0x50,0x4e, + 0x5,0x24,0x63, 0x6,0x28,0x62, 0x3,0x26,0x72, 0x4,0x2a,0x41, + 0x3,0x2e,0x29, 0x4,0x2a,0x43, 0x4,0x2e,0x2f, 0x4,0x2e,0x31, + 0x5,0x33,0x64, 0x3,0x37,0x48, 0x3,0x3d,0x41, 0x4,0x39,0x28, + 0x4,0x3e,0x69, 0x3,0x42,0x79, 0x3,0x42,0x7a, 0x4,0x3e,0x68, + 0x4,0x44,0x79, 0x3,0x4d,0x40, 0x4,0x4b,0x2a, 0x4,0x4b,0x29, + 0x4,0x51,0x44, 0x5,0x5c,0x2f, 0x4,0x5b,0x72, 0x4,0x5b,0x73, + 0x4,0x60,0x2e, 0x4,0x63,0x69, 0x4,0x6a,0x54, 0x4,0x3e,0x6d, + 0x4,0x24,0x61, 0x4,0x24,0x62, 0x5,0x27,0x37, 0x3,0x2a,0x3c, + 0x4,0x2a,0x46, 0x3,0x2e,0x2d, 0x4,0x2a,0x49, 0x3,0x2e,0x2c, + 0x3,0x2e,0x2e, 0x3,0x32,0x56, 0x4,0x2e,0x37, 0x4,0x2e,0x3b, + 0x4,0x2e,0x35, 0x4,0x2e,0x36, 0x3,0x32,0x54, 0x4,0x2e,0x33, + 0x4,0x2e,0x3f, 0x4,0x2e,0x39, 0x6,0x39,0x6b, 0x3,0x32,0x53, + 0x4,0x2e,0x38, 0x4,0x2e,0x3a, 0x5,0x33,0x6d, 0x4,0x33,0x42, + 0x3,0x37,0x4c, 0x4,0x33,0x40, 0x4,0x2e,0x3c, 0x4,0x33,0x3f, + 0x4,0x33,0x45, 0x3,0x37,0x4b, 0x4,0x33,0x43, 0x4,0x39,0x32, + 0x4,0x39,0x33, 0x3,0x3d,0x46, 0x3,0x3d,0x4b, 0x6,0x4b,0x5a, + 0x3,0x3d,0x49, 0x4,0x39,0x36, 0x5,0x40,0x60, 0x4,0x39,0x2f, + 0x4,0x39,0x30, 0x3,0x3d,0x48, 0x3,0x3d,0x4a, 0x5,0x3a,0x3b, + 0x4,0x39,0x35, 0x4,0x39,0x38, 0x4,0x3e,0x74, 0x5,0x40,0x64, + 0x4,0x3e,0x6f, 0x4,0x3e,0x78, 0x4,0x3e,0x6e, 0x4,0x3e,0x76, + 0x4,0x3e,0x73, 0x4,0x3e,0x7a, 0x4,0x45,0x24, 0x4,0x45,0x28, + 0x6,0x5f,0x2d, 0x3,0x48,0x2a, 0x3,0x48,0x2c, 0x4,0x45,0x23, + 0x4,0x45,0x21, 0x7,0x25,0x58, 0x4,0x4b,0x38, 0x3,0x4d,0x42, + 0x4,0x4b,0x37, 0x4,0x4b,0x35, 0x4,0x4b,0x33, 0x4,0x4b,0x2f, + 0x7,0x25,0x5c, 0x4,0x4b,0x2e, 0x5,0x47,0x59, 0x4,0x4b,0x3b, + 0x7,0x30,0x36, 0x4,0x51,0x48, 0x4,0x51,0x49, 0x3,0x51,0x75, + 0x4,0x51,0x4e, 0x4,0x51,0x4a, 0x4,0x51,0x50, 0x4,0x57,0x26, + 0x4,0x57,0x22, 0x4,0x5b,0x7b, 0x4,0x5b,0x77, 0x7,0x40,0x6b, + 0x4,0x57,0x25, 0x7,0x40,0x67, 0x4,0x60,0x32, 0x4,0x60,0x2f, + 0x4,0x60,0x30, 0x4,0x66,0x58, 0x4,0x66,0x59, 0x3,0x5e,0x40, + 0x5,0x73,0x5c, 0x4,0x6a,0x55, 0x4,0x6b,0x72, 0x4,0x6b,0x71, + 0x3,0x62,0x2d, 0x3,0x26,0x75, 0x3,0x2e,0x30, 0x3,0x32,0x58, + 0x3,0x37,0x4e, 0x3,0x43,0x22, 0x3,0x48,0x2d, 0x5,0x47,0x5b, + 0x5,0x4e,0x59, 0x4,0x51,0x56, 0x4,0x60,0x37, 0x4,0x66,0x5b, + 0x4,0x6c,0x73, 0x4,0x27,0x46, 0x4,0x2a,0x4e, 0x3,0x2e,0x31, + 0x4,0x2e,0x46, 0x4,0x2e,0x45, 0x4,0x33,0x47, 0x4,0x33,0x48, + 0x4,0x39,0x3a, 0x6,0x55,0x52, 0x4,0x45,0x30, 0x4,0x45,0x32, + 0x3,0x48,0x2f, 0x3,0x4d,0x43, 0x4,0x4b,0x3d, 0x4,0x51,0x57, + 0x4,0x5b,0x7e, 0x4,0x63,0x6c, 0x4,0x27,0x48, 0x4,0x2a,0x51, + 0x4,0x2a,0x50, 0x4,0x2e,0x47, 0x4,0x2e,0x49, 0x3,0x32,0x59, + 0x4,0x33,0x4b, 0x3,0x37,0x4f, 0x3,0x3d,0x4e, 0x3,0x43,0x23, + 0x5,0x40,0x6f, 0x3,0x48,0x32, 0x4,0x51,0x5a, 0x4,0x45,0x36, + 0x4,0x57,0x2c, 0x4,0x60,0x38, 0x3,0x5f,0x38, 0x4,0x6e,0x48, + 0x3,0x26,0x79, 0x4,0x24,0x65, 0x4,0x27,0x4e, 0x4,0x27,0x4f, + 0x4,0x27,0x4d, 0x4,0x27,0x4c, 0x4,0x27,0x4a, 0x4,0x2a,0x53, + 0x4,0x2a,0x56, 0x4,0x2a,0x57, 0x4,0x2a,0x54, 0x4,0x2a,0x58, + 0x5,0x2a,0x6d, 0x4,0x2a,0x5a, 0x6,0x33,0x38, 0x3,0x2e,0x34, + 0x4,0x2e,0x52, 0x3,0x32,0x5d, 0x3,0x32,0x66, 0x3,0x32,0x60, + 0x4,0x2e,0x4d, 0x3,0x32,0x61, 0x5,0x33,0x76, 0x4,0x33,0x50, + 0x4,0x33,0x51, 0x3,0x37,0x56, 0x3,0x37,0x54, 0x4,0x33,0x52, + 0x4,0x33,0x4e, 0x4,0x33,0x4d, 0x3,0x3d,0x50, 0x4,0x39,0x49, + 0x3,0x3d,0x54, 0x4,0x39,0x4a, 0x3,0x3d,0x55, 0x4,0x39,0x45, + 0x4,0x39,0x48, 0x4,0x39,0x3f, 0x4,0x39,0x41, 0x4,0x39,0x4b, + 0x4,0x39,0x46, 0x4,0x39,0x4d, 0x4,0x39,0x47, 0x4,0x39,0x43, + 0x4,0x3f,0x22, 0x4,0x39,0x4c, 0x4,0x39,0x42, 0x4,0x3f,0x30, + 0x4,0x3f,0x2d, 0x3,0x43,0x24, 0x4,0x3f,0x25, 0x4,0x3f,0x26, + 0x4,0x3f,0x27, 0x4,0x3f,0x2b, 0x4,0x3f,0x2c, 0x6,0x55,0x61, + 0x5,0x47,0x61, 0x4,0x45,0x39, 0x4,0x45,0x41, 0x4,0x45,0x3c, + 0x4,0x45,0x37, 0x3,0x48,0x37, 0x4,0x45,0x43, 0x4,0x45,0x46, + 0x4,0x45,0x3f, 0x4,0x45,0x44, 0x3,0x48,0x3a, 0x4,0x45,0x38, + 0x3,0x4d,0x45, 0x4,0x4b,0x45, 0x4,0x4b,0x42, 0x4,0x4b,0x44, + 0x4,0x4b,0x47, 0x4,0x4b,0x43, 0x4,0x4b,0x4d, 0x3,0x4d,0x47, + 0x5,0x4e,0x60, 0x4,0x4b,0x3f, 0x3,0x51,0x77, 0x3,0x51,0x78, + 0x4,0x51,0x5c, 0x4,0x51,0x60, 0x3,0x51,0x7c, 0x3,0x51,0x7a, + 0x4,0x51,0x5d, 0x4,0x51,0x64, 0x4,0x57,0x32, 0x4,0x57,0x2e, + 0x4,0x57,0x31, 0x4,0x57,0x2f, 0x3,0x55,0x5a, 0x4,0x57,0x30, + 0x4,0x57,0x33, 0x4,0x57,0x34, 0x5,0x56,0x22, 0x5,0x62,0x69, + 0x4,0x5c,0x27, 0x4,0x5c,0x29, 0x4,0x5c,0x2a, 0x4,0x5c,0x25, + 0x3,0x58,0x37, 0x4,0x5c,0x26, 0x4,0x63,0x70, 0x4,0x63,0x6e, + 0x4,0x63,0x71, 0x4,0x63,0x6f, 0x4,0x66,0x5d, 0x3,0x5e,0x41, + 0x4,0x68,0x78, 0x4,0x6a,0x57, 0x4,0x68,0x7a, 0x4,0x6c,0x75, + 0x4,0x6e,0x4d, 0x4,0x27,0x51, 0x4,0x2a,0x5f, 0x4,0x33,0x57, + 0x4,0x45,0x4a, 0x3,0x55,0x5d, 0x4,0x57,0x38, 0x4,0x63,0x74, + 0x4,0x6b,0x75, 0x4,0x2e,0x57, 0x4,0x2e,0x58, 0x4,0x33,0x5a, + 0x4,0x33,0x59, 0x6,0x4c,0x2b, 0x4,0x3f,0x33, 0x4,0x45,0x4c, + 0x3,0x24,0x32, 0x3,0x26,0x7a, 0x4,0x27,0x53, 0xf,0x28,0x7a, + 0x4,0x2a,0x64, 0x3,0x2e,0x38, 0x4,0x2a,0x62, 0x3,0x2e,0x3c, + 0x3,0x2d,0x3b, 0x4,0x2e,0x5f, 0x4,0x2e,0x5c, 0x4,0x2e,0x62, + 0x5,0x2f,0x34, 0x3,0x37,0x5b, 0x3,0x32,0x6a, 0x3,0x32,0x6b, + 0x4,0x2e,0x5e, 0x4,0x2e,0x61, 0x4,0x33,0x5e, 0x4,0x33,0x61, + 0x3,0x37,0x5c, 0x4,0x33,0x5f, 0x3,0x37,0x5a, 0x4,0x33,0x60, + 0x3,0x37,0x5e, 0x3,0x3d,0x5b, 0x5,0x3a,0x59, 0x6,0x4c,0x33, + 0x4,0x39,0x58, 0x3,0x3d,0x58, 0x4,0x39,0x53, 0x4,0x3f,0x40, + 0x4,0x3f,0x39, 0x4,0x3f,0x3f, 0x3,0x43,0x2f, 0x4,0x3f,0x3c, + 0x3,0x43,0x32, 0x4,0x3f,0x3d, 0x3,0x43,0x2c, 0x4,0x3f,0x3e, + 0x4,0x3f,0x38, 0x4,0x3f,0x3a, 0x4,0x3f,0x3b, 0x4,0x3f,0x42, + 0x4,0x45,0x4e, 0x3,0x48,0x43, 0x4,0x45,0x51, 0x3,0x48,0x41, + 0x4,0x45,0x4d, 0x4,0x45,0x55, 0x4,0x45,0x4f, 0x5,0x47,0x76, + 0x4,0x4b,0x5c, 0x4,0x4b,0x58, 0x4,0x4b,0x56, 0x4,0x4b,0x55, + 0x4,0x4b,0x5e, 0x7,0x26,0x24, 0x4,0x4b,0x5b, 0x3,0x52,0x23, + 0x3,0x51,0x7d, 0x4,0x51,0x6c, 0x3,0x51,0x7e, 0x7,0x30,0x59, + 0x5,0x56,0x33, 0x4,0x51,0x70, 0x4,0x51,0x6d, 0x4,0x57,0x3b, + 0x4,0x57,0x41, 0x3,0x48,0x42, 0x4,0x57,0x39, 0x3,0x55,0x5e, + 0x3,0x55,0x5f, 0x4,0x57,0x3f, 0x3,0x58,0x41, 0x4,0x5c,0x2d, + 0x3,0x58,0x3d, 0x4,0x5c,0x31, 0x4,0x5c,0x2f, 0x4,0x5c,0x2e, + 0x4,0x60,0x3f, 0x7,0x4e,0x5c, 0x3,0x5c,0x63, 0x4,0x63,0x76, + 0x4,0x63,0x75, 0x4,0x66,0x5f, 0x4,0x66,0x60, 0x4,0x66,0x61, + 0x4,0x68,0x7c, 0x4,0x68,0x7b, 0x3,0x60,0x75, 0x3,0x61,0x67, + 0x3,0x2e,0x3f, 0x4,0x2a,0x67, 0x4,0x2a,0x66, 0x6,0x33,0x48, + 0x3,0x32,0x6e, 0x4,0x2e,0x64, 0x3,0x32,0x71, 0x3,0x37,0x64, + 0x4,0x33,0x63, 0x4,0x33,0x62, 0x3,0x3d,0x61, 0x3,0x3d,0x60, + 0x4,0x39,0x59, 0x4,0x3f,0x45, 0x4,0x3f,0x44, 0x3,0x43,0x3a, + 0x3,0x43,0x3b, 0x3,0x43,0x3e, 0x4,0x3f,0x47, 0x3,0x43,0x3c, + 0x3,0x43,0x3f, 0x3,0x48,0x46, 0x5,0x48,0x24, 0x3,0x48,0x49, + 0x5,0x4e,0x76, 0x3,0x4d,0x4e, 0x4,0x51,0x76, 0x3,0x52,0x25, + 0x4,0x51,0x74, 0x4,0x51,0x75, 0x4,0x57,0x42, 0x3,0x58,0x46, + 0x3,0x58,0x47, 0x3,0x5a,0x64, 0x4,0x66,0x63, 0x3,0x62,0x34, + 0x5,0x24,0x6e, 0x3,0x26,0x7d, 0x5,0x27,0x46, 0x6,0x2d,0x49, + 0x4,0x27,0x56, 0x3,0x2a,0x40, 0x3,0x2a,0x41, 0x3,0x2a,0x43, + 0x4,0x2a,0x6a, 0x4,0x2a,0x6f, 0x4,0x2a,0x6b, 0x4,0x2a,0x69, + 0x4,0x2a,0x6c, 0xf,0x2c,0x6d, 0x4,0x2e,0x65, 0x3,0x32,0x75, + 0x3,0x32,0x7a, 0x6,0x42,0x66, 0x4,0x33,0x67, 0x4,0x33,0x66, + 0x3,0x37,0x6d, 0x4,0x33,0x65, 0x5,0x34,0x3b, 0x5,0x34,0x39, + 0x4,0x33,0x6a, 0x4,0x33,0x69, 0x4,0x33,0x6b, 0x3,0x37,0x68, + 0x4,0x33,0x6d, 0x5,0x34,0x38, 0x3,0x37,0x6e, 0xf,0x37,0x3b, + 0x4,0x33,0x64, 0x5,0x3a,0x65, 0x4,0x39,0x5e, 0x4,0x39,0x62, + 0x3,0x3d,0x67, 0x4,0x39,0x64, 0x3,0x3d,0x6a, 0x4,0x39,0x63, + 0x3,0x3d,0x6b, 0x4,0x39,0x61, 0x4,0x3f,0x4f, 0x3,0x43,0x40, + 0x4,0x3f,0x4d, 0x3,0x43,0x45, 0x4,0x3f,0x4c, 0x3,0x43,0x42, + 0x4,0x3f,0x4b, 0x3,0x43,0x43, 0x4,0x45,0x57, 0x4,0x3f,0x49, + 0x5,0x41,0x31, 0x3,0x48,0x51, 0x3,0x48,0x4a, 0x4,0x45,0x5b, + 0x3,0x48,0x53, 0x3,0x48,0x4e, 0x4,0x45,0x5a, 0x3,0x48,0x4c, + 0x4,0x45,0x58, 0x6,0x5f,0x6b, 0x4,0x45,0x59, 0x4,0x4b,0x65, + 0x4,0x4b,0x61, 0x3,0x4d,0x54, 0x4,0x4b,0x62, 0x3,0x4d,0x52, + 0x7,0x26,0x32, 0x3,0x4d,0x58, 0x4,0x4b,0x68, 0x4,0x4b,0x66, + 0x4,0x4b,0x64, 0x3,0x4d,0x59, 0x4,0x51,0x7d, 0x4,0x51,0x7c, + 0x3,0x52,0x2b, 0x4,0x51,0x79, 0x4,0x51,0x78, 0x4,0x51,0x7a, + 0x3,0x52,0x2d, 0x4,0x57,0x45, 0x3,0x55,0x63, 0x4,0x57,0x47, + 0x3,0x58,0x48, 0x7,0x41,0x2e, 0x4,0x5c,0x37, 0x4,0x5c,0x35, + 0x4,0x5c,0x36, 0x3,0x5e,0x46, 0x4,0x63,0x79, 0x4,0x66,0x65, + 0x7,0x58,0x4c, 0x4,0x66,0x64, 0x4,0x68,0x7e, 0x4,0x69,0x21, + 0x3,0x62,0x39, 0x4,0x24,0x69, 0x6,0x2d,0x4e, 0x3,0x2e,0x46, + 0x3,0x2e,0x45, 0x4,0x2a,0x71, 0x4,0x2a,0x72, 0x3,0x33,0x21, + 0x3,0x32,0x7e, 0x3,0x32,0x7d, 0x4,0x33,0x6f, 0x4,0x33,0x70, + 0x3,0x37,0x6f, 0x5,0x34,0x45, 0x4,0x33,0x72, 0x4,0x33,0x71, + 0x6,0x42,0x6f, 0x3,0x3d,0x6c, 0x4,0x39,0x67, 0x3,0x3d,0x6d, + 0x6,0x4c,0x53, 0x3,0x3d,0x6e, 0x5,0x41,0x39, 0x4,0x3f,0x53, + 0x4,0x3f,0x52, 0x6,0x56,0x27, 0x4,0x45,0x60, 0x6,0x5f,0x78, + 0x4,0x4b,0x6c, 0x5,0x4f,0x23, 0x5,0x54,0x24, 0x4,0x52,0x25, + 0x4,0x52,0x22, 0x4,0x52,0x24, 0x7,0x30,0x6f, 0x3,0x55,0x65, + 0x3,0x55,0x66, 0x4,0x57,0x4c, 0x4,0x57,0x4d, 0x4,0x57,0x4b, + 0x4,0x57,0x4f, 0x3,0x55,0x67, 0x4,0x5c,0x39, 0x4,0x5c,0x3a, + 0x4,0x60,0x48, 0x4,0x60,0x49, 0x4,0x63,0x7c, 0x4,0x69,0x22, + 0x3,0x24,0x34, 0x3,0x2a,0x46, 0x4,0x2a,0x76, 0x3,0x2e,0x4a, + 0x3,0x33,0x25, 0x4,0x2e,0x6d, 0x3,0x33,0x22, 0x5,0x34,0x46, + 0x3,0x3d,0x6f, 0x4,0x39,0x6a, 0x3,0x43,0x48, 0x4,0x3f,0x54, + 0x4,0x3f,0x55, 0x4,0x3f,0x5a, 0x4,0x45,0x63, 0x4,0x57,0x52, + 0x4,0x5c,0x3b, 0x3,0x5a,0x68, 0x5,0x2b,0x21, 0x4,0x2e,0x75, + 0x4,0x2e,0x70, 0x3,0x33,0x28, 0x4,0x2e,0x77, 0x3,0x33,0x29, + 0x4,0x2e,0x73, 0x4,0x2e,0x72, 0x4,0x33,0x76, 0x4,0x33,0x7d, + 0x3,0x37,0x74, 0x5,0x34,0x48, 0x4,0x33,0x77, 0x4,0x33,0x7b, + 0x3,0x37,0x75, 0x6,0x42,0x76, 0x4,0x33,0x78, 0x4,0x39,0x6d, + 0x4,0x39,0x74, 0x4,0x39,0x71, 0x3,0x3d,0x74, 0x4,0x3f,0x5b, + 0x4,0x39,0x72, 0x3,0x3d,0x7a, 0x4,0x39,0x75, 0x3,0x3d,0x73, + 0x4,0x39,0x6f, 0x6,0x4c,0x5b, 0x6,0x4c,0x56, 0x3,0x43,0x50, + 0x4,0x3f,0x66, 0x4,0x3f,0x62, 0x4,0x3f,0x61, 0x3,0x43,0x52, + 0x3,0x43,0x53, 0x4,0x3f,0x5d, 0x3,0x43,0x4e, 0x4,0x3f,0x60, + 0x3,0x43,0x4b, 0x4,0x3f,0x63, 0x5,0x48,0x46, 0x4,0x39,0x76, + 0x4,0x45,0x65, 0x3,0x48,0x5b, 0x4,0x45,0x6a, 0x4,0x45,0x69, + 0x3,0x48,0x5f, 0x4,0x45,0x6e, 0x4,0x45,0x68, 0x3,0x48,0x59, + 0x4,0x45,0x6d, 0x4,0x45,0x66, 0x5,0x48,0x36, 0x4,0x4b,0x7b, + 0x4,0x4b,0x75, 0x4,0x4b,0x70, 0x3,0x4d,0x61, 0x3,0x4d,0x5e, + 0x4,0x4c,0x22, 0x3,0x4d,0x67, 0x4,0x4b,0x7e, 0x3,0x4d,0x62, + 0x4,0x4c,0x2e, 0x5,0x4f,0x3b, 0x3,0x4d,0x64, 0x4,0x4c,0x30, + 0x4,0x4c,0x25, 0x4,0x4c,0x2d, 0x4,0x4b,0x79, 0x5,0x4f,0x32, + 0x3,0x4d,0x5f, 0x5,0x4f,0x45, 0x4,0x4c,0x2c, 0x4,0x4c,0x27, + 0x4,0x4b,0x77, 0x3,0x4d,0x66, 0x3,0x4d,0x68, 0x4,0x4c,0x28, + 0x5,0x4f,0x36, 0x4,0x52,0x34, 0x4,0x52,0x3a, 0x3,0x52,0x31, + 0x4,0x52,0x37, 0x4,0x52,0x2b, 0x4,0x52,0x38, 0x3,0x52,0x35, + 0x4,0x52,0x39, 0x4,0x52,0x3b, 0x4,0x52,0x36, 0x4,0x52,0x2f, + 0x4,0x52,0x3d, 0x4,0x52,0x29, 0x3,0x52,0x32, 0x4,0x57,0x5b, + 0x5,0x5c,0x6d, 0x4,0x57,0x5e, 0x4,0x57,0x5a, 0x4,0x57,0x62, + 0x5,0x5c,0x7d, 0x4,0x57,0x65, 0x4,0x57,0x53, 0x3,0x55,0x6c, + 0x4,0x57,0x56, 0x4,0x57,0x58, 0x4,0x57,0x59, 0x5,0x5c,0x7e, + 0x4,0x57,0x55, 0x5,0x5d,0x30, 0x4,0x5c,0x44, 0x4,0x5c,0x4f, + 0x4,0x5c,0x4b, 0x4,0x5c,0x50, 0x4,0x5c,0x43, 0x3,0x58,0x4a, + 0x4,0x5c,0x4a, 0x3,0x5a,0x6c, 0x4,0x5c,0x42, 0x4,0x5c,0x4c, + 0x7,0x41,0x3f, 0x4,0x5c,0x46, 0x4,0x5c,0x49, 0x4,0x5c,0x40, + 0x5,0x63,0x34, 0x4,0x5c,0x48, 0x3,0x58,0x4d, 0x3,0x58,0x4b, + 0x5,0x63,0x41, 0x4,0x60,0x56, 0x5,0x68,0x6e, 0x3,0x5a,0x6a, + 0x4,0x60,0x53, 0x5,0x68,0x66, 0x3,0x5a,0x6d, 0x3,0x5a,0x69, + 0x3,0x5a,0x6b, 0x4,0x5c,0x51, 0x4,0x63,0x7e, 0x4,0x66,0x69, + 0x4,0x66,0x6c, 0x4,0x66,0x6e, 0x3,0x5e,0x4a, 0x4,0x66,0x6a, + 0x3,0x5e,0x4d, 0x4,0x66,0x68, 0x4,0x66,0x6d, 0x3,0x5f,0x56, + 0x5,0x70,0x61, 0x4,0x69,0x26, 0x4,0x69,0x28, 0x4,0x6a,0x5d, + 0x4,0x6a,0x61, 0x4,0x6a,0x5c, 0x3,0x60,0x5f, 0x4,0x6b,0x76, + 0x4,0x6d,0x5c, 0x4,0x6d,0x76, 0x7,0x65,0x5d, 0x4,0x2a,0x77, + 0x3,0x33,0x2f, 0x3,0x33,0x33, 0x6,0x43,0x22, 0x4,0x34,0x25, + 0x5,0x34,0x59, 0x3,0x37,0x7c, 0x6,0x4c,0x60, 0x4,0x39,0x7b, + 0x4,0x39,0x7c, 0x3,0x3d,0x7d, 0x3,0x3d,0x7c, 0x4,0x39,0x7d, + 0x3,0x43,0x5a, 0x3,0x43,0x56, 0x3,0x43,0x57, 0x3,0x43,0x59, + 0x3,0x43,0x5b, 0x3,0x48,0x63, 0x4,0x45,0x72, 0x3,0x48,0x64, + 0x3,0x48,0x65, 0x6,0x60,0x2c, 0x3,0x48,0x66, 0x3,0x4d,0x6b, + 0x3,0x4d,0x6c, 0x3,0x4d,0x69, 0x3,0x4d,0x6a, 0x4,0x4c,0x37, + 0x7,0x26,0x57, 0x4,0x4c,0x35, 0x3,0x52,0x36, 0x4,0x57,0x6d, + 0x3,0x55,0x73, 0x3,0x55,0x72, 0x4,0x57,0x69, 0x4,0x57,0x6a, + 0x3,0x4d,0x74, 0x4,0x57,0x6b, 0x5,0x63,0x4e, 0x4,0x5c,0x56, + 0x3,0x58,0x52, 0x4,0x5c,0x55, 0x4,0x5c,0x54, 0x5,0x63,0x54, + 0x3,0x58,0x53, 0x3,0x5a,0x70, 0x4,0x60,0x5b, 0x4,0x60,0x5d, + 0x4,0x64,0x23, 0x3,0x5c,0x68, 0x7,0x54,0x3a, 0x5,0x70,0x70, + 0x4,0x6a,0x65, 0x5,0x76,0x39, 0x4,0x6c,0x7a, 0x3,0x61,0x45, + 0x4,0x27,0x5c, 0x6,0x33,0x64, 0x3,0x2e,0x57, 0x3,0x2e,0x55, + 0x3,0x2e,0x58, 0x4,0x2e,0x78, 0x4,0x2e,0x7e, 0x3,0x33,0x35, + 0x3,0x33,0x34, 0x4,0x2e,0x7c, 0x3,0x33,0x39, 0x4,0x2f,0x21, + 0x3,0x33,0x38, 0x4,0x2e,0x7d, 0x3,0x33,0x36, 0x3,0x33,0x3a, + 0x4,0x34,0x2e, 0x4,0x34,0x26, 0x3,0x38,0x23, 0x3,0x38,0x2a, + 0x4,0x34,0x27, 0x4,0x34,0x30, 0x3,0x38,0x2c, 0x4,0x34,0x2d, + 0x4,0x34,0x2b, 0x4,0x34,0x29, 0x3,0x38,0x28, 0x3,0x38,0x2d, + 0x3,0x38,0x25, 0x3,0x3e,0x36, 0x5,0x3b,0x2c, 0x3,0x3e,0x2d, + 0x3,0x3e,0x32, 0x3,0x3e,0x27, 0x3,0x3e,0x30, 0x3,0x3e,0x25, + 0x6,0x4c,0x71, 0x3,0x3e,0x31, 0x4,0x3f,0x6a, 0x3,0x43,0x65, + 0x3,0x43,0x6b, 0x4,0x3f,0x6e, 0x4,0x3f,0x73, 0x4,0x3f,0x6f, + 0x3,0x43,0x61, 0x3,0x43,0x5d, 0x3,0x48,0x6c, 0x4,0x45,0x75, + 0x4,0x45,0x7e, 0x4,0x45,0x79, 0x4,0x46,0x21, 0x3,0x48,0x67, + 0x3,0x43,0x5f, 0x3,0x48,0x72, 0x3,0x48,0x75, 0x4,0x46,0x23, + 0x5,0x48,0x54, 0x3,0x48,0x6f, 0x3,0x4e,0x2a, 0x5,0x4f,0x53, + 0x4,0x4c,0x3e, 0x4,0x4c,0x3c, 0x4,0x4c,0x40, 0x3,0x4d,0x7b, + 0x3,0x4e,0x21, 0x3,0x4e,0x2d, 0x3,0x4d,0x76, 0x3,0x4d,0x79, + 0x4,0x4c,0x3a, 0x4,0x4c,0x3d, 0x4,0x4c,0x3f, 0x3,0x4d,0x7a, + 0x4,0x4c,0x44, 0x5,0x4f,0x54, 0x3,0x4e,0x26, 0x3,0x4e,0x23, + 0x3,0x52,0x3a, 0x4,0x52,0x49, 0x3,0x52,0x3c, 0x4,0x52,0x47, + 0x3,0x52,0x3d, 0x3,0x52,0x3e, 0x4,0x57,0x73, 0x3,0x55,0x78, + 0x5,0x5d,0x3f, 0x3,0x55,0x76, 0x5,0x5d,0x46, 0x3,0x55,0x77, + 0x4,0x57,0x6e, 0x3,0x55,0x7c, 0x3,0x55,0x7b, 0x7,0x3a,0x39, + 0x4,0x5c,0x62, 0x4,0x5c,0x60, 0x4,0x57,0x72, 0x3,0x58,0x57, + 0x3,0x58,0x56, 0x3,0x59,0x29, 0x4,0x60,0x66, 0x4,0x60,0x63, + 0x4,0x60,0x68, 0x4,0x60,0x62, 0x7,0x47,0x4a, 0x3,0x5a,0x73, + 0x3,0x5a,0x71, 0x5,0x6d,0x22, 0x3,0x5c,0x69, 0x4,0x64,0x24, + 0x3,0x5c,0x6a, 0x3,0x5c,0x6b, 0x3,0x5e,0x4f, 0x3,0x5e,0x4e, + 0x4,0x69,0x2a, 0x7,0x58,0x58, 0x3,0x5f,0x59, 0x4,0x69,0x2b, + 0x4,0x6a,0x66, 0x4,0x6b,0x79, 0x4,0x6b,0x78, 0x7,0x5f,0x33, + 0x3,0x60,0x78, 0x4,0x6c,0x7c, 0x4,0x6c,0x7b, 0x4,0x6d,0x77, + 0x4,0x2a,0x79, 0x4,0x2f,0x29, 0x3,0x38,0x2f, 0x3,0x38,0x32, + 0x5,0x34,0x60, 0x4,0x34,0x34, 0x3,0x38,0x30, 0x4,0x34,0x33, + 0x4,0x3a,0x28, 0x4,0x46,0x25, 0x3,0x48,0x76, 0x4,0x52,0x4e, + 0x4,0x6a,0x6b, 0xf,0x21,0x47, 0x3,0x2a,0x4d, 0x3,0x2e,0x5c, + 0x3,0x2e,0x5b, 0x3,0x2e,0x59, 0x4,0x2a,0x7b, 0x4,0x2f,0x2a, + 0x6,0x3a,0x6b, 0x4,0x2f,0x2d, 0x4,0x34,0x35, 0x4,0x3f,0x75, + 0x4,0x3a,0x2a, 0x3,0x43,0x6c, 0x3,0x43,0x6d, 0x5,0x41,0x65, + 0x3,0x48,0x7a, 0x3,0x48,0x7b, 0x4,0x52,0x4f, 0x4,0x57,0x75, + 0x4,0x5c,0x65, 0x4,0x60,0x6d, 0x4,0x66,0x7b, 0x4,0x6b,0x7b, + 0x6,0x3a,0x74, 0x4,0x2f,0x2e, 0x3,0x31,0x3f, 0x4,0x34,0x38, + 0x4,0x34,0x36, 0x4,0x34,0x37, 0x6,0x43,0x3c, 0x4,0x3a,0x2d, + 0x4,0x3a,0x31, 0x4,0x3a,0x30, 0x4,0x3f,0x76, 0x3,0x48,0x7e, + 0x4,0x46,0x27, 0x3,0x48,0x7d, 0x4,0x46,0x28, 0x3,0x48,0x7c, + 0x4,0x4c,0x49, 0x4,0x52,0x53, 0x3,0x52,0x41, 0x4,0x57,0x77, + 0x4,0x5c,0x6a, 0x4,0x5c,0x6b, 0x4,0x69,0x2c, 0x3,0x33,0x40, + 0x3,0x33,0x41, 0x4,0x34,0x3a, 0x3,0x38,0x33, 0x4,0x34,0x3b, + 0x4,0x34,0x3e, 0x4,0x34,0x3c, 0x3,0x38,0x35, 0x3,0x38,0x34, + 0x4,0x3a,0x34, 0x4,0x3a,0x35, 0x5,0x3b,0x3a, 0x4,0x3a,0x33, + 0x3,0x43,0x70, 0x4,0x3f,0x78, 0x3,0x43,0x71, 0x4,0x3f,0x77, + 0x3,0x43,0x6f, 0x3,0x49,0x21, 0x4,0x46,0x2a, 0x4,0x46,0x29, + 0x4,0x46,0x2b, 0x4,0x52,0x55, 0x4,0x52,0x56, 0x3,0x58,0x5e, + 0x3,0x58,0x60, 0x3,0x58,0x5f, 0x3,0x5c,0x6e, 0x4,0x66,0x7d, + 0x3,0x3e,0x39, 0x3,0x3e,0x3a, 0x4,0x2b,0x27, 0x4,0x2b,0x28, + 0x4,0x2f,0x38, 0x4,0x2b,0x29, 0x3,0x38,0x38, 0x4,0x3f,0x7a, + 0x4,0x46,0x2e, 0x4,0x46,0x2d, 0x4,0x46,0x2f, 0x4,0x46,0x32, + 0x4,0x46,0x30, 0x4,0x4c,0x4f, 0x4,0x57,0x7d, 0x4,0x57,0x7a, + 0x4,0x57,0x7b, 0x4,0x5c,0x70, 0x4,0x67,0x21, 0x4,0x24,0x6d, + 0x3,0x33,0x46, 0x3,0x33,0x45, 0x3,0x38,0x3a, 0x4,0x34,0x41, + 0x4,0x3a,0x39, 0x5,0x41,0x70, 0x3,0x43,0x74, 0x4,0x46,0x36, + 0x4,0x46,0x34, 0x4,0x46,0x35, 0x4,0x46,0x37, 0x3,0x49,0x24, + 0x3,0x4e,0x33, 0x4,0x4c,0x52, 0x4,0x52,0x5a, 0x3,0x52,0x42, + 0x4,0x52,0x5b, 0x4,0x58,0x21, 0x4,0x58,0x24, 0x4,0x58,0x23, + 0x4,0x58,0x22, 0x3,0x58,0x64, 0x4,0x64,0x28, 0x3,0x5f,0x5c, + 0x6,0x56,0x6d, 0x4,0x23,0x2d, 0x6,0x25,0x49, 0x4,0x24,0x6f, + 0x4,0x24,0x6e, 0x3,0x2a,0x51, 0x6,0x3b,0x28, 0x3,0x2a,0x55, + 0x3,0x2a,0x50, 0x4,0x27,0x66, 0xf,0x28,0x52, 0x4,0x27,0x62, + 0x4,0x27,0x67, 0x4,0x27,0x63, 0x4,0x27,0x65, 0x5,0x27,0x58, + 0x3,0x2a,0x5a, 0x3,0x2a,0x53, 0x5,0x2b,0x33, 0x4,0x2b,0x2f, + 0x4,0x2b,0x2a, 0x4,0x2b,0x2c, 0x3,0x2e,0x62, 0x3,0x2e,0x5f, + 0x6,0x33,0x7d, 0x5,0x2b,0x39, 0x3,0x33,0x51, 0x4,0x2f,0x41, + 0x4,0x2f,0x46, 0x4,0x2f,0x47, 0x4,0x2f,0x3f, 0x6,0x3b,0x31, + 0x5,0x2f,0x6d, 0x3,0x38,0x46, 0x4,0x34,0x4c, 0x4,0x34,0x48, + 0x3,0x38,0x44, 0x4,0x34,0x4b, 0x4,0x34,0x52, 0x4,0x34,0x51, + 0x4,0x34,0x4a, 0x4,0x34,0x53, 0x6,0x43,0x58, 0x3,0x38,0x40, + 0x3,0x38,0x3f, 0x3,0x38,0x43, 0x4,0x3a,0x49, 0x4,0x3a,0x3a, + 0x3,0x3e,0x3f, 0x4,0x3a,0x45, 0x5,0x3b,0x4d, 0x4,0x3a,0x4a, + 0x4,0x3a,0x41, 0x4,0x3a,0x40, 0x4,0x3a,0x42, 0x4,0x3a,0x3d, + 0x3,0x3e,0x46, 0x4,0x3a,0x3f, 0x4,0x3a,0x44, 0x4,0x3a,0x4b, + 0x6,0x49,0x7e, 0x6,0x4d,0x54, 0x6,0x56,0x76, 0x4,0x40,0x27, + 0x3,0x43,0x78, 0x4,0x40,0x2a, 0x4,0x40,0x23, 0x4,0x40,0x26, + 0x3,0x43,0x7a, 0x4,0x3f,0x7d, 0x4,0x40,0x28, 0x3,0x44,0x21, + 0x4,0x40,0x2c, 0x3,0x43,0x7d, 0x3,0x43,0x79, 0x5,0x34,0x6a, + 0x4,0x40,0x25, 0x4,0x46,0x45, 0x4,0x46,0x3e, 0x4,0x46,0x3c, + 0x4,0x46,0x3d, 0x4,0x46,0x3f, 0x3,0x52,0x48, 0x4,0x46,0x42, + 0x4,0x46,0x40, 0x4,0x46,0x3b, 0x3,0x49,0x29, 0x3,0x49,0x28, + 0x4,0x46,0x38, 0x4,0x46,0x47, 0x4,0x46,0x41, 0x4,0x4c,0x5d, + 0x4,0x4c,0x58, 0x4,0x4c,0x5e, 0x4,0x4c,0x55, 0x4,0x4c,0x5c, + 0x6,0x60,0x6f, 0x4,0x4c,0x54, 0x4,0x4c,0x5b, 0x4,0x4c,0x5f, + 0x5,0x42,0x28, 0x4,0x52,0x63, 0x4,0x52,0x64, 0x3,0x52,0x46, + 0x3,0x52,0x45, 0x4,0x52,0x5e, 0x4,0x52,0x61, 0x4,0x52,0x62, + 0x4,0x52,0x66, 0xf,0x51,0x55, 0x5,0x5d,0x5b, 0x4,0x58,0x2b, + 0x4,0x58,0x28, 0x4,0x58,0x2c, 0x4,0x5c,0x74, 0x3,0x58,0x66, + 0x4,0x5c,0x76, 0x3,0x58,0x67, 0x3,0x5a,0x76, 0x4,0x60,0x74, + 0x4,0x60,0x73, 0x5,0x6d,0x2c, 0x4,0x64,0x2a, 0x4,0x67,0x22, + 0x4,0x67,0x24, 0x4,0x67,0x23, 0x4,0x67,0x25, 0x4,0x69,0x30, + 0x6,0x43,0x64, 0x7,0x42,0x24, 0x3,0x2b,0x44, 0x3,0x44,0x24, + 0x4,0x2f,0x4a, 0x4,0x34,0x58, 0x4,0x4c,0x63, 0x4,0x52,0x6b, + 0x3,0x33,0x53, 0x3,0x33,0x54, 0x3,0x38,0x4a, 0x4,0x4c,0x64, + 0x6,0x61,0x21, 0x3,0x52,0x4b, 0x3,0x5e,0x54, 0x4,0x27,0x6f, + 0x4,0x2b,0x33, 0x4,0x2b,0x32, 0x3,0x2e,0x67, 0x3,0x33,0x56, + 0x4,0x2f,0x50, 0x3,0x38,0x4b, 0x6,0x43,0x71, 0x6,0x43,0x70, + 0x3,0x3e,0x4a, 0x4,0x3a,0x4e, 0x4,0x3a,0x4f, 0x6,0x4d,0x63, + 0x5,0x42,0x2d, 0x4,0x40,0x2f, 0x4,0x46,0x4f, 0x4,0x46,0x51, + 0x4,0x46,0x50, 0x3,0x49,0x2c, 0x6,0x61,0x24, 0x5,0x49,0x2c, + 0x3,0x4e,0x3e, 0x4,0x4c,0x68, 0x4,0x4c,0x65, 0x4,0x52,0x6c, + 0x4,0x52,0x6d, 0x4,0x58,0x30, 0x4,0x58,0x34, 0x4,0x58,0x33, + 0x3,0x56,0x25, 0x3,0x56,0x26, 0x5,0x5d,0x67, 0x5,0x5c,0x4d, + 0x4,0x58,0x32, 0x4,0x5c,0x7c, 0x4,0x64,0x2d, 0x4,0x2f,0x53, + 0x4,0x34,0x5c, 0x4,0x52,0x6f, 0x4,0x52,0x6e, 0x4,0x58,0x35, + 0x4,0x5c,0x7d, 0x4,0x69,0x33, 0x6,0x25,0x4f, 0x3,0x24,0x37, + 0x3,0x24,0x39, 0x3,0x27,0x27, 0x4,0x24,0x76, 0x4,0x24,0x7d, + 0x3,0x27,0x2c, 0x3,0x2a,0x63, 0x3,0x2a,0x67, 0x3,0x2a,0x64, + 0x3,0x2a,0x6a, 0x4,0x27,0x72, 0x3,0x2a,0x62, 0x4,0x28,0x21, + 0x4,0x27,0x73, 0x3,0x2a,0x65, 0x3,0x2a,0x69, 0x5,0x27,0x63, + 0x3,0x2a,0x61, 0x3,0x2e,0x6d, 0x4,0x2b,0x36, 0x3,0x2e,0x70, + 0x3,0x2e,0x71, 0x3,0x2e,0x6c, 0x3,0x2e,0x73, 0x3,0x2e,0x75, + 0x6,0x34,0x3a, 0x4,0x2f,0x55, 0x3,0x33,0x61, 0x4,0x2f,0x61, + 0x3,0x33,0x64, 0x3,0x33,0x5b, 0x3,0x33,0x5e, 0x6,0x3b,0x56, + 0x3,0x33,0x5d, 0x4,0x2f,0x5e, 0x3,0x33,0x5c, 0x3,0x33,0x65, + 0x5,0x30,0x21, 0x4,0x2f,0x59, 0x4,0x2f,0x64, 0x3,0x33,0x60, + 0x4,0x34,0x5e, 0x4,0x34,0x6c, 0x4,0x34,0x71, 0x3,0x38,0x5a, + 0x4,0x34,0x69, 0x4,0x34,0x65, 0x3,0x38,0x56, 0x4,0x34,0x66, + 0x4,0x34,0x62, 0x4,0x34,0x5d, 0x4,0x34,0x63, 0x6,0x44,0x2c, + 0x3,0x38,0x4c, 0x6,0x44,0x28, 0x5,0x35,0x2a, 0x3,0x38,0x59, + 0x3,0x38,0x5c, 0x5,0x35,0x24, 0x4,0x3a,0x6c, 0x4,0x3a,0x60, + 0x4,0x3a,0x5f, 0x4,0x3a,0x64, 0x4,0x3a,0x59, 0x5,0x3b,0x56, + 0x4,0x3a,0x5b, 0x4,0x3a,0x56, 0x3,0x3e,0x53, 0x4,0x3a,0x5e, + 0x3,0x3e,0x54, 0x3,0x3e,0x51, 0x4,0x3a,0x5c, 0x4,0x3a,0x61, + 0x3,0x3e,0x55, 0x6,0x4e,0x27, 0x3,0x3e,0x4c, 0xf,0x3e,0x6b, + 0x4,0x40,0x30, 0x4,0x40,0x32, 0x4,0x3a,0x65, 0x3,0x44,0x37, + 0x4,0x46,0x69, 0x4,0x40,0x47, 0x4,0x40,0x49, 0x4,0x40,0x3a, + 0x3,0x44,0x2b, 0x3,0x44,0x29, 0x3,0x44,0x34, 0x4,0x40,0x48, + 0x3,0x44,0x3d, 0x4,0x40,0x4c, 0x4,0x46,0x65, 0x3,0x49,0x2f, + 0x4,0x46,0x57, 0x6,0x61,0x44, 0x4,0x46,0x64, 0x3,0x49,0x31, + 0x4,0x46,0x53, 0x5,0x49,0x3c, 0x4,0x46,0x61, 0x3,0x49,0x30, + 0x4,0x46,0x6d, 0x4,0x46,0x60, 0x4,0x46,0x5c, 0x3,0x49,0x34, + 0x5,0x49,0x3b, 0x6,0x61,0x58, 0x3,0x49,0x37, 0x3,0x49,0x40, + 0x3,0x4e,0x43, 0x4,0x4c,0x72, 0x3,0x4e,0x3f, 0x4,0x4c,0x70, + 0x4,0x4d,0x24, 0x4,0x4c,0x6b, 0x3,0x4e,0x41, 0x4,0x4c,0x71, + 0x3,0x4e,0x53, 0x4,0x4c,0x6d, 0x4,0x4c,0x73, 0x3,0x4e,0x47, + 0x3,0x4e,0x45, 0x3,0x4e,0x56, 0x4,0x4c,0x7d, 0x3,0x52,0x51, + 0x4,0x4c,0x6c, 0x3,0x4e,0x4a, 0x4,0x4c,0x6e, 0x3,0x4e,0x48, + 0x3,0x4e,0x55, 0x3,0x4e,0x49, 0x5,0x50,0x46, 0x3,0x4e,0x50, + 0xf,0x51,0x65, 0xf,0x51,0x73, 0xf,0x51,0x76, 0x4,0x4d,0x21, + 0x4,0x4c,0x6f, 0x3,0x4e,0x51, 0x4,0x4c,0x77, 0x4,0x52,0x77, + 0x4,0x52,0x7b, 0x4,0x52,0x79, 0x4,0x53,0x2c, 0x4,0x53,0x21, + 0x4,0x52,0x76, 0x3,0x52,0x53, 0x4,0x53,0x25, 0x3,0x52,0x57, + 0x4,0x52,0x7e, 0x3,0x52,0x4d, 0x4,0x53,0x23, 0x4,0x52,0x7a, + 0x4,0x52,0x7c, 0x4,0x52,0x72, 0x5,0x64,0x2d, 0x3,0x52,0x4c, + 0x4,0x53,0x22, 0x4,0x52,0x73, 0x3,0x52,0x4e, 0x4,0x53,0x27, + 0x4,0x53,0x31, 0x4,0x46,0x67, 0x4,0x58,0x44, 0x4,0x58,0x3c, + 0x4,0x58,0x38, 0x4,0x58,0x42, 0x5,0x5d,0x79, 0x4,0x58,0x36, + 0x4,0x58,0x3b, 0x3,0x56,0x2e, 0x3,0x56,0x27, 0x4,0x58,0x3d, + 0x3,0x56,0x2a, 0x3,0x56,0x2f, 0x3,0x58,0x69, 0x4,0x5c,0x7e, + 0x4,0x5d,0x2b, 0x3,0x58,0x6d, 0x3,0x58,0x70, 0x3,0x58,0x6a, + 0x3,0x58,0x71, 0x4,0x5d,0x23, 0x7,0x42,0x38, 0x4,0x5d,0x21, + 0xf,0x60,0x4e, 0x7,0x3b,0x32, 0x4,0x60,0x77, 0x3,0x5c,0x73, + 0x3,0x5b,0x23, 0x4,0x60,0x78, 0x3,0x5b,0x21, 0x3,0x5b,0x24, + 0x7,0x49,0x53, 0x4,0x64,0x2f, 0x4,0x64,0x34, 0x3,0x5c,0x7d, + 0x4,0x64,0x33, 0x3,0x5c,0x74, 0x7,0x54,0x68, 0x3,0x5c,0x79, + 0x4,0x64,0x32, 0x4,0x64,0x38, 0x3,0x5c,0x7a, 0x4,0x64,0x30, + 0x3,0x5c,0x75, 0x4,0x64,0x36, 0x4,0x67,0x27, 0x3,0x5e,0x59, + 0x4,0x67,0x28, 0xf,0x68,0x39, 0x3,0x5f,0x5d, 0x4,0x69,0x37, + 0x7,0x58,0x72, 0x3,0x60,0x41, 0x3,0x60,0x42, 0x5,0x78,0x25, + 0x4,0x6b,0x7d, 0x4,0x6d,0x5e, 0x4,0x6c,0x7d, 0x3,0x61,0x6a, + 0x4,0x6d,0x79, 0x4,0x6d,0x7b, 0xf,0x6c,0x6c, 0x4,0x6e,0x37, + 0x4,0x6e,0x36, 0x5,0x7c,0x3e, 0x3,0x2a,0x6d, 0x4,0x2b,0x3e, + 0x4,0x2f,0x67, 0x3,0x33,0x67, 0x3,0x33,0x66, 0x3,0x33,0x68, + 0x5,0x35,0x35, 0x3,0x38,0x62, 0x5,0x3b,0x70, 0x3,0x3e,0x60, + 0x3,0x44,0x41, 0x5,0x42,0x54, 0x5,0x42,0x53, 0x3,0x44,0x42, + 0x3,0x44,0x43, 0x4,0x4d,0x26, 0x4,0x53,0x36, 0x4,0x5d,0x32, + 0x5,0x64,0x3b, 0x5,0x64,0x3a, 0x4,0x64,0x3a, 0x3,0x27,0x2e, + 0x3,0x2e,0x7d, 0x3,0x2f,0x21, 0x3,0x2f,0x22, 0x4,0x2f,0x69, + 0x4,0x2f,0x6b, 0x6,0x3b,0x69, 0x3,0x38,0x68, 0x3,0x38,0x67, + 0x4,0x34,0x7c, 0x3,0x38,0x65, 0x4,0x34,0x7b, 0x4,0x34,0x79, + 0x5,0x3c,0x26, 0x6,0x44,0x48, 0x4,0x3a,0x72, 0x3,0x3e,0x67, + 0x4,0x3a,0x74, 0x3,0x3e,0x65, 0x5,0x3b,0x74, 0x4,0x3a,0x70, + 0x4,0x3a,0x6d, 0x3,0x3e,0x64, 0x3,0x3e,0x66, 0x4,0x40,0x56, + 0x4,0x40,0x57, 0x3,0x44,0x4b, 0x3,0x44,0x47, 0x4,0x40,0x5b, + 0x4,0x3a,0x6e, 0x4,0x40,0x5d, 0x3,0x44,0x4a, 0x4,0x46,0x78, + 0x3,0x49,0x46, 0x4,0x46,0x72, 0x4,0x46,0x73, 0x4,0x46,0x71, + 0x4,0x46,0x75, 0x3,0x49,0x47, 0x4,0x46,0x70, 0x4,0x46,0x76, + 0x6,0x61,0x69, 0x3,0x49,0x48, 0x4,0x46,0x7b, 0x3,0x4e,0x5a, + 0x3,0x4e,0x5c, 0x7,0x28,0x42, 0x3,0x4e,0x57, 0x3,0x4e,0x58, + 0x4,0x4d,0x30, 0x3,0x4e,0x5b, 0x4,0x46,0x79, 0x4,0x4d,0x36, + 0x4,0x4d,0x2f, 0x3,0x49,0x4d, 0x4,0x53,0x3e, 0x3,0x52,0x5c, + 0x7,0x32,0x73, 0x4,0x53,0x3d, 0x4,0x58,0x4d, 0x3,0x52,0x60, + 0x7,0x32,0x75, 0x3,0x52,0x61, 0x5,0x5e,0x32, 0x4,0x58,0x57, + 0x4,0x58,0x52, 0x3,0x56,0x37, 0x4,0x58,0x58, 0x4,0x58,0x4f, + 0x4,0x58,0x56, 0x3,0x56,0x38, 0x4,0x58,0x4e, 0x3,0x56,0x32, + 0x4,0x58,0x54, 0x4,0x58,0x5f, 0x3,0x56,0x35, 0x3,0x56,0x3c, + 0x3,0x56,0x31, 0x4,0x5d,0x3b, 0x5,0x5e,0x35, 0x4,0x5d,0x39, + 0x3,0x58,0x72, 0x4,0x61,0x24, 0x5,0x69,0x41, 0x3,0x5b,0x2a, + 0x4,0x61,0x21, 0x4,0x61,0x25, 0xf,0x63,0x6e, 0x5,0x6d,0x4b, + 0x4,0x64,0x3b, 0x4,0x64,0x3c, 0x4,0x64,0x40, 0x4,0x64,0x3e, + 0x4,0x64,0x41, 0x3,0x5d,0x26, 0x3,0x5e,0x5e, 0x4,0x67,0x30, + 0x4,0x64,0x3d, 0x4,0x69,0x3e, 0x3,0x5f,0x5e, 0x3,0x5f,0x60, + 0x3,0x60,0x44, 0x7,0x59,0x25, 0x7,0x5c,0x5e, 0x4,0x6a,0x78, + 0x7,0x5c,0x63, 0x3,0x61,0x48, 0x4,0x6e,0x39, 0x3,0x2f,0x25, + 0x6,0x3b,0x73, 0x3,0x38,0x69, 0x3,0x44,0x4c, 0x4,0x47,0x23, + 0x4,0x4d,0x37, 0x4,0x2f,0x6f, 0x4,0x3a,0x78, 0x3,0x4e,0x5e, + 0x4,0x53,0x4a, 0x3,0x5b,0x2e, 0x3,0x2a,0x6e, 0x3,0x2f,0x28, + 0x4,0x2b,0x46, 0x5,0x30,0x3d, 0x4,0x2f,0x72, 0x5,0x30,0x39, + 0x4,0x35,0x2a, 0x4,0x3a,0x7a, 0x4,0x35,0x2d, 0x4,0x35,0x2e, + 0x4,0x35,0x2c, 0xf,0x32,0x51, 0x4,0x3a,0x79, 0x3,0x3e,0x71, + 0x4,0x35,0x30, 0x3,0x3e,0x6e, 0x3,0x3e,0x6c, 0x3,0x3e,0x6b, + 0x3,0x2f,0x4a, 0x4,0x40,0x62, 0x4,0x47,0x25, 0x6,0x58,0x2b, + 0x3,0x49,0x53, 0x4,0x47,0x2d, 0x5,0x49,0x6c, 0x5,0x49,0x6d, + 0x4,0x40,0x66, 0x4,0x47,0x31, 0x4,0x47,0x27, 0x3,0x49,0x55, + 0x4,0x40,0x60, 0x4,0x47,0x2a, 0x4,0x47,0x2e, 0x4,0x47,0x26, + 0x4,0x47,0x2b, 0x3,0x49,0x5a, 0x3,0x49,0x50, 0x3,0x49,0x5b, + 0x4,0x4d,0x3c, 0x4,0x4d,0x3f, 0x4,0x4d,0x3a, 0x4,0x4d,0x39, + 0x4,0x4d,0x42, 0x4,0x4d,0x40, 0x4,0x4d,0x47, 0x4,0x53,0x52, + 0x4,0x53,0x55, 0x4,0x53,0x56, 0x3,0x4e,0x63, 0x4,0x53,0x4f, + 0x4,0x58,0x63, 0x4,0x58,0x67, 0x3,0x56,0x45, 0x3,0x56,0x43, + 0x4,0x58,0x64, 0x3,0x56,0x3e, 0x7,0x3b,0x59, 0x3,0x56,0x44, + 0x4,0x58,0x65, 0x3,0x56,0x41, 0x5,0x64,0x56, 0x4,0x5d,0x4a, + 0x4,0x5d,0x48, 0x4,0x5d,0x49, 0x4,0x5d,0x44, 0x4,0x5d,0x46, + 0x4,0x61,0x2a, 0x7,0x43,0x22, 0x4,0x64,0x43, 0x7,0x50,0x25, + 0x3,0x5d,0x27, 0x4,0x64,0x44, 0x3,0x5e,0x5f, 0x4,0x6a,0x7b, + 0x7,0x59,0x32, 0x3,0x60,0x7a, 0x4,0x6c,0x26, 0x3,0x60,0x79, + 0x4,0x6d,0x7d, 0x5,0x2b,0x47, 0x4,0x2f,0x73, 0x4,0x35,0x31, + 0x4,0x3b,0x21, 0x3,0x33,0x79, 0x3,0x33,0x78, 0x4,0x35,0x33, + 0x4,0x35,0x35, 0x4,0x3b,0x23, 0x5,0x3c,0x35, 0x4,0x3b,0x22, + 0x3,0x3e,0x73, 0x3,0x44,0x50, 0x3,0x44,0x51, 0x4,0x47,0x36, + 0x4,0x47,0x38, 0x4,0x4d,0x4a, 0x4,0x4d,0x48, 0x4,0x53,0x5a, + 0x4,0x53,0x5b, 0x5,0x58,0x32, 0x4,0x53,0x5c, 0x5,0x5e,0x43, + 0x4,0x58,0x68, 0x4,0x58,0x69, 0x4,0x5d,0x4e, 0x4,0x5d,0x50, + 0x4,0x61,0x2d, 0x4,0x61,0x2e, 0x3,0x5b,0x30, 0x4,0x61,0x2c, + 0x4,0x61,0x30, 0x3,0x5e,0x60, 0x3,0x62,0x3c, 0x4,0x35,0x3a, + 0x3,0x44,0x53, 0x4,0x40,0x67, 0x3,0x44,0x52, 0x4,0x47,0x3a, + 0x4,0x4d,0x51, 0x4,0x4d,0x4c, 0x4,0x4d,0x4e, 0x4,0x4d,0x53, + 0x4,0x4d,0x4f, 0x4,0x53,0x64, 0x4,0x53,0x61, 0x4,0x53,0x62, + 0x4,0x58,0x6b, 0x4,0x58,0x6a, 0x5,0x64,0x63, 0x4,0x61,0x31, + 0x4,0x61,0x34, 0x4,0x64,0x46, 0x4,0x64,0x47, 0x4,0x6d,0x22, + 0x3,0x2f,0x2b, 0x5,0x2b,0x49, 0x3,0x2f,0x2d, 0x4,0x2f,0x7e, + 0x3,0x33,0x7d, 0x4,0x35,0x41, 0x3,0x38,0x7c, 0x3,0x38,0x78, + 0x5,0x35,0x57, 0x4,0x35,0x44, 0x5,0x35,0x5e, 0x3,0x39,0x24, + 0x3,0x39,0x28, 0x3,0x39,0x21, 0x4,0x35,0x3f, 0x3,0x38,0x7d, + 0x3,0x39,0x27, 0x4,0x35,0x43, 0x5,0x35,0x5d, 0x6,0x44,0x6d, + 0x3,0x39,0x26, 0x5,0x35,0x56, 0x4,0x3b,0x33, 0x3,0x3e,0x79, + 0x3,0x3e,0x7a, 0x4,0x3b,0x36, 0x4,0x3b,0x35, 0x3,0x3e,0x76, + 0x3,0x3e,0x7b, 0x3,0x3e,0x77, 0x4,0x3b,0x34, 0x4,0x3b,0x2a, + 0x4,0x3b,0x29, 0x4,0x3b,0x2b, 0x3,0x3f,0x26, 0x6,0x4e,0x6b, + 0x3,0x3f,0x25, 0x3,0x44,0x57, 0x6,0x58,0x41, 0x3,0x44,0x5e, + 0x4,0x40,0x6e, 0x4,0x40,0x6d, 0x4,0x40,0x6c, 0x3,0x44,0x5a, + 0x3,0x44,0x5f, 0x3,0x44,0x62, 0x4,0x47,0x3d, 0x4,0x47,0x40, + 0x4,0x47,0x4a, 0x4,0x47,0x3c, 0x3,0x49,0x6a, 0x4,0x47,0x46, + 0x4,0x47,0x42, 0x3,0x49,0x61, 0x4,0x47,0x43, 0x3,0x49,0x69, + 0x3,0x49,0x67, 0x3,0x49,0x5d, 0x4,0x4d,0x59, 0x4,0x4d,0x56, + 0x4,0x4d,0x5c, 0x4,0x4d,0x5e, 0x3,0x4e,0x68, 0x4,0x4d,0x61, + 0x4,0x4d,0x58, 0x4,0x4d,0x5b, 0x3,0x4e,0x6d, 0x4,0x4d,0x5f, + 0x4,0x4d,0x5a, 0x3,0x4e,0x6b, 0x4,0x4d,0x60, 0x7,0x28,0x79, + 0x4,0x4d,0x55, 0x3,0x4e,0x71, 0x4,0x53,0x6a, 0x3,0x52,0x6c, + 0x3,0x52,0x6d, 0x7,0x33,0x4d, 0x4,0x53,0x6b, 0x3,0x56,0x47, + 0x4,0x58,0x70, 0x3,0x56,0x4b, 0x3,0x56,0x4c, 0x5,0x5e,0x55, + 0x4,0x5d,0x5a, 0x7,0x4a,0x25, 0x4,0x5d,0x57, 0x4,0x5d,0x5b, + 0x3,0x59,0x22, 0x3,0x59,0x25, 0x4,0x5d,0x54, 0x3,0x59,0x27, + 0x4,0x61,0x40, 0x5,0x69,0x52, 0x3,0x5b,0x33, 0x4,0x61,0x3b, + 0x4,0x61,0x3d, 0x4,0x61,0x45, 0x5,0x69,0x51, 0x4,0x64,0x4e, + 0x3,0x5d,0x2d, 0x7,0x50,0x31, 0x4,0x64,0x4c, 0x3,0x5d,0x2f, + 0x4,0x64,0x48, 0x3,0x5d,0x31, 0x4,0x67,0x3d, 0x4,0x67,0x3f, + 0x7,0x55,0x32, 0x4,0x67,0x3e, 0x4,0x67,0x40, 0x4,0x67,0x39, + 0x7,0x59,0x38, 0x3,0x5f,0x63, 0x4,0x69,0x48, 0x5,0x76,0x4c, + 0x4,0x2b,0x49, 0x4,0x30,0x23, 0x6,0x4e,0x7a, 0x3,0x3f,0x27, + 0x4,0x47,0x4c, 0x3,0x4e,0x77, 0x4,0x58,0x75, 0x4,0x5d,0x61, + 0x4,0x69,0x4c, 0x4,0x35,0x4a, 0x3,0x3f,0x28, 0x4,0x40,0x74, + 0x4,0x47,0x4e, 0x4,0x47,0x4f, 0x3,0x49,0x6c, 0x4,0x4d,0x64, + 0x3,0x52,0x70, 0x4,0x53,0x73, 0x3,0x52,0x6f, 0x4,0x53,0x72, + 0x3,0x52,0x71, 0x4,0x58,0x76, 0x4,0x58,0x77, 0x3,0x56,0x4e, + 0x4,0x67,0x44, 0x4,0x6d,0x24, 0x4,0x30,0x25, 0x4,0x35,0x4b, + 0x6,0x45,0x22, 0x4,0x35,0x4c, 0xf,0x44,0x74, 0x4,0x4d,0x67, + 0x4,0x4d,0x65, 0x4,0x4d,0x68, 0x4,0x53,0x75, 0x4,0x53,0x77, + 0x4,0x5d,0x64, 0x4,0x61,0x48, 0x4,0x61,0x46, 0x4,0x67,0x45, + 0x3,0x5f,0x65, 0x3,0x61,0x4c, 0x4,0x6d,0x25, 0x4,0x35,0x50, + 0x6,0x45,0x24, 0x3,0x39,0x2f, 0x4,0x3b,0x3e, 0x3,0x49,0x6e, + 0x3,0x4e,0x79, 0x3,0x4e,0x78, 0x3,0x52,0x72, 0x3,0x56,0x50, + 0x3,0x59,0x2c, 0x3,0x59,0x2d, 0x4,0x61,0x4a, 0x7,0x4a,0x41, + 0x3,0x5b,0x37, 0x4,0x5d,0x68, 0x4,0x35,0x51, 0x4,0x35,0x54, + 0x5,0x3c,0x4c, 0x4,0x3b,0x3f, 0x4,0x3b,0x41, 0x3,0x3f,0x2e, + 0x4,0x3b,0x42, 0x6,0x4f,0x29, 0x4,0x3b,0x43, 0x4,0x41,0x21, + 0x3,0x44,0x66, 0x3,0x44,0x68, 0x5,0x4a,0x29, 0x6,0x62,0x6a, + 0x3,0x49,0x6f, 0x3,0x4e,0x7b, 0x3,0x4e,0x7c, 0x4,0x4d,0x6e, + 0x4,0x4d,0x6c, 0x7,0x29,0x36, 0x4,0x4d,0x6d, 0x5,0x51,0x39, + 0x3,0x4f,0x21, 0x3,0x52,0x74, 0x4,0x53,0x7d, 0x4,0x53,0x79, + 0x4,0x53,0x7b, 0x4,0x53,0x7a, 0x3,0x52,0x76, 0x7,0x3c,0x33, + 0x4,0x58,0x7a, 0xf,0x60,0x7a, 0x4,0x53,0x7e, 0x3,0x5d,0x35, + 0x3,0x5e,0x64, 0x4,0x6b,0x21, 0x5,0x30,0x4b, 0x5,0x43,0x34, + 0x4,0x47,0x59, 0x4,0x47,0x58, 0x4,0x67,0x48, 0x5,0x30,0x4c, + 0x4,0x30,0x27, 0x4,0x30,0x28, 0x4,0x35,0x55, 0x4,0x35,0x56, + 0x3,0x39,0x34, 0x3,0x39,0x36, 0x3,0x3f,0x31, 0x4,0x3b,0x45, + 0x3,0x3f,0x36, 0x3,0x3f,0x32, 0x5,0x3c,0x52, 0x3,0x3f,0x35, + 0x4,0x3b,0x48, 0x4,0x3b,0x47, 0x4,0x41,0x26, 0x4,0x41,0x27, + 0x5,0x43,0x3c, 0x3,0x44,0x6a, 0x4,0x41,0x28, 0x5,0x43,0x38, + 0x4,0x47,0x5a, 0x6,0x62,0x75, 0x4,0x47,0x5b, 0x3,0x49,0x76, + 0x5,0x4a,0x34, 0x3,0x49,0x77, 0x5,0x4a,0x32, 0x3,0x4f,0x27, + 0x4,0x4d,0x73, 0x4,0x4d,0x71, 0x3,0x4f,0x24, 0x4,0x4d,0x74, + 0x7,0x29,0x3d, 0x4,0x54,0x26, 0x5,0x58,0x5c, 0x5,0x58,0x55, + 0x3,0x52,0x78, 0x4,0x58,0x7d, 0x4,0x59,0x25, 0x4,0x58,0x7c, + 0x5,0x5e,0x6d, 0x4,0x5d,0x6d, 0x3,0x59,0x2f, 0x4,0x5d,0x6c, + 0x4,0x5d,0x6a, 0x4,0x5d,0x6e, 0x3,0x59,0x30, 0x4,0x61,0x4d, + 0x3,0x5d,0x36, 0x4,0x64,0x55, 0x4,0x64,0x53, 0x4,0x64,0x56, + 0x4,0x67,0x4a, 0x4,0x69,0x4e, 0x3,0x5f,0x66, 0x4,0x69,0x4f, + 0x4,0x6b,0x23, 0x4,0x6c,0x28, 0x4,0x6d,0x27, 0x4,0x2b,0x4c, + 0x3,0x2f,0x2f, 0x4,0x30,0x2a, 0x3,0x33,0x7e, 0x4,0x35,0x5e, + 0x4,0x35,0x59, 0x5,0x35,0x72, 0x3,0x39,0x3b, 0x4,0x35,0x5b, + 0x4,0x35,0x5c, 0x4,0x35,0x5d, 0x3,0x39,0x3c, 0x5,0x3c,0x63, + 0x4,0x3b,0x4c, 0x4,0x3b,0x50, 0x3,0x3f,0x3d, 0x4,0x3b,0x4d, + 0x4,0x3b,0x49, 0x6,0x4f,0x36, 0x6,0x4f,0x3c, 0x5,0x3c,0x5c, + 0x4,0x3b,0x4a, 0x4,0x3b,0x4b, 0x4,0x3b,0x4f, 0x3,0x3f,0x3c, + 0x5,0x3c,0x5f, 0x4,0x3b,0x51, 0x4,0x41,0x29, 0x5,0x43,0x4b, + 0x3,0x44,0x6c, 0x3,0x44,0x6e, 0xf,0x45,0x58, 0x5,0x4a,0x3e, + 0x4,0x47,0x5e, 0x4,0x47,0x61, 0x4,0x47,0x5f, 0x4,0x47,0x62, + 0x4,0x47,0x65, 0x3,0x49,0x78, 0x4,0x47,0x64, 0x3,0x4f,0x28, + 0x3,0x44,0x6f, 0x4,0x4d,0x77, 0x4,0x4e,0x22, 0x3,0x4f,0x2a, + 0x7,0x29,0x4e, 0x3,0x4f,0x2e, 0x3,0x4f,0x29, 0x4,0x4d,0x7e, + 0x4,0x4e,0x21, 0x4,0x4d,0x7d, 0x4,0x4d,0x79, 0x4,0x4d,0x78, + 0x4,0x4d,0x76, 0x3,0x4f,0x2d, 0x4,0x4e,0x23, 0x4,0x54,0x2e, + 0x3,0x52,0x7d, 0x3,0x52,0x7a, 0x4,0x54,0x2f, 0x4,0x54,0x2d, + 0x5,0x58,0x62, 0x4,0x54,0x30, 0x3,0x52,0x79, 0x5,0x5e,0x7b, + 0x4,0x59,0x2b, 0x4,0x59,0x2c, 0x4,0x59,0x26, 0xf,0x5c,0x78, + 0x4,0x59,0x2a, 0x4,0x59,0x28, 0x3,0x56,0x53, 0x3,0x59,0x33, + 0x4,0x5d,0x74, 0x4,0x5d,0x78, 0x4,0x5d,0x72, 0x4,0x5d,0x75, + 0x7,0x4a,0x57, 0x4,0x61,0x50, 0x3,0x59,0x34, 0x4,0x61,0x51, + 0x4,0x5d,0x77, 0x4,0x64,0x5b, 0x4,0x64,0x5a, 0x4,0x67,0x50, + 0x4,0x67,0x4c, 0x5,0x74,0x4b, 0x4,0x6b,0x24, 0x7,0x5c,0x77, + 0x4,0x6c,0x29, 0x3,0x61,0x4f, 0x3,0x62,0x2e, 0x3,0x3f,0x42, + 0x5,0x3c,0x67, 0x4,0x3b,0x52, 0x4,0x3b,0x53, 0x3,0x3f,0x41, + 0x3,0x44,0x71, 0x3,0x44,0x70, 0x3,0x44,0x72, 0x4,0x4e,0x26, + 0x4,0x54,0x32, 0x4,0x59,0x30, 0x3,0x56,0x56, 0x3,0x5b,0x3e, + 0x4,0x64,0x5f, 0x3,0x60,0x4c, 0x4,0x2b,0x4d, 0x4,0x2b,0x4e, + 0xf,0x2d,0x53, 0x3,0x34,0x22, 0x3,0x39,0x43, 0x3,0x39,0x44, + 0x3,0x39,0x48, 0x4,0x35,0x61, 0x4,0x35,0x62, 0x3,0x39,0x45, + 0x3,0x39,0x46, 0x3,0x39,0x42, 0x6,0x45,0x45, 0x3,0x3f,0x48, + 0x3,0x3f,0x43, 0x4,0x3b,0x54, 0x3,0x3f,0x4a, 0x3,0x44,0x75, + 0x4,0x41,0x2a, 0x3,0x44,0x74, 0x6,0x59,0x24, 0x4,0x41,0x2c, + 0x4,0x47,0x66, 0x4,0x47,0x69, 0x4,0x47,0x67, 0x3,0x49,0x7e, + 0x4,0x4e,0x28, 0x4,0x4e,0x27, 0x4,0x4e,0x2a, 0x4,0x4e,0x29, + 0x3,0x53,0x23, 0x5,0x58,0x72, 0x4,0x54,0x33, 0x4,0x54,0x34, + 0x5,0x51,0x61, 0x3,0x56,0x58, 0x4,0x59,0x32, 0x4,0x59,0x35, + 0x4,0x59,0x37, 0x3,0x56,0x57, 0x4,0x59,0x31, 0x4,0x5d,0x7c, + 0x4,0x5d,0x7b, 0x4,0x5d,0x7a, 0x5,0x65,0x35, 0x4,0x5d,0x7d, + 0x4,0x5d,0x7e, 0x4,0x61,0x59, 0x4,0x61,0x58, 0x4,0x61,0x57, + 0x4,0x64,0x60, 0x4,0x64,0x61, 0x4,0x67,0x52, 0xf,0x68,0x53, + 0x3,0x5f,0x68, 0x3,0x5f,0x67, 0x3,0x60,0x7d, 0x4,0x6d,0x61, + 0x4,0x6e,0x21, 0x3,0x62,0x3d, 0x4,0x4e,0x2e, 0x3,0x5d,0x39, + 0x4,0x47,0x6b, 0xf,0x4c,0x67, 0x3,0x4f,0x38, 0x4,0x64,0x63, + 0x7,0x50,0x56, 0x3,0x27,0x32, 0x4,0x25,0x22, 0xf,0x28,0x72, + 0x3,0x2a,0x6f, 0x5,0x27,0x69, 0x4,0x2b,0x53, 0x4,0x2b,0x50, + 0x3,0x34,0x23, 0x4,0x30,0x2d, 0x4,0x30,0x30, 0x3,0x34,0x24, + 0x4,0x30,0x2e, 0x3,0x39,0x49, 0x4,0x35,0x69, 0x3,0x39,0x4d, + 0x3,0x3f,0x53, 0x4,0x3b,0x57, 0x3,0x3f,0x4e, 0x6,0x4f,0x48, + 0x3,0x3f,0x52, 0x4,0x41,0x2f, 0x3,0x4a,0x25, 0x4,0x47,0x6c, + 0x3,0x4a,0x23, 0x3,0x4f,0x3a, 0x4,0x4e,0x31, 0x4,0x4e,0x35, + 0x3,0x4f,0x3d, 0x3,0x53,0x2a, 0x3,0x53,0x28, 0x3,0x53,0x29, + 0x4,0x59,0x38, 0x4,0x59,0x39, 0x7,0x43,0x77, 0x3,0x59,0x39, + 0x4,0x61,0x5e, 0x4,0x6c,0x2c, 0x3,0x22,0x5f, 0x4,0x23,0x32, + 0x3,0x27,0x36, 0x3,0x27,0x37, 0x3,0x27,0x38, 0x3,0x2a,0x76, + 0x4,0x28,0x29, 0x3,0x2f,0x36, 0x4,0x2b,0x56, 0x3,0x45,0x22, + 0x3,0x2f,0x3d, 0x4,0x2b,0x54, 0x4,0x2b,0x58, 0x3,0x2f,0x39, + 0x3,0x2f,0x3a, 0x6,0x34,0x6d, 0x4,0x30,0x38, 0x4,0x30,0x34, + 0x3,0x34,0x28, 0x4,0x30,0x33, 0x4,0x47,0x71, 0x4,0x35,0x6c, + 0x4,0x35,0x6e, 0x4,0x35,0x73, 0x4,0x35,0x6b, 0x3,0x39,0x50, + 0x4,0x35,0x70, 0x4,0x3b,0x5e, 0x3,0x3f,0x58, 0x4,0x41,0x34, + 0x4,0x41,0x36, 0x3,0x45,0x21, 0x4,0x59,0x3c, 0x4,0x41,0x38, + 0x4,0x47,0x6d, 0x4,0x47,0x6e, 0x3,0x4a,0x29, 0x3,0x4a,0x28, + 0x5,0x4a,0x60, 0x4,0x47,0x70, 0x3,0x4f,0x3e, 0x4,0x4e,0x3d, + 0x4,0x4e,0x3c, 0x5,0x58,0x7e, 0x5,0x5f,0x3c, 0x3,0x60,0x4d, + 0x4,0x6b,0x26, 0x3,0x2f,0x3f, 0x3,0x34,0x2b, 0x3,0x34,0x2c, + 0x4,0x35,0x78, 0x4,0x35,0x74, 0x3,0x39,0x53, 0x5,0x36,0x36, + 0x4,0x35,0x75, 0x4,0x3b,0x60, 0x3,0x3f,0x5a, 0x3,0x3f,0x5b, + 0x3,0x3f,0x5c, 0x4,0x3b,0x64, 0x6,0x59,0x4c, 0x3,0x45,0x26, + 0x4,0x41,0x3d, 0x4,0x41,0x3c, 0x4,0x41,0x3f, 0x4,0x41,0x3e, + 0x4,0x47,0x73, 0x4,0x47,0x74, 0x4,0x4e,0x3f, 0x4,0x4e,0x41, + 0x4,0x4e,0x3e, 0x4,0x4e,0x40, 0x4,0x54,0x3d, 0x4,0x54,0x3c, + 0x4,0x54,0x3a, 0x3,0x53,0x2e, 0x4,0x54,0x40, 0x4,0x54,0x3b, + 0x7,0x34,0x54, 0x3,0x53,0x30, 0x4,0x59,0x3d, 0x4,0x59,0x42, + 0x7,0x3c,0x70, 0x4,0x59,0x41, 0x5,0x65,0x45, 0x4,0x61,0x61, + 0x4,0x61,0x64, 0x4,0x61,0x63, 0x4,0x61,0x62, 0x4,0x61,0x65, + 0x4,0x67,0x5a, 0x4,0x67,0x5b, 0x4,0x69,0x54, 0x4,0x69,0x53, + 0x4,0x6c,0x2e, 0x4,0x6c,0x2d, 0x4,0x6e,0x3d, 0x4,0x35,0x7a, + 0x6,0x3c,0x63, 0x3,0x39,0x5a, 0x3,0x3f,0x5f, 0x3,0x3f,0x64, + 0x3,0x3f,0x61, 0x3,0x3f,0x67, 0x3,0x45,0x2c, 0x5,0x43,0x6d, + 0x3,0x4a,0x2e, 0x4,0x47,0x79, 0x3,0x4a,0x36, 0x4,0x47,0x76, + 0x4,0x47,0x7b, 0x4,0x47,0x78, 0x3,0x4f,0x4f, 0x4,0x4e,0x43, + 0x3,0x4f,0x47, 0x3,0x4f,0x46, 0x7,0x2a,0x38, 0x3,0x4f,0x4a, + 0x7,0x2a,0x3e, 0x3,0x53,0x33, 0x3,0x53,0x34, 0x4,0x54,0x48, + 0x4,0x54,0x46, 0x7,0x3c,0x7b, 0x3,0x56,0x69, 0x7,0x3c,0x77, + 0x4,0x59,0x45, 0x4,0x59,0x44, 0xf,0x5d,0x4c, 0x3,0x59,0x3f, + 0x3,0x59,0x41, 0x4,0x5e,0x2f, 0x4,0x5e,0x2c, 0x7,0x44,0x39, + 0x4,0x5e,0x27, 0x5,0x65,0x4f, 0x4,0x5e,0x2b, 0x3,0x59,0x48, + 0x3,0x59,0x47, 0x3,0x5b,0x46, 0x4,0x61,0x66, 0x3,0x5b,0x4b, + 0x3,0x5b,0x40, 0x3,0x5b,0x52, 0x4,0x61,0x69, 0x5,0x6a,0x33, + 0x4,0x61,0x68, 0x3,0x5b,0x51, 0x3,0x5b,0x4c, 0x3,0x5b,0x49, + 0xf,0x64,0x34, 0x3,0x5d,0x3b, 0x4,0x61,0x6c, 0x3,0x5d,0x40, + 0x4,0x64,0x66, 0x4,0x64,0x6c, 0x5,0x6e,0x35, 0x3,0x5d,0x48, + 0x4,0x64,0x6d, 0x4,0x67,0x5f, 0x3,0x5e,0x6b, 0x4,0x64,0x69, + 0x4,0x67,0x61, 0x3,0x5e,0x6c, 0x4,0x67,0x63, 0x7,0x55,0x68, + 0x3,0x5e,0x69, 0x3,0x5e,0x6e, 0x3,0x5e,0x6f, 0x3,0x5f,0x6f, + 0x3,0x60,0x51, 0x5,0x71,0x55, 0x7,0x59,0x67, 0x3,0x5f,0x6d, + 0x7,0x59,0x68, 0x3,0x5f,0x70, 0x5,0x74,0x55, 0x4,0x6b,0x2a, + 0x5,0x76,0x5f, 0x4,0x6b,0x27, 0x3,0x60,0x4e, 0x3,0x60,0x50, + 0x3,0x61,0x23, 0x3,0x61,0x21, 0x4,0x6c,0x30, 0x3,0x61,0x24, + 0x3,0x61,0x6e, 0x6,0x3c,0x65, 0x4,0x3b,0x67, 0xf,0x3f,0x76, + 0x4,0x41,0x49, 0x4,0x5e,0x32, 0x3,0x39,0x5b, 0x4,0x35,0x7c, + 0x3,0x3f,0x6a, 0x4,0x3b,0x6b, 0x3,0x3f,0x6e, 0x3,0x3f,0x6b, + 0x3,0x45,0x3b, 0x4,0x41,0x50, 0x4,0x41,0x4e, 0x4,0x48,0x23, + 0x3,0x4a,0x3b, 0x3,0x4a,0x3f, 0x3,0x4a,0x3a, 0x5,0x4a,0x6e, + 0x3,0x4a,0x3c, 0x7,0x2a,0x46, 0x4,0x4e,0x48, 0x3,0x4f,0x54, + 0x3,0x4f,0x57, 0x4,0x54,0x4f, 0x4,0x54,0x4b, 0x3,0x53,0x3f, + 0x4,0x54,0x4c, 0x3,0x53,0x41, 0x3,0x53,0x43, 0x3,0x53,0x46, + 0x3,0x53,0x45, 0x7,0x34,0x73, 0x4,0x59,0x4e, 0x4,0x59,0x4f, + 0x4,0x59,0x54, 0x3,0x56,0x6e, 0x3,0x56,0x6c, 0x4,0x59,0x4d, + 0x4,0x59,0x52, 0x4,0x67,0x66, 0x4,0x64,0x71, 0x5,0x71,0x5b, + 0x4,0x69,0x55, 0x5,0x21,0x7d, 0x3,0x22,0x60, 0x3,0x24,0x3e, + 0x5,0x24,0x7b, 0x6,0x29,0x35, 0x4,0x28,0x31, 0x4,0x28,0x32, + 0x3,0x2a,0x7a, 0x5,0x2b,0x64, 0x4,0x2b,0x5a, 0x3,0x2f,0x41, + 0x4,0x2b,0x59, 0x4,0x30,0x40, 0x4,0x30,0x3d, 0x3,0x34,0x35, + 0x4,0x30,0x3e, 0x3,0x34,0x37, 0x4,0x30,0x3c, 0x3,0x39,0x63, + 0x3,0x39,0x5d, 0x4,0x35,0x7d, 0x3,0x39,0x60, 0x3,0x39,0x62, + 0x3,0x39,0x64, 0x3,0x39,0x5f, 0x3,0x3f,0x6f, 0x4,0x3b,0x6d, + 0x3,0x3f,0x74, 0x3,0x45,0x3f, 0x3,0x45,0x3e, 0x4,0x41,0x55, + 0x4,0x41,0x54, 0x3,0x45,0x3d, 0x3,0x45,0x41, 0x3,0x4a,0x41, + 0x3,0x4a,0x40, 0x3,0x4a,0x43, 0x3,0x4a,0x42, 0x3,0x4f,0x59, + 0x3,0x4f,0x58, 0x7,0x2a,0x54, 0x3,0x53,0x47, 0x4,0x54,0x53, + 0x4,0x54,0x51, 0x4,0x59,0x55, 0x3,0x5b,0x54, 0x4,0x64,0x73, + 0x4,0x67,0x67, 0x3,0x34,0x38, 0x4,0x36,0x24, 0x3,0x3f,0x7a, + 0x3,0x3f,0x76, 0x3,0x3f,0x79, 0x3,0x3f,0x77, 0x4,0x41,0x56, + 0x3,0x45,0x44, 0x3,0x45,0x43, 0x3,0x45,0x45, 0x3,0x4a,0x48, + 0x3,0x4f,0x5d, 0x3,0x4f,0x5c, 0x3,0x53,0x4b, 0x3,0x53,0x4a, + 0x3,0x52,0x38, 0x4,0x59,0x58, 0x3,0x56,0x72, 0x3,0x59,0x4c, + 0x3,0x5b,0x55, 0x3,0x5d,0x4a, 0x3,0x5b,0x56, 0x3,0x5d,0x4b, + 0x4,0x69,0x56, 0x3,0x61,0x51, 0x3,0x62,0x40, 0x3,0x39,0x66, + 0x3,0x3f,0x7d, 0x6,0x50,0x31, 0x3,0x45,0x48, 0x4,0x48,0x2d, + 0x4,0x48,0x31, 0x4,0x48,0x2e, 0x3,0x4a,0x4a, 0x4,0x48,0x34, + 0x3,0x4a,0x4b, 0x4,0x48,0x33, 0x6,0x63,0x7b, 0x3,0x4f,0x5e, + 0x3,0x4f,0x61, 0x3,0x4f,0x5f, 0x4,0x54,0x59, 0x3,0x53,0x4f, + 0x3,0x53,0x4e, 0x4,0x59,0x60, 0x3,0x56,0x73, 0x3,0x56,0x77, + 0x4,0x54,0x58, 0x3,0x56,0x76, 0x4,0x59,0x5d, 0x4,0x59,0x5f, + 0x4,0x5e,0x35, 0x3,0x59,0x4d, 0x3,0x59,0x4e, 0x4,0x5e,0x36, + 0x7,0x44,0x58, 0x7,0x44,0x60, 0x4,0x61,0x74, 0x4,0x61,0x73, + 0x3,0x5b,0x57, 0x3,0x5b,0x58, 0x3,0x5b,0x59, 0x4,0x64,0x75, + 0x3,0x5d,0x4d, 0x4,0x69,0x58, 0x4,0x69,0x5a, 0x4,0x69,0x5b, + 0x3,0x60,0x58, 0x3,0x61,0x53, 0x3,0x61,0x27, 0x3,0x61,0x52, + 0x3,0x62,0x24, 0x3,0x62,0x44, 0x3,0x62,0x46, 0x4,0x69,0x5c, + 0x4,0x36,0x28, 0x4,0x36,0x2a, 0x4,0x3b,0x74, 0x4,0x4e,0x4c, + 0x4,0x64,0x7b, 0x4,0x41,0x5a, 0x3,0x45,0x4a, 0x3,0x4a,0x4d, + 0x4,0x48,0x38, 0x4,0x48,0x37, 0x4,0x54,0x5d, 0x4,0x54,0x5c, + 0x4,0x59,0x62, 0x4,0x64,0x7c, 0x4,0x67,0x6e, 0x5,0x71,0x63, + 0x4,0x6c,0x33, 0x4,0x3b,0x79, 0x3,0x40,0x23, 0x4,0x3b,0x76, + 0x3,0x45,0x4d, 0x4,0x41,0x5d, 0x4,0x41,0x5f, 0x3,0x45,0x4c, + 0xf,0x46,0x32, 0x6,0x5a,0x28, 0x4,0x48,0x3a, 0x4,0x48,0x40, + 0x4,0x48,0x3b, 0x3,0x4a,0x4f, 0x3,0x4a,0x50, 0x4,0x48,0x3d, + 0x4,0x4e,0x4f, 0x4,0x54,0x63, 0x4,0x54,0x61, 0x4,0x54,0x60, + 0x4,0x54,0x64, 0x4,0x54,0x62, 0x4,0x59,0x63, 0x4,0x54,0x68, + 0x3,0x53,0x52, 0x3,0x56,0x7c, 0x4,0x59,0x68, 0x4,0x59,0x64, + 0x7,0x3d,0x56, 0x3,0x56,0x79, 0x3,0x56,0x7d, 0x3,0x56,0x7e, + 0x4,0x5e,0x3e, 0x5,0x65,0x7e, 0x4,0x5e,0x42, 0x4,0x5e,0x3c, + 0x5,0x65,0x73, 0x5,0x65,0x7b, 0x4,0x5e,0x3b, 0x4,0x5e,0x41, + 0x3,0x5b,0x5c, 0x3,0x5b,0x5b, 0x4,0x61,0x77, 0x4,0x61,0x7b, + 0x3,0x5b,0x5a, 0x4,0x65,0x23, 0x4,0x64,0x7e, 0x5,0x6e,0x49, + 0x7,0x56,0x27, 0x7,0x56,0x25, 0x4,0x67,0x72, 0x4,0x67,0x70, + 0x5,0x71,0x69, 0x7,0x56,0x26, 0x3,0x5f,0x74, 0x5,0x74,0x62, + 0x4,0x6b,0x2c, 0x3,0x60,0x5a, 0x4,0x6c,0x34, 0x4,0x6d,0x2d, + 0x3,0x61,0x54, 0x4,0x6d,0x65, 0x3,0x61,0x70, 0x4,0x6e,0x22, + 0x4,0x41,0x61, 0x4,0x48,0x43, 0x4,0x48,0x41, 0x4,0x48,0x42, + 0x4,0x48,0x44, 0x3,0x53,0x54, 0x4,0x59,0x6b, 0x7,0x44,0x77, + 0x4,0x5e,0x45, 0x3,0x59,0x52, 0x4,0x61,0x7d, 0x4,0x61,0x7e, + 0x4,0x67,0x73, 0x4,0x69,0x60, 0x3,0x60,0x5b, 0x3,0x45,0x4e, + 0x3,0x57,0x21, 0x3,0x5b,0x63, 0x3,0x5b,0x62, 0x3,0x5d,0x52, + 0x4,0x67,0x75, 0x4,0x6b,0x2d, 0x3,0x40,0x25, 0x3,0x40,0x26, + 0x3,0x40,0x27, 0x3,0x45,0x51, 0x4,0x54,0x6a, 0x4,0x54,0x69, + 0x3,0x59,0x53, 0x4,0x62,0x22, 0x4,0x62,0x23, 0x3,0x5f,0x75, + 0x4,0x3b,0x7b, 0xf,0x40,0x2d, 0x4,0x41,0x65, 0x4,0x41,0x64, + 0x5,0x44,0x34, 0x5,0x4b,0x3e, 0x4,0x48,0x4d, 0x3,0x4a,0x51, + 0x4,0x48,0x4e, 0x3,0x4a,0x53, 0x4,0x48,0x4c, 0x4,0x48,0x4b, + 0x5,0x4b,0x3f, 0x4,0x48,0x47, 0x3,0x4f,0x68, 0x4,0x4e,0x59, + 0x4,0x4e,0x5c, 0x5,0x52,0x60, 0x4,0x54,0x6d, 0x4,0x54,0x6f, + 0x3,0x53,0x56, 0x4,0x4e,0x5d, 0x3,0x53,0x60, 0x3,0x53,0x57, + 0x3,0x53,0x5e, 0x7,0x35,0x51, 0x3,0x57,0x25, 0x4,0x59,0x73, + 0x7,0x3d,0x69, 0x3,0x57,0x22, 0x4,0x59,0x77, 0x3,0x57,0x23, + 0x3,0x57,0x24, 0x3,0x57,0x27, 0x3,0x57,0x29, 0x4,0x5e,0x4e, + 0x3,0x59,0x54, 0x4,0x5e,0x49, 0x4,0x5e,0x47, 0x4,0x5e,0x4b, + 0x3,0x59,0x57, 0x3,0x59,0x55, 0x4,0x5e,0x4d, 0x4,0x5e,0x4c, + 0x3,0x59,0x5a, 0x4,0x62,0x27, 0x4,0x62,0x29, 0x4,0x62,0x2d, + 0x4,0x62,0x26, 0x4,0x62,0x2c, 0x3,0x5b,0x64, 0x4,0x62,0x25, + 0x4,0x62,0x2f, 0x4,0x62,0x28, 0x4,0x62,0x2b, 0x4,0x65,0x2f, + 0x4,0x65,0x31, 0x4,0x65,0x30, 0x3,0x5d,0x54, 0x4,0x67,0x77, + 0x4,0x67,0x79, 0x4,0x67,0x76, 0x4,0x67,0x7c, 0x4,0x67,0x7b, + 0x7,0x56,0x32, 0x4,0x69,0x63, 0x3,0x5f,0x76, 0x4,0x69,0x62, + 0x4,0x6c,0x39, 0x5,0x78,0x48, 0x3,0x61,0x55, 0x4,0x36,0x2b, + 0x4,0x3b,0x7e, 0x3,0x45,0x53, 0x4,0x41,0x6d, 0x4,0x41,0x72, + 0x4,0x41,0x6e, 0x4,0x48,0x51, 0x4,0x48,0x56, 0x4,0x48,0x59, + 0x4,0x48,0x50, 0x4,0x48,0x54, 0x3,0x4a,0x57, 0x4,0x4e,0x60, + 0x4,0x4e,0x61, 0x4,0x54,0x76, 0x4,0x54,0x77, 0x4,0x54,0x73, + 0x4,0x54,0x74, 0x4,0x54,0x75, 0x4,0x59,0x7d, 0x4,0x5a,0x22, + 0x4,0x5a,0x21, 0x4,0x59,0x7c, 0x4,0x59,0x7a, 0x4,0x59,0x7e, + 0x4,0x5e,0x51, 0x7,0x44,0x7e, 0x4,0x5e,0x50, 0x4,0x5e,0x52, + 0x3,0x59,0x5d, 0x3,0x59,0x5e, 0x3,0x59,0x5f, 0x4,0x62,0x32, + 0x3,0x5b,0x67, 0x3,0x5b,0x66, 0x4,0x65,0x36, 0x3,0x5d,0x55, + 0x4,0x67,0x7e, 0x4,0x6b,0x30, 0x4,0x6c,0x3a, 0x3,0x57,0x2b, + 0x3,0x59,0x60, 0x3,0x34,0x3a, 0x4,0x36,0x2c, 0x3,0x40,0x29, + 0x3,0x40,0x2a, 0x4,0x3c,0x24, 0x3,0x40,0x28, 0x4,0x3c,0x25, + 0x3,0x45,0x5d, 0x3,0x40,0x2c, 0x4,0x41,0x77, 0x4,0x41,0x74, + 0x3,0x4a,0x5c, 0x3,0x45,0x5e, 0x4,0x41,0x75, 0x3,0x45,0x56, + 0x3,0x45,0x55, 0x3,0x45,0x5a, 0x4,0x41,0x79, 0x4,0x41,0x7a, + 0x3,0x4a,0x58, 0x3,0x4a,0x59, 0x4,0x48,0x5b, 0x7,0x2b,0x38, + 0x3,0x4a,0x5a, 0x4,0x48,0x5c, 0x6,0x64,0x40, 0x3,0x4f,0x6a, + 0x4,0x4e,0x65, 0x4,0x4e,0x64, 0x4,0x4e,0x67, 0x4,0x4e,0x66, + 0x4,0x54,0x78, 0x4,0x4e,0x69, 0x4,0x54,0x7c, 0x4,0x54,0x7d, + 0x4,0x54,0x7a, 0x4,0x5a,0x27, 0x4,0x55,0x22, 0x4,0x5a,0x28, + 0x4,0x5a,0x2a, 0x5,0x60,0x31, 0x3,0x57,0x2d, 0x3,0x59,0x64, + 0x5,0x60,0x2c, 0x3,0x57,0x2c, 0x4,0x5e,0x58, 0x4,0x5e,0x57, + 0x4,0x5e,0x5b, 0x4,0x5e,0x59, 0x4,0x5e,0x5a, 0x4,0x65,0x39, + 0x4,0x62,0x36, 0x3,0x5b,0x68, 0x4,0x65,0x3c, 0x4,0x65,0x3b, + 0x3,0x5d,0x57, 0x3,0x5d,0x59, 0x4,0x68,0x24, 0x4,0x68,0x23, + 0x3,0x5e,0x7d, 0x4,0x68,0x22, 0x4,0x69,0x67, 0x4,0x69,0x65, + 0x3,0x5f,0x77, 0x4,0x69,0x68, 0x4,0x6b,0x31, 0x3,0x61,0x56, + 0x4,0x6d,0x30, 0x4,0x6d,0x67, 0x4,0x6e,0x25, 0x3,0x4f,0x6c, + 0x3,0x53,0x67, 0x4,0x5e,0x5f, 0x4,0x62,0x3c, 0x4,0x48,0x5d, + 0x3,0x57,0x2f, 0x4,0x55,0x26, 0x3,0x57,0x2e, 0x3,0x61,0x71, + 0x3,0x40,0x2d, 0x5,0x44,0x4a, 0x3,0x45,0x60, 0x4,0x48,0x5e, + 0x3,0x4a,0x65, 0x4,0x48,0x5f, 0x3,0x4a,0x5f, 0x3,0x4a,0x67, + 0x3,0x4a,0x68, 0x3,0x4a,0x6b, 0x3,0x4a,0x69, 0x4,0x4e,0x6f, + 0x3,0x4f,0x71, 0x3,0x4f,0x70, 0x4,0x4e,0x6e, 0x3,0x4f,0x6f, + 0x4,0x4e,0x6d, 0x4,0x4e,0x70, 0x3,0x53,0x6f, 0x3,0x53,0x6e, + 0x3,0x53,0x6d, 0x5,0x5a,0x2c, 0x3,0x53,0x69, 0x4,0x55,0x2d, + 0x5,0x5a,0x2e, 0x7,0x36,0x28, 0x4,0x5a,0x2e, 0x3,0x57,0x32, + 0x3,0x57,0x35, 0x4,0x5a,0x2d, 0x3,0x57,0x31, 0x4,0x5e,0x67, + 0x5,0x6a,0x6e, 0x4,0x5e,0x62, 0x3,0x59,0x68, 0x4,0x5e,0x68, + 0x3,0x59,0x69, 0x4,0x5e,0x63, 0x4,0x5e,0x65, 0x3,0x59,0x6c, + 0x4,0x62,0x41, 0x4,0x62,0x3f, 0x3,0x5b,0x6a, 0x4,0x62,0x46, + 0x4,0x62,0x40, 0x4,0x62,0x44, 0x4,0x62,0x45, 0x4,0x65,0x41, + 0x4,0x65,0x40, 0x3,0x5d,0x5d, 0x3,0x5d,0x5b, 0x4,0x65,0x47, + 0x5,0x6e,0x66, 0x5,0x6e,0x6d, 0x3,0x5d,0x5c, 0x4,0x68,0x29, + 0x4,0x68,0x2a, 0x4,0x68,0x2b, 0x4,0x68,0x2d, 0x3,0x5f,0x23, + 0x5,0x72,0x2d, 0x4,0x68,0x28, 0x7,0x5a,0x3e, 0x5,0x74,0x76, + 0x4,0x69,0x6b, 0x4,0x69,0x69, 0x3,0x5f,0x7a, 0x4,0x6b,0x33, + 0x4,0x6b,0x34, 0x4,0x6b,0x32, 0x3,0x61,0x2b, 0x7,0x60,0x2e, + 0x7,0x60,0x2d, 0x3,0x61,0x57, 0x4,0x6d,0x68, 0x3,0x62,0x27, + 0x4,0x6e,0x3f, 0x3,0x62,0x37, 0x4,0x6e,0x57, 0x3,0x39,0x69, + 0x3,0x40,0x2e, 0x4,0x48,0x62, 0x3,0x4a,0x6d, 0x3,0x4f,0x75, + 0x4,0x4e,0x75, 0x4,0x4e,0x73, 0x4,0x4e,0x76, 0x3,0x4f,0x78, + 0x3,0x53,0x72, 0x3,0x53,0x73, 0x4,0x55,0x30, 0x4,0x55,0x32, + 0x4,0x55,0x2f, 0x4,0x55,0x2e, 0x3,0x57,0x39, 0x4,0x5a,0x31, + 0x4,0x5a,0x35, 0x4,0x5a,0x30, 0x3,0x57,0x38, 0x4,0x5a,0x33, + 0x5,0x66,0x51, 0x4,0x5e,0x6e, 0x3,0x5b,0x70, 0x4,0x62,0x48, + 0x4,0x62,0x47, 0x4,0x65,0x49, 0x3,0x5d,0x5f, 0x4,0x68,0x30, + 0x4,0x69,0x6e, 0x4,0x6b,0x35, 0x4,0x6c,0x3e, 0x4,0x6d,0x33, + 0x3,0x40,0x30, 0x4,0x42,0x22, 0x4,0x62,0x4a, 0x5,0x74,0x7a, + 0x7,0x64,0x75, 0x3,0x40,0x31, 0x5,0x3d,0x52, 0x6,0x64,0x5e, + 0x4,0x48,0x6a, 0x4,0x48,0x69, 0x4,0x48,0x67, 0x3,0x4a,0x74, + 0x5,0x4b,0x59, 0x4,0x4e,0x7b, 0x3,0x4f,0x7a, 0x4,0x55,0x35, + 0x4,0x55,0x36, 0x4,0x5a,0x38, 0x3,0x57,0x3d, 0x4,0x5a,0x3b, + 0x4,0x5e,0x70, 0x4,0x5e,0x73, 0x3,0x59,0x6e, 0x4,0x5e,0x74, + 0x4,0x5e,0x76, 0x4,0x5e,0x75, 0x4,0x5e,0x77, 0x4,0x62,0x4e, + 0x3,0x5b,0x72, 0x4,0x62,0x4c, 0x4,0x65,0x4d, 0x4,0x65,0x4f, + 0x4,0x65,0x4e, 0x7,0x51,0x79, 0x5,0x72,0x3f, 0x3,0x5f,0x26, + 0x4,0x69,0x72, 0x4,0x6c,0x43, 0x4,0x6c,0x41, 0x3,0x61,0x2d, + 0x5,0x78,0x52, 0x4,0x6d,0x35, 0x7,0x61,0x6a, 0x4,0x6d,0x69, + 0x4,0x6e,0x49, 0x7,0x51,0x7d, 0x5,0x72,0x41, 0x3,0x4a,0x77, + 0x3,0x4a,0x76, 0x3,0x4d,0x3e, 0x3,0x53,0x76, 0x7,0x5a,0x4b, + 0x3,0x61,0x58, 0x3,0x4a,0x79, 0x4,0x4f,0x24, 0x4,0x4f,0x25, + 0x4,0x55,0x3f, 0x3,0x53,0x77, 0x4,0x5e,0x7e, 0x3,0x59,0x70, + 0x4,0x5e,0x7d, 0x4,0x5e,0x7c, 0x3,0x5b,0x73, 0x5,0x66,0x68, + 0x3,0x5d,0x65, 0x4,0x69,0x77, 0x4,0x69,0x76, 0x7,0x5a,0x4f, + 0x4,0x6c,0x48, 0x4,0x6c,0x49, 0x4,0x6e,0x58, 0x5,0x3d,0x54, + 0x4,0x48,0x6d, 0x5,0x4b,0x64, 0x4,0x4f,0x28, 0x4,0x4f,0x34, + 0x3,0x50,0x21, 0x7,0x2b,0x6a, 0x4,0x4f,0x39, 0x4,0x4f,0x32, + 0x4,0x4f,0x2b, 0x4,0x4f,0x29, 0x3,0x54,0x27, 0x4,0x55,0x44, + 0x4,0x55,0x42, 0x4,0x55,0x48, 0x3,0x53,0x7e, 0x3,0x54,0x28, + 0x4,0x55,0x41, 0x3,0x54,0x26, 0x3,0x54,0x24, 0x3,0x54,0x22, + 0x3,0x53,0x7b, 0x4,0x5a,0x40, 0x3,0x57,0x41, 0x4,0x5f,0x21, + 0x7,0x3e,0x49, 0x4,0x5a,0x42, 0x3,0x59,0x72, 0x4,0x5f,0x23, + 0x5,0x66,0x6e, 0x4,0x5f,0x27, 0x4,0x5f,0x25, 0x3,0x59,0x78, + 0x4,0x5f,0x24, 0x3,0x59,0x77, 0x4,0x5f,0x29, 0x4,0x5f,0x2b, + 0x4,0x62,0x5d, 0x5,0x6b,0x35, 0x4,0x62,0x67, 0x4,0x62,0x57, + 0x4,0x62,0x61, 0x4,0x62,0x59, 0x4,0x62,0x54, 0x3,0x5b,0x76, + 0x5,0x6b,0x31, 0x4,0x62,0x62, 0x5,0x6b,0x2b, 0x4,0x62,0x60, + 0x4,0x62,0x64, 0x3,0x5b,0x78, 0x3,0x5b,0x7b, 0x3,0x5b,0x7c, + 0xf,0x64,0x72, 0x3,0x5d,0x77, 0x4,0x65,0x55, 0x7,0x52,0x31, + 0x4,0x65,0x5b, 0x3,0x5d,0x6c, 0x7,0x52,0x33, 0x4,0x65,0x53, + 0x3,0x5d,0x6b, 0x3,0x5d,0x6d, 0x4,0x68,0x3d, 0x3,0x5f,0x2d, + 0x3,0x5f,0x30, 0x4,0x68,0x3c, 0x3,0x5f,0x2e, 0x3,0x5f,0x2b, + 0x4,0x68,0x3a, 0x3,0x5f,0x29, 0x3,0x5f,0x2f, 0x4,0x69,0x7d, + 0x3,0x5f,0x7d, 0x4,0x6a,0x21, 0x4,0x69,0x7c, 0x3,0x5f,0x7c, + 0x4,0x69,0x7e, 0x3,0x60,0x24, 0x4,0x69,0x7b, 0x3,0x60,0x21, + 0xf,0x6a,0x3f, 0x4,0x6b,0x3c, 0x4,0x6b,0x3d, 0x4,0x6b,0x40, + 0x4,0x6b,0x3b, 0x7,0x5e,0x23, 0x3,0x60,0x67, 0x3,0x60,0x64, + 0x5,0x78,0x5b, 0x5,0x78,0x56, 0x3,0x61,0x30, 0x4,0x6c,0x4d, + 0x4,0x6c,0x4e, 0x5,0x77,0x24, 0x3,0x61,0x5a, 0x4,0x6d,0x39, + 0x3,0x61,0x31, 0x4,0x6e,0x2c, 0x4,0x6e,0x2d, 0x4,0x6e,0x5b, + 0x3,0x45,0x65, 0x3,0x4a,0x7a, 0x3,0x4a,0x7b, 0x3,0x4a,0x7c, + 0x3,0x4a,0x7e, 0x5,0x4b,0x6b, 0x3,0x4a,0x7d, 0x5,0x53,0x38, + 0x4,0x4f,0x3f, 0x3,0x50,0x23, 0x4,0x4f,0x44, 0x4,0x4f,0x3b, + 0x7,0x2b,0x6d, 0x4,0x4f,0x40, 0x3,0x50,0x28, 0x3,0x50,0x29, + 0x3,0x50,0x26, 0x3,0x4c,0x63, 0x4,0x4f,0x41, 0x4,0x55,0x4e, + 0x3,0x54,0x2f, 0x4,0x55,0x4d, 0x3,0x54,0x30, 0x4,0x55,0x4f, + 0x3,0x54,0x2b, 0x4,0x55,0x54, 0x7,0x36,0x4a, 0x4,0x55,0x4a, + 0x3,0x54,0x2e, 0x4,0x55,0x57, 0x3,0x57,0x4b, 0x4,0x55,0x4b, + 0x3,0x54,0x31, 0x4,0x55,0x55, 0x3,0x54,0x34, 0x4,0x55,0x50, + 0x7,0x36,0x51, 0x3,0x56,0x33, 0x3,0x57,0x4c, 0x4,0x5a,0x51, + 0x3,0x57,0x47, 0x3,0x57,0x49, 0x3,0x57,0x46, 0x4,0x5a,0x52, + 0x3,0x57,0x4e, 0x4,0x5a,0x50, 0x4,0x5f,0x2f, 0x4,0x5f,0x35, + 0x4,0x5f,0x2c, 0x3,0x5a,0x21, 0x3,0x59,0x7c, 0x4,0x5f,0x32, + 0x4,0x5f,0x31, 0x5,0x67,0x26, 0x4,0x5f,0x38, 0x4,0x62,0x6a, + 0x3,0x5c,0x21, 0x4,0x62,0x6c, 0x4,0x65,0x61, 0x3,0x5c,0x28, + 0x4,0x62,0x6f, 0x5,0x6b,0x3c, 0x4,0x5f,0x36, 0xf,0x64,0x75, + 0x3,0x5d,0x78, 0x4,0x65,0x6c, 0x3,0x5d,0x7d, 0x3,0x5d,0x7b, + 0x4,0x65,0x6a, 0x4,0x65,0x64, 0x3,0x5d,0x7c, 0x7,0x52,0x42, + 0x4,0x65,0x62, 0x4,0x65,0x6b, 0x3,0x5d,0x7e, 0x3,0x5f,0x34, + 0x4,0x68,0x40, 0x4,0x68,0x42, 0x4,0x68,0x41, 0x5,0x72,0x63, + 0x3,0x5f,0x33, 0x4,0x6a,0x27, 0x4,0x6a,0x2c, 0x3,0x60,0x28, + 0x4,0x6a,0x26, 0x3,0x60,0x26, 0x3,0x60,0x27, 0x4,0x6b,0x45, + 0x3,0x60,0x6b, 0x5,0x77,0x2c, 0x4,0x6b,0x44, 0x5,0x77,0x34, + 0x4,0x6b,0x47, 0x3,0x60,0x6a, 0x3,0x60,0x69, 0x4,0x6b,0x48, + 0x4,0x6c,0x50, 0x4,0x6c,0x52, 0x4,0x6c,0x51, 0x3,0x61,0x36, + 0x4,0x6c,0x54, 0x4,0x6d,0x3d, 0x3,0x61,0x5c, 0x7,0x63,0x37, + 0x3,0x62,0x2a, 0x3,0x62,0x3e, 0x4,0x6e,0x59, 0x3,0x62,0x43, + 0x4,0x4f,0x47, 0x4,0x5f,0x39, 0x7,0x57,0x29, 0x4,0x6b,0x4d, + 0x5,0x79,0x73, 0x5,0x4b,0x6d, 0x4,0x4f,0x49, 0x4,0x4f,0x4a, + 0x3,0x50,0x2d, 0x3,0x54,0x38, 0x4,0x55,0x58, 0x7,0x36,0x5c, + 0x3,0x5a,0x23, 0x4,0x62,0x72, 0x3,0x5f,0x39, 0x3,0x61,0x37, + 0x3,0x61,0x38, 0x4,0x48,0x73, 0x4,0x48,0x74, 0x3,0x4b,0x21, + 0x4,0x4f,0x4d, 0x4,0x4f,0x4b, 0x4,0x55,0x59, 0x4,0x55,0x5c, + 0x4,0x55,0x5a, 0x4,0x55,0x5d, 0x3,0x57,0x4f, 0x4,0x5f,0x3c, + 0x4,0x5f,0x3b, 0x3,0x5a,0x27, 0x4,0x62,0x79, 0x4,0x62,0x76, + 0x4,0x62,0x7d, 0x4,0x62,0x77, 0x4,0x62,0x7c, 0x4,0x68,0x49, + 0x4,0x68,0x48, 0x4,0x68,0x4a, 0x5,0x75,0x4d, 0x5,0x75,0x48, + 0x4,0x6b,0x4e, 0x3,0x61,0x39, 0x7,0x5a,0x7d, 0x4,0x6d,0x41, + 0x7,0x2c,0x31, 0x4,0x65,0x71, 0x4,0x65,0x72, 0x7,0x36,0x65, + 0x4,0x5f,0x3d, 0x4,0x63,0x21, 0x4,0x65,0x76, 0x4,0x68,0x4b, + 0x4,0x6b,0x52, 0x4,0x6c,0x5a, 0x7,0x2c,0x33, 0x4,0x55,0x5e, + 0x7,0x36,0x67, 0x5,0x6f,0x52, 0x4,0x65,0x79, 0x5,0x6f,0x54, + 0x4,0x68,0x4c, 0x4,0x68,0x4e, 0x4,0x68,0x4d, 0x4,0x6a,0x31, + 0x4,0x6b,0x55, 0x4,0x6d,0x42, 0x4,0x42,0x2c, 0x3,0x4b,0x23, + 0x4,0x4f,0x52, 0x4,0x4f,0x53, 0x4,0x55,0x5f, 0x4,0x5a,0x5f, + 0x5,0x61,0x23, 0x5,0x67,0x40, 0x5,0x67,0x3d, 0x4,0x5f,0x3f, + 0x5,0x67,0x41, 0x4,0x63,0x23, 0x3,0x5c,0x2b, 0x4,0x65,0x7c, + 0x4,0x66,0x21, 0x4,0x65,0x7d, 0x5,0x6f,0x58, 0x4,0x68,0x52, + 0x3,0x5f,0x3b, 0x4,0x6b,0x56, 0x4,0x6c,0x5b, 0x4,0x6d,0x44, + 0x3,0x61,0x5e, 0x4,0x6d,0x43, 0x4,0x6d,0x6f, 0x4,0x5f,0x40, + 0x3,0x5c,0x2c, 0x4,0x6a,0x37, 0x3,0x61,0x3a, 0x4,0x55,0x61, + 0x4,0x6c,0x61, 0x4,0x6c,0x62, 0x4,0x5f,0x43, 0x4,0x5f,0x42, + 0x4,0x5f,0x44, 0x4,0x63,0x26, 0x4,0x68,0x59, 0x4,0x55,0x62, + 0x4,0x5a,0x63, 0x4,0x5f,0x45, 0x4,0x63,0x27, 0x4,0x68,0x5a, + 0x3,0x60,0x2a, 0x4,0x6b,0x58, 0x4,0x6b,0x5b, 0x3,0x5a,0x2c, + 0x4,0x5f,0x46, 0x3,0x5e,0x23, 0x7,0x52,0x67, 0x5,0x6f,0x61, + 0x4,0x68,0x5c, 0x4,0x6e,0x31, 0x5,0x7b,0x7a, 0x4,0x5a,0x66, + 0x5,0x61,0x2d, 0x4,0x5f,0x48, 0x4,0x63,0x29, 0x4,0x63,0x2b, + 0x4,0x66,0x27, 0x4,0x66,0x25, 0x4,0x66,0x26, 0x3,0x5f,0x3d, + 0x4,0x68,0x61, 0x4,0x6a,0x3d, 0x4,0x6a,0x3c, 0x3,0x60,0x6e, + 0x5,0x77,0x4d, 0x4,0x6c,0x69, 0x4,0x6c,0x66, 0x4,0x6c,0x6a, + 0x4,0x6d,0x4c, 0x4,0x6d,0x4b, 0x4,0x6d,0x70, 0x3,0x61,0x76, + 0x3,0x62,0x2b, 0x3,0x62,0x32, 0x4,0x6e,0x4b, 0x4,0x6e,0x4c, + 0x4,0x6e,0x5a, 0x5,0x75,0x61, 0x5,0x6b,0x69, 0x5,0x6c,0x44, + 0x4,0x68,0x62, 0x4,0x68,0x63, 0x4,0x6d,0x51, 0x3,0x62,0x2c, + 0x1,0x44,0x21, 0x1,0x44,0x23, 0x4,0x21,0x26, 0x1,0x44,0x24, + 0x3,0x21,0x26, 0x3,0x21,0x25, 0x2,0x21,0x26, 0x1,0x44,0x37, + 0x1,0x44,0x35, 0x1,0x44,0x38, 0x1,0x44,0x36, 0x2,0x21,0x27, + 0x1,0x44,0x62, 0x2,0x21,0x2f, 0x2,0x21,0x2d, 0x1,0x44,0x61, + 0x1,0x44,0x60, 0x4,0x21,0x39, 0x1,0x45,0x62, 0x1,0x45,0x61, + 0x1,0x45,0x60, 0x4,0x21,0x55, 0x1,0x45,0x63, 0x1,0x45,0x5f, + 0x1,0x47,0x22, 0x1,0x47,0x23, 0x3,0x22,0x62, 0x3,0x22,0x61, + 0x3,0x22,0x63, 0x4,0x23,0x35, 0x3,0x24,0x3f, 0x1,0x4b,0x64, + 0x3,0x21,0x21, 0x4,0x21,0x27, 0x3,0x21,0x2c, 0x1,0x44,0x39, + 0x1,0x44,0x63, 0x2,0x21,0x30, 0x4,0x21,0x3a, 0x1,0x44,0x64, + 0x2,0x21,0x43, 0x1,0x48,0x6b, 0x2,0x25,0x31, 0x4,0x2b,0x5e, + 0x3,0x21,0x22, 0x1,0x44,0x3a, 0x1,0x44,0x65, 0x1,0x45,0x64, + 0x2,0x21,0x44, 0x3,0x27,0x40, 0x3,0x21,0x23, 0x4,0x21,0x22, + 0x4,0x21,0x23, 0x2,0x21,0x21, 0x1,0x44,0x25, 0x1,0x44,0x3c, + 0x3,0x21,0x30, 0x2,0x21,0x28, 0x1,0x44,0x3d, 0x3,0x21,0x2e, + 0x1,0x44,0x66, 0x1,0x45,0x65, 0x1,0x45,0x67, 0x1,0x45,0x66, + 0x4,0x22,0x27, 0x1,0x47,0x24, 0x1,0x47,0x25, 0x3,0x23,0x45, + 0x1,0x4b,0x65, 0x3,0x2b,0x22, 0x1,0x53,0x7d, 0x1,0x44,0x22, + 0x4,0x21,0x24, 0x2,0x21,0x22, 0x1,0x44,0x26, 0x1,0x44,0x3f, + 0x1,0x44,0x3e, 0x3,0x21,0x46, 0x3,0x21,0x45, 0x3,0x22,0x64, + 0x1,0x47,0x26, 0x4,0x22,0x28, 0x3,0x24,0x40, 0x1,0x4b,0x66, + 0x4,0x25,0x31, 0x4,0x25,0x30, 0x3,0x2b,0x23, 0x1,0x58,0x71, + 0x2,0x33,0x4e, 0x3,0x39,0x6c, 0x3,0x39,0x6e, 0x1,0x63,0x2a, + 0x2,0x41,0x56, 0x2,0x41,0x57, 0x3,0x21,0x24, 0x1,0x44,0x27, + 0x3,0x21,0x2d, 0x1,0x44,0x68, 0x3,0x22,0x65, 0x1,0x4b,0x67, + 0x1,0x44,0x28, 0x2,0x21,0x29, 0x1,0x44,0x40, 0x3,0x21,0x31, + 0x1,0x44,0x69, 0x1,0x44,0x6b, 0x2,0x21,0x31, 0x1,0x44,0x6c, + 0x1,0x44,0x6a, 0x4,0x21,0x3b, 0x3,0x21,0x6c, 0x3,0x22,0x66, + 0x1,0x47,0x27, 0x1,0x4b,0x68, 0x3,0x24,0x42, 0x3,0x27,0x42, + 0x1,0x4b,0x69, 0x1,0x4f,0x67, 0x1,0x27,0x28, 0x1,0x44,0x41, + 0x1,0x44,0x6d, 0x3,0x21,0x47, 0x1,0x47,0x28, 0x1,0x47,0x2a, + 0x1,0x47,0x29, 0x1,0x48,0x6c, 0x1,0x4b,0x6a, 0x1,0x4b,0x6b, + 0x1,0x4f,0x68, 0x1,0x4f,0x69, 0x3,0x2b,0x26, 0x3,0x2b,0x25, + 0x3,0x2b,0x27, 0x3,0x2b,0x24, 0x1,0x53,0x7e, 0x4,0x36,0x2e, + 0x2,0x41,0x58, 0x3,0x40,0x33, 0x2,0x6d,0x44, 0x1,0x44,0x29, + 0x3,0x21,0x32, 0x3,0x21,0x33, 0x1,0x44,0x6f, 0x1,0x44,0x6e, + 0x2,0x21,0x32, 0x1,0x44,0x70, 0x1,0x44,0x76, 0x3,0x21,0x49, + 0x1,0x44,0x71, 0x1,0x44,0x72, 0x2,0x21,0x34, 0x2,0x21,0x33, + 0x1,0x44,0x74, 0x1,0x44,0x75, 0x3,0x21,0x4c, 0x1,0x44,0x73, + 0x3,0x21,0x4b, 0x3,0x21,0x4a, 0x4,0x21,0x3c, 0x1,0x45,0x6a, + 0x1,0x45,0x6b, 0x1,0x45,0x6c, 0x1,0x45,0x6d, 0x1,0x45,0x69, + 0x1,0x45,0x70, 0x2,0x21,0x4a, 0x4,0x21,0x5b, 0x2,0x21,0x46, + 0x2,0x21,0x49, 0x1,0x45,0x71, 0x1,0x46,0x23, 0x3,0x21,0x6d, + 0x2,0x21,0x48, 0x4,0x21,0x5a, 0x1,0x45,0x6e, 0x1,0x45,0x6f, + 0x1,0x45,0x68, 0x3,0x21,0x72, 0x3,0x21,0x70, 0x2,0x21,0x45, + 0x2,0x21,0x47, 0x3,0x22,0x6f, 0x3,0x22,0x68, 0x1,0x47,0x37, + 0x2,0x21,0x6f, 0x1,0x47,0x34, 0x1,0x47,0x38, 0x2,0x21,0x79, + 0x2,0x21,0x6d, 0x1,0x47,0x35, 0x2,0x21,0x71, 0x3,0x22,0x6b, + 0x3,0x22,0x67, 0x3,0x22,0x76, 0x1,0x47,0x36, 0x3,0x22,0x6e, + 0x1,0x47,0x39, 0x4,0x22,0x2d, 0x1,0x47,0x2b, 0x2,0x21,0x70, + 0x1,0x47,0x3a, 0x2,0x21,0x74, 0x3,0x22,0x6d, 0x2,0x21,0x78, + 0x2,0x21,0x75, 0x3,0x22,0x6c, 0x3,0x22,0x74, 0x2,0x21,0x72, + 0x1,0x47,0x2c, 0x1,0x47,0x2e, 0x1,0x47,0x3b, 0x4,0x22,0x2a, + 0x1,0x47,0x30, 0x2,0x21,0x6a, 0x1,0x47,0x33, 0x1,0x47,0x31, + 0x1,0x47,0x32, 0x2,0x21,0x7a, 0x2,0x21,0x77, 0x2,0x21,0x6e, + 0x1,0x47,0x2f, 0x3,0x22,0x70, 0x3,0x22,0x77, 0x2,0x21,0x6b, + 0x1,0x47,0x2d, 0x3,0x22,0x75, 0x4,0x22,0x2e, 0x3,0x22,0x73, + 0x2,0x21,0x73, 0x2,0x21,0x76, 0x3,0x22,0x72, 0xf,0x21,0x71, + 0x2,0x21,0x6c, 0x2,0x23,0x28, 0x4,0x23,0x39, 0x1,0x49,0x24, + 0x1,0x48,0x75, 0x3,0x24,0x50, 0x3,0x24,0x48, 0x2,0x23,0x29, + 0x1,0x48,0x72, 0x3,0x24,0x4f, 0x1,0x49,0x26, 0x3,0x24,0x46, + 0x1,0x48,0x7a, 0x3,0x24,0x45, 0x1,0x48,0x79, 0x2,0x22,0x7b, + 0x1,0x48,0x7d, 0x1,0x48,0x78, 0x2,0x23,0x22, 0x2,0x23,0x2a, + 0x3,0x24,0x4e, 0x2,0x23,0x26, 0x3,0x24,0x49, 0x1,0x48,0x7b, + 0x3,0x24,0x4b, 0x3,0x24,0x43, 0x1,0x48,0x7e, 0x1,0x48,0x6f, + 0x1,0x49,0x29, 0x2,0x22,0x7d, 0x3,0x24,0x44, 0x3,0x24,0x4c, + 0x2,0x25,0x3d, 0x1,0x48,0x6d, 0x1,0x49,0x25, 0x1,0x48,0x6e, + 0x1,0x48,0x76, 0x1,0x48,0x77, 0x2,0x23,0x24, 0x2,0x22,0x7e, + 0x1,0x48,0x7c, 0x1,0x48,0x74, 0x2,0x22,0x7a, 0x1,0x48,0x70, + 0x2,0x23,0x27, 0x1,0x49,0x27, 0x1,0x49,0x2a, 0x1,0x48,0x73, + 0x1,0x49,0x22, 0x1,0x49,0x28, 0x1,0x48,0x71, 0x2,0x23,0x25, + 0x1,0x49,0x23, 0x2,0x23,0x2b, 0x2,0x22,0x7c, 0x1,0x49,0x21, + 0x2,0x23,0x21, 0x3,0x64,0x48, 0x2,0x23,0x23, 0x3,0x64,0x49, + 0x1,0x4b,0x79, 0x2,0x25,0x3f, 0x2,0x25,0x4b, 0x1,0x4b,0x71, + 0x3,0x27,0x47, 0x2,0x25,0x4c, 0x1,0x4b,0x6c, 0x1,0x4b,0x76, + 0x4,0x25,0x3e, 0x3,0x27,0x4f, 0x1,0x4b,0x6f, 0x2,0x25,0x39, + 0x1,0x4b,0x77, 0x2,0x25,0x38, 0x2,0x25,0x3c, 0x2,0x25,0x43, + 0x2,0x25,0x41, 0x1,0x4c,0x21, 0x1,0x4b,0x7a, 0x2,0x25,0x33, + 0x2,0x25,0x35, 0x1,0x4b,0x7c, 0x1,0x4b,0x70, 0x2,0x25,0x36, + 0x2,0x25,0x42, 0x2,0x25,0x49, 0x1,0x4b,0x75, 0x2,0x25,0x3b, + 0x2,0x25,0x34, 0x1,0x4b,0x74, 0x2,0x25,0x37, 0x1,0x4b,0x78, + 0x2,0x25,0x3a, 0x3,0x27,0x44, 0x1,0x4b,0x73, 0x3,0x27,0x51, + 0x1,0x4b,0x6e, 0x3,0x27,0x48, 0x1,0x4b,0x7d, 0x2,0x25,0x44, + 0x1,0x4b,0x7e, 0x2,0x25,0x48, 0x3,0x27,0x43, 0x2,0x25,0x46, + 0x2,0x25,0x4a, 0x1,0x4b,0x7b, 0x2,0x25,0x3e, 0x2,0x25,0x32, + 0x4,0x25,0x36, 0x2,0x25,0x40, 0x1,0x4b,0x72, 0x2,0x25,0x45, + 0x1,0x4b,0x6d, 0x2,0x25,0x47, 0x3,0x27,0x4c, 0x3,0x27,0x49, + 0x3,0x27,0x4b, 0x3,0x27,0x4a, 0x3,0x27,0x4d, 0xf,0x25,0x44, + 0x1,0x4f,0x78, 0x1,0x4f,0x6c, 0x3,0x2b,0x2d, 0x3,0x2b,0x2e, + 0x2,0x29,0x22, 0x2,0x29,0x2a, 0x3,0x2b,0x36, 0x1,0x4f,0x6b, + 0x1,0x4f,0x73, 0x1,0x50,0x21, 0x3,0x2b,0x2c, 0x2,0x29,0x30, + 0x2,0x29,0x2e, 0x2,0x29,0x29, 0x4,0x28,0x38, 0x4,0x28,0x3e, + 0x3,0x2b,0x2b, 0x1,0x4f,0x6d, 0x2,0x29,0x2f, 0x2,0x29,0x25, + 0x1,0x4f,0x7b, 0x1,0x4f,0x72, 0x1,0x4f,0x7a, 0x2,0x28,0x7e, + 0x3,0x2b,0x32, 0x2,0x29,0x2c, 0x3,0x2b,0x2f, 0x2,0x29,0x23, + 0x1,0x4f,0x76, 0x2,0x29,0x24, 0x3,0x2b,0x33, 0x2,0x28,0x7d, + 0x1,0x4f,0x7d, 0x1,0x4f,0x70, 0x1,0x4f,0x79, 0x1,0x4f,0x6f, + 0x3,0x2b,0x28, 0x2,0x29,0x21, 0x2,0x29,0x26, 0x3,0x2b,0x29, + 0x2,0x29,0x2d, 0x1,0x4f,0x77, 0x1,0x4f,0x74, 0x2,0x29,0x28, + 0x1,0x4f,0x7c, 0x2,0x29,0x2b, 0x2,0x29,0x27, 0x1,0x4f,0x71, + 0x1,0x4f,0x7e, 0x1,0x4f,0x75, 0x1,0x4f,0x6e, 0x1,0x4f,0x6a, + 0x4,0x28,0x3f, 0x3,0x2b,0x35, 0xf,0x29,0x2d, 0x3,0x2b,0x34, + 0x3,0x64,0x4a, 0x4,0x28,0x3d, 0x2,0x29,0x31, 0x1,0x54,0x3a, + 0x1,0x54,0x24, 0x3,0x2f,0x48, 0x1,0x54,0x34, 0x3,0x2f,0x4d, + 0x1,0x54,0x39, 0x2,0x2d,0x71, 0x2,0x2d,0x70, 0x2,0x2d,0x75, + 0x2,0x2d,0x76, 0x1,0x54,0x27, 0x3,0x2f,0x44, 0x1,0x54,0x30, + 0x3,0x2f,0x58, 0x3,0x2f,0x4c, 0x3,0x2f,0x56, 0x1,0x54,0x3d, + 0x3,0x2f,0x46, 0x1,0x54,0x31, 0x4,0x2b,0x62, 0x3,0x2f,0x4b, + 0x3,0x2f,0x49, 0x3,0x2f,0x47, 0x2,0x2d,0x6a, 0x1,0x54,0x2a, + 0x2,0x2d,0x6b, 0x3,0x2f,0x4f, 0x1,0x54,0x3f, 0x4,0x2b,0x64, + 0x1,0x54,0x36, 0x1,0x54,0x21, 0x1,0x54,0x22, 0x2,0x2d,0x7e, + 0x1,0x59,0x24, 0x3,0x2f,0x53, 0x1,0x54,0x2f, 0x1,0x54,0x2e, + 0x2,0x2d,0x6c, 0x1,0x54,0x32, 0x2,0x33,0x5e, 0x1,0x54,0x29, + 0x2,0x2d,0x77, 0x1,0x54,0x38, 0x1,0x54,0x37, 0x1,0x54,0x2d, + 0x2,0x2d,0x6f, 0x2,0x2d,0x78, 0x3,0x2f,0x45, 0x2,0x2d,0x69, + 0x1,0x54,0x2c, 0x2,0x2d,0x79, 0x1,0x54,0x35, 0x2,0x2d,0x6d, + 0x1,0x54,0x23, 0x3,0x2f,0x4e, 0x1,0x54,0x26, 0x1,0x54,0x25, + 0x2,0x2d,0x7a, 0x1,0x54,0x33, 0x1,0x54,0x28, 0x1,0x54,0x3c, + 0x1,0x54,0x3e, 0x2,0x2d,0x74, 0x1,0x54,0x3b, 0x3,0x2f,0x51, + 0x2,0x2d,0x7c, 0x2,0x2d,0x6e, 0x2,0x2d,0x7d, 0x3,0x2f,0x43, + 0x2,0x2d,0x72, 0x4,0x2b,0x61, 0x2,0x2d,0x7b, 0x3,0x2f,0x50, + 0x2,0x2d,0x73, 0x3,0x2f,0x54, 0x3,0x2f,0x55, 0x1,0x54,0x2b, + 0x3,0x64,0x4b, 0x2,0x33,0x66, 0x2,0x33,0x5a, 0x3,0x34,0x3c, + 0x1,0x58,0x76, 0x3,0x34,0x3f, 0x2,0x33,0x5f, 0x2,0x33,0x65, + 0x1,0x58,0x75, 0x2,0x33,0x58, 0x1,0x58,0x79, 0x2,0x33,0x5c, + 0x2,0x33,0x55, 0x1,0x58,0x77, 0x2,0x33,0x59, 0x1,0x58,0x7c, + 0x1,0x59,0x23, 0x3,0x34,0x44, 0x2,0x33,0x6a, 0x3,0x34,0x41, + 0x2,0x33,0x54, 0x3,0x34,0x42, 0x1,0x58,0x7d, 0x3,0x2f,0x57, + 0x2,0x33,0x69, 0x3,0x34,0x47, 0x3,0x34,0x3d, 0x1,0x58,0x78, + 0x2,0x33,0x5b, 0x1,0x58,0x74, 0x2,0x33,0x56, 0x2,0x33,0x52, + 0x2,0x33,0x60, 0x2,0x33,0x53, 0x2,0x33,0x51, 0x2,0x33,0x5d, + 0x2,0x33,0x63, 0x2,0x33,0x64, 0x1,0x58,0x7a, 0x3,0x34,0x40, + 0x4,0x30,0x47, 0x2,0x3a,0x3f, 0x2,0x33,0x61, 0x2,0x33,0x50, + 0x2,0x33,0x62, 0x3,0x34,0x4b, 0x1,0x59,0x26, 0x2,0x33,0x67, + 0x1,0x59,0x25, 0x2,0x33,0x4f, 0x3,0x34,0x43, 0x2,0x33,0x57, + 0x2,0x33,0x68, 0x1,0x59,0x21, 0x1,0x58,0x7e, 0x1,0x58,0x7b, + 0x1,0x59,0x22, 0x3,0x34,0x4c, 0x3,0x34,0x4a, 0x1,0x58,0x72, + 0x3,0x34,0x45, 0x3,0x34,0x46, 0x1,0x58,0x73, 0x1,0x5e,0x2e, + 0x3,0x39,0x75, 0x2,0x3a,0x42, 0x2,0x3a,0x3b, 0x4,0x36,0x34, + 0x1,0x5e,0x2b, 0x4,0x36,0x33, 0x2,0x3a,0x43, 0x3,0x39,0x71, + 0x3,0x39,0x72, 0x4,0x36,0x36, 0x2,0x3a,0x39, 0x2,0x3a,0x3c, + 0x1,0x5e,0x2a, 0x2,0x3a,0x3d, 0x3,0x39,0x6f, 0x4,0x36,0x31, + 0x1,0x5e,0x2d, 0x2,0x3a,0x41, 0x4,0x36,0x3c, 0x2,0x3a,0x37, + 0x2,0x3a,0x36, 0x1,0x5e,0x2f, 0x3,0x39,0x70, 0x1,0x5e,0x30, + 0x1,0x5e,0x2c, 0x1,0x5e,0x31, 0x2,0x3a,0x35, 0x2,0x3a,0x40, + 0x2,0x3a,0x3e, 0x2,0x3a,0x38, 0x4,0x36,0x39, 0x4,0x36,0x30, + 0x4,0x36,0x3a, 0x1,0x5e,0x29, 0x2,0x3a,0x3a, 0x3,0x64,0x4d, + 0x3,0x40,0x39, 0x3,0x40,0x3c, 0x1,0x63,0x31, 0x1,0x63,0x2b, + 0x2,0x41,0x5c, 0x1,0x63,0x34, 0x2,0x41,0x62, 0x2,0x41,0x65, + 0x1,0x63,0x2d, 0x1,0x63,0x2e, 0x2,0x41,0x5f, 0x1,0x63,0x2c, + 0x2,0x41,0x68, 0x1,0x63,0x32, 0x2,0x41,0x69, 0x3,0x40,0x3a, + 0x2,0x41,0x64, 0x1,0x63,0x33, 0x3,0x40,0x37, 0x2,0x41,0x59, + 0x1,0x63,0x30, 0x2,0x41,0x5a, 0x4,0x3c,0x29, 0x2,0x41,0x63, + 0x2,0x41,0x61, 0x3,0x40,0x3d, 0x2,0x41,0x5d, 0x1,0x63,0x2f, + 0x2,0x41,0x5b, 0x1,0x63,0x35, 0x2,0x41,0x60, 0x2,0x41,0x67, + 0x2,0x41,0x5e, 0x2,0x41,0x66, 0x3,0x40,0x36, 0x3,0x40,0x3e, + 0x1,0x67,0x7c, 0x1,0x67,0x79, 0x3,0x45,0x6b, 0x1,0x67,0x7a, + 0x4,0x42,0x2d, 0x2,0x49,0x21, 0x2,0x48,0x77, 0x1,0x67,0x78, + 0x1,0x67,0x75, 0x2,0x48,0x78, 0x3,0x45,0x6e, 0x3,0x45,0x6c, + 0x1,0x67,0x77, 0x2,0x48,0x7b, 0x3,0x45,0x6d, 0x2,0x48,0x7d, + 0x3,0x45,0x76, 0x4,0x42,0x35, 0x2,0x49,0x26, 0x3,0x45,0x70, + 0x3,0x45,0x75, 0x2,0x49,0x25, 0x2,0x48,0x7e, 0x1,0x67,0x74, + 0x2,0x48,0x76, 0x1,0x67,0x72, 0x2,0x48,0x79, 0x1,0x67,0x7d, + 0x2,0x48,0x7c, 0x3,0x45,0x71, 0x2,0x49,0x22, 0x1,0x67,0x76, + 0x1,0x67,0x73, 0x2,0x49,0x24, 0x2,0x49,0x23, 0x1,0x67,0x7b, + 0x2,0x48,0x7a, 0x3,0x45,0x74, 0x1,0x6c,0x23, 0x2,0x4f,0x54, + 0x3,0x4b,0x29, 0x2,0x4f,0x51, 0x1,0x6c,0x24, 0x4,0x48,0x79, + 0x1,0x6c,0x22, 0x3,0x4b,0x2b, 0x2,0x4f,0x58, 0x2,0x4f,0x55, + 0x2,0x4f,0x4e, 0x1,0x6c,0x21, 0x3,0x4b,0x2d, 0x1,0x6c,0x25, + 0x2,0x4f,0x4f, 0x1,0x6b,0x7e, 0x1,0x6c,0x28, 0x2,0x4f,0x52, + 0x2,0x4f,0x53, 0x1,0x6c,0x26, 0x1,0x6c,0x27, 0x2,0x4f,0x59, + 0x2,0x4f,0x56, 0x2,0x4f,0x57, 0x3,0x4b,0x2c, 0x3,0x4b,0x27, + 0x3,0x64,0x4e, 0x1,0x70,0x33, 0x2,0x56,0x43, 0x1,0x70,0x30, + 0x2,0x56,0x40, 0x1,0x70,0x32, 0x1,0x70,0x34, 0x3,0x50,0x31, + 0x2,0x56,0x41, 0x1,0x70,0x31, 0x4,0x4f,0x5a, 0x2,0x56,0x42, + 0x3,0x50,0x35, 0x2,0x56,0x3f, 0x3,0x50,0x30, 0x3,0x50,0x34, + 0x1,0x73,0x41, 0x2,0x5c,0x49, 0x1,0x73,0x42, 0x2,0x5c,0x47, + 0x4,0x55,0x65, 0x2,0x5c,0x48, 0x2,0x5c,0x46, 0x2,0x5c,0x45, + 0x3,0x54,0x41, 0x3,0x54,0x40, 0x2,0x5c,0x4a, 0x1,0x73,0x40, + 0x3,0x50,0x33, 0x4,0x55,0x69, 0x2,0x61,0x44, 0x2,0x61,0x45, + 0x3,0x57,0x52, 0x2,0x4f,0x50, 0x2,0x61,0x43, 0x1,0x73,0x43, + 0x1,0x78,0x2b, 0x2,0x65,0x37, 0x2,0x65,0x38, 0x3,0x5c,0x32, + 0x1,0x7a,0x62, 0x1,0x7a,0x63, 0x2,0x6b,0x4f, 0x2,0x6b,0x4e, + 0x1,0x7b,0x58, 0x1,0x7b,0x57, 0x2,0x6e,0x7d, 0x3,0x60,0x6f, + 0x1,0x44,0x2a, 0x1,0x44,0x42, 0x1,0x44,0x78, 0x4,0x21,0x3d, + 0x1,0x44,0x77, 0x1,0x45,0x73, 0x1,0x45,0x72, 0x1,0x47,0x3e, + 0x1,0x47,0x3d, 0x1,0x47,0x3f, 0x1,0x47,0x3c, 0x3,0x22,0x78, + 0x1,0x49,0x2c, 0x1,0x49,0x2b, 0x1,0x49,0x2d, 0x3,0x24,0x54, + 0x4,0x23,0x3b, 0x3,0x24,0x53, 0x3,0x24,0x51, 0x1,0x4c,0x23, + 0x4,0x25,0x3f, 0x1,0x4c,0x22, 0x1,0x4c,0x24, 0x3,0x27,0x52, + 0x1,0x50,0x22, 0x4,0x28,0x40, 0x1,0x22,0x79, 0x2,0x2e,0x21, + 0x1,0x22,0x7a, 0x1,0x59,0x27, 0x1,0x22,0x7c, 0x1,0x22,0x7b, + 0x2,0x3a,0x44, 0x3,0x39,0x76, 0x1,0x22,0x7d, 0x1,0x67,0x7e, + 0x1,0x22,0x7e, 0x3,0x5e,0x25, 0x1,0x44,0x2b, 0x3,0x21,0x34, + 0x1,0x44,0x79, 0x1,0x47,0x40, 0x1,0x4c,0x25, 0x3,0x2b,0x37, + 0x1,0x44,0x2c, 0x1,0x44,0x7c, 0x1,0x44,0x7a, 0x1,0x44,0x7b, + 0x1,0x47,0x41, 0x3,0x22,0x7a, 0x4,0x22,0x34, 0x1,0x49,0x2e, + 0x1,0x4c,0x27, 0x1,0x4c,0x26, 0x1,0x4c,0x28, 0x3,0x2e,0x7b, + 0x1,0x54,0x40, 0x3,0x40,0x3f, 0x3,0x64,0x53, 0x1,0x70,0x35, + 0x3,0x21,0x27, 0x4,0x21,0x3e, 0x3,0x21,0x4d, 0x3,0x21,0x48, + 0x3,0x21,0x4e, 0x2,0x21,0x2e, 0x4,0x21,0x52, 0x1,0x45,0x74, + 0x1,0x45,0x75, 0x3,0x21,0x78, 0x3,0x21,0x79, 0x1,0x47,0x42, + 0x4,0x22,0x36, 0x2,0x23,0x2c, 0x3,0x27,0x55, 0x1,0x50,0x24, + 0x1,0x50,0x23, 0x2,0x2e,0x23, 0x2,0x2e,0x22, 0x1,0x59,0x28, + 0x3,0x21,0x28, 0x1,0x44,0x7d, 0x2,0x21,0x35, 0x3,0x21,0x7a, + 0x3,0x24,0x57, 0x2,0x25,0x4d, 0x3,0x2b,0x39, 0x1,0x50,0x25, + 0x3,0x2f,0x5b, 0x1,0x54,0x43, 0x3,0x2f,0x59, 0x1,0x54,0x41, + 0x1,0x54,0x42, 0x3,0x2f,0x5a, 0x3,0x34,0x4d, 0xf,0x46,0x5c, + 0x1,0x70,0x36, 0x1,0x27,0x2f, 0x1,0x45,0x76, 0x4,0x21,0x5e, + 0x1,0x47,0x43, 0x2,0x21,0x7b, 0x3,0x22,0x7e, 0x3,0x22,0x7d, + 0x3,0x22,0x7c, 0x3,0x24,0x59, 0x1,0x49,0x2f, 0x1,0x49,0x30, + 0x3,0x24,0x5a, 0x2,0x23,0x2d, 0x4,0x23,0x3d, 0x2,0x25,0x4e, + 0x1,0x4c,0x29, 0x2,0x25,0x4f, 0x4,0x25,0x40, 0x4,0x25,0x43, + 0x3,0x2b,0x3b, 0x3,0x2b,0x3d, 0x3,0x2b,0x3e, 0x2,0x2e,0x25, + 0x2,0x2e,0x26, 0x1,0x54,0x46, 0x3,0x2f,0x5e, 0x2,0x2e,0x27, + 0x3,0x2f,0x5f, 0x2,0x2e,0x24, 0x1,0x54,0x47, 0x1,0x54,0x45, + 0x1,0x54,0x44, 0x2,0x2e,0x28, 0x3,0x34,0x4f, 0x2,0x33,0x6b, + 0x3,0x34,0x4e, 0x3,0x39,0x7d, 0x3,0x39,0x7a, 0x2,0x3a,0x45, + 0x4,0x36,0x3f, 0x3,0x39,0x7e, 0x2,0x41,0x6a, 0x2,0x49,0x27, + 0x3,0x4b,0x2f, 0x3,0x4b,0x2e, 0x3,0x4b,0x30, 0x1,0x6c,0x29, + 0x1,0x70,0x37, 0x2,0x56,0x44, 0x3,0x54,0x42, 0x1,0x44,0x2d, + 0x1,0x44,0x3b, 0x3,0x21,0x2f, 0x3,0x21,0x35, 0x3,0x21,0x51, + 0x3,0x21,0x7b, 0x3,0x23,0x22, 0xf,0x22,0x59, 0x3,0x24,0x5b, + 0x3,0x27,0x59, 0x4,0x25,0x45, 0x1,0x59,0x29, 0x1,0x5e,0x33, + 0x6,0x46,0x65, 0x1,0x68,0x21, 0x3,0x45,0x7a, 0x2,0x21,0x23, + 0x1,0x44,0x7e, 0x4,0x21,0x60, 0x1,0x45,0x79, 0x1,0x45,0x77, + 0x1,0x45,0x78, 0x1,0x4c,0x2a, 0x3,0x27,0x5a, 0x1,0x44,0x2e, + 0x1,0x44,0x2f, 0x4,0x21,0x2a, 0x1,0x44,0x43, 0x3,0x21,0x36, + 0x3,0x21,0x52, 0x1,0x45,0x21, 0x1,0x45,0x22, 0x1,0x45,0x23, + 0x2,0x21,0x4c, 0x1,0x45,0x7a, 0x3,0x21,0x7d, 0x2,0x21,0x4b, + 0x1,0x47,0x47, 0x3,0x23,0x25, 0x2,0x21,0x7d, 0x1,0x47,0x45, + 0x1,0x47,0x46, 0x2,0x21,0x7c, 0x3,0x23,0x24, 0x3,0x23,0x26, + 0x1,0x47,0x48, 0x1,0x47,0x44, 0x3,0x23,0x27, 0x2,0x23,0x2e, + 0x1,0x4f,0x4f, 0x2,0x23,0x2f, 0x3,0x24,0x5f, 0x3,0x24,0x61, + 0x2,0x23,0x30, 0x4,0x23,0x40, 0x3,0x24,0x5c, 0x1,0x49,0x32, + 0x1,0x49,0x31, 0x3,0x24,0x5e, 0x3,0x24,0x5d, 0x1,0x49,0x35, + 0x1,0x49,0x33, 0x1,0x49,0x34, 0x3,0x24,0x60, 0x1,0x4c,0x30, + 0x3,0x27,0x5b, 0x1,0x4c,0x2f, 0x2,0x25,0x54, 0x2,0x25,0x51, + 0x2,0x25,0x52, 0x3,0x27,0x5e, 0x2,0x25,0x50, 0x1,0x4c,0x31, + 0x1,0x4c,0x2d, 0x1,0x4c,0x2c, 0x3,0x27,0x5f, 0x1,0x4c,0x2e, + 0x1,0x4c,0x2b, 0x3,0x27,0x5d, 0x4,0x25,0x4e, 0x3,0x64,0x4f, + 0x1,0x4c,0x32, 0x1,0x50,0x27, 0x2,0x29,0x32, 0x3,0x2b,0x3f, + 0x2,0x25,0x53, 0x1,0x50,0x2c, 0x3,0x2b,0x40, 0x2,0x29,0x33, + 0x1,0x50,0x28, 0x1,0x50,0x2b, 0x1,0x50,0x2a, 0x1,0x50,0x29, + 0x1,0x50,0x26, 0x3,0x2b,0x43, 0x2,0x2e,0x2b, 0x3,0x2f,0x68, + 0x1,0x54,0x4a, 0x2,0x2e,0x2e, 0x1,0x54,0x48, 0x3,0x2f,0x65, + 0x4,0x2b,0x6e, 0x3,0x2f,0x62, 0x2,0x2e,0x2a, 0x1,0x54,0x4b, + 0x1,0x54,0x49, 0x1,0x54,0x4c, 0x2,0x2e,0x2c, 0x2,0x2e,0x2d, + 0x3,0x2f,0x60, 0x2,0x2e,0x29, 0x2,0x2e,0x2f, 0x3,0x2f,0x66, + 0x3,0x2f,0x61, 0x3,0x2f,0x63, 0xf,0x2e,0x2d, 0x3,0x2f,0x64, + 0x3,0x34,0x50, 0x1,0x5e,0x37, 0x1,0x59,0x2a, 0x2,0x33,0x6c, + 0x2,0x33,0x6e, 0x2,0x33,0x6d, 0x2,0x33,0x6f, 0x1,0x59,0x2b, + 0x3,0x3a,0x23, 0x1,0x5e,0x34, 0x3,0x3a,0x21, 0x1,0x5e,0x35, + 0x1,0x5e,0x36, 0x3,0x34,0x51, 0x1,0x63,0x37, 0x2,0x41,0x6c, + 0x3,0x40,0x41, 0x2,0x41,0x6b, 0x2,0x41,0x6d, 0x2,0x41,0x6e, + 0x1,0x63,0x38, 0x3,0x40,0x40, 0x1,0x63,0x36, 0x2,0x49,0x28, + 0x2,0x49,0x29, 0x1,0x68,0x23, 0x1,0x68,0x22, 0x2,0x4c,0x61, + 0x4,0x49,0x25, 0x3,0x4b,0x31, 0x1,0x6c,0x2a, 0x1,0x6c,0x2b, + 0x1,0x6c,0x2c, 0x1,0x6c,0x2e, 0x2,0x4f,0x5a, 0x2,0x4f,0x5b, + 0x1,0x6c,0x2d, 0x3,0x4b,0x32, 0x3,0x50,0x36, 0x1,0x70,0x38, + 0x4,0x4f,0x64, 0x1,0x70,0x39, 0x3,0x50,0x37, 0x4,0x55,0x6d, + 0x2,0x65,0x39, 0x2,0x6b,0x51, 0x2,0x6b,0x50, 0x2,0x6e,0x7e, + 0x3,0x60,0x2c, 0x1,0x44,0x30, 0x3,0x21,0x37, 0x3,0x21,0x54, + 0x3,0x21,0x53, 0x1,0x45,0x7c, 0x1,0x45,0x7b, 0x1,0x47,0x49, + 0x4,0x22,0x42, 0x4,0x22,0x3f, 0x2,0x21,0x7e, 0x4,0x22,0x41, + 0x3,0x23,0x28, 0x1,0x49,0x37, 0x1,0x49,0x38, 0x1,0x49,0x36, + 0x1,0x49,0x39, 0x2,0x23,0x31, 0x2,0x23,0x32, 0x4,0x23,0x46, + 0x4,0x23,0x47, 0x4,0x23,0x48, 0x3,0x24,0x63, 0x3,0x24,0x62, + 0x3,0x27,0x61, 0x5,0x25,0x3a, 0x5,0x25,0x37, 0x5,0x25,0x38, + 0x3,0x27,0x60, 0x5,0x25,0x3b, 0x1,0x4c,0x34, 0x2,0x25,0x55, + 0x4,0x25,0x50, 0x1,0x4c,0x33, 0x3,0x27,0x62, 0x2,0x29,0x34, + 0x1,0x50,0x30, 0x2,0x29,0x35, 0x1,0x50,0x2f, 0x3,0x2b,0x48, + 0x3,0x2b,0x46, 0x4,0x28,0x49, 0x1,0x50,0x2d, 0x4,0x28,0x4b, + 0x1,0x50,0x2e, 0x3,0x2b,0x47, 0x3,0x2f,0x6f, 0x2,0x2e,0x30, + 0x3,0x2f,0x6c, 0x3,0x2f,0x6a, 0x3,0x2f,0x6d, 0x3,0x2f,0x6e, + 0x1,0x59,0x2c, 0x2,0x33,0x71, 0x3,0x34,0x52, 0x1,0x59,0x2f, + 0x2,0x33,0x70, 0x1,0x5b,0x2b, 0x1,0x59,0x2e, 0x1,0x59,0x2d, + 0x1,0x5e,0x3a, 0x5,0x36,0x6a, 0x1,0x5e,0x39, 0x1,0x5e,0x38, + 0x1,0x63,0x39, 0x3,0x40,0x45, 0x3,0x40,0x44, 0x1,0x63,0x3c, + 0x1,0x63,0x3d, 0x1,0x63,0x3b, 0x4,0x3c,0x3c, 0x1,0x63,0x3a, + 0x3,0x40,0x46, 0x5,0x44,0x67, 0x2,0x49,0x2a, 0x3,0x46,0x21, + 0x2,0x49,0x2b, 0x5,0x44,0x63, 0x3,0x45,0x7e, 0x3,0x4b,0x33, + 0x2,0x4f,0x5d, 0x1,0x6c,0x2f, 0x2,0x4f,0x5c, 0x3,0x4d,0x2c, + 0x1,0x70,0x3a, 0x2,0x5c,0x4b, 0x1,0x73,0x44, 0x5,0x53,0x62, + 0x2,0x65,0x3a, 0x1,0x79,0x61, 0x1,0x27,0x34, 0x1,0x44,0x44, + 0x1,0x45,0x24, 0x2,0x21,0x36, 0x3,0x21,0x55, 0x1,0x45,0x25, + 0x1,0x45,0x26, 0x3,0x21,0x56, 0xf,0x21,0x30, 0x3,0x22,0x23, + 0x3,0x22,0x22, 0x1,0x45,0x7d, 0x1,0x45,0x7e, 0x3,0x22,0x24, + 0x1,0x47,0x4a, 0x2,0x23,0x33, 0x2,0x25,0x56, 0x2,0x25,0x57, + 0x4,0x25,0x51, 0x1,0x50,0x31, 0x2,0x2e,0x31, 0x1,0x59,0x31, + 0x1,0x59,0x30, 0x2,0x3a,0x47, 0x2,0x3a,0x46, 0x6,0x50,0x74, + 0x3,0x50,0x38, 0x1,0x44,0x31, 0x1,0x45,0x27, 0x1,0x46,0x21, + 0x4,0x30,0x5e, 0x1,0x59,0x32, 0x2,0x21,0x24, 0x4,0x21,0x65, + 0x2,0x21,0x4d, 0x1,0x46,0x22, 0x3,0x22,0x26, 0x2,0x22,0x22, + 0x1,0x47,0x4c, 0x1,0x47,0x4b, 0x2,0x22,0x21, 0x1,0x49,0x3a, + 0x3,0x64,0x50, 0x3,0x24,0x65, 0x3,0x2b,0x49, 0x4,0x28,0x4e, + 0x4,0x28,0x50, 0x1,0x54,0x4d, 0x4,0x2b,0x78, 0x4,0x30,0x5f, + 0x2,0x33,0x72, 0x1,0x63,0x3e, 0x2,0x49,0x2c, 0x1,0x68,0x24, + 0x3,0x46,0x23, 0x3,0x4b,0x34, 0x2,0x56,0x45, 0x3,0x54,0x44, + 0x3,0x5c,0x34, 0x2,0x68,0x6a, 0x3,0x21,0x29, 0x1,0x45,0x28, + 0x3,0x21,0x57, 0x3,0x24,0x66, 0x2,0x25,0x58, 0x2,0x29,0x36, + 0x1,0x59,0x35, 0x1,0x59,0x33, 0x1,0x59,0x34, 0x1,0x44,0x32, + 0x4,0x21,0x30, 0x1,0x44,0x45, 0x1,0x24,0x3f, 0x1,0x45,0x2b, + 0x3,0x21,0x59, 0x1,0x45,0x2a, 0x1,0x45,0x29, 0x1,0x46,0x25, + 0x1,0x46,0x24, 0x3,0x23,0x2a, 0x2,0x21,0x4e, 0x2,0x22,0x23, + 0xf,0x22,0x2c, 0x3,0x23,0x2b, 0x3,0x23,0x2d, 0x1,0x4c,0x38, + 0x1,0x4c,0x35, 0x1,0x4c,0x37, 0x1,0x4c,0x36, 0x3,0x27,0x63, + 0x1,0x50,0x32, 0x3,0x2b,0x4a, 0x4,0x30,0x60, 0x1,0x5e,0x3b, + 0x4,0x66,0x30, 0x1,0x44,0x33, 0x3,0x21,0x5a, 0x1,0x45,0x2c, + 0x3,0x22,0x27, 0x1,0x46,0x27, 0x1,0x46,0x26, 0x2,0x23,0x34, + 0x4,0x23,0x4d, 0x3,0x64,0x51, 0x1,0x4c,0x39, 0x3,0x2a,0x5c, + 0x4,0x30,0x64, 0x3,0x21,0x2a, 0x4,0x21,0x31, 0x2,0x21,0x37, + 0x3,0x22,0x28, 0x1,0x46,0x29, 0x1,0x46,0x28, 0x1,0x47,0x4d, + 0x1,0x47,0x4e, 0x2,0x23,0x35, 0x1,0x49,0x3b, 0x3,0x24,0x67, + 0x1,0x49,0x3c, 0x3,0x27,0x65, 0x1,0x4c,0x3a, 0x1,0x4c,0x3b, + 0x1,0x4c,0x3c, 0x3,0x27,0x66, 0x1,0x50,0x33, 0x2,0x29,0x37, + 0x3,0x2b,0x4b, 0x4,0x30,0x65, 0x1,0x54,0x4e, 0x3,0x40,0x47, + 0x2,0x21,0x25, 0x4,0x21,0x44, 0x1,0x45,0x2d, 0x3,0x21,0x5b, + 0x4,0x21,0x67, 0x4,0x21,0x66, 0x3,0x22,0x29, 0x2,0x22,0x24, + 0x3,0x23,0x2f, 0x2,0x23,0x36, 0x2,0x23,0x37, 0x2,0x25,0x59, + 0x3,0x27,0x67, 0x2,0x25,0x5a, 0x2,0x29,0x39, 0x2,0x29,0x38, + 0x2,0x29,0x3b, 0x2,0x29,0x3a, 0x1,0x50,0x34, 0x3,0x64,0x52, + 0x2,0x33,0x73, 0x1,0x54,0x50, 0x2,0x2e,0x32, 0x1,0x54,0x4f, + 0x3,0x34,0x54, 0x4,0x30,0x68, 0x2,0x3a,0x48, 0x1,0x5e,0x3c, + 0x3,0x3a,0x28, 0x2,0x3a,0x49, 0x3,0x3a,0x27, 0x3,0x40,0x4a, + 0x3,0x40,0x49, 0x3,0x40,0x48, 0x2,0x49,0x2d, 0x1,0x68,0x25, + 0x3,0x46,0x25, 0x4,0x3c,0x40, 0x3,0x46,0x26, 0x3,0x4b,0x35, + 0x1,0x6c,0x30, 0x3,0x54,0x45, 0x2,0x65,0x3b, 0xf,0x6d,0x2e, + 0x3,0x21,0x2b, 0x3,0x21,0x5c, 0x4,0x21,0x45, 0x2,0x21,0x38, + 0x3,0x22,0x2a, 0x1,0x46,0x2a, 0x4,0x22,0x48, 0x3,0x23,0x31, + 0x4,0x25,0x59, 0x3,0x27,0x69, 0x3,0x27,0x6a, 0x1,0x59,0x36, + 0x3,0x34,0x55, 0x3,0x3a,0x29, 0x1,0x44,0x34, 0x1,0x44,0x46, + 0x1,0x45,0x2f, 0x1,0x45,0x2e, 0x3,0x21,0x5e, 0x1,0x45,0x30, + 0x3,0x21,0x60, 0x4,0x21,0x69, 0x3,0x22,0x2b, 0x3,0x23,0x33, + 0x4,0x23,0x4f, 0x1,0x4c,0x3e, 0x3,0x27,0x6b, 0x1,0x4c,0x3d, + 0x1,0x4c,0x3f, 0x3,0x2b,0x50, 0x3,0x2b,0x4f, 0x1,0x50,0x35, + 0x3,0x2b,0x4e, 0x3,0x2b,0x4d, 0x6,0x35,0x78, 0x1,0x54,0x51, + 0x3,0x40,0x4b, 0x2,0x56,0x46, 0x1,0x76,0x3b, 0x1,0x44,0x47, + 0x1,0x46,0x2c, 0x1,0x46,0x3b, 0x1,0x46,0x36, 0x4,0x21,0x6c, + 0x1,0x46,0x31, 0x1,0x46,0x30, 0x1,0x46,0x37, 0x1,0x46,0x35, + 0x1,0x46,0x2e, 0x1,0x46,0x3c, 0x1,0x46,0x2f, 0x1,0x46,0x2b, + 0x1,0x46,0x3a, 0x1,0x46,0x39, 0x1,0x46,0x38, 0x1,0x46,0x2d, + 0x3,0x22,0x31, 0x1,0x46,0x34, 0x3,0x22,0x2d, 0x3,0x22,0x2e, + 0x1,0x46,0x33, 0x3,0x22,0x2f, 0xf,0x21,0x50, 0x1,0x46,0x3d, + 0x1,0x46,0x32, 0x4,0x21,0x6a, 0x3,0x23,0x35, 0x3,0x23,0x37, + 0x1,0x47,0x54, 0x4,0x22,0x4c, 0x1,0x47,0x5a, 0x1,0x47,0x56, + 0x3,0x23,0x39, 0x1,0x47,0x5c, 0x2,0x22,0x25, 0x1,0x47,0x59, + 0x1,0x47,0x4f, 0x1,0x47,0x52, 0x1,0x47,0x55, 0x1,0x47,0x51, + 0x1,0x47,0x58, 0x1,0x47,0x5b, 0x1,0x47,0x50, 0x1,0x47,0x53, + 0x1,0x47,0x57, 0x1,0x47,0x5d, 0x3,0x23,0x3a, 0x3,0x23,0x3b, + 0x3,0x23,0x34, 0x2,0x23,0x40, 0x2,0x23,0x3d, 0x3,0x24,0x76, + 0x1,0x49,0x49, 0x2,0x23,0x3e, 0x1,0x49,0x3d, 0x1,0x49,0x3f, + 0x1,0x49,0x57, 0x1,0x49,0x52, 0x3,0x24,0x79, 0x3,0x24,0x7e, + 0x3,0x24,0x75, 0x2,0x23,0x45, 0x2,0x23,0x3f, 0x1,0x49,0x41, + 0x1,0x49,0x43, 0x2,0x23,0x44, 0x1,0x49,0x4a, 0x2,0x23,0x3a, + 0x1,0x49,0x56, 0x1,0x49,0x58, 0x1,0x49,0x3e, 0x1,0x49,0x4f, + 0x3,0x25,0x24, 0x2,0x23,0x38, 0x1,0x49,0x55, 0x3,0x24,0x77, + 0x1,0x49,0x46, 0x3,0x24,0x7b, 0x1,0x49,0x50, 0x1,0x49,0x51, + 0x2,0x23,0x39, 0x1,0x49,0x4e, 0x1,0x49,0x4c, 0x3,0x24,0x70, + 0x1,0x49,0x4d, 0x1,0x49,0x53, 0x2,0x23,0x41, 0x1,0x49,0x40, + 0x3,0x25,0x21, 0x1,0x49,0x54, 0x2,0x23,0x43, 0x1,0x49,0x48, + 0x1,0x49,0x45, 0x3,0x24,0x73, 0x2,0x23,0x3c, 0x1,0x49,0x44, + 0x2,0x23,0x46, 0x1,0x49,0x47, 0x3,0x24,0x7c, 0x1,0x49,0x4b, + 0x3,0x24,0x78, 0x3,0x24,0x74, 0x3,0x24,0x6d, 0x1,0x49,0x42, + 0x2,0x23,0x42, 0x3,0x24,0x7d, 0x3,0x25,0x22, 0x2,0x23,0x3b, + 0x3,0x25,0x23, 0x4,0x25,0x64, 0x4,0x25,0x63, 0x3,0x27,0x6e, + 0x2,0x25,0x6b, 0x2,0x25,0x6a, 0x1,0x4c,0x51, 0x2,0x25,0x6d, + 0x2,0x25,0x6f, 0x2,0x25,0x64, 0x2,0x25,0x67, 0x2,0x25,0x6e, + 0x1,0x4c,0x52, 0x3,0x27,0x74, 0x3,0x27,0x78, 0x2,0x25,0x61, + 0x2,0x25,0x65, 0x3,0x27,0x75, 0x4,0x25,0x5f, 0x2,0x25,0x69, + 0x2,0x29,0x4a, 0x1,0x4c,0x4d, 0x2,0x29,0x4e, 0x1,0x4c,0x40, + 0x2,0x25,0x66, 0x1,0x4c,0x41, 0x1,0x4c,0x4e, 0x1,0x4c,0x47, + 0x1,0x4c,0x43, 0x3,0x27,0x71, 0x2,0x25,0x62, 0x1,0x4c,0x46, + 0x1,0x4c,0x4b, 0x1,0x4c,0x54, 0x2,0x25,0x63, 0x2,0x25,0x5c, + 0x1,0x4c,0x45, 0x2,0x25,0x5d, 0x2,0x25,0x5f, 0x4,0x25,0x60, + 0x1,0x4c,0x48, 0x3,0x27,0x6c, 0x1,0x4c,0x4a, 0x2,0x25,0x5b, + 0x2,0x25,0x60, 0x3,0x27,0x70, 0x3,0x27,0x79, 0x1,0x4c,0x53, + 0x1,0x4c,0x4f, 0x2,0x25,0x68, 0x1,0x4c,0x55, 0x3,0x27,0x73, + 0x1,0x4c,0x4c, 0x2,0x25,0x5e, 0x1,0x4c,0x49, 0x3,0x27,0x6f, + 0x3,0x27,0x77, 0x1,0x4c,0x44, 0x1,0x4c,0x42, 0x2,0x25,0x6c, + 0x1,0x4c,0x50, 0xf,0x25,0x71, 0x3,0x2b,0x5c, 0x3,0x2b,0x5d, + 0x2,0x29,0x49, 0x2,0x29,0x3d, 0x2,0x29,0x4c, 0x3,0x2b,0x57, + 0x3,0x2b,0x59, 0x2,0x29,0x3f, 0x1,0x50,0x3c, 0x1,0x50,0x4a, + 0x1,0x50,0x38, 0x1,0x50,0x49, 0x1,0x50,0x41, 0x1,0x50,0x46, + 0x1,0x50,0x36, 0x2,0x29,0x3e, 0x2,0x29,0x44, 0x1,0x50,0x45, + 0x2,0x29,0x50, 0x1,0x50,0x47, 0x3,0x2b,0x5b, 0x1,0x50,0x3d, + 0x3,0x2b,0x54, 0x3,0x2b,0x5e, 0x2,0x29,0x46, 0x2,0x29,0x43, + 0x1,0x50,0x3b, 0x3,0x2b,0x51, 0x2,0x29,0x3c, 0x1,0x50,0x48, + 0x2,0x29,0x4b, 0x1,0x50,0x40, 0x2,0x29,0x4d, 0x1,0x50,0x4b, + 0x1,0x50,0x37, 0x1,0x50,0x42, 0x1,0x50,0x3f, 0x2,0x29,0x41, + 0x1,0x50,0x43, 0x2,0x29,0x47, 0x2,0x29,0x48, 0x1,0x50,0x3e, + 0x1,0x50,0x44, 0x1,0x50,0x3a, 0x3,0x2b,0x55, 0x3,0x64,0x54, + 0x3,0x2b,0x63, 0x3,0x2b,0x61, 0x1,0x50,0x39, 0x2,0x29,0x40, + 0x3,0x2b,0x53, 0x2,0x29,0x45, 0x3,0x2b,0x58, 0x2,0x29,0x4f, + 0x2,0x2e,0x46, 0x1,0x54,0x5e, 0x2,0x2e,0x34, 0x4,0x2c,0x2d, + 0x2,0x2e,0x39, 0x1,0x54,0x57, 0x1,0x54,0x62, 0x2,0x2e,0x37, + 0x1,0x54,0x52, 0x1,0x54,0x5c, 0x1,0x54,0x61, 0x2,0x2e,0x3e, + 0x4,0x2c,0x26, 0x1,0x54,0x5d, 0x1,0x54,0x60, 0x3,0x2f,0x77, + 0x3,0x30,0x21, 0x2,0x2e,0x41, 0x1,0x54,0x58, 0x2,0x2e,0x38, + 0x3,0x2f,0x74, 0x3,0x2f,0x78, 0x3,0x30,0x22, 0x2,0x2e,0x44, + 0x2,0x2e,0x45, 0x3,0x2f,0x79, 0x1,0x54,0x5a, 0x2,0x2e,0x43, + 0x1,0x54,0x56, 0x1,0x54,0x65, 0x4,0x2c,0x29, 0x2,0x2e,0x3b, + 0x3,0x2f,0x7b, 0x1,0x54,0x54, 0x3,0x2f,0x7a, 0x2,0x2e,0x48, + 0x2,0x2e,0x3c, 0x2,0x2e,0x40, 0x1,0x54,0x59, 0x1,0x54,0x64, + 0x2,0x2e,0x3d, 0x1,0x54,0x5f, 0x2,0x2e,0x42, 0x2,0x2e,0x49, + 0x2,0x34,0x24, 0x3,0x2f,0x73, 0x2,0x2e,0x47, 0x1,0x54,0x66, + 0x1,0x54,0x53, 0x2,0x2e,0x3f, 0x2,0x2e,0x36, 0x3,0x2f,0x76, + 0x1,0x54,0x5b, 0x4,0x2c,0x28, 0x4,0x2c,0x2e, 0x2,0x2e,0x35, + 0x3,0x2f,0x7e, 0x3,0x30,0x25, 0x2,0x2e,0x3a, 0xf,0x29,0x54, + 0xf,0x2e,0x42, 0xf,0x2e,0x4a, 0x2,0x2e,0x33, 0x1,0x54,0x63, + 0x3,0x67,0x21, 0x3,0x34,0x5f, 0x2,0x33,0x7a, 0x3,0x34,0x68, + 0x1,0x59,0x49, 0x2,0x34,0x2a, 0x1,0x59,0x47, 0x1,0x59,0x44, + 0x2,0x34,0x21, 0x1,0x59,0x40, 0x2,0x34,0x25, 0x1,0x59,0x4b, + 0x2,0x33,0x79, 0x2,0x33,0x7e, 0x2,0x33,0x7d, 0x1,0x54,0x55, + 0x1,0x59,0x46, 0x2,0x34,0x28, 0x3,0x34,0x66, 0x2,0x34,0x2b, + 0x2,0x33,0x76, 0x4,0x30,0x77, 0x1,0x5e,0x4e, 0x3,0x34,0x67, + 0x2,0x34,0x2c, 0x1,0x59,0x4c, 0x4,0x30,0x72, 0x1,0x59,0x3e, + 0x1,0x59,0x3b, 0x2,0x34,0x23, 0x1,0x59,0x38, 0x4,0x30,0x74, + 0x2,0x34,0x29, 0x3,0x34,0x5b, 0x1,0x59,0x3f, 0x2,0x34,0x2d, + 0x3,0x34,0x58, 0x2,0x33,0x77, 0x2,0x34,0x27, 0x1,0x59,0x42, + 0x2,0x33,0x78, 0x2,0x33,0x7b, 0x2,0x34,0x22, 0x3,0x34,0x62, + 0x3,0x34,0x61, 0x1,0x59,0x43, 0x1,0x59,0x41, 0x1,0x59,0x4d, + 0x3,0x34,0x57, 0x3,0x3a,0x36, 0x3,0x34,0x64, 0x4,0x30,0x6b, + 0x1,0x59,0x48, 0x3,0x34,0x5e, 0x1,0x59,0x3c, 0x1,0x5a,0x76, + 0x4,0x30,0x7a, 0x1,0x59,0x3d, 0x2,0x33,0x7c, 0x1,0x59,0x4a, + 0x1,0x59,0x45, 0x2,0x34,0x26, 0x1,0x59,0x3a, 0x3,0x34,0x59, + 0x1,0x59,0x39, 0x3,0x64,0x57, 0x3,0x64,0x56, 0x3,0x67,0x22, + 0x3,0x64,0x55, 0x2,0x33,0x74, 0x2,0x33,0x75, 0x2,0x3a,0x4e, + 0x3,0x3a,0x3c, 0x1,0x5e,0x3d, 0x1,0x5e,0x40, 0x2,0x3a,0x59, + 0x1,0x5e,0x54, 0x2,0x3a,0x5c, 0x1,0x5e,0x3e, 0x2,0x3a,0x55, + 0x1,0x5e,0x44, 0x1,0x5e,0x4a, 0x1,0x61,0x43, 0x3,0x3a,0x31, + 0x3,0x3a,0x38, 0x1,0x5e,0x48, 0x2,0x3a,0x52, 0x1,0x5e,0x55, + 0x1,0x5e,0x41, 0x1,0x5e,0x49, 0x2,0x3a,0x5a, 0x2,0x41,0x7c, + 0x2,0x3a,0x5f, 0x2,0x3a,0x53, 0x4,0x36,0x5c, 0x2,0x3a,0x4a, + 0x2,0x3a,0x57, 0x2,0x3a,0x51, 0x1,0x5e,0x47, 0x2,0x3a,0x5d, + 0x3,0x3a,0x2e, 0x3,0x3a,0x2a, 0x1,0x5e,0x43, 0x1,0x5e,0x57, + 0x1,0x5e,0x50, 0x3,0x3a,0x33, 0x1,0x5e,0x45, 0x1,0x5e,0x42, + 0x3,0x3a,0x40, 0x1,0x5e,0x4d, 0x3,0x3a,0x34, 0x2,0x3a,0x5e, + 0x2,0x3a,0x50, 0x2,0x3a,0x56, 0x2,0x3a,0x58, 0x2,0x3a,0x4c, + 0x2,0x3a,0x5b, 0x1,0x5e,0x3f, 0x2,0x3a,0x4b, 0x3,0x3a,0x42, + 0x1,0x5e,0x46, 0x1,0x5e,0x56, 0x1,0x5e,0x52, 0x2,0x3a,0x4d, + 0x1,0x5e,0x4c, 0x3,0x3a,0x3b, 0xf,0x39,0x71, 0x1,0x5e,0x53, + 0x1,0x5e,0x4f, 0x1,0x5e,0x4b, 0x3,0x3a,0x2f, 0x2,0x3a,0x54, + 0x6,0x47,0x29, 0x3,0x67,0x23, 0x1,0x5e,0x51, 0x2,0x41,0x7a, + 0x2,0x41,0x76, 0x3,0x40,0x51, 0x2,0x42,0x27, 0x2,0x41,0x6f, + 0x2,0x41,0x78, 0x1,0x63,0x4c, 0x1,0x63,0x4d, 0x1,0x63,0x45, + 0x2,0x42,0x23, 0x1,0x63,0x4f, 0x2,0x41,0x74, 0x2,0x41,0x73, + 0x2,0x41,0x71, 0x2,0x42,0x25, 0x1,0x63,0x43, 0x2,0x41,0x7d, + 0x2,0x41,0x72, 0x1,0x63,0x46, 0x2,0x41,0x7b, 0x1,0x63,0x41, + 0x2,0x41,0x77, 0x2,0x41,0x7e, 0x2,0x42,0x22, 0x3,0x40,0x4e, + 0x4,0x3c,0x4b, 0x2,0x42,0x26, 0x1,0x63,0x4a, 0x2,0x41,0x70, + 0x1,0x63,0x44, 0x2,0x41,0x75, 0x3,0x3a,0x2b, 0x1,0x63,0x3f, + 0x6,0x51,0x43, 0x1,0x63,0x4b, 0x2,0x42,0x21, 0x1,0x63,0x47, + 0x1,0x63,0x48, 0x1,0x63,0x4e, 0x1,0x63,0x42, 0x1,0x23,0x21, + 0x1,0x63,0x40, 0x2,0x41,0x79, 0x3,0x40,0x4c, 0x3,0x67,0x25, + 0x1,0x63,0x49, 0x3,0x67,0x24, 0xf,0x40,0x62, 0x2,0x42,0x24, + 0x3,0x64,0x58, 0x1,0x68,0x35, 0x1,0x68,0x30, 0x3,0x46,0x2e, + 0x2,0x49,0x3c, 0x2,0x49,0x38, 0x3,0x46,0x28, 0x2,0x49,0x32, + 0x1,0x68,0x2a, 0x1,0x68,0x26, 0x2,0x49,0x3b, 0x1,0x68,0x27, + 0x2,0x49,0x35, 0x2,0x49,0x37, 0x3,0x46,0x29, 0x2,0x49,0x3a, + 0x3,0x46,0x36, 0x1,0x68,0x2c, 0x3,0x46,0x2c, 0x1,0x68,0x33, + 0x1,0x68,0x2d, 0x4,0x42,0x57, 0x3,0x46,0x2a, 0x2,0x49,0x30, + 0x1,0x68,0x2e, 0x1,0x68,0x2f, 0x2,0x49,0x33, 0x1,0x68,0x34, + 0x3,0x46,0x34, 0x2,0x49,0x31, 0x2,0x49,0x36, 0x1,0x68,0x2b, + 0x2,0x49,0x2f, 0x1,0x68,0x31, 0x1,0x68,0x29, 0x3,0x46,0x33, + 0x4,0x42,0x4b, 0x1,0x68,0x28, 0x2,0x49,0x34, 0x2,0x49,0x39, + 0x3,0x46,0x31, 0x1,0x68,0x32, 0x3,0x64,0x5a, 0x3,0x64,0x59, + 0x3,0x46,0x50, 0x2,0x49,0x2e, 0x3,0x46,0x30, 0x1,0x6c,0x37, + 0x2,0x4f,0x6e, 0x3,0x4b,0x41, 0x2,0x4f,0x6b, 0x3,0x4b,0x38, + 0x1,0x6c,0x31, 0x1,0x6c,0x3d, 0x1,0x6c,0x3e, 0x3,0x4b,0x3d, + 0x1,0x6c,0x34, 0x2,0x4f,0x69, 0x1,0x6c,0x36, 0x2,0x4f,0x61, + 0x1,0x6c,0x3c, 0x3,0x4b,0x44, 0x2,0x4f,0x6d, 0x1,0x6c,0x33, + 0x2,0x4f,0x6f, 0x1,0x6c,0x32, 0x4,0x49,0x31, 0x2,0x4f,0x6a, + 0x2,0x4f,0x6c, 0x1,0x6c,0x35, 0x2,0x4f,0x68, 0x2,0x4f,0x62, + 0x2,0x4f,0x5f, 0x4,0x49,0x2e, 0x3,0x4b,0x3e, 0x2,0x3a,0x4f, + 0x2,0x4f,0x65, 0x3,0x4b,0x37, 0x2,0x4f,0x5e, 0x2,0x4f,0x64, + 0x2,0x4f,0x63, 0x3,0x4b,0x3b, 0x2,0x4f,0x60, 0x3,0x4b,0x43, + 0x1,0x6c,0x39, 0x3,0x4b,0x45, 0x3,0x4b,0x40, 0x3,0x46,0x35, + 0x3,0x4b,0x3c, 0x1,0x6c,0x38, 0x3,0x4b,0x39, 0x7,0x21,0x63, + 0x3,0x4b,0x3f, 0x1,0x6c,0x3a, 0x2,0x4f,0x66, 0x1,0x70,0x3b, + 0x2,0x4f,0x67, 0x2,0x56,0x4f, 0x3,0x50,0x3f, 0x2,0x56,0x48, + 0x3,0x50,0x40, 0x1,0x70,0x47, 0x2,0x56,0x4c, 0x1,0x70,0x3f, + 0x1,0x70,0x43, 0x2,0x56,0x4b, 0x3,0x50,0x3b, 0x1,0x70,0x42, + 0x1,0x70,0x3e, 0x1,0x70,0x41, 0x1,0x70,0x3c, 0x1,0x70,0x46, + 0x2,0x56,0x4d, 0x2,0x56,0x49, 0x1,0x70,0x45, 0x2,0x56,0x47, + 0x1,0x70,0x44, 0x2,0x56,0x4e, 0x2,0x56,0x4a, 0x1,0x6c,0x3b, + 0x4,0x4f,0x71, 0x1,0x70,0x48, 0x2,0x56,0x50, 0x1,0x70,0x40, + 0x1,0x70,0x3d, 0xf,0x53,0x5d, 0x3,0x50,0x3d, 0x3,0x54,0x48, + 0x2,0x5c,0x52, 0x2,0x5c,0x54, 0x1,0x73,0x46, 0x2,0x5c,0x55, + 0x2,0x5c,0x53, 0x2,0x5c,0x51, 0x2,0x5c,0x50, 0x1,0x73,0x48, + 0x2,0x5c,0x4f, 0x1,0x73,0x49, 0x4,0x55,0x74, 0x3,0x54,0x49, + 0x3,0x54,0x47, 0x4,0x55,0x78, 0x2,0x5c,0x4d, 0x2,0x5c,0x4e, + 0x1,0x73,0x45, 0x1,0x73,0x4a, 0x1,0x73,0x47, 0x3,0x64,0x5d, + 0x3,0x64,0x5b, 0x2,0x5c,0x4c, 0x3,0x57,0x5b, 0x1,0x76,0x3c, + 0x3,0x57,0x5a, 0x2,0x61,0x48, 0x2,0x61,0x46, 0x2,0x61,0x4b, + 0x2,0x61,0x49, 0x3,0x57,0x58, 0x2,0x61,0x47, 0x2,0x61,0x4a, + 0x3,0x57,0x59, 0x3,0x57,0x57, 0x3,0x57,0x5c, 0x1,0x78,0x2c, + 0x2,0x65,0x3e, 0x2,0x65,0x3f, 0x1,0x78,0x2d, 0x4,0x5f,0x4d, + 0x2,0x65,0x40, 0x2,0x65,0x3c, 0x2,0x65,0x41, 0x2,0x65,0x3d, + 0x1,0x76,0x3d, 0x3,0x5a,0x2d, 0x3,0x64,0x5e, 0x4,0x63,0x31, + 0x2,0x68,0x6b, 0x2,0x68,0x6d, 0x1,0x79,0x64, 0x2,0x68,0x6c, + 0x1,0x79,0x63, 0x1,0x79,0x62, 0x3,0x67,0x26, 0x3,0x67,0x27, + 0x3,0x64,0x5c, 0x3,0x5e,0x26, 0x1,0x79,0x65, 0x2,0x6b,0x53, + 0x2,0x6b,0x54, 0x4,0x66,0x34, 0x1,0x7a,0x65, 0x1,0x7a,0x64, + 0x1,0x7a,0x66, 0x2,0x6b,0x52, 0x3,0x67,0x28, 0x2,0x6d,0x46, + 0x2,0x6d,0x45, 0x3,0x5f,0x40, 0x1,0x7b,0x59, 0x1,0x7b,0x5b, + 0x1,0x7b,0x5a, 0x2,0x6d,0x47, 0x1,0x7c,0x34, 0x2,0x70,0x34, + 0x4,0x6a,0x44, 0x4,0x6a,0x43, 0x1,0x7c,0x5d, 0x3,0x60,0x71, + 0x2,0x70,0x33, 0x2,0x70,0x7c, 0x2,0x21,0x2a, 0x3,0x21,0x77, + 0x4,0x21,0x6f, 0x1,0x46,0x3f, 0x1,0x46,0x3e, 0x4,0x21,0x6d, + 0x1,0x47,0x60, 0x1,0x47,0x5f, 0x2,0x22,0x27, 0x1,0x47,0x5e, + 0x2,0x22,0x26, 0x3,0x23,0x3e, 0x1,0x49,0x5b, 0x2,0x23,0x49, + 0x3,0x25,0x2c, 0x2,0x23,0x48, 0xf,0x23,0x50, 0x3,0x25,0x26, + 0x1,0x49,0x59, 0x1,0x49,0x5c, 0x3,0x25,0x2b, 0x3,0x25,0x2a, + 0x2,0x23,0x47, 0x3,0x25,0x29, 0x1,0x49,0x5a, 0x3,0x25,0x48, + 0x3,0x25,0x27, 0x3,0x25,0x28, 0x3,0x28,0x22, 0x2,0x25,0x70, + 0x3,0x27,0x7d, 0x2,0x25,0x71, 0x1,0x4c,0x56, 0x3,0x27,0x7c, + 0x3,0x28,0x21, 0x3,0x27,0x7b, 0x1,0x50,0x4c, 0x3,0x2b,0x65, + 0x2,0x2e,0x4a, 0x2,0x2e,0x4b, 0x1,0x54,0x67, 0x1,0x54,0x68, + 0x3,0x30,0x27, 0x2,0x34,0x2f, 0x1,0x59,0x4e, 0x1,0x59,0x50, + 0x2,0x34,0x2e, 0x1,0x59,0x4f, 0x2,0x3a,0x60, 0x1,0x5e,0x58, + 0x3,0x3a,0x44, 0x3,0x3a,0x43, 0x4,0x36,0x68, 0x4,0x3c,0x52, + 0x1,0x63,0x50, 0x1,0x63,0x51, 0x2,0x42,0x28, 0x3,0x40,0x52, + 0x1,0x68,0x37, 0x3,0x46,0x37, 0x1,0x68,0x36, 0x2,0x4f,0x70, + 0x2,0x56,0x52, 0x2,0x56,0x51, 0x3,0x5f,0x41, 0x2,0x71,0x5a, + 0x1,0x44,0x48, 0x2,0x21,0x39, 0x3,0x21,0x61, 0x2,0x21,0x4f, + 0x2,0x21,0x50, 0x3,0x22,0x34, 0x4,0x21,0x70, 0x4,0x21,0x71, + 0x1,0x47,0x63, 0x1,0x47,0x67, 0x2,0x22,0x29, 0x4,0x22,0x51, + 0x1,0x47,0x65, 0x1,0x47,0x64, 0x2,0x22,0x28, 0x1,0x47,0x66, + 0x1,0x47,0x62, 0x3,0x23,0x41, 0x3,0x23,0x42, 0x1,0x47,0x61, + 0x2,0x22,0x2a, 0x3,0x23,0x3f, 0x3,0x23,0x40, 0x1,0x49,0x66, + 0x3,0x25,0x31, 0x3,0x25,0x3e, 0x1,0x49,0x63, 0x3,0x25,0x30, + 0x1,0x49,0x5f, 0x2,0x23,0x4a, 0x3,0x25,0x40, 0x3,0x25,0x36, + 0x3,0x25,0x2f, 0x2,0x23,0x4b, 0x3,0x25,0x3c, 0x1,0x49,0x61, + 0x3,0x25,0x2d, 0x2,0x23,0x4d, 0x1,0x49,0x5d, 0x2,0x23,0x4e, + 0x2,0x23,0x4c, 0x1,0x49,0x60, 0x1,0x49,0x62, 0x1,0x49,0x65, + 0x1,0x49,0x64, 0x1,0x49,0x5e, 0x2,0x23,0x4f, 0x3,0x25,0x32, + 0x3,0x25,0x41, 0x3,0x25,0x42, 0x3,0x25,0x33, 0x3,0x25,0x38, + 0x3,0x25,0x37, 0x3,0x64,0x5f, 0xf,0x23,0x52, 0x3,0x25,0x35, + 0x1,0x4c,0x5b, 0x2,0x25,0x7e, 0x3,0x28,0x25, 0x1,0x4c,0x5d, + 0x3,0x28,0x23, 0x1,0x4c,0x5c, 0x3,0x28,0x26, 0x2,0x26,0x21, + 0x1,0x4c,0x5a, 0x1,0x4c,0x59, 0x2,0x25,0x75, 0x4,0x25,0x69, + 0x2,0x25,0x74, 0x3,0x28,0x28, 0x2,0x25,0x72, 0x2,0x25,0x77, + 0x2,0x25,0x76, 0x2,0x25,0x73, 0x2,0x25,0x7c, 0x2,0x25,0x7d, + 0x2,0x25,0x7a, 0x2,0x25,0x78, 0x1,0x4c,0x58, 0x3,0x28,0x29, + 0x4,0x25,0x66, 0x4,0x25,0x68, 0x2,0x25,0x7b, 0x1,0x4c,0x5e, + 0x2,0x26,0x22, 0x4,0x25,0x65, 0x3,0x28,0x2a, 0x2,0x25,0x79, + 0x3,0x28,0x24, 0x1,0x50,0x4d, 0x1,0x4c,0x57, 0x4,0x25,0x6e, + 0xf,0x26,0x33, 0x3,0x64,0x60, 0x1,0x50,0x4e, 0x2,0x29,0x55, + 0x3,0x2b,0x69, 0x3,0x2b,0x68, 0x2,0x29,0x5b, 0x3,0x2b,0x6c, + 0x3,0x2b,0x67, 0x3,0x2b,0x6a, 0x1,0x50,0x54, 0x2,0x29,0x59, + 0x2,0x29,0x5f, 0x3,0x2b,0x71, 0x2,0x29,0x56, 0x2,0x29,0x5a, + 0x2,0x29,0x5c, 0x2,0x29,0x5e, 0x2,0x29,0x58, 0x3,0x2b,0x70, + 0x2,0x29,0x57, 0x2,0x29,0x52, 0x2,0x29,0x53, 0x1,0x50,0x4f, + 0x3,0x2b,0x6b, 0x1,0x50,0x51, 0x1,0x50,0x50, 0x2,0x29,0x54, + 0x2,0x29,0x5d, 0x3,0x2b,0x6d, 0x3,0x2b,0x72, 0x3,0x2b,0x6e, + 0x4,0x28,0x60, 0xf,0x29,0x6a, 0xf,0x29,0x71, 0x3,0x2b,0x66, + 0x1,0x50,0x53, 0x4,0x28,0x5e, 0x2,0x29,0x51, 0x2,0x2e,0x55, + 0x3,0x30,0x2a, 0x2,0x2e,0x54, 0x2,0x2e,0x59, 0x2,0x2e,0x50, + 0x3,0x30,0x30, 0x2,0x2e,0x53, 0x2,0x2e,0x52, 0x3,0x30,0x2f, + 0x2,0x2e,0x56, 0x3,0x30,0x38, 0x2,0x2e,0x5a, 0x1,0x54,0x69, + 0x1,0x54,0x6c, 0x3,0x30,0x34, 0x3,0x30,0x35, 0x2,0x2e,0x51, + 0x2,0x2e,0x57, 0x3,0x30,0x33, 0x3,0x30,0x28, 0x3,0x30,0x37, + 0x1,0x54,0x6b, 0x2,0x2e,0x4c, 0x3,0x30,0x2b, 0x1,0x50,0x52, + 0x2,0x34,0x3d, 0x2,0x2e,0x58, 0x3,0x30,0x36, 0x2,0x2e,0x4f, + 0x4,0x2c,0x33, 0x1,0x54,0x6a, 0x2,0x2e,0x4e, 0xf,0x2e,0x5c, + 0x3,0x30,0x32, 0x2,0x34,0x34, 0x3,0x34,0x6e, 0x3,0x34,0x71, + 0x1,0x59,0x51, 0x1,0x59,0x55, 0x2,0x34,0x44, 0x2,0x34,0x32, + 0x2,0x34,0x40, 0x1,0x59,0x56, 0x2,0x34,0x42, 0x3,0x34,0x72, + 0x2,0x34,0x48, 0x3,0x34,0x74, 0x2,0x34,0x4c, 0x3,0x34,0x69, + 0x4,0x30,0x7b, 0x2,0x34,0x43, 0x2,0x34,0x37, 0x2,0x34,0x3f, + 0x3,0x34,0x6b, 0x2,0x34,0x4d, 0x2,0x34,0x4b, 0x2,0x34,0x41, + 0x2,0x34,0x3c, 0x2,0x34,0x35, 0x2,0x3a,0x68, 0x2,0x34,0x33, + 0x1,0x59,0x5a, 0x2,0x34,0x3a, 0x1,0x59,0x5b, 0x1,0x59,0x57, + 0x2,0x34,0x30, 0x2,0x34,0x46, 0x2,0x34,0x38, 0x3,0x34,0x6f, + 0x3,0x34,0x75, 0x2,0x34,0x36, 0x2,0x34,0x49, 0x1,0x59,0x58, + 0x3,0x34,0x76, 0x2,0x34,0x4f, 0x1,0x59,0x52, 0x1,0x59,0x54, + 0x2,0x34,0x3e, 0x2,0x34,0x39, 0x1,0x54,0x6d, 0x1,0x59,0x53, + 0x2,0x34,0x3b, 0x2,0x34,0x4a, 0x2,0x34,0x4e, 0x2,0x34,0x45, + 0x3,0x64,0x61, 0x2,0x34,0x47, 0x3,0x64,0x62, 0x3,0x64,0x63, + 0x2,0x34,0x31, 0x4,0x36,0x69, 0x3,0x3a,0x4a, 0x2,0x3a,0x63, + 0x3,0x3a,0x45, 0x2,0x3a,0x6c, 0x2,0x3a,0x6b, 0x1,0x5e,0x60, + 0x2,0x3a,0x64, 0x3,0x3a,0x47, 0x1,0x5e,0x61, 0x1,0x5e,0x5f, + 0x3,0x3a,0x50, 0x2,0x3a,0x66, 0x1,0x5e,0x5c, 0x2,0x3a,0x6a, + 0x3,0x3a,0x4c, 0x2,0x3a,0x65, 0x2,0x3a,0x67, 0x2,0x3a,0x61, + 0x1,0x5e,0x5a, 0x4,0x36,0x6f, 0x2,0x3a,0x74, 0x2,0x3a,0x73, + 0x2,0x3a,0x70, 0x1,0x5e,0x59, 0x1,0x5e,0x5d, 0x1,0x5e,0x5e, + 0x2,0x2e,0x4d, 0x2,0x3a,0x6d, 0x1,0x5e,0x5b, 0x1,0x59,0x59, + 0x2,0x3a,0x6f, 0x2,0x3a,0x62, 0x2,0x3a,0x72, 0x2,0x3a,0x71, + 0x3,0x3a,0x4e, 0x2,0x3a,0x75, 0x3,0x3a,0x49, 0x2,0x42,0x36, + 0x3,0x3a,0x4b, 0x2,0x3a,0x6e, 0xf,0x39,0x7d, 0xf,0x39,0x7e, + 0x4,0x3c,0x57, 0x4,0x36,0x6d, 0x4,0x36,0x71, 0x3,0x64,0x64, + 0x2,0x3a,0x69, 0x2,0x42,0x2e, 0x1,0x63,0x5b, 0x1,0x63,0x5e, + 0x1,0x63,0x59, 0x2,0x42,0x2d, 0x2,0x42,0x31, 0x2,0x42,0x2c, + 0x3,0x40,0x57, 0x1,0x63,0x53, 0x1,0x63,0x5d, 0x2,0x42,0x29, + 0x1,0x63,0x57, 0x2,0x42,0x30, 0x3,0x40,0x5b, 0x1,0x63,0x55, + 0x1,0x63,0x54, 0x2,0x42,0x33, 0x1,0x63,0x56, 0x2,0x42,0x35, + 0x3,0x40,0x56, 0x2,0x42,0x32, 0x1,0x63,0x52, 0x3,0x40,0x5e, + 0x3,0x40,0x5c, 0x3,0x40,0x58, 0x1,0x63,0x5c, 0x2,0x42,0x37, + 0x2,0x42,0x2b, 0x2,0x42,0x34, 0x3,0x40,0x5d, 0x4,0x3c,0x53, + 0x2,0x42,0x2a, 0x3,0x40,0x5a, 0x3,0x40,0x59, 0x1,0x63,0x58, + 0x3,0x40,0x54, 0x1,0x63,0x5a, 0x2,0x42,0x2f, 0x2,0x42,0x38, + 0x3,0x46,0x43, 0x3,0x46,0x3e, 0x2,0x49,0x44, 0x1,0x68,0x38, + 0x2,0x49,0x4a, 0x3,0x46,0x42, 0x3,0x46,0x3c, 0x1,0x68,0x3d, + 0x2,0x49,0x46, 0x2,0x49,0x4d, 0x2,0x49,0x3e, 0x1,0x68,0x3f, + 0x1,0x68,0x39, 0x2,0x49,0x43, 0x1,0x6c,0x3f, 0x2,0x49,0x42, + 0x2,0x49,0x4b, 0x1,0x68,0x3a, 0x3,0x46,0x3d, 0x1,0x68,0x3e, + 0x2,0x49,0x41, 0x2,0x49,0x47, 0x2,0x49,0x4c, 0x2,0x49,0x3d, + 0x1,0x68,0x3c, 0x2,0x49,0x45, 0x3,0x46,0x3a, 0x3,0x46,0x45, + 0x2,0x49,0x49, 0x2,0x49,0x4f, 0x2,0x49,0x3f, 0x2,0x49,0x48, + 0x3,0x46,0x38, 0x1,0x68,0x3b, 0x2,0x49,0x4e, 0x3,0x46,0x41, + 0x3,0x46,0x44, 0x3,0x46,0x40, 0x2,0x49,0x40, 0x4,0x42,0x59, + 0x3,0x64,0x65, 0x1,0x6c,0x43, 0x2,0x4f,0x72, 0x1,0x6c,0x41, + 0x1,0x6c,0x40, 0x2,0x4f,0x74, 0x2,0x4f,0x79, 0x3,0x4b,0x46, + 0x2,0x4f,0x75, 0x3,0x4b,0x50, 0x2,0x4f,0x78, 0x1,0x6c,0x46, + 0x3,0x4b,0x51, 0x1,0x70,0x2e, 0x1,0x6c,0x45, 0x3,0x4b,0x4b, + 0x2,0x4f,0x71, 0x2,0x4f,0x77, 0x3,0x46,0x3f, 0x1,0x6c,0x44, + 0x2,0x4f,0x76, 0x3,0x4b,0x4d, 0x2,0x4f,0x73, 0x3,0x4b,0x49, + 0x1,0x6c,0x42, 0x3,0x4b,0x4f, 0x3,0x4b,0x4c, 0x3,0x4b,0x47, + 0x2,0x56,0x57, 0x3,0x50,0x4a, 0x2,0x56,0x59, 0x2,0x56,0x54, + 0x1,0x70,0x4a, 0x2,0x56,0x56, 0x3,0x50,0x4b, 0x1,0x70,0x49, + 0x2,0x56,0x58, 0x3,0x50,0x48, 0x3,0x50,0x4c, 0x1,0x70,0x4c, + 0x2,0x56,0x5a, 0x1,0x70,0x4b, 0x2,0x56,0x53, 0x2,0x56,0x55, + 0x3,0x50,0x49, 0x3,0x54,0x4b, 0x1,0x73,0x4e, 0x2,0x5c,0x58, + 0x3,0x54,0x4c, 0x1,0x73,0x4d, 0x2,0x5c,0x59, 0x1,0x73,0x4c, + 0x2,0x5c,0x57, 0x1,0x73,0x4b, 0x2,0x5c,0x56, 0x1,0x76,0x3f, + 0x1,0x76,0x3e, 0x2,0x65,0x42, 0x2,0x65,0x44, 0x3,0x5a,0x2f, + 0x2,0x65,0x43, 0x1,0x78,0x2e, 0x1,0x78,0x2f, 0x3,0x5a,0x2e, + 0x7,0x46,0x45, 0x1,0x78,0x30, 0x2,0x68,0x6e, 0x1,0x79,0x66, + 0x3,0x5e,0x28, 0x2,0x6f,0x22, 0x2,0x6f,0x21, 0x1,0x7c,0x5e, + 0x1,0x44,0x49, 0x1,0x45,0x31, 0x3,0x23,0x43, 0x1,0x49,0x67, + 0x3,0x25,0x45, 0x3,0x25,0x43, 0x3,0x25,0x44, 0x3,0x28,0x2d, + 0x2,0x29,0x60, 0x3,0x2b,0x77, 0x3,0x34,0x77, 0x1,0x5e,0x62, + 0x1,0x5e,0x63, 0x3,0x3a,0x52, 0x2,0x42,0x39, 0x1,0x68,0x40, + 0x2,0x49,0x50, 0x2,0x4f,0x7a, 0x3,0x64,0x66, 0x3,0x50,0x4d, + 0x3,0x21,0x39, 0x2,0x21,0x3a, 0x3,0x22,0x35, 0x3,0x23,0x44, + 0x2,0x23,0x50, 0x3,0x2b,0x7a, 0x3,0x2b,0x79, 0x3,0x21,0x3a, + 0x3,0x25,0x46, 0x2,0x26,0x23, 0x2,0x29,0x61, 0x2,0x2e,0x5b, + 0x1,0x54,0x6e, 0x3,0x46,0x46, 0x3,0x65,0x60, 0x2,0x65,0x45, + 0x4,0x5f,0x52, 0x1,0x7a,0x67, 0x1,0x44,0x4a, 0x1,0x46,0x40, + 0x2,0x21,0x51, 0x3,0x22,0x36, 0x1,0x47,0x68, 0x1,0x47,0x69, + 0x4,0x22,0x52, 0x1,0x4c,0x5f, 0x4,0x25,0x70, 0x3,0x34,0x79, + 0x1,0x59,0x5c, 0x5,0x37,0x3d, 0x1,0x68,0x42, 0x3,0x40,0x5f, + 0x1,0x68,0x43, 0x1,0x68,0x41, 0x3,0x4b,0x53, 0x1,0x44,0x4b, + 0x4,0x21,0x49, 0x1,0x45,0x32, 0x1,0x45,0x34, 0x1,0x45,0x33, + 0x2,0x21,0x3b, 0x1,0x45,0x35, 0x1,0x46,0x41, 0x2,0x21,0x52, + 0x3,0x22,0x38, 0x1,0x46,0x42, 0x3,0x22,0x37, 0x4,0x21,0x72, + 0x3,0x22,0x39, 0x4,0x22,0x53, 0x3,0x23,0x47, 0x1,0x47,0x6a, + 0x1,0x47,0x6b, 0x2,0x22,0x2b, 0x3,0x25,0x49, 0x1,0x49,0x68, + 0x4,0x23,0x62, 0x2,0x23,0x51, 0x4,0x25,0x75, 0x1,0x4c,0x63, + 0x2,0x26,0x24, 0x4,0x25,0x72, 0x1,0x4c,0x61, 0x1,0x4c,0x62, + 0x1,0x4c,0x60, 0x2,0x2e,0x5c, 0x3,0x28,0x2e, 0x3,0x28,0x2f, + 0x3,0x64,0x67, 0x1,0x50,0x58, 0x1,0x50,0x57, 0x1,0x50,0x59, + 0x1,0x50,0x56, 0x3,0x2b,0x7c, 0x2,0x29,0x62, 0x1,0x4c,0x64, + 0x1,0x50,0x55, 0x1,0x54,0x6f, 0x1,0x54,0x70, 0x4,0x2c,0x38, + 0x1,0x54,0x71, 0x3,0x34,0x7b, 0x2,0x34,0x50, 0x3,0x34,0x7c, + 0x3,0x34,0x7d, 0x4,0x31,0x26, 0x1,0x5e,0x64, 0x2,0x3a,0x76, + 0x1,0x59,0x5d, 0x3,0x3a,0x53, 0x3,0x3a,0x54, 0x4,0x36,0x79, + 0x3,0x40,0x60, 0x1,0x63,0x5f, 0x3,0x40,0x61, 0x1,0x68,0x45, + 0x1,0x68,0x44, 0x2,0x49,0x51, 0x3,0x46,0x48, 0x1,0x6c,0x47, + 0x1,0x70,0x4d, 0x4,0x4f,0x7b, 0x2,0x61,0x4c, 0x2,0x6d,0x48, + 0x2,0x6f,0x23, 0x1,0x44,0x4c, 0x1,0x46,0x43, 0x3,0x22,0x3b, + 0x1,0x46,0x44, 0x2,0x22,0x31, 0x1,0x47,0x6d, 0x1,0x47,0x70, + 0x3,0x23,0x4b, 0x2,0x22,0x2f, 0x2,0x22,0x2d, 0x1,0x47,0x6f, + 0x2,0x22,0x30, 0x2,0x22,0x32, 0x2,0x22,0x2c, 0x1,0x47,0x72, + 0x1,0x47,0x71, 0x1,0x47,0x6e, 0x1,0x47,0x6c, 0x2,0x22,0x2e, + 0x3,0x23,0x4d, 0x3,0x25,0x55, 0x1,0x49,0x73, 0x4,0x23,0x67, + 0x3,0x25,0x4c, 0x1,0x49,0x70, 0x2,0x23,0x56, 0x2,0x23,0x59, + 0x2,0x23,0x58, 0x4,0x23,0x69, 0x1,0x49,0x6a, 0x1,0x49,0x72, + 0x3,0x25,0x4b, 0x4,0x23,0x6a, 0x1,0x49,0x6f, 0x2,0x23,0x55, + 0x2,0x23,0x53, 0x1,0x49,0x6e, 0x3,0x25,0x56, 0x3,0x25,0x53, + 0x3,0x25,0x4e, 0x1,0x49,0x69, 0x1,0x49,0x6c, 0x3,0x25,0x51, + 0x2,0x23,0x54, 0x2,0x23,0x5b, 0x2,0x23,0x57, 0x1,0x49,0x6d, + 0x1,0x49,0x71, 0x1,0x49,0x74, 0x2,0x23,0x52, 0x2,0x23,0x5a, + 0x1,0x49,0x6b, 0x3,0x28,0x41, 0x3,0x28,0x33, 0x1,0x4c,0x69, + 0x1,0x4c,0x71, 0x3,0x28,0x38, 0x2,0x26,0x30, 0x2,0x26,0x29, + 0x1,0x4c,0x72, 0x2,0x26,0x34, 0x2,0x26,0x25, 0x2,0x26,0x2c, + 0x3,0x28,0x45, 0x3,0x28,0x40, 0x1,0x4c,0x68, 0x2,0x26,0x26, + 0x1,0x4c,0x66, 0x2,0x26,0x2d, 0x2,0x26,0x31, 0x1,0x4c,0x65, + 0x3,0x28,0x3d, 0x2,0x26,0x32, 0x2,0x26,0x2b, 0x3,0x28,0x37, + 0x2,0x26,0x2e, 0x3,0x28,0x35, 0x1,0x4c,0x74, 0x1,0x4c,0x6b, + 0x2,0x26,0x35, 0x2,0x26,0x33, 0x3,0x28,0x3f, 0x1,0x4c,0x70, + 0x1,0x4c,0x6e, 0x2,0x26,0x2a, 0x1,0x4c,0x6d, 0x2,0x26,0x28, + 0x2,0x26,0x27, 0x1,0x4c,0x6c, 0x1,0x4c,0x6a, 0x1,0x4c,0x73, + 0x1,0x4c,0x6f, 0x1,0x4c,0x67, 0x3,0x2c,0x26, 0x2,0x26,0x2f, + 0x3,0x28,0x46, 0x1,0x50,0x5b, 0x3,0x2c,0x2d, 0x1,0x50,0x62, + 0x2,0x29,0x70, 0x1,0x50,0x5a, 0x2,0x29,0x68, 0x2,0x29,0x64, + 0x3,0x2c,0x21, 0x2,0x29,0x74, 0x2,0x29,0x63, 0x3,0x2c,0x2c, + 0x1,0x50,0x5d, 0x2,0x29,0x6d, 0x1,0x50,0x60, 0x1,0x50,0x63, + 0x3,0x2c,0x2e, 0x1,0x50,0x5e, 0x2,0x29,0x71, 0x1,0x50,0x61, + 0x3,0x2c,0x23, 0x1,0x54,0x78, 0x2,0x29,0x77, 0x2,0x29,0x65, + 0x3,0x2c,0x24, 0x3,0x2c,0x25, 0x2,0x29,0x67, 0x2,0x29,0x6e, + 0x2,0x29,0x72, 0x2,0x29,0x76, 0x2,0x29,0x73, 0x2,0x29,0x6c, + 0x2,0x29,0x6f, 0x3,0x2c,0x2b, 0x3,0x2c,0x29, 0x2,0x29,0x69, + 0x1,0x50,0x65, 0x2,0x29,0x6b, 0x2,0x29,0x6a, 0x2,0x29,0x75, + 0x1,0x50,0x5c, 0x2,0x29,0x66, 0x1,0x50,0x64, 0x3,0x2c,0x2a, + 0x1,0x50,0x5f, 0x3,0x2c,0x28, 0x1,0x54,0x7e, 0x2,0x2e,0x64, + 0x3,0x30,0x40, 0x1,0x54,0x7d, 0x3,0x2c,0x27, 0x4,0x2c,0x40, + 0x2,0x2e,0x62, 0x4,0x2c,0x3e, 0x1,0x54,0x72, 0x3,0x30,0x4f, + 0x1,0x54,0x77, 0x3,0x30,0x4a, 0x2,0x2e,0x61, 0x2,0x2e,0x5e, + 0x2,0x2e,0x63, 0x1,0x54,0x73, 0x2,0x2e,0x5d, 0x3,0x30,0x4e, + 0x1,0x54,0x76, 0x1,0x54,0x74, 0x3,0x30,0x3e, 0x2,0x2e,0x65, + 0x1,0x54,0x75, 0x1,0x54,0x79, 0x3,0x30,0x3b, 0x3,0x30,0x45, + 0x1,0x54,0x7a, 0x3,0x30,0x48, 0x1,0x54,0x7c, 0x3,0x30,0x52, + 0x4,0x2c,0x39, 0x4,0x2c,0x3d, 0x1,0x54,0x7b, 0x3,0x30,0x3c, + 0x3,0x35,0x22, 0x3,0x35,0x38, 0x2,0x2e,0x5f, 0x2,0x2e,0x60, + 0x3,0x30,0x4d, 0x6,0x36,0x57, 0x3,0x30,0x4b, 0x2,0x2e,0x66, + 0x2,0x34,0x57, 0x1,0x59,0x5e, 0x2,0x3b,0x26, 0x2,0x34,0x56, + 0x2,0x34,0x69, 0x3,0x35,0x28, 0x3,0x35,0x24, 0x1,0x59,0x64, + 0x3,0x35,0x31, 0x2,0x34,0x67, 0x3,0x35,0x33, 0x1,0x59,0x63, + 0x1,0x59,0x5f, 0x2,0x34,0x70, 0x2,0x34,0x60, 0x2,0x34,0x63, + 0x3,0x35,0x2e, 0x1,0x59,0x67, 0x2,0x34,0x6d, 0x2,0x34,0x65, + 0x1,0x59,0x60, 0x1,0x59,0x68, 0x3,0x35,0x2a, 0x2,0x34,0x6a, + 0x2,0x34,0x68, 0x3,0x35,0x2f, 0x3,0x35,0x3b, 0x2,0x34,0x59, + 0x2,0x34,0x6e, 0x2,0x34,0x62, 0x2,0x34,0x5d, 0x3,0x35,0x3a, + 0x2,0x34,0x53, 0x2,0x34,0x6f, 0x2,0x34,0x5f, 0x2,0x34,0x52, + 0x3,0x35,0x39, 0x1,0x59,0x66, 0x2,0x34,0x64, 0x2,0x34,0x71, + 0x2,0x34,0x61, 0x2,0x34,0x55, 0x2,0x34,0x5a, 0x2,0x34,0x51, + 0x3,0x35,0x27, 0x1,0x59,0x65, 0x3,0x35,0x3c, 0x2,0x34,0x5e, + 0x2,0x34,0x5b, 0x1,0x59,0x61, 0x2,0x34,0x54, 0x3,0x35,0x30, + 0x2,0x34,0x6c, 0x1,0x59,0x62, 0x3,0x35,0x2b, 0x2,0x34,0x5c, + 0x2,0x34,0x58, 0x3,0x35,0x29, 0x3,0x35,0x34, 0x2,0x34,0x6b, + 0x3,0x35,0x32, 0xf,0x33,0x73, 0x3,0x35,0x37, 0x3,0x35,0x35, + 0x1,0x5e,0x65, 0x2,0x3a,0x7d, 0x3,0x3a,0x75, 0x2,0x3a,0x7a, + 0x2,0x3b,0x2d, 0x2,0x3b,0x21, 0x2,0x3b,0x2e, 0x3,0x3a,0x7c, + 0x1,0x5e,0x67, 0x3,0x3a,0x63, 0x3,0x3a,0x61, 0x3,0x3a,0x58, + 0x2,0x3b,0x2a, 0x2,0x3b,0x27, 0x3,0x3a,0x5b, 0x3,0x3a,0x77, + 0x3,0x3a,0x72, 0x3,0x3a,0x59, 0x3,0x3a,0x60, 0x2,0x3b,0x28, + 0x2,0x3b,0x2b, 0x2,0x3b,0x2f, 0x3,0x3a,0x7b, 0x2,0x34,0x66, + 0x2,0x3b,0x31, 0x2,0x42,0x4d, 0x3,0x3a,0x66, 0x1,0x5e,0x68, + 0x2,0x3b,0x32, 0x2,0x3a,0x78, 0x2,0x3b,0x24, 0x3,0x3a,0x62, + 0x2,0x3b,0x29, 0x3,0x3a,0x5c, 0x3,0x3a,0x5e, 0x1,0x5e,0x66, + 0x1,0x5e,0x69, 0x2,0x3b,0x30, 0x2,0x3b,0x33, 0x2,0x3a,0x7c, + 0x2,0x3a,0x79, 0x3,0x3a,0x73, 0x3,0x3a,0x5a, 0x2,0x3a,0x7b, + 0x3,0x3a,0x57, 0x3,0x3a,0x7a, 0x2,0x3b,0x22, 0x2,0x3a,0x7e, + 0x1,0x5e,0x6a, 0x3,0x3a,0x56, 0x2,0x3b,0x2c, 0x3,0x3a,0x79, + 0x3,0x3a,0x78, 0x2,0x3b,0x23, 0x2,0x3b,0x25, 0x2,0x3a,0x77, + 0x2,0x42,0x41, 0x2,0x42,0x3f, 0x1,0x63,0x68, 0x1,0x63,0x66, + 0x2,0x42,0x49, 0x2,0x42,0x40, 0x2,0x42,0x4a, 0x2,0x42,0x46, + 0x2,0x42,0x3e, 0x2,0x42,0x4c, 0x2,0x42,0x3d, 0x2,0x42,0x44, + 0x1,0x63,0x65, 0x1,0x63,0x64, 0x1,0x63,0x63, 0x2,0x42,0x42, + 0x2,0x42,0x47, 0x1,0x63,0x60, 0x1,0x63,0x67, 0x3,0x40,0x67, + 0x2,0x42,0x3b, 0x3,0x40,0x66, 0x2,0x42,0x45, 0x2,0x42,0x3a, + 0x2,0x42,0x43, 0x1,0x63,0x61, 0x2,0x42,0x48, 0x2,0x42,0x3c, + 0x1,0x63,0x62, 0x2,0x42,0x4b, 0x3,0x40,0x64, 0x3,0x3a,0x6b, + 0x3,0x40,0x6a, 0x3,0x64,0x68, 0x3,0x64,0x69, 0x2,0x49,0x55, + 0x1,0x68,0x4a, 0x1,0x68,0x49, 0x1,0x68,0x4b, 0x2,0x49,0x61, + 0x2,0x49,0x57, 0x2,0x49,0x5d, 0x2,0x49,0x52, 0x2,0x49,0x60, + 0x2,0x49,0x5f, 0x2,0x49,0x63, 0x2,0x49,0x5c, 0x1,0x68,0x46, + 0x2,0x49,0x5b, 0x1,0x68,0x4c, 0x3,0x46,0x4c, 0x2,0x49,0x54, + 0x1,0x68,0x47, 0x3,0x46,0x4a, 0x2,0x49,0x62, 0x1,0x68,0x48, + 0x2,0x49,0x56, 0x2,0x49,0x59, 0x2,0x49,0x5e, 0x2,0x49,0x58, + 0x2,0x49,0x53, 0x3,0x46,0x4f, 0x3,0x46,0x53, 0x2,0x49,0x5a, + 0x2,0x4f,0x7c, 0x1,0x6c,0x4b, 0x2,0x50,0x21, 0x2,0x4f,0x7e, + 0x2,0x50,0x23, 0x2,0x50,0x25, 0x3,0x4b,0x5c, 0x1,0x6c,0x49, + 0x3,0x4b,0x58, 0x2,0x4f,0x7d, 0x3,0x4b,0x54, 0x2,0x4f,0x7b, + 0x3,0x4b,0x5e, 0x2,0x50,0x26, 0x2,0x50,0x24, 0x2,0x50,0x22, + 0x3,0x4b,0x56, 0x2,0x50,0x28, 0x3,0x4b,0x5a, 0x2,0x50,0x27, + 0x1,0x6c,0x4d, 0x1,0x6c,0x48, 0x3,0x4b,0x5b, 0x1,0x6c,0x4a, + 0x1,0x6c,0x4c, 0x3,0x4b,0x5d, 0x3,0x4b,0x5f, 0x2,0x50,0x29, + 0x2,0x56,0x61, 0x3,0x50,0x50, 0x3,0x50,0x53, 0x2,0x56,0x60, + 0x2,0x56,0x5f, 0x3,0x50,0x51, 0x2,0x56,0x62, 0x2,0x56,0x5b, + 0x3,0x50,0x4f, 0x2,0x56,0x5c, 0x2,0x56,0x64, 0x2,0x56,0x5d, + 0x3,0x50,0x54, 0x1,0x70,0x4e, 0x2,0x56,0x66, 0x3,0x50,0x4e, + 0x2,0x56,0x65, 0x2,0x56,0x5e, 0x3,0x50,0x56, 0x2,0x5c,0x5d, + 0x1,0x73,0x51, 0x2,0x5c,0x5b, 0x2,0x5c,0x60, 0x2,0x5c,0x5f, + 0x2,0x56,0x63, 0x3,0x54,0x50, 0x1,0x73,0x50, 0x3,0x54,0x4e, + 0x2,0x5c,0x5e, 0x2,0x5c,0x5a, 0x2,0x5c,0x62, 0x2,0x5c,0x61, + 0x1,0x73,0x4f, 0x3,0x54,0x52, 0x2,0x5c,0x5c, 0x3,0x54,0x4f, + 0x1,0x70,0x4f, 0x3,0x54,0x51, 0x3,0x54,0x53, 0x1,0x76,0x40, + 0x3,0x5a,0x31, 0x3,0x57,0x61, 0x3,0x57,0x5e, 0x2,0x61,0x4d, + 0x2,0x65,0x46, 0x2,0x65,0x47, 0x2,0x65,0x48, 0x1,0x79,0x67, + 0x4,0x63,0x34, 0x3,0x5c,0x36, 0x1,0x79,0x68, 0x3,0x5c,0x39, + 0x2,0x68,0x6f, 0x3,0x5c,0x3a, 0x2,0x6b,0x56, 0x2,0x6b,0x55, + 0x3,0x5e,0x29, 0x3,0x5f,0x42, 0x2,0x6d,0x49, 0x2,0x6d,0x4a, + 0x2,0x6f,0x24, 0x2,0x70,0x35, 0x3,0x60,0x73, 0x1,0x44,0x4d, + 0x1,0x44,0x4e, 0x4,0x21,0x32, 0x1,0x44,0x4f, 0x1,0x45,0x36, + 0x1,0x46,0x45, 0x2,0x22,0x33, 0x1,0x47,0x73, 0x1,0x47,0x74, + 0x1,0x49,0x77, 0x1,0x49,0x78, 0x1,0x49,0x76, 0x1,0x49,0x75, + 0x1,0x4c,0x75, 0x3,0x28,0x48, 0x4,0x26,0x22, 0x2,0x26,0x36, + 0x1,0x4c,0x77, 0x1,0x4c,0x76, 0x2,0x26,0x37, 0x4,0x26,0x23, + 0x3,0x64,0x6a, 0x4,0x28,0x6e, 0x1,0x50,0x66, 0x3,0x2c,0x2f, + 0x1,0x55,0x21, 0x2,0x2e,0x67, 0x2,0x34,0x73, 0x4,0x31,0x2c, + 0x1,0x59,0x69, 0x1,0x5e,0x6c, 0x2,0x34,0x72, 0x1,0x5e,0x6b, + 0x3,0x40,0x71, 0x1,0x68,0x4d, 0x3,0x40,0x72, 0x2,0x49,0x64, + 0x1,0x70,0x50, 0x3,0x50,0x57, 0x1,0x73,0x52, 0x2,0x5c,0x63, + 0x3,0x5a,0x34, 0x1,0x79,0x69, 0x3,0x5c,0x3b, 0x1,0x7b,0x5c, + 0x3,0x21,0x3b, 0x2,0x21,0x53, 0x3,0x22,0x3d, 0x1,0x46,0x46, + 0x2,0x21,0x54, 0x1,0x47,0x77, 0x3,0x23,0x50, 0x1,0x47,0x75, + 0x1,0x47,0x76, 0x1,0x47,0x78, 0x4,0x23,0x6f, 0x1,0x49,0x7a, + 0x1,0x49,0x79, 0x3,0x25,0x5a, 0x2,0x23,0x5c, 0x1,0x49,0x7b, + 0x4,0x26,0x25, 0x2,0x23,0x5d, 0x2,0x26,0x38, 0x3,0x28,0x4c, + 0x2,0x26,0x39, 0x3,0x28,0x4a, 0x1,0x4c,0x78, 0x1,0x4c,0x7a, + 0x1,0x4c,0x7c, 0x1,0x4c,0x79, 0x1,0x4c,0x7d, 0x1,0x4c,0x7b, + 0x3,0x28,0x4e, 0x3,0x28,0x4b, 0x3,0x28,0x4d, 0x1,0x50,0x6a, + 0x1,0x50,0x67, 0x1,0x50,0x69, 0x1,0x50,0x6b, 0x1,0x50,0x68, + 0x2,0x2e,0x68, 0x2,0x29,0x78, 0xf,0x2a,0x39, 0x3,0x2c,0x32, + 0x2,0x2e,0x6a, 0x2,0x2e,0x69, 0x1,0x55,0x27, 0x4,0x2c,0x46, + 0x1,0x55,0x23, 0x4,0x2c,0x49, 0x6,0x36,0x66, 0x1,0x55,0x24, + 0x1,0x55,0x26, 0x1,0x55,0x28, 0x1,0x55,0x25, 0x3,0x30,0x57, + 0x1,0x55,0x2a, 0x1,0x55,0x29, 0x4,0x2c,0x48, 0x3,0x30,0x56, + 0x3,0x30,0x55, 0xf,0x2e,0x7e, 0x1,0x59,0x6e, 0x2,0x34,0x75, + 0x2,0x34,0x74, 0x1,0x59,0x6d, 0x3,0x35,0x41, 0x1,0x59,0x6c, + 0x1,0x59,0x6b, 0x1,0x59,0x6f, 0x1,0x59,0x6a, 0x3,0x35,0x3f, + 0x2,0x3b,0x39, 0x2,0x3b,0x36, 0x1,0x5e,0x6e, 0x2,0x3b,0x35, + 0x2,0x3b,0x3a, 0x4,0x37,0x24, 0x1,0x5e,0x70, 0x2,0x3b,0x38, + 0x1,0x5e,0x6d, 0x1,0x5e,0x6f, 0x2,0x3b,0x37, 0x3,0x3a,0x7e, + 0x2,0x42,0x4e, 0x3,0x40,0x74, 0x2,0x42,0x4f, 0x2,0x42,0x50, + 0x3,0x40,0x75, 0x3,0x40,0x76, 0x3,0x40,0x73, 0x4,0x3c,0x6e, + 0x1,0x68,0x4e, 0x1,0x68,0x56, 0x2,0x49,0x65, 0x1,0x68,0x50, + 0x1,0x68,0x54, 0x2,0x49,0x66, 0x1,0x68,0x55, 0x1,0x68,0x51, + 0x1,0x68,0x52, 0x1,0x68,0x4f, 0x1,0x68,0x53, 0x1,0x6c,0x50, + 0x2,0x3b,0x34, 0x1,0x6c,0x51, 0x1,0x6c,0x4f, 0x4,0x49,0x44, + 0x1,0x6c,0x4e, 0x2,0x56,0x67, 0x1,0x70,0x51, 0x2,0x5c,0x64, + 0x2,0x5c,0x65, 0x3,0x5a,0x35, 0x4,0x5f,0x55, 0x1,0x78,0x31, + 0x1,0x79,0x6a, 0x3,0x5e,0x2a, 0x1,0x44,0x50, 0x3,0x22,0x3e, + 0x1,0x47,0x79, 0x3,0x25,0x5e, 0x3,0x25,0x5c, 0x3,0x25,0x5d, + 0x3,0x28,0x50, 0x1,0x50,0x6c, 0x2,0x2e,0x6b, 0x1,0x55,0x2b, + 0x3,0x30,0x58, 0x3,0x30,0x59, 0x1,0x59,0x72, 0x1,0x59,0x71, + 0x1,0x59,0x70, 0x1,0x5e,0x71, 0x1,0x5e,0x72, 0x2,0x3b,0x3b, + 0x1,0x68,0x57, 0x1,0x70,0x52, 0x1,0x44,0x51, 0x2,0x21,0x3c, + 0x1,0x45,0x37, 0x2,0x21,0x55, 0x4,0x21,0x73, 0x3,0x22,0x3f, + 0x2,0x22,0x34, 0x1,0x47,0x7a, 0x4,0x22,0x5c, 0x3,0x23,0x52, + 0x3,0x28,0x51, 0x1,0x4c,0x7e, 0x3,0x2c,0x34, 0x3,0x3b,0x24, + 0x2,0x42,0x51, 0x3,0x40,0x78, 0x3,0x65,0x25, 0x1,0x44,0x52, + 0x4,0x21,0x4b, 0x1,0x45,0x38, 0x2,0x22,0x35, 0x2,0x23,0x5e, + 0x4,0x26,0x29, 0x2,0x23,0x5f, 0x3,0x25,0x5f, 0x1,0x49,0x7c, + 0xf,0x25,0x54, 0x3,0x2c,0x35, 0x2,0x3b,0x3c, 0x1,0x5e,0x73, + 0x2,0x42,0x52, 0x4,0x49,0x49, 0x3,0x54,0x54, 0x1,0x73,0x53, + 0x1,0x44,0x53, 0x1,0x44,0x67, 0x1,0x45,0x39, 0x2,0x21,0x56, + 0x1,0x46,0x47, 0x3,0x23,0x54, 0x1,0x4a,0x22, 0x1,0x4a,0x21, + 0x1,0x49,0x7d, 0x1,0x49,0x7e, 0x2,0x26,0x3a, 0x1,0x4d,0x22, + 0x1,0x4d,0x23, 0x2,0x26,0x3b, 0x1,0x4d,0x21, 0x3,0x28,0x54, + 0x3,0x28,0x55, 0x1,0x50,0x70, 0x2,0x29,0x79, 0x1,0x50,0x6f, + 0x1,0x50,0x6d, 0x1,0x50,0x6e, 0x1,0x55,0x2e, 0x1,0x55,0x2c, + 0x3,0x30,0x5a, 0x3,0x30,0x5b, 0x2,0x2e,0x6d, 0x1,0x55,0x2d, + 0x2,0x2e,0x6c, 0x3,0x64,0x6b, 0x1,0x55,0x22, 0x2,0x34,0x76, + 0x4,0x31,0x35, 0x3,0x35,0x43, 0x1,0x59,0x74, 0x1,0x59,0x75, + 0x3,0x3b,0x26, 0x3,0x3b,0x25, 0x1,0x59,0x73, 0x3,0x35,0x44, + 0x1,0x68,0x58, 0x2,0x49,0x67, 0x1,0x6c,0x52, 0x1,0x6c,0x53, + 0x2,0x50,0x2a, 0x1,0x73,0x54, 0x2,0x61,0x4e, 0x2,0x61,0x4f, + 0x3,0x5a,0x38, 0x1,0x7a,0x68, 0x2,0x70,0x36, 0x2,0x21,0x2b, + 0x1,0x45,0x3a, 0x4,0x22,0x5f, 0x1,0x44,0x54, 0x2,0x21,0x58, + 0x2,0x21,0x57, 0x4,0x21,0x76, 0x3,0x64,0x6c, 0x3,0x23,0x55, + 0x1,0x47,0x7b, 0x2,0x22,0x37, 0x2,0x22,0x38, 0x2,0x22,0x36, + 0x4,0x22,0x60, 0x2,0x22,0x39, 0x3,0x23,0x5a, 0xf,0x22,0x47, + 0x3,0x25,0x61, 0x3,0x25,0x66, 0x2,0x23,0x67, 0x4,0x23,0x7a, + 0x2,0x23,0x62, 0x2,0x23,0x64, 0x2,0x23,0x66, 0x2,0x23,0x63, + 0x1,0x4a,0x26, 0x2,0x23,0x60, 0x3,0x25,0x62, 0x2,0x23,0x61, + 0x1,0x4a,0x23, 0x1,0x4a,0x24, 0x2,0x23,0x65, 0x2,0x23,0x68, + 0x1,0x4a,0x25, 0x2,0x23,0x69, 0xf,0x23,0x7c, 0xf,0x23,0x78, + 0x3,0x25,0x63, 0x2,0x26,0x49, 0x3,0x28,0x5d, 0x2,0x26,0x43, + 0x2,0x26,0x3e, 0x1,0x4d,0x25, 0x2,0x26,0x46, 0x2,0x26,0x44, + 0x2,0x26,0x3d, 0x2,0x26,0x4a, 0x2,0x26,0x4d, 0x2,0x26,0x48, + 0x2,0x26,0x41, 0x1,0x4d,0x27, 0x2,0x26,0x47, 0x1,0x4d,0x28, + 0x2,0x26,0x42, 0x2,0x26,0x45, 0x2,0x26,0x3c, 0x2,0x26,0x40, + 0x2,0x26,0x4c, 0x1,0x4d,0x29, 0x4,0x26,0x2f, 0x1,0x4d,0x2a, + 0x3,0x28,0x5e, 0x2,0x26,0x3f, 0x2,0x26,0x4b, 0x1,0x4d,0x24, + 0x1,0x4d,0x26, 0x3,0x28,0x5c, 0x3,0x28,0x5f, 0x3,0x28,0x57, + 0x4,0x26,0x34, 0x3,0x28,0x58, 0x2,0x2a,0x2c, 0x2,0x2a,0x25, + 0x2,0x2a,0x2b, 0x2,0x2a,0x24, 0x2,0x2a,0x26, 0x2,0x29,0x7e, + 0x2,0x29,0x7c, 0x3,0x2c,0x3f, 0x2,0x2a,0x2d, 0x2,0x2a,0x2a, + 0x2,0x29,0x7a, 0x3,0x2c,0x3b, 0x1,0x50,0x72, 0x2,0x2a,0x28, + 0x2,0x2a,0x29, 0x3,0x64,0x6d, 0x2,0x2a,0x27, 0x2,0x29,0x7d, + 0x2,0x29,0x7b, 0x1,0x50,0x71, 0x2,0x2a,0x23, 0x2,0x2a,0x21, + 0x3,0x2c,0x3c, 0x3,0x2c,0x42, 0x2,0x2a,0x22, 0x2,0x2a,0x2e, + 0x3,0x2c,0x3e, 0x3,0x2c,0x41, 0x3,0x2c,0x43, 0x3,0x2c,0x3d, + 0x1,0x55,0x33, 0x3,0x30,0x63, 0x1,0x55,0x32, 0x3,0x30,0x5f, + 0x2,0x2e,0x6e, 0x1,0x55,0x2f, 0x2,0x2e,0x70, 0x3,0x30,0x64, + 0x1,0x55,0x34, 0x2,0x2e,0x71, 0x4,0x2c,0x60, 0x3,0x30,0x61, + 0x1,0x55,0x37, 0x3,0x30,0x62, 0x1,0x55,0x35, 0x2,0x2e,0x72, + 0x2,0x2a,0x2f, 0x2,0x2e,0x74, 0x3,0x30,0x5e, 0x1,0x55,0x31, + 0x4,0x2c,0x5c, 0x1,0x55,0x30, 0x4,0x2c,0x61, 0x2,0x2e,0x6f, + 0x2,0x2e,0x73, 0x1,0x55,0x36, 0x1,0x59,0x77, 0x1,0x59,0x76, + 0x3,0x35,0x4b, 0x3,0x35,0x48, 0x3,0x35,0x47, 0x2,0x34,0x78, + 0x2,0x34,0x7c, 0x2,0x34,0x7e, 0x1,0x59,0x78, 0x2,0x35,0x23, + 0x3,0x35,0x51, 0x1,0x59,0x7c, 0x2,0x35,0x25, 0x3,0x35,0x52, + 0x1,0x59,0x7e, 0x3,0x35,0x4f, 0x1,0x59,0x7a, 0x1,0x5a,0x24, + 0x3,0x35,0x55, 0x1,0x5a,0x21, 0x2,0x34,0x7a, 0x1,0x59,0x79, + 0x3,0x3b,0x2b, 0x2,0x34,0x79, 0x2,0x34,0x77, 0x2,0x35,0x27, + 0x2,0x34,0x7b, 0x3,0x35,0x46, 0x1,0x59,0x7b, 0x2,0x35,0x26, + 0x1,0x5a,0x22, 0x2,0x35,0x22, 0x2,0x35,0x21, 0x1,0x5a,0x23, + 0x2,0x34,0x7d, 0x1,0x59,0x7d, 0x3,0x35,0x4e, 0x6,0x3e,0x76, + 0x3,0x35,0x4a, 0x2,0x35,0x28, 0x3,0x35,0x54, 0x2,0x35,0x24, + 0x2,0x3b,0x4b, 0x2,0x3b,0x52, 0x2,0x3b,0x47, 0x1,0x5e,0x76, + 0x2,0x3b,0x43, 0x2,0x3b,0x53, 0x2,0x3b,0x3d, 0x2,0x3b,0x50, + 0x2,0x3b,0x4e, 0x2,0x3b,0x48, 0x3,0x3b,0x36, 0x2,0x3b,0x51, + 0x2,0x3b,0x4a, 0x3,0x3b,0x28, 0x2,0x3b,0x42, 0x2,0x3b,0x54, + 0x2,0x3b,0x40, 0x2,0x3b,0x4d, 0x2,0x3b,0x3e, 0x3,0x3b,0x27, + 0x2,0x3b,0x55, 0x3,0x3b,0x37, 0x1,0x5e,0x77, 0x3,0x3b,0x2a, + 0x2,0x3b,0x4f, 0x2,0x42,0x55, 0x2,0x3b,0x41, 0x1,0x5e,0x74, + 0x3,0x3b,0x2e, 0x2,0x3b,0x45, 0x3,0x3b,0x34, 0x1,0x5e,0x75, + 0x2,0x3b,0x44, 0x2,0x3b,0x49, 0x3,0x3b,0x33, 0x4,0x37,0x35, + 0x2,0x3b,0x46, 0x4,0x37,0x2f, 0x3,0x3b,0x31, 0x2,0x3b,0x4c, + 0x3,0x3b,0x2d, 0x2,0x42,0x59, 0x4,0x3c,0x79, 0x3,0x41,0x21, + 0x4,0x3c,0x7b, 0x2,0x42,0x5c, 0x2,0x42,0x54, 0x3,0x40,0x7c, + 0x2,0x42,0x56, 0x3,0x40,0x7a, 0x2,0x42,0x5b, 0x2,0x42,0x5a, + 0x1,0x63,0x69, 0x4,0x3c,0x75, 0x2,0x3b,0x3f, 0x2,0x42,0x58, + 0x3,0x40,0x79, 0x3,0x40,0x7d, 0x1,0x63,0x6a, 0x4,0x3c,0x74, + 0x2,0x42,0x53, 0x2,0x42,0x57, 0x4,0x3c,0x7c, 0x4,0x3c,0x78, + 0x3,0x64,0x6e, 0x2,0x49,0x6e, 0x3,0x46,0x5c, 0x2,0x49,0x75, + 0x2,0x49,0x6c, 0x3,0x46,0x54, 0x2,0x49,0x73, 0x2,0x49,0x6a, + 0x2,0x49,0x72, 0x2,0x49,0x76, 0x2,0x49,0x69, 0x2,0x49,0x6d, + 0x2,0x49,0x68, 0x3,0x46,0x56, 0x1,0x68,0x59, 0x4,0x43,0x2c, + 0x2,0x49,0x6b, 0x1,0x68,0x5a, 0x2,0x49,0x71, 0x2,0x49,0x70, + 0x2,0x49,0x6f, 0x3,0x46,0x59, 0x3,0x46,0x5a, 0x2,0x49,0x74, + 0x3,0x64,0x6f, 0x3,0x4b,0x65, 0x3,0x4b,0x66, 0x3,0x4b,0x63, + 0x2,0x50,0x2e, 0x2,0x50,0x30, 0x1,0x6c,0x55, 0x2,0x50,0x31, + 0x3,0x4b,0x6b, 0x2,0x50,0x2c, 0x3,0x4b,0x67, 0x2,0x50,0x2b, + 0x2,0x50,0x35, 0x3,0x4b,0x69, 0x2,0x50,0x33, 0x1,0x6c,0x54, + 0x2,0x50,0x36, 0x2,0x50,0x2d, 0x2,0x50,0x32, 0x2,0x50,0x34, + 0x2,0x50,0x2f, 0x3,0x4b,0x6a, 0x3,0x4b,0x68, 0x3,0x64,0x70, + 0x3,0x50,0x58, 0x2,0x56,0x6b, 0x2,0x56,0x70, 0x2,0x56,0x6a, + 0x2,0x56,0x6f, 0x3,0x50,0x5b, 0x2,0x56,0x68, 0x2,0x56,0x72, + 0x2,0x56,0x6e, 0x2,0x56,0x73, 0x2,0x56,0x6d, 0x2,0x56,0x69, + 0x2,0x56,0x71, 0x3,0x50,0x5a, 0x2,0x56,0x74, 0x2,0x56,0x6c, + 0x3,0x64,0x71, 0x2,0x5c,0x66, 0x1,0x73,0x58, 0x3,0x54,0x57, + 0x1,0x73,0x56, 0x3,0x54,0x59, 0x1,0x73,0x55, 0x1,0x73,0x57, + 0x3,0x54,0x55, 0x3,0x64,0x72, 0x2,0x61,0x50, 0x3,0x57,0x62, + 0x2,0x64,0x3e, 0x2,0x65,0x49, 0x3,0x5a,0x39, 0x2,0x68,0x70, + 0x2,0x68,0x71, 0x3,0x5c,0x3d, 0x1,0x79,0x6b, 0x3,0x5c,0x3c, + 0x2,0x6b,0x57, 0x3,0x5c,0x3e, 0x1,0x7a,0x69, 0x4,0x66,0x3b, + 0x2,0x6b,0x58, 0x3,0x5e,0x2d, 0x2,0x6d,0x4c, 0x1,0x7b,0x5e, + 0x3,0x5f,0x43, 0x1,0x7b,0x5d, 0x2,0x6d,0x4b, 0x1,0x7c,0x35, + 0x3,0x60,0x30, 0x2,0x6f,0x25, 0x4,0x6b,0x68, 0x4,0x6a,0x46, + 0x3,0x21,0x3c, 0x4,0x21,0x2c, 0x1,0x44,0x55, 0x1,0x47,0x7c, + 0x2,0x22,0x3a, 0x2,0x23,0x6a, 0x1,0x4b,0x56, 0x1,0x5a,0x25, + 0x3,0x35,0x57, 0x3,0x4b,0x6c, 0x1,0x44,0x56, 0x1,0x46,0x4a, + 0x1,0x46,0x49, 0x1,0x46,0x48, 0x4,0x22,0x63, 0x1,0x4a,0x27, + 0x1,0x55,0x38, 0x2,0x42,0x5d, 0x1,0x44,0x57, 0x1,0x44,0x58, + 0x1,0x44,0x59, 0x1,0x45,0x3b, 0x3,0x25,0x67, 0x3,0x28,0x60, + 0x1,0x50,0x73, 0x4,0x2c,0x64, 0x2,0x2a,0x30, 0x3,0x2c,0x45, + 0x3,0x2c,0x44, 0x1,0x5e,0x78, 0x1,0x44,0x5a, 0x2,0x21,0x3d, + 0x3,0x21,0x63, 0x4,0x21,0x4c, 0x1,0x46,0x4b, 0x1,0x46,0x4c, + 0x2,0x21,0x59, 0x1,0x47,0x7d, 0x5,0x22,0x5c, 0x3,0x23,0x5c, + 0x3,0x25,0x68, 0x2,0x23,0x6b, 0x3,0x25,0x6b, 0x1,0x4a,0x28, + 0x4,0x24,0x23, 0x2,0x23,0x6c, 0x1,0x4d,0x30, 0x3,0x28,0x62, + 0x3,0x28,0x61, 0x2,0x26,0x4f, 0x1,0x4d,0x2e, 0x1,0x4d,0x2d, + 0x2,0x26,0x4e, 0x1,0x4d,0x2b, 0x2,0x26,0x50, 0x1,0x4d,0x2c, + 0x1,0x4d,0x2f, 0x1,0x50,0x74, 0x3,0x2c,0x46, 0x1,0x50,0x76, + 0x2,0x2a,0x34, 0x2,0x2a,0x31, 0x2,0x2a,0x32, 0x2,0x2a,0x33, + 0x2,0x2a,0x35, 0x1,0x50,0x75, 0x2,0x2e,0x76, 0x2,0x2e,0x75, + 0x3,0x30,0x66, 0x1,0x55,0x3a, 0x3,0x30,0x69, 0x1,0x55,0x39, + 0x3,0x30,0x68, 0x3,0x30,0x6a, 0x3,0x30,0x67, 0x3,0x35,0x5b, + 0x1,0x5a,0x28, 0x2,0x35,0x2a, 0x3,0x35,0x59, 0x1,0x5a,0x27, + 0x1,0x5a,0x29, 0x1,0x5a,0x26, 0x3,0x35,0x58, 0x3,0x35,0x5a, + 0x1,0x5e,0x7a, 0x2,0x35,0x29, 0x5,0x37,0x7c, 0x1,0x5e,0x7b, + 0x2,0x3b,0x57, 0x3,0x39,0x79, 0x1,0x5e,0x7c, 0x2,0x3b,0x56, + 0x1,0x5e,0x79, 0x3,0x3b,0x3a, 0x3,0x3b,0x3b, 0x3,0x3b,0x3d, + 0x2,0x42,0x60, 0x2,0x42,0x62, 0x1,0x63,0x6b, 0x2,0x42,0x61, + 0x2,0x42,0x5f, 0x2,0x42,0x5e, 0x4,0x3d,0x2a, 0x4,0x43,0x35, + 0x3,0x46,0x5d, 0x2,0x49,0x79, 0x1,0x68,0x5f, 0x1,0x68,0x5d, + 0x4,0x43,0x30, 0x1,0x68,0x5e, 0x2,0x49,0x77, 0x2,0x49,0x78, + 0x3,0x4b,0x6d, 0x1,0x68,0x5b, 0x2,0x50,0x3a, 0x2,0x50,0x38, + 0x3,0x4b,0x70, 0x1,0x6c,0x57, 0x2,0x50,0x39, 0x1,0x6c,0x58, + 0x1,0x6c,0x56, 0x1,0x68,0x5c, 0xf,0x4e,0x5e, 0x3,0x64,0x73, + 0x2,0x56,0x77, 0x2,0x56,0x75, 0x2,0x56,0x76, 0x2,0x50,0x37, + 0x2,0x5c,0x68, 0x1,0x73,0x59, 0x2,0x5c,0x67, 0x2,0x61,0x51, + 0x2,0x61,0x52, 0x2,0x56,0x78, 0x2,0x65,0x4a, 0x3,0x66,0x77, + 0x1,0x44,0x5b, 0x1,0x46,0x4d, 0x1,0x48,0x21, 0x2,0x22,0x3b, + 0x1,0x47,0x7e, 0x3,0x28,0x63, 0x1,0x4d,0x31, 0x1,0x63,0x6c, + 0x3,0x21,0x3d, 0x1,0x45,0x3c, 0x1,0x46,0x4e, 0x1,0x50,0x77, + 0x1,0x5e,0x7d, 0x3,0x21,0x3e, 0x2,0x21,0x5a, 0x3,0x22,0x47, + 0x2,0x21,0x5b, 0x3,0x22,0x48, 0x2,0x22,0x3c, 0x3,0x66,0x78, + 0x1,0x4a,0x2a, 0x2,0x23,0x70, 0x2,0x23,0x6e, 0x1,0x4a,0x2b, + 0x2,0x23,0x6d, 0x2,0x23,0x6f, 0x2,0x23,0x71, 0x4,0x24,0x28, + 0x1,0x4a,0x29, 0x3,0x25,0x6e, 0x3,0x25,0x6d, 0x1,0x4d,0x35, + 0x1,0x4d,0x36, 0x1,0x4d,0x33, 0x3,0x28,0x65, 0x3,0x28,0x67, + 0x1,0x4d,0x32, 0x2,0x2a,0x39, 0x1,0x4d,0x34, 0x3,0x28,0x68, + 0x1,0x50,0x78, 0x3,0x2c,0x48, 0x2,0x2a,0x38, 0x2,0x2a,0x3a, + 0x2,0x2a,0x37, 0x2,0x2a,0x3b, 0x1,0x50,0x79, 0x1,0x55,0x3d, + 0x2,0x2e,0x77, 0x3,0x30,0x6c, 0x2,0x2e,0x79, 0x1,0x55,0x3b, + 0x2,0x2e,0x7a, 0x1,0x55,0x3c, 0x2,0x2e,0x78, 0x3,0x30,0x6b, + 0x2,0x2a,0x36, 0x2,0x35,0x2b, 0x2,0x35,0x2e, 0x2,0x35,0x2f, + 0x2,0x35,0x2c, 0x1,0x5a,0x2d, 0x1,0x5a,0x2c, 0x1,0x5a,0x2a, + 0x1,0x5a,0x2b, 0x2,0x35,0x2d, 0x3,0x35,0x61, 0x3,0x35,0x60, + 0x3,0x3b,0x3f, 0x1,0x5a,0x2e, 0x3,0x3b,0x40, 0x3,0x3b,0x3e, + 0x1,0x5f,0x21, 0x1,0x5f,0x22, 0x6,0x48,0x45, 0x1,0x5f,0x23, + 0x2,0x42,0x63, 0x2,0x42,0x65, 0x2,0x42,0x67, 0x1,0x63,0x6e, + 0x1,0x63,0x6d, 0x1,0x5e,0x7e, 0x2,0x42,0x66, 0x2,0x42,0x64, + 0x3,0x64,0x74, 0x2,0x49,0x7d, 0x3,0x46,0x61, 0x3,0x46,0x60, + 0x2,0x49,0x7b, 0x2,0x4a,0x23, 0x1,0x68,0x60, 0x2,0x4a,0x24, + 0x2,0x4a,0x21, 0x1,0x68,0x61, 0x2,0x49,0x7c, 0x2,0x49,0x7a, + 0x2,0x4a,0x22, 0x1,0x6c,0x5a, 0x2,0x50,0x3c, 0x2,0x49,0x7e, + 0x1,0x6c,0x5c, 0x2,0x50,0x3d, 0x1,0x6c,0x5b, 0x1,0x6c,0x5e, + 0x2,0x50,0x3e, 0x1,0x6c,0x59, 0x1,0x6c,0x5d, 0x2,0x56,0x7d, + 0x2,0x56,0x7b, 0x2,0x56,0x7a, 0x2,0x56,0x7c, 0x2,0x56,0x79, + 0x3,0x50,0x5c, 0x4,0x5b,0x21, 0x1,0x78,0x33, 0x3,0x64,0x75, + 0x2,0x68,0x72, 0x2,0x68,0x73, 0x3,0x5c,0x3f, 0x2,0x6b,0x59, + 0x2,0x6d,0x4d, 0x1,0x7d,0x22, 0x3,0x21,0x3f, 0x3,0x23,0x61, + 0x1,0x4d,0x37, 0x1,0x4a,0x2c, 0x3,0x28,0x69, 0x3,0x28,0x6b, + 0x1,0x50,0x7a, 0x3,0x2c,0x4c, 0x3,0x2c,0x4b, 0x3,0x30,0x6e, + 0x1,0x44,0x5c, 0x1,0x45,0x3d, 0x4,0x21,0x4d, 0x1,0x46,0x4f, + 0x2,0x22,0x3d, 0x3,0x25,0x6f, 0x1,0x4a,0x2d, 0x2,0x23,0x72, + 0x3,0x28,0x6d, 0x2,0x2a,0x3c, 0x1,0x50,0x7b, 0x1,0x68,0x62, + 0x1,0x44,0x5d, 0x3,0x21,0x64, 0x3,0x22,0x49, 0x3,0x23,0x62, + 0x1,0x48,0x22, 0xf,0x22,0x4e, 0x3,0x3b,0x42, 0x1,0x63,0x6f, + 0x1,0x44,0x5e, 0x1,0x45,0x3e, 0x1,0x45,0x3f, 0x1,0x46,0x51, + 0x1,0x46,0x50, 0x4,0x22,0x6b, 0x2,0x22,0x3e, 0x1,0x48,0x23, + 0x4,0x22,0x6c, 0x2,0x23,0x73, 0x3,0x25,0x71, 0x1,0x4a,0x2e, + 0x3,0x28,0x6e, 0x2,0x26,0x52, 0x2,0x26,0x53, 0x2,0x26,0x54, + 0x3,0x28,0x70, 0x1,0x4d,0x38, 0x1,0x4d,0x39, 0x2,0x26,0x51, + 0x1,0x4d,0x3a, 0x4,0x29,0x2c, 0x4,0x2c,0x70, 0x1,0x50,0x7c, + 0x2,0x2a,0x3d, 0x3,0x2c,0x4d, 0x2,0x2e,0x7c, 0x1,0x55,0x3e, + 0x3,0x30,0x6f, 0x2,0x2e,0x7b, 0x3,0x35,0x62, 0x1,0x5a,0x2f, + 0x2,0x35,0x30, 0x1,0x5a,0x30, 0x2,0x35,0x31, 0x3,0x35,0x63, + 0x3,0x3b,0x47, 0x3,0x3b,0x45, 0x1,0x5f,0x24, 0x4,0x37,0x45, + 0x3,0x3b,0x44, 0x4,0x3d,0x30, 0x2,0x42,0x68, 0xf,0x41,0x3f, + 0x3,0x41,0x22, 0x2,0x4a,0x26, 0x2,0x4a,0x25, 0x1,0x68,0x63, + 0x4,0x49,0x5e, 0x1,0x6c,0x5f, 0x2,0x50,0x3f, 0x1,0x70,0x53, + 0x2,0x56,0x7e, 0x1,0x73,0x5a, 0x3,0x57,0x63, 0x1,0x7b,0x5f, + 0x2,0x6f,0x27, 0x3,0x21,0x40, 0x3,0x21,0x41, 0x3,0x22,0x4a, + 0x3,0x23,0x51, 0x2,0x26,0x55, 0x3,0x28,0x71, 0x2,0x2a,0x3e, + 0x1,0x5a,0x31, 0x2,0x3b,0x58, 0x1,0x63,0x70, 0x3,0x41,0x23, + 0x3,0x50,0x5e, 0xf,0x54,0x43, 0x3,0x57,0x64, 0x1,0x76,0x41, + 0x3,0x61,0x64, 0x3,0x21,0x42, 0x1,0x4a,0x30, 0x3,0x25,0x72, + 0x1,0x4a,0x2f, 0x1,0x50,0x7d, 0x3,0x2c,0x50, 0x2,0x2e,0x7d, + 0x1,0x5a,0x33, 0x1,0x5d,0x29, 0x1,0x5a,0x34, 0x1,0x5a,0x32, + 0x1,0x5f,0x25, 0x3,0x41,0x24, 0x2,0x4a,0x27, 0x1,0x68,0x64, + 0x1,0x6c,0x60, 0x3,0x5f,0x45, 0x2,0x21,0x2c, 0x2,0x22,0x3f, + 0x4,0x22,0x6d, 0x2,0x23,0x75, 0x1,0x4a,0x31, 0x2,0x23,0x74, + 0x1,0x4a,0x32, 0x4,0x24,0x2c, 0x1,0x4d,0x3e, 0x2,0x26,0x58, + 0x2,0x26,0x57, 0x1,0x4d,0x3d, 0x1,0x4d,0x3b, 0x1,0x4d,0x3c, + 0x2,0x26,0x56, 0x3,0x28,0x76, 0x3,0x28,0x75, 0x1,0x51,0x21, + 0x2,0x2a,0x3f, 0x1,0x51,0x24, 0x1,0x50,0x7e, 0x1,0x51,0x26, + 0x1,0x51,0x22, 0x1,0x51,0x23, 0x1,0x51,0x25, 0x4,0x29,0x31, + 0x3,0x30,0x70, 0x3,0x30,0x72, 0x1,0x55,0x41, 0x1,0x55,0x40, + 0x1,0x55,0x3f, 0x3,0x30,0x71, 0x3,0x64,0x76, 0x2,0x35,0x33, + 0x1,0x5a,0x35, 0x1,0x5a,0x38, 0x1,0x5a,0x36, 0x3,0x64,0x77, + 0x2,0x35,0x32, 0x1,0x5a,0x3b, 0x4,0x31,0x53, 0x1,0x5a,0x37, + 0x2,0x35,0x34, 0x1,0x5a,0x3a, 0x1,0x5a,0x39, 0x4,0x31,0x52, + 0x4,0x31,0x57, 0x4,0x37,0x4a, 0x2,0x3b,0x5a, 0x2,0x3b,0x59, + 0x3,0x3b,0x4b, 0x1,0x5f,0x28, 0x1,0x5f,0x26, 0x1,0x5f,0x27, + 0x2,0x3b,0x5b, 0x1,0x63,0x71, 0x2,0x42,0x6a, 0x1,0x63,0x72, + 0x2,0x42,0x69, 0x4,0x3d,0x34, 0x4,0x43,0x3f, 0x2,0x50,0x40, + 0x3,0x46,0x63, 0x3,0x46,0x64, 0x1,0x6c,0x62, 0x2,0x4a,0x28, + 0x1,0x6c,0x61, 0x3,0x4b,0x72, 0x1,0x68,0x65, 0x3,0x64,0x78, + 0x2,0x57,0x22, 0x2,0x57,0x21, 0x1,0x73,0x5b, 0x2,0x5c,0x69, + 0x2,0x65,0x4b, 0x2,0x68,0x74, 0x2,0x68,0x75, 0x3,0x5e,0x2f, + 0x1,0x45,0x40, 0x4,0x21,0x36, 0x1,0x46,0x52, 0x3,0x22,0x4d, + 0x4,0x22,0x71, 0x2,0x21,0x5c, 0x3,0x22,0x4c, 0x5,0x22,0x66, + 0x1,0x4a,0x34, 0x1,0x4a,0x36, 0x3,0x25,0x78, 0x2,0x22,0x42, + 0x2,0x23,0x78, 0x2,0x23,0x77, 0x2,0x23,0x76, 0x3,0x23,0x66, + 0x2,0x22,0x41, 0x2,0x22,0x40, 0x1,0x48,0x25, 0x1,0x4a,0x35, + 0x1,0x4a,0x33, 0x1,0x48,0x24, 0x3,0x23,0x67, 0x3,0x23,0x69, + 0x3,0x25,0x77, 0x1,0x4d,0x3f, 0x2,0x26,0x59, 0x3,0x25,0x7b, + 0x1,0x4d,0x40, 0x2,0x23,0x7d, 0x4,0x26,0x50, 0x2,0x24,0x21, + 0x2,0x23,0x7e, 0x2,0x26,0x5a, 0x3,0x25,0x76, 0x3,0x25,0x74, + 0x2,0x23,0x7a, 0x3,0x28,0x7e, 0x1,0x4a,0x3a, 0x1,0x4a,0x38, + 0x3,0x25,0x7c, 0x2,0x23,0x79, 0x2,0x23,0x7b, 0x2,0x24,0x23, + 0x3,0x26,0x22, 0x1,0x4a,0x37, 0x3,0x26,0x21, 0x2,0x23,0x7c, + 0x2,0x24,0x27, 0x1,0x4d,0x42, 0x3,0x25,0x7d, 0x2,0x24,0x24, + 0x1,0x4a,0x39, 0x3,0x26,0x23, 0x2,0x24,0x22, 0x2,0x24,0x25, + 0x3,0x25,0x7a, 0x1,0x4d,0x41, 0x3,0x25,0x75, 0x1,0x4d,0x43, + 0x2,0x24,0x26, 0x3,0x28,0x78, 0x3,0x29,0x22, 0x2,0x26,0x6e, + 0x2,0x26,0x61, 0x2,0x26,0x5f, 0x2,0x26,0x6d, 0x2,0x26,0x68, + 0x1,0x51,0x2b, 0x1,0x4d,0x44, 0x2,0x26,0x69, 0x2,0x26,0x6c, + 0x1,0x51,0x27, 0x2,0x26,0x6b, 0x1,0x4d,0x45, 0x1,0x4d,0x4a, + 0x1,0x4d,0x48, 0x2,0x26,0x62, 0x4,0x29,0x36, 0x2,0x26,0x5d, + 0x2,0x26,0x64, 0x1,0x4d,0x4f, 0x2,0x26,0x6f, 0x1,0x51,0x28, + 0x2,0x26,0x65, 0x4,0x26,0x4f, 0x1,0x51,0x29, 0x1,0x4d,0x4b, + 0x2,0x26,0x67, 0x3,0x2c,0x5a, 0x2,0x2a,0x4e, 0x1,0x51,0x2a, + 0x2,0x26,0x5c, 0x1,0x4d,0x4c, 0x1,0x51,0x2c, 0x1,0x4d,0x4d, + 0x1,0x4d,0x49, 0x1,0x4d,0x4e, 0x2,0x26,0x66, 0x2,0x26,0x5b, + 0x2,0x26,0x6a, 0x1,0x4d,0x46, 0x3,0x28,0x77, 0x3,0x2c,0x5b, + 0x2,0x26,0x5e, 0x2,0x26,0x63, 0x2,0x26,0x60, 0x1,0x4d,0x47, + 0x3,0x28,0x7a, 0x2,0x2a,0x40, 0x4,0x29,0x45, 0x2,0x2a,0x41, + 0x3,0x29,0x21, 0x2,0x2a,0x4b, 0x2,0x2f,0x23, 0x2,0x2a,0x4c, + 0x1,0x51,0x32, 0x2,0x2a,0x4f, 0x2,0x2a,0x45, 0x1,0x51,0x31, + 0x2,0x2a,0x47, 0x4,0x29,0x3f, 0x2,0x2a,0x48, 0x3,0x2c,0x60, + 0x3,0x30,0x79, 0x2,0x2a,0x4a, 0x1,0x51,0x2d, 0x3,0x2c,0x56, + 0x3,0x30,0x73, 0x1,0x55,0x45, 0x3,0x2c,0x57, 0x3,0x2c,0x5d, + 0x2,0x2a,0x46, 0x2,0x2a,0x42, 0x1,0x55,0x46, 0x3,0x30,0x7e, + 0x4,0x29,0x3e, 0x2,0x2a,0x50, 0x1,0x55,0x42, 0x2,0x2f,0x21, + 0x2,0x2a,0x49, 0x3,0x2c,0x54, 0x2,0x2e,0x7e, 0x2,0x2a,0x44, + 0x2,0x2a,0x4d, 0x3,0x2c,0x5f, 0x3,0x2c,0x61, 0x1,0x51,0x30, + 0x1,0x55,0x43, 0x1,0x51,0x36, 0x1,0x55,0x44, 0x2,0x2a,0x51, + 0x2,0x2f,0x22, 0x1,0x51,0x2f, 0x1,0x55,0x48, 0x1,0x51,0x35, + 0x1,0x51,0x34, 0x1,0x51,0x33, 0x1,0x55,0x47, 0x2,0x2a,0x52, + 0x1,0x55,0x49, 0x1,0x51,0x2e, 0x4,0x29,0x4b, 0x2,0x2a,0x43, + 0x3,0x30,0x7a, 0x3,0x30,0x78, 0x3,0x30,0x7b, 0x3,0x2c,0x5c, + 0x3,0x30,0x76, 0x1,0x5a,0x3c, 0x2,0x2f,0x26, 0x2,0x2f,0x28, + 0x4,0x2d,0x25, 0x2,0x2f,0x2a, 0x1,0x55,0x4a, 0x1,0x55,0x50, + 0x2,0x35,0x37, 0x2,0x2f,0x2e, 0x2,0x2f,0x25, 0x1,0x5a,0x3e, + 0x2,0x35,0x35, 0x3,0x31,0x22, 0x1,0x55,0x4f, 0x1,0x55,0x4d, + 0x2,0x2f,0x30, 0x4,0x2d,0x2d, 0x2,0x35,0x36, 0x4,0x2d,0x2c, + 0x2,0x2f,0x27, 0x3,0x31,0x25, 0x1,0x55,0x4e, 0x2,0x2f,0x2b, + 0x1,0x55,0x51, 0x2,0x2f,0x2d, 0x3,0x35,0x68, 0x3,0x30,0x74, + 0x1,0x55,0x4c, 0x2,0x2f,0x2c, 0x2,0x2f,0x2f, 0x2,0x2f,0x29, + 0x3,0x31,0x27, 0x1,0x55,0x4b, 0x1,0x5a,0x3f, 0x3,0x35,0x71, + 0x2,0x2f,0x24, 0x1,0x5a,0x3d, 0x3,0x35,0x72, 0x4,0x31,0x6b, + 0x3,0x31,0x23, 0x3,0x31,0x28, 0x1,0x5a,0x40, 0x3,0x31,0x21, + 0x3,0x35,0x6f, 0x3,0x31,0x26, 0x2,0x35,0x39, 0x2,0x35,0x42, + 0x1,0x5f,0x2b, 0x3,0x3b,0x54, 0x1,0x5a,0x42, 0x1,0x5a,0x47, + 0x1,0x5f,0x2c, 0x2,0x35,0x44, 0x1,0x5a,0x4e, 0x2,0x3b,0x5d, + 0x2,0x35,0x3a, 0x1,0x5a,0x46, 0x1,0x5a,0x49, 0x1,0x5a,0x44, + 0x2,0x35,0x38, 0x2,0x35,0x46, 0x2,0x35,0x49, 0x2,0x3b,0x6c, + 0x4,0x31,0x68, 0x2,0x35,0x47, 0x2,0x3b,0x61, 0x1,0x5a,0x45, + 0x1,0x5a,0x4c, 0x1,0x5a,0x50, 0x2,0x35,0x41, 0x2,0x3b,0x5c, + 0x2,0x35,0x45, 0x1,0x5a,0x41, 0x2,0x3b,0x5e, 0x2,0x35,0x48, + 0x2,0x3b,0x60, 0x2,0x35,0x3d, 0x3,0x35,0x6a, 0x1,0x5f,0x29, + 0x3,0x3b,0x56, 0x2,0x35,0x3b, 0x2,0x35,0x3c, 0x1,0x5a,0x4b, + 0x3,0x3b,0x55, 0x3,0x35,0x6e, 0x1,0x5a,0x4a, 0x2,0x35,0x3f, + 0x1,0x5a,0x4f, 0x2,0x35,0x43, 0x1,0x5a,0x48, 0x2,0x35,0x40, + 0x3,0x35,0x79, 0x1,0x5a,0x4d, 0x1,0x5f,0x2d, 0x1,0x5f,0x2a, + 0x2,0x3b,0x5f, 0x3,0x3b,0x58, 0x2,0x35,0x3e, 0x3,0x3b,0x59, + 0x1,0x5a,0x43, 0x3,0x35,0x76, 0x3,0x35,0x78, 0x3,0x3b,0x5a, + 0x3,0x3b,0x4d, 0x3,0x35,0x74, 0x1,0x5f,0x32, 0x1,0x5f,0x36, + 0x2,0x3b,0x63, 0x1,0x63,0x77, 0x1,0x5f,0x34, 0x2,0x3b,0x67, + 0x1,0x5f,0x38, 0x2,0x42,0x6b, 0x2,0x3b,0x69, 0x1,0x63,0x79, + 0x1,0x5f,0x30, 0x1,0x5f,0x33, 0x2,0x3b,0x6a, 0x3,0x3b,0x5e, + 0x2,0x3b,0x6b, 0x2,0x3b,0x71, 0x1,0x5f,0x3a, 0x1,0x63,0x7a, + 0x4,0x3d,0x3d, 0x2,0x3b,0x6d, 0x2,0x3b,0x72, 0x2,0x3b,0x66, + 0x1,0x64,0x26, 0x3,0x3b,0x4f, 0x1,0x63,0x7b, 0x1,0x5f,0x39, + 0x2,0x3b,0x64, 0x2,0x3b,0x73, 0x3,0x3b,0x51, 0x1,0x64,0x25, + 0x1,0x5f,0x37, 0x1,0x63,0x74, 0x2,0x3b,0x70, 0x3,0x3b,0x5d, + 0x1,0x5f,0x3b, 0x2,0x3b,0x68, 0x2,0x3b,0x62, 0x1,0x5f,0x31, + 0x2,0x3b,0x65, 0x5,0x3f,0x30, 0x2,0x3b,0x6e, 0x3,0x41,0x2b, + 0x1,0x63,0x73, 0x1,0x63,0x78, 0x1,0x5f,0x2e, 0x2,0x3b,0x6f, + 0x3,0x3b,0x61, 0x1,0x63,0x76, 0x3,0x3b,0x62, 0x3,0x3b,0x63, + 0x3,0x3b,0x50, 0x1,0x5f,0x2f, 0x3,0x64,0x79, 0x1,0x64,0x24, + 0x2,0x4a,0x2a, 0x2,0x42,0x76, 0x3,0x41,0x29, 0x2,0x42,0x6e, + 0x2,0x4a,0x29, 0x4,0x3d,0x39, 0x2,0x42,0x72, 0x2,0x42,0x74, + 0x3,0x41,0x27, 0x3,0x41,0x2c, 0x2,0x42,0x71, 0x3,0x46,0x6f, + 0x1,0x64,0x23, 0x4,0x3d,0x38, 0x2,0x42,0x70, 0x1,0x64,0x27, + 0x3,0x46,0x6e, 0x6,0x52,0x64, 0x3,0x41,0x28, 0x2,0x4a,0x39, + 0x3,0x46,0x6c, 0x3,0x41,0x2e, 0x1,0x64,0x22, 0x1,0x68,0x67, + 0x2,0x42,0x77, 0x2,0x4a,0x2b, 0x3,0x46,0x6d, 0x3,0x41,0x2a, + 0x1,0x63,0x7e, 0x2,0x42,0x6f, 0x2,0x42,0x73, 0x1,0x68,0x66, + 0x1,0x63,0x75, 0x2,0x42,0x6c, 0x2,0x42,0x6d, 0x1,0x68,0x68, + 0x1,0x63,0x7d, 0x1,0x64,0x21, 0x1,0x63,0x7c, 0x2,0x42,0x75, + 0x3,0x64,0x7a, 0x2,0x4a,0x2f, 0x2,0x4a,0x30, 0x2,0x4a,0x35, + 0x1,0x6c,0x67, 0x2,0x4a,0x3c, 0x3,0x4b,0x73, 0x1,0x68,0x6e, + 0x3,0x4b,0x7e, 0x1,0x68,0x6d, 0x2,0x4a,0x37, 0x3,0x4b,0x74, + 0x1,0x6c,0x66, 0x2,0x4a,0x2c, 0x1,0x68,0x6c, 0x3,0x46,0x71, + 0x2,0x4a,0x3b, 0x1,0x68,0x6a, 0x1,0x68,0x6b, 0x3,0x4b,0x7c, + 0x2,0x4a,0x38, 0x2,0x50,0x51, 0x1,0x6c,0x64, 0x1,0x5f,0x35, + 0x3,0x46,0x72, 0x2,0x4a,0x3a, 0x1,0x6c,0x6b, 0x2,0x4a,0x32, + 0x4,0x49,0x6f, 0x1,0x6c,0x65, 0x3,0x46,0x6a, 0x1,0x6c,0x6a, + 0x2,0x4a,0x2d, 0x2,0x4a,0x31, 0x2,0x4a,0x2e, 0x2,0x4a,0x34, + 0x1,0x68,0x6f, 0x1,0x6c,0x63, 0x1,0x68,0x69, 0x3,0x4c,0x21, + 0x2,0x50,0x43, 0x2,0x4a,0x36, 0x3,0x46,0x68, 0x1,0x6c,0x69, + 0x3,0x46,0x73, 0x1,0x6c,0x6c, 0x7,0x22,0x71, 0x2,0x4a,0x33, + 0x3,0x46,0x6b, 0x1,0x6c,0x68, 0x2,0x50,0x42, 0x5,0x4d,0x2a, + 0x3,0x4c,0x23, 0x3,0x46,0x74, 0x3,0x4c,0x24, 0x3,0x4b,0x77, + 0x2,0x50,0x47, 0x1,0x70,0x57, 0x2,0x50,0x41, 0x2,0x57,0x2e, + 0x2,0x50,0x50, 0x1,0x6c,0x70, 0x3,0x4b,0x7a, 0x1,0x6c,0x6e, + 0x1,0x70,0x55, 0x2,0x50,0x4d, 0x2,0x50,0x49, 0x1,0x6c,0x74, + 0x3,0x4b,0x76, 0x2,0x57,0x25, 0x3,0x50,0x68, 0x3,0x4c,0x28, + 0x3,0x50,0x67, 0x1,0x6c,0x72, 0x2,0x50,0x48, 0x3,0x4c,0x29, + 0x2,0x57,0x23, 0x3,0x4c,0x25, 0x2,0x50,0x4c, 0x4,0x50,0x3b, + 0x2,0x50,0x4f, 0x2,0x50,0x46, 0x3,0x4b,0x79, 0x1,0x6c,0x73, + 0x4,0x50,0x37, 0x3,0x4b,0x75, 0x1,0x6c,0x6d, 0x2,0x57,0x24, + 0x1,0x70,0x56, 0x2,0x50,0x4e, 0x1,0x6c,0x6f, 0x1,0x6c,0x71, + 0x2,0x50,0x4b, 0x1,0x6c,0x75, 0x2,0x50,0x4a, 0x2,0x50,0x45, + 0x2,0x50,0x44, 0x1,0x70,0x54, 0x2,0x50,0x52, 0x2,0x57,0x27, + 0x2,0x5c,0x6b, 0x1,0x70,0x59, 0x3,0x50,0x61, 0x2,0x57,0x2d, + 0x3,0x50,0x63, 0x2,0x57,0x2b, 0x3,0x50,0x6a, 0x2,0x5c,0x6c, + 0x3,0x50,0x64, 0x1,0x70,0x5a, 0x2,0x57,0x2c, 0x3,0x50,0x66, + 0x2,0x57,0x29, 0x1,0x73,0x5d, 0x2,0x5c,0x6a, 0x3,0x50,0x6c, + 0x2,0x57,0x26, 0x2,0x57,0x28, 0x1,0x73,0x5e, 0x1,0x70,0x5c, + 0x1,0x73,0x5c, 0x1,0x70,0x5b, 0x1,0x73,0x60, 0x2,0x57,0x2a, + 0x1,0x70,0x58, 0x3,0x50,0x62, 0x3,0x50,0x65, 0x3,0x50,0x6b, + 0x3,0x66,0x79, 0x4,0x5b,0x2b, 0x2,0x61,0x5b, 0x4,0x56,0x33, + 0x2,0x61,0x53, 0x3,0x54,0x61, 0x3,0x54,0x5f, 0x3,0x54,0x5c, + 0x3,0x54,0x5e, 0x3,0x54,0x5d, 0x2,0x5c,0x72, 0x2,0x61,0x54, + 0x2,0x5c,0x6e, 0x4,0x56,0x32, 0x3,0x54,0x5b, 0x1,0x76,0x42, + 0x2,0x5c,0x70, 0x2,0x5c,0x6f, 0x1,0x73,0x5f, 0x2,0x5c,0x6d, + 0x2,0x5c,0x71, 0x2,0x61,0x5c, 0x2,0x61,0x58, 0x2,0x61,0x5a, + 0x4,0x5f,0x60, 0x2,0x61,0x55, 0x2,0x61,0x56, 0x4,0x5f,0x61, + 0x2,0x61,0x59, 0x2,0x61,0x57, 0x1,0x78,0x34, 0x3,0x57,0x65, + 0x1,0x78,0x37, 0x1,0x78,0x36, 0x1,0x78,0x35, 0x1,0x79,0x6c, + 0x2,0x68,0x76, 0x1,0x79,0x6d, 0x2,0x65,0x4c, 0x1,0x7a,0x6a, + 0x2,0x6b,0x5a, 0x1,0x7a,0x6b, 0x1,0x7b,0x60, 0x1,0x7c,0x36, + 0x2,0x6f,0x28, 0x3,0x5f,0x46, 0x2,0x6f,0x29, 0x2,0x6f,0x2a, + 0x3,0x61,0x3e, 0x2,0x72,0x2a, 0x1,0x45,0x41, 0x2,0x21,0x5d, + 0x1,0x46,0x53, 0x1,0x48,0x27, 0x1,0x48,0x28, 0x1,0x48,0x26, + 0x3,0x23,0x6b, 0x1,0x48,0x29, 0x1,0x4a,0x3c, 0x1,0x4a,0x3b, + 0x3,0x26,0x25, 0x2,0x26,0x70, 0x1,0x4d,0x51, 0x1,0x4d,0x50, + 0x3,0x2c,0x63, 0x2,0x2f,0x31, 0x1,0x5a,0x51, 0x1,0x5a,0x52, + 0x4,0x31,0x6e, 0x4,0x31,0x70, 0x3,0x3b,0x64, 0x1,0x5f,0x3c, + 0x2,0x42,0x78, 0x1,0x64,0x28, 0x1,0x64,0x29, 0x2,0x42,0x7a, + 0x2,0x42,0x7c, 0x2,0x42,0x7b, 0x4,0x3d,0x43, 0x2,0x4a,0x3e, + 0x3,0x46,0x76, 0x2,0x4a,0x3d, 0x1,0x68,0x70, 0x2,0x4a,0x3f, + 0x3,0x46,0x75, 0x2,0x50,0x53, 0x1,0x6c,0x76, 0x3,0x4c,0x2c, + 0x1,0x70,0x5d, 0x3,0x50,0x6d, 0x1,0x73,0x61, 0x1,0x76,0x43, + 0x1,0x73,0x62, 0x3,0x5f,0x48, 0x1,0x45,0x42, 0x3,0x21,0x65, + 0x3,0x21,0x66, 0x3,0x22,0x4e, 0x2,0x24,0x28, 0x3,0x26,0x28, + 0x3,0x26,0x29, 0x2,0x26,0x71, 0x1,0x4d,0x53, 0x1,0x4d,0x52, + 0x1,0x4d,0x54, 0x1,0x51,0x37, 0x2,0x2a,0x53, 0x2,0x2a,0x54, + 0x3,0x31,0x29, 0x2,0x2f,0x32, 0x1,0x55,0x52, 0x1,0x5a,0x53, + 0x1,0x5f,0x3d, 0x2,0x3b,0x74, 0x1,0x45,0x43, 0x4,0x21,0x37, + 0x1,0x44,0x5f, 0x1,0x45,0x44, 0x3,0x22,0x50, 0x2,0x21,0x5e, + 0x1,0x46,0x57, 0x1,0x46,0x56, 0x1,0x46,0x54, 0x1,0x46,0x55, + 0x3,0x23,0x6f, 0x1,0x48,0x2c, 0x2,0x22,0x49, 0x2,0x22,0x4b, + 0x1,0x48,0x2b, 0x2,0x22,0x43, 0x3,0x23,0x6c, 0x2,0x22,0x44, + 0x3,0x23,0x6d, 0x2,0x22,0x4a, 0x2,0x22,0x46, 0x2,0x22,0x48, + 0x1,0x48,0x2a, 0x2,0x22,0x45, 0x2,0x22,0x4c, 0x2,0x22,0x47, + 0x3,0x23,0x6e, 0xf,0x22,0x51, 0x1,0x4a,0x43, 0x1,0x4a,0x4c, + 0x1,0x4a,0x4a, 0x2,0x24,0x32, 0x2,0x24,0x2f, 0x2,0x24,0x37, + 0x1,0x4a,0x48, 0x2,0x24,0x38, 0x3,0x26,0x39, 0x1,0x4a,0x41, + 0x2,0x24,0x35, 0x3,0x26,0x2e, 0x1,0x4a,0x47, 0x2,0x24,0x31, + 0x2,0x24,0x30, 0x1,0x4a,0x45, 0x2,0x24,0x36, 0x1,0x4a,0x46, + 0x1,0x4d,0x55, 0x1,0x4a,0x40, 0x2,0x24,0x33, 0x3,0x26,0x2a, + 0x2,0x24,0x29, 0x1,0x4a,0x3d, 0x3,0x26,0x37, 0x1,0x4a,0x50, + 0x2,0x24,0x2e, 0x2,0x24,0x34, 0x1,0x4a,0x42, 0x1,0x4a,0x44, + 0x3,0x26,0x2f, 0x2,0x24,0x2a, 0x3,0x26,0x36, 0x2,0x24,0x2b, + 0x2,0x24,0x2c, 0x4,0x24,0x39, 0x1,0x4a,0x4f, 0x1,0x4a,0x49, + 0x1,0x4a,0x4e, 0x2,0x24,0x2d, 0x1,0x4a,0x4d, 0x1,0x4a,0x3f, + 0x1,0x4a,0x3e, 0x1,0x4a,0x4b, 0x3,0x26,0x35, 0x4,0x24,0x3c, + 0x3,0x26,0x33, 0x3,0x26,0x34, 0x3,0x26,0x38, 0x3,0x26,0x31, + 0x3,0x64,0x7b, 0xf,0x24,0x39, 0x3,0x26,0x32, 0x3,0x29,0x31, + 0x3,0x29,0x2a, 0x1,0x4d,0x63, 0x2,0x26,0x7d, 0x2,0x26,0x76, + 0x1,0x4d,0x5e, 0x1,0x4d,0x71, 0x2,0x26,0x72, 0x2,0x26,0x79, + 0x2,0x26,0x7b, 0x2,0x26,0x7e, 0x1,0x4d,0x6c, 0x3,0x29,0x26, + 0x2,0x26,0x7a, 0x2,0x26,0x73, 0x1,0x4d,0x6a, 0x2,0x26,0x77, + 0x3,0x29,0x28, 0x2,0x27,0x21, 0x1,0x4d,0x5b, 0x3,0x29,0x25, + 0x2,0x26,0x7c, 0x1,0x4d,0x65, 0x1,0x4d,0x64, 0x2,0x26,0x75, + 0x1,0x4d,0x59, 0x3,0x29,0x34, 0x3,0x29,0x32, 0x1,0x4d,0x5a, + 0xf,0x27,0x30, 0x1,0x4d,0x58, 0x3,0x29,0x33, 0x1,0x4d,0x70, + 0x1,0x4d,0x68, 0x1,0x4d,0x62, 0x1,0x4d,0x56, 0x2,0x26,0x78, + 0x1,0x4d,0x61, 0x1,0x4d,0x57, 0x1,0x4d,0x69, 0x1,0x4d,0x72, + 0x2,0x2a,0x55, 0x1,0x4d,0x66, 0x2,0x26,0x74, 0x1,0x4d,0x5c, + 0x1,0x4d,0x5f, 0x1,0x4d,0x60, 0x3,0x29,0x2e, 0x1,0x4d,0x6e, + 0x1,0x4d,0x6f, 0x1,0x4d,0x6d, 0x1,0x4d,0x67, 0x1,0x4d,0x6b, + 0x1,0x4d,0x5d, 0x1,0x51,0x38, 0x3,0x29,0x30, 0x3,0x29,0x37, + 0x3,0x29,0x35, 0x3,0x29,0x36, 0x3,0x29,0x2f, 0x3,0x29,0x29, + 0x3,0x2c,0x6d, 0x2,0x2a,0x5b, 0x1,0x51,0x44, 0x1,0x51,0x3c, + 0x1,0x51,0x3e, 0x1,0x51,0x43, 0x2,0x2a,0x67, 0x1,0x51,0x41, + 0x2,0x2f,0x33, 0x1,0x55,0x53, 0x1,0x51,0x46, 0x2,0x2a,0x58, + 0x2,0x2a,0x60, 0x1,0x51,0x42, 0x2,0x2a,0x5f, 0x2,0x2a,0x5c, + 0x2,0x2a,0x64, 0x2,0x2a,0x66, 0x1,0x51,0x3b, 0x1,0x51,0x3f, + 0x1,0x51,0x45, 0x1,0x55,0x55, 0x2,0x2a,0x61, 0x1,0x51,0x3d, + 0x1,0x51,0x48, 0x2,0x2a,0x5a, 0x3,0x2c,0x6f, 0x3,0x2c,0x70, + 0x5,0x29,0x45, 0x1,0x51,0x40, 0x1,0x55,0x54, 0x1,0x51,0x3a, + 0x4,0x29,0x59, 0x2,0x2a,0x57, 0x2,0x2a,0x5e, 0x2,0x2a,0x56, + 0x2,0x2a,0x59, 0x2,0x2a,0x5d, 0x2,0x2f,0x34, 0x1,0x51,0x47, + 0x4,0x29,0x51, 0x2,0x2a,0x62, 0x2,0x2a,0x63, 0x2,0x2a,0x65, + 0x1,0x51,0x39, 0x3,0x2c,0x6c, 0x3,0x31,0x32, 0x3,0x31,0x33, + 0x3,0x2c,0x6b, 0x3,0x2c,0x6e, 0x4,0x29,0x5b, 0x1,0x55,0x63, + 0x2,0x2f,0x40, 0x1,0x55,0x61, 0x1,0x55,0x62, 0x2,0x2f,0x36, + 0x2,0x2f,0x46, 0x3,0x31,0x2c, 0x1,0x55,0x58, 0x3,0x31,0x2f, + 0x3,0x31,0x35, 0x2,0x35,0x4a, 0x2,0x2f,0x48, 0x2,0x2f,0x42, + 0x3,0x31,0x38, 0x2,0x2f,0x39, 0x3,0x31,0x37, 0x2,0x2f,0x4b, + 0x2,0x2f,0x3c, 0x1,0x55,0x5e, 0x2,0x35,0x61, 0x2,0x2f,0x3f, + 0x1,0x55,0x60, 0x1,0x55,0x57, 0x3,0x31,0x3c, 0x2,0x2f,0x4d, + 0x2,0x2f,0x41, 0x1,0x55,0x5a, 0x2,0x2f,0x3a, 0x2,0x2f,0x37, + 0x2,0x2f,0x38, 0x1,0x55,0x5b, 0x2,0x2f,0x47, 0x2,0x2f,0x4e, + 0x1,0x55,0x5d, 0x2,0x2f,0x3e, 0x2,0x2f,0x3d, 0x1,0x55,0x65, + 0x1,0x55,0x64, 0x1,0x55,0x56, 0x1,0x55,0x5c, 0x1,0x55,0x5f, + 0x2,0x2f,0x4a, 0x3,0x31,0x2e, 0x3,0x31,0x39, 0x2,0x2f,0x44, + 0x1,0x55,0x59, 0x2,0x2f,0x35, 0x2,0x2f,0x4c, 0x2,0x2f,0x43, + 0x2,0x2f,0x45, 0x2,0x2f,0x49, 0x3,0x31,0x30, 0x3,0x31,0x3b, + 0x3,0x31,0x36, 0x3,0x64,0x7c, 0x3,0x64,0x7d, 0x2,0x35,0x4b, + 0x3,0x36,0x31, 0x1,0x5a,0x5b, 0x1,0x5a,0x6f, 0x1,0x5a,0x6e, + 0x3,0x36,0x27, 0x1,0x5a,0x63, 0x3,0x36,0x29, 0x2,0x35,0x5d, + 0x2,0x35,0x59, 0x2,0x35,0x56, 0x2,0x35,0x68, 0x1,0x5a,0x5e, + 0x1,0x5a,0x56, 0x3,0x36,0x26, 0x3,0x36,0x32, 0x2,0x35,0x5b, + 0x1,0x5f,0x4d, 0x1,0x5a,0x5a, 0x2,0x35,0x63, 0x3,0x36,0x22, + 0x1,0x5a,0x70, 0x1,0x5a,0x6d, 0x2,0x35,0x5f, 0x2,0x35,0x4e, + 0x3,0x35,0x7c, 0x3,0x36,0x2b, 0x1,0x5a,0x6c, 0x2,0x35,0x65, + 0x2,0x35,0x4d, 0x1,0x5a,0x61, 0x1,0x5a,0x65, 0x2,0x35,0x64, + 0x3,0x36,0x23, 0x2,0x35,0x57, 0x1,0x5a,0x66, 0x1,0x5a,0x60, + 0x2,0x35,0x4c, 0x3,0x35,0x7d, 0x1,0x5f,0x3f, 0x2,0x35,0x67, + 0x2,0x35,0x55, 0x1,0x5a,0x6b, 0x2,0x35,0x58, 0x2,0x35,0x66, + 0x1,0x5a,0x6a, 0x3,0x36,0x24, 0x2,0x3b,0x75, 0x4,0x31,0x77, + 0x1,0x5a,0x57, 0x2,0x35,0x53, 0x1,0x5a,0x5c, 0x1,0x5a,0x67, + 0x4,0x31,0x78, 0x1,0x5a,0x62, 0x2,0x35,0x5c, 0x2,0x35,0x52, + 0x2,0x35,0x50, 0x2,0x35,0x62, 0x1,0x5a,0x54, 0x1,0x5a,0x68, + 0x1,0x5a,0x58, 0x1,0x5f,0x3e, 0x2,0x35,0x60, 0x1,0x5a,0x59, + 0x4,0x32,0x23, 0x1,0x5a,0x55, 0x1,0x5a,0x64, 0x1,0x5a,0x5f, + 0x1,0x5a,0x5d, 0x2,0x35,0x54, 0x1,0x5a,0x69, 0x2,0x35,0x51, + 0x2,0x35,0x5e, 0x2,0x35,0x5a, 0x2,0x3b,0x77, 0x2,0x3b,0x76, + 0x3,0x36,0x2d, 0x3,0x64,0x7e, 0x3,0x36,0x2e, 0x2,0x35,0x4f, + 0x2,0x3c,0x29, 0x3,0x3b,0x71, 0x1,0x5f,0x41, 0x3,0x3b,0x70, + 0x2,0x3c,0x2f, 0x2,0x3b,0x7c, 0x2,0x3c,0x2c, 0x2,0x42,0x7d, + 0x1,0x5f,0x44, 0x2,0x3c,0x30, 0x2,0x3c,0x33, 0x1,0x5f,0x43, + 0x2,0x3c,0x21, 0x2,0x3c,0x32, 0x2,0x3c,0x31, 0x1,0x5f,0x45, + 0x2,0x3b,0x78, 0x1,0x5f,0x40, 0x1,0x5f,0x48, 0x3,0x3b,0x73, + 0x1,0x5f,0x46, 0x2,0x3c,0x2e, 0x4,0x37,0x71, 0x2,0x3c,0x24, + 0x1,0x5f,0x4a, 0x2,0x3c,0x35, 0x2,0x3c,0x2d, 0x2,0x3c,0x36, + 0x1,0x5f,0x52, 0x1,0x5f,0x50, 0x2,0x3c,0x2b, 0x2,0x3c,0x2a, + 0x3,0x3b,0x67, 0x2,0x3c,0x28, 0x2,0x3c,0x22, 0x1,0x5f,0x49, + 0x3,0x3b,0x66, 0x1,0x5f,0x47, 0x2,0x2f,0x3b, 0x2,0x3b,0x79, + 0x3,0x3b,0x68, 0x2,0x43,0x3d, 0x2,0x3b,0x7a, 0x1,0x5f,0x42, + 0x1,0x5f,0x4f, 0x2,0x43,0x21, 0x4,0x37,0x60, 0x1,0x5f,0x4b, + 0x1,0x5f,0x4c, 0x2,0x3b,0x7b, 0x2,0x3c,0x34, 0x2,0x42,0x7e, + 0x2,0x3c,0x25, 0x2,0x3b,0x7e, 0x1,0x5f,0x4e, 0x2,0x3c,0x26, + 0x2,0x3c,0x23, 0x3,0x3b,0x72, 0x3,0x3b,0x6d, 0x1,0x5f,0x53, + 0x4,0x37,0x6f, 0x3,0x3b,0x6f, 0x3,0x65,0x21, 0x1,0x64,0x38, + 0x3,0x41,0x49, 0x3,0x41,0x32, 0x2,0x43,0x24, 0x2,0x43,0x37, + 0x2,0x43,0x3c, 0x2,0x43,0x30, 0x1,0x64,0x34, 0x2,0x43,0x41, + 0x1,0x64,0x31, 0x2,0x43,0x22, 0x3,0x41,0x3a, 0x2,0x43,0x23, + 0x1,0x64,0x2a, 0x1,0x64,0x33, 0x2,0x43,0x2a, 0x1,0x64,0x36, + 0x1,0x64,0x37, 0x2,0x43,0x2b, 0x3,0x41,0x38, 0x2,0x43,0x38, + 0x2,0x43,0x3e, 0x1,0x64,0x32, 0x3,0x41,0x3e, 0x1,0x64,0x2c, + 0x2,0x43,0x29, 0x2,0x43,0x25, 0x2,0x43,0x40, 0x2,0x43,0x2e, + 0x2,0x43,0x2f, 0x2,0x43,0x26, 0x2,0x43,0x3a, 0x2,0x43,0x31, + 0x2,0x43,0x3b, 0x2,0x43,0x33, 0x3,0x41,0x3d, 0x1,0x64,0x2d, + 0x2,0x4a,0x40, 0x1,0x64,0x30, 0x1,0x64,0x2e, 0x2,0x43,0x3f, + 0x2,0x43,0x36, 0x2,0x43,0x32, 0x3,0x41,0x36, 0x3,0x41,0x33, + 0x2,0x43,0x27, 0x1,0x68,0x7a, 0x2,0x43,0x35, 0x1,0x64,0x35, + 0x2,0x43,0x2d, 0x3,0x41,0x34, 0x2,0x43,0x2c, 0x3,0x41,0x48, + 0x3,0x47,0x25, 0x3,0x41,0x42, 0x1,0x64,0x2f, 0x1,0x64,0x2b, + 0x2,0x4a,0x55, 0x2,0x43,0x39, 0x2,0x43,0x34, 0x2,0x43,0x28, + 0x3,0x41,0x44, 0x3,0x41,0x45, 0x3,0x66,0x76, 0x2,0x4a,0x50, + 0x3,0x46,0x78, 0x2,0x4a,0x41, 0x2,0x4a,0x4c, 0x3,0x47,0x28, + 0x2,0x4a,0x53, 0x1,0x68,0x78, 0x1,0x5f,0x51, 0x2,0x4a,0x51, + 0x1,0x68,0x73, 0x3,0x46,0x7e, 0x3,0x47,0x24, 0x3,0x46,0x7a, + 0x1,0x68,0x72, 0x2,0x4a,0x58, 0x4,0x43,0x5d, 0x2,0x4a,0x42, + 0x2,0x4a,0x4f, 0x2,0x4a,0x43, 0x2,0x4a,0x4e, 0x1,0x68,0x76, + 0x2,0x4a,0x52, 0x2,0x3c,0x27, 0x3,0x47,0x21, 0x4,0x43,0x5e, + 0x3,0x47,0x2a, 0x2,0x4a,0x59, 0x2,0x4a,0x4a, 0x1,0x68,0x79, + 0x2,0x50,0x61, 0x1,0x6c,0x77, 0x3,0x47,0x23, 0x2,0x4a,0x57, + 0x2,0x4a,0x56, 0x1,0x68,0x7b, 0x2,0x50,0x54, 0x1,0x6c,0x78, + 0x2,0x50,0x55, 0x3,0x47,0x22, 0x2,0x4a,0x46, 0x2,0x4a,0x47, + 0x2,0x4a,0x44, 0x2,0x4a,0x49, 0x2,0x4a,0x45, 0x2,0x4a,0x5a, + 0x1,0x68,0x75, 0x1,0x6c,0x79, 0x1,0x68,0x77, 0x1,0x68,0x7c, + 0x3,0x46,0x7b, 0x2,0x4a,0x48, 0x3,0x47,0x29, 0x2,0x4a,0x54, + 0x3,0x4c,0x2d, 0x3,0x47,0x26, 0x2,0x4a,0x4d, 0x3,0x4c,0x35, + 0x2,0x50,0x58, 0x3,0x4c,0x38, 0x1,0x68,0x71, 0x1,0x6c,0x7c, + 0x2,0x57,0x35, 0x2,0x50,0x5d, 0x2,0x50,0x5c, 0x2,0x50,0x5e, + 0x3,0x4c,0x30, 0x3,0x4c,0x2f, 0x2,0x50,0x5b, 0x1,0x6c,0x7d, + 0x3,0x4c,0x3b, 0x1,0x6d,0x25, 0x1,0x6d,0x22, 0x3,0x4c,0x31, + 0x1,0x6d,0x23, 0x2,0x50,0x56, 0x2,0x50,0x59, 0x2,0x50,0x63, + 0x1,0x6d,0x2b, 0x1,0x6d,0x29, 0x3,0x4c,0x2e, 0x2,0x50,0x5a, + 0x2,0x3b,0x7d, 0x1,0x6c,0x7a, 0x2,0x50,0x60, 0x2,0x50,0x57, + 0x3,0x4c,0x3e, 0x1,0x6d,0x2c, 0x2,0x50,0x5f, 0x1,0x68,0x74, + 0x1,0x6d,0x21, 0x2,0x4a,0x4b, 0x3,0x4c,0x3f, 0x3,0x4c,0x34, + 0x1,0x6d,0x24, 0x3,0x4c,0x3d, 0x1,0x6d,0x28, 0x1,0x6d,0x2a, + 0x1,0x6d,0x27, 0x1,0x6d,0x26, 0x3,0x4c,0x3a, 0x1,0x6c,0x7e, + 0x2,0x50,0x62, 0x1,0x6c,0x7b, 0x1,0x6d,0x2d, 0x3,0x4c,0x39, + 0x3,0x65,0x22, 0x3,0x4c,0x37, 0x1,0x70,0x61, 0x1,0x70,0x62, + 0x2,0x57,0x34, 0x1,0x70,0x6b, 0x1,0x70,0x68, 0x3,0x50,0x70, + 0x1,0x70,0x5f, 0x1,0x70,0x66, 0x2,0x57,0x36, 0x1,0x70,0x64, + 0x1,0x70,0x5e, 0x3,0x4c,0x32, 0x1,0x70,0x65, 0x3,0x50,0x77, + 0x2,0x57,0x33, 0x1,0x73,0x64, 0x1,0x70,0x60, 0x5,0x54,0x5e, + 0x1,0x70,0x67, 0x1,0x73,0x63, 0x2,0x57,0x32, 0x2,0x57,0x31, + 0x3,0x50,0x76, 0x1,0x70,0x69, 0x3,0x50,0x6f, 0x1,0x70,0x6a, + 0x3,0x50,0x79, 0x2,0x57,0x30, 0x2,0x57,0x2f, 0x1,0x73,0x65, + 0x2,0x57,0x39, 0x1,0x70,0x63, 0x2,0x57,0x37, 0x3,0x50,0x75, + 0x3,0x54,0x64, 0x1,0x73,0x66, 0x3,0x54,0x67, 0x1,0x73,0x6b, + 0x2,0x5c,0x75, 0x2,0x5c,0x77, 0x3,0x57,0x6b, 0x1,0x73,0x68, + 0x3,0x57,0x6d, 0x2,0x5c,0x78, 0x2,0x5c,0x74, 0x3,0x57,0x6c, + 0x2,0x5c,0x76, 0x1,0x73,0x69, 0x1,0x73,0x6c, 0x3,0x54,0x69, + 0x2,0x5c,0x73, 0x1,0x73,0x67, 0x1,0x73,0x6a, 0x1,0x76,0x45, + 0x2,0x57,0x38, 0x1,0x76,0x44, 0x7,0x3f,0x62, 0x3,0x57,0x6a, + 0x1,0x76,0x4a, 0x2,0x61,0x60, 0x3,0x57,0x70, 0x1,0x76,0x48, + 0x1,0x76,0x49, 0x2,0x61,0x63, 0x2,0x61,0x5f, 0x1,0x76,0x46, + 0x2,0x61,0x5d, 0x1,0x78,0x38, 0x2,0x61,0x61, 0x4,0x5b,0x36, + 0x2,0x61,0x62, 0x2,0x61,0x5e, 0x3,0x57,0x6e, 0x1,0x76,0x47, + 0x2,0x65,0x4d, 0x3,0x5a,0x3b, 0x2,0x65,0x50, 0x3,0x5a,0x3c, + 0x3,0x5a,0x3a, 0x2,0x65,0x51, 0x2,0x65,0x4f, 0x2,0x65,0x52, + 0x1,0x78,0x39, 0x2,0x65,0x4e, 0x3,0x5e,0x31, 0x2,0x68,0x7a, + 0x1,0x79,0x6f, 0x2,0x68,0x79, 0x2,0x68,0x78, 0x2,0x68,0x77, + 0x1,0x79,0x6e, 0x1,0x79,0x70, 0x3,0x65,0x23, 0x2,0x6b,0x5b, + 0x1,0x7a,0x6d, 0x1,0x7a,0x6c, 0x3,0x5f,0x4a, 0x3,0x5f,0x4b, + 0x2,0x6d,0x4f, 0x2,0x6d,0x4e, 0x2,0x6d,0x51, 0x1,0x7c,0x37, + 0x1,0x7b,0x61, 0x2,0x6f,0x2c, 0x2,0x6d,0x50, 0x3,0x5f,0x49, + 0x3,0x60,0x32, 0x2,0x6f,0x2b, 0x1,0x7c,0x39, 0x1,0x7c,0x38, + 0x1,0x7c,0x5f, 0x2,0x70,0x37, 0x2,0x70,0x7d, 0x1,0x45,0x45, + 0x6,0x23,0x6c, 0x3,0x2c,0x72, 0x2,0x3c,0x37, 0x2,0x57,0x3a, + 0x3,0x21,0x67, 0x3,0x21,0x68, 0x1,0x48,0x2d, 0x2,0x22,0x4d, + 0x1,0x4a,0x53, 0x1,0x4a,0x51, 0x4,0x24,0x3f, 0x1,0x4a,0x52, + 0x4,0x24,0x3e, 0x2,0x27,0x22, 0x1,0x4d,0x73, 0x1,0x51,0x49, + 0x3,0x2c,0x74, 0x2,0x2a,0x68, 0x3,0x2c,0x76, 0x2,0x2a,0x69, + 0x3,0x2c,0x73, 0x1,0x51,0x4a, 0x2,0x2f,0x50, 0x4,0x2d,0x43, + 0x1,0x55,0x66, 0x1,0x55,0x67, 0x2,0x2f,0x4f, 0x3,0x31,0x3d, + 0x4,0x2d,0x44, 0x3,0x36,0x37, 0x3,0x36,0x36, 0x1,0x5a,0x77, + 0x4,0x32,0x2b, 0x1,0x5a,0x73, 0x4,0x32,0x2f, 0x2,0x35,0x69, + 0x1,0x5a,0x7a, 0x1,0x5a,0x79, 0x1,0x5a,0x72, 0x1,0x5a,0x75, + 0x1,0x5a,0x78, 0x1,0x5a,0x74, 0x3,0x36,0x34, 0x2,0x3c,0x3b, + 0x1,0x5a,0x71, 0x1,0x5f,0x54, 0x3,0x3b,0x74, 0x3,0x3b,0x75, + 0x3,0x3b,0x76, 0x1,0x5f,0x56, 0x1,0x5f,0x57, 0x2,0x3c,0x3a, + 0x2,0x3c,0x3d, 0x1,0x5f,0x55, 0x2,0x3c,0x38, 0x2,0x3c,0x3c, + 0x2,0x3c,0x39, 0x3,0x41,0x4b, 0x1,0x64,0x39, 0x3,0x41,0x4e, + 0x4,0x3d,0x5d, 0x2,0x43,0x42, 0x3,0x41,0x4d, 0x3,0x47,0x30, + 0x1,0x68,0x7d, 0x2,0x4a,0x5b, 0x1,0x70,0x6c, 0x1,0x6d,0x2e, + 0x2,0x50,0x64, 0x1,0x6d,0x2f, 0x1,0x6d,0x30, 0x2,0x50,0x66, + 0x2,0x50,0x65, 0x2,0x50,0x67, 0x2,0x57,0x3c, 0x2,0x57,0x3b, + 0x2,0x5c,0x7a, 0x2,0x5c,0x79, 0x1,0x73,0x6d, 0x1,0x73,0x6e, + 0x2,0x65,0x53, 0x3,0x5c,0x41, 0x1,0x45,0x46, 0x3,0x25,0x58, + 0x3,0x29,0x39, 0x4,0x2d,0x47, 0x3,0x31,0x40, 0x2,0x3c,0x3e, + 0x3,0x36,0x38, 0x3,0x36,0x39, 0x1,0x5f,0x59, 0x1,0x5f,0x58, + 0x2,0x43,0x43, 0x2,0x61,0x64, 0x1,0x7a,0x6e, 0x2,0x6f,0x2d, + 0x1,0x45,0x47, 0x4,0x24,0x41, 0x1,0x55,0x68, 0x3,0x31,0x42, + 0x1,0x5a,0x7c, 0x1,0x5a,0x7b, 0x2,0x3c,0x3f, 0x2,0x3c,0x40, + 0x1,0x64,0x3a, 0x2,0x4a,0x5c, 0x1,0x68,0x7e, 0x2,0x57,0x3d, + 0x4,0x56,0x3f, 0x1,0x45,0x48, 0x1,0x46,0x58, 0x3,0x29,0x3b, + 0x1,0x4d,0x74, 0x2,0x27,0x23, 0x2,0x2a,0x6a, 0x1,0x51,0x4b, + 0x1,0x5a,0x7d, 0x3,0x36,0x3a, 0x2,0x3c,0x41, 0x1,0x5f,0x5a, + 0x1,0x64,0x3b, 0x4,0x3d,0x63, 0x2,0x50,0x68, 0x2,0x50,0x69, + 0x4,0x50,0x4e, 0x3,0x54,0x6b, 0x2,0x5c,0x7b, 0x1,0x76,0x4b, + 0x2,0x70,0x7e, 0x1,0x45,0x49, 0x3,0x29,0x3c, 0x2,0x27,0x24, + 0x1,0x4d,0x75, 0x1,0x51,0x4c, 0x3,0x2c,0x77, 0x2,0x2a,0x6b, + 0x1,0x55,0x69, 0x2,0x2f,0x54, 0x2,0x2f,0x52, 0x2,0x2f,0x53, + 0x1,0x55,0x6a, 0x2,0x2f,0x51, 0x3,0x36,0x3c, 0x4,0x32,0x34, + 0x3,0x36,0x3f, 0x3,0x36,0x3d, 0x1,0x5b,0x21, 0x1,0x5b,0x22, + 0x2,0x35,0x6a, 0x1,0x5b,0x23, 0x1,0x5a,0x7e, 0x2,0x3c,0x42, + 0x3,0x3b,0x79, 0x2,0x3c,0x43, 0x2,0x43,0x44, 0x4,0x3d,0x64, + 0x1,0x69,0x22, 0x1,0x69,0x21, 0x4,0x50,0x4f, 0xf,0x54,0x64, + 0x2,0x5c,0x7c, 0x2,0x61,0x65, 0x3,0x5a,0x3f, 0x2,0x65,0x55, + 0x2,0x65,0x54, 0x2,0x68,0x7b, 0x3,0x21,0x69, 0x2,0x21,0x3e, + 0x1,0x51,0x4d, 0x3,0x36,0x41, 0x3,0x41,0x50, 0x1,0x45,0x4a, + 0x1,0x46,0x59, 0x3,0x22,0x51, 0x1,0x48,0x2f, 0x1,0x48,0x2e, + 0x3,0x23,0x73, 0x3,0x23,0x72, 0x1,0x48,0x30, 0x1,0x48,0x31, + 0x2,0x22,0x4f, 0x2,0x22,0x4e, 0x2,0x24,0x39, 0x1,0x4a,0x54, + 0x2,0x24,0x3c, 0x2,0x24,0x3b, 0x2,0x24,0x3a, 0x2,0x24,0x3d, + 0x3,0x26,0x3d, 0x4,0x26,0x62, 0x1,0x4d,0x76, 0x2,0x27,0x2a, + 0x2,0x27,0x26, 0x2,0x27,0x2f, 0x3,0x29,0x43, 0x3,0x29,0x3e, + 0x1,0x4d,0x7d, 0x3,0x29,0x42, 0x1,0x4d,0x7b, 0x2,0x27,0x2b, + 0x2,0x27,0x27, 0x2,0x27,0x2e, 0x1,0x4d,0x7a, 0x1,0x4e,0x23, + 0x2,0x27,0x29, 0x2,0x27,0x25, 0x1,0x4e,0x22, 0x2,0x27,0x2c, + 0x1,0x4d,0x79, 0x2,0x27,0x2d, 0x1,0x4d,0x7c, 0x1,0x4d,0x7e, + 0x2,0x27,0x31, 0x2,0x27,0x30, 0x2,0x27,0x28, 0x1,0x4d,0x78, + 0x1,0x4d,0x77, 0x1,0x4e,0x21, 0x4,0x26,0x61, 0x3,0x29,0x40, + 0x3,0x29,0x41, 0xf,0x27,0x3e, 0x3,0x2c,0x7e, 0x3,0x2c,0x7a, + 0x2,0x2a,0x70, 0x2,0x2a,0x76, 0x3,0x2d,0x23, 0x1,0x51,0x53, + 0x1,0x51,0x50, 0x2,0x2a,0x6d, 0x2,0x2a,0x72, 0x3,0x2c,0x7c, + 0x1,0x51,0x56, 0x1,0x51,0x4e, 0x2,0x2a,0x71, 0x1,0x51,0x51, + 0x1,0x51,0x54, 0x3,0x2c,0x79, 0x4,0x29,0x67, 0x2,0x2a,0x74, + 0x3,0x2c,0x7d, 0x1,0x51,0x4f, 0x2,0x2a,0x79, 0x1,0x51,0x52, + 0x3,0x2d,0x21, 0x1,0x51,0x55, 0x2,0x2a,0x6e, 0x2,0x2a,0x73, + 0x2,0x2a,0x77, 0x2,0x2a,0x6f, 0x2,0x2a,0x6c, 0x3,0x2d,0x24, + 0x3,0x2d,0x25, 0x2,0x2a,0x78, 0x2,0x2a,0x75, 0x3,0x2d,0x22, + 0x3,0x2c,0x37, 0x3,0x31,0x46, 0x1,0x55,0x72, 0x1,0x55,0x6b, + 0x1,0x55,0x6e, 0x3,0x31,0x4c, 0x1,0x55,0x71, 0x3,0x31,0x44, + 0x2,0x2f,0x57, 0x3,0x31,0x49, 0x1,0x55,0x6c, 0x2,0x2f,0x55, + 0x3,0x31,0x48, 0x1,0x55,0x70, 0x3,0x31,0x4d, 0x3,0x31,0x45, + 0x1,0x55,0x6d, 0x3,0x31,0x43, 0x2,0x2f,0x58, 0x1,0x55,0x6f, + 0x3,0x36,0x42, 0x4,0x32,0x39, 0x2,0x35,0x6e, 0x1,0x5b,0x25, + 0x2,0x35,0x6d, 0x2,0x35,0x6f, 0x1,0x5b,0x24, 0x1,0x5b,0x29, + 0x2,0x2f,0x56, 0x3,0x31,0x4b, 0x2,0x35,0x6c, 0x2,0x35,0x70, + 0x3,0x36,0x44, 0x1,0x5b,0x26, 0x2,0x35,0x6b, 0x1,0x5b,0x28, + 0x3,0x36,0x45, 0x1,0x5b,0x27, 0x3,0x3c,0x26, 0x2,0x3c,0x4a, + 0x3,0x3b,0x7d, 0x2,0x3c,0x45, 0x3,0x3c,0x25, 0x1,0x5f,0x5b, + 0x1,0x5f,0x5f, 0x1,0x5f,0x5c, 0x2,0x3c,0x48, 0x2,0x3c,0x4b, + 0x3,0x3c,0x23, 0x1,0x5f,0x5d, 0x4,0x38,0x24, 0x1,0x5f,0x5e, + 0x1,0x5f,0x63, 0x2,0x43,0x4d, 0x2,0x3c,0x49, 0x1,0x5f,0x61, + 0x2,0x3c,0x46, 0x2,0x3c,0x44, 0x3,0x3b,0x7c, 0x1,0x5f,0x62, + 0x3,0x3b,0x7e, 0x2,0x3c,0x47, 0x3,0x3c,0x24, 0x1,0x64,0x41, + 0x4,0x3d,0x69, 0x2,0x43,0x45, 0x1,0x64,0x3e, 0x1,0x64,0x3f, + 0x1,0x64,0x3d, 0x2,0x43,0x4a, 0x2,0x43,0x49, 0x2,0x43,0x46, + 0x1,0x64,0x43, 0x3,0x41,0x5b, 0x3,0x41,0x56, 0x2,0x43,0x48, + 0x1,0x5f,0x60, 0x3,0x41,0x59, 0x3,0x41,0x51, 0x2,0x43,0x4c, + 0x2,0x43,0x47, 0x1,0x64,0x40, 0x1,0x64,0x3c, 0x1,0x64,0x42, + 0x2,0x43,0x4b, 0x3,0x47,0x34, 0x4,0x43,0x6b, 0x3,0x47,0x35, + 0x1,0x69,0x25, 0x4,0x43,0x6f, 0x2,0x4a,0x5f, 0x2,0x4a,0x5e, + 0x2,0x4a,0x5d, 0x1,0x69,0x23, 0x4,0x43,0x6d, 0x3,0x47,0x39, + 0x3,0x47,0x33, 0x3,0x47,0x37, 0x1,0x69,0x24, 0x2,0x50,0x6c, + 0x2,0x50,0x6f, 0x1,0x6d,0x32, 0x3,0x4c,0x44, 0x3,0x4c,0x46, + 0x1,0x6d,0x31, 0x2,0x50,0x70, 0x2,0x50,0x6b, 0x1,0x6d,0x34, + 0x2,0x50,0x6d, 0x3,0x4c,0x41, 0x1,0x6d,0x33, 0x2,0x50,0x6a, + 0x3,0x4c,0x40, 0x2,0x50,0x6e, 0x1,0x70,0x72, 0x1,0x70,0x6f, + 0x2,0x57,0x46, 0x2,0x57,0x45, 0x3,0x4c,0x43, 0x2,0x57,0x44, + 0x2,0x57,0x3f, 0x3,0x50,0x7d, 0x2,0x57,0x40, 0x3,0x51,0x23, + 0x4,0x50,0x50, 0x3,0x50,0x7a, 0x1,0x70,0x70, 0x3,0x50,0x7e, + 0x1,0x70,0x6d, 0x1,0x70,0x71, 0x2,0x57,0x3e, 0x1,0x70,0x6e, + 0x2,0x57,0x41, 0x2,0x57,0x42, 0x2,0x57,0x47, 0x3,0x51,0x22, + 0x3,0x54,0x71, 0x2,0x57,0x43, 0x3,0x54,0x6f, 0x3,0x54,0x70, + 0x2,0x5c,0x7d, 0x4,0x56,0x41, 0x3,0x54,0x6c, 0x3,0x54,0x6d, + 0x1,0x73,0x70, 0x3,0x54,0x72, 0x2,0x61,0x68, 0x1,0x73,0x6f, + 0x2,0x61,0x66, 0x2,0x61,0x67, 0x1,0x76,0x4c, 0x1,0x78,0x3b, + 0x2,0x65,0x56, 0x3,0x5a,0x43, 0x1,0x78,0x3a, 0x3,0x5a,0x42, + 0x3,0x65,0x26, 0x2,0x68,0x7d, 0x2,0x68,0x7e, 0x3,0x5c,0x42, + 0x1,0x79,0x71, 0x3,0x5c,0x43, 0x2,0x68,0x7c, 0x1,0x7a,0x6f, + 0x4,0x6a,0x4c, 0x2,0x6f,0x2e, 0x1,0x7c,0x3a, 0x2,0x70,0x38, + 0x2,0x70,0x39, 0x3,0x61,0x3f, 0x1,0x45,0x4b, 0x4,0x21,0x7c, + 0x1,0x48,0x32, 0x1,0x48,0x33, 0x1,0x4a,0x55, 0x3,0x26,0x41, + 0x2,0x27,0x32, 0x1,0x51,0x57, 0x1,0x55,0x73, 0x1,0x5b,0x2a, + 0xf,0x32,0x73, 0x1,0x59,0x37, 0x1,0x5f,0x64, 0x1,0x5f,0x65, + 0x1,0x5e,0x32, 0x2,0x3c,0x4c, 0x3,0x65,0x27, 0x1,0x64,0x44, + 0x2,0x4a,0x61, 0x2,0x4a,0x60, 0x3,0x51,0x24, 0x7,0x53,0x47, + 0x1,0x45,0x4c, 0x1,0x48,0x34, 0x2,0x27,0x33, 0x1,0x4e,0x25, + 0x3,0x29,0x45, 0x1,0x4e,0x24, 0x3,0x2d,0x27, 0x2,0x2a,0x7a, + 0x2,0x2a,0x7b, 0x3,0x66,0x32, 0x2,0x2f,0x59, 0x2,0x2f,0x5a, + 0x1,0x55,0x74, 0x1,0x55,0x75, 0x3,0x36,0x48, 0x1,0x55,0x76, + 0x2,0x35,0x71, 0x3,0x36,0x47, 0x3,0x36,0x46, 0x1,0x5b,0x2c, + 0x4,0x38,0x29, 0x1,0x5f,0x67, 0x3,0x3c,0x29, 0x1,0x5f,0x66, + 0x2,0x43,0x4e, 0x2,0x46,0x41, 0x2,0x4a,0x62, 0x2,0x57,0x48, + 0x3,0x51,0x26, 0x3,0x66,0x33, 0x1,0x76,0x4d, 0x1,0x79,0x72, + 0x1,0x45,0x4d, 0x1,0x46,0x5c, 0x1,0x46,0x5d, 0x1,0x46,0x5b, + 0x1,0x46,0x5e, 0x1,0x46,0x5a, 0x3,0x22,0x52, 0x1,0x48,0x37, + 0x3,0x23,0x77, 0x2,0x22,0x57, 0x1,0x48,0x36, 0x1,0x48,0x38, + 0x3,0x23,0x78, 0x3,0x23,0x75, 0x2,0x22,0x52, 0x2,0x22,0x51, + 0x2,0x22,0x54, 0x2,0x22,0x53, 0x2,0x22,0x56, 0x1,0x48,0x35, + 0x2,0x22,0x50, 0x2,0x22,0x55, 0xf,0x22,0x58, 0xf,0x22,0x57, + 0x3,0x26,0x48, 0x2,0x24,0x3e, 0x1,0x4a,0x5f, 0x2,0x24,0x3f, + 0x2,0x24,0x43, 0x1,0x4a,0x5e, 0x3,0x26,0x49, 0x2,0x24,0x47, + 0x2,0x24,0x42, 0x2,0x24,0x45, 0x1,0x4a,0x57, 0x1,0x4a,0x58, + 0x1,0x4a,0x59, 0x1,0x4a,0x5a, 0x3,0x26,0x45, 0x1,0x4a,0x61, + 0x3,0x26,0x44, 0x2,0x24,0x41, 0x1,0x4a,0x5c, 0x1,0x4a,0x62, + 0x3,0x26,0x47, 0x2,0x24,0x40, 0x2,0x24,0x46, 0x3,0x26,0x42, + 0x1,0x4a,0x5b, 0x2,0x24,0x44, 0x1,0x4a,0x5d, 0x1,0x4a,0x56, + 0x1,0x4a,0x60, 0x3,0x26,0x4a, 0xf,0x24,0x22, 0x4,0x24,0x46, + 0xf,0x24,0x53, 0x1,0x4e,0x3a, 0x3,0x29,0x47, 0x2,0x27,0x35, + 0x1,0x4e,0x26, 0x4,0x26,0x69, 0x1,0x4e,0x30, 0x1,0x4e,0x31, + 0x1,0x4e,0x29, 0x1,0x4e,0x3b, 0x1,0x4e,0x2b, 0x2,0x27,0x3d, + 0x1,0x4e,0x36, 0x2,0x27,0x38, 0x1,0x4e,0x2c, 0x2,0x27,0x47, + 0x2,0x27,0x48, 0x2,0x27,0x40, 0x2,0x27,0x39, 0x1,0x4e,0x39, + 0x2,0x27,0x45, 0x1,0x4e,0x34, 0x1,0x4e,0x32, 0x3,0x29,0x52, + 0x2,0x27,0x46, 0x3,0x29,0x49, 0x2,0x27,0x44, 0x2,0x27,0x3c, + 0x2,0x27,0x34, 0x2,0x27,0x3b, 0x1,0x4e,0x2d, 0x4,0x26,0x65, + 0x1,0x4e,0x33, 0x3,0x29,0x4a, 0x1,0x4e,0x27, 0x2,0x27,0x3f, + 0x2,0x27,0x3e, 0x2,0x27,0x36, 0x3,0x29,0x4f, 0x1,0x4e,0x35, + 0x2,0x27,0x42, 0x2,0x27,0x37, 0x1,0x4e,0x38, 0x2,0x27,0x49, + 0x1,0x4e,0x28, 0x3,0x29,0x48, 0x1,0x4e,0x2f, 0x2,0x27,0x3a, + 0x2,0x27,0x43, 0x1,0x4e,0x37, 0x4,0x26,0x67, 0x1,0x4e,0x2a, + 0x1,0x4e,0x2e, 0x4,0x26,0x6a, 0x2,0x27,0x41, 0xf,0x27,0x4e, + 0x3,0x29,0x4e, 0x3,0x29,0x4c, 0x3,0x65,0x28, 0xf,0x27,0x50, + 0x3,0x65,0x29, 0x2,0x2b,0x3d, 0x1,0x51,0x5f, 0x1,0x51,0x6c, + 0x3,0x2d,0x36, 0x2,0x2b,0x38, 0x2,0x2b,0x2e, 0x1,0x51,0x65, + 0x2,0x2b,0x2c, 0x1,0x51,0x5e, 0x2,0x2b,0x27, 0x1,0x51,0x68, + 0x2,0x2b,0x34, 0x2,0x2b,0x21, 0x2,0x2b,0x23, 0x3,0x2d,0x2e, + 0x4,0x2d,0x59, 0x4,0x29,0x6e, 0x3,0x2d,0x30, 0x2,0x2b,0x26, + 0x2,0x2a,0x7c, 0x2,0x2b,0x33, 0x2,0x2b,0x43, 0x1,0x51,0x63, + 0x2,0x2b,0x28, 0x2,0x2b,0x3a, 0x3,0x2d,0x2d, 0x2,0x2a,0x7e, + 0x2,0x2b,0x41, 0x2,0x2b,0x42, 0x2,0x2b,0x45, 0x2,0x2b,0x3c, + 0x2,0x2b,0x2d, 0x2,0x2b,0x35, 0x1,0x51,0x69, 0x1,0x51,0x5c, + 0x1,0x51,0x64, 0x1,0x51,0x70, 0x1,0x51,0x59, 0x1,0x51,0x5b, + 0x3,0x2d,0x31, 0x3,0x2d,0x2b, 0x3,0x2d,0x3a, 0x2,0x2b,0x25, + 0x1,0x51,0x6d, 0x1,0x51,0x66, 0x2,0x2b,0x3f, 0x2,0x2b,0x22, + 0x1,0x51,0x6f, 0x1,0x51,0x6a, 0x2,0x2b,0x2b, 0x4,0x29,0x6d, + 0x4,0x2d,0x4e, 0x1,0x51,0x6e, 0x2,0x2b,0x32, 0x2,0x2b,0x2a, + 0x1,0x51,0x67, 0x2,0x2b,0x3e, 0x2,0x2b,0x36, 0x3,0x2d,0x2a, + 0x1,0x51,0x61, 0x2,0x2b,0x44, 0x2,0x2b,0x29, 0x1,0x51,0x5d, + 0x2,0x2b,0x3b, 0x2,0x2b,0x31, 0x1,0x51,0x62, 0x2,0x2b,0x37, + 0x1,0x51,0x5a, 0x2,0x2a,0x7d, 0x1,0x51,0x6b, 0x1,0x56,0x27, + 0x1,0x51,0x60, 0x2,0x2b,0x30, 0x2,0x2b,0x2f, 0x2,0x2b,0x24, + 0x3,0x29,0x51, 0x2,0x2b,0x40, 0x3,0x2d,0x34, 0x2,0x2b,0x39, + 0x3,0x2d,0x32, 0x1,0x51,0x58, 0x3,0x2d,0x39, 0x3,0x2d,0x37, + 0x6,0x31,0x72, 0x3,0x2d,0x38, 0x3,0x65,0x2b, 0x3,0x65,0x2a, + 0xf,0x2b,0x48, 0x2,0x2f,0x6e, 0x1,0x56,0x2e, 0x2,0x2f,0x6f, + 0x3,0x31,0x5d, 0x2,0x2f,0x63, 0x1,0x56,0x23, 0x1,0x56,0x2f, + 0x3,0x31,0x57, 0x2,0x2f,0x5c, 0x3,0x31,0x53, 0x2,0x2f,0x65, + 0x2,0x2f,0x6d, 0x3,0x31,0x5b, 0x2,0x2f,0x5b, 0x2,0x2f,0x76, + 0x1,0x55,0x77, 0x3,0x31,0x5e, 0x3,0x31,0x64, 0x3,0x31,0x50, + 0x2,0x2f,0x75, 0x2,0x2f,0x70, 0x3,0x31,0x5f, 0x2,0x2f,0x71, + 0x1,0x56,0x21, 0x1,0x56,0x2c, 0x2,0x2f,0x67, 0x3,0x31,0x56, + 0x2,0x2f,0x68, 0x2,0x2f,0x72, 0x2,0x2f,0x69, 0x3,0x31,0x63, + 0x2,0x2f,0x64, 0x2,0x2f,0x5e, 0x2,0x2f,0x5f, 0x2,0x2f,0x6c, + 0x2,0x2f,0x66, 0x3,0x31,0x54, 0x3,0x31,0x4f, 0x1,0x55,0x78, + 0x1,0x55,0x7c, 0x2,0x2f,0x74, 0x2,0x2f,0x60, 0x1,0x56,0x2a, + 0x1,0x56,0x26, 0x3,0x31,0x5a, 0x4,0x2d,0x55, 0x1,0x56,0x29, + 0x1,0x56,0x30, 0x1,0x55,0x7d, 0x1,0x56,0x2b, 0x2,0x2f,0x6b, + 0x1,0x56,0x2d, 0x1,0x55,0x7a, 0x3,0x31,0x59, 0x1,0x55,0x79, + 0x2,0x2f,0x5d, 0x4,0x2d,0x4f, 0x2,0x2f,0x61, 0x1,0x56,0x24, + 0x2,0x2f,0x73, 0x2,0x2f,0x6a, 0x2,0x2f,0x62, 0x1,0x56,0x28, + 0x1,0x56,0x25, 0x3,0x2d,0x2f, 0x1,0x55,0x7b, 0x1,0x55,0x7e, + 0x3,0x31,0x62, 0x3,0x31,0x58, 0xf,0x30,0x24, 0x3,0x31,0x61, + 0x3,0x31,0x60, 0x3,0x65,0x2d, 0x3,0x65,0x2c, 0x2,0x36,0x28, + 0x3,0x36,0x55, 0x2,0x35,0x76, 0x2,0x35,0x77, 0x2,0x35,0x7b, + 0x3,0x36,0x60, 0x2,0x36,0x2c, 0x2,0x36,0x29, 0x3,0x36,0x4e, + 0x2,0x36,0x22, 0x2,0x36,0x21, 0x1,0x5b,0x33, 0x2,0x36,0x25, + 0x2,0x36,0x34, 0x2,0x35,0x72, 0x3,0x36,0x5b, 0x2,0x36,0x35, + 0x2,0x36,0x27, 0x2,0x36,0x39, 0x2,0x36,0x2d, 0x1,0x5b,0x32, + 0x2,0x36,0x2b, 0x1,0x5b,0x2d, 0x1,0x5b,0x42, 0x1,0x5b,0x38, + 0x3,0x36,0x57, 0x1,0x5b,0x3c, 0x1,0x5b,0x3b, 0x2,0x35,0x73, + 0x4,0x32,0x3f, 0x2,0x36,0x32, 0x2,0x36,0x38, 0x2,0x36,0x30, + 0x2,0x36,0x37, 0x3,0x36,0x51, 0x2,0x36,0x24, 0x2,0x35,0x74, + 0x2,0x36,0x36, 0x2,0x36,0x26, 0x1,0x5b,0x30, 0x1,0x5b,0x3d, + 0x3,0x36,0x5a, 0x2,0x36,0x2f, 0x1,0x5b,0x36, 0x3,0x36,0x4d, + 0x3,0x36,0x5c, 0x3,0x36,0x50, 0x2,0x36,0x2e, 0x2,0x35,0x75, + 0x1,0x5b,0x3e, 0x3,0x36,0x4b, 0x1,0x5b,0x40, 0x2,0x36,0x31, + 0x1,0x5b,0x41, 0x1,0x5b,0x2f, 0x2,0x35,0x7c, 0x2,0x36,0x33, + 0x3,0x36,0x54, 0x3,0x34,0x78, 0x1,0x5b,0x35, 0x1,0x5b,0x3f, + 0x2,0x35,0x7e, 0x2,0x36,0x2a, 0x2,0x35,0x79, 0x2,0x35,0x7d, + 0x1,0x5b,0x3a, 0x2,0x35,0x78, 0x1,0x5b,0x2e, 0x1,0x5b,0x37, + 0x1,0x5b,0x34, 0x2,0x36,0x23, 0x1,0x56,0x22, 0x2,0x3c,0x63, + 0x1,0x5b,0x31, 0x3,0x36,0x4c, 0x3,0x36,0x52, 0x3,0x36,0x5e, + 0x3,0x36,0x5f, 0xf,0x35,0x57, 0x3,0x36,0x56, 0x3,0x3c,0x45, + 0x1,0x5b,0x39, 0x3,0x3c,0x41, 0x2,0x3c,0x66, 0x2,0x3c,0x7c, + 0x2,0x3c,0x71, 0x1,0x5f,0x7b, 0x3,0x3c,0x38, 0x1,0x5f,0x76, + 0x2,0x3c,0x60, 0x1,0x5f,0x77, 0x2,0x3c,0x70, 0x3,0x3c,0x3e, + 0x2,0x3c,0x69, 0x2,0x3c,0x76, 0x1,0x5f,0x73, 0x2,0x3c,0x4e, + 0x2,0x3c,0x78, 0x1,0x5f,0x69, 0x2,0x3c,0x56, 0x1,0x5f,0x6c, + 0x1,0x5f,0x6b, 0x4,0x38,0x32, 0x1,0x5f,0x7c, 0x3,0x36,0x53, + 0x2,0x3c,0x50, 0x2,0x3c,0x72, 0x2,0x3c,0x73, 0x1,0x5f,0x6e, + 0x1,0x5f,0x6a, 0x2,0x3c,0x5e, 0x3,0x3c,0x3d, 0x1,0x5f,0x75, + 0x2,0x3c,0x59, 0x3,0x3c,0x32, 0x2,0x3c,0x74, 0x1,0x5f,0x71, + 0x2,0x3c,0x6c, 0x2,0x3c,0x79, 0x2,0x3c,0x53, 0x2,0x3c,0x58, + 0x2,0x3c,0x52, 0x3,0x3c,0x2a, 0x1,0x5f,0x70, 0x2,0x3c,0x65, + 0x2,0x43,0x64, 0x2,0x3c,0x54, 0x1,0x5f,0x74, 0x2,0x3c,0x5d, + 0x2,0x3c,0x75, 0x1,0x5f,0x6f, 0x2,0x3c,0x5a, 0x2,0x3c,0x57, + 0x2,0x3c,0x68, 0x1,0x5f,0x72, 0x1,0x5f,0x68, 0x1,0x5f,0x7e, + 0x2,0x3c,0x6b, 0x2,0x3c,0x6a, 0x3,0x3c,0x31, 0x3,0x3c,0x42, + 0x3,0x3c,0x39, 0x3,0x3c,0x3b, 0x3,0x3c,0x34, 0x3,0x3c,0x2f, + 0x2,0x3c,0x4f, 0x1,0x5f,0x6d, 0x2,0x3c,0x77, 0x2,0x3c,0x5f, + 0x2,0x3c,0x61, 0x3,0x3c,0x37, 0x2,0x3c,0x6e, 0x2,0x3c,0x6d, + 0x2,0x3c,0x4d, 0x1,0x5f,0x78, 0x1,0x5f,0x7a, 0x2,0x3c,0x55, + 0x2,0x3c,0x5c, 0x2,0x3c,0x64, 0x1,0x5f,0x79, 0x2,0x3c,0x5b, + 0x2,0x3c,0x67, 0x2,0x3c,0x7a, 0xf,0x3b,0x70, 0x2,0x3c,0x6f, + 0x3,0x3c,0x3c, 0xf,0x3c,0x21, 0x3,0x3c,0x44, 0x3,0x3c,0x33, + 0x2,0x3c,0x7b, 0xf,0x3c,0x29, 0x3,0x65,0x2f, 0x2,0x3c,0x51, + 0xf,0x3b,0x6e, 0x3,0x65,0x2e, 0x3,0x3c,0x40, 0x2,0x43,0x78, + 0x1,0x64,0x4c, 0x3,0x41,0x65, 0x2,0x43,0x76, 0x2,0x43,0x61, + 0x2,0x43,0x66, 0x2,0x43,0x5f, 0x3,0x41,0x77, 0x2,0x43,0x72, + 0x2,0x43,0x51, 0x2,0x43,0x58, 0x4,0x3d,0x71, 0x2,0x43,0x70, + 0x2,0x43,0x7a, 0x2,0x43,0x62, 0x3,0x41,0x68, 0x2,0x43,0x55, + 0x2,0x43,0x68, 0x2,0x43,0x6d, 0x2,0x43,0x59, 0x3,0x41,0x6b, + 0x2,0x43,0x6a, 0x2,0x43,0x56, 0x3,0x41,0x5d, 0x3,0x41,0x75, + 0x2,0x43,0x5d, 0x2,0x43,0x5e, 0x1,0x64,0x4e, 0x2,0x43,0x71, + 0x2,0x43,0x6f, 0x3,0x41,0x73, 0x2,0x43,0x52, 0x2,0x43,0x74, + 0x3,0x41,0x74, 0x2,0x43,0x75, 0x2,0x43,0x77, 0x1,0x64,0x52, + 0x1,0x64,0x4a, 0x3,0x41,0x6f, 0x2,0x35,0x7a, 0x2,0x43,0x5a, + 0x2,0x43,0x6c, 0x2,0x43,0x5b, 0x1,0x64,0x47, 0x1,0x64,0x57, + 0x2,0x43,0x73, 0x1,0x64,0x55, 0x1,0x64,0x51, 0x2,0x43,0x50, + 0x1,0x64,0x49, 0x3,0x41,0x79, 0x2,0x43,0x53, 0x1,0x64,0x56, + 0x3,0x41,0x78, 0x2,0x43,0x63, 0x2,0x43,0x4f, 0x3,0x41,0x76, + 0x1,0x64,0x4f, 0x2,0x43,0x67, 0x2,0x43,0x57, 0x1,0x64,0x50, + 0x2,0x43,0x60, 0x1,0x64,0x46, 0x1,0x5f,0x7d, 0x2,0x43,0x69, + 0x2,0x3c,0x62, 0x2,0x43,0x54, 0x4,0x3d,0x6c, 0x3,0x41,0x6d, + 0x2,0x43,0x6e, 0x1,0x64,0x4b, 0x2,0x43,0x6b, 0x1,0x64,0x48, + 0x2,0x43,0x65, 0x1,0x64,0x53, 0x2,0x43,0x5c, 0x2,0x43,0x79, + 0x3,0x41,0x6a, 0x3,0x41,0x7b, 0xf,0x42,0x49, 0xf,0x42,0x47, + 0x1,0x64,0x4d, 0x2,0x45,0x2c, 0x3,0x41,0x72, 0x1,0x64,0x54, + 0xf,0x42,0x28, 0xf,0x42,0x3c, 0x2,0x4a,0x70, 0x2,0x4a,0x6e, + 0x3,0x47,0x3a, 0x2,0x4b,0x26, 0x2,0x4a,0x6c, 0x3,0x47,0x3d, + 0x2,0x4a,0x7e, 0x1,0x64,0x45, 0x1,0x69,0x28, 0x2,0x4a,0x68, + 0x2,0x4b,0x25, 0x3,0x47,0x51, 0x2,0x4a,0x6d, 0x2,0x4a,0x7b, + 0x1,0x69,0x2d, 0x1,0x69,0x26, 0x3,0x47,0x4e, 0x2,0x4b,0x23, + 0x3,0x47,0x46, 0x2,0x4a,0x66, 0x2,0x4b,0x22, 0x3,0x47,0x47, + 0x1,0x69,0x38, 0x2,0x4a,0x77, 0x2,0x4b,0x29, 0x1,0x69,0x36, + 0x2,0x4a,0x6f, 0x1,0x69,0x27, 0x2,0x4a,0x71, 0x2,0x4b,0x21, + 0x1,0x69,0x30, 0x2,0x4a,0x6a, 0x1,0x69,0x34, 0x1,0x69,0x2a, + 0x2,0x4a,0x73, 0x2,0x4a,0x69, 0x2,0x4a,0x63, 0x3,0x47,0x3e, + 0x2,0x4a,0x7d, 0x1,0x69,0x31, 0x2,0x4b,0x28, 0x2,0x4a,0x64, + 0x1,0x69,0x2e, 0x4,0x43,0x77, 0x2,0x4a,0x79, 0x4,0x43,0x79, + 0x1,0x69,0x2f, 0x2,0x4a,0x6b, 0x2,0x4a,0x76, 0x2,0x4a,0x72, + 0x2,0x4a,0x74, 0x3,0x47,0x43, 0x1,0x69,0x29, 0x2,0x4b,0x27, + 0x1,0x69,0x37, 0x2,0x4a,0x75, 0x3,0x47,0x3b, 0x2,0x4b,0x2a, + 0x4,0x44,0x27, 0x3,0x47,0x3c, 0x2,0x4a,0x65, 0x2,0x4a,0x7a, + 0x1,0x69,0x2c, 0x1,0x69,0x35, 0x1,0x69,0x33, 0x2,0x4a,0x67, + 0x2,0x4a,0x7c, 0x1,0x69,0x32, 0x3,0x47,0x45, 0x3,0x47,0x48, + 0x1,0x69,0x2b, 0x2,0x4a,0x78, 0x3,0x47,0x4d, 0x3,0x47,0x44, + 0x4,0x44,0x28, 0x3,0x4c,0x54, 0x2,0x4b,0x24, 0x3,0x47,0x4c, + 0x2,0x50,0x7c, 0x3,0x47,0x42, 0x2,0x50,0x78, 0x2,0x50,0x74, + 0x2,0x51,0x2a, 0x2,0x51,0x27, 0x1,0x6d,0x37, 0x3,0x4c,0x64, + 0x3,0x4c,0x60, 0x2,0x51,0x2e, 0x2,0x50,0x7b, 0x1,0x6d,0x42, + 0x2,0x51,0x24, 0x3,0x4c,0x4f, 0x3,0x4c,0x51, 0x2,0x50,0x77, + 0x2,0x51,0x23, 0x1,0x6d,0x3f, 0x2,0x51,0x37, 0x4,0x4a,0x3d, + 0x2,0x51,0x34, 0x2,0x51,0x26, 0x2,0x50,0x75, 0x3,0x4c,0x5f, + 0x3,0x4c,0x57, 0x2,0x51,0x2b, 0x2,0x51,0x2d, 0x1,0x6d,0x3b, + 0x2,0x51,0x21, 0x2,0x50,0x7a, 0x2,0x50,0x71, 0x1,0x6d,0x38, + 0x1,0x6d,0x40, 0x4,0x4a,0x48, 0x2,0x51,0x30, 0x1,0x6d,0x41, + 0x2,0x50,0x72, 0x2,0x51,0x36, 0x2,0x51,0x29, 0x2,0x51,0x2f, + 0x1,0x6d,0x3e, 0x3,0x4c,0x4d, 0x3,0x4c,0x50, 0x2,0x51,0x2c, + 0x3,0x4c,0x47, 0x2,0x51,0x33, 0x3,0x4c,0x5b, 0x1,0x6d,0x43, + 0x3,0x4c,0x56, 0x1,0x6d,0x3d, 0x2,0x51,0x25, 0x2,0x50,0x76, + 0x2,0x51,0x38, 0x2,0x50,0x73, 0x2,0x51,0x31, 0x1,0x6d,0x3a, + 0x3,0x4c,0x4a, 0x2,0x50,0x7d, 0x3,0x4c,0x49, 0x2,0x50,0x7e, + 0x1,0x6d,0x39, 0x1,0x6d,0x36, 0x2,0x50,0x79, 0x1,0x6d,0x3c, + 0x3,0x4c,0x52, 0x1,0x6d,0x35, 0x3,0x4c,0x62, 0x2,0x51,0x32, + 0x2,0x51,0x35, 0x2,0x51,0x22, 0x2,0x57,0x55, 0x3,0x4c,0x5e, + 0x3,0x4c,0x59, 0xf,0x4f,0x42, 0x3,0x4c,0x61, 0x3,0x65,0x30, + 0x2,0x57,0x4d, 0x3,0x51,0x2c, 0x2,0x57,0x49, 0x1,0x71,0x21, + 0x3,0x51,0x3c, 0x3,0x51,0x38, 0x1,0x70,0x74, 0x1,0x70,0x79, + 0x1,0x70,0x75, 0x2,0x57,0x57, 0x2,0x57,0x62, 0x1,0x70,0x73, + 0x2,0x57,0x4f, 0x2,0x57,0x58, 0x2,0x51,0x28, 0x2,0x57,0x59, + 0x3,0x51,0x28, 0x3,0x51,0x2b, 0x1,0x70,0x7a, 0x3,0x51,0x40, + 0x2,0x57,0x68, 0x1,0x70,0x7e, 0x1,0x71,0x23, 0x2,0x57,0x4b, + 0x3,0x51,0x3b, 0x1,0x70,0x7d, 0x3,0x51,0x31, 0x2,0x57,0x66, + 0x2,0x57,0x67, 0x2,0x57,0x5d, 0x2,0x57,0x5c, 0x2,0x57,0x54, + 0x3,0x51,0x29, 0x3,0x51,0x3e, 0x2,0x57,0x5e, 0x2,0x57,0x65, + 0x2,0x57,0x64, 0x3,0x51,0x2f, 0x1,0x70,0x78, 0x1,0x70,0x76, + 0x2,0x57,0x56, 0x2,0x57,0x53, 0x3,0x51,0x44, 0x2,0x57,0x50, + 0x2,0x57,0x63, 0x1,0x71,0x22, 0x2,0x57,0x61, 0x1,0x70,0x7c, + 0x1,0x70,0x7b, 0x3,0x51,0x27, 0x2,0x57,0x5b, 0x4,0x4a,0x4b, + 0x2,0x57,0x4a, 0x2,0x57,0x4c, 0x2,0x57,0x4e, 0x2,0x57,0x60, + 0x2,0x57,0x5a, 0x1,0x70,0x77, 0x3,0x51,0x2e, 0x2,0x57,0x51, + 0x3,0x51,0x32, 0x2,0x57,0x5f, 0x3,0x51,0x41, 0x3,0x51,0x3a, + 0xf,0x54,0x7b, 0x2,0x57,0x52, 0x3,0x65,0x31, 0xf,0x55,0x29, + 0x3,0x65,0x32, 0x3,0x54,0x75, 0x1,0x73,0x78, 0x2,0x5d,0x31, + 0x1,0x73,0x71, 0x2,0x5d,0x22, 0x3,0x54,0x7b, 0x2,0x5d,0x2d, + 0x1,0x73,0x73, 0x2,0x5d,0x34, 0x3,0x55,0x21, 0x2,0x5d,0x29, + 0x3,0x54,0x7c, 0x2,0x5d,0x24, 0x3,0x54,0x76, 0x4,0x56,0x45, + 0x2,0x5d,0x35, 0x2,0x5c,0x7e, 0x2,0x5d,0x2b, 0x3,0x55,0x27, + 0x1,0x73,0x7a, 0x2,0x5d,0x30, 0x2,0x5d,0x36, 0x2,0x5d,0x2a, + 0x1,0x73,0x72, 0x2,0x5d,0x2c, 0x2,0x5d,0x21, 0x1,0x73,0x79, + 0x3,0x55,0x23, 0x3,0x54,0x7a, 0x2,0x5d,0x33, 0x2,0x5d,0x26, + 0x1,0x73,0x75, 0x3,0x55,0x24, 0x2,0x5d,0x28, 0x2,0x5d,0x25, + 0x1,0x73,0x7b, 0x2,0x5d,0x27, 0x1,0x73,0x74, 0x1,0x73,0x77, + 0x2,0x5d,0x2f, 0x2,0x5d,0x23, 0x2,0x5d,0x32, 0x3,0x54,0x78, + 0x2,0x5d,0x2e, 0x3,0x55,0x29, 0x3,0x57,0x74, 0x1,0x76,0x4f, + 0x2,0x61,0x73, 0x1,0x76,0x54, 0x1,0x76,0x55, 0x3,0x57,0x77, + 0x3,0x58,0x21, 0x3,0x57,0x76, 0x1,0x76,0x4e, 0x2,0x61,0x72, + 0x3,0x57,0x78, 0x2,0x61,0x6f, 0x2,0x61,0x70, 0x1,0x76,0x52, + 0x2,0x61,0x6a, 0x2,0x61,0x6e, 0x1,0x76,0x51, 0x3,0x57,0x7e, + 0x2,0x61,0x6b, 0x3,0x57,0x79, 0x3,0x58,0x23, 0x3,0x57,0x7d, + 0x3,0x57,0x7a, 0x1,0x76,0x53, 0x1,0x76,0x50, 0x3,0x58,0x22, + 0x2,0x61,0x69, 0x2,0x61,0x6d, 0x2,0x61,0x71, 0x3,0x57,0x7b, + 0x3,0x65,0x33, 0x2,0x65,0x5c, 0x2,0x65,0x59, 0x2,0x65,0x62, + 0x3,0x5a,0x44, 0x2,0x65,0x61, 0x2,0x65,0x5f, 0x2,0x65,0x5a, + 0x3,0x5a,0x4f, 0x1,0x78,0x3f, 0x3,0x5a,0x45, 0x3,0x5a,0x4e, + 0x4,0x5f,0x71, 0x3,0x5a,0x47, 0x3,0x5a,0x4d, 0x2,0x65,0x5b, + 0x1,0x78,0x3e, 0x1,0x73,0x76, 0x2,0x65,0x5e, 0x1,0x78,0x3d, + 0x2,0x65,0x63, 0x2,0x65,0x5d, 0x2,0x65,0x58, 0x2,0x61,0x6c, + 0x3,0x5a,0x48, 0x3,0x5a,0x46, 0x1,0x78,0x3c, 0x3,0x65,0x34, + 0x2,0x65,0x57, 0x2,0x69,0x24, 0x3,0x5c,0x49, 0x2,0x69,0x23, + 0x2,0x65,0x60, 0x1,0x79,0x73, 0x3,0x57,0x75, 0x2,0x69,0x27, + 0x2,0x69,0x28, 0x2,0x69,0x22, 0x2,0x69,0x26, 0x4,0x63,0x50, + 0x2,0x69,0x21, 0x3,0x5c,0x47, 0x3,0x65,0x35, 0x4,0x63,0x4e, + 0x2,0x6b,0x5f, 0x2,0x69,0x25, 0x1,0x7a,0x72, 0x1,0x7a,0x70, + 0x2,0x6b,0x5d, 0x3,0x5e,0x35, 0x3,0x5e,0x34, 0x3,0x5e,0x33, + 0x2,0x6b,0x60, 0x3,0x5e,0x37, 0x2,0x6b,0x5c, 0x2,0x6b,0x5e, + 0x1,0x7a,0x71, 0x3,0x5f,0x4f, 0x3,0x5f,0x4e, 0x2,0x6d,0x53, + 0x2,0x6d,0x54, 0x1,0x7b,0x62, 0x2,0x6d,0x52, 0xf,0x69,0x4c, + 0x3,0x65,0x36, 0x3,0x65,0x37, 0x2,0x6f,0x31, 0x1,0x7c,0x3b, + 0x2,0x6f,0x2f, 0x2,0x6f,0x30, 0x2,0x70,0x3a, 0x3,0x60,0x74, + 0xf,0x6b,0x51, 0x1,0x7d,0x23, 0x2,0x71,0x23, 0x2,0x71,0x21, + 0x2,0x71,0x22, 0x2,0x71,0x24, 0x3,0x61,0x40, 0x3,0x61,0x65, + 0x3,0x61,0x41, 0x2,0x72,0x2b, 0x1,0x45,0x4e, 0x1,0x48,0x39, + 0x3,0x23,0x79, 0x1,0x4e,0x3c, 0x4,0x26,0x71, 0x2,0x27,0x4a, + 0x3,0x29,0x53, 0x3,0x29,0x54, 0x2,0x2b,0x46, 0x4,0x29,0x72, + 0x3,0x2d,0x3c, 0x3,0x31,0x66, 0x2,0x2f,0x77, 0x2,0x2f,0x79, + 0x3,0x31,0x65, 0x2,0x2f,0x78, 0x3,0x31,0x67, 0x2,0x2f,0x7a, + 0x1,0x5b,0x43, 0x2,0x36,0x3b, 0x2,0x2f,0x7b, 0x3,0x36,0x62, + 0x2,0x36,0x3a, 0x2,0x36,0x3c, 0x2,0x36,0x3d, 0x2,0x3c,0x7d, + 0x1,0x60,0x22, 0x2,0x3c,0x7e, 0x2,0x3d,0x22, 0x1,0x60,0x23, + 0x1,0x60,0x21, 0x2,0x3d,0x21, 0x3,0x41,0x7d, 0x2,0x44,0x22, + 0x2,0x43,0x7e, 0x2,0x43,0x7d, 0x3,0x41,0x7c, 0x2,0x43,0x7c, + 0x2,0x43,0x7b, 0x1,0x64,0x58, 0x2,0x44,0x21, 0x1,0x69,0x39, + 0x2,0x4b,0x2b, 0x2,0x4b,0x2d, 0x1,0x69,0x3a, 0x2,0x4b,0x2c, + 0x1,0x6d,0x45, 0x3,0x4c,0x66, 0x1,0x6d,0x44, 0x2,0x51,0x39, + 0x3,0x4c,0x65, 0x3,0x4c,0x67, 0x2,0x57,0x6a, 0x2,0x57,0x69, + 0x2,0x57,0x6b, 0x3,0x51,0x46, 0x3,0x51,0x45, 0x1,0x71,0x24, + 0xf,0x55,0x39, 0x2,0x5d,0x37, 0x1,0x73,0x7c, 0x3,0x55,0x2b, + 0x2,0x61,0x74, 0x1,0x76,0x56, 0x2,0x65,0x64, 0x1,0x7b,0x63, + 0x1,0x45,0x4f, 0x1,0x46,0x5f, 0x1,0x48,0x3a, 0x1,0x4a,0x63, + 0x1,0x4e,0x3d, 0x1,0x4e,0x3e, 0x3,0x29,0x55, 0x3,0x29,0x56, + 0x1,0x51,0x71, 0x3,0x2d,0x3d, 0x3,0x31,0x68, 0x2,0x2f,0x7c, + 0x3,0x3c,0x49, 0x3,0x3c,0x47, 0x4,0x44,0x2d, 0x3,0x41,0x7e, + 0x1,0x64,0x59, 0x3,0x42,0x21, 0x3,0x47,0x53, 0x4,0x4a,0x4e, + 0x2,0x52,0x59, 0x1,0x71,0x25, 0x1,0x76,0x57, 0x1,0x45,0x50, + 0x3,0x22,0x53, 0x1,0x48,0x3b, 0x4,0x26,0x76, 0x2,0x27,0x4c, + 0x1,0x4e,0x3f, 0x2,0x27,0x4b, 0x3,0x29,0x58, 0x2,0x2b,0x47, + 0x1,0x51,0x72, 0x2,0x2b,0x48, 0x5,0x29,0x69, 0x1,0x51,0x73, + 0x2,0x2f,0x7e, 0x1,0x56,0x32, 0x1,0x56,0x31, 0x3,0x31,0x6a, + 0x2,0x36,0x42, 0x2,0x36,0x40, 0x2,0x36,0x41, 0x2,0x36,0x3f, + 0x3,0x36,0x64, 0x2,0x36,0x3e, 0x2,0x3d,0x23, 0x2,0x3d,0x26, + 0x1,0x60,0x25, 0x2,0x3d,0x24, 0x1,0x60,0x24, 0x2,0x3d,0x25, + 0x2,0x44,0x23, 0x3,0x42,0x22, 0x4,0x44,0x31, 0x2,0x4b,0x2e, + 0x2,0x4b,0x2f, 0x2,0x4b,0x30, 0x3,0x47,0x54, 0x2,0x51,0x3c, + 0x2,0x51,0x3b, 0x1,0x6d,0x46, 0x2,0x51,0x3a, 0x2,0x51,0x3d, + 0x2,0x57,0x6c, 0x4,0x50,0x6d, 0x5,0x5b,0x72, 0x2,0x57,0x6d, + 0x2,0x57,0x6e, 0x4,0x56,0x52, 0x2,0x5d,0x38, 0x1,0x73,0x7d, + 0x1,0x76,0x58, 0x2,0x65,0x65, 0x1,0x7a,0x73, 0x2,0x21,0x3f, + 0x3,0x29,0x59, 0x1,0x51,0x74, 0x2,0x2b,0x49, 0x1,0x56,0x33, + 0x4,0x32,0x4e, 0x4,0x32,0x50, 0x1,0x5b,0x44, 0x3,0x36,0x65, + 0x1,0x60,0x26, 0x2,0x3d,0x27, 0x3,0x3c,0x4b, 0x1,0x64,0x5b, + 0x1,0x64,0x5a, 0x3,0x42,0x26, 0x2,0x4b,0x31, 0x2,0x4b,0x32, + 0x1,0x6d,0x47, 0x1,0x6d,0x48, 0x2,0x57,0x70, 0x2,0x57,0x6f, + 0x2,0x61,0x75, 0x2,0x6f,0x32, 0x1,0x45,0x51, 0x2,0x21,0x40, + 0x1,0x46,0x60, 0x3,0x23,0x7a, 0x1,0x4a,0x64, 0x2,0x24,0x48, + 0x3,0x29,0x5a, 0x1,0x51,0x75, 0x1,0x64,0x5c, 0x1,0x45,0x52, + 0x2,0x2b,0x4a, 0x1,0x51,0x76, 0x2,0x2b,0x4b, 0x1,0x73,0x7e, + 0x1,0x45,0x53, 0x3,0x65,0x38, 0x3,0x65,0x39, 0x2,0x27,0x4d, + 0x2,0x2b,0x4c, 0x3,0x2d,0x42, 0x2,0x30,0x25, 0x2,0x30,0x24, + 0x2,0x30,0x22, 0x3,0x31,0x6e, 0x2,0x30,0x21, 0x2,0x30,0x26, + 0x2,0x30,0x23, 0x3,0x31,0x6c, 0x3,0x31,0x6d, 0x1,0x5b,0x45, + 0x1,0x5b,0x46, 0x3,0x36,0x66, 0x1,0x60,0x27, 0x2,0x3d,0x28, + 0x4,0x38,0x4e, 0x2,0x3d,0x29, 0x2,0x3d,0x2a, 0x3,0x3c,0x4d, + 0xf,0x3c,0x3c, 0x3,0x65,0x3a, 0x2,0x44,0x27, 0x2,0x44,0x28, + 0x2,0x44,0x26, 0x3,0x42,0x28, 0x2,0x44,0x24, 0x2,0x44,0x25, + 0x1,0x64,0x5d, 0x2,0x4b,0x33, 0x2,0x51,0x40, 0x2,0x51,0x3f, + 0x2,0x51,0x3e, 0x2,0x51,0x41, 0x2,0x57,0x72, 0x2,0x57,0x71, + 0x1,0x71,0x26, 0x2,0x57,0x73, 0x1,0x74,0x21, 0x2,0x5d,0x39, + 0x3,0x55,0x2d, 0x2,0x61,0x76, 0x2,0x65,0x66, 0x2,0x6d,0x55, + 0x1,0x45,0x54, 0x1,0x46,0x62, 0x1,0x46,0x61, 0x4,0x23,0x21, + 0x1,0x4e,0x40, 0x2,0x21,0x41, 0x2,0x21,0x5f, 0x1,0x48,0x3c, + 0x2,0x22,0x58, 0x2,0x24,0x49, 0x2,0x24,0x4a, 0x1,0x4e,0x41, + 0x3,0x29,0x5d, 0x2,0x27,0x4e, 0x3,0x65,0x3b, 0x1,0x51,0x77, + 0x2,0x2b,0x4d, 0x2,0x2b,0x4e, 0x1,0x56,0x34, 0x1,0x56,0x38, + 0x2,0x30,0x27, 0x1,0x56,0x37, 0x1,0x56,0x35, 0x1,0x56,0x36, + 0x2,0x36,0x43, 0x1,0x5b,0x47, 0x1,0x60,0x2a, 0x3,0x3c,0x4e, + 0x1,0x60,0x28, 0x1,0x60,0x29, 0x2,0x3d,0x2b, 0x3,0x42,0x29, + 0x3,0x42,0x2a, 0x1,0x69,0x3b, 0x1,0x45,0x55, 0x2,0x21,0x60, + 0x3,0x22,0x57, 0x1,0x46,0x63, 0x3,0x22,0x54, 0x2,0x21,0x63, + 0x3,0x24,0x21, 0x1,0x46,0x66, 0x2,0x21,0x62, 0x1,0x46,0x65, + 0x1,0x46,0x64, 0x1,0x4a,0x65, 0x2,0x21,0x61, 0x3,0x22,0x58, + 0x3,0x22,0x59, 0x2,0x22,0x59, 0xf,0x21,0x66, 0x2,0x22,0x5d, + 0x2,0x22,0x5f, 0x2,0x22,0x60, 0x1,0x48,0x46, 0x1,0x48,0x47, + 0x2,0x22,0x5c, 0x1,0x48,0x42, 0x3,0x23,0x7d, 0x2,0x22,0x5a, + 0x3,0x24,0x25, 0x2,0x22,0x5e, 0x1,0x48,0x43, 0x3,0x26,0x55, + 0x1,0x48,0x3e, 0x3,0x23,0x7c, 0x1,0x48,0x3f, 0x3,0x24,0x23, + 0x1,0x48,0x45, 0x2,0x22,0x5b, 0x1,0x48,0x3d, 0x1,0x4a,0x66, + 0x1,0x48,0x40, 0x1,0x48,0x41, 0x1,0x48,0x44, 0xf,0x22,0x5d, + 0x3,0x65,0x3c, 0x2,0x24,0x5b, 0x2,0x24,0x59, 0x2,0x24,0x4c, + 0x1,0x4a,0x72, 0x2,0x24,0x53, 0x1,0x4a,0x6d, 0x2,0x24,0x4d, + 0x3,0x29,0x64, 0x2,0x24,0x55, 0x3,0x26,0x50, 0x2,0x24,0x52, + 0x1,0x4a,0x70, 0x2,0x24,0x51, 0x1,0x4a,0x77, 0x2,0x24,0x5a, + 0x1,0x4a,0x79, 0x3,0x26,0x53, 0x1,0x4a,0x7b, 0x3,0x23,0x7e, + 0x2,0x24,0x4b, 0x3,0x26,0x57, 0x1,0x4a,0x6e, 0x2,0x24,0x5c, + 0x3,0x26,0x51, 0x1,0x4a,0x75, 0x1,0x4a,0x78, 0x3,0x26,0x4c, + 0x2,0x27,0x65, 0x1,0x4a,0x68, 0x1,0x4b,0x21, 0x1,0x4a,0x76, + 0x2,0x24,0x4e, 0x1,0x4a,0x6b, 0x1,0x4a,0x7a, 0x2,0x24,0x56, + 0x1,0x4a,0x69, 0x1,0x4a,0x6a, 0x2,0x27,0x63, 0x2,0x24,0x4f, + 0x1,0x4a,0x71, 0x1,0x4a,0x7c, 0x2,0x24,0x5d, 0x2,0x24,0x50, + 0x1,0x4a,0x6f, 0x3,0x26,0x4d, 0x1,0x4a,0x74, 0x2,0x27,0x4f, + 0x1,0x4a,0x7d, 0x2,0x24,0x57, 0x1,0x4a,0x73, 0x3,0x29,0x63, + 0x1,0x4a,0x7e, 0x1,0x4a,0x67, 0x2,0x24,0x54, 0x1,0x4a,0x6c, + 0x2,0x24,0x58, 0x2,0x27,0x64, 0x3,0x26,0x4e, 0x3,0x26,0x52, + 0x3,0x26,0x5c, 0x3,0x26,0x59, 0x3,0x26,0x56, 0xf,0x24,0x68, + 0x3,0x26,0x5b, 0x1,0x4e,0x4d, 0x1,0x4e,0x5d, 0x2,0x27,0x56, + 0x1,0x4e,0x54, 0x3,0x2d,0x4e, 0x2,0x27,0x6b, 0x1,0x4e,0x45, + 0x3,0x29,0x6b, 0x1,0x4e,0x48, 0x2,0x27,0x62, 0x4,0x27,0x26, + 0x2,0x27,0x54, 0x2,0x27,0x58, 0x1,0x4e,0x50, 0x1,0x4e,0x52, + 0x2,0x27,0x5b, 0x1,0x4e,0x59, 0x1,0x4e,0x4b, 0x1,0x4e,0x49, + 0x1,0x4e,0x4a, 0x1,0x4e,0x58, 0x2,0x27,0x67, 0x1,0x4e,0x53, + 0x2,0x27,0x5a, 0x2,0x27,0x5c, 0x1,0x4e,0x51, 0x1,0x4e,0x56, + 0x2,0x27,0x5d, 0x2,0x27,0x6a, 0x3,0x29,0x6d, 0x1,0x51,0x78, + 0x1,0x4e,0x5c, 0x4,0x26,0x7d, 0x1,0x4e,0x46, 0x2,0x27,0x69, + 0x3,0x29,0x6c, 0x2,0x27,0x6d, 0x2,0x27,0x59, 0x2,0x27,0x6f, + 0x2,0x27,0x60, 0x1,0x4e,0x4f, 0x2,0x27,0x55, 0x1,0x4e,0x4e, + 0x1,0x4e,0x60, 0x1,0x4e,0x55, 0x3,0x29,0x6a, 0x2,0x27,0x53, + 0x2,0x2b,0x57, 0x1,0x4e,0x5b, 0x1,0x4e,0x5f, 0x2,0x27,0x61, + 0x2,0x27,0x66, 0x3,0x29,0x65, 0x1,0x4e,0x61, 0x1,0x4e,0x5a, + 0x1,0x4e,0x4c, 0x1,0x4e,0x42, 0x3,0x29,0x69, 0x1,0x4e,0x47, + 0x4,0x26,0x7b, 0x2,0x27,0x57, 0x1,0x4e,0x43, 0x2,0x27,0x6e, + 0x3,0x29,0x67, 0x2,0x27,0x51, 0x2,0x27,0x50, 0x2,0x27,0x5e, + 0x2,0x27,0x52, 0x1,0x4e,0x5e, 0x1,0x56,0x39, 0x1,0x4e,0x57, + 0x2,0x27,0x5f, 0x1,0x4e,0x44, 0x3,0x2d,0x4f, 0x1,0x52,0x29, + 0x2,0x27,0x6c, 0x3,0x2d,0x46, 0x2,0x2b,0x5e, 0x2,0x2b,0x61, + 0x3,0x2d,0x50, 0x2,0x2b,0x64, 0x2,0x2b,0x59, 0x3,0x2d,0x48, + 0x3,0x2d,0x4a, 0x2,0x2b,0x67, 0x2,0x2b,0x6a, 0x2,0x2b,0x6c, + 0x2,0x2b,0x56, 0x1,0x51,0x79, 0x1,0x51,0x7e, 0x2,0x30,0x2c, + 0x1,0x52,0x30, 0x2,0x2b,0x65, 0x2,0x2b,0x6d, 0x2,0x2b,0x5d, + 0x2,0x2b,0x55, 0x3,0x2d,0x49, 0x3,0x2d,0x47, 0x3,0x2d,0x4d, + 0x2,0x30,0x47, 0x1,0x52,0x23, 0x2,0x2b,0x62, 0x2,0x2b,0x5a, + 0x2,0x2b,0x5c, 0x1,0x52,0x28, 0x3,0x31,0x7a, 0x2,0x2b,0x5f, + 0x1,0x52,0x22, 0x2,0x2b,0x52, 0x2,0x2b,0x68, 0x3,0x2d,0x4b, + 0x2,0x2b,0x6b, 0x3,0x2d,0x45, 0x3,0x2d,0x57, 0x1,0x51,0x7d, + 0x3,0x2d,0x53, 0x1,0x52,0x2b, 0x2,0x2b,0x4f, 0x1,0x52,0x2d, + 0x1,0x51,0x7b, 0x1,0x52,0x31, 0x2,0x2b,0x69, 0x2,0x2b,0x51, + 0x1,0x52,0x2e, 0x2,0x30,0x41, 0x2,0x27,0x68, 0x1,0x52,0x21, + 0x1,0x51,0x7a, 0x2,0x2b,0x58, 0x2,0x2b,0x50, 0x1,0x52,0x2f, + 0x1,0x52,0x27, 0x2,0x2b,0x63, 0x1,0x52,0x2c, 0x1,0x52,0x2a, + 0x2,0x2b,0x5b, 0x1,0x52,0x24, 0x2,0x2b,0x53, 0x1,0x52,0x25, + 0x1,0x52,0x26, 0x2,0x2b,0x54, 0x2,0x2b,0x66, 0x1,0x51,0x7c, + 0x2,0x2b,0x60, 0x4,0x2a,0x21, 0x3,0x2d,0x55, 0x3,0x2d,0x51, + 0x3,0x31,0x77, 0x3,0x31,0x73, 0x2,0x30,0x2f, 0x1,0x56,0x41, + 0x1,0x56,0x46, 0x3,0x31,0x79, 0x3,0x32,0x26, 0x3,0x31,0x76, + 0x2,0x30,0x38, 0x2,0x30,0x3e, 0x2,0x30,0x3a, 0x2,0x30,0x2d, + 0x2,0x30,0x30, 0x2,0x30,0x29, 0x2,0x30,0x2a, 0x1,0x56,0x4d, + 0x1,0x56,0x3e, 0x2,0x30,0x39, 0x2,0x30,0x42, 0x1,0x56,0x48, + 0x1,0x56,0x3a, 0x3,0x31,0x6f, 0x1,0x56,0x43, 0x2,0x30,0x31, + 0x1,0x56,0x45, 0x2,0x30,0x32, 0x2,0x30,0x3c, 0x3,0x32,0x22, + 0x3,0x32,0x25, 0x3,0x31,0x72, 0x1,0x56,0x47, 0x2,0x30,0x4b, + 0x2,0x30,0x2b, 0x1,0x56,0x40, 0x1,0x56,0x3f, 0x1,0x56,0x4b, + 0x2,0x30,0x28, 0x2,0x30,0x49, 0x2,0x30,0x3d, 0x2,0x30,0x4a, + 0x2,0x30,0x44, 0x2,0x30,0x36, 0x2,0x30,0x45, 0x3,0x32,0x21, + 0x2,0x30,0x3f, 0x2,0x30,0x48, 0x2,0x30,0x46, 0x1,0x56,0x4c, + 0x2,0x30,0x37, 0x1,0x56,0x3d, 0x1,0x56,0x3c, 0x1,0x56,0x44, + 0x1,0x56,0x4a, 0x2,0x30,0x43, 0x1,0x56,0x49, 0x2,0x30,0x34, + 0x1,0x5b,0x48, 0x3,0x31,0x78, 0x2,0x30,0x4c, 0x2,0x30,0x33, + 0x2,0x30,0x2e, 0x1,0x56,0x42, 0x1,0x56,0x4e, 0x1,0x56,0x3b, + 0x3,0x32,0x27, 0x2,0x30,0x3b, 0x2,0x30,0x40, 0x3,0x31,0x7d, + 0x3,0x31,0x7b, 0x3,0x31,0x7c, 0x3,0x65,0x3d, 0x1,0x5b,0x6a, + 0x2,0x36,0x45, 0x2,0x36,0x49, 0x3,0x36,0x6f, 0x1,0x5b,0x57, + 0x1,0x5b,0x55, 0x3,0x36,0x7a, 0x3,0x37,0x21, 0x1,0x5b,0x4c, + 0x2,0x36,0x47, 0x2,0x36,0x46, 0x1,0x5b,0x60, 0x3,0x3c,0x50, + 0x2,0x36,0x4c, 0x1,0x5b,0x5a, 0x3,0x36,0x72, 0x2,0x36,0x5e, + 0x2,0x36,0x6a, 0x1,0x5b,0x49, 0x2,0x36,0x5b, 0x2,0x36,0x54, + 0x1,0x5b,0x6c, 0x2,0x36,0x44, 0x3,0x36,0x6a, 0x2,0x36,0x60, + 0x3,0x36,0x6b, 0x1,0x5b,0x69, 0x1,0x5b,0x5d, 0x1,0x5b,0x68, + 0x1,0x5b,0x53, 0x2,0x36,0x50, 0x2,0x36,0x62, 0x2,0x36,0x5a, + 0x1,0x5b,0x54, 0x1,0x5b,0x4e, 0x2,0x36,0x68, 0x3,0x36,0x6c, + 0x2,0x36,0x61, 0x2,0x36,0x63, 0x1,0x5b,0x56, 0x1,0x5b,0x5e, + 0x2,0x36,0x65, 0x2,0x36,0x4e, 0x2,0x36,0x5f, 0x2,0x36,0x53, + 0x2,0x36,0x67, 0x1,0x5b,0x63, 0x1,0x5b,0x4b, 0x1,0x5b,0x61, + 0x2,0x36,0x58, 0x2,0x36,0x56, 0x2,0x36,0x57, 0x1,0x5b,0x58, + 0x2,0x36,0x52, 0x2,0x36,0x51, 0x1,0x5b,0x4d, 0x2,0x36,0x4b, + 0x2,0x36,0x69, 0x1,0x5b,0x4f, 0x2,0x36,0x55, 0x1,0x5b,0x6d, + 0x3,0x36,0x74, 0x1,0x5b,0x67, 0x2,0x36,0x4a, 0x1,0x5b,0x64, + 0x1,0x5b,0x62, 0x1,0x5b,0x6b, 0x2,0x36,0x5c, 0x1,0x5b,0x66, + 0x2,0x30,0x35, 0x2,0x36,0x5d, 0x1,0x5b,0x65, 0x2,0x36,0x64, + 0x1,0x5b,0x4a, 0x2,0x36,0x59, 0x1,0x5b,0x5c, 0x2,0x36,0x4d, + 0x1,0x5b,0x5b, 0x3,0x36,0x7c, 0x1,0x5b,0x59, 0x1,0x5b,0x51, + 0x1,0x5b,0x50, 0x2,0x3d,0x2c, 0x2,0x36,0x66, 0x3,0x3c,0x5d, + 0x3,0x37,0x28, 0x2,0x36,0x4f, 0x3,0x37,0x26, 0x3,0x37,0x23, + 0x2,0x3d,0x41, 0x3,0x36,0x70, 0x1,0x5b,0x52, 0x3,0x36,0x77, + 0x3,0x37,0x24, 0x3,0x36,0x76, 0x3,0x37,0x25, 0x3,0x36,0x79, + 0x4,0x32,0x6d, 0x3,0x36,0x7d, 0x3,0x65,0x3e, 0x3,0x37,0x29, + 0xf,0x36,0x29, 0x3,0x37,0x27, 0x3,0x3c,0x54, 0x1,0x60,0x47, + 0x1,0x5b,0x5f, 0x1,0x60,0x35, 0x2,0x3d,0x3b, 0x1,0x60,0x43, + 0x3,0x3c,0x52, 0x2,0x3d,0x2f, 0x1,0x60,0x32, 0x1,0x60,0x2e, + 0x2,0x3d,0x4d, 0x1,0x60,0x34, 0x1,0x60,0x38, 0x1,0x60,0x33, + 0x1,0x60,0x3c, 0x2,0x3d,0x51, 0x2,0x3d,0x48, 0x3,0x3c,0x6b, + 0x3,0x3c,0x6d, 0x2,0x3d,0x36, 0x1,0x60,0x41, 0x1,0x60,0x3b, + 0x2,0x3d,0x42, 0x1,0x60,0x2b, 0x2,0x3d,0x4e, 0x2,0x3d,0x47, + 0x1,0x60,0x2f, 0x2,0x3d,0x3c, 0x1,0x60,0x3e, 0x2,0x3d,0x59, + 0x2,0x3d,0x5a, 0x4,0x38,0x5b, 0x1,0x60,0x2c, 0x2,0x3d,0x4c, + 0x1,0x60,0x40, 0x2,0x3d,0x40, 0x2,0x3d,0x32, 0x2,0x3d,0x33, + 0x1,0x60,0x44, 0x2,0x3d,0x37, 0x2,0x3d,0x3e, 0x2,0x3d,0x38, + 0x3,0x3c,0x5a, 0x1,0x60,0x42, 0x1,0x60,0x4a, 0x2,0x3d,0x34, + 0x2,0x3d,0x2d, 0x2,0x3d,0x2e, 0x3,0x3c,0x56, 0x2,0x3d,0x30, + 0x1,0x60,0x31, 0x2,0x3d,0x3d, 0x3,0x3c,0x6e, 0x1,0x60,0x3f, + 0x1,0x60,0x48, 0x3,0x3c,0x58, 0x3,0x3c,0x69, 0x2,0x3d,0x3f, + 0x2,0x3d,0x57, 0x2,0x3d,0x4f, 0x1,0x60,0x2d, 0x2,0x3d,0x55, + 0x1,0x60,0x39, 0x3,0x3c,0x66, 0x1,0x60,0x37, 0x3,0x3c,0x64, + 0x2,0x3d,0x5b, 0x1,0x60,0x36, 0x2,0x3d,0x45, 0x2,0x3d,0x39, + 0x2,0x3d,0x43, 0x1,0x60,0x4d, 0x2,0x3d,0x49, 0x2,0x3d,0x46, + 0x2,0x3d,0x35, 0x1,0x60,0x49, 0x2,0x3d,0x53, 0x2,0x3d,0x50, + 0x2,0x3d,0x58, 0x1,0x60,0x30, 0x2,0x3d,0x44, 0x1,0x60,0x4c, + 0x3,0x3c,0x5b, 0x2,0x3d,0x4b, 0x3,0x42,0x3a, 0x3,0x3c,0x60, + 0x1,0x60,0x3a, 0x1,0x60,0x3d, 0x3,0x3c,0x5c, 0x2,0x3d,0x4a, + 0x1,0x60,0x4b, 0x2,0x3d,0x3a, 0x2,0x36,0x48, 0x3,0x3c,0x51, + 0x3,0x3c,0x6c, 0x2,0x3d,0x54, 0x2,0x3d,0x52, 0x2,0x3d,0x56, + 0xf,0x3c,0x5d, 0x3,0x3c,0x62, 0x3,0x65,0x42, 0x4,0x38,0x5e, + 0x3,0x3c,0x63, 0x3,0x3c,0x68, 0xf,0x3c,0x47, 0x3,0x65,0x40, + 0x4,0x38,0x5f, 0x2,0x3d,0x31, 0x1,0x60,0x46, 0x3,0x65,0x3f, + 0x3,0x65,0x41, 0x2,0x44,0x47, 0x2,0x44,0x46, 0x2,0x44,0x2c, + 0x1,0x64,0x63, 0x3,0x42,0x30, 0x2,0x44,0x45, 0x2,0x44,0x2f, + 0x2,0x44,0x30, 0x4,0x3e,0x3f, 0x1,0x64,0x6d, 0x2,0x44,0x4e, + 0x1,0x64,0x68, 0x2,0x44,0x44, 0x3,0x42,0x33, 0x2,0x44,0x29, + 0x1,0x64,0x6e, 0x1,0x64,0x64, 0x2,0x44,0x38, 0x2,0x44,0x2e, + 0x2,0x44,0x31, 0x2,0x44,0x49, 0x1,0x64,0x5e, 0x2,0x44,0x50, + 0x2,0x44,0x48, 0x1,0x64,0x67, 0x2,0x44,0x3d, 0x1,0x64,0x72, + 0x3,0x42,0x2e, 0x3,0x42,0x36, 0x1,0x64,0x71, 0x1,0x64,0x6b, + 0x3,0x42,0x40, 0x4,0x3e,0x36, 0x2,0x44,0x4f, 0x1,0x64,0x5f, + 0x2,0x44,0x3b, 0x2,0x44,0x32, 0x2,0x44,0x3f, 0x2,0x44,0x4b, + 0x1,0x64,0x73, 0x3,0x42,0x39, 0x1,0x64,0x61, 0x2,0x44,0x3a, + 0x3,0x42,0x2d, 0x2,0x44,0x33, 0x1,0x64,0x6a, 0x3,0x42,0x31, + 0x1,0x64,0x69, 0x2,0x44,0x36, 0x2,0x44,0x40, 0x2,0x44,0x4a, + 0x2,0x44,0x2d, 0x2,0x44,0x37, 0x1,0x64,0x62, 0x2,0x44,0x41, + 0x1,0x64,0x6f, 0x1,0x64,0x66, 0x2,0x44,0x34, 0x1,0x64,0x65, + 0x2,0x44,0x2b, 0x2,0x44,0x39, 0x2,0x44,0x4d, 0x1,0x60,0x45, + 0x1,0x69,0x57, 0x2,0x44,0x3c, 0x2,0x4b,0x34, 0x2,0x44,0x3e, + 0x2,0x44,0x4c, 0x1,0x64,0x6c, 0x2,0x44,0x35, 0x1,0x64,0x60, + 0x1,0x64,0x70, 0x1,0x6d,0x5a, 0x2,0x44,0x2a, 0x6,0x54,0x4e, + 0x2,0x44,0x43, 0x3,0x42,0x44, 0x3,0x42,0x3e, 0x3,0x42,0x47, + 0x2,0x44,0x42, 0x3,0x42,0x3d, 0x3,0x42,0x45, 0x3,0x42,0x3f, + 0x3,0x42,0x3b, 0x3,0x42,0x46, 0x2,0x4b,0x50, 0x1,0x69,0x54, + 0x2,0x4b,0x45, 0x2,0x4b,0x4a, 0x1,0x69,0x49, 0x3,0x47,0x56, + 0x2,0x4b,0x36, 0x1,0x69,0x56, 0x3,0x47,0x57, 0x1,0x69,0x40, + 0x2,0x4b,0x35, 0x2,0x4b,0x56, 0x1,0x69,0x58, 0x2,0x4b,0x39, + 0x2,0x4b,0x49, 0x3,0x47,0x65, 0x2,0x4b,0x3b, 0x2,0x4b,0x59, + 0x2,0x4b,0x55, 0x1,0x69,0x3e, 0x1,0x69,0x48, 0x2,0x51,0x5b, + 0x1,0x69,0x55, 0x1,0x69,0x46, 0x2,0x4b,0x37, 0x3,0x47,0x63, + 0x2,0x4b,0x54, 0x1,0x69,0x4a, 0x2,0x4b,0x51, 0x2,0x4b,0x5e, + 0x2,0x4b,0x3d, 0x2,0x4b,0x46, 0x3,0x4c,0x78, 0x3,0x47,0x5b, + 0x2,0x4b,0x5c, 0x2,0x4b,0x52, 0x1,0x69,0x45, 0x3,0x4c,0x6a, + 0x3,0x47,0x64, 0x2,0x4b,0x44, 0x1,0x69,0x3f, 0x1,0x69,0x3d, + 0x1,0x69,0x4f, 0x4,0x44,0x43, 0x3,0x47,0x5f, 0x2,0x4b,0x42, + 0x2,0x4b,0x3f, 0x2,0x4b,0x40, 0x3,0x47,0x5a, 0x2,0x4b,0x58, + 0x3,0x47,0x5c, 0x2,0x4b,0x5d, 0x2,0x4b,0x5b, 0x1,0x69,0x43, + 0x2,0x4b,0x5f, 0x1,0x69,0x47, 0x1,0x69,0x4e, 0x4,0x44,0x44, + 0x2,0x4b,0x38, 0x2,0x51,0x43, 0x2,0x4b,0x41, 0x3,0x47,0x5e, + 0x1,0x69,0x41, 0x1,0x69,0x53, 0x1,0x69,0x50, 0x1,0x69,0x44, + 0x2,0x4b,0x4b, 0x2,0x4b,0x3c, 0x1,0x69,0x51, 0x2,0x4b,0x4d, + 0x1,0x69,0x4b, 0x1,0x69,0x4d, 0x1,0x69,0x3c, 0x3,0x47,0x5d, + 0x2,0x4b,0x4f, 0x2,0x4b,0x47, 0x2,0x4b,0x3a, 0x1,0x69,0x4c, + 0x2,0x4b,0x57, 0x2,0x4b,0x5a, 0x2,0x4b,0x43, 0x2,0x4b,0x4e, + 0x3,0x4c,0x74, 0x1,0x69,0x42, 0x1,0x6d,0x49, 0x2,0x4b,0x4c, + 0x2,0x51,0x42, 0x3,0x47,0x62, 0x2,0x4b,0x53, 0x3,0x47,0x61, + 0x4,0x44,0x52, 0xf,0x4f,0x79, 0x3,0x65,0x44, 0x3,0x65,0x45, + 0x3,0x47,0x66, 0x3,0x65,0x43, 0x2,0x4b,0x3e, 0x2,0x51,0x4c, + 0x2,0x51,0x56, 0x1,0x6d,0x4c, 0x2,0x51,0x55, 0x2,0x51,0x61, + 0x1,0x6d,0x4e, 0x2,0x51,0x53, 0x4,0x4a,0x58, 0x2,0x51,0x57, + 0x1,0x6d,0x59, 0x3,0x4c,0x7d, 0x2,0x51,0x4e, 0x1,0x6d,0x51, + 0x3,0x4c,0x73, 0x2,0x51,0x5a, 0x2,0x57,0x7b, 0x1,0x6d,0x5d, + 0x1,0x6d,0x5c, 0x2,0x51,0x5c, 0x2,0x51,0x4b, 0x2,0x51,0x66, + 0x1,0x6d,0x57, 0x3,0x4c,0x6b, 0x1,0x6d,0x4d, 0x2,0x51,0x5f, + 0x4,0x4a,0x69, 0x2,0x51,0x63, 0x2,0x51,0x68, 0x2,0x51,0x5d, + 0x2,0x51,0x51, 0x1,0x6d,0x50, 0x1,0x6d,0x53, 0x1,0x6d,0x5b, + 0x1,0x6d,0x56, 0x3,0x4c,0x75, 0x2,0x51,0x54, 0x2,0x4b,0x48, + 0x3,0x4c,0x7e, 0x3,0x4c,0x6c, 0x2,0x51,0x50, 0x2,0x51,0x67, + 0x1,0x6d,0x52, 0x3,0x4c,0x79, 0x1,0x6d,0x55, 0x2,0x51,0x69, + 0x1,0x6d,0x4a, 0x2,0x51,0x5e, 0x2,0x51,0x44, 0x2,0x51,0x64, + 0x1,0x74,0x2a, 0x3,0x4c,0x7a, 0x2,0x51,0x52, 0x4,0x50,0x75, + 0x1,0x6d,0x4b, 0x2,0x51,0x4d, 0x1,0x6d,0x4f, 0x2,0x51,0x45, + 0x1,0x69,0x52, 0x2,0x51,0x49, 0x4,0x4a,0x57, 0x2,0x51,0x62, + 0x2,0x51,0x4a, 0x2,0x51,0x48, 0x1,0x6d,0x54, 0x3,0x4c,0x7b, + 0x2,0x51,0x60, 0x3,0x4c,0x77, 0x2,0x51,0x47, 0x2,0x51,0x59, + 0x2,0x51,0x58, 0x2,0x51,0x65, 0x2,0x51,0x4f, 0x1,0x6d,0x58, + 0x4,0x4a,0x64, 0x3,0x65,0x47, 0xf,0x4f,0x7d, 0x3,0x65,0x46, + 0x2,0x57,0x7e, 0x3,0x51,0x56, 0x1,0x71,0x33, 0x1,0x71,0x29, + 0x2,0x58,0x2c, 0x2,0x57,0x76, 0x1,0x71,0x2b, 0x2,0x58,0x24, + 0x1,0x71,0x32, 0x1,0x71,0x2d, 0x2,0x58,0x22, 0x2,0x5d,0x3b, + 0x2,0x58,0x28, 0x2,0x58,0x2e, 0x2,0x58,0x27, 0x2,0x57,0x74, + 0x2,0x58,0x25, 0x2,0x58,0x30, 0x2,0x58,0x32, 0x1,0x71,0x28, + 0x2,0x58,0x31, 0x1,0x71,0x2e, 0x1,0x71,0x34, 0x3,0x51,0x54, + 0x1,0x71,0x31, 0x3,0x51,0x58, 0x2,0x58,0x2b, 0x1,0x71,0x30, + 0x2,0x58,0x26, 0x3,0x51,0x4d, 0x2,0x57,0x78, 0x2,0x57,0x7d, + 0x3,0x51,0x50, 0x2,0x58,0x2a, 0x1,0x71,0x2f, 0x1,0x71,0x2c, + 0x1,0x71,0x27, 0x1,0x71,0x2a, 0x2,0x57,0x7c, 0x4,0x51,0x22, + 0x2,0x51,0x46, 0x2,0x57,0x77, 0x2,0x57,0x7a, 0x2,0x58,0x2d, + 0x2,0x58,0x21, 0x2,0x57,0x75, 0x2,0x5d,0x3a, 0x2,0x58,0x2f, + 0x2,0x57,0x79, 0x2,0x58,0x29, 0x3,0x4c,0x71, 0x3,0x51,0x55, + 0x2,0x5d,0x3d, 0x1,0x74,0x2e, 0x3,0x55,0x30, 0x3,0x55,0x2f, + 0x1,0x74,0x22, 0x3,0x55,0x35, 0x3,0x55,0x36, 0x1,0x74,0x26, + 0x2,0x5d,0x3f, 0x2,0x5d,0x45, 0x2,0x5d,0x43, 0x1,0x74,0x24, + 0x1,0x74,0x25, 0x1,0x74,0x2c, 0x2,0x5d,0x46, 0x2,0x5d,0x3e, + 0x1,0x74,0x27, 0x3,0x55,0x31, 0x2,0x5d,0x42, 0x2,0x5d,0x41, + 0x2,0x5d,0x47, 0x1,0x74,0x2d, 0x3,0x55,0x37, 0x1,0x74,0x28, + 0x1,0x74,0x2b, 0x2,0x5d,0x40, 0x1,0x74,0x2f, 0x1,0x74,0x29, + 0x1,0x74,0x30, 0x1,0x74,0x23, 0x2,0x5d,0x44, 0x3,0x5a,0x55, + 0x2,0x5d,0x3c, 0x3,0x51,0x59, 0x3,0x55,0x39, 0x2,0x62,0x25, + 0x3,0x65,0x48, 0x1,0x76,0x5d, 0x2,0x62,0x22, 0x2,0x62,0x24, + 0x3,0x58,0x28, 0x1,0x76,0x5b, 0x2,0x61,0x7e, 0x2,0x62,0x21, + 0x2,0x61,0x7a, 0x3,0x58,0x2a, 0x3,0x58,0x27, 0x2,0x58,0x23, + 0x2,0x61,0x7b, 0x1,0x76,0x5c, 0x2,0x61,0x77, 0x3,0x58,0x26, + 0x1,0x76,0x59, 0x2,0x62,0x26, 0x1,0x76,0x5a, 0x2,0x61,0x78, + 0x2,0x61,0x79, 0x2,0x61,0x7d, 0x1,0x76,0x5f, 0x3,0x58,0x29, + 0x1,0x76,0x5e, 0x4,0x5b,0x5e, 0x3,0x58,0x2b, 0x2,0x61,0x7c, + 0x1,0x78,0x45, 0x2,0x65,0x6a, 0x2,0x65,0x70, 0x1,0x78,0x46, + 0x2,0x65,0x67, 0x1,0x78,0x43, 0x1,0x78,0x40, 0x2,0x65,0x72, + 0x1,0x78,0x44, 0x3,0x5a,0x52, 0x1,0x78,0x41, 0x2,0x65,0x69, + 0x2,0x65,0x6c, 0x2,0x65,0x6d, 0x2,0x65,0x6e, 0x2,0x65,0x71, + 0x3,0x5a,0x54, 0x2,0x62,0x23, 0x2,0x65,0x68, 0x1,0x78,0x42, + 0x2,0x65,0x6f, 0x2,0x69,0x34, 0x2,0x65,0x6b, 0x3,0x5a,0x53, + 0x3,0x65,0x4a, 0x3,0x65,0x49, 0x2,0x69,0x2b, 0x1,0x79,0x75, + 0x2,0x69,0x2e, 0x1,0x79,0x76, 0x2,0x69,0x37, 0x2,0x69,0x2d, + 0x2,0x69,0x2a, 0x3,0x5c,0x51, 0x2,0x69,0x2c, 0x2,0x69,0x30, + 0x2,0x69,0x33, 0x2,0x69,0x32, 0x2,0x69,0x36, 0x2,0x69,0x29, + 0x3,0x5c,0x4f, 0x1,0x79,0x74, 0x2,0x69,0x31, 0x2,0x69,0x35, + 0x2,0x69,0x38, 0x2,0x69,0x2f, 0x2,0x6b,0x61, 0x2,0x6b,0x62, + 0x2,0x6b,0x66, 0x2,0x6b,0x67, 0x3,0x5e,0x3c, 0x2,0x6b,0x64, + 0x2,0x6b,0x65, 0x2,0x6b,0x63, 0x3,0x5e,0x3a, 0x1,0x7a,0x74, + 0x3,0x5e,0x3b, 0x1,0x7b,0x64, 0x2,0x6d,0x59, 0x3,0x60,0x36, + 0x3,0x5f,0x52, 0x2,0x6d,0x56, 0x2,0x6d,0x57, 0x2,0x6d,0x58, + 0x1,0x7b,0x65, 0x3,0x60,0x37, 0x2,0x6f,0x34, 0x2,0x6f,0x33, + 0x3,0x65,0x4b, 0x2,0x70,0x3d, 0x1,0x7c,0x60, 0x2,0x70,0x3b, + 0x2,0x70,0x3e, 0x2,0x70,0x3c, 0x2,0x71,0x25, 0x1,0x7d,0x24, + 0x1,0x7d,0x32, 0x2,0x71,0x71, 0x2,0x71,0x5b, 0x3,0x61,0x79, + 0x2,0x71,0x70, 0x2,0x72,0x3e, 0x2,0x72,0x3f, 0x1,0x45,0x56, + 0x4,0x21,0x50, 0x3,0x24,0x28, 0x3,0x24,0x26, 0x1,0x48,0x48, + 0x2,0x22,0x61, 0x3,0x24,0x27, 0x3,0x24,0x2b, 0x2,0x24,0x5e, + 0x3,0x26,0x62, 0x1,0x4b,0x22, 0x3,0x26,0x5f, 0x1,0x4b,0x25, + 0x3,0x26,0x5e, 0x2,0x24,0x5f, 0x3,0x26,0x63, 0x1,0x4b,0x23, + 0x1,0x4b,0x24, 0x3,0x26,0x60, 0xf,0x24,0x71, 0x3,0x29,0x77, + 0x2,0x27,0x78, 0x2,0x27,0x7a, 0x2,0x27,0x75, 0x2,0x27,0x72, + 0x2,0x27,0x74, 0x3,0x29,0x74, 0x3,0x29,0x70, 0x3,0x29,0x75, + 0x1,0x4e,0x65, 0x3,0x29,0x6f, 0x3,0x29,0x79, 0x3,0x29,0x76, + 0x1,0x4e,0x63, 0x3,0x29,0x72, 0x3,0x29,0x71, 0x2,0x27,0x76, + 0x1,0x4e,0x64, 0x2,0x27,0x73, 0x2,0x27,0x70, 0x1,0x4e,0x62, + 0x2,0x27,0x77, 0x4,0x27,0x29, 0x2,0x27,0x71, 0x1,0x4e,0x66, + 0x2,0x27,0x79, 0x4,0x27,0x2b, 0x2,0x2b,0x6f, 0x3,0x2d,0x5e, + 0x2,0x2b,0x73, 0x3,0x2d,0x5c, 0x3,0x2d,0x5a, 0x1,0x52,0x3a, + 0x3,0x2d,0x58, 0x4,0x2a,0x26, 0x3,0x2d,0x65, 0x3,0x2d,0x62, + 0x2,0x2b,0x76, 0x3,0x2d,0x5f, 0x1,0x52,0x32, 0x1,0x52,0x35, + 0x1,0x52,0x37, 0x1,0x52,0x39, 0x1,0x52,0x36, 0x2,0x2b,0x72, + 0x2,0x2b,0x71, 0x3,0x2d,0x64, 0x1,0x52,0x34, 0x2,0x2b,0x74, + 0x2,0x2b,0x75, 0x3,0x2d,0x63, 0x2,0x2b,0x6e, 0x1,0x52,0x38, + 0x3,0x2d,0x68, 0x1,0x52,0x33, 0x3,0x2d,0x5d, 0x2,0x2b,0x70, + 0x3,0x65,0x4d, 0x4,0x2a,0x28, 0x3,0x32,0x28, 0x2,0x30,0x5a, + 0x2,0x30,0x5b, 0x2,0x30,0x5c, 0x1,0x56,0x53, 0x4,0x2d,0x75, + 0x1,0x56,0x4f, 0x2,0x30,0x51, 0x3,0x32,0x2a, 0x2,0x30,0x59, + 0x2,0x30,0x5e, 0x1,0x56,0x54, 0x3,0x32,0x2b, 0x2,0x30,0x4f, + 0x2,0x30,0x55, 0x2,0x30,0x4e, 0x2,0x30,0x58, 0x3,0x32,0x31, + 0x3,0x32,0x2f, 0x2,0x30,0x54, 0x1,0x56,0x50, 0x1,0x56,0x52, + 0x2,0x30,0x5d, 0x3,0x32,0x29, 0x2,0x30,0x4d, 0x2,0x30,0x50, + 0x2,0x30,0x56, 0x3,0x32,0x2d, 0x2,0x30,0x57, 0x2,0x30,0x5f, + 0x2,0x30,0x53, 0x3,0x32,0x2c, 0x1,0x56,0x51, 0x3,0x65,0x4f, + 0x3,0x65,0x4e, 0x3,0x32,0x30, 0x1,0x5b,0x72, 0x2,0x36,0x71, + 0x3,0x37,0x30, 0x3,0x37,0x32, 0x2,0x36,0x73, 0x2,0x36,0x6f, + 0x3,0x37,0x2f, 0x2,0x36,0x7b, 0x2,0x36,0x6d, 0x2,0x36,0x7a, + 0x1,0x5b,0x6e, 0x2,0x36,0x6b, 0x2,0x3d,0x5f, 0x2,0x36,0x75, + 0x1,0x5b,0x71, 0x3,0x37,0x35, 0x2,0x36,0x76, 0x2,0x36,0x79, + 0x3,0x37,0x2e, 0x2,0x36,0x7d, 0x3,0x37,0x2c, 0x2,0x36,0x72, + 0x4,0x32,0x72, 0x2,0x36,0x77, 0x3,0x37,0x2d, 0x3,0x37,0x31, + 0x1,0x5b,0x6f, 0x1,0x5b,0x70, 0x2,0x36,0x7c, 0x2,0x36,0x70, + 0x2,0x36,0x6c, 0x2,0x36,0x7e, 0x3,0x37,0x33, 0x2,0x36,0x74, + 0x3,0x65,0x50, 0x3,0x65,0x51, 0x2,0x36,0x78, 0x2,0x36,0x6e, + 0x1,0x60,0x4e, 0x1,0x60,0x4f, 0x2,0x3d,0x69, 0x1,0x60,0x55, + 0x3,0x3c,0x74, 0x2,0x3d,0x5d, 0x2,0x3d,0x66, 0x2,0x3d,0x5c, + 0x1,0x60,0x52, 0x2,0x3d,0x64, 0x2,0x3d,0x62, 0x3,0x3c,0x7d, + 0x2,0x3d,0x63, 0x1,0x60,0x50, 0x3,0x3c,0x7c, 0x2,0x3d,0x67, + 0xf,0x3c,0x7e, 0x3,0x3c,0x6f, 0x3,0x3c,0x7a, 0x3,0x3c,0x72, + 0x3,0x3d,0x21, 0x2,0x3d,0x60, 0x2,0x3d,0x5e, 0x1,0x60,0x51, + 0x2,0x3d,0x61, 0x2,0x3d,0x65, 0x3,0x3c,0x7b, 0x3,0x3c,0x79, + 0x3,0x3c,0x71, 0x1,0x60,0x53, 0x3,0x3c,0x73, 0x3,0x3c,0x77, + 0x3,0x65,0x53, 0x2,0x3d,0x68, 0x3,0x65,0x54, 0x3,0x65,0x55, + 0x3,0x65,0x52, 0x2,0x44,0x56, 0x2,0x44,0x5d, 0x2,0x44,0x5f, + 0x2,0x44,0x65, 0x3,0x42,0x57, 0x1,0x65,0x22, 0x2,0x44,0x51, + 0x3,0x42,0x4c, 0x1,0x64,0x78, 0x3,0x42,0x4e, 0x2,0x44,0x60, + 0x1,0x64,0x7d, 0x2,0x44,0x66, 0x1,0x64,0x74, 0x3,0x42,0x51, + 0x2,0x44,0x63, 0x3,0x42,0x58, 0x2,0x44,0x53, 0x2,0x44,0x64, + 0x2,0x44,0x52, 0x1,0x65,0x24, 0x3,0x42,0x52, 0x2,0x44,0x5e, + 0x1,0x64,0x75, 0x2,0x44,0x67, 0x3,0x48,0x3c, 0x1,0x64,0x7a, + 0x2,0x44,0x57, 0x1,0x65,0x21, 0x2,0x44,0x62, 0x2,0x44,0x55, + 0x2,0x44,0x5c, 0x2,0x44,0x58, 0x2,0x44,0x54, 0x1,0x64,0x77, + 0x1,0x64,0x7e, 0x1,0x64,0x7c, 0x1,0x64,0x79, 0x1,0x65,0x23, + 0x1,0x64,0x76, 0x2,0x44,0x5b, 0x3,0x42,0x4f, 0x1,0x64,0x7b, + 0x3,0x42,0x59, 0x1,0x60,0x54, 0x3,0x42,0x49, 0x2,0x44,0x61, + 0x3,0x65,0x59, 0x2,0x44,0x59, 0x3,0x42,0x53, 0x3,0x65,0x57, + 0x3,0x65,0x58, 0x3,0x65,0x56, 0x2,0x44,0x5a, 0x4,0x44,0x57, + 0x4,0x44,0x5b, 0x2,0x4b,0x67, 0x3,0x47,0x6f, 0x1,0x69,0x5b, + 0x3,0x47,0x6e, 0x3,0x47,0x6c, 0x2,0x4b,0x63, 0x2,0x4b,0x69, + 0x2,0x4b,0x65, 0x3,0x47,0x70, 0x1,0x69,0x5d, 0x2,0x4b,0x64, + 0x2,0x4b,0x68, 0x2,0x4b,0x60, 0x3,0x47,0x72, 0x2,0x4b,0x62, + 0x1,0x69,0x5c, 0x3,0x47,0x6a, 0x3,0x47,0x6d, 0x3,0x47,0x6b, + 0x3,0x47,0x68, 0x2,0x4b,0x66, 0x2,0x4b,0x61, 0x3,0x47,0x67, + 0x1,0x69,0x5e, 0x3,0x65,0x5b, 0x1,0x69,0x59, 0xf,0x49,0x4b, + 0x3,0x65,0x5a, 0x2,0x4b,0x6a, 0xf,0x49,0x5f, 0x1,0x69,0x5a, + 0x2,0x51,0x6f, 0x2,0x51,0x6c, 0x2,0x51,0x78, 0x2,0x51,0x72, + 0x2,0x51,0x74, 0x1,0x6d,0x5e, 0x2,0x51,0x6e, 0x2,0x51,0x76, + 0x3,0x4d,0x2a, 0x3,0x4d,0x24, 0x2,0x51,0x75, 0x2,0x51,0x73, + 0x3,0x4d,0x29, 0x2,0x51,0x79, 0x1,0x6d,0x61, 0x2,0x51,0x70, + 0x2,0x51,0x77, 0x3,0x4d,0x28, 0x1,0x6d,0x5f, 0x3,0x4d,0x25, + 0x3,0x4d,0x22, 0x2,0x51,0x6b, 0x2,0x51,0x6d, 0x1,0x6d,0x60, + 0x2,0x51,0x6a, 0x2,0x51,0x7a, 0x3,0x65,0x5c, 0x2,0x51,0x71, + 0x3,0x51,0x62, 0x3,0x51,0x5a, 0x2,0x58,0x36, 0x1,0x71,0x3b, + 0x3,0x51,0x60, 0x3,0x51,0x5c, 0x2,0x58,0x41, 0x2,0x58,0x3f, + 0x1,0x71,0x35, 0x2,0x58,0x35, 0x2,0x58,0x38, 0x2,0x58,0x39, + 0x2,0x58,0x34, 0x1,0x71,0x3f, 0x1,0x71,0x40, 0x2,0x58,0x33, + 0x2,0x58,0x42, 0x2,0x58,0x3d, 0x1,0x71,0x39, 0x1,0x71,0x36, + 0x2,0x58,0x3c, 0x2,0x58,0x3a, 0x3,0x51,0x63, 0x4,0x51,0x23, + 0x1,0x71,0x3c, 0x2,0x58,0x3e, 0x1,0x71,0x37, 0x3,0x51,0x5e, + 0x1,0x71,0x38, 0x3,0x51,0x66, 0x2,0x58,0x3b, 0x1,0x71,0x3a, + 0x2,0x58,0x37, 0x7,0x2f,0x4f, 0x2,0x58,0x40, 0x1,0x71,0x3d, + 0x2,0x58,0x43, 0x2,0x58,0x44, 0x1,0x71,0x3e, 0x3,0x65,0x5d, + 0x3,0x65,0x5e, 0x1,0x74,0x32, 0x1,0x74,0x39, 0x2,0x5d,0x48, + 0x2,0x5d,0x4e, 0x3,0x55,0x3c, 0x2,0x5d,0x4c, 0x1,0x74,0x35, + 0x1,0x74,0x34, 0x1,0x74,0x31, 0x2,0x5d,0x4a, 0x3,0x55,0x3e, + 0x3,0x55,0x43, 0x3,0x55,0x40, 0x1,0x74,0x37, 0x1,0x74,0x36, + 0x1,0x74,0x33, 0x3,0x55,0x41, 0x2,0x5d,0x4d, 0x2,0x5d,0x49, + 0x2,0x5d,0x4b, 0x3,0x55,0x42, 0x1,0x74,0x38, 0xf,0x5a,0x73, + 0x1,0x76,0x63, 0x2,0x62,0x29, 0x3,0x58,0x2d, 0x1,0x76,0x60, + 0x1,0x76,0x61, 0x2,0x62,0x2b, 0x1,0x76,0x62, 0x2,0x62,0x28, + 0x3,0x58,0x2e, 0x2,0x62,0x27, 0x2,0x65,0x76, 0x2,0x62,0x2a, + 0x3,0x5a,0x56, 0x2,0x65,0x77, 0x1,0x78,0x47, 0x2,0x65,0x75, + 0x3,0x5a,0x57, 0x4,0x5f,0x7e, 0x2,0x65,0x74, 0x3,0x5c,0x59, + 0x2,0x65,0x73, 0x1,0x78,0x48, 0x3,0x65,0x5f, 0x3,0x5c,0x56, + 0x1,0x79,0x77, 0x3,0x5c,0x58, 0x3,0x5c,0x55, 0x2,0x69,0x39, + 0x2,0x69,0x3a, 0x3,0x5a,0x58, 0x3,0x5c,0x53, 0x3,0x5c,0x57, + 0x3,0x65,0x61, 0x2,0x6b,0x6a, 0x2,0x6b,0x69, 0x1,0x7a,0x75, + 0x3,0x5f,0x53, 0x2,0x6b,0x68, 0x2,0x6d,0x5a, 0x2,0x6d,0x5b, + 0x3,0x5f,0x54, 0x3,0x60,0x39, 0x2,0x6f,0x35, 0x2,0x70,0x3f, + 0x3,0x61,0x43, 0x3,0x61,0x42, 0x2,0x71,0x26, 0x2,0x72,0x2c, + 0x1,0x7d,0x46, 0x2,0x72,0x40, 0x1,0x45,0x57, 0x4,0x21,0x51, + 0x1,0x4e,0x67, 0x1,0x4e,0x68, 0x3,0x2d,0x69, 0x4,0x2a,0x2a, + 0x1,0x52,0x3b, 0x3,0x3d,0x22, 0x4,0x4a,0x6c, 0x1,0x74,0x3a, + 0x1,0x45,0x58, 0x1,0x4e,0x69, 0x1,0x56,0x55, 0x1,0x65,0x25, + 0x1,0x45,0x59, 0x3,0x2d,0x6b, 0x1,0x5b,0x73, 0x1,0x69,0x5f, + 0x2,0x21,0x42, 0x3,0x29,0x7c, 0x2,0x2b,0x77, 0x2,0x30,0x60, + 0x4,0x3e,0x4c, 0x2,0x4b,0x6b, 0x4,0x4a,0x6d, 0x1,0x74,0x3b, + 0x1,0x45,0x5a, 0x1,0x4e,0x6a, 0x2,0x2b,0x78, 0x2,0x2b,0x79, + 0x2,0x3d,0x6a, 0x1,0x60,0x56, 0x3,0x42,0x5d, 0x2,0x44,0x68, + 0x3,0x42,0x5c, 0x3,0x42,0x5b, 0x1,0x65,0x26, 0x2,0x4b,0x6c, + 0x4,0x44,0x5e, 0x3,0x4d,0x2e, 0x1,0x6d,0x62, 0x3,0x4d,0x2d, + 0x1,0x78,0x49, 0x1,0x45,0x5b, 0x2,0x3d,0x6b, 0x1,0x45,0x5c, + 0x1,0x48,0x4a, 0x2,0x22,0x62, 0x1,0x48,0x49, 0x1,0x4b,0x28, + 0x1,0x4b,0x27, 0x1,0x4b,0x26, 0x2,0x24,0x60, 0x3,0x26,0x64, + 0x3,0x2a,0x21, 0x3,0x2a,0x22, 0x1,0x4e,0x6b, 0x3,0x2a,0x23, + 0x1,0x4e,0x6c, 0x2,0x27,0x7b, 0x4,0x27,0x31, 0x2,0x2b,0x7a, + 0x3,0x2d,0x6d, 0x2,0x2b,0x7d, 0x1,0x52,0x3d, 0x2,0x2b,0x7b, + 0x4,0x2a,0x2f, 0x1,0x52,0x3c, 0x2,0x2b,0x7c, 0x1,0x52,0x3e, + 0x2,0x30,0x63, 0x2,0x30,0x62, 0x2,0x30,0x61, 0x1,0x56,0x56, + 0x3,0x32,0x36, 0x2,0x37,0x22, 0x2,0x37,0x23, 0x1,0x5b,0x74, + 0x2,0x37,0x21, 0x2,0x37,0x24, 0x1,0x60,0x58, 0x1,0x5b,0x75, + 0x3,0x3d,0x24, 0x3,0x3d,0x23, 0x1,0x60,0x57, 0x2,0x3d,0x6f, + 0x2,0x3d,0x6e, 0x3,0x3d,0x25, 0x2,0x3d,0x6c, 0x2,0x3d,0x6d, + 0x2,0x3d,0x70, 0x2,0x44,0x6a, 0x2,0x44,0x69, 0x2,0x44,0x6d, + 0x4,0x3e,0x4f, 0x2,0x44,0x6c, 0x2,0x44,0x6b, 0x1,0x69,0x60, + 0x2,0x4b,0x6f, 0x3,0x47,0x75, 0x2,0x4b,0x6e, 0x1,0x69,0x61, + 0x2,0x4b,0x6d, 0x2,0x51,0x7b, 0x3,0x4d,0x2f, 0x2,0x51,0x7c, + 0x1,0x6d,0x63, 0x4,0x51,0x2d, 0x2,0x58,0x45, 0x2,0x58,0x46, + 0x5,0x4e,0x37, 0x2,0x65,0x7c, 0x1,0x78,0x4a, 0x2,0x65,0x7b, + 0x2,0x65,0x7a, 0x2,0x65,0x78, 0x2,0x65,0x79, 0x1,0x7a,0x76, + 0x2,0x69,0x3b, 0x2,0x6d,0x5c, 0x2,0x71,0x27, 0x3,0x61,0x7b, + 0x1,0x45,0x5d, 0x4,0x21,0x38, 0x2,0x21,0x64, 0x1,0x46,0x67, + 0x2,0x21,0x65, 0x3,0x24,0x2c, 0x3,0x24,0x2d, 0x4,0x23,0x27, + 0x2,0x22,0x63, 0x2,0x22,0x64, 0x3,0x26,0x6b, 0x3,0x26,0x69, + 0x2,0x24,0x66, 0x3,0x26,0x66, 0x3,0x26,0x67, 0x2,0x24,0x62, + 0x3,0x26,0x6a, 0x2,0x24,0x61, 0x1,0x4e,0x6d, 0x2,0x24,0x65, + 0x1,0x4b,0x2a, 0x2,0x24,0x63, 0x1,0x4b,0x29, 0x2,0x24,0x67, + 0x2,0x24,0x64, 0x3,0x26,0x68, 0x2,0x28,0x21, 0x2,0x2b,0x7e, + 0x2,0x27,0x7d, 0x2,0x28,0x26, 0x3,0x2a,0x26, 0x1,0x4e,0x6e, + 0x3,0x2a,0x2a, 0x1,0x4e,0x71, 0x2,0x28,0x27, 0x2,0x28,0x23, + 0x3,0x2a,0x27, 0x2,0x28,0x24, 0x4,0x27,0x36, 0x2,0x27,0x7c, + 0x1,0x4e,0x70, 0x2,0x27,0x7e, 0x1,0x4e,0x6f, 0x2,0x28,0x25, + 0x3,0x2a,0x28, 0x2,0x28,0x22, 0x6,0x2c,0x7e, 0x2,0x2c,0x24, + 0x1,0x52,0x40, 0x1,0x52,0x41, 0x3,0x2d,0x75, 0x2,0x2c,0x27, + 0x2,0x2c,0x21, 0x3,0x2d,0x74, 0x2,0x2c,0x26, 0x3,0x2d,0x70, + 0x2,0x2c,0x22, 0x1,0x52,0x3f, 0x2,0x2c,0x25, 0x2,0x2c,0x23, + 0x3,0x2d,0x73, 0x3,0x2d,0x71, 0x2,0x30,0x69, 0x2,0x30,0x66, + 0x3,0x32,0x38, 0x2,0x30,0x68, 0x1,0x56,0x5b, 0x1,0x56,0x5a, + 0x1,0x56,0x58, 0x2,0x30,0x65, 0x2,0x30,0x6a, 0x1,0x56,0x57, + 0x1,0x56,0x59, 0x2,0x30,0x67, 0x2,0x37,0x2c, 0x2,0x30,0x64, + 0x2,0x30,0x6b, 0x3,0x32,0x39, 0x4,0x33,0x23, 0x4,0x33,0x2a, + 0x3,0x3d,0x26, 0x2,0x37,0x27, 0x2,0x37,0x2b, 0x5,0x33,0x54, + 0x2,0x37,0x2a, 0x2,0x3d,0x72, 0x2,0x3d,0x7d, 0x4,0x33,0x2d, + 0x3,0x37,0x3b, 0x2,0x37,0x2d, 0x3,0x37,0x3a, 0x2,0x37,0x28, + 0x2,0x3d,0x71, 0x1,0x5b,0x79, 0x4,0x33,0x22, 0x4,0x33,0x2c, + 0x1,0x5b,0x78, 0x2,0x37,0x26, 0x2,0x37,0x29, 0x1,0x5b,0x7a, + 0x3,0x37,0x39, 0x1,0x5b,0x77, 0x1,0x5b,0x76, 0x2,0x37,0x25, + 0x2,0x37,0x2e, 0x2,0x3d,0x74, 0x2,0x3d,0x7b, 0x3,0x3d,0x27, + 0x1,0x60,0x5a, 0x2,0x3d,0x7a, 0x2,0x3d,0x77, 0x3,0x3d,0x2e, + 0x1,0x60,0x5c, 0x3,0x3d,0x29, 0x3,0x3d,0x2b, 0x3,0x3d,0x2a, + 0x2,0x3d,0x79, 0x3,0x42,0x61, 0x3,0x3d,0x2d, 0x2,0x3d,0x73, + 0x2,0x3d,0x75, 0x2,0x3d,0x78, 0x2,0x3d,0x76, 0x1,0x60,0x5b, + 0x2,0x3d,0x7c, 0x1,0x60,0x59, 0x1,0x65,0x27, 0x3,0x3d,0x28, + 0x2,0x44,0x71, 0x2,0x44,0x70, 0x2,0x44,0x6e, 0x6,0x54,0x7c, + 0x1,0x65,0x2a, 0x1,0x65,0x29, 0x2,0x44,0x72, 0x3,0x42,0x5f, + 0x2,0x44,0x6f, 0x2,0x4b,0x70, 0x1,0x69,0x62, 0x1,0x65,0x28, + 0x3,0x42,0x62, 0x3,0x65,0x62, 0x3,0x65,0x63, 0x2,0x44,0x74, + 0x2,0x44,0x73, 0x3,0x4d,0x30, 0x2,0x4b,0x73, 0x2,0x4b,0x71, + 0x1,0x6d,0x64, 0x3,0x47,0x79, 0x1,0x69,0x63, 0x2,0x4b,0x72, + 0x2,0x51,0x7e, 0x3,0x47,0x78, 0x3,0x47,0x7a, 0x3,0x47,0x77, + 0x4,0x4a,0x77, 0x1,0x6d,0x65, 0x2,0x51,0x7d, 0x2,0x52,0x28, + 0x2,0x52,0x27, 0x2,0x52,0x25, 0x4,0x4a,0x75, 0x2,0x52,0x24, + 0x2,0x52,0x21, 0x2,0x52,0x22, 0x2,0x52,0x23, 0x2,0x52,0x26, + 0x2,0x52,0x29, 0x2,0x58,0x4b, 0x2,0x58,0x48, 0x2,0x58,0x49, + 0x1,0x71,0x41, 0x2,0x58,0x47, 0x2,0x58,0x4d, 0x2,0x58,0x4c, + 0x2,0x58,0x4a, 0x2,0x5d,0x50, 0x2,0x5d,0x51, 0x1,0x74,0x3c, + 0x3,0x55,0x49, 0x1,0x74,0x3d, 0x2,0x5d,0x4f, 0x4,0x56,0x6c, + 0x1,0x76,0x65, 0x2,0x62,0x2c, 0x1,0x76,0x64, 0x1,0x78,0x4b, + 0x4,0x60,0x25, 0x1,0x78,0x4c, 0x1,0x79,0x78, 0x2,0x69,0x3d, + 0x2,0x69,0x3c, 0x2,0x6b,0x6b, 0x2,0x6d,0x5d, 0x1,0x7b,0x66, + 0x2,0x6f,0x37, 0x2,0x6f,0x36, 0x2,0x6f,0x38, 0x1,0x46,0x68, + 0x2,0x2c,0x28, 0x1,0x56,0x5c, 0x1,0x5b,0x7b, 0x2,0x37,0x2f, + 0x1,0x46,0x69, 0x2,0x21,0x66, 0x1,0x45,0x5e, 0x3,0x22,0x5a, + 0x3,0x21,0x6b, 0x2,0x22,0x65, 0x3,0x24,0x2f, 0x4,0x23,0x2a, + 0xf,0x22,0x66, 0x2,0x24,0x6c, 0x2,0x24,0x6a, 0x2,0x24,0x6b, + 0x2,0x24,0x68, 0x1,0x4b,0x2b, 0x2,0x24,0x69, 0x3,0x26,0x6e, + 0x3,0x2a,0x33, 0x2,0x28,0x2f, 0x3,0x2a,0x2d, 0x1,0x4e,0x74, + 0x2,0x28,0x2d, 0x2,0x28,0x29, 0x2,0x28,0x2c, 0x3,0x2a,0x2c, + 0x2,0x28,0x28, 0x1,0x4e,0x76, 0x2,0x28,0x2b, 0x3,0x2a,0x2b, + 0x1,0x4e,0x73, 0x1,0x4e,0x72, 0x3,0x2a,0x32, 0x1,0x4e,0x75, + 0x2,0x28,0x2e, 0x2,0x28,0x2a, 0x3,0x2a,0x2f, 0x1,0x52,0x45, + 0x1,0x52,0x48, 0x2,0x2c,0x30, 0x2,0x2c,0x2f, 0x2,0x2c,0x2e, + 0x1,0x52,0x42, 0x2,0x2c,0x37, 0x2,0x2c,0x2d, 0x4,0x2e,0x2a, + 0x1,0x52,0x44, 0x2,0x30,0x70, 0x3,0x2d,0x78, 0x2,0x2c,0x34, + 0x2,0x2c,0x32, 0x1,0x52,0x47, 0x3,0x2d,0x7b, 0x2,0x2c,0x2a, + 0x2,0x2c,0x35, 0x3,0x2d,0x77, 0x2,0x2c,0x2c, 0x2,0x2c,0x36, + 0x2,0x2c,0x33, 0x2,0x2c,0x2b, 0x3,0x2d,0x7a, 0x1,0x52,0x43, + 0x2,0x2c,0x38, 0x2,0x2c,0x29, 0x1,0x52,0x46, 0x3,0x2d,0x7e, + 0x3,0x2d,0x79, 0x3,0x2d,0x7c, 0x2,0x30,0x75, 0x2,0x30,0x6c, + 0x2,0x30,0x77, 0x3,0x32,0x3e, 0x2,0x30,0x6f, 0x2,0x30,0x7a, + 0x2,0x30,0x7b, 0x2,0x30,0x6d, 0x2,0x30,0x79, 0x2,0x30,0x76, + 0x2,0x30,0x74, 0x2,0x30,0x78, 0x1,0x56,0x62, 0x3,0x32,0x40, + 0x1,0x56,0x60, 0x3,0x32,0x47, 0x3,0x32,0x3c, 0x2,0x30,0x72, + 0x3,0x32,0x46, 0x2,0x30,0x6e, 0x3,0x32,0x41, 0x2,0x30,0x71, + 0x2,0x30,0x7c, 0x2,0x30,0x73, 0x1,0x56,0x61, 0x2,0x2c,0x31, + 0x3,0x32,0x3d, 0x1,0x56,0x5d, 0x1,0x56,0x5f, 0x3,0x65,0x64, + 0x3,0x37,0x3d, 0x2,0x37,0x3d, 0x2,0x37,0x32, 0x2,0x37,0x30, + 0x3,0x3d,0x38, 0x2,0x37,0x31, 0x3,0x32,0x3f, 0x2,0x37,0x38, + 0x3,0x37,0x40, 0x2,0x37,0x39, 0x2,0x37,0x35, 0x1,0x5c,0x22, + 0x2,0x37,0x3a, 0x2,0x37,0x37, 0x2,0x37,0x34, 0x3,0x37,0x3c, + 0x1,0x5b,0x7e, 0x2,0x37,0x33, 0x1,0x5b,0x7c, 0x1,0x5c,0x21, + 0x2,0x37,0x36, 0x2,0x37,0x3e, 0x1,0x56,0x5e, 0x1,0x5b,0x7d, + 0x2,0x37,0x3c, 0x2,0x37,0x3b, 0x1,0x5c,0x23, 0x3,0x65,0x65, + 0xf,0x36,0x57, 0x3,0x3d,0x36, 0x3,0x3d,0x3a, 0x2,0x3e,0x24, + 0x3,0x3d,0x2f, 0x3,0x3d,0x3b, 0x3,0x3d,0x32, 0x2,0x3e,0x25, + 0x1,0x60,0x66, 0x3,0x3d,0x39, 0x2,0x3e,0x2b, 0x3,0x42,0x6d, + 0x3,0x3d,0x35, 0x2,0x3e,0x2d, 0x2,0x3e,0x26, 0x1,0x60,0x60, + 0x2,0x3e,0x2a, 0x2,0x3e,0x29, 0x1,0x60,0x61, 0x1,0x60,0x67, + 0x3,0x42,0x64, 0x1,0x60,0x68, 0x2,0x3e,0x2c, 0x1,0x60,0x5e, + 0x2,0x3e,0x23, 0x2,0x3e,0x21, 0x2,0x3e,0x27, 0x2,0x3d,0x7e, + 0x1,0x60,0x65, 0x2,0x3e,0x22, 0x2,0x3e,0x28, 0x2,0x3e,0x2e, + 0x1,0x60,0x5f, 0x1,0x60,0x64, 0x1,0x60,0x62, 0x1,0x60,0x63, + 0x3,0x3d,0x33, 0x3,0x3d,0x3c, 0x1,0x60,0x5d, 0x3,0x65,0x66, + 0x3,0x3d,0x37, 0x3,0x42,0x68, 0x3,0x42,0x75, 0x1,0x65,0x31, + 0x2,0x44,0x7b, 0x1,0x65,0x30, 0x2,0x45,0x21, 0x3,0x42,0x6f, + 0x2,0x44,0x75, 0x3,0x42,0x74, 0x2,0x45,0x22, 0x3,0x42,0x6e, + 0x3,0x42,0x66, 0x3,0x42,0x71, 0x2,0x44,0x76, 0x2,0x44,0x77, + 0x3,0x42,0x73, 0x2,0x45,0x23, 0x2,0x44,0x7e, 0x2,0x44,0x7c, + 0x2,0x44,0x7d, 0x2,0x44,0x79, 0x2,0x44,0x78, 0x3,0x42,0x67, + 0x2,0x45,0x24, 0x1,0x65,0x2d, 0x3,0x42,0x6b, 0x2,0x44,0x7a, + 0x3,0x42,0x70, 0x1,0x65,0x32, 0x1,0x65,0x2c, 0x1,0x65,0x33, + 0x1,0x65,0x34, 0x3,0x42,0x6a, 0x1,0x65,0x2f, 0x1,0x65,0x2e, + 0x3,0x48,0x25, 0x3,0x47,0x7e, 0x2,0x4b,0x74, 0x1,0x69,0x65, + 0x1,0x69,0x64, 0x3,0x47,0x7c, 0x3,0x47,0x7d, 0x2,0x4b,0x79, + 0x3,0x48,0x22, 0x1,0x6d,0x66, 0x1,0x69,0x66, 0x3,0x48,0x21, + 0x3,0x47,0x7b, 0x1,0x69,0x68, 0x2,0x4b,0x7a, 0x1,0x65,0x2b, + 0x1,0x69,0x67, 0x2,0x4b,0x76, 0x2,0x4b,0x78, 0x2,0x4b,0x75, + 0x3,0x48,0x27, 0x2,0x4b,0x77, 0x3,0x48,0x23, 0xf,0x49,0x76, + 0x2,0x52,0x33, 0x3,0x4d,0x31, 0x3,0x4d,0x3b, 0x2,0x52,0x32, + 0x2,0x52,0x2f, 0x1,0x6d,0x69, 0x2,0x58,0x4e, 0x1,0x6d,0x6a, + 0x2,0x52,0x2e, 0x3,0x4d,0x39, 0x1,0x6d,0x68, 0x3,0x4d,0x36, + 0x2,0x52,0x30, 0x2,0x52,0x2d, 0x2,0x52,0x2a, 0x2,0x52,0x31, + 0x2,0x52,0x2b, 0x2,0x52,0x2c, 0x1,0x6d,0x67, 0x3,0x4d,0x35, + 0x3,0x65,0x68, 0x4,0x51,0x39, 0x2,0x5d,0x55, 0x4,0x51,0x3a, + 0x2,0x58,0x52, 0x3,0x4d,0x3a, 0x2,0x58,0x51, 0x2,0x58,0x53, + 0x3,0x51,0x6a, 0x2,0x5d,0x52, 0x1,0x71,0x44, 0x4,0x51,0x38, + 0x2,0x58,0x4f, 0x3,0x51,0x67, 0x1,0x71,0x42, 0x3,0x51,0x6c, + 0x1,0x71,0x46, 0x1,0x71,0x45, 0x2,0x58,0x50, 0x2,0x58,0x54, + 0x3,0x51,0x6b, 0x1,0x71,0x43, 0x3,0x65,0x67, 0x2,0x5d,0x59, + 0x1,0x74,0x40, 0x1,0x76,0x66, 0x1,0x74,0x41, 0x1,0x74,0x3e, + 0x2,0x5d,0x56, 0x2,0x5d,0x54, 0x3,0x55,0x4f, 0x2,0x5d,0x57, + 0x3,0x55,0x4b, 0x2,0x5d,0x5a, 0x1,0x74,0x3f, 0x2,0x5d,0x58, + 0x2,0x5d,0x53, 0x3,0x55,0x4d, 0x3,0x65,0x69, 0x2,0x62,0x2f, + 0x2,0x62,0x32, 0x2,0x66,0x21, 0x2,0x62,0x2d, 0x3,0x58,0x2f, + 0x2,0x69,0x3e, 0x2,0x62,0x33, 0x3,0x58,0x30, 0x1,0x78,0x4d, + 0x2,0x62,0x31, 0x1,0x76,0x67, 0x2,0x62,0x2e, 0x2,0x62,0x30, + 0x2,0x62,0x34, 0x2,0x66,0x22, 0x3,0x5a,0x5a, 0x2,0x65,0x7e, + 0x4,0x60,0x27, 0x3,0x5a,0x5c, 0x3,0x5a,0x5d, 0x3,0x5a,0x5b, + 0x1,0x78,0x4e, 0x2,0x65,0x7d, 0x3,0x5c,0x5e, 0x3,0x5c,0x5c, + 0x3,0x5c,0x5f, 0x1,0x79,0x79, 0x3,0x5c,0x5d, 0x3,0x5c,0x60, + 0x3,0x5e,0x3d, 0x1,0x7a,0x78, 0x2,0x6d,0x5f, 0x1,0x7a,0x77, + 0x2,0x6d,0x61, 0x2,0x6d,0x5e, 0x2,0x6d,0x60, 0x1,0x7c,0x3c, + 0x2,0x70,0x40, 0x1,0x46,0x6a, 0x2,0x28,0x30, 0x2,0x30,0x7d, + 0x2,0x30,0x7e, 0x1,0x5c,0x24, 0x2,0x45,0x25, 0x1,0x71,0x47, + 0x1,0x78,0x4f, 0x1,0x7b,0x67, 0x2,0x70,0x41, 0x1,0x46,0x6b, + 0x2,0x28,0x31, 0x1,0x23,0x22, 0x4,0x2a,0x3c, 0x3,0x2e,0x22, + 0x2,0x2c,0x39, 0x3,0x2e,0x21, 0x2,0x2c,0x3a, 0x3,0x2e,0x24, + 0x3,0x32,0x48, 0x2,0x31,0x21, 0x2,0x31,0x22, 0x1,0x5c,0x25, + 0x1,0x5c,0x26, 0xf,0x36,0x67, 0x3,0x3d,0x3d, 0x4,0x39,0x25, + 0x2,0x3e,0x2f, 0x2,0x45,0x28, 0x2,0x45,0x27, 0x2,0x45,0x26, + 0x2,0x4b,0x7b, 0x3,0x42,0x77, 0x2,0x4b,0x7c, 0x2,0x4b,0x7d, + 0x1,0x69,0x69, 0x3,0x48,0x28, 0x2,0x52,0x35, 0x2,0x52,0x34, + 0x3,0x4d,0x3d, 0x3,0x51,0x6d, 0x2,0x58,0x55, 0x1,0x71,0x48, + 0x1,0x71,0x49, 0x3,0x51,0x6e, 0x2,0x5d,0x5e, 0x2,0x5d,0x5b, + 0x2,0x5d,0x5c, 0x2,0x5d,0x5d, 0x2,0x62,0x36, 0x2,0x62,0x35, + 0x1,0x76,0x68, 0x2,0x66,0x23, 0x2,0x6b,0x6c, 0x1,0x46,0x6c, + 0x1,0x52,0x49, 0x3,0x37,0x44, 0x1,0x5c,0x27, 0x2,0x45,0x29, + 0x3,0x42,0x78, 0x1,0x46,0x6d, 0x4,0x2a,0x40, 0x2,0x31,0x23, + 0x1,0x5c,0x28, 0x3,0x37,0x45, 0x3,0x3d,0x3e, 0x1,0x60,0x69, + 0x1,0x60,0x6a, 0x5,0x47,0x49, 0x1,0x46,0x6e, 0x1,0x46,0x6f, + 0x2,0x22,0x66, 0x1,0x4b,0x2d, 0x1,0x4b,0x2c, 0x1,0x52,0x4a, + 0x2,0x2c,0x3b, 0x2,0x3e,0x30, 0x1,0x46,0x70, 0x1,0x46,0x71, + 0x1,0x46,0x72, 0x1,0x46,0x73, 0x4,0x23,0x2b, 0x1,0x4b,0x2e, + 0x1,0x4b,0x2f, 0x2,0x24,0x6e, 0x2,0x24,0x6d, 0x3,0x2a,0x37, + 0x1,0x4e,0x77, 0x2,0x28,0x34, 0x2,0x28,0x32, 0x2,0x28,0x33, + 0x3,0x2a,0x38, 0x3,0x2a,0x35, 0x4,0x27,0x40, 0x3,0x2a,0x36, + 0x3,0x2e,0x27, 0x2,0x2c,0x3c, 0x2,0x2c,0x3d, 0x3,0x2e,0x25, + 0x3,0x2e,0x28, 0x1,0x52,0x4e, 0x1,0x52,0x4c, 0x3,0x2e,0x2a, + 0x1,0x52,0x4d, 0x1,0x52,0x4b, 0x3,0x2e,0x26, 0xf,0x2b,0x7a, + 0xf,0x2c,0x4a, 0x1,0x56,0x63, 0x3,0x32,0x4e, 0x3,0x32,0x4d, + 0x3,0x32,0x50, 0x3,0x32,0x4f, 0x1,0x56,0x67, 0x1,0x56,0x66, + 0x2,0x31,0x24, 0x1,0x56,0x65, 0x1,0x56,0x64, 0x3,0x32,0x51, + 0x2,0x31,0x25, 0x3,0x37,0x46, 0x1,0x5c,0x2b, 0x2,0x37,0x40, + 0x2,0x37,0x3f, 0x1,0x5c,0x29, 0x1,0x5c,0x2a, 0x3,0x37,0x49, + 0x3,0x37,0x47, 0x1,0x60,0x6c, 0x1,0x60,0x6b, 0x2,0x3e,0x32, + 0x3,0x3d,0x43, 0x3,0x3d,0x42, 0x2,0x3e,0x31, 0x1,0x5c,0x2c, + 0x3,0x3d,0x44, 0x4,0x39,0x2c, 0x4,0x3e,0x6b, 0x1,0x65,0x35, + 0x2,0x45,0x2b, 0x1,0x65,0x36, 0x2,0x45,0x2a, 0x3,0x42,0x7b, + 0x4,0x44,0x7c, 0x4,0x44,0x7b, 0x2,0x4b,0x7e, 0x2,0x52,0x36, + 0x1,0x6d,0x6b, 0x2,0x58,0x56, 0x3,0x51,0x70, 0x3,0x55,0x52, + 0x2,0x5d,0x5f, 0x4,0x5b,0x74, 0x1,0x78,0x51, 0x1,0x78,0x50, + 0x4,0x63,0x68, 0x3,0x5c,0x62, 0x1,0x7b,0x68, 0x1,0x46,0x74, + 0x2,0x28,0x35, 0x3,0x3d,0x45, 0x1,0x5c,0x2d, 0x2,0x4c,0x21, + 0x1,0x69,0x6a, 0x3,0x22,0x5b, 0x3,0x26,0x73, 0x2,0x24,0x6f, + 0x2,0x24,0x70, 0x2,0x28,0x36, 0x1,0x4e,0x79, 0x1,0x4e,0x7a, + 0x3,0x2a,0x3a, 0x4,0x27,0x43, 0x1,0x4e,0x78, 0x3,0x2a,0x3b, + 0x1,0x52,0x52, 0x1,0x52,0x53, 0x1,0x52,0x50, 0x1,0x52,0x51, + 0x3,0x2e,0x2b, 0x2,0x2c,0x3e, 0x3,0x2e,0x2f, 0x4,0x2a,0x4a, + 0x2,0x2c,0x3f, 0x1,0x52,0x4f, 0x2,0x31,0x26, 0x3,0x32,0x57, + 0x1,0x56,0x6b, 0x1,0x56,0x6c, 0x3,0x32,0x55, 0x1,0x5c,0x30, + 0x2,0x31,0x2c, 0x4,0x2e,0x40, 0x1,0x56,0x71, 0x1,0x56,0x6f, + 0x2,0x31,0x2d, 0x2,0x31,0x28, 0x1,0x56,0x6e, 0x1,0x56,0x6d, + 0x1,0x56,0x68, 0x2,0x31,0x2b, 0x2,0x31,0x2a, 0x2,0x31,0x27, + 0x1,0x56,0x70, 0x3,0x32,0x52, 0x2,0x31,0x29, 0x1,0x56,0x69, + 0x4,0x2e,0x34, 0x1,0x56,0x6a, 0x1,0x5c,0x31, 0x2,0x37,0x44, + 0x2,0x37,0x45, 0x1,0x5c,0x32, 0x2,0x37,0x41, 0x2,0x37,0x43, + 0x2,0x37,0x47, 0x2,0x37,0x46, 0x2,0x37,0x42, 0x3,0x37,0x4a, + 0x1,0x5c,0x2e, 0x1,0x5c,0x2f, 0x2,0x3e,0x3a, 0x1,0x60,0x71, + 0x1,0x60,0x70, 0x2,0x3e,0x34, 0x1,0x60,0x6e, 0x4,0x39,0x34, + 0x2,0x3e,0x37, 0x1,0x60,0x72, 0x2,0x3e,0x38, 0x1,0x60,0x73, + 0x2,0x3e,0x35, 0x1,0x60,0x6d, 0x1,0x60,0x6f, 0x2,0x3e,0x39, + 0x3,0x3d,0x47, 0x2,0x3e,0x36, 0x2,0x3e,0x33, 0x4,0x3e,0x77, + 0x2,0x45,0x38, 0x3,0x42,0x7c, 0x2,0x45,0x2d, 0x1,0x65,0x38, + 0x1,0x65,0x3b, 0x1,0x65,0x3a, 0x1,0x65,0x3f, 0x1,0x65,0x3e, + 0x2,0x45,0x39, 0x2,0x45,0x37, 0x2,0x45,0x30, 0x2,0x45,0x34, + 0x2,0x45,0x33, 0x1,0x65,0x3c, 0x2,0x45,0x36, 0x2,0x45,0x32, + 0x2,0x45,0x3a, 0x2,0x45,0x31, 0x1,0x65,0x3d, 0x1,0x65,0x37, + 0x1,0x65,0x39, 0x3,0x42,0x7d, 0x2,0x45,0x2f, 0x3,0x48,0x2b, + 0x2,0x4c,0x23, 0x1,0x69,0x6e, 0x2,0x4c,0x27, 0x1,0x69,0x6d, + 0x2,0x4c,0x24, 0x1,0x69,0x6c, 0x3,0x48,0x29, 0x2,0x45,0x2e, + 0x2,0x45,0x35, 0x2,0x4c,0x26, 0x4,0x44,0x7e, 0x1,0x69,0x6f, + 0x2,0x4c,0x28, 0x2,0x4c,0x25, 0x2,0x4c,0x22, 0x2,0x52,0x39, + 0x2,0x52,0x3d, 0x2,0x52,0x3f, 0x2,0x52,0x3b, 0x2,0x52,0x3a, + 0x2,0x52,0x38, 0x1,0x6d,0x6e, 0x1,0x6d,0x6c, 0x1,0x6d,0x71, + 0x1,0x6d,0x72, 0x2,0x52,0x3c, 0x1,0x6d,0x6f, 0x2,0x52,0x37, + 0x1,0x6d,0x70, 0x1,0x69,0x6b, 0x2,0x52,0x3e, 0x1,0x6d,0x6d, + 0x3,0x51,0x71, 0x2,0x58,0x58, 0x4,0x51,0x4f, 0x2,0x58,0x57, + 0x2,0x58,0x5f, 0x2,0x58,0x59, 0x2,0x58,0x5e, 0x2,0x58,0x5b, + 0x1,0x71,0x4a, 0x2,0x58,0x5d, 0x3,0x51,0x73, 0x3,0x51,0x72, + 0x1,0x71,0x4b, 0x4,0x51,0x4d, 0x1,0x71,0x4c, 0x3,0x51,0x74, + 0x2,0x58,0x5c, 0x2,0x58,0x5a, 0x4,0x57,0x21, 0x4,0x57,0x24, + 0x1,0x74,0x43, 0x2,0x5d,0x60, 0x3,0x55,0x55, 0x3,0x55,0x53, + 0x1,0x74,0x42, 0x2,0x5d,0x63, 0x2,0x5d,0x61, 0x2,0x5d,0x62, + 0x5,0x55,0x69, 0x5,0x5c,0x36, 0x1,0x74,0x44, 0x3,0x55,0x54, + 0x3,0x58,0x34, 0x2,0x62,0x3a, 0x3,0x58,0x33, 0x1,0x76,0x6b, + 0x2,0x62,0x3b, 0x4,0x5b,0x75, 0x4,0x5b,0x79, 0x1,0x76,0x69, + 0x2,0x62,0x3c, 0x1,0x76,0x6a, 0x2,0x62,0x39, 0x2,0x62,0x3d, + 0x3,0x58,0x32, 0x2,0x62,0x37, 0x1,0x78,0x52, 0x2,0x66,0x24, + 0x1,0x78,0x53, 0x1,0x79,0x7a, 0x2,0x62,0x38, 0x1,0x79,0x7b, + 0x3,0x5e,0x3f, 0x3,0x5e,0x3e, 0x1,0x7a,0x79, 0x2,0x6b,0x6d, + 0x1,0x7b,0x6a, 0x2,0x6d,0x62, 0x1,0x7b,0x69, 0x3,0x60,0x3b, + 0x2,0x6f,0x39, 0x1,0x7c,0x61, 0x1,0x7c,0x62, 0x3,0x65,0x6a, + 0x7,0x64,0x52, 0x2,0x72,0x3a, 0x3,0x22,0x5c, 0x3,0x65,0x6b, + 0x1,0x52,0x54, 0x2,0x2c,0x40, 0x1,0x60,0x74, 0x1,0x60,0x75, + 0x1,0x46,0x75, 0x1,0x48,0x4b, 0x2,0x22,0x67, 0x3,0x26,0x74, + 0x2,0x24,0x71, 0x1,0x4b,0x30, 0x3,0x26,0x76, 0x1,0x4e,0x7b, + 0x4,0x2a,0x4c, 0x1,0x52,0x55, 0x1,0x52,0x56, 0x1,0x52,0x57, + 0x2,0x37,0x49, 0x2,0x31,0x2e, 0x1,0x56,0x72, 0x4,0x2e,0x41, + 0x4,0x2e,0x43, 0x1,0x5c,0x33, 0x2,0x37,0x48, 0x3,0x37,0x4d, + 0x2,0x3e,0x3c, 0x1,0x60,0x77, 0x3,0x3d,0x4c, 0x2,0x3e,0x3b, + 0x1,0x60,0x76, 0x3,0x42,0x7e, 0x3,0x43,0x21, 0x2,0x45,0x3b, + 0x1,0x6d,0x73, 0x2,0x52,0x43, 0x2,0x52,0x40, 0x2,0x52,0x41, + 0x2,0x52,0x42, 0x4,0x51,0x54, 0x4,0x51,0x55, 0x3,0x51,0x76, + 0x5,0x5c,0x43, 0x3,0x55,0x56, 0x2,0x5d,0x64, 0x3,0x55,0x57, + 0x2,0x62,0x3e, 0x4,0x5b,0x7c, 0x4,0x5b,0x7d, 0x3,0x5a,0x5e, + 0x2,0x69,0x40, 0x2,0x69,0x3f, 0x4,0x66,0x5a, 0x2,0x6d,0x63, + 0x1,0x46,0x76, 0x2,0x28,0x37, 0x1,0x56,0x73, 0x3,0x3d,0x4d, + 0x1,0x60,0x78, 0x2,0x45,0x3c, 0x4,0x45,0x34, 0x3,0x48,0x30, + 0x2,0x4c,0x29, 0x3,0x48,0x2e, 0x1,0x6d,0x74, 0x2,0x58,0x60, + 0x3,0x65,0x6c, 0x2,0x62,0x3f, 0x2,0x69,0x41, 0x1,0x46,0x77, + 0x3,0x26,0x77, 0x3,0x26,0x78, 0x1,0x4e,0x7c, 0x1,0x52,0x5a, + 0x2,0x2c,0x41, 0x1,0x52,0x5b, 0x1,0x52,0x59, 0x3,0x2e,0x32, + 0x1,0x52,0x58, 0x2,0x31,0x2f, 0x1,0x56,0x74, 0x3,0x32,0x5a, + 0x3,0x32,0x5b, 0x1,0x56,0x75, 0x1,0x56,0x76, 0x1,0x5c,0x35, + 0x2,0x37,0x4a, 0x1,0x5c,0x34, 0x3,0x37,0x50, 0x3,0x37,0x52, + 0x3,0x37,0x51, 0xf,0x37,0x23, 0x3,0x3d,0x4f, 0x2,0x3e,0x3d, + 0x1,0x5c,0x36, 0x1,0x60,0x79, 0x2,0x45,0x3d, 0x1,0x65,0x40, + 0x1,0x65,0x41, 0x4,0x45,0x35, 0x1,0x69,0x70, 0x3,0x48,0x31, + 0x1,0x69,0x71, 0x1,0x6d,0x75, 0x1,0x71,0x4e, 0x2,0x58,0x61, + 0x1,0x71,0x4d, 0x4,0x57,0x2d, 0x2,0x5d,0x65, 0x1,0x74,0x45, + 0x3,0x58,0x35, 0x2,0x62,0x40, 0x2,0x69,0x42, 0x1,0x46,0x78, + 0x1,0x4b,0x31, 0x2,0x28,0x3a, 0x2,0x28,0x39, 0x1,0x4e,0x7d, + 0x2,0x28,0x38, 0x1,0x4e,0x7e, 0x2,0x28,0x3b, 0x4,0x2a,0x55, + 0x2,0x2c,0x47, 0x1,0x52,0x5e, 0x1,0x52,0x5d, 0x2,0x2c,0x49, + 0x2,0x2c,0x48, 0x1,0x52,0x62, 0x3,0x2e,0x35, 0x1,0x52,0x61, + 0x3,0x2e,0x33, 0x4,0x2a,0x59, 0x1,0x52,0x5c, 0x4,0x2a,0x5d, + 0x2,0x2c,0x43, 0x2,0x2c,0x44, 0x2,0x2c,0x45, 0x4,0x2a,0x52, + 0x1,0x52,0x63, 0x2,0x2c,0x42, 0x1,0x52,0x5f, 0x2,0x2c,0x46, + 0x1,0x52,0x60, 0x3,0x32,0x64, 0x3,0x32,0x5f, 0x2,0x31,0x32, + 0x2,0x31,0x36, 0x2,0x31,0x34, 0x2,0x31,0x33, 0x4,0x2e,0x55, + 0x2,0x31,0x37, 0x3,0x32,0x5e, 0x4,0x2e,0x4f, 0x3,0x32,0x68, + 0x2,0x31,0x38, 0x2,0x31,0x39, 0x2,0x31,0x31, 0x4,0x2e,0x51, + 0x2,0x31,0x30, 0x3,0x37,0x59, 0x1,0x56,0x78, 0x1,0x56,0x79, + 0x3,0x32,0x67, 0x2,0x31,0x3a, 0x2,0x31,0x35, 0x3,0x32,0x65, + 0x2,0x37,0x53, 0x3,0x37,0x55, 0x2,0x31,0x3b, 0x1,0x56,0x7a, + 0x1,0x56,0x77, 0x3,0x32,0x5c, 0x3,0x32,0x63, 0x2,0x37,0x4d, + 0x4,0x33,0x4f, 0x2,0x37,0x4c, 0x3,0x37,0x53, 0x2,0x37,0x4e, + 0x2,0x37,0x4f, 0x2,0x37,0x51, 0x2,0x37,0x50, 0x2,0x37,0x55, + 0x1,0x5c,0x3a, 0x1,0x5c,0x37, 0x1,0x5c,0x3b, 0x2,0x37,0x4b, + 0x1,0x5c,0x3c, 0x2,0x37,0x54, 0x1,0x5c,0x39, 0x2,0x37,0x52, + 0x1,0x5c,0x38, 0x3,0x32,0x62, 0x3,0x37,0x57, 0x4,0x33,0x56, + 0x3,0x3d,0x56, 0x3,0x3d,0x53, 0x2,0x3e,0x40, 0x2,0x3e,0x42, + 0x2,0x3e,0x3e, 0x2,0x3e,0x3f, 0x3,0x3d,0x51, 0x3,0x3d,0x52, + 0x2,0x3e,0x43, 0x2,0x3e,0x45, 0x2,0x3e,0x46, 0x2,0x3e,0x41, + 0x2,0x3e,0x44, 0x1,0x60,0x7a, 0x2,0x45,0x41, 0x3,0x43,0x27, + 0x2,0x45,0x46, 0x2,0x45,0x3e, 0x2,0x45,0x42, 0x4,0x3f,0x29, + 0x3,0x43,0x28, 0x2,0x45,0x47, 0x2,0x45,0x43, 0x1,0x65,0x42, + 0x1,0x65,0x4a, 0x3,0x43,0x25, 0x1,0x65,0x45, 0x2,0x45,0x3f, + 0x2,0x45,0x40, 0x1,0x69,0x75, 0x1,0x65,0x4d, 0x1,0x65,0x46, + 0x3,0x43,0x26, 0x1,0x65,0x4b, 0x1,0x65,0x44, 0x2,0x45,0x45, + 0x1,0x65,0x4c, 0x2,0x45,0x44, 0x1,0x65,0x48, 0x1,0x65,0x43, + 0x1,0x65,0x49, 0x2,0x45,0x48, 0x2,0x4c,0x2e, 0x2,0x4c,0x30, + 0x4,0x45,0x42, 0x3,0x48,0x39, 0x4,0x45,0x40, 0x4,0x45,0x3d, + 0x3,0x48,0x33, 0x3,0x48,0x36, 0x3,0x48,0x35, 0x3,0x48,0x34, + 0x3,0x48,0x38, 0x1,0x65,0x47, 0x3,0x48,0x3b, 0x3,0x48,0x3d, + 0x2,0x4c,0x2b, 0x1,0x69,0x73, 0x2,0x4c,0x31, 0x1,0x69,0x74, + 0x2,0x4c,0x2f, 0x2,0x4c,0x2a, 0x2,0x4c,0x2d, 0x2,0x4c,0x32, + 0x1,0x69,0x72, 0x2,0x4c,0x2c, 0x1,0x6d,0x77, 0x2,0x52,0x47, + 0x2,0x52,0x46, 0x3,0x4d,0x44, 0x1,0x6d,0x7a, 0x1,0x6d,0x78, + 0x2,0x52,0x44, 0x1,0x6d,0x76, 0x2,0x52,0x45, 0x3,0x4d,0x46, + 0x1,0x6d,0x79, 0x4,0x51,0x5f, 0x2,0x58,0x69, 0x3,0x51,0x7b, + 0x2,0x58,0x6b, 0x3,0x51,0x79, 0x2,0x58,0x6a, 0x2,0x58,0x62, + 0x2,0x58,0x66, 0x2,0x58,0x65, 0x2,0x58,0x63, 0x1,0x71,0x50, + 0x1,0x71,0x51, 0x1,0x71,0x4f, 0x2,0x58,0x64, 0x2,0x58,0x67, + 0x2,0x58,0x68, 0x3,0x55,0x59, 0x1,0x71,0x52, 0x3,0x55,0x58, + 0x1,0x74,0x4a, 0x2,0x5d,0x6d, 0x3,0x55,0x5b, 0x1,0x74,0x47, + 0x2,0x5d,0x67, 0x1,0x74,0x49, 0x1,0x74,0x4b, 0x4,0x51,0x61, + 0x3,0x55,0x5c, 0x1,0x74,0x48, 0x2,0x5d,0x6c, 0x2,0x5d,0x68, + 0x1,0x74,0x46, 0x2,0x5d,0x6b, 0x2,0x5d,0x66, 0x2,0x5d,0x6a, + 0x2,0x5d,0x69, 0x3,0x58,0x36, 0x3,0x58,0x38, 0x2,0x62,0x42, + 0x1,0x76,0x6e, 0x1,0x76,0x6f, 0x1,0x76,0x6c, 0x3,0x58,0x3b, + 0x1,0x76,0x6d, 0x3,0x58,0x3a, 0x3,0x58,0x39, 0x2,0x62,0x41, + 0x4,0x60,0x39, 0x2,0x66,0x27, 0x3,0x5a,0x60, 0x3,0x5a,0x5f, + 0x1,0x78,0x54, 0x2,0x66,0x25, 0x2,0x66,0x26, 0x2,0x69,0x43, + 0x2,0x69,0x46, 0x2,0x69,0x44, 0x2,0x69,0x45, 0x2,0x6b,0x6e, + 0x3,0x5e,0x42, 0x4,0x66,0x5e, 0x1,0x7a,0x7a, 0x2,0x6f,0x3a, + 0x2,0x70,0x42, 0x4,0x6b,0x74, 0x1,0x7c,0x63, 0x2,0x71,0x28, + 0x2,0x71,0x29, 0x1,0x7d,0x33, 0x1,0x46,0x79, 0x1,0x52,0x64, + 0x3,0x32,0x69, 0x2,0x3e,0x47, 0x3,0x3d,0x57, 0x2,0x45,0x49, + 0x4,0x6c,0x76, 0x1,0x46,0x7a, 0x1,0x4b,0x32, 0x4,0x27,0x52, + 0x1,0x4f,0x21, 0x3,0x2e,0x36, 0x2,0x2c,0x4a, 0x2,0x2c,0x4b, + 0x1,0x56,0x7b, 0x4,0x33,0x5b, 0x2,0x3e,0x48, 0x1,0x60,0x7b, + 0x1,0x65,0x4e, 0x1,0x74,0x4c, 0x2,0x5d,0x6e, 0x2,0x66,0x28, + 0x2,0x69,0x47, 0x1,0x46,0x7b, 0x3,0x26,0x7b, 0x3,0x26,0x7c, + 0xf,0x25,0x23, 0x2,0x28,0x41, 0x2,0x28,0x3c, 0x2,0x28,0x3e, + 0x2,0x28,0x40, 0x2,0x28,0x3f, 0x2,0x28,0x3d, 0x1,0x4f,0x22, + 0xf,0x28,0x34, 0x1,0x52,0x65, 0x2,0x2c,0x54, 0x3,0x2e,0x39, + 0x2,0x2c,0x4f, 0x2,0x2c,0x4c, 0x3,0x2e,0x3b, 0x3,0x2e,0x3e, + 0x2,0x2c,0x53, 0x3,0x2e,0x37, 0x3,0x2e,0x3a, 0x1,0x52,0x67, + 0x1,0x52,0x68, 0x2,0x2c,0x52, 0x2,0x2c,0x51, 0x2,0x2c,0x50, + 0x2,0x2c,0x4d, 0x2,0x2c,0x4e, 0x2,0x2c,0x55, 0x1,0x52,0x66, + 0x3,0x2e,0x3d, 0xf,0x2c,0x5c, 0x3,0x65,0x6d, 0x3,0x65,0x6e, + 0x1,0x57,0x21, 0x3,0x66,0x7c, 0x1,0x57,0x27, 0x1,0x57,0x26, + 0x2,0x31,0x44, 0x2,0x31,0x3e, 0x2,0x31,0x3c, 0x3,0x32,0x6c, + 0x1,0x57,0x24, 0x2,0x37,0x5c, 0x1,0x56,0x7d, 0x2,0x31,0x41, + 0x2,0x31,0x45, 0x2,0x31,0x47, 0x2,0x31,0x43, 0x2,0x31,0x3d, + 0x1,0x57,0x25, 0x2,0x31,0x42, 0x2,0x31,0x40, 0x1,0x56,0x7c, + 0x2,0x31,0x48, 0x1,0x57,0x28, 0x2,0x31,0x46, 0x1,0x57,0x22, + 0x2,0x31,0x3f, 0x3,0x32,0x6d, 0x1,0x57,0x23, 0x1,0x56,0x7e, + 0x3,0x65,0x6f, 0x3,0x37,0x62, 0x1,0x5c,0x3e, 0x4,0x33,0x5d, + 0x2,0x37,0x5d, 0x3,0x37,0x63, 0x3,0x37,0x5d, 0x2,0x37,0x56, + 0x2,0x37,0x58, 0x2,0x37,0x5a, 0x3,0x37,0x5f, 0x2,0x37,0x5b, + 0x2,0x37,0x59, 0x1,0x5c,0x3f, 0x3,0x37,0x61, 0x2,0x37,0x5e, + 0x3,0x37,0x60, 0x2,0x37,0x57, 0x3,0x65,0x70, 0x3,0x65,0x71, + 0x3,0x65,0x72, 0x2,0x3e,0x4c, 0x1,0x60,0x7c, 0x2,0x3e,0x54, + 0x3,0x3d,0x5c, 0x2,0x3e,0x49, 0x6,0x4c,0x2f, 0x2,0x3e,0x55, + 0x3,0x3d,0x59, 0x2,0x3e,0x4a, 0x2,0x3e,0x4b, 0x3,0x3d,0x5d, + 0x4,0x39,0x54, 0x2,0x3e,0x53, 0x2,0x3e,0x52, 0x2,0x3e,0x4f, + 0x1,0x5c,0x3d, 0x1,0x60,0x7d, 0x2,0x3e,0x4d, 0x2,0x3e,0x50, + 0x1,0x60,0x7e, 0x2,0x3e,0x51, 0x2,0x3e,0x4e, 0x3,0x3d,0x5a, + 0x3,0x43,0x31, 0x2,0x45,0x54, 0x3,0x43,0x2d, 0x2,0x45,0x58, + 0x1,0x65,0x55, 0x3,0x43,0x2e, 0x2,0x4c,0x38, 0x1,0x65,0x58, + 0x2,0x45,0x56, 0x3,0x43,0x37, 0x3,0x43,0x29, 0x2,0x45,0x53, + 0x2,0x45,0x4e, 0x2,0x45,0x50, 0x2,0x45,0x51, 0x2,0x45,0x4a, + 0x3,0x43,0x35, 0x1,0x65,0x54, 0x3,0x43,0x2b, 0x3,0x43,0x30, + 0x1,0x65,0x53, 0x3,0x43,0x34, 0x1,0x65,0x4f, 0x2,0x45,0x4d, + 0x3,0x43,0x2a, 0x1,0x65,0x56, 0x3,0x43,0x36, 0x1,0x65,0x57, + 0x2,0x45,0x4c, 0x2,0x45,0x4f, 0x2,0x45,0x57, 0x1,0x65,0x51, + 0x1,0x65,0x52, 0x2,0x45,0x55, 0x2,0x45,0x4b, 0xf,0x44,0x25, + 0x4,0x45,0x53, 0x2,0x4c,0x3a, 0x1,0x69,0x77, 0x2,0x4c,0x3c, + 0x2,0x45,0x52, 0x2,0x4c,0x3e, 0x1,0x69,0x7b, 0x2,0x4c,0x3f, + 0x2,0x4c,0x3b, 0x3,0x48,0x3e, 0x1,0x69,0x78, 0x2,0x4c,0x37, + 0x1,0x69,0x7a, 0x2,0x4c,0x34, 0x2,0x4c,0x39, 0x2,0x4c,0x3d, + 0x2,0x4c,0x36, 0x3,0x48,0x3f, 0x3,0x48,0x45, 0x1,0x65,0x50, + 0x3,0x48,0x44, 0x2,0x4c,0x33, 0x1,0x69,0x79, 0x2,0x4c,0x35, + 0x3,0x65,0x73, 0x3,0x48,0x40, 0xf,0x4a,0x3f, 0x1,0x6d,0x7d, + 0x2,0x52,0x49, 0x1,0x6e,0x23, 0x4,0x4b,0x59, 0x1,0x6e,0x21, + 0x4,0x4b,0x57, 0x3,0x4d,0x4a, 0x1,0x69,0x76, 0x3,0x4d,0x4d, + 0x2,0x52,0x50, 0x2,0x52,0x51, 0x1,0x6d,0x7c, 0x3,0x4d,0x48, + 0x3,0x4d,0x4c, 0x2,0x52,0x4f, 0x2,0x52,0x52, 0x1,0x6d,0x7e, + 0x1,0x6d,0x7b, 0x2,0x52,0x4b, 0x2,0x52,0x48, 0x2,0x52,0x4d, + 0x2,0x52,0x4a, 0x1,0x6e,0x24, 0x2,0x52,0x4c, 0x3,0x4d,0x4b, + 0x3,0x4d,0x49, 0x2,0x52,0x4e, 0x1,0x6e,0x22, 0x3,0x52,0x21, + 0x3,0x65,0x74, 0x1,0x71,0x54, 0x2,0x58,0x72, 0x3,0x52,0x24, + 0x2,0x58,0x6c, 0x2,0x58,0x70, 0x2,0x58,0x76, 0x2,0x58,0x77, + 0x2,0x58,0x73, 0x2,0x58,0x74, 0x2,0x58,0x71, 0x4,0x4b,0x5d, + 0x2,0x58,0x6e, 0x4,0x51,0x6e, 0x1,0x71,0x56, 0x1,0x71,0x53, + 0x2,0x58,0x6d, 0x2,0x58,0x6f, 0x3,0x52,0x22, 0x1,0x71,0x55, + 0x2,0x58,0x75, 0x3,0x65,0x75, 0x1,0x74,0x50, 0x3,0x55,0x60, + 0x3,0x55,0x62, 0x2,0x5d,0x75, 0x2,0x5d,0x6f, 0x1,0x74,0x4f, + 0x4,0x57,0x3e, 0x1,0x74,0x4d, 0x3,0x55,0x61, 0x2,0x5d,0x77, + 0x1,0x74,0x4e, 0x2,0x5d,0x72, 0x2,0x5d,0x73, 0x2,0x5d,0x70, + 0x2,0x5d,0x78, 0x2,0x5d,0x74, 0x4,0x57,0x40, 0x1,0x74,0x51, + 0x2,0x5d,0x71, 0x2,0x5d,0x79, 0x2,0x5d,0x76, 0x3,0x58,0x43, + 0x3,0x58,0x3e, 0x3,0x58,0x40, 0x2,0x62,0x46, 0x3,0x58,0x3f, + 0x3,0x58,0x3c, 0x2,0x62,0x43, 0x3,0x58,0x42, 0x1,0x76,0x70, + 0x4,0x5c,0x32, 0x2,0x62,0x47, 0x2,0x62,0x49, 0x2,0x62,0x48, + 0x2,0x62,0x44, 0x2,0x62,0x45, 0x3,0x58,0x44, 0x2,0x66,0x2d, + 0x3,0x5a,0x61, 0x1,0x78,0x55, 0x3,0x5a,0x62, 0x2,0x66,0x2a, + 0x2,0x66,0x2c, 0x2,0x66,0x29, 0x2,0x66,0x2e, 0x4,0x60,0x42, + 0x3,0x5a,0x63, 0x2,0x66,0x2b, 0x3,0x65,0x76, 0x2,0x69,0x49, + 0x2,0x69,0x4c, 0x2,0x69,0x48, 0x1,0x79,0x7c, 0x2,0x69,0x4a, + 0x2,0x69,0x4b, 0x2,0x69,0x4d, 0x1,0x79,0x7d, 0x1,0x7a,0x21, + 0x1,0x79,0x7e, 0x2,0x6b,0x6f, 0x3,0x5e,0x45, 0x2,0x6b,0x71, + 0x3,0x5e,0x43, 0x2,0x6b,0x70, 0x3,0x5e,0x44, 0x2,0x6d,0x64, + 0xf,0x6a,0x66, 0x3,0x60,0x3c, 0x2,0x70,0x43, 0x2,0x71,0x2a, + 0x1,0x46,0x7c, 0x3,0x24,0x33, 0x2,0x24,0x72, 0x1,0x4f,0x23, + 0x2,0x28,0x43, 0x1,0x4f,0x24, 0x1,0x4f,0x25, 0x2,0x28,0x42, + 0x2,0x2c,0x5a, 0x2,0x2c,0x59, 0x1,0x52,0x69, 0x1,0x52,0x6c, + 0x1,0x52,0x6b, 0x1,0x52,0x6a, 0x2,0x2c,0x56, 0x2,0x2c,0x58, + 0x2,0x2c,0x57, 0x3,0x65,0x77, 0x2,0x31,0x4b, 0x1,0x57,0x2a, + 0x2,0x31,0x4f, 0x2,0x31,0x4e, 0x2,0x31,0x4d, 0x2,0x31,0x49, + 0x1,0x57,0x29, 0x1,0x57,0x2d, 0x1,0x57,0x30, 0x3,0x32,0x6f, + 0x3,0x32,0x70, 0x1,0x57,0x31, 0x2,0x31,0x4a, 0x2,0x31,0x4c, + 0x1,0x57,0x2f, 0x1,0x57,0x2e, 0x1,0x57,0x2c, 0x1,0x57,0x2b, + 0x2,0x37,0x65, 0x3,0x32,0x72, 0x2,0x37,0x63, 0x2,0x37,0x5f, + 0x1,0x5c,0x40, 0x3,0x3d,0x5e, 0x2,0x37,0x60, 0x1,0x5c,0x41, + 0x2,0x37,0x61, 0x2,0x37,0x62, 0x2,0x37,0x64, 0x3,0x37,0x66, + 0x1,0x5c,0x42, 0x3,0x37,0x65, 0x2,0x3e,0x59, 0x3,0x3d,0x5f, + 0x2,0x3e,0x58, 0x2,0x3e,0x57, 0x2,0x3e,0x56, 0x3,0x3d,0x64, + 0x3,0x3d,0x62, 0x4,0x39,0x5a, 0x2,0x45,0x5c, 0x1,0x65,0x59, + 0x4,0x3f,0x46, 0x2,0x45,0x59, 0x2,0x45,0x5b, 0x3,0x43,0x38, + 0x1,0x65,0x5a, 0x3,0x43,0x3d, 0x1,0x65,0x5b, 0x2,0x45,0x5a, + 0x3,0x43,0x39, 0x3,0x3d,0x63, 0x3,0x65,0x78, 0x3,0x48,0x48, + 0x2,0x4c,0x48, 0x3,0x48,0x47, 0x2,0x4c,0x41, 0x2,0x4c,0x42, + 0x5,0x47,0x7e, 0x1,0x69,0x7e, 0x1,0x69,0x7c, 0x1,0x69,0x7d, + 0x2,0x4c,0x4a, 0x5,0x48,0x22, 0x2,0x4c,0x49, 0x2,0x4c,0x46, + 0x2,0x4c,0x45, 0x2,0x4c,0x44, 0x2,0x4c,0x43, 0x2,0x4c,0x47, + 0x2,0x4c,0x40, 0x3,0x65,0x79, 0x2,0x52,0x53, 0x2,0x52,0x58, + 0x2,0x52,0x56, 0x3,0x4d,0x50, 0x3,0x4d,0x51, 0x3,0x4d,0x4f, + 0x2,0x52,0x55, 0x2,0x52,0x54, 0x2,0x52,0x57, 0x3,0x65,0x7a, + 0x2,0x58,0x78, 0x3,0x52,0x26, 0x1,0x71,0x57, 0x1,0x74,0x52, + 0x2,0x5d,0x7b, 0x3,0x52,0x27, 0x1,0x74,0x53, 0x2,0x5d,0x7a, + 0x2,0x62,0x4b, 0x2,0x62,0x4a, 0x1,0x76,0x71, 0x3,0x58,0x45, + 0x2,0x66,0x2f, 0x1,0x78,0x56, 0x2,0x69,0x4e, 0x1,0x7b,0x6b, + 0x2,0x6d,0x65, 0x3,0x60,0x3d, 0x2,0x70,0x45, 0x2,0x70,0x44, + 0x2,0x21,0x67, 0x1,0x52,0x6d, 0x1,0x52,0x6e, 0x2,0x37,0x66, + 0x3,0x65,0x7b, 0x1,0x65,0x5d, 0x1,0x46,0x7d, 0x1,0x4b,0x35, + 0x1,0x4b,0x34, 0x1,0x4b,0x33, 0x4,0x24,0x68, 0x3,0x2a,0x3e, + 0x3,0x2a,0x3d, 0x2,0x28,0x44, 0x3,0x2a,0x3f, 0x3,0x2a,0x42, + 0x1,0x4f,0x27, 0x1,0x4f,0x26, 0x3,0x2a,0x44, 0x1,0x52,0x71, + 0x3,0x65,0x4c, 0x2,0x2c,0x5c, 0x2,0x2c,0x5f, 0x2,0x2c,0x5d, + 0x3,0x2e,0x42, 0x1,0x52,0x6f, 0x1,0x52,0x70, 0x3,0x2e,0x40, + 0x3,0x2e,0x41, 0x2,0x2c,0x5b, 0x2,0x2c,0x5e, 0x3,0x2e,0x43, + 0x1,0x57,0x38, 0x3,0x32,0x74, 0x3,0x32,0x73, 0x3,0x32,0x79, + 0x2,0x31,0x56, 0x2,0x31,0x58, 0x2,0x31,0x57, 0x1,0x57,0x35, + 0x2,0x31,0x52, 0x3,0x32,0x76, 0x3,0x32,0x7b, 0x1,0x57,0x33, + 0x1,0x57,0x32, 0x3,0x32,0x77, 0x1,0x57,0x36, 0x1,0x57,0x34, + 0x3,0x32,0x78, 0x1,0x57,0x37, 0x2,0x31,0x55, 0x2,0x31,0x50, + 0x2,0x31,0x51, 0x2,0x31,0x54, 0x2,0x31,0x53, 0x3,0x32,0x7c, + 0x3,0x37,0x69, 0x3,0x37,0x67, 0x3,0x37,0x6b, 0x3,0x37,0x6a, + 0x2,0x37,0x69, 0x2,0x37,0x6a, 0x2,0x37,0x68, 0x3,0x37,0x6c, + 0x2,0x37,0x67, 0x1,0x5c,0x43, 0xf,0x37,0x3f, 0x3,0x3d,0x65, + 0x1,0x61,0x25, 0x6,0x4c,0x48, 0x2,0x3e,0x5a, 0x2,0x3e,0x5c, + 0x2,0x3e,0x5e, 0x1,0x61,0x24, 0x6,0x4c,0x43, 0x3,0x3d,0x66, + 0x1,0x61,0x22, 0x3,0x3d,0x69, 0x2,0x3e,0x5b, 0x1,0x61,0x23, + 0x2,0x3e,0x5d, 0x1,0x61,0x21, 0x3,0x3d,0x68, 0x3,0x43,0x41, + 0x2,0x45,0x66, 0x2,0x45,0x5d, 0x2,0x45,0x60, 0x2,0x45,0x64, + 0x1,0x65,0x61, 0x2,0x45,0x62, 0x4,0x3f,0x50, 0x2,0x45,0x61, + 0x2,0x45,0x5e, 0x2,0x45,0x5f, 0x1,0x65,0x5f, 0x2,0x45,0x65, + 0x1,0x65,0x5e, 0x3,0x43,0x44, 0x1,0x65,0x63, 0x1,0x65,0x62, + 0x1,0x65,0x60, 0x4,0x3f,0x4a, 0x2,0x45,0x63, 0x3,0x65,0x24, + 0x2,0x4c,0x50, 0x4,0x45,0x5d, 0x2,0x4c,0x4f, 0x3,0x48,0x4b, + 0x3,0x48,0x4d, 0x2,0x4c,0x4b, 0x3,0x48,0x50, 0x3,0x48,0x4f, + 0x1,0x6a,0x21, 0x2,0x4c,0x4e, 0x2,0x4c,0x4d, 0x1,0x6a,0x22, + 0x3,0x48,0x52, 0xf,0x4a,0x64, 0x4,0x4b,0x63, 0x4,0x45,0x5e, + 0x4,0x4b,0x6b, 0x1,0x6e,0x29, 0x3,0x4d,0x55, 0x2,0x52,0x5a, + 0x3,0x4d,0x56, 0x1,0x6e,0x2a, 0x1,0x6e,0x26, 0x1,0x6e,0x28, + 0x3,0x4d,0x5a, 0x1,0x6e,0x25, 0x1,0x6e,0x27, 0x3,0x4d,0x53, + 0x3,0x4d,0x57, 0x2,0x58,0x79, 0x3,0x52,0x2a, 0x1,0x71,0x5a, + 0x2,0x58,0x7b, 0x2,0x58,0x7a, 0x3,0x55,0x64, 0x2,0x4c,0x4c, + 0x1,0x71,0x5c, 0x1,0x71,0x5b, 0x1,0x71,0x58, 0x1,0x71,0x59, + 0x3,0x52,0x2c, 0xf,0x5b,0x59, 0x3,0x52,0x29, 0x2,0x5e,0x22, + 0x4,0x57,0x49, 0x2,0x5d,0x7e, 0x1,0x74,0x54, 0x2,0x5e,0x21, + 0x4,0x57,0x48, 0x2,0x5e,0x23, 0x2,0x5d,0x7d, 0x2,0x5d,0x7c, + 0x2,0x62,0x4c, 0x1,0x76,0x74, 0x1,0x76,0x72, 0x1,0x76,0x73, + 0x3,0x5a,0x66, 0x4,0x60,0x45, 0x3,0x5a,0x65, 0x2,0x66,0x30, + 0x2,0x66,0x31, 0x1,0x78,0x58, 0x3,0x5a,0x67, 0x1,0x78,0x57, + 0x2,0x69,0x50, 0x2,0x69,0x51, 0x2,0x69,0x4f, 0x3,0x5c,0x64, + 0x2,0x6d,0x66, 0x2,0x6d,0x67, 0x3,0x60,0x76, 0x3,0x60,0x77, + 0x1,0x46,0x7e, 0x2,0x22,0x68, 0x1,0x4b,0x36, 0x2,0x28,0x45, + 0x1,0x4f,0x29, 0x1,0x4f,0x28, 0x2,0x28,0x46, 0x3,0x2e,0x44, + 0x3,0x2e,0x47, 0x2,0x2c,0x61, 0x1,0x52,0x72, 0x2,0x2c,0x60, + 0x1,0x52,0x73, 0x3,0x2e,0x49, 0x3,0x2e,0x48, 0x1,0x57,0x39, + 0x2,0x31,0x5b, 0x2,0x31,0x59, 0x2,0x31,0x5f, 0x1,0x57,0x3a, + 0x2,0x31,0x5a, 0x2,0x31,0x5e, 0x2,0x31,0x5c, 0x2,0x31,0x5d, + 0x2,0x37,0x6b, 0x2,0x37,0x6d, 0x3,0x37,0x72, 0x1,0x5c,0x44, + 0x3,0x37,0x71, 0x2,0x37,0x6c, 0x1,0x5c,0x45, 0x1,0x61,0x28, + 0x1,0x61,0x27, 0x1,0x61,0x26, 0x2,0x3e,0x5f, 0x3,0x37,0x70, + 0x4,0x39,0x65, 0x2,0x45,0x69, 0x1,0x65,0x64, 0x1,0x65,0x65, + 0x3,0x43,0x46, 0x2,0x45,0x68, 0x2,0x45,0x67, 0x3,0x43,0x47, + 0x3,0x65,0x7c, 0x2,0x4c,0x51, 0x1,0x6a,0x24, 0x1,0x6a,0x23, + 0x2,0x4c,0x52, 0x2,0x4c,0x53, 0x1,0x6e,0x2c, 0x1,0x6e,0x2b, + 0x3,0x4d,0x5b, 0x2,0x59,0x21, 0x2,0x52,0x5b, 0x2,0x52,0x5d, + 0x2,0x52,0x5c, 0x2,0x58,0x7e, 0x2,0x58,0x7c, 0x2,0x59,0x22, + 0x2,0x58,0x7d, 0x5,0x56,0x52, 0x1,0x71,0x5d, 0x3,0x52,0x2f, + 0x4,0x52,0x27, 0x3,0x52,0x2e, 0x2,0x5e,0x24, 0x1,0x74,0x55, + 0x2,0x5e,0x25, 0x2,0x5e,0x26, 0x3,0x55,0x68, 0x1,0x76,0x75, + 0x1,0x76,0x76, 0x4,0x60,0x4b, 0x1,0x7a,0x22, 0x3,0x5e,0x49, + 0x3,0x5e,0x48, 0x1,0x7c,0x3d, 0x1,0x47,0x21, 0x3,0x26,0x7e, + 0x3,0x27,0x21, 0x4,0x27,0x5b, 0x3,0x2a,0x47, 0x3,0x2e,0x4e, + 0x2,0x2c,0x62, 0x3,0x2e,0x4f, 0x3,0x2e,0x4d, 0x3,0x2e,0x4b, + 0x3,0x2e,0x4c, 0xf,0x2c,0x76, 0x2,0x31,0x60, 0x1,0x57,0x3b, + 0x3,0x33,0x23, 0x3,0x33,0x26, 0x3,0x33,0x27, 0x3,0x33,0x24, + 0x1,0x5d,0x7e, 0x1,0x5d,0x7d, 0x3,0x37,0x73, 0x3,0x3d,0x71, + 0x1,0x61,0x2a, 0x2,0x3e,0x61, 0x1,0x61,0x29, 0x2,0x3e,0x60, + 0x3,0x3d,0x70, 0x4,0x3f,0x57, 0x3,0x43,0x49, 0x3,0x43,0x4a, + 0x2,0x45,0x6a, 0x3,0x48,0x54, 0x1,0x6a,0x25, 0x2,0x4c,0x54, + 0x1,0x6a,0x26, 0x3,0x48,0x55, 0x3,0x52,0x30, 0x3,0x55,0x69, + 0x3,0x55,0x6a, 0x4,0x57,0x50, 0x3,0x58,0x49, 0x1,0x7a,0x23, + 0x2,0x69,0x52, 0x3,0x5f,0x55, 0x1,0x48,0x4c, 0x1,0x4f,0x2a, + 0x2,0x28,0x47, 0x3,0x2e,0x51, 0x1,0x52,0x75, 0x3,0x2e,0x50, + 0x1,0x52,0x74, 0x2,0x2c,0x63, 0x2,0x2c,0x64, 0x2,0x31,0x62, + 0x2,0x31,0x64, 0x1,0x57,0x3c, 0x2,0x31,0x66, 0x2,0x31,0x69, + 0x2,0x31,0x67, 0x3,0x33,0x2b, 0x4,0x2e,0x71, 0x3,0x33,0x2a, + 0x2,0x31,0x68, 0x2,0x31,0x65, 0x2,0x31,0x61, 0x1,0x57,0x3d, + 0x2,0x31,0x6a, 0x2,0x31,0x63, 0x3,0x33,0x2c, 0x3,0x37,0x78, + 0x3,0x37,0x79, 0x2,0x37,0x76, 0x1,0x5c,0x4b, 0x2,0x38,0x21, + 0x1,0x5c,0x48, 0x3,0x37,0x77, 0x2,0x37,0x78, 0x1,0x5c,0x4c, + 0x3,0x37,0x7b, 0x1,0x5c,0x46, 0x3,0x37,0x76, 0x2,0x37,0x73, + 0x2,0x38,0x22, 0x2,0x37,0x74, 0x2,0x37,0x71, 0x1,0x5c,0x4a, + 0x4,0x33,0x7c, 0x1,0x5c,0x47, 0x4,0x33,0x7a, 0x2,0x37,0x77, + 0x2,0x37,0x7a, 0x1,0x5c,0x49, 0x2,0x37,0x7b, 0x1,0x5c,0x4d, + 0x2,0x37,0x7c, 0x2,0x37,0x72, 0x2,0x37,0x79, 0x2,0x37,0x7d, + 0x2,0x37,0x75, 0x2,0x37,0x70, 0x2,0x37,0x6e, 0x3,0x37,0x7a, + 0x3,0x65,0x7d, 0x2,0x37,0x7e, 0xf,0x37,0x4d, 0x2,0x37,0x6f, + 0xf,0x36,0x7e, 0x5,0x3b,0x24, 0x2,0x3e,0x68, 0x3,0x3d,0x7b, + 0x3,0x3d,0x78, 0x3,0x3d,0x75, 0x2,0x3e,0x64, 0x2,0x3e,0x6a, + 0x1,0x61,0x2d, 0x2,0x3e,0x63, 0x2,0x3e,0x65, 0x1,0x61,0x2b, + 0x2,0x3e,0x62, 0x1,0x61,0x32, 0x2,0x3e,0x66, 0x1,0x61,0x31, + 0x2,0x3e,0x67, 0x1,0x61,0x33, 0x1,0x61,0x2e, 0x1,0x61,0x34, + 0x1,0x61,0x2f, 0x3,0x3d,0x79, 0x1,0x61,0x30, 0x3,0x3d,0x72, + 0x1,0x61,0x2c, 0x3,0x3d,0x76, 0x2,0x3e,0x69, 0x3,0x65,0x7e, + 0x3,0x43,0x4f, 0x4,0x3f,0x67, 0x1,0x65,0x68, 0x2,0x45,0x75, + 0x3,0x43,0x4c, 0x2,0x45,0x78, 0x2,0x45,0x6c, 0x2,0x45,0x71, + 0x2,0x45,0x6b, 0x1,0x65,0x6a, 0x3,0x43,0x55, 0x2,0x45,0x6f, + 0x4,0x3f,0x5e, 0x3,0x43,0x4d, 0x3,0x3d,0x77, 0x2,0x45,0x6d, + 0x1,0x65,0x69, 0x3,0x43,0x54, 0x2,0x45,0x74, 0x2,0x45,0x73, + 0x2,0x45,0x70, 0x2,0x45,0x72, 0x2,0x45,0x6e, 0x1,0x6a,0x2a, + 0x2,0x45,0x77, 0x1,0x65,0x66, 0x2,0x45,0x76, 0x3,0x43,0x51, + 0xf,0x44,0x45, 0x3,0x48,0x56, 0x2,0x4c,0x64, 0x3,0x48,0x58, + 0x1,0x6a,0x31, 0x2,0x4c,0x5f, 0x3,0x48,0x60, 0x1,0x6a,0x30, + 0x2,0x4c,0x55, 0x4,0x45,0x6b, 0x2,0x4c,0x57, 0x1,0x6a,0x29, + 0x2,0x4c,0x5c, 0x2,0x4c,0x5b, 0x2,0x4c,0x5e, 0x1,0x6a,0x2e, + 0x2,0x4c,0x59, 0x2,0x4c,0x58, 0x3,0x48,0x5a, 0x3,0x48,0x5e, + 0x1,0x6a,0x2d, 0x1,0x6a,0x28, 0x2,0x4c,0x5a, 0x1,0x6a,0x2b, + 0x2,0x4c,0x60, 0x2,0x4c,0x62, 0x2,0x4c,0x5d, 0x2,0x4c,0x56, + 0x1,0x6a,0x2c, 0x3,0x48,0x57, 0x3,0x48,0x5d, 0x1,0x6e,0x34, + 0x1,0x6a,0x27, 0x4,0x45,0x64, 0x3,0x48,0x5c, 0x2,0x4c,0x63, + 0x4,0x45,0x70, 0x2,0x52,0x61, 0x1,0x6e,0x2d, 0x3,0x4d,0x5c, + 0x2,0x52,0x63, 0x4,0x4c,0x2b, 0x1,0x6e,0x2e, 0x3,0x4d,0x65, + 0x3,0x4d,0x5d, 0x1,0x6e,0x30, 0x2,0x52,0x66, 0x4,0x4b,0x7a, + 0x2,0x52,0x5e, 0x1,0x6a,0x2f, 0x2,0x52,0x64, 0x4,0x4b,0x73, + 0x4,0x4c,0x31, 0x4,0x4b,0x74, 0x4,0x4c,0x2a, 0x2,0x52,0x60, + 0x3,0x4d,0x60, 0x1,0x65,0x67, 0x1,0x6e,0x33, 0x4,0x4c,0x21, + 0x4,0x4b,0x78, 0x1,0x6e,0x2f, 0x4,0x4c,0x26, 0x1,0x6e,0x31, + 0x1,0x6e,0x32, 0x4,0x4b,0x76, 0x1,0x71,0x60, 0x2,0x52,0x65, + 0x2,0x52,0x5f, 0x1,0x6e,0x35, 0x3,0x4d,0x63, 0x2,0x52,0x62, + 0x3,0x66,0x21, 0x2,0x59,0x2c, 0x2,0x59,0x27, 0x4,0x52,0x2d, + 0x5,0x56,0x69, 0x2,0x59,0x31, 0x1,0x71,0x5e, 0x2,0x59,0x29, + 0x1,0x71,0x62, 0x2,0x59,0x2f, 0x2,0x59,0x26, 0x2,0x59,0x23, + 0x2,0x59,0x32, 0x1,0x74,0x5b, 0x1,0x71,0x63, 0x2,0x59,0x2e, + 0x2,0x59,0x24, 0x1,0x71,0x61, 0x2,0x59,0x28, 0x1,0x71,0x65, + 0x2,0x59,0x25, 0x2,0x59,0x2a, 0x1,0x71,0x64, 0x2,0x59,0x2d, + 0x2,0x59,0x30, 0x3,0x52,0x33, 0x3,0x52,0x34, 0x2,0x5e,0x38, + 0x2,0x5e,0x39, 0x2,0x5e,0x29, 0x2,0x5e,0x30, 0x2,0x5e,0x2e, + 0x4,0x57,0x5f, 0x3,0x55,0x6d, 0x1,0x74,0x59, 0x2,0x5e,0x35, + 0x2,0x59,0x2b, 0x3,0x55,0x6b, 0x2,0x5e,0x2c, 0x3,0x55,0x6e, + 0x2,0x5e,0x36, 0x1,0x74,0x58, 0x2,0x5e,0x2b, 0x2,0x5e,0x2a, + 0x2,0x5e,0x34, 0x2,0x5e,0x31, 0x2,0x5e,0x33, 0x4,0x57,0x54, + 0x2,0x5e,0x27, 0x2,0x5e,0x37, 0x1,0x74,0x56, 0x3,0x55,0x70, + 0x2,0x5e,0x32, 0x2,0x5e,0x3b, 0x2,0x5e,0x2f, 0x1,0x74,0x5a, + 0x1,0x74,0x57, 0x2,0x5e,0x2d, 0x2,0x5e,0x28, 0x2,0x5e,0x3a, + 0x1,0x71,0x5f, 0x3,0x55,0x71, 0xf,0x5b,0x5f, 0x4,0x57,0x57, + 0x3,0x55,0x6f, 0x2,0x62,0x4f, 0x3,0x58,0x50, 0x3,0x58,0x4e, + 0x2,0x62,0x4d, 0x2,0x62,0x53, 0x1,0x76,0x7a, 0x2,0x62,0x51, + 0x2,0x62,0x50, 0x1,0x76,0x7c, 0x2,0x62,0x56, 0x1,0x76,0x7b, + 0x3,0x58,0x51, 0x2,0x62,0x57, 0x2,0x62,0x54, 0x1,0x76,0x78, + 0x2,0x62,0x55, 0x2,0x62,0x4e, 0x1,0x76,0x79, 0x1,0x76,0x77, + 0x2,0x66,0x35, 0x2,0x62,0x52, 0x3,0x58,0x4c, 0x3,0x66,0x22, + 0x2,0x62,0x58, 0x3,0x66,0x23, 0x2,0x66,0x32, 0x3,0x5a,0x6f, + 0x3,0x5a,0x6e, 0x4,0x60,0x4e, 0x1,0x78,0x5d, 0x1,0x78,0x5b, + 0x2,0x66,0x34, 0x4,0x60,0x4c, 0x2,0x66,0x36, 0x2,0x66,0x33, + 0x1,0x78,0x5c, 0x1,0x78,0x59, 0x1,0x78,0x5a, 0x1,0x78,0x5e, + 0x3,0x66,0x24, 0x1,0x7a,0x25, 0x3,0x5c,0x66, 0x2,0x69,0x57, + 0x5,0x6c,0x79, 0x2,0x69,0x56, 0x2,0x69,0x54, 0x2,0x69,0x53, + 0x2,0x69,0x55, 0x3,0x5c,0x65, 0x1,0x7a,0x24, 0x1,0x7a,0x26, + 0x3,0x66,0x25, 0xf,0x65,0x67, 0x1,0x7a,0x7b, 0x3,0x5e,0x4c, + 0x4,0x66,0x6f, 0x2,0x6b,0x73, 0x2,0x6b,0x72, 0x3,0x5c,0x67, + 0x3,0x5e,0x4b, 0x2,0x6d,0x68, 0x3,0x5f,0x58, 0x2,0x6d,0x6a, + 0x2,0x6d,0x6c, 0x2,0x6d,0x6b, 0x2,0x6d,0x69, 0x3,0x5f,0x57, + 0x3,0x60,0x3f, 0x1,0x7b,0x6d, 0x1,0x7b,0x6c, 0x3,0x60,0x3e, + 0x1,0x7c,0x3f, 0x1,0x7c,0x3e, 0x1,0x7c,0x40, 0x2,0x6f,0x3c, + 0x2,0x6f,0x3b, 0x3,0x66,0x26, 0x2,0x71,0x2b, 0x2,0x70,0x46, + 0x2,0x71,0x2c, 0x1,0x7d,0x25, 0x3,0x61,0x44, 0x1,0x7d,0x26, + 0x2,0x71,0x5c, 0x4,0x6d,0x5b, 0x3,0x62,0x3a, 0x1,0x7d,0x4b, + 0x1,0x48,0x4d, 0x3,0x2a,0x49, 0x2,0x28,0x48, 0x3,0x2a,0x48, + 0x3,0x2e,0x52, 0x2,0x2c,0x66, 0x2,0x2c,0x67, 0x2,0x2c,0x65, + 0x3,0x2e,0x54, 0x3,0x2e,0x53, 0x1,0x52,0x76, 0xf,0x2d,0x21, + 0x2,0x2c,0x68, 0x2,0x2c,0x69, 0x2,0x2c,0x6a, 0x3,0x33,0x31, + 0x2,0x31,0x6b, 0x2,0x31,0x71, 0x3,0x33,0x2e, 0x3,0x33,0x30, + 0x2,0x31,0x6f, 0x1,0x57,0x3e, 0x2,0x31,0x6d, 0x3,0x33,0x32, + 0x2,0x31,0x6e, 0x2,0x31,0x70, 0x3,0x33,0x2d, 0x2,0x31,0x6c, + 0x1,0x5c,0x4e, 0x3,0x37,0x7d, 0x2,0x38,0x23, 0x1,0x5c,0x50, + 0x2,0x38,0x25, 0x1,0x5c,0x4f, 0x2,0x38,0x24, 0x3,0x37,0x7e, + 0x3,0x38,0x21, 0x3,0x38,0x3e, 0x3,0x38,0x22, 0x4,0x34,0x22, + 0x2,0x3e,0x6c, 0x1,0x61,0x35, 0x3,0x3e,0x21, 0x2,0x3e,0x6e, + 0x2,0x3e,0x6b, 0x2,0x38,0x26, 0x3,0x3e,0x23, 0x1,0x61,0x36, + 0x3,0x3e,0x22, 0x3,0x3d,0x7e, 0x2,0x3e,0x6d, 0x3,0x66,0x27, + 0xf,0x3e,0x21, 0xf,0x3e,0x23, 0x3,0x43,0x58, 0x2,0x45,0x7b, + 0x3,0x43,0x5c, 0x1,0x65,0x6b, 0x2,0x45,0x79, 0x1,0x65,0x6c, + 0x2,0x45,0x7a, 0x1,0x65,0x6d, 0x4,0x45,0x74, 0x3,0x48,0x62, + 0x3,0x48,0x61, 0x1,0x6a,0x32, 0x2,0x4c,0x68, 0x2,0x4c,0x65, + 0x2,0x4c,0x67, 0x1,0x6a,0x33, 0x1,0x6a,0x34, 0x2,0x4c,0x66, + 0xf,0x4b,0x27, 0xf,0x4b,0x2b, 0x3,0x4d,0x6f, 0x3,0x4d,0x71, + 0x3,0x4d,0x6d, 0x2,0x52,0x67, 0x3,0x4d,0x70, 0x3,0x4d,0x73, + 0x2,0x52,0x68, 0x3,0x4d,0x72, 0x1,0x6e,0x36, 0x2,0x52,0x6a, + 0x2,0x52,0x69, 0x3,0x4d,0x6e, 0x1,0x23,0x23, 0x4,0x52,0x44, + 0x2,0x59,0x36, 0x2,0x59,0x37, 0x2,0x59,0x33, 0x3,0x52,0x37, + 0x2,0x59,0x34, 0x1,0x71,0x66, 0x1,0x71,0x67, 0x2,0x59,0x35, + 0x1,0x74,0x61, 0x3,0x55,0x75, 0x3,0x55,0x74, 0x1,0x74,0x5d, + 0x1,0x74,0x62, 0x1,0x74,0x5e, 0x1,0x74,0x60, 0x1,0x74,0x5c, + 0x3,0x52,0x39, 0x1,0x74,0x5f, 0x3,0x58,0x55, 0x4,0x5c,0x5a, + 0x4,0x5c,0x5b, 0x3,0x58,0x54, 0x1,0x76,0x7d, 0x2,0x5e,0x3c, + 0x7,0x48,0x57, 0x2,0x66,0x38, 0x4,0x60,0x5a, 0x2,0x66,0x37, + 0x3,0x66,0x28, 0x2,0x69,0x58, 0x1,0x7a,0x27, 0x1,0x7a,0x28, + 0x2,0x6d,0x6e, 0x2,0x6b,0x74, 0x3,0x61,0x69, 0x2,0x6d,0x6d, + 0x3,0x60,0x40, 0x2,0x71,0x2d, 0x2,0x71,0x72, 0x1,0x48,0x4e, + 0x3,0x27,0x22, 0x1,0x4b,0x37, 0x3,0x2a,0x4b, 0x2,0x28,0x49, + 0x1,0x4f,0x2b, 0x3,0x2a,0x4a, 0x1,0x52,0x79, 0x2,0x2c,0x6d, + 0x1,0x52,0x77, 0x2,0x2c,0x6b, 0x1,0x52,0x7c, 0x1,0x52,0x78, + 0x1,0x52,0x7d, 0x1,0x52,0x7b, 0x2,0x2c,0x6c, 0x1,0x52,0x7a, + 0x1,0x57,0x42, 0x1,0x57,0x41, 0x2,0x31,0x7c, 0x1,0x57,0x4a, + 0x2,0x31,0x75, 0x2,0x31,0x7b, 0x1,0x57,0x46, 0x2,0x31,0x74, + 0x2,0x31,0x7a, 0x2,0x31,0x78, 0x1,0x57,0x45, 0x1,0x57,0x47, + 0x2,0x31,0x77, 0x1,0x57,0x40, 0x2,0x31,0x76, 0x1,0x57,0x4b, + 0x1,0x57,0x48, 0x1,0x57,0x4c, 0x1,0x57,0x49, 0x2,0x31,0x73, + 0x2,0x31,0x72, 0x2,0x31,0x79, 0x1,0x57,0x43, 0x1,0x57,0x3f, + 0x1,0x57,0x44, 0x4,0x2f,0x25, 0x3,0x33,0x37, 0x3,0x33,0x3b, + 0x2,0x38,0x35, 0x2,0x38,0x2e, 0x4,0x3a,0x26, 0x1,0x61,0x3b, + 0x2,0x38,0x2d, 0x3,0x38,0x29, 0x1,0x5c,0x54, 0x1,0x5c,0x5b, + 0x1,0x5c,0x58, 0x1,0x5c,0x5e, 0x1,0x5c,0x5d, 0x1,0x5c,0x59, + 0x3,0x38,0x26, 0x2,0x38,0x27, 0x2,0x38,0x2a, 0x3,0x38,0x27, + 0x2,0x38,0x29, 0x1,0x5c,0x55, 0x2,0x38,0x2b, 0x2,0x38,0x34, + 0x1,0x5c,0x56, 0x2,0x38,0x28, 0x2,0x38,0x31, 0x2,0x38,0x32, + 0x1,0x5c,0x57, 0x2,0x38,0x2f, 0x1,0x5c,0x5c, 0x1,0x5c,0x52, + 0x1,0x5c,0x5a, 0x2,0x38,0x2c, 0x1,0x5c,0x51, 0x2,0x38,0x30, + 0x3,0x38,0x2e, 0x3,0x38,0x24, 0x2,0x38,0x33, 0xf,0x37,0x54, + 0x3,0x38,0x2b, 0x3,0x3e,0x34, 0x2,0x3f,0x21, 0x2,0x3e,0x76, + 0x1,0x61,0x38, 0x2,0x3e,0x7d, 0x2,0x3e,0x7a, 0x2,0x3e,0x72, + 0x2,0x3e,0x7b, 0x1,0x61,0x3a, 0x2,0x3e,0x73, 0x3,0x3e,0x29, + 0x2,0x3e,0x6f, 0x3,0x3e,0x26, 0x3,0x3e,0x2e, 0x1,0x65,0x73, + 0x2,0x3e,0x78, 0x3,0x3e,0x2f, 0x1,0x61,0x37, 0x2,0x3e,0x7e, + 0x3,0x3e,0x28, 0x1,0x61,0x3e, 0x1,0x61,0x40, 0x2,0x3e,0x71, + 0x3,0x3e,0x2c, 0x4,0x3a,0x27, 0x1,0x61,0x3f, 0x2,0x3e,0x74, + 0x1,0x61,0x39, 0x2,0x3e,0x7c, 0x2,0x3e,0x75, 0x2,0x3e,0x79, + 0x3,0x3e,0x2a, 0x2,0x3e,0x77, 0x1,0x61,0x3c, 0x2,0x3e,0x70, + 0x1,0x61,0x41, 0x1,0x5c,0x53, 0x1,0x61,0x3d, 0x1,0x61,0x42, + 0x3,0x3e,0x24, 0x3,0x3e,0x35, 0x3,0x3e,0x33, 0x3,0x43,0x67, + 0x1,0x65,0x6f, 0x2,0x46,0x24, 0x2,0x46,0x26, 0x2,0x46,0x28, + 0x2,0x46,0x2c, 0x3,0x3e,0x2b, 0x2,0x46,0x22, 0x2,0x45,0x7e, + 0x1,0x65,0x71, 0x4,0x3f,0x71, 0x2,0x46,0x27, 0x2,0x46,0x2b, + 0x2,0x46,0x23, 0x2,0x45,0x7d, 0x3,0x43,0x66, 0x2,0x45,0x7c, + 0x3,0x43,0x69, 0x3,0x43,0x60, 0x3,0x43,0x62, 0x2,0x46,0x29, + 0x2,0x46,0x21, 0x2,0x46,0x25, 0x1,0x65,0x72, 0x3,0x43,0x5e, + 0x1,0x65,0x70, 0x2,0x46,0x2d, 0x1,0x65,0x6e, 0x2,0x46,0x2a, + 0x3,0x43,0x64, 0x2,0x4c,0x79, 0x3,0x43,0x68, 0x3,0x43,0x6a, + 0x3,0x43,0x63, 0x1,0x6a,0x37, 0x2,0x4c,0x71, 0x1,0x6e,0x43, + 0x2,0x4c,0x7b, 0x1,0x6a,0x3a, 0x2,0x4d,0x21, 0x1,0x6a,0x40, + 0x2,0x4c,0x6c, 0x3,0x48,0x74, 0x4,0x45,0x7b, 0x2,0x4c,0x7c, + 0x2,0x4c,0x69, 0x3,0x48,0x6d, 0x2,0x4c,0x7e, 0x2,0x4c,0x6d, + 0x3,0x48,0x6e, 0x1,0x6a,0x47, 0x1,0x6a,0x44, 0x2,0x4c,0x7d, + 0x2,0x4c,0x77, 0x1,0x6a,0x36, 0x1,0x6a,0x3e, 0x1,0x6a,0x3d, + 0x3,0x48,0x70, 0x1,0x6a,0x3c, 0x1,0x6a,0x42, 0x3,0x48,0x69, + 0x2,0x4c,0x6a, 0x1,0x6a,0x43, 0x2,0x4c,0x78, 0x1,0x6a,0x3f, + 0x1,0x6a,0x35, 0x2,0x4c,0x7a, 0x1,0x6a,0x38, 0x1,0x6a,0x39, + 0x1,0x6a,0x41, 0x2,0x4c,0x6f, 0x2,0x4c,0x6e, 0x2,0x4c,0x6b, + 0x4,0x45,0x7c, 0x2,0x4c,0x73, 0x2,0x4c,0x70, 0x2,0x4c,0x74, + 0x1,0x6a,0x46, 0x3,0x48,0x68, 0x2,0x4d,0x22, 0x1,0x6a,0x3b, + 0x2,0x4c,0x75, 0x2,0x4c,0x76, 0x3,0x48,0x71, 0x2,0x4c,0x72, + 0x3,0x48,0x73, 0x3,0x66,0x29, 0x3,0x48,0x6b, 0x1,0x6a,0x45, + 0x3,0x66,0x2b, 0x3,0x4e,0x22, 0x2,0x52,0x6f, 0x1,0x6e,0x3b, + 0x1,0x6e,0x44, 0x1,0x6e,0x40, 0x2,0x52,0x6c, 0x3,0x4d,0x7c, + 0x1,0x6e,0x3d, 0x1,0x6e,0x41, 0x2,0x52,0x78, 0x1,0x6e,0x37, + 0x2,0x52,0x70, 0x3,0x4d,0x78, 0x1,0x6e,0x3f, 0x3,0x4e,0x24, + 0x3,0x4e,0x2f, 0x2,0x52,0x73, 0x2,0x52,0x6e, 0x1,0x6e,0x3e, + 0x1,0x6e,0x42, 0x2,0x52,0x6d, 0x3,0x4e,0x2e, 0x1,0x6e,0x3c, + 0x3,0x4d,0x77, 0x2,0x52,0x77, 0x1,0x6e,0x39, 0x2,0x52,0x76, + 0x2,0x52,0x75, 0x1,0x6e,0x45, 0x2,0x50,0x3b, 0x1,0x6e,0x38, + 0x3,0x4e,0x2b, 0x2,0x52,0x74, 0x2,0x52,0x6b, 0x3,0x4d,0x75, + 0x1,0x6e,0x46, 0x2,0x52,0x72, 0x1,0x6e,0x3a, 0x3,0x4e,0x28, + 0x3,0x4e,0x29, 0x3,0x4e,0x25, 0x3,0x4e,0x2c, 0x3,0x4e,0x27, + 0x3,0x4d,0x7e, 0x3,0x4d,0x7d, 0x2,0x52,0x71, 0x4,0x4c,0x45, + 0x3,0x66,0x2a, 0x1,0x71,0x6a, 0x1,0x71,0x6f, 0x1,0x71,0x68, + 0x2,0x59,0x44, 0x2,0x59,0x3b, 0x2,0x59,0x47, 0x2,0x59,0x3f, + 0x2,0x59,0x45, 0x1,0x71,0x70, 0x1,0x71,0x69, 0x2,0x59,0x38, + 0x2,0x59,0x3e, 0x2,0x59,0x48, 0x2,0x59,0x41, 0x2,0x59,0x46, + 0x2,0x59,0x3a, 0x4,0x52,0x4c, 0x3,0x52,0x3b, 0x2,0x59,0x42, + 0x1,0x71,0x6b, 0x2,0x59,0x40, 0x1,0x71,0x6e, 0x1,0x71,0x6d, + 0x2,0x59,0x3c, 0x2,0x59,0x3d, 0x2,0x59,0x39, 0x2,0x59,0x43, + 0x1,0x71,0x6c, 0x2,0x59,0x4a, 0x2,0x59,0x49, 0x3,0x52,0x40, + 0x3,0x52,0x3f, 0x2,0x5e,0x47, 0x2,0x5e,0x43, 0x1,0x74,0x69, + 0x3,0x55,0x79, 0x2,0x5e,0x3d, 0x1,0x74,0x63, 0x1,0x74,0x73, + 0x2,0x5e,0x49, 0x1,0x74,0x6b, 0x1,0x74,0x67, 0x2,0x5e,0x40, + 0x1,0x74,0x6e, 0x1,0x74,0x71, 0x2,0x5e,0x4b, 0x1,0x74,0x66, + 0x2,0x5e,0x42, 0x1,0x74,0x6f, 0x2,0x5e,0x4d, 0x2,0x5e,0x4a, + 0x2,0x5e,0x3e, 0x1,0x74,0x6a, 0x1,0x74,0x64, 0x1,0x74,0x72, + 0x2,0x5e,0x45, 0x1,0x74,0x6d, 0x2,0x5e,0x3f, 0x1,0x74,0x68, + 0x2,0x5e,0x4c, 0x1,0x74,0x6c, 0x1,0x74,0x65, 0x2,0x5e,0x46, + 0x1,0x74,0x70, 0x2,0x5e,0x44, 0x2,0x5e,0x48, 0x3,0x55,0x7a, + 0x4,0x5c,0x5f, 0x3,0x58,0x59, 0x2,0x62,0x5a, 0x2,0x62,0x60, + 0x1,0x77,0x25, 0x2,0x62,0x63, 0x1,0x76,0x7e, 0x1,0x77,0x21, + 0x2,0x62,0x5b, 0x2,0x62,0x62, 0x2,0x62,0x5d, 0x1,0x77,0x26, + 0x1,0x77,0x23, 0x3,0x58,0x5b, 0x2,0x62,0x59, 0x3,0x58,0x58, + 0x1,0x77,0x22, 0x2,0x62,0x5f, 0x2,0x62,0x61, 0x1,0x77,0x24, + 0x2,0x62,0x5e, 0x2,0x62,0x5c, 0x3,0x66,0x2c, 0x4,0x5c,0x5e, + 0x3,0x58,0x5a, 0x2,0x66,0x42, 0x1,0x78,0x62, 0x1,0x78,0x63, + 0x1,0x78,0x5f, 0x3,0x5a,0x72, 0x1,0x78,0x60, 0x3,0x5a,0x74, + 0x2,0x66,0x3e, 0x2,0x66,0x3c, 0x3,0x5a,0x75, 0x2,0x66,0x40, + 0x1,0x78,0x64, 0x2,0x66,0x41, 0x2,0x66,0x3a, 0x2,0x66,0x39, + 0x2,0x66,0x3d, 0x2,0x66,0x3b, 0x1,0x78,0x61, 0x2,0x66,0x3f, + 0x2,0x69,0x59, 0x1,0x7a,0x2b, 0x1,0x7a,0x2a, 0x2,0x69,0x5a, + 0x3,0x5c,0x6c, 0x2,0x69,0x5c, 0x2,0x69,0x5b, 0x1,0x7a,0x2c, + 0x3,0x5e,0x53, 0x3,0x5e,0x50, 0x2,0x6b,0x79, 0x2,0x6b,0x76, + 0x2,0x6b,0x77, 0x3,0x5e,0x51, 0x2,0x6b,0x75, 0x2,0x6b,0x78, + 0x1,0x7a,0x7d, 0x2,0x6b,0x7a, 0x3,0x5e,0x52, 0x1,0x7a,0x7c, + 0x2,0x6d,0x6f, 0x3,0x5f,0x5a, 0x1,0x7c,0x41, 0x1,0x7c,0x43, + 0x2,0x6f,0x3d, 0x1,0x7c,0x42, 0x2,0x70,0x47, 0x2,0x71,0x2f, + 0x2,0x71,0x31, 0x2,0x71,0x2e, 0x2,0x71,0x30, 0x1,0x7d,0x39, + 0x4,0x6d,0x78, 0x3,0x62,0x35, 0x1,0x48,0x4f, 0x4,0x25,0x57, + 0x1,0x52,0x7e, 0x2,0x30,0x52, 0x1,0x57,0x4d, 0x3,0x38,0x31, + 0xf,0x31,0x78, 0x1,0x5c,0x5f, 0x2,0x3f,0x22, 0x2,0x3f,0x23, + 0x3,0x66,0x2d, 0x3,0x48,0x77, 0x2,0x59,0x4b, 0x1,0x74,0x74, + 0x2,0x5e,0x4e, 0x3,0x55,0x7d, 0x3,0x58,0x5c, 0x1,0x77,0x27, + 0x2,0x66,0x44, 0x2,0x66,0x43, 0x1,0x7a,0x2d, 0x2,0x6b,0x7b, + 0x3,0x5f,0x5b, 0x2,0x6d,0x70, 0x1,0x7c,0x64, 0x2,0x22,0x69, + 0x4,0x22,0x21, 0x1,0x4f,0x2c, 0x1,0x4b,0x38, 0xf,0x28,0x4a, + 0x2,0x2c,0x6e, 0x3,0x2a,0x4e, 0x2,0x32,0x24, 0x2,0x31,0x7d, + 0x2,0x32,0x23, 0x2,0x32,0x21, 0x1,0x57,0x4e, 0x2,0x32,0x22, + 0x2,0x31,0x7e, 0x3,0x33,0x3c, 0x2,0x38,0x36, 0x4,0x3a,0x2b, + 0x2,0x3f,0x24, 0x2,0x3f,0x25, 0x2,0x46,0x30, 0x2,0x46,0x31, + 0x1,0x65,0x75, 0x1,0x65,0x76, 0x2,0x46,0x2f, 0x2,0x46,0x32, + 0x2,0x46,0x2e, 0x1,0x65,0x74, 0x3,0x48,0x78, 0x1,0x6a,0x48, + 0x3,0x48,0x79, 0x1,0x65,0x77, 0x2,0x4d,0x23, 0x1,0x6e,0x47, + 0x2,0x52,0x79, 0x1,0x6e,0x48, 0x3,0x4e,0x30, 0x1,0x71,0x71, + 0x2,0x59,0x4e, 0x2,0x59,0x4c, 0x2,0x59,0x4d, 0x2,0x5e,0x51, + 0x2,0x5e,0x50, 0x2,0x5e,0x4f, 0x7,0x41,0x61, 0x4,0x5c,0x68, + 0x2,0x66,0x45, 0x4,0x60,0x6f, 0x1,0x78,0x65, 0x2,0x66,0x46, + 0x2,0x6d,0x71, 0x1,0x7c,0x65, 0x2,0x70,0x48, 0x1,0x48,0x50, + 0x1,0x4f,0x2e, 0x1,0x4f,0x2d, 0x2,0x2c,0x70, 0x1,0x53,0x21, + 0x3,0x2e,0x5d, 0x4,0x2f,0x30, 0x2,0x2c,0x6f, 0x2,0x32,0x26, + 0x3,0x33,0x3d, 0x1,0x57,0x4f, 0x2,0x38,0x37, 0x2,0x32,0x25, + 0x3,0x33,0x3f, 0x4,0x2f,0x2f, 0x3,0x33,0x3e, 0x1,0x5c,0x61, + 0x2,0x38,0x3a, 0x2,0x38,0x38, 0x2,0x38,0x39, 0x1,0x5c,0x60, + 0x2,0x3f,0x27, 0x2,0x3f,0x28, 0x2,0x3f,0x26, 0x3,0x43,0x6e, + 0x1,0x65,0x7a, 0x2,0x46,0x34, 0x2,0x46,0x33, 0x2,0x46,0x35, + 0x1,0x65,0x79, 0x1,0x65,0x78, 0x4,0x46,0x26, 0x2,0x52,0x7a, + 0x2,0x52,0x7c, 0x3,0x4e,0x31, 0x1,0x6e,0x49, 0x2,0x52,0x7b, + 0x2,0x59,0x4f, 0x1,0x71,0x72, 0x2,0x62,0x65, 0x3,0x58,0x5d, + 0x2,0x62,0x64, 0x1,0x78,0x66, 0x2,0x66,0x47, 0x1,0x78,0x68, + 0x1,0x78,0x67, 0x2,0x69,0x5d, 0x2,0x6b,0x7c, 0x1,0x7a,0x7e, + 0x1,0x48,0x51, 0x2,0x2c,0x71, 0x1,0x53,0x22, 0x2,0x32,0x29, + 0x1,0x57,0x51, 0x2,0x32,0x28, 0x2,0x32,0x27, 0x3,0x33,0x42, + 0x1,0x57,0x50, 0x3,0x33,0x43, 0x2,0x38,0x40, 0x4,0x34,0x3d, + 0x2,0x38,0x42, 0x2,0x38,0x3b, 0x2,0x38,0x3c, 0x1,0x5c,0x62, + 0x2,0x38,0x3d, 0x1,0x5c,0x63, 0x2,0x38,0x41, 0x2,0x38,0x3e, + 0x2,0x38,0x3f, 0x1,0x5c,0x64, 0x3,0x3e,0x37, 0x1,0x61,0x44, + 0x1,0x61,0x45, 0x3,0x3e,0x38, 0x2,0x3f,0x29, 0x2,0x46,0x36, + 0x2,0x46,0x37, 0x3,0x43,0x72, 0x2,0x4d,0x27, 0x1,0x6a,0x4b, + 0x1,0x6a,0x49, 0x1,0x6a,0x4a, 0x2,0x4d,0x24, 0x2,0x4d,0x25, + 0x6,0x60,0x58, 0x2,0x4d,0x26, 0x2,0x53,0x23, 0x3,0x4e,0x32, + 0x2,0x53,0x24, 0x1,0x6e,0x4a, 0x2,0x53,0x21, 0x2,0x52,0x7e, + 0x2,0x53,0x22, 0x2,0x52,0x7d, 0x1,0x71,0x75, 0x2,0x59,0x50, + 0x1,0x71,0x73, 0x1,0x71,0x74, 0x2,0x5e,0x53, 0x1,0x74,0x75, + 0x2,0x5e,0x52, 0x2,0x61,0x34, 0x3,0x55,0x7e, 0x2,0x62,0x66, + 0x2,0x62,0x67, 0x1,0x77,0x28, 0x3,0x58,0x61, 0x1,0x77,0x29, + 0x1,0x74,0x76, 0x2,0x66,0x48, 0x2,0x66,0x49, 0x2,0x69,0x5e, + 0x1,0x7a,0x2e, 0x1,0x48,0x52, 0x3,0x66,0x7b, 0x1,0x48,0x53, + 0x1,0x57,0x53, 0x1,0x4f,0x2f, 0x1,0x57,0x52, 0x2,0x2c,0x72, + 0x3,0x38,0x36, 0x4,0x2b,0x25, 0x3,0x33,0x44, 0x1,0x61,0x46, + 0x1,0x48,0x54, 0x1,0x53,0x24, 0x2,0x2c,0x73, 0x2,0x2c,0x74, + 0x1,0x53,0x23, 0x1,0x53,0x25, 0x1,0x48,0x55, 0x4,0x27,0x61, + 0x2,0x2c,0x75, 0x1,0x57,0x55, 0x2,0x32,0x2a, 0x1,0x57,0x57, + 0x1,0x57,0x54, 0x1,0x57,0x56, 0x3,0x38,0x37, 0x2,0x38,0x45, + 0x1,0x5c,0x65, 0x3,0x38,0x39, 0x2,0x38,0x44, 0x2,0x38,0x43, + 0x4,0x3a,0x38, 0x2,0x46,0x38, 0x3,0x49,0x22, 0x2,0x4d,0x28, + 0x4,0x46,0x2c, 0x1,0x6e,0x4b, 0x1,0x71,0x76, 0x2,0x59,0x52, + 0x2,0x59,0x51, 0x3,0x56,0x21, 0x2,0x5e,0x54, 0x4,0x5c,0x71, + 0x3,0x58,0x62, 0x3,0x5c,0x6f, 0x2,0x6b,0x7d, 0x4,0x69,0x2e, + 0x4,0x69,0x2d, 0x1,0x48,0x56, 0x2,0x24,0x73, 0x2,0x28,0x4a, + 0x1,0x53,0x26, 0x2,0x2c,0x76, 0x6,0x3b,0x21, 0x2,0x32,0x2c, + 0x4,0x2f,0x3a, 0x3,0x33,0x49, 0x3,0x33,0x48, 0x1,0x57,0x58, + 0x2,0x32,0x2b, 0x1,0x57,0x59, 0x3,0x33,0x47, 0x3,0x66,0x2f, + 0x2,0x38,0x47, 0x3,0x38,0x3d, 0x3,0x38,0x3c, 0x1,0x5c,0x67, + 0x2,0x38,0x46, 0x2,0x38,0x48, 0x3,0x38,0x3b, 0x1,0x5c,0x66, + 0x3,0x3e,0x3c, 0x2,0x3f,0x2b, 0x2,0x3f,0x2c, 0x2,0x3f,0x2a, + 0x1,0x61,0x47, 0x3,0x67,0x29, 0x4,0x3f,0x7c, 0x1,0x65,0x7b, + 0x3,0x43,0x73, 0x1,0x65,0x7c, 0x4,0x46,0x33, 0x1,0x6a,0x4d, + 0x3,0x49,0x23, 0x2,0x4d,0x2a, 0x2,0x4d,0x29, 0x1,0x6a,0x4c, + 0x3,0x49,0x26, 0x3,0x3e,0x3b, 0x3,0x49,0x25, 0x3,0x66,0x30, + 0x2,0x53,0x25, 0x3,0x4e,0x34, 0x3,0x4e,0x36, 0x2,0x53,0x26, + 0x3,0x4e,0x37, 0x3,0x4e,0x35, 0x3,0x4e,0x38, 0x2,0x59,0x53, + 0x4,0x52,0x5c, 0x3,0x52,0x43, 0x1,0x74,0x7a, 0x1,0x74,0x79, + 0x1,0x74,0x77, 0x1,0x74,0x78, 0x1,0x74,0x7b, 0x3,0x56,0x22, + 0x2,0x62,0x68, 0x1,0x77,0x2b, 0x1,0x77,0x2a, 0x2,0x66,0x4a, + 0x2,0x69,0x5f, 0x3,0x5c,0x70, 0x3,0x5c,0x71, 0x3,0x5c,0x72, + 0x1,0x7b,0x6f, 0x1,0x7b,0x6e, 0x1,0x48,0x57, 0x6,0x3b,0x24, + 0x2,0x2f,0x7d, 0x1,0x65,0x7e, 0x1,0x61,0x48, 0x1,0x65,0x7d, + 0x1,0x6a,0x4e, 0x6,0x60,0x60, 0x1,0x48,0x58, 0x2,0x21,0x68, + 0x1,0x48,0x59, 0x1,0x48,0x5a, 0x3,0x24,0x35, 0x3,0x24,0x36, + 0x2,0x28,0x4b, 0x2,0x24,0x76, 0x3,0x27,0x24, 0x2,0x24,0x77, + 0x1,0x4b,0x3a, 0x3,0x27,0x26, 0x2,0x24,0x74, 0x1,0x4b,0x39, + 0x3,0x27,0x25, 0x1,0x4b,0x3c, 0x2,0x24,0x75, 0x1,0x4b,0x3e, + 0x1,0x4b,0x3d, 0x2,0x24,0x78, 0x1,0x4b,0x3b, 0x4,0x24,0x70, + 0x3,0x27,0x23, 0x1,0x4f,0x34, 0x1,0x4f,0x32, 0x2,0x28,0x4d, + 0x3,0x2a,0x56, 0x1,0x4f,0x31, 0x3,0x2a,0x5b, 0x3,0x2a,0x58, + 0x3,0x2a,0x4f, 0x1,0x4f,0x36, 0x1,0x4f,0x38, 0x1,0x4f,0x35, + 0x3,0x2a,0x59, 0x2,0x28,0x50, 0x2,0x28,0x4c, 0x1,0x4f,0x39, + 0x3,0x2a,0x52, 0x1,0x4f,0x33, 0x1,0x4b,0x3f, 0x3,0x2a,0x54, + 0x1,0x4f,0x37, 0x2,0x28,0x4f, 0x3,0x2a,0x57, 0x4,0x27,0x64, + 0x2,0x28,0x4e, 0x4,0x27,0x69, 0x1,0x4f,0x30, 0x3,0x66,0x31, + 0x2,0x2c,0x7c, 0x1,0x53,0x2a, 0x1,0x53,0x2b, 0x2,0x2c,0x7e, + 0x3,0x2e,0x66, 0x2,0x2c,0x78, 0x2,0x2c,0x7b, 0x2,0x2d,0x26, + 0x2,0x2d,0x24, 0x3,0x2e,0x60, 0x1,0x53,0x2c, 0x2,0x2d,0x2a, + 0x1,0x53,0x2f, 0x2,0x2d,0x27, 0x2,0x2c,0x7d, 0x2,0x2c,0x7a, + 0x3,0x2e,0x61, 0x3,0x2e,0x5e, 0x2,0x3f,0x2e, 0x2,0x2d,0x25, + 0x1,0x53,0x27, 0x2,0x2d,0x28, 0x2,0x2c,0x77, 0x2,0x2d,0x22, + 0x1,0x53,0x29, 0x1,0x53,0x2e, 0x2,0x2d,0x23, 0x1,0x53,0x32, + 0x1,0x53,0x30, 0x3,0x2e,0x65, 0x2,0x2c,0x79, 0x1,0x53,0x2d, + 0x3,0x2e,0x64, 0x2,0x2d,0x21, 0x1,0x53,0x31, 0x1,0x53,0x28, + 0x2,0x2d,0x29, 0x1,0x57,0x5e, 0x3,0x33,0x4c, 0x1,0x57,0x67, + 0x1,0x57,0x5c, 0x1,0x57,0x5a, 0x2,0x32,0x2e, 0x1,0x57,0x62, + 0x1,0x57,0x5f, 0x2,0x32,0x30, 0x3,0x33,0x4a, 0x3,0x33,0x52, + 0x1,0x57,0x61, 0x2,0x32,0x2f, 0x2,0x32,0x2d, 0x2,0x32,0x32, + 0x1,0x57,0x66, 0x1,0x57,0x64, 0x2,0x3f,0x2d, 0x3,0x33,0x4b, + 0x2,0x32,0x33, 0x2,0x32,0x31, 0x1,0x57,0x5b, 0x3,0x33,0x4e, + 0x3,0x33,0x4d, 0x1,0x57,0x5d, 0x1,0x57,0x60, 0x3,0x33,0x4f, + 0x1,0x57,0x63, 0x3,0x2e,0x63, 0x1,0x57,0x65, 0x3,0x3e,0x44, + 0x2,0x38,0x52, 0x1,0x5c,0x69, 0x3,0x38,0x49, 0x2,0x38,0x49, + 0x2,0x38,0x4b, 0x3,0x38,0x47, 0x2,0x38,0x4c, 0x4,0x34,0x4d, + 0x2,0x38,0x54, 0x2,0x38,0x50, 0x2,0x38,0x4e, 0x4,0x3a,0x3b, + 0x2,0x38,0x51, 0x2,0x38,0x55, 0x1,0x5c,0x6a, 0x1,0x5c,0x6e, + 0x2,0x38,0x4a, 0x4,0x34,0x47, 0x2,0x38,0x53, 0x4,0x34,0x50, + 0x1,0x5c,0x6c, 0x3,0x38,0x41, 0x1,0x5c,0x6b, 0x2,0x38,0x4f, + 0x2,0x38,0x4d, 0x3,0x38,0x42, 0x1,0x5c,0x68, 0x1,0x5c,0x6d, + 0x3,0x38,0x45, 0x3,0x38,0x48, 0x1,0x61,0x4e, 0x2,0x3f,0x36, + 0x3,0x3e,0x3e, 0x4,0x3a,0x3e, 0x2,0x3f,0x34, 0x1,0x61,0x50, + 0x4,0x3a,0x47, 0x3,0x3e,0x43, 0x3,0x3e,0x45, 0x3,0x3e,0x41, + 0x2,0x3f,0x2f, 0x2,0x46,0x46, 0x3,0x3e,0x3d, 0x1,0x61,0x4f, + 0x2,0x3f,0x33, 0x3,0x3e,0x40, 0x3,0x3e,0x42, 0x2,0x3f,0x30, + 0x1,0x61,0x4b, 0x1,0x61,0x51, 0x2,0x3f,0x35, 0x1,0x61,0x4d, + 0x2,0x3f,0x32, 0x1,0x6a,0x4f, 0x1,0x61,0x4c, 0x2,0x3f,0x31, + 0x1,0x61,0x52, 0x1,0x61,0x4a, 0x1,0x61,0x49, 0x6,0x43,0x5a, + 0x2,0x46,0x3e, 0x2,0x46,0x3c, 0x3,0x43,0x7b, 0x2,0x46,0x42, + 0x3,0x43,0x7e, 0x2,0x46,0x3a, 0x2,0x46,0x47, 0x2,0x46,0x3f, + 0x3,0x43,0x75, 0x2,0x46,0x39, 0x1,0x66,0x24, 0x1,0x66,0x2a, + 0x2,0x46,0x44, 0x4,0x40,0x29, 0x2,0x46,0x3d, 0x3,0x43,0x76, + 0x1,0x66,0x27, 0x3,0x43,0x77, 0x3,0x44,0x23, 0x1,0x66,0x25, + 0x2,0x46,0x45, 0x1,0x66,0x22, 0x1,0x66,0x21, 0x2,0x46,0x40, + 0x1,0x66,0x26, 0x1,0x61,0x53, 0x3,0x43,0x7c, 0x2,0x46,0x43, + 0x2,0x46,0x3b, 0x1,0x66,0x23, 0x1,0x66,0x28, 0x1,0x66,0x29, + 0x3,0x44,0x22, 0x1,0x6a,0x54, 0x1,0x6a,0x50, 0x3,0x49,0x27, + 0x1,0x6a,0x55, 0x2,0x4d,0x2d, 0x3,0x49,0x2a, 0x4,0x46,0x39, + 0x2,0x4d,0x2c, 0x2,0x4d,0x2e, 0x1,0x6a,0x52, 0x2,0x4d,0x2b, + 0x1,0x6a,0x53, 0x2,0x4d,0x31, 0x2,0x4d,0x30, 0x2,0x4d,0x2f, + 0x4,0x46,0x46, 0x1,0x6a,0x51, 0x4,0x52,0x67, 0x3,0x4e,0x3b, + 0x3,0x4e,0x3d, 0x3,0x4e,0x39, 0x2,0x53,0x2a, 0x3,0x4e,0x3c, + 0x2,0x53,0x2d, 0x1,0x6e,0x51, 0x2,0x53,0x2c, 0x1,0x6e,0x50, + 0x1,0x6e,0x4c, 0x1,0x6e,0x4d, 0x1,0x6e,0x4e, 0x2,0x53,0x29, + 0x2,0x53,0x28, 0x1,0x6e,0x4f, 0x3,0x4e,0x3a, 0x2,0x53,0x2b, + 0x2,0x53,0x27, 0x2,0x59,0x55, 0x2,0x59,0x5f, 0x1,0x71,0x79, + 0x1,0x71,0x78, 0x3,0x52,0x49, 0x2,0x59,0x59, 0x2,0x59,0x5b, + 0x3,0x52,0x47, 0x2,0x59,0x56, 0x3,0x52,0x44, 0x2,0x59,0x5a, + 0x2,0x59,0x54, 0x2,0x59,0x5d, 0x1,0x71,0x77, 0x2,0x59,0x5c, + 0x2,0x59,0x58, 0x2,0x59,0x5e, 0x3,0x56,0x23, 0x2,0x59,0x57, + 0x1,0x74,0x7e, 0x2,0x5e,0x55, 0x2,0x5e,0x5b, 0x1,0x75,0x24, + 0x1,0x75,0x26, 0x1,0x75,0x23, 0x1,0x75,0x22, 0x4,0x58,0x27, + 0x1,0x75,0x21, 0x1,0x74,0x7d, 0x2,0x5e,0x56, 0x2,0x5e,0x59, + 0x1,0x74,0x7c, 0x2,0x5e,0x5a, 0x3,0x56,0x24, 0x1,0x75,0x25, + 0x2,0x5e,0x58, 0x7,0x48,0x7c, 0x2,0x5e,0x57, 0x1,0x77,0x2c, + 0x3,0x58,0x65, 0x1,0x77,0x2d, 0x2,0x62,0x6b, 0x2,0x62,0x69, + 0x2,0x62,0x6a, 0x3,0x5a,0x77, 0x2,0x66,0x4c, 0x3,0x5a,0x78, + 0x2,0x66,0x4b, 0x1,0x78,0x69, 0x2,0x69,0x61, 0x1,0x7a,0x2f, + 0x2,0x69,0x60, 0x2,0x6b,0x7e, 0x2,0x6d,0x72, 0x1,0x7b,0x70, + 0x2,0x71,0x32, 0x2,0x71,0x33, 0x1,0x7c,0x44, 0x1,0x48,0x5b, + 0x4,0x27,0x6c, 0x1,0x4f,0x3a, 0x2,0x3f,0x37, 0x1,0x6a,0x56, + 0x1,0x75,0x27, 0x2,0x5e,0x5c, 0x1,0x48,0x5c, 0x4,0x24,0x73, + 0x1,0x57,0x69, 0x1,0x57,0x68, 0x2,0x3f,0x38, 0x3,0x3e,0x47, + 0x4,0x3a,0x4c, 0x4,0x4c,0x62, 0x2,0x59,0x60, 0x1,0x48,0x5d, + 0x1,0x53,0x33, 0x4,0x3a,0x4d, 0x3,0x3e,0x48, 0x2,0x3f,0x39, + 0x2,0x3f,0x3a, 0x2,0x3f,0x3b, 0x1,0x6a,0x57, 0x1,0x71,0x7a, + 0x1,0x48,0x5e, 0x4,0x27,0x6d, 0x1,0x4f,0x3b, 0x2,0x2d,0x2b, + 0x1,0x57,0x6a, 0x2,0x32,0x34, 0x1,0x5c,0x6f, 0x3,0x3e,0x49, + 0x2,0x3f,0x3c, 0x1,0x66,0x2b, 0x1,0x6a,0x58, 0x1,0x71,0x7b, + 0x1,0x75,0x28, 0x1,0x77,0x2e, 0x2,0x66,0x4d, 0x1,0x48,0x5f, + 0x1,0x4f,0x3c, 0x3,0x2a,0x5d, 0x4,0x27,0x6e, 0x1,0x57,0x6b, + 0x2,0x38,0x56, 0x1,0x61,0x54, 0x3,0x49,0x2b, 0x1,0x6a,0x59, + 0x2,0x4d,0x32, 0x2,0x53,0x2e, 0x3,0x52,0x4a, 0x3,0x58,0x68, + 0x3,0x5a,0x79, 0x1,0x48,0x60, 0x1,0x61,0x55, 0x2,0x46,0x48, + 0x1,0x6a,0x5a, 0x1,0x48,0x61, 0x2,0x28,0x51, 0x2,0x2d,0x2c, + 0x1,0x53,0x34, 0x3,0x2e,0x68, 0x2,0x32,0x36, 0x4,0x2f,0x4f, + 0x3,0x33,0x57, 0x1,0x57,0x6e, 0x3,0x33,0x58, 0x1,0x57,0x6c, + 0x1,0x57,0x6d, 0x1,0x57,0x6f, 0x3,0x33,0x55, 0x2,0x32,0x35, + 0x2,0x38,0x5b, 0x2,0x38,0x58, 0x2,0x38,0x5a, 0x1,0x5c,0x70, + 0x1,0x5c,0x72, 0x1,0x5c,0x71, 0x2,0x38,0x57, 0x1,0x5c,0x73, + 0x2,0x38,0x59, 0x2,0x3f,0x3d, 0x2,0x3f,0x3e, 0x2,0x3f,0x3f, + 0x2,0x46,0x4b, 0x3,0x44,0x26, 0x2,0x46,0x4c, 0x4,0x40,0x2e, + 0x2,0x46,0x4a, 0x2,0x46,0x4d, 0x4,0x40,0x2d, 0x1,0x66,0x2c, + 0x3,0x66,0x34, 0x2,0x46,0x49, 0x3,0x49,0x2d, 0x1,0x6a,0x5b, + 0x3,0x49,0x2e, 0x2,0x53,0x33, 0x2,0x53,0x2f, 0x2,0x53,0x32, + 0x2,0x53,0x34, 0x2,0x53,0x31, 0x2,0x53,0x30, 0x2,0x59,0x61, + 0x2,0x59,0x62, 0x2,0x59,0x63, 0x1,0x71,0x7c, 0x1,0x71,0x7d, + 0x2,0x5e,0x5e, 0x2,0x5e,0x5d, 0x2,0x5e,0x5f, 0x2,0x62,0x6d, + 0x2,0x62,0x6c, 0x2,0x66,0x4f, 0x3,0x5a,0x7a, 0x2,0x66,0x50, + 0x2,0x66,0x4e, 0x3,0x5a,0x7b, 0x1,0x7a,0x30, 0x4,0x64,0x2c, + 0x2,0x69,0x62, 0x2,0x69,0x63, 0x3,0x5e,0x55, 0x2,0x6d,0x73, + 0x2,0x6f,0x3e, 0x2,0x70,0x49, 0x1,0x48,0x62, 0x1,0x4b,0x40, + 0x1,0x75,0x29, 0x1,0x48,0x63, 0xf,0x32,0x32, 0x2,0x38,0x5c, + 0x2,0x3f,0x40, 0x3,0x5a,0x7c, 0x1,0x7c,0x6c, 0x2,0x22,0x6a, + 0x4,0x21,0x53, 0x3,0x24,0x38, 0x2,0x22,0x6b, 0x2,0x22,0x6d, + 0x1,0x48,0x64, 0x2,0x22,0x6e, 0x2,0x22,0x6c, 0x4,0x23,0x2f, + 0x2,0x25,0x22, 0x2,0x25,0x23, 0x2,0x24,0x7b, 0x3,0x27,0x28, + 0x4,0x24,0x7b, 0x4,0x24,0x75, 0x2,0x25,0x21, 0x1,0x4b,0x42, + 0x3,0x27,0x29, 0x1,0x4b,0x43, 0x2,0x24,0x7c, 0x2,0x24,0x7a, + 0x2,0x24,0x79, 0x2,0x24,0x7d, 0x1,0x4b,0x41, 0x2,0x24,0x7e, + 0x2,0x2d,0x2d, 0x3,0x27,0x2b, 0x4,0x24,0x79, 0x2,0x28,0x56, + 0x1,0x4f,0x3f, 0x2,0x28,0x55, 0x2,0x28,0x57, 0x3,0x2a,0x60, + 0x1,0x4f,0x3e, 0x2,0x28,0x5c, 0x1,0x4f,0x42, 0x2,0x28,0x52, + 0x2,0x28,0x60, 0x2,0x28,0x66, 0x1,0x4f,0x49, 0x2,0x28,0x63, + 0x1,0x4f,0x46, 0x3,0x2a,0x6b, 0x2,0x28,0x59, 0x2,0x28,0x5f, + 0x2,0x28,0x61, 0x3,0x2a,0x66, 0x2,0x28,0x54, 0x1,0x4f,0x45, + 0x1,0x4f,0x40, 0x2,0x28,0x5a, 0x1,0x4f,0x47, 0x1,0x4f,0x4a, + 0x1,0x4f,0x44, 0x3,0x2a,0x6c, 0x1,0x4f,0x3d, 0x2,0x28,0x5e, + 0x2,0x28,0x58, 0x2,0x28,0x65, 0x1,0x4f,0x4c, 0x1,0x4f,0x48, + 0x1,0x4f,0x43, 0x2,0x28,0x5d, 0x1,0x57,0x70, 0x2,0x28,0x5b, + 0x1,0x4f,0x41, 0x1,0x4f,0x4b, 0x4,0x27,0x7a, 0x2,0x28,0x53, + 0x4,0x27,0x7e, 0x2,0x28,0x62, 0x2,0x28,0x64, 0x3,0x2a,0x5e, + 0xf,0x28,0x63, 0x3,0x2a,0x68, 0x4,0x27,0x7b, 0x3,0x2e,0x76, + 0x1,0x53,0x45, 0x1,0x53,0x3f, 0x1,0x53,0x47, 0x1,0x53,0x44, + 0x2,0x2d,0x34, 0x2,0x2d,0x37, 0x1,0x53,0x40, 0x3,0x2e,0x6a, + 0x2,0x2d,0x2e, 0x4,0x2b,0x3a, 0x1,0x53,0x39, 0x1,0x53,0x43, + 0x3,0x2e,0x6b, 0x1,0x53,0x46, 0x1,0x53,0x48, 0x2,0x2d,0x43, + 0x2,0x2d,0x3a, 0x3,0x2e,0x78, 0x1,0x53,0x38, 0x2,0x2d,0x42, + 0x1,0x53,0x3c, 0x1,0x53,0x3a, 0x1,0x53,0x35, 0x2,0x2d,0x32, + 0x3,0x2e,0x72, 0x2,0x2d,0x41, 0x2,0x2d,0x36, 0x2,0x2d,0x39, + 0x2,0x2d,0x46, 0x3,0x2e,0x74, 0x1,0x53,0x49, 0x2,0x2d,0x40, + 0x1,0x53,0x41, 0x2,0x2d,0x3b, 0x2,0x2d,0x45, 0x2,0x2d,0x38, + 0x2,0x2d,0x3c, 0x2,0x2d,0x3f, 0x3,0x2e,0x69, 0x3,0x2e,0x6e, + 0x2,0x2d,0x30, 0x2,0x2d,0x44, 0x2,0x2d,0x3e, 0x3,0x2e,0x6f, + 0x3,0x2e,0x7a, 0x2,0x2d,0x2f, 0x6,0x34,0x3c, 0x2,0x2d,0x33, + 0x1,0x53,0x42, 0x1,0x53,0x3d, 0x1,0x53,0x36, 0x1,0x53,0x3b, + 0x1,0x53,0x37, 0x1,0x53,0x4a, 0x2,0x2d,0x31, 0x2,0x32,0x47, + 0x1,0x53,0x3e, 0x4,0x2b,0x3d, 0x3,0x2e,0x79, 0x2,0x2d,0x3d, + 0x2,0x29,0x42, 0x3,0x2e,0x77, 0x3,0x66,0x35, 0x3,0x66,0x37, + 0x2,0x32,0x4a, 0x1,0x57,0x7e, 0x3,0x33,0x62, 0x2,0x32,0x3a, + 0x4,0x2f,0x5d, 0x2,0x32,0x45, 0x2,0x32,0x41, 0x3,0x38,0x4d, + 0x2,0x32,0x54, 0x3,0x33,0x59, 0x2,0x32,0x4c, 0x3,0x33,0x5f, + 0x2,0x32,0x42, 0x3,0x38,0x5b, 0x2,0x32,0x4b, 0x2,0x32,0x3c, + 0x2,0x32,0x40, 0x2,0x32,0x57, 0x1,0x58,0x23, 0x2,0x32,0x4f, + 0x2,0x32,0x46, 0x1,0x57,0x71, 0x2,0x32,0x55, 0x2,0x32,0x38, + 0x4,0x2f,0x5a, 0x2,0x32,0x4e, 0x4,0x2f,0x63, 0x1,0x58,0x22, + 0x1,0x57,0x7b, 0x2,0x32,0x37, 0x1,0x57,0x79, 0x1,0x57,0x78, + 0x1,0x57,0x7d, 0x2,0x32,0x4d, 0x1,0x57,0x75, 0x1,0x57,0x7c, + 0x2,0x2d,0x35, 0x2,0x3f,0x41, 0x2,0x32,0x48, 0x4,0x2f,0x5f, + 0x3,0x2a,0x5f, 0x2,0x32,0x3e, 0x1,0x58,0x21, 0x2,0x32,0x3f, + 0x2,0x32,0x43, 0x1,0x58,0x24, 0x2,0x32,0x39, 0x2,0x32,0x51, + 0x3,0x3e,0x57, 0x2,0x32,0x50, 0x2,0x32,0x58, 0x1,0x57,0x77, + 0x1,0x57,0x74, 0x2,0x32,0x56, 0x2,0x32,0x52, 0x2,0x32,0x49, + 0x2,0x32,0x44, 0x1,0x57,0x7a, 0x1,0x57,0x76, 0x2,0x32,0x3b, + 0x1,0x57,0x72, 0x2,0x32,0x53, 0x1,0x57,0x73, 0x4,0x2f,0x5c, + 0x2,0x32,0x3d, 0x3,0x33,0x5a, 0x3,0x33,0x63, 0x3,0x66,0x36, + 0x3,0x2d,0x33, 0x4,0x34,0x67, 0x3,0x38,0x4e, 0x3,0x38,0x51, + 0x2,0x38,0x62, 0x2,0x38,0x64, 0x2,0x38,0x69, 0x2,0x38,0x7d, + 0x1,0x5d,0x23, 0x1,0x5c,0x77, 0x3,0x38,0x54, 0x2,0x38,0x61, + 0x1,0x5d,0x24, 0x1,0x5d,0x25, 0x2,0x38,0x6c, 0x2,0x38,0x73, + 0x2,0x38,0x79, 0x3,0x38,0x50, 0x2,0x38,0x66, 0x4,0x34,0x6d, + 0x2,0x38,0x6d, 0x3,0x38,0x4f, 0x3,0x38,0x5d, 0x1,0x5d,0x26, + 0x2,0x38,0x7b, 0x2,0x38,0x76, 0x1,0x5d,0x21, 0x1,0x5c,0x7d, + 0x2,0x38,0x72, 0x2,0x38,0x6e, 0x2,0x38,0x60, 0x1,0x5c,0x74, + 0x2,0x38,0x65, 0x2,0x38,0x5d, 0x3,0x38,0x55, 0x1,0x5c,0x7c, + 0x1,0x5c,0x7e, 0x2,0x38,0x6a, 0x2,0x38,0x67, 0x1,0x5c,0x79, + 0x2,0x38,0x77, 0x1,0x5c,0x76, 0x2,0x38,0x68, 0x2,0x3f,0x6a, + 0x2,0x38,0x70, 0x3,0x38,0x5e, 0x2,0x38,0x6f, 0x1,0x5c,0x75, + 0x3,0x38,0x57, 0x1,0x5d,0x22, 0x3,0x38,0x52, 0x1,0x5c,0x78, + 0x2,0x38,0x5e, 0x2,0x38,0x63, 0x2,0x38,0x74, 0x2,0x38,0x7a, + 0x1,0x5d,0x27, 0x2,0x38,0x5f, 0x2,0x38,0x6b, 0x2,0x38,0x71, + 0x1,0x5c,0x7b, 0x4,0x34,0x6f, 0x3,0x38,0x58, 0x2,0x38,0x7c, + 0x2,0x38,0x75, 0x2,0x38,0x78, 0x3,0x38,0x5f, 0xf,0x37,0x78, + 0x1,0x5c,0x7a, 0x4,0x3a,0x68, 0x2,0x3f,0x51, 0x2,0x3f,0x45, + 0x1,0x61,0x5d, 0x2,0x3f,0x62, 0x2,0x3f,0x6b, 0x2,0x3f,0x6e, + 0x1,0x61,0x5b, 0x2,0x3f,0x4d, 0x2,0x3f,0x66, 0x2,0x3f,0x4e, + 0x2,0x3f,0x5c, 0x1,0x61,0x68, 0x2,0x3f,0x58, 0x1,0x61,0x65, + 0x3,0x3e,0x5e, 0x2,0x3f,0x59, 0x2,0x3f,0x42, 0x5,0x3b,0x6f, + 0x2,0x3f,0x67, 0x3,0x3e,0x4f, 0x3,0x3e,0x59, 0x1,0x61,0x6e, + 0x2,0x3f,0x64, 0x2,0x3f,0x5a, 0x2,0x3f,0x70, 0x2,0x3f,0x55, + 0x2,0x46,0x6d, 0x3,0x3e,0x4d, 0x2,0x3f,0x73, 0x1,0x61,0x6c, + 0x2,0x3f,0x53, 0x2,0x3f,0x5f, 0x1,0x61,0x6f, 0x1,0x61,0x5a, + 0x2,0x3f,0x57, 0x2,0x3f,0x71, 0x2,0x3f,0x50, 0x2,0x3f,0x49, + 0x2,0x3f,0x54, 0x3,0x3e,0x5f, 0x2,0x3f,0x48, 0x2,0x3f,0x46, + 0x1,0x61,0x56, 0x2,0x3f,0x68, 0x2,0x3f,0x4f, 0x2,0x3f,0x6c, + 0x3,0x3e,0x4b, 0x2,0x3f,0x6d, 0x1,0x61,0x5e, 0x1,0x61,0x63, + 0x1,0x61,0x5f, 0x1,0x61,0x67, 0x2,0x3f,0x63, 0x1,0x61,0x60, + 0x2,0x3f,0x5b, 0x2,0x3f,0x4b, 0xf,0x3e,0x66, 0x1,0x61,0x58, + 0x2,0x3f,0x43, 0x2,0x3f,0x65, 0x2,0x3f,0x6f, 0x2,0x3f,0x4a, + 0x1,0x61,0x66, 0x2,0x3f,0x74, 0x2,0x3f,0x56, 0x3,0x3e,0x52, + 0x2,0x3f,0x52, 0x3,0x3e,0x5c, 0x1,0x61,0x57, 0x1,0x61,0x6b, + 0x3,0x3e,0x5a, 0x2,0x3f,0x61, 0x1,0x61,0x6d, 0x3,0x3e,0x50, + 0x2,0x3f,0x5d, 0x1,0x61,0x62, 0x1,0x61,0x5c, 0x1,0x61,0x64, + 0x1,0x61,0x59, 0x1,0x61,0x6a, 0x2,0x3f,0x5e, 0x2,0x3f,0x4c, + 0x2,0x3f,0x60, 0x2,0x3f,0x47, 0x2,0x3f,0x69, 0x3,0x3e,0x58, + 0x4,0x3a,0x67, 0x3,0x3e,0x5d, 0x3,0x3e,0x56, 0x3,0x3e,0x4e, + 0x2,0x3f,0x72, 0x3,0x66,0x39, 0x3,0x3e,0x5b, 0x3,0x66,0x38, + 0x2,0x3f,0x44, 0x2,0x46,0x6c, 0x3,0x44,0x2d, 0x2,0x47,0x24, + 0x1,0x65,0x5c, 0x2,0x46,0x71, 0x3,0x44,0x31, 0x2,0x46,0x6f, + 0x2,0x46,0x5a, 0x1,0x66,0x30, 0x2,0x46,0x6a, 0x2,0x46,0x7e, + 0x2,0x46,0x66, 0x1,0x66,0x38, 0x2,0x46,0x7d, 0x2,0x46,0x64, + 0x1,0x61,0x69, 0x2,0x46,0x74, 0x2,0x46,0x65, 0x2,0x46,0x7b, + 0x1,0x66,0x37, 0x1,0x66,0x2f, 0x3,0x44,0x3a, 0x2,0x46,0x4f, + 0x2,0x46,0x57, 0x3,0x44,0x35, 0x2,0x46,0x70, 0x2,0x46,0x68, + 0x2,0x47,0x23, 0x2,0x46,0x6b, 0x1,0x66,0x3d, 0x2,0x46,0x7c, + 0x3,0x44,0x2c, 0x1,0x66,0x34, 0x3,0x44,0x3e, 0x2,0x46,0x6e, + 0x2,0x46,0x76, 0x2,0x46,0x5b, 0x2,0x46,0x75, 0x3,0x44,0x27, + 0x2,0x47,0x28, 0x2,0x46,0x56, 0x2,0x46,0x77, 0x3,0x44,0x33, + 0x2,0x47,0x26, 0x3,0x44,0x3f, 0x2,0x46,0x50, 0x1,0x61,0x61, + 0x3,0x44,0x40, 0x2,0x46,0x5e, 0x2,0x46,0x5d, 0x1,0x66,0x36, + 0x3,0x44,0x32, 0x2,0x46,0x61, 0x2,0x46,0x63, 0x2,0x46,0x72, + 0x2,0x47,0x25, 0x1,0x66,0x39, 0x3,0x44,0x38, 0x1,0x66,0x3a, + 0x3,0x44,0x30, 0x2,0x46,0x55, 0x1,0x66,0x32, 0x2,0x46,0x59, + 0x2,0x47,0x21, 0x1,0x66,0x3b, 0x4,0x40,0x44, 0x1,0x66,0x33, + 0x1,0x66,0x35, 0x1,0x66,0x3c, 0x2,0x47,0x27, 0x2,0x46,0x78, + 0x2,0x46,0x73, 0x3,0x44,0x3c, 0x3,0x44,0x2f, 0x2,0x46,0x60, + 0x2,0x46,0x5f, 0x1,0x66,0x31, 0x2,0x46,0x51, 0x1,0x66,0x2e, + 0x2,0x46,0x69, 0x2,0x46,0x52, 0x2,0x46,0x67, 0x3,0x44,0x2e, + 0x4,0x40,0x41, 0x2,0x46,0x5c, 0x2,0x47,0x22, 0x3,0x44,0x2a, + 0x3,0x44,0x39, 0x4,0x40,0x36, 0x1,0x66,0x2d, 0x3,0x44,0x3b, + 0x3,0x44,0x28, 0x2,0x46,0x58, 0x4,0x40,0x46, 0x2,0x46,0x54, + 0x2,0x46,0x7a, 0x2,0x46,0x53, 0x1,0x6a,0x68, 0x2,0x4d,0x5a, + 0x3,0x49,0x35, 0x3,0x49,0x44, 0x2,0x4d,0x49, 0x3,0x49,0x33, + 0x3,0x49,0x38, 0x2,0x4d,0x33, 0x2,0x4d,0x51, 0x1,0x6a,0x60, + 0x2,0x4d,0x42, 0x2,0x4d,0x4c, 0x1,0x6a,0x63, 0x2,0x4d,0x45, + 0x1,0x6a,0x61, 0x2,0x4d,0x36, 0x2,0x4d,0x54, 0x2,0x4d,0x35, + 0x2,0x4d,0x48, 0x3,0x49,0x3c, 0x2,0x4d,0x34, 0x3,0x49,0x39, + 0x4,0x46,0x6c, 0x2,0x4d,0x46, 0x2,0x4d,0x4f, 0x2,0x4d,0x4d, + 0x2,0x4d,0x41, 0x2,0x4d,0x3c, 0x2,0x4d,0x3a, 0x3,0x49,0x42, + 0x2,0x4d,0x3b, 0x2,0x4d,0x4e, 0x2,0x4d,0x59, 0x2,0x4d,0x43, + 0x1,0x6a,0x62, 0x3,0x49,0x3b, 0x2,0x4d,0x3e, 0x3,0x49,0x3a, + 0x2,0x4d,0x52, 0x3,0x49,0x41, 0x1,0x6a,0x65, 0x2,0x4d,0x3d, + 0x2,0x4d,0x37, 0x2,0x4d,0x47, 0x1,0x6a,0x69, 0x3,0x49,0x32, + 0x4,0x46,0x58, 0x1,0x6a,0x5d, 0x1,0x6a,0x66, 0x2,0x4d,0x3f, + 0x2,0x4d,0x39, 0x3,0x49,0x36, 0x1,0x6a,0x5f, 0x2,0x46,0x79, + 0x1,0x6a,0x5e, 0x2,0x4d,0x4a, 0x3,0x44,0x36, 0x1,0x6a,0x5c, + 0x1,0x6a,0x6b, 0x1,0x6a,0x64, 0x2,0x4d,0x4b, 0x2,0x4d,0x40, + 0x2,0x4d,0x38, 0x2,0x4d,0x53, 0x2,0x4d,0x44, 0x1,0x6a,0x6a, + 0x2,0x4d,0x57, 0x1,0x6a,0x67, 0x2,0x4d,0x56, 0x3,0x49,0x3f, + 0x2,0x4d,0x50, 0x2,0x4d,0x55, 0x3,0x49,0x3e, 0x3,0x49,0x43, + 0x2,0x4d,0x58, 0x3,0x66,0x3b, 0x3,0x66,0x3c, 0x3,0x66,0x3a, + 0x3,0x49,0x3d, 0x2,0x53,0x5c, 0x2,0x53,0x5d, 0x2,0x53,0x50, + 0x2,0x53,0x4f, 0x2,0x53,0x4b, 0x1,0x6e,0x5d, 0x3,0x4e,0x4f, + 0x1,0x6e,0x55, 0x2,0x53,0x5f, 0x2,0x53,0x5e, 0x2,0x46,0x4e, + 0x2,0x53,0x48, 0x2,0x53,0x4c, 0x2,0x53,0x46, 0x3,0x4e,0x44, + 0x2,0x53,0x59, 0x2,0x53,0x4a, 0x3,0x4e,0x42, 0x2,0x53,0x60, + 0x2,0x53,0x43, 0x2,0x53,0x41, 0x2,0x53,0x4d, 0x2,0x53,0x57, + 0x2,0x53,0x52, 0x1,0x6e,0x5f, 0x2,0x53,0x38, 0x3,0x4e,0x40, + 0x2,0x53,0x56, 0x3,0x4e,0x4c, 0x3,0x4e,0x46, 0x3,0x4e,0x54, + 0x1,0x6e,0x60, 0x2,0x46,0x62, 0x2,0x53,0x44, 0x2,0x53,0x3b, + 0x2,0x53,0x3e, 0x2,0x53,0x64, 0x2,0x53,0x45, 0x2,0x53,0x3c, + 0x2,0x53,0x3a, 0x2,0x53,0x37, 0x4,0x4c,0x7a, 0x1,0x6e,0x59, + 0x2,0x53,0x4e, 0x1,0x6e,0x58, 0x1,0x6e,0x5c, 0x2,0x53,0x49, + 0x2,0x53,0x51, 0x1,0x6e,0x52, 0x2,0x53,0x61, 0x2,0x53,0x65, + 0x1,0x6e,0x54, 0x3,0x4e,0x4b, 0x2,0x53,0x40, 0x2,0x53,0x54, + 0x2,0x53,0x58, 0x2,0x53,0x3d, 0x2,0x53,0x62, 0x1,0x6e,0x5b, + 0x4,0x4c,0x6a, 0x1,0x6e,0x5a, 0x2,0x53,0x35, 0x1,0x6e,0x5e, + 0x2,0x53,0x5b, 0x2,0x53,0x3f, 0x2,0x53,0x53, 0x2,0x53,0x39, + 0x2,0x53,0x47, 0x2,0x53,0x42, 0x1,0x6e,0x56, 0x1,0x6e,0x57, + 0x2,0x53,0x55, 0x2,0x53,0x66, 0x2,0x53,0x63, 0x2,0x53,0x5a, + 0x4,0x4c,0x78, 0x3,0x4e,0x4d, 0x3,0x4e,0x4e, 0x3,0x4e,0x52, + 0x4,0x4c,0x74, 0x2,0x53,0x36, 0x1,0x6e,0x53, 0x2,0x59,0x74, + 0x3,0x52,0x5a, 0x2,0x59,0x6b, 0x2,0x59,0x6e, 0x3,0x52,0x52, + 0x1,0x72,0x25, 0x2,0x59,0x70, 0x2,0x59,0x65, 0x2,0x59,0x6c, + 0x2,0x59,0x72, 0x1,0x72,0x22, 0x1,0x72,0x26, 0x1,0x71,0x7e, + 0x3,0x52,0x59, 0x3,0x52,0x50, 0x2,0x59,0x67, 0x2,0x59,0x77, + 0x4,0x4d,0x25, 0x4,0x53,0x33, 0x2,0x59,0x71, 0x4,0x53,0x24, + 0x2,0x59,0x68, 0x2,0x5a,0x22, 0x2,0x59,0x7a, 0x2,0x59,0x64, + 0x2,0x5e,0x72, 0x2,0x59,0x6a, 0x1,0x72,0x21, 0x3,0x52,0x58, + 0x2,0x59,0x75, 0x3,0x52,0x54, 0x2,0x5a,0x21, 0x1,0x72,0x29, + 0x3,0x52,0x56, 0x2,0x59,0x7c, 0x2,0x59,0x69, 0x2,0x59,0x6f, + 0x2,0x59,0x73, 0x2,0x59,0x6d, 0x2,0x5a,0x23, 0x2,0x59,0x7e, + 0x2,0x59,0x7b, 0x1,0x72,0x23, 0x1,0x72,0x24, 0x1,0x72,0x28, + 0x2,0x59,0x66, 0x2,0x5a,0x24, 0x1,0x72,0x27, 0x2,0x59,0x78, + 0x3,0x52,0x4f, 0x3,0x52,0x55, 0x2,0x59,0x76, 0x3,0x66,0x3d, + 0x2,0x59,0x79, 0x2,0x5f,0x21, 0x2,0x5e,0x6c, 0x2,0x5e,0x71, + 0x2,0x5e,0x7e, 0x2,0x5e,0x70, 0x2,0x5e,0x68, 0x2,0x5e,0x6d, + 0x4,0x58,0x3e, 0x1,0x75,0x2c, 0x3,0x56,0x2b, 0x2,0x5e,0x61, + 0x2,0x5e,0x79, 0x2,0x5e,0x7b, 0x2,0x5e,0x60, 0x1,0x75,0x2b, + 0x2,0x5e,0x7d, 0x2,0x5e,0x75, 0x1,0x75,0x32, 0x2,0x5e,0x7c, + 0x2,0x5e,0x6e, 0x1,0x75,0x34, 0x2,0x5e,0x66, 0x2,0x59,0x7d, + 0x2,0x5e,0x76, 0x2,0x5e,0x73, 0x2,0x5e,0x62, 0x2,0x5f,0x23, + 0x1,0x75,0x2e, 0x3,0x56,0x28, 0x3,0x56,0x29, 0x1,0x75,0x2f, + 0x2,0x5e,0x64, 0x2,0x5e,0x74, 0x3,0x56,0x2d, 0x2,0x5f,0x22, + 0x2,0x5e,0x77, 0x2,0x5e,0x6a, 0x1,0x75,0x31, 0x1,0x75,0x2d, + 0x2,0x5e,0x78, 0x2,0x5e,0x6b, 0x2,0x5f,0x24, 0x2,0x5e,0x65, + 0x2,0x5e,0x6f, 0x2,0x5e,0x7a, 0x2,0x5e,0x67, 0x2,0x5e,0x69, + 0x4,0x58,0x40, 0x1,0x75,0x35, 0x2,0x5e,0x63, 0x1,0x75,0x33, + 0x1,0x77,0x30, 0x1,0x75,0x2a, 0x3,0x56,0x2c, 0x3,0x56,0x30, + 0x1,0x75,0x30, 0x1,0x77,0x34, 0x2,0x62,0x7d, 0x3,0x58,0x6c, + 0x2,0x62,0x73, 0x2,0x62,0x6e, 0x2,0x62,0x74, 0x2,0x62,0x7e, + 0x2,0x63,0x24, 0x2,0x63,0x23, 0x1,0x77,0x36, 0x1,0x77,0x35, + 0x3,0x58,0x6e, 0x4,0x5d,0x2c, 0x2,0x62,0x75, 0x2,0x63,0x25, + 0x2,0x62,0x78, 0x2,0x62,0x70, 0x3,0x58,0x6f, 0x2,0x62,0x72, + 0x2,0x62,0x71, 0x2,0x62,0x77, 0x2,0x62,0x7c, 0x2,0x62,0x6f, + 0x2,0x62,0x76, 0x2,0x62,0x7b, 0x1,0x77,0x33, 0x4,0x5d,0x28, + 0x2,0x62,0x79, 0x3,0x58,0x6b, 0x1,0x77,0x31, 0x2,0x62,0x7a, + 0x1,0x77,0x2f, 0x1,0x77,0x32, 0x2,0x66,0x60, 0x2,0x63,0x21, + 0x3,0x66,0x3e, 0x1,0x78,0x6d, 0x3,0x5a,0x7e, 0x2,0x66,0x58, + 0x2,0x66,0x5c, 0x2,0x66,0x54, 0x2,0x66,0x57, 0x3,0x5a,0x7d, + 0x2,0x66,0x5f, 0x1,0x78,0x6b, 0x2,0x66,0x64, 0x2,0x66,0x5d, + 0x4,0x60,0x7a, 0x2,0x66,0x55, 0x2,0x66,0x65, 0x2,0x66,0x5e, + 0x1,0x78,0x6e, 0x1,0x78,0x6f, 0x2,0x66,0x62, 0x3,0x5b,0x22, + 0x2,0x66,0x56, 0x1,0x78,0x6a, 0x1,0x78,0x6c, 0x2,0x66,0x51, + 0x2,0x66,0x59, 0x2,0x66,0x53, 0x3,0x5c,0x7b, 0x2,0x66,0x63, + 0x2,0x66,0x61, 0x2,0x66,0x52, 0x2,0x66,0x5a, 0x4,0x60,0x7b, + 0x3,0x5b,0x25, 0x3,0x66,0x3f, 0x2,0x69,0x6a, 0x1,0x78,0x70, + 0x2,0x66,0x5b, 0x1,0x7a,0x32, 0x1,0x7a,0x34, 0x1,0x7a,0x31, + 0x3,0x5c,0x76, 0x2,0x69,0x6f, 0x2,0x69,0x67, 0x2,0x69,0x65, + 0x2,0x69,0x69, 0x2,0x69,0x66, 0x3,0x5c,0x78, 0x3,0x5c,0x7c, + 0x2,0x69,0x6b, 0x2,0x69,0x6d, 0x1,0x7a,0x35, 0x1,0x7a,0x37, + 0x3,0x5d,0x22, 0x2,0x69,0x6c, 0x1,0x7a,0x38, 0x1,0x7a,0x36, + 0x2,0x69,0x6e, 0x3,0x5c,0x7e, 0x4,0x64,0x37, 0x3,0x5d,0x23, + 0x3,0x5c,0x77, 0x1,0x7a,0x33, 0x3,0x5d,0x21, 0x3,0x5e,0x5b, + 0x3,0x5e,0x5a, 0x1,0x7b,0x21, 0x2,0x6c,0x21, 0x2,0x6c,0x27, + 0x1,0x7b,0x23, 0x2,0x69,0x68, 0x2,0x6c,0x26, 0x3,0x5e,0x5c, + 0x2,0x6c,0x2d, 0x2,0x6c,0x24, 0x2,0x6c,0x2b, 0x2,0x6c,0x2a, + 0x2,0x69,0x64, 0x2,0x6c,0x25, 0x2,0x63,0x22, 0x2,0x6c,0x2e, + 0x2,0x6c,0x23, 0x2,0x6c,0x28, 0x3,0x5e,0x58, 0x2,0x6c,0x2c, + 0x2,0x6c,0x22, 0x3,0x5e,0x56, 0x2,0x6d,0x77, 0x1,0x7b,0x22, + 0x2,0x6c,0x29, 0x3,0x5e,0x57, 0x2,0x6f,0x43, 0x2,0x6d,0x78, + 0x2,0x6d,0x76, 0x2,0x6d,0x74, 0x2,0x6d,0x75, 0x2,0x6d,0x79, + 0x3,0x66,0x40, 0x1,0x7c,0x45, 0x2,0x6f,0x41, 0x2,0x6f,0x3f, + 0x2,0x6f,0x44, 0x2,0x6f,0x42, 0x3,0x60,0x43, 0x2,0x6f,0x45, + 0x1,0x7c,0x46, 0x2,0x6f,0x40, 0x3,0x60,0x2f, 0x3,0x61,0x46, + 0x2,0x70,0x4a, 0x3,0x66,0x41, 0x2,0x71,0x34, 0x2,0x71,0x35, + 0x2,0x71,0x36, 0x3,0x61,0x47, 0x3,0x61,0x7c, 0x2,0x72,0x35, + 0x2,0x72,0x2d, 0x2,0x22,0x6f, 0x1,0x4f,0x4d, 0x1,0x53,0x4b, + 0x4,0x2f,0x68, 0x2,0x32,0x5a, 0x2,0x32,0x59, 0x1,0x58,0x25, + 0x1,0x5d,0x28, 0x2,0x39,0x21, 0x3,0x38,0x63, 0x3,0x38,0x60, + 0x2,0x38,0x7e, 0x3,0x38,0x61, 0x1,0x61,0x70, 0x1,0x66,0x3f, + 0x3,0x3e,0x61, 0x1,0x66,0x3e, 0x1,0x66,0x40, 0x5,0x49,0x4e, + 0x2,0x4d,0x5b, 0x2,0x53,0x67, 0x2,0x5a,0x25, 0x2,0x5a,0x27, + 0x2,0x5a,0x26, 0x7,0x32,0x61, 0x1,0x75,0x36, 0x2,0x5f,0x25, + 0x2,0x63,0x26, 0x2,0x71,0x73, 0x1,0x48,0x65, 0x3,0x27,0x2d, + 0x2,0x28,0x69, 0x2,0x28,0x6a, 0x2,0x28,0x68, 0x2,0x28,0x67, + 0x1,0x4f,0x4e, 0x3,0x66,0x42, 0x2,0x2d,0x4a, 0x2,0x2d,0x48, + 0x3,0x2f,0x23, 0x3,0x2e,0x7c, 0x2,0x2d,0x47, 0x3,0x2e,0x7e, + 0x1,0x53,0x4c, 0x1,0x53,0x4e, 0x1,0x53,0x4d, 0x2,0x2d,0x49, + 0x3,0x2f,0x24, 0xf,0x2d,0x3e, 0x3,0x33,0x69, 0x2,0x32,0x66, + 0x2,0x32,0x63, 0x2,0x32,0x61, 0x4,0x2f,0x6d, 0x3,0x33,0x6c, + 0x1,0x58,0x26, 0x2,0x32,0x64, 0x1,0x58,0x2b, 0x2,0x32,0x5e, + 0x2,0x32,0x6d, 0x3,0x33,0x6f, 0x2,0x32,0x6f, 0x2,0x32,0x5f, + 0x3,0x33,0x6e, 0x1,0x58,0x28, 0x2,0x32,0x70, 0x2,0x32,0x6b, + 0x2,0x32,0x5d, 0x2,0x32,0x62, 0x2,0x32,0x6c, 0x2,0x32,0x68, + 0x2,0x32,0x65, 0x3,0x33,0x6b, 0x1,0x58,0x2d, 0x2,0x32,0x6e, + 0x2,0x32,0x60, 0x3,0x33,0x6a, 0x3,0x33,0x70, 0x2,0x32,0x69, + 0x2,0x32,0x5b, 0x1,0x58,0x2c, 0x1,0x58,0x29, 0x2,0x32,0x67, + 0x3,0x33,0x6d, 0x2,0x32,0x6a, 0x2,0x32,0x5c, 0x1,0x58,0x2a, + 0x1,0x58,0x27, 0x4,0x34,0x7a, 0x3,0x38,0x66, 0x1,0x5d,0x32, + 0x2,0x39,0x28, 0x1,0x5d,0x31, 0x3,0x38,0x64, 0x2,0x39,0x2b, + 0x2,0x39,0x2e, 0x1,0x5d,0x2e, 0x1,0x5d,0x2c, 0x2,0x39,0x23, + 0x2,0x39,0x2c, 0x2,0x39,0x2a, 0x2,0x39,0x27, 0x2,0x39,0x2f, + 0x2,0x39,0x30, 0x2,0x39,0x32, 0x2,0x39,0x33, 0x2,0x39,0x22, + 0x1,0x5d,0x2b, 0x2,0x39,0x25, 0x2,0x39,0x24, 0x2,0x39,0x31, + 0x1,0x5d,0x2d, 0x2,0x39,0x26, 0x1,0x5d,0x2f, 0x1,0x5d,0x2a, + 0x2,0x39,0x29, 0x1,0x5d,0x33, 0x4,0x35,0x26, 0x1,0x5d,0x30, + 0x2,0x39,0x2d, 0xf,0x38,0x3a, 0x1,0x61,0x77, 0x2,0x40,0x25, + 0x4,0x3a,0x71, 0x2,0x3f,0x78, 0x1,0x61,0x74, 0x3,0x3e,0x62, + 0x2,0x47,0x2e, 0x2,0x40,0x23, 0x2,0x3f,0x75, 0x1,0x61,0x72, + 0x2,0x3f,0x7a, 0x1,0x61,0x75, 0x2,0x3f,0x7e, 0x2,0x3f,0x7c, + 0x1,0x61,0x78, 0x1,0x61,0x71, 0x4,0x3a,0x76, 0x3,0x3e,0x63, + 0x2,0x3f,0x76, 0x2,0x3f,0x79, 0x1,0x61,0x76, 0x4,0x3a,0x6f, + 0x2,0x3f,0x77, 0x5,0x3b,0x7b, 0x2,0x40,0x24, 0x2,0x40,0x22, + 0x2,0x3f,0x7b, 0x2,0x3f,0x7d, 0x2,0x40,0x21, 0x1,0x61,0x73, + 0x3,0x3e,0x68, 0x2,0x47,0x2f, 0x2,0x47,0x35, 0x2,0x47,0x2b, + 0x2,0x47,0x31, 0x1,0x66,0x41, 0x2,0x47,0x2d, 0x1,0x66,0x47, + 0x3,0x44,0x44, 0x3,0x44,0x45, 0x1,0x66,0x46, 0x3,0x44,0x49, + 0x1,0x66,0x45, 0x2,0x47,0x34, 0x1,0x66,0x48, 0x1,0x66,0x49, + 0x2,0x47,0x2a, 0x2,0x47,0x37, 0x1,0x66,0x4a, 0x1,0x66,0x44, + 0x1,0x66,0x43, 0x2,0x47,0x33, 0x1,0x66,0x4b, 0x2,0x47,0x29, + 0x2,0x47,0x2c, 0x2,0x47,0x36, 0x2,0x47,0x32, 0x4,0x40,0x59, + 0x4,0x40,0x52, 0x2,0x4d,0x7b, 0x2,0x4d,0x70, 0x1,0x66,0x42, + 0x5,0x42,0x5d, 0x3,0x44,0x46, 0x3,0x44,0x48, 0x1,0x6a,0x72, + 0x2,0x4d,0x64, 0x2,0x4d,0x79, 0x2,0x4d,0x65, 0x1,0x6a,0x6d, + 0x3,0x49,0x4f, 0x2,0x4d,0x62, 0x4,0x40,0x55, 0x2,0x4d,0x6b, + 0x2,0x4d,0x63, 0x1,0x6a,0x6f, 0x2,0x4d,0x5d, 0x2,0x4d,0x78, + 0x1,0x6a,0x70, 0x2,0x4d,0x75, 0x2,0x4d,0x76, 0x2,0x4d,0x5e, + 0x1,0x6a,0x75, 0x2,0x4d,0x6d, 0x3,0x49,0x4a, 0x2,0x4d,0x67, + 0x2,0x4d,0x6e, 0x2,0x4d,0x61, 0x4,0x46,0x7e, 0x2,0x4d,0x7a, + 0x2,0x4d,0x72, 0x2,0x4d,0x6c, 0x2,0x4d,0x5c, 0x1,0x6a,0x71, + 0x2,0x4d,0x73, 0x3,0x49,0x45, 0x1,0x6a,0x74, 0x2,0x4d,0x77, + 0x3,0x49,0x4c, 0x2,0x4d,0x71, 0x1,0x6a,0x6e, 0x2,0x4d,0x6f, + 0x3,0x49,0x49, 0x2,0x4d,0x69, 0x1,0x6a,0x6c, 0x2,0x4d,0x60, + 0x2,0x4d,0x68, 0x2,0x4d,0x74, 0x2,0x4d,0x66, 0xf,0x4c,0x33, + 0x3,0x49,0x4e, 0x2,0x4d,0x6a, 0x3,0x49,0x4b, 0x3,0x66,0x43, + 0x1,0x6e,0x6a, 0x2,0x47,0x30, 0x2,0x53,0x79, 0x2,0x54,0x24, + 0x2,0x53,0x78, 0x2,0x53,0x74, 0x2,0x53,0x71, 0x1,0x6e,0x6b, + 0x2,0x53,0x6f, 0x1,0x6a,0x73, 0x2,0x53,0x68, 0x1,0x6e,0x69, + 0x2,0x53,0x6e, 0x1,0x6e,0x68, 0x2,0x53,0x73, 0x2,0x53,0x70, + 0x2,0x54,0x22, 0x2,0x53,0x7b, 0x2,0x53,0x75, 0x2,0x53,0x7a, + 0x1,0x6e,0x64, 0x2,0x53,0x72, 0x2,0x54,0x27, 0x2,0x53,0x69, + 0x2,0x53,0x6a, 0x2,0x54,0x23, 0x1,0x6e,0x65, 0x2,0x54,0x28, + 0x1,0x6e,0x67, 0x2,0x54,0x29, 0x2,0x53,0x77, 0x2,0x4d,0x5f, + 0x2,0x53,0x7d, 0x2,0x53,0x76, 0x2,0x54,0x21, 0x2,0x53,0x7c, + 0x5,0x50,0x55, 0x3,0x4e,0x5d, 0x4,0x4d,0x28, 0x2,0x53,0x6d, + 0x1,0x6e,0x62, 0x2,0x54,0x26, 0x1,0x6e,0x63, 0x2,0x53,0x6b, + 0x1,0x6e,0x66, 0x2,0x5a,0x32, 0x2,0x53,0x7e, 0x2,0x54,0x25, + 0x4,0x4d,0x31, 0x3,0x4e,0x59, 0x2,0x5a,0x2f, 0x1,0x6e,0x61, + 0x1,0x72,0x2a, 0x2,0x5a,0x39, 0x2,0x5a,0x35, 0x4,0x53,0x3c, + 0x2,0x5a,0x33, 0x2,0x5a,0x2e, 0x2,0x5a,0x3d, 0x3,0x52,0x5b, + 0x3,0x52,0x5d, 0x4,0x53,0x44, 0x1,0x72,0x2e, 0x3,0x52,0x5f, + 0x2,0x5a,0x2a, 0x2,0x5a,0x36, 0x2,0x5a,0x37, 0x2,0x5a,0x2d, + 0x2,0x5a,0x2c, 0x2,0x5a,0x3a, 0x4,0x53,0x41, 0x2,0x5a,0x30, + 0x2,0x5a,0x2b, 0x2,0x5a,0x31, 0x3,0x52,0x62, 0x2,0x5a,0x3c, + 0x2,0x5a,0x29, 0x2,0x5a,0x3b, 0x2,0x5a,0x38, 0x1,0x72,0x2c, + 0x1,0x72,0x2b, 0x4,0x53,0x39, 0x3,0x52,0x5e, 0x1,0x72,0x2d, + 0x2,0x5a,0x34, 0x2,0x5a,0x28, 0x3,0x66,0x45, 0x3,0x66,0x44, + 0x2,0x5f,0x27, 0x1,0x75,0x3c, 0x2,0x5f,0x2b, 0x2,0x5f,0x28, + 0x2,0x5f,0x2f, 0x2,0x5f,0x35, 0x2,0x5f,0x2a, 0x3,0x56,0x3a, + 0x2,0x5f,0x3e, 0x1,0x75,0x39, 0x2,0x5f,0x38, 0x2,0x5f,0x2d, + 0x2,0x5f,0x39, 0x2,0x5f,0x34, 0x2,0x5f,0x3b, 0x2,0x5f,0x2c, + 0x1,0x75,0x3e, 0x1,0x75,0x3d, 0x2,0x5f,0x2e, 0x2,0x5f,0x3c, + 0x2,0x5f,0x26, 0x2,0x5f,0x3a, 0x1,0x75,0x37, 0x3,0x56,0x39, + 0x2,0x5f,0x32, 0x2,0x5f,0x31, 0x2,0x5f,0x36, 0x2,0x5f,0x29, + 0x1,0x75,0x3b, 0x3,0x56,0x3b, 0x1,0x75,0x3f, 0x2,0x5f,0x30, + 0x2,0x5f,0x37, 0x1,0x75,0x40, 0x2,0x5f,0x33, 0x3,0x56,0x36, + 0x3,0x56,0x34, 0x1,0x75,0x38, 0x1,0x75,0x3a, 0x2,0x63,0x33, + 0x2,0x63,0x31, 0x3,0x5b,0x28, 0x3,0x58,0x76, 0x2,0x63,0x37, + 0x2,0x63,0x35, 0x2,0x63,0x38, 0x3,0x58,0x78, 0x2,0x63,0x2a, + 0x2,0x63,0x32, 0x2,0x63,0x3c, 0x2,0x5f,0x3d, 0x2,0x63,0x2e, + 0x1,0x77,0x3a, 0x2,0x53,0x6c, 0x2,0x63,0x29, 0x2,0x63,0x36, + 0x2,0x63,0x30, 0x2,0x63,0x2d, 0x2,0x63,0x28, 0x2,0x63,0x27, + 0x2,0x63,0x3b, 0x3,0x58,0x73, 0x2,0x63,0x2c, 0x2,0x63,0x2b, + 0x1,0x77,0x38, 0x2,0x63,0x34, 0x3,0x58,0x74, 0x1,0x77,0x37, + 0x3,0x58,0x75, 0x5,0x64,0x48, 0x1,0x77,0x39, 0x2,0x63,0x2f, + 0x2,0x63,0x3a, 0x3,0x66,0x46, 0x2,0x66,0x69, 0x2,0x66,0x6a, + 0x3,0x5b,0x2c, 0x1,0x78,0x74, 0x2,0x66,0x67, 0x1,0x78,0x71, + 0x2,0x66,0x6f, 0x3,0x5b,0x27, 0x1,0x78,0x75, 0x2,0x66,0x71, + 0x2,0x66,0x66, 0x2,0x63,0x39, 0x2,0x66,0x73, 0x2,0x66,0x68, + 0x5,0x69,0x43, 0x1,0x78,0x72, 0x2,0x66,0x6e, 0x3,0x5b,0x29, + 0x2,0x66,0x70, 0x2,0x66,0x6b, 0x2,0x66,0x72, 0x2,0x66,0x6d, + 0x2,0x66,0x6c, 0x1,0x78,0x73, 0x3,0x58,0x77, 0x3,0x5b,0x2b, + 0x2,0x69,0x71, 0x2,0x69,0x72, 0x3,0x5d,0x25, 0x2,0x69,0x74, + 0x1,0x7a,0x39, 0x1,0x7a,0x3a, 0x2,0x69,0x75, 0x2,0x69,0x73, + 0x3,0x5d,0x24, 0x2,0x69,0x70, 0x3,0x5e,0x5d, 0x2,0x6c,0x31, + 0x2,0x6c,0x34, 0x2,0x6c,0x30, 0x4,0x61,0x26, 0x1,0x7b,0x27, + 0x2,0x6c,0x32, 0x1,0x7b,0x26, 0x1,0x7b,0x25, 0x1,0x7b,0x24, + 0x2,0x6c,0x33, 0x2,0x6d,0x7e, 0x2,0x6d,0x7c, 0x3,0x5f,0x5f, + 0x2,0x6d,0x7b, 0x2,0x6c,0x2f, 0x2,0x6d,0x7d, 0x2,0x6c,0x35, + 0x2,0x6d,0x7a, 0x3,0x60,0x45, 0x2,0x6f,0x48, 0x2,0x6f,0x26, + 0x2,0x6f,0x46, 0x1,0x7c,0x47, 0x2,0x6f,0x47, 0x2,0x6f,0x49, + 0x3,0x66,0x47, 0x2,0x70,0x4d, 0x1,0x7c,0x66, 0x2,0x70,0x4c, + 0x2,0x70,0x4b, 0x1,0x7c,0x67, 0x4,0x6c,0x23, 0x1,0x7d,0x27, + 0x2,0x71,0x5d, 0x2,0x71,0x75, 0x2,0x71,0x74, 0x2,0x71,0x76, + 0x1,0x48,0x66, 0x2,0x2d,0x4b, 0x3,0x2f,0x26, 0x2,0x32,0x71, + 0x2,0x32,0x72, 0x3,0x38,0x6a, 0x3,0x3e,0x6a, 0x3,0x3e,0x69, + 0x2,0x40,0x26, 0x6,0x4e,0x4f, 0x2,0x6c,0x36, 0x2,0x70,0x4e, + 0x1,0x48,0x67, 0x1,0x53,0x4f, 0x2,0x2d,0x4c, 0x3,0x33,0x71, + 0x3,0x66,0x48, 0x4,0x35,0x27, 0x2,0x39,0x34, 0x1,0x5d,0x34, + 0x2,0x40,0x28, 0x2,0x40,0x27, 0x1,0x61,0x79, 0x3,0x44,0x4d, + 0x1,0x66,0x4c, 0x2,0x54,0x2a, 0x1,0x6e,0x6c, 0x3,0x4e,0x5f, + 0x1,0x6e,0x6d, 0x3,0x52,0x63, 0x3,0x52,0x64, 0x4,0x53,0x4b, + 0x1,0x72,0x2f, 0x1,0x7c,0x68, 0x1,0x48,0x68, 0x3,0x2f,0x27, + 0x2,0x2d,0x4d, 0x1,0x4f,0x50, 0x2,0x2d,0x4f, 0x2,0x2d,0x4e, + 0x1,0x53,0x50, 0x2,0x32,0x73, 0x3,0x33,0x74, 0x2,0x32,0x7a, + 0x1,0x58,0x2e, 0x2,0x32,0x78, 0x2,0x32,0x76, 0x3,0x33,0x77, + 0x2,0x32,0x7d, 0x2,0x32,0x74, 0x2,0x32,0x75, 0x1,0x58,0x2f, + 0x3,0x33,0x72, 0x1,0x58,0x33, 0x3,0x33,0x73, 0x3,0x33,0x75, + 0x2,0x32,0x7e, 0x1,0x58,0x32, 0x2,0x32,0x7c, 0x2,0x32,0x79, + 0x2,0x32,0x77, 0x1,0x58,0x30, 0x1,0x58,0x31, 0x2,0x32,0x7b, + 0x3,0x33,0x76, 0x3,0x66,0x49, 0x1,0x5d,0x36, 0x2,0x39,0x35, + 0x3,0x38,0x72, 0x1,0x5d,0x3b, 0x2,0x39,0x45, 0x1,0x5d,0x3a, + 0x2,0x39,0x47, 0x3,0x38,0x6e, 0x3,0x38,0x74, 0x2,0x39,0x3b, + 0x1,0x5d,0x38, 0x2,0x39,0x46, 0x3,0x38,0x6c, 0x2,0x39,0x36, + 0x1,0x5d,0x39, 0x2,0x39,0x42, 0x2,0x39,0x3e, 0x2,0x39,0x40, + 0x2,0x39,0x3a, 0x2,0x39,0x41, 0x3,0x38,0x6b, 0x4,0x35,0x2f, + 0x1,0x5d,0x35, 0x2,0x39,0x3d, 0x3,0x38,0x73, 0x2,0x39,0x3c, + 0x2,0x39,0x38, 0x3,0x38,0x6d, 0x2,0x39,0x43, 0x3,0x38,0x6f, + 0x3,0x38,0x71, 0x2,0x39,0x3f, 0x2,0x39,0x37, 0x3,0x38,0x70, + 0x2,0x39,0x39, 0x1,0x5d,0x37, 0x2,0x39,0x44, 0x1,0x61,0x7c, + 0x2,0x40,0x33, 0x4,0x3a,0x7b, 0x3,0x3e,0x70, 0x3,0x3e,0x72, + 0x2,0x40,0x2f, 0x2,0x40,0x31, 0x2,0x40,0x2c, 0x2,0x40,0x2b, + 0x2,0x40,0x29, 0x3,0x3e,0x6d, 0x2,0x40,0x30, 0x2,0x40,0x32, + 0x2,0x40,0x2e, 0x3,0x3e,0x6f, 0x2,0x40,0x2d, 0x1,0x61,0x7a, + 0x1,0x61,0x7b, 0x2,0x40,0x35, 0x1,0x66,0x54, 0x2,0x47,0x39, + 0x2,0x47,0x3f, 0x2,0x47,0x3a, 0x2,0x47,0x3b, 0x3,0x44,0x4e, + 0x2,0x47,0x40, 0x5,0x42,0x6c, 0x1,0x66,0x56, 0x4,0x40,0x61, + 0x1,0x66,0x4e, 0x1,0x66,0x55, 0x2,0x47,0x38, 0x2,0x40,0x2a, + 0x1,0x66,0x51, 0x1,0x66,0x4f, 0x2,0x47,0x3e, 0x2,0x47,0x3d, + 0x1,0x66,0x50, 0x1,0x66,0x52, 0x2,0x47,0x3c, 0x1,0x66,0x4d, + 0x3,0x44,0x4f, 0x1,0x66,0x53, 0x3,0x4e,0x60, 0x2,0x4d,0x7d, + 0x1,0x6a,0x7c, 0x3,0x49,0x59, 0x3,0x49,0x52, 0x2,0x4e,0x2a, + 0x2,0x4e,0x29, 0x3,0x49,0x57, 0x2,0x4e,0x24, 0x1,0x6a,0x7e, + 0x2,0x4e,0x28, 0x2,0x4d,0x7e, 0x2,0x4e,0x21, 0x1,0x6a,0x76, + 0x1,0x6a,0x78, 0x3,0x49,0x54, 0x2,0x4e,0x26, 0x2,0x4d,0x7c, + 0x1,0x6a,0x7a, 0x1,0x6a,0x79, 0x2,0x4e,0x22, 0x2,0x4e,0x27, + 0x2,0x4e,0x25, 0x1,0x6a,0x7b, 0x2,0x4e,0x23, 0x3,0x49,0x51, + 0x3,0x49,0x56, 0x2,0x40,0x34, 0x1,0x6a,0x77, 0x3,0x49,0x58, + 0x2,0x54,0x2b, 0x2,0x54,0x32, 0x1,0x6e,0x6f, 0x4,0x4d,0x46, + 0x2,0x54,0x36, 0x1,0x6e,0x73, 0x2,0x54,0x2e, 0x2,0x54,0x2c, + 0x4,0x4d,0x3e, 0x2,0x54,0x35, 0x3,0x4e,0x61, 0x1,0x6e,0x6e, + 0x2,0x54,0x34, 0x1,0x6e,0x70, 0x1,0x6e,0x71, 0x2,0x54,0x2d, + 0x1,0x6e,0x72, 0x2,0x54,0x33, 0x2,0x54,0x2f, 0x2,0x54,0x30, + 0x2,0x54,0x31, 0x1,0x6a,0x7d, 0x3,0x4e,0x62, 0x2,0x5a,0x3e, + 0x2,0x5a,0x4a, 0x4,0x53,0x53, 0x1,0x72,0x34, 0x2,0x5a,0x45, + 0x2,0x5a,0x47, 0x3,0x52,0x65, 0x1,0x72,0x32, 0x2,0x5a,0x3f, + 0x2,0x5a,0x43, 0x4,0x53,0x50, 0x2,0x5a,0x46, 0x1,0x72,0x30, + 0x1,0x72,0x33, 0x2,0x5a,0x49, 0x2,0x5a,0x41, 0x2,0x5a,0x42, + 0x2,0x5a,0x48, 0x2,0x5a,0x40, 0x2,0x5a,0x44, 0x1,0x72,0x31, + 0x2,0x5f,0x40, 0x2,0x5f,0x3f, 0x1,0x75,0x42, 0x2,0x5f,0x45, + 0x1,0x75,0x44, 0x3,0x56,0x40, 0x4,0x58,0x62, 0x1,0x75,0x41, + 0x2,0x5f,0x41, 0x1,0x75,0x45, 0x2,0x5f,0x42, 0x3,0x56,0x3f, + 0x3,0x56,0x3d, 0x2,0x5f,0x43, 0x2,0x5f,0x46, 0x3,0x56,0x42, + 0x1,0x75,0x43, 0x2,0x63,0x41, 0x3,0x58,0x79, 0x2,0x63,0x44, + 0x3,0x58,0x7a, 0x2,0x63,0x3e, 0x2,0x63,0x40, 0x3,0x58,0x7c, + 0x3,0x58,0x7b, 0x2,0x63,0x3f, 0x2,0x63,0x42, 0x2,0x63,0x43, + 0x2,0x5f,0x44, 0x2,0x63,0x3d, 0x3,0x66,0x4a, 0x1,0x78,0x78, + 0x2,0x66,0x77, 0x2,0x66,0x7a, 0x2,0x66,0x7c, 0x2,0x66,0x75, + 0x2,0x66,0x76, 0x2,0x66,0x79, 0x2,0x66,0x7b, 0x1,0x78,0x79, + 0x1,0x78,0x77, 0x1,0x78,0x76, 0x2,0x66,0x78, 0x2,0x66,0x74, + 0x2,0x69,0x76, 0x1,0x7a,0x3b, 0x3,0x5d,0x29, 0x2,0x69,0x77, + 0x3,0x5d,0x28, 0x2,0x6c,0x38, 0x1,0x7b,0x28, 0x2,0x6c,0x3a, + 0x1,0x7b,0x29, 0x2,0x6c,0x37, 0x2,0x6c,0x39, 0x1,0x7b,0x72, + 0x5,0x74,0x38, 0x2,0x6e,0x21, 0x1,0x7b,0x71, 0x2,0x6f,0x4c, + 0x2,0x6f,0x4b, 0x4,0x6c,0x25, 0x2,0x6f,0x4a, 0xf,0x68,0x4a, + 0x3,0x61,0x49, 0x2,0x71,0x37, 0x2,0x71,0x38, 0x2,0x71,0x3a, + 0x2,0x71,0x39, 0x3,0x61,0x7d, 0x2,0x22,0x70, 0x1,0x48,0x69, + 0x1,0x53,0x51, 0x2,0x39,0x48, 0x1,0x61,0x7d, 0x3,0x66,0x4b, + 0x2,0x47,0x41, 0x1,0x77,0x3b, 0x3,0x5b,0x2f, 0x2,0x66,0x7d, + 0x3,0x60,0x46, 0x3,0x61,0x4a, 0x1,0x4b,0x44, 0x3,0x2f,0x29, + 0x4,0x2f,0x76, 0x4,0x2f,0x75, 0x1,0x5d,0x3d, 0x4,0x35,0x34, + 0x3,0x38,0x76, 0x3,0x38,0x75, 0x1,0x5d,0x3c, 0x3,0x38,0x77, + 0x2,0x40,0x36, 0x1,0x61,0x7e, 0x2,0x40,0x38, 0x2,0x40,0x37, + 0x6,0x4e,0x60, 0x3,0x3e,0x74, 0x2,0x47,0x42, 0x1,0x66,0x57, + 0x2,0x4e,0x2b, 0x2,0x4e,0x2e, 0x2,0x4e,0x2d, 0x4,0x47,0x35, + 0x2,0x4e,0x2c, 0x2,0x54,0x37, 0x2,0x54,0x39, 0x2,0x54,0x38, + 0x3,0x4e,0x65, 0x1,0x72,0x36, 0x3,0x52,0x66, 0x4,0x53,0x59, + 0x3,0x4e,0x64, 0x1,0x72,0x35, 0x3,0x56,0x46, 0x1,0x75,0x46, + 0x2,0x5f,0x47, 0x2,0x5f,0x49, 0x2,0x5f,0x48, 0x3,0x58,0x7e, + 0x3,0x58,0x7d, 0x1,0x77,0x3c, 0x3,0x59,0x21, 0x4,0x61,0x2f, + 0x3,0x5b,0x31, 0x2,0x67,0x21, 0x2,0x66,0x7e, 0xf,0x63,0x77, + 0x2,0x69,0x78, 0x1,0x7a,0x3c, 0x3,0x5d,0x2a, 0x3,0x5e,0x61, + 0x1,0x7b,0x2a, 0x2,0x6e,0x23, 0x2,0x6e,0x22, 0x1,0x7d,0x28, + 0x1,0x4b,0x45, 0x2,0x2d,0x50, 0x1,0x53,0x52, 0x2,0x39,0x4b, + 0x2,0x39,0x49, 0x4,0x35,0x39, 0x4,0x35,0x38, 0x2,0x39,0x4a, + 0x2,0x40,0x3a, 0x2,0x40,0x3b, 0x2,0x47,0x49, 0x2,0x40,0x39, + 0x2,0x47,0x43, 0x2,0x47,0x47, 0x2,0x47,0x46, 0x2,0x47,0x48, + 0x1,0x66,0x58, 0x2,0x47,0x45, 0x2,0x47,0x44, 0x2,0x47,0x4a, + 0x3,0x44,0x54, 0x2,0x4e,0x31, 0x2,0x4e,0x2f, 0x3,0x49,0x5c, + 0x2,0x4e,0x30, 0x2,0x54,0x3c, 0x2,0x54,0x3a, 0x3,0x4e,0x66, + 0x2,0x54,0x3b, 0x2,0x5a,0x4b, 0x2,0x5f,0x4a, 0x2,0x5f,0x4b, + 0x1,0x77,0x3d, 0x3,0x5b,0x32, 0x2,0x67,0x22, 0x2,0x69,0x79, + 0x1,0x7a,0x3d, 0x4,0x61,0x37, 0x2,0x6c,0x3b, 0x2,0x6e,0x24, + 0x1,0x7b,0x73, 0x4,0x69,0x45, 0x2,0x6f,0x4d, 0x2,0x71,0x3b, + 0x1,0x4b,0x46, 0x1,0x53,0x54, 0x1,0x53,0x55, 0x2,0x2d,0x51, + 0x3,0x2f,0x2a, 0x3,0x2f,0x2c, 0x2,0x2d,0x52, 0x1,0x53,0x53, + 0x4,0x2f,0x7c, 0x1,0x58,0x39, 0x3,0x33,0x7b, 0x1,0x58,0x37, + 0x3,0x33,0x7a, 0x1,0x58,0x36, 0x1,0x58,0x3d, 0x1,0x58,0x35, + 0x1,0x58,0x3e, 0x2,0x33,0x21, 0x1,0x58,0x3b, 0x4,0x2f,0x7d, + 0x1,0x58,0x38, 0x1,0x58,0x3c, 0x1,0x58,0x3a, 0x1,0x58,0x34, + 0x3,0x33,0x7c, 0x1,0x5d,0x45, 0x3,0x38,0x7e, 0x1,0x5d,0x3f, + 0x2,0x39,0x4f, 0x1,0x5d,0x44, 0x3,0x39,0x23, 0x3,0x39,0x29, + 0x1,0x5d,0x46, 0x1,0x5d,0x40, 0x6,0x44,0x70, 0x1,0x5d,0x41, + 0x3,0x38,0x79, 0x2,0x39,0x4d, 0x3,0x38,0x7b, 0x3,0x39,0x25, + 0x1,0x5d,0x3e, 0x3,0x39,0x22, 0x2,0x39,0x4e, 0x1,0x5d,0x43, + 0x4,0x35,0x3d, 0x5,0x35,0x5b, 0x2,0x39,0x4c, 0x1,0x5d,0x42, + 0x3,0x38,0x7a, 0x1,0x62,0x2b, 0x3,0x3e,0x7c, 0x1,0x62,0x2d, + 0x4,0x3b,0x2f, 0x3,0x3e,0x7d, 0x2,0x40,0x3e, 0x1,0x62,0x2c, + 0x1,0x62,0x21, 0x1,0x62,0x25, 0x3,0x3f,0x24, 0x1,0x66,0x6b, + 0x2,0x47,0x4f, 0x2,0x40,0x40, 0x1,0x62,0x26, 0x3,0x3e,0x7e, + 0x3,0x3e,0x75, 0x2,0x40,0x43, 0x2,0x40,0x44, 0x1,0x62,0x2a, + 0x4,0x3b,0x30, 0x2,0x40,0x46, 0x3,0x3f,0x21, 0x2,0x40,0x48, + 0x3,0x3f,0x23, 0x2,0x40,0x49, 0x2,0x40,0x3d, 0x2,0x40,0x3c, + 0x2,0x40,0x4a, 0x1,0x62,0x29, 0x2,0x40,0x47, 0x2,0x40,0x45, + 0x4,0x3b,0x2c, 0x1,0x62,0x27, 0x1,0x62,0x23, 0x1,0x62,0x2e, + 0x2,0x40,0x41, 0x2,0x40,0x42, 0x2,0x40,0x3f, 0x3,0x3e,0x78, + 0x1,0x62,0x28, 0x4,0x3b,0x31, 0x3,0x3f,0x22, 0x1,0x62,0x24, + 0x1,0x62,0x22, 0x2,0x47,0x4e, 0x1,0x66,0x66, 0x1,0x66,0x61, + 0x3,0x44,0x60, 0x3,0x44,0x59, 0x1,0x66,0x5c, 0x3,0x44,0x63, + 0x1,0x66,0x6c, 0x1,0x66,0x5d, 0x3,0x44,0x55, 0x1,0x66,0x59, + 0x1,0x66,0x68, 0x1,0x66,0x65, 0x1,0x66,0x67, 0x3,0x44,0x58, + 0x1,0x66,0x5e, 0x1,0x66,0x63, 0x1,0x66,0x5a, 0x1,0x66,0x5b, + 0x2,0x47,0x56, 0x2,0x47,0x53, 0x2,0x47,0x4b, 0x2,0x47,0x50, + 0x3,0x44,0x5b, 0x1,0x66,0x69, 0x2,0x47,0x57, 0x1,0x66,0x6a, + 0x1,0x66,0x60, 0x3,0x44,0x5c, 0x3,0x44,0x61, 0x2,0x47,0x4d, + 0x3,0x44,0x56, 0x2,0x47,0x55, 0x2,0x47,0x51, 0x2,0x47,0x54, + 0x2,0x47,0x52, 0x1,0x66,0x64, 0x2,0x47,0x4c, 0x1,0x66,0x5f, + 0x3,0x44,0x5d, 0x2,0x4e,0x34, 0x1,0x6b,0x22, 0x1,0x6b,0x25, + 0x3,0x49,0x5f, 0x2,0x4e,0x36, 0x3,0x49,0x64, 0x1,0x6b,0x2d, + 0x2,0x4e,0x35, 0x1,0x6b,0x27, 0x3,0x49,0x63, 0x1,0x6e,0x78, + 0x2,0x4e,0x37, 0x4,0x47,0x45, 0x1,0x6b,0x2c, 0x2,0x4e,0x33, + 0x1,0x6b,0x2e, 0x3,0x49,0x5e, 0x3,0x49,0x62, 0x3,0x49,0x6b, + 0x1,0x6b,0x23, 0x3,0x49,0x68, 0x1,0x66,0x62, 0x1,0x6b,0x26, + 0x3,0x49,0x60, 0x1,0x6b,0x24, 0x1,0x6b,0x28, 0x1,0x6b,0x2a, + 0x1,0x6b,0x21, 0x1,0x6b,0x2f, 0x1,0x6b,0x2b, 0x3,0x49,0x65, + 0x1,0x6b,0x29, 0x2,0x4e,0x32, 0x3,0x49,0x66, 0xf,0x4c,0x41, + 0x3,0x4e,0x74, 0x1,0x6f,0x21, 0x3,0x4e,0x67, 0x1,0x6e,0x7b, + 0x3,0x4e,0x72, 0x3,0x4e,0x70, 0x3,0x4e,0x6e, 0x1,0x6f,0x24, + 0x3,0x4e,0x6c, 0x2,0x54,0x3f, 0x1,0x6f,0x25, 0x2,0x54,0x4b, + 0x2,0x54,0x44, 0x1,0x6e,0x74, 0x2,0x54,0x4c, 0x2,0x54,0x46, + 0x1,0x6e,0x7e, 0x2,0x54,0x47, 0x3,0x4e,0x73, 0x1,0x6e,0x7d, + 0x2,0x54,0x4a, 0x1,0x6e,0x77, 0x2,0x54,0x48, 0x2,0x54,0x3e, + 0x1,0x6e,0x76, 0x2,0x5a,0x56, 0x1,0x6e,0x7c, 0x3,0x4e,0x75, + 0x1,0x6e,0x79, 0x3,0x4e,0x69, 0x1,0x6f,0x23, 0x3,0x4e,0x6a, + 0x2,0x54,0x3d, 0x3,0x4e,0x76, 0x2,0x54,0x41, 0x1,0x6e,0x75, + 0x2,0x54,0x40, 0x2,0x54,0x42, 0x2,0x54,0x43, 0x1,0x6f,0x22, + 0x2,0x54,0x45, 0x2,0x54,0x49, 0x2,0x54,0x4d, 0x1,0x6f,0x26, + 0x1,0x72,0x3c, 0x2,0x5a,0x51, 0x2,0x5a,0x57, 0x2,0x5a,0x54, + 0x2,0x5a,0x4c, 0x2,0x5a,0x58, 0x2,0x5a,0x4d, 0x3,0x52,0x6a, + 0x2,0x5a,0x53, 0x3,0x52,0x6b, 0x1,0x72,0x37, 0x1,0x72,0x3d, + 0x2,0x5a,0x59, 0x3,0x4e,0x6f, 0x3,0x52,0x67, 0x1,0x72,0x39, + 0x3,0x52,0x6e, 0x1,0x72,0x43, 0x1,0x72,0x3e, 0x2,0x5a,0x5b, + 0x2,0x5a,0x55, 0x1,0x72,0x3a, 0x2,0x5a,0x4e, 0x1,0x72,0x44, + 0x2,0x5a,0x4f, 0x2,0x5a,0x50, 0x1,0x72,0x45, 0x1,0x72,0x42, + 0x1,0x6e,0x7a, 0x3,0x52,0x69, 0x1,0x72,0x38, 0x2,0x5a,0x5c, + 0x1,0x72,0x46, 0x3,0x52,0x68, 0x1,0x72,0x3f, 0x2,0x5a,0x5a, + 0x1,0x72,0x3b, 0x1,0x72,0x40, 0x1,0x72,0x41, 0x3,0x66,0x4c, + 0x1,0x75,0x4e, 0x2,0x5f,0x50, 0x2,0x5f,0x59, 0x2,0x5f,0x56, + 0x2,0x5f,0x58, 0x3,0x56,0x49, 0x1,0x75,0x4b, 0x2,0x5f,0x51, + 0x3,0x56,0x4a, 0x2,0x5f,0x57, 0x1,0x75,0x47, 0x2,0x5f,0x53, + 0x1,0x75,0x4f, 0x2,0x5f,0x4f, 0x2,0x5f,0x54, 0x2,0x5f,0x5b, + 0x2,0x5a,0x52, 0x2,0x5f,0x55, 0x2,0x5f,0x4e, 0x1,0x75,0x48, + 0x2,0x5f,0x4d, 0x1,0x75,0x49, 0x2,0x5f,0x5c, 0x1,0x75,0x4a, + 0x2,0x5f,0x5a, 0x1,0x75,0x4d, 0x2,0x5f,0x4c, 0x3,0x56,0x48, + 0x1,0x75,0x4c, 0x2,0x5f,0x52, 0x2,0x63,0x47, 0x2,0x63,0x55, + 0x2,0x63,0x50, 0x2,0x63,0x52, 0x2,0x63,0x46, 0x1,0x77,0x3e, + 0x3,0x59,0x2a, 0x2,0x63,0x45, 0x1,0x77,0x41, 0x1,0x77,0x40, + 0x3,0x59,0x26, 0x2,0x63,0x54, 0x2,0x63,0x4c, 0x2,0x63,0x49, + 0x2,0x63,0x4f, 0x3,0x59,0x24, 0x2,0x63,0x48, 0x3,0x59,0x28, + 0x2,0x63,0x4a, 0x2,0x63,0x53, 0x2,0x63,0x51, 0x3,0x59,0x23, + 0x1,0x77,0x3f, 0x2,0x63,0x58, 0x2,0x63,0x56, 0x2,0x63,0x4d, + 0x2,0x63,0x57, 0x2,0x63,0x4e, 0x3,0x5b,0x34, 0x2,0x67,0x26, + 0x1,0x78,0x7a, 0x2,0x67,0x2d, 0x3,0x5b,0x35, 0x4,0x61,0x3a, + 0x2,0x6c,0x3e, 0x1,0x79,0x23, 0x2,0x63,0x4b, 0x2,0x67,0x24, + 0x1,0x78,0x7d, 0x2,0x67,0x25, 0x2,0x67,0x2a, 0x3,0x5b,0x36, + 0x3,0x5d,0x33, 0x1,0x79,0x21, 0x1,0x79,0x22, 0x2,0x67,0x23, + 0x2,0x67,0x2c, 0x2,0x67,0x2e, 0x2,0x67,0x27, 0x2,0x67,0x29, + 0x2,0x67,0x2b, 0x2,0x67,0x28, 0x2,0x67,0x2f, 0x1,0x78,0x7c, + 0x1,0x79,0x24, 0x1,0x78,0x7e, 0x1,0x78,0x7b, 0x2,0x69,0x7c, + 0x4,0x64,0x4d, 0x1,0x7a,0x42, 0x2,0x69,0x7a, 0x3,0x5d,0x30, + 0x3,0x5d,0x2c, 0x2,0x69,0x7e, 0x3,0x5d,0x32, 0x2,0x6a,0x21, + 0x1,0x7a,0x40, 0x2,0x6a,0x22, 0x2,0x69,0x7d, 0x3,0x5d,0x2b, + 0x2,0x69,0x7b, 0x1,0x7a,0x43, 0x1,0x7a,0x3f, 0x2,0x6a,0x23, + 0x3,0x5d,0x2e, 0x1,0x7a,0x41, 0x1,0x7a,0x3e, 0x3,0x5c,0x6d, + 0x4,0x67,0x3b, 0x1,0x7b,0x2b, 0x3,0x5e,0x62, 0x4,0x67,0x41, + 0x1,0x7b,0x2c, 0x2,0x6c,0x3d, 0x2,0x6c,0x3c, 0x2,0x6c,0x3f, + 0x2,0x6c,0x40, 0x3,0x5e,0x63, 0x1,0x7b,0x2d, 0x2,0x6e,0x25, + 0x2,0x6e,0x2a, 0x1,0x7b,0x74, 0x3,0x5f,0x61, 0x2,0x6e,0x27, + 0x3,0x5f,0x62, 0x2,0x6e,0x26, 0x2,0x6e,0x29, 0x2,0x6e,0x28, + 0x3,0x60,0x48, 0x2,0x6f,0x51, 0x4,0x6a,0x7c, 0x1,0x7c,0x48, + 0x2,0x6f,0x50, 0x2,0x6f,0x4e, 0x3,0x60,0x47, 0x2,0x6f,0x4f, + 0x3,0x60,0x49, 0x3,0x60,0x7b, 0x1,0x7c,0x6a, 0x1,0x7c,0x69, + 0x2,0x70,0x4f, 0x2,0x70,0x50, 0x1,0x7c,0x6b, 0x3,0x61,0x4b, + 0x2,0x71,0x3c, 0x2,0x71,0x3d, 0x1,0x7d,0x34, 0x3,0x61,0x6b, + 0x1,0x7d,0x3a, 0x3,0x61,0x7e, 0x2,0x71,0x77, 0x2,0x72,0x36, + 0x1,0x4b,0x47, 0x5,0x30,0x46, 0x2,0x39,0x50, 0x3,0x39,0x2a, + 0x2,0x39,0x51, 0x2,0x47,0x58, 0x2,0x4e,0x38, 0x2,0x54,0x4e, + 0x1,0x75,0x51, 0x3,0x56,0x4d, 0x1,0x75,0x50, 0x2,0x63,0x59, + 0x2,0x67,0x30, 0x3,0x5f,0x64, 0x2,0x6f,0x52, 0x1,0x4b,0x48, + 0x2,0x33,0x22, 0x1,0x58,0x3f, 0x1,0x5d,0x47, 0x2,0x47,0x5a, + 0x2,0x47,0x59, 0x1,0x6f,0x27, 0x2,0x54,0x4f, 0x1,0x6f,0x28, + 0x2,0x5f,0x5d, 0x1,0x77,0x42, 0x3,0x5d,0x34, 0x3,0x66,0x4d, + 0x3,0x62,0x21, 0x1,0x7d,0x43, 0x1,0x4b,0x49, 0x2,0x28,0x6b, + 0x2,0x33,0x23, 0x3,0x39,0x2d, 0x4,0x35,0x4d, 0x1,0x5d,0x48, + 0x3,0x39,0x2c, 0x2,0x39,0x52, 0x2,0x39,0x53, 0x3,0x3f,0x2a, + 0x2,0x40,0x4b, 0x3,0x3f,0x29, 0x1,0x62,0x2f, 0x1,0x66,0x6d, + 0x3,0x44,0x64, 0x2,0x47,0x5c, 0x2,0x47,0x5b, 0x2,0x47,0x5d, + 0x3,0x49,0x6d, 0x2,0x4e,0x39, 0x2,0x4e,0x3a, 0x1,0x6b,0x30, + 0x1,0x72,0x47, 0x1,0x6f,0x29, 0x1,0x72,0x48, 0x2,0x5f,0x61, + 0x2,0x5f,0x5e, 0x2,0x5f,0x60, 0x2,0x5f,0x5f, 0x1,0x75,0x52, + 0x3,0x59,0x2b, 0x2,0x63,0x5a, 0x2,0x67,0x32, 0x2,0x67,0x31, + 0x2,0x25,0x24, 0x1,0x58,0x41, 0x1,0x58,0x40, 0x2,0x33,0x24, + 0x3,0x39,0x2e, 0x2,0x39,0x54, 0x3,0x3f,0x2c, 0x3,0x3f,0x2b, + 0x2,0x40,0x4d, 0x2,0x40,0x4c, 0x1,0x62,0x30, 0x3,0x3f,0x2d, + 0x2,0x47,0x5f, 0x2,0x47,0x60, 0x2,0x47,0x5e, 0x4,0x40,0x78, + 0x3,0x44,0x65, 0x1,0x66,0x6f, 0x1,0x66,0x6e, 0x4,0x47,0x54, + 0x1,0x6b,0x32, 0x1,0x6b,0x31, 0x3,0x4e,0x7a, 0x2,0x54,0x50, + 0x2,0x5a,0x5f, 0x2,0x5a,0x5d, 0x2,0x5a,0x5e, 0x1,0x72,0x49, + 0x2,0x5f,0x63, 0x2,0x5f,0x62, 0x3,0x56,0x4f, 0x2,0x63,0x5d, + 0x2,0x63,0x5c, 0x2,0x63,0x5b, 0x2,0x67,0x33, 0x3,0x61,0x4d, + 0x2,0x71,0x78, 0x1,0x4b,0x4a, 0x1,0x53,0x56, 0x3,0x2f,0x2e, + 0x1,0x53,0x57, 0x1,0x58,0x42, 0x1,0x58,0x43, 0x2,0x33,0x26, + 0x2,0x33,0x25, 0x2,0x39,0x55, 0x3,0x39,0x30, 0x1,0x5d,0x4e, + 0x1,0x5d,0x4c, 0x1,0x5d,0x49, 0x1,0x5d,0x4d, 0x1,0x5d,0x4b, + 0x1,0x5d,0x4a, 0x3,0x39,0x32, 0x3,0x39,0x31, 0x1,0x62,0x31, + 0x2,0x40,0x50, 0x3,0x3f,0x2f, 0x1,0x66,0x74, 0x1,0x62,0x33, + 0x1,0x62,0x38, 0x2,0x40,0x52, 0x1,0x62,0x3a, 0x1,0x62,0x39, + 0x1,0x62,0x3c, 0x2,0x40,0x51, 0x2,0x40,0x4e, 0x1,0x62,0x36, + 0x1,0x62,0x32, 0x1,0x62,0x34, 0x2,0x40,0x4f, 0x1,0x62,0x3b, + 0x1,0x62,0x37, 0x1,0x62,0x35, 0x1,0x66,0x76, 0x1,0x66,0x75, + 0x1,0x66,0x73, 0x1,0x66,0x77, 0x4,0x40,0x7e, 0x1,0x66,0x71, + 0x1,0x66,0x72, 0x3,0x44,0x69, 0x1,0x66,0x70, 0x5,0x43,0x2d, + 0x2,0x47,0x61, 0x3,0x44,0x67, 0x2,0x4e,0x3c, 0x3,0x49,0x70, + 0x1,0x6b,0x34, 0x1,0x6b,0x35, 0x1,0x6b,0x33, 0x3,0x49,0x72, + 0x2,0x4e,0x3b, 0x3,0x49,0x71, 0x2,0x4e,0x3d, 0x3,0x66,0x4e, + 0x2,0x54,0x53, 0x2,0x54,0x55, 0x3,0x4e,0x7e, 0x1,0x6f,0x32, + 0x2,0x54,0x56, 0x1,0x6f,0x2b, 0x2,0x54,0x52, 0x1,0x6f,0x2a, + 0x1,0x6f,0x34, 0x1,0x6f,0x30, 0x1,0x6f,0x31, 0x1,0x6f,0x2d, + 0x2,0x54,0x51, 0x1,0x6f,0x2c, 0x2,0x54,0x57, 0x2,0x54,0x54, + 0x3,0x4e,0x7d, 0x1,0x6f,0x33, 0x3,0x4f,0x22, 0x1,0x6f,0x2e, + 0x1,0x6f,0x2f, 0x2,0x5a,0x61, 0x3,0x52,0x75, 0x2,0x5a,0x63, + 0x2,0x5a,0x62, 0x3,0x52,0x73, 0x2,0x5a,0x64, 0x1,0x72,0x4a, + 0x2,0x5a,0x60, 0x3,0x56,0x51, 0x3,0x56,0x52, 0x1,0x75,0x56, + 0x2,0x5f,0x64, 0x1,0x75,0x53, 0x1,0x75,0x57, 0x1,0x75,0x55, + 0x1,0x75,0x54, 0x2,0x63,0x5e, 0x4,0x5d,0x69, 0x2,0x63,0x61, + 0x7,0x43,0x52, 0x2,0x63,0x60, 0x3,0x59,0x2e, 0x2,0x63,0x5f, + 0x1,0x77,0x43, 0x2,0x67,0x34, 0x2,0x67,0x35, 0x1,0x79,0x25, + 0x2,0x67,0x36, 0x1,0x79,0x26, 0x3,0x5b,0x38, 0x3,0x66,0x4f, + 0x1,0x7a,0x45, 0x4,0x64,0x4f, 0x1,0x7a,0x44, 0x2,0x6c,0x41, + 0x3,0x5e,0x65, 0x3,0x5e,0x66, 0x1,0x7b,0x2e, 0x2,0x6c,0x42, + 0x2,0x6e,0x2b, 0x1,0x7b,0x75, 0x1,0x7b,0x76, 0x3,0x66,0x50, + 0x2,0x6f,0x53, 0x3,0x60,0x4a, 0x1,0x7c,0x6d, 0x3,0x61,0x4e, + 0x1,0x4b,0x4b, 0x3,0x39,0x33, 0x1,0x5d,0x50, 0x1,0x5d,0x4f, + 0x2,0x47,0x62, 0x2,0x47,0x63, 0x1,0x6b,0x36, 0x2,0x5a,0x65, + 0x1,0x6f,0x35, 0x2,0x5a,0x66, 0x2,0x5f,0x65, 0x1,0x4b,0x4c, + 0x3,0x24,0x3a, 0x2,0x2d,0x53, 0x1,0x53,0x59, 0x1,0x53,0x58, + 0x2,0x33,0x27, 0x1,0x58,0x44, 0x2,0x33,0x28, 0x2,0x39,0x58, + 0x3,0x39,0x39, 0x2,0x39,0x57, 0x3,0x39,0x37, 0x2,0x39,0x56, + 0x3,0x39,0x35, 0x3,0x39,0x38, 0x2,0x40,0x54, 0x1,0x62,0x3f, + 0x3,0x3f,0x39, 0x3,0x3f,0x34, 0x2,0x40,0x53, 0x1,0x62,0x3e, + 0x3,0x3f,0x37, 0x3,0x3f,0x30, 0x3,0x3f,0x33, 0x2,0x40,0x55, + 0x1,0x62,0x3d, 0x3,0x3f,0x38, 0x2,0x47,0x65, 0x2,0x47,0x68, + 0x2,0x47,0x66, 0x2,0x47,0x67, 0x2,0x47,0x6b, 0x2,0x47,0x64, + 0x2,0x47,0x6c, 0x2,0x47,0x69, 0x2,0x47,0x6a, 0x1,0x6b,0x38, + 0x2,0x4e,0x3e, 0x3,0x49,0x75, 0x3,0x49,0x73, 0x1,0x6b,0x37, + 0x3,0x49,0x74, 0x2,0x54,0x5b, 0x2,0x54,0x59, 0x3,0x4f,0x26, + 0x4,0x4d,0x75, 0x1,0x6f,0x36, 0x2,0x54,0x58, 0x2,0x54,0x5a, + 0x3,0x4f,0x25, 0x1,0x6f,0x37, 0x3,0x4f,0x23, 0x2,0x5a,0x67, + 0x3,0x52,0x77, 0x2,0x5a,0x68, 0x1,0x75,0x58, 0x3,0x59,0x31, + 0x2,0x67,0x38, 0x2,0x67,0x3a, 0x2,0x67,0x37, 0x2,0x67,0x39, + 0x2,0x6a,0x24, 0x2,0x6c,0x43, 0x3,0x66,0x51, 0x2,0x71,0x5e, + 0x1,0x4b,0x4d, 0x1,0x53,0x5a, 0x2,0x33,0x29, 0x2,0x33,0x2b, + 0x2,0x33,0x2a, 0x2,0x39,0x5b, 0x1,0x5d,0x52, 0x3,0x39,0x3e, + 0x2,0x39,0x59, 0x3,0x39,0x3a, 0x1,0x5d,0x51, 0x2,0x39,0x5c, + 0x3,0x39,0x3d, 0x2,0x39,0x5d, 0x2,0x39,0x5a, 0x6,0x45,0x38, + 0x2,0x40,0x61, 0x1,0x62,0x47, 0x2,0x40,0x59, 0x2,0x40,0x5f, + 0x3,0x3f,0x3f, 0x3,0x3f,0x3a, 0x1,0x62,0x42, 0x1,0x62,0x45, + 0x2,0x40,0x58, 0x1,0x62,0x40, 0x2,0x40,0x5c, 0x2,0x47,0x72, + 0x1,0x62,0x44, 0x3,0x3f,0x3b, 0x2,0x40,0x57, 0x3,0x3f,0x3e, + 0x2,0x40,0x5d, 0x2,0x40,0x5a, 0x2,0x40,0x60, 0x2,0x40,0x56, + 0x2,0x40,0x5e, 0x1,0x62,0x43, 0x1,0x62,0x46, 0x2,0x40,0x5b, + 0x1,0x62,0x41, 0x1,0x66,0x79, 0x2,0x47,0x6e, 0x1,0x66,0x78, + 0x2,0x47,0x75, 0x2,0x47,0x74, 0x1,0x67,0x21, 0x1,0x67,0x22, + 0x2,0x47,0x76, 0x1,0x66,0x7a, 0x2,0x47,0x73, 0x1,0x66,0x7e, + 0x2,0x47,0x78, 0x2,0x47,0x6f, 0x3,0x44,0x6b, 0x2,0x47,0x71, + 0x1,0x66,0x7b, 0x2,0x47,0x6d, 0x2,0x47,0x70, 0x2,0x47,0x77, + 0x1,0x66,0x7c, 0x2,0x47,0x79, 0x1,0x66,0x7d, 0x1,0x6b,0x39, + 0x2,0x4e,0x43, 0x2,0x4e,0x49, 0x2,0x4e,0x41, 0x2,0x4e,0x4a, + 0x3,0x49,0x7b, 0x2,0x4e,0x40, 0x2,0x4e,0x45, 0x2,0x4e,0x4b, + 0x2,0x4e,0x48, 0x2,0x4e,0x47, 0x2,0x4e,0x46, 0x3,0x49,0x7a, + 0x2,0x4e,0x3f, 0x2,0x4e,0x44, 0x3,0x49,0x79, 0x2,0x4e,0x42, + 0x1,0x6f,0x3c, 0x1,0x6f,0x39, 0x2,0x54,0x64, 0x2,0x54,0x69, + 0x2,0x54,0x6b, 0x2,0x54,0x68, 0x2,0x54,0x61, 0x2,0x54,0x63, + 0x2,0x54,0x6d, 0x2,0x54,0x6a, 0x2,0x54,0x65, 0x2,0x54,0x6e, + 0x2,0x54,0x62, 0x2,0x54,0x6c, 0x1,0x6f,0x3a, 0x1,0x6f,0x40, + 0x1,0x6f,0x3e, 0x2,0x54,0x5c, 0x1,0x6f,0x3f, 0x1,0x6f,0x3b, + 0x2,0x54,0x5d, 0x2,0x54,0x5f, 0x2,0x54,0x5e, 0x2,0x54,0x66, + 0x2,0x54,0x67, 0x3,0x4f,0x2c, 0x1,0x6f,0x3d, 0x3,0x4f,0x2b, + 0x1,0x6f,0x38, 0x2,0x54,0x60, 0x2,0x5a,0x72, 0x1,0x72,0x4c, + 0x3,0x52,0x7e, 0x2,0x5a,0x69, 0x1,0x72,0x4d, 0x1,0x72,0x50, + 0x2,0x5a,0x6e, 0x5,0x51,0x48, 0x2,0x5a,0x6b, 0x1,0x72,0x4f, + 0x4,0x54,0x29, 0x3,0x52,0x7b, 0x2,0x5a,0x6f, 0x2,0x5a,0x70, + 0x2,0x5a,0x6a, 0x2,0x5a,0x73, 0x2,0x5a,0x6c, 0x2,0x5a,0x71, + 0x1,0x72,0x4e, 0x3,0x52,0x7c, 0x1,0x72,0x4b, 0x2,0x5a,0x6d, + 0x3,0x56,0x54, 0x2,0x5f,0x6b, 0x1,0x75,0x5b, 0x1,0x75,0x59, + 0x1,0x75,0x5c, 0x1,0x75,0x5a, 0x2,0x5f,0x6a, 0x2,0x5f,0x67, + 0x2,0x5f,0x66, 0x3,0x56,0x55, 0x2,0x5f,0x69, 0x4,0x59,0x2d, + 0x2,0x5f,0x68, 0x2,0x63,0x6f, 0x1,0x77,0x49, 0x2,0x63,0x66, + 0x2,0x63,0x65, 0x3,0x59,0x32, 0x1,0x77,0x44, 0x2,0x63,0x6b, + 0x2,0x63,0x6a, 0x2,0x63,0x62, 0x2,0x63,0x6d, 0x2,0x63,0x67, + 0x1,0x77,0x48, 0x2,0x63,0x64, 0x2,0x63,0x6c, 0x2,0x63,0x63, + 0x1,0x77,0x45, 0x1,0x77,0x47, 0x2,0x63,0x68, 0x1,0x77,0x46, + 0x2,0x63,0x69, 0x3,0x5b,0x3a, 0x2,0x63,0x6e, 0x2,0x67,0x3e, + 0x3,0x5b,0x39, 0x1,0x79,0x2b, 0x2,0x67,0x3b, 0x4,0x61,0x52, + 0x2,0x67,0x3f, 0x3,0x5b,0x3b, 0x4,0x61,0x4f, 0x1,0x79,0x28, + 0x2,0x67,0x3d, 0x1,0x79,0x2d, 0x3,0x5b,0x3c, 0x1,0x79,0x2a, + 0x3,0x5b,0x3d, 0x2,0x67,0x3c, 0x4,0x61,0x54, 0x1,0x79,0x2c, + 0x2,0x67,0x40, 0x1,0x79,0x27, 0x1,0x7a,0x47, 0x1,0x7a,0x49, + 0x3,0x5d,0x37, 0x2,0x6a,0x27, 0x1,0x7a,0x48, 0x2,0x6a,0x25, + 0x1,0x79,0x29, 0x2,0x6a,0x26, 0x1,0x7a,0x46, 0x1,0x7b,0x2f, + 0x1,0x7b,0x31, 0x2,0x6c,0x45, 0x1,0x7b,0x30, 0x2,0x6c,0x44, + 0x2,0x6e,0x30, 0x1,0x7b,0x77, 0x2,0x6e,0x2f, 0x1,0x7b,0x78, + 0x2,0x6e,0x2d, 0x2,0x6e,0x2c, 0x2,0x6e,0x31, 0x2,0x6e,0x32, + 0x2,0x6f,0x54, 0x3,0x60,0x4b, 0x2,0x6e,0x2e, 0x2,0x70,0x54, + 0x2,0x70,0x51, 0x2,0x70,0x52, 0x2,0x70,0x53, 0x1,0x7d,0x29, + 0x3,0x61,0x50, 0x2,0x71,0x40, 0x2,0x71,0x3f, 0x2,0x71,0x3e, + 0x2,0x71,0x5f, 0x3,0x61,0x6c, 0x2,0x72,0x2e, 0x2,0x71,0x79, + 0x1,0x7d,0x3b, 0x1,0x4b,0x4e, 0x1,0x58,0x45, 0x3,0x39,0x3f, + 0xf,0x38,0x6c, 0x3,0x39,0x40, 0x3,0x3f,0x40, 0x3,0x44,0x73, + 0x1,0x67,0x23, 0x3,0x49,0x7d, 0x3,0x49,0x7c, 0x3,0x4f,0x30, + 0x3,0x4f,0x32, 0x3,0x4f,0x2f, 0x3,0x4f,0x31, 0x1,0x6f,0x41, + 0x3,0x66,0x52, 0x2,0x5a,0x74, 0xf,0x58,0x33, 0x3,0x59,0x35, + 0x1,0x77,0x4a, 0x3,0x59,0x36, 0x2,0x67,0x41, 0x3,0x5b,0x3f, + 0x4,0x61,0x56, 0x3,0x5d,0x38, 0x4,0x67,0x51, 0x2,0x71,0x7a, + 0x1,0x4b,0x4f, 0x1,0x4f,0x51, 0x1,0x53,0x5c, 0x1,0x53,0x5b, + 0x5,0x30,0x55, 0x1,0x58,0x48, 0x3,0x34,0x21, 0x2,0x33,0x2c, + 0x1,0x58,0x46, 0x2,0x33,0x2d, 0x1,0x58,0x47, 0x3,0x66,0x53, + 0x3,0x39,0x41, 0x2,0x39,0x62, 0x2,0x39,0x5e, 0x3,0x39,0x47, + 0x4,0x35,0x63, 0x1,0x5d,0x53, 0x2,0x39,0x61, 0x2,0x39,0x60, + 0x2,0x39,0x5f, 0x1,0x5d,0x54, 0x2,0x39,0x63, 0x2,0x39,0x64, + 0x3,0x3f,0x45, 0x2,0x40,0x68, 0x2,0x40,0x66, 0x2,0x40,0x6a, + 0x2,0x40,0x6b, 0x2,0x40,0x71, 0x3,0x3f,0x47, 0x2,0x40,0x6d, + 0x2,0x40,0x6f, 0x5,0x43,0x50, 0x2,0x40,0x67, 0x2,0x40,0x62, + 0x4,0x3b,0x55, 0x2,0x40,0x6e, 0x3,0x3f,0x44, 0x3,0x3f,0x46, + 0x2,0x40,0x70, 0x2,0x40,0x69, 0x2,0x40,0x6c, 0x2,0x40,0x63, + 0x1,0x62,0x49, 0x2,0x40,0x65, 0x2,0x40,0x64, 0x1,0x62,0x48, + 0x1,0x62,0x4a, 0x3,0x3f,0x49, 0x1,0x67,0x26, 0x2,0x47,0x7b, + 0x2,0x47,0x7d, 0x2,0x47,0x7c, 0x2,0x48,0x23, 0x1,0x67,0x24, + 0x3,0x44,0x76, 0x2,0x47,0x7e, 0x2,0x47,0x7a, 0x2,0x48,0x21, + 0x2,0x48,0x22, 0x1,0x67,0x25, 0x1,0x67,0x27, 0x2,0x48,0x24, + 0x2,0x4e,0x4f, 0x2,0x4e,0x4e, 0x4,0x47,0x6a, 0x2,0x4e,0x4c, + 0x2,0x4e,0x4d, 0x1,0x6b,0x3b, 0x1,0x6b,0x3d, 0x1,0x6b,0x3a, + 0x1,0x6b,0x3c, 0x2,0x54,0x75, 0x2,0x54,0x76, 0x2,0x54,0x71, + 0x3,0x4f,0x36, 0x2,0x54,0x72, 0x1,0x6f,0x43, 0x1,0x6f,0x48, + 0x1,0x6f,0x42, 0x1,0x6f,0x49, 0x1,0x6f,0x44, 0x2,0x54,0x73, + 0x4,0x4e,0x2d, 0x3,0x4f,0x33, 0x2,0x54,0x74, 0x2,0x54,0x70, + 0x1,0x6f,0x4a, 0x1,0x6f,0x46, 0x3,0x4f,0x35, 0x4,0x4e,0x2b, + 0x1,0x6f,0x45, 0x1,0x6f,0x47, 0x3,0x4f,0x34, 0x2,0x54,0x6f, + 0x3,0x53,0x24, 0x2,0x5a,0x76, 0x1,0x72,0x52, 0x3,0x53,0x22, + 0x3,0x53,0x21, 0x2,0x5a,0x78, 0x1,0x72,0x54, 0x2,0x5a,0x7b, + 0x2,0x5a,0x77, 0x2,0x5a,0x75, 0x2,0x5a,0x7a, 0x1,0x72,0x53, + 0x2,0x5a,0x79, 0x7,0x34,0x32, 0x1,0x72,0x51, 0x3,0x53,0x25, + 0x3,0x56,0x59, 0x1,0x75,0x5e, 0x1,0x75,0x61, 0x2,0x5f,0x6d, + 0x3,0x56,0x5a, 0x1,0x75,0x5f, 0x2,0x5f,0x6c, 0x1,0x75,0x5d, + 0x1,0x75,0x60, 0x2,0x63,0x70, 0x2,0x63,0x71, 0x2,0x63,0x72, + 0x1,0x77,0x4b, 0x3,0x59,0x37, 0x2,0x63,0x73, 0x1,0x77,0x4c, + 0x1,0x79,0x2f, 0x2,0x67,0x44, 0x2,0x67,0x45, 0x2,0x67,0x43, + 0x2,0x67,0x42, 0x2,0x67,0x46, 0x1,0x79,0x2e, 0x2,0x6a,0x2b, + 0x2,0x6a,0x29, 0x2,0x6a,0x2a, 0x2,0x6a,0x2c, 0x2,0x6a,0x28, + 0x2,0x6a,0x2d, 0x2,0x6c,0x47, 0x3,0x5e,0x67, 0x2,0x6c,0x48, + 0x2,0x6c,0x46, 0x1,0x7b,0x32, 0x2,0x6e,0x33, 0x1,0x7b,0x79, + 0x2,0x6e,0x34, 0x2,0x6f,0x56, 0x2,0x6f,0x55, 0x3,0x62,0x22, + 0x1,0x4b,0x50, 0x1,0x62,0x4b, 0x3,0x3f,0x4b, 0x3,0x44,0x77, + 0x1,0x67,0x28, 0x3,0x44,0x78, 0x3,0x4a,0x21, 0x3,0x4a,0x22, + 0x1,0x6b,0x3e, 0x3,0x4f,0x37, 0x3,0x53,0x27, 0x1,0x72,0x56, + 0x3,0x53,0x26, 0x1,0x72,0x55, 0x3,0x66,0x54, 0x3,0x59,0x38, + 0x1,0x79,0x30, 0x1,0x7a,0x29, 0x1,0x7b,0x33, 0x1,0x4b,0x51, + 0x1,0x58,0x49, 0x1,0x67,0x29, 0x3,0x4f,0x39, 0x2,0x67,0x47, + 0x3,0x27,0x2f, 0x4,0x21,0x54, 0xf,0x21,0x6a, 0x4,0x23,0x30, + 0x3,0x24,0x3b, 0xf,0x22,0x71, 0xf,0x22,0x72, 0x3,0x27,0x30, + 0x2,0x25,0x26, 0x4,0x25,0x21, 0x3,0x27,0x33, 0x1,0x4b,0x52, + 0x4,0x25,0x23, 0x1,0x4b,0x55, 0x1,0x4b,0x54, 0x1,0x4b,0x53, + 0x3,0x27,0x31, 0xf,0x25,0x32, 0x2,0x25,0x25, 0x3,0x2a,0x72, + 0x2,0x28,0x6d, 0x3,0x2a,0x70, 0x2,0x28,0x6f, 0x1,0x4f,0x52, + 0x3,0x2a,0x74, 0x4,0x28,0x26, 0x1,0x4f,0x54, 0x2,0x28,0x6c, + 0x2,0x28,0x6e, 0x1,0x4f,0x53, 0x2,0x28,0x71, 0x2,0x28,0x70, + 0x2,0x28,0x72, 0x3,0x2a,0x73, 0x3,0x2a,0x71, 0xf,0x28,0x71, + 0xf,0x28,0x6e, 0x2,0x2d,0x57, 0x2,0x2d,0x55, 0x1,0x53,0x5f, + 0x2,0x2d,0x54, 0x1,0x53,0x64, 0x1,0x53,0x61, 0x1,0x53,0x5e, + 0x3,0x2f,0x31, 0x1,0x53,0x65, 0x3,0x2f,0x32, 0x1,0x53,0x60, + 0x1,0x53,0x63, 0x6,0x34,0x60, 0x1,0x53,0x62, 0x2,0x2d,0x56, + 0x3,0x2f,0x33, 0x1,0x53,0x5d, 0x3,0x2f,0x30, 0x1,0x58,0x4f, + 0x2,0x33,0x2f, 0x2,0x33,0x35, 0x1,0x58,0x4c, 0x1,0x58,0x53, + 0x3,0x34,0x25, 0x1,0x58,0x4e, 0x2,0x33,0x32, 0x2,0x33,0x34, + 0x1,0x58,0x51, 0x2,0x33,0x2e, 0x2,0x33,0x31, 0x1,0x58,0x4d, + 0x1,0x58,0x4a, 0x2,0x33,0x30, 0x1,0x58,0x50, 0x2,0x33,0x33, + 0x1,0x58,0x52, 0x1,0x58,0x4b, 0x4,0x30,0x2f, 0x3,0x34,0x27, + 0x3,0x34,0x26, 0x2,0x39,0x66, 0x2,0x39,0x69, 0x1,0x5d,0x56, + 0x3,0x39,0x4b, 0x1,0x5d,0x60, 0x1,0x5d,0x5c, 0x2,0x39,0x67, + 0x3,0x39,0x4a, 0x3,0x39,0x4e, 0x1,0x5d,0x64, 0x1,0x5d,0x5d, + 0x1,0x5d,0x62, 0x1,0x5d,0x58, 0x4,0x35,0x68, 0x1,0x5d,0x55, + 0x1,0x5d,0x57, 0x1,0x5d,0x63, 0x2,0x39,0x68, 0x1,0x5d,0x5b, + 0x1,0x5d,0x5e, 0x1,0x5d,0x5a, 0x1,0x5d,0x5f, 0x2,0x39,0x6a, + 0x1,0x5d,0x61, 0x1,0x5d,0x59, 0x2,0x39,0x65, 0x3,0x39,0x4c, + 0x3,0x3f,0x4f, 0x3,0x3f,0x50, 0x3,0x3f,0x4d, 0x3,0x3f,0x4c, + 0x3,0x3f,0x51, 0x2,0x40,0x72, 0x1,0x62,0x4c, 0x2,0x40,0x74, + 0x3,0x3f,0x55, 0x1,0x62,0x4e, 0x1,0x62,0x50, 0x4,0x35,0x66, + 0x2,0x40,0x73, 0x1,0x62,0x4d, 0x1,0x62,0x51, 0x3,0x3f,0x56, + 0x1,0x62,0x4f, 0x3,0x3f,0x54, 0x3,0x3f,0x57, 0x1,0x67,0x2f, + 0x2,0x48,0x29, 0x1,0x67,0x37, 0x2,0x48,0x26, 0x3,0x44,0x7d, + 0x1,0x67,0x38, 0x1,0x67,0x2d, 0x3,0x44,0x79, 0x2,0x48,0x27, + 0x3,0x44,0x7c, 0x3,0x44,0x7a, 0x1,0x67,0x32, 0x3,0x44,0x7b, + 0x2,0x48,0x28, 0x1,0x67,0x2b, 0x1,0x67,0x2a, 0x3,0x44,0x7e, + 0x1,0x67,0x35, 0x1,0x67,0x34, 0x1,0x67,0x33, 0x1,0x67,0x31, + 0x1,0x67,0x36, 0x2,0x48,0x25, 0x1,0x67,0x2c, 0x1,0x67,0x2e, + 0x1,0x67,0x30, 0x1,0x6b,0x40, 0x1,0x6b,0x43, 0x3,0x4a,0x24, + 0x1,0x6b,0x47, 0x1,0x6b,0x41, 0x1,0x6b,0x46, 0x1,0x6b,0x44, + 0x3,0x4a,0x27, 0x1,0x6b,0x3f, 0x3,0x4a,0x26, 0x1,0x6b,0x45, + 0x1,0x6b,0x42, 0xf,0x4c,0x6b, 0x4,0x4e,0x32, 0x2,0x54,0x7a, + 0x1,0x6f,0x4d, 0x1,0x6f,0x4b, 0x3,0x4f,0x3c, 0x2,0x54,0x7b, + 0x4,0x4e,0x33, 0x1,0x6f,0x4e, 0x1,0x6f,0x4c, 0x2,0x54,0x79, + 0x2,0x54,0x78, 0x3,0x4f,0x3b, 0x1,0x72,0x5a, 0x2,0x54,0x77, + 0x1,0x72,0x58, 0x1,0x72,0x57, 0x2,0x5a,0x7c, 0x1,0x6f,0x4f, + 0x1,0x72,0x59, 0x2,0x5a,0x7d, 0x1,0x72,0x5c, 0x2,0x5a,0x7e, + 0x1,0x72,0x5b, 0x1,0x75,0x63, 0x2,0x5f,0x6f, 0x1,0x75,0x62, + 0x1,0x75,0x67, 0x1,0x75,0x65, 0x1,0x75,0x66, 0x1,0x77,0x4e, + 0x1,0x75,0x64, 0x2,0x5f,0x6e, 0x2,0x5b,0x21, 0x1,0x77,0x4d, + 0x1,0x77,0x4f, 0x3,0x59,0x3a, 0x1,0x79,0x31, 0x1,0x79,0x32, + 0x4,0x61,0x5f, 0x2,0x6a,0x2e, 0x4,0x69,0x52, 0x1,0x7c,0x4a, + 0x1,0x7c,0x49, 0x1,0x4b,0x57, 0x3,0x22,0x5e, 0x3,0x22,0x5d, + 0x2,0x22,0x75, 0x1,0x58,0x54, 0x3,0x24,0x3c, 0x2,0x22,0x72, + 0x2,0x22,0x73, 0x2,0x22,0x71, 0x3,0x24,0x3d, 0x2,0x22,0x74, + 0x3,0x66,0x55, 0x2,0x25,0x2a, 0x2,0x25,0x27, 0x2,0x25,0x2c, + 0x2,0x25,0x28, 0x1,0x4b,0x58, 0x1,0x4b,0x5b, 0x3,0x27,0x35, + 0x2,0x25,0x29, 0x1,0x4b,0x5a, 0x2,0x25,0x2b, 0x3,0x27,0x39, + 0x3,0x27,0x34, 0x1,0x4b,0x59, 0x3,0x39,0x51, 0x3,0x2a,0x77, + 0x4,0x28,0x2b, 0x2,0x28,0x75, 0x2,0x28,0x77, 0x1,0x4f,0x57, + 0x2,0x28,0x73, 0x2,0x28,0x76, 0x2,0x28,0x74, 0x1,0x4f,0x55, + 0x1,0x4f,0x58, 0x3,0x2a,0x75, 0x1,0x4f,0x56, 0x3,0x2a,0x78, + 0x3,0x2f,0x35, 0x2,0x2d,0x59, 0x2,0x2d,0x5d, 0x2,0x2d,0x5a, + 0x3,0x2f,0x38, 0x1,0x53,0x68, 0x3,0x2f,0x34, 0x1,0x53,0x69, + 0x3,0x2f,0x3e, 0x2,0x2d,0x5c, 0x3,0x2f,0x37, 0x2,0x2d,0x5e, + 0x2,0x2d,0x60, 0x3,0x2f,0x3c, 0x1,0x53,0x66, 0x2,0x2d,0x5f, + 0x4,0x41,0x39, 0x3,0x2f,0x3b, 0x1,0x53,0x67, 0xf,0x45,0x6d, + 0x2,0x39,0x71, 0x2,0x2d,0x5b, 0x2,0x33,0x36, 0x2,0x33,0x3f, + 0x2,0x33,0x3d, 0x2,0x33,0x38, 0x2,0x33,0x39, 0x2,0x33,0x3e, + 0x2,0x33,0x40, 0x1,0x58,0x56, 0x3,0x34,0x29, 0x2,0x33,0x3b, + 0x2,0x33,0x37, 0x1,0x58,0x55, 0x1,0x58,0x57, 0x2,0x33,0x3a, + 0x2,0x33,0x41, 0x2,0x33,0x3c, 0x1,0x5d,0x65, 0x2,0x39,0x74, + 0x2,0x39,0x6c, 0x2,0x39,0x72, 0x2,0x39,0x73, 0x1,0x5d,0x66, + 0x3,0x39,0x4f, 0x2,0x39,0x6b, 0x2,0x39,0x6d, 0x2,0x2d,0x58, + 0x2,0x39,0x6f, 0x2,0x39,0x70, 0x2,0x39,0x6e, 0x1,0x62,0x53, + 0x4,0x4e,0x3b, 0x3,0x39,0x52, 0x2,0x40,0x7b, 0x2,0x5b,0x22, + 0x2,0x40,0x7c, 0x2,0x40,0x79, 0x1,0x5d,0x67, 0x1,0x62,0x55, + 0x2,0x40,0x78, 0x2,0x40,0x7e, 0x2,0x40,0x7d, 0x1,0x62,0x52, + 0x2,0x41,0x23, 0x2,0x40,0x77, 0x2,0x41,0x22, 0x2,0x40,0x75, + 0x2,0x41,0x21, 0x2,0x40,0x7a, 0x1,0x62,0x54, 0x3,0x3f,0x59, + 0x2,0x48,0x30, 0x3,0x45,0x23, 0x2,0x48,0x2b, 0x2,0x48,0x31, + 0x2,0x48,0x2c, 0x2,0x48,0x2a, 0x2,0x48,0x2d, 0x1,0x67,0x39, + 0x3,0x45,0x24, 0x2,0x48,0x2f, 0x3,0x45,0x25, 0x2,0x48,0x2e, + 0x1,0x67,0x3a, 0x1,0x6b,0x49, 0x1,0x6b,0x48, 0x2,0x4e,0x56, + 0x2,0x4e,0x59, 0x2,0x4e,0x51, 0x2,0x4e,0x55, 0x1,0x6b,0x4a, + 0x2,0x4e,0x54, 0x2,0x4e,0x52, 0x2,0x4e,0x58, 0x2,0x4e,0x53, + 0x2,0x4e,0x50, 0x2,0x4e,0x57, 0x3,0x4a,0x2a, 0x2,0x55,0x23, + 0x1,0x6f,0x52, 0x2,0x63,0x74, 0x2,0x54,0x7e, 0x2,0x55,0x21, + 0x2,0x54,0x7d, 0x2,0x40,0x76, 0x1,0x6f,0x51, 0x2,0x55,0x24, + 0x2,0x54,0x7c, 0x1,0x6f,0x50, 0x1,0x6f,0x53, 0x2,0x55,0x22, + 0x2,0x5b,0x23, 0x1,0x72,0x5d, 0x2,0x5b,0x24, 0x2,0x5b,0x25, + 0x3,0x53,0x2b, 0x2,0x5f,0x70, 0x1,0x75,0x68, 0x2,0x63,0x75, + 0x2,0x63,0x76, 0x3,0x59,0x3c, 0x3,0x59,0x3b, 0x2,0x63,0x77, + 0x2,0x67,0x49, 0x2,0x67,0x48, 0x2,0x6a,0x30, 0x2,0x6a,0x2f, + 0x2,0x6c,0x4a, 0x2,0x6c,0x4b, 0x2,0x6c,0x49, 0x2,0x6e,0x35, + 0x1,0x7b,0x7a, 0x1,0x4b,0x5c, 0x1,0x53,0x6b, 0x1,0x53,0x6a, + 0x1,0x58,0x5a, 0x1,0x58,0x59, 0x2,0x33,0x43, 0x2,0x33,0x44, + 0x2,0x33,0x42, 0x3,0x34,0x2a, 0x1,0x58,0x58, 0x2,0x39,0x78, + 0x3,0x39,0x55, 0x2,0x39,0x79, 0x2,0x39,0x75, 0x1,0x5d,0x68, + 0x2,0x39,0x76, 0x3,0x39,0x54, 0x2,0x39,0x77, 0x3,0x66,0x57, + 0x2,0x41,0x26, 0x2,0x41,0x28, 0x2,0x41,0x24, 0x2,0x41,0x27, + 0x1,0x62,0x56, 0x2,0x41,0x25, 0x1,0x62,0x57, 0x3,0x45,0x28, + 0x2,0x42,0x79, 0x1,0x67,0x3d, 0x1,0x67,0x3c, 0x3,0x45,0x27, + 0x1,0x67,0x3b, 0x4,0x41,0x3a, 0x2,0x48,0x32, 0x2,0x48,0x33, + 0x4,0x41,0x3b, 0x2,0x4e,0x5b, 0x2,0x4e,0x5d, 0x1,0x6b,0x4e, + 0x1,0x6b,0x4b, 0x3,0x4a,0x2c, 0x1,0x6b,0x4d, 0x1,0x6b,0x4c, + 0x2,0x4e,0x5c, 0x2,0x4e,0x5a, 0x3,0x4a,0x2b, 0x3,0x4a,0x2d, + 0x2,0x55,0x2b, 0x2,0x55,0x28, 0x2,0x55,0x29, 0x1,0x6f,0x57, + 0x2,0x55,0x2a, 0x2,0x55,0x25, 0x2,0x55,0x26, 0x1,0x6f,0x54, + 0x3,0x4f,0x3f, 0x1,0x6f,0x55, 0x2,0x55,0x27, 0x1,0x6f,0x56, + 0x3,0x4f,0x40, 0x2,0x5b,0x29, 0x3,0x53,0x2d, 0x2,0x5b,0x2a, + 0x2,0x5b,0x27, 0x2,0x5b,0x28, 0x1,0x72,0x5e, 0x2,0x5b,0x26, + 0x4,0x54,0x42, 0x3,0x53,0x2c, 0x3,0x53,0x2f, 0x4,0x59,0x3f, + 0x2,0x5f,0x74, 0x2,0x5f,0x71, 0x2,0x5f,0x73, 0x1,0x75,0x6b, + 0x2,0x5f,0x77, 0x1,0x75,0x6a, 0x2,0x5f,0x75, 0x2,0x5f,0x78, + 0x2,0x5f,0x76, 0x2,0x5f,0x72, 0x1,0x75,0x69, 0x2,0x63,0x79, + 0x4,0x5e,0x24, 0x2,0x63,0x7a, 0x2,0x63,0x78, 0x3,0x59,0x3d, + 0x2,0x63,0x7c, 0x1,0x77,0x50, 0x1,0x77,0x51, 0x2,0x67,0x4b, + 0x1,0x79,0x34, 0x2,0x63,0x7b, 0x2,0x67,0x4a, 0x1,0x79,0x33, + 0x2,0x6a,0x33, 0x2,0x6a,0x34, 0x1,0x7a,0x4a, 0x2,0x6a,0x32, + 0x4,0x64,0x65, 0x2,0x6a,0x31, 0x2,0x6c,0x4c, 0x1,0x7b,0x34, + 0x3,0x5e,0x68, 0x2,0x6f,0x57, 0x2,0x70,0x56, 0x2,0x70,0x55, + 0x3,0x60,0x7e, 0x1,0x7c,0x6e, 0x1,0x7d,0x2a, 0x2,0x70,0x57, + 0x2,0x71,0x60, 0x3,0x61,0x6d, 0x1,0x7d,0x3c, 0x1,0x4b,0x5d, + 0x1,0x4f,0x59, 0x1,0x67,0x3e, 0x1,0x7a,0x4b, 0x1,0x4b,0x5e, + 0x1,0x53,0x6c, 0x1,0x5d,0x69, 0x1,0x62,0x58, 0x1,0x77,0x52, + 0x1,0x4f,0x5a, 0x2,0x2d,0x62, 0x2,0x2d,0x61, 0x2,0x33,0x45, + 0x3,0x34,0x30, 0x1,0x58,0x5d, 0x1,0x58,0x5b, 0x1,0x58,0x5f, + 0x2,0x33,0x47, 0x3,0x34,0x2d, 0x1,0x58,0x5e, 0x1,0x58,0x5c, + 0x3,0x34,0x2f, 0x3,0x34,0x2e, 0x3,0x34,0x31, 0x2,0x33,0x46, + 0x1,0x5d,0x6c, 0x2,0x3a,0x21, 0x3,0x39,0x58, 0x1,0x5d,0x6b, + 0x1,0x5d,0x6d, 0x2,0x3a,0x26, 0x1,0x5d,0x6f, 0x2,0x3a,0x23, + 0x2,0x3a,0x24, 0x2,0x39,0x7a, 0x1,0x5d,0x6e, 0x2,0x3a,0x27, + 0x4,0x35,0x7b, 0x3,0x39,0x57, 0x2,0x39,0x7c, 0x3,0x39,0x56, + 0x2,0x39,0x7d, 0x2,0x39,0x7b, 0x1,0x5d,0x6a, 0x3,0x39,0x59, + 0x2,0x3a,0x25, 0x2,0x39,0x7e, 0x2,0x3a,0x22, 0x2,0x41,0x34, + 0x3,0x3f,0x5d, 0x2,0x41,0x33, 0x2,0x41,0x31, 0x2,0x41,0x29, + 0x2,0x41,0x38, 0x2,0x41,0x2c, 0x2,0x41,0x36, 0x2,0x41,0x3d, + 0x2,0x41,0x35, 0x1,0x62,0x60, 0x3,0x3f,0x66, 0x1,0x62,0x5c, + 0x2,0x41,0x2a, 0x3,0x3f,0x60, 0x2,0x41,0x30, 0x1,0x62,0x5e, + 0x3,0x3f,0x68, 0x2,0x41,0x2f, 0x1,0x62,0x5f, 0x1,0x62,0x61, + 0x2,0x41,0x32, 0x3,0x3f,0x69, 0x1,0x62,0x59, 0x1,0x62,0x5a, + 0x2,0x41,0x3e, 0x2,0x41,0x3c, 0x3,0x3f,0x62, 0x2,0x41,0x3b, + 0x2,0x41,0x2d, 0x3,0x3f,0x65, 0x2,0x41,0x39, 0x4,0x3b,0x66, + 0x1,0x62,0x5d, 0x6,0x4f,0x6f, 0x3,0x3f,0x5e, 0x3,0x66,0x59, + 0x3,0x3f,0x63, 0x1,0x62,0x5b, 0x2,0x41,0x3a, 0x2,0x41,0x2b, + 0x2,0x41,0x2e, 0x2,0x41,0x37, 0x3,0x66,0x58, 0x2,0x4f,0x22, + 0x2,0x48,0x3d, 0x3,0x45,0x2e, 0x2,0x48,0x36, 0x2,0x48,0x49, + 0x2,0x48,0x52, 0x2,0x48,0x39, 0x1,0x67,0x49, 0x3,0x45,0x2b, + 0x2,0x48,0x46, 0x1,0x67,0x3f, 0x1,0x67,0x41, 0x1,0x67,0x4d, + 0x2,0x48,0x37, 0x3,0x45,0x37, 0x3,0x45,0x2f, 0x1,0x67,0x42, + 0x1,0x67,0x44, 0x1,0x67,0x4e, 0x1,0x67,0x43, 0x3,0x45,0x39, + 0x4,0x41,0x41, 0x4,0x41,0x46, 0x3,0x45,0x38, 0x1,0x67,0x4c, + 0x2,0x48,0x3f, 0x4,0x41,0x48, 0x2,0x48,0x34, 0x1,0x67,0x4a, + 0x2,0x48,0x3e, 0x1,0x67,0x46, 0x2,0x48,0x50, 0x1,0x67,0x4b, + 0x2,0x48,0x4e, 0x2,0x48,0x42, 0x2,0x48,0x4c, 0x1,0x67,0x48, + 0x2,0x48,0x35, 0x2,0x48,0x4f, 0x2,0x48,0x4a, 0x3,0x45,0x2a, + 0x2,0x48,0x51, 0x1,0x67,0x40, 0x4,0x41,0x40, 0x3,0x45,0x2d, + 0x1,0x67,0x4f, 0x1,0x67,0x45, 0x3,0x45,0x31, 0x3,0x45,0x29, + 0x2,0x48,0x3b, 0x3,0x45,0x34, 0x2,0x48,0x43, 0x2,0x48,0x47, + 0x3,0x45,0x33, 0x2,0x48,0x4b, 0x1,0x67,0x47, 0x2,0x48,0x3a, + 0x2,0x48,0x38, 0x2,0x48,0x44, 0x4,0x41,0x42, 0x4,0x41,0x43, + 0x3,0x45,0x32, 0x3,0x45,0x35, 0x2,0x48,0x41, 0x2,0x48,0x40, + 0x3,0x45,0x36, 0x2,0x48,0x45, 0x2,0x48,0x48, 0x2,0x48,0x4d, + 0x3,0x66,0x5a, 0xf,0x45,0x72, 0x4,0x47,0x75, 0x2,0x4e,0x60, + 0xf,0x4d,0x22, 0x1,0x6b,0x4f, 0x2,0x4e,0x6a, 0x2,0x4e,0x62, + 0x1,0x6b,0x55, 0x1,0x6b,0x59, 0x2,0x4e,0x73, 0x2,0x4e,0x7b, + 0x2,0x4e,0x6c, 0x1,0x6b,0x51, 0x3,0x4a,0x34, 0x2,0x4e,0x70, + 0x2,0x48,0x3c, 0x3,0x4a,0x35, 0x1,0x6b,0x52, 0x2,0x4e,0x77, + 0x2,0x4e,0x7c, 0x2,0x4e,0x74, 0x3,0x4a,0x2f, 0x2,0x4e,0x76, + 0x2,0x4f,0x21, 0x2,0x4e,0x78, 0x2,0x4e,0x66, 0x2,0x4e,0x6f, + 0x3,0x45,0x30, 0x3,0x4a,0x38, 0x1,0x6b,0x5a, 0x3,0x4a,0x33, + 0x1,0x6b,0x56, 0x2,0x4e,0x64, 0x2,0x4e,0x71, 0x1,0x6b,0x54, + 0x2,0x4e,0x6b, 0x1,0x6b,0x53, 0x2,0x4e,0x79, 0x2,0x4e,0x68, + 0x2,0x4e,0x61, 0x1,0x6b,0x57, 0x2,0x4e,0x7e, 0x3,0x4a,0x39, + 0x4,0x47,0x77, 0x2,0x4e,0x63, 0x2,0x4e,0x75, 0x2,0x4e,0x72, + 0x2,0x4e,0x6d, 0x2,0x4e,0x5f, 0x2,0x4e,0x5e, 0x2,0x4e,0x67, + 0x2,0x4e,0x7a, 0x1,0x6b,0x58, 0x2,0x4e,0x7d, 0x2,0x4e,0x65, + 0x2,0x4e,0x69, 0x1,0x6b,0x50, 0x3,0x4a,0x32, 0x3,0x4a,0x37, + 0xf,0x4d,0x27, 0x3,0x67,0x2a, 0x3,0x4a,0x31, 0x1,0x6f,0x63, + 0x1,0x6f,0x5e, 0x2,0x55,0x4d, 0x2,0x55,0x49, 0x2,0x55,0x31, + 0x1,0x6f,0x5a, 0x3,0x4f,0x42, 0x3,0x4f,0x50, 0x4,0x4e,0x45, + 0x1,0x6f,0x59, 0x1,0x6f,0x5f, 0x4,0x4e,0x47, 0x3,0x4f,0x43, + 0x3,0x4f,0x41, 0x2,0x55,0x2f, 0x1,0x6f,0x5d, 0x2,0x55,0x3b, + 0x2,0x55,0x2d, 0x2,0x55,0x2e, 0x1,0x6f,0x58, 0x2,0x55,0x4c, + 0x1,0x6f,0x61, 0x2,0x55,0x3e, 0x2,0x55,0x43, 0x2,0x55,0x3d, + 0x2,0x5b,0x3c, 0x2,0x55,0x39, 0x2,0x55,0x41, 0x2,0x55,0x3f, + 0x2,0x55,0x32, 0x2,0x55,0x2c, 0x2,0x55,0x47, 0x1,0x6f,0x60, + 0x2,0x55,0x48, 0x3,0x4f,0x48, 0x2,0x55,0x42, 0x3,0x4f,0x49, + 0x2,0x55,0x37, 0x2,0x55,0x35, 0x2,0x55,0x30, 0x3,0x4f,0x4b, + 0x3,0x4f,0x4e, 0x3,0x4f,0x44, 0x2,0x55,0x38, 0x2,0x55,0x45, + 0x2,0x55,0x34, 0x2,0x55,0x44, 0x2,0x55,0x4a, 0x3,0x4f,0x51, + 0x4,0x4e,0x46, 0x1,0x6f,0x5c, 0x3,0x4f,0x45, 0x2,0x55,0x40, + 0x2,0x55,0x46, 0x2,0x55,0x3c, 0x2,0x55,0x36, 0x1,0x6f,0x5b, + 0x3,0x4f,0x52, 0x4,0x4e,0x44, 0x3,0x4f,0x4c, 0x2,0x4e,0x6e, + 0x2,0x55,0x3a, 0x1,0x6f,0x62, 0x2,0x55,0x33, 0xf,0x52,0x6b, + 0x3,0x4f,0x4d, 0x3,0x66,0x5b, 0x3,0x66,0x5c, 0x3,0x4a,0x30, + 0x2,0x5b,0x41, 0x1,0x72,0x61, 0x2,0x5b,0x40, 0x2,0x5b,0x3e, + 0x2,0x5b,0x50, 0x1,0x72,0x65, 0x3,0x53,0x35, 0x2,0x5b,0x4d, + 0x2,0x5b,0x45, 0x2,0x5b,0x4f, 0x2,0x5b,0x37, 0x2,0x5b,0x43, + 0x3,0x53,0x3d, 0x1,0x72,0x67, 0x3,0x53,0x3e, 0x2,0x5b,0x2f, + 0x3,0x53,0x38, 0x2,0x5b,0x2d, 0x2,0x5b,0x4e, 0x3,0x53,0x32, + 0x2,0x5b,0x4c, 0x2,0x5b,0x4b, 0x2,0x5b,0x3b, 0x2,0x5b,0x3a, + 0x2,0x5b,0x30, 0x1,0x72,0x69, 0x4,0x54,0x43, 0x2,0x5b,0x36, + 0x2,0x5b,0x3f, 0x2,0x5b,0x4a, 0x1,0x72,0x6c, 0x2,0x5b,0x51, + 0x3,0x53,0x36, 0x1,0x75,0x73, 0x1,0x72,0x6e, 0x1,0x72,0x68, + 0x2,0x5b,0x34, 0x3,0x53,0x37, 0x2,0x5b,0x3d, 0x2,0x5b,0x2c, + 0x2,0x5b,0x2e, 0x1,0x72,0x5f, 0x1,0x72,0x6b, 0x1,0x72,0x64, + 0x2,0x5b,0x35, 0x2,0x5b,0x44, 0x2,0x55,0x4b, 0x1,0x72,0x6a, + 0x2,0x5b,0x2b, 0x1,0x75,0x6e, 0x2,0x5b,0x46, 0x2,0x5b,0x49, + 0x1,0x72,0x66, 0x3,0x53,0x3b, 0x2,0x5b,0x39, 0x1,0x72,0x6d, + 0x1,0x72,0x63, 0x3,0x53,0x3c, 0x3,0x53,0x39, 0x3,0x53,0x3a, + 0x1,0x72,0x62, 0x2,0x5b,0x42, 0x2,0x5b,0x48, 0x1,0x72,0x60, + 0x4,0x54,0x45, 0x2,0x5b,0x32, 0x2,0x5b,0x47, 0xf,0x58,0x59, + 0xf,0x58,0x48, 0x2,0x5b,0x33, 0x7,0x34,0x63, 0x3,0x66,0x5d, + 0xf,0x58,0x55, 0x3,0x66,0x5e, 0x4,0x54,0x49, 0x3,0x53,0x31, + 0x2,0x5b,0x38, 0x2,0x5f,0x7e, 0x3,0x56,0x65, 0x2,0x60,0x25, + 0x1,0x75,0x70, 0x1,0x75,0x72, 0x2,0x60,0x2b, 0x1,0x75,0x6c, + 0x2,0x60,0x39, 0x2,0x60,0x31, 0x2,0x60,0x26, 0x2,0x60,0x27, + 0x2,0x60,0x30, 0x3,0x56,0x66, 0x1,0x75,0x79, 0x2,0x60,0x2f, + 0x2,0x5f,0x7d, 0x2,0x60,0x2e, 0x2,0x60,0x22, 0x2,0x60,0x3a, + 0x1,0x75,0x78, 0x1,0x75,0x76, 0x2,0x60,0x23, 0x3,0x56,0x5d, + 0x2,0x60,0x36, 0x3,0x56,0x67, 0x2,0x60,0x28, 0x2,0x60,0x35, + 0x3,0x56,0x64, 0x2,0x60,0x37, 0x2,0x5f,0x7c, 0x1,0x75,0x71, + 0x3,0x56,0x5b, 0x2,0x60,0x38, 0x3,0x56,0x68, 0x3,0x56,0x5e, + 0x2,0x60,0x2c, 0x3,0x56,0x6b, 0x1,0x75,0x75, 0x2,0x60,0x29, + 0x3,0x56,0x61, 0x4,0x59,0x49, 0x1,0x75,0x77, 0x2,0x60,0x32, + 0x3,0x56,0x62, 0x3,0x56,0x63, 0x3,0x56,0x5f, 0x1,0x75,0x6f, + 0x2,0x60,0x24, 0x2,0x60,0x33, 0x3,0x56,0x5c, 0x2,0x60,0x2d, + 0x2,0x5b,0x31, 0x2,0x60,0x34, 0x2,0x60,0x21, 0x3,0x56,0x60, + 0x1,0x75,0x74, 0x3,0x56,0x6a, 0x2,0x64,0x2f, 0x4,0x59,0x47, + 0x1,0x75,0x6d, 0x2,0x5f,0x7a, 0x4,0x59,0x46, 0xf,0x5d,0x41, + 0x3,0x66,0x5f, 0xf,0x5d,0x39, 0x2,0x64,0x2c, 0x2,0x64,0x25, + 0x1,0x77,0x54, 0x3,0x59,0x43, 0x2,0x63,0x7e, 0x2,0x64,0x30, + 0x2,0x64,0x27, 0x2,0x60,0x2a, 0x3,0x59,0x40, 0x2,0x64,0x32, + 0x2,0x64,0x21, 0x3,0x59,0x42, 0x1,0x77,0x53, 0x2,0x64,0x2b, + 0x1,0x77,0x55, 0x1,0x77,0x5d, 0x1,0x77,0x5b, 0x2,0x64,0x2d, + 0x1,0x77,0x5c, 0x2,0x64,0x23, 0x3,0x59,0x49, 0x2,0x64,0x24, + 0x2,0x64,0x29, 0x2,0x64,0x2e, 0x3,0x59,0x3e, 0x2,0x5f,0x79, + 0x1,0x77,0x56, 0x2,0x64,0x37, 0x2,0x64,0x34, 0x2,0x67,0x61, + 0x2,0x64,0x2a, 0x2,0x64,0x26, 0x2,0x64,0x35, 0x2,0x67,0x56, + 0x2,0x64,0x28, 0x4,0x5e,0x31, 0x1,0x77,0x59, 0x3,0x59,0x44, + 0x1,0x77,0x58, 0x2,0x5f,0x7b, 0x1,0x77,0x5a, 0x2,0x64,0x31, + 0x2,0x64,0x33, 0x1,0x77,0x57, 0x2,0x64,0x36, 0x2,0x63,0x7d, + 0x4,0x5e,0x29, 0x2,0x64,0x22, 0x3,0x59,0x46, 0xf,0x61,0x33, + 0x3,0x59,0x45, 0x3,0x66,0x61, 0x3,0x66,0x62, 0x3,0x66,0x60, + 0xf,0x61,0x43, 0x2,0x67,0x5f, 0x3,0x5b,0x50, 0x2,0x67,0x4f, + 0x1,0x79,0x38, 0x2,0x67,0x5d, 0x3,0x5b,0x44, 0x3,0x5b,0x45, + 0x2,0x67,0x4d, 0x1,0x79,0x39, 0x4,0x61,0x67, 0x2,0x67,0x58, + 0x3,0x5b,0x43, 0x2,0x67,0x54, 0x1,0x79,0x3e, 0x2,0x67,0x5e, + 0x2,0x67,0x4e, 0x2,0x67,0x51, 0x1,0x79,0x36, 0x2,0x67,0x60, + 0x3,0x5b,0x48, 0x2,0x67,0x59, 0x2,0x67,0x5c, 0x1,0x79,0x3c, + 0x1,0x79,0x41, 0x1,0x79,0x3f, 0x2,0x67,0x55, 0x2,0x67,0x50, + 0x3,0x5b,0x4d, 0x1,0x79,0x3a, 0x1,0x79,0x3b, 0x2,0x67,0x4c, + 0x1,0x79,0x37, 0x3,0x5b,0x4f, 0x1,0x79,0x35, 0x1,0x79,0x3d, + 0x2,0x67,0x5b, 0x1,0x79,0x40, 0x3,0x5b,0x4a, 0x2,0x67,0x57, + 0x2,0x67,0x62, 0x1,0x79,0x42, 0x3,0x5b,0x41, 0x3,0x5b,0x42, + 0x3,0x5b,0x4e, 0x2,0x67,0x53, 0x3,0x5b,0x47, 0x2,0x67,0x5a, + 0x3,0x66,0x65, 0x3,0x66,0x63, 0x3,0x66,0x64, 0x3,0x5d,0x41, + 0x3,0x5e,0x6a, 0x2,0x6a,0x41, 0x2,0x6a,0x50, 0x2,0x6a,0x43, + 0x2,0x6a,0x4a, 0x2,0x67,0x52, 0x2,0x6a,0x48, 0x2,0x6a,0x37, + 0x2,0x6a,0x4e, 0x1,0x7a,0x4e, 0x2,0x6a,0x3b, 0x2,0x6a,0x4d, + 0x2,0x6a,0x42, 0x4,0x64,0x67, 0x3,0x5d,0x43, 0x1,0x7a,0x4d, + 0x3,0x5d,0x3c, 0x3,0x5d,0x3f, 0x2,0x6a,0x52, 0x2,0x6a,0x44, + 0x3,0x5d,0x3e, 0x2,0x6a,0x49, 0x2,0x6a,0x4c, 0x2,0x6a,0x35, + 0x2,0x6a,0x4f, 0x2,0x6a,0x40, 0x2,0x6a,0x45, 0x2,0x6a,0x39, + 0x2,0x6a,0x3d, 0x2,0x6a,0x51, 0x2,0x6a,0x47, 0x2,0x6a,0x36, + 0x2,0x6a,0x3a, 0x2,0x6a,0x3c, 0x2,0x6a,0x46, 0x3,0x5d,0x3d, + 0x1,0x7a,0x4c, 0x2,0x6a,0x3f, 0x3,0x5d,0x44, 0x3,0x5d,0x45, + 0x3,0x5d,0x47, 0x4,0x64,0x6b, 0x3,0x5d,0x42, 0x3,0x5d,0x3a, + 0x2,0x6a,0x38, 0x3,0x66,0x66, 0x3,0x66,0x67, 0x3,0x66,0x68, + 0xf,0x66,0x57, 0x3,0x5d,0x46, 0x2,0x6a,0x3e, 0x2,0x6c,0x50, + 0x2,0x6c,0x54, 0x1,0x7b,0x3b, 0x2,0x6c,0x56, 0x3,0x5e,0x6d, + 0x1,0x7b,0x35, 0x4,0x64,0x6f, 0x2,0x6c,0x52, 0x2,0x6c,0x58, + 0x1,0x7b,0x3a, 0x1,0x7b,0x36, 0x4,0x67,0x5c, 0x1,0x7b,0x37, + 0x2,0x6c,0x4f, 0x2,0x6c,0x55, 0x1,0x7b,0x39, 0x2,0x6c,0x53, + 0x1,0x7b,0x38, 0x2,0x6c,0x4e, 0x2,0x6a,0x4b, 0x2,0x6c,0x51, + 0x4,0x67,0x62, 0x2,0x6c,0x4d, 0x2,0x6c,0x57, 0x3,0x5f,0x69, + 0x3,0x5f,0x6e, 0x1,0x7b,0x7b, 0x2,0x6e,0x3c, 0x2,0x6e,0x3f, + 0x2,0x6e,0x3b, 0x2,0x6e,0x3d, 0x2,0x6e,0x3e, 0x2,0x6e,0x38, + 0x2,0x6e,0x39, 0x2,0x6e,0x36, 0x3,0x5f,0x6a, 0x3,0x5f,0x6c, + 0x2,0x6e,0x3a, 0x2,0x6e,0x37, 0x1,0x7b,0x7c, 0x1,0x7b,0x7d, + 0x3,0x5f,0x6b, 0x2,0x6f,0x59, 0x3,0x60,0x52, 0x2,0x6f,0x5b, + 0x4,0x6b,0x29, 0x5,0x76,0x5d, 0x3,0x60,0x55, 0x3,0x60,0x54, + 0x3,0x60,0x56, 0x2,0x6f,0x5a, 0x2,0x6f,0x5c, 0x3,0x60,0x4f, + 0x1,0x7c,0x4c, 0x3,0x60,0x53, 0x2,0x6f,0x58, 0x1,0x7c,0x4b, + 0x1,0x7c,0x4d, 0x3,0x60,0x57, 0x3,0x66,0x6a, 0x3,0x66,0x69, + 0x2,0x70,0x59, 0x2,0x70,0x5a, 0x1,0x7c,0x6f, 0x2,0x70,0x58, + 0x3,0x61,0x22, 0x2,0x71,0x42, 0x2,0x71,0x41, 0x2,0x71,0x43, + 0x1,0x7d,0x2c, 0x2,0x71,0x44, 0x1,0x7d,0x2b, 0x2,0x71,0x45, + 0x2,0x71,0x61, 0x2,0x71,0x64, 0x2,0x71,0x63, 0x1,0x7d,0x35, + 0x2,0x71,0x62, 0x4,0x6d,0x62, 0x3,0x61,0x6f, 0x3,0x62,0x23, + 0x1,0x7d,0x3f, 0x1,0x7d,0x3d, 0x1,0x7d,0x3e, 0x1,0x7d,0x44, + 0x2,0x72,0x30, 0x2,0x72,0x31, 0x2,0x72,0x2f, 0x2,0x72,0x37, + 0x3,0x62,0x36, 0x1,0x4f,0x5b, 0x4,0x25,0x2b, 0x4,0x30,0x3a, + 0x2,0x3a,0x28, 0x2,0x41,0x3f, 0x2,0x55,0x4e, 0x2,0x67,0x63, + 0x5,0x71,0x56, 0x1,0x4f,0x5c, 0x3,0x2f,0x40, 0x1,0x53,0x6d, + 0x1,0x58,0x60, 0x4,0x30,0x3b, 0x3,0x34,0x32, 0x2,0x3a,0x29, + 0x3,0x39,0x5c, 0x2,0x3a,0x2a, 0x1,0x5d,0x70, 0x1,0x62,0x64, + 0x2,0x41,0x41, 0x2,0x41,0x40, 0x1,0x62,0x68, 0x1,0x62,0x63, + 0x2,0x41,0x42, 0x1,0x62,0x65, 0x1,0x62,0x67, 0x1,0x62,0x66, + 0x1,0x62,0x62, 0x3,0x3f,0x6c, 0xf,0x3f,0x7e, 0x3,0x66,0x6b, + 0x1,0x67,0x50, 0x3,0x45,0x3c, 0x3,0x45,0x3a, 0x2,0x48,0x56, + 0x2,0x48,0x54, 0x4,0x41,0x53, 0x2,0x48,0x55, 0x2,0x48,0x53, + 0xf,0x45,0x7b, 0x1,0x6b,0x5b, 0x3,0x4a,0x3d, 0x1,0x6b,0x5e, + 0x1,0x6b,0x60, 0x1,0x6b,0x5f, 0x4,0x48,0x22, 0x3,0x4a,0x3e, + 0x1,0x6b,0x5c, 0x1,0x6b,0x5d, 0x2,0x55,0x50, 0x2,0x55,0x4f, + 0x1,0x6f,0x64, 0x2,0x55,0x51, 0x3,0x4f,0x53, 0x2,0x55,0x52, + 0x1,0x6f,0x65, 0x3,0x4f,0x55, 0x3,0x4f,0x56, 0x4,0x4e,0x4a, + 0x2,0x5b,0x59, 0x2,0x5b,0x57, 0x2,0x60,0x40, 0x3,0x53,0x42, + 0x2,0x5b,0x55, 0x2,0x5b,0x56, 0x1,0x72,0x6f, 0x2,0x5b,0x52, + 0x2,0x5b,0x5a, 0x2,0x5b,0x54, 0x2,0x5b,0x58, 0x2,0x60,0x3c, + 0x3,0x53,0x44, 0x3,0x53,0x40, 0x2,0x60,0x3e, 0x3,0x56,0x6d, + 0x2,0x60,0x3f, 0x1,0x75,0x7e, 0x2,0x60,0x3b, 0x1,0x75,0x7d, + 0x2,0x60,0x3d, 0x1,0x75,0x7a, 0x1,0x75,0x7b, 0x1,0x75,0x7c, + 0x2,0x5b,0x53, 0x3,0x66,0x6c, 0x1,0x77,0x60, 0x2,0x64,0x3a, + 0x2,0x64,0x38, 0x2,0x64,0x39, 0x1,0x77,0x5e, 0x1,0x77,0x61, + 0x1,0x77,0x5f, 0x3,0x59,0x4b, 0x3,0x59,0x4a, 0x7,0x4b,0x40, + 0x2,0x67,0x64, 0x2,0x67,0x65, 0x1,0x79,0x43, 0x3,0x5b,0x53, + 0x2,0x6a,0x53, 0x2,0x6a,0x55, 0x2,0x6a,0x54, 0x1,0x7a,0x4f, + 0x1,0x7b,0x3c, 0x2,0x6c,0x5b, 0x2,0x6c,0x5a, 0x2,0x6c,0x59, + 0xf,0x68,0x72, 0x3,0x66,0x6d, 0xf,0x25,0x39, 0x1,0x4f,0x5d, + 0x3,0x21,0x43, 0x2,0x21,0x69, 0x2,0x22,0x78, 0x1,0x48,0x6a, + 0x2,0x22,0x76, 0x2,0x22,0x79, 0x2,0x22,0x77, 0x4,0x25,0x2e, + 0x3,0x27,0x3b, 0x3,0x27,0x3a, 0x2,0x25,0x2e, 0x3,0x27,0x3f, + 0x1,0x4b,0x62, 0x3,0x27,0x3c, 0x1,0x4b,0x63, 0x2,0x25,0x30, + 0x1,0x4b,0x60, 0x2,0x25,0x2f, 0x2,0x25,0x2d, 0x1,0x4b,0x61, + 0x1,0x4b,0x5f, 0x3,0x27,0x3d, 0x3,0x27,0x3e, 0x3,0x2a,0x79, + 0x4,0x28,0x33, 0x2,0x28,0x78, 0x2,0x28,0x7b, 0x1,0x4f,0x60, + 0x2,0x28,0x7a, 0x2,0x28,0x79, 0x3,0x2a,0x7c, 0x1,0x4f,0x5f, + 0x1,0x4f,0x5e, 0x3,0x2a,0x7b, 0x1,0x4f,0x62, 0x2,0x28,0x7c, + 0x1,0x4f,0x61, 0x2,0x2d,0x67, 0x1,0x53,0x6f, 0x1,0x53,0x70, + 0x1,0x53,0x71, 0x2,0x2d,0x68, 0x2,0x2d,0x64, 0x1,0x53,0x6e, + 0x2,0x2d,0x65, 0x4,0x2b,0x5d, 0x2,0x2d,0x66, 0x2,0x2d,0x63, + 0x4,0x2b,0x5b, 0x3,0x34,0x36, 0x4,0x30,0x3f, 0x1,0x58,0x67, + 0x3,0x34,0x34, 0x3,0x39,0x5e, 0x1,0x58,0x64, 0x2,0x33,0x48, + 0x1,0x58,0x65, 0x1,0x58,0x68, 0x2,0x33,0x49, 0x3,0x34,0x33, + 0x1,0x58,0x63, 0x1,0x58,0x61, 0x1,0x58,0x62, 0x1,0x58,0x66, + 0x1,0x5d,0x71, 0x2,0x3a,0x2d, 0x1,0x5d,0x79, 0x2,0x3a,0x2c, + 0x3,0x39,0x61, 0x2,0x3a,0x2f, 0x1,0x5d,0x75, 0x2,0x3a,0x2e, + 0x1,0x62,0x70, 0x1,0x5d,0x73, 0x1,0x5d,0x76, 0x1,0x5d,0x72, + 0x1,0x5d,0x77, 0x1,0x5d,0x78, 0x1,0x5d,0x74, 0x3,0x39,0x65, + 0x3,0x3f,0x71, 0x2,0x3a,0x2b, 0x1,0x62,0x6c, 0x2,0x41,0x44, + 0x3,0x3f,0x72, 0x2,0x41,0x48, 0x3,0x3f,0x73, 0x3,0x3f,0x75, + 0x2,0x41,0x47, 0x1,0x62,0x71, 0x1,0x62,0x6d, 0x1,0x62,0x6e, + 0x2,0x41,0x43, 0x2,0x41,0x45, 0x2,0x41,0x46, 0x1,0x62,0x69, + 0x1,0x62,0x6b, 0x3,0x3f,0x70, 0x1,0x62,0x6f, 0x1,0x62,0x6a, + 0x3,0x45,0x40, 0x2,0x48,0x59, 0x2,0x48,0x57, 0x2,0x48,0x58, + 0x1,0x67,0x52, 0x1,0x67,0x53, 0x3,0x45,0x42, 0x2,0x48,0x5a, + 0x1,0x67,0x51, 0x1,0x6b,0x61, 0x4,0x48,0x24, 0x1,0x6b,0x63, + 0x1,0x6b,0x62, 0x3,0x4a,0x45, 0x2,0x4f,0x23, 0x3,0x4a,0x46, + 0x3,0x4a,0x44, 0x2,0x4f,0x24, 0x2,0x55,0x54, 0x3,0x4f,0x5a, + 0x2,0x55,0x53, 0x3,0x4f,0x5b, 0x4,0x54,0x52, 0x1,0x72,0x70, + 0x1,0x72,0x71, 0x2,0x5b,0x5b, 0x1,0x72,0x72, 0x3,0x53,0x48, + 0x2,0x60,0x43, 0x3,0x56,0x70, 0x2,0x60,0x41, 0x3,0x56,0x6f, + 0x2,0x60,0x42, 0x1,0x76,0x21, 0x3,0x56,0x71, 0x2,0x64,0x3b, + 0x1,0x79,0x44, 0x3,0x5d,0x49, 0x3,0x2a,0x7d, 0x3,0x53,0x49, + 0x1,0x76,0x22, 0x1,0x4f,0x63, 0x4,0x30,0x41, 0x1,0x58,0x69, + 0x2,0x33,0x4a, 0x3,0x34,0x39, 0xf,0x32,0x6f, 0x2,0x3a,0x30, + 0x1,0x5d,0x7a, 0x1,0x62,0x72, 0x2,0x41,0x49, 0x2,0x41,0x4b, + 0x1,0x62,0x74, 0x1,0x62,0x73, 0x1,0x62,0x75, 0x1,0x62,0x76, + 0x2,0x41,0x4a, 0x1,0x67,0x56, 0x1,0x67,0x57, 0x1,0x67,0x55, + 0x1,0x6b,0x64, 0x1,0x67,0x54, 0x2,0x48,0x5b, 0x4,0x41,0x57, + 0x3,0x4a,0x47, 0x3,0x4a,0x49, 0x1,0x6b,0x65, 0x2,0x55,0x55, + 0x2,0x5b,0x5c, 0x1,0x72,0x73, 0x1,0x76,0x23, 0x2,0x64,0x3c, + 0x2,0x64,0x40, 0x1,0x77,0x64, 0x2,0x64,0x3d, 0x1,0x77,0x65, + 0x1,0x77,0x63, 0x2,0x64,0x41, 0x1,0x77,0x66, 0x2,0x64,0x3f, + 0x2,0x67,0x66, 0x1,0x77,0x62, 0x1,0x79,0x45, 0x3,0x5e,0x70, + 0x2,0x70,0x5b, 0x3,0x61,0x25, 0x3,0x62,0x2f, 0x1,0x4f,0x64, + 0x1,0x5d,0x7c, 0x1,0x5d,0x7b, 0xf,0x39,0x2a, 0x3,0x3f,0x7e, + 0x3,0x3f,0x7c, 0x3,0x3f,0x7b, 0x1,0x62,0x77, 0x2,0x41,0x4d, + 0x2,0x41,0x4c, 0x1,0x62,0x78, 0x3,0x45,0x46, 0x2,0x48,0x5f, + 0x1,0x67,0x5b, 0x1,0x67,0x58, 0x2,0x48,0x5e, 0x1,0x67,0x5a, + 0x2,0x48,0x5c, 0x1,0x67,0x59, 0x3,0x45,0x47, 0x2,0x48,0x5d, + 0x2,0x4f,0x25, 0x1,0x6b,0x66, 0x2,0x55,0x58, 0x5,0x52,0x3b, + 0x1,0x6f,0x66, 0x2,0x55,0x56, 0x1,0x6f,0x67, 0x1,0x6f,0x68, + 0x2,0x55,0x57, 0x1,0x6f,0x69, 0x3,0x4f,0x60, 0x2,0x5b,0x5d, + 0x3,0x53,0x50, 0x1,0x72,0x77, 0x1,0x72,0x74, 0x1,0x72,0x79, + 0x2,0x5b,0x5f, 0x1,0x72,0x75, 0x2,0x5b,0x5e, 0x1,0x72,0x78, + 0x3,0x53,0x4d, 0x3,0x53,0x4c, 0x1,0x72,0x76, 0x3,0x53,0x51, + 0x2,0x60,0x46, 0x2,0x60,0x48, 0x3,0x56,0x74, 0x3,0x56,0x75, + 0x1,0x76,0x24, 0x2,0x60,0x47, 0x1,0x76,0x25, 0x2,0x60,0x45, + 0x2,0x60,0x44, 0x4,0x5e,0x38, 0x2,0x64,0x43, 0x2,0x64,0x42, + 0x1,0x77,0x67, 0x2,0x64,0x44, 0x2,0x67,0x6b, 0x1,0x79,0x47, + 0x2,0x67,0x6a, 0x2,0x67,0x67, 0x1,0x79,0x46, 0x2,0x67,0x68, + 0x2,0x67,0x69, 0x2,0x6a,0x56, 0x2,0x6a,0x57, 0x1,0x7a,0x50, + 0x3,0x5d,0x4f, 0x1,0x7b,0x3f, 0x3,0x5d,0x4c, 0x3,0x5d,0x4e, + 0x2,0x6c,0x5c, 0x3,0x5e,0x72, 0x3,0x5e,0x71, 0x1,0x7b,0x3d, + 0x1,0x7b,0x3e, 0x2,0x6c,0x5d, 0x3,0x66,0x6e, 0x3,0x5f,0x71, + 0x1,0x7b,0x7e, 0x1,0x7c,0x21, 0x2,0x6e,0x40, 0x3,0x5f,0x72, + 0x3,0x60,0x59, 0x1,0x7c,0x70, 0x2,0x70,0x5d, 0x1,0x7c,0x72, + 0x3,0x61,0x26, 0x2,0x70,0x5c, 0x2,0x70,0x5e, 0x1,0x7c,0x71, + 0x2,0x71,0x46, 0x4,0x6d,0x64, 0x2,0x71,0x7b, 0x3,0x66,0x6f, + 0x3,0x62,0x45, 0x3,0x2a,0x7e, 0x1,0x4f,0x65, 0x3,0x45,0x49, + 0x1,0x67,0x5c, 0x4,0x48,0x35, 0x2,0x4f,0x26, 0x3,0x4a,0x4c, + 0x2,0x55,0x59, 0x1,0x72,0x7a, 0x1,0x72,0x7b, 0x3,0x59,0x4f, + 0x1,0x4f,0x66, 0x3,0x40,0x21, 0x1,0x6f,0x6a, 0x1,0x79,0x48, + 0x1,0x53,0x72, 0x3,0x2b,0x21, 0x3,0x4a,0x4e, 0x1,0x72,0x7c, + 0x3,0x5e,0x73, 0x1,0x7c,0x4e, 0x1,0x53,0x73, 0x2,0x3a,0x31, + 0x4,0x3b,0x77, 0x2,0x41,0x4e, 0x3,0x40,0x24, 0x2,0x41,0x50, + 0x3,0x40,0x22, 0x2,0x41,0x4f, 0x2,0x48,0x63, 0x2,0x48,0x60, + 0x1,0x67,0x5d, 0x6,0x5a,0x24, 0x1,0x67,0x5e, 0x2,0x48,0x61, + 0x2,0x48,0x62, 0x3,0x45,0x4b, 0x2,0x4f,0x28, 0x2,0x4f,0x2d, + 0x1,0x6b,0x67, 0x2,0x4f,0x27, 0x2,0x4f,0x29, 0x2,0x4f,0x30, + 0x2,0x4f,0x2b, 0x2,0x4f,0x2f, 0x2,0x4f,0x2c, 0x2,0x4f,0x2a, + 0x2,0x4f,0x2e, 0x1,0x6b,0x68, 0x3,0x4f,0x62, 0x2,0x55,0x5c, + 0x3,0x4f,0x63, 0x2,0x55,0x5a, 0x1,0x6f,0x6c, 0x3,0x4f,0x64, + 0x1,0x6f,0x6b, 0x2,0x55,0x5b, 0x1,0x6f,0x6d, 0x3,0x53,0x53, + 0x2,0x5b,0x62, 0x4,0x54,0x5f, 0x4,0x54,0x67, 0x2,0x5b,0x61, + 0x1,0x72,0x7d, 0x2,0x5b,0x60, 0x2,0x60,0x49, 0x3,0x56,0x7a, + 0x2,0x60,0x4b, 0x2,0x60,0x4d, 0x2,0x60,0x4c, 0x3,0x56,0x7b, + 0x1,0x76,0x26, 0x2,0x60,0x4a, 0x2,0x64,0x4b, 0x1,0x77,0x68, + 0x2,0x64,0x49, 0x2,0x64,0x4c, 0x1,0x77,0x69, 0x4,0x5e,0x43, + 0x2,0x64,0x47, 0x3,0x59,0x50, 0x2,0x64,0x4a, 0x2,0x64,0x48, + 0x2,0x64,0x45, 0x1,0x77,0x6a, 0x2,0x64,0x46, 0x4,0x61,0x7c, + 0x3,0x5b,0x5f, 0x3,0x5b,0x5d, 0x2,0x67,0x6c, 0x3,0x5b,0x5e, + 0x3,0x5b,0x60, 0x2,0x67,0x6e, 0x2,0x67,0x6d, 0x3,0x5d,0x50, + 0x2,0x6a,0x58, 0x3,0x5d,0x51, 0x2,0x6a,0x59, 0x4,0x67,0x71, + 0x3,0x5e,0x75, 0x3,0x5e,0x74, 0x2,0x6c,0x5e, 0x3,0x5f,0x73, + 0x1,0x7c,0x23, 0x4,0x69,0x5e, 0x1,0x7c,0x22, 0x2,0x6f,0x5d, + 0x2,0x6f,0x5e, 0x1,0x7c,0x73, 0x2,0x70,0x5f, 0x3,0x61,0x28, + 0x1,0x7d,0x36, 0x3,0x62,0x3b, 0x1,0x53,0x74, 0x1,0x62,0x79, + 0x2,0x4f,0x32, 0x2,0x4f,0x31, 0x2,0x55,0x5e, 0x2,0x55,0x5d, + 0x4,0x4e,0x57, 0x3,0x53,0x55, 0x1,0x76,0x27, 0x2,0x60,0x4f, + 0x2,0x60,0x4e, 0x2,0x64,0x4f, 0x2,0x64,0x4d, 0x2,0x64,0x50, + 0x2,0x64,0x4e, 0x3,0x59,0x51, 0x4,0x65,0x29, 0x1,0x79,0x49, + 0x2,0x67,0x6f, 0x2,0x67,0x70, 0x2,0x67,0x71, 0x4,0x65,0x27, + 0x2,0x6c,0x5f, 0x3,0x5e,0x76, 0x2,0x6e,0x41, 0x3,0x61,0x29, + 0x2,0x70,0x60, 0x1,0x53,0x75, 0x3,0x45,0x4f, 0x3,0x4f,0x65, + 0x2,0x5b,0x63, 0x2,0x60,0x50, 0x3,0x5b,0x61, 0x1,0x53,0x76, + 0x4,0x41,0x63, 0x3,0x45,0x50, 0x1,0x6b,0x69, 0x4,0x48,0x46, + 0x2,0x5b,0x64, 0x1,0x77,0x6b, 0x2,0x64,0x51, 0x1,0x79,0x4a, + 0x3,0x5d,0x53, 0x2,0x6a,0x5a, 0x2,0x6a,0x5b, 0x1,0x7b,0x40, + 0x2,0x6f,0x5f, 0x1,0x53,0x77, 0x1,0x5e,0x21, 0x1,0x5e,0x22, + 0x2,0x3a,0x32, 0x1,0x62,0x7a, 0x1,0x62,0x7b, 0x2,0x41,0x51, + 0x1,0x62,0x7c, 0x4,0x41,0x68, 0x1,0x67,0x62, 0x3,0x45,0x52, + 0x1,0x67,0x64, 0x2,0x48,0x65, 0x2,0x48,0x66, 0x2,0x48,0x64, + 0x1,0x67,0x5f, 0x1,0x67,0x60, 0x1,0x67,0x63, 0x1,0x67,0x61, + 0x3,0x4a,0x54, 0x3,0x4a,0x55, 0x2,0x4f,0x33, 0x1,0x6b,0x6a, + 0x1,0x6b,0x6b, 0x3,0x4a,0x52, 0x3,0x4a,0x56, 0x2,0x55,0x65, + 0x1,0x6f,0x70, 0x2,0x55,0x60, 0x2,0x55,0x5f, 0x3,0x4f,0x69, + 0x2,0x55,0x64, 0x1,0x6f,0x6e, 0x3,0x4f,0x67, 0x4,0x4e,0x5a, + 0x1,0x73,0x26, 0x4,0x54,0x70, 0x2,0x55,0x61, 0x2,0x55,0x66, + 0x2,0x55,0x63, 0x2,0x55,0x62, 0x3,0x4f,0x66, 0x1,0x6f,0x6f, + 0x1,0x73,0x24, 0x3,0x53,0x5c, 0x2,0x5b,0x66, 0x1,0x72,0x7e, + 0x3,0x53,0x59, 0x2,0x5b,0x67, 0x3,0x53,0x5a, 0x3,0x52,0x28, + 0x2,0x5b,0x65, 0x3,0x53,0x58, 0x1,0x73,0x23, 0x1,0x73,0x21, + 0x1,0x73,0x25, 0x3,0x53,0x5d, 0x1,0x73,0x22, 0x3,0x53,0x5b, + 0x3,0x53,0x5f, 0x4,0x5e,0x4f, 0x3,0x59,0x5b, 0x3,0x57,0x26, + 0x2,0x60,0x51, 0x4,0x59,0x70, 0x2,0x60,0x56, 0x2,0x60,0x52, + 0x2,0x60,0x55, 0x1,0x76,0x28, 0x3,0x57,0x28, 0x2,0x5e,0x41, + 0x2,0x60,0x54, 0x2,0x60,0x53, 0x3,0x59,0x59, 0x1,0x77,0x6e, + 0x1,0x77,0x6c, 0x1,0x77,0x6f, 0x1,0x77,0x6d, 0x2,0x64,0x52, + 0x2,0x64,0x53, 0x2,0x64,0x54, 0x1,0x77,0x70, 0x3,0x59,0x56, + 0x3,0x59,0x58, 0x3,0x5b,0x65, 0x2,0x67,0x75, 0x1,0x79,0x4c, + 0x2,0x67,0x73, 0x4,0x62,0x30, 0x1,0x79,0x4d, 0x2,0x67,0x72, + 0x2,0x67,0x74, 0x1,0x79,0x4b, 0x2,0x6a,0x5f, 0x2,0x6a,0x5c, + 0x4,0x65,0x2c, 0x2,0x6a,0x5d, 0x2,0x6a,0x5e, 0x2,0x6c,0x60, + 0x1,0x7b,0x42, 0x3,0x5e,0x78, 0x1,0x7b,0x41, 0x3,0x5e,0x77, + 0x2,0x6e,0x43, 0x2,0x6e,0x42, 0x1,0x7c,0x24, 0x3,0x60,0x5d, + 0x3,0x60,0x5e, 0x3,0x60,0x5c, 0x1,0x7c,0x4f, 0x1,0x7c,0x74, + 0x1,0x7d,0x2d, 0x2,0x71,0x47, 0x2,0x71,0x7c, 0x2,0x71,0x7d, + 0x1,0x53,0x78, 0x2,0x41,0x52, 0x4,0x41,0x71, 0x2,0x48,0x67, + 0x2,0x4f,0x34, 0x2,0x4f,0x35, 0x1,0x6b,0x6c, 0x4,0x48,0x57, + 0x1,0x6b,0x6d, 0x2,0x55,0x67, 0x1,0x6f,0x71, 0x3,0x53,0x61, + 0x1,0x76,0x29, 0x3,0x57,0x2a, 0x2,0x64,0x55, 0x3,0x59,0x5c, + 0x1,0x77,0x71, 0x2,0x67,0x78, 0x1,0x79,0x4e, 0x2,0x67,0x77, + 0x2,0x67,0x79, 0x2,0x67,0x76, 0x2,0x6c,0x63, 0x2,0x6a,0x60, + 0x2,0x6a,0x61, 0x3,0x5d,0x56, 0x1,0x7a,0x51, 0x2,0x6c,0x62, + 0x3,0x5e,0x7b, 0x3,0x5e,0x79, 0x2,0x6c,0x61, 0x3,0x5e,0x7a, + 0x2,0x6e,0x44, 0x2,0x71,0x7e, 0x3,0x62,0x25, 0x1,0x53,0x79, + 0x3,0x5e,0x7c, 0x3,0x62,0x26, 0x1,0x53,0x7a, 0x3,0x39,0x67, + 0x1,0x58,0x6a, 0x2,0x33,0x4b, 0x3,0x66,0x70, 0x2,0x3a,0x33, + 0x3,0x39,0x68, 0x1,0x62,0x7d, 0x1,0x63,0x22, 0x1,0x62,0x7e, + 0x2,0x41,0x53, 0x3,0x45,0x5b, 0x1,0x63,0x24, 0x1,0x63,0x21, + 0x3,0x40,0x2b, 0x3,0x45,0x5c, 0x1,0x63,0x23, 0x3,0x45,0x54, + 0x1,0x67,0x66, 0x3,0x45,0x59, 0x2,0x48,0x68, 0x3,0x45,0x57, + 0x3,0x4a,0x5d, 0x2,0x48,0x69, 0x2,0x55,0x69, 0x4,0x41,0x7b, + 0x1,0x67,0x65, 0x1,0x67,0x67, 0x1,0x67,0x68, 0x3,0x45,0x58, + 0x2,0x4f,0x37, 0x3,0x4a,0x5e, 0x2,0x4f,0x36, 0x1,0x6b,0x6e, + 0x5,0x4b,0x4c, 0x1,0x6b,0x6f, 0x3,0x4a,0x5b, 0x2,0x4f,0x38, + 0x2,0x55,0x68, 0x1,0x6b,0x71, 0x1,0x6f,0x72, 0x4,0x4e,0x63, + 0x1,0x6b,0x70, 0x3,0x66,0x7a, 0x1,0x73,0x27, 0x2,0x55,0x6a, + 0x1,0x6f,0x74, 0x1,0x6f,0x73, 0x2,0x55,0x6b, 0x2,0x55,0x6e, + 0x2,0x55,0x6c, 0x2,0x55,0x6d, 0x1,0x6f,0x75, 0x3,0x4f,0x6b, + 0x1,0x73,0x2c, 0x1,0x73,0x2a, 0x3,0x53,0x65, 0x3,0x53,0x66, + 0x1,0x73,0x29, 0x2,0x5b,0x69, 0x3,0x53,0x64, 0x1,0x73,0x2b, + 0x3,0x53,0x62, 0x3,0x53,0x63, 0x2,0x5b,0x68, 0x2,0x60,0x57, + 0x4,0x54,0x7e, 0x2,0x5b,0x6a, 0x1,0x73,0x28, 0x2,0x5b,0x6b, + 0x2,0x60,0x5a, 0x2,0x60,0x58, 0x2,0x60,0x59, 0x2,0x60,0x5e, + 0x1,0x77,0x75, 0x2,0x60,0x5d, 0x2,0x60,0x60, 0x2,0x60,0x5f, + 0x2,0x60,0x5c, 0x2,0x60,0x5b, 0x4,0x55,0x21, 0x1,0x76,0x2a, + 0x3,0x59,0x62, 0x4,0x5a,0x29, 0x3,0x59,0x61, 0x3,0x59,0x66, + 0x2,0x64,0x58, 0x3,0x59,0x65, 0x2,0x64,0x57, 0x1,0x77,0x74, + 0x1,0x77,0x72, 0x1,0x77,0x73, 0x3,0x59,0x63, 0x2,0x64,0x56, + 0x3,0x66,0x71, 0x2,0x67,0x7c, 0x3,0x5b,0x69, 0x1,0x79,0x4f, + 0x4,0x62,0x38, 0x2,0x67,0x7b, 0x2,0x67,0x7a, 0x1,0x79,0x50, + 0x4,0x65,0x3a, 0x2,0x6a,0x66, 0x2,0x6a,0x65, 0x3,0x5d,0x58, + 0x2,0x6a,0x63, 0x3,0x5e,0x7e, 0x2,0x6a,0x62, 0x1,0x7a,0x53, + 0x1,0x7a,0x52, 0x2,0x6a,0x67, 0x2,0x6e,0x45, 0x1,0x7c,0x25, + 0x2,0x6c,0x65, 0x1,0x7b,0x43, 0x2,0x6c,0x64, 0x2,0x6a,0x64, + 0x3,0x5f,0x78, 0x2,0x6e,0x46, 0x1,0x7c,0x50, 0x3,0x61,0x2a, + 0x1,0x7d,0x2e, 0x2,0x71,0x48, 0x4,0x6e,0x24, 0x2,0x72,0x21, + 0x1,0x53,0x7b, 0x2,0x3a,0x34, 0x2,0x60,0x61, 0x1,0x53,0x7c, + 0x3,0x45,0x5f, 0x5,0x4b,0x4e, 0x2,0x4f,0x3a, 0x2,0x4f,0x39, + 0x2,0x5b,0x6c, 0x5,0x5a,0x26, 0x3,0x53,0x68, 0x2,0x60,0x63, + 0x3,0x57,0x30, 0x2,0x60,0x62, 0x3,0x59,0x67, 0x1,0x77,0x76, + 0x2,0x67,0x7d, 0x2,0x67,0x7e, 0x1,0x7a,0x54, 0x3,0x5f,0x21, + 0x3,0x60,0x60, 0x2,0x72,0x22, 0x1,0x58,0x6b, 0x1,0x63,0x26, + 0x1,0x63,0x25, 0x2,0x48,0x6a, 0x2,0x48,0x6c, 0x1,0x67,0x6a, + 0x2,0x48,0x6b, 0x1,0x67,0x69, 0x1,0x67,0x6b, 0x2,0x48,0x6d, + 0x3,0x4a,0x63, 0x3,0x4a,0x62, 0x3,0x4a,0x66, 0x2,0x4f,0x3c, + 0x2,0x4f,0x3e, 0x2,0x4f,0x3d, 0x3,0x4a,0x61, 0x2,0x4f,0x40, + 0x3,0x4a,0x60, 0x3,0x4a,0x6c, 0x3,0x4a,0x64, 0x1,0x6b,0x72, + 0x2,0x4f,0x3f, 0x2,0x4f,0x3b, 0x3,0x4a,0x6a, 0x4,0x48,0x60, + 0x2,0x4f,0x41, 0x3,0x4f,0x73, 0x2,0x55,0x75, 0x3,0x4f,0x6d, + 0x2,0x55,0x78, 0x2,0x55,0x7a, 0x2,0x55,0x70, 0x2,0x55,0x74, + 0x2,0x55,0x71, 0x1,0x6f,0x77, 0x1,0x6f,0x7a, 0x1,0x6f,0x7c, + 0x2,0x55,0x72, 0x2,0x55,0x73, 0x1,0x6f,0x7b, 0x2,0x55,0x76, + 0x2,0x55,0x79, 0x2,0x55,0x77, 0x1,0x6f,0x7d, 0x3,0x4f,0x6e, + 0x1,0x6f,0x79, 0x2,0x55,0x6f, 0x1,0x6f,0x76, 0x3,0x4f,0x72, + 0x1,0x6f,0x78, 0x3,0x4f,0x74, 0x3,0x53,0x70, 0x1,0x73,0x2e, + 0x2,0x5b,0x72, 0x2,0x5b,0x70, 0x2,0x5b,0x6f, 0x3,0x53,0x71, + 0x2,0x5b,0x75, 0x3,0x53,0x6b, 0x2,0x5b,0x74, 0x2,0x5b,0x73, + 0x3,0x53,0x6c, 0x2,0x5b,0x6e, 0x1,0x73,0x2d, 0x2,0x5b,0x6d, + 0x3,0x53,0x6a, 0x2,0x5b,0x71, 0x1,0x73,0x2f, 0x3,0x57,0x34, + 0x2,0x60,0x66, 0x3,0x57,0x37, 0x2,0x60,0x6a, 0x2,0x60,0x67, + 0x2,0x60,0x69, 0x2,0x60,0x68, 0x2,0x60,0x65, 0x2,0x60,0x6b, + 0x2,0x60,0x6e, 0x2,0x60,0x6c, 0x2,0x60,0x6d, 0x1,0x76,0x2c, + 0x3,0x57,0x33, 0x1,0x76,0x2b, 0x2,0x60,0x64, 0x2,0x60,0x6f, + 0x2,0x64,0x5d, 0x2,0x64,0x60, 0x2,0x64,0x62, 0x2,0x64,0x61, + 0x3,0x59,0x6a, 0x2,0x64,0x5b, 0x2,0x64,0x5f, 0x2,0x64,0x5a, + 0x3,0x59,0x6b, 0x2,0x64,0x5c, 0x1,0x77,0x77, 0x2,0x64,0x59, + 0x3,0x59,0x6d, 0x2,0x64,0x5e, 0x2,0x68,0x2d, 0x2,0x68,0x22, + 0x1,0x79,0x51, 0x3,0x5b,0x6f, 0x3,0x5b,0x6d, 0x1,0x79,0x52, + 0x2,0x68,0x21, 0x2,0x68,0x26, 0x2,0x68,0x2c, 0x2,0x68,0x24, + 0x2,0x68,0x2b, 0x3,0x5b,0x6c, 0x2,0x68,0x28, 0x3,0x5b,0x6e, + 0x2,0x68,0x27, 0x2,0x68,0x2a, 0x2,0x68,0x25, 0x2,0x68,0x23, + 0x3,0x5b,0x6b, 0x2,0x68,0x29, 0x2,0x6a,0x6e, 0x2,0x6a,0x6c, + 0x1,0x7a,0x55, 0x2,0x6a,0x6b, 0x2,0x6a,0x71, 0x2,0x6a,0x6f, + 0x3,0x5d,0x5a, 0x1,0x7a,0x56, 0x2,0x6a,0x6a, 0x2,0x6a,0x68, + 0x4,0x65,0x46, 0x2,0x6a,0x69, 0x1,0x7a,0x58, 0x2,0x6a,0x6d, + 0x1,0x7a,0x57, 0x2,0x6a,0x70, 0x2,0x6c,0x66, 0x2,0x6c,0x6c, + 0x3,0x5f,0x24, 0x3,0x5f,0x22, 0x2,0x6c,0x67, 0x1,0x7b,0x47, + 0x2,0x6c,0x6d, 0x1,0x7b,0x46, 0x2,0x6c,0x6b, 0x2,0x6c,0x6a, + 0x1,0x7b,0x45, 0x2,0x6c,0x69, 0x1,0x7b,0x44, 0x2,0x6c,0x68, + 0x7,0x56,0x51, 0x2,0x6e,0x4c, 0x2,0x6e,0x4e, 0x2,0x6e,0x4d, + 0x4,0x69,0x6a, 0x2,0x6e,0x4a, 0x1,0x7c,0x27, 0x2,0x6e,0x47, + 0x2,0x6e,0x4b, 0x2,0x6e,0x50, 0x3,0x5f,0x79, 0x2,0x6e,0x4f, + 0x2,0x6e,0x48, 0x2,0x6e,0x49, 0x1,0x7c,0x26, 0x2,0x6f,0x60, + 0x1,0x7c,0x53, 0x3,0x60,0x62, 0x2,0x6f,0x61, 0x1,0x7c,0x51, + 0x1,0x7c,0x52, 0x3,0x60,0x61, 0x4,0x6c,0x3d, 0x2,0x70,0x61, + 0x1,0x7c,0x75, 0x2,0x71,0x65, 0x3,0x61,0x72, 0x1,0x7d,0x37, + 0x3,0x61,0x73, 0x2,0x72,0x23, 0x1,0x7d,0x38, 0x2,0x72,0x24, + 0x2,0x72,0x25, 0x2,0x72,0x33, 0x2,0x72,0x32, 0x1,0x7d,0x47, + 0x2,0x72,0x3b, 0x1,0x58,0x6c, 0x3,0x40,0x2f, 0x4,0x42,0x21, + 0x2,0x48,0x6f, 0x4,0x41,0x7d, 0x2,0x48,0x6e, 0x4,0x41,0x7e, + 0x1,0x6b,0x73, 0x1,0x6b,0x74, 0x2,0x4f,0x42, 0x4,0x4e,0x74, + 0x2,0x55,0x7b, 0x2,0x5b,0x78, 0x3,0x4f,0x77, 0x3,0x4f,0x76, + 0x1,0x6f,0x7e, 0x1,0x73,0x30, 0x2,0x5b,0x76, 0x4,0x55,0x31, + 0x2,0x5b,0x79, 0x1,0x73,0x31, 0x3,0x57,0x3a, 0x2,0x60,0x70, + 0x2,0x5b,0x77, 0x2,0x64,0x63, 0x1,0x77,0x78, 0x2,0x68,0x2e, + 0x4,0x62,0x49, 0x3,0x5d,0x61, 0x2,0x6a,0x74, 0x2,0x6a,0x72, + 0x3,0x5d,0x60, 0x3,0x5d,0x5e, 0x2,0x6a,0x73, 0x2,0x6c,0x6e, + 0x3,0x5f,0x25, 0x1,0x7b,0x48, 0x2,0x6e,0x51, 0x1,0x7c,0x56, + 0x1,0x7c,0x28, 0x1,0x7c,0x54, 0x1,0x7c,0x55, 0x2,0x70,0x62, + 0x1,0x7d,0x2f, 0x3,0x61,0x74, 0x1,0x58,0x6d, 0x4,0x36,0x2d, + 0x3,0x4a,0x6e, 0x4,0x4e,0x79, 0x2,0x64,0x64, 0x3,0x5f,0x7b, + 0x3,0x60,0x63, 0x2,0x33,0x4c, 0x3,0x40,0x32, 0x1,0x67,0x6c, + 0x3,0x45,0x61, 0x2,0x4f,0x43, 0x3,0x4a,0x6f, 0x3,0x4a,0x73, + 0x1,0x6b,0x75, 0x2,0x4f,0x44, 0x3,0x4a,0x71, 0x3,0x4a,0x70, + 0x3,0x4a,0x72, 0x2,0x55,0x7d, 0x2,0x55,0x7c, 0x1,0x73,0x33, + 0x1,0x70,0x21, 0x1,0x70,0x22, 0x4,0x4f,0x21, 0x2,0x56,0x22, + 0x2,0x56,0x21, 0x2,0x55,0x7e, 0x3,0x4f,0x79, 0x3,0x53,0x75, + 0x2,0x5b,0x7a, 0x2,0x5b,0x7d, 0x3,0x53,0x74, 0x2,0x5b,0x7c, + 0x2,0x5b,0x7b, 0x1,0x73,0x32, 0x2,0x60,0x74, 0x2,0x60,0x72, + 0x2,0x60,0x71, 0x4,0x5a,0x37, 0x3,0x57,0x3b, 0x2,0x60,0x73, + 0x3,0x57,0x3c, 0x1,0x77,0x79, 0x2,0x64,0x66, 0x2,0x64,0x67, + 0x1,0x77,0x7a, 0x3,0x59,0x6f, 0x2,0x64,0x65, 0x3,0x5b,0x71, + 0x2,0x68,0x30, 0x2,0x68,0x2f, 0x2,0x68,0x32, 0x1,0x79,0x53, + 0x2,0x68,0x31, 0x4,0x62,0x4f, 0x2,0x6a,0x75, 0x2,0x6a,0x77, + 0x2,0x6a,0x76, 0x3,0x5f,0x27, 0x2,0x6c,0x6f, 0x2,0x6c,0x72, + 0x2,0x6c,0x70, 0x2,0x6c,0x71, 0x2,0x6e,0x52, 0x1,0x7c,0x29, + 0x4,0x69,0x74, 0x4,0x69,0x71, 0x3,0x66,0x72, 0x2,0x6f,0x62, + 0x2,0x6f,0x63, 0x2,0x6f,0x64, 0x3,0x61,0x2c, 0x1,0x7c,0x76, + 0x1,0x7d,0x30, 0x2,0x72,0x26, 0x1,0x58,0x6e, 0x3,0x4a,0x75, + 0x1,0x70,0x23, 0x1,0x73,0x34, 0x2,0x64,0x68, 0x3,0x5d,0x62, + 0x2,0x6e,0x53, 0x3,0x61,0x2e, 0x4,0x6d,0x37, 0x2,0x71,0x66, + 0x2,0x33,0x4d, 0x3,0x62,0x28, 0x1,0x7d,0x48, 0x1,0x58,0x6f, + 0x2,0x5b,0x7e, 0x3,0x57,0x3e, 0x2,0x64,0x69, 0x2,0x68,0x33, + 0x3,0x5d,0x63, 0x4,0x68,0x36, 0x2,0x6c,0x73, 0x2,0x6e,0x54, + 0x1,0x58,0x70, 0x3,0x45,0x62, 0x2,0x4f,0x45, 0x2,0x4f,0x46, + 0x3,0x4a,0x78, 0x1,0x6b,0x76, 0x1,0x6b,0x77, 0x2,0x56,0x24, + 0x1,0x70,0x25, 0x1,0x70,0x24, 0x2,0x56,0x23, 0x2,0x60,0x75, + 0x3,0x57,0x3f, 0x2,0x64,0x6a, 0x2,0x64,0x6c, 0x2,0x64,0x6b, + 0x1,0x77,0x7d, 0x1,0x77,0x7c, 0x1,0x77,0x7b, 0x3,0x5d,0x64, + 0x1,0x7b,0x4a, 0x2,0x6c,0x74, 0x3,0x5f,0x28, 0x1,0x7b,0x49, + 0x2,0x6e,0x56, 0x2,0x6e,0x55, 0x3,0x61,0x2f, 0x1,0x7c,0x77, + 0x2,0x70,0x63, 0x1,0x5e,0x23, 0x2,0x48,0x70, 0x4,0x42,0x29, + 0x3,0x45,0x63, 0x2,0x4f,0x49, 0x2,0x4f,0x47, 0x2,0x4f,0x48, + 0x4,0x48,0x6b, 0x3,0x4f,0x7e, 0x2,0x56,0x2d, 0x4,0x4f,0x30, + 0x2,0x56,0x28, 0x2,0x56,0x25, 0x2,0x56,0x2c, 0x3,0x4f,0x7c, + 0x4,0x4f,0x35, 0x3,0x4f,0x7b, 0x2,0x56,0x2e, 0x4,0x4f,0x37, + 0x4,0x4f,0x2c, 0x1,0x70,0x27, 0x2,0x56,0x2b, 0x2,0x56,0x27, + 0x3,0x4f,0x7d, 0x4,0x4f,0x2a, 0x2,0x56,0x26, 0x2,0x56,0x2a, + 0x2,0x56,0x29, 0x1,0x70,0x26, 0xf,0x53,0x3e, 0x2,0x5c,0x2b, + 0x2,0x5c,0x26, 0x2,0x5c,0x24, 0x2,0x5c,0x2d, 0x2,0x5c,0x25, + 0x4,0x55,0x47, 0x2,0x5c,0x21, 0x4,0x55,0x43, 0x2,0x5c,0x27, + 0x3,0x53,0x78, 0x3,0x53,0x7a, 0x2,0x5c,0x22, 0x2,0x60,0x7e, + 0x2,0x5c,0x23, 0x2,0x5c,0x2e, 0x3,0x54,0x23, 0x4,0x55,0x45, + 0x3,0x53,0x7c, 0x3,0x54,0x21, 0x5,0x5a,0x4a, 0x3,0x54,0x25, + 0x3,0x53,0x7d, 0x2,0x5c,0x2a, 0x1,0x73,0x35, 0x2,0x5c,0x29, + 0x2,0x5c,0x28, 0x3,0x53,0x79, 0x2,0x5c,0x2c, 0xf,0x59,0x38, + 0x3,0x66,0x73, 0x3,0x57,0x44, 0x2,0x60,0x76, 0x2,0x60,0x79, + 0x4,0x5a,0x49, 0x3,0x57,0x45, 0x2,0x60,0x78, 0x3,0x57,0x40, + 0x2,0x61,0x22, 0x2,0x60,0x7b, 0x2,0x61,0x21, 0x3,0x57,0x42, + 0x2,0x60,0x7d, 0x2,0x60,0x7c, 0x2,0x60,0x7a, 0x4,0x5a,0x41, + 0x2,0x60,0x77, 0x4,0x5a,0x3f, 0x1,0x76,0x2f, 0x1,0x76,0x2e, + 0x4,0x5a,0x44, 0x1,0x76,0x30, 0x1,0x76,0x2d, 0x2,0x61,0x23, + 0x4,0x5a,0x45, 0xf,0x5d,0x76, 0x4,0x5a,0x43, 0x2,0x64,0x72, + 0x2,0x64,0x75, 0x4,0x5f,0x26, 0x2,0x64,0x73, 0x2,0x64,0x77, + 0x5,0x66,0x79, 0x3,0x59,0x74, 0x4,0x5f,0x22, 0x2,0x64,0x78, + 0x4,0x5f,0x2a, 0x2,0x64,0x70, 0x1,0x78,0x24, 0x2,0x64,0x71, + 0x3,0x59,0x73, 0x2,0x64,0x6f, 0x2,0x64,0x76, 0x3,0x5b,0x74, + 0x2,0x64,0x6e, 0x2,0x64,0x6d, 0x1,0x78,0x23, 0x1,0x78,0x21, + 0x1,0x77,0x7e, 0x3,0x59,0x76, 0x3,0x59,0x75, 0x3,0x57,0x43, + 0xf,0x61,0x72, 0x3,0x59,0x71, 0x2,0x64,0x74, 0x2,0x68,0x3c, + 0x2,0x68,0x42, 0x1,0x79,0x56, 0x2,0x68,0x3d, 0x5,0x6b,0x33, + 0x2,0x68,0x40, 0x2,0x68,0x44, 0x1,0x79,0x57, 0x2,0x68,0x3f, + 0x4,0x62,0x5c, 0x2,0x68,0x37, 0x3,0x5b,0x75, 0x2,0x68,0x36, + 0x2,0x68,0x43, 0x2,0x68,0x3a, 0x3,0x5b,0x77, 0x2,0x68,0x38, + 0x2,0x68,0x41, 0x2,0x68,0x39, 0x1,0x79,0x55, 0x1,0x79,0x54, + 0x3,0x5b,0x79, 0x2,0x68,0x34, 0x2,0x68,0x35, 0x2,0x68,0x3e, + 0x4,0x62,0x66, 0x3,0x5b,0x7a, 0x4,0x62,0x68, 0x2,0x68,0x3b, + 0xf,0x64,0x6b, 0x4,0x62,0x55, 0x3,0x5d,0x6f, 0x2,0x6a,0x7a, + 0x2,0x6a,0x7d, 0x3,0x5d,0x71, 0x4,0x62,0x56, 0x3,0x5d,0x67, + 0x3,0x5d,0x69, 0x1,0x78,0x22, 0x3,0x5d,0x6a, 0x3,0x5d,0x74, + 0x3,0x5d,0x75, 0x4,0x65,0x5a, 0x3,0x5d,0x6e, 0x4,0x65,0x59, + 0x3,0x5d,0x68, 0x2,0x6a,0x7b, 0x2,0x6b,0x23, 0x2,0x6b,0x21, + 0x2,0x6a,0x79, 0x2,0x6b,0x26, 0x3,0x5d,0x66, 0x2,0x6a,0x78, + 0x3,0x5d,0x76, 0x1,0x7a,0x5a, 0x2,0x6b,0x22, 0x4,0x65,0x54, + 0x3,0x5d,0x73, 0x4,0x65,0x57, 0x2,0x6a,0x7c, 0x1,0x7a,0x59, + 0x2,0x6b,0x25, 0x3,0x5d,0x72, 0x4,0x65,0x5d, 0x2,0x6b,0x24, + 0x3,0x5d,0x70, 0x2,0x6c,0x77, 0x2,0x6c,0x76, 0x5,0x72,0x51, + 0x3,0x5f,0x2c, 0x5,0x72,0x4b, 0x2,0x6c,0x7d, 0x5,0x72,0x4e, + 0x2,0x6c,0x79, 0x2,0x6c,0x7c, 0x1,0x7b,0x4c, 0x4,0x68,0x3b, + 0x4,0x68,0x3e, 0x2,0x6c,0x7a, 0x2,0x6c,0x7b, 0x4,0x68,0x39, + 0x2,0x6c,0x75, 0x2,0x6c,0x78, 0x1,0x7b,0x4b, 0x3,0x5f,0x2a, + 0xf,0x69,0x2a, 0x1,0x7c,0x2b, 0x2,0x6e,0x61, 0x2,0x6e,0x5c, + 0x2,0x6e,0x60, 0x3,0x60,0x25, 0x2,0x6e,0x63, 0x2,0x6e,0x5f, + 0x3,0x5f,0x7e, 0x2,0x6e,0x5b, 0x3,0x60,0x23, 0x1,0x7c,0x2d, + 0x2,0x6e,0x5e, 0x2,0x6e,0x62, 0x1,0x7c,0x2c, 0x2,0x6e,0x59, + 0x2,0x6a,0x7e, 0x2,0x6e,0x5d, 0x4,0x6a,0x23, 0x5,0x75,0x2d, + 0x2,0x6e,0x5a, 0x3,0x60,0x22, 0x2,0x6e,0x57, 0xf,0x6a,0x3e, + 0x2,0x6e,0x58, 0x1,0x7c,0x2a, 0x2,0x6f,0x68, 0x2,0x6f,0x6a, + 0x2,0x6f,0x6d, 0x2,0x6f,0x69, 0x2,0x6f,0x6e, 0x3,0x60,0x65, + 0x2,0x6f,0x67, 0x3,0x60,0x66, 0x2,0x6f,0x65, 0x3,0x60,0x68, + 0x1,0x7c,0x57, 0x2,0x6f,0x6b, 0x1,0x7c,0x59, 0x1,0x7c,0x58, + 0x2,0x6f,0x66, 0x2,0x6f,0x6c, 0x3,0x61,0x32, 0x2,0x70,0x68, + 0x1,0x7c,0x78, 0x2,0x70,0x69, 0x3,0x61,0x33, 0x2,0x70,0x67, + 0x2,0x70,0x64, 0x4,0x6c,0x4a, 0x3,0x61,0x34, 0x2,0x70,0x66, + 0x2,0x70,0x65, 0x2,0x71,0x49, 0x3,0x61,0x59, 0x2,0x71,0x4b, + 0x2,0x71,0x4a, 0x3,0x61,0x5b, 0x2,0x71,0x69, 0x5,0x7a,0x53, + 0x2,0x71,0x68, 0x2,0x71,0x67, 0x2,0x71,0x6a, 0x3,0x61,0x75, + 0x1,0x7d,0x40, 0x1,0x7d,0x41, 0x2,0x72,0x38, 0x2,0x72,0x3c, + 0x3,0x62,0x41, 0x1,0x5e,0x24, 0x2,0x41,0x54, 0x2,0x48,0x73, + 0x3,0x45,0x64, 0x1,0x67,0x6d, 0x2,0x48,0x71, 0x3,0x45,0x66, + 0x3,0x2f,0x42, 0x2,0x48,0x72, 0x3,0x45,0x68, 0x3,0x45,0x67, + 0x2,0x4f,0x4a, 0x2,0x4f,0x4b, 0x1,0x6b,0x7a, 0x1,0x6b,0x78, + 0x2,0x4f,0x4c, 0x1,0x6b,0x79, 0x2,0x56,0x33, 0x3,0x50,0x27, + 0x2,0x56,0x36, 0x2,0x56,0x30, 0x2,0x56,0x37, 0x2,0x56,0x2f, + 0x2,0x56,0x31, 0x3,0x50,0x2a, 0x2,0x56,0x32, 0x2,0x56,0x35, + 0x3,0x50,0x24, 0x3,0x50,0x2b, 0x1,0x70,0x2a, 0x2,0x56,0x3a, + 0x2,0x56,0x39, 0x1,0x70,0x28, 0x2,0x56,0x34, 0x2,0x56,0x38, + 0x1,0x70,0x29, 0x3,0x54,0x2d, 0x4,0x4f,0x42, 0x3,0x50,0x25, + 0x3,0x50,0x22, 0x3,0x54,0x2a, 0x2,0x5c,0x38, 0x4,0x55,0x52, + 0x1,0x73,0x3a, 0x3,0x54,0x2c, 0x2,0x5c,0x33, 0x1,0x73,0x36, + 0x3,0x54,0x36, 0x2,0x5c,0x30, 0x2,0x5c,0x36, 0x2,0x5c,0x39, + 0x3,0x54,0x33, 0x1,0x73,0x3b, 0x4,0x5a,0x4e, 0x2,0x5c,0x35, + 0x2,0x5c,0x32, 0x2,0x5c,0x3a, 0x2,0x5c,0x31, 0x3,0x54,0x37, + 0x2,0x5c,0x37, 0x1,0x73,0x37, 0x3,0x54,0x29, 0x2,0x5c,0x2f, + 0x1,0x73,0x38, 0x3,0x54,0x35, 0x1,0x73,0x39, 0x2,0x5c,0x34, + 0x3,0x54,0x32, 0x2,0x61,0x35, 0x2,0x61,0x28, 0x2,0x61,0x29, + 0x2,0x61,0x2c, 0x2,0x61,0x2a, 0x4,0x5a,0x55, 0x2,0x61,0x24, + 0x4,0x5a,0x56, 0x3,0x57,0x4d, 0x2,0x61,0x27, 0x2,0x61,0x31, + 0x2,0x61,0x2b, 0x3,0x57,0x48, 0x4,0x5a,0x4f, 0x1,0x76,0x31, + 0x4,0x5a,0x4d, 0x2,0x61,0x33, 0x2,0x61,0x30, 0x1,0x76,0x32, + 0x2,0x61,0x32, 0x2,0x61,0x25, 0x2,0x61,0x2e, 0x2,0x61,0x2f, + 0x3,0x57,0x4a, 0x2,0x61,0x2d, 0xf,0x5e,0x24, 0x3,0x66,0x75, + 0x2,0x64,0x7c, 0x2,0x64,0x7e, 0x2,0x65,0x23, 0x3,0x59,0x79, + 0x3,0x59,0x7b, 0x2,0x64,0x7b, 0x3,0x59,0x7d, 0x1,0x78,0x25, + 0x2,0x65,0x25, 0x2,0x64,0x7a, 0x2,0x65,0x26, 0x3,0x59,0x7e, + 0x2,0x65,0x22, 0x2,0x65,0x24, 0x2,0x65,0x28, 0x2,0x65,0x21, + 0x2,0x65,0x29, 0x2,0x64,0x7d, 0x2,0x64,0x79, 0x1,0x78,0x26, + 0x3,0x5a,0x22, 0x2,0x65,0x27, 0x1,0x78,0x27, 0x1,0x79,0x59, + 0x4,0x5f,0x34, 0x3,0x59,0x7a, 0xf,0x61,0x77, 0x3,0x5b,0x7d, + 0x2,0x61,0x26, 0x2,0x68,0x5e, 0x2,0x68,0x55, 0x1,0x79,0x5b, + 0x2,0x68,0x51, 0x1,0x79,0x5c, 0x3,0x5c,0x27, 0x3,0x5c,0x22, + 0x2,0x68,0x5a, 0x2,0x68,0x54, 0x2,0x68,0x4a, 0x1,0x79,0x5a, + 0x2,0x68,0x57, 0x2,0x68,0x52, 0x2,0x68,0x53, 0x3,0x5c,0x25, + 0x2,0x68,0x45, 0x2,0x68,0x4c, 0x2,0x68,0x5b, 0x3,0x5b,0x7e, + 0x2,0x68,0x58, 0x5,0x6b,0x3f, 0x2,0x68,0x50, 0x3,0x5c,0x26, + 0x2,0x68,0x5c, 0x2,0x68,0x4b, 0x2,0x68,0x46, 0x2,0x68,0x59, + 0x3,0x5c,0x24, 0x2,0x68,0x48, 0x2,0x68,0x56, 0x2,0x68,0x4d, + 0x2,0x68,0x5d, 0x2,0x68,0x49, 0x1,0x79,0x58, 0x2,0x68,0x47, + 0x2,0x68,0x4e, 0x2,0x68,0x4f, 0x2,0x6b,0x2d, 0x3,0x5c,0x23, + 0x2,0x6b,0x2b, 0x4,0x65,0x69, 0x2,0x6b,0x30, 0x3,0x5d,0x79, + 0x2,0x6b,0x3c, 0x2,0x6b,0x33, 0x2,0x6b,0x2c, 0x2,0x6b,0x28, + 0x2,0x6b,0x35, 0x2,0x6b,0x2e, 0x2,0x6b,0x31, 0x2,0x6b,0x2a, + 0x2,0x6b,0x38, 0x2,0x6b,0x27, 0x2,0x6b,0x2f, 0x2,0x6b,0x34, + 0x2,0x6b,0x36, 0x2,0x6b,0x39, 0x2,0x6b,0x29, 0x3,0x5d,0x7a, + 0x2,0x6b,0x3d, 0x2,0x6b,0x3e, 0x2,0x6b,0x37, 0x2,0x6b,0x3b, + 0x2,0x6b,0x32, 0x2,0x6d,0x2f, 0x2,0x6d,0x32, 0x3,0x5f,0x35, + 0x1,0x7b,0x4d, 0x3,0x5f,0x31, 0x2,0x6d,0x31, 0x2,0x6d,0x36, + 0x2,0x6d,0x34, 0x1,0x7b,0x4e, 0x2,0x6d,0x2b, 0x2,0x6d,0x21, + 0x2,0x6c,0x7e, 0x1,0x7b,0x50, 0x2,0x6d,0x2d, 0x2,0x6d,0x2e, + 0x2,0x6d,0x2a, 0x2,0x6d,0x22, 0x3,0x5f,0x32, 0x2,0x6d,0x27, + 0x2,0x6b,0x3a, 0x4,0x68,0x43, 0x2,0x6d,0x23, 0x1,0x7b,0x4f, + 0x2,0x6d,0x29, 0x3,0x5f,0x36, 0x2,0x6d,0x28, 0x2,0x6d,0x24, + 0x2,0x6d,0x30, 0x4,0x68,0x44, 0x2,0x6d,0x25, 0x2,0x6e,0x68, + 0x2,0x6d,0x33, 0x2,0x6d,0x35, 0x2,0x6d,0x2c, 0x2,0x6d,0x26, + 0x2,0x6e,0x69, 0x2,0x6e,0x6b, 0x2,0x6e,0x65, 0x1,0x7c,0x2e, + 0x4,0x6a,0x25, 0x2,0x6e,0x72, 0x2,0x6e,0x70, 0x1,0x7c,0x2f, + 0x2,0x6e,0x6f, 0x2,0x6e,0x6e, 0x2,0x6e,0x67, 0x2,0x6e,0x64, + 0x2,0x6e,0x6a, 0x2,0x6e,0x73, 0x2,0x6e,0x66, 0x2,0x6e,0x6c, + 0x5,0x75,0x45, 0x2,0x6f,0x77, 0x2,0x6f,0x7c, 0x2,0x6f,0x72, + 0x2,0x6f,0x75, 0x1,0x7c,0x5a, 0x2,0x6f,0x79, 0x4,0x6b,0x46, + 0x2,0x70,0x22, 0x2,0x6e,0x6d, 0x4,0x6b,0x4a, 0x2,0x6f,0x73, + 0x2,0x6f,0x7d, 0x2,0x70,0x23, 0x2,0x6f,0x78, 0x2,0x6f,0x71, + 0x2,0x6f,0x7b, 0x4,0x6b,0x4b, 0x2,0x6f,0x7a, 0x2,0x70,0x21, + 0x2,0x6f,0x7e, 0x2,0x6e,0x71, 0x2,0x6f,0x76, 0x2,0x6f,0x70, + 0x2,0x6f,0x74, 0x1,0x7c,0x79, 0x1,0x7c,0x7a, 0x2,0x6f,0x6f, + 0x3,0x60,0x6c, 0x2,0x70,0x74, 0x2,0x70,0x6b, 0x2,0x70,0x73, + 0x2,0x70,0x70, 0x2,0x70,0x71, 0x2,0x70,0x6a, 0x2,0x70,0x6d, + 0x2,0x70,0x75, 0x2,0x70,0x6f, 0x2,0x70,0x6e, 0x2,0x70,0x6c, + 0x3,0x61,0x35, 0x2,0x70,0x72, 0x4,0x6c,0x56, 0x2,0x71,0x4c, + 0x4,0x6d,0x3a, 0x2,0x71,0x4d, 0x3,0x61,0x5d, 0x2,0x71,0x4f, + 0x2,0x71,0x4e, 0x2,0x71,0x51, 0x2,0x71,0x50, 0x2,0x71,0x6c, + 0x2,0x71,0x6b, 0x2,0x72,0x27, 0x3,0x62,0x29, 0x2,0x72,0x28, + 0x3,0x62,0x30, 0x2,0x72,0x34, 0x1,0x7d,0x45, 0x1,0x7d,0x49, + 0x3,0x62,0x38, 0x2,0x72,0x3d, 0x1,0x7d,0x4a, 0x1,0x5e,0x25, + 0x4,0x4f,0x48, 0x5,0x5a,0x5b, 0x1,0x7a,0x5b, 0x2,0x6d,0x37, + 0x3,0x5f,0x37, 0x1,0x7c,0x7b, 0x1,0x7c,0x7c, 0x1,0x5e,0x26, + 0x2,0x48,0x74, 0x3,0x45,0x69, 0x1,0x67,0x6e, 0x2,0x56,0x3b, + 0x3,0x50,0x2c, 0x3,0x54,0x39, 0x2,0x5c,0x3c, 0x2,0x5c,0x3d, + 0x2,0x5c,0x3b, 0x2,0x61,0x37, 0x2,0x61,0x36, 0x1,0x76,0x33, + 0x2,0x65,0x2b, 0x2,0x61,0x38, 0x2,0x65,0x2a, 0x4,0x5f,0x3a, + 0x3,0x5a,0x24, 0x2,0x68,0x60, 0x1,0x79,0x5d, 0x1,0x79,0x5f, + 0x2,0x68,0x5f, 0x3,0x5c,0x29, 0x4,0x62,0x75, 0x1,0x79,0x5e, + 0x3,0x5e,0x21, 0x2,0x6b,0x3f, 0x2,0x6b,0x41, 0x2,0x6b,0x40, + 0x2,0x6d,0x38, 0x1,0x7b,0x51, 0x3,0x5f,0x3a, 0x1,0x7c,0x5b, + 0x2,0x70,0x76, 0x2,0x71,0x52, 0x3,0x62,0x31, 0x3,0x62,0x3f, + 0x2,0x72,0x41, 0x1,0x5e,0x27, 0x3,0x25,0x47, 0x2,0x4f,0x4d, + 0x4,0x4f,0x4c, 0x1,0x70,0x2b, 0x3,0x50,0x2f, 0x3,0x50,0x2e, + 0x3,0x54,0x3a, 0x2,0x5c,0x3f, 0x2,0x5c,0x3e, 0x3,0x57,0x50, + 0x2,0x61,0x39, 0x3,0x5a,0x26, 0x3,0x5a,0x25, 0x4,0x62,0x7e, + 0x1,0x79,0x60, 0x1,0x7a,0x5c, 0x2,0x6e,0x74, 0x2,0x72,0x39, + 0x1,0x5e,0x28, 0x1,0x6b,0x7b, 0x3,0x4b,0x22, 0x1,0x70,0x2c, + 0xf,0x61,0x7c, 0x2,0x68,0x61, 0x3,0x5e,0x22, 0x2,0x70,0x24, + 0x1,0x63,0x27, 0x3,0x39,0x6a, 0x3,0x54,0x3c, 0x3,0x54,0x3b, + 0x4,0x5a,0x5d, 0x2,0x61,0x3a, 0x3,0x5a,0x28, 0x4,0x5f,0x3e, + 0x1,0x7d,0x31, 0x1,0x63,0x28, 0x1,0x70,0x2d, 0x1,0x76,0x34, + 0x2,0x70,0x25, 0x1,0x63,0x29, 0x3,0x39,0x6b, 0x2,0x56,0x3c, + 0x1,0x73,0x3d, 0x2,0x5c,0x40, 0x2,0x5c,0x41, 0x3,0x54,0x3d, + 0x1,0x73,0x3c, 0x4,0x55,0x60, 0x2,0x61,0x3b, 0x1,0x76,0x38, + 0x1,0x76,0x36, 0x1,0x76,0x37, 0x1,0x76,0x35, 0x2,0x65,0x2c, + 0x1,0x78,0x28, 0x4,0x63,0x24, 0x3,0x5c,0x2a, 0x2,0x6b,0x43, + 0x2,0x6b,0x42, 0x2,0x6b,0x45, 0x2,0x6b,0x44, 0x1,0x7a,0x5d, + 0x2,0x6d,0x39, 0x4,0x68,0x56, 0x2,0x6d,0x3b, 0x2,0x6d,0x3a, + 0x1,0x7b,0x52, 0x2,0x6e,0x75, 0x3,0x60,0x29, 0x2,0x70,0x26, + 0x2,0x70,0x27, 0x1,0x7c,0x5c, 0x2,0x71,0x53, 0x2,0x71,0x6d, + 0x1,0x7d,0x42, 0x4,0x6e,0x43, 0x2,0x41,0x55, 0x2,0x5c,0x42, + 0x2,0x61,0x3c, 0x2,0x68,0x62, 0x2,0x48,0x75, 0x3,0x27,0x72, + 0x2,0x61,0x3d, 0x2,0x65,0x2e, 0x2,0x65,0x2d, 0x3,0x5a,0x29, + 0x3,0x5c,0x2d, 0x3,0x5c,0x2e, 0x3,0x5f,0x3c, 0x2,0x70,0x28, + 0x1,0x7c,0x7d, 0x3,0x61,0x5f, 0x2,0x71,0x54, 0x2,0x71,0x6e, + 0x1,0x67,0x6f, 0x2,0x56,0x3d, 0x2,0x56,0x3e, 0x4,0x4f,0x56, + 0x2,0x5c,0x43, 0x1,0x67,0x70, 0x3,0x45,0x6a, 0x1,0x78,0x29, + 0x2,0x65,0x2f, 0x3,0x5c,0x30, 0x2,0x6d,0x3d, 0x1,0x7b,0x53, + 0x2,0x6d,0x3e, 0x2,0x6d,0x3c, 0x2,0x70,0x29, 0x3,0x61,0x60, + 0x2,0x70,0x77, 0x4,0x6d,0x48, 0x1,0x67,0x71, 0x2,0x61,0x40, + 0x2,0x61,0x3f, 0x2,0x61,0x3e, 0x2,0x65,0x30, 0x3,0x5a,0x2b, + 0x3,0x5a,0x2a, 0x2,0x65,0x34, 0x2,0x65,0x33, 0x2,0x65,0x32, + 0x2,0x65,0x31, 0x1,0x78,0x2a, 0x2,0x68,0x63, 0x2,0x6b,0x47, + 0x1,0x7a,0x5e, 0x2,0x6b,0x46, 0x2,0x6d,0x3f, 0x2,0x6e,0x78, + 0x2,0x6e,0x77, 0x1,0x7c,0x30, 0x2,0x6e,0x76, 0x2,0x70,0x2c, + 0x2,0x70,0x2b, 0x2,0x70,0x2a, 0x3,0x60,0x6d, 0x4,0x6e,0x44, + 0x1,0x6b,0x7c, 0x4,0x55,0x63, 0x2,0x5c,0x44, 0x1,0x76,0x39, + 0x4,0x5a,0x64, 0x2,0x68,0x64, 0x2,0x68,0x65, 0x2,0x6e,0x79, + 0x2,0x70,0x2d, 0x4,0x6b,0x5c, 0x3,0x61,0x3b, 0x2,0x70,0x78, + 0x2,0x71,0x55, 0x2,0x72,0x29, 0x2,0x72,0x43, 0x1,0x6b,0x7d, + 0x1,0x76,0x3a, 0x2,0x65,0x35, 0x2,0x68,0x66, 0x2,0x6d,0x40, + 0x2,0x70,0x2e, 0x3,0x23,0x70, 0x1,0x70,0x2f, 0x3,0x54,0x3e, + 0x2,0x61,0x41, 0x2,0x65,0x36, 0x2,0x68,0x67, 0x2,0x68,0x68, + 0x2,0x68,0x69, 0x2,0x6b,0x4c, 0x3,0x5e,0x24, 0x2,0x6b,0x48, + 0x1,0x7b,0x54, 0x2,0x6b,0x4b, 0x2,0x6b,0x4a, 0x1,0x7a,0x5f, + 0x2,0x6b,0x49, 0x1,0x7a,0x61, 0x1,0x7a,0x60, 0x2,0x6d,0x42, + 0x2,0x6d,0x41, 0x1,0x7b,0x55, 0x1,0x7b,0x56, 0x4,0x68,0x60, + 0x3,0x5f,0x3e, 0x1,0x7c,0x32, 0x2,0x6e,0x7a, 0x1,0x7c,0x31, + 0x4,0x6b,0x61, 0x2,0x70,0x31, 0x2,0x70,0x32, 0x2,0x70,0x30, + 0x2,0x70,0x2f, 0x1,0x7d,0x21, 0x4,0x6c,0x64, 0x2,0x70,0x79, + 0x2,0x70,0x7a, 0x2,0x70,0x7b, 0x1,0x7c,0x7e, 0x2,0x71,0x56, + 0x2,0x71,0x59, 0x2,0x71,0x58, 0x2,0x71,0x57, 0x3,0x62,0x33, + 0x4,0x6e,0x45, 0x2,0x72,0x42, 0x1,0x73,0x3e, 0x3,0x57,0x55, + 0x4,0x63,0x2d, 0x1,0x78,0x32, 0x2,0x6b,0x4d, 0x2,0x6d,0x43, + 0x3,0x60,0x2b, 0x1,0x7c,0x33, 0x2,0x6e,0x7b, 0x4,0x6e,0x55, + 0x3,0x62,0x42, 0x2,0x72,0x44, 0xf,0x21,0x59, 0x1,0x73,0x3f, + 0x3,0x5e,0x47, 0x4,0x6e,0x33, 0x2,0x61,0x42, 0x3,0x5f,0x3f, + 0x2,0x6e,0x7c, 0x3,0x61,0x61, 0x2,0x71,0x6f, 0x3,0x61,0x77, + 0xf,0x58,0x4c, 0x1,0x21,0x2b, 0x1,0x21,0x36, 0x1,0x21,0x38, + 0x1,0x21,0x40, 0x1,0x21,0x41, 0x1,0x21,0x44, 0x1,0x21,0x45, + 0x1,0x21,0x48, 0x1,0x21,0x49, 0x1,0x21,0x4c, 0x1,0x21,0x4d, + 0x1,0x21,0x50, 0x1,0x21,0x51, 0x1,0x21,0x54, 0x1,0x21,0x55, + 0x1,0x21,0x58, 0x1,0x21,0x59, 0x1,0x21,0x5c, 0x1,0x21,0x5d, + 0x1,0x22,0x27, 0x1,0x22,0x28, 0x1,0x22,0x2b, 0x1,0x22,0x2c, + 0x1,0x22,0x29, 0x1,0x22,0x2a, 0x1,0x21,0x2e, 0x1,0x21,0x2f, + 0x1,0x21,0x30, 0x1,0x21,0x32, 0x1,0x21,0x33, 0x1,0x21,0x34, + 0x1,0x21,0x35, 0x1,0x21,0x5e, 0x1,0x21,0x5f, 0x1,0x21,0x60, + 0x1,0x21,0x61, 0x1,0x21,0x62, 0x1,0x21,0x63, 0x1,0x22,0x2d, + 0x1,0x22,0x2e, 0x1,0x22,0x2f, 0x1,0x22,0x3f, 0x1,0x22,0x40, + 0x1,0x22,0x41, 0x1,0x22,0x43, 0x1,0x22,0x42, 0x1,0x22,0x62, + 0x1,0x22,0x6c, 0x1,0x22,0x6d, 0x1,0x22,0x6e, 0x1,0x21,0x2a, + 0x1,0x21,0x6c, 0x1,0x22,0x63, 0x1,0x22,0x68, 0x1,0x21,0x6d, + 0x1,0x21,0x3e, 0x1,0x21,0x3f, 0x1,0x21,0x6e, 0x1,0x22,0x30, + 0x1,0x21,0x22, 0x1,0x22,0x31, 0x1,0x21,0x25, 0x1,0x22,0x5f, + 0x1,0x24,0x21, 0x1,0x24,0x22, 0x1,0x24,0x23, 0x1,0x24,0x24, + 0x1,0x24,0x25, 0x1,0x24,0x26, 0x1,0x24,0x27, 0x1,0x24,0x28, + 0x1,0x24,0x29, 0x1,0x24,0x2a, 0x1,0x21,0x28, 0x1,0x21,0x27, + 0x1,0x22,0x36, 0x1,0x22,0x38, 0x1,0x22,0x37, 0x1,0x21,0x29, + 0x1,0x22,0x69, 0x1,0x24,0x41, 0x1,0x24,0x42, 0x1,0x24,0x43, + 0x1,0x24,0x44, 0x1,0x24,0x45, 0x1,0x24,0x46, 0x1,0x24,0x47, + 0x1,0x24,0x48, 0x1,0x24,0x49, 0x1,0x24,0x4a, 0x1,0x24,0x4b, + 0x1,0x24,0x4c, 0x1,0x24,0x4d, 0x1,0x24,0x4e, 0x1,0x24,0x4f, + 0x1,0x24,0x50, 0x1,0x24,0x51, 0x1,0x24,0x52, 0x1,0x24,0x53, + 0x1,0x24,0x54, 0x1,0x24,0x55, 0x1,0x24,0x56, 0x1,0x24,0x57, + 0x1,0x24,0x58, 0x1,0x24,0x59, 0x1,0x24,0x5a, 0x1,0x22,0x60, + 0x1,0x22,0x25, 0x1,0x24,0x5b, 0x1,0x24,0x5c, 0x1,0x24,0x5d, + 0x1,0x24,0x5e, 0x1,0x24,0x5f, 0x1,0x24,0x60, 0x1,0x24,0x61, + 0x1,0x24,0x62, 0x1,0x24,0x63, 0x1,0x24,0x64, 0x1,0x24,0x65, + 0x1,0x24,0x66, 0x1,0x24,0x67, 0x1,0x24,0x68, 0x1,0x24,0x69, + 0x1,0x24,0x6a, 0x1,0x24,0x6b, 0x1,0x24,0x6c, 0x1,0x24,0x6d, + 0x1,0x24,0x6e, 0x1,0x24,0x6f, 0x1,0x24,0x70, 0x1,0x24,0x71, + 0x1,0x24,0x72, 0x1,0x24,0x73, 0x1,0x24,0x74, 0x1,0x21,0x42, + 0x1,0x22,0x5e, 0x1,0x21,0x43, 0x1,0x22,0x66, 0x1,0x22,0x67, + 0x1,0x22,0x64, 0x5,0x21,0x25, 0xf,0x21,0x21, 0x6,0x21,0x2f, + 0x6,0x21,0x2d, 0x6,0x21,0x2e, 0x6,0x21,0x42, 0x6,0x21,0x43, + 0x5,0x21,0x33, 0x3,0x21,0x44, 0xf,0x21,0x3e, 0xf,0x21,0x3f, + 0x6,0x22,0x2b, 0x5,0x21,0x4d, 0x6,0x23,0x40, 0x6,0x23,0x3e, + 0x6,0x23,0x3f, 0x6,0x24,0x67, 0x6,0x25,0x5f, 0x5,0x23,0x2f, + 0xf,0x22,0x74, 0x6,0x25,0x67, 0x6,0x25,0x63, 0x6,0x29,0x37, + 0x6,0x29,0x3a, 0x6,0x29,0x38, 0xf,0x29,0x22, 0xf,0x29,0x23, + 0x6,0x2e,0x66, 0x5,0x30,0x72, 0x5,0x33,0x23, 0xf,0x39,0x32, + 0xf,0x39,0x33, 0x6,0x47,0x2d, 0xf,0x3b,0x73, 0xf,0x40,0x35, + 0xf,0x40,0x75, 0xf,0x47,0x42, 0xf,0x4d,0x56, 0x7,0x21,0x21, + 0xf,0x59,0x47, 0x4,0x4f,0x7c, 0xf,0x5a,0x3f, 0x6,0x21,0x2c, + 0x6,0x21,0x22, 0x6,0x22,0x5f, 0x4,0x21,0x56, 0x6,0x23,0x41, + 0x6,0x25,0x60, 0x6,0x29,0x3b, 0x5,0x25,0x21, 0x5,0x27,0x7a, + 0x6,0x2e,0x4a, 0xf,0x29,0x50, 0x6,0x35,0x25, 0x6,0x35,0x26, + 0x6,0x45,0x7d, 0x6,0x46,0x3f, 0xf,0x46,0x40, 0x5,0x44,0x7e, + 0x6,0x21,0x32, 0x5,0x21,0x2d, 0x6,0x22,0x2d, 0x6,0x23,0x42, + 0xf,0x2d,0x61, 0x6,0x50,0x50, 0xf,0x53,0x44, 0x4,0x21,0x21, + 0x5,0x21,0x26, 0x6,0x21,0x24, 0xf,0x21,0x22, 0x6,0x21,0x33, + 0x6,0x21,0x44, 0xf,0x21,0x25, 0xf,0x21,0x26, 0x5,0x21,0x4e, + 0x6,0x22,0x30, 0xf,0x21,0x45, 0x6,0x22,0x4e, 0x6,0x22,0x2f, + 0xf,0x21,0x40, 0xf,0x21,0x41, 0x6,0x21,0x45, 0x6,0x22,0x31, + 0x6,0x22,0x2e, 0x4,0x22,0x26, 0x4,0x22,0x25, 0x5,0x22,0x24, + 0x5,0x22,0x25, 0x6,0x23,0x43, 0x6,0x29,0x3e, 0x6,0x24,0x5d, + 0x6,0x25,0x56, 0x6,0x25,0x61, 0x6,0x25,0x62, 0x6,0x2c,0x43, + 0x6,0x29,0x3c, 0x6,0x3a,0x65, 0xf,0x29,0x25, 0x6,0x2d,0x2d, + 0x6,0x29,0x3d, 0x6,0x2e,0x4b, 0x5,0x2b,0x67, 0x6,0x35,0x2a, + 0x6,0x35,0x27, 0x6,0x39,0x64, 0x6,0x35,0x29, 0x6,0x3c,0x7b, + 0x6,0x45,0x7e, 0x6,0x46,0x40, 0x6,0x46,0x41, 0x5,0x3d,0x56, + 0x5,0x21,0x23, 0x5,0x21,0x22, 0x6,0x21,0x26, 0x6,0x21,0x25, + 0x5,0x21,0x21, 0x5,0x21,0x2b, 0xf,0x21,0x23, 0x6,0x21,0x46, + 0x5,0x21,0x34, 0xf,0x21,0x27, 0xf,0x21,0x28, 0x6,0x22,0x33, + 0x6,0x22,0x32, 0x6,0x22,0x2a, 0x5,0x21,0x4f, 0x6,0x23,0x46, + 0x6,0x23,0x44, 0xf,0x21,0x6e, 0x6,0x23,0x45, 0xf,0x22,0x75, + 0x6,0x29,0x3f, 0x6,0x2d,0x2c, 0x4,0x26,0x24, 0x6,0x2e,0x4d, + 0x6,0x2e,0x4e, 0xf,0x25,0x40, 0x6,0x2e,0x4c, 0x6,0x35,0x2b, + 0xf,0x2d,0x60, 0x6,0x3c,0x7e, 0x5,0x30,0x73, 0x6,0x3c,0x7d, + 0xf,0x39,0x34, 0x6,0x50,0x51, 0x5,0x44,0x55, 0xf,0x46,0x41, + 0x6,0x5a,0x63, 0x6,0x5a,0x62, 0x7,0x36,0x73, 0x7,0x46,0x27, + 0x7,0x4d,0x3a, 0x5,0x21,0x24, 0x5,0x21,0x27, 0x4,0x21,0x28, + 0x5,0x21,0x28, 0x5,0x21,0x2c, 0x6,0x21,0x47, 0x6,0x21,0x48, + 0x6,0x21,0x49, 0x6,0x23,0x47, 0x5,0x23,0x30, 0x6,0x25,0x64, + 0x6,0x29,0x40, 0x5,0x30,0x74, 0x6,0x46,0x42, 0x7,0x2c,0x3c, + 0x6,0x21,0x27, 0x6,0x21,0x28, 0x6,0x21,0x29, 0x6,0x21,0x4a, + 0x6,0x25,0x65, 0x6,0x23,0x48, 0x6,0x23,0x49, 0x6,0x25,0x68, + 0xf,0x22,0x76, 0x4,0x25,0x33, 0x5,0x25,0x22, 0x4,0x25,0x32, + 0x6,0x2e,0x50, 0x5,0x27,0x7b, 0xf,0x29,0x27, 0x6,0x30,0x7c, + 0x6,0x35,0x2d, 0x6,0x35,0x2c, 0xf,0x2d,0x62, 0x6,0x3d,0x21, + 0xf,0x4d,0x6e, 0x6,0x23,0x4a, 0xf,0x21,0x6f, 0xf,0x21,0x70, + 0xf,0x22,0x2b, 0x5,0x23,0x31, 0xf,0x22,0x77, 0xf,0x22,0x78, + 0xf,0x22,0x79, 0x5,0x25,0x23, 0x6,0x29,0x41, 0xf,0x25,0x43, + 0x6,0x2e,0x52, 0x6,0x2e,0x51, 0xf,0x29,0x28, 0x6,0x35,0x2f, + 0x5,0x2c,0x66, 0x4,0x2b,0x5f, 0x6,0x35,0x30, 0xf,0x2d,0x63, + 0x6,0x35,0x31, 0x6,0x46,0x43, 0x6,0x3d,0x23, 0x6,0x3d,0x22, + 0x4,0x30,0x44, 0x5,0x30,0x75, 0xf,0x32,0x74, 0xf,0x32,0x75, + 0xf,0x32,0x72, 0x6,0x46,0x45, 0x6,0x46,0x44, 0x6,0x46,0x46, + 0x4,0x36,0x2f, 0xf,0x39,0x35, 0xf,0x39,0x36, 0xf,0x39,0x37, + 0x6,0x4c,0x2d, 0xf,0x40,0x36, 0xf,0x40,0x37, 0xf,0x40,0x38, + 0xf,0x46,0x42, 0x6,0x50,0x52, 0x5,0x4b,0x71, 0x7,0x21,0x22, + 0xf,0x4d,0x57, 0xf,0x4d,0x58, 0xf,0x4d,0x59, 0x7,0x26,0x79, + 0x7,0x21,0x24, 0x7,0x21,0x23, 0x7,0x21,0x46, 0x7,0x2c,0x3f, + 0x5,0x53,0x53, 0x7,0x2c,0x3e, 0x7,0x2c,0x3d, 0x7,0x46,0x23, + 0x7,0x46,0x28, 0x6,0x21,0x34, 0x6,0x21,0x35, 0xf,0x21,0x24, + 0x6,0x21,0x4c, 0xf,0x21,0x29, 0x6,0x21,0x4b, 0x3,0x21,0x6f, + 0xf,0x21,0x43, 0x6,0x22,0x35, 0x6,0x22,0x34, 0x6,0x22,0x36, + 0x4,0x21,0x58, 0x4,0x22,0x2c, 0x4,0x22,0x2b, 0x4,0x22,0x29, + 0x6,0x23,0x4f, 0x4,0x22,0x30, 0x6,0x23,0x50, 0x5,0x22,0x27, + 0x6,0x23,0x4d, 0x6,0x23,0x4c, 0x4,0x22,0x2f, 0x6,0x23,0x4b, + 0xf,0x21,0x73, 0xf,0x21,0x74, 0xf,0x21,0x75, 0xf,0x21,0x76, + 0xf,0x21,0x77, 0xf,0x21,0x78, 0xf,0x21,0x79, 0x5,0x22,0x28, + 0x6,0x23,0x51, 0x5,0x22,0x26, 0xf,0x21,0x7a, 0x5,0x23,0x32, + 0x6,0x25,0x6a, 0x4,0x23,0x3a, 0x6,0x25,0x6b, 0x6,0x25,0x74, + 0x6,0x25,0x70, 0x6,0x25,0x6c, 0xf,0x22,0x7a, 0xf,0x22,0x7b, + 0xf,0x22,0x7c, 0xf,0x22,0x7d, 0xf,0x23,0x21, 0xf,0x23,0x22, + 0xf,0x23,0x23, 0xf,0x23,0x25, 0xf,0x23,0x28, 0xf,0x23,0x29, + 0xf,0x23,0x2a, 0xf,0x23,0x2b, 0xf,0x23,0x2c, 0x4,0x23,0x38, + 0x6,0x25,0x6d, 0x6,0x25,0x6f, 0xf,0x23,0x26, 0x6,0x25,0x6e, + 0x6,0x25,0x69, 0x5,0x23,0x33, 0x6,0x25,0x73, 0x6,0x29,0x43, + 0x6,0x29,0x45, 0x4,0x25,0x3a, 0x5,0x25,0x28, 0x6,0x29,0x46, + 0x5,0x25,0x29, 0x3,0x27,0x4e, 0x5,0x25,0x2a, 0x4,0x25,0x37, + 0x4,0x25,0x35, 0x6,0x29,0x4a, 0x6,0x29,0x44, 0x6,0x29,0x4c, + 0x6,0x29,0x47, 0x6,0x29,0x4e, 0x5,0x25,0x26, 0x6,0x29,0x42, + 0xf,0x25,0x45, 0xf,0x25,0x46, 0xf,0x25,0x48, 0xf,0x25,0x49, + 0xf,0x25,0x4b, 0xf,0x25,0x4c, 0xf,0x25,0x4d, 0xf,0x25,0x4e, + 0xf,0x25,0x4f, 0xf,0x25,0x50, 0xf,0x25,0x51, 0x6,0x29,0x4d, + 0x6,0x29,0x48, 0x6,0x29,0x49, 0x6,0x29,0x4b, 0x5,0x25,0x24, + 0x5,0x25,0x27, 0x5,0x27,0x7c, 0x6,0x2e,0x64, 0x6,0x2e,0x59, + 0x5,0x2b,0x72, 0x4,0x28,0x36, 0x6,0x2e,0x63, 0x6,0x2e,0x57, + 0x6,0x2e,0x56, 0x5,0x28,0x23, 0x4,0x28,0x3b, 0x6,0x2e,0x5d, + 0x5,0x27,0x7e, 0x5,0x27,0x7d, 0x5,0x28,0x22, 0x6,0x2e,0x62, + 0x6,0x2e,0x55, 0x6,0x2e,0x54, 0x6,0x2e,0x65, 0x6,0x2e,0x5c, + 0xf,0x29,0x29, 0xf,0x29,0x2a, 0xf,0x29,0x2b, 0xf,0x29,0x2c, + 0xf,0x29,0x2e, 0xf,0x29,0x2f, 0xf,0x29,0x31, 0xf,0x29,0x32, + 0xf,0x29,0x33, 0xf,0x29,0x34, 0xf,0x29,0x35, 0xf,0x29,0x36, + 0xf,0x29,0x37, 0xf,0x29,0x38, 0x6,0x2e,0x53, 0x6,0x2e,0x58, + 0x6,0x2e,0x5b, 0x6,0x2e,0x5e, 0x6,0x2e,0x60, 0xf,0x25,0x47, + 0x6,0x2e,0x5f, 0x5,0x28,0x24, 0x4,0x2b,0x63, 0x5,0x2b,0x70, + 0x4,0x2b,0x67, 0x6,0x35,0x36, 0x5,0x2b,0x6b, 0x6,0x35,0x35, + 0x5,0x2b,0x74, 0x4,0x2b,0x66, 0x4,0x2b,0x68, 0x5,0x2b,0x6f, + 0x6,0x35,0x32, 0x5,0x2b,0x69, 0xf,0x2d,0x64, 0xf,0x2d,0x6e, + 0x6,0x35,0x37, 0x5,0x2b,0x6e, 0xf,0x2d,0x66, 0xf,0x2d,0x67, + 0xf,0x2d,0x6a, 0xf,0x2d,0x6b, 0xf,0x2d,0x6c, 0xf,0x2d,0x6d, + 0xf,0x2d,0x6f, 0xf,0x2d,0x71, 0xf,0x2d,0x72, 0xf,0x2d,0x73, + 0xf,0x2d,0x74, 0xf,0x2d,0x75, 0xf,0x2d,0x76, 0xf,0x2d,0x78, + 0xf,0x2d,0x79, 0xf,0x2d,0x7a, 0xf,0x2d,0x7b, 0xf,0x2d,0x7c, + 0x6,0x35,0x21, 0x6,0x35,0x3a, 0x6,0x35,0x3b, 0x6,0x35,0x33, + 0x6,0x35,0x34, 0x5,0x2b,0x68, 0x6,0x35,0x39, 0xf,0x2d,0x77, + 0xf,0x2d,0x70, 0x5,0x2b,0x6a, 0x5,0x2b,0x6d, 0x5,0x2b,0x75, + 0x5,0x2b,0x71, 0x5,0x2b,0x73, 0x4,0x2b,0x60, 0x6,0x3d,0x2b, + 0x6,0x3d,0x2d, 0x6,0x3d,0x2c, 0x4,0x30,0x49, 0x4,0x30,0x48, + 0x6,0x3d,0x30, 0x6,0x3d,0x28, 0x5,0x31,0x21, 0x6,0x3d,0x33, + 0x5,0x30,0x77, 0x6,0x3d,0x2e, 0x6,0x3d,0x27, 0x5,0x31,0x22, + 0x5,0x30,0x76, 0x4,0x30,0x46, 0x6,0x3d,0x2a, 0x6,0x3d,0x31, + 0x6,0x3d,0x37, 0x6,0x3d,0x32, 0x6,0x3d,0x29, 0x4,0x30,0x4b, + 0x6,0x3d,0x34, 0xf,0x2d,0x69, 0xf,0x32,0x77, 0xf,0x32,0x78, + 0xf,0x32,0x79, 0xf,0x32,0x7a, 0xf,0x32,0x7b, 0xf,0x32,0x7c, + 0xf,0x32,0x7e, 0xf,0x33,0x21, 0xf,0x33,0x23, 0xf,0x33,0x24, + 0xf,0x33,0x25, 0xf,0x33,0x26, 0xf,0x33,0x27, 0x6,0x46,0x37, + 0x6,0x3d,0x38, 0x6,0x3e,0x65, 0x6,0x3d,0x39, 0x6,0x3d,0x2f, + 0x5,0x30,0x7a, 0x6,0x43,0x63, 0x5,0x30,0x7d, 0x5,0x31,0x23, + 0x6,0x3d,0x24, 0x6,0x3d,0x26, 0xf,0x32,0x7d, 0x5,0x30,0x79, + 0x5,0x30,0x7e, 0x5,0x30,0x78, 0x6,0x3d,0x25, 0x6,0x3d,0x36, + 0x5,0x30,0x7c, 0x6,0x46,0x49, 0x6,0x46,0x4f, 0x5,0x36,0x56, + 0x5,0x36,0x51, 0x6,0x46,0x4c, 0x5,0x36,0x4e, 0x5,0x36,0x52, + 0x5,0x36,0x63, 0x5,0x36,0x53, 0x6,0x46,0x48, 0x5,0x36,0x55, + 0x5,0x36,0x50, 0x6,0x46,0x56, 0x4,0x36,0x35, 0x5,0x36,0x54, + 0x6,0x46,0x52, 0x6,0x46,0x50, 0x6,0x46,0x4b, 0x6,0x46,0x4e, + 0x6,0x46,0x53, 0xf,0x32,0x76, 0x6,0x46,0x58, 0x5,0x36,0x4f, + 0x5,0x36,0x57, 0x6,0x46,0x47, 0xf,0x39,0x38, 0xf,0x39,0x39, + 0xf,0x39,0x3a, 0xf,0x39,0x3b, 0xf,0x39,0x3c, 0xf,0x39,0x3d, + 0xf,0x39,0x3e, 0xf,0x39,0x3f, 0x6,0x46,0x4d, 0x4,0x36,0x3b, + 0x6,0x46,0x51, 0x6,0x46,0x54, 0x5,0x36,0x4d, 0x6,0x46,0x4a, + 0x5,0x34,0x21, 0x6,0x50,0x5a, 0x4,0x42,0x38, 0x5,0x3d,0x5a, + 0x5,0x3d,0x58, 0x6,0x50,0x53, 0x5,0x30,0x7b, 0x5,0x3d,0x5e, + 0x5,0x3d,0x5c, 0x6,0x50,0x58, 0x5,0x3d,0x5b, 0x6,0x50,0x5f, + 0x6,0x50,0x5d, 0x4,0x3c,0x2e, 0x6,0x50,0x5c, 0x6,0x50,0x62, + 0x6,0x50,0x55, 0x4,0x3c,0x2f, 0x5,0x3d,0x60, 0x6,0x50,0x54, + 0x5,0x3d,0x57, 0x6,0x50,0x57, 0x6,0x50,0x5e, 0xf,0x40,0x39, + 0xf,0x40,0x3a, 0xf,0x40,0x3b, 0xf,0x40,0x3c, 0xf,0x40,0x3d, + 0xf,0x40,0x3e, 0xf,0x40,0x3f, 0xf,0x40,0x40, 0xf,0x40,0x41, + 0xf,0x40,0x42, 0xf,0x40,0x43, 0xf,0x40,0x44, 0xf,0x40,0x45, + 0xf,0x40,0x46, 0x6,0x50,0x61, 0x6,0x56,0x4e, 0x6,0x50,0x59, + 0x6,0x50,0x56, 0x6,0x46,0x57, 0x5,0x3d,0x59, 0x5,0x3d,0x5d, + 0x5,0x3d,0x5f, 0x4,0x3c,0x2b, 0x6,0x50,0x60, 0x6,0x5a,0x71, + 0x5,0x3d,0x61, 0x7,0x21,0x2e, 0x4,0x42,0x34, 0x5,0x44,0x56, + 0x6,0x5a,0x64, 0x6,0x5a,0x69, 0x5,0x3d,0x62, 0x6,0x5a,0x6b, + 0x4,0x42,0x39, 0x6,0x5a,0x74, 0x4,0x42,0x31, 0x6,0x5a,0x75, + 0x6,0x5a,0x68, 0x6,0x5a,0x67, 0x6,0x5a,0x76, 0xf,0x46,0x43, + 0xf,0x46,0x44, 0xf,0x46,0x45, 0xf,0x46,0x46, 0xf,0x46,0x47, + 0xf,0x46,0x49, 0xf,0x46,0x4a, 0xf,0x46,0x4b, 0xf,0x46,0x4c, + 0xf,0x46,0x4d, 0xf,0x46,0x4e, 0xf,0x46,0x4f, 0xf,0x46,0x51, + 0xf,0x46,0x52, 0xf,0x46,0x53, 0xf,0x46,0x54, 0xf,0x46,0x56, + 0xf,0x46,0x57, 0xf,0x46,0x58, 0xf,0x53,0x45, 0x7,0x26,0x2d, + 0x5,0x44,0x58, 0x6,0x5a,0x77, 0x6,0x5e,0x57, 0x6,0x5a,0x6d, + 0x6,0x5a,0x6f, 0x6,0x5a,0x65, 0xf,0x46,0x50, 0xf,0x46,0x48, + 0xf,0x46,0x55, 0x4,0x42,0x30, 0x6,0x5a,0x66, 0x6,0x5a,0x6a, + 0x6,0x5a,0x6e, 0x6,0x5a,0x70, 0x4,0x42,0x36, 0x5,0x3f,0x46, + 0x4,0x48,0x7e, 0x4,0x48,0x7a, 0x6,0x5a,0x6c, 0x7,0x21,0x2f, + 0x7,0x21,0x31, 0x7,0x21,0x29, 0x7,0x21,0x26, 0x7,0x21,0x25, + 0x5,0x4b,0x77, 0x4,0x48,0x7c, 0x7,0x21,0x2b, 0x7,0x21,0x2c, + 0x5,0x4b,0x73, 0x7,0x21,0x2a, 0x5,0x4b,0x79, 0x5,0x4b,0x78, + 0x7,0x21,0x27, 0xf,0x4d,0x5a, 0xf,0x4d,0x5b, 0xf,0x4d,0x5c, + 0xf,0x4d,0x5d, 0xf,0x4d,0x5e, 0xf,0x4d,0x60, 0xf,0x4d,0x61, + 0x7,0x21,0x28, 0x5,0x4b,0x72, 0x7,0x21,0x2d, 0xf,0x4d,0x62, + 0x4,0x49,0x21, 0x5,0x4b,0x75, 0x7,0x21,0x30, 0x5,0x4b,0x74, + 0x5,0x4c,0x45, 0x5,0x53,0x54, 0x5,0x53,0x5a, 0x7,0x2c,0x40, + 0x4,0x4f,0x58, 0x4,0x4f,0x5f, 0x5,0x53,0x58, 0x4,0x4f,0x5c, + 0x4,0x4f,0x5e, 0x5,0x53,0x55, 0x5,0x53,0x56, 0xf,0x53,0x46, + 0xf,0x53,0x47, 0xf,0x53,0x48, 0xf,0x53,0x49, 0xf,0x53,0x4a, + 0x5,0x53,0x5b, 0x5,0x53,0x57, 0x7,0x36,0x78, 0x5,0x4b,0x76, + 0x5,0x5a,0x6f, 0x5,0x5a,0x70, 0x4,0x55,0x67, 0x4,0x55,0x66, + 0x7,0x36,0x76, 0xf,0x59,0x48, 0xf,0x59,0x4a, 0xf,0x59,0x4b, + 0xf,0x59,0x4c, 0xf,0x59,0x4e, 0x7,0x36,0x75, 0x7,0x36,0x77, + 0xf,0x59,0x49, 0x4,0x55,0x68, 0x7,0x36,0x74, 0x7,0x3e,0x76, + 0x4,0x5a,0x6b, 0x4,0x5a,0x69, 0x4,0x5a,0x6a, 0x7,0x3e,0x78, + 0x7,0x3e,0x77, 0xf,0x5e,0x30, 0xf,0x5e,0x31, 0xf,0x5e,0x2c, + 0xf,0x5e,0x2e, 0xf,0x5e,0x2f, 0x7,0x3e,0x75, 0x5,0x61,0x31, + 0x4,0x5a,0x6c, 0x5,0x61,0x2f, 0x5,0x61,0x30, 0x5,0x61,0x32, + 0x5,0x67,0x4a, 0x5,0x67,0x4e, 0x4,0x63,0x2e, 0x5,0x67,0x4d, + 0x5,0x67,0x4f, 0xf,0x61,0x7e, 0xf,0x62,0x21, 0x7,0x47,0x6f, + 0x5,0x67,0x4c, 0x5,0x67,0x4b, 0x5,0x69,0x7c, 0x7,0x52,0x75, + 0x7,0x4d,0x3c, 0xf,0x64,0x7a, 0x5,0x6b,0x6b, 0x7,0x4d,0x3b, + 0x7,0x4d,0x68, 0x4,0x66,0x2f, 0x4,0x66,0x2e, 0x5,0x6f,0x68, + 0x7,0x57,0x4e, 0x5,0x6b,0x6c, 0xf,0x67,0x3f, 0xf,0x67,0x7e, + 0x4,0x66,0x2d, 0x7,0x57,0x4d, 0xf,0x69,0x38, 0xf,0x69,0x3a, + 0xf,0x69,0x39, 0x5,0x73,0x31, 0x4,0x6a,0x40, 0x7,0x5b,0x45, + 0xf,0x6a,0x4b, 0xf,0x6b,0x41, 0x5,0x75,0x62, 0x4,0x6d,0x52, + 0xf,0x6c,0x49, 0x6,0x21,0x4d, 0x4,0x21,0x5c, 0x4,0x22,0x32, + 0x6,0x23,0x53, 0x6,0x23,0x54, 0x6,0x25,0x75, 0x6,0x25,0x77, + 0x6,0x25,0x78, 0x5,0x23,0x35, 0x6,0x25,0x76, 0x6,0x29,0x51, + 0x6,0x29,0x50, 0x6,0x29,0x4f, 0x6,0x29,0x53, 0xf,0x25,0x53, + 0x6,0x29,0x52, 0xf,0x25,0x52, 0x6,0x2e,0x67, 0x6,0x2e,0x68, + 0x5,0x2b,0x76, 0xf,0x2d,0x7d, 0xf,0x2d,0x7e, 0xf,0x2e,0x21, + 0x6,0x35,0x3c, 0xf,0x33,0x28, 0x5,0x31,0x24, 0x5,0x31,0x25, + 0xf,0x33,0x29, 0xf,0x33,0x2a, 0x6,0x46,0x59, 0xf,0x39,0x40, + 0xf,0x39,0x41, 0xf,0x39,0x42, 0x5,0x36,0x58, 0xf,0x39,0x43, + 0xf,0x40,0x47, 0x6,0x50,0x63, 0xf,0x40,0x48, 0xf,0x46,0x59, + 0xf,0x46,0x5a, 0x5,0x44,0x59, 0x7,0x21,0x34, 0x7,0x21,0x32, + 0x5,0x4b,0x7b, 0xf,0x4d,0x63, 0xf,0x4d,0x64, 0x5,0x4b,0x7a, + 0x7,0x21,0x33, 0x5,0x53,0x5c, 0x7,0x2c,0x41, 0xf,0x53,0x4b, + 0xf,0x53,0x4c, 0xf,0x53,0x4d, 0xf,0x53,0x4e, 0x5,0x5a,0x71, + 0xf,0x59,0x4f, 0xf,0x59,0x50, 0xf,0x59,0x51, 0x7,0x3e,0x79, + 0x5,0x61,0x33, 0xf,0x5e,0x32, 0x7,0x46,0x29, 0x5,0x67,0x50, + 0xf,0x64,0x7b, 0x5,0x67,0x51, 0x5,0x6b,0x6d, 0xf,0x67,0x41, + 0xf,0x69,0x3b, 0xf,0x6a,0x4c, 0x5,0x77,0x53, 0xf,0x6b,0x42, + 0x6,0x21,0x36, 0x5,0x21,0x36, 0x5,0x21,0x35, 0x6,0x22,0x37, + 0x6,0x23,0x56, 0x6,0x23,0x55, 0x5,0x23,0x36, 0x6,0x25,0x79, + 0x5,0x23,0x38, 0x5,0x28,0x25, 0x5,0x28,0x26, 0x4,0x2b,0x6a, + 0x6,0x35,0x3d, 0xf,0x2e,0x22, 0xf,0x2e,0x23, 0x6,0x3d,0x3a, + 0x6,0x46,0x5a, 0x6,0x50,0x64, 0x5,0x3d,0x63, 0x4,0x3c,0x31, + 0x6,0x5a,0x78, 0x5,0x5a,0x72, 0x6,0x21,0x37, 0x6,0x21,0x4e, + 0x5,0x21,0x37, 0x6,0x21,0x41, 0x6,0x21,0x59, 0x5,0x21,0x50, + 0x6,0x23,0x3b, 0x4,0x22,0x35, 0x6,0x23,0x57, 0x6,0x25,0x7c, + 0x6,0x25,0x7e, 0x5,0x23,0x39, 0xf,0x23,0x2d, 0x6,0x25,0x7a, + 0x6,0x29,0x54, 0x6,0x2e,0x6b, 0x6,0x2e,0x69, 0x5,0x28,0x27, + 0x6,0x2e,0x6a, 0x6,0x2e,0x4f, 0x6,0x30,0x7b, 0x6,0x35,0x40, + 0x6,0x35,0x3f, 0x6,0x35,0x41, 0x6,0x35,0x3e, 0x6,0x3d,0x3b, + 0x6,0x46,0x5d, 0x5,0x3d,0x64, 0xf,0x39,0x44, 0xf,0x39,0x45, + 0x6,0x46,0x5b, 0x6,0x46,0x5c, 0x5,0x3d,0x65, 0x6,0x50,0x65, + 0xf,0x40,0x49, 0xf,0x40,0x4a, 0x4,0x42,0x3a, 0x6,0x5a,0x79, + 0xf,0x54,0x46, 0xf,0x53,0x4f, 0xf,0x53,0x50, 0x5,0x61,0x34, + 0xf,0x5e,0x33, 0x7,0x46,0x2a, 0x7,0x46,0x2b, 0x4,0x21,0x2d, + 0x6,0x21,0x4f, 0x6,0x21,0x51, 0x6,0x22,0x39, 0x4,0x21,0x5d, + 0x6,0x22,0x38, 0x5,0x21,0x52, 0xf,0x21,0x46, 0x6,0x22,0x3a, + 0x5,0x21,0x51, 0x6,0x23,0x5a, 0x6,0x23,0x58, 0x6,0x25,0x47, + 0x6,0x26,0x23, 0x6,0x26,0x21, 0x6,0x26,0x22, 0x5,0x23,0x3a, + 0x6,0x28,0x7a, 0x5,0x25,0x2c, 0x6,0x29,0x55, 0x6,0x29,0x56, + 0x6,0x2e,0x6c, 0x6,0x35,0x42, 0x6,0x35,0x43, 0x5,0x2b,0x77, + 0x5,0x2b,0x78, 0x6,0x3d,0x3d, 0x6,0x46,0x5f, 0x3,0x39,0x77, + 0x6,0x46,0x5e, 0x4,0x3c,0x33, 0x5,0x3d,0x66, 0x6,0x5a,0x7b, + 0x6,0x5a,0x7a, 0x7,0x21,0x35, 0x5,0x53,0x5d, 0x7,0x2c,0x42, + 0xf,0x55,0x76, 0x4,0x5a,0x6d, 0xf,0x67,0x42, 0x7,0x57,0x4f, + 0x5,0x21,0x38, 0x6,0x22,0x3b, 0xf,0x21,0x48, 0xf,0x21,0x49, + 0x6,0x23,0x5b, 0x4,0x22,0x37, 0x5,0x22,0x29, 0xf,0x21,0x7b, + 0xf,0x23,0x2e, 0xf,0x23,0x2f, 0x5,0x25,0x2d, 0xf,0x25,0x55, + 0x6,0x2e,0x6d, 0x6,0x3d,0x3e, 0xf,0x2e,0x25, 0xf,0x2e,0x26, + 0xf,0x2e,0x27, 0xf,0x2e,0x28, 0xf,0x2e,0x29, 0x5,0x31,0x27, + 0x6,0x46,0x60, 0xf,0x39,0x47, 0xf,0x39,0x48, 0x6,0x46,0x61, + 0xf,0x3a,0x5d, 0x6,0x50,0x66, 0x6,0x5a,0x7c, 0xf,0x46,0x5b, + 0x5,0x4e,0x77, 0x7,0x2c,0x43, 0xf,0x59,0x52, 0xf,0x53,0x51, + 0x7,0x3e,0x7a, 0x7,0x46,0x2c, 0x7,0x4d,0x3f, 0x5,0x6f,0x69, + 0x5,0x75,0x63, 0xf,0x21,0x4a, 0x6,0x23,0x5c, 0xf,0x21,0x7d, + 0xf,0x21,0x7e, 0x4,0x22,0x38, 0x5,0x23,0x3b, 0x6,0x26,0x24, + 0x4,0x23,0x3c, 0xf,0x23,0x30, 0xf,0x23,0x31, 0xf,0x23,0x32, + 0xf,0x23,0x33, 0xf,0x23,0x24, 0xf,0x22,0x7e, 0x4,0x25,0x41, + 0x4,0x25,0x42, 0x6,0x29,0x58, 0x6,0x29,0x59, 0x5,0x25,0x2f, + 0xf,0x25,0x57, 0x5,0x28,0x29, 0x4,0x28,0x41, 0x4,0x28,0x42, + 0x5,0x28,0x2c, 0x5,0x28,0x28, 0x5,0x28,0x2a, 0x6,0x2e,0x6f, + 0xf,0x29,0x3a, 0xf,0x29,0x3c, 0xf,0x29,0x3d, 0xf,0x29,0x3e, + 0xf,0x29,0x3f, 0x6,0x2e,0x6e, 0x5,0x2b,0x7a, 0x4,0x2b,0x6b, + 0x5,0x2b,0x79, 0x5,0x28,0x2b, 0x6,0x35,0x45, 0x5,0x2b,0x7b, + 0xf,0x2e,0x2a, 0xf,0x2e,0x2b, 0x6,0x35,0x46, 0x5,0x31,0x28, + 0x6,0x3d,0x3f, 0x6,0x3d,0x40, 0x4,0x30,0x4e, 0xf,0x33,0x2b, + 0xf,0x33,0x2c, 0xf,0x33,0x2d, 0xf,0x33,0x2f, 0xf,0x33,0x30, + 0x6,0x46,0x62, 0x5,0x36,0x5c, 0x5,0x36,0x5a, 0x5,0x36,0x5b, + 0x5,0x36,0x59, 0x4,0x36,0x3e, 0xf,0x33,0x2e, 0x5,0x3d,0x6c, + 0x5,0x3d,0x67, 0x5,0x3d,0x69, 0x5,0x3d,0x6a, 0x5,0x3d,0x68, + 0x5,0x3d,0x6b, 0x6,0x50,0x67, 0x6,0x5a,0x7d, 0x5,0x4c,0x21, + 0x5,0x44,0x5a, 0x7,0x21,0x37, 0xf,0x46,0x5d, 0xf,0x46,0x5e, + 0x5,0x4b,0x7e, 0x5,0x4b,0x7d, 0x5,0x4b,0x7c, 0x7,0x21,0x36, + 0xf,0x4d,0x67, 0xf,0x53,0x53, 0x7,0x2c,0x45, 0xf,0x4d,0x66, + 0xf,0x53,0x52, 0x4,0x55,0x6a, 0x7,0x2c,0x46, 0x5,0x5a,0x73, + 0xf,0x59,0x53, 0xf,0x59,0x54, 0x5,0x61,0x36, 0x5,0x61,0x35, + 0x5,0x61,0x37, 0xf,0x5e,0x34, 0x7,0x3e,0x7b, 0x5,0x67,0x52, + 0x5,0x67,0x53, 0x7,0x52,0x76, 0x5,0x73,0x32, 0x4,0x21,0x29, + 0x6,0x21,0x52, 0xf,0x21,0x2a, 0xf,0x21,0x2b, 0xf,0x21,0x2c, + 0xf,0x21,0x2e, 0x6,0x21,0x5c, 0xf,0x21,0x2d, 0x5,0x21,0x53, + 0x6,0x22,0x3d, 0x4,0x21,0x5f, 0x6,0x23,0x5e, 0x6,0x23,0x5d, + 0x6,0x23,0x5f, 0x6,0x23,0x60, 0xf,0x21,0x4b, 0x6,0x26,0x27, + 0x6,0x26,0x25, 0x6,0x26,0x26, 0xf,0x23,0x34, 0xf,0x23,0x35, + 0x4,0x25,0x46, 0x6,0x29,0x5a, 0x4,0x25,0x44, 0x6,0x29,0x5b, + 0x6,0x29,0x5c, 0x6,0x29,0x5d, 0xf,0x25,0x58, 0xf,0x25,0x59, + 0x6,0x2e,0x72, 0x6,0x2e,0x70, 0x6,0x2e,0x71, 0x6,0x35,0x47, + 0xf,0x2e,0x2c, 0x6,0x37,0x27, 0x6,0x3d,0x42, 0x6,0x3d,0x43, + 0x6,0x3d,0x41, 0xf,0x33,0x31, 0xf,0x33,0x32, 0xf,0x33,0x33, + 0x6,0x46,0x63, 0x6,0x46,0x66, 0xf,0x39,0x49, 0x6,0x46,0x64, + 0xf,0x39,0x4a, 0xf,0x46,0x5f, 0xf,0x46,0x60, 0xf,0x46,0x61, + 0xf,0x4d,0x68, 0x7,0x2c,0x47, 0xf,0x53,0x54, 0xf,0x53,0x55, + 0xf,0x53,0x43, 0xf,0x59,0x55, 0xf,0x5e,0x35, 0xf,0x67,0x43, + 0x4,0x21,0x2e, 0x5,0x21,0x39, 0x6,0x21,0x53, 0x6,0x21,0x54, + 0x6,0x22,0x3f, 0x5,0x21,0x54, 0x6,0x22,0x3e, 0xf,0x21,0x4c, + 0x6,0x23,0x65, 0x6,0x23,0x61, 0x6,0x23,0x62, 0x6,0x23,0x63, + 0xf,0x22,0x21, 0x5,0x22,0x2a, 0x6,0x26,0x28, 0xf,0x23,0x36, + 0x6,0x29,0x60, 0x6,0x29,0x5f, 0x6,0x2e,0x73, 0x6,0x2e,0x74, + 0x6,0x34,0x7a, 0x6,0x35,0x48, 0x6,0x3d,0x44, 0x6,0x3d,0x45, + 0x5,0x36,0x5d, 0x6,0x5a,0x7e, 0xf,0x46,0x62, 0x7,0x21,0x70, + 0x7,0x36,0x7b, 0x5,0x5a,0x76, 0x5,0x67,0x54, 0x7,0x4e,0x3e, + 0x6,0x21,0x39, 0x4,0x21,0x40, 0x6,0x21,0x55, 0x5,0x21,0x3a, + 0x5,0x21,0x3b, 0x6,0x21,0x56, 0x4,0x21,0x41, 0xf,0x21,0x2f, + 0x6,0x21,0x57, 0x5,0x21,0x55, 0x5,0x21,0x56, 0x4,0x21,0x62, + 0x6,0x22,0x44, 0x5,0x21,0x57, 0x6,0x22,0x43, 0x6,0x22,0x40, + 0x6,0x22,0x45, 0x4,0x22,0x3a, 0x6,0x23,0x6a, 0x5,0x22,0x2e, + 0x5,0x22,0x2c, 0x5,0x22,0x2b, 0x4,0x22,0x3b, 0x4,0x22,0x39, + 0x6,0x23,0x68, 0x6,0x23,0x67, 0x5,0x22,0x2f, 0x6,0x23,0x6b, + 0x6,0x23,0x69, 0x5,0x22,0x2d, 0x4,0x22,0x3d, 0xf,0x22,0x22, + 0xf,0x22,0x23, 0x4,0x22,0x3e, 0x6,0x23,0x66, 0x4,0x23,0x41, + 0x6,0x26,0x2b, 0x4,0x23,0x43, 0x5,0x23,0x3d, 0x4,0x23,0x42, + 0x5,0x23,0x46, 0x5,0x23,0x45, 0x5,0x23,0x43, 0x5,0x23,0x40, + 0x6,0x26,0x29, 0x5,0x23,0x3f, 0x5,0x23,0x42, 0x5,0x23,0x41, + 0x6,0x26,0x2a, 0x6,0x26,0x2c, 0x5,0x23,0x3e, 0x5,0x23,0x44, + 0x6,0x29,0x69, 0x5,0x25,0x33, 0x5,0x25,0x35, 0x4,0x25,0x49, + 0x4,0x25,0x4b, 0x3,0x27,0x5c, 0x6,0x29,0x66, 0x4,0x25,0x4d, + 0x6,0x29,0x64, 0x6,0x29,0x65, 0x6,0x29,0x6c, 0x6,0x2e,0x75, + 0x6,0x29,0x6a, 0x5,0x25,0x30, 0x5,0x25,0x36, 0x6,0x29,0x6b, + 0x5,0x25,0x32, 0x6,0x29,0x67, 0x5,0x25,0x34, 0xf,0x25,0x5a, + 0xf,0x25,0x5b, 0xf,0x25,0x5c, 0xf,0x25,0x5d, 0x6,0x29,0x68, + 0x6,0x29,0x62, 0x6,0x29,0x61, 0x5,0x25,0x31, 0x6,0x29,0x57, + 0x4,0x28,0x47, 0x5,0x28,0x2d, 0x4,0x28,0x45, 0x6,0x2f,0x24, + 0x6,0x2e,0x7b, 0x6,0x2f,0x22, 0x4,0x28,0x48, 0x6,0x2f,0x21, + 0x4,0x28,0x44, 0x4,0x28,0x46, 0x6,0x2e,0x78, 0x6,0x2e,0x7e, + 0x6,0x2f,0x23, 0x6,0x2e,0x7a, 0x6,0x2e,0x7d, 0x6,0x2e,0x7c, + 0xf,0x29,0x40, 0xf,0x29,0x41, 0xf,0x29,0x42, 0x6,0x2e,0x79, + 0x5,0x28,0x2e, 0x6,0x2e,0x77, 0x6,0x35,0x49, 0x4,0x2b,0x70, + 0x4,0x2b,0x6d, 0x5,0x2c,0x25, 0x5,0x2c,0x23, 0x4,0x2b,0x6f, + 0x4,0x2b,0x73, 0x6,0x35,0x4e, 0x6,0x35,0x52, 0x5,0x2c,0x22, + 0x6,0x35,0x53, 0x4,0x2b,0x6c, 0x5,0x2c,0x26, 0x6,0x35,0x51, + 0x4,0x2b,0x71, 0x6,0x35,0x50, 0x6,0x35,0x4f, 0x6,0x35,0x4c, + 0x6,0x35,0x4b, 0x4,0x2b,0x72, 0x5,0x2c,0x24, 0x6,0x35,0x4d, + 0xf,0x2e,0x33, 0x6,0x35,0x54, 0xf,0x2e,0x2e, 0xf,0x2e,0x2f, + 0xf,0x2e,0x30, 0xf,0x2e,0x32, 0xf,0x2e,0x31, 0x6,0x35,0x4a, + 0x5,0x2c,0x27, 0x5,0x2b,0x7d, 0x5,0x2c,0x21, 0x5,0x2b,0x7e, + 0x4,0x30,0x50, 0x5,0x31,0x2b, 0x4,0x30,0x51, 0x5,0x31,0x2a, + 0x6,0x3d,0x46, 0x4,0x30,0x56, 0x4,0x36,0x49, 0x4,0x30,0x55, + 0x6,0x3d,0x49, 0x6,0x3d,0x47, 0x5,0x36,0x5e, 0x4,0x30,0x4f, + 0x5,0x2c,0x28, 0xf,0x33,0x34, 0xf,0x33,0x35, 0xf,0x33,0x37, + 0x6,0x3d,0x48, 0x6,0x3d,0x4a, 0x6,0x3d,0x4b, 0x4,0x36,0x43, + 0x5,0x36,0x5f, 0x6,0x46,0x6d, 0x6,0x46,0x69, 0x4,0x36,0x46, + 0x4,0x36,0x47, 0x5,0x36,0x60, 0x5,0x36,0x64, 0x4,0x36,0x4a, + 0x4,0x36,0x44, 0x4,0x36,0x41, 0x4,0x36,0x40, 0x6,0x46,0x6b, + 0x6,0x46,0x68, 0x6,0x46,0x6c, 0x5,0x36,0x61, 0x5,0x36,0x62, + 0x6,0x46,0x6a, 0xf,0x39,0x4b, 0xf,0x39,0x4c, 0xf,0x39,0x4d, + 0xf,0x39,0x4e, 0x4,0x36,0x48, 0x6,0x4c,0x46, 0x6,0x46,0x6e, + 0x5,0x36,0x65, 0x4,0x3c,0x39, 0x6,0x50,0x6f, 0x5,0x3d,0x73, + 0x6,0x50,0x6d, 0x4,0x3c,0x35, 0x5,0x3d,0x74, 0x6,0x50,0x6e, + 0x5,0x3d,0x6d, 0x4,0x3c,0x37, 0x4,0x3c,0x36, 0x5,0x3d,0x6e, + 0x4,0x3c,0x3a, 0x5,0x3d,0x6f, 0x6,0x50,0x6b, 0xf,0x40,0x4b, + 0x6,0x50,0x6a, 0x6,0x50,0x68, 0x6,0x50,0x70, 0x6,0x50,0x69, + 0x5,0x3d,0x72, 0x5,0x3d,0x71, 0xf,0x40,0x4c, 0x5,0x44,0x5b, + 0x4,0x42,0x3b, 0x6,0x5b,0x24, 0x5,0x44,0x61, 0x6,0x5b,0x22, + 0x6,0x5b,0x21, 0x4,0x3c,0x38, 0x4,0x42,0x40, 0x5,0x44,0x62, + 0x5,0x44,0x5c, 0x5,0x44,0x5f, 0x4,0x42,0x3d, 0x4,0x42,0x44, + 0x6,0x5b,0x2b, 0x6,0x5b,0x29, 0x6,0x5b,0x28, 0x5,0x44,0x5e, + 0x5,0x4c,0x22, 0x6,0x5b,0x26, 0x5,0x44,0x5d, 0x6,0x5b,0x2a, + 0x5,0x44,0x60, 0x6,0x5b,0x25, 0xf,0x46,0x63, 0xf,0x46,0x64, + 0xf,0x46,0x65, 0x6,0x5b,0x23, 0x6,0x5b,0x27, 0x5,0x4c,0x23, + 0x5,0x4c,0x27, 0x4,0x49,0x24, 0x5,0x4c,0x24, 0x5,0x4c,0x26, + 0x7,0x21,0x3c, 0x7,0x21,0x3d, 0x7,0x21,0x3a, 0x7,0x21,0x3e, + 0x7,0x21,0x3b, 0x5,0x4c,0x25, 0x7,0x21,0x38, 0x7,0x22,0x5a, + 0x7,0x21,0x39, 0x4,0x4f,0x60, 0x7,0x2c,0x49, 0x5,0x5a,0x77, + 0x7,0x2c,0x4a, 0x7,0x2c,0x4e, 0x7,0x2c,0x4d, 0x7,0x2c,0x4c, + 0x5,0x53,0x5f, 0x5,0x53,0x61, 0x5,0x53,0x60, 0x5,0x53,0x5e, + 0x7,0x2c,0x48, 0x7,0x2c,0x4b, 0x7,0x21,0x3f, 0xf,0x53,0x56, + 0x5,0x58,0x51, 0x5,0x5a,0x7a, 0x4,0x55,0x6b, 0x5,0x5a,0x79, + 0x5,0x5a,0x78, 0x7,0x36,0x7c, 0xf,0x59,0x56, 0x4,0x55,0x6e, + 0x7,0x3e,0x7c, 0x5,0x61,0x38, 0x5,0x61,0x39, 0x7,0x36,0x7d, + 0xf,0x5e,0x36, 0x5,0x61,0x3a, 0x7,0x46,0x2f, 0x7,0x46,0x2e, + 0x7,0x46,0x2d, 0x7,0x4d,0x40, 0x7,0x4d,0x41, 0x5,0x6f,0x6a, + 0x7,0x52,0x77, 0xf,0x67,0x44, 0x5,0x75,0x64, 0x4,0x6b,0x65, + 0x7,0x62,0x2d, 0x7,0x62,0x2c, 0x6,0x21,0x3a, 0x5,0x21,0x3c, + 0x6,0x21,0x58, 0x4,0x21,0x63, 0x5,0x21,0x59, 0x5,0x21,0x58, + 0x5,0x22,0x31, 0x5,0x22,0x32, 0xf,0x22,0x25, 0xf,0x22,0x26, + 0xf,0x22,0x27, 0xf,0x22,0x28, 0x5,0x22,0x33, 0x6,0x26,0x2e, + 0x4,0x23,0x45, 0x5,0x23,0x47, 0xf,0x23,0x38, 0xf,0x23,0x3a, + 0xf,0x23,0x3b, 0x6,0x26,0x2d, 0x4,0x23,0x49, 0x5,0x25,0x3d, + 0x5,0x25,0x39, 0x6,0x29,0x6d, 0x5,0x25,0x3c, 0x6,0x29,0x6e, + 0xf,0x25,0x60, 0xf,0x25,0x61, 0xf,0x25,0x62, 0xf,0x25,0x63, + 0x5,0x28,0x30, 0x4,0x28,0x4a, 0x6,0x2f,0x26, 0x5,0x28,0x31, + 0x5,0x28,0x2f, 0x6,0x2f,0x28, 0xf,0x29,0x43, 0xf,0x29,0x44, + 0xf,0x29,0x45, 0x6,0x35,0x55, 0x6,0x35,0x59, 0x4,0x2b,0x74, + 0x5,0x2c,0x2d, 0x5,0x2c,0x29, 0x5,0x2c,0x2b, 0x5,0x2c,0x2c, + 0x5,0x2c,0x2a, 0xf,0x2e,0x34, 0xf,0x2e,0x35, 0x6,0x35,0x56, + 0x6,0x35,0x57, 0x5,0x31,0x2d, 0x6,0x3d,0x4e, 0x6,0x3d,0x4c, + 0x6,0x3d,0x4f, 0x6,0x3d,0x50, 0x6,0x3d,0x51, 0xf,0x33,0x38, + 0xf,0x33,0x39, 0x6,0x3d,0x4d, 0x5,0x36,0x69, 0x5,0x36,0x66, + 0x5,0x36,0x68, 0x5,0x36,0x6b, 0x5,0x36,0x67, 0xf,0x39,0x4f, + 0xf,0x39,0x50, 0x6,0x46,0x6f, 0x6,0x46,0x70, 0x6,0x46,0x71, + 0x5,0x3d,0x76, 0x5,0x3d,0x75, 0x4,0x3c,0x3b, 0x6,0x50,0x72, + 0x6,0x50,0x71, 0xf,0x40,0x4d, 0x5,0x3d,0x77, 0x4,0x42,0x46, + 0x5,0x44,0x66, 0x5,0x44,0x64, 0x5,0x44,0x65, 0x5,0x44,0x69, + 0x4,0x42,0x45, 0x5,0x44,0x68, 0x6,0x5b,0x2e, 0xf,0x46,0x66, + 0x6,0x5b,0x2c, 0x6,0x5b,0x2d, 0x5,0x4c,0x2b, 0x5,0x4c,0x28, + 0x4,0x49,0x26, 0x5,0x4c,0x29, 0x5,0x4c,0x2a, 0x7,0x2c,0x4f, + 0x5,0x5a,0x7c, 0xf,0x53,0x57, 0x5,0x5a,0x7b, 0x5,0x5a,0x7d, + 0x7,0x36,0x7e, 0x7,0x37,0x22, 0x7,0x37,0x21, 0x5,0x61,0x3c, + 0x7,0x3e,0x7e, 0x7,0x3f,0x21, 0x5,0x67,0x56, 0x5,0x67,0x55, + 0x7,0x4d,0x42, 0x5,0x6f,0x6b, 0x7,0x5b,0x46, 0x5,0x75,0x65, + 0x4,0x6c,0x6b, 0x7,0x66,0x3b, 0x5,0x21,0x3d, 0x6,0x22,0x47, + 0x6,0x22,0x48, 0x5,0x22,0x35, 0x5,0x22,0x34, 0x5,0x22,0x36, + 0xf,0x22,0x2a, 0x6,0x26,0x2f, 0x5,0x23,0x48, 0x5,0x23,0x49, + 0x4,0x25,0x52, 0x6,0x29,0x71, 0x6,0x29,0x70, 0xf,0x25,0x64, + 0xf,0x25,0x65, 0x6,0x2f,0x2a, 0x4,0x28,0x4c, 0x6,0x2f,0x2b, + 0x6,0x2f,0x2c, 0xf,0x29,0x46, 0x6,0x2f,0x29, 0x4,0x2b,0x76, + 0x6,0x35,0x5c, 0x6,0x35,0x5b, 0x6,0x35,0x5e, 0x6,0x35,0x5f, + 0x6,0x35,0x5a, 0x6,0x35,0x5d, 0x5,0x2c,0x2f, 0x4,0x30,0x5d, + 0x6,0x3d,0x52, 0x5,0x2c,0x2e, 0x5,0x31,0x2e, 0x5,0x31,0x2f, + 0x6,0x3d,0x53, 0x4,0x36,0x4e, 0xf,0x39,0x51, 0x6,0x50,0x73, + 0x4,0x30,0x5b, 0x5,0x3d,0x79, 0xf,0x40,0x4e, 0xf,0x40,0x4f, + 0x6,0x5b,0x2f, 0x4,0x42,0x47, 0x5,0x44,0x6a, 0x5,0x44,0x6b, + 0xf,0x46,0x67, 0xf,0x4d,0x69, 0x4,0x4f,0x65, 0x7,0x2c,0x50, + 0x7,0x2c,0x51, 0x7,0x37,0x23, 0x7,0x37,0x24, 0x5,0x5a,0x7e, + 0x7,0x4d,0x43, 0x6,0x21,0x2a, 0x4,0x21,0x42, 0x6,0x22,0x4a, + 0x6,0x26,0x30, 0x6,0x26,0x33, 0x5,0x23,0x4a, 0x6,0x26,0x31, + 0x6,0x26,0x32, 0x4,0x28,0x4d, 0x6,0x2f,0x2f, 0x6,0x2f,0x31, + 0x6,0x2f,0x2d, 0x6,0x2f,0x2e, 0x6,0x2f,0x30, 0x6,0x3d,0x54, + 0x6,0x35,0x60, 0xf,0x2e,0x36, 0xf,0x2e,0x37, 0x6,0x35,0x24, + 0x6,0x46,0x72, 0xf,0x39,0x52, 0x4,0x3c,0x3d, 0xf,0x46,0x68, + 0x7,0x3f,0x22, 0x5,0x6d,0x32, 0x6,0x21,0x2b, 0xf,0x21,0x31, + 0x5,0x22,0x37, 0x6,0x23,0x6e, 0x4,0x22,0x43, 0x6,0x23,0x6d, + 0x6,0x26,0x34, 0x4,0x23,0x4a, 0x6,0x26,0x35, 0xf,0x23,0x3c, + 0x6,0x29,0x73, 0x5,0x25,0x3e, 0x5,0x25,0x3f, 0x4,0x28,0x4f, + 0x6,0x2f,0x34, 0x5,0x28,0x33, 0x6,0x2f,0x33, 0x5,0x28,0x32, + 0x6,0x2f,0x32, 0x6,0x2f,0x37, 0x6,0x2f,0x35, 0xf,0x29,0x47, + 0x5,0x2c,0x30, 0x6,0x35,0x62, 0x6,0x35,0x61, 0x5,0x2c,0x31, + 0x6,0x3d,0x55, 0xf,0x33,0x3a, 0x4,0x36,0x4f, 0x6,0x50,0x75, + 0x6,0x46,0x73, 0x6,0x35,0x63, 0x5,0x3d,0x7a, 0x4,0x42,0x48, + 0x6,0x5b,0x31, 0x6,0x5b,0x30, 0x5,0x4c,0x2c, 0x5,0x4c,0x2d, + 0x5,0x4c,0x2e, 0xf,0x4d,0x6a, 0x5,0x53,0x64, 0x7,0x37,0x25, + 0xf,0x5e,0x37, 0x4,0x5f,0x4b, 0x7,0x3f,0x23, 0x7,0x4d,0x44, + 0x7,0x60,0x69, 0x7,0x64,0x43, 0xf,0x21,0x32, 0x5,0x22,0x38, + 0x6,0x23,0x6f, 0x5,0x23,0x4c, 0x6,0x26,0x37, 0xf,0x23,0x3d, + 0xf,0x25,0x66, 0x6,0x2f,0x36, 0x5,0x28,0x34, 0x6,0x35,0x64, + 0xf,0x46,0x69, 0x7,0x4d,0x45, 0x7,0x57,0x50, 0x6,0x21,0x5a, + 0x5,0x21,0x5a, 0x5,0x21,0x5b, 0x6,0x22,0x4b, 0x6,0x23,0x70, + 0x4,0x22,0x44, 0x4,0x22,0x45, 0x6,0x23,0x73, 0x6,0x23,0x72, + 0x5,0x22,0x3a, 0x5,0x22,0x39, 0x6,0x23,0x74, 0x6,0x26,0x39, + 0x5,0x23,0x4d, 0x6,0x26,0x3a, 0x6,0x23,0x75, 0x6,0x26,0x3b, + 0xf,0x23,0x3e, 0x5,0x25,0x40, 0x6,0x29,0x74, 0x6,0x29,0x77, + 0x6,0x29,0x78, 0x6,0x29,0x76, 0xf,0x25,0x67, 0xf,0x25,0x69, + 0xf,0x25,0x6a, 0xf,0x25,0x6b, 0xf,0x25,0x68, 0x6,0x29,0x75, + 0x6,0x35,0x65, 0x6,0x35,0x66, 0xf,0x2e,0x38, 0xf,0x2e,0x39, + 0x4,0x30,0x63, 0x4,0x30,0x61, 0x4,0x30,0x62, 0xf,0x33,0x3b, + 0xf,0x39,0x53, 0xf,0x39,0x54, 0x6,0x50,0x78, 0x6,0x50,0x77, + 0x6,0x50,0x79, 0x6,0x50,0x7b, 0xf,0x40,0x50, 0xf,0x46,0x6a, + 0xf,0x46,0x6b, 0x5,0x4c,0x2f, 0xf,0x4d,0x6b, 0xf,0x4d,0x6c, + 0x7,0x21,0x40, 0x7,0x37,0x26, 0xf,0x5e,0x38, 0x7,0x46,0x30, + 0x7,0x52,0x78, 0x7,0x60,0x6a, 0x7,0x62,0x2e, 0x6,0x22,0x4c, + 0x6,0x23,0x77, 0x6,0x23,0x76, 0x6,0x23,0x78, 0x4,0x23,0x4c, + 0x5,0x23,0x4f, 0x5,0x23,0x4e, 0x6,0x26,0x3c, 0x4,0x25,0x55, + 0x4,0x25,0x54, 0x6,0x29,0x7c, 0x6,0x29,0x7b, 0x6,0x29,0x7d, + 0x6,0x29,0x7a, 0x6,0x29,0x7e, 0x6,0x29,0x79, 0xf,0x25,0x6c, + 0x6,0x2a,0x22, 0x4,0x28,0x52, 0x4,0x28,0x51, 0x5,0x28,0x37, + 0xf,0x29,0x48, 0xf,0x29,0x49, 0xf,0x29,0x4a, 0xf,0x29,0x4b, + 0x6,0x2f,0x39, 0x6,0x35,0x68, 0x4,0x2b,0x79, 0x5,0x2c,0x32, + 0x6,0x35,0x67, 0x6,0x35,0x6a, 0x6,0x3c,0x7a, 0x6,0x35,0x69, + 0x6,0x3d,0x57, 0x6,0x3d,0x56, 0x6,0x35,0x6b, 0x6,0x3d,0x58, + 0x6,0x46,0x75, 0x6,0x46,0x76, 0x6,0x46,0x77, 0x5,0x37,0x3f, + 0x6,0x50,0x7c, 0x5,0x44,0x6d, 0x6,0x5b,0x32, 0x7,0x21,0x41, + 0xf,0x53,0x58, 0x7,0x63,0x4b, 0x5,0x21,0x3e, 0x4,0x21,0x43, + 0xf,0x21,0x34, 0x6,0x21,0x5b, 0x4,0x22,0x46, 0x6,0x2a,0x24, + 0x6,0x23,0x7a, 0x6,0x23,0x79, 0x4,0x23,0x4e, 0x6,0x2f,0x3b, + 0x5,0x28,0x38, 0x6,0x2f,0x3a, 0x4,0x28,0x53, 0x6,0x35,0x6c, + 0x6,0x2f,0x3c, 0x6,0x46,0x78, 0x5,0x2c,0x33, 0x5,0x3d,0x7b, + 0x6,0x50,0x7d, 0x5,0x44,0x6e, 0x7,0x3f,0x24, 0x5,0x21,0x3f, + 0x5,0x21,0x5c, 0x6,0x23,0x7b, 0x6,0x22,0x4f, 0x6,0x22,0x4d, + 0x6,0x22,0x50, 0x5,0x21,0x5d, 0x4,0x22,0x47, 0x5,0x22,0x3b, + 0x6,0x23,0x7c, 0x6,0x23,0x7d, 0x5,0x22,0x3f, 0x5,0x22,0x40, + 0x5,0x22,0x3d, 0x5,0x22,0x3e, 0xf,0x22,0x2d, 0x6,0x26,0x3e, + 0x5,0x23,0x50, 0x6,0x26,0x3d, 0x5,0x23,0x51, 0x6,0x25,0x5e, + 0xf,0x23,0x3f, 0x6,0x2a,0x27, 0x6,0x2a,0x26, 0x6,0x2a,0x29, + 0x6,0x2a,0x28, 0x5,0x25,0x41, 0x4,0x25,0x58, 0xf,0x25,0x6d, + 0xf,0x25,0x6e, 0x6,0x2a,0x25, 0x5,0x28,0x39, 0x4,0x28,0x54, + 0x6,0x2f,0x46, 0x6,0x2f,0x41, 0x6,0x2f,0x44, 0x6,0x2f,0x45, + 0x6,0x2f,0x40, 0x6,0x2f,0x3e, 0x6,0x2f,0x42, 0x6,0x2f,0x43, + 0xf,0x29,0x4d, 0xf,0x29,0x4e, 0x4,0x28,0x55, 0x6,0x2f,0x3f, + 0x6,0x35,0x73, 0x6,0x35,0x74, 0x4,0x2b,0x7b, 0x5,0x2c,0x34, + 0x4,0x2b,0x7c, 0x6,0x35,0x6f, 0x6,0x35,0x6d, 0x6,0x35,0x70, + 0x6,0x35,0x72, 0x6,0x35,0x71, 0x6,0x35,0x6e, 0x5,0x2c,0x35, + 0xf,0x2e,0x3a, 0xf,0x2e,0x3b, 0x6,0x3d,0x60, 0x6,0x3d,0x5b, + 0x4,0x30,0x67, 0x6,0x3d,0x5f, 0x6,0x3d,0x5c, 0x6,0x3d,0x5d, + 0xf,0x33,0x3d, 0x5,0x31,0x30, 0x6,0x3d,0x5e, 0x4,0x30,0x66, + 0x4,0x36,0x52, 0x6,0x46,0x7c, 0x6,0x46,0x7a, 0x4,0x36,0x53, + 0x6,0x46,0x7b, 0x6,0x46,0x79, 0x6,0x46,0x7d, 0xf,0x39,0x55, + 0x6,0x46,0x7e, 0x5,0x3d,0x7c, 0x5,0x3d,0x7d, 0x6,0x51,0x24, + 0x6,0x51,0x23, 0x6,0x50,0x7e, 0xf,0x40,0x51, 0x6,0x51,0x21, + 0x4,0x3c,0x3f, 0x4,0x42,0x49, 0x6,0x5b,0x34, 0x6,0x5b,0x37, + 0x6,0x5b,0x33, 0x6,0x5b,0x38, 0x5,0x44,0x6f, 0xf,0x46,0x6d, + 0xf,0x46,0x6e, 0x6,0x5b,0x36, 0x6,0x5b,0x39, 0x6,0x5b,0x3b, + 0x6,0x5b,0x3a, 0x6,0x5b,0x35, 0x7,0x21,0x43, 0x4,0x49,0x28, + 0x5,0x4c,0x30, 0x7,0x21,0x44, 0x7,0x21,0x42, 0xf,0x4d,0x6d, + 0x7,0x25,0x48, 0x5,0x53,0x65, 0x7,0x2c,0x53, 0x7,0x2c,0x52, + 0xf,0x53,0x59, 0xf,0x53,0x5a, 0x7,0x3b,0x4d, 0xf,0x5e,0x39, + 0xf,0x5e,0x3a, 0xf,0x5e,0x3b, 0xf,0x64,0x7c, 0x7,0x4e,0x27, + 0x7,0x52,0x79, 0x5,0x77,0x54, 0x7,0x5e,0x50, 0x7,0x65,0x33, + 0x7,0x66,0x33, 0x5,0x21,0x2e, 0x6,0x21,0x3c, 0x6,0x21,0x3d, + 0x6,0x21,0x5d, 0x6,0x22,0x52, 0x6,0x22,0x51, 0x4,0x22,0x4a, + 0x6,0x24,0x23, 0x6,0x24,0x21, 0xf,0x22,0x2e, 0x4,0x22,0x49, + 0x6,0x24,0x22, 0x6,0x26,0x40, 0xf,0x23,0x40, 0x5,0x23,0x3c, + 0x6,0x2a,0x2c, 0x6,0x2a,0x2b, 0x6,0x2a,0x2d, 0x6,0x2a,0x2e, + 0x6,0x2f,0x47, 0x6,0x2f,0x48, 0x4,0x28,0x56, 0xf,0x29,0x4f, + 0x6,0x35,0x76, 0x6,0x35,0x75, 0x6,0x36,0x49, 0x6,0x35,0x2e, + 0x5,0x36,0x6c, 0x6,0x47,0x22, 0x6,0x47,0x24, 0x6,0x4d,0x62, + 0xf,0x39,0x56, 0x6,0x47,0x23, 0x5,0x3e,0x21, 0x6,0x51,0x25, + 0x5,0x3d,0x7e, 0xf,0x40,0x52, 0x6,0x5b,0x3c, 0xf,0x46,0x6f, + 0x6,0x60,0x72, 0x7,0x21,0x45, 0x5,0x53,0x66, 0xf,0x59,0x57, + 0x7,0x4b,0x6a, 0x6,0x21,0x60, 0x5,0x21,0x40, 0x6,0x21,0x5e, + 0x5,0x21,0x42, 0x6,0x21,0x62, 0x6,0x21,0x5f, 0x6,0x22,0x55, + 0x4,0x21,0x68, 0x5,0x21,0x5e, 0x6,0x22,0x56, 0x5,0x21,0x5f, + 0x6,0x22,0x53, 0x6,0x22,0x54, 0x6,0x24,0x25, 0x4,0x22,0x4b, + 0x6,0x24,0x24, 0x5,0x22,0x42, 0x6,0x24,0x26, 0x5,0x22,0x41, + 0x6,0x24,0x27, 0x6,0x26,0x44, 0x6,0x26,0x42, 0x5,0x23,0x52, + 0xf,0x23,0x41, 0xf,0x23,0x42, 0xf,0x23,0x43, 0xf,0x23,0x44, + 0x4,0x23,0x50, 0x6,0x2a,0x31, 0x6,0x2a,0x2f, 0x6,0x2a,0x32, + 0x6,0x2a,0x30, 0xf,0x25,0x6f, 0x6,0x2f,0x4d, 0x6,0x2f,0x4a, + 0x6,0x2f,0x4c, 0x6,0x2f,0x4b, 0x6,0x2f,0x49, 0xf,0x29,0x51, + 0xf,0x29,0x52, 0x6,0x32,0x72, 0x5,0x28,0x36, 0x6,0x35,0x7b, + 0x5,0x2c,0x36, 0x6,0x35,0x7c, 0x6,0x35,0x79, 0x6,0x35,0x77, + 0x6,0x35,0x7a, 0xf,0x2e,0x3c, 0xf,0x2e,0x3d, 0xf,0x2e,0x3e, + 0xf,0x2e,0x3f, 0x6,0x3c,0x67, 0x6,0x3d,0x66, 0x6,0x3d,0x68, + 0x5,0x31,0x32, 0x5,0x31,0x33, 0x6,0x3d,0x65, 0x6,0x3d,0x63, + 0x6,0x3d,0x6b, 0x6,0x3d,0x64, 0x5,0x2c,0x37, 0x6,0x3d,0x62, + 0x6,0x3d,0x69, 0x6,0x3d,0x6a, 0x6,0x3c,0x7c, 0x6,0x3d,0x67, + 0x4,0x36,0x54, 0x5,0x36,0x6d, 0x6,0x47,0x27, 0x6,0x47,0x25, + 0xf,0x33,0x3e, 0xf,0x39,0x57, 0xf,0x39,0x58, 0xf,0x39,0x59, + 0xf,0x39,0x5a, 0x6,0x47,0x26, 0x4,0x3c,0x43, 0x4,0x3c,0x42, + 0x6,0x51,0x27, 0x6,0x51,0x28, 0x6,0x51,0x26, 0x4,0x3c,0x41, + 0x6,0x47,0x28, 0x6,0x51,0x5b, 0x6,0x51,0x29, 0x6,0x5f,0x21, + 0x6,0x5b,0x3e, 0x6,0x5b,0x3d, 0x5,0x44,0x70, 0x6,0x53,0x7b, + 0xf,0x4d,0x55, 0x5,0x4c,0x33, 0x5,0x4c,0x34, 0xf,0x46,0x70, + 0x5,0x4c,0x32, 0x7,0x2c,0x55, 0xf,0x53,0x5b, 0x3,0x50,0x39, + 0x5,0x54,0x2e, 0x7,0x2c,0x54, 0x7,0x37,0x29, 0x7,0x37,0x28, + 0xf,0x59,0x58, 0x4,0x5a,0x6f, 0x7,0x46,0x32, 0x7,0x46,0x31, + 0x4,0x66,0x31, 0xf,0x67,0x45, 0x7,0x57,0x51, 0x5,0x75,0x66, + 0x7,0x5e,0x51, 0x7,0x5e,0x52, 0x5,0x21,0x43, 0x6,0x21,0x64, + 0x4,0x21,0x47, 0x4,0x21,0x46, 0xf,0x21,0x36, 0x6,0x21,0x63, + 0x5,0x21,0x61, 0x6,0x22,0x59, 0x6,0x22,0x58, 0x6,0x22,0x5e, + 0x6,0x22,0x5a, 0x6,0x22,0x5d, 0x6,0x22,0x57, 0x6,0x22,0x42, + 0xf,0x21,0x4e, 0x6,0x22,0x5c, 0x5,0x22,0x47, 0x6,0x24,0x2d, + 0x5,0x22,0x45, 0x6,0x24,0x2e, 0x4,0x22,0x4d, 0x5,0x22,0x46, + 0x4,0x22,0x50, 0x6,0x24,0x2c, 0x4,0x22,0x4f, 0x4,0x22,0x4e, + 0x5,0x22,0x44, 0x6,0x24,0x28, 0xf,0x22,0x2f, 0xf,0x22,0x30, + 0xf,0x22,0x32, 0xf,0x22,0x34, 0x6,0x24,0x2a, 0xf,0x22,0x31, + 0xf,0x22,0x33, 0x5,0x22,0x43, 0x6,0x24,0x29, 0x6,0x24,0x2b, + 0x4,0x23,0x56, 0x6,0x26,0x4f, 0x6,0x26,0x46, 0x6,0x26,0x4d, + 0x6,0x26,0x4c, 0x5,0x23,0x56, 0x4,0x23,0x5a, 0x4,0x23,0x5d, + 0x5,0x23,0x5b, 0x5,0x23,0x54, 0x6,0x26,0x48, 0x4,0x23,0x57, + 0x4,0x23,0x52, 0x4,0x23,0x58, 0x5,0x23,0x58, 0x6,0x26,0x49, + 0x5,0x23,0x59, 0x4,0x23,0x55, 0x5,0x23,0x55, 0x6,0x26,0x47, + 0x5,0x23,0x5c, 0xf,0x23,0x45, 0xf,0x23,0x46, 0xf,0x23,0x47, + 0xf,0x23,0x4a, 0xf,0x23,0x4b, 0xf,0x23,0x4c, 0xf,0x23,0x48, + 0x6,0x26,0x4b, 0x6,0x26,0x4a, 0x6,0x26,0x50, 0x6,0x26,0x45, + 0x5,0x23,0x53, 0x5,0x23,0x57, 0x5,0x23,0x5a, 0x4,0x25,0x5c, + 0x4,0x25,0x5e, 0x6,0x2a,0x36, 0x5,0x25,0x4c, 0x5,0x25,0x44, + 0x4,0x25,0x5b, 0x6,0x2a,0x34, 0x5,0x25,0x4d, 0x5,0x25,0x45, + 0x5,0x25,0x47, 0x4,0x25,0x61, 0x5,0x25,0x50, 0x6,0x2a,0x33, + 0x5,0x25,0x52, 0x5,0x28,0x47, 0x6,0x2a,0x3b, 0x5,0x25,0x48, + 0x5,0x25,0x4b, 0x5,0x25,0x4a, 0x5,0x25,0x51, 0x5,0x25,0x49, + 0x5,0x25,0x4e, 0x6,0x2a,0x3d, 0x5,0x25,0x4f, 0xf,0x25,0x70, + 0xf,0x25,0x72, 0xf,0x25,0x73, 0xf,0x25,0x74, 0xf,0x25,0x75, + 0xf,0x25,0x76, 0xf,0x25,0x77, 0xf,0x25,0x78, 0xf,0x25,0x79, + 0xf,0x25,0x7a, 0xf,0x25,0x7d, 0xf,0x25,0x7e, 0xf,0x26,0x21, + 0xf,0x26,0x22, 0xf,0x26,0x23, 0x5,0x25,0x46, 0x6,0x2a,0x35, + 0x5,0x25,0x43, 0x6,0x2a,0x38, 0x6,0x2a,0x37, 0xf,0x25,0x7c, + 0x6,0x2a,0x3a, 0x5,0x2c,0x38, 0x5,0x28,0x46, 0x5,0x28,0x52, + 0x5,0x28,0x4d, 0x5,0x28,0x3c, 0x5,0x28,0x51, 0x6,0x2f,0x54, + 0x6,0x2f,0x4e, 0x5,0x28,0x3f, 0x4,0x28,0x5b, 0x4,0x28,0x5a, + 0x5,0x28,0x4f, 0x5,0x28,0x45, 0x5,0x28,0x4b, 0x5,0x28,0x4a, + 0x5,0x28,0x4e, 0x5,0x28,0x48, 0x5,0x28,0x49, 0x5,0x28,0x3d, + 0x5,0x28,0x41, 0x5,0x28,0x4c, 0x4,0x25,0x62, 0x6,0x2f,0x59, + 0x6,0x2f,0x5a, 0x5,0x28,0x53, 0x6,0x2f,0x4f, 0x5,0x28,0x3a, + 0x6,0x2f,0x57, 0x6,0x2f,0x56, 0x5,0x28,0x50, 0x6,0x2f,0x50, + 0x6,0x2f,0x58, 0x6,0x2f,0x52, 0x5,0x28,0x40, 0x5,0x28,0x42, + 0xf,0x2b,0x33, 0xf,0x29,0x53, 0xf,0x29,0x55, 0xf,0x29,0x56, + 0xf,0x29,0x57, 0xf,0x29,0x58, 0xf,0x29,0x59, 0xf,0x29,0x5a, + 0xf,0x29,0x5b, 0xf,0x29,0x5e, 0xf,0x29,0x5f, 0xf,0x29,0x60, + 0xf,0x29,0x61, 0xf,0x29,0x62, 0xf,0x29,0x63, 0xf,0x29,0x64, + 0xf,0x29,0x66, 0xf,0x29,0x67, 0x5,0x28,0x43, 0x5,0x28,0x44, + 0x4,0x28,0x5d, 0xf,0x29,0x65, 0x6,0x2f,0x55, 0x6,0x2f,0x53, + 0x4,0x28,0x58, 0x5,0x28,0x3b, 0x5,0x28,0x3e, 0x6,0x2f,0x51, + 0x6,0x36,0x29, 0x4,0x2c,0x24, 0x4,0x2c,0x2b, 0x4,0x2c,0x2c, + 0x4,0x2c,0x27, 0x6,0x36,0x22, 0x5,0x2c,0x4e, 0x5,0x2c,0x41, + 0x5,0x2c,0x3f, 0x5,0x2c,0x4c, 0x5,0x2c,0x3d, 0x5,0x2c,0x46, + 0x5,0x2c,0x56, 0x5,0x2c,0x49, 0x4,0x2c,0x2a, 0x5,0x2c,0x4d, + 0x5,0x2c,0x54, 0x5,0x2c,0x52, 0x4,0x2c,0x22, 0x6,0x36,0x23, + 0x6,0x36,0x24, 0x5,0x2c,0x51, 0x4,0x2c,0x23, 0x5,0x2c,0x40, + 0x6,0x36,0x27, 0x6,0x36,0x28, 0x5,0x2c,0x57, 0x6,0x36,0x26, + 0x5,0x2c,0x53, 0x5,0x2c,0x58, 0x5,0x2c,0x47, 0x5,0x2c,0x59, + 0x5,0x2c,0x44, 0x5,0x2c,0x55, 0xf,0x2e,0x40, 0xf,0x2e,0x41, + 0xf,0x2e,0x43, 0xf,0x2e,0x44, 0xf,0x2e,0x48, 0xf,0x2e,0x49, + 0xf,0x2e,0x4b, 0xf,0x2e,0x4c, 0xf,0x2e,0x4d, 0xf,0x2e,0x4e, + 0xf,0x2e,0x4f, 0xf,0x2e,0x50, 0xf,0x2e,0x51, 0xf,0x2e,0x52, + 0xf,0x2e,0x53, 0xf,0x2e,0x54, 0x6,0x39,0x5e, 0x6,0x36,0x21, + 0x5,0x2c,0x42, 0x5,0x2c,0x45, 0x5,0x2c,0x48, 0x6,0x36,0x25, + 0x5,0x2c,0x50, 0x5,0x2c,0x4b, 0x5,0x2c,0x39, 0x5,0x2c,0x3a, + 0x5,0x2c,0x3b, 0xf,0x2e,0x45, 0x5,0x2c,0x4a, 0x5,0x2c,0x4f, + 0x5,0x2c,0x3e, 0x5,0x2c,0x3c, 0x5,0x2c,0x5a, 0x5,0x31,0x46, + 0x4,0x30,0x69, 0x6,0x3d,0x77, 0x6,0x3d,0x74, 0x4,0x30,0x78, + 0x6,0x3d,0x6f, 0x4,0x30,0x75, 0x5,0x31,0x51, 0x5,0x31,0x49, + 0x5,0x31,0x4c, 0x4,0x30,0x6e, 0x4,0x30,0x79, 0x5,0x31,0x44, + 0x6,0x3d,0x76, 0x5,0x31,0x36, 0x5,0x31,0x4a, 0x5,0x31,0x45, + 0x5,0x31,0x4e, 0x5,0x31,0x34, 0x5,0x31,0x4d, 0x5,0x31,0x42, + 0x5,0x31,0x3b, 0x6,0x3d,0x71, 0x6,0x3d,0x75, 0x6,0x3d,0x7d, + 0x6,0x3d,0x7a, 0x6,0x3d,0x7e, 0x5,0x31,0x3a, 0x5,0x31,0x3c, + 0x6,0x3d,0x6c, 0x5,0x31,0x38, 0x6,0x3d,0x72, 0x6,0x3d,0x7b, + 0xf,0x33,0x3f, 0xf,0x33,0x40, 0xf,0x33,0x41, 0xf,0x33,0x42, + 0xf,0x33,0x44, 0xf,0x33,0x45, 0xf,0x33,0x46, 0xf,0x33,0x47, + 0xf,0x33,0x48, 0xf,0x33,0x49, 0xf,0x33,0x4c, 0xf,0x33,0x4d, + 0x5,0x31,0x37, 0x6,0x3d,0x73, 0x5,0x31,0x39, 0x6,0x3d,0x6d, + 0x5,0x31,0x41, 0x5,0x31,0x48, 0x6,0x3e,0x21, 0x5,0x31,0x52, + 0x6,0x3d,0x70, 0x5,0x31,0x40, 0x5,0x31,0x35, 0x5,0x31,0x47, + 0x5,0x31,0x3e, 0x5,0x31,0x43, 0x5,0x31,0x3d, 0x5,0x31,0x50, + 0x6,0x3d,0x79, 0x3,0x34,0x60, 0x5,0x31,0x53, 0x5,0x31,0x4f, + 0x6,0x3d,0x78, 0x6,0x3d,0x6e, 0x5,0x31,0x3f, 0x5,0x31,0x4b, + 0x4,0x36,0x55, 0x4,0x36,0x61, 0x6,0x47,0x32, 0x5,0x37,0x24, + 0x6,0x47,0x37, 0x6,0x47,0x3e, 0x5,0x36,0x77, 0x6,0x47,0x35, + 0x5,0x36,0x7c, 0x4,0x36,0x56, 0x5,0x37,0x28, 0x5,0x36,0x6f, + 0x5,0x36,0x71, 0x4,0x36,0x5a, 0x5,0x36,0x78, 0x4,0x36,0x57, + 0x5,0x37,0x29, 0x5,0x36,0x7e, 0x4,0x36,0x62, 0x4,0x36,0x5b, + 0x5,0x37,0x23, 0x5,0x37,0x27, 0x4,0x36,0x66, 0x5,0x37,0x30, + 0x4,0x36,0x5d, 0x5,0x37,0x2c, 0x5,0x37,0x2e, 0x6,0x47,0x2e, + 0x6,0x47,0x3c, 0x5,0x3e,0x22, 0x6,0x47,0x2b, 0x6,0x47,0x2f, + 0x6,0x47,0x38, 0x5,0x37,0x22, 0x6,0x47,0x34, 0x6,0x47,0x3f, + 0x6,0x47,0x3a, 0x4,0x36,0x64, 0x5,0x37,0x26, 0x5,0x36,0x73, + 0xf,0x39,0x5b, 0xf,0x39,0x5d, 0xf,0x39,0x5e, 0xf,0x39,0x61, + 0xf,0x39,0x62, 0xf,0x39,0x63, 0xf,0x39,0x64, 0xf,0x39,0x65, + 0xf,0x39,0x66, 0xf,0x39,0x67, 0xf,0x39,0x68, 0xf,0x39,0x6a, + 0xf,0x39,0x6d, 0xf,0x39,0x6e, 0xf,0x39,0x6f, 0xf,0x39,0x70, + 0x5,0x36,0x74, 0x5,0x36,0x75, 0x5,0x36,0x7b, 0x5,0x37,0x25, + 0x5,0x37,0x21, 0x6,0x47,0x3b, 0xf,0x39,0x6b, 0xf,0x39,0x5c, + 0xf,0x39,0x5f, 0xf,0x39,0x69, 0xf,0x39,0x6c, 0x5,0x37,0x2b, + 0x5,0x37,0x2f, 0x6,0x47,0x3d, 0x5,0x37,0x2d, 0x5,0x37,0x2a, + 0x5,0x36,0x7d, 0x6,0x47,0x36, 0x6,0x51,0x39, 0x5,0x3e,0x23, + 0x4,0x3c,0x49, 0x5,0x3e,0x27, 0x4,0x3c,0x4e, 0x5,0x36,0x72, + 0x6,0x51,0x41, 0x4,0x3c,0x48, 0x4,0x3c,0x44, 0x6,0x5b,0x42, + 0x5,0x3e,0x2d, 0x6,0x51,0x33, 0x6,0x51,0x35, 0x5,0x3e,0x2a, + 0x5,0x3e,0x38, 0x6,0x51,0x3a, 0x6,0x51,0x30, 0x5,0x3e,0x2e, + 0x5,0x3e,0x24, 0x5,0x3e,0x35, 0x5,0x3e,0x3f, 0x6,0x51,0x3f, + 0x6,0x51,0x37, 0x5,0x3e,0x34, 0x5,0x3e,0x37, 0x4,0x3c,0x4d, + 0x5,0x3e,0x3a, 0x4,0x3c,0x45, 0x5,0x3e,0x33, 0x5,0x3e,0x2c, + 0x4,0x3c,0x4f, 0x5,0x3e,0x2f, 0x4,0x3c,0x51, 0x5,0x3e,0x31, + 0x5,0x3e,0x32, 0x6,0x51,0x3b, 0x6,0x51,0x40, 0x6,0x51,0x2a, + 0x6,0x51,0x3e, 0x6,0x51,0x3d, 0x5,0x3e,0x3b, 0x6,0x51,0x38, + 0x5,0x3e,0x28, 0x5,0x3e,0x30, 0x5,0x3e,0x2b, 0x6,0x51,0x2c, + 0x6,0x51,0x44, 0x6,0x51,0x2e, 0x6,0x51,0x2b, 0x6,0x51,0x2d, + 0xf,0x47,0x26, 0x5,0x3e,0x3e, 0x6,0x51,0x31, 0xf,0x40,0x56, + 0xf,0x40,0x57, 0xf,0x40,0x58, 0xf,0x40,0x59, 0xf,0x40,0x5a, + 0xf,0x40,0x5b, 0xf,0x40,0x5c, 0xf,0x40,0x5d, 0xf,0x40,0x5e, + 0xf,0x40,0x5f, 0xf,0x40,0x60, 0xf,0x40,0x61, 0xf,0x40,0x63, + 0x6,0x51,0x2f, 0x6,0x51,0x34, 0x6,0x51,0x3c, 0xf,0x40,0x54, + 0x6,0x51,0x42, 0x5,0x3e,0x3c, 0x5,0x3e,0x36, 0x5,0x3e,0x25, + 0x5,0x3e,0x29, 0x5,0x3e,0x26, 0xf,0x40,0x64, 0x6,0x5b,0x46, + 0x6,0x5b,0x40, 0x6,0x5b,0x4b, 0x4,0x42,0x4d, 0x6,0x5b,0x4f, + 0x6,0x5b,0x45, 0x6,0x5b,0x51, 0x6,0x5b,0x50, 0x4,0x42,0x4e, + 0x6,0x5b,0x4c, 0x5,0x44,0x73, 0x5,0x44,0x77, 0x5,0x44,0x75, + 0x5,0x44,0x7c, 0x6,0x5b,0x43, 0x6,0x5b,0x47, 0x4,0x42,0x4c, + 0x4,0x42,0x54, 0x5,0x44,0x7b, 0x4,0x42,0x50, 0x5,0x44,0x76, + 0x6,0x5b,0x41, 0x5,0x44,0x71, 0x5,0x44,0x72, 0x5,0x44,0x79, + 0x6,0x5b,0x52, 0x6,0x5b,0x3f, 0x6,0x5b,0x49, 0x6,0x5b,0x4a, + 0x5,0x44,0x78, 0x6,0x5b,0x4d, 0xf,0x46,0x71, 0xf,0x46,0x72, + 0xf,0x46,0x73, 0xf,0x46,0x74, 0xf,0x46,0x76, 0xf,0x46,0x77, + 0xf,0x46,0x78, 0xf,0x46,0x79, 0xf,0x46,0x7a, 0xf,0x46,0x7b, + 0xf,0x46,0x7c, 0xf,0x46,0x7e, 0xf,0x47,0x21, 0xf,0x47,0x22, + 0xf,0x47,0x23, 0xf,0x47,0x27, 0xf,0x47,0x28, 0xf,0x47,0x29, + 0xf,0x47,0x2a, 0xf,0x47,0x2b, 0xf,0x47,0x2c, 0xf,0x47,0x2d, + 0xf,0x47,0x24, 0x6,0x5b,0x48, 0xf,0x46,0x75, 0x5,0x44,0x74, + 0x5,0x44,0x7a, 0x6,0x5b,0x4e, 0x5,0x45,0x21, 0xf,0x46,0x7d, + 0x6,0x5b,0x44, 0xf,0x47,0x25, 0x5,0x4c,0x35, 0x5,0x44,0x7d, + 0xf,0x46,0x6c, 0x7,0x21,0x51, 0x5,0x4c,0x3b, 0x7,0x21,0x55, + 0x7,0x21,0x52, 0x5,0x4c,0x39, 0x7,0x21,0x58, 0x7,0x21,0x4a, + 0x5,0x4c,0x40, 0x5,0x4c,0x46, 0x5,0x4c,0x3d, 0x7,0x21,0x4f, + 0x5,0x4c,0x3e, 0x7,0x21,0x57, 0x7,0x21,0x50, 0x5,0x4c,0x36, + 0x7,0x21,0x4b, 0x5,0x4c,0x3f, 0x7,0x21,0x56, 0x7,0x21,0x59, + 0x5,0x4c,0x41, 0x4,0x49,0x2f, 0x7,0x21,0x5b, 0x5,0x4c,0x3a, + 0x7,0x21,0x48, 0x5,0x4c,0x38, 0x5,0x5b,0x27, 0x7,0x21,0x5a, + 0x4,0x49,0x2b, 0x7,0x21,0x54, 0x5,0x45,0x23, 0x7,0x21,0x53, + 0x7,0x21,0x49, 0x7,0x21,0x47, 0x7,0x21,0x62, 0x7,0x21,0x5c, + 0xf,0x4d,0x7a, 0x7,0x21,0x5e, 0x5,0x4c,0x42, 0x7,0x21,0x61, + 0x7,0x2c,0x61, 0x5,0x4c,0x37, 0x4,0x49,0x32, 0x5,0x4c,0x47, + 0xf,0x4d,0x6f, 0xf,0x4d,0x70, 0xf,0x4d,0x71, 0xf,0x4d,0x72, + 0xf,0x4d,0x73, 0xf,0x4d,0x74, 0xf,0x4d,0x75, 0xf,0x4d,0x76, + 0xf,0x4d,0x78, 0xf,0x4d,0x79, 0x5,0x4c,0x44, 0x7,0x21,0x5f, + 0x7,0x26,0x2b, 0x7,0x21,0x5d, 0x7,0x21,0x4d, 0x7,0x21,0x4c, + 0x5,0x4c,0x3c, 0x5,0x4c,0x43, 0x7,0x2c,0x6a, 0x4,0x4f,0x6e, + 0x5,0x53,0x74, 0x7,0x2c,0x5c, 0x5,0x53,0x72, 0x7,0x2c,0x68, + 0x4,0x4f,0x72, 0x5,0x53,0x6a, 0x5,0x53,0x78, 0x7,0x2c,0x60, + 0x4,0x4f,0x68, 0x4,0x4f,0x73, 0x4,0x4f,0x66, 0x5,0x53,0x71, + 0x4,0x4f,0x70, 0x5,0x53,0x6f, 0x5,0x53,0x68, 0x7,0x2c,0x6b, + 0x7,0x2c,0x5b, 0x7,0x2c,0x64, 0x5,0x53,0x6e, 0x7,0x2c,0x5f, + 0x5,0x53,0x6c, 0x5,0x53,0x67, 0x5,0x53,0x75, 0x5,0x53,0x70, + 0x5,0x53,0x73, 0x7,0x2c,0x59, 0x5,0x53,0x6b, 0x5,0x53,0x69, + 0x7,0x2c,0x67, 0x7,0x2c,0x58, 0x7,0x2c,0x57, 0xf,0x4d,0x77, + 0x4,0x4f,0x69, 0x4,0x4f,0x74, 0x5,0x53,0x77, 0x7,0x2c,0x66, + 0xf,0x53,0x5c, 0xf,0x53,0x5e, 0xf,0x53,0x5f, 0xf,0x53,0x60, + 0xf,0x53,0x61, 0xf,0x53,0x62, 0xf,0x53,0x63, 0xf,0x53,0x64, + 0xf,0x53,0x65, 0xf,0x53,0x67, 0xf,0x53,0x68, 0xf,0x53,0x69, + 0xf,0x53,0x6a, 0xf,0x53,0x6b, 0xf,0x53,0x6c, 0xf,0x53,0x6d, + 0xf,0x53,0x6e, 0xf,0x53,0x6f, 0x7,0x2c,0x5e, 0x7,0x2c,0x5d, + 0x7,0x2c,0x62, 0x7,0x2c,0x69, 0x5,0x53,0x6d, 0xf,0x55,0x74, + 0x5,0x53,0x76, 0x4,0x55,0x7a, 0x5,0x5b,0x26, 0x5,0x5b,0x21, + 0x7,0x37,0x2d, 0x7,0x37,0x2a, 0x7,0x37,0x34, 0x7,0x37,0x35, + 0x5,0x5b,0x23, 0x5,0x5b,0x2b, 0x4,0x55,0x71, 0x4,0x55,0x76, + 0x5,0x5b,0x28, 0x4,0x55,0x77, 0x7,0x37,0x2b, 0x5,0x5b,0x29, + 0x4,0x55,0x79, 0x7,0x37,0x31, 0x7,0x37,0x2f, 0x7,0x37,0x2e, + 0x5,0x5b,0x24, 0x4,0x55,0x75, 0x7,0x37,0x32, 0x7,0x37,0x39, + 0xf,0x59,0x59, 0xf,0x59,0x5a, 0xf,0x59,0x5e, 0xf,0x59,0x5f, + 0xf,0x59,0x60, 0xf,0x59,0x61, 0xf,0x59,0x62, 0x7,0x37,0x38, + 0x7,0x37,0x30, 0x7,0x37,0x36, 0x7,0x37,0x33, 0x7,0x37,0x2c, + 0x5,0x5b,0x2a, 0x5,0x5b,0x22, 0x4,0x5a,0x74, 0x7,0x3f,0x29, + 0x7,0x3f,0x2f, 0x4,0x5a,0x73, 0x5,0x61,0x3e, 0x7,0x3f,0x2b, + 0x4,0x5a,0x71, 0x4,0x5a,0x76, 0x5,0x61,0x46, 0x4,0x5a,0x77, + 0x5,0x67,0x58, 0x5,0x61,0x3d, 0x5,0x61,0x44, 0x5,0x61,0x43, + 0x4,0x5a,0x78, 0x7,0x3f,0x2a, 0x4,0x5a,0x75, 0x4,0x5a,0x79, + 0x4,0x5a,0x72, 0x7,0x3f,0x2e, 0x5,0x61,0x41, 0x7,0x3f,0x27, + 0x7,0x3f,0x2d, 0x7,0x3f,0x28, 0x7,0x3f,0x26, 0x7,0x3f,0x2c, + 0x5,0x61,0x42, 0xf,0x59,0x5b, 0x7,0x3f,0x25, 0xf,0x5e,0x3c, + 0xf,0x5e,0x3d, 0xf,0x5e,0x3e, 0xf,0x5e,0x3f, 0xf,0x5e,0x40, + 0xf,0x5e,0x43, 0xf,0x5e,0x44, 0xf,0x5e,0x45, 0x5,0x61,0x3f, + 0xf,0x5e,0x4a, 0x7,0x46,0x34, 0x4,0x5f,0x4e, 0x5,0x5b,0x25, + 0x7,0x46,0x3b, 0x7,0x46,0x39, 0x7,0x46,0x37, 0x5,0x67,0x5a, + 0x5,0x67,0x5b, 0x4,0x5f,0x50, 0x5,0x67,0x57, 0x7,0x46,0x3c, + 0x7,0x46,0x3a, 0x7,0x46,0x33, 0x7,0x46,0x35, 0x7,0x46,0x38, + 0x4,0x5f,0x4f, 0xf,0x5e,0x46, 0x5,0x67,0x5c, 0xf,0x62,0x22, + 0xf,0x62,0x23, 0xf,0x62,0x24, 0xf,0x62,0x25, 0xf,0x62,0x26, + 0x7,0x46,0x36, 0x7,0x47,0x6e, 0x7,0x46,0x3d, 0x5,0x6b,0x74, + 0x5,0x6b,0x75, 0x5,0x6b,0x6f, 0x5,0x6b,0x71, 0x5,0x6b,0x70, + 0x7,0x4d,0x47, 0x7,0x4d,0x49, 0x7,0x4d,0x4b, 0x7,0x4d,0x48, + 0x7,0x4d,0x46, 0x7,0x4d,0x4a, 0xf,0x64,0x7d, 0xf,0x64,0x7e, + 0xf,0x65,0x21, 0x7,0x4d,0x4c, 0x5,0x6b,0x72, 0x7,0x52,0x7b, + 0x5,0x6f,0x71, 0x5,0x6f,0x6f, 0x4,0x66,0x35, 0x5,0x6f,0x6e, + 0x7,0x52,0x7a, 0x5,0x6f,0x6d, 0x7,0x52,0x7e, 0x5,0x6f,0x70, + 0x7,0x52,0x7d, 0x4,0x66,0x33, 0xf,0x67,0x47, 0xf,0x67,0x48, + 0x5,0x6f,0x6c, 0x7,0x52,0x7c, 0x7,0x57,0x59, 0x7,0x57,0x5a, + 0x5,0x73,0x33, 0x7,0x57,0x55, 0x7,0x57,0x56, 0x7,0x57,0x57, + 0x7,0x57,0x54, 0x7,0x57,0x52, 0x7,0x57,0x53, 0xf,0x69,0x3c, + 0x4,0x68,0x64, 0x7,0x57,0x58, 0x7,0x5b,0x49, 0x7,0x5b,0x4a, + 0xf,0x6a,0x4d, 0x7,0x5b,0x48, 0x7,0x5b,0x47, 0x5,0x77,0x55, + 0x5,0x77,0x56, 0x4,0x6b,0x66, 0x7,0x5e,0x53, 0x7,0x5e,0x55, + 0x7,0x5e,0x54, 0x7,0x5e,0x56, 0xf,0x6b,0x43, 0x5,0x75,0x67, + 0x5,0x79,0x23, 0x4,0x6c,0x6d, 0xf,0x6c,0x22, 0xf,0x6c,0x23, + 0x7,0x60,0x6b, 0x7,0x62,0x32, 0x7,0x62,0x31, 0x7,0x62,0x34, + 0x7,0x62,0x30, 0x7,0x62,0x33, 0xf,0x6c,0x79, 0xf,0x6c,0x7a, + 0x6,0x21,0x65, 0x6,0x21,0x66, 0xf,0x21,0x37, 0x4,0x21,0x6e, + 0x6,0x24,0x32, 0x6,0x24,0x30, 0x5,0x22,0x49, 0xf,0x22,0x35, + 0x6,0x24,0x31, 0x6,0x24,0x2f, 0x5,0x22,0x48, 0x6,0x26,0x54, + 0x6,0x2f,0x5c, 0x6,0x2a,0x3e, 0x6,0x26,0x58, 0x6,0x26,0x56, + 0xf,0x23,0x4f, 0xf,0x23,0x51, 0x6,0x26,0x57, 0x6,0x26,0x59, + 0x6,0x26,0x5c, 0x6,0x26,0x5a, 0x6,0x26,0x51, 0x6,0x26,0x55, + 0x6,0x26,0x52, 0x6,0x26,0x53, 0x6,0x26,0x5b, 0x5,0x25,0x55, + 0x6,0x2a,0x43, 0x6,0x2a,0x40, 0x6,0x2a,0x41, 0x6,0x2a,0x42, + 0x6,0x2d,0x34, 0x6,0x2a,0x3f, 0xf,0x26,0x24, 0x5,0x25,0x54, + 0x5,0x28,0x54, 0x5,0x28,0x56, 0x6,0x2f,0x60, 0x6,0x2f,0x5f, + 0x5,0x28,0x55, 0x6,0x2f,0x5b, 0x6,0x2f,0x5e, 0x6,0x2f,0x5d, + 0x5,0x2c,0x5c, 0x6,0x36,0x2d, 0x6,0x36,0x2a, 0x6,0x36,0x2c, + 0x5,0x2c,0x5b, 0x6,0x36,0x2b, 0x5,0x2c,0x5d, 0x5,0x31,0x56, + 0x6,0x3e,0x25, 0x5,0x31,0x57, 0x6,0x3e,0x24, 0x6,0x3e,0x23, + 0x6,0x3e,0x22, 0x5,0x31,0x54, 0x6,0x3e,0x26, 0x5,0x37,0x33, + 0x6,0x47,0x40, 0x6,0x47,0x41, 0x5,0x37,0x31, 0x5,0x31,0x55, + 0xf,0x39,0x72, 0xf,0x39,0x73, 0xf,0x39,0x74, 0x6,0x47,0x42, + 0x5,0x37,0x32, 0x5,0x3e,0x40, 0x6,0x51,0x45, 0x5,0x3e,0x41, + 0x6,0x51,0x47, 0x6,0x51,0x48, 0x5,0x3e,0x42, 0x6,0x51,0x46, + 0xf,0x40,0x65, 0x6,0x5b,0x54, 0x6,0x5b,0x58, 0x5,0x45,0x24, + 0x6,0x5b,0x55, 0x6,0x5b,0x5a, 0x6,0x5b,0x56, 0xf,0x47,0x2e, + 0xf,0x47,0x2f, 0xf,0x47,0x30, 0x6,0x5b,0x57, 0x7,0x21,0x65, + 0x7,0x21,0x66, 0x7,0x21,0x64, 0xf,0x4d,0x7b, 0x4,0x4f,0x75, + 0xf,0x53,0x73, 0x7,0x37,0x3c, 0x7,0x37,0x3a, 0x7,0x37,0x3b, + 0x4,0x5f,0x51, 0x7,0x4d,0x4d, 0x7,0x53,0x22, 0x7,0x53,0x21, + 0x4,0x21,0x48, 0x5,0x21,0x44, 0x6,0x22,0x60, 0xf,0x21,0x51, + 0xf,0x21,0x52, 0x6,0x22,0x61, 0x6,0x24,0x35, 0xf,0x22,0x36, + 0xf,0x22,0x37, 0x6,0x24,0x34, 0x6,0x26,0x6a, 0x4,0x23,0x60, + 0x6,0x26,0x66, 0x6,0x26,0x62, 0x6,0x26,0x5e, 0x6,0x26,0x69, + 0x6,0x26,0x5d, 0x6,0x26,0x65, 0x6,0x26,0x67, 0xf,0x23,0x53, + 0xf,0x23,0x54, 0xf,0x23,0x56, 0xf,0x23,0x58, 0xf,0x23,0x5a, + 0x6,0x26,0x60, 0x6,0x26,0x63, 0x6,0x26,0x68, 0x6,0x26,0x64, + 0x6,0x26,0x61, 0x6,0x26,0x5f, 0x5,0x23,0x5e, 0xf,0x23,0x59, + 0x5,0x23,0x5d, 0x5,0x23,0x5f, 0x5,0x23,0x60, 0x5,0x23,0x61, + 0x4,0x25,0x6a, 0x6,0x2a,0x4f, 0x6,0x2a,0x47, 0x6,0x2a,0x4c, + 0x6,0x2a,0x46, 0x4,0x25,0x67, 0x6,0x2a,0x4a, 0x4,0x25,0x6c, + 0x6,0x2a,0x48, 0x5,0x25,0x56, 0x6,0x2a,0x51, 0x6,0x26,0x41, + 0x6,0x2a,0x49, 0xf,0x26,0x26, 0xf,0x26,0x27, 0xf,0x26,0x28, + 0xf,0x26,0x29, 0xf,0x26,0x2a, 0xf,0x26,0x30, 0xf,0x26,0x31, + 0xf,0x26,0x2c, 0xf,0x26,0x2b, 0x4,0x25,0x6b, 0xf,0x26,0x2f, + 0xf,0x26,0x2e, 0x6,0x2a,0x50, 0x6,0x2a,0x4b, 0x6,0x2a,0x4d, + 0x6,0x2a,0x4e, 0xf,0x26,0x32, 0xf,0x26,0x25, 0x6,0x2a,0x45, + 0x6,0x2a,0x44, 0x5,0x25,0x57, 0x5,0x28,0x5b, 0x6,0x2f,0x62, + 0x5,0x28,0x57, 0x6,0x2f,0x64, 0x6,0x2f,0x61, 0x5,0x28,0x58, + 0x4,0x28,0x5f, 0x6,0x2f,0x6b, 0x6,0x2f,0x63, 0xf,0x29,0x7a, + 0xf,0x29,0x68, 0xf,0x29,0x69, 0xf,0x29,0x6b, 0xf,0x29,0x6c, + 0xf,0x29,0x6d, 0xf,0x29,0x6e, 0xf,0x29,0x6f, 0xf,0x29,0x70, + 0xf,0x29,0x72, 0xf,0x29,0x73, 0xf,0x29,0x75, 0xf,0x29,0x76, + 0xf,0x29,0x77, 0xf,0x29,0x78, 0xf,0x29,0x79, 0xf,0x29,0x7b, + 0xf,0x29,0x7c, 0xf,0x29,0x7d, 0x6,0x2f,0x6a, 0x6,0x2f,0x6c, + 0x6,0x34,0x31, 0x6,0x2f,0x67, 0x6,0x2f,0x68, 0x6,0x2f,0x66, + 0xf,0x29,0x74, 0x5,0x28,0x5d, 0x5,0x28,0x5a, 0x5,0x28,0x5e, + 0x5,0x28,0x5c, 0x5,0x28,0x59, 0x5,0x2c,0x5e, 0x4,0x2c,0x32, + 0x6,0x36,0x34, 0x4,0x2c,0x30, 0x4,0x2c,0x34, 0x6,0x36,0x32, + 0x6,0x36,0x3c, 0x6,0x36,0x36, 0x6,0x36,0x3d, 0x6,0x36,0x3e, + 0x6,0x36,0x31, 0x6,0x36,0x2e, 0x6,0x36,0x3a, 0x6,0x36,0x2f, + 0x6,0x36,0x40, 0xf,0x2e,0x55, 0xf,0x2e,0x56, 0xf,0x2e,0x57, + 0xf,0x2e,0x58, 0xf,0x2e,0x59, 0xf,0x2e,0x5a, 0xf,0x2e,0x5b, + 0xf,0x2e,0x5e, 0xf,0x2e,0x5f, 0xf,0x2e,0x60, 0x6,0x36,0x30, + 0x6,0x36,0x3f, 0x6,0x36,0x37, 0x6,0x36,0x38, 0x6,0x36,0x39, + 0x5,0x2c,0x60, 0x6,0x36,0x3b, 0xf,0x2e,0x5d, 0xf,0x2e,0x61, + 0x6,0x36,0x33, 0x5,0x2c,0x5f, 0x5,0x2c,0x62, 0x4,0x30,0x7d, + 0x6,0x3e,0x27, 0x4,0x30,0x7c, 0x5,0x31,0x5d, 0x6,0x3e,0x34, + 0x6,0x3e,0x2d, 0x5,0x31,0x5b, 0x6,0x3e,0x2a, 0x5,0x2c,0x61, + 0x6,0x3e,0x33, 0x6,0x3e,0x30, 0x5,0x31,0x5a, 0x4,0x31,0x22, + 0x4,0x31,0x23, 0xf,0x33,0x4f, 0xf,0x33,0x5b, 0x6,0x3e,0x2e, + 0x6,0x3e,0x2f, 0xf,0x33,0x4e, 0xf,0x33,0x50, 0xf,0x33,0x51, + 0xf,0x33,0x52, 0xf,0x33,0x53, 0xf,0x33,0x54, 0xf,0x33,0x55, + 0xf,0x33,0x56, 0xf,0x33,0x58, 0xf,0x33,0x59, 0xf,0x33,0x5a, + 0xf,0x33,0x5e, 0xf,0x33,0x5f, 0xf,0x33,0x60, 0xf,0x33,0x61, + 0x5,0x31,0x5c, 0x6,0x3e,0x31, 0x6,0x3e,0x35, 0x4,0x30,0x7e, + 0x6,0x3e,0x28, 0x6,0x3e,0x29, 0x5,0x31,0x58, 0x5,0x31,0x59, + 0x3,0x3a,0x4f, 0x6,0x51,0x4e, 0x4,0x36,0x72, 0x6,0x47,0x47, + 0x4,0x36,0x6a, 0x6,0x47,0x45, 0x4,0x36,0x70, 0x4,0x36,0x6c, + 0x6,0x47,0x4b, 0x6,0x47,0x50, 0x4,0x36,0x75, 0x6,0x47,0x44, + 0x6,0x47,0x46, 0x6,0x47,0x4d, 0x5,0x37,0x34, 0x6,0x3e,0x32, + 0x6,0x47,0x4f, 0x4,0x3c,0x5a, 0x5,0x37,0x39, 0x4,0x36,0x73, + 0x6,0x4f,0x6d, 0x5,0x37,0x38, 0xf,0x39,0x76, 0xf,0x39,0x78, + 0xf,0x39,0x79, 0xf,0x39,0x7a, 0xf,0x39,0x7b, 0xf,0x39,0x7c, + 0xf,0x3a,0x21, 0xf,0x3a,0x22, 0xf,0x3a,0x23, 0xf,0x3a,0x24, + 0xf,0x3a,0x25, 0xf,0x3a,0x26, 0x6,0x47,0x51, 0x6,0x47,0x4a, + 0x6,0x47,0x49, 0x4,0x36,0x74, 0x6,0x47,0x4c, 0xf,0x39,0x75, + 0x5,0x37,0x37, 0x5,0x37,0x3a, 0x6,0x47,0x48, 0x5,0x37,0x35, + 0x5,0x37,0x36, 0x5,0x37,0x3b, 0x5,0x3e,0x46, 0x6,0x51,0x56, + 0x6,0x51,0x4b, 0x6,0x51,0x55, 0x5,0x3e,0x4d, 0x4,0x3c,0x54, + 0x6,0x5b,0x62, 0x6,0x51,0x52, 0x5,0x3e,0x4c, 0x6,0x51,0x51, + 0x5,0x3e,0x44, 0x5,0x3e,0x4b, 0x5,0x3e,0x43, 0x6,0x51,0x54, + 0x6,0x51,0x50, 0x5,0x3e,0x49, 0x5,0x3e,0x4a, 0x4,0x3c,0x55, + 0x5,0x3e,0x47, 0x6,0x51,0x49, 0x6,0x51,0x4c, 0xf,0x39,0x77, + 0x6,0x51,0x53, 0x6,0x51,0x4d, 0xf,0x40,0x66, 0xf,0x40,0x67, + 0xf,0x40,0x68, 0xf,0x40,0x6a, 0xf,0x40,0x6b, 0xf,0x40,0x6c, + 0xf,0x40,0x6d, 0xf,0x40,0x6e, 0xf,0x40,0x6f, 0xf,0x40,0x70, + 0xf,0x40,0x71, 0xf,0x40,0x72, 0xf,0x40,0x73, 0x6,0x51,0x4f, + 0x5,0x3e,0x4e, 0x5,0x3e,0x48, 0x5,0x3e,0x45, 0x5,0x45,0x29, + 0x5,0x45,0x28, 0x5,0x45,0x27, 0x6,0x5b,0x5c, 0x4,0x42,0x5c, + 0x6,0x5b,0x64, 0x6,0x5b,0x66, 0x6,0x5b,0x61, 0x5,0x45,0x2a, + 0x6,0x5b,0x60, 0x5,0x45,0x26, 0x6,0x5b,0x67, 0xf,0x47,0x32, + 0xf,0x47,0x33, 0xf,0x47,0x34, 0xf,0x47,0x35, 0xf,0x47,0x36, + 0xf,0x47,0x37, 0xf,0x47,0x39, 0xf,0x47,0x3a, 0xf,0x47,0x3b, + 0xf,0x47,0x3c, 0x6,0x5b,0x5d, 0xf,0x47,0x38, 0x6,0x5b,0x6b, + 0x6,0x5b,0x63, 0x6,0x5b,0x53, 0xf,0x47,0x31, 0x4,0x42,0x5a, + 0x6,0x5b,0x65, 0x6,0x5b,0x5e, 0x5,0x45,0x25, 0x5,0x45,0x2b, + 0x7,0x21,0x72, 0x4,0x49,0x34, 0x4,0x49,0x35, 0x7,0x21,0x6f, + 0x4,0x49,0x36, 0x5,0x4c,0x4b, 0x5,0x4c,0x4c, 0x7,0x21,0x6b, + 0x7,0x21,0x78, 0x4,0x49,0x37, 0x7,0x21,0x77, 0x7,0x21,0x74, + 0xf,0x4e,0x21, 0x5,0x4c,0x4d, 0x5,0x4c,0x4f, 0x7,0x21,0x67, + 0x7,0x21,0x75, 0xf,0x4d,0x7c, 0xf,0x4d,0x7d, 0xf,0x4e,0x26, + 0xf,0x4e,0x27, 0xf,0x4e,0x28, 0xf,0x4e,0x29, 0xf,0x4e,0x2a, + 0xf,0x4e,0x2b, 0xf,0x4e,0x2d, 0x7,0x21,0x6c, 0x7,0x21,0x6d, + 0x7,0x21,0x6e, 0x5,0x4c,0x71, 0x7,0x21,0x73, 0x7,0x21,0x71, + 0x7,0x21,0x69, 0xf,0x4d,0x7e, 0xf,0x4e,0x24, 0xf,0x4e,0x23, + 0x5,0x4c,0x4e, 0x5,0x4c,0x4a, 0x5,0x4c,0x48, 0x7,0x21,0x68, + 0x5,0x4c,0x49, 0x7,0x2c,0x6f, 0x7,0x2c,0x71, 0x7,0x2c,0x6c, + 0x4,0x4f,0x77, 0x4,0x4f,0x7a, 0x4,0x4f,0x79, 0x7,0x2c,0x6d, + 0x7,0x2c,0x70, 0xf,0x4e,0x2c, 0xf,0x53,0x74, 0xf,0x53,0x76, + 0xf,0x53,0x78, 0x5,0x53,0x7a, 0x7,0x2c,0x72, 0x5,0x53,0x7b, + 0x5,0x53,0x79, 0x7,0x34,0x6f, 0x7,0x2c,0x73, 0x7,0x2c,0x6e, + 0xf,0x53,0x77, 0x4,0x4f,0x76, 0x7,0x37,0x43, 0x4,0x55,0x7d, + 0x7,0x37,0x3d, 0x5,0x5b,0x2e, 0x7,0x37,0x3f, 0x7,0x37,0x44, + 0x7,0x37,0x42, 0x7,0x37,0x45, 0x5,0x5b,0x2c, 0x7,0x2c,0x74, + 0xf,0x59,0x64, 0xf,0x59,0x65, 0xf,0x59,0x66, 0xf,0x59,0x67, + 0xf,0x59,0x68, 0xf,0x59,0x69, 0xf,0x59,0x6a, 0xf,0x59,0x6b, + 0x7,0x3e,0x6c, 0x7,0x37,0x40, 0x7,0x37,0x41, 0x4,0x55,0x7e, + 0x5,0x5b,0x2f, 0x7,0x3f,0x34, 0x5,0x61,0x47, 0x7,0x37,0x3e, + 0x5,0x61,0x49, 0x7,0x3f,0x33, 0xf,0x5e,0x47, 0xf,0x5e,0x48, + 0xf,0x5e,0x49, 0xf,0x5e,0x4b, 0xf,0x5e,0x4d, 0xf,0x5e,0x4e, + 0x7,0x3f,0x31, 0x7,0x3f,0x32, 0x5,0x5b,0x30, 0x5,0x61,0x48, + 0xf,0x62,0x28, 0x5,0x61,0x4a, 0x7,0x46,0x42, 0x7,0x46,0x3f, + 0x5,0x67,0x5d, 0x7,0x46,0x47, 0x7,0x46,0x41, 0xf,0x5e,0x4c, + 0xf,0x62,0x27, 0x7,0x46,0x43, 0x7,0x46,0x46, 0x7,0x4a,0x3b, + 0x7,0x46,0x40, 0x7,0x3f,0x35, 0x4,0x63,0x33, 0xf,0x65,0x22, + 0xf,0x65,0x23, 0xf,0x65,0x24, 0xf,0x65,0x25, 0x7,0x4d,0x4e, + 0x5,0x6b,0x77, 0x7,0x53,0x28, 0x4,0x66,0x36, 0x7,0x53,0x24, + 0x7,0x53,0x23, 0x7,0x53,0x27, 0x7,0x53,0x25, 0x5,0x6f,0x74, + 0xf,0x67,0x49, 0xf,0x67,0x4a, 0xf,0x67,0x4c, 0x7,0x53,0x26, + 0xf,0x67,0x4b, 0x5,0x6f,0x72, 0x5,0x6f,0x73, 0x7,0x57,0x5b, + 0xf,0x69,0x3d, 0x5,0x73,0x34, 0x7,0x57,0x5d, 0x5,0x73,0x35, + 0x7,0x5b,0x4b, 0x7,0x57,0x5c, 0x7,0x5e,0x57, 0x5,0x77,0x57, + 0x5,0x7b,0x5f, 0x7,0x65,0x5a, 0x7,0x66,0x42, 0x7,0x66,0x4f, + 0x6,0x22,0x62, 0x6,0x2f,0x6d, 0x6,0x26,0x6b, 0x6,0x2a,0x52, + 0xf,0x29,0x7e, 0xf,0x2a,0x21, 0x5,0x2c,0x64, 0x6,0x36,0x42, + 0x6,0x2f,0x6e, 0x6,0x36,0x41, 0xf,0x2e,0x62, 0x5,0x2c,0x63, + 0x6,0x3e,0x36, 0xf,0x33,0x62, 0x6,0x47,0x52, 0x6,0x51,0x59, + 0x6,0x51,0x58, 0x6,0x5b,0x6a, 0x6,0x64,0x7a, 0x6,0x5b,0x68, + 0xf,0x47,0x3d, 0x6,0x5b,0x69, 0x7,0x21,0x7a, 0x7,0x21,0x79, + 0x7,0x2c,0x75, 0x7,0x3f,0x36, 0x7,0x43,0x3f, 0xf,0x5e,0x4f, + 0x7,0x3f,0x37, 0x7,0x46,0x48, 0x7,0x46,0x49, 0x7,0x48,0x3b, + 0x7,0x57,0x5e, 0x5,0x21,0x2f, 0x6,0x22,0x63, 0x6,0x24,0x37, + 0x6,0x24,0x36, 0x6,0x26,0x6c, 0xf,0x23,0x5c, 0x6,0x36,0x43, + 0x6,0x3e,0x37, 0x6,0x3e,0x38, 0x6,0x51,0x5a, 0x6,0x24,0x39, + 0x6,0x24,0x38, 0x5,0x23,0x64, 0x5,0x23,0x63, 0x4,0x25,0x6f, + 0x6,0x2a,0x53, 0xf,0x26,0x34, 0xf,0x2e,0x63, 0x5,0x31,0x5e, + 0x6,0x3e,0x39, 0x6,0x3e,0x3c, 0x5,0x2c,0x65, 0x6,0x3e,0x3b, + 0x6,0x3e,0x3a, 0x5,0x3e,0x4f, 0x6,0x51,0x5c, 0xf,0x40,0x74, + 0x6,0x5b,0x6c, 0xf,0x47,0x3e, 0x6,0x5b,0x6d, 0x5,0x4c,0x50, + 0xf,0x4e,0x2f, 0xf,0x53,0x79, 0x7,0x2c,0x76, 0x7,0x2c,0x77, + 0x7,0x37,0x46, 0x7,0x46,0x4a, 0x7,0x3f,0x3a, 0x7,0x3f,0x38, + 0x7,0x3f,0x39, 0x7,0x46,0x4b, 0x7,0x4d,0x4f, 0x6,0x22,0x64, + 0x6,0x22,0x65, 0x6,0x24,0x3a, 0x6,0x26,0x6e, 0x6,0x26,0x6d, + 0x6,0x2a,0x54, 0xf,0x25,0x42, 0x5,0x28,0x5f, 0x5,0x2c,0x68, + 0x4,0x2c,0x35, 0x5,0x2c,0x67, 0x6,0x36,0x46, 0x6,0x36,0x45, + 0xf,0x2e,0x64, 0xf,0x2e,0x65, 0x6,0x36,0x47, 0x5,0x2c,0x69, + 0x4,0x31,0x24, 0x5,0x31,0x61, 0x6,0x3e,0x3d, 0x5,0x31,0x5f, + 0x5,0x31,0x60, 0x5,0x31,0x62, 0xf,0x33,0x63, 0x6,0x47,0x54, + 0x5,0x37,0x3e, 0x5,0x37,0x42, 0x5,0x37,0x40, 0x5,0x37,0x41, + 0xf,0x3a,0x27, 0x5,0x3e,0x50, 0x6,0x51,0x5d, 0x5,0x3e,0x52, + 0x5,0x3e,0x51, 0x6,0x51,0x5f, 0x4,0x42,0x61, 0x6,0x5b,0x6f, + 0x6,0x5b,0x70, 0x6,0x5b,0x6e, 0x5,0x45,0x2c, 0x5,0x45,0x2e, + 0x7,0x21,0x7b, 0x5,0x4c,0x51, 0x7,0x3f,0x3b, 0x5,0x5b,0x31, + 0x5,0x5b,0x32, 0x7,0x46,0x4c, 0x6,0x21,0x67, 0x6,0x21,0x68, + 0xf,0x21,0x38, 0x6,0x22,0x66, 0xf,0x21,0x53, 0xf,0x21,0x54, + 0x5,0x21,0x76, 0x6,0x24,0x3c, 0x4,0x22,0x54, 0x6,0x24,0x3f, + 0x6,0x24,0x40, 0x6,0x24,0x3e, 0x6,0x24,0x3d, 0xf,0x21,0x6b, + 0x4,0x23,0x63, 0x4,0x23,0x64, 0x4,0x23,0x66, 0xf,0x23,0x5d, + 0xf,0x23,0x5e, 0xf,0x23,0x5f, 0xf,0x23,0x60, 0xf,0x23,0x61, + 0xf,0x23,0x62, 0xf,0x23,0x63, 0x6,0x26,0x70, 0x6,0x26,0x6f, + 0x4,0x25,0x76, 0x5,0x25,0x5a, 0x4,0x25,0x74, 0x6,0x2a,0x55, + 0x6,0x2a,0x56, 0x4,0x28,0x63, 0x6,0x2a,0x5c, 0x6,0x2a,0x58, + 0x6,0x2a,0x59, 0xf,0x26,0x36, 0xf,0x26,0x37, 0x6,0x2a,0x5a, + 0x6,0x2a,0x5b, 0x6,0x2a,0x5d, 0x4,0x25,0x79, 0x6,0x2a,0x57, + 0x6,0x29,0x39, 0x4,0x28,0x64, 0x4,0x28,0x62, 0x5,0x28,0x61, + 0x5,0x28,0x62, 0x5,0x28,0x60, 0xf,0x2a,0x23, 0xf,0x2a,0x24, + 0xf,0x2a,0x25, 0xf,0x2a,0x26, 0xf,0x2a,0x28, 0xf,0x2a,0x29, + 0xf,0x2a,0x27, 0xf,0x2a,0x22, 0x5,0x2c,0x6c, 0x6,0x36,0x48, + 0x6,0x36,0x4b, 0x5,0x2c,0x6a, 0x5,0x2c,0x6d, 0xf,0x2e,0x67, + 0xf,0x2e,0x68, 0xf,0x2e,0x69, 0x6,0x36,0x4a, 0x4,0x2c,0x37, + 0x5,0x2c,0x6b, 0x5,0x31,0x64, 0xf,0x2e,0x66, 0x4,0x2c,0x36, + 0x6,0x3e,0x41, 0x6,0x3e,0x44, 0x3,0x34,0x7e, 0x6,0x3e,0x3e, + 0x6,0x3e,0x43, 0x6,0x3e,0x40, 0x6,0x3e,0x45, 0x6,0x3e,0x3f, + 0xf,0x33,0x64, 0xf,0x33,0x65, 0x4,0x31,0x27, 0x5,0x31,0x63, + 0x4,0x3c,0x5e, 0x6,0x47,0x58, 0x6,0x47,0x5b, 0x6,0x47,0x5d, + 0x6,0x47,0x5a, 0xf,0x3a,0x28, 0x6,0x47,0x55, 0x6,0x47,0x5c, + 0x5,0x37,0x43, 0x6,0x47,0x59, 0x4,0x36,0x7a, 0x4,0x36,0x78, + 0x5,0x37,0x44, 0x6,0x47,0x57, 0x6,0x51,0x60, 0x6,0x51,0x61, + 0x4,0x3c,0x5d, 0xf,0x40,0x76, 0x5,0x3e,0x53, 0x5,0x3e,0x54, + 0x5,0x3e,0x55, 0x6,0x5b,0x72, 0x4,0x42,0x63, 0x5,0x45,0x2f, + 0x4,0x42,0x62, 0xf,0x47,0x3f, 0xf,0x47,0x40, 0xf,0x47,0x41, + 0x6,0x5b,0x71, 0x5,0x45,0x30, 0x4,0x49,0x38, 0x7,0x22,0x22, + 0x7,0x21,0x7c, 0x7,0x22,0x21, 0x7,0x2c,0x7c, 0x7,0x21,0x7e, + 0x5,0x4c,0x53, 0xf,0x4e,0x31, 0xf,0x4e,0x32, 0x7,0x21,0x7d, + 0x4,0x42,0x64, 0x5,0x4c,0x52, 0x7,0x2c,0x7d, 0x5,0x53,0x7c, + 0x7,0x2c,0x78, 0x7,0x2c,0x79, 0x4,0x56,0x21, 0xf,0x53,0x7a, + 0x7,0x2c,0x7a, 0x7,0x37,0x48, 0x7,0x37,0x47, 0x5,0x5b,0x33, + 0x4,0x56,0x2e, 0x4,0x5a,0x7b, 0xf,0x62,0x29, 0x5,0x6b,0x78, + 0x7,0x53,0x29, 0xf,0x69,0x3e, 0x5,0x75,0x68, 0xf,0x6b,0x44, + 0x7,0x5e,0x58, 0xf,0x6c,0x5f, 0x5,0x21,0x62, 0xf,0x21,0x55, + 0xf,0x21,0x56, 0x6,0x24,0x41, 0x4,0x22,0x58, 0x6,0x24,0x42, + 0xf,0x22,0x39, 0xf,0x22,0x3a, 0xf,0x22,0x3b, 0xf,0x22,0x3c, + 0x4,0x22,0x57, 0x5,0x22,0x4b, 0x6,0x24,0x43, 0x5,0x22,0x4a, + 0x6,0x26,0x74, 0x4,0x23,0x68, 0x4,0x23,0x6b, 0xf,0x23,0x64, + 0xf,0x23,0x66, 0xf,0x23,0x68, 0xf,0x23,0x69, 0xf,0x23,0x6b, + 0xf,0x23,0x6c, 0xf,0x23,0x6d, 0xf,0x23,0x6e, 0xf,0x23,0x6f, + 0xf,0x23,0x65, 0x6,0x26,0x72, 0x6,0x26,0x73, 0x6,0x26,0x75, + 0x6,0x26,0x71, 0xf,0x23,0x6a, 0xf,0x23,0x67, 0x5,0x23,0x66, + 0x5,0x23,0x67, 0x5,0x23,0x65, 0x4,0x25,0x7c, 0x6,0x2a,0x61, + 0x6,0x2a,0x60, 0x5,0x25,0x60, 0x4,0x25,0x7a, 0x5,0x25,0x5e, + 0x4,0x25,0x7d, 0x5,0x25,0x5b, 0x5,0x25,0x5c, 0x4,0x25,0x7e, + 0xf,0x26,0x3a, 0xf,0x26,0x3b, 0xf,0x26,0x3e, 0xf,0x26,0x3f, + 0xf,0x26,0x40, 0xf,0x26,0x41, 0xf,0x26,0x42, 0xf,0x26,0x43, + 0xf,0x26,0x45, 0xf,0x26,0x46, 0xf,0x26,0x47, 0xf,0x26,0x48, + 0xf,0x26,0x49, 0x6,0x2a,0x5f, 0x6,0x2a,0x5e, 0xf,0x26,0x44, + 0xf,0x26,0x3c, 0xf,0x26,0x3d, 0x5,0x25,0x62, 0x5,0x25,0x5f, + 0x5,0x25,0x63, 0x5,0x25,0x61, 0x4,0x28,0x68, 0x5,0x28,0x64, + 0x6,0x2f,0x76, 0x6,0x2f,0x78, 0x6,0x2f,0x79, 0x4,0x28,0x65, + 0x4,0x28,0x6b, 0x5,0x28,0x66, 0x4,0x28,0x66, 0x5,0x28,0x63, + 0x6,0x2f,0x70, 0x6,0x2f,0x7b, 0x6,0x2f,0x74, 0x5,0x28,0x6b, + 0x6,0x2f,0x7e, 0xf,0x2a,0x2d, 0xf,0x2a,0x2e, 0xf,0x2a,0x2f, + 0xf,0x2a,0x30, 0xf,0x2a,0x31, 0xf,0x2a,0x32, 0xf,0x2a,0x33, + 0xf,0x2a,0x34, 0x6,0x2f,0x73, 0x6,0x2f,0x77, 0x4,0x28,0x6c, + 0x6,0x2f,0x75, 0x6,0x2f,0x7a, 0x6,0x2f,0x6f, 0x6,0x2f,0x7d, + 0x5,0x28,0x69, 0x4,0x28,0x6a, 0x5,0x28,0x6a, 0x5,0x28,0x67, + 0x6,0x2f,0x71, 0x6,0x2f,0x7c, 0x5,0x28,0x65, 0x5,0x28,0x68, + 0x6,0x2f,0x72, 0x3,0x30,0x53, 0x5,0x2c,0x70, 0x6,0x36,0x4f, + 0x5,0x2c,0x72, 0x5,0x2c,0x75, 0x5,0x2c,0x6f, 0x6,0x36,0x55, + 0x5,0x2c,0x6e, 0x6,0x36,0x56, 0x6,0x36,0x50, 0x6,0x36,0x51, + 0xf,0x2e,0x6c, 0xf,0x2e,0x6e, 0xf,0x2e,0x70, 0xf,0x2e,0x71, + 0xf,0x2e,0x73, 0xf,0x2e,0x74, 0xf,0x2e,0x75, 0xf,0x2e,0x76, + 0xf,0x2e,0x77, 0xf,0x2e,0x79, 0x6,0x36,0x54, 0x6,0x36,0x4e, + 0x5,0x2c,0x71, 0x6,0x36,0x53, 0x6,0x36,0x52, 0xf,0x2e,0x6f, + 0xf,0x2e,0x72, 0x5,0x2c,0x77, 0x5,0x2c,0x74, 0x5,0x2c,0x73, + 0x5,0x2c,0x76, 0x5,0x2c,0x78, 0x6,0x3e,0x4c, 0x6,0x3e,0x52, + 0x6,0x3e,0x46, 0x6,0x3e,0x47, 0x5,0x31,0x6a, 0x6,0x3e,0x48, + 0x6,0x3e,0x49, 0x6,0x3e,0x4f, 0x5,0x31,0x69, 0x5,0x31,0x6d, + 0x6,0x3e,0x4d, 0x4,0x31,0x2b, 0x6,0x3e,0x4e, 0x5,0x31,0x6b, + 0x6,0x3e,0x53, 0xf,0x33,0x68, 0xf,0x33,0x69, 0xf,0x33,0x6a, + 0xf,0x33,0x6b, 0xf,0x33,0x6c, 0xf,0x33,0x6d, 0xf,0x33,0x6e, + 0xf,0x33,0x6f, 0xf,0x33,0x71, 0xf,0x33,0x72, 0xf,0x33,0x74, + 0xf,0x33,0x75, 0xf,0x33,0x76, 0xf,0x33,0x77, 0xf,0x33,0x78, + 0xf,0x33,0x79, 0xf,0x33,0x7a, 0xf,0x33,0x7b, 0xf,0x33,0x7c, + 0xf,0x33,0x7d, 0xf,0x33,0x7e, 0xf,0x34,0x21, 0xf,0x34,0x22, + 0xf,0x34,0x23, 0xf,0x33,0x70, 0x6,0x3e,0x51, 0x4,0x31,0x2a, + 0x6,0x3e,0x4b, 0x6,0x3e,0x4a, 0x5,0x31,0x66, 0x5,0x31,0x67, + 0x5,0x31,0x68, 0x5,0x31,0x65, 0x4,0x36,0x7b, 0x6,0x47,0x62, + 0x4,0x36,0x7c, 0x5,0x37,0x5a, 0x6,0x47,0x5f, 0x4,0x37,0x21, + 0x5,0x37,0x48, 0x5,0x37,0x59, 0x6,0x47,0x64, 0x6,0x47,0x66, + 0x5,0x37,0x4f, 0x6,0x47,0x65, 0x6,0x47,0x60, 0x5,0x37,0x50, + 0x5,0x37,0x49, 0x5,0x37,0x57, 0x5,0x37,0x54, 0x5,0x37,0x47, + 0x5,0x37,0x4b, 0xf,0x3a,0x29, 0xf,0x3a,0x2b, 0xf,0x3a,0x2c, + 0xf,0x3a,0x2d, 0xf,0x3a,0x2e, 0xf,0x3a,0x2f, 0xf,0x3a,0x30, + 0xf,0x3a,0x32, 0xf,0x3a,0x33, 0xf,0x3a,0x34, 0xf,0x3a,0x36, + 0xf,0x3a,0x37, 0xf,0x3a,0x38, 0xf,0x3a,0x39, 0xf,0x3a,0x3a, + 0xf,0x3a,0x3e, 0xf,0x3a,0x3f, 0xf,0x3a,0x41, 0xf,0x3a,0x42, + 0xf,0x3a,0x43, 0xf,0x3a,0x44, 0xf,0x3a,0x45, 0xf,0x3a,0x3b, + 0x5,0x37,0x56, 0x6,0x47,0x63, 0x5,0x37,0x58, 0x6,0x47,0x5e, + 0xf,0x3a,0x3d, 0xf,0x3a,0x40, 0xf,0x3a,0x31, 0xf,0x3a,0x2a, + 0x5,0x37,0x45, 0x5,0x3e,0x56, 0x5,0x37,0x53, 0x5,0x37,0x4c, + 0x5,0x37,0x52, 0x5,0x37,0x51, 0x5,0x37,0x4a, 0x5,0x37,0x4d, + 0x5,0x37,0x55, 0x6,0x47,0x67, 0xf,0x33,0x67, 0x5,0x3e,0x5f, + 0x5,0x3e,0x5a, 0x5,0x3e,0x5d, 0x5,0x3e,0x57, 0x4,0x3c,0x65, + 0x5,0x3e,0x59, 0x6,0x51,0x63, 0x4,0x3c,0x62, 0x4,0x3c,0x60, + 0x6,0x51,0x67, 0x6,0x51,0x65, 0x6,0x5b,0x7c, 0x5,0x3e,0x5c, + 0x5,0x3e,0x5b, 0x6,0x51,0x66, 0xf,0x40,0x78, 0xf,0x40,0x79, + 0xf,0x40,0x7a, 0xf,0x40,0x7c, 0xf,0x40,0x7d, 0xf,0x40,0x7e, + 0xf,0x41,0x22, 0xf,0x41,0x23, 0x6,0x51,0x62, 0x6,0x51,0x64, + 0xf,0x40,0x77, 0x6,0x51,0x68, 0x5,0x3e,0x58, 0x5,0x3e,0x5e, + 0x5,0x3e,0x60, 0x6,0x51,0x6a, 0xf,0x41,0x21, 0x4,0x42,0x70, + 0x5,0x45,0x32, 0x4,0x42,0x6a, 0x6,0x5b,0x7b, 0x4,0x42,0x71, + 0x6,0x5b,0x73, 0x5,0x45,0x34, 0x7,0x22,0x29, 0x4,0x42,0x73, + 0x6,0x5b,0x75, 0xf,0x47,0x48, 0x4,0x42,0x6f, 0x5,0x45,0x37, + 0x4,0x42,0x6e, 0xf,0x47,0x47, 0xf,0x47,0x49, 0xf,0x47,0x4a, + 0xf,0x47,0x4b, 0xf,0x47,0x4c, 0xf,0x47,0x4d, 0xf,0x47,0x4e, + 0xf,0x47,0x4f, 0xf,0x47,0x50, 0xf,0x47,0x51, 0xf,0x47,0x52, + 0xf,0x47,0x54, 0x6,0x5b,0x74, 0x6,0x5b,0x78, 0x4,0x42,0x72, + 0x4,0x42,0x65, 0x6,0x5b,0x76, 0xf,0x47,0x53, 0x5,0x45,0x33, + 0x5,0x45,0x36, 0x5,0x45,0x35, 0x7,0x22,0x26, 0x5,0x45,0x31, + 0x6,0x5b,0x77, 0x5,0x4c,0x5b, 0x5,0x4c,0x59, 0x4,0x49,0x39, + 0x5,0x4c,0x56, 0x7,0x22,0x2f, 0x5,0x4c,0x57, 0x4,0x49,0x3f, + 0x4,0x49,0x3b, 0x7,0x22,0x2c, 0x4,0x49,0x3e, 0x7,0x22,0x25, + 0x6,0x5b,0x79, 0x7,0x22,0x24, 0xf,0x4e,0x3a, 0x7,0x37,0x51, + 0xf,0x47,0x45, 0x5,0x4c,0x54, 0x5,0x4c,0x5c, 0xf,0x4e,0x33, + 0xf,0x4e,0x34, 0xf,0x4e,0x35, 0xf,0x4e,0x36, 0xf,0x4e,0x37, + 0xf,0x4e,0x38, 0xf,0x4e,0x39, 0xf,0x4e,0x3b, 0xf,0x4e,0x3d, + 0xf,0x4e,0x3e, 0xf,0x4e,0x3f, 0xf,0x4e,0x40, 0xf,0x4e,0x41, + 0xf,0x4e,0x42, 0xf,0x4e,0x44, 0x6,0x5b,0x7a, 0x7,0x22,0x27, + 0x7,0x22,0x2e, 0x7,0x22,0x2d, 0x7,0x22,0x28, 0x7,0x22,0x23, + 0xf,0x4e,0x45, 0xf,0x4e,0x43, 0xf,0x4e,0x3c, 0x5,0x4c,0x5a, + 0x5,0x4c,0x55, 0x4,0x49,0x3d, 0x7,0x22,0x2a, 0x5,0x4c,0x58, + 0x7,0x22,0x2b, 0xf,0x54,0x25, 0x5,0x54,0x28, 0x5,0x54,0x23, + 0x7,0x2d,0x25, 0x7,0x2c,0x7e, 0x5,0x54,0x29, 0x5,0x54,0x26, + 0x7,0x2d,0x21, 0x4,0x4f,0x7e, 0x7,0x2d,0x28, 0x5,0x54,0x22, + 0x7,0x2d,0x2b, 0x5,0x53,0x7d, 0x7,0x2d,0x2a, 0x7,0x2d,0x2c, + 0xf,0x53,0x7b, 0xf,0x53,0x7c, 0xf,0x53,0x7d, 0xf,0x53,0x7e, + 0xf,0x54,0x22, 0xf,0x54,0x23, 0xf,0x54,0x24, 0xf,0x54,0x26, + 0xf,0x54,0x27, 0xf,0x54,0x2b, 0xf,0x54,0x2c, 0x5,0x53,0x7e, + 0x7,0x2d,0x26, 0x7,0x2d,0x27, 0x7,0x2d,0x23, 0x7,0x2d,0x22, + 0x7,0x2d,0x24, 0xf,0x54,0x21, 0xf,0x54,0x28, 0x5,0x54,0x27, + 0x5,0x54,0x21, 0x5,0x54,0x25, 0x7,0x2d,0x29, 0x7,0x37,0x4b, + 0x7,0x37,0x54, 0x7,0x37,0x4f, 0x4,0x4f,0x7d, 0x7,0x37,0x4d, + 0x4,0x56,0x23, 0x7,0x37,0x53, 0x7,0x37,0x4a, 0x5,0x5b,0x36, + 0x5,0x5b,0x34, 0x7,0x37,0x4c, 0x7,0x37,0x4e, 0x7,0x37,0x50, + 0x5,0x5b,0x35, 0x4,0x56,0x25, 0xf,0x59,0x6c, 0xf,0x59,0x6d, + 0xf,0x59,0x6e, 0xf,0x59,0x6f, 0xf,0x59,0x70, 0xf,0x59,0x71, + 0x7,0x37,0x52, 0x7,0x37,0x55, 0x7,0x37,0x49, 0x5,0x61,0x4b, + 0x4,0x5a,0x7c, 0x7,0x3f,0x3f, 0x5,0x61,0x4c, 0x5,0x61,0x4d, + 0x7,0x3f,0x3e, 0x7,0x3f,0x40, 0xf,0x5e,0x50, 0xf,0x5e,0x51, + 0xf,0x5e,0x52, 0xf,0x5e,0x54, 0x7,0x3f,0x3d, 0x7,0x3f,0x41, + 0xf,0x5e,0x53, 0x7,0x3f,0x3c, 0x5,0x67,0x5f, 0x4,0x5f,0x53, + 0x7,0x46,0x4d, 0x7,0x46,0x52, 0x7,0x46,0x50, 0xf,0x5e,0x55, + 0xf,0x62,0x2a, 0xf,0x62,0x2b, 0x7,0x46,0x4e, 0x5,0x67,0x61, + 0x5,0x67,0x60, 0xf,0x5f,0x73, 0x7,0x4d,0x51, 0x5,0x6b,0x79, + 0xf,0x65,0x26, 0x5,0x6b,0x7a, 0x5,0x6b,0x7b, 0x7,0x53,0x2a, + 0x5,0x6f,0x76, 0x7,0x53,0x2b, 0x5,0x6f,0x75, 0xf,0x67,0x4d, + 0xf,0x67,0x4e, 0x7,0x57,0x62, 0x5,0x73,0x36, 0x7,0x57,0x61, + 0x7,0x57,0x63, 0x7,0x57,0x5f, 0xf,0x69,0x3f, 0x7,0x57,0x60, + 0x7,0x57,0x64, 0xf,0x69,0x40, 0x5,0x75,0x69, 0x7,0x5b,0x4c, + 0x7,0x5e,0x5a, 0x7,0x5e,0x5b, 0xf,0x6b,0x45, 0x7,0x5e,0x59, + 0x7,0x5e,0x5c, 0xf,0x6c,0x24, 0x5,0x79,0x24, 0xf,0x6c,0x4a, + 0x7,0x63,0x4d, 0x5,0x7a,0x65, 0x4,0x21,0x33, 0x6,0x22,0x68, + 0x5,0x21,0x63, 0x6,0x22,0x69, 0xf,0x21,0x58, 0xf,0x21,0x57, + 0x6,0x24,0x45, 0x6,0x24,0x44, 0x6,0x26,0x76, 0x6,0x26,0x77, + 0x5,0x23,0x6a, 0x4,0x23,0x6c, 0xf,0x23,0x70, 0x5,0x23,0x69, + 0x4,0x28,0x6f, 0x6,0x30,0x24, 0x6,0x2a,0x63, 0x6,0x2a,0x62, + 0xf,0x26,0x4a, 0xf,0x26,0x4b, 0xf,0x26,0x4c, 0xf,0x26,0x4d, + 0xf,0x26,0x4f, 0x6,0x2a,0x64, 0xf,0x26,0x4e, 0x6,0x30,0x23, + 0x6,0x30,0x21, 0x6,0x30,0x26, 0x6,0x30,0x25, 0xf,0x2a,0x35, + 0xf,0x2a,0x36, 0xf,0x2a,0x37, 0x6,0x30,0x22, 0x6,0x36,0x59, + 0x5,0x2c,0x79, 0x6,0x36,0x58, 0xf,0x2e,0x7a, 0xf,0x2e,0x7b, + 0x5,0x2c,0x7a, 0xf,0x33,0x66, 0xf,0x34,0x24, 0xf,0x34,0x25, + 0xf,0x34,0x26, 0xf,0x34,0x27, 0x5,0x37,0x5c, 0x6,0x47,0x69, + 0x5,0x37,0x5b, 0x6,0x47,0x6a, 0xf,0x3a,0x47, 0x6,0x47,0x68, + 0xf,0x3a,0x46, 0x4,0x3c,0x66, 0x4,0x3c,0x68, 0x6,0x51,0x6d, + 0x5,0x3e,0x62, 0xf,0x41,0x25, 0xf,0x41,0x26, 0x6,0x51,0x6b, + 0x6,0x51,0x6c, 0x5,0x3e,0x61, 0x4,0x3c,0x69, 0x6,0x5b,0x7d, + 0xf,0x47,0x55, 0xf,0x47,0x56, 0x5,0x45,0x38, 0x4,0x49,0x41, + 0x4,0x49,0x42, 0xf,0x4e,0x46, 0x5,0x4c,0x5d, 0x7,0x2d,0x2f, + 0x7,0x2d,0x2e, 0x7,0x2d,0x31, 0x7,0x2d,0x32, 0x5,0x54,0x2a, + 0x7,0x2d,0x30, 0xf,0x54,0x2d, 0xf,0x54,0x2e, 0x7,0x37,0x56, + 0x7,0x4d,0x52, 0xf,0x62,0x2c, 0xf,0x62,0x2d, 0x5,0x6b,0x7c, + 0xf,0x6c,0x60, 0x6,0x21,0x69, 0x5,0x21,0x64, 0x6,0x24,0x46, + 0x6,0x24,0x49, 0x6,0x24,0x4a, 0x4,0x22,0x5a, 0xf,0x22,0x3d, + 0xf,0x22,0x3e, 0xf,0x22,0x3f, 0xf,0x22,0x40, 0xf,0x22,0x41, + 0x6,0x24,0x47, 0x6,0x26,0x7e, 0x6,0x26,0x7d, 0x4,0x23,0x6e, + 0x6,0x26,0x7b, 0x6,0x26,0x7c, 0xf,0x23,0x72, 0x5,0x25,0x65, + 0x5,0x25,0x64, 0x6,0x2a,0x66, 0x5,0x25,0x66, 0x6,0x2a,0x67, + 0x6,0x2a,0x68, 0xf,0x26,0x51, 0xf,0x26,0x52, 0xf,0x26,0x54, + 0xf,0x26,0x55, 0x6,0x2a,0x65, 0xf,0x26,0x53, 0x5,0x28,0x6c, + 0x6,0x30,0x28, 0x6,0x30,0x2a, 0x5,0x28,0x6d, 0x4,0x28,0x71, + 0x4,0x28,0x72, 0x4,0x28,0x73, 0x6,0x30,0x2b, 0x6,0x30,0x27, + 0x6,0x30,0x29, 0xf,0x2a,0x38, 0xf,0x2a,0x3a, 0xf,0x2a,0x3b, + 0xf,0x2a,0x3c, 0x6,0x30,0x2c, 0x6,0x30,0x2d, 0x4,0x2c,0x4a, + 0x6,0x36,0x61, 0x4,0x2c,0x45, 0x4,0x2c,0x44, 0x4,0x2c,0x43, + 0x4,0x2c,0x47, 0x6,0x36,0x64, 0x6,0x36,0x65, 0x6,0x36,0x5f, + 0x6,0x36,0x5e, 0x5,0x2c,0x7d, 0x5,0x2d,0x22, 0x6,0x36,0x5b, + 0x6,0x36,0x62, 0xf,0x2e,0x7c, 0xf,0x2e,0x7d, 0x6,0x36,0x60, + 0x6,0x36,0x63, 0x6,0x36,0x5a, 0x6,0x36,0x5c, 0x5,0x2d,0x21, + 0x5,0x2c,0x7e, 0x4,0x31,0x2d, 0x5,0x31,0x6f, 0x6,0x3e,0x57, + 0x6,0x3e,0x59, 0x6,0x3e,0x58, 0x6,0x3e,0x56, 0x6,0x3e,0x5b, + 0x5,0x31,0x70, 0xf,0x34,0x28, 0xf,0x34,0x29, 0xf,0x34,0x2a, + 0xf,0x34,0x2b, 0xf,0x34,0x2c, 0xf,0x34,0x2d, 0xf,0x34,0x2e, + 0xf,0x34,0x2f, 0x4,0x31,0x2f, 0x6,0x3e,0x5c, 0x5,0x31,0x6e, + 0x6,0x3e,0x55, 0x5,0x37,0x5e, 0x4,0x37,0x26, 0x5,0x37,0x61, + 0x6,0x47,0x70, 0x6,0x47,0x6b, 0x4,0x37,0x23, 0x5,0x37,0x5d, + 0x5,0x37,0x60, 0x6,0x47,0x6e, 0x4,0x37,0x25, 0x5,0x37,0x5f, + 0x6,0x47,0x6f, 0x6,0x47,0x6c, 0xf,0x3a,0x48, 0xf,0x3a,0x49, + 0xf,0x3a,0x4a, 0xf,0x3a,0x4b, 0xf,0x3a,0x4c, 0xf,0x3a,0x4d, + 0xf,0x3a,0x4e, 0xf,0x3a,0x4f, 0x6,0x47,0x6d, 0x5,0x37,0x62, + 0xf,0x3d,0x6c, 0x6,0x51,0x74, 0x6,0x51,0x70, 0x4,0x3c,0x6b, + 0x4,0x3c,0x70, 0x5,0x3e,0x63, 0x6,0x51,0x77, 0x5,0x3e,0x64, + 0x6,0x51,0x72, 0x6,0x51,0x71, 0x6,0x51,0x76, 0x4,0x3c,0x6d, + 0x6,0x51,0x73, 0x6,0x51,0x6f, 0x6,0x51,0x75, 0xf,0x41,0x27, + 0xf,0x41,0x28, 0xf,0x41,0x29, 0xf,0x41,0x2a, 0xf,0x41,0x2c, + 0xf,0x41,0x2d, 0xf,0x41,0x2e, 0x6,0x51,0x6e, 0x6,0x5b,0x7e, + 0x6,0x5c,0x27, 0x5,0x45,0x3c, 0x5,0x45,0x3a, 0x6,0x5c,0x24, + 0x6,0x5c,0x2c, 0x4,0x42,0x76, 0x6,0x5c,0x2e, 0x6,0x5c,0x2b, + 0x6,0x5c,0x26, 0x5,0x45,0x39, 0x7,0x22,0x33, 0xf,0x47,0x57, + 0xf,0x47,0x58, 0xf,0x47,0x59, 0xf,0x47,0x5a, 0x6,0x5c,0x28, + 0x6,0x5c,0x25, 0x6,0x5c,0x29, 0x6,0x5c,0x2d, 0x6,0x5c,0x21, + 0x6,0x5c,0x23, 0x5,0x45,0x3b, 0x6,0x5c,0x2a, 0xf,0x47,0x44, + 0x6,0x62,0x67, 0x7,0x22,0x30, 0x5,0x4c,0x5e, 0x4,0x49,0x47, + 0x7,0x22,0x37, 0x4,0x49,0x48, 0x7,0x22,0x35, 0x7,0x22,0x32, + 0xf,0x4e,0x47, 0xf,0x4e,0x48, 0xf,0x4e,0x49, 0xf,0x4e,0x4a, + 0xf,0x4e,0x4b, 0xf,0x4e,0x4c, 0xf,0x4e,0x4e, 0xf,0x4e,0x4f, + 0x7,0x22,0x38, 0x7,0x22,0x36, 0xf,0x4e,0x4d, 0x5,0x4c,0x61, + 0x5,0x4c,0x5f, 0x7,0x22,0x31, 0x5,0x4c,0x60, 0x7,0x2d,0x35, + 0x7,0x2d,0x37, 0x5,0x54,0x2c, 0x4,0x50,0x22, 0x5,0x54,0x2d, + 0x5,0x54,0x2b, 0x7,0x2d,0x36, 0x7,0x2d,0x33, 0x7,0x2d,0x34, + 0xf,0x54,0x2f, 0xf,0x54,0x30, 0xf,0x54,0x31, 0xf,0x54,0x33, + 0xf,0x54,0x34, 0xf,0x54,0x35, 0xf,0x54,0x36, 0xf,0x54,0x37, + 0x7,0x37,0x59, 0x7,0x37,0x57, 0x5,0x5b,0x38, 0xf,0x59,0x72, + 0xf,0x59,0x73, 0xf,0x59,0x74, 0xf,0x59,0x75, 0x7,0x37,0x58, + 0x7,0x37,0x5a, 0x7,0x22,0x34, 0x5,0x5b,0x37, 0x7,0x46,0x58, + 0x5,0x61,0x4e, 0xf,0x59,0x76, 0xf,0x5e,0x56, 0xf,0x5e,0x57, + 0x7,0x3f,0x42, 0xf,0x62,0x2e, 0x4,0x5f,0x57, 0x7,0x46,0x53, + 0x7,0x46,0x55, 0x4,0x5f,0x56, 0x7,0x46,0x57, 0x7,0x46,0x56, + 0xf,0x62,0x2f, 0x7,0x46,0x54, 0x4,0x63,0x36, 0x7,0x4d,0x53, + 0x7,0x53,0x2c, 0x4,0x66,0x38, 0x7,0x53,0x2d, 0xf,0x67,0x4f, + 0xf,0x67,0x50, 0x7,0x53,0x2e, 0x5,0x73,0x38, 0x4,0x68,0x66, + 0x7,0x57,0x65, 0x5,0x73,0x37, 0x7,0x57,0x66, 0x4,0x6a,0x45, + 0x4,0x6b,0x67, 0xf,0x6b,0x46, 0x7,0x60,0x6c, 0x7,0x64,0x45, + 0x5,0x79,0x25, 0xf,0x6c,0x25, 0x4,0x6d,0x54, 0x5,0x7a,0x27, + 0x4,0x6d,0x71, 0x7,0x63,0x4e, 0x7,0x65,0x34, 0x6,0x21,0x6a, + 0x6,0x2a,0x6a, 0x6,0x2a,0x69, 0xf,0x26,0x56, 0xf,0x26,0x57, + 0x5,0x28,0x6f, 0x6,0x30,0x2e, 0xf,0x2a,0x3d, 0x6,0x30,0x31, + 0x6,0x30,0x2f, 0x4,0x31,0x31, 0x6,0x43,0x67, 0x6,0x3e,0x5e, + 0x6,0x3e,0x5d, 0x4,0x37,0x27, 0x6,0x3e,0x5f, 0x6,0x51,0x7a, + 0x6,0x51,0x78, 0x6,0x51,0x79, 0x6,0x5c,0x30, 0x4,0x44,0x26, + 0xf,0x47,0x5b, 0x6,0x5c,0x31, 0x5,0x45,0x3d, 0xf,0x4e,0x51, + 0x7,0x22,0x3a, 0x7,0x22,0x39, 0x7,0x2d,0x39, 0x5,0x53,0x52, + 0x7,0x2d,0x38, 0x7,0x37,0x5b, 0x7,0x37,0x5c, 0x5,0x61,0x4f, + 0x7,0x46,0x59, 0x7,0x4d,0x54, 0x7,0x53,0x2f, 0x6,0x21,0x6b, + 0xf,0x21,0x39, 0x6,0x24,0x4c, 0x5,0x22,0x4c, 0x6,0x27,0x24, + 0x4,0x23,0x72, 0x6,0x27,0x23, 0x6,0x27,0x22, 0xf,0x23,0x73, + 0x5,0x25,0x67, 0xf,0x26,0x58, 0x6,0x2a,0x6b, 0x6,0x30,0x32, + 0x6,0x30,0x30, 0x6,0x30,0x33, 0x5,0x28,0x70, 0x4,0x2c,0x4b, + 0xf,0x2f,0x21, 0x6,0x36,0x69, 0x6,0x3e,0x61, 0x5,0x31,0x71, + 0x5,0x37,0x63, 0x6,0x3e,0x63, 0x6,0x3e,0x60, 0x6,0x3e,0x62, + 0xf,0x34,0x30, 0x6,0x47,0x71, 0xf,0x3a,0x50, 0x6,0x47,0x73, + 0x6,0x47,0x72, 0x5,0x3e,0x65, 0xf,0x41,0x2f, 0x5,0x45,0x3e, + 0x6,0x5c,0x33, 0x6,0x5c,0x32, 0x5,0x4c,0x62, 0x7,0x22,0x3b, + 0x5,0x54,0x2f, 0x7,0x2d,0x3a, 0xf,0x59,0x77, 0x5,0x61,0x50, + 0x5,0x6f,0x77, 0x4,0x21,0x4a, 0xf,0x21,0x3a, 0x5,0x21,0x65, + 0xf,0x21,0x4d, 0xf,0x21,0x5a, 0x6,0x22,0x6b, 0x6,0x22,0x6a, + 0x5,0x22,0x4d, 0xf,0x22,0x43, 0x5,0x23,0x6c, 0x4,0x23,0x73, + 0x5,0x25,0x68, 0x6,0x27,0x25, 0x5,0x23,0x6b, 0x5,0x23,0x6e, + 0x5,0x23,0x6d, 0x6,0x30,0x34, 0x5,0x25,0x69, 0x6,0x2a,0x6c, + 0x5,0x25,0x6b, 0xf,0x26,0x59, 0x6,0x30,0x35, 0x5,0x25,0x6a, + 0x5,0x28,0x71, 0x6,0x30,0x37, 0x6,0x30,0x38, 0x5,0x28,0x72, + 0x6,0x30,0x39, 0x5,0x2d,0x23, 0x6,0x36,0x6c, 0x6,0x36,0x6a, + 0x5,0x2d,0x24, 0x6,0x36,0x6b, 0x6,0x36,0x6d, 0xf,0x2f,0x22, + 0x6,0x3e,0x66, 0x5,0x31,0x72, 0x4,0x31,0x34, 0x5,0x31,0x74, + 0x6,0x47,0x76, 0x6,0x47,0x74, 0x6,0x47,0x75, 0x4,0x37,0x2a, + 0x6,0x47,0x77, 0xf,0x3a,0x51, 0x6,0x51,0x7b, 0x6,0x51,0x7d, + 0x6,0x51,0x7c, 0x5,0x48,0x26, 0x4,0x42,0x7a, 0x6,0x5c,0x34, + 0x5,0x45,0x40, 0x5,0x45,0x3f, 0x6,0x5c,0x35, 0x5,0x45,0x41, + 0x7,0x2d,0x3d, 0x7,0x22,0x3e, 0x7,0x22,0x3d, 0x7,0x22,0x3c, + 0x7,0x2d,0x3b, 0x5,0x54,0x30, 0x7,0x2d,0x3c, 0x7,0x2d,0x3e, + 0xf,0x54,0x38, 0x7,0x37,0x5d, 0x4,0x66,0x39, 0x4,0x68,0x67, + 0x5,0x79,0x26, 0x6,0x21,0x3e, 0x4,0x21,0x75, 0x4,0x21,0x74, + 0x6,0x22,0x6c, 0x6,0x24,0x4d, 0x4,0x22,0x5e, 0x5,0x22,0x4e, + 0x6,0x24,0x4e, 0x6,0x24,0x50, 0x6,0x24,0x51, 0x6,0x24,0x4f, + 0xf,0x22,0x44, 0x6,0x27,0x29, 0xf,0x23,0x74, 0x6,0x27,0x27, + 0x6,0x27,0x26, 0x6,0x27,0x28, 0x5,0x23,0x6f, 0x4,0x26,0x2c, + 0x4,0x26,0x2b, 0x6,0x2a,0x6d, 0x6,0x2a,0x6e, 0x5,0x25,0x6c, + 0x6,0x2a,0x6f, 0xf,0x26,0x5b, 0x5,0x25,0x6d, 0x4,0x28,0x77, + 0x6,0x30,0x3a, 0x6,0x30,0x3f, 0x4,0x28,0x7a, 0x4,0x28,0x76, + 0x5,0x28,0x75, 0x6,0x30,0x3e, 0x6,0x30,0x3d, 0x6,0x30,0x3c, + 0x6,0x30,0x3b, 0xf,0x2a,0x40, 0xf,0x2a,0x41, 0xf,0x2a,0x42, + 0xf,0x2a,0x43, 0xf,0x2a,0x44, 0xf,0x2a,0x3f, 0x6,0x30,0x40, + 0x5,0x28,0x74, 0x6,0x36,0x72, 0x4,0x2c,0x50, 0x6,0x36,0x6f, + 0x4,0x2c,0x4f, 0x6,0x3e,0x67, 0x6,0x36,0x70, 0x6,0x36,0x6e, + 0xf,0x2f,0x23, 0xf,0x2f,0x24, 0xf,0x2f,0x26, 0xf,0x2f,0x27, + 0xf,0x2f,0x28, 0x5,0x2d,0x26, 0x5,0x2d,0x27, 0x6,0x36,0x71, + 0x6,0x36,0x73, 0x5,0x2d,0x25, 0x6,0x36,0x74, 0x6,0x3e,0x6d, + 0x6,0x3e,0x69, 0x5,0x31,0x78, 0x5,0x31,0x7a, 0x5,0x31,0x77, + 0x5,0x31,0x79, 0x5,0x31,0x76, 0x5,0x31,0x7b, 0x6,0x3e,0x70, + 0x6,0x3e,0x6a, 0xf,0x34,0x31, 0xf,0x34,0x32, 0xf,0x34,0x35, + 0xf,0x34,0x36, 0xf,0x34,0x37, 0xf,0x34,0x38, 0xf,0x34,0x39, + 0xf,0x34,0x3a, 0x6,0x3e,0x68, 0x6,0x3e,0x6c, 0x6,0x3e,0x6f, + 0x6,0x3e,0x6e, 0xf,0x34,0x33, 0x6,0x48,0x23, 0x6,0x48,0x24, + 0x6,0x48,0x22, 0x4,0x37,0x2c, 0x6,0x47,0x7e, 0x6,0x47,0x7a, + 0x5,0x37,0x64, 0x4,0x37,0x2d, 0x5,0x37,0x65, 0x6,0x47,0x79, + 0x6,0x47,0x78, 0x6,0x48,0x25, 0x6,0x48,0x21, 0x6,0x48,0x26, + 0x6,0x47,0x7c, 0xf,0x3a,0x52, 0xf,0x3a,0x53, 0xf,0x3a,0x54, + 0x6,0x47,0x7d, 0x4,0x37,0x2e, 0x6,0x52,0x23, 0x5,0x3e,0x69, + 0x5,0x3e,0x67, 0x6,0x52,0x26, 0x5,0x3e,0x68, 0x6,0x52,0x25, + 0x6,0x52,0x29, 0x6,0x52,0x21, 0x6,0x51,0x7e, 0x6,0x52,0x27, + 0x6,0x52,0x24, 0xf,0x41,0x30, 0xf,0x41,0x31, 0xf,0x41,0x32, + 0x6,0x52,0x22, 0x6,0x52,0x28, 0x5,0x3e,0x66, 0x4,0x42,0x7c, + 0x4,0x42,0x7e, 0x4,0x42,0x7b, 0x6,0x5c,0x38, 0x6,0x5c,0x36, + 0x6,0x5c,0x37, 0xf,0x47,0x5d, 0x6,0x5c,0x39, 0x5,0x45,0x42, + 0x7,0x22,0x40, 0x5,0x4c,0x66, 0xf,0x4e,0x52, 0xf,0x4e,0x53, + 0xf,0x4e,0x54, 0xf,0x4e,0x55, 0xf,0x4e,0x56, 0x5,0x4c,0x65, + 0x5,0x4c,0x64, 0x7,0x2d,0x40, 0x7,0x2d,0x3f, 0x7,0x22,0x3f, + 0xf,0x54,0x39, 0x7,0x30,0x2d, 0x7,0x37,0x5e, 0x7,0x3f,0x43, + 0x4,0x5f,0x58, 0x5,0x67,0x62, 0xf,0x65,0x27, 0xf,0x65,0x28, + 0x5,0x6b,0x7d, 0xf,0x67,0x51, 0x5,0x73,0x3a, 0x5,0x21,0x30, + 0x6,0x21,0x6c, 0x6,0x22,0x6d, 0x6,0x24,0x54, 0x6,0x24,0x53, + 0x6,0x24,0x52, 0x5,0x22,0x4f, 0x4,0x23,0x75, 0x6,0x27,0x2a, + 0x4,0x26,0x2d, 0x6,0x2a,0x71, 0x6,0x2a,0x70, 0x5,0x28,0x77, + 0x6,0x30,0x42, 0x6,0x30,0x43, 0x5,0x28,0x76, 0x6,0x30,0x44, + 0x6,0x36,0x77, 0x6,0x36,0x78, 0x6,0x36,0x76, 0x6,0x35,0x28, + 0x6,0x36,0x75, 0x6,0x3e,0x71, 0x6,0x3e,0x72, 0x6,0x48,0x28, + 0x5,0x37,0x67, 0x6,0x48,0x29, 0x6,0x48,0x27, 0xf,0x3a,0x55, + 0x6,0x52,0x2a, 0x6,0x5c,0x3a, 0x7,0x22,0x41, 0x7,0x2d,0x41, + 0x7,0x22,0x42, 0x7,0x22,0x43, 0x7,0x53,0x30, 0x7,0x5e,0x5d, + 0x5,0x21,0x45, 0x5,0x21,0x46, 0x6,0x22,0x70, 0x6,0x22,0x6e, + 0x6,0x22,0x72, 0x6,0x22,0x71, 0xf,0x21,0x5c, 0xf,0x21,0x5d, + 0xf,0x21,0x5e, 0x6,0x22,0x73, 0x5,0x21,0x66, 0x6,0x22,0x6f, + 0x6,0x24,0x57, 0x6,0x24,0x55, 0x6,0x24,0x59, 0x3,0x23,0x59, + 0xf,0x22,0x45, 0xf,0x22,0x46, 0x6,0x24,0x56, 0x5,0x22,0x53, + 0x6,0x24,0x5a, 0x6,0x24,0x58, 0x5,0x22,0x52, 0x6,0x27,0x2e, + 0x5,0x23,0x71, 0x5,0x23,0x78, 0x5,0x23,0x79, 0x6,0x27,0x30, + 0x5,0x23,0x76, 0x5,0x23,0x75, 0x5,0x23,0x77, 0x5,0x23,0x72, + 0x5,0x23,0x73, 0x6,0x27,0x31, 0x6,0x27,0x2c, 0x6,0x27,0x32, + 0xf,0x23,0x76, 0xf,0x23,0x77, 0xf,0x23,0x79, 0xf,0x23,0x7a, + 0xf,0x23,0x7b, 0xf,0x23,0x7e, 0xf,0x24,0x21, 0x6,0x27,0x2d, + 0x6,0x27,0x2f, 0x4,0x23,0x7d, 0xf,0x23,0x7d, 0x6,0x27,0x34, + 0x6,0x27,0x33, 0x4,0x23,0x7c, 0x6,0x27,0x2b, 0x5,0x23,0x7a, + 0x4,0x26,0x30, 0x5,0x25,0x75, 0x6,0x2a,0x75, 0x4,0x26,0x33, + 0x6,0x2a,0x72, 0x5,0x25,0x73, 0x5,0x25,0x74, 0x6,0x2a,0x7a, + 0x5,0x25,0x71, 0x6,0x2a,0x77, 0x6,0x2a,0x7c, 0x5,0x25,0x6f, + 0x6,0x2a,0x79, 0x5,0x25,0x72, 0x5,0x25,0x70, 0x6,0x2a,0x74, + 0x6,0x27,0x35, 0xf,0x26,0x5c, 0xf,0x26,0x5d, 0xf,0x26,0x5e, + 0xf,0x26,0x5f, 0xf,0x26,0x60, 0xf,0x26,0x61, 0xf,0x26,0x63, + 0xf,0x26,0x64, 0xf,0x26,0x65, 0xf,0x26,0x66, 0xf,0x26,0x67, + 0xf,0x26,0x68, 0x6,0x2a,0x78, 0x6,0x2d,0x2b, 0x6,0x2a,0x73, + 0x5,0x25,0x76, 0x6,0x30,0x50, 0x6,0x30,0x4a, 0x5,0x28,0x78, + 0x6,0x30,0x4b, 0x5,0x28,0x79, 0x4,0x28,0x7e, 0x5,0x28,0x7a, + 0x6,0x30,0x46, 0x6,0x30,0x49, 0x6,0x30,0x52, 0xf,0x2a,0x45, + 0xf,0x2a,0x47, 0xf,0x2a,0x48, 0xf,0x2a,0x4b, 0xf,0x2a,0x4c, + 0xf,0x2a,0x4d, 0xf,0x2a,0x4e, 0xf,0x2a,0x4f, 0xf,0x2a,0x50, + 0xf,0x2a,0x51, 0x6,0x30,0x4d, 0x6,0x30,0x45, 0x6,0x30,0x47, + 0x6,0x30,0x51, 0x6,0x30,0x4f, 0x6,0x30,0x4c, 0xf,0x2a,0x4a, + 0xf,0x2a,0x46, 0x6,0x30,0x48, 0x5,0x28,0x7b, 0x4,0x28,0x7c, + 0x5,0x2d,0x2c, 0x5,0x2d,0x29, 0x4,0x2c,0x52, 0x4,0x2c,0x59, + 0x5,0x2d,0x2a, 0x6,0x37,0x21, 0x4,0x2c,0x58, 0x5,0x2d,0x34, + 0x5,0x2d,0x30, 0x5,0x2d,0x2b, 0x6,0x36,0x7d, 0x5,0x2d,0x31, + 0x5,0x2d,0x2d, 0x5,0x2d,0x2f, 0x6,0x37,0x24, 0x6,0x36,0x7e, + 0x4,0x2c,0x62, 0x6,0x36,0x79, 0x4,0x2c,0x63, 0x4,0x2c,0x56, + 0x6,0x37,0x25, 0x6,0x37,0x22, 0x6,0x37,0x23, 0x6,0x36,0x7b, + 0xf,0x2f,0x29, 0xf,0x2f,0x2a, 0xf,0x2f,0x2b, 0xf,0x2f,0x2c, + 0xf,0x2f,0x2d, 0xf,0x2f,0x2e, 0xf,0x2f,0x2f, 0xf,0x2f,0x31, + 0xf,0x2f,0x33, 0x5,0x2d,0x28, 0xf,0x2f,0x30, 0xf,0x2f,0x32, + 0x5,0x2d,0x33, 0x4,0x2c,0x5d, 0x5,0x2d,0x35, 0x5,0x2d,0x36, + 0x5,0x2d,0x32, 0x6,0x3b,0x4e, 0x4,0x31,0x3a, 0x6,0x3f,0x2b, + 0x6,0x3f,0x24, 0x6,0x3f,0x26, 0x4,0x31,0x3c, 0x4,0x31,0x3e, + 0x5,0x31,0x7e, 0x6,0x3e,0x79, 0x6,0x3f,0x22, 0x6,0x3e,0x7b, + 0x5,0x32,0x28, 0x4,0x31,0x38, 0x6,0x3f,0x27, 0x6,0x3f,0x2c, + 0x6,0x3f,0x29, 0x6,0x3e,0x74, 0x6,0x3f,0x2a, 0x4,0x31,0x40, + 0x4,0x31,0x3b, 0x5,0x31,0x7c, 0x5,0x32,0x26, 0x6,0x3e,0x73, + 0x4,0x31,0x36, 0x5,0x31,0x7d, 0x5,0x32,0x24, 0x6,0x3f,0x28, + 0x6,0x3f,0x23, 0xf,0x34,0x3b, 0xf,0x34,0x3c, 0xf,0x34,0x3d, + 0xf,0x34,0x3e, 0xf,0x34,0x40, 0xf,0x34,0x41, 0xf,0x34,0x42, + 0xf,0x34,0x43, 0xf,0x34,0x44, 0xf,0x34,0x46, 0xf,0x34,0x47, + 0xf,0x34,0x48, 0x6,0x3e,0x77, 0x6,0x32,0x2a, 0x6,0x3e,0x7d, + 0x6,0x3e,0x7c, 0x6,0x3e,0x7e, 0x6,0x3f,0x21, 0x6,0x3f,0x25, + 0x4,0x31,0x3f, 0x5,0x32,0x29, 0x5,0x32,0x21, 0x5,0x32,0x27, + 0x5,0x32,0x23, 0x5,0x32,0x22, 0x5,0x32,0x25, 0x5,0x32,0x2a, + 0x5,0x37,0x69, 0x6,0x48,0x33, 0x5,0x37,0x6e, 0x6,0x48,0x2a, + 0x6,0x48,0x34, 0x5,0x37,0x6f, 0x5,0x37,0x6c, 0x5,0x37,0x6b, + 0x4,0x37,0x30, 0x5,0x37,0x70, 0x5,0x37,0x6a, 0x5,0x37,0x71, + 0x5,0x37,0x72, 0x5,0x37,0x74, 0x6,0x48,0x2e, 0x6,0x3e,0x7a, + 0x4,0x37,0x31, 0x6,0x48,0x2f, 0x5,0x37,0x6d, 0x4,0x37,0x33, + 0x5,0x37,0x68, 0x5,0x37,0x73, 0xf,0x3a,0x56, 0xf,0x3a,0x58, + 0xf,0x3a,0x59, 0xf,0x3a,0x5a, 0xf,0x3a,0x5b, 0x6,0x48,0x2d, + 0x5,0x37,0x75, 0x6,0x48,0x32, 0x6,0x48,0x2c, 0x6,0x48,0x31, + 0x6,0x48,0x30, 0xf,0x3a,0x5c, 0x5,0x3e,0x70, 0x6,0x52,0x2d, + 0x5,0x3e,0x6c, 0x4,0x3c,0x7a, 0x5,0x3e,0x71, 0x6,0x52,0x2e, + 0x6,0x5c,0x3b, 0x4,0x3c,0x7d, 0x6,0x52,0x35, 0x5,0x3e,0x6a, + 0x5,0x3e,0x73, 0x6,0x52,0x2b, 0x5,0x3e,0x6f, 0x6,0x52,0x2c, + 0x6,0x52,0x39, 0x6,0x52,0x30, 0x6,0x52,0x38, 0x5,0x3e,0x6e, + 0x6,0x52,0x36, 0x6,0x5c,0x40, 0xf,0x41,0x37, 0x5,0x3e,0x72, + 0xf,0x41,0x33, 0xf,0x41,0x34, 0xf,0x41,0x36, 0xf,0x41,0x38, + 0xf,0x41,0x39, 0x6,0x52,0x3a, 0x6,0x52,0x32, 0x6,0x52,0x37, + 0x5,0x3e,0x6b, 0xf,0x41,0x35, 0x6,0x52,0x2f, 0x5,0x45,0x43, + 0x5,0x45,0x4b, 0x5,0x45,0x49, 0x6,0x5c,0x41, 0x6,0x5c,0x3c, + 0x4,0x43,0x2b, 0x4,0x43,0x26, 0x4,0x43,0x25, 0x5,0x45,0x44, + 0x5,0x45,0x48, 0x5,0x45,0x47, 0x5,0x45,0x4a, 0x5,0x45,0x4e, + 0x6,0x5c,0x3e, 0x6,0x5c,0x47, 0x5,0x45,0x4d, 0x5,0x45,0x45, + 0x5,0x45,0x46, 0x6,0x5c,0x42, 0x4,0x43,0x29, 0x6,0x5c,0x46, + 0x4,0x43,0x27, 0x4,0x43,0x23, 0x5,0x45,0x4c, 0x6,0x5c,0x45, + 0x6,0x5c,0x43, 0x6,0x5c,0x3f, 0x4,0x43,0x28, 0xf,0x47,0x5e, + 0xf,0x47,0x5f, 0xf,0x47,0x60, 0xf,0x47,0x61, 0x6,0x52,0x31, + 0x4,0x49,0x4e, 0x7,0x22,0x49, 0x4,0x49,0x52, 0x7,0x22,0x45, + 0x5,0x4c,0x69, 0x7,0x22,0x50, 0x7,0x22,0x4a, 0x5,0x4c,0x6e, + 0x5,0x4c,0x67, 0x7,0x22,0x47, 0x7,0x22,0x51, 0x5,0x4c,0x6f, + 0x7,0x22,0x4f, 0x7,0x22,0x4c, 0x7,0x22,0x4d, 0x5,0x4c,0x70, + 0x5,0x4c,0x6a, 0x5,0x4c,0x6d, 0x7,0x2d,0x44, 0x7,0x22,0x46, + 0xf,0x4e,0x57, 0xf,0x4e,0x58, 0xf,0x4e,0x59, 0xf,0x4e,0x5b, + 0xf,0x4e,0x5c, 0x7,0x22,0x44, 0x7,0x22,0x4b, 0x7,0x22,0x4e, + 0x5,0x4c,0x6b, 0x7,0x22,0x48, 0x4,0x49,0x51, 0x5,0x54,0x33, + 0x4,0x50,0x23, 0x7,0x2d,0x4a, 0x4,0x50,0x24, 0x5,0x54,0x35, + 0x7,0x2d,0x42, 0x5,0x54,0x38, 0x5,0x54,0x34, 0x5,0x54,0x31, + 0x7,0x2d,0x47, 0x7,0x2d,0x43, 0x5,0x5b,0x39, 0x5,0x54,0x32, + 0xf,0x54,0x3a, 0xf,0x54,0x3b, 0xf,0x54,0x3c, 0x7,0x2d,0x45, + 0x7,0x2d,0x49, 0x7,0x2d,0x48, 0x7,0x2d,0x4b, 0x7,0x2d,0x46, + 0x7,0x2d,0x4d, 0x5,0x54,0x37, 0x4,0x56,0x29, 0x5,0x5b,0x3b, + 0x5,0x61,0x55, 0x7,0x37,0x60, 0x5,0x5b,0x3f, 0x7,0x37,0x66, + 0x5,0x5b,0x3a, 0x7,0x37,0x62, 0x7,0x37,0x64, 0x7,0x37,0x61, + 0x5,0x5b,0x3d, 0x7,0x37,0x5f, 0x7,0x37,0x65, 0xf,0x59,0x79, + 0xf,0x59,0x7a, 0xf,0x59,0x7b, 0x4,0x56,0x2a, 0x7,0x37,0x63, + 0x7,0x37,0x67, 0x7,0x39,0x27, 0x5,0x5b,0x40, 0x7,0x46,0x5a, + 0x5,0x61,0x54, 0x7,0x3f,0x47, 0x4,0x5a,0x7e, 0x5,0x61,0x51, + 0x5,0x61,0x52, 0x7,0x3f,0x49, 0xf,0x5e,0x59, 0x5,0x61,0x53, + 0x7,0x3f,0x46, 0xf,0x5e,0x58, 0x7,0x3f,0x45, 0x7,0x3f,0x48, + 0x5,0x61,0x56, 0x5,0x61,0x57, 0x7,0x46,0x5c, 0x4,0x5f,0x5b, + 0x7,0x46,0x5e, 0x5,0x67,0x65, 0x4,0x5f,0x59, 0x7,0x46,0x5d, + 0x7,0x46,0x5f, 0x7,0x46,0x60, 0xf,0x62,0x30, 0xf,0x62,0x31, + 0xf,0x62,0x32, 0x7,0x46,0x61, 0x7,0x46,0x62, 0x7,0x46,0x5b, + 0x4,0x63,0x38, 0x7,0x4d,0x55, 0x4,0x63,0x37, 0x5,0x6b,0x7e, + 0x7,0x4d,0x57, 0xf,0x65,0x29, 0x7,0x4d,0x56, 0x5,0x5b,0x3e, + 0x5,0x6f,0x78, 0x5,0x6f,0x7a, 0x5,0x6f,0x79, 0x7,0x53,0x32, + 0x7,0x53,0x31, 0x5,0x73,0x3b, 0x4,0x68,0x69, 0x4,0x68,0x6a, + 0x7,0x57,0x67, 0x7,0x57,0x69, 0x7,0x57,0x68, 0x7,0x57,0x6a, + 0x5,0x73,0x3c, 0x7,0x5e,0x5e, 0x4,0x6b,0x6a, 0x4,0x6b,0x69, + 0x7,0x5e,0x60, 0x5,0x77,0x58, 0x7,0x5e,0x5f, 0x5,0x79,0x27, + 0xf,0x6c,0x26, 0x5,0x7a,0x28, 0x5,0x7a,0x66, 0x5,0x7b,0x3c, + 0x7,0x63,0x4f, 0x5,0x7c,0x34, 0x6,0x21,0x6d, 0x4,0x21,0x25, + 0x4,0x22,0x62, 0x5,0x22,0x54, 0x6,0x24,0x5b, 0x6,0x24,0x5c, + 0x5,0x22,0x55, 0x6,0x23,0x7e, 0x4,0x23,0x7e, 0x5,0x23,0x7b, + 0x6,0x2a,0x7d, 0xf,0x26,0x6a, 0xf,0x26,0x69, 0x6,0x30,0x55, + 0x6,0x30,0x54, 0x6,0x30,0x56, 0x6,0x30,0x53, 0x6,0x37,0x26, + 0x5,0x32,0x2b, 0x4,0x31,0x41, 0x6,0x3f,0x2d, 0x5,0x37,0x76, + 0x6,0x5c,0x48, 0x7,0x22,0x52, 0x5,0x54,0x39, 0xf,0x4e,0x5d, + 0xf,0x54,0x3d, 0x7,0x37,0x68, 0x7,0x3f,0x4a, 0x7,0x46,0x63, + 0x5,0x67,0x66, 0x7,0x5e,0x61, 0x7,0x65,0x35, 0x6,0x21,0x6f, + 0x6,0x21,0x71, 0x6,0x21,0x70, 0xf,0x21,0x3b, 0x5,0x21,0x68, + 0x5,0x21,0x67, 0x5,0x23,0x7c, 0x6,0x27,0x37, 0xf,0x26,0x6b, + 0x6,0x30,0x57, 0x6,0x37,0x28, 0xf,0x2f,0x34, 0x6,0x3f,0x2e, + 0xf,0x3a,0x5e, 0x7,0x22,0x53, 0x7,0x46,0x64, 0x6,0x22,0x74, + 0x5,0x22,0x56, 0x6,0x2a,0x7e, 0x6,0x30,0x59, 0x6,0x30,0x58, + 0x4,0x2c,0x65, 0x6,0x3f,0x2f, 0x5,0x35,0x5f, 0x5,0x32,0x2d, + 0x6,0x3f,0x30, 0x5,0x32,0x2c, 0x6,0x48,0x36, 0xf,0x3a,0x5f, + 0xf,0x3a,0x60, 0xf,0x3a,0x61, 0x7,0x22,0x54, 0x7,0x3f,0x4b, + 0x4,0x21,0x77, 0x6,0x22,0x75, 0x6,0x22,0x76, 0x5,0x22,0x59, + 0x5,0x22,0x58, 0x4,0x22,0x64, 0x5,0x22,0x5b, 0x6,0x24,0x61, + 0x6,0x24,0x60, 0x6,0x24,0x5e, 0xf,0x22,0x48, 0xf,0x22,0x4a, + 0x5,0x22,0x57, 0x6,0x24,0x5f, 0x5,0x22,0x5a, 0x6,0x27,0x41, + 0x6,0x27,0x3b, 0x5,0x24,0x22, 0x6,0x27,0x38, 0x5,0x23,0x7e, + 0x5,0x23,0x7d, 0x5,0x24,0x23, 0x6,0x27,0x40, 0x5,0x24,0x24, + 0x6,0x27,0x3c, 0x6,0x27,0x3f, 0x5,0x24,0x21, 0xf,0x24,0x24, + 0x6,0x27,0x39, 0x6,0x27,0x3a, 0x6,0x27,0x3d, 0x5,0x24,0x25, + 0x6,0x27,0x3e, 0x5,0x25,0x7b, 0x4,0x26,0x35, 0x5,0x25,0x79, + 0x5,0x25,0x7d, 0x5,0x25,0x7a, 0x5,0x25,0x7c, 0x5,0x26,0x21, + 0x6,0x2b,0x23, 0x5,0x25,0x7e, 0x5,0x26,0x22, 0x6,0x2b,0x22, + 0xf,0x26,0x6c, 0x5,0x26,0x23, 0x6,0x2b,0x21, 0x5,0x25,0x77, + 0x5,0x25,0x78, 0x5,0x28,0x7e, 0x6,0x30,0x62, 0x5,0x28,0x7d, + 0x5,0x29,0x22, 0x5,0x28,0x7c, 0x5,0x29,0x23, 0x6,0x30,0x5f, + 0x5,0x29,0x25, 0x5,0x29,0x24, 0x6,0x30,0x5b, 0x5,0x29,0x21, + 0x6,0x30,0x5a, 0x6,0x30,0x65, 0x6,0x30,0x67, 0xf,0x2a,0x53, + 0xf,0x2a,0x54, 0xf,0x2a,0x55, 0x4,0x29,0x26, 0x6,0x30,0x61, + 0x6,0x30,0x60, 0x6,0x30,0x5c, 0x6,0x30,0x5d, 0x6,0x30,0x66, + 0x6,0x30,0x64, 0x6,0x30,0x5e, 0x5,0x2d,0x38, 0x6,0x37,0x32, + 0x5,0x2d,0x37, 0x6,0x37,0x2e, 0x5,0x2d,0x39, 0x5,0x32,0x2e, + 0x6,0x37,0x2a, 0x4,0x2c,0x69, 0x4,0x2c,0x6a, 0x6,0x37,0x2f, + 0x5,0x2d,0x3a, 0x6,0x37,0x2d, 0x6,0x37,0x31, 0x6,0x37,0x30, + 0x4,0x2c,0x67, 0x6,0x37,0x33, 0x6,0x37,0x34, 0xf,0x2f,0x36, + 0xf,0x2f,0x35, 0x6,0x37,0x29, 0x6,0x37,0x2b, 0x6,0x3f,0x35, + 0x5,0x32,0x35, 0x4,0x31,0x46, 0x4,0x31,0x43, 0x4,0x31,0x44, + 0x5,0x32,0x33, 0x5,0x32,0x2f, 0x6,0x3f,0x3a, 0x5,0x32,0x30, + 0x5,0x32,0x34, 0x6,0x3f,0x3c, 0x5,0x32,0x31, 0x5,0x32,0x36, + 0x6,0x3f,0x36, 0x6,0x3f,0x3b, 0x6,0x3f,0x32, 0x5,0x32,0x32, + 0x6,0x3f,0x34, 0xf,0x34,0x49, 0xf,0x34,0x4a, 0xf,0x34,0x4b, + 0xf,0x34,0x4c, 0x6,0x3f,0x39, 0x6,0x3f,0x31, 0x6,0x3f,0x3d, + 0x6,0x3f,0x37, 0x6,0x3f,0x33, 0x6,0x48,0x39, 0x4,0x37,0x3e, + 0x6,0x48,0x3e, 0x5,0x37,0x79, 0x5,0x37,0x7a, 0x4,0x37,0x38, + 0x5,0x37,0x78, 0x6,0x48,0x3a, 0x4,0x37,0x37, 0x5,0x38,0x21, + 0x5,0x38,0x22, 0x6,0x3f,0x38, 0x6,0x48,0x40, 0x6,0x48,0x3d, + 0x6,0x48,0x3b, 0x5,0x37,0x7d, 0x6,0x48,0x38, 0xf,0x3a,0x62, + 0xf,0x3a,0x63, 0x6,0x48,0x3f, 0x5,0x37,0x7b, 0x5,0x37,0x77, + 0x6,0x48,0x41, 0x5,0x37,0x7e, 0xf,0x40,0x2b, 0x5,0x3e,0x78, + 0x4,0x3d,0x22, 0x5,0x45,0x52, 0x4,0x3d,0x25, 0x5,0x3e,0x75, + 0x5,0x3e,0x74, 0x4,0x3d,0x24, 0x5,0x3e,0x77, 0x5,0x3e,0x7a, + 0x6,0x52,0x3e, 0x6,0x52,0x3b, 0x6,0x52,0x3d, 0x6,0x5c,0x4b, + 0x5,0x3e,0x7b, 0x6,0x52,0x3c, 0x5,0x3e,0x76, 0x5,0x3e,0x79, + 0x6,0x5c,0x4c, 0x6,0x5c,0x4d, 0x5,0x45,0x58, 0x4,0x43,0x34, + 0x5,0x45,0x4f, 0x5,0x45,0x55, 0x6,0x5c,0x4a, 0x5,0x45,0x54, + 0x5,0x45,0x57, 0xf,0x47,0x62, 0x5,0x45,0x59, 0x5,0x45,0x50, + 0x5,0x45,0x56, 0x5,0x45,0x51, 0x7,0x22,0x57, 0x7,0x22,0x59, + 0x5,0x4c,0x74, 0x5,0x4c,0x73, 0x5,0x4c,0x75, 0x4,0x49,0x57, + 0x5,0x4c,0x76, 0x5,0x4c,0x78, 0x4,0x49,0x56, 0x7,0x22,0x56, + 0x7,0x22,0x55, 0x7,0x22,0x58, 0x5,0x4c,0x77, 0x5,0x4c,0x79, + 0x5,0x4c,0x72, 0x7,0x2d,0x50, 0x5,0x54,0x3e, 0x7,0x2d,0x52, + 0x7,0x2d,0x58, 0x5,0x54,0x3d, 0x4,0x50,0x28, 0x7,0x2d,0x57, + 0x7,0x2d,0x56, 0x5,0x54,0x3b, 0x7,0x2d,0x51, 0x5,0x54,0x3c, + 0x7,0x2d,0x54, 0x5,0x54,0x3f, 0x7,0x2d,0x4f, 0x4,0x50,0x2a, + 0x5,0x5b,0x41, 0x5,0x5b,0x42, 0x4,0x56,0x2c, 0x7,0x37,0x6b, + 0xf,0x59,0x7c, 0x7,0x37,0x69, 0x7,0x37,0x6a, 0x5,0x61,0x5a, + 0x5,0x61,0x59, 0x5,0x61,0x58, 0x7,0x46,0x66, 0x4,0x5f,0x5d, + 0x5,0x67,0x67, 0x4,0x5f,0x5c, 0x7,0x46,0x65, 0x7,0x46,0x67, + 0x5,0x67,0x68, 0xf,0x62,0x33, 0x7,0x4d,0x58, 0x5,0x6c,0x21, + 0x7,0x53,0x33, 0x7,0x57,0x6c, 0x5,0x6f,0x7b, 0x5,0x73,0x3d, + 0x7,0x57,0x6b, 0x7,0x5e,0x62, 0x7,0x5e,0x63, 0x5,0x77,0x59, + 0x7,0x63,0x50, 0x7,0x63,0x75, 0x4,0x21,0x78, 0x6,0x27,0x42, + 0x5,0x24,0x26, 0x4,0x24,0x26, 0x6,0x2b,0x24, 0xf,0x26,0x6d, + 0xf,0x26,0x6e, 0x6,0x30,0x69, 0x6,0x30,0x68, 0xf,0x2a,0x56, + 0x6,0x37,0x35, 0x5,0x32,0x37, 0x6,0x48,0x42, 0x5,0x38,0x23, + 0x6,0x52,0x3f, 0x5,0x45,0x5a, 0xf,0x47,0x64, 0x7,0x4d,0x59, + 0xf,0x6a,0x4e, 0x6,0x21,0x72, 0x6,0x21,0x73, 0x6,0x22,0x78, + 0x5,0x21,0x69, 0x6,0x22,0x77, 0xf,0x21,0x62, 0x4,0x22,0x67, + 0x4,0x24,0x27, 0x5,0x24,0x27, 0xf,0x24,0x26, 0x6,0x29,0x5e, + 0x6,0x2b,0x25, 0x5,0x26,0x24, 0x5,0x26,0x25, 0x6,0x30,0x6a, + 0x6,0x30,0x41, 0x4,0x2f,0x27, 0x6,0x37,0x36, 0x4,0x31,0x4a, + 0x6,0x48,0x43, 0x5,0x3e,0x7c, 0x5,0x45,0x5b, 0x7,0x22,0x5b, + 0xf,0x47,0x65, 0x6,0x5c,0x4e, 0xf,0x4e,0x5f, 0x7,0x22,0x5c, + 0x7,0x22,0x5d, 0x4,0x56,0x26, 0x7,0x57,0x6d, 0x4,0x22,0x68, + 0x5,0x22,0x5e, 0x6,0x24,0x64, 0x5,0x22,0x5d, 0x6,0x24,0x63, + 0x6,0x24,0x62, 0x6,0x24,0x66, 0x4,0x22,0x69, 0x6,0x24,0x65, + 0x6,0x27,0x45, 0x5,0x24,0x2a, 0x5,0x24,0x2c, 0x5,0x24,0x2b, + 0x5,0x24,0x28, 0x5,0x24,0x29, 0x6,0x27,0x44, 0x6,0x27,0x48, + 0x6,0x2b,0x28, 0x6,0x27,0x43, 0x6,0x27,0x46, 0x5,0x24,0x2d, + 0x5,0x26,0x2c, 0x5,0x26,0x28, 0x5,0x26,0x27, 0x5,0x26,0x2b, + 0x5,0x26,0x2a, 0x4,0x26,0x39, 0x6,0x2b,0x26, 0x6,0x2b,0x29, + 0x6,0x2b,0x27, 0x4,0x26,0x3e, 0x6,0x2b,0x2a, 0xf,0x26,0x70, + 0xf,0x26,0x71, 0xf,0x26,0x72, 0xf,0x26,0x73, 0xf,0x26,0x74, + 0x5,0x26,0x29, 0x5,0x26,0x2d, 0x6,0x2b,0x2b, 0x5,0x29,0x28, + 0x5,0x29,0x2a, 0x4,0x29,0x27, 0x6,0x30,0x6c, 0x5,0x29,0x29, + 0x6,0x30,0x6d, 0xf,0x2a,0x57, 0xf,0x2a,0x59, 0xf,0x2a,0x58, + 0xf,0x2a,0x5a, 0xf,0x2a,0x5b, 0xf,0x2a,0x5c, 0x6,0x30,0x6b, + 0x5,0x2d,0x3d, 0x5,0x2d,0x40, 0x5,0x2d,0x3e, 0x5,0x2d,0x41, + 0x5,0x2d,0x3b, 0x6,0x37,0x3a, 0x6,0x37,0x3b, 0x4,0x2c,0x6e, + 0x5,0x2d,0x42, 0x5,0x2d,0x3f, 0x6,0x37,0x3c, 0x5,0x2d,0x3c, + 0x6,0x37,0x39, 0xf,0x2f,0x37, 0x6,0x37,0x37, 0x6,0x37,0x38, + 0x5,0x2c,0x7b, 0x5,0x32,0x44, 0x5,0x32,0x3b, 0x5,0x32,0x39, + 0x4,0x31,0x4d, 0x6,0x3f,0x43, 0x5,0x32,0x42, 0x6,0x3f,0x48, + 0x6,0x3f,0x3e, 0x5,0x32,0x3d, 0x5,0x32,0x3c, 0x5,0x32,0x3f, + 0x5,0x32,0x3e, 0x6,0x3f,0x3f, 0x6,0x3f,0x40, 0x5,0x32,0x41, + 0x5,0x32,0x38, 0x4,0x31,0x50, 0x6,0x3f,0x44, 0x5,0x32,0x43, + 0x5,0x38,0x28, 0x6,0x3f,0x41, 0xf,0x34,0x4d, 0xf,0x34,0x4e, + 0xf,0x34,0x4f, 0xf,0x34,0x50, 0xf,0x34,0x51, 0xf,0x34,0x52, + 0xf,0x34,0x53, 0x6,0x3f,0x47, 0x6,0x46,0x3d, 0x5,0x32,0x3a, + 0x6,0x3f,0x42, 0x5,0x32,0x40, 0x6,0x48,0x4a, 0x4,0x31,0x4b, + 0x5,0x38,0x2b, 0x5,0x38,0x2c, 0x5,0x38,0x2d, 0x6,0x48,0x4b, + 0x6,0x48,0x4e, 0x5,0x38,0x27, 0x6,0x48,0x4d, 0x4,0x37,0x42, + 0x5,0x38,0x2a, 0x5,0x38,0x26, 0x6,0x48,0x49, 0x4,0x37,0x43, + 0x5,0x38,0x25, 0x6,0x52,0x44, 0x6,0x48,0x46, 0x6,0x48,0x47, + 0x5,0x38,0x24, 0xf,0x3a,0x65, 0xf,0x3a,0x67, 0xf,0x3a,0x68, + 0xf,0x3a,0x69, 0xf,0x3a,0x6a, 0x6,0x48,0x48, 0x6,0x48,0x4c, + 0xf,0x3a,0x66, 0x4,0x3d,0x2b, 0x5,0x3f,0x25, 0x4,0x3d,0x2c, + 0x6,0x52,0x41, 0x6,0x52,0x42, 0x5,0x3f,0x22, 0x5,0x3f,0x23, + 0x6,0x52,0x47, 0x5,0x3e,0x7d, 0x6,0x52,0x45, 0xf,0x41,0x3a, + 0xf,0x41,0x3b, 0xf,0x41,0x3c, 0x6,0x52,0x43, 0x6,0x52,0x48, + 0x5,0x3f,0x24, 0x5,0x3e,0x7e, 0x6,0x52,0x46, 0x4,0x43,0x38, + 0x5,0x45,0x5c, 0x4,0x43,0x37, 0x5,0x45,0x5e, 0x6,0x5c,0x50, + 0x5,0x45,0x60, 0x5,0x45,0x5f, 0x6,0x5c,0x4f, 0xf,0x47,0x67, + 0xf,0x47,0x68, 0xf,0x47,0x69, 0xf,0x47,0x6a, 0xf,0x47,0x6b, + 0xf,0x47,0x6c, 0xf,0x47,0x6d, 0xf,0x47,0x6e, 0xf,0x47,0x6f, + 0x6,0x5c,0x51, 0x6,0x60,0x31, 0xf,0x4a,0x54, 0x7,0x22,0x5e, + 0x4,0x49,0x5a, 0x4,0x37,0x3f, 0x4,0x49,0x58, 0x5,0x4c,0x7a, + 0x4,0x49,0x59, 0x7,0x2d,0x59, 0x7,0x22,0x62, 0x5,0x4c,0x7c, + 0x5,0x4c,0x7e, 0xf,0x4e,0x60, 0xf,0x4e,0x62, 0xf,0x4e,0x63, + 0x7,0x22,0x5f, 0x7,0x22,0x61, 0x7,0x22,0x63, 0x7,0x22,0x60, + 0x5,0x4c,0x7b, 0x5,0x54,0x41, 0x5,0x4c,0x7d, 0x5,0x54,0x43, + 0x5,0x54,0x40, 0x4,0x50,0x2d, 0x5,0x54,0x44, 0xf,0x54,0x3f, + 0xf,0x54,0x40, 0xf,0x54,0x41, 0xf,0x54,0x42, 0x7,0x37,0x6e, + 0x5,0x5b,0x44, 0x7,0x37,0x6c, 0x7,0x37,0x6d, 0xf,0x59,0x7e, + 0xf,0x5a,0x21, 0xf,0x5a,0x22, 0xf,0x5a,0x23, 0x5,0x5b,0x43, + 0x7,0x37,0x6f, 0x5,0x5b,0x45, 0x7,0x3f,0x51, 0x7,0x3f,0x4e, + 0x5,0x61,0x5b, 0xf,0x5e,0x5a, 0xf,0x5e,0x5c, 0x7,0x3f,0x4d, + 0x7,0x3f,0x4f, 0x7,0x3f,0x4c, 0xf,0x5e,0x5b, 0x7,0x3f,0x50, + 0x7,0x46,0x68, 0x7,0x46,0x69, 0x5,0x61,0x5c, 0x5,0x67,0x69, + 0xf,0x62,0x34, 0xf,0x62,0x35, 0xf,0x62,0x36, 0x5,0x67,0x6a, + 0x5,0x6c,0x24, 0x5,0x6c,0x23, 0x7,0x4d,0x5d, 0x7,0x4d,0x5b, + 0x5,0x6c,0x22, 0x7,0x4d,0x5a, 0x7,0x4d,0x5c, 0x7,0x4d,0x5e, + 0x4,0x66,0x3c, 0x7,0x53,0x34, 0x7,0x53,0x61, 0x5,0x73,0x3e, + 0x7,0x57,0x6e, 0x7,0x57,0x6f, 0x5,0x75,0x6a, 0xf,0x6a,0x4f, + 0x7,0x5b,0x4d, 0x7,0x5e,0x64, 0x7,0x62,0x36, 0x5,0x7a,0x68, + 0x5,0x7a,0x67, 0xf,0x6c,0x7b, 0xf,0x21,0x63, 0xf,0x22,0x4b, + 0xf,0x22,0x4c, 0x6,0x2b,0x2c, 0xf,0x24,0x27, 0x6,0x2b,0x2d, + 0x6,0x2b,0x2e, 0xf,0x2f,0x39, 0xf,0x2f,0x3b, 0xf,0x2f,0x3c, + 0xf,0x2f,0x3a, 0x5,0x32,0x45, 0xf,0x34,0x54, 0x6,0x48,0x4f, + 0xf,0x3a,0x6b, 0xf,0x3a,0x6c, 0x5,0x3f,0x26, 0x6,0x21,0x3f, + 0x6,0x21,0x75, 0x6,0x22,0x79, 0x6,0x27,0x49, 0x4,0x24,0x2a, + 0x6,0x30,0x70, 0x6,0x27,0x4d, 0xf,0x24,0x28, 0x6,0x27,0x4b, + 0x6,0x27,0x4e, 0x4,0x26,0x3f, 0x6,0x2b,0x30, 0x5,0x26,0x2e, + 0x6,0x2b,0x31, 0x3,0x2a,0x39, 0x4,0x27,0x41, 0x6,0x35,0x23, + 0x6,0x30,0x72, 0x6,0x30,0x73, 0x6,0x30,0x71, 0x6,0x30,0x6f, + 0x6,0x30,0x6e, 0x6,0x37,0x3f, 0x6,0x37,0x3e, 0x4,0x2c,0x6f, + 0x6,0x37,0x3d, 0x6,0x37,0x40, 0x6,0x3f,0x49, 0x6,0x3f,0x4a, + 0x6,0x3f,0x4b, 0x6,0x3f,0x4c, 0x6,0x3f,0x4d, 0x6,0x3f,0x4e, + 0x4,0x37,0x44, 0x6,0x48,0x50, 0x6,0x48,0x54, 0x6,0x48,0x53, + 0x6,0x48,0x51, 0xf,0x3a,0x6d, 0x6,0x48,0x52, 0x6,0x52,0x49, + 0x5,0x3f,0x27, 0xf,0x41,0x3d, 0x6,0x5c,0x53, 0x6,0x5c,0x54, + 0x6,0x5c,0x52, 0x5,0x45,0x61, 0x7,0x22,0x64, 0x7,0x2d,0x5a, + 0x7,0x2d,0x5c, 0x4,0x50,0x2f, 0x5,0x54,0x45, 0x7,0x37,0x71, + 0x7,0x37,0x70, 0x7,0x57,0x70, 0x7,0x63,0x51, 0x7,0x63,0x52, + 0x7,0x65,0x36, 0x6,0x21,0x40, 0x6,0x21,0x76, 0xf,0x22,0x4d, + 0x4,0x24,0x2b, 0x6,0x27,0x50, 0x6,0x27,0x4f, 0x5,0x24,0x2e, + 0x6,0x2b,0x32, 0x6,0x30,0x76, 0x6,0x30,0x75, 0x6,0x30,0x77, + 0x5,0x2e,0x68, 0x6,0x3f,0x4f, 0x5,0x38,0x2e, 0x6,0x52,0x4a, + 0x6,0x5c,0x55, 0x7,0x22,0x65, 0x7,0x2d,0x5d, 0x5,0x21,0x2a, + 0x5,0x21,0x47, 0x6,0x21,0x78, 0x6,0x21,0x7c, 0x6,0x21,0x77, + 0x6,0x21,0x7a, 0x6,0x21,0x7b, 0x6,0x23,0x21, 0x6,0x23,0x22, + 0x6,0x22,0x7c, 0x6,0x22,0x7a, 0x6,0x23,0x23, 0x6,0x22,0x7b, + 0x6,0x22,0x7d, 0x6,0x22,0x7e, 0x5,0x21,0x6a, 0x5,0x22,0x60, + 0x5,0x22,0x5f, 0x6,0x24,0x68, 0x6,0x24,0x69, 0x6,0x24,0x6a, + 0x6,0x24,0x6b, 0x5,0x24,0x2f, 0x6,0x27,0x51, 0x5,0x24,0x31, + 0x6,0x27,0x53, 0x5,0x24,0x30, 0xf,0x24,0x29, 0xf,0x24,0x2a, + 0xf,0x24,0x2b, 0xf,0x24,0x2c, 0x6,0x27,0x52, 0x5,0x24,0x32, + 0x5,0x26,0x2f, 0x6,0x2b,0x36, 0x6,0x2b,0x33, 0x6,0x2b,0x34, + 0x6,0x2b,0x37, 0x6,0x2b,0x35, 0x6,0x30,0x7e, 0x5,0x29,0x2c, + 0x6,0x30,0x7d, 0x4,0x29,0x30, 0x6,0x30,0x79, 0x5,0x29,0x2b, + 0x6,0x30,0x78, 0x5,0x2d,0x44, 0x5,0x2d,0x43, 0x5,0x2d,0x45, + 0x6,0x37,0x43, 0x6,0x37,0x41, 0x5,0x2d,0x46, 0xf,0x2f,0x3d, + 0x6,0x37,0x42, 0x5,0x32,0x4a, 0x5,0x32,0x48, 0x5,0x32,0x49, + 0x6,0x3f,0x56, 0x6,0x3f,0x50, 0x4,0x29,0x2f, 0x6,0x48,0x55, + 0x6,0x3f,0x52, 0x6,0x3f,0x53, 0x5,0x32,0x47, 0x6,0x3f,0x51, + 0xf,0x34,0x55, 0xf,0x34,0x56, 0xf,0x34,0x57, 0x6,0x3f,0x54, + 0x6,0x3f,0x57, 0x6,0x3f,0x55, 0x6,0x48,0x56, 0x6,0x48,0x59, + 0x5,0x38,0x2f, 0x5,0x38,0x32, 0x5,0x38,0x31, 0x6,0x48,0x5a, + 0x5,0x38,0x30, 0x6,0x48,0x58, 0x6,0x48,0x57, 0x5,0x3f,0x28, + 0x4,0x3d,0x31, 0x6,0x52,0x4b, 0xf,0x41,0x40, 0x6,0x52,0x4c, + 0x5,0x45,0x62, 0x6,0x5c,0x56, 0x5,0x45,0x63, 0x6,0x5c,0x57, + 0x6,0x5c,0x59, 0xf,0x47,0x70, 0x6,0x5c,0x5a, 0x6,0x5c,0x58, + 0x5,0x4d,0x21, 0x5,0x4d,0x22, 0x4,0x49,0x60, 0x7,0x22,0x66, + 0xf,0x4e,0x64, 0xf,0x4e,0x65, 0x7,0x22,0x67, 0x7,0x2d,0x5f, + 0x5,0x54,0x46, 0x4,0x50,0x30, 0x7,0x2d,0x60, 0x7,0x2d,0x5e, + 0x7,0x37,0x73, 0x7,0x37,0x72, 0x7,0x37,0x74, 0xf,0x5a,0x24, + 0x4,0x5b,0x22, 0x5,0x61,0x5e, 0x7,0x3f,0x52, 0xf,0x5e,0x5d, + 0x5,0x61,0x5d, 0x7,0x46,0x6d, 0x7,0x46,0x6b, 0x7,0x46,0x6f, + 0x7,0x46,0x6a, 0x7,0x46,0x6c, 0x5,0x67,0x6b, 0x5,0x6c,0x25, + 0x7,0x4d,0x5f, 0x4,0x5f,0x5f, 0x7,0x4d,0x61, 0x7,0x4d,0x60, + 0x5,0x6c,0x26, 0x5,0x6f,0x7c, 0x5,0x6f,0x7d, 0x4,0x66,0x3d, + 0x7,0x53,0x35, 0x5,0x73,0x3f, 0x7,0x60,0x3c, 0x7,0x60,0x6f, + 0x7,0x64,0x46, 0x6,0x24,0x6e, 0x6,0x24,0x6c, 0x6,0x24,0x6d, + 0x5,0x24,0x33, 0x6,0x31,0x21, 0x6,0x2b,0x38, 0x6,0x2d,0x32, + 0x6,0x31,0x24, 0x6,0x37,0x44, 0x6,0x31,0x22, 0x6,0x31,0x23, + 0x6,0x37,0x46, 0x6,0x37,0x45, 0x6,0x3f,0x58, 0x6,0x4f,0x21, + 0x5,0x38,0x33, 0x6,0x48,0x5c, 0x6,0x48,0x5b, 0x5,0x3f,0x2a, + 0x6,0x5c,0x5c, 0x6,0x5c,0x5f, 0x6,0x5c,0x5d, 0x6,0x5c,0x5b, + 0x6,0x5c,0x5e, 0x7,0x2d,0x61, 0x7,0x2d,0x4e, 0x4,0x50,0x32, + 0x7,0x37,0x75, 0x7,0x3f,0x55, 0x7,0x3f,0x54, 0x7,0x3f,0x53, + 0x7,0x46,0x72, 0x7,0x46,0x70, 0x7,0x46,0x71, 0x7,0x57,0x71, + 0x7,0x5b,0x4e, 0x7,0x62,0x37, 0x6,0x23,0x25, 0x6,0x23,0x24, + 0xf,0x21,0x64, 0x6,0x24,0x71, 0x6,0x24,0x6f, 0xf,0x24,0x2d, + 0x6,0x27,0x54, 0x5,0x26,0x30, 0x6,0x2b,0x3b, 0x6,0x2b,0x3a, + 0x6,0x37,0x47, 0x4,0x2c,0x74, 0x4,0x2c,0x73, 0x5,0x35,0x60, + 0x6,0x3f,0x5d, 0x6,0x3f,0x59, 0x6,0x3f,0x5a, 0xf,0x34,0x58, + 0xf,0x34,0x59, 0xf,0x34,0x5a, 0x6,0x3f,0x5c, 0x6,0x3f,0x5b, + 0x5,0x32,0x4b, 0x6,0x48,0x5d, 0x6,0x48,0x60, 0x6,0x48,0x5e, + 0x6,0x48,0x5f, 0xf,0x3a,0x6e, 0x6,0x52,0x51, 0x6,0x52,0x4e, + 0x6,0x52,0x50, 0x6,0x52,0x4f, 0xf,0x41,0x41, 0x4,0x43,0x3c, + 0x6,0x5c,0x60, 0x7,0x22,0x6b, 0x7,0x22,0x6c, 0x7,0x22,0x69, + 0x7,0x22,0x6a, 0x5,0x4d,0x23, 0x4,0x50,0x33, 0x5,0x54,0x47, + 0x7,0x2d,0x64, 0x7,0x37,0x76, 0x7,0x3f,0x56, 0xf,0x67,0x54, + 0x7,0x4d,0x62, 0x7,0x53,0x36, 0x5,0x73,0x41, 0xf,0x6c,0x27, + 0x6,0x21,0x7d, 0x5,0x21,0x6b, 0x4,0x21,0x79, 0x5,0x22,0x61, + 0x4,0x22,0x6e, 0x5,0x22,0x62, 0x5,0x24,0x34, 0x6,0x27,0x58, + 0x5,0x24,0x35, 0x6,0x27,0x57, 0x6,0x27,0x59, 0x6,0x27,0x5b, + 0x6,0x27,0x56, 0x5,0x24,0x36, 0x6,0x27,0x55, 0x6,0x27,0x5a, + 0x5,0x26,0x33, 0x6,0x2b,0x3d, 0x5,0x26,0x31, 0x6,0x2b,0x3c, + 0x5,0x26,0x32, 0x5,0x29,0x2d, 0x6,0x2b,0x3f, 0x4,0x29,0x33, + 0x6,0x31,0x26, 0x5,0x29,0x30, 0x5,0x29,0x2e, 0x6,0x31,0x28, + 0x5,0x29,0x32, 0x5,0x29,0x31, 0xf,0x2a,0x5e, 0x6,0x31,0x27, + 0x6,0x37,0x4d, 0x4,0x2c,0x79, 0x4,0x2c,0x77, 0x4,0x2c,0x7c, + 0x4,0x2c,0x75, 0x5,0x2d,0x4b, 0x5,0x2d,0x49, 0x4,0x2c,0x78, + 0x4,0x2c,0x7a, 0x4,0x2c,0x76, 0x4,0x2c,0x7b, 0x5,0x2d,0x4a, + 0x6,0x37,0x49, 0x6,0x37,0x4f, 0x6,0x37,0x4c, 0xf,0x2f,0x3f, + 0xf,0x2f,0x40, 0x6,0x37,0x4b, 0x6,0x37,0x50, 0x6,0x37,0x4e, + 0x6,0x37,0x4a, 0x4,0x31,0x56, 0x5,0x32,0x4f, 0x6,0x3f,0x68, + 0x6,0x3f,0x61, 0x5,0x32,0x4c, 0x5,0x32,0x51, 0x5,0x32,0x4e, + 0x6,0x3f,0x60, 0x5,0x32,0x50, 0x4,0x31,0x58, 0x6,0x3f,0x67, + 0x6,0x3f,0x65, 0x6,0x3f,0x62, 0x4,0x31,0x59, 0x6,0x3f,0x66, + 0x5,0x32,0x4d, 0x6,0x3f,0x64, 0x6,0x3f,0x5f, 0x6,0x3f,0x63, + 0x6,0x48,0x64, 0xf,0x34,0x5c, 0x4,0x37,0x46, 0x5,0x38,0x36, + 0x5,0x38,0x35, 0x5,0x38,0x3b, 0x5,0x38,0x3a, 0x5,0x38,0x37, + 0x4,0x37,0x47, 0x6,0x48,0x61, 0x5,0x38,0x34, 0x6,0x48,0x63, + 0x5,0x38,0x38, 0x4,0x31,0x55, 0xf,0x3a,0x70, 0x6,0x48,0x62, + 0xf,0x3a,0x6f, 0x5,0x38,0x39, 0x5,0x3f,0x2c, 0x5,0x3f,0x2b, + 0x6,0x52,0x52, 0x6,0x52,0x54, 0x6,0x52,0x57, 0x6,0x52,0x53, + 0xf,0x41,0x42, 0xf,0x41,0x43, 0xf,0x41,0x44, 0xf,0x41,0x45, + 0xf,0x41,0x46, 0xf,0x41,0x47, 0x6,0x52,0x55, 0x6,0x52,0x56, + 0x6,0x56,0x6c, 0x5,0x3f,0x2d, 0x4,0x3d,0x32, 0x6,0x5c,0x66, + 0x6,0x5c,0x63, 0x5,0x45,0x66, 0x6,0x5c,0x62, 0x4,0x43,0x3e, + 0x5,0x45,0x65, 0x4,0x43,0x41, 0x4,0x43,0x40, 0x6,0x5c,0x61, + 0x5,0x45,0x68, 0x5,0x45,0x6a, 0x5,0x45,0x64, 0x6,0x5c,0x68, + 0x6,0x5c,0x69, 0x6,0x5c,0x6a, 0x5,0x45,0x67, 0x6,0x5c,0x64, + 0xf,0x47,0x71, 0xf,0x47,0x72, 0xf,0x47,0x73, 0xf,0x47,0x74, + 0xf,0x47,0x75, 0x6,0x5c,0x65, 0x4,0x49,0x64, 0x5,0x4d,0x24, + 0x5,0x5b,0x48, 0x4,0x49,0x63, 0x4,0x49,0x62, 0x5,0x4d,0x25, + 0x7,0x22,0x6d, 0x7,0x22,0x6f, 0xf,0x4e,0x66, 0xf,0x4e,0x67, + 0x7,0x22,0x6e, 0x7,0x22,0x70, 0x7,0x2d,0x65, 0x5,0x54,0x48, + 0x5,0x54,0x4a, 0x7,0x2d,0x67, 0x7,0x2d,0x66, 0xf,0x54,0x44, + 0xf,0x54,0x45, 0x7,0x2d,0x68, 0x5,0x54,0x49, 0x5,0x5b,0x47, + 0x7,0x37,0x77, 0x4,0x56,0x30, 0xf,0x5c,0x5f, 0x5,0x5b,0x46, + 0x5,0x61,0x60, 0x7,0x3f,0x57, 0x5,0x61,0x5f, 0x7,0x3f,0x58, + 0xf,0x5e,0x5e, 0x5,0x61,0x61, 0x7,0x46,0x73, 0x7,0x46,0x75, + 0x7,0x46,0x76, 0x7,0x4d,0x22, 0x7,0x46,0x74, 0x5,0x6c,0x27, + 0x4,0x63,0x3e, 0x4,0x63,0x3d, 0xf,0x65,0x2a, 0x7,0x4d,0x63, + 0x7,0x53,0x37, 0x5,0x6f,0x7e, 0x7,0x57,0x72, 0x4,0x6a,0x47, + 0x5,0x79,0x28, 0x5,0x21,0x31, 0x6,0x22,0x21, 0x4,0x22,0x6f, + 0x5,0x21,0x6c, 0x6,0x23,0x26, 0xf,0x22,0x4f, 0x6,0x24,0x75, + 0x5,0x22,0x63, 0x6,0x27,0x60, 0x5,0x22,0x69, 0x6,0x27,0x5d, + 0x5,0x22,0x64, 0x6,0x24,0x73, 0x6,0x24,0x74, 0x5,0x22,0x65, + 0x6,0x27,0x5c, 0x6,0x27,0x5e, 0x6,0x27,0x61, 0x6,0x24,0x72, + 0x5,0x22,0x68, 0x5,0x24,0x37, 0x5,0x24,0x39, 0x4,0x26,0x45, + 0x6,0x27,0x66, 0x6,0x27,0x64, 0x6,0x2b,0x46, 0x6,0x27,0x67, + 0x6,0x2b,0x40, 0x6,0x27,0x62, 0x6,0x27,0x63, 0x6,0x2b,0x44, + 0x6,0x27,0x65, 0x6,0x27,0x68, 0x3,0x25,0x7e, 0x6,0x27,0x69, + 0x5,0x24,0x3a, 0xf,0x24,0x2e, 0xf,0x24,0x2f, 0xf,0x24,0x31, + 0xf,0x24,0x32, 0xf,0x24,0x34, 0xf,0x24,0x35, 0xf,0x24,0x36, + 0xf,0x26,0x77, 0xf,0x26,0x78, 0xf,0x26,0x79, 0xf,0x26,0x7a, + 0xf,0x26,0x7b, 0xf,0x26,0x7d, 0xf,0x26,0x7e, 0xf,0x27,0x21, + 0xf,0x26,0x7c, 0x6,0x2b,0x45, 0x6,0x2b,0x41, 0x6,0x2b,0x42, + 0x4,0x24,0x2d, 0xf,0x24,0x30, 0x4,0x26,0x44, 0x5,0x26,0x34, + 0x6,0x2b,0x43, 0x4,0x26,0x47, 0x6,0x2b,0x4c, 0x4,0x29,0x47, + 0x6,0x31,0x2f, 0x4,0x26,0x4b, 0x6,0x2b,0x4d, 0x6,0x31,0x29, + 0x5,0x26,0x35, 0x6,0x31,0x2c, 0x6,0x2b,0x4f, 0x4,0x26,0x4a, + 0x5,0x26,0x37, 0x4,0x29,0x38, 0x5,0x26,0x36, 0x4,0x29,0x43, + 0x6,0x2b,0x49, 0x5,0x26,0x38, 0x4,0x26,0x51, 0x4,0x29,0x44, + 0x6,0x31,0x2a, 0x6,0x31,0x2b, 0x6,0x2b,0x50, 0x6,0x2b,0x47, + 0x6,0x31,0x2d, 0xf,0x26,0x75, 0xf,0x27,0x22, 0xf,0x2a,0x70, + 0x4,0x29,0x46, 0x6,0x31,0x2e, 0x6,0x2b,0x48, 0x6,0x2b,0x4a, + 0x6,0x2b,0x4e, 0x6,0x2b,0x4b, 0xf,0x2a,0x64, 0xf,0x2a,0x5f, + 0xf,0x2a,0x62, 0xf,0x2a,0x65, 0xf,0x2a,0x68, 0xf,0x2a,0x6c, + 0x6,0x37,0x5b, 0x6,0x37,0x59, 0x6,0x31,0x32, 0x4,0x29,0x49, + 0x5,0x29,0x37, 0x4,0x29,0x42, 0x4,0x2d,0x29, 0x5,0x2d,0x4e, + 0x5,0x29,0x36, 0x6,0x31,0x39, 0x6,0x37,0x57, 0x6,0x31,0x33, + 0x4,0x2c,0x7d, 0x5,0x2d,0x4c, 0x6,0x31,0x35, 0x6,0x37,0x53, + 0x4,0x2d,0x21, 0x6,0x31,0x38, 0x5,0x29,0x34, 0x4,0x2c,0x7e, + 0x6,0x31,0x3a, 0x6,0x31,0x31, 0x6,0x31,0x37, 0x6,0x37,0x56, + 0x6,0x37,0x55, 0x4,0x2d,0x2a, 0x6,0x31,0x34, 0xf,0x2a,0x61, + 0xf,0x2a,0x66, 0xf,0x2a,0x69, 0xf,0x2a,0x6b, 0xf,0x2a,0x6d, + 0xf,0x2a,0x6e, 0xf,0x2a,0x6f, 0xf,0x2f,0x46, 0xf,0x2f,0x47, + 0xf,0x2f,0x48, 0xf,0x2f,0x4a, 0x6,0x37,0x52, 0xf,0x2f,0x44, + 0x6,0x37,0x58, 0xf,0x2a,0x63, 0x5,0x2d,0x4d, 0x6,0x37,0x51, + 0x5,0x2d,0x52, 0x5,0x2d,0x58, 0x5,0x2d,0x5b, 0x6,0x3f,0x6d, + 0x6,0x37,0x63, 0x6,0x3f,0x6f, 0x6,0x3f,0x6b, 0x6,0x3f,0x70, + 0x6,0x37,0x64, 0x5,0x2d,0x55, 0x6,0x3f,0x69, 0x4,0x2d,0x2e, + 0x6,0x3f,0x73, 0x5,0x2d,0x56, 0x4,0x2d,0x26, 0x5,0x32,0x5d, + 0x5,0x2d,0x51, 0x5,0x2d,0x5c, 0x6,0x37,0x62, 0x6,0x37,0x5d, + 0x5,0x32,0x54, 0x6,0x37,0x5f, 0x6,0x37,0x61, 0x6,0x3f,0x6c, + 0x6,0x37,0x60, 0x6,0x3f,0x71, 0x4,0x2d,0x27, 0x5,0x2d,0x50, + 0x6,0x37,0x5c, 0x5,0x32,0x53, 0x6,0x3f,0x72, 0x6,0x3f,0x74, + 0x5,0x32,0x52, 0x5,0x2d,0x4f, 0xf,0x2f,0x41, 0xf,0x2f,0x42, + 0xf,0x2f,0x43, 0xf,0x2f,0x49, 0xf,0x2f,0x4b, 0xf,0x34,0x5d, + 0xf,0x34,0x5f, 0xf,0x34,0x60, 0xf,0x34,0x64, 0xf,0x34,0x65, + 0xf,0x34,0x66, 0xf,0x34,0x67, 0xf,0x34,0x68, 0x6,0x3f,0x6a, + 0x6,0x37,0x65, 0x6,0x37,0x66, 0x5,0x2d,0x54, 0x5,0x2d,0x59, + 0x4,0x37,0x5a, 0x6,0x48,0x71, 0x4,0x37,0x4d, 0x5,0x32,0x59, + 0x6,0x3f,0x7c, 0x4,0x37,0x4b, 0x6,0x48,0x73, 0x6,0x48,0x69, + 0x5,0x38,0x55, 0x6,0x3f,0x7e, 0x6,0x48,0x72, 0x6,0x40,0x22, + 0x4,0x31,0x65, 0x5,0x2d,0x53, 0x4,0x31,0x6d, 0x6,0x3f,0x77, + 0x6,0x48,0x6e, 0x4,0x31,0x61, 0x5,0x38,0x3f, 0x5,0x32,0x57, + 0x5,0x32,0x5a, 0x4,0x37,0x4c, 0x6,0x3f,0x79, 0x5,0x32,0x5c, + 0x6,0x3f,0x76, 0x6,0x3f,0x6e, 0x4,0x31,0x69, 0x5,0x38,0x3c, + 0x6,0x48,0x70, 0x5,0x32,0x5e, 0x4,0x31,0x5f, 0x6,0x3f,0x7d, + 0x6,0x3f,0x7b, 0x6,0x3f,0x7a, 0x6,0x48,0x66, 0x6,0x48,0x6c, + 0x5,0x38,0x3e, 0x5,0x38,0x41, 0x6,0x48,0x74, 0x5,0x32,0x55, + 0x6,0x48,0x6b, 0x6,0x48,0x76, 0x6,0x48,0x67, 0x6,0x48,0x65, + 0x6,0x3f,0x75, 0x5,0x38,0x40, 0xf,0x34,0x61, 0xf,0x34,0x5e, + 0xf,0x34,0x62, 0xf,0x34,0x63, 0xf,0x34,0x69, 0xf,0x34,0x6a, + 0xf,0x34,0x6b, 0xf,0x34,0x6c, 0xf,0x34,0x6d, 0xf,0x34,0x6f, + 0xf,0x34,0x70, 0xf,0x34,0x72, 0xf,0x3a,0x72, 0xf,0x3a,0x73, + 0xf,0x3a,0x74, 0xf,0x3a,0x75, 0xf,0x3a,0x76, 0xf,0x3a,0x77, + 0xf,0x3a,0x79, 0xf,0x3a,0x7a, 0xf,0x3a,0x7c, 0xf,0x3a,0x7d, + 0xf,0x3a,0x7e, 0xf,0x3b,0x21, 0xf,0x3b,0x22, 0xf,0x3b,0x25, + 0xf,0x3b,0x29, 0xf,0x3b,0x2a, 0xf,0x3b,0x2c, 0xf,0x3b,0x2e, + 0x6,0x48,0x68, 0x5,0x32,0x56, 0x6,0x3f,0x78, 0xf,0x3b,0x27, + 0xf,0x34,0x6e, 0x6,0x49,0x24, 0x6,0x48,0x6d, 0x6,0x40,0x21, + 0xf,0x3b,0x24, 0x4,0x3d,0x3f, 0x5,0x38,0x4a, 0x5,0x38,0x4d, + 0x5,0x38,0x52, 0x4,0x37,0x4f, 0x4,0x37,0x57, 0x4,0x37,0x51, + 0x6,0x52,0x5d, 0x6,0x49,0x23, 0x5,0x38,0x50, 0x6,0x49,0x22, + 0x4,0x37,0x53, 0x5,0x38,0x56, 0x5,0x38,0x58, 0x5,0x38,0x43, + 0x6,0x52,0x61, 0x5,0x38,0x5a, 0x5,0x3f,0x33, 0x4,0x37,0x5b, + 0x5,0x38,0x53, 0x6,0x49,0x21, 0x5,0x38,0x46, 0x6,0x48,0x7b, + 0x5,0x3f,0x34, 0x5,0x38,0x44, 0x5,0x38,0x54, 0x5,0x32,0x5f, + 0x6,0x52,0x58, 0x5,0x38,0x47, 0x4,0x3d,0x36, 0x4,0x37,0x58, + 0x5,0x38,0x59, 0x5,0x38,0x51, 0x5,0x38,0x4b, 0x5,0x3f,0x31, + 0x6,0x48,0x77, 0x5,0x38,0x4f, 0x5,0x38,0x3d, 0x6,0x48,0x7e, + 0x6,0x52,0x62, 0x6,0x52,0x63, 0x6,0x52,0x5a, 0x6,0x48,0x7d, + 0x5,0x38,0x57, 0x6,0x52,0x5e, 0x6,0x52,0x60, 0x5,0x3f,0x2f, + 0x4,0x3d,0x40, 0x4,0x37,0x52, 0x5,0x38,0x49, 0x6,0x48,0x79, + 0xf,0x3a,0x71, 0xf,0x3a,0x7b, 0xf,0x3b,0x23, 0xf,0x3b,0x28, + 0xf,0x3b,0x2d, 0xf,0x41,0x48, 0xf,0x41,0x4e, 0xf,0x41,0x50, + 0xf,0x41,0x51, 0xf,0x41,0x52, 0x6,0x52,0x5c, 0x6,0x52,0x5f, + 0x6,0x52,0x5b, 0x6,0x48,0x7a, 0xf,0x3b,0x2b, 0x5,0x38,0x4e, + 0x5,0x3f,0x2e, 0x5,0x38,0x4c, 0xf,0x34,0x71, 0xf,0x47,0x7d, + 0x5,0x3f,0x3c, 0x5,0x3f,0x36, 0x5,0x3f,0x35, 0x6,0x52,0x6b, + 0x5,0x4d,0x26, 0x5,0x3f,0x45, 0x6,0x5c,0x6f, 0x5,0x3f,0x39, + 0x5,0x3f,0x3f, 0x5,0x3f,0x44, 0x6,0x5c,0x74, 0x6,0x52,0x6f, + 0x5,0x45,0x6b, 0x5,0x3f,0x3b, 0x6,0x5c,0x6c, 0x6,0x52,0x65, + 0x5,0x3f,0x38, 0x5,0x3f,0x3d, 0x5,0x3f,0x3a, 0x6,0x52,0x59, + 0x4,0x49,0x6e, 0x6,0x5c,0x76, 0x6,0x5c,0x79, 0x5,0x3f,0x43, + 0x6,0x52,0x68, 0x6,0x5c,0x72, 0x4,0x43,0x4f, 0x6,0x5c,0x78, + 0x6,0x5c,0x77, 0x5,0x3f,0x41, 0x5,0x45,0x6d, 0x5,0x3f,0x3e, + 0x6,0x5c,0x71, 0x6,0x5c,0x6e, 0x6,0x5c,0x6d, 0x5,0x3f,0x37, + 0x6,0x52,0x67, 0x6,0x52,0x6d, 0xf,0x41,0x4a, 0xf,0x41,0x4b, + 0xf,0x41,0x4c, 0xf,0x41,0x4d, 0xf,0x41,0x4f, 0xf,0x41,0x53, + 0xf,0x47,0x76, 0xf,0x47,0x77, 0xf,0x47,0x79, 0xf,0x47,0x7a, + 0xf,0x48,0x25, 0xf,0x48,0x28, 0x6,0x5c,0x70, 0x6,0x5c,0x75, + 0x5,0x3f,0x40, 0xf,0x41,0x49, 0x6,0x5c,0x73, 0x6,0x52,0x6e, + 0x6,0x5d,0x23, 0x6,0x5d,0x27, 0x4,0x43,0x45, 0x4,0x43,0x44, + 0x5,0x4d,0x27, 0x6,0x5c,0x7c, 0x5,0x45,0x77, 0x5,0x45,0x76, + 0x5,0x45,0x73, 0x4,0x3d,0x35, 0x6,0x5c,0x7b, 0x7,0x22,0x72, + 0x7,0x22,0x75, 0x5,0x4d,0x29, 0x5,0x45,0x70, 0x5,0x45,0x6f, + 0x5,0x45,0x6c, 0x5,0x45,0x71, 0x5,0x45,0x72, 0x5,0x45,0x79, + 0x6,0x5d,0x25, 0x6,0x5c,0x7d, 0x6,0x5c,0x7e, 0x6,0x52,0x6a, + 0x6,0x5d,0x22, 0x7,0x22,0x74, 0x6,0x5d,0x21, 0x7,0x22,0x77, + 0x5,0x45,0x74, 0x5,0x45,0x78, 0x7,0x2d,0x6a, 0x4,0x43,0x53, + 0xf,0x47,0x78, 0xf,0x47,0x7c, 0xf,0x47,0x7e, 0xf,0x48,0x21, + 0xf,0x48,0x23, 0xf,0x48,0x24, 0xf,0x48,0x26, 0xf,0x4e,0x69, + 0xf,0x4e,0x6a, 0xf,0x4e,0x6b, 0xf,0x4e,0x6c, 0xf,0x4e,0x6d, + 0xf,0x4e,0x6e, 0xf,0x4e,0x6f, 0xf,0x4e,0x73, 0xf,0x4e,0x75, + 0x7,0x22,0x73, 0x7,0x22,0x78, 0x6,0x5c,0x6b, 0x5,0x45,0x6e, + 0x6,0x5c,0x7a, 0x5,0x4d,0x28, 0x5,0x45,0x75, 0x7,0x2d,0x71, + 0x4,0x49,0x66, 0x4,0x43,0x52, 0x7,0x2d,0x6b, 0x4,0x49,0x71, + 0x7,0x2d,0x6d, 0x5,0x4d,0x2f, 0x7,0x2d,0x73, 0x4,0x49,0x6a, + 0x5,0x4d,0x2e, 0x7,0x22,0x79, 0x5,0x4d,0x33, 0x4,0x49,0x72, + 0x7,0x2d,0x75, 0x5,0x38,0x45, 0x5,0x4d,0x32, 0x5,0x4d,0x35, + 0x4,0x50,0x35, 0x4,0x50,0x36, 0x7,0x23,0x21, 0x5,0x4d,0x34, + 0x7,0x37,0x7c, 0x5,0x4d,0x30, 0x5,0x54,0x4e, 0x4,0x56,0x34, + 0x7,0x22,0x7a, 0x7,0x23,0x22, 0x5,0x54,0x54, 0x5,0x4d,0x2b, + 0x5,0x4d,0x2d, 0x5,0x54,0x4d, 0x5,0x4d,0x2c, 0x7,0x2e,0x22, + 0x7,0x2d,0x77, 0x7,0x2d,0x76, 0x7,0x22,0x7e, 0x4,0x50,0x3c, + 0x7,0x2d,0x70, 0x7,0x2d,0x6f, 0xf,0x48,0x22, 0xf,0x4e,0x70, + 0x7,0x2d,0x72, 0x5,0x4d,0x31, 0x7,0x2d,0x6c, 0xf,0x4e,0x71, + 0xf,0x4e,0x72, 0xf,0x4e,0x74, 0xf,0x4e,0x76, 0xf,0x54,0x47, + 0xf,0x54,0x48, 0xf,0x54,0x4a, 0xf,0x54,0x4b, 0xf,0x54,0x51, + 0xf,0x54,0x53, 0x7,0x2d,0x74, 0x5,0x54,0x4b, 0x7,0x30,0x50, + 0x7,0x22,0x7d, 0x7,0x25,0x71, 0x4,0x49,0x70, 0x5,0x54,0x4c, + 0x5,0x54,0x4f, 0xf,0x4e,0x68, 0xf,0x54,0x4f, 0x5,0x54,0x50, + 0x5,0x54,0x52, 0x7,0x2d,0x7b, 0x7,0x2d,0x78, 0x5,0x54,0x55, + 0x5,0x54,0x56, 0x5,0x54,0x51, 0x7,0x2d,0x7e, 0x7,0x2d,0x7c, + 0x7,0x2d,0x7d, 0x5,0x54,0x57, 0x4,0x50,0x3d, 0x5,0x5b,0x49, + 0x7,0x2e,0x21, 0x7,0x37,0x7b, 0x7,0x37,0x7d, 0x7,0x37,0x7a, + 0x7,0x38,0x21, 0x5,0x5b,0x4b, 0x7,0x2d,0x7a, 0x7,0x37,0x79, + 0x7,0x2d,0x6e, 0xf,0x54,0x4d, 0x5,0x54,0x53, 0x7,0x38,0x22, + 0xf,0x54,0x49, 0xf,0x54,0x4e, 0xf,0x54,0x52, 0xf,0x5a,0x25, + 0xf,0x5a,0x26, 0xf,0x5a,0x2e, 0xf,0x5a,0x27, 0x5,0x5b,0x4a, + 0x5,0x54,0x58, 0xf,0x5a,0x2a, 0xf,0x54,0x4c, 0x7,0x37,0x78, + 0x5,0x5b,0x51, 0x4,0x56,0x35, 0x4,0x56,0x31, 0x4,0x5b,0x2a, + 0x5,0x5b,0x4e, 0x5,0x61,0x64, 0x5,0x61,0x62, 0x7,0x3f,0x5b, + 0x7,0x38,0x26, 0x4,0x5b,0x26, 0x5,0x5b,0x4d, 0x5,0x5b,0x4f, + 0x7,0x38,0x23, 0x7,0x38,0x25, 0x5,0x5b,0x50, 0x5,0x61,0x63, + 0x7,0x3f,0x5a, 0x5,0x61,0x65, 0x7,0x3f,0x59, 0x7,0x22,0x76, + 0xf,0x5a,0x2b, 0xf,0x5a,0x2d, 0xf,0x5e,0x5f, 0xf,0x5e,0x60, + 0xf,0x5e,0x62, 0xf,0x5e,0x63, 0xf,0x5e,0x65, 0xf,0x5e,0x66, + 0xf,0x5e,0x67, 0x7,0x3f,0x5c, 0x7,0x38,0x24, 0xf,0x5a,0x28, + 0x4,0x5b,0x27, 0x5,0x5b,0x52, 0x7,0x46,0x79, 0x7,0x3f,0x5d, + 0x5,0x61,0x68, 0x7,0x4d,0x64, 0x4,0x5f,0x63, 0x4,0x5f,0x62, + 0x7,0x46,0x7c, 0x5,0x61,0x69, 0x7,0x4d,0x67, 0x4,0x5b,0x28, + 0x5,0x61,0x6a, 0x7,0x47,0x25, 0x7,0x47,0x21, 0x7,0x46,0x78, + 0x5,0x61,0x67, 0x7,0x46,0x7e, 0x5,0x67,0x6d, 0x7,0x46,0x7a, + 0x5,0x67,0x70, 0x7,0x46,0x77, 0x7,0x47,0x22, 0x7,0x3f,0x5e, + 0x7,0x46,0x7d, 0x5,0x67,0x6e, 0xf,0x5e,0x64, 0x5,0x67,0x6f, + 0x7,0x46,0x7b, 0x5,0x67,0x6c, 0xf,0x62,0x39, 0x7,0x47,0x2a, + 0x4,0x63,0x44, 0x7,0x47,0x27, 0x5,0x67,0x74, 0x7,0x47,0x24, + 0x5,0x6c,0x2a, 0x7,0x47,0x29, 0x7,0x47,0x26, 0x7,0x3f,0x5f, + 0x5,0x67,0x75, 0x4,0x63,0x3f, 0x5,0x67,0x71, 0x5,0x6c,0x28, + 0x7,0x47,0x2b, 0x7,0x47,0x23, 0x7,0x4d,0x65, 0x5,0x67,0x77, + 0xf,0x62,0x3a, 0xf,0x62,0x38, 0xf,0x62,0x3b, 0xf,0x62,0x3c, + 0xf,0x62,0x3d, 0x7,0x4d,0x66, 0x5,0x61,0x66, 0x5,0x67,0x72, + 0xf,0x65,0x2b, 0x5,0x67,0x76, 0x5,0x6c,0x29, 0x7,0x53,0x39, + 0x7,0x4d,0x6a, 0x4,0x63,0x41, 0x7,0x4d,0x69, 0x4,0x63,0x45, + 0x7,0x53,0x38, 0x7,0x4d,0x6b, 0xf,0x67,0x55, 0x7,0x5b,0x4f, + 0x4,0x66,0x3e, 0x5,0x6c,0x2b, 0x7,0x57,0x73, 0x7,0x57,0x74, + 0x7,0x57,0x75, 0x7,0x53,0x3b, 0x7,0x53,0x3a, 0x7,0x53,0x3c, + 0xf,0x69,0x42, 0x7,0x57,0x76, 0x7,0x5b,0x50, 0x7,0x5b,0x52, + 0x7,0x5b,0x53, 0x7,0x5b,0x51, 0xf,0x6a,0x50, 0xf,0x69,0x41, + 0xf,0x6a,0x51, 0xf,0x6a,0x52, 0x7,0x5b,0x55, 0x5,0x77,0x5a, + 0x7,0x5b,0x54, 0x7,0x5e,0x65, 0xf,0x6a,0x53, 0xf,0x6b,0x47, + 0xf,0x6b,0x48, 0x5,0x77,0x5b, 0x7,0x5e,0x66, 0x5,0x79,0x29, + 0x7,0x5e,0x67, 0xf,0x6c,0x28, 0xf,0x6c,0x29, 0x4,0x6d,0x72, + 0xf,0x6c,0x7c, 0xf,0x6c,0x7d, 0x5,0x7b,0x3e, 0x5,0x7b,0x60, + 0xf,0x6d,0x34, 0x5,0x22,0x6a, 0x4,0x22,0x72, 0x6,0x24,0x76, + 0x6,0x27,0x6b, 0x5,0x24,0x3b, 0x6,0x27,0x6a, 0x6,0x27,0x6d, + 0x6,0x27,0x6c, 0x4,0x26,0x52, 0x6,0x2b,0x51, 0x6,0x2b,0x58, + 0x6,0x2b,0x54, 0x6,0x2b,0x56, 0x4,0x26,0x53, 0x6,0x2b,0x55, + 0x6,0x2b,0x53, 0x6,0x2b,0x57, 0xf,0x27,0x24, 0xf,0x27,0x23, + 0x6,0x31,0x3d, 0x6,0x31,0x3b, 0x6,0x31,0x3e, 0x6,0x31,0x40, + 0x4,0x29,0x4c, 0x6,0x31,0x41, 0x6,0x31,0x3f, 0xf,0x2a,0x71, + 0xf,0x2a,0x72, 0x6,0x31,0x3c, 0x6,0x37,0x67, 0x5,0x2d,0x5f, + 0x6,0x37,0x69, 0x5,0x2d,0x5e, 0x6,0x37,0x68, 0x5,0x32,0x61, + 0x4,0x31,0x6f, 0x6,0x40,0x25, 0xf,0x34,0x73, 0xf,0x34,0x74, + 0x6,0x40,0x24, 0x5,0x32,0x60, 0x6,0x49,0x28, 0x6,0x49,0x27, + 0x6,0x49,0x25, 0x6,0x49,0x26, 0x4,0x37,0x5c, 0x6,0x49,0x29, + 0xf,0x3b,0x2f, 0x5,0x38,0x5b, 0x5,0x38,0x5c, 0xf,0x34,0x76, + 0x4,0x3d,0x44, 0x6,0x52,0x71, 0x5,0x3f,0x47, 0x5,0x3f,0x49, + 0xf,0x41,0x55, 0x4,0x3d,0x41, 0x6,0x52,0x70, 0x5,0x3f,0x48, + 0x6,0x5d,0x29, 0x6,0x5d,0x2a, 0x5,0x45,0x7a, 0x5,0x45,0x7c, + 0x5,0x45,0x7b, 0x7,0x23,0x24, 0x5,0x45,0x7d, 0xf,0x48,0x29, + 0xf,0x48,0x2a, 0x6,0x5d,0x28, 0x5,0x4d,0x36, 0x4,0x49,0x73, + 0x4,0x49,0x74, 0x7,0x23,0x28, 0x7,0x23,0x27, 0x7,0x23,0x25, + 0x6,0x5d,0x2b, 0x7,0x23,0x23, 0xf,0x4e,0x7b, 0x7,0x23,0x29, + 0x7,0x23,0x26, 0xf,0x4e,0x77, 0xf,0x4e,0x78, 0xf,0x4e,0x7a, + 0x7,0x23,0x2a, 0x7,0x2e,0x2a, 0x7,0x2e,0x25, 0x7,0x2e,0x24, + 0x7,0x2e,0x27, 0x7,0x2e,0x26, 0x7,0x2e,0x29, 0x7,0x2e,0x28, + 0x7,0x2c,0x63, 0x7,0x31,0x70, 0x7,0x2e,0x23, 0x7,0x38,0x27, + 0x5,0x5b,0x53, 0xf,0x5a,0x2f, 0x7,0x3f,0x60, 0x7,0x47,0x2d, + 0x4,0x5f,0x65, 0x7,0x47,0x2e, 0x5,0x6c,0x2c, 0xf,0x65,0x2c, + 0x5,0x70,0x21, 0x7,0x53,0x3d, 0x6,0x23,0x27, 0x5,0x21,0x6d, + 0x6,0x24,0x77, 0x6,0x24,0x78, 0x4,0x24,0x34, 0xf,0x24,0x37, + 0xf,0x24,0x38, 0x5,0x26,0x39, 0x6,0x2b,0x59, 0x6,0x2b,0x5a, + 0x6,0x31,0x43, 0x6,0x31,0x42, 0x6,0x31,0x44, 0x5,0x29,0x39, + 0xf,0x2a,0x73, 0xf,0x2a,0x74, 0xf,0x2a,0x75, 0x6,0x31,0x46, + 0x6,0x31,0x45, 0x5,0x29,0x38, 0x6,0x37,0x6c, 0x6,0x37,0x6a, + 0x6,0x37,0x6b, 0x5,0x2d,0x61, 0x5,0x2d,0x60, 0x6,0x40,0x26, + 0xf,0x34,0x77, 0x5,0x38,0x5d, 0x5,0x38,0x5f, 0x5,0x38,0x60, + 0x5,0x38,0x5e, 0x5,0x3f,0x4a, 0x5,0x45,0x7e, 0x4,0x43,0x55, + 0x7,0x23,0x2b, 0x5,0x5b,0x54, 0x5,0x70,0x22, 0x6,0x23,0x28, + 0x5,0x21,0x6e, 0x6,0x23,0x29, 0x6,0x23,0x2a, 0x5,0x21,0x6f, + 0x5,0x22,0x6c, 0x4,0x22,0x76, 0x6,0x24,0x79, 0x5,0x22,0x72, + 0x5,0x22,0x70, 0x5,0x22,0x6f, 0x5,0x22,0x6b, 0x5,0x22,0x6d, + 0xf,0x22,0x50, 0xf,0x22,0x52, 0x5,0x22,0x71, 0x4,0x24,0x37, + 0x6,0x27,0x73, 0x6,0x27,0x76, 0x6,0x27,0x75, 0x4,0x26,0x57, + 0x5,0x24,0x3d, 0x6,0x27,0x6f, 0x4,0x24,0x38, 0x4,0x24,0x35, + 0x6,0x27,0x77, 0x5,0x24,0x3e, 0x4,0x24,0x3b, 0x6,0x27,0x72, + 0x6,0x2b,0x5d, 0x6,0x27,0x71, 0x6,0x2b,0x65, 0x6,0x2b,0x5b, + 0x6,0x27,0x70, 0x5,0x24,0x3c, 0x6,0x2b,0x5c, 0x6,0x27,0x74, + 0xf,0x24,0x3b, 0xf,0x24,0x3c, 0xf,0x24,0x3d, 0xf,0x24,0x3e, + 0xf,0x24,0x3f, 0xf,0x24,0x40, 0xf,0x24,0x41, 0xf,0x24,0x43, + 0xf,0x24,0x44, 0xf,0x24,0x45, 0xf,0x24,0x3a, 0x6,0x2b,0x5e, + 0x6,0x2b,0x5f, 0x6,0x2b,0x61, 0x5,0x26,0x3b, 0x5,0x29,0x3a, + 0x6,0x2b,0x64, 0x6,0x31,0x48, 0x5,0x26,0x3d, 0x6,0x31,0x4a, + 0x5,0x26,0x3c, 0x6,0x31,0x49, 0x6,0x31,0x47, 0x6,0x2b,0x62, + 0xf,0x27,0x26, 0xf,0x27,0x27, 0xf,0x27,0x28, 0xf,0x27,0x29, + 0xf,0x27,0x2a, 0xf,0x27,0x2b, 0xf,0x27,0x2c, 0xf,0x27,0x2d, + 0xf,0x27,0x2f, 0xf,0x27,0x25, 0x5,0x26,0x3e, 0x6,0x31,0x52, + 0x6,0x31,0x54, 0x4,0x29,0x58, 0x4,0x29,0x4f, 0x4,0x29,0x50, + 0x6,0x31,0x53, 0x6,0x37,0x6d, 0x5,0x29,0x3f, 0x5,0x29,0x42, + 0x5,0x29,0x41, 0x6,0x31,0x4d, 0x5,0x29,0x47, 0x4,0x2d,0x34, + 0x4,0x29,0x5c, 0x5,0x29,0x3e, 0x5,0x29,0x3d, 0x5,0x2d,0x63, + 0x4,0x29,0x53, 0x6,0x37,0x6e, 0x5,0x29,0x48, 0x4,0x29,0x5a, + 0x6,0x31,0x50, 0x5,0x29,0x40, 0x5,0x29,0x44, 0x6,0x31,0x4e, + 0x6,0x31,0x56, 0x6,0x31,0x4b, 0x5,0x29,0x43, 0x5,0x29,0x3c, + 0x6,0x31,0x55, 0x6,0x31,0x51, 0xf,0x2a,0x76, 0xf,0x2a,0x77, + 0xf,0x2a,0x78, 0xf,0x2a,0x79, 0xf,0x2a,0x7a, 0xf,0x2a,0x7b, + 0xf,0x2a,0x7c, 0xf,0x2a,0x7d, 0xf,0x2a,0x7e, 0xf,0x2b,0x21, + 0xf,0x2b,0x23, 0xf,0x2b,0x24, 0xf,0x2b,0x25, 0xf,0x2b,0x26, + 0xf,0x2b,0x27, 0xf,0x2b,0x28, 0xf,0x2b,0x29, 0xf,0x2b,0x2a, + 0xf,0x2f,0x53, 0xf,0x2f,0x5c, 0xf,0x2f,0x61, 0x6,0x31,0x4c, + 0xf,0x2b,0x22, 0x5,0x29,0x3b, 0x5,0x2d,0x62, 0x5,0x2d,0x64, + 0x4,0x2d,0x3d, 0x6,0x37,0x75, 0x4,0x2d,0x38, 0x5,0x2d,0x6d, + 0x5,0x2d,0x6b, 0x4,0x2d,0x39, 0x4,0x29,0x57, 0x4,0x2d,0x35, + 0x5,0x2d,0x6a, 0x6,0x37,0x7b, 0x6,0x37,0x70, 0x6,0x37,0x7d, + 0x6,0x37,0x73, 0x5,0x2d,0x69, 0x6,0x37,0x72, 0x6,0x37,0x77, + 0x4,0x2d,0x36, 0x6,0x37,0x78, 0x5,0x2d,0x6c, 0x5,0x2d,0x65, + 0x4,0x2d,0x37, 0x5,0x2d,0x67, 0x5,0x2d,0x68, 0x4,0x2d,0x3a, + 0x6,0x37,0x7a, 0x5,0x2d,0x66, 0x6,0x31,0x57, 0x6,0x37,0x76, + 0x6,0x40,0x27, 0x6,0x37,0x79, 0x6,0x37,0x74, 0x5,0x29,0x46, + 0x6,0x37,0x7c, 0x6,0x37,0x7e, 0xf,0x2f,0x4c, 0xf,0x2f,0x4d, + 0xf,0x2f,0x4e, 0xf,0x2f,0x4f, 0xf,0x2f,0x50, 0xf,0x2f,0x51, + 0xf,0x2f,0x52, 0xf,0x2f,0x55, 0xf,0x2f,0x56, 0xf,0x2f,0x57, + 0xf,0x2f,0x5a, 0xf,0x2f,0x5b, 0xf,0x2f,0x5d, 0xf,0x2f,0x5e, + 0xf,0x2f,0x60, 0xf,0x2f,0x62, 0x6,0x40,0x28, 0xf,0x2f,0x58, + 0x6,0x37,0x6f, 0xf,0x2f,0x54, 0x4,0x31,0x72, 0x4,0x31,0x73, + 0x4,0x37,0x5e, 0x5,0x32,0x69, 0x6,0x40,0x31, 0x5,0x2d,0x6e, + 0x6,0x40,0x37, 0x5,0x32,0x63, 0x4,0x31,0x74, 0x4,0x32,0x22, + 0x4,0x31,0x76, 0x5,0x32,0x62, 0x4,0x31,0x7d, 0x5,0x38,0x61, + 0x5,0x32,0x64, 0x6,0x40,0x34, 0x5,0x32,0x67, 0x6,0x40,0x35, + 0x6,0x40,0x2c, 0x6,0x40,0x29, 0x4,0x32,0x24, 0x6,0x49,0x2f, + 0x6,0x49,0x2a, 0x6,0x40,0x2a, 0x5,0x32,0x65, 0x6,0x49,0x2d, + 0x4,0x37,0x5d, 0x6,0x40,0x2f, 0x6,0x49,0x2c, 0x6,0x49,0x2b, + 0x5,0x32,0x68, 0x6,0x40,0x2d, 0x6,0x49,0x2e, 0x6,0x40,0x33, + 0x6,0x40,0x30, 0x4,0x31,0x75, 0x6,0x40,0x2e, 0xf,0x34,0x78, + 0xf,0x34,0x79, 0xf,0x34,0x7a, 0xf,0x34,0x7b, 0xf,0x34,0x7c, + 0xf,0x34,0x7e, 0xf,0x35,0x22, 0xf,0x35,0x23, 0xf,0x35,0x24, + 0xf,0x35,0x25, 0xf,0x35,0x26, 0xf,0x35,0x27, 0xf,0x35,0x28, + 0xf,0x35,0x29, 0xf,0x35,0x2a, 0xf,0x35,0x2b, 0xf,0x35,0x2c, + 0xf,0x35,0x2e, 0xf,0x35,0x2d, 0xf,0x35,0x2f, 0xf,0x35,0x30, + 0xf,0x3b,0x31, 0xf,0x34,0x7d, 0x5,0x32,0x66, 0x4,0x32,0x26, + 0xf,0x3b,0x41, 0x5,0x38,0x6b, 0x6,0x49,0x34, 0x4,0x37,0x69, + 0x6,0x49,0x3b, 0x6,0x49,0x36, 0x5,0x38,0x6d, 0x6,0x49,0x41, + 0x5,0x38,0x74, 0x6,0x49,0x31, 0x4,0x3d,0x51, 0x4,0x37,0x67, + 0x5,0x38,0x62, 0x5,0x38,0x6a, 0x4,0x37,0x5f, 0x5,0x38,0x68, + 0x4,0x37,0x63, 0x5,0x38,0x69, 0x4,0x37,0x6a, 0x5,0x38,0x66, + 0x4,0x37,0x6d, 0x5,0x38,0x6f, 0x4,0x37,0x66, 0x6,0x49,0x42, + 0x6,0x49,0x43, 0x6,0x49,0x3a, 0x5,0x38,0x71, 0x6,0x49,0x33, + 0x6,0x49,0x46, 0x6,0x49,0x37, 0x5,0x38,0x70, 0x4,0x37,0x6c, + 0x6,0x49,0x47, 0x6,0x49,0x32, 0x5,0x38,0x6c, 0x5,0x38,0x6e, + 0x6,0x49,0x44, 0x5,0x38,0x64, 0x6,0x49,0x3c, 0x6,0x49,0x45, + 0x6,0x49,0x40, 0x6,0x49,0x4c, 0x6,0x49,0x3f, 0x6,0x49,0x4d, + 0x6,0x49,0x48, 0x6,0x49,0x39, 0x5,0x38,0x72, 0x6,0x49,0x3d, + 0x5,0x38,0x73, 0x5,0x38,0x67, 0x6,0x49,0x38, 0x6,0x49,0x4b, + 0x5,0x38,0x65, 0x6,0x52,0x73, 0xf,0x3b,0x30, 0xf,0x3b,0x32, + 0xf,0x3b,0x34, 0xf,0x3b,0x35, 0xf,0x3b,0x36, 0xf,0x3b,0x37, + 0xf,0x3b,0x38, 0xf,0x3b,0x39, 0xf,0x3b,0x3a, 0xf,0x3b,0x3b, + 0xf,0x3b,0x3c, 0xf,0x3b,0x3d, 0xf,0x3b,0x3f, 0xf,0x3b,0x40, + 0xf,0x3b,0x42, 0xf,0x3b,0x43, 0xf,0x3b,0x44, 0xf,0x3b,0x45, + 0xf,0x3b,0x46, 0xf,0x3b,0x48, 0xf,0x3b,0x49, 0xf,0x3b,0x4a, + 0x6,0x52,0x74, 0x6,0x49,0x3e, 0x6,0x49,0x49, 0x6,0x49,0x35, + 0x5,0x38,0x63, 0xf,0x3b,0x47, 0x5,0x3f,0x52, 0x6,0x52,0x7b, + 0x4,0x3d,0x4b, 0x4,0x3d,0x49, 0x5,0x3f,0x55, 0x4,0x3d,0x46, + 0x6,0x52,0x78, 0x4,0x3d,0x4d, 0x4,0x3d,0x53, 0x4,0x3d,0x47, + 0x4,0x3d,0x52, 0x6,0x52,0x7e, 0x5,0x3f,0x51, 0x5,0x46,0x21, + 0x5,0x3f,0x4b, 0x6,0x5d,0x2c, 0x6,0x53,0x25, 0x6,0x52,0x75, + 0x6,0x53,0x23, 0x6,0x53,0x22, 0x5,0x3f,0x4d, 0x5,0x3f,0x53, + 0x5,0x3f,0x4e, 0x6,0x52,0x79, 0x6,0x53,0x21, 0x5,0x3f,0x50, + 0x6,0x53,0x24, 0x6,0x52,0x7c, 0x5,0x3f,0x4c, 0x6,0x52,0x7a, + 0x5,0x3f,0x4f, 0xf,0x41,0x56, 0xf,0x41,0x57, 0xf,0x41,0x58, + 0xf,0x41,0x59, 0xf,0x41,0x5a, 0xf,0x41,0x5b, 0xf,0x41,0x5c, + 0xf,0x41,0x5d, 0xf,0x41,0x5e, 0xf,0x41,0x60, 0xf,0x41,0x61, + 0xf,0x41,0x63, 0xf,0x41,0x64, 0xf,0x41,0x65, 0xf,0x41,0x66, + 0xf,0x41,0x67, 0xf,0x41,0x69, 0xf,0x48,0x30, 0x6,0x52,0x77, + 0x6,0x52,0x7d, 0x6,0x52,0x76, 0xf,0x41,0x68, 0x5,0x3f,0x54, + 0x6,0x5d,0x36, 0x5,0x4d,0x39, 0x5,0x46,0x27, 0x5,0x46,0x2a, + 0x4,0x43,0x62, 0x4,0x43,0x5f, 0x6,0x5d,0x3c, 0x6,0x5d,0x3d, + 0x6,0x5d,0x2e, 0x4,0x43,0x57, 0x6,0x5d,0x3f, 0x5,0x46,0x26, + 0x4,0x43,0x63, 0x5,0x4d,0x38, 0x5,0x46,0x29, 0x6,0x5d,0x35, + 0x4,0x43,0x59, 0x7,0x23,0x2f, 0x4,0x43,0x5b, 0x4,0x43,0x5a, + 0x7,0x23,0x2e, 0x7,0x23,0x31, 0x5,0x46,0x24, 0x4,0x43,0x65, + 0x6,0x5d,0x39, 0x6,0x5d,0x3e, 0x6,0x5d,0x3a, 0x5,0x46,0x28, + 0x6,0x5d,0x37, 0x5,0x46,0x2b, 0x7,0x23,0x2c, 0x6,0x5d,0x3b, + 0x6,0x5d,0x33, 0x6,0x5d,0x31, 0x5,0x46,0x22, 0x4,0x43,0x60, + 0x6,0x5d,0x2f, 0x6,0x5d,0x34, 0xf,0x48,0x2b, 0xf,0x48,0x2c, + 0xf,0x48,0x2d, 0xf,0x48,0x2e, 0xf,0x48,0x2f, 0xf,0x48,0x33, + 0xf,0x48,0x34, 0xf,0x48,0x35, 0xf,0x48,0x37, 0xf,0x48,0x38, + 0xf,0x48,0x3a, 0xf,0x48,0x3b, 0xf,0x48,0x39, 0xf,0x48,0x3c, + 0xf,0x48,0x3d, 0xf,0x48,0x3e, 0xf,0x48,0x3f, 0xf,0x48,0x40, + 0xf,0x48,0x41, 0xf,0x48,0x42, 0xf,0x48,0x43, 0xf,0x48,0x44, + 0xf,0x48,0x45, 0xf,0x48,0x47, 0xf,0x48,0x48, 0xf,0x48,0x49, + 0xf,0x48,0x46, 0x6,0x5d,0x30, 0xf,0x48,0x36, 0x7,0x23,0x33, + 0x7,0x23,0x38, 0x5,0x4d,0x3c, 0x4,0x4a,0x25, 0x7,0x23,0x3d, + 0x7,0x23,0x37, 0x7,0x23,0x39, 0x4,0x49,0x7b, 0x4,0x49,0x78, + 0x5,0x4d,0x3d, 0x5,0x4d,0x3b, 0x7,0x23,0x45, 0x4,0x49,0x7d, + 0x7,0x2e,0x2f, 0x4,0x4a,0x21, 0x5,0x4d,0x41, 0x4,0x4a,0x26, + 0x4,0x49,0x7c, 0x5,0x54,0x59, 0x7,0x2e,0x3c, 0x7,0x23,0x35, + 0x7,0x23,0x34, 0x7,0x2e,0x2d, 0x7,0x2e,0x2b, 0x7,0x23,0x44, + 0x7,0x2e,0x2c, 0x7,0x23,0x3c, 0x5,0x4d,0x40, 0x7,0x2e,0x2e, + 0x5,0x4d,0x3f, 0x7,0x23,0x3b, 0x7,0x23,0x42, 0x7,0x23,0x43, + 0x7,0x23,0x3e, 0x7,0x23,0x41, 0x4,0x49,0x77, 0xf,0x48,0x31, + 0x7,0x23,0x32, 0x7,0x23,0x3f, 0x7,0x23,0x40, 0xf,0x4e,0x7c, + 0xf,0x4e,0x7d, 0xf,0x4e,0x7e, 0xf,0x4f,0x21, 0xf,0x4f,0x22, + 0xf,0x4f,0x23, 0xf,0x4f,0x26, 0xf,0x4f,0x27, 0xf,0x4f,0x28, + 0xf,0x4f,0x29, 0xf,0x4f,0x2a, 0xf,0x4f,0x2b, 0xf,0x4f,0x2d, + 0xf,0x4f,0x2e, 0xf,0x4f,0x2f, 0xf,0x4f,0x30, 0xf,0x54,0x5f, + 0xf,0x4f,0x24, 0x4,0x56,0x38, 0x4,0x50,0x41, 0x7,0x2e,0x35, + 0x7,0x2e,0x30, 0x5,0x54,0x5a, 0x5,0x54,0x5b, 0x7,0x2e,0x3e, + 0x7,0x2e,0x3a, 0x7,0x2e,0x32, 0x7,0x23,0x36, 0x4,0x50,0x3e, + 0x4,0x50,0x43, 0x4,0x50,0x40, 0x5,0x54,0x5d, 0x4,0x50,0x3f, + 0x7,0x2e,0x3d, 0x4,0x50,0x46, 0x7,0x2e,0x3b, 0x4,0x50,0x48, + 0x4,0x50,0x42, 0x4,0x50,0x47, 0x7,0x2e,0x39, 0x7,0x2e,0x31, + 0x7,0x2e,0x40, 0x7,0x38,0x29, 0x7,0x2e,0x38, 0x5,0x54,0x5f, + 0x5,0x54,0x5c, 0x7,0x2e,0x37, 0x7,0x38,0x28, 0x7,0x2e,0x33, + 0x7,0x2e,0x3f, 0xf,0x54,0x55, 0xf,0x54,0x56, 0xf,0x54,0x57, + 0xf,0x54,0x58, 0xf,0x54,0x59, 0xf,0x54,0x5a, 0xf,0x54,0x5b, + 0xf,0x54,0x5c, 0xf,0x54,0x5d, 0xf,0x54,0x5e, 0xf,0x54,0x60, + 0x7,0x2e,0x34, 0x7,0x2e,0x36, 0x4,0x50,0x44, 0xf,0x54,0x54, + 0x5,0x5b,0x56, 0x7,0x38,0x31, 0x5,0x5b,0x57, 0x7,0x38,0x36, + 0x4,0x56,0x3b, 0x7,0x38,0x2f, 0x7,0x38,0x35, 0x4,0x56,0x3a, + 0x7,0x38,0x34, 0x7,0x38,0x2c, 0x5,0x5b,0x58, 0x4,0x56,0x37, + 0x5,0x5b,0x55, 0x7,0x38,0x2a, 0x7,0x38,0x37, 0x7,0x38,0x30, + 0x7,0x38,0x2e, 0x7,0x38,0x32, 0x7,0x38,0x38, 0x7,0x38,0x2b, + 0x7,0x38,0x2d, 0xf,0x5a,0x30, 0xf,0x5a,0x31, 0xf,0x5a,0x32, + 0xf,0x5a,0x33, 0xf,0x5a,0x34, 0xf,0x5a,0x35, 0x7,0x38,0x33, + 0x4,0x5b,0x33, 0x4,0x5b,0x38, 0x5,0x61,0x6e, 0x5,0x61,0x6b, + 0x5,0x61,0x6c, 0x5,0x61,0x6d, 0x7,0x3f,0x68, 0x7,0x3f,0x67, + 0x4,0x5b,0x35, 0x4,0x5b,0x37, 0x5,0x67,0x7a, 0x5,0x6c,0x2d, + 0x7,0x3f,0x69, 0x7,0x3f,0x66, 0x4,0x5b,0x34, 0x7,0x3f,0x63, + 0x7,0x3f,0x65, 0x7,0x47,0x2f, 0x7,0x3f,0x61, 0x7,0x3f,0x64, + 0xf,0x5e,0x68, 0xf,0x5e,0x69, 0xf,0x5e,0x6a, 0xf,0x5e,0x6d, + 0xf,0x5e,0x6e, 0xf,0x5e,0x6f, 0xf,0x5e,0x71, 0xf,0x5e,0x72, + 0xf,0x5e,0x74, 0xf,0x5e,0x6c, 0xf,0x5e,0x6b, 0x4,0x5f,0x66, + 0x4,0x5f,0x68, 0x4,0x5f,0x67, 0x4,0x5f,0x69, 0x5,0x6c,0x2f, + 0x7,0x47,0x32, 0x7,0x47,0x34, 0x7,0x47,0x36, 0x5,0x67,0x7b, + 0x7,0x47,0x30, 0x5,0x6c,0x2e, 0x7,0x47,0x38, 0x4,0x5f,0x6b, + 0x7,0x47,0x35, 0x7,0x47,0x33, 0x7,0x47,0x31, 0x4,0x5f,0x6a, + 0x5,0x67,0x79, 0xf,0x62,0x3e, 0xf,0x62,0x3f, 0xf,0x62,0x40, + 0xf,0x62,0x41, 0xf,0x62,0x42, 0xf,0x62,0x43, 0xf,0x62,0x44, + 0xf,0x62,0x45, 0xf,0x62,0x46, 0xf,0x62,0x49, 0xf,0x65,0x2f, + 0x7,0x3f,0x6a, 0x7,0x47,0x37, 0xf,0x62,0x47, 0x5,0x6c,0x32, + 0x4,0x66,0x3f, 0x7,0x4d,0x6d, 0x4,0x63,0x48, 0x7,0x4d,0x6c, + 0x4,0x63,0x49, 0x7,0x4d,0x70, 0x4,0x63,0x4a, 0x7,0x4d,0x6e, + 0x5,0x6c,0x33, 0x5,0x6c,0x30, 0x5,0x6c,0x31, 0x7,0x4d,0x6f, + 0xf,0x65,0x2d, 0xf,0x65,0x2e, 0xf,0x65,0x30, 0x7,0x53,0x44, + 0x7,0x57,0x77, 0x4,0x66,0x41, 0x7,0x53,0x3f, 0x7,0x53,0x43, + 0x7,0x53,0x42, 0x4,0x66,0x42, 0x5,0x73,0x45, 0x7,0x53,0x41, + 0x7,0x53,0x40, 0xf,0x67,0x56, 0xf,0x67,0x57, 0xf,0x67,0x58, + 0xf,0x67,0x59, 0x7,0x57,0x78, 0x7,0x57,0x79, 0x5,0x73,0x44, + 0x5,0x73,0x47, 0x5,0x70,0x23, 0x7,0x57,0x7a, 0x5,0x73,0x42, + 0x5,0x73,0x46, 0x7,0x57,0x7c, 0x7,0x5b,0x57, 0x7,0x53,0x3e, + 0xf,0x69,0x43, 0xf,0x69,0x44, 0x5,0x73,0x43, 0x7,0x57,0x7b, + 0x7,0x5b,0x58, 0xf,0x6a,0x54, 0xf,0x6a,0x55, 0xf,0x6a,0x56, + 0x7,0x5e,0x6a, 0x5,0x77,0x5d, 0x7,0x5e,0x69, 0x4,0x6b,0x6b, + 0x7,0x5e,0x6b, 0x5,0x77,0x5c, 0x7,0x5e,0x68, 0xf,0x6b,0x49, + 0xf,0x6b,0x4a, 0xf,0x6b,0x4b, 0xf,0x6b,0x4c, 0x7,0x62,0x38, + 0xf,0x6c,0x2a, 0xf,0x6c,0x2b, 0x4,0x6d,0x73, 0x7,0x63,0x53, + 0xf,0x6c,0x61, 0x7,0x66,0x26, 0x4,0x22,0x77, 0x4,0x24,0x3d, + 0x4,0x26,0x5a, 0xf,0x27,0x31, 0xf,0x27,0x32, 0xf,0x27,0x33, + 0x6,0x31,0x58, 0x6,0x38,0x22, 0x5,0x2f,0x5c, 0x4,0x2d,0x3e, + 0x6,0x38,0x21, 0x6,0x36,0x44, 0x6,0x40,0x39, 0x6,0x40,0x38, + 0x6,0x49,0x4f, 0x6,0x49,0x4e, 0xf,0x3b,0x4c, 0xf,0x3b,0x4d, + 0x5,0x38,0x75, 0x6,0x53,0x26, 0xf,0x41,0x6a, 0x6,0x53,0x27, + 0x5,0x46,0x2d, 0x6,0x5d,0x40, 0x7,0x23,0x46, 0x7,0x23,0x47, + 0x5,0x54,0x60, 0xf,0x54,0x61, 0x7,0x38,0x3b, 0x7,0x38,0x3a, + 0x5,0x5b,0x59, 0x7,0x38,0x3c, 0x7,0x4d,0x71, 0x5,0x24,0x3f, + 0x6,0x27,0x79, 0x5,0x24,0x40, 0x6,0x27,0x7a, 0x5,0x24,0x41, + 0x6,0x27,0x78, 0x6,0x2b,0x68, 0x4,0x26,0x60, 0x5,0x26,0x42, + 0x5,0x26,0x40, 0x4,0x26,0x5d, 0x6,0x2b,0x6c, 0x6,0x2b,0x66, + 0x6,0x2b,0x6a, 0x6,0x2b,0x69, 0x6,0x2b,0x67, 0x5,0x26,0x3f, + 0x5,0x26,0x41, 0x4,0x26,0x5c, 0x4,0x29,0x60, 0x6,0x31,0x59, + 0x5,0x29,0x4c, 0x5,0x29,0x4b, 0x6,0x31,0x5c, 0x6,0x31,0x5e, + 0x6,0x31,0x5d, 0x5,0x29,0x49, 0x5,0x29,0x4a, 0x4,0x29,0x5e, + 0x4,0x29,0x5f, 0x6,0x31,0x5b, 0x6,0x38,0x23, 0x6,0x38,0x24, + 0x6,0x38,0x26, 0x5,0x2d,0x72, 0x6,0x31,0x5f, 0x4,0x2d,0x45, + 0x6,0x38,0x28, 0x5,0x2d,0x70, 0x6,0x38,0x2a, 0x5,0x2d,0x6f, + 0x5,0x2d,0x74, 0x6,0x38,0x25, 0x5,0x2d,0x73, 0x5,0x2d,0x71, + 0x6,0x38,0x29, 0x6,0x38,0x27, 0x4,0x2d,0x41, 0x5,0x32,0x6d, + 0x6,0x40,0x40, 0x4,0x32,0x2e, 0x6,0x40,0x3a, 0x6,0x40,0x3b, + 0x6,0x40,0x3d, 0x5,0x32,0x6f, 0x5,0x32,0x70, 0x4,0x32,0x30, + 0x6,0x40,0x3e, 0x6,0x40,0x3c, 0x5,0x32,0x6b, 0x6,0x40,0x41, + 0x4,0x32,0x31, 0x4,0x32,0x2a, 0x4,0x32,0x2d, 0x4,0x32,0x29, + 0x5,0x32,0x6e, 0xf,0x35,0x31, 0xf,0x35,0x32, 0xf,0x35,0x33, + 0xf,0x35,0x34, 0xf,0x35,0x35, 0x5,0x32,0x6a, 0x6,0x40,0x3f, + 0x6,0x49,0x58, 0x5,0x39,0x22, 0x6,0x49,0x55, 0x4,0x37,0x7a, + 0x4,0x37,0x7b, 0x6,0x49,0x59, 0x6,0x49,0x54, 0x6,0x49,0x5a, + 0x5,0x38,0x76, 0x5,0x38,0x7e, 0x5,0x39,0x21, 0x5,0x38,0x7d, + 0x5,0x38,0x77, 0x6,0x49,0x56, 0x5,0x38,0x7b, 0x6,0x49,0x51, + 0x6,0x49,0x50, 0x6,0x49,0x53, 0x4,0x37,0x72, 0x4,0x37,0x73, + 0x4,0x37,0x74, 0x5,0x38,0x78, 0x5,0x38,0x79, 0x5,0x32,0x6c, + 0x6,0x49,0x52, 0x6,0x53,0x2f, 0x5,0x38,0x7a, 0x5,0x3f,0x57, + 0x5,0x3f,0x5a, 0x5,0x3f,0x5c, 0x4,0x3d,0x57, 0x4,0x3d,0x5f, + 0x6,0x53,0x2b, 0x6,0x53,0x2e, 0x6,0x53,0x29, 0x5,0x3f,0x5b, + 0x6,0x53,0x30, 0x6,0x53,0x2d, 0x6,0x53,0x28, 0x4,0x3d,0x60, + 0x5,0x3f,0x56, 0x6,0x53,0x31, 0x5,0x3f,0x59, 0x4,0x3d,0x5e, + 0x4,0x3d,0x55, 0x4,0x3d,0x56, 0x4,0x3d,0x58, 0x5,0x3f,0x58, + 0x6,0x53,0x2a, 0xf,0x41,0x6b, 0x6,0x53,0x2c, 0x5,0x32,0x71, + 0x4,0x3d,0x5a, 0x6,0x55,0x60, 0x5,0x46,0x34, 0x6,0x5d,0x49, + 0x5,0x46,0x32, 0x6,0x5d,0x41, 0x4,0x43,0x68, 0x5,0x46,0x31, + 0x6,0x5d,0x42, 0x5,0x46,0x2f, 0x6,0x5d,0x46, 0x5,0x46,0x37, + 0x5,0x46,0x35, 0x6,0x5d,0x47, 0x6,0x5d,0x45, 0x6,0x5d,0x44, + 0x6,0x5d,0x48, 0x6,0x5d,0x43, 0x6,0x5d,0x4a, 0x5,0x46,0x33, + 0x4,0x43,0x67, 0x5,0x46,0x36, 0x6,0x5d,0x4b, 0x5,0x48,0x25, + 0x5,0x4d,0x42, 0x5,0x4d,0x47, 0x4,0x4a,0x2c, 0x7,0x23,0x4e, + 0x7,0x23,0x49, 0x7,0x23,0x48, 0x5,0x4d,0x46, 0x7,0x23,0x52, + 0x7,0x23,0x4f, 0x7,0x23,0x4d, 0x5,0x4d,0x45, 0x7,0x23,0x50, + 0x5,0x4d,0x43, 0x5,0x4d,0x44, 0xf,0x4f,0x31, 0x7,0x23,0x4b, + 0x7,0x23,0x4c, 0x7,0x23,0x4a, 0x4,0x50,0x4b, 0x7,0x2e,0x42, + 0x7,0x2e,0x46, 0x7,0x2e,0x48, 0xf,0x54,0x62, 0x5,0x54,0x61, + 0x7,0x2e,0x4b, 0x7,0x2e,0x47, 0x7,0x2e,0x49, 0x7,0x2e,0x41, + 0x7,0x2e,0x45, 0x7,0x2e,0x4c, 0x5,0x54,0x63, 0x7,0x2e,0x4a, + 0x4,0x50,0x4a, 0x5,0x54,0x64, 0x5,0x54,0x65, 0x5,0x54,0x66, + 0xf,0x54,0x63, 0x7,0x2e,0x44, 0x5,0x54,0x62, 0x7,0x23,0x51, + 0x5,0x54,0x67, 0x7,0x38,0x3e, 0x7,0x38,0x3d, 0x5,0x5b,0x5a, + 0x5,0x5b,0x5e, 0x5,0x5b,0x5d, 0x4,0x56,0x3c, 0x4,0x56,0x3d, + 0x5,0x5b,0x5b, 0xf,0x5a,0x37, 0xf,0x5a,0x38, 0x7,0x38,0x3f, + 0x5,0x5b,0x5c, 0x5,0x61,0x70, 0x7,0x3f,0x6c, 0x5,0x61,0x6f, + 0x4,0x5b,0x3b, 0x7,0x3f,0x6d, 0x7,0x3f,0x6e, 0x4,0x5b,0x39, + 0x7,0x3f,0x6b, 0x5,0x68,0x21, 0x5,0x67,0x7e, 0x5,0x67,0x7c, + 0x5,0x67,0x7d, 0xf,0x62,0x4a, 0x5,0x6c,0x34, 0x4,0x63,0x4d, + 0x5,0x6c,0x35, 0x7,0x4d,0x72, 0x4,0x63,0x4b, 0x7,0x4d,0x75, + 0x7,0x4d,0x74, 0x5,0x6c,0x36, 0x7,0x4d,0x76, 0x7,0x4d,0x77, + 0x4,0x66,0x44, 0x5,0x70,0x25, 0x5,0x70,0x26, 0x5,0x73,0x48, + 0xf,0x69,0x45, 0x7,0x5b,0x59, 0x5,0x75,0x6b, 0x4,0x6a,0x4a, + 0x7,0x5b,0x5a, 0x4,0x6c,0x6f, 0xf,0x6c,0x62, 0xf,0x22,0x53, + 0xf,0x24,0x46, 0x6,0x2b,0x6d, 0xf,0x2b,0x2d, 0xf,0x2b,0x2e, + 0xf,0x2b,0x2f, 0x6,0x38,0x2d, 0x6,0x38,0x2e, 0xf,0x2f,0x65, + 0x6,0x40,0x42, 0x6,0x40,0x44, 0xf,0x35,0x37, 0xf,0x35,0x38, + 0x6,0x40,0x43, 0xf,0x3b,0x4e, 0x5,0x3f,0x5d, 0xf,0x41,0x6c, + 0x6,0x53,0x32, 0xf,0x35,0x36, 0x5,0x4d,0x48, 0x7,0x23,0x54, + 0x7,0x23,0x53, 0x5,0x4d,0x49, 0xf,0x4f,0x33, 0xf,0x4f,0x34, + 0x5,0x4d,0x4a, 0x7,0x2e,0x4d, 0xf,0x5a,0x39, 0xf,0x5e,0x75, + 0xf,0x62,0x4b, 0xf,0x67,0x5a, 0x7,0x5b,0x5b, 0x6,0x22,0x22, + 0xf,0x27,0x34, 0x6,0x31,0x60, 0x4,0x2d,0x48, 0x5,0x2d,0x76, + 0x5,0x2d,0x75, 0x6,0x38,0x2f, 0x5,0x32,0x72, 0xf,0x35,0x39, + 0x6,0x40,0x46, 0x6,0x40,0x45, 0x6,0x49,0x5d, 0xf,0x40,0x32, + 0x6,0x49,0x5b, 0x6,0x49,0x5c, 0x4,0x3d,0x61, 0x6,0x5d,0x4c, + 0x5,0x3f,0x5e, 0xf,0x41,0x6d, 0x4,0x43,0x6a, 0x4,0x4a,0x2d, + 0x7,0x23,0x55, 0x7,0x38,0x40, 0x4,0x5f,0x6c, 0x6,0x22,0x23, + 0xf,0x24,0x47, 0x6,0x2b,0x6f, 0x6,0x2b,0x6e, 0x6,0x31,0x61, + 0xf,0x2f,0x66, 0x4,0x32,0x32, 0x6,0x40,0x48, 0x6,0x40,0x47, + 0x6,0x49,0x60, 0x6,0x49,0x64, 0x6,0x49,0x63, 0x5,0x39,0x23, + 0x6,0x49,0x66, 0x6,0x49,0x5f, 0x6,0x49,0x5e, 0x6,0x49,0x62, + 0x4,0x37,0x7c, 0x6,0x4c,0x3e, 0x6,0x49,0x65, 0x4,0x3d,0x62, + 0x6,0x53,0x36, 0x6,0x53,0x34, 0x6,0x53,0x37, 0x5,0x3f,0x5f, + 0x6,0x5d,0x4f, 0x6,0x5d,0x4e, 0x6,0x5d,0x50, 0x3,0x47,0x31, + 0x4,0x4a,0x2f, 0x6,0x5d,0x4d, 0x5,0x4d,0x4c, 0x5,0x4d,0x4d, + 0x7,0x2e,0x51, 0x7,0x2e,0x50, 0x7,0x2e,0x4f, 0x7,0x2e,0x52, + 0x7,0x2e,0x4e, 0x4,0x50,0x4d, 0x7,0x38,0x41, 0x7,0x38,0x42, + 0x7,0x3f,0x6f, 0x4,0x5b,0x3c, 0x7,0x3f,0x70, 0x7,0x3f,0x71, + 0x7,0x47,0x39, 0xf,0x62,0x4c, 0x7,0x4d,0x78, 0x7,0x57,0x7d, + 0x4,0x24,0x42, 0x6,0x27,0x7b, 0xf,0x27,0x35, 0xf,0x27,0x36, + 0x5,0x29,0x4d, 0x6,0x31,0x64, 0x6,0x31,0x63, 0xf,0x2b,0x30, + 0x6,0x31,0x62, 0x4,0x2d,0x4a, 0x5,0x2d,0x77, 0x6,0x38,0x31, + 0x6,0x38,0x33, 0x6,0x38,0x35, 0xf,0x2f,0x67, 0xf,0x2f,0x68, + 0xf,0x2f,0x69, 0xf,0x2f,0x6a, 0x6,0x38,0x32, 0x4,0x32,0x33, + 0x4,0x32,0x35, 0x6,0x40,0x4a, 0xf,0x35,0x3a, 0xf,0x35,0x3b, + 0x6,0x40,0x49, 0x6,0x49,0x69, 0x5,0x39,0x25, 0x5,0x39,0x24, + 0x6,0x49,0x68, 0x6,0x49,0x6a, 0x6,0x49,0x67, 0xf,0x3b,0x4f, + 0xf,0x3b,0x50, 0x6,0x53,0x38, 0x5,0x3f,0x60, 0x6,0x53,0x39, + 0xf,0x41,0x6e, 0xf,0x41,0x6f, 0x5,0x46,0x38, 0x5,0x46,0x3a, + 0x6,0x5d,0x52, 0x5,0x46,0x39, 0x7,0x23,0x56, 0xf,0x4f,0x35, + 0x7,0x2e,0x53, 0x5,0x54,0x68, 0x7,0x38,0x43, 0x5,0x5b,0x5f, + 0x7,0x3f,0x73, 0x5,0x61,0x71, 0x4,0x5b,0x3d, 0x7,0x3f,0x74, + 0x7,0x3f,0x72, 0x7,0x47,0x3a, 0x7,0x53,0x45, 0x4,0x68,0x6d, + 0x7,0x57,0x7e, 0x7,0x5e,0x6c, 0x7,0x60,0x70, 0x5,0x24,0x42, + 0x5,0x29,0x4e, 0x5,0x2d,0x79, 0x5,0x2d,0x78, 0x4,0x37,0x7d, + 0x6,0x49,0x6b, 0x6,0x53,0x3a, 0x6,0x53,0x3b, 0x4,0x3d,0x66, + 0xf,0x4f,0x36, 0x6,0x23,0x2c, 0x6,0x23,0x2b, 0x6,0x24,0x7b, + 0x5,0x22,0x73, 0x6,0x24,0x7a, 0x6,0x24,0x7c, 0xf,0x22,0x54, + 0xf,0x24,0x4b, 0x6,0x27,0x7c, 0x6,0x27,0x7d, 0x6,0x28,0x25, + 0x5,0x24,0x43, 0x6,0x28,0x22, 0x6,0x27,0x7e, 0x6,0x28,0x24, + 0x6,0x28,0x23, 0x6,0x28,0x21, 0xf,0x24,0x48, 0xf,0x24,0x4a, + 0xf,0x24,0x4c, 0x4,0x24,0x44, 0x5,0x26,0x48, 0x6,0x2b,0x74, + 0x6,0x2b,0x73, 0x5,0x26,0x49, 0x6,0x2b,0x7d, 0x5,0x26,0x44, + 0x6,0x2b,0x79, 0x5,0x26,0x47, 0x6,0x2b,0x7a, 0x6,0x2b,0x77, + 0x5,0x26,0x46, 0x5,0x26,0x45, 0x6,0x2b,0x75, 0x6,0x2b,0x78, + 0xf,0x27,0x37, 0xf,0x27,0x38, 0xf,0x27,0x39, 0xf,0x27,0x3a, + 0xf,0x27,0x3b, 0xf,0x27,0x3c, 0xf,0x27,0x3d, 0x6,0x2b,0x71, + 0x6,0x2b,0x7b, 0x6,0x2b,0x7c, 0x6,0x2b,0x72, 0x6,0x2b,0x76, + 0x5,0x29,0x51, 0x6,0x31,0x65, 0x6,0x31,0x66, 0x5,0x29,0x50, + 0x4,0x29,0x66, 0x6,0x31,0x68, 0x6,0x31,0x69, 0x4,0x29,0x68, + 0xf,0x2b,0x31, 0xf,0x2b,0x32, 0x6,0x31,0x6a, 0xf,0x2b,0x35, + 0xf,0x2b,0x36, 0x6,0x31,0x6e, 0x6,0x31,0x6c, 0x6,0x31,0x6b, + 0x5,0x2d,0x7e, 0x6,0x38,0x3a, 0x5,0x2e,0x21, 0x5,0x2e,0x22, + 0x5,0x2d,0x7b, 0x5,0x2e,0x23, 0x5,0x2d,0x7c, 0x5,0x2d,0x7a, + 0x6,0x38,0x3e, 0x6,0x38,0x38, 0x6,0x38,0x3c, 0x5,0x2d,0x7d, + 0x6,0x38,0x39, 0x6,0x38,0x3d, 0xf,0x2f,0x6b, 0xf,0x2f,0x6d, + 0x6,0x38,0x3b, 0xf,0x2f,0x6c, 0x6,0x38,0x41, 0x6,0x38,0x3f, + 0x5,0x32,0x73, 0x4,0x32,0x38, 0x4,0x38,0x21, 0x6,0x40,0x53, + 0x4,0x32,0x3d, 0x6,0x40,0x4e, 0x6,0x40,0x4b, 0x6,0x40,0x4c, + 0x6,0x40,0x50, 0x6,0x40,0x4d, 0x6,0x40,0x55, 0x5,0x32,0x75, + 0x6,0x38,0x40, 0x6,0x40,0x54, 0x6,0x40,0x56, 0xf,0x35,0x3c, + 0xf,0x35,0x3d, 0xf,0x35,0x3e, 0xf,0x35,0x3f, 0xf,0x35,0x40, + 0xf,0x35,0x41, 0xf,0x35,0x42, 0xf,0x35,0x43, 0xf,0x35,0x44, + 0xf,0x35,0x45, 0xf,0x35,0x46, 0xf,0x35,0x47, 0x6,0x40,0x52, + 0x5,0x32,0x74, 0x6,0x49,0x71, 0x6,0x49,0x74, 0x4,0x32,0x3c, + 0x5,0x3f,0x61, 0x5,0x39,0x2a, 0x6,0x49,0x6f, 0x5,0x39,0x27, + 0x6,0x49,0x70, 0x5,0x39,0x29, 0x5,0x39,0x26, 0x6,0x49,0x6c, + 0x6,0x49,0x6d, 0x4,0x38,0x23, 0x6,0x49,0x76, 0x5,0x39,0x2b, + 0x4,0x38,0x27, 0x6,0x49,0x6e, 0x6,0x49,0x75, 0x6,0x49,0x77, + 0xf,0x3b,0x51, 0xf,0x3b,0x53, 0xf,0x3b,0x54, 0xf,0x3b,0x56, + 0xf,0x3b,0x57, 0xf,0x3b,0x59, 0xf,0x3b,0x5a, 0xf,0x3b,0x5c, + 0xf,0x3b,0x5d, 0xf,0x3b,0x52, 0xf,0x3b,0x58, 0x4,0x38,0x26, + 0x4,0x38,0x28, 0x6,0x49,0x72, 0x5,0x39,0x2c, 0x5,0x39,0x28, + 0x6,0x53,0x43, 0x5,0x3f,0x63, 0x6,0x53,0x41, 0x6,0x5d,0x53, + 0x6,0x53,0x42, 0x6,0x53,0x3f, 0x6,0x53,0x44, 0xf,0x46,0x39, + 0xf,0x3b,0x5b, 0x6,0x53,0x3e, 0xf,0x41,0x70, 0xf,0x41,0x71, + 0xf,0x41,0x73, 0xf,0x41,0x74, 0xf,0x41,0x75, 0xf,0x41,0x76, + 0xf,0x41,0x77, 0xf,0x41,0x78, 0xf,0x41,0x79, 0xf,0x41,0x7a, + 0xf,0x41,0x7b, 0xf,0x41,0x7d, 0x5,0x3d,0x55, 0x6,0x53,0x45, + 0x6,0x53,0x40, 0x5,0x3f,0x64, 0x5,0x46,0x3b, 0x5,0x46,0x3f, + 0x5,0x46,0x3d, 0x5,0x46,0x3e, 0x6,0x5d,0x56, 0x5,0x46,0x40, + 0x5,0x46,0x43, 0x5,0x46,0x44, 0x4,0x43,0x6c, 0x5,0x46,0x42, + 0x5,0x4d,0x4e, 0xf,0x48,0x4a, 0xf,0x48,0x4b, 0xf,0x48,0x4c, + 0xf,0x48,0x4d, 0xf,0x48,0x4e, 0xf,0x48,0x4f, 0x6,0x5d,0x54, + 0x5,0x46,0x3c, 0x6,0x5d,0x57, 0x6,0x5d,0x59, 0x6,0x5d,0x5a, + 0x6,0x5d,0x55, 0x6,0x5d,0x58, 0x7,0x23,0x61, 0x7,0x23,0x5c, + 0x7,0x23,0x5b, 0x7,0x23,0x5e, 0x5,0x4d,0x52, 0x5,0x4d,0x55, + 0x7,0x23,0x5a, 0x7,0x23,0x57, 0x7,0x23,0x58, 0x7,0x23,0x62, + 0xf,0x4f,0x37, 0xf,0x4f,0x39, 0xf,0x4f,0x3a, 0x5,0x4d,0x54, + 0x7,0x23,0x60, 0xf,0x4e,0x30, 0x7,0x23,0x5d, 0x7,0x23,0x5f, + 0x7,0x23,0x59, 0x5,0x4d,0x51, 0x5,0x54,0x69, 0x5,0x54,0x6b, + 0x7,0x2e,0x57, 0x4,0x50,0x55, 0x7,0x2e,0x55, 0x7,0x2e,0x5b, + 0x7,0x2e,0x59, 0x7,0x2e,0x5d, 0x4,0x50,0x54, 0x7,0x2e,0x5c, + 0x7,0x2e,0x54, 0xf,0x54,0x65, 0xf,0x54,0x66, 0xf,0x54,0x67, + 0xf,0x54,0x69, 0xf,0x54,0x6a, 0x7,0x2e,0x58, 0x5,0x4d,0x4f, + 0x7,0x2d,0x62, 0xf,0x54,0x68, 0x7,0x2e,0x43, 0x5,0x54,0x6a, + 0x7,0x2e,0x56, 0xf,0x4f,0x38, 0x7,0x38,0x47, 0x5,0x5b,0x60, + 0x5,0x5b,0x61, 0x7,0x38,0x48, 0x5,0x5b,0x62, 0x7,0x38,0x45, + 0x7,0x38,0x46, 0x7,0x38,0x49, 0xf,0x5a,0x3a, 0xf,0x5a,0x3b, + 0xf,0x5a,0x3c, 0x7,0x38,0x44, 0xf,0x5a,0x3d, 0x4,0x5b,0x3e, + 0x5,0x61,0x72, 0x5,0x61,0x73, 0x7,0x3f,0x75, 0xf,0x5e,0x76, + 0xf,0x5e,0x77, 0xf,0x5e,0x78, 0xf,0x5e,0x79, 0xf,0x5e,0x7b, + 0x7,0x3f,0x78, 0x5,0x68,0x23, 0x7,0x47,0x3d, 0x7,0x47,0x3c, + 0x5,0x68,0x22, 0x5,0x68,0x24, 0x7,0x47,0x3b, 0x7,0x47,0x3e, + 0xf,0x62,0x4d, 0x5,0x6c,0x37, 0xf,0x65,0x31, 0xf,0x65,0x32, + 0x5,0x6b,0x6e, 0x7,0x4d,0x79, 0x7,0x53,0x46, 0x7,0x58,0x21, + 0xf,0x69,0x46, 0x5,0x73,0x39, 0x5,0x73,0x49, 0x7,0x5b,0x5c, + 0x5,0x77,0x5e, 0x7,0x5e,0x6d, 0xf,0x6b,0x4d, 0x5,0x79,0x2b, + 0x7,0x64,0x47, 0xf,0x24,0x4d, 0x6,0x2b,0x7e, 0xf,0x27,0x3f, + 0xf,0x27,0x40, 0x6,0x2c,0x21, 0x5,0x29,0x53, 0x5,0x29,0x52, + 0x6,0x31,0x70, 0xf,0x2b,0x37, 0xf,0x2b,0x39, 0x6,0x31,0x6f, + 0x6,0x38,0x42, 0xf,0x2f,0x6f, 0xf,0x2f,0x70, 0xf,0x2f,0x71, + 0xf,0x2f,0x72, 0xf,0x2f,0x73, 0xf,0x35,0x49, 0xf,0x35,0x4a, + 0xf,0x3b,0x5f, 0x6,0x49,0x7a, 0x6,0x49,0x79, 0x5,0x3f,0x65, + 0x4,0x43,0x70, 0x6,0x53,0x46, 0x5,0x4d,0x57, 0x5,0x4d,0x56, + 0x7,0x23,0x63, 0xf,0x54,0x6b, 0x5,0x5b,0x63, 0x7,0x3f,0x7a, + 0x5,0x61,0x74, 0x7,0x3f,0x79, 0x7,0x3f,0x77, 0x4,0x5f,0x6d, + 0x7,0x4d,0x7a, 0x7,0x4d,0x7b, 0x5,0x7b,0x3f, 0x7,0x66,0x3e, + 0x6,0x23,0x2d, 0x6,0x24,0x7d, 0x5,0x24,0x44, 0x6,0x28,0x29, + 0x6,0x28,0x27, 0x6,0x28,0x28, 0x6,0x28,0x26, 0x6,0x2c,0x22, + 0x5,0x29,0x54, 0x4,0x29,0x69, 0x4,0x29,0x6a, 0xf,0x2b,0x3a, + 0x6,0x31,0x71, 0x6,0x38,0x43, 0xf,0x35,0x4b, 0x5,0x32,0x76, + 0x6,0x40,0x59, 0x6,0x40,0x5b, 0x6,0x49,0x7d, 0x6,0x49,0x7c, + 0x6,0x40,0x5a, 0x5,0x39,0x2d, 0xf,0x39,0x46, 0xf,0x3b,0x61, + 0xf,0x3b,0x62, 0x6,0x53,0x47, 0x5,0x3f,0x67, 0xf,0x3b,0x60, + 0xf,0x41,0x7e, 0xf,0x42,0x21, 0x6,0x53,0x48, 0x6,0x5d,0x5d, + 0x6,0x5d,0x5e, 0x7,0x23,0x64, 0x4,0x4a,0x34, 0x5,0x4d,0x59, + 0x4,0x4a,0x33, 0xf,0x4f,0x3b, 0xf,0x4f,0x3c, 0x5,0x54,0x6e, + 0x5,0x54,0x6c, 0x5,0x5b,0x64, 0x5,0x54,0x6d, 0xf,0x54,0x6d, + 0xf,0x54,0x6e, 0x7,0x38,0x4b, 0x7,0x38,0x4a, 0xf,0x5a,0x3e, + 0x5,0x61,0x75, 0xf,0x5e,0x7c, 0x7,0x3f,0x7b, 0x5,0x6c,0x38, + 0x5,0x75,0x6f, 0x5,0x77,0x5f, 0x5,0x21,0x48, 0x4,0x21,0x4e, + 0x4,0x21,0x7d, 0xf,0x21,0x65, 0x5,0x22,0x75, 0x6,0x25,0x22, + 0x5,0x22,0x74, 0x6,0x24,0x7e, 0x6,0x25,0x21, 0xf,0x22,0x56, + 0x4,0x22,0x7b, 0x4,0x22,0x7a, 0x6,0x28,0x2c, 0x4,0x24,0x49, + 0x6,0x28,0x2a, 0x6,0x28,0x2b, 0xf,0x24,0x4e, 0xf,0x24,0x4f, + 0xf,0x24,0x54, 0xf,0x24,0x50, 0xf,0x24,0x52, 0x5,0x24,0x46, + 0x6,0x28,0x2d, 0x5,0x24,0x45, 0x4,0x24,0x45, 0x4,0x26,0x6b, + 0x5,0x26,0x4c, 0x4,0x26,0x66, 0x5,0x26,0x4b, 0x6,0x2c,0x2b, + 0x5,0x26,0x50, 0x5,0x26,0x52, 0x6,0x2c,0x28, 0x6,0x2c,0x27, + 0x6,0x2c,0x26, 0x5,0x26,0x4d, 0x5,0x26,0x53, 0x5,0x26,0x4f, + 0x5,0x26,0x4e, 0xf,0x27,0x43, 0xf,0x27,0x45, 0xf,0x27,0x46, + 0xf,0x27,0x47, 0xf,0x27,0x49, 0xf,0x27,0x4a, 0xf,0x27,0x4b, + 0xf,0x27,0x4d, 0xf,0x27,0x4f, 0xf,0x27,0x51, 0xf,0x27,0x54, + 0xf,0x27,0x55, 0x6,0x2c,0x24, 0x6,0x2c,0x29, 0x5,0x26,0x54, + 0x6,0x2c,0x2c, 0xf,0x27,0x44, 0x6,0x2c,0x2d, 0x6,0x2c,0x2a, + 0xf,0x27,0x48, 0xf,0x27,0x42, 0x6,0x2c,0x25, 0x5,0x26,0x55, + 0x6,0x2d,0x5c, 0x6,0x31,0x74, 0x6,0x31,0x73, 0x4,0x29,0x6b, + 0x5,0x29,0x56, 0x6,0x31,0x75, 0x6,0x31,0x76, 0x5,0x29,0x55, + 0x5,0x29,0x59, 0x6,0x31,0x77, 0x5,0x2e,0x26, 0x5,0x29,0x5a, + 0x5,0x29,0x58, 0xf,0x27,0x53, 0xf,0x2b,0x3b, 0xf,0x2b,0x3c, + 0xf,0x2b,0x3d, 0xf,0x2b,0x3f, 0xf,0x2b,0x40, 0xf,0x2b,0x41, + 0xf,0x2b,0x42, 0xf,0x2b,0x43, 0xf,0x2b,0x44, 0xf,0x2b,0x45, + 0xf,0x2b,0x46, 0xf,0x2b,0x47, 0xf,0x2b,0x49, 0xf,0x2b,0x4a, + 0xf,0x2b,0x4b, 0xf,0x2b,0x4c, 0xf,0x2b,0x4d, 0xf,0x2b,0x4e, + 0xf,0x2b,0x4f, 0x5,0x29,0x5b, 0x6,0x40,0x5c, 0x6,0x38,0x4f, + 0x6,0x38,0x53, 0x6,0x38,0x4b, 0x6,0x38,0x4d, 0x6,0x38,0x46, + 0x5,0x2e,0x27, 0x6,0x38,0x48, 0x6,0x38,0x45, 0x6,0x38,0x51, + 0x4,0x2d,0x50, 0x6,0x40,0x5d, 0x5,0x29,0x57, 0x5,0x2e,0x29, + 0x5,0x2e,0x2a, 0x6,0x38,0x44, 0xf,0x2f,0x74, 0xf,0x2f,0x75, + 0xf,0x2f,0x76, 0xf,0x2f,0x78, 0xf,0x2f,0x79, 0xf,0x2f,0x7a, + 0xf,0x2f,0x7b, 0xf,0x2f,0x7c, 0xf,0x2f,0x7d, 0xf,0x2f,0x7e, + 0xf,0x30,0x21, 0xf,0x30,0x22, 0xf,0x30,0x23, 0xf,0x30,0x25, + 0xf,0x30,0x26, 0xf,0x30,0x27, 0xf,0x30,0x29, 0xf,0x30,0x2a, + 0xf,0x30,0x2b, 0xf,0x30,0x2c, 0xf,0x30,0x2e, 0x6,0x38,0x4c, + 0x6,0x38,0x47, 0x6,0x38,0x49, 0x4,0x2d,0x53, 0x6,0x38,0x4e, + 0xf,0x30,0x30, 0xf,0x30,0x28, 0x4,0x2d,0x5a, 0xf,0x30,0x2d, + 0x5,0x2e,0x2c, 0x5,0x2e,0x28, 0xf,0x2f,0x77, 0x6,0x38,0x52, + 0x6,0x40,0x68, 0x6,0x40,0x69, 0x6,0x40,0x5f, 0x5,0x32,0x77, + 0x5,0x33,0x21, 0x5,0x39,0x36, 0x4,0x32,0x45, 0x4,0x32,0x40, + 0x5,0x32,0x7d, 0x6,0x40,0x67, 0x6,0x4a,0x2e, 0x6,0x40,0x63, + 0xf,0x35,0x4c, 0xf,0x35,0x4d, 0xf,0x35,0x4f, 0xf,0x35,0x50, + 0xf,0x35,0x51, 0xf,0x35,0x52, 0xf,0x35,0x53, 0xf,0x35,0x54, + 0xf,0x35,0x55, 0xf,0x35,0x56, 0xf,0x35,0x58, 0xf,0x35,0x59, + 0xf,0x35,0x5a, 0xf,0x35,0x5b, 0xf,0x35,0x5c, 0xf,0x35,0x5d, + 0xf,0x35,0x5e, 0xf,0x35,0x5f, 0xf,0x35,0x60, 0xf,0x35,0x61, + 0xf,0x35,0x62, 0xf,0x35,0x63, 0xf,0x35,0x65, 0xf,0x35,0x66, + 0x6,0x40,0x64, 0x6,0x40,0x66, 0x6,0x40,0x65, 0x4,0x32,0x47, + 0x6,0x40,0x62, 0x6,0x40,0x60, 0x6,0x40,0x61, 0x4,0x32,0x44, + 0x5,0x33,0x22, 0x5,0x32,0x78, 0x5,0x32,0x7b, 0x5,0x32,0x7a, + 0x5,0x32,0x7c, 0x6,0x40,0x6a, 0xf,0x35,0x4e, 0x6,0x40,0x5e, + 0x4,0x38,0x36, 0x6,0x4a,0x34, 0x5,0x39,0x35, 0x6,0x53,0x49, + 0x4,0x38,0x2e, 0x5,0x39,0x38, 0x6,0x4a,0x22, 0x5,0x39,0x32, + 0x4,0x38,0x2b, 0x5,0x39,0x30, 0x5,0x39,0x34, 0x4,0x38,0x31, + 0x6,0x4a,0x2d, 0x6,0x4a,0x2f, 0x5,0x39,0x3a, 0x6,0x4a,0x24, + 0x6,0x4a,0x21, 0x5,0x39,0x37, 0x6,0x4a,0x33, 0x5,0x39,0x3c, + 0x5,0x39,0x3b, 0x6,0x4a,0x26, 0x4,0x38,0x30, 0x6,0x4a,0x27, + 0x6,0x4a,0x2a, 0x6,0x4a,0x31, 0x5,0x39,0x40, 0x6,0x53,0x4a, + 0x5,0x39,0x3d, 0x6,0x4a,0x38, 0x6,0x4a,0x23, 0x6,0x4a,0x25, + 0x6,0x4a,0x35, 0x4,0x38,0x33, 0x4,0x38,0x38, 0x6,0x4a,0x36, + 0x6,0x4a,0x37, 0xf,0x3b,0x64, 0xf,0x3b,0x65, 0xf,0x3b,0x67, + 0xf,0x3b,0x68, 0xf,0x3b,0x69, 0xf,0x3b,0x6b, 0xf,0x3b,0x6c, + 0xf,0x3b,0x6d, 0xf,0x3b,0x6f, 0xf,0x3b,0x71, 0xf,0x3b,0x72, + 0xf,0x3b,0x74, 0xf,0x3b,0x75, 0xf,0x3b,0x76, 0xf,0x3b,0x77, + 0xf,0x3b,0x78, 0xf,0x3b,0x79, 0xf,0x3b,0x7a, 0xf,0x3b,0x7b, + 0xf,0x3b,0x7c, 0xf,0x3b,0x7d, 0xf,0x3b,0x7e, 0xf,0x3c,0x22, + 0xf,0x3c,0x23, 0xf,0x3c,0x24, 0xf,0x3c,0x25, 0xf,0x3c,0x26, + 0xf,0x3c,0x27, 0xf,0x3c,0x28, 0xf,0x3c,0x2a, 0xf,0x3c,0x2b, + 0xf,0x3c,0x2c, 0xf,0x3c,0x2d, 0xf,0x3c,0x2e, 0xf,0x3c,0x2f, + 0x6,0x4a,0x29, 0x6,0x4a,0x2b, 0x6,0x4a,0x2c, 0x6,0x4a,0x32, + 0x5,0x39,0x42, 0x6,0x4a,0x30, 0x6,0x4a,0x39, 0x6,0x4a,0x28, + 0x5,0x39,0x3e, 0x5,0x39,0x41, 0x5,0x39,0x2e, 0x5,0x39,0x2f, + 0x5,0x39,0x31, 0x6,0x53,0x4e, 0x6,0x53,0x58, 0x4,0x3d,0x77, + 0x6,0x53,0x56, 0x4,0x3d,0x74, 0x6,0x53,0x57, 0x5,0x3f,0x6f, + 0x5,0x3f,0x6a, 0x5,0x3f,0x6e, 0x5,0x3f,0x6b, 0x4,0x3d,0x6a, + 0x6,0x53,0x5b, 0x5,0x3f,0x73, 0x6,0x53,0x61, 0x5,0x3f,0x68, + 0x4,0x3d,0x7a, 0x5,0x3f,0x74, 0x5,0x3f,0x69, 0x6,0x53,0x55, + 0x5,0x3f,0x70, 0x5,0x3f,0x6d, 0x6,0x53,0x60, 0x4,0x3d,0x73, + 0x6,0x53,0x59, 0x6,0x53,0x5a, 0x6,0x53,0x5d, 0x6,0x53,0x50, + 0x4,0x3d,0x70, 0x6,0x53,0x5c, 0x5,0x3f,0x6c, 0x6,0x53,0x63, + 0x6,0x53,0x4f, 0x6,0x53,0x51, 0x6,0x53,0x4c, 0xf,0x42,0x23, + 0xf,0x42,0x24, 0xf,0x42,0x25, 0xf,0x42,0x26, 0xf,0x42,0x27, + 0xf,0x42,0x29, 0xf,0x42,0x2a, 0xf,0x42,0x2b, 0xf,0x42,0x2c, + 0xf,0x42,0x2d, 0xf,0x42,0x2e, 0xf,0x42,0x30, 0xf,0x42,0x31, + 0xf,0x42,0x32, 0xf,0x42,0x33, 0xf,0x42,0x34, 0xf,0x42,0x35, + 0xf,0x42,0x36, 0xf,0x42,0x38, 0xf,0x42,0x39, 0xf,0x42,0x3a, + 0xf,0x42,0x3b, 0xf,0x42,0x3d, 0xf,0x42,0x3e, 0xf,0x42,0x3f, + 0xf,0x42,0x40, 0xf,0x42,0x41, 0xf,0x42,0x42, 0xf,0x42,0x43, + 0xf,0x42,0x44, 0xf,0x42,0x45, 0xf,0x42,0x46, 0xf,0x42,0x48, + 0xf,0x42,0x4a, 0xf,0x42,0x4c, 0x6,0x53,0x4d, 0x6,0x53,0x52, + 0x6,0x53,0x54, 0x4,0x3d,0x79, 0x6,0x53,0x62, 0x6,0x53,0x4b, + 0x6,0x53,0x5f, 0xf,0x42,0x22, 0xf,0x42,0x2f, 0xf,0x42,0x37, + 0x5,0x39,0x3f, 0x5,0x3f,0x72, 0x6,0x53,0x53, 0xf,0x43,0x74, + 0x5,0x46,0x4e, 0xf,0x42,0x4b, 0x5,0x46,0x50, 0x4,0x43,0x7b, + 0x4,0x43,0x72, 0x5,0x46,0x4d, 0x5,0x46,0x4f, 0x6,0x5d,0x69, + 0x5,0x46,0x55, 0x5,0x46,0x52, 0x7,0x23,0x65, 0x6,0x53,0x64, + 0x5,0x46,0x47, 0x6,0x5d,0x5f, 0x5,0x46,0x54, 0x5,0x46,0x46, + 0x5,0x46,0x58, 0x6,0x5d,0x62, 0x5,0x46,0x4a, 0x5,0x46,0x53, + 0x6,0x5d,0x63, 0x4,0x43,0x76, 0x5,0x46,0x48, 0x5,0x46,0x49, + 0x6,0x5d,0x65, 0x5,0x46,0x4c, 0x5,0x46,0x51, 0xf,0x48,0x57, + 0xf,0x48,0x58, 0xf,0x48,0x59, 0xf,0x48,0x5a, 0xf,0x48,0x5b, + 0xf,0x48,0x5c, 0xf,0x48,0x5d, 0xf,0x48,0x5e, 0xf,0x48,0x5f, + 0xf,0x48,0x60, 0xf,0x48,0x61, 0xf,0x48,0x62, 0xf,0x48,0x63, + 0xf,0x48,0x64, 0xf,0x48,0x65, 0xf,0x48,0x66, 0xf,0x48,0x67, + 0xf,0x48,0x68, 0xf,0x48,0x69, 0xf,0x48,0x6a, 0xf,0x48,0x6b, + 0xf,0x48,0x6c, 0xf,0x48,0x6d, 0xf,0x48,0x6e, 0xf,0x48,0x6f, + 0xf,0x48,0x71, 0xf,0x48,0x72, 0xf,0x48,0x73, 0xf,0x48,0x75, + 0x3,0x47,0x4b, 0x6,0x5d,0x6a, 0x6,0x5d,0x67, 0x6,0x5d,0x6b, + 0x6,0x5d,0x6c, 0x5,0x46,0x56, 0x5,0x46,0x57, 0xf,0x48,0x74, + 0x6,0x5d,0x64, 0x6,0x5d,0x66, 0xf,0x48,0x50, 0xf,0x48,0x51, + 0xf,0x48,0x53, 0xf,0x48,0x54, 0x6,0x5d,0x60, 0x6,0x5d,0x6d, + 0x6,0x5d,0x61, 0xf,0x48,0x56, 0x7,0x23,0x68, 0x5,0x4d,0x67, + 0x5,0x4d,0x5e, 0x4,0x4a,0x3b, 0x4,0x4a,0x47, 0x5,0x4d,0x5b, + 0x4,0x4a,0x40, 0x7,0x23,0x71, 0x7,0x23,0x6c, 0x7,0x23,0x74, + 0x5,0x4d,0x6b, 0x5,0x4d,0x65, 0x7,0x23,0x70, 0x4,0x4a,0x46, + 0x5,0x4d,0x5f, 0x4,0x4a,0x3f, 0x5,0x4d,0x64, 0x4,0x4a,0x43, + 0x4,0x4a,0x3e, 0x4,0x4a,0x35, 0x7,0x23,0x73, 0x5,0x4d,0x5c, + 0x4,0x4a,0x4a, 0x5,0x4d,0x69, 0x7,0x23,0x6e, 0x5,0x4d,0x63, + 0x5,0x4d,0x6a, 0x7,0x23,0x69, 0x4,0x4a,0x41, 0x5,0x4d,0x5d, + 0x7,0x23,0x75, 0x4,0x4a,0x3c, 0x4,0x4a,0x45, 0x4,0x4a,0x49, + 0x7,0x23,0x66, 0x7,0x23,0x6a, 0xf,0x4f,0x3d, 0xf,0x4f,0x3e, + 0xf,0x4f,0x3f, 0xf,0x4f,0x43, 0xf,0x4f,0x44, 0xf,0x4f,0x46, + 0xf,0x4f,0x47, 0xf,0x4f,0x48, 0xf,0x4f,0x49, 0xf,0x4f,0x4a, + 0xf,0x4f,0x4b, 0xf,0x4f,0x4c, 0xf,0x4f,0x4d, 0xf,0x4f,0x4e, + 0xf,0x4f,0x4f, 0xf,0x4f,0x50, 0xf,0x4f,0x51, 0xf,0x4f,0x52, + 0xf,0x4f,0x53, 0xf,0x4f,0x40, 0x7,0x23,0x6b, 0x5,0x4d,0x6c, + 0x5,0x4d,0x68, 0x5,0x4d,0x66, 0x7,0x23,0x67, 0x7,0x23,0x6d, + 0x5,0x4d,0x60, 0x5,0x4d,0x5a, 0x5,0x4d,0x62, 0x4,0x50,0x5b, + 0x5,0x54,0x7d, 0x7,0x2e,0x69, 0x4,0x50,0x65, 0x4,0x50,0x58, + 0x5,0x5b,0x65, 0x7,0x38,0x4c, 0x7,0x2e,0x60, 0x7,0x2e,0x63, + 0x5,0x54,0x7b, 0x7,0x2e,0x68, 0x7,0x2e,0x72, 0x5,0x54,0x7a, + 0x7,0x2e,0x6f, 0x7,0x2e,0x62, 0x4,0x50,0x62, 0x4,0x56,0x4c, + 0x4,0x50,0x57, 0x7,0x2e,0x5f, 0x4,0x50,0x5f, 0x5,0x54,0x79, + 0x7,0x2e,0x67, 0x7,0x2e,0x64, 0x5,0x54,0x71, 0x5,0x54,0x77, + 0x4,0x50,0x5c, 0x7,0x2e,0x6e, 0x7,0x2e,0x74, 0x5,0x54,0x78, + 0x4,0x50,0x5d, 0x7,0x2e,0x66, 0x7,0x2e,0x6b, 0x4,0x50,0x63, + 0x5,0x54,0x70, 0x7,0x2e,0x61, 0x5,0x61,0x7b, 0x5,0x54,0x75, + 0x5,0x54,0x76, 0x5,0x54,0x72, 0x4,0x4a,0x44, 0x7,0x2e,0x73, + 0x7,0x2e,0x6c, 0x7,0x2e,0x65, 0x7,0x2e,0x5e, 0x5,0x54,0x7c, + 0x5,0x54,0x6f, 0x5,0x54,0x73, 0xf,0x54,0x6f, 0xf,0x54,0x70, + 0xf,0x54,0x71, 0xf,0x54,0x72, 0xf,0x54,0x73, 0xf,0x54,0x75, + 0xf,0x54,0x76, 0xf,0x54,0x77, 0xf,0x54,0x78, 0xf,0x54,0x79, + 0xf,0x54,0x7a, 0xf,0x54,0x7c, 0xf,0x54,0x7d, 0xf,0x54,0x7e, + 0xf,0x55,0x21, 0xf,0x55,0x22, 0xf,0x55,0x24, 0xf,0x55,0x25, + 0xf,0x55,0x26, 0xf,0x55,0x27, 0xf,0x55,0x28, 0xf,0x55,0x2b, + 0xf,0x55,0x2c, 0xf,0x55,0x2d, 0xf,0x55,0x2e, 0xf,0x55,0x2f, + 0xf,0x55,0x30, 0xf,0x55,0x32, 0xf,0x55,0x33, 0xf,0x55,0x34, + 0xf,0x55,0x35, 0xf,0x55,0x36, 0xf,0x55,0x37, 0xf,0x55,0x38, + 0x7,0x2e,0x70, 0x7,0x2e,0x71, 0x4,0x50,0x61, 0xf,0x55,0x23, + 0x5,0x54,0x74, 0xf,0x48,0x70, 0xf,0x4f,0x41, 0x7,0x2e,0x6d, + 0x4,0x56,0x43, 0x7,0x38,0x50, 0x7,0x38,0x4e, 0x4,0x56,0x47, + 0x7,0x38,0x52, 0x7,0x38,0x56, 0x5,0x5b,0x6a, 0x5,0x5b,0x6b, + 0x4,0x56,0x4a, 0x4,0x56,0x46, 0x5,0x5b,0x6e, 0x7,0x38,0x53, + 0x5,0x5b,0x6c, 0x7,0x38,0x51, 0x7,0x38,0x57, 0x5,0x61,0x7c, + 0x5,0x5b,0x67, 0x4,0x56,0x4d, 0x4,0x56,0x44, 0x7,0x38,0x59, + 0x4,0x56,0x42, 0x5,0x5b,0x69, 0x7,0x38,0x5b, 0x5,0x5b,0x66, + 0x7,0x38,0x54, 0xf,0x5a,0x40, 0xf,0x5a,0x41, 0xf,0x5a,0x43, + 0xf,0x5a,0x44, 0xf,0x5a,0x45, 0xf,0x5a,0x46, 0xf,0x5a,0x47, + 0xf,0x5a,0x48, 0xf,0x5a,0x49, 0xf,0x5a,0x4a, 0xf,0x5a,0x4b, + 0xf,0x5a,0x4c, 0xf,0x5a,0x4e, 0xf,0x5a,0x4f, 0xf,0x5a,0x51, + 0xf,0x5a,0x52, 0xf,0x5a,0x54, 0x7,0x38,0x58, 0x5,0x5b,0x6d, + 0x7,0x38,0x5a, 0x7,0x38,0x4d, 0x7,0x38,0x4f, 0x7,0x37,0x27, + 0xf,0x5a,0x53, 0xf,0x5a,0x4d, 0x5,0x5b,0x6f, 0x5,0x5b,0x70, + 0xf,0x55,0x31, 0xf,0x5a,0x50, 0x4,0x5b,0x47, 0x5,0x61,0x78, + 0x7,0x40,0x27, 0x7,0x40,0x23, 0x4,0x5b,0x42, 0x7,0x40,0x2b, + 0x5,0x62,0x24, 0x5,0x61,0x7d, 0x5,0x62,0x26, 0x7,0x40,0x29, + 0x4,0x5b,0x45, 0x5,0x61,0x7a, 0x5,0x62,0x22, 0x5,0x62,0x27, + 0x5,0x61,0x7e, 0x7,0x38,0x5c, 0x5,0x62,0x2b, 0x5,0x61,0x79, + 0x4,0x5b,0x43, 0x4,0x5b,0x4c, 0x4,0x5b,0x46, 0x7,0x40,0x2d, + 0x7,0x40,0x28, 0x5,0x62,0x23, 0x7,0x47,0x46, 0x5,0x62,0x29, + 0x7,0x40,0x26, 0x4,0x5b,0x4b, 0x5,0x62,0x28, 0x5,0x62,0x25, + 0x5,0x61,0x76, 0x7,0x3f,0x7c, 0x7,0x3f,0x7d, 0xf,0x5e,0x7e, + 0xf,0x5f,0x22, 0xf,0x5f,0x23, 0xf,0x5f,0x24, 0xf,0x5f,0x25, + 0xf,0x5f,0x26, 0xf,0x5f,0x27, 0xf,0x5f,0x28, 0xf,0x5f,0x2a, + 0xf,0x5f,0x2b, 0xf,0x5f,0x2c, 0xf,0x5f,0x2e, 0xf,0x5f,0x2f, + 0xf,0x5f,0x30, 0x7,0x40,0x21, 0x7,0x40,0x25, 0x7,0x40,0x2c, + 0x7,0x40,0x2a, 0x5,0x62,0x21, 0xf,0x5f,0x21, 0x5,0x62,0x2a, + 0x5,0x61,0x77, 0x7,0x40,0x22, 0x7,0x40,0x24, 0xf,0x5f,0x2d, + 0x5,0x68,0x25, 0x7,0x47,0x43, 0x5,0x68,0x28, 0x5,0x68,0x2b, + 0x5,0x68,0x29, 0x7,0x47,0x42, 0x7,0x47,0x40, 0x5,0x68,0x2d, + 0x7,0x47,0x41, 0x4,0x5f,0x74, 0x7,0x47,0x48, 0x7,0x47,0x49, + 0x5,0x68,0x27, 0x5,0x68,0x26, 0x7,0x47,0x45, 0x5,0x68,0x2f, + 0x7,0x47,0x47, 0x7,0x3f,0x7e, 0xf,0x62,0x52, 0xf,0x62,0x56, + 0xf,0x62,0x58, 0xf,0x62,0x59, 0xf,0x62,0x5a, 0xf,0x62,0x5b, + 0xf,0x62,0x5c, 0xf,0x62,0x5d, 0xf,0x62,0x5f, 0xf,0x62,0x60, + 0xf,0x62,0x61, 0x5,0x68,0x2e, 0x7,0x47,0x44, 0x7,0x47,0x3f, + 0xf,0x62,0x54, 0x5,0x68,0x2c, 0xf,0x62,0x57, 0xf,0x62,0x4f, + 0xf,0x62,0x5e, 0xf,0x5e,0x7d, 0x4,0x63,0x53, 0x7,0x4d,0x7c, + 0x5,0x6c,0x3f, 0x7,0x4d,0x7e, 0x5,0x6c,0x42, 0x5,0x68,0x30, + 0x5,0x6c,0x3a, 0x5,0x6c,0x39, 0x5,0x6c,0x3d, 0x7,0x4d,0x7d, + 0x5,0x6c,0x3c, 0x5,0x6c,0x41, 0x5,0x6c,0x3b, 0x5,0x68,0x2a, + 0x5,0x6c,0x40, 0x5,0x6c,0x3e, 0xf,0x65,0x33, 0xf,0x65,0x34, + 0xf,0x65,0x35, 0xf,0x65,0x36, 0xf,0x65,0x37, 0xf,0x65,0x39, + 0xf,0x65,0x3a, 0xf,0x65,0x3b, 0xf,0x65,0x3c, 0xf,0x65,0x3d, + 0xf,0x65,0x3f, 0x7,0x4e,0x21, 0x4,0x63,0x52, 0x7,0x53,0x49, + 0x7,0x53,0x48, 0x5,0x70,0x2b, 0x5,0x70,0x2d, 0x4,0x66,0x46, + 0x5,0x70,0x29, 0x7,0x53,0x4d, 0x5,0x70,0x28, 0x5,0x70,0x2a, + 0x5,0x70,0x2c, 0x7,0x53,0x4a, 0x4,0x66,0x45, 0x5,0x70,0x2f, + 0x7,0x53,0x4e, 0x5,0x70,0x32, 0xf,0x67,0x5b, 0xf,0x67,0x5c, + 0xf,0x67,0x5d, 0xf,0x67,0x5e, 0xf,0x67,0x5f, 0xf,0x67,0x60, + 0xf,0x67,0x61, 0xf,0x67,0x62, 0xf,0x67,0x63, 0xf,0x67,0x64, + 0x7,0x53,0x4c, 0x5,0x70,0x31, 0x5,0x70,0x30, 0x7,0x53,0x4b, + 0x5,0x70,0x2e, 0x7,0x58,0x26, 0x5,0x73,0x4e, 0x5,0x73,0x4f, + 0x5,0x73,0x4c, 0x5,0x73,0x4a, 0x4,0x68,0x6f, 0x5,0x73,0x4b, + 0x5,0x73,0x4d, 0x7,0x58,0x25, 0xf,0x69,0x47, 0xf,0x69,0x48, + 0xf,0x69,0x49, 0xf,0x69,0x4b, 0xf,0x69,0x4e, 0xf,0x69,0x4f, + 0xf,0x69,0x50, 0xf,0x69,0x51, 0x7,0x58,0x24, 0x7,0x58,0x22, + 0xf,0x67,0x65, 0x5,0x75,0x71, 0x5,0x75,0x73, 0x5,0x77,0x60, + 0x5,0x75,0x74, 0x7,0x5b,0x60, 0x5,0x75,0x72, 0x7,0x5b,0x61, + 0x5,0x75,0x75, 0x7,0x5b,0x5f, 0x5,0x77,0x61, 0x7,0x5b,0x5d, + 0xf,0x6a,0x57, 0xf,0x6a,0x59, 0x7,0x5b,0x5e, 0x5,0x75,0x76, + 0x5,0x75,0x70, 0x4,0x6b,0x6c, 0x7,0x5e,0x6e, 0x5,0x77,0x62, + 0x7,0x60,0x71, 0xf,0x6b,0x4e, 0xf,0x6b,0x4f, 0xf,0x6b,0x50, + 0xf,0x6b,0x53, 0xf,0x6b,0x54, 0x7,0x5e,0x6f, 0x7,0x5e,0x70, + 0xf,0x6a,0x58, 0x7,0x60,0x72, 0x5,0x79,0x2d, 0xf,0x6c,0x2c, + 0x7,0x60,0x73, 0x5,0x79,0x2c, 0x5,0x79,0x2e, 0xf,0x6b,0x52, + 0x5,0x7a,0x29, 0x7,0x63,0x54, 0x7,0x60,0x74, 0x4,0x6d,0x55, + 0xf,0x6c,0x2d, 0xf,0x6c,0x4c, 0xf,0x6c,0x63, 0x7,0x63,0x4c, + 0x7,0x63,0x55, 0x5,0x7b,0x40, 0x7,0x64,0x48, 0x7,0x64,0x49, + 0x7,0x65,0x5b, 0xf,0x6d,0x2f, 0x7,0x65,0x74, 0x6,0x25,0x24, + 0x4,0x24,0x4b, 0x6,0x28,0x2f, 0x6,0x2c,0x2e, 0x6,0x28,0x32, + 0x5,0x24,0x47, 0x6,0x28,0x31, 0x4,0x24,0x4a, 0x5,0x26,0x5c, + 0x5,0x26,0x5b, 0x5,0x26,0x58, 0x6,0x2c,0x2f, 0x4,0x26,0x6f, + 0x6,0x2c,0x30, 0x5,0x26,0x5d, 0x4,0x26,0x6e, 0x5,0x26,0x59, + 0x5,0x26,0x5a, 0x5,0x26,0x57, 0xf,0x27,0x56, 0x5,0x29,0x5f, + 0x6,0x31,0x7a, 0x6,0x38,0x54, 0x6,0x31,0x7c, 0x5,0x29,0x62, + 0x4,0x29,0x75, 0x5,0x29,0x61, 0x5,0x29,0x5e, 0x6,0x31,0x79, + 0x5,0x29,0x5c, 0x5,0x29,0x60, 0x6,0x31,0x7b, 0x5,0x29,0x5d, + 0xf,0x2c,0x77, 0x6,0x38,0x57, 0x6,0x38,0x58, 0x6,0x38,0x55, + 0x5,0x2e,0x33, 0x5,0x2e,0x2d, 0x6,0x38,0x56, 0x6,0x40,0x6b, + 0x5,0x2e,0x32, 0x4,0x2d,0x5f, 0x5,0x2e,0x2f, 0x5,0x2e,0x34, + 0x5,0x2e,0x31, 0x5,0x2e,0x30, 0xf,0x30,0x31, 0x5,0x33,0x25, + 0x6,0x40,0x6c, 0x6,0x40,0x6d, 0xf,0x35,0x67, 0xf,0x35,0x68, + 0xf,0x35,0x69, 0xf,0x35,0x6a, 0xf,0x35,0x6b, 0xf,0x35,0x6c, + 0xf,0x35,0x6d, 0xf,0x35,0x6e, 0x4,0x38,0x3d, 0x5,0x39,0x47, + 0x5,0x3f,0x77, 0x4,0x38,0x3a, 0x5,0x39,0x45, 0x6,0x4a,0x3c, + 0x5,0x33,0x24, 0x5,0x39,0x48, 0x6,0x4a,0x3d, 0x5,0x39,0x44, + 0x5,0x39,0x49, 0x6,0x4a,0x3e, 0x5,0x39,0x46, 0x6,0x4a,0x3b, + 0xf,0x3c,0x30, 0xf,0x3c,0x31, 0x6,0x4a,0x3a, 0x6,0x53,0x6e, + 0x5,0x3f,0x76, 0x5,0x3f,0x75, 0x5,0x3f,0x7a, 0x6,0x53,0x6b, + 0x5,0x3f,0x79, 0x6,0x53,0x67, 0x6,0x53,0x66, 0x6,0x53,0x68, + 0x6,0x53,0x69, 0x6,0x53,0x6a, 0x6,0x53,0x6d, 0x5,0x3f,0x78, + 0xf,0x42,0x4e, 0x6,0x58,0x5a, 0x6,0x53,0x6c, 0x6,0x53,0x65, + 0xf,0x42,0x4d, 0x5,0x46,0x5c, 0x4,0x44,0x2b, 0x5,0x46,0x5e, + 0x6,0x5d,0x6f, 0x6,0x5d,0x6e, 0x4,0x44,0x2c, 0x5,0x46,0x5d, + 0x4,0x44,0x29, 0x6,0x5d,0x75, 0x6,0x5d,0x70, 0x5,0x46,0x5a, + 0x6,0x5d,0x76, 0x6,0x5d,0x74, 0x5,0x46,0x5b, 0x6,0x5d,0x72, + 0x6,0x5d,0x71, 0x6,0x5d,0x73, 0x6,0x53,0x6f, 0xf,0x48,0x76, + 0xf,0x48,0x78, 0x5,0x46,0x59, 0x5,0x4d,0x6e, 0x7,0x23,0x7d, + 0x5,0x4d,0x70, 0x5,0x4d,0x71, 0x4,0x4a,0x4d, 0x7,0x23,0x79, + 0x7,0x23,0x77, 0x7,0x23,0x7e, 0x7,0x23,0x76, 0x7,0x23,0x7a, + 0x7,0x23,0x7b, 0x5,0x4d,0x6f, 0xf,0x4f,0x54, 0x7,0x23,0x7c, + 0x5,0x54,0x7e, 0x7,0x2e,0x76, 0x4,0x50,0x68, 0x7,0x2e,0x75, + 0xf,0x55,0x3a, 0xf,0x55,0x3b, 0x7,0x38,0x5e, 0x7,0x38,0x60, + 0x5,0x5b,0x71, 0x7,0x38,0x5f, 0xf,0x5a,0x55, 0x7,0x38,0x5d, + 0x5,0x62,0x2c, 0x5,0x68,0x32, 0x5,0x68,0x31, 0xf,0x62,0x62, + 0x5,0x70,0x36, 0x7,0x4e,0x23, 0x5,0x70,0x35, 0x5,0x70,0x34, + 0x4,0x68,0x70, 0x5,0x70,0x33, 0x5,0x73,0x50, 0x7,0x58,0x29, + 0x7,0x58,0x27, 0x7,0x58,0x28, 0x5,0x77,0x63, 0x7,0x60,0x75, + 0x4,0x6c,0x70, 0x4,0x6d,0x56, 0x5,0x21,0x32, 0x5,0x21,0x70, + 0x6,0x23,0x2e, 0x6,0x25,0x26, 0x5,0x24,0x4a, 0x6,0x28,0x34, + 0x6,0x2c,0x31, 0x5,0x24,0x49, 0x5,0x24,0x4b, 0x6,0x28,0x33, + 0x6,0x2c,0x3c, 0x6,0x2c,0x34, 0x6,0x2c,0x3b, 0x6,0x2c,0x3a, + 0x6,0x2c,0x36, 0x6,0x2c,0x33, 0x6,0x2c,0x38, 0x6,0x2c,0x32, + 0x6,0x2c,0x37, 0x5,0x26,0x5e, 0x6,0x2c,0x39, 0x6,0x2c,0x35, + 0x5,0x26,0x5f, 0xf,0x27,0x57, 0xf,0x27,0x58, 0xf,0x27,0x59, + 0x4,0x26,0x72, 0x4,0x29,0x76, 0x5,0x29,0x63, 0x5,0x28,0x35, + 0x6,0x38,0x59, 0x6,0x38,0x5c, 0x5,0x2e,0x35, 0x6,0x38,0x5a, + 0x6,0x38,0x5e, 0x6,0x38,0x5d, 0x6,0x38,0x5b, 0x6,0x37,0x48, + 0x5,0x33,0x26, 0x6,0x40,0x70, 0xf,0x35,0x6f, 0x6,0x40,0x6f, + 0x4,0x38,0x40, 0x4,0x38,0x3e, 0x5,0x39,0x4a, 0x5,0x39,0x4b, + 0x6,0x4a,0x43, 0x4,0x38,0x41, 0x6,0x4a,0x42, 0x6,0x4a,0x44, + 0x6,0x4a,0x40, 0x6,0x4a,0x45, 0x6,0x4a,0x46, 0x6,0x4a,0x41, + 0x5,0x3f,0x7c, 0x6,0x53,0x70, 0x5,0x3f,0x7b, 0xf,0x42,0x4f, + 0x6,0x5a,0x61, 0x7,0x24,0x22, 0x7,0x24,0x25, 0x7,0x24,0x23, + 0x7,0x24,0x26, 0x7,0x24,0x21, 0x7,0x24,0x24, 0xf,0x4f,0x55, + 0x7,0x2e,0x7a, 0x7,0x2e,0x79, 0x7,0x2e,0x77, 0x7,0x2e,0x78, + 0x7,0x38,0x61, 0x4,0x56,0x50, 0xf,0x5a,0x56, 0xf,0x5a,0x57, + 0x5,0x62,0x2d, 0x5,0x62,0x2e, 0x7,0x40,0x2e, 0x5,0x73,0x51, + 0x7,0x5b,0x62, 0x7,0x5b,0x63, 0x5,0x21,0x71, 0x5,0x21,0x49, + 0x5,0x22,0x76, 0x6,0x28,0x35, 0x4,0x22,0x7d, 0x6,0x25,0x27, + 0x5,0x24,0x4c, 0x4,0x24,0x4d, 0x6,0x25,0x28, 0x6,0x28,0x36, + 0x6,0x28,0x3b, 0x6,0x28,0x37, 0x4,0x24,0x4c, 0x6,0x28,0x3c, + 0x5,0x24,0x4d, 0x6,0x28,0x39, 0x6,0x28,0x38, 0x6,0x28,0x3a, + 0x6,0x2c,0x3f, 0x5,0x26,0x60, 0x5,0x26,0x66, 0x5,0x26,0x61, + 0x5,0x26,0x64, 0x4,0x26,0x73, 0x4,0x26,0x74, 0x5,0x26,0x63, + 0x4,0x26,0x77, 0x6,0x2c,0x3d, 0x6,0x2c,0x3e, 0x6,0x2c,0x40, + 0x6,0x31,0x7d, 0x5,0x26,0x65, 0x5,0x29,0x68, 0x4,0x29,0x78, + 0x4,0x29,0x79, 0x6,0x32,0x26, 0x4,0x29,0x77, 0x6,0x31,0x7e, + 0x5,0x29,0x64, 0x5,0x29,0x65, 0x5,0x29,0x6b, 0x5,0x29,0x66, + 0x5,0x29,0x67, 0x6,0x32,0x25, 0x4,0x29,0x7a, 0x6,0x32,0x22, + 0x6,0x32,0x23, 0x5,0x29,0x6a, 0x6,0x32,0x24, 0x6,0x38,0x5f, + 0xf,0x2b,0x50, 0x6,0x32,0x21, 0x5,0x29,0x6c, 0x5,0x2e,0x36, + 0x4,0x2d,0x63, 0x6,0x38,0x62, 0x5,0x2e,0x3b, 0x6,0x38,0x65, + 0x5,0x2e,0x3c, 0x5,0x2e,0x38, 0x5,0x2e,0x39, 0x6,0x38,0x63, + 0x6,0x38,0x66, 0x5,0x2e,0x3d, 0x5,0x2e,0x37, 0x5,0x2e,0x3a, + 0x5,0x2e,0x3e, 0x6,0x38,0x60, 0x6,0x38,0x61, 0x5,0x33,0x2b, + 0x6,0x40,0x74, 0x5,0x33,0x2a, 0x6,0x40,0x73, 0x5,0x33,0x27, + 0x5,0x33,0x28, 0x5,0x33,0x29, 0x6,0x40,0x71, 0x4,0x32,0x4b, + 0x5,0x33,0x2c, 0x6,0x4a,0x49, 0x6,0x40,0x75, 0x6,0x40,0x72, + 0xf,0x35,0x71, 0x6,0x53,0x72, 0x6,0x4a,0x4a, 0x5,0x39,0x53, + 0x4,0x38,0x48, 0x6,0x4a,0x4b, 0x4,0x38,0x43, 0x5,0x39,0x4e, + 0x5,0x39,0x4d, 0x5,0x39,0x4f, 0x4,0x38,0x47, 0x5,0x39,0x52, + 0x5,0x39,0x54, 0x5,0x39,0x50, 0x5,0x39,0x4c, 0x5,0x39,0x51, + 0x6,0x4a,0x4c, 0x6,0x53,0x71, 0x6,0x4a,0x48, 0xf,0x3c,0x32, + 0x6,0x53,0x74, 0x6,0x53,0x79, 0x5,0x3f,0x7d, 0x5,0x3f,0x7e, + 0x6,0x53,0x76, 0x6,0x53,0x78, 0x4,0x3e,0x25, 0x6,0x5d,0x78, + 0x6,0x53,0x7a, 0x6,0x53,0x75, 0x6,0x53,0x73, 0xf,0x42,0x50, + 0xf,0x35,0x70, 0x4,0x44,0x34, 0x4,0x44,0x2e, 0x6,0x5d,0x7b, + 0x6,0x5d,0x7c, 0x4,0x44,0x2f, 0x6,0x5d,0x79, 0x6,0x5d,0x7a, + 0x6,0x5d,0x2d, 0x7,0x24,0x29, 0x4,0x4a,0x51, 0x5,0x4d,0x72, + 0x7,0x24,0x27, 0x5,0x4d,0x75, 0x7,0x24,0x28, 0x7,0x24,0x2b, + 0x5,0x4d,0x74, 0x4,0x50,0x69, 0x7,0x24,0x2c, 0x7,0x24,0x2a, + 0xf,0x4f,0x56, 0x5,0x4d,0x73, 0x7,0x2e,0x7b, 0x7,0x2e,0x7c, + 0x5,0x55,0x21, 0x4,0x50,0x6c, 0x5,0x55,0x23, 0x5,0x55,0x22, + 0x7,0x2e,0x7e, 0xf,0x55,0x3c, 0xf,0x55,0x3d, 0x7,0x38,0x64, + 0x7,0x38,0x62, 0x5,0x5b,0x73, 0x7,0x38,0x65, 0x7,0x38,0x63, + 0x5,0x5b,0x74, 0x5,0x62,0x30, 0x5,0x62,0x2f, 0x4,0x5b,0x4d, + 0x7,0x40,0x30, 0x7,0x2e,0x7d, 0x5,0x5b,0x75, 0x7,0x40,0x2f, + 0x5,0x68,0x33, 0x5,0x70,0x37, 0x5,0x70,0x38, 0x7,0x53,0x4f, + 0x7,0x58,0x2a, 0x5,0x75,0x7a, 0x5,0x75,0x79, 0x5,0x26,0x68, + 0x5,0x26,0x67, 0x6,0x32,0x27, 0x6,0x32,0x28, 0x5,0x2e,0x3f, + 0x4,0x32,0x4c, 0x4,0x32,0x4d, 0x6,0x40,0x78, 0x6,0x40,0x79, + 0x6,0x40,0x76, 0x6,0x40,0x77, 0xf,0x35,0x73, 0xf,0x35,0x75, + 0xf,0x35,0x76, 0xf,0x35,0x77, 0x6,0x40,0x7b, 0x6,0x40,0x7a, + 0x5,0x33,0x2d, 0x6,0x4a,0x4f, 0x6,0x4a,0x4e, 0xf,0x3c,0x33, + 0xf,0x35,0x72, 0x6,0x54,0x21, 0x6,0x54,0x22, 0x6,0x53,0x7d, + 0x6,0x53,0x7e, 0x6,0x54,0x24, 0xf,0x42,0x51, 0xf,0x42,0x52, + 0x6,0x54,0x23, 0x6,0x53,0x7c, 0x5,0x40,0x21, 0x5,0x40,0x7b, + 0x5,0x46,0x61, 0x4,0x44,0x36, 0x6,0x5e,0x21, 0x4,0x44,0x37, + 0x6,0x5d,0x7e, 0x6,0x5d,0x7d, 0xf,0x48,0x7a, 0x5,0x4d,0x76, + 0x6,0x5e,0x22, 0x7,0x24,0x2d, 0x4,0x4a,0x52, 0x7,0x2f,0x25, + 0x7,0x2f,0x23, 0x7,0x2f,0x26, 0x7,0x2f,0x21, 0x7,0x2f,0x24, + 0x5,0x55,0x24, 0x7,0x2f,0x22, 0xf,0x55,0x3e, 0xf,0x55,0x3f, + 0xf,0x55,0x40, 0x7,0x38,0x66, 0x7,0x38,0x67, 0x4,0x5b,0x4e, + 0x7,0x40,0x33, 0x5,0x62,0x32, 0x5,0x62,0x31, 0x7,0x40,0x31, + 0x7,0x40,0x32, 0x4,0x5f,0x78, 0x7,0x47,0x4c, 0x7,0x4e,0x25, + 0x7,0x47,0x4d, 0x7,0x53,0x50, 0x4,0x6a,0x4d, 0x5,0x75,0x7b, + 0x7,0x5b,0x64, 0x5,0x73,0x52, 0x7,0x5e,0x73, 0x5,0x77,0x65, + 0x5,0x77,0x64, 0x7,0x60,0x76, 0x7,0x63,0x56, 0x5,0x21,0x72, + 0x6,0x28,0x3d, 0x6,0x2c,0x41, 0x6,0x32,0x29, 0x6,0x38,0x67, + 0xf,0x3c,0x34, 0x5,0x40,0x22, 0x4,0x4a,0x53, 0xf,0x4f,0x57, + 0xf,0x4f,0x58, 0xf,0x5a,0x59, 0xf,0x55,0x41, 0xf,0x62,0x63, + 0xf,0x6a,0x5a, 0x5,0x24,0x4f, 0x6,0x28,0x3e, 0x6,0x2c,0x45, + 0x6,0x2c,0x44, 0x5,0x26,0x69, 0x6,0x38,0x68, 0x6,0x38,0x6a, + 0x6,0x38,0x69, 0x6,0x40,0x7c, 0x6,0x40,0x7d, 0x5,0x40,0x23, + 0x4,0x3e,0x26, 0x5,0x46,0x62, 0x5,0x46,0x63, 0x6,0x5e,0x23, + 0x7,0x24,0x2e, 0x7,0x2f,0x27, 0x7,0x2f,0x28, 0x5,0x55,0x25, + 0x7,0x47,0x4e, 0x5,0x6c,0x43, 0x5,0x79,0x30, 0x5,0x21,0x4a, + 0x4,0x22,0x7e, 0xf,0x22,0x5a, 0xf,0x22,0x5b, 0x6,0x28,0x40, + 0x6,0x28,0x3f, 0x4,0x24,0x4e, 0xf,0x24,0x55, 0xf,0x24,0x56, + 0xf,0x24,0x57, 0xf,0x24,0x59, 0xf,0x24,0x5a, 0x5,0x26,0x6d, + 0x5,0x26,0x6a, 0x5,0x26,0x6c, 0x5,0x26,0x6b, 0x6,0x2c,0x47, + 0x6,0x2c,0x46, 0xf,0x27,0x5a, 0xf,0x27,0x5c, 0xf,0x27,0x5d, + 0xf,0x27,0x5e, 0xf,0x27,0x5f, 0x5,0x26,0x43, 0x6,0x32,0x2c, + 0x5,0x29,0x6e, 0x5,0x29,0x6f, 0x5,0x29,0x6d, 0x5,0x29,0x70, + 0x5,0x29,0x71, 0x6,0x32,0x2d, 0x5,0x29,0x73, 0x6,0x32,0x2f, + 0x6,0x38,0x6d, 0x6,0x32,0x2e, 0x5,0x29,0x74, 0x6,0x32,0x2b, + 0x5,0x29,0x72, 0xf,0x2b,0x51, 0xf,0x2b,0x52, 0xf,0x2b,0x53, + 0xf,0x2b,0x54, 0xf,0x2b,0x55, 0xf,0x2b,0x56, 0xf,0x2b,0x57, + 0xf,0x2b,0x58, 0xf,0x2b,0x59, 0xf,0x2b,0x5a, 0xf,0x2b,0x5b, + 0xf,0x2b,0x5c, 0xf,0x2b,0x5e, 0xf,0x2b,0x5d, 0x6,0x38,0x6f, + 0x5,0x2e,0x41, 0x6,0x38,0x6e, 0x4,0x2d,0x69, 0x5,0x2e,0x43, + 0x4,0x2d,0x68, 0x6,0x38,0x6c, 0x5,0x2e,0x42, 0xf,0x30,0x32, + 0xf,0x30,0x33, 0xf,0x30,0x34, 0xf,0x30,0x35, 0xf,0x30,0x36, + 0xf,0x30,0x37, 0xf,0x30,0x38, 0xf,0x30,0x39, 0x6,0x38,0x6b, + 0x5,0x2e,0x40, 0x6,0x41,0x26, 0x4,0x32,0x56, 0x6,0x41,0x21, + 0x5,0x33,0x31, 0x6,0x41,0x22, 0x6,0x41,0x23, 0x5,0x33,0x2e, + 0x6,0x41,0x25, 0x5,0x33,0x32, 0x5,0x33,0x30, 0x5,0x33,0x2f, + 0x6,0x40,0x7e, 0x6,0x41,0x24, 0xf,0x35,0x78, 0xf,0x35,0x79, + 0xf,0x35,0x7a, 0xf,0x35,0x7b, 0xf,0x35,0x7c, 0x5,0x39,0x55, + 0x4,0x38,0x4d, 0x5,0x39,0x56, 0x4,0x38,0x50, 0x6,0x4a,0x51, + 0x6,0x4a,0x53, 0x5,0x39,0x59, 0x5,0x39,0x58, 0x5,0x39,0x5a, + 0x6,0x4a,0x56, 0x6,0x4a,0x50, 0x6,0x4a,0x55, 0x5,0x39,0x57, + 0x6,0x4a,0x52, 0xf,0x3c,0x3a, 0xf,0x3c,0x35, 0xf,0x3c,0x37, + 0xf,0x3c,0x38, 0xf,0x3c,0x39, 0xf,0x3c,0x3b, 0xf,0x3c,0x3d, + 0xf,0x3c,0x3f, 0xf,0x3c,0x40, 0x6,0x4a,0x54, 0xf,0x3c,0x36, + 0x5,0x39,0x5c, 0x6,0x54,0x2e, 0x6,0x54,0x2c, 0x4,0x3e,0x2b, + 0x6,0x54,0x27, 0x6,0x54,0x2b, 0x4,0x3e,0x2a, 0x6,0x54,0x28, + 0x6,0x54,0x25, 0x6,0x54,0x29, 0x6,0x54,0x26, 0x6,0x54,0x2d, + 0x6,0x54,0x2a, 0x6,0x54,0x2f, 0x5,0x40,0x24, 0xf,0x42,0x53, + 0xf,0x42,0x55, 0xf,0x42,0x56, 0xf,0x42,0x57, 0x6,0x54,0x30, + 0x6,0x5e,0x29, 0x5,0x46,0x66, 0x5,0x46,0x65, 0x6,0x5e,0x2a, + 0x6,0x5e,0x2b, 0x6,0x5e,0x2d, 0x4,0x44,0x3d, 0x6,0x5e,0x24, + 0x4,0x44,0x3e, 0x5,0x46,0x67, 0x4,0x44,0x3b, 0x6,0x5e,0x2e, + 0x6,0x5e,0x2f, 0x6,0x5e,0x26, 0x6,0x5e,0x27, 0xf,0x48,0x7c, + 0xf,0x48,0x7d, 0xf,0x48,0x7e, 0xf,0x49,0x21, 0x6,0x5e,0x28, + 0x5,0x46,0x69, 0x6,0x5e,0x30, 0x6,0x5e,0x25, 0x6,0x5e,0x2c, + 0x4,0x4a,0x56, 0x7,0x24,0x33, 0x7,0x24,0x37, 0x7,0x24,0x35, + 0x4,0x4a,0x55, 0x4,0x4a,0x54, 0x5,0x4d,0x79, 0x7,0x24,0x34, + 0x5,0x4d,0x77, 0x5,0x4d,0x78, 0x7,0x24,0x31, 0x7,0x24,0x32, + 0x7,0x24,0x30, 0x7,0x24,0x2f, 0x7,0x24,0x36, 0x7,0x24,0x38, + 0x7,0x2f,0x29, 0x5,0x55,0x27, 0x7,0x2f,0x2a, 0x4,0x50,0x70, + 0x5,0x55,0x26, 0x4,0x50,0x73, 0x7,0x2f,0x2c, 0xf,0x55,0x42, + 0xf,0x55,0x43, 0xf,0x55,0x44, 0xf,0x55,0x45, 0x7,0x2f,0x2b, + 0x7,0x24,0x39, 0x7,0x38,0x6a, 0x4,0x56,0x55, 0x4,0x56,0x54, + 0x7,0x38,0x69, 0x5,0x5b,0x76, 0x7,0x38,0x68, 0xf,0x5a,0x5a, + 0xf,0x5a,0x5b, 0xf,0x5a,0x5c, 0x7,0x38,0x6c, 0x7,0x38,0x6b, + 0x5,0x62,0x35, 0x5,0x62,0x34, 0x5,0x62,0x36, 0x7,0x40,0x37, + 0x7,0x47,0x4f, 0x7,0x40,0x35, 0x5,0x62,0x37, 0x7,0x40,0x34, + 0x7,0x40,0x36, 0xf,0x5f,0x31, 0x5,0x62,0x33, 0xf,0x5f,0x32, + 0x7,0x47,0x52, 0x5,0x68,0x34, 0x7,0x47,0x50, 0x7,0x47,0x51, + 0xf,0x65,0x41, 0x7,0x4e,0x26, 0x4,0x66,0x47, 0x5,0x70,0x39, + 0x7,0x53,0x51, 0xf,0x67,0x67, 0x7,0x58,0x2b, 0x5,0x73,0x53, + 0xf,0x69,0x52, 0x5,0x75,0x7c, 0x7,0x5b,0x65, 0x7,0x64,0x4a, + 0x6,0x2c,0x48, 0x6,0x32,0x30, 0x5,0x29,0x75, 0x5,0x29,0x76, + 0x6,0x33,0x4c, 0x6,0x41,0x27, 0xf,0x35,0x7d, 0x6,0x41,0x28, + 0x6,0x54,0x31, 0x4,0x44,0x40, 0x7,0x2f,0x2d, 0x7,0x38,0x6d, + 0x4,0x5b,0x51, 0xf,0x5a,0x5d, 0x6,0x25,0x2a, 0x6,0x25,0x29, + 0xf,0x24,0x5c, 0x6,0x2c,0x4b, 0x6,0x2c,0x4a, 0x6,0x2c,0x49, + 0x6,0x32,0x31, 0x6,0x32,0x32, 0xf,0x2b,0x5f, 0x5,0x29,0x77, + 0x5,0x2e,0x44, 0xf,0x35,0x7e, 0x5,0x39,0x5d, 0xf,0x3c,0x41, + 0x6,0x54,0x32, 0x7,0x24,0x3b, 0x7,0x24,0x3a, 0x7,0x40,0x38, + 0x7,0x53,0x52, 0xf,0x21,0x67, 0x6,0x22,0x24, 0x6,0x25,0x2b, + 0x5,0x21,0x73, 0x6,0x25,0x2c, 0xf,0x22,0x5e, 0xf,0x24,0x69, + 0x4,0x23,0x23, 0x6,0x25,0x2d, 0x5,0x24,0x50, 0x6,0x25,0x2f, + 0x6,0x25,0x31, 0x3,0x24,0x24, 0xf,0x22,0x5c, 0xf,0x24,0x5f, + 0xf,0x24,0x60, 0x6,0x25,0x30, 0x6,0x2c,0x4d, 0x5,0x24,0x52, + 0x6,0x28,0x42, 0x5,0x24,0x51, 0x5,0x24,0x53, 0x4,0x24,0x50, + 0x6,0x28,0x46, 0x6,0x28,0x47, 0x6,0x2c,0x4c, 0x6,0x28,0x43, + 0x6,0x28,0x41, 0x6,0x28,0x45, 0x6,0x28,0x48, 0xf,0x24,0x61, + 0xf,0x24,0x5e, 0xf,0x24,0x62, 0xf,0x24,0x63, 0xf,0x24,0x64, + 0xf,0x24,0x65, 0xf,0x24,0x66, 0xf,0x24,0x67, 0xf,0x27,0x63, + 0xf,0x27,0x64, 0xf,0x27,0x65, 0x4,0x27,0x23, 0x5,0x26,0x6f, + 0x6,0x32,0x33, 0x5,0x26,0x72, 0x5,0x26,0x73, 0x4,0x27,0x21, + 0x6,0x2c,0x57, 0x4,0x27,0x25, 0x6,0x2c,0x50, 0x4,0x27,0x24, + 0x6,0x2c,0x4e, 0x5,0x26,0x6e, 0x5,0x26,0x70, 0x6,0x2c,0x58, + 0x5,0x26,0x71, 0x6,0x2c,0x5a, 0x6,0x32,0x34, 0x6,0x2c,0x56, + 0x6,0x2c,0x5c, 0x4,0x26,0x7c, 0x6,0x2c,0x53, 0xf,0x27,0x60, + 0xf,0x27,0x61, 0xf,0x27,0x62, 0xf,0x27,0x67, 0xf,0x27,0x68, + 0xf,0x27,0x69, 0xf,0x27,0x6a, 0xf,0x27,0x6b, 0xf,0x27,0x6d, + 0xf,0x2b,0x64, 0xf,0x2b,0x67, 0xf,0x2b,0x6c, 0x6,0x2c,0x52, + 0x6,0x2c,0x54, 0x6,0x2c,0x55, 0x6,0x2c,0x59, 0x6,0x2c,0x4f, + 0x5,0x29,0x78, 0x4,0x29,0x7c, 0x6,0x32,0x36, 0x5,0x2a,0x22, + 0x6,0x32,0x3b, 0x6,0x32,0x3e, 0x5,0x29,0x79, 0x4,0x2a,0x22, + 0x4,0x2d,0x71, 0x5,0x2a,0x21, 0x5,0x29,0x7e, 0x6,0x32,0x3a, + 0x6,0x32,0x40, 0x5,0x29,0x7a, 0x6,0x32,0x41, 0x5,0x29,0x7d, + 0x6,0x38,0x70, 0x6,0x32,0x3d, 0x6,0x32,0x3c, 0x4,0x2a,0x23, + 0x4,0x29,0x7d, 0x6,0x32,0x3f, 0xf,0x2b,0x60, 0xf,0x2b,0x61, + 0xf,0x2b,0x62, 0xf,0x2b,0x63, 0xf,0x2b,0x65, 0xf,0x2b,0x66, + 0xf,0x2b,0x68, 0xf,0x2b,0x69, 0xf,0x2b,0x6a, 0xf,0x2b,0x6b, + 0xf,0x2b,0x6d, 0xf,0x2b,0x6e, 0xf,0x30,0x3a, 0xf,0x30,0x3d, + 0xf,0x30,0x44, 0x6,0x32,0x38, 0x4,0x2a,0x24, 0x6,0x32,0x35, + 0x6,0x32,0x37, 0x5,0x2a,0x23, 0xf,0x30,0x57, 0x4,0x2d,0x6e, + 0x5,0x2e,0x49, 0x6,0x39,0x30, 0x6,0x39,0x2e, 0x5,0x2e,0x48, + 0x5,0x2e,0x47, 0x6,0x38,0x7c, 0x5,0x2e,0x4a, 0x6,0x38,0x71, + 0x6,0x38,0x7b, 0x4,0x2d,0x6d, 0x4,0x2d,0x6f, 0x6,0x39,0x25, + 0x6,0x38,0x76, 0x6,0x39,0x26, 0x6,0x39,0x2a, 0x6,0x38,0x77, + 0x6,0x39,0x29, 0x6,0x38,0x7e, 0x6,0x39,0x28, 0x6,0x41,0x2a, + 0x6,0x41,0x29, 0x4,0x32,0x66, 0x6,0x39,0x24, 0x6,0x39,0x2c, + 0x5,0x2e,0x45, 0x6,0x39,0x23, 0x6,0x38,0x73, 0x6,0x39,0x2b, + 0x6,0x38,0x78, 0x6,0x39,0x2f, 0x6,0x39,0x32, 0x6,0x41,0x46, + 0xf,0x30,0x3b, 0xf,0x30,0x3e, 0xf,0x30,0x3f, 0xf,0x30,0x40, + 0xf,0x30,0x41, 0xf,0x30,0x42, 0xf,0x30,0x43, 0xf,0x30,0x45, + 0xf,0x30,0x46, 0xf,0x30,0x47, 0xf,0x30,0x48, 0xf,0x30,0x4a, + 0xf,0x30,0x4b, 0xf,0x30,0x4c, 0xf,0x30,0x4d, 0xf,0x30,0x4e, + 0xf,0x30,0x4f, 0xf,0x30,0x50, 0xf,0x30,0x51, 0xf,0x30,0x52, + 0xf,0x30,0x53, 0xf,0x30,0x54, 0xf,0x30,0x55, 0xf,0x30,0x56, + 0xf,0x30,0x58, 0xf,0x30,0x59, 0xf,0x30,0x5a, 0x6,0x38,0x79, + 0x6,0x39,0x22, 0x6,0x39,0x31, 0x4,0x2d,0x72, 0x6,0x39,0x27, + 0x6,0x38,0x7d, 0x6,0x38,0x75, 0x5,0x2e,0x46, 0xf,0x36,0x2d, + 0x4,0x32,0x5d, 0x5,0x33,0x40, 0x4,0x32,0x5b, 0x4,0x32,0x6b, + 0x6,0x41,0x34, 0x6,0x41,0x38, 0x6,0x41,0x3c, 0x4,0x32,0x6a, + 0x6,0x41,0x43, 0x4,0x32,0x61, 0x6,0x41,0x36, 0x4,0x32,0x65, + 0x6,0x41,0x35, 0x6,0x41,0x45, 0x4,0x32,0x69, 0x5,0x33,0x33, + 0x6,0x41,0x31, 0x4,0x32,0x60, 0x4,0x32,0x67, 0x6,0x4a,0x64, + 0x5,0x33,0x3f, 0x6,0x41,0x42, 0x5,0x33,0x3e, 0x6,0x41,0x3f, + 0x4,0x32,0x59, 0x4,0x32,0x5f, 0x6,0x41,0x2c, 0x4,0x25,0x2f, + 0x6,0x41,0x3b, 0x6,0x41,0x30, 0x6,0x4a,0x66, 0x5,0x33,0x38, + 0x5,0x33,0x41, 0x6,0x4a,0x58, 0x6,0x4a,0x59, 0x6,0x41,0x3e, + 0x6,0x41,0x44, 0x5,0x33,0x36, 0x4,0x32,0x62, 0x6,0x41,0x40, + 0x5,0x33,0x3b, 0x6,0x41,0x2f, 0x6,0x41,0x32, 0x5,0x33,0x3a, + 0x5,0x33,0x35, 0x4,0x32,0x6c, 0x4,0x32,0x6e, 0x5,0x33,0x37, + 0x6,0x41,0x3d, 0xf,0x36,0x21, 0xf,0x36,0x22, 0xf,0x36,0x23, + 0xf,0x36,0x25, 0xf,0x36,0x26, 0xf,0x36,0x27, 0xf,0x36,0x28, + 0xf,0x36,0x2a, 0xf,0x36,0x2c, 0xf,0x36,0x2e, 0xf,0x36,0x2f, + 0xf,0x36,0x30, 0xf,0x36,0x31, 0xf,0x36,0x32, 0xf,0x36,0x36, + 0xf,0x36,0x37, 0xf,0x36,0x38, 0xf,0x36,0x39, 0xf,0x36,0x3a, + 0xf,0x36,0x3b, 0xf,0x36,0x3c, 0xf,0x36,0x3d, 0xf,0x3c,0x42, + 0xf,0x3c,0x4b, 0xf,0x3c,0x4d, 0xf,0x3c,0x57, 0xf,0x42,0x5f, + 0x6,0x4a,0x57, 0x6,0x41,0x33, 0x6,0x41,0x37, 0x5,0x33,0x39, + 0x6,0x41,0x3a, 0x6,0x41,0x39, 0x6,0x41,0x47, 0x6,0x41,0x2d, + 0x6,0x41,0x2e, 0x5,0x33,0x34, 0x5,0x33,0x3c, 0x6,0x38,0x7a, + 0x6,0x4a,0x62, 0x6,0x4a,0x70, 0x4,0x38,0x54, 0x5,0x39,0x63, + 0x4,0x38,0x55, 0x6,0x4a,0x5d, 0x6,0x4a,0x5f, 0x5,0x39,0x67, + 0x5,0x39,0x6a, 0x5,0x39,0x62, 0x6,0x54,0x48, 0x5,0x39,0x6c, + 0x6,0x4a,0x5a, 0x4,0x38,0x53, 0x5,0x33,0x42, 0x4,0x38,0x58, + 0x6,0x4a,0x6c, 0x6,0x4a,0x5c, 0x5,0x39,0x68, 0x6,0x4a,0x71, + 0x6,0x54,0x35, 0x6,0x4a,0x67, 0x6,0x4a,0x68, 0x6,0x4a,0x6e, + 0x5,0x39,0x60, 0x6,0x54,0x34, 0x6,0x4a,0x6f, 0x4,0x3e,0x2c, + 0x5,0x39,0x5f, 0x5,0x39,0x66, 0x5,0x39,0x65, 0x5,0x39,0x64, + 0x6,0x4a,0x6a, 0x5,0x39,0x61, 0x6,0x54,0x33, 0x6,0x4a,0x72, + 0x5,0x39,0x6d, 0x6,0x4a,0x61, 0xf,0x3c,0x44, 0xf,0x3c,0x45, + 0xf,0x3c,0x46, 0xf,0x3c,0x48, 0xf,0x3c,0x49, 0xf,0x3c,0x4a, + 0xf,0x3c,0x4e, 0xf,0x3c,0x4f, 0xf,0x3c,0x50, 0xf,0x3c,0x51, + 0xf,0x3c,0x52, 0xf,0x3c,0x53, 0xf,0x3c,0x54, 0xf,0x3c,0x55, + 0xf,0x3c,0x56, 0xf,0x3c,0x58, 0xf,0x3c,0x59, 0xf,0x3c,0x5b, + 0xf,0x3c,0x5c, 0x6,0x4a,0x69, 0x5,0x39,0x69, 0x6,0x4a,0x6b, + 0x4,0x38,0x5d, 0x6,0x4a,0x5b, 0x6,0x4a,0x60, 0x6,0x4a,0x5e, + 0x5,0x39,0x6b, 0xf,0x42,0x73, 0x6,0x54,0x41, 0x5,0x40,0x25, + 0x4,0x3e,0x41, 0x6,0x54,0x38, 0x4,0x3e,0x34, 0x6,0x54,0x3b, + 0x6,0x54,0x43, 0x4,0x3e,0x3b, 0x4,0x3e,0x43, 0x4,0x3e,0x3e, + 0x4,0x3e,0x2e, 0x6,0x54,0x4a, 0x5,0x40,0x29, 0x5,0x40,0x26, + 0x4,0x3e,0x40, 0x6,0x5e,0x31, 0x6,0x54,0x42, 0x4,0x3e,0x3a, + 0x5,0x40,0x2f, 0x5,0x40,0x2d, 0x4,0x3e,0x31, 0x6,0x5e,0x32, + 0x4,0x3e,0x42, 0x5,0x40,0x2c, 0x5,0x40,0x2e, 0x6,0x54,0x3e, + 0x6,0x54,0x4c, 0x7,0x24,0x3c, 0x6,0x54,0x47, 0x4,0x44,0x4b, + 0x6,0x54,0x3f, 0x6,0x54,0x46, 0x6,0x54,0x37, 0x6,0x54,0x36, + 0x5,0x40,0x2b, 0x5,0x40,0x28, 0x4,0x3e,0x3d, 0x6,0x54,0x3c, + 0x6,0x54,0x3d, 0x6,0x54,0x40, 0x6,0x54,0x45, 0xf,0x42,0x58, + 0xf,0x42,0x59, 0xf,0x42,0x5a, 0xf,0x42,0x5b, 0xf,0x42,0x5c, + 0xf,0x42,0x5d, 0xf,0x42,0x5e, 0xf,0x42,0x60, 0xf,0x42,0x61, + 0xf,0x42,0x62, 0xf,0x42,0x65, 0xf,0x42,0x66, 0xf,0x42,0x67, + 0xf,0x42,0x68, 0xf,0x42,0x69, 0xf,0x42,0x6a, 0xf,0x42,0x6c, + 0xf,0x42,0x6d, 0xf,0x42,0x6e, 0xf,0x42,0x6f, 0xf,0x42,0x70, + 0xf,0x42,0x71, 0xf,0x42,0x72, 0xf,0x42,0x75, 0xf,0x49,0x22, + 0xf,0x49,0x3e, 0x5,0x40,0x2a, 0x6,0x54,0x44, 0x4,0x3e,0x35, + 0x6,0x54,0x4d, 0x6,0x54,0x3a, 0x6,0x54,0x4b, 0xf,0x49,0x2f, + 0xf,0x42,0x6b, 0xf,0x4f,0x6c, 0x6,0x54,0x39, 0x7,0x24,0x3d, + 0x4,0x44,0x54, 0x4,0x44,0x47, 0x4,0x44,0x48, 0x4,0x44,0x4c, + 0x5,0x46,0x6b, 0x4,0x44,0x4e, 0x5,0x46,0x6a, 0x5,0x46,0x74, + 0x5,0x46,0x76, 0x4,0x44,0x45, 0x4,0x44,0x53, 0x6,0x5e,0x44, + 0x5,0x46,0x6f, 0x6,0x5e,0x41, 0x6,0x5e,0x3a, 0x4,0x44,0x51, + 0x4,0x44,0x50, 0x5,0x46,0x75, 0x5,0x46,0x72, 0x5,0x46,0x6d, + 0x7,0x24,0x40, 0x7,0x24,0x3f, 0x5,0x46,0x77, 0x6,0x5e,0x45, + 0x4,0x44,0x4f, 0x6,0x5e,0x39, 0x6,0x5e,0x42, 0x5,0x46,0x70, + 0x5,0x46,0x71, 0x4,0x44,0x41, 0x6,0x5e,0x3d, 0x5,0x4d,0x7a, + 0x7,0x24,0x3e, 0x6,0x5e,0x34, 0x5,0x46,0x6e, 0x6,0x5e,0x3f, + 0x5,0x46,0x73, 0xf,0x49,0x23, 0xf,0x49,0x24, 0xf,0x49,0x25, + 0xf,0x49,0x26, 0xf,0x49,0x27, 0xf,0x49,0x28, 0xf,0x49,0x29, + 0xf,0x49,0x2b, 0xf,0x49,0x2c, 0xf,0x49,0x2d, 0xf,0x49,0x2e, + 0xf,0x49,0x30, 0xf,0x49,0x31, 0xf,0x49,0x34, 0xf,0x49,0x36, + 0xf,0x49,0x37, 0xf,0x49,0x38, 0xf,0x49,0x39, 0xf,0x49,0x3a, + 0xf,0x49,0x3c, 0xf,0x49,0x3d, 0xf,0x49,0x41, 0xf,0x49,0x42, + 0xf,0x49,0x43, 0xf,0x4f,0x6d, 0x7,0x22,0x68, 0x4,0x44,0x42, + 0x6,0x5e,0x3c, 0x6,0x5e,0x43, 0x6,0x5e,0x35, 0x5,0x46,0x6c, + 0x6,0x5e,0x33, 0x6,0x5e,0x37, 0x6,0x5e,0x38, 0xf,0x49,0x3b, + 0x6,0x5e,0x36, 0xf,0x49,0x2a, 0x7,0x24,0x62, 0x7,0x24,0x52, + 0x7,0x24,0x4d, 0x4,0x4a,0x60, 0x7,0x24,0x5a, 0x7,0x24,0x54, + 0x7,0x24,0x4c, 0x4,0x4a,0x65, 0x4,0x4a,0x67, 0x5,0x4e,0x25, + 0x7,0x24,0x63, 0x7,0x24,0x4e, 0x7,0x24,0x50, 0x7,0x24,0x56, + 0x4,0x4a,0x5c, 0x7,0x24,0x57, 0x7,0x24,0x49, 0x5,0x4e,0x21, + 0x7,0x24,0x65, 0x7,0x24,0x47, 0x7,0x24,0x44, 0x4,0x4a,0x66, + 0x5,0x4d,0x7b, 0x5,0x4e,0x24, 0x7,0x24,0x64, 0x4,0x4a,0x5b, + 0x7,0x24,0x5b, 0x4,0x4a,0x5a, 0x7,0x24,0x59, 0x5,0x4d,0x7e, + 0x7,0x24,0x43, 0x7,0x24,0x67, 0x5,0x4e,0x23, 0x5,0x4d,0x7d, + 0x7,0x24,0x53, 0x7,0x24,0x42, 0x7,0x3a,0x69, 0x7,0x24,0x45, + 0x7,0x24,0x68, 0x5,0x4e,0x22, 0x7,0x24,0x41, 0x7,0x24,0x5e, + 0x7,0x24,0x66, 0x5,0x4e,0x26, 0x5,0x4e,0x28, 0x5,0x4d,0x7c, + 0x4,0x4a,0x5e, 0x7,0x24,0x5f, 0x7,0x24,0x4b, 0x7,0x24,0x51, + 0x5,0x4e,0x27, 0x7,0x24,0x5c, 0xf,0x4f,0x59, 0xf,0x4f,0x5a, + 0xf,0x4f,0x5b, 0xf,0x4f,0x5c, 0xf,0x4f,0x5d, 0xf,0x4f,0x5e, + 0xf,0x4f,0x5f, 0xf,0x4f,0x62, 0xf,0x4f,0x63, 0xf,0x4f,0x64, + 0xf,0x4f,0x65, 0xf,0x4f,0x66, 0xf,0x4f,0x67, 0xf,0x4f,0x68, + 0xf,0x4f,0x6a, 0xf,0x4f,0x6b, 0xf,0x4f,0x6f, 0xf,0x4f,0x70, + 0xf,0x4f,0x71, 0xf,0x4f,0x72, 0xf,0x4f,0x73, 0xf,0x4f,0x74, + 0xf,0x4f,0x75, 0xf,0x4f,0x76, 0xf,0x4f,0x77, 0xf,0x4f,0x78, + 0xf,0x4f,0x7b, 0xf,0x4f,0x7c, 0xf,0x55,0x51, 0x7,0x24,0x55, + 0x7,0x24,0x60, 0x7,0x2f,0x30, 0x4,0x4a,0x63, 0x7,0x24,0x46, + 0x7,0x24,0x5d, 0x7,0x24,0x48, 0x7,0x24,0x4a, 0xf,0x55,0x4a, + 0xf,0x4f,0x7e, 0xf,0x49,0x40, 0x4,0x50,0x7c, 0x5,0x55,0x35, + 0x5,0x55,0x34, 0x5,0x55,0x28, 0x5,0x55,0x29, 0x5,0x55,0x2b, + 0x7,0x2f,0x33, 0x5,0x55,0x30, 0x7,0x2f,0x47, 0x7,0x2f,0x40, + 0x7,0x2f,0x3a, 0x4,0x50,0x79, 0x7,0x2f,0x39, 0x4,0x50,0x7e, + 0x5,0x55,0x33, 0x7,0x2f,0x3d, 0x7,0x2f,0x31, 0x7,0x2f,0x37, + 0x7,0x2f,0x46, 0x7,0x2f,0x3b, 0x7,0x2f,0x38, 0x7,0x2f,0x43, + 0x7,0x2f,0x36, 0x7,0x2f,0x32, 0x5,0x55,0x31, 0x5,0x55,0x2a, + 0x5,0x5b,0x77, 0x7,0x2f,0x3c, 0x7,0x2f,0x49, 0x5,0x55,0x2c, + 0x5,0x5b,0x79, 0x5,0x55,0x32, 0x7,0x2f,0x2f, 0x7,0x2f,0x34, + 0x7,0x2f,0x3e, 0x7,0x2f,0x41, 0xf,0x55,0x46, 0xf,0x55,0x48, + 0xf,0x55,0x49, 0xf,0x55,0x4b, 0xf,0x55,0x4c, 0xf,0x55,0x4f, + 0xf,0x55,0x50, 0xf,0x55,0x52, 0xf,0x55,0x53, 0xf,0x55,0x54, + 0xf,0x55,0x55, 0xf,0x55,0x57, 0xf,0x5a,0x6d, 0x5,0x55,0x2f, + 0x7,0x2f,0x3f, 0x7,0x2f,0x45, 0x7,0x2f,0x48, 0x7,0x2f,0x4a, + 0x7,0x2f,0x2e, 0x7,0x2f,0x44, 0x4,0x51,0x21, 0xf,0x4f,0x61, + 0xf,0x5a,0x66, 0xf,0x5a,0x5f, 0x5,0x54,0x3a, 0x5,0x5b,0x7c, + 0x4,0x56,0x5a, 0x4,0x56,0x5f, 0x5,0x5b,0x7a, 0x7,0x38,0x7a, + 0x7,0x38,0x6e, 0x4,0x5b,0x52, 0x5,0x5b,0x7b, 0x5,0x5b,0x78, + 0x7,0x38,0x70, 0x7,0x38,0x76, 0x7,0x38,0x6f, 0x7,0x38,0x79, + 0x7,0x38,0x74, 0x7,0x38,0x73, 0x5,0x62,0x38, 0x7,0x38,0x75, + 0x7,0x38,0x7b, 0x5,0x5b,0x7d, 0x7,0x38,0x77, 0x5,0x55,0x37, + 0x3,0x55,0x3a, 0x7,0x38,0x78, 0xf,0x5a,0x60, 0xf,0x5a,0x61, + 0xf,0x5a,0x62, 0xf,0x5a,0x63, 0xf,0x5a,0x64, 0xf,0x5a,0x65, + 0xf,0x5a,0x67, 0xf,0x5a,0x69, 0xf,0x5a,0x6b, 0xf,0x5a,0x70, + 0x7,0x38,0x72, 0x5,0x5b,0x7e, 0x7,0x38,0x7c, 0x7,0x38,0x71, + 0xf,0x55,0x4e, 0xf,0x5a,0x6c, 0xf,0x5a,0x6f, 0xf,0x55,0x47, + 0xf,0x55,0x4d, 0xf,0x5a,0x5e, 0x7,0x2f,0x35, 0x5,0x62,0x3f, + 0x5,0x62,0x46, 0x5,0x62,0x45, 0x4,0x5b,0x5d, 0x5,0x62,0x3d, + 0x5,0x62,0x39, 0x5,0x62,0x42, 0x7,0x40,0x40, 0x7,0x40,0x46, + 0x4,0x5b,0x59, 0x5,0x62,0x4b, 0x5,0x62,0x44, 0x7,0x40,0x3c, + 0x5,0x62,0x41, 0x5,0x62,0x4a, 0x4,0x5b,0x58, 0x5,0x62,0x43, + 0x7,0x40,0x47, 0x5,0x62,0x3b, 0x7,0x40,0x41, 0x5,0x62,0x40, + 0x7,0x40,0x48, 0x7,0x40,0x3a, 0x4,0x5b,0x5f, 0x4,0x5b,0x55, + 0x7,0x40,0x45, 0x7,0x40,0x44, 0x7,0x40,0x3e, 0x5,0x62,0x3a, + 0x4,0x5b,0x53, 0x5,0x62,0x3c, 0x5,0x62,0x3e, 0x5,0x62,0x49, + 0x5,0x62,0x4c, 0x5,0x62,0x47, 0x7,0x40,0x3f, 0x4,0x5b,0x5c, + 0x7,0x40,0x42, 0x7,0x47,0x5f, 0x5,0x62,0x4d, 0xf,0x5f,0x33, + 0xf,0x5f,0x35, 0xf,0x5f,0x36, 0xf,0x5f,0x37, 0xf,0x5f,0x39, + 0xf,0x5f,0x3a, 0xf,0x5f,0x3b, 0xf,0x5f,0x3c, 0xf,0x5f,0x3d, + 0xf,0x5f,0x3e, 0xf,0x5f,0x3f, 0xf,0x5f,0x40, 0xf,0x5f,0x41, + 0xf,0x5f,0x42, 0xf,0x5f,0x43, 0xf,0x62,0x64, 0xf,0x62,0x65, + 0xf,0x62,0x6c, 0x7,0x47,0x5e, 0x7,0x40,0x3d, 0x7,0x40,0x39, + 0x7,0x40,0x43, 0x7,0x40,0x3b, 0xf,0x5f,0x34, 0xf,0x5a,0x6a, + 0xf,0x5a,0x6e, 0x5,0x62,0x48, 0x7,0x47,0x65, 0x7,0x47,0x5c, + 0x7,0x47,0x62, 0x4,0x5f,0x7c, 0x4,0x5f,0x7a, 0x7,0x47,0x53, + 0x5,0x68,0x36, 0x7,0x47,0x56, 0x7,0x47,0x54, 0x7,0x47,0x5b, + 0x7,0x47,0x5a, 0x7,0x47,0x55, 0x5,0x68,0x35, 0x7,0x47,0x59, + 0x7,0x47,0x5d, 0x5,0x6c,0x45, 0x7,0x47,0x61, 0xf,0x62,0x66, + 0xf,0x62,0x67, 0xf,0x62,0x68, 0xf,0x62,0x69, 0xf,0x62,0x6a, + 0xf,0x62,0x6d, 0xf,0x62,0x6e, 0xf,0x62,0x6f, 0xf,0x62,0x70, + 0xf,0x62,0x71, 0x7,0x47,0x57, 0x7,0x47,0x60, 0x7,0x47,0x66, + 0x7,0x47,0x64, 0x7,0x47,0x63, 0x7,0x47,0x58, 0x5,0x6c,0x47, + 0x5,0x6c,0x4a, 0x5,0x6c,0x4b, 0x7,0x4e,0x2b, 0x4,0x63,0x59, + 0x4,0x63,0x5d, 0x7,0x4e,0x2a, 0x7,0x4e,0x29, 0x5,0x6c,0x48, + 0x4,0x63,0x5c, 0x7,0x4e,0x2e, 0x4,0x63,0x57, 0x4,0x63,0x58, + 0x4,0x63,0x56, 0x7,0x4e,0x2d, 0x5,0x70,0x3b, 0x5,0x6c,0x49, + 0x5,0x6c,0x4c, 0x7,0x4e,0x2f, 0xf,0x65,0x42, 0xf,0x65,0x43, + 0xf,0x65,0x44, 0x7,0x4e,0x2c, 0x4,0x66,0x48, 0x5,0x70,0x40, + 0x7,0x53,0x56, 0x5,0x70,0x3f, 0x5,0x70,0x3d, 0x4,0x66,0x4b, + 0x7,0x53,0x54, 0x5,0x70,0x3c, 0x7,0x53,0x59, 0x7,0x53,0x53, + 0x4,0x66,0x4d, 0x7,0x53,0x5f, 0x5,0x70,0x41, 0x7,0x53,0x55, + 0x7,0x53,0x5a, 0xf,0x67,0x68, 0xf,0x67,0x69, 0xf,0x67,0x6a, + 0xf,0x67,0x6b, 0xf,0x67,0x6d, 0xf,0x67,0x6e, 0xf,0x67,0x6f, + 0x7,0x53,0x5b, 0x7,0x53,0x5c, 0x7,0x53,0x5d, 0x7,0x53,0x5e, + 0x5,0x70,0x3a, 0xf,0x67,0x70, 0xf,0x69,0x55, 0x7,0x58,0x2e, + 0x7,0x53,0x57, 0x7,0x58,0x2f, 0x5,0x73,0x54, 0x5,0x70,0x42, + 0x7,0x58,0x2d, 0x5,0x73,0x55, 0x7,0x58,0x31, 0x4,0x68,0x72, + 0x7,0x58,0x32, 0xf,0x69,0x53, 0xf,0x69,0x54, 0x7,0x58,0x33, + 0x7,0x58,0x30, 0x7,0x58,0x2c, 0x5,0x76,0x21, 0x5,0x76,0x22, + 0x7,0x5b,0x69, 0x7,0x5b,0x68, 0x5,0x75,0x7e, 0x7,0x5b,0x67, + 0x5,0x75,0x7d, 0xf,0x6a,0x5b, 0xf,0x6a,0x5c, 0xf,0x6a,0x5d, + 0x7,0x5b,0x6a, 0x7,0x5b,0x66, 0x7,0x5e,0x76, 0x5,0x77,0x67, + 0x7,0x5e,0x77, 0x4,0x6c,0x71, 0x7,0x5e,0x74, 0x5,0x77,0x66, + 0x7,0x5e,0x75, 0x4,0x6c,0x72, 0x7,0x60,0x79, 0x7,0x60,0x78, + 0x7,0x60,0x77, 0xf,0x6c,0x2f, 0x7,0x62,0x39, 0x4,0x6d,0x58, + 0x5,0x7a,0x2b, 0x5,0x7a,0x2a, 0x4,0x6d,0x59, 0x4,0x6d,0x74, + 0x5,0x7a,0x69, 0x5,0x7a,0x6a, 0x7,0x63,0x57, 0x7,0x64,0x4b, + 0x5,0x7b,0x41, 0xf,0x6d,0x26, 0x7,0x65,0x5c, 0x5,0x7c,0x3c, + 0x6,0x23,0x2f, 0x6,0x25,0x33, 0x4,0x23,0x24, 0x4,0x23,0x25, + 0x6,0x25,0x32, 0xf,0x22,0x5f, 0xf,0x22,0x60, 0xf,0x22,0x61, + 0x6,0x25,0x34, 0x4,0x24,0x53, 0x4,0x24,0x54, 0x5,0x24,0x54, + 0x6,0x28,0x4c, 0x5,0x24,0x55, 0x5,0x24,0x57, 0xf,0x24,0x6b, + 0xf,0x24,0x6c, 0xf,0x24,0x6d, 0xf,0x24,0x70, 0xf,0x24,0x72, + 0x6,0x28,0x4b, 0x5,0x26,0x74, 0x4,0x27,0x28, 0x5,0x26,0x75, + 0xf,0x27,0x6f, 0xf,0x27,0x70, 0xf,0x27,0x71, 0xf,0x27,0x73, + 0xf,0x27,0x74, 0xf,0x27,0x75, 0xf,0x27,0x76, 0xf,0x27,0x77, + 0x6,0x2c,0x5f, 0xf,0x27,0x72, 0x6,0x2c,0x5e, 0x4,0x27,0x2a, + 0x5,0x24,0x56, 0x5,0x2a,0x25, 0x6,0x32,0x4c, 0x5,0x2a,0x26, + 0x6,0x32,0x44, 0x5,0x2a,0x27, 0x6,0x32,0x4b, 0x6,0x32,0x46, + 0xf,0x2b,0x6f, 0xf,0x2b,0x70, 0xf,0x2b,0x71, 0xf,0x2b,0x72, + 0xf,0x2b,0x73, 0xf,0x2b,0x74, 0xf,0x2b,0x75, 0xf,0x2b,0x76, + 0xf,0x2b,0x77, 0xf,0x2b,0x78, 0xf,0x2b,0x79, 0xf,0x2b,0x7b, + 0xf,0x2b,0x7c, 0xf,0x2b,0x7d, 0xf,0x2b,0x7e, 0xf,0x2c,0x21, + 0xf,0x2c,0x23, 0x4,0x2a,0x29, 0x6,0x32,0x45, 0x6,0x32,0x43, + 0x6,0x32,0x47, 0x6,0x39,0x3a, 0x5,0x2a,0x28, 0x6,0x32,0x4a, + 0xf,0x2c,0x22, 0x6,0x32,0x49, 0x5,0x2e,0x4f, 0x5,0x2e,0x4e, + 0x6,0x39,0x36, 0x6,0x39,0x39, 0xf,0x30,0x6a, 0x4,0x32,0x6f, + 0x6,0x39,0x37, 0x4,0x2d,0x74, 0x6,0x39,0x34, 0x5,0x2e,0x4b, + 0xf,0x30,0x5d, 0xf,0x30,0x5e, 0xf,0x30,0x5f, 0xf,0x30,0x60, + 0xf,0x30,0x61, 0xf,0x30,0x62, 0xf,0x30,0x63, 0xf,0x30,0x64, + 0xf,0x30,0x65, 0xf,0x30,0x66, 0xf,0x30,0x68, 0xf,0x30,0x69, + 0xf,0x30,0x6b, 0xf,0x30,0x6c, 0xf,0x30,0x6e, 0xf,0x30,0x6f, + 0xf,0x30,0x70, 0xf,0x30,0x71, 0xf,0x30,0x72, 0x5,0x2e,0x4c, + 0x6,0x39,0x35, 0x6,0x39,0x3b, 0x6,0x39,0x3c, 0xf,0x30,0x67, + 0xf,0x30,0x6d, 0x6,0x39,0x38, 0x5,0x2e,0x4d, 0x6,0x41,0x4b, + 0x4,0x32,0x74, 0x5,0x33,0x44, 0x6,0x41,0x4f, 0x4,0x32,0x73, + 0x4,0x32,0x75, 0x6,0x41,0x4e, 0x6,0x41,0x54, 0x6,0x41,0x51, + 0x6,0x41,0x4d, 0x6,0x41,0x4c, 0x6,0x4a,0x73, 0x6,0x41,0x52, + 0x6,0x41,0x50, 0x6,0x41,0x53, 0xf,0x36,0x24, 0xf,0x36,0x3e, + 0xf,0x36,0x3f, 0xf,0x36,0x40, 0xf,0x36,0x41, 0xf,0x36,0x43, + 0xf,0x36,0x44, 0xf,0x36,0x45, 0xf,0x36,0x46, 0xf,0x36,0x47, + 0xf,0x36,0x49, 0xf,0x36,0x4a, 0xf,0x36,0x4c, 0xf,0x36,0x4d, + 0xf,0x36,0x4e, 0xf,0x36,0x50, 0x6,0x41,0x49, 0x6,0x41,0x48, + 0xf,0x36,0x4b, 0x5,0x33,0x43, 0x5,0x33,0x45, 0x6,0x41,0x55, + 0x4,0x38,0x69, 0x6,0x4a,0x78, 0x6,0x41,0x4a, 0x5,0x39,0x71, + 0x5,0x39,0x6f, 0x6,0x4a,0x7e, 0x6,0x4b,0x21, 0x5,0x39,0x6e, + 0x6,0x4a,0x75, 0x4,0x38,0x66, 0x6,0x4a,0x7a, 0x6,0x4a,0x74, + 0x6,0x4a,0x7d, 0x4,0x38,0x63, 0x5,0x39,0x70, 0x6,0x4a,0x77, + 0xf,0x3c,0x5e, 0xf,0x3c,0x5f, 0xf,0x3c,0x60, 0xf,0x3c,0x61, + 0xf,0x3c,0x62, 0xf,0x3c,0x63, 0xf,0x3c,0x64, 0xf,0x3c,0x66, + 0xf,0x3c,0x67, 0xf,0x3c,0x68, 0xf,0x3c,0x69, 0xf,0x3c,0x6b, + 0xf,0x3c,0x6c, 0xf,0x3c,0x6d, 0xf,0x3c,0x6e, 0xf,0x3c,0x6f, + 0xf,0x3c,0x70, 0xf,0x3c,0x71, 0xf,0x3c,0x72, 0xf,0x3c,0x75, + 0xf,0x3c,0x77, 0xf,0x3c,0x78, 0xf,0x3c,0x79, 0xf,0x3c,0x7a, + 0xf,0x3c,0x7b, 0xf,0x3c,0x7c, 0xf,0x3d,0x21, 0x6,0x4a,0x79, + 0x6,0x4a,0x7c, 0x4,0x38,0x67, 0x6,0x4a,0x76, 0x6,0x4a,0x7b, + 0xf,0x3c,0x6a, 0x5,0x39,0x72, 0x5,0x40,0x34, 0x6,0x54,0x5a, + 0x6,0x54,0x58, 0x5,0x40,0x30, 0x6,0x54,0x56, 0x6,0x54,0x5d, + 0x4,0x3e,0x47, 0x6,0x54,0x57, 0x4,0x3e,0x44, 0x6,0x54,0x5b, + 0x6,0x54,0x5e, 0x4,0x3e,0x45, 0x5,0x40,0x32, 0x6,0x54,0x53, + 0x6,0x54,0x63, 0x6,0x54,0x5f, 0x6,0x54,0x64, 0x5,0x40,0x35, + 0x6,0x54,0x5c, 0x6,0x54,0x62, 0xf,0x42,0x76, 0xf,0x42,0x79, + 0xf,0x42,0x7b, 0xf,0x42,0x7c, 0xf,0x42,0x7d, 0xf,0x43,0x21, + 0xf,0x43,0x22, 0xf,0x43,0x23, 0xf,0x43,0x25, 0xf,0x43,0x26, + 0xf,0x43,0x27, 0xf,0x43,0x28, 0xf,0x43,0x29, 0xf,0x43,0x2a, + 0xf,0x43,0x2b, 0xf,0x43,0x2d, 0xf,0x43,0x2e, 0xf,0x43,0x30, + 0xf,0x43,0x33, 0xf,0x43,0x34, 0xf,0x43,0x35, 0xf,0x43,0x36, + 0xf,0x43,0x37, 0xf,0x43,0x38, 0xf,0x43,0x39, 0xf,0x43,0x3a, + 0xf,0x43,0x3b, 0xf,0x43,0x3d, 0xf,0x43,0x3e, 0x6,0x54,0x51, + 0x6,0x54,0x52, 0x6,0x54,0x55, 0x6,0x54,0x66, 0x4,0x3e,0x4a, + 0x6,0x54,0x61, 0x6,0x54,0x65, 0x6,0x5a,0x54, 0xf,0x43,0x2c, + 0x5,0x40,0x33, 0x5,0x40,0x31, 0xf,0x49,0x54, 0x6,0x5e,0x51, + 0x6,0x5e,0x50, 0x5,0x46,0x7e, 0x6,0x5e,0x4a, 0x5,0x47,0x22, + 0x4,0x44,0x55, 0x5,0x46,0x7c, 0x5,0x46,0x7b, 0x5,0x46,0x7a, + 0x7,0x24,0x70, 0x7,0x24,0x6a, 0x6,0x5e,0x46, 0x5,0x47,0x21, + 0x6,0x5e,0x47, 0x6,0x5e,0x48, 0x5,0x46,0x79, 0x6,0x5e,0x4b, + 0x6,0x5e,0x4f, 0xf,0x49,0x44, 0xf,0x49,0x45, 0xf,0x49,0x46, + 0xf,0x49,0x47, 0xf,0x49,0x49, 0xf,0x49,0x4a, 0xf,0x49,0x4c, + 0xf,0x49,0x4d, 0xf,0x49,0x4e, 0xf,0x49,0x4f, 0xf,0x49,0x50, + 0xf,0x49,0x51, 0xf,0x49,0x52, 0xf,0x49,0x53, 0xf,0x49,0x55, + 0xf,0x49,0x56, 0xf,0x49,0x57, 0xf,0x49,0x5a, 0xf,0x49,0x5b, + 0xf,0x49,0x5d, 0xf,0x49,0x5e, 0xf,0x49,0x60, 0xf,0x49,0x62, + 0xf,0x49,0x63, 0xf,0x49,0x64, 0x4,0x44,0x5d, 0x5,0x46,0x7d, + 0x6,0x5e,0x4c, 0x6,0x5e,0x52, 0x6,0x5e,0x49, 0x6,0x5e,0x4d, + 0xf,0x49,0x5c, 0x6,0x54,0x60, 0xf,0x42,0x7e, 0xf,0x42,0x7a, + 0x4,0x4a,0x6b, 0x5,0x4e,0x2c, 0x7,0x24,0x74, 0x7,0x24,0x6d, + 0x7,0x24,0x69, 0x5,0x4e,0x2a, 0x7,0x24,0x6c, 0x7,0x24,0x71, + 0x7,0x24,0x72, 0x7,0x24,0x75, 0x7,0x24,0x6b, 0x5,0x4e,0x29, + 0xf,0x4e,0x22, 0x5,0x4e,0x2b, 0x7,0x24,0x73, 0xf,0x50,0x23, + 0xf,0x50,0x24, 0xf,0x50,0x26, 0xf,0x50,0x27, 0xf,0x50,0x28, + 0xf,0x50,0x29, 0xf,0x50,0x2a, 0xf,0x50,0x2b, 0xf,0x50,0x2e, + 0xf,0x50,0x2f, 0xf,0x50,0x31, 0xf,0x50,0x32, 0xf,0x50,0x33, + 0xf,0x50,0x34, 0xf,0x50,0x35, 0xf,0x50,0x37, 0xf,0x50,0x38, + 0xf,0x50,0x39, 0xf,0x50,0x3a, 0xf,0x50,0x3b, 0xf,0x50,0x3c, + 0x7,0x24,0x6e, 0xf,0x50,0x2c, 0x7,0x2a,0x71, 0xf,0x50,0x2d, + 0xf,0x50,0x30, 0xf,0x50,0x25, 0xf,0x50,0x22, 0x5,0x4e,0x2e, + 0x5,0x4e,0x2d, 0x6,0x5e,0x4e, 0x4,0x51,0x2a, 0x7,0x2f,0x52, + 0x7,0x2f,0x66, 0x7,0x2f,0x50, 0x7,0x2f,0x60, 0x7,0x2f,0x5e, + 0x5,0x55,0x3b, 0x4,0x51,0x27, 0x7,0x2f,0x61, 0x7,0x2f,0x63, + 0x7,0x2f,0x55, 0x7,0x24,0x6f, 0x4,0x51,0x28, 0x7,0x2f,0x56, + 0x7,0x2f,0x64, 0x7,0x2f,0x65, 0x4,0x51,0x26, 0x7,0x2f,0x58, + 0x7,0x2f,0x54, 0x4,0x51,0x29, 0x7,0x2f,0x67, 0x5,0x55,0x3a, + 0x5,0x55,0x3c, 0x7,0x2f,0x62, 0x7,0x2f,0x59, 0x7,0x2f,0x5d, + 0x7,0x2f,0x5a, 0x7,0x2f,0x4b, 0x7,0x2f,0x53, 0x7,0x2f,0x5c, + 0xf,0x55,0x59, 0xf,0x55,0x5a, 0xf,0x55,0x5b, 0xf,0x55,0x5c, + 0xf,0x55,0x5d, 0xf,0x55,0x5e, 0xf,0x55,0x5f, 0xf,0x55,0x60, + 0xf,0x55,0x61, 0xf,0x55,0x62, 0xf,0x55,0x63, 0xf,0x55,0x66, + 0xf,0x55,0x67, 0xf,0x55,0x68, 0xf,0x55,0x6a, 0xf,0x55,0x6b, + 0xf,0x55,0x6d, 0xf,0x55,0x6e, 0xf,0x55,0x70, 0xf,0x55,0x71, + 0xf,0x55,0x72, 0xf,0x55,0x65, 0x5,0x55,0x38, 0x7,0x2f,0x4d, + 0x7,0x2f,0x4e, 0x7,0x2f,0x5b, 0x7,0x2f,0x5f, 0x7,0x31,0x7a, + 0x7,0x2f,0x51, 0x7,0x2c,0x7b, 0xf,0x55,0x6f, 0x5,0x55,0x3d, + 0x5,0x55,0x39, 0x7,0x2f,0x4c, 0x7,0x24,0x76, 0x7,0x2f,0x57, + 0x7,0x39,0x23, 0x4,0x56,0x61, 0x7,0x39,0x25, 0x5,0x55,0x3e, + 0x7,0x39,0x29, 0x7,0x39,0x28, 0x4,0x56,0x63, 0x7,0x2f,0x68, + 0x5,0x5c,0x21, 0x7,0x38,0x7d, 0x5,0x5c,0x24, 0x5,0x5c,0x22, + 0xf,0x5a,0x71, 0xf,0x5a,0x72, 0xf,0x5a,0x76, 0xf,0x5a,0x77, + 0xf,0x5a,0x78, 0xf,0x5a,0x79, 0xf,0x5a,0x7a, 0xf,0x5a,0x7b, + 0xf,0x5a,0x7c, 0xf,0x5a,0x7d, 0xf,0x5a,0x7e, 0xf,0x5b,0x21, + 0xf,0x5b,0x22, 0xf,0x5b,0x23, 0x7,0x38,0x7e, 0x7,0x39,0x24, + 0x7,0x39,0x22, 0x5,0x5c,0x23, 0x7,0x39,0x21, 0xf,0x55,0x69, + 0x7,0x40,0x4f, 0x4,0x5b,0x62, 0x7,0x40,0x4e, 0x5,0x62,0x4e, + 0x7,0x40,0x4b, 0x7,0x40,0x53, 0x7,0x40,0x51, 0x7,0x40,0x4c, + 0x4,0x5b,0x63, 0x5,0x62,0x4f, 0x5,0x62,0x50, 0x4,0x5b,0x61, + 0x7,0x40,0x54, 0x7,0x40,0x4a, 0x7,0x40,0x52, 0xf,0x5f,0x44, + 0xf,0x5f,0x46, 0xf,0x5f,0x45, 0xf,0x5f,0x47, 0xf,0x5f,0x48, + 0xf,0x5f,0x49, 0xf,0x5f,0x4a, 0xf,0x5f,0x4c, 0xf,0x5f,0x4d, + 0x7,0x40,0x50, 0x7,0x42,0x22, 0x7,0x40,0x55, 0x7,0x40,0x4d, + 0x7,0x40,0x49, 0x7,0x39,0x2a, 0xf,0x61,0x76, 0xf,0x5a,0x74, + 0xf,0x5a,0x75, 0x7,0x47,0x6c, 0x5,0x68,0x37, 0x4,0x60,0x21, + 0x7,0x47,0x6d, 0x4,0x60,0x22, 0x7,0x47,0x6a, 0xf,0x62,0x74, + 0xf,0x62,0x75, 0xf,0x62,0x76, 0xf,0x62,0x77, 0x7,0x47,0x69, + 0x7,0x47,0x67, 0x7,0x47,0x6b, 0xf,0x5f,0x4b, 0x7,0x47,0x68, + 0xf,0x65,0x45, 0x5,0x6c,0x4f, 0x7,0x4e,0x30, 0x7,0x4e,0x33, + 0x7,0x4e,0x3b, 0x5,0x6c,0x4e, 0x5,0x6c,0x4d, 0x5,0x6c,0x51, + 0x4,0x60,0x23, 0x7,0x4e,0x32, 0x7,0x4e,0x38, 0x4,0x63,0x62, + 0x4,0x63,0x60, 0x7,0x4e,0x3c, 0x7,0x4e,0x31, 0x7,0x4e,0x35, + 0x7,0x4e,0x37, 0xf,0x65,0x48, 0x7,0x4e,0x34, 0xf,0x65,0x46, + 0xf,0x65,0x47, 0xf,0x65,0x4a, 0xf,0x65,0x4b, 0xf,0x65,0x4c, + 0xf,0x65,0x4d, 0xf,0x65,0x4e, 0x7,0x4e,0x39, 0x7,0x4e,0x36, + 0x7,0x4e,0x3a, 0x5,0x6c,0x50, 0x7,0x53,0x64, 0x4,0x63,0x61, + 0x7,0x53,0x66, 0x5,0x70,0x43, 0x4,0x66,0x4f, 0x7,0x53,0x67, + 0x7,0x53,0x62, 0x7,0x53,0x63, 0x7,0x53,0x65, 0xf,0x67,0x71, + 0xf,0x67,0x72, 0xf,0x67,0x73, 0xf,0x67,0x74, 0xf,0x67,0x75, + 0x7,0x58,0x36, 0x5,0x73,0x56, 0x4,0x6a,0x4f, 0x7,0x58,0x37, + 0x7,0x58,0x38, 0x7,0x58,0x34, 0xf,0x69,0x56, 0xf,0x69,0x57, + 0xf,0x69,0x58, 0x7,0x58,0x35, 0x7,0x5b,0x24, 0x7,0x5b,0x6e, + 0x7,0x5b,0x70, 0x7,0x5b,0x6d, 0x7,0x5c,0x44, 0x7,0x5b,0x6f, + 0x7,0x5b,0x6c, 0x7,0x5b,0x6b, 0x5,0x76,0x23, 0xf,0x6a,0x60, + 0x7,0x5e,0x78, 0xf,0x6a,0x5f, 0x5,0x77,0x68, 0x7,0x61,0x21, + 0x7,0x60,0x7c, 0x7,0x60,0x7e, 0x7,0x61,0x38, 0x7,0x60,0x7b, + 0x7,0x60,0x7d, 0x7,0x62,0x3a, 0x5,0x7a,0x6b, 0xf,0x6c,0x64, + 0xf,0x6c,0x65, 0x7,0x64,0x4d, 0x7,0x64,0x4c, 0x7,0x64,0x4e, + 0x7,0x65,0x37, 0x7,0x66,0x34, 0x5,0x21,0x4b, 0x6,0x23,0x30, + 0x6,0x28,0x4d, 0x6,0x28,0x4e, 0x5,0x24,0x58, 0x6,0x2c,0x62, + 0x6,0x2c,0x61, 0x6,0x2c,0x63, 0xf,0x27,0x78, 0xf,0x27,0x79, + 0x6,0x32,0x4e, 0x5,0x2a,0x2b, 0x5,0x2a,0x29, 0x6,0x32,0x4f, + 0x5,0x2a,0x2a, 0x6,0x32,0x51, 0xf,0x2c,0x24, 0xf,0x2c,0x25, + 0xf,0x2c,0x26, 0x6,0x32,0x4d, 0x6,0x32,0x50, 0x5,0x2e,0x51, + 0x5,0x2e,0x50, 0xf,0x30,0x73, 0x6,0x41,0x57, 0x6,0x41,0x56, + 0x6,0x41,0x58, 0xf,0x36,0x51, 0x4,0x38,0x6a, 0x6,0x4b,0x22, + 0x6,0x47,0x43, 0x6,0x4d,0x5d, 0x6,0x54,0x68, 0x6,0x54,0x69, + 0x6,0x5e,0x53, 0x5,0x47,0x23, 0x6,0x5e,0x56, 0x6,0x5e,0x55, + 0x6,0x5e,0x54, 0x7,0x24,0x7a, 0x5,0x4e,0x2f, 0x7,0x24,0x77, + 0x7,0x24,0x79, 0x7,0x24,0x78, 0x7,0x2f,0x69, 0x7,0x2f,0x6a, + 0x5,0x55,0x3f, 0x4,0x56,0x65, 0xf,0x5b,0x24, 0xf,0x5b,0x25, + 0xf,0x5b,0x26, 0xf,0x55,0x73, 0x7,0x40,0x56, 0x5,0x68,0x38, + 0xf,0x65,0x4f, 0xf,0x65,0x50, 0x7,0x4e,0x3d, 0x7,0x53,0x68, + 0x7,0x5b,0x71, 0x7,0x5e,0x79, 0x7,0x61,0x22, 0xf,0x24,0x73, + 0xf,0x24,0x74, 0x6,0x2c,0x64, 0x6,0x2c,0x65, 0x6,0x41,0x59, + 0x6,0x41,0x5a, 0xf,0x3d,0x22, 0xf,0x3d,0x23, 0x6,0x54,0x6a, + 0xf,0x49,0x65, 0x5,0x47,0x24, 0x5,0x55,0x40, 0xf,0x21,0x68, + 0x6,0x2b,0x6b, 0x5,0x2a,0x2c, 0x4,0x2a,0x2b, 0x4,0x2d,0x77, + 0xf,0x30,0x74, 0x5,0x31,0x6c, 0x6,0x4b,0x23, 0x6,0x54,0x6c, + 0x6,0x54,0x6b, 0x5,0x55,0x41, 0x7,0x24,0x7b, 0x7,0x24,0x7c, + 0x5,0x55,0x42, 0x6,0x22,0x25, 0x6,0x23,0x31, 0x6,0x25,0x35, + 0x6,0x28,0x4f, 0x4,0x27,0x2d, 0x6,0x2c,0x67, 0x6,0x2c,0x66, + 0x6,0x32,0x52, 0x4,0x2a,0x2d, 0x6,0x32,0x53, 0x6,0x32,0x54, + 0x6,0x39,0x3e, 0x4,0x2d,0x78, 0xf,0x30,0x75, 0x6,0x39,0x3d, + 0x6,0x41,0x5b, 0x6,0x41,0x5e, 0x6,0x41,0x5d, 0x4,0x32,0x78, + 0x6,0x41,0x5c, 0xf,0x36,0x52, 0xf,0x36,0x53, 0x6,0x4b,0x28, + 0x6,0x4b,0x24, 0x6,0x4b,0x26, 0x6,0x4b,0x27, 0x6,0x4b,0x29, + 0x6,0x4b,0x25, 0x6,0x4d,0x58, 0x6,0x54,0x6d, 0x6,0x54,0x6e, + 0xf,0x43,0x3f, 0x6,0x5e,0x58, 0x6,0x5e,0x59, 0xf,0x49,0x66, + 0x7,0x24,0x7d, 0xf,0x50,0x3e, 0x7,0x24,0x7e, 0x5,0x55,0x43, + 0x5,0x62,0x51, 0x4,0x51,0x2c, 0x7,0x2f,0x6b, 0x7,0x25,0x21, + 0x5,0x55,0x44, 0x7,0x39,0x2b, 0x7,0x39,0x2c, 0x5,0x5c,0x25, + 0x7,0x47,0x70, 0x5,0x6c,0x52, 0x7,0x58,0x39, 0x7,0x5b,0x72, + 0x7,0x63,0x58, 0x5,0x7b,0x42, 0x7,0x64,0x4f, 0xf,0x21,0x69, + 0x6,0x28,0x51, 0x5,0x24,0x59, 0x6,0x28,0x50, 0x4,0x27,0x2e, + 0x6,0x2c,0x6b, 0x6,0x2c,0x6a, 0x6,0x2c,0x69, 0x6,0x2c,0x68, + 0x6,0x32,0x56, 0x6,0x32,0x55, 0x5,0x2a,0x2d, 0x6,0x32,0x57, + 0x5,0x2a,0x2e, 0x5,0x2e,0x52, 0x4,0x2d,0x79, 0x4,0x2d,0x7b, + 0x6,0x39,0x41, 0x6,0x39,0x3f, 0x5,0x33,0x46, 0x5,0x33,0x47, + 0x6,0x41,0x5f, 0x6,0x41,0x62, 0x6,0x41,0x60, 0x6,0x4b,0x2b, + 0x4,0x38,0x6d, 0x6,0x4b,0x2e, 0x6,0x4b,0x2a, 0x6,0x4b,0x2c, + 0x6,0x4b,0x2d, 0x5,0x39,0x73, 0x5,0x39,0x76, 0x5,0x39,0x74, + 0x5,0x39,0x75, 0x4,0x38,0x6e, 0x5,0x40,0x38, 0x6,0x54,0x6f, + 0x4,0x3e,0x4d, 0x5,0x40,0x36, 0x5,0x40,0x37, 0x6,0x54,0x70, + 0xf,0x3d,0x24, 0x5,0x47,0x25, 0x6,0x5e,0x5b, 0x6,0x5e,0x5c, + 0x6,0x5e,0x5a, 0xf,0x49,0x67, 0x5,0x4e,0x32, 0x7,0x25,0x25, + 0x5,0x4e,0x31, 0x5,0x4e,0x30, 0x5,0x4e,0x33, 0x7,0x25,0x24, + 0x7,0x25,0x22, 0x5,0x4e,0x34, 0x7,0x25,0x23, 0x5,0x55,0x46, + 0x5,0x55,0x47, 0x5,0x55,0x48, 0x7,0x2f,0x6d, 0x5,0x55,0x45, + 0x7,0x2f,0x6c, 0x5,0x5c,0x26, 0x4,0x56,0x66, 0xf,0x5b,0x27, + 0xf,0x5b,0x28, 0x5,0x62,0x53, 0x5,0x62,0x52, 0x5,0x6c,0x53, + 0x7,0x53,0x69, 0x5,0x23,0x68, 0x6,0x39,0x43, 0x6,0x39,0x42, + 0x4,0x38,0x6f, 0x6,0x4b,0x2f, 0xf,0x3d,0x25, 0xf,0x3d,0x26, + 0x6,0x54,0x71, 0x6,0x5e,0x5d, 0x5,0x21,0x75, 0xf,0x22,0x63, + 0x6,0x25,0x36, 0xf,0x22,0x62, 0x6,0x28,0x53, 0xf,0x24,0x75, + 0x6,0x28,0x52, 0x6,0x28,0x54, 0x5,0x26,0x79, 0x5,0x27,0x22, + 0x5,0x26,0x78, 0x5,0x26,0x7b, 0x5,0x26,0x76, 0x5,0x26,0x7d, + 0x6,0x2c,0x6e, 0x4,0x27,0x30, 0x5,0x27,0x21, 0x6,0x2c,0x6c, + 0x5,0x26,0x7e, 0x5,0x27,0x23, 0x5,0x26,0x7c, 0x6,0x2c,0x6d, + 0xf,0x27,0x7b, 0xf,0x27,0x7c, 0xf,0x27,0x7e, 0xf,0x28,0x21, + 0x5,0x26,0x7a, 0x6,0x2c,0x6f, 0x6,0x2c,0x70, 0x5,0x2a,0x32, + 0x5,0x2a,0x30, 0x5,0x2a,0x2f, 0x6,0x32,0x5f, 0x6,0x32,0x5c, + 0x5,0x2a,0x33, 0x5,0x2a,0x31, 0x4,0x2a,0x30, 0x6,0x32,0x5a, + 0x6,0x32,0x59, 0xf,0x2c,0x28, 0xf,0x2c,0x29, 0x6,0x32,0x5b, + 0x6,0x32,0x5e, 0x6,0x32,0x58, 0x6,0x32,0x5d, 0x5,0x2a,0x34, + 0xf,0x27,0x7d, 0x5,0x2e,0x58, 0x5,0x2e,0x54, 0x5,0x2e,0x56, + 0x5,0x2e,0x57, 0x5,0x2e,0x55, 0x6,0x39,0x44, 0x5,0x2e,0x59, + 0x4,0x32,0x7b, 0x6,0x41,0x67, 0x6,0x41,0x68, 0x5,0x33,0x49, + 0x5,0x39,0x77, 0x4,0x32,0x7d, 0x4,0x32,0x7c, 0x5,0x33,0x4b, + 0x5,0x33,0x4c, 0xf,0x36,0x54, 0xf,0x36,0x55, 0x6,0x41,0x65, + 0x6,0x41,0x69, 0x6,0x41,0x64, 0x5,0x33,0x48, 0x4,0x38,0x71, + 0x4,0x38,0x74, 0x5,0x39,0x7d, 0x6,0x4b,0x34, 0x5,0x39,0x79, + 0x5,0x39,0x7b, 0x5,0x39,0x78, 0x6,0x4b,0x32, 0x6,0x4b,0x35, + 0xf,0x3d,0x27, 0xf,0x3d,0x28, 0x6,0x4b,0x33, 0x6,0x4b,0x30, + 0x6,0x4b,0x31, 0x5,0x39,0x7a, 0x5,0x39,0x7c, 0x5,0x33,0x4a, + 0xf,0x3d,0x29, 0x6,0x4b,0x36, 0x5,0x47,0x2b, 0x5,0x40,0x3e, + 0x5,0x40,0x3c, 0x4,0x3e,0x50, 0x6,0x5e,0x64, 0x6,0x54,0x73, + 0x5,0x47,0x26, 0x6,0x54,0x72, 0x6,0x54,0x75, 0x6,0x54,0x74, + 0xf,0x43,0x40, 0xf,0x43,0x41, 0x5,0x40,0x3d, 0x6,0x54,0x77, + 0x5,0x40,0x3b, 0x4,0x44,0x61, 0x5,0x47,0x2d, 0x5,0x47,0x28, + 0x5,0x47,0x2e, 0x5,0x47,0x2c, 0x6,0x5e,0x5f, 0x6,0x5e,0x63, + 0x5,0x47,0x27, 0x5,0x47,0x2a, 0x6,0x5e,0x67, 0x6,0x5e,0x62, + 0x6,0x5e,0x61, 0x5,0x40,0x3a, 0x6,0x5e,0x66, 0xf,0x49,0x68, + 0xf,0x49,0x69, 0xf,0x49,0x6a, 0xf,0x49,0x6b, 0x5,0x47,0x2f, + 0x5,0x47,0x29, 0x6,0x5e,0x60, 0x6,0x54,0x76, 0x6,0x5e,0x65, + 0xf,0x49,0x6c, 0x5,0x47,0x30, 0x5,0x4e,0x36, 0x7,0x25,0x26, + 0x4,0x4a,0x74, 0x5,0x4e,0x39, 0x5,0x4e,0x3a, 0x5,0x4e,0x38, + 0x4,0x4a,0x70, 0x5,0x4e,0x35, 0xf,0x50,0x3f, 0x7,0x25,0x28, + 0x7,0x25,0x27, 0x7,0x2f,0x70, 0x5,0x55,0x49, 0x5,0x55,0x4e, + 0x7,0x2f,0x71, 0x5,0x55,0x4b, 0x5,0x55,0x4d, 0x5,0x55,0x4a, + 0x5,0x55,0x4c, 0x7,0x2f,0x6f, 0x7,0x39,0x30, 0x7,0x39,0x2e, + 0x5,0x5c,0x27, 0x4,0x56,0x68, 0x4,0x56,0x69, 0x7,0x2f,0x6e, + 0x7,0x39,0x2f, 0x7,0x40,0x57, 0x7,0x40,0x58, 0x5,0x68,0x3a, + 0x7,0x53,0x6a, 0x7,0x47,0x72, 0x7,0x47,0x73, 0x7,0x47,0x71, + 0x5,0x68,0x39, 0x7,0x4e,0x3f, 0x5,0x6c,0x54, 0x5,0x6c,0x55, + 0x5,0x70,0x45, 0x7,0x53,0x6c, 0x5,0x70,0x44, 0x5,0x70,0x46, + 0x7,0x58,0x3a, 0x5,0x73,0x59, 0x7,0x5b,0x74, 0x5,0x73,0x58, + 0x7,0x5b,0x75, 0x7,0x5b,0x73, 0x5,0x77,0x69, 0x7,0x61,0x23, + 0xf,0x6c,0x31, 0x7,0x64,0x50, 0xf,0x21,0x3d, 0x6,0x23,0x32, + 0x5,0x21,0x77, 0x5,0x21,0x78, 0x5,0x22,0x78, 0x5,0x22,0x7b, + 0x5,0x22,0x77, 0x4,0x23,0x28, 0x5,0x22,0x7a, 0x6,0x25,0x37, + 0x5,0x22,0x79, 0x5,0x24,0x5e, 0x5,0x24,0x5f, 0x4,0x24,0x5b, + 0x4,0x27,0x37, 0x6,0x28,0x58, 0x4,0x24,0x5a, 0x5,0x24,0x5a, + 0x6,0x28,0x5e, 0x5,0x24,0x5b, 0x6,0x28,0x5b, 0x5,0x27,0x2f, + 0x6,0x2c,0x72, 0x4,0x24,0x57, 0x5,0x24,0x5d, 0x5,0x24,0x5c, + 0x6,0x28,0x5a, 0x6,0x28,0x59, 0x6,0x2c,0x73, 0xf,0x24,0x77, + 0x6,0x28,0x57, 0x6,0x28,0x5c, 0x6,0x28,0x5d, 0x6,0x28,0x56, + 0x4,0x24,0x58, 0x6,0x2c,0x7a, 0x5,0x27,0x28, 0x6,0x2c,0x7b, + 0x5,0x27,0x2c, 0x6,0x2c,0x79, 0x6,0x2c,0x7c, 0x5,0x27,0x27, + 0x5,0x27,0x2a, 0x6,0x2c,0x78, 0x5,0x27,0x2d, 0x5,0x27,0x25, + 0x5,0x27,0x29, 0x5,0x27,0x24, 0x6,0x2c,0x77, 0x4,0x27,0x38, + 0x5,0x2a,0x36, 0x6,0x28,0x55, 0x6,0x32,0x60, 0x5,0x27,0x2b, + 0x6,0x2c,0x76, 0xf,0x28,0x22, 0x6,0x2c,0x7d, 0x6,0x2c,0x74, + 0x4,0x27,0x35, 0x5,0x2a,0x35, 0x5,0x2a,0x3e, 0x6,0x32,0x68, + 0x5,0x2a,0x39, 0x6,0x39,0x4b, 0x5,0x2a,0x3d, 0x6,0x32,0x61, + 0x6,0x39,0x4c, 0x6,0x41,0x6c, 0x5,0x2a,0x3c, 0x4,0x2a,0x31, + 0x5,0x2a,0x3b, 0x6,0x32,0x64, 0x5,0x2a,0x3a, 0x6,0x32,0x66, + 0x4,0x2a,0x33, 0x5,0x2a,0x40, 0x6,0x32,0x63, 0x5,0x27,0x26, + 0x5,0x2a,0x37, 0x5,0x2a,0x38, 0xf,0x2c,0x2a, 0xf,0x2c,0x2c, + 0xf,0x2c,0x2d, 0x6,0x32,0x65, 0xf,0x2c,0x2b, 0x5,0x2a,0x3f, + 0x6,0x39,0x4e, 0x5,0x2e,0x5e, 0x4,0x33,0x21, 0x6,0x39,0x49, + 0x6,0x39,0x4d, 0x4,0x2e,0x25, 0x5,0x2e,0x5b, 0x5,0x2e,0x60, + 0x5,0x2e,0x5d, 0x4,0x2e,0x23, 0x6,0x39,0x45, 0x6,0x39,0x4a, + 0xf,0x30,0x77, 0xf,0x30,0x78, 0x6,0x39,0x48, 0x5,0x2e,0x5a, + 0x4,0x2e,0x24, 0x6,0x39,0x47, 0x6,0x39,0x4f, 0x5,0x2e,0x5f, + 0x6,0x39,0x46, 0x5,0x33,0x4e, 0xf,0x30,0x76, 0x4,0x33,0x24, + 0x6,0x41,0x6e, 0x5,0x33,0x55, 0x5,0x39,0x7e, 0x5,0x33,0x52, + 0x6,0x41,0x70, 0x6,0x41,0x73, 0x5,0x33,0x4f, 0x6,0x41,0x6f, + 0x6,0x4b,0x3b, 0x4,0x33,0x26, 0x5,0x33,0x53, 0x6,0x4b,0x38, + 0x6,0x4b,0x37, 0x5,0x33,0x50, 0x6,0x4b,0x39, 0x6,0x41,0x71, + 0x6,0x41,0x72, 0x6,0x41,0x74, 0x6,0x4b,0x3a, 0x5,0x3a,0x28, + 0x6,0x54,0x7b, 0x5,0x3a,0x26, 0x5,0x40,0x3f, 0x4,0x38,0x75, + 0x5,0x3a,0x22, 0x6,0x4b,0x44, 0x5,0x40,0x40, 0x5,0x3a,0x27, + 0x4,0x38,0x76, 0x5,0x3a,0x25, 0x5,0x3a,0x24, 0x4,0x38,0x78, + 0x6,0x4b,0x3f, 0x4,0x3e,0x51, 0x5,0x3a,0x21, 0x6,0x4b,0x3c, + 0x6,0x4b,0x3e, 0x4,0x3e,0x57, 0xf,0x3d,0x2a, 0xf,0x3d,0x2b, + 0x6,0x54,0x79, 0x6,0x52,0x72, 0x6,0x54,0x7a, 0x6,0x4b,0x40, + 0x6,0x4b,0x41, 0x6,0x4b,0x45, 0x6,0x4b,0x3d, 0x5,0x3a,0x23, + 0xf,0x43,0x43, 0x4,0x3e,0x56, 0x5,0x40,0x48, 0x6,0x55,0x22, + 0x5,0x40,0x47, 0x4,0x3e,0x55, 0x6,0x55,0x27, 0x5,0x40,0x4b, + 0x6,0x55,0x24, 0x6,0x54,0x7e, 0x6,0x54,0x7d, 0x6,0x55,0x26, + 0x5,0x40,0x46, 0x5,0x40,0x44, 0x5,0x40,0x43, 0x6,0x55,0x21, + 0x5,0x40,0x42, 0x6,0x55,0x28, 0x5,0x40,0x4a, 0x5,0x40,0x41, + 0x4,0x3e,0x58, 0x5,0x40,0x49, 0x6,0x55,0x25, 0xf,0x43,0x45, + 0xf,0x43,0x46, 0xf,0x49,0x70, 0xf,0x50,0x40, 0x5,0x40,0x45, + 0x6,0x55,0x23, 0x5,0x40,0x4c, 0x6,0x5e,0x6d, 0x5,0x47,0x3a, + 0x6,0x5e,0x69, 0x7,0x25,0x29, 0x5,0x47,0x37, 0x4,0x44,0x6b, + 0x5,0x47,0x35, 0x5,0x47,0x33, 0x6,0x5e,0x6c, 0x5,0x47,0x3b, + 0x5,0x47,0x36, 0x5,0x47,0x34, 0x6,0x5e,0x70, 0x4,0x44,0x6c, + 0x5,0x47,0x31, 0xf,0x49,0x6d, 0x7,0x25,0x2a, 0xf,0x49,0x6f, + 0x6,0x5e,0x6b, 0x6,0x5e,0x68, 0x6,0x5e,0x6a, 0x6,0x5e,0x6f, + 0x4,0x4a,0x7d, 0x5,0x47,0x3d, 0x5,0x47,0x3c, 0x5,0x47,0x39, + 0x5,0x47,0x38, 0x6,0x5e,0x71, 0x5,0x47,0x32, 0x7,0x25,0x31, + 0x4,0x4a,0x78, 0x4,0x4a,0x79, 0x7,0x25,0x30, 0x5,0x4e,0x3c, + 0x7,0x25,0x34, 0x7,0x2f,0x73, 0x5,0x4e,0x41, 0x7,0x25,0x2f, + 0x7,0x25,0x2b, 0x5,0x4e,0x3e, 0x5,0x4e,0x45, 0x5,0x4e,0x3b, + 0x5,0x4e,0x44, 0x5,0x4e,0x43, 0x5,0x4e,0x3d, 0x5,0x55,0x4f, + 0x7,0x2f,0x72, 0x5,0x4e,0x3f, 0x5,0x4e,0x40, 0x5,0x4e,0x46, + 0x7,0x25,0x2c, 0x7,0x25,0x2d, 0xf,0x55,0x75, 0x5,0x55,0x50, + 0x7,0x25,0x2e, 0x7,0x25,0x33, 0xf,0x49,0x6e, 0x4,0x51,0x33, + 0x5,0x4e,0x42, 0x5,0x55,0x57, 0x4,0x51,0x35, 0x5,0x55,0x55, + 0x5,0x55,0x51, 0x5,0x55,0x52, 0x7,0x2f,0x79, 0x4,0x51,0x31, + 0x7,0x2f,0x78, 0x7,0x2f,0x77, 0x5,0x5c,0x28, 0x4,0x51,0x36, + 0x5,0x55,0x53, 0x5,0x55,0x56, 0x7,0x2f,0x75, 0x7,0x39,0x32, + 0x4,0x56,0x6d, 0x7,0x39,0x31, 0x7,0x2f,0x76, 0x7,0x25,0x32, + 0xf,0x55,0x77, 0x7,0x25,0x35, 0x5,0x55,0x54, 0x5,0x5c,0x2a, + 0x7,0x39,0x33, 0x5,0x5c,0x29, 0x7,0x47,0x77, 0x7,0x39,0x35, + 0x7,0x39,0x34, 0xf,0x5b,0x29, 0xf,0x5b,0x2a, 0xf,0x5b,0x2b, + 0xf,0x5b,0x2c, 0x7,0x40,0x5d, 0x5,0x62,0x55, 0x5,0x62,0x54, + 0x7,0x40,0x5a, 0x7,0x40,0x59, 0x7,0x40,0x5c, 0x4,0x5b,0x68, + 0x7,0x40,0x5b, 0xf,0x5f,0x4e, 0xf,0x5f,0x4f, 0x5,0x62,0x56, + 0x4,0x63,0x64, 0x7,0x47,0x78, 0x7,0x4e,0x40, 0x7,0x47,0x76, + 0x7,0x47,0x74, 0x7,0x4e,0x41, 0x5,0x6c,0x56, 0x7,0x4e,0x42, + 0x5,0x70,0x48, 0x7,0x53,0x6d, 0x5,0x70,0x47, 0x4,0x68,0x74, + 0x5,0x70,0x49, 0x7,0x58,0x3b, 0x7,0x5b,0x76, 0x7,0x5b,0x78, + 0x7,0x5b,0x77, 0x5,0x77,0x6a, 0x7,0x5e,0x7a, 0xf,0x6b,0x55, + 0x7,0x61,0x24, 0x7,0x63,0x59, 0xf,0x28,0x23, 0x6,0x4b,0x46, + 0x6,0x5e,0x72, 0x5,0x21,0x4c, 0x6,0x25,0x38, 0x6,0x23,0x33, + 0x6,0x28,0x5f, 0x5,0x24,0x61, 0x4,0x24,0x5d, 0x4,0x24,0x5c, + 0x6,0x28,0x61, 0x6,0x28,0x60, 0xf,0x24,0x79, 0x5,0x24,0x60, + 0x5,0x27,0x30, 0x6,0x2d,0x25, 0x4,0x27,0x3c, 0x5,0x2a,0x41, + 0xf,0x28,0x25, 0xf,0x28,0x26, 0xf,0x28,0x27, 0xf,0x28,0x28, + 0xf,0x28,0x29, 0x6,0x2d,0x23, 0xf,0x2c,0x40, 0xf,0x28,0x24, + 0x6,0x2d,0x22, 0xf,0x2c,0x3c, 0x6,0x32,0x69, 0x5,0x2a,0x45, + 0x5,0x2a,0x42, 0x4,0x2a,0x36, 0x6,0x32,0x6b, 0x6,0x2f,0x69, + 0xf,0x2c,0x2f, 0xf,0x2c,0x30, 0xf,0x2c,0x31, 0xf,0x2c,0x33, + 0xf,0x2c,0x34, 0xf,0x2c,0x35, 0xf,0x2c,0x36, 0xf,0x2c,0x37, + 0xf,0x2c,0x38, 0xf,0x2c,0x3a, 0xf,0x2c,0x3b, 0xf,0x2c,0x3d, + 0x6,0x32,0x6a, 0x6,0x32,0x6c, 0xf,0x2c,0x3e, 0xf,0x2c,0x3f, + 0xf,0x2c,0x2e, 0x5,0x2a,0x44, 0x5,0x2a,0x43, 0x6,0x39,0x53, + 0x5,0x33,0x56, 0x5,0x2e,0x61, 0x4,0x2e,0x29, 0x6,0x39,0x51, + 0x4,0x2e,0x28, 0x6,0x39,0x52, 0x6,0x39,0x54, 0xf,0x30,0x79, + 0xf,0x30,0x7a, 0xf,0x30,0x7b, 0xf,0x30,0x7c, 0xf,0x30,0x7d, + 0xf,0x30,0x7e, 0xf,0x31,0x21, 0xf,0x31,0x23, 0xf,0x31,0x24, + 0xf,0x31,0x25, 0xf,0x31,0x26, 0x6,0x39,0x50, 0xf,0x36,0x63, + 0x4,0x33,0x31, 0x6,0x39,0x55, 0x6,0x41,0x7a, 0x5,0x33,0x57, + 0x6,0x41,0x7b, 0x4,0x33,0x32, 0x6,0x41,0x77, 0x6,0x41,0x78, + 0x6,0x41,0x79, 0xf,0x31,0x22, 0xf,0x36,0x56, 0xf,0x36,0x58, + 0xf,0x36,0x5c, 0xf,0x36,0x5f, 0xf,0x36,0x60, 0xf,0x36,0x61, + 0xf,0x36,0x62, 0xf,0x36,0x64, 0xf,0x36,0x5d, 0x6,0x41,0x7c, + 0xf,0x36,0x5b, 0xf,0x36,0x5a, 0xf,0x36,0x5e, 0x5,0x33,0x58, + 0x6,0x41,0x76, 0xf,0x3d,0x3e, 0xf,0x3d,0x34, 0x6,0x4b,0x4b, + 0x5,0x3a,0x2b, 0x5,0x3a,0x2a, 0x5,0x3a,0x2c, 0x6,0x55,0x29, + 0x4,0x3e,0x5a, 0x5,0x40,0x4d, 0xf,0x3d,0x38, 0x4,0x38,0x7c, + 0x6,0x4b,0x49, 0x6,0x4b,0x4c, 0xf,0x3d,0x2c, 0xf,0x3d,0x2d, + 0xf,0x3d,0x2e, 0xf,0x3d,0x2f, 0xf,0x3d,0x30, 0xf,0x3d,0x32, + 0xf,0x3d,0x35, 0xf,0x3d,0x36, 0xf,0x3d,0x37, 0xf,0x3d,0x39, + 0xf,0x3d,0x3a, 0xf,0x3d,0x3f, 0xf,0x43,0x50, 0x6,0x4b,0x4e, + 0x6,0x55,0x32, 0x6,0x4b,0x4d, 0xf,0x3d,0x40, 0x6,0x4b,0x48, + 0x6,0x4b,0x4a, 0x6,0x55,0x2a, 0xf,0x3d,0x33, 0xf,0x3d,0x3d, + 0xf,0x3d,0x31, 0x5,0x3a,0x29, 0x6,0x55,0x2b, 0x6,0x55,0x30, + 0x4,0x3e,0x5b, 0x6,0x55,0x31, 0x6,0x55,0x2f, 0x6,0x55,0x2e, + 0x5,0x47,0x3e, 0xf,0x43,0x47, 0xf,0x43,0x4a, 0xf,0x43,0x4c, + 0xf,0x43,0x4d, 0xf,0x43,0x4e, 0xf,0x43,0x4f, 0xf,0x43,0x51, + 0xf,0x43,0x52, 0xf,0x43,0x53, 0xf,0x43,0x54, 0xf,0x43,0x55, + 0xf,0x43,0x57, 0xf,0x43,0x58, 0xf,0x43,0x5a, 0xf,0x43,0x5b, + 0xf,0x43,0x5c, 0xf,0x43,0x5d, 0xf,0x43,0x5e, 0xf,0x43,0x5f, + 0xf,0x43,0x60, 0xf,0x43,0x61, 0xf,0x43,0x62, 0xf,0x43,0x63, + 0xf,0x43,0x65, 0x6,0x55,0x2c, 0x5,0x40,0x4f, 0x5,0x3a,0x2e, + 0xf,0x43,0x4b, 0xf,0x43,0x48, 0x5,0x47,0x3f, 0x6,0x55,0x2d, + 0xf,0x43,0x59, 0xf,0x49,0x7a, 0xf,0x49,0x7b, 0xf,0x4a,0x26, + 0x7,0x25,0x38, 0x6,0x5e,0x74, 0x5,0x47,0x41, 0x7,0x25,0x36, + 0x4,0x44,0x6d, 0x5,0x47,0x40, 0x6,0x5e,0x75, 0x6,0x5e,0x77, + 0x6,0x5e,0x76, 0x6,0x5e,0x73, 0xf,0x49,0x71, 0xf,0x49,0x72, + 0xf,0x49,0x73, 0xf,0x49,0x74, 0xf,0x49,0x75, 0xf,0x49,0x77, + 0xf,0x49,0x78, 0xf,0x49,0x79, 0xf,0x49,0x7c, 0xf,0x49,0x7d, + 0xf,0x49,0x7e, 0xf,0x4a,0x21, 0xf,0x4a,0x22, 0xf,0x4a,0x24, + 0xf,0x4a,0x25, 0xf,0x4a,0x27, 0xf,0x4a,0x28, 0xf,0x4a,0x29, + 0x5,0x47,0x42, 0x3,0x48,0x26, 0x7,0x25,0x39, 0xf,0x4a,0x23, + 0x7,0x25,0x40, 0x4,0x4a,0x7e, 0x5,0x4e,0x47, 0x7,0x2f,0x7b, + 0x7,0x25,0x3a, 0x7,0x2f,0x7a, 0x7,0x25,0x3c, 0x7,0x25,0x3f, + 0x7,0x25,0x41, 0x7,0x25,0x42, 0xf,0x50,0x41, 0xf,0x50,0x42, + 0xf,0x50,0x43, 0xf,0x50,0x44, 0xf,0x50,0x45, 0xf,0x50,0x46, + 0xf,0x50,0x48, 0xf,0x50,0x49, 0xf,0x50,0x4a, 0xf,0x50,0x4b, + 0xf,0x50,0x4c, 0x7,0x25,0x3d, 0x5,0x4e,0x48, 0x7,0x25,0x3b, + 0x5,0x4e,0x49, 0xf,0x55,0x7c, 0xf,0x56,0x2e, 0xf,0x50,0x47, + 0x7,0x30,0x22, 0x7,0x25,0x3e, 0x5,0x55,0x58, 0x5,0x55,0x5b, + 0x5,0x55,0x59, 0x4,0x51,0x3b, 0x7,0x30,0x24, 0x7,0x2f,0x7d, + 0x7,0x2f,0x7e, 0x7,0x2f,0x7c, 0x4,0x51,0x3c, 0x7,0x30,0x21, + 0xf,0x55,0x78, 0xf,0x55,0x79, 0xf,0x55,0x7b, 0xf,0x55,0x7d, + 0xf,0x56,0x23, 0xf,0x56,0x24, 0xf,0x56,0x25, 0xf,0x56,0x26, + 0xf,0x56,0x27, 0xf,0x56,0x29, 0xf,0x56,0x2d, 0xf,0x56,0x2f, + 0x7,0x30,0x25, 0x7,0x30,0x23, 0x7,0x39,0x36, 0xf,0x56,0x30, + 0xf,0x56,0x21, 0xf,0x56,0x28, 0x5,0x55,0x5c, 0x5,0x55,0x5a, + 0xf,0x56,0x2c, 0x7,0x39,0x3b, 0x7,0x39,0x3d, 0x5,0x5c,0x2d, + 0x5,0x5c,0x2b, 0x7,0x40,0x5e, 0x7,0x39,0x39, 0x4,0x5b,0x6a, + 0x4,0x56,0x6e, 0x4,0x56,0x70, 0x7,0x39,0x38, 0xf,0x5b,0x2e, + 0xf,0x5b,0x2f, 0xf,0x5b,0x30, 0xf,0x5b,0x31, 0xf,0x5b,0x32, + 0xf,0x5b,0x33, 0xf,0x5b,0x34, 0xf,0x5b,0x35, 0x5,0x5c,0x2c, + 0x7,0x39,0x3a, 0x7,0x39,0x3c, 0x7,0x39,0x37, 0x7,0x40,0x5f, + 0x5,0x68,0x3c, 0x4,0x5b,0x6b, 0x5,0x62,0x57, 0x4,0x60,0x26, + 0x7,0x40,0x60, 0x4,0x60,0x28, 0xf,0x5f,0x51, 0xf,0x5f,0x53, + 0xf,0x5f,0x54, 0xf,0x5f,0x55, 0xf,0x5f,0x57, 0xf,0x5f,0x59, + 0xf,0x5f,0x5a, 0xf,0x5f,0x5b, 0xf,0x5f,0x5c, 0xf,0x5f,0x5f, + 0x7,0x40,0x61, 0x7,0x40,0x62, 0xf,0x5f,0x50, 0xf,0x5f,0x52, + 0xf,0x5f,0x58, 0xf,0x63,0x23, 0x7,0x47,0x7c, 0x7,0x47,0x7b, + 0x5,0x68,0x3e, 0x7,0x47,0x7a, 0x7,0x4e,0x43, 0x5,0x68,0x3d, + 0x7,0x47,0x79, 0xf,0x62,0x7c, 0xf,0x62,0x7e, 0xf,0x63,0x21, + 0xf,0x63,0x22, 0x4,0x60,0x29, 0xf,0x62,0x79, 0xf,0x62,0x7a, + 0xf,0x62,0x7d, 0x7,0x53,0x6f, 0x5,0x6c,0x57, 0x4,0x66,0x52, + 0xf,0x65,0x52, 0xf,0x65,0x53, 0xf,0x65,0x54, 0xf,0x65,0x55, + 0x7,0x4e,0x44, 0x7,0x53,0x6e, 0xf,0x5f,0x5e, 0x4,0x66,0x51, + 0x7,0x55,0x7c, 0x4,0x66,0x53, 0x7,0x58,0x3c, 0xf,0x67,0x76, + 0x7,0x5b,0x79, 0x4,0x6a,0x52, 0xf,0x69,0x59, 0xf,0x69,0x5a, + 0x5,0x76,0x24, 0xf,0x6a,0x61, 0xf,0x6a,0x63, 0xf,0x6b,0x56, + 0xf,0x6a,0x62, 0x5,0x79,0x31, 0x7,0x61,0x26, 0x7,0x61,0x25, + 0xf,0x6c,0x32, 0x5,0x7a,0x2c, 0x4,0x6e,0x34, 0x6,0x2d,0x26, + 0x5,0x2a,0x47, 0x5,0x2a,0x46, 0x6,0x32,0x6d, 0xf,0x2c,0x41, + 0x6,0x32,0x6e, 0x6,0x39,0x56, 0x5,0x2e,0x63, 0x5,0x2e,0x64, + 0x6,0x39,0x57, 0x6,0x39,0x58, 0x4,0x33,0x36, 0x5,0x33,0x59, + 0x5,0x33,0x5a, 0xf,0x36,0x65, 0x5,0x3a,0x2f, 0x5,0x3a,0x30, + 0x6,0x4b,0x4f, 0xf,0x3d,0x41, 0x6,0x4b,0x50, 0x4,0x3e,0x5c, + 0x5,0x40,0x50, 0x5,0x40,0x51, 0xf,0x43,0x66, 0x7,0x25,0x45, + 0x6,0x5e,0x78, 0x5,0x47,0x43, 0xf,0x4a,0x2a, 0x5,0x47,0x44, + 0x7,0x25,0x44, 0x7,0x30,0x26, 0x4,0x51,0x3d, 0x5,0x4e,0x4a, + 0xf,0x50,0x4d, 0x7,0x25,0x43, 0x4,0x51,0x3e, 0x7,0x39,0x3e, + 0x5,0x62,0x58, 0xf,0x5f,0x60, 0x4,0x5b,0x6d, 0x4,0x66,0x54, + 0x7,0x53,0x70, 0x5,0x70,0x4a, 0x5,0x76,0x25, 0x7,0x5b,0x7a, + 0x7,0x5e,0x7b, 0x7,0x62,0x3b, 0x7,0x62,0x3c, 0x5,0x24,0x62, + 0x5,0x27,0x31, 0x4,0x27,0x3d, 0x6,0x2d,0x27, 0x5,0x2a,0x48, + 0x5,0x2a,0x49, 0x6,0x32,0x6f, 0x4,0x2a,0x3b, 0x4,0x2a,0x3e, + 0x5,0x2e,0x65, 0x5,0x2e,0x67, 0x6,0x39,0x5c, 0x5,0x2e,0x66, + 0xf,0x31,0x29, 0x6,0x39,0x5b, 0x6,0x39,0x59, 0x6,0x39,0x5a, + 0x5,0x33,0x5d, 0x6,0x42,0x22, 0x6,0x41,0x7e, 0x6,0x42,0x24, + 0x5,0x33,0x5e, 0x6,0x42,0x23, 0x5,0x33,0x5c, 0xf,0x36,0x66, + 0xf,0x36,0x68, 0x4,0x39,0x22, 0x5,0x3a,0x31, 0x6,0x55,0x36, + 0x4,0x39,0x27, 0x5,0x3a,0x34, 0x5,0x3a,0x33, 0x5,0x33,0x5f, + 0x6,0x4b,0x52, 0x5,0x3a,0x32, 0x5,0x33,0x5b, 0x6,0x4b,0x51, + 0x6,0x4b,0x53, 0x4,0x3e,0x64, 0x5,0x40,0x52, 0x6,0x55,0x37, + 0x4,0x3e,0x5e, 0x5,0x40,0x53, 0x6,0x55,0x33, 0x6,0x55,0x35, + 0x4,0x3e,0x5f, 0x6,0x55,0x38, 0xf,0x43,0x67, 0x6,0x55,0x34, + 0x5,0x47,0x47, 0x6,0x5e,0x7c, 0x5,0x47,0x45, 0x6,0x5e,0x7a, + 0x4,0x44,0x72, 0x6,0x5e,0x79, 0x6,0x5e,0x7b, 0x5,0x47,0x46, + 0x4,0x4b,0x28, 0x7,0x25,0x4a, 0x5,0x4e,0x4c, 0x5,0x4e,0x4d, + 0x5,0x4e,0x4e, 0x7,0x25,0x46, 0x7,0x25,0x47, 0x7,0x25,0x49, + 0x7,0x30,0x27, 0x4,0x56,0x74, 0x7,0x30,0x28, 0x5,0x55,0x5f, + 0x5,0x55,0x61, 0x4,0x51,0x40, 0x5,0x55,0x60, 0x5,0x55,0x5e, + 0x4,0x56,0x76, 0x5,0x5c,0x2e, 0x4,0x56,0x77, 0x7,0x39,0x40, + 0x7,0x39,0x3f, 0x5,0x4e,0x4b, 0x4,0x5b,0x70, 0x5,0x62,0x5b, + 0x5,0x62,0x5a, 0x7,0x40,0x64, 0x5,0x62,0x59, 0x7,0x40,0x65, + 0x5,0x68,0x3f, 0x7,0x4e,0x45, 0x7,0x53,0x71, 0x7,0x53,0x72, + 0x4,0x66,0x56, 0x5,0x70,0x4b, 0x4,0x66,0x55, 0x7,0x53,0x73, + 0x4,0x68,0x76, 0x7,0x58,0x3d, 0x5,0x73,0x5a, 0x5,0x76,0x28, + 0x5,0x76,0x27, 0x7,0x5b,0x7b, 0x5,0x76,0x26, 0x7,0x5c,0x6b, + 0x5,0x7a,0x6c, 0x7,0x65,0x38, 0x6,0x23,0x34, 0x6,0x2d,0x28, + 0x5,0x27,0x33, 0x4,0x27,0x3e, 0xf,0x28,0x2b, 0x6,0x32,0x70, + 0xf,0x2c,0x43, 0x5,0x40,0x54, 0x6,0x5e,0x7d, 0x7,0x30,0x2b, + 0x7,0x30,0x29, 0x7,0x30,0x2a, 0x4,0x56,0x79, 0x7,0x40,0x66, + 0x5,0x70,0x4c, 0x6,0x23,0x35, 0x6,0x25,0x39, 0x6,0x2d,0x29, + 0x5,0x27,0x34, 0x6,0x2d,0x2a, 0xf,0x2c,0x44, 0xf,0x2c,0x45, + 0x5,0x2a,0x4a, 0x4,0x2a,0x3f, 0x6,0x32,0x71, 0x6,0x34,0x79, + 0x5,0x2e,0x69, 0x6,0x42,0x26, 0x5,0x33,0x60, 0x6,0x42,0x25, + 0x6,0x42,0x27, 0xf,0x36,0x69, 0x6,0x55,0x39, 0x6,0x4b,0x54, + 0xf,0x3d,0x43, 0xf,0x3d,0x42, 0x6,0x55,0x3b, 0xf,0x43,0x68, + 0x6,0x55,0x3a, 0x6,0x5e,0x7e, 0x7,0x25,0x4b, 0xf,0x4a,0x2b, + 0x4,0x56,0x7a, 0xf,0x5b,0x36, 0xf,0x63,0x26, 0x7,0x46,0x6e, + 0xf,0x63,0x25, 0x7,0x53,0x74, 0x6,0x25,0x3a, 0xf,0x24,0x7a, + 0x5,0x27,0x35, 0x6,0x2d,0x2e, 0x6,0x39,0x5d, 0x5,0x33,0x61, + 0xf,0x4a,0x2c, 0xf,0x5f,0x61, 0x7,0x47,0x7d, 0xf,0x6c,0x33, + 0x5,0x73,0x5b, 0x4,0x24,0x5f, 0xf,0x24,0x7c, 0xf,0x24,0x7b, + 0x6,0x28,0x63, 0x4,0x27,0x42, 0x4,0x25,0x53, 0x4,0x27,0x3f, + 0x5,0x27,0x36, 0x6,0x2d,0x31, 0x6,0x2d,0x30, 0x6,0x2d,0x33, + 0xf,0x28,0x2c, 0xf,0x28,0x2d, 0x6,0x2d,0x2f, 0x4,0x2a,0x42, + 0x5,0x2a,0x4d, 0x6,0x32,0x74, 0x5,0x2a,0x4c, 0x6,0x32,0x73, + 0x5,0x2a,0x4b, 0x6,0x32,0x76, 0x6,0x32,0x7a, 0x6,0x32,0x77, + 0x6,0x39,0x65, 0x5,0x2a,0x4e, 0x6,0x32,0x78, 0x6,0x32,0x75, + 0x5,0x2e,0x6e, 0xf,0x2c,0x46, 0xf,0x2c,0x47, 0xf,0x2c,0x48, + 0xf,0x2c,0x49, 0xf,0x2c,0x4b, 0xf,0x2c,0x4c, 0xf,0x2c,0x4d, + 0xf,0x2c,0x4e, 0xf,0x2c,0x4f, 0x5,0x2a,0x4f, 0x5,0x2e,0x6a, + 0x4,0x2e,0x2e, 0x5,0x2e,0x6b, 0x6,0x39,0x61, 0x6,0x39,0x60, + 0x6,0x39,0x62, 0x6,0x39,0x5f, 0x6,0x39,0x63, 0xf,0x31,0x2a, + 0xf,0x31,0x2b, 0xf,0x31,0x2c, 0xf,0x31,0x2e, 0x4,0x2e,0x30, + 0xf,0x31,0x2d, 0x5,0x2e,0x6d, 0x5,0x2e,0x6c, 0x4,0x33,0x3e, + 0x6,0x42,0x28, 0x5,0x33,0x63, 0x5,0x33,0x62, 0x4,0x33,0x3d, + 0x6,0x42,0x2c, 0x6,0x42,0x2f, 0x6,0x42,0x2a, 0x6,0x42,0x2d, + 0x6,0x42,0x2e, 0xf,0x36,0x6b, 0xf,0x36,0x6c, 0x6,0x42,0x2b, + 0x6,0x42,0x29, 0x6,0x41,0x6b, 0x4,0x39,0x2b, 0x4,0x39,0x29, + 0x4,0x39,0x2a, 0x6,0x4b,0x57, 0x6,0x4b,0x59, 0xf,0x36,0x6a, + 0xf,0x3d,0x46, 0xf,0x3d,0x47, 0xf,0x3d,0x48, 0x6,0x4b,0x58, + 0x4,0x39,0x2d, 0x6,0x4b,0x55, 0xf,0x3d,0x44, 0xf,0x3d,0x45, + 0x6,0x55,0x40, 0x4,0x3e,0x6a, 0x4,0x3e,0x67, 0x6,0x55,0x3e, + 0x6,0x55,0x3f, 0x4,0x3e,0x66, 0x5,0x40,0x56, 0x6,0x55,0x3c, + 0x6,0x55,0x42, 0x5,0x40,0x55, 0x6,0x55,0x43, 0x6,0x55,0x44, + 0x6,0x55,0x41, 0xf,0x43,0x69, 0xf,0x43,0x6a, 0x5,0x40,0x57, + 0x6,0x55,0x3d, 0x6,0x5f,0x23, 0x4,0x44,0x7a, 0x5,0x47,0x4a, + 0x6,0x5f,0x22, 0x6,0x5f,0x25, 0x6,0x5f,0x28, 0xf,0x4a,0x2d, + 0x6,0x5f,0x26, 0x6,0x5f,0x24, 0x6,0x5f,0x27, 0x7,0x25,0x50, + 0x4,0x4b,0x2c, 0x7,0x25,0x4c, 0x7,0x25,0x4e, 0x7,0x25,0x4d, + 0x7,0x25,0x4f, 0x5,0x4e,0x4f, 0x7,0x25,0x51, 0xf,0x50,0x4f, + 0x4,0x4b,0x2b, 0x4,0x51,0x45, 0x4,0x51,0x43, 0x4,0x51,0x46, + 0x7,0x30,0x2c, 0x5,0x55,0x62, 0xf,0x56,0x32, 0x7,0x2c,0x3b, + 0x7,0x39,0x41, 0x5,0x5c,0x33, 0x7,0x39,0x43, 0x5,0x5c,0x31, + 0x4,0x56,0x7b, 0x7,0x39,0x42, 0x5,0x5c,0x34, 0xf,0x5b,0x37, + 0x7,0x3c,0x76, 0x5,0x5c,0x30, 0x5,0x5c,0x32, 0xf,0x56,0x31, + 0x4,0x5b,0x71, 0x7,0x47,0x7e, 0x5,0x68,0x41, 0x7,0x48,0x23, + 0x7,0x4e,0x46, 0x7,0x48,0x21, 0x7,0x48,0x24, 0x4,0x60,0x2d, + 0x7,0x48,0x22, 0x7,0x4e,0x48, 0x7,0x4e,0x47, 0x7,0x53,0x77, + 0xf,0x67,0x77, 0x7,0x53,0x75, 0x7,0x53,0x76, 0xf,0x67,0x52, + 0x7,0x58,0x3e, 0x4,0x68,0x77, 0x7,0x53,0x78, 0x7,0x5b,0x7d, + 0xf,0x6a,0x64, 0x7,0x5b,0x7c, 0x7,0x5e,0x7c, 0x7,0x62,0x3e, + 0x7,0x62,0x3d, 0x7,0x63,0x5a, 0x7,0x63,0x5c, 0x7,0x63,0x5b, + 0x7,0x66,0x29, 0x7,0x66,0x35, 0x7,0x66,0x46, 0x6,0x23,0x36, + 0x6,0x25,0x3b, 0xf,0x28,0x2e, 0x4,0x2e,0x32, 0x5,0x2a,0x50, + 0x4,0x39,0x2e, 0x6,0x55,0x46, 0x6,0x55,0x45, 0x6,0x5f,0x29, + 0x5,0x55,0x63, 0x7,0x30,0x2e, 0x7,0x25,0x52, 0x7,0x58,0x3f, + 0x5,0x22,0x7c, 0x5,0x24,0x64, 0x5,0x24,0x65, 0x4,0x24,0x60, + 0x6,0x28,0x66, 0x6,0x28,0x67, 0x6,0x28,0x65, 0x6,0x28,0x68, + 0x4,0x27,0x45, 0x6,0x2d,0x35, 0x4,0x27,0x44, 0xf,0x28,0x2f, + 0x5,0x27,0x38, 0x6,0x2d,0x36, 0x6,0x32,0x7d, 0x4,0x2a,0x4b, + 0x6,0x32,0x7c, 0x6,0x32,0x7b, 0x5,0x2a,0x52, 0x5,0x2a,0x56, + 0x4,0x2a,0x47, 0x4,0x2a,0x48, 0x5,0x2a,0x53, 0x4,0x2a,0x45, + 0x5,0x2a,0x54, 0x5,0x2a,0x51, 0x5,0x2a,0x55, 0x6,0x33,0x24, + 0xf,0x2c,0x50, 0x6,0x32,0x7e, 0xf,0x2c,0x51, 0x6,0x33,0x22, + 0x6,0x33,0x23, 0x6,0x33,0x21, 0x6,0x39,0x69, 0x5,0x2e,0x6f, + 0x5,0x2e,0x73, 0x6,0x39,0x6f, 0x5,0x2e,0x71, 0x6,0x39,0x70, + 0x6,0x39,0x6a, 0x5,0x2e,0x76, 0x5,0x2e,0x72, 0x5,0x2e,0x75, + 0x6,0x39,0x6d, 0x6,0x39,0x71, 0x6,0x39,0x66, 0x4,0x2e,0x3d, + 0x5,0x2e,0x74, 0x6,0x39,0x68, 0x4,0x2e,0x3e, 0x5,0x2e,0x70, + 0x6,0x39,0x6e, 0xf,0x31,0x2f, 0x6,0x39,0x67, 0x6,0x39,0x6c, + 0x6,0x42,0x31, 0x6,0x42,0x37, 0x5,0x33,0x68, 0x6,0x42,0x35, + 0x5,0x33,0x6b, 0x4,0x33,0x41, 0x5,0x33,0x6a, 0x5,0x33,0x66, + 0x6,0x42,0x33, 0x4,0x33,0x44, 0x5,0x33,0x69, 0xf,0x36,0x6d, + 0xf,0x36,0x6e, 0xf,0x36,0x6f, 0x6,0x42,0x36, 0x6,0x42,0x39, + 0x6,0x42,0x34, 0x6,0x42,0x38, 0xf,0x36,0x70, 0x6,0x42,0x30, + 0x5,0x33,0x67, 0x5,0x33,0x6c, 0x5,0x3a,0x36, 0x5,0x3a,0x3f, + 0x6,0x4b,0x61, 0x5,0x3a,0x35, 0x6,0x4b,0x65, 0x5,0x3a,0x39, + 0x5,0x3a,0x3a, 0x5,0x3a,0x3c, 0x5,0x3a,0x37, 0x6,0x4b,0x63, + 0x6,0x4b,0x5f, 0x5,0x3a,0x40, 0x6,0x4b,0x62, 0x6,0x4b,0x5b, + 0x6,0x4b,0x66, 0x5,0x3a,0x3e, 0x6,0x4b,0x5e, 0x4,0x39,0x39, + 0x6,0x4b,0x5d, 0x6,0x4b,0x60, 0x6,0x4b,0x64, 0xf,0x3d,0x49, + 0xf,0x3d,0x4a, 0x4,0x39,0x37, 0x6,0x4b,0x5c, 0x4,0x39,0x31, + 0x5,0x3a,0x38, 0x6,0x55,0x4c, 0x4,0x3e,0x72, 0x4,0x3e,0x70, + 0x4,0x3e,0x7b, 0x5,0x40,0x59, 0x4,0x3e,0x71, 0x4,0x3e,0x75, + 0x4,0x44,0x7d, 0x4,0x3e,0x79, 0x6,0x55,0x49, 0x5,0x40,0x5a, + 0x5,0x40,0x5c, 0x5,0x40,0x62, 0x4,0x3e,0x7c, 0x6,0x55,0x47, + 0x5,0x40,0x61, 0x6,0x55,0x4d, 0x5,0x40,0x65, 0x5,0x40,0x63, + 0x5,0x40,0x5b, 0x5,0x3a,0x3d, 0x5,0x40,0x5f, 0x5,0x40,0x5e, + 0x6,0x55,0x4b, 0x6,0x55,0x4a, 0x4,0x3e,0x7d, 0xf,0x43,0x6b, + 0xf,0x43,0x6c, 0x6,0x55,0x48, 0x6,0x55,0x4e, 0x5,0x40,0x58, + 0x5,0x40,0x66, 0x5,0x40,0x5d, 0x5,0x47,0x58, 0x5,0x47,0x50, + 0x4,0x45,0x25, 0x4,0x45,0x2b, 0x5,0x47,0x4b, 0x5,0x47,0x4f, + 0x4,0x45,0x26, 0x6,0x5f,0x2f, 0x6,0x5f,0x2a, 0x4,0x45,0x2e, + 0x4,0x45,0x2a, 0x6,0x5f,0x2b, 0x6,0x5f,0x34, 0x5,0x47,0x4d, + 0x5,0x47,0x4e, 0x5,0x47,0x53, 0x4,0x45,0x2c, 0x6,0x5f,0x37, + 0x6,0x5f,0x35, 0x5,0x47,0x5a, 0x6,0x5f,0x2e, 0x4,0x45,0x27, + 0x4,0x45,0x22, 0x5,0x47,0x51, 0x5,0x47,0x52, 0x6,0x5f,0x33, + 0x5,0x47,0x4c, 0x5,0x47,0x56, 0x6,0x5f,0x31, 0x6,0x5f,0x30, + 0xf,0x4a,0x2e, 0x6,0x5f,0x38, 0x6,0x5f,0x2c, 0x4,0x45,0x2d, + 0x6,0x5f,0x32, 0x6,0x5f,0x36, 0x5,0x47,0x55, 0x4,0x4b,0x3a, + 0x4,0x4b,0x36, 0x4,0x4b,0x2d, 0x4,0x4b,0x39, 0x5,0x4e,0x53, + 0x4,0x4b,0x34, 0x7,0x25,0x5d, 0x4,0x4b,0x32, 0x5,0x4e,0x55, + 0x5,0x4e,0x57, 0x5,0x4e,0x54, 0x4,0x4b,0x31, 0x7,0x25,0x55, + 0x4,0x4b,0x30, 0x5,0x4e,0x51, 0x5,0x4e,0x52, 0x7,0x25,0x53, + 0x5,0x47,0x57, 0x5,0x4e,0x58, 0x7,0x25,0x54, 0x7,0x25,0x5b, + 0x7,0x25,0x59, 0xf,0x50,0x50, 0xf,0x50,0x51, 0xf,0x50,0x52, + 0xf,0x50,0x53, 0xf,0x50,0x54, 0x7,0x25,0x56, 0x7,0x25,0x5a, + 0x7,0x25,0x5e, 0x5,0x4e,0x56, 0x5,0x4e,0x50, 0x4,0x51,0x4b, + 0x5,0x55,0x65, 0x7,0x30,0x2f, 0x7,0x30,0x30, 0x5,0x55,0x6c, + 0x5,0x55,0x6d, 0x4,0x51,0x4c, 0x4,0x51,0x47, 0x5,0x55,0x68, + 0x7,0x30,0x35, 0x5,0x55,0x66, 0x5,0x55,0x67, 0x5,0x55,0x6b, + 0x7,0x30,0x31, 0x7,0x30,0x37, 0x5,0x55,0x6e, 0xf,0x56,0x34, + 0xf,0x56,0x35, 0x7,0x30,0x34, 0x7,0x30,0x33, 0x5,0x55,0x6a, + 0x7,0x30,0x32, 0x7,0x30,0x38, 0x7,0x30,0x39, 0x5,0x55,0x64, + 0x7,0x25,0x57, 0x4,0x56,0x7c, 0x5,0x5c,0x39, 0x5,0x55,0x70, + 0x7,0x39,0x50, 0x4,0x51,0x51, 0x4,0x45,0x29, 0x4,0x56,0x7e, + 0x7,0x39,0x47, 0x5,0x5c,0x35, 0x7,0x39,0x48, 0x5,0x5c,0x3c, + 0x5,0x5c,0x3a, 0x5,0x5c,0x3d, 0x7,0x39,0x4f, 0x7,0x40,0x6a, + 0x5,0x55,0x6f, 0x5,0x5c,0x37, 0x4,0x56,0x7d, 0x5,0x5c,0x38, + 0x4,0x57,0x23, 0x7,0x39,0x49, 0x7,0x39,0x4d, 0x7,0x39,0x51, + 0x7,0x39,0x4b, 0x7,0x39,0x46, 0x7,0x39,0x4c, 0xf,0x5b,0x38, + 0x7,0x39,0x44, 0x7,0x39,0x45, 0x7,0x39,0x4e, 0x5,0x5c,0x3b, + 0x5,0x62,0x5c, 0x5,0x5c,0x3e, 0x7,0x39,0x4a, 0x4,0x5b,0x78, + 0x5,0x5c,0x40, 0x5,0x62,0x60, 0x7,0x40,0x68, 0x5,0x62,0x65, + 0x7,0x40,0x69, 0x5,0x62,0x61, 0x5,0x62,0x64, 0x4,0x5b,0x76, + 0x5,0x5c,0x3f, 0x5,0x62,0x5d, 0x5,0x62,0x62, 0x5,0x62,0x5e, + 0x5,0x62,0x5f, 0x4,0x5b,0x7a, 0x7,0x40,0x6d, 0x5,0x62,0x63, + 0x7,0x48,0x2b, 0x4,0x60,0x33, 0x7,0x48,0x27, 0x4,0x60,0x34, + 0x5,0x68,0x44, 0x4,0x60,0x35, 0x7,0x48,0x26, 0x5,0x68,0x43, + 0x5,0x68,0x42, 0x4,0x60,0x36, 0xf,0x63,0x27, 0x4,0x60,0x31, + 0x7,0x48,0x28, 0x7,0x48,0x29, 0x7,0x48,0x25, 0x7,0x48,0x2a, + 0x7,0x40,0x6c, 0x4,0x63,0x6a, 0x4,0x63,0x6b, 0x7,0x4e,0x49, + 0x7,0x4e,0x4d, 0x7,0x4e,0x4c, 0x5,0x6c,0x58, 0x5,0x6c,0x59, + 0x7,0x4e,0x4e, 0x7,0x4e,0x4b, 0x7,0x4e,0x4a, 0x5,0x70,0x51, + 0x5,0x70,0x50, 0x5,0x70,0x4e, 0x4,0x66,0x57, 0x7,0x53,0x7a, + 0x5,0x70,0x4f, 0x7,0x53,0x79, 0xf,0x67,0x78, 0x5,0x73,0x5f, + 0x5,0x73,0x5e, 0x5,0x73,0x5d, 0x7,0x5c,0x22, 0x7,0x5b,0x7e, + 0x4,0x6a,0x56, 0x7,0x5c,0x21, 0x5,0x76,0x29, 0x5,0x77,0x6b, + 0x7,0x5e,0x7d, 0x7,0x5e,0x7e, 0x7,0x61,0x42, 0x7,0x61,0x27, + 0x7,0x62,0x3f, 0x7,0x62,0x40, 0x7,0x62,0x41, 0x5,0x7a,0x6d, + 0x7,0x64,0x51, 0x7,0x65,0x39, 0x4,0x24,0x63, 0x6,0x33,0x25, + 0xf,0x2c,0x52, 0x6,0x39,0x73, 0x6,0x39,0x72, 0xf,0x31,0x30, + 0x6,0x42,0x3a, 0xf,0x36,0x71, 0x6,0x4b,0x69, 0x6,0x4b,0x67, + 0x5,0x3a,0x41, 0x6,0x4b,0x68, 0x7,0x25,0x5f, 0x4,0x51,0x53, + 0x4,0x51,0x52, 0x7,0x30,0x3a, 0x6,0x25,0x3c, 0x6,0x25,0x3d, + 0x5,0x24,0x66, 0x5,0x27,0x3a, 0x5,0x27,0x3b, 0x5,0x27,0x39, + 0x5,0x27,0x3c, 0x4,0x2a,0x4d, 0x5,0x2a,0x59, 0x5,0x2a,0x58, + 0x5,0x2a,0x57, 0x6,0x33,0x27, 0x6,0x33,0x28, 0x6,0x33,0x26, + 0xf,0x2c,0x53, 0xf,0x2c,0x54, 0x6,0x33,0x29, 0x5,0x2a,0x5a, + 0x6,0x39,0x74, 0x4,0x2e,0x42, 0x6,0x39,0x75, 0x6,0x42,0x3c, + 0xf,0x31,0x31, 0xf,0x31,0x32, 0xf,0x31,0x33, 0xf,0x31,0x35, + 0xf,0x31,0x36, 0xf,0x36,0x75, 0x4,0x33,0x46, 0x5,0x33,0x6e, + 0x6,0x42,0x3b, 0xf,0x36,0x72, 0xf,0x36,0x73, 0xf,0x36,0x76, + 0x6,0x4b,0x6b, 0x6,0x4b,0x6c, 0x6,0x4b,0x6a, 0xf,0x36,0x74, + 0x5,0x40,0x68, 0x5,0x40,0x67, 0x6,0x55,0x50, 0x4,0x3e,0x7e, + 0x6,0x55,0x4f, 0x5,0x40,0x69, 0xf,0x43,0x6d, 0x4,0x45,0x2f, + 0x6,0x5f,0x39, 0x6,0x5f,0x3a, 0xf,0x4a,0x30, 0xf,0x4a,0x31, + 0xf,0x4a,0x33, 0xf,0x4a,0x34, 0xf,0x4a,0x32, 0x4,0x4b,0x3c, + 0x7,0x25,0x60, 0x7,0x25,0x61, 0x5,0x55,0x72, 0x7,0x30,0x3c, + 0x5,0x55,0x71, 0x7,0x30,0x3b, 0x4,0x57,0x27, 0x4,0x57,0x28, + 0x5,0x5c,0x42, 0x5,0x5c,0x44, 0x7,0x40,0x6e, 0x5,0x5c,0x41, + 0x7,0x39,0x52, 0x5,0x62,0x66, 0x7,0x40,0x6f, 0x7,0x40,0x70, + 0x5,0x68,0x45, 0x5,0x68,0x46, 0x5,0x68,0x47, 0x5,0x68,0x48, + 0x7,0x48,0x2c, 0x7,0x4e,0x50, 0x7,0x4e,0x4f, 0x5,0x62,0x67, + 0x7,0x58,0x40, 0x7,0x58,0x41, 0xf,0x67,0x79, 0x7,0x5c,0x23, + 0x4,0x6b,0x73, 0x7,0x5f,0x21, 0x7,0x65,0x3a, 0x5,0x24,0x67, + 0x5,0x24,0x68, 0x6,0x2d,0x39, 0x6,0x2d,0x37, 0x6,0x2d,0x38, + 0x5,0x27,0x3d, 0x6,0x33,0x2b, 0x5,0x2a,0x5b, 0x4,0x2a,0x4f, + 0x6,0x30,0x36, 0x6,0x33,0x2a, 0x5,0x2e,0x77, 0x5,0x2e,0x78, + 0x6,0x39,0x76, 0x6,0x39,0x7a, 0x5,0x33,0x6f, 0x4,0x2e,0x44, + 0x6,0x39,0x77, 0x6,0x39,0x78, 0x6,0x39,0x79, 0x4,0x33,0x49, + 0x5,0x33,0x70, 0x6,0x42,0x3e, 0xf,0x36,0x79, 0x6,0x42,0x3d, + 0x4,0x39,0x3c, 0x6,0x4b,0x6d, 0x5,0x3a,0x42, 0x6,0x4b,0x6f, + 0x4,0x39,0x3b, 0xf,0x3d,0x4b, 0x6,0x4b,0x6e, 0xf,0x36,0x78, + 0x5,0x40,0x6a, 0x5,0x40,0x6d, 0x5,0x40,0x6b, 0x5,0x40,0x6c, + 0x5,0x40,0x6e, 0x6,0x55,0x53, 0xf,0x43,0x6e, 0x6,0x55,0x51, + 0x4,0x3f,0x21, 0x4,0x45,0x31, 0x4,0x45,0x33, 0x6,0x5f,0x3e, + 0xf,0x4a,0x35, 0x6,0x5f,0x3d, 0x5,0x47,0x5c, 0x6,0x5f,0x3f, + 0x6,0x5f,0x3b, 0x6,0x5f,0x3c, 0x7,0x25,0x63, 0x5,0x4e,0x5a, + 0x5,0x4e,0x5b, 0x5,0x4e,0x5c, 0x7,0x25,0x62, 0x5,0x55,0x76, + 0x5,0x55,0x78, 0x5,0x55,0x74, 0x4,0x51,0x58, 0x5,0x55,0x77, + 0x5,0x55,0x75, 0xf,0x56,0x36, 0x5,0x55,0x73, 0x7,0x30,0x3d, + 0x7,0x30,0x3e, 0x7,0x39,0x53, 0x7,0x30,0x3f, 0x4,0x57,0x29, + 0x5,0x62,0x68, 0x7,0x40,0x72, 0x7,0x40,0x73, 0x7,0x40,0x74, + 0x7,0x40,0x71, 0x5,0x68,0x4a, 0x5,0x68,0x49, 0x7,0x48,0x2d, + 0x4,0x63,0x6d, 0x5,0x6c,0x5b, 0x5,0x6c,0x5a, 0x7,0x4e,0x51, + 0x7,0x53,0x7c, 0x4,0x66,0x5c, 0x7,0x58,0x42, 0x5,0x77,0x6c, + 0x5,0x77,0x6d, 0x7,0x63,0x44, 0x7,0x65,0x58, 0x6,0x28,0x69, + 0xf,0x24,0x7d, 0x4,0x27,0x49, 0x5,0x27,0x3e, 0x4,0x27,0x47, + 0x6,0x2d,0x3b, 0x5,0x27,0x3f, 0x5,0x2a,0x5e, 0x5,0x2a,0x5c, + 0x5,0x2a,0x5d, 0x6,0x33,0x2d, 0x6,0x33,0x2c, 0xf,0x2c,0x55, + 0x5,0x2e,0x79, 0x6,0x3a,0x21, 0x6,0x3a,0x23, 0x4,0x2e,0x48, + 0x5,0x2e,0x7a, 0x6,0x39,0x7e, 0x6,0x39,0x7b, 0x4,0x2e,0x4a, + 0x6,0x3a,0x22, 0xf,0x31,0x37, 0xf,0x31,0x38, 0x6,0x3a,0x24, + 0x6,0x39,0x7c, 0x6,0x39,0x7d, 0x4,0x33,0x4c, 0x5,0x33,0x72, + 0x4,0x33,0x4a, 0x6,0x42,0x3f, 0xf,0x36,0x7a, 0xf,0x36,0x7b, + 0xf,0x36,0x7c, 0xf,0x36,0x7d, 0xf,0x37,0x21, 0xf,0x37,0x22, + 0x6,0x42,0x40, 0x6,0x42,0x41, 0x6,0x3a,0x25, 0x6,0x4b,0x74, + 0x6,0x4b,0x70, 0x5,0x3a,0x43, 0x4,0x39,0x3d, 0x6,0x4b,0x72, + 0x6,0x4b,0x73, 0xf,0x3d,0x4c, 0xf,0x3d,0x4d, 0x6,0x4b,0x71, + 0x6,0x55,0x54, 0x6,0x55,0x56, 0x5,0x40,0x70, 0x6,0x55,0x58, + 0x6,0x55,0x57, 0x6,0x55,0x55, 0xf,0x43,0x6f, 0xf,0x43,0x70, + 0x6,0x5f,0x41, 0x6,0x5f,0x40, 0x6,0x5f,0x4b, 0xf,0x4a,0x36, + 0x5,0x4e,0x5d, 0x7,0x25,0x64, 0x7,0x25,0x65, 0xf,0x50,0x55, + 0xf,0x50,0x56, 0xf,0x50,0x57, 0xf,0x50,0x58, 0xf,0x50,0x59, + 0xf,0x50,0x5a, 0x4,0x51,0x59, 0x7,0x30,0x44, 0x4,0x51,0x5b, + 0x7,0x30,0x40, 0x7,0x30,0x45, 0x5,0x55,0x7a, 0x5,0x55,0x79, + 0xf,0x56,0x37, 0xf,0x56,0x38, 0xf,0x56,0x39, 0xf,0x56,0x3a, + 0xf,0x56,0x3b, 0x7,0x30,0x43, 0x7,0x30,0x41, 0x4,0x57,0x2b, + 0x4,0x5c,0x23, 0x4,0x57,0x2a, 0x7,0x39,0x54, 0x5,0x5c,0x47, + 0x7,0x40,0x75, 0x5,0x5c,0x46, 0xf,0x5b,0x3b, 0xf,0x5b,0x3c, + 0x7,0x39,0x55, 0x7,0x39,0x56, 0x7,0x36,0x79, 0x5,0x5c,0x45, + 0x7,0x30,0x42, 0x7,0x39,0x57, 0x4,0x5c,0x22, 0x4,0x5c,0x21, + 0x7,0x40,0x76, 0x7,0x40,0x78, 0x7,0x40,0x77, 0xf,0x5f,0x62, + 0x7,0x40,0x79, 0x7,0x48,0x2e, 0x5,0x68,0x4b, 0x7,0x48,0x2f, + 0xf,0x63,0x28, 0xf,0x63,0x29, 0x5,0x6c,0x5d, 0x7,0x4e,0x53, + 0x5,0x6c,0x5c, 0x7,0x4e,0x55, 0xf,0x65,0x56, 0x7,0x4e,0x52, + 0x7,0x4e,0x54, 0xf,0x67,0x7b, 0x7,0x58,0x44, 0x5,0x73,0x60, + 0x7,0x58,0x43, 0x7,0x58,0x45, 0xf,0x67,0x7a, 0x7,0x5f,0x22, + 0x5,0x76,0x2a, 0x7,0x5f,0x23, 0x7,0x62,0x42, 0x5,0x22,0x7d, + 0xf,0x22,0x67, 0x6,0x28,0x6a, 0x4,0x24,0x64, 0x5,0x24,0x6a, + 0x4,0x24,0x66, 0x5,0x24,0x6b, 0x5,0x24,0x69, 0xf,0x24,0x7e, + 0x4,0x27,0x50, 0x6,0x2d,0x3c, 0x5,0x27,0x41, 0x4,0x27,0x4b, + 0x6,0x2d,0x40, 0x6,0x2d,0x42, 0x6,0x2d,0x3e, 0x5,0x27,0x42, + 0x5,0x27,0x43, 0x6,0x2d,0x41, 0x6,0x2d,0x3f, 0x5,0x27,0x40, + 0x6,0x2d,0x43, 0x6,0x2d,0x44, 0x6,0x33,0x39, 0x6,0x33,0x35, + 0x6,0x33,0x2e, 0x6,0x33,0x32, 0x4,0x2a,0x5e, 0x6,0x33,0x36, + 0x4,0x2a,0x5c, 0x6,0x33,0x3c, 0x5,0x2a,0x65, 0x6,0x33,0x33, + 0x5,0x2a,0x69, 0x4,0x2a,0x5b, 0x6,0x33,0x2f, 0x6,0x33,0x3b, + 0x5,0x2a,0x60, 0x5,0x2a,0x67, 0x5,0x2a,0x6b, 0x5,0x2a,0x61, + 0x5,0x2a,0x6a, 0x5,0x2a,0x68, 0x5,0x2a,0x63, 0x5,0x2a,0x6c, + 0x6,0x33,0x30, 0x5,0x2a,0x5f, 0x5,0x2a,0x66, 0x5,0x2a,0x62, + 0x5,0x2a,0x64, 0xf,0x2c,0x56, 0xf,0x2c,0x58, 0x6,0x33,0x37, + 0x6,0x33,0x3a, 0x6,0x33,0x34, 0x4,0x2e,0x50, 0x5,0x2f,0x24, + 0x3,0x2e,0x5a, 0x4,0x2e,0x4c, 0x5,0x2e,0x7b, 0x6,0x3a,0x26, + 0x4,0x2e,0x4e, 0x5,0x2f,0x22, 0x5,0x2e,0x7c, 0x6,0x3a,0x28, + 0x4,0x2e,0x4b, 0x6,0x3a,0x29, 0x5,0x2f,0x23, 0x6,0x3a,0x2a, + 0x4,0x2e,0x53, 0x6,0x3a,0x2c, 0x5,0x2e,0x7e, 0x5,0x2f,0x25, + 0x6,0x3a,0x2b, 0xf,0x31,0x39, 0xf,0x31,0x3a, 0xf,0x31,0x3b, + 0xf,0x31,0x3c, 0xf,0x31,0x3d, 0x6,0x3a,0x27, 0x5,0x2f,0x21, + 0x5,0x2e,0x7d, 0x4,0x2e,0x54, 0x4,0x33,0x55, 0x6,0x42,0x53, + 0x6,0x42,0x46, 0x6,0x42,0x4d, 0x5,0x33,0x74, 0x5,0x33,0x73, + 0x5,0x33,0x7d, 0x4,0x33,0x54, 0x6,0x42,0x47, 0x6,0x42,0x44, + 0x6,0x42,0x42, 0x5,0x33,0x7a, 0x5,0x33,0x7b, 0x5,0x33,0x75, + 0x6,0x42,0x4a, 0x5,0x33,0x78, 0x6,0x42,0x54, 0x5,0x33,0x79, + 0x6,0x42,0x43, 0x6,0x42,0x4f, 0x6,0x42,0x4b, 0x6,0x42,0x50, + 0xf,0x37,0x25, 0x6,0x42,0x52, 0x6,0x42,0x4c, 0x6,0x42,0x49, + 0x6,0x42,0x51, 0xf,0x37,0x26, 0x5,0x33,0x7e, 0x6,0x42,0x45, + 0x6,0x42,0x4e, 0x5,0x33,0x77, 0x5,0x33,0x7c, 0x5,0x3a,0x49, + 0x5,0x3a,0x4c, 0x6,0x4b,0x79, 0x6,0x4c,0x23, 0x4,0x33,0x53, + 0x6,0x4b,0x78, 0x5,0x3a,0x4b, 0x6,0x4b,0x7d, 0x6,0x4c,0x21, + 0x5,0x3a,0x46, 0x6,0x4c,0x26, 0x6,0x4b,0x77, 0x4,0x39,0x4f, + 0x5,0x3a,0x4a, 0x5,0x3a,0x48, 0x5,0x3a,0x44, 0x4,0x39,0x4e, + 0x5,0x40,0x71, 0x6,0x4c,0x25, 0x5,0x40,0x7e, 0x4,0x39,0x40, + 0x6,0x4b,0x7e, 0x5,0x3a,0x4d, 0x6,0x4b,0x7b, 0x5,0x3a,0x4e, + 0x6,0x4c,0x28, 0x5,0x3a,0x45, 0x5,0x3a,0x47, 0xf,0x3d,0x4f, + 0xf,0x3d,0x50, 0xf,0x3d,0x51, 0x6,0x4b,0x7c, 0x6,0x4c,0x27, + 0x6,0x4b,0x76, 0x6,0x4c,0x24, 0x6,0x4c,0x22, 0x4,0x39,0x44, + 0x4,0x39,0x50, 0x5,0x3a,0x4f, 0x4,0x39,0x3e, 0x6,0x55,0x5b, + 0x6,0x55,0x5e, 0x6,0x55,0x5a, 0x4,0x3f,0x2a, 0x5,0x40,0x78, + 0x6,0x55,0x5c, 0x5,0x40,0x77, 0x6,0x55,0x5f, 0x5,0x40,0x75, + 0x6,0x55,0x59, 0x4,0x3f,0x23, 0x4,0x3f,0x28, 0x4,0x3f,0x31, + 0x4,0x3f,0x2e, 0x5,0x40,0x7a, 0x6,0x55,0x62, 0x5,0x40,0x76, + 0x4,0x3f,0x2f, 0x4,0x3f,0x24, 0x6,0x55,0x64, 0x5,0x40,0x79, + 0x5,0x40,0x72, 0x5,0x40,0x7c, 0x6,0x55,0x66, 0x6,0x55,0x5d, + 0xf,0x43,0x71, 0xf,0x43,0x72, 0xf,0x43,0x73, 0x6,0x4b,0x75, + 0x6,0x55,0x63, 0x6,0x53,0x35, 0x5,0x40,0x73, 0x5,0x40,0x7d, + 0x5,0x40,0x74, 0x6,0x55,0x65, 0x5,0x47,0x60, 0x4,0x45,0x45, + 0x6,0x5f,0x44, 0x4,0x45,0x3e, 0x5,0x47,0x63, 0x6,0x5f,0x48, + 0x5,0x47,0x65, 0x5,0x47,0x66, 0x6,0x5f,0x49, 0x4,0x4b,0x4f, + 0x6,0x5f,0x4e, 0x6,0x5f,0x46, 0x6,0x5f,0x4f, 0x7,0x25,0x6c, + 0x6,0x5f,0x47, 0x5,0x47,0x67, 0x5,0x47,0x64, 0x6,0x5f,0x43, + 0x6,0x5f,0x4a, 0x6,0x5f,0x45, 0x5,0x47,0x62, 0x6,0x5f,0x42, + 0x5,0x47,0x5f, 0x5,0x47,0x5e, 0x5,0x47,0x5d, 0x7,0x25,0x66, + 0xf,0x4a,0x37, 0xf,0x4a,0x38, 0xf,0x4a,0x39, 0xf,0x4a,0x3a, + 0xf,0x4a,0x3b, 0xf,0x4a,0x3c, 0xf,0x4a,0x3d, 0x4,0x45,0x3a, + 0x6,0x5f,0x4d, 0x6,0x5f,0x4c, 0x5,0x47,0x69, 0x4,0x45,0x3b, + 0x4,0x4b,0x50, 0x4,0x4b,0x4c, 0x4,0x4b,0x3e, 0x5,0x4e,0x62, + 0x5,0x4e,0x67, 0x4,0x4b,0x4e, 0x7,0x25,0x6b, 0x5,0x4e,0x6c, + 0x5,0x4e,0x65, 0x4,0x4b,0x41, 0x7,0x25,0x70, 0x4,0x4b,0x40, + 0x4,0x51,0x65, 0x7,0x30,0x4d, 0x5,0x4e,0x64, 0x5,0x56,0x21, + 0x5,0x4e,0x66, 0x7,0x25,0x6d, 0x5,0x4e,0x6a, 0x7,0x25,0x72, + 0x4,0x4b,0x49, 0x4,0x4b,0x4b, 0x4,0x4b,0x46, 0x5,0x4e,0x5f, + 0x5,0x4e,0x6b, 0x7,0x25,0x67, 0x7,0x25,0x68, 0x7,0x25,0x6a, + 0x4,0x4b,0x4a, 0x5,0x4e,0x63, 0x7,0x25,0x6e, 0x5,0x4e,0x5e, + 0x5,0x4e,0x61, 0x5,0x55,0x7b, 0x5,0x4e,0x69, 0x5,0x4e,0x68, + 0x7,0x25,0x69, 0xf,0x50,0x5b, 0xf,0x50,0x5c, 0xf,0x50,0x5d, + 0x7,0x25,0x6f, 0x4,0x4b,0x48, 0x5,0x56,0x2a, 0x5,0x56,0x2b, + 0x4,0x51,0x5e, 0x5,0x56,0x25, 0x5,0x56,0x23, 0x5,0x56,0x27, + 0x5,0x55,0x7d, 0x4,0x51,0x63, 0x5,0x56,0x29, 0x5,0x55,0x7e, + 0x5,0x56,0x26, 0x5,0x56,0x24, 0x4,0x51,0x62, 0x7,0x30,0x46, + 0x7,0x30,0x4e, 0x7,0x30,0x4f, 0x7,0x30,0x4b, 0x7,0x30,0x47, + 0x5,0x4e,0x6d, 0x4,0x51,0x67, 0x5,0x55,0x7c, 0x7,0x30,0x49, + 0xf,0x56,0x3d, 0x7,0x30,0x51, 0x7,0x30,0x4c, 0x5,0x56,0x2c, + 0x4,0x51,0x66, 0x5,0x47,0x68, 0x5,0x56,0x28, 0x4,0x5c,0x2b, + 0x5,0x5c,0x48, 0x5,0x5c,0x4b, 0x4,0x57,0x35, 0x4,0x57,0x36, + 0x7,0x30,0x52, 0x7,0x39,0x5e, 0x7,0x39,0x59, 0x5,0x5c,0x4a, + 0x7,0x39,0x5a, 0x5,0x5c,0x4c, 0x7,0x39,0x64, 0x5,0x5c,0x49, + 0x7,0x41,0x22, 0x7,0x39,0x5f, 0x7,0x39,0x60, 0x7,0x39,0x5d, + 0x4,0x57,0x37, 0x7,0x39,0x63, 0x5,0x5c,0x4f, 0x7,0x30,0x48, + 0x5,0x5c,0x4e, 0x7,0x39,0x61, 0x7,0x39,0x5c, 0x7,0x39,0x5b, + 0xf,0x5b,0x3e, 0xf,0x5b,0x3f, 0xf,0x5b,0x40, 0x7,0x39,0x62, + 0x7,0x39,0x58, 0x4,0x5c,0x28, 0x7,0x41,0x23, 0x7,0x40,0x7e, + 0x5,0x62,0x6e, 0x4,0x5c,0x2c, 0x5,0x62,0x6b, 0x7,0x40,0x7b, + 0x7,0x40,0x7c, 0x5,0x62,0x70, 0x4,0x5c,0x24, 0x5,0x62,0x6c, + 0x5,0x62,0x6f, 0x5,0x62,0x71, 0x5,0x62,0x6a, 0xf,0x5f,0x63, + 0xf,0x5f,0x64, 0x7,0x41,0x24, 0x7,0x41,0x25, 0x7,0x40,0x7d, + 0x5,0x62,0x6d, 0x7,0x40,0x7a, 0x7,0x41,0x21, 0x5,0x68,0x4f, + 0x5,0x68,0x4c, 0x5,0x68,0x51, 0x4,0x60,0x3e, 0x5,0x68,0x50, + 0x4,0x60,0x3b, 0x5,0x68,0x54, 0x5,0x68,0x4e, 0x7,0x48,0x32, + 0x4,0x60,0x3a, 0x7,0x48,0x34, 0x4,0x60,0x3c, 0x4,0x60,0x3d, + 0x7,0x48,0x30, 0x5,0x68,0x4d, 0x7,0x48,0x31, 0x5,0x68,0x53, + 0x5,0x68,0x52, 0xf,0x63,0x2a, 0x7,0x4b,0x5d, 0x7,0x48,0x35, + 0x7,0x48,0x33, 0x5,0x6c,0x60, 0x5,0x6c,0x62, 0x5,0x6c,0x5e, + 0x7,0x4e,0x58, 0x5,0x6c,0x61, 0x5,0x6c,0x63, 0x7,0x4e,0x57, + 0xf,0x65,0x57, 0x4,0x63,0x72, 0x5,0x6c,0x5f, 0x4,0x63,0x73, + 0x7,0x4e,0x56, 0x7,0x54,0x22, 0x5,0x70,0x52, 0x5,0x70,0x54, + 0x5,0x70,0x53, 0x5,0x70,0x55, 0x7,0x53,0x7e, 0x7,0x54,0x23, + 0x7,0x53,0x7d, 0x4,0x68,0x79, 0x5,0x73,0x63, 0x7,0x58,0x46, + 0x5,0x73,0x61, 0x5,0x73,0x62, 0x7,0x58,0x47, 0x5,0x73,0x65, + 0x4,0x6a,0x59, 0x7,0x54,0x21, 0x5,0x73,0x64, 0x7,0x59,0x33, + 0x5,0x73,0x66, 0x5,0x76,0x2b, 0x7,0x5c,0x26, 0x4,0x6a,0x58, + 0x7,0x5c,0x25, 0x7,0x5f,0x24, 0x4,0x6c,0x74, 0x7,0x62,0x43, + 0x7,0x62,0x45, 0x7,0x62,0x44, 0xf,0x6c,0x66, 0x5,0x7b,0x43, + 0x5,0x27,0x44, 0x4,0x2a,0x60, 0x4,0x2a,0x61, 0x4,0x2e,0x56, + 0x5,0x2f,0x28, 0x5,0x2f,0x27, 0x6,0x3a,0x2f, 0x6,0x3a,0x30, + 0x4,0x33,0x58, 0x5,0x34,0x22, 0xf,0x37,0x27, 0x5,0x3a,0x52, + 0x4,0x39,0x51, 0x5,0x3a,0x53, 0x5,0x3a,0x51, 0x5,0x3a,0x55, + 0x5,0x3a,0x50, 0x6,0x4c,0x29, 0x5,0x3a,0x54, 0x5,0x41,0x23, + 0x5,0x41,0x22, 0x5,0x41,0x21, 0x6,0x5f,0x51, 0x6,0x5f,0x52, + 0x4,0x45,0x47, 0x4,0x45,0x48, 0x5,0x47,0x6c, 0x5,0x47,0x6a, + 0x5,0x47,0x6b, 0x4,0x45,0x49, 0x6,0x5f,0x50, 0x4,0x45,0x4b, + 0xf,0x4d,0x3f, 0x5,0x4e,0x6e, 0x4,0x4b,0x52, 0x7,0x25,0x75, + 0x5,0x4e,0x6f, 0x4,0x4b,0x51, 0x7,0x25,0x74, 0x4,0x4b,0x53, + 0x4,0x51,0x69, 0x4,0x51,0x68, 0x4,0x51,0x6a, 0x5,0x56,0x2d, + 0x5,0x62,0x75, 0x7,0x39,0x65, 0x5,0x5a,0x75, 0x5,0x5c,0x50, + 0x5,0x62,0x74, 0x5,0x62,0x73, 0x5,0x62,0x72, 0x5,0x68,0x57, + 0x5,0x68,0x56, 0x5,0x68,0x55, 0x5,0x68,0x58, 0x7,0x48,0x36, + 0x7,0x48,0x37, 0x4,0x6a,0x5a, 0x7,0x66,0x3f, 0x7,0x66,0x49, + 0x6,0x26,0x3f, 0x6,0x28,0x6b, 0x6,0x28,0x6c, 0x6,0x33,0x41, + 0x6,0x33,0x3f, 0x6,0x33,0x40, 0x5,0x2a,0x6e, 0x5,0x2f,0x2a, + 0x5,0x2f,0x2b, 0x6,0x3a,0x33, 0xf,0x31,0x3f, 0xf,0x31,0x40, + 0x6,0x3a,0x31, 0x6,0x3a,0x32, 0x5,0x2f,0x29, 0x5,0x34,0x23, + 0x5,0x34,0x24, 0x4,0x33,0x5c, 0x6,0x42,0x59, 0x6,0x42,0x57, + 0x5,0x34,0x25, 0x6,0x42,0x55, 0x6,0x42,0x5b, 0x6,0x42,0x56, + 0x6,0x42,0x5a, 0x6,0x42,0x58, 0x4,0x39,0x52, 0x6,0x4c,0x2c, + 0xf,0x3d,0x52, 0x6,0x4c,0x2a, 0xf,0x3d,0x53, 0x5,0x41,0x24, + 0x4,0x3f,0x32, 0x6,0x55,0x69, 0x4,0x3f,0x35, 0x4,0x3f,0x34, + 0x6,0x55,0x67, 0x5,0x3a,0x56, 0x4,0x3f,0x36, 0xf,0x43,0x75, + 0x6,0x55,0x68, 0x5,0x47,0x6d, 0x5,0x47,0x6e, 0x6,0x5f,0x53, + 0x5,0x47,0x6f, 0x5,0x47,0x70, 0xf,0x4a,0x3e, 0x7,0x25,0x78, + 0x4,0x4b,0x54, 0x7,0x25,0x76, 0x7,0x25,0x77, 0xf,0x50,0x61, + 0x7,0x25,0x79, 0x7,0x30,0x54, 0x4,0x51,0x6b, 0xf,0x56,0x3f, + 0x7,0x30,0x53, 0x5,0x5c,0x51, 0x5,0x5c,0x52, 0x7,0x39,0x66, + 0x7,0x39,0x67, 0x5,0x73,0x67, 0x5,0x76,0x2c, 0x5,0x22,0x7e, + 0x6,0x25,0x3e, 0x4,0x24,0x67, 0x6,0x28,0x6d, 0x5,0x24,0x6d, + 0x5,0x24,0x6c, 0xf,0x25,0x21, 0xf,0x25,0x22, 0x5,0x27,0x45, + 0x4,0x27,0x54, 0xf,0x28,0x30, 0xf,0x28,0x31, 0xf,0x28,0x32, + 0xf,0x28,0x33, 0x6,0x2d,0x47, 0xf,0x28,0x35, 0x4,0x2a,0x65, + 0x4,0x2a,0x63, 0x6,0x33,0x45, 0x5,0x2a,0x70, 0xf,0x2c,0x59, + 0xf,0x2c,0x5a, 0xf,0x2c,0x5b, 0xf,0x2c,0x5d, 0xf,0x2c,0x5e, + 0xf,0x2c,0x5f, 0xf,0x2c,0x61, 0xf,0x2c,0x63, 0x6,0x33,0x43, + 0x6,0x33,0x44, 0xf,0x2c,0x64, 0xf,0x2c,0x60, 0x6,0x33,0x42, + 0x5,0x2a,0x6f, 0x5,0x2a,0x71, 0x4,0x2e,0x60, 0x5,0x2f,0x33, + 0x6,0x3a,0x34, 0x6,0x33,0x46, 0x6,0x3a,0x35, 0x5,0x2f,0x2f, + 0x6,0x3a,0x39, 0x5,0x2f,0x2c, 0x5,0x2f,0x31, 0x5,0x2f,0x30, + 0x4,0x2e,0x5b, 0x4,0x2e,0x5d, 0x5,0x2f,0x36, 0x5,0x2f,0x32, + 0x5,0x2f,0x35, 0xf,0x31,0x3e, 0x4,0x2e,0x59, 0x5,0x2f,0x37, + 0x6,0x3a,0x38, 0xf,0x31,0x42, 0xf,0x31,0x43, 0xf,0x31,0x45, + 0xf,0x31,0x46, 0x4,0x2e,0x5a, 0x5,0x2f,0x2d, 0x6,0x3a,0x37, + 0xf,0x31,0x48, 0xf,0x31,0x41, 0x5,0x34,0x26, 0x5,0x2f,0x2e, + 0x6,0x3a,0x36, 0x5,0x34,0x2c, 0x5,0x34,0x28, 0x6,0x42,0x61, + 0x6,0x42,0x5f, 0x5,0x34,0x31, 0x5,0x34,0x30, 0x5,0x34,0x2a, + 0x6,0x42,0x60, 0x5,0x34,0x34, 0x5,0x34,0x32, 0x5,0x2f,0x38, + 0x5,0x34,0x2e, 0x5,0x34,0x27, 0x5,0x34,0x29, 0x5,0x34,0x2d, + 0xf,0x37,0x28, 0xf,0x37,0x29, 0xf,0x37,0x2a, 0xf,0x37,0x2b, + 0xf,0x37,0x2e, 0xf,0x37,0x2f, 0xf,0x37,0x31, 0xf,0x37,0x32, + 0xf,0x37,0x33, 0x6,0x42,0x5e, 0x6,0x42,0x5c, 0x6,0x4c,0x2e, + 0xf,0x37,0x30, 0x5,0x34,0x2b, 0xf,0x37,0x2c, 0x6,0x42,0x62, + 0x5,0x34,0x2f, 0x5,0x34,0x33, 0x6,0x42,0x5d, 0x5,0x3a,0x58, + 0x5,0x3a,0x5e, 0x5,0x3a,0x57, 0x5,0x3a,0x5b, 0x4,0x39,0x56, + 0x6,0x4c,0x35, 0x4,0x39,0x57, 0x4,0x39,0x55, 0x5,0x3a,0x5c, + 0x5,0x3a,0x5d, 0x6,0x4c,0x31, 0x5,0x3a,0x5a, 0x5,0x3a,0x5f, + 0xf,0x3d,0x54, 0xf,0x3d,0x55, 0xf,0x3d,0x56, 0xf,0x3d,0x57, + 0x6,0x4c,0x34, 0x6,0x4c,0x30, 0x6,0x4c,0x32, 0x5,0x3a,0x61, + 0x5,0x3a,0x60, 0x5,0x41,0x28, 0x6,0x55,0x71, 0x4,0x3f,0x37, + 0x5,0x41,0x29, 0x6,0x55,0x6a, 0x6,0x55,0x6c, 0x5,0x41,0x25, + 0x6,0x55,0x6e, 0x4,0x3f,0x41, 0x4,0x3f,0x43, 0x6,0x55,0x6f, + 0x6,0x55,0x72, 0x5,0x41,0x26, 0x5,0x41,0x27, 0x6,0x55,0x6d, + 0xf,0x43,0x77, 0xf,0x43,0x78, 0xf,0x43,0x79, 0xf,0x43,0x7a, + 0xf,0x43,0x7b, 0xf,0x43,0x7c, 0xf,0x43,0x7d, 0xf,0x43,0x7e, + 0xf,0x44,0x21, 0xf,0x44,0x22, 0xf,0x44,0x23, 0xf,0x44,0x24, + 0xf,0x44,0x26, 0x6,0x55,0x70, 0x6,0x55,0x73, 0x6,0x5f,0x5b, + 0x5,0x47,0x78, 0x6,0x5f,0x54, 0x7,0x25,0x7e, 0x5,0x47,0x7a, + 0x6,0x5f,0x56, 0x4,0x45,0x52, 0x5,0x47,0x73, 0x5,0x47,0x72, + 0x6,0x5f,0x57, 0x5,0x47,0x7b, 0x6,0x5f,0x59, 0x6,0x5f,0x5a, + 0x5,0x47,0x75, 0x6,0x5f,0x55, 0x5,0x47,0x71, 0x5,0x47,0x7d, + 0x6,0x5f,0x58, 0xf,0x4a,0x41, 0xf,0x4a,0x43, 0xf,0x4a,0x44, + 0xf,0x4a,0x45, 0xf,0x4a,0x46, 0xf,0x4a,0x47, 0xf,0x4a,0x48, + 0xf,0x4a,0x49, 0xf,0x4a,0x4b, 0xf,0x4a,0x4c, 0xf,0x4a,0x4d, + 0xf,0x4a,0x4f, 0xf,0x4a,0x50, 0xf,0x4a,0x51, 0xf,0x4a,0x52, + 0x4,0x45,0x54, 0xf,0x4a,0x40, 0x5,0x47,0x77, 0x5,0x47,0x7c, + 0x5,0x47,0x79, 0x5,0x47,0x74, 0xf,0x50,0x64, 0x4,0x4b,0x5a, + 0x5,0x4e,0x72, 0x5,0x4e,0x73, 0x7,0x26,0x21, 0x5,0x4e,0x70, + 0x4,0x45,0x50, 0x7,0x26,0x25, 0x5,0x4e,0x75, 0x7,0x25,0x7d, + 0xf,0x50,0x62, 0xf,0x50,0x63, 0xf,0x50,0x65, 0xf,0x50,0x66, + 0xf,0x50,0x68, 0x7,0x26,0x22, 0x7,0x25,0x7a, 0x7,0x26,0x23, + 0x5,0x4e,0x71, 0x5,0x4e,0x74, 0x7,0x25,0x7c, 0xf,0x4a,0x4a, + 0x7,0x30,0x58, 0x5,0x56,0x31, 0x5,0x56,0x2e, 0x5,0x56,0x32, + 0x7,0x30,0x55, 0x4,0x51,0x71, 0x4,0x51,0x73, 0x5,0x56,0x34, + 0x4,0x51,0x72, 0x7,0x30,0x56, 0x7,0x30,0x5a, 0x4,0x51,0x6f, + 0x7,0x30,0x57, 0xf,0x56,0x41, 0xf,0x56,0x42, 0xf,0x56,0x43, + 0x5,0x56,0x30, 0xf,0x56,0x44, 0x5,0x56,0x2f, 0xf,0x56,0x45, + 0xf,0x56,0x46, 0xf,0x56,0x47, 0xf,0x56,0x49, 0xf,0x56,0x4b, + 0xf,0x56,0x4c, 0xf,0x56,0x4d, 0x5,0x5c,0x56, 0x7,0x39,0x68, + 0x5,0x5c,0x54, 0x7,0x39,0x6f, 0x7,0x39,0x6a, 0x5,0x5c,0x53, + 0x4,0x57,0x3a, 0x7,0x39,0x69, 0x5,0x5c,0x55, 0x4,0x57,0x3d, + 0x7,0x39,0x6c, 0x4,0x57,0x3c, 0x5,0x56,0x35, 0x5,0x5c,0x58, + 0x5,0x5c,0x57, 0x5,0x5c,0x59, 0xf,0x5b,0x41, 0xf,0x5b,0x42, + 0xf,0x5b,0x43, 0xf,0x5b,0x44, 0xf,0x5b,0x45, 0xf,0x5b,0x46, + 0xf,0x5b,0x47, 0xf,0x5b,0x48, 0xf,0x5b,0x49, 0x7,0x39,0x6b, + 0x7,0x39,0x6e, 0xf,0x56,0x4a, 0x7,0x41,0x29, 0x5,0x62,0x76, + 0x5,0x62,0x78, 0x7,0x41,0x26, 0x7,0x41,0x28, 0x5,0x62,0x77, + 0x4,0x5c,0x30, 0x5,0x62,0x7a, 0x7,0x41,0x27, 0x5,0x62,0x79, + 0x7,0x41,0x2a, 0xf,0x5f,0x65, 0xf,0x5f,0x66, 0xf,0x5f,0x67, + 0xf,0x5f,0x68, 0xf,0x5f,0x69, 0x4,0x60,0x40, 0x5,0x68,0x5a, + 0x5,0x68,0x59, 0xf,0x63,0x2b, 0xf,0x63,0x2c, 0xf,0x63,0x2d, + 0xf,0x63,0x2e, 0x7,0x48,0x3a, 0x7,0x48,0x38, 0x7,0x48,0x39, + 0xf,0x63,0x2f, 0x5,0x6c,0x65, 0x5,0x6c,0x66, 0x7,0x4e,0x59, + 0x7,0x4e,0x5a, 0x5,0x6c,0x64, 0x5,0x6c,0x67, 0x4,0x60,0x41, + 0x7,0x4e,0x5b, 0xf,0x65,0x5a, 0xf,0x65,0x5b, 0xf,0x65,0x5c, + 0xf,0x65,0x5d, 0x7,0x4e,0x5d, 0x5,0x70,0x56, 0x5,0x70,0x57, + 0xf,0x67,0x7d, 0x7,0x54,0x24, 0x4,0x66,0x62, 0xf,0x67,0x7c, + 0x5,0x73,0x68, 0x7,0x58,0x48, 0x5,0x73,0x69, 0xf,0x69,0x5b, + 0xf,0x69,0x5c, 0x7,0x58,0x49, 0x5,0x73,0x6a, 0x5,0x76,0x2e, + 0x4,0x6a,0x5b, 0x5,0x76,0x2d, 0x5,0x76,0x2f, 0xf,0x6a,0x65, + 0x7,0x5c,0x28, 0x7,0x5c,0x27, 0x7,0x5f,0x26, 0x7,0x5f,0x25, + 0x7,0x5f,0x27, 0x7,0x62,0x46, 0x5,0x7a,0x2d, 0x5,0x7a,0x6e, + 0x4,0x6d,0x75, 0x7,0x64,0x53, 0x7,0x65,0x3b, 0x5,0x7c,0x43, + 0x6,0x22,0x27, 0x6,0x25,0x40, 0x6,0x28,0x6e, 0xf,0x22,0x68, + 0x6,0x2d,0x48, 0xf,0x25,0x24, 0x6,0x33,0x47, 0x6,0x33,0x49, + 0xf,0x28,0x36, 0xf,0x28,0x38, 0xf,0x28,0x39, 0xf,0x28,0x3a, + 0xf,0x28,0x3b, 0xf,0x28,0x3d, 0xf,0x28,0x37, 0x6,0x31,0x5a, + 0x5,0x2f,0x39, 0x6,0x3a,0x3a, 0x4,0x2e,0x63, 0x5,0x2f,0x3a, + 0x6,0x3a,0x3b, 0x6,0x33,0x4b, 0xf,0x2c,0x65, 0xf,0x2c,0x66, + 0xf,0x2c,0x67, 0xf,0x2c,0x68, 0xf,0x2c,0x69, 0xf,0x31,0x49, + 0xf,0x31,0x4b, 0xf,0x31,0x4e, 0x6,0x3a,0x3e, 0x6,0x3a,0x3f, + 0x6,0x3a,0x3d, 0x6,0x3a,0x40, 0x6,0x3a,0x3c, 0xf,0x2c,0x6a, + 0x4,0x2a,0x68, 0x5,0x34,0x36, 0x6,0x3a,0x41, 0xf,0x31,0x4a, + 0xf,0x31,0x4c, 0xf,0x31,0x4d, 0xf,0x31,0x4f, 0xf,0x31,0x50, + 0xf,0x31,0x51, 0xf,0x31,0x52, 0xf,0x31,0x53, 0xf,0x31,0x54, + 0xf,0x37,0x37, 0x6,0x42,0x63, 0x5,0x34,0x35, 0x6,0x4c,0x38, + 0x5,0x3a,0x62, 0x6,0x4c,0x39, 0x6,0x4c,0x3a, 0x6,0x4c,0x3c, + 0x5,0x3a,0x63, 0x6,0x4c,0x3d, 0x6,0x4c,0x3b, 0x6,0x4c,0x36, + 0x6,0x4c,0x37, 0xf,0x37,0x34, 0xf,0x37,0x36, 0xf,0x37,0x38, + 0xf,0x3d,0x5b, 0xf,0x37,0x35, 0x6,0x55,0x75, 0x5,0x41,0x2b, + 0x5,0x41,0x2a, 0x5,0x41,0x2c, 0x6,0x4c,0x3f, 0x4,0x3f,0x48, + 0xf,0x3d,0x58, 0xf,0x3d,0x59, 0xf,0x3d,0x5a, 0xf,0x3d,0x5c, + 0xf,0x3d,0x5d, 0xf,0x3d,0x5e, 0xf,0x3d,0x5f, 0xf,0x3d,0x62, + 0xf,0x3d,0x63, 0xf,0x3d,0x64, 0xf,0x44,0x28, 0xf,0x44,0x2a, + 0xf,0x3d,0x61, 0x6,0x55,0x74, 0x5,0x48,0x23, 0x6,0x5f,0x5f, + 0x6,0x5f,0x60, 0x4,0x45,0x56, 0x6,0x5f,0x63, 0x6,0x5f,0x61, + 0xf,0x44,0x27, 0xf,0x44,0x29, 0xf,0x44,0x2b, 0xf,0x44,0x2c, + 0xf,0x44,0x2d, 0xf,0x44,0x2e, 0xf,0x44,0x2f, 0xf,0x44,0x30, + 0xf,0x44,0x31, 0xf,0x44,0x32, 0x6,0x5f,0x5d, 0x6,0x5f,0x62, + 0x5,0x48,0x21, 0x6,0x5f,0x5e, 0x4,0x4b,0x5f, 0x7,0x26,0x26, + 0x6,0x5f,0x5c, 0x6,0x5f,0x64, 0xf,0x4a,0x53, 0xf,0x4a,0x55, + 0xf,0x4a,0x56, 0xf,0x4a,0x57, 0xf,0x4a,0x58, 0xf,0x4a,0x5a, + 0x7,0x26,0x28, 0x5,0x56,0x38, 0x7,0x30,0x5c, 0x5,0x56,0x36, + 0x7,0x30,0x5d, 0x4,0x51,0x77, 0x5,0x56,0x39, 0x5,0x56,0x37, + 0x5,0x56,0x3a, 0x7,0x26,0x2a, 0x7,0x30,0x5b, 0xf,0x50,0x6a, + 0xf,0x50,0x69, 0xf,0x56,0x51, 0x4,0x57,0x43, 0x5,0x5c,0x5a, + 0x7,0x39,0x73, 0x4,0x57,0x44, 0x7,0x39,0x76, 0x7,0x39,0x74, + 0x7,0x30,0x5e, 0xf,0x50,0x6b, 0xf,0x56,0x4e, 0xf,0x56,0x4f, + 0xf,0x56,0x50, 0xf,0x56,0x52, 0x7,0x39,0x71, 0x7,0x39,0x75, + 0x7,0x39,0x72, 0x7,0x39,0x70, 0xf,0x5b,0x4d, 0xf,0x5b,0x4f, + 0x4,0x5c,0x34, 0x5,0x62,0x7b, 0x7,0x41,0x2c, 0xf,0x5b,0x4b, + 0xf,0x5b,0x4c, 0xf,0x5b,0x4e, 0xf,0x5b,0x50, 0xf,0x5b,0x51, + 0xf,0x5b,0x52, 0x7,0x41,0x2b, 0x4,0x5c,0x33, 0x5,0x68,0x5b, + 0x7,0x48,0x3c, 0x7,0x48,0x3d, 0xf,0x5f,0x6a, 0xf,0x5f,0x6b, + 0x5,0x6c,0x68, 0x4,0x63,0x77, 0xf,0x65,0x5e, 0x7,0x4e,0x5e, + 0x7,0x54,0x26, 0x7,0x54,0x25, 0xf,0x65,0x5f, 0x4,0x68,0x7d, + 0x7,0x58,0x4a, 0x7,0x58,0x4b, 0x7,0x5c,0x29, 0xf,0x69,0x5d, + 0x7,0x5c,0x2a, 0x7,0x5c,0x2b, 0x5,0x77,0x6e, 0x7,0x5c,0x2c, + 0x5,0x77,0x6f, 0xf,0x6a,0x67, 0x5,0x79,0x32, 0x7,0x62,0x49, + 0x7,0x62,0x47, 0x7,0x63,0x5d, 0xf,0x6c,0x67, 0xf,0x22,0x69, + 0x6,0x33,0x4d, 0x6,0x42,0x64, 0x4,0x39,0x5b, 0x6,0x4c,0x40, + 0x6,0x55,0x76, 0x6,0x5f,0x65, 0x7,0x26,0x2c, 0x7,0x30,0x5f, + 0x7,0x30,0x60, 0x7,0x41,0x2d, 0x5,0x73,0x6b, 0x7,0x61,0x28, + 0x4,0x21,0x7e, 0x6,0x25,0x41, 0xf,0x22,0x6a, 0x6,0x28,0x6f, + 0xf,0x25,0x25, 0x6,0x28,0x70, 0x4,0x27,0x55, 0x5,0x27,0x48, + 0x4,0x27,0x57, 0x5,0x27,0x47, 0xf,0x28,0x3e, 0xf,0x28,0x3f, + 0xf,0x28,0x40, 0xf,0x28,0x41, 0xf,0x28,0x42, 0x6,0x2d,0x4a, + 0x6,0x33,0x51, 0x6,0x33,0x54, 0x5,0x2a,0x74, 0x5,0x2a,0x72, + 0x4,0x2a,0x70, 0x5,0x2a,0x75, 0x6,0x33,0x56, 0x6,0x33,0x50, + 0x6,0x33,0x52, 0x4,0x2a,0x6d, 0x6,0x33,0x4f, 0x5,0x2a,0x73, + 0x6,0x33,0x57, 0xf,0x2c,0x6b, 0xf,0x2c,0x6c, 0xf,0x2c,0x6e, + 0xf,0x2c,0x6f, 0xf,0x2c,0x70, 0x6,0x33,0x55, 0x6,0x33,0x53, + 0x6,0x33,0x4e, 0x5,0x2f,0x3c, 0x5,0x2f,0x3b, 0x6,0x3a,0x45, + 0x5,0x2f,0x3d, 0x6,0x3a,0x46, 0x5,0x2f,0x3e, 0x5,0x2a,0x76, + 0x5,0x34,0x3c, 0x6,0x3a,0x47, 0xf,0x31,0x55, 0xf,0x31,0x56, + 0x6,0x3a,0x42, 0x6,0x3a,0x44, 0x5,0x34,0x3a, 0x6,0x42,0x69, + 0x5,0x34,0x3f, 0x4,0x33,0x68, 0x5,0x34,0x3d, 0x6,0x42,0x68, + 0x5,0x34,0x37, 0xf,0x37,0x3a, 0xf,0x37,0x3c, 0xf,0x37,0x3d, + 0xf,0x37,0x3e, 0x4,0x33,0x6c, 0x6,0x42,0x65, 0x6,0x42,0x6a, + 0x4,0x39,0x5f, 0x5,0x3a,0x64, 0x4,0x39,0x60, 0x4,0x39,0x5c, + 0x6,0x4c,0x41, 0x6,0x4c,0x42, 0x6,0x4c,0x45, 0x6,0x4c,0x47, + 0x4,0x39,0x5d, 0x6,0x4c,0x44, 0x4,0x3f,0x51, 0xf,0x3d,0x65, + 0xf,0x3d,0x67, 0xf,0x3d,0x69, 0x5,0x34,0x3e, 0xf,0x3d,0x66, + 0x5,0x41,0x36, 0x5,0x41,0x2f, 0x6,0x55,0x79, 0x6,0x55,0x77, + 0x6,0x55,0x7a, 0x5,0x41,0x30, 0x5,0x41,0x2d, 0x5,0x41,0x32, + 0x5,0x41,0x34, 0x5,0x41,0x38, 0x5,0x41,0x33, 0x4,0x3f,0x4e, + 0x6,0x56,0x21, 0x5,0x41,0x2e, 0x6,0x55,0x7b, 0x6,0x55,0x7e, + 0x6,0x55,0x7c, 0xf,0x44,0x33, 0xf,0x44,0x34, 0xf,0x44,0x35, + 0xf,0x44,0x36, 0xf,0x44,0x37, 0xf,0x44,0x38, 0xf,0x44,0x39, + 0xf,0x44,0x3a, 0x6,0x55,0x78, 0x6,0x55,0x7d, 0x5,0x41,0x37, + 0x5,0x41,0x35, 0x5,0x48,0x28, 0x6,0x5f,0x69, 0x5,0x45,0x2d, + 0x5,0x48,0x2d, 0x6,0x5f,0x68, 0x6,0x5f,0x66, 0x6,0x5f,0x6a, + 0x4,0x45,0x5c, 0x5,0x48,0x2e, 0x5,0x48,0x29, 0x6,0x5f,0x6e, + 0x6,0x5f,0x6f, 0x5,0x48,0x2b, 0x5,0x48,0x27, 0x5,0x48,0x2c, + 0x6,0x5f,0x70, 0x5,0x48,0x2a, 0x6,0x5f,0x67, 0xf,0x4a,0x60, + 0xf,0x4a,0x5b, 0xf,0x4a,0x5c, 0xf,0x4a,0x5d, 0xf,0x4a,0x5e, + 0xf,0x4a,0x5f, 0xf,0x4a,0x61, 0xf,0x4a,0x62, 0xf,0x4a,0x63, + 0xf,0x4a,0x65, 0x6,0x5f,0x6d, 0x6,0x5f,0x6c, 0x5,0x4e,0x7b, + 0x5,0x4e,0x78, 0x5,0x4e,0x7a, 0x7,0x26,0x33, 0x7,0x26,0x30, + 0x5,0x4e,0x79, 0x4,0x4b,0x69, 0x7,0x26,0x34, 0x7,0x26,0x31, + 0x7,0x26,0x38, 0x5,0x48,0x2f, 0x7,0x26,0x2f, 0x5,0x56,0x45, + 0x5,0x4e,0x7c, 0x5,0x4e,0x7d, 0x4,0x4b,0x67, 0x4,0x4b,0x6a, + 0x7,0x26,0x35, 0xf,0x50,0x6c, 0xf,0x50,0x6e, 0xf,0x50,0x6f, + 0xf,0x50,0x70, 0xf,0x50,0x71, 0xf,0x50,0x72, 0x7,0x26,0x2e, + 0x7,0x26,0x36, 0x7,0x26,0x37, 0x4,0x51,0x7b, 0x7,0x30,0x6d, + 0x5,0x56,0x3d, 0x5,0x56,0x40, 0x7,0x30,0x69, 0x5,0x56,0x3c, + 0x5,0x56,0x3f, 0x5,0x56,0x3e, 0x4,0x51,0x7e, 0x5,0x56,0x3b, + 0x5,0x56,0x43, 0x7,0x30,0x63, 0x7,0x30,0x64, 0x5,0x56,0x42, + 0x7,0x30,0x62, 0x5,0x56,0x46, 0x5,0x5c,0x5b, 0x5,0x56,0x47, + 0x7,0x30,0x6b, 0x7,0x30,0x6a, 0x7,0x30,0x6c, 0x7,0x30,0x61, + 0xf,0x56,0x54, 0xf,0x56,0x55, 0x7,0x30,0x65, 0x7,0x30,0x67, + 0x7,0x30,0x68, 0x5,0x56,0x44, 0x5,0x56,0x41, 0x5,0x5c,0x5e, + 0x5,0x5c,0x61, 0x5,0x5c,0x62, 0x5,0x5c,0x5f, 0x5,0x5c,0x5c, + 0x5,0x5c,0x5d, 0x4,0x57,0x4a, 0x7,0x39,0x77, 0x5,0x5c,0x64, + 0x4,0x57,0x46, 0x5,0x5c,0x60, 0x7,0x39,0x7a, 0xf,0x5b,0x54, + 0xf,0x5b,0x55, 0xf,0x5b,0x56, 0xf,0x5b,0x57, 0xf,0x5b,0x58, + 0xf,0x5b,0x5a, 0x7,0x39,0x78, 0xf,0x5b,0x53, 0x5,0x56,0x48, + 0x7,0x39,0x79, 0x5,0x5c,0x63, 0xf,0x56,0x53, 0x5,0x62,0x7d, + 0x5,0x63,0x26, 0x5,0x63,0x24, 0x5,0x63,0x21, 0x5,0x63,0x22, + 0x5,0x63,0x25, 0x7,0x41,0x30, 0x5,0x62,0x7e, 0x7,0x41,0x2f, + 0x5,0x63,0x23, 0xf,0x5f,0x6c, 0xf,0x5f,0x6d, 0xf,0x5f,0x6e, + 0xf,0x5f,0x6f, 0xf,0x5f,0x70, 0xf,0x5f,0x71, 0xf,0x5f,0x72, + 0x5,0x62,0x7c, 0x5,0x68,0x5e, 0x4,0x60,0x43, 0x5,0x68,0x5c, + 0x4,0x60,0x44, 0x4,0x60,0x47, 0x7,0x48,0x3f, 0x4,0x60,0x46, + 0x5,0x68,0x5d, 0x7,0x4e,0x62, 0x7,0x48,0x41, 0x7,0x48,0x3e, + 0xf,0x63,0x30, 0x7,0x48,0x40, 0x5,0x6c,0x6b, 0x4,0x63,0x7a, + 0x4,0x63,0x78, 0x5,0x6c,0x6a, 0x7,0x4e,0x60, 0x4,0x5c,0x38, + 0x5,0x6c,0x69, 0x5,0x6c,0x6c, 0x7,0x4e,0x5f, 0x7,0x4e,0x61, + 0xf,0x65,0x60, 0xf,0x65,0x61, 0xf,0x65,0x63, 0x7,0x4e,0x63, + 0x5,0x6c,0x6d, 0x7,0x54,0x28, 0x7,0x54,0x27, 0x5,0x70,0x58, + 0x7,0x54,0x29, 0x7,0x58,0x4d, 0x5,0x73,0x6c, 0x7,0x58,0x4e, + 0x5,0x76,0x30, 0x5,0x76,0x31, 0x7,0x58,0x4f, 0x5,0x77,0x70, + 0x7,0x5c,0x2d, 0x7,0x5c,0x2e, 0x7,0x5f,0x28, 0x7,0x5e,0x71, + 0xf,0x6b,0x57, 0xf,0x6b,0x58, 0x4,0x6c,0x77, 0x5,0x79,0x33, + 0xf,0x6c,0x34, 0x4,0x6c,0x78, 0x5,0x7a,0x2e, 0x5,0x7b,0x61, + 0x5,0x7b,0x62, 0x6,0x23,0x37, 0x5,0x24,0x6f, 0x5,0x24,0x70, + 0x4,0x27,0x59, 0x4,0x27,0x5a, 0x4,0x27,0x58, 0x6,0x2d,0x4d, + 0x6,0x2d,0x4c, 0x6,0x2d,0x4f, 0x3,0x2a,0x45, 0x6,0x2d,0x4b, + 0xf,0x28,0x43, 0x4,0x2a,0x74, 0x6,0x33,0x59, 0x6,0x33,0x5b, + 0x6,0x33,0x58, 0x5,0x2a,0x77, 0x4,0x2a,0x73, 0x5,0x2a,0x79, + 0x5,0x2a,0x78, 0x6,0x33,0x5a, 0x6,0x33,0x5c, 0x6,0x33,0x5d, + 0x5,0x2a,0x7a, 0xf,0x2c,0x71, 0xf,0x2c,0x72, 0xf,0x2c,0x73, + 0x5,0x2f,0x3f, 0x4,0x2e,0x66, 0x4,0x2e,0x6b, 0x4,0x2e,0x68, + 0x5,0x2f,0x43, 0x5,0x2f,0x42, 0x5,0x2f,0x41, 0x6,0x3a,0x4c, + 0x4,0x2e,0x69, 0x4,0x2e,0x6a, 0x4,0x2e,0x67, 0x6,0x3a,0x4a, + 0x6,0x3a,0x48, 0x5,0x2f,0x40, 0x5,0x2f,0x44, 0xf,0x31,0x58, + 0xf,0x31,0x59, 0xf,0x31,0x5a, 0x6,0x3a,0x4b, 0x6,0x3a,0x49, + 0x5,0x34,0x44, 0x5,0x34,0x43, 0x6,0x42,0x6c, 0x6,0x42,0x6b, + 0x6,0x42,0x6d, 0x5,0x34,0x41, 0x4,0x33,0x6e, 0x5,0x34,0x42, + 0x5,0x34,0x40, 0x6,0x42,0x6e, 0xf,0x37,0x40, 0xf,0x37,0x41, + 0xf,0x37,0x42, 0xf,0x37,0x43, 0xf,0x37,0x44, 0x5,0x3a,0x72, + 0x4,0x39,0x66, 0x5,0x3a,0x74, 0x6,0x4c,0x4e, 0x6,0x4c,0x4a, + 0x4,0x39,0x69, 0x6,0x4c,0x52, 0x5,0x3a,0x69, 0x5,0x3a,0x6f, + 0x5,0x3a,0x71, 0x6,0x4c,0x50, 0x5,0x3a,0x67, 0x6,0x4c,0x51, + 0x5,0x3a,0x68, 0x6,0x4c,0x4b, 0x5,0x3a,0x6a, 0x4,0x39,0x68, + 0x5,0x3a,0x73, 0x6,0x4c,0x4c, 0x5,0x3a,0x70, 0x6,0x4c,0x49, + 0x5,0x3a,0x66, 0x5,0x3a,0x6d, 0x6,0x4c,0x4f, 0x5,0x3a,0x6e, + 0x5,0x3a,0x6b, 0x6,0x4c,0x4d, 0xf,0x3d,0x6b, 0x5,0x41,0x3a, + 0x6,0x56,0x29, 0x5,0x41,0x3c, 0x5,0x41,0x3b, 0x5,0x41,0x3e, + 0x6,0x56,0x22, 0x6,0x56,0x24, 0x5,0x3a,0x6c, 0x5,0x41,0x3d, + 0x5,0x41,0x3f, 0x6,0x56,0x28, 0x6,0x56,0x2b, 0x5,0x41,0x40, + 0x6,0x56,0x26, 0x6,0x56,0x25, 0xf,0x44,0x3b, 0xf,0x44,0x3d, + 0xf,0x44,0x3e, 0xf,0x44,0x3f, 0xf,0x44,0x40, 0x6,0x56,0x23, + 0x6,0x56,0x2a, 0x6,0x57,0x26, 0x4,0x45,0x61, 0x6,0x5f,0x77, + 0x5,0x48,0x32, 0x6,0x5f,0x76, 0x6,0x5f,0x72, 0x6,0x5f,0x74, + 0x6,0x5f,0x73, 0x5,0x48,0x31, 0x6,0x5f,0x79, 0xf,0x4a,0x66, + 0x5,0x48,0x33, 0x6,0x5f,0x71, 0xf,0x44,0x3c, 0x7,0x26,0x3b, + 0x5,0x4f,0x21, 0x5,0x4f,0x27, 0x5,0x4f,0x2a, 0x5,0x48,0x30, + 0x7,0x26,0x3a, 0x5,0x4f,0x2b, 0x5,0x4f,0x26, 0x5,0x4f,0x22, + 0x5,0x4f,0x2c, 0x5,0x4f,0x25, 0x7,0x26,0x39, 0x5,0x4e,0x7e, + 0x5,0x4f,0x28, 0x5,0x4f,0x24, 0x5,0x4f,0x29, 0x7,0x27,0x2e, + 0x4,0x4b,0x6d, 0x5,0x56,0x4f, 0x5,0x56,0x51, 0x4,0x52,0x23, + 0x5,0x56,0x50, 0x4,0x52,0x26, 0x5,0x56,0x49, 0x4,0x52,0x28, + 0x7,0x30,0x70, 0x5,0x56,0x4a, 0x5,0x56,0x4c, 0x5,0x56,0x4b, + 0x5,0x56,0x53, 0x5,0x56,0x4d, 0x5,0x56,0x54, 0x7,0x30,0x6e, + 0x5,0x56,0x4e, 0x5,0x5c,0x65, 0x5,0x56,0x55, 0xf,0x56,0x56, + 0xf,0x56,0x57, 0xf,0x56,0x58, 0xf,0x56,0x59, 0xf,0x56,0x5a, + 0x7,0x30,0x71, 0x5,0x5c,0x6a, 0x5,0x5c,0x67, 0x7,0x3a,0x21, + 0x4,0x57,0x4e, 0x5,0x5c,0x69, 0x7,0x39,0x7c, 0x7,0x39,0x7d, + 0x7,0x39,0x7b, 0x5,0x5c,0x66, 0x7,0x39,0x7e, 0x7,0x30,0x72, + 0x5,0x5c,0x68, 0xf,0x5b,0x5b, 0x5,0x63,0x28, 0x5,0x63,0x27, + 0xf,0x5f,0x74, 0x4,0x60,0x4a, 0x7,0x48,0x44, 0x7,0x48,0x43, + 0x5,0x68,0x5f, 0x7,0x48,0x42, 0x7,0x4e,0x64, 0x7,0x4e,0x66, + 0x5,0x68,0x60, 0x4,0x63,0x7b, 0x5,0x6c,0x6e, 0x7,0x54,0x2d, + 0x7,0x4e,0x67, 0x7,0x4e,0x65, 0xf,0x65,0x64, 0x5,0x70,0x5b, + 0x7,0x54,0x2b, 0x4,0x66,0x67, 0x4,0x66,0x66, 0x5,0x70,0x59, + 0x7,0x54,0x2c, 0x5,0x70,0x5a, 0xf,0x68,0x21, 0xf,0x65,0x65, + 0x5,0x76,0x32, 0x7,0x5c,0x2f, 0x5,0x77,0x71, 0x7,0x61,0x2a, + 0xf,0x6b,0x59, 0x7,0x5f,0x29, 0x5,0x79,0x34, 0x7,0x62,0x4a, + 0x5,0x7b,0x63, 0x6,0x28,0x72, 0x6,0x28,0x71, 0x5,0x27,0x49, + 0x5,0x27,0x4a, 0x4,0x2a,0x75, 0xf,0x2c,0x74, 0xf,0x2c,0x78, + 0x4,0x2e,0x6f, 0x5,0x2f,0x47, 0x5,0x2f,0x48, 0x4,0x2e,0x6c, + 0x5,0x2f,0x46, 0x5,0x2f,0x45, 0x4,0x2e,0x6e, 0xf,0x31,0x5c, + 0xf,0x31,0x5d, 0xf,0x31,0x5e, 0xf,0x31,0x5f, 0xf,0x31,0x61, + 0xf,0x31,0x62, 0x6,0x3a,0x4d, 0x6,0x3a,0x4e, 0x6,0x42,0x72, + 0x4,0x33,0x73, 0x6,0x42,0x71, 0x6,0x42,0x73, 0x6,0x42,0x70, + 0x4,0x33,0x74, 0xf,0x37,0x45, 0xf,0x37,0x47, 0x5,0x34,0x47, + 0xf,0x37,0x48, 0x4,0x39,0x6b, 0x6,0x4c,0x55, 0x5,0x3a,0x75, + 0x5,0x3a,0x77, 0x5,0x3a,0x76, 0x5,0x3a,0x78, 0x6,0x4c,0x54, + 0xf,0x3d,0x6d, 0xf,0x3d,0x6e, 0xf,0x3d,0x6f, 0xf,0x3d,0x70, + 0x4,0x3f,0x56, 0x4,0x3f,0x58, 0x5,0x41,0x42, 0x4,0x3f,0x59, + 0x6,0x56,0x2c, 0x5,0x41,0x41, 0x6,0x56,0x2d, 0x6,0x56,0x2e, + 0xf,0x44,0x41, 0xf,0x44,0x42, 0xf,0x44,0x43, 0x5,0x41,0x43, + 0x5,0x48,0x34, 0x6,0x5f,0x7a, 0x5,0x48,0x35, 0x4,0x45,0x62, + 0xf,0x4a,0x67, 0xf,0x4a,0x68, 0xf,0x4a,0x6a, 0xf,0x4a,0x69, + 0x7,0x26,0x3f, 0x4,0x4b,0x6e, 0x5,0x4f,0x2d, 0xf,0x50,0x73, + 0xf,0x50,0x74, 0xf,0x50,0x75, 0x7,0x26,0x3d, 0xf,0x56,0x5c, + 0xf,0x56,0x5b, 0x4,0x57,0x51, 0x7,0x30,0x74, 0x5,0x56,0x56, + 0xf,0x5b,0x5c, 0x5,0x5c,0x6c, 0x5,0x5d,0x63, 0x7,0x3a,0x22, + 0x5,0x5c,0x6b, 0x5,0x63,0x2a, 0x7,0x3a,0x23, 0xf,0x5f,0x75, + 0x7,0x41,0x31, 0x5,0x63,0x29, 0x7,0x4e,0x68, 0x7,0x54,0x2e, + 0xf,0x65,0x66, 0x7,0x48,0x45, 0x5,0x70,0x5c, 0xf,0x68,0x22, + 0x7,0x58,0x50, 0xf,0x69,0x5e, 0xf,0x6a,0x68, 0x7,0x61,0x2b, + 0xf,0x25,0x26, 0x5,0x27,0x4b, 0x6,0x2d,0x50, 0x5,0x27,0x4d, + 0x5,0x27,0x4c, 0x5,0x2a,0x7c, 0x5,0x2a,0x7d, 0x5,0x2a,0x7b, + 0x6,0x33,0x5f, 0x6,0x33,0x5e, 0x5,0x2a,0x7e, 0xf,0x2c,0x79, + 0xf,0x2c,0x7a, 0xf,0x2c,0x7b, 0xf,0x2c,0x7c, 0xf,0x2c,0x7d, + 0xf,0x29,0x24, 0x5,0x2f,0x4e, 0x5,0x2f,0x49, 0x4,0x2e,0x74, + 0x5,0x2f,0x4a, 0x5,0x2f,0x4c, 0x5,0x2f,0x4d, 0x6,0x3a,0x50, + 0x5,0x2f,0x51, 0x5,0x2f,0x4f, 0x5,0x2f,0x4b, 0x6,0x3a,0x4f, + 0x6,0x3a,0x51, 0x5,0x2f,0x50, 0x5,0x2f,0x52, 0xf,0x31,0x63, + 0xf,0x31,0x64, 0xf,0x31,0x65, 0xf,0x31,0x66, 0xf,0x31,0x67, + 0xf,0x31,0x68, 0xf,0x31,0x69, 0xf,0x31,0x6a, 0x4,0x2e,0x76, + 0x6,0x42,0x74, 0x6,0x42,0x7a, 0x5,0x34,0x4a, 0x4,0x33,0x79, + 0x5,0x34,0x4d, 0x6,0x42,0x77, 0x5,0x34,0x4c, 0x6,0x42,0x7c, + 0x4,0x33,0x75, 0x5,0x34,0x4e, 0x6,0x42,0x75, 0x5,0x2f,0x53, + 0x5,0x34,0x49, 0x6,0x42,0x79, 0x6,0x42,0x7b, 0x5,0x34,0x50, + 0x5,0x34,0x51, 0x6,0x42,0x78, 0xf,0x37,0x49, 0xf,0x37,0x4a, + 0xf,0x37,0x4b, 0xf,0x37,0x4c, 0xf,0x37,0x4e, 0xf,0x37,0x4f, + 0x5,0x3a,0x7c, 0x5,0x3b,0x22, 0x5,0x3a,0x7b, 0x5,0x3a,0x7e, + 0x4,0x39,0x6c, 0x4,0x39,0x6e, 0x6,0x4c,0x5a, 0x5,0x34,0x4b, + 0x4,0x39,0x73, 0x5,0x3b,0x21, 0x5,0x3a,0x7a, 0x4,0x39,0x79, + 0x4,0x39,0x77, 0x4,0x39,0x70, 0x6,0x4c,0x5d, 0x4,0x39,0x78, + 0x6,0x4c,0x57, 0x5,0x3b,0x25, 0x6,0x4c,0x59, 0x6,0x4c,0x5c, + 0x5,0x34,0x4f, 0x5,0x3a,0x7d, 0xf,0x3d,0x71, 0xf,0x3d,0x72, + 0xf,0x3d,0x73, 0xf,0x3d,0x74, 0xf,0x3d,0x75, 0xf,0x3d,0x76, + 0xf,0x3d,0x78, 0xf,0x3d,0x79, 0xf,0x3d,0x7a, 0xf,0x3d,0x77, + 0x5,0x3b,0x23, 0x5,0x41,0x54, 0x5,0x41,0x48, 0x5,0x41,0x4f, + 0x4,0x3f,0x5c, 0x5,0x41,0x4d, 0x5,0x41,0x45, 0x4,0x3f,0x64, + 0x4,0x3f,0x65, 0x5,0x41,0x50, 0x4,0x3f,0x5f, 0x5,0x3a,0x79, + 0x6,0x56,0x30, 0x5,0x41,0x46, 0x5,0x41,0x55, 0x5,0x41,0x4b, + 0x5,0x41,0x52, 0x5,0x41,0x44, 0x5,0x41,0x49, 0x5,0x41,0x4c, + 0x6,0x56,0x34, 0x6,0x56,0x32, 0x6,0x56,0x37, 0x6,0x56,0x3a, + 0x6,0x56,0x33, 0x6,0x56,0x36, 0x6,0x56,0x38, 0x6,0x5f,0x7b, + 0x5,0x41,0x53, 0x5,0x41,0x51, 0x5,0x41,0x4e, 0x5,0x41,0x47, + 0x6,0x56,0x31, 0x6,0x4c,0x58, 0x6,0x56,0x35, 0x6,0x56,0x39, + 0xf,0x44,0x44, 0xf,0x44,0x46, 0xf,0x44,0x47, 0xf,0x44,0x48, + 0xf,0x44,0x49, 0xf,0x44,0x4a, 0xf,0x44,0x4b, 0xf,0x44,0x4c, + 0xf,0x44,0x4d, 0xf,0x44,0x4e, 0xf,0x44,0x4f, 0xf,0x44,0x50, + 0x6,0x56,0x2f, 0xf,0x41,0x3e, 0x5,0x48,0x45, 0x5,0x41,0x56, + 0x4,0x45,0x6c, 0x5,0x48,0x43, 0x6,0x60,0x27, 0x4,0x45,0x67, + 0x6,0x5f,0x7c, 0x6,0x5f,0x7d, 0x5,0x48,0x3c, 0x5,0x48,0x3b, + 0x5,0x48,0x42, 0x4,0x45,0x6f, 0x6,0x60,0x28, 0x5,0x48,0x40, + 0x6,0x60,0x26, 0x5,0x48,0x38, 0x5,0x48,0x39, 0x6,0x60,0x25, + 0x6,0x60,0x21, 0x5,0x48,0x3a, 0x5,0x48,0x41, 0x5,0x48,0x37, + 0x5,0x48,0x3d, 0x6,0x60,0x22, 0x5,0x41,0x4a, 0x5,0x48,0x47, + 0x6,0x5f,0x7e, 0x5,0x48,0x3e, 0x6,0x60,0x24, 0x5,0x48,0x3f, + 0x4,0x45,0x71, 0x5,0x48,0x44, 0xf,0x4a,0x6b, 0xf,0x4a,0x6c, + 0xf,0x4a,0x6d, 0xf,0x4a,0x6e, 0xf,0x4a,0x6f, 0xf,0x4a,0x70, + 0xf,0x4a,0x73, 0xf,0x4a,0x74, 0xf,0x4a,0x75, 0xf,0x4a,0x76, + 0xf,0x4a,0x77, 0xf,0x4a,0x78, 0xf,0x4a,0x79, 0xf,0x4a,0x7a, + 0xf,0x4a,0x72, 0xf,0x4a,0x71, 0x5,0x4f,0x3a, 0x7,0x26,0x49, + 0x7,0x26,0x4b, 0x5,0x4f,0x44, 0x4,0x4c,0x2f, 0x5,0x4f,0x33, + 0x7,0x26,0x51, 0x7,0x26,0x4a, 0x5,0x4f,0x3e, 0x4,0x4b,0x71, + 0x4,0x4b,0x6f, 0x5,0x4f,0x41, 0x5,0x4f,0x2f, 0x5,0x4f,0x34, + 0x5,0x4f,0x43, 0x7,0x26,0x42, 0x5,0x4f,0x40, 0x5,0x4f,0x31, + 0x4,0x52,0x40, 0x5,0x4f,0x39, 0x5,0x4f,0x42, 0x4,0x4b,0x72, + 0x4,0x4c,0x29, 0x4,0x4c,0x23, 0x4,0x4b,0x7d, 0x5,0x4f,0x38, + 0x5,0x4f,0x37, 0x5,0x4f,0x3c, 0x7,0x26,0x4e, 0x5,0x48,0x48, + 0x5,0x4f,0x35, 0x7,0x26,0x50, 0x7,0x26,0x47, 0x7,0x26,0x44, + 0x5,0x4f,0x3f, 0x7,0x26,0x40, 0x7,0x26,0x53, 0x4,0x4c,0x24, + 0x7,0x26,0x4f, 0x4,0x4b,0x7c, 0x7,0x26,0x4c, 0x5,0x4f,0x3d, + 0x7,0x26,0x45, 0x7,0x26,0x43, 0x5,0x4f,0x2e, 0x7,0x26,0x48, + 0x7,0x26,0x46, 0x5,0x4f,0x46, 0xf,0x50,0x78, 0x7,0x26,0x52, + 0xf,0x50,0x77, 0xf,0x50,0x7a, 0xf,0x50,0x7b, 0xf,0x50,0x7c, + 0xf,0x50,0x7d, 0xf,0x50,0x7e, 0xf,0x51,0x22, 0xf,0x51,0x24, + 0xf,0x51,0x29, 0xf,0x51,0x25, 0xf,0x51,0x26, 0xf,0x51,0x27, + 0xf,0x51,0x2a, 0x5,0x56,0x64, 0x4,0x52,0x41, 0x4,0x52,0x3e, + 0x5,0x56,0x58, 0x5,0x56,0x5e, 0x5,0x56,0x66, 0x7,0x31,0x2a, + 0x5,0x56,0x5c, 0x4,0x52,0x2e, 0x5,0x56,0x5d, 0x4,0x52,0x2c, + 0x5,0x56,0x68, 0x7,0x26,0x41, 0x7,0x31,0x25, 0x4,0x52,0x32, + 0x5,0x56,0x67, 0x4,0x52,0x31, 0x7,0x31,0x29, 0x4,0x52,0x3c, + 0x7,0x30,0x7e, 0x7,0x31,0x26, 0x4,0x52,0x30, 0x5,0x56,0x60, + 0x7,0x30,0x7b, 0x4,0x52,0x3f, 0x5,0x56,0x5f, 0x5,0x56,0x59, + 0x7,0x30,0x7a, 0x7,0x31,0x28, 0x4,0x52,0x2a, 0x5,0x56,0x57, + 0x7,0x31,0x24, 0x4,0x52,0x35, 0x5,0x56,0x65, 0x7,0x30,0x7d, + 0x5,0x56,0x62, 0x4,0x52,0x33, 0x7,0x31,0x2b, 0x7,0x30,0x75, + 0x7,0x31,0x27, 0x5,0x4f,0x30, 0x5,0x56,0x63, 0x5,0x56,0x5a, + 0x7,0x30,0x78, 0x7,0x31,0x23, 0x7,0x30,0x76, 0x5,0x56,0x61, + 0xf,0x56,0x72, 0x5,0x56,0x5b, 0x7,0x30,0x7c, 0x7,0x30,0x77, + 0x7,0x31,0x22, 0xf,0x56,0x5d, 0xf,0x56,0x5e, 0xf,0x56,0x60, + 0xf,0x56,0x61, 0xf,0x56,0x62, 0xf,0x56,0x63, 0xf,0x56,0x64, + 0xf,0x56,0x65, 0xf,0x56,0x66, 0xf,0x56,0x67, 0xf,0x56,0x68, + 0xf,0x56,0x69, 0xf,0x56,0x6a, 0xf,0x56,0x6b, 0xf,0x56,0x6c, + 0xf,0x56,0x6d, 0xf,0x56,0x6e, 0xf,0x56,0x6f, 0xf,0x56,0x70, + 0xf,0x56,0x71, 0xf,0x56,0x73, 0x7,0x30,0x79, 0xf,0x50,0x79, + 0x5,0x5d,0x24, 0x5,0x5d,0x21, 0x4,0x57,0x5d, 0x5,0x5c,0x75, + 0x5,0x5d,0x2d, 0x5,0x5c,0x79, 0x4,0x57,0x5c, 0x4,0x57,0x63, + 0x4,0x57,0x67, 0x7,0x3a,0x2c, 0x5,0x5d,0x2b, 0x4,0x57,0x60, + 0x5,0x5d,0x22, 0x5,0x5c,0x70, 0x5,0x5d,0x23, 0x5,0x5c,0x72, + 0x5,0x5d,0x31, 0x5,0x5c,0x7b, 0x5,0x5d,0x2a, 0x5,0x5c,0x77, + 0x5,0x5d,0x34, 0x7,0x3a,0x24, 0x5,0x5c,0x76, 0x5,0x5c,0x7c, + 0x5,0x5d,0x26, 0x4,0x57,0x64, 0x5,0x5d,0x27, 0x7,0x3a,0x29, + 0x5,0x63,0x42, 0x5,0x5d,0x2c, 0x5,0x5c,0x7a, 0x7,0x3a,0x2f, + 0x7,0x3a,0x28, 0x5,0x5c,0x6f, 0x5,0x5d,0x32, 0x5,0x5d,0x29, + 0x5,0x5c,0x73, 0x7,0x3a,0x2b, 0x5,0x5d,0x2e, 0x5,0x5c,0x71, + 0x5,0x5c,0x6e, 0x5,0x5d,0x28, 0x4,0x57,0x66, 0x4,0x5c,0x3c, + 0x5,0x5d,0x33, 0x5,0x5c,0x78, 0x5,0x5d,0x2f, 0x5,0x5d,0x25, + 0x7,0x31,0x21, 0x5,0x5c,0x74, 0x7,0x3a,0x27, 0x7,0x3a,0x26, + 0x7,0x3a,0x25, 0x7,0x3a,0x2d, 0xf,0x5b,0x5d, 0xf,0x5b,0x5e, + 0xf,0x5b,0x60, 0xf,0x5b,0x61, 0xf,0x5b,0x62, 0xf,0x5b,0x63, + 0xf,0x5b,0x64, 0xf,0x5b,0x66, 0xf,0x5b,0x67, 0xf,0x5b,0x68, + 0xf,0x5b,0x69, 0x7,0x3a,0x2a, 0x7,0x3a,0x2e, 0x4,0x57,0x68, + 0xf,0x5b,0x65, 0x4,0x57,0x61, 0x5,0x63,0x4b, 0x5,0x63,0x47, + 0x5,0x5d,0x35, 0x4,0x5c,0x52, 0x5,0x63,0x45, 0x5,0x63,0x38, + 0x5,0x63,0x33, 0x4,0x5c,0x47, 0x5,0x63,0x4a, 0x5,0x63,0x40, + 0x3,0x58,0x4f, 0x5,0x63,0x2e, 0x4,0x5c,0x4e, 0x4,0x5c,0x45, + 0x5,0x63,0x43, 0x5,0x63,0x39, 0x5,0x63,0x4c, 0x4,0x5c,0x3d, + 0x7,0x41,0x3b, 0x5,0x63,0x46, 0x5,0x63,0x30, 0x5,0x63,0x37, + 0x4,0x5c,0x3e, 0x4,0x5c,0x3f, 0x5,0x63,0x48, 0x7,0x41,0x39, + 0x5,0x63,0x35, 0x5,0x63,0x32, 0x5,0x63,0x3f, 0x7,0x41,0x35, + 0x5,0x63,0x2c, 0x7,0x41,0x36, 0x4,0x5c,0x41, 0x7,0x41,0x33, + 0x4,0x5c,0x53, 0x5,0x63,0x3e, 0x7,0x41,0x38, 0x5,0x63,0x3d, + 0x7,0x41,0x3a, 0x7,0x41,0x3e, 0x7,0x41,0x34, 0x5,0x63,0x31, + 0x4,0x5c,0x4d, 0x5,0x63,0x36, 0x5,0x63,0x3a, 0x5,0x63,0x44, + 0x5,0x63,0x49, 0x5,0x63,0x3c, 0x5,0x63,0x2d, 0x7,0x41,0x42, + 0x7,0x41,0x41, 0x5,0x63,0x3b, 0x5,0x63,0x2b, 0x5,0x63,0x2f, + 0x7,0x41,0x32, 0x7,0x41,0x37, 0xf,0x5f,0x76, 0xf,0x5f,0x77, + 0xf,0x5f,0x78, 0xf,0x5f,0x79, 0xf,0x5f,0x7a, 0xf,0x5f,0x7b, + 0xf,0x5f,0x7c, 0xf,0x5f,0x7d, 0xf,0x5f,0x7e, 0xf,0x60,0x21, + 0xf,0x60,0x23, 0xf,0x60,0x24, 0xf,0x60,0x25, 0x7,0x41,0x40, + 0x7,0x41,0x3d, 0xf,0x5b,0x6a, 0xf,0x63,0x36, 0xf,0x63,0x37, + 0xf,0x60,0x22, 0x5,0x68,0x6a, 0x5,0x68,0x6f, 0x7,0x48,0x4e, + 0x4,0x60,0x59, 0x7,0x48,0x4c, 0x5,0x68,0x63, 0x4,0x60,0x54, + 0x4,0x60,0x55, 0x4,0x60,0x51, 0x5,0x68,0x69, 0x4,0x60,0x4f, + 0x4,0x60,0x50, 0x7,0x48,0x48, 0x4,0x60,0x52, 0x5,0x68,0x62, + 0x4,0x60,0x58, 0x4,0x60,0x4d, 0x7,0x48,0x47, 0x5,0x68,0x6d, + 0x5,0x68,0x68, 0x5,0x68,0x70, 0x5,0x68,0x6c, 0x5,0x68,0x6b, + 0x5,0x68,0x65, 0x5,0x68,0x64, 0x5,0x68,0x67, 0x7,0x48,0x46, + 0x7,0x48,0x4a, 0x5,0x68,0x61, 0x5,0x68,0x71, 0x7,0x48,0x49, + 0xf,0x63,0x31, 0xf,0x63,0x33, 0xf,0x63,0x34, 0xf,0x63,0x35, + 0xf,0x63,0x38, 0xf,0x63,0x39, 0xf,0x63,0x3a, 0xf,0x63,0x3b, + 0xf,0x63,0x3c, 0x7,0x48,0x4b, 0x7,0x48,0x4d, 0x5,0x6c,0x7c, + 0x5,0x6c,0x7b, 0x5,0x6c,0x76, 0x4,0x60,0x57, 0x5,0x6c,0x74, + 0x7,0x4e,0x6c, 0x5,0x6c,0x7a, 0x4,0x63,0x7d, 0x7,0x4e,0x74, + 0x4,0x64,0x22, 0x5,0x6c,0x78, 0x5,0x6c,0x73, 0x4,0x66,0x70, + 0x7,0x4e,0x6a, 0x5,0x6c,0x6f, 0x5,0x6c,0x75, 0x5,0x6c,0x71, + 0x7,0x4e,0x69, 0x7,0x4e,0x75, 0x5,0x6c,0x77, 0x7,0x4e,0x6d, + 0x7,0x4e,0x6e, 0x5,0x6c,0x72, 0x7,0x4e,0x6f, 0x7,0x54,0x38, + 0x7,0x4e,0x71, 0x7,0x4e,0x70, 0x7,0x4e,0x72, 0x7,0x4e,0x73, + 0xf,0x65,0x68, 0xf,0x65,0x69, 0x7,0x4e,0x6b, 0x5,0x70,0x64, + 0x5,0x70,0x68, 0x5,0x70,0x69, 0x4,0x66,0x71, 0x4,0x66,0x6b, + 0x5,0x70,0x66, 0x5,0x70,0x6b, 0x7,0x54,0x2f, 0x5,0x70,0x5e, + 0x5,0x70,0x63, 0x5,0x70,0x60, 0x4,0x64,0x21, 0x5,0x70,0x67, + 0x5,0x70,0x5f, 0x5,0x6c,0x70, 0x7,0x54,0x35, 0x5,0x70,0x6a, + 0x5,0x70,0x5d, 0x7,0x54,0x31, 0x5,0x70,0x65, 0x4,0x69,0x27, + 0x5,0x70,0x6c, 0x7,0x54,0x36, 0x7,0x54,0x30, 0x7,0x54,0x34, + 0xf,0x68,0x23, 0xf,0x68,0x24, 0xf,0x68,0x25, 0xf,0x68,0x26, + 0xf,0x68,0x27, 0xf,0x68,0x28, 0xf,0x68,0x29, 0x7,0x54,0x33, + 0x7,0x54,0x39, 0x7,0x54,0x32, 0x7,0x58,0x55, 0x4,0x69,0x24, + 0x4,0x69,0x23, 0x5,0x73,0x70, 0x5,0x73,0x6e, 0x5,0x70,0x62, + 0x5,0x73,0x71, 0x7,0x58,0x52, 0x5,0x70,0x6d, 0x7,0x58,0x51, + 0x5,0x73,0x74, 0x4,0x69,0x25, 0x5,0x73,0x6d, 0x7,0x58,0x54, + 0x7,0x54,0x37, 0x5,0x73,0x76, 0x5,0x73,0x73, 0x5,0x73,0x6f, + 0x5,0x73,0x75, 0x5,0x73,0x72, 0x7,0x58,0x56, 0xf,0x69,0x5f, + 0xf,0x69,0x60, 0xf,0x69,0x61, 0xf,0x69,0x62, 0x7,0x58,0x53, + 0x7,0x59,0x34, 0x4,0x6a,0x5e, 0x5,0x76,0x33, 0x7,0x5c,0x31, + 0x5,0x76,0x34, 0x4,0x6a,0x5f, 0x4,0x6a,0x60, 0x4,0x6a,0x62, + 0x7,0x5c,0x30, 0x5,0x76,0x36, 0x7,0x5c,0x32, 0x5,0x76,0x35, + 0x7,0x5c,0x36, 0x7,0x5c,0x35, 0xf,0x6a,0x69, 0x7,0x5c,0x33, + 0x7,0x5c,0x37, 0x7,0x5c,0x34, 0x5,0x77,0x72, 0x7,0x5f,0x2b, + 0x7,0x5f,0x2e, 0x5,0x77,0x74, 0x5,0x77,0x75, 0x7,0x5f,0x2d, + 0x5,0x76,0x37, 0x7,0x5f,0x2c, 0x7,0x5f,0x2a, 0x5,0x77,0x73, + 0x7,0x5f,0x31, 0x4,0x6b,0x77, 0xf,0x6b,0x5a, 0xf,0x6b,0x5b, + 0xf,0x6b,0x5c, 0x7,0x5f,0x2f, 0x5,0x79,0x35, 0x7,0x61,0x2c, + 0x7,0x61,0x2e, 0x7,0x61,0x31, 0x4,0x6c,0x79, 0x7,0x61,0x2f, + 0x7,0x5f,0x30, 0x7,0x61,0x2d, 0x5,0x7a,0x31, 0x5,0x7a,0x2f, + 0x5,0x7a,0x30, 0x7,0x61,0x30, 0xf,0x6c,0x4f, 0xf,0x6c,0x4d, + 0x7,0x63,0x5e, 0x7,0x63,0x5f, 0xf,0x6c,0x68, 0x7,0x63,0x60, + 0x5,0x7b,0x44, 0x5,0x7b,0x64, 0xf,0x6d,0x27, 0x7,0x64,0x54, + 0x4,0x6e,0x4e, 0x5,0x7b,0x7c, 0x5,0x7c,0x2b, 0x5,0x24,0x71, + 0xf,0x25,0x27, 0x5,0x27,0x4e, 0x6,0x2d,0x51, 0xf,0x28,0x45, + 0x6,0x33,0x61, 0x5,0x2b,0x22, 0x6,0x33,0x60, 0x5,0x2b,0x23, + 0xf,0x2c,0x7e, 0xf,0x2d,0x22, 0x6,0x3a,0x52, 0x5,0x2f,0x54, + 0x6,0x3a,0x56, 0x5,0x2f,0x55, 0x6,0x3a,0x54, 0x5,0x2f,0x56, + 0xf,0x31,0x6b, 0xf,0x31,0x6c, 0xf,0x31,0x6d, 0xf,0x31,0x6e, + 0x6,0x3a,0x53, 0x6,0x3a,0x55, 0x4,0x33,0x7e, 0x5,0x34,0x55, + 0x4,0x34,0x24, 0x5,0x34,0x54, 0x4,0x34,0x21, 0x5,0x34,0x58, + 0x5,0x34,0x53, 0x5,0x34,0x56, 0x5,0x34,0x57, 0x4,0x34,0x23, + 0x5,0x34,0x5a, 0x5,0x34,0x52, 0x6,0x42,0x7d, 0x6,0x4c,0x63, + 0x6,0x43,0x21, 0xf,0x37,0x50, 0xf,0x37,0x51, 0x6,0x42,0x7e, + 0xf,0x37,0x52, 0x5,0x3b,0x26, 0x4,0x39,0x7a, 0x6,0x4c,0x61, + 0x6,0x4c,0x5e, 0x6,0x4c,0x65, 0x5,0x3b,0x28, 0x4,0x3a,0x21, + 0x6,0x4c,0x64, 0x6,0x4c,0x5f, 0xf,0x3d,0x7c, 0xf,0x3d,0x7e, + 0xf,0x3e,0x22, 0xf,0x3d,0x7b, 0x6,0x4c,0x62, 0x5,0x41,0x57, + 0x4,0x3f,0x68, 0x6,0x56,0x3d, 0x5,0x41,0x59, 0x5,0x41,0x5a, + 0x5,0x3b,0x27, 0x5,0x41,0x58, 0x6,0x56,0x3f, 0x6,0x56,0x3e, + 0x4,0x39,0x7e, 0x5,0x41,0x5b, 0x5,0x41,0x5d, 0x5,0x41,0x5c, + 0x6,0x56,0x41, 0xf,0x44,0x52, 0xf,0x44,0x53, 0xf,0x44,0x55, + 0xf,0x44,0x56, 0x6,0x56,0x3b, 0xf,0x44,0x54, 0x6,0x56,0x40, + 0xf,0x44,0x51, 0x6,0x60,0x2d, 0x5,0x48,0x4a, 0x6,0x60,0x2b, + 0x6,0x60,0x2e, 0x5,0x48,0x4c, 0x4,0x45,0x73, 0x6,0x56,0x3c, + 0x6,0x60,0x33, 0x6,0x60,0x32, 0x5,0x48,0x4b, 0x6,0x60,0x30, + 0x5,0x48,0x49, 0x5,0x48,0x4d, 0xf,0x4a,0x7c, 0xf,0x4a,0x7d, + 0xf,0x4a,0x7e, 0xf,0x4b,0x21, 0xf,0x4b,0x22, 0xf,0x4b,0x23, + 0xf,0x4b,0x25, 0xf,0x4b,0x26, 0xf,0x4b,0x28, 0xf,0x4b,0x29, + 0xf,0x4b,0x2a, 0xf,0x4b,0x2d, 0x6,0x60,0x2f, 0xf,0x4b,0x2c, + 0x6,0x60,0x29, 0x6,0x60,0x2a, 0xf,0x4b,0x24, 0x7,0x26,0x58, + 0x7,0x26,0x54, 0x4,0x4c,0x36, 0x5,0x4f,0x4b, 0x7,0x26,0x55, + 0x7,0x26,0x59, 0x4,0x4c,0x33, 0x5,0x4f,0x4a, 0x5,0x4f,0x4c, + 0x5,0x4f,0x50, 0x5,0x48,0x4e, 0x5,0x4f,0x4f, 0x5,0x4f,0x4d, + 0x7,0x26,0x5b, 0x7,0x26,0x56, 0x5,0x4f,0x49, 0x4,0x4c,0x34, + 0x5,0x4f,0x4e, 0x4,0x4c,0x32, 0x7,0x26,0x5a, 0x5,0x4f,0x48, + 0x5,0x4f,0x47, 0xf,0x51,0x2b, 0xf,0x51,0x2c, 0xf,0x51,0x2d, + 0xf,0x51,0x2f, 0x5,0x56,0x6e, 0x5,0x56,0x6c, 0x5,0x5d,0x3c, + 0x4,0x52,0x43, 0x5,0x56,0x6b, 0x4,0x52,0x42, 0x7,0x31,0x2f, + 0x7,0x31,0x30, 0x5,0x56,0x6f, 0x7,0x31,0x2c, 0x5,0x56,0x6a, + 0x5,0x56,0x6d, 0x5,0x56,0x70, 0xf,0x56,0x74, 0xf,0x56,0x75, + 0x7,0x31,0x2e, 0x5,0x5d,0x36, 0x5,0x5d,0x38, 0x7,0x3a,0x30, + 0x5,0x5d,0x39, 0x5,0x5d,0x37, 0x5,0x5d,0x3a, 0x5,0x5d,0x3b, + 0x7,0x3a,0x32, 0x7,0x3a,0x34, 0x7,0x3a,0x35, 0x7,0x3a,0x31, + 0xf,0x5b,0x6b, 0xf,0x5b,0x6c, 0xf,0x5b,0x6d, 0xf,0x5b,0x6f, + 0xf,0x5b,0x70, 0xf,0x5b,0x71, 0xf,0x5b,0x72, 0x4,0x57,0x6c, + 0x5,0x63,0x52, 0x7,0x41,0x45, 0x4,0x5c,0x57, 0x5,0x63,0x53, + 0x5,0x63,0x4f, 0x7,0x48,0x56, 0x5,0x63,0x51, 0x5,0x5d,0x3d, + 0x7,0x41,0x46, 0x5,0x63,0x50, 0x7,0x4e,0x78, 0x5,0x63,0x4d, + 0x7,0x41,0x43, 0xf,0x60,0x27, 0xf,0x60,0x28, 0xf,0x60,0x29, + 0xf,0x5b,0x6e, 0x5,0x68,0x74, 0x7,0x48,0x4f, 0x7,0x48,0x50, + 0x4,0x60,0x5e, 0x4,0x60,0x5c, 0x5,0x68,0x73, 0x5,0x70,0x6e, + 0x7,0x48,0x52, 0x7,0x48,0x53, 0x7,0x41,0x48, 0x4,0x60,0x5f, + 0x4,0x5c,0x58, 0x5,0x68,0x75, 0x7,0x41,0x47, 0x5,0x68,0x72, + 0xf,0x63,0x3e, 0x7,0x48,0x51, 0x7,0x48,0x54, 0x7,0x48,0x55, + 0xf,0x63,0x3f, 0x7,0x4e,0x77, 0x5,0x6c,0x7e, 0x7,0x4e,0x76, + 0xf,0x65,0x6a, 0xf,0x65,0x6b, 0x4,0x66,0x73, 0x4,0x66,0x72, + 0x5,0x70,0x6f, 0x7,0x54,0x3d, 0x7,0x54,0x3c, 0xf,0x68,0x2a, + 0xf,0x68,0x2b, 0x7,0x54,0x3b, 0x5,0x73,0x77, 0x7,0x58,0x57, + 0x5,0x73,0x78, 0x4,0x6a,0x63, 0x4,0x6a,0x64, 0x7,0x5c,0x38, + 0xf,0x6a,0x6a, 0x5,0x76,0x38, 0x7,0x5c,0x39, 0x7,0x5f,0x32, + 0x5,0x77,0x77, 0x5,0x77,0x76, 0x5,0x79,0x38, 0x7,0x61,0x33, + 0x5,0x79,0x37, 0x5,0x79,0x36, 0x7,0x61,0x32, 0x7,0x62,0x4c, + 0x4,0x6d,0x5d, 0x5,0x7a,0x32, 0x7,0x62,0x4b, 0x5,0x7a,0x33, + 0x7,0x63,0x62, 0x7,0x63,0x61, 0x5,0x7b,0x7d, 0x7,0x66,0x36, + 0x5,0x27,0x4f, 0x6,0x2d,0x52, 0x5,0x27,0x50, 0xf,0x28,0x47, + 0xf,0x28,0x48, 0x5,0x27,0x51, 0x5,0x2b,0x26, 0x6,0x33,0x62, + 0x6,0x33,0x65, 0x5,0x2b,0x24, 0x5,0x2b,0x25, 0x6,0x33,0x67, + 0x6,0x33,0x63, 0x5,0x2b,0x27, 0xf,0x2d,0x23, 0x6,0x33,0x68, + 0x6,0x3a,0x5b, 0x6,0x3a,0x57, 0x4,0x2e,0x79, 0x6,0x3a,0x63, + 0x4,0x2e,0x7b, 0x6,0x3a,0x5d, 0x6,0x3a,0x5c, 0x6,0x3a,0x5f, + 0x5,0x2f,0x5a, 0x4,0x2e,0x7a, 0x4,0x2f,0x24, 0x6,0x3a,0x64, + 0x6,0x3a,0x59, 0x4,0x2f,0x23, 0x6,0x3a,0x5e, 0x4,0x2f,0x22, + 0x6,0x3a,0x60, 0x6,0x3a,0x58, 0x5,0x2f,0x59, 0x6,0x3a,0x61, + 0x5,0x2f,0x58, 0x5,0x2f,0x57, 0x6,0x3a,0x5a, 0xf,0x31,0x71, + 0xf,0x31,0x72, 0xf,0x31,0x73, 0xf,0x31,0x74, 0xf,0x31,0x75, + 0xf,0x31,0x76, 0xf,0x31,0x77, 0x4,0x2f,0x26, 0x6,0x3a,0x62, + 0x5,0x34,0x5f, 0x5,0x34,0x5d, 0x4,0x34,0x32, 0x4,0x34,0x28, + 0x4,0x34,0x2a, 0x6,0x43,0x28, 0x4,0x34,0x2f, 0x5,0x34,0x5e, + 0x4,0x34,0x31, 0x6,0x43,0x29, 0x5,0x34,0x5b, 0x4,0x34,0x2c, + 0x6,0x43,0x2b, 0x6,0x43,0x2a, 0x6,0x43,0x25, 0x6,0x43,0x23, + 0x6,0x43,0x24, 0x5,0x34,0x5c, 0xf,0x37,0x58, 0xf,0x37,0x59, + 0xf,0x37,0x5a, 0xf,0x37,0x5b, 0x6,0x43,0x27, 0x6,0x43,0x2c, + 0xf,0x37,0x55, 0x5,0x3b,0x31, 0x5,0x3b,0x30, 0x5,0x3b,0x2e, + 0x5,0x3b,0x32, 0x6,0x4c,0x6d, 0x4,0x3a,0x23, 0x6,0x4c,0x66, + 0x6,0x4c,0x6c, 0x4,0x3a,0x22, 0x4,0x3a,0x24, 0x6,0x4c,0x6e, + 0x6,0x43,0x26, 0x6,0x4c,0x67, 0x6,0x4c,0x70, 0x6,0x4c,0x68, + 0x5,0x3b,0x2d, 0x6,0x4c,0x6a, 0x6,0x4c,0x69, 0x6,0x4c,0x6f, + 0x5,0x3b,0x2a, 0x5,0x3b,0x29, 0x5,0x3b,0x2b, 0xf,0x3e,0x25, + 0xf,0x3e,0x26, 0xf,0x3e,0x27, 0xf,0x3e,0x28, 0xf,0x3e,0x29, + 0xf,0x3e,0x2a, 0xf,0x3e,0x2b, 0xf,0x3e,0x2c, 0xf,0x3e,0x2d, + 0xf,0x3e,0x2e, 0x6,0x4c,0x6b, 0x5,0x3b,0x2f, 0x6,0x56,0x4b, + 0x6,0x56,0x42, 0x5,0x41,0x5f, 0x5,0x41,0x5e, 0x4,0x3f,0x6c, + 0x6,0x56,0x44, 0x4,0x3f,0x6d, 0x6,0x56,0x48, 0x6,0x56,0x45, + 0x4,0x3f,0x69, 0x5,0x41,0x61, 0x5,0x41,0x60, 0x6,0x56,0x43, + 0x6,0x56,0x49, 0x4,0x3a,0x25, 0x4,0x3f,0x6b, 0x6,0x56,0x46, + 0x5,0x41,0x62, 0x6,0x56,0x4c, 0x6,0x56,0x4d, 0x4,0x3f,0x72, + 0x6,0x56,0x4a, 0xf,0x44,0x57, 0xf,0x44,0x58, 0xf,0x44,0x59, + 0xf,0x44,0x5a, 0xf,0x44,0x5b, 0xf,0x44,0x5c, 0xf,0x44,0x5d, + 0xf,0x44,0x5e, 0xf,0x44,0x5f, 0xf,0x44,0x60, 0xf,0x44,0x61, + 0xf,0x44,0x62, 0x6,0x56,0x47, 0x4,0x3f,0x70, 0x4,0x45,0x78, + 0x5,0x48,0x50, 0x4,0x45,0x76, 0x5,0x48,0x52, 0x6,0x60,0x3f, + 0x6,0x60,0x3e, 0x5,0x48,0x56, 0x4,0x45,0x7a, 0x5,0x48,0x55, + 0x4,0x45,0x77, 0x6,0x60,0x39, 0x6,0x60,0x43, 0x6,0x60,0x42, + 0x6,0x60,0x36, 0x4,0x45,0x7d, 0x5,0x48,0x4f, 0x5,0x41,0x63, + 0x6,0x60,0x41, 0x5,0x48,0x51, 0x6,0x60,0x3c, 0x6,0x60,0x34, + 0x5,0x48,0x53, 0x5,0x48,0x57, 0x6,0x60,0x40, 0x6,0x60,0x3b, + 0x4,0x46,0x22, 0x6,0x60,0x38, 0xf,0x4b,0x2e, 0xf,0x4b,0x2f, + 0xf,0x4b,0x30, 0xf,0x4b,0x31, 0xf,0x4b,0x32, 0xf,0x4b,0x33, + 0xf,0x4b,0x34, 0xf,0x4b,0x35, 0xf,0x4b,0x36, 0xf,0x4b,0x37, + 0x6,0x60,0x35, 0x6,0x60,0x37, 0x6,0x60,0x3d, 0x4,0x4c,0x38, + 0x4,0x4c,0x43, 0x7,0x26,0x60, 0x4,0x4c,0x42, 0x4,0x4c,0x3b, + 0x5,0x4f,0x5b, 0x5,0x4f,0x59, 0x4,0x52,0x48, 0x5,0x4f,0x58, + 0x5,0x4f,0x5d, 0x5,0x4f,0x55, 0x4,0x4c,0x46, 0x5,0x4f,0x5a, + 0x7,0x26,0x6c, 0x7,0x26,0x5e, 0x7,0x26,0x64, 0x5,0x4f,0x5c, + 0x5,0x4f,0x52, 0x7,0x26,0x61, 0x7,0x26,0x66, 0x5,0x4f,0x57, + 0x4,0x4c,0x41, 0x4,0x4c,0x39, 0x7,0x26,0x5d, 0x7,0x26,0x65, + 0x7,0x26,0x5c, 0x7,0x26,0x67, 0x6,0x60,0x3a, 0x7,0x26,0x6d, + 0x7,0x26,0x6b, 0x5,0x4f,0x51, 0x5,0x4f,0x56, 0x5,0x4f,0x5e, + 0xf,0x51,0x30, 0xf,0x51,0x31, 0xf,0x51,0x32, 0xf,0x51,0x33, + 0xf,0x51,0x34, 0xf,0x51,0x35, 0xf,0x51,0x38, 0xf,0x51,0x39, + 0xf,0x51,0x3a, 0xf,0x51,0x3d, 0xf,0x51,0x3e, 0xf,0x51,0x3f, + 0x7,0x26,0x62, 0x7,0x26,0x68, 0x7,0x26,0x5f, 0x7,0x26,0x63, + 0x7,0x31,0x46, 0x4,0x52,0x46, 0x7,0x31,0x43, 0x7,0x31,0x44, + 0x4,0x52,0x4a, 0x7,0x31,0x40, 0x7,0x31,0x3d, 0x5,0x56,0x74, + 0x5,0x56,0x76, 0x7,0x31,0x31, 0x7,0x31,0x42, 0x7,0x31,0x32, + 0x7,0x3a,0x36, 0x7,0x31,0x33, 0x7,0x31,0x36, 0x5,0x56,0x75, + 0x5,0x56,0x77, 0x5,0x56,0x73, 0x5,0x5d,0x45, 0x4,0x52,0x45, + 0x5,0x56,0x71, 0x5,0x56,0x72, 0x4,0x52,0x4b, 0x7,0x31,0x3a, + 0x7,0x31,0x37, 0x7,0x31,0x38, 0x7,0x31,0x41, 0x4,0x52,0x4d, + 0x7,0x31,0x35, 0x5,0x56,0x79, 0x7,0x31,0x34, 0x7,0x31,0x45, + 0x7,0x31,0x3b, 0x5,0x56,0x78, 0x7,0x31,0x3f, 0x7,0x31,0x3e, + 0x7,0x31,0x39, 0x7,0x31,0x3c, 0xf,0x56,0x76, 0xf,0x56,0x77, + 0xf,0x56,0x78, 0xf,0x56,0x79, 0xf,0x56,0x7a, 0xf,0x56,0x7b, + 0xf,0x56,0x7c, 0xf,0x56,0x7d, 0xf,0x56,0x7e, 0x7,0x3a,0x44, + 0x7,0x3a,0x43, 0x5,0x5d,0x43, 0x5,0x5d,0x40, 0x4,0x57,0x71, + 0x7,0x3a,0x37, 0x5,0x5d,0x41, 0x7,0x3a,0x42, 0x4,0x57,0x6f, + 0x7,0x3a,0x3a, 0x5,0x5d,0x44, 0x5,0x5d,0x3e, 0x7,0x3a,0x3e, + 0x7,0x3a,0x3b, 0x7,0x3a,0x3c, 0x7,0x3a,0x40, 0x5,0x5d,0x42, + 0x7,0x3a,0x41, 0x7,0x3a,0x3d, 0x5,0x5d,0x47, 0xf,0x5b,0x73, + 0xf,0x5b,0x74, 0xf,0x5b,0x75, 0xf,0x5b,0x77, 0xf,0x5b,0x78, + 0xf,0x5b,0x79, 0xf,0x5b,0x7a, 0xf,0x5b,0x7b, 0xf,0x5b,0x7c, + 0xf,0x5b,0x7d, 0xf,0x5b,0x7e, 0xf,0x5c,0x21, 0xf,0x5c,0x22, + 0x7,0x3a,0x3f, 0x7,0x3a,0x38, 0x4,0x5c,0x64, 0x4,0x5c,0x5c, + 0x7,0x41,0x4e, 0x4,0x5c,0x63, 0x4,0x5c,0x5d, 0x7,0x41,0x4d, + 0x7,0x41,0x54, 0x4,0x5c,0x61, 0x4,0x57,0x70, 0x7,0x41,0x49, + 0x5,0x63,0x55, 0x5,0x63,0x58, 0x5,0x63,0x57, 0x7,0x41,0x4b, + 0x7,0x41,0x51, 0x5,0x63,0x56, 0x7,0x41,0x4a, 0x7,0x41,0x4f, + 0x7,0x41,0x52, 0x7,0x41,0x4c, 0x7,0x41,0x57, 0x7,0x41,0x55, + 0x7,0x41,0x50, 0x7,0x41,0x5b, 0x5,0x63,0x5a, 0x7,0x41,0x56, + 0xf,0x60,0x2a, 0xf,0x60,0x2b, 0xf,0x60,0x2c, 0xf,0x60,0x2d, + 0xf,0x60,0x2e, 0xf,0x60,0x2f, 0xf,0x60,0x30, 0xf,0x60,0x31, + 0xf,0x60,0x32, 0x5,0x63,0x59, 0x7,0x41,0x5c, 0x7,0x41,0x5a, + 0x7,0x41,0x58, 0x7,0x41,0x53, 0x4,0x60,0x64, 0x4,0x60,0x65, + 0x7,0x48,0x5f, 0x4,0x60,0x69, 0x7,0x48,0x67, 0x5,0x68,0x76, + 0x7,0x48,0x64, 0x4,0x60,0x67, 0x7,0x48,0x66, 0x4,0x60,0x6b, + 0x5,0x68,0x79, 0x4,0x60,0x60, 0x5,0x68,0x7a, 0x7,0x48,0x61, + 0x7,0x47,0x4b, 0x4,0x60,0x61, 0x7,0x48,0x5d, 0x5,0x68,0x77, + 0x7,0x48,0x63, 0x7,0x48,0x5b, 0x7,0x48,0x62, 0x5,0x68,0x78, + 0x7,0x48,0x59, 0x7,0x48,0x5a, 0x7,0x48,0x60, 0x7,0x48,0x5e, + 0xf,0x63,0x40, 0xf,0x63,0x41, 0xf,0x63,0x43, 0xf,0x63,0x44, + 0xf,0x63,0x45, 0x7,0x4a,0x73, 0x7,0x48,0x5c, 0x7,0x48,0x65, + 0x4,0x60,0x6a, 0x7,0x4e,0x7d, 0x7,0x4e,0x7c, 0x5,0x6d,0x23, + 0x5,0x6d,0x21, 0x4,0x64,0x25, 0x7,0x4e,0x7e, 0x7,0x4f,0x23, + 0x7,0x4e,0x7b, 0x7,0x54,0x42, 0x7,0x48,0x58, 0x5,0x6d,0x24, + 0x7,0x4f,0x24, 0x7,0x4f,0x26, 0x7,0x4e,0x7a, 0x4,0x66,0x79, + 0x7,0x4f,0x22, 0x7,0x4e,0x79, 0x7,0x4f,0x25, 0xf,0x65,0x6c, + 0xf,0x65,0x6d, 0xf,0x65,0x6e, 0xf,0x65,0x70, 0xf,0x65,0x71, + 0x7,0x4f,0x21, 0x5,0x70,0x72, 0x4,0x66,0x75, 0x7,0x54,0x43, + 0x5,0x70,0x73, 0x4,0x66,0x78, 0x4,0x66,0x76, 0x4,0x66,0x77, + 0x7,0x58,0x5e, 0x7,0x4f,0x27, 0x7,0x54,0x3f, 0x7,0x54,0x3e, + 0x7,0x54,0x41, 0xf,0x68,0x2c, 0xf,0x68,0x2d, 0xf,0x68,0x2e, + 0xf,0x68,0x2f, 0x4,0x66,0x74, 0x7,0x54,0x40, 0x5,0x70,0x71, + 0x7,0x54,0x44, 0x5,0x73,0x7b, 0x7,0x58,0x59, 0x5,0x73,0x7c, + 0x5,0x73,0x79, 0x4,0x69,0x29, 0x5,0x76,0x3a, 0x7,0x58,0x5d, + 0x5,0x73,0x7a, 0x7,0x58,0x5b, 0xf,0x69,0x63, 0xf,0x69,0x64, + 0xf,0x69,0x65, 0xf,0x69,0x66, 0x7,0x58,0x5a, 0x7,0x58,0x5c, + 0x4,0x69,0x4b, 0x4,0x6a,0x67, 0x7,0x58,0x5f, 0x7,0x5c,0x3a, + 0x7,0x5c,0x3b, 0x4,0x6a,0x68, 0x4,0x6a,0x69, 0x4,0x6b,0x7a, + 0x5,0x77,0x78, 0x7,0x5f,0x37, 0x7,0x5f,0x35, 0xf,0x6b,0x5d, + 0x7,0x5f,0x36, 0x7,0x5f,0x38, 0x5,0x79,0x3a, 0x7,0x5f,0x34, + 0x5,0x79,0x39, 0x7,0x61,0x34, 0x7,0x62,0x4f, 0x7,0x62,0x4e, + 0x7,0x63,0x63, 0xf,0x6c,0x69, 0x7,0x63,0x65, 0x7,0x63,0x64, + 0x7,0x64,0x55, 0x5,0x7b,0x65, 0xf,0x6d,0x30, 0x7,0x65,0x75, + 0x6,0x25,0x42, 0x4,0x2a,0x78, 0x5,0x2b,0x28, 0x4,0x2f,0x28, + 0x6,0x3a,0x66, 0x5,0x2f,0x5b, 0x5,0x34,0x61, 0x6,0x43,0x2d, + 0x5,0x3b,0x34, 0x6,0x43,0x2f, 0x6,0x43,0x2e, 0x6,0x4c,0x74, + 0x4,0x3a,0x29, 0x6,0x4c,0x73, 0x5,0x3b,0x33, 0xf,0x3e,0x2f, + 0x6,0x56,0x50, 0x6,0x56,0x4f, 0x4,0x3f,0x74, 0x4,0x46,0x24, + 0x6,0x60,0x45, 0x5,0x48,0x58, 0x6,0x60,0x44, 0x7,0x26,0x6e, + 0xf,0x4b,0x39, 0xf,0x4b,0x3a, 0xf,0x4b,0x3b, 0x7,0x26,0x70, + 0x4,0x4c,0x47, 0xf,0x51,0x40, 0xf,0x51,0x41, 0x7,0x26,0x6f, + 0x5,0x56,0x7b, 0x5,0x56,0x7a, 0xf,0x57,0x22, 0xf,0x57,0x21, + 0x5,0x5d,0x49, 0x7,0x3a,0x45, 0x5,0x5d,0x48, 0xf,0x5a,0x58, + 0xf,0x5c,0x23, 0xf,0x5c,0x24, 0x7,0x41,0x5d, 0x7,0x41,0x5e, + 0xf,0x60,0x33, 0x7,0x48,0x68, 0x4,0x60,0x6c, 0xf,0x63,0x46, + 0x5,0x70,0x74, 0x4,0x64,0x27, 0x4,0x66,0x7a, 0x7,0x54,0x45, + 0x4,0x6a,0x6a, 0x7,0x5c,0x3c, 0xf,0x6a,0x6b, 0x7,0x5f,0x3a, + 0x7,0x5f,0x39, 0x5,0x7a,0x34, 0x7,0x66,0x2a, 0x6,0x22,0x29, + 0x6,0x22,0x28, 0x4,0x24,0x6a, 0x6,0x25,0x44, 0x6,0x25,0x45, + 0x6,0x28,0x73, 0xf,0x21,0x7c, 0x6,0x25,0x43, 0xf,0x25,0x28, + 0xf,0x25,0x2a, 0x6,0x2d,0x53, 0x6,0x33,0x6a, 0x4,0x27,0x5d, + 0x6,0x33,0x69, 0x6,0x2d,0x54, 0x4,0x27,0x5e, 0x6,0x28,0x74, + 0x4,0x24,0x6b, 0x6,0x33,0x6b, 0x4,0x2a,0x7a, 0x4,0x2a,0x7c, + 0xf,0x25,0x56, 0x5,0x2b,0x29, 0xf,0x28,0x49, 0x5,0x27,0x52, + 0x6,0x3a,0x67, 0x6,0x3a,0x68, 0x6,0x3a,0x69, 0x5,0x2f,0x5f, + 0x6,0x3a,0x6c, 0x6,0x3a,0x6a, 0x4,0x2f,0x2c, 0x4,0x2f,0x2b, + 0x6,0x33,0x6e, 0x6,0x33,0x6c, 0x6,0x33,0x6f, 0x6,0x43,0x35, + 0xf,0x29,0x39, 0x5,0x2f,0x5d, 0x6,0x43,0x30, 0x6,0x43,0x31, + 0x6,0x43,0x32, 0x6,0x43,0x34, 0x6,0x43,0x36, 0xf,0x31,0x79, + 0x6,0x33,0x6d, 0x6,0x36,0x7a, 0x5,0x2b,0x2a, 0x4,0x2a,0x7d, + 0x6,0x43,0x33, 0x6,0x4c,0x77, 0x6,0x43,0x37, 0x6,0x3a,0x6d, + 0x6,0x4c,0x76, 0x6,0x43,0x38, 0x5,0x2f,0x5e, 0x5,0x34,0x62, + 0xf,0x37,0x5c, 0x6,0x4c,0x75, 0x5,0x3b,0x36, 0x5,0x3b,0x35, + 0x4,0x3a,0x2c, 0x6,0x4c,0x78, 0xf,0x3e,0x30, 0x6,0x56,0x52, + 0x5,0x41,0x67, 0x6,0x56,0x54, 0x6,0x4c,0x7a, 0x5,0x41,0x64, + 0x5,0x41,0x66, 0x6,0x56,0x53, 0x6,0x56,0x55, 0x6,0x4c,0x79, + 0x6,0x56,0x56, 0xf,0x3e,0x31, 0x6,0x56,0x51, 0xf,0x44,0x63, + 0x6,0x60,0x46, 0x6,0x60,0x48, 0x6,0x60,0x49, 0x6,0x60,0x4a, + 0x6,0x60,0x4b, 0x6,0x60,0x4c, 0x6,0x60,0x4d, 0x6,0x60,0x50, + 0x5,0x48,0x5b, 0x7,0x26,0x75, 0x6,0x60,0x4e, 0x5,0x48,0x5a, + 0x6,0x56,0x57, 0x5,0x48,0x59, 0x6,0x60,0x4f, 0x6,0x60,0x47, + 0xf,0x4b,0x3c, 0x7,0x26,0x71, 0x7,0x26,0x72, 0x7,0x26,0x73, + 0x7,0x26,0x74, 0x5,0x4f,0x62, 0x5,0x4f,0x5f, 0x6,0x60,0x52, + 0x7,0x26,0x76, 0x5,0x4f,0x60, 0x5,0x4f,0x61, 0x6,0x60,0x51, + 0xf,0x51,0x42, 0xf,0x51,0x43, 0x7,0x25,0x73, 0x7,0x31,0x47, + 0x7,0x31,0x48, 0x7,0x31,0x4c, 0x7,0x31,0x49, 0x5,0x56,0x7c, + 0x7,0x31,0x4b, 0x4,0x52,0x51, 0x7,0x3a,0x4e, 0x7,0x31,0x4a, + 0x7,0x31,0x4d, 0x5,0x4f,0x63, 0x5,0x56,0x7d, 0x4,0x52,0x50, + 0x7,0x26,0x77, 0x7,0x26,0x78, 0x7,0x3a,0x47, 0x7,0x3a,0x48, + 0x7,0x3a,0x4b, 0x5,0x5d,0x4a, 0x7,0x31,0x4e, 0x4,0x57,0x74, + 0x5,0x63,0x5b, 0x7,0x3a,0x4c, 0x7,0x3a,0x4d, 0xf,0x5c,0x25, + 0xf,0x57,0x23, 0x7,0x41,0x5f, 0x7,0x41,0x60, 0x7,0x41,0x62, + 0x7,0x41,0x64, 0x4,0x5c,0x67, 0x4,0x5c,0x66, 0x5,0x63,0x5c, + 0x7,0x41,0x63, 0x7,0x48,0x69, 0x7,0x3a,0x4a, 0x5,0x63,0x5e, + 0x5,0x68,0x7b, 0x7,0x48,0x6c, 0x4,0x60,0x6e, 0x7,0x48,0x6a, + 0x7,0x48,0x6b, 0x7,0x4f,0x28, 0x7,0x4f,0x29, 0x7,0x4f,0x2a, + 0x7,0x4f,0x2b, 0x5,0x6d,0x25, 0x5,0x6d,0x27, 0x7,0x4f,0x2c, + 0x5,0x6d,0x26, 0x5,0x6d,0x28, 0x7,0x54,0x46, 0x7,0x4f,0x2d, + 0x5,0x77,0x7a, 0x4,0x6b,0x7c, 0x7,0x5f,0x3b, 0x5,0x77,0x7b, + 0x5,0x77,0x79, 0x7,0x61,0x35, 0x7,0x62,0x50, 0x7,0x63,0x66, + 0x7,0x64,0x56, 0x7,0x65,0x3c, 0x4,0x24,0x6c, 0x4,0x23,0x2c, + 0xf,0x21,0x60, 0x6,0x2d,0x56, 0x5,0x27,0x53, 0x6,0x2d,0x55, + 0xf,0x2d,0x24, 0x6,0x33,0x71, 0x6,0x33,0x70, 0x4,0x2a,0x7e, + 0xf,0x28,0x4b, 0x6,0x3a,0x6e, 0x6,0x3a,0x6f, 0x6,0x43,0x3b, + 0x6,0x3a,0x73, 0x6,0x3a,0x72, 0x6,0x3a,0x71, 0x6,0x3a,0x70, + 0x6,0x43,0x3a, 0xf,0x31,0x7a, 0xf,0x31,0x7b, 0x6,0x43,0x3d, + 0x5,0x34,0x64, 0x4,0x3a,0x2e, 0x6,0x43,0x3e, 0x4,0x34,0x39, + 0x5,0x34,0x65, 0xf,0x37,0x5d, 0x5,0x34,0x63, 0x6,0x43,0x39, + 0xf,0x37,0x5e, 0xf,0x37,0x5f, 0x6,0x43,0x3f, 0x5,0x3b,0x39, + 0x5,0x3b,0x37, 0x6,0x4c,0x7d, 0x4,0x3a,0x2f, 0x6,0x4d,0x21, + 0x5,0x3b,0x38, 0x6,0x4c,0x7e, 0x6,0x4c,0x7c, 0x6,0x4d,0x22, + 0x6,0x47,0x21, 0x6,0x56,0x5a, 0x5,0x41,0x68, 0x6,0x56,0x5b, + 0x6,0x56,0x58, 0x5,0x41,0x69, 0x6,0x56,0x59, 0x6,0x56,0x5c, + 0x5,0x41,0x6a, 0xf,0x3e,0x33, 0xf,0x3e,0x34, 0x5,0x48,0x5c, + 0x6,0x60,0x53, 0x6,0x60,0x55, 0x5,0x48,0x5d, 0x6,0x60,0x54, + 0x5,0x4f,0x64, 0x4,0x4c,0x4a, 0x7,0x26,0x7b, 0x7,0x26,0x7c, + 0x4,0x4c,0x4b, 0x7,0x31,0x4f, 0x7,0x26,0x7a, 0x4,0x4c,0x48, + 0x5,0x57,0x21, 0x5,0x56,0x7e, 0x4,0x52,0x52, 0xf,0x57,0x25, + 0x7,0x31,0x50, 0x4,0x57,0x78, 0x4,0x57,0x76, 0x5,0x5d,0x4b, + 0x7,0x3a,0x50, 0x7,0x3a,0x4f, 0x7,0x3a,0x52, 0xf,0x5c,0x26, + 0x4,0x52,0x54, 0x7,0x3a,0x51, 0x5,0x63,0x5d, 0x4,0x5c,0x69, + 0x5,0x63,0x5f, 0x7,0x41,0x69, 0x7,0x41,0x6a, 0x4,0x5c,0x6d, + 0x7,0x41,0x67, 0x7,0x41,0x68, 0x7,0x41,0x66, 0xf,0x57,0x24, + 0xf,0x60,0x34, 0xf,0x60,0x35, 0x4,0x5c,0x6c, 0x5,0x68,0x7c, + 0x7,0x48,0x70, 0x5,0x76,0x3b, 0x7,0x48,0x6f, 0x7,0x4f,0x2e, + 0x7,0x48,0x6e, 0x5,0x6d,0x29, 0x7,0x4f,0x2f, 0x7,0x4f,0x30, + 0x7,0x4f,0x31, 0x7,0x4f,0x32, 0x7,0x41,0x65, 0x5,0x70,0x75, + 0x7,0x54,0x47, 0x7,0x54,0x48, 0x5,0x73,0x7d, 0x7,0x58,0x60, + 0x7,0x5c,0x3e, 0x7,0x5c,0x3d, 0x7,0x61,0x36, 0x7,0x63,0x67, + 0x7,0x65,0x5e, 0x6,0x2d,0x57, 0x6,0x33,0x75, 0x6,0x33,0x72, + 0x6,0x33,0x76, 0x5,0x2b,0x2b, 0x4,0x2b,0x22, 0x4,0x2b,0x21, + 0x4,0x2b,0x24, 0x6,0x33,0x74, 0x4,0x2b,0x23, 0xf,0x2d,0x25, + 0xf,0x2d,0x26, 0x6,0x33,0x73, 0x4,0x2f,0x33, 0x6,0x3a,0x76, + 0x5,0x2f,0x61, 0x5,0x2f,0x63, 0x5,0x2f,0x60, 0x4,0x2f,0x31, + 0x4,0x2f,0x36, 0x4,0x2f,0x35, 0x6,0x3a,0x75, 0x5,0x2f,0x62, + 0x4,0x2f,0x34, 0x4,0x2f,0x32, 0x6,0x3a,0x77, 0xf,0x2f,0x63, + 0xf,0x2f,0x64, 0x4,0x2f,0x37, 0xf,0x31,0x7c, 0x5,0x34,0x66, + 0x6,0x43,0x41, 0x6,0x43,0x40, 0x6,0x43,0x42, 0x6,0x43,0x43, + 0x6,0x43,0x44, 0x6,0x43,0x46, 0x6,0x43,0x47, 0x4,0x34,0x3f, + 0x6,0x43,0x45, 0x5,0x3b,0x3b, 0x4,0x3a,0x32, 0x6,0x4d,0x26, + 0x6,0x4d,0x27, 0x6,0x4d,0x2d, 0x5,0x3b,0x3d, 0x4,0x3a,0x36, + 0x6,0x4d,0x2e, 0x6,0x4d,0x28, 0x6,0x4d,0x25, 0x6,0x4d,0x2f, + 0x6,0x4d,0x30, 0x5,0x3b,0x3c, 0x6,0x4d,0x2a, 0x6,0x4d,0x2c, + 0x6,0x4d,0x2b, 0xf,0x3e,0x35, 0xf,0x3e,0x36, 0x6,0x4d,0x29, + 0x5,0x41,0x6e, 0x5,0x41,0x6b, 0x4,0x3f,0x79, 0x6,0x56,0x5d, + 0x6,0x56,0x5e, 0x6,0x56,0x5f, 0x5,0x41,0x6d, 0x5,0x41,0x6c, + 0xf,0x44,0x64, 0x6,0x4d,0x24, 0x5,0x48,0x65, 0x5,0x48,0x5e, + 0x6,0x60,0x57, 0x5,0x48,0x5f, 0x5,0x48,0x63, 0x5,0x48,0x60, + 0x5,0x48,0x64, 0x5,0x48,0x61, 0x5,0x48,0x62, 0x6,0x60,0x56, + 0x5,0x48,0x66, 0xf,0x4b,0x3d, 0xf,0x4b,0x3e, 0xf,0x4b,0x3f, + 0xf,0x4b,0x40, 0x5,0x4f,0x6a, 0x5,0x4f,0x6b, 0x7,0x26,0x7e, + 0x5,0x4f,0x68, 0x4,0x4c,0x4c, 0x5,0x4f,0x6c, 0x5,0x4f,0x65, + 0x7,0x26,0x7d, 0x5,0x4f,0x67, 0xf,0x51,0x46, 0x6,0x60,0x59, + 0x5,0x4f,0x66, 0x7,0x27,0x24, 0x7,0x27,0x25, 0x7,0x27,0x21, + 0x4,0x4c,0x4e, 0x7,0x27,0x22, 0x4,0x4c,0x4d, 0x7,0x27,0x23, + 0xf,0x51,0x44, 0xf,0x51,0x45, 0x7,0x31,0x51, 0x7,0x31,0x53, + 0x5,0x57,0x25, 0x7,0x31,0x56, 0x7,0x31,0x52, 0x7,0x31,0x54, + 0x4,0x52,0x57, 0x5,0x57,0x23, 0x5,0x57,0x26, 0x5,0x57,0x24, + 0x5,0x4f,0x69, 0x5,0x57,0x22, 0x7,0x31,0x55, 0x5,0x57,0x27, + 0xf,0x57,0x26, 0x4,0x57,0x79, 0x7,0x3a,0x54, 0x5,0x5d,0x4c, + 0x7,0x3a,0x55, 0x7,0x48,0x71, 0x5,0x5d,0x4d, 0x7,0x3a,0x53, + 0xf,0x5c,0x27, 0xf,0x5c,0x28, 0x5,0x63,0x60, 0x4,0x5c,0x6e, + 0x7,0x41,0x71, 0x5,0x5d,0x4e, 0x4,0x5c,0x6f, 0x7,0x41,0x6d, + 0x7,0x41,0x6f, 0x7,0x41,0x6c, 0x7,0x41,0x70, 0x7,0x41,0x6e, + 0xf,0x60,0x36, 0xf,0x60,0x37, 0x7,0x41,0x6b, 0x4,0x60,0x70, + 0x5,0x68,0x7e, 0x5,0x68,0x7d, 0x7,0x48,0x72, 0x7,0x4f,0x35, + 0x7,0x4f,0x36, 0xf,0x65,0x72, 0x7,0x4f,0x33, 0x4,0x66,0x7c, + 0x7,0x54,0x49, 0x7,0x54,0x4b, 0x7,0x4f,0x34, 0x7,0x54,0x4a, + 0x7,0x58,0x62, 0x7,0x58,0x63, 0x7,0x58,0x61, 0x6,0x25,0x46, + 0x6,0x2d,0x58, 0x6,0x28,0x75, 0x4,0x27,0x5f, 0x4,0x27,0x60, + 0x6,0x3a,0x78, 0x4,0x34,0x40, 0x5,0x2b,0x2c, 0xf,0x37,0x60, + 0xf,0x37,0x61, 0x6,0x43,0x48, 0x6,0x4d,0x31, 0x7,0x27,0x26, + 0x7,0x31,0x58, 0x7,0x31,0x57, 0xf,0x6b,0x5e, 0x6,0x2d,0x59, + 0x6,0x2d,0x5a, 0x5,0x21,0x79, 0xf,0x28,0x4c, 0x4,0x2f,0x39, + 0x5,0x34,0x67, 0x5,0x3b,0x3e, 0x5,0x41,0x6f, 0x6,0x60,0x5a, + 0x7,0x27,0x27, 0x7,0x27,0x29, 0x5,0x48,0x67, 0x7,0x31,0x5a, + 0x7,0x31,0x59, 0x7,0x3a,0x56, 0x5,0x23,0x21, 0x6,0x2d,0x5b, + 0xf,0x28,0x4d, 0x6,0x33,0x77, 0xf,0x2d,0x27, 0x6,0x33,0x78, + 0xf,0x31,0x7e, 0x5,0x34,0x68, 0xf,0x37,0x62, 0x6,0x43,0x49, + 0x4,0x3a,0x37, 0x5,0x3b,0x41, 0x5,0x3b,0x40, 0x4,0x3f,0x7b, + 0x6,0x56,0x60, 0x6,0x60,0x5c, 0x5,0x48,0x6c, 0x5,0x48,0x68, + 0x5,0x48,0x6d, 0x5,0x48,0x6a, 0x5,0x48,0x69, 0x5,0x48,0x6b, + 0x4,0x46,0x31, 0xf,0x44,0x65, 0x6,0x60,0x5b, 0x5,0x4f,0x6f, + 0x5,0x4f,0x70, 0x5,0x4f,0x71, 0x5,0x4f,0x6d, 0x5,0x4f,0x6e, + 0x7,0x27,0x2a, 0x5,0x57,0x29, 0x5,0x57,0x28, 0x4,0x52,0x58, + 0x4,0x52,0x59, 0x7,0x31,0x5c, 0x7,0x31,0x5d, 0x7,0x31,0x5b, + 0xf,0x51,0x47, 0x5,0x5d,0x4f, 0x4,0x57,0x7c, 0x7,0x3a,0x5a, + 0x7,0x3a,0x57, 0x7,0x3a,0x58, 0xf,0x57,0x29, 0x5,0x63,0x61, + 0x4,0x57,0x7e, 0x7,0x41,0x72, 0x7,0x3a,0x59, 0x7,0x48,0x75, + 0x5,0x63,0x62, 0x7,0x41,0x74, 0x7,0x41,0x73, 0xf,0x5c,0x29, + 0xf,0x5c,0x2a, 0x7,0x48,0x74, 0x5,0x69,0x21, 0x7,0x48,0x73, + 0x4,0x66,0x7e, 0x7,0x54,0x4c, 0x4,0x6a,0x6c, 0x5,0x77,0x7c, + 0x5,0x79,0x3b, 0x5,0x27,0x55, 0x5,0x27,0x54, 0x6,0x2d,0x5e, + 0xf,0x28,0x4e, 0xf,0x28,0x4f, 0x6,0x2d,0x5d, 0x5,0x2b,0x2f, + 0x5,0x2b,0x2d, 0x5,0x2b,0x2e, 0x4,0x2f,0x3c, 0x6,0x3a,0x7e, + 0x4,0x2f,0x3b, 0x6,0x3a,0x7a, 0x5,0x2f,0x64, 0x6,0x3b,0x22, + 0xf,0x32,0x21, 0xf,0x32,0x24, 0xf,0x32,0x26, 0xf,0x32,0x27, + 0x6,0x3a,0x7b, 0xf,0x32,0x22, 0x6,0x3a,0x7d, 0x6,0x3a,0x7c, + 0x6,0x3b,0x23, 0x6,0x3a,0x79, 0xf,0x32,0x25, 0x5,0x2f,0x65, + 0x6,0x43,0x4b, 0x4,0x34,0x43, 0x4,0x34,0x42, 0x4,0x34,0x44, + 0x6,0x43,0x4d, 0x5,0x34,0x69, 0x6,0x43,0x4f, 0x6,0x43,0x4e, + 0x6,0x43,0x4c, 0x6,0x43,0x4a, 0xf,0x37,0x63, 0xf,0x37,0x64, + 0xf,0x37,0x65, 0xf,0x37,0x66, 0x5,0x3b,0x42, 0x6,0x4d,0x33, + 0x6,0x4d,0x34, 0x5,0x3b,0x43, 0x6,0x4d,0x35, 0xf,0x3e,0x37, + 0xf,0x3e,0x38, 0xf,0x3e,0x39, 0xf,0x3e,0x3a, 0xf,0x3e,0x3c, + 0xf,0x3e,0x3d, 0xf,0x3e,0x3e, 0xf,0x3e,0x3f, 0xf,0x3e,0x40, + 0x6,0x4d,0x32, 0xf,0x3e,0x3b, 0x6,0x56,0x62, 0x6,0x56,0x66, + 0x5,0x41,0x71, 0x5,0x41,0x72, 0x6,0x56,0x61, 0x6,0x56,0x6b, + 0x6,0x56,0x69, 0x6,0x56,0x67, 0x5,0x41,0x73, 0x6,0x56,0x68, + 0x6,0x56,0x64, 0x6,0x56,0x6a, 0x6,0x56,0x63, 0xf,0x44,0x66, + 0xf,0x44,0x67, 0x6,0x56,0x65, 0x5,0x48,0x70, 0x5,0x48,0x71, + 0x5,0x48,0x6e, 0x4,0x4c,0x50, 0x6,0x60,0x5e, 0x5,0x48,0x72, + 0x5,0x48,0x6f, 0x5,0x48,0x73, 0xf,0x4b,0x41, 0xf,0x4b,0x42, + 0xf,0x4b,0x43, 0xf,0x4b,0x44, 0xf,0x4b,0x45, 0xf,0x4b,0x46, + 0xf,0x4b,0x47, 0xf,0x4b,0x48, 0xf,0x4b,0x4a, 0xf,0x4b,0x4b, + 0xf,0x4b,0x4c, 0x6,0x60,0x5f, 0x5,0x4f,0x72, 0x7,0x27,0x2c, + 0x5,0x4f,0x75, 0x7,0x27,0x2f, 0x5,0x4f,0x74, 0x5,0x4f,0x73, + 0x4,0x4c,0x51, 0x5,0x4f,0x77, 0x7,0x27,0x2b, 0x7,0x27,0x30, + 0x5,0x4f,0x76, 0xf,0x51,0x48, 0xf,0x51,0x49, 0xf,0x51,0x4a, + 0xf,0x51,0x4b, 0xf,0x51,0x4c, 0xf,0x51,0x4d, 0xf,0x51,0x4e, + 0xf,0x51,0x4f, 0x7,0x27,0x2d, 0x5,0x57,0x2c, 0x5,0x57,0x2f, + 0x5,0x57,0x2b, 0x5,0x57,0x2d, 0x5,0x57,0x2e, 0x7,0x31,0x61, + 0x7,0x31,0x5f, 0x7,0x31,0x5e, 0xf,0x57,0x2a, 0xf,0x57,0x2b, + 0xf,0x57,0x2c, 0xf,0x57,0x2d, 0xf,0x57,0x2e, 0xf,0x57,0x2f, + 0x7,0x31,0x60, 0x5,0x57,0x2a, 0x5,0x5d,0x50, 0x5,0x5d,0x51, + 0x5,0x5d,0x52, 0x7,0x3a,0x5b, 0x4,0x58,0x25, 0x4,0x58,0x26, + 0x5,0x5d,0x54, 0x5,0x5d,0x53, 0xf,0x5c,0x2c, 0x7,0x3a,0x5d, + 0x7,0x3a,0x5c, 0x3,0x58,0x63, 0x7,0x41,0x77, 0x5,0x63,0x66, + 0x5,0x63,0x63, 0x4,0x5c,0x72, 0x7,0x41,0x79, 0x5,0x5d,0x55, + 0x7,0x41,0x78, 0x5,0x63,0x64, 0x5,0x63,0x65, 0x7,0x41,0x75, + 0xf,0x60,0x38, 0xf,0x60,0x39, 0xf,0x60,0x3a, 0x7,0x41,0x76, + 0xf,0x5c,0x2b, 0xf,0x63,0x47, 0x7,0x48,0x76, 0x5,0x69,0x22, + 0x5,0x69,0x23, 0x7,0x48,0x78, 0x7,0x48,0x77, 0xf,0x63,0x48, + 0xf,0x63,0x49, 0x7,0x4f,0x39, 0xf,0x65,0x73, 0xf,0x65,0x74, + 0xf,0x65,0x75, 0x7,0x4f,0x38, 0x7,0x4f,0x37, 0x5,0x70,0x76, + 0xf,0x68,0x30, 0xf,0x68,0x31, 0x7,0x54,0x4d, 0x7,0x54,0x4e, + 0x5,0x73,0x7e, 0x7,0x58,0x64, 0x4,0x6a,0x6d, 0xf,0x6a,0x6c, + 0xf,0x6b,0x5f, 0xf,0x6c,0x36, 0xf,0x6c,0x50, 0x5,0x21,0x7a, + 0x6,0x2d,0x5f, 0x5,0x2b,0x30, 0x6,0x43,0x50, 0x6,0x4d,0x36, + 0x6,0x48,0x6a, 0x6,0x56,0x6e, 0x6,0x60,0x62, 0x6,0x60,0x61, + 0x7,0x27,0x31, 0xf,0x51,0x50, 0x7,0x31,0x62, 0x7,0x4f,0x3a, + 0x5,0x23,0x25, 0x5,0x23,0x23, 0x6,0x2d,0x60, 0x6,0x2d,0x61, + 0x6,0x25,0x48, 0xf,0x22,0x6c, 0xf,0x22,0x6d, 0x5,0x23,0x24, + 0x5,0x23,0x22, 0x5,0x24,0x73, 0x5,0x24,0x72, 0x6,0x28,0x79, + 0x6,0x28,0x78, 0x6,0x28,0x77, 0x6,0x28,0x76, 0x6,0x33,0x7b, + 0x6,0x33,0x7a, 0x6,0x33,0x79, 0x5,0x27,0x5a, 0x5,0x27,0x5e, + 0x6,0x2d,0x64, 0x4,0x2f,0x43, 0x6,0x2d,0x6d, 0x6,0x2d,0x6e, + 0x6,0x2d,0x62, 0x5,0x27,0x5d, 0x6,0x2d,0x66, 0x5,0x27,0x59, + 0x5,0x27,0x57, 0x6,0x2d,0x6b, 0x5,0x27,0x5b, 0x4,0x27,0x6b, + 0x6,0x2d,0x68, 0x6,0x2d,0x6f, 0xf,0x28,0x50, 0xf,0x28,0x51, + 0xf,0x28,0x53, 0xf,0x28,0x54, 0x6,0x2d,0x6c, 0x4,0x26,0x64, + 0x6,0x2d,0x65, 0x6,0x2d,0x67, 0x5,0x27,0x5c, 0x6,0x2d,0x6a, + 0x6,0x2d,0x63, 0x6,0x3b,0x27, 0x6,0x3b,0x25, 0x4,0x2f,0x3d, + 0x5,0x27,0x56, 0x6,0x3b,0x26, 0x6,0x34,0x2d, 0x4,0x2b,0x2d, + 0x5,0x2b,0x34, 0x6,0x34,0x28, 0x5,0x2b,0x31, 0x5,0x2b,0x38, + 0x6,0x34,0x29, 0x4,0x2b,0x2e, 0x6,0x43,0x54, 0x6,0x34,0x27, + 0x4,0x2b,0x2b, 0x6,0x34,0x2b, 0x4,0x2b,0x30, 0x6,0x34,0x25, + 0x5,0x2b,0x36, 0x6,0x34,0x26, 0x5,0x2b,0x37, 0x5,0x2b,0x32, + 0x4,0x2f,0x48, 0x5,0x2b,0x35, 0x6,0x33,0x7c, 0x6,0x34,0x21, + 0x6,0x34,0x22, 0x6,0x34,0x24, 0xf,0x2d,0x2a, 0xf,0x2d,0x2f, + 0xf,0x37,0x67, 0xf,0x37,0x68, 0x6,0x33,0x7e, 0x6,0x34,0x2f, + 0x6,0x34,0x2c, 0x6,0x34,0x2a, 0x6,0x34,0x30, 0x6,0x34,0x2e, + 0x6,0x43,0x53, 0x6,0x43,0x52, 0xf,0x2d,0x2b, 0x6,0x43,0x55, + 0x6,0x43,0x56, 0x6,0x3b,0x30, 0x6,0x43,0x51, 0xf,0x2d,0x2d, + 0x5,0x2f,0x67, 0x4,0x2f,0x3e, 0x4,0x34,0x45, 0x4,0x2f,0x45, + 0x6,0x3b,0x32, 0x5,0x2f,0x6c, 0x4,0x2f,0x44, 0x6,0x3b,0x2e, + 0x5,0x2f,0x6e, 0x6,0x3b,0x2a, 0x5,0x2f,0x70, 0x5,0x3b,0x44, + 0x5,0x2f,0x6f, 0x6,0x3b,0x29, 0x5,0x2f,0x66, 0x6,0x3b,0x2b, + 0x4,0x2f,0x40, 0x6,0x4d,0x3b, 0x5,0x2f,0x69, 0xf,0x2d,0x29, + 0xf,0x32,0x28, 0xf,0x32,0x29, 0xf,0x32,0x2d, 0xf,0x3e,0x4c, + 0x5,0x2f,0x68, 0x5,0x2e,0x24, 0x6,0x3b,0x2f, 0x6,0x3b,0x2d, + 0x6,0x3b,0x2c, 0x6,0x3b,0x33, 0x6,0x4d,0x3a, 0x6,0x4d,0x38, + 0x6,0x4d,0x39, 0x6,0x4d,0x37, 0x6,0x34,0x23, 0x5,0x2f,0x6b, + 0x5,0x2f,0x71, 0x5,0x2f,0x6a, 0x5,0x34,0x74, 0x6,0x43,0x5b, + 0x6,0x43,0x59, 0x5,0x34,0x6b, 0x4,0x34,0x4e, 0x5,0x34,0x6c, + 0x4,0x2f,0x42, 0x5,0x34,0x71, 0x4,0x34,0x46, 0x4,0x34,0x55, + 0x5,0x41,0x74, 0x4,0x34,0x54, 0x6,0x43,0x57, 0x5,0x34,0x6e, + 0x6,0x43,0x5f, 0x4,0x34,0x49, 0x5,0x34,0x75, 0x5,0x34,0x76, + 0x6,0x43,0x60, 0x6,0x43,0x5e, 0x4,0x34,0x4f, 0x5,0x34,0x72, + 0x6,0x43,0x61, 0x6,0x43,0x62, 0xf,0x37,0x69, 0xf,0x37,0x6b, + 0x6,0x43,0x5c, 0x6,0x43,0x5d, 0x6,0x56,0x6f, 0x6,0x56,0x70, + 0x6,0x56,0x71, 0x5,0x34,0x73, 0x5,0x34,0x6f, 0x5,0x34,0x70, + 0x6,0x4d,0x43, 0x5,0x3b,0x48, 0x6,0x4d,0x3d, 0x5,0x3b,0x45, + 0x6,0x4d,0x4b, 0x6,0x4d,0x42, 0x4,0x3a,0x3c, 0x5,0x3b,0x4a, + 0x6,0x4d,0x4f, 0x6,0x4d,0x3c, 0x6,0x60,0x65, 0x5,0x3b,0x47, + 0x6,0x4d,0x50, 0x6,0x56,0x75, 0x4,0x3a,0x48, 0x5,0x3b,0x4c, + 0x6,0x4d,0x55, 0x6,0x4d,0x4e, 0x6,0x4d,0x4c, 0x6,0x4d,0x53, + 0x5,0x3b,0x46, 0x5,0x48,0x75, 0x6,0x4d,0x3e, 0x6,0x4d,0x47, + 0x6,0x4d,0x4a, 0xf,0x3e,0x41, 0xf,0x3e,0x44, 0xf,0x3e,0x46, + 0xf,0x3e,0x47, 0xf,0x3e,0x48, 0xf,0x3e,0x49, 0xf,0x3e,0x4a, + 0xf,0x3e,0x4b, 0x6,0x4d,0x44, 0x6,0x4d,0x49, 0xf,0x3b,0x63, + 0x6,0x4d,0x4d, 0x6,0x4d,0x41, 0x6,0x4d,0x52, 0x6,0x4d,0x3f, + 0x6,0x4d,0x40, 0x6,0x60,0x63, 0x6,0x60,0x67, 0x6,0x60,0x64, + 0xf,0x3e,0x45, 0x5,0x3b,0x49, 0x6,0x4d,0x46, 0x5,0x34,0x6d, + 0x5,0x3b,0x4b, 0x5,0x3b,0x4e, 0x5,0x3b,0x4f, 0x6,0x4d,0x51, + 0x5,0x3b,0x51, 0x6,0x4d,0x45, 0x6,0x60,0x68, 0x6,0x60,0x66, + 0x5,0x41,0x7d, 0x4,0x40,0x21, 0x5,0x42,0x26, 0x5,0x42,0x21, + 0x5,0x41,0x75, 0x5,0x41,0x79, 0x5,0x42,0x27, 0x6,0x56,0x7d, + 0x4,0x3f,0x7e, 0x6,0x56,0x72, 0x4,0x3a,0x46, 0x5,0x42,0x22, + 0x5,0x41,0x78, 0x6,0x56,0x77, 0x4,0x40,0x24, 0x6,0x56,0x79, + 0x4,0x40,0x22, 0x6,0x57,0x21, 0x6,0x56,0x73, 0x5,0x42,0x29, + 0x6,0x56,0x74, 0x6,0x56,0x78, 0x5,0x42,0x23, 0x6,0x56,0x7c, + 0x5,0x41,0x7b, 0x5,0x41,0x7a, 0x5,0x42,0x25, 0x5,0x42,0x24, + 0x6,0x56,0x7a, 0x5,0x41,0x76, 0x6,0x56,0x7e, 0xf,0x44,0x69, + 0xf,0x44,0x6a, 0xf,0x44,0x6b, 0xf,0x44,0x6c, 0xf,0x44,0x6d, + 0xf,0x44,0x6f, 0xf,0x44,0x71, 0x4,0x40,0x2b, 0x6,0x57,0x23, + 0x6,0x57,0x22, 0xf,0x44,0x70, 0x7,0x27,0x32, 0x7,0x27,0x33, + 0x6,0x56,0x7b, 0x5,0x41,0x7e, 0x5,0x41,0x7c, 0x4,0x46,0x44, + 0x5,0x48,0x7b, 0x4,0x46,0x4c, 0x4,0x46,0x43, 0x5,0x49,0x23, + 0x6,0x60,0x6a, 0x5,0x48,0x7a, 0x4,0x46,0x4a, 0x5,0x49,0x24, + 0x5,0x49,0x21, 0x4,0x46,0x49, 0x5,0x48,0x77, 0x5,0x48,0x7d, + 0x4,0x46,0x3a, 0x4,0x46,0x4b, 0x5,0x48,0x78, 0x6,0x60,0x71, + 0x6,0x60,0x6c, 0x5,0x48,0x76, 0x6,0x60,0x6e, 0x5,0x48,0x79, + 0x6,0x60,0x6d, 0x5,0x48,0x7c, 0x7,0x31,0x63, 0x5,0x49,0x22, + 0x4,0x46,0x48, 0x6,0x60,0x6b, 0xf,0x4b,0x4d, 0xf,0x4b,0x4e, + 0xf,0x4b,0x4f, 0xf,0x4b,0x51, 0xf,0x4b,0x52, 0xf,0x4b,0x55, + 0xf,0x4b,0x53, 0x6,0x60,0x70, 0x6,0x5d,0x5c, 0x5,0x41,0x77, + 0x5,0x48,0x7e, 0x4,0x4c,0x53, 0x5,0x4f,0x7b, 0x7,0x27,0x34, + 0x4,0x4c,0x57, 0x7,0x27,0x3b, 0x5,0x4f,0x7a, 0x4,0x4c,0x59, + 0x7,0x3a,0x60, 0x7,0x27,0x37, 0x5,0x4f,0x7c, 0x7,0x27,0x35, + 0x4,0x4c,0x5a, 0x7,0x3a,0x5e, 0x5,0x4f,0x78, 0x7,0x27,0x38, + 0xf,0x51,0x51, 0xf,0x51,0x52, 0xf,0x51,0x53, 0xf,0x51,0x54, + 0x7,0x27,0x36, 0x7,0x27,0x39, 0x7,0x27,0x3a, 0x7,0x3a,0x5f, + 0x6,0x60,0x69, 0x5,0x4f,0x79, 0xf,0x5c,0x35, 0x7,0x31,0x6c, + 0x5,0x57,0x37, 0x5,0x57,0x32, 0x4,0x52,0x68, 0x4,0x52,0x5d, + 0x5,0x57,0x31, 0x4,0x52,0x5f, 0x7,0x31,0x67, 0x7,0x31,0x6e, + 0x5,0x57,0x35, 0x5,0x57,0x36, 0x4,0x52,0x65, 0x5,0x4f,0x7d, + 0x5,0x57,0x34, 0x7,0x31,0x65, 0x7,0x31,0x6d, 0x5,0x57,0x39, + 0x7,0x31,0x6a, 0x5,0x69,0x24, 0x4,0x52,0x60, 0x7,0x31,0x6f, + 0xf,0x57,0x31, 0xf,0x57,0x33, 0xf,0x57,0x32, 0x7,0x27,0x3c, + 0x7,0x31,0x68, 0x7,0x31,0x69, 0x7,0x31,0x64, 0x7,0x31,0x66, + 0x7,0x31,0x6b, 0x7,0x41,0x7a, 0x7,0x48,0x79, 0x7,0x41,0x7b, + 0x5,0x57,0x3a, 0x5,0x57,0x30, 0x5,0x57,0x3b, 0x5,0x57,0x38, + 0x5,0x57,0x33, 0x7,0x42,0x21, 0x5,0x5d,0x5a, 0x5,0x5d,0x59, + 0x7,0x3a,0x62, 0x4,0x58,0x2e, 0x4,0x58,0x2a, 0x4,0x58,0x29, + 0x5,0x5d,0x58, 0x5,0x5d,0x56, 0x4,0x60,0x71, 0x7,0x48,0x7b, + 0x5,0x5d,0x5e, 0x7,0x3a,0x65, 0xf,0x5c,0x2e, 0xf,0x5c,0x2f, + 0xf,0x5c,0x31, 0xf,0x5c,0x32, 0xf,0x5c,0x33, 0xf,0x5c,0x34, + 0xf,0x5c,0x36, 0xf,0x5c,0x30, 0x7,0x37,0x7e, 0x7,0x3a,0x63, + 0x7,0x48,0x7a, 0x7,0x48,0x7d, 0x5,0x5d,0x5d, 0x7,0x3a,0x61, + 0x5,0x5d,0x5c, 0x5,0x5d,0x57, 0x7,0x3a,0x64, 0x7,0x48,0x7e, + 0x4,0x5c,0x75, 0x5,0x63,0x6a, 0x5,0x63,0x67, 0x5,0x63,0x69, + 0x5,0x63,0x6c, 0x7,0x41,0x7c, 0x5,0x63,0x6e, 0x7,0x41,0x7e, + 0x5,0x63,0x6b, 0x7,0x42,0x23, 0x5,0x63,0x68, 0x5,0x6d,0x2a, + 0x5,0x63,0x6f, 0xf,0x60,0x3b, 0xf,0x60,0x3c, 0xf,0x60,0x3d, + 0xf,0x60,0x40, 0xf,0x60,0x41, 0x7,0x41,0x7d, 0x7,0x42,0x6d, + 0x4,0x5c,0x73, 0x4,0x60,0x72, 0x7,0x49,0x23, 0x7,0x49,0x29, + 0x5,0x69,0x25, 0x5,0x69,0x26, 0x5,0x63,0x6d, 0x7,0x49,0x24, + 0xf,0x63,0x4a, 0x7,0x49,0x28, 0x7,0x49,0x2a, 0xf,0x63,0x4c, + 0xf,0x63,0x4d, 0x7,0x49,0x22, 0x7,0x49,0x26, 0x7,0x49,0x25, + 0x7,0x49,0x27, 0x7,0x49,0x21, 0xf,0x63,0x4b, 0x7,0x49,0x2b, + 0x7,0x4f,0x3d, 0x5,0x6d,0x2e, 0x5,0x6d,0x2d, 0x4,0x64,0x2b, + 0x4,0x64,0x29, 0x5,0x6d,0x2b, 0xf,0x65,0x76, 0x7,0x4f,0x3c, + 0x7,0x4f,0x3b, 0x4,0x67,0x26, 0x7,0x54,0x4f, 0x5,0x70,0x77, + 0x7,0x5c,0x40, 0x7,0x55,0x3a, 0x7,0x5c,0x3f, 0x4,0x69,0x31, + 0x4,0x69,0x2f, 0x7,0x58,0x65, 0xf,0x68,0x33, 0x7,0x5c,0x41, + 0x5,0x76,0x3d, 0x7,0x5c,0x43, 0x7,0x5c,0x45, 0x7,0x5c,0x46, + 0x5,0x76,0x3c, 0x7,0x5c,0x42, 0x4,0x6a,0x6e, 0x7,0x5c,0x47, + 0x7,0x5c,0x48, 0x7,0x5f,0x3d, 0x5,0x77,0x7d, 0x7,0x5f,0x3e, + 0x5,0x79,0x3c, 0x7,0x64,0x57, 0x5,0x7a,0x6f, 0x5,0x7b,0x45, + 0x6,0x28,0x7c, 0x4,0x24,0x71, 0xf,0x2a,0x49, 0x6,0x3b,0x34, + 0xf,0x32,0x2f, 0x6,0x4d,0x56, 0x6,0x4d,0x57, 0xf,0x4b,0x58, + 0xf,0x4b,0x59, 0xf,0x51,0x56, 0x6,0x60,0x73, 0xf,0x5c,0x37, + 0x7,0x42,0x25, 0xf,0x60,0x42, 0x5,0x70,0x79, 0xf,0x68,0x34, + 0xf,0x69,0x67, 0x7,0x65,0x3d, 0x5,0x7c,0x2c, 0x6,0x25,0x4a, + 0x6,0x28,0x7e, 0x4,0x24,0x72, 0x6,0x28,0x7d, 0x6,0x2d,0x70, + 0x5,0x2b,0x3a, 0x6,0x34,0x32, 0xf,0x2d,0x30, 0x5,0x2f,0x72, + 0x6,0x3b,0x36, 0x4,0x2f,0x49, 0xf,0x32,0x30, 0x6,0x3b,0x37, + 0x6,0x3b,0x35, 0x6,0x43,0x66, 0x6,0x43,0x65, 0xf,0x37,0x6d, + 0xf,0x37,0x6e, 0x6,0x4d,0x59, 0x6,0x4d,0x5a, 0x6,0x57,0x24, + 0x5,0x49,0x25, 0xf,0x4b,0x5a, 0x4,0x4c,0x60, 0x4,0x4c,0x61, + 0x5,0x4f,0x7e, 0xf,0x51,0x57, 0x7,0x27,0x3d, 0x4,0x52,0x69, + 0x5,0x57,0x3c, 0x7,0x3a,0x66, 0x5,0x5d,0x60, 0x5,0x5d,0x5f, + 0xf,0x5c,0x38, 0xf,0x60,0x43, 0x5,0x69,0x27, 0x4,0x60,0x75, + 0x5,0x6d,0x31, 0xf,0x63,0x4e, 0x7,0x49,0x2c, 0x5,0x6d,0x2f, + 0x5,0x6d,0x30, 0x7,0x62,0x51, 0x6,0x29,0x21, 0x6,0x2d,0x71, + 0x6,0x2d,0x72, 0x6,0x3b,0x3a, 0xf,0x2d,0x31, 0x6,0x3b,0x38, + 0x6,0x3b,0x39, 0x5,0x34,0x77, 0x4,0x34,0x56, 0x6,0x4d,0x5b, + 0x5,0x42,0x2a, 0x5,0x49,0x26, 0xf,0x4b,0x5b, 0x5,0x50,0x21, + 0x7,0x27,0x3e, 0xf,0x51,0x58, 0x5,0x50,0x22, 0x7,0x31,0x71, + 0x4,0x52,0x6a, 0x5,0x57,0x3d, 0xf,0x57,0x34, 0x4,0x58,0x2f, + 0x5,0x63,0x70, 0x5,0x63,0x71, 0x4,0x24,0x74, 0x6,0x25,0x4b, + 0x6,0x23,0x64, 0x6,0x2d,0x73, 0x6,0x2d,0x74, 0xf,0x2d,0x32, + 0x4,0x2f,0x4b, 0x6,0x34,0x33, 0x6,0x3b,0x3b, 0x6,0x3b,0x41, + 0x6,0x3b,0x3d, 0x6,0x3b,0x3c, 0x4,0x2f,0x4c, 0x6,0x3b,0x3f, + 0x6,0x3b,0x40, 0x6,0x43,0x69, 0x5,0x34,0x78, 0x6,0x3b,0x3e, + 0x6,0x43,0x68, 0x6,0x43,0x6b, 0x6,0x43,0x6a, 0x5,0x3b,0x52, + 0x6,0x4d,0x5c, 0x5,0x3b,0x53, 0x5,0x49,0x27, 0x6,0x57,0x28, + 0x6,0x57,0x27, 0x6,0x57,0x25, 0x6,0x60,0x74, 0x6,0x60,0x7a, + 0x6,0x60,0x75, 0x6,0x60,0x76, 0x5,0x50,0x23, 0x7,0x27,0x3f, + 0x6,0x60,0x77, 0x6,0x60,0x7b, 0x6,0x60,0x78, 0x7,0x27,0x40, + 0x7,0x27,0x41, 0x7,0x27,0x42, 0x6,0x60,0x79, 0x5,0x49,0x28, + 0x5,0x50,0x24, 0x5,0x50,0x25, 0x7,0x27,0x43, 0x7,0x27,0x44, + 0x7,0x31,0x72, 0x7,0x27,0x45, 0x7,0x27,0x46, 0xf,0x57,0x35, + 0x7,0x31,0x74, 0x7,0x31,0x73, 0x5,0x5d,0x62, 0x7,0x31,0x77, + 0x7,0x31,0x76, 0x7,0x31,0x75, 0x5,0x5d,0x61, 0x5,0x5d,0x64, + 0x7,0x3a,0x67, 0x7,0x42,0x28, 0x7,0x42,0x27, 0x5,0x5d,0x65, + 0x4,0x5c,0x77, 0x7,0x42,0x26, 0xf,0x60,0x44, 0xf,0x60,0x45, + 0x7,0x49,0x2d, 0x5,0x63,0x73, 0x5,0x63,0x72, 0x7,0x49,0x2e, + 0x7,0x4f,0x3f, 0x5,0x69,0x28, 0x5,0x6d,0x33, 0x5,0x6d,0x34, + 0x5,0x6d,0x35, 0x7,0x4f,0x3e, 0x7,0x49,0x2f, 0xf,0x63,0x4f, + 0x5,0x69,0x29, 0x7,0x4f,0x40, 0x7,0x4f,0x41, 0x5,0x70,0x7a, + 0xf,0x65,0x78, 0xf,0x68,0x35, 0xf,0x68,0x37, 0x7,0x58,0x66, + 0xf,0x68,0x36, 0x7,0x58,0x67, 0x7,0x5c,0x49, 0x5,0x77,0x7e, + 0x7,0x61,0x37, 0x5,0x79,0x3d, 0x5,0x79,0x3f, 0x5,0x79,0x3e, + 0xf,0x6c,0x6a, 0x7,0x65,0x3e, 0x7,0x65,0x3f, 0x7,0x66,0x53, + 0x5,0x7c,0x50, 0xf,0x25,0x2b, 0x6,0x34,0x34, 0x4,0x2f,0x4e, + 0x4,0x2f,0x4d, 0x6,0x3b,0x42, 0x6,0x3b,0x43, 0x6,0x3b,0x44, + 0x5,0x2f,0x73, 0x5,0x2f,0x74, 0x6,0x43,0x6c, 0x6,0x43,0x6d, + 0x6,0x41,0x7d, 0x6,0x4d,0x60, 0x6,0x4d,0x5f, 0x6,0x4d,0x61, + 0xf,0x3e,0x50, 0x5,0x49,0x29, 0x4,0x46,0x4d, 0x5,0x45,0x53, + 0x4,0x46,0x4e, 0x6,0x57,0x29, 0xf,0x4b,0x5c, 0x6,0x60,0x7c, + 0x6,0x60,0x7e, 0x6,0x60,0x7d, 0x7,0x27,0x47, 0xf,0x51,0x59, + 0x7,0x27,0x49, 0x7,0x27,0x48, 0x7,0x31,0x78, 0x5,0x57,0x3e, + 0x7,0x31,0x79, 0x7,0x3a,0x68, 0xf,0x60,0x46, 0x5,0x63,0x74, + 0x7,0x42,0x2a, 0x7,0x42,0x29, 0x5,0x6d,0x36, 0x5,0x70,0x7b, + 0x7,0x5c,0x4a, 0x5,0x76,0x3e, 0x5,0x50,0x26, 0x5,0x50,0x27, + 0xf,0x60,0x47, 0x7,0x4f,0x42, 0x7,0x5c,0x4b, 0x7,0x5f,0x3f, + 0x7,0x61,0x39, 0x5,0x7a,0x70, 0x5,0x24,0x74, 0x4,0x27,0x71, + 0x4,0x27,0x70, 0x6,0x2d,0x77, 0x6,0x2d,0x76, 0x6,0x2d,0x75, + 0x5,0x27,0x5f, 0x4,0x2b,0x31, 0x4,0x2b,0x35, 0x4,0x2b,0x34, + 0x6,0x34,0x35, 0x6,0x34,0x37, 0x6,0x34,0x36, 0x6,0x3b,0x4a, + 0x5,0x2f,0x75, 0x6,0x3b,0x49, 0x6,0x3b,0x45, 0x5,0x2f,0x76, + 0x4,0x2f,0x52, 0x4,0x2f,0x51, 0x6,0x3b,0x46, 0x6,0x3b,0x47, + 0x6,0x3b,0x48, 0x5,0x34,0x7a, 0x4,0x34,0x59, 0x4,0x34,0x5b, + 0x6,0x43,0x72, 0x5,0x34,0x7b, 0x6,0x43,0x6e, 0x6,0x43,0x6f, + 0xf,0x37,0x71, 0x5,0x34,0x79, 0xf,0x37,0x70, 0xf,0x37,0x72, + 0x5,0x3b,0x54, 0x6,0x4d,0x65, 0x6,0x4d,0x64, 0x4,0x34,0x5a, + 0x4,0x3a,0x52, 0x4,0x3a,0x50, 0x4,0x3a,0x51, 0x4,0x3a,0x53, + 0x6,0x4d,0x66, 0x5,0x42,0x2b, 0x6,0x57,0x2c, 0x5,0x42,0x2c, + 0x6,0x57,0x2a, 0xf,0x44,0x72, 0x6,0x57,0x2b, 0x6,0x57,0x2d, + 0x6,0x57,0x2e, 0x5,0x42,0x2e, 0x6,0x61,0x27, 0x5,0x49,0x2d, + 0x5,0x49,0x2b, 0x4,0x46,0x52, 0x6,0x61,0x22, 0x6,0x61,0x26, + 0xf,0x4b,0x5e, 0xf,0x4b,0x5f, 0xf,0x4b,0x5d, 0x6,0x61,0x23, + 0x5,0x49,0x2a, 0x5,0x50,0x2f, 0x4,0x4c,0x67, 0x4,0x4c,0x66, + 0x5,0x50,0x2e, 0x5,0x50,0x2b, 0x5,0x50,0x2c, 0x5,0x50,0x30, + 0x5,0x50,0x28, 0x7,0x27,0x4f, 0x7,0x27,0x4d, 0x5,0x50,0x31, + 0x7,0x27,0x4a, 0x7,0x27,0x4c, 0x7,0x27,0x4e, 0x7,0x27,0x4b, + 0x5,0x50,0x2d, 0x5,0x50,0x29, 0x5,0x50,0x2a, 0x5,0x57,0x42, + 0x5,0x57,0x3f, 0x5,0x57,0x43, 0x7,0x31,0x7c, 0x5,0x57,0x40, + 0x7,0x32,0x21, 0x7,0x31,0x7d, 0x7,0x32,0x23, 0x5,0x57,0x41, + 0x7,0x32,0x22, 0xf,0x57,0x36, 0x7,0x31,0x7e, 0x7,0x31,0x7b, + 0x7,0x3a,0x6a, 0x4,0x58,0x31, 0x5,0x5d,0x6c, 0x5,0x5d,0x66, + 0x5,0x5d,0x69, 0x5,0x5d,0x68, 0x5,0x5d,0x6a, 0x5,0x5d,0x6b, + 0x4,0x5c,0x79, 0x5,0x63,0x7b, 0x7,0x42,0x2c, 0x5,0x63,0x75, + 0x5,0x63,0x7a, 0x5,0x63,0x7d, 0x5,0x63,0x79, 0x4,0x5c,0x7a, + 0x4,0x5c,0x7b, 0x5,0x63,0x76, 0x5,0x63,0x77, 0x5,0x63,0x7c, + 0x4,0x5c,0x78, 0x7,0x42,0x2d, 0x7,0x42,0x2b, 0x5,0x63,0x78, + 0x7,0x49,0x30, 0x5,0x69,0x2d, 0x5,0x69,0x2c, 0x5,0x69,0x2b, + 0x5,0x69,0x2a, 0x7,0x49,0x31, 0xf,0x63,0x50, 0x7,0x49,0x32, + 0x5,0x6d,0x37, 0x7,0x4f,0x43, 0x5,0x70,0x7d, 0x5,0x70,0x7c, + 0x7,0x54,0x52, 0x5,0x74,0x21, 0x5,0x74,0x22, 0x4,0x69,0x32, + 0x7,0x58,0x68, 0x7,0x54,0x50, 0x7,0x54,0x51, 0x4,0x6a,0x6f, + 0x7,0x5c,0x4c, 0x7,0x61,0x3b, 0x7,0x61,0x3a, 0x7,0x62,0x52, + 0x5,0x7a,0x71, 0x4,0x6e,0x4f, 0x6,0x34,0x38, 0xf,0x37,0x73, + 0x5,0x3b,0x3f, 0xf,0x3e,0x51, 0xf,0x51,0x5a, 0xf,0x5c,0x39, + 0x7,0x4f,0x44, 0x5,0x34,0x7c, 0x5,0x34,0x7d, 0x6,0x43,0x73, + 0x5,0x34,0x7e, 0xf,0x3e,0x52, 0x6,0x57,0x2f, 0x6,0x57,0x30, + 0x6,0x57,0x31, 0x6,0x61,0x29, 0xf,0x4b,0x60, 0x6,0x61,0x2a, + 0x6,0x61,0x28, 0x7,0x27,0x51, 0x7,0x27,0x50, 0x7,0x27,0x52, + 0xf,0x51,0x5b, 0xf,0x51,0x5c, 0xf,0x51,0x5d, 0x5,0x57,0x44, + 0x5,0x57,0x45, 0x7,0x32,0x25, 0x7,0x32,0x24, 0x5,0x6d,0x39, + 0x5,0x6d,0x38, 0x7,0x4f,0x45, 0xf,0x6c,0x37, 0x5,0x21,0x7b, + 0x6,0x23,0x38, 0x4,0x23,0x2e, 0x6,0x25,0x50, 0x6,0x25,0x51, + 0x6,0x2d,0x78, 0x6,0x25,0x4e, 0x5,0x23,0x26, 0x6,0x25,0x4d, + 0xf,0x22,0x6f, 0xf,0x22,0x70, 0xf,0x22,0x6e, 0x6,0x25,0x4c, + 0x4,0x24,0x77, 0x4,0x24,0x78, 0x4,0x24,0x7c, 0x6,0x29,0x22, + 0x4,0x24,0x7a, 0x6,0x29,0x25, 0x6,0x29,0x23, 0x6,0x29,0x24, + 0x6,0x29,0x26, 0xf,0x25,0x2c, 0xf,0x25,0x2d, 0xf,0x25,0x2e, + 0xf,0x25,0x2f, 0xf,0x25,0x30, 0xf,0x25,0x31, 0x6,0x2d,0x7b, + 0x4,0x27,0x7c, 0x4,0x27,0x77, 0x4,0x27,0x79, 0x5,0x27,0x62, + 0x4,0x27,0x7d, 0x4,0x27,0x78, 0x4,0x27,0x75, 0x5,0x27,0x60, + 0x6,0x2d,0x7c, 0x5,0x27,0x61, 0x4,0x27,0x74, 0x6,0x3b,0x4b, + 0x6,0x27,0x4c, 0x6,0x2e,0x21, 0x5,0x27,0x64, 0x4,0x27,0x76, + 0x6,0x2d,0x7a, 0x6,0x2d,0x7e, 0x6,0x3b,0x4d, 0x6,0x3b,0x4c, + 0xf,0x28,0x57, 0xf,0x28,0x58, 0xf,0x28,0x59, 0xf,0x28,0x5a, + 0xf,0x28,0x5b, 0xf,0x28,0x5d, 0xf,0x28,0x5e, 0xf,0x28,0x5f, + 0xf,0x28,0x60, 0xf,0x28,0x61, 0xf,0x28,0x62, 0xf,0x28,0x64, + 0x6,0x2d,0x79, 0x4,0x2b,0x3b, 0x4,0x2b,0x37, 0x4,0x2b,0x38, + 0x4,0x2b,0x39, 0x5,0x2b,0x3f, 0x6,0x34,0x43, 0x6,0x34,0x3b, + 0x4,0x2b,0x3c, 0x6,0x34,0x41, 0x6,0x34,0x3d, 0x5,0x2b,0x3d, + 0x6,0x34,0x39, 0x6,0x34,0x40, 0x6,0x34,0x3e, 0x6,0x34,0x42, + 0x6,0x34,0x45, 0x6,0x34,0x46, 0x5,0x2b,0x3b, 0x5,0x2b,0x3e, + 0x5,0x2b,0x3c, 0xf,0x2d,0x33, 0xf,0x2d,0x35, 0xf,0x2d,0x37, + 0xf,0x2d,0x38, 0xf,0x2d,0x39, 0xf,0x2d,0x3a, 0xf,0x2d,0x3b, + 0xf,0x2d,0x3c, 0xf,0x2d,0x36, 0x6,0x33,0x3e, 0x6,0x34,0x3f, + 0xf,0x2d,0x34, 0x6,0x2d,0x7d, 0x6,0x4d,0x68, 0xf,0x2a,0x52, + 0x5,0x2f,0x7c, 0x4,0x2f,0x56, 0x4,0x2f,0x57, 0x4,0x2f,0x62, + 0x5,0x2f,0x78, 0x5,0x2f,0x7a, 0x5,0x2f,0x7e, 0x4,0x2f,0x54, + 0x5,0x2f,0x77, 0x5,0x30,0x23, 0x4,0x2f,0x5b, 0x5,0x30,0x27, + 0x4,0x2f,0x58, 0x4,0x2f,0x65, 0x5,0x30,0x24, 0x4,0x2f,0x60, + 0x6,0x3b,0x5e, 0x6,0x3b,0x5f, 0x5,0x30,0x25, 0x6,0x3b,0x61, + 0x5,0x30,0x22, 0x4,0x2f,0x66, 0x6,0x3b,0x59, 0x6,0x3b,0x58, + 0x6,0x4d,0x67, 0x6,0x44,0x22, 0x6,0x3b,0x55, 0x5,0x2f,0x7d, + 0x6,0x3b,0x54, 0x6,0x3b,0x51, 0x6,0x3b,0x4f, 0x6,0x3b,0x5a, + 0x6,0x3b,0x5c, 0x5,0x2f,0x7b, 0x6,0x3b,0x57, 0x5,0x30,0x26, + 0x5,0x2f,0x79, 0x6,0x3b,0x53, 0x6,0x3b,0x5b, 0x6,0x3b,0x5d, + 0x6,0x3b,0x62, 0xf,0x32,0x33, 0xf,0x32,0x35, 0xf,0x32,0x36, + 0xf,0x32,0x37, 0xf,0x32,0x38, 0xf,0x32,0x39, 0xf,0x32,0x3b, + 0xf,0x32,0x3c, 0xf,0x32,0x3d, 0xf,0x32,0x3f, 0xf,0x32,0x40, + 0xf,0x32,0x42, 0xf,0x32,0x43, 0xf,0x32,0x44, 0xf,0x32,0x45, + 0xf,0x32,0x47, 0xf,0x32,0x48, 0xf,0x32,0x49, 0xf,0x32,0x4a, + 0xf,0x32,0x4b, 0x6,0x3b,0x50, 0xf,0x32,0x46, 0xf,0x32,0x4c, + 0xf,0x32,0x3e, 0x5,0x35,0x2b, 0x5,0x35,0x2e, 0x5,0x35,0x27, + 0x4,0x34,0x70, 0x5,0x35,0x2c, 0x4,0x34,0x61, 0x4,0x34,0x6e, + 0x4,0x34,0x68, 0x6,0x44,0x32, 0x4,0x34,0x72, 0x4,0x34,0x75, + 0x6,0x44,0x26, 0x6,0x43,0x7b, 0x6,0x44,0x23, 0x5,0x35,0x23, + 0x6,0x43,0x79, 0x6,0x43,0x75, 0x4,0x34,0x60, 0x5,0x35,0x32, + 0x6,0x43,0x74, 0x6,0x44,0x21, 0x6,0x44,0x38, 0x4,0x34,0x64, + 0x6,0x44,0x36, 0x6,0x4e,0x3a, 0x6,0x44,0x34, 0x6,0x3b,0x60, + 0x6,0x4d,0x78, 0x4,0x34,0x5f, 0x5,0x35,0x21, 0x4,0x34,0x6b, + 0x6,0x43,0x77, 0x6,0x44,0x24, 0x5,0x35,0x30, 0x6,0x44,0x2f, + 0x6,0x44,0x35, 0x6,0x44,0x2e, 0x6,0x44,0x29, 0x5,0x35,0x2f, + 0x6,0x44,0x33, 0x6,0x43,0x78, 0x6,0x44,0x27, 0x5,0x35,0x31, + 0x5,0x42,0x2f, 0x6,0x57,0x32, 0x6,0x57,0x33, 0x6,0x44,0x30, + 0x6,0x44,0x31, 0x6,0x43,0x7e, 0x5,0x35,0x22, 0x5,0x35,0x33, + 0x6,0x44,0x2a, 0x5,0x35,0x29, 0x5,0x35,0x2d, 0x5,0x35,0x26, + 0x6,0x4e,0x37, 0x6,0x44,0x39, 0x6,0x44,0x3a, 0x6,0x43,0x7c, + 0x6,0x43,0x7a, 0xf,0x37,0x74, 0xf,0x37,0x75, 0xf,0x37,0x76, + 0xf,0x37,0x77, 0xf,0x37,0x79, 0xf,0x37,0x7b, 0xf,0x37,0x7c, + 0xf,0x37,0x7d, 0xf,0x37,0x7e, 0xf,0x38,0x21, 0xf,0x38,0x22, + 0xf,0x38,0x24, 0xf,0x38,0x25, 0xf,0x38,0x26, 0xf,0x38,0x27, + 0xf,0x38,0x28, 0xf,0x38,0x29, 0xf,0x38,0x2a, 0xf,0x38,0x2b, + 0xf,0x38,0x2c, 0xf,0x38,0x2d, 0xf,0x38,0x2e, 0xf,0x38,0x2f, + 0xf,0x38,0x30, 0xf,0x38,0x31, 0xf,0x38,0x32, 0xf,0x38,0x33, + 0xf,0x38,0x34, 0xf,0x38,0x35, 0x5,0x3b,0x5d, 0x6,0x43,0x7d, + 0x5,0x35,0x28, 0x6,0x44,0x25, 0xf,0x37,0x7a, 0x6,0x44,0x2d, + 0x6,0x44,0x37, 0xf,0x38,0x23, 0x5,0x35,0x25, 0x5,0x3b,0x55, + 0x4,0x3a,0x55, 0x5,0x3b,0x69, 0x5,0x3b,0x6a, 0x5,0x3b,0x62, + 0x5,0x3b,0x6c, 0x5,0x3b,0x6d, 0x5,0x3b,0x63, 0x4,0x3a,0x5d, + 0x6,0x4d,0x7a, 0x6,0x4d,0x72, 0x6,0x4e,0x2b, 0x6,0x4d,0x70, + 0x6,0x4d,0x6b, 0x5,0x3b,0x5f, 0x5,0x3b,0x67, 0x5,0x3b,0x68, + 0x6,0x4d,0x7b, 0x6,0x4d,0x79, 0x5,0x3b,0x5e, 0x5,0x3b,0x6e, + 0x5,0x3b,0x6b, 0x4,0x34,0x6a, 0x4,0x3a,0x57, 0x4,0x3a,0x5a, + 0x4,0x3a,0x58, 0x4,0x3a,0x62, 0x5,0x3b,0x5a, 0x4,0x3a,0x54, + 0x6,0x4d,0x69, 0x6,0x4e,0x35, 0x4,0x3a,0x63, 0x6,0x4d,0x6a, + 0x5,0x3b,0x64, 0x6,0x4d,0x7c, 0x6,0x4e,0x36, 0x6,0x4d,0x7d, + 0x6,0x4e,0x2f, 0x6,0x4e,0x30, 0x4,0x3a,0x6b, 0x6,0x4e,0x26, + 0x4,0x3a,0x69, 0x6,0x4e,0x23, 0x5,0x3b,0x5c, 0x6,0x4e,0x28, + 0x6,0x4d,0x75, 0x6,0x4e,0x2d, 0x6,0x4d,0x74, 0x6,0x4e,0x22, + 0x6,0x4e,0x31, 0x6,0x4e,0x29, 0x5,0x3b,0x65, 0x6,0x61,0x32, + 0x6,0x61,0x2d, 0x6,0x61,0x2e, 0x5,0x3b,0x57, 0x6,0x4e,0x24, + 0x6,0x4d,0x6f, 0x6,0x4e,0x2e, 0x5,0x49,0x2e, 0x6,0x4d,0x73, + 0x6,0x4e,0x2c, 0x6,0x4d,0x77, 0x6,0x4e,0x25, 0x6,0x4d,0x6d, + 0x6,0x4e,0x2a, 0x4,0x3a,0x6a, 0x5,0x3b,0x60, 0x5,0x3b,0x5b, + 0x6,0x4d,0x76, 0x6,0x4e,0x38, 0x6,0x61,0x2b, 0x5,0x3b,0x66, + 0x6,0x61,0x2f, 0x5,0x3b,0x61, 0x6,0x4e,0x34, 0x6,0x61,0x31, + 0x6,0x61,0x30, 0x6,0x4d,0x6c, 0x6,0x4d,0x7e, 0x6,0x4c,0x7b, + 0x5,0x3b,0x58, 0x6,0x4d,0x6e, 0x6,0x4d,0x71, 0x6,0x4e,0x33, + 0x6,0x4e,0x39, 0xf,0x3e,0x53, 0xf,0x3e,0x55, 0xf,0x3e,0x56, + 0xf,0x3e,0x58, 0xf,0x3e,0x5a, 0xf,0x3e,0x5b, 0xf,0x3e,0x5c, + 0xf,0x3e,0x5d, 0xf,0x3e,0x5e, 0xf,0x3e,0x5f, 0xf,0x3e,0x60, + 0xf,0x3e,0x61, 0xf,0x3e,0x63, 0xf,0x3e,0x64, 0xf,0x3e,0x65, + 0xf,0x3e,0x68, 0xf,0x3e,0x69, 0xf,0x3e,0x6a, 0xf,0x3e,0x6d, + 0xf,0x3e,0x6f, 0xf,0x3e,0x70, 0xf,0x3e,0x71, 0xf,0x3e,0x72, + 0xf,0x3e,0x74, 0xf,0x3e,0x75, 0xf,0x3e,0x76, 0xf,0x3e,0x77, + 0xf,0x3e,0x78, 0xf,0x3e,0x79, 0xf,0x3e,0x7a, 0xf,0x3e,0x7b, + 0xf,0x3e,0x7c, 0xf,0x3e,0x7d, 0xf,0x3e,0x7e, 0x6,0x61,0x2c, + 0x5,0x3b,0x59, 0x6,0x4e,0x21, 0xf,0x3e,0x62, 0xf,0x3e,0x54, + 0xf,0x3e,0x6e, 0xf,0x3e,0x73, 0x4,0x40,0x43, 0x6,0x57,0x34, + 0x6,0x57,0x46, 0x5,0x42,0x4e, 0x6,0x57,0x3a, 0x6,0x57,0x3b, + 0x5,0x42,0x34, 0x4,0x40,0x3d, 0x6,0x57,0x49, 0x6,0x57,0x5a, + 0x4,0x40,0x40, 0x4,0x40,0x42, 0x5,0x42,0x45, 0x6,0x57,0x5e, + 0x5,0x42,0x3a, 0x4,0x40,0x37, 0x4,0x40,0x34, 0x6,0x57,0x41, + 0x6,0x57,0x63, 0x5,0x42,0x33, 0x6,0x57,0x51, 0x6,0x57,0x55, + 0x5,0x42,0x43, 0x6,0x57,0x4a, 0x4,0x40,0x38, 0x4,0x40,0x3b, + 0x5,0x42,0x36, 0x6,0x57,0x43, 0x4,0x40,0x3c, 0x4,0x40,0x45, + 0x5,0x42,0x41, 0x4,0x40,0x4d, 0x5,0x42,0x4f, 0x4,0x40,0x3e, + 0x5,0x42,0x46, 0x6,0x57,0x5d, 0x5,0x42,0x3f, 0x4,0x40,0x33, + 0x4,0x40,0x31, 0x6,0x57,0x65, 0x4,0x40,0x3f, 0x6,0x57,0x42, + 0x5,0x42,0x48, 0x5,0x42,0x42, 0x5,0x42,0x38, 0x5,0x42,0x3e, + 0x6,0x57,0x38, 0x6,0x57,0x53, 0x6,0x57,0x4f, 0x6,0x57,0x40, + 0x6,0x57,0x67, 0x5,0x42,0x3d, 0x6,0x57,0x39, 0x6,0x57,0x64, + 0x6,0x57,0x37, 0x5,0x42,0x50, 0x6,0x57,0x4e, 0x6,0x57,0x45, + 0x6,0x57,0x3c, 0x5,0x42,0x49, 0x5,0x42,0x4d, 0x5,0x42,0x3b, + 0x5,0x42,0x47, 0x6,0x57,0x52, 0x6,0x57,0x60, 0x6,0x57,0x5c, + 0x6,0x57,0x48, 0x6,0x57,0x56, 0x5,0x42,0x39, 0x4,0x40,0x39, + 0x6,0x57,0x57, 0x5,0x42,0x30, 0x5,0x42,0x40, 0x5,0x42,0x32, + 0x5,0x42,0x4a, 0x6,0x57,0x3f, 0x4,0x40,0x35, 0x4,0x40,0x4b, + 0x6,0x57,0x4c, 0x5,0x42,0x35, 0x5,0x42,0x31, 0x6,0x57,0x47, + 0x6,0x57,0x58, 0x7,0x27,0x53, 0x6,0x57,0x61, 0x5,0x42,0x3c, + 0x6,0x57,0x44, 0x6,0x57,0x54, 0x6,0x57,0x36, 0x6,0x57,0x62, + 0x6,0x57,0x66, 0x6,0x57,0x59, 0x4,0x40,0x4e, 0x5,0x42,0x44, + 0x5,0x42,0x4b, 0x6,0x57,0x35, 0x6,0x57,0x3e, 0x6,0x57,0x4b, + 0x6,0x57,0x4d, 0x6,0x57,0x5b, 0x6,0x57,0x5f, 0xf,0x44,0x73, + 0xf,0x44,0x75, 0xf,0x44,0x76, 0xf,0x44,0x77, 0xf,0x44,0x78, + 0xf,0x44,0x79, 0xf,0x44,0x7a, 0xf,0x44,0x7b, 0xf,0x44,0x7c, + 0xf,0x44,0x7d, 0xf,0x44,0x7e, 0xf,0x45,0x21, 0xf,0x45,0x22, + 0xf,0x45,0x23, 0xf,0x45,0x24, 0xf,0x45,0x25, 0xf,0x45,0x26, + 0xf,0x45,0x27, 0xf,0x45,0x28, 0xf,0x45,0x29, 0xf,0x45,0x2a, + 0xf,0x45,0x2b, 0xf,0x45,0x2c, 0xf,0x45,0x2e, 0xf,0x45,0x2f, + 0xf,0x45,0x30, 0xf,0x45,0x31, 0x5,0x42,0x4c, 0x4,0x40,0x4a, + 0x6,0x57,0x3d, 0x6,0x4e,0x32, 0xf,0x3e,0x57, 0x5,0x42,0x37, + 0x4,0x46,0x66, 0x6,0x61,0x60, 0x5,0x49,0x45, 0x6,0x61,0x33, + 0x6,0x61,0x43, 0x5,0x49,0x4b, 0x4,0x46,0x63, 0x6,0x61,0x56, + 0x4,0x46,0x56, 0x6,0x61,0x45, 0x4,0x46,0x59, 0x6,0x61,0x3c, + 0x5,0x49,0x41, 0x6,0x61,0x4a, 0x4,0x46,0x55, 0x6,0x61,0x52, + 0x5,0x49,0x3d, 0x6,0x61,0x40, 0x6,0x61,0x59, 0x5,0x49,0x49, + 0x5,0x49,0x46, 0x6,0x61,0x4c, 0x5,0x49,0x3a, 0x4,0x46,0x5a, + 0x6,0x61,0x39, 0x6,0x61,0x55, 0x6,0x61,0x4d, 0x6,0x61,0x3f, + 0x5,0x49,0x44, 0x5,0x49,0x39, 0x5,0x49,0x30, 0x4,0x46,0x62, + 0x6,0x61,0x41, 0x4,0x46,0x5e, 0x6,0x61,0x36, 0x4,0x46,0x5d, + 0x4,0x46,0x6b, 0x4,0x46,0x5b, 0x5,0x49,0x3f, 0x7,0x27,0x58, + 0x6,0x61,0x37, 0x5,0x49,0x32, 0x5,0x49,0x37, 0x5,0x49,0x31, + 0x5,0x49,0x48, 0x5,0x50,0x3b, 0x4,0x46,0x5f, 0x5,0x49,0x43, + 0x6,0x61,0x38, 0x4,0x46,0x68, 0x6,0x61,0x50, 0x5,0x49,0x38, + 0x6,0x61,0x57, 0x6,0x61,0x46, 0x6,0x61,0x3b, 0x5,0x49,0x40, + 0x5,0x49,0x36, 0x7,0x32,0x27, 0x5,0x49,0x2f, 0x5,0x49,0x34, + 0x6,0x61,0x47, 0x6,0x61,0x49, 0x6,0x61,0x4b, 0x6,0x61,0x4e, + 0x6,0x61,0x5a, 0x6,0x61,0x5d, 0x6,0x61,0x5e, 0xf,0x4b,0x61, + 0xf,0x4b,0x62, 0xf,0x4b,0x63, 0xf,0x4b,0x66, 0xf,0x4b,0x68, + 0xf,0x4b,0x69, 0xf,0x4b,0x6a, 0xf,0x4b,0x6b, 0xf,0x4b,0x6c, + 0xf,0x4b,0x6d, 0xf,0x4b,0x6e, 0xf,0x4b,0x6f, 0xf,0x4b,0x70, + 0xf,0x4b,0x71, 0xf,0x4b,0x72, 0xf,0x4b,0x73, 0xf,0x4b,0x74, + 0xf,0x4b,0x75, 0xf,0x4b,0x76, 0xf,0x4b,0x78, 0xf,0x4b,0x79, + 0xf,0x4b,0x7a, 0xf,0x4b,0x7c, 0xf,0x4b,0x7d, 0xf,0x4b,0x7e, + 0xf,0x4c,0x21, 0xf,0x4c,0x22, 0xf,0x4c,0x23, 0xf,0x4c,0x25, + 0xf,0x4c,0x26, 0xf,0x4c,0x27, 0xf,0x4c,0x28, 0xf,0x4c,0x29, + 0xf,0x4c,0x2a, 0x6,0x61,0x48, 0x5,0x49,0x42, 0x6,0x61,0x53, + 0x6,0x61,0x51, 0x6,0x57,0x68, 0x5,0x49,0x4a, 0x6,0x61,0x5c, + 0x6,0x61,0x5f, 0x6,0x61,0x5b, 0x6,0x61,0x3a, 0x6,0x61,0x35, + 0x6,0x61,0x42, 0x6,0x61,0x3d, 0x6,0x57,0x50, 0xf,0x4b,0x64, + 0xf,0x4b,0x67, 0x6,0x61,0x54, 0x4,0x46,0x6a, 0x4,0x46,0x54, + 0x5,0x49,0x35, 0x5,0x49,0x4d, 0x7,0x32,0x26, 0x5,0x49,0x33, + 0x6,0x61,0x61, 0x5,0x49,0x47, 0x5,0x49,0x4c, 0x5,0x57,0x46, + 0xf,0x4b,0x7b, 0x5,0x49,0x3e, 0x7,0x27,0x6c, 0x4,0x4c,0x7e, + 0x5,0x50,0x32, 0x4,0x4c,0x69, 0x4,0x4c,0x7c, 0x7,0x28,0x21, + 0x5,0x50,0x35, 0x7,0x28,0x24, 0x7,0x27,0x77, 0x7,0x27,0x5c, + 0x5,0x50,0x39, 0x7,0x27,0x69, 0x7,0x27,0x78, 0x7,0x27,0x79, + 0x7,0x27,0x6a, 0x7,0x27,0x73, 0x5,0x50,0x3a, 0x7,0x27,0x6f, + 0x4,0x4c,0x75, 0x5,0x50,0x3d, 0x5,0x50,0x42, 0x7,0x27,0x60, + 0x7,0x28,0x22, 0x5,0x50,0x40, 0x5,0x50,0x3f, 0x5,0x57,0x47, + 0x5,0x50,0x41, 0x5,0x50,0x4b, 0x7,0x27,0x6b, 0x7,0x27,0x76, + 0x7,0x27,0x59, 0x7,0x27,0x72, 0x7,0x27,0x65, 0x5,0x50,0x48, + 0x5,0x50,0x37, 0x4,0x4c,0x7b, 0x7,0x27,0x54, 0x7,0x27,0x5b, + 0x7,0x27,0x64, 0x7,0x27,0x63, 0x7,0x27,0x67, 0x5,0x50,0x33, + 0x7,0x27,0x66, 0x7,0x27,0x7d, 0x7,0x27,0x5e, 0x5,0x50,0x3e, + 0x7,0x27,0x56, 0x5,0x50,0x34, 0x5,0x50,0x4a, 0x7,0x27,0x7c, + 0x7,0x27,0x62, 0x7,0x27,0x5d, 0x7,0x27,0x6e, 0x4,0x4c,0x76, + 0x5,0x50,0x49, 0x5,0x50,0x45, 0x7,0x27,0x74, 0x5,0x57,0x58, + 0x4,0x4d,0x22, 0x5,0x50,0x43, 0x7,0x27,0x55, 0x7,0x27,0x5a, + 0x7,0x27,0x5f, 0x7,0x27,0x70, 0x7,0x27,0x71, 0x7,0x28,0x23, + 0xf,0x51,0x5e, 0xf,0x51,0x5f, 0xf,0x51,0x60, 0xf,0x51,0x62, + 0xf,0x51,0x63, 0xf,0x51,0x66, 0xf,0x51,0x67, 0xf,0x51,0x68, + 0xf,0x51,0x69, 0xf,0x51,0x6a, 0xf,0x51,0x6c, 0xf,0x51,0x6d, + 0xf,0x51,0x6e, 0xf,0x51,0x6f, 0xf,0x51,0x70, 0xf,0x51,0x72, + 0xf,0x51,0x75, 0xf,0x51,0x77, 0x4,0x4d,0x23, 0x7,0x27,0x7a, + 0x5,0x50,0x44, 0x7,0x27,0x7e, 0x7,0x27,0x75, 0x7,0x27,0x68, + 0xf,0x51,0x71, 0xf,0x51,0x61, 0xf,0x51,0x6b, 0x5,0x50,0x36, + 0x7,0x27,0x57, 0x5,0x50,0x47, 0x5,0x50,0x3c, 0x6,0x61,0x34, + 0x7,0x42,0x2e, 0xf,0x4c,0x24, 0x7,0x32,0x51, 0x4,0x53,0x2d, + 0x7,0x32,0x32, 0x4,0x53,0x2a, 0x4,0x53,0x34, 0x7,0x32,0x53, + 0x5,0x57,0x49, 0x4,0x53,0x2b, 0x5,0x57,0x5d, 0x7,0x32,0x43, + 0x5,0x57,0x54, 0x4,0x52,0x71, 0x4,0x53,0x30, 0x5,0x57,0x51, + 0x5,0x57,0x5b, 0x7,0x32,0x3c, 0x4,0x52,0x75, 0x5,0x57,0x5a, + 0x5,0x57,0x4b, 0x5,0x57,0x5f, 0x7,0x32,0x33, 0x5,0x57,0x61, + 0x4,0x53,0x2f, 0x7,0x32,0x28, 0x5,0x57,0x4d, 0x5,0x57,0x4f, + 0x7,0x32,0x4c, 0x5,0x57,0x55, 0x5,0x57,0x62, 0x7,0x32,0x3d, + 0x7,0x32,0x3b, 0x5,0x50,0x4c, 0x4,0x52,0x70, 0x5,0x57,0x48, + 0x5,0x57,0x5e, 0x7,0x32,0x45, 0x7,0x32,0x4b, 0x7,0x32,0x41, + 0x5,0x57,0x64, 0x5,0x57,0x60, 0x7,0x28,0x25, 0x7,0x27,0x7b, + 0x7,0x32,0x52, 0x5,0x5d,0x7a, 0x4,0x53,0x26, 0x7,0x32,0x2e, + 0x4,0x53,0x29, 0x7,0x32,0x36, 0x5,0x57,0x53, 0x4,0x53,0x28, + 0x4,0x52,0x74, 0x5,0x50,0x38, 0x7,0x32,0x2f, 0x5,0x57,0x52, + 0x7,0x32,0x38, 0x5,0x57,0x56, 0x5,0x57,0x4c, 0x7,0x32,0x2d, + 0x7,0x32,0x57, 0x7,0x32,0x4e, 0x4,0x53,0x2e, 0x5,0x57,0x5c, + 0x7,0x32,0x2a, 0x4,0x52,0x78, 0x7,0x32,0x39, 0x7,0x42,0x2f, + 0x7,0x32,0x2b, 0x7,0x32,0x55, 0x4,0x53,0x32, 0x7,0x32,0x42, + 0x7,0x32,0x35, 0x7,0x32,0x3f, 0xf,0x57,0x3e, 0xf,0x57,0x3f, + 0xf,0x57,0x40, 0xf,0x57,0x41, 0x5,0x57,0x4a, 0x5,0x57,0x50, + 0x5,0x57,0x57, 0x7,0x32,0x2c, 0x7,0x32,0x34, 0x7,0x32,0x37, + 0x7,0x32,0x3e, 0x7,0x32,0x40, 0x7,0x32,0x47, 0x7,0x32,0x49, + 0x7,0x32,0x4d, 0x7,0x32,0x4f, 0x7,0x32,0x54, 0x7,0x32,0x59, + 0x7,0x32,0x5a, 0xf,0x57,0x37, 0xf,0x57,0x38, 0xf,0x57,0x39, + 0xf,0x57,0x3a, 0xf,0x57,0x3b, 0xf,0x57,0x3c, 0xf,0x57,0x3d, + 0xf,0x57,0x42, 0xf,0x57,0x43, 0xf,0x57,0x44, 0xf,0x57,0x49, + 0xf,0x57,0x4c, 0xf,0x57,0x4d, 0xf,0x57,0x4e, 0xf,0x57,0x4f, + 0xf,0x57,0x50, 0xf,0x57,0x51, 0xf,0x57,0x52, 0xf,0x57,0x53, + 0xf,0x57,0x54, 0xf,0x57,0x56, 0xf,0x57,0x57, 0xf,0x57,0x58, + 0xf,0x57,0x59, 0xf,0x57,0x5a, 0xf,0x57,0x5b, 0xf,0x57,0x5c, + 0x7,0x32,0x31, 0xf,0x57,0x45, 0x4,0x52,0x7d, 0x7,0x32,0x3a, + 0x7,0x32,0x58, 0x7,0x32,0x50, 0x5,0x57,0x65, 0x5,0x57,0x4e, + 0x7,0x32,0x30, 0x7,0x32,0x29, 0x7,0x32,0x48, 0xf,0x57,0x4a, + 0x7,0x32,0x56, 0x5,0x57,0x63, 0x5,0x57,0x59, 0x7,0x32,0x46, + 0x7,0x3a,0x76, 0x4,0x58,0x3a, 0x4,0x58,0x3f, 0x7,0x3a,0x6e, + 0x7,0x42,0x3b, 0x7,0x3a,0x78, 0x4,0x58,0x48, 0x4,0x58,0x49, + 0x5,0x57,0x66, 0x5,0x5d,0x75, 0x5,0x5d,0x7d, 0x5,0x5d,0x73, + 0x7,0x3b,0x2b, 0x7,0x3b,0x2f, 0x5,0x5d,0x6f, 0x4,0x58,0x4a, + 0x4,0x58,0x37, 0x7,0x3a,0x7b, 0x4,0x58,0x45, 0x5,0x5e,0x21, + 0x7,0x3a,0x7c, 0x7,0x3b,0x23, 0x7,0x3b,0x33, 0x5,0x5d,0x7e, + 0x5,0x5e,0x25, 0x7,0x3b,0x31, 0x5,0x5e,0x22, 0x5,0x5d,0x6e, + 0x5,0x5d,0x78, 0x7,0x3a,0x7e, 0x5,0x5d,0x7c, 0x7,0x3a,0x73, + 0x7,0x3b,0x24, 0x7,0x3b,0x2a, 0x5,0x5d,0x7b, 0x4,0x58,0x4b, + 0x5,0x5d,0x6d, 0x5,0x5e,0x23, 0x4,0x58,0x41, 0x7,0x3b,0x30, + 0x5,0x5d,0x77, 0x4,0x58,0x46, 0x5,0x5d,0x71, 0x5,0x5e,0x24, + 0x7,0x3b,0x25, 0x5,0x5d,0x76, 0x7,0x3a,0x70, 0x7,0x3a,0x75, + 0x7,0x42,0x39, 0x7,0x3a,0x6b, 0x7,0x3a,0x6c, 0x7,0x3b,0x35, + 0x7,0x3a,0x7d, 0x4,0x58,0x47, 0x7,0x3b,0x2e, 0x7,0x3a,0x72, + 0x7,0x3a,0x77, 0x7,0x49,0x34, 0x7,0x3a,0x71, 0x7,0x3b,0x22, + 0x7,0x3b,0x29, 0x7,0x32,0x4a, 0x7,0x3a,0x79, 0x7,0x3b,0x21, + 0x7,0x3b,0x37, 0x5,0x5d,0x74, 0x5,0x50,0x4d, 0x4,0x58,0x43, + 0x7,0x49,0x35, 0x5,0x5d,0x70, 0x5,0x5d,0x72, 0x7,0x3a,0x6d, + 0x7,0x3b,0x27, 0x7,0x3b,0x28, 0x7,0x3b,0x2c, 0x7,0x3b,0x34, + 0xf,0x5c,0x3a, 0xf,0x5c,0x3b, 0xf,0x5c,0x3c, 0xf,0x5c,0x3d, + 0xf,0x5c,0x3e, 0xf,0x5c,0x40, 0xf,0x5c,0x41, 0xf,0x5c,0x42, + 0xf,0x5c,0x43, 0xf,0x5c,0x44, 0xf,0x5c,0x45, 0xf,0x5c,0x46, + 0xf,0x5c,0x47, 0xf,0x5c,0x49, 0xf,0x5c,0x4a, 0xf,0x5c,0x4b, + 0xf,0x5c,0x4c, 0xf,0x5c,0x4f, 0xf,0x5c,0x50, 0x4,0x58,0x39, + 0x7,0x3a,0x7a, 0x7,0x3b,0x2d, 0x7,0x3b,0x36, 0x7,0x3a,0x74, + 0xf,0x5c,0x48, 0xf,0x5c,0x3f, 0xf,0x5c,0x4e, 0xf,0x57,0x55, + 0xf,0x63,0x5b, 0x5,0x64,0x2c, 0x7,0x42,0x4b, 0x4,0x5d,0x24, + 0x7,0x42,0x4c, 0x5,0x64,0x22, 0x4,0x5d,0x25, 0x5,0x5e,0x26, + 0x5,0x64,0x2f, 0x7,0x42,0x48, 0x5,0x64,0x25, 0x5,0x63,0x7e, + 0x7,0x42,0x30, 0x5,0x64,0x21, 0x5,0x64,0x29, 0x5,0x64,0x36, + 0x5,0x64,0x39, 0x7,0x42,0x36, 0x5,0x64,0x33, 0x7,0x42,0x46, + 0x4,0x5d,0x22, 0x5,0x5e,0x27, 0x5,0x64,0x38, 0x5,0x64,0x26, + 0x5,0x64,0x30, 0x7,0x42,0x3d, 0x5,0x64,0x24, 0x5,0x64,0x2e, + 0x7,0x42,0x4d, 0x4,0x5d,0x30, 0x5,0x64,0x31, 0x4,0x5d,0x2e, + 0x4,0x5d,0x26, 0x4,0x5d,0x2a, 0x5,0x64,0x34, 0x5,0x64,0x32, + 0x7,0x42,0x3e, 0x7,0x4f,0x46, 0x7,0x42,0x3a, 0x7,0x42,0x37, + 0x4,0x5d,0x2f, 0x7,0x49,0x44, 0x5,0x64,0x2b, 0x7,0x42,0x33, + 0x7,0x42,0x45, 0x7,0x42,0x49, 0x4,0x5d,0x2d, 0x7,0x3b,0x26, + 0x7,0x42,0x32, 0x7,0x42,0x34, 0x7,0x42,0x35, 0x7,0x42,0x3f, + 0x7,0x42,0x42, 0x7,0x42,0x44, 0x7,0x42,0x4a, 0x7,0x42,0x4e, + 0x7,0x42,0x4f, 0xf,0x60,0x48, 0xf,0x60,0x49, 0xf,0x60,0x4a, + 0xf,0x60,0x4b, 0xf,0x60,0x4c, 0xf,0x60,0x4f, 0xf,0x60,0x50, + 0xf,0x60,0x51, 0xf,0x60,0x52, 0xf,0x60,0x53, 0xf,0x60,0x54, + 0xf,0x60,0x55, 0xf,0x60,0x56, 0xf,0x60,0x57, 0xf,0x60,0x58, + 0xf,0x60,0x59, 0xf,0x60,0x5a, 0xf,0x60,0x5b, 0xf,0x60,0x5c, + 0xf,0x60,0x5e, 0xf,0x60,0x5f, 0x4,0x5d,0x27, 0x7,0x42,0x40, + 0x5,0x64,0x27, 0x7,0x42,0x41, 0x7,0x49,0x33, 0x5,0x64,0x35, + 0x5,0x64,0x2a, 0x4,0x5d,0x29, 0x7,0x42,0x47, 0x5,0x64,0x23, + 0x5,0x64,0x28, 0x5,0x64,0x37, 0x7,0x42,0x43, 0x7,0x42,0x31, + 0x5,0x69,0x3e, 0x5,0x69,0x2f, 0x7,0x4f,0x5d, 0x5,0x69,0x30, + 0x5,0x69,0x3a, 0x5,0x69,0x36, 0x4,0x60,0x7d, 0x4,0x60,0x79, + 0x5,0x69,0x3f, 0x5,0x69,0x37, 0x7,0x49,0x38, 0x7,0x49,0x45, + 0x5,0x69,0x3b, 0x5,0x69,0x35, 0x4,0x60,0x7c, 0x5,0x69,0x2e, + 0x5,0x6d,0x42, 0x7,0x49,0x43, 0x5,0x69,0x38, 0x7,0x49,0x46, + 0x5,0x69,0x39, 0x7,0x49,0x41, 0x7,0x49,0x54, 0x7,0x49,0x51, + 0x7,0x49,0x3c, 0x5,0x69,0x33, 0x5,0x69,0x3d, 0x7,0x49,0x4b, + 0x7,0x49,0x4e, 0x7,0x49,0x3e, 0x7,0x49,0x3d, 0x7,0x49,0x42, + 0x7,0x49,0x47, 0x7,0x4f,0x54, 0x7,0x49,0x4d, 0x7,0x49,0x39, + 0x7,0x49,0x4c, 0x7,0x49,0x4a, 0x7,0x4f,0x47, 0x5,0x69,0x34, + 0x5,0x69,0x32, 0x4,0x60,0x76, 0x5,0x69,0x3c, 0x7,0x49,0x49, + 0x7,0x49,0x40, 0x7,0x49,0x3f, 0x7,0x49,0x36, 0x7,0x49,0x37, + 0x7,0x49,0x3a, 0x7,0x49,0x48, 0x7,0x49,0x50, 0x7,0x49,0x52, + 0xf,0x63,0x51, 0xf,0x63,0x52, 0xf,0x63,0x54, 0xf,0x63,0x55, + 0xf,0x63,0x56, 0xf,0x63,0x57, 0xf,0x63,0x58, 0xf,0x63,0x59, + 0xf,0x63,0x5a, 0xf,0x63,0x5c, 0xf,0x63,0x5d, 0xf,0x63,0x5e, + 0xf,0x63,0x5f, 0xf,0x63,0x60, 0xf,0x63,0x61, 0xf,0x63,0x62, + 0xf,0x63,0x63, 0xf,0x63,0x64, 0xf,0x63,0x65, 0xf,0x63,0x66, + 0xf,0x63,0x67, 0xf,0x63,0x68, 0xf,0x63,0x69, 0x7,0x49,0x4f, + 0x7,0x4f,0x5e, 0x7,0x4f,0x55, 0x7,0x4f,0x4e, 0x5,0x6d,0x40, + 0x5,0x6d,0x47, 0x7,0x4f,0x61, 0x5,0x6d,0x41, 0x5,0x6d,0x44, + 0x4,0x64,0x39, 0x7,0x4f,0x58, 0x5,0x6d,0x46, 0x4,0x64,0x35, + 0x5,0x6d,0x3f, 0x5,0x70,0x7e, 0x7,0x4f,0x5f, 0x5,0x6d,0x3b, + 0x7,0x4f,0x51, 0x7,0x4f,0x50, 0x7,0x4f,0x4c, 0x5,0x6d,0x3e, + 0x5,0x6d,0x45, 0x7,0x4f,0x4d, 0x4,0x64,0x31, 0x7,0x4f,0x67, + 0x5,0x6d,0x3c, 0x7,0x4f,0x4b, 0x7,0x4f,0x53, 0x7,0x4f,0x62, + 0x7,0x4f,0x5b, 0x7,0x49,0x3b, 0x7,0x4f,0x65, 0x5,0x6d,0x43, + 0x4,0x64,0x2e, 0x7,0x4f,0x59, 0x5,0x6d,0x3d, 0x7,0x4f,0x66, + 0x7,0x4f,0x5a, 0x5,0x69,0x31, 0x7,0x54,0x67, 0x7,0x58,0x69, + 0x7,0x4f,0x49, 0x5,0x6d,0x3a, 0x5,0x6d,0x48, 0x7,0x4f,0x52, + 0x7,0x4f,0x56, 0x7,0x4f,0x57, 0x7,0x4f,0x5c, 0x7,0x4f,0x63, + 0x7,0x4f,0x64, 0xf,0x65,0x79, 0xf,0x65,0x7a, 0xf,0x65,0x7b, + 0xf,0x65,0x7c, 0xf,0x65,0x7d, 0xf,0x65,0x7e, 0xf,0x66,0x21, + 0xf,0x66,0x22, 0xf,0x66,0x23, 0xf,0x66,0x24, 0xf,0x66,0x25, + 0xf,0x66,0x26, 0xf,0x66,0x27, 0xf,0x66,0x28, 0xf,0x66,0x29, + 0xf,0x66,0x2a, 0xf,0x66,0x2b, 0xf,0x66,0x2c, 0x7,0x4f,0x4a, + 0x7,0x4f,0x48, 0x7,0x4f,0x60, 0x7,0x54,0x63, 0x4,0x69,0x35, + 0x5,0x71,0x28, 0x7,0x54,0x66, 0x7,0x54,0x5f, 0x5,0x71,0x24, + 0x4,0x67,0x2c, 0x4,0x67,0x2a, 0x7,0x54,0x59, 0x4,0x67,0x2e, + 0x5,0x71,0x22, 0x7,0x54,0x64, 0x5,0x71,0x25, 0x7,0x54,0x65, + 0x4,0x67,0x29, 0x5,0x6d,0x49, 0x5,0x71,0x27, 0x7,0x54,0x5b, + 0x7,0x54,0x53, 0x5,0x71,0x26, 0x7,0x54,0x62, 0x7,0x54,0x57, + 0x7,0x54,0x55, 0x7,0x54,0x60, 0x4,0x67,0x2d, 0x5,0x71,0x23, + 0x5,0x71,0x29, 0x5,0x71,0x2a, 0x7,0x54,0x54, 0x7,0x54,0x5c, + 0x7,0x4f,0x4f, 0x7,0x54,0x5a, 0x7,0x58,0x76, 0x5,0x71,0x21, + 0x7,0x54,0x56, 0x7,0x54,0x5d, 0x7,0x54,0x61, 0xf,0x68,0x38, + 0xf,0x68,0x3a, 0xf,0x68,0x3b, 0xf,0x68,0x3c, 0xf,0x68,0x3d, + 0xf,0x68,0x3e, 0xf,0x68,0x3f, 0xf,0x68,0x41, 0xf,0x68,0x42, + 0xf,0x68,0x43, 0xf,0x68,0x44, 0xf,0x68,0x40, 0x7,0x54,0x58, + 0x5,0x74,0x24, 0x4,0x69,0x36, 0x5,0x74,0x25, 0x5,0x74,0x27, + 0x5,0x74,0x28, 0x7,0x58,0x70, 0x5,0x74,0x29, 0x4,0x69,0x3b, + 0x4,0x69,0x3a, 0x7,0x58,0x77, 0x7,0x58,0x75, 0x7,0x58,0x6d, + 0x7,0x5c,0x53, 0x5,0x74,0x23, 0x5,0x74,0x26, 0x7,0x58,0x6f, + 0x4,0x69,0x38, 0x4,0x69,0x39, 0x7,0x58,0x6e, 0x4,0x69,0x34, + 0x7,0x58,0x73, 0x7,0x58,0x6b, 0x7,0x58,0x78, 0x7,0x58,0x6a, + 0x7,0x58,0x6c, 0x7,0x58,0x71, 0x7,0x58,0x74, 0xf,0x69,0x68, + 0xf,0x69,0x6b, 0xf,0x69,0x6c, 0x7,0x5c,0x4f, 0x7,0x5c,0x5a, + 0x4,0x6a,0x75, 0x5,0x76,0x40, 0x4,0x6a,0x74, 0x5,0x76,0x3f, + 0x4,0x6a,0x71, 0x4,0x6a,0x73, 0x4,0x6a,0x72, 0x4,0x6a,0x70, + 0x5,0x76,0x43, 0x7,0x5c,0x51, 0x7,0x5c,0x5b, 0x5,0x76,0x42, + 0x5,0x79,0x40, 0x7,0x5c,0x55, 0x5,0x76,0x44, 0x7,0x5c,0x57, + 0x7,0x5c,0x58, 0x7,0x5c,0x4d, 0x7,0x5c,0x50, 0x5,0x76,0x41, + 0x7,0x5c,0x56, 0x7,0x5c,0x54, 0x7,0x5c,0x52, 0x7,0x5c,0x59, + 0xf,0x6a,0x6d, 0xf,0x6a,0x6e, 0xf,0x6a,0x6f, 0x7,0x5c,0x4e, + 0xf,0x69,0x6a, 0x5,0x78,0x23, 0x5,0x78,0x22, 0x5,0x78,0x21, + 0x7,0x5f,0x40, 0x5,0x78,0x24, 0x7,0x5f,0x42, 0x7,0x5f,0x46, + 0x7,0x5f,0x43, 0x7,0x5f,0x44, 0x7,0x5f,0x49, 0x7,0x5f,0x41, + 0x7,0x5f,0x47, 0x5,0x79,0x42, 0xf,0x6b,0x60, 0xf,0x6b,0x61, + 0xf,0x6b,0x63, 0x7,0x5f,0x45, 0x7,0x5f,0x48, 0x5,0x79,0x43, + 0x7,0x62,0x55, 0x5,0x79,0x41, 0x7,0x62,0x53, 0x7,0x61,0x3e, + 0x7,0x61,0x3d, 0x7,0x61,0x3c, 0xf,0x6c,0x38, 0xf,0x6c,0x39, + 0x7,0x61,0x3f, 0x5,0x7a,0x35, 0x5,0x7a,0x36, 0x7,0x62,0x59, + 0x7,0x62,0x57, 0x7,0x62,0x56, 0x7,0x62,0x58, 0x7,0x62,0x54, + 0xf,0x6c,0x51, 0x7,0x62,0x48, 0x4,0x6d,0x7a, 0x7,0x63,0x68, + 0x5,0x7a,0x72, 0x4,0x6d,0x5f, 0x4,0x6d,0x7c, 0xf,0x6c,0x6b, + 0xf,0x6c,0x6d, 0x5,0x7b,0x46, 0x4,0x6e,0x35, 0x7,0x64,0x58, + 0x7,0x64,0x59, 0x5,0x7c,0x49, 0x7,0x65,0x40, 0x5,0x7b,0x66, + 0x7,0x65,0x60, 0x7,0x65,0x76, 0x5,0x7c,0x4f, 0x5,0x7c,0x3d, + 0x7,0x65,0x5f, 0xf,0x28,0x65, 0x4,0x2b,0x3f, 0x6,0x34,0x49, + 0x6,0x34,0x48, 0xf,0x32,0x4e, 0x5,0x35,0x36, 0x5,0x35,0x34, + 0x4,0x34,0x77, 0x4,0x34,0x76, 0x6,0x44,0x41, 0x4,0x34,0x78, + 0x6,0x44,0x42, 0x6,0x44,0x40, 0x6,0x44,0x3f, 0x6,0x3b,0x63, + 0x6,0x4e,0x3c, 0x5,0x3b,0x71, 0x6,0x4e,0x3d, 0xf,0x3f,0x22, + 0xf,0x3f,0x23, 0xf,0x3f,0x24, 0x5,0x42,0x55, 0x5,0x42,0x51, + 0x5,0x42,0x52, 0x6,0x57,0x6b, 0x6,0x57,0x6a, 0x6,0x57,0x69, + 0x5,0x49,0x4f, 0x6,0x61,0x62, 0x6,0x61,0x66, 0x4,0x46,0x6f, + 0x6,0x61,0x65, 0x6,0x61,0x67, 0x6,0x61,0x63, 0x6,0x61,0x64, + 0x5,0x49,0x50, 0xf,0x4c,0x2b, 0xf,0x4c,0x2c, 0x4,0x46,0x6e, + 0x7,0x28,0x29, 0x7,0x28,0x27, 0x7,0x32,0x5f, 0x5,0x50,0x4e, + 0x7,0x28,0x26, 0x7,0x28,0x28, 0xf,0x51,0x79, 0x7,0x26,0x29, + 0x5,0x57,0x6a, 0x5,0x57,0x6b, 0x5,0x57,0x68, 0x5,0x57,0x69, + 0x4,0x53,0x35, 0x5,0x57,0x67, 0x7,0x32,0x60, 0x7,0x32,0x5c, + 0x7,0x32,0x5d, 0x4,0x53,0x38, 0x4,0x53,0x37, 0x5,0x57,0x6d, + 0x7,0x32,0x5e, 0xf,0x57,0x5d, 0xf,0x57,0x5e, 0xf,0x57,0x5f, + 0x5,0x57,0x6c, 0x7,0x32,0x5b, 0x4,0x58,0x4c, 0x7,0x3b,0x39, + 0xf,0x5c,0x51, 0xf,0x5c,0x52, 0xf,0x5c,0x53, 0x7,0x42,0x51, + 0x5,0x64,0x3d, 0x4,0x5d,0x33, 0x7,0x42,0x50, 0x4,0x5d,0x31, + 0x7,0x42,0x52, 0x5,0x64,0x3c, 0xf,0x60,0x60, 0x7,0x49,0x56, + 0x7,0x49,0x55, 0x4,0x60,0x7e, 0x7,0x49,0x57, 0x7,0x4f,0x69, + 0x5,0x6d,0x4a, 0x7,0x4f,0x6a, 0x7,0x4c,0x26, 0x5,0x71,0x2c, + 0x7,0x4f,0x68, 0x5,0x71,0x2b, 0x5,0x70,0x4d, 0x7,0x54,0x6a, + 0x7,0x54,0x69, 0x5,0x74,0x2a, 0x7,0x5c,0x24, 0x4,0x6e,0x38, + 0x5,0x24,0x75, 0x6,0x29,0x29, 0x4,0x28,0x22, 0x6,0x2e,0x25, + 0xf,0x28,0x66, 0xf,0x28,0x67, 0xf,0x28,0x69, 0xf,0x28,0x6a, + 0x4,0x2b,0x43, 0x6,0x34,0x4b, 0x4,0x2b,0x40, 0x4,0x2b,0x42, + 0x6,0x34,0x4a, 0x5,0x2b,0x40, 0x6,0x34,0x4d, 0x6,0x34,0x4c, + 0x6,0x34,0x4e, 0xf,0x2d,0x3d, 0xf,0x2d,0x3f, 0xf,0x2d,0x42, + 0xf,0x2d,0x43, 0xf,0x2d,0x44, 0xf,0x2d,0x41, 0x4,0x2b,0x41, + 0x5,0x30,0x30, 0x6,0x3b,0x68, 0x5,0x30,0x2c, 0x5,0x30,0x33, + 0x6,0x3b,0x67, 0x5,0x30,0x2d, 0x5,0x30,0x32, 0x6,0x3b,0x66, + 0x4,0x2f,0x6c, 0x4,0x2f,0x6a, 0x4,0x2f,0x6e, 0x5,0x30,0x2e, + 0x6,0x3b,0x70, 0x5,0x30,0x29, 0x6,0x3b,0x6b, 0x5,0x30,0x31, + 0x5,0x30,0x28, 0x6,0x3b,0x6a, 0x5,0x30,0x2f, 0x5,0x30,0x34, + 0x6,0x3b,0x6e, 0x6,0x3b,0x64, 0x5,0x30,0x2b, 0x6,0x3b,0x65, + 0xf,0x32,0x4f, 0x6,0x3b,0x6c, 0x6,0x3b,0x6d, 0x5,0x30,0x2a, + 0x6,0x3b,0x6f, 0x5,0x35,0x37, 0x4,0x34,0x7d, 0x6,0x44,0x45, + 0x5,0x35,0x38, 0x5,0x35,0x39, 0x5,0x35,0x3a, 0x5,0x35,0x40, + 0x4,0x35,0x22, 0xf,0x38,0x3d, 0x4,0x35,0x23, 0x6,0x44,0x4c, + 0x5,0x35,0x3c, 0x4,0x35,0x21, 0x5,0x35,0x3d, 0x6,0x44,0x46, + 0x5,0x35,0x41, 0x6,0x44,0x49, 0x4,0x35,0x24, 0x4,0x34,0x7e, + 0x6,0x44,0x47, 0x6,0x44,0x4a, 0x6,0x44,0x44, 0x6,0x44,0x4b, + 0x6,0x44,0x4d, 0xf,0x38,0x36, 0xf,0x38,0x37, 0xf,0x38,0x38, + 0xf,0x38,0x39, 0xf,0x38,0x3b, 0xf,0x38,0x3c, 0xf,0x38,0x3e, + 0xf,0x38,0x3f, 0xf,0x38,0x40, 0x5,0x35,0x3e, 0x6,0x44,0x4e, + 0x4,0x35,0x25, 0x6,0x44,0x43, 0x5,0x35,0x3f, 0x5,0x35,0x3b, + 0x5,0x3b,0x73, 0x6,0x4e,0x40, 0xf,0x3f,0x28, 0x4,0x3a,0x73, + 0x6,0x4e,0x48, 0x5,0x3c,0x28, 0x5,0x3b,0x78, 0x5,0x3b,0x75, + 0x5,0x3b,0x77, 0x5,0x3b,0x7a, 0x5,0x3c,0x23, 0x5,0x3b,0x7d, + 0x6,0x4e,0x49, 0x6,0x4e,0x3e, 0x6,0x4e,0x43, 0x5,0x3b,0x76, + 0x5,0x3c,0x27, 0x6,0x4e,0x42, 0x6,0x4e,0x4b, 0x6,0x4e,0x4a, + 0x5,0x3b,0x7c, 0x6,0x4e,0x3f, 0x5,0x3b,0x79, 0x5,0x3c,0x21, + 0x6,0x4e,0x4d, 0x6,0x4e,0x44, 0x6,0x4e,0x45, 0x6,0x57,0x6e, + 0x5,0x3c,0x25, 0x5,0x3b,0x7e, 0x6,0x57,0x78, 0x5,0x3c,0x24, + 0x6,0x4e,0x4c, 0x6,0x4e,0x47, 0x5,0x3c,0x22, 0x5,0x3b,0x72, + 0x6,0x4e,0x41, 0xf,0x3f,0x25, 0xf,0x3f,0x26, 0xf,0x3f,0x27, + 0xf,0x3f,0x29, 0x4,0x3a,0x77, 0x6,0x57,0x70, 0x6,0x57,0x6f, + 0x4,0x40,0x5a, 0x4,0x40,0x5c, 0x6,0x57,0x74, 0x4,0x40,0x54, + 0x5,0x42,0x58, 0x5,0x42,0x5b, 0x5,0x42,0x56, 0x4,0x40,0x51, + 0x4,0x40,0x53, 0x5,0x42,0x5c, 0x5,0x42,0x5e, 0x5,0x42,0x5a, + 0x5,0x42,0x57, 0x4,0x40,0x5e, 0x4,0x40,0x50, 0x6,0x57,0x72, + 0x6,0x57,0x73, 0x6,0x57,0x6c, 0x6,0x57,0x6d, 0x6,0x61,0x68, + 0x6,0x57,0x71, 0x6,0x57,0x75, 0x5,0x42,0x59, 0xf,0x45,0x32, + 0xf,0x45,0x33, 0xf,0x45,0x34, 0xf,0x45,0x35, 0xf,0x45,0x36, + 0xf,0x45,0x37, 0xf,0x45,0x38, 0xf,0x45,0x39, 0x6,0x57,0x76, + 0x7,0x49,0x6b, 0x6,0x57,0x77, 0x6,0x57,0x79, 0x5,0x49,0x51, + 0x5,0x49,0x56, 0x5,0x49,0x5b, 0x5,0x49,0x57, 0x5,0x49,0x5c, + 0x4,0x47,0x21, 0x5,0x49,0x55, 0x4,0x46,0x7d, 0x6,0x62,0x23, + 0x5,0x49,0x5f, 0x4,0x46,0x77, 0x5,0x49,0x59, 0x4,0x46,0x74, + 0x6,0x61,0x76, 0x6,0x61,0x6a, 0x6,0x61,0x75, 0x4,0x47,0x22, + 0x5,0x49,0x5e, 0x6,0x61,0x6b, 0x6,0x61,0x71, 0x5,0x49,0x54, + 0x6,0x61,0x7c, 0x5,0x49,0x5d, 0x5,0x49,0x58, 0x6,0x61,0x7b, + 0x6,0x62,0x21, 0x5,0x49,0x60, 0x6,0x61,0x74, 0x6,0x61,0x7d, + 0x6,0x61,0x6d, 0x5,0x49,0x61, 0x5,0x49,0x62, 0x6,0x61,0x72, + 0x6,0x62,0x22, 0x5,0x49,0x5a, 0x6,0x61,0x6c, 0x6,0x61,0x79, + 0x6,0x61,0x7a, 0x6,0x61,0x70, 0x5,0x49,0x52, 0x6,0x61,0x6e, + 0x5,0x49,0x53, 0x6,0x61,0x73, 0xf,0x4c,0x2d, 0xf,0x4c,0x2e, + 0xf,0x4c,0x30, 0xf,0x4c,0x31, 0xf,0x4c,0x32, 0x6,0x61,0x78, + 0x4,0x40,0x58, 0x6,0x61,0x7e, 0x6,0x61,0x6f, 0x4,0x4d,0x2d, + 0x7,0x28,0x43, 0x5,0x50,0x53, 0x4,0x4d,0x2e, 0x4,0x4d,0x2b, + 0x7,0x28,0x38, 0x4,0x4d,0x34, 0x5,0x50,0x5f, 0x7,0x28,0x37, + 0x7,0x28,0x2c, 0x5,0x50,0x51, 0x7,0x28,0x2b, 0x7,0x28,0x35, + 0x7,0x28,0x3f, 0x5,0x50,0x57, 0x4,0x4d,0x32, 0x4,0x4d,0x2a, + 0x7,0x28,0x40, 0x7,0x28,0x34, 0x5,0x50,0x56, 0x7,0x28,0x3b, + 0x7,0x28,0x31, 0x7,0x28,0x3e, 0x5,0x57,0x6e, 0x4,0x4d,0x2c, + 0x4,0x4d,0x29, 0x5,0x50,0x5c, 0x5,0x50,0x5a, 0x5,0x50,0x50, + 0x5,0x50,0x59, 0x5,0x50,0x58, 0x7,0x28,0x2a, 0x5,0x50,0x5b, + 0x4,0x46,0x7a, 0x5,0x50,0x52, 0x5,0x50,0x5e, 0x5,0x50,0x5d, + 0x4,0x4d,0x35, 0x7,0x28,0x46, 0x7,0x28,0x30, 0x7,0x28,0x2d, + 0x7,0x28,0x44, 0x7,0x28,0x39, 0x7,0x28,0x45, 0x7,0x28,0x3c, + 0x7,0x28,0x2f, 0x6,0x61,0x77, 0x7,0x28,0x36, 0x7,0x28,0x3d, + 0x5,0x50,0x54, 0x4,0x4d,0x27, 0x5,0x50,0x4f, 0xf,0x51,0x7a, + 0xf,0x51,0x7b, 0xf,0x51,0x7e, 0xf,0x52,0x21, 0xf,0x52,0x22, + 0xf,0x52,0x23, 0xf,0x52,0x25, 0xf,0x52,0x28, 0xf,0x52,0x29, + 0xf,0x52,0x2a, 0xf,0x52,0x2b, 0x7,0x28,0x33, 0x7,0x28,0x41, + 0x7,0x28,0x3a, 0xf,0x52,0x27, 0x7,0x28,0x32, 0xf,0x4c,0x2f, + 0x5,0x57,0x70, 0x4,0x53,0x45, 0x5,0x57,0x76, 0x5,0x57,0x75, + 0x4,0x53,0x3a, 0x5,0x57,0x74, 0x5,0x57,0x71, 0x7,0x32,0x6e, + 0x7,0x32,0x7d, 0x5,0x57,0x77, 0x4,0x53,0x48, 0x5,0x57,0x7b, + 0x4,0x53,0x49, 0x4,0x53,0x40, 0x4,0x53,0x42, 0x5,0x57,0x7c, + 0x7,0x32,0x6d, 0x4,0x53,0x3b, 0x7,0x32,0x67, 0x4,0x53,0x3f, + 0x7,0x32,0x7c, 0x5,0x57,0x79, 0x5,0x57,0x6f, 0x5,0x58,0x21, + 0x5,0x57,0x72, 0x7,0x3b,0x3a, 0x5,0x57,0x78, 0x7,0x32,0x69, + 0x4,0x53,0x46, 0x5,0x57,0x7a, 0x7,0x32,0x70, 0x7,0x33,0x22, + 0x5,0x57,0x73, 0x7,0x32,0x64, 0x5,0x57,0x7e, 0x7,0x32,0x74, + 0x4,0x53,0x47, 0x5,0x50,0x60, 0x7,0x32,0x6b, 0x7,0x32,0x65, + 0x5,0x57,0x7d, 0x7,0x32,0x76, 0x4,0x53,0x43, 0x7,0x32,0x7b, + 0x7,0x33,0x24, 0x7,0x32,0x62, 0x7,0x32,0x77, 0x7,0x32,0x63, + 0x7,0x32,0x78, 0x7,0x32,0x6f, 0x7,0x32,0x7e, 0x7,0x32,0x72, + 0x7,0x32,0x68, 0x7,0x33,0x23, 0xf,0x57,0x60, 0xf,0x57,0x61, + 0xf,0x57,0x63, 0xf,0x57,0x64, 0xf,0x57,0x65, 0xf,0x57,0x66, + 0x7,0x32,0x79, 0x7,0x32,0x6a, 0x7,0x32,0x7a, 0x7,0x32,0x71, + 0x7,0x32,0x66, 0x7,0x32,0x6c, 0x4,0x58,0x59, 0x5,0x5e,0x29, + 0x5,0x5e,0x2c, 0x4,0x58,0x55, 0x7,0x3b,0x52, 0x7,0x3b,0x44, + 0x4,0x58,0x60, 0x4,0x58,0x5c, 0x7,0x3b,0x48, 0x7,0x3b,0x42, + 0x7,0x3b,0x55, 0x4,0x58,0x5e, 0x7,0x3b,0x46, 0x7,0x28,0x47, + 0x4,0x58,0x50, 0x5,0x5e,0x31, 0x7,0x3b,0x50, 0x7,0x3b,0x3f, + 0x4,0x58,0x5d, 0x7,0x3b,0x4f, 0x5,0x5e,0x2b, 0x5,0x5e,0x2f, + 0x7,0x3b,0x53, 0x4,0x58,0x5a, 0x7,0x3b,0x47, 0x7,0x3b,0x41, + 0x5,0x5e,0x33, 0x4,0x58,0x53, 0x7,0x3b,0x40, 0x4,0x58,0x51, + 0x7,0x3b,0x3e, 0x7,0x3b,0x54, 0x5,0x5e,0x2a, 0x7,0x3b,0x3c, + 0x7,0x3b,0x3b, 0x7,0x3b,0x49, 0x4,0x58,0x5b, 0x5,0x5e,0x2d, + 0x5,0x5e,0x2e, 0x7,0x3b,0x45, 0xf,0x5c,0x54, 0xf,0x5c,0x55, + 0xf,0x5c,0x56, 0xf,0x5c,0x57, 0xf,0x5c,0x58, 0xf,0x5c,0x59, + 0xf,0x5c,0x5a, 0xf,0x5c,0x5c, 0x7,0x3b,0x43, 0x7,0x3b,0x4b, + 0x7,0x3b,0x4e, 0x7,0x3b,0x51, 0x7,0x3b,0x3d, 0x5,0x5e,0x28, + 0x7,0x3b,0x4a, 0x7,0x3b,0x4c, 0x5,0x5e,0x30, 0x4,0x5d,0x3d, + 0x4,0x5d,0x37, 0x7,0x42,0x55, 0x7,0x42,0x61, 0x7,0x42,0x58, + 0x7,0x42,0x68, 0x5,0x64,0x43, 0x5,0x64,0x44, 0x5,0x5e,0x34, + 0x4,0x5d,0x38, 0x5,0x64,0x50, 0x7,0x42,0x59, 0x4,0x5d,0x36, + 0x5,0x64,0x45, 0x4,0x5d,0x35, 0x4,0x5d,0x3a, 0x5,0x64,0x3f, + 0x5,0x64,0x42, 0x5,0x64,0x4d, 0x4,0x5d,0x34, 0x5,0x64,0x4a, + 0x7,0x42,0x56, 0x5,0x64,0x3e, 0x5,0x64,0x41, 0x5,0x64,0x4b, + 0x7,0x42,0x57, 0x7,0x42,0x5c, 0x7,0x42,0x5b, 0x5,0x64,0x40, + 0x7,0x42,0x6f, 0x7,0x42,0x6b, 0x5,0x64,0x4f, 0x7,0x42,0x6e, + 0x5,0x64,0x49, 0x5,0x64,0x4c, 0x7,0x42,0x69, 0x5,0x64,0x46, + 0x7,0x42,0x6c, 0x5,0x64,0x47, 0x7,0x42,0x65, 0x7,0x42,0x62, + 0x7,0x42,0x5d, 0x7,0x42,0x63, 0x7,0x42,0x54, 0x7,0x42,0x5a, + 0x7,0x42,0x53, 0x7,0x42,0x5e, 0x7,0x42,0x6a, 0x7,0x42,0x66, + 0xf,0x60,0x62, 0xf,0x60,0x64, 0xf,0x60,0x65, 0xf,0x60,0x66, + 0xf,0x60,0x68, 0xf,0x60,0x69, 0xf,0x60,0x6a, 0x7,0x42,0x64, + 0x4,0x5d,0x3c, 0x7,0x42,0x67, 0xf,0x60,0x67, 0xf,0x60,0x61, + 0x5,0x64,0x4e, 0x4,0x61,0x28, 0x7,0x49,0x6a, 0x7,0x49,0x59, + 0x7,0x49,0x60, 0x7,0x49,0x6c, 0x7,0x49,0x5a, 0x7,0x49,0x69, + 0x7,0x49,0x6d, 0x4,0x61,0x23, 0x5,0x69,0x42, 0x5,0x69,0x40, + 0x7,0x49,0x62, 0x7,0x49,0x67, 0x7,0x49,0x65, 0x5,0x69,0x44, + 0x7,0x49,0x5d, 0x7,0x49,0x68, 0x7,0x49,0x64, 0x7,0x49,0x66, + 0x7,0x4f,0x6b, 0x7,0x49,0x61, 0x7,0x49,0x6e, 0x7,0x49,0x6f, + 0x7,0x49,0x63, 0x5,0x69,0x45, 0x7,0x49,0x5c, 0x7,0x49,0x5f, + 0x7,0x49,0x58, 0xf,0x63,0x6b, 0xf,0x63,0x6c, 0xf,0x63,0x6d, + 0xf,0x63,0x6f, 0xf,0x63,0x70, 0xf,0x63,0x71, 0xf,0x63,0x72, + 0xf,0x63,0x73, 0xf,0x63,0x74, 0xf,0x63,0x75, 0x7,0x49,0x5b, + 0x4,0x61,0x22, 0x4,0x61,0x27, 0x7,0x49,0x5e, 0x7,0x42,0x70, + 0x7,0x4f,0x75, 0x7,0x4f,0x7a, 0x5,0x6d,0x4d, 0x7,0x4f,0x6c, + 0x4,0x64,0x42, 0x5,0x6d,0x4c, 0x5,0x6d,0x51, 0x7,0x4f,0x78, + 0x7,0x4f,0x70, 0x5,0x6d,0x50, 0x7,0x4f,0x74, 0x5,0x6d,0x52, + 0x5,0x6d,0x53, 0x7,0x4f,0x73, 0x5,0x6d,0x4e, 0x7,0x4f,0x72, + 0x7,0x4f,0x77, 0x7,0x4f,0x71, 0x7,0x4f,0x6d, 0x5,0x6d,0x4f, + 0x7,0x4f,0x6f, 0x7,0x54,0x77, 0x7,0x4f,0x6e, 0x7,0x4f,0x7b, + 0xf,0x66,0x2d, 0xf,0x66,0x2e, 0xf,0x66,0x2f, 0xf,0x66,0x30, + 0xf,0x66,0x31, 0x7,0x4f,0x76, 0x4,0x67,0x2f, 0x4,0x67,0x34, + 0x7,0x54,0x6b, 0x7,0x54,0x70, 0x5,0x71,0x2f, 0x7,0x54,0x75, + 0x7,0x54,0x6e, 0x7,0x54,0x71, 0x5,0x71,0x2e, 0x7,0x54,0x73, + 0x5,0x71,0x2d, 0x5,0x71,0x30, 0x7,0x54,0x6c, 0x4,0x67,0x33, + 0x7,0x54,0x6f, 0x4,0x67,0x35, 0x4,0x67,0x31, 0x7,0x54,0x72, + 0x5,0x71,0x32, 0x7,0x54,0x78, 0x7,0x4f,0x79, 0x7,0x54,0x74, + 0x4,0x67,0x32, 0x7,0x54,0x79, 0x5,0x71,0x31, 0x5,0x71,0x33, + 0x7,0x54,0x76, 0xf,0x68,0x45, 0xf,0x68,0x46, 0xf,0x68,0x47, + 0xf,0x68,0x48, 0xf,0x68,0x49, 0x7,0x54,0x6d, 0x5,0x74,0x2e, + 0x4,0x69,0x3c, 0x5,0x74,0x2c, 0x5,0x74,0x2b, 0x7,0x59,0x23, + 0x7,0x58,0x7c, 0x5,0x74,0x2d, 0x5,0x74,0x31, 0x5,0x74,0x30, + 0x7,0x58,0x7a, 0x5,0x74,0x33, 0x5,0x74,0x35, 0x5,0x74,0x32, + 0x7,0x58,0x79, 0x4,0x69,0x3d, 0x7,0x59,0x26, 0x7,0x59,0x28, + 0x7,0x59,0x27, 0x7,0x58,0x7e, 0x7,0x59,0x21, 0x5,0x74,0x34, + 0x5,0x74,0x36, 0x7,0x59,0x24, 0x7,0x59,0x29, 0x5,0x74,0x2f, + 0x7,0x58,0x7d, 0x7,0x58,0x7b, 0xf,0x69,0x6d, 0xf,0x69,0x6e, + 0x5,0x76,0x46, 0x4,0x6a,0x76, 0x4,0x6a,0x77, 0x7,0x5c,0x5d, + 0x5,0x76,0x47, 0x4,0x6a,0x79, 0x7,0x5c,0x5f, 0x7,0x5c,0x5c, + 0x5,0x76,0x48, 0x7,0x5c,0x62, 0x5,0x76,0x45, 0x7,0x5f,0x4a, + 0x7,0x5c,0x60, 0x4,0x6a,0x7a, 0x7,0x5c,0x61, 0x5,0x76,0x4a, + 0x7,0x59,0x22, 0x5,0x76,0x49, 0xf,0x6a,0x70, 0xf,0x6a,0x71, + 0xf,0x6a,0x72, 0x5,0x78,0x2c, 0x7,0x5f,0x4b, 0x4,0x6b,0x7e, + 0x5,0x78,0x2b, 0x5,0x78,0x29, 0x7,0x5f,0x4c, 0x5,0x78,0x26, + 0x4,0x6c,0x22, 0x7,0x5f,0x4d, 0x5,0x78,0x2a, 0x5,0x78,0x28, + 0x4,0x6c,0x24, 0x5,0x78,0x2d, 0x5,0x78,0x27, 0x5,0x79,0x44, + 0x4,0x6c,0x7e, 0x5,0x79,0x48, 0x5,0x79,0x4a, 0x4,0x6c,0x21, + 0x7,0x61,0x40, 0x5,0x79,0x46, 0x7,0x61,0x44, 0x7,0x61,0x43, + 0x7,0x61,0x45, 0x5,0x79,0x47, 0x5,0x79,0x49, 0x7,0x61,0x41, + 0x5,0x79,0x45, 0x7,0x62,0x5d, 0x7,0x62,0x5b, 0x7,0x62,0x5e, + 0x7,0x62,0x5c, 0x7,0x62,0x5f, 0x7,0x63,0x6e, 0x7,0x63,0x6c, + 0x5,0x7a,0x73, 0x7,0x63,0x6b, 0x7,0x63,0x6f, 0x7,0x62,0x5a, + 0x7,0x63,0x69, 0x7,0x63,0x71, 0x7,0x63,0x6a, 0x7,0x63,0x70, + 0x7,0x63,0x6d, 0x7,0x64,0x5c, 0x4,0x6e,0x3a, 0x7,0x64,0x5d, + 0x5,0x7b,0x47, 0x5,0x7b,0x48, 0x7,0x64,0x5a, 0x7,0x64,0x5b, + 0x5,0x7b,0x67, 0x7,0x65,0x41, 0x7,0x65,0x42, 0x5,0x7b,0x68, + 0x4,0x6e,0x50, 0x7,0x65,0x62, 0x7,0x65,0x61, 0xf,0x6d,0x31, + 0x7,0x66,0x2b, 0x5,0x27,0x65, 0x6,0x2e,0x27, 0x6,0x2e,0x26, + 0x4,0x2b,0x44, 0x6,0x3b,0x72, 0x5,0x30,0x35, 0x6,0x3b,0x75, + 0x6,0x3b,0x74, 0xf,0x38,0x41, 0x6,0x4e,0x4e, 0x6,0x4e,0x50, + 0x5,0x42,0x5f, 0x6,0x57,0x7c, 0x6,0x57,0x7a, 0x6,0x57,0x7d, + 0x6,0x57,0x7b, 0x5,0x49,0x65, 0x5,0x49,0x63, 0x5,0x49,0x64, + 0x6,0x62,0x26, 0x6,0x62,0x24, 0x7,0x28,0x48, 0x5,0x50,0x61, + 0x7,0x28,0x49, 0x7,0x28,0x4a, 0x6,0x62,0x25, 0x5,0x58,0x23, + 0x5,0x58,0x24, 0x5,0x58,0x22, 0x7,0x33,0x25, 0x7,0x33,0x26, + 0x5,0x5e,0x37, 0x5,0x5e,0x36, 0xf,0x5c,0x5d, 0x4,0x5d,0x3e, + 0x4,0x5d,0x3f, 0x7,0x42,0x71, 0x7,0x42,0x73, 0x4,0x5d,0x40, + 0x7,0x42,0x72, 0x5,0x69,0x46, 0x5,0x6d,0x54, 0x7,0x4f,0x7c, + 0x7,0x54,0x7a, 0x7,0x59,0x2b, 0x7,0x59,0x2a, 0x7,0x5f,0x4e, + 0x7,0x65,0x63, 0x4,0x28,0x23, 0x6,0x2e,0x28, 0x4,0x28,0x24, + 0x6,0x34,0x4f, 0x6,0x34,0x50, 0x5,0x2b,0x41, 0xf,0x2d,0x45, + 0x5,0x30,0x36, 0x6,0x3b,0x77, 0x6,0x3b,0x76, 0x5,0x30,0x37, + 0x6,0x44,0x4f, 0x5,0x3c,0x29, 0x6,0x4e,0x53, 0x6,0x4e,0x52, + 0xf,0x3f,0x2a, 0xf,0x3f,0x2b, 0x6,0x4e,0x51, 0x6,0x58,0x23, + 0x6,0x58,0x21, 0x4,0x40,0x5f, 0x6,0x58,0x22, 0x6,0x57,0x7e, + 0xf,0x45,0x3a, 0x4,0x47,0x24, 0x5,0x50,0x62, 0x6,0x62,0x27, + 0x6,0x62,0x28, 0x4,0x58,0x61, 0x7,0x3b,0x56, 0xf,0x5c,0x5e, + 0x4,0x5d,0x41, 0x7,0x42,0x74, 0x7,0x49,0x70, 0x7,0x54,0x7b, + 0x7,0x5c,0x64, 0x5,0x27,0x66, 0x6,0x2e,0x29, 0x6,0x2e,0x2a, + 0x6,0x2e,0x2b, 0x5,0x2b,0x43, 0x6,0x34,0x51, 0x4,0x2b,0x45, + 0x4,0x2b,0x47, 0x5,0x2b,0x45, 0x6,0x34,0x53, 0x5,0x2b,0x44, + 0xf,0x28,0x6b, 0x6,0x34,0x52, 0x5,0x2b,0x42, 0x5,0x2b,0x46, + 0x6,0x3b,0x7d, 0x5,0x30,0x3c, 0x4,0x2f,0x71, 0x6,0x3c,0x21, + 0x6,0x3c,0x25, 0x5,0x30,0x3f, 0x6,0x3c,0x26, 0x6,0x3c,0x27, + 0x4,0x2f,0x70, 0x6,0x3b,0x79, 0x5,0x30,0x40, 0x6,0x3b,0x7b, + 0x5,0x30,0x38, 0x6,0x3c,0x22, 0x6,0x3b,0x7c, 0x6,0x3c,0x23, + 0x6,0x3b,0x7e, 0x5,0x30,0x3b, 0x6,0x3b,0x7a, 0x6,0x3b,0x78, + 0x5,0x30,0x3a, 0xf,0x32,0x50, 0x6,0x3c,0x24, 0x6,0x3c,0x28, + 0x6,0x3c,0x29, 0xf,0x2d,0x48, 0xf,0x2d,0x49, 0xf,0x32,0x52, + 0x4,0x35,0x28, 0x5,0x3c,0x32, 0x4,0x35,0x2b, 0x4,0x3a,0x7c, + 0x5,0x35,0x46, 0x4,0x35,0x29, 0x6,0x44,0x58, 0x5,0x35,0x47, + 0x5,0x35,0x4a, 0x5,0x35,0x44, 0x5,0x35,0x45, 0x5,0x35,0x43, + 0x6,0x44,0x59, 0x6,0x44,0x5a, 0x5,0x35,0x42, 0x6,0x44,0x53, + 0x6,0x44,0x55, 0x6,0x44,0x54, 0x6,0x44,0x51, 0x6,0x44,0x50, + 0x6,0x44,0x57, 0x6,0x44,0x52, 0xf,0x2d,0x46, 0xf,0x38,0x45, + 0x5,0x35,0x48, 0x6,0x44,0x56, 0x5,0x35,0x49, 0x5,0x3c,0x31, + 0x6,0x4e,0x5b, 0x6,0x4e,0x59, 0x5,0x3c,0x2e, 0x6,0x4e,0x57, + 0x5,0x3c,0x2f, 0x5,0x3c,0x33, 0x4,0x3a,0x7e, 0x6,0x4e,0x58, + 0x6,0x4e,0x54, 0x4,0x3a,0x7d, 0x6,0x4e,0x56, 0x5,0x3c,0x30, + 0x5,0x3c,0x2d, 0x5,0x3c,0x2b, 0x5,0x42,0x64, 0x5,0x3c,0x2a, + 0xf,0x38,0x44, 0xf,0x3f,0x2e, 0x6,0x4e,0x55, 0x6,0x4e,0x5a, + 0x6,0x4e,0x5c, 0x5,0x3c,0x2c, 0xf,0x38,0x43, 0x5,0x42,0x6a, + 0x5,0x42,0x62, 0x5,0x42,0x66, 0x4,0x40,0x65, 0x5,0x42,0x6b, + 0x5,0x42,0x63, 0x5,0x42,0x67, 0x4,0x40,0x63, 0x5,0x42,0x65, + 0x5,0x42,0x69, 0x6,0x58,0x2f, 0x4,0x40,0x64, 0x6,0x58,0x2a, + 0x6,0x58,0x28, 0x6,0x58,0x30, 0x5,0x42,0x68, 0x5,0x42,0x60, + 0x6,0x58,0x24, 0x6,0x58,0x27, 0x6,0x58,0x2d, 0xf,0x3f,0x2c, + 0xf,0x3f,0x2d, 0xf,0x3f,0x2f, 0xf,0x3f,0x30, 0xf,0x45,0x3b, + 0x6,0x58,0x26, 0x6,0x58,0x31, 0x6,0x58,0x25, 0x6,0x58,0x29, + 0x5,0x42,0x61, 0xf,0x45,0x3e, 0x4,0x47,0x30, 0x4,0x47,0x2c, + 0x6,0x62,0x2d, 0x6,0x62,0x33, 0x4,0x47,0x29, 0x5,0x49,0x66, + 0x5,0x49,0x69, 0x4,0x47,0x28, 0x5,0x49,0x68, 0x5,0x3c,0x34, + 0x6,0x62,0x34, 0x5,0x49,0x6a, 0x6,0x62,0x2b, 0x6,0x62,0x29, + 0x6,0x62,0x2a, 0x6,0x62,0x32, 0x6,0x62,0x31, 0x5,0x49,0x67, + 0x6,0x62,0x2f, 0x5,0x49,0x6b, 0x6,0x62,0x30, 0x6,0x62,0x2c, + 0x4,0x47,0x33, 0x6,0x62,0x35, 0x6,0x62,0x2e, 0xf,0x4c,0x34, + 0xf,0x4c,0x36, 0xf,0x4c,0x37, 0x4,0x47,0x2f, 0xf,0x45,0x3c, + 0xf,0x45,0x3f, 0x5,0x50,0x66, 0x7,0x28,0x54, 0x4,0x4d,0x41, + 0x5,0x50,0x69, 0x7,0x28,0x57, 0x4,0x47,0x32, 0x7,0x28,0x56, + 0x5,0x50,0x65, 0x4,0x4d,0x38, 0x7,0x28,0x55, 0x7,0x33,0x28, + 0x5,0x50,0x67, 0x7,0x28,0x5a, 0x7,0x28,0x4b, 0x4,0x4d,0x45, + 0x4,0x4d,0x3b, 0x4,0x4d,0x3d, 0x7,0x28,0x53, 0x4,0x4d,0x44, + 0x4,0x4d,0x43, 0x5,0x50,0x63, 0x7,0x28,0x58, 0x7,0x28,0x52, + 0x7,0x28,0x4c, 0x5,0x50,0x64, 0x7,0x28,0x4f, 0x5,0x50,0x68, + 0x7,0x28,0x51, 0x7,0x28,0x50, 0x7,0x28,0x4d, 0xf,0x4c,0x35, + 0xf,0x52,0x2d, 0x7,0x28,0x4e, 0x7,0x28,0x59, 0x5,0x58,0x2c, + 0x5,0x58,0x2b, 0x7,0x33,0x2b, 0x5,0x58,0x27, 0x5,0x58,0x2a, + 0x7,0x33,0x27, 0x4,0x53,0x51, 0x7,0x33,0x29, 0x4,0x53,0x54, + 0x7,0x3b,0x62, 0x5,0x58,0x29, 0x5,0x58,0x28, 0x7,0x33,0x2a, + 0x4,0x53,0x4e, 0x7,0x33,0x2c, 0x7,0x33,0x2f, 0x4,0x53,0x4d, + 0x5,0x58,0x25, 0x7,0x33,0x30, 0x5,0x58,0x26, 0x7,0x33,0x2e, + 0xf,0x52,0x2c, 0x7,0x33,0x2d, 0x5,0x5e,0x3e, 0x5,0x5e,0x3f, + 0x7,0x3b,0x57, 0x5,0x5e,0x3b, 0x7,0x3b,0x5d, 0x7,0x3b,0x64, + 0x4,0x58,0x66, 0x5,0x5e,0x38, 0x5,0x5e,0x39, 0x5,0x5e,0x3d, + 0x5,0x5e,0x3c, 0x7,0x3b,0x5f, 0x7,0x3b,0x5b, 0x7,0x3b,0x63, + 0x7,0x42,0x7b, 0x7,0x3b,0x5c, 0x7,0x28,0x5b, 0x7,0x3b,0x5e, + 0x7,0x3b,0x60, 0x5,0x5e,0x40, 0x7,0x3b,0x58, 0x7,0x3b,0x5a, + 0x5,0x5e,0x3a, 0xf,0x57,0x67, 0xf,0x57,0x68, 0xf,0x57,0x69, + 0xf,0x57,0x6a, 0x7,0x42,0x75, 0x4,0x5d,0x45, 0x7,0x42,0x7c, + 0x7,0x42,0x7e, 0x5,0x64,0x5b, 0x5,0x64,0x57, 0x7,0x42,0x7d, + 0x4,0x5d,0x4b, 0x5,0x64,0x54, 0x5,0x64,0x55, 0x5,0x64,0x5f, + 0x4,0x5d,0x4d, 0x4,0x5d,0x42, 0x7,0x42,0x7a, 0x5,0x64,0x53, + 0x4,0x5d,0x47, 0x4,0x5d,0x4c, 0x5,0x64,0x5d, 0x7,0x42,0x79, + 0x7,0x42,0x77, 0x5,0x64,0x51, 0x4,0x5d,0x43, 0x5,0x5e,0x42, + 0x5,0x64,0x52, 0x7,0x42,0x78, 0x7,0x43,0x23, 0x7,0x42,0x76, + 0x5,0x64,0x59, 0x5,0x64,0x5a, 0x5,0x5e,0x41, 0x5,0x64,0x5c, + 0x5,0x64,0x5e, 0x5,0x64,0x58, 0xf,0x5c,0x60, 0x7,0x49,0x76, + 0x5,0x69,0x49, 0x5,0x69,0x4a, 0x4,0x61,0x29, 0x7,0x49,0x7b, + 0x7,0x49,0x7c, 0x5,0x69,0x47, 0x5,0x69,0x48, 0x7,0x49,0x72, + 0x7,0x49,0x73, 0x7,0x49,0x75, 0x7,0x49,0x79, 0x7,0x49,0x7a, + 0x7,0x49,0x74, 0x7,0x49,0x78, 0x4,0x61,0x2b, 0x7,0x49,0x77, + 0x7,0x43,0x21, 0xf,0x60,0x6b, 0xf,0x60,0x6c, 0xf,0x63,0x76, + 0x7,0x4f,0x7d, 0x5,0x6d,0x58, 0x7,0x50,0x26, 0x5,0x6d,0x5b, + 0x5,0x71,0x34, 0x5,0x6d,0x55, 0x4,0x64,0x45, 0x7,0x50,0x23, + 0x5,0x6d,0x56, 0x7,0x50,0x22, 0x7,0x54,0x7c, 0x7,0x4f,0x7e, + 0x5,0x6d,0x59, 0x7,0x49,0x71, 0x5,0x6d,0x5a, 0x5,0x6d,0x5c, + 0x7,0x50,0x24, 0xf,0x66,0x34, 0x7,0x50,0x21, 0x5,0x6d,0x5d, + 0x7,0x55,0x22, 0x7,0x55,0x24, 0x5,0x71,0x36, 0x4,0x67,0x36, + 0x7,0x55,0x26, 0x7,0x55,0x25, 0x5,0x71,0x35, 0x7,0x54,0x7e, + 0x7,0x55,0x21, 0x4,0x67,0x37, 0x7,0x55,0x23, 0x7,0x59,0x31, + 0x7,0x54,0x7d, 0xf,0x66,0x33, 0x4,0x69,0x41, 0x7,0x59,0x2e, + 0x4,0x69,0x40, 0x4,0x69,0x3f, 0x5,0x74,0x37, 0x7,0x59,0x2c, + 0x7,0x59,0x2d, 0x7,0x59,0x30, 0x7,0x59,0x2f, 0x5,0x78,0x2e, + 0xf,0x69,0x6f, 0x7,0x5f,0x51, 0x7,0x5f,0x50, 0x7,0x5f,0x4f, + 0x5,0x79,0x4b, 0x7,0x61,0x48, 0x7,0x61,0x47, 0x7,0x61,0x46, + 0x7,0x62,0x61, 0x5,0x7a,0x37, 0x7,0x62,0x62, 0x7,0x62,0x60, + 0x7,0x64,0x5f, 0x7,0x63,0x73, 0x7,0x63,0x72, 0x7,0x64,0x5e, + 0x5,0x7b,0x7e, 0x7,0x65,0x64, 0x7,0x66,0x2c, 0x5,0x7c,0x4b, + 0x7,0x66,0x4d, 0x5,0x24,0x76, 0x6,0x2e,0x2c, 0x4,0x2b,0x48, + 0x5,0x30,0x41, 0x4,0x2f,0x74, 0x6,0x3c,0x2a, 0x6,0x44,0x5b, + 0xf,0x38,0x46, 0xf,0x3f,0x31, 0xf,0x3f,0x32, 0x6,0x58,0x32, + 0x4,0x47,0x34, 0x6,0x62,0x36, 0x6,0x62,0x37, 0x6,0x62,0x38, + 0xf,0x4c,0x38, 0xf,0x4c,0x39, 0x7,0x28,0x5c, 0xf,0x4c,0x3a, + 0xf,0x52,0x30, 0x7,0x33,0x31, 0x7,0x33,0x32, 0xf,0x52,0x2f, + 0x7,0x3b,0x65, 0xf,0x60,0x6d, 0xf,0x60,0x6e, 0x5,0x69,0x4b, + 0x7,0x50,0x27, 0x7,0x55,0x27, 0x5,0x27,0x67, 0x6,0x2e,0x2d, + 0x4,0x2f,0x77, 0x5,0x30,0x42, 0xf,0x32,0x53, 0x5,0x35,0x4d, + 0x5,0x35,0x4e, 0x6,0x44,0x5c, 0x6,0x44,0x5d, 0x5,0x35,0x50, + 0x5,0x35,0x4b, 0xf,0x38,0x47, 0xf,0x38,0x49, 0xf,0x38,0x4b, + 0x4,0x35,0x32, 0x4,0x35,0x36, 0x5,0x35,0x4c, 0x5,0x35,0x4f, + 0x6,0x4e,0x5f, 0x4,0x3b,0x25, 0x6,0x4e,0x62, 0x6,0x4e,0x61, + 0x5,0x3c,0x36, 0x6,0x4e,0x5e, 0x4,0x3b,0x24, 0x6,0x4e,0x5d, + 0x6,0x58,0x36, 0x5,0x42,0x6d, 0x5,0x42,0x6f, 0x5,0x42,0x6e, + 0x6,0x58,0x33, 0x6,0x58,0x37, 0x5,0x42,0x70, 0xf,0x45,0x40, + 0xf,0x45,0x41, 0xf,0x45,0x42, 0x6,0x58,0x35, 0x6,0x62,0x39, + 0x5,0x49,0x71, 0x5,0x49,0x6e, 0x5,0x49,0x72, 0x4,0x47,0x37, + 0x6,0x62,0x3a, 0xf,0x4c,0x3b, 0xf,0x4c,0x3c, 0x5,0x49,0x6f, + 0x6,0x62,0x3b, 0x5,0x49,0x70, 0x4,0x4d,0x49, 0x7,0x28,0x5f, + 0x5,0x50,0x6c, 0x4,0x4d,0x4b, 0x5,0x50,0x6b, 0x7,0x28,0x63, + 0x5,0x50,0x6d, 0x6,0x58,0x34, 0x7,0x28,0x62, 0x5,0x50,0x6a, + 0x5,0x50,0x6e, 0xf,0x52,0x31, 0x7,0x28,0x60, 0x7,0x28,0x5e, + 0x7,0x28,0x5d, 0x7,0x28,0x61, 0x5,0x58,0x30, 0x5,0x58,0x2f, + 0x5,0x58,0x2e, 0x4,0x53,0x57, 0x7,0x33,0x34, 0x5,0x58,0x34, + 0x7,0x3b,0x67, 0x4,0x53,0x58, 0x4,0x53,0x5e, 0x4,0x53,0x5d, + 0x5,0x58,0x31, 0x5,0x58,0x35, 0x7,0x33,0x33, 0x5,0x58,0x2d, + 0x5,0x58,0x33, 0xf,0x57,0x6b, 0xf,0x57,0x6c, 0xf,0x57,0x6d, + 0x7,0x3b,0x66, 0x5,0x64,0x60, 0x5,0x5e,0x45, 0x5,0x5e,0x44, + 0x7,0x3b,0x6a, 0x7,0x3b,0x69, 0x7,0x3b,0x6b, 0x7,0x3b,0x68, + 0xf,0x5c,0x61, 0xf,0x5c,0x62, 0x5,0x64,0x62, 0x4,0x5d,0x51, + 0x4,0x5d,0x4f, 0x7,0x43,0x24, 0x5,0x64,0x61, 0xf,0x60,0x6f, + 0xf,0x60,0x70, 0xf,0x60,0x71, 0x7,0x43,0x25, 0x7,0x49,0x7d, + 0x7,0x49,0x7e, 0x5,0x6d,0x5f, 0x7,0x50,0x29, 0x7,0x50,0x28, + 0xf,0x66,0x35, 0x5,0x6d,0x5e, 0xf,0x68,0x4b, 0xf,0x68,0x4c, + 0x7,0x55,0x28, 0x4,0x69,0x43, 0x5,0x74,0x39, 0x4,0x69,0x42, + 0xf,0x69,0x70, 0xf,0x69,0x71, 0x5,0x78,0x2f, 0x7,0x5f,0x53, + 0xf,0x6b,0x64, 0x7,0x5f,0x52, 0x5,0x79,0x4d, 0x5,0x79,0x4c, + 0x7,0x61,0x49, 0x4,0x6d,0x21, 0x5,0x7a,0x74, 0x4,0x6e,0x3b, + 0x5,0x7c,0x44, 0x7,0x66,0x54, 0x6,0x2e,0x2e, 0x6,0x2e,0x2f, + 0x6,0x34,0x54, 0x5,0x2b,0x48, 0x4,0x2f,0x78, 0x6,0x3c,0x2c, + 0x4,0x2f,0x79, 0x6,0x3c,0x2b, 0x6,0x44,0x67, 0x4,0x35,0x3b, + 0x5,0x35,0x53, 0x5,0x35,0x52, 0x6,0x44,0x5f, 0x6,0x44,0x63, + 0x4,0x35,0x37, 0x6,0x44,0x64, 0x5,0x35,0x51, 0x6,0x44,0x60, + 0xf,0x38,0x4d, 0xf,0x38,0x4e, 0xf,0x38,0x4f, 0x4,0x35,0x3c, + 0x6,0x44,0x66, 0x6,0x44,0x5e, 0x6,0x44,0x62, 0x6,0x44,0x65, + 0x6,0x44,0x61, 0x5,0x3c,0x37, 0x4,0x3b,0x26, 0x6,0x4e,0x64, + 0x6,0x4e,0x67, 0x5,0x3c,0x38, 0x6,0x4e,0x63, 0x6,0x4e,0x66, + 0x6,0x4e,0x69, 0x6,0x4e,0x65, 0x4,0x3b,0x27, 0x4,0x3b,0x28, + 0x6,0x4e,0x68, 0xf,0x3f,0x33, 0x5,0x42,0x73, 0x5,0x42,0x71, + 0x5,0x42,0x72, 0x6,0x58,0x38, 0x6,0x62,0x3e, 0x5,0x49,0x75, + 0x4,0x47,0x39, 0x6,0x62,0x40, 0x5,0x49,0x73, 0x5,0x49,0x74, + 0x6,0x62,0x3d, 0x6,0x62,0x41, 0x6,0x62,0x3c, 0x6,0x62,0x3f, + 0x7,0x28,0x66, 0x5,0x50,0x75, 0x7,0x28,0x67, 0x5,0x50,0x74, + 0x5,0x50,0x70, 0x5,0x50,0x6f, 0x4,0x4d,0x50, 0x4,0x4d,0x52, + 0x4,0x4d,0x4d, 0x7,0x28,0x69, 0x4,0x4d,0x54, 0x5,0x50,0x72, + 0x7,0x28,0x68, 0x7,0x28,0x6a, 0x5,0x50,0x71, 0x7,0x28,0x64, + 0x7,0x28,0x65, 0x5,0x50,0x73, 0x7,0x33,0x38, 0x7,0x33,0x37, + 0x4,0x53,0x5f, 0x5,0x58,0x36, 0x4,0x53,0x63, 0x5,0x58,0x39, + 0x5,0x58,0x3b, 0x4,0x53,0x60, 0x7,0x33,0x36, 0x7,0x33,0x35, + 0x5,0x58,0x37, 0x5,0x58,0x38, 0x5,0x58,0x3a, 0x7,0x33,0x39, + 0x5,0x5e,0x46, 0x7,0x3b,0x6d, 0x7,0x3b,0x73, 0x7,0x3b,0x6c, + 0x5,0x5e,0x4a, 0x5,0x5e,0x49, 0x7,0x3b,0x6e, 0x7,0x33,0x3a, + 0x5,0x5e,0x48, 0x7,0x3b,0x6f, 0x7,0x3b,0x70, 0x7,0x3b,0x71, + 0x4,0x58,0x6c, 0x7,0x3b,0x74, 0x7,0x3b,0x72, 0x5,0x5e,0x47, + 0x7,0x43,0x27, 0x7,0x43,0x28, 0x4,0x5d,0x52, 0x7,0x43,0x26, + 0x7,0x43,0x29, 0x4,0x61,0x35, 0x5,0x69,0x4c, 0x4,0x61,0x32, + 0x4,0x61,0x33, 0x7,0x4a,0x21, 0x7,0x4a,0x22, 0x7,0x4a,0x23, + 0x7,0x4a,0x24, 0x4,0x61,0x36, 0x7,0x50,0x2a, 0x5,0x71,0x37, + 0x7,0x55,0x29, 0x5,0x74,0x3a, 0x4,0x69,0x44, 0x7,0x5c,0x65, + 0x5,0x78,0x30, 0x7,0x62,0x63, 0x4,0x6d,0x60, 0x7,0x64,0x60, + 0x7,0x64,0x61, 0x5,0x7b,0x69, 0x7,0x65,0x43, 0x5,0x23,0x27, + 0x5,0x23,0x28, 0x6,0x2e,0x30, 0x6,0x3c,0x33, 0x4,0x30,0x21, + 0x4,0x2f,0x7b, 0x4,0x2f,0x7a, 0x4,0x30,0x22, 0x5,0x30,0x43, + 0x6,0x3c,0x30, 0x6,0x3c,0x31, 0x6,0x3c,0x2f, 0x6,0x3c,0x32, + 0x6,0x3c,0x2e, 0x4,0x35,0x40, 0x6,0x44,0x6a, 0x6,0x44,0x73, + 0x4,0x35,0x3e, 0x6,0x44,0x6f, 0x5,0x35,0x5c, 0x5,0x35,0x59, + 0x6,0x44,0x71, 0x4,0x35,0x42, 0x5,0x35,0x54, 0x4,0x35,0x46, + 0x6,0x44,0x79, 0x5,0x35,0x55, 0x6,0x44,0x77, 0x6,0x44,0x6b, + 0x6,0x44,0x78, 0x5,0x35,0x58, 0x6,0x44,0x74, 0x6,0x44,0x75, + 0x6,0x44,0x6e, 0x6,0x44,0x7a, 0xf,0x38,0x50, 0xf,0x38,0x51, + 0xf,0x38,0x53, 0xf,0x38,0x54, 0xf,0x38,0x55, 0xf,0x38,0x56, + 0x6,0x44,0x72, 0x6,0x44,0x69, 0x6,0x44,0x68, 0x6,0x44,0x76, + 0x6,0x44,0x6c, 0x5,0x35,0x5a, 0x6,0x4e,0x74, 0x4,0x3b,0x32, + 0x4,0x3b,0x2e, 0x5,0x3c,0x3b, 0x6,0x4e,0x6f, 0x6,0x4e,0x6e, + 0x6,0x4e,0x71, 0x6,0x4e,0x6a, 0x4,0x3b,0x2d, 0x6,0x4e,0x78, + 0x4,0x3b,0x38, 0x4,0x3b,0x39, 0x5,0x3c,0x3c, 0x6,0x4e,0x6d, + 0x6,0x4e,0x76, 0x6,0x4e,0x70, 0x6,0x4e,0x77, 0x4,0x3b,0x37, + 0x5,0x3c,0x39, 0x5,0x3c,0x3a, 0xf,0x3f,0x34, 0xf,0x3f,0x35, + 0xf,0x3f,0x36, 0xf,0x3f,0x37, 0xf,0x3f,0x38, 0xf,0x3f,0x39, + 0xf,0x3f,0x3a, 0xf,0x3f,0x3c, 0x6,0x4e,0x72, 0x6,0x4e,0x75, + 0x6,0x4e,0x6c, 0x6,0x4e,0x79, 0x6,0x4e,0x73, 0x5,0x42,0x75, + 0x4,0x40,0x68, 0x4,0x40,0x6a, 0x6,0x58,0x46, 0x5,0x42,0x76, + 0x5,0x3c,0x3d, 0x5,0x42,0x79, 0x4,0x40,0x71, 0x4,0x40,0x70, + 0x6,0x58,0x40, 0x6,0x58,0x4b, 0x6,0x58,0x3d, 0x6,0x58,0x49, + 0x4,0x40,0x69, 0x4,0x40,0x6b, 0x5,0x42,0x7c, 0x5,0x42,0x74, + 0x4,0x40,0x73, 0x6,0x58,0x43, 0x6,0x58,0x3c, 0x6,0x58,0x47, + 0x6,0x58,0x42, 0x6,0x58,0x3f, 0x4,0x40,0x72, 0x5,0x42,0x7a, + 0x6,0x58,0x48, 0x5,0x42,0x78, 0x5,0x42,0x77, 0x6,0x58,0x44, + 0xf,0x45,0x43, 0xf,0x45,0x45, 0xf,0x45,0x46, 0x6,0x58,0x4a, + 0x5,0x42,0x7b, 0x6,0x58,0x39, 0x6,0x58,0x3b, 0x4,0x40,0x6f, + 0x6,0x58,0x3a, 0x6,0x58,0x45, 0x6,0x58,0x3e, 0x6,0x62,0x4e, + 0x4,0x47,0x3f, 0x5,0x49,0x7a, 0x4,0x47,0x3b, 0x5,0x49,0x78, + 0x5,0x49,0x7b, 0x4,0x47,0x3e, 0x4,0x47,0x48, 0x6,0x62,0x42, + 0x6,0x62,0x4c, 0x4,0x47,0x41, 0x6,0x62,0x53, 0x4,0x47,0x44, + 0x6,0x62,0x4f, 0x4,0x47,0x47, 0x6,0x62,0x46, 0x5,0x49,0x79, + 0x6,0x62,0x51, 0x6,0x62,0x45, 0x4,0x47,0x49, 0x6,0x62,0x50, + 0x6,0x62,0x44, 0x5,0x49,0x76, 0x5,0x49,0x77, 0xf,0x4c,0x3d, + 0xf,0x4c,0x3e, 0xf,0x4c,0x3f, 0xf,0x4c,0x40, 0xf,0x4c,0x42, + 0xf,0x4c,0x43, 0xf,0x4c,0x44, 0xf,0x4c,0x45, 0x6,0x62,0x48, + 0x4,0x47,0x4b, 0x6,0x62,0x4a, 0x5,0x42,0x7d, 0x6,0x62,0x4b, + 0x6,0x62,0x4d, 0x6,0x62,0x43, 0x6,0x62,0x52, 0x6,0x62,0x49, + 0x7,0x29,0x21, 0x5,0x51,0x2a, 0x7,0x28,0x6b, 0x5,0x50,0x7a, + 0x5,0x51,0x22, 0x7,0x28,0x71, 0x7,0x28,0x74, 0x7,0x29,0x22, + 0x7,0x28,0x7c, 0x7,0x28,0x70, 0x5,0x51,0x27, 0x4,0x4d,0x57, + 0x5,0x51,0x29, 0x5,0x51,0x23, 0x5,0x50,0x7b, 0x5,0x50,0x7e, + 0x7,0x28,0x78, 0x5,0x51,0x24, 0x4,0x4d,0x5d, 0x5,0x51,0x26, + 0x4,0x4d,0x62, 0x7,0x29,0x24, 0x7,0x28,0x77, 0x7,0x28,0x6f, + 0x5,0x50,0x78, 0x5,0x50,0x7c, 0x7,0x28,0x7d, 0x7,0x28,0x6d, + 0x5,0x51,0x25, 0x5,0x50,0x7d, 0x5,0x50,0x77, 0x5,0x50,0x79, + 0x5,0x50,0x76, 0xf,0x52,0x32, 0xf,0x52,0x33, 0xf,0x52,0x34, + 0xf,0x52,0x35, 0xf,0x52,0x37, 0xf,0x52,0x39, 0xf,0x52,0x3a, + 0x7,0x28,0x76, 0x7,0x28,0x75, 0x7,0x28,0x6c, 0x7,0x28,0x72, + 0xf,0x52,0x38, 0x5,0x51,0x21, 0x7,0x28,0x7b, 0x7,0x28,0x6e, + 0x5,0x51,0x28, 0x7,0x29,0x23, 0x7,0x28,0x7e, 0x7,0x28,0x7a, + 0x7,0x28,0x73, 0x7,0x33,0x46, 0x5,0x58,0x40, 0x4,0x53,0x71, + 0x7,0x33,0x52, 0x4,0x53,0x68, 0x4,0x53,0x65, 0x4,0x53,0x6c, + 0x7,0x33,0x49, 0x7,0x33,0x51, 0x7,0x33,0x43, 0x5,0x58,0x3d, + 0x7,0x33,0x42, 0x5,0x58,0x3c, 0x7,0x33,0x3c, 0x4,0x53,0x70, + 0x4,0x53,0x67, 0x7,0x33,0x45, 0x4,0x53,0x6f, 0x7,0x33,0x3d, + 0x4,0x53,0x6e, 0x7,0x33,0x47, 0x7,0x33,0x4e, 0x4,0x53,0x66, + 0x7,0x33,0x50, 0x7,0x33,0x3e, 0x4,0x53,0x69, 0x7,0x33,0x3b, + 0x7,0x33,0x53, 0x7,0x33,0x40, 0x7,0x33,0x3f, 0x7,0x33,0x48, + 0x7,0x33,0x4a, 0x5,0x58,0x3f, 0x7,0x33,0x4c, 0x4,0x53,0x6d, + 0x7,0x33,0x44, 0x5,0x58,0x3e, 0xf,0x57,0x6e, 0xf,0x57,0x6f, + 0xf,0x57,0x70, 0xf,0x57,0x71, 0xf,0x57,0x72, 0xf,0x57,0x73, + 0xf,0x57,0x74, 0xf,0x57,0x75, 0xf,0x57,0x76, 0xf,0x57,0x77, + 0xf,0x57,0x78, 0x7,0x33,0x54, 0x7,0x33,0x41, 0x7,0x33,0x4b, + 0x4,0x58,0x6e, 0x5,0x5e,0x52, 0x5,0x5e,0x51, 0x7,0x3b,0x7d, + 0x4,0x58,0x6f, 0x5,0x5e,0x54, 0x4,0x58,0x71, 0x7,0x3b,0x79, + 0x4,0x58,0x6d, 0x5,0x5e,0x4d, 0x5,0x5e,0x53, 0x5,0x5e,0x4e, + 0x7,0x3b,0x76, 0x7,0x3c,0x25, 0x4,0x58,0x72, 0x7,0x43,0x2a, + 0x5,0x5e,0x4f, 0x7,0x3c,0x21, 0x7,0x3b,0x77, 0x5,0x5e,0x56, + 0x7,0x3c,0x27, 0x7,0x3b,0x7c, 0x7,0x3b,0x78, 0x5,0x5e,0x50, + 0x4,0x58,0x74, 0x7,0x3b,0x7b, 0x7,0x3b,0x7e, 0x7,0x3c,0x22, + 0x7,0x3c,0x23, 0x4,0x58,0x73, 0x5,0x5e,0x4b, 0x7,0x3c,0x26, + 0x5,0x5e,0x4c, 0x7,0x3c,0x24, 0x7,0x3b,0x75, 0xf,0x5c,0x63, + 0xf,0x5c,0x64, 0xf,0x5c,0x65, 0xf,0x5c,0x66, 0xf,0x5c,0x67, + 0xf,0x5c,0x68, 0xf,0x5c,0x69, 0xf,0x5c,0x6a, 0xf,0x5c,0x6b, + 0x7,0x3c,0x28, 0x7,0x3c,0x29, 0x7,0x3b,0x7a, 0x4,0x5d,0x5e, + 0x4,0x5d,0x56, 0x7,0x43,0x37, 0x4,0x5d,0x58, 0x7,0x43,0x35, + 0x5,0x64,0x68, 0x7,0x43,0x3a, 0x7,0x43,0x2b, 0x4,0x5d,0x60, + 0x5,0x64,0x66, 0x5,0x58,0x41, 0x4,0x5d,0x59, 0x5,0x64,0x67, + 0x7,0x43,0x38, 0x7,0x43,0x32, 0x5,0x64,0x64, 0x4,0x5d,0x53, + 0x7,0x43,0x3b, 0x4,0x5d,0x55, 0x5,0x64,0x65, 0x4,0x5d,0x5d, + 0x7,0x43,0x39, 0x7,0x43,0x2f, 0x7,0x43,0x33, 0x7,0x4a,0x2a, + 0x7,0x43,0x30, 0x4,0x5d,0x5c, 0x7,0x43,0x34, 0x7,0x43,0x31, + 0x7,0x43,0x3c, 0x7,0x43,0x2c, 0x7,0x43,0x2d, 0xf,0x60,0x72, + 0xf,0x60,0x75, 0x7,0x43,0x36, 0x4,0x5d,0x5f, 0x7,0x43,0x2e, + 0x5,0x69,0x4d, 0x5,0x69,0x4f, 0x7,0x4a,0x2f, 0x4,0x61,0x3e, + 0x7,0x4a,0x2c, 0x7,0x4a,0x2e, 0x4,0x61,0x43, 0x4,0x61,0x39, + 0x5,0x69,0x50, 0x4,0x61,0x41, 0x7,0x4a,0x34, 0x4,0x61,0x42, + 0x5,0x69,0x4e, 0x4,0x61,0x3f, 0x7,0x4a,0x26, 0x7,0x4a,0x29, + 0x7,0x43,0x3d, 0x7,0x4a,0x28, 0x7,0x4a,0x35, 0x7,0x50,0x33, + 0x7,0x4a,0x33, 0x4,0x61,0x3c, 0x5,0x6d,0x60, 0x7,0x4a,0x27, + 0xf,0x63,0x78, 0xf,0x63,0x79, 0xf,0x63,0x7a, 0x4,0x61,0x44, + 0x7,0x4a,0x2b, 0x7,0x50,0x35, 0x7,0x4a,0x30, 0x7,0x4a,0x31, + 0x7,0x4a,0x2d, 0x7,0x4a,0x32, 0x4,0x61,0x38, 0xf,0x60,0x74, + 0x4,0x64,0x4a, 0x4,0x64,0x4b, 0x5,0x6d,0x62, 0x5,0x6d,0x61, + 0x7,0x50,0x2d, 0x5,0x6d,0x63, 0x7,0x50,0x2f, 0x4,0x64,0x49, + 0x7,0x50,0x2b, 0x5,0x69,0x53, 0x7,0x50,0x32, 0x7,0x50,0x2e, + 0x7,0x50,0x34, 0x7,0x50,0x36, 0x7,0x50,0x2c, 0x7,0x50,0x30, + 0xf,0x66,0x36, 0xf,0x66,0x37, 0xf,0x66,0x38, 0xf,0x66,0x39, + 0x7,0x50,0x38, 0x7,0x50,0x37, 0x7,0x50,0x39, 0x7,0x55,0x2a, + 0x4,0x67,0x42, 0x7,0x55,0x34, 0x7,0x55,0x2d, 0x7,0x55,0x33, + 0x4,0x67,0x38, 0x7,0x55,0x2e, 0x5,0x71,0x3d, 0x7,0x55,0x2c, + 0x7,0x55,0x2f, 0x4,0x67,0x3c, 0x5,0x71,0x3a, 0x5,0x71,0x39, + 0x4,0x67,0x43, 0x7,0x59,0x3b, 0x7,0x59,0x35, 0x4,0x67,0x3a, + 0x5,0x71,0x3c, 0x5,0x71,0x3b, 0x7,0x55,0x31, 0x7,0x55,0x2b, + 0x7,0x55,0x30, 0x5,0x71,0x38, 0x7,0x55,0x35, 0x5,0x74,0x3b, + 0x5,0x74,0x3d, 0x5,0x74,0x40, 0x5,0x76,0x4b, 0x4,0x69,0x47, + 0x7,0x59,0x39, 0x4,0x69,0x4a, 0x5,0x74,0x3f, 0x4,0x69,0x49, + 0x5,0x74,0x3e, 0x7,0x59,0x37, 0x7,0x59,0x40, 0x7,0x55,0x36, + 0x5,0x74,0x3c, 0x7,0x59,0x36, 0x7,0x59,0x3a, 0x7,0x59,0x3f, + 0x4,0x69,0x46, 0x7,0x59,0x3e, 0xf,0x69,0x72, 0xf,0x69,0x73, + 0xf,0x69,0x74, 0x7,0x59,0x3c, 0x7,0x59,0x3d, 0x4,0x6a,0x7d, + 0x4,0x6a,0x7e, 0x7,0x5c,0x66, 0x5,0x76,0x4e, 0x5,0x76,0x4d, + 0x5,0x78,0x31, 0x7,0x5c,0x68, 0x7,0x5c,0x69, 0x7,0x5c,0x6a, + 0xf,0x6a,0x74, 0xf,0x6a,0x75, 0x7,0x5c,0x67, 0x7,0x59,0x42, + 0x7,0x5f,0x57, 0x7,0x5f,0x58, 0x7,0x5f,0x55, 0x4,0x6c,0x27, + 0x7,0x5f,0x56, 0x7,0x5f,0x5a, 0xf,0x6b,0x65, 0xf,0x6b,0x66, + 0x7,0x5f,0x54, 0x7,0x5f,0x59, 0x7,0x5f,0x5b, 0x4,0x6d,0x23, + 0x7,0x61,0x4b, 0x5,0x79,0x4e, 0x7,0x61,0x4c, 0xf,0x6c,0x3a, + 0xf,0x6c,0x3b, 0x7,0x61,0x4a, 0x5,0x7a,0x75, 0x7,0x62,0x65, + 0x7,0x62,0x64, 0x5,0x7a,0x39, 0x4,0x6d,0x7e, 0x7,0x63,0x74, + 0x7,0x64,0x62, 0x4,0x6e,0x3c, 0x7,0x64,0x44, 0x7,0x65,0x44, + 0x7,0x66,0x50, 0x5,0x24,0x77, 0x4,0x30,0x24, 0x5,0x30,0x44, + 0x5,0x30,0x45, 0x4,0x35,0x48, 0x4,0x35,0x49, 0x4,0x35,0x47, + 0x6,0x44,0x7b, 0x4,0x3b,0x3a, 0x5,0x42,0x7e, 0x5,0x43,0x21, + 0x6,0x58,0x4c, 0x4,0x47,0x4d, 0x5,0x51,0x2c, 0x4,0x4d,0x63, + 0x5,0x51,0x2d, 0x5,0x51,0x2b, 0x5,0x58,0x42, 0x7,0x33,0x56, + 0x7,0x33,0x55, 0x7,0x3c,0x2a, 0x5,0x5e,0x57, 0x7,0x43,0x3e, + 0x7,0x4a,0x36, 0x7,0x4a,0x39, 0x5,0x69,0x54, 0x7,0x4a,0x37, + 0x5,0x69,0x55, 0x7,0x4a,0x38, 0x7,0x50,0x3a, 0x7,0x4a,0x3a, + 0x5,0x71,0x3e, 0x5,0x7a,0x76, 0x7,0x65,0x77, 0x6,0x34,0x55, + 0x6,0x3c,0x35, 0x6,0x3c,0x34, 0xf,0x38,0x57, 0x4,0x3b,0x3b, + 0x5,0x3c,0x3e, 0x6,0x4e,0x7b, 0xf,0x3f,0x3d, 0x5,0x43,0x22, + 0x4,0x40,0x75, 0x6,0x5b,0x5f, 0x4,0x47,0x50, 0x6,0x62,0x54, + 0x4,0x47,0x51, 0x7,0x29,0x28, 0x7,0x29,0x27, 0x7,0x29,0x25, + 0x5,0x51,0x2f, 0x5,0x51,0x2e, 0x7,0x29,0x26, 0xf,0x52,0x3b, + 0x5,0x58,0x43, 0x4,0x53,0x74, 0x7,0x33,0x57, 0x5,0x58,0x44, + 0x7,0x2c,0x56, 0x5,0x5e,0x5a, 0x7,0x3c,0x2d, 0x5,0x5e,0x58, + 0x7,0x3c,0x2c, 0x5,0x5e,0x59, 0x7,0x3c,0x2b, 0x5,0x64,0x69, + 0x4,0x5d,0x63, 0x7,0x43,0x40, 0x4,0x5d,0x62, 0x5,0x5e,0x5b, + 0x7,0x4a,0x3c, 0x5,0x69,0x57, 0x7,0x4a,0x3d, 0x7,0x43,0x41, + 0x7,0x43,0x42, 0x5,0x69,0x56, 0x5,0x6d,0x66, 0x5,0x6d,0x65, + 0x5,0x6d,0x67, 0xf,0x66,0x3a, 0x5,0x6d,0x64, 0xf,0x63,0x7b, + 0x5,0x71,0x3f, 0x5,0x74,0x41, 0xf,0x6a,0x76, 0xf,0x6a,0x77, + 0x5,0x78,0x32, 0x5,0x79,0x4f, 0x5,0x7a,0x77, 0x7,0x65,0x45, + 0x6,0x25,0x54, 0x5,0x23,0x29, 0x5,0x2b,0x4a, 0x5,0x30,0x48, + 0x5,0x30,0x47, 0x6,0x3c,0x37, 0x6,0x3c,0x36, 0x6,0x44,0x7e, + 0x6,0x44,0x7c, 0x5,0x35,0x61, 0x6,0x45,0x21, 0x6,0x44,0x7d, + 0x4,0x3b,0x3c, 0x6,0x4e,0x7c, 0x4,0x3b,0x3d, 0x5,0x3c,0x40, + 0x5,0x3c,0x3f, 0x6,0x4e,0x7e, 0x5,0x3c,0x41, 0x6,0x4f,0x23, + 0x6,0x4e,0x7d, 0xf,0x32,0x55, 0x4,0x40,0x77, 0x5,0x43,0x25, + 0x4,0x40,0x76, 0x6,0x58,0x4e, 0x6,0x58,0x4f, 0x5,0x43,0x27, + 0x5,0x43,0x23, 0x5,0x43,0x26, 0x6,0x58,0x4d, 0x6,0x4f,0x22, + 0x5,0x43,0x24, 0x5,0x43,0x28, 0x6,0x62,0x55, 0x6,0x62,0x56, + 0x4,0x47,0x53, 0x4,0x47,0x52, 0x6,0x62,0x59, 0x5,0x49,0x7d, + 0x5,0x49,0x7c, 0x6,0x62,0x5b, 0x6,0x62,0x5a, 0x6,0x62,0x57, + 0x6,0x62,0x58, 0x5,0x51,0x32, 0x4,0x4d,0x66, 0x7,0x29,0x29, + 0x7,0x29,0x2b, 0x5,0x51,0x31, 0x5,0x51,0x33, 0x7,0x29,0x2d, + 0x7,0x29,0x2c, 0x5,0x49,0x7e, 0x5,0x51,0x30, 0x7,0x29,0x2a, + 0x5,0x4a,0x21, 0x7,0x29,0x2e, 0xf,0x52,0x3c, 0x5,0x58,0x47, + 0x5,0x58,0x48, 0x5,0x58,0x46, 0x7,0x33,0x59, 0x4,0x53,0x76, + 0x7,0x33,0x5a, 0x7,0x33,0x5c, 0x7,0x33,0x5b, 0x5,0x58,0x45, + 0x7,0x33,0x58, 0x5,0x5e,0x5d, 0x5,0x5e,0x5e, 0x5,0x5e,0x5f, + 0x5,0x5e,0x5c, 0x7,0x3c,0x30, 0x7,0x3c,0x2e, 0x7,0x3c,0x2f, + 0x4,0x5d,0x65, 0x5,0x64,0x6a, 0x5,0x64,0x6b, 0x7,0x43,0x43, + 0x7,0x43,0x44, 0x7,0x43,0x45, 0x4,0x61,0x47, 0x5,0x69,0x58, + 0x5,0x58,0x49, 0x7,0x4a,0x3e, 0x4,0x61,0x49, 0x5,0x6d,0x6b, + 0x5,0x6d,0x68, 0x7,0x50,0x3b, 0x5,0x6d,0x6a, 0x5,0x6d,0x69, + 0x4,0x67,0x46, 0x5,0x71,0x40, 0x7,0x55,0x37, 0x7,0x55,0x38, + 0x7,0x59,0x43, 0x7,0x5c,0x6c, 0x7,0x59,0x44, 0x7,0x59,0x45, + 0x7,0x5c,0x6d, 0x7,0x5c,0x6e, 0x5,0x74,0x42, 0x7,0x5f,0x5c, + 0x7,0x61,0x4d, 0x7,0x5f,0x5d, 0x5,0x79,0x50, 0x5,0x7a,0x3a, + 0x7,0x65,0x46, 0x7,0x66,0x43, 0xf,0x28,0x6c, 0x5,0x2b,0x4b, + 0x6,0x3c,0x38, 0xf,0x32,0x56, 0x5,0x35,0x64, 0x5,0x35,0x63, + 0x4,0x35,0x4f, 0x5,0x35,0x62, 0x4,0x35,0x4e, 0x6,0x45,0x25, + 0x6,0x45,0x23, 0x6,0x4f,0x25, 0x5,0x3c,0x42, 0x5,0x3c,0x46, + 0x5,0x3c,0x44, 0x5,0x3c,0x48, 0x5,0x3c,0x45, 0x6,0x4f,0x28, + 0x6,0x4f,0x26, 0x5,0x3c,0x47, 0x5,0x3c,0x43, 0x6,0x4f,0x27, + 0x6,0x4f,0x24, 0xf,0x3f,0x3e, 0x4,0x40,0x7c, 0x4,0x40,0x7d, + 0x4,0x40,0x7a, 0x6,0x58,0x52, 0x5,0x43,0x2b, 0x6,0x58,0x51, + 0x5,0x43,0x2a, 0x4,0x40,0x79, 0x4,0x40,0x7b, 0x6,0x58,0x53, + 0xf,0x45,0x47, 0x5,0x43,0x29, 0x6,0x62,0x61, 0x6,0x62,0x5c, + 0x5,0x4a,0x25, 0x5,0x4a,0x23, 0x5,0x4a,0x22, 0x6,0x62,0x5f, + 0x5,0x4a,0x24, 0x6,0x62,0x5e, 0x6,0x62,0x60, 0xf,0x4c,0x48, + 0x6,0x62,0x5d, 0x6,0x62,0x62, 0xf,0x4c,0x49, 0x5,0x51,0x35, + 0x5,0x51,0x34, 0x4,0x4d,0x69, 0x5,0x51,0x37, 0x5,0x51,0x36, + 0x5,0x51,0x38, 0x4,0x4d,0x6a, 0x7,0x29,0x2f, 0x7,0x29,0x30, + 0x4,0x4d,0x6b, 0x7,0x29,0x31, 0x7,0x33,0x64, 0x5,0x58,0x4b, + 0x7,0x33,0x5e, 0x7,0x33,0x60, 0x7,0x33,0x61, 0x4,0x53,0x78, + 0x5,0x58,0x4a, 0x7,0x33,0x62, 0x5,0x58,0x4c, 0x7,0x33,0x5f, + 0xf,0x57,0x7a, 0x7,0x33,0x5d, 0x7,0x33,0x63, 0x4,0x58,0x79, + 0x5,0x5e,0x63, 0x7,0x3c,0x31, 0x5,0x5e,0x62, 0x4,0x58,0x78, + 0x5,0x5e,0x60, 0x5,0x5e,0x64, 0x5,0x5e,0x61, 0xf,0x5c,0x6c, + 0x7,0x43,0x46, 0x4,0x5d,0x67, 0x7,0x43,0x47, 0x4,0x5d,0x66, + 0x5,0x64,0x6c, 0x7,0x4a,0x3f, 0x5,0x64,0x6d, 0x5,0x69,0x5b, + 0x7,0x4a,0x40, 0x5,0x69,0x5a, 0x7,0x4a,0x43, 0x7,0x50,0x3d, + 0x7,0x4a,0x42, 0x5,0x69,0x59, 0x5,0x6d,0x6d, 0x5,0x6d,0x6c, + 0x7,0x50,0x3c, 0x5,0x71,0x42, 0x5,0x6d,0x6e, 0x5,0x71,0x41, + 0x7,0x55,0x39, 0x7,0x59,0x46, 0x7,0x5c,0x70, 0x7,0x5c,0x6f, + 0x5,0x7a,0x78, 0x5,0x2b,0x4c, 0x4,0x2b,0x4a, 0x6,0x34,0x56, + 0xf,0x2d,0x4a, 0x4,0x30,0x26, 0x6,0x3c,0x39, 0x5,0x30,0x49, + 0x5,0x30,0x4a, 0xf,0x32,0x57, 0xf,0x32,0x58, 0x6,0x3c,0x3a, + 0x6,0x45,0x2a, 0x6,0x45,0x2c, 0x6,0x45,0x27, 0x6,0x45,0x28, + 0x6,0x45,0x26, 0x6,0x45,0x2b, 0x5,0x35,0x65, 0xf,0x38,0x59, + 0xf,0x38,0x5a, 0xf,0x38,0x5b, 0xf,0x38,0x5c, 0xf,0x38,0x5d, + 0xf,0x38,0x5e, 0xf,0x38,0x5f, 0xf,0x38,0x60, 0x6,0x45,0x2d, + 0x4,0x35,0x53, 0x6,0x45,0x29, 0x4,0x35,0x52, 0x6,0x4f,0x2b, + 0x4,0x3b,0x40, 0x5,0x3c,0x49, 0x5,0x3c,0x4b, 0x6,0x4f,0x2e, + 0x6,0x4f,0x2c, 0x6,0x4f,0x2d, 0x6,0x58,0x57, 0x5,0x3c,0x4a, + 0xf,0x3f,0x3f, 0xf,0x3f,0x41, 0xf,0x3f,0x42, 0xf,0x3f,0x43, + 0xf,0x3f,0x44, 0xf,0x3f,0x45, 0x6,0x4f,0x2f, 0x6,0x4f,0x2a, + 0x5,0x3c,0x4d, 0x4,0x41,0x22, 0x6,0x58,0x54, 0x6,0x58,0x59, + 0x6,0x58,0x56, 0x5,0x43,0x30, 0x5,0x43,0x2c, 0x6,0x58,0x5e, + 0x6,0x58,0x55, 0x5,0x43,0x2f, 0x5,0x43,0x31, 0x5,0x43,0x32, + 0x6,0x58,0x58, 0x6,0x58,0x60, 0x6,0x58,0x62, 0x5,0x43,0x33, + 0x6,0x58,0x5f, 0xf,0x45,0x48, 0xf,0x45,0x49, 0xf,0x45,0x4a, + 0xf,0x45,0x4b, 0xf,0x45,0x4c, 0xf,0x45,0x4d, 0xf,0x45,0x4e, + 0x6,0x58,0x61, 0xf,0x3f,0x40, 0x6,0x58,0x5b, 0x5,0x43,0x2e, + 0xf,0x46,0x34, 0x6,0x62,0x65, 0x4,0x47,0x55, 0x5,0x4a,0x26, + 0x6,0x62,0x64, 0x6,0x62,0x66, 0x6,0x62,0x6c, 0x6,0x62,0x63, + 0x6,0x62,0x69, 0x5,0x4a,0x27, 0x4,0x47,0x57, 0xf,0x4c,0x4d, + 0xf,0x4c,0x4e, 0xf,0x4c,0x4f, 0xf,0x4c,0x51, 0xf,0x4c,0x50, + 0xf,0x4c,0x4c, 0x6,0x62,0x6b, 0x6,0x58,0x5d, 0x7,0x29,0x33, + 0x7,0x29,0x35, 0x5,0x4a,0x28, 0x4,0x4d,0x6f, 0x7,0x29,0x34, + 0x5,0x51,0x3a, 0x4,0x4d,0x70, 0x5,0x51,0x3b, 0x7,0x29,0x39, + 0x7,0x29,0x38, 0x7,0x29,0x32, 0xf,0x52,0x3d, 0xf,0x52,0x3e, + 0xf,0x52,0x3f, 0x7,0x29,0x37, 0xf,0x4c,0x4b, 0x7,0x33,0x6a, + 0x5,0x58,0x4e, 0x7,0x33,0x67, 0x7,0x33,0x66, 0x5,0x58,0x4f, + 0x7,0x33,0x6b, 0x7,0x33,0x6e, 0x4,0x53,0x7c, 0x7,0x33,0x68, + 0x5,0x58,0x4d, 0x6,0x62,0x68, 0xf,0x54,0x32, 0xf,0x57,0x7b, + 0xf,0x57,0x7c, 0xf,0x57,0x7d, 0xf,0x57,0x7e, 0xf,0x58,0x21, + 0xf,0x58,0x22, 0x7,0x33,0x6d, 0x7,0x33,0x6c, 0x7,0x33,0x65, + 0x7,0x33,0x69, 0x5,0x58,0x50, 0x7,0x3c,0x32, 0x5,0x5e,0x65, + 0x5,0x5b,0x2d, 0x5,0x5e,0x67, 0x5,0x58,0x52, 0x5,0x5e,0x66, + 0x4,0x58,0x7b, 0x7,0x3c,0x38, 0x7,0x3c,0x34, 0x7,0x3c,0x36, + 0x7,0x3c,0x37, 0x7,0x3c,0x35, 0xf,0x5c,0x6e, 0xf,0x5c,0x70, + 0xf,0x5c,0x6f, 0x7,0x43,0x4b, 0x5,0x64,0x73, 0x7,0x43,0x4e, + 0x5,0x64,0x6f, 0x7,0x43,0x49, 0x7,0x43,0x4a, 0x7,0x43,0x51, + 0x5,0x64,0x71, 0x5,0x64,0x6e, 0x5,0x64,0x72, 0x7,0x43,0x4d, + 0x7,0x43,0x4c, 0xf,0x60,0x76, 0xf,0x60,0x77, 0xf,0x60,0x78, + 0xf,0x60,0x79, 0xf,0x60,0x7b, 0xf,0x60,0x7c, 0x7,0x43,0x48, + 0x7,0x43,0x50, 0x5,0x64,0x70, 0x7,0x4a,0x47, 0x7,0x4a,0x4b, + 0x5,0x69,0x5d, 0x5,0x64,0x74, 0x7,0x4a,0x4a, 0x7,0x43,0x4f, + 0x5,0x69,0x5c, 0x4,0x61,0x4b, 0x7,0x4a,0x48, 0x5,0x69,0x5e, + 0x7,0x4a,0x4d, 0x7,0x4a,0x4c, 0x5,0x69,0x60, 0x7,0x4a,0x44, + 0x7,0x4a,0x49, 0x7,0x4a,0x46, 0xf,0x63,0x7c, 0xf,0x63,0x7d, + 0xf,0x63,0x7e, 0xf,0x64,0x21, 0x7,0x4a,0x4e, 0x7,0x4a,0x45, + 0x5,0x69,0x5f, 0x4,0x64,0x51, 0x5,0x6d,0x70, 0x4,0x64,0x50, + 0x5,0x6d,0x6f, 0x7,0x50,0x3e, 0x7,0x50,0x40, 0xf,0x66,0x3b, + 0xf,0x66,0x3c, 0xf,0x66,0x3d, 0xf,0x66,0x3e, 0xf,0x66,0x3f, + 0x7,0x50,0x3f, 0x5,0x71,0x43, 0x4,0x67,0x47, 0x5,0x71,0x44, + 0x5,0x71,0x45, 0xf,0x68,0x4e, 0xf,0x68,0x4f, 0x7,0x55,0x3b, + 0x7,0x59,0x47, 0x5,0x74,0x45, 0x5,0x74,0x44, 0xf,0x69,0x76, + 0xf,0x69,0x77, 0xf,0x69,0x78, 0x7,0x59,0x4a, 0x7,0x59,0x48, + 0x7,0x59,0x49, 0xf,0x68,0x4d, 0x7,0x5c,0x71, 0x4,0x6b,0x22, + 0x5,0x74,0x43, 0x7,0x5c,0x72, 0xf,0x6a,0x78, 0x7,0x5c,0x73, + 0x7,0x5f,0x5e, 0x7,0x5f,0x60, 0x7,0x5f,0x5f, 0x7,0x62,0x66, + 0x6,0x2e,0x31, 0x6,0x34,0x57, 0x6,0x34,0x58, 0x5,0x35,0x66, + 0xf,0x38,0x61, 0x6,0x4f,0x30, 0x4,0x3b,0x44, 0x6,0x58,0x63, + 0xf,0x45,0x4f, 0x5,0x4a,0x2a, 0xf,0x4c,0x52, 0x7,0x29,0x3a, + 0x5,0x58,0x54, 0x5,0x58,0x53, 0xf,0x58,0x23, 0x7,0x33,0x6f, + 0x5,0x5e,0x69, 0x5,0x5e,0x6a, 0x5,0x5e,0x68, 0xf,0x5c,0x71, + 0x5,0x64,0x75, 0x7,0x43,0x53, 0x7,0x4a,0x50, 0x7,0x4a,0x4f, + 0x5,0x71,0x46, 0x7,0x5c,0x74, 0x6,0x2e,0x32, 0x6,0x2e,0x33, + 0x6,0x34,0x59, 0xf,0x2d,0x4b, 0xf,0x2d,0x4d, 0xf,0x2d,0x4e, + 0xf,0x2d,0x4f, 0xf,0x2d,0x50, 0x4,0x2b,0x4b, 0x5,0x30,0x4d, + 0x6,0x3c,0x3e, 0x6,0x3c,0x3d, 0x5,0x30,0x4e, 0x6,0x3c,0x3c, + 0x4,0x30,0x29, 0xf,0x32,0x59, 0xf,0x32,0x5a, 0xf,0x32,0x5b, + 0xf,0x32,0x5c, 0xf,0x32,0x5d, 0x5,0x35,0x6d, 0x6,0x45,0x30, + 0x5,0x35,0x67, 0x4,0x35,0x57, 0x5,0x35,0x6a, 0x5,0x35,0x6f, + 0x5,0x35,0x6e, 0x4,0x35,0x58, 0x6,0x45,0x2e, 0x6,0x45,0x2f, + 0x5,0x35,0x6b, 0x5,0x35,0x68, 0xf,0x38,0x63, 0xf,0x38,0x64, + 0xf,0x38,0x65, 0xf,0x38,0x66, 0xf,0x38,0x68, 0xf,0x38,0x69, + 0xf,0x38,0x62, 0x5,0x35,0x6c, 0x5,0x35,0x69, 0xf,0x38,0x67, + 0x5,0x3c,0x51, 0x5,0x3c,0x50, 0x5,0x3c,0x54, 0x5,0x3c,0x4f, + 0x6,0x4f,0x34, 0x6,0x4f,0x31, 0x5,0x43,0x39, 0x5,0x3c,0x53, + 0x5,0x3c,0x4e, 0x6,0x4f,0x33, 0x4,0x3b,0x46, 0x5,0x3c,0x55, + 0x6,0x58,0x64, 0x6,0x4f,0x35, 0xf,0x3f,0x47, 0xf,0x3f,0x48, + 0xf,0x3f,0x49, 0xf,0x3f,0x4a, 0xf,0x3f,0x4b, 0xf,0x3f,0x4c, + 0xf,0x3f,0x4f, 0xf,0x3f,0x50, 0xf,0x3f,0x51, 0x6,0x4f,0x32, + 0xf,0x3f,0x4e, 0x6,0x58,0x66, 0x5,0x43,0x36, 0x4,0x41,0x23, + 0x6,0x58,0x68, 0x4,0x41,0x25, 0x5,0x43,0x3b, 0x5,0x43,0x35, + 0x5,0x43,0x3d, 0x5,0x43,0x37, 0x4,0x41,0x24, 0x6,0x58,0x6a, + 0x6,0x58,0x69, 0x5,0x43,0x3a, 0xf,0x45,0x50, 0xf,0x45,0x51, + 0xf,0x45,0x52, 0xf,0x45,0x53, 0xf,0x45,0x54, 0xf,0x45,0x55, + 0xf,0x45,0x56, 0xf,0x45,0x57, 0x6,0x58,0x65, 0x6,0x58,0x67, + 0x6,0x62,0x6d, 0xf,0x3f,0x4d, 0x6,0x62,0x6e, 0x4,0x47,0x5c, + 0x5,0x4a,0x2c, 0x5,0x4a,0x30, 0x6,0x62,0x72, 0x5,0x4a,0x2b, + 0x5,0x4a,0x2e, 0x5,0x4a,0x31, 0x6,0x62,0x71, 0x6,0x62,0x6f, + 0x5,0x4a,0x33, 0x4,0x47,0x5d, 0x5,0x4a,0x2f, 0x6,0x62,0x76, + 0x5,0x4a,0x2d, 0x6,0x62,0x73, 0xf,0x4c,0x53, 0xf,0x4c,0x54, + 0xf,0x4c,0x55, 0xf,0x4c,0x56, 0xf,0x4c,0x57, 0xf,0x4c,0x58, + 0xf,0x4c,0x59, 0x6,0x62,0x70, 0x5,0x51,0x42, 0x5,0x51,0x3c, + 0x4,0x4d,0x72, 0x5,0x51,0x3f, 0x5,0x51,0x3e, 0x5,0x51,0x3d, + 0x5,0x51,0x40, 0x7,0x29,0x3f, 0x5,0x51,0x46, 0x5,0x51,0x43, + 0x7,0x29,0x41, 0x5,0x51,0x41, 0x7,0x29,0x3c, 0x7,0x29,0x40, + 0x7,0x29,0x3e, 0x6,0x62,0x74, 0x7,0x29,0x42, 0x7,0x33,0x72, + 0x5,0x51,0x45, 0x5,0x51,0x44, 0xf,0x52,0x40, 0xf,0x52,0x41, + 0x7,0x29,0x43, 0x7,0x29,0x3b, 0xf,0x58,0x2d, 0x4,0x54,0x23, + 0x4,0x54,0x24, 0x4,0x54,0x28, 0x7,0x33,0x74, 0x5,0x58,0x59, + 0x4,0x54,0x21, 0x4,0x54,0x22, 0x4,0x54,0x27, 0x7,0x33,0x75, + 0x4,0x54,0x25, 0x7,0x33,0x71, 0x7,0x33,0x70, 0x5,0x58,0x58, + 0x5,0x58,0x5a, 0x7,0x33,0x76, 0xf,0x58,0x24, 0xf,0x58,0x26, + 0xf,0x58,0x27, 0xf,0x58,0x28, 0xf,0x58,0x29, 0xf,0x58,0x2a, + 0xf,0x58,0x2b, 0xf,0x58,0x2c, 0xf,0x58,0x2e, 0x7,0x33,0x78, + 0x7,0x33,0x77, 0x5,0x58,0x5b, 0x5,0x58,0x56, 0x5,0x58,0x57, + 0x5,0x5e,0x6f, 0x5,0x5e,0x71, 0x4,0x59,0x22, 0x5,0x5e,0x70, + 0x4,0x59,0x24, 0x4,0x59,0x21, 0x5,0x5e,0x72, 0x4,0x58,0x7e, + 0x5,0x5e,0x6c, 0x4,0x59,0x23, 0x5,0x5e,0x6e, 0x5,0x5e,0x6b, + 0x7,0x3c,0x3a, 0x5,0x5e,0x73, 0xf,0x58,0x25, 0xf,0x5c,0x72, + 0xf,0x5c,0x73, 0xf,0x5c,0x74, 0xf,0x5c,0x75, 0xf,0x5c,0x76, + 0x7,0x3c,0x39, 0x5,0x64,0x79, 0x5,0x64,0x7c, 0x4,0x5d,0x6b, + 0x7,0x43,0x57, 0x7,0x43,0x56, 0x5,0x64,0x76, 0x5,0x64,0x7a, + 0x5,0x64,0x78, 0x5,0x64,0x77, 0x5,0x64,0x7d, 0x5,0x64,0x7e, + 0x7,0x43,0x5b, 0x7,0x43,0x5a, 0x5,0x64,0x7b, 0xf,0x60,0x7d, + 0x7,0x43,0x58, 0x7,0x43,0x55, 0x7,0x43,0x59, 0x7,0x43,0x54, + 0x5,0x58,0x5d, 0x5,0x69,0x62, 0x5,0x69,0x66, 0x5,0x69,0x68, + 0x4,0x61,0x4e, 0x4,0x61,0x4c, 0x5,0x69,0x63, 0x5,0x69,0x67, + 0x5,0x69,0x65, 0x5,0x69,0x61, 0x7,0x4a,0x52, 0x5,0x69,0x69, + 0x5,0x69,0x64, 0xf,0x64,0x23, 0xf,0x64,0x24, 0xf,0x64,0x25, + 0x7,0x4a,0x51, 0x7,0x4a,0x53, 0x4,0x64,0x52, 0x4,0x64,0x54, + 0x4,0x64,0x58, 0x4,0x64,0x57, 0x5,0x6d,0x71, 0x7,0x50,0x41, + 0x7,0x50,0x43, 0x5,0x6d,0x72, 0x7,0x50,0x42, 0xf,0x66,0x40, + 0xf,0x66,0x41, 0xf,0x66,0x42, 0x4,0x67,0x49, 0x5,0x71,0x48, + 0x5,0x71,0x49, 0x7,0x55,0x3f, 0x7,0x55,0x3d, 0x7,0x55,0x3c, + 0x7,0x55,0x3e, 0x5,0x71,0x47, 0x5,0x74,0x46, 0x5,0x74,0x49, + 0x4,0x69,0x4d, 0x5,0x74,0x48, 0x5,0x74,0x47, 0xf,0x69,0x79, + 0x5,0x76,0x4f, 0x5,0x76,0x50, 0xf,0x6a,0x79, 0x7,0x59,0x4b, + 0x7,0x5c,0x75, 0x7,0x5c,0x76, 0x5,0x78,0x33, 0x5,0x78,0x34, + 0x5,0x78,0x35, 0x4,0x6d,0x26, 0x7,0x61,0x4e, 0x5,0x7a,0x79, + 0x5,0x7b,0x49, 0x6,0x2e,0x35, 0x6,0x2e,0x34, 0x6,0x34,0x5b, + 0x5,0x2b,0x4d, 0xf,0x2d,0x51, 0x6,0x34,0x5a, 0x6,0x3c,0x41, + 0x4,0x30,0x2b, 0x6,0x3c,0x42, 0x6,0x3c,0x40, 0x5,0x30,0x50, + 0x5,0x30,0x4f, 0x6,0x3c,0x3f, 0x6,0x3c,0x43, 0x4,0x35,0x5f, + 0x6,0x45,0x33, 0x4,0x35,0x5a, 0x5,0x35,0x73, 0x6,0x45,0x37, + 0x5,0x35,0x77, 0x6,0x45,0x3a, 0x5,0x35,0x71, 0x5,0x35,0x75, + 0x6,0x45,0x3c, 0x6,0x45,0x3d, 0x5,0x35,0x74, 0x6,0x45,0x3b, + 0x6,0x45,0x32, 0x6,0x45,0x36, 0xf,0x38,0x6a, 0x6,0x45,0x31, + 0x6,0x45,0x35, 0x6,0x45,0x39, 0x5,0x35,0x76, 0x5,0x35,0x70, + 0x6,0x45,0x34, 0x5,0x3c,0x60, 0x5,0x3c,0x57, 0x5,0x3c,0x58, + 0x5,0x3c,0x5b, 0x6,0x4f,0x3b, 0x5,0x3c,0x56, 0x6,0x4f,0x38, + 0x4,0x3b,0x4e, 0x5,0x3c,0x5d, 0x5,0x3c,0x59, 0x5,0x3c,0x61, + 0x5,0x3c,0x5a, 0x6,0x4f,0x39, 0x6,0x58,0x79, 0x5,0x3c,0x62, + 0xf,0x3f,0x54, 0x6,0x4f,0x37, 0xf,0x3f,0x52, 0x6,0x4f,0x3a, + 0x5,0x3c,0x5e, 0x5,0x43,0x41, 0x5,0x43,0x3f, 0x6,0x58,0x71, + 0x5,0x43,0x40, 0x5,0x43,0x42, 0x6,0x58,0x74, 0x6,0x58,0x70, + 0x5,0x43,0x47, 0x5,0x43,0x45, 0x6,0x58,0x6e, 0x6,0x58,0x6d, + 0x5,0x43,0x3e, 0x6,0x58,0x6f, 0x6,0x58,0x72, 0x6,0x58,0x76, + 0x5,0x43,0x4a, 0x6,0x58,0x6c, 0x6,0x58,0x77, 0x5,0x43,0x43, + 0x5,0x43,0x4c, 0x5,0x43,0x48, 0x6,0x58,0x73, 0x5,0x43,0x49, + 0x5,0x43,0x46, 0x6,0x58,0x75, 0x5,0x4a,0x35, 0xf,0x45,0x59, + 0x6,0x58,0x78, 0x6,0x58,0x6b, 0x6,0x63,0x22, 0x5,0x4a,0x43, + 0x4,0x47,0x60, 0x5,0x4a,0x37, 0x5,0x4a,0x3f, 0x5,0x4a,0x36, + 0x5,0x51,0x4e, 0x5,0x4a,0x3b, 0x6,0x62,0x77, 0x6,0x62,0x7b, + 0x5,0x4a,0x42, 0x5,0x4a,0x3c, 0x5,0x4a,0x39, 0x5,0x4a,0x40, + 0x5,0x4a,0x41, 0x5,0x4a,0x3d, 0x5,0x43,0x44, 0x5,0x4a,0x38, + 0x5,0x4a,0x44, 0x6,0x62,0x7e, 0x5,0x4a,0x46, 0x6,0x62,0x79, + 0x5,0x4a,0x47, 0xf,0x4c,0x5a, 0xf,0x4c,0x5b, 0x6,0x62,0x78, + 0x6,0x62,0x7a, 0x6,0x62,0x7d, 0x6,0x63,0x21, 0x6,0x62,0x7c, + 0x5,0x4a,0x3a, 0x7,0x29,0x46, 0x4,0x4d,0x7a, 0x5,0x51,0x4c, + 0x5,0x51,0x47, 0x5,0x51,0x4a, 0x5,0x51,0x4f, 0x7,0x29,0x45, + 0x7,0x29,0x49, 0x4,0x4d,0x7c, 0x7,0x29,0x4d, 0x4,0x4d,0x7b, + 0x5,0x51,0x4b, 0x5,0x51,0x4d, 0x4,0x4e,0x24, 0x5,0x51,0x51, + 0x5,0x51,0x52, 0x4,0x47,0x63, 0x7,0x29,0x4f, 0x5,0x51,0x49, + 0x7,0x29,0x4b, 0xf,0x52,0x42, 0xf,0x52,0x43, 0xf,0x52,0x44, + 0xf,0x52,0x45, 0x7,0x29,0x48, 0x7,0x29,0x4c, 0x7,0x29,0x47, + 0x7,0x29,0x4a, 0x5,0x51,0x50, 0x5,0x51,0x54, 0x5,0x51,0x55, + 0x5,0x4a,0x45, 0x7,0x34,0x21, 0x5,0x58,0x60, 0x5,0x4a,0x48, + 0x5,0x58,0x69, 0x4,0x54,0x2a, 0x7,0x33,0x7a, 0x5,0x58,0x63, + 0x7,0x33,0x7e, 0x7,0x34,0x23, 0x7,0x33,0x7c, 0x5,0x58,0x5f, + 0x7,0x33,0x7b, 0x7,0x34,0x25, 0x5,0x51,0x53, 0x7,0x34,0x26, + 0x5,0x58,0x67, 0x5,0x58,0x68, 0x5,0x58,0x5e, 0x5,0x58,0x61, + 0x7,0x33,0x7d, 0x5,0x58,0x65, 0x5,0x58,0x64, 0x7,0x34,0x24, + 0x4,0x54,0x2b, 0x5,0x58,0x66, 0x4,0x54,0x2c, 0xf,0x58,0x31, + 0xf,0x58,0x32, 0x7,0x34,0x22, 0x5,0x5e,0x7a, 0x5,0x5e,0x7d, + 0x5,0x5e,0x75, 0x7,0x3c,0x40, 0x5,0x5e,0x76, 0x5,0x5e,0x7c, + 0x5,0x5e,0x78, 0x4,0x59,0x29, 0x7,0x3c,0x3e, 0x7,0x43,0x67, + 0x7,0x3c,0x43, 0x5,0x5e,0x7e, 0x4,0x59,0x2e, 0x7,0x3c,0x3b, + 0x7,0x3c,0x42, 0x7,0x3c,0x44, 0x5,0x5e,0x79, 0x4,0x59,0x27, + 0x7,0x3c,0x41, 0x7,0x34,0x27, 0x7,0x3c,0x3f, 0x4,0x59,0x2f, + 0xf,0x5c,0x77, 0x7,0x3c,0x3d, 0xf,0x5c,0x79, 0x5,0x5e,0x77, + 0x5,0x5e,0x74, 0x7,0x43,0x62, 0x4,0x5d,0x70, 0x7,0x43,0x66, + 0x4,0x5d,0x6f, 0x5,0x65,0x21, 0x5,0x65,0x22, 0x5,0x65,0x2d, + 0x5,0x65,0x26, 0x4,0x5d,0x71, 0x5,0x65,0x2c, 0x5,0x65,0x28, + 0x7,0x43,0x5f, 0x5,0x69,0x70, 0x7,0x43,0x65, 0x7,0x43,0x5c, + 0x5,0x65,0x2e, 0x7,0x43,0x5e, 0x5,0x65,0x24, 0x7,0x43,0x61, + 0x5,0x65,0x23, 0x5,0x65,0x29, 0x4,0x5f,0x33, 0x4,0x5d,0x76, + 0x5,0x65,0x25, 0xf,0x60,0x7e, 0xf,0x61,0x21, 0xf,0x61,0x22, + 0xf,0x61,0x23, 0xf,0x61,0x24, 0xf,0x61,0x25, 0x7,0x43,0x6b, + 0x5,0x65,0x27, 0x7,0x43,0x60, 0x7,0x43,0x69, 0x7,0x43,0x68, + 0x7,0x43,0x6a, 0x7,0x43,0x5d, 0x5,0x65,0x2b, 0x7,0x43,0x63, + 0x7,0x3c,0x3c, 0x5,0x65,0x2f, 0x5,0x69,0x6a, 0x7,0x4a,0x65, + 0x5,0x69,0x6f, 0x5,0x69,0x71, 0x7,0x4a,0x68, 0x5,0x69,0x74, + 0x7,0x4a,0x5b, 0x5,0x65,0x2a, 0x5,0x69,0x6e, 0x7,0x4a,0x58, + 0x5,0x69,0x6d, 0x5,0x69,0x72, 0x4,0x61,0x55, 0x7,0x4a,0x54, + 0x4,0x5d,0x73, 0x7,0x4a,0x59, 0x7,0x43,0x64, 0x7,0x4a,0x5e, + 0x5,0x69,0x73, 0x7,0x4a,0x5a, 0x7,0x4a,0x66, 0x7,0x4a,0x55, + 0x7,0x4a,0x5c, 0x5,0x69,0x6b, 0x5,0x69,0x6c, 0x7,0x4a,0x61, + 0x7,0x4a,0x62, 0x7,0x4a,0x63, 0x7,0x4a,0x5f, 0x5,0x69,0x76, + 0x5,0x69,0x75, 0x7,0x4a,0x60, 0x7,0x4a,0x5d, 0x7,0x4a,0x67, + 0x7,0x4a,0x56, 0x7,0x4a,0x64, 0x4,0x61,0x53, 0x4,0x64,0x59, + 0x5,0x6d,0x7d, 0x5,0x6d,0x77, 0x7,0x50,0x44, 0x5,0x6d,0x7b, + 0x5,0x6d,0x76, 0x5,0x6d,0x79, 0x7,0x50,0x48, 0x7,0x50,0x46, + 0x4,0x64,0x5c, 0x5,0x6d,0x73, 0x4,0x64,0x5d, 0x7,0x50,0x47, + 0x5,0x6d,0x78, 0x5,0x6d,0x75, 0x5,0x6d,0x74, 0x7,0x50,0x49, + 0xf,0x66,0x43, 0xf,0x66,0x44, 0xf,0x66,0x45, 0xf,0x66,0x46, + 0xf,0x66,0x47, 0x7,0x50,0x45, 0x7,0x50,0x4a, 0x7,0x50,0x4b, + 0x5,0x6d,0x7c, 0x5,0x6d,0x7e, 0x5,0x6d,0x7a, 0x4,0x67,0x4e, + 0x7,0x55,0x42, 0x4,0x67,0x4f, 0x5,0x71,0x4b, 0x7,0x55,0x41, + 0x7,0x55,0x44, 0x4,0x67,0x4d, 0x4,0x67,0x4b, 0x5,0x71,0x4c, + 0x7,0x55,0x43, 0x7,0x55,0x40, 0x5,0x71,0x4a, 0xf,0x68,0x51, + 0xf,0x68,0x52, 0x5,0x74,0x4a, 0x7,0x55,0x45, 0x7,0x59,0x4c, + 0x5,0x74,0x4d, 0x5,0x74,0x4f, 0x5,0x74,0x4e, 0x5,0x74,0x4c, + 0x7,0x59,0x4d, 0x5,0x74,0x51, 0x7,0x59,0x4e, 0xf,0x69,0x7a, + 0x7,0x59,0x4f, 0x5,0x74,0x50, 0x5,0x76,0x54, 0x5,0x76,0x52, + 0x5,0x76,0x55, 0x7,0x5c,0x79, 0x7,0x5c,0x78, 0x5,0x76,0x53, + 0x5,0x76,0x51, 0x4,0x6c,0x2b, 0x7,0x5f,0x61, 0x5,0x78,0x37, + 0x5,0x78,0x36, 0x4,0x6c,0x2a, 0x5,0x78,0x38, 0x7,0x5f,0x62, + 0x7,0x61,0x4f, 0x7,0x5f,0x63, 0x7,0x61,0x52, 0x4,0x6d,0x28, + 0x7,0x61,0x54, 0x7,0x62,0x67, 0x7,0x61,0x53, 0x7,0x61,0x51, + 0x7,0x61,0x50, 0xf,0x6b,0x67, 0x5,0x7a,0x3c, 0x5,0x7a,0x3b, + 0x5,0x7a,0x3d, 0x7,0x63,0x76, 0x5,0x7b,0x4a, 0x7,0x64,0x63, + 0x5,0x7b,0x6a, 0xf,0x6d,0x28, 0x7,0x65,0x65, 0xf,0x6d,0x33, + 0x6,0x23,0x39, 0x6,0x23,0x3a, 0x6,0x25,0x55, 0x5,0x30,0x52, + 0x6,0x3c,0x44, 0x5,0x30,0x51, 0x5,0x35,0x7a, 0x5,0x35,0x79, + 0x5,0x35,0x78, 0x6,0x45,0x3e, 0x6,0x45,0x41, 0x6,0x45,0x40, + 0x6,0x45,0x42, 0x6,0x45,0x3f, 0x6,0x45,0x43, 0x6,0x45,0x44, + 0x4,0x35,0x60, 0xf,0x38,0x6b, 0x5,0x3c,0x65, 0x6,0x4f,0x3f, + 0x5,0x3c,0x64, 0x6,0x4f,0x41, 0x6,0x4f,0x3e, 0x5,0x3c,0x66, + 0xf,0x3f,0x55, 0xf,0x3f,0x56, 0xf,0x3f,0x57, 0xf,0x3f,0x58, + 0x6,0x4f,0x3d, 0x6,0x4f,0x40, 0x6,0x58,0x7d, 0x5,0x43,0x4d, + 0x6,0x58,0x7a, 0x6,0x58,0x7e, 0x6,0x59,0x21, 0xf,0x45,0x5a, + 0xf,0x45,0x5b, 0xf,0x45,0x5c, 0x6,0x58,0x7b, 0x6,0x58,0x7c, + 0x6,0x59,0x22, 0x5,0x4a,0x4a, 0x6,0x63,0x23, 0x6,0x63,0x24, + 0x5,0x4a,0x49, 0x6,0x63,0x25, 0x6,0x63,0x26, 0xf,0x4c,0x5c, + 0xf,0x4c,0x5d, 0xf,0x4c,0x5e, 0x7,0x29,0x51, 0x5,0x51,0x56, + 0x4,0x4e,0x25, 0xf,0x52,0x46, 0xf,0x52,0x48, 0x7,0x29,0x50, + 0x5,0x58,0x6a, 0x4,0x54,0x31, 0x5,0x58,0x6b, 0x7,0x34,0x28, + 0x7,0x3c,0x46, 0xf,0x58,0x34, 0xf,0x58,0x36, 0x7,0x3c,0x48, + 0x7,0x3c,0x47, 0x7,0x3c,0x45, 0x5,0x5f,0x21, 0xf,0x5c,0x7a, + 0xf,0x5c,0x7b, 0x5,0x65,0x30, 0x7,0x43,0x6c, 0xf,0x61,0x26, + 0xf,0x61,0x27, 0x7,0x4a,0x6c, 0x7,0x4a,0x6d, 0x7,0x4a,0x6a, + 0xf,0x64,0x26, 0xf,0x64,0x27, 0x7,0x4a,0x6b, 0x7,0x4a,0x69, + 0x4,0x64,0x5e, 0x7,0x50,0x4d, 0xf,0x66,0x48, 0xf,0x66,0x49, + 0x7,0x50,0x4e, 0x7,0x55,0x46, 0x5,0x71,0x4d, 0x7,0x55,0x47, + 0x7,0x55,0x48, 0x7,0x55,0x49, 0x7,0x59,0x50, 0xf,0x69,0x7c, + 0x5,0x76,0x56, 0x5,0x79,0x51, 0x6,0x34,0x5c, 0x5,0x2b,0x4e, + 0x6,0x34,0x5e, 0xf,0x2d,0x52, 0xf,0x2d,0x54, 0x6,0x3c,0x45, + 0x5,0x30,0x54, 0x6,0x3c,0x47, 0xf,0x32,0x5f, 0xf,0x32,0x60, + 0x6,0x3c,0x46, 0x5,0x30,0x53, 0xf,0x32,0x5e, 0x5,0x35,0x7b, + 0x6,0x45,0x4e, 0x6,0x45,0x4d, 0x6,0x45,0x46, 0x4,0x35,0x64, + 0x5,0x36,0x22, 0x5,0x36,0x21, 0x6,0x45,0x4a, 0x5,0x35,0x7d, + 0x6,0x45,0x47, 0x6,0x45,0x4c, 0x6,0x45,0x4b, 0x5,0x35,0x7c, + 0x5,0x35,0x7e, 0xf,0x38,0x6d, 0x6,0x45,0x48, 0x6,0x45,0x49, + 0x4,0x35,0x65, 0x6,0x4f,0x46, 0x6,0x4f,0x47, 0x5,0x3c,0x70, + 0x5,0x3c,0x6e, 0x6,0x4f,0x45, 0x6,0x4f,0x44, 0x6,0x4f,0x42, + 0x5,0x36,0x23, 0x5,0x3c,0x6d, 0x5,0x3c,0x68, 0x5,0x3c,0x6b, + 0x5,0x3c,0x6a, 0x6,0x4f,0x43, 0x5,0x3c,0x69, 0x5,0x3c,0x71, + 0x5,0x3c,0x6c, 0x5,0x3c,0x6f, 0x6,0x59,0x23, 0x6,0x59,0x28, + 0x5,0x43,0x53, 0x6,0x59,0x26, 0x6,0x59,0x29, 0x5,0x43,0x51, + 0x4,0x41,0x2b, 0x5,0x43,0x52, 0x5,0x43,0x4f, 0x6,0x59,0x27, + 0x5,0x43,0x4e, 0xf,0x45,0x5d, 0xf,0x45,0x5e, 0xf,0x45,0x5f, + 0x6,0x59,0x25, 0x4,0x41,0x2d, 0x5,0x43,0x54, 0x6,0x63,0x2d, + 0x6,0x63,0x2f, 0x5,0x4a,0x50, 0x4,0x47,0x68, 0x6,0x63,0x28, + 0x6,0x63,0x2b, 0x5,0x4a,0x4d, 0x6,0x63,0x2c, 0x6,0x63,0x27, + 0x6,0x63,0x30, 0x5,0x4a,0x4b, 0x5,0x4a,0x4e, 0x6,0x63,0x31, + 0x6,0x63,0x2e, 0xf,0x4c,0x5f, 0xf,0x4c,0x60, 0xf,0x4c,0x61, + 0xf,0x4c,0x63, 0x5,0x4a,0x4f, 0x5,0x4a,0x4c, 0x7,0x29,0x59, + 0x6,0x63,0x2a, 0x5,0x51,0x60, 0x7,0x29,0x57, 0x7,0x29,0x5e, + 0x7,0x29,0x62, 0x7,0x29,0x56, 0x5,0x51,0x59, 0x7,0x29,0x5a, + 0x7,0x29,0x55, 0x7,0x29,0x5c, 0x5,0x51,0x58, 0x5,0x51,0x5b, + 0x5,0x51,0x5e, 0x4,0x4e,0x2c, 0x6,0x63,0x29, 0x7,0x29,0x58, + 0x7,0x29,0x5d, 0x7,0x29,0x5b, 0x5,0x51,0x5d, 0x5,0x51,0x5f, + 0x7,0x29,0x52, 0x5,0x51,0x57, 0x7,0x29,0x54, 0x7,0x29,0x63, + 0xf,0x52,0x49, 0xf,0x52,0x4a, 0xf,0x52,0x4b, 0xf,0x52,0x4c, + 0x7,0x29,0x53, 0x7,0x29,0x5f, 0x7,0x29,0x60, 0x7,0x29,0x61, + 0x5,0x51,0x5c, 0x5,0x51,0x5a, 0x7,0x34,0x29, 0x5,0x58,0x73, + 0x7,0x34,0x2f, 0x5,0x58,0x74, 0x7,0x34,0x2d, 0x5,0x58,0x70, + 0x7,0x34,0x2b, 0x7,0x34,0x34, 0x5,0x58,0x6e, 0x5,0x58,0x71, + 0x5,0x58,0x6d, 0x7,0x34,0x35, 0x7,0x34,0x30, 0x7,0x34,0x36, + 0x5,0x58,0x6c, 0x7,0x34,0x33, 0xf,0x58,0x37, 0xf,0x58,0x39, + 0xf,0x58,0x3a, 0x7,0x34,0x2c, 0x7,0x34,0x2e, 0x7,0x34,0x2a, + 0xf,0x58,0x38, 0x4,0x54,0x35, 0x5,0x58,0x6f, 0x7,0x3c,0x4a, + 0x7,0x3c,0x52, 0x5,0x5f,0x25, 0x7,0x3c,0x4d, 0x7,0x3c,0x4c, + 0x7,0x3c,0x4b, 0x7,0x3c,0x53, 0x4,0x59,0x33, 0x7,0x3c,0x50, + 0x4,0x59,0x34, 0x7,0x3c,0x51, 0x5,0x5f,0x22, 0x5,0x5f,0x2b, + 0x4,0x59,0x36, 0x5,0x5f,0x28, 0x5,0x5f,0x27, 0x7,0x3c,0x54, + 0x5,0x5f,0x24, 0x5,0x5f,0x2a, 0x7,0x3c,0x49, 0xf,0x5c,0x7c, + 0xf,0x5c,0x7d, 0x7,0x3c,0x4e, 0x7,0x3c,0x4f, 0x5,0x5f,0x26, + 0x5,0x5f,0x23, 0x5,0x5f,0x29, 0x4,0x5d,0x79, 0x7,0x43,0x70, + 0x4,0x5e,0x21, 0x5,0x65,0x32, 0x5,0x65,0x34, 0xf,0x61,0x28, + 0xf,0x61,0x29, 0xf,0x61,0x2a, 0x7,0x43,0x6f, 0x7,0x43,0x72, + 0x7,0x43,0x71, 0x7,0x43,0x6e, 0x7,0x43,0x6d, 0x5,0x65,0x31, + 0x5,0x65,0x33, 0x5,0x69,0x78, 0x7,0x4a,0x6e, 0x7,0x4a,0x71, + 0x7,0x4a,0x6f, 0x7,0x4a,0x70, 0x5,0x69,0x7a, 0x4,0x61,0x5a, + 0x4,0x61,0x5b, 0x5,0x69,0x79, 0x5,0x69,0x77, 0x5,0x69,0x7b, + 0x7,0x4a,0x72, 0xf,0x64,0x28, 0x7,0x4a,0x74, 0x4,0x64,0x62, + 0x5,0x6e,0x25, 0x5,0x6e,0x23, 0x7,0x50,0x53, 0x5,0x6e,0x24, + 0x5,0x6e,0x22, 0x7,0x50,0x51, 0x5,0x6e,0x21, 0xf,0x66,0x4a, + 0x7,0x50,0x52, 0x7,0x50,0x50, 0x7,0x50,0x4f, 0x5,0x6e,0x26, + 0x7,0x50,0x54, 0x4,0x67,0x53, 0x5,0x71,0x4e, 0x4,0x67,0x54, + 0x7,0x55,0x4c, 0x7,0x55,0x4b, 0x7,0x55,0x4a, 0x7,0x59,0x56, + 0x4,0x69,0x50, 0x7,0x59,0x52, 0x7,0x59,0x51, 0x4,0x69,0x51, + 0x7,0x59,0x57, 0x7,0x59,0x53, 0x7,0x59,0x54, 0x7,0x59,0x55, + 0x7,0x5c,0x7e, 0x7,0x5d,0x21, 0x5,0x76,0x57, 0x7,0x5c,0x7b, + 0x7,0x5c,0x7a, 0x7,0x5c,0x7c, 0x7,0x5c,0x7d, 0x5,0x76,0x59, + 0x5,0x76,0x58, 0x5,0x78,0x3c, 0x5,0x78,0x3b, 0x5,0x78,0x3a, + 0x7,0x5f,0x67, 0x7,0x5f,0x65, 0x7,0x5f,0x64, 0x5,0x78,0x39, + 0x7,0x5f,0x66, 0x5,0x79,0x53, 0x5,0x79,0x52, 0x5,0x7a,0x3e, + 0x5,0x7a,0x3f, 0x7,0x62,0x68, 0x5,0x7a,0x7a, 0x7,0x64,0x64, + 0x7,0x62,0x69, 0x7,0x63,0x77, 0x5,0x7b,0x6b, 0x7,0x65,0x66, + 0x6,0x29,0x2b, 0x6,0x2e,0x36, 0x6,0x3c,0x48, 0x6,0x45,0x4f, + 0x5,0x36,0x25, 0x5,0x36,0x24, 0x4,0x41,0x2e, 0x6,0x59,0x2a, + 0xf,0x45,0x61, 0x5,0x4a,0x51, 0xf,0x4c,0x65, 0xf,0x4c,0x66, + 0x5,0x4a,0x52, 0x7,0x29,0x64, 0x7,0x29,0x65, 0x7,0x29,0x66, + 0x5,0x51,0x62, 0x7,0x34,0x37, 0x5,0x58,0x75, 0x7,0x34,0x38, + 0xf,0x58,0x3b, 0x5,0x5f,0x2d, 0x5,0x5f,0x2c, 0xf,0x5c,0x7e, + 0xf,0x5d,0x21, 0xf,0x5d,0x22, 0xf,0x5d,0x23, 0x5,0x5f,0x2e, + 0x5,0x65,0x37, 0x5,0x65,0x36, 0x7,0x43,0x73, 0x7,0x4a,0x75, + 0x4,0x61,0x5c, 0x7,0x4a,0x76, 0xf,0x66,0x4b, 0x7,0x50,0x55, + 0xf,0x68,0x54, 0x7,0x59,0x58, 0x7,0x5f,0x68, 0x7,0x65,0x47, + 0x7,0x65,0x67, 0x6,0x29,0x2c, 0x6,0x2e,0x37, 0x6,0x59,0x2d, + 0x6,0x59,0x2c, 0x6,0x59,0x2b, 0xf,0x52,0x4d, 0x7,0x33,0x21, + 0x4,0x61,0x5d, 0x7,0x55,0x4d, 0x6,0x25,0x59, 0x6,0x25,0x58, + 0x6,0x25,0x57, 0x4,0x24,0x7e, 0x6,0x29,0x2d, 0x4,0x25,0x24, + 0x6,0x3c,0x49, 0x6,0x29,0x2e, 0xf,0x25,0x33, 0xf,0x25,0x34, + 0x6,0x3c,0x4a, 0x6,0x29,0x2f, 0x5,0x24,0x78, 0x6,0x3c,0x4b, + 0x6,0x45,0x50, 0x5,0x27,0x6a, 0x5,0x27,0x6b, 0x5,0x27,0x70, + 0x6,0x2e,0x38, 0x6,0x2e,0x3d, 0x5,0x27,0x6f, 0x4,0x28,0x25, + 0x5,0x27,0x71, 0x5,0x27,0x6d, 0x4,0x28,0x28, 0x6,0x2e,0x3b, + 0xf,0x28,0x6d, 0xf,0x28,0x6f, 0xf,0x28,0x70, 0xf,0x28,0x73, + 0xf,0x28,0x74, 0xf,0x28,0x75, 0x6,0x2e,0x3a, 0x6,0x2e,0x3f, + 0x5,0x27,0x6e, 0x5,0x27,0x68, 0x6,0x2e,0x3c, 0x5,0x27,0x6c, + 0x6,0x2e,0x39, 0x6,0x2e,0x3e, 0x5,0x2b,0x4f, 0x5,0x2b,0x56, + 0x5,0x2b,0x52, 0x6,0x34,0x5f, 0x5,0x2b,0x51, 0x6,0x34,0x62, + 0x5,0x2b,0x55, 0x5,0x2b,0x53, 0x4,0x2b,0x4f, 0x4,0x2b,0x51, + 0x5,0x2b,0x50, 0x6,0x34,0x64, 0x6,0x34,0x63, 0xf,0x2d,0x55, + 0xf,0x2d,0x56, 0xf,0x2d,0x57, 0xf,0x2d,0x58, 0xf,0x2d,0x59, + 0x4,0x2b,0x52, 0x6,0x34,0x65, 0x6,0x34,0x61, 0x6,0x4a,0x47, + 0x5,0x2b,0x57, 0x5,0x2b,0x54, 0x6,0x3c,0x54, 0x6,0x3c,0x58, + 0x5,0x30,0x5b, 0x6,0x3c,0x53, 0x5,0x30,0x56, 0x5,0x30,0x5a, + 0x4,0x30,0x31, 0x5,0x30,0x57, 0x5,0x30,0x59, 0x6,0x3c,0x52, + 0x6,0x3c,0x4c, 0x6,0x3c,0x56, 0x4,0x30,0x32, 0x6,0x3c,0x57, + 0x6,0x3c,0x4d, 0x5,0x43,0x55, 0x6,0x3c,0x55, 0x5,0x30,0x58, + 0x6,0x3c,0x50, 0x6,0x3c,0x4e, 0x5,0x30,0x5c, 0x5,0x36,0x27, + 0x5,0x36,0x26, 0x6,0x3c,0x4f, 0x6,0x45,0x5b, 0x5,0x36,0x2c, + 0x4,0x35,0x6a, 0x6,0x45,0x5c, 0x5,0x36,0x2b, 0x6,0x3c,0x51, + 0x5,0x36,0x29, 0x6,0x45,0x57, 0x6,0x45,0x5a, 0xf,0x38,0x70, + 0xf,0x38,0x71, 0xf,0x38,0x72, 0x6,0x45,0x56, 0x6,0x45,0x54, + 0x6,0x45,0x55, 0x6,0x45,0x52, 0x6,0x45,0x5d, 0x6,0x45,0x58, + 0x6,0x45,0x53, 0x5,0x36,0x2a, 0x4,0x35,0x67, 0x6,0x45,0x59, + 0x5,0x36,0x2d, 0x5,0x36,0x28, 0xf,0x38,0x6f, 0x6,0x45,0x51, + 0x5,0x3c,0x76, 0x5,0x3c,0x72, 0x5,0x3c,0x78, 0x5,0x3c,0x77, + 0x4,0x3b,0x56, 0x6,0x4f,0x53, 0x4,0x3b,0x5a, 0x4,0x3b,0x58, + 0x5,0x3c,0x79, 0x6,0x4f,0x52, 0x7,0x29,0x67, 0x6,0x4f,0x4d, + 0x6,0x4f,0x4c, 0x6,0x4f,0x50, 0x6,0x4f,0x4f, 0x4,0x3b,0x5b, + 0x6,0x4f,0x49, 0x6,0x4f,0x4b, 0xf,0x3f,0x62, 0x6,0x4f,0x51, + 0x6,0x4f,0x54, 0x6,0x4f,0x55, 0x6,0x4f,0x4a, 0xf,0x3f,0x59, + 0xf,0x3f,0x5a, 0xf,0x3f,0x5b, 0xf,0x3f,0x5c, 0xf,0x3f,0x5d, + 0xf,0x3f,0x5f, 0xf,0x3f,0x60, 0xf,0x3f,0x61, 0x5,0x3c,0x75, + 0x6,0x4f,0x4e, 0x5,0x3c,0x74, 0x5,0x3c,0x73, 0x4,0x3b,0x59, + 0x6,0x4f,0x56, 0x6,0x59,0x40, 0x6,0x59,0x34, 0x6,0x59,0x3d, + 0x6,0x59,0x30, 0x4,0x41,0x31, 0x4,0x41,0x30, 0x6,0x59,0x2e, + 0x5,0x43,0x59, 0x6,0x59,0x31, 0x6,0x59,0x41, 0x6,0x59,0x3b, + 0x6,0x59,0x3f, 0x6,0x59,0x37, 0x6,0x59,0x35, 0x6,0x59,0x43, + 0x6,0x59,0x42, 0x5,0x3c,0x7a, 0x4,0x41,0x32, 0x6,0x59,0x33, + 0x6,0x59,0x3e, 0xf,0x45,0x62, 0xf,0x45,0x63, 0xf,0x45,0x64, + 0xf,0x45,0x65, 0xf,0x45,0x66, 0xf,0x45,0x67, 0xf,0x45,0x68, + 0xf,0x45,0x69, 0xf,0x45,0x6a, 0xf,0x45,0x6b, 0xf,0x45,0x6c, + 0x6,0x59,0x32, 0x6,0x59,0x36, 0x6,0x59,0x3c, 0x6,0x59,0x39, + 0x6,0x59,0x38, 0x6,0x59,0x3a, 0x6,0x59,0x2f, 0x5,0x43,0x58, + 0x5,0x43,0x57, 0x5,0x43,0x56, 0x6,0x63,0x35, 0x6,0x63,0x34, + 0x6,0x63,0x37, 0x6,0x63,0x32, 0x6,0x63,0x3a, 0x5,0x4a,0x54, + 0x6,0x63,0x36, 0x6,0x63,0x38, 0x6,0x63,0x3c, 0x5,0x4a,0x53, + 0x5,0x4a,0x56, 0x6,0x63,0x33, 0x6,0x63,0x3b, 0x7,0x3c,0x55, + 0xf,0x4c,0x69, 0xf,0x4c,0x6a, 0xf,0x4c,0x6c, 0xf,0x4c,0x6d, + 0xf,0x4c,0x6e, 0xf,0x4c,0x6f, 0xf,0x4c,0x70, 0xf,0x4c,0x71, + 0xf,0x4c,0x72, 0x6,0x63,0x39, 0x7,0x3c,0x56, 0x7,0x3c,0x57, + 0x7,0x3c,0x58, 0x5,0x4a,0x55, 0x7,0x29,0x6e, 0x7,0x29,0x6c, + 0x7,0x29,0x72, 0x7,0x29,0x69, 0x7,0x29,0x6b, 0x4,0x4e,0x2f, + 0x5,0x51,0x64, 0x4,0x4e,0x30, 0x5,0x51,0x68, 0x5,0x51,0x65, + 0x4,0x4e,0x34, 0x7,0x29,0x70, 0xf,0x52,0x4e, 0xf,0x52,0x4f, + 0xf,0x52,0x50, 0xf,0x52,0x51, 0xf,0x52,0x52, 0x5,0x51,0x6d, + 0x7,0x29,0x6a, 0x7,0x29,0x6f, 0x7,0x29,0x74, 0x7,0x29,0x75, + 0x7,0x29,0x71, 0x7,0x29,0x73, 0x7,0x43,0x74, 0x7,0x29,0x68, + 0x7,0x43,0x75, 0x7,0x29,0x6d, 0x5,0x51,0x69, 0x5,0x51,0x67, + 0x5,0x51,0x6c, 0x5,0x51,0x66, 0x5,0x51,0x6a, 0x5,0x51,0x6b, + 0x5,0x51,0x63, 0x7,0x34,0x46, 0x5,0x58,0x7c, 0x5,0x58,0x7b, + 0x5,0x58,0x79, 0x7,0x34,0x41, 0x5,0x58,0x77, 0x7,0x34,0x45, + 0x7,0x34,0x3e, 0x7,0x34,0x47, 0x4,0x54,0x36, 0x7,0x34,0x42, + 0x7,0x34,0x44, 0x7,0x34,0x39, 0x7,0x34,0x4a, 0x7,0x4a,0x77, + 0x7,0x34,0x3c, 0x7,0x34,0x40, 0x7,0x34,0x4c, 0xf,0x58,0x3c, + 0xf,0x58,0x3d, 0xf,0x58,0x3e, 0x7,0x34,0x3d, 0xf,0x58,0x3f, + 0x7,0x2c,0x5a, 0x7,0x34,0x48, 0x7,0x34,0x3b, 0x7,0x34,0x3a, + 0x7,0x34,0x43, 0x7,0x34,0x4b, 0x5,0x58,0x78, 0x5,0x58,0x7d, + 0x5,0x58,0x7a, 0x7,0x34,0x3f, 0x5,0x58,0x76, 0x5,0x5f,0x2f, + 0x4,0x59,0x3a, 0x7,0x3c,0x60, 0x5,0x5f,0x33, 0x7,0x3c,0x5d, + 0x5,0x5f,0x34, 0x7,0x3c,0x5b, 0x7,0x50,0x57, 0x7,0x34,0x49, + 0x7,0x3c,0x62, 0x7,0x3c,0x5e, 0x5,0x5f,0x32, 0x5,0x5f,0x35, + 0xf,0x5d,0x24, 0xf,0x5d,0x26, 0xf,0x5d,0x27, 0xf,0x5d,0x28, + 0x7,0x3c,0x59, 0x7,0x3c,0x5c, 0x7,0x3c,0x5f, 0x7,0x3c,0x63, + 0xf,0x5d,0x25, 0x5,0x5f,0x36, 0x5,0x5f,0x37, 0x5,0x5f,0x31, + 0x5,0x5f,0x30, 0x7,0x3c,0x5a, 0x5,0x65,0x3d, 0x7,0x43,0x7c, + 0x4,0x5e,0x22, 0x7,0x43,0x7a, 0x5,0x65,0x3a, 0x7,0x43,0x78, + 0xf,0x61,0x2b, 0xf,0x61,0x2c, 0xf,0x61,0x2d, 0x7,0x44,0x21, + 0x7,0x43,0x7e, 0x5,0x65,0x39, 0x7,0x43,0x7d, 0x7,0x43,0x76, + 0x7,0x43,0x79, 0x5,0x65,0x3c, 0x5,0x65,0x3b, 0x5,0x65,0x38, + 0x7,0x43,0x7b, 0x7,0x4b,0x21, 0x7,0x4b,0x22, 0x7,0x4a,0x7e, + 0xf,0x64,0x2a, 0xf,0x64,0x2b, 0xf,0x64,0x2d, 0xf,0x64,0x2e, + 0x7,0x4a,0x79, 0x7,0x4a,0x7a, 0x7,0x4a,0x7d, 0x7,0x4a,0x7b, + 0x7,0x4a,0x7c, 0x7,0x4a,0x78, 0x5,0x6a,0x21, 0x5,0x69,0x7e, + 0xf,0x64,0x2c, 0x7,0x50,0x5a, 0x5,0x6e,0x29, 0x7,0x50,0x59, + 0x5,0x6e,0x27, 0xf,0x66,0x4c, 0x7,0x50,0x58, 0x5,0x6e,0x28, + 0x7,0x5d,0x22, 0x4,0x67,0x55, 0x7,0x55,0x4f, 0x5,0x71,0x51, + 0x7,0x55,0x50, 0x7,0x55,0x4e, 0xf,0x68,0x55, 0xf,0x68,0x56, + 0xf,0x68,0x57, 0xf,0x68,0x58, 0x5,0x71,0x4f, 0x5,0x71,0x50, + 0x5,0x69,0x7d, 0x7,0x55,0x51, 0x5,0x71,0x52, 0x5,0x74,0x52, + 0x4,0x6b,0x25, 0x7,0x59,0x5b, 0x7,0x59,0x5a, 0x7,0x59,0x59, + 0x7,0x5d,0x23, 0x7,0x5d,0x25, 0x7,0x5d,0x24, 0x7,0x62,0x6a, + 0x7,0x5f,0x6a, 0x7,0x5f,0x69, 0x5,0x78,0x3d, 0x7,0x61,0x55, + 0x7,0x62,0x6b, 0x7,0x65,0x68, 0x6,0x29,0x30, 0x5,0x21,0x7c, + 0x5,0x23,0x2c, 0x5,0x23,0x2b, 0x5,0x23,0x2d, 0x5,0x23,0x2a, + 0x4,0x23,0x31, 0x6,0x25,0x5a, 0x6,0x25,0x5c, 0x4,0x23,0x33, + 0x4,0x25,0x27, 0x5,0x24,0x79, 0x4,0x25,0x26, 0x4,0x25,0x28, + 0x4,0x25,0x25, 0x6,0x29,0x33, 0x4,0x25,0x2a, 0x5,0x24,0x7a, + 0x4,0x35,0x71, 0x6,0x29,0x32, 0xf,0x25,0x35, 0xf,0x25,0x36, + 0xf,0x25,0x37, 0xf,0x38,0x73, 0xf,0x38,0x75, 0x6,0x45,0x61, + 0x6,0x45,0x5f, 0x6,0x45,0x60, 0x6,0x29,0x31, 0x4,0x25,0x29, + 0x4,0x28,0x2e, 0x6,0x45,0x5e, 0x4,0x28,0x2a, 0x4,0x28,0x2d, + 0x4,0x28,0x2c, 0x6,0x34,0x69, 0x4,0x28,0x2f, 0x5,0x27,0x72, + 0x5,0x27,0x73, 0x6,0x4f,0x58, 0x6,0x2e,0x43, 0xf,0x28,0x76, + 0xf,0x28,0x78, 0xf,0x28,0x79, 0xf,0x28,0x7c, 0x6,0x4f,0x5a, + 0x6,0x2e,0x41, 0x6,0x2e,0x42, 0x6,0x2e,0x40, 0xf,0x28,0x77, + 0xf,0x28,0x7b, 0x6,0x4f,0x57, 0x6,0x4f,0x59, 0x5,0x27,0x74, + 0x5,0x2b,0x5a, 0x5,0x2b,0x59, 0x5,0x2b,0x58, 0x4,0x2b,0x57, + 0x4,0x2b,0x55, 0x5,0x2b,0x5f, 0x4,0x41,0x33, 0x5,0x2b,0x5b, + 0xf,0x2d,0x5a, 0xf,0x45,0x6e, 0x6,0x59,0x45, 0x6,0x59,0x44, + 0x6,0x59,0x46, 0x6,0x34,0x6c, 0x6,0x34,0x66, 0x6,0x34,0x67, + 0x6,0x34,0x68, 0x6,0x34,0x6b, 0x6,0x34,0x6a, 0x5,0x2b,0x5e, + 0x5,0x2b,0x5c, 0x5,0x2b,0x5d, 0x5,0x30,0x61, 0x5,0x30,0x5d, + 0x4,0x30,0x36, 0x6,0x3c,0x5b, 0x5,0x30,0x65, 0x5,0x30,0x66, + 0x5,0x30,0x5e, 0x5,0x30,0x63, 0x5,0x30,0x5f, 0x4,0x30,0x35, + 0x6,0x3c,0x5d, 0x4,0x30,0x37, 0x6,0x3c,0x5f, 0x6,0x63,0x3d, + 0x6,0x63,0x3f, 0x6,0x63,0x40, 0x6,0x3c,0x5c, 0x6,0x3c,0x5e, + 0x6,0x3c,0x5a, 0x5,0x30,0x62, 0x5,0x30,0x64, 0x5,0x30,0x60, + 0x5,0x30,0x67, 0x6,0x63,0x3e, 0x6,0x3c,0x59, 0xf,0x32,0x62, + 0xf,0x32,0x63, 0xf,0x32,0x64, 0x5,0x51,0x6e, 0x4,0x4e,0x36, + 0x4,0x35,0x6f, 0x5,0x36,0x31, 0x5,0x36,0x30, 0x5,0x36,0x35, + 0x5,0x36,0x2e, 0x5,0x36,0x32, 0x4,0x35,0x6d, 0x6,0x45,0x66, + 0x5,0x36,0x34, 0x7,0x29,0x7a, 0x7,0x29,0x79, 0x6,0x45,0x68, + 0xf,0x32,0x61, 0xf,0x38,0x76, 0xf,0x52,0x54, 0x7,0x29,0x76, + 0x7,0x29,0x77, 0x7,0x29,0x7b, 0x7,0x29,0x78, 0x6,0x45,0x63, + 0x6,0x45,0x65, 0x6,0x45,0x64, 0x6,0x45,0x62, 0xf,0x33,0x3c, + 0x6,0x45,0x67, 0x5,0x36,0x2f, 0x5,0x36,0x33, 0x5,0x30,0x68, + 0x4,0x3b,0x5f, 0x5,0x3d,0x23, 0x5,0x3c,0x7e, 0x5,0x3d,0x22, + 0x4,0x3b,0x5d, 0x5,0x3d,0x24, 0x6,0x4f,0x64, 0x5,0x3d,0x21, + 0x5,0x43,0x67, 0x5,0x3c,0x7d, 0x5,0x3c,0x7c, 0x6,0x4f,0x62, + 0x6,0x4f,0x5b, 0x4,0x3b,0x5c, 0xf,0x3f,0x63, 0xf,0x3f,0x64, + 0xf,0x3f,0x65, 0xf,0x58,0x41, 0x7,0x34,0x4e, 0x6,0x4f,0x5d, + 0x6,0x4f,0x5c, 0x6,0x4f,0x5e, 0x6,0x4f,0x5f, 0x6,0x4f,0x60, + 0x6,0x4f,0x61, 0xf,0x3f,0x66, 0x6,0x4f,0x63, 0x7,0x34,0x4d, + 0x5,0x3c,0x7b, 0x7,0x3c,0x64, 0x5,0x43,0x5b, 0x5,0x43,0x60, + 0x5,0x43,0x63, 0x5,0x43,0x5e, 0x5,0x43,0x5d, 0x4,0x41,0x35, + 0x6,0x63,0x41, 0x5,0x43,0x5c, 0x5,0x43,0x62, 0x5,0x43,0x5f, + 0x5,0x43,0x64, 0x5,0x43,0x66, 0x4,0x41,0x37, 0x5,0x43,0x65, + 0x6,0x59,0x49, 0x5,0x43,0x5a, 0xf,0x45,0x6f, 0x6,0x59,0x48, + 0x6,0x59,0x4b, 0x5,0x43,0x61, 0x4,0x47,0x6f, 0x5,0x4a,0x5d, + 0x5,0x4a,0x5c, 0x5,0x4a,0x59, 0x5,0x4a,0x58, 0x5,0x4a,0x63, + 0x5,0x4a,0x5f, 0x5,0x4a,0x5b, 0x6,0x63,0x46, 0x6,0x63,0x43, + 0x6,0x63,0x42, 0x5,0x4a,0x61, 0x5,0x4a,0x62, 0x7,0x44,0x22, + 0x7,0x44,0x24, 0x7,0x44,0x23, 0x7,0x44,0x25, 0x6,0x63,0x45, + 0x5,0x4a,0x57, 0x4,0x47,0x72, 0x6,0x63,0x44, 0x5,0x65,0x3e, + 0x5,0x4a,0x5a, 0x5,0x4a,0x5e, 0x5,0x4a,0x64, 0x4,0x4e,0x38, + 0x7,0x4b,0x23, 0x5,0x51,0x72, 0x7,0x2a,0x21, 0x4,0x4e,0x37, + 0x5,0x51,0x73, 0x4,0x4e,0x39, 0x5,0x59,0x28, 0x5,0x51,0x6f, + 0x5,0x51,0x70, 0x7,0x29,0x7e, 0x7,0x2a,0x22, 0x4,0x4e,0x3a, + 0xf,0x52,0x53, 0xf,0x52,0x55, 0xf,0x52,0x56, 0x7,0x4b,0x26, + 0x7,0x4b,0x24, 0x7,0x2a,0x23, 0x7,0x2a,0x25, 0x7,0x2a,0x26, + 0x7,0x2a,0x24, 0x7,0x29,0x7c, 0x7,0x29,0x7d, 0x5,0x51,0x74, + 0x7,0x34,0x50, 0x5,0x51,0x71, 0x7,0x4b,0x25, 0x5,0x6e,0x2a, + 0x5,0x59,0x25, 0x5,0x59,0x26, 0x7,0x50,0x5c, 0x4,0x54,0x38, + 0x7,0x34,0x4f, 0x5,0x59,0x21, 0x5,0x59,0x24, 0x7,0x34,0x52, + 0x5,0x59,0x22, 0x5,0x59,0x23, 0x4,0x54,0x39, 0x7,0x34,0x51, + 0xf,0x58,0x40, 0x7,0x50,0x5d, 0x7,0x50,0x5b, 0x5,0x6e,0x2b, + 0x7,0x3c,0x65, 0x7,0x3c,0x69, 0x5,0x5f,0x38, 0x4,0x59,0x3b, + 0x5,0x5f,0x39, 0x7,0x55,0x52, 0x7,0x55,0x53, 0x7,0x55,0x54, + 0x7,0x3c,0x67, 0x7,0x3c,0x6a, 0x7,0x3c,0x66, 0x5,0x5f,0x3b, + 0x5,0x5f,0x3a, 0x7,0x55,0x55, 0x7,0x3c,0x68, 0x5,0x65,0x40, + 0x7,0x44,0x26, 0x7,0x44,0x27, 0x5,0x65,0x41, 0x5,0x6a,0x25, + 0x5,0x65,0x44, 0x7,0x44,0x29, 0x7,0x44,0x28, 0x5,0x65,0x42, + 0x5,0x65,0x43, 0x7,0x59,0x5c, 0x5,0x65,0x3f, 0x7,0x44,0x2a, + 0x7,0x4b,0x28, 0x7,0x44,0x2b, 0x5,0x6a,0x24, 0x7,0x4b,0x27, + 0x5,0x6a,0x23, 0x7,0x4b,0x2a, 0x7,0x4b,0x29, 0x4,0x61,0x60, + 0x5,0x59,0x27, 0x5,0x6a,0x22, 0x4,0x64,0x64, 0x5,0x6e,0x2c, + 0x7,0x50,0x5f, 0x7,0x50,0x61, 0x7,0x50,0x5e, 0x7,0x50,0x60, + 0x4,0x67,0x56, 0xf,0x68,0x59, 0x7,0x55,0x56, 0x7,0x55,0x57, + 0x7,0x59,0x5d, 0x7,0x55,0x58, 0xf,0x68,0x5a, 0x7,0x5d,0x26, + 0x7,0x5f,0x6b, 0x7,0x5f,0x6c, 0x5,0x7b,0x4b, 0x7,0x63,0x78, + 0x4,0x30,0x39, 0xf,0x32,0x65, 0x6,0x3c,0x60, 0x5,0x36,0x38, + 0x5,0x36,0x37, 0x6,0x45,0x72, 0x6,0x45,0x6e, 0x5,0x36,0x39, + 0x4,0x35,0x76, 0x6,0x45,0x6c, 0x6,0x45,0x73, 0x6,0x45,0x69, + 0x4,0x35,0x77, 0x5,0x36,0x3a, 0x6,0x45,0x70, 0x6,0x45,0x6f, + 0x6,0x45,0x6a, 0x6,0x45,0x6b, 0xf,0x38,0x77, 0x6,0x45,0x71, + 0x4,0x35,0x79, 0x6,0x45,0x6d, 0x6,0x45,0x74, 0x6,0x4f,0x6b, + 0x5,0x3d,0x25, 0x5,0x3d,0x26, 0x4,0x3b,0x65, 0x6,0x4f,0x69, + 0x5,0x43,0x6a, 0x4,0x3b,0x62, 0x4,0x3b,0x63, 0x6,0x4f,0x6a, + 0x6,0x4f,0x66, 0x6,0x4f,0x65, 0x4,0x3b,0x61, 0x6,0x4f,0x67, + 0x6,0x4f,0x68, 0xf,0x3f,0x68, 0xf,0x3f,0x69, 0xf,0x3f,0x6a, + 0xf,0x3f,0x6b, 0x6,0x4f,0x6c, 0x5,0x43,0x69, 0x5,0x43,0x6c, + 0x5,0x43,0x68, 0x6,0x59,0x4e, 0x6,0x59,0x4d, 0x5,0x43,0x6b, + 0x6,0x63,0x4a, 0x5,0x4a,0x66, 0x5,0x4a,0x65, 0xf,0x4c,0x73, + 0xf,0x4c,0x74, 0xf,0x4c,0x75, 0xf,0x4c,0x77, 0x6,0x63,0x49, + 0x6,0x63,0x48, 0xf,0x4c,0x78, 0x6,0x63,0x47, 0x7,0x2a,0x28, + 0x5,0x51,0x78, 0x7,0x2a,0x2c, 0x5,0x51,0x79, 0x5,0x51,0x75, + 0x7,0x2a,0x30, 0x5,0x51,0x76, 0x7,0x2a,0x2f, 0x7,0x2a,0x2e, + 0x7,0x2a,0x2d, 0x7,0x2a,0x29, 0x7,0x2a,0x27, 0x5,0x51,0x77, + 0xf,0x4c,0x76, 0xf,0x52,0x58, 0xf,0x52,0x59, 0x7,0x2a,0x2a, + 0x7,0x2a,0x2b, 0x7,0x2a,0x32, 0x7,0x2a,0x31, 0x7,0x34,0x56, + 0x7,0x34,0x55, 0x5,0x59,0x29, 0x7,0x34,0x58, 0x5,0x59,0x2c, + 0x7,0x34,0x5a, 0x4,0x54,0x41, 0x7,0x34,0x5f, 0x4,0x54,0x3e, + 0x4,0x54,0x3f, 0x7,0x34,0x5e, 0x5,0x59,0x2a, 0x7,0x34,0x57, + 0x7,0x34,0x5d, 0x7,0x34,0x5c, 0x5,0x59,0x2b, 0xf,0x58,0x42, + 0xf,0x58,0x43, 0x7,0x34,0x59, 0x7,0x34,0x5b, 0x7,0x34,0x53, + 0x7,0x34,0x60, 0x5,0x5f,0x41, 0x5,0x5f,0x3f, 0x5,0x5f,0x40, + 0x5,0x5f,0x43, 0x4,0x59,0x40, 0x7,0x3c,0x6c, 0x5,0x5f,0x42, + 0x4,0x59,0x3e, 0x7,0x3c,0x6e, 0x5,0x5f,0x3e, 0x7,0x3c,0x74, + 0x5,0x5f,0x44, 0x7,0x3c,0x6d, 0x7,0x3c,0x73, 0xf,0x5d,0x2a, + 0xf,0x5d,0x2b, 0xf,0x5d,0x2c, 0x7,0x3c,0x6f, 0x7,0x3c,0x71, + 0x7,0x3c,0x72, 0x5,0x5f,0x3d, 0x5,0x65,0x46, 0x5,0x65,0x47, + 0x5,0x65,0x49, 0x7,0x44,0x33, 0x7,0x44,0x2f, 0x4,0x5e,0x23, + 0x7,0x44,0x2c, 0x5,0x65,0x48, 0x4,0x5e,0x26, 0x5,0x65,0x4a, + 0x7,0x3c,0x75, 0x4,0x5e,0x25, 0x7,0x44,0x32, 0x5,0x65,0x4b, + 0x7,0x44,0x35, 0x7,0x44,0x36, 0x7,0x44,0x2d, 0xf,0x61,0x2e, + 0x7,0x44,0x31, 0x7,0x44,0x2e, 0x5,0x65,0x4c, 0x7,0x44,0x30, + 0x7,0x4b,0x2f, 0x7,0x4b,0x2c, 0x5,0x6a,0x2e, 0x5,0x6a,0x2b, + 0x5,0x6a,0x27, 0x5,0x6a,0x2a, 0x5,0x6a,0x29, 0x5,0x6a,0x2f, + 0x5,0x6a,0x2c, 0x5,0x6a,0x28, 0x5,0x6a,0x2d, 0x7,0x4b,0x2d, + 0x7,0x4b,0x2e, 0x7,0x4b,0x30, 0x7,0x4b,0x2b, 0x7,0x44,0x34, + 0x5,0x6a,0x30, 0x5,0x6a,0x26, 0x7,0x50,0x62, 0x5,0x6e,0x31, + 0x5,0x6e,0x2e, 0x5,0x6e,0x2f, 0x5,0x6e,0x2d, 0x5,0x6e,0x30, + 0x7,0x50,0x63, 0x7,0x50,0x64, 0xf,0x66,0x4e, 0x7,0x50,0x65, + 0x7,0x50,0x67, 0x7,0x50,0x66, 0x4,0x67,0x59, 0x4,0x67,0x57, + 0x4,0x67,0x58, 0x5,0x71,0x53, 0x7,0x55,0x5a, 0xf,0x68,0x5b, + 0x7,0x55,0x59, 0x7,0x59,0x5e, 0x7,0x59,0x5f, 0x7,0x59,0x62, + 0x5,0x74,0x53, 0x7,0x59,0x61, 0x7,0x59,0x60, 0xf,0x69,0x7d, + 0x7,0x5d,0x27, 0x7,0x5d,0x29, 0x5,0x76,0x5a, 0x7,0x5d,0x2b, + 0x7,0x5d,0x2a, 0x5,0x76,0x5b, 0x7,0x5d,0x28, 0xf,0x6a,0x7a, + 0x5,0x78,0x3f, 0x4,0x6c,0x2f, 0x7,0x5f,0x6d, 0x7,0x5f,0x6e, + 0x5,0x78,0x3e, 0x7,0x62,0x6c, 0x5,0x7a,0x7b, 0x7,0x63,0x7a, + 0x7,0x63,0x79, 0x7,0x64,0x66, 0x7,0x64,0x65, 0x7,0x65,0x78, + 0x7,0x65,0x79, 0x6,0x34,0x6e, 0x5,0x3d,0x27, 0x5,0x36,0x3b, + 0x6,0x63,0x4b, 0x6,0x63,0x4c, 0x5,0x51,0x7a, 0x7,0x2a,0x34, + 0x7,0x2a,0x33, 0x5,0x59,0x2d, 0x7,0x34,0x61, 0x5,0x5f,0x45, + 0xf,0x5d,0x2d, 0x7,0x44,0x37, 0xf,0x66,0x4f, 0xf,0x68,0x5c, + 0x5,0x74,0x54, 0x5,0x36,0x3c, 0x6,0x3c,0x61, 0x6,0x45,0x75, + 0x6,0x4f,0x6e, 0x5,0x3d,0x29, 0x5,0x3d,0x28, 0xf,0x45,0x70, + 0x6,0x63,0x4d, 0x7,0x2a,0x35, 0x5,0x5f,0x46, 0xf,0x61,0x2f, + 0x5,0x65,0x4d, 0xf,0x68,0x5d, 0x5,0x71,0x54, 0x7,0x55,0x5b, + 0x6,0x3c,0x64, 0xf,0x32,0x66, 0x6,0x3c,0x62, 0x5,0x36,0x3d, + 0x6,0x45,0x76, 0x6,0x45,0x77, 0xf,0x38,0x78, 0x6,0x4f,0x73, + 0x6,0x4f,0x74, 0x6,0x4f,0x75, 0x6,0x4f,0x71, 0x6,0x4f,0x72, + 0x6,0x4f,0x78, 0x6,0x4f,0x76, 0x6,0x4f,0x70, 0x6,0x4f,0x79, + 0xf,0x3f,0x6c, 0xf,0x3f,0x6d, 0xf,0x3f,0x6e, 0xf,0x3f,0x6f, + 0xf,0x3f,0x72, 0xf,0x3f,0x74, 0xf,0x3f,0x71, 0x6,0x4f,0x77, + 0xf,0x3f,0x70, 0x4,0x41,0x47, 0x5,0x43,0x6e, 0x4,0x41,0x45, + 0x4,0x41,0x44, 0x6,0x59,0x53, 0x6,0x59,0x4f, 0xf,0x45,0x71, + 0xf,0x45,0x75, 0xf,0x45,0x76, 0xf,0x45,0x77, 0xf,0x45,0x78, + 0x6,0x59,0x55, 0x6,0x59,0x51, 0x6,0x59,0x52, 0xf,0x45,0x79, + 0x6,0x59,0x54, 0x6,0x59,0x50, 0xf,0x45,0x74, 0x5,0x4a,0x67, + 0x5,0x4a,0x68, 0x6,0x63,0x52, 0x5,0x4a,0x69, 0xf,0x4c,0x68, + 0xf,0x4c,0x79, 0xf,0x4c,0x7b, 0xf,0x4c,0x7c, 0xf,0x4c,0x7d, + 0xf,0x4d,0x21, 0xf,0x4d,0x23, 0xf,0x4d,0x24, 0xf,0x4d,0x25, + 0xf,0x4d,0x28, 0xf,0x4d,0x29, 0x6,0x63,0x4e, 0x4,0x47,0x7a, + 0x6,0x63,0x50, 0x6,0x63,0x51, 0xf,0x4d,0x2a, 0x6,0x63,0x54, + 0xf,0x4c,0x7a, 0x6,0x63,0x55, 0xf,0x4d,0x2b, 0xf,0x4d,0x26, + 0xf,0x4c,0x7e, 0x7,0x2a,0x3a, 0x4,0x4e,0x42, 0x5,0x51,0x7e, + 0x7,0x2a,0x41, 0x7,0x2a,0x3b, 0x7,0x2a,0x40, 0x7,0x2a,0x39, + 0x5,0x51,0x7d, 0x7,0x2a,0x43, 0x7,0x2a,0x44, 0x7,0x2a,0x3d, + 0x5,0x51,0x7b, 0x7,0x2a,0x37, 0xf,0x52,0x5b, 0xf,0x52,0x5d, + 0xf,0x52,0x5f, 0xf,0x52,0x60, 0xf,0x52,0x63, 0xf,0x52,0x64, + 0xf,0x52,0x65, 0xf,0x52,0x67, 0xf,0x52,0x68, 0xf,0x52,0x69, + 0xf,0x52,0x6a, 0xf,0x52,0x6c, 0xf,0x52,0x6d, 0x7,0x2a,0x42, + 0x7,0x2a,0x3c, 0x7,0x2a,0x3f, 0x7,0x2a,0x45, 0xf,0x52,0x5e, + 0x7,0x2a,0x36, 0x5,0x51,0x7c, 0xf,0x52,0x62, 0xf,0x52,0x66, + 0xf,0x52,0x5a, 0x5,0x59,0x34, 0x5,0x59,0x37, 0x5,0x59,0x32, + 0x4,0x54,0x47, 0x5,0x59,0x2e, 0x5,0x59,0x30, 0x7,0x34,0x65, + 0x7,0x34,0x64, 0x7,0x34,0x6b, 0x7,0x34,0x69, 0x7,0x34,0x67, + 0x5,0x59,0x36, 0x4,0x54,0x44, 0x7,0x34,0x62, 0x7,0x34,0x6a, + 0x7,0x34,0x68, 0x5,0x59,0x2f, 0x7,0x34,0x66, 0xf,0x52,0x5c, + 0x5,0x59,0x33, 0xf,0x58,0x44, 0xf,0x58,0x46, 0xf,0x58,0x47, + 0xf,0x58,0x49, 0xf,0x58,0x4a, 0xf,0x58,0x4b, 0xf,0x58,0x4d, + 0xf,0x58,0x4e, 0xf,0x58,0x4f, 0xf,0x58,0x51, 0xf,0x58,0x53, + 0xf,0x58,0x54, 0xf,0x58,0x56, 0xf,0x58,0x57, 0xf,0x58,0x5a, + 0xf,0x58,0x5c, 0xf,0x58,0x5d, 0xf,0x58,0x5e, 0xf,0x58,0x60, + 0xf,0x58,0x61, 0xf,0x58,0x63, 0xf,0x58,0x64, 0xf,0x58,0x50, + 0xf,0x58,0x52, 0xf,0x58,0x5f, 0xf,0x58,0x45, 0xf,0x58,0x58, + 0x5,0x59,0x38, 0x5,0x59,0x31, 0x5,0x5f,0x48, 0x5,0x5f,0x49, + 0x7,0x3c,0x79, 0x4,0x59,0x43, 0x5,0x5f,0x4c, 0x5,0x5f,0x4b, + 0x7,0x3c,0x7c, 0x5,0x59,0x35, 0x5,0x5f,0x47, 0x7,0x3c,0x7a, + 0x5,0x5f,0x4a, 0x5,0x5f,0x4f, 0x7,0x3c,0x7e, 0x7,0x3d,0x24, + 0x7,0x3d,0x21, 0x7,0x3d,0x25, 0xf,0x5d,0x2f, 0xf,0x5d,0x30, + 0xf,0x5d,0x34, 0xf,0x5d,0x35, 0xf,0x5d,0x36, 0xf,0x5d,0x37, + 0xf,0x5d,0x3a, 0xf,0x5d,0x3b, 0xf,0x5d,0x3c, 0xf,0x5d,0x3d, + 0xf,0x5d,0x3f, 0xf,0x5d,0x40, 0xf,0x5d,0x42, 0xf,0x5d,0x43, + 0xf,0x5d,0x44, 0xf,0x5d,0x45, 0xf,0x5d,0x46, 0xf,0x5d,0x47, + 0xf,0x5d,0x48, 0xf,0x5d,0x49, 0xf,0x5d,0x4b, 0xf,0x5d,0x4e, + 0xf,0x5d,0x4f, 0x7,0x3c,0x7d, 0x7,0x3d,0x22, 0x7,0x3c,0x78, + 0x7,0x3d,0x23, 0x4,0x59,0x48, 0xf,0x5d,0x4a, 0xf,0x5d,0x38, + 0xf,0x5d,0x33, 0xf,0x5d,0x31, 0x5,0x5f,0x4e, 0x5,0x5f,0x4d, + 0xf,0x5d,0x2e, 0x5,0x65,0x51, 0x4,0x5e,0x2d, 0x4,0x5e,0x2e, + 0x5,0x65,0x52, 0x4,0x5e,0x28, 0x4,0x5e,0x2a, 0x7,0x44,0x38, + 0x5,0x65,0x50, 0x5,0x65,0x4e, 0x5,0x6a,0x31, 0x7,0x44,0x3a, + 0x5,0x65,0x53, 0x4,0x5e,0x30, 0x7,0x44,0x40, 0x7,0x44,0x3f, + 0x5,0x65,0x54, 0x5,0x65,0x55, 0x7,0x44,0x41, 0xf,0x61,0x31, + 0xf,0x61,0x32, 0xf,0x61,0x34, 0xf,0x61,0x36, 0xf,0x61,0x37, + 0xf,0x61,0x38, 0xf,0x61,0x3a, 0xf,0x61,0x3c, 0xf,0x61,0x3d, + 0xf,0x61,0x3e, 0xf,0x61,0x40, 0xf,0x61,0x41, 0xf,0x61,0x42, + 0xf,0x61,0x44, 0xf,0x61,0x45, 0xf,0x61,0x46, 0x7,0x44,0x3b, + 0x7,0x44,0x3c, 0x7,0x44,0x3e, 0x7,0x44,0x3d, 0xf,0x61,0x30, + 0xf,0x61,0x39, 0xf,0x61,0x35, 0xf,0x5f,0x5d, 0x4,0x61,0x6b, + 0x7,0x4b,0x33, 0x7,0x4b,0x37, 0x5,0x6a,0x32, 0x7,0x4b,0x34, + 0x5,0x6a,0x34, 0x7,0x4b,0x32, 0x7,0x4b,0x3a, 0x7,0x4b,0x36, + 0x7,0x4b,0x39, 0x7,0x4b,0x3b, 0xf,0x64,0x31, 0xf,0x64,0x32, + 0xf,0x64,0x33, 0xf,0x64,0x35, 0xf,0x64,0x36, 0xf,0x64,0x38, + 0xf,0x64,0x39, 0xf,0x64,0x3a, 0xf,0x64,0x3b, 0xf,0x64,0x3c, + 0xf,0x64,0x3d, 0xf,0x64,0x3f, 0xf,0x64,0x40, 0xf,0x64,0x41, + 0xf,0x64,0x42, 0xf,0x64,0x43, 0xf,0x64,0x44, 0xf,0x64,0x45, + 0x7,0x4b,0x3c, 0x7,0x4b,0x35, 0x7,0x4b,0x38, 0x4,0x61,0x6a, + 0x7,0x4b,0x31, 0x5,0x65,0x56, 0xf,0x64,0x3e, 0x4,0x64,0x68, + 0x7,0x50,0x6d, 0x7,0x50,0x6e, 0x5,0x6e,0x38, 0x7,0x50,0x72, + 0x5,0x6e,0x33, 0x4,0x64,0x6a, 0x5,0x6e,0x36, 0x5,0x6e,0x32, + 0x7,0x50,0x70, 0x7,0x50,0x68, 0x7,0x50,0x69, 0x5,0x6e,0x37, + 0x4,0x64,0x6e, 0x7,0x50,0x71, 0x5,0x6e,0x34, 0xf,0x66,0x50, + 0xf,0x66,0x51, 0xf,0x66,0x53, 0xf,0x66,0x54, 0xf,0x66,0x55, + 0xf,0x66,0x56, 0xf,0x66,0x58, 0xf,0x66,0x59, 0xf,0x66,0x5a, + 0xf,0x66,0x5b, 0xf,0x66,0x5d, 0xf,0x66,0x5f, 0xf,0x66,0x60, + 0xf,0x66,0x61, 0xf,0x66,0x62, 0xf,0x66,0x63, 0xf,0x66,0x64, + 0xf,0x66,0x66, 0xf,0x66,0x68, 0xf,0x66,0x6a, 0xf,0x66,0x6b, + 0xf,0x66,0x6c, 0xf,0x66,0x6d, 0xf,0x66,0x6e, 0xf,0x66,0x6f, + 0x7,0x50,0x6c, 0x7,0x50,0x6f, 0xf,0x66,0x52, 0xf,0x66,0x5c, + 0xf,0x66,0x67, 0x7,0x50,0x6a, 0x7,0x55,0x62, 0x4,0x67,0x5e, + 0x7,0x55,0x67, 0x7,0x55,0x61, 0x7,0x55,0x5c, 0x4,0x67,0x60, + 0x4,0x67,0x5d, 0x7,0x55,0x60, 0x7,0x55,0x63, 0x7,0x55,0x69, + 0x7,0x55,0x5e, 0xf,0x68,0x5e, 0xf,0x68,0x5f, 0xf,0x68,0x60, + 0xf,0x68,0x61, 0xf,0x68,0x62, 0xf,0x68,0x63, 0xf,0x68,0x64, + 0xf,0x68,0x65, 0xf,0x68,0x66, 0xf,0x68,0x67, 0xf,0x68,0x68, + 0xf,0x68,0x69, 0xf,0x68,0x6b, 0xf,0x68,0x6c, 0xf,0x68,0x6d, + 0xf,0x68,0x6e, 0xf,0x68,0x6f, 0x7,0x55,0x5f, 0x7,0x55,0x64, + 0x7,0x55,0x65, 0x7,0x55,0x66, 0x7,0x55,0x5d, 0xf,0x68,0x6a, + 0x5,0x74,0x57, 0x7,0x59,0x6b, 0x7,0x59,0x6a, 0x7,0x5d,0x30, + 0x7,0x59,0x66, 0x7,0x59,0x64, 0xf,0x69,0x7e, 0xf,0x6a,0x21, + 0xf,0x6a,0x22, 0xf,0x6a,0x23, 0xf,0x6a,0x24, 0xf,0x6a,0x25, + 0xf,0x6a,0x26, 0xf,0x6a,0x27, 0xf,0x6a,0x28, 0xf,0x6a,0x29, + 0xf,0x6a,0x2a, 0xf,0x6a,0x2b, 0x7,0x59,0x63, 0x7,0x59,0x65, + 0x5,0x74,0x56, 0x5,0x76,0x5e, 0x4,0x6b,0x28, 0x5,0x76,0x5c, + 0xf,0x6b,0x2f, 0x7,0x5d,0x2f, 0x7,0x5d,0x2d, 0x7,0x59,0x69, + 0x7,0x5d,0x2c, 0xf,0x6a,0x7c, 0xf,0x6a,0x7d, 0xf,0x6b,0x23, + 0xf,0x6b,0x24, 0xf,0x6b,0x25, 0xf,0x6b,0x26, 0xf,0x6b,0x29, + 0xf,0x6b,0x2a, 0xf,0x6b,0x2b, 0xf,0x6b,0x2c, 0xf,0x6b,0x2d, + 0xf,0x6b,0x2e, 0x7,0x5d,0x2e, 0x7,0x5d,0x31, 0xf,0x6b,0x21, + 0xf,0x6a,0x7e, 0xf,0x6b,0x27, 0x5,0x78,0x40, 0x7,0x5f,0x70, + 0x7,0x5f,0x71, 0x7,0x5f,0x72, 0x7,0x5f,0x6f, 0x7,0x5f,0x73, + 0xf,0x6b,0x68, 0xf,0x6b,0x69, 0xf,0x6b,0x6a, 0xf,0x6b,0x6b, + 0xf,0x6b,0x6c, 0x4,0x6d,0x63, 0x7,0x61,0x57, 0x7,0x61,0x58, + 0xf,0x6b,0x6d, 0xf,0x6c,0x3c, 0xf,0x6c,0x3d, 0x7,0x61,0x56, + 0x7,0x62,0x72, 0x7,0x62,0x6d, 0x7,0x62,0x6e, 0x7,0x62,0x74, + 0x7,0x62,0x70, 0x7,0x62,0x6f, 0x5,0x7a,0x40, 0x7,0x62,0x73, + 0x7,0x62,0x71, 0x7,0x62,0x75, 0xf,0x6c,0x52, 0xf,0x6c,0x53, + 0xf,0x6c,0x54, 0xf,0x6c,0x55, 0xf,0x6c,0x56, 0xf,0x6c,0x57, + 0xf,0x6c,0x58, 0xf,0x6c,0x40, 0x5,0x7a,0x41, 0x5,0x7a,0x7c, + 0x7,0x63,0x7d, 0x7,0x63,0x7b, 0xf,0x6c,0x6f, 0x7,0x63,0x7c, + 0xf,0x6d,0x23, 0x7,0x64,0x68, 0xf,0x6d,0x21, 0x7,0x64,0x67, + 0x7,0x64,0x69, 0xf,0x6d,0x22, 0xf,0x6c,0x3e, 0x7,0x65,0x48, + 0x7,0x65,0x49, 0xf,0x6d,0x29, 0x5,0x7c,0x21, 0xf,0x6d,0x35, + 0xf,0x6d,0x38, 0xf,0x6d,0x39, 0x6,0x2e,0x44, 0x6,0x29,0x34, + 0x5,0x2b,0x60, 0x5,0x36,0x3f, 0x6,0x45,0x7b, 0x5,0x36,0x3e, + 0x5,0x36,0x40, 0x6,0x45,0x7a, 0xf,0x38,0x79, 0x6,0x45,0x79, + 0x6,0x45,0x78, 0x5,0x3d,0x2a, 0x5,0x3d,0x2b, 0x4,0x3b,0x68, + 0x6,0x4f,0x7a, 0x6,0x4f,0x7b, 0xf,0x3f,0x75, 0x6,0x59,0x59, + 0x6,0x59,0x58, 0x4,0x41,0x4a, 0x6,0x59,0x56, 0x6,0x59,0x57, + 0xf,0x45,0x7a, 0x5,0x43,0x70, 0x5,0x43,0x6f, 0x5,0x4a,0x6a, + 0x4,0x47,0x7c, 0x6,0x63,0x56, 0x6,0x63,0x57, 0x5,0x4a,0x6b, + 0x5,0x52,0x21, 0x5,0x52,0x23, 0x5,0x59,0x39, 0x5,0x52,0x22, + 0x5,0x52,0x24, 0x5,0x52,0x25, 0xf,0x58,0x65, 0x5,0x59,0x3b, + 0x7,0x34,0x6e, 0x5,0x59,0x3a, 0x7,0x3d,0x26, 0x7,0x34,0x6d, + 0x7,0x34,0x70, 0x7,0x34,0x6c, 0x7,0x3d,0x29, 0x4,0x59,0x4a, + 0x5,0x5f,0x50, 0x4,0x59,0x4b, 0x7,0x3d,0x2a, 0x7,0x3d,0x28, + 0x7,0x3d,0x27, 0x7,0x44,0x43, 0x5,0x65,0x58, 0x7,0x44,0x42, + 0x5,0x65,0x57, 0x5,0x6a,0x38, 0x5,0x6a,0x36, 0x5,0x6a,0x35, + 0x5,0x6a,0x37, 0x5,0x6e,0x39, 0x7,0x50,0x73, 0x7,0x50,0x74, + 0x4,0x67,0x64, 0x7,0x55,0x6a, 0x7,0x59,0x6d, 0x7,0x59,0x6e, + 0x7,0x59,0x6c, 0x5,0x76,0x61, 0x5,0x76,0x60, 0x5,0x78,0x41, + 0x7,0x5f,0x74, 0x7,0x62,0x76, 0x7,0x64,0x6a, 0x5,0x2b,0x61, + 0x5,0x30,0x6a, 0x5,0x30,0x6b, 0x5,0x30,0x69, 0xf,0x32,0x67, + 0x6,0x3c,0x66, 0x5,0x36,0x42, 0x5,0x36,0x41, 0xf,0x38,0x7a, + 0xf,0x38,0x7b, 0x6,0x45,0x7c, 0x5,0x3d,0x33, 0x5,0x3d,0x31, + 0x5,0x3d,0x2f, 0x4,0x3b,0x6a, 0x5,0x3d,0x30, 0x4,0x3b,0x6c, + 0x3,0x3f,0x6d, 0x5,0x3d,0x2c, 0x5,0x3d,0x2d, 0x5,0x3d,0x2e, + 0x6,0x4f,0x7e, 0x6,0x50,0x21, 0x5,0x3d,0x32, 0x6,0x4f,0x7c, + 0xf,0x3f,0x78, 0xf,0x3f,0x79, 0xf,0x3f,0x7a, 0xf,0x3f,0x7b, + 0xf,0x3f,0x7c, 0xf,0x3f,0x7d, 0xf,0x40,0x21, 0x6,0x4f,0x7d, + 0x4,0x3b,0x69, 0x4,0x41,0x4c, 0x6,0x59,0x5e, 0x4,0x41,0x52, + 0x4,0x41,0x4d, 0x4,0x41,0x4b, 0xf,0x45,0x7e, 0x6,0x59,0x5d, + 0x5,0x43,0x74, 0x5,0x43,0x71, 0x5,0x43,0x73, 0x5,0x43,0x72, + 0x6,0x59,0x5b, 0x4,0x41,0x51, 0x4,0x41,0x4f, 0x6,0x59,0x5c, + 0x6,0x59,0x5a, 0xf,0x45,0x7d, 0xf,0x46,0x21, 0x5,0x4a,0x73, + 0x5,0x4a,0x6f, 0x5,0x4a,0x71, 0x4,0x47,0x7e, 0x5,0x4a,0x6d, + 0x4,0x48,0x21, 0x5,0x4a,0x74, 0x6,0x63,0x5a, 0x5,0x4a,0x70, + 0x5,0x4a,0x75, 0x4,0x47,0x7d, 0x5,0x4a,0x72, 0x5,0x4a,0x76, + 0x6,0x63,0x59, 0x6,0x63,0x5b, 0x6,0x63,0x5c, 0x5,0x4a,0x6c, + 0x7,0x2a,0x48, 0x5,0x52,0x2d, 0x5,0x52,0x28, 0x7,0x2a,0x4d, + 0x5,0x52,0x2a, 0x5,0x52,0x27, 0x7,0x2a,0x4e, 0x4,0x4e,0x49, + 0x5,0x52,0x2c, 0x5,0x52,0x29, 0x7,0x2a,0x4c, 0xf,0x52,0x6e, + 0xf,0x52,0x6f, 0xf,0x52,0x71, 0x7,0x2a,0x47, 0x7,0x2a,0x49, + 0x7,0x2a,0x4a, 0x7,0x2a,0x4b, 0x5,0x52,0x26, 0x5,0x52,0x2b, + 0x5,0x52,0x2e, 0xf,0x52,0x70, 0x4,0x54,0x50, 0x4,0x54,0x4d, + 0x5,0x59,0x3d, 0x5,0x59,0x40, 0x7,0x34,0x72, 0x5,0x59,0x3c, + 0x5,0x59,0x3e, 0x5,0x59,0x3f, 0x7,0x34,0x75, 0x7,0x34,0x77, + 0x7,0x34,0x79, 0xf,0x58,0x66, 0xf,0x58,0x67, 0xf,0x58,0x68, + 0x7,0x34,0x74, 0x7,0x34,0x78, 0x7,0x34,0x76, 0x4,0x54,0x4e, + 0x4,0x59,0x53, 0x4,0x59,0x51, 0x5,0x5f,0x54, 0x7,0x3d,0x2b, + 0x5,0x5f,0x51, 0x5,0x5f,0x53, 0x5,0x5f,0x55, 0x5,0x5f,0x52, + 0x7,0x3d,0x2d, 0x4,0x59,0x50, 0x7,0x3d,0x2c, 0x4,0x59,0x4c, + 0x7,0x3d,0x2e, 0xf,0x5d,0x50, 0x7,0x3d,0x2f, 0x7,0x3d,0x30, + 0x7,0x3d,0x31, 0x5,0x65,0x5f, 0x5,0x65,0x5e, 0x5,0x65,0x5a, + 0x4,0x5e,0x33, 0x7,0x44,0x44, 0x5,0x65,0x5b, 0x5,0x65,0x61, + 0x5,0x65,0x60, 0x7,0x44,0x46, 0x5,0x65,0x5d, 0x5,0x65,0x59, + 0x5,0x65,0x5c, 0xf,0x61,0x47, 0xf,0x61,0x48, 0xf,0x61,0x49, + 0xf,0x61,0x4c, 0xf,0x61,0x4b, 0x7,0x44,0x45, 0x7,0x44,0x47, + 0x5,0x6a,0x39, 0x7,0x4b,0x3e, 0x7,0x4b,0x3f, 0x4,0x61,0x6d, + 0x5,0x6a,0x3a, 0x7,0x4b,0x3d, 0x4,0x61,0x6e, 0xf,0x64,0x46, + 0xf,0x64,0x47, 0xf,0x64,0x48, 0xf,0x64,0x49, 0xf,0x64,0x4a, + 0x4,0x64,0x70, 0x5,0x6e,0x3f, 0x5,0x6e,0x3a, 0x5,0x6e,0x3d, + 0x5,0x6e,0x3c, 0x5,0x6e,0x3e, 0x5,0x6e,0x40, 0x4,0x64,0x72, + 0x7,0x50,0x78, 0x5,0x6a,0x3b, 0x7,0x50,0x75, 0xf,0x66,0x70, + 0xf,0x66,0x71, 0x7,0x50,0x76, 0x5,0x6e,0x3b, 0x7,0x50,0x77, + 0x5,0x71,0x5a, 0x5,0x6e,0x41, 0x4,0x67,0x65, 0x5,0x71,0x59, + 0x5,0x71,0x57, 0xf,0x68,0x70, 0xf,0x68,0x71, 0xf,0x68,0x73, + 0xf,0x68,0x74, 0xf,0x68,0x75, 0x5,0x71,0x5c, 0x5,0x71,0x58, + 0x5,0x74,0x58, 0x7,0x55,0x6b, 0xf,0x6a,0x2f, 0x7,0x59,0x6f, + 0xf,0x6a,0x2c, 0xf,0x6a,0x2d, 0xf,0x6a,0x2e, 0xf,0x6a,0x30, + 0xf,0x6a,0x31, 0xf,0x6b,0x30, 0xf,0x6b,0x31, 0xf,0x6b,0x32, + 0x7,0x5d,0x32, 0x5,0x78,0x42, 0xf,0x6b,0x6e, 0xf,0x6b,0x6f, + 0x7,0x5f,0x76, 0x7,0x5f,0x75, 0x5,0x79,0x54, 0x4,0x6d,0x29, + 0x4,0x6d,0x2a, 0x7,0x61,0x59, 0x7,0x62,0x77, 0x7,0x62,0x78, + 0x5,0x7a,0x7d, 0xf,0x6d,0x2a, 0x6,0x2e,0x45, 0x5,0x22,0x22, + 0x5,0x21,0x7e, 0x4,0x22,0x23, 0x5,0x22,0x23, 0x4,0x22,0x22, + 0x5,0x22,0x21, 0x5,0x23,0x2e, 0x4,0x23,0x34, 0x6,0x25,0x5d, + 0x5,0x24,0x7d, 0x4,0x25,0x2c, 0x4,0x25,0x2d, 0x5,0x24,0x7e, + 0x5,0x24,0x7c, 0xf,0x25,0x3a, 0xf,0x25,0x3b, 0xf,0x25,0x3c, + 0xf,0x25,0x3d, 0xf,0x25,0x3e, 0xf,0x25,0x3f, 0x5,0x27,0x75, + 0x6,0x2e,0x47, 0x5,0x27,0x76, 0x5,0x27,0x78, 0x5,0x27,0x79, + 0x4,0x28,0x30, 0x5,0x27,0x77, 0x6,0x2e,0x46, 0x6,0x2e,0x48, + 0xf,0x28,0x7d, 0xf,0x28,0x7e, 0x5,0x2b,0x62, 0x6,0x34,0x70, + 0x6,0x34,0x73, 0x4,0x2b,0x5c, 0x5,0x2b,0x65, 0x6,0x34,0x71, + 0x6,0x63,0x5d, 0x6,0x34,0x75, 0x6,0x34,0x76, 0x6,0x34,0x77, + 0x6,0x34,0x72, 0x5,0x2b,0x63, 0x6,0x34,0x78, 0xf,0x2d,0x5b, + 0xf,0x2d,0x5c, 0xf,0x2d,0x5d, 0x6,0x34,0x74, 0x6,0x34,0x6f, + 0x6,0x3c,0x69, 0x5,0x30,0x6f, 0x5,0x2b,0x66, 0x6,0x3c,0x68, + 0x5,0x30,0x6c, 0x5,0x30,0x6e, 0x6,0x3c,0x6e, 0x6,0x3c,0x6b, + 0x6,0x3c,0x6f, 0x5,0x30,0x6d, 0x6,0x3c,0x6a, 0x6,0x3c,0x6d, + 0x6,0x3c,0x6c, 0xf,0x32,0x68, 0xf,0x32,0x69, 0xf,0x32,0x6a, + 0xf,0x32,0x6b, 0xf,0x32,0x6c, 0xf,0x32,0x6d, 0xf,0x32,0x6e, + 0x5,0x36,0x43, 0x6,0x46,0x28, 0x6,0x46,0x21, 0x4,0x35,0x7e, + 0x4,0x36,0x22, 0x4,0x36,0x21, 0x5,0x36,0x44, 0x6,0x46,0x23, + 0x6,0x46,0x24, 0x6,0x46,0x2b, 0x6,0x46,0x2a, 0x6,0x63,0x5e, + 0x6,0x46,0x26, 0x6,0x46,0x22, 0x6,0x46,0x29, 0x6,0x46,0x27, + 0x7,0x34,0x7b, 0x6,0x46,0x25, 0xf,0x38,0x7c, 0xf,0x38,0x7d, + 0xf,0x38,0x7e, 0xf,0x39,0x21, 0xf,0x39,0x22, 0xf,0x39,0x23, + 0xf,0x39,0x24, 0xf,0x39,0x25, 0xf,0x39,0x26, 0xf,0x39,0x27, + 0x5,0x3d,0x38, 0x5,0x3d,0x3d, 0x5,0x3d,0x39, 0x5,0x3d,0x3a, + 0x5,0x3d,0x3c, 0x6,0x50,0x25, 0x6,0x50,0x23, 0x5,0x3d,0x34, + 0x5,0x3d,0x35, 0x5,0x3d,0x37, 0x6,0x50,0x24, 0x6,0x50,0x29, + 0x7,0x3d,0x34, 0x6,0x50,0x27, 0x5,0x3d,0x3b, 0x6,0x50,0x28, + 0x6,0x50,0x26, 0xf,0x40,0x22, 0xf,0x40,0x23, 0x7,0x3d,0x32, + 0x5,0x3d,0x36, 0x6,0x59,0x6a, 0x5,0x43,0x7b, 0x5,0x43,0x78, + 0x6,0x59,0x62, 0x6,0x59,0x69, 0x6,0x59,0x67, 0x5,0x43,0x7c, + 0x5,0x43,0x79, 0x5,0x43,0x77, 0x6,0x63,0x5f, 0x6,0x59,0x63, + 0x6,0x59,0x65, 0x5,0x43,0x7d, 0x5,0x43,0x7a, 0x6,0x59,0x66, + 0x7,0x44,0x49, 0x6,0x59,0x64, 0x7,0x44,0x48, 0x5,0x43,0x76, + 0x6,0x59,0x5f, 0x6,0x59,0x6b, 0x6,0x59,0x60, 0x5,0x43,0x75, + 0x6,0x59,0x61, 0xf,0x46,0x22, 0xf,0x46,0x23, 0xf,0x46,0x24, + 0xf,0x46,0x25, 0xf,0x46,0x26, 0xf,0x46,0x27, 0xf,0x46,0x28, + 0xf,0x46,0x29, 0x6,0x59,0x68, 0x6,0x59,0x6c, 0x7,0x3d,0x33, + 0x6,0x63,0x64, 0x6,0x63,0x62, 0x6,0x63,0x66, 0x4,0x48,0x27, + 0x4,0x48,0x26, 0x5,0x52,0x2f, 0x4,0x48,0x28, 0x4,0x48,0x29, + 0x5,0x4a,0x78, 0x6,0x63,0x63, 0x6,0x63,0x60, 0x4,0x48,0x25, + 0x5,0x4a,0x79, 0x5,0x4a,0x7a, 0x6,0x63,0x65, 0x6,0x63,0x67, + 0x7,0x4b,0x41, 0xf,0x4d,0x2e, 0xf,0x4d,0x2f, 0xf,0x4d,0x30, + 0xf,0x4d,0x31, 0xf,0x4d,0x32, 0xf,0x4d,0x33, 0x6,0x63,0x61, + 0x5,0x4a,0x77, 0x5,0x52,0x36, 0x5,0x52,0x34, 0x5,0x52,0x35, + 0x7,0x2a,0x55, 0x5,0x52,0x38, 0x5,0x52,0x32, 0x5,0x52,0x31, + 0x7,0x2a,0x4f, 0x5,0x52,0x33, 0x5,0x52,0x37, 0x5,0x52,0x30, + 0x7,0x50,0x7a, 0x7,0x2a,0x53, 0x7,0x2a,0x51, 0x7,0x2a,0x50, + 0x7,0x2a,0x52, 0xf,0x52,0x72, 0xf,0x52,0x73, 0xf,0x52,0x74, + 0xf,0x52,0x75, 0xf,0x52,0x76, 0xf,0x52,0x77, 0x7,0x2a,0x56, + 0x5,0x59,0x41, 0x5,0x59,0x42, 0x4,0x54,0x54, 0x7,0x34,0x7c, + 0x5,0x59,0x44, 0x5,0x59,0x43, 0x7,0x34,0x7e, 0x7,0x50,0x79, + 0xf,0x58,0x69, 0xf,0x58,0x6a, 0xf,0x58,0x6b, 0xf,0x58,0x6c, + 0x5,0x6a,0x3c, 0x7,0x34,0x7d, 0x5,0x5f,0x56, 0x5,0x5f,0x57, + 0x7,0x3d,0x36, 0x7,0x3d,0x37, 0x7,0x3d,0x35, 0x5,0x74,0x59, + 0xf,0x5d,0x51, 0xf,0x5d,0x52, 0xf,0x5d,0x53, 0xf,0x5d,0x54, + 0x5,0x65,0x62, 0x7,0x44,0x4c, 0x4,0x5e,0x34, 0x7,0x44,0x4a, + 0x7,0x44,0x4b, 0xf,0x61,0x4d, 0xf,0x61,0x4e, 0xf,0x61,0x4f, + 0xf,0x61,0x50, 0x5,0x6a,0x3d, 0x7,0x4b,0x43, 0x7,0x55,0x6c, + 0x7,0x4b,0x45, 0xf,0x64,0x4c, 0x5,0x78,0x43, 0x7,0x4b,0x42, + 0x7,0x4b,0x44, 0x7,0x5f,0x77, 0xf,0x66,0x72, 0xf,0x66,0x73, + 0x7,0x51,0x72, 0x5,0x71,0x5d, 0x7,0x55,0x6e, 0x7,0x55,0x6d, + 0x7,0x62,0x79, 0x7,0x62,0x7a, 0x7,0x59,0x70, 0x7,0x5d,0x49, + 0x7,0x5f,0x78, 0x5,0x7a,0x7e, 0x5,0x7b,0x21, 0x7,0x66,0x37, + 0x7,0x66,0x28, 0x6,0x59,0x6d, 0x4,0x4e,0x4b, 0x7,0x2a,0x57, + 0xf,0x52,0x79, 0xf,0x52,0x78, 0x5,0x59,0x45, 0x7,0x35,0x21, + 0x4,0x59,0x56, 0x7,0x44,0x4d, 0x7,0x44,0x4e, 0x5,0x6a,0x3e, + 0x7,0x50,0x7b, 0x6,0x3c,0x70, 0x6,0x3c,0x71, 0x6,0x3c,0x72, + 0x6,0x46,0x2c, 0x5,0x36,0x45, 0x4,0x36,0x23, 0x6,0x46,0x2e, + 0x6,0x46,0x2d, 0x6,0x46,0x30, 0x6,0x46,0x2f, 0x4,0x3b,0x70, + 0x6,0x50,0x2c, 0x4,0x3b,0x6e, 0x6,0x50,0x2a, 0x6,0x59,0x73, + 0x6,0x50,0x30, 0x6,0x50,0x2e, 0x6,0x50,0x2b, 0x4,0x3b,0x71, + 0x4,0x3b,0x6f, 0x6,0x50,0x2f, 0x6,0x50,0x2d, 0x6,0x59,0x7b, + 0x5,0x43,0x7e, 0x6,0x59,0x6e, 0x6,0x59,0x71, 0x6,0x59,0x77, + 0x6,0x59,0x75, 0x6,0x59,0x7a, 0x6,0x59,0x72, 0x6,0x59,0x70, + 0x6,0x59,0x74, 0x6,0x59,0x79, 0x6,0x59,0x78, 0x6,0x59,0x6f, + 0x6,0x59,0x76, 0x6,0x63,0x74, 0x6,0x63,0x72, 0x5,0x4a,0x7b, + 0x6,0x63,0x6b, 0x6,0x63,0x6c, 0x6,0x63,0x76, 0x6,0x63,0x68, + 0x6,0x63,0x77, 0x6,0x63,0x70, 0x4,0x48,0x2a, 0x6,0x63,0x75, + 0x6,0x63,0x6f, 0x5,0x4a,0x7c, 0x6,0x63,0x71, 0x6,0x63,0x69, + 0x5,0x4a,0x7d, 0x4,0x48,0x2b, 0x6,0x63,0x6a, 0xf,0x4d,0x34, + 0xf,0x4d,0x35, 0x6,0x63,0x73, 0x6,0x63,0x78, 0x6,0x63,0x6d, + 0x7,0x2a,0x5d, 0x7,0x2a,0x5b, 0x7,0x2a,0x64, 0x7,0x2a,0x5f, + 0x7,0x2a,0x5c, 0x5,0x52,0x3a, 0x7,0x2a,0x5e, 0x7,0x2a,0x66, + 0x7,0x2a,0x62, 0x7,0x2a,0x60, 0x7,0x2a,0x61, 0x7,0x2a,0x63, + 0x7,0x2a,0x5a, 0x7,0x2a,0x58, 0x5,0x52,0x39, 0x7,0x2a,0x65, + 0x7,0x2a,0x67, 0x4,0x59,0x57, 0x4,0x54,0x55, 0x5,0x59,0x47, + 0x7,0x35,0x29, 0x7,0x35,0x24, 0x7,0x35,0x2f, 0x7,0x35,0x22, + 0x7,0x35,0x2d, 0x7,0x35,0x28, 0x7,0x35,0x25, 0x7,0x35,0x2c, + 0x7,0x35,0x2a, 0x7,0x35,0x26, 0x5,0x59,0x46, 0x7,0x35,0x30, + 0x4,0x54,0x56, 0x7,0x35,0x2b, 0x7,0x35,0x33, 0x7,0x35,0x27, + 0x7,0x2a,0x59, 0x7,0x35,0x34, 0x7,0x35,0x31, 0x7,0x35,0x23, + 0x7,0x35,0x32, 0xf,0x58,0x6d, 0x7,0x35,0x2e, 0xf,0x52,0x7a, + 0x4,0x59,0x59, 0x7,0x3d,0x3d, 0x7,0x3d,0x3b, 0x7,0x3d,0x45, + 0x7,0x3d,0x3c, 0x7,0x3d,0x3e, 0x7,0x3d,0x49, 0x7,0x3d,0x3a, + 0x7,0x3d,0x42, 0x7,0x3d,0x39, 0x7,0x3d,0x38, 0x7,0x3d,0x3f, + 0x5,0x5f,0x58, 0x7,0x3d,0x47, 0x7,0x3d,0x41, 0x7,0x3d,0x40, + 0x7,0x3d,0x43, 0x7,0x3d,0x48, 0x7,0x35,0x36, 0xf,0x5d,0x55, + 0xf,0x5d,0x57, 0x7,0x3d,0x44, 0x7,0x3d,0x46, 0x7,0x44,0x50, + 0x7,0x44,0x56, 0x7,0x44,0x52, 0x7,0x44,0x53, 0x7,0x44,0x4f, + 0x5,0x65,0x63, 0x7,0x44,0x57, 0x7,0x44,0x55, 0x5,0x65,0x64, + 0x7,0x44,0x51, 0x7,0x44,0x54, 0x7,0x4b,0x4a, 0x7,0x4b,0x47, + 0x7,0x4b,0x4b, 0x7,0x4b,0x48, 0x5,0x6a,0x3f, 0x7,0x4b,0x4e, + 0x4,0x61,0x6f, 0x5,0x6a,0x40, 0x7,0x4b,0x46, 0x7,0x4b,0x4c, + 0x7,0x4b,0x4d, 0x4,0x61,0x70, 0x7,0x4b,0x49, 0x7,0x4b,0x4f, + 0x7,0x51,0x23, 0x7,0x51,0x27, 0x7,0x50,0x7d, 0x7,0x51,0x2a, + 0x7,0x51,0x24, 0x7,0x51,0x2b, 0x7,0x51,0x28, 0x7,0x50,0x7c, + 0x5,0x6e,0x42, 0x7,0x51,0x25, 0x7,0x51,0x26, 0x5,0x6e,0x43, + 0x7,0x51,0x22, 0xf,0x66,0x74, 0x7,0x50,0x7e, 0x7,0x51,0x2c, + 0x7,0x51,0x29, 0x7,0x55,0x74, 0x4,0x67,0x68, 0x7,0x55,0x72, + 0x7,0x55,0x6f, 0x7,0x55,0x76, 0x7,0x55,0x70, 0x7,0x55,0x75, + 0x7,0x55,0x73, 0x7,0x55,0x77, 0x7,0x51,0x21, 0xf,0x68,0x76, + 0x7,0x55,0x71, 0x7,0x59,0x71, 0x7,0x59,0x72, 0x4,0x69,0x57, + 0x7,0x59,0x75, 0x7,0x59,0x76, 0x7,0x59,0x74, 0xf,0x6a,0x32, + 0x7,0x59,0x73, 0x7,0x5d,0x38, 0x7,0x5d,0x39, 0x7,0x5d,0x3a, + 0x4,0x6b,0x2b, 0x7,0x5d,0x37, 0x7,0x5d,0x33, 0x7,0x5d,0x34, + 0x7,0x5d,0x35, 0x7,0x5d,0x36, 0x7,0x5f,0x7c, 0x7,0x5f,0x7a, + 0x7,0x5f,0x7b, 0x7,0x5f,0x79, 0x7,0x61,0x5a, 0xf,0x6c,0x41, + 0x7,0x63,0x7e, 0x7,0x64,0x6b, 0x7,0x66,0x40, 0xf,0x2d,0x5e, + 0x5,0x30,0x70, 0xf,0x32,0x70, 0x6,0x46,0x32, 0x6,0x46,0x33, + 0x4,0x36,0x25, 0x6,0x46,0x31, 0xf,0x39,0x28, 0xf,0x39,0x29, + 0x5,0x3d,0x40, 0x5,0x3d,0x3e, 0x5,0x3d,0x41, 0x5,0x3d,0x3f, + 0x4,0x3b,0x73, 0x6,0x50,0x33, 0x4,0x3b,0x72, 0x6,0x50,0x32, + 0xf,0x40,0x25, 0xf,0x40,0x27, 0xf,0x40,0x26, 0x4,0x41,0x58, + 0x5,0x44,0x25, 0x5,0x44,0x22, 0x5,0x44,0x21, 0x5,0x44,0x24, + 0x5,0x44,0x23, 0x6,0x59,0x7c, 0xf,0x46,0x2b, 0xf,0x46,0x2c, + 0xf,0x46,0x2d, 0x5,0x44,0x26, 0x5,0x4b,0x22, 0x4,0x48,0x30, + 0x5,0x4b,0x23, 0x5,0x4b,0x21, 0x5,0x4a,0x7e, 0x4,0x48,0x2c, + 0x4,0x48,0x2f, 0x6,0x63,0x7d, 0x4,0x48,0x32, 0x6,0x63,0x7c, + 0x6,0x63,0x7e, 0xf,0x4d,0x37, 0xf,0x4d,0x38, 0x6,0x63,0x7a, + 0x6,0x63,0x79, 0x7,0x2a,0x6a, 0x7,0x2a,0x69, 0x5,0x52,0x45, + 0x5,0x52,0x40, 0x5,0x52,0x41, 0x5,0x52,0x3f, 0x5,0x52,0x3e, + 0x5,0x52,0x43, 0x5,0x52,0x3d, 0x4,0x54,0x57, 0x5,0x52,0x3c, + 0x7,0x2a,0x6b, 0x7,0x2a,0x6c, 0xf,0x46,0x2a, 0xf,0x52,0x7b, + 0xf,0x52,0x7c, 0xf,0x52,0x7d, 0xf,0x52,0x7e, 0xf,0x53,0x21, + 0x7,0x2a,0x68, 0x5,0x52,0x44, 0x5,0x52,0x42, 0x5,0x5f,0x59, + 0x7,0x35,0x3b, 0x4,0x54,0x5b, 0x5,0x59,0x4e, 0x5,0x59,0x4b, + 0x4,0x54,0x5a, 0x7,0x35,0x38, 0x5,0x59,0x4d, 0x5,0x59,0x4a, + 0x7,0x35,0x3a, 0x5,0x59,0x49, 0x7,0x35,0x39, 0x7,0x35,0x37, + 0x5,0x59,0x48, 0x7,0x35,0x3c, 0xf,0x58,0x6e, 0xf,0x58,0x6f, + 0xf,0x58,0x71, 0xf,0x58,0x72, 0xf,0x58,0x73, 0xf,0x58,0x74, + 0xf,0x58,0x75, 0xf,0x58,0x70, 0xf,0x55,0x64, 0x5,0x59,0x4c, + 0x4,0x59,0x5c, 0x4,0x59,0x5a, 0x4,0x59,0x5b, 0x5,0x5f,0x5a, + 0x4,0x59,0x61, 0x5,0x5f,0x5c, 0x4,0x59,0x5e, 0x7,0x3d,0x4a, + 0x5,0x65,0x68, 0x7,0x3d,0x4b, 0x7,0x3d,0x4d, 0x5,0x5f,0x5b, + 0xf,0x5d,0x59, 0x7,0x3d,0x4c, 0x7,0x3d,0x4e, 0xf,0x5d,0x5a, + 0x5,0x5f,0x5d, 0x5,0x65,0x6c, 0x5,0x65,0x6f, 0x7,0x44,0x5f, + 0x7,0x44,0x63, 0x5,0x65,0x69, 0x7,0x44,0x5e, 0x5,0x65,0x66, + 0x7,0x44,0x65, 0x7,0x44,0x62, 0x4,0x5e,0x37, 0x5,0x65,0x65, + 0x5,0x65,0x67, 0x7,0x44,0x61, 0x7,0x44,0x5a, 0x7,0x44,0x5d, + 0x5,0x65,0x6e, 0x7,0x44,0x5b, 0xf,0x61,0x51, 0x7,0x44,0x64, + 0x7,0x44,0x59, 0x7,0x44,0x5c, 0x5,0x65,0x6b, 0x5,0x65,0x6d, + 0xf,0x5d,0x58, 0x5,0x65,0x6a, 0x5,0x6a,0x47, 0x5,0x6a,0x41, + 0x5,0x6a,0x45, 0x5,0x6a,0x42, 0x5,0x6a,0x43, 0x4,0x61,0x72, + 0x5,0x6a,0x46, 0x5,0x6a,0x44, 0x5,0x6a,0x49, 0x4,0x61,0x71, + 0x7,0x4b,0x50, 0x7,0x4b,0x55, 0x7,0x4b,0x51, 0x5,0x6a,0x48, + 0x7,0x4b,0x53, 0xf,0x64,0x4e, 0x7,0x4b,0x57, 0x7,0x4b,0x56, + 0x7,0x4b,0x54, 0x7,0x4b,0x52, 0x7,0x4b,0x58, 0x7,0x51,0x2e, + 0x4,0x64,0x74, 0x7,0x51,0x36, 0x4,0x64,0x76, 0x5,0x6e,0x44, + 0x4,0x67,0x6d, 0x4,0x64,0x78, 0x7,0x51,0x34, 0x7,0x51,0x33, + 0x5,0x6e,0x45, 0x4,0x64,0x7a, 0x4,0x64,0x77, 0x4,0x64,0x79, + 0x7,0x51,0x2f, 0x7,0x51,0x31, 0x7,0x51,0x32, 0xf,0x66,0x75, + 0x7,0x51,0x35, 0x7,0x51,0x37, 0x7,0x51,0x30, 0x7,0x51,0x2d, + 0x4,0x67,0x6a, 0x4,0x67,0x69, 0x7,0x55,0x78, 0x5,0x71,0x5e, + 0x5,0x71,0x5f, 0x4,0x67,0x6b, 0x4,0x67,0x6c, 0x7,0x55,0x7a, + 0x5,0x71,0x60, 0x5,0x71,0x61, 0x7,0x55,0x7d, 0x7,0x55,0x79, + 0x7,0x55,0x7e, 0x7,0x55,0x7b, 0x5,0x74,0x5c, 0x5,0x74,0x5f, + 0x4,0x69,0x59, 0x7,0x59,0x78, 0x5,0x74,0x5d, 0x7,0x59,0x79, + 0x7,0x59,0x7a, 0x5,0x74,0x5a, 0x5,0x74,0x5e, 0x5,0x74,0x5b, + 0x7,0x59,0x77, 0x5,0x76,0x62, 0x7,0x5d,0x3b, 0x7,0x5d,0x3c, + 0xf,0x6b,0x33, 0x5,0x76,0x63, 0x5,0x78,0x44, 0x4,0x6c,0x32, + 0x4,0x6c,0x31, 0x7,0x5f,0x7d, 0x7,0x5f,0x7e, 0x7,0x60,0x21, + 0xf,0x6b,0x70, 0x4,0x6d,0x2c, 0x5,0x79,0x56, 0x4,0x6d,0x2b, + 0x5,0x79,0x55, 0x7,0x61,0x5b, 0x5,0x79,0x57, 0x5,0x7a,0x44, + 0x7,0x62,0x7b, 0x5,0x7a,0x43, 0x7,0x62,0x7c, 0xf,0x6c,0x59, + 0x7,0x63,0x23, 0x5,0x7a,0x42, 0x7,0x64,0x6c, 0x4,0x6e,0x3e, + 0x7,0x65,0x4b, 0x7,0x65,0x4a, 0x7,0x65,0x4c, 0x5,0x7b,0x6c, + 0x7,0x66,0x2d, 0x7,0x66,0x4e, 0x7,0x66,0x51, 0x4,0x6e,0x5c, + 0x4,0x36,0x26, 0x6,0x50,0x34, 0xf,0x46,0x2e, 0xf,0x46,0x2f, + 0xf,0x46,0x30, 0x6,0x59,0x7d, 0x4,0x48,0x36, 0x7,0x2c,0x44, + 0x7,0x35,0x3d, 0x5,0x5a,0x74, 0x7,0x44,0x66, 0xf,0x64,0x4f, + 0x5,0x71,0x62, 0xf,0x6b,0x71, 0x6,0x3c,0x74, 0x6,0x2e,0x49, + 0x6,0x3c,0x73, 0x4,0x36,0x27, 0x6,0x46,0x34, 0x4,0x36,0x29, + 0xf,0x39,0x2d, 0x6,0x50,0x35, 0x5,0x3d,0x42, 0x4,0x3b,0x75, + 0x6,0x50,0x37, 0x6,0x50,0x36, 0xf,0x40,0x28, 0xf,0x40,0x29, + 0x6,0x5a,0x21, 0x6,0x59,0x7e, 0xf,0x4d,0x3b, 0x4,0x4e,0x4d, + 0x7,0x2a,0x6e, 0x7,0x2a,0x6d, 0x7,0x35,0x3e, 0x7,0x51,0x38, + 0x7,0x51,0x39, 0x6,0x50,0x39, 0x6,0x50,0x3a, 0x6,0x50,0x38, + 0x4,0x41,0x59, 0x4,0x41,0x5b, 0x5,0x44,0x28, 0x5,0x44,0x27, + 0x6,0x5a,0x23, 0x6,0x5a,0x22, 0x6,0x64,0x22, 0x5,0x4b,0x25, + 0x4,0x48,0x39, 0x6,0x64,0x21, 0x5,0x4b,0x24, 0xf,0x4d,0x3c, + 0x6,0x64,0x23, 0x4,0x4e,0x4e, 0x5,0x52,0x46, 0x5,0x52,0x48, + 0x5,0x52,0x47, 0x7,0x2a,0x70, 0x7,0x2a,0x6f, 0xf,0x58,0x77, + 0x5,0x59,0x50, 0x5,0x59,0x4f, 0x5,0x59,0x54, 0x5,0x59,0x51, + 0x5,0x59,0x52, 0x5,0x59,0x53, 0xf,0x58,0x76, 0x7,0x35,0x3f, + 0x7,0x3d,0x4f, 0x5,0x5f,0x5f, 0x5,0x5f,0x60, 0x5,0x5f,0x62, + 0x5,0x5f,0x61, 0xf,0x5d,0x5b, 0x7,0x3d,0x51, 0x5,0x65,0x72, + 0x7,0x44,0x67, 0x5,0x65,0x70, 0x5,0x65,0x71, 0x4,0x5e,0x39, + 0x5,0x6a,0x4b, 0x5,0x6a,0x4a, 0x5,0x6e,0x47, 0x5,0x6e,0x46, + 0x7,0x4d,0x50, 0x7,0x51,0x3a, 0x5,0x6c,0x46, 0x5,0x71,0x64, + 0x7,0x56,0x22, 0x5,0x71,0x66, 0x5,0x71,0x65, 0xf,0x68,0x79, + 0x7,0x56,0x21, 0x7,0x56,0x24, 0x7,0x56,0x23, 0x7,0x59,0x7b, + 0x7,0x59,0x7c, 0x7,0x5d,0x3d, 0x5,0x76,0x64, 0xf,0x6b,0x34, + 0x7,0x60,0x22, 0x5,0x7a,0x45, 0x7,0x64,0x21, 0x7,0x64,0x6e, + 0x7,0x64,0x6d, 0xf,0x39,0x2e, 0x5,0x3d,0x43, 0x4,0x3b,0x78, + 0x6,0x50,0x3b, 0x5,0x44,0x2c, 0x5,0x44,0x2b, 0x6,0x5a,0x26, + 0x6,0x5a,0x29, 0x5,0x44,0x2a, 0x6,0x5a,0x27, 0x5,0x44,0x29, + 0x6,0x5a,0x25, 0x6,0x5a,0x2b, 0x6,0x5a,0x2a, 0x4,0x41,0x5c, + 0x4,0x41,0x5e, 0xf,0x46,0x31, 0x5,0x4b,0x27, 0x4,0x48,0x3c, + 0x5,0x4b,0x26, 0x6,0x64,0x27, 0x6,0x64,0x25, 0x5,0x4b,0x28, + 0x5,0x4b,0x29, 0x4,0x48,0x3e, 0x5,0x4b,0x2c, 0x5,0x4b,0x2a, + 0x5,0x4b,0x2d, 0x5,0x4b,0x2b, 0x6,0x64,0x29, 0x4,0x48,0x3f, + 0x6,0x64,0x28, 0x6,0x64,0x24, 0x6,0x64,0x26, 0x7,0x2a,0x73, + 0x5,0x52,0x49, 0x7,0x2a,0x77, 0x7,0x2a,0x76, 0x4,0x4e,0x51, + 0x7,0x2a,0x79, 0x5,0x52,0x4a, 0x4,0x4e,0x52, 0x7,0x2a,0x75, + 0x4,0x4e,0x53, 0x5,0x52,0x4d, 0x4,0x4e,0x50, 0x5,0x52,0x4c, + 0x5,0x52,0x4e, 0x7,0x2a,0x74, 0x5,0x52,0x4b, 0x7,0x2a,0x78, + 0x7,0x2a,0x72, 0x7,0x35,0x44, 0x5,0x59,0x55, 0x5,0x59,0x58, + 0x4,0x54,0x66, 0x4,0x54,0x5e, 0x4,0x54,0x65, 0x5,0x59,0x56, + 0x5,0x59,0x57, 0x7,0x35,0x43, 0x7,0x35,0x47, 0x7,0x35,0x40, + 0x7,0x35,0x41, 0x7,0x35,0x45, 0x7,0x35,0x46, 0x7,0x3d,0x58, + 0x7,0x3d,0x5a, 0x5,0x5f,0x63, 0x5,0x5f,0x69, 0x4,0x59,0x66, + 0x5,0x5f,0x65, 0x7,0x3d,0x53, 0x4,0x59,0x67, 0x7,0x35,0x42, + 0x5,0x5f,0x6d, 0x7,0x3d,0x57, 0x4,0x59,0x65, 0x7,0x3d,0x59, + 0x5,0x5f,0x67, 0x5,0x5f,0x6a, 0x7,0x3d,0x55, 0x5,0x5f,0x6b, + 0x7,0x3d,0x5b, 0x7,0x35,0x48, 0x5,0x5f,0x68, 0x7,0x3d,0x54, + 0x7,0x3d,0x5c, 0xf,0x5d,0x5c, 0x7,0x3d,0x52, 0x5,0x5f,0x6c, + 0x5,0x5f,0x66, 0x4,0x5e,0x44, 0x5,0x65,0x7c, 0x5,0x65,0x74, + 0x4,0x5e,0x3a, 0x5,0x65,0x76, 0x5,0x66,0x22, 0x7,0x44,0x6a, + 0x7,0x44,0x68, 0x4,0x5e,0x3f, 0x5,0x65,0x77, 0x4,0x5e,0x40, + 0x7,0x44,0x6d, 0x7,0x44,0x70, 0x5,0x66,0x21, 0x7,0x44,0x6f, + 0x4,0x5e,0x3d, 0x5,0x66,0x23, 0x7,0x44,0x71, 0x7,0x44,0x72, + 0x7,0x44,0x6e, 0xf,0x61,0x53, 0xf,0x61,0x54, 0x5,0x5f,0x64, + 0x7,0x44,0x6c, 0x7,0x44,0x6b, 0x5,0x65,0x78, 0x5,0x66,0x24, + 0x7,0x44,0x69, 0x5,0x65,0x75, 0x5,0x65,0x7a, 0x5,0x65,0x79, + 0x5,0x65,0x7d, 0x4,0x61,0x7a, 0x5,0x6a,0x51, 0x5,0x6a,0x54, + 0x5,0x6a,0x4f, 0x4,0x61,0x79, 0x5,0x6a,0x4d, 0x7,0x4b,0x5a, + 0x5,0x6a,0x55, 0x7,0x4b,0x63, 0x5,0x6a,0x4e, 0x4,0x61,0x78, + 0x7,0x4b,0x61, 0x4,0x61,0x76, 0x7,0x4b,0x5e, 0x4,0x61,0x75, + 0x7,0x4b,0x62, 0x5,0x6a,0x50, 0x7,0x4b,0x60, 0xf,0x64,0x50, + 0xf,0x64,0x52, 0xf,0x64,0x53, 0x7,0x4b,0x5b, 0x7,0x4b,0x5c, + 0x5,0x6a,0x53, 0x5,0x6a,0x52, 0x7,0x4b,0x59, 0x5,0x6a,0x4c, + 0x4,0x65,0x24, 0x5,0x6e,0x4e, 0x4,0x64,0x7d, 0x5,0x6e,0x4f, + 0x5,0x6e,0x4a, 0x7,0x51,0x3b, 0x5,0x6e,0x48, 0x7,0x51,0x3d, + 0x4,0x65,0x21, 0x5,0x6e,0x4c, 0x4,0x65,0x22, 0x4,0x65,0x25, + 0x5,0x6e,0x4d, 0x7,0x51,0x41, 0x7,0x51,0x3c, 0xf,0x66,0x78, + 0x7,0x51,0x3e, 0x7,0x51,0x43, 0x7,0x51,0x40, 0x5,0x6e,0x4b, + 0x7,0x51,0x3f, 0x5,0x6e,0x50, 0x4,0x65,0x26, 0x7,0x51,0x42, + 0x5,0x71,0x6d, 0x7,0x56,0x28, 0x4,0x67,0x6f, 0x7,0x56,0x2a, + 0x7,0x56,0x2b, 0x5,0x71,0x6a, 0x5,0x71,0x6b, 0x5,0x71,0x6c, + 0x5,0x71,0x67, 0x5,0x71,0x68, 0x7,0x56,0x29, 0xf,0x66,0x77, + 0x5,0x74,0x60, 0x7,0x5a,0x26, 0x7,0x59,0x7d, 0x4,0x69,0x5d, + 0x5,0x74,0x61, 0x7,0x5a,0x25, 0x7,0x5a,0x23, 0x7,0x59,0x7e, + 0x7,0x5a,0x24, 0x5,0x74,0x63, 0x5,0x74,0x64, 0x7,0x5a,0x21, + 0x7,0x5a,0x22, 0x5,0x74,0x65, 0x5,0x76,0x65, 0x5,0x76,0x68, + 0x5,0x76,0x66, 0x7,0x5d,0x3e, 0x5,0x76,0x69, 0x5,0x76,0x67, + 0x7,0x5d,0x41, 0x7,0x5d,0x3f, 0x7,0x5d,0x42, 0x7,0x5d,0x40, + 0x5,0x78,0x46, 0x5,0x79,0x58, 0x7,0x60,0x23, 0x5,0x78,0x45, + 0x5,0x78,0x47, 0x7,0x61,0x5e, 0x7,0x61,0x5c, 0x7,0x61,0x5d, + 0x5,0x7a,0x46, 0x7,0x62,0x7e, 0x7,0x63,0x22, 0x5,0x79,0x59, + 0x7,0x63,0x21, 0x7,0x62,0x7d, 0x5,0x7b,0x22, 0x7,0x64,0x70, + 0x7,0x64,0x6f, 0x5,0x7b,0x4c, 0x7,0x65,0x69, 0x5,0x7c,0x35, + 0x7,0x66,0x2e, 0x7,0x66,0x39, 0x7,0x66,0x38, 0x5,0x7c,0x4c, + 0x5,0x3d,0x44, 0x4,0x41,0x60, 0x4,0x41,0x62, 0x6,0x5a,0x2c, + 0x5,0x44,0x2d, 0x6,0x64,0x2b, 0x5,0x4b,0x2f, 0x5,0x4b,0x31, + 0x5,0x4b,0x2e, 0x5,0x4b,0x30, 0x6,0x64,0x2a, 0xf,0x4d,0x3d, + 0x5,0x4b,0x32, 0x4,0x4e,0x55, 0x5,0x52,0x50, 0x4,0x4e,0x54, + 0x4,0x4e,0x56, 0x7,0x2a,0x7b, 0x7,0x2a,0x7a, 0x7,0x2a,0x7c, + 0x7,0x2a,0x7d, 0x7,0x2a,0x7e, 0x5,0x52,0x4f, 0x5,0x52,0x51, + 0x5,0x59,0x59, 0x7,0x35,0x49, 0x7,0x35,0x4a, 0x5,0x59,0x5c, + 0x5,0x59,0x5d, 0x5,0x59,0x5b, 0x7,0x35,0x4b, 0x5,0x59,0x5a, + 0x4,0x59,0x69, 0x7,0x3d,0x5e, 0x5,0x5f,0x6e, 0x7,0x3d,0x5f, + 0x4,0x59,0x6c, 0x4,0x59,0x6a, 0x5,0x5f,0x6f, 0x5,0x5f,0x70, + 0xf,0x5d,0x5d, 0x7,0x3d,0x5d, 0x7,0x3d,0x60, 0x7,0x44,0x76, + 0x7,0x44,0x73, 0x4,0x5e,0x46, 0x7,0x44,0x74, 0x7,0x3d,0x61, + 0x5,0x66,0x25, 0x7,0x44,0x78, 0x7,0x44,0x75, 0x7,0x4b,0x64, + 0x7,0x4b,0x66, 0x7,0x4b,0x69, 0x7,0x4b,0x65, 0x7,0x4b,0x68, + 0x7,0x4b,0x67, 0x7,0x51,0x44, 0x5,0x6a,0x56, 0x5,0x6a,0x57, + 0x7,0x51,0x45, 0x7,0x51,0x46, 0x4,0x65,0x28, 0xf,0x66,0x79, + 0x5,0x6e,0x52, 0x5,0x6e,0x51, 0x5,0x71,0x6e, 0x5,0x71,0x70, + 0x5,0x71,0x72, 0x4,0x67,0x74, 0x7,0x56,0x2c, 0x5,0x71,0x6f, + 0x5,0x71,0x71, 0x7,0x5a,0x27, 0x4,0x69,0x5f, 0x5,0x74,0x66, + 0x7,0x5a,0x28, 0x7,0x5a,0x29, 0x5,0x74,0x67, 0x7,0x5d,0x43, + 0x7,0x5d,0x46, 0x7,0x5d,0x45, 0x7,0x5d,0x44, 0x4,0x6c,0x35, + 0x7,0x61,0x5f, 0x5,0x7a,0x47, 0x7,0x64,0x24, 0x7,0x64,0x22, + 0x7,0x64,0x23, 0x5,0x7b,0x4d, 0x5,0x7b,0x6d, 0x5,0x7c,0x22, + 0x5,0x44,0x2e, 0x6,0x5a,0x2d, 0x5,0x52,0x52, 0x7,0x35,0x4c, + 0x4,0x59,0x6d, 0x7,0x3d,0x62, 0x7,0x4b,0x6c, 0x7,0x51,0x48, + 0x4,0x65,0x2b, 0x5,0x71,0x73, 0x7,0x51,0x47, 0x7,0x56,0x2d, + 0x7,0x5a,0x2a, 0x7,0x5d,0x48, 0x7,0x5d,0x47, 0x7,0x61,0x60, + 0xf,0x40,0x2c, 0x5,0x44,0x30, 0x5,0x44,0x2f, 0x5,0x4b,0x33, + 0x4,0x48,0x45, 0x5,0x4b,0x34, 0x5,0x52,0x5a, 0x7,0x2b,0x21, + 0x5,0x52,0x54, 0x5,0x52,0x57, 0x7,0x2b,0x22, 0x5,0x52,0x55, + 0x5,0x52,0x56, 0x5,0x52,0x59, 0x5,0x52,0x53, 0x4,0x54,0x6b, + 0x5,0x52,0x58, 0xf,0x58,0x79, 0x5,0x59,0x5e, 0x7,0x35,0x4d, + 0x7,0x3d,0x63, 0x5,0x5f,0x71, 0x5,0x5f,0x72, 0x5,0x66,0x26, + 0x5,0x66,0x27, 0x5,0x66,0x28, 0x4,0x62,0x21, 0x5,0x6a,0x58, + 0x5,0x6a,0x59, 0x7,0x51,0x49, 0x7,0x51,0x4a, 0x5,0x6e,0x54, + 0x5,0x6e,0x53, 0x5,0x6e,0x55, 0x7,0x56,0x2e, 0x5,0x71,0x74, + 0x5,0x66,0x29, 0x5,0x74,0x68, 0x5,0x74,0x69, 0x4,0x69,0x61, + 0xf,0x6a,0x33, 0x7,0x5d,0x4a, 0x4,0x6c,0x36, 0x5,0x7b,0x23, + 0x5,0x7c,0x3f, 0x6,0x34,0x7b, 0x6,0x46,0x35, 0x5,0x36,0x46, + 0x5,0x3d,0x4a, 0x5,0x3d,0x48, 0x5,0x3d,0x49, 0x5,0x3d,0x46, + 0x4,0x3b,0x7d, 0x5,0x3d,0x45, 0x4,0x3b,0x7c, 0x6,0x50,0x3c, + 0x4,0x3b,0x7a, 0x4,0x41,0x6c, 0x5,0x44,0x3a, 0x4,0x41,0x6b, + 0x5,0x44,0x31, 0x5,0x44,0x39, 0x6,0x5a,0x2f, 0x4,0x41,0x69, + 0x5,0x4b,0x3b, 0x5,0x44,0x37, 0x4,0x41,0x66, 0x4,0x41,0x67, + 0x4,0x41,0x6a, 0x6,0x5a,0x32, 0x5,0x44,0x36, 0x5,0x44,0x32, + 0x6,0x5a,0x30, 0x6,0x5a,0x31, 0x6,0x5a,0x2e, 0xf,0x46,0x33, + 0x5,0x44,0x33, 0x5,0x44,0x38, 0x5,0x4b,0x3d, 0x6,0x64,0x31, + 0x6,0x64,0x32, 0x5,0x4b,0x37, 0x5,0x4b,0x44, 0x5,0x4b,0x38, + 0x4,0x48,0x49, 0x4,0x48,0x48, 0x5,0x4b,0x3a, 0x5,0x4b,0x36, + 0x4,0x48,0x4f, 0x5,0x4b,0x42, 0x5,0x4b,0x39, 0x7,0x2b,0x2b, + 0x5,0x4b,0x43, 0x6,0x64,0x35, 0x6,0x64,0x33, 0x6,0x64,0x2e, + 0x5,0x4b,0x3c, 0x5,0x4b,0x41, 0xf,0x4d,0x3e, 0x6,0x64,0x2d, + 0x5,0x4b,0x40, 0x6,0x64,0x2c, 0x6,0x64,0x36, 0x5,0x4b,0x35, + 0x6,0x64,0x2f, 0x6,0x64,0x34, 0x5,0x52,0x5d, 0x4,0x4e,0x5b, + 0x7,0x2b,0x25, 0x7,0x2b,0x30, 0x5,0x52,0x5c, 0x5,0x52,0x5b, + 0x4,0x4e,0x58, 0x7,0x2b,0x24, 0x7,0x2b,0x2a, 0x4,0x48,0x4a, + 0x7,0x2b,0x2e, 0x5,0x52,0x5e, 0x4,0x4e,0x5e, 0x7,0x2b,0x2d, + 0x7,0x2b,0x29, 0x7,0x35,0x4f, 0x7,0x2b,0x2c, 0xf,0x53,0x23, + 0xf,0x53,0x24, 0x7,0x2b,0x27, 0x7,0x2b,0x28, 0x7,0x2b,0x2f, + 0x7,0x2b,0x31, 0x7,0x2b,0x23, 0x7,0x2b,0x26, 0x5,0x52,0x5f, + 0x4,0x54,0x6c, 0x5,0x59,0x61, 0x4,0x54,0x6e, 0x5,0x59,0x69, + 0x7,0x35,0x58, 0x5,0x59,0x68, 0x5,0x59,0x66, 0x7,0x35,0x59, + 0x7,0x35,0x57, 0x5,0x59,0x65, 0x5,0x59,0x63, 0x7,0x35,0x5b, + 0x7,0x35,0x50, 0x5,0x59,0x6a, 0x5,0x59,0x62, 0x5,0x59,0x6b, + 0x5,0x59,0x64, 0x5,0x59,0x67, 0x4,0x54,0x71, 0x7,0x35,0x4e, + 0x5,0x59,0x60, 0x7,0x35,0x5a, 0x4,0x54,0x72, 0x7,0x35,0x56, + 0x7,0x35,0x5c, 0xf,0x4d,0x40, 0xf,0x58,0x7a, 0xf,0x58,0x7c, + 0xf,0x58,0x7d, 0xf,0x59,0x21, 0xf,0x59,0x22, 0xf,0x59,0x23, + 0x7,0x35,0x52, 0x7,0x35,0x53, 0x7,0x35,0x54, 0x7,0x35,0x55, + 0x5,0x59,0x6c, 0x5,0x59,0x5f, 0xf,0x58,0x7e, 0x5,0x59,0x6d, + 0x4,0x59,0x75, 0x4,0x59,0x71, 0x4,0x59,0x6e, 0x7,0x3d,0x65, + 0x5,0x5f,0x77, 0x4,0x59,0x79, 0x5,0x5f,0x78, 0x4,0x59,0x74, + 0x5,0x5f,0x76, 0x5,0x5f,0x73, 0x5,0x5f,0x75, 0x4,0x59,0x6f, + 0x5,0x5f,0x7b, 0x7,0x3d,0x6a, 0x4,0x59,0x72, 0x7,0x3d,0x6c, + 0x5,0x5f,0x74, 0x7,0x3d,0x67, 0x4,0x59,0x78, 0x7,0x3d,0x6b, + 0xf,0x5d,0x5e, 0xf,0x5d,0x5f, 0xf,0x5d,0x60, 0xf,0x5d,0x61, + 0xf,0x5d,0x62, 0xf,0x5d,0x63, 0x7,0x3d,0x64, 0x7,0x3d,0x66, + 0x5,0x5f,0x79, 0x5,0x5f,0x7a, 0x7,0x3d,0x68, 0x7,0x3d,0x6d, + 0x5,0x66,0x2a, 0x4,0x5e,0x4a, 0x5,0x66,0x30, 0x5,0x66,0x2e, + 0x4,0x62,0x24, 0x5,0x66,0x2d, 0x5,0x66,0x2b, 0x7,0x44,0x7b, + 0x5,0x66,0x2c, 0x4,0x5e,0x48, 0x5,0x66,0x31, 0x5,0x66,0x2f, + 0x7,0x44,0x7c, 0xf,0x61,0x55, 0xf,0x61,0x56, 0xf,0x61,0x57, + 0xf,0x61,0x58, 0x7,0x44,0x79, 0x7,0x44,0x7a, 0x7,0x4b,0x76, + 0x5,0x6a,0x5d, 0x7,0x4b,0x70, 0x7,0x4b,0x6d, 0x5,0x6a,0x5e, + 0x4,0x62,0x2e, 0x7,0x4b,0x72, 0x5,0x6a,0x5c, 0x5,0x6e,0x56, + 0x5,0x6a,0x5b, 0x5,0x6a,0x5a, 0x7,0x4b,0x74, 0x7,0x4b,0x6f, + 0x4,0x62,0x2a, 0x7,0x4b,0x6e, 0x7,0x4b,0x75, 0x7,0x4b,0x71, + 0xf,0x64,0x54, 0xf,0x64,0x55, 0x7,0x4b,0x77, 0x7,0x4b,0x73, + 0x4,0x65,0x2e, 0x4,0x65,0x2d, 0x5,0x6e,0x5b, 0x5,0x6e,0x59, + 0x7,0x51,0x4e, 0x5,0x6e,0x5a, 0x4,0x65,0x32, 0x7,0x51,0x4d, + 0x4,0x65,0x33, 0x5,0x6e,0x58, 0x7,0x51,0x4b, 0x7,0x51,0x4f, + 0xf,0x66,0x7a, 0x4,0x65,0x34, 0x7,0x51,0x50, 0x7,0x51,0x4c, + 0x5,0x6e,0x57, 0x7,0x50,0x4c, 0x5,0x71,0x75, 0x5,0x71,0x76, + 0x7,0x56,0x2f, 0x5,0x71,0x78, 0x7,0x56,0x38, 0x7,0x5a,0x31, + 0x4,0x67,0x7a, 0x4,0x67,0x78, 0x7,0x56,0x33, 0x7,0x56,0x31, + 0x7,0x56,0x36, 0x5,0x71,0x77, 0x5,0x71,0x79, 0x5,0x71,0x7a, + 0x7,0x56,0x30, 0x7,0x56,0x34, 0xf,0x68,0x7a, 0xf,0x68,0x7b, + 0xf,0x68,0x7c, 0x7,0x56,0x37, 0x7,0x56,0x35, 0x7,0x5a,0x30, + 0x5,0x74,0x6c, 0x5,0x74,0x6b, 0x7,0x5a,0x2d, 0x7,0x5a,0x2f, + 0x5,0x74,0x6a, 0xf,0x6a,0x34, 0x7,0x5a,0x2b, 0x7,0x5a,0x2e, + 0x7,0x5a,0x2c, 0x7,0x5d,0x52, 0x7,0x5d,0x51, 0x7,0x5d,0x4f, + 0x5,0x76,0x6c, 0x5,0x76,0x6d, 0x4,0x6b,0x2e, 0x5,0x76,0x6a, + 0x7,0x5d,0x4d, 0x4,0x6b,0x2f, 0x7,0x5d,0x4e, 0xf,0x6b,0x35, + 0x7,0x5d,0x50, 0x7,0x5d,0x4c, 0x7,0x5d,0x4b, 0x4,0x6c,0x38, + 0x7,0x60,0x24, 0x5,0x76,0x6b, 0x4,0x6c,0x37, 0xf,0x6b,0x72, + 0x7,0x60,0x25, 0x4,0x6d,0x2e, 0x5,0x79,0x5a, 0x5,0x7a,0x48, + 0x7,0x63,0x24, 0x5,0x7a,0x49, 0x7,0x63,0x25, 0x7,0x63,0x26, + 0x4,0x6e,0x23, 0x7,0x64,0x25, 0x7,0x65,0x4d, 0x6,0x46,0x36, + 0x6,0x50,0x3f, 0x4,0x3c,0x21, 0x6,0x50,0x3d, 0x5,0x3d,0x4b, + 0xf,0x40,0x2e, 0x6,0x50,0x3e, 0x5,0x44,0x3b, 0x5,0x44,0x40, + 0x4,0x41,0x6f, 0x5,0x44,0x3d, 0x5,0x44,0x3e, 0x6,0x5a,0x34, + 0x6,0x5a,0x36, 0x5,0x44,0x3c, 0x4,0x41,0x70, 0x6,0x5a,0x35, + 0x6,0x53,0x33, 0x5,0x44,0x3f, 0x6,0x5a,0x37, 0x4,0x48,0x58, + 0x5,0x4b,0x48, 0x4,0x48,0x55, 0x5,0x4b,0x47, 0x5,0x4b,0x46, + 0x5,0x4b,0x45, 0x4,0x48,0x53, 0x6,0x64,0x37, 0x4,0x48,0x52, + 0x6,0x64,0x3b, 0x6,0x64,0x39, 0x6,0x64,0x38, 0x4,0x4e,0x5f, + 0x5,0x52,0x62, 0x4,0x4e,0x62, 0x7,0x2b,0x34, 0x7,0x2b,0x33, + 0x7,0x2b,0x32, 0x5,0x52,0x61, 0x7,0x2b,0x35, 0xf,0x53,0x25, + 0xf,0x53,0x26, 0x5,0x59,0x6f, 0x5,0x59,0x77, 0x5,0x59,0x70, + 0x7,0x35,0x5d, 0x7,0x35,0x60, 0x5,0x59,0x6e, 0x5,0x59,0x73, + 0x5,0x59,0x76, 0x7,0x35,0x5f, 0x7,0x35,0x61, 0x5,0x59,0x74, + 0x5,0x59,0x75, 0x7,0x35,0x5e, 0xf,0x59,0x25, 0x5,0x59,0x72, + 0x5,0x59,0x71, 0x7,0x3d,0x71, 0x4,0x5a,0x25, 0x5,0x60,0x25, + 0x5,0x60,0x26, 0x4,0x59,0x7b, 0x5,0x5f,0x7c, 0x7,0x3d,0x70, + 0x4,0x5a,0x24, 0x5,0x66,0x32, 0x5,0x60,0x22, 0x4,0x5a,0x23, + 0x5,0x5f,0x7e, 0x5,0x60,0x21, 0x5,0x60,0x24, 0x5,0x5f,0x7d, + 0x5,0x60,0x23, 0x7,0x3d,0x6e, 0xf,0x5d,0x64, 0xf,0x5d,0x65, + 0x7,0x3d,0x72, 0x7,0x3d,0x6f, 0x4,0x5e,0x53, 0x7,0x45,0x22, + 0x7,0x45,0x24, 0x5,0x66,0x37, 0x7,0x45,0x26, 0x5,0x66,0x34, + 0x5,0x66,0x38, 0x4,0x5e,0x54, 0x5,0x66,0x3a, 0x4,0x62,0x31, + 0x5,0x66,0x35, 0x7,0x45,0x25, 0x5,0x66,0x36, 0x5,0x66,0x39, + 0x5,0x66,0x33, 0xf,0x61,0x59, 0x7,0x45,0x28, 0x7,0x45,0x23, + 0x7,0x45,0x21, 0x7,0x45,0x27, 0x7,0x44,0x7d, 0x5,0x6a,0x5f, + 0x4,0x62,0x33, 0x4,0x62,0x34, 0x4,0x62,0x35, 0x5,0x6a,0x60, + 0x7,0x4b,0x79, 0xf,0x64,0x56, 0xf,0x64,0x57, 0x7,0x4b,0x78, + 0x7,0x4b,0x7a, 0x7,0x4b,0x7b, 0x7,0x4b,0x7c, 0x5,0x6e,0x5e, + 0x5,0x6e,0x61, 0x5,0x6e,0x60, 0x4,0x65,0x35, 0x5,0x6e,0x5c, + 0x4,0x65,0x37, 0x5,0x6e,0x5f, 0xf,0x66,0x7b, 0x5,0x6e,0x62, + 0x5,0x6e,0x5d, 0x4,0x65,0x38, 0x7,0x56,0x40, 0x4,0x67,0x7d, + 0x4,0x68,0x21, 0x5,0x71,0x7b, 0x7,0x56,0x39, 0x5,0x71,0x7c, + 0x7,0x56,0x3c, 0x7,0x56,0x3a, 0xf,0x68,0x7d, 0x7,0x56,0x3f, + 0x7,0x56,0x41, 0x7,0x56,0x42, 0x7,0x56,0x3d, 0x7,0x56,0x3e, + 0x7,0x56,0x3b, 0x7,0x5a,0x32, 0xf,0x6a,0x35, 0x7,0x5a,0x33, + 0x7,0x5d,0x53, 0x5,0x78,0x49, 0x4,0x6c,0x3b, 0x7,0x60,0x26, + 0x7,0x60,0x27, 0x5,0x79,0x5b, 0x7,0x61,0x61, 0x5,0x79,0x5c, + 0x4,0x6d,0x2f, 0x4,0x6d,0x66, 0x5,0x7a,0x4a, 0x5,0x7b,0x24, + 0x7,0x64,0x26, 0xf,0x6d,0x24, 0x5,0x7c,0x47, 0x7,0x66,0x55, + 0x6,0x3c,0x75, 0x5,0x40,0x39, 0x7,0x2b,0x36, 0x7,0x4b,0x7d, + 0x5,0x6a,0x61, 0x7,0x56,0x43, 0x4,0x69,0x64, 0x5,0x74,0x6d, + 0x6,0x34,0x7c, 0x6,0x34,0x7d, 0x6,0x35,0x22, 0x6,0x34,0x7e, + 0x5,0x30,0x71, 0x6,0x3c,0x76, 0x6,0x3c,0x78, 0x5,0x3d,0x4c, + 0x5,0x36,0x4a, 0x5,0x36,0x47, 0x6,0x46,0x3a, 0x6,0x46,0x38, + 0x5,0x36,0x49, 0x6,0x46,0x39, 0x6,0x46,0x3b, 0x6,0x50,0x40, + 0x5,0x36,0x48, 0x6,0x50,0x41, 0x6,0x50,0x46, 0x4,0x3c,0x22, + 0x5,0x3d,0x4d, 0x6,0x50,0x44, 0x6,0x50,0x45, 0x4,0x3c,0x26, + 0x5,0x3d,0x4e, 0x6,0x5a,0x38, 0x5,0x3d,0x4f, 0x6,0x50,0x42, + 0xf,0x40,0x2f, 0x6,0x50,0x43, 0x4,0x3c,0x23, 0x6,0x5a,0x42, + 0x6,0x5a,0x39, 0x5,0x44,0x42, 0x5,0x44,0x44, 0x5,0x44,0x41, + 0x5,0x44,0x47, 0x4,0x41,0x76, 0x5,0x44,0x43, 0x6,0x64,0x43, + 0x5,0x44,0x45, 0x6,0x5a,0x3c, 0x6,0x5a,0x3b, 0x6,0x64,0x3d, + 0x4,0x41,0x73, 0x6,0x5a,0x3a, 0x6,0x64,0x3e, 0x6,0x5a,0x3e, + 0x5,0x44,0x48, 0x6,0x5a,0x41, 0x5,0x52,0x63, 0xf,0x46,0x37, + 0x6,0x5a,0x40, 0x6,0x5a,0x3f, 0x6,0x64,0x3c, 0x4,0x41,0x78, + 0x5,0x44,0x46, 0x6,0x64,0x3f, 0x7,0x2b,0x37, 0x6,0x64,0x44, + 0x5,0x4b,0x4d, 0x5,0x4b,0x49, 0x6,0x64,0x45, 0x5,0x4b,0x4a, + 0x4,0x48,0x5a, 0x6,0x64,0x42, 0x5,0x4b,0x4b, 0x7,0x2b,0x39, + 0x6,0x64,0x41, 0xf,0x46,0x36, 0xf,0x53,0x28, 0x7,0x2b,0x3a, + 0x4,0x4e,0x6b, 0x7,0x2b,0x40, 0x4,0x4e,0x6a, 0x5,0x52,0x69, + 0x5,0x52,0x64, 0x5,0x59,0x79, 0x4,0x4e,0x68, 0x5,0x52,0x66, + 0x5,0x52,0x6b, 0x5,0x52,0x68, 0x4,0x4e,0x6c, 0x5,0x52,0x6a, + 0x7,0x2b,0x3c, 0x5,0x52,0x65, 0x7,0x2b,0x3b, 0x7,0x3d,0x73, + 0x5,0x52,0x67, 0x7,0x2b,0x3e, 0x7,0x2b,0x3d, 0xf,0x53,0x27, + 0x5,0x59,0x78, 0x7,0x2b,0x3f, 0x5,0x5a,0x23, 0x4,0x5a,0x26, + 0x5,0x5a,0x24, 0x4,0x54,0x7b, 0x7,0x35,0x66, 0x7,0x35,0x6a, + 0x5,0x60,0x27, 0x5,0x59,0x7b, 0x7,0x35,0x69, 0x5,0x59,0x7e, + 0x7,0x35,0x67, 0x5,0x59,0x7c, 0x7,0x35,0x6f, 0x4,0x54,0x79, + 0x7,0x35,0x6b, 0x7,0x35,0x70, 0x5,0x5a,0x25, 0x7,0x35,0x68, + 0x7,0x35,0x63, 0x5,0x59,0x7a, 0x7,0x35,0x65, 0x7,0x35,0x64, + 0x7,0x35,0x6c, 0x5,0x60,0x29, 0x7,0x35,0x6e, 0x7,0x3d,0x75, + 0x7,0x35,0x62, 0x5,0x5a,0x22, 0x7,0x35,0x6d, 0x5,0x59,0x7d, + 0xf,0x59,0x26, 0xf,0x59,0x27, 0xf,0x59,0x28, 0xf,0x59,0x29, + 0x5,0x5a,0x21, 0x7,0x3d,0x74, 0x5,0x60,0x28, 0x5,0x60,0x34, + 0x7,0x3d,0x77, 0x5,0x60,0x2d, 0x5,0x60,0x2f, 0x5,0x60,0x33, + 0x5,0x60,0x2b, 0x7,0x3d,0x76, 0x5,0x60,0x32, 0x5,0x60,0x35, + 0x4,0x5a,0x2b, 0x5,0x60,0x36, 0x7,0x3d,0x78, 0x7,0x3d,0x7d, + 0x7,0x45,0x2a, 0x7,0x3d,0x7a, 0x5,0x60,0x2a, 0x7,0x45,0x2b, + 0x7,0x3e,0x21, 0x5,0x60,0x2e, 0x7,0x3d,0x79, 0x7,0x3d,0x7e, + 0xf,0x5d,0x66, 0xf,0x5d,0x67, 0x7,0x3d,0x7b, 0x5,0x60,0x30, + 0x7,0x3d,0x7c, 0x7,0x45,0x2f, 0x5,0x66,0x3f, 0x5,0x66,0x3b, + 0x4,0x5e,0x56, 0x4,0x5e,0x5c, 0x5,0x60,0x38, 0x4,0x5e,0x5d, + 0x5,0x66,0x3d, 0x5,0x60,0x37, 0x5,0x66,0x3c, 0x7,0x45,0x2e, + 0x7,0x45,0x2d, 0x7,0x4b,0x7e, 0x4,0x5e,0x5e, 0x5,0x66,0x3e, + 0x7,0x4c,0x22, 0x7,0x51,0x54, 0x7,0x45,0x2c, 0x7,0x45,0x29, + 0x7,0x45,0x31, 0xf,0x61,0x5a, 0xf,0x61,0x5b, 0x7,0x4c,0x25, + 0x7,0x4c,0x21, 0x4,0x5e,0x55, 0x7,0x45,0x32, 0x7,0x45,0x30, + 0x5,0x6a,0x64, 0x7,0x4c,0x23, 0x5,0x6a,0x62, 0x4,0x62,0x3b, + 0x4,0x65,0x3d, 0x7,0x51,0x53, 0x5,0x6a,0x69, 0x5,0x6a,0x66, + 0x5,0x6a,0x68, 0x5,0x6a,0x6a, 0x7,0x51,0x51, 0x4,0x62,0x37, + 0x5,0x6a,0x67, 0x5,0x60,0x39, 0x5,0x6a,0x63, 0x7,0x51,0x52, + 0x4,0x62,0x39, 0x7,0x51,0x58, 0x7,0x4c,0x24, 0x7,0x51,0x57, + 0x4,0x62,0x3a, 0xf,0x64,0x58, 0xf,0x64,0x59, 0x5,0x6a,0x65, + 0x7,0x51,0x56, 0x5,0x6a,0x6b, 0x4,0x65,0x3e, 0x7,0x51,0x55, + 0x7,0x51,0x59, 0x7,0x51,0x5f, 0x7,0x56,0x44, 0x5,0x71,0x7d, + 0x7,0x51,0x60, 0x5,0x6e,0x65, 0x4,0x65,0x3f, 0x5,0x71,0x7e, + 0x5,0x6e,0x64, 0x7,0x51,0x5e, 0x7,0x51,0x62, 0x5,0x6e,0x63, + 0x7,0x4c,0x27, 0x7,0x51,0x61, 0x7,0x51,0x5b, 0x7,0x51,0x5c, + 0x7,0x51,0x5d, 0x7,0x56,0x45, 0x7,0x51,0x63, 0x7,0x51,0x5a, + 0x5,0x72,0x28, 0x5,0x72,0x22, 0x7,0x56,0x46, 0x4,0x68,0x25, + 0x5,0x72,0x24, 0x5,0x72,0x21, 0x7,0x56,0x47, 0x5,0x72,0x2b, + 0x7,0x56,0x48, 0x5,0x72,0x2a, 0x5,0x72,0x23, 0x5,0x72,0x27, + 0x5,0x72,0x25, 0x7,0x56,0x49, 0x5,0x72,0x26, 0x5,0x72,0x29, + 0xf,0x68,0x7e, 0x4,0x69,0x66, 0x5,0x74,0x6e, 0x5,0x74,0x6f, + 0x7,0x5a,0x37, 0x7,0x5d,0x54, 0x7,0x5a,0x36, 0x5,0x74,0x70, + 0x7,0x5a,0x35, 0xf,0x6a,0x37, 0x7,0x5a,0x34, 0x5,0x76,0x6e, + 0x7,0x5d,0x56, 0x5,0x76,0x6f, 0x5,0x76,0x70, 0x5,0x78,0x4a, + 0x7,0x5d,0x55, 0x5,0x78,0x4b, 0x5,0x78,0x4c, 0x4,0x6c,0x3c, + 0x7,0x60,0x28, 0x7,0x60,0x2a, 0x7,0x60,0x29, 0x5,0x79,0x5d, + 0x7,0x64,0x27, 0x5,0x7b,0x25, 0x6,0x3c,0x79, 0x6,0x46,0x3c, + 0x6,0x64,0x46, 0x7,0x2b,0x41, 0x6,0x64,0x48, 0x6,0x64,0x47, + 0x5,0x52,0x6c, 0x4,0x55,0x24, 0x4,0x55,0x25, 0x7,0x3e,0x22, + 0x7,0x3e,0x23, 0x7,0x35,0x71, 0x7,0x35,0x73, 0x7,0x35,0x72, + 0x7,0x4c,0x29, 0x7,0x4c,0x28, 0x7,0x45,0x33, 0x7,0x4d,0x73, + 0x7,0x51,0x64, 0x7,0x60,0x2b, 0x4,0x6e,0x26, 0xf,0x32,0x71, + 0x4,0x41,0x7c, 0x6,0x5a,0x43, 0x5,0x47,0x54, 0x6,0x64,0x49, + 0x6,0x64,0x4a, 0xf,0x4d,0x41, 0xf,0x53,0x29, 0x6,0x64,0x4b, + 0x7,0x2b,0x42, 0xf,0x53,0x2a, 0xf,0x59,0x2a, 0x7,0x35,0x74, + 0xf,0x5d,0x68, 0x7,0x3e,0x24, 0x7,0x45,0x36, 0x5,0x66,0x41, + 0x5,0x66,0x40, 0x5,0x66,0x42, 0x7,0x45,0x35, 0x7,0x45,0x34, + 0x5,0x6a,0x6c, 0x4,0x62,0x3d, 0x4,0x62,0x3e, 0x7,0x4c,0x2a, + 0x7,0x51,0x65, 0xf,0x66,0x7c, 0x5,0x72,0x2c, 0xf,0x69,0x21, + 0x7,0x56,0x4a, 0x7,0x5d,0x57, 0x5,0x7a,0x4b, 0x5,0x36,0x4b, + 0x5,0x36,0x4c, 0x5,0x3d,0x50, 0x6,0x50,0x48, 0xf,0x40,0x31, + 0x6,0x50,0x47, 0x5,0x44,0x49, 0x6,0x5a,0x45, 0x6,0x5a,0x44, + 0x6,0x5a,0x47, 0x6,0x5a,0x46, 0x5,0x4b,0x51, 0x6,0x64,0x4d, + 0x6,0x64,0x4e, 0x5,0x4b,0x50, 0x4,0x48,0x61, 0x6,0x64,0x4c, + 0x6,0x64,0x52, 0x5,0x4b,0x4f, 0x7,0x2b,0x43, 0xf,0x4d,0x42, + 0xf,0x4d,0x43, 0xf,0x4d,0x44, 0xf,0x4d,0x45, 0x7,0x2b,0x46, + 0x6,0x64,0x4f, 0x6,0x64,0x51, 0x5,0x4b,0x52, 0x7,0x2b,0x4a, + 0x5,0x52,0x72, 0x7,0x2b,0x4e, 0x7,0x2b,0x47, 0x5,0x5a,0x32, + 0x5,0x52,0x74, 0x5,0x52,0x77, 0x5,0x52,0x6d, 0x5,0x52,0x70, + 0x5,0x52,0x6e, 0x5,0x52,0x75, 0x7,0x2b,0x44, 0x5,0x52,0x76, + 0x7,0x2b,0x48, 0x5,0x52,0x73, 0x7,0x2b,0x4b, 0x7,0x2b,0x49, + 0x5,0x52,0x6f, 0x7,0x2b,0x45, 0x7,0x2b,0x4c, 0x5,0x52,0x71, + 0xf,0x53,0x2b, 0xf,0x53,0x2c, 0xf,0x53,0x2d, 0x7,0x2b,0x4d, + 0x7,0x35,0x7a, 0x4,0x55,0x2c, 0x7,0x35,0x79, 0x5,0x5a,0x2f, + 0x4,0x55,0x2a, 0x4,0x55,0x27, 0x4,0x55,0x2b, 0x4,0x55,0x28, + 0x7,0x35,0x75, 0x5,0x5a,0x29, 0x4,0x55,0x29, 0x5,0x5a,0x30, + 0x5,0x5a,0x2d, 0x7,0x36,0x24, 0x5,0x5a,0x33, 0x5,0x5a,0x27, + 0x5,0x5a,0x31, 0x5,0x5a,0x34, 0x5,0x5a,0x2b, 0x7,0x35,0x7c, + 0x7,0x35,0x7b, 0x7,0x36,0x26, 0x7,0x36,0x21, 0x7,0x35,0x78, + 0x7,0x36,0x23, 0x5,0x5a,0x2a, 0x7,0x36,0x22, 0xf,0x59,0x2c, + 0x5,0x5a,0x28, 0x7,0x35,0x7d, 0x7,0x35,0x7e, 0x7,0x36,0x27, + 0x7,0x36,0x25, 0xf,0x59,0x2b, 0x7,0x35,0x76, 0x7,0x35,0x77, + 0x5,0x60,0x3a, 0x7,0x3e,0x2c, 0x5,0x60,0x3b, 0x7,0x3e,0x26, + 0x4,0x5a,0x2f, 0x7,0x3e,0x27, 0x7,0x3e,0x25, 0x5,0x60,0x3c, + 0x4,0x5a,0x2c, 0x7,0x3e,0x2a, 0x7,0x3e,0x2b, 0x5,0x4b,0x53, + 0x7,0x3e,0x28, 0x5,0x60,0x3e, 0x5,0x60,0x3d, 0xf,0x5d,0x69, + 0xf,0x5d,0x6a, 0x7,0x45,0x3c, 0x5,0x66,0x4c, 0x5,0x66,0x4b, + 0x5,0x66,0x47, 0x4,0x5e,0x64, 0x5,0x66,0x49, 0x5,0x66,0x48, + 0x4,0x5e,0x61, 0x5,0x66,0x45, 0x5,0x66,0x4e, 0x4,0x5e,0x6d, + 0x4,0x5e,0x69, 0x4,0x5e,0x6a, 0x4,0x5e,0x66, 0x5,0x66,0x4f, + 0x5,0x66,0x43, 0x4,0x5e,0x6c, 0x7,0x45,0x3b, 0x7,0x45,0x3a, + 0x7,0x45,0x37, 0x5,0x66,0x4a, 0xf,0x61,0x5d, 0xf,0x61,0x5e, + 0xf,0x61,0x60, 0x4,0x5e,0x6b, 0xf,0x61,0x5c, 0x7,0x45,0x38, + 0x5,0x66,0x44, 0x7,0x45,0x39, 0x5,0x66,0x4d, 0x5,0x6a,0x6d, + 0x5,0x6a,0x73, 0x5,0x6a,0x6f, 0x4,0x62,0x43, 0x7,0x4c,0x31, + 0x5,0x66,0x50, 0x7,0x4c,0x2c, 0x5,0x66,0x46, 0x5,0x6a,0x71, + 0x5,0x6a,0x70, 0x5,0x6a,0x74, 0x7,0x4c,0x2b, 0x5,0x6a,0x72, + 0x5,0x6a,0x76, 0x4,0x62,0x42, 0x5,0x6a,0x77, 0x7,0x4c,0x32, + 0x7,0x4c,0x34, 0x5,0x6a,0x75, 0x7,0x4c,0x33, 0x7,0x4c,0x2d, + 0x7,0x4c,0x2e, 0x7,0x4c,0x2f, 0xf,0x64,0x5b, 0xf,0x64,0x5c, + 0xf,0x64,0x5d, 0x7,0x4c,0x30, 0x3,0x57,0x36, 0x7,0x4c,0x35, + 0x4,0x65,0x45, 0x7,0x51,0x6a, 0x7,0x51,0x69, 0x5,0x6e,0x6e, + 0x5,0x6e,0x69, 0x5,0x6e,0x6b, 0x5,0x6e,0x68, 0x4,0x65,0x42, + 0x5,0x6e,0x70, 0xf,0x66,0x7d, 0x4,0x65,0x43, 0x4,0x65,0x44, + 0x4,0x65,0x48, 0x5,0x6e,0x71, 0x5,0x6e,0x72, 0x5,0x6e,0x67, + 0x7,0x51,0x68, 0x4,0x68,0x26, 0x5,0x6e,0x6a, 0x5,0x6e,0x6f, + 0x5,0x6e,0x6c, 0x7,0x51,0x6b, 0x7,0x51,0x6f, 0x7,0x51,0x70, + 0x7,0x51,0x71, 0x7,0x51,0x6d, 0x7,0x51,0x6c, 0xf,0x66,0x7e, + 0xf,0x67,0x21, 0x7,0x51,0x67, 0x7,0x51,0x6e, 0x7,0x52,0x27, + 0x7,0x51,0x66, 0x5,0x72,0x2f, 0x5,0x72,0x2e, 0x5,0x72,0x31, + 0x4,0x68,0x27, 0x5,0x72,0x32, 0x5,0x72,0x30, 0x4,0x68,0x2c, + 0x7,0x56,0x4d, 0x7,0x56,0x4c, 0x7,0x56,0x4e, 0x7,0x56,0x4b, + 0xf,0x69,0x22, 0x7,0x56,0x4f, 0x7,0x56,0x50, 0x5,0x74,0x78, + 0x7,0x5a,0x3d, 0x5,0x72,0x34, 0x7,0x5a,0x41, 0x7,0x5a,0x38, + 0x5,0x74,0x71, 0x7,0x5a,0x3b, 0x5,0x72,0x33, 0x5,0x74,0x74, + 0x5,0x74,0x77, 0x5,0x74,0x73, 0x7,0x5a,0x40, 0x4,0x69,0x6c, + 0x5,0x74,0x75, 0x7,0x5a,0x39, 0x7,0x5a,0x3a, 0x7,0x5a,0x3c, + 0xf,0x6a,0x38, 0xf,0x6a,0x39, 0xf,0x6a,0x3a, 0x5,0x74,0x72, + 0x5,0x74,0x79, 0x7,0x5a,0x3f, 0x7,0x5d,0x5f, 0x7,0x5d,0x5d, + 0x5,0x76,0x71, 0x5,0x78,0x4e, 0x7,0x5d,0x5c, 0x7,0x5d,0x59, + 0x5,0x76,0x72, 0x7,0x5d,0x5a, 0x7,0x5d,0x5e, 0x7,0x5d,0x5b, + 0x7,0x5d,0x60, 0xf,0x6b,0x38, 0xf,0x6b,0x39, 0x7,0x5d,0x58, + 0x5,0x78,0x4f, 0x7,0x60,0x31, 0x7,0x60,0x34, 0x5,0x78,0x4d, + 0x7,0x60,0x33, 0x7,0x60,0x36, 0x7,0x60,0x35, 0x7,0x60,0x2f, + 0x7,0x60,0x30, 0x7,0x60,0x2c, 0x7,0x60,0x32, 0x5,0x79,0x62, + 0x7,0x61,0x63, 0x5,0x79,0x63, 0x5,0x79,0x5f, 0x4,0x6d,0x31, + 0x5,0x79,0x60, 0x7,0x61,0x62, 0x5,0x79,0x5e, 0x5,0x79,0x61, + 0x4,0x6d,0x32, 0x7,0x61,0x64, 0x5,0x7a,0x4c, 0x5,0x7a,0x4d, + 0x4,0x6e,0x27, 0x7,0x64,0x29, 0x7,0x64,0x28, 0x4,0x6e,0x40, + 0x7,0x64,0x72, 0x7,0x64,0x73, 0x7,0x64,0x71, 0x7,0x65,0x4e, + 0x5,0x7c,0x23, 0x7,0x65,0x6a, 0x7,0x65,0x7a, 0x7,0x65,0x7b, + 0x7,0x66,0x44, 0x5,0x3d,0x51, 0x4,0x3c,0x27, 0x6,0x5a,0x49, + 0x6,0x5a,0x4a, 0x6,0x5a,0x48, 0x6,0x5a,0x4b, 0x4,0x48,0x63, + 0x4,0x48,0x65, 0x5,0x4b,0x55, 0x6,0x64,0x58, 0x5,0x4b,0x54, + 0x4,0x48,0x64, 0x6,0x64,0x56, 0x6,0x64,0x53, 0x6,0x64,0x54, + 0x6,0x64,0x55, 0x6,0x64,0x57, 0x4,0x4e,0x72, 0x4,0x4e,0x71, + 0x5,0x52,0x7a, 0x5,0x52,0x79, 0x7,0x2b,0x52, 0x7,0x36,0x2c, + 0x5,0x52,0x78, 0x5,0x52,0x7b, 0x4,0x4e,0x77, 0x7,0x2b,0x50, + 0x7,0x2b,0x54, 0x7,0x2b,0x51, 0x4,0x4e,0x78, 0x7,0x2b,0x53, + 0x5,0x5a,0x36, 0x5,0x5a,0x35, 0x4,0x55,0x33, 0x7,0x36,0x2b, + 0x7,0x2b,0x4f, 0x7,0x36,0x2a, 0x7,0x36,0x29, 0x7,0x3e,0x2e, + 0x4,0x5a,0x34, 0x7,0x3e,0x32, 0x4,0x5a,0x32, 0x7,0x3e,0x33, + 0x5,0x60,0x3f, 0x7,0x3e,0x31, 0x7,0x3e,0x2d, 0x7,0x3e,0x2f, + 0x7,0x3e,0x30, 0x5,0x66,0x59, 0x7,0x45,0x3e, 0x4,0x5e,0x6f, + 0x7,0x45,0x3d, 0x5,0x66,0x57, 0x7,0x45,0x3f, 0x5,0x66,0x52, + 0x5,0x6a,0x78, 0x5,0x66,0x55, 0x5,0x66,0x53, 0x5,0x66,0x56, + 0x5,0x66,0x58, 0x7,0x3e,0x34, 0x5,0x66,0x54, 0x7,0x4c,0x3b, + 0x5,0x6a,0x7a, 0x5,0x6a,0x79, 0x7,0x4c,0x3a, 0x7,0x4c,0x37, + 0x5,0x6a,0x7c, 0x5,0x6a,0x7d, 0x5,0x6a,0x7b, 0x7,0x4c,0x3d, + 0x7,0x4c,0x3e, 0x7,0x4c,0x39, 0x7,0x4c,0x38, 0x7,0x4c,0x3c, + 0x7,0x4c,0x36, 0x4,0x65,0x4a, 0x5,0x6e,0x75, 0x5,0x6e,0x74, + 0x5,0x6e,0x73, 0x7,0x51,0x73, 0x7,0x51,0x74, 0x7,0x51,0x75, + 0x4,0x68,0x2f, 0x5,0x72,0x36, 0x7,0x56,0x57, 0x4,0x68,0x2e, + 0x5,0x72,0x35, 0x5,0x72,0x37, 0x7,0x56,0x53, 0x7,0x56,0x54, + 0x5,0x72,0x38, 0x7,0x56,0x55, 0xf,0x69,0x23, 0x7,0x56,0x56, + 0x7,0x56,0x52, 0x4,0x69,0x6d, 0x7,0x5a,0x42, 0x4,0x69,0x70, + 0x7,0x5a,0x43, 0x4,0x69,0x6f, 0x7,0x5a,0x44, 0x7,0x5d,0x65, + 0x7,0x5d,0x66, 0x5,0x76,0x73, 0x4,0x6b,0x36, 0x5,0x76,0x75, + 0x4,0x6b,0x37, 0x7,0x5d,0x62, 0x5,0x76,0x74, 0x7,0x5d,0x67, + 0x7,0x5d,0x61, 0x7,0x5d,0x63, 0x7,0x5d,0x64, 0x4,0x6c,0x3f, + 0x5,0x78,0x50, 0x4,0x6d,0x34, 0x7,0x61,0x65, 0xf,0x6b,0x3a, + 0x7,0x63,0x27, 0x5,0x7a,0x4e, 0x7,0x63,0x28, 0x7,0x64,0x2a, + 0x7,0x64,0x74, 0x5,0x7b,0x6e, 0x4,0x42,0x23, 0x4,0x48,0x66, + 0x5,0x46,0x64, 0x5,0x4b,0x56, 0x6,0x64,0x5a, 0xf,0x4d,0x46, + 0xf,0x4d,0x47, 0xf,0x4d,0x48, 0x6,0x64,0x59, 0x7,0x2b,0x56, + 0xf,0x53,0x2e, 0xf,0x53,0x2f, 0x7,0x36,0x2e, 0x7,0x36,0x2d, + 0xf,0x59,0x2d, 0xf,0x59,0x2e, 0x4,0x5a,0x36, 0x5,0x60,0x40, + 0xf,0x5d,0x6b, 0xf,0x5d,0x6c, 0x7,0x45,0x40, 0xf,0x61,0x61, + 0xf,0x61,0x62, 0x7,0x4c,0x3f, 0xf,0x64,0x5f, 0x5,0x6e,0x76, + 0xf,0x67,0x22, 0xf,0x67,0x23, 0xf,0x67,0x24, 0xf,0x67,0x25, + 0x4,0x68,0x31, 0x7,0x56,0x58, 0x7,0x5a,0x45, 0x7,0x5d,0x68, + 0x7,0x5d,0x69, 0x7,0x5d,0x6a, 0x7,0x60,0x37, 0xf,0x6b,0x73, + 0x7,0x61,0x66, 0x7,0x61,0x67, 0x7,0x63,0x29, 0x7,0x64,0x2b, + 0x4,0x6e,0x28, 0x7,0x65,0x7c, 0x6,0x50,0x49, 0x6,0x50,0x4a, + 0x6,0x5a,0x4d, 0x6,0x5a,0x4c, 0xf,0x46,0x3a, 0xf,0x40,0x69, + 0x4,0x48,0x68, 0x5,0x4b,0x58, 0x6,0x64,0x60, 0x6,0x64,0x5f, + 0x6,0x64,0x5d, 0x6,0x64,0x61, 0x6,0x64,0x5b, 0x6,0x64,0x5c, + 0x5,0x4b,0x57, 0x5,0x4b,0x5a, 0x5,0x52,0x7e, 0x7,0x2b,0x57, + 0x7,0x2b,0x5a, 0x4,0x4e,0x7e, 0x7,0x2b,0x58, 0x5,0x53,0x24, + 0x4,0x4f,0x22, 0x7,0x2b,0x5b, 0x5,0x53,0x23, 0x4,0x4e,0x7c, + 0x4,0x4e,0x7d, 0x5,0x52,0x7c, 0x4,0x4e,0x7a, 0x5,0x52,0x7d, + 0x5,0x53,0x22, 0x5,0x53,0x21, 0x7,0x2b,0x5c, 0x7,0x2b,0x59, + 0xf,0x53,0x30, 0xf,0x53,0x31, 0xf,0x53,0x32, 0xf,0x53,0x33, + 0x7,0x36,0x2f, 0x4,0x55,0x37, 0x7,0x36,0x31, 0x5,0x5a,0x3a, + 0x7,0x36,0x30, 0x4,0x55,0x39, 0x4,0x55,0x34, 0x4,0x55,0x3b, + 0x5,0x5a,0x37, 0x5,0x5a,0x39, 0x4,0x55,0x3a, 0x4,0x55,0x38, + 0x7,0x36,0x33, 0x5,0x5a,0x38, 0xf,0x59,0x2f, 0xf,0x59,0x30, + 0xf,0x59,0x31, 0xf,0x59,0x33, 0x7,0x36,0x32, 0x4,0x5a,0x3a, + 0x4,0x5a,0x3c, 0x7,0x3e,0x3a, 0x5,0x60,0x41, 0x5,0x60,0x44, + 0x5,0x60,0x42, 0x7,0x3e,0x38, 0x5,0x60,0x45, 0x5,0x60,0x46, + 0x5,0x60,0x43, 0x7,0x3e,0x35, 0x4,0x5a,0x39, 0x7,0x3e,0x36, + 0xf,0x5d,0x6d, 0xf,0x5d,0x6e, 0xf,0x5d,0x6f, 0x7,0x3e,0x37, + 0x7,0x3e,0x39, 0x7,0x3e,0x3b, 0x7,0x45,0x42, 0x5,0x66,0x5e, + 0x4,0x5e,0x71, 0x5,0x66,0x5c, 0x5,0x66,0x60, 0x5,0x66,0x5f, + 0x7,0x45,0x44, 0x5,0x66,0x61, 0x7,0x4c,0x40, 0x7,0x45,0x43, + 0x4,0x5e,0x72, 0x5,0x66,0x5a, 0x4,0x5e,0x78, 0x5,0x66,0x5b, + 0xf,0x61,0x63, 0xf,0x61,0x65, 0x5,0x66,0x5d, 0x7,0x45,0x41, + 0xf,0x61,0x64, 0x4,0x62,0x4d, 0x7,0x4c,0x43, 0x7,0x4c,0x47, + 0x5,0x6a,0x7e, 0x5,0x6b,0x21, 0x5,0x6b,0x23, 0x4,0x62,0x50, + 0x7,0x4c,0x48, 0x7,0x4c,0x46, 0x7,0x4c,0x41, 0x5,0x6b,0x24, + 0x5,0x6b,0x22, 0x7,0x4c,0x45, 0x7,0x4c,0x42, 0x4,0x62,0x4b, + 0x7,0x4c,0x44, 0xf,0x64,0x60, 0xf,0x64,0x61, 0xf,0x64,0x63, + 0x5,0x6e,0x7c, 0x7,0x51,0x76, 0x5,0x6e,0x77, 0x5,0x6e,0x7b, + 0x5,0x6e,0x7a, 0x5,0x6e,0x79, 0x4,0x65,0x50, 0x4,0x65,0x4c, + 0x5,0x6e,0x7e, 0x5,0x6e,0x78, 0x4,0x65,0x4b, 0x7,0x51,0x77, + 0x7,0x51,0x78, 0x7,0x51,0x7b, 0x7,0x51,0x7c, 0xf,0x67,0x26, + 0xf,0x67,0x27, 0xf,0x67,0x28, 0x5,0x6e,0x7d, 0x5,0x72,0x3b, + 0x5,0x72,0x3e, 0x5,0x72,0x3a, 0x7,0x56,0x59, 0x4,0x68,0x32, + 0x4,0x68,0x34, 0x5,0x72,0x39, 0x4,0x68,0x33, 0x5,0x72,0x3d, + 0x7,0x56,0x5a, 0x5,0x72,0x3c, 0x7,0x56,0x5e, 0xf,0x69,0x24, + 0x7,0x56,0x5b, 0x7,0x56,0x5c, 0x5,0x75,0x21, 0x5,0x74,0x7c, + 0x7,0x5a,0x46, 0x5,0x75,0x22, 0x5,0x74,0x7e, 0x5,0x74,0x7b, + 0x5,0x75,0x25, 0x5,0x75,0x24, 0x5,0x75,0x23, 0x5,0x74,0x7d, + 0x5,0x75,0x26, 0x7,0x56,0x5d, 0x4,0x69,0x73, 0x7,0x5a,0x47, + 0x7,0x5a,0x48, 0xf,0x6a,0x3b, 0xf,0x6a,0x3c, 0x5,0x76,0x77, + 0x4,0x6b,0x38, 0x4,0x6b,0x39, 0x5,0x76,0x76, 0x7,0x5d,0x6c, + 0x7,0x5d,0x6d, 0x7,0x5d,0x6b, 0xf,0x6b,0x3b, 0x4,0x6c,0x40, + 0x7,0x60,0x38, 0x5,0x78,0x51, 0x4,0x6c,0x44, 0x4,0x6c,0x42, + 0x5,0x79,0x65, 0x7,0x61,0x68, 0x5,0x79,0x64, 0x4,0x6d,0x36, + 0xf,0x6c,0x42, 0xf,0x6c,0x43, 0x7,0x61,0x69, 0x5,0x7a,0x4f, + 0x7,0x63,0x2a, 0x7,0x63,0x2b, 0x7,0x64,0x2c, 0x4,0x6e,0x29, + 0x5,0x7b,0x26, 0xf,0x6c,0x72, 0x7,0x64,0x77, 0x7,0x64,0x76, + 0x5,0x7b,0x4e, 0x4,0x6e,0x54, 0x6,0x23,0x3d, 0x6,0x23,0x3c, + 0x5,0x44,0x4b, 0x5,0x4b,0x5b, 0x5,0x4b,0x5c, 0x6,0x64,0x62, + 0x7,0x2b,0x5d, 0x7,0x36,0x34, 0x7,0x3e,0x3c, 0x7,0x45,0x45, + 0x4,0x5e,0x79, 0x7,0x51,0x7e, 0x7,0x56,0x5f, 0x5,0x72,0x40, + 0x7,0x5a,0x49, 0x7,0x60,0x3a, 0x7,0x60,0x39, 0x5,0x78,0x53, + 0x5,0x7b,0x4f, 0x7,0x2b,0x5e, 0x4,0x4f,0x23, 0x4,0x55,0x3c, + 0x7,0x45,0x46, 0x7,0x52,0x21, 0x7,0x56,0x61, 0x7,0x56,0x60, + 0x7,0x5a,0x4a, 0x7,0x5d,0x6e, 0xf,0x6c,0x73, 0x5,0x7b,0x50, + 0x4,0x42,0x24, 0x6,0x5a,0x4e, 0x6,0x64,0x64, 0x6,0x64,0x63, + 0x7,0x2b,0x5f, 0x7,0x36,0x38, 0x4,0x55,0x3e, 0x5,0x5a,0x3b, + 0x7,0x36,0x36, 0x7,0x36,0x35, 0x4,0x55,0x3d, 0x7,0x36,0x37, + 0x5,0x60,0x47, 0x7,0x3e,0x3d, 0x4,0x5e,0x7a, 0x7,0x45,0x48, + 0x7,0x45,0x49, 0x7,0x45,0x47, 0x7,0x4c,0x49, 0x5,0x6b,0x25, + 0x7,0x4c,0x4a, 0x4,0x65,0x51, 0x7,0x52,0x24, 0x7,0x52,0x23, + 0x7,0x52,0x22, 0x7,0x52,0x25, 0x7,0x56,0x62, 0x4,0x68,0x35, + 0x7,0x56,0x64, 0x5,0x72,0x42, 0x7,0x56,0x63, 0x7,0x56,0x65, + 0x7,0x56,0x66, 0x5,0x75,0x27, 0x7,0x5a,0x4c, 0x7,0x5d,0x71, + 0x7,0x5d,0x72, 0x5,0x76,0x78, 0x4,0x69,0x75, 0x4,0x6b,0x3a, + 0x7,0x5d,0x70, 0x5,0x76,0x79, 0x7,0x5d,0x6f, 0x7,0x5d,0x73, + 0x4,0x6c,0x46, 0x4,0x6c,0x45, 0x7,0x5d,0x74, 0x7,0x60,0x3b, + 0x7,0x61,0x6b, 0x7,0x61,0x6c, 0x5,0x7a,0x50, 0x7,0x63,0x2c, + 0x7,0x63,0x2d, 0x7,0x63,0x2e, 0x4,0x6e,0x2a, 0x7,0x64,0x2d, + 0x7,0x64,0x79, 0x7,0x64,0x78, 0x7,0x64,0x7a, 0x7,0x65,0x4f, + 0x5,0x7c,0x24, 0x4,0x6e,0x51, 0x5,0x7c,0x2d, 0x7,0x65,0x7d, + 0x7,0x66,0x4a, 0x7,0x66,0x4b, 0x6,0x50,0x4b, 0x5,0x3d,0x53, + 0x6,0x5a,0x52, 0x5,0x44,0x4e, 0x6,0x5a,0x51, 0x4,0x42,0x26, + 0x5,0x44,0x4c, 0x6,0x5a,0x50, 0x5,0x44,0x4d, 0x4,0x42,0x25, + 0x6,0x5a,0x4f, 0xf,0x39,0x30, 0xf,0x39,0x2f, 0x6,0x5a,0x53, + 0x5,0x4b,0x5f, 0x5,0x4b,0x60, 0x5,0x4b,0x61, 0x5,0x4b,0x5e, + 0x5,0x4b,0x5d, 0x5,0x4b,0x62, 0x6,0x64,0x68, 0x6,0x64,0x65, + 0x6,0x64,0x69, 0xf,0x4d,0x49, 0xf,0x4d,0x4a, 0xf,0x4d,0x4b, + 0x6,0x64,0x6b, 0x6,0x64,0x66, 0x6,0x64,0x6e, 0x6,0x64,0x6c, + 0x6,0x64,0x6d, 0x6,0x64,0x6a, 0x6,0x64,0x67, 0x4,0x4f,0x27, + 0x5,0x53,0x29, 0x7,0x2b,0x61, 0x7,0x2b,0x60, 0x5,0x53,0x28, + 0x5,0x53,0x2b, 0x5,0x5a,0x41, 0x5,0x53,0x2a, 0x4,0x4f,0x26, + 0x7,0x2b,0x63, 0x5,0x53,0x25, 0xf,0x53,0x34, 0xf,0x53,0x35, + 0xf,0x53,0x36, 0x5,0x53,0x27, 0x7,0x2b,0x62, 0x5,0x53,0x26, + 0x5,0x5a,0x3c, 0x7,0x36,0x3a, 0x5,0x5a,0x45, 0x5,0x5a,0x43, + 0x7,0x36,0x39, 0x4,0x55,0x40, 0x5,0x5a,0x44, 0x7,0x36,0x3b, + 0xf,0x59,0x34, 0x5,0x5a,0x3e, 0x5,0x5a,0x3d, 0x5,0x5a,0x3f, + 0x5,0x5a,0x42, 0x7,0x36,0x3c, 0x5,0x5a,0x40, 0x4,0x5a,0x3d, + 0x5,0x60,0x49, 0x5,0x60,0x4c, 0x5,0x60,0x50, 0x4,0x5a,0x3e, + 0x7,0x3e,0x3e, 0x5,0x60,0x48, 0x5,0x60,0x4a, 0x5,0x60,0x4f, + 0x5,0x60,0x4d, 0x7,0x3e,0x40, 0x7,0x3e,0x41, 0x7,0x3e,0x43, + 0xf,0x5d,0x70, 0xf,0x5d,0x71, 0xf,0x5d,0x72, 0x5,0x60,0x4e, + 0x7,0x3e,0x3f, 0x7,0x3e,0x42, 0x5,0x60,0x4b, 0x5,0x66,0x63, + 0x7,0x45,0x4b, 0x4,0x5e,0x7b, 0x5,0x66,0x69, 0x7,0x45,0x4e, + 0x5,0x66,0x67, 0x5,0x66,0x65, 0x7,0x45,0x4f, 0x7,0x45,0x4c, + 0xf,0x61,0x67, 0x7,0x45,0x4a, 0x7,0x45,0x51, 0x5,0x66,0x62, + 0x7,0x45,0x4d, 0x7,0x45,0x50, 0x5,0x66,0x66, 0x5,0x6b,0x26, + 0x5,0x6b,0x29, 0x7,0x4c,0x4b, 0x5,0x6b,0x27, 0x7,0x4c,0x4c, + 0x7,0x4c,0x4d, 0xf,0x64,0x64, 0xf,0x64,0x65, 0xf,0x64,0x66, + 0xf,0x64,0x67, 0x5,0x66,0x64, 0x5,0x6b,0x28, 0x7,0x52,0x2b, + 0x4,0x65,0x52, 0x7,0x52,0x2a, 0x5,0x6f,0x21, 0x7,0x52,0x29, + 0x7,0x52,0x28, 0x5,0x6f,0x22, 0x7,0x52,0x26, 0xf,0x67,0x29, + 0x5,0x72,0x44, 0x5,0x72,0x46, 0x5,0x72,0x48, 0x4,0x68,0x37, + 0x7,0x56,0x67, 0x7,0x56,0x68, 0xf,0x69,0x25, 0x5,0x72,0x45, + 0x5,0x72,0x43, 0x7,0x56,0x69, 0x5,0x72,0x47, 0x5,0x75,0x2a, + 0x4,0x62,0x51, 0x7,0x5a,0x50, 0x4,0x69,0x78, 0x5,0x75,0x28, + 0x7,0x5a,0x4e, 0x4,0x69,0x79, 0x5,0x75,0x2b, 0xf,0x6a,0x3d, + 0x5,0x75,0x2c, 0x5,0x75,0x29, 0x4,0x69,0x7a, 0xf,0x67,0x2a, + 0x7,0x5a,0x4d, 0x5,0x76,0x7b, 0x5,0x76,0x7a, 0xf,0x69,0x26, + 0x5,0x78,0x54, 0x5,0x78,0x55, 0x4,0x6c,0x47, 0x7,0x60,0x3f, + 0x7,0x60,0x3e, 0x7,0x60,0x40, 0x7,0x60,0x3d, 0x5,0x79,0x67, + 0x5,0x79,0x66, 0xf,0x6c,0x44, 0x7,0x63,0x2f, 0x4,0x6e,0x2b, + 0x7,0x64,0x2e, 0x7,0x64,0x2f, 0x4,0x6e,0x41, 0x5,0x7b,0x51, + 0x5,0x7b,0x6f, 0x5,0x7c,0x25, 0x5,0x7c,0x40, 0x4,0x30,0x43, + 0x4,0x42,0x2a, 0x4,0x42,0x27, 0x6,0x5a,0x55, 0x4,0x42,0x28, + 0x6,0x5a,0x56, 0x5,0x44,0x4f, 0xf,0x46,0x3b, 0x6,0x64,0x6f, + 0x5,0x4b,0x65, 0x4,0x48,0x6c, 0x5,0x4b,0x63, 0xf,0x4d,0x4c, + 0xf,0x4d,0x4d, 0x5,0x4b,0x66, 0x4,0x4f,0x2f, 0x4,0x4f,0x33, + 0x4,0x4f,0x31, 0x4,0x4f,0x2d, 0x7,0x2b,0x68, 0x5,0x53,0x31, + 0x5,0x53,0x30, 0x7,0x2b,0x65, 0x7,0x2b,0x64, 0x5,0x53,0x2e, + 0x4,0x4f,0x38, 0x5,0x53,0x33, 0x5,0x53,0x2c, 0x5,0x53,0x2d, + 0x7,0x2b,0x6c, 0x7,0x2b,0x66, 0x4,0x4f,0x36, 0x5,0x53,0x32, + 0xf,0x53,0x37, 0xf,0x53,0x3a, 0xf,0x53,0x3d, 0x7,0x2b,0x6b, + 0x7,0x2b,0x67, 0x7,0x2b,0x69, 0x4,0x4f,0x2e, 0xf,0x53,0x39, + 0x5,0x53,0x2f, 0x5,0x5a,0x48, 0x5,0x5a,0x46, 0x7,0x36,0x3d, + 0x5,0x5a,0x49, 0x4,0x55,0x46, 0x4,0x5a,0x46, 0x5,0x5a,0x4e, + 0x5,0x5a,0x4d, 0x4,0x55,0x49, 0x7,0x36,0x43, 0x7,0x36,0x3e, + 0x7,0x36,0x41, 0x7,0x36,0x40, 0x5,0x5a,0x4c, 0x7,0x36,0x44, + 0xf,0x59,0x36, 0xf,0x59,0x37, 0xf,0x59,0x39, 0xf,0x59,0x3a, + 0x5,0x5a,0x4b, 0x7,0x36,0x42, 0xf,0x59,0x35, 0x5,0x5a,0x47, + 0x7,0x36,0x3f, 0x5,0x60,0x56, 0x4,0x5a,0x48, 0x5,0x60,0x57, + 0x5,0x60,0x54, 0x5,0x60,0x52, 0x4,0x5a,0x47, 0x7,0x3e,0x4b, + 0x5,0x60,0x55, 0x7,0x3e,0x46, 0x7,0x3e,0x4d, 0x7,0x3e,0x45, + 0x4,0x5a,0x4b, 0x7,0x3e,0x4c, 0x5,0x60,0x5a, 0x5,0x60,0x58, + 0x7,0x3e,0x44, 0x4,0x5a,0x4a, 0xf,0x46,0x3c, 0xf,0x5d,0x73, + 0xf,0x5d,0x74, 0xf,0x5d,0x75, 0xf,0x5d,0x77, 0xf,0x5d,0x79, + 0x7,0x3e,0x48, 0x5,0x60,0x5b, 0x5,0x60,0x53, 0x7,0x3e,0x4a, + 0x5,0x60,0x51, 0x5,0x60,0x59, 0x5,0x66,0x77, 0x5,0x66,0x74, + 0x5,0x66,0x70, 0x5,0x66,0x6b, 0x7,0x45,0x53, 0x4,0x5f,0x28, + 0x5,0x66,0x6d, 0x7,0x45,0x52, 0x5,0x66,0x6a, 0x5,0x66,0x71, + 0x5,0x66,0x75, 0x5,0x66,0x72, 0x5,0x66,0x6f, 0x5,0x66,0x6c, + 0x7,0x45,0x54, 0xf,0x61,0x68, 0xf,0x61,0x69, 0xf,0x61,0x6a, + 0xf,0x61,0x6b, 0xf,0x61,0x6c, 0xf,0x61,0x6d, 0xf,0x61,0x6e, + 0xf,0x61,0x6f, 0xf,0x61,0x71, 0xf,0x61,0x73, 0x7,0x45,0x55, + 0x7,0x3e,0x47, 0x5,0x66,0x76, 0x5,0x66,0x73, 0x7,0x4c,0x5b, + 0x7,0x4c,0x58, 0x4,0x62,0x5e, 0x7,0x4c,0x52, 0x5,0x6b,0x2d, + 0x4,0x62,0x52, 0x5,0x6b,0x2f, 0x7,0x4c,0x4f, 0x7,0x4c,0x51, + 0x4,0x62,0x5f, 0x5,0x66,0x78, 0x4,0x62,0x63, 0x5,0x6b,0x32, + 0x4,0x62,0x5b, 0x7,0x4c,0x4e, 0x4,0x62,0x5a, 0x4,0x62,0x65, + 0x7,0x4c,0x5a, 0x7,0x4c,0x53, 0x7,0x4c,0x59, 0x4,0x62,0x58, + 0x7,0x4c,0x55, 0x5,0x6b,0x36, 0x5,0x6b,0x2e, 0x7,0x4c,0x50, + 0x5,0x6b,0x34, 0xf,0x64,0x6e, 0xf,0x64,0x68, 0xf,0x64,0x6a, + 0xf,0x64,0x6c, 0xf,0x64,0x6f, 0xf,0x64,0x70, 0xf,0x64,0x71, + 0x5,0x6b,0x30, 0x7,0x4c,0x54, 0x7,0x4c,0x57, 0x4,0x62,0x53, + 0x5,0x6b,0x37, 0x5,0x6b,0x2a, 0xf,0x64,0x69, 0x5,0x6b,0x2c, + 0xf,0x61,0x70, 0x7,0x4c,0x56, 0x5,0x6f,0x27, 0x7,0x52,0x2e, + 0x5,0x6f,0x26, 0x5,0x6b,0x38, 0x5,0x6f,0x29, 0x7,0x52,0x2c, + 0x4,0x65,0x58, 0x5,0x6f,0x2b, 0x7,0x52,0x2f, 0x7,0x52,0x2d, + 0x5,0x6f,0x28, 0x4,0x65,0x56, 0x5,0x6f,0x24, 0x7,0x52,0x32, + 0x4,0x65,0x5e, 0x5,0x6f,0x25, 0x5,0x6f,0x23, 0x4,0x65,0x60, + 0x7,0x52,0x30, 0x5,0x6f,0x2c, 0x7,0x52,0x34, 0xf,0x67,0x2b, + 0xf,0x67,0x2c, 0xf,0x67,0x2d, 0xf,0x67,0x2f, 0xf,0x67,0x30, + 0xf,0x67,0x31, 0xf,0x67,0x32, 0xf,0x67,0x2e, 0x5,0x6f,0x2a, + 0xf,0x67,0x34, 0x5,0x72,0x4a, 0x4,0x68,0x3f, 0x5,0x72,0x4f, + 0x5,0x72,0x53, 0x5,0x77,0x23, 0x5,0x72,0x49, 0x5,0x72,0x52, + 0x4,0x68,0x38, 0x7,0x56,0x71, 0x5,0x72,0x4c, 0x7,0x56,0x72, + 0x5,0x72,0x57, 0x7,0x56,0x6d, 0x5,0x72,0x54, 0x5,0x72,0x4d, + 0x7,0x56,0x73, 0x7,0x56,0x75, 0x7,0x56,0x6a, 0x7,0x56,0x74, + 0x5,0x72,0x56, 0x7,0x56,0x6e, 0x7,0x56,0x6f, 0xf,0x69,0x28, + 0xf,0x69,0x29, 0xf,0x69,0x2b, 0xf,0x69,0x2c, 0xf,0x69,0x2d, + 0xf,0x69,0x2e, 0xf,0x69,0x2f, 0xf,0x69,0x30, 0xf,0x69,0x31, + 0xf,0x69,0x32, 0x7,0x56,0x6b, 0x7,0x56,0x6c, 0x5,0x72,0x55, + 0x7,0x56,0x70, 0x5,0x72,0x50, 0x7,0x5a,0x54, 0x7,0x5a,0x52, + 0x5,0x75,0x32, 0x4,0x6a,0x22, 0x5,0x75,0x2e, 0x5,0x75,0x2f, + 0x7,0x5a,0x5a, 0x7,0x5a,0x57, 0x5,0x75,0x30, 0x7,0x5a,0x5c, + 0x7,0x5a,0x59, 0x5,0x75,0x34, 0x7,0x5a,0x56, 0x7,0x5a,0x5b, + 0x7,0x5a,0x53, 0x7,0x5a,0x55, 0x7,0x5a,0x51, 0x7,0x5a,0x5e, + 0xf,0x6a,0x41, 0xf,0x6a,0x42, 0xf,0x6a,0x43, 0xf,0x6a,0x40, + 0x7,0x5a,0x5f, 0x5,0x75,0x33, 0x7,0x5a,0x58, 0x7,0x5a,0x5d, + 0x5,0x75,0x31, 0x5,0x76,0x7e, 0x7,0x5d,0x78, 0x5,0x77,0x22, + 0x4,0x6b,0x3e, 0x4,0x6b,0x3f, 0x5,0x76,0x7c, 0x7,0x5d,0x77, + 0x4,0x65,0x5c, 0x7,0x60,0x46, 0x7,0x5d,0x75, 0x7,0x5e,0x22, + 0x7,0x5d,0x76, 0x5,0x76,0x7d, 0x7,0x5e,0x21, 0x7,0x5d,0x7c, + 0x5,0x77,0x21, 0x7,0x5d,0x79, 0xf,0x6b,0x3d, 0xf,0x6b,0x3f, + 0x7,0x5d,0x7a, 0x7,0x5d,0x7d, 0x7,0x5d,0x7e, 0x7,0x5d,0x7b, + 0xf,0x6b,0x3c, 0x7,0x60,0x43, 0x5,0x78,0x5c, 0x5,0x78,0x60, + 0x5,0x78,0x5a, 0x7,0x60,0x41, 0x4,0x6c,0x4f, 0x4,0x6c,0x4c, + 0x5,0x78,0x59, 0x5,0x78,0x61, 0x4,0x6c,0x4b, 0x5,0x78,0x5f, + 0x5,0x78,0x5e, 0x5,0x78,0x57, 0x7,0x60,0x4b, 0x7,0x60,0x47, + 0x5,0x78,0x58, 0xf,0x6b,0x75, 0xf,0x6b,0x78, 0x7,0x60,0x48, + 0x7,0x60,0x42, 0x7,0x60,0x44, 0x7,0x60,0x45, 0x5,0x78,0x5d, + 0x7,0x60,0x4a, 0x7,0x60,0x49, 0x7,0x61,0x73, 0x5,0x79,0x68, + 0x4,0x6d,0x38, 0x5,0x79,0x69, 0x7,0x61,0x6e, 0x7,0x60,0x7a, + 0x7,0x61,0x71, 0x7,0x61,0x6f, 0x5,0x79,0x6b, 0x7,0x61,0x72, + 0x7,0x61,0x70, 0xf,0x6c,0x45, 0xf,0x6c,0x46, 0x5,0x79,0x6a, + 0x7,0x61,0x6d, 0x7,0x63,0x35, 0x7,0x63,0x30, 0x7,0x63,0x32, + 0x7,0x63,0x33, 0x7,0x63,0x34, 0x5,0x7a,0x51, 0x5,0x7a,0x52, + 0xf,0x6c,0x5a, 0xf,0x6c,0x5b, 0xf,0x6c,0x5c, 0xf,0x6c,0x5d, + 0x7,0x63,0x31, 0x5,0x7b,0x28, 0x5,0x7b,0x27, 0x7,0x64,0x30, + 0x5,0x7b,0x29, 0xf,0x6c,0x74, 0x7,0x64,0x31, 0x5,0x7b,0x2a, + 0x7,0x64,0x32, 0x7,0x64,0x7e, 0x5,0x7b,0x53, 0x5,0x7b,0x52, + 0x5,0x7b,0x55, 0x7,0x64,0x7c, 0x7,0x65,0x21, 0x7,0x64,0x7b, + 0x5,0x7b,0x54, 0x7,0x64,0x7d, 0xf,0x6c,0x75, 0x5,0x7b,0x73, + 0x5,0x7b,0x72, 0x5,0x7b,0x71, 0x5,0x7b,0x70, 0x7,0x65,0x50, + 0x5,0x7c,0x26, 0xf,0x6d,0x2b, 0xf,0x6d,0x2c, 0x5,0x7c,0x27, + 0x7,0x65,0x6b, 0x5,0x7c,0x2e, 0x5,0x7c,0x37, 0x7,0x66,0x2f, + 0x5,0x7c,0x36, 0xf,0x53,0x3c, 0xf,0x5d,0x78, 0xf,0x6b,0x3e, + 0x6,0x50,0x4c, 0xf,0x40,0x33, 0x6,0x50,0x4d, 0x4,0x42,0x2b, + 0x6,0x5a,0x57, 0x5,0x44,0x51, 0x5,0x44,0x52, 0x6,0x5a,0x5c, + 0x6,0x5a,0x58, 0x6,0x5a,0x59, 0x5,0x44,0x50, 0x6,0x5a,0x5a, + 0x6,0x5a,0x5b, 0x6,0x64,0x70, 0x5,0x4b,0x6a, 0x6,0x64,0x71, + 0x5,0x4b,0x69, 0x4,0x48,0x6e, 0x4,0x48,0x6f, 0x6,0x64,0x72, + 0x6,0x64,0x73, 0x6,0x64,0x74, 0x4,0x48,0x70, 0x5,0x4b,0x68, + 0xf,0x4d,0x4f, 0xf,0x4d,0x50, 0xf,0x4d,0x51, 0x5,0x4b,0x67, + 0x4,0x4f,0x45, 0x7,0x2b,0x72, 0x7,0x2b,0x7d, 0x7,0x2b,0x6f, + 0x7,0x2b,0x73, 0x7,0x2b,0x79, 0x5,0x53,0x37, 0x5,0x53,0x3b, + 0x5,0x53,0x3d, 0x5,0x53,0x39, 0x7,0x2b,0x76, 0x7,0x2b,0x7c, + 0x5,0x53,0x3f, 0x5,0x53,0x34, 0x4,0x4f,0x3d, 0x5,0x53,0x41, + 0x5,0x53,0x3e, 0x5,0x53,0x35, 0x4,0x4f,0x3e, 0x5,0x53,0x42, + 0x7,0x2b,0x7a, 0x4,0x4f,0x3c, 0x7,0x2b,0x75, 0x4,0x4f,0x43, + 0x4,0x4f,0x3a, 0x5,0x53,0x43, 0x4,0x4f,0x46, 0x7,0x2b,0x70, + 0x7,0x2b,0x7b, 0xf,0x53,0x40, 0x7,0x2b,0x6e, 0x7,0x2b,0x77, + 0x7,0x2b,0x78, 0x5,0x53,0x36, 0x5,0x53,0x3a, 0x5,0x53,0x40, + 0x7,0x2b,0x71, 0x7,0x2b,0x74, 0x5,0x53,0x3c, 0x7,0x36,0x4b, + 0x5,0x5a,0x54, 0x5,0x5a,0x56, 0x5,0x5a,0x51, 0x5,0x5a,0x4f, + 0x4,0x55,0x4c, 0x5,0x5a,0x53, 0x5,0x5a,0x59, 0x5,0x5a,0x52, + 0x7,0x36,0x57, 0x7,0x36,0x52, 0x5,0x5a,0x57, 0x4,0x55,0x56, + 0x7,0x36,0x54, 0x5,0x5a,0x58, 0x7,0x36,0x50, 0x5,0x5a,0x55, + 0x7,0x36,0x53, 0x7,0x36,0x4c, 0x7,0x36,0x45, 0x7,0x36,0x4e, + 0xf,0x59,0x3d, 0xf,0x59,0x3e, 0xf,0x59,0x3f, 0xf,0x59,0x40, + 0x7,0x36,0x4d, 0x7,0x36,0x4f, 0x7,0x36,0x58, 0x7,0x36,0x56, + 0x7,0x36,0x47, 0x7,0x36,0x48, 0x7,0x36,0x55, 0x4,0x55,0x53, + 0x4,0x55,0x51, 0x6,0x50,0x4e, 0x7,0x36,0x49, 0x5,0x5a,0x50, + 0x7,0x36,0x46, 0xf,0x56,0x33, 0x7,0x3e,0x51, 0x4,0x5a,0x4c, + 0x5,0x60,0x5e, 0x5,0x60,0x69, 0x7,0x3e,0x54, 0x4,0x5a,0x53, + 0x5,0x60,0x67, 0x7,0x3e,0x55, 0x5,0x60,0x5d, 0x5,0x60,0x61, + 0x7,0x3e,0x4e, 0x5,0x60,0x64, 0x5,0x60,0x6b, 0x5,0x60,0x60, + 0x5,0x60,0x62, 0x4,0x5a,0x54, 0x7,0x3e,0x57, 0x5,0x60,0x5c, + 0x5,0x60,0x63, 0x4,0x5a,0x58, 0x7,0x3e,0x4f, 0x4,0x5a,0x5b, + 0x5,0x60,0x6c, 0x7,0x3e,0x58, 0x7,0x3e,0x53, 0x5,0x60,0x68, + 0x5,0x60,0x6a, 0xf,0x5d,0x7a, 0xf,0x5d,0x7b, 0xf,0x5d,0x7c, + 0xf,0x5d,0x7d, 0xf,0x5e,0x21, 0xf,0x5e,0x22, 0xf,0x5e,0x23, + 0xf,0x5e,0x25, 0x7,0x3e,0x50, 0x5,0x60,0x5f, 0x4,0x5a,0x5a, + 0x7,0x3e,0x56, 0x5,0x60,0x65, 0x5,0x60,0x66, 0x7,0x3e,0x52, + 0x4,0x5a,0x57, 0x7,0x45,0x5b, 0x5,0x60,0x6d, 0x7,0x45,0x5f, + 0x5,0x66,0x7d, 0x5,0x67,0x25, 0x5,0x67,0x27, 0x4,0x5f,0x2e, + 0x5,0x67,0x2a, 0x5,0x66,0x7a, 0x5,0x67,0x21, 0x5,0x66,0x7e, + 0x5,0x66,0x7b, 0x7,0x45,0x5d, 0x7,0x45,0x58, 0x4,0x5f,0x2d, + 0x7,0x45,0x5e, 0x5,0x66,0x7c, 0x5,0x67,0x2b, 0x4,0x5f,0x30, + 0x7,0x45,0x67, 0x5,0x67,0x22, 0x7,0x45,0x64, 0x7,0x45,0x5c, + 0x5,0x67,0x28, 0x7,0x45,0x61, 0x7,0x45,0x62, 0x7,0x45,0x66, + 0x5,0x67,0x24, 0x7,0x45,0x59, 0x5,0x67,0x23, 0x7,0x45,0x68, + 0x7,0x45,0x56, 0x7,0x45,0x60, 0xf,0x61,0x74, 0xf,0x61,0x75, + 0x7,0x45,0x57, 0x5,0x67,0x29, 0x7,0x45,0x63, 0x5,0x6b,0x39, + 0x7,0x4c,0x5d, 0x5,0x6b,0x3a, 0x7,0x4c,0x62, 0x5,0x6b,0x3e, + 0x5,0x6b,0x4a, 0x5,0x6b,0x40, 0x7,0x4c,0x6a, 0x7,0x4c,0x64, + 0x5,0x6b,0x3b, 0x7,0x4c,0x68, 0x7,0x4c,0x6b, 0x7,0x4c,0x63, + 0x5,0x6b,0x4c, 0x5,0x6b,0x3d, 0x5,0x6b,0x4b, 0x4,0x62,0x6b, + 0x5,0x6b,0x42, 0x5,0x6b,0x45, 0x7,0x4c,0x60, 0x7,0x4c,0x5e, + 0x5,0x6b,0x48, 0x5,0x6b,0x44, 0x7,0x4c,0x5c, 0x7,0x4c,0x66, + 0x7,0x4c,0x6c, 0x5,0x6b,0x41, 0x4,0x62,0x6d, 0x7,0x4c,0x69, + 0x5,0x6b,0x46, 0xf,0x64,0x74, 0xf,0x64,0x76, 0xf,0x64,0x77, + 0x7,0x4c,0x61, 0x5,0x6b,0x47, 0x7,0x4c,0x6f, 0x5,0x6b,0x49, + 0x7,0x45,0x69, 0x7,0x4c,0x65, 0x7,0x4c,0x67, 0x7,0x4c,0x6d, + 0x5,0x6b,0x43, 0x7,0x4c,0x6e, 0x7,0x4c,0x5f, 0x4,0x62,0x69, + 0x5,0x6f,0x38, 0x5,0x6f,0x30, 0x7,0x52,0x3a, 0x4,0x65,0x65, + 0x5,0x6f,0x3e, 0x7,0x52,0x43, 0x5,0x6f,0x32, 0x5,0x6f,0x42, + 0x4,0x62,0x70, 0x7,0x52,0x36, 0x5,0x6f,0x2f, 0x4,0x65,0x63, + 0x5,0x6f,0x31, 0x4,0x65,0x6e, 0x4,0x65,0x68, 0x5,0x6f,0x33, + 0x5,0x6f,0x2d, 0x5,0x6f,0x37, 0x5,0x6f,0x44, 0x5,0x6f,0x39, + 0x4,0x65,0x6d, 0x4,0x65,0x66, 0x5,0x6f,0x3a, 0x5,0x6f,0x3c, + 0x5,0x6f,0x40, 0x4,0x65,0x67, 0x5,0x6f,0x2e, 0x5,0x6f,0x3b, + 0x5,0x6f,0x36, 0x5,0x6f,0x3f, 0x7,0x52,0x3f, 0x7,0x52,0x3b, + 0x7,0x52,0x40, 0x7,0x52,0x35, 0x7,0x52,0x37, 0x5,0x6f,0x3d, + 0x5,0x6f,0x35, 0x5,0x6f,0x34, 0x5,0x6f,0x43, 0x7,0x52,0x38, + 0xf,0x67,0x37, 0x7,0x52,0x3e, 0x7,0x52,0x3d, 0x7,0x52,0x39, + 0x7,0x52,0x44, 0x7,0x52,0x41, 0x7,0x52,0x3c, 0xf,0x67,0x38, + 0x5,0x6f,0x41, 0x7,0x45,0x5a, 0x5,0x72,0x5e, 0x7,0x56,0x79, + 0x5,0x72,0x66, 0x7,0x56,0x7e, 0x5,0x72,0x5d, 0x5,0x72,0x60, + 0x5,0x72,0x5b, 0x5,0x72,0x65, 0x5,0x72,0x64, 0x7,0x57,0x21, + 0x7,0x56,0x7d, 0x7,0x56,0x7a, 0x5,0x72,0x68, 0x7,0x57,0x27, + 0x7,0x57,0x26, 0x7,0x57,0x24, 0x5,0x72,0x5c, 0x5,0x72,0x61, + 0x5,0x6f,0x45, 0x5,0x72,0x5a, 0x5,0x72,0x62, 0x7,0x57,0x22, + 0x7,0x56,0x7c, 0x5,0x72,0x69, 0x5,0x72,0x6a, 0xf,0x69,0x34, + 0x5,0x72,0x5f, 0x7,0x57,0x23, 0x7,0x56,0x77, 0x7,0x57,0x28, + 0x7,0x56,0x76, 0x7,0x56,0x7b, 0xf,0x69,0x33, 0x5,0x72,0x58, + 0x7,0x56,0x78, 0x5,0x72,0x59, 0xf,0x67,0x36, 0x5,0x75,0x42, + 0x5,0x75,0x3d, 0x4,0x6a,0x24, 0x4,0x6a,0x2d, 0x5,0x75,0x3c, + 0x4,0x6a,0x28, 0x5,0x75,0x43, 0x5,0x75,0x39, 0x5,0x6f,0x46, + 0x5,0x75,0x44, 0x5,0x75,0x40, 0x5,0x75,0x3f, 0x4,0x6a,0x2b, + 0x7,0x5a,0x62, 0x7,0x5a,0x6c, 0x7,0x5a,0x6a, 0x7,0x5a,0x70, + 0x4,0x6a,0x2a, 0x7,0x5a,0x6b, 0x7,0x5a,0x6e, 0x5,0x75,0x3b, + 0x4,0x6a,0x29, 0x7,0x5a,0x69, 0x5,0x75,0x37, 0x7,0x5a,0x68, + 0x5,0x75,0x38, 0x5,0x75,0x46, 0x5,0x72,0x67, 0x7,0x5a,0x71, + 0x5,0x75,0x41, 0x7,0x5a,0x6f, 0x7,0x5a,0x67, 0x7,0x57,0x25, + 0xf,0x6a,0x44, 0xf,0x6a,0x45, 0xf,0x6a,0x46, 0xf,0x6a,0x47, + 0xf,0x6a,0x48, 0x5,0x75,0x3e, 0x7,0x5a,0x66, 0x7,0x5a,0x64, + 0x7,0x5a,0x61, 0x7,0x5a,0x63, 0x5,0x75,0x3a, 0x7,0x5e,0x2b, + 0x7,0x5e,0x27, 0x7,0x5e,0x31, 0x5,0x77,0x33, 0x7,0x5e,0x2f, + 0x5,0x77,0x2e, 0x5,0x77,0x29, 0x4,0x6b,0x43, 0x7,0x5e,0x32, + 0x7,0x5e,0x36, 0x5,0x77,0x25, 0x5,0x77,0x30, 0x5,0x77,0x2a, + 0x5,0x77,0x28, 0x5,0x77,0x2f, 0x7,0x5e,0x2c, 0x5,0x77,0x27, + 0x5,0x77,0x26, 0x5,0x77,0x38, 0x5,0x77,0x2b, 0x4,0x6b,0x49, + 0x4,0x6b,0x42, 0x7,0x5e,0x35, 0x5,0x77,0x31, 0x7,0x5e,0x30, + 0x7,0x5e,0x33, 0x5,0x77,0x2d, 0x7,0x5a,0x65, 0x5,0x77,0x35, + 0x7,0x5a,0x6d, 0x7,0x5e,0x34, 0x5,0x77,0x36, 0x7,0x5e,0x2d, + 0xf,0x6b,0x40, 0x7,0x5e,0x24, 0x7,0x5e,0x26, 0x7,0x5e,0x2e, + 0x7,0x5e,0x29, 0x7,0x5e,0x28, 0x5,0x77,0x32, 0x7,0x5e,0x2a, + 0x7,0x5e,0x25, 0x4,0x6b,0x41, 0xf,0x6b,0x7a, 0x7,0x5e,0x37, + 0x7,0x60,0x4d, 0x5,0x78,0x67, 0x5,0x78,0x69, 0x5,0x78,0x6d, + 0x5,0x78,0x65, 0x5,0x77,0x37, 0x5,0x78,0x68, 0x7,0x60,0x4e, + 0x5,0x78,0x6a, 0x5,0x78,0x6b, 0x7,0x60,0x4f, 0x7,0x60,0x50, + 0x7,0x60,0x54, 0x5,0x78,0x6c, 0x7,0x60,0x53, 0x7,0x60,0x4c, + 0x7,0x60,0x51, 0x5,0x78,0x63, 0x5,0x78,0x66, 0x5,0x78,0x62, + 0xf,0x6b,0x79, 0x7,0x60,0x52, 0x4,0x6c,0x55, 0x5,0x78,0x64, + 0x4,0x6c,0x53, 0x5,0x79,0x71, 0x5,0x79,0x6d, 0x5,0x79,0x70, + 0x7,0x61,0x76, 0x4,0x6d,0x3b, 0x5,0x79,0x6e, 0x5,0x79,0x6c, + 0x4,0x6d,0x3c, 0x7,0x61,0x74, 0x5,0x79,0x6f, 0x7,0x61,0x78, + 0x7,0x61,0x75, 0x7,0x61,0x77, 0x4,0x6d,0x3e, 0x5,0x7a,0x58, + 0x7,0x63,0x39, 0x5,0x7a,0x56, 0x4,0x6d,0x6b, 0x5,0x7a,0x5a, + 0x5,0x7a,0x59, 0x5,0x7a,0x55, 0x5,0x7a,0x57, 0x4,0x6d,0x6a, + 0x7,0x63,0x38, 0x5,0x7a,0x54, 0x7,0x63,0x3b, 0x5,0x7a,0x5b, + 0x7,0x63,0x3d, 0xf,0x6c,0x5e, 0x7,0x63,0x3a, 0x7,0x63,0x36, + 0x7,0x63,0x3c, 0x5,0x7b,0x2e, 0x7,0x64,0x34, 0x7,0x64,0x36, + 0x5,0x7b,0x2f, 0x5,0x7b,0x2c, 0x5,0x7b,0x2b, 0x5,0x7b,0x31, + 0x5,0x7b,0x30, 0x5,0x7b,0x2d, 0x7,0x64,0x37, 0xf,0x6c,0x76, + 0x4,0x6e,0x2e, 0x7,0x64,0x33, 0x7,0x64,0x35, 0x5,0x7b,0x56, + 0x7,0x65,0x22, 0x7,0x65,0x53, 0x7,0x65,0x24, 0x7,0x65,0x26, + 0x7,0x65,0x23, 0x7,0x65,0x27, 0x5,0x7b,0x57, 0x7,0x65,0x25, + 0x4,0x6e,0x42, 0x5,0x7b,0x74, 0x7,0x65,0x54, 0x7,0x65,0x55, + 0x5,0x7b,0x75, 0x7,0x65,0x52, 0x7,0x65,0x56, 0x7,0x65,0x51, + 0x7,0x65,0x6d, 0x7,0x65,0x6c, 0x5,0x7c,0x29, 0x5,0x7c,0x28, + 0xf,0x6d,0x32, 0x5,0x7c,0x2f, 0x7,0x66,0x21, 0x7,0x65,0x7e, + 0x5,0x7c,0x38, 0x7,0x66,0x30, 0x5,0x7c,0x39, 0x7,0x66,0x3a, + 0x5,0x7c,0x41, 0xf,0x6d,0x37, 0x5,0x7c,0x48, 0x7,0x66,0x45, + 0x4,0x48,0x71, 0x4,0x48,0x72, 0x5,0x53,0x44, 0x7,0x2c,0x22, + 0x7,0x2c,0x21, 0x7,0x2b,0x7e, 0x5,0x5a,0x5a, 0x5,0x5a,0x5c, + 0x7,0x36,0x5a, 0x7,0x36,0x5b, 0xf,0x59,0x41, 0x7,0x36,0x59, + 0x5,0x67,0x2c, 0x7,0x3e,0x59, 0x4,0x62,0x71, 0x7,0x4c,0x70, + 0x5,0x6b,0x4d, 0x7,0x4c,0x71, 0x7,0x52,0x46, 0x5,0x6f,0x48, + 0x5,0x6f,0x49, 0x7,0x52,0x47, 0x5,0x6f,0x47, 0x7,0x52,0x49, + 0x7,0x52,0x48, 0x4,0x68,0x45, 0x7,0x57,0x2b, 0x7,0x57,0x2a, + 0x5,0x72,0x6b, 0x7,0x5a,0x73, 0x7,0x5a,0x72, 0x4,0x6b,0x4c, + 0x7,0x5e,0x38, 0x7,0x5e,0x39, 0x5,0x77,0x39, 0x7,0x60,0x55, + 0x4,0x6c,0x57, 0x5,0x79,0x72, 0x4,0x6d,0x3f, 0x7,0x63,0x3e, + 0x5,0x7b,0x32, 0x6,0x5a,0x5d, 0xf,0x46,0x3d, 0x5,0x4b,0x6c, + 0xf,0x4d,0x52, 0x7,0x2c,0x28, 0x5,0x53,0x45, 0x7,0x2c,0x27, + 0x7,0x2c,0x26, 0x7,0x2c,0x24, 0x5,0x53,0x46, 0x7,0x2c,0x25, + 0x5,0x53,0x47, 0x7,0x2c,0x29, 0x7,0x2c,0x23, 0x7,0x36,0x5d, + 0x5,0x5a,0x5d, 0xf,0x59,0x42, 0xf,0x59,0x43, 0xf,0x59,0x44, + 0x5,0x60,0x6f, 0x5,0x60,0x72, 0x5,0x60,0x70, 0x4,0x5a,0x5c, + 0x5,0x60,0x73, 0x5,0x60,0x71, 0x7,0x3e,0x5b, 0x7,0x3e,0x5a, + 0x7,0x3e,0x5e, 0x7,0x3e,0x5d, 0xf,0x5e,0x26, 0x5,0x60,0x6e, + 0x7,0x45,0x6e, 0x5,0x67,0x31, 0x5,0x67,0x2e, 0x5,0x67,0x2d, + 0x7,0x45,0x6b, 0x7,0x45,0x6d, 0x7,0x45,0x6a, 0x5,0x67,0x30, + 0x7,0x45,0x6c, 0xf,0x61,0x78, 0xf,0x61,0x79, 0xf,0x61,0x7a, + 0x5,0x67,0x2f, 0x5,0x6b,0x4f, 0x5,0x6b,0x4e, 0x5,0x6b,0x51, + 0x4,0x62,0x73, 0x7,0x4c,0x73, 0x5,0x6b,0x50, 0x7,0x4c,0x72, + 0x5,0x68,0x40, 0x7,0x52,0x4b, 0x4,0x62,0x74, 0x4,0x65,0x6f, + 0x7,0x4c,0x74, 0xf,0x67,0x39, 0x7,0x52,0x4a, 0x7,0x52,0x4c, + 0x5,0x6f,0x4a, 0x4,0x68,0x47, 0x7,0x57,0x2c, 0x7,0x57,0x2d, + 0x4,0x68,0x46, 0xf,0x69,0x35, 0x5,0x75,0x47, 0x4,0x6a,0x2e, + 0xf,0x6a,0x49, 0x5,0x77,0x3a, 0x5,0x77,0x3c, 0x5,0x77,0x3b, + 0x7,0x5e,0x3a, 0x7,0x5e,0x3b, 0x7,0x60,0x56, 0x4,0x6c,0x58, + 0x7,0x60,0x57, 0xf,0x6b,0x7b, 0x5,0x79,0x75, 0x5,0x79,0x74, + 0x5,0x78,0x6e, 0x4,0x6d,0x40, 0x4,0x6d,0x6c, 0xf,0x6c,0x47, + 0x7,0x65,0x28, 0x7,0x65,0x57, 0x5,0x7c,0x46, 0x7,0x66,0x47, + 0x6,0x5a,0x5f, 0x6,0x5a,0x5e, 0x5,0x44,0x53, 0xf,0x46,0x3f, + 0x4,0x48,0x75, 0x6,0x64,0x75, 0xf,0x4d,0x53, 0x5,0x53,0x4b, + 0x5,0x53,0x4a, 0x4,0x4f,0x4f, 0x5,0x53,0x49, 0x5,0x53,0x48, + 0x7,0x2c,0x2b, 0x7,0x2c,0x2f, 0x7,0x2c,0x2a, 0x4,0x4f,0x4e, + 0x7,0x2c,0x2c, 0x5,0x53,0x4c, 0x7,0x2c,0x2e, 0x7,0x2c,0x2d, + 0x7,0x36,0x61, 0x7,0x36,0x5f, 0x7,0x36,0x5e, 0x7,0x36,0x63, + 0x4,0x55,0x5b, 0x7,0x36,0x62, 0x6,0x47,0x53, 0xf,0x59,0x45, + 0x5,0x5a,0x5e, 0x7,0x36,0x60, 0x5,0x60,0x74, 0x5,0x60,0x75, + 0x7,0x3e,0x60, 0x7,0x3e,0x61, 0xf,0x5e,0x28, 0x7,0x3e,0x62, + 0x7,0x3e,0x5f, 0x7,0x45,0x70, 0x5,0x67,0x32, 0x7,0x45,0x72, + 0x5,0x67,0x33, 0x5,0x67,0x35, 0x7,0x45,0x73, 0x5,0x67,0x34, + 0xf,0x61,0x7b, 0x7,0x45,0x71, 0x7,0x45,0x6f, 0x4,0x62,0x7a, + 0x4,0x62,0x78, 0x7,0x4c,0x79, 0x7,0x4c,0x7b, 0x7,0x4c,0x75, + 0x5,0x6b,0x54, 0x5,0x6b,0x52, 0x7,0x4c,0x7a, 0x5,0x6b,0x55, + 0x5,0x6b,0x53, 0x7,0x4c,0x78, 0x4,0x62,0x7b, 0x7,0x4c,0x77, + 0x7,0x4c,0x76, 0x5,0x6f,0x4b, 0x7,0x52,0x53, 0x7,0x52,0x52, + 0x5,0x6f,0x4c, 0x7,0x52,0x50, 0x4,0x65,0x70, 0x7,0x52,0x4f, + 0x5,0x6f,0x4e, 0x5,0x6f,0x4d, 0x7,0x52,0x51, 0xf,0x67,0x3a, + 0x7,0x52,0x4e, 0x7,0x52,0x4d, 0x5,0x72,0x6c, 0x7,0x57,0x2f, + 0x5,0x72,0x6f, 0x7,0x57,0x30, 0x5,0x72,0x6e, 0x7,0x57,0x31, + 0x7,0x57,0x2e, 0x5,0x72,0x6d, 0x5,0x75,0x4b, 0x5,0x75,0x4c, + 0x7,0x5a,0x74, 0x5,0x75,0x49, 0x5,0x75,0x4e, 0x7,0x5a,0x7b, + 0x7,0x5a,0x76, 0x7,0x5a,0x77, 0x7,0x5a,0x7c, 0x7,0x5a,0x79, + 0x5,0x75,0x4a, 0x7,0x5a,0x75, 0x7,0x5a,0x78, 0x7,0x5a,0x7a, + 0x5,0x77,0x3f, 0x4,0x6b,0x4f, 0x5,0x77,0x3e, 0x5,0x77,0x40, + 0x5,0x77,0x3d, 0x5,0x78,0x6f, 0x5,0x78,0x71, 0x5,0x78,0x70, + 0x7,0x60,0x59, 0x7,0x5e,0x3c, 0x4,0x6c,0x59, 0x7,0x60,0x58, + 0x4,0x6d,0x6d, 0x7,0x63,0x3f, 0x7,0x64,0x39, 0x7,0x64,0x38, + 0x5,0x7b,0x58, 0x7,0x65,0x29, 0x4,0x6e,0x52, 0x5,0x7c,0x30, + 0xf,0x29,0x21, 0xf,0x46,0x3e, 0xf,0x53,0x42, 0xf,0x5e,0x27, + 0x5,0x4b,0x70, 0x5,0x4b,0x6e, 0x5,0x4b,0x6f, 0x5,0x53,0x4e, + 0x4,0x4f,0x50, 0x5,0x53,0x4d, 0x7,0x2c,0x30, 0x5,0x5a,0x61, + 0x7,0x36,0x64, 0x5,0x5a,0x5f, 0x5,0x5a,0x60, 0xf,0x59,0x46, + 0x5,0x60,0x78, 0x5,0x60,0x76, 0xf,0x5e,0x29, 0x5,0x60,0x77, + 0x5,0x67,0x36, 0x7,0x4c,0x7c, 0x5,0x6b,0x56, 0x7,0x4c,0x7d, + 0x4,0x65,0x73, 0x7,0x57,0x32, 0x5,0x72,0x70, 0x7,0x5a,0x7e, + 0x4,0x6b,0x50, 0x7,0x5b,0x56, 0x7,0x5e,0x3d, 0x4,0x6b,0x51, + 0x5,0x7c,0x31, 0xf,0x4d,0x54, 0x7,0x2c,0x32, 0x5,0x5a,0x62, + 0x5,0x5a,0x64, 0x5,0x5a,0x63, 0x5,0x60,0x7a, 0x5,0x67,0x38, + 0x5,0x60,0x79, 0x5,0x67,0x39, 0x5,0x67,0x37, 0x5,0x6b,0x57, + 0x4,0x63,0x22, 0xf,0x64,0x79, 0x4,0x65,0x75, 0x4,0x65,0x74, + 0x5,0x6f,0x50, 0x5,0x6f,0x4f, 0x4,0x65,0x77, 0x7,0x52,0x54, + 0x7,0x52,0x55, 0x7,0x52,0x56, 0xf,0x67,0x3b, 0x7,0x52,0x57, + 0x5,0x72,0x73, 0x5,0x72,0x72, 0x5,0x72,0x71, 0x7,0x57,0x33, + 0x7,0x57,0x34, 0x5,0x75,0x4f, 0x4,0x6a,0x2f, 0x4,0x6a,0x30, + 0x7,0x5b,0x23, 0x7,0x5b,0x22, 0x7,0x5b,0x21, 0x7,0x5e,0x3e, + 0x5,0x78,0x72, 0x7,0x60,0x5a, 0x5,0x78,0x73, 0x7,0x61,0x79, + 0x5,0x79,0x76, 0x7,0x66,0x27, 0x4,0x48,0x76, 0x5,0x53,0x4f, + 0x4,0x4f,0x51, 0x7,0x36,0x68, 0x7,0x36,0x66, 0x5,0x5a,0x66, + 0x5,0x5a,0x65, 0x5,0x5a,0x67, 0x5,0x60,0x7e, 0x7,0x3e,0x64, + 0x5,0x60,0x7c, 0x7,0x3e,0x63, 0x5,0x60,0x7b, 0x4,0x5a,0x5e, + 0x5,0x60,0x7d, 0x7,0x3e,0x65, 0x7,0x3e,0x66, 0x5,0x67,0x3b, + 0x5,0x67,0x3a, 0x4,0x65,0x78, 0x5,0x6f,0x51, 0x5,0x6f,0x53, + 0x5,0x72,0x74, 0x7,0x57,0x36, 0x7,0x57,0x35, 0xf,0x69,0x36, + 0x5,0x75,0x50, 0x4,0x6b,0x54, 0x5,0x77,0x42, 0x5,0x77,0x41, + 0x4,0x6b,0x53, 0x7,0x63,0x40, 0x7,0x61,0x7a, 0x4,0x6d,0x6e, + 0x5,0x7b,0x5a, 0x7,0x65,0x2a, 0x5,0x7b,0x59, 0x6,0x64,0x76, + 0x5,0x44,0x54, 0x6,0x64,0x78, 0x6,0x64,0x77, 0x7,0x2c,0x34, + 0x4,0x4f,0x55, 0x4,0x4f,0x54, 0x5,0x53,0x50, 0x7,0x2c,0x35, + 0x7,0x2c,0x36, 0x7,0x36,0x6a, 0x5,0x5a,0x6a, 0x5,0x5a,0x68, + 0x5,0x5a,0x69, 0x7,0x36,0x69, 0x7,0x36,0x6b, 0x7,0x36,0x6c, + 0x4,0x5a,0x60, 0x7,0x3e,0x68, 0x5,0x61,0x21, 0xf,0x5e,0x2a, + 0x7,0x3e,0x67, 0x5,0x67,0x3e, 0x5,0x67,0x3c, 0x7,0x45,0x74, + 0x5,0x6b,0x58, 0x5,0x61,0x22, 0x5,0x67,0x3f, 0x5,0x6b,0x5a, + 0x5,0x6b,0x59, 0x5,0x6b,0x5b, 0x5,0x6b,0x5d, 0x5,0x6b,0x5c, + 0x7,0x4d,0x21, 0x7,0x4c,0x7e, 0x5,0x6f,0x56, 0x5,0x6f,0x57, + 0x7,0x52,0x5b, 0x5,0x6f,0x5b, 0x5,0x6f,0x59, 0x5,0x6f,0x55, + 0x7,0x52,0x58, 0x4,0x65,0x7e, 0x4,0x65,0x7b, 0x7,0x52,0x5c, + 0x5,0x6f,0x5a, 0x4,0x65,0x7a, 0x7,0x52,0x5a, 0xf,0x67,0x3c, + 0x7,0x52,0x59, 0x7,0x57,0x38, 0x4,0x68,0x53, 0x4,0x68,0x51, + 0x5,0x72,0x78, 0x4,0x68,0x50, 0x5,0x72,0x7b, 0x7,0x57,0x37, + 0x5,0x72,0x75, 0x5,0x72,0x79, 0x5,0x72,0x77, 0x4,0x68,0x54, + 0x5,0x72,0x76, 0x4,0x68,0x55, 0x4,0x6a,0x34, 0x7,0x57,0x39, + 0x7,0x57,0x3a, 0x5,0x72,0x7a, 0x5,0x75,0x51, 0x4,0x6a,0x33, + 0x4,0x6a,0x35, 0x7,0x5b,0x2a, 0x7,0x5b,0x27, 0x7,0x5b,0x26, + 0x4,0x6a,0x32, 0x7,0x5b,0x29, 0x7,0x5b,0x28, 0x5,0x75,0x52, + 0x7,0x5b,0x25, 0x5,0x77,0x47, 0x7,0x5e,0x41, 0x5,0x77,0x46, + 0x5,0x77,0x44, 0x5,0x77,0x45, 0x5,0x77,0x43, 0x5,0x77,0x48, + 0x7,0x5e,0x3f, 0x5,0x78,0x76, 0x5,0x78,0x77, 0x7,0x60,0x5d, + 0x4,0x6c,0x5c, 0x4,0x6c,0x60, 0x5,0x78,0x75, 0x7,0x60,0x5c, + 0x5,0x78,0x74, 0x4,0x6c,0x5f, 0x4,0x6c,0x5e, 0x4,0x6c,0x5d, + 0x7,0x5e,0x40, 0x7,0x60,0x5b, 0x5,0x79,0x78, 0x5,0x79,0x79, + 0x5,0x79,0x7a, 0x5,0x79,0x77, 0x4,0x6d,0x45, 0x7,0x61,0x7b, + 0x7,0x61,0x7c, 0x4,0x6d,0x46, 0x5,0x7a,0x5c, 0x7,0x64,0x3a, + 0x7,0x65,0x2b, 0x4,0x6e,0x30, 0x7,0x64,0x3b, 0x5,0x7b,0x33, + 0x4,0x6e,0x2f, 0x5,0x7b,0x5b, 0x5,0x7b,0x5c, 0x7,0x65,0x2c, + 0x4,0x6e,0x4a, 0x5,0x7b,0x76, 0x7,0x65,0x6e, 0x5,0x7c,0x4a, + 0x7,0x66,0x52, 0x7,0x45,0x75, 0x4,0x66,0x22, 0x5,0x72,0x7c, + 0x4,0x68,0x57, 0x5,0x77,0x49, 0x6,0x64,0x79, 0x7,0x2c,0x38, + 0x7,0x2c,0x37, 0x5,0x61,0x24, 0x7,0x36,0x6d, 0x4,0x5a,0x61, + 0x7,0x3e,0x69, 0x7,0x3e,0x6a, 0x7,0x45,0x78, 0x5,0x67,0x42, + 0x7,0x45,0x79, 0x7,0x45,0x77, 0x7,0x45,0x76, 0x4,0x5f,0x41, + 0x7,0x4d,0x24, 0x7,0x4d,0x25, 0x7,0x3e,0x6b, 0x7,0x4d,0x23, + 0x7,0x52,0x5e, 0x7,0x52,0x5f, 0x7,0x52,0x5d, 0x5,0x72,0x7d, + 0x7,0x57,0x3b, 0x4,0x6a,0x36, 0x7,0x5b,0x2c, 0x7,0x5b,0x31, + 0x7,0x5b,0x32, 0x7,0x5b,0x2e, 0x7,0x5b,0x30, 0x7,0x5b,0x2d, + 0x7,0x5b,0x2b, 0x7,0x5b,0x2f, 0x5,0x77,0x4a, 0x7,0x5e,0x42, + 0x5,0x78,0x78, 0x5,0x79,0x7b, 0x5,0x7a,0x5d, 0x4,0x6d,0x47, + 0x7,0x63,0x41, 0x5,0x7b,0x34, 0x7,0x63,0x42, 0x7,0x65,0x2d, + 0x6,0x50,0x4f, 0x7,0x36,0x6e, 0x7,0x36,0x6f, 0x5,0x5a,0x6b, + 0x7,0x46,0x4f, 0x7,0x65,0x2e, 0x5,0x5a,0x6c, 0x5,0x61,0x25, + 0x7,0x3e,0x6d, 0x5,0x67,0x43, 0x7,0x45,0x7a, 0x5,0x67,0x44, + 0xf,0x61,0x7d, 0x7,0x4d,0x27, 0x5,0x6b,0x60, 0x7,0x4d,0x26, + 0x5,0x6b,0x5e, 0x5,0x6b,0x5f, 0x4,0x63,0x25, 0x4,0x66,0x23, + 0x7,0x52,0x60, 0x4,0x6a,0x39, 0x4,0x68,0x58, 0x7,0x57,0x3c, + 0x7,0x57,0x3d, 0x5,0x75,0x53, 0x7,0x5b,0x34, 0x7,0x5b,0x35, + 0x5,0x75,0x55, 0x4,0x6a,0x38, 0x7,0x5b,0x33, 0x5,0x75,0x54, + 0x7,0x5e,0x43, 0x7,0x60,0x5e, 0x5,0x78,0x79, 0x7,0x60,0x5f, + 0x5,0x79,0x7c, 0x7,0x63,0x43, 0x5,0x7b,0x35, 0x5,0x7b,0x77, + 0x7,0x2c,0x39, 0x5,0x5a,0x6d, 0x7,0x3e,0x6e, 0x5,0x5a,0x6e, + 0x5,0x61,0x28, 0x5,0x61,0x2a, 0x5,0x61,0x2b, 0x5,0x61,0x29, + 0x5,0x61,0x27, 0x7,0x3e,0x70, 0x5,0x61,0x26, 0x7,0x3e,0x6f, + 0x5,0x61,0x2c, 0x4,0x5a,0x62, 0x7,0x45,0x7c, 0x7,0x4d,0x2c, + 0x5,0x67,0x47, 0x5,0x67,0x48, 0x5,0x67,0x46, 0x5,0x67,0x45, + 0x7,0x45,0x7b, 0x7,0x4d,0x2a, 0x5,0x6b,0x61, 0x5,0x6b,0x63, + 0x5,0x6b,0x62, 0x7,0x4d,0x2d, 0x7,0x4d,0x2e, 0x7,0x4d,0x29, + 0x7,0x52,0x62, 0x7,0x52,0x64, 0x7,0x52,0x63, 0x5,0x6f,0x5d, + 0x5,0x6f,0x5e, 0x7,0x4d,0x2b, 0x7,0x52,0x65, 0x5,0x6f,0x5c, + 0x7,0x52,0x61, 0x5,0x73,0x21, 0x5,0x72,0x7e, 0x7,0x57,0x3e, + 0x5,0x75,0x57, 0x7,0x5b,0x36, 0x5,0x75,0x58, 0x5,0x75,0x59, + 0x5,0x75,0x56, 0x4,0x6a,0x3a, 0x7,0x5e,0x44, 0x5,0x77,0x4b, + 0x4,0x6b,0x59, 0x7,0x5e,0x48, 0x4,0x6b,0x57, 0x4,0x6b,0x5a, + 0x7,0x5e,0x47, 0x7,0x5e,0x46, 0x7,0x5e,0x45, 0x5,0x78,0x7d, + 0x4,0x6c,0x63, 0x5,0x78,0x7b, 0x5,0x78,0x7a, 0x7,0x60,0x60, + 0x7,0x61,0x7e, 0x7,0x61,0x7d, 0x4,0x6d,0x49, 0x5,0x79,0x7d, + 0x5,0x7b,0x36, 0x5,0x7b,0x79, 0x5,0x7b,0x78, 0x7,0x65,0x6f, + 0x7,0x66,0x22, 0x4,0x4f,0x57, 0x7,0x36,0x70, 0x7,0x36,0x71, + 0x7,0x3e,0x72, 0x7,0x3e,0x71, 0x5,0x67,0x49, 0x7,0x45,0x7e, + 0x7,0x46,0x21, 0x7,0x45,0x7d, 0x5,0x6b,0x64, 0x5,0x6b,0x65, + 0x7,0x52,0x66, 0x5,0x6f,0x5f, 0x5,0x6f,0x60, 0x7,0x52,0x68, + 0x4,0x68,0x5b, 0x5,0x73,0x22, 0x7,0x57,0x3f, 0x7,0x57,0x40, + 0x5,0x73,0x23, 0x5,0x73,0x24, 0x7,0x5b,0x37, 0x5,0x77,0x4c, + 0x7,0x5e,0x49, 0x5,0x78,0x7c, 0xf,0x6b,0x7e, 0x7,0x60,0x61, + 0x5,0x79,0x7e, 0x5,0x7a,0x21, 0x7,0x63,0x46, 0x5,0x7a,0x5e, + 0x7,0x63,0x45, 0x7,0x64,0x3c, 0x4,0x6e,0x53, 0x5,0x7c,0x32, + 0xf,0x40,0x34, 0x4,0x55,0x64, 0x4,0x5a,0x65, 0x7,0x46,0x22, + 0x4,0x63,0x28, 0x7,0x4d,0x2f, 0x5,0x6d,0x57, 0x4,0x66,0x24, + 0x4,0x6a,0x3b, 0xf,0x69,0x37, 0x5,0x7a,0x23, 0x5,0x7a,0x22, + 0x7,0x62,0x21, 0x7,0x65,0x2f, 0x5,0x61,0x2e, 0x7,0x3e,0x73, + 0x7,0x46,0x25, 0x4,0x5f,0x47, 0x7,0x46,0x24, 0x7,0x4d,0x30, + 0x5,0x6b,0x66, 0x4,0x63,0x2a, 0x7,0x4d,0x31, 0x7,0x4d,0x34, + 0x7,0x4d,0x32, 0x7,0x4d,0x33, 0x7,0x4d,0x35, 0x7,0x4d,0x36, + 0x5,0x6b,0x67, 0x7,0x52,0x6b, 0x5,0x6f,0x63, 0x5,0x6f,0x62, + 0x4,0x66,0x28, 0x7,0x52,0x69, 0x4,0x66,0x2a, 0x7,0x52,0x6d, + 0x4,0x66,0x29, 0x7,0x52,0x6e, 0x7,0x52,0x6a, 0x4,0x48,0x78, + 0x7,0x52,0x6c, 0x7,0x57,0x46, 0x5,0x73,0x2a, 0x5,0x73,0x27, + 0x7,0x57,0x43, 0x7,0x57,0x42, 0x4,0x68,0x5e, 0x5,0x73,0x28, + 0x4,0x68,0x5f, 0x4,0x68,0x5d, 0x7,0x57,0x44, 0x5,0x73,0x25, + 0x5,0x73,0x2b, 0x7,0x57,0x45, 0x7,0x57,0x47, 0x5,0x73,0x29, + 0x7,0x57,0x41, 0x5,0x73,0x26, 0x7,0x5b,0x38, 0x4,0x6a,0x3e, + 0x5,0x75,0x5c, 0x5,0x75,0x5b, 0x5,0x75,0x5e, 0x7,0x5b,0x40, + 0x7,0x5b,0x3f, 0x5,0x75,0x5f, 0x7,0x5b,0x3a, 0x5,0x75,0x60, + 0x4,0x6a,0x3f, 0x7,0x5b,0x39, 0x5,0x75,0x5a, 0x7,0x5b,0x3b, + 0x7,0x5b,0x3d, 0x7,0x5b,0x3e, 0x7,0x5b,0x3c, 0x5,0x75,0x5d, + 0x5,0x77,0x4f, 0x5,0x77,0x4e, 0x4,0x6b,0x5e, 0x4,0x6b,0x62, + 0x4,0x6b,0x63, 0x4,0x6b,0x5f, 0x4,0x6b,0x60, 0x5,0x77,0x50, + 0x7,0x5e,0x4e, 0x7,0x5e,0x4c, 0x4,0x6b,0x5d, 0x7,0x5e,0x4a, + 0x7,0x5e,0x4b, 0x7,0x5e,0x4f, 0x4,0x6b,0x64, 0x4,0x6c,0x67, + 0x5,0x78,0x7e, 0x7,0x60,0x67, 0x4,0x6c,0x68, 0x7,0x60,0x65, + 0x5,0x79,0x21, 0x7,0x62,0x23, 0x4,0x6c,0x65, 0x7,0x60,0x63, + 0x7,0x60,0x66, 0x7,0x60,0x64, 0x7,0x60,0x62, 0x7,0x60,0x68, + 0x5,0x79,0x22, 0x4,0x6d,0x4e, 0x4,0x6d,0x4a, 0x7,0x62,0x25, + 0x5,0x7a,0x26, 0x4,0x6d,0x50, 0x4,0x6d,0x4d, 0x5,0x7a,0x24, + 0x7,0x62,0x27, 0x4,0x6d,0x4f, 0x7,0x62,0x24, 0x7,0x62,0x26, + 0x7,0x62,0x28, 0x7,0x62,0x29, 0x7,0x62,0x22, 0x5,0x7a,0x25, + 0x7,0x63,0x48, 0x5,0x7a,0x60, 0x7,0x63,0x47, 0x5,0x7a,0x62, + 0x5,0x7a,0x5f, 0x5,0x7a,0x61, 0x7,0x64,0x3e, 0x4,0x6e,0x32, + 0x7,0x64,0x3d, 0x5,0x7b,0x37, 0x5,0x7b,0x39, 0x5,0x7b,0x38, + 0x7,0x64,0x40, 0x7,0x64,0x41, 0x7,0x64,0x3f, 0x4,0x6e,0x46, + 0x7,0x65,0x32, 0x5,0x7b,0x5d, 0x7,0x65,0x31, 0x7,0x65,0x30, + 0x7,0x65,0x59, 0x7,0x65,0x71, 0x7,0x65,0x72, 0x5,0x7c,0x2a, + 0x7,0x65,0x70, 0x7,0x65,0x73, 0x5,0x7c,0x33, 0x7,0x66,0x24, + 0x7,0x66,0x23, 0x5,0x7c,0x3b, 0x7,0x66,0x32, 0x5,0x7c,0x3a, + 0x7,0x66,0x31, 0x7,0x66,0x3d, 0x7,0x66,0x3c, 0x5,0x7c,0x45, + 0x7,0x66,0x41, 0x7,0x66,0x48, 0x5,0x7c,0x4e, 0x5,0x7c,0x4d, + 0x5,0x6b,0x68, 0x7,0x4d,0x37, 0x4,0x63,0x2c, 0x7,0x52,0x70, + 0x7,0x52,0x6f, 0x7,0x4e,0x24, 0x5,0x6f,0x64, 0x7,0x57,0x48, + 0xf,0x67,0x3d, 0x7,0x5b,0x42, 0x7,0x5b,0x41, 0x7,0x5b,0x43, + 0x7,0x5b,0x44, 0x5,0x77,0x51, 0x5,0x7c,0x51, 0x7,0x36,0x72, + 0x7,0x3e,0x74, 0x7,0x46,0x26, 0x7,0x57,0x49, 0x5,0x6f,0x65, + 0x4,0x66,0x2b, 0x5,0x6f,0x67, 0x5,0x6f,0x66, 0x4,0x66,0x2c, + 0x7,0x52,0x73, 0x7,0x52,0x71, 0xf,0x67,0x3e, 0x7,0x52,0x72, + 0x5,0x73,0x2c, 0x5,0x73,0x2e, 0x7,0x57,0x4b, 0x5,0x73,0x2f, + 0x5,0x6b,0x6a, 0x5,0x73,0x2d, 0x7,0x54,0x2a, 0x7,0x57,0x4a, + 0x7,0x4d,0x39, 0x7,0x4d,0x38, 0x5,0x7b,0x5e, 0x7,0x61,0x29, + 0x5,0x7b,0x3a, 0x5,0x77,0x52, 0x7,0x64,0x42, 0xf,0x6d,0x2d, + 0x5,0x7c,0x42, 0xf,0x29,0x26, 0x5,0x73,0x30, 0x7,0x62,0x2b, + 0x7,0x62,0x2a, 0x5,0x7a,0x64, 0x5,0x7a,0x63, 0x7,0x63,0x4a, + 0x7,0x63,0x49, 0x5,0x7b,0x3b, 0x4,0x6e,0x47, 0x7,0x66,0x25, + 0x4,0x6e,0x56, 0x7,0x66,0x4c, 0x6,0x29,0x36, 0x6,0x21,0x31, + 0x6,0x21,0x21, 0x6,0x25,0x66, 0x6,0x25,0x72, 0x4,0x25,0x3d, + 0x6,0x2e,0x61, 0xf,0x2d,0x68, 0x6,0x3d,0x35, 0x6,0x50,0x5b, + 0x4,0x3c,0x30, 0x6,0x5a,0x72, 0xf,0x59,0x4d, 0x6,0x23,0x52, + 0x3,0x24,0x52, 0x3,0x27,0x53, 0xf,0x67,0x40, 0x3,0x27,0x54, + 0x6,0x3d,0x3c, 0x7,0x4d,0x3e, 0x6,0x21,0x50, 0x3,0x22,0x7b, + 0x6,0x23,0x59, 0x3,0x21,0x4f, 0x6,0x35,0x44, 0x4,0x21,0x3f, + 0x6,0x22,0x3c, 0x3,0x24,0x41, 0x7,0x36,0x7a, 0x5,0x21,0x29, + 0x6,0x21,0x38, 0xf,0x23,0x37, 0x6,0x29,0x63, 0x6,0x2e,0x76, + 0x6,0x46,0x67, 0x3,0x40,0x43, 0xf,0x22,0x29, 0x6,0x2f,0x25, + 0x6,0x35,0x58, 0x4,0x36,0x4c, 0x4,0x21,0x2f, 0x6,0x22,0x46, + 0x3,0x22,0x25, 0x6,0x22,0x49, 0x3,0x23,0x29, 0x6,0x2f,0x38, + 0x6,0x46,0x74, 0x6,0x2a,0x23, 0x6,0x2f,0x3d, 0x6,0x3d,0x59, + 0x6,0x3d,0x5a, 0x3,0x3a,0x26, 0xf,0x21,0x33, 0x3,0x24,0x29, + 0x6,0x21,0x61, 0x6,0x26,0x43, 0x5,0x31,0x31, 0x6,0x22,0x5b, + 0x5,0x21,0x60, 0x3,0x23,0x3c, 0x4,0x23,0x5c, 0x6,0x26,0x4e, + 0x4,0x23,0x5b, 0x6,0x2a,0x3c, 0x3,0x30,0x23, 0x6,0x35,0x7e, + 0x4,0x30,0x76, 0x6,0x3d,0x7c, 0x6,0x47,0x2a, 0x6,0x47,0x2c, + 0x6,0x47,0x30, 0x6,0x47,0x31, 0x6,0x47,0x33, 0x4,0x3c,0x50, + 0x6,0x5b,0x5b, 0x6,0x51,0x36, 0x6,0x5b,0x59, 0x7,0x21,0x60, + 0x7,0x2c,0x65, 0x3,0x21,0x7c, 0x6,0x24,0x33, 0x6,0x36,0x35, + 0x6,0x3e,0x2c, 0x6,0x3e,0x2b, 0x3,0x34,0x70, 0x4,0x36,0x76, + 0x6,0x51,0x4a, 0x7,0x21,0x76, 0x7,0x46,0x3e, 0xf,0x23,0x5b, + 0x6,0x51,0x57, 0x5,0x23,0x62, 0x6,0x24,0x3b, 0x6,0x51,0x5e, + 0x6,0x47,0x56, 0x6,0x22,0x67, 0xf,0x2a,0x2b, 0x6,0x36,0x4c, + 0x6,0x36,0x4d, 0xf,0x2e,0x6d, 0x6,0x3e,0x54, 0x6,0x3e,0x50, + 0x6,0x47,0x61, 0x6,0x51,0x69, 0xf,0x47,0x46, 0x3,0x5a,0x33, + 0x7,0x46,0x51, 0x6,0x24,0x48, 0x4,0x31,0x30, 0xf,0x41,0x2b, + 0x6,0x5c,0x22, 0x3,0x5a,0x36, 0x7,0x60,0x6d, 0x6,0x27,0x21, + 0x6,0x36,0x67, 0x6,0x24,0x4b, 0x4,0x21,0x34, 0x5,0x28,0x73, + 0x6,0x47,0x7b, 0x4,0x21,0x35, 0xf,0x26,0x62, 0x3,0x2c,0x40, + 0x6,0x30,0x4e, 0x6,0x48,0x2b, 0x6,0x48,0x35, 0x3,0x40,0x7e, + 0x6,0x52,0x33, 0x6,0x5c,0x3d, 0x6,0x27,0x36, 0x6,0x5c,0x49, + 0xf,0x21,0x5f, 0x6,0x48,0x37, 0x6,0x37,0x2c, 0x6,0x48,0x3c, + 0x7,0x2d,0x53, 0x7,0x2d,0x55, 0x7,0x60,0x6e, 0x5,0x29,0x27, + 0x6,0x3f,0x46, 0x6,0x3f,0x45, 0x3,0x35,0x5f, 0x6,0x52,0x40, + 0x5,0x45,0x5d, 0x6,0x21,0x74, 0x6,0x27,0x4a, 0x6,0x2b,0x2f, + 0x6,0x30,0x74, 0xf,0x2a,0x5d, 0x6,0x2b,0x39, 0x7,0x2d,0x63, + 0x5,0x73,0x40, 0x3,0x2c,0x51, 0x6,0x3f,0x5e, 0x5,0x2d,0x48, + 0x3,0x35,0x65, 0x6,0x27,0x5f, 0xf,0x24,0x33, 0x5,0x24,0x38, + 0x6,0x31,0x36, 0x6,0x31,0x30, 0xf,0x2a,0x67, 0x4,0x29,0x4a, + 0x6,0x48,0x7c, 0x6,0x48,0x78, 0x3,0x46,0x70, 0x6,0x52,0x6c, + 0x6,0x52,0x66, 0x6,0x5d,0x26, 0x6,0x5d,0x24, 0x4,0x43,0x51, + 0x7,0x2d,0x69, 0x7,0x2d,0x79, 0x7,0x22,0x7b, 0x3,0x54,0x60, + 0x4,0x5b,0x2c, 0x7,0x47,0x28, 0x3,0x26,0x27, 0x6,0x40,0x23, + 0x5,0x22,0x6e, 0x6,0x2b,0x63, 0x6,0x2b,0x60, 0x6,0x31,0x4f, + 0xf,0x2b,0x2b, 0x6,0x37,0x71, 0x3,0x36,0x28, 0x6,0x40,0x36, + 0x6,0x40,0x2b, 0x6,0x49,0x4a, 0x6,0x49,0x30, 0xf,0x41,0x5f, + 0x7,0x23,0x30, 0x6,0x5d,0x38, 0x5,0x46,0x2c, 0x7,0x23,0x2d, + 0xf,0x4f,0x25, 0x4,0x4a,0x27, 0x7,0x38,0x39, 0xf,0x5e,0x70, + 0x4,0x2d,0x46, 0x6,0x49,0x57, 0xf,0x5a,0x36, 0x3,0x36,0x40, + 0x6,0x38,0x36, 0xf,0x41,0x72, 0x6,0x53,0x3c, 0x5,0x46,0x41, + 0xf,0x2b,0x38, 0x6,0x31,0x6d, 0x6,0x40,0x57, 0x6,0x49,0x78, + 0x6,0x5d,0x5b, 0x6,0x2c,0x23, 0x5,0x26,0x4a, 0x4,0x32,0x3e, + 0x6,0x40,0x58, 0x5,0x3f,0x66, 0x4,0x24,0x47, 0x6,0x28,0x2e, + 0xf,0x24,0x51, 0x4,0x26,0x68, 0x3,0x2d,0x35, 0x6,0x38,0x4a, + 0x3,0x31,0x5c, 0x4,0x2d,0x5c, 0x6,0x38,0x50, 0x5,0x32,0x7e, + 0x3,0x3c,0x3a, 0x6,0x53,0x5e, 0x5,0x3f,0x71, 0x3,0x41,0x6e, + 0x6,0x5d,0x68, 0x7,0x23,0x72, 0xf,0x54,0x74, 0x7,0x2e,0x6a, + 0x4,0x5f,0x76, 0x7,0x58,0x23, 0x6,0x25,0x23, 0x6,0x4a,0x3f, + 0x7,0x23,0x78, 0x7,0x5e,0x72, 0xf,0x48,0x79, 0x6,0x53,0x77, + 0x4,0x2d,0x65, 0xf,0x35,0x74, 0x6,0x4a,0x4d, 0x6,0x2c,0x42, + 0xf,0x48,0x7b, 0x6,0x25,0x2e, 0xf,0x24,0x5d, 0x6,0x2c,0x5b, + 0x6,0x2c,0x51, 0x3,0x2d,0x52, 0x6,0x32,0x39, 0x6,0x32,0x42, + 0x4,0x2a,0x25, 0x4,0x2d,0x70, 0x6,0x39,0x2d, 0x6,0x38,0x74, + 0x6,0x39,0x21, 0xf,0x30,0x5b, 0x3,0x36,0x75, 0x6,0x4a,0x65, + 0x6,0x4a,0x63, 0x4,0x3e,0x33, 0x6,0x54,0x49, 0x6,0x54,0x4f, + 0xf,0x42,0x74, 0x6,0x5e,0x3e, 0x7,0x24,0x4f, 0x7,0x24,0x58, + 0xf,0x4f,0x69, 0x7,0x2f,0x42, 0xf,0x55,0x56, 0x4,0x56,0x5d, + 0x7,0x4e,0x28, 0x7,0x53,0x60, 0x7,0x53,0x58, 0x6,0x2c,0x60, + 0x6,0x2c,0x5d, 0x6,0x32,0x48, 0x4,0x38,0x68, 0xf,0x43,0x2f, + 0x6,0x54,0x59, 0xf,0x50,0x3d, 0xf,0x55,0x58, 0x5,0x7b,0x7b, + 0x3,0x55,0x45, 0x6,0x41,0x61, 0x6,0x41,0x63, 0x6,0x41,0x6a, + 0x6,0x5e,0x5e, 0x6,0x32,0x62, 0x6,0x4b,0x42, 0x7,0x47,0x75, + 0x6,0x22,0x26, 0xf,0x24,0x78, 0x6,0x2d,0x24, 0xf,0x2c,0x39, + 0xf,0x31,0x28, 0x6,0x4b,0x47, 0xf,0x43,0x64, 0x4,0x44,0x6e, + 0x7,0x40,0x63, 0xf,0x63,0x24, 0x6,0x42,0x21, 0x3,0x3d,0x3f, + 0x6,0x32,0x79, 0x4,0x2a,0x44, 0x5,0x33,0x65, 0x6,0x4b,0x56, + 0x4,0x3e,0x6c, 0x6,0x42,0x32, 0xf,0x4a,0x2f, 0x7,0x53,0x7b, + 0x6,0x2d,0x3a, 0x5,0x33,0x71, 0xf,0x56,0x3c, 0x6,0x2d,0x45, + 0x6,0x2d,0x3d, 0x6,0x33,0x3d, 0x6,0x33,0x31, 0x5,0x2f,0x26, + 0xf,0x2c,0x57, 0x6,0x3a,0x2d, 0x6,0x3a,0x2e, 0x6,0x42,0x48, + 0x6,0x4b,0x7a, 0xf,0x50,0x5f, 0x7,0x30,0x4a, 0x6,0x25,0x3f, + 0x6,0x2d,0x46, 0x3,0x43,0x33, 0x6,0x55,0x6b, 0x7,0x25,0x7b, + 0x7,0x39,0x6d, 0xf,0x28,0x3c, 0x6,0x33,0x4a, 0xf,0x3d,0x60, + 0x4,0x4b,0x60, 0x7,0x26,0x27, 0x6,0x3a,0x43, 0x6,0x42,0x67, + 0x4,0x45,0x5f, 0x4,0x52,0x21, 0x7,0x30,0x66, 0x6,0x5f,0x75, + 0x7,0x26,0x3e, 0x7,0x26,0x3c, 0x7,0x30,0x73, 0xf,0x4a,0x7b, + 0x6,0x60,0x23, 0xf,0x51,0x23, 0x7,0x26,0x4d, 0x7,0x41,0x3c, + 0x5,0x6c,0x7d, 0x7,0x31,0x2d, 0x7,0x3a,0x33, 0x4,0x5c,0x59, + 0x7,0x41,0x44, 0x3,0x2e,0x56, 0x6,0x33,0x66, 0x3,0x48,0x6a, + 0xf,0x51,0x37, 0x7,0x26,0x6a, 0x7,0x26,0x69, 0x4,0x64,0x26, + 0x7,0x62,0x4d, 0x6,0x4c,0x72, 0x7,0x3a,0x46, 0xf,0x3e,0x32, + 0x7,0x3a,0x49, 0x7,0x48,0x6d, 0x7,0x5f,0x3c, 0x6,0x4d,0x23, + 0xf,0x57,0x27, 0x4,0x2b,0x26, 0x7,0x27,0x28, 0xf,0x57,0x28, + 0x6,0x60,0x5d, 0x5,0x48,0x74, 0xf,0x5c,0x2d, 0x6,0x28,0x7b, + 0x4,0x27,0x68, 0x6,0x2d,0x69, 0x3,0x33,0x50, 0x5,0x3b,0x50, + 0x6,0x4d,0x48, 0xf,0x44,0x68, 0xf,0x4b,0x57, 0xf,0x4b,0x56, + 0x4,0x4c,0x56, 0x4,0x58,0x2d, 0x4,0x34,0x57, 0x6,0x4d,0x5e, + 0x3,0x44,0x25, 0x6,0x61,0x25, 0x3,0x27,0x2a, 0x6,0x25,0x52, + 0x6,0x29,0x27, 0xf,0x28,0x5c, 0x6,0x29,0x28, 0x6,0x2e,0x22, + 0x6,0x2e,0x23, 0x6,0x34,0x44, 0x6,0x2e,0x24, 0x6,0x3b,0x52, + 0xf,0x32,0x3a, 0x4,0x34,0x73, 0x6,0x44,0x2b, 0x4,0x34,0x74, + 0x6,0x43,0x76, 0x6,0x44,0x3b, 0x4,0x3a,0x66, 0x6,0x44,0x3e, + 0x6,0x44,0x3c, 0x6,0x44,0x3d, 0x6,0x4e,0x3b, 0x6,0x61,0x3e, + 0x6,0x61,0x4f, 0xf,0x51,0x64, 0x4,0x4c,0x79, 0x7,0x27,0x61, + 0x7,0x27,0x6d, 0x7,0x32,0x44, 0xf,0x57,0x47, 0x7,0x3a,0x6f, + 0xf,0x60,0x5d, 0x7,0x42,0x3c, 0x7,0x54,0x5e, 0x4,0x67,0x2b, + 0x6,0x34,0x47, 0x4,0x40,0x4f, 0x7,0x3b,0x38, 0x3,0x5b,0x26, + 0x6,0x3b,0x71, 0x4,0x3a,0x75, 0x6,0x4e,0x46, 0x4,0x46,0x7c, + 0x4,0x4d,0x33, 0xf,0x52,0x24, 0x7,0x28,0x2e, 0xf,0x51,0x7d, + 0x7,0x42,0x60, 0x7,0x42,0x5f, 0x3,0x5b,0x2d, 0x4,0x64,0x3f, + 0x4,0x53,0x4c, 0x6,0x25,0x53, 0x5,0x30,0x3e, 0x6,0x58,0x2e, + 0x6,0x58,0x2c, 0xf,0x45,0x3d, 0x7,0x3b,0x61, 0xf,0x38,0x4a, + 0x5,0x7a,0x38, 0x6,0x3c,0x2d, 0x4,0x35,0x45, 0xf,0x3f,0x3b, + 0x6,0x62,0x47, 0x7,0x33,0x4f, 0x7,0x59,0x41, 0x6,0x29,0x2a, + 0x6,0x58,0x50, 0x6,0x58,0x5c, 0x3,0x60,0x7c, 0x6,0x3c,0x3b, + 0x7,0x33,0x79, 0x7,0x33,0x73, 0xf,0x3f,0x53, 0x3,0x44,0x6d, + 0x7,0x29,0x44, 0x6,0x34,0x5d, 0x4,0x30,0x2c, 0x7,0x34,0x31, + 0x4,0x54,0x37, 0x7,0x3c,0x61, 0x6,0x25,0x5b, 0x4,0x35,0x72, + 0x6,0x59,0x47, 0x6,0x59,0x4a, 0x7,0x3c,0x6b, 0xf,0x45,0x73, + 0x6,0x63,0x53, 0x6,0x63,0x4f, 0x4,0x54,0x4a, 0xf,0x66,0x5e, + 0x7,0x50,0x6b, 0xf,0x6c,0x3f, 0x6,0x63,0x58, 0x7,0x34,0x7a, + 0x7,0x34,0x71, 0xf,0x61,0x4a, 0x6,0x50,0x22, 0x6,0x63,0x6e, + 0x7,0x35,0x35, 0x3,0x56,0x78, 0x5,0x5f,0x5e, 0x7,0x3d,0x50, + 0xf,0x58,0x78, 0x7,0x4b,0x5f, 0x4,0x65,0x2a, 0x7,0x4b,0x6b, + 0x5,0x3d,0x47, 0x5,0x44,0x35, 0x6,0x5a,0x33, 0x6,0x64,0x30, + 0x4,0x59,0x76, 0x6,0x64,0x3a, 0x6,0x3c,0x77, 0x6,0x5a,0x3d, + 0x4,0x55,0x23, 0x4,0x5e,0x60, 0x6,0x64,0x50, 0x7,0x3e,0x29, + 0x7,0x2b,0x55, 0xf,0x59,0x32, 0x7,0x51,0x7a, 0x7,0x5a,0x60, + 0x4,0x5a,0x59, 0x7,0x45,0x65, 0x4,0x5f,0x37, 0x4,0x62,0x6e, + 0x7,0x52,0x45, 0x5,0x75,0x36, 0x5,0x75,0x35, 0xf,0x6c,0x77, + 0x7,0x3e,0x5c, 0x6,0x46,0x3e, 0x4,0x68,0x4f, 0x6,0x5a,0x60, + 0x4,0x28,0x34, 0x3,0x5c,0x2f, 0x5,0x53,0x51, 0x7,0x4d,0x28, + 0x4,0x48,0x77, 0x7,0x5e,0x4d, +}; + +static const Summary16 cns11643_inv_uni2indx_page00[16] = { + /* 0x0000 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0080 }, { 1, 0x0083 }, + { 4, 0x0000 }, { 4, 0x0080 }, { 5, 0x0000 }, { 5, 0x0080 }, +}; +static const Summary16 cns11643_inv_uni2indx_page02[29] = { + /* 0x0200 */ + { 6, 0x0000 }, { 6, 0x0000 }, { 6, 0x0000 }, { 6, 0x0000 }, + { 6, 0x0000 }, { 6, 0x0000 }, { 6, 0x0000 }, { 6, 0x0000 }, + { 6, 0x0000 }, { 6, 0x0000 }, { 6, 0x0000 }, { 6, 0x0000 }, + { 6, 0x0e80 }, { 10, 0x0200 }, { 11, 0x0000 }, { 11, 0x0000 }, + /* 0x0300 */ + { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0000 }, { 11, 0xfffe }, { 26, 0x03fb }, { 35, 0xfffe }, + { 50, 0x03fb }, +}; +static const Summary16 cns11643_inv_uni2indx_page20[44] = { + /* 0x2000 */ + { 59, 0x0000 }, { 59, 0x3358 }, { 66, 0x0060 }, { 68, 0x4824 }, + { 72, 0x0000 }, { 72, 0x0000 }, { 72, 0x0000 }, { 72, 0x0000 }, + { 72, 0x0000 }, { 72, 0x0000 }, { 72, 0x1000 }, { 73, 0x0000 }, + { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, + /* 0x2100 */ + { 73, 0x0228 }, { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, + { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x03ff }, { 86, 0x03ff }, + { 96, 0x0000 }, { 96, 0x03cf }, { 104, 0x0000 }, { 104, 0x0000 }, + { 104, 0x0000 }, { 104, 0x0000 }, { 104, 0x0000 }, { 104, 0x0000 }, + /* 0x2200 */ + { 104, 0x0000 }, { 104, 0xc420 }, { 108, 0x4e01 }, { 113, 0x1030 }, + { 116, 0x0000 }, { 116, 0x0004 }, { 117, 0x00c3 }, { 121, 0x0000 }, + { 121, 0x0000 }, { 121, 0x0000 }, { 121, 0x0020 }, { 122, 0x8000 }, +}; +static const Summary16 cns11643_inv_uni2indx_page24[37] = { + /* 0x2400 */ + { 123, 0xffff }, { 139, 0xffff }, { 155, 0x0002 }, { 156, 0x0000 }, + { 156, 0x0000 }, { 156, 0x0000 }, { 156, 0x03ff }, { 166, 0x3ff0 }, + { 176, 0x0000 }, { 176, 0x0000 }, { 176, 0x0000 }, { 176, 0x0000 }, + { 176, 0x0000 }, { 176, 0x0000 }, { 176, 0x0000 }, { 176, 0x0000 }, + /* 0x2500 */ + { 176, 0x1005 }, { 179, 0x1111 }, { 183, 0x1010 }, { 185, 0x1010 }, + { 187, 0x0000 }, { 187, 0x4001 }, { 189, 0xe402 }, { 194, 0x000f }, + { 198, 0xfffe }, { 213, 0x0030 }, { 215, 0x0003 }, { 217, 0x300c }, + { 221, 0xc8c0 }, { 226, 0x0000 }, { 226, 0x003c }, { 230, 0x0000 }, + /* 0x2600 */ + { 230, 0x0260 }, { 233, 0x0000 }, { 233, 0x0000 }, { 233, 0x0000 }, + { 233, 0x0007 }, +}; +static const Summary16 cns11643_inv_uni2indx_page30[1787] = { + /* 0x3000 */ + { 236, 0xff0f }, { 248, 0x6037 }, { 255, 0x03fe }, { 264, 0x0000 }, + { 264, 0x0000 }, { 264, 0x0000 }, { 264, 0x0000 }, { 264, 0x0000 }, + { 264, 0x0000 }, { 264, 0x0000 }, { 264, 0x0000 }, { 264, 0x0000 }, + { 264, 0x0000 }, { 264, 0x0000 }, { 264, 0x0000 }, { 264, 0x0800 }, + /* 0x3100 */ + { 265, 0xffe0 }, { 276, 0xffff }, { 292, 0x03ff }, { 302, 0x0000 }, + { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, + { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, + { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, + /* 0x3200 */ + { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, + { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, + { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0008 }, { 303, 0x0000 }, + { 303, 0x0000 }, { 303, 0x0000 }, { 303, 0x0000 }, { 303, 0x0000 }, + /* 0x3300 */ + { 303, 0x0000 }, { 303, 0x0000 }, { 303, 0x0000 }, { 303, 0x0000 }, + { 303, 0x0000 }, { 303, 0x0000 }, { 303, 0x0000 }, { 303, 0x0000 }, + { 303, 0xc000 }, { 305, 0x7000 }, { 308, 0x0002 }, { 309, 0x0000 }, + { 309, 0x4010 }, { 311, 0x0026 }, { 314, 0x0000 }, { 314, 0x0000 }, + /* 0x3400 */ + { 314, 0x1073 }, { 320, 0x1040 }, { 322, 0x7b12 }, { 330, 0x5f5f }, + { 342, 0xfe3e }, { 354, 0xff8b }, { 366, 0xc0f8 }, { 373, 0xfefb }, + { 387, 0x7fff }, { 402, 0xfefe }, { 416, 0xbff3 }, { 429, 0xfffd }, + { 444, 0xdfbc }, { 456, 0xfdfb }, { 470, 0xf39f }, { 482, 0x7ffe }, + /* 0x3500 */ + { 496, 0xfcff }, { 510, 0x77af }, { 522, 0xf7ff }, { 537, 0xffff }, + { 553, 0xffff }, { 569, 0xdff7 }, { 583, 0xfeff }, { 598, 0x1fef }, + { 610, 0x81ff }, { 620, 0x81ff }, { 630, 0x0fff }, { 642, 0xfff0 }, + { 654, 0x3fff }, { 668, 0x1ff9 }, { 679, 0x3ffc }, { 691, 0xf87f }, + /* 0x3600 */ + { 703, 0x3fe7 }, { 715, 0xfe7b }, { 728, 0xbfff }, { 743, 0x8fdf }, + { 755, 0xefbf }, { 769, 0x7e2f }, { 780, 0xffbf }, { 795, 0x5fff }, + { 809, 0xfebf }, { 823, 0xf5fd }, { 836, 0x7fff }, { 851, 0xffff }, + { 867, 0xe63e }, { 877, 0x7fff }, { 892, 0xffe6 }, { 905, 0x7fff }, + /* 0x3700 */ + { 920, 0xfffe }, { 935, 0x7fef }, { 949, 0xdfff }, { 964, 0xffff }, + { 980, 0xf5bf }, { 993, 0xfbff }, { 1008, 0xfefd }, { 1022, 0xfff7 }, + { 1037, 0x9fff }, { 1051, 0x9fff }, { 1065, 0xbffe }, { 1079, 0xfeff }, + { 1094, 0xffbb }, { 1108, 0xffdf }, { 1123, 0xbfe5 }, { 1135, 0xff7f }, + /* 0x3800 */ + { 1150, 0xfff7 }, { 1165, 0x3fff }, { 1179, 0xe7e7 }, { 1191, 0xfff6 }, + { 1205, 0xdfff }, { 1220, 0xffff }, { 1236, 0xefed }, { 1249, 0xffff }, + { 1265, 0xff7f }, { 1280, 0xffff }, { 1296, 0xd7eb }, { 1308, 0x7d7d }, + { 1320, 0xfbff }, { 1335, 0xff1f }, { 1348, 0xb87d }, { 1358, 0xfce7 }, + /* 0x3900 */ + { 1370, 0xfffe }, { 1385, 0xfeff }, { 1400, 0xd7ff }, { 1414, 0xcfff }, + { 1428, 0xffff }, { 1444, 0xfc7f }, { 1457, 0xfbff }, { 1472, 0xf7ff }, + { 1487, 0xfeff }, { 1502, 0xfdff }, { 1517, 0xffff }, { 1533, 0xfff5 }, + { 1547, 0x7fff }, { 1562, 0x47fc }, { 1572, 0xfffe }, { 1587, 0xfffe }, + /* 0x3a00 */ + { 1602, 0xffff }, { 1618, 0xfeff }, { 1633, 0xe7ff }, { 1647, 0xffff }, + { 1663, 0x7ff9 }, { 1676, 0x7ffd }, { 1690, 0xbfff }, { 1705, 0xfeff }, + { 1720, 0xfbb7 }, { 1733, 0xf46e }, { 1743, 0xfb7f }, { 1757, 0xdff3 }, + { 1770, 0xec3f }, { 1781, 0xffbf }, { 1796, 0xdef3 }, { 1808, 0x3fff }, + /* 0x3b00 */ + { 1822, 0xfffe }, { 1837, 0x7fbd }, { 1850, 0xfeef }, { 1864, 0x9b7f }, + { 1876, 0x1f9e }, { 1886, 0xff3e }, { 1899, 0xff07 }, { 1910, 0xff07 }, + { 1921, 0xf9ff }, { 1935, 0xffff }, { 1951, 0xfffa }, { 1965, 0x97ff }, + { 1978, 0xffff }, { 1994, 0xfff9 }, { 2008, 0xfc7f }, { 2021, 0xcfff }, + /* 0x3c00 */ + { 2035, 0xffff }, { 2051, 0xeff7 }, { 2065, 0xffff }, { 2081, 0xfeff }, + { 2096, 0xffff }, { 2112, 0xdff4 }, { 2124, 0xbdff }, { 2138, 0xff7f }, + { 2153, 0xffff }, { 2169, 0xfffe }, { 2184, 0xbdff }, { 2198, 0x7fff }, + { 2213, 0xfdff }, { 2228, 0xffcf }, { 2242, 0x7ff0 }, { 2253, 0xfff8 }, + /* 0x3d00 */ + { 2266, 0xc7ff }, { 2279, 0x7fff }, { 2294, 0xffe3 }, { 2307, 0xf9ff }, + { 2321, 0xfc7f }, { 2334, 0xe3ff }, { 2347, 0xffff }, { 2363, 0xefff }, + { 2378, 0xf1f3 }, { 2389, 0xddfe }, { 2402, 0xfffb }, { 2417, 0xde3d }, + { 2428, 0xefff }, { 2443, 0x8fff }, { 2456, 0xf97f }, { 2469, 0xdbf9 }, + /* 0x3e00 */ + { 2481, 0xff3f }, { 2495, 0xffff }, { 2511, 0xffff }, { 2527, 0x7fef }, + { 2541, 0xfeff }, { 2556, 0xffff }, { 2572, 0xf8ff }, { 2585, 0xfffe }, + { 2600, 0xdfbf }, { 2614, 0xfdff }, { 2629, 0x7ffb }, { 2643, 0xa7bf }, + { 2655, 0x7f9f }, { 2668, 0xe6fe }, { 2680, 0xf98f }, { 2691, 0xffe7 }, + /* 0x3f00 */ + { 2705, 0xfef6 }, { 2718, 0xffff }, { 2734, 0xffff }, { 2750, 0xffff }, + { 2766, 0x7fdf }, { 2780, 0xffef }, { 2795, 0xffff }, { 2811, 0xefb7 }, + { 2824, 0xffff }, { 2840, 0xffff }, { 2856, 0xffff }, { 2872, 0xffc1 }, + { 2883, 0xfffe }, { 2898, 0xffee }, { 2912, 0xfffe }, { 2927, 0xffff }, + /* 0x4000 */ + { 2943, 0xefff }, { 2958, 0xdfff }, { 2973, 0xff9f }, { 2987, 0xffff }, + { 3003, 0xfffe }, { 3018, 0xffbf }, { 3033, 0xfbfd }, { 3047, 0xffff }, + { 3063, 0xf7ff }, { 3078, 0xffff }, { 3094, 0xfeff }, { 3109, 0xffdf }, + { 3124, 0xff87 }, { 3136, 0x7ffe }, { 3150, 0x7eff }, { 3164, 0xefff }, + /* 0x4100 */ + { 3179, 0xfbff }, { 3194, 0xbf3f }, { 3207, 0xfff7 }, { 3222, 0xfdcf }, + { 3235, 0xfdff }, { 3250, 0x7fff }, { 3265, 0xf3ff }, { 3279, 0xffff }, + { 3295, 0xef3f }, { 3308, 0xffff }, { 3324, 0xbfff }, { 3339, 0xffef }, + { 3354, 0xfbef }, { 3368, 0xffff }, { 3384, 0xffff }, { 3400, 0x7fe7 }, + /* 0x4200 */ + { 3413, 0xffff }, { 3429, 0xffff }, { 3445, 0xfcff }, { 3459, 0xffff }, + { 3475, 0xff7f }, { 3490, 0xffff }, { 3506, 0xffef }, { 3521, 0xffff }, + { 3537, 0xefff }, { 3552, 0xffff }, { 3568, 0xfffb }, { 3583, 0xffff }, + { 3599, 0xff1f }, { 3612, 0xdfff }, { 3627, 0xffff }, { 3643, 0xffff }, + /* 0x4300 */ + { 3659, 0xf7ff }, { 3674, 0xffff }, { 3690, 0xffff }, { 3706, 0x003f }, + { 3712, 0xfffc }, { 3726, 0xffff }, { 3742, 0xfffe }, { 3757, 0xffff }, + { 3773, 0xffff }, { 3789, 0xb7ff }, { 3803, 0xefdf }, { 3817, 0xffff }, + { 3833, 0xffff }, { 3849, 0xdfff }, { 3864, 0x9fff }, { 3878, 0xffff }, + /* 0x4400 */ + { 3894, 0xffbf }, { 3909, 0xffff }, { 3925, 0xfbff }, { 3940, 0xffff }, + { 3956, 0xffff }, { 3972, 0xffbf }, { 3987, 0xbdff }, { 4001, 0xbe7f }, + { 4014, 0xff7f }, { 4029, 0xfdfd }, { 4043, 0x3fff }, { 4057, 0x3fff }, + { 4071, 0xfffe }, { 4086, 0xff8f }, { 4099, 0xe4ff }, { 4111, 0xf7ff }, + /* 0x4500 */ + { 4126, 0xffff }, { 4142, 0xffff }, { 4158, 0xffff }, { 4174, 0xffff }, + { 4190, 0xfffb }, { 4205, 0xfffe }, { 4220, 0xfff7 }, { 4235, 0xffbf }, + { 4250, 0xffff }, { 4266, 0xffff }, { 4282, 0xefff }, { 4297, 0xbfff }, + { 4312, 0xffff }, { 4328, 0xffbf }, { 4343, 0xdfff }, { 4358, 0xf7f7 }, + /* 0x4600 */ + { 4372, 0xffff }, { 4388, 0xb7ff }, { 4402, 0xffff }, { 4418, 0xfffb }, + { 4433, 0xc3ff }, { 4445, 0xfff7 }, { 4460, 0xf7ff }, { 4475, 0xf7bf }, + { 4489, 0xffff }, { 4505, 0xffdf }, { 4520, 0xefef }, { 4534, 0xffff }, + { 4550, 0xffff }, { 4566, 0xfff7 }, { 4581, 0xffff }, { 4597, 0xffff }, + /* 0x4700 */ + { 4613, 0xffff }, { 4629, 0xffff }, { 4645, 0xfc07 }, { 4654, 0xfff7 }, + { 4669, 0xffff }, { 4685, 0xf5ff }, { 4699, 0xffff }, { 4715, 0xefff }, + { 4730, 0x0fff }, { 4742, 0xfffe }, { 4757, 0xffff }, { 4773, 0xfffb }, + { 4788, 0xffff }, { 4804, 0xffff }, { 4820, 0xffff }, { 4836, 0xfffb }, + /* 0x4800 */ + { 4851, 0xefff }, { 4866, 0xffbf }, { 4881, 0xffff }, { 4897, 0xfbff }, + { 4912, 0xffff }, { 4928, 0xffff }, { 4944, 0xffff }, { 4960, 0xf7fd }, + { 4974, 0x7ff8 }, { 4986, 0xfe7f }, { 5000, 0xfff7 }, { 5015, 0xfbff }, + { 5030, 0xfdff }, { 5045, 0xfffb }, { 5060, 0xffbf }, { 5075, 0xfff7 }, + /* 0x4900 */ + { 5090, 0xfffe }, { 5105, 0xffff }, { 5121, 0xfdf7 }, { 5135, 0xfffb }, + { 5150, 0xff7f }, { 5165, 0xefff }, { 5180, 0xffff }, { 5196, 0x01ff }, + { 5205, 0xff80 }, { 5214, 0xf7ff }, { 5229, 0xfdff }, { 5244, 0x3e3e }, + { 5254, 0x7efe }, { 5267, 0xffff }, { 5283, 0xd5ff }, { 5296, 0xffff }, + /* 0x4a00 */ + { 5312, 0xffff }, { 5328, 0xfbff }, { 5343, 0xffff }, { 5359, 0xffff }, + { 5375, 0xbfef }, { 5389, 0xffff }, { 5405, 0xffff }, { 5421, 0xffff }, + { 5437, 0xffff }, { 5453, 0x7fff }, { 5468, 0xfbff }, { 5483, 0xffff }, + { 5499, 0xffff }, { 5515, 0xffff }, { 5531, 0xffff }, { 5547, 0xffff }, + /* 0x4b00 */ + { 5563, 0xffff }, { 5579, 0xffff }, { 5595, 0xffff }, { 5611, 0xffff }, + { 5627, 0x7fff }, { 5642, 0xefff }, { 5657, 0xfbff }, { 5672, 0xffff }, + { 5688, 0xffff }, { 5704, 0xffff }, { 5720, 0xffff }, { 5736, 0xffff }, + { 5752, 0xffc7 }, { 5765, 0xffff }, { 5781, 0xfdff }, { 5796, 0xf7ff }, + /* 0x4c00 */ + { 5811, 0xff7f }, { 5826, 0xffff }, { 5842, 0xbfff }, { 5857, 0xffb7 }, + { 5871, 0xffff }, { 5887, 0xffff }, { 5903, 0xfbff }, { 5918, 0xffef }, + { 5933, 0xff7f }, { 5948, 0x1eff }, { 5960, 0xffe0 }, { 5971, 0xffbf }, + { 5986, 0xffff }, { 6002, 0xffff }, { 6018, 0xffff }, { 6034, 0xfdff }, + /* 0x4d00 */ + { 6049, 0xffff }, { 6065, 0xfc07 }, { 6074, 0xfeff }, { 6089, 0xffff }, + { 6105, 0xffff }, { 6121, 0xffff }, { 6137, 0xffff }, { 6153, 0xffff }, + { 6169, 0xffff }, { 6185, 0xffff }, { 6201, 0x9fff }, { 6215, 0x003b }, + { 6220, 0x0000 }, { 6220, 0x0000 }, { 6220, 0x0000 }, { 6220, 0x0000 }, + /* 0x4e00 */ + { 6220, 0xffbf }, { 6235, 0xc3f7 }, { 6246, 0xef5f }, { 6259, 0xbb6f }, + { 6271, 0xebef }, { 6284, 0xf7de }, { 6297, 0x070c }, { 6302, 0xc23a }, + { 6309, 0xfbff }, { 6324, 0xfbfe }, { 6338, 0xf97f }, { 6351, 0x56df }, + { 6362, 0xffff }, { 6378, 0xfff1 }, { 6391, 0xc3ff }, { 6403, 0xffff }, + /* 0x4f00 */ + { 6419, 0xffff }, { 6435, 0x3fff }, { 6449, 0xf304 }, { 6456, 0xffff }, + { 6472, 0xffff }, { 6488, 0xffff }, { 6504, 0xffdf }, { 6519, 0xffff }, + { 6535, 0xffff }, { 6551, 0xffff }, { 6567, 0xc80f }, { 6574, 0xffff }, + { 6590, 0xffff }, { 6606, 0xffff }, { 6622, 0xd2bf }, { 6633, 0xffff }, + /* 0x5000 */ + { 6649, 0xffff }, { 6665, 0xffff }, { 6681, 0xffff }, { 6697, 0x93ff }, + { 6709, 0xffff }, { 6725, 0xffff }, { 6741, 0xffff }, { 6757, 0x3fff }, + { 6771, 0xffff }, { 6787, 0xffff }, { 6803, 0xfc4f }, { 6814, 0xffff }, + { 6830, 0xffff }, { 6846, 0xffff }, { 6862, 0xffff }, { 6878, 0xfffb }, + /* 0x5100 */ + { 6893, 0xffff }, { 6909, 0xffff }, { 6925, 0xffff }, { 6941, 0xffff }, + { 6957, 0xffff }, { 6973, 0xffff }, { 6989, 0x7fff }, { 7004, 0xd3ee }, + { 7015, 0xfffd }, { 7030, 0xe3ff }, { 7043, 0x3f7f }, { 7056, 0xf7ff }, + { 7071, 0xffff }, { 7087, 0xffff }, { 7103, 0x753f }, { 7114, 0x67ff }, + /* 0x5200 */ + { 7127, 0xdfff }, { 7142, 0xf1ff }, { 7155, 0xcfff }, { 7169, 0x7fff }, + { 7184, 0xfffa }, { 7198, 0xfffc }, { 7212, 0xffff }, { 7228, 0xfffd }, + { 7243, 0x7fff }, { 7258, 0xffff }, { 7274, 0xfff9 }, { 7288, 0xfffb }, + { 7303, 0xf7ff }, { 7318, 0xfbff }, { 7333, 0xffff }, { 7349, 0xffff }, + /* 0x5300 */ + { 7365, 0xfffb }, { 7380, 0xffff }, { 7396, 0xbfbf }, { 7410, 0xffff }, + { 7426, 0xffff }, { 7442, 0xffbf }, { 7457, 0xf7fb }, { 7471, 0xffff }, + { 7487, 0xcfdd }, { 7499, 0xffdc }, { 7512, 0xfff3 }, { 7526, 0x6fff }, + { 7540, 0xff3f }, { 7554, 0xfefd }, { 7568, 0xffff }, { 7584, 0xbfff }, + /* 0x5400 */ + { 7599, 0xffff }, { 7615, 0xff6f }, { 7629, 0xffff }, { 7645, 0xffff }, + { 7661, 0xffff }, { 7677, 0xe413 }, { 7684, 0xffff }, { 7700, 0xffff }, + { 7716, 0xffff }, { 7732, 0xd57f }, { 7744, 0xffff }, { 7760, 0xffff }, + { 7776, 0xffff }, { 7792, 0x4441 }, { 7796, 0xffff }, { 7812, 0xffff }, + /* 0x5500 */ + { 7828, 0xffff }, { 7844, 0x0fff }, { 7856, 0xffc3 }, { 7868, 0xffff }, + { 7884, 0xffff }, { 7900, 0xffff }, { 7916, 0x0d7f }, { 7926, 0xfcee }, + { 7938, 0xffff }, { 7954, 0xffff }, { 7970, 0xffff }, { 7986, 0x8c7f }, + { 7996, 0xffff }, { 8012, 0xffff }, { 8028, 0xc7ff }, { 8041, 0xffd7 }, + /* 0x5600 */ + { 8055, 0xffff }, { 8071, 0xfbff }, { 8086, 0xffc5 }, { 8098, 0xffff }, + { 8114, 0xffff }, { 8130, 0xc7ff }, { 8143, 0xffff }, { 8159, 0xefff }, + { 8174, 0xffff }, { 8190, 0xffff }, { 8206, 0xffe1 }, { 8218, 0xffff }, + { 8234, 0xbfff }, { 8249, 0xff9f }, { 8263, 0xfffb }, { 8278, 0xbfcf }, + /* 0x5700 */ + { 8291, 0xffbf }, { 8306, 0xfdff }, { 8321, 0xffbf }, { 8336, 0xf87f }, + { 8348, 0xffff }, { 8364, 0x8bff }, { 8376, 0xfffe }, { 8391, 0xffff }, + { 8407, 0xfd8f }, { 8419, 0xffff }, { 8435, 0x5fff }, { 8449, 0xfff0 }, + { 8461, 0xffff }, { 8477, 0xf8bf }, { 8489, 0xffff }, { 8505, 0xffff }, + /* 0x5800 */ + { 8521, 0xffff }, { 8537, 0xff9d }, { 8550, 0xffff }, { 8566, 0xffff }, + { 8582, 0xffbd }, { 8596, 0xffff }, { 8612, 0xbfff }, { 8627, 0xfffe }, + { 8642, 0xffff }, { 8658, 0xfdff }, { 8673, 0xffff }, { 8689, 0xfcbf }, + { 8702, 0xe7ff }, { 8716, 0xff7f }, { 8731, 0xdbdf }, { 8744, 0xfebf }, + /* 0x5900 */ + { 8758, 0xff7f }, { 8773, 0xbfff }, { 8788, 0xffff }, { 8804, 0xf1ff }, + { 8817, 0xfff9 }, { 8831, 0xffbf }, { 8846, 0xffff }, { 8862, 0xffff }, + { 8878, 0xfe7f }, { 8892, 0xffff }, { 8908, 0xf1ff }, { 8921, 0xffff }, + { 8937, 0xffff }, { 8953, 0xffff }, { 8969, 0xffff }, { 8985, 0xffff }, + /* 0x5a00 */ + { 9001, 0xfe1f }, { 9013, 0xffff }, { 9029, 0xffff }, { 9045, 0xffeb }, + { 9059, 0xffff }, { 9075, 0xffff }, { 9091, 0xffff }, { 9107, 0xffaf }, + { 9121, 0xffff }, { 9137, 0xffff }, { 9153, 0xdfff }, { 9168, 0xffff }, + { 9184, 0xffff }, { 9200, 0xffeb }, { 9214, 0xffff }, { 9230, 0xfff9 }, + /* 0x5b00 */ + { 9244, 0xffff }, { 9260, 0xffff }, { 9276, 0xffff }, { 9292, 0xffbf }, + { 9307, 0xffff }, { 9323, 0xbdff }, { 9337, 0xdfff }, { 9352, 0xffff }, + { 9368, 0xffff }, { 9384, 0xfffd }, { 9399, 0xfbfc }, { 9412, 0xdfff }, + { 9427, 0xfdff }, { 9442, 0xffff }, { 9458, 0xffff }, { 9474, 0xe7ff }, + /* 0x5c00 */ + { 9488, 0xfffb }, { 9503, 0xcfff }, { 9517, 0xbf3f }, { 9530, 0xffeb }, + { 9544, 0xfff3 }, { 9558, 0xffff }, { 9574, 0xffbf }, { 9589, 0x7fbb }, + { 9602, 0xfff3 }, { 9616, 0xf2bf }, { 9628, 0xffff }, { 9644, 0x0fff }, + { 9656, 0xffc3 }, { 9668, 0xffff }, { 9684, 0xff66 }, { 9696, 0xffff }, + /* 0x5d00 */ + { 9712, 0xffc3 }, { 9724, 0xffff }, { 9740, 0xdfff }, { 9755, 0xffff }, + { 9771, 0xffff }, { 9787, 0xcaff }, { 9799, 0xffff }, { 9815, 0xffbf }, + { 9830, 0xffff }, { 9846, 0xffff }, { 9862, 0xffff }, { 9878, 0xffff }, + { 9894, 0xffdf }, { 9909, 0xffff }, { 9925, 0x4bff }, { 9937, 0xefff }, + /* 0x5e00 */ + { 9952, 0x7fdf }, { 9966, 0xeffe }, { 9980, 0xff3f }, { 9994, 0xe7fd }, + { 10007, 0xfdff }, { 10022, 0xffff }, { 10038, 0xffff }, { 10054, 0xffff }, + { 10070, 0xffbf }, { 10085, 0x3fe5 }, { 10096, 0xffff }, { 10112, 0xefff }, + { 10127, 0xffff }, { 10143, 0xffff }, { 10159, 0xffef }, { 10174, 0xffff }, + /* 0x5f00 */ + { 10190, 0xfdff }, { 10205, 0xffbf }, { 10220, 0xfbfe }, { 10234, 0xffff }, + { 10250, 0xffdf }, { 10265, 0x7fff }, { 10280, 0xfeff }, { 10295, 0xf7ff }, + { 10310, 0xffff }, { 10326, 0xffdf }, { 10341, 0xffff }, { 10357, 0xffff }, + { 10373, 0xffbf }, { 10388, 0xffff }, { 10404, 0xffff }, { 10420, 0xffff }, + /* 0x6000 */ + { 10436, 0xff81 }, { 10446, 0xffff }, { 10462, 0xffff }, { 10478, 0x23ff }, + { 10489, 0xffff }, { 10505, 0xffff }, { 10521, 0xffff }, { 10537, 0xd03f }, + { 10546, 0xffff }, { 10562, 0xffff }, { 10578, 0x47ff }, { 10590, 0xffff }, + { 10606, 0xffff }, { 10622, 0xffff }, { 10638, 0x47ff }, { 10650, 0xffff }, + /* 0x6100 */ + { 10666, 0xffff }, { 10682, 0xffff }, { 10698, 0xffaf }, { 10712, 0xffff }, + { 10728, 0xffff }, { 10744, 0xfffd }, { 10759, 0xffff }, { 10775, 0xffff }, + { 10791, 0xffff }, { 10807, 0xffff }, { 10823, 0xffff }, { 10839, 0xffff }, + { 10855, 0xffff }, { 10871, 0xffe9 }, { 10884, 0xffff }, { 10900, 0xffef }, + /* 0x6200 */ + { 10915, 0xf7bf }, { 10929, 0xff7f }, { 10944, 0xffff }, { 10960, 0xffff }, + { 10976, 0xffef }, { 10991, 0xff9f }, { 11005, 0xe1ff }, { 11017, 0xffff }, + { 11033, 0xffff }, { 11049, 0x7fff }, { 11064, 0xfff8 }, { 11077, 0xffff }, + { 11093, 0xffff }, { 11109, 0xffff }, { 11125, 0xfc13 }, { 11134, 0xffff }, + /* 0x6300 */ + { 11150, 0xffff }, { 11166, 0x8aff }, { 11177, 0xff0a }, { 11187, 0xffff }, + { 11203, 0xffff }, { 11219, 0x3fff }, { 11233, 0xfff1 }, { 11246, 0xffff }, + { 11262, 0xffff }, { 11278, 0xffff }, { 11294, 0xffff }, { 11310, 0xe447 }, + { 11318, 0xffff }, { 11334, 0xffff }, { 11350, 0xffff }, { 11366, 0x47ff }, + /* 0x6400 */ + { 11378, 0xffc8 }, { 11389, 0xffff }, { 11405, 0xffff }, { 11421, 0xffff }, + { 11437, 0xfacb }, { 11448, 0xffff }, { 11464, 0xffff }, { 11480, 0xffff }, + { 11496, 0xffef }, { 11511, 0xffff }, { 11527, 0xffff }, { 11543, 0xfa5f }, + { 11555, 0xffff }, { 11571, 0x9fff }, { 11585, 0xffff }, { 11601, 0xffff }, + /* 0x6500 */ + { 11617, 0xffff }, { 11633, 0xfffb }, { 11648, 0xffff }, { 11664, 0xffff }, + { 11680, 0xffff }, { 11696, 0xf7ff }, { 11711, 0xfdff }, { 11726, 0x9fff }, + { 11740, 0x7fbf }, { 11754, 0xfff7 }, { 11769, 0xfdff }, { 11784, 0xffff }, + { 11800, 0xfffe }, { 11815, 0xffdf }, { 11830, 0xffff }, { 11846, 0xfe7f }, + /* 0x6600 */ + { 11860, 0xffff }, { 11876, 0xffff }, { 11892, 0xffff }, { 11908, 0x1fff }, + { 11921, 0xffff }, { 11937, 0xff87 }, { 11949, 0xffff }, { 11965, 0xffff }, + { 11981, 0xfff3 }, { 11995, 0xffff }, { 12011, 0xff7f }, { 12026, 0xffff }, + { 12042, 0xffff }, { 12058, 0xffff }, { 12074, 0xffff }, { 12090, 0xd7ff }, + /* 0x6700 */ + { 12104, 0xffff }, { 12120, 0xffff }, { 12136, 0xfdff }, { 12151, 0xfffe }, + { 12166, 0xfff5 }, { 12180, 0xffff }, { 12196, 0xfc67 }, { 12207, 0xffff }, + { 12223, 0xffff }, { 12239, 0xffff }, { 12255, 0xd05e }, { 12263, 0xffff }, + { 12279, 0xffff }, { 12295, 0xffff }, { 12311, 0xffff }, { 12327, 0xdfff }, + /* 0x6800 */ + { 12342, 0x0073 }, { 12347, 0xffff }, { 12363, 0xffff }, { 12379, 0xffff }, + { 12395, 0xffff }, { 12411, 0x47ff }, { 12423, 0xf800 }, { 12428, 0xffff }, + { 12444, 0xdfff }, { 12459, 0xffff }, { 12475, 0xffff }, { 12491, 0x23ff }, + { 12502, 0xfffa }, { 12516, 0xffff }, { 12532, 0xffff }, { 12548, 0xffff }, + /* 0x6900 */ + { 12564, 0xffff }, { 12580, 0x59ff }, { 12592, 0xdea0 }, { 12600, 0xffff }, + { 12616, 0xffff }, { 12632, 0xffff }, { 12648, 0xffff }, { 12664, 0xbfff }, + { 12679, 0xf46d }, { 12689, 0xffff }, { 12705, 0xffff }, { 12721, 0xffff }, + { 12737, 0xffff }, { 12753, 0x03ff }, { 12763, 0xfffe }, { 12778, 0xffff }, + /* 0x6a00 */ + { 12794, 0xffff }, { 12810, 0xffff }, { 12826, 0x3fff }, { 12840, 0xfffc }, + { 12854, 0xffff }, { 12870, 0xffff }, { 12886, 0xffff }, { 12902, 0xe5c7 }, + { 12912, 0xffff }, { 12928, 0xffff }, { 12944, 0xfdff }, { 12959, 0xffff }, + { 12975, 0xfdff }, { 12990, 0xffff }, { 13006, 0xffef }, { 13021, 0xff7f }, + /* 0x6b00 */ + { 13036, 0xffdf }, { 13051, 0x7fff }, { 13066, 0xffff }, { 13082, 0xffff }, + { 13098, 0xffff }, { 13114, 0xffff }, { 13130, 0xffff }, { 13146, 0xefff }, + { 13161, 0xff7f }, { 13176, 0xfbf3 }, { 13189, 0xffff }, { 13205, 0xfffd }, + { 13220, 0xfffb }, { 13235, 0x7ddf }, { 13248, 0xbfff }, { 13263, 0xffff }, + /* 0x6c00 */ + { 13279, 0xbf7f }, { 13293, 0xff7f }, { 13308, 0xfdfb }, { 13322, 0xdbdf }, + { 13335, 0xfe7f }, { 13349, 0xffff }, { 13365, 0xffef }, { 13380, 0xffff }, + { 13396, 0xffff }, { 13412, 0xffff }, { 13428, 0xfc0f }, { 13438, 0xffff }, + { 13454, 0xffff }, { 13470, 0xffff }, { 13486, 0xffff }, { 13502, 0x823f }, + /* 0x6d00 */ + { 13510, 0xffff }, { 13526, 0xffff }, { 13542, 0xffff }, { 13558, 0xffff }, + { 13574, 0x003f }, { 13580, 0xffc0 }, { 13590, 0xffff }, { 13606, 0xffff }, + { 13622, 0xffff }, { 13638, 0x0fff }, { 13650, 0xfc20 }, { 13657, 0xffff }, + { 13673, 0xffff }, { 13689, 0xffff }, { 13705, 0xffff }, { 13721, 0xffff }, + /* 0x6e00 */ + { 13737, 0x9fff }, { 13751, 0xffa4 }, { 13762, 0xffff }, { 13778, 0xffff }, + { 13794, 0xffff }, { 13810, 0xffff }, { 13826, 0xffff }, { 13842, 0x7fff }, + { 13857, 0xef55 }, { 13868, 0xffff }, { 13884, 0xffff }, { 13900, 0xffff }, + { 13916, 0xffff }, { 13932, 0x3fff }, { 13946, 0xfb48 }, { 13955, 0xffff }, + /* 0x6f00 */ + { 13971, 0xffff }, { 13987, 0xffff }, { 14003, 0xffff }, { 14019, 0xffff }, + { 14035, 0xd77f }, { 14048, 0xffff }, { 14064, 0xffff }, { 14080, 0xffff }, + { 14096, 0xffff }, { 14112, 0xe7ff }, { 14126, 0xffff }, { 14142, 0xffff }, + { 14158, 0xffff }, { 14174, 0xfff9 }, { 14188, 0xffff }, { 14204, 0xfdff }, + /* 0x7000 */ + { 14219, 0xffff }, { 14235, 0xffff }, { 14251, 0xffff }, { 14267, 0xffff }, + { 14283, 0x3fff }, { 14297, 0xfffe }, { 14312, 0xdfff }, { 14327, 0xffff }, + { 14343, 0xfffe }, { 14358, 0x8fff }, { 14371, 0xffff }, { 14387, 0xcfff }, + { 14401, 0xfff1 }, { 14414, 0xffff }, { 14430, 0xc43f }, { 14439, 0xffff }, + /* 0x7100 */ + { 14455, 0xffff }, { 14471, 0xfe8f }, { 14483, 0xffff }, { 14499, 0xafff }, + { 14513, 0xfffe }, { 14528, 0xffdf }, { 14543, 0xffff }, { 14559, 0xfff7 }, + { 14574, 0xffff }, { 14590, 0xffff }, { 14606, 0xffff }, { 14622, 0xffff }, + { 14638, 0xffff }, { 14654, 0xffff }, { 14670, 0xffff }, { 14686, 0xff3f }, + /* 0x7200 */ + { 14700, 0xffff }, { 14716, 0xffff }, { 14732, 0xffff }, { 14748, 0xff75 }, + { 14761, 0xdfff }, { 14776, 0xefff }, { 14791, 0xffff }, { 14807, 0xffdf }, + { 14822, 0xfbff }, { 14837, 0xffff }, { 14853, 0xfffe }, { 14868, 0xfe7f }, + { 14882, 0xfeff }, { 14897, 0xbfff }, { 14912, 0x3fff }, { 14926, 0xfff8 }, + /* 0x7300 */ + { 14939, 0xfff7 }, { 14954, 0x7fff }, { 14969, 0xfffc }, { 14983, 0xfdff }, + { 14998, 0xffff }, { 15014, 0xffff }, { 15030, 0xdfe7 }, { 15043, 0xffff }, + { 15059, 0xffff }, { 15075, 0xf1ff }, { 15088, 0xbfff }, { 15103, 0xfffc }, + { 15117, 0xffff }, { 15133, 0xfffd }, { 15148, 0xffff }, { 15164, 0xfff8 }, + /* 0x7400 */ + { 15177, 0x3fff }, { 15191, 0xfffc }, { 15205, 0xffff }, { 15221, 0xff7f }, + { 15236, 0xffff }, { 15252, 0xffff }, { 15268, 0xffff }, { 15284, 0xff7f }, + { 15299, 0xbfff }, { 15314, 0xffff }, { 15330, 0xffff }, { 15346, 0xffff }, + { 15362, 0xffff }, { 15378, 0xfffb }, { 15393, 0xff7f }, { 15408, 0xeff8 }, + /* 0x7500 */ + { 15420, 0xffdf }, { 15435, 0xfdff }, { 15450, 0xffff }, { 15466, 0xefcf }, + { 15479, 0xffdf }, { 15494, 0xfffb }, { 15509, 0xfdfe }, { 15523, 0xffe7 }, + { 15537, 0xdffb }, { 15551, 0x7f3f }, { 15564, 0x0ffc }, { 15574, 0xffff }, + { 15590, 0xfcff }, { 15604, 0xffbf }, { 15619, 0xf0ff }, { 15631, 0xffff }, + /* 0x7600 */ + { 15647, 0xff8f }, { 15660, 0xfe7f }, { 15674, 0xf3ff }, { 15688, 0x3fff }, + { 15702, 0xdfff }, { 15717, 0x9fff }, { 15731, 0xf7b7 }, { 15744, 0xfbff }, + { 15759, 0xffff }, { 15775, 0xfffd }, { 15790, 0xffff }, { 15806, 0xfff9 }, + { 15820, 0x7fff }, { 15835, 0xfffc }, { 15849, 0xffff }, { 15865, 0xffff }, + /* 0x7700 */ + { 15881, 0xcfff }, { 15895, 0xffff }, { 15911, 0xefff }, { 15926, 0xffff }, + { 15942, 0xffff }, { 15958, 0xfffc }, { 15972, 0xffff }, { 15988, 0xffff }, + { 16004, 0xffbf }, { 16019, 0xfff3 }, { 16033, 0xffff }, { 16049, 0xffff }, + { 16065, 0xf6ff }, { 16079, 0xffff }, { 16095, 0xf7ff }, { 16110, 0x7fff }, + /* 0x7800 */ + { 16125, 0xfffc }, { 16139, 0xeb3f }, { 16151, 0xffff }, { 16167, 0x21ff }, + { 16177, 0xfffc }, { 16191, 0xf11f }, { 16201, 0xffff }, { 16217, 0xff43 }, + { 16228, 0xffff }, { 16244, 0xf7ff }, { 16259, 0xffff }, { 16275, 0xff9f }, + { 16289, 0xffff }, { 16305, 0xfd7f }, { 16319, 0xffff }, { 16335, 0xffdf }, + /* 0x7900 */ + { 16350, 0xfff7 }, { 16365, 0xffbf }, { 16380, 0xffff }, { 16396, 0xf7e7 }, + { 16409, 0xbff7 }, { 16423, 0xffff }, { 16439, 0x7fff }, { 16454, 0xfeff }, + { 16469, 0xffdf }, { 16484, 0xffff }, { 16500, 0xffff }, { 16516, 0xffff }, + { 16532, 0xffff }, { 16548, 0xffff }, { 16564, 0x7fff }, { 16579, 0x9fef }, + /* 0x7a00 */ + { 16592, 0xffff }, { 16608, 0xffff }, { 16624, 0xffe7 }, { 16638, 0xffff }, + { 16654, 0xfff7 }, { 16669, 0x9ff9 }, { 16681, 0xfff7 }, { 16696, 0xff7f }, + { 16711, 0x9fff }, { 16725, 0xcfff }, { 16739, 0xdf9f }, { 16752, 0xffff }, + { 16768, 0xfff7 }, { 16783, 0xbfbf }, { 16797, 0xffff }, { 16813, 0xffff }, + /* 0x7b00 */ + { 16829, 0xff73 }, { 16842, 0xffdf }, { 16857, 0xffff }, { 16873, 0xabff }, + { 16886, 0xffff }, { 16902, 0xc3ff }, { 16914, 0xffff }, { 16930, 0x0bff }, + { 16941, 0xfffe }, { 16956, 0xfbff }, { 16971, 0xf03f }, { 16981, 0xffff }, + { 16997, 0x7fff }, { 17012, 0xfff1 }, { 17025, 0x3fff }, { 17039, 0xffff }, + /* 0x7c00 */ + { 17055, 0xffff }, { 17071, 0xff37 }, { 17084, 0xffff }, { 17100, 0xfffd }, + { 17115, 0xfffd }, { 17130, 0xffff }, { 17146, 0xfffd }, { 17161, 0xffff }, + { 17177, 0x7ffb }, { 17191, 0xfffe }, { 17206, 0xdbff }, { 17220, 0xffff }, + { 17236, 0xffff }, { 17252, 0xfeff }, { 17267, 0xffff }, { 17283, 0xfdff }, + /* 0x7d00 */ + { 17298, 0xffff }, { 17314, 0xffff }, { 17330, 0xff3f }, { 17344, 0xffff }, + { 17360, 0xffff }, { 17376, 0xffff }, { 17392, 0xffff }, { 17408, 0xff7f }, + { 17423, 0xffff }, { 17439, 0xf3ff }, { 17453, 0xffff }, { 17469, 0xffff }, + { 17485, 0xffff }, { 17501, 0xffcf }, { 17515, 0xffff }, { 17531, 0xffff }, + /* 0x7e00 */ + { 17547, 0xff9f }, { 17561, 0xffff }, { 17577, 0xfeff }, { 17592, 0xffff }, + { 17608, 0xf3ff }, { 17622, 0xffff }, { 17638, 0xff7f }, { 17653, 0xffff }, + { 17669, 0xfff7 }, { 17684, 0x7ffe }, { 17698, 0x0000 }, { 17698, 0x0000 }, + { 17698, 0x0000 }, { 17698, 0x0000 }, { 17698, 0x0000 }, { 17698, 0x0000 }, + /* 0x7f00 */ + { 17698, 0x0000 }, { 17698, 0x0000 }, { 17698, 0x0000 }, { 17698, 0xffc0 }, + { 17708, 0xfdfb }, { 17722, 0xfbb7 }, { 17735, 0xffff }, { 17751, 0xffef }, + { 17766, 0xfffd }, { 17781, 0x7fff }, { 17796, 0xfbff }, { 17811, 0xffff }, + { 17827, 0xffff }, { 17843, 0xf8ff }, { 17856, 0xffff }, { 17872, 0xffff }, + /* 0x8000 */ + { 17888, 0xffff }, { 17904, 0xffff }, { 17920, 0xff7b }, { 17934, 0xffff }, + { 17950, 0xc7fb }, { 17962, 0xffef }, { 17977, 0xfdfb }, { 17991, 0xffff }, + { 18007, 0xfff6 }, { 18021, 0xffff }, { 18037, 0xfffe }, { 18052, 0x0fff }, + { 18064, 0xfffc }, { 18078, 0xffff }, { 18094, 0xe07f }, { 18104, 0xffff }, + /* 0x8100 */ + { 18120, 0x07ff }, { 18131, 0xfff0 }, { 18143, 0xffff }, { 18159, 0xfe13 }, + { 18169, 0xffff }, { 18185, 0xf93f }, { 18197, 0xffff }, { 18213, 0xa7ff }, + { 18226, 0xffff }, { 18242, 0xfffd }, { 18257, 0xffcf }, { 18271, 0xffbf }, + { 18286, 0xffff }, { 18302, 0xeff7 }, { 18316, 0xffff }, { 18332, 0xffff }, + /* 0x8200 */ + { 18348, 0xffbf }, { 18363, 0xff7f }, { 18378, 0xbff7 }, { 18392, 0xb7fc }, + { 18404, 0xdfff }, { 18419, 0xdfef }, { 18433, 0xfffe }, { 18448, 0xfbfe }, + { 18462, 0xfefb }, { 18476, 0xff7f }, { 18491, 0xffff }, { 18507, 0xffff }, + { 18523, 0x063f }, { 18531, 0xffff }, { 18547, 0xffff }, { 18563, 0xffff }, + /* 0x8300 */ + { 18579, 0x7fff }, { 18594, 0xffc5 }, { 18606, 0xffff }, { 18622, 0xffff }, + { 18638, 0xffff }, { 18654, 0x01ff }, { 18663, 0x000c }, { 18665, 0xffff }, + { 18681, 0xffff }, { 18697, 0xffff }, { 18713, 0xffff }, { 18729, 0xe281 }, + { 18735, 0xffff }, { 18751, 0xffff }, { 18767, 0xffff }, { 18783, 0xffff }, + /* 0x8400 */ + { 18799, 0xffff }, { 18815, 0xc9ff }, { 18827, 0xfe0a }, { 18836, 0xffff }, + { 18852, 0xffff }, { 18868, 0xffff }, { 18884, 0xffff }, { 18900, 0xffff }, + { 18916, 0xe15f }, { 18926, 0xffff }, { 18942, 0xffff }, { 18958, 0xffff }, + { 18974, 0xffff }, { 18990, 0x4dff }, { 19002, 0xff96 }, { 19014, 0xffff }, + /* 0x8500 */ + { 19030, 0xffff }, { 19046, 0xffff }, { 19062, 0xffff }, { 19078, 0xe93f }, + { 19089, 0xffff }, { 19105, 0xffff }, { 19121, 0xffff }, { 19137, 0xffeb }, + { 19151, 0xffff }, { 19167, 0xffff }, { 19183, 0x9fff }, { 19197, 0xffff }, + { 19213, 0xffff }, { 19229, 0xfff7 }, { 19244, 0xffff }, { 19260, 0xffff }, + /* 0x8600 */ + { 19276, 0xffff }, { 19292, 0xffeb }, { 19306, 0xffff }, { 19322, 0xfffe }, + { 19337, 0x7fef }, { 19351, 0xffff }, { 19367, 0xffff }, { 19383, 0x7fff }, + { 19398, 0xfff0 }, { 19410, 0xffff }, { 19426, 0xe7ff }, { 19440, 0xffff }, + { 19456, 0x9fff }, { 19470, 0xffff }, { 19486, 0x7fff }, { 19501, 0xffe0 }, + /* 0x8700 */ + { 19512, 0xffff }, { 19528, 0xff7f }, { 19543, 0xffff }, { 19559, 0xffff }, + { 19575, 0xf4ff }, { 19588, 0xffff }, { 19604, 0xffff }, { 19620, 0x3fff }, + { 19634, 0xfffe }, { 19649, 0xffff }, { 19665, 0xfe3f }, { 19678, 0xffff }, + { 19694, 0x7fff }, { 19709, 0xfffe }, { 19724, 0xffff }, { 19740, 0xffff }, + /* 0x8800 */ + { 19756, 0xffff }, { 19772, 0xffff }, { 19788, 0xffff }, { 19804, 0xffff }, + { 19820, 0xffff }, { 19836, 0xffef }, { 19851, 0xefcf }, { 19864, 0xffff }, + { 19880, 0xff9f }, { 19894, 0xffff }, { 19910, 0x1fff }, { 19923, 0xfffe }, + { 19938, 0xfe07 }, { 19948, 0xffff }, { 19964, 0xffc3 }, { 19976, 0xffff }, + /* 0x8900 */ + { 19992, 0xffef }, { 20007, 0xcfff }, { 20021, 0xffff }, { 20037, 0xffef }, + { 20052, 0xff5f }, { 20066, 0xffdf }, { 20081, 0xfeff }, { 20096, 0xffff }, + { 20112, 0xfffe }, { 20127, 0xffff }, { 20143, 0xffff }, { 20159, 0xffff }, + { 20175, 0x0001 }, { 20176, 0xbffc }, { 20189, 0x7fff }, { 20204, 0xffff }, + /* 0x8a00 */ + { 20220, 0xfffd }, { 20235, 0xfbff }, { 20250, 0xffff }, { 20266, 0xfff7 }, + { 20281, 0xffff }, { 20297, 0x7fff }, { 20312, 0xffff }, { 20328, 0xffff }, + { 20344, 0xf9ff }, { 20358, 0xffff }, { 20374, 0xbfff }, { 20389, 0xffff }, + { 20405, 0xffff }, { 20421, 0xfbff }, { 20436, 0xffff }, { 20452, 0xffff }, + /* 0x8b00 */ + { 20468, 0xffff }, { 20484, 0xffff }, { 20500, 0xfffd }, { 20515, 0xffff }, + { 20531, 0xffff }, { 20547, 0xf7ff }, { 20562, 0xffff }, { 20578, 0xfffb }, + { 20593, 0x7fff }, { 20608, 0xffff }, { 20624, 0x0000 }, { 20624, 0x0000 }, + { 20624, 0x0000 }, { 20624, 0x0000 }, { 20624, 0x0000 }, { 20624, 0x0000 }, + /* 0x8c00 */ + { 20624, 0x0000 }, { 20624, 0x0000 }, { 20624, 0x0000 }, { 20624, 0xff80 }, + { 20633, 0xffff }, { 20649, 0xffff }, { 20665, 0xbfff }, { 20680, 0xffff }, + { 20696, 0xffff }, { 20712, 0xffff }, { 20728, 0xffff }, { 20744, 0xffff }, + { 20760, 0xbfff }, { 20775, 0xffff }, { 20791, 0xffff }, { 20807, 0xffff }, + /* 0x8d00 */ + { 20823, 0xffff }, { 20839, 0x1fff }, { 20852, 0x0000 }, { 20852, 0x0000 }, + { 20852, 0x0000 }, { 20852, 0x0000 }, { 20852, 0xfbf0 }, { 20863, 0xffdf }, + { 20878, 0xffff }, { 20894, 0xffff }, { 20910, 0xffff }, { 20926, 0xfefd }, + { 20940, 0xffef }, { 20955, 0xbfff }, { 20970, 0xffdf }, { 20985, 0xf41f }, + /* 0x8e00 */ + { 20995, 0xafff }, { 21009, 0xffff }, { 21025, 0x4fff }, { 21038, 0xffff }, + { 21054, 0xffff }, { 21070, 0xfffb }, { 21085, 0xffff }, { 21101, 0x1fff }, + { 21114, 0x7ffe }, { 21128, 0xe7ff }, { 21142, 0xffff }, { 21158, 0xf7df }, + { 21172, 0xfedf }, { 21186, 0xffff }, { 21202, 0xfff3 }, { 21216, 0xffff }, + /* 0x8f00 */ + { 21232, 0xefff }, { 21247, 0xffff }, { 21263, 0xffff }, { 21279, 0xffff }, + { 21295, 0xefff }, { 21310, 0xffff }, { 21326, 0x003f }, { 21332, 0x0000 }, + { 21332, 0x0000 }, { 21332, 0xf800 }, { 21337, 0xf5ff }, { 21351, 0xdbff }, + { 21365, 0xffff }, { 21381, 0x93ff }, { 21393, 0xffff }, { 21409, 0xfff3 }, + /* 0x9000 */ + { 21423, 0xfbff }, { 21438, 0xffff }, { 21454, 0xff3f }, { 21468, 0xfdff }, + { 21483, 0xffff }, { 21499, 0xff3f }, { 21513, 0xffdf }, { 21528, 0xffff }, + { 21544, 0xffff }, { 21560, 0xdfff }, { 21575, 0xefff }, { 21590, 0xf3ff }, + { 21604, 0x7fff }, { 21619, 0xfff4 }, { 21632, 0xff3f }, { 21646, 0xfeff }, + /* 0x9100 */ + { 21661, 0xffff }, { 21677, 0xffff }, { 21693, 0xffff }, { 21709, 0xffff }, + { 21725, 0xfffb }, { 21740, 0x97ff }, { 21753, 0xffbf }, { 21768, 0x1ffd }, + { 21780, 0xffff }, { 21796, 0xff7f }, { 21811, 0xffef }, { 21826, 0xfeff }, + { 21841, 0xfaff }, { 21855, 0xfffb }, { 21870, 0xfffd }, { 21885, 0xe3ff }, + /* 0x9200 */ + { 21898, 0xffff }, { 21914, 0xffff }, { 21930, 0xe8ff }, { 21942, 0xffff }, + { 21958, 0xffff }, { 21974, 0xffff }, { 21990, 0xffff }, { 22006, 0xfffd }, + { 22021, 0xffff }, { 22037, 0xffff }, { 22053, 0xffff }, { 22069, 0xffff }, + { 22085, 0xffff }, { 22101, 0xffff }, { 22117, 0xffff }, { 22133, 0xffff }, + /* 0x9300 */ + { 22149, 0xffff }, { 22165, 0xffff }, { 22181, 0xffff }, { 22197, 0xbfff }, + { 22212, 0xffed }, { 22226, 0xffff }, { 22242, 0xffff }, { 22258, 0xffff }, + { 22274, 0xffff }, { 22290, 0xffff }, { 22306, 0xffff }, { 22322, 0xfbff }, + { 22337, 0xffff }, { 22353, 0xffff }, { 22369, 0xffff }, { 22385, 0xfffe }, + /* 0x9400 */ + { 22400, 0xffff }, { 22416, 0xffff }, { 22432, 0xffbd }, { 22446, 0xffff }, + { 22462, 0xfffd }, { 22477, 0xfff7 }, { 22492, 0xffff }, { 22508, 0xffff }, + { 22524, 0x001f }, { 22529, 0x0000 }, { 22529, 0x0000 }, { 22529, 0x0000 }, + { 22529, 0x0000 }, { 22529, 0x0000 }, { 22529, 0x0000 }, { 22529, 0x0000 }, + /* 0x9500 */ + { 22529, 0x0000 }, { 22529, 0x0000 }, { 22529, 0x0000 }, { 22529, 0x0000 }, + { 22529, 0x0000 }, { 22529, 0x0000 }, { 22529, 0x0000 }, { 22529, 0x7f80 }, + { 22537, 0xfbff }, { 22552, 0xffff }, { 22568, 0xfbff }, { 22583, 0xffff }, + { 22599, 0x7fff }, { 22614, 0xffff }, { 22630, 0x00ff }, { 22638, 0x0020 }, + /* 0x9600 */ + { 22639, 0x0000 }, { 22639, 0x7000 }, { 22642, 0xffff }, { 22658, 0xff9f }, + { 22672, 0xfc1f }, { 22683, 0xffff }, { 22699, 0xfc1f }, { 22710, 0xfbff }, + { 22725, 0xffff }, { 22741, 0xfffe }, { 22756, 0xffff }, { 22772, 0xffff }, + { 22788, 0xffff }, { 22804, 0xffff }, { 22820, 0xfffe }, { 22835, 0xbff7 }, + /* 0x9700 */ + { 22849, 0xfffd }, { 22864, 0xffff }, { 22880, 0xdfff }, { 22895, 0xffff }, + { 22911, 0x2fff }, { 22924, 0xffe7 }, { 22938, 0xffdf }, { 22953, 0xfffd }, + { 22968, 0xffbf }, { 22983, 0xfff8 }, { 22996, 0x7fff }, { 23011, 0xffff }, + { 23027, 0xffff }, { 23043, 0xffff }, { 23059, 0xe03f }, { 23068, 0xffff }, + /* 0x9800 */ + { 23084, 0xffff }, { 23100, 0xffff }, { 23116, 0xefff }, { 23131, 0xffff }, + { 23147, 0xffff }, { 23163, 0xffff }, { 23179, 0xffff }, { 23195, 0x001f }, + { 23200, 0x0000 }, { 23200, 0x0000 }, { 23200, 0xfb00 }, { 23207, 0xffef }, + { 23222, 0x3fdf }, { 23235, 0xb800 }, { 23239, 0xbefe }, { 23252, 0xffff }, + /* 0x9900 */ + { 23268, 0x5fff }, { 23282, 0xffff }, { 23298, 0xffff }, { 23314, 0xffff }, + { 23330, 0xffff }, { 23346, 0xffff }, { 23362, 0x0003 }, { 23364, 0x0000 }, + { 23364, 0x0000 }, { 23364, 0xffc0 }, { 23374, 0xffff }, { 23390, 0xffff }, + { 23406, 0xffdf }, { 23421, 0xffff }, { 23437, 0xffff }, { 23453, 0xfffb }, + /* 0x9a00 */ + { 23468, 0xffff }, { 23484, 0xfff3 }, { 23498, 0xfeff }, { 23513, 0xffff }, + { 23529, 0xffff }, { 23545, 0xffff }, { 23561, 0x0fff }, { 23573, 0x0000 }, + { 23573, 0x0000 }, { 23573, 0x0000 }, { 23573, 0xff00 }, { 23581, 0xffff }, + { 23597, 0xe7df }, { 23610, 0xffff }, { 23626, 0xffff }, { 23642, 0xffff }, + /* 0x9b00 */ + { 23658, 0xffff }, { 23674, 0xfff7 }, { 23689, 0xffff }, { 23705, 0xffbf }, + { 23720, 0xff7f }, { 23735, 0xbfff }, { 23750, 0xffff }, { 23766, 0xfeff }, + { 23781, 0xffff }, { 23797, 0xff7f }, { 23812, 0xffff }, { 23828, 0xffeb }, + { 23842, 0xbfff }, { 23857, 0xfffc }, { 23871, 0xffff }, { 23887, 0xffd9 }, + /* 0x9c00 */ + { 23900, 0xffff }, { 23916, 0xf8ff }, { 23929, 0xffff }, { 23945, 0xfffe }, + { 23960, 0xffff }, { 23976, 0xe3ff }, { 23989, 0xf1ff }, { 24002, 0x0ffe }, + { 24013, 0x0000 }, { 24013, 0x0000 }, { 24013, 0x0000 }, { 24013, 0x0000 }, + { 24013, 0x0000 }, { 24013, 0x0000 }, { 24013, 0xffe0 }, { 24024, 0xfffe }, + /* 0x9d00 */ + { 24039, 0xbfff }, { 24054, 0xffff }, { 24070, 0xe7ff }, { 24084, 0xffff }, + { 24100, 0xfebf }, { 24114, 0xffff }, { 24130, 0xffdf }, { 24145, 0xffff }, + { 24161, 0x1fff }, { 24174, 0xffff }, { 24190, 0xf7ff }, { 24205, 0xffff }, + { 24221, 0xffbf }, { 24236, 0xffff }, { 24252, 0xffff }, { 24268, 0xffff }, + /* 0x9e00 */ + { 24284, 0xffff }, { 24300, 0x7fff }, { 24315, 0x0000 }, { 24315, 0x0000 }, + { 24315, 0x0000 }, { 24315, 0x0000 }, { 24315, 0x0000 }, { 24315, 0xbee0 }, + { 24324, 0xffff }, { 24340, 0xffff }, { 24356, 0xffff }, { 24372, 0xf8ff }, + { 24385, 0xfdff }, { 24400, 0xffff }, { 24416, 0xf9fd }, { 24429, 0xffff }, + /* 0x9f00 */ + { 24445, 0xc7ff }, { 24458, 0xffff }, { 24474, 0xfffd }, { 24489, 0xffff }, + { 24505, 0xffff }, { 24521, 0xfffd }, { 24536, 0xfffb }, { 24551, 0x7fff }, + { 24566, 0xe000 }, { 24569, 0x73ff }, { 24582, 0x003f }, +}; +static const Summary16 cns11643_inv_uni2indx_pagefa[3] = { + /* 0xfa00 */ + { 24588, 0x0000 }, { 24588, 0x0000 }, { 24588, 0x0100 }, +}; +static const Summary16 cns11643_inv_uni2indx_pagefe[31] = { + /* 0xfe00 */ + { 24589, 0x0000 }, { 24589, 0x0000 }, { 24589, 0x0000 }, { 24589, 0xffe7 }, + { 24603, 0x7e1f }, { 24614, 0xfef7 }, { 24628, 0x0f7f }, { 24639, 0x0000 }, + { 24639, 0x0000 }, { 24639, 0x0000 }, { 24639, 0x0000 }, { 24639, 0x0000 }, + { 24639, 0x0000 }, { 24639, 0x0000 }, { 24639, 0x0000 }, { 24639, 0x0000 }, + /* 0xff00 */ + { 24639, 0xff7a }, { 24652, 0xffff }, { 24668, 0xffff }, { 24684, 0x97ff }, + { 24697, 0xfffe }, { 24712, 0x3fff }, { 24726, 0x0000 }, { 24726, 0x0000 }, + { 24726, 0x0000 }, { 24726, 0x0000 }, { 24726, 0x0000 }, { 24726, 0x0000 }, + { 24726, 0x0000 }, { 24726, 0x0000 }, { 24726, 0x0023 }, +}; +static const Summary16 cns11643_inv_uni2indx_page200[2670] = { + /* 0x20000 */ + { 24729, 0x8bbd }, { 24739, 0x0715 }, { 24745, 0x722f }, { 24754, 0x0860 }, + { 24757, 0x39ca }, { 24765, 0x08ec }, { 24771, 0xeaf6 }, { 24782, 0xe0d7 }, + { 24791, 0xb1fc }, { 24801, 0x5fbc }, { 24812, 0xd33d }, { 24822, 0xf6ff }, + { 24836, 0x8a5c }, { 24843, 0xc377 }, { 24853, 0x24f3 }, { 24861, 0x795f }, + /* 0x20100 */ + { 24872, 0xfff4 }, { 24885, 0xeefe }, { 24898, 0x751f }, { 24908, 0x03b7 }, + { 24916, 0x9fb9 }, { 24927, 0xe3fa }, { 24938, 0xfebf }, { 24952, 0x4071 }, + { 24957, 0xd6ff }, { 24970, 0x3004 }, { 24973, 0xb3f8 }, { 24983, 0x1ff5 }, + { 24994, 0x8ffc }, { 25005, 0xff11 }, { 25015, 0x0fff }, { 25027, 0xc096 }, + /* 0x20200 */ + { 25033, 0xfffb }, { 25048, 0xffe3 }, { 25061, 0xf787 }, { 25072, 0xffff }, + { 25088, 0xfff0 }, { 25100, 0x0977 }, { 25108, 0x7ffe }, { 25122, 0xffce }, + { 25135, 0x1dff }, { 25147, 0x4056 }, { 25152, 0x7ffd }, { 25166, 0x4fff }, + { 25179, 0xfffe }, { 25194, 0x287f }, { 25203, 0xffae }, { 25216, 0xffff }, + /* 0x20300 */ + { 25232, 0xfb81 }, { 25241, 0x119f }, { 25249, 0xfe03 }, { 25258, 0xdeff }, + { 25272, 0xff11 }, { 25282, 0xc17f }, { 25292, 0xdf84 }, { 25301, 0x0fff }, + { 25313, 0xfffc }, { 25327, 0x4fff }, { 25340, 0xd08e }, { 25347, 0xffcf }, + { 25361, 0xf59f }, { 25373, 0x04d7 }, { 25380, 0xff9e }, { 25393, 0x0dd1 }, + /* 0x20400 */ + { 25400, 0x7f41 }, { 25409, 0x8de4 }, { 25417, 0xcdfe }, { 25429, 0xfc6f }, + { 25441, 0xf037 }, { 25450, 0xbf8e }, { 25461, 0xefd0 }, { 25471, 0xeecc }, + { 25481, 0x3d7b }, { 25492, 0xcff9 }, { 25504, 0x2f1f }, { 25514, 0xbf7f }, + { 25528, 0xfb5c }, { 25539, 0xb9ac }, { 25548, 0xecb3 }, { 25558, 0x21db }, + /* 0x20500 */ + { 25566, 0xdfdf }, { 25580, 0xbfed }, { 25593, 0x8fa7 }, { 25603, 0x73fa }, + { 25614, 0x6d5e }, { 25624, 0xed5f }, { 25636, 0xf3fd }, { 25649, 0x2eef }, + { 25660, 0xb433 }, { 25668, 0xd6ff }, { 25681, 0x4acf }, { 25690, 0x3fd6 }, + { 25701, 0x7fff }, { 25716, 0x7fbe }, { 25729, 0xf5e6 }, { 25740, 0xfcfe }, + /* 0x20600 */ + { 25753, 0x7ff1 }, { 25765, 0xf9de }, { 25777, 0xfabf }, { 25790, 0xf5ef }, + { 25803, 0xbfc1 }, { 25813, 0xbf8f }, { 25825, 0xef87 }, { 25836, 0xefef }, + { 25850, 0xe9c7 }, { 25860, 0xefc6 }, { 25871, 0xffea }, { 25884, 0xff9f }, + { 25898, 0xe39f }, { 25909, 0x0fff }, { 25921, 0xffe1 }, { 25933, 0xfbf7 }, + /* 0x20700 */ + { 25947, 0x12c4 }, { 25952, 0xbfff }, { 25967, 0x016f }, { 25974, 0xffff }, + { 25990, 0x3f3f }, { 26002, 0xef06 }, { 26011, 0xe7bf }, { 26024, 0xe002 }, + { 26028, 0xffff }, { 26044, 0x311f }, { 26052, 0xfff0 }, { 26064, 0xf88f }, + { 26074, 0xfffe }, { 26089, 0x9fff }, { 26103, 0xffc0 }, { 26113, 0xfc2b }, + /* 0x20800 */ + { 26123, 0xe9ff }, { 26136, 0xf88d }, { 26145, 0xdccf }, { 26156, 0xfbdf }, + { 26170, 0x31de }, { 26179, 0xc3fe }, { 26190, 0xff47 }, { 26202, 0xfb37 }, + { 26214, 0xcff7 }, { 26227, 0x03fc }, { 26235, 0xa1ff }, { 26246, 0x9fdf }, + { 26259, 0xfffb }, { 26274, 0xf7de }, { 26287, 0xcfff }, { 26301, 0xffbb }, + /* 0x20900 */ + { 26315, 0xcfbb }, { 26327, 0xdfbf }, { 26341, 0xfd3f }, { 26354, 0xd77b }, + { 26366, 0xde3f }, { 26378, 0x7e4f }, { 26389, 0xfe6e }, { 26401, 0x6dff }, + { 26414, 0x31ed }, { 26423, 0xff7e }, { 26437, 0x3c7f }, { 26448, 0x70f3 }, + { 26457, 0xc517 }, { 26465, 0xdf9b }, { 26477, 0xff7f }, { 26492, 0x3ffc }, + /* 0x20a00 */ + { 26504, 0xebef }, { 26517, 0xff5d }, { 26530, 0xf0ad }, { 26539, 0x2ff7 }, + { 26551, 0xfc9f }, { 26563, 0xffc6 }, { 26575, 0xffdd }, { 26589, 0xff1f }, + { 26602, 0xffd0 }, { 26613, 0xff7e }, { 26627, 0xec75 }, { 26637, 0xfe29 }, + { 26647, 0x5387 }, { 26655, 0xc6bd }, { 26665, 0x1ff5 }, { 26676, 0x9e1b }, + /* 0x20b00 */ + { 26685, 0xc5f7 }, { 26696, 0xfd8b }, { 26707, 0xffee }, { 26721, 0xbffe }, + { 26735, 0xfebf }, { 26749, 0xffff }, { 26765, 0xffeb }, { 26779, 0xd97f }, + { 26791, 0xeffe }, { 26805, 0x7fff }, { 26820, 0xfdff }, { 26835, 0x0fbf }, + { 26846, 0xff46 }, { 26857, 0x7fff }, { 26872, 0x59fa }, { 26882, 0x0068 }, + /* 0x20c00 */ + { 26885, 0xff30 }, { 26895, 0x7fff }, { 26910, 0xfffe }, { 26925, 0x8165 }, + { 26931, 0x4001 }, { 26933, 0xffff }, { 26949, 0xfbff }, { 26964, 0xfe2f }, + { 26976, 0xdbff }, { 26990, 0x0089 }, { 26993, 0xee00 }, { 26999, 0xffff }, + { 27015, 0x7fff }, { 27030, 0xf800 }, { 27035, 0xcfff }, { 27049, 0x8f93 }, + /* 0x20d00 */ + { 27058, 0x0008 }, { 27059, 0x0000 }, { 27059, 0xffce }, { 27072, 0xffff }, + { 27088, 0x040f }, { 27093, 0xfffe }, { 27108, 0x0427 }, { 27113, 0x02a5 }, + { 27118, 0x0000 }, { 27118, 0x0000 }, { 27118, 0x7f80 }, { 27126, 0xfdbf }, + { 27140, 0xffff }, { 27156, 0xfffe }, { 27171, 0xff80 }, { 27180, 0x79ff }, + /* 0x20e00 */ + { 27193, 0x3011 }, { 27197, 0x2040 }, { 27199, 0x6000 }, { 27201, 0x8fef }, + { 27213, 0xffff }, { 27229, 0xdfff }, { 27244, 0x4fff }, { 27257, 0x8000 }, + { 27258, 0xffff }, { 27274, 0x0008 }, { 27275, 0x0014 }, { 27277, 0x0000 }, + { 27277, 0xf000 }, { 27281, 0xfff3 }, { 27295, 0xffff }, { 27311, 0xc043 }, + /* 0x20f00 */ + { 27316, 0xffff }, { 27332, 0x557f }, { 27343, 0x020c }, { 27346, 0x0000 }, + { 27346, 0x0000 }, { 27346, 0x3000 }, { 27348, 0xfffd }, { 27363, 0xff7f }, + { 27378, 0x1f7f }, { 27390, 0xffc0 }, { 27400, 0x84e3 }, { 27407, 0x0001 }, + { 27408, 0xffe0 }, { 27419, 0xffff }, { 27435, 0x40ff }, { 27444, 0xfc00 }, + /* 0x21000 */ + { 27450, 0xffff }, { 27466, 0x000d }, { 27469, 0x0000 }, { 27469, 0xbe00 }, + { 27475, 0xfbfe }, { 27489, 0x80ef }, { 27497, 0x3b3f }, { 27508, 0x0000 }, + { 27508, 0x8c00 }, { 27511, 0xffff }, { 27527, 0x13ff }, { 27538, 0x7fc0 }, + { 27547, 0x0000 }, { 27547, 0xa000 }, { 27549, 0xffff }, { 27565, 0x0084 }, + /* 0x21100 */ + { 27567, 0x077c }, { 27575, 0x7ffe }, { 27589, 0x0009 }, { 27591, 0x8ffe }, + { 27603, 0x0003 }, { 27605, 0xf790 }, { 27614, 0x600a }, { 27618, 0xff47 }, + { 27630, 0xce68 }, { 27638, 0x180f }, { 27644, 0x238f }, { 27652, 0xdffd }, + { 27666, 0x7fda }, { 27678, 0x09ff }, { 27688, 0x041f }, { 27694, 0xf2ff }, + /* 0x21200 */ + { 27707, 0xfe9d }, { 27719, 0xbff2 }, { 27731, 0x743c }, { 27739, 0xd38a }, + { 27747, 0x3416 }, { 27753, 0xaf04 }, { 27760, 0x10ff }, { 27769, 0x10ee }, + { 27776, 0xffff }, { 27792, 0x5ff8 }, { 27803, 0x11fb }, { 27812, 0x7ff0 }, + { 27823, 0xfff0 }, { 27835, 0x797f }, { 27847, 0xff89 }, { 27858, 0x01ff }, + /* 0x21300 */ + { 27867, 0xffc2 }, { 27878, 0x97ed }, { 27889, 0xfef0 }, { 27900, 0xfbdf }, + { 27914, 0x87ff }, { 27926, 0x003a }, { 27930, 0xfff3 }, { 27944, 0xfcff }, + { 27958, 0x40ff }, { 27967, 0x04e1 }, { 27972, 0xdf80 }, { 27980, 0xfffb }, + { 27995, 0xffaf }, { 28009, 0x00bf }, { 28016, 0xee00 }, { 28022, 0x81ff }, + /* 0x21400 */ + { 28032, 0x47ff }, { 28044, 0xe83b }, { 28053, 0x2f7f }, { 28065, 0x5fff }, + { 28079, 0x8784 }, { 28085, 0xdf16 }, { 28095, 0x395f }, { 28105, 0x07c0 }, + { 28110, 0x7fc4 }, { 28120, 0xfe4d }, { 28131, 0x811b }, { 28137, 0x3fbf }, + { 28150, 0x3600 }, { 28154, 0x0ebf }, { 28164, 0x1ed8 }, { 28172, 0xbf7f }, + /* 0x21500 */ + { 28186, 0x8f96 }, { 28195, 0xefa0 }, { 28204, 0xb1f7 }, { 28215, 0x7ee1 }, + { 28225, 0x7c60 }, { 28232, 0xff6e }, { 28245, 0xdfdf }, { 28259, 0xffde }, + { 28273, 0xad53 }, { 28282, 0xf7be }, { 28295, 0xfe3c }, { 28306, 0xe3dd }, + { 28317, 0x114a }, { 28322, 0xf33c }, { 28332, 0xff6f }, { 28346, 0xff91 }, + /* 0x21600 */ + { 28357, 0xfa77 }, { 28369, 0xa7f5 }, { 28380, 0x0a7d }, { 28388, 0xbffd }, + { 28402, 0xf792 }, { 28412, 0x35e1 }, { 28420, 0xff05 }, { 28430, 0xffc7 }, + { 28443, 0x9fe3 }, { 28454, 0x59c3 }, { 28462, 0x8d39 }, { 28470, 0xff3f }, + { 28484, 0x6ff8 }, { 28495, 0xffed }, { 28509, 0xfe27 }, { 28520, 0x7e9f }, + /* 0x21700 */ + { 28532, 0xffff }, { 28548, 0xbbfe }, { 28561, 0xffeb }, { 28575, 0xe17f }, + { 28586, 0xb4ff }, { 28598, 0xff82 }, { 28608, 0x0fff }, { 28620, 0xffe4 }, + { 28632, 0x5fff }, { 28646, 0xff1b }, { 28658, 0xffdf }, { 28673, 0xffc1 }, + { 28684, 0x47ff }, { 28696, 0xfe72 }, { 28707, 0xffff }, { 28723, 0xe09f }, + /* 0x21800 */ + { 28732, 0x493f }, { 28741, 0xfebf }, { 28755, 0xf8f5 }, { 28766, 0x21ff }, + { 28776, 0xbf2c }, { 28786, 0xbeff }, { 28800, 0xff21 }, { 28810, 0xf2ff }, + { 28823, 0x2ffc }, { 28834, 0x3ffe }, { 28847, 0x7ff8 }, { 28859, 0xc1b6 }, + { 28867, 0xfbef }, { 28881, 0xfc37 }, { 28892, 0xee12 }, { 28900, 0xf5bf }, + /* 0x21900 */ + { 28913, 0xb9c7 }, { 28923, 0x3fe4 }, { 28933, 0xdf7e }, { 28946, 0xd6d7 }, + { 28957, 0xe7ef }, { 28970, 0x79ff }, { 28983, 0xff4e }, { 28995, 0x6ec7 }, + { 29005, 0xdaf8 }, { 29015, 0xe5ae }, { 29025, 0xa23f }, { 29034, 0xf321 }, + { 29042, 0xf9fc }, { 29054, 0xf7c2 }, { 29064, 0xfe0d }, { 29074, 0x0df3 }, + /* 0x21a00 */ + { 29083, 0xe7ff }, { 29097, 0xd01b }, { 29104, 0xfffd }, { 29119, 0xf853 }, + { 29128, 0xc3ff }, { 29140, 0xca3f }, { 29150, 0xf7ff }, { 29165, 0xfc1f }, + { 29176, 0xcf7f }, { 29189, 0x8dd9 }, { 29198, 0x7fbf }, { 29212, 0xf5d0 }, + { 29221, 0x7fff }, { 29236, 0xfdfc }, { 29249, 0xf60d }, { 29258, 0xf88f }, + /* 0x21b00 */ + { 29268, 0xb4f9 }, { 29278, 0xaf5e }, { 29289, 0xd78d }, { 29299, 0xee1b }, + { 29309, 0x7d66 }, { 29319, 0xe66f }, { 29330, 0x8f23 }, { 29338, 0xe238 }, + { 29345, 0xc00f }, { 29351, 0xe221 }, { 29357, 0x00c2 }, { 29360, 0x8813 }, + { 29365, 0xe67c }, { 29375, 0xfb55 }, { 29386, 0xf7ef }, { 29400, 0x1dfc }, + /* 0x21c00 */ + { 29410, 0x7e9c }, { 29420, 0x33f7 }, { 29431, 0xfe7d }, { 29444, 0xf5c1 }, + { 29453, 0xf81f }, { 29463, 0x2fbf }, { 29475, 0x7dff }, { 29489, 0xfe97 }, + { 29501, 0x5fff }, { 29515, 0xfffe }, { 29530, 0xf7cb }, { 29542, 0x4f7f }, + { 29554, 0xa7f4 }, { 29564, 0xc1fb }, { 29574, 0x39c3 }, { 29582, 0xc196 }, + /* 0x21d00 */ + { 29589, 0xf977 }, { 29601, 0xfbee }, { 29614, 0xbbfa }, { 29626, 0x99ef }, + { 29637, 0xcdc3 }, { 29646, 0x7ffa }, { 29659, 0x4fd8 }, { 29668, 0x560b }, + { 29675, 0xfffc }, { 29689, 0xefff }, { 29704, 0xfe15 }, { 29714, 0xfb0b }, + { 29724, 0x92ff }, { 29735, 0xffff }, { 29751, 0xe7ff }, { 29765, 0x81ff }, + /* 0x21e00 */ + { 29775, 0x5704 }, { 29781, 0xdfff }, { 29796, 0x17ff }, { 29808, 0xff60 }, + { 29818, 0xac4f }, { 29827, 0x0014 }, { 29829, 0xffbc }, { 29842, 0x7fed }, + { 29855, 0xfd40 }, { 29863, 0x2614 }, { 29868, 0xf812 }, { 29875, 0xfeff }, + { 29890, 0x28ff }, { 29900, 0xffa2 }, { 29911, 0xf7ff }, { 29926, 0x43f7 }, + /* 0x21f00 */ + { 29936, 0x7c00 }, { 29941, 0x3fff }, { 29955, 0x87e0 }, { 29962, 0xf441 }, + { 29969, 0x77ff }, { 29983, 0xfd39 }, { 29994, 0xf0fb }, { 30005, 0x2521 }, + { 30010, 0x7fe5 }, { 30022, 0xff33 }, { 30034, 0xc2dc }, { 30042, 0x78c7 }, + { 30051, 0x9fc2 }, { 30060, 0xb972 }, { 30069, 0xffaf }, { 30083, 0xeb8f }, + /* 0x22000 */ + { 30094, 0x47ff }, { 30106, 0xb31f }, { 30116, 0x821f }, { 30123, 0x8ad0 }, + { 30129, 0x11ff }, { 30139, 0x9ffd }, { 30152, 0xf7fc }, { 30165, 0xfe3f }, + { 30178, 0xadcf }, { 30189, 0xe5ff }, { 30202, 0xde6f }, { 30214, 0xfff6 }, + { 30228, 0xf85f }, { 30239, 0xffff }, { 30255, 0xfd9b }, { 30267, 0x6fff }, + /* 0x22100 */ + { 30281, 0xfdf2 }, { 30293, 0xddf9 }, { 30305, 0x08ff }, { 30314, 0xf7ff }, + { 30329, 0xee04 }, { 30336, 0xceff }, { 30349, 0xef4f }, { 30361, 0xfb67 }, + { 30373, 0xefb8 }, { 30384, 0x9e0f }, { 30393, 0xd014 }, { 30398, 0xfbfe }, + { 30412, 0xfcc3 }, { 30422, 0x7fd7 }, { 30435, 0xaff9 }, { 30447, 0xfffd }, + /* 0x22200 */ + { 30462, 0xffb7 }, { 30476, 0xfe87 }, { 30487, 0x313f }, { 30496, 0xfffc }, + { 30510, 0xfd7f }, { 30524, 0xff61 }, { 30535, 0xffff }, { 30551, 0x9057 }, + { 30558, 0x5eff }, { 30571, 0xfbfd }, { 30585, 0xf57f }, { 30598, 0x1fff }, + { 30611, 0xf0fe }, { 30622, 0x35ff }, { 30634, 0xacfe }, { 30645, 0xf9e7 }, + /* 0x22300 */ + { 30657, 0xabdd }, { 30668, 0x7bfe }, { 30681, 0xbfed }, { 30694, 0xfd7a }, + { 30706, 0xe47e }, { 30716, 0xfff5 }, { 30730, 0xd9dd }, { 30741, 0xcfcf }, + { 30753, 0x74db }, { 30763, 0xb70f }, { 30773, 0x2ffd }, { 30785, 0xdfc7 }, + { 30797, 0x03e3 }, { 30804, 0x07fc }, { 30813, 0xdfd0 }, { 30823, 0x7fff }, + /* 0x22400 */ + { 30838, 0xbdff }, { 30852, 0xe37c }, { 30862, 0xb3ff }, { 30875, 0xdfbd }, + { 30888, 0x3fdf }, { 30901, 0x5fff }, { 30915, 0xaf5e }, { 30926, 0xe3ef }, + { 30938, 0x979f }, { 30949, 0xfff3 }, { 30963, 0xfff7 }, { 30978, 0xebfd }, + { 30991, 0x8ffd }, { 31003, 0xf1fd }, { 31015, 0xfe2d }, { 31026, 0x77ff }, + /* 0x22500 */ + { 31040, 0xffdf }, { 31055, 0xf503 }, { 31063, 0x2fff }, { 31076, 0xf9fb }, + { 31089, 0xe189 }, { 31096, 0xffff }, { 31112, 0xfc9f }, { 31124, 0x5edb }, + { 31135, 0xe71e }, { 31145, 0xff8f }, { 31158, 0x3efd }, { 31170, 0x2ffd }, + { 31182, 0x7f8a }, { 31192, 0xf9bf }, { 31205, 0x5fff }, { 31219, 0x8e26 }, + /* 0x22600 */ + { 31226, 0xffff }, { 31242, 0x647f }, { 31252, 0x8dc9 }, { 31260, 0xfdff }, + { 31275, 0x7fff }, { 31290, 0xffc0 }, { 31300, 0x414f }, { 31307, 0xffff }, + { 31323, 0xffff }, { 31339, 0xfe83 }, { 31349, 0x807f }, { 31357, 0x0c01 }, + { 31360, 0xfffe }, { 31375, 0xffff }, { 31391, 0x7fff }, { 31406, 0xff81 }, + /* 0x22700 */ + { 31416, 0xffff }, { 31432, 0x8ccf }, { 31441, 0xffb8 }, { 31453, 0xffff }, + { 31469, 0xffff }, { 31485, 0xe0bf }, { 31495, 0x67ff }, { 31508, 0x2004 }, + { 31510, 0xf682 }, { 31518, 0xf7ff }, { 31533, 0xffff }, { 31549, 0xffcf }, + { 31563, 0x0c1f }, { 31570, 0x3000 }, { 31572, 0xdfdf }, { 31586, 0xffff }, + /* 0x22800 */ + { 31602, 0xfc01 }, { 31609, 0xd7ff }, { 31623, 0x5003 }, { 31627, 0xfffe }, + { 31642, 0xcfff }, { 31656, 0x43ff }, { 31667, 0xfff6 }, { 31681, 0xe118 }, + { 31687, 0xb000 }, { 31690, 0xfffe }, { 31705, 0x40ff }, { 31714, 0x00ff }, + { 31722, 0xfe02 }, { 31730, 0xff7f }, { 31745, 0xff07 }, { 31756, 0xf8c5 }, + /* 0x22900 */ + { 31765, 0xdfff }, { 31780, 0x03ef }, { 31789, 0xfff0 }, { 31801, 0x7c7f }, + { 31813, 0xfc1a }, { 31822, 0xfd9f }, { 31835, 0xfbf2 }, { 31847, 0xff07 }, + { 31858, 0xcbe2 }, { 31867, 0xfe79 }, { 31879, 0xdfdf }, { 31893, 0x8fc0 }, + { 31900, 0x7fcf }, { 31913, 0x997e }, { 31923, 0x1ff5 }, { 31934, 0xe7f8 }, + /* 0x22a00 */ + { 31945, 0x7ff0 }, { 31956, 0xce3f }, { 31967, 0xb67b }, { 31978, 0x7f94 }, + { 31988, 0x69f2 }, { 31997, 0x236e }, { 32005, 0x7b65 }, { 32015, 0x007f }, + { 32022, 0xfffc }, { 32036, 0xf0ff }, { 32048, 0x029f }, { 32055, 0xfdf0 }, + { 32066, 0x7fc5 }, { 32077, 0x0010 }, { 32078, 0xfff4 }, { 32091, 0xffff }, + /* 0x22b00 */ + { 32107, 0xffc9 }, { 32119, 0x4fff }, { 32132, 0x9c04 }, { 32137, 0xffff }, + { 32153, 0x7fff }, { 32168, 0xfffc }, { 32182, 0x055f }, { 32190, 0x0000 }, + { 32190, 0xffde }, { 32204, 0xf7ff }, { 32219, 0xc19f }, { 32228, 0xffff }, + { 32244, 0x115f }, { 32252, 0x0000 }, { 32252, 0xfe08 }, { 32260, 0xffff }, + /* 0x22c00 */ + { 32276, 0xffff }, { 32292, 0x1fff }, { 32305, 0xff00 }, { 32313, 0x7fff }, + { 32328, 0x20ad }, { 32334, 0x8000 }, { 32335, 0xdfff }, { 32350, 0xdfdf }, + { 32364, 0xffff }, { 32380, 0x0167 }, { 32386, 0x0002 }, { 32387, 0x7ff9 }, + { 32400, 0xebff }, { 32414, 0x077f }, { 32424, 0xfffe }, { 32439, 0x5fff }, + /* 0x22d00 */ + { 32453, 0x0003 }, { 32455, 0x0000 }, { 32455, 0x7fff }, { 32470, 0xffff }, + { 32486, 0xe51b }, { 32495, 0xffff }, { 32511, 0x0009 }, { 32513, 0x8000 }, + { 32514, 0xffff }, { 32530, 0x3fff }, { 32544, 0xffc0 }, { 32554, 0x0023 }, + { 32557, 0xfb80 }, { 32565, 0x3fff }, { 32579, 0x2ff0 }, { 32588, 0xffc0 }, + /* 0x22e00 */ + { 32598, 0xc3ff }, { 32610, 0x037f }, { 32619, 0xfff8 }, { 32632, 0xff9f }, + { 32646, 0xa817 }, { 32653, 0x87fb }, { 32664, 0xf007 }, { 32671, 0x0ebf }, + { 32681, 0x9ffc }, { 32693, 0xc763 }, { 32702, 0x77e7 }, { 32714, 0x47f7 }, + { 32725, 0xe51e }, { 32734, 0x6cf3 }, { 32744, 0xf6e3 }, { 32755, 0x6ede }, + /* 0x22f00 */ + { 32766, 0xffe0 }, { 32777, 0xf133 }, { 32786, 0xf5af }, { 32798, 0xac40 }, + { 32803, 0x8fff }, { 32816, 0xe9bf }, { 32828, 0xf7f3 }, { 32841, 0x84fd }, + { 32850, 0xbbfd }, { 32863, 0xfe1d }, { 32874, 0xffb9 }, { 32887, 0x77fa }, + { 32899, 0x6fc0 }, { 32907, 0xcbff }, { 32920, 0x7f3b }, { 32932, 0xe3fc }, + /* 0x23000 */ + { 32943, 0xde47 }, { 32953, 0x6577 }, { 32963, 0xfdff }, { 32978, 0x34fa }, + { 32987, 0xddce }, { 32998, 0xf7a7 }, { 33010, 0x5abf }, { 33021, 0xbdfa }, + { 33033, 0x9677 }, { 33043, 0xca3a }, { 33051, 0xedff }, { 33065, 0xbf66 }, + { 33076, 0xbd4f }, { 33087, 0xfb5b }, { 33099, 0xffc6 }, { 33111, 0xfba8 }, + /* 0x23100 */ + { 33121, 0xdf17 }, { 33132, 0xe793 }, { 33142, 0x4dd7 }, { 33152, 0xdbf7 }, + { 33165, 0x5fd7 }, { 33177, 0xfc4f }, { 33188, 0xffff }, { 33204, 0x7f9e }, + { 33216, 0x0e7a }, { 33224, 0x7ffc }, { 33237, 0x0bc9 }, { 33244, 0xfffc }, + { 33258, 0xf841 }, { 33265, 0x043f }, { 33272, 0xdffc }, { 33285, 0xfc4f }, + /* 0x23200 */ + { 33296, 0xa19f }, { 33305, 0x8000 }, { 33306, 0x47f3 }, { 33316, 0x7fe0 }, + { 33326, 0x051f }, { 33333, 0x1ffe }, { 33345, 0x3ff8 }, { 33356, 0xfc01 }, + { 33363, 0x805e }, { 33369, 0xee73 }, { 33380, 0xc1fb }, { 33390, 0x255f }, + { 33399, 0xbf30 }, { 33408, 0xc1f9 }, { 33417, 0xfc28 }, { 33425, 0x85fc }, + /* 0x23300 */ + { 33434, 0xe1b8 }, { 33442, 0x93c8 }, { 33449, 0xbffc }, { 33462, 0x798f }, + { 33472, 0x91d8 }, { 33479, 0xfb5e }, { 33491, 0x58ff }, { 33502, 0x17f8 }, + { 33511, 0x3e36 }, { 33520, 0x9f9d }, { 33531, 0x723b }, { 33540, 0xbf7e }, + { 33553, 0x0fef }, { 33564, 0xfff7 }, { 33579, 0xffa3 }, { 33591, 0x6b4f }, + /* 0x23400 */ + { 33601, 0xff8b }, { 33613, 0xff8f }, { 33626, 0x07ff }, { 33637, 0xffe1 }, + { 33649, 0x801f }, { 33655, 0xfffe }, { 33670, 0xed3f }, { 33682, 0xe306 }, + { 33689, 0x83ff }, { 33700, 0xffff }, { 33716, 0xbfff }, { 33731, 0x9fc0 }, + { 33739, 0xffff }, { 33755, 0xffff }, { 33771, 0xff83 }, { 33782, 0xffff }, + /* 0x23500 */ + { 33798, 0xffff }, { 33814, 0x007e }, { 33820, 0xf800 }, { 33825, 0xfffe }, + { 33840, 0x7fff }, { 33855, 0xfa0f }, { 33865, 0xffff }, { 33881, 0x9fff }, + { 33895, 0x048f }, { 33901, 0x0029 }, { 33904, 0xff78 }, { 33916, 0xfff7 }, + { 33931, 0x000e }, { 33934, 0xfff1 }, { 33947, 0xffff }, { 33963, 0x0db9 }, + /* 0x23600 */ + { 33971, 0xe8a1 }, { 33978, 0xfff7 }, { 33993, 0xffff }, { 34009, 0x880f }, + { 34015, 0xfffe }, { 34030, 0x0a7f }, { 34039, 0x0010 }, { 34040, 0xf87f }, + { 34052, 0xffff }, { 34068, 0xfff7 }, { 34083, 0x877f }, { 34094, 0xffff }, + { 34110, 0xffff }, { 34126, 0x8543 }, { 34132, 0x5800 }, { 34135, 0xbfff }, + /* 0x23700 */ + { 34150, 0xe1ff }, { 34162, 0xffff }, { 34178, 0x91f8 }, { 34186, 0x9600 }, + { 34190, 0xfffe }, { 34205, 0x7fff }, { 34220, 0xffa0 }, { 34230, 0x5aff }, + { 34242, 0x1ac2 }, { 34248, 0xffff }, { 34264, 0xfff8 }, { 34277, 0x98e5 }, + { 34285, 0xfff4 }, { 34298, 0xff07 }, { 34309, 0x910f }, { 34316, 0x7f7d }, + /* 0x23800 */ + { 34329, 0xdffe }, { 34343, 0xfe11 }, { 34352, 0x7fe3 }, { 34364, 0xffa0 }, + { 34374, 0xf679 }, { 34385, 0x591f }, { 34394, 0x6fad }, { 34405, 0x1dde }, + { 34415, 0xfeff }, { 34430, 0xff9f }, { 34444, 0xf7cf }, { 34457, 0xac3f }, + { 34467, 0xff7f }, { 34482, 0xe3ef }, { 34494, 0x9bff }, { 34507, 0xffff }, + /* 0x23900 */ + { 34523, 0xffbf }, { 34538, 0x77b7 }, { 34550, 0x723f }, { 34560, 0xdef6 }, + { 34572, 0xffbf }, { 34587, 0x3bff }, { 34600, 0x2fed }, { 34611, 0xff3c }, + { 34623, 0x0fbe }, { 34633, 0xf7f0 }, { 34644, 0x81f6 }, { 34652, 0xbfe6 }, + { 34664, 0xfeff }, { 34679, 0xe07f }, { 34689, 0xffff }, { 34705, 0xfbff }, + /* 0x23a00 */ + { 34720, 0xffeb }, { 34734, 0xffc7 }, { 34747, 0x837f }, { 34757, 0x2bfe }, + { 34768, 0xfbf8 }, { 34780, 0xe3ff }, { 34793, 0xbf3f }, { 34806, 0xdcdf }, + { 34818, 0xf96d }, { 34829, 0x9aff }, { 34841, 0xf6fb }, { 34854, 0xfbef }, + { 34868, 0x30e3 }, { 34875, 0xc74f }, { 34885, 0xbbfe }, { 34898, 0xf711 }, + /* 0x23b00 */ + { 34907, 0xff7f }, { 34922, 0xdcff }, { 34935, 0xfffe }, { 34950, 0xff2f }, + { 34963, 0xfeb7 }, { 34976, 0xf43f }, { 34987, 0x7fef }, { 35001, 0xfffe }, + { 35016, 0xff07 }, { 35027, 0xffbf }, { 35042, 0xff98 }, { 35053, 0x3e1f }, + { 35063, 0xffe4 }, { 35075, 0xbbee }, { 35087, 0xfff4 }, { 35100, 0xff87 }, + /* 0x23c00 */ + { 35112, 0x7e47 }, { 35122, 0xdc5f }, { 35133, 0x7d1f }, { 35144, 0xdbc6 }, + { 35154, 0xdfb1 }, { 35165, 0xdf7f }, { 35179, 0xcc7b }, { 35189, 0x03f4 }, + { 35196, 0xcbdf }, { 35208, 0xe03f }, { 35217, 0xffa3 }, { 35229, 0xfffd }, + { 35244, 0xfc37 }, { 35255, 0x2fff }, { 35268, 0xfff8 }, { 35281, 0x00ff }, + /* 0x23d00 */ + { 35289, 0xfffe }, { 35304, 0xe077 }, { 35313, 0xffff }, { 35329, 0x5fff }, + { 35343, 0xfffc }, { 35357, 0x7fff }, { 35372, 0x1354 }, { 35378, 0xff8a }, + { 35389, 0xffff }, { 35405, 0xff7f }, { 35420, 0x007e }, { 35426, 0xc020 }, + { 35429, 0xffff }, { 35445, 0xafff }, { 35459, 0x02d6 }, { 35465, 0xf860 }, + /* 0x23e00 */ + { 35472, 0xffff }, { 35488, 0xffff }, { 35504, 0x0003 }, { 35506, 0xfffc }, + { 35520, 0x76df }, { 35532, 0xec00 }, { 35537, 0xffff }, { 35553, 0xfffe }, + { 35568, 0xf003 }, { 35574, 0xffff }, { 35590, 0x97ff }, { 35603, 0x8057 }, + { 35609, 0xb400 }, { 35613, 0xffff }, { 35629, 0xffff }, { 35645, 0x8007 }, + /* 0x23f00 */ + { 35649, 0xffff }, { 35665, 0xafff }, { 35679, 0x000f }, { 35683, 0x8820 }, + { 35686, 0xdff8 }, { 35698, 0xffff }, { 35714, 0xffff }, { 35730, 0x2079 }, + { 35736, 0xfff0 }, { 35748, 0xffff }, { 35764, 0x7f0f }, { 35775, 0x0081 }, + { 35777, 0xffe2 }, { 35789, 0xffff }, { 35805, 0x001f }, { 35810, 0xfffe }, + /* 0x24000 */ + { 35825, 0x49f3 }, { 35834, 0x8002 }, { 35836, 0xffff }, { 35852, 0xc2ff }, + { 35863, 0x37ff }, { 35876, 0xf481 }, { 35883, 0xfffe }, { 35898, 0xffff }, + { 35914, 0xc4ff }, { 35925, 0xffff }, { 35941, 0x806e }, { 35947, 0xefff }, + { 35962, 0xfc17 }, { 35972, 0x07bf }, { 35982, 0xbe08 }, { 35989, 0x7bf7 }, + /* 0x24100 */ + { 36002, 0xc2e0 }, { 36008, 0xfffb }, { 36023, 0x1f5f }, { 36034, 0x2ff8 }, + { 36044, 0x7cee }, { 36055, 0x2f06 }, { 36062, 0x6f5f }, { 36074, 0xfb9f }, + { 36087, 0xef7d }, { 36100, 0xe5f7 }, { 36112, 0xbfc0 }, { 36121, 0xf017 }, + { 36129, 0xff83 }, { 36140, 0xafff }, { 36154, 0x8807 }, { 36159, 0xe0ff }, + /* 0x24200 */ + { 36170, 0xffff }, { 36186, 0x0967 }, { 36193, 0xffec }, { 36206, 0xfe07 }, + { 36216, 0x07ff }, { 36227, 0xa202 }, { 36231, 0xfefe }, { 36245, 0xfe00 }, + { 36252, 0xffff }, { 36268, 0x1bff }, { 36280, 0x8020 }, { 36282, 0xfff4 }, + { 36295, 0xf8df }, { 36307, 0xffff }, { 36323, 0x97ff }, { 36336, 0x040b }, + /* 0x24300 */ + { 36340, 0xff8a }, { 36351, 0xf87f }, { 36363, 0xffff }, { 36379, 0x3f7f }, + { 36392, 0xe100 }, { 36396, 0x3ff9 }, { 36408, 0xffc4 }, { 36419, 0xdfff }, + { 36434, 0x1034 }, { 36438, 0xe5c0 }, { 36445, 0xffff }, { 36461, 0xc1bf }, + { 36471, 0xffff }, { 36487, 0xefbf }, { 36501, 0xe201 }, { 36506, 0xfff1 }, + /* 0x24400 */ + { 36519, 0xfff1 }, { 36532, 0xc0a7 }, { 36539, 0xbfc4 }, { 36549, 0xff8f }, + { 36562, 0xcc6f }, { 36572, 0xf0dd }, { 36582, 0x0185 }, { 36586, 0xf7ff }, + { 36601, 0xff47 }, { 36613, 0x5089 }, { 36618, 0x58de }, { 36627, 0x7de8 }, + { 36637, 0x873f }, { 36647, 0xf6f5 }, { 36659, 0xfde3 }, { 36671, 0x79de }, + /* 0x24500 */ + { 36682, 0xd4ff }, { 36694, 0x11bf }, { 36703, 0x57fd }, { 36715, 0x033f }, + { 36723, 0xeb2d }, { 36733, 0xffeb }, { 36747, 0xefff }, { 36762, 0x7eff }, + { 36776, 0xffee }, { 36790, 0x7ffb }, { 36804, 0xfffd }, { 36819, 0x7c9f }, + { 36830, 0xffb7 }, { 36844, 0x1f82 }, { 36851, 0xffef }, { 36866, 0xbdfa }, + /* 0x24600 */ + { 36878, 0xf339 }, { 36888, 0xfff3 }, { 36902, 0xf8ff }, { 36915, 0xff1d }, + { 36927, 0xb61d }, { 36936, 0xf9bf }, { 36949, 0x2dd7 }, { 36959, 0x0fbf }, + { 36970, 0xff1c }, { 36981, 0x437f }, { 36991, 0xff01 }, { 37000, 0xff7f }, + { 37015, 0xff04 }, { 37024, 0x8823 }, { 37029, 0x8afe }, { 37039, 0xee5f }, + /* 0x24700 */ + { 37051, 0xbbbd }, { 37063, 0x3ed7 }, { 37074, 0x895e }, { 37082, 0xffff }, + { 37098, 0xb04f }, { 37106, 0xdfff }, { 37121, 0xd17b }, { 37131, 0xffff }, + { 37147, 0x8177 }, { 37155, 0xfe80 }, { 37163, 0xb02f }, { 37171, 0xc305 }, + { 37177, 0xfffb }, { 37192, 0xf6b7 }, { 37204, 0x3fff }, { 37218, 0x2d7c }, + /* 0x24800 */ + { 37227, 0xe480 }, { 37232, 0xf7ff }, { 37247, 0x1bf3 }, { 37257, 0xfe20 }, + { 37265, 0x60ff }, { 37275, 0xf383 }, { 37284, 0x7fff }, { 37299, 0xbe7f }, + { 37312, 0xfe28 }, { 37321, 0x77ff }, { 37335, 0x87cf }, { 37345, 0x0fff }, + { 37357, 0x6f2b }, { 37367, 0xbb8f }, { 37378, 0xcfdd }, { 37390, 0x1fb5 }, + /* 0x24900 */ + { 37400, 0xf97c }, { 37411, 0xfd0f }, { 37422, 0x9d3f }, { 37433, 0x1fe6 }, + { 37443, 0xfff8 }, { 37456, 0x1ff0 }, { 37465, 0x3ff0 }, { 37475, 0xfbf2 }, + { 37487, 0x002b }, { 37491, 0xffff }, { 37507, 0xf977 }, { 37519, 0xf01f }, + { 37528, 0xffff }, { 37544, 0xc2df }, { 37554, 0xfcfd }, { 37567, 0xfc05 }, + /* 0x24a00 */ + { 37575, 0xbfff }, { 37590, 0x3ff9 }, { 37602, 0xf800 }, { 37607, 0x7f3f }, + { 37620, 0x0bff }, { 37631, 0xfffc }, { 37645, 0xfff8 }, { 37658, 0xf837 }, + { 37668, 0xf8ff }, { 37681, 0xff81 }, { 37691, 0x7f7d }, { 37704, 0xf7f0 }, + { 37715, 0x377f }, { 37727, 0x9df1 }, { 37737, 0xff78 }, { 37749, 0x7dff }, + /* 0x24b00 */ + { 37763, 0xfb9e }, { 37775, 0x3fc7 }, { 37786, 0xf75f }, { 37799, 0xdef1 }, + { 37810, 0xf07f }, { 37821, 0xf9bf }, { 37834, 0x17ef }, { 37845, 0xfe19 }, + { 37855, 0xefe1 }, { 37866, 0x3f59 }, { 37876, 0xefc6 }, { 37887, 0x3f2f }, + { 37898, 0x7b8b }, { 37908, 0xeff9 }, { 37921, 0xdcdf }, { 37933, 0x729c }, + /* 0x24c00 */ + { 37941, 0x65f9 }, { 37951, 0xeaa3 }, { 37960, 0xff3f }, { 37974, 0xff7f }, + { 37989, 0xf801 }, { 37995, 0xc7e5 }, { 38005, 0xfff8 }, { 38018, 0x704b }, + { 38025, 0xe9f8 }, { 38035, 0x3fff }, { 38049, 0xf88b }, { 38058, 0xefe7 }, + { 38071, 0xbf21 }, { 38080, 0x8dfc }, { 38090, 0xfe13 }, { 38100, 0xde4c }, + /* 0x24d00 */ + { 38109, 0x59bf }, { 38120, 0xf3ef }, { 38133, 0xcff3 }, { 38145, 0xff9f }, + { 38159, 0x398f }, { 38168, 0xff92 }, { 38179, 0x2fff }, { 38192, 0xff80 }, + { 38201, 0x1e7f }, { 38212, 0xfff8 }, { 38225, 0x3f3f }, { 38237, 0x00c0 }, + { 38239, 0xffff }, { 38255, 0x7ffb }, { 38269, 0x0021 }, { 38271, 0xfb80 }, + /* 0x24e00 */ + { 38279, 0xffff }, { 38295, 0xe3fe }, { 38307, 0xfe15 }, { 38317, 0xffff }, + { 38333, 0xa27c }, { 38341, 0xf800 }, { 38346, 0x9fff }, { 38360, 0x0a5b }, + { 38367, 0xfff3 }, { 38381, 0x3fff }, { 38395, 0x03c2 }, { 38400, 0xff80 }, + { 38409, 0x23ff }, { 38420, 0x7fe0 }, { 38430, 0xc12e }, { 38437, 0x07fe }, + /* 0x24f00 */ + { 38447, 0x38ff }, { 38458, 0xb7c7 }, { 38469, 0xbfbf }, { 38483, 0x7687 }, + { 38492, 0x77ce }, { 38503, 0xef57 }, { 38515, 0x97f3 }, { 38526, 0xbe81 }, + { 38534, 0xff08 }, { 38543, 0x7b20 }, { 38550, 0x3dff }, { 38563, 0x795c }, + { 38572, 0xcfe9 }, { 38583, 0xbfe7 }, { 38596, 0x5fa7 }, { 38607, 0x86fc }, + /* 0x25000 */ + { 38616, 0xefde }, { 38629, 0xdff3 }, { 38642, 0xb97e }, { 38653, 0xb677 }, + { 38664, 0xdbff }, { 38678, 0xdf7f }, { 38692, 0xfffb }, { 38707, 0x9fdb }, + { 38719, 0xf5f9 }, { 38731, 0xdffb }, { 38745, 0x73f3 }, { 38756, 0xd7ee }, + { 38768, 0x6fbf }, { 38781, 0x13fc }, { 38790, 0x1ff2 }, { 38800, 0x3ffc }, + /* 0x25100 */ + { 38812, 0xfffd }, { 38827, 0x7bff }, { 38841, 0x02b8 }, { 38846, 0xfffe }, + { 38861, 0x7e13 }, { 38870, 0xff88 }, { 38880, 0x7fef }, { 38894, 0x324f }, + { 38902, 0xfbe0 }, { 38912, 0xffff }, { 38928, 0x1c7f }, { 38938, 0x0069 }, + { 38942, 0xfef8 }, { 38954, 0xff7f }, { 38969, 0x4f13 }, { 38977, 0xc030 }, + /* 0x25200 */ + { 38981, 0xffed }, { 38995, 0x1fff }, { 39008, 0x07fc }, { 39017, 0xf980 }, + { 39024, 0xffff }, { 39040, 0xffff }, { 39056, 0x007c }, { 39061, 0xfff1 }, + { 39074, 0x47f7 }, { 39085, 0x0021 }, { 39087, 0xfd80 }, { 39095, 0xffff }, + { 39111, 0x271f }, { 39120, 0xfe01 }, { 39128, 0xbf3f }, { 39141, 0x8801 }, + /* 0x25300 */ + { 39144, 0xffff }, { 39160, 0xfcf1 }, { 39171, 0xe70e }, { 39180, 0xfc67 }, + { 39191, 0x9e5f }, { 39202, 0xc6b8 }, { 39210, 0xffbf }, { 39225, 0xffef }, + { 39240, 0xfefd }, { 39254, 0x17fd }, { 39265, 0x1ff2 }, { 39275, 0xff7f }, + { 39290, 0xc207 }, { 39296, 0xf792 }, { 39306, 0x9c07 }, { 39313, 0x78ff }, + /* 0x25400 */ + { 39325, 0x001b }, { 39329, 0x7fea }, { 39341, 0x1e3f }, { 39351, 0x35fe }, + { 39362, 0xfff3 }, { 39376, 0x7f9f }, { 39389, 0xd20c }, { 39395, 0xff7d }, + { 39409, 0xbfd7 }, { 39422, 0x5054 }, { 39427, 0xff90 }, { 39437, 0x3e7f }, + { 39449, 0xfcc3 }, { 39459, 0xfcff }, { 39473, 0x20ff }, { 39482, 0xfc02 }, + /* 0x25500 */ + { 39489, 0x07ff }, { 39500, 0xfffd }, { 39515, 0xff0d }, { 39526, 0x07ff }, + { 39537, 0xfbe8 }, { 39548, 0xc5fb }, { 39559, 0x3fe3 }, { 39570, 0xffff }, + { 39586, 0x9ffc }, { 39598, 0xff80 }, { 39607, 0xdc7f }, { 39619, 0xfa9b }, + { 39630, 0x027f }, { 39638, 0xeb4c }, { 39647, 0xfc0e }, { 39656, 0xcd96 }, + /* 0x25600 */ + { 39665, 0x637a }, { 39674, 0x7e60 }, { 39682, 0x7850 }, { 39688, 0xff03 }, + { 39698, 0xfe14 }, { 39707, 0x3ff0 }, { 39717, 0xf910 }, { 39724, 0x1f87 }, + { 39733, 0xff08 }, { 39742, 0x17ff }, { 39754, 0x0fc0 }, { 39760, 0x03ff }, + { 39770, 0xfdef }, { 39784, 0xff10 }, { 39793, 0xc01f }, { 39800, 0xbfbf }, + /* 0x25700 */ + { 39814, 0x9fbe }, { 39826, 0xccbe }, { 39836, 0x9ee9 }, { 39846, 0xff9f }, + { 39860, 0xbdba }, { 39871, 0x7d7d }, { 39883, 0xfffc }, { 39897, 0xde78 }, + { 39907, 0x037f }, { 39916, 0xff84 }, { 39926, 0x8207 }, { 39931, 0xfffe }, + { 39946, 0xe0a0 }, { 39951, 0x5fff }, { 39965, 0x03fc }, { 39973, 0xed80 }, + /* 0x25800 */ + { 39980, 0xffff }, { 39996, 0x01ff }, { 40005, 0x0006 }, { 40007, 0xf6fe }, + { 40020, 0x1feb }, { 40031, 0xbc10 }, { 40037, 0xffff }, { 40053, 0x0279 }, + { 40059, 0xfd83 }, { 40069, 0x7f7e }, { 40082, 0x6080 }, { 40085, 0xbff3 }, + { 40098, 0x003f }, { 40104, 0xd7c8 }, { 40113, 0xffe1 }, { 40125, 0x40bf }, + /* 0x25900 */ + { 40133, 0x5cef }, { 40144, 0xd7fe }, { 40157, 0x6f9c }, { 40167, 0xfff3 }, + { 40181, 0xff8e }, { 40193, 0x4f9f }, { 40204, 0x7fff }, { 40219, 0xffc0 }, + { 40229, 0xfdff }, { 40244, 0xf80b }, { 40252, 0xe7f7 }, { 40265, 0xff67 }, + { 40278, 0x84e0 }, { 40283, 0xfffd }, { 40298, 0xf025 }, { 40305, 0xbfff }, + /* 0x25a00 */ + { 40320, 0xe40f }, { 40328, 0x05ff }, { 40338, 0x7c0e }, { 40346, 0xb9ff }, + { 40359, 0xdd0f }, { 40369, 0x1bfd }, { 40380, 0x7fff }, { 40395, 0xdb7e }, + { 40407, 0xffdf }, { 40422, 0x8f3f }, { 40433, 0xf7f3 }, { 40446, 0xf86f }, + { 40457, 0xe708 }, { 40464, 0xff47 }, { 40476, 0xe1e7 }, { 40486, 0xfffb }, + /* 0x25b00 */ + { 40501, 0xf0bf }, { 40512, 0xeeff }, { 40526, 0xfc7e }, { 40538, 0xfbff }, + { 40553, 0x0fff }, { 40565, 0xffff }, { 40581, 0xfdff }, { 40596, 0xff83 }, + { 40607, 0xf03f }, { 40617, 0x7fff }, { 40632, 0xeffd }, { 40646, 0xffe0 }, + { 40657, 0x0047 }, { 40661, 0xffff }, { 40677, 0xffff }, { 40693, 0xf7ff }, + /* 0x25c00 */ + { 40708, 0xfa64 }, { 40717, 0xffff }, { 40733, 0xffff }, { 40749, 0xffff }, + { 40765, 0xf0f7 }, { 40776, 0xffff }, { 40792, 0x025f }, { 40799, 0xffe8 }, + { 40811, 0xfff3 }, { 40825, 0xffe7 }, { 40839, 0xdfff }, { 40854, 0x3fff }, + { 40868, 0xffc1 }, { 40879, 0xffff }, { 40895, 0xffff }, { 40911, 0x87ff }, + /* 0x25d00 */ + { 40923, 0xffff }, { 40939, 0xe018 }, { 40944, 0xffff }, { 40960, 0xeff7 }, + { 40974, 0x7ff0 }, { 40985, 0xf009 }, { 40991, 0xffff }, { 41007, 0x2f7f }, + { 41019, 0xfdc0 }, { 41028, 0xffff }, { 41044, 0x0ff8 }, { 41053, 0xfff0 }, + { 41065, 0xf3ff }, { 41079, 0xfff3 }, { 41093, 0xff1f }, { 41106, 0xf1f7 }, + /* 0x25e00 */ + { 41118, 0xcfa9 }, { 41128, 0x13d3 }, { 41136, 0xbbee }, { 41148, 0x7ffb }, + { 41162, 0xffee }, { 41176, 0xf467 }, { 41186, 0x29d7 }, { 41195, 0xfffc }, + { 41209, 0x0bf0 }, { 41216, 0xff80 }, { 41225, 0xff9f }, { 41239, 0x115f }, + { 41247, 0xfffe }, { 41262, 0x1e7f }, { 41273, 0xfff0 }, { 41285, 0x800f }, + /* 0x25f00 */ + { 41290, 0xf3ff }, { 41304, 0xff0f }, { 41316, 0x01f7 }, { 41324, 0xffe0 }, + { 41335, 0x8eef }, { 41346, 0x6fe3 }, { 41357, 0xf0e8 }, { 41365, 0xffdf }, + { 41380, 0xf7f7 }, { 41394, 0x7e5f }, { 41406, 0xffff }, { 41422, 0x0dfd }, + { 41432, 0xfff8 }, { 41445, 0x93ef }, { 41456, 0xffc2 }, { 41467, 0xf7ff }, + /* 0x26000 */ + { 41482, 0x02ff }, { 41491, 0xfffc }, { 41505, 0xf0ff }, { 41517, 0x00ff }, + { 41525, 0xff58 }, { 41536, 0x7fff }, { 41551, 0xfff2 }, { 41564, 0x0013 }, + { 41567, 0xfbff }, { 41582, 0xffbf }, { 41597, 0xffc7 }, { 41610, 0x00b3 }, + { 41615, 0xfffa }, { 41629, 0xfbff }, { 41644, 0x01fd }, { 41652, 0x07ff }, + /* 0x26100 */ + { 41663, 0xfe00 }, { 41670, 0x1fff }, { 41683, 0x7ffc }, { 41696, 0xf006 }, + { 41702, 0xffff }, { 41718, 0xe03f }, { 41727, 0x15bf }, { 41737, 0xffe8 }, + { 41749, 0xff7f }, { 41764, 0xf8ff }, { 41777, 0x9eff }, { 41790, 0xf87f }, + { 41802, 0xdf3f }, { 41815, 0xdffa }, { 41828, 0x1faf }, { 41839, 0xffdf }, + /* 0x26200 */ + { 41854, 0x00eb }, { 41860, 0x0000 }, { 41860, 0xfbec }, { 41872, 0xdf7f }, + { 41886, 0xdbb7 }, { 41898, 0xeeef }, { 41911, 0xfefd }, { 41925, 0xdbbc }, + { 41936, 0xeb8f }, { 41947, 0xf3ff }, { 41961, 0xef9f }, { 41974, 0xf078 }, + { 41982, 0x3ff4 }, { 41993, 0xffc7 }, { 42006, 0xf99f }, { 42018, 0xfbbf }, + /* 0x26300 */ + { 42032, 0xe66f }, { 42043, 0xfaff }, { 42057, 0x7f1f }, { 42069, 0xddfe }, + { 42082, 0xfdcf }, { 42095, 0xfdf7 }, { 42109, 0xf7e6 }, { 42121, 0xfe05 }, + { 42130, 0x2fe9 }, { 42140, 0x27f0 }, { 42148, 0x8afc }, { 42157, 0x9f9b }, + { 42168, 0xffea }, { 42181, 0xf7e3 }, { 42193, 0xaf8f }, { 42204, 0x7ff5 }, + /* 0x26400 */ + { 42217, 0x7ffd }, { 42231, 0x5ffb }, { 42244, 0xf7fc }, { 42257, 0x7fef }, + { 42271, 0xffd1 }, { 42283, 0xff3f }, { 42297, 0x1fff }, { 42310, 0xff7f }, + { 42325, 0xfdf8 }, { 42337, 0xbe7f }, { 42350, 0xf77d }, { 42363, 0x7dce }, + { 42374, 0xd01b }, { 42381, 0x67df }, { 42393, 0xff71 }, { 42405, 0x7fb3 }, + /* 0x26500 */ + { 42417, 0xfa7f }, { 42430, 0xfdbf }, { 42444, 0xbf7f }, { 42458, 0xf3af }, + { 42470, 0xfdbf }, { 42484, 0x7dff }, { 42498, 0xffe7 }, { 42512, 0xffe6 }, + { 42525, 0x7f3d }, { 42537, 0x1fff }, { 42550, 0x9ffc }, { 42562, 0xf27f }, + { 42574, 0x27ff }, { 42586, 0x87ff }, { 42598, 0x9fff }, { 42612, 0x43fe }, + /* 0x26600 */ + { 42622, 0xefff }, { 42637, 0xe93f }, { 42648, 0xff0d }, { 42659, 0xedfc }, + { 42671, 0x2fff }, { 42684, 0x99ff }, { 42696, 0xff87 }, { 42708, 0x9fff }, + { 42722, 0x73ff }, { 42735, 0xff1e }, { 42747, 0x7fff }, { 42762, 0x2ffc }, + { 42773, 0xc03e }, { 42780, 0xfffd }, { 42795, 0x7efb }, { 42808, 0x02d8 }, + /* 0x26700 */ + { 42813, 0xfddc }, { 42825, 0x9fff }, { 42839, 0x17ff }, { 42851, 0xee68 }, + { 42860, 0x8002 }, { 42862, 0xffff }, { 42878, 0xffff }, { 42894, 0xfdff }, + { 42909, 0x0ab3 }, { 42916, 0xfee0 }, { 42926, 0xbfff }, { 42941, 0x3fe7 }, + { 42953, 0x0003 }, { 42955, 0xbb30 }, { 42963, 0xbeff }, { 42977, 0x0019 }, + /* 0x26800 */ + { 42980, 0xffff }, { 42996, 0xd6ff }, { 43009, 0x1b31 }, { 43016, 0xdf80 }, + { 43024, 0xf1ef }, { 43036, 0x19bf }, { 43046, 0x3f00 }, { 43052, 0xfff7 }, + { 43067, 0xf52f }, { 43078, 0x3ff3 }, { 43090, 0xbff0 }, { 43101, 0xbf00 }, + { 43108, 0xbfe3 }, { 43120, 0xfc4f }, { 43131, 0x7a13 }, { 43139, 0xfffe }, + /* 0x26900 */ + { 43154, 0xf47d }, { 43165, 0xef75 }, { 43177, 0x1ffe }, { 43189, 0x9efc }, + { 43200, 0xdff6 }, { 43213, 0xebbf }, { 43226, 0x6be7 }, { 43237, 0xfffc }, + { 43251, 0xd7ff }, { 43265, 0xffeb }, { 43279, 0xfebf }, { 43293, 0xff7f }, + { 43308, 0xd7f7 }, { 43321, 0xa4fb }, { 43331, 0x6dff }, { 43344, 0xdb7b }, + /* 0x26a00 */ + { 43356, 0xfffb }, { 43371, 0xb7fd }, { 43384, 0xf5df }, { 43397, 0xf4f7 }, + { 43409, 0xff98 }, { 43420, 0xf318 }, { 43428, 0x1fff }, { 43441, 0x7ff6 }, + { 43454, 0x6ff0 }, { 43464, 0x3ffe }, { 43477, 0xfeb0 }, { 43487, 0xe1c7 }, + { 43496, 0xddff }, { 43510, 0x7eb7 }, { 43522, 0xbffd }, { 43536, 0xffdf }, + /* 0x26b00 */ + { 43551, 0xfbff }, { 43566, 0xfff9 }, { 43580, 0xfeff }, { 43595, 0xffbf }, + { 43610, 0x0bff }, { 43621, 0x3ff0 }, { 43631, 0xfb04 }, { 43639, 0xffff }, + { 43655, 0xffff }, { 43671, 0xff0f }, { 43683, 0xffff }, { 43699, 0xffa8 }, + { 43710, 0xffff }, { 43726, 0xff7e }, { 43740, 0xff7f }, { 43755, 0xff1f }, + /* 0x26c00 */ + { 43768, 0xffff }, { 43784, 0x6bff }, { 43797, 0xfc82 }, { 43805, 0xffff }, + { 43821, 0xffbf }, { 43836, 0xdfff }, { 43851, 0xffff }, { 43867, 0x1ffd }, + { 43879, 0xfff8 }, { 43892, 0xffff }, { 43908, 0x97ff }, { 43921, 0x20c1 }, + { 43925, 0xffff }, { 43941, 0xffff }, { 43957, 0x7fff }, { 43972, 0xffff }, + /* 0x26d00 */ + { 43988, 0xffa7 }, { 44001, 0xffff }, { 44017, 0xf801 }, { 44023, 0xffff }, + { 44039, 0x7fff }, { 44054, 0xe007 }, { 44060, 0xfffe }, { 44075, 0xffff }, + { 44091, 0xfff7 }, { 44106, 0x0fff }, { 44118, 0xff00 }, { 44126, 0xffff }, + { 44142, 0xffff }, { 44158, 0xefbf }, { 44172, 0x040b }, { 44176, 0xbfff }, + /* 0x26e00 */ + { 44191, 0xffdf }, { 44206, 0xffff }, { 44222, 0xffdf }, { 44237, 0x07ff }, + { 44248, 0xffc0 }, { 44258, 0xffff }, { 44274, 0x451e }, { 44281, 0xe084 }, + { 44286, 0xffd7 }, { 44300, 0xffff }, { 44316, 0xffff }, { 44332, 0xffff }, + { 44348, 0x3fff }, { 44362, 0xff00 }, { 44370, 0xffff }, { 44386, 0xffff }, + /* 0x26f00 */ + { 44402, 0xfcff }, { 44416, 0x0227 }, { 44421, 0xfe16 }, { 44431, 0xffff }, + { 44447, 0xdfff }, { 44462, 0xffff }, { 44478, 0x5fff }, { 44492, 0xffe2 }, + { 44504, 0xffff }, { 44520, 0x8895 }, { 44526, 0xf482 }, { 44533, 0xffff }, + { 44549, 0xff7f }, { 44564, 0x03ff }, { 44574, 0xffff }, { 44590, 0xfe3f }, + /* 0x27000 */ + { 44603, 0x20f7 }, { 44611, 0x2ff0 }, { 44620, 0xffff }, { 44636, 0xffbf }, + { 44651, 0xbfff }, { 44666, 0xfff2 }, { 44679, 0xffff }, { 44695, 0xf801 }, + { 44701, 0xff7f }, { 44716, 0xffff }, { 44732, 0x03ba }, { 44739, 0xffff }, + { 44755, 0xc3ff }, { 44767, 0xffff }, { 44783, 0xdfff }, { 44798, 0xfe01 }, + /* 0x27100 */ + { 44806, 0xeaff }, { 44819, 0xffff }, { 44835, 0x7f0f }, { 44846, 0xffc0 }, + { 44856, 0xffff }, { 44872, 0xffdf }, { 44887, 0xc7c7 }, { 44897, 0x7ddf }, + { 44910, 0xefea }, { 44922, 0x7fff }, { 44937, 0x1ff9 }, { 44948, 0xfc7e }, + { 44960, 0x2ffe }, { 44972, 0xf1bf }, { 44984, 0x3fff }, { 44998, 0xf83e }, + /* 0x27200 */ + { 45008, 0x6bcb }, { 45018, 0xf5ef }, { 45031, 0xffb9 }, { 45044, 0xfff1 }, + { 45057, 0xffff }, { 45073, 0xd9e3 }, { 45083, 0xffff }, { 45099, 0xf8f9 }, + { 45110, 0xe1ef }, { 45121, 0xffff }, { 45137, 0xfbff }, { 45152, 0x9fc3 }, + { 45162, 0xff00 }, { 45170, 0xfbff }, { 45185, 0xff83 }, { 45196, 0x0009 }, + /* 0x27300 */ + { 45198, 0xfffa }, { 45212, 0xbfff }, { 45227, 0x3fdf }, { 45240, 0xaff0 }, + { 45250, 0x0000 }, { 45250, 0xfffe }, { 45265, 0xffff }, { 45281, 0xffff }, + { 45297, 0xff1f }, { 45310, 0xc59f }, { 45320, 0xff7e }, { 45334, 0xffff }, + { 45350, 0xffff }, { 45366, 0xf03f }, { 45376, 0x175f }, { 45386, 0xff00 }, + /* 0x27400 */ + { 45394, 0xfff7 }, { 45409, 0xffff }, { 45425, 0xeff8 }, { 45437, 0x007a }, + { 45442, 0xfff1 }, { 45455, 0xf7ff }, { 45470, 0xffff }, { 45486, 0xff1f }, + { 45499, 0xc15e }, { 45507, 0xfdff }, { 45522, 0x0ffe }, { 45533, 0xfffc }, + { 45547, 0xdf00 }, { 45554, 0xffff }, { 45570, 0x18fe }, { 45579, 0xfffe }, + /* 0x27500 */ + { 45594, 0xc1df }, { 45604, 0xe13f }, { 45614, 0xddff }, { 45628, 0x24ff }, + { 45638, 0xfffe }, { 45653, 0xf9f7 }, { 45666, 0xc1ff }, { 45677, 0xf7ff }, + { 45692, 0xfdf5 }, { 45705, 0xfffe }, { 45720, 0xbf90 }, { 45729, 0x7ffc }, + { 45742, 0xffdf }, { 45757, 0xfff7 }, { 45772, 0xffee }, { 45786, 0x8ffe }, + /* 0x27600 */ + { 45798, 0xef7f }, { 45812, 0xf64f }, { 45823, 0xffff }, { 45839, 0x7cf9 }, + { 45850, 0xffff }, { 45866, 0xff07 }, { 45877, 0xffbf }, { 45892, 0xc2ac }, + { 45899, 0xffff }, { 45915, 0x7fe7 }, { 45928, 0xfffa }, { 45942, 0xf7ff }, + { 45957, 0xe009 }, { 45962, 0xffff }, { 45978, 0x1fff }, { 45991, 0xff0f }, + /* 0x27700 */ + { 46003, 0x2dff }, { 46015, 0xe026 }, { 46021, 0xfaff }, { 46035, 0xe187 }, + { 46043, 0xbfff }, { 46058, 0x0fff }, { 46070, 0xfc0c }, { 46078, 0xffff }, + { 46094, 0xf1c7 }, { 46104, 0xfafd }, { 46117, 0xffc6 }, { 46129, 0x3fef }, + { 46142, 0xf78c }, { 46152, 0xcff7 }, { 46165, 0xefca }, { 46176, 0xff9e }, + /* 0x27800 */ + { 46189, 0xdadf }, { 46201, 0xffef }, { 46216, 0x6f0f }, { 46226, 0xf82f }, + { 46236, 0xf979 }, { 46247, 0x29ef }, { 46257, 0xffff }, { 46273, 0xef8e }, + { 46284, 0xe77f }, { 46297, 0x777c }, { 46308, 0xe9ff }, { 46321, 0xffbe }, + { 46335, 0xe3ff }, { 46348, 0x5fff }, { 46362, 0xff2e }, { 46374, 0x7ff3 }, + /* 0x27900 */ + { 46387, 0xfbf8 }, { 46399, 0xf9ff }, { 46413, 0xdecf }, { 46425, 0xfcc6 }, + { 46435, 0x3517 }, { 46443, 0x3fea }, { 46454, 0xef7e }, { 46467, 0xffbb }, + { 46481, 0xbfc7 }, { 46493, 0xfe84 }, { 46502, 0xffff }, { 46518, 0x4cff }, + { 46529, 0xff76 }, { 46542, 0xffff }, { 46558, 0x0df3 }, { 46567, 0xffff }, + /* 0x27a00 */ + { 46583, 0x8fff }, { 46596, 0x7e7f }, { 46609, 0xffd9 }, { 46622, 0xffff }, + { 46638, 0xfefd }, { 46652, 0xff43 }, { 46663, 0xffff }, { 46679, 0xfffe }, + { 46694, 0xffff }, { 46710, 0xffd7 }, { 46724, 0xffff }, { 46740, 0x86ff }, + { 46751, 0x89ff }, { 46762, 0xfffd }, { 46777, 0xffff }, { 46793, 0xe565 }, + /* 0x27b00 */ + { 46802, 0xfffd }, { 46817, 0xbeef }, { 46830, 0xffbf }, { 46845, 0xf87f }, + { 46857, 0xff7f }, { 46872, 0xff7f }, { 46887, 0xffbf }, { 46902, 0xff97 }, + { 46915, 0xdfff }, { 46930, 0xef7f }, { 46944, 0xfb2c }, { 46954, 0x3def }, + { 46966, 0xfe47 }, { 46977, 0x9f39 }, { 46987, 0xeeef }, { 47000, 0xff9b }, + /* 0x27c00 */ + { 47013, 0x3efb }, { 47025, 0x637f }, { 47036, 0xffab }, { 47049, 0xfff5 }, + { 47063, 0xe7ff }, { 47077, 0xffff }, { 47093, 0xff3f }, { 47107, 0xd9ff }, + { 47120, 0xffff }, { 47136, 0xfdbf }, { 47150, 0xf7ff }, { 47165, 0xc2ff }, + { 47176, 0xffff }, { 47192, 0xfedf }, { 47206, 0xffe7 }, { 47220, 0x5fee }, + /* 0x27d00 */ + { 47232, 0xf0fe }, { 47243, 0xe7f1 }, { 47254, 0x3d7b }, { 47265, 0xffef }, + { 47280, 0xffb7 }, { 47294, 0x37e3 }, { 47304, 0xfff9 }, { 47318, 0xe7f7 }, + { 47331, 0x7fec }, { 47343, 0xff8f }, { 47356, 0x05ff }, { 47366, 0xdfff }, + { 47381, 0xfe9f }, { 47394, 0xd6ff }, { 47407, 0xfbff }, { 47422, 0xf825 }, + /* 0x27e00 */ + { 47430, 0xffff }, { 47446, 0x47f2 }, { 47455, 0xe9ff }, { 47468, 0xf3fe }, + { 47481, 0x43c9 }, { 47488, 0x7f00 }, { 47495, 0xf09b }, { 47504, 0x23fc }, + { 47513, 0xffd0 }, { 47524, 0xefdd }, { 47537, 0xffff }, { 47553, 0xffec }, + { 47566, 0xdfff }, { 47581, 0xbffe }, { 47595, 0xd8ff }, { 47607, 0xbf7f }, + /* 0x27f00 */ + { 47621, 0xc2ff }, { 47632, 0xffff }, { 47648, 0xffef }, { 47663, 0xffff }, + { 47679, 0xfe76 }, { 47691, 0xffff }, { 47707, 0xbfff }, { 47722, 0xffd8 }, + { 47734, 0xe93f }, { 47745, 0xffff }, { 47761, 0xff7f }, { 47776, 0x1f73 }, + { 47786, 0x227f }, { 47795, 0xfffc }, { 47809, 0xc05d }, { 47816, 0xfffe }, + /* 0x28000 */ + { 47831, 0x0249 }, { 47835, 0xfff8 }, { 47848, 0x7fff }, { 47863, 0x00c2 }, + { 47866, 0xffff }, { 47882, 0x5e3f }, { 47893, 0x000d }, { 47896, 0xffe8 }, + { 47908, 0xf9ff }, { 47922, 0xf80a }, { 47929, 0xffff }, { 47945, 0x81ff }, + { 47955, 0x0003 }, { 47957, 0xfffc }, { 47971, 0x51ff }, { 47982, 0x8008 }, + /* 0x28100 */ + { 47984, 0xffe9 }, { 47997, 0x0fff }, { 48009, 0x3ffe }, { 48022, 0x0000 }, + { 48022, 0xdd60 }, { 48030, 0xffff }, { 48046, 0x07ff }, { 48057, 0x0076 }, + { 48062, 0xffff }, { 48078, 0x1df3 }, { 48088, 0xfdc0 }, { 48097, 0x183f }, + { 48105, 0x9dfe }, { 48117, 0x67d0 }, { 48125, 0xeff0 }, { 48136, 0x3c1f }, + /* 0x28200 */ + { 48145, 0xad38 }, { 48153, 0xff3b }, { 48166, 0xfe17 }, { 48177, 0xff37 }, + { 48190, 0xff0d }, { 48201, 0x0bb1 }, { 48208, 0xc1fc }, { 48217, 0x9e0f }, + { 48226, 0xe45b }, { 48235, 0x2bfd }, { 48246, 0x9e9f }, { 48257, 0xfffe }, + { 48272, 0xd0d1 }, { 48279, 0x1fff }, { 48292, 0xffc0 }, { 48302, 0x1277 }, + /* 0x28300 */ + { 48310, 0xeffe }, { 48324, 0xbe40 }, { 48331, 0xffff }, { 48347, 0x79ff }, + { 48360, 0xffef }, { 48375, 0x87df }, { 48386, 0xffa9 }, { 48398, 0x8bdf }, + { 48409, 0x3fbf }, { 48422, 0x136f }, { 48431, 0xfff6 }, { 48445, 0x53ff }, + { 48457, 0xcfe2 }, { 48467, 0xe37e }, { 48478, 0x9f5f }, { 48490, 0x677f }, + /* 0x28400 */ + { 48502, 0xb806 }, { 48508, 0xffb3 }, { 48521, 0xbf17 }, { 48532, 0x7a67 }, + { 48542, 0xafff }, { 48556, 0x4f1f }, { 48566, 0xbfff }, { 48581, 0xf0bf }, + { 48592, 0xfffb }, { 48607, 0x2cf8 }, { 48615, 0xfffd }, { 48630, 0xf00d }, + { 48637, 0x6fbf }, { 48650, 0x2bfc }, { 48660, 0xfff0 }, { 48672, 0xefff }, + /* 0x28500 */ + { 48687, 0xc829 }, { 48693, 0xfeff }, { 48708, 0xffde }, { 48722, 0x0007 }, + { 48725, 0xaffe }, { 48738, 0xfc5b }, { 48749, 0xc7ff }, { 48762, 0x317f }, + { 48772, 0xffca }, { 48784, 0xe3f9 }, { 48795, 0xfc3b }, { 48806, 0xdffb }, + { 48820, 0xf81f }, { 48830, 0xc3bd }, { 48840, 0xffee }, { 48854, 0x3fc3 }, + /* 0x28600 */ + { 48864, 0xf7bf }, { 48878, 0xfe0b }, { 48888, 0x7fcf }, { 48901, 0xb3e5 }, + { 48911, 0xc7ff }, { 48924, 0xd7bf }, { 48937, 0xebd9 }, { 48948, 0x7fe7 }, + { 48961, 0xaefc }, { 48972, 0xfffe }, { 48987, 0xfd25 }, { 48997, 0xbe7f }, + { 49010, 0xffda }, { 49023, 0xde7f }, { 49036, 0xfffb }, { 49051, 0xf9fb }, + /* 0x28700 */ + { 49064, 0xfd6f }, { 49077, 0x9fff }, { 49091, 0xe5ff }, { 49104, 0xfffd }, + { 49119, 0xfe9b }, { 49131, 0xe9bb }, { 49142, 0xfdef }, { 49156, 0xe1fb }, + { 49167, 0xf2bf }, { 49179, 0xdffe }, { 49193, 0xcfc3 }, { 49203, 0xffeb }, + { 49217, 0xe13f }, { 49227, 0xdff3 }, { 49240, 0xd9df }, { 49252, 0xfff7 }, + /* 0x28800 */ + { 49267, 0xfde7 }, { 49280, 0x79ff }, { 49293, 0x40f4 }, { 49299, 0x7fc0 }, + { 49308, 0xf826 }, { 49316, 0x3dfb }, { 49328, 0xfe0d }, { 49338, 0x61ff }, + { 49349, 0xfffb }, { 49364, 0x0e77 }, { 49373, 0xbfff }, { 49388, 0xe66f }, + { 49399, 0x48ff }, { 49409, 0xbffb }, { 49423, 0xefcb }, { 49435, 0xffdf }, + /* 0x28900 */ + { 49450, 0xf7a7 }, { 49462, 0x6fef }, { 49475, 0x376f }, { 49486, 0xc7d0 }, + { 49494, 0xfe1d }, { 49505, 0x03ff }, { 49515, 0xe7f4 }, { 49526, 0x4a6f }, + { 49535, 0xfc74 }, { 49545, 0xf25f }, { 49556, 0xfd09 }, { 49565, 0xc19f }, + { 49574, 0xfffe }, { 49589, 0x1a68 }, { 49595, 0xfff2 }, { 49608, 0xe07f }, + /* 0x28a00 */ + { 49618, 0x7fff }, { 49633, 0x20ff }, { 49642, 0xd220 }, { 49647, 0x7fff }, + { 49662, 0xf000 }, { 49666, 0xf9ff }, { 49680, 0x121f }, { 49687, 0x1620 }, + { 49691, 0xfffe }, { 49706, 0x80df }, { 49714, 0xffff }, { 49730, 0x30c1 }, + { 49735, 0xd840 }, { 49740, 0x037f }, { 49749, 0xffc0 }, { 49759, 0x2bff }, + /* 0x28b00 */ + { 49771, 0xf038 }, { 49778, 0xafdf }, { 49791, 0xc7f8 }, { 49801, 0x7fff }, + { 49816, 0x4290 }, { 49820, 0xffe9 }, { 49833, 0xef84 }, { 49842, 0x50ff }, + { 49852, 0x8019 }, { 49856, 0xccbc }, { 49865, 0x89ff }, { 49876, 0xfb80 }, + { 49884, 0xffd0 }, { 49895, 0xc697 }, { 49904, 0xe04f }, { 49912, 0x5c01 }, + /* 0x28c00 */ + { 49917, 0xfe23 }, { 49927, 0xf7f7 }, { 49941, 0xd315 }, { 49949, 0x394f }, + { 49958, 0x0000 }, { 49958, 0xff80 }, { 49967, 0x0bf4 }, { 49975, 0x86f8 }, + { 49983, 0x3fcf }, { 49995, 0xedb8 }, { 50005, 0xe3e7 }, { 50016, 0x5d5c }, + { 50025, 0xde3f }, { 50037, 0xffeb }, { 50051, 0x3faf }, { 50063, 0xfffd }, + /* 0x28d00 */ + { 50078, 0xe037 }, { 50086, 0xa3ff }, { 50098, 0xff21 }, { 50108, 0x81eb }, + { 50116, 0xbff3 }, { 50129, 0x10ff }, { 50138, 0xfff4 }, { 50151, 0x02ad }, + { 50157, 0xffff }, { 50173, 0xf444 }, { 50180, 0xf0ff }, { 50192, 0x43df }, + { 50202, 0x3efe }, { 50214, 0xfabc }, { 50225, 0x0dde }, { 50234, 0x198f }, + /* 0x28e00 */ + { 50242, 0x8000 }, { 50243, 0x7dff }, { 50257, 0xfa1f }, { 50268, 0x012f }, + { 50274, 0xdffe }, { 50288, 0xff2b }, { 50300, 0xe08f }, { 50308, 0xffef }, + { 50323, 0xfc7f }, { 50336, 0x800f }, { 50341, 0xffff }, { 50357, 0x8032 }, + { 50361, 0xffff }, { 50377, 0xfd7f }, { 50391, 0x8543 }, { 50397, 0xffff }, + /* 0x28f00 */ + { 50413, 0xfd7f }, { 50427, 0xfbff }, { 50442, 0xfc41 }, { 50450, 0xe07b }, + { 50459, 0xf0ff }, { 50471, 0xb3ff }, { 50484, 0x5def }, { 50496, 0xbf7e }, + { 50509, 0xafef }, { 50522, 0x3ffe }, { 50535, 0xcfff }, { 50549, 0xfffc }, + { 50563, 0xfb7f }, { 50577, 0x47ff }, { 50589, 0xffff }, { 50605, 0xe67f }, + /* 0x29000 */ + { 50617, 0xffff }, { 50633, 0xffbf }, { 50648, 0xfff3 }, { 50662, 0xfff3 }, + { 50676, 0xffe7 }, { 50690, 0xfbff }, { 50705, 0x3b9f }, { 50716, 0x7fe5 }, + { 50728, 0x37fc }, { 50739, 0x1dfc }, { 50749, 0x77fe }, { 50762, 0xffac }, + { 50774, 0x17ef }, { 50785, 0x7fff }, { 50800, 0xafcb }, { 50811, 0xf7f0 }, + /* 0x29100 */ + { 50822, 0x221b }, { 50828, 0xffc0 }, { 50838, 0x6aff }, { 50850, 0xff80 }, + { 50859, 0xceff }, { 50872, 0xe00d }, { 50878, 0x3fff }, { 50892, 0xf0c6 }, + { 50900, 0x03ff }, { 50910, 0x8dfe }, { 50921, 0xea70 }, { 50929, 0xa5ef }, + { 50940, 0x5f9f }, { 50952, 0xffbe }, { 50966, 0xffdb }, { 50980, 0xd7ef }, + /* 0x29200 */ + { 50993, 0xf7f8 }, { 51005, 0xbe4e }, { 51015, 0xf9ff }, { 51029, 0x7b7f }, + { 51042, 0x7fbf }, { 51056, 0xee52 }, { 51065, 0x5ffe }, { 51078, 0xff00 }, + { 51086, 0x0b3f }, { 51095, 0xffff }, { 51111, 0xfe60 }, { 51120, 0x938d }, + { 51128, 0xffff }, { 51144, 0xe83f }, { 51154, 0xffff }, { 51170, 0xf77f }, + /* 0x29300 */ + { 51184, 0xfff9 }, { 51198, 0x2cff }, { 51209, 0xffc7 }, { 51222, 0xcecf }, + { 51233, 0xceff }, { 51246, 0xfffe }, { 51261, 0xcff0 }, { 51271, 0xc3be }, + { 51281, 0xffb7 }, { 51295, 0x7fbe }, { 51308, 0xfff2 }, { 51321, 0xffef }, + { 51336, 0xcfeb }, { 51348, 0xcfff }, { 51362, 0xff7f }, { 51377, 0x0ff7 }, + /* 0x29400 */ + { 51388, 0xbebe }, { 51400, 0xdff8 }, { 51412, 0x7dff }, { 51426, 0xdef7 }, + { 51439, 0x3fef }, { 51452, 0xffff }, { 51468, 0x5fff }, { 51482, 0x7fff }, + { 51497, 0x9fff }, { 51511, 0xffff }, { 51527, 0xecd7 }, { 51538, 0xffff }, + { 51554, 0x7f7f }, { 51568, 0xe37a }, { 51578, 0xffff }, { 51594, 0x7dff }, + /* 0x29500 */ + { 51608, 0xffff }, { 51624, 0xfe19 }, { 51634, 0xb3ff }, { 51647, 0xfff9 }, + { 51661, 0xff65 }, { 51673, 0xefff }, { 51688, 0xfa7f }, { 51701, 0xd5fe }, + { 51713, 0xfcdb }, { 51725, 0xbe09 }, { 51733, 0x53fe }, { 51744, 0x7ffd }, + { 51758, 0x3ff2 }, { 51769, 0xeff8 }, { 51781, 0xff0f }, { 51793, 0x0dff }, + /* 0x29600 */ + { 51804, 0xffea }, { 51817, 0xf6ff }, { 51831, 0xe0ff }, { 51842, 0xffff }, + { 51858, 0x477f }, { 51869, 0xfede }, { 51882, 0x0012 }, { 51884, 0x34d6 }, + { 51892, 0xffff }, { 51908, 0x7fec }, { 51920, 0xff19 }, { 51931, 0xafff }, + { 51945, 0xff63 }, { 51957, 0xe8cf }, { 51967, 0xffff }, { 51983, 0xfe0a }, + /* 0x29700 */ + { 51992, 0xffff }, { 52008, 0xfcfd }, { 52021, 0xb004 }, { 52025, 0xffff }, + { 52041, 0x0267 }, { 52047, 0xef80 }, { 52055, 0x5bff }, { 52068, 0xf337 }, + { 52079, 0xffff }, { 52095, 0xc6c3 }, { 52103, 0x7fff }, { 52118, 0xf4a4 }, + { 52126, 0xbfff }, { 52141, 0x2bf8 }, { 52150, 0xe5f8 }, { 52160, 0x01d3 }, + /* 0x29800 */ + { 52166, 0x0000 }, { 52166, 0x1ee3 }, { 52175, 0x1c7c }, { 52183, 0xde85 }, + { 52192, 0x77f7 }, { 52205, 0x6d3f }, { 52216, 0x67b2 }, { 52225, 0xffaf }, + { 52239, 0xf35e }, { 52250, 0xffff }, { 52266, 0xe0eb }, { 52275, 0xffff }, + { 52291, 0x77bf }, { 52304, 0xffe7 }, { 52318, 0xe19f }, { 52328, 0xffff }, + /* 0x29900 */ + { 52344, 0x82d3 }, { 52351, 0xffcd }, { 52364, 0x7fff }, { 52379, 0xe88b }, + { 52387, 0xffff }, { 52403, 0x5ddf }, { 52415, 0xf814 }, { 52422, 0x0c1f }, + { 52429, 0xffff }, { 52445, 0xdaf3 }, { 52456, 0x31ff }, { 52467, 0xffc8 }, + { 52478, 0xcffd }, { 52491, 0x0f71 }, { 52499, 0x003f }, { 52505, 0x0000 }, + /* 0x29a00 */ + { 52505, 0x0000 }, { 52505, 0xf8e6 }, { 52515, 0xf0df }, { 52526, 0xe5ff }, + { 52539, 0xfe4f }, { 52551, 0xffa8 }, { 52562, 0xe04f }, { 52570, 0x637f }, + { 52581, 0xfe7f }, { 52595, 0x1fbf }, { 52607, 0x6fff }, { 52621, 0xdbcc }, + { 52631, 0xde7f }, { 52644, 0xf7a3 }, { 52655, 0xffff }, { 52671, 0xb69b }, + /* 0x29b00 */ + { 52681, 0x8e1b }, { 52689, 0xffff }, { 52705, 0x03c7 }, { 52712, 0xbfff }, + { 52727, 0xff8f }, { 52740, 0xe5ef }, { 52752, 0x6fff }, { 52766, 0xff80 }, + { 52775, 0x3bff }, { 52788, 0xffc0 }, { 52798, 0xc3cf }, { 52808, 0x77ff }, + { 52822, 0xfff8 }, { 52835, 0xf853 }, { 52844, 0x23f1 }, { 52852, 0x8d3f }, + /* 0x29c00 */ + { 52862, 0xfefe }, { 52876, 0xf2ff }, { 52889, 0xffff }, { 52905, 0xd2fe }, + { 52916, 0xffbb }, { 52930, 0xbfdf }, { 52944, 0xbbff }, { 52958, 0xe7bf }, + { 52971, 0xfdff }, { 52986, 0x7ff3 }, { 52999, 0xdfee }, { 53012, 0xfa49 }, + { 53021, 0xfbf7 }, { 53035, 0xbf7f }, { 53049, 0xf7ff }, { 53064, 0xf7e7 }, + /* 0x29d00 */ + { 53077, 0xefc9 }, { 53088, 0xfb7f }, { 53102, 0xef5f }, { 53115, 0xaddf }, + { 53127, 0xfdb7 }, { 53140, 0x0bfb }, { 53150, 0xffff }, { 53166, 0x13fb }, + { 53176, 0x7fff }, { 53191, 0x4c7e }, { 53200, 0xfffd }, { 53215, 0xbfc3 }, + { 53226, 0xf80c }, { 53233, 0xf7ff }, { 53248, 0x507f }, { 53257, 0xffb0 }, + /* 0x29e00 */ + { 53268, 0xffff }, { 53284, 0x9f85 }, { 53293, 0x21a5 }, { 53299, 0xd600 }, + { 53304, 0xffff }, { 53320, 0x5fc7 }, { 53331, 0x0104 }, { 53333, 0xfffe }, + { 53348, 0xe07f }, { 53358, 0x1e7f }, { 53369, 0xe800 }, { 53373, 0x7fff }, + { 53388, 0x2fe0 }, { 53396, 0xff40 }, { 53405, 0x0dff }, { 53416, 0x0174 }, + /* 0x29f00 */ + { 53421, 0x7ffc }, { 53434, 0xf1c7 }, { 53444, 0x7fe3 }, { 53456, 0xf83e }, + { 53466, 0xf11f }, { 53476, 0xfd2b }, { 53487, 0x7fcb }, { 53499, 0x00eb }, + { 53505, 0xa201 }, { 53509, 0xfbff }, { 53524, 0x1eff }, { 53536, 0xffff }, + { 53552, 0x9fff }, { 53566, 0xf8ff }, { 53579, 0x7fff }, { 53594, 0x11fe }, + /* 0x2a000 */ + { 53603, 0xbf83 }, { 53613, 0xeffe }, { 53627, 0x3fff }, { 53641, 0xb5ff }, + { 53654, 0xff01 }, { 53663, 0xffff }, { 53679, 0x7fff }, { 53694, 0xfb85 }, + { 53704, 0xffff }, { 53720, 0xefbb }, { 53733, 0x242a }, { 53738, 0xfff0 }, + { 53750, 0xffff }, { 53766, 0x3dff }, { 53779, 0x86d5 }, { 53787, 0xfe48 }, + /* 0x2a100 */ + { 53796, 0xfeff }, { 53811, 0x599f }, { 53821, 0xfe09 }, { 53830, 0xfbff }, + { 53845, 0x7fff }, { 53860, 0x947e }, { 53869, 0xc002 }, { 53872, 0xffff }, + { 53888, 0x3fff }, { 53902, 0x24f2 }, { 53909, 0xff02 }, { 53918, 0xffff }, + { 53934, 0x065e }, { 53941, 0x35fe }, { 53952, 0xf003 }, { 53958, 0x9fff }, + /* 0x2a200 */ + { 53972, 0x7efa }, { 53984, 0xff0d }, { 53995, 0xcff4 }, { 54006, 0xbfb7 }, + { 54019, 0x0001 }, { 54020, 0xffc0 }, { 54030, 0xe3db }, { 54041, 0x95ef }, + { 54052, 0xfbdf }, { 54066, 0x5bfb }, { 54078, 0xbde3 }, { 54089, 0xfffe }, + { 54104, 0xebf8 }, { 54115, 0x7ff7 }, { 54129, 0xfcae }, { 54140, 0xfd9d }, + /* 0x2a300 */ + { 54152, 0x7fee }, { 54165, 0x3df7 }, { 54177, 0xf17d }, { 54188, 0xf91f }, + { 54199, 0xfaff }, { 54213, 0xfd7f }, { 54227, 0xffff }, { 54243, 0xff7d }, + { 54257, 0xe0df }, { 54267, 0xfcfd }, { 54280, 0xfdff }, { 54295, 0x6e7d }, + { 54306, 0x7fde }, { 54319, 0x7f7a }, { 54331, 0xf1f2 }, { 54341, 0xffdf }, + /* 0x2a400 */ + { 54356, 0xff9d }, { 54369, 0xfbfe }, { 54383, 0x0df3 }, { 54392, 0x831c }, + { 54398, 0x7f1f }, { 54410, 0x7ffc }, { 54423, 0xffea }, { 54436, 0xc09f }, + { 54444, 0x993f }, { 54454, 0xff7f }, { 54469, 0xfe8f }, { 54481, 0xcf31 }, + { 54490, 0xde5b }, { 54501, 0xfdff }, { 54516, 0xf3b6 }, { 54527, 0xfbff }, + /* 0x2a500 */ + { 54542, 0xed77 }, { 54554, 0x39f7 }, { 54565, 0xdffc }, { 54578, 0xfdeb }, + { 54591, 0xff5f }, { 54605, 0xff9e }, { 54618, 0xff92 }, { 54629, 0xefe2 }, + { 54640, 0xf9ef }, { 54653, 0x0dff }, { 54664, 0xc7fe }, { 54676, 0x78f9 }, + { 54686, 0xfef6 }, { 54699, 0xff37 }, { 54712, 0xbfff }, { 54727, 0xffe4 }, + /* 0x2a600 */ + { 54739, 0xec33 }, { 54748, 0x99ff }, { 54760, 0x77f7 }, { 54773, 0xffd5 }, + { 54786, 0xffcf }, { 54800, 0xffcf }, { 54814, 0x56f8 }, { 54823, 0xbbfd }, + { 54836, 0x7b5f }, { 54848, 0xfbee }, { 54861, 0xf9e1 }, { 54871, 0xfffb }, + { 54886, 0xef5f }, { 54899, 0x007f }, +}; +static const Summary16 cns11643_inv_uni2indx_page2f8[34] = { + /* 0x2f800 */ + { 54906, 0xffff }, { 54922, 0xffff }, { 54938, 0xffff }, { 54954, 0xffff }, + { 54970, 0xfffe }, { 54985, 0xffff }, { 55001, 0xffff }, { 55017, 0xffff }, + { 55033, 0xffff }, { 55049, 0xffef }, { 55064, 0xffff }, { 55080, 0xffff }, + { 55096, 0xdfff }, { 55111, 0xffff }, { 55127, 0xffff }, { 55143, 0xffff }, + /* 0x2f900 */ + { 55159, 0xffff }, { 55175, 0xffff }, { 55191, 0xffff }, { 55207, 0xffff }, + { 55223, 0xffff }, { 55239, 0xffff }, { 55255, 0xffff }, { 55271, 0xffff }, + { 55287, 0xffff }, { 55303, 0xffef }, { 55318, 0xffff }, { 55334, 0xfffb }, + { 55349, 0xffff }, { 55365, 0xffef }, { 55380, 0xffff }, { 55396, 0xffff }, + /* 0x2fa00 */ + { 55412, 0xffff }, { 55428, 0x3fff }, +}; + +static int +cns11643_inv_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc >= 0x0000 && wc < 0x0100) + summary = &cns11643_inv_uni2indx_page00[(wc>>4)]; + else if (wc >= 0x0200 && wc < 0x03d0) + summary = &cns11643_inv_uni2indx_page02[(wc>>4)-0x020]; + else if (wc >= 0x2000 && wc < 0x22c0) + summary = &cns11643_inv_uni2indx_page20[(wc>>4)-0x200]; + else if (wc >= 0x2400 && wc < 0x2650) + summary = &cns11643_inv_uni2indx_page24[(wc>>4)-0x240]; + else if (wc >= 0x3000 && wc < 0x9fb0) + summary = &cns11643_inv_uni2indx_page30[(wc>>4)-0x300]; + else if (wc >= 0xfa00 && wc < 0xfa30) + summary = &cns11643_inv_uni2indx_pagefa[(wc>>4)-0xfa0]; + else if (wc >= 0xfe00 && wc < 0xfff0) + summary = &cns11643_inv_uni2indx_pagefe[(wc>>4)-0xfe0]; + else if (wc >= 0x20000 && wc < 0x2a6e0) + summary = &cns11643_inv_uni2indx_page200[(wc>>4)-0x2000]; + else if (wc >= 0x2f800 && wc < 0x2fa20) + summary = &cns11643_inv_uni2indx_page2f8[(wc>>4)-0x2f80]; + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + used += summary->indx; + r[0] = cns11643_inv_2charset[3*used]; + r[1] = cns11643_inv_2charset[3*used+1]; + r[2] = cns11643_inv_2charset[3*used+2]; + return 3; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/config.h b/graf2d/win32gdk/gdk/src/iconv/config.h new file mode 100644 index 0000000000000..fb706d02e667c --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/config.h @@ -0,0 +1,458 @@ +/* config.h.in. Generated from configure.ac by autoheader. */ + +/* Define if the compiler is building for multiple architectures of Apple + platforms at once. */ +#undef AA_APPLE_UNIVERSAL_BUILD + +/* Define to the number of bits in type 'ptrdiff_t'. */ +#undef BITSIZEOF_PTRDIFF_T + +/* Define to the number of bits in type 'sig_atomic_t'. */ +#undef BITSIZEOF_SIG_ATOMIC_T + +/* Define to the number of bits in type 'size_t'. */ +#undef BITSIZEOF_SIZE_T + +/* Define to the number of bits in type 'wchar_t'. */ +#undef BITSIZEOF_WCHAR_T + +/* Define to the number of bits in type 'wint_t'. */ +#undef BITSIZEOF_WINT_T + +/* Define to one of `_getb67', `GETB67', `getb67' for Cray-2 and Cray-YMP + systems. This function is required for `alloca.c' support on those systems. + */ +#undef CRAY_STACKSEG_END + +/* Define to 1 if using `alloca.c'. */ +#undef C_ALLOCA + +/* Define as good substitute value for EILSEQ. */ +//#undef EILSEQ + +/* Define to 1 to enable a few rarely used encodings. */ +#undef ENABLE_EXTRA + +/* Define to 1 if translation of program messages to the user's native + language is requested. */ +#undef ENABLE_NLS + +/* Define to 1 if the package shall run at any location in the filesystem. */ +#undef ENABLE_RELOCATABLE + +/* Define to 1 when using the gnulib module canonicalize-lgpl. */ +#undef GNULIB_CANONICALIZE_LGPL + +/* Define to 1 when using the gnulib module sigpipe. */ +#undef GNULIB_SIGPIPE + +/* Define to 1 if you have `alloca', as a function or macro. */ +#undef HAVE_ALLOCA + +/* Define to 1 if you have <alloca.h> and it should be used (not on Ultrix). + */ +#undef HAVE_ALLOCA_H + +/* Define to 1 if you have the `canonicalize_file_name' function. */ +#undef HAVE_CANONICALIZE_FILE_NAME + +/* Define to 1 if you have the MacOS X function CFLocaleCopyCurrent in the + CoreFoundation framework. */ +#undef HAVE_CFLOCALECOPYCURRENT + +/* Define to 1 if you have the MacOS X function CFPreferencesCopyAppValue in + the CoreFoundation framework. */ +#undef HAVE_CFPREFERENCESCOPYAPPVALUE + +/* Define if the GNU dcgettext() function is already present or preinstalled. + */ +#undef HAVE_DCGETTEXT + +/* Define to 1 if you have the declaration of `canonicalize_file_name', and to + 0 if you don't. */ +#undef HAVE_DECL_CANONICALIZE_FILE_NAME + +/* Define to 1 if you have the declaration of `clearerr_unlocked', and to 0 if + you don't. */ +#undef HAVE_DECL_CLEARERR_UNLOCKED + +/* Define to 1 if you have the declaration of `feof_unlocked', and to 0 if you + don't. */ +#undef HAVE_DECL_FEOF_UNLOCKED + +/* Define to 1 if you have the declaration of `ferror_unlocked', and to 0 if + you don't. */ +#undef HAVE_DECL_FERROR_UNLOCKED + +/* Define to 1 if you have the declaration of `fflush_unlocked', and to 0 if + you don't. */ +#undef HAVE_DECL_FFLUSH_UNLOCKED + +/* Define to 1 if you have the declaration of `fgets_unlocked', and to 0 if + you don't. */ +#undef HAVE_DECL_FGETS_UNLOCKED + +/* Define to 1 if you have the declaration of `fputc_unlocked', and to 0 if + you don't. */ +#undef HAVE_DECL_FPUTC_UNLOCKED + +/* Define to 1 if you have the declaration of `fputs_unlocked', and to 0 if + you don't. */ +#undef HAVE_DECL_FPUTS_UNLOCKED + +/* Define to 1 if you have the declaration of `fread_unlocked', and to 0 if + you don't. */ +#undef HAVE_DECL_FREAD_UNLOCKED + +/* Define to 1 if you have the declaration of `fwrite_unlocked', and to 0 if + you don't. */ +#undef HAVE_DECL_FWRITE_UNLOCKED + +/* Define to 1 if you have the declaration of `getchar_unlocked', and to 0 if + you don't. */ +#undef HAVE_DECL_GETCHAR_UNLOCKED + +/* Define to 1 if you have the declaration of `getc_unlocked', and to 0 if you + don't. */ +#undef HAVE_DECL_GETC_UNLOCKED + +/* Define to 1 if you have the declaration of `putchar_unlocked', and to 0 if + you don't. */ +#undef HAVE_DECL_PUTCHAR_UNLOCKED + +/* Define to 1 if you have the declaration of `putc_unlocked', and to 0 if you + don't. */ +#undef HAVE_DECL_PUTC_UNLOCKED + +/* Define to 1 if you have the declaration of `strerror', and to 0 if you + don't. */ +#undef HAVE_DECL_STRERROR + +/* Define to 1 if you have the declaration of `strerror_r', and to 0 if you + don't. */ +#undef HAVE_DECL_STRERROR_R + +/* Define to 1 if you have the <dlfcn.h> header file. */ +#undef HAVE_DLFCN_H + +/* Define if you have the declaration of environ. */ +#undef HAVE_ENVIRON_DECL + +/* Define to 1 if you have the <errno.h> header file. */ +#undef HAVE_ERRNO_H + +/* Define to 1 if you have the `getcwd' function. */ +#undef HAVE_GETCWD + +/* Define to 1 if you have the `getc_unlocked' function. */ +#undef HAVE_GETC_UNLOCKED + +/* Define if the GNU gettext() function is already present or preinstalled. */ +#undef HAVE_GETTEXT + +/* Define if you have the iconv() function and it works. */ +#undef HAVE_ICONV + +/* Define to 1 if you have the <inttypes.h> header file. */ +#undef HAVE_INTTYPES_H + +/* Define if you have <langinfo.h> and nl_langinfo(CODESET). */ +#undef HAVE_LANGINFO_CODESET + +/* Define to 1 if the system has the type `long long int'. */ +#undef HAVE_LONG_LONG_INT + +/* Define to 1 if you have the <mach-o/dyld.h> header file. */ +#undef HAVE_MACH_O_DYLD_H + +/* Define if the 'malloc' function is POSIX compliant. */ +#undef HAVE_MALLOC_POSIX + +/* Define to 1 if you have the `mbrtowc' function. */ +#undef HAVE_MBRTOWC + +/* Define to 1 if you have the `mbsinit' function. */ +#undef HAVE_MBSINIT + +/* Define to 1 if <wchar.h> declares mbstate_t. */ +#undef HAVE_MBSTATE_T + +/* Define to 1 if you have the <memory.h> header file. */ +#undef HAVE_MEMORY_H + +/* Define to 1 if you have the `pathconf' function. */ +#undef HAVE_PATHCONF + +/* Define to 1 if you have the <random.h> header file. */ +#undef HAVE_RANDOM_H + +/* Define to 1 if you have the `readlink' function. */ +#undef HAVE_READLINK + +/* Define to 1 if you have the <search.h> header file. */ +#undef HAVE_SEARCH_H + +/* Define to 1 if you have the `setenv' function. */ +#undef HAVE_SETENV + +/* Define to 1 if you have the `setlocale' function. */ +#undef HAVE_SETLOCALE + +/* Define to 1 if you have the <signal.h> header file. */ +#undef HAVE_SIGNAL_H + +/* Define to 1 if 'sig_atomic_t' is a signed integer type. */ +#undef HAVE_SIGNED_SIG_ATOMIC_T + +/* Define to 1 if 'wchar_t' is a signed integer type. */ +#undef HAVE_SIGNED_WCHAR_T + +/* Define to 1 if 'wint_t' is a signed integer type. */ +#undef HAVE_SIGNED_WINT_T + +/* Define to 1 if the system has the type `sigset_t'. */ +#undef HAVE_SIGSET_T + +/* Define to 1 if stdbool.h conforms to C99. */ +#undef HAVE_STDBOOL_H + +/* Define to 1 if you have the <stdint.h> header file. */ +#undef HAVE_STDINT_H + +/* Define to 1 if you have the <stdio.h> header file. */ +#undef HAVE_STDIO_H + +/* Define to 1 if you have the <stdlib.h> header file. */ +#undef HAVE_STDLIB_H + +/* Define to 1 if you have the `strerror_r' function. */ +#undef HAVE_STRERROR_R + +/* Define to 1 if you have the <strings.h> header file. */ +#undef HAVE_STRINGS_H + +/* Define to 1 if you have the <string.h> header file. */ +#undef HAVE_STRING_H + +/* Define to 1 if the system has the type `struct random_data'. */ +#undef HAVE_STRUCT_RANDOM_DATA + +/* Define to 1 if you have the <sys/bitypes.h> header file. */ +#undef HAVE_SYS_BITYPES_H + +/* Define to 1 if you have the <sys/inttypes.h> header file. */ +#undef HAVE_SYS_INTTYPES_H + +/* Define to 1 if you have the <sys/param.h> header file. */ +#undef HAVE_SYS_PARAM_H + +/* Define to 1 if you have the <sys/socket.h> header file. */ +#undef HAVE_SYS_SOCKET_H + +/* Define to 1 if you have the <sys/stat.h> header file. */ +#undef HAVE_SYS_STAT_H + +/* Define to 1 if you have the <sys/types.h> header file. */ +#undef HAVE_SYS_TYPES_H + +/* Define to 1 if you have the `tsearch' function. */ +#undef HAVE_TSEARCH + +/* Define to 1 if you have the <unistd.h> header file. */ +#undef HAVE_UNISTD_H + +/* Define to 1 if the system has the type `unsigned long long int'. */ +#undef HAVE_UNSIGNED_LONG_LONG_INT + +/* Define to 1 or 0, depending whether the compiler supports simple visibility + declarations. */ +#undef HAVE_VISIBILITY + +/* Define to 1 if you have the <wchar.h> header file. */ +#undef HAVE_WCHAR_H + +/* Define if you have the 'wchar_t' type. */ +#undef HAVE_WCHAR_T + +/* Define to 1 if you have the `wcrtomb' function. */ +#undef HAVE_WCRTOMB + +/* Define to 1 if you have the <winsock2.h> header file. */ +#undef HAVE_WINSOCK2_H + +/* Define if you have the 'wint_t' type. */ +#undef HAVE_WINT_T + +/* Define to 1 if the system has the type `_Bool'. */ +#undef HAVE__BOOL + +/* Define to 1 if you have the `_NSGetExecutablePath' function. */ +#undef HAVE__NSGETEXECUTABLEPATH + +/* Define as const if the declaration of iconv() needs const. */ +#undef ICONV_CONST + +/* Define to the value of ${prefix}, as a string. */ +#undef INSTALLPREFIX + +/* Define to the sub-directory in which libtool stores uninstalled libraries. + */ +#undef LT_OBJDIR + +/* If malloc(0) is != NULL, define this to 1. Otherwise define this to 0. */ +#undef MALLOC_0_IS_NONNULL + +/* Define to 1 if your C compiler doesn't accept -c and -o together. */ +#undef NO_MINUS_C_MINUS_O + +/* Name of package */ +#undef PACKAGE + +/* Define to the address where bug reports for this package should be sent. */ +#undef PACKAGE_BUGREPORT + +/* Define to the full name of this package. */ +#undef PACKAGE_NAME + +/* Define to the full name and version of this package. */ +#undef PACKAGE_STRING + +/* Define to the one symbol short name of this package. */ +#undef PACKAGE_TARNAME + +/* Define to the version of this package. */ +#undef PACKAGE_VERSION + +/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type + 'ptrdiff_t'. */ +#undef PTRDIFF_T_SUFFIX + +/* Define this to 1 if strerror is broken. */ +#undef REPLACE_STRERROR + +/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type + 'sig_atomic_t'. */ +#undef SIG_ATOMIC_T_SUFFIX + +/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type + 'size_t'. */ +#undef SIZE_T_SUFFIX + +/* If using the C implementation of alloca, define if you know the + direction of stack growth for your system; otherwise it will be + automatically deduced at runtime. + STACK_DIRECTION > 0 => grows toward higher addresses + STACK_DIRECTION < 0 => grows toward lower addresses + STACK_DIRECTION = 0 => direction of growth unknown */ +#undef STACK_DIRECTION + +/* Define to 1 if you have the ANSI C header files. */ +#undef STDC_HEADERS + +/* Define to 1 if strerror_r returns char *. */ +#undef STRERROR_R_CHAR_P + +/* Define to 1 if you want getc etc. to use unlocked I/O if available. + Unlocked I/O can improve performance in unithreaded apps, but it is not + safe for multithreaded apps. */ +#undef USE_UNLOCKED_IO + +/* Version number of package */ +#undef VERSION + +/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type + 'wchar_t'. */ +#undef WCHAR_T_SUFFIX + +/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type + 'wint_t'. */ +#undef WINT_T_SUFFIX + +/* Define if the machine's byte ordering is little endian. */ +#undef WORDS_LITTLEENDIAN + +/* Define to 1 if on MINIX. */ +#undef _MINIX + +/* Define to 2 if the system does not provide POSIX.1 features except with + this defined. */ +#undef _POSIX_1_SOURCE + +/* Define to 1 if you need to in order for `stat' and other things to work. */ +#undef _POSIX_SOURCE + +/* Define to 500 only on HP-UX. */ +#undef _XOPEN_SOURCE + +/* Enable extensions on AIX 3, Interix. */ +#ifndef _ALL_SOURCE +# undef _ALL_SOURCE +#endif +/* Enable GNU extensions on systems that have them. */ +#ifndef _GNU_SOURCE +# undef _GNU_SOURCE +#endif +/* Enable threading extensions on Solaris. */ +#ifndef _POSIX_PTHREAD_SEMANTICS +# undef _POSIX_PTHREAD_SEMANTICS +#endif +/* Enable extensions on HP NonStop. */ +#ifndef _TANDEM_SOURCE +# undef _TANDEM_SOURCE +#endif +/* Enable general extensions on Solaris. */ +#ifndef __EXTENSIONS__ +# undef __EXTENSIONS__ +#endif + + +/* Work around a bug in Apple GCC 4.0.1 build 5465: In C99 mode, it supports + the ISO C 99 semantics of 'extern inline' (unlike the GNU C semantics of + earlier versions), but does not display it by setting __GNUC_STDC_INLINE__. + __APPLE__ && __MACH__ test for MacOS X. + __APPLE_CC__ tests for the Apple compiler and its version. + __STDC_VERSION__ tests for the C99 mode. */ +#if defined __APPLE__ && defined __MACH__ && __APPLE_CC__ >= 5465 && !defined __cplusplus && __STDC_VERSION__ >= 199901L && !defined __GNUC_STDC_INLINE__ +# define __GNUC_STDC_INLINE__ 1 +#endif + +/* Define to a type if <wchar.h> does not define. */ +#undef mbstate_t + +/* Define to a replacement function name for realpath(). */ +#undef realpath + +/* Define to the equivalent of the C99 'restrict' keyword, or to + nothing if this is not supported. Do not define if restrict is + supported directly. */ +#undef restrict +/* Work around a bug in Sun C++: it does not support _Restrict, even + though the corresponding Sun C compiler does, which causes + "#define restrict _Restrict" in the previous line. Perhaps some future + version of Sun C++ will work with _Restrict; if so, it'll probably + define __RESTRICT, just as Sun C does. */ +#if defined __SUNPRO_CC && !defined __RESTRICT +# define _Restrict +#endif + +/* Define as a signed type of the same size as size_t. */ +#undef ssize_t + +/* Define as a marker that can be attached to function parameter declarations + for parameters that are not used. This helps to reduce warnings, such as + from GCC -Wunused-parameter. */ +#if __GNUC__ >= 3 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 7) +# define _UNUSED_PARAMETER_ __attribute__ ((__unused__)) +#else +# define _UNUSED_PARAMETER_ +#endif + + + +/* On Windows, variables that may be in a DLL must be marked specially. */ +#if defined _MSC_VER && defined _DLL +# define DLL_VARIABLE __declspec (dllimport) +#else +# define DLL_VARIABLE +#endif + diff --git a/graf2d/win32gdk/gdk/src/iconv/converters.h b/graf2d/win32gdk/gdk/src/iconv/converters.h new file mode 100644 index 0000000000000..f2cd366978baf --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/converters.h @@ -0,0 +1,297 @@ +/* + * Copyright (C) 1999-2002, 2004-2009 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* This file defines all the converters. */ + + +/* Our own notion of wide character, as UCS-4, according to ISO-10646-1. */ +typedef unsigned int ucs4_t; + +/* State used by a conversion. 0 denotes the initial state. */ +typedef unsigned int state_t; + +/* iconv_t is an opaque type. This is the real iconv_t type. */ +typedef struct conv_struct * conv_t; + +/* + * Data type for conversion multibyte -> unicode + */ +struct mbtowc_funcs { + int (*xxx_mbtowc) (conv_t conv, ucs4_t *pwc, unsigned char const *s, int n); + /* + * int xxx_mbtowc (conv_t conv, ucs4_t *pwc, unsigned char const *s, int n) + * converts the byte sequence starting at s to a wide character. Up to n bytes + * are available at s. n is >= 1. + * Result is number of bytes consumed (if a wide character was read), + * or -1 if invalid, or -2 if n too small, or -2-(number of bytes consumed) + * if only a shift sequence was read. + */ + int (*xxx_flushwc) (conv_t conv, ucs4_t *pwc); + /* + * int xxx_flushwc (conv_t conv, ucs4_t *pwc) + * returns to the initial state and stores the pending wide character, if any. + * Result is 1 (if a wide character was read) or 0 if none was pending. + */ +}; + +/* Return code if invalid input after a shift sequence of n bytes was read. + (xxx_mbtowc) */ +#define RET_SHIFT_ILSEQ(n) (-1-2*(n)) +/* Return code if invalid. (xxx_mbtowc) */ +#define RET_ILSEQ RET_SHIFT_ILSEQ(0) +/* Return code if only a shift sequence of n bytes was read. (xxx_mbtowc) */ +#define RET_TOOFEW(n) (-2-2*(n)) +/* Retrieve the n from the encoded RET_... value. */ +#define DECODE_SHIFT_ILSEQ(r) ((unsigned int)(RET_SHIFT_ILSEQ(0) - (r)) / 2) +#define DECODE_TOOFEW(r) ((unsigned int)(RET_TOOFEW(0) - (r)) / 2) + +/* + * Data type for conversion unicode -> multibyte + */ +struct wctomb_funcs { + int (*xxx_wctomb) (conv_t conv, unsigned char *r, ucs4_t wc, int n); + /* + * int xxx_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) + * converts the wide character wc to the character set xxx, and stores the + * result beginning at r. Up to n bytes may be written at r. n is >= 1. + * Result is number of bytes written, or -1 if invalid, or -2 if n too small. + */ + int (*xxx_reset) (conv_t conv, unsigned char *r, int n); + /* + * int xxx_reset (conv_t conv, unsigned char *r, int n) + * stores a shift sequences returning to the initial state beginning at r. + * Up to n bytes may be written at r. n is >= 0. + * Result is number of bytes written, or -2 if n too small. + */ +}; + +/* Return code if invalid. (xxx_wctomb) */ +#define RET_ILUNI -1 +/* Return code if output buffer is too small. (xxx_wctomb, xxx_reset) */ +#define RET_TOOSMALL -2 + +/* + * Contents of a conversion descriptor. + */ +struct conv_struct { + struct loop_funcs lfuncs; + /* Input (conversion multibyte -> unicode) */ + int iindex; + struct mbtowc_funcs ifuncs; + state_t istate; + /* Output (conversion unicode -> multibyte) */ + int oindex; + struct wctomb_funcs ofuncs; + int oflags; + state_t ostate; + /* Operation flags */ + int transliterate; + int discard_ilseq; + #ifndef LIBICONV_PLUG + struct iconv_fallbacks fallbacks; + struct iconv_hooks hooks; + #endif +}; + +/* + * Include all the converters. + */ + +#include "ascii.h" + +/* General multi-byte encodings */ +#include "utf8.h" +#include "ucs2.h" +#include "ucs2be.h" +#include "ucs2le.h" +#include "ucs4.h" +#include "ucs4be.h" +#include "ucs4le.h" +#include "utf16.h" +#include "utf16be.h" +#include "utf16le.h" +#include "utf32.h" +#include "utf32be.h" +#include "utf32le.h" +#include "utf7.h" +#include "ucs2internal.h" +#include "ucs2swapped.h" +#include "ucs4internal.h" +#include "ucs4swapped.h" +#include "c99.h" +#include "java.h" + +/* 8-bit encodings */ +#include "iso8859_1.h" +#include "iso8859_2.h" +#include "iso8859_3.h" +#include "iso8859_4.h" +#include "iso8859_5.h" +#include "iso8859_6.h" +#include "iso8859_7.h" +#include "iso8859_8.h" +#include "iso8859_9.h" +#include "iso8859_10.h" +#include "iso8859_11.h" +#include "iso8859_13.h" +#include "iso8859_14.h" +#include "iso8859_15.h" +#include "iso8859_16.h" +#include "koi8_r.h" +#include "koi8_u.h" +#include "koi8_ru.h" +#include "cp1250.h" +#include "cp1251.h" +#include "cp1252.h" +#include "cp1253.h" +#include "cp1254.h" +#include "cp1255.h" +#include "cp1256.h" +#include "cp1257.h" +#include "cp1258.h" +#include "cp850.h" +#include "cp862.h" +#include "cp866.h" +#include "cp1131.h" +#include "mac_roman.h" +#include "mac_centraleurope.h" +#include "mac_iceland.h" +#include "mac_croatian.h" +#include "mac_romania.h" +#include "mac_cyrillic.h" +#include "mac_ukraine.h" +#include "mac_greek.h" +#include "mac_turkish.h" +#include "mac_hebrew.h" +#include "mac_arabic.h" +#include "mac_thai.h" +#include "hp_roman8.h" +#include "nextstep.h" +#include "armscii_8.h" +#include "georgian_academy.h" +#include "georgian_ps.h" +#include "koi8_t.h" +#include "pt154.h" +#include "rk1048.h" +#include "mulelao.h" +#include "cp1133.h" +#include "tis620.h" +#include "cp874.h" +#include "viscii.h" +#include "tcvn.h" + +/* CJK character sets [CCS = coded character set] [CJKV.INF chapter 3] */ + +typedef struct { + unsigned short indx; /* index into big table */ + unsigned short used; /* bitmask of used entries */ +} Summary16; + +#include "iso646_jp.h" +#include "jisx0201.h" +#include "jisx0208.h" +#include "jisx0212.h" + +#include "iso646_cn.h" +#include "gb2312.h" +#include "isoir165.h" +/*#include "gb12345.h"*/ +#include "gbk.h" +#include "cns11643.h" +#include "big5.h" + +#include "ksc5601.h" +#include "johab_hangul.h" + +/* CJK encodings [CES = character encoding scheme] [CJKV.INF chapter 4] */ + +#include "euc_jp.h" +#include "sjis.h" +#include "cp932.h" +#include "iso2022_jp.h" +#include "iso2022_jp1.h" +#include "iso2022_jp2.h" + +#include "euc_cn.h" +#include "ces_gbk.h" +#include "cp936.h" +#include "gb18030.h" +#include "iso2022_cn.h" +#include "iso2022_cnext.h" +#include "hz.h" +#include "euc_tw.h" +#include "ces_big5.h" +#include "cp950.h" +#include "big5hkscs1999.h" +#include "big5hkscs2001.h" +#include "big5hkscs2004.h" + +#include "euc_kr.h" +#include "cp949.h" +#include "johab.h" +#include "iso2022_kr.h" + +/* Encodings used by system dependent locales. */ + +#ifdef USE_AIX +#include "cp856.h" +#include "cp922.h" +#include "cp943.h" +#include "cp1046.h" +#include "cp1124.h" +#include "cp1129.h" +#include "cp1161.h" +#include "cp1162.h" +#include "cp1163.h" +#endif + +#ifdef USE_OSF1 +#include "dec_kanji.h" +#include "dec_hanyu.h" +#endif + +#ifdef USE_DOS +#include "cp437.h" +#include "cp737.h" +#include "cp775.h" +#include "cp852.h" +#include "cp853.h" +#include "cp855.h" +#include "cp857.h" +#include "cp858.h" +#include "cp860.h" +#include "cp861.h" +#include "cp863.h" +#include "cp864.h" +#include "cp865.h" +#include "cp869.h" +#include "cp1125.h" +#endif + +#ifdef USE_EXTRA +#include "euc_jisx0213.h" +#include "shift_jisx0213.h" +#include "iso2022_jp3.h" +#include "big5_2003.h" +#include "tds565.h" +#include "atarist.h" +#include "riscos1.h" +#endif + diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1046.h b/graf2d/win32gdk/gdk/src/iconv/cp1046.h new file mode 100644 index 0000000000000..b6716b73db328 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1046.h @@ -0,0 +1,157 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1046 + */ + +static const unsigned short cp1046_2uni[128] = { + /* 0x80 */ + 0xfe88, 0x00d7, 0x00f7, 0xf8f6, 0xf8f5, 0xf8f4, 0xf8f7, 0xfe71, + 0x0088, 0x25a0, 0x2502, 0x2500, 0x2510, 0x250c, 0x2514, 0x2518, + /* 0x90 */ + 0xfe79, 0xfe7b, 0xfe7d, 0xfe7f, 0xfe77, 0xfe8a, 0xfef0, 0xfef3, + 0xfef2, 0xfece, 0xfecf, 0xfed0, 0xfef6, 0xfef8, 0xfefa, 0xfefc, + /* 0xa0 */ + 0x00a0, 0xf8fa, 0xf8f9, 0xf8f8, 0x00a4, 0xf8fb, 0xfe8b, 0xfe91, + 0xfe97, 0xfe9b, 0xfe9f, 0xfea3, 0x060c, 0x00ad, 0xfea7, 0xfeb3, + /* 0xb0 */ + 0x0660, 0x0661, 0x0662, 0x0663, 0x0664, 0x0665, 0x0666, 0x0667, + 0x0668, 0x0669, 0xfeb7, 0x061b, 0xfebb, 0xfebf, 0xfeca, 0x061f, + /* 0xc0 */ + 0xfecb, 0x0621, 0x0622, 0x0623, 0x0624, 0x0625, 0x0626, 0x0627, + 0x0628, 0x0629, 0x062a, 0x062b, 0x062c, 0x062d, 0x062e, 0x062f, + /* 0xd0 */ + 0x0630, 0x0631, 0x0632, 0x0633, 0x0634, 0x0635, 0x0636, 0x0637, + 0xfec7, 0x0639, 0x063a, 0xfecc, 0xfe82, 0xfe84, 0xfe8e, 0xfed3, + /* 0xe0 */ + 0x0640, 0x0641, 0x0642, 0x0643, 0x0644, 0x0645, 0x0646, 0x0647, + 0x0648, 0x0649, 0x064a, 0x064b, 0x064c, 0x064d, 0x064e, 0x064f, + /* 0xf0 */ + 0x0650, 0x0651, 0x0652, 0xfed7, 0xfedb, 0xfedf, 0xf8fc, 0xfef5, + 0xfef7, 0xfef9, 0xfefb, 0xfee3, 0xfee7, 0xfeec, 0xfee9, 0xfffd, +}; + +static int +cp1046_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp1046_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp1046_page00[112] = { + 0x88, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xa0, 0x00, 0x00, 0x00, 0xa4, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xad, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x82, /* 0xf0-0xf7 */ +}; +static const unsigned char cp1046_page06[104] = { + 0x00, 0x00, 0x00, 0x00, 0xac, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0xbb, 0x00, 0x00, 0x00, 0xbf, /* 0x18-0x1f */ + 0x00, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x20-0x27 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x28-0x2f */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0x30-0x37 */ + 0x00, 0xd9, 0xda, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x40-0x47 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x48-0x4f */ + 0xf0, 0xf1, 0xf2, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, /* 0x60-0x67 */ + 0xb8, 0xb9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ +}; +static const unsigned char cp1046_page25[32] = { + 0x8b, 0x00, 0x8a, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x8d, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x8c, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x8f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ +}; +static const unsigned char cp1046_pagef8[16] = { + 0x00, 0x00, 0x00, 0x00, 0x85, 0x84, 0x83, 0x86, /* 0xf0-0xf7 */ + 0xa3, 0xa2, 0xa1, 0xa5, 0xf6, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; +static const unsigned char cp1046_pagefe[144] = { + 0x00, 0x87, 0x00, 0x00, 0x00, 0x00, 0x00, 0x94, /* 0x70-0x77 */ + 0x00, 0x90, 0x00, 0x91, 0x00, 0x92, 0x00, 0x93, /* 0x78-0x7f */ + 0x00, 0x00, 0xdc, 0x00, 0xdd, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x80, 0x00, 0x95, 0xa6, 0x00, 0x00, 0xde, 0x00, /* 0x88-0x8f */ + 0x00, 0xa7, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa8, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0xa9, 0x00, 0x00, 0x00, 0xaa, /* 0x98-0x9f */ + 0x00, 0x00, 0x00, 0xab, 0x00, 0x00, 0x00, 0xae, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0xaf, 0x00, 0x00, 0x00, 0xba, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xbc, 0x00, 0x00, 0x00, 0xbd, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd8, /* 0xc0-0xc7 */ + 0x00, 0x00, 0xbe, 0xc0, 0xdb, 0x00, 0x99, 0x9a, /* 0xc8-0xcf */ + 0x9b, 0x00, 0x00, 0xdf, 0x00, 0x00, 0x00, 0xf3, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0xf4, 0x00, 0x00, 0x00, 0xf5, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0xfb, 0x00, 0x00, 0x00, 0xfc, /* 0xe0-0xe7 */ + 0x00, 0xfe, 0x00, 0x00, 0xfd, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x96, 0x00, 0x98, 0x97, 0x00, 0xf7, 0x9c, 0xf8, /* 0xf0-0xf7 */ + 0x9d, 0xf9, 0x9e, 0xfa, 0x9f, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; + +static int +cp1046_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x0088 && wc < 0x00f8) + c = cp1046_page00[wc-0x0088]; + else if (wc >= 0x0608 && wc < 0x0670) + c = cp1046_page06[wc-0x0608]; + else if (wc >= 0x2500 && wc < 0x2520) + c = cp1046_page25[wc-0x2500]; + else if (wc == 0x25a0) + c = 0x89; + else if (wc >= 0xf8f0 && wc < 0xf900) + c = cp1046_pagef8[wc-0xf8f0]; + else if (wc >= 0xfe70 && wc < 0xff00) + c = cp1046_pagefe[wc-0xfe70]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1124.h b/graf2d/win32gdk/gdk/src/iconv/cp1124.h new file mode 100644 index 0000000000000..8b97a7e85153b --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1124.h @@ -0,0 +1,102 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1124 + */ + +static const unsigned short cp1124_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x0401, 0x0402, 0x0490, 0x0404, 0x0405, 0x0406, 0x0407, + 0x0408, 0x0409, 0x040a, 0x040b, 0x040c, 0x00ad, 0x040e, 0x040f, + /* 0xb0 */ + 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, + 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, 0x041f, + /* 0xc0 */ + 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, 0x0427, + 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, 0x042f, + /* 0xd0 */ + 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0436, 0x0437, + 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, + /* 0xe0 */ + 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, + 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x044f, + /* 0xf0 */ + 0x2116, 0x0451, 0x0452, 0x0491, 0x0454, 0x0455, 0x0456, 0x0457, + 0x0458, 0x0459, 0x045a, 0x045b, 0x045c, 0x00a7, 0x045e, 0x045f, +}; + +static int +cp1124_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp1124_2uni[c-0xa0]; + return 1; +} + +static const unsigned char cp1124_page00[16] = { + 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfd, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xad, 0x00, 0x00, /* 0xa8-0xaf */ +}; +static const unsigned char cp1124_page04[152] = { + 0x00, 0xa1, 0xa2, 0x00, 0xa4, 0xa5, 0xa6, 0xa7, /* 0x00-0x07 */ + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0x00, 0xae, 0xaf, /* 0x08-0x0f */ + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, /* 0x10-0x17 */ + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, /* 0x18-0x1f */ + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x20-0x27 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x28-0x2f */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0x30-0x37 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xdf, /* 0x38-0x3f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x40-0x47 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x48-0x4f */ + 0x00, 0xf1, 0xf2, 0x00, 0xf4, 0xf5, 0xf6, 0xf7, /* 0x50-0x57 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0x00, 0xfe, 0xff, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xa3, 0xf3, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; + +static int +cp1124_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00b0) + c = cp1124_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x0498) + c = cp1124_page04[wc-0x0400]; + else if (wc == 0x2116) + c = 0xf0; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1125.h b/graf2d/win32gdk/gdk/src/iconv/cp1125.h new file mode 100644 index 0000000000000..802f0742d6c7b --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1125.h @@ -0,0 +1,129 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1125 + */ + +static const unsigned short cp1125_2uni[80] = { + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, + 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, + /* 0xd0 */ + 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, + 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, + /* 0xe0 */ + 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, + 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x044f, + /* 0xf0 */ + 0x0401, 0x0451, 0x0490, 0x0491, 0x0404, 0x0454, 0x0406, 0x0456, + 0x0407, 0x0457, 0x00b7, 0x221a, 0x2116, 0x00a4, 0x25a0, 0x00a0, +}; + +static int +cp1125_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else if (c < 0xb0) + *pwc = (ucs4_t) c + 0x0390; + else + *pwc = (ucs4_t) cp1125_2uni[c-0xb0]; + return 1; +} + +static const unsigned char cp1125_page00[24] = { + 0xff, 0x00, 0x00, 0x00, 0xfd, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfa, /* 0xb0-0xb7 */ +}; +static const unsigned char cp1125_page04[152] = { + 0x00, 0xf0, 0x00, 0x00, 0xf4, 0x00, 0xf6, 0xf8, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, /* 0x10-0x17 */ + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, /* 0x18-0x1f */ + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, /* 0x20-0x27 */ + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, /* 0x28-0x2f */ + 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, /* 0x30-0x37 */ + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, /* 0x38-0x3f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x40-0x47 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x48-0x4f */ + 0x00, 0xf1, 0x00, 0x00, 0xf5, 0x00, 0xf7, 0xf9, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xf2, 0xf3, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char cp1125_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0xd5, 0xd6, 0xc9, 0xb8, 0xb7, 0xbb, /* 0x50-0x57 */ + 0xd4, 0xd3, 0xc8, 0xbe, 0xbd, 0xbc, 0xc6, 0xc7, /* 0x58-0x5f */ + 0xcc, 0xb5, 0xb6, 0xb9, 0xd1, 0xd2, 0xcb, 0xcf, /* 0x60-0x67 */ + 0xd0, 0xca, 0xd8, 0xd7, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0xdd, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xde, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp1125_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00b8) + c = cp1125_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x0498) + c = cp1125_page04[wc-0x0400]; + else if (wc == 0x2116) + c = 0xfc; + else if (wc == 0x221a) + c = 0xfb; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp1125_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1129.h b/graf2d/win32gdk/gdk/src/iconv/cp1129.h new file mode 100644 index 0000000000000..1b7cff8594369 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1129.h @@ -0,0 +1,121 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1129 + */ + +static const unsigned short cp1129_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, + 0x0153, 0x00a9, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x0178, 0x00b5, 0x00b6, 0x00b7, + 0x0152, 0x00b9, 0x00ba, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf, + /* 0xc0 */ + 0x00c0, 0x00c1, 0x00c2, 0x0102, 0x00c4, 0x00c5, 0x00c6, 0x00c7, + 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x0300, 0x00cd, 0x00ce, 0x00cf, + /* 0xd0 */ + 0x0110, 0x00d1, 0x0309, 0x00d3, 0x00d4, 0x01a0, 0x00d6, 0x00d7, + 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x01af, 0x0303, 0x00df, + /* 0xe0 */ + 0x00e0, 0x00e1, 0x00e2, 0x0103, 0x00e4, 0x00e5, 0x00e6, 0x00e7, + 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x0301, 0x00ed, 0x00ee, 0x00ef, + /* 0xf0 */ + 0x0111, 0x00f1, 0x0323, 0x00f3, 0x00f4, 0x01a1, 0x00f6, 0x00f7, + 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x01b0, 0x20ab, 0x00ff, +}; + +static int +cp1129_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp1129_2uni[c-0xa0]; + return 1; +} + +static const unsigned char cp1129_page00[272] = { + 0x00, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0xb2, 0xb3, 0x00, 0xb5, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0x00, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, /* 0xb8-0xbf */ + 0xc0, 0xc1, 0xc2, 0x00, 0xc4, 0xc5, 0xc6, 0xc7, /* 0xc0-0xc7 */ + 0xc8, 0xc9, 0xca, 0xcb, 0x00, 0xcd, 0xce, 0xcf, /* 0xc8-0xcf */ + 0x00, 0xd1, 0x00, 0xd3, 0xd4, 0x00, 0xd6, 0xd7, /* 0xd0-0xd7 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0x00, 0x00, 0xdf, /* 0xd8-0xdf */ + 0xe0, 0xe1, 0xe2, 0x00, 0xe4, 0xe5, 0xe6, 0xe7, /* 0xe0-0xe7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0x00, 0xed, 0xee, 0xef, /* 0xe8-0xef */ + 0x00, 0xf1, 0x00, 0xf3, 0xf4, 0x00, 0xf6, 0xf7, /* 0xf0-0xf7 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0x00, 0x00, 0xff, /* 0xf8-0xff */ + /* 0x0100 */ + 0x00, 0x00, 0xc3, 0xe3, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xd0, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0xb8, 0xa8, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0xb4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xd5, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xdd, /* 0xa8-0xaf */ + 0xfd, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ +}; +static const unsigned char cp1129_page03[40] = { + 0xcc, 0xec, 0x00, 0xde, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0xd2, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0xf2, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; + +static int +cp1129_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a8) { + *r = wc; + return 1; + } + else if (wc >= 0x00a8 && wc < 0x01b8) + c = cp1129_page00[wc-0x00a8]; + else if (wc >= 0x0300 && wc < 0x0328) + c = cp1129_page03[wc-0x0300]; + else if (wc == 0x20ab) + c = 0xfe; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1131.h b/graf2d/win32gdk/gdk/src/iconv/cp1131.h new file mode 100644 index 0000000000000..15f4ed2accf54 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1131.h @@ -0,0 +1,132 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1131 + */ + +static const unsigned short cp1131_2uni[128] = { + /* 0x80 */ + 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, + 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, 0x041f, + /* 0x90 */ + 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, 0x0427, + 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, 0x042f, + /* 0xa0 */ + 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0436, 0x0437, + 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, + 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, + /* 0xd0 */ + 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, + 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, + /* 0xe0 */ + 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, + 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x044f, + /* 0xf0 */ + 0x0401, 0x0451, 0x0404, 0x0454, 0x0407, 0x0457, 0x040e, 0x045e, + 0x0406, 0x0456, 0x00b7, 0x00a4, 0x0490, 0x0491, 0x2219, 0x00a0, +}; + +static int +cp1131_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp1131_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp1131_page00[24] = { + 0xff, 0x00, 0x00, 0x00, 0xfb, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfa, /* 0xb0-0xb7 */ +}; +static const unsigned char cp1131_page04[152] = { + 0x00, 0xf0, 0x00, 0x00, 0xf2, 0x00, 0xf8, 0xf4, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf6, 0x00, /* 0x08-0x0f */ + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, /* 0x10-0x17 */ + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, /* 0x18-0x1f */ + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, /* 0x20-0x27 */ + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, /* 0x28-0x2f */ + 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, /* 0x30-0x37 */ + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, /* 0x38-0x3f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x40-0x47 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x48-0x4f */ + 0x00, 0xf1, 0x00, 0x00, 0xf3, 0x00, 0xf9, 0xf5, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf7, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xfc, 0xfd, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char cp1131_page25[152] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0xd5, 0xd6, 0xc9, 0xb8, 0xb7, 0xbb, /* 0x50-0x57 */ + 0xd4, 0xd3, 0xc8, 0xbe, 0xbd, 0xbc, 0xc6, 0xc7, /* 0x58-0x5f */ + 0xcc, 0xb5, 0xb6, 0xb9, 0xd1, 0xd2, 0xcb, 0xcf, /* 0x60-0x67 */ + 0xd0, 0xca, 0xd8, 0xd7, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0xdd, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xde, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; + +static int +cp1131_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00b8) + c = cp1131_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x0498) + c = cp1131_page04[wc-0x0400]; + else if (wc == 0x2219) + c = 0xfe; + else if (wc >= 0x2500 && wc < 0x2598) + c = cp1131_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1133.h b/graf2d/win32gdk/gdk/src/iconv/cp1133.h new file mode 100644 index 0000000000000..a16d93f1a4625 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1133.h @@ -0,0 +1,110 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * IBM-CP1133 + */ + +static const unsigned short cp1133_2uni_1[64] = { + /* 0xa0 */ + 0x00a0, 0x0e81, 0x0e82, 0x0e84, 0x0e87, 0x0e88, 0x0eaa, 0x0e8a, + 0x0e8d, 0x0e94, 0x0e95, 0x0e96, 0x0e97, 0x0e99, 0x0e9a, 0x0e9b, + /* 0xb0 */ + 0x0e9c, 0x0e9d, 0x0e9e, 0x0e9f, 0x0ea1, 0x0ea2, 0x0ea3, 0x0ea5, + 0x0ea7, 0x0eab, 0x0ead, 0x0eae, 0xfffd, 0xfffd, 0xfffd, 0x0eaf, + /* 0xc0 */ + 0x0eb0, 0x0eb2, 0x0eb3, 0x0eb4, 0x0eb5, 0x0eb6, 0x0eb7, 0x0eb8, + 0x0eb9, 0x0ebc, 0x0eb1, 0x0ebb, 0x0ebd, 0xfffd, 0xfffd, 0xfffd, + /* 0xd0 */ + 0x0ec0, 0x0ec1, 0x0ec2, 0x0ec3, 0x0ec4, 0x0ec8, 0x0ec9, 0x0eca, + 0x0ecb, 0x0ecc, 0x0ecd, 0x0ec6, 0xfffd, 0x0edc, 0x0edd, 0x20ad, +}; +static const unsigned short cp1133_2uni_2[16] = { + /* 0xf0 */ + 0x0ed0, 0x0ed1, 0x0ed2, 0x0ed3, 0x0ed4, 0x0ed5, 0x0ed6, 0x0ed7, + 0x0ed8, 0x0ed9, 0xfffd, 0xfffd, 0x00a2, 0x00ac, 0x00a6, 0xfffd, +}; + +static int +cp1133_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) { + *pwc = (ucs4_t) c; + return 1; + } + else if (c < 0xe0) { + unsigned short wc = cp1133_2uni_1[c-0xa0]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + else if (c < 0xf0) { + } + else { + unsigned short wc = cp1133_2uni_2[c-0xf0]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp1133_page00[16] = { + 0xa0, 0x00, 0xfc, 0x00, 0x00, 0x00, 0xfe, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0xfd, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ +}; +static const unsigned char cp1133_page0e[96] = { + 0x00, 0xa1, 0xa2, 0x00, 0xa3, 0x00, 0x00, 0xa4, /* 0x80-0x87 */ + 0xa5, 0x00, 0xa7, 0x00, 0x00, 0xa8, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x00, 0x00, 0xa9, 0xaa, 0xab, 0xac, /* 0x90-0x97 */ + 0x00, 0xad, 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, /* 0x98-0x9f */ + 0x00, 0xb4, 0xb5, 0xb6, 0x00, 0xb7, 0x00, 0xb8, /* 0xa0-0xa7 */ + 0x00, 0x00, 0xa6, 0xb9, 0x00, 0xba, 0xbb, 0xbf, /* 0xa8-0xaf */ + 0xc0, 0xca, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, /* 0xb0-0xb7 */ + 0xc7, 0xc8, 0x00, 0xcb, 0xc9, 0xcc, 0x00, 0x00, /* 0xb8-0xbf */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0x00, 0xdb, 0x00, /* 0xc0-0xc7 */ + 0xd5, 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0x00, 0x00, /* 0xc8-0xcf */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0xd0-0xd7 */ + 0xf8, 0xf9, 0x00, 0x00, 0xdd, 0xde, 0x00, 0x00, /* 0xd8-0xdf */ +}; + +static int +cp1133_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00b0) + c = cp1133_page00[wc-0x00a0]; + else if (wc >= 0x0e80 && wc < 0x0ee0) + c = cp1133_page0e[wc-0x0e80]; + else if (wc == 0x20ad) + c = 0xdf; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1161.h b/graf2d/win32gdk/gdk/src/iconv/cp1161.h new file mode 100644 index 0000000000000..b6349c67c4cdb --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1161.h @@ -0,0 +1,89 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1161 + */ + +static const unsigned short cp1161_2uni[96] = { + /* 0xa0 */ + 0x0e48, 0x0e01, 0x0e02, 0x0e03, 0x0e04, 0x0e05, 0x0e06, 0x0e07, + 0x0e08, 0x0e09, 0x0e0a, 0x0e0b, 0x0e0c, 0x0e0d, 0x0e0e, 0x0e0f, + /* 0xb0 */ + 0x0e10, 0x0e11, 0x0e12, 0x0e13, 0x0e14, 0x0e15, 0x0e16, 0x0e17, + 0x0e18, 0x0e19, 0x0e1a, 0x0e1b, 0x0e1c, 0x0e1d, 0x0e1e, 0x0e1f, + /* 0xc0 */ + 0x0e20, 0x0e21, 0x0e22, 0x0e23, 0x0e24, 0x0e25, 0x0e26, 0x0e27, + 0x0e28, 0x0e29, 0x0e2a, 0x0e2b, 0x0e2c, 0x0e2d, 0x0e2e, 0x0e2f, + /* 0xd0 */ + 0x0e30, 0x0e31, 0x0e32, 0x0e33, 0x0e34, 0x0e35, 0x0e36, 0x0e37, + 0x0e38, 0x0e39, 0x0e3a, 0x0e49, 0x0e4a, 0x0e4b, 0x20ac, 0x0e3f, + /* 0xe0 */ + 0x0e40, 0x0e41, 0x0e42, 0x0e43, 0x0e44, 0x0e45, 0x0e46, 0x0e47, + 0x0e48, 0x0e49, 0x0e4a, 0x0e4b, 0x0e4c, 0x0e4d, 0x0e4e, 0x0e4f, + /* 0xf0 */ + 0x0e50, 0x0e51, 0x0e52, 0x0e53, 0x0e54, 0x0e55, 0x0e56, 0x0e57, + 0x0e58, 0x0e59, 0x0e5a, 0x0e5b, 0x00a2, 0x00ac, 0x00a6, 0x00a0, +}; + +static int +cp1161_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else if (c < 0xa0) { + } + else { + *pwc = (ucs4_t) cp1161_2uni[c-0xa0]; + return 1; + } + return RET_ILSEQ; +} + +static const unsigned char cp1161_page00[16] = { + 0xff, 0x00, 0xfc, 0x00, 0x00, 0x00, 0xfe, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0xfd, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ +}; + +static int +cp1161_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00b0) + c = cp1161_page00[wc-0x00a0]; + else if (wc >= 0x0e48 && wc < 0x0e4c) + c = wc-0x0d60; + else if (wc >= 0x0e00 && wc < 0x0e60) + c = cp874_page0e[wc-0x0e00]; + else if (wc == 0x20ac) + c = 0xde; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1162.h b/graf2d/win32gdk/gdk/src/iconv/cp1162.h new file mode 100644 index 0000000000000..6c7fa82ae5da2 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1162.h @@ -0,0 +1,70 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1162 + */ + +static int +cp1162_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp874_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + if (c < 0xa0) { + *pwc = (ucs4_t) c; + return 1; + } + } + return RET_ILSEQ; +} + +static int +cp1162_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x0080 && wc < 0x00a0 && cp874_2uni[wc-0x0080] == 0xfffd) + c = wc; + else if (wc == 0x00a0) + c = 0xa0; + else if (wc >= 0x0e00 && wc < 0x0e60) + c = cp874_page0e[wc-0x0e00]; + else if (wc >= 0x2010 && wc < 0x2028) + c = cp874_page20[wc-0x2010]; + else if (wc == 0x20ac) + c = 0x80; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1163.h b/graf2d/win32gdk/gdk/src/iconv/cp1163.h new file mode 100644 index 0000000000000..ca5d0b07d1189 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1163.h @@ -0,0 +1,63 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1163 + */ + +static int +cp1163_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) + *pwc = (ucs4_t) c; + else if (c == 0xa4) + *pwc = 0x20ac; + else + *pwc = (ucs4_t) cp1129_2uni[c-0xa0]; + return 1; +} + +static const unsigned char cp1163_page20[8] = { + 0x00, 0x00, 0x00, 0xfe, 0xa4, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ +}; + +static int +cp1163_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0 || (wc < 0x00a8 && wc != 0x00a4) || wc == 0x00d0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a8 && wc < 0x01b8) + c = cp1129_page00[wc-0x00a8]; + else if (wc >= 0x0300 && wc < 0x0328) + c = cp1129_page03[wc-0x0300]; + else if (wc == 0x203e) + c = 0xaf; + else if (wc >= 0x20a8 && wc < 0x20b0) + c = cp1163_page20[wc-0x20a8]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1250.h b/graf2d/win32gdk/gdk/src/iconv/cp1250.h new file mode 100644 index 0000000000000..b89300fecb80f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1250.h @@ -0,0 +1,139 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1250 + */ + +static const unsigned short cp1250_2uni[128] = { + /* 0x80 */ + 0x20ac, 0xfffd, 0x201a, 0xfffd, 0x201e, 0x2026, 0x2020, 0x2021, + 0xfffd, 0x2030, 0x0160, 0x2039, 0x015a, 0x0164, 0x017d, 0x0179, + /* 0x90 */ + 0xfffd, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0xfffd, 0x2122, 0x0161, 0x203a, 0x015b, 0x0165, 0x017e, 0x017a, + /* 0xa0 */ + 0x00a0, 0x02c7, 0x02d8, 0x0141, 0x00a4, 0x0104, 0x00a6, 0x00a7, + 0x00a8, 0x00a9, 0x015e, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x017b, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x02db, 0x0142, 0x00b4, 0x00b5, 0x00b6, 0x00b7, + 0x00b8, 0x0105, 0x015f, 0x00bb, 0x013d, 0x02dd, 0x013e, 0x017c, + /* 0xc0 */ + 0x0154, 0x00c1, 0x00c2, 0x0102, 0x00c4, 0x0139, 0x0106, 0x00c7, + 0x010c, 0x00c9, 0x0118, 0x00cb, 0x011a, 0x00cd, 0x00ce, 0x010e, + /* 0xd0 */ + 0x0110, 0x0143, 0x0147, 0x00d3, 0x00d4, 0x0150, 0x00d6, 0x00d7, + 0x0158, 0x016e, 0x00da, 0x0170, 0x00dc, 0x00dd, 0x0162, 0x00df, + /* 0xe0 */ + 0x0155, 0x00e1, 0x00e2, 0x0103, 0x00e4, 0x013a, 0x0107, 0x00e7, + 0x010d, 0x00e9, 0x0119, 0x00eb, 0x011b, 0x00ed, 0x00ee, 0x010f, + /* 0xf0 */ + 0x0111, 0x0144, 0x0148, 0x00f3, 0x00f4, 0x0151, 0x00f6, 0x00f7, + 0x0159, 0x016f, 0x00fa, 0x0171, 0x00fc, 0x00fd, 0x0163, 0x02d9, +}; + +static int +cp1250_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp1250_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp1250_page00[224] = { + 0xa0, 0x00, 0x00, 0x00, 0xa4, 0x00, 0xa6, 0xa7, /* 0xa0-0xa7 */ + 0xa8, 0xa9, 0x00, 0xab, 0xac, 0xad, 0xae, 0x00, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0x00, 0x00, 0xb4, 0xb5, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0xb8, 0x00, 0x00, 0xbb, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0xc1, 0xc2, 0x00, 0xc4, 0x00, 0x00, 0xc7, /* 0xc0-0xc7 */ + 0x00, 0xc9, 0x00, 0xcb, 0x00, 0xcd, 0xce, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0xd3, 0xd4, 0x00, 0xd6, 0xd7, /* 0xd0-0xd7 */ + 0x00, 0x00, 0xda, 0x00, 0xdc, 0xdd, 0x00, 0xdf, /* 0xd8-0xdf */ + 0x00, 0xe1, 0xe2, 0x00, 0xe4, 0x00, 0x00, 0xe7, /* 0xe0-0xe7 */ + 0x00, 0xe9, 0x00, 0xeb, 0x00, 0xed, 0xee, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0xf3, 0xf4, 0x00, 0xf6, 0xf7, /* 0xf0-0xf7 */ + 0x00, 0x00, 0xfa, 0x00, 0xfc, 0xfd, 0x00, 0x00, /* 0xf8-0xff */ + /* 0x0100 */ + 0x00, 0x00, 0xc3, 0xe3, 0xa5, 0xb9, 0xc6, 0xe6, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xc8, 0xe8, 0xcf, 0xef, /* 0x08-0x0f */ + 0xd0, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xca, 0xea, 0xcc, 0xec, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0xc5, 0xe5, 0x00, 0x00, 0xbc, 0xbe, 0x00, /* 0x38-0x3f */ + 0x00, 0xa3, 0xb3, 0xd1, 0xf1, 0x00, 0x00, 0xd2, /* 0x40-0x47 */ + 0xf2, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xd5, 0xf5, 0x00, 0x00, 0xc0, 0xe0, 0x00, 0x00, /* 0x50-0x57 */ + 0xd8, 0xf8, 0x8c, 0x9c, 0x00, 0x00, 0xaa, 0xba, /* 0x58-0x5f */ + 0x8a, 0x9a, 0xde, 0xfe, 0x8d, 0x9d, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd9, 0xf9, /* 0x68-0x6f */ + 0xdb, 0xfb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x8f, 0x9f, 0xaf, 0xbf, 0x8e, 0x9e, 0x00, /* 0x78-0x7f */ +}; +static const unsigned char cp1250_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa1, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0xa2, 0xff, 0x00, 0xb2, 0x00, 0xbd, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char cp1250_page20[48] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; + +static int +cp1250_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0180) + c = cp1250_page00[wc-0x00a0]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = cp1250_page02[wc-0x02c0]; + else if (wc >= 0x2010 && wc < 0x2040) + c = cp1250_page20[wc-0x2010]; + else if (wc == 0x20ac) + c = 0x80; + else if (wc == 0x2122) + c = 0x99; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1251.h b/graf2d/win32gdk/gdk/src/iconv/cp1251.h new file mode 100644 index 0000000000000..0fa540db49033 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1251.h @@ -0,0 +1,131 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1251 + */ + +static const unsigned short cp1251_2uni[128] = { + /* 0x80 */ + 0x0402, 0x0403, 0x201a, 0x0453, 0x201e, 0x2026, 0x2020, 0x2021, + 0x20ac, 0x2030, 0x0409, 0x2039, 0x040a, 0x040c, 0x040b, 0x040f, + /* 0x90 */ + 0x0452, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0xfffd, 0x2122, 0x0459, 0x203a, 0x045a, 0x045c, 0x045b, 0x045f, + /* 0xa0 */ + 0x00a0, 0x040e, 0x045e, 0x0408, 0x00a4, 0x0490, 0x00a6, 0x00a7, + 0x0401, 0x00a9, 0x0404, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x0407, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x0406, 0x0456, 0x0491, 0x00b5, 0x00b6, 0x00b7, + 0x0451, 0x2116, 0x0454, 0x00bb, 0x0458, 0x0405, 0x0455, 0x0457, + /* 0xc0 */ + 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, + 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, 0x041f, + /* 0xd0 */ + 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, 0x0427, + 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, 0x042f, + /* 0xe0 */ + 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0436, 0x0437, + 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, + /* 0xf0 */ + 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, + 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x044f, +}; + +static int +cp1251_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp1251_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp1251_page00[32] = { + 0xa0, 0x00, 0x00, 0x00, 0xa4, 0x00, 0xa6, 0xa7, /* 0xa0-0xa7 */ + 0x00, 0xa9, 0x00, 0xab, 0xac, 0xad, 0xae, 0x00, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0x00, 0x00, 0x00, 0xb5, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xbb, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ +}; +static const unsigned char cp1251_page04[152] = { + 0x00, 0xa8, 0x80, 0x81, 0xaa, 0xbd, 0xb2, 0xaf, /* 0x00-0x07 */ + 0xa3, 0x8a, 0x8c, 0x8e, 0x8d, 0x00, 0xa1, 0x8f, /* 0x08-0x0f */ + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x10-0x17 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x18-0x1f */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0x20-0x27 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xdf, /* 0x28-0x2f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x30-0x37 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x38-0x3f */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0x40-0x47 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xff, /* 0x48-0x4f */ + 0x00, 0xb8, 0x90, 0x83, 0xba, 0xbe, 0xb3, 0xbf, /* 0x50-0x57 */ + 0xbc, 0x9a, 0x9c, 0x9e, 0x9d, 0x00, 0xa2, 0x9f, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xa5, 0xb4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char cp1251_page20[48] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; + +static int +cp1251_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = cp1251_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x0498) + c = cp1251_page04[wc-0x0400]; + else if (wc >= 0x2010 && wc < 0x2040) + c = cp1251_page20[wc-0x2010]; + else if (wc == 0x20ac) + c = 0x88; + else if (wc == 0x2116) + c = 0xb9; + else if (wc == 0x2122) + c = 0x99; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1252.h b/graf2d/win32gdk/gdk/src/iconv/cp1252.h new file mode 100644 index 0000000000000..15644423add8e --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1252.h @@ -0,0 +1,103 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1252 + */ + +static const unsigned short cp1252_2uni[32] = { + /* 0x80 */ + 0x20ac, 0xfffd, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, + 0x02c6, 0x2030, 0x0160, 0x2039, 0x0152, 0xfffd, 0x017d, 0xfffd, + /* 0x90 */ + 0xfffd, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0x02dc, 0x2122, 0x0161, 0x203a, 0x0153, 0xfffd, 0x017e, 0x0178, +}; + +static int +cp1252_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80 || c >= 0xa0) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp1252_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp1252_page01[72] = { + 0x00, 0x00, 0x8c, 0x9c, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x8a, 0x9a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x9f, 0x00, 0x00, 0x00, 0x00, 0x8e, 0x9e, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x83, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char cp1252_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char cp1252_page20[48] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; + +static int +cp1252_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = wc; + else if (wc >= 0x0150 && wc < 0x0198) + c = cp1252_page01[wc-0x0150]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = cp1252_page02[wc-0x02c0]; + else if (wc >= 0x2010 && wc < 0x2040) + c = cp1252_page20[wc-0x2010]; + else if (wc == 0x20ac) + c = 0x80; + else if (wc == 0x2122) + c = 0x99; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1253.h b/graf2d/win32gdk/gdk/src/iconv/cp1253.h new file mode 100644 index 0000000000000..020f0d6e05715 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1253.h @@ -0,0 +1,122 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1253 + */ + +static const unsigned short cp1253_2uni[128] = { + /* 0x80 */ + 0x20ac, 0xfffd, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, + 0xfffd, 0x2030, 0xfffd, 0x2039, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x90 */ + 0xfffd, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0xfffd, 0x2122, 0xfffd, 0x203a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xa0 */ + 0x00a0, 0x0385, 0x0386, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, + 0x00a8, 0x00a9, 0xfffd, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x2015, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x0384, 0x00b5, 0x00b6, 0x00b7, + 0x0388, 0x0389, 0x038a, 0x00bb, 0x038c, 0x00bd, 0x038e, 0x038f, + /* 0xc0 */ + 0x0390, 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, + 0x0398, 0x0399, 0x039a, 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, + /* 0xd0 */ + 0x03a0, 0x03a1, 0xfffd, 0x03a3, 0x03a4, 0x03a5, 0x03a6, 0x03a7, + 0x03a8, 0x03a9, 0x03aa, 0x03ab, 0x03ac, 0x03ad, 0x03ae, 0x03af, + /* 0xe0 */ + 0x03b0, 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, + 0x03b8, 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, + /* 0xf0 */ + 0x03c0, 0x03c1, 0x03c2, 0x03c3, 0x03c4, 0x03c5, 0x03c6, 0x03c7, + 0x03c8, 0x03c9, 0x03ca, 0x03cb, 0x03cc, 0x03cd, 0x03ce, 0xfffd, +}; + +static int +cp1253_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp1253_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp1253_page00[32] = { + 0xa0, 0x00, 0x00, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, /* 0xa0-0xa7 */ + 0xa8, 0xa9, 0x00, 0xab, 0xac, 0xad, 0xae, 0x00, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0xb2, 0xb3, 0x00, 0xb5, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xbb, 0x00, 0xbd, 0x00, 0x00, /* 0xb8-0xbf */ +}; +static const unsigned char cp1253_page03[80] = { + 0x00, 0x00, 0x00, 0x00, 0xb4, 0xa1, 0xa2, 0x00, /* 0x80-0x87 */ + 0xb8, 0xb9, 0xba, 0x00, 0xbc, 0x00, 0xbe, 0xbf, /* 0x88-0x8f */ + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x90-0x97 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x98-0x9f */ + 0xd0, 0xd1, 0x00, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0xa0-0xa7 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xdf, /* 0xa8-0xaf */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0xb0-0xb7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0xb8-0xbf */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0xc0-0xc7 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0x00, /* 0xc8-0xcf */ +}; +static const unsigned char cp1253_page20[48] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0xaf, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; + +static int +cp1253_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = cp1253_page00[wc-0x00a0]; + else if (wc == 0x0192) + c = 0x83; + else if (wc >= 0x0380 && wc < 0x03d0) + c = cp1253_page03[wc-0x0380]; + else if (wc >= 0x2010 && wc < 0x2040) + c = cp1253_page20[wc-0x2010]; + else if (wc == 0x20ac) + c = 0x80; + else if (wc == 0x2122) + c = 0x99; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1254.h b/graf2d/win32gdk/gdk/src/iconv/cp1254.h new file mode 100644 index 0000000000000..845a01b8948d8 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1254.h @@ -0,0 +1,146 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1254 + */ + +static const unsigned short cp1254_2uni_1[32] = { + /* 0x80 */ + 0x20ac, 0xfffd, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, + 0x02c6, 0x2030, 0x0160, 0x2039, 0x0152, 0xfffd, 0xfffd, 0xfffd, + /* 0x90 */ + 0xfffd, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0x02dc, 0x2122, 0x0161, 0x203a, 0x0153, 0xfffd, 0xfffd, 0x0178, +}; +static const unsigned short cp1254_2uni_2[16] = { + /* 0xd0 */ + 0x011e, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x00d7, + 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x0130, 0x015e, 0x00df, +}; +static const unsigned short cp1254_2uni_3[16] = { + /* 0xf0 */ + 0x011f, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x00f7, + 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x0131, 0x015f, 0x00ff, +}; + +static int +cp1254_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else if (c < 0xa0) { + unsigned short wc = cp1254_2uni_1[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + else if (c < 0xd0) { + *pwc = (ucs4_t) c; + return 1; + } + else if (c < 0xe0) { + *pwc = (ucs4_t) cp1254_2uni_2[c-0xd0]; + return 1; + } + else if (c < 0xf0) { + *pwc = (ucs4_t) c; + return 1; + } + else { + *pwc = (ucs4_t) cp1254_2uni_3[c-0xf0]; + return 1; + } + return RET_ILSEQ; +} + +static const unsigned char cp1254_page00[48] = { + 0x00, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0xd0-0xd7 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0x00, 0x00, 0xdf, /* 0xd8-0xdf */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0xe0-0xe7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0xe8-0xef */ + 0x00, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0xf0-0xf7 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0x00, 0x00, 0xff, /* 0xf8-0xff */ +}; +static const unsigned char cp1254_page01[128] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd0, 0xf0, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0xdd, 0xfd, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x8c, 0x9c, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xde, 0xfe, /* 0x58-0x5f */ + 0x8a, 0x9a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x9f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x83, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char cp1254_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char cp1254_page20[48] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; + +static int +cp1254_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00d0) + c = wc; + else if (wc >= 0x00d0 && wc < 0x0100) + c = cp1254_page00[wc-0x00d0]; + else if (wc >= 0x0118 && wc < 0x0198) + c = cp1254_page01[wc-0x0118]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = cp1254_page02[wc-0x02c0]; + else if (wc >= 0x2010 && wc < 0x2040) + c = cp1254_page20[wc-0x2010]; + else if (wc == 0x20ac) + c = 0x80; + else if (wc == 0x2122) + c = 0x99; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1255.h b/graf2d/win32gdk/gdk/src/iconv/cp1255.h new file mode 100644 index 0000000000000..e7761aeb5b375 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1255.h @@ -0,0 +1,380 @@ +/* + * Copyright (C) 1999-2001, 2004 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1255 + */ + +#include "flushwc.h" + +/* Combining characters used in Hebrew encoding CP1255. */ + +/* Relevant combining characters: + 0x05b4, 0x05b7, 0x05b8, 0x05b9, 0x05bc, 0x05bf, 0x05c1, 0x05c2. */ + +/* Composition tables for each of the relevant combining characters. */ +static const struct { unsigned short base; unsigned short composed; } cp1255_comp_table_data[] = { +#define cp1255_comp_table05b4_idx 0 +#define cp1255_comp_table05b4_len 1 + { 0x05D9, 0xFB1D }, +#define cp1255_comp_table05b7_idx (cp1255_comp_table05b4_idx+cp1255_comp_table05b4_len) +#define cp1255_comp_table05b7_len 2 + { 0x05D0, 0xFB2E }, + { 0x05F2, 0xFB1F }, +#define cp1255_comp_table05b8_idx (cp1255_comp_table05b7_idx+cp1255_comp_table05b7_len) +#define cp1255_comp_table05b8_len 1 + { 0x05D0, 0xFB2F }, +#define cp1255_comp_table05b9_idx (cp1255_comp_table05b8_idx+cp1255_comp_table05b8_len) +#define cp1255_comp_table05b9_len 1 + { 0x05D5, 0xFB4B }, +#define cp1255_comp_table05bc_idx (cp1255_comp_table05b9_idx+cp1255_comp_table05b9_len) +#define cp1255_comp_table05bc_len 24 + { 0x05D0, 0xFB30 }, + { 0x05D1, 0xFB31 }, + { 0x05D2, 0xFB32 }, + { 0x05D3, 0xFB33 }, + { 0x05D4, 0xFB34 }, + { 0x05D5, 0xFB35 }, + { 0x05D6, 0xFB36 }, + { 0x05D8, 0xFB38 }, + { 0x05D9, 0xFB39 }, + { 0x05DA, 0xFB3A }, + { 0x05DB, 0xFB3B }, + { 0x05DC, 0xFB3C }, + { 0x05DE, 0xFB3E }, + { 0x05E0, 0xFB40 }, + { 0x05E1, 0xFB41 }, + { 0x05E3, 0xFB43 }, + { 0x05E4, 0xFB44 }, + { 0x05E6, 0xFB46 }, + { 0x05E7, 0xFB47 }, + { 0x05E8, 0xFB48 }, + { 0x05E9, 0xFB49 }, + { 0x05EA, 0xFB4A }, + { 0xFB2A, 0xFB2C }, + { 0xFB2B, 0xFB2D }, +#define cp1255_comp_table05bf_idx (cp1255_comp_table05bc_idx+cp1255_comp_table05bc_len) +#define cp1255_comp_table05bf_len 3 + { 0x05D1, 0xFB4C }, + { 0x05DB, 0xFB4D }, + { 0x05E4, 0xFB4E }, +#define cp1255_comp_table05c1_idx (cp1255_comp_table05bf_idx+cp1255_comp_table05bf_len) +#define cp1255_comp_table05c1_len 2 + { 0x05E9, 0xFB2A }, + { 0xFB49, 0xFB2C }, +#define cp1255_comp_table05c2_idx (cp1255_comp_table05c1_idx+cp1255_comp_table05c1_len) +#define cp1255_comp_table05c2_len 2 + { 0x05E9, 0xFB2B }, + { 0xFB49, 0xFB2D }, +}; +static const struct { unsigned int len; unsigned int idx; } cp1255_comp_table[] = { + { cp1255_comp_table05b4_len, cp1255_comp_table05b4_idx }, + { cp1255_comp_table05b7_len, cp1255_comp_table05b7_idx }, + { cp1255_comp_table05b8_len, cp1255_comp_table05b8_idx }, + { cp1255_comp_table05b9_len, cp1255_comp_table05b9_idx }, + { cp1255_comp_table05bc_len, cp1255_comp_table05bc_idx }, + { cp1255_comp_table05bf_len, cp1255_comp_table05bf_idx }, + { cp1255_comp_table05c1_len, cp1255_comp_table05c1_idx }, + { cp1255_comp_table05c2_len, cp1255_comp_table05c2_idx }, +}; + +/* Decomposition table for the relevant Unicode characters. */ +struct cp1255_decomp { unsigned short composed; unsigned short base; int comb1 : 8; signed int comb2 : 8; }; +static const struct cp1255_decomp cp1255_decomp_table[] = { + { 0xFB1D, 0x05D9, 0, -1 }, + { 0xFB1F, 0x05F2, 1, -1 }, + { 0xFB2A, 0x05E9, 6, -1 }, + { 0xFB2B, 0x05E9, 7, -1 }, + { 0xFB2C, 0x05E9, 4, 6 }, + { 0xFB2D, 0x05E9, 4, 7 }, + { 0xFB2E, 0x05D0, 1, -1 }, + { 0xFB2F, 0x05D0, 2, -1 }, + { 0xFB30, 0x05D0, 4, -1 }, + { 0xFB31, 0x05D1, 4, -1 }, + { 0xFB32, 0x05D2, 4, -1 }, + { 0xFB33, 0x05D3, 4, -1 }, + { 0xFB34, 0x05D4, 4, -1 }, + { 0xFB35, 0x05D5, 4, -1 }, + { 0xFB36, 0x05D6, 4, -1 }, + { 0xFB38, 0x05D8, 4, -1 }, + { 0xFB39, 0x05D9, 4, -1 }, + { 0xFB3A, 0x05DA, 4, -1 }, + { 0xFB3B, 0x05DB, 4, -1 }, + { 0xFB3C, 0x05DC, 4, -1 }, + { 0xFB3E, 0x05DE, 4, -1 }, + { 0xFB40, 0x05E0, 4, -1 }, + { 0xFB41, 0x05E1, 4, -1 }, + { 0xFB43, 0x05E3, 4, -1 }, + { 0xFB44, 0x05E4, 4, -1 }, + { 0xFB46, 0x05E6, 4, -1 }, + { 0xFB47, 0x05E7, 4, -1 }, + { 0xFB48, 0x05E8, 4, -1 }, + { 0xFB49, 0x05E9, 4, -1 }, + { 0xFB4A, 0x05EA, 4, -1 }, + { 0xFB4B, 0x05D5, 3, -1 }, + { 0xFB4C, 0x05D1, 5, -1 }, + { 0xFB4D, 0x05DB, 5, -1 }, + { 0xFB4E, 0x05E4, 5, -1 }, +}; + +static const unsigned char cp1255_comb_table[] = { + 0xc4, 0xc7, 0xc8, 0xc9, 0xcc, 0xcf, 0xd1, 0xd2, +}; + +static const unsigned short cp1255_2uni[128] = { + /* 0x80 */ + 0x20ac, 0xfffd, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, + 0x02c6, 0x2030, 0xfffd, 0x2039, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x90 */ + 0xfffd, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0x02dc, 0x2122, 0xfffd, 0x203a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xa0 */ + 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x20aa, 0x00a5, 0x00a6, 0x00a7, + 0x00a8, 0x00a9, 0x00d7, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, + 0x00b8, 0x00b9, 0x00f7, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf, + /* 0xc0 */ + 0x05b0, 0x05b1, 0x05b2, 0x05b3, 0x05b4, 0x05b5, 0x05b6, 0x05b7, + 0x05b8, 0x05b9, 0xfffd, 0x05bb, 0x05bc, 0x05bd, 0x05be, 0x05bf, + /* 0xd0 */ + 0x05c0, 0x05c1, 0x05c2, 0x05c3, 0x05f0, 0x05f1, 0x05f2, 0x05f3, + 0x05f4, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xe0 */ + 0x05d0, 0x05d1, 0x05d2, 0x05d3, 0x05d4, 0x05d5, 0x05d6, 0x05d7, + 0x05d8, 0x05d9, 0x05da, 0x05db, 0x05dc, 0x05dd, 0x05de, 0x05df, + /* 0xf0 */ + 0x05e0, 0x05e1, 0x05e2, 0x05e3, 0x05e4, 0x05e5, 0x05e6, 0x05e7, + 0x05e8, 0x05e9, 0x05ea, 0xfffd, 0xfffd, 0x200e, 0x200f, 0xfffd, +}; + +/* In the CP1255 to Unicode direction, the state contains a buffered + character, or 0 if none. */ + +static int +cp1255_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + unsigned short wc; + unsigned short last_wc; + if (c < 0x80) { + wc = c; + } else { + wc = cp1255_2uni[c-0x80]; + if (wc == 0xfffd) + return RET_ILSEQ; + } + last_wc = conv->istate; + if (last_wc) { + if (wc >= 0x05b0 && wc < 0x05c5) { + /* See whether last_wc and wc can be combined. */ + unsigned int k; + unsigned int i1, i2; + switch (wc) { + case 0x05b4: k = 0; break; + case 0x05b7: k = 1; break; + case 0x05b8: k = 2; break; + case 0x05b9: k = 3; break; + case 0x05bc: k = 4; break; + case 0x05bf: k = 5; break; + case 0x05c1: k = 6; break; + case 0x05c2: k = 7; break; + default: goto not_combining; + } + i1 = cp1255_comp_table[k].idx; + i2 = i1 + cp1255_comp_table[k].len-1; + if (last_wc >= cp1255_comp_table_data[i1].base + && last_wc <= cp1255_comp_table_data[i2].base) { + unsigned int i; + for (;;) { + i = (i1+i2)>>1; + if (last_wc == cp1255_comp_table_data[i].base) + break; + if (last_wc < cp1255_comp_table_data[i].base) { + if (i1 == i) + goto not_combining; + i2 = i; + } else { + if (i1 != i) + i1 = i; + else { + i = i2; + if (last_wc == cp1255_comp_table_data[i].base) + break; + goto not_combining; + } + } + } + last_wc = cp1255_comp_table_data[i].composed; + if (last_wc == 0xfb2a || last_wc == 0xfb2b || last_wc == 0xfb49) { + /* Buffer the combined character. */ + conv->istate = last_wc; + return RET_TOOFEW(1); + } else { + /* Output the combined character. */ + conv->istate = 0; + *pwc = (ucs4_t) last_wc; + return 1; + } + } + } + not_combining: + /* Output the buffered character. */ + conv->istate = 0; + *pwc = (ucs4_t) last_wc; + return 0; /* Don't advance the input pointer. */ + } + if ((wc >= 0x05d0 && wc <= 0x05ea && ((0x07db5f7f >> (wc - 0x05d0)) & 1)) + || wc == 0x05f2) { + /* wc is a possible match in cp1255_comp_table_data. Buffer it. */ + conv->istate = wc; + return RET_TOOFEW(1); + } else { + /* Output wc immediately. */ + *pwc = (ucs4_t) wc; + return 1; + } +} + +#define cp1255_flushwc normal_flushwc + +static const unsigned char cp1255_page00[88] = { + 0xa0, 0xa1, 0xa2, 0xa3, 0x00, 0xa5, 0xa6, 0xa7, /* 0xa0-0xa7 */ + 0xa8, 0xa9, 0x00, 0xab, 0xac, 0xad, 0xae, 0xaf, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0xb8, 0xb9, 0x00, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xaa, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xba, /* 0xf0-0xf7 */ +}; +static const unsigned char cp1255_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char cp1255_page05[72] = { + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0xb0-0xb7 */ + 0xc8, 0xc9, 0x00, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0xb8-0xbf */ + 0xd0, 0xd1, 0xd2, 0xd3, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0xd0-0xd7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0xd8-0xdf */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0xe0-0xe7 */ + 0xf8, 0xf9, 0xfa, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0xd4, 0xd5, 0xd6, 0xd7, 0xd8, 0x00, 0x00, 0x00, /* 0xf0-0xf7 */ +}; +static const unsigned char cp1255_page20[56] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfd, 0xfe, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; + +static int +cp1255_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00f8) + c = cp1255_page00[wc-0x00a0]; + else if (wc == 0x0192) + c = 0x83; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = cp1255_page02[wc-0x02c0]; + else if (wc >= 0x05b0 && wc < 0x05f8) + c = cp1255_page05[wc-0x05b0]; + else if (wc >= 0x2008 && wc < 0x2040) + c = cp1255_page20[wc-0x2008]; + else if (wc == 0x20aa) + c = 0xa4; + else if (wc == 0x20ac) + c = 0x80; + else if (wc == 0x2122) + c = 0x99; + if (c != 0) { + *r = c; + return 1; + } + /* Try canonical decomposition. */ + { + /* Binary search through cp1255_decomp_table. */ + unsigned int i1 = 0; + unsigned int i2 = sizeof(cp1255_decomp_table)/sizeof(cp1255_decomp_table[0])-1; + if (wc >= cp1255_decomp_table[i1].composed + && wc <= cp1255_decomp_table[i2].composed) { + unsigned int i; + for (;;) { + /* Here i2 - i1 > 0. */ + i = (i1+i2)>>1; + if (wc == cp1255_decomp_table[i].composed) + break; + if (wc < cp1255_decomp_table[i].composed) { + if (i1 == i) + return RET_ILUNI; + /* Here i1 < i < i2. */ + i2 = i; + } else { + /* Here i1 <= i < i2. */ + if (i1 != i) + i1 = i; + else { + /* Here i2 - i1 = 1. */ + i = i2; + if (wc == cp1255_decomp_table[i].composed) + break; + else + return RET_ILUNI; + } + } + } + /* Found a canonical decomposition. */ + wc = cp1255_decomp_table[i].base; + /* wc is one of 0x05d0..0x05d6, 0x05d8..0x05dc, 0x05de, 0x05e0..0x05e1, + 0x05e3..0x05e4, 0x05e6..0x05ea, 0x05f2. */ + c = cp1255_page05[wc-0x05b0]; + if (cp1255_decomp_table[i].comb2 < 0) { + if (n < 2) + return RET_TOOSMALL; + r[0] = c; + r[1] = cp1255_comb_table[cp1255_decomp_table[i].comb1]; + return 2; + } else { + if (n < 3) + return RET_TOOSMALL; + r[0] = c; + r[1] = cp1255_comb_table[cp1255_decomp_table[i].comb1]; + r[2] = cp1255_comb_table[cp1255_decomp_table[i].comb2]; + return 3; + } + } + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1256.h b/graf2d/win32gdk/gdk/src/iconv/cp1256.h new file mode 100644 index 0000000000000..3804e8f4bdfa3 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1256.h @@ -0,0 +1,153 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1256 + */ + +static const unsigned short cp1256_2uni[128] = { + /* 0x80 */ + 0x20ac, 0x067e, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, + 0x02c6, 0x2030, 0x0679, 0x2039, 0x0152, 0x0686, 0x0698, 0x0688, + /* 0x90 */ + 0x06af, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0x06a9, 0x2122, 0x0691, 0x203a, 0x0153, 0x200c, 0x200d, 0x06ba, + /* 0xa0 */ + 0x00a0, 0x060c, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, + 0x00a8, 0x00a9, 0x06be, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, + 0x00b8, 0x00b9, 0x061b, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x061f, + /* 0xc0 */ + 0x06c1, 0x0621, 0x0622, 0x0623, 0x0624, 0x0625, 0x0626, 0x0627, + 0x0628, 0x0629, 0x062a, 0x062b, 0x062c, 0x062d, 0x062e, 0x062f, + /* 0xd0 */ + 0x0630, 0x0631, 0x0632, 0x0633, 0x0634, 0x0635, 0x0636, 0x00d7, + 0x0637, 0x0638, 0x0639, 0x063a, 0x0640, 0x0641, 0x0642, 0x0643, + /* 0xe0 */ + 0x00e0, 0x0644, 0x00e2, 0x0645, 0x0646, 0x0647, 0x0648, 0x00e7, + 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x0649, 0x064a, 0x00ee, 0x00ef, + /* 0xf0 */ + 0x064b, 0x064c, 0x064d, 0x064e, 0x00f4, 0x064f, 0x0650, 0x00f7, + 0x0651, 0x00f9, 0x0652, 0x00fb, 0x00fc, 0x200e, 0x200f, 0x06d2, +}; + +static int +cp1256_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp1256_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp1256_page00[96] = { + 0xa0, 0x00, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, /* 0xa0-0xa7 */ + 0xa8, 0xa9, 0x00, 0xab, 0xac, 0xad, 0xae, 0xaf, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0xb8, 0xb9, 0x00, 0xbb, 0xbc, 0xbd, 0xbe, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd7, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0xe0, 0x00, 0xe2, 0x00, 0x00, 0x00, 0x00, 0xe7, /* 0xe0-0xe7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0x00, 0x00, 0xee, 0xef, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x00, 0xf4, 0x00, 0x00, 0xf7, /* 0xf0-0xf7 */ + 0x00, 0xf9, 0x00, 0xfb, 0xfc, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; +static const unsigned char cp1256_page01[72] = { + 0x00, 0x00, 0x8c, 0x9c, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x83, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char cp1256_page06[208] = { + 0x00, 0x00, 0x00, 0x00, 0xa1, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0xba, 0x00, 0x00, 0x00, 0xbf, /* 0x18-0x1f */ + 0x00, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x20-0x27 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x28-0x2f */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd8, /* 0x30-0x37 */ + 0xd9, 0xda, 0xdb, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0xdc, 0xdd, 0xde, 0xdf, 0xe1, 0xe3, 0xe4, 0xe5, /* 0x40-0x47 */ + 0xe6, 0xec, 0xed, 0xf0, 0xf1, 0xf2, 0xf3, 0xf5, /* 0x48-0x4f */ + 0xf6, 0xf8, 0xfa, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x8a, 0x00, 0x00, 0x00, 0x00, 0x81, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x8d, 0x00, /* 0x80-0x87 */ + 0x8f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x9a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x8e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x98, 0x00, 0x00, 0x00, 0x00, 0x00, 0x90, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x9f, 0x00, 0x00, 0x00, 0xaa, 0x00, /* 0xb8-0xbf */ + 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ +}; +static const unsigned char cp1256_page20[56] = { + 0x00, 0x00, 0x00, 0x00, 0x9d, 0x9e, 0xfd, 0xfe, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; + +static int +cp1256_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = cp1256_page00[wc-0x00a0]; + else if (wc >= 0x0150 && wc < 0x0198) + c = cp1256_page01[wc-0x0150]; + else if (wc == 0x02c6) + c = 0x88; + else if (wc >= 0x0608 && wc < 0x06d8) + c = cp1256_page06[wc-0x0608]; + else if (wc >= 0x2008 && wc < 0x2040) + c = cp1256_page20[wc-0x2008]; + else if (wc == 0x20ac) + c = 0x80; + else if (wc == 0x2122) + c = 0x99; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1257.h b/graf2d/win32gdk/gdk/src/iconv/cp1257.h new file mode 100644 index 0000000000000..0d8518e4e239f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1257.h @@ -0,0 +1,139 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1257 + */ + +static const unsigned short cp1257_2uni[128] = { + /* 0x80 */ + 0x20ac, 0xfffd, 0x201a, 0xfffd, 0x201e, 0x2026, 0x2020, 0x2021, + 0xfffd, 0x2030, 0xfffd, 0x2039, 0xfffd, 0x00a8, 0x02c7, 0x00b8, + /* 0x90 */ + 0xfffd, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0xfffd, 0x2122, 0xfffd, 0x203a, 0xfffd, 0x00af, 0x02db, 0xfffd, + /* 0xa0 */ + 0x00a0, 0xfffd, 0x00a2, 0x00a3, 0x00a4, 0xfffd, 0x00a6, 0x00a7, + 0x00d8, 0x00a9, 0x0156, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00c6, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, + 0x00f8, 0x00b9, 0x0157, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00e6, + /* 0xc0 */ + 0x0104, 0x012e, 0x0100, 0x0106, 0x00c4, 0x00c5, 0x0118, 0x0112, + 0x010c, 0x00c9, 0x0179, 0x0116, 0x0122, 0x0136, 0x012a, 0x013b, + /* 0xd0 */ + 0x0160, 0x0143, 0x0145, 0x00d3, 0x014c, 0x00d5, 0x00d6, 0x00d7, + 0x0172, 0x0141, 0x015a, 0x016a, 0x00dc, 0x017b, 0x017d, 0x00df, + /* 0xe0 */ + 0x0105, 0x012f, 0x0101, 0x0107, 0x00e4, 0x00e5, 0x0119, 0x0113, + 0x010d, 0x00e9, 0x017a, 0x0117, 0x0123, 0x0137, 0x012b, 0x013c, + /* 0xf0 */ + 0x0161, 0x0144, 0x0146, 0x00f3, 0x014d, 0x00f5, 0x00f6, 0x00f7, + 0x0173, 0x0142, 0x015b, 0x016b, 0x00fc, 0x017c, 0x017e, 0x02d9, +}; + +static int +cp1257_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp1257_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp1257_page00[224] = { + 0xa0, 0x00, 0xa2, 0xa3, 0xa4, 0x00, 0xa6, 0xa7, /* 0xa0-0xa7 */ + 0x8d, 0xa9, 0x00, 0xab, 0xac, 0xad, 0xae, 0x9d, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0x8f, 0xb9, 0x00, 0xbb, 0xbc, 0xbd, 0xbe, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0xc4, 0xc5, 0xaf, 0x00, /* 0xc0-0xc7 */ + 0x00, 0xc9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0xd3, 0x00, 0xd5, 0xd6, 0xd7, /* 0xd0-0xd7 */ + 0xa8, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0xdf, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0xe4, 0xe5, 0xbf, 0x00, /* 0xe0-0xe7 */ + 0x00, 0xe9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0xf3, 0x00, 0xf5, 0xf6, 0xf7, /* 0xf0-0xf7 */ + 0xb8, 0x00, 0x00, 0x00, 0xfc, 0x00, 0x00, 0x00, /* 0xf8-0xff */ + /* 0x0100 */ + 0xc2, 0xe2, 0x00, 0x00, 0xc0, 0xe0, 0xc3, 0xe3, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xc8, 0xe8, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0xc7, 0xe7, 0x00, 0x00, 0xcb, 0xeb, /* 0x10-0x17 */ + 0xc6, 0xe6, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0xcc, 0xec, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0xce, 0xee, 0x00, 0x00, 0xc1, 0xe1, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xcd, 0xed, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0xcf, 0xef, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0xd9, 0xf9, 0xd1, 0xf1, 0xd2, 0xf2, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0xd4, 0xf4, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xaa, 0xba, /* 0x50-0x57 */ + 0x00, 0x00, 0xda, 0xfa, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xd0, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0xdb, 0xfb, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0xd8, 0xf8, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0xca, 0xea, 0xdd, 0xfd, 0xde, 0xfe, 0x00, /* 0x78-0x7f */ +}; +static const unsigned char cp1257_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x8e, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0xff, 0x00, 0x9e, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char cp1257_page20[48] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; + +static int +cp1257_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0180) + c = cp1257_page00[wc-0x00a0]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = cp1257_page02[wc-0x02c0]; + else if (wc >= 0x2010 && wc < 0x2040) + c = cp1257_page20[wc-0x2010]; + else if (wc == 0x20ac) + c = 0x80; + else if (wc == 0x2122) + c = 0x99; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp1258.h b/graf2d/win32gdk/gdk/src/iconv/cp1258.h new file mode 100644 index 0000000000000..578340483735a --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp1258.h @@ -0,0 +1,288 @@ +/* + * Copyright (C) 1999-2001, 2004 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP1258 + */ + +#include "flushwc.h" +#include "vietcomb.h" + +static const unsigned char cp1258_comb_table[] = { + 0xcc, 0xec, 0xde, 0xd2, 0xf2, +}; + +/* The possible bases in viet_comp_table_data: + 0x0041..0x0045, 0x0047..0x0049, 0x004B..0x0050, 0x0052..0x0057, + 0x0059..0x005A, 0x0061..0x0065, 0x0067..0x0069, 0x006B..0x0070, + 0x0072..0x0077, 0x0079..0x007A, 0x00A5, 0x00A8, 0x00C2, 0x00C5..0x00C7, + 0x00CA, 0x00CF, 0x00D3..0x00D4, 0x00D6, 0x00D8, 0x00DA, 0x00DC, 0x00E2, + 0x00E5..0x00E7, 0x00EA, 0x00EF, 0x00F3..0x00F4, 0x00F6, 0x00F8, 0x00FA, + 0x00FC, 0x0102..0x0103, 0x01A0..0x01A1, 0x01AF..0x01B0. */ +static const unsigned int cp1258_comp_bases[] = { + 0x06fdfbbe, 0x06fdfbbe, 0x00000000, 0x00000120, 0x155884e4, 0x155884e4, + 0x0000000c, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00018003 +}; + +static const unsigned short cp1258_2uni[128] = { + /* 0x80 */ + 0x20ac, 0xfffd, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, + 0x02c6, 0x2030, 0xfffd, 0x2039, 0x0152, 0xfffd, 0xfffd, 0xfffd, + /* 0x90 */ + 0xfffd, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0x02dc, 0x2122, 0xfffd, 0x203a, 0x0153, 0xfffd, 0xfffd, 0x0178, + /* 0xa0 */ + 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, + 0x00a8, 0x00a9, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, + 0x00b8, 0x00b9, 0x00ba, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf, + /* 0xc0 */ + 0x00c0, 0x00c1, 0x00c2, 0x0102, 0x00c4, 0x00c5, 0x00c6, 0x00c7, + 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x0300, 0x00cd, 0x00ce, 0x00cf, + /* 0xd0 */ + 0x0110, 0x00d1, 0x0309, 0x00d3, 0x00d4, 0x01a0, 0x00d6, 0x00d7, + 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x01af, 0x0303, 0x00df, + /* 0xe0 */ + 0x00e0, 0x00e1, 0x00e2, 0x0103, 0x00e4, 0x00e5, 0x00e6, 0x00e7, + 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x0301, 0x00ed, 0x00ee, 0x00ef, + /* 0xf0 */ + 0x0111, 0x00f1, 0x0323, 0x00f3, 0x00f4, 0x01a1, 0x00f6, 0x00f7, + 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x01b0, 0x20ab, 0x00ff, +}; + +/* In the CP1258 to Unicode direction, the state contains a buffered + character, or 0 if none. */ + +static int +cp1258_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + unsigned short wc; + unsigned short last_wc; + if (c < 0x80) { + wc = c; + } else { + wc = cp1258_2uni[c-0x80]; + if (wc == 0xfffd) + return RET_ILSEQ; + } + last_wc = conv->istate; + if (last_wc) { + if (wc >= 0x0300 && wc < 0x0340) { + /* See whether last_wc and wc can be combined. */ + unsigned int k; + unsigned int i1, i2; + switch (wc) { + case 0x0300: k = 0; break; + case 0x0301: k = 1; break; + case 0x0303: k = 2; break; + case 0x0309: k = 3; break; + case 0x0323: k = 4; break; + default: abort(); + } + i1 = viet_comp_table[k].idx; + i2 = i1 + viet_comp_table[k].len-1; + if (last_wc >= viet_comp_table_data[i1].base + && last_wc <= viet_comp_table_data[i2].base) { + unsigned int i; + for (;;) { + i = (i1+i2)>>1; + if (last_wc == viet_comp_table_data[i].base) + break; + if (last_wc < viet_comp_table_data[i].base) { + if (i1 == i) + goto not_combining; + i2 = i; + } else { + if (i1 != i) + i1 = i; + else { + i = i2; + if (last_wc == viet_comp_table_data[i].base) + break; + goto not_combining; + } + } + } + last_wc = viet_comp_table_data[i].composed; + /* Output the combined character. */ + conv->istate = 0; + *pwc = (ucs4_t) last_wc; + return 1; + } + } + not_combining: + /* Output the buffered character. */ + conv->istate = 0; + *pwc = (ucs4_t) last_wc; + return 0; /* Don't advance the input pointer. */ + } + if (wc >= 0x0041 && wc <= 0x01b0 + && ((cp1258_comp_bases[(wc - 0x0040) >> 5] >> (wc & 0x1f)) & 1)) { + /* wc is a possible match in viet_comp_table_data. Buffer it. */ + conv->istate = wc; + return RET_TOOFEW(1); + } else { + /* Output wc immediately. */ + *pwc = (ucs4_t) wc; + return 1; + } +} + +#define cp1258_flushwc normal_flushwc + +static const unsigned char cp1258_page00[88] = { + 0xc0, 0xc1, 0xc2, 0x00, 0xc4, 0xc5, 0xc6, 0xc7, /* 0xc0-0xc7 */ + 0xc8, 0xc9, 0xca, 0xcb, 0x00, 0xcd, 0xce, 0xcf, /* 0xc8-0xcf */ + 0x00, 0xd1, 0x00, 0xd3, 0xd4, 0x00, 0xd6, 0xd7, /* 0xd0-0xd7 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0x00, 0x00, 0xdf, /* 0xd8-0xdf */ + 0xe0, 0xe1, 0xe2, 0x00, 0xe4, 0xe5, 0xe6, 0xe7, /* 0xe0-0xe7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0x00, 0xed, 0xee, 0xef, /* 0xe8-0xef */ + 0x00, 0xf1, 0x00, 0xf3, 0xf4, 0x00, 0xf6, 0xf7, /* 0xf0-0xf7 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0x00, 0x00, 0xff, /* 0xf8-0xff */ + /* 0x0100 */ + 0x00, 0x00, 0xc3, 0xe3, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xd0, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ +}; +static const unsigned char cp1258_page01[104] = { + 0x00, 0x00, 0x8c, 0x9c, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x9f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x83, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xd5, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xdd, /* 0xa8-0xaf */ + 0xfd, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ +}; +static const unsigned char cp1258_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char cp1258_page03[40] = { + 0xcc, 0xec, 0x00, 0xde, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0xd2, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0xf2, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char cp1258_page20[48] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; + +static int +cp1258_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = wc; + else if (wc >= 0x00c0 && wc < 0x0118) + c = cp1258_page00[wc-0x00c0]; + else if (wc >= 0x0150 && wc < 0x01b8) + c = cp1258_page01[wc-0x0150]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = cp1258_page02[wc-0x02c0]; + else if (wc >= 0x0300 && wc < 0x0328) + c = cp1258_page03[wc-0x0300]; + else if (wc >= 0x0340 && wc < 0x0342) /* deprecated Vietnamese tone marks */ + c = cp1258_page03[wc-0x0340]; + else if (wc >= 0x2010 && wc < 0x2040) + c = cp1258_page20[wc-0x2010]; + else if (wc == 0x20ab) + c = 0xfe; + else if (wc == 0x20ac) + c = 0x80; + else if (wc == 0x2122) + c = 0x99; + if (c != 0) { + *r = c; + return 1; + } + /* Try canonical decomposition. */ + { + /* Binary search through viet_decomp_table. */ + unsigned int i1 = 0; + unsigned int i2 = sizeof(viet_decomp_table)/sizeof(viet_decomp_table[0])-1; + if (wc >= viet_decomp_table[i1].composed + && wc <= viet_decomp_table[i2].composed) { + unsigned int i; + for (;;) { + /* Here i2 - i1 > 0. */ + i = (i1+i2)>>1; + if (wc == viet_decomp_table[i].composed) + break; + if (wc < viet_decomp_table[i].composed) { + if (i1 == i) + return RET_ILUNI; + /* Here i1 < i < i2. */ + i2 = i; + } else { + /* Here i1 <= i < i2. */ + if (i1 != i) + i1 = i; + else { + /* Here i2 - i1 = 1. */ + i = i2; + if (wc == viet_decomp_table[i].composed) + break; + else + return RET_ILUNI; + } + } + } + /* Found a canonical decomposition. */ + wc = viet_decomp_table[i].base; + /* wc is one of 0x0020, 0x0041..0x005a, 0x0061..0x007a, 0x00a5, 0x00a8, + 0x00c2, 0x00c5..0x00c7, 0x00ca, 0x00cf, 0x00d3, 0x00d4, 0x00d6, + 0x00d8, 0x00da, 0x00dc, 0x00e2, 0x00e5..0x00e7, 0x00ea, 0x00ef, + 0x00f3, 0x00f4, 0x00f6, 0x00f8, 0x00fc, 0x0102, 0x0103, 0x01a0, + 0x01a1, 0x01af, 0x01b0. */ + if (wc < 0x0100) + c = wc; + else if (wc < 0x0118) + c = cp1258_page00[wc-0x00c0]; + else + c = cp1258_page01[wc-0x0150]; + if (n < 2) + return RET_TOOSMALL; + r[0] = c; + r[1] = cp1258_comb_table[viet_decomp_table[i].comb1]; + return 2; + } + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp437.h b/graf2d/win32gdk/gdk/src/iconv/cp437.h new file mode 100644 index 0000000000000..a3c8e685bb46f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp437.h @@ -0,0 +1,156 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP437 + */ + +static const unsigned short cp437_2uni[128] = { + /* 0x80 */ + 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x00e0, 0x00e5, 0x00e7, + 0x00ea, 0x00eb, 0x00e8, 0x00ef, 0x00ee, 0x00ec, 0x00c4, 0x00c5, + /* 0x90 */ + 0x00c9, 0x00e6, 0x00c6, 0x00f4, 0x00f6, 0x00f2, 0x00fb, 0x00f9, + 0x00ff, 0x00d6, 0x00dc, 0x00a2, 0x00a3, 0x00a5, 0x20a7, 0x0192, + /* 0xa0 */ + 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x00aa, 0x00ba, + 0x00bf, 0x2310, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, + 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, + /* 0xd0 */ + 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, + 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, + /* 0xe0 */ + 0x03b1, 0x00df, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, + 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x221e, 0x03c6, 0x03b5, 0x2229, + /* 0xf0 */ + 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, + 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0, +}; + +static int +cp437_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp437_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp437_page00[96] = { + 0xff, 0xad, 0x9b, 0x9c, 0x00, 0x9d, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0xa6, 0xae, 0xaa, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0xfd, 0x00, 0x00, 0xe6, 0x00, 0xfa, /* 0xb0-0xb7 */ + 0x00, 0x00, 0xa7, 0xaf, 0xac, 0xab, 0x00, 0xa8, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x8e, 0x8f, 0x92, 0x80, /* 0xc0-0xc7 */ + 0x00, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0xa5, 0x00, 0x00, 0x00, 0x00, 0x99, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x9a, 0x00, 0x00, 0xe1, /* 0xd8-0xdf */ + 0x85, 0xa0, 0x83, 0x00, 0x84, 0x86, 0x91, 0x87, /* 0xe0-0xe7 */ + 0x8a, 0x82, 0x88, 0x89, 0x8d, 0xa1, 0x8c, 0x8b, /* 0xe8-0xef */ + 0x00, 0xa4, 0x95, 0xa2, 0x93, 0x00, 0x94, 0xf6, /* 0xf0-0xf7 */ + 0x00, 0x97, 0xa3, 0x96, 0x81, 0x00, 0x00, 0x98, /* 0xf8-0xff */ +}; +static const unsigned char cp437_page03[56] = { + 0x00, 0x00, 0x00, 0xe2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0xe9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x00, 0x00, 0x00, 0xe4, 0x00, 0x00, 0xe8, 0x00, /* 0xa0-0xa7 */ + 0x00, 0xea, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0xe0, 0x00, 0x00, 0xeb, 0xee, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0xe3, 0x00, 0x00, 0xe5, 0xe7, 0x00, 0xed, 0x00, /* 0xc0-0xc7 */ +}; +static const unsigned char cp437_page22[80] = { + 0x00, 0xf9, 0xfb, 0x00, 0x00, 0x00, 0xec, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0xef, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xf7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0xf0, 0x00, 0x00, 0xf3, 0xf2, 0x00, 0x00, /* 0x60-0x67 */ +}; +static const unsigned char cp437_page23[24] = { + 0xa9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0xf4, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char cp437_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0xd5, 0xd6, 0xc9, 0xb8, 0xb7, 0xbb, /* 0x50-0x57 */ + 0xd4, 0xd3, 0xc8, 0xbe, 0xbd, 0xbc, 0xc6, 0xc7, /* 0x58-0x5f */ + 0xcc, 0xb5, 0xb6, 0xb9, 0xd1, 0xd2, 0xcb, 0xcf, /* 0x60-0x67 */ + 0xd0, 0xca, 0xd8, 0xd7, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0xdd, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xde, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp437_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = cp437_page00[wc-0x00a0]; + else if (wc == 0x0192) + c = 0x9f; + else if (wc >= 0x0390 && wc < 0x03c8) + c = cp437_page03[wc-0x0390]; + else if (wc == 0x207f) + c = 0xfc; + else if (wc == 0x20a7) + c = 0x9e; + else if (wc >= 0x2218 && wc < 0x2268) + c = cp437_page22[wc-0x2218]; + else if (wc >= 0x2310 && wc < 0x2328) + c = cp437_page23[wc-0x2310]; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp437_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp737.h b/graf2d/win32gdk/gdk/src/iconv/cp737.h new file mode 100644 index 0000000000000..955e458d043b4 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp737.h @@ -0,0 +1,141 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP737 + */ + +static const unsigned short cp737_2uni[128] = { + /* 0x80 */ + 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, 0x0398, + 0x0399, 0x039a, 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, 0x03a0, + /* 0x90 */ + 0x03a1, 0x03a3, 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, + 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, 0x03b8, + /* 0xa0 */ + 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, 0x03c0, + 0x03c1, 0x03c3, 0x03c2, 0x03c4, 0x03c5, 0x03c6, 0x03c7, 0x03c8, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, + 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, + /* 0xd0 */ + 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, + 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, + /* 0xe0 */ + 0x03c9, 0x03ac, 0x03ad, 0x03ae, 0x03ca, 0x03af, 0x03cc, 0x03cd, + 0x03cb, 0x03ce, 0x0386, 0x0388, 0x0389, 0x038a, 0x038c, 0x038e, + /* 0xf0 */ + 0x038f, 0x00b1, 0x2265, 0x2264, 0x03aa, 0x03ab, 0x00f7, 0x2248, + 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0, +}; + +static int +cp737_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp737_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp737_page00[24] = { + 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0xfd, 0x00, 0x00, 0x00, 0x00, 0xfa, /* 0xb0-0xb7 */ +}; +static const unsigned char cp737_page03[80] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xea, 0x00, /* 0x80-0x87 */ + 0xeb, 0xec, 0xed, 0x00, 0xee, 0x00, 0xef, 0xf0, /* 0x88-0x8f */ + 0x00, 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, /* 0x90-0x97 */ + 0x87, 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, /* 0x98-0x9f */ + 0x8f, 0x90, 0x00, 0x91, 0x92, 0x93, 0x94, 0x95, /* 0xa0-0xa7 */ + 0x96, 0x97, 0xf4, 0xf5, 0xe1, 0xe2, 0xe3, 0xe5, /* 0xa8-0xaf */ + 0x00, 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, /* 0xb0-0xb7 */ + 0x9f, 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, /* 0xb8-0xbf */ + 0xa7, 0xa8, 0xaa, 0xa9, 0xab, 0xac, 0xad, 0xae, /* 0xc0-0xc7 */ + 0xaf, 0xe0, 0xe4, 0xe8, 0xe6, 0xe7, 0xe9, 0x00, /* 0xc8-0xcf */ +}; +static const unsigned char cp737_page22[80] = { + 0x00, 0xf9, 0xfb, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xf7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0xf3, 0xf2, 0x00, 0x00, /* 0x60-0x67 */ +}; +static const unsigned char cp737_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0xd5, 0xd6, 0xc9, 0xb8, 0xb7, 0xbb, /* 0x50-0x57 */ + 0xd4, 0xd3, 0xc8, 0xbe, 0xbd, 0xbc, 0xc6, 0xc7, /* 0x58-0x5f */ + 0xcc, 0xb5, 0xb6, 0xb9, 0xd1, 0xd2, 0xcb, 0xcf, /* 0x60-0x67 */ + 0xd0, 0xca, 0xd8, 0xd7, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0xdd, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xde, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp737_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00b8) + c = cp737_page00[wc-0x00a0]; + else if (wc == 0x00f7) + c = 0xf6; + else if (wc >= 0x0380 && wc < 0x03d0) + c = cp737_page03[wc-0x0380]; + else if (wc == 0x207f) + c = 0xfc; + else if (wc >= 0x2218 && wc < 0x2268) + c = cp737_page22[wc-0x2218]; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp737_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp775.h b/graf2d/win32gdk/gdk/src/iconv/cp775.h new file mode 100644 index 0000000000000..b9a5a5c4eb96c --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp775.h @@ -0,0 +1,142 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP775 + */ + +static const unsigned short cp775_2uni[128] = { + /* 0x80 */ + 0x0106, 0x00fc, 0x00e9, 0x0101, 0x00e4, 0x0123, 0x00e5, 0x0107, + 0x0142, 0x0113, 0x0156, 0x0157, 0x012b, 0x0179, 0x00c4, 0x00c5, + /* 0x90 */ + 0x00c9, 0x00e6, 0x00c6, 0x014d, 0x00f6, 0x0122, 0x00a2, 0x015a, + 0x015b, 0x00d6, 0x00dc, 0x00f8, 0x00a3, 0x00d8, 0x00d7, 0x00a4, + /* 0xa0 */ + 0x0100, 0x012a, 0x00f3, 0x017b, 0x017c, 0x017a, 0x201d, 0x00a6, + 0x00a9, 0x00ae, 0x00ac, 0x00bd, 0x00bc, 0x0141, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x0104, 0x010c, 0x0118, + 0x0116, 0x2563, 0x2551, 0x2557, 0x255d, 0x012e, 0x0160, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x0172, 0x016a, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x017d, + /* 0xd0 */ + 0x0105, 0x010d, 0x0119, 0x0117, 0x012f, 0x0161, 0x0173, 0x016b, + 0x017e, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, + /* 0xe0 */ + 0x00d3, 0x00df, 0x014c, 0x0143, 0x00f5, 0x00d5, 0x00b5, 0x0144, + 0x0136, 0x0137, 0x013b, 0x013c, 0x0146, 0x0112, 0x0145, 0x2019, + /* 0xf0 */ + 0x00ad, 0x00b1, 0x201c, 0x00be, 0x00b6, 0x00a7, 0x00f7, 0x201e, + 0x00b0, 0x2219, 0x00b7, 0x00b9, 0x00b3, 0x00b2, 0x25a0, 0x00a0, +}; + +static int +cp775_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp775_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp775_page00[224] = { + 0xff, 0x00, 0x96, 0x9c, 0x9f, 0x00, 0xa7, 0xf5, /* 0xa0-0xa7 */ + 0x00, 0xa8, 0x00, 0xae, 0xaa, 0xf0, 0xa9, 0x00, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0xfd, 0xfc, 0x00, 0xe6, 0xf4, 0xfa, /* 0xb0-0xb7 */ + 0x00, 0xfb, 0x00, 0xaf, 0xac, 0xab, 0xf3, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x8e, 0x8f, 0x92, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0xe0, 0x00, 0xe5, 0x99, 0x9e, /* 0xd0-0xd7 */ + 0x9d, 0x00, 0x00, 0x00, 0x9a, 0x00, 0x00, 0xe1, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0x84, 0x86, 0x91, 0x00, /* 0xe0-0xe7 */ + 0x00, 0x82, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0xa2, 0x00, 0xe4, 0x94, 0xf6, /* 0xf0-0xf7 */ + 0x9b, 0x00, 0x00, 0x00, 0x81, 0x00, 0x00, 0x00, /* 0xf8-0xff */ + /* 0x0100 */ + 0xa0, 0x83, 0x00, 0x00, 0xb5, 0xd0, 0x80, 0x87, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xb6, 0xd1, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0xed, 0x89, 0x00, 0x00, 0xb8, 0xd3, /* 0x10-0x17 */ + 0xb7, 0xd2, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x95, 0x85, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0xa1, 0x8c, 0x00, 0x00, 0xbd, 0xd4, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe8, 0xe9, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0xea, 0xeb, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0xad, 0x88, 0xe3, 0xe7, 0xee, 0xec, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0xe2, 0x93, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x8a, 0x8b, /* 0x50-0x57 */ + 0x00, 0x00, 0x97, 0x98, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xbe, 0xd5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0xc7, 0xd7, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0xc6, 0xd6, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x8d, 0xa5, 0xa3, 0xa4, 0xcf, 0xd8, 0x00, /* 0x78-0x7f */ +}; +static const unsigned char cp775_page20[8] = { + 0x00, 0xef, 0x00, 0x00, 0xf2, 0xa6, 0xf7, 0x00, /* 0x18-0x1f */ +}; +static const unsigned char cp775_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0x00, 0x00, 0xc9, 0x00, 0x00, 0xbb, /* 0x50-0x57 */ + 0x00, 0x00, 0xc8, 0x00, 0x00, 0xbc, 0x00, 0x00, /* 0x58-0x5f */ + 0xcc, 0x00, 0x00, 0xb9, 0x00, 0x00, 0xcb, 0x00, /* 0x60-0x67 */ + 0x00, 0xca, 0x00, 0x00, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0xdd, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xde, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp775_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0180) + c = cp775_page00[wc-0x00a0]; + else if (wc >= 0x2018 && wc < 0x2020) + c = cp775_page20[wc-0x2018]; + else if (wc == 0x2219) + c = 0xf9; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp775_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp850.h b/graf2d/win32gdk/gdk/src/iconv/cp850.h new file mode 100644 index 0000000000000..25acfee148104 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp850.h @@ -0,0 +1,124 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP850 + */ + +static const unsigned short cp850_2uni[128] = { + /* 0x80 */ + 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x00e0, 0x00e5, 0x00e7, + 0x00ea, 0x00eb, 0x00e8, 0x00ef, 0x00ee, 0x00ec, 0x00c4, 0x00c5, + /* 0x90 */ + 0x00c9, 0x00e6, 0x00c6, 0x00f4, 0x00f6, 0x00f2, 0x00fb, 0x00f9, + 0x00ff, 0x00d6, 0x00dc, 0x00f8, 0x00a3, 0x00d8, 0x00d7, 0x0192, + /* 0xa0 */ + 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x00aa, 0x00ba, + 0x00bf, 0x00ae, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x00c1, 0x00c2, 0x00c0, + 0x00a9, 0x2563, 0x2551, 0x2557, 0x255d, 0x00a2, 0x00a5, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x00e3, 0x00c3, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x00a4, + /* 0xd0 */ + 0x00f0, 0x00d0, 0x00ca, 0x00cb, 0x00c8, 0x0131, 0x00cd, 0x00ce, + 0x00cf, 0x2518, 0x250c, 0x2588, 0x2584, 0x00a6, 0x00cc, 0x2580, + /* 0xe0 */ + 0x00d3, 0x00df, 0x00d4, 0x00d2, 0x00f5, 0x00d5, 0x00b5, 0x00fe, + 0x00de, 0x00da, 0x00db, 0x00d9, 0x00fd, 0x00dd, 0x00af, 0x00b4, + /* 0xf0 */ + 0x00ad, 0x00b1, 0x2017, 0x00be, 0x00b6, 0x00a7, 0x00f7, 0x00b8, + 0x00b0, 0x00a8, 0x00b7, 0x00b9, 0x00b3, 0x00b2, 0x25a0, 0x00a0, +}; + +static int +cp850_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp850_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp850_page00[96] = { + 0xff, 0xad, 0xbd, 0x9c, 0xcf, 0xbe, 0xdd, 0xf5, /* 0xa0-0xa7 */ + 0xf9, 0xb8, 0xa6, 0xae, 0xaa, 0xf0, 0xa9, 0xee, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0xfd, 0xfc, 0xef, 0xe6, 0xf4, 0xfa, /* 0xb0-0xb7 */ + 0xf7, 0xfb, 0xa7, 0xaf, 0xac, 0xab, 0xf3, 0xa8, /* 0xb8-0xbf */ + 0xb7, 0xb5, 0xb6, 0xc7, 0x8e, 0x8f, 0x92, 0x80, /* 0xc0-0xc7 */ + 0xd4, 0x90, 0xd2, 0xd3, 0xde, 0xd6, 0xd7, 0xd8, /* 0xc8-0xcf */ + 0xd1, 0xa5, 0xe3, 0xe0, 0xe2, 0xe5, 0x99, 0x9e, /* 0xd0-0xd7 */ + 0x9d, 0xeb, 0xe9, 0xea, 0x9a, 0xed, 0xe8, 0xe1, /* 0xd8-0xdf */ + 0x85, 0xa0, 0x83, 0xc6, 0x84, 0x86, 0x91, 0x87, /* 0xe0-0xe7 */ + 0x8a, 0x82, 0x88, 0x89, 0x8d, 0xa1, 0x8c, 0x8b, /* 0xe8-0xef */ + 0xd0, 0xa4, 0x95, 0xa2, 0x93, 0xe4, 0x94, 0xf6, /* 0xf0-0xf7 */ + 0x9b, 0x97, 0xa3, 0x96, 0x81, 0xec, 0xe7, 0x98, /* 0xf8-0xff */ +}; +static const unsigned char cp850_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0x00, 0x00, 0xc9, 0x00, 0x00, 0xbb, /* 0x50-0x57 */ + 0x00, 0x00, 0xc8, 0x00, 0x00, 0xbc, 0x00, 0x00, /* 0x58-0x5f */ + 0xcc, 0x00, 0x00, 0xb9, 0x00, 0x00, 0xcb, 0x00, /* 0x60-0x67 */ + 0x00, 0xca, 0x00, 0x00, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp850_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = cp850_page00[wc-0x00a0]; + else if (wc == 0x0131) + c = 0xd5; + else if (wc == 0x0192) + c = 0x9f; + else if (wc == 0x2017) + c = 0xf2; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp850_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp852.h b/graf2d/win32gdk/gdk/src/iconv/cp852.h new file mode 100644 index 0000000000000..fac7a63f15c93 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp852.h @@ -0,0 +1,143 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP852 + */ + +static const unsigned short cp852_2uni[128] = { + /* 0x80 */ + 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x016f, 0x0107, 0x00e7, + 0x0142, 0x00eb, 0x0150, 0x0151, 0x00ee, 0x0179, 0x00c4, 0x0106, + /* 0x90 */ + 0x00c9, 0x0139, 0x013a, 0x00f4, 0x00f6, 0x013d, 0x013e, 0x015a, + 0x015b, 0x00d6, 0x00dc, 0x0164, 0x0165, 0x0141, 0x00d7, 0x010d, + /* 0xa0 */ + 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x0104, 0x0105, 0x017d, 0x017e, + 0x0118, 0x0119, 0x00ac, 0x017a, 0x010c, 0x015f, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x00c1, 0x00c2, 0x011a, + 0x015e, 0x2563, 0x2551, 0x2557, 0x255d, 0x017b, 0x017c, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x0102, 0x0103, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x00a4, + /* 0xd0 */ + 0x0111, 0x0110, 0x010e, 0x00cb, 0x010f, 0x0147, 0x00cd, 0x00ce, + 0x011b, 0x2518, 0x250c, 0x2588, 0x2584, 0x0162, 0x016e, 0x2580, + /* 0xe0 */ + 0x00d3, 0x00df, 0x00d4, 0x0143, 0x0144, 0x0148, 0x0160, 0x0161, + 0x0154, 0x00da, 0x0155, 0x0170, 0x00fd, 0x00dd, 0x0163, 0x00b4, + /* 0xf0 */ + 0x00ad, 0x02dd, 0x02db, 0x02c7, 0x02d8, 0x00a7, 0x00f7, 0x00b8, + 0x00b0, 0x00a8, 0x02d9, 0x0171, 0x0158, 0x0159, 0x25a0, 0x00a0, +}; + +static int +cp852_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp852_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp852_page00[224] = { + 0xff, 0x00, 0x00, 0x00, 0xcf, 0x00, 0x00, 0xf5, /* 0xa0-0xa7 */ + 0xf9, 0x00, 0x00, 0xae, 0xaa, 0xf0, 0x00, 0x00, /* 0xa8-0xaf */ + 0xf8, 0x00, 0x00, 0x00, 0xef, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0xf7, 0x00, 0x00, 0xaf, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0xb5, 0xb6, 0x00, 0x8e, 0x00, 0x00, 0x80, /* 0xc0-0xc7 */ + 0x00, 0x90, 0x00, 0xd3, 0x00, 0xd6, 0xd7, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0xe0, 0xe2, 0x00, 0x99, 0x9e, /* 0xd0-0xd7 */ + 0x00, 0x00, 0xe9, 0x00, 0x9a, 0xed, 0x00, 0xe1, /* 0xd8-0xdf */ + 0x00, 0xa0, 0x83, 0x00, 0x84, 0x00, 0x00, 0x87, /* 0xe0-0xe7 */ + 0x00, 0x82, 0x00, 0x89, 0x00, 0xa1, 0x8c, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0xa2, 0x93, 0x00, 0x94, 0xf6, /* 0xf0-0xf7 */ + 0x00, 0x00, 0xa3, 0x00, 0x81, 0xec, 0x00, 0x00, /* 0xf8-0xff */ + /* 0x0100 */ + 0x00, 0x00, 0xc6, 0xc7, 0xa4, 0xa5, 0x8f, 0x86, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xac, 0x9f, 0xd2, 0xd4, /* 0x08-0x0f */ + 0xd1, 0xd0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xa8, 0xa9, 0xb7, 0xd8, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x91, 0x92, 0x00, 0x00, 0x95, 0x96, 0x00, /* 0x38-0x3f */ + 0x00, 0x9d, 0x88, 0xe3, 0xe4, 0x00, 0x00, 0xd5, /* 0x40-0x47 */ + 0xe5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x8a, 0x8b, 0x00, 0x00, 0xe8, 0xea, 0x00, 0x00, /* 0x50-0x57 */ + 0xfc, 0xfd, 0x97, 0x98, 0x00, 0x00, 0xb8, 0xad, /* 0x58-0x5f */ + 0xe6, 0xe7, 0xdd, 0xee, 0x9b, 0x9c, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xde, 0x85, /* 0x68-0x6f */ + 0xeb, 0xfb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x8d, 0xab, 0xbd, 0xbe, 0xa6, 0xa7, 0x00, /* 0x78-0x7f */ +}; +static const unsigned char cp852_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf3, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0xf4, 0xfa, 0x00, 0xf2, 0x00, 0xf1, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char cp852_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0x00, 0x00, 0xc9, 0x00, 0x00, 0xbb, /* 0x50-0x57 */ + 0x00, 0x00, 0xc8, 0x00, 0x00, 0xbc, 0x00, 0x00, /* 0x58-0x5f */ + 0xcc, 0x00, 0x00, 0xb9, 0x00, 0x00, 0xcb, 0x00, /* 0x60-0x67 */ + 0x00, 0xca, 0x00, 0x00, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp852_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0180) + c = cp852_page00[wc-0x00a0]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = cp852_page02[wc-0x02c0]; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp852_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp853.h b/graf2d/win32gdk/gdk/src/iconv/cp853.h new file mode 100644 index 0000000000000..fe82ae9817bc4 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp853.h @@ -0,0 +1,151 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP853 + */ + +static const unsigned short cp853_2uni[128] = { + /* 0x80 */ + 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x00e0, 0x0109, 0x00e7, + 0x00ea, 0x00eb, 0x00e8, 0x00ef, 0x00ee, 0x00ec, 0x00c4, 0x0108, + /* 0x90 */ + 0x00c9, 0x010b, 0x010a, 0x00f4, 0x00f6, 0x00f2, 0x00fb, 0x00f9, + 0x0130, 0x00d6, 0x00dc, 0x011d, 0x00a3, 0x011c, 0x00d7, 0x0135, + /* 0xa0 */ + 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x011e, 0x011f, + 0x0124, 0x0125, 0xfffd, 0x00bd, 0x0134, 0x015f, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x00c1, 0x00c2, 0x00c0, + 0x015e, 0x2563, 0x2551, 0x2557, 0x255d, 0x017b, 0x017c, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x015c, 0x015d, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x00a4, + /* 0xd0 */ + 0xfffd, 0xfffd, 0x00ca, 0x00cb, 0x00c8, 0x0131, 0x00cd, 0x00ce, + 0x00cf, 0x2518, 0x250c, 0x2588, 0x2584, 0xfffd, 0x00cc, 0x2580, + /* 0xe0 */ + 0x00d3, 0x00df, 0x00d4, 0x00d2, 0x0120, 0x0121, 0x00b5, 0x0126, + 0x0127, 0x00da, 0x00db, 0x00d9, 0x016c, 0x016d, 0xfffd, 0x00b4, + /* 0xf0 */ + 0x00ad, 0xfffd, 0x2113, 0x0149, 0x02d8, 0x00a7, 0x00f7, 0x00b8, + 0x00b0, 0x00a8, 0x02d9, 0xfffd, 0x00b3, 0x00b2, 0x25a0, 0x00a0, +}; + +static int +cp853_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp853_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp853_page00[96] = { + 0xff, 0x00, 0x00, 0x9c, 0xcf, 0x00, 0x00, 0xf5, /* 0xa0-0xa7 */ + 0xf9, 0x00, 0x00, 0xae, 0x00, 0xf0, 0x00, 0x00, /* 0xa8-0xaf */ + 0xf8, 0x00, 0xfd, 0xfc, 0xef, 0xe6, 0x00, 0x00, /* 0xb0-0xb7 */ + 0xf7, 0x00, 0x00, 0xaf, 0x00, 0xab, 0x00, 0x00, /* 0xb8-0xbf */ + 0xb7, 0xb5, 0xb6, 0x00, 0x8e, 0x00, 0x00, 0x80, /* 0xc0-0xc7 */ + 0xd4, 0x90, 0xd2, 0xd3, 0xde, 0xd6, 0xd7, 0xd8, /* 0xc8-0xcf */ + 0x00, 0xa5, 0xe3, 0xe0, 0xe2, 0x00, 0x99, 0x9e, /* 0xd0-0xd7 */ + 0x00, 0xeb, 0xe9, 0xea, 0x9a, 0x00, 0x00, 0xe1, /* 0xd8-0xdf */ + 0x85, 0xa0, 0x83, 0x00, 0x84, 0x00, 0x00, 0x87, /* 0xe0-0xe7 */ + 0x8a, 0x82, 0x88, 0x89, 0x8d, 0xa1, 0x8c, 0x8b, /* 0xe8-0xef */ + 0x00, 0xa4, 0x95, 0xa2, 0x93, 0x00, 0x94, 0xf6, /* 0xf0-0xf7 */ + 0x00, 0x97, 0xa3, 0x96, 0x81, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; +static const unsigned char cp853_page01[120] = { + 0x8f, 0x86, 0x92, 0x91, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x9d, 0x9b, 0xa6, 0xa7, /* 0x18-0x1f */ + 0xe4, 0xe5, 0x00, 0x00, 0xa8, 0xa9, 0xe7, 0xe8, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x98, 0xd5, 0x00, 0x00, 0xac, 0x9f, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0xf3, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0xc6, 0xc7, 0xb8, 0xad, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0xec, 0xed, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0xbd, 0xbe, 0x00, 0x00, 0x00, /* 0x78-0x7f */ +}; +static const unsigned char cp853_page02[8] = { + 0xf4, 0xfa, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char cp853_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0x00, 0x00, 0xc9, 0x00, 0x00, 0xbb, /* 0x50-0x57 */ + 0x00, 0x00, 0xc8, 0x00, 0x00, 0xbc, 0x00, 0x00, /* 0x58-0x5f */ + 0xcc, 0x00, 0x00, 0xb9, 0x00, 0x00, 0xcb, 0x00, /* 0x60-0x67 */ + 0x00, 0xca, 0x00, 0x00, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp853_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = cp853_page00[wc-0x00a0]; + else if (wc >= 0x0108 && wc < 0x0180) + c = cp853_page01[wc-0x0108]; + else if (wc >= 0x02d8 && wc < 0x02e0) + c = cp853_page02[wc-0x02d8]; + else if (wc == 0x2113) + c = 0xf2; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp853_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp855.h b/graf2d/win32gdk/gdk/src/iconv/cp855.h new file mode 100644 index 0000000000000..ddb8bf17d08a1 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp855.h @@ -0,0 +1,128 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP855 + */ + +static const unsigned short cp855_2uni[128] = { + /* 0x80 */ + 0x0452, 0x0402, 0x0453, 0x0403, 0x0451, 0x0401, 0x0454, 0x0404, + 0x0455, 0x0405, 0x0456, 0x0406, 0x0457, 0x0407, 0x0458, 0x0408, + /* 0x90 */ + 0x0459, 0x0409, 0x045a, 0x040a, 0x045b, 0x040b, 0x045c, 0x040c, + 0x045e, 0x040e, 0x045f, 0x040f, 0x044e, 0x042e, 0x044a, 0x042a, + /* 0xa0 */ + 0x0430, 0x0410, 0x0431, 0x0411, 0x0446, 0x0426, 0x0434, 0x0414, + 0x0435, 0x0415, 0x0444, 0x0424, 0x0433, 0x0413, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x0445, 0x0425, 0x0438, + 0x0418, 0x2563, 0x2551, 0x2557, 0x255d, 0x0439, 0x0419, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x043a, 0x041a, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x00a4, + /* 0xd0 */ + 0x043b, 0x041b, 0x043c, 0x041c, 0x043d, 0x041d, 0x043e, 0x041e, + 0x043f, 0x2518, 0x250c, 0x2588, 0x2584, 0x041f, 0x044f, 0x2580, + /* 0xe0 */ + 0x042f, 0x0440, 0x0420, 0x0441, 0x0421, 0x0442, 0x0422, 0x0443, + 0x0423, 0x0436, 0x0416, 0x0432, 0x0412, 0x044c, 0x042c, 0x2116, + /* 0xf0 */ + 0x00ad, 0x044b, 0x042b, 0x0437, 0x0417, 0x0448, 0x0428, 0x044d, + 0x042d, 0x0449, 0x0429, 0x0447, 0x0427, 0x00a7, 0x25a0, 0x00a0, +}; + +static int +cp855_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp855_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp855_page00[32] = { + 0xff, 0x00, 0x00, 0x00, 0xcf, 0x00, 0x00, 0xfd, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0xae, 0x00, 0xf0, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xaf, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ +}; +static const unsigned char cp855_page04[96] = { + 0x00, 0x85, 0x81, 0x83, 0x87, 0x89, 0x8b, 0x8d, /* 0x00-0x07 */ + 0x8f, 0x91, 0x93, 0x95, 0x97, 0x00, 0x99, 0x9b, /* 0x08-0x0f */ + 0xa1, 0xa3, 0xec, 0xad, 0xa7, 0xa9, 0xea, 0xf4, /* 0x10-0x17 */ + 0xb8, 0xbe, 0xc7, 0xd1, 0xd3, 0xd5, 0xd7, 0xdd, /* 0x18-0x1f */ + 0xe2, 0xe4, 0xe6, 0xe8, 0xab, 0xb6, 0xa5, 0xfc, /* 0x20-0x27 */ + 0xf6, 0xfa, 0x9f, 0xf2, 0xee, 0xf8, 0x9d, 0xe0, /* 0x28-0x2f */ + 0xa0, 0xa2, 0xeb, 0xac, 0xa6, 0xa8, 0xe9, 0xf3, /* 0x30-0x37 */ + 0xb7, 0xbd, 0xc6, 0xd0, 0xd2, 0xd4, 0xd6, 0xd8, /* 0x38-0x3f */ + 0xe1, 0xe3, 0xe5, 0xe7, 0xaa, 0xb5, 0xa4, 0xfb, /* 0x40-0x47 */ + 0xf5, 0xf9, 0x9e, 0xf1, 0xed, 0xf7, 0x9c, 0xde, /* 0x48-0x4f */ + 0x00, 0x84, 0x80, 0x82, 0x86, 0x88, 0x8a, 0x8c, /* 0x50-0x57 */ + 0x8e, 0x90, 0x92, 0x94, 0x96, 0x00, 0x98, 0x9a, /* 0x58-0x5f */ +}; +static const unsigned char cp855_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0x00, 0x00, 0xc9, 0x00, 0x00, 0xbb, /* 0x50-0x57 */ + 0x00, 0x00, 0xc8, 0x00, 0x00, 0xbc, 0x00, 0x00, /* 0x58-0x5f */ + 0xcc, 0x00, 0x00, 0xb9, 0x00, 0x00, 0xcb, 0x00, /* 0x60-0x67 */ + 0x00, 0xca, 0x00, 0x00, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp855_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = cp855_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x0460) + c = cp855_page04[wc-0x0400]; + else if (wc == 0x2116) + c = 0xef; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp855_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp856.h b/graf2d/win32gdk/gdk/src/iconv/cp856.h new file mode 100644 index 0000000000000..30ba80b331dcb --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp856.h @@ -0,0 +1,134 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP856 + */ + +static const unsigned short cp856_2uni[128] = { + /* 0x80 */ + 0x05d0, 0x05d1, 0x05d2, 0x05d3, 0x05d4, 0x05d5, 0x05d6, 0x05d7, + 0x05d8, 0x05d9, 0x05da, 0x05db, 0x05dc, 0x05dd, 0x05de, 0x05df, + /* 0x90 */ + 0x05e0, 0x05e1, 0x05e2, 0x05e3, 0x05e4, 0x05e5, 0x05e6, 0x05e7, + 0x05e8, 0x05e9, 0x05ea, 0xfffd, 0x00a3, 0xfffd, 0x00d7, 0xfffd, + /* 0xa0 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x00ae, 0x00ac, 0x00bd, 0x00bc, 0xfffd, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0xfffd, 0xfffd, 0xfffd, + 0x00a9, 0x2563, 0x2551, 0x2557, 0x255d, 0x00a2, 0x00a5, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0xfffd, 0xfffd, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x00a4, + /* 0xd0 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x2518, 0x250c, 0x2588, 0x2584, 0x00a6, 0xfffd, 0x2580, + /* 0xe0 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x00b5, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x00af, 0x00b4, + /* 0xf0 */ + 0x00ad, 0x00b1, 0x2017, 0x00be, 0x00b6, 0x00a7, 0x00f7, 0x00b8, + 0x00b0, 0x00a8, 0x00b7, 0x00b9, 0x00b3, 0x00b2, 0x25a0, 0x00a0, +}; + +static int +cp856_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp856_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp856_page00[88] = { + 0xff, 0x00, 0xbd, 0x9c, 0xcf, 0xbe, 0xdd, 0xf5, /* 0xa0-0xa7 */ + 0xf9, 0xb8, 0x00, 0xae, 0xaa, 0xf0, 0xa9, 0xee, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0xfd, 0xfc, 0xef, 0xe6, 0xf4, 0xfa, /* 0xb0-0xb7 */ + 0xf7, 0xfb, 0x00, 0xaf, 0xac, 0xab, 0xf3, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9e, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf6, /* 0xf0-0xf7 */ +}; +static const unsigned char cp856_page05[32] = { + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, /* 0xd0-0xd7 */ + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, /* 0xd8-0xdf */ + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, /* 0xe0-0xe7 */ + 0x98, 0x99, 0x9a, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ +}; +static const unsigned char cp856_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0x00, 0x00, 0xc9, 0x00, 0x00, 0xbb, /* 0x50-0x57 */ + 0x00, 0x00, 0xc8, 0x00, 0x00, 0xbc, 0x00, 0x00, /* 0x58-0x5f */ + 0xcc, 0x00, 0x00, 0xb9, 0x00, 0x00, 0xcb, 0x00, /* 0x60-0x67 */ + 0x00, 0xca, 0x00, 0x00, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp856_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00f8) + c = cp856_page00[wc-0x00a0]; + else if (wc >= 0x05d0 && wc < 0x05f0) + c = cp856_page05[wc-0x05d0]; + else if (wc == 0x2017) + c = 0xf2; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp856_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp857.h b/graf2d/win32gdk/gdk/src/iconv/cp857.h new file mode 100644 index 0000000000000..09de722d21506 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp857.h @@ -0,0 +1,138 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP857 + */ + +static const unsigned short cp857_2uni[128] = { + /* 0x80 */ + 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x00e0, 0x00e5, 0x00e7, + 0x00ea, 0x00eb, 0x00e8, 0x00ef, 0x00ee, 0x0131, 0x00c4, 0x00c5, + /* 0x90 */ + 0x00c9, 0x00e6, 0x00c6, 0x00f4, 0x00f6, 0x00f2, 0x00fb, 0x00f9, + 0x0130, 0x00d6, 0x00dc, 0x00f8, 0x00a3, 0x00d8, 0x015e, 0x015f, + /* 0xa0 */ + 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x011e, 0x011f, + 0x00bf, 0x00ae, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x00c1, 0x00c2, 0x00c0, + 0x00a9, 0x2563, 0x2551, 0x2557, 0x255d, 0x00a2, 0x00a5, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x00e3, 0x00c3, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x00a4, + /* 0xd0 */ + 0x00ba, 0x00aa, 0x00ca, 0x00cb, 0x00c8, 0xfffd, 0x00cd, 0x00ce, + 0x00cf, 0x2518, 0x250c, 0x2588, 0x2584, 0x00a6, 0x00cc, 0x2580, + /* 0xe0 */ + 0x00d3, 0x00df, 0x00d4, 0x00d2, 0x00f5, 0x00d5, 0x00b5, 0xfffd, + 0x00d7, 0x00da, 0x00db, 0x00d9, 0x00ec, 0x00ff, 0x00af, 0x00b4, + /* 0xf0 */ + 0x00ad, 0x00b1, 0xfffd, 0x00be, 0x00b6, 0x00a7, 0x00f7, 0x00b8, + 0x00b0, 0x00a8, 0x00b7, 0x00b9, 0x00b3, 0x00b2, 0x25a0, 0x00a0, +}; + +static int +cp857_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp857_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp857_page00[96] = { + 0xff, 0xad, 0xbd, 0x9c, 0xcf, 0xbe, 0xdd, 0xf5, /* 0xa0-0xa7 */ + 0xf9, 0xb8, 0xd1, 0xae, 0xaa, 0xf0, 0xa9, 0xee, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0xfd, 0xfc, 0xef, 0xe6, 0xf4, 0xfa, /* 0xb0-0xb7 */ + 0xf7, 0xfb, 0xd0, 0xaf, 0xac, 0xab, 0xf3, 0xa8, /* 0xb8-0xbf */ + 0xb7, 0xb5, 0xb6, 0xc7, 0x8e, 0x8f, 0x92, 0x80, /* 0xc0-0xc7 */ + 0xd4, 0x90, 0xd2, 0xd3, 0xde, 0xd6, 0xd7, 0xd8, /* 0xc8-0xcf */ + 0x00, 0xa5, 0xe3, 0xe0, 0xe2, 0xe5, 0x99, 0xe8, /* 0xd0-0xd7 */ + 0x9d, 0xeb, 0xe9, 0xea, 0x9a, 0x00, 0x00, 0xe1, /* 0xd8-0xdf */ + 0x85, 0xa0, 0x83, 0xc6, 0x84, 0x86, 0x91, 0x87, /* 0xe0-0xe7 */ + 0x8a, 0x82, 0x88, 0x89, 0xec, 0xa1, 0x8c, 0x8b, /* 0xe8-0xef */ + 0x00, 0xa4, 0x95, 0xa2, 0x93, 0xe4, 0x94, 0xf6, /* 0xf0-0xf7 */ + 0x9b, 0x97, 0xa3, 0x96, 0x81, 0x00, 0x00, 0xed, /* 0xf8-0xff */ +}; +static const unsigned char cp857_page01[72] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa6, 0xa7, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x98, 0x8d, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9e, 0x9f, /* 0x58-0x5f */ +}; +static const unsigned char cp857_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0x00, 0x00, 0xc9, 0x00, 0x00, 0xbb, /* 0x50-0x57 */ + 0x00, 0x00, 0xc8, 0x00, 0x00, 0xbc, 0x00, 0x00, /* 0x58-0x5f */ + 0xcc, 0x00, 0x00, 0xb9, 0x00, 0x00, 0xcb, 0x00, /* 0x60-0x67 */ + 0x00, 0xca, 0x00, 0x00, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp857_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = cp857_page00[wc-0x00a0]; + else if (wc >= 0x0118 && wc < 0x0160) + c = cp857_page01[wc-0x0118]; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp857_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp858.h b/graf2d/win32gdk/gdk/src/iconv/cp858.h new file mode 100644 index 0000000000000..dd26d0a27e254 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp858.h @@ -0,0 +1,61 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP858 + */ + +static int +cp858_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else if (c == 0xd5) + *pwc = 0x20ac; + else + *pwc = (ucs4_t) cp850_2uni[c-0x80]; + return 1; +} + +static int +cp858_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = cp850_page00[wc-0x00a0]; + else if (wc == 0x0192) + c = 0x9f; + else if (wc == 0x2017) + c = 0xf2; + else if (wc == 0x20ac) + c = 0xd5; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp850_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp860.h b/graf2d/win32gdk/gdk/src/iconv/cp860.h new file mode 100644 index 0000000000000..2cca2f12ff9b4 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp860.h @@ -0,0 +1,149 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP860 + */ + +static const unsigned short cp860_2uni[128] = { + /* 0x80 */ + 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e3, 0x00e0, 0x00c1, 0x00e7, + 0x00ea, 0x00ca, 0x00e8, 0x00cd, 0x00d4, 0x00ec, 0x00c3, 0x00c2, + /* 0x90 */ + 0x00c9, 0x00c0, 0x00c8, 0x00f4, 0x00f5, 0x00f2, 0x00da, 0x00f9, + 0x00cc, 0x00d5, 0x00dc, 0x00a2, 0x00a3, 0x00d9, 0x20a7, 0x00d3, + /* 0xa0 */ + 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x00aa, 0x00ba, + 0x00bf, 0x00d2, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, + 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, + /* 0xd0 */ + 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, + 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, + /* 0xe0 */ + 0x03b1, 0x00df, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, + 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x221e, 0x03c6, 0x03b5, 0x2229, + /* 0xf0 */ + 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, + 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0, +}; + +static int +cp860_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp860_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp860_page00[96] = { + 0xff, 0xad, 0x9b, 0x9c, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0xa6, 0xae, 0xaa, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0xfd, 0x00, 0x00, 0xe6, 0x00, 0xfa, /* 0xb0-0xb7 */ + 0x00, 0x00, 0xa7, 0xaf, 0xac, 0xab, 0x00, 0xa8, /* 0xb8-0xbf */ + 0x91, 0x86, 0x8f, 0x8e, 0x00, 0x00, 0x00, 0x80, /* 0xc0-0xc7 */ + 0x92, 0x90, 0x89, 0x00, 0x98, 0x8b, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0xa5, 0xa9, 0x9f, 0x8c, 0x99, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x9d, 0x96, 0x00, 0x9a, 0x00, 0x00, 0xe1, /* 0xd8-0xdf */ + 0x85, 0xa0, 0x83, 0x84, 0x00, 0x00, 0x00, 0x87, /* 0xe0-0xe7 */ + 0x8a, 0x82, 0x88, 0x00, 0x8d, 0xa1, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0xa4, 0x95, 0xa2, 0x93, 0x94, 0x00, 0xf6, /* 0xf0-0xf7 */ + 0x00, 0x97, 0xa3, 0x00, 0x81, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; +static const unsigned char cp860_page03[56] = { + 0x00, 0x00, 0x00, 0xe2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0xe9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x00, 0x00, 0x00, 0xe4, 0x00, 0x00, 0xe8, 0x00, /* 0xa0-0xa7 */ + 0x00, 0xea, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0xe0, 0x00, 0x00, 0xeb, 0xee, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0xe3, 0x00, 0x00, 0xe5, 0xe7, 0x00, 0xed, 0x00, /* 0xc0-0xc7 */ +}; +static const unsigned char cp860_page22[80] = { + 0x00, 0xf9, 0xfb, 0x00, 0x00, 0x00, 0xec, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0xef, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xf7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0xf0, 0x00, 0x00, 0xf3, 0xf2, 0x00, 0x00, /* 0x60-0x67 */ +}; +static const unsigned char cp860_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0xd5, 0xd6, 0xc9, 0xb8, 0xb7, 0xbb, /* 0x50-0x57 */ + 0xd4, 0xd3, 0xc8, 0xbe, 0xbd, 0xbc, 0xc6, 0xc7, /* 0x58-0x5f */ + 0xcc, 0xb5, 0xb6, 0xb9, 0xd1, 0xd2, 0xcb, 0xcf, /* 0x60-0x67 */ + 0xd0, 0xca, 0xd8, 0xd7, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0xdd, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xde, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp860_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = cp860_page00[wc-0x00a0]; + else if (wc >= 0x0390 && wc < 0x03c8) + c = cp860_page03[wc-0x0390]; + else if (wc == 0x207f) + c = 0xfc; + else if (wc == 0x20a7) + c = 0x9e; + else if (wc >= 0x2218 && wc < 0x2268) + c = cp860_page22[wc-0x2218]; + else if (wc >= 0x2320 && wc < 0x2322) + c = wc-0x222c; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp860_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp861.h b/graf2d/win32gdk/gdk/src/iconv/cp861.h new file mode 100644 index 0000000000000..07bcf5f2d8af9 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp861.h @@ -0,0 +1,156 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP861 + */ + +static const unsigned short cp861_2uni[128] = { + /* 0x80 */ + 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x00e0, 0x00e5, 0x00e7, + 0x00ea, 0x00eb, 0x00e8, 0x00d0, 0x00f0, 0x00de, 0x00c4, 0x00c5, + /* 0x90 */ + 0x00c9, 0x00e6, 0x00c6, 0x00f4, 0x00f6, 0x00fe, 0x00fb, 0x00dd, + 0x00fd, 0x00d6, 0x00dc, 0x00f8, 0x00a3, 0x00d8, 0x20a7, 0x0192, + /* 0xa0 */ + 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00c1, 0x00cd, 0x00d3, 0x00da, + 0x00bf, 0x2310, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, + 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, + /* 0xd0 */ + 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, + 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, + /* 0xe0 */ + 0x03b1, 0x00df, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, + 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x221e, 0x03c6, 0x03b5, 0x2229, + /* 0xf0 */ + 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, + 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0, +}; + +static int +cp861_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp861_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp861_page00[96] = { + 0xff, 0xad, 0x00, 0x9c, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0xae, 0xaa, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0xfd, 0x00, 0x00, 0xe6, 0x00, 0xfa, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xaf, 0xac, 0xab, 0x00, 0xa8, /* 0xb8-0xbf */ + 0x00, 0xa4, 0x00, 0x00, 0x8e, 0x8f, 0x92, 0x80, /* 0xc0-0xc7 */ + 0x00, 0x90, 0x00, 0x00, 0x00, 0xa5, 0x00, 0x00, /* 0xc8-0xcf */ + 0x8b, 0x00, 0x00, 0xa6, 0x00, 0x00, 0x99, 0x00, /* 0xd0-0xd7 */ + 0x9d, 0x00, 0xa7, 0x00, 0x9a, 0x97, 0x8d, 0xe1, /* 0xd8-0xdf */ + 0x85, 0xa0, 0x83, 0x00, 0x84, 0x86, 0x91, 0x87, /* 0xe0-0xe7 */ + 0x8a, 0x82, 0x88, 0x89, 0x00, 0xa1, 0x00, 0x00, /* 0xe8-0xef */ + 0x8c, 0x00, 0x00, 0xa2, 0x93, 0x00, 0x94, 0xf6, /* 0xf0-0xf7 */ + 0x9b, 0x00, 0xa3, 0x96, 0x81, 0x98, 0x95, 0x00, /* 0xf8-0xff */ +}; +static const unsigned char cp861_page03[56] = { + 0x00, 0x00, 0x00, 0xe2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0xe9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x00, 0x00, 0x00, 0xe4, 0x00, 0x00, 0xe8, 0x00, /* 0xa0-0xa7 */ + 0x00, 0xea, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0xe0, 0x00, 0x00, 0xeb, 0xee, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0xe3, 0x00, 0x00, 0xe5, 0xe7, 0x00, 0xed, 0x00, /* 0xc0-0xc7 */ +}; +static const unsigned char cp861_page22[80] = { + 0x00, 0xf9, 0xfb, 0x00, 0x00, 0x00, 0xec, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0xef, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xf7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0xf0, 0x00, 0x00, 0xf3, 0xf2, 0x00, 0x00, /* 0x60-0x67 */ +}; +static const unsigned char cp861_page23[24] = { + 0xa9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0xf4, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char cp861_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0xd5, 0xd6, 0xc9, 0xb8, 0xb7, 0xbb, /* 0x50-0x57 */ + 0xd4, 0xd3, 0xc8, 0xbe, 0xbd, 0xbc, 0xc6, 0xc7, /* 0x58-0x5f */ + 0xcc, 0xb5, 0xb6, 0xb9, 0xd1, 0xd2, 0xcb, 0xcf, /* 0x60-0x67 */ + 0xd0, 0xca, 0xd8, 0xd7, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0xdd, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xde, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp861_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = cp861_page00[wc-0x00a0]; + else if (wc == 0x0192) + c = 0x9f; + else if (wc >= 0x0390 && wc < 0x03c8) + c = cp861_page03[wc-0x0390]; + else if (wc == 0x207f) + c = 0xfc; + else if (wc == 0x20a7) + c = 0x9e; + else if (wc >= 0x2218 && wc < 0x2268) + c = cp861_page22[wc-0x2218]; + else if (wc >= 0x2310 && wc < 0x2328) + c = cp861_page23[wc-0x2310]; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp861_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp862.h b/graf2d/win32gdk/gdk/src/iconv/cp862.h new file mode 100644 index 0000000000000..623fc4d5fa5a5 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp862.h @@ -0,0 +1,155 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP862 + */ + +static const unsigned short cp862_2uni[128] = { + /* 0x80 */ + 0x05d0, 0x05d1, 0x05d2, 0x05d3, 0x05d4, 0x05d5, 0x05d6, 0x05d7, + 0x05d8, 0x05d9, 0x05da, 0x05db, 0x05dc, 0x05dd, 0x05de, 0x05df, + /* 0x90 */ + 0x05e0, 0x05e1, 0x05e2, 0x05e3, 0x05e4, 0x05e5, 0x05e6, 0x05e7, + 0x05e8, 0x05e9, 0x05ea, 0x00a2, 0x00a3, 0x00a5, 0x20a7, 0x0192, + /* 0xa0 */ + 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x00aa, 0x00ba, + 0x00bf, 0x2310, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, + 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, + /* 0xd0 */ + 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, + 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, + /* 0xe0 */ + 0x03b1, 0x00df, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, + 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x221e, 0x03c6, 0x03b5, 0x2229, + /* 0xf0 */ + 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, + 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0, +}; + +static int +cp862_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp862_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp862_page00[96] = { + 0xff, 0xad, 0x9b, 0x9c, 0x00, 0x9d, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0xa6, 0xae, 0xaa, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0xfd, 0x00, 0x00, 0xe6, 0x00, 0xfa, /* 0xb0-0xb7 */ + 0x00, 0x00, 0xa7, 0xaf, 0xac, 0xab, 0x00, 0xa8, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0xa5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe1, /* 0xd8-0xdf */ + 0x00, 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xa1, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0xa4, 0x00, 0xa2, 0x00, 0x00, 0x00, 0xf6, /* 0xf0-0xf7 */ + 0x00, 0x00, 0xa3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; +static const unsigned char cp862_page03[56] = { + 0x00, 0x00, 0x00, 0xe2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0xe9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x00, 0x00, 0x00, 0xe4, 0x00, 0x00, 0xe8, 0x00, /* 0xa0-0xa7 */ + 0x00, 0xea, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0xe0, 0x00, 0x00, 0xeb, 0xee, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0xe3, 0x00, 0x00, 0xe5, 0xe7, 0x00, 0xed, 0x00, /* 0xc0-0xc7 */ +}; +static const unsigned char cp862_page22[80] = { + 0x00, 0xf9, 0xfb, 0x00, 0x00, 0x00, 0xec, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0xef, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xf7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0xf0, 0x00, 0x00, 0xf3, 0xf2, 0x00, 0x00, /* 0x60-0x67 */ +}; +static const unsigned char cp862_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0xd5, 0xd6, 0xc9, 0xb8, 0xb7, 0xbb, /* 0x50-0x57 */ + 0xd4, 0xd3, 0xc8, 0xbe, 0xbd, 0xbc, 0xc6, 0xc7, /* 0x58-0x5f */ + 0xcc, 0xb5, 0xb6, 0xb9, 0xd1, 0xd2, 0xcb, 0xcf, /* 0x60-0x67 */ + 0xd0, 0xca, 0xd8, 0xd7, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0xdd, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xde, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp862_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = cp862_page00[wc-0x00a0]; + else if (wc == 0x0192) + c = 0x9f; + else if (wc >= 0x0390 && wc < 0x03c8) + c = cp862_page03[wc-0x0390]; + else if (wc >= 0x05d0 && wc < 0x05eb) + c = wc-0x0550; + else if (wc == 0x207f) + c = 0xfc; + else if (wc == 0x20a7) + c = 0x9e; + else if (wc >= 0x2218 && wc < 0x2268) + c = cp862_page22[wc-0x2218]; + else if (wc == 0x2310) + c = 0xa9; + else if (wc >= 0x2320 && wc < 0x2322) + c = wc-0x222c; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp862_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp863.h b/graf2d/win32gdk/gdk/src/iconv/cp863.h new file mode 100644 index 0000000000000..5890ad423d506 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp863.h @@ -0,0 +1,156 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP863 + */ + +static const unsigned short cp863_2uni[128] = { + /* 0x80 */ + 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00c2, 0x00e0, 0x00b6, 0x00e7, + 0x00ea, 0x00eb, 0x00e8, 0x00ef, 0x00ee, 0x2017, 0x00c0, 0x00a7, + /* 0x90 */ + 0x00c9, 0x00c8, 0x00ca, 0x00f4, 0x00cb, 0x00cf, 0x00fb, 0x00f9, + 0x00a4, 0x00d4, 0x00dc, 0x00a2, 0x00a3, 0x00d9, 0x00db, 0x0192, + /* 0xa0 */ + 0x00a6, 0x00b4, 0x00f3, 0x00fa, 0x00a8, 0x00b8, 0x00b3, 0x00af, + 0x00ce, 0x2310, 0x00ac, 0x00bd, 0x00bc, 0x00be, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, + 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, + /* 0xd0 */ + 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, + 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, + /* 0xe0 */ + 0x03b1, 0x00df, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, + 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x221e, 0x03c6, 0x03b5, 0x2229, + /* 0xf0 */ + 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, + 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0, +}; + +static int +cp863_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp863_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp863_page00[96] = { + 0xff, 0x00, 0x9b, 0x9c, 0x98, 0x00, 0xa0, 0x8f, /* 0xa0-0xa7 */ + 0xa4, 0x00, 0x00, 0xae, 0xaa, 0x00, 0x00, 0xa7, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0xfd, 0xa6, 0xa1, 0xe6, 0x86, 0xfa, /* 0xb0-0xb7 */ + 0xa5, 0x00, 0x00, 0xaf, 0xac, 0xab, 0xad, 0x00, /* 0xb8-0xbf */ + 0x8e, 0x00, 0x84, 0x00, 0x00, 0x00, 0x00, 0x80, /* 0xc0-0xc7 */ + 0x91, 0x90, 0x92, 0x94, 0x00, 0x00, 0xa8, 0x95, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x99, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x9d, 0x00, 0x9e, 0x9a, 0x00, 0x00, 0xe1, /* 0xd8-0xdf */ + 0x85, 0x00, 0x83, 0x00, 0x00, 0x00, 0x00, 0x87, /* 0xe0-0xe7 */ + 0x8a, 0x82, 0x88, 0x89, 0x00, 0x00, 0x8c, 0x8b, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0xa2, 0x93, 0x00, 0x00, 0xf6, /* 0xf0-0xf7 */ + 0x00, 0x97, 0xa3, 0x96, 0x81, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; +static const unsigned char cp863_page03[56] = { + 0x00, 0x00, 0x00, 0xe2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0xe9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x00, 0x00, 0x00, 0xe4, 0x00, 0x00, 0xe8, 0x00, /* 0xa0-0xa7 */ + 0x00, 0xea, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0xe0, 0x00, 0x00, 0xeb, 0xee, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0xe3, 0x00, 0x00, 0xe5, 0xe7, 0x00, 0xed, 0x00, /* 0xc0-0xc7 */ +}; +static const unsigned char cp863_page22[80] = { + 0x00, 0xf9, 0xfb, 0x00, 0x00, 0x00, 0xec, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0xef, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xf7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0xf0, 0x00, 0x00, 0xf3, 0xf2, 0x00, 0x00, /* 0x60-0x67 */ +}; +static const unsigned char cp863_page23[24] = { + 0xa9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0xf4, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char cp863_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0xd5, 0xd6, 0xc9, 0xb8, 0xb7, 0xbb, /* 0x50-0x57 */ + 0xd4, 0xd3, 0xc8, 0xbe, 0xbd, 0xbc, 0xc6, 0xc7, /* 0x58-0x5f */ + 0xcc, 0xb5, 0xb6, 0xb9, 0xd1, 0xd2, 0xcb, 0xcf, /* 0x60-0x67 */ + 0xd0, 0xca, 0xd8, 0xd7, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0xdd, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xde, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp863_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = cp863_page00[wc-0x00a0]; + else if (wc == 0x0192) + c = 0x9f; + else if (wc >= 0x0390 && wc < 0x03c8) + c = cp863_page03[wc-0x0390]; + else if (wc == 0x2017) + c = 0x8d; + else if (wc == 0x207f) + c = 0xfc; + else if (wc >= 0x2218 && wc < 0x2268) + c = cp863_page22[wc-0x2218]; + else if (wc >= 0x2310 && wc < 0x2328) + c = cp863_page23[wc-0x2310]; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp863_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp864.h b/graf2d/win32gdk/gdk/src/iconv/cp864.h new file mode 100644 index 0000000000000..a1d8c4a23fd9c --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp864.h @@ -0,0 +1,188 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP864 + */ + +static const unsigned short cp864_2uni_1[16] = { + /* 0x20 */ + 0x0020, 0x0021, 0x0022, 0x0023, 0x0024, 0x066a, 0x0026, 0x0027, + 0x0028, 0x0029, 0x002a, 0x002b, 0x002c, 0x002d, 0x002e, 0x002f, +}; +static const unsigned short cp864_2uni_2[128] = { + /* 0x80 */ + 0x00b0, 0x00b7, 0x2219, 0x221a, 0x2592, 0x2500, 0x2502, 0x253c, + 0x2524, 0x252c, 0x251c, 0x2534, 0x2510, 0x250c, 0x2514, 0x2518, + /* 0x90 */ + 0x03b2, 0x221e, 0x03c6, 0x00b1, 0x00bd, 0x00bc, 0x2248, 0x00ab, + 0x00bb, 0xfef7, 0xfef8, 0xfffd, 0xfffd, 0xfefb, 0xfefc, 0xfffd, + /* 0xa0 */ + 0x00a0, 0x00ad, 0xfe82, 0x00a3, 0x00a4, 0xfe84, 0xfffd, 0xfffd, + 0xfe8e, 0xfe8f, 0xfe95, 0xfe99, 0x060c, 0xfe9d, 0xfea1, 0xfea5, + /* 0xb0 */ + 0x0660, 0x0661, 0x0662, 0x0663, 0x0664, 0x0665, 0x0666, 0x0667, + 0x0668, 0x0669, 0xfed1, 0x061b, 0xfeb1, 0xfeb5, 0xfeb9, 0x061f, + /* 0xc0 */ + 0x00a2, 0xfe80, 0xfe81, 0xfe83, 0xfe85, 0xfeca, 0xfe8b, 0xfe8d, + 0xfe91, 0xfe93, 0xfe97, 0xfe9b, 0xfe9f, 0xfea3, 0xfea7, 0xfea9, + /* 0xd0 */ + 0xfeab, 0xfead, 0xfeaf, 0xfeb3, 0xfeb7, 0xfebb, 0xfebf, 0xfec1, + 0xfec5, 0xfecb, 0xfecf, 0x00a6, 0x00ac, 0x00f7, 0x00d7, 0xfec9, + /* 0xe0 */ + 0x0640, 0xfed3, 0xfed7, 0xfedb, 0xfedf, 0xfee3, 0xfee7, 0xfeeb, + 0xfeed, 0xfeef, 0xfef3, 0xfebd, 0xfecc, 0xfece, 0xfecd, 0xfee1, + /* 0xf0 */ + 0xfe7d, 0x0651, 0xfee5, 0xfee9, 0xfeec, 0xfef0, 0xfef2, 0xfed0, + 0xfed5, 0xfef5, 0xfef6, 0xfedd, 0xfed9, 0xfef1, 0x25a0, 0xfffd, +}; + +static int +cp864_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x20) { + *pwc = (ucs4_t) c; + return 1; + } + else if (c < 0x30) { + *pwc = (ucs4_t) cp864_2uni_1[c-0x20]; + return 1; + } + else if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp864_2uni_2[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp864_page00[8] = { + 0x20, 0x21, 0x22, 0x23, 0x24, 0x00, 0x26, 0x27, /* 0x20-0x27 */ +}; +static const unsigned char cp864_page00_1[88] = { + 0xa0, 0x00, 0xc0, 0xa3, 0xa4, 0x00, 0xdb, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x97, 0xdc, 0xa1, 0x00, 0x00, /* 0xa8-0xaf */ + 0x80, 0x93, 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x98, 0x95, 0x94, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xde, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xdd, /* 0xf0-0xf7 */ +}; +static const unsigned char cp864_page06[104] = { + 0x00, 0x00, 0x00, 0x00, 0xac, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0xbb, 0x00, 0x00, 0x00, 0xbf, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0xf1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, /* 0x60-0x67 */ + 0xb8, 0xb9, 0x25, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ +}; +static const unsigned char cp864_page22[56] = { + 0x00, 0x82, 0x83, 0x00, 0x00, 0x00, 0x91, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x96, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ +}; +static const unsigned char cp864_page25[64] = { + 0x85, 0x00, 0x86, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x8d, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x8c, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x8f, 0x00, 0x00, 0x00, 0x8a, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x89, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x8b, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x87, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; +static const unsigned char cp864_pagefe[136] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x00, 0x00, /* 0x78-0x7f */ + 0xc1, 0xc2, 0xa2, 0xc3, 0xa5, 0xc4, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0xc6, 0x00, 0xc7, 0xa8, 0xa9, /* 0x88-0x8f */ + 0x00, 0xc8, 0x00, 0xc9, 0x00, 0xaa, 0x00, 0xca, /* 0x90-0x97 */ + 0x00, 0xab, 0x00, 0xcb, 0x00, 0xad, 0x00, 0xcc, /* 0x98-0x9f */ + 0x00, 0xae, 0x00, 0xcd, 0x00, 0xaf, 0x00, 0xce, /* 0xa0-0xa7 */ + 0x00, 0xcf, 0x00, 0xd0, 0x00, 0xd1, 0x00, 0xd2, /* 0xa8-0xaf */ + 0x00, 0xbc, 0x00, 0xd3, 0x00, 0xbd, 0x00, 0xd4, /* 0xb0-0xb7 */ + 0x00, 0xbe, 0x00, 0xd5, 0x00, 0xeb, 0x00, 0xd6, /* 0xb8-0xbf */ + 0x00, 0xd7, 0x00, 0x00, 0x00, 0xd8, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0xdf, 0xc5, 0xd9, 0xec, 0xee, 0xed, 0xda, /* 0xc8-0xcf */ + 0xf7, 0xba, 0x00, 0xe1, 0x00, 0xf8, 0x00, 0xe2, /* 0xd0-0xd7 */ + 0x00, 0xfc, 0x00, 0xe3, 0x00, 0xfb, 0x00, 0xe4, /* 0xd8-0xdf */ + 0x00, 0xef, 0x00, 0xe5, 0x00, 0xf2, 0x00, 0xe6, /* 0xe0-0xe7 */ + 0x00, 0xf3, 0x00, 0xe7, 0xf4, 0xe8, 0x00, 0xe9, /* 0xe8-0xef */ + 0xf5, 0xfd, 0xf6, 0xea, 0x00, 0xf9, 0xfa, 0x99, /* 0xf0-0xf7 */ + 0x9a, 0x00, 0x00, 0x9d, 0x9e, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; + +static int +cp864_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0020) { + *r = wc; + return 1; + } + else if (wc >= 0x0020 && wc < 0x0028) + c = cp864_page00[wc-0x0020]; + else if (wc >= 0x0028 && wc < 0x0080) + c = wc; + else if (wc >= 0x00a0 && wc < 0x00f8) + c = cp864_page00_1[wc-0x00a0]; + else if (wc == 0x03b2) + c = 0x90; + else if (wc == 0x03c6) + c = 0x92; + else if (wc >= 0x0608 && wc < 0x0670) + c = cp864_page06[wc-0x0608]; + else if (wc >= 0x2218 && wc < 0x2250) + c = cp864_page22[wc-0x2218]; + else if (wc >= 0x2500 && wc < 0x2540) + c = cp864_page25[wc-0x2500]; + else if (wc == 0x2592) + c = 0x84; + else if (wc == 0x25a0) + c = 0xfe; + else if (wc >= 0xfe78 && wc < 0xff00) + c = cp864_pagefe[wc-0xfe78]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp865.h b/graf2d/win32gdk/gdk/src/iconv/cp865.h new file mode 100644 index 0000000000000..3944916d9fd25 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp865.h @@ -0,0 +1,156 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP865 + */ + +static const unsigned short cp865_2uni[128] = { + /* 0x80 */ + 0x00c7, 0x00fc, 0x00e9, 0x00e2, 0x00e4, 0x00e0, 0x00e5, 0x00e7, + 0x00ea, 0x00eb, 0x00e8, 0x00ef, 0x00ee, 0x00ec, 0x00c4, 0x00c5, + /* 0x90 */ + 0x00c9, 0x00e6, 0x00c6, 0x00f4, 0x00f6, 0x00f2, 0x00fb, 0x00f9, + 0x00ff, 0x00d6, 0x00dc, 0x00f8, 0x00a3, 0x00d8, 0x20a7, 0x0192, + /* 0xa0 */ + 0x00e1, 0x00ed, 0x00f3, 0x00fa, 0x00f1, 0x00d1, 0x00aa, 0x00ba, + 0x00bf, 0x2310, 0x00ac, 0x00bd, 0x00bc, 0x00a1, 0x00ab, 0x00a4, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, + 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, + /* 0xd0 */ + 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, + 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, + /* 0xe0 */ + 0x03b1, 0x00df, 0x0393, 0x03c0, 0x03a3, 0x03c3, 0x00b5, 0x03c4, + 0x03a6, 0x0398, 0x03a9, 0x03b4, 0x221e, 0x03c6, 0x03b5, 0x2229, + /* 0xf0 */ + 0x2261, 0x00b1, 0x2265, 0x2264, 0x2320, 0x2321, 0x00f7, 0x2248, + 0x00b0, 0x2219, 0x00b7, 0x221a, 0x207f, 0x00b2, 0x25a0, 0x00a0, +}; + +static int +cp865_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp865_2uni[c-0x80]; + return 1; +} + +static const unsigned char cp865_page00[96] = { + 0xff, 0xad, 0x00, 0x9c, 0xaf, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0xa6, 0xae, 0xaa, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0xfd, 0x00, 0x00, 0xe6, 0x00, 0xfa, /* 0xb0-0xb7 */ + 0x00, 0x00, 0xa7, 0x00, 0xac, 0xab, 0x00, 0xa8, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x8e, 0x8f, 0x92, 0x80, /* 0xc0-0xc7 */ + 0x00, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0xa5, 0x00, 0x00, 0x00, 0x00, 0x99, 0x00, /* 0xd0-0xd7 */ + 0x9d, 0x00, 0x00, 0x00, 0x9a, 0x00, 0x00, 0xe1, /* 0xd8-0xdf */ + 0x85, 0xa0, 0x83, 0x00, 0x84, 0x86, 0x91, 0x87, /* 0xe0-0xe7 */ + 0x8a, 0x82, 0x88, 0x89, 0x8d, 0xa1, 0x8c, 0x8b, /* 0xe8-0xef */ + 0x00, 0xa4, 0x95, 0xa2, 0x93, 0x00, 0x94, 0xf6, /* 0xf0-0xf7 */ + 0x9b, 0x97, 0xa3, 0x96, 0x81, 0x00, 0x00, 0x98, /* 0xf8-0xff */ +}; +static const unsigned char cp865_page03[56] = { + 0x00, 0x00, 0x00, 0xe2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0xe9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x00, 0x00, 0x00, 0xe4, 0x00, 0x00, 0xe8, 0x00, /* 0xa0-0xa7 */ + 0x00, 0xea, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0xe0, 0x00, 0x00, 0xeb, 0xee, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0xe3, 0x00, 0x00, 0xe5, 0xe7, 0x00, 0xed, 0x00, /* 0xc0-0xc7 */ +}; +static const unsigned char cp865_page22[80] = { + 0x00, 0xf9, 0xfb, 0x00, 0x00, 0x00, 0xec, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0xef, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xf7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0xf0, 0x00, 0x00, 0xf3, 0xf2, 0x00, 0x00, /* 0x60-0x67 */ +}; +static const unsigned char cp865_page23[24] = { + 0xa9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0xf4, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char cp865_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0xd5, 0xd6, 0xc9, 0xb8, 0xb7, 0xbb, /* 0x50-0x57 */ + 0xd4, 0xd3, 0xc8, 0xbe, 0xbd, 0xbc, 0xc6, 0xc7, /* 0x58-0x5f */ + 0xcc, 0xb5, 0xb6, 0xb9, 0xd1, 0xd2, 0xcb, 0xcf, /* 0x60-0x67 */ + 0xd0, 0xca, 0xd8, 0xd7, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0xdd, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xde, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp865_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = cp865_page00[wc-0x00a0]; + else if (wc == 0x0192) + c = 0x9f; + else if (wc >= 0x0390 && wc < 0x03c8) + c = cp865_page03[wc-0x0390]; + else if (wc == 0x207f) + c = 0xfc; + else if (wc == 0x20a7) + c = 0x9e; + else if (wc >= 0x2218 && wc < 0x2268) + c = cp865_page22[wc-0x2218]; + else if (wc >= 0x2310 && wc < 0x2328) + c = cp865_page23[wc-0x2310]; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp865_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp866.h b/graf2d/win32gdk/gdk/src/iconv/cp866.h new file mode 100644 index 0000000000000..0aaa2169f04c4 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp866.h @@ -0,0 +1,125 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP866 + */ + +static const unsigned short cp866_2uni[80] = { + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x2561, 0x2562, 0x2556, + 0x2555, 0x2563, 0x2551, 0x2557, 0x255d, 0x255c, 0x255b, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x255e, 0x255f, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x2567, + /* 0xd0 */ + 0x2568, 0x2564, 0x2565, 0x2559, 0x2558, 0x2552, 0x2553, 0x256b, + 0x256a, 0x2518, 0x250c, 0x2588, 0x2584, 0x258c, 0x2590, 0x2580, + /* 0xe0 */ + 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, + 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x044f, + /* 0xf0 */ + 0x0401, 0x0451, 0x0404, 0x0454, 0x0407, 0x0457, 0x040e, 0x045e, + 0x00b0, 0x2219, 0x00b7, 0x221a, 0x2116, 0x00a4, 0x25a0, 0x00a0, +}; + +static int +cp866_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else if (c < 0xb0) + *pwc = (ucs4_t) c + 0x0390; + else + *pwc = (ucs4_t) cp866_2uni[c-0xb0]; + return 1; +} + +static const unsigned char cp866_page00[24] = { + 0xff, 0x00, 0x00, 0x00, 0xfd, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfa, /* 0xb0-0xb7 */ +}; +static const unsigned char cp866_page04[96] = { + 0x00, 0xf0, 0x00, 0x00, 0xf2, 0x00, 0x00, 0xf4, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf6, 0x00, /* 0x08-0x0f */ + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, /* 0x10-0x17 */ + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, /* 0x18-0x1f */ + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, /* 0x20-0x27 */ + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, /* 0x28-0x2f */ + 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, /* 0x30-0x37 */ + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, /* 0x38-0x3f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x40-0x47 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x48-0x4f */ + 0x00, 0xf1, 0x00, 0x00, 0xf3, 0x00, 0x00, 0xf5, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf7, 0x00, /* 0x58-0x5f */ +}; +static const unsigned char cp866_page22[8] = { + 0x00, 0xf9, 0xfb, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ +}; +static const unsigned char cp866_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0xd5, 0xd6, 0xc9, 0xb8, 0xb7, 0xbb, /* 0x50-0x57 */ + 0xd4, 0xd3, 0xc8, 0xbe, 0xbd, 0xbc, 0xc6, 0xc7, /* 0x58-0x5f */ + 0xcc, 0xb5, 0xb6, 0xb9, 0xd1, 0xd2, 0xcb, 0xcf, /* 0x60-0x67 */ + 0xd0, 0xca, 0xd8, 0xd7, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0xdd, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xde, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp866_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00b8) + c = cp866_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x0460) + c = cp866_page04[wc-0x0400]; + else if (wc == 0x2116) + c = 0xfc; + else if (wc >= 0x2218 && wc < 0x2220) + c = cp866_page22[wc-0x2218]; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp866_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp869.h b/graf2d/win32gdk/gdk/src/iconv/cp869.h new file mode 100644 index 0000000000000..8e839d2cfa8d1 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp869.h @@ -0,0 +1,137 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP869 + */ + +static const unsigned short cp869_2uni[128] = { + /* 0x80 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x0386, 0xfffd, + 0x00b7, 0x00ac, 0x00a6, 0x2018, 0x2019, 0x0388, 0x2015, 0x0389, + /* 0x90 */ + 0x038a, 0x03aa, 0x038c, 0xfffd, 0xfffd, 0x038e, 0x03ab, 0x00a9, + 0x038f, 0x00b2, 0x00b3, 0x03ac, 0x00a3, 0x03ad, 0x03ae, 0x03af, + /* 0xa0 */ + 0x03ca, 0x0390, 0x03cc, 0x03cd, 0x0391, 0x0392, 0x0393, 0x0394, + 0x0395, 0x0396, 0x0397, 0x00bd, 0x0398, 0x0399, 0x00ab, 0x00bb, + /* 0xb0 */ + 0x2591, 0x2592, 0x2593, 0x2502, 0x2524, 0x039a, 0x039b, 0x039c, + 0x039d, 0x2563, 0x2551, 0x2557, 0x255d, 0x039e, 0x039f, 0x2510, + /* 0xc0 */ + 0x2514, 0x2534, 0x252c, 0x251c, 0x2500, 0x253c, 0x03a0, 0x03a1, + 0x255a, 0x2554, 0x2569, 0x2566, 0x2560, 0x2550, 0x256c, 0x03a3, + /* 0xd0 */ + 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, 0x03b1, 0x03b2, + 0x03b3, 0x2518, 0x250c, 0x2588, 0x2584, 0x03b4, 0x03b5, 0x2580, + /* 0xe0 */ + 0x03b6, 0x03b7, 0x03b8, 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, + 0x03be, 0x03bf, 0x03c0, 0x03c1, 0x03c3, 0x03c2, 0x03c4, 0x0384, + /* 0xf0 */ + 0x00ad, 0x00b1, 0x03c5, 0x03c6, 0x03c7, 0x00a7, 0x03c8, 0x0385, + 0x00b0, 0x00a8, 0x03c9, 0x03cb, 0x03b0, 0x03ce, 0x25a0, 0x00a0, +}; + +static int +cp869_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp869_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp869_page00[32] = { + 0xff, 0x00, 0x00, 0x9c, 0x00, 0x00, 0x8a, 0xf5, /* 0xa0-0xa7 */ + 0xf9, 0x97, 0x00, 0xae, 0x89, 0xf0, 0x00, 0x00, /* 0xa8-0xaf */ + 0xf8, 0xf1, 0x99, 0x9a, 0x00, 0x00, 0x00, 0x88, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xaf, 0x00, 0xab, 0x00, 0x00, /* 0xb8-0xbf */ +}; +static const unsigned char cp869_page03[80] = { + 0x00, 0x00, 0x00, 0x00, 0xef, 0xf7, 0x86, 0x00, /* 0x80-0x87 */ + 0x8d, 0x8f, 0x90, 0x00, 0x92, 0x00, 0x95, 0x98, /* 0x88-0x8f */ + 0xa1, 0xa4, 0xa5, 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, /* 0x90-0x97 */ + 0xac, 0xad, 0xb5, 0xb6, 0xb7, 0xb8, 0xbd, 0xbe, /* 0x98-0x9f */ + 0xc6, 0xc7, 0x00, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, /* 0xa0-0xa7 */ + 0xd4, 0xd5, 0x91, 0x96, 0x9b, 0x9d, 0x9e, 0x9f, /* 0xa8-0xaf */ + 0xfc, 0xd6, 0xd7, 0xd8, 0xdd, 0xde, 0xe0, 0xe1, /* 0xb0-0xb7 */ + 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, 0xe8, 0xe9, /* 0xb8-0xbf */ + 0xea, 0xeb, 0xed, 0xec, 0xee, 0xf2, 0xf3, 0xf4, /* 0xc0-0xc7 */ + 0xf6, 0xfa, 0xa0, 0xfb, 0xa2, 0xa3, 0xfd, 0x00, /* 0xc8-0xcf */ +}; +static const unsigned char cp869_page20[16] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, /* 0x10-0x17 */ + 0x8b, 0x8c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ +}; +static const unsigned char cp869_page25[168] = { + 0xc4, 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xbf, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd9, 0x00, 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0xc2, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0xc5, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xcd, 0xba, 0x00, 0x00, 0xc9, 0x00, 0x00, 0xbb, /* 0x50-0x57 */ + 0x00, 0x00, 0xc8, 0x00, 0x00, 0xbc, 0x00, 0x00, /* 0x58-0x5f */ + 0xcc, 0x00, 0x00, 0xb9, 0x00, 0x00, 0xcb, 0x00, /* 0x60-0x67 */ + 0x00, 0xca, 0x00, 0x00, 0xce, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xdf, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0xdb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +cp869_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = cp869_page00[wc-0x00a0]; + else if (wc >= 0x0380 && wc < 0x03d0) + c = cp869_page03[wc-0x0380]; + else if (wc >= 0x2010 && wc < 0x2020) + c = cp869_page20[wc-0x2010]; + else if (wc >= 0x2500 && wc < 0x25a8) + c = cp869_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp874.h b/graf2d/win32gdk/gdk/src/iconv/cp874.h new file mode 100644 index 0000000000000..6374dd7d05c6e --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp874.h @@ -0,0 +1,111 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP874 + */ + +static const unsigned short cp874_2uni[128] = { + /* 0x80 */ + 0x20ac, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x2026, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x90 */ + 0xfffd, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xa0 */ + 0x00a0, 0x0e01, 0x0e02, 0x0e03, 0x0e04, 0x0e05, 0x0e06, 0x0e07, + 0x0e08, 0x0e09, 0x0e0a, 0x0e0b, 0x0e0c, 0x0e0d, 0x0e0e, 0x0e0f, + /* 0xb0 */ + 0x0e10, 0x0e11, 0x0e12, 0x0e13, 0x0e14, 0x0e15, 0x0e16, 0x0e17, + 0x0e18, 0x0e19, 0x0e1a, 0x0e1b, 0x0e1c, 0x0e1d, 0x0e1e, 0x0e1f, + /* 0xc0 */ + 0x0e20, 0x0e21, 0x0e22, 0x0e23, 0x0e24, 0x0e25, 0x0e26, 0x0e27, + 0x0e28, 0x0e29, 0x0e2a, 0x0e2b, 0x0e2c, 0x0e2d, 0x0e2e, 0x0e2f, + /* 0xd0 */ + 0x0e30, 0x0e31, 0x0e32, 0x0e33, 0x0e34, 0x0e35, 0x0e36, 0x0e37, + 0x0e38, 0x0e39, 0x0e3a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x0e3f, + /* 0xe0 */ + 0x0e40, 0x0e41, 0x0e42, 0x0e43, 0x0e44, 0x0e45, 0x0e46, 0x0e47, + 0x0e48, 0x0e49, 0x0e4a, 0x0e4b, 0x0e4c, 0x0e4d, 0x0e4e, 0x0e4f, + /* 0xf0 */ + 0x0e50, 0x0e51, 0x0e52, 0x0e53, 0x0e54, 0x0e55, 0x0e56, 0x0e57, + 0x0e58, 0x0e59, 0x0e5a, 0x0e5b, 0xfffd, 0xfffd, 0xfffd, 0xfffd, +}; + +static int +cp874_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = cp874_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char cp874_page0e[96] = { + 0x00, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, /* 0x00-0x07 */ + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, /* 0x08-0x0f */ + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, /* 0x10-0x17 */ + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, /* 0x18-0x1f */ + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x20-0x27 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x28-0x2f */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0x30-0x37 */ + 0xd8, 0xd9, 0xda, 0x00, 0x00, 0x00, 0x00, 0xdf, /* 0x38-0x3f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x40-0x47 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x48-0x4f */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0x50-0x57 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ +}; +static const unsigned char cp874_page20[24] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x00, 0x00, 0x93, 0x94, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ +}; + +static int +cp874_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc == 0x00a0) + c = 0xa0; + else if (wc >= 0x0e00 && wc < 0x0e60) + c = cp874_page0e[wc-0x0e00]; + else if (wc >= 0x2010 && wc < 0x2028) + c = cp874_page20[wc-0x2010]; + else if (wc == 0x20ac) + c = 0x80; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp922.h b/graf2d/win32gdk/gdk/src/iconv/cp922.h new file mode 100644 index 0000000000000..ca661b3862fac --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp922.h @@ -0,0 +1,99 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP922 + */ + +static const unsigned short cp922_2uni_1[16] = { + /* 0xa0 */ + 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, + 0x00a8, 0x00a9, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x203e, +}; +static const unsigned short cp922_2uni_2[16] = { + /* 0xd0 */ + 0x0160, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x00d7, + 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x00dd, 0x017d, 0x00df, +}; +static const unsigned short cp922_2uni_3[16] = { + /* 0xf0 */ + 0x0161, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x00f7, + 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x00fd, 0x017e, 0x00ff, +}; + +static int +cp922_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) + *pwc = (ucs4_t) c; + else if (c < 0xb0) + *pwc = (ucs4_t) cp922_2uni_1[c-0xa0]; + else if (c < 0xd0) + *pwc = (ucs4_t) c; + else if (c < 0xe0) + *pwc = (ucs4_t) cp922_2uni_2[c-0xd0]; + else if (c < 0xf0) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) cp922_2uni_3[c-0xf0]; + return 1; +} + +static const unsigned char cp922_page00[88] = { + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0x00, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, /* 0xb8-0xbf */ + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0xc0-0xc7 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0xc8-0xcf */ + 0x00, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0xd0-0xd7 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0x00, 0xdf, /* 0xd8-0xdf */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0xe0-0xe7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0xe8-0xef */ + 0x00, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0xf0-0xf7 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0x00, 0xff, /* 0xf8-0xff */ +}; +static const unsigned char cp922_page01[32] = { + 0xd0, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xde, 0xfe, 0x00, /* 0x78-0x7f */ +}; + +static int +cp922_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a8) { + *r = wc; + return 1; + } + else if (wc >= 0x00a8 && wc < 0x0100) + c = cp922_page00[wc-0x00a8]; + else if (wc >= 0x0160 && wc < 0x0180) + c = cp922_page01[wc-0x0160]; + else if (wc == 0x203e) + c = 0xaf; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp932.h b/graf2d/win32gdk/gdk/src/iconv/cp932.h new file mode 100644 index 0000000000000..6534cd0297d23 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp932.h @@ -0,0 +1,240 @@ +/* + * Copyright (C) 1999-2002, 2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP932 + */ + +/* + * Microsoft CP932 is a slightly extended version of SHIFT_JIS. + * The differences between the EASTASIA/JIS/SHIFTJIS.TXT and the + * VENDORS/MICSFT/WINDOWS/CP932.TXT tables found on ftp.unicode.org are + * as follows: + * + * 1. CP932 uses ASCII, not JISX0201 Roman. + * + * 2. Some characters in the JISX0208 range are defined differently: + * + * code SHIFTJIS.TXT CP932.TXT + * 0x815F 0x005C # REVERSE SOLIDUS 0xFF3C # FULLWIDTH REVERSE SOLIDUS + * 0x8160 0x301C # WAVE DASH 0xFF5E # FULLWIDTH TILDE + * 0x8161 0x2016 # DOUBLE VERTICAL LINE 0x2225 # PARALLEL TO + * 0x817C 0x2212 # MINUS SIGN 0xFF0D # FULLWIDTH HYPHEN-MINUS + * 0x8191 0x00A2 # CENT SIGN 0xFFE0 # FULLWIDTH CENT SIGN + * 0x8192 0x00A3 # POUND SIGN 0xFFE1 # FULLWIDTH POUND SIGN + * 0x81CA 0x00AC # NOT SIGN 0xFFE2 # FULLWIDTH NOT SIGN + * + * We don't implement the latter 6 of these changes, only the first one. + * SHIFTJIS.TXT makes more sense. However, as a compromise with user + * expectation, we implement the middle 5 of these changes in the + * Unicode to CP932 direction. We don't implement the last one at all, + * because it would collide with the mapping of 0xFA54. + * + * 3. A few new rows. See cp932ext.h. + * + * Many variants of CP932 (in GNU libc, JDK, OSF/1, Windows-2000, ICU) also + * add: + * + * 4. Private area mappings: + * + * code Unicode + * 0x{F0..F9}{40..7E,80..FC} U+E000..U+E757 + * + * We add them too because, although there are backward compatibility problems + * when a character from a private area is moved to an official Unicode code + * point, they are useful for some people in practice. + */ + +#include "cp932ext.h" + +/* + Conversion between SJIS codes (s1,s2) and JISX0208 codes (c1,c2): + Example. (s1,s2) = 0x8140, (c1,c2) = 0x2121. + 0x81 <= s1 <= 0x9F || 0xE0 <= s1 <= 0xEA, + 0x40 <= s2 <= 0x7E || 0x80 <= s2 <= 0xFC, + 0x21 <= c1 <= 0x74, 0x21 <= c2 <= 0x7E. + Invariant: + 94*2*(s1 < 0xE0 ? s1-0x81 : s1-0xC1) + (s2 < 0x80 ? s2-0x40 : s2-0x41) + = 94*(c1-0x21)+(c2-0x21) + Conversion (s1,s2) -> (c1,c2): + t1 := (s1 < 0xE0 ? s1-0x81 : s1-0xC1) + t2 := (s2 < 0x80 ? s2-0x40 : s2-0x41) + c1 := 2*t1 + (t2 < 0x5E ? 0 : 1) + 0x21 + c2 := (t2 < 0x5E ? t2 : t2-0x5E) + 0x21 + Conversion (c1,c2) -> (s1,s2): + t1 := (c1 - 0x21) >> 1 + t2 := ((c1 - 0x21) & 1) * 0x5E + (c2 - 0x21) + s1 := (t1 < 0x1F ? t1+0x81 : t1+0xC1) + s2 := (t2 < 0x3F ? t2+0x40 : t2+0x41) + */ + +static int +cp932_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + else if (c >= 0xa1 && c <= 0xdf) + return jisx0201_mbtowc(conv,pwc,s,n); + else { + unsigned char s1, s2; + s1 = c; + if ((s1 >= 0x81 && s1 <= 0x9f && s1 != 0x87) || (s1 >= 0xe0 && s1 <= 0xea)) { + if (n < 2) + return RET_TOOFEW(0); + s2 = s[1]; + if ((s2 >= 0x40 && s2 <= 0x7e) || (s2 >= 0x80 && s2 <= 0xfc)) { + unsigned char t1 = (s1 < 0xe0 ? s1-0x81 : s1-0xc1); + unsigned char t2 = (s2 < 0x80 ? s2-0x40 : s2-0x41); + unsigned char buf[2]; + buf[0] = 2*t1 + (t2 < 0x5e ? 0 : 1) + 0x21; + buf[1] = (t2 < 0x5e ? t2 : t2-0x5e) + 0x21; + return jisx0208_mbtowc(conv,pwc,buf,2); + } + } else if ((s1 == 0x87) || (s1 >= 0xed && s1 <= 0xee) || (s1 >= 0xfa)) { + if (n < 2) + return RET_TOOFEW(0); + return cp932ext_mbtowc(conv,pwc,s,2); + } else if (s1 >= 0xf0 && s1 <= 0xf9) { + /* User-defined range. See + * Ken Lunde's "CJKV Information Processing", table 4-66, p. 206. */ + if (n < 2) + return RET_TOOFEW(0); + s2 = s[1]; + if ((s2 >= 0x40 && s2 <= 0x7e) || (s2 >= 0x80 && s2 <= 0xfc)) { + *pwc = 0xe000 + 188*(s1 - 0xf0) + (s2 < 0x80 ? s2-0x40 : s2-0x41); + return 2; + } + } + return RET_ILSEQ; + } +} + +static int +cp932_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Try ASCII. */ + ret = ascii_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + unsigned char c; + if (ret != 1) abort(); + c = buf[0]; + if (c < 0x80) { + r[0] = c; + return 1; + } + } + + /* Try JIS X 0201-1976 Katakana. */ + ret = jisx0201_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + unsigned char c; + if (ret != 1) abort(); + c = buf[0]; + if (c >= 0xa1 && c <= 0xdf) { + r[0] = c; + return 1; + } + } + + /* Try JIS X 0208-1990. */ + ret = jisx0208_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + unsigned char c1, c2; + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + c1 = buf[0]; + c2 = buf[1]; + if ((c1 >= 0x21 && c1 <= 0x74) && (c2 >= 0x21 && c2 <= 0x7e)) { + unsigned char t1 = (c1 - 0x21) >> 1; + unsigned char t2 = (((c1 - 0x21) & 1) ? 0x5e : 0) + (c2 - 0x21); + r[0] = (t1 < 0x1f ? t1+0x81 : t1+0xc1); + r[1] = (t2 < 0x3f ? t2+0x40 : t2+0x41); + return 2; + } + } + + /* Try CP932 extensions. */ + ret = cp932ext_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]; + r[1] = buf[1]; + return 2; + } + + /* User-defined range. See + * Ken Lunde's "CJKV Information Processing", table 4-66, p. 206. */ + if (wc >= 0xe000 && wc < 0xe758) { + unsigned char c1, c2; + if (n < 2) + return RET_TOOSMALL; + c1 = (unsigned int) (wc - 0xe000) / 188; + c2 = (unsigned int) (wc - 0xe000) % 188; + r[0] = c1+0xf0; + r[1] = (c2 < 0x3f ? c2+0x40 : c2+0x41); + return 2; + } + + /* Irreversible mappings. */ + if (wc == 0xff5e) { + if (n < 2) + return RET_TOOSMALL; + r[0] = 0x81; + r[1] = 0x60; + return 2; + } + if (wc == 0x2225) { + if (n < 2) + return RET_TOOSMALL; + r[0] = 0x81; + r[1] = 0x61; + return 2; + } + if (wc == 0xff0d) { + if (n < 2) + return RET_TOOSMALL; + r[0] = 0x81; + r[1] = 0x7c; + return 2; + } + if (wc == 0xffe0) { + if (n < 2) + return RET_TOOSMALL; + r[0] = 0x81; + r[1] = 0x91; + return 2; + } + if (wc == 0xffe1) { + if (n < 2) + return RET_TOOSMALL; + r[0] = 0x81; + r[1] = 0x92; + return 2; + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp932ext.h b/graf2d/win32gdk/gdk/src/iconv/cp932ext.h new file mode 100644 index 0000000000000..6f94c9a5cfb2e --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp932ext.h @@ -0,0 +1,709 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP932 extensions + */ + +static const unsigned short cp932ext_2uni_page87[92] = { + /* 0x87 */ + 0x2460, 0x2461, 0x2462, 0x2463, 0x2464, 0x2465, 0x2466, 0x2467, + 0x2468, 0x2469, 0x246a, 0x246b, 0x246c, 0x246d, 0x246e, 0x246f, + 0x2470, 0x2471, 0x2472, 0x2473, 0x2160, 0x2161, 0x2162, 0x2163, + 0x2164, 0x2165, 0x2166, 0x2167, 0x2168, 0x2169, 0xfffd, 0x3349, + 0x3314, 0x3322, 0x334d, 0x3318, 0x3327, 0x3303, 0x3336, 0x3351, + 0x3357, 0x330d, 0x3326, 0x3323, 0x332b, 0x334a, 0x333b, 0x339c, + 0x339d, 0x339e, 0x338e, 0x338f, 0x33c4, 0x33a1, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x337b, 0x301d, + 0x301f, 0x2116, 0x33cd, 0x2121, 0x32a4, 0x32a5, 0x32a6, 0x32a7, + 0x32a8, 0x3231, 0x3232, 0x3239, 0x337e, 0x337d, 0x337c, 0x2252, + 0x2261, 0x222b, 0x222e, 0x2211, 0x221a, 0x22a5, 0x2220, 0x221f, + 0x22bf, 0x2235, 0x2229, 0x222a, +}; +static const unsigned short cp932ext_2uni_pageed[376] = { + /* 0xed */ + 0x7e8a, 0x891c, 0x9348, 0x9288, 0x84dc, 0x4fc9, 0x70bb, 0x6631, + 0x68c8, 0x92f9, 0x66fb, 0x5f45, 0x4e28, 0x4ee1, 0x4efc, 0x4f00, + 0x4f03, 0x4f39, 0x4f56, 0x4f92, 0x4f8a, 0x4f9a, 0x4f94, 0x4fcd, + 0x5040, 0x5022, 0x4fff, 0x501e, 0x5046, 0x5070, 0x5042, 0x5094, + 0x50f4, 0x50d8, 0x514a, 0x5164, 0x519d, 0x51be, 0x51ec, 0x5215, + 0x529c, 0x52a6, 0x52c0, 0x52db, 0x5300, 0x5307, 0x5324, 0x5372, + 0x5393, 0x53b2, 0x53dd, 0xfa0e, 0x549c, 0x548a, 0x54a9, 0x54ff, + 0x5586, 0x5759, 0x5765, 0x57ac, 0x57c8, 0x57c7, 0xfa0f, 0xfa10, + 0x589e, 0x58b2, 0x590b, 0x5953, 0x595b, 0x595d, 0x5963, 0x59a4, + 0x59ba, 0x5b56, 0x5bc0, 0x752f, 0x5bd8, 0x5bec, 0x5c1e, 0x5ca6, + 0x5cba, 0x5cf5, 0x5d27, 0x5d53, 0xfa11, 0x5d42, 0x5d6d, 0x5db8, + 0x5db9, 0x5dd0, 0x5f21, 0x5f34, 0x5f67, 0x5fb7, 0x5fde, 0x605d, + 0x6085, 0x608a, 0x60de, 0x60d5, 0x6120, 0x60f2, 0x6111, 0x6137, + 0x6130, 0x6198, 0x6213, 0x62a6, 0x63f5, 0x6460, 0x649d, 0x64ce, + 0x654e, 0x6600, 0x6615, 0x663b, 0x6609, 0x662e, 0x661e, 0x6624, + 0x6665, 0x6657, 0x6659, 0xfa12, 0x6673, 0x6699, 0x66a0, 0x66b2, + 0x66bf, 0x66fa, 0x670e, 0xf929, 0x6766, 0x67bb, 0x6852, 0x67c0, + 0x6801, 0x6844, 0x68cf, 0xfa13, 0x6968, 0xfa14, 0x6998, 0x69e2, + 0x6a30, 0x6a6b, 0x6a46, 0x6a73, 0x6a7e, 0x6ae2, 0x6ae4, 0x6bd6, + 0x6c3f, 0x6c5c, 0x6c86, 0x6c6f, 0x6cda, 0x6d04, 0x6d87, 0x6d6f, + 0x6d96, 0x6dac, 0x6dcf, 0x6df8, 0x6df2, 0x6dfc, 0x6e39, 0x6e5c, + 0x6e27, 0x6e3c, 0x6ebf, 0x6f88, 0x6fb5, 0x6ff5, 0x7005, 0x7007, + 0x7028, 0x7085, 0x70ab, 0x710f, 0x7104, 0x715c, 0x7146, 0x7147, + 0xfa15, 0x71c1, 0x71fe, 0x72b1, + /* 0xee */ + 0x72be, 0x7324, 0xfa16, 0x7377, 0x73bd, 0x73c9, 0x73d6, 0x73e3, + 0x73d2, 0x7407, 0x73f5, 0x7426, 0x742a, 0x7429, 0x742e, 0x7462, + 0x7489, 0x749f, 0x7501, 0x756f, 0x7682, 0x769c, 0x769e, 0x769b, + 0x76a6, 0xfa17, 0x7746, 0x52af, 0x7821, 0x784e, 0x7864, 0x787a, + 0x7930, 0xfa18, 0xfa19, 0xfa1a, 0x7994, 0xfa1b, 0x799b, 0x7ad1, + 0x7ae7, 0xfa1c, 0x7aeb, 0x7b9e, 0xfa1d, 0x7d48, 0x7d5c, 0x7db7, + 0x7da0, 0x7dd6, 0x7e52, 0x7f47, 0x7fa1, 0xfa1e, 0x8301, 0x8362, + 0x837f, 0x83c7, 0x83f6, 0x8448, 0x84b4, 0x8553, 0x8559, 0x856b, + 0xfa1f, 0x85b0, 0xfa20, 0xfa21, 0x8807, 0x88f5, 0x8a12, 0x8a37, + 0x8a79, 0x8aa7, 0x8abe, 0x8adf, 0xfa22, 0x8af6, 0x8b53, 0x8b7f, + 0x8cf0, 0x8cf4, 0x8d12, 0x8d76, 0xfa23, 0x8ecf, 0xfa24, 0xfa25, + 0x9067, 0x90de, 0xfa26, 0x9115, 0x9127, 0x91da, 0x91d7, 0x91de, + 0x91ed, 0x91ee, 0x91e4, 0x91e5, 0x9206, 0x9210, 0x920a, 0x923a, + 0x9240, 0x923c, 0x924e, 0x9259, 0x9251, 0x9239, 0x9267, 0x92a7, + 0x9277, 0x9278, 0x92e7, 0x92d7, 0x92d9, 0x92d0, 0xfa27, 0x92d5, + 0x92e0, 0x92d3, 0x9325, 0x9321, 0x92fb, 0xfa28, 0x931e, 0x92ff, + 0x931d, 0x9302, 0x9370, 0x9357, 0x93a4, 0x93c6, 0x93de, 0x93f8, + 0x9431, 0x9445, 0x9448, 0x9592, 0xf9dc, 0xfa29, 0x969d, 0x96af, + 0x9733, 0x973b, 0x9743, 0x974d, 0x974f, 0x9751, 0x9755, 0x9857, + 0x9865, 0xfa2a, 0xfa2b, 0x9927, 0xfa2c, 0x999e, 0x9a4e, 0x9ad9, + 0x9adc, 0x9b75, 0x9b72, 0x9b8f, 0x9bb1, 0x9bbb, 0x9c00, 0x9d70, + 0x9d6b, 0xfa2d, 0x9e19, 0x9ed1, 0xfffd, 0xfffd, 0x2170, 0x2171, + 0x2172, 0x2173, 0x2174, 0x2175, 0x2176, 0x2177, 0x2178, 0x2179, + 0xffe2, 0xffe4, 0xff07, 0xff02, +}; +static const unsigned short cp932ext_2uni_pagefa[388] = { + /* 0xfa */ + 0x2170, 0x2171, 0x2172, 0x2173, 0x2174, 0x2175, 0x2176, 0x2177, + 0x2178, 0x2179, 0x2160, 0x2161, 0x2162, 0x2163, 0x2164, 0x2165, + 0x2166, 0x2167, 0x2168, 0x2169, 0xffe2, 0xffe4, 0xff07, 0xff02, + 0x3231, 0x2116, 0x2121, 0x2235, 0x7e8a, 0x891c, 0x9348, 0x9288, + 0x84dc, 0x4fc9, 0x70bb, 0x6631, 0x68c8, 0x92f9, 0x66fb, 0x5f45, + 0x4e28, 0x4ee1, 0x4efc, 0x4f00, 0x4f03, 0x4f39, 0x4f56, 0x4f92, + 0x4f8a, 0x4f9a, 0x4f94, 0x4fcd, 0x5040, 0x5022, 0x4fff, 0x501e, + 0x5046, 0x5070, 0x5042, 0x5094, 0x50f4, 0x50d8, 0x514a, 0x5164, + 0x519d, 0x51be, 0x51ec, 0x5215, 0x529c, 0x52a6, 0x52c0, 0x52db, + 0x5300, 0x5307, 0x5324, 0x5372, 0x5393, 0x53b2, 0x53dd, 0xfa0e, + 0x549c, 0x548a, 0x54a9, 0x54ff, 0x5586, 0x5759, 0x5765, 0x57ac, + 0x57c8, 0x57c7, 0xfa0f, 0xfa10, 0x589e, 0x58b2, 0x590b, 0x5953, + 0x595b, 0x595d, 0x5963, 0x59a4, 0x59ba, 0x5b56, 0x5bc0, 0x752f, + 0x5bd8, 0x5bec, 0x5c1e, 0x5ca6, 0x5cba, 0x5cf5, 0x5d27, 0x5d53, + 0xfa11, 0x5d42, 0x5d6d, 0x5db8, 0x5db9, 0x5dd0, 0x5f21, 0x5f34, + 0x5f67, 0x5fb7, 0x5fde, 0x605d, 0x6085, 0x608a, 0x60de, 0x60d5, + 0x6120, 0x60f2, 0x6111, 0x6137, 0x6130, 0x6198, 0x6213, 0x62a6, + 0x63f5, 0x6460, 0x649d, 0x64ce, 0x654e, 0x6600, 0x6615, 0x663b, + 0x6609, 0x662e, 0x661e, 0x6624, 0x6665, 0x6657, 0x6659, 0xfa12, + 0x6673, 0x6699, 0x66a0, 0x66b2, 0x66bf, 0x66fa, 0x670e, 0xf929, + 0x6766, 0x67bb, 0x6852, 0x67c0, 0x6801, 0x6844, 0x68cf, 0xfa13, + 0x6968, 0xfa14, 0x6998, 0x69e2, 0x6a30, 0x6a6b, 0x6a46, 0x6a73, + 0x6a7e, 0x6ae2, 0x6ae4, 0x6bd6, 0x6c3f, 0x6c5c, 0x6c86, 0x6c6f, + 0x6cda, 0x6d04, 0x6d87, 0x6d6f, + /* 0xfb */ + 0x6d96, 0x6dac, 0x6dcf, 0x6df8, 0x6df2, 0x6dfc, 0x6e39, 0x6e5c, + 0x6e27, 0x6e3c, 0x6ebf, 0x6f88, 0x6fb5, 0x6ff5, 0x7005, 0x7007, + 0x7028, 0x7085, 0x70ab, 0x710f, 0x7104, 0x715c, 0x7146, 0x7147, + 0xfa15, 0x71c1, 0x71fe, 0x72b1, 0x72be, 0x7324, 0xfa16, 0x7377, + 0x73bd, 0x73c9, 0x73d6, 0x73e3, 0x73d2, 0x7407, 0x73f5, 0x7426, + 0x742a, 0x7429, 0x742e, 0x7462, 0x7489, 0x749f, 0x7501, 0x756f, + 0x7682, 0x769c, 0x769e, 0x769b, 0x76a6, 0xfa17, 0x7746, 0x52af, + 0x7821, 0x784e, 0x7864, 0x787a, 0x7930, 0xfa18, 0xfa19, 0xfa1a, + 0x7994, 0xfa1b, 0x799b, 0x7ad1, 0x7ae7, 0xfa1c, 0x7aeb, 0x7b9e, + 0xfa1d, 0x7d48, 0x7d5c, 0x7db7, 0x7da0, 0x7dd6, 0x7e52, 0x7f47, + 0x7fa1, 0xfa1e, 0x8301, 0x8362, 0x837f, 0x83c7, 0x83f6, 0x8448, + 0x84b4, 0x8553, 0x8559, 0x856b, 0xfa1f, 0x85b0, 0xfa20, 0xfa21, + 0x8807, 0x88f5, 0x8a12, 0x8a37, 0x8a79, 0x8aa7, 0x8abe, 0x8adf, + 0xfa22, 0x8af6, 0x8b53, 0x8b7f, 0x8cf0, 0x8cf4, 0x8d12, 0x8d76, + 0xfa23, 0x8ecf, 0xfa24, 0xfa25, 0x9067, 0x90de, 0xfa26, 0x9115, + 0x9127, 0x91da, 0x91d7, 0x91de, 0x91ed, 0x91ee, 0x91e4, 0x91e5, + 0x9206, 0x9210, 0x920a, 0x923a, 0x9240, 0x923c, 0x924e, 0x9259, + 0x9251, 0x9239, 0x9267, 0x92a7, 0x9277, 0x9278, 0x92e7, 0x92d7, + 0x92d9, 0x92d0, 0xfa27, 0x92d5, 0x92e0, 0x92d3, 0x9325, 0x9321, + 0x92fb, 0xfa28, 0x931e, 0x92ff, 0x931d, 0x9302, 0x9370, 0x9357, + 0x93a4, 0x93c6, 0x93de, 0x93f8, 0x9431, 0x9445, 0x9448, 0x9592, + 0xf9dc, 0xfa29, 0x969d, 0x96af, 0x9733, 0x973b, 0x9743, 0x974d, + 0x974f, 0x9751, 0x9755, 0x9857, 0x9865, 0xfa2a, 0xfa2b, 0x9927, + 0xfa2c, 0x999e, 0x9a4e, 0x9ad9, + /* 0xfc */ + 0x9adc, 0x9b75, 0x9b72, 0x9b8f, 0x9bb1, 0x9bbb, 0x9c00, 0x9d70, + 0x9d6b, 0xfa2d, 0x9e19, 0x9ed1, +}; + +static int +cp932ext_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 == 0x87) || (c1 >= 0xed && c1 <= 0xee) || (c1 >= 0xfa && c1 <= 0xfc)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0x80 && c2 < 0xfd)) { + unsigned int i = 188 * (c1 - (c1 >= 0xe0 ? 0xc1 : 0x81)) + (c2 - (c2 >= 0x80 ? 0x41 : 0x40)); + unsigned short wc = 0xfffd; + if (i < 8272) { + if (i < 1220) + wc = cp932ext_2uni_page87[i-1128]; + } else if (i < 10716) { + if (i < 8648) + wc = cp932ext_2uni_pageed[i-8272]; + } else { + if (i < 11104) + wc = cp932ext_2uni_pagefa[i-10716]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short cp932ext_2charset[457] = { + 0xfa59, 0xfa5a, 0xfa4a, 0xfa4b, 0xfa4c, 0xfa4d, 0xfa4e, 0xfa4f, + 0xfa50, 0xfa51, 0xfa52, 0xfa53, 0xfa40, 0xfa41, 0xfa42, 0xfa43, + 0xfa44, 0xfa45, 0xfa46, 0xfa47, 0xfa48, 0xfa49, 0x8794, 0x8795, + 0x8798, 0x8797, 0x879b, 0x879c, 0x8792, 0x8793, 0xfa5b, 0x8790, + 0x8791, 0x8796, 0x8799, 0x8740, 0x8741, 0x8742, 0x8743, 0x8744, + 0x8745, 0x8746, 0x8747, 0x8748, 0x8749, 0x874a, 0x874b, 0x874c, + 0x874d, 0x874e, 0x874f, 0x8750, 0x8751, 0x8752, 0x8753, 0x8780, + 0x8781, 0xfa58, 0x878b, 0x878c, 0x8785, 0x8786, 0x8787, 0x8788, + 0x8789, 0x8765, 0x8769, 0x8760, 0x8763, 0x8761, 0x876b, 0x876a, + 0x8764, 0x876c, 0x8766, 0x876e, 0x875f, 0x876d, 0x8762, 0x8767, + 0x8768, 0x877e, 0x878f, 0x878e, 0x878d, 0x8772, 0x8773, 0x876f, + 0x8770, 0x8771, 0x8775, 0x8774, 0x8783, 0xfa68, 0xfa69, 0xfa6a, + 0xfa6b, 0xfa6c, 0xfa6d, 0xfa6e, 0xfa70, 0xfa6f, 0xfa72, 0xfa71, + 0xfa61, 0xfa73, 0xfa76, 0xfa77, 0xfa75, 0xfa74, 0xfa7a, 0xfa78, + 0xfa79, 0xfa7b, 0xfa7d, 0xfa7c, 0xfa7e, 0xfa80, 0xfa81, 0xfa82, + 0xfa83, 0xfa84, 0xfa85, 0xfa86, 0xfb77, 0xfa87, 0xfa88, 0xfa89, + 0xfa8a, 0xfa8b, 0xfa8c, 0xfa8d, 0xfa8e, 0xfa8f, 0xfa92, 0xfa91, + 0xfa93, 0xfa94, 0xfa95, 0xfa96, 0xfa97, 0xfa98, 0xfa9a, 0xfa99, + 0xfa9d, 0xfa9e, 0xfa9f, 0xfaa0, 0xfaa1, 0xfaa2, 0xfaa3, 0xfaa4, + 0xfaa5, 0xfaa6, 0xfaa7, 0xfaa9, 0xfaaa, 0xfaab, 0xfaac, 0xfaad, + 0xfaae, 0xfaaf, 0xfab2, 0xfab0, 0xfab3, 0xfab4, 0xfab5, 0xfab6, + 0xfab7, 0xfab8, 0xfa67, 0xfab9, 0xfaba, 0xfabb, 0xfabc, 0xfabd, + 0xfabe, 0xfac0, 0xfabf, 0xfac2, 0xfac3, 0xfac1, 0xfac5, 0xfac4, + 0xfac6, 0xfac7, 0xfac8, 0xfac9, 0xfaca, 0xfacb, 0xfacc, 0xfacd, + 0xface, 0xfad1, 0xfacf, 0xfad3, 0xfad4, 0xfad2, 0xfa63, 0xfad0, + 0xfad6, 0xfad7, 0xfad5, 0xfad9, 0xfada, 0xfadb, 0xfadc, 0xfadd, + 0xfade, 0xfa66, 0xfadf, 0xfae1, 0xfae2, 0xfae4, 0xfae5, 0xfae6, + 0xfae3, 0xfa64, 0xfae7, 0xfae9, 0xfaeb, 0xfaec, 0xfaed, 0xfaef, + 0xfaee, 0xfaf0, 0xfaf1, 0xfaf2, 0xfaf3, 0xfaf4, 0xfaf5, 0xfaf6, + 0xfaf8, 0xfaf7, 0xfaf9, 0xfafa, 0xfafc, 0xfafb, 0xfb40, 0xfb41, + 0xfb42, 0xfb44, 0xfb43, 0xfb45, 0xfb48, 0xfb46, 0xfb49, 0xfb47, + 0xfb4a, 0xfb4b, 0xfb4c, 0xfb4d, 0xfb4e, 0xfb4f, 0xfb50, 0xfb51, + 0xfb52, 0xfa62, 0xfb54, 0xfb53, 0xfb56, 0xfb57, 0xfb55, 0xfb59, + 0xfb5a, 0xfb5b, 0xfb5c, 0xfb5d, 0xfb5f, 0xfb60, 0xfb61, 0xfb64, + 0xfb62, 0xfb63, 0xfb66, 0xfb65, 0xfb67, 0xfb69, 0xfb68, 0xfb6a, + 0xfb6b, 0xfb6c, 0xfb6d, 0xfb6e, 0xfaa8, 0xfb6f, 0xfb70, 0xfb73, + 0xfb71, 0xfb72, 0xfb74, 0xfb76, 0xfb78, 0xfb79, 0xfb7a, 0xfb7b, + 0xfb7c, 0xfb81, 0xfb83, 0xfb84, 0xfb85, 0xfb87, 0xfb88, 0xfb8a, + 0xfb8b, 0xfb8d, 0xfb8c, 0xfb8e, 0xfb8f, 0xfa5c, 0xfb90, 0xfb91, + 0xfb93, 0xfb94, 0xfb95, 0xfb96, 0xfb97, 0xfb98, 0xfb99, 0xfa60, + 0xfb9a, 0xfb9b, 0xfb9c, 0xfb9e, 0xfba1, 0xfba2, 0xfa5d, 0xfba3, + 0xfba4, 0xfba5, 0xfba6, 0xfba7, 0xfba8, 0xfbaa, 0xfbab, 0xfbac, + 0xfbad, 0xfbae, 0xfbaf, 0xfbb0, 0xfbb2, 0xfbb5, 0xfbb6, 0xfbb8, + 0xfbb9, 0xfbbb, 0xfbba, 0xfbbc, 0xfbbf, 0xfbc0, 0xfbbd, 0xfbbe, + 0xfbc1, 0xfbc3, 0xfbc2, 0xfbca, 0xfbc4, 0xfbc6, 0xfbc5, 0xfbc7, + 0xfbc9, 0xfbc8, 0xfbcb, 0xfbcd, 0xfbce, 0xfa5f, 0xfbcc, 0xfbd2, + 0xfbd6, 0xfbd4, 0xfbd0, 0xfbd1, 0xfbd5, 0xfbcf, 0xfa65, 0xfbd9, + 0xfbdc, 0xfbde, 0xfbdd, 0xfbdb, 0xfbd8, 0xfbd7, 0xfa5e, 0xfbe0, + 0xfbdf, 0xfbe1, 0xfbe2, 0xfbe3, 0xfbe4, 0xfbe5, 0xfbe6, 0xfbe7, + 0xfbe8, 0xfbeb, 0xfbec, 0xfbed, 0xfbee, 0xfbef, 0xfbf0, 0xfbf1, + 0xfbf2, 0xfbf3, 0xfbf4, 0xfbf5, 0xfbf8, 0xfbfa, 0xfbfb, 0xfbfc, + 0xfc40, 0xfc42, 0xfc41, 0xfc43, 0xfc44, 0xfc45, 0xfc46, 0xfc48, + 0xfc47, 0xfc4a, 0xfc4b, 0xfae0, 0xfbe9, 0xfa90, 0xfa9b, 0xfa9c, + 0xfab1, 0xfad8, 0xfae8, 0xfaea, 0xfb58, 0xfb5e, 0xfb75, 0xfb7d, + 0xfb7e, 0xfb80, 0xfb82, 0xfb86, 0xfb89, 0xfb92, 0xfb9d, 0xfb9f, + 0xfba0, 0xfba9, 0xfbb1, 0xfbb3, 0xfbb4, 0xfbb7, 0xfbd3, 0xfbda, + 0xfbea, 0xfbf6, 0xfbf7, 0xfbf9, 0xfc49, 0xfa57, 0xfa56, 0xfa54, + 0xfa55, +}; + +static const Summary16 cp932ext_uni2indx_page21[28] = { + /* 0x2100 */ + { 0, 0x0000 }, { 0, 0x0040 }, { 1, 0x0002 }, { 2, 0x0000 }, + { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x03ff }, { 12, 0x03ff }, + { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, + { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, + /* 0x2200 */ + { 22, 0x0000 }, { 22, 0x8402 }, { 25, 0x4e01 }, { 30, 0x0020 }, + { 31, 0x0000 }, { 31, 0x0004 }, { 32, 0x0002 }, { 33, 0x0000 }, + { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0020 }, { 34, 0x8000 }, +}; +static const Summary16 cp932ext_uni2indx_page24[8] = { + /* 0x2400 */ + { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, + { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0xffff }, { 51, 0x000f }, +}; +static const Summary16 cp932ext_uni2indx_page30[2] = { + /* 0x3000 */ + { 55, 0x0000 }, { 55, 0xa000 }, +}; +static const Summary16 cp932ext_uni2indx_page32[29] = { + /* 0x3200 */ + { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0206 }, + { 60, 0x0000 }, { 60, 0x0000 }, { 60, 0x0000 }, { 60, 0x0000 }, + { 60, 0x0000 }, { 60, 0x0000 }, { 60, 0x01f0 }, { 65, 0x0000 }, + { 65, 0x0000 }, { 65, 0x0000 }, { 65, 0x0000 }, { 65, 0x0000 }, + /* 0x3300 */ + { 65, 0x2008 }, { 67, 0x0110 }, { 69, 0x08cc }, { 74, 0x0840 }, + { 76, 0x2600 }, { 79, 0x0082 }, { 81, 0x0000 }, { 81, 0x7800 }, + { 85, 0xc000 }, { 87, 0x7000 }, { 90, 0x0002 }, { 91, 0x0000 }, + { 91, 0x2010 }, +}; +static const Summary16 cp932ext_uni2indx_page4e[121] = { + /* 0x4e00 */ + { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0100 }, { 94, 0x0000 }, + { 94, 0x0000 }, { 94, 0x0000 }, { 94, 0x0000 }, { 94, 0x0000 }, + { 94, 0x0000 }, { 94, 0x0000 }, { 94, 0x0000 }, { 94, 0x0000 }, + { 94, 0x0000 }, { 94, 0x0000 }, { 94, 0x0002 }, { 95, 0x1000 }, + /* 0x4f00 */ + { 96, 0x0009 }, { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x0200 }, + { 99, 0x0000 }, { 99, 0x0040 }, { 100, 0x0000 }, { 100, 0x0000 }, + { 100, 0x0400 }, { 101, 0x0414 }, { 104, 0x0000 }, { 104, 0x0000 }, + { 104, 0x2200 }, { 106, 0x0000 }, { 106, 0x0000 }, { 106, 0x8000 }, + /* 0x5000 */ + { 107, 0x0000 }, { 107, 0x4000 }, { 108, 0x0004 }, { 109, 0x0000 }, + { 109, 0x0045 }, { 112, 0x0000 }, { 112, 0x0000 }, { 112, 0x0001 }, + { 113, 0x0000 }, { 113, 0x0010 }, { 114, 0x0000 }, { 114, 0x0000 }, + { 114, 0x0000 }, { 114, 0x0100 }, { 115, 0x0000 }, { 115, 0x0010 }, + /* 0x5100 */ + { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0000 }, + { 116, 0x0400 }, { 117, 0x0000 }, { 117, 0x0010 }, { 118, 0x0000 }, + { 118, 0x0000 }, { 118, 0x2000 }, { 119, 0x0000 }, { 119, 0x4000 }, + { 120, 0x0000 }, { 120, 0x0000 }, { 120, 0x1000 }, { 121, 0x0000 }, + /* 0x5200 */ + { 121, 0x0000 }, { 121, 0x0020 }, { 122, 0x0000 }, { 122, 0x0000 }, + { 122, 0x0000 }, { 122, 0x0000 }, { 122, 0x0000 }, { 122, 0x0000 }, + { 122, 0x0000 }, { 122, 0x1000 }, { 123, 0x8040 }, { 125, 0x0000 }, + { 125, 0x0001 }, { 126, 0x0800 }, { 127, 0x0000 }, { 127, 0x0000 }, + /* 0x5300 */ + { 127, 0x0081 }, { 129, 0x0000 }, { 129, 0x0010 }, { 130, 0x0000 }, + { 130, 0x0000 }, { 130, 0x0000 }, { 130, 0x0000 }, { 130, 0x0004 }, + { 131, 0x0000 }, { 131, 0x0008 }, { 132, 0x0000 }, { 132, 0x0004 }, + { 133, 0x0000 }, { 133, 0x2000 }, { 134, 0x0000 }, { 134, 0x0000 }, + /* 0x5400 */ + { 134, 0x0000 }, { 134, 0x0000 }, { 134, 0x0000 }, { 134, 0x0000 }, + { 134, 0x0000 }, { 134, 0x0000 }, { 134, 0x0000 }, { 134, 0x0000 }, + { 134, 0x0400 }, { 135, 0x1000 }, { 136, 0x0200 }, { 137, 0x0000 }, + { 137, 0x0000 }, { 137, 0x0000 }, { 137, 0x0000 }, { 137, 0x8000 }, + /* 0x5500 */ + { 138, 0x0000 }, { 138, 0x0000 }, { 138, 0x0000 }, { 138, 0x0000 }, + { 138, 0x0000 }, { 138, 0x0000 }, { 138, 0x0000 }, { 138, 0x0000 }, + { 138, 0x0040 }, +}; +static const Summary16 cp932ext_uni2indx_page57[44] = { + /* 0x5700 */ + { 139, 0x0000 }, { 139, 0x0000 }, { 139, 0x0000 }, { 139, 0x0000 }, + { 139, 0x0000 }, { 139, 0x0200 }, { 140, 0x0020 }, { 141, 0x0000 }, + { 141, 0x0000 }, { 141, 0x0000 }, { 141, 0x1000 }, { 142, 0x0000 }, + { 142, 0x0180 }, { 144, 0x0000 }, { 144, 0x0000 }, { 144, 0x0000 }, + /* 0x5800 */ + { 144, 0x0000 }, { 144, 0x0000 }, { 144, 0x0000 }, { 144, 0x0000 }, + { 144, 0x0000 }, { 144, 0x0000 }, { 144, 0x0000 }, { 144, 0x0000 }, + { 144, 0x0000 }, { 144, 0x4000 }, { 145, 0x0000 }, { 145, 0x0004 }, + { 146, 0x0000 }, { 146, 0x0000 }, { 146, 0x0000 }, { 146, 0x0000 }, + /* 0x5900 */ + { 146, 0x0800 }, { 147, 0x0000 }, { 147, 0x0000 }, { 147, 0x0000 }, + { 147, 0x0000 }, { 147, 0x2808 }, { 150, 0x0008 }, { 151, 0x0000 }, + { 151, 0x0000 }, { 151, 0x0000 }, { 151, 0x0010 }, { 152, 0x0400 }, +}; +static const Summary16 cp932ext_uni2indx_page5b[46] = { + /* 0x5b00 */ + { 153, 0x0000 }, { 153, 0x0000 }, { 153, 0x0000 }, { 153, 0x0000 }, + { 153, 0x0000 }, { 153, 0x0040 }, { 154, 0x0000 }, { 154, 0x0000 }, + { 154, 0x0000 }, { 154, 0x0000 }, { 154, 0x0000 }, { 154, 0x0000 }, + { 154, 0x0001 }, { 155, 0x0100 }, { 156, 0x1000 }, { 157, 0x0000 }, + /* 0x5c00 */ + { 157, 0x0000 }, { 157, 0x4000 }, { 158, 0x0000 }, { 158, 0x0000 }, + { 158, 0x0000 }, { 158, 0x0000 }, { 158, 0x0000 }, { 158, 0x0000 }, + { 158, 0x0000 }, { 158, 0x0000 }, { 158, 0x0040 }, { 159, 0x0400 }, + { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0020 }, + /* 0x5d00 */ + { 161, 0x0000 }, { 161, 0x0000 }, { 161, 0x0080 }, { 162, 0x0000 }, + { 162, 0x0004 }, { 163, 0x0008 }, { 164, 0x2000 }, { 165, 0x0000 }, + { 165, 0x0000 }, { 165, 0x0000 }, { 165, 0x0000 }, { 165, 0x0300 }, + { 167, 0x0000 }, { 167, 0x0001 }, +}; +static const Summary16 cp932ext_uni2indx_page5f[458] = { + /* 0x5f00 */ + { 168, 0x0000 }, { 168, 0x0000 }, { 168, 0x0002 }, { 169, 0x0010 }, + { 170, 0x0020 }, { 171, 0x0000 }, { 171, 0x0080 }, { 172, 0x0000 }, + { 172, 0x0000 }, { 172, 0x0000 }, { 172, 0x0000 }, { 172, 0x0080 }, + { 173, 0x0000 }, { 173, 0x4000 }, { 174, 0x0000 }, { 174, 0x0000 }, + /* 0x6000 */ + { 174, 0x0000 }, { 174, 0x0000 }, { 174, 0x0000 }, { 174, 0x0000 }, + { 174, 0x0000 }, { 174, 0x2000 }, { 175, 0x0000 }, { 175, 0x0000 }, + { 175, 0x0420 }, { 177, 0x0000 }, { 177, 0x0000 }, { 177, 0x0000 }, + { 177, 0x0000 }, { 177, 0x4020 }, { 179, 0x0000 }, { 179, 0x0004 }, + /* 0x6100 */ + { 180, 0x0000 }, { 180, 0x0002 }, { 181, 0x0001 }, { 182, 0x0081 }, + { 184, 0x0000 }, { 184, 0x0000 }, { 184, 0x0000 }, { 184, 0x0000 }, + { 184, 0x0000 }, { 184, 0x0100 }, { 185, 0x0000 }, { 185, 0x0000 }, + { 185, 0x0000 }, { 185, 0x0000 }, { 185, 0x0000 }, { 185, 0x0000 }, + /* 0x6200 */ + { 185, 0x0000 }, { 185, 0x0008 }, { 186, 0x0000 }, { 186, 0x0000 }, + { 186, 0x0000 }, { 186, 0x0000 }, { 186, 0x0000 }, { 186, 0x0000 }, + { 186, 0x0000 }, { 186, 0x0000 }, { 186, 0x0040 }, { 187, 0x0000 }, + { 187, 0x0000 }, { 187, 0x0000 }, { 187, 0x0000 }, { 187, 0x0000 }, + /* 0x6300 */ + { 187, 0x0000 }, { 187, 0x0000 }, { 187, 0x0000 }, { 187, 0x0000 }, + { 187, 0x0000 }, { 187, 0x0000 }, { 187, 0x0000 }, { 187, 0x0000 }, + { 187, 0x0000 }, { 187, 0x0000 }, { 187, 0x0000 }, { 187, 0x0000 }, + { 187, 0x0000 }, { 187, 0x0000 }, { 187, 0x0000 }, { 187, 0x0020 }, + /* 0x6400 */ + { 188, 0x0000 }, { 188, 0x0000 }, { 188, 0x0000 }, { 188, 0x0000 }, + { 188, 0x0000 }, { 188, 0x0000 }, { 188, 0x0001 }, { 189, 0x0000 }, + { 189, 0x0000 }, { 189, 0x2000 }, { 190, 0x0000 }, { 190, 0x0000 }, + { 190, 0x4000 }, { 191, 0x0000 }, { 191, 0x0000 }, { 191, 0x0000 }, + /* 0x6500 */ + { 191, 0x0000 }, { 191, 0x0000 }, { 191, 0x0000 }, { 191, 0x0000 }, + { 191, 0x4000 }, { 192, 0x0000 }, { 192, 0x0000 }, { 192, 0x0000 }, + { 192, 0x0000 }, { 192, 0x0000 }, { 192, 0x0000 }, { 192, 0x0000 }, + { 192, 0x0000 }, { 192, 0x0000 }, { 192, 0x0000 }, { 192, 0x0000 }, + /* 0x6600 */ + { 192, 0x0201 }, { 194, 0x4020 }, { 196, 0x4010 }, { 198, 0x0802 }, + { 200, 0x0000 }, { 200, 0x0280 }, { 202, 0x0020 }, { 203, 0x0008 }, + { 204, 0x0000 }, { 204, 0x0200 }, { 205, 0x0001 }, { 206, 0x8004 }, + { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0c00 }, + /* 0x6700 */ + { 210, 0x4000 }, { 211, 0x0000 }, { 211, 0x0000 }, { 211, 0x0000 }, + { 211, 0x0000 }, { 211, 0x0000 }, { 211, 0x0040 }, { 212, 0x0000 }, + { 212, 0x0000 }, { 212, 0x0000 }, { 212, 0x0000 }, { 212, 0x0800 }, + { 213, 0x0001 }, { 214, 0x0000 }, { 214, 0x0000 }, { 214, 0x0000 }, + /* 0x6800 */ + { 214, 0x0002 }, { 215, 0x0000 }, { 215, 0x0000 }, { 215, 0x0000 }, + { 215, 0x0010 }, { 216, 0x0004 }, { 217, 0x0000 }, { 217, 0x0000 }, + { 217, 0x0000 }, { 217, 0x0000 }, { 217, 0x0000 }, { 217, 0x0000 }, + { 217, 0x8100 }, { 219, 0x0000 }, { 219, 0x0000 }, { 219, 0x0000 }, + /* 0x6900 */ + { 219, 0x0000 }, { 219, 0x0000 }, { 219, 0x0000 }, { 219, 0x0000 }, + { 219, 0x0000 }, { 219, 0x0000 }, { 219, 0x0100 }, { 220, 0x0000 }, + { 220, 0x0000 }, { 220, 0x0100 }, { 221, 0x0000 }, { 221, 0x0000 }, + { 221, 0x0000 }, { 221, 0x0000 }, { 221, 0x0004 }, { 222, 0x0000 }, + /* 0x6a00 */ + { 222, 0x0000 }, { 222, 0x0000 }, { 222, 0x0000 }, { 222, 0x0001 }, + { 223, 0x0040 }, { 224, 0x0000 }, { 224, 0x0800 }, { 225, 0x4008 }, + { 227, 0x0000 }, { 227, 0x0000 }, { 227, 0x0000 }, { 227, 0x0000 }, + { 227, 0x0000 }, { 227, 0x0000 }, { 227, 0x0014 }, { 229, 0x0000 }, + /* 0x6b00 */ + { 229, 0x0000 }, { 229, 0x0000 }, { 229, 0x0000 }, { 229, 0x0000 }, + { 229, 0x0000 }, { 229, 0x0000 }, { 229, 0x0000 }, { 229, 0x0000 }, + { 229, 0x0000 }, { 229, 0x0000 }, { 229, 0x0000 }, { 229, 0x0000 }, + { 229, 0x0000 }, { 229, 0x0040 }, { 230, 0x0000 }, { 230, 0x0000 }, + /* 0x6c00 */ + { 230, 0x0000 }, { 230, 0x0000 }, { 230, 0x0000 }, { 230, 0x8000 }, + { 231, 0x0000 }, { 231, 0x1000 }, { 232, 0x8000 }, { 233, 0x0000 }, + { 233, 0x0040 }, { 234, 0x0000 }, { 234, 0x0000 }, { 234, 0x0000 }, + { 234, 0x0000 }, { 234, 0x0400 }, { 235, 0x0000 }, { 235, 0x0000 }, + /* 0x6d00 */ + { 235, 0x0010 }, { 236, 0x0000 }, { 236, 0x0000 }, { 236, 0x0000 }, + { 236, 0x0000 }, { 236, 0x0000 }, { 236, 0x8000 }, { 237, 0x0000 }, + { 237, 0x0080 }, { 238, 0x0040 }, { 239, 0x1000 }, { 240, 0x0000 }, + { 240, 0x8000 }, { 241, 0x0000 }, { 241, 0x0000 }, { 241, 0x1104 }, + /* 0x6e00 */ + { 244, 0x0000 }, { 244, 0x0000 }, { 244, 0x0080 }, { 245, 0x1200 }, + { 247, 0x0000 }, { 247, 0x1000 }, { 248, 0x0000 }, { 248, 0x0000 }, + { 248, 0x0000 }, { 248, 0x0000 }, { 248, 0x0000 }, { 248, 0x8000 }, + { 249, 0x0000 }, { 249, 0x0000 }, { 249, 0x0000 }, { 249, 0x0000 }, + /* 0x6f00 */ + { 249, 0x0000 }, { 249, 0x0000 }, { 249, 0x0000 }, { 249, 0x0000 }, + { 249, 0x0000 }, { 249, 0x0000 }, { 249, 0x0000 }, { 249, 0x0000 }, + { 249, 0x0100 }, { 250, 0x0000 }, { 250, 0x0000 }, { 250, 0x0020 }, + { 251, 0x0000 }, { 251, 0x0000 }, { 251, 0x0000 }, { 251, 0x0020 }, + /* 0x7000 */ + { 252, 0x00a0 }, { 254, 0x0000 }, { 254, 0x0100 }, { 255, 0x0000 }, + { 255, 0x0000 }, { 255, 0x0000 }, { 255, 0x0000 }, { 255, 0x0000 }, + { 255, 0x0020 }, { 256, 0x0000 }, { 256, 0x0800 }, { 257, 0x0800 }, + { 258, 0x0000 }, { 258, 0x0000 }, { 258, 0x0000 }, { 258, 0x0000 }, + /* 0x7100 */ + { 258, 0x8010 }, { 260, 0x0000 }, { 260, 0x0000 }, { 260, 0x0000 }, + { 260, 0x00c0 }, { 262, 0x1000 }, { 263, 0x0000 }, { 263, 0x0000 }, + { 263, 0x0000 }, { 263, 0x0000 }, { 263, 0x0000 }, { 263, 0x0000 }, + { 263, 0x0002 }, { 264, 0x0000 }, { 264, 0x0000 }, { 264, 0x4000 }, + /* 0x7200 */ + { 265, 0x0000 }, { 265, 0x0000 }, { 265, 0x0000 }, { 265, 0x0000 }, + { 265, 0x0000 }, { 265, 0x0000 }, { 265, 0x0000 }, { 265, 0x0000 }, + { 265, 0x0000 }, { 265, 0x0000 }, { 265, 0x0000 }, { 265, 0x4002 }, + { 267, 0x0000 }, { 267, 0x0000 }, { 267, 0x0000 }, { 267, 0x0000 }, + /* 0x7300 */ + { 267, 0x0000 }, { 267, 0x0000 }, { 267, 0x0010 }, { 268, 0x0000 }, + { 268, 0x0000 }, { 268, 0x0000 }, { 268, 0x0000 }, { 268, 0x0080 }, + { 269, 0x0000 }, { 269, 0x0000 }, { 269, 0x0000 }, { 269, 0x2000 }, + { 270, 0x0200 }, { 271, 0x0044 }, { 273, 0x0008 }, { 274, 0x0020 }, + /* 0x7400 */ + { 275, 0x0080 }, { 276, 0x0000 }, { 276, 0x4640 }, { 280, 0x0000 }, + { 280, 0x0000 }, { 280, 0x0000 }, { 280, 0x0004 }, { 281, 0x0000 }, + { 281, 0x0200 }, { 282, 0x8000 }, { 283, 0x0000 }, { 283, 0x0000 }, + { 283, 0x0000 }, { 283, 0x0000 }, { 283, 0x0000 }, { 283, 0x0000 }, + /* 0x7500 */ + { 283, 0x0002 }, { 284, 0x0000 }, { 284, 0x8000 }, { 285, 0x0000 }, + { 285, 0x0000 }, { 285, 0x0000 }, { 285, 0x8000 }, { 286, 0x0000 }, + { 286, 0x0000 }, { 286, 0x0000 }, { 286, 0x0000 }, { 286, 0x0000 }, + { 286, 0x0000 }, { 286, 0x0000 }, { 286, 0x0000 }, { 286, 0x0000 }, + /* 0x7600 */ + { 286, 0x0000 }, { 286, 0x0000 }, { 286, 0x0000 }, { 286, 0x0000 }, + { 286, 0x0000 }, { 286, 0x0000 }, { 286, 0x0000 }, { 286, 0x0000 }, + { 286, 0x0004 }, { 287, 0x5800 }, { 290, 0x0040 }, { 291, 0x0000 }, + { 291, 0x0000 }, { 291, 0x0000 }, { 291, 0x0000 }, { 291, 0x0000 }, + /* 0x7700 */ + { 291, 0x0000 }, { 291, 0x0000 }, { 291, 0x0000 }, { 291, 0x0000 }, + { 291, 0x0040 }, { 292, 0x0000 }, { 292, 0x0000 }, { 292, 0x0000 }, + { 292, 0x0000 }, { 292, 0x0000 }, { 292, 0x0000 }, { 292, 0x0000 }, + { 292, 0x0000 }, { 292, 0x0000 }, { 292, 0x0000 }, { 292, 0x0000 }, + /* 0x7800 */ + { 292, 0x0000 }, { 292, 0x0000 }, { 292, 0x0002 }, { 293, 0x0000 }, + { 293, 0x4000 }, { 294, 0x0000 }, { 294, 0x0010 }, { 295, 0x0400 }, + { 296, 0x0000 }, { 296, 0x0000 }, { 296, 0x0000 }, { 296, 0x0000 }, + { 296, 0x0000 }, { 296, 0x0000 }, { 296, 0x0000 }, { 296, 0x0000 }, + /* 0x7900 */ + { 296, 0x0000 }, { 296, 0x0000 }, { 296, 0x0000 }, { 296, 0x0001 }, + { 297, 0x0000 }, { 297, 0x0000 }, { 297, 0x0000 }, { 297, 0x0000 }, + { 297, 0x0000 }, { 297, 0x0810 }, { 299, 0x0000 }, { 299, 0x0000 }, + { 299, 0x0000 }, { 299, 0x0000 }, { 299, 0x0000 }, { 299, 0x0000 }, + /* 0x7a00 */ + { 299, 0x0000 }, { 299, 0x0000 }, { 299, 0x0000 }, { 299, 0x0000 }, + { 299, 0x0000 }, { 299, 0x0000 }, { 299, 0x0000 }, { 299, 0x0000 }, + { 299, 0x0000 }, { 299, 0x0000 }, { 299, 0x0000 }, { 299, 0x0000 }, + { 299, 0x0000 }, { 299, 0x0002 }, { 300, 0x0880 }, { 302, 0x0000 }, + /* 0x7b00 */ + { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, + { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0000 }, + { 302, 0x0000 }, { 302, 0x4000 }, +}; +static const Summary16 cp932ext_uni2indx_page7d[43] = { + /* 0x7d00 */ + { 303, 0x0000 }, { 303, 0x0000 }, { 303, 0x0000 }, { 303, 0x0000 }, + { 303, 0x0100 }, { 304, 0x1000 }, { 305, 0x0000 }, { 305, 0x0000 }, + { 305, 0x0000 }, { 305, 0x0000 }, { 305, 0x0001 }, { 306, 0x0080 }, + { 307, 0x0000 }, { 307, 0x0040 }, { 308, 0x0000 }, { 308, 0x0000 }, + /* 0x7e00 */ + { 308, 0x0000 }, { 308, 0x0000 }, { 308, 0x0000 }, { 308, 0x0000 }, + { 308, 0x0000 }, { 308, 0x0004 }, { 309, 0x0000 }, { 309, 0x0000 }, + { 309, 0x0400 }, { 310, 0x0000 }, { 310, 0x0000 }, { 310, 0x0000 }, + { 310, 0x0000 }, { 310, 0x0000 }, { 310, 0x0000 }, { 310, 0x0000 }, + /* 0x7f00 */ + { 310, 0x0000 }, { 310, 0x0000 }, { 310, 0x0000 }, { 310, 0x0000 }, + { 310, 0x0080 }, { 311, 0x0000 }, { 311, 0x0000 }, { 311, 0x0000 }, + { 311, 0x0000 }, { 311, 0x0000 }, { 311, 0x0002 }, +}; +static const Summary16 cp932ext_uni2indx_page83[44] = { + /* 0x8300 */ + { 312, 0x0002 }, { 313, 0x0000 }, { 313, 0x0000 }, { 313, 0x0000 }, + { 313, 0x0000 }, { 313, 0x0000 }, { 313, 0x0004 }, { 314, 0x8000 }, + { 315, 0x0000 }, { 315, 0x0000 }, { 315, 0x0000 }, { 315, 0x0000 }, + { 315, 0x0080 }, { 316, 0x0000 }, { 316, 0x0000 }, { 316, 0x0040 }, + /* 0x8400 */ + { 317, 0x0000 }, { 317, 0x0000 }, { 317, 0x0000 }, { 317, 0x0000 }, + { 317, 0x0100 }, { 318, 0x0000 }, { 318, 0x0000 }, { 318, 0x0000 }, + { 318, 0x0000 }, { 318, 0x0000 }, { 318, 0x0000 }, { 318, 0x0010 }, + { 319, 0x0000 }, { 319, 0x1000 }, { 320, 0x0000 }, { 320, 0x0000 }, + /* 0x8500 */ + { 320, 0x0000 }, { 320, 0x0000 }, { 320, 0x0000 }, { 320, 0x0000 }, + { 320, 0x0000 }, { 320, 0x0208 }, { 322, 0x0800 }, { 323, 0x0000 }, + { 323, 0x0000 }, { 323, 0x0000 }, { 323, 0x0000 }, { 323, 0x0001 }, +}; +static const Summary16 cp932ext_uni2indx_page88[109] = { + /* 0x8800 */ + { 324, 0x0080 }, { 325, 0x0000 }, { 325, 0x0000 }, { 325, 0x0000 }, + { 325, 0x0000 }, { 325, 0x0000 }, { 325, 0x0000 }, { 325, 0x0000 }, + { 325, 0x0000 }, { 325, 0x0000 }, { 325, 0x0000 }, { 325, 0x0000 }, + { 325, 0x0000 }, { 325, 0x0000 }, { 325, 0x0000 }, { 325, 0x0020 }, + /* 0x8900 */ + { 326, 0x0000 }, { 326, 0x1000 }, { 327, 0x0000 }, { 327, 0x0000 }, + { 327, 0x0000 }, { 327, 0x0000 }, { 327, 0x0000 }, { 327, 0x0000 }, + { 327, 0x0000 }, { 327, 0x0000 }, { 327, 0x0000 }, { 327, 0x0000 }, + { 327, 0x0000 }, { 327, 0x0000 }, { 327, 0x0000 }, { 327, 0x0000 }, + /* 0x8a00 */ + { 327, 0x0000 }, { 327, 0x0004 }, { 328, 0x0000 }, { 328, 0x0080 }, + { 329, 0x0000 }, { 329, 0x0000 }, { 329, 0x0000 }, { 329, 0x0200 }, + { 330, 0x0000 }, { 330, 0x0000 }, { 330, 0x0080 }, { 331, 0x4000 }, + { 332, 0x0000 }, { 332, 0x8000 }, { 333, 0x0000 }, { 333, 0x0040 }, + /* 0x8b00 */ + { 334, 0x0000 }, { 334, 0x0000 }, { 334, 0x0000 }, { 334, 0x0000 }, + { 334, 0x0000 }, { 334, 0x0008 }, { 335, 0x0000 }, { 335, 0x8000 }, + { 336, 0x0000 }, { 336, 0x0000 }, { 336, 0x0000 }, { 336, 0x0000 }, + { 336, 0x0000 }, { 336, 0x0000 }, { 336, 0x0000 }, { 336, 0x0000 }, + /* 0x8c00 */ + { 336, 0x0000 }, { 336, 0x0000 }, { 336, 0x0000 }, { 336, 0x0000 }, + { 336, 0x0000 }, { 336, 0x0000 }, { 336, 0x0000 }, { 336, 0x0000 }, + { 336, 0x0000 }, { 336, 0x0000 }, { 336, 0x0000 }, { 336, 0x0000 }, + { 336, 0x0000 }, { 336, 0x0000 }, { 336, 0x0000 }, { 336, 0x0011 }, + /* 0x8d00 */ + { 338, 0x0000 }, { 338, 0x0004 }, { 339, 0x0000 }, { 339, 0x0000 }, + { 339, 0x0000 }, { 339, 0x0000 }, { 339, 0x0000 }, { 339, 0x0040 }, + { 340, 0x0000 }, { 340, 0x0000 }, { 340, 0x0000 }, { 340, 0x0000 }, + { 340, 0x0000 }, { 340, 0x0000 }, { 340, 0x0000 }, { 340, 0x0000 }, + /* 0x8e00 */ + { 340, 0x0000 }, { 340, 0x0000 }, { 340, 0x0000 }, { 340, 0x0000 }, + { 340, 0x0000 }, { 340, 0x0000 }, { 340, 0x0000 }, { 340, 0x0000 }, + { 340, 0x0000 }, { 340, 0x0000 }, { 340, 0x0000 }, { 340, 0x0000 }, + { 340, 0x8000 }, +}; +static const Summary16 cp932ext_uni2indx_page90[238] = { + /* 0x9000 */ + { 341, 0x0000 }, { 341, 0x0000 }, { 341, 0x0000 }, { 341, 0x0000 }, + { 341, 0x0000 }, { 341, 0x0000 }, { 341, 0x0080 }, { 342, 0x0000 }, + { 342, 0x0000 }, { 342, 0x0000 }, { 342, 0x0000 }, { 342, 0x0000 }, + { 342, 0x0000 }, { 342, 0x4000 }, { 343, 0x0000 }, { 343, 0x0000 }, + /* 0x9100 */ + { 343, 0x0000 }, { 343, 0x0020 }, { 344, 0x0080 }, { 345, 0x0000 }, + { 345, 0x0000 }, { 345, 0x0000 }, { 345, 0x0000 }, { 345, 0x0000 }, + { 345, 0x0000 }, { 345, 0x0000 }, { 345, 0x0000 }, { 345, 0x0000 }, + { 345, 0x0000 }, { 345, 0x4480 }, { 348, 0x6030 }, { 352, 0x0000 }, + /* 0x9200 */ + { 352, 0x0440 }, { 354, 0x0001 }, { 355, 0x0000 }, { 355, 0x1600 }, + { 358, 0x4001 }, { 360, 0x0202 }, { 362, 0x0080 }, { 363, 0x0180 }, + { 365, 0x0100 }, { 366, 0x0000 }, { 366, 0x0080 }, { 367, 0x0000 }, + { 367, 0x0000 }, { 367, 0x02a9 }, { 372, 0x0081 }, { 374, 0x8a00 }, + /* 0x9300 */ + { 377, 0x0004 }, { 378, 0x6000 }, { 380, 0x0022 }, { 382, 0x0000 }, + { 382, 0x0100 }, { 383, 0x0080 }, { 384, 0x0000 }, { 384, 0x0001 }, + { 385, 0x0000 }, { 385, 0x0000 }, { 385, 0x0010 }, { 386, 0x0000 }, + { 386, 0x0040 }, { 387, 0x4000 }, { 388, 0x0000 }, { 388, 0x0100 }, + /* 0x9400 */ + { 389, 0x0000 }, { 389, 0x0000 }, { 389, 0x0000 }, { 389, 0x0002 }, + { 390, 0x0120 }, { 392, 0x0000 }, { 392, 0x0000 }, { 392, 0x0000 }, + { 392, 0x0000 }, { 392, 0x0000 }, { 392, 0x0000 }, { 392, 0x0000 }, + { 392, 0x0000 }, { 392, 0x0000 }, { 392, 0x0000 }, { 392, 0x0000 }, + /* 0x9500 */ + { 392, 0x0000 }, { 392, 0x0000 }, { 392, 0x0000 }, { 392, 0x0000 }, + { 392, 0x0000 }, { 392, 0x0000 }, { 392, 0x0000 }, { 392, 0x0000 }, + { 392, 0x0000 }, { 392, 0x0004 }, { 393, 0x0000 }, { 393, 0x0000 }, + { 393, 0x0000 }, { 393, 0x0000 }, { 393, 0x0000 }, { 393, 0x0000 }, + /* 0x9600 */ + { 393, 0x0000 }, { 393, 0x0000 }, { 393, 0x0000 }, { 393, 0x0000 }, + { 393, 0x0000 }, { 393, 0x0000 }, { 393, 0x0000 }, { 393, 0x0000 }, + { 393, 0x0000 }, { 393, 0x2000 }, { 394, 0x8000 }, { 395, 0x0000 }, + { 395, 0x0000 }, { 395, 0x0000 }, { 395, 0x0000 }, { 395, 0x0000 }, + /* 0x9700 */ + { 395, 0x0000 }, { 395, 0x0000 }, { 395, 0x0000 }, { 395, 0x0808 }, + { 397, 0xa008 }, { 400, 0x0022 }, { 402, 0x0000 }, { 402, 0x0000 }, + { 402, 0x0000 }, { 402, 0x0000 }, { 402, 0x0000 }, { 402, 0x0000 }, + { 402, 0x0000 }, { 402, 0x0000 }, { 402, 0x0000 }, { 402, 0x0000 }, + /* 0x9800 */ + { 402, 0x0000 }, { 402, 0x0000 }, { 402, 0x0000 }, { 402, 0x0000 }, + { 402, 0x0000 }, { 402, 0x0080 }, { 403, 0x0020 }, { 404, 0x0000 }, + { 404, 0x0000 }, { 404, 0x0000 }, { 404, 0x0000 }, { 404, 0x0000 }, + { 404, 0x0000 }, { 404, 0x0000 }, { 404, 0x0000 }, { 404, 0x0000 }, + /* 0x9900 */ + { 404, 0x0000 }, { 404, 0x0000 }, { 404, 0x0080 }, { 405, 0x0000 }, + { 405, 0x0000 }, { 405, 0x0000 }, { 405, 0x0000 }, { 405, 0x0000 }, + { 405, 0x0000 }, { 405, 0x4000 }, { 406, 0x0000 }, { 406, 0x0000 }, + { 406, 0x0000 }, { 406, 0x0000 }, { 406, 0x0000 }, { 406, 0x0000 }, + /* 0x9a00 */ + { 406, 0x0000 }, { 406, 0x0000 }, { 406, 0x0000 }, { 406, 0x0000 }, + { 406, 0x4000 }, { 407, 0x0000 }, { 407, 0x0000 }, { 407, 0x0000 }, + { 407, 0x0000 }, { 407, 0x0000 }, { 407, 0x0000 }, { 407, 0x0000 }, + { 407, 0x0000 }, { 407, 0x1200 }, { 409, 0x0000 }, { 409, 0x0000 }, + /* 0x9b00 */ + { 409, 0x0000 }, { 409, 0x0000 }, { 409, 0x0000 }, { 409, 0x0000 }, + { 409, 0x0000 }, { 409, 0x0000 }, { 409, 0x0000 }, { 409, 0x0024 }, + { 411, 0x8000 }, { 412, 0x0000 }, { 412, 0x0000 }, { 412, 0x0802 }, + { 414, 0x0000 }, { 414, 0x0000 }, { 414, 0x0000 }, { 414, 0x0000 }, + /* 0x9c00 */ + { 414, 0x0001 }, { 415, 0x0000 }, { 415, 0x0000 }, { 415, 0x0000 }, + { 415, 0x0000 }, { 415, 0x0000 }, { 415, 0x0000 }, { 415, 0x0000 }, + { 415, 0x0000 }, { 415, 0x0000 }, { 415, 0x0000 }, { 415, 0x0000 }, + { 415, 0x0000 }, { 415, 0x0000 }, { 415, 0x0000 }, { 415, 0x0000 }, + /* 0x9d00 */ + { 415, 0x0000 }, { 415, 0x0000 }, { 415, 0x0000 }, { 415, 0x0000 }, + { 415, 0x0000 }, { 415, 0x0000 }, { 415, 0x0800 }, { 416, 0x0001 }, + { 417, 0x0000 }, { 417, 0x0000 }, { 417, 0x0000 }, { 417, 0x0000 }, + { 417, 0x0000 }, { 417, 0x0000 }, { 417, 0x0000 }, { 417, 0x0000 }, + /* 0x9e00 */ + { 417, 0x0000 }, { 417, 0x0200 }, { 418, 0x0000 }, { 418, 0x0000 }, + { 418, 0x0000 }, { 418, 0x0000 }, { 418, 0x0000 }, { 418, 0x0000 }, + { 418, 0x0000 }, { 418, 0x0000 }, { 418, 0x0000 }, { 418, 0x0000 }, + { 418, 0x0000 }, { 418, 0x0002 }, +}; +static const Summary16 cp932ext_uni2indx_pagef9[19] = { + /* 0xf900 */ + { 419, 0x0000 }, { 419, 0x0000 }, { 419, 0x0200 }, { 420, 0x0000 }, + { 420, 0x0000 }, { 420, 0x0000 }, { 420, 0x0000 }, { 420, 0x0000 }, + { 420, 0x0000 }, { 420, 0x0000 }, { 420, 0x0000 }, { 420, 0x0000 }, + { 420, 0x0000 }, { 420, 0x1000 }, { 421, 0x0000 }, { 421, 0x0000 }, + /* 0xfa00 */ + { 421, 0xc000 }, { 423, 0xffff }, { 439, 0x3fff }, +}; +static const Summary16 cp932ext_uni2indx_pageff[15] = { + /* 0xff00 */ + { 453, 0x0084 }, { 455, 0x0000 }, { 455, 0x0000 }, { 455, 0x0000 }, + { 455, 0x0000 }, { 455, 0x0000 }, { 455, 0x0000 }, { 455, 0x0000 }, + { 455, 0x0000 }, { 455, 0x0000 }, { 455, 0x0000 }, { 455, 0x0000 }, + { 455, 0x0000 }, { 455, 0x0000 }, { 455, 0x0014 }, +}; + +static int +cp932ext_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc >= 0x2100 && wc < 0x22c0) + summary = &cp932ext_uni2indx_page21[(wc>>4)-0x210]; + else if (wc >= 0x2400 && wc < 0x2480) + summary = &cp932ext_uni2indx_page24[(wc>>4)-0x240]; + else if (wc >= 0x3000 && wc < 0x3020) + summary = &cp932ext_uni2indx_page30[(wc>>4)-0x300]; + else if (wc >= 0x3200 && wc < 0x33d0) + summary = &cp932ext_uni2indx_page32[(wc>>4)-0x320]; + else if (wc >= 0x4e00 && wc < 0x5590) + summary = &cp932ext_uni2indx_page4e[(wc>>4)-0x4e0]; + else if (wc >= 0x5700 && wc < 0x59c0) + summary = &cp932ext_uni2indx_page57[(wc>>4)-0x570]; + else if (wc >= 0x5b00 && wc < 0x5de0) + summary = &cp932ext_uni2indx_page5b[(wc>>4)-0x5b0]; + else if (wc >= 0x5f00 && wc < 0x7ba0) + summary = &cp932ext_uni2indx_page5f[(wc>>4)-0x5f0]; + else if (wc >= 0x7d00 && wc < 0x7fb0) + summary = &cp932ext_uni2indx_page7d[(wc>>4)-0x7d0]; + else if (wc >= 0x8300 && wc < 0x85c0) + summary = &cp932ext_uni2indx_page83[(wc>>4)-0x830]; + else if (wc >= 0x8800 && wc < 0x8ed0) + summary = &cp932ext_uni2indx_page88[(wc>>4)-0x880]; + else if (wc >= 0x9000 && wc < 0x9ee0) + summary = &cp932ext_uni2indx_page90[(wc>>4)-0x900]; + else if (wc >= 0xf900 && wc < 0xfa30) + summary = &cp932ext_uni2indx_pagef9[(wc>>4)-0xf90]; + else if (wc >= 0xff00 && wc < 0xfff0) + summary = &cp932ext_uni2indx_pageff[(wc>>4)-0xff0]; + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = cp932ext_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp936.h b/graf2d/win32gdk/gdk/src/iconv/cp936.h new file mode 100644 index 0000000000000..06e510cae2872 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp936.h @@ -0,0 +1,126 @@ +/* + * Copyright (C) 2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP936 + */ + +/* + * The IANA has CP936 as an alias of GBK. But GBK is an official Chinese + * specification, whereas CP936 is de-facto maintained by Microsoft. And, + * of course, Microsoft modified CP936 since 1999. + * + * The differences from GBK are: + * + * 1. A single character: + * + * code CP936.TXT + * 0x80 0x20AC # EURO SIGN + * + * Some variants of CP936 (in JDK, Windows-2000, ICU) also add: + * + * 2. Private area mappings: + * + * code Unicode + * 0x{A1..A2}{40..7E,80..A0} U+E4C6..U+E585 + * 0x{AA..AF,F8..FE}{A1..FE} U+E000..U+E4C5 + * + * We add them too because, although there are backward compatibility problems + * when a character from a private area is moved to an official Unicode code + * point, they are useful for some people in practice. + */ + +static int +cp936_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + /* Try GBK first. */ + { + int ret = ces_gbk_mbtowc(conv,pwc,s,n); + if (ret != RET_ILSEQ) + return ret; + } + /* Then handle the additional mappings. */ + { + unsigned char c = *s; + if (c == 0x80) { + *pwc = 0x20ac; + return 1; + } + /* User-defined characters */ + if (c >= 0xa1 && c <= 0xa2) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0x80 && c2 < 0xa1)) { + *pwc = 0xe4c6 + 96 * (c - 0xa1) + (c2 - (c2 >= 0x80 ? 0x41 : 0x40)); + return 2; + } + } + } else if ((c >= 0xaa && c < 0xb0) || (c >= 0xf8 && c < 0xff)) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 < 0xff) { + *pwc = 0xe000 + 94 * (c - (c >= 0xf8 ? 0xf2 : 0xaa)) + (c2 - 0xa1); + return 2; + } + } + } + } + return RET_ILSEQ; +} + +static int +cp936_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + /* Try GBK first. */ + { + int ret = ces_gbk_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + } + /* Then handle the additional mappings. */ + if (wc >= 0xe000 && wc < 0xe586) { + /* User-defined characters */ + if (n < 2) + return RET_TOOFEW(0); + if (wc < 0xe4c6) { + unsigned int i = wc - 0xe000; + unsigned int c1 = i / 94; + unsigned int c2 = i % 94; + r[0] = c1 + (c1 < 6 ? 0xaa : 0xf2); + r[1] = c2 + 0xa1; + return 2; + } else { + unsigned int i = wc - 0xe4c6; + unsigned int c1 = i / 96; + unsigned int c2 = i % 96; + r[0] = c1 + 0xa1; + r[1] = c2 + (c2 < 0x3f ? 0x40 : 0x41); + return 2; + } + } else if (wc == 0x20ac) { + r[0] = 0x80; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp936ext.h b/graf2d/win32gdk/gdk/src/iconv/cp936ext.h new file mode 100644 index 0000000000000..db1817b701ec9 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp936ext.h @@ -0,0 +1,99 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP936 extensions + */ + +static const unsigned short cp936ext_2uni_pagea6[181-159] = { + /* 0xa6 */ + 0xfe35, + 0xfe36, 0xfe39, 0xfe3a, 0xfe3f, 0xfe40, 0xfe3d, 0xfe3e, 0xfe41, + 0xfe42, 0xfe43, 0xfe44, 0xfffd, 0xfffd, 0xfe3b, 0xfe3c, 0xfe37, + 0xfe38, 0xfe31, 0xfffd, 0xfe33, 0xfe34, +}; +static const unsigned short cp936ext_2uni_pagea8[128-122] = { + /* 0xa8 */ + 0x0251, 0xfffd, 0x0144, 0x0148, 0xfffd, 0x0261, +}; + +static int +cp936ext_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 == 0xa6) || (c1 == 0xa8)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0x80 && c2 < 0xff)) { + unsigned int i = 190 * (c1 - 0x81) + (c2 - (c2 >= 0x80 ? 0x41 : 0x40)); + unsigned short wc = 0xfffd; + if (i < 7410) { + if (i >= 7189 && i < 7211) + wc = cp936ext_2uni_pagea6[i-7189]; + } else { + if (i >= 7532 && i < 7538) + wc = cp936ext_2uni_pagea8[i-7532]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short cp936ext_page01[16] = { + 0x0000, 0x0000, 0x0000, 0x0000, 0xa8bd, 0x0000, 0x0000, 0x0000, /*0x40-0x47*/ + 0xa8be, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x48-0x4f*/ +}; +static const unsigned short cp936ext_page02[24] = { + 0x0000, 0xa8bb, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x50-0x57*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x58-0x5f*/ + 0x0000, 0xa8c0, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x60-0x67*/ +}; +static const unsigned short cp936ext_pagefe[24] = { + 0x0000, 0xa6f2, 0x0000, 0xa6f4, 0xa6f5, 0xa6e0, 0xa6e1, 0xa6f0, /*0x30-0x37*/ + 0xa6f1, 0xa6e2, 0xa6e3, 0xa6ee, 0xa6ef, 0xa6e6, 0xa6e7, 0xa6e4, /*0x38-0x3f*/ + 0xa6e5, 0xa6e8, 0xa6e9, 0xa6ea, 0xa6eb, 0x0000, 0x0000, 0x0000, /*0x40-0x47*/ +}; + +static int +cp936ext_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + unsigned short c = 0; + if (wc >= 0x0140 && wc < 0x0150) + c = cp936ext_page01[wc-0x0140]; + else if (wc >= 0x0250 && wc < 0x0268) + c = cp936ext_page02[wc-0x0250]; + else if (wc >= 0xfe30 && wc < 0xfe48) + c = cp936ext_pagefe[wc-0xfe30]; + if (c != 0) { + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp943.h b/graf2d/win32gdk/gdk/src/iconv/cp943.h new file mode 100644 index 0000000000000..dbaebe97e2a4f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp943.h @@ -0,0 +1,29 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * IBM CP943 + */ + +/* This is essentially CP932, with many mappings missing in the AIX conversion + table. We just pretend it were the same as CP932. */ + +#define cp943_mbtowc cp932_mbtowc +#define cp943_wctomb cp932_wctomb diff --git a/graf2d/win32gdk/gdk/src/iconv/cp949.h b/graf2d/win32gdk/gdk/src/iconv/cp949.h new file mode 100644 index 0000000000000..665e7243ae9c3 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp949.h @@ -0,0 +1,128 @@ +/* + * Copyright (C) 1999-2001, 2005, 2007 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP949 is EUC-KR, extended with UHC (Unified Hangul Code). + * + * Some variants of CP949 (in JDK, Windows-2000, ICU) also add: + * + * 2. Private area mappings: + * + * code Unicode + * 0xC9{A1..FE} U+E000..U+E05D + * 0xFE{A1..FE} U+E05E..U+E0BB + * + * We add them too because, although there are backward compatibility problems + * when a character from a private area is moved to an official Unicode code + * point, they are useful for some people in practice. + */ + +#include "uhc_1.h" +#include "uhc_2.h" + +static int +cp949_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + /* Code set 0 (ASCII) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* UHC part 1 */ + if (c >= 0x81 && c <= 0xa0) + return uhc_1_mbtowc(conv,pwc,s,n); + if (c >= 0xa1 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c2 < 0xa1) + /* UHC part 2 */ + return uhc_2_mbtowc(conv,pwc,s,n); + else if (c2 < 0xff && !(c == 0xa2 && c2 == 0xe8)) { + /* Code set 1 (KS C 5601-1992, now KS X 1001:1998) */ + unsigned char buf[2]; + int ret; + buf[0] = c-0x80; buf[1] = c2-0x80; + ret = ksc5601_mbtowc(conv,pwc,buf,2); + if (ret != RET_ILSEQ) + return ret; + /* User-defined characters */ + if (c == 0xc9) { + *pwc = 0xe000 + (c2 - 0xa1); + return 2; + } + if (c == 0xfe) { + *pwc = 0xe05e + (c2 - 0xa1); + return 2; + } + } + } + } + return RET_ILSEQ; +} + +static int +cp949_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Code set 0 (ASCII) */ + ret = ascii_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + /* Code set 1 (KS C 5601-1992, now KS X 1001:1998) */ + if (wc != 0x327e) { + ret = ksc5601_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]+0x80; + r[1] = buf[1]+0x80; + return 2; + } + } + + /* UHC */ + if (wc >= 0xac00 && wc < 0xd7a4) { + if (wc < 0xc8a5) + return uhc_1_wctomb(conv,r,wc,n); + else + return uhc_2_wctomb(conv,r,wc,n); + } + + /* User-defined characters */ + if (wc >= 0xe000 && wc < 0xe0bc) { + if (n < 2) + return RET_TOOSMALL; + if (wc < 0xe05e) { + r[0] = 0xc9; + r[1] = wc - 0xe000 + 0xa1; + } else { + r[0] = 0xfe; + r[1] = wc - 0xe05e + 0xa1; + } + return 2; + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp950.h b/graf2d/win32gdk/gdk/src/iconv/cp950.h new file mode 100644 index 0000000000000..28ca19945cc95 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp950.h @@ -0,0 +1,284 @@ +/* + * Copyright (C) 1999-2001, 2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP950 + */ + +/* + * Microsoft CP950 is a slightly extended and slightly modified version of + * BIG5. The differences between the EASTASIA/OTHER/BIG5.TXT and + * VENDORS/MICSFT/WINDOWS/CP950.TXT tables found on ftp.unicode.org are + * as follows: + * + * 1. Some characters in the BIG5 range are defined differently: + * + * code BIG5.TXT CP950.TXT + * 0xA145 0x2022 # BULLET 0x2027 # HYPHENATION POINT + * 0xA14E 0xFF64 # HALFWIDTH IDEOGRAPHIC COMMA + * 0xFE51 # SMALL IDEOGRAPHIC COMMA + * 0xA15A --- 0x2574 # BOX DRAWINGS LIGHT LEFT + * 0xA1C2 0x203E # OVERLINE 0x00AF # MACRON + * 0xA1C3 --- 0xFFE3 # FULLWIDTH MACRON + * 0xA1C5 --- 0x02CD # MODIFIER LETTER LOW MACRON + * 0xA1E3 0x223C # TILDE OPERATOR 0xFF5E # FULLWIDTH TILDE + * 0xA1F2 0x2641 # EARTH 0x2295 # CIRCLED PLUS + * 0xA1F3 0x2609 # SUN 0x2299 # CIRCLED DOT OPERATOR + * 0xA1FE --- 0xFF0F # FULLWIDTH SOLIDUS + * 0xA240 --- 0xFF3C # FULLWIDTH REVERSE SOLIDUS + * 0xA241 0xFF0F # FULLWIDTH SOLIDUS 0x2215 # DIVISION SLASH + * 0xA242 0xFF3C # FULLWIDTH REVERSE SOLIDUS + * 0xFE68 # SMALL REVERSE SOLIDUS + * 0xA244 0x00A5 # YEN SIGN 0xFFE5 # FULLWIDTH YEN SIGN + * 0xA246 0x00A2 # CENT SIGN 0xFFE0 # FULLWIDTH CENT SIGN + * 0xA247 0x00A3 # POUND SIGN 0xFFE1 # FULLWIDTH POUND SIGN + * 0xA2CC --- 0x5341 + * 0xA2CE --- 0x5345 + * + * 2. A small new row. See cp950ext.h. + * + * 3. CP950.TXT is lacking the range 0xC6A1..0xC7FC (Hiragana, Katakana, + * Cyrillic, circled digits, parenthesized digits). + * + * We implement this omission, because said range is marked "uncertain" + * in the unicode.org BIG5 table. + * + * The table found on Microsoft's website furthermore adds: + * + * 4. A single character: + * + * code CP950.TXT + * 0xA3E1 0x20AC # EURO SIGN + * + * Many variants of BIG5 or CP950 (in JDK, Solaris, OSF/1, Windows-2000, ICU, + * as well as our BIG5-2003 converter) also add: + * + * 5. Private area mappings: + * + * code Unicode + * 0x{81..8D}{40..7E,A1..FE} U+EEB8..U+F6B0 + * 0x{8E..A0}{40..7E,A1..FE} U+E311..U+EEB7 + * 0x{FA..FE}{40..7E,A1..FE} U+E000..U+E310 + * + * We add them too because, although there are backward compatibility problems + * when a character from a private area is moved to an official Unicode code + * point, they are useful for some people in practice. + */ + +static const unsigned short cp950_2uni_pagea1[314] = { + /* 0xa1 */ + 0x3000, 0xff0c, 0x3001, 0x3002, 0xff0e, 0x2027, 0xff1b, 0xff1a, + 0xff1f, 0xff01, 0xfe30, 0x2026, 0x2025, 0xfe50, 0xfe51, 0xfe52, + 0x00b7, 0xfe54, 0xfe55, 0xfe56, 0xfe57, 0xff5c, 0x2013, 0xfe31, + 0x2014, 0xfe33, 0x2574, 0xfe34, 0xfe4f, 0xff08, 0xff09, 0xfe35, + 0xfe36, 0xff5b, 0xff5d, 0xfe37, 0xfe38, 0x3014, 0x3015, 0xfe39, + 0xfe3a, 0x3010, 0x3011, 0xfe3b, 0xfe3c, 0x300a, 0x300b, 0xfe3d, + 0xfe3e, 0x3008, 0x3009, 0xfe3f, 0xfe40, 0x300c, 0x300d, 0xfe41, + 0xfe42, 0x300e, 0x300f, 0xfe43, 0xfe44, 0xfe59, 0xfe5a, 0xfe5b, + 0xfe5c, 0xfe5d, 0xfe5e, 0x2018, 0x2019, 0x201c, 0x201d, 0x301d, + 0x301e, 0x2035, 0x2032, 0xff03, 0xff06, 0xff0a, 0x203b, 0x00a7, + 0x3003, 0x25cb, 0x25cf, 0x25b3, 0x25b2, 0x25ce, 0x2606, 0x2605, + 0x25c7, 0x25c6, 0x25a1, 0x25a0, 0x25bd, 0x25bc, 0x32a3, 0x2105, + 0x00af, 0xffe3, 0xff3f, 0x02cd, 0xfe49, 0xfe4a, 0xfe4d, 0xfe4e, + 0xfe4b, 0xfe4c, 0xfe5f, 0xfe60, 0xfe61, 0xff0b, 0xff0d, 0x00d7, + 0x00f7, 0x00b1, 0x221a, 0xff1c, 0xff1e, 0xff1d, 0x2266, 0x2267, + 0x2260, 0x221e, 0x2252, 0x2261, 0xfe62, 0xfe63, 0xfe64, 0xfe65, + 0xfe66, 0xff5e, 0x2229, 0x222a, 0x22a5, 0x2220, 0x221f, 0x22bf, + 0x33d2, 0x33d1, 0x222b, 0x222e, 0x2235, 0x2234, 0x2640, 0x2642, + 0x2295, 0x2299, 0x2191, 0x2193, 0x2190, 0x2192, 0x2196, 0x2197, + 0x2199, 0x2198, 0x2225, 0x2223, 0xff0f, + /* 0xa2 */ + 0xff3c, 0x2215, 0xfe68, 0xff04, 0xffe5, 0x3012, 0xffe0, 0xffe1, + 0xff05, 0xff20, 0x2103, 0x2109, 0xfe69, 0xfe6a, 0xfe6b, 0x33d5, + 0x339c, 0x339d, 0x339e, 0x33ce, 0x33a1, 0x338e, 0x338f, 0x33c4, + 0x00b0, 0x5159, 0x515b, 0x515e, 0x515d, 0x5161, 0x5163, 0x55e7, + 0x74e9, 0x7cce, 0x2581, 0x2582, 0x2583, 0x2584, 0x2585, 0x2586, + 0x2587, 0x2588, 0x258f, 0x258e, 0x258d, 0x258c, 0x258b, 0x258a, + 0x2589, 0x253c, 0x2534, 0x252c, 0x2524, 0x251c, 0x2594, 0x2500, + 0x2502, 0x2595, 0x250c, 0x2510, 0x2514, 0x2518, 0x256d, 0x256e, + 0x2570, 0x256f, 0x2550, 0x255e, 0x256a, 0x2561, 0x25e2, 0x25e3, + 0x25e5, 0x25e4, 0x2571, 0x2572, 0x2573, 0xff10, 0xff11, 0xff12, + 0xff13, 0xff14, 0xff15, 0xff16, 0xff17, 0xff18, 0xff19, 0x2160, + 0x2161, 0x2162, 0x2163, 0x2164, 0x2165, 0x2166, 0x2167, 0x2168, + 0x2169, 0x3021, 0x3022, 0x3023, 0x3024, 0x3025, 0x3026, 0x3027, + 0x3028, 0x3029, 0x5341, 0x5344, 0x5345, 0xff21, 0xff22, 0xff23, + 0xff24, 0xff25, 0xff26, 0xff27, 0xff28, 0xff29, 0xff2a, 0xff2b, + 0xff2c, 0xff2d, 0xff2e, 0xff2f, 0xff30, 0xff31, 0xff32, 0xff33, + 0xff34, 0xff35, 0xff36, 0xff37, 0xff38, 0xff39, 0xff3a, 0xff41, + 0xff42, 0xff43, 0xff44, 0xff45, 0xff46, 0xff47, 0xff48, 0xff49, + 0xff4a, 0xff4b, 0xff4c, 0xff4d, 0xff4e, 0xff4f, 0xff50, 0xff51, + 0xff52, 0xff53, 0xff54, 0xff55, 0xff56, +}; + +#include "cp950ext.h" + +static int +cp950_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + /* Code set 0 (ASCII) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (BIG5 extended) */ + if (c >= 0x81 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0xa1 && c2 < 0xff)) { + if (c >= 0xa1) { + if (c < 0xa3) { + unsigned int i = 157 * (c - 0xa1) + (c2 - (c2 >= 0xa1 ? 0x62 : 0x40)); + unsigned short wc = cp950_2uni_pagea1[i]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + if (!((c == 0xc6 && c2 >= 0xa1) || c == 0xc7)) { + int ret = big5_mbtowc(conv,pwc,s,2); + if (ret != RET_ILSEQ) + return ret; + } + if (c == 0xa3 && c2 == 0xe1) { + *pwc = 0x20ac; + return 2; + } + if (c >= 0xfa) { + /* User-defined characters */ + *pwc = 0xe000 + 157 * (c - 0xfa) + (c2 - (c2 >= 0xa1 ? 0x62 : 0x40)); + return 2; + } + } else { + /* 0x81 <= c < 0xa1. */ + /* User-defined characters */ + *pwc = (c >= 0x8e ? 0xdb18 : 0xeeb8) + 157 * (c - 0x81) + + (c2 - (c2 >= 0xa1 ? 0x62 : 0x40)); + return 2; + } + } + } + if (c == 0xf9) { + int ret = cp950ext_mbtowc(conv,pwc,s,2); + if (ret != RET_ILSEQ) + return ret; + } + } + return RET_ILSEQ; +} + +static int +cp950_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Code set 0 (ASCII) */ + ret = ascii_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + /* Code set 1 (BIG5 extended) */ + switch (wc >> 8) { + case 0x00: + if (wc == 0x00af) { buf[0] = 0xa1; buf[1] = 0xc2; ret = 2; break; } + if (wc == 0x00a2 || wc == 0x00a3 || wc == 0x00a4) + return RET_ILUNI; + break; + case 0x02: + if (wc == 0x02cd) { buf[0] = 0xa1; buf[1] = 0xc5; ret = 2; break; } + break; + case 0x20: + if (wc == 0x2027) { buf[0] = 0xa1; buf[1] = 0x45; ret = 2; break; } + if (wc == 0x20ac) { buf[0] = 0xa3; buf[1] = 0xe1; ret = 2; break; } + if (wc == 0x2022 || wc == 0x203e) + return RET_ILUNI; + break; + case 0x22: + if (wc == 0x2215) { buf[0] = 0xa2; buf[1] = 0x41; ret = 2; break; } + if (wc == 0x2295) { buf[0] = 0xa1; buf[1] = 0xf2; ret = 2; break; } + if (wc == 0x2299) { buf[0] = 0xa1; buf[1] = 0xf3; ret = 2; break; } + if (wc == 0x223c) + return RET_ILUNI; + break; + case 0x25: + if (wc == 0x2574) { buf[0] = 0xa1; buf[1] = 0x5a; ret = 2; break; } + break; + case 0x26: + if (wc == 0x2609 || wc == 0x2641) + return RET_ILUNI; + break; + case 0xe0: case 0xe1: case 0xe2: case 0xe3: case 0xe4: case 0xe5: + case 0xe6: case 0xe7: case 0xe8: case 0xe9: case 0xea: case 0xeb: + case 0xec: case 0xed: case 0xee: case 0xef: case 0xf0: case 0xf1: + case 0xf2: case 0xf3: case 0xf4: case 0xf5: case 0xf6: + { + /* User-defined characters */ + unsigned int i = wc - 0xe000; + if (i < 5809) { + unsigned int c1 = i / 157; + unsigned int c2 = i % 157; + buf[0] = c1 + (c1 < 5 ? 0xfa : c1 < 24 ? 0x89 : 0x69); + buf[1] = c2 + (c2 < 0x3f ? 0x40 : 0x62); + ret = 2; + break; + } + } + break; + case 0xfe: + if (wc == 0xfe51) { buf[0] = 0xa1; buf[1] = 0x4e; ret = 2; break; } + if (wc == 0xfe68) { buf[0] = 0xa2; buf[1] = 0x42; ret = 2; break; } + break; + case 0xff: + if (wc == 0xff0f) { buf[0] = 0xa1; buf[1] = 0xfe; ret = 2; break; } + if (wc == 0xff3c) { buf[0] = 0xa2; buf[1] = 0x40; ret = 2; break; } + if (wc == 0xff5e) { buf[0] = 0xa1; buf[1] = 0xe3; ret = 2; break; } + if (wc == 0xffe0) { buf[0] = 0xa2; buf[1] = 0x46; ret = 2; break; } + if (wc == 0xffe1) { buf[0] = 0xa2; buf[1] = 0x47; ret = 2; break; } + if (wc == 0xffe3) { buf[0] = 0xa1; buf[1] = 0xc3; ret = 2; break; } + if (wc == 0xffe5) { buf[0] = 0xa2; buf[1] = 0x44; ret = 2; break; } + if (wc == 0xff64) + return RET_ILUNI; + break; + } + if (ret == RET_ILUNI) + ret = big5_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (!((buf[0] == 0xc6 && buf[1] >= 0xa1) || buf[0] == 0xc7)) { + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]; + r[1] = buf[1]; + return 2; + } + } + ret = cp950ext_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]; + r[1] = buf[1]; + return 2; + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/cp950ext.h b/graf2d/win32gdk/gdk/src/iconv/cp950ext.h new file mode 100644 index 0000000000000..2a18d8054545f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/cp950ext.h @@ -0,0 +1,161 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * CP950 extensions + */ + +static const unsigned short cp950ext_2uni_pagef9[157-116] = { + /* 0xf9 */ + 0x7881, 0x92b9, 0x88cf, 0x58bb, + 0x6052, 0x7ca7, 0x5afa, 0x2554, 0x2566, 0x2557, 0x2560, 0x256c, + 0x2563, 0x255a, 0x2569, 0x255d, 0x2552, 0x2564, 0x2555, 0x255e, + 0x256a, 0x2561, 0x2558, 0x2567, 0x255b, 0x2553, 0x2565, 0x2556, + 0x255f, 0x256b, 0x2562, 0x2559, 0x2568, 0x255c, 0x2551, 0x2550, + 0x256d, 0x256e, 0x2570, 0x256f, 0x2593, +}; + +static int +cp950ext_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 == 0xf9)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0xa1 && c2 < 0xff)) { + unsigned int i = 157 * (c1 - 0xa1) + (c2 - (c2 >= 0xa1 ? 0x62 : 0x40)); + unsigned short wc = 0xfffd; + { + if (i >= 13932 && i < 13973) + wc = cp950ext_2uni_pagef9[i-13932]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short cp950ext_2charset[41] = { + 0xf9f9, 0xf9f8, 0xf9e6, 0xf9ef, 0xf9dd, 0xf9e8, 0xf9f1, 0xf9df, + 0xf9ec, 0xf9f5, 0xf9e3, 0xf9ee, 0xf9f7, 0xf9e5, 0xf9e9, 0xf9f2, + 0xf9e0, 0xf9eb, 0xf9f4, 0xf9e2, 0xf9e7, 0xf9f0, 0xf9de, 0xf9ed, + 0xf9f6, 0xf9e4, 0xf9ea, 0xf9f3, 0xf9e1, 0xf9fa, 0xf9fb, 0xf9fd, + 0xf9fc, 0xf9fe, 0xf9d9, 0xf9dc, 0xf9da, 0xf9d6, 0xf9db, 0xf9d8, + 0xf9d7, +}; + +static const Summary16 cp950ext_uni2indx_page25[10] = { + /* 0x2500 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0xffff }, { 16, 0xffff }, { 32, 0x0001 }, + { 33, 0x0000 }, { 33, 0x0008 }, +}; +static const Summary16 cp950ext_uni2indx_page58[12] = { + /* 0x5800 */ + { 34, 0x0000 }, { 34, 0x0000 }, { 34, 0x0000 }, { 34, 0x0000 }, + { 34, 0x0000 }, { 34, 0x0000 }, { 34, 0x0000 }, { 34, 0x0000 }, + { 34, 0x0000 }, { 34, 0x0000 }, { 34, 0x0000 }, { 34, 0x0800 }, +}; +static const Summary16 cp950ext_uni2indx_page5a[16] = { + /* 0x5a00 */ + { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, + { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, + { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, + { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0400 }, +}; +static const Summary16 cp950ext_uni2indx_page60[6] = { + /* 0x6000 */ + { 36, 0x0000 }, { 36, 0x0000 }, { 36, 0x0000 }, { 36, 0x0000 }, + { 36, 0x0000 }, { 36, 0x0004 }, +}; +static const Summary16 cp950ext_uni2indx_page78[9] = { + /* 0x7800 */ + { 37, 0x0000 }, { 37, 0x0000 }, { 37, 0x0000 }, { 37, 0x0000 }, + { 37, 0x0000 }, { 37, 0x0000 }, { 37, 0x0000 }, { 37, 0x0000 }, + { 37, 0x0002 }, +}; +static const Summary16 cp950ext_uni2indx_page7c[11] = { + /* 0x7c00 */ + { 38, 0x0000 }, { 38, 0x0000 }, { 38, 0x0000 }, { 38, 0x0000 }, + { 38, 0x0000 }, { 38, 0x0000 }, { 38, 0x0000 }, { 38, 0x0000 }, + { 38, 0x0000 }, { 38, 0x0000 }, { 38, 0x0080 }, +}; +static const Summary16 cp950ext_uni2indx_page88[13] = { + /* 0x8800 */ + { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, + { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, + { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, + { 39, 0x8000 }, +}; +static const Summary16 cp950ext_uni2indx_page92[12] = { + /* 0x9200 */ + { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0000 }, + { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0000 }, + { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0200 }, +}; + +static int +cp950ext_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc >= 0x2500 && wc < 0x25a0) + summary = &cp950ext_uni2indx_page25[(wc>>4)-0x250]; + else if (wc >= 0x5800 && wc < 0x58c0) + summary = &cp950ext_uni2indx_page58[(wc>>4)-0x580]; + else if (wc >= 0x5a00 && wc < 0x5b00) + summary = &cp950ext_uni2indx_page5a[(wc>>4)-0x5a0]; + else if (wc >= 0x6000 && wc < 0x6060) + summary = &cp950ext_uni2indx_page60[(wc>>4)-0x600]; + else if (wc >= 0x7800 && wc < 0x7890) + summary = &cp950ext_uni2indx_page78[(wc>>4)-0x780]; + else if (wc >= 0x7c00 && wc < 0x7cb0) + summary = &cp950ext_uni2indx_page7c[(wc>>4)-0x7c0]; + else if (wc >= 0x8800 && wc < 0x88d0) + summary = &cp950ext_uni2indx_page88[(wc>>4)-0x880]; + else if (wc >= 0x9200 && wc < 0x92c0) + summary = &cp950ext_uni2indx_page92[(wc>>4)-0x920]; + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = cp950ext_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/dec_hanyu.h b/graf2d/win32gdk/gdk/src/iconv/dec_hanyu.h new file mode 100644 index 0000000000000..065fd5d5158eb --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/dec_hanyu.h @@ -0,0 +1,115 @@ +/* + * Copyright (C) 2001, 2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * DEC-HANYU + */ + +static int +dec_hanyu_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + /* Code set 0 (ASCII) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (CNS 11643-1992 Plane 1), + Code set 2 (CNS 11643-1992 Plane 2), + Code set 3 (CNS 11643-1992 Plane 3) */ + if (c >= 0xa1 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c == 0xc2 && c2 == 0xcb) { + if (n < 4) + return RET_TOOFEW(0); + if (s[2] >= 0xa1 && s[2] < 0xff && s[3] >= 0xa1 && s[3] < 0xff) { + unsigned char buf[2]; + int ret; + buf[0] = s[2]-0x80; buf[1] = s[3]-0x80; + ret = cns11643_3_mbtowc(conv,pwc,buf,2); + if (ret != RET_ILSEQ) { + if (ret != 2) abort(); + return 4; + } + } + } else if (c2 >= 0xa1 && c2 < 0xff) { + if (c != 0xc2 || c2 < 0xc2) { + unsigned char buf[2]; + buf[0] = c-0x80; buf[1] = c2-0x80; + return cns11643_1_mbtowc(conv,pwc,buf,2); + } + } else if (c2 >= 0x21 && c2 < 0x7f) { + unsigned char buf[2]; + buf[0] = c-0x80; buf[1] = c2; + return cns11643_2_mbtowc(conv,pwc,buf,2); + } + } + } + return RET_ILSEQ; +} + +static int +dec_hanyu_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[3]; + int ret; + + /* Code set 0 (ASCII) */ + ret = ascii_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + ret = cns11643_wctomb(conv,buf,wc,3); + if (ret != RET_ILUNI) { + if (ret != 3) abort(); + + /* Code set 1 (CNS 11643-1992 Plane 1) */ + if (buf[0] == 1 && (buf[1] != 0x42 || buf[2] < 0x42)) { + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[1]+0x80; + r[1] = buf[2]+0x80; + return 2; + } + + /* Code set 2 (CNS 11643-1992 Plane 2) */ + if (buf[0] == 2) { + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[1]+0x80; + r[1] = buf[2]; + return 2; + } + + /* Code set 3 (CNS 11643-1992 Plane 3) */ + if (buf[0] == 3) { + if (n < 4) + return RET_TOOSMALL; + r[0] = 0xc2; + r[1] = 0xcb; + r[2] = buf[1]+0x80; + r[3] = buf[2]+0x80; + return 4; + } + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/dec_kanji.h b/graf2d/win32gdk/gdk/src/iconv/dec_kanji.h new file mode 100644 index 0000000000000..0a056fb87ed14 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/dec_kanji.h @@ -0,0 +1,71 @@ +/* + * Copyright (C) 2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * DEC-KANJI + */ + +static int +dec_kanji_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + /* Code set 0 (ASCII or JIS X 0201-1976 Roman) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (JIS X 0208) */ + if (c >= 0xa1 && c < 0xf5) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 < 0xff) { + unsigned char buf[2]; + buf[0] = c-0x80; buf[1] = c2-0x80; + return jisx0208_mbtowc(conv,pwc,buf,2); + } + } + } + return RET_ILSEQ; +} + +static int +dec_kanji_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Code set 0 (ASCII or JIS X 0201-1976 Roman) */ + ret = ascii_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + /* Code set 1 (JIS X 0208) */ + ret = jisx0208_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]+0x80; + r[1] = buf[1]+0x80; + return 2; + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/encodings.def b/graf2d/win32gdk/gdk/src/iconv/encodings.def new file mode 100644 index 0000000000000..b5fda5480f06f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/encodings.def @@ -0,0 +1,1025 @@ +/* Copyright (C) 1999-2009 Free Software Foundation, Inc. + This file is part of the GNU LIBICONV Library. + + The GNU LIBICONV Library is free software; you can redistribute it + and/or modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either version 2 + of the License, or (at your option) any later version. + + The GNU LIBICONV Library is distributed in the hope that it will be + useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with the GNU LIBICONV Library; see the file COPYING.LIB. + If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + Fifth Floor, Boston, MA 02110-1301, USA. */ + +/* The list of all system independent user-visible encodings. */ + +/* By convention, an encoding named FOOBAR or FOO_BAR or FOO-BAR is defined + in a file named "foobar.h" through the functions foobar_mbtowc and + foobar_wctomb (and possibly foobar_reset). */ + +/* DEFENCODING(( name, alias1, ..., ), + xxx, + { xxx_mbtowc, xxx_flushwc }, + { xxx_wctomb, xxx_reset }) + defines an encoding with the given name and aliases. (There is no + difference between a name and an alias. By convention, the name is chosen + as the preferred MIME name or the standard name.) + All names and aliases must be in ASCII. Case is not significant, but + for the "cs*" aliases mixed case is preferred, otherwise UPPERCASE is + preferred. For all names and aliases, note where it comes from. + xxx is the name as used in the C code (lowercase). + */ + + +DEFENCODING(( "US-ASCII", /* IANA */ + "ASCII", /* IANA, JDK 1.1 */ + "ISO646-US", /* IANA */ + "ISO_646.IRV:1991", /* IANA */ + "ISO-IR-6", /* IANA */ + "ANSI_X3.4-1968", /* IANA */ + "ANSI_X3.4-1986", /* IANA */ + "CP367", /* IANA */ + "IBM367", /* IANA */ + "US", /* IANA */ + "csASCII", /* IANA */ + /*"ISO646.1991-IRV", X11R6.4 */ + ), + ascii, + { ascii_mbtowc, NULL }, { ascii_wctomb, NULL }) +#ifdef USE_SOLARIS_ALIASES +DEFALIAS( "646", /* Solaris */ + ascii) +#endif + +/* General multi-byte encodings */ + +DEFENCODING(( "UTF-8", /* IANA, RFC 2279 */ + /*"UTF8", JDK 1.1 */ + /*"CP65001", Windows */ + ), + utf8, + { utf8_mbtowc, NULL }, { utf8_wctomb, NULL }) +#ifdef USE_HPUX_ALIASES +DEFALIAS( "UTF8", /* HP-UX */ + utf8) +#endif + +DEFENCODING(( "UCS-2", /* glibc */ + "ISO-10646-UCS-2", /* IANA */ + "csUnicode", /* IANA */ + ), + ucs2, + { ucs2_mbtowc, NULL }, { ucs2_wctomb, NULL }) + +DEFENCODING(( "UCS-2BE", /* glibc */ + "UNICODEBIG", /* glibc */ + "UNICODE-1-1", /* IANA */ + "csUnicode11", /* IANA */ + /*"CP1201", Windows */ + ), + ucs2be, + { ucs2be_mbtowc, NULL }, { ucs2be_wctomb, NULL }) + +DEFENCODING(( "UCS-2LE", /* glibc */ + "UNICODELITTLE", /* glibc */ + /*"CP1200", Windows */ + ), + ucs2le, + { ucs2le_mbtowc, NULL }, { ucs2le_wctomb, NULL }) + +DEFENCODING(( "UCS-4", /* glibc */ + "ISO-10646-UCS-4", /* IANA */ + "csUCS4", /* IANA */ + ), + ucs4, + { ucs4_mbtowc, NULL }, { ucs4_wctomb, NULL }) + +DEFENCODING(( "UCS-4BE", /* glibc */ + /*"CP12001", Windows */ + ), + ucs4be, + { ucs4be_mbtowc, NULL }, { ucs4be_wctomb, NULL }) + +DEFENCODING(( "UCS-4LE", /* glibc */ + /*"CP12000", Windows */ + ), + ucs4le, + { ucs4le_mbtowc, NULL }, { ucs4le_wctomb, NULL }) + +DEFENCODING(( "UTF-16", /* IANA, RFC 2781 */ + ), + utf16, + { utf16_mbtowc, NULL }, { utf16_wctomb, NULL }) + +DEFENCODING(( "UTF-16BE", /* IANA, RFC 2781 */ + ), + utf16be, + { utf16be_mbtowc, NULL }, { utf16be_wctomb, NULL }) + +DEFENCODING(( "UTF-16LE", /* IANA, RFC 2781 */ + ), + utf16le, + { utf16le_mbtowc, NULL }, { utf16le_wctomb, NULL }) + +DEFENCODING(( "UTF-32", /* IANA, Unicode 3.1 */ + ), + utf32, + { utf32_mbtowc, NULL }, { utf32_wctomb, NULL }) + +DEFENCODING(( "UTF-32BE", /* IANA, Unicode 3.1 */ + ), + utf32be, + { utf32be_mbtowc, NULL }, { utf32be_wctomb, NULL }) + +DEFENCODING(( "UTF-32LE", /* IANA, Unicode 3.1 */ + ), + utf32le, + { utf32le_mbtowc, NULL }, { utf32le_wctomb, NULL }) + +DEFENCODING(( "UTF-7", /* IANA, RFC 2152 */ + "UNICODE-1-1-UTF-7", /* IANA, RFC 1642 */ + "csUnicode11UTF7", /* IANA */ + /*"CP65000", Windows */ + ), + utf7, + { utf7_mbtowc, NULL }, { utf7_wctomb, utf7_reset }) + +DEFENCODING(( "UCS-2-INTERNAL", /* libiconv */ + ), + ucs2internal, + { ucs2internal_mbtowc, NULL }, { ucs2internal_wctomb, NULL }) + +DEFENCODING(( "UCS-2-SWAPPED", /* libiconv */ + ), + ucs2swapped, + { ucs2swapped_mbtowc, NULL }, { ucs2swapped_wctomb, NULL }) + +DEFENCODING(( "UCS-4-INTERNAL", /* libiconv */ + ), + ucs4internal, + { ucs4internal_mbtowc, NULL },{ ucs4internal_wctomb, NULL }) + +DEFENCODING(( "UCS-4-SWAPPED", /* libiconv */ + ), + ucs4swapped, + { ucs4swapped_mbtowc, NULL }, { ucs4swapped_wctomb, NULL }) + +DEFENCODING(( "C99", + ), + c99, + { c99_mbtowc, NULL }, { c99_wctomb, NULL }) + +DEFENCODING(( "JAVA", + ), + java, + { java_mbtowc, NULL }, { java_wctomb, NULL }) + +/* Standard 8-bit encodings */ + +DEFENCODING(( "ISO-8859-1", /* IANA */ + "ISO_8859-1", /* IANA */ + "ISO_8859-1:1987", /* IANA */ + "ISO-IR-100", /* IANA */ + "CP819", /* IANA */ + "IBM819", /* IANA */ + "LATIN1", /* IANA */ + "L1", /* IANA */ + "csISOLatin1", /* IANA */ + "ISO8859-1", /* X11R6.4, glibc, FreeBSD, AIX, IRIX, OSF/1, Solaris */ + /*"ISO8859_1", JDK 1.1 */ + /*"CP28591", Windows */ + ), + iso8859_1, + { iso8859_1_mbtowc, NULL }, { iso8859_1_wctomb, NULL }) +#ifdef USE_HPUX_ALIASES +DEFALIAS( "ISO88591", /* HP-UX */ + iso8859_1) +#endif + +DEFENCODING(( "ISO-8859-2", /* IANA */ + "ISO_8859-2", /* IANA */ + "ISO_8859-2:1987", /* IANA */ + "ISO-IR-101", /* IANA */ + "LATIN2", /* IANA */ + "L2", /* IANA */ + "csISOLatin2", /* IANA */ + "ISO8859-2", /* X11R6.4, glibc, FreeBSD, AIX, IRIX, OSF/1, Solaris */ + /*"ISO8859_2", JDK 1.1 */ + /*"CP28592", Windows */ + ), + iso8859_2, + { iso8859_2_mbtowc, NULL }, { iso8859_2_wctomb, NULL }) +#ifdef USE_HPUX_ALIASES +DEFALIAS( "ISO88592", /* HP-UX */ + iso8859_2) +#endif + +DEFENCODING(( "ISO-8859-3", /* IANA */ + "ISO_8859-3", /* IANA */ + "ISO_8859-3:1988", /* IANA */ + "ISO-IR-109", /* IANA */ + "LATIN3", /* IANA */ + "L3", /* IANA */ + "csISOLatin3", /* IANA */ + "ISO8859-3", /* X11R6.4, glibc, FreeBSD, Solaris */ + /*"ISO8859_3", JDK 1.1 */ + /*"CP28593", Windows */ + ), + iso8859_3, + { iso8859_3_mbtowc, NULL }, { iso8859_3_wctomb, NULL }) + +DEFENCODING(( "ISO-8859-4", /* IANA */ + "ISO_8859-4", /* IANA */ + "ISO_8859-4:1988", /* IANA */ + "ISO-IR-110", /* IANA */ + "LATIN4", /* IANA */ + "L4", /* IANA */ + "csISOLatin4", /* IANA */ + "ISO8859-4", /* X11R6.4, glibc, FreeBSD, OSF/1, Solaris */ + /*"ISO8859_4", JDK 1.1 */ + /*"CP28594", Windows */ + ), + iso8859_4, + { iso8859_4_mbtowc, NULL }, { iso8859_4_wctomb, NULL }) + +DEFENCODING(( "ISO-8859-5", /* IANA */ + "ISO_8859-5", /* IANA */ + "ISO_8859-5:1988", /* IANA */ + "ISO-IR-144", /* IANA */ + "CYRILLIC", /* IANA */ + "csISOLatinCyrillic", /* IANA */ + "ISO8859-5", /* X11R6.4, glibc, FreeBSD, AIX, IRIX, OSF/1, Solaris */ + /*"ISO8859_5", JDK 1.1 */ + /*"CP28595", Windows */ + ), + iso8859_5, + { iso8859_5_mbtowc, NULL }, { iso8859_5_wctomb, NULL }) +#ifdef USE_HPUX_ALIASES +DEFALIAS( "ISO88595", /* HP-UX */ + iso8859_5) +#endif + +DEFENCODING(( "ISO-8859-6", /* IANA */ + "ISO_8859-6", /* IANA */ + "ISO_8859-6:1987", /* IANA */ + "ISO-IR-127", /* IANA */ + "ECMA-114", /* IANA */ + "ASMO-708", /* IANA */ + "ARABIC", /* IANA */ + "csISOLatinArabic", /* IANA */ + "ISO8859-6", /* X11R6.4, glibc, FreeBSD, AIX, Solaris */ + /*"ISO8859_6", JDK 1.1 */ + /*"CP28596", Windows */ + ), + iso8859_6, + { iso8859_6_mbtowc, NULL }, { iso8859_6_wctomb, NULL }) +#ifdef USE_HPUX_ALIASES +DEFALIAS( "ISO88596", /* HP-UX */ + iso8859_6) +#endif + +DEFENCODING(( "ISO-8859-7", /* IANA, RFC 1947 */ + "ISO_8859-7", /* IANA */ + "ISO_8859-7:1987", /* IANA */ + "ISO_8859-7:2003", + "ISO-IR-126", /* IANA */ + "ECMA-118", /* IANA */ + "ELOT_928", /* IANA */ + "GREEK8", /* IANA */ + "GREEK", /* IANA */ + "csISOLatinGreek", /* IANA */ + "ISO8859-7", /* X11R6.4, glibc, FreeBSD, AIX, IRIX, OSF/1, Solaris */ + /*"ISO8859_7", JDK 1.1 */ + /*"CP28597", Windows */ + ), + iso8859_7, + { iso8859_7_mbtowc, NULL }, { iso8859_7_wctomb, NULL }) +#ifdef USE_HPUX_ALIASES +DEFALIAS( "ISO88597", /* HP-UX */ + iso8859_7) +#endif + +DEFENCODING(( "ISO-8859-8", /* IANA */ + "ISO_8859-8", /* IANA */ + "ISO_8859-8:1988", /* IANA */ + "ISO-IR-138", /* IANA */ + "HEBREW", /* IANA */ + "csISOLatinHebrew", /* IANA */ + "ISO8859-8", /* X11R6.4, glibc, FreeBSD, AIX, OSF/1, Solaris */ + /*"ISO8859_8", JDK 1.1 */ + /*"CP28598", Windows */ + /*"CP38598", Windows */ + ), + iso8859_8, + { iso8859_8_mbtowc, NULL }, { iso8859_8_wctomb, NULL }) +#ifdef USE_HPUX_ALIASES +DEFALIAS( "ISO88598", /* HP-UX */ + iso8859_8) +#endif + +DEFENCODING(( "ISO-8859-9", /* IANA */ + "ISO_8859-9", /* IANA */ + "ISO_8859-9:1989", /* IANA */ + "ISO-IR-148", /* IANA */ + "LATIN5", /* IANA */ + "L5", /* IANA */ + "csISOLatin5", /* IANA */ + "ISO8859-9", /* X11R6.4, glibc, FreeBSD, AIX, IRIX, OSF/1, Solaris */ + /*"ISO8859_9", JDK 1.1 */ + /*"CP28599", Windows */ + ), + iso8859_9, + { iso8859_9_mbtowc, NULL }, { iso8859_9_wctomb, NULL }) +#ifdef USE_HPUX_ALIASES +DEFALIAS( "ISO88599", /* HP-UX */ + iso8859_9) +#endif + +DEFENCODING(( "ISO-8859-10", /* IANA */ + "ISO_8859-10", + "ISO_8859-10:1992", /* IANA */ + "ISO-IR-157", /* IANA */ + "LATIN6", /* IANA */ + "L6", /* IANA */ + "csISOLatin6", /* IANA */ + "ISO8859-10", /* X11R6.4, glibc, FreeBSD */ + ), + iso8859_10, + { iso8859_10_mbtowc, NULL }, { iso8859_10_wctomb, NULL }) + +DEFENCODING(( "ISO-8859-11", /* glibc */ + "ISO_8859-11", + "ISO8859-11", /* X11R6.7, glibc */ + ), + iso8859_11, + { iso8859_11_mbtowc, NULL }, { iso8859_11_wctomb, NULL }) + +DEFENCODING(( "ISO-8859-13", /* IANA, glibc */ + "ISO_8859-13", + "ISO-IR-179", /* glibc */ + "LATIN7", /* glibc */ + "L7", /* glibc */ + "ISO8859-13", /* glibc, FreeBSD */ + ), + iso8859_13, + { iso8859_13_mbtowc, NULL }, { iso8859_13_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-921", /* AIX */ + iso8859_13) +#endif + +DEFENCODING(( "ISO-8859-14", /* IANA, glibc */ + "ISO_8859-14", /* IANA */ + "ISO_8859-14:1998", /* IANA, glibc */ + "ISO-IR-199", /* IANA */ + "LATIN8", /* IANA, glibc */ + "L8", /* IANA, glibc */ + "ISO-CELTIC", /* IANA */ + "ISO8859-14", /* glibc, FreeBSD */ + ), + iso8859_14, + { iso8859_14_mbtowc, NULL }, { iso8859_14_wctomb, NULL }) + +DEFENCODING(( "ISO-8859-15", /* IANA, glibc */ + "ISO_8859-15", /* IANA */ + "ISO_8859-15:1998", /* glibc */ + "ISO-IR-203", + "LATIN-9", /* IANA */ + "ISO8859-15", /* glibc, FreeBSD, AIX, OSF/1, Solaris */ + /*"CP28605", Windows */ + ), + iso8859_15, + { iso8859_15_mbtowc, NULL }, { iso8859_15_wctomb, NULL }) +#ifdef USE_HPUX_ALIASES +DEFALIAS( "ISO885915", /* HP-UX */ + iso8859_15) +#endif + +DEFENCODING(( "ISO-8859-16", /* IANA */ + "ISO_8859-16", /* IANA */ + "ISO_8859-16:2001", /* IANA */ + "ISO-IR-226", /* IANA */ + "LATIN10", /* IANA */ + "L10", /* IANA */ + "ISO8859-16", /* glibc, FreeBSD */ + ), + iso8859_16, + { iso8859_16_mbtowc, NULL }, { iso8859_16_wctomb, NULL }) + +DEFENCODING(( "KOI8-R", /* IANA, RFC 1489, X11R6.4, JDK 1.1 */ + "csKOI8R", /* IANA */ + /*"CP20866", Windows */ + ), + koi8_r, + { koi8_r_mbtowc, NULL }, { koi8_r_wctomb, NULL }) + +DEFENCODING(( "KOI8-U", /* IANA, RFC 2319 */ + ), + koi8_u, + { koi8_u_mbtowc, NULL }, { koi8_u_wctomb, NULL }) + +DEFENCODING(( "KOI8-RU", + ), + koi8_ru, + { koi8_ru_mbtowc, NULL }, { koi8_ru_wctomb, NULL }) + +/* Windows 8-bit encodings */ + +DEFENCODING(( "CP1250", /* JDK 1.1 */ + "WINDOWS-1250", /* IANA */ + "MS-EE", + ), + cp1250, + { cp1250_mbtowc, NULL }, { cp1250_wctomb, NULL }) + +DEFENCODING(( "CP1251", /* JDK 1.1 */ + "WINDOWS-1251", /* IANA */ + "MS-CYRL", + ), + cp1251, + { cp1251_mbtowc, NULL }, { cp1251_wctomb, NULL }) +#ifdef USE_SOLARIS_ALIASES +DEFALIAS( "ANSI-1251", /* Solaris */ + cp1251) +#endif + +DEFENCODING(( "CP1252", /* JDK 1.1 */ + "WINDOWS-1252", /* IANA */ + "MS-ANSI", + ), + cp1252, + { cp1252_mbtowc, NULL }, { cp1252_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-1252", /* AIX */ + cp1252) +#endif + +DEFENCODING(( "CP1253", /* JDK 1.1 */ + "WINDOWS-1253", /* IANA */ + "MS-GREEK", + ), + cp1253, + { cp1253_mbtowc, NULL }, { cp1253_wctomb, NULL }) + +DEFENCODING(( "CP1254", /* JDK 1.1 */ + "WINDOWS-1254", /* IANA */ + "MS-TURK", + ), + cp1254, + { cp1254_mbtowc, NULL }, { cp1254_wctomb, NULL }) + +DEFENCODING(( "CP1255", /* JDK 1.1 */ + "WINDOWS-1255", /* IANA */ + "MS-HEBR", + ), + cp1255, + { cp1255_mbtowc, cp1255_flushwc }, { cp1255_wctomb, NULL }) + +DEFENCODING(( "CP1256", /* JDK 1.1 */ + "WINDOWS-1256", /* IANA */ + "MS-ARAB", + ), + cp1256, + { cp1256_mbtowc, NULL }, { cp1256_wctomb, NULL }) + +DEFENCODING(( "CP1257", /* JDK 1.1 */ + "WINDOWS-1257", /* IANA */ + "WINBALTRIM", + ), + cp1257, + { cp1257_mbtowc, NULL }, { cp1257_wctomb, NULL }) + +DEFENCODING(( "CP1258", /* JDK 1.1 */ + "WINDOWS-1258", /* IANA */ + ), + cp1258, + { cp1258_mbtowc, cp1258_flushwc }, { cp1258_wctomb, NULL }) + +/* DOS 8-bit encodings */ + +DEFENCODING(( "CP850", /* IANA, JDK 1.1 */ + "IBM850", /* IANA */ + "850", /* IANA */ + "csPC850Multilingual", /* IANA */ + ), + cp850, + { cp850_mbtowc, NULL }, { cp850_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-850", /* AIX */ + cp850) +#endif + +DEFENCODING(( "CP862", /* IANA, JDK 1.1 */ + "IBM862", /* IANA */ + "862", /* IANA */ + "csPC862LatinHebrew", /* IANA */ + ), + cp862, + { cp862_mbtowc, NULL }, { cp862_wctomb, NULL }) + +DEFENCODING(( "CP866", /* IANA, JDK 1.1 */ + "IBM866", /* IANA */ + "866", /* IANA */ + "csIBM866", /* IANA */ + ), + cp866, + { cp866_mbtowc, NULL }, { cp866_wctomb, NULL }) + +DEFENCODING(( "CP1131", /* FreeBSD, MacOS X */ + ), + cp1131, + { cp1131_mbtowc, NULL }, { cp1131_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-1131", /* AIX */ + cp1131) +#endif + +/* Macintosh 8-bit encodings */ + +DEFENCODING(( "MacRoman", /* JDK 1.1 */ + /* This is the best table for MACINTOSH. The ones */ + /* in glibc and FreeBSD-iconv are bad quality. */ + "MACINTOSH", /* IANA */ + "MAC", /* IANA */ + "csMacintosh", /* IANA */ + /*"CP10000", Windows */ + ), + mac_roman, + { mac_roman_mbtowc, NULL }, { mac_roman_wctomb, NULL }) + +DEFENCODING(( "MacCentralEurope", /* JDK 1.1 */ + /*"CP10029", Windows */ + ), + mac_centraleurope, + { mac_centraleurope_mbtowc, NULL }, { mac_centraleurope_wctomb, NULL }) + +DEFENCODING(( "MacIceland", /* JDK 1.1 */ + /*"CP10079", Windows */ + ), + mac_iceland, + { mac_iceland_mbtowc, NULL }, { mac_iceland_wctomb, NULL }) + +DEFENCODING(( "MacCroatian", /* JDK 1.1 */ + /*"CP10082", Windows */ + ), + mac_croatian, + { mac_croatian_mbtowc, NULL }, { mac_croatian_wctomb, NULL }) + +DEFENCODING(( "MacRomania", /* JDK 1.1 */ + /*"CP10010", Windows */ + ), + mac_romania, + { mac_romania_mbtowc, NULL }, { mac_romania_wctomb, NULL }) + +DEFENCODING(( "MacCyrillic", /* JDK 1.1 */ + /*"CP10007", Windows */ + ), + mac_cyrillic, + { mac_cyrillic_mbtowc, NULL }, { mac_cyrillic_wctomb, NULL }) + +DEFENCODING(( "MacUkraine", /* JDK 1.1 */ + /*"CP10017", Windows */ + ), + mac_ukraine, + { mac_ukraine_mbtowc, NULL }, { mac_ukraine_wctomb, NULL }) + +DEFENCODING(( "MacGreek", /* JDK 1.1 */ + /*"CP10006", Windows */ + ), + mac_greek, + { mac_greek_mbtowc, NULL }, { mac_greek_wctomb, NULL }) + +DEFENCODING(( "MacTurkish", /* JDK 1.1 */ + /*"CP10081", Windows */ + ), + mac_turkish, + { mac_turkish_mbtowc, NULL }, { mac_turkish_wctomb, NULL }) + +DEFENCODING(( "MacHebrew", /* JDK 1.1 */ + /*"CP10005", Windows */ + ), + mac_hebrew, + { mac_hebrew_mbtowc, NULL }, { mac_hebrew_wctomb, NULL }) + +DEFENCODING(( "MacArabic", /* JDK 1.1 */ + /*"CP10004", Windows */ + ), + mac_arabic, + { mac_arabic_mbtowc, NULL }, { mac_arabic_wctomb, NULL }) + +DEFENCODING(( "MacThai", /* JDK 1.1 */ + /*"CP10021", Windows */ + ), + mac_thai, + { mac_thai_mbtowc, NULL }, { mac_thai_wctomb, NULL }) + +/* Other platform specific 8-bit encodings */ + +DEFENCODING(( "HP-ROMAN8", /* IANA, X11R6.4 */ + "ROMAN8", /* IANA */ + "R8", /* IANA */ + "csHPRoman8", /* IANA */ + ), + hp_roman8, + { hp_roman8_mbtowc, NULL }, { hp_roman8_wctomb, NULL }) + +DEFENCODING(( "NEXTSTEP", + ), + nextstep, + { nextstep_mbtowc, NULL }, { nextstep_wctomb, NULL }) + +/* Regional 8-bit encodings used for a single language */ + +DEFENCODING(( "ARMSCII-8", + ), + armscii_8, + { armscii_8_mbtowc, NULL }, { armscii_8_wctomb, NULL }) + +DEFENCODING(( "GEORGIAN-ACADEMY", + ), + georgian_academy, + { georgian_academy_mbtowc, NULL }, { georgian_academy_wctomb, NULL }) + +DEFENCODING(( "GEORGIAN-PS", + ), + georgian_ps, + { georgian_ps_mbtowc, NULL }, { georgian_ps_wctomb, NULL }) + +DEFENCODING(( "KOI8-T", + ), + koi8_t, + { koi8_t_mbtowc, NULL }, { koi8_t_wctomb, NULL }) + +DEFENCODING(( "PT154", /* IANA, glibc */ + "PTCP154", /* IANA */ + "CP154", /* IANA */ + "CYRILLIC-ASIAN", /* IANA */ + "csPTCP154", /* IANA */ + ), + pt154, + { pt154_mbtowc, NULL }, { pt154_wctomb, NULL }) + +DEFENCODING(( "RK1048", /* IANA, glibc */ + "STRK1048-2002", /* IANA */ + "KZ-1048", /* IANA */ + "csKZ1048", /* IANA */ + ), + rk1048, + { rk1048_mbtowc, NULL }, { rk1048_wctomb, NULL }) + +DEFENCODING(( "MULELAO-1", + ), + mulelao, + { mulelao_mbtowc, NULL }, { mulelao_wctomb, NULL }) + +DEFENCODING(( "CP1133", + "IBM-CP1133", + ), + cp1133, + { cp1133_mbtowc, NULL }, { cp1133_wctomb, NULL }) + +DEFENCODING(( "TIS-620", /* IANA */ + "TIS620", /* glibc, HP-UX */ + "TIS620-0", /* glibc */ + "TIS620.2529-1", /* glibc */ + "TIS620.2533-0", /* glibc */ + "TIS620.2533-1", + "ISO-IR-166", /* glibc */ + ), + tis620, + { tis620_mbtowc, NULL }, { tis620_wctomb, NULL }) +#ifdef USE_OSF1_ALIASES +DEFALIAS( "TACTIS", /* OSF/1 */ + tis620) +#endif +#ifdef USE_SOLARIS_ALIASES +DEFALIAS( "TIS620.2533", /* Solaris */ + tis620) +#endif + +DEFENCODING(( "CP874", /* JDK 1.1 */ + "WINDOWS-874", + ), + cp874, + { cp874_mbtowc, NULL }, { cp874_wctomb, NULL }) + +DEFENCODING(( "VISCII", /* IANA, RFC 1456 */ + "VISCII1.1-1", + "csVISCII", /* IANA */ + ), + viscii, + { viscii_mbtowc, NULL }, { viscii_wctomb, NULL }) + +DEFENCODING(( "TCVN", + "TCVN-5712", + "TCVN5712-1", + "TCVN5712-1:1993", + ), + tcvn, + { tcvn_mbtowc, tcvn_flushwc }, { tcvn_wctomb, NULL }) + +/* CJK character sets (not documented) */ + +DEFENCODING(( "JIS_C6220-1969-RO", /* IANA */ + "ISO646-JP", /* IANA */ + "ISO-IR-14", /* IANA */ + "JP", /* IANA */ + "csISO14JISC6220ro", /* IANA */ + ), + iso646_jp, + { iso646_jp_mbtowc, NULL }, { iso646_jp_wctomb, NULL }) + +DEFENCODING(( "JIS_X0201", /* IANA */ + "JISX0201-1976", + "X0201", /* IANA */ + "csHalfWidthKatakana", /* IANA */ + /*"JISX0201.1976-0", X11R6.4 */ + /*"JIS0201", JDK 1.1 */ + ), + jisx0201, + { jisx0201_mbtowc, NULL }, { jisx0201_wctomb, NULL }) + +DEFENCODING(( "JIS_X0208", + "JIS_X0208-1983", /* IANA */ + "JIS_X0208-1990", + "JIS0208", + "X0208", /* IANA */ + "ISO-IR-87", /* IANA */ + "JIS_C6226-1983", /* IANA */ + "csISO87JISX0208", /* IANA */ + /*"JISX0208.1983-0", X11R6.4 */ + /*"JISX0208.1990-0", X11R6.4 */ + /*"JIS0208", JDK 1.1 */ + ), + jisx0208, + { jisx0208_mbtowc, NULL }, { jisx0208_wctomb, NULL }) + +DEFENCODING(( "JIS_X0212", + "JIS_X0212.1990-0", + "JIS_X0212-1990", /* IANA */ + "X0212", /* IANA */ + "ISO-IR-159", /* IANA */ + "csISO159JISX02121990", /* IANA */ + /*"JISX0212.1990-0", X11R6.4 */ + /*"JIS0212", JDK 1.1 */ + ), + jisx0212, + { jisx0212_mbtowc, NULL }, { jisx0212_wctomb, NULL }) + +DEFENCODING(( "GB_1988-80", /* IANA */ + "ISO646-CN", /* IANA */ + "ISO-IR-57", /* IANA */ + "CN", /* IANA */ + "csISO57GB1988", /* IANA */ + ), + iso646_cn, + { iso646_cn_mbtowc, NULL }, { iso646_cn_wctomb, NULL }) + +DEFENCODING(( "GB_2312-80", /* IANA */ + "ISO-IR-58", /* IANA */ + "csISO58GB231280", /* IANA */ + "CHINESE", /* IANA */ + /*"GB2312.1980-0", X11R6.4 */ + ), + gb2312, + { gb2312_mbtowc, NULL }, { gb2312_wctomb, NULL }) + +DEFENCODING(( "ISO-IR-165", + "CN-GB-ISOIR165", /* RFC 1922 */ + ), + isoir165, + { isoir165_mbtowc, NULL }, { isoir165_wctomb, NULL }) + +DEFENCODING(( "KSC_5601", /* IANA */ + "KS_C_5601-1987", /* IANA */ + "KS_C_5601-1989", /* IANA */ + "ISO-IR-149", /* IANA */ + "csKSC56011987", /* IANA */ + "KOREAN", /* IANA */ + /*"KSC5601.1987-0", X11R6.4 */ + /*"KSX1001:1992", Ken Lunde */ + ), + ksc5601, + { ksc5601_mbtowc, NULL }, { ksc5601_wctomb, NULL }) + +/* CJK encodings */ + +DEFENCODING(( "EUC-JP", /* IANA */ + "EUCJP", /* glibc, HP-UX, IRIX, OSF/1, Solaris */ + "Extended_UNIX_Code_Packed_Format_for_Japanese", /* IANA */ + "csEUCPkdFmtJapanese", /* IANA */ + /*"EUC_JP", JDK 1.1 */ + /*"CP51932", Windows */ + ), + euc_jp, + { euc_jp_mbtowc, NULL }, { euc_jp_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-EUCJP", /* AIX */ + euc_jp) +#endif +#ifdef USE_OSF1_ALIASES +DEFALIAS( "SDECKANJI", /* OSF/1 */ + euc_jp) +#endif + +DEFENCODING(( "SHIFT_JIS", /* IANA */ + "SHIFT-JIS", /* glibc */ + "SJIS", /* JDK 1.1, HP-UX, OSF/1 */ + "MS_KANJI", /* IANA */ + "csShiftJIS", /* IANA */ + ), + sjis, + { sjis_mbtowc, NULL }, { sjis_wctomb, NULL }) +#ifdef USE_SOLARIS_ALIASES +DEFALIAS( "PCK", /* Solaris */ + sjis) +#endif + +DEFENCODING(( "CP932", /* glibc */ + ), + cp932, + { cp932_mbtowc, NULL }, { cp932_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-932", /* AIX */ + cp932) +#endif + +DEFENCODING(( "ISO-2022-JP", /* IANA, RFC 1468 */ + "csISO2022JP", /* IANA */ + /*"ISO2022JP", JDK 1.1 */ + ), + iso2022_jp, + { iso2022_jp_mbtowc, NULL }, { iso2022_jp_wctomb, iso2022_jp_reset }) + +DEFENCODING(( "ISO-2022-JP-1", /* RFC 2237 */ + ), + iso2022_jp1, + { iso2022_jp1_mbtowc, NULL }, { iso2022_jp1_wctomb, iso2022_jp1_reset }) + +DEFENCODING(( "ISO-2022-JP-2", /* IANA, RFC 1554 */ + "csISO2022JP2", /* IANA */ + ), + iso2022_jp2, + { iso2022_jp2_mbtowc, NULL }, { iso2022_jp2_wctomb, iso2022_jp2_reset }) + +DEFENCODING(( "EUC-CN", /* glibc */ + "EUCCN", /* glibc, IRIX */ + "GB2312", /* IANA */ + "CN-GB", /* RFC 1922 */ + "csGB2312", /* IANA */ + /*"EUC_CN", JDK 1.1 */ + /*"CP51936", Windows */ + ), + euc_cn, + { euc_cn_mbtowc, NULL }, { euc_cn_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-EUCCN", /* AIX */ + euc_cn) +#endif +#ifdef USE_HPUX_ALIASES +DEFALIAS( "HP15CN", /* HP-UX */ + euc_cn) +#endif +#ifdef USE_OSF1_ALIASES +DEFALIAS( "DECHANZI", /* OSF/1 */ + euc_cn) +#endif + +DEFENCODING(( "GBK", /* IANA, JDK 1.1 */ + ), + ces_gbk, + { ces_gbk_mbtowc, NULL }, { ces_gbk_wctomb, NULL }) + +DEFENCODING(( "CP936", /* IANA */ + "MS936", /* IANA */ + "WINDOWS-936", /* IANA */ + ), + cp936, + { cp936_mbtowc, NULL }, { cp936_wctomb, NULL }) + +DEFENCODING(( "GB18030", /* IANA, glibc */ + /*"CP54936", Windows */ + ), + gb18030, + { gb18030_mbtowc, NULL }, { gb18030_wctomb, NULL }) + +DEFENCODING(( "ISO-2022-CN", /* IANA, RFC 1922 */ + "csISO2022CN", + /*"ISO2022CN", JDK 1.1 */ + ), + iso2022_cn, + { iso2022_cn_mbtowc, NULL }, { iso2022_cn_wctomb, iso2022_cn_reset }) + +DEFENCODING(( "ISO-2022-CN-EXT", /* IANA, RFC 1922 */ + ), + iso2022_cn_ext, + { iso2022_cn_ext_mbtowc, NULL }, { iso2022_cn_ext_wctomb, iso2022_cn_ext_reset }) + +DEFENCODING(( "HZ", /* RFC 1843 */ + "HZ-GB-2312", /* IANA, RFC 1842 */ + ), + hz, + { hz_mbtowc, NULL }, { hz_wctomb, hz_reset }) + +DEFENCODING(( "EUC-TW", /* glibc */ + "EUCTW", /* glibc, HP-UX, IRIX, OSF/1 */ + "csEUCTW", + /*"EUC_TW", JDK 1.1 */ + /*"CP51950", Windows */ + ), + euc_tw, + { euc_tw_mbtowc, NULL }, { euc_tw_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-EUCTW", /* AIX */ + euc_tw) +#endif +#ifdef USE_SOLARIS_ALIASES +DEFALIAS( "CNS11643", /* Solaris */ + euc_tw) +#endif + +DEFENCODING(( "BIG5", /* IANA, JDK 1.1 */ + "BIG-5", /* glibc */ + "BIG-FIVE", /* glibc */ + "BIGFIVE", /* glibc */ + "CN-BIG5", /* RFC 1922 */ + "csBig5", /* IANA */ + ), + ces_big5, + { ces_big5_mbtowc, NULL }, { ces_big5_wctomb, NULL }) + +DEFENCODING(( "CP950", /* JDK 1.1 */ + ), + cp950, + { cp950_mbtowc, NULL }, { cp950_wctomb, NULL }) + +DEFENCODING(( "BIG5-HKSCS:1999", + ), + big5hkscs1999, + { big5hkscs1999_mbtowc, big5hkscs1999_flushwc }, { big5hkscs1999_wctomb, big5hkscs1999_reset }) + +DEFENCODING(( "BIG5-HKSCS:2001", + ), + big5hkscs2001, + { big5hkscs2001_mbtowc, big5hkscs2001_flushwc }, { big5hkscs2001_wctomb, big5hkscs2001_reset }) + +DEFENCODING(( "BIG5-HKSCS", /* IANA */ + "BIG5HKSCS", /* glibc */ + "BIG5-HKSCS:2004", + ), + big5hkscs2004, + { big5hkscs2004_mbtowc, big5hkscs2004_flushwc }, { big5hkscs2004_wctomb, big5hkscs2004_reset }) + +DEFENCODING(( "EUC-KR", /* IANA, RFC 1557 */ + "EUCKR", /* glibc, HP-UX, IRIX, OSF/1 */ + "csEUCKR", /* IANA */ + /*"EUC_KR", JDK 1.1 */ + /*"CP51949", Windows */ + ), + euc_kr, + { euc_kr_mbtowc, NULL }, { euc_kr_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-EUCKR", /* AIX */ + euc_kr) +#endif +#ifdef USE_OSF1_ALIASES +DEFALIAS( "DECKOREAN", /* OSF/1 */ + euc_kr) +#endif +#ifdef USE_SOLARIS_ALIASES +DEFALIAS( "5601", /* Solaris */ + euc_kr) +#endif + +DEFENCODING(( "CP949", /* JDK 1.1 */ + "UHC", /* glibc */ + ), + cp949, + { cp949_mbtowc, NULL }, { cp949_wctomb, NULL }) +#ifdef USE_OSF1_ALIASES +DEFALIAS( "KSC5601", /* OSF/1 */ + cp949) +#endif + +DEFENCODING(( "JOHAB", /* glibc */ + "CP1361", /* glibc */ + ), + johab, + { johab_mbtowc, NULL }, { johab_wctomb, NULL }) +#ifdef USE_SOLARIS_ALIASES +DEFALIAS( "KO_KR.JOHAP92", /* Solaris */ + johab) +#endif + +DEFENCODING(( "ISO-2022-KR", /* IANA, RFC 1557 */ + "csISO2022KR", /* IANA */ + /*"ISO2022KR", JDK 1.1 */ + ), + iso2022_kr, + { iso2022_kr_mbtowc, NULL }, { iso2022_kr_wctomb, iso2022_kr_reset }) + diff --git a/graf2d/win32gdk/gdk/src/iconv/encodings_aix.def b/graf2d/win32gdk/gdk/src/iconv/encodings_aix.def new file mode 100644 index 0000000000000..259452eb538b4 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/encodings_aix.def @@ -0,0 +1,97 @@ +/* Copyright (C) 2000-2002, 2008 Free Software Foundation, Inc. + This file is part of the GNU LIBICONV Library. + + The GNU LIBICONV Library is free software; you can redistribute it + and/or modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either version 2 + of the License, or (at your option) any later version. + + The GNU LIBICONV Library is distributed in the hope that it will be + useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with the GNU LIBICONV Library; see the file COPYING.LIB. + If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + Fifth Floor, Boston, MA 02110-1301, USA. */ + +/* Encodings used by system dependent locales on AIX. */ + +DEFENCODING(( "CP856", + ), + cp856, + { cp856_mbtowc, NULL }, { cp856_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-856", /* AIX */ + cp856) +#endif + +DEFENCODING(( "CP922", + ), + cp922, + { cp922_mbtowc, NULL }, { cp922_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-922", /* AIX */ + cp922) +#endif + +DEFENCODING(( "CP943", + ), + cp943, + { cp943_mbtowc, NULL }, { cp943_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-943", /* AIX */ + cp943) +#endif + +DEFENCODING(( "CP1046", + ), + cp1046, + { cp1046_mbtowc, NULL }, { cp1046_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-1046", /* AIX */ + cp1046) +#endif + +DEFENCODING(( "CP1124", + ), + cp1124, + { cp1124_mbtowc, NULL }, { cp1124_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-1124", /* AIX */ + cp1124) +#endif + +DEFENCODING(( "CP1129", + ), + cp1129, + { cp1129_mbtowc, NULL }, { cp1129_wctomb, NULL }) +#ifdef USE_AIX_ALIASES +DEFALIAS( "IBM-1129", /* AIX */ + cp1129) +#endif + +DEFENCODING(( "CP1161", + "IBM1161", /* glibc */ + "IBM-1161", /* glibc */ + "csIBM1161", /* glibc */ + ), + cp1161, + { cp1161_mbtowc, NULL }, { cp1161_wctomb, NULL }) + +DEFENCODING(( "CP1162", + "IBM1162", /* glibc */ + "IBM-1162", /* glibc */ + "csIBM1162", /* glibc */ + ), + cp1162, + { cp1162_mbtowc, NULL }, { cp1162_wctomb, NULL }) + +DEFENCODING(( "CP1163", + "IBM1163", /* glibc */ + "IBM-1163", /* glibc */ + "csIBM1163", /* glibc */ + ), + cp1163, + { cp1163_mbtowc, NULL }, { cp1163_wctomb, NULL }) diff --git a/graf2d/win32gdk/gdk/src/iconv/encodings_dos.def b/graf2d/win32gdk/gdk/src/iconv/encodings_dos.def new file mode 100644 index 0000000000000..c9d30c8c0ff4f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/encodings_dos.def @@ -0,0 +1,127 @@ +/* Copyright (C) 2001-2002 Free Software Foundation, Inc. + This file is part of the GNU LIBICONV Library. + + The GNU LIBICONV Library is free software; you can redistribute it + and/or modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either version 2 + of the License, or (at your option) any later version. + + The GNU LIBICONV Library is distributed in the hope that it will be + useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with the GNU LIBICONV Library; see the file COPYING.LIB. + If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + Fifth Floor, Boston, MA 02110-1301, USA. */ + +/* Encodings used by system dependent locales on MSDOS. */ + +DEFENCODING(( "CP437", /* IANA, JDK 1.1 */ + "IBM437", /* IANA */ + "437", /* IANA */ + "csPC8CodePage437", /* IANA */ + ), + cp437, + { cp437_mbtowc, NULL }, { cp437_wctomb, NULL }) + +DEFENCODING(( "CP737", /* JDK 1.1 */ + ), + cp737, + { cp737_mbtowc, NULL }, { cp737_wctomb, NULL }) + +DEFENCODING(( "CP775", /* IANA, JDK 1.1 */ + "IBM775", /* IANA */ + "csPC775Baltic", /* IANA */ + ), + cp775, + { cp775_mbtowc, NULL }, { cp775_wctomb, NULL }) + +DEFENCODING(( "CP852", /* IANA, JDK 1.1 */ + "IBM852", /* IANA */ + "852", /* IANA */ + "csPCp852", /* IANA */ + ), + cp852, + { cp852_mbtowc, NULL }, { cp852_wctomb, NULL }) + +DEFENCODING(( "CP853", + ), + cp853, + { cp853_mbtowc, NULL }, { cp853_wctomb, NULL }) + +DEFENCODING(( "CP855", /* IANA, JDK 1.1 */ + "IBM855", /* IANA */ + "855", /* IANA */ + "csIBM855", /* IANA */ + ), + cp855, + { cp855_mbtowc, NULL }, { cp855_wctomb, NULL }) + +DEFENCODING(( "CP857", /* IANA, JDK 1.1 */ + "IBM857", /* IANA */ + "857", /* IANA */ + "csIBM857", /* IANA */ + ), + cp857, + { cp857_mbtowc, NULL }, { cp857_wctomb, NULL }) + +DEFENCODING(( "CP858", /* JDK 1.1.7 */ + ), + cp858, + { cp858_mbtowc, NULL }, { cp858_wctomb, NULL }) + +DEFENCODING(( "CP860", /* IANA, JDK 1.1 */ + "IBM860", /* IANA */ + "860", /* IANA */ + "csIBM860", /* IANA */ + ), + cp860, + { cp860_mbtowc, NULL }, { cp860_wctomb, NULL }) + +DEFENCODING(( "CP861", /* IANA, JDK 1.1 */ + "IBM861", /* IANA */ + "861", /* IANA */ + "CP-IS", /* IANA */ + "csIBM861", /* IANA */ + ), + cp861, + { cp861_mbtowc, NULL }, { cp861_wctomb, NULL }) + +DEFENCODING(( "CP863", /* IANA, JDK 1.1 */ + "IBM863", /* IANA */ + "863", /* IANA */ + "csIBM863", /* IANA */ + ), + cp863, + { cp863_mbtowc, NULL }, { cp863_wctomb, NULL }) + +DEFENCODING(( "CP864", /* IANA, JDK 1.1 */ + "IBM864", /* IANA */ + "csIBM864", /* IANA */ + ), + cp864, + { cp864_mbtowc, NULL }, { cp864_wctomb, NULL }) + +DEFENCODING(( "CP865", /* IANA, JDK 1.1 */ + "IBM865", /* IANA */ + "865", /* IANA */ + "csIBM865", /* IANA */ + ), + cp865, + { cp865_mbtowc, NULL }, { cp865_wctomb, NULL }) + +DEFENCODING(( "CP869", /* IANA, JDK 1.1 */ + "IBM869", /* IANA */ + "869", /* IANA */ + "CP-GR", /* IANA */ + "csIBM869", /* IANA */ + ), + cp869, + { cp869_mbtowc, NULL }, { cp869_wctomb, NULL }) + +DEFENCODING(( "CP1125", /* ICU */ + ), + cp1125, + { cp1125_mbtowc, NULL }, { cp1125_wctomb, NULL }) diff --git a/graf2d/win32gdk/gdk/src/iconv/encodings_extra.def b/graf2d/win32gdk/gdk/src/iconv/encodings_extra.def new file mode 100644 index 0000000000000..614422b68d6e2 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/encodings_extra.def @@ -0,0 +1,57 @@ +/* Copyright (C) 2002, 2005, 2008 Free Software Foundation, Inc. + This file is part of the GNU LIBICONV Library. + + The GNU LIBICONV Library is free software; you can redistribute it + and/or modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either version 2 + of the License, or (at your option) any later version. + + The GNU LIBICONV Library is distributed in the hope that it will be + useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with the GNU LIBICONV Library; see the file COPYING.LIB. + If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + Fifth Floor, Boston, MA 02110-1301, USA. */ + +DEFENCODING(( "EUC-JISX0213", + "EUC-JIS-2004", /* x0213.org */ + ), + euc_jisx0213, + { euc_jisx0213_mbtowc, euc_jisx0213_flushwc }, { euc_jisx0213_wctomb, euc_jisx0213_reset }) + +DEFENCODING(( "SHIFT_JISX0213", + "SHIFT_JIS-2004", /* x0213.org */ + ), + shift_jisx0213, + { shift_jisx0213_mbtowc, shift_jisx0213_flushwc }, { shift_jisx0213_wctomb, shift_jisx0213_reset }) + +DEFENCODING(( "ISO-2022-JP-3", + "ISO-2022-JP-2004", /* x0213.org */ + ), + iso2022_jp3, + { iso2022_jp3_mbtowc, iso2022_jp3_flushwc }, { iso2022_jp3_wctomb, iso2022_jp3_reset }) + +DEFENCODING(( "BIG5-2003", + ), + big5_2003, + { big5_2003_mbtowc, NULL }, { big5_2003_wctomb, NULL }) + +DEFENCODING(( "TDS565", + "ISO-IR-230", + ), + tds565, + { tds565_mbtowc, NULL }, { tds565_wctomb, NULL }) + +DEFENCODING(( "ATARIST", + "ATARI", + ), + atarist, + { atarist_mbtowc, NULL }, { atarist_wctomb, NULL }) + +DEFENCODING(( "RISCOS-LATIN1", + ), + riscos1, + { riscos1_mbtowc, NULL }, { riscos1_wctomb, NULL }) diff --git a/graf2d/win32gdk/gdk/src/iconv/encodings_local.def b/graf2d/win32gdk/gdk/src/iconv/encodings_local.def new file mode 100644 index 0000000000000..4e793e5bd978a --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/encodings_local.def @@ -0,0 +1,29 @@ +/* Copyright (C) 2000-2001 Free Software Foundation, Inc. + This file is part of the GNU LIBICONV Library. + + The GNU LIBICONV Library is free software; you can redistribute it + and/or modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either version 2 + of the License, or (at your option) any later version. + + The GNU LIBICONV Library is distributed in the hope that it will be + useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with the GNU LIBICONV Library; see the file COPYING.LIB. + If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + Fifth Floor, Boston, MA 02110-1301, USA. */ + +/* Names for locale dependent encodings. */ + +DEFENCODING(( "CHAR", + ), + local_char, + { NULL, NULL }, { NULL, NULL }) + +DEFENCODING(( "WCHAR_T", /* glibc */ + ), + local_wchar_t, + { NULL, NULL }, { NULL, NULL }) diff --git a/graf2d/win32gdk/gdk/src/iconv/encodings_osf1.def b/graf2d/win32gdk/gdk/src/iconv/encodings_osf1.def new file mode 100644 index 0000000000000..7912854bbbd92 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/encodings_osf1.def @@ -0,0 +1,37 @@ +/* Copyright (C) 2001, 2008 Free Software Foundation, Inc. + This file is part of the GNU LIBICONV Library. + + The GNU LIBICONV Library is free software; you can redistribute it + and/or modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either version 2 + of the License, or (at your option) any later version. + + The GNU LIBICONV Library is distributed in the hope that it will be + useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with the GNU LIBICONV Library; see the file COPYING.LIB. + If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + Fifth Floor, Boston, MA 02110-1301, USA. */ + +/* Encodings used by system dependent locales on OSF/1 a.k.a. Tru64. */ + +DEFENCODING(( "DEC-KANJI", + ), + dec_kanji, + { dec_kanji_mbtowc, NULL }, { dec_kanji_wctomb, NULL }) +#ifdef USE_OSF1_ALIASES +DEFALIAS( "DECKANJI", /* OSF/1 */ + dec_kanji) +#endif + +DEFENCODING(( "DEC-HANYU", + ), + dec_hanyu, + { dec_hanyu_mbtowc, NULL }, { dec_hanyu_wctomb, NULL }) +#ifdef USE_OSF1_ALIASES +DEFALIAS( "DECHANYU", /* OSF/1 */ + dec_hanyu) +#endif diff --git a/graf2d/win32gdk/gdk/src/iconv/euc_cn.h b/graf2d/win32gdk/gdk/src/iconv/euc_cn.h new file mode 100644 index 0000000000000..a25417a989c60 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/euc_cn.h @@ -0,0 +1,72 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * EUC-CN + */ + +static int +euc_cn_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + /* Code set 0 (ASCII or GB 1988-89) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (GB 2312-1980) */ + if (c >= 0xa1 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 < 0xff) { + unsigned char buf[2]; + buf[0] = c-0x80; buf[1] = c2-0x80; + return gb2312_mbtowc(conv,pwc,buf,2); + } else + return RET_ILSEQ; + } + } + return RET_ILSEQ; +} + +static int +euc_cn_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Code set 0 (ASCII or GB 1988-89) */ + ret = ascii_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + /* Code set 1 (GB 2312-1980) */ + ret = gb2312_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]+0x80; + r[1] = buf[1]+0x80; + return 2; + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/euc_jisx0213.h b/graf2d/win32gdk/gdk/src/iconv/euc_jisx0213.h new file mode 100644 index 0000000000000..4d417ca12e119 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/euc_jisx0213.h @@ -0,0 +1,268 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * EUC-JISX0213 + */ + +/* The structure of EUC-JISX0213 is as follows: + + 0x00..0x7F: ASCII + + 0x8E{A1..FE}: JISX0201 Katakana, with prefix 0x8E, offset by +0x80. + + 0x8F{A1..FE}{A1..FE}: JISX0213 plane 2, with prefix 0x8F, offset by +0x8080. + + 0x{A1..FE}{A1..FE}: JISX0213 plane 1, offset by +0x8080. + + Note that some JISX0213 characters are not contained in Unicode 3.2 + and are therefore best represented as sequences of Unicode characters. +*/ + +#include "jisx0213.h" +#include "flushwc.h" + +static int +euc_jisx0213_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + ucs4_t last_wc = conv->istate; + if (last_wc) { + /* Output the buffered character. */ + conv->istate = 0; + *pwc = last_wc; + return 0; /* Don't advance the input pointer. */ + } else { + unsigned char c = *s; + if (c < 0x80) { + /* Plain ASCII character. */ + *pwc = (ucs4_t) c; + return 1; + } else { + if ((c >= 0xa1 && c <= 0xfe) || c == 0x8e || c == 0x8f) { + /* Two or three byte character. */ + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 <= 0xfe) { + if (c == 0x8e) { + /* Half-width katakana. */ + if (c2 <= 0xdf) { + *pwc = c2 + 0xfec0; + return 2; + } + } else { + ucs4_t wc; + if (c == 0x8f) { + /* JISX 0213 plane 2. */ + if (n >= 3) { + unsigned char c3 = s[2]; + wc = jisx0213_to_ucs4(0x200-0x80+c2,c3^0x80); + } else + return RET_TOOFEW(0); + } else { + /* JISX 0213 plane 1. */ + wc = jisx0213_to_ucs4(0x100-0x80+c,c2^0x80); + } + if (wc) { + if (wc < 0x80) { + /* It's a combining character. */ + ucs4_t wc1 = jisx0213_to_ucs_combining[wc - 1][0]; + ucs4_t wc2 = jisx0213_to_ucs_combining[wc - 1][1]; + /* We cannot output two Unicode characters at once. So, + output the first character and buffer the second one. */ + *pwc = wc1; + conv->istate = wc2; + } else + *pwc = wc; + return (c == 0x8f ? 3 : 2); + } + } + } + } else + return RET_TOOFEW(0); + } + return RET_ILSEQ; + } + } +} + +#define euc_jisx0213_flushwc normal_flushwc + +/* Composition tables for each of the relevant combining characters. */ +static const struct { unsigned short base; unsigned short composed; } euc_jisx0213_comp_table_data[] = { +#define euc_jisx0213_comp_table02e5_idx 0 +#define euc_jisx0213_comp_table02e5_len 1 + { 0xabe4, 0xabe5 }, /* 0x12B65 = 0x12B64 U+02E5 */ +#define euc_jisx0213_comp_table02e9_idx (euc_jisx0213_comp_table02e5_idx+euc_jisx0213_comp_table02e5_len) +#define euc_jisx0213_comp_table02e9_len 1 + { 0xabe0, 0xabe6 }, /* 0x12B66 = 0x12B60 U+02E9 */ +#define euc_jisx0213_comp_table0300_idx (euc_jisx0213_comp_table02e9_idx+euc_jisx0213_comp_table02e9_len) +#define euc_jisx0213_comp_table0300_len 5 + { 0xa9dc, 0xabc4 }, /* 0x12B44 = 0x1295C U+0300 */ + { 0xabb8, 0xabc8 }, /* 0x12B48 = 0x12B38 U+0300 */ + { 0xabb7, 0xabca }, /* 0x12B4A = 0x12B37 U+0300 */ + { 0xabb0, 0xabcc }, /* 0x12B4C = 0x12B30 U+0300 */ + { 0xabc3, 0xabce }, /* 0x12B4E = 0x12B43 U+0300 */ +#define euc_jisx0213_comp_table0301_idx (euc_jisx0213_comp_table0300_idx+euc_jisx0213_comp_table0300_len) +#define euc_jisx0213_comp_table0301_len 4 + { 0xabb8, 0xabc9 }, /* 0x12B49 = 0x12B38 U+0301 */ + { 0xabb7, 0xabcb }, /* 0x12B4B = 0x12B37 U+0301 */ + { 0xabb0, 0xabcd }, /* 0x12B4D = 0x12B30 U+0301 */ + { 0xabc3, 0xabcf }, /* 0x12B4F = 0x12B43 U+0301 */ +#define euc_jisx0213_comp_table309a_idx (euc_jisx0213_comp_table0301_idx+euc_jisx0213_comp_table0301_len) +#define euc_jisx0213_comp_table309a_len 14 + { 0xa4ab, 0xa4f7 }, /* 0x12477 = 0x1242B U+309A */ + { 0xa4ad, 0xa4f8 }, /* 0x12478 = 0x1242D U+309A */ + { 0xa4af, 0xa4f9 }, /* 0x12479 = 0x1242F U+309A */ + { 0xa4b1, 0xa4fa }, /* 0x1247A = 0x12431 U+309A */ + { 0xa4b3, 0xa4fb }, /* 0x1247B = 0x12433 U+309A */ + { 0xa5ab, 0xa5f7 }, /* 0x12577 = 0x1252B U+309A */ + { 0xa5ad, 0xa5f8 }, /* 0x12578 = 0x1252D U+309A */ + { 0xa5af, 0xa5f9 }, /* 0x12579 = 0x1252F U+309A */ + { 0xa5b1, 0xa5fa }, /* 0x1257A = 0x12531 U+309A */ + { 0xa5b3, 0xa5fb }, /* 0x1257B = 0x12533 U+309A */ + { 0xa5bb, 0xa5fc }, /* 0x1257C = 0x1253B U+309A */ + { 0xa5c4, 0xa5fd }, /* 0x1257D = 0x12544 U+309A */ + { 0xa5c8, 0xa5fe }, /* 0x1257E = 0x12548 U+309A */ + { 0xa6f5, 0xa6f8 }, /* 0x12678 = 0x12675 U+309A */ +}; + +static int +euc_jisx0213_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + int count = 0; + unsigned short lasttwo = conv->ostate; + + if (lasttwo) { + /* Attempt to combine the last character with this one. */ + unsigned int idx; + unsigned int len; + + if (wc == 0x02e5) + idx = euc_jisx0213_comp_table02e5_idx, + len = euc_jisx0213_comp_table02e5_len; + else if (wc == 0x02e9) + idx = euc_jisx0213_comp_table02e9_idx, + len = euc_jisx0213_comp_table02e9_len; + else if (wc == 0x0300) + idx = euc_jisx0213_comp_table0300_idx, + len = euc_jisx0213_comp_table0300_len; + else if (wc == 0x0301) + idx = euc_jisx0213_comp_table0301_idx, + len = euc_jisx0213_comp_table0301_len; + else if (wc == 0x309a) + idx = euc_jisx0213_comp_table309a_idx, + len = euc_jisx0213_comp_table309a_len; + else + goto not_combining; + + do + if (euc_jisx0213_comp_table_data[idx].base == lasttwo) + break; + while (++idx, --len > 0); + + if (len > 0) { + /* Output the combined character. */ + if (n >= 2) { + lasttwo = euc_jisx0213_comp_table_data[idx].composed; + r[0] = (lasttwo >> 8) & 0xff; + r[1] = lasttwo & 0xff; + conv->ostate = 0; + return 2; + } else + return RET_TOOSMALL; + } + + not_combining: + /* Output the buffered character. */ + if (n < 2) + return RET_TOOSMALL; + r[0] = (lasttwo >> 8) & 0xff; + r[1] = lasttwo & 0xff; + r += 2; + count = 2; + } + + if (wc < 0x80) { + /* Plain ASCII character. */ + if (n > count) { + r[0] = (unsigned char) wc; + conv->ostate = 0; + return count+1; + } else + return RET_TOOSMALL; + } else if (wc >= 0xff61 && wc <= 0xff9f) { + /* Half-width katakana. */ + if (n >= count+2) { + r[0] = 0x8e; + r[1] = wc - 0xfec0; + conv->ostate = 0; + return count+2; + } else + return RET_TOOSMALL; + } else { + unsigned short jch = ucs4_to_jisx0213(wc); + if (jch != 0) { + if (jch & 0x0080) { + /* A possible match in comp_table_data. We have to buffer it. */ + /* We know it's a JISX 0213 plane 1 character. */ + if (jch & 0x8000) abort(); + conv->ostate = jch | 0x8080; + return count+0; + } + if (jch & 0x8000) { + /* JISX 0213 plane 2. */ + if (n >= count+3) { + r[0] = 0x8f; + r[1] = (jch >> 8) | 0x80; + r[2] = (jch & 0xff) | 0x80; + conv->ostate = 0; + return count+3; + } else + return RET_TOOSMALL; + } else { + /* JISX 0213 plane 1. */ + if (n >= count+2) { + r[0] = (jch >> 8) | 0x80; + r[1] = (jch & 0xff) | 0x80; + conv->ostate = 0; + return count+2; + } else + return RET_TOOSMALL; + } + } + return RET_ILUNI; + } +} + +static int +euc_jisx0213_reset (conv_t conv, unsigned char *r, int n) +{ + state_t lasttwo = conv->ostate; + + if (lasttwo) { + if (n < 2) + return RET_TOOSMALL; + r[0] = (lasttwo >> 8) & 0xff; + r[1] = lasttwo & 0xff; + /* conv->ostate = 0; will be done by the caller */ + return 2; + } else + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/euc_jp.h b/graf2d/win32gdk/gdk/src/iconv/euc_jp.h new file mode 100644 index 0000000000000..84fa2e7eb03b7 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/euc_jp.h @@ -0,0 +1,191 @@ +/* + * Copyright (C) 1999-2001, 2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * EUC-JP + */ + +static int +euc_jp_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + /* Code set 0 (ASCII or JIS X 0201-1976 Roman) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (JIS X 0208) */ + if (c >= 0xa1 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + if (c < 0xf5) { + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 < 0xff) { + unsigned char buf[2]; + buf[0] = c-0x80; buf[1] = c2-0x80; + return jisx0208_mbtowc(conv,pwc,buf,2); + } else + return RET_ILSEQ; + } else { + /* User-defined range. See + * Ken Lunde's "CJKV Information Processing", table 4-66, p. 206. */ + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 < 0xff) { + *pwc = 0xe000 + 94*(c-0xf5) + (c2-0xa1); + return 2; + } else + return RET_ILSEQ; + } + } + /* Code set 2 (half-width katakana) */ + if (c == 0x8e) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 < 0xe0) { + int ret = jisx0201_mbtowc(conv,pwc,s+1,n-1); + if (ret == RET_ILSEQ) + return RET_ILSEQ; + if (ret != 1) abort(); + return 2; + } else + return RET_ILSEQ; + } + } + /* Code set 3 (JIS X 0212-1990) */ + if (c == 0x8f) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 < 0xff) { + if (n < 3) + return RET_TOOFEW(0); + if (c2 < 0xf5) { + unsigned char c3 = s[2]; + if (c3 >= 0xa1 && c3 < 0xff) { + unsigned char buf[2]; + int ret; + buf[0] = c2-0x80; buf[1] = c3-0x80; + ret = jisx0212_mbtowc(conv,pwc,buf,2); + if (ret == RET_ILSEQ) + return RET_ILSEQ; + if (ret != 2) abort(); + return 3; + } else + return RET_ILSEQ; + } else { + /* User-defined range. See + * Ken Lunde's "CJKV Information Processing", table 4-66, p. 206. */ + unsigned char c3 = s[2]; + if (c3 >= 0xa1 && c3 < 0xff) { + *pwc = 0xe3ac + 94*(c2-0xf5) + (c3-0xa1); + return 3; + } else + return RET_ILSEQ; + } + } else + return RET_ILSEQ; + } + } + return RET_ILSEQ; +} + +static int +euc_jp_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Code set 0 (ASCII or JIS X 0201-1976 Roman) */ + ret = ascii_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + /* Code set 1 (JIS X 0208) */ + ret = jisx0208_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]+0x80; + r[1] = buf[1]+0x80; + return 2; + } + + /* Code set 2 (half-width katakana) */ + ret = jisx0201_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI && buf[0] >= 0x80) { + if (ret != 1) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = 0x8e; + r[1] = buf[0]; + return 2; + } + + /* Code set 3 (JIS X 0212-1990) */ + ret = jisx0212_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 3) + return RET_TOOSMALL; + r[0] = 0x8f; + r[1] = buf[0]+0x80; + r[2] = buf[1]+0x80; + return 3; + } + + /* Extra compatibility with Shift_JIS. */ + if (wc == 0x00a5) { + r[0] = 0x5c; + return 1; + } + if (wc == 0x203e) { + r[0] = 0x7e; + return 1; + } + + /* User-defined range. See + * Ken Lunde's "CJKV Information Processing", table 4-66, p. 206. */ + if (wc >= 0xe000 && wc < 0xe758) { + if (wc < 0xe3ac) { + unsigned char c1, c2; + if (n < 2) + return RET_TOOSMALL; + c1 = (unsigned int) (wc - 0xe000) / 94; + c2 = (unsigned int) (wc - 0xe000) % 94; + r[0] = c1+0xf5; + r[1] = c2+0xa1; + return 2; + } else { + unsigned char c1, c2; + if (n < 3) + return RET_TOOSMALL; + c1 = (unsigned int) (wc - 0xe3ac) / 94; + c2 = (unsigned int) (wc - 0xe3ac) % 94; + r[0] = 0x8f; + r[1] = c1+0xf5; + r[2] = c2+0xa1; + return 3; + } + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/euc_kr.h b/graf2d/win32gdk/gdk/src/iconv/euc_kr.h new file mode 100644 index 0000000000000..8b3dd0528d7c3 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/euc_kr.h @@ -0,0 +1,74 @@ +/* + * Copyright (C) 1999-2001, 2007 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * EUC-KR + */ + +/* Specification: RFC 1557 */ + +static int +euc_kr_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + /* Code set 0 (ASCII or KS C 5636-1993) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (KS C 5601-1992, now KS X 1001:2002) */ + if (c >= 0xa1 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 < 0xff) { + unsigned char buf[2]; + buf[0] = c-0x80; buf[1] = c2-0x80; + return ksc5601_mbtowc(conv,pwc,buf,2); + } else + return RET_ILSEQ; + } + } + return RET_ILSEQ; +} + +static int +euc_kr_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Code set 0 (ASCII or KS C 5636-1993) */ + ret = ascii_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + /* Code set 1 (KS C 5601-1992, now KS X 1001:2002) */ + ret = ksc5601_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]+0x80; + r[1] = buf[1]+0x80; + return 2; + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/euc_tw.h b/graf2d/win32gdk/gdk/src/iconv/euc_tw.h new file mode 100644 index 0000000000000..f7bdc8b7ca361 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/euc_tw.h @@ -0,0 +1,116 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * EUC-TW + */ + +static int +euc_tw_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + /* Code set 0 (ASCII) */ + if (c < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + /* Code set 1 (CNS 11643-1992 Plane 1) */ + if (c >= 0xa1 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 < 0xff) { + unsigned char buf[2]; + buf[0] = c-0x80; buf[1] = c2-0x80; + return cns11643_1_mbtowc(conv,pwc,buf,2); + } else + return RET_ILSEQ; + } + } + /* Code set 2 (CNS 11643-1992 Planes 1-16) */ + if (c == 0x8e) { + if (n < 4) + return RET_TOOFEW(0); + { + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 <= 0xb0) { + unsigned char c3 = s[2]; + unsigned char c4 = s[3]; + if (c3 >= 0xa1 && c3 < 0xff && c4 >= 0xa1 && c4 < 0xff) { + unsigned char buf[2]; + int ret; + buf[0] = c3-0x80; buf[1] = c4-0x80; + switch (c2-0xa0) { + case 1: ret = cns11643_1_mbtowc(conv,pwc,buf,2); break; + case 2: ret = cns11643_2_mbtowc(conv,pwc,buf,2); break; + case 3: ret = cns11643_3_mbtowc(conv,pwc,buf,2); break; + case 4: ret = cns11643_4_mbtowc(conv,pwc,buf,2); break; + case 5: ret = cns11643_5_mbtowc(conv,pwc,buf,2); break; + case 6: ret = cns11643_6_mbtowc(conv,pwc,buf,2); break; + case 7: ret = cns11643_7_mbtowc(conv,pwc,buf,2); break; + case 15: ret = cns11643_15_mbtowc(conv,pwc,buf,2); break; + default: return RET_ILSEQ; + } + if (ret == RET_ILSEQ) + return RET_ILSEQ; + if (ret != 2) abort(); + return 4; + } + } + } + } + return RET_ILSEQ; +} + +static int +euc_tw_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[3]; + int ret; + + /* Code set 0 (ASCII) */ + ret = ascii_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + ret = cns11643_wctomb(conv,buf,wc,3); + if (ret != RET_ILUNI) { + if (ret != 3) abort(); + + /* Code set 1 (CNS 11643-1992 Plane 1) */ + if (buf[0] == 1) { + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[1]+0x80; + r[1] = buf[2]+0x80; + return 2; + } + + /* Code set 2 (CNS 11643-1992 Planes 1-16) */ + if (n < 4) + return RET_TOOSMALL; + r[0] = 0x8e; + r[1] = buf[0]+0xa0; + r[2] = buf[1]+0x80; + r[3] = buf[2]+0x80; + return 4; + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/flags.h b/graf2d/win32gdk/gdk/src/iconv/flags.h new file mode 100644 index 0000000000000..d7cda212c68dd --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/flags.h @@ -0,0 +1,156 @@ +/* Generated automatically by genflags. */ + +/* Set if the encoding can encode + the acute and grave accents U+00B4 and U+0060. */ +#define HAVE_ACCENTS 1 + +/* Set if the encoding can encode + the single quotation marks U+2018 and U+2019. */ +#define HAVE_QUOTATION_MARKS 2 + +/* Set if the encoding can encode + the double-width Hangul letters (Jamo) U+3131 to U+3163. */ +#define HAVE_HANGUL_JAMO 4 + +#define ei_ascii_oflags (0) +#define ei_utf8_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_ucs2_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_ucs2be_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_ucs2le_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_ucs4_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_ucs4be_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_ucs4le_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_utf16_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_utf16be_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_utf16le_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_utf32_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_utf32be_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_utf32le_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_utf7_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_ucs2internal_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_ucs2swapped_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_ucs4internal_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_ucs4swapped_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_c99_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_java_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_iso8859_1_oflags (HAVE_ACCENTS) +#define ei_iso8859_2_oflags (HAVE_ACCENTS) +#define ei_iso8859_3_oflags (HAVE_ACCENTS) +#define ei_iso8859_4_oflags (HAVE_ACCENTS) +#define ei_iso8859_5_oflags (0) +#define ei_iso8859_6_oflags (0) +#define ei_iso8859_7_oflags (HAVE_QUOTATION_MARKS) +#define ei_iso8859_8_oflags (HAVE_ACCENTS) +#define ei_iso8859_9_oflags (HAVE_ACCENTS) +#define ei_iso8859_10_oflags (0) +#define ei_iso8859_11_oflags (0) +#define ei_iso8859_13_oflags (0) +#define ei_iso8859_14_oflags (0) +#define ei_iso8859_15_oflags (0) +#define ei_iso8859_16_oflags (0) +#define ei_koi8_r_oflags (0) +#define ei_koi8_u_oflags (0) +#define ei_koi8_ru_oflags (0) +#define ei_cp1250_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_cp1251_oflags (HAVE_QUOTATION_MARKS) +#define ei_cp1252_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_cp1253_oflags (HAVE_QUOTATION_MARKS) +#define ei_cp1254_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_cp1255_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_cp1256_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_cp1257_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_cp1258_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_cp850_oflags (HAVE_ACCENTS) +#define ei_cp862_oflags (0) +#define ei_cp866_oflags (0) +#define ei_cp1131_oflags (0) +#define ei_mac_roman_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_mac_centraleurope_oflags (HAVE_QUOTATION_MARKS) +#define ei_mac_iceland_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_mac_croatian_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_mac_romania_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_mac_cyrillic_oflags (HAVE_QUOTATION_MARKS) +#define ei_mac_ukraine_oflags (HAVE_QUOTATION_MARKS) +#define ei_mac_greek_oflags (HAVE_QUOTATION_MARKS) +#define ei_mac_turkish_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_mac_hebrew_oflags (HAVE_QUOTATION_MARKS) +#define ei_mac_arabic_oflags (0) +#define ei_mac_thai_oflags (HAVE_QUOTATION_MARKS) +#define ei_hp_roman8_oflags (HAVE_ACCENTS) +#define ei_nextstep_oflags (HAVE_ACCENTS) +#define ei_armscii_8_oflags (0) +#define ei_georgian_academy_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_georgian_ps_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_koi8_t_oflags (HAVE_QUOTATION_MARKS) +#define ei_pt154_oflags (HAVE_QUOTATION_MARKS) +#define ei_rk1048_oflags (HAVE_QUOTATION_MARKS) +#define ei_mulelao_oflags (0) +#define ei_cp1133_oflags (0) +#define ei_tis620_oflags (0) +#define ei_cp874_oflags (HAVE_QUOTATION_MARKS) +#define ei_viscii_oflags (0) +#define ei_tcvn_oflags (HAVE_ACCENTS) +#define ei_iso646_jp_oflags (0) +#define ei_jisx0201_oflags (0) +#define ei_jisx0208_oflags (HAVE_QUOTATION_MARKS) +#define ei_jisx0212_oflags (0) +#define ei_iso646_cn_oflags (0) +#define ei_gb2312_oflags (HAVE_QUOTATION_MARKS) +#define ei_isoir165_oflags (HAVE_QUOTATION_MARKS) +#define ei_ksc5601_oflags (HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_euc_jp_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_sjis_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_cp932_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_iso2022_jp_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_iso2022_jp1_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_iso2022_jp2_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_euc_cn_oflags (HAVE_QUOTATION_MARKS) +#define ei_ces_gbk_oflags (HAVE_QUOTATION_MARKS) +#define ei_cp936_oflags (HAVE_QUOTATION_MARKS) +#define ei_gb18030_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_iso2022_cn_oflags (HAVE_QUOTATION_MARKS) +#define ei_iso2022_cn_ext_oflags (HAVE_QUOTATION_MARKS) +#define ei_hz_oflags (HAVE_QUOTATION_MARKS) +#define ei_euc_tw_oflags (HAVE_QUOTATION_MARKS) +#define ei_ces_big5_oflags (HAVE_QUOTATION_MARKS) +#define ei_cp950_oflags (HAVE_QUOTATION_MARKS) +#define ei_big5hkscs1999_oflags (HAVE_QUOTATION_MARKS) +#define ei_big5hkscs2001_oflags (HAVE_QUOTATION_MARKS) +#define ei_big5hkscs2004_oflags (HAVE_QUOTATION_MARKS) +#define ei_euc_kr_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_cp949_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_johab_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_iso2022_kr_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS | HAVE_HANGUL_JAMO) +#define ei_cp856_oflags (HAVE_ACCENTS) +#define ei_cp922_oflags (HAVE_ACCENTS) +#define ei_cp943_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_cp1046_oflags (0) +#define ei_cp1124_oflags (0) +#define ei_cp1129_oflags (0) +#define ei_cp1161_oflags (0) +#define ei_cp1162_oflags (HAVE_QUOTATION_MARKS) +#define ei_cp1163_oflags (0) +#define ei_dec_kanji_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_dec_hanyu_oflags (HAVE_QUOTATION_MARKS) +#define ei_cp437_oflags (0) +#define ei_cp737_oflags (0) +#define ei_cp775_oflags (0) +#define ei_cp852_oflags (HAVE_ACCENTS) +#define ei_cp853_oflags (HAVE_ACCENTS) +#define ei_cp855_oflags (0) +#define ei_cp857_oflags (HAVE_ACCENTS) +#define ei_cp858_oflags (HAVE_ACCENTS) +#define ei_cp860_oflags (0) +#define ei_cp861_oflags (0) +#define ei_cp863_oflags (HAVE_ACCENTS) +#define ei_cp864_oflags (0) +#define ei_cp865_oflags (0) +#define ei_cp869_oflags (HAVE_QUOTATION_MARKS) +#define ei_cp1125_oflags (0) +#define ei_euc_jisx0213_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_shift_jisx0213_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_iso2022_jp3_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) +#define ei_big5_2003_oflags (HAVE_QUOTATION_MARKS) +#define ei_tds565_oflags (0) +#define ei_atarist_oflags (HAVE_ACCENTS) +#define ei_riscos1_oflags (HAVE_ACCENTS | HAVE_QUOTATION_MARKS) diff --git a/graf2d/win32gdk/gdk/src/iconv/flushwc.h b/graf2d/win32gdk/gdk/src/iconv/flushwc.h new file mode 100644 index 0000000000000..da25212efaab7 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/flushwc.h @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +#ifndef _FLUSHWC_H +#define _FLUSHWC_H + +static int +normal_flushwc (conv_t conv, ucs4_t *pwc) +{ + ucs4_t last_wc = conv->istate; + if (last_wc) { + /* Output the buffered character. */ + conv->istate = 0; + *pwc = (ucs4_t) last_wc; + return 1; + } else + return 0; +} + +#endif /* _FLUSHWC_H */ diff --git a/graf2d/win32gdk/gdk/src/iconv/gb12345.h b/graf2d/win32gdk/gdk/src/iconv/gb12345.h new file mode 100644 index 0000000000000..b7e062e3e6234 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/gb12345.h @@ -0,0 +1,67 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GB/T 12345-1990 + */ + +/* + * GB/T 12345-1990 is a traditional chinese counterpart of GB 2312-1986. + * According to the unicode.org tables: + * 2146 characters have been changed to their traditional counterpart, + * 103 characters have been added, no characters have been removed. + * Therefore we use an auxiliary table, which contains only the changes. + */ + +#include "gb12345ext.h" + +static int +gb12345_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + int ret; + + /* The gb12345ext table overrides some entries in the gb2312 table. */ + /* Try the GB12345 extensions -> Unicode table. */ + ret = gb12345ext_mbtowc(conv,pwc,s,n); + if (ret != RET_ILSEQ) + return ret; + /* Try the GB2312 -> Unicode table. */ + ret = gb2312_mbtowc(conv,pwc,s,n); + return ret; +} + +static int +gb12345_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + int ret; + + /* The gb12345ext table overrides some entries in the gb2312 table. */ + /* Try the Unicode -> GB12345 extensions table. */ + ret = gb12345ext_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + /* Try the Unicode -> GB2312 table, and check that the resulting GB2312 + byte sequence is not overridden by the GB12345 extensions table. */ + ret = gb2312_wctomb(conv,r,wc,n); + if (ret == 2 && gb12345ext_mbtowc(conv,&wc,r,2) == 2) + return RET_ILUNI; + else + return ret; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/gb12345ext.h b/graf2d/win32gdk/gdk/src/iconv/gb12345ext.h new file mode 100644 index 0000000000000..b461ec87d561a --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/gb12345ext.h @@ -0,0 +1,1796 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GB/T 12345.1990-0 extensions + */ + +static const unsigned short gb12345ext_2uni_page21[12] = { + /* 0x21 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x2225, +}; +static const unsigned short gb12345ext_2uni_page26[85] = { + /* 0x26 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfe35, + 0xfe36, 0xfe39, 0xfe3a, 0xfe3f, 0xfe40, 0xfe3d, 0xfe3e, 0xfe41, + 0xfe42, 0xfe43, 0xfe44, 0xfffd, 0xfffd, 0xfe3b, 0xfe3c, 0xfe37, + 0xfe38, 0xfe31, 0xfffd, 0xfe33, 0xfe34, +}; +static const unsigned short gb12345ext_2uni_page28[32] = { + /* 0x28 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x0251, 0x1e3f, 0x0144, 0x0148, 0x01f9, 0x0261, +}; +static const unsigned short gb12345ext_2uni_page30[6871] = { + /* 0x30 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x769a, + 0xfffd, 0x85f9, 0xfffd, 0xfffd, 0x7919, 0x611b, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x9aaf, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8956, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x58e9, 0xfffd, 0x7f77, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x64fa, 0xfffd, 0x6557, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x9812, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x8fa6, 0x7d46, 0xfffd, 0x5e6b, 0xfffd, + 0xfffd, 0xfffd, 0x7d81, 0xfffd, 0xfffd, 0xfffd, 0x938a, 0xfffd, + 0x8b17, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x31 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x98fd, 0x5bf6, 0xfffd, 0x5831, + 0xfffd, 0xfffd, 0x9b91, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x8f29, 0xfffd, 0x8c9d, 0x92c7, 0xfffd, 0x72fd, 0x5099, + 0x618a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x7db3, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x7b46, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7562, 0x6583, + 0xfffd, 0x5e63, 0xfffd, 0xfffd, 0x9589, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x908a, 0x7de8, + 0x8cb6, 0xfffd, 0xfffd, 0x8b8a, 0xfffd, 0xfffd, 0x8faf, 0x8fae, + 0xfffd, 0x6a19, 0xfffd, 0xfffd, 0xfffd, 0x9c49, 0xfffd, 0xfffd, + 0x765f, 0xfffd, 0xfffd, 0x7015, 0x6ff1, 0x8cd3, 0x64ef, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9905, 0xfffd, + /* 0x32 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x64a5, 0x9262, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x9251, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x99c1, 0xfffd, 0xfffd, 0xfffd, + 0x88dc, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8ca1, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x53c3, 0x8836, 0x6b98, + 0x615a, 0x6158, 0x71e6, 0x84bc, 0x8259, 0x5009, 0x6ec4, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x53a0, 0xfffd, 0x5074, + 0xfffd, 0x6e2c, 0x5c64, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8a6b, 0xfffd, + 0xfffd, 0xfffd, 0x6519, 0x647b, 0x87ec, 0x995e, 0x8b92, 0x7e8f, + 0x93df, 0x7523, 0x95e1, 0x986b, 0xfffd, 0xfffd, + /* 0x33 */ + 0x5834, 0x5617, 0xfffd, 0x9577, 0x511f, 0x8178, 0x5ee0, 0xfffd, + 0x66a2, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9214, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8eca, 0xfffd, 0xfffd, 0xfffd, + 0x5fb9, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5875, 0xfffd, 0xfffd, + 0xfffd, 0x9673, 0xfffd, 0x896f, 0xfffd, 0x7a31, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x61f2, 0xfffd, 0x8aa0, 0xfffd, + 0xfffd, 0x9a01, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x9072, 0xfffd, 0x99b3, 0xfffd, 0x9f52, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x71be, 0xfffd, 0x885d, 0x87f2, 0xfffd, 0x5bf5, + 0xfffd, 0xfffd, 0x7587, 0x8e8a, 0xfffd, 0xfffd, 0x7c4c, 0xfffd, + 0x7da2, 0xfffd, 0x919c, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x92e4, 0x96db, 0xfffd, 0xfffd, 0xfffd, + /* 0x34 */ + 0x790e, 0x5132, 0xfffd, 0xfffd, 0x89f8, 0x8655, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x50b3, 0xfffd, 0xfffd, 0xfffd, 0x7621, 0xfffd, + 0xfffd, 0xfffd, 0x95d6, 0x5275, 0xfffd, 0xfffd, 0xfffd, 0x9318, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7d14, 0xfffd, + 0xfffd, 0x7dbd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8fad, 0xfffd, + 0xfffd, 0x8a5e, 0xfffd, 0xfffd, 0x8cdc, 0xfffd, 0x8070, 0xfffd, + 0xfffd, 0xfffd, 0x5f9e, 0x53e2, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x8ea5, 0xfffd, 0x7ac4, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x932f, 0xfffd, 0x9054, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5e36, + 0xfffd, 0xfffd, 0x8cb8, 0xfffd, 0xfffd, 0xfffd, + /* 0x35 */ + 0xfffd, 0xfffd, 0x64d4, 0xfffd, 0x55ae, 0x9132, 0x64a3, 0x81bd, + 0xfffd, 0xfffd, 0xfffd, 0x619a, 0xfffd, 0x8a95, 0x5f48, 0xfffd, + 0x7576, 0x64cb, 0x9ee8, 0x8569, 0x6a94, 0xfffd, 0x6417, 0xfffd, + 0xfffd, 0x5cf6, 0x79b1, 0x5c0e, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x71c8, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x9127, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6575, + 0xfffd, 0xfffd, 0x6ecc, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x905e, 0x7de0, 0x985b, 0xfffd, + 0xfffd, 0xfffd, 0x9ede, 0xfffd, 0xfffd, 0x588a, 0x96fb, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6fb1, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x91e3, 0x8abf, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8adc, 0xfffd, + /* 0x36 */ + 0xfffd, 0xfffd, 0xfffd, 0x91d8, 0x9802, 0xfffd, 0x9320, 0xfffd, + 0x8a02, 0xfffd, 0x6771, 0xfffd, 0xfffd, 0xfffd, 0x52d5, 0x68df, + 0xfffd, 0xfffd, 0x51cd, 0xfffd, 0xfffd, 0xfffd, 0x9b25, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x72a2, 0x7368, + 0x8b80, 0xfffd, 0xfffd, 0x8ced, 0xfffd, 0x934d, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x935b, 0xfffd, 0x65b7, 0x7dde, + 0xfffd, 0xfffd, 0x968a, 0x5c0d, 0xfffd, 0x5678, 0xfffd, 0xfffd, + 0x9813, 0xfffd, 0x920d, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x596a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x58ae, 0xfffd, 0xfffd, 0x9d5d, 0xfffd, 0x984d, 0x8a1b, 0xfffd, + 0x60e1, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9913, 0xfffd, 0xfffd, + 0x5152, 0xfffd, 0x723e, 0x990c, 0xfffd, 0xfffd, + /* 0x37 */ + 0x8cb3, 0x767c, 0x7f70, 0xfffd, 0xfffd, 0xfffd, 0x95a5, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x792c, 0x91e9, + 0xfffd, 0xfffd, 0x7169, 0xfffd, 0xfffd, 0x7bc4, 0x8ca9, 0xfffd, + 0x98ef, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x8a2a, 0x7d21, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x98db, 0xfffd, 0xfffd, 0x8ab9, 0xfffd, 0xfffd, 0x5ee2, 0xfffd, + 0x8cbb, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7d1b, 0x58b3, + 0xfffd, 0xfffd, 0xfffd, 0x596e, 0xfffd, 0xfffd, 0x61a4, 0x7cde, + 0x8c50, 0xfffd, 0x6953, 0xfffd, 0xfffd, 0x92d2, 0x98a8, 0x760b, + 0xfffd, 0xfffd, 0x99ae, 0x7e2b, 0x8af7, 0xfffd, 0x9cf3, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x819a, 0xfffd, 0xfffd, 0xfffd, 0x8f3b, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x38 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x64ab, 0x8f14, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x8ce6, 0x5fa9, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x8ca0, 0xfffd, 0x8a03, 0xfffd, 0x5a66, 0x7e1b, 0xfffd, + 0xfffd, 0xfffd, 0x8a72, 0xfffd, 0xfffd, 0x9223, 0x84cb, 0xfffd, + 0x5e79, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8d95, 0xfffd, + 0xfffd, 0xfffd, 0x8d1b, 0x5ca1, 0x525b, 0x92fc, 0xfffd, 0xfffd, + 0x7db1, 0x5d17, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x93ac, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x64f1, 0xfffd, 0x9d3f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x95a3, 0xfffd, 0x927b, 0x500b, 0xfffd, 0x7d66, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x39 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9f94, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x978f, 0xfffd, 0xfffd, + 0x8ca2, 0xfffd, 0x920e, 0xfffd, 0x6e9d, 0xfffd, 0xfffd, 0xfffd, + 0x69cb, 0x8cfc, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8831, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x9867, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x526e, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x95dc, + 0xfffd, 0xfffd, 0x89c0, 0xfffd, 0x9928, 0xfffd, 0x6163, 0xfffd, + 0x8cab, 0xfffd, 0x5ee3, 0xfffd, 0xfffd, 0x898f, 0xfffd, 0xfffd, + 0x6b78, 0x9f9c, 0x95a8, 0x8ecc, 0xfffd, 0x8a6d, 0xfffd, 0xfffd, + 0x6ac3, 0xfffd, 0x8cb4, 0x528a, 0x8f25, 0xfffd, 0xfffd, 0x934b, + 0xfffd, 0x570b, 0xfffd, 0xfffd, 0x904e, 0xfffd, + /* 0x3a */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x99ed, 0xfffd, + 0xfffd, 0xfffd, 0x97d3, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x6f22, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x865f, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x95a1, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9db4, 0x8cc0, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x8f5f, 0xfffd, 0xfffd, 0xfffd, 0x9d3b, + 0xfffd, 0xfffd, 0xfffd, 0x7d05, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x5f8c, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x58fa, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x3b */ + 0xfffd, 0xfffd, 0xfffd, 0x8b77, 0xfffd, 0x6eec, 0xfffd, 0xfffd, + 0x5629, 0x83ef, 0xfffd, 0xfffd, 0x756b, 0x5283, 0xfffd, 0x8a71, + 0xfffd, 0xfffd, 0x61f7, 0xfffd, 0x58de, 0x6b61, 0x74b0, 0xfffd, + 0x9084, 0x7de9, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x8b0a, 0xfffd, 0x63ee, 0x8f1d, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8cc4, 0x7a62, + 0x6703, 0x71f4, 0x532f, 0x8af1, 0x8aa8, 0x7e6a, 0x8477, 0xfffd, + 0xfffd, 0xfffd, 0x6e3e, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x7372, 0xfffd, 0xfffd, 0xfffd, 0x8ca8, 0x798d, 0x64ca, 0xfffd, + 0xfffd, 0x6a5f, 0xfffd, 0xfffd, 0x7a4d, 0xfffd, + /* 0x3c */ + 0xfffd, 0x9951, 0xfffd, 0xfffd, 0x8b4f, 0x9dc4, 0xfffd, 0x7e3e, + 0x7ddd, 0xfffd, 0x6975, 0xfffd, 0x8f2f, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7d1a, 0x64e0, 0x5e7e, + 0xfffd, 0xfffd, 0x858a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x5291, 0xfffd, 0x6fdf, 0xfffd, 0xfffd, 0x8a08, 0x8a18, 0xfffd, + 0xfffd, 0x969b, 0xfffd, 0x7e7c, 0x7d00, 0xfffd, 0xfffd, 0x593e, + 0xfffd, 0xfffd, 0xfffd, 0x83a2, 0x9830, 0x8cc8, 0xfffd, 0x9240, + 0xfffd, 0xfffd, 0x50f9, 0xfffd, 0x99d5, 0xfffd, 0x6bb2, 0x76e3, + 0x5805, 0xfffd, 0x7b8b, 0x9593, 0xfffd, 0xfffd, 0xfffd, 0x8271, + 0xfffd, 0x7dd8, 0x7e6d, 0x6aa2, 0xfffd, 0xfffd, 0x9e7c, 0x63c0, + 0x64bf, 0x7c21, 0x5109, 0xfffd, 0xfffd, 0x85a6, 0x6abb, 0x9452, + 0x8e10, 0x8ce4, 0x898b, 0x9375, 0xfffd, 0xfffd, + /* 0x3d */ + 0xfffd, 0x8266, 0x528d, 0x991e, 0x6f38, 0x6ffa, 0x6f97, 0xfffd, + 0xfffd, 0xfffd, 0x5c07, 0x6f3f, 0xfffd, 0xfffd, 0x8523, 0x69f3, + 0x596c, 0x8b1b, 0xfffd, 0x91ac, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x81a0, 0xfffd, 0xfffd, 0x6f86, 0x9a55, 0x5b0c, 0xfffd, + 0x652a, 0x9278, 0x77ef, 0x50e5, 0xfffd, 0xfffd, 0xfffd, 0x9903, + 0x7e73, 0x7d5e, 0xfffd, 0xfffd, 0xfffd, 0x8f4e, 0x8f03, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x968e, 0xfffd, + 0xfffd, 0x7bc0, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6f54, + 0x7d50, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x8aa1, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x7dca, 0x9326, 0x50c5, 0x8b39, 0x9032, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x71fc, 0xfffd, + /* 0x3e */ + 0x76e1, 0x52c1, 0xfffd, 0xfffd, 0x8396, 0xfffd, 0xfffd, 0x9be8, + 0xfffd, 0x9a5a, 0xfffd, 0xfffd, 0x7d93, 0xfffd, 0xfffd, 0xfffd, + 0x9838, 0xfffd, 0xfffd, 0xfffd, 0x93e1, 0x5f91, 0x75d9, 0xfffd, + 0xfffd, 0x7af6, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7cfe, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x820a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x99d2, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x8209, 0xfffd, 0xfffd, 0xfffd, 0x64da, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x92f8, 0xfffd, 0xfffd, 0x61fc, 0xfffd, 0x5287, 0xfffd, + 0x9d51, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7d79, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x89ba, 0xfffd, 0x8a23, 0x7d76, + 0xfffd, 0xfffd, 0x921e, 0x8ecd, 0xfffd, 0xfffd, + /* 0x3f */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x99ff, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x958b, 0xfffd, 0xfffd, 0x51f1, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9846, 0xfffd, 0x6bbb, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8ab2, 0xfffd, 0xfffd, + 0x58be, 0x61c7, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x6473, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x5eab, 0x8932, 0x8a87, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x584a, 0xfffd, 0x5108, 0xfffd, 0x5bec, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x7926, 0xfffd, 0x66e0, 0xfffd, 0x8667, 0xfffd, + 0x5dcb, 0x7aba, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x40 */ + 0x994b, 0xfffd, 0x6f70, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x64f4, 0xfffd, 0x95ca, 0xfffd, 0xfffd, 0xfffd, 0x881f, 0x81d8, + 0xfffd, 0xfffd, 0x840a, 0x4f86, 0x8cf4, 0x85cd, 0xfffd, 0x6b04, + 0x6514, 0x7c43, 0x95cc, 0x862d, 0x703e, 0x8b95, 0x652c, 0x89bd, + 0x61f6, 0x7e9c, 0x721b, 0x6feb, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x6488, 0x52de, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x6f87, 0xfffd, 0x6a02, 0xfffd, 0x9433, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x58d8, 0xfffd, 0xfffd, 0x985e, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x7c6c, 0xfffd, 0x96e2, 0x7055, 0xfffd, 0xfffd, 0x88cf, 0x9bc9, + 0x79ae, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9e97, 0x53b2, 0x52f5, + 0x792b, 0x6b77, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x41 */ + 0xfffd, 0xfffd, 0xfffd, 0x701d, 0x96b8, 0xfffd, 0xfffd, 0xfffd, + 0x5006, 0x806f, 0x84ee, 0x9023, 0x942e, 0xfffd, 0x6190, 0x6f23, + 0x7c3e, 0x6582, 0x81c9, 0x93c8, 0x6200, 0x7149, 0x7df4, 0x7ce7, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5169, 0x8f1b, 0xfffd, 0xfffd, + 0xfffd, 0x8ad2, 0xfffd, 0xfffd, 0xfffd, 0x7642, 0xfffd, 0xfffd, + 0x907c, 0xfffd, 0xfffd, 0xfffd, 0x9410, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x7375, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x81e8, 0x9130, 0x9c57, 0xfffd, 0xfffd, 0x8cc3, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x9f61, 0x9234, 0xfffd, 0xfffd, 0xfffd, + 0x9748, 0xfffd, 0x5dba, 0x9818, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x993e, 0xfffd, 0x5289, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x9f8d, 0x807e, 0x56a8, 0x7c60, 0xfffd, + /* 0x42 */ + 0xfffd, 0x58df, 0x650f, 0x96b4, 0x6a13, 0x5a41, 0x645f, 0x7c0d, + 0xfffd, 0xfffd, 0x8606, 0x76e7, 0x9871, 0x5eec, 0x7210, 0x64c4, + 0x6ef7, 0x865c, 0x9b6f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8cc2, + 0xfffd, 0xfffd, 0xfffd, 0x9332, 0x9678, 0xfffd, 0x9a62, 0xfffd, + 0x92c1, 0xfffd, 0xfffd, 0xfffd, 0x5c62, 0x7e37, 0x616e, 0xfffd, + 0xfffd, 0xfffd, 0x6ffe, 0x7dd1, 0x5dd2, 0x6523, 0x5b7f, 0x7064, + 0xfffd, 0x4e82, 0xfffd, 0xfffd, 0x6384, 0x8f2a, 0x502b, 0x4f96, + 0x6dea, 0x7db8, 0x8ad6, 0x863f, 0xfffd, 0x7f85, 0x908f, 0x947c, + 0x7c6e, 0x9a3e, 0xfffd, 0xfffd, 0xfffd, 0x99f1, 0x7d61, 0x5abd, + 0xfffd, 0x746a, 0x78bc, 0x879e, 0x99ac, 0x99e1, 0xfffd, 0x55ce, + 0xfffd, 0x8cb7, 0x9ea5, 0x8ce3, 0x9081, 0xfffd, 0x779e, 0x9945, + 0x883b, 0x6eff, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x43 */ + 0x8b3e, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x9328, 0xfffd, 0xfffd, 0x925a, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x8cbf, 0x9ebd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9382, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9580, 0x60b6, 0x5011, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x9333, 0xfffd, 0x5922, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8b0e, 0x5f4c, 0xfffd, 0xfffd, + 0x8993, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7dbf, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7dec, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5edf, 0xfffd, 0xfffd, 0x6ec5, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x61ab, 0x95a9, 0xfffd, 0xfffd, + 0x9cf4, 0x9298, 0xfffd, 0xfffd, 0x8b2c, 0xfffd, + /* 0x44 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x8b00, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x755d, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9209, 0xfffd, 0xfffd, + 0x7d0d, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x96e3, 0xfffd, 0x6493, 0x8166, 0x60f1, 0x9b27, 0xfffd, 0xfffd, + 0x9912, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x64ec, 0xfffd, 0xfffd, 0x81a9, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x6506, 0xfffd, 0xfffd, 0xfffd, 0x91c0, + 0x9ce5, 0xfffd, 0xfffd, 0x8076, 0xfffd, 0x5699, 0x9477, 0x93b3, + 0xfffd, 0xfffd, 0x6ab8, 0x7370, 0xfffd, 0x5be7, + /* 0x45 */ + 0x64f0, 0x6fd8, 0xfffd, 0xfffd, 0x9215, 0x7d10, 0x81bf, 0x6fc3, + 0x8fb2, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x7627, 0xfffd, 0xfffd, 0xfffd, 0x8afe, 0xfffd, 0x6b50, 0x9dd7, + 0x6bc6, 0xfffd, 0x5614, 0xfffd, 0x6f1a, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x76e4, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x9f90, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x8ce0, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5674, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x9d6c, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x46 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9a19, 0x98c4, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x983b, 0x8ca7, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x860b, 0xfffd, 0xfffd, 0x6191, 0xfffd, 0x8a55, + 0xfffd, 0xfffd, 0x6f51, 0x9817, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x64b2, 0x92ea, 0x50d5, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x6a38, 0xfffd, 0xfffd, 0xfffd, 0x8b5c, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x81cd, 0x9f4a, 0xfffd, 0xfffd, 0xfffd, 0x9a0e, 0xfffd, + 0x8c48, 0xfffd, 0xfffd, 0x5553, 0xfffd, 0xfffd, 0xfffd, 0x6c23, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8a16, 0xfffd, + /* 0x47 */ + 0xfffd, 0xfffd, 0x727d, 0xfffd, 0x91fa, 0x925b, 0xfffd, 0x9077, + 0x7c3d, 0xfffd, 0x8b19, 0xfffd, 0xfffd, 0x9322, 0x9257, 0xfffd, + 0xfffd, 0xfffd, 0x6dfa, 0x8b74, 0x5879, 0xfffd, 0xfffd, 0xfffd, + 0x69cd, 0x55c6, 0xfffd, 0xfffd, 0x58bb, 0x8594, 0xfffd, 0x6436, + 0xfffd, 0x936c, 0xfffd, 0xfffd, 0x6a4b, 0xfffd, 0x55ac, 0x50d1, + 0xfffd, 0xfffd, 0xfffd, 0x7ff9, 0xfffd, 0xfffd, 0x7ac5, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x7aca, 0x6b3d, 0xfffd, 0x89aa, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5be2, 0xfffd, 0xfffd, + 0x8f15, 0x6c2b, 0x50be, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x9803, 0x8acb, 0x6176, 0x74ca, 0x7aae, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8da8, 0x5340, + 0xfffd, 0xfffd, 0x8ec0, 0xfffd, 0x9a45, 0xfffd, + /* 0x48 */ + 0xfffd, 0xfffd, 0x9f72, 0xfffd, 0xfffd, 0xfffd, 0x9874, 0x6b0a, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x52f8, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9d72, 0xfffd, 0x78ba, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x8b93, 0x9952, 0x64fe, 0x7e5e, 0xfffd, 0x71b1, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x97cc, 0xfffd, 0x8a8d, 0xfffd, + 0xfffd, 0x7d09, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x69ae, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7d68, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8edf, 0xfffd, 0xfffd, 0xfffd, + 0x92ed, 0x958f, 0x6f64, 0xfffd, 0xfffd, 0xfffd, 0x7051, 0x85a9, + 0xfffd, 0x9c13, 0xfffd, 0x8cfd, 0xfffd, 0xfffd, + /* 0x49 */ + 0x5098, 0xfffd, 0xfffd, 0xfffd, 0x55aa, 0xfffd, 0x9a37, 0x6383, + 0xfffd, 0xfffd, 0xfffd, 0x6f80, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x6bba, 0xfffd, 0xfffd, 0x7d17, 0xfffd, 0xfffd, 0xfffd, 0x7be9, + 0x66ec, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x9583, 0x965d, 0xfffd, 0x8d0d, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x7e55, 0xfffd, 0x50b7, 0xfffd, 0x8cde, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x71d2, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x7d39, 0xfffd, 0x8cd2, 0xfffd, 0xfffd, + 0x6368, 0xfffd, 0x651d, 0xfffd, 0x61fe, 0xfffd, 0xfffd, 0x8a2d, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7d33, + 0xfffd, 0xfffd, 0x5be9, 0x5b38, 0xfffd, 0x814e, 0xfffd, 0x6ef2, + 0x8072, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7e69, + /* 0x4a */ + 0xfffd, 0xfffd, 0xfffd, 0x52dd, 0x8056, 0x5e2b, 0xfffd, 0x7345, + 0xfffd, 0x6fd5, 0x8a69, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x6642, 0xfffd, 0xfffd, 0x8755, 0x5be6, 0x8b58, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x99db, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x52e2, 0xfffd, 0xfffd, + 0xfffd, 0x9069, 0xfffd, 0xfffd, 0x91cb, 0x98fe, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x8996, 0x8a66, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x58fd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7378, 0xfffd, 0x6a1e, + 0xfffd, 0xfffd, 0xfffd, 0x8f38, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x66f8, 0x8d16, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x5c6c, 0x8853, 0xfffd, 0x6a39, 0xfffd, + 0xfffd, 0x7aea, 0xfffd, 0xfffd, 0x6578, 0xfffd, + /* 0x4b */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5e25, 0xfffd, + 0xfffd, 0xfffd, 0x96d9, 0xfffd, 0x8ab0, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x9806, 0xfffd, 0x8aac, 0x78a9, 0xfffd, 0x720d, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7d72, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x98fc, 0xfffd, + 0x9b06, 0x8073, 0x616b, 0x980c, 0xfffd, 0xfffd, 0x8a1f, 0x8aa6, + 0xfffd, 0xfffd, 0x64fb, 0xfffd, 0x8607, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8a34, 0x8085, + 0xfffd, 0xfffd, 0xfffd, 0x96d6, 0xfffd, 0x96a8, 0x7d8f, 0xfffd, + 0xfffd, 0x6b72, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5b6b, 0x640d, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7e2e, 0x7463, 0xfffd, 0x9396, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x4c */ + 0x737a, 0x64bb, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x81fa, + 0xfffd, 0xfffd, 0xfffd, 0x614b, 0xfffd, 0xfffd, 0x6524, 0x8caa, + 0x7671, 0x7058, 0x58c7, 0xfffd, 0xfffd, 0xfffd, 0x8b5a, 0x8ac7, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5606, 0xfffd, 0x6e6f, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x71d9, 0xfffd, 0x6fe4, 0xfffd, 0x7e27, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8a0e, 0xfffd, 0xfffd, + 0xfffd, 0x9a30, 0xfffd, 0x8b04, 0xfffd, 0xfffd, 0xfffd, 0x92bb, + 0xfffd, 0x984c, 0xfffd, 0xfffd, 0x9ad4, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x689d, 0xfffd, 0xfffd, 0xfffd, + 0x8cbc, 0x9435, 0xfffd, 0x5ef3, 0x807d, 0x70f4, + /* 0x4d */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9285, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x7d71, 0xfffd, 0xfffd, 0xfffd, 0x982d, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x5716, 0xfffd, 0xfffd, 0x5857, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5718, 0xfffd, 0x983d, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x9d15, 0xfffd, 0x99b1, 0x99dd, 0x6a62, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7aaa, 0xfffd, 0xfffd, 0x896a, + 0xfffd, 0xfffd, 0xfffd, 0x5f4e, 0x7063, 0xfffd, 0x9811, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x842c, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7db2, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x4e */ + 0xfffd, 0xfffd, 0xfffd, 0x97cb, 0x9055, 0xfffd, 0x570d, 0xfffd, + 0xfffd, 0x7232, 0x6ff0, 0x7dad, 0x8466, 0xfffd, 0xfffd, 0x5049, + 0x50de, 0xfffd, 0x7def, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8b02, 0xfffd, 0xfffd, 0x885b, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x805e, 0x7d0b, 0xfffd, 0x7a69, + 0xfffd, 0x554f, 0xfffd, 0xfffd, 0xfffd, 0x64be, 0x8778, 0x6e26, + 0x7aa9, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x55da, + 0x93a2, 0x70cf, 0xfffd, 0x8aa3, 0xfffd, 0x7121, 0x856a, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x5862, 0xfffd, 0x9727, 0xfffd, 0xfffd, 0xfffd, + 0x52d9, 0xfffd, 0x8aa4, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x932b, 0x72a7, + /* 0x4f */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8972, 0xfffd, 0x7fd2, + 0xfffd, 0xfffd, 0x9291, 0xfffd, 0xfffd, 0xfffd, 0x6232, 0x7d30, + 0xfffd, 0x8766, 0xfffd, 0xfffd, 0x8f44, 0xfffd, 0x5cfd, 0x4fe0, + 0x72f9, 0xfffd, 0xfffd, 0xfffd, 0x5687, 0xfffd, 0x9341, 0xfffd, + 0xfffd, 0x9bae, 0x7e96, 0xfffd, 0x8ce2, 0x929c, 0xfffd, 0x9591, + 0xfffd, 0xfffd, 0xfffd, 0x986f, 0x96aa, 0x73fe, 0x737b, 0x7e23, + 0xfffd, 0x9921, 0xfffd, 0x61b2, 0xfffd, 0xfffd, 0x7dab, 0xfffd, + 0xfffd, 0x9472, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9109, 0xfffd, + 0xfffd, 0x8a73, 0xfffd, 0x97ff, 0xfffd, 0x9805, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x856d, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x56c2, 0x92b7, 0xfffd, 0xfffd, 0xfffd, 0x66c9, + /* 0x50 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x562f, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5354, 0x633e, 0xfffd, 0xfffd, + 0xfffd, 0x8105, 0x8ae7, 0x5beb, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x7009, 0x8b1d, 0xfffd, 0xfffd, 0xfffd, 0x92c5, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x91c1, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x8208, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x92b9, 0xfffd, 0xfffd, 0x7d89, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x9808, 0xfffd, 0x8a31, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7dd2, 0x7e8c, + 0x8ed2, 0xfffd, 0xfffd, 0x61f8, 0xfffd, 0xfffd, + /* 0x51 */ + 0x9078, 0x766c, 0xfffd, 0x7d62, 0xfffd, 0xfffd, 0x5b78, 0xfffd, + 0xfffd, 0xfffd, 0x52db, 0xfffd, 0xfffd, 0xfffd, 0x8a62, 0x5c0b, + 0x99b4, 0xfffd, 0xfffd, 0xfffd, 0x8a13, 0x8a0a, 0x905c, 0xfffd, + 0x58d3, 0xfffd, 0x9d09, 0x9d28, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x555e, 0x4e9e, 0x8a1d, + 0xfffd, 0xfffd, 0x95b9, 0xfffd, 0xfffd, 0x9e7d, 0x56b4, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9854, 0x95bb, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8277, 0xfffd, 0xfffd, + 0x53ad, 0x786f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8afa, + 0x9a57, 0xfffd, 0xfffd, 0x9d26, 0xfffd, 0x694a, 0x63da, 0xfffd, + 0x760d, 0xfffd, 0xfffd, 0x967d, 0xfffd, 0xfffd, 0x7662, 0x990a, + 0x6a23, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x52 */ + 0xfffd, 0x582f, 0xfffd, 0xfffd, 0x8b21, 0xfffd, 0xfffd, 0xfffd, + 0x85e5, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x723a, 0xfffd, + 0xfffd, 0xfffd, 0x9801, 0xfffd, 0x696d, 0x8449, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x91ab, 0xfffd, 0x92a5, 0xfffd, + 0xfffd, 0xfffd, 0x9824, 0xfffd, 0x907a, 0xfffd, 0x5100, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x87fb, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x85dd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x5104, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x61b6, 0x7fa9, 0xfffd, 0xfffd, 0x8a63, + 0x8b70, 0x8abc, 0x8b6f, 0xfffd, 0xfffd, 0xfffd, 0x7e79, 0xfffd, + 0x852d, 0xfffd, 0xfffd, 0xfffd, 0x9670, 0xfffd, 0xfffd, 0x9280, + 0xfffd, 0xfffd, 0x98f2, 0xfffd, 0xfffd, 0x96b1, + /* 0x53 */ + 0xfffd, 0xfffd, 0x6afb, 0x5b30, 0x9df9, 0x61c9, 0x7e93, 0x7469, + 0x87a2, 0x71df, 0x7192, 0x8805, 0xfffd, 0x8d0f, 0xfffd, 0xfffd, + 0x7a4e, 0xfffd, 0xfffd, 0x55b2, 0x64c1, 0x50ad, 0xfffd, 0x7670, + 0xfffd, 0xfffd, 0x8e34, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x512a, 0xfffd, 0x6182, 0xfffd, + 0xfffd, 0x90f5, 0x923e, 0x7336, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8a98, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8f3f, 0x9918, + 0xfffd, 0xfffd, 0x9b5a, 0xfffd, 0xfffd, 0x6f01, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x8207, 0x5dbc, 0xfffd, 0xfffd, 0x8a9e, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x9b31, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x7344, 0xfffd, 0x8b7d, + /* 0x54 */ + 0xfffd, 0xfffd, 0xfffd, 0x9810, 0xfffd, 0x99ad, 0x9d1b, 0x6df5, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8f45, 0x5712, + 0x54e1, 0x5713, 0xfffd, 0xfffd, 0x7de3, 0x9060, 0xfffd, 0x9858, + 0xfffd, 0xfffd, 0xfffd, 0x7d04, 0xfffd, 0x8e8d, 0x9470, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x95b2, 0xfffd, 0x96f2, 0x9116, 0xfffd, + 0x9695, 0xfffd, 0x904b, 0x85f4, 0x9196, 0x6688, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x96dc, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8f09, + 0xfffd, 0xfffd, 0xfffd, 0x6522, 0x66ab, 0x8d0a, 0x8d1c, 0x81df, + 0xfffd, 0xfffd, 0xfffd, 0x947f, 0xfffd, 0x68d7, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7ac8, 0xfffd, 0x8cac, + 0x64c7, 0x5247, 0x6fa4, 0x8cca, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x8d08, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8ecb, + /* 0x55 */ + 0x9358, 0x9598, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x8a50, 0xfffd, 0x9f4b, 0xfffd, 0xfffd, 0x50b5, 0xfffd, 0xfffd, + 0x6c08, 0xfffd, 0xfffd, 0xfffd, 0x76de, 0x65ac, 0x8f3e, 0x5d84, + 0xfffd, 0xfffd, 0x68e7, 0xfffd, 0x6230, 0xfffd, 0xfffd, 0x7dbb, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5f35, 0xfffd, 0x6f32, 0xfffd, + 0xfffd, 0x5e33, 0x8cec, 0xfffd, 0x8139, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x8d99, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x87c4, 0x8f4d, 0xfffd, 0x937a, + 0xfffd, 0x9019, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x8c9e, 0x91dd, 0x5075, 0xfffd, 0xfffd, 0x8a3a, 0xfffd, + 0xfffd, 0x93ae, 0x9663, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x56 */ + 0x5e40, 0x7665, 0x912d, 0x8b49, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7e54, 0x8077, + 0xfffd, 0xfffd, 0xfffd, 0x57f7, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x8879, 0xfffd, 0x7d19, 0xfffd, 0x646f, 0x64f2, + 0xfffd, 0xfffd, 0xfffd, 0x5e5f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x8cea, 0xfffd, 0xfffd, 0x6eef, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x9418, 0xfffd, 0x7d42, 0x7a2e, 0x816b, 0xfffd, + 0xfffd, 0x8846, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8b05, 0xfffd, + 0x8ef8, 0xfffd, 0xfffd, 0xfffd, 0x76ba, 0xfffd, 0x665d, 0x9a5f, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8af8, 0x8a85, 0xfffd, + 0xfffd, 0x71ed, 0xfffd, 0xfffd, 0x77da, 0x56d1, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x8caf, 0x9444, 0x7bc9, + /* 0x57 */ + 0xfffd, 0xfffd, 0xfffd, 0x99d0, 0xfffd, 0xfffd, 0xfffd, 0x5c08, + 0x78da, 0x8f49, 0xfffd, 0x8cfa, 0xfffd, 0x6a01, 0x838a, 0x88dd, + 0x599d, 0xfffd, 0x58ef, 0x72c0, 0xfffd, 0x9310, 0xfffd, 0x8d05, + 0x589c, 0x7db4, 0x8ac4, 0x6e96, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6fc1, 0xfffd, + 0xfffd, 0x8cc7, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6f2c, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x7d9c, 0x7e3d, 0x7e31, 0x9112, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8a5b, 0xfffd, + 0x7d44, 0x947d, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x58 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x55c7, 0xfffd, 0xfffd, 0x5399, 0xfffd, + 0x53b4, 0xfffd, 0xfffd, 0x9768, 0x8d0b, 0xfffd, 0xfffd, 0x532d, + 0x5331, 0xfffd, 0x8cfe, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x5244, 0xfffd, 0x528c, 0x5274, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x50b4, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5000, 0x5096, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x59 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5115, 0xfffd, 0x5102, 0xfffd, + 0x5114, 0x513c, 0x5137, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x50e8, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x50c2, 0x513b, 0x5110, 0x513a, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x50c9, 0xfffd, 0xfffd, 0xfffd, + 0x7cf4, 0xfffd, 0xfffd, 0x9ecc, 0xfffd, 0x56c5, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x9cec, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x893b, 0x81e0, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x5a */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8a01, 0x8a10, 0x8a0c, 0x8a15, + 0x8b33, 0x8a4e, 0x8a25, 0x8a41, 0x8a36, 0x8a46, 0x8a54, 0x8a58, + 0x8a52, 0x8a86, 0x8a84, 0x8a7f, 0x8a70, 0x8a7c, 0x8a75, 0x8a6c, + 0x8a6e, 0x8acd, 0x8ae2, 0x8a61, 0x8a9a, 0x8aa5, 0x8a91, 0x8a92, + 0x8acf, 0x8ad1, 0x8ac9, 0x8adb, 0x8ad7, 0x8ac2, 0x8ab6, 0x8af6, + 0x8aeb, 0x8b14, 0x8b01, 0x8ae4, 0x8aed, 0x8afc, 0x8af3, 0x8ae6, + 0x8aee, 0x8ade, 0x8b28, 0x8b9c, 0x8b16, 0x8b1a, 0x8b10, 0x8b2b, + 0x8b2d, 0x8b56, 0x8b59, 0x8b4e, 0x8b9e, 0x8b6b, 0x8b96, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x9658, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x913a, 0xfffd, + 0x9114, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9134, + /* 0x5b */ + 0xfffd, 0xfffd, 0x90df, 0xfffd, 0xfffd, 0x9136, 0xfffd, 0xfffd, + 0x9106, 0x9148, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x82bb, 0xfffd, 0x52f1, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5df0, 0xfffd, + 0x580a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x58d9, 0xfffd, 0xfffd, 0x58e2, 0xfffd, 0xfffd, + 0xfffd, 0x58e0, 0xfffd, 0x58da, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x57e1, 0xfffd, 0xfffd, 0x584f, 0xfffd, 0xfffd, + 0x5816, 0xfffd, 0xfffd, 0xfffd, 0x5852, 0x581d, 0x5864, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x5c */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x858c, 0xfffd, 0xfffd, 0x8553, 0xfffd, + 0xfffd, 0x85f6, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x83a7, + 0x8407, 0x84ef, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x82e7, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8622, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8526, + 0xfffd, 0xfffd, 0x584b, 0x7162, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x8558, 0x84fd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x854e, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8588, 0xfffd, 0xfffd, + 0x85ba, 0xfffd, 0xfffd, 0xfffd, 0x7296, 0x6ece, + /* 0x5d */ + 0x8541, 0xfffd, 0x85ce, 0x8552, 0x84c0, 0x8452, 0x8464, 0xfffd, + 0xfffd, 0x8494, 0x8435, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x859f, 0xfffd, 0xfffd, 0x8555, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x9daf, 0x8493, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x7e08, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x8546, 0xfffd, 0xfffd, 0x8562, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x851e, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x9a40, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x863a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x93a3, 0x8577, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x861e, 0xfffd, 0x85fa, + /* 0x5e */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8604, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x85ea, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x861a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5969, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5c37, 0xfffd, + 0x636b, 0x6476, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x649f, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x6451, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x645c, + 0xfffd, 0xfffd, 0xfffd, 0x64b3, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x6504, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x6516, 0xfffd, 0xfffd, + /* 0x5f */ + 0xfffd, 0x64f7, 0x64fc, 0xfffd, 0x651b, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x5630, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x5638, 0x56c8, 0xfffd, 0x56a6, 0xfffd, + 0xfffd, 0x5504, 0x54bc, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x5680, 0xfffd, 0xfffd, 0xfffd, 0x565d, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5660, 0xfffd, 0xfffd, 0x5635, + 0x55f6, 0xfffd, 0xfffd, 0x5666, 0xfffd, 0xfffd, 0xfffd, 0x5672, + 0xfffd, 0x568c, 0xfffd, 0xfffd, 0xfffd, 0x5665, 0xfffd, 0xfffd, + 0x561c, 0xfffd, 0x562e, 0xfffd, 0xfffd, 0xfffd, 0x55e9, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5616, 0xfffd, 0xfffd, 0xfffd, + 0x56c0, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x60 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x560d, 0x56b3, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x56c1, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x566f, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8f61, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x56b6, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5695, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5707, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5e43, + 0xfffd, 0xfffd, 0xfffd, 0x5e6c, 0x5e58, 0x5e57, + /* 0x61 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x5d87, 0xfffd, 0x5cf4, 0xfffd, 0xfffd, 0x5d50, + 0xfffd, 0xfffd, 0xfffd, 0x5d2c, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x5da7, 0xfffd, 0x5da0, 0xfffd, 0xfffd, 0x5d97, + 0x5d0d, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x5db8, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5d81, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x5dd4, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x540e, 0x5fa0, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7377, 0x7341, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x736a, 0xfffd, 0x733b, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x736b, 0xfffd, + /* 0x62 */ + 0xfffd, 0xfffd, 0xfffd, 0x7380, 0xfffd, 0xfffd, 0xfffd, 0x737c, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x98e0, 0x9933, 0x98e9, 0x993c, 0x98ea, 0x98eb, + 0x98ed, 0x98f4, 0x9909, 0x9911, 0x4f59, 0x991b, 0x9937, 0x993f, + 0x9943, 0x9948, 0x9949, 0x994a, 0x994c, 0x9962, 0xfffd, 0x5ee1, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x8ce1, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x61fa, 0x61ae, 0xfffd, 0x616a, 0xfffd, 0xfffd, + 0x613e, 0x60b5, 0x6134, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x61cc, + 0xfffd, 0x615f, 0x61e8, 0x60fb, 0x6137, 0xfffd, + /* 0x63 */ + 0xfffd, 0x60f2, 0xfffd, 0xfffd, 0x6173, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x611c, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x6192, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9582, 0x9586, 0x95c8, 0x958e, + 0x9594, 0x958c, 0x95e5, 0x95ad, 0x95ab, 0x9b2e, 0x95ac, 0x95be, + 0x95b6, 0x9b29, 0x95bf, 0x95bd, 0x95bc, 0x95c3, 0x95cb, 0x95d4, + 0x95d0, 0x95d5, 0x95de, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x7043, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6f59, 0xfffd, 0xfffd, 0xfffd, + 0x7027, 0x7018, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6ffc, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6d87, + /* 0x64 */ + 0xfffd, 0xfffd, 0xfffd, 0x6d79, 0x6e5e, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x6fae, 0xfffd, 0xfffd, 0xfffd, 0x700f, 0x6ef8, + 0x6f6f, 0xfffd, 0xfffd, 0xfffd, 0x6df6, 0x6f7f, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x7006, 0xfffd, 0xfffd, 0x6fa0, 0xfffd, 0xfffd, 0xfffd, + 0x700b, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x7067, 0xfffd, 0xfffd, 0x7044, 0xfffd, 0x7005, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x6f77, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x7020, 0x701f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x7032, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7028, + /* 0x65 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x705d, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x9a2b, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9087, 0xfffd, + 0x9015, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9090, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5c68, + 0xfffd, 0x5f33, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x5af5, 0x5ad7, 0xfffd, + /* 0x66 */ + 0xfffd, 0xfffd, 0x5b00, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x5a6d, 0x5b08, 0xfffd, 0x5b4c, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x5aa7, 0x5afb, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5b0b, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x5b21, + 0x5b2a, 0xfffd, 0xfffd, 0xfffd, 0x5b19, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x99d4, + 0x99df, 0x99d9, 0x9a36, 0x9a5b, 0x99d1, 0x99d8, 0x9a4d, 0x9a4a, + 0x99e2, 0x9a6a, 0x9a0f, 0x9a0d, 0x9a05, 0x9a42, 0x9a2d, 0x9a16, + 0x9a41, 0x9a2e, 0x9a38, 0x9a43, 0x9a44, 0x9a4f, 0x9a65, 0x9a64, + 0x7cf9, 0x7d06, 0x7d02, 0x7d07, 0x7d08, 0x7e8a, + /* 0x67 */ + 0x7d1c, 0x7d15, 0x7d13, 0x7d3a, 0x7d32, 0x7d31, 0x7e10, 0x7d3c, + 0x7d40, 0x7d3f, 0x7d5d, 0x7d4e, 0x7d73, 0x7d86, 0x7d83, 0x7d88, + 0x7dbe, 0x7dba, 0x7dcb, 0x7dd4, 0x7dc4, 0x7d9e, 0x7dac, 0x7db9, + 0x7da3, 0x7db0, 0x7dc7, 0x7dd9, 0x7dd7, 0x7df9, 0x7df2, 0x7e62, + 0x7de6, 0x7df6, 0x7df1, 0x7e0b, 0x7de1, 0x7e09, 0x7e1d, 0x7e1f, + 0x7e1e, 0x7e2d, 0x7e0a, 0x7e11, 0x7e7d, 0x7e39, 0x7e35, 0x7e32, + 0x7e46, 0x7e45, 0x7e88, 0x7e5a, 0x7e52, 0x7e6e, 0x7e7e, 0x7e70, + 0x7e6f, 0x7e98, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x74a3, 0x744b, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x74cf, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x980a, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x74bd, 0x743f, 0x7489, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x68 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x74a6, + 0xfffd, 0xfffd, 0xfffd, 0x74d4, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x74da, 0xfffd, 0x97d9, + 0x97de, 0x97dc, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x69aa, 0x6aea, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6898, 0xfffd, 0x68d6, 0x6a05, + 0x689f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6adb, 0xfffd, 0x6af3, + 0xfffd, 0xfffd, 0x6ae8, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6adf, 0xfffd, 0x6a89, 0xfffd, + 0xfffd, 0x690f, 0x6a48, 0xfffd, 0x6968, 0xfffd, 0x69bf, 0xfffd, + 0xfffd, 0xfffd, 0x6a3a, 0xfffd, 0x6a9c, 0xfffd, 0x6b12, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x6b1e, 0xfffd, 0xfffd, 0x6add, 0x69e7, 0xfffd, + /* 0x69 */ + 0x6b0f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6b16, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x6aec, 0x6ada, 0xfffd, 0x6af8, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x6ab3, 0xfffd, 0x6ae7, 0xfffd, 0xfffd, + 0x6aa3, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6ad3, 0xfffd, 0xfffd, + 0xfffd, 0x6ade, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x6ba4, 0xfffd, 0x6b9e, 0x6bae, 0xfffd, + 0x6bab, 0xfffd, 0x6baf, 0xfffd, 0x8ed4, 0x8edb, 0x8ef2, 0x8efb, + 0x8f64, 0x8ef9, 0x8efc, 0x8eeb, 0x8ee4, 0x8f62, 0x8efa, 0x8efe, + 0x8f0a, 0x8f07, 0x8f05, 0x8f12, 0x8f26, 0x8f1e, + /* 0x6a */ + 0x8f1f, 0x8f1c, 0x8f33, 0x8f46, 0x8f54, 0xfffd, 0x6214, 0x6227, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x750c, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x66c7, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x66c4, 0xfffd, 0xfffd, 0x6689, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x66d6, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x8cc1, 0x8cb0, 0x8cba, 0x8cbd, 0x8d04, 0x8cb2, 0x8cc5, + 0x8d10, 0x8cd1, 0x8cda, 0x8cd5, 0x8ceb, 0x8ce7, 0x8cfb, 0x8998, + 0x89ac, 0x89a1, 0x89bf, 0x89a6, 0x89af, 0x89b2, 0x89b7, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x6b */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6bff, 0xfffd, + 0xfffd, 0x6c0c, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x6c2c, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x7258, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x6727, 0x8156, 0xfffd, 0x81da, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x811b, 0xfffd, 0xfffd, + 0xfffd, 0x81be, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x8161, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x81cf, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x6c */ + 0xfffd, 0xfffd, 0x6b5f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x98ae, 0x98af, 0x98b6, 0x98bc, 0x98c6, 0x98c8, 0xfffd, 0xfffd, + 0x8f42, 0xfffd, 0xfffd, 0x9f4f, 0x6595, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x716c, 0x7152, 0xfffd, + 0x7197, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x71c1, 0xfffd, + 0xfffd, 0xfffd, 0x71dc, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x71fe, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x79b0, 0xfffd, 0xfffd, 0x798e, 0xfffd, 0xfffd, 0x79aa, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x6d */ + 0x61df, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x6164, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x61e3, 0x6207, + 0xfffd, 0xfffd, 0xfffd, 0x6fa9, 0xfffd, 0x78ef, 0xfffd, 0x78ad, + 0xfffd, 0x7868, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x78b8, 0xfffd, + 0xfffd, 0x792a, 0x7931, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x7864, 0x78fd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x78e7, 0xfffd, 0xfffd, 0xfffd, 0x78e3, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9f95, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7798, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x775e, 0x77bc, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x6e */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x7f86, 0xfffd, 0xfffd, 0x7f88, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x91d2, 0x91d3, 0x91d4, 0x91d9, 0x91d7, + 0x91d5, 0x91f7, 0x91e7, 0x91e4, 0x9346, 0x91f5, 0x91f9, 0x9208, + 0x9226, 0x9245, 0x9211, 0x9210, 0x9201, 0x9227, 0x9204, 0x9225, + 0x9200, 0x923a, 0x9266, 0x9237, 0x9233, 0x9255, 0x923d, 0x9238, + 0x925e, 0x926c, 0x926d, 0x923f, 0x9460, 0x9230, 0x9249, 0x9248, + 0x924d, 0x922e, 0x9239, 0x9438, 0x92ac, 0x92a0, 0x927a, 0x92aa, + 0x92ee, 0x92cf, 0x9403, 0x92e3, 0x943a, 0x92b1, 0x92a6, 0x93a7, + 0x9296, 0x92cc, 0x92a9, 0x93f5, 0x9293, 0x927f, + /* 0x6f */ + 0x93a9, 0x929a, 0x931a, 0x92ab, 0x9283, 0x940b, 0x92a8, 0x92a3, + 0x9412, 0x9338, 0x92f1, 0x93d7, 0x92e5, 0x92f0, 0x92ef, 0x92e8, + 0x92bc, 0x92dd, 0x92f6, 0x9426, 0x9427, 0x92c3, 0x92df, 0x92e6, + 0x9312, 0x9306, 0x9369, 0x931b, 0x9340, 0x9301, 0x9315, 0x932e, + 0x9343, 0x9307, 0x9308, 0x931f, 0x9319, 0x9365, 0x9347, 0x9376, + 0x9354, 0x9364, 0x93aa, 0x9370, 0x9384, 0x93e4, 0x93d8, 0x9428, + 0x9387, 0x93cc, 0x9398, 0x93b8, 0x93bf, 0x93a6, 0x93b0, 0x93b5, + 0x944c, 0x93e2, 0x93dc, 0x93dd, 0x93cd, 0x93de, 0x93c3, 0x93c7, + 0x93d1, 0x9414, 0x941d, 0x93f7, 0x9465, 0x9413, 0x946d, 0x9420, + 0x9479, 0x93f9, 0x9419, 0x944a, 0x9432, 0x943f, 0x9454, 0x9463, + 0x937e, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x70 */ + 0xfffd, 0xfffd, 0x7a61, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9ce9, 0x9cf6, + 0x9d07, 0x9d06, 0x9d23, 0x9d87, 0x9e15, 0x9d1d, 0x9d1f, 0x9de5, + 0x9d2f, 0x9dd9, 0x9d30, 0x9d42, 0x9e1e, 0x9d53, 0x9e1d, 0x9d60, + 0x9d52, 0x9df3, 0x9d5c, 0x9d61, 0x9d93, 0x9d6a, 0x9d6f, 0x9d89, + 0x9d98, 0x9d9a, 0x9dc0, 0x9da5, 0x9da9, 0x9dc2, 0x9dbc, 0x9e1a, + 0x9dd3, 0x9dda, 0x9def, 0x9de6, 0x9df2, 0x9df8, 0x9e0c, 0x9dfa, + 0x9e1b, 0xfffd, 0xfffd, 0x7664, 0x7658, 0xfffd, 0x7667, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x7602, 0xfffd, 0xfffd, 0x7646, 0xfffd, 0xfffd, 0x7647, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7649, 0xfffd, + 0x761e, 0xfffd, 0xfffd, 0x763b, 0xfffd, 0xfffd, + /* 0x71 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x766d, + 0xfffd, 0xfffd, 0x766e, 0xfffd, 0xfffd, 0x7669, 0xfffd, 0xfffd, + 0xfffd, 0x7672, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x7ac7, 0xfffd, 0xfffd, 0xfffd, 0x7ab6, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x8960, 0xfffd, 0xfffd, 0xfffd, 0x8933, 0xfffd, 0x895d, 0x8947, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x8938, 0xfffd, 0x8964, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x76b8, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x802e, 0xfffd, 0xfffd, 0x802c, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8079, 0xfffd, + 0x8075, 0xfffd, 0xfffd, 0x9807, 0x980e, 0x980f, + /* 0x72 */ + 0x9821, 0x981c, 0x6f41, 0x9826, 0x9837, 0x984e, 0x9853, 0x9873, + 0x9862, 0x9859, 0x9865, 0x986c, 0x9870, 0xfffd, 0xfffd, 0xfffd, + 0x87e3, 0x8806, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x8706, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x8823, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x87f6, 0xfffd, 0xfffd, 0x86fa, 0x87ef, 0xfffd, 0x8784, 0xfffd, + 0xfffd, 0xfffd, 0x8810, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x87c8, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8811, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x87bb, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x87ce, 0xfffd, + /* 0x73 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7f4c, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7be4, 0xfffd, 0x7b67, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7c69, 0xfffd, 0xfffd, + 0x7bf3, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7c00, 0x7bcb, 0xfffd, 0xfffd, + 0xfffd, 0x7c5c, 0xfffd, 0x7c1e, 0xfffd, 0xfffd, 0x7c2b, 0xfffd, + 0x7c23, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7c6a, 0xfffd, + /* 0x74 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7c5f, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8264, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x826b, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x88ca, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7fa5, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7cf2, 0x7cf6, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x7cdd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x7e36, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9ea9, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8db2, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x75 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x91c5, 0x91c3, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x9e7a, 0x8e89, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x8e4c, 0xfffd, 0xfffd, 0xfffd, 0x8e92, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8e7a, 0x8e55, 0xfffd, + 0x8e9a, 0x8e8b, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x8e93, 0xfffd, 0xfffd, 0x8e91, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8ea1, 0x8e63, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8eaa, 0xfffd, + 0xfffd, 0x8ea6, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x89f4, 0xfffd, 0xfffd, + /* 0x76 */ + 0xfffd, 0xfffd, 0x89f6, 0xfffd, 0xfffd, 0x975a, 0xfffd, 0x9742, + 0xfffd, 0xfffd, 0x973d, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9744, + 0xfffd, 0xfffd, 0x9f54, 0x9f5f, 0x9f59, 0x9f60, 0x9f5c, 0x9f66, + 0x9f6c, 0x9f6a, 0x9f77, 0x9efd, 0x9eff, 0x9f09, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x8b8e, 0xfffd, 0x947e, 0xfffd, + 0x93e8, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9b77, 0x9b74, + 0x9b81, 0x9b83, 0x9b8e, 0x9c78, 0x7a4c, 0x9b92, 0x9c5f, 0x9b90, + 0x9bad, 0x9b9a, 0x9baa, 0x9b9e, 0x9c6d, 0x9bab, 0x9b9d, 0x9c58, + 0x9bc1, 0x9c7a, 0x9c31, 0x9c39, 0x9c23, 0x9c37, 0x9bc0, 0x9bca, + 0x9bc7, 0x9bfd, 0x9bd6, 0x9bea, 0x9beb, 0x9be1, 0x9be4, 0x9be7, + 0x9bdd, 0x9be2, 0x9bf0, 0x9bdb, 0x9bf4, 0x9bd4, 0x9c5d, 0x9c08, + 0x9c10, 0x9c0d, 0x9c12, 0x9c09, 0x9bff, 0x9c20, + /* 0x77 */ + 0x9c32, 0x9c2d, 0x9c28, 0x9c25, 0x9c29, 0x9c33, 0x9c3e, 0x9c48, + 0x9c3b, 0x9c35, 0x9c45, 0x9c56, 0x9c54, 0x9c52, 0x9c67, 0xfffd, + 0xfffd, 0x97c3, 0x97bd, 0xfffd, 0x97c9, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9dbb, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x9acf, 0xfffd, 0x9ad6, 0x9ad5, 0xfffd, 0xfffd, + 0xfffd, 0x9b58, 0x9b4e, 0xfffd, 0xfffd, 0xfffd, 0x9957, 0x995c, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x9b22, 0xfffd, 0xfffd, + 0x4e48, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x9ef7, 0xfffd, 0xfffd, 0x9ef2, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x78 */ + 0x896c, 0x95c6, 0x9336, 0x5f46, 0x8514, 0x7e94, 0x5382, 0x51b2, + 0x4e11, 0x9f63, 0x5679, 0x515a, 0x6dc0, 0x9f15, 0x6597, 0x5641, + 0x9aee, 0x8303, 0x4e30, 0x8907, 0x5e72, 0x7a40, 0x98b3, 0x5e7f, + 0x95a4, 0x9b0d, 0x5212, 0x8ff4, 0x5f59, 0x7a6b, 0x98e2, 0x51e0, + 0x50a2, 0x4ef7, 0x8350, 0x8591, 0x5118, 0x636e, 0x6372, 0x524b, + 0x5938, 0x774f, 0x8721, 0x814a, 0x7e8d, 0x91cc, 0x66c6, 0x5e18, + 0x77ad, 0x9e75, 0x56c9, 0x9ef4, 0x6fdb, 0x61de, 0x77c7, 0x7030, + 0x9eb5, 0x884a, 0x95e2, 0x82f9, 0x51ed, 0x6251, 0x4ec6, 0x6734, + 0x97c6, 0x7c64, 0x7e34, 0x97a6, 0x9eaf, 0x786e, 0x820d, 0x672f, + 0x677e, 0x56cc, 0x53f0, 0x98b1, 0x6aaf, 0x7f4e, 0x6d82, 0x7cf0, + 0x4e07, 0x4fc2, 0x7e6b, 0x9e79, 0x56ae, 0x9b1a, 0x846f, 0x53f6, + 0x90c1, 0x79a6, 0x7c72, 0x613f, 0x4e91, 0x9ad2, + /* 0x79 */ + 0x75c7, 0x96bb, 0x53ea, 0x7dfb, 0x88fd, 0x79cd, 0x7843, 0x7b51, + 0x51c6, +}; + +static int +gb12345ext_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 == 0x21) || (c1 == 0x26) || (c1 == 0x28) || (c1 >= 0x30 && c1 <= 0x79)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + unsigned short wc = 0xfffd; + if (i < 470) { + if (i < 12) + wc = gb12345ext_2uni_page21[i]; + } else if (i < 658) { + if (i < 555) + wc = gb12345ext_2uni_page26[i-470]; + } else if (i < 1410) { + if (i < 690) + wc = gb12345ext_2uni_page28[i-658]; + } else { + if (i < 8281) + wc = gb12345ext_2uni_page30[i-1410]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short gb12345ext_2charset[2252] = { + 0x283d, 0x283e, 0x283f, 0x283b, 0x2840, 0x283c, 0x212c, 0x7871, + 0x7829, 0x7833, 0x7761, 0x4252, 0x787d, 0x5147, 0x785f, 0x7842, + 0x6245, 0x4034, 0x4258, 0x7872, 0x4f40, 0x5876, 0x4129, 0x3256, + 0x3876, 0x4347, 0x4257, 0x4e30, 0x3260, 0x556c, 0x5877, 0x4921, + 0x3138, 0x7841, 0x5336, 0x342b, 0x5871, 0x552e, 0x494b, 0x4763, + 0x594d, 0x3d76, 0x595d, 0x4748, 0x464d, 0x4e31, 0x3d44, 0x5947, + 0x3c5b, 0x5247, 0x592f, 0x525a, 0x3f6b, 0x3c73, 0x594f, 0x5931, + 0x592d, 0x7845, 0x3325, 0x5345, 0x3422, 0x5933, 0x5950, 0x594e, + 0x5932, 0x3679, 0x782c, 0x413d, 0x7828, 0x7929, 0x3633, 0x7840, + 0x785d, 0x3f2d, 0x783b, 0x5859, 0x5472, 0x7848, 0x3855, 0x3950, + 0x585c, 0x3434, 0x3b2e, 0x3e67, 0x4175, 0x3974, 0x585b, 0x3d23, + 0x3c41, 0x3e22, 0x362f, 0x4e71, 0x512b, 0x4a24, 0x404d, 0x4a46, + 0x5b3d, 0x4078, 0x4830, 0x5850, 0x3b63, 0x5851, 0x4778, 0x502d, + 0x7827, 0x5847, 0x325e, 0x5161, 0x4077, 0x5849, 0x324e, 0x3454, + 0x7923, 0x786b, 0x7878, 0x6161, 0x5f43, 0x5431, 0x5f42, 0x4e4a, + 0x4674, 0x5146, 0x4925, 0x4747, 0x3525, 0x5334, 0x473a, 0x5844, + 0x4270, 0x4e58, 0x5f6f, 0x5f59, 0x4c3e, 0x6036, 0x453b, 0x5f75, + 0x3322, 0x5f69, 0x3b29, 0x5f6b, 0x5025, 0x5f34, 0x5f58, 0x5f3c, + 0x7830, 0x5f50, 0x5f55, 0x5f66, 0x5f5c, 0x6048, 0x5f60, 0x4567, + 0x3656, 0x782b, 0x5f4c, 0x4f45, 0x5f62, 0x6060, 0x4476, 0x5f3f, + 0x417c, 0x7875, 0x6037, 0x514f, 0x6053, 0x5f79, 0x603f, 0x4f79, + 0x5966, 0x5f3d, 0x7853, 0x786a, 0x5676, 0x6070, 0x397a, 0x4e27, + 0x5430, 0x5432, 0x4d3c, 0x4d45, 0x5b6b, 0x5634, 0x3c61, 0x5b51, + 0x5b71, 0x5b76, 0x5222, 0x3128, 0x3321, 0x3f69, 0x5c63, 0x5b6e, + 0x5b75, 0x4d3f, 0x4e6b, 0x5b77, 0x333e, 0x4735, 0x3566, 0x5739, + 0x3669, 0x3758, 0x473d, 0x3f51, 0x4c33, 0x5139, 0x405d, 0x5b5b, + 0x5b64, 0x3b35, 0x4222, 0x5b62, 0x5b5e, 0x3053, 0x5733, 0x3a78, + 0x4a59, 0x434e, 0x7849, 0x3c50, 0x5e46, 0x3661, 0x3d31, 0x375c, + 0x5731, 0x4226, 0x383e, 0x662b, 0x6634, 0x4268, 0x657d, 0x657c, + 0x6635, 0x6623, 0x662c, 0x663f, 0x3d3f, 0x664d, 0x6648, 0x6649, + 0x5324, 0x4974, 0x662e, 0x4b6f, 0x5127, 0x424f, 0x475e, 0x4a35, + 0x447e, 0x4973, 0x5034, 0x3f6d, 0x3368, 0x3126, 0x3d2b, 0x5728, + 0x5130, 0x3654, 0x353c, 0x5e4f, 0x4245, 0x3263, 0x6570, 0x4a74, + 0x3854, 0x612d, 0x353a, 0x4f3f, 0x6141, 0x385a, 0x6134, 0x6130, + 0x6150, 0x5538, 0x612b, 0x6140, 0x613d, 0x613b, 0x6149, 0x416b, + 0x536c, 0x3f79, 0x424d, 0x615b, 0x5b4f, 0x7850, 0x4b27, 0x4a26, + 0x554a, 0x3478, 0x5621, 0x6078, 0x607e, 0x607d, 0x5644, 0x3152, + 0x306f, 0x607c, 0x7835, 0x3849, 0x3c38, 0x7838, 0x3f62, 0x436d, + 0x3327, 0x6250, 0x374f, 0x3963, 0x422e, 0x4c7c, 0x6572, 0x5545, + 0x7824, 0x352f, 0x4356, 0x4d64, 0x783d, 0x3a73, 0x3e36, 0x3453, + 0x6162, 0x3834, 0x3339, 0x626a, 0x4346, 0x3671, 0x4455, 0x6322, + 0x627c, 0x302e, 0x632b, 0x626b, 0x627d, 0x6269, 0x787c, 0x4c2c, + 0x3252, 0x3251, 0x627a, 0x395f, 0x6d28, 0x6266, 0x4b4b, 0x4247, + 0x6325, 0x476c, 0x5347, 0x3139, 0x412f, 0x463e, 0x6334, 0x352c, + 0x375f, 0x4375, 0x6264, 0x4f5c, 0x5264, 0x3f52, 0x5326, 0x6278, + 0x7856, 0x6d21, 0x6d2f, 0x627b, 0x334d, 0x4041, 0x3b33, 0x507c, + 0x6263, 0x3e65, 0x4965, 0x4135, 0x6d30, 0x6a27, 0x6a28, 0x553d, + 0x4f37, 0x785e, 0x502e, 0x4961, 0x5e51, 0x7846, 0x7847, 0x4928, + 0x4255, 0x3c70, 0x516f, 0x3b53, 0x4b70, 0x3537, 0x4740, 0x5e62, + 0x5e68, 0x4227, 0x563f, 0x3f59, 0x5e52, 0x3274, 0x404c, 0x4453, + 0x5e58, 0x3527, 0x3226, 0x3827, 0x464b, 0x5e6c, 0x4c22, 0x4e4e, + 0x3c71, 0x5335, 0x4230, 0x5471, 0x3b77, 0x3532, 0x3523, 0x3e5d, + 0x3c37, 0x4462, 0x3177, 0x4521, 0x3869, 0x5640, 0x4029, 0x5f22, + 0x305a, 0x4b53, 0x5f23, 0x4845, 0x5e73, 0x446c, 0x4223, 0x4039, + 0x5e7c, 0x3273, 0x5f25, 0x4963, 0x545c, 0x424e, 0x4c2f, 0x3d41, + 0x403f, 0x305c, 0x3550, 0x4a7d, 0x4132, 0x3150, 0x6c35, 0x782f, + 0x5536, 0x364f, 0x4a31, 0x5667, 0x544e, 0x6a4d, 0x3329, 0x545d, + 0x6a4a, 0x784f, 0x6a3c, 0x4f7e, 0x6a53, 0x3f75, 0x4939, 0x4a69, + 0x3b61, 0x6b4a, 0x7868, 0x7860, 0x362b, 0x7869, 0x6845, 0x4c75, + 0x6849, 0x6847, 0x5466, 0x3630, 0x553b, 0x6862, 0x516e, 0x3763, + 0x6865, 0x5235, 0x3c2b, 0x683f, 0x4859, 0x6867, 0x3939, 0x4739, + 0x687d, 0x3d30, 0x572e, 0x4056, 0x6848, 0x4225, 0x316a, 0x4a60, + 0x5179, 0x4653, 0x4a77, 0x686b, 0x6863, 0x4745, 0x3b7a, 0x4d56, + 0x685f, 0x3535, 0x686d, 0x3c6c, 0x6949, 0x786d, 0x6944, 0x447b, + 0x3c77, 0x3971, 0x6956, 0x6935, 0x684e, 0x687c, 0x695a, 0x685d, + 0x6946, 0x6853, 0x6840, 0x6934, 0x6850, 0x6937, 0x5323, 0x4038, + 0x4828, 0x6921, 0x686f, 0x692d, 0x6879, 0x4755, 0x4537, 0x6c23, + 0x3b36, 0x4b6a, 0x407a, 0x3969, 0x3250, 0x6966, 0x6964, 0x6969, + 0x6967, 0x696b, 0x3c5f, 0x4931, 0x3f47, 0x4539, 0x6b27, 0x5531, + 0x6b2a, 0x4678, 0x4762, 0x6b32, 0x6424, 0x786f, 0x637e, 0x782d, + 0x4259, 0x5428, 0x6435, 0x4733, 0x4e50, 0x3262, 0x3b6b, 0x6425, + 0x4c40, 0x573c, 0x3935, 0x3257, 0x4370, 0x3553, 0x5c7e, 0x3b26, + 0x564d, 0x4978, 0x4231, 0x6430, 0x427a, 0x5366, 0x453d, 0x3a3a, + 0x4130, 0x5755, 0x5547, 0x3d25, 0x3d2c, 0x7223, 0x4643, 0x3d60, + 0x636d, 0x4873, 0x6431, 0x4023, 0x6464, 0x6436, 0x492c, 0x3d3d, + 0x4054, 0x3d27, 0x6445, 0x5473, 0x6d34, 0x642b, 0x356d, 0x5747, + 0x4528, 0x4a2a, 0x4522, 0x7855, 0x3c43, 0x4c4e, 0x4044, 0x4e2b, + 0x3175, 0x3d26, 0x6378, 0x424b, 0x645e, 0x6442, 0x503a, 0x6449, + 0x642f, 0x3174, 0x6372, 0x4124, 0x646c, 0x646b, 0x6371, 0x647e, + 0x7858, 0x6472, 0x403d, 0x6363, 0x645c, 0x4877, 0x406c, 0x4c32, + 0x6530, 0x4d65, 0x4250, 0x6459, 0x4e5a, 0x4c7e, 0x4e5e, 0x4136, + 0x6c3f, 0x5c64, 0x3733, 0x6c3e, 0x532b, 0x6c41, 0x4848, 0x3363, + 0x6c47, 0x3546, 0x4955, 0x4c4c, 0x6c4b, 0x532a, 0x3253, 0x5672, + 0x3b62, 0x3d7d, 0x6c62, 0x4b38, 0x422f, 0x4043, 0x4e2a, 0x522f, + 0x367b, 0x6b39, 0x4723, 0x5c7d, 0x363f, 0x4e7e, 0x5734, 0x4f41, + 0x3137, 0x534c, 0x6178, 0x616f, 0x537c, 0x4a28, 0x3640, 0x6176, + 0x617d, 0x447c, 0x3b71, 0x4154, 0x616e, 0x4a5e, 0x4c21, 0x4f57, + 0x6228, 0x6224, 0x4f56, 0x6775, 0x6762, 0x4b76, 0x5328, 0x426a, + 0x6776, 0x6761, 0x6828, 0x3b37, 0x6774, 0x476d, 0x6767, 0x682c, + 0x6836, 0x6a31, 0x327a, 0x4436, 0x314f, 0x3b2d, 0x3531, 0x336b, + 0x7921, 0x3e37, 0x7069, 0x3768, 0x5171, 0x7079, 0x342f, 0x4531, + 0x707c, 0x4146, 0x706c, 0x706f, 0x7077, 0x705d, 0x3171, 0x5177, + 0x705c, 0x5622, 0x705f, 0x712e, 0x5122, 0x7128, 0x712b, 0x5338, + 0x4c31, 0x7132, 0x3722, 0x3028, 0x7164, 0x5665, 0x5535, 0x3e21, + 0x3c60, 0x454c, 0x422c, 0x784a, 0x6d79, 0x6d6e, 0x4277, 0x7851, + 0x6d7a, 0x7857, 0x5675, 0x3d43, 0x7927, 0x6d4c, 0x6d3a, 0x7866, + 0x5162, 0x4b36, 0x6d38, 0x6d3f, 0x4837, 0x426b, 0x5729, 0x6d57, + 0x6d53, 0x6d36, 0x6d4d, 0x3421, 0x302d, 0x3f73, 0x6d42, 0x4079, + 0x372f, 0x6d43, 0x3b76, 0x6c75, 0x787a, 0x6c78, 0x4071, 0x6c72, + 0x353b, 0x7926, 0x5656, 0x3346, 0x7836, 0x7655, 0x3b7d, 0x5331, + 0x7023, 0x3b60, 0x4e48, 0x783e, 0x4e51, 0x4d5d, 0x476e, 0x7140, + 0x3f7a, 0x345c, 0x474f, 0x713c, 0x546e, 0x4754, 0x4a7a, 0x3e3a, + 0x314a, 0x7928, 0x7348, 0x3c63, 0x3d5a, 0x3736, 0x567e, 0x7366, + 0x7346, 0x4938, 0x7359, 0x7365, 0x4228, 0x736c, 0x3c72, 0x7371, + 0x736f, 0x4729, 0x4131, 0x403a, 0x336f, 0x736a, 0x7425, 0x417d, + 0x7862, 0x7356, 0x737d, 0x4069, 0x4261, 0x787b, 0x7456, 0x3760, + 0x4138, 0x7870, 0x744f, 0x5961, 0x7450, 0x6679, 0x3e40, 0x3c4d, + 0x667b, 0x543c, 0x3a6c, 0x667a, 0x667c, 0x667d, 0x4852, 0x4e46, + 0x4449, 0x4526, 0x6723, 0x343f, 0x6722, 0x4934, 0x563d, 0x3c36, + 0x3757, 0x6721, 0x3744, 0x4f38, 0x6726, 0x6725, 0x4970, 0x495c, + 0x6724, 0x6728, 0x672a, 0x6729, 0x5655, 0x5769, 0x306d, 0x672c, + 0x3d61, 0x672b, 0x3d4a, 0x4267, 0x5124, 0x3878, 0x485e, 0x4d33, + 0x4b3f, 0x672d, 0x3e78, 0x3e6e, 0x3073, 0x672f, 0x672e, 0x6730, + 0x5065, 0x4b67, 0x3e2d, 0x575b, 0x6736, 0x3371, 0x6739, 0x4f5f, + 0x6737, 0x4e2c, 0x673a, 0x3859, 0x4d78, 0x3141, 0x573a, 0x425a, + 0x6738, 0x6732, 0x5540, 0x3442, 0x6731, 0x4360, 0x6735, 0x673b, + 0x3d74, 0x6733, 0x424c, 0x5077, 0x6734, 0x673d, 0x3c6a, 0x673c, + 0x3c29, 0x3650, 0x355e, 0x6745, 0x5435, 0x6741, 0x3160, 0x3b3a, + 0x4365, 0x4e33, 0x6743, 0x673f, 0x4137, 0x6742, 0x673e, 0x7924, + 0x5d53, 0x6746, 0x674b, 0x6744, 0x6727, 0x674c, 0x383f, 0x6747, + 0x6749, 0x6748, 0x4f58, 0x4c50, 0x376c, 0x674a, 0x4b75, 0x575d, + 0x6750, 0x7863, 0x674f, 0x746a, 0x4246, 0x674e, 0x575c, 0x3c28, + 0x6752, 0x6751, 0x6755, 0x562f, 0x4949, 0x6754, 0x4846, 0x6740, + 0x497e, 0x3b66, 0x7873, 0x3c6b, 0x6756, 0x6759, 0x6758, 0x3d49, + 0x526f, 0x3c4c, 0x674d, 0x6757, 0x6753, 0x667e, 0x5078, 0x784d, + 0x3278, 0x5327, 0x7826, 0x4f4b, 0x675a, 0x4042, 0x733f, 0x786e, + 0x3723, 0x3055, 0x425e, 0x6e3c, 0x6e3f, 0x7447, 0x5265, 0x4f30, + 0x474c, 0x716f, 0x716c, 0x4a25, 0x4e45, 0x412a, 0x344f, 0x4979, + 0x4b4a, 0x7179, 0x4474, 0x5630, 0x7177, 0x4c7d, 0x417b, 0x4b60, + 0x5032, 0x6b56, 0x554d, 0x784c, 0x4976, 0x6b4b, 0x6b61, 0x4454, + 0x5657, 0x3326, 0x3774, 0x3d3a, 0x4465, 0x3528, 0x6b5a, 0x4527, + 0x4133, 0x466a, 0x6b77, 0x4030, 0x6b4d, 0x5460, 0x5975, 0x4159, + 0x4c28, 0x536b, 0x504b, 0x3e59, 0x3e49, 0x7867, 0x3255, 0x742f, + 0x3d22, 0x7435, 0x3c68, 0x515e, 0x5b3b, 0x5c51, 0x785c, 0x7832, + 0x7843, 0x572f, 0x3e25, 0x3c54, 0x5c48, 0x3b2a, 0x5c49, 0x4033, + 0x4d72, 0x5d2b, 0x5236, 0x5d26, 0x5d27, 0x4e2d, 0x7877, 0x3b67, + 0x5d3b, 0x5d2a, 0x3254, 0x5d25, 0x3847, 0x412b, 0x5c4a, 0x5c6a, + 0x7825, 0x5d64, 0x3d2f, 0x5c60, 0x5271, 0x5d21, 0x5d5b, 0x5c71, + 0x5d24, 0x5c3f, 0x5d35, 0x5c69, 0x5d5e, 0x3534, 0x4e5f, 0x4f74, + 0x5d77, 0x5c76, 0x3c3b, 0x5c3c, 0x7844, 0x473e, 0x5d32, 0x3c76, + 0x4878, 0x5c79, 0x4036, 0x5d23, 0x5255, 0x5229, 0x5e34, 0x544c, + 0x5c42, 0x302a, 0x5d7e, 0x5e2d, 0x422b, 0x4b55, 0x463b, 0x5e3a, + 0x5d7c, 0x5c57, 0x403c, 0x5d71, 0x425c, 0x3426, 0x4232, 0x3a45, + 0x3f77, 0x724c, 0x7239, 0x784b, 0x4a34, 0x4f3a, 0x4e4f, 0x724f, + 0x426c, 0x5329, 0x7277, 0x555d, 0x7265, 0x727d, 0x7231, 0x3275, + 0x724d, 0x3366, 0x7249, 0x524f, 0x532c, 0x7232, 0x7253, 0x726e, + 0x402f, 0x7243, 0x3946, 0x324f, 0x4279, 0x565a, 0x785a, 0x4a75, + 0x4e40, 0x3365, 0x563b, 0x7441, 0x406f, 0x3239, 0x5730, 0x7925, + 0x7834, 0x3f63, 0x714d, 0x715a, 0x5974, 0x7150, 0x3040, 0x714f, + 0x7149, 0x715c, 0x4d60, 0x7821, 0x3344, 0x4f2e, 0x3c7b, 0x3966, + 0x4359, 0x4a53, 0x6a68, 0x6a6a, 0x6a6c, 0x4757, 0x6a69, 0x6a6d, + 0x6a6e, 0x6a6f, 0x3e75, 0x4040, 0x6a6b, 0x395b, 0x757c, 0x7623, + 0x3425, 0x5a25, 0x3629, 0x383c, 0x3c46, 0x5136, 0x5a27, 0x4c56, + 0x5a26, 0x5135, 0x5a28, 0x467d, 0x3c47, 0x366f, 0x5148, 0x4b4f, + 0x3e77, 0x5a2b, 0x3743, 0x4968, 0x506d, 0x4b5f, 0x5a2d, 0x556f, + 0x5a2c, 0x5a2e, 0x5a2a, 0x5529, 0x5a31, 0x5a2f, 0x4640, 0x5a30, + 0x5767, 0x344a, 0x5a3c, 0x512f, 0x5268, 0x4a54, 0x4a2b, 0x326f, + 0x5a38, 0x396e, 0x5a39, 0x5a35, 0x3b30, 0x3843, 0x4f6a, 0x5a37, + 0x5a36, 0x5a34, 0x5a33, 0x566f, 0x5a32, 0x3f64, 0x484f, 0x5a3f, + 0x5a40, 0x352e, 0x5355, 0x5a3d, 0x536f, 0x334f, 0x3d6b, 0x4e5c, + 0x4e73, 0x5a3e, 0x4b50, 0x3b65, 0x4b35, 0x4b2d, 0x3f4e, 0x5a47, + 0x374c, 0x526a, 0x3577, 0x5a46, 0x573b, 0x4c38, 0x5a43, 0x476b, + 0x5a3a, 0x5a41, 0x5a42, 0x4142, 0x425b, 0x5a45, 0x5a44, 0x357d, + 0x5a52, 0x5a3b, 0x5a4c, 0x5a50, 0x5033, 0x5a49, 0x5a4d, 0x5a51, + 0x3b64, 0x5a4f, 0x5a48, 0x376d, 0x566e, 0x5168, 0x5a4e, 0x4535, + 0x4431, 0x5a4b, 0x4e3d, 0x4c5c, 0x565f, 0x3b51, 0x4355, 0x5a57, + 0x5a4a, 0x5a55, 0x3079, 0x472b, 0x5a56, 0x3d32, 0x503b, 0x5225, + 0x5a53, 0x5a58, 0x437d, 0x5a59, 0x5a29, 0x3d77, 0x4321, 0x5624, + 0x5a5c, 0x3c25, 0x5a5a, 0x4a36, 0x5a5b, 0x4c37, 0x4657, 0x5a5e, + 0x526b, 0x5269, 0x4734, 0x3b24, 0x537e, 0x3641, 0x3164, 0x7645, + 0x3277, 0x4843, 0x403e, 0x5a5f, 0x5a54, 0x5a5d, 0x4671, 0x3761, + 0x3134, 0x556a, 0x383a, 0x3246, 0x3931, 0x4636, 0x3b75, 0x3737, + 0x4c30, 0x3961, 0x5470, 0x567c, 0x6a5b, 0x6a5f, 0x3721, 0x3973, + 0x3161, 0x4272, 0x347b, 0x6a5c, 0x3751, 0x4c79, 0x6a5d, 0x4333, + 0x3a58, 0x6a5a, 0x4238, 0x415e, 0x3b5f, 0x6a60, 0x574a, 0x3c56, + 0x5474, 0x6a62, 0x495e, 0x3176, 0x6a64, 0x6a63, 0x344d, 0x494d, + 0x4562, 0x6259, 0x4f4d, 0x4274, 0x3c7a, 0x3833, 0x6a66, 0x564a, + 0x6a65, 0x554b, 0x3644, 0x4035, 0x572c, 0x6a67, 0x393a, 0x487c, + 0x5853, 0x6a5e, 0x5738, 0x5479, 0x545e, 0x584d, 0x4944, 0x532e, + 0x6a61, 0x4a6a, 0x3853, 0x545f, 0x384f, 0x5554, 0x4777, 0x7475, + 0x3c79, 0x533b, 0x7544, 0x754f, 0x7567, 0x754e, 0x753b, 0x336c, + 0x7552, 0x543e, 0x755c, 0x7548, 0x7559, 0x7551, 0x7566, 0x345a, + 0x7572, 0x756f, 0x477b, 0x3335, 0x547e, 0x396c, 0x3e7c, 0x5079, + 0x696d, 0x696e, 0x486d, 0x6975, 0x6974, 0x696f, 0x5661, 0x6972, + 0x6977, 0x6970, 0x6973, 0x6978, 0x3d4f, 0x697b, 0x697a, 0x5458, + 0x6979, 0x697c, 0x3828, 0x4761, 0x413e, 0x6a22, 0x3b54, 0x697e, + 0x6a21, 0x3975, 0x697d, 0x3132, 0x4256, 0x3c2d, 0x6a23, 0x4a64, + 0x3778, 0x5537, 0x535f, 0x6c31, 0x4f3d, 0x542f, 0x6a24, 0x572a, + 0x555e, 0x3d4e, 0x6a25, 0x3a64, 0x604e, 0x6976, 0x6971, 0x306c, + 0x3447, 0x3168, 0x3167, 0x4529, 0x783c, 0x6549, 0x5562, 0x412c, + 0x3d78, 0x544b, 0x397d, 0x346f, 0x4e25, 0x5137, 0x355d, 0x5436, + 0x4a4a, 0x3359, 0x4728, 0x5121, 0x5245, 0x4149, 0x4275, 0x3b39, + 0x6547, 0x315f, 0x425f, 0x654e, 0x7879, 0x5b23, 0x534a, 0x5b29, + 0x4f67, 0x575e, 0x5a79, 0x5447, 0x354b, 0x5623, 0x415a, 0x3526, + 0x5a7e, 0x5b26, 0x5a77, 0x5b2a, 0x544d, 0x3373, 0x523d, 0x3d34, + 0x4470, 0x5046, 0x7527, 0x7526, 0x4a4d, 0x784e, 0x6e44, 0x6e45, + 0x6e46, 0x6e49, 0x6e48, 0x3624, 0x6e47, 0x556b, 0x3576, 0x6e4c, + 0x6e4b, 0x3730, 0x6e4e, 0x6e4a, 0x6e4f, 0x4725, 0x6e59, 0x6e55, + 0x6e57, 0x6e50, 0x4446, 0x365b, 0x3933, 0x6e54, 0x6e53, 0x332e, + 0x4525, 0x3e7b, 0x3846, 0x6e58, 0x6e51, 0x6e56, 0x6e6a, 0x6e66, + 0x6e5d, 0x4165, 0x6e5c, 0x6e60, 0x6e6b, 0x6e5a, 0x6e5f, 0x534b, + 0x6e64, 0x3c58, 0x6e52, 0x6e68, 0x6e67, 0x6e69, 0x322c, 0x6e5e, + 0x472f, 0x432d, 0x4726, 0x6e61, 0x3227, 0x6e5b, 0x6e62, 0x6e63, + 0x3d42, 0x6e6f, 0x3875, 0x6e7e, 0x5278, 0x6f25, 0x4d2d, 0x4f33, + 0x6e7d, 0x6e79, 0x437a, 0x6f22, 0x4f4e, 0x6e6e, 0x6f28, 0x523f, + 0x6e77, 0x6f27, 0x6e7b, 0x6e70, 0x6f24, 0x6e6d, 0x6e76, 0x4f7a, + 0x5062, 0x4c60, 0x6f31, 0x4241, 0x6f36, 0x503f, 0x3135, 0x6e7a, + 0x6e72, 0x3766, 0x6f32, 0x6f37, 0x6e74, 0x337a, 0x6f2d, 0x6f38, + 0x6f30, 0x464c, 0x4871, 0x6e71, 0x6f2f, 0x6f2e, 0x6f2b, 0x6f33, + 0x3e62, 0x3856, 0x6f3e, 0x6f3a, 0x6f42, 0x6f43, 0x5736, 0x6f39, + 0x6f3f, 0x3438, 0x6f45, 0x6f23, 0x6f3c, 0x6f44, 0x3627, 0x472e, + 0x3d75, 0x432a, 0x4e7d, 0x6f40, 0x346d, 0x423c, 0x434c, 0x7823, + 0x6f2a, 0x6f3d, 0x4f47, 0x6f41, 0x6e4d, 0x6f47, 0x3978, 0x3646, + 0x6f49, 0x5521, 0x364d, 0x6f4a, 0x6f46, 0x6f3b, 0x4742, 0x6f4c, + 0x3c7c, 0x6f48, 0x5560, 0x6f71, 0x433e, 0x6f4d, 0x6f51, 0x3077, + 0x4b78, 0x6f53, 0x4e59, 0x5d76, 0x6f56, 0x6e78, 0x6f21, 0x6f4b, + 0x3864, 0x5572, 0x6f57, 0x4478, 0x6f58, 0x6f54, 0x6f55, 0x6f5f, + 0x6f60, 0x4134, 0x6f52, 0x6f5d, 0x6f61, 0x6f2c, 0x6f4f, 0x6f5b, + 0x6f5c, 0x6f5e, 0x3279, 0x3e35, 0x6f5a, 0x6f4e, 0x7649, 0x6e7c, + 0x6f64, 0x6f6a, 0x6e73, 0x6f26, 0x414d, 0x6f29, 0x6f66, 0x6f62, + 0x5653, 0x6f6b, 0x6f63, 0x6f68, 0x6f34, 0x6f35, 0x6f50, 0x412d, + 0x6f6d, 0x4058, 0x4c7a, 0x6e6c, 0x6e75, 0x6f6e, 0x567d, 0x6f6c, + 0x6f59, 0x3c78, 0x6f6f, 0x6e65, 0x6f70, 0x6f65, 0x6f67, 0x543f, + 0x4f62, 0x4477, 0x6f69, 0x4260, 0x576a, 0x7647, 0x5464, 0x3324, + 0x4345, 0x6345, 0x4941, 0x6346, 0x3155, 0x3f2a, 0x634a, 0x6348, + 0x4872, 0x4f50, 0x3c64, 0x6349, 0x5522, 0x3a52, 0x3873, 0x7839, + 0x3727, 0x396b, 0x4376, 0x634d, 0x634f, 0x634c, 0x5444, 0x6351, + 0x514b, 0x5156, 0x6355, 0x6354, 0x6350, 0x6353, 0x6356, 0x7822, + 0x6347, 0x402b, 0x6357, 0x403b, 0x6359, 0x6358, 0x635a, 0x3433, + 0x3958, 0x635b, 0x327b, 0x785b, 0x634b, 0x5a6a, 0x4942, 0x5573, + 0x5275, 0x3342, 0x423d, 0x5174, 0x3653, 0x3d57, 0x5449, 0x3c4a, + 0x4b66, 0x4f55, 0x527e, 0x4224, 0x4125, 0x7922, 0x4b64, 0x4b2b, + 0x337b, 0x5453, 0x406b, 0x4451, 0x5446, 0x3567, 0x4e6d, 0x762b, + 0x7628, 0x7630, 0x4169, 0x7626, 0x584c, 0x392e, 0x7864, 0x7733, + 0x7732, 0x7861, 0x7735, 0x4e24, 0x484d, 0x3a2b, 0x6838, 0x683a, + 0x6839, 0x4f6c, 0x5233, 0x3625, 0x476a, 0x4f6e, 0x4b33, 0x717c, + 0x506b, 0x676f, 0x4b4c, 0x717d, 0x717e, 0x5424, 0x4d67, 0x3064, + 0x3659, 0x4644, 0x416c, 0x7222, 0x7221, 0x5243, 0x7224, 0x4d37, + 0x3c55, 0x7225, 0x3e31, 0x4635, 0x4d47, 0x3f45, 0x4c62, 0x366e, + 0x7226, 0x7227, 0x5155, 0x5438, 0x722a, 0x355f, 0x4060, 0x7229, + 0x722b, 0x394b, 0x327c, 0x722c, 0x4f54, 0x722d, 0x422d, 0x7228, + 0x4827, 0x3767, 0x6c29, 0x6c2a, 0x786c, 0x7837, 0x6c2b, 0x6c2c, + 0x462e, 0x6c2d, 0x6c2e, 0x3749, 0x623b, 0x783f, 0x623d, 0x623f, + 0x6240, 0x6241, 0x3739, 0x527b, 0x6242, 0x4b47, 0x3125, 0x4a4e, + 0x3d48, 0x317d, 0x6243, 0x5178, 0x367c, 0x6244, 0x4459, 0x3676, + 0x5360, 0x6246, 0x3d24, 0x4f5a, 0x395d, 0x623c, 0x6247, 0x623e, + 0x4173, 0x6248, 0x6249, 0x4278, 0x624a, 0x624b, 0x624c, 0x4021, + 0x624d, 0x3c22, 0x4844, 0x774f, 0x7750, 0x3276, 0x624e, 0x426d, + 0x5426, 0x376b, 0x4d54, 0x335b, 0x5131, 0x3235, 0x5724, 0x6665, + 0x3e54, 0x6660, 0x3c5d, 0x6666, 0x6662, 0x4a3b, 0x4d55, 0x6661, + 0x426e, 0x6669, 0x3a27, 0x4266, 0x3f25, 0x3352, 0x666d, 0x666c, + 0x466f, 0x666b, 0x6670, 0x462d, 0x6539, 0x666f, 0x6672, 0x4c5a, + 0x6663, 0x4927, 0x6673, 0x4262, 0x5d6b, 0x6671, 0x666e, 0x6674, + 0x6675, 0x477d, 0x6668, 0x6667, 0x6676, 0x3d3e, 0x5169, 0x3e2a, + 0x6664, 0x5668, 0x423f, 0x6678, 0x6677, 0x666a, 0x3039, 0x7743, + 0x787e, 0x4c65, 0x7746, 0x7745, 0x7831, 0x4b49, 0x783a, 0x7876, + 0x775e, 0x3637, 0x4456, 0x6352, 0x634e, 0x5374, 0x774b, 0x774a, + 0x5363, 0x4233, 0x7650, 0x764f, 0x7651, 0x7652, 0x7653, 0x7658, + 0x312b, 0x7656, 0x765a, 0x765f, 0x765c, 0x765b, 0x765e, 0x7659, + 0x4f4a, 0x7667, 0x7661, 0x7669, 0x4070, 0x7668, 0x7676, 0x766b, + 0x7674, 0x7671, 0x766e, 0x7672, 0x766f, 0x7670, 0x3e28, 0x766c, + 0x766d, 0x7673, 0x7675, 0x766a, 0x767d, 0x7678, 0x767c, 0x767a, + 0x7679, 0x767b, 0x487a, 0x767e, 0x7665, 0x7724, 0x7723, 0x7725, + 0x7722, 0x7663, 0x7721, 0x7726, 0x772a, 0x7666, 0x7664, 0x7729, + 0x7727, 0x772b, 0x7728, 0x316e, 0x772e, 0x772d, 0x772c, 0x415b, + 0x7660, 0x7677, 0x7657, 0x772f, 0x765d, 0x7654, 0x7662, 0x4471, + 0x702f, 0x596c, 0x376f, 0x4379, 0x7030, 0x7032, 0x7031, 0x513b, + 0x4d52, 0x5427, 0x7036, 0x7037, 0x7033, 0x516c, 0x513c, 0x7039, + 0x703b, 0x3a68, 0x386b, 0x703c, 0x3e69, 0x7041, 0x703e, 0x7043, + 0x366c, 0x7040, 0x7044, 0x7046, 0x4574, 0x7047, 0x4835, 0x7034, + 0x7048, 0x7045, 0x7049, 0x704a, 0x704c, 0x704d, 0x5d3a, 0x3a57, + 0x773d, 0x704f, 0x704b, 0x704e, 0x3c26, 0x7051, 0x4538, 0x703a, + 0x7052, 0x7038, 0x7054, 0x7053, 0x7055, 0x7042, 0x7056, 0x5325, + 0x7058, 0x7057, 0x7035, 0x7050, 0x7059, 0x703f, 0x703d, 0x7852, + 0x7874, 0x753a, 0x3c6f, 0x514e, 0x4076, 0x4273, 0x746f, 0x7865, + 0x7859, 0x4334, 0x5964, 0x3563, 0x3533, 0x7775, 0x7854, 0x7772, + 0x763c, 0x763d, 0x763e, 0x782e, 0x466b, 0x552b, 0x6c34, 0x335d, + 0x7633, 0x7635, 0x7637, 0x7634, 0x7636, 0x4164, 0x782a, 0x7638, + 0x763a, 0x7639, 0x4823, 0x763b, 0x417a, 0x4553, 0x3928, 0x6d68, + 0x396a, 0x2672, 0x2674, 0x2675, 0x2660, 0x2661, 0x2670, 0x2671, + 0x2662, 0x2663, 0x266e, 0x266f, 0x2666, 0x2667, 0x2664, 0x2665, + 0x2668, 0x2669, 0x266a, 0x266b, +}; + +static const Summary16 gb12345ext_uni2indx_page01[23] = { + /* 0x0100 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0110 }, { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, + { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, + { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0200 }, + /* 0x0200 */ + { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, + { 3, 0x0000 }, { 3, 0x0002 }, { 4, 0x0002 }, +}; +static const Summary16 gb12345ext_uni2indx_page1e[4] = { + /* 0x1e00 */ + { 5, 0x0000 }, { 5, 0x0000 }, { 5, 0x0000 }, { 5, 0x8000 }, +}; +static const Summary16 gb12345ext_uni2indx_page22[3] = { + /* 0x2200 */ + { 6, 0x0000 }, { 6, 0x0000 }, { 6, 0x0020 }, +}; +static const Summary16 gb12345ext_uni2indx_page4e[1306] = { + /* 0x4e00 */ + { 7, 0x0080 }, { 8, 0x0002 }, { 9, 0x0000 }, { 9, 0x0001 }, + { 10, 0x0100 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0004 }, { 12, 0x4002 }, { 14, 0x0000 }, { 14, 0x0000 }, + { 14, 0x0040 }, { 15, 0x0000 }, { 15, 0x0000 }, { 15, 0x0080 }, + /* 0x4f00 */ + { 16, 0x0000 }, { 16, 0x0000 }, { 16, 0x0000 }, { 16, 0x0000 }, + { 16, 0x0000 }, { 16, 0x0200 }, { 17, 0x0000 }, { 17, 0x0000 }, + { 17, 0x0040 }, { 18, 0x0040 }, { 19, 0x0000 }, { 19, 0x0000 }, + { 19, 0x0004 }, { 20, 0x0000 }, { 20, 0x0001 }, { 21, 0x0000 }, + /* 0x5000 */ + { 21, 0x0a41 }, { 25, 0x0002 }, { 26, 0x0800 }, { 27, 0x0000 }, + { 27, 0x0200 }, { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0030 }, + { 30, 0x0000 }, { 30, 0x0340 }, { 33, 0x2004 }, { 35, 0x40b8 }, + { 40, 0x0224 }, { 43, 0x4022 }, { 46, 0x0120 }, { 48, 0x0200 }, + /* 0x5100 */ + { 49, 0x0315 }, { 54, 0x8131 }, { 59, 0x0400 }, { 60, 0x1c84 }, + { 65, 0x0000 }, { 65, 0x0404 }, { 67, 0x0200 }, { 68, 0x0000 }, + { 68, 0x0000 }, { 68, 0x0000 }, { 68, 0x0000 }, { 68, 0x0004 }, + { 69, 0x2040 }, { 71, 0x0000 }, { 71, 0x2001 }, { 73, 0x0002 }, + /* 0x5200 */ + { 74, 0x0000 }, { 74, 0x0004 }, { 75, 0x0000 }, { 75, 0x0000 }, + { 75, 0x0890 }, { 78, 0x0800 }, { 79, 0x4000 }, { 80, 0x0030 }, + { 82, 0x3688 }, { 88, 0x0002 }, { 89, 0x0000 }, { 89, 0x0000 }, + { 89, 0x0002 }, { 90, 0x6a20 }, { 95, 0x0004 }, { 96, 0x0122 }, + /* 0x5300 */ + { 99, 0x0000 }, { 99, 0x0000 }, { 99, 0xa000 }, { 101, 0x0002 }, + { 102, 0x0001 }, { 103, 0x0010 }, { 104, 0x0000 }, { 104, 0x0000 }, + { 104, 0x0004 }, { 105, 0x0200 }, { 106, 0x2001 }, { 108, 0x0014 }, + { 110, 0x0008 }, { 111, 0x0000 }, { 111, 0x0404 }, { 113, 0x0041 }, + /* 0x5400 */ + { 115, 0x4000 }, { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0000 }, + { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0000 }, + { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x1000 }, + { 117, 0x0000 }, { 117, 0x0000 }, { 117, 0x0002 }, { 118, 0x0000 }, + /* 0x5500 */ + { 118, 0x0010 }, { 119, 0x0000 }, { 119, 0x0000 }, { 119, 0x0000 }, + { 119, 0x8000 }, { 120, 0x4008 }, { 122, 0x0000 }, { 122, 0x0000 }, + { 122, 0x0000 }, { 122, 0x0000 }, { 122, 0x5400 }, { 125, 0x0004 }, + { 126, 0x40c0 }, { 129, 0x0400 }, { 130, 0x0200 }, { 131, 0x0040 }, + /* 0x5600 */ + { 132, 0x2040 }, { 134, 0x10d0 }, { 138, 0xc200 }, { 141, 0x0121 }, + { 144, 0x0002 }, { 145, 0x2000 }, { 146, 0x8061 }, { 150, 0x0314 }, + { 154, 0x1081 }, { 157, 0x0220 }, { 159, 0x4140 }, { 162, 0x0058 }, + { 165, 0x1327 }, { 172, 0x0002 }, { 173, 0x0000 }, { 173, 0x0000 }, + /* 0x5700 */ + { 173, 0x2880 }, { 176, 0x014c }, { 180, 0x0000 }, { 180, 0x0000 }, + { 180, 0x0000 }, { 180, 0x0000 }, { 180, 0x0000 }, { 180, 0x0000 }, + { 180, 0x0000 }, { 180, 0x0000 }, { 180, 0x0000 }, { 180, 0x0000 }, + { 180, 0x0000 }, { 180, 0x0000 }, { 180, 0x0002 }, { 181, 0x0080 }, + /* 0x5800 */ + { 182, 0x0420 }, { 184, 0x2040 }, { 186, 0x8000 }, { 187, 0x0012 }, + { 189, 0x8c00 }, { 192, 0x0084 }, { 194, 0x0014 }, { 196, 0x0220 }, + { 198, 0x0400 }, { 199, 0x1000 }, { 200, 0x4000 }, { 201, 0x4808 }, + { 204, 0x0080 }, { 205, 0xc708 }, { 211, 0x8205 }, { 215, 0x2400 }, + /* 0x5900 */ + { 217, 0x0000 }, { 217, 0x0000 }, { 217, 0x0004 }, { 218, 0x4100 }, + { 220, 0x0000 }, { 220, 0x0000 }, { 220, 0x5600 }, { 224, 0x0000 }, + { 224, 0x0000 }, { 224, 0x2000 }, { 225, 0x0000 }, { 225, 0x0000 }, + { 225, 0x0000 }, { 225, 0x0000 }, { 225, 0x0000 }, { 225, 0x0000 }, + /* 0x5a00 */ + { 225, 0x0000 }, { 225, 0x0000 }, { 225, 0x0000 }, { 225, 0x0000 }, + { 225, 0x0002 }, { 226, 0x0000 }, { 226, 0x2040 }, { 228, 0x0000 }, + { 228, 0x0000 }, { 228, 0x0000 }, { 228, 0x0080 }, { 229, 0x2000 }, + { 230, 0x0000 }, { 230, 0x0080 }, { 231, 0x0000 }, { 231, 0x0820 }, + /* 0x5b00 */ + { 233, 0x1901 }, { 237, 0x0200 }, { 238, 0x0402 }, { 240, 0x0101 }, + { 242, 0x1000 }, { 243, 0x0000 }, { 243, 0x0800 }, { 244, 0x8100 }, + { 246, 0x0000 }, { 246, 0x0000 }, { 246, 0x0000 }, { 246, 0x0000 }, + { 246, 0x0000 }, { 246, 0x0000 }, { 246, 0x1ac4 }, { 252, 0x0060 }, + /* 0x5c00 */ + { 254, 0x6980 }, { 259, 0x0000 }, { 259, 0x0000 }, { 259, 0x0080 }, + { 260, 0x0000 }, { 260, 0x0000 }, { 260, 0x1114 }, { 264, 0x0000 }, + { 264, 0x0000 }, { 264, 0x0000 }, { 264, 0x0002 }, { 265, 0x0000 }, + { 265, 0x0000 }, { 265, 0x0000 }, { 265, 0x0000 }, { 265, 0x2050 }, + /* 0x5d00 */ + { 268, 0x2000 }, { 269, 0x0080 }, { 270, 0x1000 }, { 271, 0x0000 }, + { 271, 0x0000 }, { 271, 0x0001 }, { 272, 0x0000 }, { 272, 0x0000 }, + { 272, 0x0092 }, { 275, 0x0080 }, { 276, 0x0081 }, { 278, 0x1500 }, + { 281, 0x0800 }, { 282, 0x0014 }, { 284, 0x0000 }, { 284, 0x0001 }, + /* 0x5e00 */ + { 285, 0x0000 }, { 285, 0x0100 }, { 286, 0x0820 }, { 288, 0x0048 }, + { 290, 0x0009 }, { 292, 0x8180 }, { 295, 0x1808 }, { 298, 0xc204 }, + { 302, 0x0000 }, { 302, 0x0000 }, { 302, 0x0800 }, { 303, 0x0000 }, + { 303, 0x0000 }, { 303, 0x8000 }, { 304, 0x100f }, { 309, 0x0008 }, + /* 0x5f00 */ + { 310, 0x0000 }, { 310, 0x0000 }, { 310, 0x0000 }, { 310, 0x0028 }, + { 312, 0x5140 }, { 316, 0x0200 }, { 317, 0x0000 }, { 317, 0x0000 }, + { 317, 0x1000 }, { 318, 0x4002 }, { 320, 0x0201 }, { 322, 0x0200 }, + { 323, 0x0000 }, { 323, 0x0000 }, { 323, 0x0000 }, { 323, 0x0000 }, + /* 0x6000 */ + { 323, 0x0000 }, { 323, 0x0000 }, { 323, 0x0000 }, { 323, 0x0000 }, + { 323, 0x0000 }, { 323, 0x0000 }, { 323, 0x0000 }, { 323, 0x0000 }, + { 323, 0x0000 }, { 323, 0x0000 }, { 323, 0x0000 }, { 323, 0x0060 }, + { 325, 0x0000 }, { 325, 0x0000 }, { 325, 0x0002 }, { 326, 0x0806 }, + /* 0x6100 */ + { 329, 0x0000 }, { 329, 0x1800 }, { 331, 0x0000 }, { 331, 0xc090 }, + { 335, 0x0800 }, { 336, 0x8500 }, { 339, 0x4c18 }, { 344, 0x0048 }, + { 346, 0x0404 }, { 348, 0x0407 }, { 352, 0x4810 }, { 355, 0x0044 }, + { 357, 0x1280 }, { 360, 0xc000 }, { 362, 0x0108 }, { 364, 0x55c4 }, + /* 0x6200 */ + { 371, 0x0081 }, { 373, 0x0010 }, { 374, 0x0080 }, { 375, 0x0005 }, + { 377, 0x0000 }, { 377, 0x0002 }, { 378, 0x0000 }, { 378, 0x0000 }, + { 378, 0x0000 }, { 378, 0x0000 }, { 378, 0x0000 }, { 378, 0x0000 }, + { 378, 0x0000 }, { 378, 0x0000 }, { 378, 0x0000 }, { 378, 0x0000 }, + /* 0x6300 */ + { 378, 0x0000 }, { 378, 0x0000 }, { 378, 0x0000 }, { 378, 0x4000 }, + { 379, 0x0000 }, { 379, 0x0000 }, { 379, 0x4900 }, { 382, 0x0004 }, + { 383, 0x0018 }, { 385, 0x0000 }, { 385, 0x0000 }, { 385, 0x0000 }, + { 385, 0x0001 }, { 386, 0x0400 }, { 387, 0x4000 }, { 388, 0x0000 }, + /* 0x6400 */ + { 388, 0x2000 }, { 389, 0x0080 }, { 390, 0x0000 }, { 390, 0x0040 }, + { 391, 0x0000 }, { 391, 0x9002 }, { 394, 0x8000 }, { 395, 0x0848 }, + { 398, 0x0100 }, { 399, 0x8008 }, { 401, 0x0828 }, { 404, 0xc80c }, + { 409, 0x0c92 }, { 414, 0x0410 }, { 416, 0x9001 }, { 419, 0x5c97 }, + /* 0x6500 */ + { 428, 0x8050 }, { 431, 0x2a50 }, { 436, 0x141c }, { 441, 0x0000 }, + { 441, 0x0000 }, { 441, 0x0080 }, { 442, 0x0000 }, { 442, 0x0120 }, + { 444, 0x000c }, { 446, 0x00a0 }, { 448, 0x1000 }, { 449, 0x0080 }, + { 450, 0x0000 }, { 450, 0x0000 }, { 450, 0x0000 }, { 450, 0x0000 }, + /* 0x6600 */ + { 450, 0x0000 }, { 450, 0x0000 }, { 450, 0x0000 }, { 450, 0x0000 }, + { 450, 0x0004 }, { 451, 0x2000 }, { 452, 0x0000 }, { 452, 0x0000 }, + { 452, 0x0300 }, { 454, 0x0000 }, { 454, 0x0804 }, { 456, 0x0000 }, + { 456, 0x02d0 }, { 460, 0x0040 }, { 461, 0x1001 }, { 463, 0x0100 }, + /* 0x6700 */ + { 464, 0x0008 }, { 465, 0x0000 }, { 465, 0x8080 }, { 467, 0x0010 }, + { 468, 0x0000 }, { 468, 0x0000 }, { 468, 0x0000 }, { 468, 0x4002 }, + { 470, 0x0000 }, { 470, 0x0000 }, { 470, 0x0000 }, { 470, 0x0000 }, + { 470, 0x0000 }, { 470, 0x0000 }, { 470, 0x0000 }, { 470, 0x0000 }, + /* 0x6800 */ + { 470, 0x0000 }, { 470, 0x0000 }, { 470, 0x0000 }, { 470, 0x0000 }, + { 470, 0x0000 }, { 470, 0x0000 }, { 470, 0x0000 }, { 470, 0x0000 }, + { 470, 0x0000 }, { 470, 0xa100 }, { 473, 0x0000 }, { 473, 0x0000 }, + { 473, 0x0000 }, { 473, 0x80c0 }, { 476, 0x0080 }, { 477, 0x0000 }, + /* 0x6900 */ + { 477, 0x8000 }, { 478, 0x0000 }, { 478, 0x0000 }, { 478, 0x0000 }, + { 478, 0x0400 }, { 479, 0x0008 }, { 480, 0x2100 }, { 482, 0x0020 }, + { 483, 0x0000 }, { 483, 0x0000 }, { 483, 0x4400 }, { 485, 0x8000 }, + { 486, 0x2800 }, { 488, 0x0000 }, { 488, 0x0080 }, { 489, 0x0008 }, + /* 0x6a00 */ + { 490, 0x0026 }, { 493, 0x4208 }, { 496, 0x0008 }, { 497, 0x0700 }, + { 500, 0x0900 }, { 502, 0x8000 }, { 503, 0x0004 }, { 504, 0x0000 }, + { 504, 0x0200 }, { 505, 0x1010 }, { 507, 0x800c }, { 510, 0x0908 }, + { 513, 0x0008 }, { 514, 0xec08 }, { 520, 0x1580 }, { 524, 0x0908 }, + /* 0x6b00 */ + { 527, 0x8410 }, { 530, 0x4044 }, { 533, 0x0000 }, { 533, 0x2000 }, + { 534, 0x0000 }, { 534, 0x8001 }, { 536, 0x0002 }, { 537, 0x0184 }, + { 540, 0x0000 }, { 540, 0x4100 }, { 542, 0xc810 }, { 546, 0x0c04 }, + { 549, 0x0040 }, { 550, 0x0000 }, { 550, 0x0000 }, { 550, 0x8000 }, + /* 0x6c00 */ + { 551, 0x1100 }, { 553, 0x0000 }, { 553, 0x1808 }, { 556, 0x0000 }, + { 556, 0x0000 }, { 556, 0x0000 }, { 556, 0x0000 }, { 556, 0x0000 }, + { 556, 0x0000 }, { 556, 0x0000 }, { 556, 0x0000 }, { 556, 0x0000 }, + { 556, 0x0000 }, { 556, 0x0000 }, { 556, 0x0000 }, { 556, 0x0000 }, + /* 0x6d00 */ + { 556, 0x0000 }, { 556, 0x0000 }, { 556, 0x0000 }, { 556, 0x0000 }, + { 556, 0x0000 }, { 556, 0x0000 }, { 556, 0x0000 }, { 556, 0x0200 }, + { 557, 0x0084 }, { 559, 0x0000 }, { 559, 0x0000 }, { 559, 0x0000 }, + { 559, 0x0001 }, { 560, 0x0000 }, { 560, 0x0400 }, { 561, 0x0460 }, + /* 0x6e00 */ + { 564, 0x0000 }, { 564, 0x0000 }, { 564, 0x1040 }, { 566, 0x4000 }, + { 567, 0x0000 }, { 567, 0x4000 }, { 568, 0x8000 }, { 569, 0x0000 }, + { 569, 0x0000 }, { 569, 0x2040 }, { 571, 0x0000 }, { 571, 0x0000 }, + { 571, 0x5030 }, { 575, 0x0000 }, { 575, 0x9000 }, { 577, 0x8184 }, + /* 0x6f00 */ + { 581, 0x0002 }, { 582, 0x0400 }, { 583, 0x100c }, { 586, 0x8104 }, + { 589, 0x0002 }, { 590, 0x0212 }, { 593, 0x8010 }, { 595, 0x8081 }, + { 598, 0x00c1 }, { 601, 0x0080 }, { 602, 0x4211 }, { 606, 0x0002 }, + { 607, 0x000a }, { 609, 0x8920 }, { 613, 0x0810 }, { 615, 0x5403 }, + /* 0x7000 */ + { 620, 0x8a60 }, { 625, 0xa120 }, { 629, 0x0181 }, { 632, 0x4005 }, + { 635, 0x0018 }, { 637, 0x2122 }, { 641, 0x0098 }, { 644, 0x0000 }, + { 644, 0x0000 }, { 644, 0x0000 }, { 644, 0x0000 }, { 644, 0x0000 }, + { 644, 0x8000 }, { 645, 0x0000 }, { 645, 0x0000 }, { 645, 0x0010 }, + /* 0x7100 */ + { 646, 0x0000 }, { 646, 0x0000 }, { 646, 0x0002 }, { 647, 0x0000 }, + { 647, 0x0200 }, { 648, 0x0004 }, { 649, 0x1204 }, { 652, 0x0000 }, + { 652, 0x0000 }, { 652, 0x0084 }, { 654, 0x0000 }, { 654, 0x4002 }, + { 656, 0x0102 }, { 658, 0x9204 }, { 662, 0x2040 }, { 664, 0x5010 }, + /* 0x7200 */ + { 667, 0x2000 }, { 668, 0x0801 }, { 670, 0x0000 }, { 670, 0x4404 }, + { 673, 0x0000 }, { 673, 0x0100 }, { 674, 0x0000 }, { 674, 0x2000 }, + { 675, 0x0000 }, { 675, 0x0040 }, { 676, 0x0084 }, { 678, 0x0000 }, + { 678, 0x0001 }, { 679, 0x0000 }, { 679, 0x0000 }, { 679, 0x2200 }, + /* 0x7300 */ + { 681, 0x0000 }, { 681, 0x0000 }, { 681, 0x0000 }, { 681, 0x0840 }, + { 683, 0x0032 }, { 686, 0x0000 }, { 686, 0x0d00 }, { 689, 0x1da5 }, + { 697, 0x0001 }, { 698, 0x0000 }, { 698, 0x0000 }, { 698, 0x0000 }, + { 698, 0x0000 }, { 698, 0x0000 }, { 698, 0x0000 }, { 698, 0x4000 }, + /* 0x7400 */ + { 699, 0x0000 }, { 699, 0x0000 }, { 699, 0x0000 }, { 699, 0x8000 }, + { 700, 0x0800 }, { 701, 0x0000 }, { 701, 0x0608 }, { 704, 0x0000 }, + { 704, 0x0200 }, { 705, 0x0000 }, { 705, 0x0048 }, { 707, 0x2001 }, + { 709, 0x8400 }, { 711, 0x0410 }, { 713, 0x0000 }, { 713, 0x0000 }, + /* 0x7500 */ + { 713, 0x1000 }, { 714, 0x0000 }, { 714, 0x0008 }, { 715, 0x0000 }, + { 715, 0x0000 }, { 715, 0x2000 }, { 716, 0x0804 }, { 718, 0x0040 }, + { 719, 0x0080 }, { 720, 0x0000 }, { 720, 0x0000 }, { 720, 0x0000 }, + { 720, 0x0080 }, { 721, 0x0200 }, { 722, 0x0000 }, { 722, 0x0000 }, + /* 0x7600 */ + { 722, 0x2804 }, { 725, 0x4000 }, { 726, 0x0082 }, { 728, 0x0800 }, + { 729, 0x02c4 }, { 733, 0x8100 }, { 735, 0x72b4 }, { 743, 0x1007 }, + { 747, 0x0000 }, { 747, 0x0400 }, { 748, 0x0000 }, { 748, 0x0500 }, + { 750, 0x0000 }, { 750, 0x4000 }, { 751, 0x009a }, { 755, 0x0000 }, + /* 0x7700 */ + { 755, 0x0000 }, { 755, 0x0000 }, { 755, 0x0000 }, { 755, 0x0000 }, + { 755, 0x8000 }, { 756, 0x4000 }, { 757, 0x0000 }, { 757, 0x0000 }, + { 757, 0x0000 }, { 757, 0x4100 }, { 759, 0x2000 }, { 760, 0x1000 }, + { 761, 0x0080 }, { 762, 0x0400 }, { 763, 0x8000 }, { 764, 0x0000 }, + /* 0x7800 */ + { 764, 0x0000 }, { 764, 0x0000 }, { 764, 0x0000 }, { 764, 0x0000 }, + { 764, 0x0008 }, { 765, 0x0000 }, { 765, 0xc110 }, { 769, 0x0000 }, + { 769, 0x0000 }, { 769, 0x0000 }, { 769, 0x2200 }, { 771, 0x1500 }, + { 774, 0x0000 }, { 774, 0x0400 }, { 775, 0x8088 }, { 778, 0x2000 }, + /* 0x7900 */ + { 779, 0x4000 }, { 780, 0x0200 }, { 781, 0x1c40 }, { 785, 0x0002 }, + { 786, 0x0000 }, { 786, 0x0000 }, { 786, 0x0000 }, { 786, 0x0000 }, + { 786, 0x6000 }, { 788, 0x0000 }, { 788, 0x4440 }, { 791, 0x0003 }, + { 793, 0x2000 }, { 794, 0x0000 }, { 794, 0x0000 }, { 794, 0x0000 }, + /* 0x7a00 */ + { 794, 0x0000 }, { 794, 0x0000 }, { 794, 0x4000 }, { 795, 0x0002 }, + { 796, 0x7001 }, { 800, 0x0000 }, { 800, 0x0a06 }, { 804, 0x0000 }, + { 804, 0x0000 }, { 804, 0x0000 }, { 804, 0x4600 }, { 807, 0x0440 }, + { 809, 0x05b0 }, { 814, 0x0000 }, { 814, 0x0400 }, { 815, 0x0040 }, + /* 0x7b00 */ + { 816, 0x0000 }, { 816, 0x0000 }, { 816, 0x0000 }, { 816, 0x0000 }, + { 816, 0x0040 }, { 817, 0x0002 }, { 818, 0x0080 }, { 819, 0x0000 }, + { 819, 0x0800 }, { 820, 0x0000 }, { 820, 0x0000 }, { 820, 0x0000 }, + { 820, 0x0a11 }, { 824, 0x0000 }, { 824, 0x0210 }, { 826, 0x0008 }, + /* 0x7c00 */ + { 827, 0x2001 }, { 829, 0x4000 }, { 830, 0x080a }, { 833, 0x6000 }, + { 835, 0x1008 }, { 837, 0x9000 }, { 839, 0x5611 }, { 845, 0x0004 }, + { 846, 0x0000 }, { 846, 0x0000 }, { 846, 0x0000 }, { 846, 0x0000 }, + { 846, 0x0000 }, { 846, 0x6000 }, { 848, 0x0080 }, { 849, 0x4255 }, + /* 0x7d00 */ + { 855, 0x2bf5 }, { 865, 0x1eb9 }, { 874, 0x0002 }, { 875, 0x960f }, + { 883, 0x4055 }, { 888, 0x6001 }, { 891, 0x0146 }, { 895, 0x024e }, + { 900, 0x834a }, { 906, 0x5008 }, { 909, 0x380c }, { 914, 0xef1f }, + { 926, 0x0c90 }, { 930, 0x6396 }, { 938, 0x934b }, { 946, 0x0a56 }, + /* 0x7e00 */ + { 952, 0x0f00 }, { 956, 0xe803 }, { 962, 0x6888 }, { 967, 0x62f6 }, + { 976, 0x0060 }, { 978, 0x4434 }, { 983, 0xee04 }, { 990, 0x7209 }, + { 996, 0xb500 }, { 1001, 0x1158 }, { 1006, 0x0000 }, { 1006, 0x0000 }, + { 1006, 0x0000 }, { 1006, 0x0000 }, { 1006, 0x0000 }, { 1006, 0x0000 }, + /* 0x7f00 */ + { 1006, 0x0000 }, { 1006, 0x0000 }, { 1006, 0x0000 }, { 1006, 0x0000 }, + { 1006, 0x5000 }, { 1008, 0x0000 }, { 1008, 0x0000 }, { 1008, 0x0081 }, + { 1010, 0x0160 }, { 1013, 0x0000 }, { 1013, 0x0220 }, { 1015, 0x0000 }, + { 1015, 0x0000 }, { 1015, 0x0004 }, { 1016, 0x0000 }, { 1016, 0x0200 }, + /* 0x8000 */ + { 1017, 0x0000 }, { 1017, 0x0000 }, { 1017, 0x5000 }, { 1019, 0x0000 }, + { 1019, 0x0000 }, { 1019, 0x4040 }, { 1021, 0x8000 }, { 1022, 0x62ed }, + { 1031, 0x0020 }, { 1032, 0x0000 }, { 1032, 0x0000 }, { 1032, 0x0000 }, + { 1032, 0x0000 }, { 1032, 0x0000 }, { 1032, 0x0000 }, { 1032, 0x0000 }, + /* 0x8100 */ + { 1032, 0x0020 }, { 1033, 0x0800 }, { 1034, 0x0000 }, { 1034, 0x0200 }, + { 1035, 0x4400 }, { 1037, 0x0040 }, { 1038, 0x0842 }, { 1041, 0x0100 }, + { 1042, 0x0000 }, { 1042, 0x0400 }, { 1043, 0x0201 }, { 1045, 0xe000 }, + { 1048, 0xa200 }, { 1051, 0x8500 }, { 1054, 0x0101 }, { 1056, 0x0400 }, + /* 0x8200 */ + { 1057, 0x2780 }, { 1062, 0x0000 }, { 1062, 0x0000 }, { 1062, 0x0000 }, + { 1062, 0x0000 }, { 1062, 0x0200 }, { 1063, 0x0850 }, { 1066, 0x0082 }, + { 1068, 0x0000 }, { 1068, 0x0000 }, { 1068, 0x0000 }, { 1068, 0x0800 }, + { 1069, 0x0000 }, { 1069, 0x0000 }, { 1069, 0x0080 }, { 1070, 0x0200 }, + /* 0x8300 */ + { 1071, 0x0008 }, { 1072, 0x0000 }, { 1072, 0x0000 }, { 1072, 0x0000 }, + { 1072, 0x0000 }, { 1072, 0x0001 }, { 1073, 0x0000 }, { 1073, 0x0000 }, + { 1073, 0x0400 }, { 1074, 0x0040 }, { 1075, 0x0084 }, { 1077, 0x0000 }, + { 1077, 0x0000 }, { 1077, 0x0000 }, { 1077, 0x8000 }, { 1078, 0x0000 }, + /* 0x8400 */ + { 1078, 0x0480 }, { 1080, 0x0000 }, { 1080, 0x1000 }, { 1081, 0x0020 }, + { 1082, 0x0200 }, { 1083, 0x0004 }, { 1084, 0x8050 }, { 1087, 0x0080 }, + { 1088, 0x0000 }, { 1088, 0x0018 }, { 1090, 0x0000 }, { 1090, 0x1000 }, + { 1091, 0x0801 }, { 1093, 0x0000 }, { 1093, 0xc000 }, { 1095, 0x2000 }, + /* 0x8500 */ + { 1096, 0x0000 }, { 1096, 0x4010 }, { 1098, 0x2048 }, { 1101, 0x0000 }, + { 1101, 0x4042 }, { 1104, 0x012c }, { 1108, 0x2604 }, { 1112, 0x0080 }, + { 1113, 0x1500 }, { 1116, 0x8012 }, { 1119, 0x0240 }, { 1121, 0x0400 }, + { 1122, 0x6000 }, { 1124, 0x2000 }, { 1125, 0x0420 }, { 1127, 0x0650 }, + /* 0x8600 */ + { 1131, 0x08d0 }, { 1135, 0x4400 }, { 1137, 0x2004 }, { 1139, 0x8400 }, + { 1141, 0x0000 }, { 1141, 0x9020 }, { 1144, 0x0080 }, { 1145, 0x0000 }, + { 1145, 0x0000 }, { 1145, 0x0000 }, { 1145, 0x0000 }, { 1145, 0x0000 }, + { 1145, 0x0000 }, { 1145, 0x0000 }, { 1145, 0x0000 }, { 1145, 0x0400 }, + /* 0x8700 */ + { 1146, 0x0040 }, { 1147, 0x0000 }, { 1147, 0x0002 }, { 1148, 0x0000 }, + { 1148, 0x0000 }, { 1148, 0x0020 }, { 1149, 0x0040 }, { 1150, 0x0100 }, + { 1151, 0x0010 }, { 1152, 0x4000 }, { 1153, 0x0004 }, { 1154, 0x0800 }, + { 1155, 0x4110 }, { 1158, 0x0000 }, { 1158, 0x9008 }, { 1161, 0x0844 }, + /* 0x8800 */ + { 1164, 0x0060 }, { 1166, 0x8003 }, { 1169, 0x0008 }, { 1170, 0x0842 }, + { 1173, 0x0440 }, { 1175, 0x2808 }, { 1178, 0x0000 }, { 1178, 0x0200 }, + { 1179, 0x0000 }, { 1179, 0x0000 }, { 1179, 0x0000 }, { 1179, 0x0000 }, + { 1179, 0x8400 }, { 1181, 0x3000 }, { 1183, 0x0000 }, { 1183, 0x2000 }, + /* 0x8900 */ + { 1184, 0x0080 }, { 1185, 0x0000 }, { 1185, 0x0000 }, { 1185, 0x090c }, + { 1189, 0x0080 }, { 1190, 0x2040 }, { 1192, 0x9411 }, { 1197, 0x0004 }, + { 1198, 0x8800 }, { 1200, 0x0148 }, { 1203, 0x9442 }, { 1208, 0xa484 }, + { 1213, 0x0001 }, { 1214, 0x0000 }, { 1214, 0x0000 }, { 1214, 0x0150 }, + /* 0x8a00 */ + { 1217, 0x550e }, { 1224, 0xa969 }, { 1232, 0x2428 }, { 1236, 0x0452 }, + { 1240, 0x4042 }, { 1243, 0x4935 }, { 1250, 0x7a4e }, { 1259, 0x902f }, + { 1266, 0x20f0 }, { 1271, 0x4526 }, { 1277, 0x117b }, { 1285, 0x9245 }, + { 1291, 0xaa94 }, { 1298, 0x58c6 }, { 1305, 0x68d4 }, { 1312, 0x55ca }, + /* 0x8b00 */ + { 1320, 0x4437 }, { 1327, 0x2ed1 }, { 1335, 0x3902 }, { 1340, 0x4208 }, + { 1343, 0xc200 }, { 1346, 0x1740 }, { 1351, 0x8800 }, { 1353, 0x2091 }, + { 1357, 0x4401 }, { 1360, 0x506c }, { 1366, 0x0000 }, { 1366, 0x0000 }, + { 1366, 0x0000 }, { 1366, 0x0000 }, { 1366, 0x0000 }, { 1366, 0x0000 }, + /* 0x8c00 */ + { 1366, 0x0000 }, { 1366, 0x0000 }, { 1366, 0x0000 }, { 1366, 0x0000 }, + { 1366, 0x0100 }, { 1367, 0x0001 }, { 1368, 0x0000 }, { 1368, 0x0000 }, + { 1368, 0x0000 }, { 1368, 0x6000 }, { 1370, 0x9f87 }, { 1380, 0xbddd }, + { 1392, 0x05bf }, { 1401, 0x542e }, { 1408, 0x3cdf }, { 1419, 0x7c10 }, + /* 0x8d00 */ + { 1425, 0xad30 }, { 1432, 0x1841 }, { 1436, 0x0000 }, { 1436, 0x0000 }, + { 1436, 0x0000 }, { 1436, 0x0000 }, { 1436, 0x0000 }, { 1436, 0x0000 }, + { 1436, 0x0000 }, { 1436, 0x0220 }, { 1438, 0x0100 }, { 1439, 0x0004 }, + { 1440, 0x0000 }, { 1440, 0x0000 }, { 1440, 0x0000 }, { 1440, 0x0000 }, + /* 0x8e00 */ + { 1440, 0x0000 }, { 1440, 0x0001 }, { 1441, 0x0000 }, { 1441, 0x0010 }, + { 1442, 0x1000 }, { 1443, 0x0020 }, { 1444, 0x0008 }, { 1445, 0x0400 }, + { 1446, 0x2e00 }, { 1450, 0x040e }, { 1454, 0x0462 }, { 1458, 0x0000 }, + { 1458, 0x3c01 }, { 1463, 0x8814 }, { 1467, 0x0810 }, { 1469, 0x5f04 }, + /* 0x8f00 */ + { 1476, 0x06a8 }, { 1481, 0xf834 }, { 1489, 0x8660 }, { 1494, 0xc908 }, + { 1499, 0x6274 }, { 1506, 0x8010 }, { 1508, 0x0016 }, { 1511, 0x0000 }, + { 1511, 0x0000 }, { 1511, 0x0000 }, { 1511, 0xe040 }, { 1515, 0x0004 }, + { 1516, 0x0000 }, { 1516, 0x0000 }, { 1516, 0x0000 }, { 1516, 0x0010 }, + /* 0x9000 */ + { 1517, 0x0000 }, { 1517, 0x0220 }, { 1519, 0x0008 }, { 1520, 0x0004 }, + { 1521, 0x4800 }, { 1523, 0x5030 }, { 1527, 0x0201 }, { 1529, 0x1584 }, + { 1534, 0x8492 }, { 1539, 0x0001 }, { 1540, 0x0000 }, { 1540, 0x0000 }, + { 1540, 0x0002 }, { 1541, 0x8000 }, { 1542, 0x0000 }, { 1542, 0x0020 }, + /* 0x9100 */ + { 1543, 0x0240 }, { 1545, 0x0054 }, { 1548, 0x2080 }, { 1550, 0x0455 }, + { 1555, 0x0100 }, { 1556, 0x0000 }, { 1556, 0x0000 }, { 1556, 0x0000 }, + { 1556, 0x0000 }, { 1556, 0x1040 }, { 1558, 0x1800 }, { 1560, 0x0000 }, + { 1560, 0x182b }, { 1566, 0x23bc }, { 1574, 0x0298 }, { 1578, 0x06a0 }, + /* 0x9200 */ + { 1582, 0x6313 }, { 1589, 0x4033 }, { 1594, 0x40e8 }, { 1599, 0xe799 }, + { 1609, 0x2321 }, { 1614, 0x4ca2 }, { 1620, 0x3044 }, { 1624, 0x8d00 }, + { 1628, 0x0029 }, { 1631, 0x154a }, { 1637, 0x1f69 }, { 1646, 0x1a82 }, + { 1651, 0x90aa }, { 1657, 0xa004 }, { 1660, 0xe578 }, { 1669, 0x1143 }, + /* 0x9300 */ + { 1674, 0x01c2 }, { 1678, 0x8f25 }, { 1686, 0xc945 }, { 1693, 0x014c }, + { 1697, 0x28cb }, { 1704, 0x0910 }, { 1707, 0x1230 }, { 1711, 0x4461 }, + { 1716, 0x0494 }, { 1720, 0x0140 }, { 1722, 0x56cc }, { 1730, 0x8129 }, + { 1735, 0x3188 }, { 1740, 0xf182 }, { 1747, 0x0116 }, { 1751, 0x02a0 }, + /* 0x9400 */ + { 1754, 0x0808 }, { 1756, 0x231d }, { 1763, 0x41c1 }, { 1768, 0x852c }, + { 1774, 0x1410 }, { 1777, 0x0014 }, { 1779, 0x2029 }, { 1783, 0xf285 }, + { 1791, 0x0000 }, { 1791, 0x0000 }, { 1791, 0x0000 }, { 1791, 0x0000 }, + { 1791, 0x0000 }, { 1791, 0x0000 }, { 1791, 0x0000 }, { 1791, 0x0000 }, + /* 0x9500 */ + { 1791, 0x0000 }, { 1791, 0x0000 }, { 1791, 0x0000 }, { 1791, 0x0000 }, + { 1791, 0x0000 }, { 1791, 0x0000 }, { 1791, 0x0000 }, { 1791, 0x0080 }, + { 1792, 0xda4d }, { 1801, 0x011a }, { 1805, 0x3b3a }, { 1814, 0xfa44 }, + { 1822, 0x1d48 }, { 1828, 0x5071 }, { 1834, 0x0026 }, { 1837, 0x0000 }, + /* 0x9600 */ + { 1837, 0x0000 }, { 1837, 0x0000 }, { 1837, 0x0000 }, { 1837, 0x0000 }, + { 1837, 0x0000 }, { 1837, 0x2100 }, { 1839, 0x0008 }, { 1840, 0x2109 }, + { 1844, 0x4400 }, { 1846, 0x0820 }, { 1848, 0x0500 }, { 1850, 0x0912 }, + { 1854, 0x0000 }, { 1854, 0x1a40 }, { 1858, 0x000c }, { 1860, 0x0804 }, + /* 0x9700 */ + { 1862, 0x0000 }, { 1862, 0x0000 }, { 1862, 0x0080 }, { 1863, 0x2000 }, + { 1864, 0x0114 }, { 1867, 0x0400 }, { 1868, 0x0100 }, { 1869, 0x0000 }, + { 1869, 0x8000 }, { 1870, 0x0000 }, { 1870, 0x0040 }, { 1871, 0x2000 }, + { 1872, 0x1a48 }, { 1877, 0x5208 }, { 1881, 0x0000 }, { 1881, 0x8000 }, + /* 0x9800 */ + { 1882, 0xd5ee }, { 1893, 0x118f }, { 1900, 0x2052 }, { 1904, 0x2981 }, + { 1909, 0x7040 }, { 1913, 0x4b18 }, { 1919, 0x98a4 }, { 1925, 0x001b }, + { 1929, 0x0000 }, { 1929, 0x0000 }, { 1929, 0xc100 }, { 1932, 0x104a }, + { 1936, 0x0150 }, { 1939, 0x0800 }, { 1940, 0xae05 }, { 1947, 0x7014 }, + /* 0x9900 */ + { 1952, 0x1628 }, { 1957, 0x490e }, { 1963, 0x0102 }, { 1965, 0xd088 }, + { 1970, 0x1f28 }, { 1977, 0x5086 }, { 1982, 0x0004 }, { 1983, 0x0000 }, + { 1983, 0x0000 }, { 1983, 0x0000 }, { 1983, 0x7000 }, { 1986, 0x001a }, + { 1989, 0x0002 }, { 1990, 0xab37 }, { 2000, 0x2006 }, { 2003, 0x8002 }, + /* 0x9a00 */ + { 2005, 0xe022 }, { 2010, 0x0240 }, { 2012, 0x6800 }, { 2015, 0x41c1 }, + { 2020, 0xa43f }, { 2029, 0x8ca0 }, { 2034, 0x0434 }, { 2038, 0x0000 }, + { 2038, 0x0000 }, { 2038, 0x0000 }, { 2038, 0x8000 }, { 2039, 0x0000 }, + { 2039, 0x8000 }, { 2040, 0x0074 }, { 2044, 0x4000 }, { 2045, 0x0000 }, + /* 0x9b00 */ + { 2045, 0x2040 }, { 2047, 0x0400 }, { 2048, 0x42a4 }, { 2053, 0x0002 }, + { 2054, 0x4000 }, { 2055, 0x0500 }, { 2057, 0x8000 }, { 2058, 0x0090 }, + { 2060, 0x400a }, { 2063, 0x6407 }, { 2069, 0x6c00 }, { 2073, 0x0000 }, + { 2073, 0x0683 }, { 2078, 0x2850 }, { 2082, 0x0d96 }, { 2089, 0xa011 }, + /* 0x9c00 */ + { 2093, 0x2300 }, { 2096, 0x000d }, { 2099, 0x2329 }, { 2105, 0x4aae }, + { 2113, 0x0320 }, { 2116, 0xa1d4 }, { 2123, 0x2080 }, { 2125, 0x0500 }, + { 2127, 0x0000 }, { 2127, 0x0000 }, { 2127, 0x0000 }, { 2127, 0x0000 }, + { 2127, 0x0000 }, { 2127, 0x0000 }, { 2127, 0x1220 }, { 2130, 0x0058 }, + /* 0x9d00 */ + { 2133, 0x02c0 }, { 2136, 0xa820 }, { 2140, 0x8148 }, { 2144, 0x8801 }, + { 2147, 0x0004 }, { 2148, 0x300e }, { 2153, 0x9403 }, { 2158, 0x0004 }, + { 2159, 0x0280 }, { 2161, 0x0508 }, { 2164, 0x8220 }, { 2167, 0x1810 }, + { 2170, 0x0015 }, { 2173, 0x0688 }, { 2177, 0x8060 }, { 2180, 0x070c }, + /* 0x9e00 */ + { 2185, 0x1000 }, { 2186, 0x6c20 }, { 2191, 0x0000 }, { 2191, 0x0000 }, + { 2191, 0x0000 }, { 2191, 0x0000 }, { 2191, 0x0000 }, { 2191, 0x3620 }, + { 2196, 0x0000 }, { 2196, 0x0080 }, { 2197, 0x8220 }, { 2200, 0x2020 }, + { 2202, 0x1000 }, { 2203, 0x4000 }, { 2204, 0x0100 }, { 2205, 0xa094 }, + /* 0x9f00 */ + { 2210, 0x0200 }, { 2211, 0x0020 }, { 2212, 0x0000 }, { 2212, 0x0000 }, + { 2212, 0x8c00 }, { 2215, 0x9214 }, { 2220, 0x144b }, { 2226, 0x0084 }, + { 2228, 0x2000 }, { 2229, 0x1031 }, +}; +static const Summary16 gb12345ext_uni2indx_pagefe[5] = { + /* 0xfe00 */ + { 2233, 0x0000 }, { 2233, 0x0000 }, { 2233, 0x0000 }, { 2233, 0xfffa }, + { 2247, 0x001f }, +}; + +static int +gb12345ext_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc >= 0x0100 && wc < 0x0270) + summary = &gb12345ext_uni2indx_page01[(wc>>4)-0x010]; + else if (wc >= 0x1e00 && wc < 0x1e40) + summary = &gb12345ext_uni2indx_page1e[(wc>>4)-0x1e0]; + else if (wc >= 0x2200 && wc < 0x2230) + summary = &gb12345ext_uni2indx_page22[(wc>>4)-0x220]; + else if (wc >= 0x4e00 && wc < 0x9fa0) + summary = &gb12345ext_uni2indx_page4e[(wc>>4)-0x4e0]; + else if (wc >= 0xfe00 && wc < 0xfe50) + summary = &gb12345ext_uni2indx_pagefe[(wc>>4)-0xfe0]; + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = gb12345ext_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/gb18030.h b/graf2d/win32gdk/gdk/src/iconv/gb18030.h new file mode 100644 index 0000000000000..e9502e1bdd8f0 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/gb18030.h @@ -0,0 +1,382 @@ +/* + * Copyright (C) 1999-2001, 2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GB18030 + */ + +/* + * GB18030, as specified in the GB18030 standard, is an extension of GBK. + * + * In what follows, page numbers refer to the GB18030 standard (second + * printing). + * + * + * It consists of the following parts: + * + * One-byte range: + * ASCII p. 2 0x{00..7F} + * + * Two-byte range: + * GBK part 1 p. 10..12 0x{A1..A9}{A1..FE} + * GBK part 2 p. 13..36 0x{B0..F7}{A1..FE} + * GBK part 3 p. 37..52 0x{81..A0}{40..7E,80..FE} + * GBK part 4 p. 53..81 0x{AA..FE}{40..7E,80..A0} + * GBK part 5 p. 82 0x{A8..A9}{40..7E,80..A0} + * UDA part 1 p. 83..84 0x{AA..AF}{A1..FE} U+E000..U+E233 + * UDA part 2 p. 85..87 0x{F8..FE}{A1..FE} U+E234..U+E4C5 + * UDA part 3 p. 88..90 0x{A1..A7}{40..7E,80..A0} U+E4C6..U+E765 + * + * Four-byte range: + * BMP rest p. 94..283 0x{81..84}{30..39}{81..FE}{30..39} + * rest of U+0080..U+FFFF + * Planes 1-16 p. 5 0x{90..FE}{30..39}{81..FE}{30..39} + * U+10000..U+10FFFF + * + * To GBK part 1 were added: + * 1. 0xA2E3, 0xA8BF. + * 2. Characters mapped to the Unicode PUA + * 0xA2AB..0xA2B0 U+E766..U+E76B + * 0xA2E4 U+E76D + * 0xA2EF..0xA2F0 U+E76E..U+E76F + * 0xA2FD..0xA2FE U+E770..U+E771 + * 0xA4F4..0xA4FE U+E772..U+E77C + * 0xA5F7..0xA5FE U+E77D..U+E784 + * 0xA6B9..0xA6C0 U+E785..U+E78C + * 0xA6D9..0xA6DF [glyphs here!!] U+E78D..U+E793 + * 0xA6EC..0xA6ED [glyphs here!!] U+E794..U+E795 + * 0xA6F3 [glyphs here!!] U+E796 + * 0xA6F6..0xA6FE U+E797..U+E79F + * 0xA7C2..0xA7D0 U+E7A0..U+E7AE + * 0xA7F2..0xA7FE U+E7AF..U+E7BB + * 0xA8BC [glyphs here!!] U+E7C7 + * 0xA8C1..0xA8C4 U+E7C9..U+E7CC + * 0xA8EA..0xA8FE U+E7CD..U+E7E1 + * 0xA9A1..0xA9A3 U+E7FE..U+E800 + * 0xA9F0..0xA9FE U+E801..U+E80F + * + * To GBK part 2 were added: + * 3. Characters mapped to the Unicode PUA + * 0xD7FA..0xD7FE U+E810..0xE814 + * + * To GBK part 3 nothing was added. + * + * To GBK part 4 were added: + * 4. 0xFE{50,54..58,5A..60,62..65,68..6B,6E..75,77..7D,80..8F,92..9F}. + * 5. Characters mapped to the Unicode PUA + * 0xFE51..0xFE53 [glyphs here!!] U+E816..U+E818 + * 0xFE59 [glyphs here!!] U+E81E + * 0xFE61 [glyphs here!!] U+E826 + * 0xFE66..0xFE67 [glyphs here!!] U+E82B..U+E82C + * 0xFE6C..0xFE6D [glyphs here!!] U+E831..U+E832 + * 0xFE76 [glyphs here!!] U+E83B + * 0xFE7E [glyphs here!!] U+E843 + * 0xFE90..0xFE91 [glyphs here!!] U+E854..U+E855 + * 0xFEA0 [glyphs here!!] U+E864 + * + * To GBK part 5 were added: + * 6. 0xA98A..0xA995. + * 7. Characters mapped to the Unicode PUA + * 0xA896..0xA8A0 U+E7BC..U+E7C6 + * 0xA958 U+E7E2 + * 0xA95B U+E7E3 + * 0xA95D..0xA95F U+E7E4..U+E7E6 + * 0xA997..0xA9A0 U+E7F4..U+E7FD + * + * UDA part 1 contains the user-defined characters, mapped to the Unicode PUA + * U+E000..U+E233 in ascending order. + * + * UDA part 2 contains the user-defined characters, mapped to the Unicode PUA + * U+E234..U+E4C5 in ascending order. + * + * UDA part 3 contains the user-defined characters, mapped to the Unicode PUA + * U+E4C6..U+E765 in ascending order. + * + * The four-byte range 0x{81..84}{30..39}{81..FE}{30..39} + * contains the rest of the Unicode BMP in ascending order. + * Start: 0x81308130 = 0x0080 + * End: 0x8431A439 = 0xFFFF + * + * The four-byte range 0x{90..E3}{30..39}{81..FE}{30..39} + * contains the remaining 16 Unicode planes in Unicode order. + * Start: 0x90308130 = 0x010000 + * End: 0xE3329A35 = 0x10FFFF + * + * + * Unassigned Unicode characters are mapped. For example, + * U+173F = 0x8134BF35 (p. 120) + * U+2EFF = 0x81398B31 (p. 148) + * U+FFFE = 0x8431A438 (p. 283) + * + * + * The Unicode PUA (U+E000..U+F8FF) is mapped as follows: + * p. 83..84 0x{AA..AF}{A1..FE} U+E000..U+E233 + * p. 85..87 0x{F8..FE}{A1..FE} U+E234..U+E4C5 + * p. 88..90 0x{A1..A7}{40..7E,80..A0} U+E4C6..U+E765 + * p. 10 0xA2AB..0xA2B0 U+E766..U+E76B + * p. 255 0x8336C739 U+E76C + * p. 10 0xA2E4 U+E76D + * p. 10 0xA2EF..0xA2F0 U+E76E..U+E76F + * p. 10 0xA2FD..0xA2FE U+E770..U+E771 + * p. 11 0xA4F4..0xA4FE U+E772..U+E77C + * p. 11 0xA5F7..0xA5FE U+E77D..U+E784 + * p. 11 0xA6B9..0xA6C0 U+E785..U+E78C + * p. 11 0xA6D9..0xA6DF [glyphs here!!] U+E78D..U+E793 + * p. 11 0xA6EC..0xA6ED [glyphs here!!] U+E794..U+E795 + * p. 11 0xA6F3 [glyphs here!!] U+E796 + * p. 11 0xA6F6..0xA6FE U+E797..U+E79F + * p. 12 0xA7C2..0xA7D0 U+E7A0..U+E7AE + * p. 12 0xA7F2..0xA7FE U+E7AF..U+E7BB + * p. 82 0xA896..0xA8A0 U+E7BC..U+E7C6 + * p. 12 0xA8BC [glyphs here!!] U+E7C7 + * p. 255 0x8336C830 U+E7C8 + * p. 12 0xA8C1..0xA8C4 U+E7C9..U+E7CC + * p. 12 0xA8EA..0xA8FE U+E7CD..U+E7E1 + * p. 82 0xA958 U+E7E2 + * p. 82 0xA95B U+E7E3 + * p. 82 0xA95D..0xA95F U+E7E4..U+E7E6 + * p. 255 0x8336C831..0x8336C933 U+E7E7..U+E7F3 + * p. 82 0xA997..0xA9A0 U+E7F4..U+E7FD + * p. 12 0xA9A1..0xA9A3 U+E7FE..U+E800 + * p. 12 0xA9F0..0xA9FE U+E801..U+E80F + * p. 26 0xD7FA..0xD7FE U+E810..0xE814 + * p. 255 0x8336C934 U+E815 + * p. 81 0xFE51..0xFE53 [glyphs here!!] U+E816..U+E818 + * p. 255 0x8336C935..0x8336C939 U+E819..U+E81D + * p. 81 0xFE59 [glyphs here!!] U+E81E + * p. 255 0x8336CA30..0x8336CA36 U+E81F..U+E825 + * p. 81 0xFE61 [glyphs here!!] U+E826 + * p. 255 0x8336CA37..0x8336CB30 U+E827..U+E82A + * p. 81 0xFE66..0xFE67 [glyphs here!!] U+E82B..U+E82C + * p. 255 0x8336CB31..0x8336CB34 U+E82D..U+E830 + * p. 81 0xFE6C..0xFE6D [glyphs here!!] U+E831..U+E832 + * p. 255 0x8336CB35..0x8336CC32 U+E833..U+E83A + * p. 81 0xFE76 [glyphs here!!] U+E83B + * p. 255 0x8336CC33..0x8336CC39 U+E83C..U+E842 + * p. 81 0xFE7E [glyphs here!!] U+E843 + * p. 255 0x8336CD30..0x8336CE35 U+E844..U+E853 + * p. 81 0xFE90..0xFE91 [glyphs here!!] U+E854..U+E855 + * p. 255 0x8336CE36..0x8336CF39 U+E856..U+E863 + * p. 81 0xFEA0 [glyphs here!!] U+E864 + * p. 255..276 0x8336D030..0x84308130 U+E865..U+F8FF + * + * + * The Unicode surrogate area (U+D800..U+DFFF) is not mapped. (p. 255) + * + */ + +#include "gb18030ext.h" +#include "gb18030uni.h" + +static int +gb18030_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + int ret; + + /* Code set 0 (ASCII) */ + if (*s < 0x80) + return ascii_mbtowc(conv,pwc,s,n); + + /* Code set 1 (GBK extended) */ + ret = gbk_mbtowc(conv,pwc,s,n); + if (ret != RET_ILSEQ) + return ret; + + ret = gb18030ext_mbtowc(conv,pwc,s,n); + if (ret != RET_ILSEQ) + return ret; + + /* Code set 2 (remainder of Unicode U+0000..U+FFFF), including + User-defined characters, two-byte part of range U+E766..U+E864 */ + ret = gb18030uni_mbtowc(conv,pwc,s,n); + if (ret != RET_ILSEQ) + return ret; + /* User-defined characters range U+E000..U+E765 */ + { + unsigned char c1 = s[0]; + if ((c1 >= 0xaa && c1 <= 0xaf) || (c1 >= 0xf8 && c1 <= 0xfe)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 <= 0xfe) { + *pwc = 0xe000 + 94 * (c1 >= 0xf8 ? c1 - 0xf2 : c1 - 0xaa) + (c2 - 0xa1); + return 2; + } + } else + return RET_TOOFEW(0); + } else if (c1 >= 0xa1 && c1 <= 0xa7) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x40 && c2 <= 0xa1 && c2 != 0x7f) { + *pwc = 0xe4c6 + 96 * (c1 - 0xa1) + c2 - (c2 >= 0x80 ? 0x41 : 0x40); + return 2; + } + } else + return RET_TOOFEW(0); + } + } + + /* Code set 3 (Unicode U+10000..U+10FFFF) */ + { + unsigned char c1 = s[0]; + if (c1 >= 0x90 && c1 <= 0xe3) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x30 && c2 <= 0x39) { + if (n >= 3) { + unsigned char c3 = s[2]; + if (c3 >= 0x81 && c3 <= 0xfe) { + if (n >= 4) { + unsigned char c4 = s[3]; + if (c4 >= 0x30 && c4 <= 0x39) { + unsigned int i = (((c1 - 0x90) * 10 + (c2 - 0x30)) * 126 + (c3 - 0x81)) * 10 + (c4 - 0x30); + if (i >= 0 && i < 0x100000) { + *pwc = (ucs4_t) (0x10000 + i); + return 4; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; + } +} + +static const unsigned short gb18030_pua2charset[32*3] = { +/* Unicode range GB18030 range */ + 0xe766, 0xe76b, 0xa2ab, /*.. 0xa2b0, */ + 0xe76d, 0xe76d, 0xa2e4, + 0xe76e, 0xe76f, 0xa2ef, /*.. 0xa2f0, */ + 0xe770, 0xe771, 0xa2fd, /*.. 0xa2fe, */ + 0xe772, 0xe77c, 0xa4f4, /*.. 0xa4fe, */ + 0xe77d, 0xe784, 0xa5f7, /*.. 0xa5fe, */ + 0xe785, 0xe78c, 0xa6b9, /*.. 0xa6c0, */ + 0xe78d, 0xe793, 0xa6d9, /*.. 0xa6df, */ + 0xe794, 0xe795, 0xa6ec, /*.. 0xa6ed, */ + 0xe796, 0xe796, 0xa6f3, + 0xe797, 0xe79f, 0xa6f6, /*.. 0xa6fe, */ + 0xe7a0, 0xe7ae, 0xa7c2, /*.. 0xa7d0, */ + 0xe7af, 0xe7bb, 0xa7f2, /*.. 0xa7fe, */ + 0xe7bc, 0xe7c6, 0xa896, /*.. 0xa8a0, */ + 0xe7c7, 0xe7c7, 0xa8bc, + 0xe7c9, 0xe7cc, 0xa8c1, /*.. 0xa8c4, */ + 0xe7cd, 0xe7e1, 0xa8ea, /*.. 0xa8fe, */ + 0xe7e2, 0xe7e2, 0xa958, + 0xe7e3, 0xe7e3, 0xa95b, + 0xe7e4, 0xe7e6, 0xa95d, /*.. 0xa95f, */ + 0xe7f4, 0xe800, 0xa997, /*.. 0xa9a3, */ + 0xe801, 0xe80f, 0xa9f0, /*.. 0xa9fe, */ + 0xe810, 0xe814, 0xd7fa, /*.. 0xd7fe, */ + 0xe816, 0xe818, 0xfe51, /*.. 0xfe53, */ + 0xe81e, 0xe81e, 0xfe59, + 0xe826, 0xe826, 0xfe61, + 0xe82b, 0xe82c, 0xfe66, /*.. 0xfe67, */ + 0xe831, 0xe832, 0xfe6c, /*.. 0xfe6d, */ + 0xe83b, 0xe83b, 0xfe76, + 0xe843, 0xe843, 0xfe7e, + 0xe854, 0xe855, 0xfe90, /*.. 0xfe91, */ + 0xe864, 0xe864, 0xfea0, +}; + +static int +gb18030_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + int ret; + + /* Code set 0 (ASCII) */ + ret = ascii_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + /* Code set 1 (GBK extended) */ + ret = gbk_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + ret = gb18030ext_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + /* Code set 2 (remainder of Unicode U+0000..U+FFFF) */ + if (wc >= 0xe000 && wc <= 0xe864) { + if (n >= 2) { + if (wc < 0xe766) { + /* User-defined characters range U+E000..U+E765 */ + if (wc < 0xe4c6) { + unsigned int i = wc - 0xe000; + r[1] = (i % 94) + 0xa1; i = i / 94; + r[0] = (i < 6 ? i + 0xaa : i + 0xf2); + return 2; + } else { + unsigned int i = wc - 0xe4c6; + r[0] = (i / 96) + 0xa1; i = i % 96; + r[1] = i + (i >= 0x3f ? 0x41 : 0x40); + return 2; + } + } else { + /* User-defined characters, two-byte part of range U+E766..U+E864 */ + unsigned int k1 = 0; + unsigned int k2 = 32; + /* Invariant: We know that if wc occurs in Unicode interval in + gb18030_pua2charset, it does so at a k with k1 <= k < k2. */ + while (k1 < k2) { + unsigned int k = (k1 + k2) / 2; + if (wc < gb18030_pua2charset[k*3+0]) + k2 = k; + else if (wc > gb18030_pua2charset[k*3+1]) + k1 = k + 1; + else { + unsigned short c = + gb18030_pua2charset[k*3+2] + (wc - gb18030_pua2charset[k*3+0]); + r[0] = (c >> 8); + r[1] = (c & 0xff); + return 2; + } + } + } + } else + return RET_TOOSMALL; + } + ret = gb18030uni_wctomb(conv,r,wc,n); + if (ret != RET_ILUNI) + return ret; + + /* Code set 3 (Unicode U+10000..U+10FFFF) */ + if (n >= 4) { + if (wc >= 0x10000 && wc < 0x110000) { + unsigned int i = wc - 0x10000; + r[3] = (i % 10) + 0x30; i = i / 10; + r[2] = (i % 126) + 0x81; i = i / 126; + r[1] = (i % 10) + 0x30; i = i / 10; + r[0] = i + 0x90; + return 4; + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/gb18030ext.h b/graf2d/win32gdk/gdk/src/iconv/gb18030ext.h new file mode 100644 index 0000000000000..14b0e452ed0f6 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/gb18030ext.h @@ -0,0 +1,300 @@ +/* + * Copyright (C) 1999-2001, 2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GB18030 two-byte extension + */ + +static const unsigned short gb18030ext_2uni_pagea9[13] = { + /* 0xa9 */ + 0x303e, 0x2ff0, 0x2ff1, 0x2ff2, 0x2ff3, 0x2ff4, 0x2ff5, 0x2ff6, + 0x2ff7, 0x2ff8, 0x2ff9, 0x2ffa, 0x2ffb, +}; +static const unsigned short gb18030ext_2uni_pagefe[96] = { + /* 0xfe */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x2e81, 0xe816, 0xe817, 0xe818, 0x2e84, 0x3473, 0x3447, 0x2e88, + 0x2e8b, 0xe81e, 0x359e, 0x361a, 0x360e, 0x2e8c, 0x2e97, 0x396e, + 0x3918, 0xe826, 0x39cf, 0x39df, 0x3a73, 0x39d0, 0xe82b, 0xe82c, + 0x3b4e, 0x3c6e, 0x3ce0, 0x2ea7, 0xe831, 0xe832, 0x2eaa, 0x4056, + 0x415f, 0x2eae, 0x4337, 0x2eb3, 0x2eb6, 0x2eb7, 0xe83b, 0x43b1, + 0x43ac, 0x2ebb, 0x43dd, 0x44d6, 0x4661, 0x464c, 0xe843, 0x4723, + 0x4729, 0x477c, 0x478d, 0x2eca, 0x4947, 0x497a, 0x497d, 0x4982, + 0x4983, 0x4985, 0x4986, 0x499f, 0x499b, 0x49b7, 0x49b6, 0xe854, + 0xe855, 0x4ca3, 0x4c9f, 0x4ca0, 0x4ca1, 0x4c77, 0x4ca2, 0x4d13, + 0x4d14, 0x4d15, 0x4d16, 0x4d17, 0x4d18, 0x4d19, 0x4dae, 0xe864, +}; + +static int +gb18030ext_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 == 0xa2) || (c1 >= 0xa4 && c1 <= 0xa9) || (c1 == 0xd7) || (c1 == 0xfe)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0x80 && c2 < 0xff)) { + unsigned int i = 190 * (c1 - 0x81) + (c2 - (c2 >= 0x80 ? 0x41 : 0x40)); + unsigned short wc = 0xfffd; + switch (c1) { + case 0xa2: + if (i >= 6376 && i <= 6381) /* 0xA2AB..0xA2B0 */ + wc = 0xe766 + (i - 6376); + else if (i == 6432) /* 0xA2E3 */ + wc = 0x20ac; + else if (i == 6433) /* 0xA2E4 */ + wc = 0xe76d; + else if (i >= 6444 && i <= 6445) /* 0xA2EF..0xA2F0 */ + wc = 0xe76e + (i - 6444); + else if (i >= 6458 && i <= 6459) /* 0xA2FD..0xA2FE */ + wc = 0xe770 + (i - 6458); + break; + case 0xa4: + if (i >= 6829 && i <= 6839) /* 0xA4F4..0xA4FE */ + wc = 0xe772 + (i - 6829); + break; + case 0xa5: + if (i >= 7022 && i <= 7029) /* 0xA5F7..0xA5FE */ + wc = 0xe77d + (i - 7022); + break; + case 0xa6: + if (i >= 7150 && i <= 7157) /* 0xA6B9..0xA6C0 */ + wc = 0xe785 + (i - 7150); + else if (i >= 7182 && i <= 7190) /* 0xA6D9..0xA6DF */ + wc = 0xe78d + (i - 7182); + else if (i >= 7201 && i <= 7202) /* 0xA6EC..0xA6ED */ + wc = 0xe794 + (i - 7201); + else if (i == 7208) /* 0xA6F3 */ + wc = 0xe796; + else if (i >= 7211 && i <= 7219) /* 0xA6F6..0xA6FE */ + wc = 0xe797 + (i - 7211); + break; + case 0xa7: + if (i >= 7349 && i <= 7363) /* 0xA7C2..0xA7D0 */ + wc = 0xe7a0 + (i - 7349); + else if (i >= 7397 && i <= 7409) /* 0xA7F2..0xA7FE */ + wc = 0xe7af + (i - 7397); + break; + case 0xa8: + if (i >= 7495 && i <= 7505) /* 0xA896..0xA8A0 */ + wc = 0xe7bc + (i - 7495); + else if (i == 7533) /* 0xA8BC */ + wc = 0xe7c7; + else if (i == 7536) /* 0xA8BF */ + wc = 0x01f9; + else if (i >= 7538 && i <= 7541) /* 0xA8C1..0xA8C4 */ + wc = 0xe7c9 + (i - 7538); + else if (i >= 7579 && i <= 7599) /* 0xA8EA..0xA8FE */ + wc = 0xe7cd + (i - 7579); + break; + case 0xa9: + if (i == 7624) /* 0xA958 */ + wc = 0xe7e2; + else if (i == 7627) /* 0xA95B */ + wc = 0xe7e3; + else if (i >= 7629 && i <= 7631) /* 0xA95D..0xA95F */ + wc = 0xe7e4 + (i - 7629); + else if (i >= 7672 && i < 7685) /* 0xA989..0xA995 */ + wc = gb18030ext_2uni_pagea9[i-7672]; + else if (i >= 7686 && i <= 7698) /* 0xA997..0xA9A3 */ + wc = 0xe7f4 + (i - 7686); + else if (i >= 7775 && i <= 7789) /* 0xA9F0..0xA9FE */ + wc = 0xe801 + (i - 7775); + break; + case 0xd7: + if (i >= 16525 && i <= 16529) /* 0xD7FA..0xD7FE */ + wc = 0xe810 + (i - 16525); + break; + case 0xfe: + if (i < 23846) + wc = gb18030ext_2uni_pagefe[i-23750]; + break; + default: + break; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short gb18030ext_page2e[80] = { + 0x0000, 0xfe50, 0x0000, 0x0000, 0xfe54, 0x0000, 0x0000, 0x0000, /*0x80-0x87*/ + 0xfe57, 0x0000, 0x0000, 0xfe58, 0xfe5d, 0x0000, 0x0000, 0x0000, /*0x88-0x8f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xfe5e, /*0x90-0x97*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x98-0x9f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xfe6b, /*0xa0-0xa7*/ + 0x0000, 0x0000, 0xfe6e, 0x0000, 0x0000, 0x0000, 0xfe71, 0x0000, /*0xa8-0xaf*/ + 0x0000, 0x0000, 0x0000, 0xfe73, 0x0000, 0x0000, 0xfe74, 0xfe75, /*0xb0-0xb7*/ + 0x0000, 0x0000, 0x0000, 0xfe79, 0x0000, 0x0000, 0x0000, 0x0000, /*0xb8-0xbf*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0xc0-0xc7*/ + 0x0000, 0x0000, 0xfe84, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0xc8-0xcf*/ +}; +static const unsigned short gb18030ext_page2f[16] = { + 0xa98a, 0xa98b, 0xa98c, 0xa98d, 0xa98e, 0xa98f, 0xa990, 0xa991, /*0xf0-0xf7*/ + 0xa992, 0xa993, 0xa994, 0xa995, 0x0000, 0x0000, 0x0000, 0x0000, /*0xf8-0xff*/ +}; +static const unsigned short gb18030ext_page34[56] = { + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xfe56, /*0x40-0x47*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x48-0x4f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x50-0x57*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x58-0x5f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x60-0x67*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x68-0x6f*/ + 0x0000, 0x0000, 0x0000, 0xfe55, 0x0000, 0x0000, 0x0000, 0x0000, /*0x70-0x77*/ +}; +static const unsigned short gb18030ext_page36[24] = { + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xfe5c, 0x0000, /*0x08-0x0f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x10-0x17*/ + 0x0000, 0x0000, 0xfe5b, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x18-0x1f*/ +}; +static const unsigned short gb18030ext_page39[24] = { + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xfe62, /*0xc8-0xcf*/ + 0xfe65, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0xd0-0xd7*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xfe63, /*0xd8-0xdf*/ +}; +static const unsigned short gb18030ext_page43[56] = { + 0x0000, 0x0000, 0x0000, 0x0000, 0xfe78, 0x0000, 0x0000, 0x0000, /*0xa8-0xaf*/ + 0x0000, 0xfe77, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0xb0-0xb7*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0xb8-0xbf*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0xc0-0xc7*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0xc8-0xcf*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0xd0-0xd7*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xfe7a, 0x0000, 0x0000, /*0xd8-0xdf*/ +}; +static const unsigned short gb18030ext_page46[32] = { + 0x0000, 0x0000, 0x0000, 0x0000, 0xfe7d, 0x0000, 0x0000, 0x0000, /*0x48-0x4f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x50-0x57*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x58-0x5f*/ + 0x0000, 0xfe7c, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x60-0x67*/ +}; +static const unsigned short gb18030ext_page47_1[16] = { + 0x0000, 0x0000, 0x0000, 0xfe80, 0x0000, 0x0000, 0x0000, 0x0000, /*0x20-0x27*/ + 0x0000, 0xfe81, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x28-0x2f*/ +}; +static const unsigned short gb18030ext_page47_2[24] = { + 0x0000, 0x0000, 0x0000, 0x0000, 0xfe82, 0x0000, 0x0000, 0x0000, /*0x78-0x7f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x80-0x87*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xfe83, 0x0000, 0x0000, /*0x88-0x8f*/ +}; +static const unsigned short gb18030ext_page49[120] = { + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xfe85, /*0x40-0x47*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x48-0x4f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x50-0x57*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x58-0x5f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x60-0x67*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x68-0x6f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x70-0x77*/ + 0x0000, 0x0000, 0xfe86, 0x0000, 0x0000, 0xfe87, 0x0000, 0x0000, /*0x78-0x7f*/ + 0x0000, 0x0000, 0xfe88, 0xfe89, 0x0000, 0xfe8a, 0xfe8b, 0x0000, /*0x80-0x87*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x88-0x8f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x90-0x97*/ + 0x0000, 0x0000, 0x0000, 0xfe8d, 0x0000, 0x0000, 0x0000, 0xfe8c, /*0x98-0x9f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0xa0-0xa7*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0xa8-0xaf*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xfe8f, 0xfe8e, /*0xb0-0xb7*/ +}; +static const unsigned short gb18030ext_page4c[56] = { + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xfe96, /*0x70-0x77*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x78-0x7f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x80-0x87*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x88-0x8f*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x90-0x97*/ + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0xfe93, /*0x98-0x9f*/ + 0xfe94, 0xfe95, 0xfe97, 0xfe92, 0x0000, 0x0000, 0x0000, 0x0000, /*0xa0-0xa7*/ +}; +static const unsigned short gb18030ext_page4d[16] = { + 0x0000, 0x0000, 0x0000, 0xfe98, 0xfe99, 0xfe9a, 0xfe9b, 0xfe9c, /*0x10-0x17*/ + 0xfe9d, 0xfe9e, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*0x18-0x1f*/ +}; + +static int +gb18030ext_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + unsigned short c = 0; + if (wc == 0x01f9) + c = 0xa8bf; + else if (wc == 0x20ac) + c = 0xa2e3; + else if (wc >= 0x2e80 && wc < 0x2ed0) + c = gb18030ext_page2e[wc-0x2e80]; + else if (wc >= 0x2ff0 && wc < 0x3000) + c = gb18030ext_page2f[wc-0x2ff0]; + else if (wc == 0x303e) + c = 0xa989; + else if (wc >= 0x3440 && wc < 0x3478) + c = gb18030ext_page34[wc-0x3440]; + else if (wc == 0x359e) + c = 0xfe5a; + else if (wc >= 0x3608 && wc < 0x3620) + c = gb18030ext_page36[wc-0x3608]; + else if (wc == 0x3918) + c = 0xfe60; + else if (wc == 0x396e) + c = 0xfe5f; + else if (wc >= 0x39c8 && wc < 0x39e0) + c = gb18030ext_page39[wc-0x39c8]; + else if (wc == 0x3a73) + c = 0xfe64; + else if (wc == 0x3b4e) + c = 0xfe68; + else if (wc == 0x3c6e) + c = 0xfe69; + else if (wc == 0x3ce0) + c = 0xfe6a; + else if (wc == 0x4056) + c = 0xfe6f; + else if (wc == 0x415f) + c = 0xfe70; + else if (wc == 0x4337) + c = 0xfe72; + else if (wc >= 0x43a8 && wc < 0x43e0) + c = gb18030ext_page43[wc-0x43a8]; + else if (wc == 0x44d6) + c = 0xfe7b; + else if (wc >= 0x4648 && wc < 0x4668) + c = gb18030ext_page46[wc-0x4648]; + else if (wc >= 0x4720 && wc < 0x4730) + c = gb18030ext_page47_1[wc-0x4720]; + else if (wc >= 0x4778 && wc < 0x4790) + c = gb18030ext_page47_2[wc-0x4778]; + else if (wc >= 0x4940 && wc < 0x49b8) + c = gb18030ext_page49[wc-0x4940]; + else if (wc >= 0x4c70 && wc < 0x4ca8) + c = gb18030ext_page4c[wc-0x4c70]; + else if (wc >= 0x4d10 && wc < 0x4d20) + c = gb18030ext_page4d[wc-0x4d10]; + else if (wc == 0x4dae) + c = 0xfe9f; + if (c != 0) { + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/gb18030uni.h b/graf2d/win32gdk/gdk/src/iconv/gb18030uni.h new file mode 100644 index 0000000000000..bea31e513b7f7 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/gb18030uni.h @@ -0,0 +1,249 @@ +/* + * Copyright (C) 1999-2001, 2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GB18030 four-byte extension + */ + +static const unsigned short gb18030uni_charset2uni_ranges[412] = { + 0x0000, 0x0023, 0x0024, 0x0025, 0x0026, 0x002c, 0x002d, 0x0031, + 0x0032, 0x0050, 0x0051, 0x0058, 0x0059, 0x005e, 0x005f, 0x005f, + 0x0060, 0x0063, 0x0064, 0x0066, 0x0067, 0x0067, 0x0068, 0x0068, + 0x0069, 0x006c, 0x006d, 0x007d, 0x007e, 0x0084, 0x0085, 0x0093, + 0x0094, 0x00ab, 0x00ac, 0x00ae, 0x00af, 0x00b2, 0x00b3, 0x00cf, + 0x00d0, 0x0131, 0x0132, 0x0132, 0x0133, 0x0133, 0x0134, 0x0134, + 0x0135, 0x0135, 0x0136, 0x0136, 0x0137, 0x0137, 0x0138, 0x0138, + 0x0139, 0x0154, 0x0155, 0x01ab, 0x01ac, 0x01ba, 0x01bb, 0x021f, + 0x0220, 0x0220, 0x0221, 0x022d, 0x022e, 0x02e4, 0x02e5, 0x02e5, + 0x02e6, 0x02ec, 0x02ed, 0x02ed, 0x02ee, 0x0324, 0x0325, 0x0332, + 0x0333, 0x0333, 0x0334, 0x1ef1, 0x1ef2, 0x1ef3, 0x1ef4, 0x1ef4, + 0x1ef5, 0x1ef6, 0x1ef7, 0x1efd, 0x1efe, 0x1f06, 0x1f07, 0x1f07, + 0x1f08, 0x1f08, 0x1f09, 0x1f0d, 0x1f0e, 0x1f7d, 0x1f7e, 0x1fd3, + 0x1fd4, 0x1fd4, 0x1fd5, 0x1fd7, 0x1fd8, 0x1fe3, 0x1fe4, 0x1fed, + 0x1fee, 0x202b, 0x202c, 0x202f, 0x2030, 0x2045, 0x2046, 0x2047, + 0x2048, 0x20b5, 0x20b6, 0x20bb, 0x20bc, 0x20bc, 0x20bd, 0x20bf, + 0x20c0, 0x20c3, 0x20c4, 0x20c5, 0x20c6, 0x20c7, 0x20c8, 0x20c8, + 0x20c9, 0x20c9, 0x20ca, 0x20cb, 0x20cc, 0x20d0, 0x20d1, 0x20d5, + 0x20d6, 0x20df, 0x20e0, 0x20e2, 0x20e3, 0x20e7, 0x20e8, 0x20f4, + 0x20f5, 0x20f6, 0x20f7, 0x20fc, 0x20fd, 0x2121, 0x2122, 0x2124, + 0x2125, 0x212f, 0x2130, 0x2148, 0x2149, 0x219a, 0x219b, 0x22e7, + 0x22e8, 0x22f1, 0x22f2, 0x2355, 0x2356, 0x2359, 0x235a, 0x2366, + 0x2367, 0x2369, 0x236a, 0x2373, 0x2374, 0x2383, 0x2384, 0x238b, + 0x238c, 0x2393, 0x2394, 0x2396, 0x2397, 0x2398, 0x2399, 0x23aa, + 0x23ab, 0x23c9, 0x23ca, 0x23cb, 0x23cc, 0x2401, 0x2402, 0x2402, + 0x2403, 0x2c40, 0x2c41, 0x2c42, 0x2c43, 0x2c45, 0x2c46, 0x2c47, + 0x2c48, 0x2c51, 0x2c52, 0x2c60, 0x2c61, 0x2c62, 0x2c63, 0x2c65, + 0x2c66, 0x2c69, 0x2c6a, 0x2c6b, 0x2c6c, 0x2c6e, 0x2c6f, 0x2c7c, + 0x2c7d, 0x2da1, 0x2da2, 0x2da5, 0x2da6, 0x2da6, 0x2da7, 0x2dab, + 0x2dac, 0x2dad, 0x2dae, 0x2dc1, 0x2dc2, 0x2dc3, 0x2dc4, 0x2dca, + 0x2dcb, 0x2dcc, 0x2dcd, 0x2dd1, 0x2dd2, 0x2dd7, 0x2dd8, 0x2ecd, + 0x2ece, 0x2ed4, 0x2ed5, 0x2f45, 0x2f46, 0x302f, 0x3030, 0x303b, + 0x303c, 0x303d, 0x303e, 0x305f, 0x3060, 0x3068, 0x3069, 0x306a, + 0x306b, 0x306c, 0x306d, 0x30dd, 0x30de, 0x3108, 0x3109, 0x3232, + 0x3233, 0x32a1, 0x32a2, 0x32ac, 0x32ad, 0x35a9, 0x35aa, 0x35fe, + 0x35ff, 0x365e, 0x365f, 0x366c, 0x366d, 0x36ff, 0x3700, 0x37d9, + 0x37da, 0x38f8, 0x38f9, 0x3969, 0x396a, 0x3cde, 0x3cdf, 0x3de6, + 0x3de7, 0x3fbd, 0x3fbe, 0x4031, 0x4032, 0x4035, 0x4036, 0x4060, + 0x4061, 0x4158, 0x4159, 0x42cd, 0x42ce, 0x42e1, 0x42e2, 0x43a2, + 0x43a3, 0x43a7, 0x43a8, 0x43f9, 0x43fa, 0x4409, 0x440a, 0x45c2, + 0x45c3, 0x45f4, 0x45f5, 0x45f6, 0x45f7, 0x45fa, 0x45fb, 0x45fb, + 0x45fc, 0x460f, 0x4610, 0x4612, 0x4613, 0x4628, 0x4629, 0x48e7, + 0x48e8, 0x490e, 0x490f, 0x497d, 0x497e, 0x4a11, 0x4a12, 0x4a62, + 0x4a63, 0x82bc, + 0x82bd, 0x82bd, 0x82be, 0x82be, 0x82bf, 0x82cb, + 0x82cc, 0x82cc, 0x82cd, 0x82d1, 0x82d2, 0x82d8, 0x82d9, 0x82dc, + 0x82dd, 0x82e0, 0x82e1, 0x82e8, 0x82e9, 0x82ef, 0x82f0, 0x82ff, + 0x8300, 0x830d, + 0x830e, 0x93d4, 0x93d5, 0x9420, 0x9421, 0x943b, + 0x943c, 0x948c, 0x948d, 0x9495, 0x9496, 0x94af, 0x94b0, 0x94b0, + 0x94b1, 0x94b1, 0x94b2, 0x94b4, 0x94b5, 0x94ba, 0x94bb, 0x94bb, + 0x94bc, 0x94bd, 0x94be, 0x98c3, 0x98c4, 0x98c4, 0x98c5, 0x98c8, + 0x98c9, 0x98c9, 0x98ca, 0x98ca, 0x98cb, 0x98cb, 0x98cc, 0x9960, + 0x9961, 0x99e1, 0x99e2, 0x99fb +}; + +static const unsigned short gb18030uni_uni2charset_ranges[412] = { + 0x0080, 0x00a3, 0x00a5, 0x00a6, 0x00a9, 0x00af, 0x00b2, 0x00b6, + 0x00b8, 0x00d6, 0x00d8, 0x00df, 0x00e2, 0x00e7, 0x00eb, 0x00eb, + 0x00ee, 0x00f1, 0x00f4, 0x00f6, 0x00f8, 0x00f8, 0x00fb, 0x00fb, + 0x00fd, 0x0100, 0x0102, 0x0112, 0x0114, 0x011a, 0x011c, 0x012a, + 0x012c, 0x0143, 0x0145, 0x0147, 0x0149, 0x014c, 0x014e, 0x016a, + 0x016c, 0x01cd, 0x01cf, 0x01cf, 0x01d1, 0x01d1, 0x01d3, 0x01d3, + 0x01d5, 0x01d5, 0x01d7, 0x01d7, 0x01d9, 0x01d9, 0x01db, 0x01db, + 0x01dd, 0x01f8, 0x01fa, 0x0250, 0x0252, 0x0260, 0x0262, 0x02c6, + 0x02c8, 0x02c8, 0x02cc, 0x02d8, 0x02da, 0x0390, 0x03a2, 0x03a2, + 0x03aa, 0x03b0, 0x03c2, 0x03c2, 0x03ca, 0x0400, 0x0402, 0x040f, + 0x0450, 0x0450, 0x0452, 0x200f, 0x2011, 0x2012, 0x2017, 0x2017, + 0x201a, 0x201b, 0x201e, 0x2024, 0x2027, 0x202f, 0x2031, 0x2031, + 0x2034, 0x2034, 0x2036, 0x203a, 0x203c, 0x20ab, 0x20ad, 0x2102, + 0x2104, 0x2104, 0x2106, 0x2108, 0x210a, 0x2115, 0x2117, 0x2120, + 0x2122, 0x215f, 0x216c, 0x216f, 0x217a, 0x218f, 0x2194, 0x2195, + 0x219a, 0x2207, 0x2209, 0x220e, 0x2210, 0x2210, 0x2212, 0x2214, + 0x2216, 0x2219, 0x221b, 0x221c, 0x2221, 0x2222, 0x2224, 0x2224, + 0x2226, 0x2226, 0x222c, 0x222d, 0x222f, 0x2233, 0x2238, 0x223c, + 0x223e, 0x2247, 0x2249, 0x224b, 0x224d, 0x2251, 0x2253, 0x225f, + 0x2262, 0x2263, 0x2268, 0x226d, 0x2270, 0x2294, 0x2296, 0x2298, + 0x229a, 0x22a4, 0x22a6, 0x22be, 0x22c0, 0x2311, 0x2313, 0x245f, + 0x246a, 0x2473, 0x249c, 0x24ff, 0x254c, 0x254f, 0x2574, 0x2580, + 0x2590, 0x2592, 0x2596, 0x259f, 0x25a2, 0x25b1, 0x25b4, 0x25bb, + 0x25be, 0x25c5, 0x25c8, 0x25ca, 0x25cc, 0x25cd, 0x25d0, 0x25e1, + 0x25e6, 0x2604, 0x2607, 0x2608, 0x260a, 0x263f, 0x2641, 0x2641, + 0x2643, 0x2e80, 0x2e82, 0x2e83, 0x2e85, 0x2e87, 0x2e89, 0x2e8a, + 0x2e8d, 0x2e96, 0x2e98, 0x2ea6, 0x2ea8, 0x2ea9, 0x2eab, 0x2ead, + 0x2eaf, 0x2eb2, 0x2eb4, 0x2eb5, 0x2eb8, 0x2eba, 0x2ebc, 0x2ec9, + 0x2ecb, 0x2fef, 0x2ffc, 0x2fff, 0x3004, 0x3004, 0x3018, 0x301c, + 0x301f, 0x3020, 0x302a, 0x303d, 0x303f, 0x3040, 0x3094, 0x309a, + 0x309f, 0x30a0, 0x30f7, 0x30fb, 0x30ff, 0x3104, 0x312a, 0x321f, + 0x322a, 0x3230, 0x3232, 0x32a2, 0x32a4, 0x338d, 0x3390, 0x339b, + 0x339f, 0x33a0, 0x33a2, 0x33c3, 0x33c5, 0x33cd, 0x33cf, 0x33d0, + 0x33d3, 0x33d4, 0x33d6, 0x3446, 0x3448, 0x3472, 0x3474, 0x359d, + 0x359f, 0x360d, 0x360f, 0x3619, 0x361b, 0x3917, 0x3919, 0x396d, + 0x396f, 0x39ce, 0x39d1, 0x39de, 0x39e0, 0x3a72, 0x3a74, 0x3b4d, + 0x3b4f, 0x3c6d, 0x3c6f, 0x3cdf, 0x3ce1, 0x4055, 0x4057, 0x415e, + 0x4160, 0x4336, 0x4338, 0x43ab, 0x43ad, 0x43b0, 0x43b2, 0x43dc, + 0x43de, 0x44d5, 0x44d7, 0x464b, 0x464d, 0x4660, 0x4662, 0x4722, + 0x4724, 0x4728, 0x472a, 0x477b, 0x477d, 0x478c, 0x478e, 0x4946, + 0x4948, 0x4979, 0x497b, 0x497c, 0x497e, 0x4981, 0x4984, 0x4984, + 0x4987, 0x499a, 0x499c, 0x499e, 0x49a0, 0x49b5, 0x49b8, 0x4c76, + 0x4c78, 0x4c9e, 0x4ca4, 0x4d12, 0x4d1a, 0x4dad, 0x4daf, 0x4dff, + 0x9fa6, 0xd7ff, + 0xe76c, 0xe76c, 0xe7c8, 0xe7c8, 0xe7e7, 0xe7f3, + 0xe815, 0xe815, 0xe819, 0xe81d, 0xe81f, 0xe825, 0xe827, 0xe82a, + 0xe82d, 0xe830, 0xe833, 0xe83a, 0xe83c, 0xe842, 0xe844, 0xe853, + 0xe856, 0xe863, + 0xe865, 0xf92b, 0xf92d, 0xf978, 0xf97a, 0xf994, + 0xf996, 0xf9e6, 0xf9e8, 0xf9f0, 0xf9f2, 0xfa0b, 0xfa10, 0xfa10, + 0xfa12, 0xfa12, 0xfa15, 0xfa17, 0xfa19, 0xfa1e, 0xfa22, 0xfa22, + 0xfa25, 0xfa26, 0xfa2a, 0xfe2f, 0xfe32, 0xfe32, 0xfe45, 0xfe48, + 0xfe53, 0xfe53, 0xfe58, 0xfe58, 0xfe67, 0xfe67, 0xfe6c, 0xff00, + 0xff5f, 0xffdf, 0xffe6, 0xffff +}; + +static const unsigned short gb18030uni_ranges[206] = { + 128, 129, 131, 133, 134, 135, 137, 140, + 142, 144, 145, 147, 148, 149, 150, 151, + 152, 153, 154, 155, 156, 157, 158, 159, + 160, 161, 162, 163, 164, 165, 166, 167, + 168, 171, 172, 189, 196, 213, 220, 221, + 285, 286, 287, 291, 293, 295, 297, 298, + 300, 301, 302, 303, 304, 305, 306, 307, + 308, 320, 330, 334, 338, 339, 340, 341, + 342, 343, 347, 348, 349, 354, 355, 359, + 360, 361, 362, 363, 365, 369, 371, 372, + 373, 374, 375, 376, 386, 426, 502, 538, + 553, 556, 558, 560, 562, 564, 565, 567, + 571, 573, 574, 575, 576, 577, 578, 579, + 581, 582, 583, 584, 585, 586, 588, 589, + 590, 602, 606, 625, 627, 636, 637, 720, + 724, 810, 813, 850, 860, 861, 862, 864, + 867, 868, 869, 870, 872, 873, 874, 875, + 876, 877, 878, 879, 880, 882, 883, 884, + 885, 886, 887, 888, 889, 890, 891, 892, + 893, 894, 895, 896, 897, 898, 899, 900, + 901, 902, 903, 905, 907, 908, 909, 911, + 912, 917, 924, 925, 21827, + 25775, 25866, 25896, + 25929, 25932, 25933, 25934, 25936, 25938, 25939, 25940, + 25942, + 25943, 25944, 25945, 25946, 25947, 25948, 25952, + 25953, 25955, 25956, 25959, 25961, 25964, 25966, 25984, + 25994, 25998, 26012, 26016, 26110, 26116 +}; + +static int +gb18030uni_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if (c1 >= 0x81 && c1 <= 0x84) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x30 && c2 <= 0x39) { + if (n >= 3) { + unsigned char c3 = s[2]; + if (c3 >= 0x81 && c3 <= 0xfe) { + if (n >= 4) { + unsigned char c4 = s[3]; + if (c4 >= 0x30 && c4 <= 0x39) { + unsigned int i = (((c1 - 0x81) * 10 + (c2 - 0x30)) * 126 + (c3 - 0x81)) * 10 + (c4 - 0x30); + if (i >= 0 && i <= 39419) { + unsigned int k1 = 0; + unsigned int k2 = 205; + while (k1 < k2) { + unsigned int k = (k1 + k2) / 2; + if (i <= gb18030uni_charset2uni_ranges[2*k+1]) + k2 = k; + else if (i >= gb18030uni_charset2uni_ranges[2*k+2]) + k1 = k + 1; + else + return RET_ILSEQ; + } + { + unsigned int diff = gb18030uni_ranges[k1]; + *pwc = (ucs4_t) (i + diff); + return 4; + } + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static int +gb18030uni_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 4) { + unsigned int i = wc; + if (i >= 0x0080 && i <= 0xffff) { + unsigned int k1 = 0; + unsigned int k2 = 205; + while (k1 < k2) { + unsigned int k = (k1 + k2) / 2; + if (i <= gb18030uni_uni2charset_ranges[2*k+1]) + k2 = k; + else if (i >= gb18030uni_uni2charset_ranges[2*k+2]) + k1 = k + 1; + else + return RET_ILUNI; + } + { + unsigned int diff = gb18030uni_ranges[k1]; + i -= diff; + r[3] = (i % 10) + 0x30; i = i / 10; + r[2] = (i % 126) + 0x81; i = i / 126; + r[1] = (i % 10) + 0x30; i = i / 10; + r[0] = i + 0x81; + return 4; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/gb2312.h b/graf2d/win32gdk/gdk/src/iconv/gb2312.h new file mode 100644 index 0000000000000..831a5691273b1 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/gb2312.h @@ -0,0 +1,2571 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GB2312.1980-0 + */ + +static const unsigned short gb2312_2uni_page21[831] = { + /* 0x21 */ + 0x3000, 0x3001, 0x3002, 0x30fb, 0x02c9, 0x02c7, 0x00a8, 0x3003, + 0x3005, 0x2015, 0xff5e, 0x2016, 0x2026, 0x2018, 0x2019, 0x201c, + 0x201d, 0x3014, 0x3015, 0x3008, 0x3009, 0x300a, 0x300b, 0x300c, + 0x300d, 0x300e, 0x300f, 0x3016, 0x3017, 0x3010, 0x3011, 0x00b1, + 0x00d7, 0x00f7, 0x2236, 0x2227, 0x2228, 0x2211, 0x220f, 0x222a, + 0x2229, 0x2208, 0x2237, 0x221a, 0x22a5, 0x2225, 0x2220, 0x2312, + 0x2299, 0x222b, 0x222e, 0x2261, 0x224c, 0x2248, 0x223d, 0x221d, + 0x2260, 0x226e, 0x226f, 0x2264, 0x2265, 0x221e, 0x2235, 0x2234, + 0x2642, 0x2640, 0x00b0, 0x2032, 0x2033, 0x2103, 0xff04, 0x00a4, + 0xffe0, 0xffe1, 0x2030, 0x00a7, 0x2116, 0x2606, 0x2605, 0x25cb, + 0x25cf, 0x25ce, 0x25c7, 0x25c6, 0x25a1, 0x25a0, 0x25b3, 0x25b2, + 0x203b, 0x2192, 0x2190, 0x2191, 0x2193, 0x3013, + /* 0x22 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x2488, 0x2489, 0x248a, 0x248b, 0x248c, 0x248d, 0x248e, 0x248f, + 0x2490, 0x2491, 0x2492, 0x2493, 0x2494, 0x2495, 0x2496, 0x2497, + 0x2498, 0x2499, 0x249a, 0x249b, 0x2474, 0x2475, 0x2476, 0x2477, + 0x2478, 0x2479, 0x247a, 0x247b, 0x247c, 0x247d, 0x247e, 0x247f, + 0x2480, 0x2481, 0x2482, 0x2483, 0x2484, 0x2485, 0x2486, 0x2487, + 0x2460, 0x2461, 0x2462, 0x2463, 0x2464, 0x2465, 0x2466, 0x2467, + 0x2468, 0x2469, 0xfffd, 0xfffd, 0x3220, 0x3221, 0x3222, 0x3223, + 0x3224, 0x3225, 0x3226, 0x3227, 0x3228, 0x3229, 0xfffd, 0xfffd, + 0x2160, 0x2161, 0x2162, 0x2163, 0x2164, 0x2165, 0x2166, 0x2167, + 0x2168, 0x2169, 0x216a, 0x216b, 0xfffd, 0xfffd, + /* 0x23 */ + 0xff01, 0xff02, 0xff03, 0xffe5, 0xff05, 0xff06, 0xff07, 0xff08, + 0xff09, 0xff0a, 0xff0b, 0xff0c, 0xff0d, 0xff0e, 0xff0f, 0xff10, + 0xff11, 0xff12, 0xff13, 0xff14, 0xff15, 0xff16, 0xff17, 0xff18, + 0xff19, 0xff1a, 0xff1b, 0xff1c, 0xff1d, 0xff1e, 0xff1f, 0xff20, + 0xff21, 0xff22, 0xff23, 0xff24, 0xff25, 0xff26, 0xff27, 0xff28, + 0xff29, 0xff2a, 0xff2b, 0xff2c, 0xff2d, 0xff2e, 0xff2f, 0xff30, + 0xff31, 0xff32, 0xff33, 0xff34, 0xff35, 0xff36, 0xff37, 0xff38, + 0xff39, 0xff3a, 0xff3b, 0xff3c, 0xff3d, 0xff3e, 0xff3f, 0xff40, + 0xff41, 0xff42, 0xff43, 0xff44, 0xff45, 0xff46, 0xff47, 0xff48, + 0xff49, 0xff4a, 0xff4b, 0xff4c, 0xff4d, 0xff4e, 0xff4f, 0xff50, + 0xff51, 0xff52, 0xff53, 0xff54, 0xff55, 0xff56, 0xff57, 0xff58, + 0xff59, 0xff5a, 0xff5b, 0xff5c, 0xff5d, 0xffe3, + /* 0x24 */ + 0x3041, 0x3042, 0x3043, 0x3044, 0x3045, 0x3046, 0x3047, 0x3048, + 0x3049, 0x304a, 0x304b, 0x304c, 0x304d, 0x304e, 0x304f, 0x3050, + 0x3051, 0x3052, 0x3053, 0x3054, 0x3055, 0x3056, 0x3057, 0x3058, + 0x3059, 0x305a, 0x305b, 0x305c, 0x305d, 0x305e, 0x305f, 0x3060, + 0x3061, 0x3062, 0x3063, 0x3064, 0x3065, 0x3066, 0x3067, 0x3068, + 0x3069, 0x306a, 0x306b, 0x306c, 0x306d, 0x306e, 0x306f, 0x3070, + 0x3071, 0x3072, 0x3073, 0x3074, 0x3075, 0x3076, 0x3077, 0x3078, + 0x3079, 0x307a, 0x307b, 0x307c, 0x307d, 0x307e, 0x307f, 0x3080, + 0x3081, 0x3082, 0x3083, 0x3084, 0x3085, 0x3086, 0x3087, 0x3088, + 0x3089, 0x308a, 0x308b, 0x308c, 0x308d, 0x308e, 0x308f, 0x3090, + 0x3091, 0x3092, 0x3093, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x25 */ + 0x30a1, 0x30a2, 0x30a3, 0x30a4, 0x30a5, 0x30a6, 0x30a7, 0x30a8, + 0x30a9, 0x30aa, 0x30ab, 0x30ac, 0x30ad, 0x30ae, 0x30af, 0x30b0, + 0x30b1, 0x30b2, 0x30b3, 0x30b4, 0x30b5, 0x30b6, 0x30b7, 0x30b8, + 0x30b9, 0x30ba, 0x30bb, 0x30bc, 0x30bd, 0x30be, 0x30bf, 0x30c0, + 0x30c1, 0x30c2, 0x30c3, 0x30c4, 0x30c5, 0x30c6, 0x30c7, 0x30c8, + 0x30c9, 0x30ca, 0x30cb, 0x30cc, 0x30cd, 0x30ce, 0x30cf, 0x30d0, + 0x30d1, 0x30d2, 0x30d3, 0x30d4, 0x30d5, 0x30d6, 0x30d7, 0x30d8, + 0x30d9, 0x30da, 0x30db, 0x30dc, 0x30dd, 0x30de, 0x30df, 0x30e0, + 0x30e1, 0x30e2, 0x30e3, 0x30e4, 0x30e5, 0x30e6, 0x30e7, 0x30e8, + 0x30e9, 0x30ea, 0x30eb, 0x30ec, 0x30ed, 0x30ee, 0x30ef, 0x30f0, + 0x30f1, 0x30f2, 0x30f3, 0x30f4, 0x30f5, 0x30f6, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x26 */ + 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, 0x0398, + 0x0399, 0x039a, 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, 0x03a0, + 0x03a1, 0x03a3, 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, 0x03b8, + 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, 0x03c0, + 0x03c1, 0x03c3, 0x03c4, 0x03c5, 0x03c6, 0x03c7, 0x03c8, 0x03c9, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x27 */ + 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0401, 0x0416, + 0x0417, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, + 0x041f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, + 0x0427, 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, + 0x042f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0451, 0x0436, + 0x0437, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, + 0x043f, 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, + 0x0447, 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, + 0x044f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x28 */ + 0x0101, 0x00e1, 0x01ce, 0x00e0, 0x0113, 0x00e9, 0x011b, 0x00e8, + 0x012b, 0x00ed, 0x01d0, 0x00ec, 0x014d, 0x00f3, 0x01d2, 0x00f2, + 0x016b, 0x00fa, 0x01d4, 0x00f9, 0x01d6, 0x01d8, 0x01da, 0x01dc, + 0x00fc, 0x00ea, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x3105, 0x3106, 0x3107, 0x3108, + 0x3109, 0x310a, 0x310b, 0x310c, 0x310d, 0x310e, 0x310f, 0x3110, + 0x3111, 0x3112, 0x3113, 0x3114, 0x3115, 0x3116, 0x3117, 0x3118, + 0x3119, 0x311a, 0x311b, 0x311c, 0x311d, 0x311e, 0x311f, 0x3120, + 0x3121, 0x3122, 0x3123, 0x3124, 0x3125, 0x3126, 0x3127, 0x3128, + 0x3129, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x29 */ + 0xfffd, 0xfffd, 0xfffd, 0x2500, 0x2501, 0x2502, 0x2503, 0x2504, + 0x2505, 0x2506, 0x2507, 0x2508, 0x2509, 0x250a, 0x250b, 0x250c, + 0x250d, 0x250e, 0x250f, 0x2510, 0x2511, 0x2512, 0x2513, 0x2514, + 0x2515, 0x2516, 0x2517, 0x2518, 0x2519, 0x251a, 0x251b, 0x251c, + 0x251d, 0x251e, 0x251f, 0x2520, 0x2521, 0x2522, 0x2523, 0x2524, + 0x2525, 0x2526, 0x2527, 0x2528, 0x2529, 0x252a, 0x252b, 0x252c, + 0x252d, 0x252e, 0x252f, 0x2530, 0x2531, 0x2532, 0x2533, 0x2534, + 0x2535, 0x2536, 0x2537, 0x2538, 0x2539, 0x253a, 0x253b, 0x253c, + 0x253d, 0x253e, 0x253f, 0x2540, 0x2541, 0x2542, 0x2543, 0x2544, + 0x2545, 0x2546, 0x2547, 0x2548, 0x2549, 0x254a, 0x254b, +}; +static const unsigned short gb2312_2uni_page30[6768] = { + /* 0x30 */ + 0x554a, 0x963f, 0x57c3, 0x6328, 0x54ce, 0x5509, 0x54c0, 0x7691, + 0x764c, 0x853c, 0x77ee, 0x827e, 0x788d, 0x7231, 0x9698, 0x978d, + 0x6c28, 0x5b89, 0x4ffa, 0x6309, 0x6697, 0x5cb8, 0x80fa, 0x6848, + 0x80ae, 0x6602, 0x76ce, 0x51f9, 0x6556, 0x71ac, 0x7ff1, 0x8884, + 0x50b2, 0x5965, 0x61ca, 0x6fb3, 0x82ad, 0x634c, 0x6252, 0x53ed, + 0x5427, 0x7b06, 0x516b, 0x75a4, 0x5df4, 0x62d4, 0x8dcb, 0x9776, + 0x628a, 0x8019, 0x575d, 0x9738, 0x7f62, 0x7238, 0x767d, 0x67cf, + 0x767e, 0x6446, 0x4f70, 0x8d25, 0x62dc, 0x7a17, 0x6591, 0x73ed, + 0x642c, 0x6273, 0x822c, 0x9881, 0x677f, 0x7248, 0x626e, 0x62cc, + 0x4f34, 0x74e3, 0x534a, 0x529e, 0x7eca, 0x90a6, 0x5e2e, 0x6886, + 0x699c, 0x8180, 0x7ed1, 0x68d2, 0x78c5, 0x868c, 0x9551, 0x508d, + 0x8c24, 0x82de, 0x80de, 0x5305, 0x8912, 0x5265, + /* 0x31 */ + 0x8584, 0x96f9, 0x4fdd, 0x5821, 0x9971, 0x5b9d, 0x62b1, 0x62a5, + 0x66b4, 0x8c79, 0x9c8d, 0x7206, 0x676f, 0x7891, 0x60b2, 0x5351, + 0x5317, 0x8f88, 0x80cc, 0x8d1d, 0x94a1, 0x500d, 0x72c8, 0x5907, + 0x60eb, 0x7119, 0x88ab, 0x5954, 0x82ef, 0x672c, 0x7b28, 0x5d29, + 0x7ef7, 0x752d, 0x6cf5, 0x8e66, 0x8ff8, 0x903c, 0x9f3b, 0x6bd4, + 0x9119, 0x7b14, 0x5f7c, 0x78a7, 0x84d6, 0x853d, 0x6bd5, 0x6bd9, + 0x6bd6, 0x5e01, 0x5e87, 0x75f9, 0x95ed, 0x655d, 0x5f0a, 0x5fc5, + 0x8f9f, 0x58c1, 0x81c2, 0x907f, 0x965b, 0x97ad, 0x8fb9, 0x7f16, + 0x8d2c, 0x6241, 0x4fbf, 0x53d8, 0x535e, 0x8fa8, 0x8fa9, 0x8fab, + 0x904d, 0x6807, 0x5f6a, 0x8198, 0x8868, 0x9cd6, 0x618b, 0x522b, + 0x762a, 0x5f6c, 0x658c, 0x6fd2, 0x6ee8, 0x5bbe, 0x6448, 0x5175, + 0x51b0, 0x67c4, 0x4e19, 0x79c9, 0x997c, 0x70b3, + /* 0x32 */ + 0x75c5, 0x5e76, 0x73bb, 0x83e0, 0x64ad, 0x62e8, 0x94b5, 0x6ce2, + 0x535a, 0x52c3, 0x640f, 0x94c2, 0x7b94, 0x4f2f, 0x5e1b, 0x8236, + 0x8116, 0x818a, 0x6e24, 0x6cca, 0x9a73, 0x6355, 0x535c, 0x54fa, + 0x8865, 0x57e0, 0x4e0d, 0x5e03, 0x6b65, 0x7c3f, 0x90e8, 0x6016, + 0x64e6, 0x731c, 0x88c1, 0x6750, 0x624d, 0x8d22, 0x776c, 0x8e29, + 0x91c7, 0x5f69, 0x83dc, 0x8521, 0x9910, 0x53c2, 0x8695, 0x6b8b, + 0x60ed, 0x60e8, 0x707f, 0x82cd, 0x8231, 0x4ed3, 0x6ca7, 0x85cf, + 0x64cd, 0x7cd9, 0x69fd, 0x66f9, 0x8349, 0x5395, 0x7b56, 0x4fa7, + 0x518c, 0x6d4b, 0x5c42, 0x8e6d, 0x63d2, 0x53c9, 0x832c, 0x8336, + 0x67e5, 0x78b4, 0x643d, 0x5bdf, 0x5c94, 0x5dee, 0x8be7, 0x62c6, + 0x67f4, 0x8c7a, 0x6400, 0x63ba, 0x8749, 0x998b, 0x8c17, 0x7f20, + 0x94f2, 0x4ea7, 0x9610, 0x98a4, 0x660c, 0x7316, + /* 0x33 */ + 0x573a, 0x5c1d, 0x5e38, 0x957f, 0x507f, 0x80a0, 0x5382, 0x655e, + 0x7545, 0x5531, 0x5021, 0x8d85, 0x6284, 0x949e, 0x671d, 0x5632, + 0x6f6e, 0x5de2, 0x5435, 0x7092, 0x8f66, 0x626f, 0x64a4, 0x63a3, + 0x5f7b, 0x6f88, 0x90f4, 0x81e3, 0x8fb0, 0x5c18, 0x6668, 0x5ff1, + 0x6c89, 0x9648, 0x8d81, 0x886c, 0x6491, 0x79f0, 0x57ce, 0x6a59, + 0x6210, 0x5448, 0x4e58, 0x7a0b, 0x60e9, 0x6f84, 0x8bda, 0x627f, + 0x901e, 0x9a8b, 0x79e4, 0x5403, 0x75f4, 0x6301, 0x5319, 0x6c60, + 0x8fdf, 0x5f1b, 0x9a70, 0x803b, 0x9f7f, 0x4f88, 0x5c3a, 0x8d64, + 0x7fc5, 0x65a5, 0x70bd, 0x5145, 0x51b2, 0x866b, 0x5d07, 0x5ba0, + 0x62bd, 0x916c, 0x7574, 0x8e0c, 0x7a20, 0x6101, 0x7b79, 0x4ec7, + 0x7ef8, 0x7785, 0x4e11, 0x81ed, 0x521d, 0x51fa, 0x6a71, 0x53a8, + 0x8e87, 0x9504, 0x96cf, 0x6ec1, 0x9664, 0x695a, + /* 0x34 */ + 0x7840, 0x50a8, 0x77d7, 0x6410, 0x89e6, 0x5904, 0x63e3, 0x5ddd, + 0x7a7f, 0x693d, 0x4f20, 0x8239, 0x5598, 0x4e32, 0x75ae, 0x7a97, + 0x5e62, 0x5e8a, 0x95ef, 0x521b, 0x5439, 0x708a, 0x6376, 0x9524, + 0x5782, 0x6625, 0x693f, 0x9187, 0x5507, 0x6df3, 0x7eaf, 0x8822, + 0x6233, 0x7ef0, 0x75b5, 0x8328, 0x78c1, 0x96cc, 0x8f9e, 0x6148, + 0x74f7, 0x8bcd, 0x6b64, 0x523a, 0x8d50, 0x6b21, 0x806a, 0x8471, + 0x56f1, 0x5306, 0x4ece, 0x4e1b, 0x51d1, 0x7c97, 0x918b, 0x7c07, + 0x4fc3, 0x8e7f, 0x7be1, 0x7a9c, 0x6467, 0x5d14, 0x50ac, 0x8106, + 0x7601, 0x7cb9, 0x6dec, 0x7fe0, 0x6751, 0x5b58, 0x5bf8, 0x78cb, + 0x64ae, 0x6413, 0x63aa, 0x632b, 0x9519, 0x642d, 0x8fbe, 0x7b54, + 0x7629, 0x6253, 0x5927, 0x5446, 0x6b79, 0x50a3, 0x6234, 0x5e26, + 0x6b86, 0x4ee3, 0x8d37, 0x888b, 0x5f85, 0x902e, + /* 0x35 */ + 0x6020, 0x803d, 0x62c5, 0x4e39, 0x5355, 0x90f8, 0x63b8, 0x80c6, + 0x65e6, 0x6c2e, 0x4f46, 0x60ee, 0x6de1, 0x8bde, 0x5f39, 0x86cb, + 0x5f53, 0x6321, 0x515a, 0x8361, 0x6863, 0x5200, 0x6363, 0x8e48, + 0x5012, 0x5c9b, 0x7977, 0x5bfc, 0x5230, 0x7a3b, 0x60bc, 0x9053, + 0x76d7, 0x5fb7, 0x5f97, 0x7684, 0x8e6c, 0x706f, 0x767b, 0x7b49, + 0x77aa, 0x51f3, 0x9093, 0x5824, 0x4f4e, 0x6ef4, 0x8fea, 0x654c, + 0x7b1b, 0x72c4, 0x6da4, 0x7fdf, 0x5ae1, 0x62b5, 0x5e95, 0x5730, + 0x8482, 0x7b2c, 0x5e1d, 0x5f1f, 0x9012, 0x7f14, 0x98a0, 0x6382, + 0x6ec7, 0x7898, 0x70b9, 0x5178, 0x975b, 0x57ab, 0x7535, 0x4f43, + 0x7538, 0x5e97, 0x60e6, 0x5960, 0x6dc0, 0x6bbf, 0x7889, 0x53fc, + 0x96d5, 0x51cb, 0x5201, 0x6389, 0x540a, 0x9493, 0x8c03, 0x8dcc, + 0x7239, 0x789f, 0x8776, 0x8fed, 0x8c0d, 0x53e0, + /* 0x36 */ + 0x4e01, 0x76ef, 0x53ee, 0x9489, 0x9876, 0x9f0e, 0x952d, 0x5b9a, + 0x8ba2, 0x4e22, 0x4e1c, 0x51ac, 0x8463, 0x61c2, 0x52a8, 0x680b, + 0x4f97, 0x606b, 0x51bb, 0x6d1e, 0x515c, 0x6296, 0x6597, 0x9661, + 0x8c46, 0x9017, 0x75d8, 0x90fd, 0x7763, 0x6bd2, 0x728a, 0x72ec, + 0x8bfb, 0x5835, 0x7779, 0x8d4c, 0x675c, 0x9540, 0x809a, 0x5ea6, + 0x6e21, 0x5992, 0x7aef, 0x77ed, 0x953b, 0x6bb5, 0x65ad, 0x7f0e, + 0x5806, 0x5151, 0x961f, 0x5bf9, 0x58a9, 0x5428, 0x8e72, 0x6566, + 0x987f, 0x56e4, 0x949d, 0x76fe, 0x9041, 0x6387, 0x54c6, 0x591a, + 0x593a, 0x579b, 0x8eb2, 0x6735, 0x8dfa, 0x8235, 0x5241, 0x60f0, + 0x5815, 0x86fe, 0x5ce8, 0x9e45, 0x4fc4, 0x989d, 0x8bb9, 0x5a25, + 0x6076, 0x5384, 0x627c, 0x904f, 0x9102, 0x997f, 0x6069, 0x800c, + 0x513f, 0x8033, 0x5c14, 0x9975, 0x6d31, 0x4e8c, + /* 0x37 */ + 0x8d30, 0x53d1, 0x7f5a, 0x7b4f, 0x4f10, 0x4e4f, 0x9600, 0x6cd5, + 0x73d0, 0x85e9, 0x5e06, 0x756a, 0x7ffb, 0x6a0a, 0x77fe, 0x9492, + 0x7e41, 0x51e1, 0x70e6, 0x53cd, 0x8fd4, 0x8303, 0x8d29, 0x72af, + 0x996d, 0x6cdb, 0x574a, 0x82b3, 0x65b9, 0x80aa, 0x623f, 0x9632, + 0x59a8, 0x4eff, 0x8bbf, 0x7eba, 0x653e, 0x83f2, 0x975e, 0x5561, + 0x98de, 0x80a5, 0x532a, 0x8bfd, 0x5420, 0x80ba, 0x5e9f, 0x6cb8, + 0x8d39, 0x82ac, 0x915a, 0x5429, 0x6c1b, 0x5206, 0x7eb7, 0x575f, + 0x711a, 0x6c7e, 0x7c89, 0x594b, 0x4efd, 0x5fff, 0x6124, 0x7caa, + 0x4e30, 0x5c01, 0x67ab, 0x8702, 0x5cf0, 0x950b, 0x98ce, 0x75af, + 0x70fd, 0x9022, 0x51af, 0x7f1d, 0x8bbd, 0x5949, 0x51e4, 0x4f5b, + 0x5426, 0x592b, 0x6577, 0x80a4, 0x5b75, 0x6276, 0x62c2, 0x8f90, + 0x5e45, 0x6c1f, 0x7b26, 0x4f0f, 0x4fd8, 0x670d, + /* 0x38 */ + 0x6d6e, 0x6daa, 0x798f, 0x88b1, 0x5f17, 0x752b, 0x629a, 0x8f85, + 0x4fef, 0x91dc, 0x65a7, 0x812f, 0x8151, 0x5e9c, 0x8150, 0x8d74, + 0x526f, 0x8986, 0x8d4b, 0x590d, 0x5085, 0x4ed8, 0x961c, 0x7236, + 0x8179, 0x8d1f, 0x5bcc, 0x8ba3, 0x9644, 0x5987, 0x7f1a, 0x5490, + 0x5676, 0x560e, 0x8be5, 0x6539, 0x6982, 0x9499, 0x76d6, 0x6e89, + 0x5e72, 0x7518, 0x6746, 0x67d1, 0x7aff, 0x809d, 0x8d76, 0x611f, + 0x79c6, 0x6562, 0x8d63, 0x5188, 0x521a, 0x94a2, 0x7f38, 0x809b, + 0x7eb2, 0x5c97, 0x6e2f, 0x6760, 0x7bd9, 0x768b, 0x9ad8, 0x818f, + 0x7f94, 0x7cd5, 0x641e, 0x9550, 0x7a3f, 0x544a, 0x54e5, 0x6b4c, + 0x6401, 0x6208, 0x9e3d, 0x80f3, 0x7599, 0x5272, 0x9769, 0x845b, + 0x683c, 0x86e4, 0x9601, 0x9694, 0x94ec, 0x4e2a, 0x5404, 0x7ed9, + 0x6839, 0x8ddf, 0x8015, 0x66f4, 0x5e9a, 0x7fb9, + /* 0x39 */ + 0x57c2, 0x803f, 0x6897, 0x5de5, 0x653b, 0x529f, 0x606d, 0x9f9a, + 0x4f9b, 0x8eac, 0x516c, 0x5bab, 0x5f13, 0x5de9, 0x6c5e, 0x62f1, + 0x8d21, 0x5171, 0x94a9, 0x52fe, 0x6c9f, 0x82df, 0x72d7, 0x57a2, + 0x6784, 0x8d2d, 0x591f, 0x8f9c, 0x83c7, 0x5495, 0x7b8d, 0x4f30, + 0x6cbd, 0x5b64, 0x59d1, 0x9f13, 0x53e4, 0x86ca, 0x9aa8, 0x8c37, + 0x80a1, 0x6545, 0x987e, 0x56fa, 0x96c7, 0x522e, 0x74dc, 0x5250, + 0x5be1, 0x6302, 0x8902, 0x4e56, 0x62d0, 0x602a, 0x68fa, 0x5173, + 0x5b98, 0x51a0, 0x89c2, 0x7ba1, 0x9986, 0x7f50, 0x60ef, 0x704c, + 0x8d2f, 0x5149, 0x5e7f, 0x901b, 0x7470, 0x89c4, 0x572d, 0x7845, + 0x5f52, 0x9f9f, 0x95fa, 0x8f68, 0x9b3c, 0x8be1, 0x7678, 0x6842, + 0x67dc, 0x8dea, 0x8d35, 0x523d, 0x8f8a, 0x6eda, 0x68cd, 0x9505, + 0x90ed, 0x56fd, 0x679c, 0x88f9, 0x8fc7, 0x54c8, + /* 0x3a */ + 0x9ab8, 0x5b69, 0x6d77, 0x6c26, 0x4ea5, 0x5bb3, 0x9a87, 0x9163, + 0x61a8, 0x90af, 0x97e9, 0x542b, 0x6db5, 0x5bd2, 0x51fd, 0x558a, + 0x7f55, 0x7ff0, 0x64bc, 0x634d, 0x65f1, 0x61be, 0x608d, 0x710a, + 0x6c57, 0x6c49, 0x592f, 0x676d, 0x822a, 0x58d5, 0x568e, 0x8c6a, + 0x6beb, 0x90dd, 0x597d, 0x8017, 0x53f7, 0x6d69, 0x5475, 0x559d, + 0x8377, 0x83cf, 0x6838, 0x79be, 0x548c, 0x4f55, 0x5408, 0x76d2, + 0x8c89, 0x9602, 0x6cb3, 0x6db8, 0x8d6b, 0x8910, 0x9e64, 0x8d3a, + 0x563f, 0x9ed1, 0x75d5, 0x5f88, 0x72e0, 0x6068, 0x54fc, 0x4ea8, + 0x6a2a, 0x8861, 0x6052, 0x8f70, 0x54c4, 0x70d8, 0x8679, 0x9e3f, + 0x6d2a, 0x5b8f, 0x5f18, 0x7ea2, 0x5589, 0x4faf, 0x7334, 0x543c, + 0x539a, 0x5019, 0x540e, 0x547c, 0x4e4e, 0x5ffd, 0x745a, 0x58f6, + 0x846b, 0x80e1, 0x8774, 0x72d0, 0x7cca, 0x6e56, + /* 0x3b */ + 0x5f27, 0x864e, 0x552c, 0x62a4, 0x4e92, 0x6caa, 0x6237, 0x82b1, + 0x54d7, 0x534e, 0x733e, 0x6ed1, 0x753b, 0x5212, 0x5316, 0x8bdd, + 0x69d0, 0x5f8a, 0x6000, 0x6dee, 0x574f, 0x6b22, 0x73af, 0x6853, + 0x8fd8, 0x7f13, 0x6362, 0x60a3, 0x5524, 0x75ea, 0x8c62, 0x7115, + 0x6da3, 0x5ba6, 0x5e7b, 0x8352, 0x614c, 0x9ec4, 0x78fa, 0x8757, + 0x7c27, 0x7687, 0x51f0, 0x60f6, 0x714c, 0x6643, 0x5e4c, 0x604d, + 0x8c0e, 0x7070, 0x6325, 0x8f89, 0x5fbd, 0x6062, 0x86d4, 0x56de, + 0x6bc1, 0x6094, 0x6167, 0x5349, 0x60e0, 0x6666, 0x8d3f, 0x79fd, + 0x4f1a, 0x70e9, 0x6c47, 0x8bb3, 0x8bf2, 0x7ed8, 0x8364, 0x660f, + 0x5a5a, 0x9b42, 0x6d51, 0x6df7, 0x8c41, 0x6d3b, 0x4f19, 0x706b, + 0x83b7, 0x6216, 0x60d1, 0x970d, 0x8d27, 0x7978, 0x51fb, 0x573e, + 0x57fa, 0x673a, 0x7578, 0x7a3d, 0x79ef, 0x7b95, + /* 0x3c */ + 0x808c, 0x9965, 0x8ff9, 0x6fc0, 0x8ba5, 0x9e21, 0x59ec, 0x7ee9, + 0x7f09, 0x5409, 0x6781, 0x68d8, 0x8f91, 0x7c4d, 0x96c6, 0x53ca, + 0x6025, 0x75be, 0x6c72, 0x5373, 0x5ac9, 0x7ea7, 0x6324, 0x51e0, + 0x810a, 0x5df1, 0x84df, 0x6280, 0x5180, 0x5b63, 0x4f0e, 0x796d, + 0x5242, 0x60b8, 0x6d4e, 0x5bc4, 0x5bc2, 0x8ba1, 0x8bb0, 0x65e2, + 0x5fcc, 0x9645, 0x5993, 0x7ee7, 0x7eaa, 0x5609, 0x67b7, 0x5939, + 0x4f73, 0x5bb6, 0x52a0, 0x835a, 0x988a, 0x8d3e, 0x7532, 0x94be, + 0x5047, 0x7a3c, 0x4ef7, 0x67b6, 0x9a7e, 0x5ac1, 0x6b7c, 0x76d1, + 0x575a, 0x5c16, 0x7b3a, 0x95f4, 0x714e, 0x517c, 0x80a9, 0x8270, + 0x5978, 0x7f04, 0x8327, 0x68c0, 0x67ec, 0x78b1, 0x7877, 0x62e3, + 0x6361, 0x7b80, 0x4fed, 0x526a, 0x51cf, 0x8350, 0x69db, 0x9274, + 0x8df5, 0x8d31, 0x89c1, 0x952e, 0x7bad, 0x4ef6, + /* 0x3d */ + 0x5065, 0x8230, 0x5251, 0x996f, 0x6e10, 0x6e85, 0x6da7, 0x5efa, + 0x50f5, 0x59dc, 0x5c06, 0x6d46, 0x6c5f, 0x7586, 0x848b, 0x6868, + 0x5956, 0x8bb2, 0x5320, 0x9171, 0x964d, 0x8549, 0x6912, 0x7901, + 0x7126, 0x80f6, 0x4ea4, 0x90ca, 0x6d47, 0x9a84, 0x5a07, 0x56bc, + 0x6405, 0x94f0, 0x77eb, 0x4fa5, 0x811a, 0x72e1, 0x89d2, 0x997a, + 0x7f34, 0x7ede, 0x527f, 0x6559, 0x9175, 0x8f7f, 0x8f83, 0x53eb, + 0x7a96, 0x63ed, 0x63a5, 0x7686, 0x79f8, 0x8857, 0x9636, 0x622a, + 0x52ab, 0x8282, 0x6854, 0x6770, 0x6377, 0x776b, 0x7aed, 0x6d01, + 0x7ed3, 0x89e3, 0x59d0, 0x6212, 0x85c9, 0x82a5, 0x754c, 0x501f, + 0x4ecb, 0x75a5, 0x8beb, 0x5c4a, 0x5dfe, 0x7b4b, 0x65a4, 0x91d1, + 0x4eca, 0x6d25, 0x895f, 0x7d27, 0x9526, 0x4ec5, 0x8c28, 0x8fdb, + 0x9773, 0x664b, 0x7981, 0x8fd1, 0x70ec, 0x6d78, + /* 0x3e */ + 0x5c3d, 0x52b2, 0x8346, 0x5162, 0x830e, 0x775b, 0x6676, 0x9cb8, + 0x4eac, 0x60ca, 0x7cbe, 0x7cb3, 0x7ecf, 0x4e95, 0x8b66, 0x666f, + 0x9888, 0x9759, 0x5883, 0x656c, 0x955c, 0x5f84, 0x75c9, 0x9756, + 0x7adf, 0x7ade, 0x51c0, 0x70af, 0x7a98, 0x63ea, 0x7a76, 0x7ea0, + 0x7396, 0x97ed, 0x4e45, 0x7078, 0x4e5d, 0x9152, 0x53a9, 0x6551, + 0x65e7, 0x81fc, 0x8205, 0x548e, 0x5c31, 0x759a, 0x97a0, 0x62d8, + 0x72d9, 0x75bd, 0x5c45, 0x9a79, 0x83ca, 0x5c40, 0x5480, 0x77e9, + 0x4e3e, 0x6cae, 0x805a, 0x62d2, 0x636e, 0x5de8, 0x5177, 0x8ddd, + 0x8e1e, 0x952f, 0x4ff1, 0x53e5, 0x60e7, 0x70ac, 0x5267, 0x6350, + 0x9e43, 0x5a1f, 0x5026, 0x7737, 0x5377, 0x7ee2, 0x6485, 0x652b, + 0x6289, 0x6398, 0x5014, 0x7235, 0x89c9, 0x51b3, 0x8bc0, 0x7edd, + 0x5747, 0x83cc, 0x94a7, 0x519b, 0x541b, 0x5cfb, + /* 0x3f */ + 0x4fca, 0x7ae3, 0x6d5a, 0x90e1, 0x9a8f, 0x5580, 0x5496, 0x5361, + 0x54af, 0x5f00, 0x63e9, 0x6977, 0x51ef, 0x6168, 0x520a, 0x582a, + 0x52d8, 0x574e, 0x780d, 0x770b, 0x5eb7, 0x6177, 0x7ce0, 0x625b, + 0x6297, 0x4ea2, 0x7095, 0x8003, 0x62f7, 0x70e4, 0x9760, 0x5777, + 0x82db, 0x67ef, 0x68f5, 0x78d5, 0x9897, 0x79d1, 0x58f3, 0x54b3, + 0x53ef, 0x6e34, 0x514b, 0x523b, 0x5ba2, 0x8bfe, 0x80af, 0x5543, + 0x57a6, 0x6073, 0x5751, 0x542d, 0x7a7a, 0x6050, 0x5b54, 0x63a7, + 0x62a0, 0x53e3, 0x6263, 0x5bc7, 0x67af, 0x54ed, 0x7a9f, 0x82e6, + 0x9177, 0x5e93, 0x88e4, 0x5938, 0x57ae, 0x630e, 0x8de8, 0x80ef, + 0x5757, 0x7b77, 0x4fa9, 0x5feb, 0x5bbd, 0x6b3e, 0x5321, 0x7b50, + 0x72c2, 0x6846, 0x77ff, 0x7736, 0x65f7, 0x51b5, 0x4e8f, 0x76d4, + 0x5cbf, 0x7aa5, 0x8475, 0x594e, 0x9b41, 0x5080, + /* 0x40 */ + 0x9988, 0x6127, 0x6e83, 0x5764, 0x6606, 0x6346, 0x56f0, 0x62ec, + 0x6269, 0x5ed3, 0x9614, 0x5783, 0x62c9, 0x5587, 0x8721, 0x814a, + 0x8fa3, 0x5566, 0x83b1, 0x6765, 0x8d56, 0x84dd, 0x5a6a, 0x680f, + 0x62e6, 0x7bee, 0x9611, 0x5170, 0x6f9c, 0x8c30, 0x63fd, 0x89c8, + 0x61d2, 0x7f06, 0x70c2, 0x6ee5, 0x7405, 0x6994, 0x72fc, 0x5eca, + 0x90ce, 0x6717, 0x6d6a, 0x635e, 0x52b3, 0x7262, 0x8001, 0x4f6c, + 0x59e5, 0x916a, 0x70d9, 0x6d9d, 0x52d2, 0x4e50, 0x96f7, 0x956d, + 0x857e, 0x78ca, 0x7d2f, 0x5121, 0x5792, 0x64c2, 0x808b, 0x7c7b, + 0x6cea, 0x68f1, 0x695e, 0x51b7, 0x5398, 0x68a8, 0x7281, 0x9ece, + 0x7bf1, 0x72f8, 0x79bb, 0x6f13, 0x7406, 0x674e, 0x91cc, 0x9ca4, + 0x793c, 0x8389, 0x8354, 0x540f, 0x6817, 0x4e3d, 0x5389, 0x52b1, + 0x783e, 0x5386, 0x5229, 0x5088, 0x4f8b, 0x4fd0, + /* 0x41 */ + 0x75e2, 0x7acb, 0x7c92, 0x6ca5, 0x96b6, 0x529b, 0x7483, 0x54e9, + 0x4fe9, 0x8054, 0x83b2, 0x8fde, 0x9570, 0x5ec9, 0x601c, 0x6d9f, + 0x5e18, 0x655b, 0x8138, 0x94fe, 0x604b, 0x70bc, 0x7ec3, 0x7cae, + 0x51c9, 0x6881, 0x7cb1, 0x826f, 0x4e24, 0x8f86, 0x91cf, 0x667e, + 0x4eae, 0x8c05, 0x64a9, 0x804a, 0x50da, 0x7597, 0x71ce, 0x5be5, + 0x8fbd, 0x6f66, 0x4e86, 0x6482, 0x9563, 0x5ed6, 0x6599, 0x5217, + 0x88c2, 0x70c8, 0x52a3, 0x730e, 0x7433, 0x6797, 0x78f7, 0x9716, + 0x4e34, 0x90bb, 0x9cde, 0x6dcb, 0x51db, 0x8d41, 0x541d, 0x62ce, + 0x73b2, 0x83f1, 0x96f6, 0x9f84, 0x94c3, 0x4f36, 0x7f9a, 0x51cc, + 0x7075, 0x9675, 0x5cad, 0x9886, 0x53e6, 0x4ee4, 0x6e9c, 0x7409, + 0x69b4, 0x786b, 0x998f, 0x7559, 0x5218, 0x7624, 0x6d41, 0x67f3, + 0x516d, 0x9f99, 0x804b, 0x5499, 0x7b3c, 0x7abf, + /* 0x42 */ + 0x9686, 0x5784, 0x62e2, 0x9647, 0x697c, 0x5a04, 0x6402, 0x7bd3, + 0x6f0f, 0x964b, 0x82a6, 0x5362, 0x9885, 0x5e90, 0x7089, 0x63b3, + 0x5364, 0x864f, 0x9c81, 0x9e93, 0x788c, 0x9732, 0x8def, 0x8d42, + 0x9e7f, 0x6f5e, 0x7984, 0x5f55, 0x9646, 0x622e, 0x9a74, 0x5415, + 0x94dd, 0x4fa3, 0x65c5, 0x5c65, 0x5c61, 0x7f15, 0x8651, 0x6c2f, + 0x5f8b, 0x7387, 0x6ee4, 0x7eff, 0x5ce6, 0x631b, 0x5b6a, 0x6ee6, + 0x5375, 0x4e71, 0x63a0, 0x7565, 0x62a1, 0x8f6e, 0x4f26, 0x4ed1, + 0x6ca6, 0x7eb6, 0x8bba, 0x841d, 0x87ba, 0x7f57, 0x903b, 0x9523, + 0x7ba9, 0x9aa1, 0x88f8, 0x843d, 0x6d1b, 0x9a86, 0x7edc, 0x5988, + 0x9ebb, 0x739b, 0x7801, 0x8682, 0x9a6c, 0x9a82, 0x561b, 0x5417, + 0x57cb, 0x4e70, 0x9ea6, 0x5356, 0x8fc8, 0x8109, 0x7792, 0x9992, + 0x86ee, 0x6ee1, 0x8513, 0x66fc, 0x6162, 0x6f2b, + /* 0x43 */ + 0x8c29, 0x8292, 0x832b, 0x76f2, 0x6c13, 0x5fd9, 0x83bd, 0x732b, + 0x8305, 0x951a, 0x6bdb, 0x77db, 0x94c6, 0x536f, 0x8302, 0x5192, + 0x5e3d, 0x8c8c, 0x8d38, 0x4e48, 0x73ab, 0x679a, 0x6885, 0x9176, + 0x9709, 0x7164, 0x6ca1, 0x7709, 0x5a92, 0x9541, 0x6bcf, 0x7f8e, + 0x6627, 0x5bd0, 0x59b9, 0x5a9a, 0x95e8, 0x95f7, 0x4eec, 0x840c, + 0x8499, 0x6aac, 0x76df, 0x9530, 0x731b, 0x68a6, 0x5b5f, 0x772f, + 0x919a, 0x9761, 0x7cdc, 0x8ff7, 0x8c1c, 0x5f25, 0x7c73, 0x79d8, + 0x89c5, 0x6ccc, 0x871c, 0x5bc6, 0x5e42, 0x68c9, 0x7720, 0x7ef5, + 0x5195, 0x514d, 0x52c9, 0x5a29, 0x7f05, 0x9762, 0x82d7, 0x63cf, + 0x7784, 0x85d0, 0x79d2, 0x6e3a, 0x5e99, 0x5999, 0x8511, 0x706d, + 0x6c11, 0x62bf, 0x76bf, 0x654f, 0x60af, 0x95fd, 0x660e, 0x879f, + 0x9e23, 0x94ed, 0x540d, 0x547d, 0x8c2c, 0x6478, + /* 0x44 */ + 0x6479, 0x8611, 0x6a21, 0x819c, 0x78e8, 0x6469, 0x9b54, 0x62b9, + 0x672b, 0x83ab, 0x58a8, 0x9ed8, 0x6cab, 0x6f20, 0x5bde, 0x964c, + 0x8c0b, 0x725f, 0x67d0, 0x62c7, 0x7261, 0x4ea9, 0x59c6, 0x6bcd, + 0x5893, 0x66ae, 0x5e55, 0x52df, 0x6155, 0x6728, 0x76ee, 0x7766, + 0x7267, 0x7a46, 0x62ff, 0x54ea, 0x5450, 0x94a0, 0x90a3, 0x5a1c, + 0x7eb3, 0x6c16, 0x4e43, 0x5976, 0x8010, 0x5948, 0x5357, 0x7537, + 0x96be, 0x56ca, 0x6320, 0x8111, 0x607c, 0x95f9, 0x6dd6, 0x5462, + 0x9981, 0x5185, 0x5ae9, 0x80fd, 0x59ae, 0x9713, 0x502a, 0x6ce5, + 0x5c3c, 0x62df, 0x4f60, 0x533f, 0x817b, 0x9006, 0x6eba, 0x852b, + 0x62c8, 0x5e74, 0x78be, 0x64b5, 0x637b, 0x5ff5, 0x5a18, 0x917f, + 0x9e1f, 0x5c3f, 0x634f, 0x8042, 0x5b7d, 0x556e, 0x954a, 0x954d, + 0x6d85, 0x60a8, 0x67e0, 0x72de, 0x51dd, 0x5b81, + /* 0x45 */ + 0x62e7, 0x6cde, 0x725b, 0x626d, 0x94ae, 0x7ebd, 0x8113, 0x6d53, + 0x519c, 0x5f04, 0x5974, 0x52aa, 0x6012, 0x5973, 0x6696, 0x8650, + 0x759f, 0x632a, 0x61e6, 0x7cef, 0x8bfa, 0x54e6, 0x6b27, 0x9e25, + 0x6bb4, 0x85d5, 0x5455, 0x5076, 0x6ca4, 0x556a, 0x8db4, 0x722c, + 0x5e15, 0x6015, 0x7436, 0x62cd, 0x6392, 0x724c, 0x5f98, 0x6e43, + 0x6d3e, 0x6500, 0x6f58, 0x76d8, 0x78d0, 0x76fc, 0x7554, 0x5224, + 0x53db, 0x4e53, 0x5e9e, 0x65c1, 0x802a, 0x80d6, 0x629b, 0x5486, + 0x5228, 0x70ae, 0x888d, 0x8dd1, 0x6ce1, 0x5478, 0x80da, 0x57f9, + 0x88f4, 0x8d54, 0x966a, 0x914d, 0x4f69, 0x6c9b, 0x55b7, 0x76c6, + 0x7830, 0x62a8, 0x70f9, 0x6f8e, 0x5f6d, 0x84ec, 0x68da, 0x787c, + 0x7bf7, 0x81a8, 0x670b, 0x9e4f, 0x6367, 0x78b0, 0x576f, 0x7812, + 0x9739, 0x6279, 0x62ab, 0x5288, 0x7435, 0x6bd7, + /* 0x46 */ + 0x5564, 0x813e, 0x75b2, 0x76ae, 0x5339, 0x75de, 0x50fb, 0x5c41, + 0x8b6c, 0x7bc7, 0x504f, 0x7247, 0x9a97, 0x98d8, 0x6f02, 0x74e2, + 0x7968, 0x6487, 0x77a5, 0x62fc, 0x9891, 0x8d2b, 0x54c1, 0x8058, + 0x4e52, 0x576a, 0x82f9, 0x840d, 0x5e73, 0x51ed, 0x74f6, 0x8bc4, + 0x5c4f, 0x5761, 0x6cfc, 0x9887, 0x5a46, 0x7834, 0x9b44, 0x8feb, + 0x7c95, 0x5256, 0x6251, 0x94fa, 0x4ec6, 0x8386, 0x8461, 0x83e9, + 0x84b2, 0x57d4, 0x6734, 0x5703, 0x666e, 0x6d66, 0x8c31, 0x66dd, + 0x7011, 0x671f, 0x6b3a, 0x6816, 0x621a, 0x59bb, 0x4e03, 0x51c4, + 0x6f06, 0x67d2, 0x6c8f, 0x5176, 0x68cb, 0x5947, 0x6b67, 0x7566, + 0x5d0e, 0x8110, 0x9f50, 0x65d7, 0x7948, 0x7941, 0x9a91, 0x8d77, + 0x5c82, 0x4e5e, 0x4f01, 0x542f, 0x5951, 0x780c, 0x5668, 0x6c14, + 0x8fc4, 0x5f03, 0x6c7d, 0x6ce3, 0x8bab, 0x6390, + /* 0x47 */ + 0x6070, 0x6d3d, 0x7275, 0x6266, 0x948e, 0x94c5, 0x5343, 0x8fc1, + 0x7b7e, 0x4edf, 0x8c26, 0x4e7e, 0x9ed4, 0x94b1, 0x94b3, 0x524d, + 0x6f5c, 0x9063, 0x6d45, 0x8c34, 0x5811, 0x5d4c, 0x6b20, 0x6b49, + 0x67aa, 0x545b, 0x8154, 0x7f8c, 0x5899, 0x8537, 0x5f3a, 0x62a2, + 0x6a47, 0x9539, 0x6572, 0x6084, 0x6865, 0x77a7, 0x4e54, 0x4fa8, + 0x5de7, 0x9798, 0x64ac, 0x7fd8, 0x5ced, 0x4fcf, 0x7a8d, 0x5207, + 0x8304, 0x4e14, 0x602f, 0x7a83, 0x94a6, 0x4fb5, 0x4eb2, 0x79e6, + 0x7434, 0x52e4, 0x82b9, 0x64d2, 0x79bd, 0x5bdd, 0x6c81, 0x9752, + 0x8f7b, 0x6c22, 0x503e, 0x537f, 0x6e05, 0x64ce, 0x6674, 0x6c30, + 0x60c5, 0x9877, 0x8bf7, 0x5e86, 0x743c, 0x7a77, 0x79cb, 0x4e18, + 0x90b1, 0x7403, 0x6c42, 0x56da, 0x914b, 0x6cc5, 0x8d8b, 0x533a, + 0x86c6, 0x66f2, 0x8eaf, 0x5c48, 0x9a71, 0x6e20, + /* 0x48 */ + 0x53d6, 0x5a36, 0x9f8b, 0x8da3, 0x53bb, 0x5708, 0x98a7, 0x6743, + 0x919b, 0x6cc9, 0x5168, 0x75ca, 0x62f3, 0x72ac, 0x5238, 0x529d, + 0x7f3a, 0x7094, 0x7638, 0x5374, 0x9e4a, 0x69b7, 0x786e, 0x96c0, + 0x88d9, 0x7fa4, 0x7136, 0x71c3, 0x5189, 0x67d3, 0x74e4, 0x58e4, + 0x6518, 0x56b7, 0x8ba9, 0x9976, 0x6270, 0x7ed5, 0x60f9, 0x70ed, + 0x58ec, 0x4ec1, 0x4eba, 0x5fcd, 0x97e7, 0x4efb, 0x8ba4, 0x5203, + 0x598a, 0x7eab, 0x6254, 0x4ecd, 0x65e5, 0x620e, 0x8338, 0x84c9, + 0x8363, 0x878d, 0x7194, 0x6eb6, 0x5bb9, 0x7ed2, 0x5197, 0x63c9, + 0x67d4, 0x8089, 0x8339, 0x8815, 0x5112, 0x5b7a, 0x5982, 0x8fb1, + 0x4e73, 0x6c5d, 0x5165, 0x8925, 0x8f6f, 0x962e, 0x854a, 0x745e, + 0x9510, 0x95f0, 0x6da6, 0x82e5, 0x5f31, 0x6492, 0x6d12, 0x8428, + 0x816e, 0x9cc3, 0x585e, 0x8d5b, 0x4e09, 0x53c1, + /* 0x49 */ + 0x4f1e, 0x6563, 0x6851, 0x55d3, 0x4e27, 0x6414, 0x9a9a, 0x626b, + 0x5ac2, 0x745f, 0x8272, 0x6da9, 0x68ee, 0x50e7, 0x838e, 0x7802, + 0x6740, 0x5239, 0x6c99, 0x7eb1, 0x50bb, 0x5565, 0x715e, 0x7b5b, + 0x6652, 0x73ca, 0x82eb, 0x6749, 0x5c71, 0x5220, 0x717d, 0x886b, + 0x95ea, 0x9655, 0x64c5, 0x8d61, 0x81b3, 0x5584, 0x6c55, 0x6247, + 0x7f2e, 0x5892, 0x4f24, 0x5546, 0x8d4f, 0x664c, 0x4e0a, 0x5c1a, + 0x88f3, 0x68a2, 0x634e, 0x7a0d, 0x70e7, 0x828d, 0x52fa, 0x97f6, + 0x5c11, 0x54e8, 0x90b5, 0x7ecd, 0x5962, 0x8d4a, 0x86c7, 0x820c, + 0x820d, 0x8d66, 0x6444, 0x5c04, 0x6151, 0x6d89, 0x793e, 0x8bbe, + 0x7837, 0x7533, 0x547b, 0x4f38, 0x8eab, 0x6df1, 0x5a20, 0x7ec5, + 0x795e, 0x6c88, 0x5ba1, 0x5a76, 0x751a, 0x80be, 0x614e, 0x6e17, + 0x58f0, 0x751f, 0x7525, 0x7272, 0x5347, 0x7ef3, + /* 0x4a */ + 0x7701, 0x76db, 0x5269, 0x80dc, 0x5723, 0x5e08, 0x5931, 0x72ee, + 0x65bd, 0x6e7f, 0x8bd7, 0x5c38, 0x8671, 0x5341, 0x77f3, 0x62fe, + 0x65f6, 0x4ec0, 0x98df, 0x8680, 0x5b9e, 0x8bc6, 0x53f2, 0x77e2, + 0x4f7f, 0x5c4e, 0x9a76, 0x59cb, 0x5f0f, 0x793a, 0x58eb, 0x4e16, + 0x67ff, 0x4e8b, 0x62ed, 0x8a93, 0x901d, 0x52bf, 0x662f, 0x55dc, + 0x566c, 0x9002, 0x4ed5, 0x4f8d, 0x91ca, 0x9970, 0x6c0f, 0x5e02, + 0x6043, 0x5ba4, 0x89c6, 0x8bd5, 0x6536, 0x624b, 0x9996, 0x5b88, + 0x5bff, 0x6388, 0x552e, 0x53d7, 0x7626, 0x517d, 0x852c, 0x67a2, + 0x68b3, 0x6b8a, 0x6292, 0x8f93, 0x53d4, 0x8212, 0x6dd1, 0x758f, + 0x4e66, 0x8d4e, 0x5b70, 0x719f, 0x85af, 0x6691, 0x66d9, 0x7f72, + 0x8700, 0x9ecd, 0x9f20, 0x5c5e, 0x672f, 0x8ff0, 0x6811, 0x675f, + 0x620d, 0x7ad6, 0x5885, 0x5eb6, 0x6570, 0x6f31, + /* 0x4b */ + 0x6055, 0x5237, 0x800d, 0x6454, 0x8870, 0x7529, 0x5e05, 0x6813, + 0x62f4, 0x971c, 0x53cc, 0x723d, 0x8c01, 0x6c34, 0x7761, 0x7a0e, + 0x542e, 0x77ac, 0x987a, 0x821c, 0x8bf4, 0x7855, 0x6714, 0x70c1, + 0x65af, 0x6495, 0x5636, 0x601d, 0x79c1, 0x53f8, 0x4e1d, 0x6b7b, + 0x8086, 0x5bfa, 0x55e3, 0x56db, 0x4f3a, 0x4f3c, 0x9972, 0x5df3, + 0x677e, 0x8038, 0x6002, 0x9882, 0x9001, 0x5b8b, 0x8bbc, 0x8bf5, + 0x641c, 0x8258, 0x64de, 0x55fd, 0x82cf, 0x9165, 0x4fd7, 0x7d20, + 0x901f, 0x7c9f, 0x50f3, 0x5851, 0x6eaf, 0x5bbf, 0x8bc9, 0x8083, + 0x9178, 0x849c, 0x7b97, 0x867d, 0x968b, 0x968f, 0x7ee5, 0x9ad3, + 0x788e, 0x5c81, 0x7a57, 0x9042, 0x96a7, 0x795f, 0x5b59, 0x635f, + 0x7b0b, 0x84d1, 0x68ad, 0x5506, 0x7f29, 0x7410, 0x7d22, 0x9501, + 0x6240, 0x584c, 0x4ed6, 0x5b83, 0x5979, 0x5854, + /* 0x4c */ + 0x736d, 0x631e, 0x8e4b, 0x8e0f, 0x80ce, 0x82d4, 0x62ac, 0x53f0, + 0x6cf0, 0x915e, 0x592a, 0x6001, 0x6c70, 0x574d, 0x644a, 0x8d2a, + 0x762b, 0x6ee9, 0x575b, 0x6a80, 0x75f0, 0x6f6d, 0x8c2d, 0x8c08, + 0x5766, 0x6bef, 0x8892, 0x78b3, 0x63a2, 0x53f9, 0x70ad, 0x6c64, + 0x5858, 0x642a, 0x5802, 0x68e0, 0x819b, 0x5510, 0x7cd6, 0x5018, + 0x8eba, 0x6dcc, 0x8d9f, 0x70eb, 0x638f, 0x6d9b, 0x6ed4, 0x7ee6, + 0x8404, 0x6843, 0x9003, 0x6dd8, 0x9676, 0x8ba8, 0x5957, 0x7279, + 0x85e4, 0x817e, 0x75bc, 0x8a8a, 0x68af, 0x5254, 0x8e22, 0x9511, + 0x63d0, 0x9898, 0x8e44, 0x557c, 0x4f53, 0x66ff, 0x568f, 0x60d5, + 0x6d95, 0x5243, 0x5c49, 0x5929, 0x6dfb, 0x586b, 0x7530, 0x751c, + 0x606c, 0x8214, 0x8146, 0x6311, 0x6761, 0x8fe2, 0x773a, 0x8df3, + 0x8d34, 0x94c1, 0x5e16, 0x5385, 0x542c, 0x70c3, + /* 0x4d */ + 0x6c40, 0x5ef7, 0x505c, 0x4ead, 0x5ead, 0x633a, 0x8247, 0x901a, + 0x6850, 0x916e, 0x77b3, 0x540c, 0x94dc, 0x5f64, 0x7ae5, 0x6876, + 0x6345, 0x7b52, 0x7edf, 0x75db, 0x5077, 0x6295, 0x5934, 0x900f, + 0x51f8, 0x79c3, 0x7a81, 0x56fe, 0x5f92, 0x9014, 0x6d82, 0x5c60, + 0x571f, 0x5410, 0x5154, 0x6e4d, 0x56e2, 0x63a8, 0x9893, 0x817f, + 0x8715, 0x892a, 0x9000, 0x541e, 0x5c6f, 0x81c0, 0x62d6, 0x6258, + 0x8131, 0x9e35, 0x9640, 0x9a6e, 0x9a7c, 0x692d, 0x59a5, 0x62d3, + 0x553e, 0x6316, 0x54c7, 0x86d9, 0x6d3c, 0x5a03, 0x74e6, 0x889c, + 0x6b6a, 0x5916, 0x8c4c, 0x5f2f, 0x6e7e, 0x73a9, 0x987d, 0x4e38, + 0x70f7, 0x5b8c, 0x7897, 0x633d, 0x665a, 0x7696, 0x60cb, 0x5b9b, + 0x5a49, 0x4e07, 0x8155, 0x6c6a, 0x738b, 0x4ea1, 0x6789, 0x7f51, + 0x5f80, 0x65fa, 0x671b, 0x5fd8, 0x5984, 0x5a01, + /* 0x4e */ + 0x5dcd, 0x5fae, 0x5371, 0x97e6, 0x8fdd, 0x6845, 0x56f4, 0x552f, + 0x60df, 0x4e3a, 0x6f4d, 0x7ef4, 0x82c7, 0x840e, 0x59d4, 0x4f1f, + 0x4f2a, 0x5c3e, 0x7eac, 0x672a, 0x851a, 0x5473, 0x754f, 0x80c3, + 0x5582, 0x9b4f, 0x4f4d, 0x6e2d, 0x8c13, 0x5c09, 0x6170, 0x536b, + 0x761f, 0x6e29, 0x868a, 0x6587, 0x95fb, 0x7eb9, 0x543b, 0x7a33, + 0x7d0a, 0x95ee, 0x55e1, 0x7fc1, 0x74ee, 0x631d, 0x8717, 0x6da1, + 0x7a9d, 0x6211, 0x65a1, 0x5367, 0x63e1, 0x6c83, 0x5deb, 0x545c, + 0x94a8, 0x4e4c, 0x6c61, 0x8bec, 0x5c4b, 0x65e0, 0x829c, 0x68a7, + 0x543e, 0x5434, 0x6bcb, 0x6b66, 0x4e94, 0x6342, 0x5348, 0x821e, + 0x4f0d, 0x4fae, 0x575e, 0x620a, 0x96fe, 0x6664, 0x7269, 0x52ff, + 0x52a1, 0x609f, 0x8bef, 0x6614, 0x7199, 0x6790, 0x897f, 0x7852, + 0x77fd, 0x6670, 0x563b, 0x5438, 0x9521, 0x727a, + /* 0x4f */ + 0x7a00, 0x606f, 0x5e0c, 0x6089, 0x819d, 0x5915, 0x60dc, 0x7184, + 0x70ef, 0x6eaa, 0x6c50, 0x7280, 0x6a84, 0x88ad, 0x5e2d, 0x4e60, + 0x5ab3, 0x559c, 0x94e3, 0x6d17, 0x7cfb, 0x9699, 0x620f, 0x7ec6, + 0x778e, 0x867e, 0x5323, 0x971e, 0x8f96, 0x6687, 0x5ce1, 0x4fa0, + 0x72ed, 0x4e0b, 0x53a6, 0x590f, 0x5413, 0x6380, 0x9528, 0x5148, + 0x4ed9, 0x9c9c, 0x7ea4, 0x54b8, 0x8d24, 0x8854, 0x8237, 0x95f2, + 0x6d8e, 0x5f26, 0x5acc, 0x663e, 0x9669, 0x73b0, 0x732e, 0x53bf, + 0x817a, 0x9985, 0x7fa1, 0x5baa, 0x9677, 0x9650, 0x7ebf, 0x76f8, + 0x53a2, 0x9576, 0x9999, 0x7bb1, 0x8944, 0x6e58, 0x4e61, 0x7fd4, + 0x7965, 0x8be6, 0x60f3, 0x54cd, 0x4eab, 0x9879, 0x5df7, 0x6a61, + 0x50cf, 0x5411, 0x8c61, 0x8427, 0x785d, 0x9704, 0x524a, 0x54ee, + 0x56a3, 0x9500, 0x6d88, 0x5bb5, 0x6dc6, 0x6653, + /* 0x50 */ + 0x5c0f, 0x5b5d, 0x6821, 0x8096, 0x5578, 0x7b11, 0x6548, 0x6954, + 0x4e9b, 0x6b47, 0x874e, 0x978b, 0x534f, 0x631f, 0x643a, 0x90aa, + 0x659c, 0x80c1, 0x8c10, 0x5199, 0x68b0, 0x5378, 0x87f9, 0x61c8, + 0x6cc4, 0x6cfb, 0x8c22, 0x5c51, 0x85aa, 0x82af, 0x950c, 0x6b23, + 0x8f9b, 0x65b0, 0x5ffb, 0x5fc3, 0x4fe1, 0x8845, 0x661f, 0x8165, + 0x7329, 0x60fa, 0x5174, 0x5211, 0x578b, 0x5f62, 0x90a2, 0x884c, + 0x9192, 0x5e78, 0x674f, 0x6027, 0x59d3, 0x5144, 0x51f6, 0x80f8, + 0x5308, 0x6c79, 0x96c4, 0x718a, 0x4f11, 0x4fee, 0x7f9e, 0x673d, + 0x55c5, 0x9508, 0x79c0, 0x8896, 0x7ee3, 0x589f, 0x620c, 0x9700, + 0x865a, 0x5618, 0x987b, 0x5f90, 0x8bb8, 0x84c4, 0x9157, 0x53d9, + 0x65ed, 0x5e8f, 0x755c, 0x6064, 0x7d6e, 0x5a7f, 0x7eea, 0x7eed, + 0x8f69, 0x55a7, 0x5ba3, 0x60ac, 0x65cb, 0x7384, + /* 0x51 */ + 0x9009, 0x7663, 0x7729, 0x7eda, 0x9774, 0x859b, 0x5b66, 0x7a74, + 0x96ea, 0x8840, 0x52cb, 0x718f, 0x5faa, 0x65ec, 0x8be2, 0x5bfb, + 0x9a6f, 0x5de1, 0x6b89, 0x6c5b, 0x8bad, 0x8baf, 0x900a, 0x8fc5, + 0x538b, 0x62bc, 0x9e26, 0x9e2d, 0x5440, 0x4e2b, 0x82bd, 0x7259, + 0x869c, 0x5d16, 0x8859, 0x6daf, 0x96c5, 0x54d1, 0x4e9a, 0x8bb6, + 0x7109, 0x54bd, 0x9609, 0x70df, 0x6df9, 0x76d0, 0x4e25, 0x7814, + 0x8712, 0x5ca9, 0x5ef6, 0x8a00, 0x989c, 0x960e, 0x708e, 0x6cbf, + 0x5944, 0x63a9, 0x773c, 0x884d, 0x6f14, 0x8273, 0x5830, 0x71d5, + 0x538c, 0x781a, 0x96c1, 0x5501, 0x5f66, 0x7130, 0x5bb4, 0x8c1a, + 0x9a8c, 0x6b83, 0x592e, 0x9e2f, 0x79e7, 0x6768, 0x626c, 0x4f6f, + 0x75a1, 0x7f8a, 0x6d0b, 0x9633, 0x6c27, 0x4ef0, 0x75d2, 0x517b, + 0x6837, 0x6f3e, 0x9080, 0x8170, 0x5996, 0x7476, + /* 0x52 */ + 0x6447, 0x5c27, 0x9065, 0x7a91, 0x8c23, 0x59da, 0x54ac, 0x8200, + 0x836f, 0x8981, 0x8000, 0x6930, 0x564e, 0x8036, 0x7237, 0x91ce, + 0x51b6, 0x4e5f, 0x9875, 0x6396, 0x4e1a, 0x53f6, 0x66f3, 0x814b, + 0x591c, 0x6db2, 0x4e00, 0x58f9, 0x533b, 0x63d6, 0x94f1, 0x4f9d, + 0x4f0a, 0x8863, 0x9890, 0x5937, 0x9057, 0x79fb, 0x4eea, 0x80f0, + 0x7591, 0x6c82, 0x5b9c, 0x59e8, 0x5f5d, 0x6905, 0x8681, 0x501a, + 0x5df2, 0x4e59, 0x77e3, 0x4ee5, 0x827a, 0x6291, 0x6613, 0x9091, + 0x5c79, 0x4ebf, 0x5f79, 0x81c6, 0x9038, 0x8084, 0x75ab, 0x4ea6, + 0x88d4, 0x610f, 0x6bc5, 0x5fc6, 0x4e49, 0x76ca, 0x6ea2, 0x8be3, + 0x8bae, 0x8c0a, 0x8bd1, 0x5f02, 0x7ffc, 0x7fcc, 0x7ece, 0x8335, + 0x836b, 0x56e0, 0x6bb7, 0x97f3, 0x9634, 0x59fb, 0x541f, 0x94f6, + 0x6deb, 0x5bc5, 0x996e, 0x5c39, 0x5f15, 0x9690, + /* 0x53 */ + 0x5370, 0x82f1, 0x6a31, 0x5a74, 0x9e70, 0x5e94, 0x7f28, 0x83b9, + 0x8424, 0x8425, 0x8367, 0x8747, 0x8fce, 0x8d62, 0x76c8, 0x5f71, + 0x9896, 0x786c, 0x6620, 0x54df, 0x62e5, 0x4f63, 0x81c3, 0x75c8, + 0x5eb8, 0x96cd, 0x8e0a, 0x86f9, 0x548f, 0x6cf3, 0x6d8c, 0x6c38, + 0x607f, 0x52c7, 0x7528, 0x5e7d, 0x4f18, 0x60a0, 0x5fe7, 0x5c24, + 0x7531, 0x90ae, 0x94c0, 0x72b9, 0x6cb9, 0x6e38, 0x9149, 0x6709, + 0x53cb, 0x53f3, 0x4f51, 0x91c9, 0x8bf1, 0x53c8, 0x5e7c, 0x8fc2, + 0x6de4, 0x4e8e, 0x76c2, 0x6986, 0x865e, 0x611a, 0x8206, 0x4f59, + 0x4fde, 0x903e, 0x9c7c, 0x6109, 0x6e1d, 0x6e14, 0x9685, 0x4e88, + 0x5a31, 0x96e8, 0x4e0e, 0x5c7f, 0x79b9, 0x5b87, 0x8bed, 0x7fbd, + 0x7389, 0x57df, 0x828b, 0x90c1, 0x5401, 0x9047, 0x55bb, 0x5cea, + 0x5fa1, 0x6108, 0x6b32, 0x72f1, 0x80b2, 0x8a89, + /* 0x54 */ + 0x6d74, 0x5bd3, 0x88d5, 0x9884, 0x8c6b, 0x9a6d, 0x9e33, 0x6e0a, + 0x51a4, 0x5143, 0x57a3, 0x8881, 0x539f, 0x63f4, 0x8f95, 0x56ed, + 0x5458, 0x5706, 0x733f, 0x6e90, 0x7f18, 0x8fdc, 0x82d1, 0x613f, + 0x6028, 0x9662, 0x66f0, 0x7ea6, 0x8d8a, 0x8dc3, 0x94a5, 0x5cb3, + 0x7ca4, 0x6708, 0x60a6, 0x9605, 0x8018, 0x4e91, 0x90e7, 0x5300, + 0x9668, 0x5141, 0x8fd0, 0x8574, 0x915d, 0x6655, 0x97f5, 0x5b55, + 0x531d, 0x7838, 0x6742, 0x683d, 0x54c9, 0x707e, 0x5bb0, 0x8f7d, + 0x518d, 0x5728, 0x54b1, 0x6512, 0x6682, 0x8d5e, 0x8d43, 0x810f, + 0x846c, 0x906d, 0x7cdf, 0x51ff, 0x85fb, 0x67a3, 0x65e9, 0x6fa1, + 0x86a4, 0x8e81, 0x566a, 0x9020, 0x7682, 0x7076, 0x71e5, 0x8d23, + 0x62e9, 0x5219, 0x6cfd, 0x8d3c, 0x600e, 0x589e, 0x618e, 0x66fe, + 0x8d60, 0x624e, 0x55b3, 0x6e23, 0x672d, 0x8f67, + /* 0x55 */ + 0x94e1, 0x95f8, 0x7728, 0x6805, 0x69a8, 0x548b, 0x4e4d, 0x70b8, + 0x8bc8, 0x6458, 0x658b, 0x5b85, 0x7a84, 0x503a, 0x5be8, 0x77bb, + 0x6be1, 0x8a79, 0x7c98, 0x6cbe, 0x76cf, 0x65a9, 0x8f97, 0x5d2d, + 0x5c55, 0x8638, 0x6808, 0x5360, 0x6218, 0x7ad9, 0x6e5b, 0x7efd, + 0x6a1f, 0x7ae0, 0x5f70, 0x6f33, 0x5f20, 0x638c, 0x6da8, 0x6756, + 0x4e08, 0x5e10, 0x8d26, 0x4ed7, 0x80c0, 0x7634, 0x969c, 0x62db, + 0x662d, 0x627e, 0x6cbc, 0x8d75, 0x7167, 0x7f69, 0x5146, 0x8087, + 0x53ec, 0x906e, 0x6298, 0x54f2, 0x86f0, 0x8f99, 0x8005, 0x9517, + 0x8517, 0x8fd9, 0x6d59, 0x73cd, 0x659f, 0x771f, 0x7504, 0x7827, + 0x81fb, 0x8d1e, 0x9488, 0x4fa6, 0x6795, 0x75b9, 0x8bca, 0x9707, + 0x632f, 0x9547, 0x9635, 0x84b8, 0x6323, 0x7741, 0x5f81, 0x72f0, + 0x4e89, 0x6014, 0x6574, 0x62ef, 0x6b63, 0x653f, + /* 0x56 */ + 0x5e27, 0x75c7, 0x90d1, 0x8bc1, 0x829d, 0x679d, 0x652f, 0x5431, + 0x8718, 0x77e5, 0x80a2, 0x8102, 0x6c41, 0x4e4b, 0x7ec7, 0x804c, + 0x76f4, 0x690d, 0x6b96, 0x6267, 0x503c, 0x4f84, 0x5740, 0x6307, + 0x6b62, 0x8dbe, 0x53ea, 0x65e8, 0x7eb8, 0x5fd7, 0x631a, 0x63b7, + 0x81f3, 0x81f4, 0x7f6e, 0x5e1c, 0x5cd9, 0x5236, 0x667a, 0x79e9, + 0x7a1a, 0x8d28, 0x7099, 0x75d4, 0x6ede, 0x6cbb, 0x7a92, 0x4e2d, + 0x76c5, 0x5fe0, 0x949f, 0x8877, 0x7ec8, 0x79cd, 0x80bf, 0x91cd, + 0x4ef2, 0x4f17, 0x821f, 0x5468, 0x5dde, 0x6d32, 0x8bcc, 0x7ca5, + 0x8f74, 0x8098, 0x5e1a, 0x5492, 0x76b1, 0x5b99, 0x663c, 0x9aa4, + 0x73e0, 0x682a, 0x86db, 0x6731, 0x732a, 0x8bf8, 0x8bdb, 0x9010, + 0x7af9, 0x70db, 0x716e, 0x62c4, 0x77a9, 0x5631, 0x4e3b, 0x8457, + 0x67f1, 0x52a9, 0x86c0, 0x8d2e, 0x94f8, 0x7b51, + /* 0x57 */ + 0x4f4f, 0x6ce8, 0x795d, 0x9a7b, 0x6293, 0x722a, 0x62fd, 0x4e13, + 0x7816, 0x8f6c, 0x64b0, 0x8d5a, 0x7bc6, 0x6869, 0x5e84, 0x88c5, + 0x5986, 0x649e, 0x58ee, 0x72b6, 0x690e, 0x9525, 0x8ffd, 0x8d58, + 0x5760, 0x7f00, 0x8c06, 0x51c6, 0x6349, 0x62d9, 0x5353, 0x684c, + 0x7422, 0x8301, 0x914c, 0x5544, 0x7740, 0x707c, 0x6d4a, 0x5179, + 0x54a8, 0x8d44, 0x59ff, 0x6ecb, 0x6dc4, 0x5b5c, 0x7d2b, 0x4ed4, + 0x7c7d, 0x6ed3, 0x5b50, 0x81ea, 0x6e0d, 0x5b57, 0x9b03, 0x68d5, + 0x8e2a, 0x5b97, 0x7efc, 0x603b, 0x7eb5, 0x90b9, 0x8d70, 0x594f, + 0x63cd, 0x79df, 0x8db3, 0x5352, 0x65cf, 0x7956, 0x8bc5, 0x963b, + 0x7ec4, 0x94bb, 0x7e82, 0x5634, 0x9189, 0x6700, 0x7f6a, 0x5c0a, + 0x9075, 0x6628, 0x5de6, 0x4f50, 0x67de, 0x505a, 0x4f5c, 0x5750, + 0x5ea7, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x58 */ + 0x4e8d, 0x4e0c, 0x5140, 0x4e10, 0x5eff, 0x5345, 0x4e15, 0x4e98, + 0x4e1e, 0x9b32, 0x5b6c, 0x5669, 0x4e28, 0x79ba, 0x4e3f, 0x5315, + 0x4e47, 0x592d, 0x723b, 0x536e, 0x6c10, 0x56df, 0x80e4, 0x9997, + 0x6bd3, 0x777e, 0x9f17, 0x4e36, 0x4e9f, 0x9f10, 0x4e5c, 0x4e69, + 0x4e93, 0x8288, 0x5b5b, 0x556c, 0x560f, 0x4ec4, 0x538d, 0x539d, + 0x53a3, 0x53a5, 0x53ae, 0x9765, 0x8d5d, 0x531a, 0x53f5, 0x5326, + 0x532e, 0x533e, 0x8d5c, 0x5366, 0x5363, 0x5202, 0x5208, 0x520e, + 0x522d, 0x5233, 0x523f, 0x5240, 0x524c, 0x525e, 0x5261, 0x525c, + 0x84af, 0x527d, 0x5282, 0x5281, 0x5290, 0x5293, 0x5182, 0x7f54, + 0x4ebb, 0x4ec3, 0x4ec9, 0x4ec2, 0x4ee8, 0x4ee1, 0x4eeb, 0x4ede, + 0x4f1b, 0x4ef3, 0x4f22, 0x4f64, 0x4ef5, 0x4f25, 0x4f27, 0x4f09, + 0x4f2b, 0x4f5e, 0x4f67, 0x6538, 0x4f5a, 0x4f5d, + /* 0x59 */ + 0x4f5f, 0x4f57, 0x4f32, 0x4f3d, 0x4f76, 0x4f74, 0x4f91, 0x4f89, + 0x4f83, 0x4f8f, 0x4f7e, 0x4f7b, 0x4faa, 0x4f7c, 0x4fac, 0x4f94, + 0x4fe6, 0x4fe8, 0x4fea, 0x4fc5, 0x4fda, 0x4fe3, 0x4fdc, 0x4fd1, + 0x4fdf, 0x4ff8, 0x5029, 0x504c, 0x4ff3, 0x502c, 0x500f, 0x502e, + 0x502d, 0x4ffe, 0x501c, 0x500c, 0x5025, 0x5028, 0x507e, 0x5043, + 0x5055, 0x5048, 0x504e, 0x506c, 0x507b, 0x50a5, 0x50a7, 0x50a9, + 0x50ba, 0x50d6, 0x5106, 0x50ed, 0x50ec, 0x50e6, 0x50ee, 0x5107, + 0x510b, 0x4edd, 0x6c3d, 0x4f58, 0x4f65, 0x4fce, 0x9fa0, 0x6c46, + 0x7c74, 0x516e, 0x5dfd, 0x9ec9, 0x9998, 0x5181, 0x5914, 0x52f9, + 0x530d, 0x8a07, 0x5310, 0x51eb, 0x5919, 0x5155, 0x4ea0, 0x5156, + 0x4eb3, 0x886e, 0x88a4, 0x4eb5, 0x8114, 0x88d2, 0x7980, 0x5b34, + 0x8803, 0x7fb8, 0x51ab, 0x51b1, 0x51bd, 0x51bc, + /* 0x5a */ + 0x51c7, 0x5196, 0x51a2, 0x51a5, 0x8ba0, 0x8ba6, 0x8ba7, 0x8baa, + 0x8bb4, 0x8bb5, 0x8bb7, 0x8bc2, 0x8bc3, 0x8bcb, 0x8bcf, 0x8bce, + 0x8bd2, 0x8bd3, 0x8bd4, 0x8bd6, 0x8bd8, 0x8bd9, 0x8bdc, 0x8bdf, + 0x8be0, 0x8be4, 0x8be8, 0x8be9, 0x8bee, 0x8bf0, 0x8bf3, 0x8bf6, + 0x8bf9, 0x8bfc, 0x8bff, 0x8c00, 0x8c02, 0x8c04, 0x8c07, 0x8c0c, + 0x8c0f, 0x8c11, 0x8c12, 0x8c14, 0x8c15, 0x8c16, 0x8c19, 0x8c1b, + 0x8c18, 0x8c1d, 0x8c1f, 0x8c20, 0x8c21, 0x8c25, 0x8c27, 0x8c2a, + 0x8c2b, 0x8c2e, 0x8c2f, 0x8c32, 0x8c33, 0x8c35, 0x8c36, 0x5369, + 0x537a, 0x961d, 0x9622, 0x9621, 0x9631, 0x962a, 0x963d, 0x963c, + 0x9642, 0x9649, 0x9654, 0x965f, 0x9667, 0x966c, 0x9672, 0x9674, + 0x9688, 0x968d, 0x9697, 0x96b0, 0x9097, 0x909b, 0x909d, 0x9099, + 0x90ac, 0x90a1, 0x90b4, 0x90b3, 0x90b6, 0x90ba, + /* 0x5b */ + 0x90b8, 0x90b0, 0x90cf, 0x90c5, 0x90be, 0x90d0, 0x90c4, 0x90c7, + 0x90d3, 0x90e6, 0x90e2, 0x90dc, 0x90d7, 0x90db, 0x90eb, 0x90ef, + 0x90fe, 0x9104, 0x9122, 0x911e, 0x9123, 0x9131, 0x912f, 0x9139, + 0x9143, 0x9146, 0x520d, 0x5942, 0x52a2, 0x52ac, 0x52ad, 0x52be, + 0x54ff, 0x52d0, 0x52d6, 0x52f0, 0x53df, 0x71ee, 0x77cd, 0x5ef4, + 0x51f5, 0x51fc, 0x9b2f, 0x53b6, 0x5f01, 0x755a, 0x5def, 0x574c, + 0x57a9, 0x57a1, 0x587e, 0x58bc, 0x58c5, 0x58d1, 0x5729, 0x572c, + 0x572a, 0x5733, 0x5739, 0x572e, 0x572f, 0x575c, 0x573b, 0x5742, + 0x5769, 0x5785, 0x576b, 0x5786, 0x577c, 0x577b, 0x5768, 0x576d, + 0x5776, 0x5773, 0x57ad, 0x57a4, 0x578c, 0x57b2, 0x57cf, 0x57a7, + 0x57b4, 0x5793, 0x57a0, 0x57d5, 0x57d8, 0x57da, 0x57d9, 0x57d2, + 0x57b8, 0x57f4, 0x57ef, 0x57f8, 0x57e4, 0x57dd, + /* 0x5c */ + 0x580b, 0x580d, 0x57fd, 0x57ed, 0x5800, 0x581e, 0x5819, 0x5844, + 0x5820, 0x5865, 0x586c, 0x5881, 0x5889, 0x589a, 0x5880, 0x99a8, + 0x9f19, 0x61ff, 0x8279, 0x827d, 0x827f, 0x828f, 0x828a, 0x82a8, + 0x8284, 0x828e, 0x8291, 0x8297, 0x8299, 0x82ab, 0x82b8, 0x82be, + 0x82b0, 0x82c8, 0x82ca, 0x82e3, 0x8298, 0x82b7, 0x82ae, 0x82cb, + 0x82cc, 0x82c1, 0x82a9, 0x82b4, 0x82a1, 0x82aa, 0x829f, 0x82c4, + 0x82ce, 0x82a4, 0x82e1, 0x8309, 0x82f7, 0x82e4, 0x830f, 0x8307, + 0x82dc, 0x82f4, 0x82d2, 0x82d8, 0x830c, 0x82fb, 0x82d3, 0x8311, + 0x831a, 0x8306, 0x8314, 0x8315, 0x82e0, 0x82d5, 0x831c, 0x8351, + 0x835b, 0x835c, 0x8308, 0x8392, 0x833c, 0x8334, 0x8331, 0x839b, + 0x835e, 0x832f, 0x834f, 0x8347, 0x8343, 0x835f, 0x8340, 0x8317, + 0x8360, 0x832d, 0x833a, 0x8333, 0x8366, 0x8365, + /* 0x5d */ + 0x8368, 0x831b, 0x8369, 0x836c, 0x836a, 0x836d, 0x836e, 0x83b0, + 0x8378, 0x83b3, 0x83b4, 0x83a0, 0x83aa, 0x8393, 0x839c, 0x8385, + 0x837c, 0x83b6, 0x83a9, 0x837d, 0x83b8, 0x837b, 0x8398, 0x839e, + 0x83a8, 0x83ba, 0x83bc, 0x83c1, 0x8401, 0x83e5, 0x83d8, 0x5807, + 0x8418, 0x840b, 0x83dd, 0x83fd, 0x83d6, 0x841c, 0x8438, 0x8411, + 0x8406, 0x83d4, 0x83df, 0x840f, 0x8403, 0x83f8, 0x83f9, 0x83ea, + 0x83c5, 0x83c0, 0x8426, 0x83f0, 0x83e1, 0x845c, 0x8451, 0x845a, + 0x8459, 0x8473, 0x8487, 0x8488, 0x847a, 0x8489, 0x8478, 0x843c, + 0x8446, 0x8469, 0x8476, 0x848c, 0x848e, 0x8431, 0x846d, 0x84c1, + 0x84cd, 0x84d0, 0x84e6, 0x84bd, 0x84d3, 0x84ca, 0x84bf, 0x84ba, + 0x84e0, 0x84a1, 0x84b9, 0x84b4, 0x8497, 0x84e5, 0x84e3, 0x850c, + 0x750d, 0x8538, 0x84f0, 0x8539, 0x851f, 0x853a, + /* 0x5e */ + 0x8556, 0x853b, 0x84ff, 0x84fc, 0x8559, 0x8548, 0x8568, 0x8564, + 0x855e, 0x857a, 0x77a2, 0x8543, 0x8572, 0x857b, 0x85a4, 0x85a8, + 0x8587, 0x858f, 0x8579, 0x85ae, 0x859c, 0x8585, 0x85b9, 0x85b7, + 0x85b0, 0x85d3, 0x85c1, 0x85dc, 0x85ff, 0x8627, 0x8605, 0x8629, + 0x8616, 0x863c, 0x5efe, 0x5f08, 0x593c, 0x5941, 0x8037, 0x5955, + 0x595a, 0x5958, 0x530f, 0x5c22, 0x5c25, 0x5c2c, 0x5c34, 0x624c, + 0x626a, 0x629f, 0x62bb, 0x62ca, 0x62da, 0x62d7, 0x62ee, 0x6322, + 0x62f6, 0x6339, 0x634b, 0x6343, 0x63ad, 0x63f6, 0x6371, 0x637a, + 0x638e, 0x63b4, 0x636d, 0x63ac, 0x638a, 0x6369, 0x63ae, 0x63bc, + 0x63f2, 0x63f8, 0x63e0, 0x63ff, 0x63c4, 0x63de, 0x63ce, 0x6452, + 0x63c6, 0x63be, 0x6445, 0x6441, 0x640b, 0x641b, 0x6420, 0x640c, + 0x6426, 0x6421, 0x645e, 0x6484, 0x646d, 0x6496, + /* 0x5f */ + 0x647a, 0x64b7, 0x64b8, 0x6499, 0x64ba, 0x64c0, 0x64d0, 0x64d7, + 0x64e4, 0x64e2, 0x6509, 0x6525, 0x652e, 0x5f0b, 0x5fd2, 0x7519, + 0x5f11, 0x535f, 0x53f1, 0x53fd, 0x53e9, 0x53e8, 0x53fb, 0x5412, + 0x5416, 0x5406, 0x544b, 0x5452, 0x5453, 0x5454, 0x5456, 0x5443, + 0x5421, 0x5457, 0x5459, 0x5423, 0x5432, 0x5482, 0x5494, 0x5477, + 0x5471, 0x5464, 0x549a, 0x549b, 0x5484, 0x5476, 0x5466, 0x549d, + 0x54d0, 0x54ad, 0x54c2, 0x54b4, 0x54d2, 0x54a7, 0x54a6, 0x54d3, + 0x54d4, 0x5472, 0x54a3, 0x54d5, 0x54bb, 0x54bf, 0x54cc, 0x54d9, + 0x54da, 0x54dc, 0x54a9, 0x54aa, 0x54a4, 0x54dd, 0x54cf, 0x54de, + 0x551b, 0x54e7, 0x5520, 0x54fd, 0x5514, 0x54f3, 0x5522, 0x5523, + 0x550f, 0x5511, 0x5527, 0x552a, 0x5567, 0x558f, 0x55b5, 0x5549, + 0x556d, 0x5541, 0x5555, 0x553f, 0x5550, 0x553c, + /* 0x60 */ + 0x5537, 0x5556, 0x5575, 0x5576, 0x5577, 0x5533, 0x5530, 0x555c, + 0x558b, 0x55d2, 0x5583, 0x55b1, 0x55b9, 0x5588, 0x5581, 0x559f, + 0x557e, 0x55d6, 0x5591, 0x557b, 0x55df, 0x55bd, 0x55be, 0x5594, + 0x5599, 0x55ea, 0x55f7, 0x55c9, 0x561f, 0x55d1, 0x55eb, 0x55ec, + 0x55d4, 0x55e6, 0x55dd, 0x55c4, 0x55ef, 0x55e5, 0x55f2, 0x55f3, + 0x55cc, 0x55cd, 0x55e8, 0x55f5, 0x55e4, 0x8f94, 0x561e, 0x5608, + 0x560c, 0x5601, 0x5624, 0x5623, 0x55fe, 0x5600, 0x5627, 0x562d, + 0x5658, 0x5639, 0x5657, 0x562c, 0x564d, 0x5662, 0x5659, 0x565c, + 0x564c, 0x5654, 0x5686, 0x5664, 0x5671, 0x566b, 0x567b, 0x567c, + 0x5685, 0x5693, 0x56af, 0x56d4, 0x56d7, 0x56dd, 0x56e1, 0x56f5, + 0x56eb, 0x56f9, 0x56ff, 0x5704, 0x570a, 0x5709, 0x571c, 0x5e0f, + 0x5e19, 0x5e14, 0x5e11, 0x5e31, 0x5e3b, 0x5e3c, + /* 0x61 */ + 0x5e37, 0x5e44, 0x5e54, 0x5e5b, 0x5e5e, 0x5e61, 0x5c8c, 0x5c7a, + 0x5c8d, 0x5c90, 0x5c96, 0x5c88, 0x5c98, 0x5c99, 0x5c91, 0x5c9a, + 0x5c9c, 0x5cb5, 0x5ca2, 0x5cbd, 0x5cac, 0x5cab, 0x5cb1, 0x5ca3, + 0x5cc1, 0x5cb7, 0x5cc4, 0x5cd2, 0x5ce4, 0x5ccb, 0x5ce5, 0x5d02, + 0x5d03, 0x5d27, 0x5d26, 0x5d2e, 0x5d24, 0x5d1e, 0x5d06, 0x5d1b, + 0x5d58, 0x5d3e, 0x5d34, 0x5d3d, 0x5d6c, 0x5d5b, 0x5d6f, 0x5d5d, + 0x5d6b, 0x5d4b, 0x5d4a, 0x5d69, 0x5d74, 0x5d82, 0x5d99, 0x5d9d, + 0x8c73, 0x5db7, 0x5dc5, 0x5f73, 0x5f77, 0x5f82, 0x5f87, 0x5f89, + 0x5f8c, 0x5f95, 0x5f99, 0x5f9c, 0x5fa8, 0x5fad, 0x5fb5, 0x5fbc, + 0x8862, 0x5f61, 0x72ad, 0x72b0, 0x72b4, 0x72b7, 0x72b8, 0x72c3, + 0x72c1, 0x72ce, 0x72cd, 0x72d2, 0x72e8, 0x72ef, 0x72e9, 0x72f2, + 0x72f4, 0x72f7, 0x7301, 0x72f3, 0x7303, 0x72fa, + /* 0x62 */ + 0x72fb, 0x7317, 0x7313, 0x7321, 0x730a, 0x731e, 0x731d, 0x7315, + 0x7322, 0x7339, 0x7325, 0x732c, 0x7338, 0x7331, 0x7350, 0x734d, + 0x7357, 0x7360, 0x736c, 0x736f, 0x737e, 0x821b, 0x5925, 0x98e7, + 0x5924, 0x5902, 0x9963, 0x9967, 0x9968, 0x9969, 0x996a, 0x996b, + 0x996c, 0x9974, 0x9977, 0x997d, 0x9980, 0x9984, 0x9987, 0x998a, + 0x998d, 0x9990, 0x9991, 0x9993, 0x9994, 0x9995, 0x5e80, 0x5e91, + 0x5e8b, 0x5e96, 0x5ea5, 0x5ea0, 0x5eb9, 0x5eb5, 0x5ebe, 0x5eb3, + 0x8d53, 0x5ed2, 0x5ed1, 0x5edb, 0x5ee8, 0x5eea, 0x81ba, 0x5fc4, + 0x5fc9, 0x5fd6, 0x5fcf, 0x6003, 0x5fee, 0x6004, 0x5fe1, 0x5fe4, + 0x5ffe, 0x6005, 0x6006, 0x5fea, 0x5fed, 0x5ff8, 0x6019, 0x6035, + 0x6026, 0x601b, 0x600f, 0x600d, 0x6029, 0x602b, 0x600a, 0x603f, + 0x6021, 0x6078, 0x6079, 0x607b, 0x607a, 0x6042, + /* 0x63 */ + 0x606a, 0x607d, 0x6096, 0x609a, 0x60ad, 0x609d, 0x6083, 0x6092, + 0x608c, 0x609b, 0x60ec, 0x60bb, 0x60b1, 0x60dd, 0x60d8, 0x60c6, + 0x60da, 0x60b4, 0x6120, 0x6126, 0x6115, 0x6123, 0x60f4, 0x6100, + 0x610e, 0x612b, 0x614a, 0x6175, 0x61ac, 0x6194, 0x61a7, 0x61b7, + 0x61d4, 0x61f5, 0x5fdd, 0x96b3, 0x95e9, 0x95eb, 0x95f1, 0x95f3, + 0x95f5, 0x95f6, 0x95fc, 0x95fe, 0x9603, 0x9604, 0x9606, 0x9608, + 0x960a, 0x960b, 0x960c, 0x960d, 0x960f, 0x9612, 0x9615, 0x9616, + 0x9617, 0x9619, 0x961a, 0x4e2c, 0x723f, 0x6215, 0x6c35, 0x6c54, + 0x6c5c, 0x6c4a, 0x6ca3, 0x6c85, 0x6c90, 0x6c94, 0x6c8c, 0x6c68, + 0x6c69, 0x6c74, 0x6c76, 0x6c86, 0x6ca9, 0x6cd0, 0x6cd4, 0x6cad, + 0x6cf7, 0x6cf8, 0x6cf1, 0x6cd7, 0x6cb2, 0x6ce0, 0x6cd6, 0x6cfa, + 0x6ceb, 0x6cee, 0x6cb1, 0x6cd3, 0x6cef, 0x6cfe, + /* 0x64 */ + 0x6d39, 0x6d27, 0x6d0c, 0x6d43, 0x6d48, 0x6d07, 0x6d04, 0x6d19, + 0x6d0e, 0x6d2b, 0x6d4d, 0x6d2e, 0x6d35, 0x6d1a, 0x6d4f, 0x6d52, + 0x6d54, 0x6d33, 0x6d91, 0x6d6f, 0x6d9e, 0x6da0, 0x6d5e, 0x6d93, + 0x6d94, 0x6d5c, 0x6d60, 0x6d7c, 0x6d63, 0x6e1a, 0x6dc7, 0x6dc5, + 0x6dde, 0x6e0e, 0x6dbf, 0x6de0, 0x6e11, 0x6de6, 0x6ddd, 0x6dd9, + 0x6e16, 0x6dab, 0x6e0c, 0x6dae, 0x6e2b, 0x6e6e, 0x6e4e, 0x6e6b, + 0x6eb2, 0x6e5f, 0x6e86, 0x6e53, 0x6e54, 0x6e32, 0x6e25, 0x6e44, + 0x6edf, 0x6eb1, 0x6e98, 0x6ee0, 0x6f2d, 0x6ee2, 0x6ea5, 0x6ea7, + 0x6ebd, 0x6ebb, 0x6eb7, 0x6ed7, 0x6eb4, 0x6ecf, 0x6e8f, 0x6ec2, + 0x6e9f, 0x6f62, 0x6f46, 0x6f47, 0x6f24, 0x6f15, 0x6ef9, 0x6f2f, + 0x6f36, 0x6f4b, 0x6f74, 0x6f2a, 0x6f09, 0x6f29, 0x6f89, 0x6f8d, + 0x6f8c, 0x6f78, 0x6f72, 0x6f7c, 0x6f7a, 0x6fd1, + /* 0x65 */ + 0x6fc9, 0x6fa7, 0x6fb9, 0x6fb6, 0x6fc2, 0x6fe1, 0x6fee, 0x6fde, + 0x6fe0, 0x6fef, 0x701a, 0x7023, 0x701b, 0x7039, 0x7035, 0x704f, + 0x705e, 0x5b80, 0x5b84, 0x5b95, 0x5b93, 0x5ba5, 0x5bb8, 0x752f, + 0x9a9e, 0x6434, 0x5be4, 0x5bee, 0x8930, 0x5bf0, 0x8e47, 0x8b07, + 0x8fb6, 0x8fd3, 0x8fd5, 0x8fe5, 0x8fee, 0x8fe4, 0x8fe9, 0x8fe6, + 0x8ff3, 0x8fe8, 0x9005, 0x9004, 0x900b, 0x9026, 0x9011, 0x900d, + 0x9016, 0x9021, 0x9035, 0x9036, 0x902d, 0x902f, 0x9044, 0x9051, + 0x9052, 0x9050, 0x9068, 0x9058, 0x9062, 0x905b, 0x66b9, 0x9074, + 0x907d, 0x9082, 0x9088, 0x9083, 0x908b, 0x5f50, 0x5f57, 0x5f56, + 0x5f58, 0x5c3b, 0x54ab, 0x5c50, 0x5c59, 0x5b71, 0x5c63, 0x5c66, + 0x7fbc, 0x5f2a, 0x5f29, 0x5f2d, 0x8274, 0x5f3c, 0x9b3b, 0x5c6e, + 0x5981, 0x5983, 0x598d, 0x59a9, 0x59aa, 0x59a3, + /* 0x66 */ + 0x5997, 0x59ca, 0x59ab, 0x599e, 0x59a4, 0x59d2, 0x59b2, 0x59af, + 0x59d7, 0x59be, 0x5a05, 0x5a06, 0x59dd, 0x5a08, 0x59e3, 0x59d8, + 0x59f9, 0x5a0c, 0x5a09, 0x5a32, 0x5a34, 0x5a11, 0x5a23, 0x5a13, + 0x5a40, 0x5a67, 0x5a4a, 0x5a55, 0x5a3c, 0x5a62, 0x5a75, 0x80ec, + 0x5aaa, 0x5a9b, 0x5a77, 0x5a7a, 0x5abe, 0x5aeb, 0x5ab2, 0x5ad2, + 0x5ad4, 0x5ab8, 0x5ae0, 0x5ae3, 0x5af1, 0x5ad6, 0x5ae6, 0x5ad8, + 0x5adc, 0x5b09, 0x5b17, 0x5b16, 0x5b32, 0x5b37, 0x5b40, 0x5c15, + 0x5c1c, 0x5b5a, 0x5b65, 0x5b73, 0x5b51, 0x5b53, 0x5b62, 0x9a75, + 0x9a77, 0x9a78, 0x9a7a, 0x9a7f, 0x9a7d, 0x9a80, 0x9a81, 0x9a85, + 0x9a88, 0x9a8a, 0x9a90, 0x9a92, 0x9a93, 0x9a96, 0x9a98, 0x9a9b, + 0x9a9c, 0x9a9d, 0x9a9f, 0x9aa0, 0x9aa2, 0x9aa3, 0x9aa5, 0x9aa7, + 0x7e9f, 0x7ea1, 0x7ea3, 0x7ea5, 0x7ea8, 0x7ea9, + /* 0x67 */ + 0x7ead, 0x7eb0, 0x7ebe, 0x7ec0, 0x7ec1, 0x7ec2, 0x7ec9, 0x7ecb, + 0x7ecc, 0x7ed0, 0x7ed4, 0x7ed7, 0x7edb, 0x7ee0, 0x7ee1, 0x7ee8, + 0x7eeb, 0x7eee, 0x7eef, 0x7ef1, 0x7ef2, 0x7f0d, 0x7ef6, 0x7efa, + 0x7efb, 0x7efe, 0x7f01, 0x7f02, 0x7f03, 0x7f07, 0x7f08, 0x7f0b, + 0x7f0c, 0x7f0f, 0x7f11, 0x7f12, 0x7f17, 0x7f19, 0x7f1c, 0x7f1b, + 0x7f1f, 0x7f21, 0x7f22, 0x7f23, 0x7f24, 0x7f25, 0x7f26, 0x7f27, + 0x7f2a, 0x7f2b, 0x7f2c, 0x7f2d, 0x7f2f, 0x7f30, 0x7f31, 0x7f32, + 0x7f33, 0x7f35, 0x5e7a, 0x757f, 0x5ddb, 0x753e, 0x9095, 0x738e, + 0x7391, 0x73ae, 0x73a2, 0x739f, 0x73cf, 0x73c2, 0x73d1, 0x73b7, + 0x73b3, 0x73c0, 0x73c9, 0x73c8, 0x73e5, 0x73d9, 0x987c, 0x740a, + 0x73e9, 0x73e7, 0x73de, 0x73ba, 0x73f2, 0x740f, 0x742a, 0x745b, + 0x7426, 0x7425, 0x7428, 0x7430, 0x742e, 0x742c, + /* 0x68 */ + 0x741b, 0x741a, 0x7441, 0x745c, 0x7457, 0x7455, 0x7459, 0x7477, + 0x746d, 0x747e, 0x749c, 0x748e, 0x7480, 0x7481, 0x7487, 0x748b, + 0x749e, 0x74a8, 0x74a9, 0x7490, 0x74a7, 0x74d2, 0x74ba, 0x97ea, + 0x97eb, 0x97ec, 0x674c, 0x6753, 0x675e, 0x6748, 0x6769, 0x67a5, + 0x6787, 0x676a, 0x6773, 0x6798, 0x67a7, 0x6775, 0x67a8, 0x679e, + 0x67ad, 0x678b, 0x6777, 0x677c, 0x67f0, 0x6809, 0x67d8, 0x680a, + 0x67e9, 0x67b0, 0x680c, 0x67d9, 0x67b5, 0x67da, 0x67b3, 0x67dd, + 0x6800, 0x67c3, 0x67b8, 0x67e2, 0x680e, 0x67c1, 0x67fd, 0x6832, + 0x6833, 0x6860, 0x6861, 0x684e, 0x6862, 0x6844, 0x6864, 0x6883, + 0x681d, 0x6855, 0x6866, 0x6841, 0x6867, 0x6840, 0x683e, 0x684a, + 0x6849, 0x6829, 0x68b5, 0x688f, 0x6874, 0x6877, 0x6893, 0x686b, + 0x68c2, 0x696e, 0x68fc, 0x691f, 0x6920, 0x68f9, + /* 0x69 */ + 0x6924, 0x68f0, 0x690b, 0x6901, 0x6957, 0x68e3, 0x6910, 0x6971, + 0x6939, 0x6960, 0x6942, 0x695d, 0x6984, 0x696b, 0x6980, 0x6998, + 0x6978, 0x6934, 0x69cc, 0x6987, 0x6988, 0x69ce, 0x6989, 0x6966, + 0x6963, 0x6979, 0x699b, 0x69a7, 0x69bb, 0x69ab, 0x69ad, 0x69d4, + 0x69b1, 0x69c1, 0x69ca, 0x69df, 0x6995, 0x69e0, 0x698d, 0x69ff, + 0x6a2f, 0x69ed, 0x6a17, 0x6a18, 0x6a65, 0x69f2, 0x6a44, 0x6a3e, + 0x6aa0, 0x6a50, 0x6a5b, 0x6a35, 0x6a8e, 0x6a79, 0x6a3d, 0x6a28, + 0x6a58, 0x6a7c, 0x6a91, 0x6a90, 0x6aa9, 0x6a97, 0x6aab, 0x7337, + 0x7352, 0x6b81, 0x6b82, 0x6b87, 0x6b84, 0x6b92, 0x6b93, 0x6b8d, + 0x6b9a, 0x6b9b, 0x6ba1, 0x6baa, 0x8f6b, 0x8f6d, 0x8f71, 0x8f72, + 0x8f73, 0x8f75, 0x8f76, 0x8f78, 0x8f77, 0x8f79, 0x8f7a, 0x8f7c, + 0x8f7e, 0x8f81, 0x8f82, 0x8f84, 0x8f87, 0x8f8b, + /* 0x6a */ + 0x8f8d, 0x8f8e, 0x8f8f, 0x8f98, 0x8f9a, 0x8ece, 0x620b, 0x6217, + 0x621b, 0x621f, 0x6222, 0x6221, 0x6225, 0x6224, 0x622c, 0x81e7, + 0x74ef, 0x74f4, 0x74ff, 0x750f, 0x7511, 0x7513, 0x6534, 0x65ee, + 0x65ef, 0x65f0, 0x660a, 0x6619, 0x6772, 0x6603, 0x6615, 0x6600, + 0x7085, 0x66f7, 0x661d, 0x6634, 0x6631, 0x6636, 0x6635, 0x8006, + 0x665f, 0x6654, 0x6641, 0x664f, 0x6656, 0x6661, 0x6657, 0x6677, + 0x6684, 0x668c, 0x66a7, 0x669d, 0x66be, 0x66db, 0x66dc, 0x66e6, + 0x66e9, 0x8d32, 0x8d33, 0x8d36, 0x8d3b, 0x8d3d, 0x8d40, 0x8d45, + 0x8d46, 0x8d48, 0x8d49, 0x8d47, 0x8d4d, 0x8d55, 0x8d59, 0x89c7, + 0x89ca, 0x89cb, 0x89cc, 0x89ce, 0x89cf, 0x89d0, 0x89d1, 0x726e, + 0x729f, 0x725d, 0x7266, 0x726f, 0x727e, 0x727f, 0x7284, 0x728b, + 0x728d, 0x728f, 0x7292, 0x6308, 0x6332, 0x63b0, + /* 0x6b */ + 0x643f, 0x64d8, 0x8004, 0x6bea, 0x6bf3, 0x6bfd, 0x6bf5, 0x6bf9, + 0x6c05, 0x6c07, 0x6c06, 0x6c0d, 0x6c15, 0x6c18, 0x6c19, 0x6c1a, + 0x6c21, 0x6c29, 0x6c24, 0x6c2a, 0x6c32, 0x6535, 0x6555, 0x656b, + 0x724d, 0x7252, 0x7256, 0x7230, 0x8662, 0x5216, 0x809f, 0x809c, + 0x8093, 0x80bc, 0x670a, 0x80bd, 0x80b1, 0x80ab, 0x80ad, 0x80b4, + 0x80b7, 0x80e7, 0x80e8, 0x80e9, 0x80ea, 0x80db, 0x80c2, 0x80c4, + 0x80d9, 0x80cd, 0x80d7, 0x6710, 0x80dd, 0x80eb, 0x80f1, 0x80f4, + 0x80ed, 0x810d, 0x810e, 0x80f2, 0x80fc, 0x6715, 0x8112, 0x8c5a, + 0x8136, 0x811e, 0x812c, 0x8118, 0x8132, 0x8148, 0x814c, 0x8153, + 0x8174, 0x8159, 0x815a, 0x8171, 0x8160, 0x8169, 0x817c, 0x817d, + 0x816d, 0x8167, 0x584d, 0x5ab5, 0x8188, 0x8182, 0x8191, 0x6ed5, + 0x81a3, 0x81aa, 0x81cc, 0x6726, 0x81ca, 0x81bb, + /* 0x6c */ + 0x81c1, 0x81a6, 0x6b24, 0x6b37, 0x6b39, 0x6b43, 0x6b46, 0x6b59, + 0x98d1, 0x98d2, 0x98d3, 0x98d5, 0x98d9, 0x98da, 0x6bb3, 0x5f40, + 0x6bc2, 0x89f3, 0x6590, 0x9f51, 0x6593, 0x65bc, 0x65c6, 0x65c4, + 0x65c3, 0x65cc, 0x65ce, 0x65d2, 0x65d6, 0x7080, 0x709c, 0x7096, + 0x709d, 0x70bb, 0x70c0, 0x70b7, 0x70ab, 0x70b1, 0x70e8, 0x70ca, + 0x7110, 0x7113, 0x7116, 0x712f, 0x7131, 0x7173, 0x715c, 0x7168, + 0x7145, 0x7172, 0x714a, 0x7178, 0x717a, 0x7198, 0x71b3, 0x71b5, + 0x71a8, 0x71a0, 0x71e0, 0x71d4, 0x71e7, 0x71f9, 0x721d, 0x7228, + 0x706c, 0x7118, 0x7166, 0x71b9, 0x623e, 0x623d, 0x6243, 0x6248, + 0x6249, 0x793b, 0x7940, 0x7946, 0x7949, 0x795b, 0x795c, 0x7953, + 0x795a, 0x7962, 0x7957, 0x7960, 0x796f, 0x7967, 0x797a, 0x7985, + 0x798a, 0x799a, 0x79a7, 0x79b3, 0x5fd1, 0x5fd0, + /* 0x6d */ + 0x603c, 0x605d, 0x605a, 0x6067, 0x6041, 0x6059, 0x6063, 0x60ab, + 0x6106, 0x610d, 0x615d, 0x61a9, 0x619d, 0x61cb, 0x61d1, 0x6206, + 0x8080, 0x807f, 0x6c93, 0x6cf6, 0x6dfc, 0x77f6, 0x77f8, 0x7800, + 0x7809, 0x7817, 0x7818, 0x7811, 0x65ab, 0x782d, 0x781c, 0x781d, + 0x7839, 0x783a, 0x783b, 0x781f, 0x783c, 0x7825, 0x782c, 0x7823, + 0x7829, 0x784e, 0x786d, 0x7856, 0x7857, 0x7826, 0x7850, 0x7847, + 0x784c, 0x786a, 0x789b, 0x7893, 0x789a, 0x7887, 0x789c, 0x78a1, + 0x78a3, 0x78b2, 0x78b9, 0x78a5, 0x78d4, 0x78d9, 0x78c9, 0x78ec, + 0x78f2, 0x7905, 0x78f4, 0x7913, 0x7924, 0x791e, 0x7934, 0x9f9b, + 0x9ef9, 0x9efb, 0x9efc, 0x76f1, 0x7704, 0x770d, 0x76f9, 0x7707, + 0x7708, 0x771a, 0x7722, 0x7719, 0x772d, 0x7726, 0x7735, 0x7738, + 0x7750, 0x7751, 0x7747, 0x7743, 0x775a, 0x7768, + /* 0x6e */ + 0x7762, 0x7765, 0x777f, 0x778d, 0x777d, 0x7780, 0x778c, 0x7791, + 0x779f, 0x77a0, 0x77b0, 0x77b5, 0x77bd, 0x753a, 0x7540, 0x754e, + 0x754b, 0x7548, 0x755b, 0x7572, 0x7579, 0x7583, 0x7f58, 0x7f61, + 0x7f5f, 0x8a48, 0x7f68, 0x7f74, 0x7f71, 0x7f79, 0x7f81, 0x7f7e, + 0x76cd, 0x76e5, 0x8832, 0x9485, 0x9486, 0x9487, 0x948b, 0x948a, + 0x948c, 0x948d, 0x948f, 0x9490, 0x9494, 0x9497, 0x9495, 0x949a, + 0x949b, 0x949c, 0x94a3, 0x94a4, 0x94ab, 0x94aa, 0x94ad, 0x94ac, + 0x94af, 0x94b0, 0x94b2, 0x94b4, 0x94b6, 0x94b7, 0x94b8, 0x94b9, + 0x94ba, 0x94bc, 0x94bd, 0x94bf, 0x94c4, 0x94c8, 0x94c9, 0x94ca, + 0x94cb, 0x94cc, 0x94cd, 0x94ce, 0x94d0, 0x94d1, 0x94d2, 0x94d5, + 0x94d6, 0x94d7, 0x94d9, 0x94d8, 0x94db, 0x94de, 0x94df, 0x94e0, + 0x94e2, 0x94e4, 0x94e5, 0x94e7, 0x94e8, 0x94ea, + /* 0x6f */ + 0x94e9, 0x94eb, 0x94ee, 0x94ef, 0x94f3, 0x94f4, 0x94f5, 0x94f7, + 0x94f9, 0x94fc, 0x94fd, 0x94ff, 0x9503, 0x9502, 0x9506, 0x9507, + 0x9509, 0x950a, 0x950d, 0x950e, 0x950f, 0x9512, 0x9513, 0x9514, + 0x9515, 0x9516, 0x9518, 0x951b, 0x951d, 0x951e, 0x951f, 0x9522, + 0x952a, 0x952b, 0x9529, 0x952c, 0x9531, 0x9532, 0x9534, 0x9536, + 0x9537, 0x9538, 0x953c, 0x953e, 0x953f, 0x9542, 0x9535, 0x9544, + 0x9545, 0x9546, 0x9549, 0x954c, 0x954e, 0x954f, 0x9552, 0x9553, + 0x9554, 0x9556, 0x9557, 0x9558, 0x9559, 0x955b, 0x955e, 0x955f, + 0x955d, 0x9561, 0x9562, 0x9564, 0x9565, 0x9566, 0x9567, 0x9568, + 0x9569, 0x956a, 0x956b, 0x956c, 0x956f, 0x9571, 0x9572, 0x9573, + 0x953a, 0x77e7, 0x77ec, 0x96c9, 0x79d5, 0x79ed, 0x79e3, 0x79eb, + 0x7a06, 0x5d47, 0x7a03, 0x7a02, 0x7a1e, 0x7a14, + /* 0x70 */ + 0x7a39, 0x7a37, 0x7a51, 0x9ecf, 0x99a5, 0x7a70, 0x7688, 0x768e, + 0x7693, 0x7699, 0x76a4, 0x74de, 0x74e0, 0x752c, 0x9e20, 0x9e22, + 0x9e28, 0x9e29, 0x9e2a, 0x9e2b, 0x9e2c, 0x9e32, 0x9e31, 0x9e36, + 0x9e38, 0x9e37, 0x9e39, 0x9e3a, 0x9e3e, 0x9e41, 0x9e42, 0x9e44, + 0x9e46, 0x9e47, 0x9e48, 0x9e49, 0x9e4b, 0x9e4c, 0x9e4e, 0x9e51, + 0x9e55, 0x9e57, 0x9e5a, 0x9e5b, 0x9e5c, 0x9e5e, 0x9e63, 0x9e66, + 0x9e67, 0x9e68, 0x9e69, 0x9e6a, 0x9e6b, 0x9e6c, 0x9e71, 0x9e6d, + 0x9e73, 0x7592, 0x7594, 0x7596, 0x75a0, 0x759d, 0x75ac, 0x75a3, + 0x75b3, 0x75b4, 0x75b8, 0x75c4, 0x75b1, 0x75b0, 0x75c3, 0x75c2, + 0x75d6, 0x75cd, 0x75e3, 0x75e8, 0x75e6, 0x75e4, 0x75eb, 0x75e7, + 0x7603, 0x75f1, 0x75fc, 0x75ff, 0x7610, 0x7600, 0x7605, 0x760c, + 0x7617, 0x760a, 0x7625, 0x7618, 0x7615, 0x7619, + /* 0x71 */ + 0x761b, 0x763c, 0x7622, 0x7620, 0x7640, 0x762d, 0x7630, 0x763f, + 0x7635, 0x7643, 0x763e, 0x7633, 0x764d, 0x765e, 0x7654, 0x765c, + 0x7656, 0x766b, 0x766f, 0x7fca, 0x7ae6, 0x7a78, 0x7a79, 0x7a80, + 0x7a86, 0x7a88, 0x7a95, 0x7aa6, 0x7aa0, 0x7aac, 0x7aa8, 0x7aad, + 0x7ab3, 0x8864, 0x8869, 0x8872, 0x887d, 0x887f, 0x8882, 0x88a2, + 0x88c6, 0x88b7, 0x88bc, 0x88c9, 0x88e2, 0x88ce, 0x88e3, 0x88e5, + 0x88f1, 0x891a, 0x88fc, 0x88e8, 0x88fe, 0x88f0, 0x8921, 0x8919, + 0x8913, 0x891b, 0x890a, 0x8934, 0x892b, 0x8936, 0x8941, 0x8966, + 0x897b, 0x758b, 0x80e5, 0x76b2, 0x76b4, 0x77dc, 0x8012, 0x8014, + 0x8016, 0x801c, 0x8020, 0x8022, 0x8025, 0x8026, 0x8027, 0x8029, + 0x8028, 0x8031, 0x800b, 0x8035, 0x8043, 0x8046, 0x804d, 0x8052, + 0x8069, 0x8071, 0x8983, 0x9878, 0x9880, 0x9883, + /* 0x72 */ + 0x9889, 0x988c, 0x988d, 0x988f, 0x9894, 0x989a, 0x989b, 0x989e, + 0x989f, 0x98a1, 0x98a2, 0x98a5, 0x98a6, 0x864d, 0x8654, 0x866c, + 0x866e, 0x867f, 0x867a, 0x867c, 0x867b, 0x86a8, 0x868d, 0x868b, + 0x86ac, 0x869d, 0x86a7, 0x86a3, 0x86aa, 0x8693, 0x86a9, 0x86b6, + 0x86c4, 0x86b5, 0x86ce, 0x86b0, 0x86ba, 0x86b1, 0x86af, 0x86c9, + 0x86cf, 0x86b4, 0x86e9, 0x86f1, 0x86f2, 0x86ed, 0x86f3, 0x86d0, + 0x8713, 0x86de, 0x86f4, 0x86df, 0x86d8, 0x86d1, 0x8703, 0x8707, + 0x86f8, 0x8708, 0x870a, 0x870d, 0x8709, 0x8723, 0x873b, 0x871e, + 0x8725, 0x872e, 0x871a, 0x873e, 0x8748, 0x8734, 0x8731, 0x8729, + 0x8737, 0x873f, 0x8782, 0x8722, 0x877d, 0x877e, 0x877b, 0x8760, + 0x8770, 0x874c, 0x876e, 0x878b, 0x8753, 0x8763, 0x877c, 0x8764, + 0x8759, 0x8765, 0x8793, 0x87af, 0x87a8, 0x87d2, + /* 0x73 */ + 0x87c6, 0x8788, 0x8785, 0x87ad, 0x8797, 0x8783, 0x87ab, 0x87e5, + 0x87ac, 0x87b5, 0x87b3, 0x87cb, 0x87d3, 0x87bd, 0x87d1, 0x87c0, + 0x87ca, 0x87db, 0x87ea, 0x87e0, 0x87ee, 0x8816, 0x8813, 0x87fe, + 0x880a, 0x881b, 0x8821, 0x8839, 0x883c, 0x7f36, 0x7f42, 0x7f44, + 0x7f45, 0x8210, 0x7afa, 0x7afd, 0x7b08, 0x7b03, 0x7b04, 0x7b15, + 0x7b0a, 0x7b2b, 0x7b0f, 0x7b47, 0x7b38, 0x7b2a, 0x7b19, 0x7b2e, + 0x7b31, 0x7b20, 0x7b25, 0x7b24, 0x7b33, 0x7b3e, 0x7b1e, 0x7b58, + 0x7b5a, 0x7b45, 0x7b75, 0x7b4c, 0x7b5d, 0x7b60, 0x7b6e, 0x7b7b, + 0x7b62, 0x7b72, 0x7b71, 0x7b90, 0x7ba6, 0x7ba7, 0x7bb8, 0x7bac, + 0x7b9d, 0x7ba8, 0x7b85, 0x7baa, 0x7b9c, 0x7ba2, 0x7bab, 0x7bb4, + 0x7bd1, 0x7bc1, 0x7bcc, 0x7bdd, 0x7bda, 0x7be5, 0x7be6, 0x7bea, + 0x7c0c, 0x7bfe, 0x7bfc, 0x7c0f, 0x7c16, 0x7c0b, + /* 0x74 */ + 0x7c1f, 0x7c2a, 0x7c26, 0x7c38, 0x7c41, 0x7c40, 0x81fe, 0x8201, + 0x8202, 0x8204, 0x81ec, 0x8844, 0x8221, 0x8222, 0x8223, 0x822d, + 0x822f, 0x8228, 0x822b, 0x8238, 0x823b, 0x8233, 0x8234, 0x823e, + 0x8244, 0x8249, 0x824b, 0x824f, 0x825a, 0x825f, 0x8268, 0x887e, + 0x8885, 0x8888, 0x88d8, 0x88df, 0x895e, 0x7f9d, 0x7f9f, 0x7fa7, + 0x7faf, 0x7fb0, 0x7fb2, 0x7c7c, 0x6549, 0x7c91, 0x7c9d, 0x7c9c, + 0x7c9e, 0x7ca2, 0x7cb2, 0x7cbc, 0x7cbd, 0x7cc1, 0x7cc7, 0x7ccc, + 0x7ccd, 0x7cc8, 0x7cc5, 0x7cd7, 0x7ce8, 0x826e, 0x66a8, 0x7fbf, + 0x7fce, 0x7fd5, 0x7fe5, 0x7fe1, 0x7fe6, 0x7fe9, 0x7fee, 0x7ff3, + 0x7cf8, 0x7d77, 0x7da6, 0x7dae, 0x7e47, 0x7e9b, 0x9eb8, 0x9eb4, + 0x8d73, 0x8d84, 0x8d94, 0x8d91, 0x8db1, 0x8d67, 0x8d6d, 0x8c47, + 0x8c49, 0x914a, 0x9150, 0x914e, 0x914f, 0x9164, + /* 0x75 */ + 0x9162, 0x9161, 0x9170, 0x9169, 0x916f, 0x917d, 0x917e, 0x9172, + 0x9174, 0x9179, 0x918c, 0x9185, 0x9190, 0x918d, 0x9191, 0x91a2, + 0x91a3, 0x91aa, 0x91ad, 0x91ae, 0x91af, 0x91b5, 0x91b4, 0x91ba, + 0x8c55, 0x9e7e, 0x8db8, 0x8deb, 0x8e05, 0x8e59, 0x8e69, 0x8db5, + 0x8dbf, 0x8dbc, 0x8dba, 0x8dc4, 0x8dd6, 0x8dd7, 0x8dda, 0x8dde, + 0x8dce, 0x8dcf, 0x8ddb, 0x8dc6, 0x8dec, 0x8df7, 0x8df8, 0x8de3, + 0x8df9, 0x8dfb, 0x8de4, 0x8e09, 0x8dfd, 0x8e14, 0x8e1d, 0x8e1f, + 0x8e2c, 0x8e2e, 0x8e23, 0x8e2f, 0x8e3a, 0x8e40, 0x8e39, 0x8e35, + 0x8e3d, 0x8e31, 0x8e49, 0x8e41, 0x8e42, 0x8e51, 0x8e52, 0x8e4a, + 0x8e70, 0x8e76, 0x8e7c, 0x8e6f, 0x8e74, 0x8e85, 0x8e8f, 0x8e94, + 0x8e90, 0x8e9c, 0x8e9e, 0x8c78, 0x8c82, 0x8c8a, 0x8c85, 0x8c98, + 0x8c94, 0x659b, 0x89d6, 0x89de, 0x89da, 0x89dc, + /* 0x76 */ + 0x89e5, 0x89eb, 0x89ef, 0x8a3e, 0x8b26, 0x9753, 0x96e9, 0x96f3, + 0x96ef, 0x9706, 0x9701, 0x9708, 0x970f, 0x970e, 0x972a, 0x972d, + 0x9730, 0x973e, 0x9f80, 0x9f83, 0x9f85, 0x9f86, 0x9f87, 0x9f88, + 0x9f89, 0x9f8a, 0x9f8c, 0x9efe, 0x9f0b, 0x9f0d, 0x96b9, 0x96bc, + 0x96bd, 0x96ce, 0x96d2, 0x77bf, 0x96e0, 0x928e, 0x92ae, 0x92c8, + 0x933e, 0x936a, 0x93ca, 0x938f, 0x943e, 0x946b, 0x9c7f, 0x9c82, + 0x9c85, 0x9c86, 0x9c87, 0x9c88, 0x7a23, 0x9c8b, 0x9c8e, 0x9c90, + 0x9c91, 0x9c92, 0x9c94, 0x9c95, 0x9c9a, 0x9c9b, 0x9c9e, 0x9c9f, + 0x9ca0, 0x9ca1, 0x9ca2, 0x9ca3, 0x9ca5, 0x9ca6, 0x9ca7, 0x9ca8, + 0x9ca9, 0x9cab, 0x9cad, 0x9cae, 0x9cb0, 0x9cb1, 0x9cb2, 0x9cb3, + 0x9cb4, 0x9cb5, 0x9cb6, 0x9cb7, 0x9cba, 0x9cbb, 0x9cbc, 0x9cbd, + 0x9cc4, 0x9cc5, 0x9cc6, 0x9cc7, 0x9cca, 0x9ccb, + /* 0x77 */ + 0x9ccc, 0x9ccd, 0x9cce, 0x9ccf, 0x9cd0, 0x9cd3, 0x9cd4, 0x9cd5, + 0x9cd7, 0x9cd8, 0x9cd9, 0x9cdc, 0x9cdd, 0x9cdf, 0x9ce2, 0x977c, + 0x9785, 0x9791, 0x9792, 0x9794, 0x97af, 0x97ab, 0x97a3, 0x97b2, + 0x97b4, 0x9ab1, 0x9ab0, 0x9ab7, 0x9e58, 0x9ab6, 0x9aba, 0x9abc, + 0x9ac1, 0x9ac0, 0x9ac5, 0x9ac2, 0x9acb, 0x9acc, 0x9ad1, 0x9b45, + 0x9b43, 0x9b47, 0x9b49, 0x9b48, 0x9b4d, 0x9b51, 0x98e8, 0x990d, + 0x992e, 0x9955, 0x9954, 0x9adf, 0x9ae1, 0x9ae6, 0x9aef, 0x9aeb, + 0x9afb, 0x9aed, 0x9af9, 0x9b08, 0x9b0f, 0x9b13, 0x9b1f, 0x9b23, + 0x9ebd, 0x9ebe, 0x7e3b, 0x9e82, 0x9e87, 0x9e88, 0x9e8b, 0x9e92, + 0x93d6, 0x9e9d, 0x9e9f, 0x9edb, 0x9edc, 0x9edd, 0x9ee0, 0x9edf, + 0x9ee2, 0x9ee9, 0x9ee7, 0x9ee5, 0x9eea, 0x9eef, 0x9f22, 0x9f2c, + 0x9f2f, 0x9f39, 0x9f37, 0x9f3d, 0x9f3e, 0x9f44, +}; + +static int +gb2312_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x21 && c1 <= 0x29) || (c1 >= 0x30 && c1 <= 0x77)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + unsigned short wc = 0xfffd; + if (i < 1410) { + if (i < 831) + wc = gb2312_2uni_page21[i]; + } else { + if (i < 8178) + wc = gb2312_2uni_page30[i-1410]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short gb2312_2charset[7445] = { + 0x2168, 0x216c, 0x2127, 0x2163, 0x2140, 0x2141, 0x2824, 0x2822, + 0x2828, 0x2826, 0x283a, 0x282c, 0x282a, 0x2830, 0x282e, 0x2142, + 0x2834, 0x2832, 0x2839, 0x2821, 0x2825, 0x2827, 0x2829, 0x282d, + 0x2831, 0x2823, 0x282b, 0x282f, 0x2833, 0x2835, 0x2836, 0x2837, + 0x2838, 0x2126, 0x2125, 0x2621, 0x2622, 0x2623, 0x2624, 0x2625, + 0x2626, 0x2627, 0x2628, 0x2629, 0x262a, 0x262b, 0x262c, 0x262d, + 0x262e, 0x262f, 0x2630, 0x2631, 0x2632, 0x2633, 0x2634, 0x2635, + 0x2636, 0x2637, 0x2638, 0x2641, 0x2642, 0x2643, 0x2644, 0x2645, + 0x2646, 0x2647, 0x2648, 0x2649, 0x264a, 0x264b, 0x264c, 0x264d, + 0x264e, 0x264f, 0x2650, 0x2651, 0x2652, 0x2653, 0x2654, 0x2655, + 0x2656, 0x2657, 0x2658, 0x2727, 0x2721, 0x2722, 0x2723, 0x2724, + 0x2725, 0x2726, 0x2728, 0x2729, 0x272a, 0x272b, 0x272c, 0x272d, + 0x272e, 0x272f, 0x2730, 0x2731, 0x2732, 0x2733, 0x2734, 0x2735, + 0x2736, 0x2737, 0x2738, 0x2739, 0x273a, 0x273b, 0x273c, 0x273d, + 0x273e, 0x273f, 0x2740, 0x2741, 0x2751, 0x2752, 0x2753, 0x2754, + 0x2755, 0x2756, 0x2758, 0x2759, 0x275a, 0x275b, 0x275c, 0x275d, + 0x275e, 0x275f, 0x2760, 0x2761, 0x2762, 0x2763, 0x2764, 0x2765, + 0x2766, 0x2767, 0x2768, 0x2769, 0x276a, 0x276b, 0x276c, 0x276d, + 0x276e, 0x276f, 0x2770, 0x2771, 0x2757, 0x212a, 0x212c, 0x212e, + 0x212f, 0x2130, 0x2131, 0x212d, 0x216b, 0x2164, 0x2165, 0x2179, + 0x2166, 0x216d, 0x2271, 0x2272, 0x2273, 0x2274, 0x2275, 0x2276, + 0x2277, 0x2278, 0x2279, 0x227a, 0x227b, 0x227c, 0x217b, 0x217c, + 0x217a, 0x217d, 0x214a, 0x2147, 0x2146, 0x214c, 0x2158, 0x215e, + 0x214f, 0x214e, 0x2144, 0x2145, 0x2149, 0x2148, 0x2152, 0x2153, + 0x2160, 0x215f, 0x2143, 0x214b, 0x2157, 0x2156, 0x2155, 0x2159, + 0x2154, 0x215c, 0x215d, 0x215a, 0x215b, 0x2151, 0x214d, 0x2150, + 0x2259, 0x225a, 0x225b, 0x225c, 0x225d, 0x225e, 0x225f, 0x2260, + 0x2261, 0x2262, 0x2245, 0x2246, 0x2247, 0x2248, 0x2249, 0x224a, + 0x224b, 0x224c, 0x224d, 0x224e, 0x224f, 0x2250, 0x2251, 0x2252, + 0x2253, 0x2254, 0x2255, 0x2256, 0x2257, 0x2258, 0x2231, 0x2232, + 0x2233, 0x2234, 0x2235, 0x2236, 0x2237, 0x2238, 0x2239, 0x223a, + 0x223b, 0x223c, 0x223d, 0x223e, 0x223f, 0x2240, 0x2241, 0x2242, + 0x2243, 0x2244, 0x2924, 0x2925, 0x2926, 0x2927, 0x2928, 0x2929, + 0x292a, 0x292b, 0x292c, 0x292d, 0x292e, 0x292f, 0x2930, 0x2931, + 0x2932, 0x2933, 0x2934, 0x2935, 0x2936, 0x2937, 0x2938, 0x2939, + 0x293a, 0x293b, 0x293c, 0x293d, 0x293e, 0x293f, 0x2940, 0x2941, + 0x2942, 0x2943, 0x2944, 0x2945, 0x2946, 0x2947, 0x2948, 0x2949, + 0x294a, 0x294b, 0x294c, 0x294d, 0x294e, 0x294f, 0x2950, 0x2951, + 0x2952, 0x2953, 0x2954, 0x2955, 0x2956, 0x2957, 0x2958, 0x2959, + 0x295a, 0x295b, 0x295c, 0x295d, 0x295e, 0x295f, 0x2960, 0x2961, + 0x2962, 0x2963, 0x2964, 0x2965, 0x2966, 0x2967, 0x2968, 0x2969, + 0x296a, 0x296b, 0x296c, 0x296d, 0x296e, 0x296f, 0x2176, 0x2175, + 0x2178, 0x2177, 0x2174, 0x2173, 0x2170, 0x2172, 0x2171, 0x216f, + 0x216e, 0x2162, 0x2161, 0x2121, 0x2122, 0x2123, 0x2128, 0x2129, + 0x2134, 0x2135, 0x2136, 0x2137, 0x2138, 0x2139, 0x213a, 0x213b, + 0x213e, 0x213f, 0x217e, 0x2132, 0x2133, 0x213c, 0x213d, 0x2421, + 0x2422, 0x2423, 0x2424, 0x2425, 0x2426, 0x2427, 0x2428, 0x2429, + 0x242a, 0x242b, 0x242c, 0x242d, 0x242e, 0x242f, 0x2430, 0x2431, + 0x2432, 0x2433, 0x2434, 0x2435, 0x2436, 0x2437, 0x2438, 0x2439, + 0x243a, 0x243b, 0x243c, 0x243d, 0x243e, 0x243f, 0x2440, 0x2441, + 0x2442, 0x2443, 0x2444, 0x2445, 0x2446, 0x2447, 0x2448, 0x2449, + 0x244a, 0x244b, 0x244c, 0x244d, 0x244e, 0x244f, 0x2450, 0x2451, + 0x2452, 0x2453, 0x2454, 0x2455, 0x2456, 0x2457, 0x2458, 0x2459, + 0x245a, 0x245b, 0x245c, 0x245d, 0x245e, 0x245f, 0x2460, 0x2461, + 0x2462, 0x2463, 0x2464, 0x2465, 0x2466, 0x2467, 0x2468, 0x2469, + 0x246a, 0x246b, 0x246c, 0x246d, 0x246e, 0x246f, 0x2470, 0x2471, + 0x2472, 0x2473, 0x2521, 0x2522, 0x2523, 0x2524, 0x2525, 0x2526, + 0x2527, 0x2528, 0x2529, 0x252a, 0x252b, 0x252c, 0x252d, 0x252e, + 0x252f, 0x2530, 0x2531, 0x2532, 0x2533, 0x2534, 0x2535, 0x2536, + 0x2537, 0x2538, 0x2539, 0x253a, 0x253b, 0x253c, 0x253d, 0x253e, + 0x253f, 0x2540, 0x2541, 0x2542, 0x2543, 0x2544, 0x2545, 0x2546, + 0x2547, 0x2548, 0x2549, 0x254a, 0x254b, 0x254c, 0x254d, 0x254e, + 0x254f, 0x2550, 0x2551, 0x2552, 0x2553, 0x2554, 0x2555, 0x2556, + 0x2557, 0x2558, 0x2559, 0x255a, 0x255b, 0x255c, 0x255d, 0x255e, + 0x255f, 0x2560, 0x2561, 0x2562, 0x2563, 0x2564, 0x2565, 0x2566, + 0x2567, 0x2568, 0x2569, 0x256a, 0x256b, 0x256c, 0x256d, 0x256e, + 0x256f, 0x2570, 0x2571, 0x2572, 0x2573, 0x2574, 0x2575, 0x2576, + 0x2124, 0x2845, 0x2846, 0x2847, 0x2848, 0x2849, 0x284a, 0x284b, + 0x284c, 0x284d, 0x284e, 0x284f, 0x2850, 0x2851, 0x2852, 0x2853, + 0x2854, 0x2855, 0x2856, 0x2857, 0x2858, 0x2859, 0x285a, 0x285b, + 0x285c, 0x285d, 0x285e, 0x285f, 0x2860, 0x2861, 0x2862, 0x2863, + 0x2864, 0x2865, 0x2866, 0x2867, 0x2868, 0x2869, 0x2265, 0x2266, + 0x2267, 0x2268, 0x2269, 0x226a, 0x226b, 0x226c, 0x226d, 0x226e, + 0x523b, 0x3621, 0x465f, 0x4d72, 0x5549, 0x487d, 0x494f, 0x4f42, + 0x5822, 0x323b, 0x536b, 0x5824, 0x3373, 0x5728, 0x4752, 0x5827, + 0x4a40, 0x4770, 0x317b, 0x5235, 0x3454, 0x362b, 0x4b3f, 0x5829, + 0x362a, 0x413d, 0x514f, 0x4925, 0x582d, 0x3876, 0x513e, 0x635c, + 0x5650, 0x3761, 0x342e, 0x4159, 0x583c, 0x4d68, 0x3524, 0x4e2a, + 0x5677, 0x4076, 0x3e59, 0x582f, 0x444b, 0x3e43, 0x5831, 0x4334, + 0x5265, 0x562e, 0x4e5a, 0x5527, 0x3a75, 0x3726, 0x4056, 0x4639, + 0x4552, 0x4747, 0x3954, 0x334b, 0x5252, 0x583f, 0x3e45, 0x4672, + 0x5232, 0x4f30, 0x4f67, 0x4a69, 0x5840, 0x4272, 0x4252, 0x4869, + 0x472c, 0x414b, 0x5368, 0x5579, 0x4a42, 0x367e, 0x5821, 0x535a, + 0x3f77, 0x5446, 0x3b25, 0x5841, 0x4e65, 0x3e2e, 0x5828, 0x5147, + 0x5029, 0x583d, 0x596f, 0x4d76, 0x3f3a, 0x3d3b, 0x3a25, 0x5260, + 0x327a, 0x3a60, 0x4436, 0x4f6d, 0x3e29, 0x4d24, 0x4141, 0x4757, + 0x5971, 0x5974, 0x484b, 0x5869, 0x525a, 0x4a32, 0x484a, 0x586c, + 0x586a, 0x5846, 0x3d76, 0x464d, 0x3370, 0x586b, 0x3d71, 0x3d69, + 0x4854, 0x3453, 0x4258, 0x3256, 0x5750, 0x4a4b, 0x4b7b, 0x554c, + 0x3836, 0x4f49, 0x595a, 0x5870, 0x472a, 0x586e, 0x347a, 0x416e, + 0x5254, 0x586d, 0x5247, 0x586f, 0x4347, 0x5176, 0x5659, 0x5872, + 0x5875, 0x3c7e, 0x3c5b, 0x484e, 0x375d, 0x3742, 0x4673, 0x5878, + 0x5241, 0x4e69, 0x3c3f, 0x377c, 0x3725, 0x505d, 0x565a, 0x5345, + 0x3b6f, 0x3b61, 0x5871, 0x4921, 0x4e30, 0x342b, 0x5873, 0x494b, + 0x5876, 0x4257, 0x5877, 0x4e31, 0x5879, 0x322e, 0x3940, 0x5923, + 0x3069, 0x4166, 0x496c, 0x4b45, 0x4b46, 0x5924, 0x3568, 0x352b, + 0x4e3b, 0x354d, 0x5721, 0x5774, 0x5353, 0x4c65, 0x3a4e, 0x5922, + 0x595c, 0x5360, 0x587d, 0x3770, 0x5777, 0x587e, 0x587a, 0x5921, + 0x4463, 0x5336, 0x5874, 0x595d, 0x587b, 0x4565, 0x4050, 0x5170, + 0x305b, 0x3c51, 0x5926, 0x5925, 0x592c, 0x592e, 0x592b, 0x4a39, + 0x5929, 0x5636, 0x335e, 0x5928, 0x407d, 0x4a4c, 0x592a, 0x5927, + 0x5930, 0x3631, 0x3929, 0x5240, 0x4f40, 0x4242, 0x3d44, 0x556c, + 0x3260, 0x4748, 0x3f6b, 0x592d, 0x592f, 0x4e6a, 0x3a6e, 0x4756, + 0x3163, 0x3459, 0x366d, 0x5934, 0x3f21, 0x595e, 0x474e, 0x407e, + 0x5938, 0x4b57, 0x377d, 0x5935, 0x5937, 0x3123, 0x5361, 0x5939, + 0x5045, 0x5936, 0x5931, 0x5932, 0x4129, 0x5933, 0x3c73, 0x505e, + 0x3829, 0x3e63, 0x593d, 0x593a, 0x3033, 0x5942, 0x5944, 0x3136, + 0x593f, 0x3539, 0x3e73, 0x4c48, 0x3a72, 0x5250, 0x5943, 0x3d68, + 0x332b, 0x5945, 0x3e6b, 0x5946, 0x593b, 0x445f, 0x593e, 0x5941, + 0x5940, 0x552e, 0x5635, 0x4763, 0x5948, 0x3c59, 0x594a, 0x593c, + 0x594b, 0x462b, 0x5949, 0x5776, 0x4d23, 0x3d21, 0x594c, 0x453c, + 0x4d35, 0x594d, 0x5947, 0x3325, 0x3f7e, 0x3835, 0x407c, 0x3078, + 0x3476, 0x594e, 0x594f, 0x3422, 0x5950, 0x345f, 0x3041, 0x5951, + 0x4935, 0x4f71, 0x5952, 0x4145, 0x5956, 0x492e, 0x5955, 0x5954, + 0x5957, 0x4b5b, 0x3d29, 0x4627, 0x5953, 0x5958, 0x5959, 0x4865, + 0x405c, 0x3679, 0x5823, 0x544a, 0x542a, 0x5056, 0x3364, 0x5557, + 0x4f48, 0x3962, 0x3f4b, 0x4362, 0x3652, 0x4d43, 0x596e, 0x5970, + 0x3533, 0x3635, 0x3e24, 0x486b, 0x482b, 0x304b, 0x392b, 0x4179, + 0x5962, 0x403c, 0x3932, 0x3958, 0x504b, 0x3178, 0x4664, 0x3e5f, + 0x3564, 0x5748, 0x5178, 0x3c66, 0x4a5e, 0x3c3d, 0x5966, 0x5867, + 0x445a, 0x3854, 0x483d, 0x3261, 0x5459, 0x4330, 0x4361, 0x5a22, + 0x485f, 0x5034, 0x3e7c, 0x4529, 0x395a, 0x5a23, 0x5429, 0x5a24, + 0x597b, 0x362c, 0x376b, 0x3179, 0x597c, 0x3365, 0x3e76, 0x3f76, + 0x5231, 0x4064, 0x3633, 0x597e, 0x597d, 0x3e3b, 0x4660, 0x573c, + 0x5a21, 0x4139, 0x3572, 0x4168, 0x3c75, 0x3455, 0x415d, 0x447d, + 0x3c38, 0x3732, 0x376f, 0x596c, 0x463e, 0x3f2d, 0x3b4b, 0x354a, + 0x5b49, 0x5057, 0x4d39, 0x303c, 0x3376, 0x3b77, 0x5b4a, 0x3a2f, + 0x5464, 0x3536, 0x3573, 0x5856, 0x4850, 0x3756, 0x4750, 0x5857, + 0x3f2f, 0x5b3b, 0x5858, 0x504c, 0x3b2e, 0x6b3e, 0x4150, 0x4175, + 0x5472, 0x3855, 0x3434, 0x3375, 0x493e, 0x4550, 0x4559, 0x407b, + 0x3170, 0x5859, 0x394e, 0x353d, 0x585a, 0x5646, 0x4b22, 0x482f, + 0x4932, 0x344c, 0x3f4c, 0x3974, 0x585b, 0x585c, 0x3667, 0x3c41, + 0x4c6a, 0x4f77, 0x585d, 0x4730, 0x3950, 0x3d23, 0x4c5e, 0x464a, + 0x5860, 0x585e, 0x585f, 0x307e, 0x3e67, 0x4a23, 0x3c74, 0x3831, + 0x386e, 0x5862, 0x3d4b, 0x5864, 0x5863, 0x457c, 0x5865, 0x5866, + 0x4126, 0x4830, 0x306c, 0x3926, 0x3c53, 0x4e71, 0x5b3d, 0x4153, + 0x362f, 0x567a, 0x452c, 0x3d59, 0x5b3e, 0x5b3f, 0x4078, 0x3e22, + 0x404d, 0x5b40, 0x4a46, 0x322a, 0x5342, 0x4363, 0x512b, 0x5b42, + 0x4055, 0x5b43, 0x3f31, 0x443c, 0x475a, 0x5b44, 0x5968, 0x4957, + 0x3934, 0x4e70, 0x5448, 0x307c, 0x3452, 0x5059, 0x5969, 0x5e4b, + 0x596b, 0x5830, 0x3b2f, 0x3131, 0x3357, 0x584e, 0x5451, 0x3d33, + 0x3f6f, 0x4f3b, 0x5850, 0x374b, 0x5851, 0x4625, 0x4778, 0x523d, + 0x5852, 0x4464, 0x4a2e, 0x4727, 0x5826, 0x497d, 0x4e67, 0x3b5c, + 0x306b, 0x3b2a, 0x502d, 0x3130, 0x5764, 0x573f, 0x3525, 0x4274, + 0x444f, 0x3229, 0x3237, 0x3165, 0x5f32, 0x553c, 0x3f28, 0x422c, + 0x5855, 0x4231, 0x5854, 0x4e54, 0x5a60, 0x4e40, 0x5834, 0x432e, + 0x5321, 0x4e23, 0x3c34, 0x4834, 0x4251, 0x3e6d, 0x5036, 0x5a61, + 0x4764, 0x3327, 0x3672, 0x4c7c, 0x407a, 0x4077, 0x5139, 0x5161, + 0x5847, 0x325e, 0x4065, 0x3a71, 0x5848, 0x542d, 0x4f61, 0x5849, + 0x584a, 0x4f43, 0x3378, 0x3e47, 0x584b, 0x5b4c, 0x4825, 0x4f58, + 0x487e, 0x324e, 0x5356, 0x3266, 0x3c30, 0x5351, 0x4b2b, 0x3734, + 0x3722, 0x4a65, 0x4821, 0x4a5c, 0x3164, 0x5070, 0x4551, 0x5b45, + 0x357e, 0x3f5a, 0x3945, 0x3e64, 0x416d, 0x5f36, 0x5f35, 0x563b, + 0x3d50, 0x5559, 0x3048, 0x3623, 0x3f49, 0x4c28, 0x5f33, 0x4a37, + 0x5352, 0x584f, 0x5236, 0x3a45, 0x4b3e, 0x4c3e, 0x5f37, 0x3570, + 0x5f34, 0x5375, 0x3354, 0x3877, 0x5f3a, 0x3a4f, 0x3c2a, 0x3575, + 0x4d2c, 0x437b, 0x3a73, 0x4074, 0x4d42, 0x4f72, 0x5f38, 0x4f45, + 0x4240, 0x5f39, 0x4270, 0x3e7d, 0x415f, 0x4d4c, 0x5277, 0x374d, + 0x5f41, 0x5f44, 0x3771, 0x3049, 0x3656, 0x3754, 0x3a2c, 0x4c7d, + 0x3f54, 0x4b31, 0x4674, 0x5628, 0x5f45, 0x4e62, 0x3333, 0x4e7c, + 0x3435, 0x4e47, 0x3a70, 0x4e61, 0x513d, 0x5f40, 0x3474, 0x334a, + 0x3866, 0x5f3b, 0x4445, 0x5f3c, 0x5f3d, 0x5f3e, 0x453b, 0x5f3f, + 0x5f42, 0x5431, 0x5f43, 0x473a, 0x4e58, 0x4458, 0x5f4a, 0x5f4f, + 0x565c, 0x5f49, 0x5f5a, 0x4e36, 0x3a47, 0x5f4e, 0x5f48, 0x455e, + 0x496b, 0x3a74, 0x437c, 0x3e57, 0x5f46, 0x5f4d, 0x4558, 0x5526, + 0x3a4d, 0x3e4c, 0x533d, 0x3840, 0x5664, 0x5f47, 0x393e, 0x3f27, + 0x417c, 0x5f4b, 0x5f4c, 0x5f50, 0x5f5b, 0x5f65, 0x5f57, 0x5f56, + 0x5749, 0x5f63, 0x5f64, 0x656b, 0x5227, 0x5f52, 0x3f29, 0x545b, + 0x3f48, 0x5f54, 0x4f4c, 0x5f5d, 0x514a, 0x5f5e, 0x3027, 0x4637, + 0x5f53, 0x3a65, 0x365f, 0x4d5b, 0x397e, 0x5455, 0x5f5f, 0x4f6c, + 0x3025, 0x5f67, 0x5f51, 0x5146, 0x5f55, 0x5f58, 0x5f59, 0x5f5c, + 0x3b29, 0x5f60, 0x5f61, 0x5f62, 0x5f66, 0x5f68, 0x5334, 0x3867, + 0x4536, 0x5f6a, 0x495a, 0x4128, 0x4444, 0x3f5e, 0x4f78, 0x555c, + 0x5f6e, 0x3238, 0x3a5f, 0x5f6c, 0x5b41, 0x5164, 0x4b74, 0x343d, + 0x3026, 0x5f71, 0x4c46, 0x5f72, 0x5f6d, 0x5f69, 0x5f6b, 0x5f6f, + 0x5f70, 0x3b3d, 0x5f73, 0x5f74, 0x3b23, 0x4a5b, 0x4e28, 0x6027, + 0x332a, 0x6026, 0x6021, 0x5f7e, 0x4d59, 0x5f7c, 0x5f7a, 0x3f50, + 0x5744, 0x494c, 0x5f78, 0x3021, 0x5f7d, 0x5f7b, 0x6022, 0x6028, + 0x3748, 0x4621, 0x4936, 0x4032, 0x5f75, 0x453e, 0x5844, 0x5f79, + 0x4476, 0x6023, 0x6024, 0x6025, 0x5025, 0x6034, 0x4c64, 0x6031, + 0x3f26, 0x602f, 0x4e39, 0x602b, 0x4946, 0x402e, 0x602e, 0x3a6d, + 0x3a30, 0x6029, 0x5f76, 0x6033, 0x6038, 0x342d, 0x6039, 0x4f32, + 0x3a48, 0x6030, 0x507a, 0x602c, 0x547b, 0x5f77, 0x4567, 0x602d, + 0x5377, 0x6036, 0x6037, 0x6044, 0x5061, 0x603c, 0x6049, 0x604a, + 0x603e, 0x602a, 0x4924, 0x6041, 0x6032, 0x4a48, 0x6043, 0x6035, + 0x4e4b, 0x4b43, 0x604d, 0x6046, 0x6042, 0x604b, 0x603a, 0x603f, + 0x6040, 0x6045, 0x6047, 0x6048, 0x604c, 0x603b, 0x4b54, 0x6055, + 0x6056, 0x6052, 0x6050, 0x3c4e, 0x6051, 0x3842, 0x5845, 0x506a, + 0x426f, 0x604f, 0x603d, 0x6054, 0x6053, 0x6057, 0x605c, 0x6058, + 0x5676, 0x3330, 0x576c, 0x4b3b, 0x605a, 0x4e7b, 0x3a59, 0x6061, + 0x605d, 0x522d, 0x6062, 0x605b, 0x6059, 0x605f, 0x6060, 0x605e, + 0x6064, 0x4677, 0x582c, 0x546b, 0x6066, 0x4a49, 0x6065, 0x3841, + 0x6067, 0x6068, 0x6069, 0x6063, 0x3a3f, 0x4c67, 0x606a, 0x4f79, + 0x606b, 0x4842, 0x3d40, 0x4452, 0x606c, 0x606d, 0x4774, 0x4b44, + 0x606e, 0x3b58, 0x5836, 0x5272, 0x606f, 0x4d45, 0x365a, 0x6071, + 0x5430, 0x4027, 0x3451, 0x4e27, 0x6070, 0x6072, 0x394c, 0x397a, + 0x4d3c, 0x6073, 0x4654, 0x6074, 0x5432, 0x4826, 0x6076, 0x6075, + 0x6077, 0x4d41, 0x4a25, 0x545a, 0x5b57, 0x5b59, 0x5b58, 0x3967, + 0x5b5c, 0x5b5d, 0x3558, 0x5b5a, 0x5b5b, 0x3321, 0x5b5f, 0x3b78, + 0x5637, 0x5b60, 0x3e79, 0x373b, 0x5b50, 0x4c2e, 0x3f32, 0x3b35, + 0x5778, 0x3f53, 0x3f69, 0x3c61, 0x4c33, 0x5b5e, 0x3053, 0x4e6b, + 0x3758, 0x5739, 0x4642, 0x4024, 0x4c39, 0x5b67, 0x5b61, 0x463a, + 0x5b63, 0x5b68, 0x4577, 0x5b6a, 0x5b69, 0x3f40, 0x5b66, 0x5b65, + 0x3439, 0x402c, 0x4222, 0x5b62, 0x5b64, 0x504d, 0x5b6d, 0x405d, + 0x5b72, 0x3662, 0x5b73, 0x5b52, 0x3938, 0x542b, 0x5b6c, 0x3f51, + 0x5b70, 0x5b51, 0x3566, 0x5b6b, 0x3f65, 0x5b6e, 0x5b71, 0x5b79, + 0x3921, 0x3023, 0x4271, 0x3347, 0x5b6f, 0x5b78, 0x4652, 0x5b74, + 0x5b75, 0x5b77, 0x5b76, 0x5b7e, 0x5372, 0x323a, 0x5b7d, 0x5c24, + 0x5b7b, 0x5b7a, 0x5b7c, 0x4560, 0x3b79, 0x5c23, 0x5c25, 0x4c43, + 0x3651, 0x5d40, 0x5c21, 0x5c22, 0x4735, 0x3669, 0x5c27, 0x5c26, + 0x5c29, 0x3124, 0x354c, 0x3f30, 0x515f, 0x3642, 0x5c28, 0x4b7a, + 0x6b73, 0x4b5c, 0x4b7e, 0x4c41, 0x487b, 0x5c2a, 0x4c6e, 0x5c2b, + 0x5b53, 0x5c2f, 0x5c2c, 0x3e33, 0x4a7b, 0x5c2d, 0x494a, 0x4439, + 0x473d, 0x5c2e, 0x5476, 0x5066, 0x442b, 0x3655, 0x5b54, 0x315a, + 0x5b55, 0x5b56, 0x3a3e, 0x4840, 0x4a3f, 0x4849, 0x5733, 0x4979, + 0x3f47, 0x3a78, 0x523c, 0x623a, 0x3426, 0x3138, 0x3834, 0x4f44, + 0x5967, 0x4f26, 0x4d62, 0x596d, 0x3660, 0x5239, 0x393b, 0x6239, + 0x6237, 0x3473, 0x4c6c, 0x4c2b, 0x3772, 0x5832, 0x516b, 0x3a3b, + 0x4a27, 0x4d37, 0x5244, 0x3f64, 0x3c50, 0x3661, 0x5e45, 0x5e46, + 0x5b3c, 0x5159, 0x4666, 0x444e, 0x376e, 0x375c, 0x3f7c, 0x5760, + 0x4675, 0x313c, 0x5e48, 0x3d31, 0x4c57, 0x5e4a, 0x5e49, 0x356c, + 0x495d, 0x3042, 0x452e, 0x452b, 0x444c, 0x3c69, 0x4b7d, 0x3a43, + 0x6579, 0x4867, 0x657a, 0x4d7d, 0x5731, 0x383e, 0x4268, 0x4851, + 0x657b, 0x364a, 0x3c4b, 0x517d, 0x6621, 0x436e, 0x6624, 0x657e, + 0x6625, 0x4d57, 0x3741, 0x657c, 0x657d, 0x6623, 0x445d, 0x6628, + 0x6627, 0x4343, 0x465e, 0x662a, 0x4437, 0x6622, 0x4a3c, 0x3d63, + 0x3943, 0x6626, 0x5055, 0x4e2f, 0x6629, 0x6630, 0x5226, 0x3d2a, + 0x662d, 0x662f, 0x4051, 0x524c, 0x3c27, 0x6631, 0x5276, 0x574b, + 0x4d7e, 0x4d5e, 0x4226, 0x662b, 0x662c, 0x3d3f, 0x662e, 0x6633, + 0x6632, 0x6636, 0x6638, 0x446f, 0x4448, 0x3e6a, 0x496f, 0x6637, + 0x3670, 0x4364, 0x5369, 0x6634, 0x6635, 0x4822, 0x663d, 0x6639, + 0x4645, 0x4d71, 0x663b, 0x663c, 0x3b69, 0x663e, 0x663a, 0x4037, + 0x5324, 0x663f, 0x4974, 0x6643, 0x6644, 0x5076, 0x433d, 0x4344, + 0x6642, 0x6641, 0x6647, 0x4f31, 0x6b74, 0x664a, 0x6645, 0x3c5e, + 0x4929, 0x3c35, 0x4f53, 0x6648, 0x6649, 0x664e, 0x6650, 0x6651, + 0x664b, 0x3555, 0x664c, 0x664f, 0x445b, 0x6646, 0x664d, 0x6652, + 0x6654, 0x6653, 0x6655, 0x5978, 0x6656, 0x6657, 0x5753, 0x665d, + 0x665e, 0x3f57, 0x5450, 0x5756, 0x3466, 0x4b6f, 0x665a, 0x5843, + 0x574e, 0x5022, 0x434f, 0x665f, 0x3c3e, 0x3942, 0x665b, 0x5127, + 0x3a22, 0x424f, 0x582b, 0x4a6b, 0x656e, 0x665c, 0x3775, 0x4866, + 0x4475, 0x6532, 0x447e, 0x4b7c, 0x6533, 0x552c, 0x536e, 0x4a58, + 0x3032, 0x4b4e, 0x4d6a, 0x3a6a, 0x6535, 0x6534, 0x575a, 0x3959, + 0x5666, 0x3628, 0x4d70, 0x524b, 0x3126, 0x4a35, 0x3368, 0x4973, + 0x3f4d, 0x507b, 0x4a52, 0x6536, 0x3b42, 0x4f5c, 0x392c, 0x5457, + 0x3a26, 0x5167, 0x4f7c, 0x3c52, 0x6537, 0x485d, 0x3f6d, 0x3176, + 0x4b5e, 0x3c45, 0x3c44, 0x527a, 0x435c, 0x3f5c, 0x383b, 0x4342, + 0x3a2e, 0x5422, 0x475e, 0x442f, 0x326c, 0x3951, 0x653b, 0x4148, + 0x552f, 0x653c, 0x653e, 0x3467, 0x3654, 0x4b42, 0x5130, 0x353c, + 0x4a59, 0x3762, 0x4964, 0x3d2b, 0x4e3e, 0x5770, 0x5021, 0x4959, + 0x367b, 0x6658, 0x3c62, 0x333e, 0x4950, 0x6659, 0x3322, 0x5e4c, + 0x5348, 0x5e4d, 0x5222, 0x5e4e, 0x3e4d, 0x5e4f, 0x4a2c, 0x527c, + 0x335f, 0x656a, 0x4461, 0x3e21, 0x4e32, 0x4472, 0x3e56, 0x4628, + 0x3263, 0x3e53, 0x477c, 0x4c6b, 0x3d6c, 0x4e5d, 0x4a3a, 0x4641, + 0x656c, 0x503c, 0x5539, 0x656d, 0x4a74, 0x4d40, 0x4245, 0x656f, + 0x4244, 0x6570, 0x6578, 0x4d4d, 0x493d, 0x5259, 0x6128, 0x536c, + 0x4b6a, 0x4671, 0x612c, 0x6127, 0x6129, 0x612a, 0x612f, 0x326d, + 0x612b, 0x385a, 0x612d, 0x612e, 0x6130, 0x353a, 0x6131, 0x6133, + 0x6138, 0x5152, 0x6136, 0x6135, 0x416b, 0x6137, 0x5440, 0x6132, + 0x613a, 0x3036, 0x6134, 0x3f79, 0x6139, 0x613b, 0x613e, 0x613c, + 0x5645, 0x4f3f, 0x613d, 0x613f, 0x424d, 0x366b, 0x5378, 0x474d, + 0x3765, 0x3e7e, 0x6140, 0x6141, 0x6147, 0x3367, 0x4669, 0x345e, + 0x5142, 0x6148, 0x6146, 0x6145, 0x6143, 0x6142, 0x3140, 0x5538, + 0x6144, 0x614b, 0x614c, 0x614a, 0x6f7a, 0x6153, 0x6152, 0x4736, + 0x6149, 0x614e, 0x6150, 0x6154, 0x6151, 0x614d, 0x614f, 0x6155, + 0x6156, 0x6157, 0x6158, 0x615a, 0x615b, 0x4e21, 0x675d, 0x3428, + 0x565d, 0x5132, 0x3332, 0x3924, 0x5773, 0x4749, 0x3e5e, 0x392e, + 0x4e57, 0x326e, 0x5b4f, 0x3c3a, 0x5251, 0x4b48, 0x304d, 0x4f6f, + 0x5963, 0x3d6d, 0x3152, 0x4a50, 0x323c, 0x4b27, 0x372b, 0x4a26, + 0x4f23, 0x6078, 0x554a, 0x607b, 0x607a, 0x4541, 0x4c7b, 0x4131, + 0x6079, 0x5663, 0x322f, 0x5644, 0x355b, 0x3478, 0x5621, 0x4f2f, + 0x306f, 0x607c, 0x6121, 0x3323, 0x607d, 0x607e, 0x4331, 0x435d, + 0x6122, 0x3779, 0x3b4f, 0x6123, 0x443b, 0x6124, 0x6125, 0x6126, + 0x3431, 0x3849, 0x463d, 0x446a, 0x3222, 0x5052, 0x675b, 0x3b43, + 0x5357, 0x5344, 0x3963, 0x624f, 0x572f, 0x476c, 0x3153, 0x3432, + 0x6251, 0x5072, 0x422e, 0x6250, 0x3f62, 0x5326, 0x3557, 0x6252, + 0x356a, 0x436d, 0x387d, 0x382e, 0x4553, 0x374f, 0x6254, 0x6253, + 0x3648, 0x5779, 0x4d25, 0x6258, 0x6256, 0x4a7c, 0x3f35, 0x5339, + 0x6255, 0x6257, 0x412e, 0x4048, 0x625b, 0x625a, 0x402a, 0x414e, + 0x625c, 0x625d, 0x625e, 0x5b48, 0x5153, 0x4d22, 0x3d28, 0x5e43, + 0x5825, 0x3f2a, 0x5b4d, 0x526c, 0x467a, 0x452a, 0x5e44, 0x3157, + 0x5f2e, 0x4a3d, 0x5f31, 0x392d, 0x527d, 0x3825, 0x3a6b, 0x335a, + 0x355c, 0x5545, 0x4356, 0x4f52, 0x3b21, 0x6573, 0x6572, 0x6574, + 0x4d64, 0x4875, 0x352f, 0x473f, 0x6576, 0x6c30, 0x6566, 0x3969, + 0x3531, 0x423c, 0x6568, 0x6567, 0x6569, 0x524d, 0x616a, 0x504e, + 0x4d2e, 0x5165, 0x324a, 0x316b, 0x3172, 0x456d, 0x5543, 0x5330, + 0x615c, 0x615d, 0x525b, 0x3339, 0x314b, 0x4d79, 0x5577, 0x615e, + 0x3e36, 0x347d, 0x615f, 0x3a5c, 0x6160, 0x3b32, 0x4249, 0x6161, + 0x506c, 0x4d3d, 0x6162, 0x3543, 0x4547, 0x6163, 0x6164, 0x5379, + 0x6165, 0x512d, 0x6166, 0x4e22, 0x6167, 0x3542, 0x6168, 0x3b55, + 0x5044, 0x6260, 0x3158, 0x5264, 0x6261, 0x3c49, 0x484c, 0x6263, + 0x6c7e, 0x6c7d, 0x5f2f, 0x6262, 0x563e, 0x4d7c, 0x4326, 0x6343, + 0x5652, 0x6267, 0x6268, 0x5347, 0x626c, 0x3f6c, 0x626d, 0x6265, + 0x3340, 0x446e, 0x626e, 0x5043, 0x3a76, 0x6269, 0x375e, 0x3b33, + 0x4c2c, 0x4b4b, 0x6264, 0x6266, 0x626a, 0x626b, 0x6277, 0x6274, + 0x5475, 0x6273, 0x452d, 0x557a, 0x4542, 0x3240, 0x626f, 0x6272, + 0x412f, 0x4b3c, 0x3521, 0x6279, 0x3c31, 0x6271, 0x5054, 0x5439, + 0x6275, 0x3956, 0x6276, 0x4753, 0x6270, 0x575c, 0x6d21, 0x6278, + 0x6d25, 0x627e, 0x4a51, 0x4135, 0x3b50, 0x3f56, 0x3a63, 0x4b21, + 0x6d26, 0x6d23, 0x6d22, 0x3b56, 0x6d27, 0x5074, 0x6d24, 0x3a5e, + 0x3677, 0x6321, 0x3632, 0x4c71, 0x3927, 0x4f22, 0x4721, 0x3f52, + 0x3671, 0x627a, 0x627b, 0x627d, 0x627c, 0x4455, 0x6322, 0x5341, + 0x6327, 0x4744, 0x4f24, 0x6329, 0x3a37, 0x6328, 0x3b5a, 0x6323, + 0x6324, 0x632a, 0x6326, 0x4e72, 0x5346, 0x3b3c, 0x5443, 0x447a, + 0x6d28, 0x507c, 0x6325, 0x4375, 0x632d, 0x312f, 0x6332, 0x3c42, + 0x632c, 0x353f, 0x4769, 0x6330, 0x3e2a, 0x4d6f, 0x3b73, 0x4c68, + 0x632f, 0x6331, 0x4f27, 0x632e, 0x4e29, 0x3b5d, 0x356b, 0x3e65, + 0x3252, 0x334d, 0x3139, 0x632b, 0x3251, 0x352c, 0x395f, 0x3668, + 0x4f6b, 0x6337, 0x3b4c, 0x4847, 0x504a, 0x6338, 0x336e, 0x6d29, + 0x537a, 0x5364, 0x6d2a, 0x6339, 0x5262, 0x6335, 0x535e, 0x3850, + 0x6333, 0x6336, 0x375f, 0x6334, 0x4022, 0x633a, 0x5438, 0x3448, + 0x633b, 0x3b45, 0x4977, 0x4965, 0x443d, 0x6d2b, 0x427d, 0x3b5b, + 0x3f2e, 0x4e3f, 0x633c, 0x3f36, 0x316f, 0x5477, 0x633e, 0x6d2d, + 0x633f, 0x3a29, 0x6d2c, 0x633d, 0x6340, 0x3a36, 0x362e, 0x5038, + 0x3043, 0x6d2e, 0x6d2f, 0x4041, 0x6341, 0x4533, 0x6342, 0x5c32, + 0x6d30, 0x386a, 0x4e6c, 0x6a27, 0x5067, 0x4a79, 0x4856, 0x4f37, + 0x3349, 0x4e52, 0x3d64, 0x635e, 0x3b72, 0x6a28, 0x553d, 0x465d, + 0x6a29, 0x6a2a, 0x6a2c, 0x6a2b, 0x6a2e, 0x6a2d, 0x3d58, 0x6a2f, + 0x423e, 0x3441, 0x3477, 0x3b27, 0x6c66, 0x6c65, 0x373f, 0x4b79, + 0x3162, 0x6c67, 0x4948, 0x6c68, 0x6c69, 0x4a56, 0x5e50, 0x3245, + 0x547a, 0x464b, 0x3047, 0x3472, 0x4853, 0x4d50, 0x3f38, 0x3f5b, + 0x4724, 0x5634, 0x4029, 0x5e51, 0x4928, 0x516f, 0x4524, 0x3067, + 0x3336, 0x4845, 0x3062, 0x3776, 0x457a, 0x3673, 0x5552, 0x3350, + 0x3c3c, 0x332d, 0x3e71, 0x3051, 0x5256, 0x4a63, 0x5725, 0x4d36, + 0x3636, 0x3f39, 0x555b, 0x3827, 0x4557, 0x5e52, 0x3f59, 0x4255, + 0x4740, 0x3b24, 0x3128, 0x456a, 0x457b, 0x4c27, 0x3127, 0x3556, + 0x4428, 0x5e53, 0x513a, 0x3369, 0x4372, 0x3777, 0x5674, 0x3523, + 0x3270, 0x4434, 0x4469, 0x402d, 0x5e54, 0x3068, 0x4544, 0x4160, + 0x3955, 0x3e5c, 0x4d58, 0x304e, 0x4d4f, 0x5e56, 0x3e50, 0x573e, + 0x5e55, 0x5550, 0x305d, 0x4462, 0x4223, 0x3c70, 0x5335, 0x4039, + 0x4521, 0x3226, 0x5471, 0x4028, 0x4a43, 0x5e57, 0x557c, 0x3930, + 0x482d, 0x4b29, 0x5e59, 0x3f3d, 0x4634, 0x5727, 0x4a30, 0x4443, + 0x3356, 0x3952, 0x5638, 0x6a7c, 0x3034, 0x3f66, 0x4c74, 0x4d5a, + 0x563f, 0x424e, 0x4e4e, 0x4c22, 0x502e, 0x4453, 0x3532, 0x5e58, + 0x5575, 0x3c37, 0x3b53, 0x3024, 0x4532, 0x346c, 0x5571, 0x6a7d, + 0x5e5a, 0x4d26, 0x4d6c, 0x4e66, 0x5e5c, 0x4d31, 0x4026, 0x573d, + 0x5e5b, 0x3046, 0x3a34, 0x4953, 0x4473, 0x3e68, 0x3236, 0x404c, + 0x4b70, 0x3c71, 0x3b3b, 0x3537, 0x4575, 0x5e66, 0x5e63, 0x3e5d, + 0x5e5f, 0x3437, 0x3d5d, 0x5e60, 0x446d, 0x4f46, 0x3560, 0x365e, + 0x4a5a, 0x3574, 0x5e65, 0x5546, 0x5e61, 0x4c4d, 0x467e, 0x4545, + 0x5234, 0x3e72, 0x4253, 0x4c3d, 0x3338, 0x3d53, 0x3f58, 0x4d46, + 0x515a, 0x346b, 0x5e64, 0x5e5d, 0x5e67, 0x6a7e, 0x4230, 0x5e62, + 0x5640, 0x3527, 0x3274, 0x5e68, 0x5e72, 0x5e6d, 0x5e71, 0x4860, + 0x5761, 0x5e6f, 0x4368, 0x4c61, 0x3265, 0x523e, 0x5e6e, 0x5e6b, + 0x4e55, 0x3427, 0x3f2b, 0x3e3e, 0x3d52, 0x5e69, 0x542e, 0x5e5e, + 0x5e6a, 0x403f, 0x5e6c, 0x3273, 0x3869, 0x4227, 0x3d41, 0x5e75, + 0x5e78, 0x322b, 0x3424, 0x346a, 0x4926, 0x5e76, 0x4b51, 0x3863, + 0x5e77, 0x5e7a, 0x5e79, 0x4c42, 0x3061, 0x346e, 0x653a, 0x502f, + 0x326b, 0x6b21, 0x5e74, 0x4963, 0x5e73, 0x305a, 0x5221, 0x3177, + 0x4c2f, 0x5e70, 0x4b24, 0x552a, 0x5e7b, 0x345d, 0x4426, 0x5e7d, + 0x437e, 0x4421, 0x5f21, 0x414c, 0x5e7c, 0x3e6f, 0x4632, 0x3345, + 0x4876, 0x4b3a, 0x5e7e, 0x5f24, 0x5732, 0x3337, 0x4143, 0x474b, + 0x3225, 0x3469, 0x572b, 0x446c, 0x5f22, 0x5f23, 0x5f25, 0x3a33, + 0x5f26, 0x405e, 0x4943, 0x3259, 0x4766, 0x5f27, 0x475c, 0x5f28, + 0x6b22, 0x4b53, 0x5f2a, 0x5f29, 0x3241, 0x454a, 0x5f2b, 0x545c, + 0x4841, 0x5f2c, 0x3e70, 0x5f2d, 0x5627, 0x6a37, 0x6b36, 0x4a55, + 0x587c, 0x3844, 0x3925, 0x3745, 0x557e, 0x394a, 0x5027, 0x744d, + 0x3550, 0x4374, 0x3e48, 0x6b37, 0x303d, 0x3d4c, 0x4132, 0x3156, + 0x3328, 0x3852, 0x4922, 0x3658, 0x6b38, 0x3e34, 0x4a7d, 0x4743, + 0x557b, 0x3773, 0x4e44, 0x552b, 0x3173, 0x6c33, 0x305f, 0x6c35, + 0x3637, 0x414f, 0x757a, 0x5031, 0x5565, 0x4e53, 0x3d6f, 0x3362, + 0x382b, 0x5536, 0x6d3d, 0x364f, 0x4b39, 0x5042, 0x373d, 0x6c36, + 0x4a29, 0x4554, 0x6c39, 0x6c38, 0x4243, 0x6c37, 0x507d, 0x6c3a, + 0x6c3b, 0x5765, 0x6c3c, 0x6c3d, 0x466c, 0x4e5e, 0x3c48, 0x4855, + 0x3529, 0x3e49, 0x563c, 0x5467, 0x512e, 0x5071, 0x6a38, 0x6a39, + 0x6a3a, 0x3a35, 0x4a31, 0x3f75, 0x4d7a, 0x6a40, 0x303a, 0x6a3e, + 0x4025, 0x6a3b, 0x327d, 0x4377, 0x3b68, 0x5257, 0x4e74, 0x6a3f, + 0x6a3c, 0x6a43, 0x5047, 0x5333, 0x343a, 0x4341, 0x5772, 0x5551, + 0x4a47, 0x6a45, 0x6a44, 0x6a47, 0x6a46, 0x5667, 0x4f54, 0x6a4b, + 0x3b4e, 0x3d7a, 0x494e, 0x6a4c, 0x4939, 0x4f7e, 0x6a4a, 0x544e, + 0x6a4d, 0x6a4f, 0x4d6d, 0x6a49, 0x6a4e, 0x4e6e, 0x3b5e, 0x333f, + 0x4655, 0x3e30, 0x4e7a, 0x4767, 0x3e27, 0x6a50, 0x5647, 0x4140, + 0x545d, 0x6a51, 0x4f3e, 0x6a52, 0x4a6e, 0x452f, 0x3035, 0x6a54, + 0x6a53, 0x745f, 0x443a, 0x3129, 0x655f, 0x6a55, 0x4a6f, 0x6a56, + 0x6a57, 0x4658, 0x6a58, 0x6a59, 0x543b, 0x477a, 0x5237, 0x387c, + 0x6a42, 0x325c, 0x427c, 0x5478, 0x4c66, 0x576e, 0x5442, 0x5350, + 0x6b43, 0x4573, 0x377e, 0x6b54, 0x4b37, 0x6b5e, 0x404a, 0x4d7b, + 0x332f, 0x465a, 0x6b7c, 0x443e, 0x4e34, 0x4429, 0x313e, 0x547d, + 0x4a75, 0x566c, 0x4653, 0x3664, 0x3b7a, 0x5060, 0x4931, 0x5453, + 0x4828, 0x384b, 0x683e, 0x493c, 0x683b, 0x406e, 0x5053, 0x3244, + 0x3465, 0x683c, 0x5548, 0x3645, 0x683d, 0x4a78, 0x385c, 0x4c75, + 0x4034, 0x516e, 0x683f, 0x6842, 0x3a3c, 0x312d, 0x3d5c, 0x6a3d, + 0x6843, 0x6846, 0x684b, 0x684c, 0x4b49, 0x3065, 0x3c2b, 0x3939, + 0x6841, 0x4d77, 0x684a, 0x4e76, 0x556d, 0x4156, 0x6844, 0x4336, + 0x397b, 0x5626, 0x6848, 0x4a60, 0x5466, 0x6840, 0x6845, 0x6847, + 0x4739, 0x3763, 0x6849, 0x3f5d, 0x6852, 0x6857, 0x6855, 0x3c5c, + 0x3c4f, 0x685b, 0x685e, 0x685a, 0x317a, 0x3058, 0x4433, 0x384c, + 0x4662, 0x483e, 0x4861, 0x684f, 0x6854, 0x6856, 0x3971, 0x6858, + 0x5775, 0x447b, 0x685c, 0x3269, 0x6851, 0x3c6d, 0x3f42, 0x684d, + 0x5679, 0x4178, 0x3271, 0x685f, 0x4a41, 0x6859, 0x5524, 0x316a, + 0x553b, 0x684e, 0x6850, 0x3630, 0x6853, 0x685d, 0x4038, 0x4a77, + 0x4b28, 0x465c, 0x4075, 0x6869, 0x5023, 0x6872, 0x566a, 0x6860, + 0x6861, 0x5179, 0x3a4b, 0x3879, 0x3871, 0x5454, 0x686f, 0x686e, + 0x686c, 0x3970, 0x4c52, 0x6866, 0x4e26, 0x3f72, 0x3038, 0x6871, + 0x6870, 0x5740, 0x6864, 0x4d29, 0x4923, 0x3b38, 0x3d5b, 0x686a, + 0x6862, 0x6863, 0x6865, 0x3535, 0x6867, 0x4745, 0x686b, 0x686d, + 0x3d30, 0x572e, 0x6878, 0x6875, 0x4d30, 0x6876, 0x413a, 0x6868, + 0x4337, 0x3070, 0x6874, 0x6877, 0x3923, 0x4952, 0x434e, 0x4e60, + 0x4066, 0x4b73, 0x4c5d, 0x5035, 0x4a61, 0x6873, 0x3c6c, 0x6879, + 0x435e, 0x4665, 0x3977, 0x3074, 0x5758, 0x3c2c, 0x456f, 0x4c44, + 0x6926, 0x492d, 0x6922, 0x4062, 0x3f43, 0x687e, 0x3957, 0x687b, + 0x6924, 0x524e, 0x6923, 0x5632, 0x5735, 0x6927, 0x3d37, 0x687c, + 0x687d, 0x6921, 0x4d56, 0x522c, 0x6932, 0x6929, 0x342a, 0x343b, + 0x692b, 0x5028, 0x6925, 0x337e, 0x692c, 0x4063, 0x692a, 0x6939, + 0x6938, 0x692e, 0x687a, 0x6928, 0x3f2c, 0x6931, 0x693a, 0x4225, + 0x692f, 0x3845, 0x692d, 0x535c, 0x6934, 0x6935, 0x6937, 0x6947, + 0x4046, 0x6945, 0x6930, 0x693b, 0x3071, 0x693c, 0x5525, 0x693e, + 0x693f, 0x6941, 0x4171, 0x4836, 0x693d, 0x6942, 0x6943, 0x6933, + 0x6936, 0x3b31, 0x6940, 0x3c77, 0x6944, 0x6946, 0x694a, 0x694e, + 0x325b, 0x6948, 0x372e, 0x694b, 0x694c, 0x5541, 0x4423, 0x6958, + 0x3a61, 0x6949, 0x5323, 0x6954, 0x6957, 0x6950, 0x694f, 0x4741, + 0x6952, 0x6959, 0x3348, 0x6953, 0x4f70, 0x694d, 0x3377, 0x6956, + 0x695a, 0x4c34, 0x4f2d, 0x6955, 0x695c, 0x695b, 0x695e, 0x6951, + 0x695d, 0x695f, 0x434a, 0x4737, 0x344e, 0x3b36, 0x5040, 0x6c23, + 0x4537, 0x537b, 0x6c24, 0x6c25, 0x465b, 0x3f6e, 0x6c26, 0x6c27, + 0x502a, 0x4738, 0x3868, 0x6c28, 0x5639, 0x557d, 0x344b, 0x323d, + 0x4e64, 0x4667, 0x4d61, 0x3475, 0x4b40, 0x3c5f, 0x6962, 0x6963, + 0x516a, 0x6965, 0x3479, 0x6964, 0x5133, 0x4a62, 0x3250, 0x6968, + 0x6966, 0x6967, 0x5633, 0x6969, 0x696a, 0x696b, 0x696c, 0x6c2f, + 0x4539, 0x364e, 0x5273, 0x356e, 0x3b59, 0x6c31, 0x5263, 0x4e63, + 0x4438, 0x433f, 0x363e, 0x5839, 0x3148, 0x314f, 0x3151, 0x457e, + 0x3150, 0x432b, 0x5531, 0x6b24, 0x3a41, 0x4c3a, 0x6b25, 0x6b27, + 0x6b28, 0x6b26, 0x6b29, 0x6b2b, 0x6b2a, 0x6b2c, 0x4a4f, 0x5835, + 0x4371, 0x4325, 0x4678, 0x6b2d, 0x444a, 0x6b2e, 0x6b2f, 0x6b30, + 0x3755, 0x377a, 0x6b31, 0x4762, 0x6b33, 0x3a24, 0x5175, 0x3031, + 0x6b32, 0x6b34, 0x352a, 0x4248, 0x4768, 0x6b35, 0x4b2e, 0x635f, + 0x5340, 0x595b, 0x4d21, 0x562d, 0x4773, 0x5960, 0x3b63, 0x3a3a, + 0x6362, 0x4f2b, 0x6360, 0x4947, 0x3a39, 0x5134, 0x6361, 0x486a, + 0x392f, 0x3d2d, 0x3358, 0x4e5b, 0x4c40, 0x6368, 0x6369, 0x4d74, + 0x4c2d, 0x3c33, 0x636a, 0x636b, 0x505a, 0x467b, 0x375a, 0x475f, + 0x524a, 0x4e56, 0x6364, 0x636c, 0x4972, 0x3341, 0x6367, 0x4663, + 0x6365, 0x6d33, 0x6366, 0x4933, 0x4566, 0x3935, 0x433b, 0x6363, + 0x453d, 0x4124, 0x4259, 0x3257, 0x636d, 0x3b26, 0x442d, 0x6370, + 0x3e5a, 0x637b, 0x6375, 0x3a53, 0x3750, 0x534d, 0x564e, 0x5553, + 0x3941, 0x5534, 0x5158, 0x5039, 0x4776, 0x482a, 0x3234, 0x435a, + 0x636e, 0x637c, 0x636f, 0x3728, 0x6377, 0x6374, 0x373a, 0x4522, + 0x6376, 0x455d, 0x3228, 0x467c, 0x4460, 0x5722, 0x4061, 0x6379, + 0x637a, 0x637d, 0x4c29, 0x6373, 0x533e, 0x3143, 0x6d34, 0x6371, + 0x6372, 0x6378, 0x503a, 0x4643, 0x5473, 0x637e, 0x3d60, 0x6427, + 0x6426, 0x5173, 0x6423, 0x6429, 0x4877, 0x4f34, 0x6428, 0x642e, + 0x4265, 0x3634, 0x3d72, 0x6422, 0x3a69, 0x642a, 0x642c, 0x367d, + 0x565e, 0x6432, 0x642d, 0x6421, 0x3b6e, 0x4d5d, 0x4722, 0x4549, + 0x4177, 0x6424, 0x4733, 0x3d2c, 0x3d3d, 0x6425, 0x5747, 0x3262, + 0x642b, 0x3c43, 0x642f, 0x3b6b, 0x6430, 0x4528, 0x6431, 0x5563, + 0x3f23, 0x643a, 0x6437, 0x643b, 0x643d, 0x4656, 0x3a46, 0x404b, + 0x3821, 0x6434, 0x5421, 0x3a23, 0x3d7e, 0x643c, 0x4d3f, 0x4479, + 0x4f7b, 0x4966, 0x533f, 0x4f51, 0x6433, 0x6438, 0x6439, 0x4c69, + 0x4c4e, 0x4054, 0x6435, 0x4130, 0x6436, 0x4e50, 0x3b41, 0x3553, + 0x4873, 0x3d27, 0x5547, 0x492c, 0x3822, 0x644a, 0x644c, 0x5144, + 0x523a, 0x3a2d, 0x3a54, 0x6443, 0x356d, 0x574d, 0x6440, 0x4f7d, + 0x643f, 0x415c, 0x4c4a, 0x4a67, 0x4457, 0x4c54, 0x6448, 0x6447, + 0x6441, 0x6444, 0x352d, 0x5359, 0x6446, 0x5279, 0x3463, 0x3b34, + 0x496e, 0x343e, 0x3b6c, 0x514d, 0x4c6d, 0x6d35, 0x4765, 0x5428, + 0x644b, 0x5755, 0x6442, 0x3d25, 0x6445, 0x5366, 0x6449, 0x4978, + 0x643e, 0x5365, 0x477e, 0x3649, 0x547c, 0x3233, 0x6457, 0x4e42, + 0x644d, 0x4e3c, 0x385b, 0x6456, 0x3f4a, 0x534e, 0x436c, 0x4548, + 0x6458, 0x4d44, 0x644f, 0x6454, 0x6455, 0x3a7e, 0x4f66, 0x553f, + 0x6452, 0x6450, 0x644e, 0x4d65, 0x4a2a, 0x4023, 0x3d26, 0x6453, + 0x3848, 0x6467, 0x5434, 0x645b, 0x416f, 0x6469, 0x5267, 0x645f, + 0x6460, 0x4f2a, 0x4b5d, 0x645a, 0x6451, 0x6465, 0x485c, 0x6463, + 0x4467, 0x6462, 0x6461, 0x337c, 0x6468, 0x3561, 0x574c, 0x6466, + 0x3b2c, 0x5752, 0x4c4f, 0x6b78, 0x6464, 0x3976, 0x564d, 0x6459, + 0x645c, 0x427a, 0x645e, 0x424b, 0x4044, 0x4250, 0x3175, 0x4c32, + 0x354e, 0x646f, 0x462f, 0x4661, 0x6475, 0x4229, 0x406c, 0x515d, + 0x646e, 0x442e, 0x646d, 0x6476, 0x6474, 0x427e, 0x645d, 0x6470, + 0x4a7e, 0x5544, 0x6471, 0x517a, 0x646b, 0x646c, 0x6472, 0x4e2b, + 0x454b, 0x4731, 0x423a, 0x646a, 0x414a, 0x4c36, 0x3331, 0x647b, + 0x6473, 0x647a, 0x647d, 0x647c, 0x334e, 0x333a, 0x6477, 0x6479, + 0x6478, 0x456c, 0x403d, 0x5468, 0x6522, 0x3044, 0x6524, 0x6523, + 0x3c24, 0x6525, 0x6521, 0x647e, 0x3174, 0x6528, 0x6529, 0x6526, + 0x6527, 0x652a, 0x4659, 0x652b, 0x652d, 0x652c, 0x652f, 0x652e, + 0x3960, 0x6530, 0x6531, 0x3b70, 0x6c61, 0x4370, 0x3546, 0x3b52, + 0x4169, 0x546e, 0x3e44, 0x5746, 0x5456, 0x3253, 0x6c3e, 0x6a41, + 0x422f, 0x3436, 0x5157, 0x3334, 0x4832, 0x3f3b, 0x6c40, 0x564b, + 0x6c3f, 0x6c41, 0x6c45, 0x3e66, 0x4c3f, 0x455a, 0x3e3c, 0x6c46, + 0x317e, 0x6c44, 0x5528, 0x3563, 0x6c42, 0x4136, 0x3363, 0x6c43, + 0x4b38, 0x4043, 0x4c7e, 0x4152, 0x6c48, 0x3a66, 0x4053, 0x5672, + 0x514c, 0x3f3e, 0x3733, 0x4955, 0x6c47, 0x3b62, 0x4c4c, 0x3d7d, + 0x4848, 0x4f29, 0x4d69, 0x456b, 0x3769, 0x5149, 0x3a38, 0x6c49, + 0x6c4a, 0x3b40, 0x6c4b, 0x6c62, 0x313a, 0x3759, 0x3d39, 0x6c4c, + 0x5166, 0x6c4d, 0x483b, 0x6c51, 0x6c53, 0x3b4d, 0x3c65, 0x6c4f, + 0x4937, 0x433a, 0x6c63, 0x5555, 0x6c50, 0x5673, 0x6c52, 0x6c4e, + 0x6c54, 0x6c55, 0x493f, 0x4f28, 0x505c, 0x512c, 0x485b, 0x6c56, + 0x4e75, 0x4a6c, 0x6c5a, 0x6c59, 0x303e, 0x6c57, 0x6c58, 0x6c64, + 0x483c, 0x4147, 0x6c5c, 0x5160, 0x6c5b, 0x546f, 0x6c5d, 0x5b46, + 0x6c5e, 0x312c, 0x6c5f, 0x6c60, 0x5726, 0x4540, 0x6b3c, 0x302e, + 0x3e74, 0x3838, 0x522f, 0x3056, 0x3579, 0x5833, 0x4b2c, 0x635d, + 0x462c, 0x3066, 0x4546, 0x6b39, 0x6b3a, 0x6b3b, 0x5140, 0x4523, + 0x6a72, 0x4432, 0x4435, 0x404e, 0x6a73, 0x4441, 0x4e6f, 0x6a70, + 0x6a74, 0x497c, 0x4723, 0x4c58, 0x4e7e, 0x6a75, 0x6a76, 0x4f2c, + 0x4067, 0x6a77, 0x363f, 0x6a78, 0x6a79, 0x6a7a, 0x6a7b, 0x6a71, + 0x482e, 0x616b, 0x3738, 0x616c, 0x616d, 0x5734, 0x616e, 0x616f, + 0x534c, 0x6171, 0x3f71, 0x6170, 0x3552, 0x3137, 0x6173, 0x6172, + 0x3a7c, 0x6174, 0x3937, 0x3e51, 0x447c, 0x3a5d, 0x3d46, 0x6175, + 0x6177, 0x3640, 0x4f41, 0x4a28, 0x6176, 0x5578, 0x537c, 0x6178, + 0x617c, 0x6179, 0x617a, 0x406a, 0x617e, 0x6221, 0x4047, 0x617b, + 0x617d, 0x6225, 0x4154, 0x6223, 0x6228, 0x327e, 0x6222, 0x434d, + 0x3242, 0x6227, 0x6226, 0x6224, 0x6229, 0x622b, 0x5049, 0x566d, + 0x4328, 0x622c, 0x4f57, 0x622e, 0x3a6f, 0x6960, 0x622d, 0x622a, + 0x3b2b, 0x5433, 0x6230, 0x622f, 0x6961, 0x6231, 0x6232, 0x6233, + 0x4c21, 0x6234, 0x6235, 0x507e, 0x424a, 0x5371, 0x4d75, 0x6760, + 0x6761, 0x3e41, 0x426a, 0x6764, 0x6763, 0x4d66, 0x4335, 0x6762, + 0x3b37, 0x4f56, 0x4161, 0x6769, 0x6768, 0x6774, 0x3223, 0x676a, + 0x6766, 0x676c, 0x676b, 0x493a, 0x5564, 0x6765, 0x3729, 0x6767, + 0x676e, 0x6773, 0x5669, 0x676d, 0x6772, 0x6771, 0x3060, 0x6775, + 0x4772, 0x4045, 0x406d, 0x4170, 0x6770, 0x6776, 0x4b76, 0x6822, + 0x6821, 0x5741, 0x677a, 0x6779, 0x677b, 0x6777, 0x677e, 0x677d, + 0x677c, 0x4155, 0x4759, 0x457d, 0x4543, 0x476d, 0x6823, 0x6826, + 0x6825, 0x6827, 0x3a77, 0x6778, 0x6824, 0x4870, 0x492a, 0x6829, + 0x3965, 0x517e, 0x6828, 0x682a, 0x682d, 0x682e, 0x4127, 0x682f, + 0x6830, 0x682c, 0x6834, 0x682b, 0x6831, 0x6835, 0x6832, 0x6833, + 0x6837, 0x6836, 0x394f, 0x702c, 0x702d, 0x4630, 0x306a, 0x483f, + 0x4d5f, 0x4e4d, 0x6a31, 0x6a32, 0x463f, 0x3449, 0x6a33, 0x5567, + 0x5d79, 0x6a34, 0x6a35, 0x6a36, 0x384a, 0x5f30, 0x4975, 0x4c70, + 0x497a, 0x497b, 0x5343, 0x4b26, 0x3826, 0x702e, 0x3142, 0x6538, + 0x4c6f, 0x5349, 0x3c57, 0x496a, 0x3567, 0x4450, 0x3569, 0x6e2e, + 0x3b2d, 0x675e, 0x6e2f, 0x3329, 0x6e32, 0x6e31, 0x3d67, 0x6e30, + 0x4e37, 0x454f, 0x4174, 0x5b4e, 0x6e33, 0x5073, 0x4254, 0x4668, + 0x372c, 0x6e34, 0x336b, 0x3b7b, 0x6e35, 0x675c, 0x6e36, 0x3d2e, + 0x7162, 0x4a68, 0x5249, 0x705a, 0x705b, 0x705c, 0x4146, 0x386d, + 0x3e4e, 0x705e, 0x4531, 0x705d, 0x5171, 0x7060, 0x304c, 0x3d6a, + 0x525f, 0x705f, 0x342f, 0x3768, 0x7066, 0x7065, 0x4623, 0x7061, + 0x7062, 0x3443, 0x7063, 0x556e, 0x4c5b, 0x3e52, 0x3c32, 0x7068, + 0x7067, 0x7064, 0x3221, 0x5622, 0x5338, 0x3e37, 0x482c, 0x706a, + 0x5177, 0x564c, 0x3a5b, 0x7069, 0x363b, 0x4d34, 0x4626, 0x4121, + 0x706b, 0x706e, 0x706d, 0x7070, 0x706c, 0x3b3e, 0x706f, 0x4c35, + 0x7072, 0x3355, 0x3154, 0x7073, 0x7074, 0x7076, 0x3461, 0x7071, + 0x7077, 0x707a, 0x7078, 0x7075, 0x707d, 0x7079, 0x707c, 0x707e, + 0x7121, 0x4e41, 0x7124, 0x7123, 0x4176, 0x707b, 0x4a5d, 0x3471, + 0x3171, 0x4c31, 0x7126, 0x7127, 0x712c, 0x554e, 0x7129, 0x4833, + 0x7122, 0x712b, 0x7128, 0x7125, 0x712a, 0x3029, 0x712d, 0x712f, + 0x7131, 0x7130, 0x712e, 0x5122, 0x7132, 0x7133, 0x396f, 0x3547, + 0x3057, 0x3059, 0x546d, 0x3544, 0x3d54, 0x3b4a, 0x7027, 0x385e, + 0x7028, 0x3028, 0x7029, 0x4d6e, 0x702a, 0x702b, 0x4624, 0x5665, + 0x7164, 0x7165, 0x4373, 0x535b, 0x5651, 0x4568, 0x532f, 0x5266, + 0x6e41, 0x303b, 0x5535, 0x514e, 0x3c60, 0x3a50, 0x3f78, 0x3847, + 0x3541, 0x454c, 0x4a22, 0x434b, 0x6e42, 0x443f, 0x3622, 0x6d6c, + 0x4324, 0x5631, 0x4f60, 0x6d6f, 0x454e, 0x365c, 0x4a21, 0x6d6d, + 0x6d70, 0x6d71, 0x433c, 0x3f34, 0x6d6e, 0x6d74, 0x6d72, 0x5566, + 0x435f, 0x6d73, 0x6d76, 0x5523, 0x5123, 0x6d75, 0x4350, 0x6d77, + 0x3f74, 0x3e6c, 0x6d78, 0x4c77, 0x515b, 0x5745, 0x5576, 0x6d7c, + 0x6d7b, 0x6d79, 0x6d7a, 0x6d7d, 0x3e26, 0x4b2f, 0x6e21, 0x363d, + 0x6e22, 0x4440, 0x6d7e, 0x3d5e, 0x3247, 0x3643, 0x6e25, 0x583a, + 0x6e23, 0x6e26, 0x4369, 0x3372, 0x6e27, 0x6e24, 0x4f39, 0x6e28, + 0x4277, 0x6e29, 0x6e2a, 0x5e2b, 0x4633, 0x4746, 0x5675, 0x3549, + 0x4b32, 0x6e2b, 0x4d2b, 0x6e2c, 0x5530, 0x6e2d, 0x7644, 0x5b47, + 0x3423, 0x432c, 0x7166, 0x4a38, 0x5253, 0x562a, 0x6f72, 0x3e58, + 0x3d43, 0x6f73, 0x364c, 0x302b, 0x4a2f, 0x6d36, 0x6d37, 0x4e79, + 0x372f, 0x3f73, 0x6d38, 0x426b, 0x4930, 0x6d39, 0x4676, 0x3f33, + 0x6d3c, 0x4578, 0x5150, 0x5729, 0x6d3a, 0x6d3b, 0x5162, 0x6d3f, + 0x6d40, 0x6d44, 0x6d48, 0x6d46, 0x6d4e, 0x5568, 0x6d49, 0x6d47, + 0x6d3e, 0x4569, 0x4646, 0x4969, 0x5452, 0x6d41, 0x6d42, 0x6d43, + 0x6d45, 0x4079, 0x3421, 0x3968, 0x6d50, 0x6d51, 0x6d4a, 0x6d4f, + 0x4e78, 0x4b36, 0x6d4c, 0x6d4d, 0x4f75, 0x6d52, 0x4172, 0x5332, + 0x6d4b, 0x4837, 0x3c6f, 0x4570, 0x6d56, 0x356f, 0x4235, 0x302d, + 0x4b69, 0x312e, 0x6d54, 0x4d6b, 0x3562, 0x6d55, 0x6d53, 0x6d57, + 0x357a, 0x6d58, 0x6d59, 0x6d5c, 0x314c, 0x4576, 0x3c6e, 0x6d5a, + 0x4c3c, 0x326a, 0x6d5b, 0x446b, 0x3445, 0x3075, 0x6d5f, 0x405a, + 0x3468, 0x454d, 0x6d5d, 0x3f44, 0x6d5e, 0x4425, 0x6d60, 0x6d61, + 0x6d63, 0x4157, 0x3b47, 0x3d38, 0x6d62, 0x6d64, 0x6d66, 0x6d65, + 0x6d67, 0x4a3e, 0x6c6a, 0x4071, 0x4967, 0x6c6b, 0x466e, 0x6c6c, + 0x466d, 0x6c6d, 0x6c70, 0x5766, 0x6c73, 0x6c71, 0x6c6e, 0x6c6f, + 0x5723, 0x4971, 0x4b6e, 0x6c74, 0x6c72, 0x4f69, 0x6c76, 0x4631, + 0x3c40, 0x6c75, 0x353b, 0x3b76, 0x6c77, 0x5977, 0x3d7b, 0x423b, + 0x6c78, 0x6c79, 0x3823, 0x6c7a, 0x6c7b, 0x6c7c, 0x536d, 0x582e, + 0x406b, 0x475d, 0x3a4c, 0x5063, 0x4b3d, 0x4d3a, 0x3851, 0x317c, + 0x476f, 0x5656, 0x3f46, 0x436b, 0x6f75, 0x4358, 0x5762, 0x6f77, + 0x3353, 0x4758, 0x516d, 0x5648, 0x6f78, 0x6f76, 0x3b7d, 0x3346, + 0x3d55, 0x5246, 0x3b60, 0x4f21, 0x6f7c, 0x6f7b, 0x6f79, 0x334c, + 0x4954, 0x4b30, 0x6f7e, 0x305e, 0x5649, 0x6f7d, 0x336d, 0x7655, + 0x4e48, 0x7022, 0x7021, 0x353e, 0x3c5a, 0x3b7c, 0x3865, 0x4442, + 0x7023, 0x4b6b, 0x7026, 0x5128, 0x3e3f, 0x476e, 0x7136, 0x7137, + 0x3f55, 0x3429, 0x7138, 0x4d3b, 0x4754, 0x552d, 0x7139, 0x713a, + 0x474f, 0x5224, 0x564f, 0x713b, 0x3d51, 0x3430, 0x3e3d, 0x345c, + 0x4e51, 0x3f5f, 0x713d, 0x3f7a, 0x713c, 0x713f, 0x713e, 0x7140, + 0x7141, 0x417e, 0x4122, 0x4a7a, 0x553e, 0x3e3a, 0x3e39, 0x5542, + 0x3f22, 0x4d2f, 0x7135, 0x3d5f, 0x364b, 0x5671, 0x7343, 0x7344, + 0x384d, 0x7346, 0x7347, 0x304a, 0x7345, 0x7349, 0x4b71, 0x734b, + 0x5026, 0x314a, 0x7348, 0x734f, 0x3551, 0x7357, 0x7352, 0x7354, + 0x7353, 0x377b, 0x313f, 0x734e, 0x734a, 0x355a, 0x7350, 0x7351, + 0x7355, 0x734d, 0x3c63, 0x417d, 0x7356, 0x735a, 0x734c, 0x3548, + 0x3d6e, 0x735c, 0x3724, 0x3f70, 0x567e, 0x4d32, 0x3470, 0x325f, + 0x7358, 0x7359, 0x4938, 0x735d, 0x735e, 0x7361, 0x735f, 0x7363, + 0x7362, 0x735b, 0x3f6a, 0x336f, 0x7360, 0x4729, 0x3c72, 0x736b, + 0x393f, 0x7364, 0x322d, 0x3b7e, 0x4b63, 0x736d, 0x7369, 0x395c, + 0x736e, 0x7365, 0x7366, 0x736a, 0x4261, 0x736c, 0x736f, 0x7368, + 0x3c7d, 0x4f64, 0x7370, 0x7367, 0x7372, 0x572d, 0x462a, 0x7373, + 0x7371, 0x4228, 0x385d, 0x7375, 0x7374, 0x345b, 0x7376, 0x7377, + 0x7378, 0x403a, 0x4069, 0x4571, 0x737b, 0x737a, 0x3458, 0x737e, + 0x7379, 0x737c, 0x737d, 0x7421, 0x7423, 0x3b49, 0x7422, 0x7424, + 0x323e, 0x7426, 0x7425, 0x3c2e, 0x4357, 0x5961, 0x4060, 0x744c, + 0x5751, 0x375b, 0x744e, 0x4123, 0x4649, 0x3456, 0x5533, 0x7450, + 0x744f, 0x7451, 0x4b5a, 0x7452, 0x5441, 0x5660, 0x3760, 0x4138, + 0x413b, 0x7453, 0x3e2c, 0x3462, 0x7454, 0x7455, 0x3e2b, 0x7456, + 0x745b, 0x7457, 0x745a, 0x3a7d, 0x7458, 0x7459, 0x3862, 0x4c47, + 0x745c, 0x325a, 0x4353, 0x5463, 0x3f37, 0x745d, 0x4534, 0x7469, + 0x4f35, 0x4e49, 0x4b58, 0x4b77, 0x3d74, 0x574f, 0x405b, 0x5075, + 0x746a, 0x746b, 0x746c, 0x7763, 0x3731, 0x746d, 0x576b, 0x746e, + 0x6679, 0x3e40, 0x667a, 0x3a6c, 0x667b, 0x4f4b, 0x667c, 0x543c, + 0x3c36, 0x667d, 0x667e, 0x3c4d, 0x4852, 0x4e33, 0x6721, 0x343f, + 0x6722, 0x4934, 0x3859, 0x4449, 0x575d, 0x425a, 0x3757, 0x563d, + 0x4e46, 0x3744, 0x4526, 0x6723, 0x4f5f, 0x6724, 0x6725, 0x6726, + 0x4137, 0x5769, 0x4970, 0x4f38, 0x562f, 0x5655, 0x6727, 0x306d, + 0x6728, 0x6729, 0x495c, 0x526f, 0x3e2d, 0x672a, 0x3073, 0x485e, + 0x3d61, 0x672b, 0x4846, 0x672c, 0x3b66, 0x3878, 0x5124, 0x672d, + 0x4267, 0x3e78, 0x3d4a, 0x4d33, 0x672e, 0x672f, 0x3e6e, 0x5065, + 0x4b67, 0x4c50, 0x3c4c, 0x6730, 0x3c28, 0x5077, 0x6731, 0x5078, + 0x6732, 0x6733, 0x3442, 0x6734, 0x6735, 0x497e, 0x4e2c, 0x4360, + 0x6737, 0x3141, 0x3371, 0x6738, 0x6739, 0x575b, 0x5540, 0x673a, + 0x424c, 0x573a, 0x673b, 0x673c, 0x673d, 0x3c6a, 0x4365, 0x4042, + 0x673e, 0x673f, 0x3c29, 0x6740, 0x6741, 0x6736, 0x3650, 0x6742, + 0x6743, 0x6744, 0x3b3a, 0x355e, 0x4246, 0x3160, 0x6745, 0x5435, + 0x6746, 0x383f, 0x6748, 0x6747, 0x376c, 0x6749, 0x3278, 0x674a, + 0x674b, 0x674c, 0x674d, 0x674e, 0x674f, 0x6750, 0x5327, 0x4b75, + 0x6751, 0x6752, 0x6753, 0x6754, 0x4949, 0x6755, 0x6756, 0x6757, + 0x6758, 0x6759, 0x3d49, 0x675a, 0x733e, 0x3857, 0x4831, 0x733f, + 0x7340, 0x7341, 0x395e, 0x4d78, 0x5868, 0x3a31, 0x425e, 0x6e37, + 0x3723, 0x6e39, 0x6e38, 0x3055, 0x6e3b, 0x5556, 0x576f, 0x5643, + 0x6e3d, 0x4a70, 0x6e3c, 0x6e3e, 0x6e40, 0x6e3f, 0x5172, 0x473c, + 0x4340, 0x3861, 0x4167, 0x7446, 0x505f, 0x7447, 0x4f5b, 0x483a, + 0x7448, 0x7449, 0x744a, 0x744b, 0x597a, 0x387e, 0x6571, 0x5370, + 0x7460, 0x4e4c, 0x3361, 0x7134, 0x526e, 0x7461, 0x4f68, 0x7462, + 0x474c, 0x3554, 0x3464, 0x7464, 0x7463, 0x7465, 0x7466, 0x7467, + 0x3a32, 0x303f, 0x7468, 0x372d, 0x526d, 0x522b, 0x404f, 0x3f3c, + 0x6b23, 0x555f, 0x6a48, 0x7173, 0x3678, 0x4b23, 0x444d, 0x7167, + 0x7168, 0x387b, 0x7169, 0x3a44, 0x5445, 0x3052, 0x716a, 0x716b, + 0x716c, 0x716d, 0x716e, 0x716f, 0x7171, 0x7170, 0x4555, 0x7172, + 0x367a, 0x7174, 0x522e, 0x5e47, 0x4b4a, 0x335c, 0x3522, 0x3922, + 0x4474, 0x7175, 0x7176, 0x4144, 0x417b, 0x5630, 0x7177, 0x7178, + 0x412a, 0x4638, 0x3e5b, 0x7179, 0x344f, 0x717a, 0x6d32, 0x6d31, + 0x4b60, 0x525e, 0x4b41, 0x5558, 0x4862, 0x405f, 0x3c21, 0x6b41, + 0x5024, 0x5662, 0x3647, 0x3858, 0x6b40, 0x384e, 0x6b3f, 0x3326, + 0x3949, 0x562b, 0x3774, 0x374a, 0x3c67, 0x373e, 0x6b46, 0x6b47, + 0x3039, 0x3f4f, 0x6b45, 0x537d, 0x6b48, 0x6b49, 0x374e, 0x6b42, + 0x6b44, 0x4976, 0x5657, 0x554d, 0x5032, 0x6b4f, 0x4e38, 0x6b50, + 0x3528, 0x3133, 0x6b52, 0x4c25, 0x4556, 0x6b53, 0x6b51, 0x455f, + 0x6b4e, 0x4a24, 0x6b55, 0x307b, 0x3a7a, 0x5837, 0x7163, 0x6b4a, + 0x6b4b, 0x6b4c, 0x6b4d, 0x6b56, 0x6640, 0x6b59, 0x3f68, 0x5248, + 0x6b57, 0x6b5c, 0x386c, 0x6b58, 0x3d3a, 0x5058, 0x3037, 0x6b5d, + 0x445c, 0x562c, 0x3460, 0x4276, 0x3c39, 0x6b5a, 0x6b5b, 0x5460, + 0x466a, 0x4454, 0x6b5f, 0x4527, 0x5975, 0x3231, 0x6b64, 0x3d45, + 0x6b62, 0x6b63, 0x382c, 0x4d51, 0x6b65, 0x6b61, 0x4133, 0x4622, + 0x4c73, 0x6b66, 0x4030, 0x5238, 0x6b67, 0x382f, 0x382d, 0x6b68, + 0x473b, 0x4d73, 0x6b6a, 0x6b6b, 0x6b6d, 0x5048, 0x6b72, 0x6b6e, + 0x6b71, 0x4879, 0x517c, 0x6b6c, 0x6b69, 0x3839, 0x4f59, 0x4465, + 0x6b6f, 0x6b70, 0x4c5a, 0x4d48, 0x3072, 0x6b76, 0x6b75, 0x3232, + 0x3860, 0x6b77, 0x316c, 0x4c45, 0x4424, 0x4f25, 0x6b79, 0x6c22, + 0x4572, 0x6b7a, 0x4945, 0x625f, 0x6b7e, 0x4d4e, 0x6c21, 0x315b, + 0x5337, 0x525c, 0x6b7d, 0x6b7b, 0x333c, 0x6a30, 0x5754, 0x742b, + 0x3374, 0x5641, 0x5642, 0x5569, 0x3e4a, 0x7427, 0x5228, 0x7428, + 0x7429, 0x742a, 0x3e4b, 0x535f, 0x4960, 0x4961, 0x7342, 0x4a66, + 0x4c72, 0x6236, 0x4b34, 0x4e68, 0x565b, 0x742d, 0x742e, 0x742f, + 0x7432, 0x3a3d, 0x7433, 0x3063, 0x7430, 0x7431, 0x3d22, 0x3255, + 0x7436, 0x7437, 0x3666, 0x3230, 0x4f4f, 0x7434, 0x342c, 0x7435, + 0x7438, 0x7439, 0x4d27, 0x743a, 0x743b, 0x743c, 0x4b52, 0x743d, + 0x743e, 0x743f, 0x745e, 0x413c, 0x3c68, 0x492b, 0x515e, 0x6575, + 0x5c33, 0x5255, 0x5c34, 0x302c, 0x5c35, 0x3d5a, 0x5c39, 0x5842, + 0x5c37, 0x5373, 0x4956, 0x5c3a, 0x5c36, 0x5c3b, 0x4322, 0x5c3c, + 0x5c45, 0x5c3d, 0x4e5f, 0x5625, 0x5c4f, 0x5c4d, 0x5c52, 0x3d66, + 0x422b, 0x5c38, 0x5c4b, 0x5c4e, 0x5c3e, 0x3752, 0x3045, 0x5c47, + 0x503e, 0x5c41, 0x3b28, 0x373c, 0x5c4c, 0x5c46, 0x5c3f, 0x475b, + 0x513f, 0x5c40, 0x5c4a, 0x5c50, 0x4e2d, 0x5c42, 0x5c43, 0x5c48, + 0x5c49, 0x3254, 0x5c51, 0x4b55, 0x5437, 0x5c5b, 0x5c5f, 0x4c26, + 0x5c66, 0x4367, 0x5c5c, 0x3f41, 0x5c59, 0x307a, 0x3936, 0x5c65, + 0x5c53, 0x5c44, 0x5c56, 0x4874, 0x3f60, 0x493b, 0x313d, 0x5322, + 0x5c5a, 0x5c55, 0x463b, 0x5c5e, 0x5742, 0x432f, 0x3736, 0x4751, + 0x4329, 0x5c62, 0x5c58, 0x5c6b, 0x5c54, 0x5c5d, 0x3e25, 0x5c57, + 0x5c60, 0x5c63, 0x5c64, 0x5c78, 0x5c61, 0x5d22, 0x5c67, 0x3c6b, + 0x3444, 0x4323, 0x3267, 0x5c7a, 0x5c72, 0x5c6f, 0x5c7c, 0x5c6e, + 0x5270, 0x3268, 0x4857, 0x4863, 0x5c7b, 0x5c6d, 0x5c77, 0x5c75, + 0x3e23, 0x5c74, 0x325d, 0x5c73, 0x3c76, 0x5c68, 0x3b44, 0x4073, + 0x3c54, 0x5c69, 0x5c6a, 0x5c71, 0x5c76, 0x5c79, 0x3534, 0x4859, + 0x3b67, 0x5c7e, 0x5c7d, 0x532b, 0x5d21, 0x5d23, 0x5d25, 0x5271, + 0x5d24, 0x5d26, 0x5d27, 0x5229, 0x3a49, 0x5d29, 0x5d36, 0x5d31, + 0x5d34, 0x5d30, 0x464e, 0x4072, 0x492f, 0x5c6c, 0x5d2e, 0x5d37, + 0x5c70, 0x5d2f, 0x5d38, 0x5d2c, 0x5d39, 0x5d33, 0x5d2d, 0x442a, + 0x5d28, 0x4033, 0x412b, 0x5d2a, 0x5d2b, 0x5d32, 0x3b71, 0x5d35, + 0x5328, 0x5d3a, 0x5d3b, 0x4327, 0x5d52, 0x5d3c, 0x5d51, 0x393d, + 0x3e55, 0x3e7a, 0x3a4a, 0x5d4a, 0x5d45, 0x5d3f, 0x324b, 0x5d43, + 0x5d4b, 0x3224, 0x5d55, 0x5d3e, 0x4650, 0x5d50, 0x5d54, 0x4162, + 0x3746, 0x5d4e, 0x5d4f, 0x5d44, 0x5d3d, 0x5d4d, 0x4c51, 0x5d49, + 0x5d42, 0x4348, 0x463c, 0x4e2e, 0x5d4c, 0x5d48, 0x5d41, 0x5d46, + 0x425c, 0x5329, 0x532a, 0x5d53, 0x4f74, 0x4878, 0x5d66, 0x5d47, + 0x5d60, 0x4264, 0x5d61, 0x5d57, 0x5678, 0x5d59, 0x5d58, 0x3870, + 0x5d56, 0x464f, 0x362d, 0x5d62, 0x3a79, 0x5461, 0x5d67, 0x3450, + 0x5d5a, 0x3f7b, 0x5d63, 0x5d5f, 0x5d5d, 0x3559, 0x5d5b, 0x5d5c, + 0x5d5e, 0x3d2f, 0x5d64, 0x5d65, 0x5d75, 0x4349, 0x4b62, 0x5d72, + 0x5861, 0x4651, 0x5d74, 0x5574, 0x5d73, 0x5d70, 0x5d6c, 0x5d6f, + 0x5d68, 0x506e, 0x4858, 0x5d6e, 0x5d69, 0x5d6a, 0x4b72, 0x5d6d, + 0x314d, 0x4036, 0x3c3b, 0x5d71, 0x5d77, 0x5d76, 0x5d6b, 0x456e, + 0x5d7b, 0x5e24, 0x5e23, 0x5d78, 0x436f, 0x427b, 0x5561, 0x4e35, + 0x5d7d, 0x324c, 0x4468, 0x4a5f, 0x473e, 0x5d7a, 0x5d7c, 0x5d7e, + 0x5e22, 0x302a, 0x314e, 0x5e2c, 0x5e26, 0x3d36, 0x486f, 0x5e21, + 0x5e25, 0x5e29, 0x5e28, 0x5e27, 0x5e2d, 0x544c, 0x5e33, 0x5e2a, + 0x5e2e, 0x4059, 0x3121, 0x5e36, 0x5e31, 0x5e32, 0x5126, 0x5e35, + 0x5e2f, 0x5e30, 0x503d, 0x5e34, 0x4a6d, 0x5e39, 0x5e38, 0x5e37, + 0x5e3b, 0x3d65, 0x3258, 0x436a, 0x5e3a, 0x453a, 0x5e3c, 0x4c59, + 0x372a, 0x5465, 0x5e3d, 0x5e3f, 0x4422, 0x5e41, 0x5e3e, 0x5e40, + 0x553a, 0x5e42, 0x722e, 0x3b22, 0x4232, 0x4530, 0x4247, 0x722f, + 0x5069, 0x535d, 0x6b3d, 0x3366, 0x7230, 0x7231, 0x4a2d, 0x3a67, + 0x7233, 0x7235, 0x7234, 0x4b64, 0x4f3a, 0x7232, 0x4a34, 0x524f, + 0x426c, 0x4e43, 0x7238, 0x3076, 0x7237, 0x723e, 0x324f, 0x5141, + 0x723a, 0x723c, 0x5469, 0x723b, 0x7236, 0x723f, 0x723d, 0x7239, + 0x7247, 0x7244, 0x7246, 0x724a, 0x7242, 0x7240, 0x7245, 0x567b, + 0x7241, 0x4779, 0x495f, 0x7248, 0x3946, 0x3530, 0x7243, 0x7249, + 0x7250, 0x7256, 0x3b57, 0x7255, 0x4d5c, 0x566b, 0x7252, 0x7254, + 0x3872, 0x724b, 0x724e, 0x4279, 0x555d, 0x724c, 0x724d, 0x724f, + 0x7253, 0x7259, 0x533c, 0x366a, 0x4a71, 0x3764, 0x7257, 0x7258, + 0x725a, 0x725d, 0x725b, 0x725c, 0x5151, 0x7251, 0x4d49, 0x4e4f, + 0x5629, 0x7263, 0x435b, 0x7260, 0x402f, 0x726c, 0x725e, 0x7261, + 0x7268, 0x7262, 0x7267, 0x7266, 0x7269, 0x725f, 0x7264, 0x726a, + 0x532c, 0x7265, 0x3275, 0x7272, 0x502b, 0x7275, 0x3b48, 0x7279, + 0x7270, 0x7276, 0x7278, 0x727a, 0x7273, 0x7271, 0x3a7b, 0x357b, + 0x726f, 0x7277, 0x726d, 0x726e, 0x726b, 0x7326, 0x7323, 0x7322, + 0x7274, 0x485a, 0x727b, 0x7325, 0x4378, 0x727d, 0x7327, 0x7329, + 0x7324, 0x727c, 0x732b, 0x732a, 0x425d, 0x732e, 0x7330, 0x7321, + 0x7331, 0x732c, 0x732f, 0x727e, 0x732d, 0x7332, 0x7334, 0x7328, + 0x7333, 0x7335, 0x5037, 0x7338, 0x5979, 0x7339, 0x7337, 0x4864, + 0x7336, 0x733a, 0x733b, 0x3440, 0x6e43, 0x733c, 0x733d, 0x512a, + 0x742c, 0x5046, 0x5050, 0x515c, 0x4f4e, 0x3d56, 0x5143, 0x3a62, + 0x6169, 0x5242, 0x7142, 0x3239, 0x316d, 0x7143, 0x4940, 0x3344, + 0x5972, 0x4b25, 0x7144, 0x5654, 0x7145, 0x7440, 0x7146, 0x542c, + 0x7147, 0x3040, 0x7441, 0x7442, 0x347c, 0x455b, 0x4c3b, 0x5064, + 0x4d60, 0x7148, 0x5973, 0x313b, 0x4f2e, 0x3824, 0x714a, 0x714b, + 0x3243, 0x4151, 0x5730, 0x7149, 0x714c, 0x714e, 0x5976, 0x5261, + 0x5423, 0x7443, 0x4839, 0x7444, 0x714d, 0x714f, 0x3f63, 0x7150, + 0x7154, 0x7156, 0x7151, 0x4951, 0x4561, 0x4263, 0x397c, 0x7153, + 0x7155, 0x3953, 0x715b, 0x3a56, 0x307d, 0x7159, 0x7158, 0x7152, + 0x715a, 0x7157, 0x486c, 0x4d4a, 0x715d, 0x653d, 0x715c, 0x715e, + 0x715f, 0x4f65, 0x7445, 0x3d73, 0x7160, 0x7161, 0x4e77, 0x522a, + 0x717b, 0x3832, 0x3c7b, 0x395b, 0x3966, 0x4359, 0x4a53, 0x6a68, + 0x4040, 0x3e75, 0x6a69, 0x6a6a, 0x6a6b, 0x6a6c, 0x6a6d, 0x6a6e, + 0x6a6f, 0x3d47, 0x757b, 0x757d, 0x757e, 0x757c, 0x3d62, 0x7621, + 0x3425, 0x7622, 0x7623, 0x6c32, 0x5154, 0x596a, 0x7624, 0x6e3a, + 0x5532, 0x537e, 0x4c5c, 0x4a44, 0x6540, 0x7625, 0x3e2f, 0x4629, + 0x5a25, 0x3c46, 0x3629, 0x383c, 0x484f, 0x3c25, 0x5a26, 0x5a27, + 0x4c56, 0x4843, 0x5a28, 0x467d, 0x5135, 0x5269, 0x5136, 0x3c47, + 0x3d32, 0x3b64, 0x5a29, 0x5a2a, 0x5148, 0x5a2b, 0x506d, 0x366f, + 0x425b, 0x4b4f, 0x376d, 0x4968, 0x3743, 0x3e77, 0x5624, 0x5a2c, + 0x5a2d, 0x4640, 0x5767, 0x4a36, 0x5529, 0x4b5f, 0x556f, 0x5a2e, + 0x565f, 0x344a, 0x5a30, 0x5a2f, 0x526b, 0x5a31, 0x5a32, 0x5a33, + 0x4a54, 0x5a34, 0x4a2b, 0x5a35, 0x5a36, 0x334f, 0x566f, 0x5a37, + 0x3b30, 0x352e, 0x5a38, 0x5a39, 0x396e, 0x512f, 0x5268, 0x5a3a, + 0x3843, 0x4f6a, 0x326f, 0x5a3b, 0x5a3c, 0x3d6b, 0x4e5c, 0x536f, + 0x5a3d, 0x4e73, 0x5a3e, 0x5355, 0x3b65, 0x5a3f, 0x4b35, 0x4b50, + 0x5a40, 0x476b, 0x566e, 0x5a41, 0x4535, 0x3641, 0x5a42, 0x374c, + 0x3f4e, 0x5a43, 0x5a44, 0x4b2d, 0x5a45, 0x3577, 0x5a46, 0x4142, + 0x573b, 0x5a47, 0x4c38, 0x526a, 0x4431, 0x5a48, 0x357d, 0x3b51, + 0x5a49, 0x5033, 0x5a4a, 0x5a4b, 0x4e3d, 0x5a4c, 0x5a4d, 0x5a4e, + 0x3277, 0x5a51, 0x5a4f, 0x5168, 0x5a50, 0x4355, 0x5a52, 0x5a53, + 0x5a54, 0x5a55, 0x503b, 0x5225, 0x3079, 0x5a56, 0x472b, 0x5a57, + 0x3d77, 0x4321, 0x5a58, 0x5a59, 0x437d, 0x4c37, 0x5a5a, 0x5a5b, + 0x403e, 0x4657, 0x5a5c, 0x5a5d, 0x4734, 0x5a5e, 0x5a5f, 0x3948, + 0x3b6d, 0x3639, 0x7478, 0x7479, 0x4d63, 0x7539, 0x6b60, 0x4f73, + 0x3b3f, 0x3a40, 0x5425, 0x6159, 0x7574, 0x312a, 0x3272, 0x7575, + 0x7577, 0x3a51, 0x7576, 0x4332, 0x7579, 0x7578, 0x3134, 0x556a, + 0x383a, 0x3931, 0x3246, 0x5470, 0x4f4d, 0x305c, 0x554b, 0x3b75, + 0x564a, 0x3737, 0x4c30, 0x4636, 0x3161, 0x393a, 0x567c, 0x3961, + 0x3721, 0x3c7a, 0x6a5a, 0x6a5b, 0x4c79, 0x3973, 0x6a5c, 0x347b, + 0x4333, 0x3751, 0x3a58, 0x6a5d, 0x5474, 0x6a5e, 0x3c56, 0x3b5f, + 0x6a5f, 0x415e, 0x4238, 0x545f, 0x574a, 0x6a60, 0x6a61, 0x6a64, + 0x6a62, 0x6a63, 0x495e, 0x3833, 0x3644, 0x6a65, 0x4a6a, 0x494d, + 0x344d, 0x6259, 0x4562, 0x6a66, 0x4035, 0x5738, 0x6a67, 0x572c, + 0x487c, 0x5853, 0x584d, 0x545e, 0x5479, 0x4944, 0x532e, 0x3853, + 0x3360, 0x4962, 0x7476, 0x3a55, 0x7477, 0x575f, 0x7471, 0x3830, + 0x5554, 0x384f, 0x4670, 0x3343, 0x7472, 0x332c, 0x543d, 0x4777, + 0x7474, 0x7473, 0x4c4b, 0x4824, 0x7475, 0x5763, 0x453f, 0x7540, + 0x753b, 0x7543, 0x7542, 0x563a, 0x7541, 0x543e, 0x7544, 0x754c, + 0x304f, 0x3578, 0x7549, 0x754a, 0x455c, 0x7545, 0x7546, 0x7547, + 0x754b, 0x3e60, 0x7548, 0x387a, 0x7550, 0x7553, 0x3f67, 0x3972, + 0x753c, 0x754d, 0x4237, 0x4c78, 0x3c79, 0x754e, 0x754f, 0x7551, + 0x3665, 0x7552, 0x7555, 0x753d, 0x7554, 0x533b, 0x336c, 0x4c24, + 0x7556, 0x7557, 0x3e61, 0x7558, 0x4c5f, 0x755b, 0x3248, 0x5759, + 0x7559, 0x755a, 0x755c, 0x7562, 0x7560, 0x755f, 0x755d, 0x7561, + 0x755e, 0x7564, 0x7565, 0x4c63, 0x653f, 0x3538, 0x7563, 0x7568, + 0x4c23, 0x7566, 0x7567, 0x753e, 0x3144, 0x753f, 0x3545, 0x3264, + 0x756c, 0x7569, 0x3657, 0x756d, 0x756a, 0x756b, 0x345a, 0x546a, + 0x756e, 0x3379, 0x756f, 0x7571, 0x7570, 0x7572, 0x7573, 0x496d, + 0x392a, 0x477b, 0x3663, 0x4c49, 0x6a26, 0x3335, 0x547e, 0x396c, + 0x5079, 0x696d, 0x572a, 0x696e, 0x4256, 0x486d, 0x3a64, 0x696f, + 0x6970, 0x6971, 0x5661, 0x6972, 0x6973, 0x6975, 0x6974, 0x6976, + 0x6977, 0x4761, 0x6978, 0x5458, 0x6979, 0x3d4e, 0x697a, 0x697b, + 0x3d4f, 0x697c, 0x3828, 0x413e, 0x697d, 0x3132, 0x3b54, 0x3975, + 0x697e, 0x6a21, 0x6a22, 0x6a23, 0x3778, 0x3c2d, 0x4a64, 0x604e, + 0x542f, 0x4f3d, 0x5537, 0x6a24, 0x555e, 0x6a25, 0x5041, 0x393c, + 0x3447, 0x3159, 0x4031, 0x3166, 0x3167, 0x3168, 0x333d, 0x4868, + 0x6541, 0x315f, 0x4149, 0x346f, 0x4728, 0x5358, 0x4679, 0x5138, + 0x397d, 0x4275, 0x532d, 0x544b, 0x3d7c, 0x6542, 0x3735, 0x6543, + 0x3b39, 0x5562, 0x3d78, 0x5436, 0x4e25, 0x412c, 0x3359, 0x4c76, + 0x6546, 0x6544, 0x6548, 0x654a, 0x6547, 0x354f, 0x4648, 0x357c, + 0x6545, 0x4a76, 0x6549, 0x4354, 0x3145, 0x3c23, 0x5737, 0x4d4b, + 0x4b4d, 0x4a4a, 0x4c53, 0x654c, 0x654b, 0x4466, 0x5121, 0x5137, + 0x654d, 0x6550, 0x4d38, 0x5670, 0x654f, 0x355d, 0x4d3e, 0x6551, + 0x363a, 0x4d28, 0x3964, 0x4a45, 0x3351, 0x4b59, 0x546c, 0x6552, + 0x376a, 0x654e, 0x6555, 0x347e, 0x6556, 0x6553, 0x6554, 0x525d, + 0x425f, 0x3146, 0x5362, 0x365d, 0x4b6c, 0x6557, 0x5376, 0x3169, + 0x3674, 0x655a, 0x6558, 0x6559, 0x3540, 0x5245, 0x655c, 0x655e, + 0x655d, 0x4732, 0x5223, 0x655b, 0x5462, 0x555a, 0x6560, 0x5771, + 0x6561, 0x315c, 0x517b, 0x6562, 0x6564, 0x6563, 0x6565, 0x5258, + 0x354b, 0x675f, 0x5a75, 0x5a78, 0x5a76, 0x5a77, 0x5a7a, 0x504f, + 0x4447, 0x306e, 0x5030, 0x5a79, 0x534a, 0x3a2a, 0x5b22, 0x4771, + 0x5a7c, 0x5a7b, 0x495b, 0x5a7d, 0x5b21, 0x575e, 0x5a7e, 0x415a, + 0x5b25, 0x5374, 0x5b27, 0x5b24, 0x5b28, 0x3d3c, 0x4049, 0x5b23, + 0x5b26, 0x5623, 0x5b29, 0x5b2d, 0x5b2e, 0x5b2c, 0x3a42, 0x3f24, + 0x5b2b, 0x5b2a, 0x5447, 0x323f, 0x5b2f, 0x3979, 0x5b30, 0x333b, + 0x3526, 0x363c, 0x5b31, 0x3675, 0x5b32, 0x3149, 0x5b34, 0x5b33, + 0x5b35, 0x5b37, 0x5b36, 0x5b38, 0x5b39, 0x5b3a, 0x534f, 0x747a, + 0x4775, 0x5743, 0x4564, 0x747c, 0x747d, 0x747b, 0x3e46, 0x506f, + 0x3753, 0x544d, 0x4c2a, 0x7522, 0x7521, 0x3a28, 0x747e, 0x4b56, + 0x7524, 0x4052, 0x336a, 0x4d2a, 0x7525, 0x7523, 0x3d34, 0x7528, + 0x7529, 0x3d4d, 0x4338, 0x3f61, 0x4b61, 0x752a, 0x7526, 0x7527, + 0x4470, 0x752c, 0x343c, 0x576d, 0x3457, 0x752b, 0x752e, 0x752d, + 0x752f, 0x5051, 0x4351, 0x4829, 0x7530, 0x7531, 0x7532, 0x7533, + 0x7534, 0x7535, 0x7537, 0x7536, 0x7538, 0x3249, 0x5354, 0x4a4d, + 0x406f, 0x5658, 0x5230, 0x413f, 0x3d70, 0x382a, 0x3c78, 0x7646, + 0x7647, 0x7648, 0x7649, 0x764a, 0x764c, 0x764b, 0x7769, 0x764d, + 0x764e, 0x6e44, 0x6e45, 0x6e46, 0x556b, 0x3624, 0x6e48, 0x6e47, + 0x6e49, 0x6e4a, 0x4725, 0x6e4b, 0x6e4c, 0x3730, 0x3576, 0x6e4d, + 0x6e4f, 0x6e4e, 0x3846, 0x6e50, 0x6e51, 0x6e52, 0x365b, 0x332e, + 0x5653, 0x4446, 0x3135, 0x3856, 0x6e53, 0x6e54, 0x543f, 0x4755, + 0x3e7b, 0x4e59, 0x3933, 0x6e56, 0x6e55, 0x6e58, 0x6e57, 0x4525, + 0x6e59, 0x6e5a, 0x472e, 0x6e5b, 0x472f, 0x6e5c, 0x3227, 0x6e5d, + 0x6e5e, 0x6e5f, 0x6e60, 0x6e61, 0x576a, 0x6e62, 0x6e63, 0x3c58, + 0x6e64, 0x534b, 0x4c7a, 0x322c, 0x4165, 0x6e65, 0x4726, 0x432d, + 0x6e66, 0x6e67, 0x6e68, 0x6e69, 0x6e6a, 0x6e6b, 0x6e6c, 0x6e6d, + 0x6e6e, 0x6e6f, 0x6e70, 0x6e71, 0x6e72, 0x6e74, 0x6e73, 0x6e75, + 0x4d2d, 0x4241, 0x6e76, 0x6e77, 0x6e78, 0x5521, 0x6e79, 0x4f33, + 0x6e7a, 0x6e7b, 0x6e7c, 0x6e7d, 0x6f21, 0x6e7e, 0x6f22, 0x3875, + 0x437a, 0x6f23, 0x6f24, 0x3d42, 0x523f, 0x3279, 0x6f25, 0x6f26, + 0x6f27, 0x5278, 0x6f28, 0x567d, 0x6f29, 0x464c, 0x6f2a, 0x6f2b, + 0x4134, 0x6f2c, 0x4f7a, 0x4b78, 0x6f2e, 0x6f2d, 0x337a, 0x3978, + 0x6f2f, 0x6f30, 0x5062, 0x6f31, 0x6f32, 0x3766, 0x503f, 0x6f33, + 0x6f34, 0x6f35, 0x4871, 0x4c60, 0x6f36, 0x6f37, 0x6f38, 0x6f39, + 0x6f3a, 0x5560, 0x6f3b, 0x346d, 0x432a, 0x6f3c, 0x6f3d, 0x6f3e, + 0x6f3f, 0x4e7d, 0x6f40, 0x4260, 0x3438, 0x5736, 0x3d75, 0x4f47, + 0x6f43, 0x6f41, 0x6f42, 0x6f44, 0x3627, 0x3c7c, 0x3e62, 0x434c, + 0x6f45, 0x6f46, 0x6f47, 0x6f4f, 0x6f48, 0x6f49, 0x6f4a, 0x4742, + 0x6f71, 0x364d, 0x6f4b, 0x6f4c, 0x6f4d, 0x3646, 0x433e, 0x6f4e, + 0x6f50, 0x6f51, 0x6f52, 0x5572, 0x6f53, 0x4477, 0x6f54, 0x4478, + 0x6f55, 0x6f56, 0x3864, 0x3077, 0x6f57, 0x6f58, 0x6f59, 0x6f5a, + 0x6f5b, 0x6f5c, 0x6f5d, 0x6f5e, 0x3e35, 0x6f61, 0x6f5f, 0x6f60, + 0x6f62, 0x6f63, 0x414d, 0x6f64, 0x6f65, 0x6f66, 0x6f67, 0x6f68, + 0x6f69, 0x6f6a, 0x6f6b, 0x6f6c, 0x4058, 0x6f6d, 0x412d, 0x6f6e, + 0x6f6f, 0x6f70, 0x4f62, 0x3324, 0x4345, 0x6345, 0x4941, 0x6346, + 0x3155, 0x4e4a, 0x3433, 0x4872, 0x6347, 0x4f50, 0x6348, 0x3c64, + 0x6349, 0x634a, 0x4346, 0x5522, 0x4456, 0x396b, 0x4e45, 0x634b, + 0x4376, 0x634c, 0x3727, 0x3873, 0x3a52, 0x634d, 0x634e, 0x5444, + 0x634f, 0x6350, 0x514b, 0x6351, 0x6352, 0x6353, 0x6354, 0x5156, + 0x6355, 0x327b, 0x403b, 0x6356, 0x402b, 0x6357, 0x6358, 0x6359, + 0x635a, 0x635b, 0x3837, 0x5a62, 0x3653, 0x5a64, 0x5a63, 0x5a66, + 0x486e, 0x5a65, 0x3740, 0x5174, 0x5275, 0x5573, 0x3d57, 0x5768, + 0x5a68, 0x5a67, 0x3022, 0x4d53, 0x5a69, 0x383d, 0x3c4a, 0x423d, + 0x4224, 0x3342, 0x5a6a, 0x422a, 0x4430, 0x3d35, 0x4f5e, 0x5a6b, + 0x4942, 0x315d, 0x5a6c, 0x3638, 0x543a, 0x337d, 0x5a6d, 0x5449, + 0x4f55, 0x4563, 0x5a6e, 0x5a6f, 0x5a70, 0x416a, 0x4c55, 0x4f5d, + 0x5367, 0x4221, 0x5a71, 0x4b65, 0x5a72, 0x4b66, 0x527e, 0x3874, + 0x5a73, 0x302f, 0x4f36, 0x554f, 0x4b6d, 0x5a74, 0x6344, 0x4125, + 0x763f, 0x7640, 0x7641, 0x4451, 0x4838, 0x5163, 0x505b, 0x5145, + 0x3c2f, 0x394d, 0x6f74, 0x3446, 0x533a, 0x7642, 0x337b, 0x7643, + 0x3571, 0x7645, 0x536a, 0x7627, 0x5129, 0x7629, 0x7628, 0x4163, + 0x4057, 0x3122, 0x4e6d, 0x5068, 0x762b, 0x4f76, 0x762a, 0x5570, + 0x762c, 0x4339, 0x3b74, 0x762e, 0x762d, 0x445e, 0x4158, 0x4b2a, + 0x4f3c, 0x762f, 0x7630, 0x7631, 0x4236, 0x3054, 0x4579, 0x7632, + 0x4760, 0x7626, 0x3e38, 0x3e32, 0x3565, 0x3747, 0x3f3f, 0x4352, + 0x4366, 0x584c, 0x386f, 0x3d79, 0x5125, 0x3050, 0x7730, 0x7731, + 0x502c, 0x3030, 0x7732, 0x7733, 0x7734, 0x474a, 0x3e4f, 0x7737, + 0x7736, 0x315e, 0x7735, 0x7738, 0x7739, 0x4e24, 0x484d, 0x3a2b, + 0x6838, 0x6839, 0x683a, 0x3e42, 0x5274, 0x544f, 0x4958, 0x5233, + 0x3625, 0x476a, 0x717c, 0x4f6e, 0x4b33, 0x506b, 0x676f, 0x4d67, + 0x394b, 0x3659, 0x717d, 0x3064, 0x4b4c, 0x717e, 0x5424, 0x422d, + 0x416c, 0x4644, 0x3e31, 0x7221, 0x3c55, 0x7222, 0x7223, 0x7224, + 0x5243, 0x4635, 0x4d47, 0x7225, 0x5331, 0x3f45, 0x4c62, 0x7226, + 0x7227, 0x5155, 0x366e, 0x7228, 0x7229, 0x355f, 0x722a, 0x722b, + 0x327c, 0x722c, 0x722d, 0x4827, 0x3767, 0x6c29, 0x6c2a, 0x6c2b, + 0x6c2c, 0x462e, 0x6c2d, 0x6c2e, 0x3749, 0x4a33, 0x6238, 0x774f, + 0x7750, 0x324d, 0x7751, 0x7753, 0x7752, 0x623b, 0x3c22, 0x623c, + 0x623d, 0x623e, 0x623f, 0x6240, 0x6241, 0x3739, 0x527b, 0x3d24, + 0x4a4e, 0x3125, 0x4b47, 0x6242, 0x367c, 0x4844, 0x6243, 0x3d48, + 0x317d, 0x6244, 0x3676, 0x6245, 0x4459, 0x6246, 0x4f5a, 0x395d, + 0x6247, 0x4021, 0x6248, 0x3276, 0x6249, 0x4173, 0x624a, 0x624b, + 0x4278, 0x624c, 0x624d, 0x624e, 0x4a57, 0x5838, 0x5965, 0x4f63, + 0x7025, 0x5c30, 0x426d, 0x5426, 0x4d54, 0x5131, 0x335b, 0x477d, + 0x3235, 0x423f, 0x6660, 0x4a3b, 0x6661, 0x6662, 0x3e54, 0x6663, + 0x5724, 0x4d55, 0x6665, 0x3c5d, 0x6664, 0x6666, 0x6667, 0x426e, + 0x3d3e, 0x6668, 0x4266, 0x3a27, 0x6669, 0x666a, 0x3352, 0x5169, + 0x3f25, 0x666b, 0x466f, 0x666c, 0x666d, 0x666e, 0x462d, 0x666f, + 0x4927, 0x6670, 0x6671, 0x6672, 0x6539, 0x6673, 0x6674, 0x4262, + 0x6675, 0x6676, 0x5668, 0x6677, 0x6678, 0x3947, 0x773b, 0x773a, + 0x773e, 0x773c, 0x3a21, 0x773f, 0x7740, 0x7742, 0x7741, 0x7744, + 0x7743, 0x7745, 0x7746, 0x7747, 0x4b68, 0x385f, 0x7754, 0x7755, + 0x7756, 0x7758, 0x775a, 0x7757, 0x775b, 0x7759, 0x5757, 0x775c, + 0x775d, 0x775e, 0x775f, 0x7760, 0x5b4b, 0x582a, 0x6577, 0x396d, + 0x3f7d, 0x3b6a, 0x7749, 0x4647, 0x7748, 0x774a, 0x774c, 0x774b, + 0x774d, 0x4e3a, 0x774e, 0x4427, 0x5363, 0x764f, 0x4233, 0x7650, + 0x7651, 0x7652, 0x7653, 0x7654, 0x7656, 0x312b, 0x7657, 0x7658, + 0x7659, 0x765a, 0x765b, 0x765c, 0x765d, 0x765e, 0x4f4a, 0x765f, + 0x7660, 0x7661, 0x7662, 0x7663, 0x7664, 0x4070, 0x7665, 0x7666, + 0x7667, 0x7668, 0x7669, 0x766a, 0x766b, 0x766c, 0x766d, 0x766e, + 0x766f, 0x7670, 0x7671, 0x7672, 0x7673, 0x7674, 0x3e28, 0x7675, + 0x7676, 0x7677, 0x7678, 0x487a, 0x7679, 0x767a, 0x767b, 0x767c, + 0x767d, 0x767e, 0x7721, 0x7722, 0x7723, 0x7724, 0x7725, 0x7726, + 0x7727, 0x7728, 0x316e, 0x7729, 0x772a, 0x772b, 0x772c, 0x772d, + 0x415b, 0x772e, 0x772f, 0x4471, 0x702f, 0x3c26, 0x7030, 0x4379, + 0x4538, 0x513b, 0x7031, 0x7032, 0x7033, 0x7034, 0x7035, 0x513c, + 0x516c, 0x7037, 0x7036, 0x5427, 0x4d52, 0x7038, 0x703a, 0x7039, + 0x703b, 0x703c, 0x386b, 0x703d, 0x3a68, 0x703e, 0x703f, 0x3e69, + 0x7040, 0x366c, 0x7041, 0x7042, 0x7043, 0x7044, 0x4835, 0x7045, + 0x7046, 0x7047, 0x4574, 0x7048, 0x7049, 0x704a, 0x773d, 0x704b, + 0x704c, 0x704d, 0x704e, 0x704f, 0x3a57, 0x7050, 0x7051, 0x7052, + 0x7053, 0x7054, 0x7055, 0x7056, 0x7058, 0x5325, 0x7057, 0x7059, + 0x753a, 0x4239, 0x7764, 0x7765, 0x7766, 0x7767, 0x7768, 0x4234, + 0x776a, 0x776b, 0x4273, 0x7470, 0x746f, 0x4269, 0x7761, 0x7762, + 0x3b46, 0x5964, 0x4a72, 0x4068, 0x7024, 0x3a5a, 0x472d, 0x442c, + 0x776c, 0x776d, 0x776e, 0x7770, 0x776f, 0x7771, 0x7774, 0x7773, + 0x7772, 0x7775, 0x7776, 0x6d69, 0x6d6a, 0x6d6b, 0x763c, 0x763d, + 0x763e, 0x3626, 0x583e, 0x3944, 0x583b, 0x5c31, 0x4a73, 0x7777, + 0x7778, 0x7779, 0x777b, 0x777a, 0x3147, 0x777c, 0x777d, 0x777e, + 0x466b, 0x6c34, 0x335d, 0x7633, 0x7634, 0x4164, 0x7635, 0x7636, + 0x7637, 0x7638, 0x7639, 0x763a, 0x4823, 0x763b, 0x417a, 0x3928, + 0x6d68, 0x396a, 0x595f, 0x2321, 0x2322, 0x2323, 0x2167, 0x2325, + 0x2326, 0x2327, 0x2328, 0x2329, 0x232a, 0x232b, 0x232c, 0x232d, + 0x232e, 0x232f, 0x2330, 0x2331, 0x2332, 0x2333, 0x2334, 0x2335, + 0x2336, 0x2337, 0x2338, 0x2339, 0x233a, 0x233b, 0x233c, 0x233d, + 0x233e, 0x233f, 0x2340, 0x2341, 0x2342, 0x2343, 0x2344, 0x2345, + 0x2346, 0x2347, 0x2348, 0x2349, 0x234a, 0x234b, 0x234c, 0x234d, + 0x234e, 0x234f, 0x2350, 0x2351, 0x2352, 0x2353, 0x2354, 0x2355, + 0x2356, 0x2357, 0x2358, 0x2359, 0x235a, 0x235b, 0x235c, 0x235d, + 0x235e, 0x235f, 0x2360, 0x2361, 0x2362, 0x2363, 0x2364, 0x2365, + 0x2366, 0x2367, 0x2368, 0x2369, 0x236a, 0x236b, 0x236c, 0x236d, + 0x236e, 0x236f, 0x2370, 0x2371, 0x2372, 0x2373, 0x2374, 0x2375, + 0x2376, 0x2377, 0x2378, 0x2379, 0x237a, 0x237b, 0x237c, 0x237d, + 0x212b, 0x2169, 0x216a, 0x237e, 0x2324, +}; + +static const Summary16 gb2312_uni2indx_page00[70] = { + /* 0x0000 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0190 }, { 3, 0x0003 }, + { 5, 0x0000 }, { 5, 0x0080 }, { 6, 0x3703 }, { 13, 0x168c }, + /* 0x0100 */ + { 19, 0x0002 }, { 20, 0x0808 }, { 22, 0x0800 }, { 23, 0x0000 }, + { 23, 0x2000 }, { 24, 0x0000 }, { 24, 0x0800 }, { 25, 0x0000 }, + { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x0000 }, + { 25, 0x4000 }, { 26, 0x1555 }, { 33, 0x0000 }, { 33, 0x0000 }, + /* 0x0200 */ + { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0000 }, + { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0000 }, + { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0000 }, + { 33, 0x0280 }, { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, + /* 0x0300 */ + { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, + { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, + { 35, 0x0000 }, { 35, 0xfffe }, { 50, 0x03fb }, { 59, 0xfffe }, + { 74, 0x03fb }, { 83, 0x0000 }, { 83, 0x0000 }, { 83, 0x0000 }, + /* 0x0400 */ + { 83, 0x0002 }, { 84, 0xffff }, { 100, 0xffff }, { 116, 0xffff }, + { 132, 0xffff }, { 148, 0x0002 }, +}; +static const Summary16 gb2312_uni2indx_page20[101] = { + /* 0x2000 */ + { 149, 0x0000 }, { 149, 0x3360 }, { 155, 0x0040 }, { 156, 0x080d }, + { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, + { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, + { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, + /* 0x2100 */ + { 160, 0x0008 }, { 161, 0x0040 }, { 162, 0x0000 }, { 162, 0x0000 }, + { 162, 0x0000 }, { 162, 0x0000 }, { 162, 0x0fff }, { 174, 0x0000 }, + { 174, 0x0000 }, { 174, 0x000f }, { 178, 0x0000 }, { 178, 0x0000 }, + { 178, 0x0000 }, { 178, 0x0000 }, { 178, 0x0000 }, { 178, 0x0000 }, + /* 0x2200 */ + { 178, 0x8100 }, { 180, 0x6402 }, { 184, 0x4fa1 }, { 192, 0x20f0 }, + { 197, 0x1100 }, { 199, 0x0000 }, { 199, 0xc033 }, { 205, 0x0000 }, + { 205, 0x0000 }, { 205, 0x0200 }, { 206, 0x0020 }, { 207, 0x0000 }, + { 207, 0x0000 }, { 207, 0x0000 }, { 207, 0x0000 }, { 207, 0x0000 }, + /* 0x2300 */ + { 207, 0x0000 }, { 207, 0x0004 }, { 208, 0x0000 }, { 208, 0x0000 }, + { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, + { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, + { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, + /* 0x2400 */ + { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, + { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x03ff }, { 218, 0xfff0 }, + { 230, 0xffff }, { 246, 0x0fff }, { 258, 0x0000 }, { 258, 0x0000 }, + { 258, 0x0000 }, { 258, 0x0000 }, { 258, 0x0000 }, { 258, 0x0000 }, + /* 0x2500 */ + { 258, 0xffff }, { 274, 0xffff }, { 290, 0xffff }, { 306, 0xffff }, + { 322, 0x0fff }, { 334, 0x0000 }, { 334, 0x0000 }, { 334, 0x0000 }, + { 334, 0x0000 }, { 334, 0x0000 }, { 334, 0x0003 }, { 336, 0x000c }, + { 338, 0xc8c0 }, { 343, 0x0000 }, { 343, 0x0000 }, { 343, 0x0000 }, + /* 0x2600 */ + { 343, 0x0060 }, { 345, 0x0000 }, { 345, 0x0000 }, { 345, 0x0000 }, + { 345, 0x0005 }, +}; +static const Summary16 gb2312_uni2indx_page30[35] = { + /* 0x3000 */ + { 347, 0xff2f }, { 360, 0x00fb }, { 367, 0x0000 }, { 367, 0x0000 }, + { 367, 0xfffe }, { 382, 0xffff }, { 398, 0xffff }, { 414, 0xffff }, + { 430, 0xffff }, { 446, 0x000f }, { 450, 0xfffe }, { 465, 0xffff }, + { 481, 0xffff }, { 497, 0xffff }, { 513, 0xffff }, { 529, 0x087f }, + /* 0x3100 */ + { 537, 0xffe0 }, { 548, 0xffff }, { 564, 0x03ff }, { 574, 0x0000 }, + { 574, 0x0000 }, { 574, 0x0000 }, { 574, 0x0000 }, { 574, 0x0000 }, + { 574, 0x0000 }, { 574, 0x0000 }, { 574, 0x0000 }, { 574, 0x0000 }, + { 574, 0x0000 }, { 574, 0x0000 }, { 574, 0x0000 }, { 574, 0x0000 }, + /* 0x3200 */ + { 574, 0x0000 }, { 574, 0x0000 }, { 574, 0x03ff }, +}; +static const Summary16 gb2312_uni2indx_page4e[1263] = { + /* 0x4e00 */ + { 584, 0x7f8b }, { 595, 0x7f7b }, { 608, 0x3db4 }, { 617, 0xef55 }, + { 628, 0xfba8 }, { 638, 0xf35d }, { 649, 0x0243 }, { 653, 0x400b }, + { 657, 0xfb40 }, { 665, 0x8d3e }, { 674, 0x7bf7 }, { 687, 0x8c2c }, + { 693, 0x6eff }, { 706, 0xe3fa }, { 717, 0x1d3a }, { 725, 0xa8ed }, + /* 0x4f00 */ + { 734, 0xe602 }, { 740, 0xcf83 }, { 749, 0x8cf5 }, { 758, 0x3555 }, + { 766, 0xe048 }, { 771, 0xffab }, { 784, 0x92b9 }, { 792, 0xd859 }, + { 800, 0xab18 }, { 807, 0x2892 }, { 812, 0xd7e9 }, { 823, 0x8020 }, + { 825, 0xc438 }, { 831, 0xf583 }, { 840, 0xe74a }, { 849, 0x450a }, + /* 0x5000 */ + { 854, 0xb000 }, { 857, 0x9714 }, { 864, 0x7762 }, { 873, 0x5400 }, + { 876, 0xd188 }, { 882, 0x1420 }, { 885, 0x1020 }, { 887, 0xc8c0 }, + { 892, 0x2121 }, { 896, 0x0000 }, { 896, 0x13a8 }, { 902, 0x0c04 }, + { 905, 0x8000 }, { 906, 0x0440 }, { 908, 0x70c0 }, { 913, 0x0828 }, + /* 0x5100 */ + { 916, 0x08c0 }, { 919, 0x0004 }, { 920, 0x0002 }, { 921, 0x8000 }, + { 922, 0x2b7b }, { 932, 0x1472 }, { 938, 0x7924 }, { 945, 0x3bfb }, + { 957, 0x3327 }, { 965, 0x1ae4 }, { 972, 0x9835 }, { 979, 0x38ef }, + { 989, 0x9ad1 }, { 997, 0x2802 }, { 1000, 0xa813 }, { 1006, 0xbf69 }, + /* 0x5200 */ + { 1017, 0x65cf }, { 1027, 0x2fc6 }, { 1036, 0x6b11 }, { 1043, 0xafc9 }, + { 1053, 0x340f }, { 1060, 0x5053 }, { 1066, 0x86a2 }, { 1072, 0xa004 }, + { 1075, 0x0106 }, { 1078, 0xe809 }, { 1084, 0x3f0f }, { 1094, 0xc00e }, + { 1099, 0x0a88 }, { 1103, 0x8145 }, { 1108, 0x0010 }, { 1109, 0xc601 }, + /* 0x5300 */ + { 1114, 0xa161 }, { 1120, 0x26e1 }, { 1127, 0x444b }, { 1133, 0xce00 }, + { 1138, 0xc7aa }, { 1147, 0xd4ee }, { 1157, 0xcadf }, { 1168, 0x85bb }, + { 1177, 0x3a74 }, { 1185, 0xa520 }, { 1190, 0x436c }, { 1197, 0x8840 }, + { 1200, 0x3f06 }, { 1208, 0x8bd2 }, { 1216, 0xff79 }, { 1229, 0x3bef }, + /* 0x5400 */ + { 1241, 0xf75a }, { 1252, 0xe8ef }, { 1263, 0xfbcb }, { 1275, 0x5b36 }, + { 1284, 0x0d49 }, { 1290, 0x1bfd }, { 1301, 0x0154 }, { 1305, 0x39ee }, + { 1315, 0xd855 }, { 1323, 0x2e75 }, { 1332, 0xbfd8 }, { 1343, 0xa91a }, + { 1350, 0xf3d7 }, { 1362, 0xf6bf }, { 1375, 0x67e0 }, { 1383, 0xb40c }, + /* 0x5500 */ + { 1389, 0x82c2 }, { 1394, 0x0813 }, { 1398, 0xd49d }, { 1407, 0xd08b }, + { 1414, 0x065a }, { 1420, 0x1061 }, { 1424, 0x74f2 }, { 1433, 0x59e0 }, + { 1440, 0x8f9f }, { 1451, 0xb312 }, { 1458, 0x0080 }, { 1459, 0x6aaa }, + { 1467, 0x3230 }, { 1472, 0xb05e }, { 1480, 0x9d7a }, { 1490, 0x60ac }, + /* 0x5600 */ + { 1496, 0xd303 }, { 1503, 0xc900 }, { 1507, 0x3098 }, { 1512, 0x8a56 }, + { 1519, 0x7000 }, { 1522, 0x1390 }, { 1527, 0x1f14 }, { 1534, 0x1842 }, + { 1538, 0xc060 }, { 1542, 0x0008 }, { 1543, 0x8008 }, { 1545, 0x1080 }, + { 1547, 0x0400 }, { 1548, 0xec90 }, { 1555, 0x2817 }, { 1561, 0xe633 }, + /* 0x5700 */ + { 1570, 0x0758 }, { 1576, 0x9000 }, { 1578, 0xf708 }, { 1586, 0x4e09 }, + { 1592, 0xf485 }, { 1600, 0xfc83 }, { 1609, 0xaf53 }, { 1619, 0x18c8 }, + { 1624, 0x187c }, { 1631, 0x080c }, { 1634, 0x6adf }, { 1645, 0x0114 }, + { 1648, 0xc80c }, { 1653, 0xa734 }, { 1661, 0xa011 }, { 1665, 0x2710 }, + /* 0x5800 */ + { 1670, 0x28c5 }, { 1676, 0x4222 }, { 1680, 0x0413 }, { 1684, 0x0021 }, + { 1686, 0x3010 }, { 1689, 0x4112 }, { 1693, 0x1820 }, { 1696, 0x4000 }, + { 1697, 0x022b }, { 1702, 0xc60c }, { 1708, 0x0300 }, { 1710, 0x1000 }, + { 1711, 0x0022 }, { 1713, 0x0022 }, { 1715, 0x5810 }, { 1719, 0x0249 }, + /* 0x5900 */ + { 1723, 0xa094 }, { 1728, 0x9670 }, { 1735, 0xeeb0 }, { 1744, 0x1792 }, + { 1751, 0xcb96 }, { 1760, 0x05f2 }, { 1767, 0x0025 }, { 1770, 0x2358 }, + { 1776, 0x25de }, { 1785, 0x42cc }, { 1791, 0xcf38 }, { 1800, 0x4a04 }, + { 1804, 0x0c40 }, { 1807, 0x359f }, { 1817, 0x1128 }, { 1821, 0x8a00 }, + /* 0x5a00 */ + { 1824, 0x13fa }, { 1833, 0x910a }, { 1838, 0x0229 }, { 1842, 0x1056 }, + { 1847, 0x0641 }, { 1851, 0x0420 }, { 1853, 0x0484 }, { 1856, 0x84f0 }, + { 1862, 0x0000 }, { 1862, 0x0c04 }, { 1865, 0x0400 }, { 1866, 0x412c }, + { 1871, 0x1206 }, { 1875, 0x1154 }, { 1880, 0x0a4b }, { 1886, 0x0002 }, + /* 0x5b00 */ + { 1887, 0x0200 }, { 1888, 0x00c0 }, { 1890, 0x0000 }, { 1890, 0x0094 }, + { 1893, 0x0001 }, { 1894, 0xbfbb }, { 1907, 0x167c }, { 1915, 0x242b }, + { 1921, 0x9bbb }, { 1932, 0x7fa8 }, { 1942, 0x0c7f }, { 1951, 0xe379 }, + { 1961, 0x10f4 }, { 1967, 0xe00d }, { 1973, 0x4132 }, { 1978, 0x9f01 }, + /* 0x5c00 */ + { 1985, 0x8652 }, { 1991, 0x3572 }, { 1999, 0x10b4 }, { 2004, 0xff12 }, + { 2014, 0xcf27 }, { 2024, 0x4223 }, { 2029, 0xc06b }, { 2036, 0x8602 }, + { 2040, 0x3106 }, { 2045, 0x1fd3 }, { 2055, 0x3a0c }, { 2061, 0xa1aa }, + { 2068, 0x0812 }, { 2071, 0x0204 }, { 2073, 0x2572 }, { 2080, 0x0801 }, + /* 0x5d00 */ + { 2082, 0x40cc }, { 2087, 0x4850 }, { 2091, 0x62d0 }, { 2097, 0x6010 }, + { 2100, 0x1c80 }, { 2104, 0x2900 }, { 2107, 0x9a00 }, { 2111, 0x0010 }, + { 2112, 0x0004 }, { 2113, 0x2200 }, { 2115, 0x0000 }, { 2115, 0x0080 }, + { 2116, 0x2020 }, { 2118, 0x6800 }, { 2121, 0xcbe6 }, { 2131, 0x609e }, + /* 0x5e00 */ + { 2138, 0x916e }, { 2146, 0x3f73 }, { 2157, 0x60c0 }, { 2161, 0x3982 }, + { 2167, 0x1034 }, { 2171, 0x4830 }, { 2175, 0x0006 }, { 2177, 0xbd5c }, + { 2187, 0x8cd1 }, { 2194, 0xd6fb }, { 2206, 0x20e1 }, { 2211, 0x43e8 }, + { 2218, 0x0600 }, { 2220, 0x084e }, { 2225, 0x0500 }, { 2227, 0xc4d0 }, + /* 0x5f00 */ + { 2233, 0x8d1f }, { 2242, 0x89aa }, { 2249, 0xa6e1 }, { 2257, 0x1602 }, + { 2261, 0x0001 }, { 2262, 0x21ed }, { 2270, 0x3656 }, { 2278, 0x1a8b }, + { 2285, 0x1fb7 }, { 2296, 0x13a5 }, { 2303, 0x6502 }, { 2308, 0x30a0 }, + { 2312, 0xb278 }, { 2320, 0x23c7 }, { 2328, 0x6c93 }, { 2336, 0xe922 }, + /* 0x6000 */ + { 2343, 0xe47f }, { 2354, 0x3a74 }, { 2362, 0x8fe3 }, { 2372, 0x9820 }, + { 2376, 0x280e }, { 2381, 0x2625 }, { 2387, 0xbf9c }, { 2398, 0xbf49 }, + { 2408, 0x3218 }, { 2413, 0xac54 }, { 2420, 0xb949 }, { 2428, 0x1916 }, + { 2434, 0x0c60 }, { 2438, 0xb522 }, { 2445, 0xfbc1 }, { 2455, 0x0659 }, + /* 0x6100 */ + { 2461, 0xe343 }, { 2469, 0x8420 }, { 2472, 0x08d9 }, { 2478, 0x8000 }, + { 2479, 0x5500 }, { 2483, 0x2022 }, { 2486, 0x0184 }, { 2489, 0x00a1 }, + { 2492, 0x4800 }, { 2494, 0x2010 }, { 2496, 0x1380 }, { 2500, 0x4080 }, + { 2502, 0x0d04 }, { 2506, 0x0016 }, { 2509, 0x0040 }, { 2510, 0x8020 }, + /* 0x6200 */ + { 2512, 0xfd40 }, { 2520, 0x8de7 }, { 2530, 0x5436 }, { 2537, 0xe098 }, + { 2543, 0x7b8b }, { 2553, 0x091e }, { 2559, 0xfec8 }, { 2569, 0xd249 }, + { 2576, 0x0611 }, { 2580, 0x8dee }, { 2590, 0x1937 }, { 2598, 0xba22 }, + { 2605, 0x77f4 }, { 2616, 0x9fdd }, { 2628, 0xf3ec }, { 2639, 0xf0da }, + /* 0x6300 */ + { 2648, 0x4386 }, { 2654, 0xec42 }, { 2661, 0x8d3f }, { 2671, 0x2604 }, + { 2675, 0xfa6c }, { 2685, 0xc021 }, { 2689, 0x628e }, { 2696, 0x0cc2 }, + { 2701, 0xd785 }, { 2710, 0x0145 }, { 2714, 0x77ad }, { 2725, 0x5599 }, + { 2733, 0xe250 }, { 2739, 0x4045 }, { 2743, 0x260b }, { 2749, 0xa154 }, + /* 0x6400 */ + { 2755, 0x9827 }, { 2762, 0x5819 }, { 2768, 0x3443 }, { 2774, 0xa410 }, + { 2778, 0x05f2 }, { 2785, 0x4114 }, { 2789, 0x2280 }, { 2792, 0x0700 }, + { 2795, 0x00b4 }, { 2799, 0x4266 }, { 2805, 0x7210 }, { 2810, 0x15a1 }, + { 2816, 0x6025 }, { 2821, 0x4185 }, { 2826, 0x0054 }, { 2829, 0x0000 }, + /* 0x6500 */ + { 2829, 0x0201 }, { 2831, 0x0104 }, { 2833, 0xc820 }, { 2837, 0xcb70 }, + { 2845, 0x9320 }, { 2850, 0x6a62 }, { 2857, 0x184c }, { 2862, 0x0095 }, + { 2866, 0x1880 }, { 2869, 0x9a8b }, { 2877, 0xaab2 }, { 2885, 0x3201 }, + { 2889, 0xd87a }, { 2898, 0x00c4 }, { 2901, 0xf3e5 }, { 2912, 0x04c3 }, + /* 0x6600 */ + { 2917, 0xd44d }, { 2925, 0xa238 }, { 2931, 0xa1a1 }, { 2937, 0x5072 }, + { 2943, 0x980a }, { 2948, 0x84fc }, { 2956, 0xc152 }, { 2962, 0x44d1 }, + { 2968, 0x1094 }, { 2972, 0x20c2 }, { 2976, 0x4180 }, { 2979, 0x4210 }, + { 2982, 0x0000 }, { 2982, 0x3a00 }, { 2986, 0x0240 }, { 2988, 0xd29d }, + /* 0x6700 */ + { 2997, 0x2f01 }, { 3003, 0xa8b1 }, { 3010, 0xbd40 }, { 3017, 0x2432 }, + { 3022, 0xd34d }, { 3031, 0xd04b }, { 3038, 0xa723 }, { 3046, 0xd0ad }, + { 3054, 0x0a92 }, { 3059, 0x75a1 }, { 3067, 0xadac }, { 3076, 0x01e9 }, + { 3082, 0x801a }, { 3086, 0x771f }, { 3097, 0x9225 }, { 3103, 0xa01b }, + /* 0x6800 */ + { 3109, 0xdfa1 }, { 3119, 0x20ca }, { 3124, 0x0602 }, { 3127, 0x738c }, + { 3135, 0x577f }, { 3147, 0x003b }, { 3152, 0x0bff }, { 3163, 0x00d0 }, + { 3166, 0x806a }, { 3171, 0x0088 }, { 3173, 0xa1c4 }, { 3179, 0x0029 }, + { 3182, 0x2a05 }, { 3187, 0x0524 }, { 3191, 0x4009 }, { 3194, 0x1623 }, + /* 0x6900 */ + { 3200, 0x6822 }, { 3205, 0x8005 }, { 3208, 0x2011 }, { 3211, 0xa211 }, + { 3216, 0x0004 }, { 3217, 0x6490 }, { 3222, 0x4849 }, { 3227, 0x1382 }, + { 3232, 0x23d5 }, { 3240, 0x1930 }, { 3245, 0x2980 }, { 3249, 0x0892 }, + { 3253, 0x5402 }, { 3257, 0x8811 }, { 3261, 0x2001 }, { 3263, 0xa004 }, + /* 0x6a00 */ + { 3266, 0x0400 }, { 3267, 0x8180 }, { 3270, 0x8502 }, { 3274, 0x6022 }, + { 3278, 0x0090 }, { 3280, 0x0b01 }, { 3284, 0x0022 }, { 3286, 0x1202 }, + { 3289, 0x4011 }, { 3292, 0x0083 }, { 3295, 0x1a01 }, { 3299, 0x0000 }, + { 3299, 0x0000 }, { 3299, 0x0000 }, { 3299, 0x0000 }, { 3299, 0x0000 }, + /* 0x6b00 */ + { 3299, 0x0000 }, { 3299, 0x0000 }, { 3299, 0x009f }, { 3305, 0x4684 }, + { 3310, 0x12c8 }, { 3315, 0x0200 }, { 3316, 0x04fc }, { 3323, 0x1a00 }, + { 3326, 0x2ede }, { 3336, 0x0c4c }, { 3341, 0x0402 }, { 3343, 0x80b8 }, + { 3348, 0xa826 }, { 3354, 0x0afc }, { 3362, 0x8c02 }, { 3366, 0x2228 }, + /* 0x6c00 */ + { 3370, 0xa0e0 }, { 3375, 0x8f7b }, { 3386, 0xc7d6 }, { 3396, 0x2135 }, + { 3402, 0x06c7 }, { 3409, 0xf8b1 }, { 3418, 0x0713 }, { 3424, 0x6255 }, + { 3431, 0x936e }, { 3440, 0x8a19 }, { 3446, 0x6efa }, { 3457, 0xfb0e }, + { 3467, 0x1630 }, { 3472, 0x48f9 }, { 3480, 0xcd2f }, { 3490, 0x7deb }, + /* 0x6d00 */ + { 3502, 0x5892 }, { 3508, 0x4e84 }, { 3514, 0x4ca0 }, { 3519, 0x7a2e }, + { 3528, 0xedea }, { 3539, 0x561e }, { 3547, 0xc649 }, { 3554, 0x1190 }, + { 3558, 0x5324 }, { 3564, 0xe83a }, { 3572, 0xcfdb }, { 3584, 0x8124 }, + { 3588, 0x18f1 }, { 3595, 0x6342 }, { 3601, 0x5853 }, { 3608, 0x1a8a }, + /* 0x6e00 */ + { 3614, 0x7420 }, { 3619, 0x24d3 }, { 3626, 0xaa3b }, { 3635, 0x0514 }, + { 3639, 0x6018 }, { 3643, 0x8958 }, { 3649, 0x4800 }, { 3651, 0xc000 }, + { 3653, 0x8268 }, { 3658, 0x9101 }, { 3662, 0x84a4 }, { 3667, 0x2cd6 }, + { 3675, 0x8886 }, { 3680, 0xc4ba }, { 3688, 0x0377 }, { 3696, 0x0210 }, + /* 0x6f00 */ + { 3698, 0x8244 }, { 3702, 0x0038 }, { 3705, 0xae11 }, { 3712, 0x404a }, + { 3716, 0x28c0 }, { 3720, 0x5100 }, { 3723, 0x6044 }, { 3727, 0x1514 }, + { 3732, 0x7310 }, { 3738, 0x1000 }, { 3739, 0x0082 }, { 3741, 0x0248 }, + { 3744, 0x0205 }, { 3747, 0x4006 }, { 3750, 0xc003 }, { 3754, 0x0000 }, + /* 0x7000 */ + { 3754, 0x0000 }, { 3754, 0x0c02 }, { 3757, 0x0008 }, { 3758, 0x0220 }, + { 3760, 0x9000 }, { 3762, 0x4000 }, { 3763, 0xb800 }, { 3767, 0xd161 }, + { 3774, 0x4621 }, { 3779, 0x3274 }, { 3786, 0xf800 }, { 3791, 0x3b8a }, + { 3799, 0x050f }, { 3805, 0x8b00 }, { 3809, 0xbbd0 }, { 3818, 0x2280 }, + /* 0x7100 */ + { 3821, 0x0600 }, { 3823, 0x0769 }, { 3830, 0x8040 }, { 3832, 0x0043 }, + { 3835, 0x5420 }, { 3839, 0x5000 }, { 3841, 0x41d0 }, { 3846, 0x250c }, + { 3851, 0x8410 }, { 3854, 0x8310 }, { 3858, 0x1101 }, { 3861, 0x0228 }, + { 3864, 0x4008 }, { 3866, 0x0030 }, { 3868, 0x40a1 }, { 3872, 0x0200 }, + /* 0x7200 */ + { 3873, 0x0040 }, { 3874, 0x2000 }, { 3875, 0x1500 }, { 3878, 0xabe3 }, + { 3888, 0x3180 }, { 3892, 0xaa44 }, { 3898, 0xc2c6 }, { 3905, 0xc624 }, + { 3911, 0xac13 }, { 3918, 0x8004 }, { 3920, 0xb000 }, { 3923, 0x03d1 }, + { 3929, 0x611e }, { 3936, 0x4285 }, { 3941, 0xf303 }, { 3949, 0x1d9f }, + /* 0x7300 */ + { 3959, 0x440a }, { 3963, 0x78e8 }, { 3971, 0x5e26 }, { 3979, 0xc392 }, + { 3986, 0x2000 }, { 3987, 0x0085 }, { 3990, 0xb001 }, { 3994, 0x4000 }, + { 3995, 0x4a90 }, { 4000, 0x8842 }, { 4004, 0xca04 }, { 4009, 0x0c8d }, + { 4015, 0xa705 }, { 4022, 0x4203 }, { 4026, 0x22a1 }, { 4031, 0x0004 }, + /* 0x7400 */ + { 4032, 0x8668 }, { 4038, 0x0c01 }, { 4041, 0x5564 }, { 4048, 0x1079 }, + { 4054, 0x0002 }, { 4055, 0xdea0 }, { 4063, 0x2000 }, { 4064, 0x40c1 }, + { 4068, 0x488b }, { 4074, 0x5001 }, { 4077, 0x0380 }, { 4080, 0x0400 }, + { 4081, 0x0000 }, { 4081, 0x5004 }, { 4084, 0xc05d }, { 4091, 0x80d0 }, + /* 0x7500 */ + { 4095, 0xa010 }, { 4098, 0x970a }, { 4105, 0xbb20 }, { 4112, 0x4daf }, + { 4122, 0xd921 }, { 4129, 0x1e10 }, { 4134, 0x0460 }, { 4137, 0x8314 }, + { 4142, 0x8848 }, { 4146, 0xa6d6 }, { 4155, 0xd83b }, { 4164, 0x733f }, + { 4175, 0x27bc }, { 4184, 0x4974 }, { 4191, 0x0ddc }, { 4199, 0x9213 }, + /* 0x7600 */ + { 4205, 0x142b }, { 4211, 0x8ba1 }, { 4218, 0x2e75 }, { 4227, 0xd139 }, + { 4235, 0x3009 }, { 4239, 0x5050 }, { 4243, 0x8808 }, { 4246, 0x6900 }, + { 4250, 0x49d4 }, { 4257, 0x024a }, { 4261, 0x4010 }, { 4263, 0x8016 }, + { 4267, 0xe564 }, { 4275, 0x89d7 }, { 4284, 0xc020 }, { 4287, 0x5316 }, + /* 0x7700 */ + { 4294, 0x2b92 }, { 4301, 0x8600 }, { 4304, 0xa345 }, { 4311, 0x15e0 }, + { 4317, 0x008b }, { 4321, 0x0c03 }, { 4325, 0x196e }, { 4333, 0xe200 }, + { 4337, 0x7031 }, { 4343, 0x8006 }, { 4346, 0x16a5 }, { 4353, 0xa829 }, + { 4359, 0x2000 }, { 4360, 0x1880 }, { 4363, 0x7aac }, { 4372, 0xe148 }, + /* 0x7800 */ + { 4378, 0x3207 }, { 4384, 0xb5d6 }, { 4394, 0x32e8 }, { 4401, 0x5f91 }, + { 4410, 0x50a1 }, { 4415, 0x20e5 }, { 4421, 0x7c00 }, { 4426, 0x1080 }, + { 4428, 0x7280 }, { 4433, 0x9d8a }, { 4441, 0x00aa }, { 4445, 0x421f }, + { 4452, 0x0e22 }, { 4457, 0x0231 }, { 4461, 0x1100 }, { 4463, 0x0494 }, + /* 0x7900 */ + { 4467, 0x0022 }, { 4469, 0x4008 }, { 4471, 0x0010 }, { 4472, 0x5c10 }, + { 4477, 0x0343 }, { 4482, 0xfcc8 }, { 4491, 0xa1a5 }, { 4498, 0x0580 }, + { 4501, 0x8433 }, { 4507, 0x0400 }, { 4508, 0x0080 }, { 4509, 0x6e08 }, + { 4515, 0x2a4b }, { 4522, 0x8126 }, { 4527, 0xaad8 }, { 4535, 0x2901 }, + /* 0x7a00 */ + { 4539, 0x684d }, { 4546, 0x4490 }, { 4550, 0x0009 }, { 4552, 0xba88 }, + { 4559, 0x0040 }, { 4560, 0x0082 }, { 4562, 0x0000 }, { 4562, 0x87d1 }, + { 4570, 0x215b }, { 4577, 0xb1e6 }, { 4586, 0x3161 }, { 4592, 0x8008 }, + { 4594, 0x0800 }, { 4595, 0xc240 }, { 4599, 0xa069 }, { 4605, 0xa600 }, + /* 0x7b00 */ + { 4609, 0x8d58 }, { 4616, 0x4a32 }, { 4622, 0x5d71 }, { 4631, 0x550a }, + { 4637, 0x9aa0 }, { 4643, 0x2d57 }, { 4652, 0x4005 }, { 4655, 0x4aa6 }, + { 4662, 0x2021 }, { 4665, 0x30b1 }, { 4671, 0x3fc6 }, { 4681, 0x0112 }, + { 4684, 0x10c2 }, { 4688, 0x260a }, { 4693, 0x4462 }, { 4698, 0x5082 }, + /* 0x7c00 */ + { 4702, 0x9880 }, { 4706, 0x8040 }, { 4708, 0x04c0 }, { 4711, 0x8100 }, + { 4713, 0x2003 }, { 4716, 0x0000 }, { 4716, 0x0000 }, { 4716, 0x3818 }, + { 4721, 0x0200 }, { 4722, 0xf1a6 }, { 4731, 0x4434 }, { 4736, 0x720e }, + { 4743, 0x35a2 }, { 4750, 0x92e0 }, { 4756, 0x8101 }, { 4759, 0x0900 }, + /* 0x7d00 */ + { 4761, 0x0400 }, { 4762, 0x0000 }, { 4762, 0x8885 }, { 4767, 0x0000 }, + { 4767, 0x0000 }, { 4767, 0x0000 }, { 4767, 0x4000 }, { 4768, 0x0080 }, + { 4769, 0x0000 }, { 4769, 0x0000 }, { 4769, 0x4040 }, { 4771, 0x0000 }, + { 4771, 0x0000 }, { 4771, 0x0000 }, { 4771, 0x0000 }, { 4771, 0x0000 }, + /* 0x7e00 */ + { 4771, 0x0000 }, { 4771, 0x0000 }, { 4771, 0x0000 }, { 4771, 0x0800 }, + { 4772, 0x0082 }, { 4774, 0x0000 }, { 4774, 0x0000 }, { 4774, 0x0000 }, + { 4774, 0x0004 }, { 4775, 0x8800 }, { 4777, 0xbfff }, { 4792, 0xe7ef }, + { 4805, 0xffff }, { 4821, 0xffbf }, { 4836, 0xefef }, { 4850, 0xfdff }, + /* 0x7f00 */ + { 4865, 0xfbff }, { 4880, 0xbffe }, { 4894, 0xffff }, { 4910, 0x057f }, + { 4919, 0x0034 }, { 4922, 0x85b3 }, { 4930, 0x4706 }, { 4936, 0x4216 }, + { 4941, 0x5402 }, { 4945, 0xe410 }, { 4950, 0x8092 }, { 4954, 0xb305 }, + { 4961, 0x5422 }, { 4966, 0x8130 }, { 4970, 0x4263 }, { 4976, 0x180b }, + /* 0x8000 */ + { 4981, 0x387b }, { 4990, 0x13f5 }, { 4999, 0x07e5 }, { 5007, 0xa9ea }, + { 5016, 0x3c4c }, { 5023, 0x0514 }, { 5027, 0x0600 }, { 5029, 0x8002 }, + { 5031, 0x1ad9 }, { 5039, 0xbd48 }, { 5047, 0xee37 }, { 5058, 0xf496 }, + { 5067, 0x705f }, { 5076, 0x7ec0 }, { 5084, 0xbfb2 }, { 5095, 0x355f }, + /* 0x8100 */ + { 5105, 0xe644 }, { 5112, 0x455f }, { 5121, 0x9000 }, { 5123, 0x4146 }, + { 5128, 0x1d40 }, { 5133, 0x063b }, { 5140, 0x62a1 }, { 5146, 0xfe13 }, + { 5156, 0x8505 }, { 5161, 0x3902 }, { 5166, 0x0548 }, { 5170, 0x0c08 }, + { 5173, 0x144f }, { 5180, 0x0000 }, { 5180, 0x3488 }, { 5185, 0x5818 }, + /* 0x8200 */ + { 5190, 0x3077 }, { 5198, 0xd815 }, { 5205, 0xbd0e }, { 5214, 0x4bfb }, + { 5225, 0x8a90 }, { 5230, 0x8500 }, { 5233, 0xc100 }, { 5236, 0xe61d }, + { 5245, 0xed14 }, { 5253, 0xb386 }, { 5261, 0xff72 }, { 5273, 0x639b }, + { 5282, 0xfd92 }, { 5292, 0xd9be }, { 5303, 0x887b }, { 5311, 0x0a92 }, + /* 0x8300 */ + { 5316, 0xd3fe }, { 5328, 0x1cb2 }, { 5335, 0xb980 }, { 5341, 0x177a }, + { 5350, 0x82c9 }, { 5356, 0xdc17 }, { 5365, 0xfffb }, { 5380, 0x3980 }, + { 5385, 0x4260 }, { 5389, 0x590c }, { 5395, 0x0f01 }, { 5400, 0x37df }, + { 5412, 0x94a3 }, { 5419, 0xb150 }, { 5425, 0x0623 }, { 5430, 0x2307 }, + /* 0x8400 */ + { 5436, 0xf85a }, { 5445, 0x3102 }, { 5449, 0x01f0 }, { 5454, 0x3102 }, + { 5458, 0x0040 }, { 5459, 0x1e82 }, { 5465, 0x3a0a }, { 5471, 0x056a }, + { 5477, 0x5b84 }, { 5484, 0x1280 }, { 5487, 0x8002 }, { 5489, 0xa714 }, + { 5496, 0x2612 }, { 5501, 0xa04b }, { 5507, 0x1069 }, { 5512, 0x9001 }, + /* 0x8500 */ + { 5515, 0x1000 }, { 5516, 0x848a }, { 5521, 0x1802 }, { 5524, 0x3f80 }, + { 5531, 0x0708 }, { 5535, 0x4240 }, { 5538, 0x0110 }, { 5540, 0x4e14 }, + { 5546, 0x80b0 }, { 5550, 0x1800 }, { 5552, 0xc510 }, { 5557, 0x0281 }, + { 5560, 0x8202 }, { 5563, 0x1029 }, { 5567, 0x0210 }, { 5569, 0x8800 }, + /* 0x8600 */ + { 5571, 0x0020 }, { 5572, 0x0042 }, { 5574, 0x0280 }, { 5576, 0x1100 }, + { 5578, 0xe000 }, { 5581, 0x4413 }, { 5586, 0x5804 }, { 5590, 0xfe02 }, + { 5598, 0x3c07 }, { 5605, 0x3028 }, { 5609, 0x9798 }, { 5617, 0x0473 }, + { 5623, 0xced1 }, { 5632, 0xcb13 }, { 5640, 0x6210 }, { 5644, 0x431f }, + /* 0x8700 */ + { 5652, 0x278d }, { 5660, 0x55ac }, { 5668, 0x422e }, { 5674, 0xc892 }, + { 5680, 0x5380 }, { 5685, 0x0288 }, { 5688, 0x4039 }, { 5693, 0x7851 }, + { 5700, 0x292c }, { 5706, 0x8088 }, { 5709, 0xb900 }, { 5714, 0x2428 }, + { 5718, 0x0c41 }, { 5722, 0x080e }, { 5726, 0x4421 }, { 5730, 0x4200 }, + /* 0x8800 */ + { 5732, 0x0408 }, { 5734, 0x0868 }, { 5738, 0x0006 }, { 5740, 0x1204 }, + { 5743, 0x3031 }, { 5748, 0x0290 }, { 5751, 0x5b3e }, { 5761, 0xe085 }, + { 5767, 0x2936 }, { 5774, 0x1044 }, { 5777, 0x2814 }, { 5781, 0x1082 }, + { 5784, 0x4266 }, { 5790, 0x8334 }, { 5796, 0x013c }, { 5801, 0x531b }, + /* 0x8900 */ + { 5809, 0x0404 }, { 5811, 0x0e0d }, { 5817, 0x0c22 }, { 5821, 0x0051 }, + { 5824, 0x0012 }, { 5826, 0xc000 }, { 5828, 0x0040 }, { 5829, 0x8800 }, + { 5831, 0x004a }, { 5834, 0x0000 }, { 5834, 0x0000 }, { 5834, 0x0000 }, + { 5834, 0xdff6 }, { 5847, 0x5447 }, { 5854, 0x8868 }, { 5859, 0x0008 }, + /* 0x8a00 */ + { 5860, 0x0081 }, { 5862, 0x0000 }, { 5862, 0x0000 }, { 5862, 0x4000 }, + { 5863, 0x0100 }, { 5864, 0x0000 }, { 5864, 0x0000 }, { 5864, 0x0200 }, + { 5865, 0x0600 }, { 5867, 0x0008 }, { 5868, 0x0000 }, { 5868, 0x0000 }, + { 5868, 0x0000 }, { 5868, 0x0000 }, { 5868, 0x0000 }, { 5868, 0x0000 }, + /* 0x8b00 */ + { 5868, 0x0080 }, { 5869, 0x0000 }, { 5869, 0x0040 }, { 5870, 0x0000 }, + { 5870, 0x0000 }, { 5870, 0x0000 }, { 5870, 0x1040 }, { 5872, 0x0000 }, + { 5872, 0x0000 }, { 5872, 0x0000 }, { 5872, 0xefff }, { 5887, 0xf7fd }, + { 5901, 0xff7f }, { 5916, 0xfffe }, { 5931, 0xfbff }, { 5946, 0xffff }, + /* 0x8c00 */ + { 5962, 0xfdff }, { 5977, 0xbfff }, { 5992, 0xffff }, { 6008, 0x00ff }, + { 6016, 0x12c2 }, { 6021, 0x0420 }, { 6023, 0x0c06 }, { 6027, 0x0708 }, + { 6031, 0x1624 }, { 6036, 0x0110 }, { 6038, 0x0000 }, { 6038, 0x0000 }, + { 6038, 0x0000 }, { 6038, 0x0000 }, { 6038, 0x0000 }, { 6038, 0x0000 }, + /* 0x8d00 */ + { 6038, 0x0000 }, { 6038, 0xe000 }, { 6041, 0xfffe }, { 6056, 0xffff }, + { 6072, 0xffff }, { 6088, 0x7f79 }, { 6100, 0x28df }, { 6109, 0x00f9 }, + { 6115, 0x0c32 }, { 6120, 0x8012 }, { 6123, 0x0008 }, { 6124, 0xd53a }, + { 6133, 0xd858 }, { 6140, 0xecc2 }, { 6148, 0x9d18 }, { 6155, 0x2fa8 }, + /* 0x8e00 */ + { 6163, 0x9620 }, { 6168, 0xe010 }, { 6172, 0xd60c }, { 6179, 0x2622 }, + { 6184, 0x0f97 }, { 6193, 0x0206 }, { 6196, 0xb240 }, { 6201, 0x9055 }, + { 6207, 0x80a2 }, { 6211, 0x5011 }, { 6215, 0x9800 }, { 6218, 0x0404 }, + { 6220, 0x4000 }, { 6221, 0x0000 }, { 6221, 0x0000 }, { 6221, 0x0000 }, + /* 0x8f00 */ + { 6221, 0x0000 }, { 6221, 0x0000 }, { 6221, 0x0000 }, { 6221, 0x0000 }, + { 6221, 0x0000 }, { 6221, 0x0000 }, { 6221, 0xfbc0 }, { 6230, 0xffff }, + { 6246, 0xeffe }, { 6260, 0xdffb }, { 6274, 0x0b08 }, { 6278, 0x6243 }, + { 6284, 0x41b6 }, { 6291, 0xfb3b }, { 6303, 0x6f74 }, { 6313, 0x2389 }, + /* 0x9000 */ + { 6319, 0xae7f }, { 6331, 0xecd7 }, { 6342, 0xe047 }, { 6349, 0x5960 }, + { 6355, 0xa096 }, { 6361, 0x098f }, { 6368, 0x612c }, { 6374, 0xa030 }, + { 6378, 0x090d }, { 6383, 0x2aaa }, { 6390, 0xd44e }, { 6398, 0x4f7b }, + { 6409, 0xc4b2 }, { 6416, 0x388b }, { 6423, 0xa9c6 }, { 6431, 0x6110 }, + /* 0x9100 */ + { 6435, 0x0014 }, { 6437, 0x4200 }, { 6439, 0x800c }, { 6442, 0x0202 }, + { 6444, 0xfe48 }, { 6453, 0x6485 }, { 6459, 0xd63e }, { 6469, 0xe3f7 }, + { 6481, 0x3aa0 }, { 6487, 0x0c07 }, { 6492, 0xe40c }, { 6498, 0x0430 }, + { 6501, 0xf680 }, { 6508, 0x1002 }, { 6510, 0x0000 }, { 6510, 0x0000 }, + /* 0x9200 */ + { 6510, 0x0000 }, { 6510, 0x0000 }, { 6510, 0x0000 }, { 6510, 0x0000 }, + { 6510, 0x0000 }, { 6510, 0x0000 }, { 6510, 0x0000 }, { 6510, 0x0010 }, + { 6511, 0x4000 }, { 6512, 0x0000 }, { 6512, 0x4000 }, { 6513, 0x0000 }, + { 6513, 0x0100 }, { 6514, 0x0000 }, { 6514, 0x0000 }, { 6514, 0x0000 }, + /* 0x9300 */ + { 6514, 0x0000 }, { 6514, 0x0000 }, { 6514, 0x0000 }, { 6514, 0x4000 }, + { 6515, 0x0000 }, { 6515, 0x0000 }, { 6515, 0x0400 }, { 6516, 0x0000 }, + { 6516, 0x8000 }, { 6517, 0x0000 }, { 6517, 0x0000 }, { 6517, 0x0000 }, + { 6517, 0x0400 }, { 6518, 0x0040 }, { 6519, 0x0000 }, { 6519, 0x0000 }, + /* 0x9400 */ + { 6519, 0x0000 }, { 6519, 0x0000 }, { 6519, 0x0000 }, { 6519, 0x4000 }, + { 6520, 0x0000 }, { 6520, 0x0000 }, { 6520, 0x0800 }, { 6521, 0x0000 }, + { 6521, 0xffe0 }, { 6532, 0xfebd }, { 6545, 0xffff }, { 6561, 0xffff }, + { 6577, 0x7f7f }, { 6591, 0xfbe7 }, { 6604, 0xffbf }, { 6619, 0xf7ff }, + /* 0x9500 */ + { 6634, 0xffff }, { 6650, 0xefff }, { 6665, 0xff7e }, { 6679, 0xdff7 }, + { 6693, 0xf6f7 }, { 6706, 0xfbdf }, { 6720, 0xbffe }, { 6734, 0x804f }, + { 6740, 0x0000 }, { 6740, 0x0000 }, { 6740, 0x0000 }, { 6740, 0x0000 }, + { 6740, 0x0000 }, { 6740, 0x0000 }, { 6740, 0xef00 }, { 6747, 0x7fff }, + /* 0x9600 */ + { 6762, 0xff7f }, { 6777, 0xb6f7 }, { 6789, 0x4406 }, { 6793, 0xb87e }, + { 6803, 0x3bf5 }, { 6814, 0x8831 }, { 6819, 0x1796 }, { 6827, 0x00f4 }, + { 6832, 0xa960 }, { 6838, 0x1391 }, { 6844, 0x0080 }, { 6845, 0x7249 }, + { 6852, 0xf2f3 }, { 6863, 0x0024 }, { 6865, 0x8701 }, { 6870, 0x42c8 }, + /* 0x9700 */ + { 6875, 0xe3d3 }, { 6885, 0x5048 }, { 6889, 0x2400 }, { 6891, 0x4305 }, + { 6896, 0x0000 }, { 6896, 0x4a4c }, { 6902, 0x0227 }, { 6907, 0x1058 }, + { 6911, 0x2820 }, { 6914, 0x0116 }, { 6918, 0xa809 }, { 6923, 0x0014 }, + { 6925, 0x0000 }, { 6925, 0x0000 }, { 6925, 0x3ec0 }, { 6932, 0x0068 }, + /* 0x9800 */ + { 6935, 0x0000 }, { 6935, 0x0000 }, { 6935, 0x0000 }, { 6935, 0x0000 }, + { 6935, 0x0000 }, { 6935, 0x0000 }, { 6935, 0x0000 }, { 6935, 0xffe0 }, + { 6946, 0xb7ff }, { 6960, 0xfddb }, { 6973, 0x00f7 }, { 6980, 0x0000 }, + { 6980, 0x4000 }, { 6981, 0xc72e }, { 6990, 0x0180 }, { 6992, 0x0000 }, + /* 0x9900 */ + { 6992, 0x2000 }, { 6993, 0x0001 }, { 6994, 0x4000 }, { 6995, 0x0000 }, + { 6995, 0x0000 }, { 6995, 0x0030 }, { 6997, 0xffa8 }, { 7008, 0xb4f7 }, + { 7019, 0xadf3 }, { 7030, 0x03ff }, { 7040, 0x0120 }, { 7042, 0x0000 }, + { 7042, 0x0000 }, { 7042, 0x0000 }, { 7042, 0x0000 }, { 7042, 0x0000 }, + /* 0x9a00 */ + { 7042, 0x0000 }, { 7042, 0x0000 }, { 7042, 0x0000 }, { 7042, 0x0000 }, + { 7042, 0x0000 }, { 7042, 0x0000 }, { 7042, 0xf000 }, { 7046, 0xfffb }, + { 7061, 0x9df7 }, { 7073, 0xfdcf }, { 7086, 0x01bf }, { 7094, 0x15c3 }, + { 7101, 0x1827 }, { 7107, 0x810a }, { 7111, 0xa842 }, { 7116, 0x0a00 }, + /* 0x9b00 */ + { 7118, 0x8108 }, { 7121, 0x8008 }, { 7123, 0x8008 }, { 7125, 0x1804 }, + { 7128, 0xa3be }, { 7138, 0x0012 }, { 7140, 0x0000 }, { 7140, 0x0000 }, + { 7140, 0x0000 }, { 7140, 0x0000 }, { 7140, 0x0000 }, { 7140, 0x0000 }, + { 7140, 0x0000 }, { 7140, 0x0000 }, { 7140, 0x0000 }, { 7140, 0x0000 }, + /* 0x9c00 */ + { 7140, 0x0000 }, { 7140, 0x0000 }, { 7140, 0x0000 }, { 7140, 0x0000 }, + { 7140, 0x0000 }, { 7140, 0x0000 }, { 7140, 0x0000 }, { 7140, 0x9000 }, + { 7142, 0x69e6 }, { 7151, 0xdc37 }, { 7161, 0x6bff }, { 7174, 0x3dff }, + { 7187, 0xfcf8 }, { 7198, 0xf3f9 }, { 7210, 0x0004 }, +}; +static const Summary16 gb2312_uni2indx_page9e[27] = { + /* 0x9e00 */ + { 7211, 0x0000 }, { 7211, 0x8000 }, { 7212, 0xbf6f }, { 7225, 0xe7ee }, + { 7237, 0xdffe }, { 7251, 0x5da2 }, { 7259, 0x3fd8 }, { 7269, 0xc00b }, + { 7274, 0x0984 }, { 7278, 0xa00c }, { 7282, 0x0040 }, { 7283, 0x6910 }, + { 7288, 0xe210 }, { 7293, 0xb912 }, { 7300, 0x86a5 }, { 7307, 0x5a00 }, + /* 0x9f00 */ + { 7311, 0x6800 }, { 7314, 0x0289 }, { 7318, 0x9005 }, { 7322, 0x6a80 }, + { 7327, 0x0010 }, { 7328, 0x0003 }, { 7330, 0x0000 }, { 7330, 0x8000 }, + { 7331, 0x1ff9 }, { 7342, 0x8e00 }, { 7346, 0x0001 }, +}; +static const Summary16 gb2312_uni2indx_pageff[15] = { + /* 0xff00 */ + { 7347, 0xfffe }, { 7362, 0xffff }, { 7378, 0xffff }, { 7394, 0xffff }, + { 7410, 0xffff }, { 7426, 0x7fff }, { 7441, 0x0000 }, { 7441, 0x0000 }, + { 7441, 0x0000 }, { 7441, 0x0000 }, { 7441, 0x0000 }, { 7441, 0x0000 }, + { 7441, 0x0000 }, { 7441, 0x0000 }, { 7441, 0x002b }, +}; + +static int +gb2312_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc >= 0x0000 && wc < 0x0460) + summary = &gb2312_uni2indx_page00[(wc>>4)]; + else if (wc >= 0x2000 && wc < 0x2650) + summary = &gb2312_uni2indx_page20[(wc>>4)-0x200]; + else if (wc >= 0x3000 && wc < 0x3230) + summary = &gb2312_uni2indx_page30[(wc>>4)-0x300]; + else if (wc >= 0x4e00 && wc < 0x9cf0) + summary = &gb2312_uni2indx_page4e[(wc>>4)-0x4e0]; + else if (wc >= 0x9e00 && wc < 0x9fb0) + summary = &gb2312_uni2indx_page9e[(wc>>4)-0x9e0]; + else if (wc >= 0xff00 && wc < 0xfff0) + summary = &gb2312_uni2indx_pageff[(wc>>4)-0xff0]; + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = gb2312_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/gbk.h b/graf2d/win32gdk/gdk/src/iconv/gbk.h new file mode 100644 index 0000000000000..b6ff526284e6f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/gbk.h @@ -0,0 +1,169 @@ +/* + * Copyright (C) 1999-2001, 2005, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GBK + */ + +/* + * GBK, as described in Ken Lunde's book, is an extension of GB 2312-1980 + * (shifted by adding 0x8080 to the range 0xA1A1..0xFEFE, as used in EUC-CN). + * It adds the following ranges: + * + * (part of GBK/1) 0xA2A1-0xA2AA Small Roman numerals + * GBK/3 0x{81-A0}{40-7E,80-FE} 6080 new characters, all in Unicode + * GBK/4 0x{AA-FE}{40-7E,80-A0} 8160 new characters, 8080 in Unicode + * GBK/5 0x{A8-A9}{40-7E,80-A0} 166 new characters, 153 in Unicode + * + * Furthermore, all four tables I have looked at + * - the CP936 table by Microsoft, found on ftp.unicode.org in 1999, + * - the GBK table by Sun, investigated on a Solaris 2.7 machine, + * - the GBK tables by CWEX, found in the Big5+ package, + * - the GB18030 standard (second printing), + * agree in the following extensions. (Ken Lunde must have overlooked these + * differences between GB2312 and GBK. Also, the CWEX tables have additional + * differences.) + * + * 1. Some characters in the GB2312 range are defined differently: + * + * code GB2312 GBK + * 0xA1A4 0x30FB # KATAKANA MIDDLE DOT 0x00B7 # MIDDLE DOT + * 0xA1AA 0x2015 # HORIZONTAL BAR 0x2014 # EM DASH + * + * 2. 19 characters added in the range 0xA6E0-0xA6F5. + * + * 3. 4 characters added in the range 0xA8BB-0xA8C0. + * + * CP936 as of 1999 was identical to GBK. However, since 1999, Microsoft has + * added new mappings to CP936... + */ + +#include "gbkext1.h" +#include "gbkext2.h" +#include "gbkext_inv.h" +#include "cp936ext.h" + +static int +gbk_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + + if (c >= 0x81 && c < 0xff) { + if (n < 2) + return RET_TOOFEW(0); + if (c >= 0xa1 && c <= 0xf7) { + unsigned char c2 = s[1]; + if (c == 0xa1) { + if (c2 == 0xa4) { + *pwc = 0x00b7; + return 2; + } + if (c2 == 0xaa) { + *pwc = 0x2014; + return 2; + } + } + if (c2 >= 0xa1 && c2 < 0xff) { + unsigned char buf[2]; + int ret; + buf[0] = c-0x80; buf[1] = c2-0x80; + ret = gb2312_mbtowc(conv,pwc,buf,2); + if (ret != RET_ILSEQ) + return ret; + buf[0] = c; buf[1] = c2; + ret = cp936ext_mbtowc(conv,pwc,buf,2); + if (ret != RET_ILSEQ) + return ret; + } + } + if (c >= 0x81 && c <= 0xa0) + return gbkext1_mbtowc(conv,pwc,s,2); + if (c >= 0xa8 && c <= 0xfe) + return gbkext2_mbtowc(conv,pwc,s,2); + if (c == 0xa2) { + unsigned char c2 = s[1]; + if (c2 >= 0xa1 && c2 <= 0xaa) { + *pwc = 0x2170+(c2-0xa1); + return 2; + } + } + } + return RET_ILSEQ; +} + +static int +gbk_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + if (wc != 0x30fb && wc != 0x2015) { + ret = gb2312_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]+0x80; + r[1] = buf[1]+0x80; + return 2; + } + } + ret = gbkext_inv_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]; + r[1] = buf[1]; + return 2; + } + if (wc >= 0x2170 && wc <= 0x2179) { + if (n < 2) + return RET_TOOSMALL; + r[0] = 0xa2; + r[1] = 0xa1 + (wc-0x2170); + return 2; + } + ret = cp936ext_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]; + r[1] = buf[1]; + return 2; + } + if (wc == 0x00b7) { + if (n < 2) + return RET_TOOSMALL; + r[0] = 0xa1; + r[1] = 0xa4; + return 2; + } + if (wc == 0x2014) { + if (n < 2) + return RET_TOOSMALL; + r[0] = 0xa1; + r[1] = 0xaa; + return 2; + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/gbkext1.h b/graf2d/win32gdk/gdk/src/iconv/gbkext1.h new file mode 100644 index 0000000000000..d244c7695e269 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/gbkext1.h @@ -0,0 +1,853 @@ +/* + * Copyright (C) 1999-2000 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GBK/3 extensions + */ + +static const unsigned short gbkext1_2uni_page81[6080] = { + /* 0x81 */ + 0x4e02, 0x4e04, 0x4e05, 0x4e06, 0x4e0f, 0x4e12, 0x4e17, 0x4e1f, + 0x4e20, 0x4e21, 0x4e23, 0x4e26, 0x4e29, 0x4e2e, 0x4e2f, 0x4e31, + 0x4e33, 0x4e35, 0x4e37, 0x4e3c, 0x4e40, 0x4e41, 0x4e42, 0x4e44, + 0x4e46, 0x4e4a, 0x4e51, 0x4e55, 0x4e57, 0x4e5a, 0x4e5b, 0x4e62, + 0x4e63, 0x4e64, 0x4e65, 0x4e67, 0x4e68, 0x4e6a, 0x4e6b, 0x4e6c, + 0x4e6d, 0x4e6e, 0x4e6f, 0x4e72, 0x4e74, 0x4e75, 0x4e76, 0x4e77, + 0x4e78, 0x4e79, 0x4e7a, 0x4e7b, 0x4e7c, 0x4e7d, 0x4e7f, 0x4e80, + 0x4e81, 0x4e82, 0x4e83, 0x4e84, 0x4e85, 0x4e87, 0x4e8a, 0x4e90, + 0x4e96, 0x4e97, 0x4e99, 0x4e9c, 0x4e9d, 0x4e9e, 0x4ea3, 0x4eaa, + 0x4eaf, 0x4eb0, 0x4eb1, 0x4eb4, 0x4eb6, 0x4eb7, 0x4eb8, 0x4eb9, + 0x4ebc, 0x4ebd, 0x4ebe, 0x4ec8, 0x4ecc, 0x4ecf, 0x4ed0, 0x4ed2, + 0x4eda, 0x4edb, 0x4edc, 0x4ee0, 0x4ee2, 0x4ee6, 0x4ee7, 0x4ee9, + 0x4eed, 0x4eee, 0x4eef, 0x4ef1, 0x4ef4, 0x4ef8, 0x4ef9, 0x4efa, + 0x4efc, 0x4efe, 0x4f00, 0x4f02, 0x4f03, 0x4f04, 0x4f05, 0x4f06, + 0x4f07, 0x4f08, 0x4f0b, 0x4f0c, 0x4f12, 0x4f13, 0x4f14, 0x4f15, + 0x4f16, 0x4f1c, 0x4f1d, 0x4f21, 0x4f23, 0x4f28, 0x4f29, 0x4f2c, + 0x4f2d, 0x4f2e, 0x4f31, 0x4f33, 0x4f35, 0x4f37, 0x4f39, 0x4f3b, + 0x4f3e, 0x4f3f, 0x4f40, 0x4f41, 0x4f42, 0x4f44, 0x4f45, 0x4f47, + 0x4f48, 0x4f49, 0x4f4a, 0x4f4b, 0x4f4c, 0x4f52, 0x4f54, 0x4f56, + 0x4f61, 0x4f62, 0x4f66, 0x4f68, 0x4f6a, 0x4f6b, 0x4f6d, 0x4f6e, + 0x4f71, 0x4f72, 0x4f75, 0x4f77, 0x4f78, 0x4f79, 0x4f7a, 0x4f7d, + 0x4f80, 0x4f81, 0x4f82, 0x4f85, 0x4f86, 0x4f87, 0x4f8a, 0x4f8c, + 0x4f8e, 0x4f90, 0x4f92, 0x4f93, 0x4f95, 0x4f96, 0x4f98, 0x4f99, + 0x4f9a, 0x4f9c, 0x4f9e, 0x4f9f, 0x4fa1, 0x4fa2, + /* 0x82 */ + 0x4fa4, 0x4fab, 0x4fad, 0x4fb0, 0x4fb1, 0x4fb2, 0x4fb3, 0x4fb4, + 0x4fb6, 0x4fb7, 0x4fb8, 0x4fb9, 0x4fba, 0x4fbb, 0x4fbc, 0x4fbd, + 0x4fbe, 0x4fc0, 0x4fc1, 0x4fc2, 0x4fc6, 0x4fc7, 0x4fc8, 0x4fc9, + 0x4fcb, 0x4fcc, 0x4fcd, 0x4fd2, 0x4fd3, 0x4fd4, 0x4fd5, 0x4fd6, + 0x4fd9, 0x4fdb, 0x4fe0, 0x4fe2, 0x4fe4, 0x4fe5, 0x4fe7, 0x4feb, + 0x4fec, 0x4ff0, 0x4ff2, 0x4ff4, 0x4ff5, 0x4ff6, 0x4ff7, 0x4ff9, + 0x4ffb, 0x4ffc, 0x4ffd, 0x4fff, 0x5000, 0x5001, 0x5002, 0x5003, + 0x5004, 0x5005, 0x5006, 0x5007, 0x5008, 0x5009, 0x500a, 0x500b, + 0x500e, 0x5010, 0x5011, 0x5013, 0x5015, 0x5016, 0x5017, 0x501b, + 0x501d, 0x501e, 0x5020, 0x5022, 0x5023, 0x5024, 0x5027, 0x502b, + 0x502f, 0x5030, 0x5031, 0x5032, 0x5033, 0x5034, 0x5035, 0x5036, + 0x5037, 0x5038, 0x5039, 0x503b, 0x503d, 0x503f, 0x5040, 0x5041, + 0x5042, 0x5044, 0x5045, 0x5046, 0x5049, 0x504a, 0x504b, 0x504d, + 0x5050, 0x5051, 0x5052, 0x5053, 0x5054, 0x5056, 0x5057, 0x5058, + 0x5059, 0x505b, 0x505d, 0x505e, 0x505f, 0x5060, 0x5061, 0x5062, + 0x5063, 0x5064, 0x5066, 0x5067, 0x5068, 0x5069, 0x506a, 0x506b, + 0x506d, 0x506e, 0x506f, 0x5070, 0x5071, 0x5072, 0x5073, 0x5074, + 0x5075, 0x5078, 0x5079, 0x507a, 0x507c, 0x507d, 0x5081, 0x5082, + 0x5083, 0x5084, 0x5086, 0x5087, 0x5089, 0x508a, 0x508b, 0x508c, + 0x508e, 0x508f, 0x5090, 0x5091, 0x5092, 0x5093, 0x5094, 0x5095, + 0x5096, 0x5097, 0x5098, 0x5099, 0x509a, 0x509b, 0x509c, 0x509d, + 0x509e, 0x509f, 0x50a0, 0x50a1, 0x50a2, 0x50a4, 0x50a6, 0x50aa, + 0x50ab, 0x50ad, 0x50ae, 0x50af, 0x50b0, 0x50b1, 0x50b3, 0x50b4, + 0x50b5, 0x50b6, 0x50b7, 0x50b8, 0x50b9, 0x50bc, + /* 0x83 */ + 0x50bd, 0x50be, 0x50bf, 0x50c0, 0x50c1, 0x50c2, 0x50c3, 0x50c4, + 0x50c5, 0x50c6, 0x50c7, 0x50c8, 0x50c9, 0x50ca, 0x50cb, 0x50cc, + 0x50cd, 0x50ce, 0x50d0, 0x50d1, 0x50d2, 0x50d3, 0x50d4, 0x50d5, + 0x50d7, 0x50d8, 0x50d9, 0x50db, 0x50dc, 0x50dd, 0x50de, 0x50df, + 0x50e0, 0x50e1, 0x50e2, 0x50e3, 0x50e4, 0x50e5, 0x50e8, 0x50e9, + 0x50ea, 0x50eb, 0x50ef, 0x50f0, 0x50f1, 0x50f2, 0x50f4, 0x50f6, + 0x50f7, 0x50f8, 0x50f9, 0x50fa, 0x50fc, 0x50fd, 0x50fe, 0x50ff, + 0x5100, 0x5101, 0x5102, 0x5103, 0x5104, 0x5105, 0x5108, 0x5109, + 0x510a, 0x510c, 0x510d, 0x510e, 0x510f, 0x5110, 0x5111, 0x5113, + 0x5114, 0x5115, 0x5116, 0x5117, 0x5118, 0x5119, 0x511a, 0x511b, + 0x511c, 0x511d, 0x511e, 0x511f, 0x5120, 0x5122, 0x5123, 0x5124, + 0x5125, 0x5126, 0x5127, 0x5128, 0x5129, 0x512a, 0x512b, 0x512c, + 0x512d, 0x512e, 0x512f, 0x5130, 0x5131, 0x5132, 0x5133, 0x5134, + 0x5135, 0x5136, 0x5137, 0x5138, 0x5139, 0x513a, 0x513b, 0x513c, + 0x513d, 0x513e, 0x5142, 0x5147, 0x514a, 0x514c, 0x514e, 0x514f, + 0x5150, 0x5152, 0x5153, 0x5157, 0x5158, 0x5159, 0x515b, 0x515d, + 0x515e, 0x515f, 0x5160, 0x5161, 0x5163, 0x5164, 0x5166, 0x5167, + 0x5169, 0x516a, 0x516f, 0x5172, 0x517a, 0x517e, 0x517f, 0x5183, + 0x5184, 0x5186, 0x5187, 0x518a, 0x518b, 0x518e, 0x518f, 0x5190, + 0x5191, 0x5193, 0x5194, 0x5198, 0x519a, 0x519d, 0x519e, 0x519f, + 0x51a1, 0x51a3, 0x51a6, 0x51a7, 0x51a8, 0x51a9, 0x51aa, 0x51ad, + 0x51ae, 0x51b4, 0x51b8, 0x51b9, 0x51ba, 0x51be, 0x51bf, 0x51c1, + 0x51c2, 0x51c3, 0x51c5, 0x51c8, 0x51ca, 0x51cd, 0x51ce, 0x51d0, + 0x51d2, 0x51d3, 0x51d4, 0x51d5, 0x51d6, 0x51d7, + /* 0x84 */ + 0x51d8, 0x51d9, 0x51da, 0x51dc, 0x51de, 0x51df, 0x51e2, 0x51e3, + 0x51e5, 0x51e6, 0x51e7, 0x51e8, 0x51e9, 0x51ea, 0x51ec, 0x51ee, + 0x51f1, 0x51f2, 0x51f4, 0x51f7, 0x51fe, 0x5204, 0x5205, 0x5209, + 0x520b, 0x520c, 0x520f, 0x5210, 0x5213, 0x5214, 0x5215, 0x521c, + 0x521e, 0x521f, 0x5221, 0x5222, 0x5223, 0x5225, 0x5226, 0x5227, + 0x522a, 0x522c, 0x522f, 0x5231, 0x5232, 0x5234, 0x5235, 0x523c, + 0x523e, 0x5244, 0x5245, 0x5246, 0x5247, 0x5248, 0x5249, 0x524b, + 0x524e, 0x524f, 0x5252, 0x5253, 0x5255, 0x5257, 0x5258, 0x5259, + 0x525a, 0x525b, 0x525d, 0x525f, 0x5260, 0x5262, 0x5263, 0x5264, + 0x5266, 0x5268, 0x526b, 0x526c, 0x526d, 0x526e, 0x5270, 0x5271, + 0x5273, 0x5274, 0x5275, 0x5276, 0x5277, 0x5278, 0x5279, 0x527a, + 0x527b, 0x527c, 0x527e, 0x5280, 0x5283, 0x5284, 0x5285, 0x5286, + 0x5287, 0x5289, 0x528a, 0x528b, 0x528c, 0x528d, 0x528e, 0x528f, + 0x5291, 0x5292, 0x5294, 0x5295, 0x5296, 0x5297, 0x5298, 0x5299, + 0x529a, 0x529c, 0x52a4, 0x52a5, 0x52a6, 0x52a7, 0x52ae, 0x52af, + 0x52b0, 0x52b4, 0x52b5, 0x52b6, 0x52b7, 0x52b8, 0x52b9, 0x52ba, + 0x52bb, 0x52bc, 0x52bd, 0x52c0, 0x52c1, 0x52c2, 0x52c4, 0x52c5, + 0x52c6, 0x52c8, 0x52ca, 0x52cc, 0x52cd, 0x52ce, 0x52cf, 0x52d1, + 0x52d3, 0x52d4, 0x52d5, 0x52d7, 0x52d9, 0x52da, 0x52db, 0x52dc, + 0x52dd, 0x52de, 0x52e0, 0x52e1, 0x52e2, 0x52e3, 0x52e5, 0x52e6, + 0x52e7, 0x52e8, 0x52e9, 0x52ea, 0x52eb, 0x52ec, 0x52ed, 0x52ee, + 0x52ef, 0x52f1, 0x52f2, 0x52f3, 0x52f4, 0x52f5, 0x52f6, 0x52f7, + 0x52f8, 0x52fb, 0x52fc, 0x52fd, 0x5301, 0x5302, 0x5303, 0x5304, + 0x5307, 0x5309, 0x530a, 0x530b, 0x530c, 0x530e, + /* 0x85 */ + 0x5311, 0x5312, 0x5313, 0x5314, 0x5318, 0x531b, 0x531c, 0x531e, + 0x531f, 0x5322, 0x5324, 0x5325, 0x5327, 0x5328, 0x5329, 0x532b, + 0x532c, 0x532d, 0x532f, 0x5330, 0x5331, 0x5332, 0x5333, 0x5334, + 0x5335, 0x5336, 0x5337, 0x5338, 0x533c, 0x533d, 0x5340, 0x5342, + 0x5344, 0x5346, 0x534b, 0x534c, 0x534d, 0x5350, 0x5354, 0x5358, + 0x5359, 0x535b, 0x535d, 0x5365, 0x5368, 0x536a, 0x536c, 0x536d, + 0x5372, 0x5376, 0x5379, 0x537b, 0x537c, 0x537d, 0x537e, 0x5380, + 0x5381, 0x5383, 0x5387, 0x5388, 0x538a, 0x538e, 0x538f, 0x5390, + 0x5391, 0x5392, 0x5393, 0x5394, 0x5396, 0x5397, 0x5399, 0x539b, + 0x539c, 0x539e, 0x53a0, 0x53a1, 0x53a4, 0x53a7, 0x53aa, 0x53ab, + 0x53ac, 0x53ad, 0x53af, 0x53b0, 0x53b1, 0x53b2, 0x53b3, 0x53b4, + 0x53b5, 0x53b7, 0x53b8, 0x53b9, 0x53ba, 0x53bc, 0x53bd, 0x53be, + 0x53c0, 0x53c3, 0x53c4, 0x53c5, 0x53c6, 0x53c7, 0x53ce, 0x53cf, + 0x53d0, 0x53d2, 0x53d3, 0x53d5, 0x53da, 0x53dc, 0x53dd, 0x53de, + 0x53e1, 0x53e2, 0x53e7, 0x53f4, 0x53fa, 0x53fe, 0x53ff, 0x5400, + 0x5402, 0x5405, 0x5407, 0x540b, 0x5414, 0x5418, 0x5419, 0x541a, + 0x541c, 0x5422, 0x5424, 0x5425, 0x542a, 0x5430, 0x5433, 0x5436, + 0x5437, 0x543a, 0x543d, 0x543f, 0x5441, 0x5442, 0x5444, 0x5445, + 0x5447, 0x5449, 0x544c, 0x544d, 0x544e, 0x544f, 0x5451, 0x545a, + 0x545d, 0x545e, 0x545f, 0x5460, 0x5461, 0x5463, 0x5465, 0x5467, + 0x5469, 0x546a, 0x546b, 0x546c, 0x546d, 0x546e, 0x546f, 0x5470, + 0x5474, 0x5479, 0x547a, 0x547e, 0x547f, 0x5481, 0x5483, 0x5485, + 0x5487, 0x5488, 0x5489, 0x548a, 0x548d, 0x5491, 0x5493, 0x5497, + 0x5498, 0x549c, 0x549e, 0x549f, 0x54a0, 0x54a1, + /* 0x86 */ + 0x54a2, 0x54a5, 0x54ae, 0x54b0, 0x54b2, 0x54b5, 0x54b6, 0x54b7, + 0x54b9, 0x54ba, 0x54bc, 0x54be, 0x54c3, 0x54c5, 0x54ca, 0x54cb, + 0x54d6, 0x54d8, 0x54db, 0x54e0, 0x54e1, 0x54e2, 0x54e3, 0x54e4, + 0x54eb, 0x54ec, 0x54ef, 0x54f0, 0x54f1, 0x54f4, 0x54f5, 0x54f6, + 0x54f7, 0x54f8, 0x54f9, 0x54fb, 0x54fe, 0x5500, 0x5502, 0x5503, + 0x5504, 0x5505, 0x5508, 0x550a, 0x550b, 0x550c, 0x550d, 0x550e, + 0x5512, 0x5513, 0x5515, 0x5516, 0x5517, 0x5518, 0x5519, 0x551a, + 0x551c, 0x551d, 0x551e, 0x551f, 0x5521, 0x5525, 0x5526, 0x5528, + 0x5529, 0x552b, 0x552d, 0x5532, 0x5534, 0x5535, 0x5536, 0x5538, + 0x5539, 0x553a, 0x553b, 0x553d, 0x5540, 0x5542, 0x5545, 0x5547, + 0x5548, 0x554b, 0x554c, 0x554d, 0x554e, 0x554f, 0x5551, 0x5552, + 0x5553, 0x5554, 0x5557, 0x5558, 0x5559, 0x555a, 0x555b, 0x555d, + 0x555e, 0x555f, 0x5560, 0x5562, 0x5563, 0x5568, 0x5569, 0x556b, + 0x556f, 0x5570, 0x5571, 0x5572, 0x5573, 0x5574, 0x5579, 0x557a, + 0x557d, 0x557f, 0x5585, 0x5586, 0x558c, 0x558d, 0x558e, 0x5590, + 0x5592, 0x5593, 0x5595, 0x5596, 0x5597, 0x559a, 0x559b, 0x559e, + 0x55a0, 0x55a1, 0x55a2, 0x55a3, 0x55a4, 0x55a5, 0x55a6, 0x55a8, + 0x55a9, 0x55aa, 0x55ab, 0x55ac, 0x55ad, 0x55ae, 0x55af, 0x55b0, + 0x55b2, 0x55b4, 0x55b6, 0x55b8, 0x55ba, 0x55bc, 0x55bf, 0x55c0, + 0x55c1, 0x55c2, 0x55c3, 0x55c6, 0x55c7, 0x55c8, 0x55ca, 0x55cb, + 0x55ce, 0x55cf, 0x55d0, 0x55d5, 0x55d7, 0x55d8, 0x55d9, 0x55da, + 0x55db, 0x55de, 0x55e0, 0x55e2, 0x55e7, 0x55e9, 0x55ed, 0x55ee, + 0x55f0, 0x55f1, 0x55f4, 0x55f6, 0x55f8, 0x55f9, 0x55fa, 0x55fb, + 0x55fc, 0x55ff, 0x5602, 0x5603, 0x5604, 0x5605, + /* 0x87 */ + 0x5606, 0x5607, 0x560a, 0x560b, 0x560d, 0x5610, 0x5611, 0x5612, + 0x5613, 0x5614, 0x5615, 0x5616, 0x5617, 0x5619, 0x561a, 0x561c, + 0x561d, 0x5620, 0x5621, 0x5622, 0x5625, 0x5626, 0x5628, 0x5629, + 0x562a, 0x562b, 0x562e, 0x562f, 0x5630, 0x5633, 0x5635, 0x5637, + 0x5638, 0x563a, 0x563c, 0x563d, 0x563e, 0x5640, 0x5641, 0x5642, + 0x5643, 0x5644, 0x5645, 0x5646, 0x5647, 0x5648, 0x5649, 0x564a, + 0x564b, 0x564f, 0x5650, 0x5651, 0x5652, 0x5653, 0x5655, 0x5656, + 0x565a, 0x565b, 0x565d, 0x565e, 0x565f, 0x5660, 0x5661, 0x5663, + 0x5665, 0x5666, 0x5667, 0x566d, 0x566e, 0x566f, 0x5670, 0x5672, + 0x5673, 0x5674, 0x5675, 0x5677, 0x5678, 0x5679, 0x567a, 0x567d, + 0x567e, 0x567f, 0x5680, 0x5681, 0x5682, 0x5683, 0x5684, 0x5687, + 0x5688, 0x5689, 0x568a, 0x568b, 0x568c, 0x568d, 0x5690, 0x5691, + 0x5692, 0x5694, 0x5695, 0x5696, 0x5697, 0x5698, 0x5699, 0x569a, + 0x569b, 0x569c, 0x569d, 0x569e, 0x569f, 0x56a0, 0x56a1, 0x56a2, + 0x56a4, 0x56a5, 0x56a6, 0x56a7, 0x56a8, 0x56a9, 0x56aa, 0x56ab, + 0x56ac, 0x56ad, 0x56ae, 0x56b0, 0x56b1, 0x56b2, 0x56b3, 0x56b4, + 0x56b5, 0x56b6, 0x56b8, 0x56b9, 0x56ba, 0x56bb, 0x56bd, 0x56be, + 0x56bf, 0x56c0, 0x56c1, 0x56c2, 0x56c3, 0x56c4, 0x56c5, 0x56c6, + 0x56c7, 0x56c8, 0x56c9, 0x56cb, 0x56cc, 0x56cd, 0x56ce, 0x56cf, + 0x56d0, 0x56d1, 0x56d2, 0x56d3, 0x56d5, 0x56d6, 0x56d8, 0x56d9, + 0x56dc, 0x56e3, 0x56e5, 0x56e6, 0x56e7, 0x56e8, 0x56e9, 0x56ea, + 0x56ec, 0x56ee, 0x56ef, 0x56f2, 0x56f3, 0x56f6, 0x56f7, 0x56f8, + 0x56fb, 0x56fc, 0x5700, 0x5701, 0x5702, 0x5705, 0x5707, 0x570b, + 0x570c, 0x570d, 0x570e, 0x570f, 0x5710, 0x5711, + /* 0x88 */ + 0x5712, 0x5713, 0x5714, 0x5715, 0x5716, 0x5717, 0x5718, 0x5719, + 0x571a, 0x571b, 0x571d, 0x571e, 0x5720, 0x5721, 0x5722, 0x5724, + 0x5725, 0x5726, 0x5727, 0x572b, 0x5731, 0x5732, 0x5734, 0x5735, + 0x5736, 0x5737, 0x5738, 0x573c, 0x573d, 0x573f, 0x5741, 0x5743, + 0x5744, 0x5745, 0x5746, 0x5748, 0x5749, 0x574b, 0x5752, 0x5753, + 0x5754, 0x5755, 0x5756, 0x5758, 0x5759, 0x5762, 0x5763, 0x5765, + 0x5767, 0x576c, 0x576e, 0x5770, 0x5771, 0x5772, 0x5774, 0x5775, + 0x5778, 0x5779, 0x577a, 0x577d, 0x577e, 0x577f, 0x5780, 0x5781, + 0x5787, 0x5788, 0x5789, 0x578a, 0x578d, 0x578e, 0x578f, 0x5790, + 0x5791, 0x5794, 0x5795, 0x5796, 0x5797, 0x5798, 0x5799, 0x579a, + 0x579c, 0x579d, 0x579e, 0x579f, 0x57a5, 0x57a8, 0x57aa, 0x57ac, + 0x57af, 0x57b0, 0x57b1, 0x57b3, 0x57b5, 0x57b6, 0x57b7, 0x57b9, + 0x57ba, 0x57bb, 0x57bc, 0x57bd, 0x57be, 0x57bf, 0x57c0, 0x57c1, + 0x57c4, 0x57c5, 0x57c6, 0x57c7, 0x57c8, 0x57c9, 0x57ca, 0x57cc, + 0x57cd, 0x57d0, 0x57d1, 0x57d3, 0x57d6, 0x57d7, 0x57db, 0x57dc, + 0x57de, 0x57e1, 0x57e2, 0x57e3, 0x57e5, 0x57e6, 0x57e7, 0x57e8, + 0x57e9, 0x57ea, 0x57eb, 0x57ec, 0x57ee, 0x57f0, 0x57f1, 0x57f2, + 0x57f3, 0x57f5, 0x57f6, 0x57f7, 0x57fb, 0x57fc, 0x57fe, 0x57ff, + 0x5801, 0x5803, 0x5804, 0x5805, 0x5808, 0x5809, 0x580a, 0x580c, + 0x580e, 0x580f, 0x5810, 0x5812, 0x5813, 0x5814, 0x5816, 0x5817, + 0x5818, 0x581a, 0x581b, 0x581c, 0x581d, 0x581f, 0x5822, 0x5823, + 0x5825, 0x5826, 0x5827, 0x5828, 0x5829, 0x582b, 0x582c, 0x582d, + 0x582e, 0x582f, 0x5831, 0x5832, 0x5833, 0x5834, 0x5836, 0x5837, + 0x5838, 0x5839, 0x583a, 0x583b, 0x583c, 0x583d, + /* 0x89 */ + 0x583e, 0x583f, 0x5840, 0x5841, 0x5842, 0x5843, 0x5845, 0x5846, + 0x5847, 0x5848, 0x5849, 0x584a, 0x584b, 0x584e, 0x584f, 0x5850, + 0x5852, 0x5853, 0x5855, 0x5856, 0x5857, 0x5859, 0x585a, 0x585b, + 0x585c, 0x585d, 0x585f, 0x5860, 0x5861, 0x5862, 0x5863, 0x5864, + 0x5866, 0x5867, 0x5868, 0x5869, 0x586a, 0x586d, 0x586e, 0x586f, + 0x5870, 0x5871, 0x5872, 0x5873, 0x5874, 0x5875, 0x5876, 0x5877, + 0x5878, 0x5879, 0x587a, 0x587b, 0x587c, 0x587d, 0x587f, 0x5882, + 0x5884, 0x5886, 0x5887, 0x5888, 0x588a, 0x588b, 0x588c, 0x588d, + 0x588e, 0x588f, 0x5890, 0x5891, 0x5894, 0x5895, 0x5896, 0x5897, + 0x5898, 0x589b, 0x589c, 0x589d, 0x58a0, 0x58a1, 0x58a2, 0x58a3, + 0x58a4, 0x58a5, 0x58a6, 0x58a7, 0x58aa, 0x58ab, 0x58ac, 0x58ad, + 0x58ae, 0x58af, 0x58b0, 0x58b1, 0x58b2, 0x58b3, 0x58b4, 0x58b5, + 0x58b6, 0x58b7, 0x58b8, 0x58b9, 0x58ba, 0x58bb, 0x58bd, 0x58be, + 0x58bf, 0x58c0, 0x58c2, 0x58c3, 0x58c4, 0x58c6, 0x58c7, 0x58c8, + 0x58c9, 0x58ca, 0x58cb, 0x58cc, 0x58cd, 0x58ce, 0x58cf, 0x58d0, + 0x58d2, 0x58d3, 0x58d4, 0x58d6, 0x58d7, 0x58d8, 0x58d9, 0x58da, + 0x58db, 0x58dc, 0x58dd, 0x58de, 0x58df, 0x58e0, 0x58e1, 0x58e2, + 0x58e3, 0x58e5, 0x58e6, 0x58e7, 0x58e8, 0x58e9, 0x58ea, 0x58ed, + 0x58ef, 0x58f1, 0x58f2, 0x58f4, 0x58f5, 0x58f7, 0x58f8, 0x58fa, + 0x58fb, 0x58fc, 0x58fd, 0x58fe, 0x58ff, 0x5900, 0x5901, 0x5903, + 0x5905, 0x5906, 0x5908, 0x5909, 0x590a, 0x590b, 0x590c, 0x590e, + 0x5910, 0x5911, 0x5912, 0x5913, 0x5917, 0x5918, 0x591b, 0x591d, + 0x591e, 0x5920, 0x5921, 0x5922, 0x5923, 0x5926, 0x5928, 0x592c, + 0x5930, 0x5932, 0x5933, 0x5935, 0x5936, 0x593b, + /* 0x8a */ + 0x593d, 0x593e, 0x593f, 0x5940, 0x5943, 0x5945, 0x5946, 0x594a, + 0x594c, 0x594d, 0x5950, 0x5952, 0x5953, 0x5959, 0x595b, 0x595c, + 0x595d, 0x595e, 0x595f, 0x5961, 0x5963, 0x5964, 0x5966, 0x5967, + 0x5968, 0x5969, 0x596a, 0x596b, 0x596c, 0x596d, 0x596e, 0x596f, + 0x5970, 0x5971, 0x5972, 0x5975, 0x5977, 0x597a, 0x597b, 0x597c, + 0x597e, 0x597f, 0x5980, 0x5985, 0x5989, 0x598b, 0x598c, 0x598e, + 0x598f, 0x5990, 0x5991, 0x5994, 0x5995, 0x5998, 0x599a, 0x599b, + 0x599c, 0x599d, 0x599f, 0x59a0, 0x59a1, 0x59a2, 0x59a6, 0x59a7, + 0x59ac, 0x59ad, 0x59b0, 0x59b1, 0x59b3, 0x59b4, 0x59b5, 0x59b6, + 0x59b7, 0x59b8, 0x59ba, 0x59bc, 0x59bd, 0x59bf, 0x59c0, 0x59c1, + 0x59c2, 0x59c3, 0x59c4, 0x59c5, 0x59c7, 0x59c8, 0x59c9, 0x59cc, + 0x59cd, 0x59ce, 0x59cf, 0x59d5, 0x59d6, 0x59d9, 0x59db, 0x59de, + 0x59df, 0x59e0, 0x59e1, 0x59e2, 0x59e4, 0x59e6, 0x59e7, 0x59e9, + 0x59ea, 0x59eb, 0x59ed, 0x59ee, 0x59ef, 0x59f0, 0x59f1, 0x59f2, + 0x59f3, 0x59f4, 0x59f5, 0x59f6, 0x59f7, 0x59f8, 0x59fa, 0x59fc, + 0x59fd, 0x59fe, 0x5a00, 0x5a02, 0x5a0a, 0x5a0b, 0x5a0d, 0x5a0e, + 0x5a0f, 0x5a10, 0x5a12, 0x5a14, 0x5a15, 0x5a16, 0x5a17, 0x5a19, + 0x5a1a, 0x5a1b, 0x5a1d, 0x5a1e, 0x5a21, 0x5a22, 0x5a24, 0x5a26, + 0x5a27, 0x5a28, 0x5a2a, 0x5a2b, 0x5a2c, 0x5a2d, 0x5a2e, 0x5a2f, + 0x5a30, 0x5a33, 0x5a35, 0x5a37, 0x5a38, 0x5a39, 0x5a3a, 0x5a3b, + 0x5a3d, 0x5a3e, 0x5a3f, 0x5a41, 0x5a42, 0x5a43, 0x5a44, 0x5a45, + 0x5a47, 0x5a48, 0x5a4b, 0x5a4c, 0x5a4d, 0x5a4e, 0x5a4f, 0x5a50, + 0x5a51, 0x5a52, 0x5a53, 0x5a54, 0x5a56, 0x5a57, 0x5a58, 0x5a59, + 0x5a5b, 0x5a5c, 0x5a5d, 0x5a5e, 0x5a5f, 0x5a60, + /* 0x8b */ + 0x5a61, 0x5a63, 0x5a64, 0x5a65, 0x5a66, 0x5a68, 0x5a69, 0x5a6b, + 0x5a6c, 0x5a6d, 0x5a6e, 0x5a6f, 0x5a70, 0x5a71, 0x5a72, 0x5a73, + 0x5a78, 0x5a79, 0x5a7b, 0x5a7c, 0x5a7d, 0x5a7e, 0x5a80, 0x5a81, + 0x5a82, 0x5a83, 0x5a84, 0x5a85, 0x5a86, 0x5a87, 0x5a88, 0x5a89, + 0x5a8a, 0x5a8b, 0x5a8c, 0x5a8d, 0x5a8e, 0x5a8f, 0x5a90, 0x5a91, + 0x5a93, 0x5a94, 0x5a95, 0x5a96, 0x5a97, 0x5a98, 0x5a99, 0x5a9c, + 0x5a9d, 0x5a9e, 0x5a9f, 0x5aa0, 0x5aa1, 0x5aa2, 0x5aa3, 0x5aa4, + 0x5aa5, 0x5aa6, 0x5aa7, 0x5aa8, 0x5aa9, 0x5aab, 0x5aac, 0x5aad, + 0x5aae, 0x5aaf, 0x5ab0, 0x5ab1, 0x5ab4, 0x5ab6, 0x5ab7, 0x5ab9, + 0x5aba, 0x5abb, 0x5abc, 0x5abd, 0x5abf, 0x5ac0, 0x5ac3, 0x5ac4, + 0x5ac5, 0x5ac6, 0x5ac7, 0x5ac8, 0x5aca, 0x5acb, 0x5acd, 0x5ace, + 0x5acf, 0x5ad0, 0x5ad1, 0x5ad3, 0x5ad5, 0x5ad7, 0x5ad9, 0x5ada, + 0x5adb, 0x5add, 0x5ade, 0x5adf, 0x5ae2, 0x5ae4, 0x5ae5, 0x5ae7, + 0x5ae8, 0x5aea, 0x5aec, 0x5aed, 0x5aee, 0x5aef, 0x5af0, 0x5af2, + 0x5af3, 0x5af4, 0x5af5, 0x5af6, 0x5af7, 0x5af8, 0x5af9, 0x5afa, + 0x5afb, 0x5afc, 0x5afd, 0x5afe, 0x5aff, 0x5b00, 0x5b01, 0x5b02, + 0x5b03, 0x5b04, 0x5b05, 0x5b06, 0x5b07, 0x5b08, 0x5b0a, 0x5b0b, + 0x5b0c, 0x5b0d, 0x5b0e, 0x5b0f, 0x5b10, 0x5b11, 0x5b12, 0x5b13, + 0x5b14, 0x5b15, 0x5b18, 0x5b19, 0x5b1a, 0x5b1b, 0x5b1c, 0x5b1d, + 0x5b1e, 0x5b1f, 0x5b20, 0x5b21, 0x5b22, 0x5b23, 0x5b24, 0x5b25, + 0x5b26, 0x5b27, 0x5b28, 0x5b29, 0x5b2a, 0x5b2b, 0x5b2c, 0x5b2d, + 0x5b2e, 0x5b2f, 0x5b30, 0x5b31, 0x5b33, 0x5b35, 0x5b36, 0x5b38, + 0x5b39, 0x5b3a, 0x5b3b, 0x5b3c, 0x5b3d, 0x5b3e, 0x5b3f, 0x5b41, + 0x5b42, 0x5b43, 0x5b44, 0x5b45, 0x5b46, 0x5b47, + /* 0x8c */ + 0x5b48, 0x5b49, 0x5b4a, 0x5b4b, 0x5b4c, 0x5b4d, 0x5b4e, 0x5b4f, + 0x5b52, 0x5b56, 0x5b5e, 0x5b60, 0x5b61, 0x5b67, 0x5b68, 0x5b6b, + 0x5b6d, 0x5b6e, 0x5b6f, 0x5b72, 0x5b74, 0x5b76, 0x5b77, 0x5b78, + 0x5b79, 0x5b7b, 0x5b7c, 0x5b7e, 0x5b7f, 0x5b82, 0x5b86, 0x5b8a, + 0x5b8d, 0x5b8e, 0x5b90, 0x5b91, 0x5b92, 0x5b94, 0x5b96, 0x5b9f, + 0x5ba7, 0x5ba8, 0x5ba9, 0x5bac, 0x5bad, 0x5bae, 0x5baf, 0x5bb1, + 0x5bb2, 0x5bb7, 0x5bba, 0x5bbb, 0x5bbc, 0x5bc0, 0x5bc1, 0x5bc3, + 0x5bc8, 0x5bc9, 0x5bca, 0x5bcb, 0x5bcd, 0x5bce, 0x5bcf, 0x5bd1, + 0x5bd4, 0x5bd5, 0x5bd6, 0x5bd7, 0x5bd8, 0x5bd9, 0x5bda, 0x5bdb, + 0x5bdc, 0x5be0, 0x5be2, 0x5be3, 0x5be6, 0x5be7, 0x5be9, 0x5bea, + 0x5beb, 0x5bec, 0x5bed, 0x5bef, 0x5bf1, 0x5bf2, 0x5bf3, 0x5bf4, + 0x5bf5, 0x5bf6, 0x5bf7, 0x5bfd, 0x5bfe, 0x5c00, 0x5c02, 0x5c03, + 0x5c05, 0x5c07, 0x5c08, 0x5c0b, 0x5c0c, 0x5c0d, 0x5c0e, 0x5c10, + 0x5c12, 0x5c13, 0x5c17, 0x5c19, 0x5c1b, 0x5c1e, 0x5c1f, 0x5c20, + 0x5c21, 0x5c23, 0x5c26, 0x5c28, 0x5c29, 0x5c2a, 0x5c2b, 0x5c2d, + 0x5c2e, 0x5c2f, 0x5c30, 0x5c32, 0x5c33, 0x5c35, 0x5c36, 0x5c37, + 0x5c43, 0x5c44, 0x5c46, 0x5c47, 0x5c4c, 0x5c4d, 0x5c52, 0x5c53, + 0x5c54, 0x5c56, 0x5c57, 0x5c58, 0x5c5a, 0x5c5b, 0x5c5c, 0x5c5d, + 0x5c5f, 0x5c62, 0x5c64, 0x5c67, 0x5c68, 0x5c69, 0x5c6a, 0x5c6b, + 0x5c6c, 0x5c6d, 0x5c70, 0x5c72, 0x5c73, 0x5c74, 0x5c75, 0x5c76, + 0x5c77, 0x5c78, 0x5c7b, 0x5c7c, 0x5c7d, 0x5c7e, 0x5c80, 0x5c83, + 0x5c84, 0x5c85, 0x5c86, 0x5c87, 0x5c89, 0x5c8a, 0x5c8b, 0x5c8e, + 0x5c8f, 0x5c92, 0x5c93, 0x5c95, 0x5c9d, 0x5c9e, 0x5c9f, 0x5ca0, + 0x5ca1, 0x5ca4, 0x5ca5, 0x5ca6, 0x5ca7, 0x5ca8, + /* 0x8d */ + 0x5caa, 0x5cae, 0x5caf, 0x5cb0, 0x5cb2, 0x5cb4, 0x5cb6, 0x5cb9, + 0x5cba, 0x5cbb, 0x5cbc, 0x5cbe, 0x5cc0, 0x5cc2, 0x5cc3, 0x5cc5, + 0x5cc6, 0x5cc7, 0x5cc8, 0x5cc9, 0x5cca, 0x5ccc, 0x5ccd, 0x5cce, + 0x5ccf, 0x5cd0, 0x5cd1, 0x5cd3, 0x5cd4, 0x5cd5, 0x5cd6, 0x5cd7, + 0x5cd8, 0x5cda, 0x5cdb, 0x5cdc, 0x5cdd, 0x5cde, 0x5cdf, 0x5ce0, + 0x5ce2, 0x5ce3, 0x5ce7, 0x5ce9, 0x5ceb, 0x5cec, 0x5cee, 0x5cef, + 0x5cf1, 0x5cf2, 0x5cf3, 0x5cf4, 0x5cf5, 0x5cf6, 0x5cf7, 0x5cf8, + 0x5cf9, 0x5cfa, 0x5cfc, 0x5cfd, 0x5cfe, 0x5cff, 0x5d00, 0x5d01, + 0x5d04, 0x5d05, 0x5d08, 0x5d09, 0x5d0a, 0x5d0b, 0x5d0c, 0x5d0d, + 0x5d0f, 0x5d10, 0x5d11, 0x5d12, 0x5d13, 0x5d15, 0x5d17, 0x5d18, + 0x5d19, 0x5d1a, 0x5d1c, 0x5d1d, 0x5d1f, 0x5d20, 0x5d21, 0x5d22, + 0x5d23, 0x5d25, 0x5d28, 0x5d2a, 0x5d2b, 0x5d2c, 0x5d2f, 0x5d30, + 0x5d31, 0x5d32, 0x5d33, 0x5d35, 0x5d36, 0x5d37, 0x5d38, 0x5d39, + 0x5d3a, 0x5d3b, 0x5d3c, 0x5d3f, 0x5d40, 0x5d41, 0x5d42, 0x5d43, + 0x5d44, 0x5d45, 0x5d46, 0x5d48, 0x5d49, 0x5d4d, 0x5d4e, 0x5d4f, + 0x5d50, 0x5d51, 0x5d52, 0x5d53, 0x5d54, 0x5d55, 0x5d56, 0x5d57, + 0x5d59, 0x5d5a, 0x5d5c, 0x5d5e, 0x5d5f, 0x5d60, 0x5d61, 0x5d62, + 0x5d63, 0x5d64, 0x5d65, 0x5d66, 0x5d67, 0x5d68, 0x5d6a, 0x5d6d, + 0x5d6e, 0x5d70, 0x5d71, 0x5d72, 0x5d73, 0x5d75, 0x5d76, 0x5d77, + 0x5d78, 0x5d79, 0x5d7a, 0x5d7b, 0x5d7c, 0x5d7d, 0x5d7e, 0x5d7f, + 0x5d80, 0x5d81, 0x5d83, 0x5d84, 0x5d85, 0x5d86, 0x5d87, 0x5d88, + 0x5d89, 0x5d8a, 0x5d8b, 0x5d8c, 0x5d8d, 0x5d8e, 0x5d8f, 0x5d90, + 0x5d91, 0x5d92, 0x5d93, 0x5d94, 0x5d95, 0x5d96, 0x5d97, 0x5d98, + 0x5d9a, 0x5d9b, 0x5d9c, 0x5d9e, 0x5d9f, 0x5da0, + /* 0x8e */ + 0x5da1, 0x5da2, 0x5da3, 0x5da4, 0x5da5, 0x5da6, 0x5da7, 0x5da8, + 0x5da9, 0x5daa, 0x5dab, 0x5dac, 0x5dad, 0x5dae, 0x5daf, 0x5db0, + 0x5db1, 0x5db2, 0x5db3, 0x5db4, 0x5db5, 0x5db6, 0x5db8, 0x5db9, + 0x5dba, 0x5dbb, 0x5dbc, 0x5dbd, 0x5dbe, 0x5dbf, 0x5dc0, 0x5dc1, + 0x5dc2, 0x5dc3, 0x5dc4, 0x5dc6, 0x5dc7, 0x5dc8, 0x5dc9, 0x5dca, + 0x5dcb, 0x5dcc, 0x5dce, 0x5dcf, 0x5dd0, 0x5dd1, 0x5dd2, 0x5dd3, + 0x5dd4, 0x5dd5, 0x5dd6, 0x5dd7, 0x5dd8, 0x5dd9, 0x5dda, 0x5ddc, + 0x5ddf, 0x5de0, 0x5de3, 0x5de4, 0x5dea, 0x5dec, 0x5ded, 0x5df0, + 0x5df5, 0x5df6, 0x5df8, 0x5df9, 0x5dfa, 0x5dfb, 0x5dfc, 0x5dff, + 0x5e00, 0x5e04, 0x5e07, 0x5e09, 0x5e0a, 0x5e0b, 0x5e0d, 0x5e0e, + 0x5e12, 0x5e13, 0x5e17, 0x5e1e, 0x5e1f, 0x5e20, 0x5e21, 0x5e22, + 0x5e23, 0x5e24, 0x5e25, 0x5e28, 0x5e29, 0x5e2a, 0x5e2b, 0x5e2c, + 0x5e2f, 0x5e30, 0x5e32, 0x5e33, 0x5e34, 0x5e35, 0x5e36, 0x5e39, + 0x5e3a, 0x5e3e, 0x5e3f, 0x5e40, 0x5e41, 0x5e43, 0x5e46, 0x5e47, + 0x5e48, 0x5e49, 0x5e4a, 0x5e4b, 0x5e4d, 0x5e4e, 0x5e4f, 0x5e50, + 0x5e51, 0x5e52, 0x5e53, 0x5e56, 0x5e57, 0x5e58, 0x5e59, 0x5e5a, + 0x5e5c, 0x5e5d, 0x5e5f, 0x5e60, 0x5e63, 0x5e64, 0x5e65, 0x5e66, + 0x5e67, 0x5e68, 0x5e69, 0x5e6a, 0x5e6b, 0x5e6c, 0x5e6d, 0x5e6e, + 0x5e6f, 0x5e70, 0x5e71, 0x5e75, 0x5e77, 0x5e79, 0x5e7e, 0x5e81, + 0x5e82, 0x5e83, 0x5e85, 0x5e88, 0x5e89, 0x5e8c, 0x5e8d, 0x5e8e, + 0x5e92, 0x5e98, 0x5e9b, 0x5e9d, 0x5ea1, 0x5ea2, 0x5ea3, 0x5ea4, + 0x5ea8, 0x5ea9, 0x5eaa, 0x5eab, 0x5eac, 0x5eae, 0x5eaf, 0x5eb0, + 0x5eb1, 0x5eb2, 0x5eb4, 0x5eba, 0x5ebb, 0x5ebc, 0x5ebd, 0x5ebf, + 0x5ec0, 0x5ec1, 0x5ec2, 0x5ec3, 0x5ec4, 0x5ec5, + /* 0x8f */ + 0x5ec6, 0x5ec7, 0x5ec8, 0x5ecb, 0x5ecc, 0x5ecd, 0x5ece, 0x5ecf, + 0x5ed0, 0x5ed4, 0x5ed5, 0x5ed7, 0x5ed8, 0x5ed9, 0x5eda, 0x5edc, + 0x5edd, 0x5ede, 0x5edf, 0x5ee0, 0x5ee1, 0x5ee2, 0x5ee3, 0x5ee4, + 0x5ee5, 0x5ee6, 0x5ee7, 0x5ee9, 0x5eeb, 0x5eec, 0x5eed, 0x5eee, + 0x5eef, 0x5ef0, 0x5ef1, 0x5ef2, 0x5ef3, 0x5ef5, 0x5ef8, 0x5ef9, + 0x5efb, 0x5efc, 0x5efd, 0x5f05, 0x5f06, 0x5f07, 0x5f09, 0x5f0c, + 0x5f0d, 0x5f0e, 0x5f10, 0x5f12, 0x5f14, 0x5f16, 0x5f19, 0x5f1a, + 0x5f1c, 0x5f1d, 0x5f1e, 0x5f21, 0x5f22, 0x5f23, 0x5f24, 0x5f28, + 0x5f2b, 0x5f2c, 0x5f2e, 0x5f30, 0x5f32, 0x5f33, 0x5f34, 0x5f35, + 0x5f36, 0x5f37, 0x5f38, 0x5f3b, 0x5f3d, 0x5f3e, 0x5f3f, 0x5f41, + 0x5f42, 0x5f43, 0x5f44, 0x5f45, 0x5f46, 0x5f47, 0x5f48, 0x5f49, + 0x5f4a, 0x5f4b, 0x5f4c, 0x5f4d, 0x5f4e, 0x5f4f, 0x5f51, 0x5f54, + 0x5f59, 0x5f5a, 0x5f5b, 0x5f5c, 0x5f5e, 0x5f5f, 0x5f60, 0x5f63, + 0x5f65, 0x5f67, 0x5f68, 0x5f6b, 0x5f6e, 0x5f6f, 0x5f72, 0x5f74, + 0x5f75, 0x5f76, 0x5f78, 0x5f7a, 0x5f7d, 0x5f7e, 0x5f7f, 0x5f83, + 0x5f86, 0x5f8d, 0x5f8e, 0x5f8f, 0x5f91, 0x5f93, 0x5f94, 0x5f96, + 0x5f9a, 0x5f9b, 0x5f9d, 0x5f9e, 0x5f9f, 0x5fa0, 0x5fa2, 0x5fa3, + 0x5fa4, 0x5fa5, 0x5fa6, 0x5fa7, 0x5fa9, 0x5fab, 0x5fac, 0x5faf, + 0x5fb0, 0x5fb1, 0x5fb2, 0x5fb3, 0x5fb4, 0x5fb6, 0x5fb8, 0x5fb9, + 0x5fba, 0x5fbb, 0x5fbe, 0x5fbf, 0x5fc0, 0x5fc1, 0x5fc2, 0x5fc7, + 0x5fc8, 0x5fca, 0x5fcb, 0x5fce, 0x5fd3, 0x5fd4, 0x5fd5, 0x5fda, + 0x5fdb, 0x5fdc, 0x5fde, 0x5fdf, 0x5fe2, 0x5fe3, 0x5fe5, 0x5fe6, + 0x5fe8, 0x5fe9, 0x5fec, 0x5fef, 0x5ff0, 0x5ff2, 0x5ff3, 0x5ff4, + 0x5ff6, 0x5ff7, 0x5ff9, 0x5ffa, 0x5ffc, 0x6007, + /* 0x90 */ + 0x6008, 0x6009, 0x600b, 0x600c, 0x6010, 0x6011, 0x6013, 0x6017, + 0x6018, 0x601a, 0x601e, 0x601f, 0x6022, 0x6023, 0x6024, 0x602c, + 0x602d, 0x602e, 0x6030, 0x6031, 0x6032, 0x6033, 0x6034, 0x6036, + 0x6037, 0x6038, 0x6039, 0x603a, 0x603d, 0x603e, 0x6040, 0x6044, + 0x6045, 0x6046, 0x6047, 0x6048, 0x6049, 0x604a, 0x604c, 0x604e, + 0x604f, 0x6051, 0x6053, 0x6054, 0x6056, 0x6057, 0x6058, 0x605b, + 0x605c, 0x605e, 0x605f, 0x6060, 0x6061, 0x6065, 0x6066, 0x606e, + 0x6071, 0x6072, 0x6074, 0x6075, 0x6077, 0x607e, 0x6080, 0x6081, + 0x6082, 0x6085, 0x6086, 0x6087, 0x6088, 0x608a, 0x608b, 0x608e, + 0x608f, 0x6090, 0x6091, 0x6093, 0x6095, 0x6097, 0x6098, 0x6099, + 0x609c, 0x609e, 0x60a1, 0x60a2, 0x60a4, 0x60a5, 0x60a7, 0x60a9, + 0x60aa, 0x60ae, 0x60b0, 0x60b3, 0x60b5, 0x60b6, 0x60b7, 0x60b9, + 0x60ba, 0x60bd, 0x60be, 0x60bf, 0x60c0, 0x60c1, 0x60c2, 0x60c3, + 0x60c4, 0x60c7, 0x60c8, 0x60c9, 0x60cc, 0x60cd, 0x60ce, 0x60cf, + 0x60d0, 0x60d2, 0x60d3, 0x60d4, 0x60d6, 0x60d7, 0x60d9, 0x60db, + 0x60de, 0x60e1, 0x60e2, 0x60e3, 0x60e4, 0x60e5, 0x60ea, 0x60f1, + 0x60f2, 0x60f5, 0x60f7, 0x60f8, 0x60fb, 0x60fc, 0x60fd, 0x60fe, + 0x60ff, 0x6102, 0x6103, 0x6104, 0x6105, 0x6107, 0x610a, 0x610b, + 0x610c, 0x6110, 0x6111, 0x6112, 0x6113, 0x6114, 0x6116, 0x6117, + 0x6118, 0x6119, 0x611b, 0x611c, 0x611d, 0x611e, 0x6121, 0x6122, + 0x6125, 0x6128, 0x6129, 0x612a, 0x612c, 0x612d, 0x612e, 0x612f, + 0x6130, 0x6131, 0x6132, 0x6133, 0x6134, 0x6135, 0x6136, 0x6137, + 0x6138, 0x6139, 0x613a, 0x613b, 0x613c, 0x613d, 0x613e, 0x6140, + 0x6141, 0x6142, 0x6143, 0x6144, 0x6145, 0x6146, + /* 0x91 */ + 0x6147, 0x6149, 0x614b, 0x614d, 0x614f, 0x6150, 0x6152, 0x6153, + 0x6154, 0x6156, 0x6157, 0x6158, 0x6159, 0x615a, 0x615b, 0x615c, + 0x615e, 0x615f, 0x6160, 0x6161, 0x6163, 0x6164, 0x6165, 0x6166, + 0x6169, 0x616a, 0x616b, 0x616c, 0x616d, 0x616e, 0x616f, 0x6171, + 0x6172, 0x6173, 0x6174, 0x6176, 0x6178, 0x6179, 0x617a, 0x617b, + 0x617c, 0x617d, 0x617e, 0x617f, 0x6180, 0x6181, 0x6182, 0x6183, + 0x6184, 0x6185, 0x6186, 0x6187, 0x6188, 0x6189, 0x618a, 0x618c, + 0x618d, 0x618f, 0x6190, 0x6191, 0x6192, 0x6193, 0x6195, 0x6196, + 0x6197, 0x6198, 0x6199, 0x619a, 0x619b, 0x619c, 0x619e, 0x619f, + 0x61a0, 0x61a1, 0x61a2, 0x61a3, 0x61a4, 0x61a5, 0x61a6, 0x61aa, + 0x61ab, 0x61ad, 0x61ae, 0x61af, 0x61b0, 0x61b1, 0x61b2, 0x61b3, + 0x61b4, 0x61b5, 0x61b6, 0x61b8, 0x61b9, 0x61ba, 0x61bb, 0x61bc, + 0x61bd, 0x61bf, 0x61c0, 0x61c1, 0x61c3, 0x61c4, 0x61c5, 0x61c6, + 0x61c7, 0x61c9, 0x61cc, 0x61cd, 0x61ce, 0x61cf, 0x61d0, 0x61d3, + 0x61d5, 0x61d6, 0x61d7, 0x61d8, 0x61d9, 0x61da, 0x61db, 0x61dc, + 0x61dd, 0x61de, 0x61df, 0x61e0, 0x61e1, 0x61e2, 0x61e3, 0x61e4, + 0x61e5, 0x61e7, 0x61e8, 0x61e9, 0x61ea, 0x61eb, 0x61ec, 0x61ed, + 0x61ee, 0x61ef, 0x61f0, 0x61f1, 0x61f2, 0x61f3, 0x61f4, 0x61f6, + 0x61f7, 0x61f8, 0x61f9, 0x61fa, 0x61fb, 0x61fc, 0x61fd, 0x61fe, + 0x6200, 0x6201, 0x6202, 0x6203, 0x6204, 0x6205, 0x6207, 0x6209, + 0x6213, 0x6214, 0x6219, 0x621c, 0x621d, 0x621e, 0x6220, 0x6223, + 0x6226, 0x6227, 0x6228, 0x6229, 0x622b, 0x622d, 0x622f, 0x6230, + 0x6231, 0x6232, 0x6235, 0x6236, 0x6238, 0x6239, 0x623a, 0x623b, + 0x623c, 0x6242, 0x6244, 0x6245, 0x6246, 0x624a, + /* 0x92 */ + 0x624f, 0x6250, 0x6255, 0x6256, 0x6257, 0x6259, 0x625a, 0x625c, + 0x625d, 0x625e, 0x625f, 0x6260, 0x6261, 0x6262, 0x6264, 0x6265, + 0x6268, 0x6271, 0x6272, 0x6274, 0x6275, 0x6277, 0x6278, 0x627a, + 0x627b, 0x627d, 0x6281, 0x6282, 0x6283, 0x6285, 0x6286, 0x6287, + 0x6288, 0x628b, 0x628c, 0x628d, 0x628e, 0x628f, 0x6290, 0x6294, + 0x6299, 0x629c, 0x629d, 0x629e, 0x62a3, 0x62a6, 0x62a7, 0x62a9, + 0x62aa, 0x62ad, 0x62ae, 0x62af, 0x62b0, 0x62b2, 0x62b3, 0x62b4, + 0x62b6, 0x62b7, 0x62b8, 0x62ba, 0x62be, 0x62c0, 0x62c1, 0x62c3, + 0x62cb, 0x62cf, 0x62d1, 0x62d5, 0x62dd, 0x62de, 0x62e0, 0x62e1, + 0x62e4, 0x62ea, 0x62eb, 0x62f0, 0x62f2, 0x62f5, 0x62f8, 0x62f9, + 0x62fa, 0x62fb, 0x6300, 0x6303, 0x6304, 0x6305, 0x6306, 0x630a, + 0x630b, 0x630c, 0x630d, 0x630f, 0x6310, 0x6312, 0x6313, 0x6314, + 0x6315, 0x6317, 0x6318, 0x6319, 0x631c, 0x6326, 0x6327, 0x6329, + 0x632c, 0x632d, 0x632e, 0x6330, 0x6331, 0x6333, 0x6334, 0x6335, + 0x6336, 0x6337, 0x6338, 0x633b, 0x633c, 0x633e, 0x633f, 0x6340, + 0x6341, 0x6344, 0x6347, 0x6348, 0x634a, 0x6351, 0x6352, 0x6353, + 0x6354, 0x6356, 0x6357, 0x6358, 0x6359, 0x635a, 0x635b, 0x635c, + 0x635d, 0x6360, 0x6364, 0x6365, 0x6366, 0x6368, 0x636a, 0x636b, + 0x636c, 0x636f, 0x6370, 0x6372, 0x6373, 0x6374, 0x6375, 0x6378, + 0x6379, 0x637c, 0x637d, 0x637e, 0x637f, 0x6381, 0x6383, 0x6384, + 0x6385, 0x6386, 0x638b, 0x638d, 0x6391, 0x6393, 0x6394, 0x6395, + 0x6397, 0x6399, 0x639a, 0x639b, 0x639c, 0x639d, 0x639e, 0x639f, + 0x63a1, 0x63a4, 0x63a6, 0x63ab, 0x63af, 0x63b1, 0x63b2, 0x63b5, + 0x63b6, 0x63b9, 0x63bb, 0x63bd, 0x63bf, 0x63c0, + /* 0x93 */ + 0x63c1, 0x63c2, 0x63c3, 0x63c5, 0x63c7, 0x63c8, 0x63ca, 0x63cb, + 0x63cc, 0x63d1, 0x63d3, 0x63d4, 0x63d5, 0x63d7, 0x63d8, 0x63d9, + 0x63da, 0x63db, 0x63dc, 0x63dd, 0x63df, 0x63e2, 0x63e4, 0x63e5, + 0x63e6, 0x63e7, 0x63e8, 0x63eb, 0x63ec, 0x63ee, 0x63ef, 0x63f0, + 0x63f1, 0x63f3, 0x63f5, 0x63f7, 0x63f9, 0x63fa, 0x63fb, 0x63fc, + 0x63fe, 0x6403, 0x6404, 0x6406, 0x6407, 0x6408, 0x6409, 0x640a, + 0x640d, 0x640e, 0x6411, 0x6412, 0x6415, 0x6416, 0x6417, 0x6418, + 0x6419, 0x641a, 0x641d, 0x641f, 0x6422, 0x6423, 0x6424, 0x6425, + 0x6427, 0x6428, 0x6429, 0x642b, 0x642e, 0x642f, 0x6430, 0x6431, + 0x6432, 0x6433, 0x6435, 0x6436, 0x6437, 0x6438, 0x6439, 0x643b, + 0x643c, 0x643e, 0x6440, 0x6442, 0x6443, 0x6449, 0x644b, 0x644c, + 0x644d, 0x644e, 0x644f, 0x6450, 0x6451, 0x6453, 0x6455, 0x6456, + 0x6457, 0x6459, 0x645a, 0x645b, 0x645c, 0x645d, 0x645f, 0x6460, + 0x6461, 0x6462, 0x6463, 0x6464, 0x6465, 0x6466, 0x6468, 0x646a, + 0x646b, 0x646c, 0x646e, 0x646f, 0x6470, 0x6471, 0x6472, 0x6473, + 0x6474, 0x6475, 0x6476, 0x6477, 0x647b, 0x647c, 0x647d, 0x647e, + 0x647f, 0x6480, 0x6481, 0x6483, 0x6486, 0x6488, 0x6489, 0x648a, + 0x648b, 0x648c, 0x648d, 0x648e, 0x648f, 0x6490, 0x6493, 0x6494, + 0x6497, 0x6498, 0x649a, 0x649b, 0x649c, 0x649d, 0x649f, 0x64a0, + 0x64a1, 0x64a2, 0x64a3, 0x64a5, 0x64a6, 0x64a7, 0x64a8, 0x64aa, + 0x64ab, 0x64af, 0x64b1, 0x64b2, 0x64b3, 0x64b4, 0x64b6, 0x64b9, + 0x64bb, 0x64bd, 0x64be, 0x64bf, 0x64c1, 0x64c3, 0x64c4, 0x64c6, + 0x64c7, 0x64c8, 0x64c9, 0x64ca, 0x64cb, 0x64cc, 0x64cf, 0x64d1, + 0x64d3, 0x64d4, 0x64d5, 0x64d6, 0x64d9, 0x64da, + /* 0x94 */ + 0x64db, 0x64dc, 0x64dd, 0x64df, 0x64e0, 0x64e1, 0x64e3, 0x64e5, + 0x64e7, 0x64e8, 0x64e9, 0x64ea, 0x64eb, 0x64ec, 0x64ed, 0x64ee, + 0x64ef, 0x64f0, 0x64f1, 0x64f2, 0x64f3, 0x64f4, 0x64f5, 0x64f6, + 0x64f7, 0x64f8, 0x64f9, 0x64fa, 0x64fb, 0x64fc, 0x64fd, 0x64fe, + 0x64ff, 0x6501, 0x6502, 0x6503, 0x6504, 0x6505, 0x6506, 0x6507, + 0x6508, 0x650a, 0x650b, 0x650c, 0x650d, 0x650e, 0x650f, 0x6510, + 0x6511, 0x6513, 0x6514, 0x6515, 0x6516, 0x6517, 0x6519, 0x651a, + 0x651b, 0x651c, 0x651d, 0x651e, 0x651f, 0x6520, 0x6521, 0x6522, + 0x6523, 0x6524, 0x6526, 0x6527, 0x6528, 0x6529, 0x652a, 0x652c, + 0x652d, 0x6530, 0x6531, 0x6532, 0x6533, 0x6537, 0x653a, 0x653c, + 0x653d, 0x6540, 0x6541, 0x6542, 0x6543, 0x6544, 0x6546, 0x6547, + 0x654a, 0x654b, 0x654d, 0x654e, 0x6550, 0x6552, 0x6553, 0x6554, + 0x6557, 0x6558, 0x655a, 0x655c, 0x655f, 0x6560, 0x6561, 0x6564, + 0x6565, 0x6567, 0x6568, 0x6569, 0x656a, 0x656d, 0x656e, 0x656f, + 0x6571, 0x6573, 0x6575, 0x6576, 0x6578, 0x6579, 0x657a, 0x657b, + 0x657c, 0x657d, 0x657e, 0x657f, 0x6580, 0x6581, 0x6582, 0x6583, + 0x6584, 0x6585, 0x6586, 0x6588, 0x6589, 0x658a, 0x658d, 0x658e, + 0x658f, 0x6592, 0x6594, 0x6595, 0x6596, 0x6598, 0x659a, 0x659d, + 0x659e, 0x65a0, 0x65a2, 0x65a3, 0x65a6, 0x65a8, 0x65aa, 0x65ac, + 0x65ae, 0x65b1, 0x65b2, 0x65b3, 0x65b4, 0x65b5, 0x65b6, 0x65b7, + 0x65b8, 0x65ba, 0x65bb, 0x65be, 0x65bf, 0x65c0, 0x65c2, 0x65c7, + 0x65c8, 0x65c9, 0x65ca, 0x65cd, 0x65d0, 0x65d1, 0x65d3, 0x65d4, + 0x65d5, 0x65d8, 0x65d9, 0x65da, 0x65db, 0x65dc, 0x65dd, 0x65de, + 0x65df, 0x65e1, 0x65e3, 0x65e4, 0x65ea, 0x65eb, + /* 0x95 */ + 0x65f2, 0x65f3, 0x65f4, 0x65f5, 0x65f8, 0x65f9, 0x65fb, 0x65fc, + 0x65fd, 0x65fe, 0x65ff, 0x6601, 0x6604, 0x6605, 0x6607, 0x6608, + 0x6609, 0x660b, 0x660d, 0x6610, 0x6611, 0x6612, 0x6616, 0x6617, + 0x6618, 0x661a, 0x661b, 0x661c, 0x661e, 0x6621, 0x6622, 0x6623, + 0x6624, 0x6626, 0x6629, 0x662a, 0x662b, 0x662c, 0x662e, 0x6630, + 0x6632, 0x6633, 0x6637, 0x6638, 0x6639, 0x663a, 0x663b, 0x663d, + 0x663f, 0x6640, 0x6642, 0x6644, 0x6645, 0x6646, 0x6647, 0x6648, + 0x6649, 0x664a, 0x664d, 0x664e, 0x6650, 0x6651, 0x6658, 0x6659, + 0x665b, 0x665c, 0x665d, 0x665e, 0x6660, 0x6662, 0x6663, 0x6665, + 0x6667, 0x6669, 0x666a, 0x666b, 0x666c, 0x666d, 0x6671, 0x6672, + 0x6673, 0x6675, 0x6678, 0x6679, 0x667b, 0x667c, 0x667d, 0x667f, + 0x6680, 0x6681, 0x6683, 0x6685, 0x6686, 0x6688, 0x6689, 0x668a, + 0x668b, 0x668d, 0x668e, 0x668f, 0x6690, 0x6692, 0x6693, 0x6694, + 0x6695, 0x6698, 0x6699, 0x669a, 0x669b, 0x669c, 0x669e, 0x669f, + 0x66a0, 0x66a1, 0x66a2, 0x66a3, 0x66a4, 0x66a5, 0x66a6, 0x66a9, + 0x66aa, 0x66ab, 0x66ac, 0x66ad, 0x66af, 0x66b0, 0x66b1, 0x66b2, + 0x66b3, 0x66b5, 0x66b6, 0x66b7, 0x66b8, 0x66ba, 0x66bb, 0x66bc, + 0x66bd, 0x66bf, 0x66c0, 0x66c1, 0x66c2, 0x66c3, 0x66c4, 0x66c5, + 0x66c6, 0x66c7, 0x66c8, 0x66c9, 0x66ca, 0x66cb, 0x66cc, 0x66cd, + 0x66ce, 0x66cf, 0x66d0, 0x66d1, 0x66d2, 0x66d3, 0x66d4, 0x66d5, + 0x66d6, 0x66d7, 0x66d8, 0x66da, 0x66de, 0x66df, 0x66e0, 0x66e1, + 0x66e2, 0x66e3, 0x66e4, 0x66e5, 0x66e7, 0x66e8, 0x66ea, 0x66eb, + 0x66ec, 0x66ed, 0x66ee, 0x66ef, 0x66f1, 0x66f5, 0x66f6, 0x66f8, + 0x66fa, 0x66fb, 0x66fd, 0x6701, 0x6702, 0x6703, + /* 0x96 */ + 0x6704, 0x6705, 0x6706, 0x6707, 0x670c, 0x670e, 0x670f, 0x6711, + 0x6712, 0x6713, 0x6716, 0x6718, 0x6719, 0x671a, 0x671c, 0x671e, + 0x6720, 0x6721, 0x6722, 0x6723, 0x6724, 0x6725, 0x6727, 0x6729, + 0x672e, 0x6730, 0x6732, 0x6733, 0x6736, 0x6737, 0x6738, 0x6739, + 0x673b, 0x673c, 0x673e, 0x673f, 0x6741, 0x6744, 0x6745, 0x6747, + 0x674a, 0x674b, 0x674d, 0x6752, 0x6754, 0x6755, 0x6757, 0x6758, + 0x6759, 0x675a, 0x675b, 0x675d, 0x6762, 0x6763, 0x6764, 0x6766, + 0x6767, 0x676b, 0x676c, 0x676e, 0x6771, 0x6774, 0x6776, 0x6778, + 0x6779, 0x677a, 0x677b, 0x677d, 0x6780, 0x6782, 0x6783, 0x6785, + 0x6786, 0x6788, 0x678a, 0x678c, 0x678d, 0x678e, 0x678f, 0x6791, + 0x6792, 0x6793, 0x6794, 0x6796, 0x6799, 0x679b, 0x679f, 0x67a0, + 0x67a1, 0x67a4, 0x67a6, 0x67a9, 0x67ac, 0x67ae, 0x67b1, 0x67b2, + 0x67b4, 0x67b9, 0x67ba, 0x67bb, 0x67bc, 0x67bd, 0x67be, 0x67bf, + 0x67c0, 0x67c2, 0x67c5, 0x67c6, 0x67c7, 0x67c8, 0x67c9, 0x67ca, + 0x67cb, 0x67cc, 0x67cd, 0x67ce, 0x67d5, 0x67d6, 0x67d7, 0x67db, + 0x67df, 0x67e1, 0x67e3, 0x67e4, 0x67e6, 0x67e7, 0x67e8, 0x67ea, + 0x67eb, 0x67ed, 0x67ee, 0x67f2, 0x67f5, 0x67f6, 0x67f7, 0x67f8, + 0x67f9, 0x67fa, 0x67fb, 0x67fc, 0x67fe, 0x6801, 0x6802, 0x6803, + 0x6804, 0x6806, 0x680d, 0x6810, 0x6812, 0x6814, 0x6815, 0x6818, + 0x6819, 0x681a, 0x681b, 0x681c, 0x681e, 0x681f, 0x6820, 0x6822, + 0x6823, 0x6824, 0x6825, 0x6826, 0x6827, 0x6828, 0x682b, 0x682c, + 0x682d, 0x682e, 0x682f, 0x6830, 0x6831, 0x6834, 0x6835, 0x6836, + 0x683a, 0x683b, 0x683f, 0x6847, 0x684b, 0x684d, 0x684f, 0x6852, + 0x6856, 0x6857, 0x6858, 0x6859, 0x685a, 0x685b, + /* 0x97 */ + 0x685c, 0x685d, 0x685e, 0x685f, 0x686a, 0x686c, 0x686d, 0x686e, + 0x686f, 0x6870, 0x6871, 0x6872, 0x6873, 0x6875, 0x6878, 0x6879, + 0x687a, 0x687b, 0x687c, 0x687d, 0x687e, 0x687f, 0x6880, 0x6882, + 0x6884, 0x6887, 0x6888, 0x6889, 0x688a, 0x688b, 0x688c, 0x688d, + 0x688e, 0x6890, 0x6891, 0x6892, 0x6894, 0x6895, 0x6896, 0x6898, + 0x6899, 0x689a, 0x689b, 0x689c, 0x689d, 0x689e, 0x689f, 0x68a0, + 0x68a1, 0x68a3, 0x68a4, 0x68a5, 0x68a9, 0x68aa, 0x68ab, 0x68ac, + 0x68ae, 0x68b1, 0x68b2, 0x68b4, 0x68b6, 0x68b7, 0x68b8, 0x68b9, + 0x68ba, 0x68bb, 0x68bc, 0x68bd, 0x68be, 0x68bf, 0x68c1, 0x68c3, + 0x68c4, 0x68c5, 0x68c6, 0x68c7, 0x68c8, 0x68ca, 0x68cc, 0x68ce, + 0x68cf, 0x68d0, 0x68d1, 0x68d3, 0x68d4, 0x68d6, 0x68d7, 0x68d9, + 0x68db, 0x68dc, 0x68dd, 0x68de, 0x68df, 0x68e1, 0x68e2, 0x68e4, + 0x68e5, 0x68e6, 0x68e7, 0x68e8, 0x68e9, 0x68ea, 0x68eb, 0x68ec, + 0x68ed, 0x68ef, 0x68f2, 0x68f3, 0x68f4, 0x68f6, 0x68f7, 0x68f8, + 0x68fb, 0x68fd, 0x68fe, 0x68ff, 0x6900, 0x6902, 0x6903, 0x6904, + 0x6906, 0x6907, 0x6908, 0x6909, 0x690a, 0x690c, 0x690f, 0x6911, + 0x6913, 0x6914, 0x6915, 0x6916, 0x6917, 0x6918, 0x6919, 0x691a, + 0x691b, 0x691c, 0x691d, 0x691e, 0x6921, 0x6922, 0x6923, 0x6925, + 0x6926, 0x6927, 0x6928, 0x6929, 0x692a, 0x692b, 0x692c, 0x692e, + 0x692f, 0x6931, 0x6932, 0x6933, 0x6935, 0x6936, 0x6937, 0x6938, + 0x693a, 0x693b, 0x693c, 0x693e, 0x6940, 0x6941, 0x6943, 0x6944, + 0x6945, 0x6946, 0x6947, 0x6948, 0x6949, 0x694a, 0x694b, 0x694c, + 0x694d, 0x694e, 0x694f, 0x6950, 0x6951, 0x6952, 0x6953, 0x6955, + 0x6956, 0x6958, 0x6959, 0x695b, 0x695c, 0x695f, + /* 0x98 */ + 0x6961, 0x6962, 0x6964, 0x6965, 0x6967, 0x6968, 0x6969, 0x696a, + 0x696c, 0x696d, 0x696f, 0x6970, 0x6972, 0x6973, 0x6974, 0x6975, + 0x6976, 0x697a, 0x697b, 0x697d, 0x697e, 0x697f, 0x6981, 0x6983, + 0x6985, 0x698a, 0x698b, 0x698c, 0x698e, 0x698f, 0x6990, 0x6991, + 0x6992, 0x6993, 0x6996, 0x6997, 0x6999, 0x699a, 0x699d, 0x699e, + 0x699f, 0x69a0, 0x69a1, 0x69a2, 0x69a3, 0x69a4, 0x69a5, 0x69a6, + 0x69a9, 0x69aa, 0x69ac, 0x69ae, 0x69af, 0x69b0, 0x69b2, 0x69b3, + 0x69b5, 0x69b6, 0x69b8, 0x69b9, 0x69ba, 0x69bc, 0x69bd, 0x69be, + 0x69bf, 0x69c0, 0x69c2, 0x69c3, 0x69c4, 0x69c5, 0x69c6, 0x69c7, + 0x69c8, 0x69c9, 0x69cb, 0x69cd, 0x69cf, 0x69d1, 0x69d2, 0x69d3, + 0x69d5, 0x69d6, 0x69d7, 0x69d8, 0x69d9, 0x69da, 0x69dc, 0x69dd, + 0x69de, 0x69e1, 0x69e2, 0x69e3, 0x69e4, 0x69e5, 0x69e6, 0x69e7, + 0x69e8, 0x69e9, 0x69ea, 0x69eb, 0x69ec, 0x69ee, 0x69ef, 0x69f0, + 0x69f1, 0x69f3, 0x69f4, 0x69f5, 0x69f6, 0x69f7, 0x69f8, 0x69f9, + 0x69fa, 0x69fb, 0x69fc, 0x69fe, 0x6a00, 0x6a01, 0x6a02, 0x6a03, + 0x6a04, 0x6a05, 0x6a06, 0x6a07, 0x6a08, 0x6a09, 0x6a0b, 0x6a0c, + 0x6a0d, 0x6a0e, 0x6a0f, 0x6a10, 0x6a11, 0x6a12, 0x6a13, 0x6a14, + 0x6a15, 0x6a16, 0x6a19, 0x6a1a, 0x6a1b, 0x6a1c, 0x6a1d, 0x6a1e, + 0x6a20, 0x6a22, 0x6a23, 0x6a24, 0x6a25, 0x6a26, 0x6a27, 0x6a29, + 0x6a2b, 0x6a2c, 0x6a2d, 0x6a2e, 0x6a30, 0x6a32, 0x6a33, 0x6a34, + 0x6a36, 0x6a37, 0x6a38, 0x6a39, 0x6a3a, 0x6a3b, 0x6a3c, 0x6a3f, + 0x6a40, 0x6a41, 0x6a42, 0x6a43, 0x6a45, 0x6a46, 0x6a48, 0x6a49, + 0x6a4a, 0x6a4b, 0x6a4c, 0x6a4d, 0x6a4e, 0x6a4f, 0x6a51, 0x6a52, + 0x6a53, 0x6a54, 0x6a55, 0x6a56, 0x6a57, 0x6a5a, + /* 0x99 */ + 0x6a5c, 0x6a5d, 0x6a5e, 0x6a5f, 0x6a60, 0x6a62, 0x6a63, 0x6a64, + 0x6a66, 0x6a67, 0x6a68, 0x6a69, 0x6a6a, 0x6a6b, 0x6a6c, 0x6a6d, + 0x6a6e, 0x6a6f, 0x6a70, 0x6a72, 0x6a73, 0x6a74, 0x6a75, 0x6a76, + 0x6a77, 0x6a78, 0x6a7a, 0x6a7b, 0x6a7d, 0x6a7e, 0x6a7f, 0x6a81, + 0x6a82, 0x6a83, 0x6a85, 0x6a86, 0x6a87, 0x6a88, 0x6a89, 0x6a8a, + 0x6a8b, 0x6a8c, 0x6a8d, 0x6a8f, 0x6a92, 0x6a93, 0x6a94, 0x6a95, + 0x6a96, 0x6a98, 0x6a99, 0x6a9a, 0x6a9b, 0x6a9c, 0x6a9d, 0x6a9e, + 0x6a9f, 0x6aa1, 0x6aa2, 0x6aa3, 0x6aa4, 0x6aa5, 0x6aa6, 0x6aa7, + 0x6aa8, 0x6aaa, 0x6aad, 0x6aae, 0x6aaf, 0x6ab0, 0x6ab1, 0x6ab2, + 0x6ab3, 0x6ab4, 0x6ab5, 0x6ab6, 0x6ab7, 0x6ab8, 0x6ab9, 0x6aba, + 0x6abb, 0x6abc, 0x6abd, 0x6abe, 0x6abf, 0x6ac0, 0x6ac1, 0x6ac2, + 0x6ac3, 0x6ac4, 0x6ac5, 0x6ac6, 0x6ac7, 0x6ac8, 0x6ac9, 0x6aca, + 0x6acb, 0x6acc, 0x6acd, 0x6ace, 0x6acf, 0x6ad0, 0x6ad1, 0x6ad2, + 0x6ad3, 0x6ad4, 0x6ad5, 0x6ad6, 0x6ad7, 0x6ad8, 0x6ad9, 0x6ada, + 0x6adb, 0x6adc, 0x6add, 0x6ade, 0x6adf, 0x6ae0, 0x6ae1, 0x6ae2, + 0x6ae3, 0x6ae4, 0x6ae5, 0x6ae6, 0x6ae7, 0x6ae8, 0x6ae9, 0x6aea, + 0x6aeb, 0x6aec, 0x6aed, 0x6aee, 0x6aef, 0x6af0, 0x6af1, 0x6af2, + 0x6af3, 0x6af4, 0x6af5, 0x6af6, 0x6af7, 0x6af8, 0x6af9, 0x6afa, + 0x6afb, 0x6afc, 0x6afd, 0x6afe, 0x6aff, 0x6b00, 0x6b01, 0x6b02, + 0x6b03, 0x6b04, 0x6b05, 0x6b06, 0x6b07, 0x6b08, 0x6b09, 0x6b0a, + 0x6b0b, 0x6b0c, 0x6b0d, 0x6b0e, 0x6b0f, 0x6b10, 0x6b11, 0x6b12, + 0x6b13, 0x6b14, 0x6b15, 0x6b16, 0x6b17, 0x6b18, 0x6b19, 0x6b1a, + 0x6b1b, 0x6b1c, 0x6b1d, 0x6b1e, 0x6b1f, 0x6b25, 0x6b26, 0x6b28, + 0x6b29, 0x6b2a, 0x6b2b, 0x6b2c, 0x6b2d, 0x6b2e, + /* 0x9a */ + 0x6b2f, 0x6b30, 0x6b31, 0x6b33, 0x6b34, 0x6b35, 0x6b36, 0x6b38, + 0x6b3b, 0x6b3c, 0x6b3d, 0x6b3f, 0x6b40, 0x6b41, 0x6b42, 0x6b44, + 0x6b45, 0x6b48, 0x6b4a, 0x6b4b, 0x6b4d, 0x6b4e, 0x6b4f, 0x6b50, + 0x6b51, 0x6b52, 0x6b53, 0x6b54, 0x6b55, 0x6b56, 0x6b57, 0x6b58, + 0x6b5a, 0x6b5b, 0x6b5c, 0x6b5d, 0x6b5e, 0x6b5f, 0x6b60, 0x6b61, + 0x6b68, 0x6b69, 0x6b6b, 0x6b6c, 0x6b6d, 0x6b6e, 0x6b6f, 0x6b70, + 0x6b71, 0x6b72, 0x6b73, 0x6b74, 0x6b75, 0x6b76, 0x6b77, 0x6b78, + 0x6b7a, 0x6b7d, 0x6b7e, 0x6b7f, 0x6b80, 0x6b85, 0x6b88, 0x6b8c, + 0x6b8e, 0x6b8f, 0x6b90, 0x6b91, 0x6b94, 0x6b95, 0x6b97, 0x6b98, + 0x6b99, 0x6b9c, 0x6b9d, 0x6b9e, 0x6b9f, 0x6ba0, 0x6ba2, 0x6ba3, + 0x6ba4, 0x6ba5, 0x6ba6, 0x6ba7, 0x6ba8, 0x6ba9, 0x6bab, 0x6bac, + 0x6bad, 0x6bae, 0x6baf, 0x6bb0, 0x6bb1, 0x6bb2, 0x6bb6, 0x6bb8, + 0x6bb9, 0x6bba, 0x6bbb, 0x6bbc, 0x6bbd, 0x6bbe, 0x6bc0, 0x6bc3, + 0x6bc4, 0x6bc6, 0x6bc7, 0x6bc8, 0x6bc9, 0x6bca, 0x6bcc, 0x6bce, + 0x6bd0, 0x6bd1, 0x6bd8, 0x6bda, 0x6bdc, 0x6bdd, 0x6bde, 0x6bdf, + 0x6be0, 0x6be2, 0x6be3, 0x6be4, 0x6be5, 0x6be6, 0x6be7, 0x6be8, + 0x6be9, 0x6bec, 0x6bed, 0x6bee, 0x6bf0, 0x6bf1, 0x6bf2, 0x6bf4, + 0x6bf6, 0x6bf7, 0x6bf8, 0x6bfa, 0x6bfb, 0x6bfc, 0x6bfe, 0x6bff, + 0x6c00, 0x6c01, 0x6c02, 0x6c03, 0x6c04, 0x6c08, 0x6c09, 0x6c0a, + 0x6c0b, 0x6c0c, 0x6c0e, 0x6c12, 0x6c17, 0x6c1c, 0x6c1d, 0x6c1e, + 0x6c20, 0x6c23, 0x6c25, 0x6c2b, 0x6c2c, 0x6c2d, 0x6c31, 0x6c33, + 0x6c36, 0x6c37, 0x6c39, 0x6c3a, 0x6c3b, 0x6c3c, 0x6c3e, 0x6c3f, + 0x6c43, 0x6c44, 0x6c45, 0x6c48, 0x6c4b, 0x6c4c, 0x6c4d, 0x6c4e, + 0x6c4f, 0x6c51, 0x6c52, 0x6c53, 0x6c56, 0x6c58, + /* 0x9b */ + 0x6c59, 0x6c5a, 0x6c62, 0x6c63, 0x6c65, 0x6c66, 0x6c67, 0x6c6b, + 0x6c6c, 0x6c6d, 0x6c6e, 0x6c6f, 0x6c71, 0x6c73, 0x6c75, 0x6c77, + 0x6c78, 0x6c7a, 0x6c7b, 0x6c7c, 0x6c7f, 0x6c80, 0x6c84, 0x6c87, + 0x6c8a, 0x6c8b, 0x6c8d, 0x6c8e, 0x6c91, 0x6c92, 0x6c95, 0x6c96, + 0x6c97, 0x6c98, 0x6c9a, 0x6c9c, 0x6c9d, 0x6c9e, 0x6ca0, 0x6ca2, + 0x6ca8, 0x6cac, 0x6caf, 0x6cb0, 0x6cb4, 0x6cb5, 0x6cb6, 0x6cb7, + 0x6cba, 0x6cc0, 0x6cc1, 0x6cc2, 0x6cc3, 0x6cc6, 0x6cc7, 0x6cc8, + 0x6ccb, 0x6ccd, 0x6cce, 0x6ccf, 0x6cd1, 0x6cd2, 0x6cd8, 0x6cd9, + 0x6cda, 0x6cdc, 0x6cdd, 0x6cdf, 0x6ce4, 0x6ce6, 0x6ce7, 0x6ce9, + 0x6cec, 0x6ced, 0x6cf2, 0x6cf4, 0x6cf9, 0x6cff, 0x6d00, 0x6d02, + 0x6d03, 0x6d05, 0x6d06, 0x6d08, 0x6d09, 0x6d0a, 0x6d0d, 0x6d0f, + 0x6d10, 0x6d11, 0x6d13, 0x6d14, 0x6d15, 0x6d16, 0x6d18, 0x6d1c, + 0x6d1d, 0x6d1f, 0x6d20, 0x6d21, 0x6d22, 0x6d23, 0x6d24, 0x6d26, + 0x6d28, 0x6d29, 0x6d2c, 0x6d2d, 0x6d2f, 0x6d30, 0x6d34, 0x6d36, + 0x6d37, 0x6d38, 0x6d3a, 0x6d3f, 0x6d40, 0x6d42, 0x6d44, 0x6d49, + 0x6d4c, 0x6d50, 0x6d55, 0x6d56, 0x6d57, 0x6d58, 0x6d5b, 0x6d5d, + 0x6d5f, 0x6d61, 0x6d62, 0x6d64, 0x6d65, 0x6d67, 0x6d68, 0x6d6b, + 0x6d6c, 0x6d6d, 0x6d70, 0x6d71, 0x6d72, 0x6d73, 0x6d75, 0x6d76, + 0x6d79, 0x6d7a, 0x6d7b, 0x6d7d, 0x6d7e, 0x6d7f, 0x6d80, 0x6d81, + 0x6d83, 0x6d84, 0x6d86, 0x6d87, 0x6d8a, 0x6d8b, 0x6d8d, 0x6d8f, + 0x6d90, 0x6d92, 0x6d96, 0x6d97, 0x6d98, 0x6d99, 0x6d9a, 0x6d9c, + 0x6da2, 0x6da5, 0x6dac, 0x6dad, 0x6db0, 0x6db1, 0x6db3, 0x6db4, + 0x6db6, 0x6db7, 0x6db9, 0x6dba, 0x6dbb, 0x6dbc, 0x6dbd, 0x6dbe, + 0x6dc1, 0x6dc2, 0x6dc3, 0x6dc8, 0x6dc9, 0x6dca, + /* 0x9c */ + 0x6dcd, 0x6dce, 0x6dcf, 0x6dd0, 0x6dd2, 0x6dd3, 0x6dd4, 0x6dd5, + 0x6dd7, 0x6dda, 0x6ddb, 0x6ddc, 0x6ddf, 0x6de2, 0x6de3, 0x6de5, + 0x6de7, 0x6de8, 0x6de9, 0x6dea, 0x6ded, 0x6def, 0x6df0, 0x6df2, + 0x6df4, 0x6df5, 0x6df6, 0x6df8, 0x6dfa, 0x6dfd, 0x6dfe, 0x6dff, + 0x6e00, 0x6e01, 0x6e02, 0x6e03, 0x6e04, 0x6e06, 0x6e07, 0x6e08, + 0x6e09, 0x6e0b, 0x6e0f, 0x6e12, 0x6e13, 0x6e15, 0x6e18, 0x6e19, + 0x6e1b, 0x6e1c, 0x6e1e, 0x6e1f, 0x6e22, 0x6e26, 0x6e27, 0x6e28, + 0x6e2a, 0x6e2c, 0x6e2e, 0x6e30, 0x6e31, 0x6e33, 0x6e35, 0x6e36, + 0x6e37, 0x6e39, 0x6e3b, 0x6e3c, 0x6e3d, 0x6e3e, 0x6e3f, 0x6e40, + 0x6e41, 0x6e42, 0x6e45, 0x6e46, 0x6e47, 0x6e48, 0x6e49, 0x6e4a, + 0x6e4b, 0x6e4c, 0x6e4f, 0x6e50, 0x6e51, 0x6e52, 0x6e55, 0x6e57, + 0x6e59, 0x6e5a, 0x6e5c, 0x6e5d, 0x6e5e, 0x6e60, 0x6e61, 0x6e62, + 0x6e63, 0x6e64, 0x6e65, 0x6e66, 0x6e67, 0x6e68, 0x6e69, 0x6e6a, + 0x6e6c, 0x6e6d, 0x6e6f, 0x6e70, 0x6e71, 0x6e72, 0x6e73, 0x6e74, + 0x6e75, 0x6e76, 0x6e77, 0x6e78, 0x6e79, 0x6e7a, 0x6e7b, 0x6e7c, + 0x6e7d, 0x6e80, 0x6e81, 0x6e82, 0x6e84, 0x6e87, 0x6e88, 0x6e8a, + 0x6e8b, 0x6e8c, 0x6e8d, 0x6e8e, 0x6e91, 0x6e92, 0x6e93, 0x6e94, + 0x6e95, 0x6e96, 0x6e97, 0x6e99, 0x6e9a, 0x6e9b, 0x6e9d, 0x6e9e, + 0x6ea0, 0x6ea1, 0x6ea3, 0x6ea4, 0x6ea6, 0x6ea8, 0x6ea9, 0x6eab, + 0x6eac, 0x6ead, 0x6eae, 0x6eb0, 0x6eb3, 0x6eb5, 0x6eb8, 0x6eb9, + 0x6ebc, 0x6ebe, 0x6ebf, 0x6ec0, 0x6ec3, 0x6ec4, 0x6ec5, 0x6ec6, + 0x6ec8, 0x6ec9, 0x6eca, 0x6ecc, 0x6ecd, 0x6ece, 0x6ed0, 0x6ed2, + 0x6ed6, 0x6ed8, 0x6ed9, 0x6edb, 0x6edc, 0x6edd, 0x6ee3, 0x6ee7, + 0x6eea, 0x6eeb, 0x6eec, 0x6eed, 0x6eee, 0x6eef, + /* 0x9d */ + 0x6ef0, 0x6ef1, 0x6ef2, 0x6ef3, 0x6ef5, 0x6ef6, 0x6ef7, 0x6ef8, + 0x6efa, 0x6efb, 0x6efc, 0x6efd, 0x6efe, 0x6eff, 0x6f00, 0x6f01, + 0x6f03, 0x6f04, 0x6f05, 0x6f07, 0x6f08, 0x6f0a, 0x6f0b, 0x6f0c, + 0x6f0d, 0x6f0e, 0x6f10, 0x6f11, 0x6f12, 0x6f16, 0x6f17, 0x6f18, + 0x6f19, 0x6f1a, 0x6f1b, 0x6f1c, 0x6f1d, 0x6f1e, 0x6f1f, 0x6f21, + 0x6f22, 0x6f23, 0x6f25, 0x6f26, 0x6f27, 0x6f28, 0x6f2c, 0x6f2e, + 0x6f30, 0x6f32, 0x6f34, 0x6f35, 0x6f37, 0x6f38, 0x6f39, 0x6f3a, + 0x6f3b, 0x6f3c, 0x6f3d, 0x6f3f, 0x6f40, 0x6f41, 0x6f42, 0x6f43, + 0x6f44, 0x6f45, 0x6f48, 0x6f49, 0x6f4a, 0x6f4c, 0x6f4e, 0x6f4f, + 0x6f50, 0x6f51, 0x6f52, 0x6f53, 0x6f54, 0x6f55, 0x6f56, 0x6f57, + 0x6f59, 0x6f5a, 0x6f5b, 0x6f5d, 0x6f5f, 0x6f60, 0x6f61, 0x6f63, + 0x6f64, 0x6f65, 0x6f67, 0x6f68, 0x6f69, 0x6f6a, 0x6f6b, 0x6f6c, + 0x6f6f, 0x6f70, 0x6f71, 0x6f73, 0x6f75, 0x6f76, 0x6f77, 0x6f79, + 0x6f7b, 0x6f7d, 0x6f7e, 0x6f7f, 0x6f80, 0x6f81, 0x6f82, 0x6f83, + 0x6f85, 0x6f86, 0x6f87, 0x6f8a, 0x6f8b, 0x6f8f, 0x6f90, 0x6f91, + 0x6f92, 0x6f93, 0x6f94, 0x6f95, 0x6f96, 0x6f97, 0x6f98, 0x6f99, + 0x6f9a, 0x6f9b, 0x6f9d, 0x6f9e, 0x6f9f, 0x6fa0, 0x6fa2, 0x6fa3, + 0x6fa4, 0x6fa5, 0x6fa6, 0x6fa8, 0x6fa9, 0x6faa, 0x6fab, 0x6fac, + 0x6fad, 0x6fae, 0x6faf, 0x6fb0, 0x6fb1, 0x6fb2, 0x6fb4, 0x6fb5, + 0x6fb7, 0x6fb8, 0x6fba, 0x6fbb, 0x6fbc, 0x6fbd, 0x6fbe, 0x6fbf, + 0x6fc1, 0x6fc3, 0x6fc4, 0x6fc5, 0x6fc6, 0x6fc7, 0x6fc8, 0x6fca, + 0x6fcb, 0x6fcc, 0x6fcd, 0x6fce, 0x6fcf, 0x6fd0, 0x6fd3, 0x6fd4, + 0x6fd5, 0x6fd6, 0x6fd7, 0x6fd8, 0x6fd9, 0x6fda, 0x6fdb, 0x6fdc, + 0x6fdd, 0x6fdf, 0x6fe2, 0x6fe3, 0x6fe4, 0x6fe5, + /* 0x9e */ + 0x6fe6, 0x6fe7, 0x6fe8, 0x6fe9, 0x6fea, 0x6feb, 0x6fec, 0x6fed, + 0x6ff0, 0x6ff1, 0x6ff2, 0x6ff3, 0x6ff4, 0x6ff5, 0x6ff6, 0x6ff7, + 0x6ff8, 0x6ff9, 0x6ffa, 0x6ffb, 0x6ffc, 0x6ffd, 0x6ffe, 0x6fff, + 0x7000, 0x7001, 0x7002, 0x7003, 0x7004, 0x7005, 0x7006, 0x7007, + 0x7008, 0x7009, 0x700a, 0x700b, 0x700c, 0x700d, 0x700e, 0x700f, + 0x7010, 0x7012, 0x7013, 0x7014, 0x7015, 0x7016, 0x7017, 0x7018, + 0x7019, 0x701c, 0x701d, 0x701e, 0x701f, 0x7020, 0x7021, 0x7022, + 0x7024, 0x7025, 0x7026, 0x7027, 0x7028, 0x7029, 0x702a, 0x702b, + 0x702c, 0x702d, 0x702e, 0x702f, 0x7030, 0x7031, 0x7032, 0x7033, + 0x7034, 0x7036, 0x7037, 0x7038, 0x703a, 0x703b, 0x703c, 0x703d, + 0x703e, 0x703f, 0x7040, 0x7041, 0x7042, 0x7043, 0x7044, 0x7045, + 0x7046, 0x7047, 0x7048, 0x7049, 0x704a, 0x704b, 0x704d, 0x704e, + 0x7050, 0x7051, 0x7052, 0x7053, 0x7054, 0x7055, 0x7056, 0x7057, + 0x7058, 0x7059, 0x705a, 0x705b, 0x705c, 0x705d, 0x705f, 0x7060, + 0x7061, 0x7062, 0x7063, 0x7064, 0x7065, 0x7066, 0x7067, 0x7068, + 0x7069, 0x706a, 0x706e, 0x7071, 0x7072, 0x7073, 0x7074, 0x7077, + 0x7079, 0x707a, 0x707b, 0x707d, 0x7081, 0x7082, 0x7083, 0x7084, + 0x7086, 0x7087, 0x7088, 0x708b, 0x708c, 0x708d, 0x708f, 0x7090, + 0x7091, 0x7093, 0x7097, 0x7098, 0x709a, 0x709b, 0x709e, 0x709f, + 0x70a0, 0x70a1, 0x70a2, 0x70a3, 0x70a4, 0x70a5, 0x70a6, 0x70a7, + 0x70a8, 0x70a9, 0x70aa, 0x70b0, 0x70b2, 0x70b4, 0x70b5, 0x70b6, + 0x70ba, 0x70be, 0x70bf, 0x70c4, 0x70c5, 0x70c6, 0x70c7, 0x70c9, + 0x70cb, 0x70cc, 0x70cd, 0x70ce, 0x70cf, 0x70d0, 0x70d1, 0x70d2, + 0x70d3, 0x70d4, 0x70d5, 0x70d6, 0x70d7, 0x70da, + /* 0x9f */ + 0x70dc, 0x70dd, 0x70de, 0x70e0, 0x70e1, 0x70e2, 0x70e3, 0x70e5, + 0x70ea, 0x70ee, 0x70f0, 0x70f1, 0x70f2, 0x70f3, 0x70f4, 0x70f5, + 0x70f6, 0x70f8, 0x70fa, 0x70fb, 0x70fc, 0x70fe, 0x70ff, 0x7100, + 0x7101, 0x7102, 0x7103, 0x7104, 0x7105, 0x7106, 0x7107, 0x7108, + 0x710b, 0x710c, 0x710d, 0x710e, 0x710f, 0x7111, 0x7112, 0x7114, + 0x7117, 0x711b, 0x711c, 0x711d, 0x711e, 0x711f, 0x7120, 0x7121, + 0x7122, 0x7123, 0x7124, 0x7125, 0x7127, 0x7128, 0x7129, 0x712a, + 0x712b, 0x712c, 0x712d, 0x712e, 0x7132, 0x7133, 0x7134, 0x7135, + 0x7137, 0x7138, 0x7139, 0x713a, 0x713b, 0x713c, 0x713d, 0x713e, + 0x713f, 0x7140, 0x7141, 0x7142, 0x7143, 0x7144, 0x7146, 0x7147, + 0x7148, 0x7149, 0x714b, 0x714d, 0x714f, 0x7150, 0x7151, 0x7152, + 0x7153, 0x7154, 0x7155, 0x7156, 0x7157, 0x7158, 0x7159, 0x715a, + 0x715b, 0x715d, 0x715f, 0x7160, 0x7161, 0x7162, 0x7163, 0x7165, + 0x7169, 0x716a, 0x716b, 0x716c, 0x716d, 0x716f, 0x7170, 0x7171, + 0x7174, 0x7175, 0x7176, 0x7177, 0x7179, 0x717b, 0x717c, 0x717e, + 0x717f, 0x7180, 0x7181, 0x7182, 0x7183, 0x7185, 0x7186, 0x7187, + 0x7188, 0x7189, 0x718b, 0x718c, 0x718d, 0x718e, 0x7190, 0x7191, + 0x7192, 0x7193, 0x7195, 0x7196, 0x7197, 0x719a, 0x719b, 0x719c, + 0x719d, 0x719e, 0x71a1, 0x71a2, 0x71a3, 0x71a4, 0x71a5, 0x71a6, + 0x71a7, 0x71a9, 0x71aa, 0x71ab, 0x71ad, 0x71ae, 0x71af, 0x71b0, + 0x71b1, 0x71b2, 0x71b4, 0x71b6, 0x71b7, 0x71b8, 0x71ba, 0x71bb, + 0x71bc, 0x71bd, 0x71be, 0x71bf, 0x71c0, 0x71c1, 0x71c2, 0x71c4, + 0x71c5, 0x71c6, 0x71c7, 0x71c8, 0x71c9, 0x71ca, 0x71cb, 0x71cc, + 0x71cd, 0x71cf, 0x71d0, 0x71d1, 0x71d2, 0x71d3, + /* 0xa0 */ + 0x71d6, 0x71d7, 0x71d8, 0x71d9, 0x71da, 0x71db, 0x71dc, 0x71dd, + 0x71de, 0x71df, 0x71e1, 0x71e2, 0x71e3, 0x71e4, 0x71e6, 0x71e8, + 0x71e9, 0x71ea, 0x71eb, 0x71ec, 0x71ed, 0x71ef, 0x71f0, 0x71f1, + 0x71f2, 0x71f3, 0x71f4, 0x71f5, 0x71f6, 0x71f7, 0x71f8, 0x71fa, + 0x71fb, 0x71fc, 0x71fd, 0x71fe, 0x71ff, 0x7200, 0x7201, 0x7202, + 0x7203, 0x7204, 0x7205, 0x7207, 0x7208, 0x7209, 0x720a, 0x720b, + 0x720c, 0x720d, 0x720e, 0x720f, 0x7210, 0x7211, 0x7212, 0x7213, + 0x7214, 0x7215, 0x7216, 0x7217, 0x7218, 0x7219, 0x721a, 0x721b, + 0x721c, 0x721e, 0x721f, 0x7220, 0x7221, 0x7222, 0x7223, 0x7224, + 0x7225, 0x7226, 0x7227, 0x7229, 0x722b, 0x722d, 0x722e, 0x722f, + 0x7232, 0x7233, 0x7234, 0x723a, 0x723c, 0x723e, 0x7240, 0x7241, + 0x7242, 0x7243, 0x7244, 0x7245, 0x7246, 0x7249, 0x724a, 0x724b, + 0x724e, 0x724f, 0x7250, 0x7251, 0x7253, 0x7254, 0x7255, 0x7257, + 0x7258, 0x725a, 0x725c, 0x725e, 0x7260, 0x7263, 0x7264, 0x7265, + 0x7268, 0x726a, 0x726b, 0x726c, 0x726d, 0x7270, 0x7271, 0x7273, + 0x7274, 0x7276, 0x7277, 0x7278, 0x727b, 0x727c, 0x727d, 0x7282, + 0x7283, 0x7285, 0x7286, 0x7287, 0x7288, 0x7289, 0x728c, 0x728e, + 0x7290, 0x7291, 0x7293, 0x7294, 0x7295, 0x7296, 0x7297, 0x7298, + 0x7299, 0x729a, 0x729b, 0x729c, 0x729d, 0x729e, 0x72a0, 0x72a1, + 0x72a2, 0x72a3, 0x72a4, 0x72a5, 0x72a6, 0x72a7, 0x72a8, 0x72a9, + 0x72aa, 0x72ab, 0x72ae, 0x72b1, 0x72b2, 0x72b3, 0x72b5, 0x72ba, + 0x72bb, 0x72bc, 0x72bd, 0x72be, 0x72bf, 0x72c0, 0x72c5, 0x72c6, + 0x72c7, 0x72c9, 0x72ca, 0x72cb, 0x72cc, 0x72cf, 0x72d1, 0x72d3, + 0x72d4, 0x72d5, 0x72d6, 0x72d8, 0x72da, 0x72db, +}; + +static int +gbkext1_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x81 && c1 <= 0xa0)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0x80 && c2 < 0xff)) { + unsigned int i = 190 * (c1 - 0x81) + (c2 - (c2 >= 0x80 ? 0x41 : 0x40)); + unsigned short wc = 0xfffd; + { + if (i < 6080) + wc = gbkext1_2uni_page81[i]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + diff --git a/graf2d/win32gdk/gdk/src/iconv/gbkext2.h b/graf2d/win32gdk/gdk/src/iconv/gbkext2.h new file mode 100644 index 0000000000000..5a0dbdec57fef --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/gbkext2.h @@ -0,0 +1,1174 @@ +/* + * Copyright (C) 1999-2000 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GBK/4 and GBK/5 extensions + */ + +static const unsigned short gbkext2_2uni_pagea8[8272] = { + /* 0xa8 */ + 0x02ca, 0x02cb, 0x02d9, 0x2013, 0x2015, 0x2025, 0x2035, 0x2105, + 0x2109, 0x2196, 0x2197, 0x2198, 0x2199, 0x2215, 0x221f, 0x2223, + 0x2252, 0x2266, 0x2267, 0x22bf, 0x2550, 0x2551, 0x2552, 0x2553, + 0x2554, 0x2555, 0x2556, 0x2557, 0x2558, 0x2559, 0x255a, 0x255b, + 0x255c, 0x255d, 0x255e, 0x255f, 0x2560, 0x2561, 0x2562, 0x2563, + 0x2564, 0x2565, 0x2566, 0x2567, 0x2568, 0x2569, 0x256a, 0x256b, + 0x256c, 0x256d, 0x256e, 0x256f, 0x2570, 0x2571, 0x2572, 0x2573, + 0x2581, 0x2582, 0x2583, 0x2584, 0x2585, 0x2586, 0x2587, 0x2588, + 0x2589, 0x258a, 0x258b, 0x258c, 0x258d, 0x258e, 0x258f, 0x2593, + 0x2594, 0x2595, 0x25bc, 0x25bd, 0x25e2, 0x25e3, 0x25e4, 0x25e5, + 0x2609, 0x2295, 0x3012, 0x301d, 0x301e, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xa9 */ + 0x3021, 0x3022, 0x3023, 0x3024, 0x3025, 0x3026, 0x3027, 0x3028, + 0x3029, 0x32a3, 0x338e, 0x338f, 0x339c, 0x339d, 0x339e, 0x33a1, + 0x33c4, 0x33ce, 0x33d1, 0x33d2, 0x33d5, 0xfe30, 0xffe2, 0xffe4, + 0xfffd, 0x2121, 0x3231, 0xfffd, 0x2010, 0xfffd, 0xfffd, 0xfffd, + 0x30fc, 0x309b, 0x309c, 0x30fd, 0x30fe, 0x3006, 0x309d, 0x309e, + 0xfe49, 0xfe4a, 0xfe4b, 0xfe4c, 0xfe4d, 0xfe4e, 0xfe4f, 0xfe50, + 0xfe51, 0xfe52, 0xfe54, 0xfe55, 0xfe56, 0xfe57, 0xfe59, 0xfe5a, + 0xfe5b, 0xfe5c, 0xfe5d, 0xfe5e, 0xfe5f, 0xfe60, 0xfe61, 0xfe62, + 0xfe63, 0xfe64, 0xfe65, 0xfe66, 0xfe68, 0xfe69, 0xfe6a, 0xfe6b, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x3007, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xaa */ + 0x72dc, 0x72dd, 0x72df, 0x72e2, 0x72e3, 0x72e4, 0x72e5, 0x72e6, + 0x72e7, 0x72ea, 0x72eb, 0x72f5, 0x72f6, 0x72f9, 0x72fd, 0x72fe, + 0x72ff, 0x7300, 0x7302, 0x7304, 0x7305, 0x7306, 0x7307, 0x7308, + 0x7309, 0x730b, 0x730c, 0x730d, 0x730f, 0x7310, 0x7311, 0x7312, + 0x7314, 0x7318, 0x7319, 0x731a, 0x731f, 0x7320, 0x7323, 0x7324, + 0x7326, 0x7327, 0x7328, 0x732d, 0x732f, 0x7330, 0x7332, 0x7333, + 0x7335, 0x7336, 0x733a, 0x733b, 0x733c, 0x733d, 0x7340, 0x7341, + 0x7342, 0x7343, 0x7344, 0x7345, 0x7346, 0x7347, 0x7348, 0x7349, + 0x734a, 0x734b, 0x734c, 0x734e, 0x734f, 0x7351, 0x7353, 0x7354, + 0x7355, 0x7356, 0x7358, 0x7359, 0x735a, 0x735b, 0x735c, 0x735d, + 0x735e, 0x735f, 0x7361, 0x7362, 0x7363, 0x7364, 0x7365, 0x7366, + 0x7367, 0x7368, 0x7369, 0x736a, 0x736b, 0x736e, 0x7370, 0x7371, + /* 0xab */ + 0x7372, 0x7373, 0x7374, 0x7375, 0x7376, 0x7377, 0x7378, 0x7379, + 0x737a, 0x737b, 0x737c, 0x737d, 0x737f, 0x7380, 0x7381, 0x7382, + 0x7383, 0x7385, 0x7386, 0x7388, 0x738a, 0x738c, 0x738d, 0x738f, + 0x7390, 0x7392, 0x7393, 0x7394, 0x7395, 0x7397, 0x7398, 0x7399, + 0x739a, 0x739c, 0x739d, 0x739e, 0x73a0, 0x73a1, 0x73a3, 0x73a4, + 0x73a5, 0x73a6, 0x73a7, 0x73a8, 0x73aa, 0x73ac, 0x73ad, 0x73b1, + 0x73b4, 0x73b5, 0x73b6, 0x73b8, 0x73b9, 0x73bc, 0x73bd, 0x73be, + 0x73bf, 0x73c1, 0x73c3, 0x73c4, 0x73c5, 0x73c6, 0x73c7, 0x73cb, + 0x73cc, 0x73ce, 0x73d2, 0x73d3, 0x73d4, 0x73d5, 0x73d6, 0x73d7, + 0x73d8, 0x73da, 0x73db, 0x73dc, 0x73dd, 0x73df, 0x73e1, 0x73e2, + 0x73e3, 0x73e4, 0x73e6, 0x73e8, 0x73ea, 0x73eb, 0x73ec, 0x73ee, + 0x73ef, 0x73f0, 0x73f1, 0x73f3, 0x73f4, 0x73f5, 0x73f6, 0x73f7, + /* 0xac */ + 0x73f8, 0x73f9, 0x73fa, 0x73fb, 0x73fc, 0x73fd, 0x73fe, 0x73ff, + 0x7400, 0x7401, 0x7402, 0x7404, 0x7407, 0x7408, 0x740b, 0x740c, + 0x740d, 0x740e, 0x7411, 0x7412, 0x7413, 0x7414, 0x7415, 0x7416, + 0x7417, 0x7418, 0x7419, 0x741c, 0x741d, 0x741e, 0x741f, 0x7420, + 0x7421, 0x7423, 0x7424, 0x7427, 0x7429, 0x742b, 0x742d, 0x742f, + 0x7431, 0x7432, 0x7437, 0x7438, 0x7439, 0x743a, 0x743b, 0x743d, + 0x743e, 0x743f, 0x7440, 0x7442, 0x7443, 0x7444, 0x7445, 0x7446, + 0x7447, 0x7448, 0x7449, 0x744a, 0x744b, 0x744c, 0x744d, 0x744e, + 0x744f, 0x7450, 0x7451, 0x7452, 0x7453, 0x7454, 0x7456, 0x7458, + 0x745d, 0x7460, 0x7461, 0x7462, 0x7463, 0x7464, 0x7465, 0x7466, + 0x7467, 0x7468, 0x7469, 0x746a, 0x746b, 0x746c, 0x746e, 0x746f, + 0x7471, 0x7472, 0x7473, 0x7474, 0x7475, 0x7478, 0x7479, 0x747a, + /* 0xad */ + 0x747b, 0x747c, 0x747d, 0x747f, 0x7482, 0x7484, 0x7485, 0x7486, + 0x7488, 0x7489, 0x748a, 0x748c, 0x748d, 0x748f, 0x7491, 0x7492, + 0x7493, 0x7494, 0x7495, 0x7496, 0x7497, 0x7498, 0x7499, 0x749a, + 0x749b, 0x749d, 0x749f, 0x74a0, 0x74a1, 0x74a2, 0x74a3, 0x74a4, + 0x74a5, 0x74a6, 0x74aa, 0x74ab, 0x74ac, 0x74ad, 0x74ae, 0x74af, + 0x74b0, 0x74b1, 0x74b2, 0x74b3, 0x74b4, 0x74b5, 0x74b6, 0x74b7, + 0x74b8, 0x74b9, 0x74bb, 0x74bc, 0x74bd, 0x74be, 0x74bf, 0x74c0, + 0x74c1, 0x74c2, 0x74c3, 0x74c4, 0x74c5, 0x74c6, 0x74c7, 0x74c8, + 0x74c9, 0x74ca, 0x74cb, 0x74cc, 0x74cd, 0x74ce, 0x74cf, 0x74d0, + 0x74d1, 0x74d3, 0x74d4, 0x74d5, 0x74d6, 0x74d7, 0x74d8, 0x74d9, + 0x74da, 0x74db, 0x74dd, 0x74df, 0x74e1, 0x74e5, 0x74e7, 0x74e8, + 0x74e9, 0x74ea, 0x74eb, 0x74ec, 0x74ed, 0x74f0, 0x74f1, 0x74f2, + /* 0xae */ + 0x74f3, 0x74f5, 0x74f8, 0x74f9, 0x74fa, 0x74fb, 0x74fc, 0x74fd, + 0x74fe, 0x7500, 0x7501, 0x7502, 0x7503, 0x7505, 0x7506, 0x7507, + 0x7508, 0x7509, 0x750a, 0x750b, 0x750c, 0x750e, 0x7510, 0x7512, + 0x7514, 0x7515, 0x7516, 0x7517, 0x751b, 0x751d, 0x751e, 0x7520, + 0x7521, 0x7522, 0x7523, 0x7524, 0x7526, 0x7527, 0x752a, 0x752e, + 0x7534, 0x7536, 0x7539, 0x753c, 0x753d, 0x753f, 0x7541, 0x7542, + 0x7543, 0x7544, 0x7546, 0x7547, 0x7549, 0x754a, 0x754d, 0x7550, + 0x7551, 0x7552, 0x7553, 0x7555, 0x7556, 0x7557, 0x7558, 0x755d, + 0x755e, 0x755f, 0x7560, 0x7561, 0x7562, 0x7563, 0x7564, 0x7567, + 0x7568, 0x7569, 0x756b, 0x756c, 0x756d, 0x756e, 0x756f, 0x7570, + 0x7571, 0x7573, 0x7575, 0x7576, 0x7577, 0x757a, 0x757b, 0x757c, + 0x757d, 0x757e, 0x7580, 0x7581, 0x7582, 0x7584, 0x7585, 0x7587, + /* 0xaf */ + 0x7588, 0x7589, 0x758a, 0x758c, 0x758d, 0x758e, 0x7590, 0x7593, + 0x7595, 0x7598, 0x759b, 0x759c, 0x759e, 0x75a2, 0x75a6, 0x75a7, + 0x75a8, 0x75a9, 0x75aa, 0x75ad, 0x75b6, 0x75b7, 0x75ba, 0x75bb, + 0x75bf, 0x75c0, 0x75c1, 0x75c6, 0x75cb, 0x75cc, 0x75ce, 0x75cf, + 0x75d0, 0x75d1, 0x75d3, 0x75d7, 0x75d9, 0x75da, 0x75dc, 0x75dd, + 0x75df, 0x75e0, 0x75e1, 0x75e5, 0x75e9, 0x75ec, 0x75ed, 0x75ee, + 0x75ef, 0x75f2, 0x75f3, 0x75f5, 0x75f6, 0x75f7, 0x75f8, 0x75fa, + 0x75fb, 0x75fd, 0x75fe, 0x7602, 0x7604, 0x7606, 0x7607, 0x7608, + 0x7609, 0x760b, 0x760d, 0x760e, 0x760f, 0x7611, 0x7612, 0x7613, + 0x7614, 0x7616, 0x761a, 0x761c, 0x761d, 0x761e, 0x7621, 0x7623, + 0x7627, 0x7628, 0x762c, 0x762e, 0x762f, 0x7631, 0x7632, 0x7636, + 0x7637, 0x7639, 0x763a, 0x763b, 0x763d, 0x7641, 0x7642, 0x7644, + /* 0xb0 */ + 0x7645, 0x7646, 0x7647, 0x7648, 0x7649, 0x764a, 0x764b, 0x764e, + 0x764f, 0x7650, 0x7651, 0x7652, 0x7653, 0x7655, 0x7657, 0x7658, + 0x7659, 0x765a, 0x765b, 0x765d, 0x765f, 0x7660, 0x7661, 0x7662, + 0x7664, 0x7665, 0x7666, 0x7667, 0x7668, 0x7669, 0x766a, 0x766c, + 0x766d, 0x766e, 0x7670, 0x7671, 0x7672, 0x7673, 0x7674, 0x7675, + 0x7676, 0x7677, 0x7679, 0x767a, 0x767c, 0x767f, 0x7680, 0x7681, + 0x7683, 0x7685, 0x7689, 0x768a, 0x768c, 0x768d, 0x768f, 0x7690, + 0x7692, 0x7694, 0x7695, 0x7697, 0x7698, 0x769a, 0x769b, 0x769c, + 0x769d, 0x769e, 0x769f, 0x76a0, 0x76a1, 0x76a2, 0x76a3, 0x76a5, + 0x76a6, 0x76a7, 0x76a8, 0x76a9, 0x76aa, 0x76ab, 0x76ac, 0x76ad, + 0x76af, 0x76b0, 0x76b3, 0x76b5, 0x76b6, 0x76b7, 0x76b8, 0x76b9, + 0x76ba, 0x76bb, 0x76bc, 0x76bd, 0x76be, 0x76c0, 0x76c1, 0x76c3, + /* 0xb1 */ + 0x76c4, 0x76c7, 0x76c9, 0x76cb, 0x76cc, 0x76d3, 0x76d5, 0x76d9, + 0x76da, 0x76dc, 0x76dd, 0x76de, 0x76e0, 0x76e1, 0x76e2, 0x76e3, + 0x76e4, 0x76e6, 0x76e7, 0x76e8, 0x76e9, 0x76ea, 0x76eb, 0x76ec, + 0x76ed, 0x76f0, 0x76f3, 0x76f5, 0x76f6, 0x76f7, 0x76fa, 0x76fb, + 0x76fd, 0x76ff, 0x7700, 0x7702, 0x7703, 0x7705, 0x7706, 0x770a, + 0x770c, 0x770e, 0x770f, 0x7710, 0x7711, 0x7712, 0x7713, 0x7714, + 0x7715, 0x7716, 0x7717, 0x7718, 0x771b, 0x771c, 0x771d, 0x771e, + 0x7721, 0x7723, 0x7724, 0x7725, 0x7727, 0x772a, 0x772b, 0x772c, + 0x772e, 0x7730, 0x7731, 0x7732, 0x7733, 0x7734, 0x7739, 0x773b, + 0x773d, 0x773e, 0x773f, 0x7742, 0x7744, 0x7745, 0x7746, 0x7748, + 0x7749, 0x774a, 0x774b, 0x774c, 0x774d, 0x774e, 0x774f, 0x7752, + 0x7753, 0x7754, 0x7755, 0x7756, 0x7757, 0x7758, 0x7759, 0x775c, + /* 0xb2 */ + 0x775d, 0x775e, 0x775f, 0x7760, 0x7764, 0x7767, 0x7769, 0x776a, + 0x776d, 0x776e, 0x776f, 0x7770, 0x7771, 0x7772, 0x7773, 0x7774, + 0x7775, 0x7776, 0x7777, 0x7778, 0x777a, 0x777b, 0x777c, 0x7781, + 0x7782, 0x7783, 0x7786, 0x7787, 0x7788, 0x7789, 0x778a, 0x778b, + 0x778f, 0x7790, 0x7793, 0x7794, 0x7795, 0x7796, 0x7797, 0x7798, + 0x7799, 0x779a, 0x779b, 0x779c, 0x779d, 0x779e, 0x77a1, 0x77a3, + 0x77a4, 0x77a6, 0x77a8, 0x77ab, 0x77ad, 0x77ae, 0x77af, 0x77b1, + 0x77b2, 0x77b4, 0x77b6, 0x77b7, 0x77b8, 0x77b9, 0x77ba, 0x77bc, + 0x77be, 0x77c0, 0x77c1, 0x77c2, 0x77c3, 0x77c4, 0x77c5, 0x77c6, + 0x77c7, 0x77c8, 0x77c9, 0x77ca, 0x77cb, 0x77cc, 0x77ce, 0x77cf, + 0x77d0, 0x77d1, 0x77d2, 0x77d3, 0x77d4, 0x77d5, 0x77d6, 0x77d8, + 0x77d9, 0x77da, 0x77dd, 0x77de, 0x77df, 0x77e0, 0x77e1, 0x77e4, + /* 0xb3 */ + 0x77e6, 0x77e8, 0x77ea, 0x77ef, 0x77f0, 0x77f1, 0x77f2, 0x77f4, + 0x77f5, 0x77f7, 0x77f9, 0x77fa, 0x77fb, 0x77fc, 0x7803, 0x7804, + 0x7805, 0x7806, 0x7807, 0x7808, 0x780a, 0x780b, 0x780e, 0x780f, + 0x7810, 0x7813, 0x7815, 0x7819, 0x781b, 0x781e, 0x7820, 0x7821, + 0x7822, 0x7824, 0x7828, 0x782a, 0x782b, 0x782e, 0x782f, 0x7831, + 0x7832, 0x7833, 0x7835, 0x7836, 0x783d, 0x783f, 0x7841, 0x7842, + 0x7843, 0x7844, 0x7846, 0x7848, 0x7849, 0x784a, 0x784b, 0x784d, + 0x784f, 0x7851, 0x7853, 0x7854, 0x7858, 0x7859, 0x785a, 0x785b, + 0x785c, 0x785e, 0x785f, 0x7860, 0x7861, 0x7862, 0x7863, 0x7864, + 0x7865, 0x7866, 0x7867, 0x7868, 0x7869, 0x786f, 0x7870, 0x7871, + 0x7872, 0x7873, 0x7874, 0x7875, 0x7876, 0x7878, 0x7879, 0x787a, + 0x787b, 0x787d, 0x787e, 0x787f, 0x7880, 0x7881, 0x7882, 0x7883, + /* 0xb4 */ + 0x7884, 0x7885, 0x7886, 0x7888, 0x788a, 0x788b, 0x788f, 0x7890, + 0x7892, 0x7894, 0x7895, 0x7896, 0x7899, 0x789d, 0x789e, 0x78a0, + 0x78a2, 0x78a4, 0x78a6, 0x78a8, 0x78a9, 0x78aa, 0x78ab, 0x78ac, + 0x78ad, 0x78ae, 0x78af, 0x78b5, 0x78b6, 0x78b7, 0x78b8, 0x78ba, + 0x78bb, 0x78bc, 0x78bd, 0x78bf, 0x78c0, 0x78c2, 0x78c3, 0x78c4, + 0x78c6, 0x78c7, 0x78c8, 0x78cc, 0x78cd, 0x78ce, 0x78cf, 0x78d1, + 0x78d2, 0x78d3, 0x78d6, 0x78d7, 0x78d8, 0x78da, 0x78db, 0x78dc, + 0x78dd, 0x78de, 0x78df, 0x78e0, 0x78e1, 0x78e2, 0x78e3, 0x78e4, + 0x78e5, 0x78e6, 0x78e7, 0x78e9, 0x78ea, 0x78eb, 0x78ed, 0x78ee, + 0x78ef, 0x78f0, 0x78f1, 0x78f3, 0x78f5, 0x78f6, 0x78f8, 0x78f9, + 0x78fb, 0x78fc, 0x78fd, 0x78fe, 0x78ff, 0x7900, 0x7902, 0x7903, + 0x7904, 0x7906, 0x7907, 0x7908, 0x7909, 0x790a, 0x790b, 0x790c, + /* 0xb5 */ + 0x790d, 0x790e, 0x790f, 0x7910, 0x7911, 0x7912, 0x7914, 0x7915, + 0x7916, 0x7917, 0x7918, 0x7919, 0x791a, 0x791b, 0x791c, 0x791d, + 0x791f, 0x7920, 0x7921, 0x7922, 0x7923, 0x7925, 0x7926, 0x7927, + 0x7928, 0x7929, 0x792a, 0x792b, 0x792c, 0x792d, 0x792e, 0x792f, + 0x7930, 0x7931, 0x7932, 0x7933, 0x7935, 0x7936, 0x7937, 0x7938, + 0x7939, 0x793d, 0x793f, 0x7942, 0x7943, 0x7944, 0x7945, 0x7947, + 0x794a, 0x794b, 0x794c, 0x794d, 0x794e, 0x794f, 0x7950, 0x7951, + 0x7952, 0x7954, 0x7955, 0x7958, 0x7959, 0x7961, 0x7963, 0x7964, + 0x7966, 0x7969, 0x796a, 0x796b, 0x796c, 0x796e, 0x7970, 0x7971, + 0x7972, 0x7973, 0x7974, 0x7975, 0x7976, 0x7979, 0x797b, 0x797c, + 0x797d, 0x797e, 0x797f, 0x7982, 0x7983, 0x7986, 0x7987, 0x7988, + 0x7989, 0x798b, 0x798c, 0x798d, 0x798e, 0x7990, 0x7991, 0x7992, + /* 0xb6 */ + 0x7993, 0x7994, 0x7995, 0x7996, 0x7997, 0x7998, 0x7999, 0x799b, + 0x799c, 0x799d, 0x799e, 0x799f, 0x79a0, 0x79a1, 0x79a2, 0x79a3, + 0x79a4, 0x79a5, 0x79a6, 0x79a8, 0x79a9, 0x79aa, 0x79ab, 0x79ac, + 0x79ad, 0x79ae, 0x79af, 0x79b0, 0x79b1, 0x79b2, 0x79b4, 0x79b5, + 0x79b6, 0x79b7, 0x79b8, 0x79bc, 0x79bf, 0x79c2, 0x79c4, 0x79c5, + 0x79c7, 0x79c8, 0x79ca, 0x79cc, 0x79ce, 0x79cf, 0x79d0, 0x79d3, + 0x79d4, 0x79d6, 0x79d7, 0x79d9, 0x79da, 0x79db, 0x79dc, 0x79dd, + 0x79de, 0x79e0, 0x79e1, 0x79e2, 0x79e5, 0x79e8, 0x79ea, 0x79ec, + 0x79ee, 0x79f1, 0x79f2, 0x79f3, 0x79f4, 0x79f5, 0x79f6, 0x79f7, + 0x79f9, 0x79fa, 0x79fc, 0x79fe, 0x79ff, 0x7a01, 0x7a04, 0x7a05, + 0x7a07, 0x7a08, 0x7a09, 0x7a0a, 0x7a0c, 0x7a0f, 0x7a10, 0x7a11, + 0x7a12, 0x7a13, 0x7a15, 0x7a16, 0x7a18, 0x7a19, 0x7a1b, 0x7a1c, + /* 0xb7 */ + 0x7a1d, 0x7a1f, 0x7a21, 0x7a22, 0x7a24, 0x7a25, 0x7a26, 0x7a27, + 0x7a28, 0x7a29, 0x7a2a, 0x7a2b, 0x7a2c, 0x7a2d, 0x7a2e, 0x7a2f, + 0x7a30, 0x7a31, 0x7a32, 0x7a34, 0x7a35, 0x7a36, 0x7a38, 0x7a3a, + 0x7a3e, 0x7a40, 0x7a41, 0x7a42, 0x7a43, 0x7a44, 0x7a45, 0x7a47, + 0x7a48, 0x7a49, 0x7a4a, 0x7a4b, 0x7a4c, 0x7a4d, 0x7a4e, 0x7a4f, + 0x7a50, 0x7a52, 0x7a53, 0x7a54, 0x7a55, 0x7a56, 0x7a58, 0x7a59, + 0x7a5a, 0x7a5b, 0x7a5c, 0x7a5d, 0x7a5e, 0x7a5f, 0x7a60, 0x7a61, + 0x7a62, 0x7a63, 0x7a64, 0x7a65, 0x7a66, 0x7a67, 0x7a68, 0x7a69, + 0x7a6a, 0x7a6b, 0x7a6c, 0x7a6d, 0x7a6e, 0x7a6f, 0x7a71, 0x7a72, + 0x7a73, 0x7a75, 0x7a7b, 0x7a7c, 0x7a7d, 0x7a7e, 0x7a82, 0x7a85, + 0x7a87, 0x7a89, 0x7a8a, 0x7a8b, 0x7a8c, 0x7a8e, 0x7a8f, 0x7a90, + 0x7a93, 0x7a94, 0x7a99, 0x7a9a, 0x7a9b, 0x7a9e, 0x7aa1, 0x7aa2, + /* 0xb8 */ + 0x7aa3, 0x7aa4, 0x7aa7, 0x7aa9, 0x7aaa, 0x7aab, 0x7aae, 0x7aaf, + 0x7ab0, 0x7ab1, 0x7ab2, 0x7ab4, 0x7ab5, 0x7ab6, 0x7ab7, 0x7ab8, + 0x7ab9, 0x7aba, 0x7abb, 0x7abc, 0x7abd, 0x7abe, 0x7ac0, 0x7ac1, + 0x7ac2, 0x7ac3, 0x7ac4, 0x7ac5, 0x7ac6, 0x7ac7, 0x7ac8, 0x7ac9, + 0x7aca, 0x7acc, 0x7acd, 0x7ace, 0x7acf, 0x7ad0, 0x7ad1, 0x7ad2, + 0x7ad3, 0x7ad4, 0x7ad5, 0x7ad7, 0x7ad8, 0x7ada, 0x7adb, 0x7adc, + 0x7add, 0x7ae1, 0x7ae2, 0x7ae4, 0x7ae7, 0x7ae8, 0x7ae9, 0x7aea, + 0x7aeb, 0x7aec, 0x7aee, 0x7af0, 0x7af1, 0x7af2, 0x7af3, 0x7af4, + 0x7af5, 0x7af6, 0x7af7, 0x7af8, 0x7afb, 0x7afc, 0x7afe, 0x7b00, + 0x7b01, 0x7b02, 0x7b05, 0x7b07, 0x7b09, 0x7b0c, 0x7b0d, 0x7b0e, + 0x7b10, 0x7b12, 0x7b13, 0x7b16, 0x7b17, 0x7b18, 0x7b1a, 0x7b1c, + 0x7b1d, 0x7b1f, 0x7b21, 0x7b22, 0x7b23, 0x7b27, 0x7b29, 0x7b2d, + /* 0xb9 */ + 0x7b2f, 0x7b30, 0x7b32, 0x7b34, 0x7b35, 0x7b36, 0x7b37, 0x7b39, + 0x7b3b, 0x7b3d, 0x7b3f, 0x7b40, 0x7b41, 0x7b42, 0x7b43, 0x7b44, + 0x7b46, 0x7b48, 0x7b4a, 0x7b4d, 0x7b4e, 0x7b53, 0x7b55, 0x7b57, + 0x7b59, 0x7b5c, 0x7b5e, 0x7b5f, 0x7b61, 0x7b63, 0x7b64, 0x7b65, + 0x7b66, 0x7b67, 0x7b68, 0x7b69, 0x7b6a, 0x7b6b, 0x7b6c, 0x7b6d, + 0x7b6f, 0x7b70, 0x7b73, 0x7b74, 0x7b76, 0x7b78, 0x7b7a, 0x7b7c, + 0x7b7d, 0x7b7f, 0x7b81, 0x7b82, 0x7b83, 0x7b84, 0x7b86, 0x7b87, + 0x7b88, 0x7b89, 0x7b8a, 0x7b8b, 0x7b8c, 0x7b8e, 0x7b8f, 0x7b91, + 0x7b92, 0x7b93, 0x7b96, 0x7b98, 0x7b99, 0x7b9a, 0x7b9b, 0x7b9e, + 0x7b9f, 0x7ba0, 0x7ba3, 0x7ba4, 0x7ba5, 0x7bae, 0x7baf, 0x7bb0, + 0x7bb2, 0x7bb3, 0x7bb5, 0x7bb6, 0x7bb7, 0x7bb9, 0x7bba, 0x7bbb, + 0x7bbc, 0x7bbd, 0x7bbe, 0x7bbf, 0x7bc0, 0x7bc2, 0x7bc3, 0x7bc4, + /* 0xba */ + 0x7bc5, 0x7bc8, 0x7bc9, 0x7bca, 0x7bcb, 0x7bcd, 0x7bce, 0x7bcf, + 0x7bd0, 0x7bd2, 0x7bd4, 0x7bd5, 0x7bd6, 0x7bd7, 0x7bd8, 0x7bdb, + 0x7bdc, 0x7bde, 0x7bdf, 0x7be0, 0x7be2, 0x7be3, 0x7be4, 0x7be7, + 0x7be8, 0x7be9, 0x7beb, 0x7bec, 0x7bed, 0x7bef, 0x7bf0, 0x7bf2, + 0x7bf3, 0x7bf4, 0x7bf5, 0x7bf6, 0x7bf8, 0x7bf9, 0x7bfa, 0x7bfb, + 0x7bfd, 0x7bff, 0x7c00, 0x7c01, 0x7c02, 0x7c03, 0x7c04, 0x7c05, + 0x7c06, 0x7c08, 0x7c09, 0x7c0a, 0x7c0d, 0x7c0e, 0x7c10, 0x7c11, + 0x7c12, 0x7c13, 0x7c14, 0x7c15, 0x7c17, 0x7c18, 0x7c19, 0x7c1a, + 0x7c1b, 0x7c1c, 0x7c1d, 0x7c1e, 0x7c20, 0x7c21, 0x7c22, 0x7c23, + 0x7c24, 0x7c25, 0x7c28, 0x7c29, 0x7c2b, 0x7c2c, 0x7c2d, 0x7c2e, + 0x7c2f, 0x7c30, 0x7c31, 0x7c32, 0x7c33, 0x7c34, 0x7c35, 0x7c36, + 0x7c37, 0x7c39, 0x7c3a, 0x7c3b, 0x7c3c, 0x7c3d, 0x7c3e, 0x7c42, + /* 0xbb */ + 0x7c43, 0x7c44, 0x7c45, 0x7c46, 0x7c47, 0x7c48, 0x7c49, 0x7c4a, + 0x7c4b, 0x7c4c, 0x7c4e, 0x7c4f, 0x7c50, 0x7c51, 0x7c52, 0x7c53, + 0x7c54, 0x7c55, 0x7c56, 0x7c57, 0x7c58, 0x7c59, 0x7c5a, 0x7c5b, + 0x7c5c, 0x7c5d, 0x7c5e, 0x7c5f, 0x7c60, 0x7c61, 0x7c62, 0x7c63, + 0x7c64, 0x7c65, 0x7c66, 0x7c67, 0x7c68, 0x7c69, 0x7c6a, 0x7c6b, + 0x7c6c, 0x7c6d, 0x7c6e, 0x7c6f, 0x7c70, 0x7c71, 0x7c72, 0x7c75, + 0x7c76, 0x7c77, 0x7c78, 0x7c79, 0x7c7a, 0x7c7e, 0x7c7f, 0x7c80, + 0x7c81, 0x7c82, 0x7c83, 0x7c84, 0x7c85, 0x7c86, 0x7c87, 0x7c88, + 0x7c8a, 0x7c8b, 0x7c8c, 0x7c8d, 0x7c8e, 0x7c8f, 0x7c90, 0x7c93, + 0x7c94, 0x7c96, 0x7c99, 0x7c9a, 0x7c9b, 0x7ca0, 0x7ca1, 0x7ca3, + 0x7ca6, 0x7ca7, 0x7ca8, 0x7ca9, 0x7cab, 0x7cac, 0x7cad, 0x7caf, + 0x7cb0, 0x7cb4, 0x7cb5, 0x7cb6, 0x7cb7, 0x7cb8, 0x7cba, 0x7cbb, + /* 0xbc */ + 0x7cbf, 0x7cc0, 0x7cc2, 0x7cc3, 0x7cc4, 0x7cc6, 0x7cc9, 0x7ccb, + 0x7cce, 0x7ccf, 0x7cd0, 0x7cd1, 0x7cd2, 0x7cd3, 0x7cd4, 0x7cd8, + 0x7cda, 0x7cdb, 0x7cdd, 0x7cde, 0x7ce1, 0x7ce2, 0x7ce3, 0x7ce4, + 0x7ce5, 0x7ce6, 0x7ce7, 0x7ce9, 0x7cea, 0x7ceb, 0x7cec, 0x7ced, + 0x7cee, 0x7cf0, 0x7cf1, 0x7cf2, 0x7cf3, 0x7cf4, 0x7cf5, 0x7cf6, + 0x7cf7, 0x7cf9, 0x7cfa, 0x7cfc, 0x7cfd, 0x7cfe, 0x7cff, 0x7d00, + 0x7d01, 0x7d02, 0x7d03, 0x7d04, 0x7d05, 0x7d06, 0x7d07, 0x7d08, + 0x7d09, 0x7d0b, 0x7d0c, 0x7d0d, 0x7d0e, 0x7d0f, 0x7d10, 0x7d11, + 0x7d12, 0x7d13, 0x7d14, 0x7d15, 0x7d16, 0x7d17, 0x7d18, 0x7d19, + 0x7d1a, 0x7d1b, 0x7d1c, 0x7d1d, 0x7d1e, 0x7d1f, 0x7d21, 0x7d23, + 0x7d24, 0x7d25, 0x7d26, 0x7d28, 0x7d29, 0x7d2a, 0x7d2c, 0x7d2d, + 0x7d2e, 0x7d30, 0x7d31, 0x7d32, 0x7d33, 0x7d34, 0x7d35, 0x7d36, + /* 0xbd */ + 0x7d37, 0x7d38, 0x7d39, 0x7d3a, 0x7d3b, 0x7d3c, 0x7d3d, 0x7d3e, + 0x7d3f, 0x7d40, 0x7d41, 0x7d42, 0x7d43, 0x7d44, 0x7d45, 0x7d46, + 0x7d47, 0x7d48, 0x7d49, 0x7d4a, 0x7d4b, 0x7d4c, 0x7d4d, 0x7d4e, + 0x7d4f, 0x7d50, 0x7d51, 0x7d52, 0x7d53, 0x7d54, 0x7d55, 0x7d56, + 0x7d57, 0x7d58, 0x7d59, 0x7d5a, 0x7d5b, 0x7d5c, 0x7d5d, 0x7d5e, + 0x7d5f, 0x7d60, 0x7d61, 0x7d62, 0x7d63, 0x7d64, 0x7d65, 0x7d66, + 0x7d67, 0x7d68, 0x7d69, 0x7d6a, 0x7d6b, 0x7d6c, 0x7d6d, 0x7d6f, + 0x7d70, 0x7d71, 0x7d72, 0x7d73, 0x7d74, 0x7d75, 0x7d76, 0x7d78, + 0x7d79, 0x7d7a, 0x7d7b, 0x7d7c, 0x7d7d, 0x7d7e, 0x7d7f, 0x7d80, + 0x7d81, 0x7d82, 0x7d83, 0x7d84, 0x7d85, 0x7d86, 0x7d87, 0x7d88, + 0x7d89, 0x7d8a, 0x7d8b, 0x7d8c, 0x7d8d, 0x7d8e, 0x7d8f, 0x7d90, + 0x7d91, 0x7d92, 0x7d93, 0x7d94, 0x7d95, 0x7d96, 0x7d97, 0x7d98, + /* 0xbe */ + 0x7d99, 0x7d9a, 0x7d9b, 0x7d9c, 0x7d9d, 0x7d9e, 0x7d9f, 0x7da0, + 0x7da1, 0x7da2, 0x7da3, 0x7da4, 0x7da5, 0x7da7, 0x7da8, 0x7da9, + 0x7daa, 0x7dab, 0x7dac, 0x7dad, 0x7daf, 0x7db0, 0x7db1, 0x7db2, + 0x7db3, 0x7db4, 0x7db5, 0x7db6, 0x7db7, 0x7db8, 0x7db9, 0x7dba, + 0x7dbb, 0x7dbc, 0x7dbd, 0x7dbe, 0x7dbf, 0x7dc0, 0x7dc1, 0x7dc2, + 0x7dc3, 0x7dc4, 0x7dc5, 0x7dc6, 0x7dc7, 0x7dc8, 0x7dc9, 0x7dca, + 0x7dcb, 0x7dcc, 0x7dcd, 0x7dce, 0x7dcf, 0x7dd0, 0x7dd1, 0x7dd2, + 0x7dd3, 0x7dd4, 0x7dd5, 0x7dd6, 0x7dd7, 0x7dd8, 0x7dd9, 0x7dda, + 0x7ddb, 0x7ddc, 0x7ddd, 0x7dde, 0x7ddf, 0x7de0, 0x7de1, 0x7de2, + 0x7de3, 0x7de4, 0x7de5, 0x7de6, 0x7de7, 0x7de8, 0x7de9, 0x7dea, + 0x7deb, 0x7dec, 0x7ded, 0x7dee, 0x7def, 0x7df0, 0x7df1, 0x7df2, + 0x7df3, 0x7df4, 0x7df5, 0x7df6, 0x7df7, 0x7df8, 0x7df9, 0x7dfa, + /* 0xbf */ + 0x7dfb, 0x7dfc, 0x7dfd, 0x7dfe, 0x7dff, 0x7e00, 0x7e01, 0x7e02, + 0x7e03, 0x7e04, 0x7e05, 0x7e06, 0x7e07, 0x7e08, 0x7e09, 0x7e0a, + 0x7e0b, 0x7e0c, 0x7e0d, 0x7e0e, 0x7e0f, 0x7e10, 0x7e11, 0x7e12, + 0x7e13, 0x7e14, 0x7e15, 0x7e16, 0x7e17, 0x7e18, 0x7e19, 0x7e1a, + 0x7e1b, 0x7e1c, 0x7e1d, 0x7e1e, 0x7e1f, 0x7e20, 0x7e21, 0x7e22, + 0x7e23, 0x7e24, 0x7e25, 0x7e26, 0x7e27, 0x7e28, 0x7e29, 0x7e2a, + 0x7e2b, 0x7e2c, 0x7e2d, 0x7e2e, 0x7e2f, 0x7e30, 0x7e31, 0x7e32, + 0x7e33, 0x7e34, 0x7e35, 0x7e36, 0x7e37, 0x7e38, 0x7e39, 0x7e3a, + 0x7e3c, 0x7e3d, 0x7e3e, 0x7e3f, 0x7e40, 0x7e42, 0x7e43, 0x7e44, + 0x7e45, 0x7e46, 0x7e48, 0x7e49, 0x7e4a, 0x7e4b, 0x7e4c, 0x7e4d, + 0x7e4e, 0x7e4f, 0x7e50, 0x7e51, 0x7e52, 0x7e53, 0x7e54, 0x7e55, + 0x7e56, 0x7e57, 0x7e58, 0x7e59, 0x7e5a, 0x7e5b, 0x7e5c, 0x7e5d, + /* 0xc0 */ + 0x7e5e, 0x7e5f, 0x7e60, 0x7e61, 0x7e62, 0x7e63, 0x7e64, 0x7e65, + 0x7e66, 0x7e67, 0x7e68, 0x7e69, 0x7e6a, 0x7e6b, 0x7e6c, 0x7e6d, + 0x7e6e, 0x7e6f, 0x7e70, 0x7e71, 0x7e72, 0x7e73, 0x7e74, 0x7e75, + 0x7e76, 0x7e77, 0x7e78, 0x7e79, 0x7e7a, 0x7e7b, 0x7e7c, 0x7e7d, + 0x7e7e, 0x7e7f, 0x7e80, 0x7e81, 0x7e83, 0x7e84, 0x7e85, 0x7e86, + 0x7e87, 0x7e88, 0x7e89, 0x7e8a, 0x7e8b, 0x7e8c, 0x7e8d, 0x7e8e, + 0x7e8f, 0x7e90, 0x7e91, 0x7e92, 0x7e93, 0x7e94, 0x7e95, 0x7e96, + 0x7e97, 0x7e98, 0x7e99, 0x7e9a, 0x7e9c, 0x7e9d, 0x7e9e, 0x7eae, + 0x7eb4, 0x7ebb, 0x7ebc, 0x7ed6, 0x7ee4, 0x7eec, 0x7ef9, 0x7f0a, + 0x7f10, 0x7f1e, 0x7f37, 0x7f39, 0x7f3b, 0x7f3c, 0x7f3d, 0x7f3e, + 0x7f3f, 0x7f40, 0x7f41, 0x7f43, 0x7f46, 0x7f47, 0x7f48, 0x7f49, + 0x7f4a, 0x7f4b, 0x7f4c, 0x7f4d, 0x7f4e, 0x7f4f, 0x7f52, 0x7f53, + /* 0xc1 */ + 0x7f56, 0x7f59, 0x7f5b, 0x7f5c, 0x7f5d, 0x7f5e, 0x7f60, 0x7f63, + 0x7f64, 0x7f65, 0x7f66, 0x7f67, 0x7f6b, 0x7f6c, 0x7f6d, 0x7f6f, + 0x7f70, 0x7f73, 0x7f75, 0x7f76, 0x7f77, 0x7f78, 0x7f7a, 0x7f7b, + 0x7f7c, 0x7f7d, 0x7f7f, 0x7f80, 0x7f82, 0x7f83, 0x7f84, 0x7f85, + 0x7f86, 0x7f87, 0x7f88, 0x7f89, 0x7f8b, 0x7f8d, 0x7f8f, 0x7f90, + 0x7f91, 0x7f92, 0x7f93, 0x7f95, 0x7f96, 0x7f97, 0x7f98, 0x7f99, + 0x7f9b, 0x7f9c, 0x7fa0, 0x7fa2, 0x7fa3, 0x7fa5, 0x7fa6, 0x7fa8, + 0x7fa9, 0x7faa, 0x7fab, 0x7fac, 0x7fad, 0x7fae, 0x7fb1, 0x7fb3, + 0x7fb4, 0x7fb5, 0x7fb6, 0x7fb7, 0x7fba, 0x7fbb, 0x7fbe, 0x7fc0, + 0x7fc2, 0x7fc3, 0x7fc4, 0x7fc6, 0x7fc7, 0x7fc8, 0x7fc9, 0x7fcb, + 0x7fcd, 0x7fcf, 0x7fd0, 0x7fd1, 0x7fd2, 0x7fd3, 0x7fd6, 0x7fd7, + 0x7fd9, 0x7fda, 0x7fdb, 0x7fdc, 0x7fdd, 0x7fde, 0x7fe2, 0x7fe3, + /* 0xc2 */ + 0x7fe4, 0x7fe7, 0x7fe8, 0x7fea, 0x7feb, 0x7fec, 0x7fed, 0x7fef, + 0x7ff2, 0x7ff4, 0x7ff5, 0x7ff6, 0x7ff7, 0x7ff8, 0x7ff9, 0x7ffa, + 0x7ffd, 0x7ffe, 0x7fff, 0x8002, 0x8007, 0x8008, 0x8009, 0x800a, + 0x800e, 0x800f, 0x8011, 0x8013, 0x801a, 0x801b, 0x801d, 0x801e, + 0x801f, 0x8021, 0x8023, 0x8024, 0x802b, 0x802c, 0x802d, 0x802e, + 0x802f, 0x8030, 0x8032, 0x8034, 0x8039, 0x803a, 0x803c, 0x803e, + 0x8040, 0x8041, 0x8044, 0x8045, 0x8047, 0x8048, 0x8049, 0x804e, + 0x804f, 0x8050, 0x8051, 0x8053, 0x8055, 0x8056, 0x8057, 0x8059, + 0x805b, 0x805c, 0x805d, 0x805e, 0x805f, 0x8060, 0x8061, 0x8062, + 0x8063, 0x8064, 0x8065, 0x8066, 0x8067, 0x8068, 0x806b, 0x806c, + 0x806d, 0x806e, 0x806f, 0x8070, 0x8072, 0x8073, 0x8074, 0x8075, + 0x8076, 0x8077, 0x8078, 0x8079, 0x807a, 0x807b, 0x807c, 0x807d, + /* 0xc3 */ + 0x807e, 0x8081, 0x8082, 0x8085, 0x8088, 0x808a, 0x808d, 0x808e, + 0x808f, 0x8090, 0x8091, 0x8092, 0x8094, 0x8095, 0x8097, 0x8099, + 0x809e, 0x80a3, 0x80a6, 0x80a7, 0x80a8, 0x80ac, 0x80b0, 0x80b3, + 0x80b5, 0x80b6, 0x80b8, 0x80b9, 0x80bb, 0x80c5, 0x80c7, 0x80c8, + 0x80c9, 0x80ca, 0x80cb, 0x80cf, 0x80d0, 0x80d1, 0x80d2, 0x80d3, + 0x80d4, 0x80d5, 0x80d8, 0x80df, 0x80e0, 0x80e2, 0x80e3, 0x80e6, + 0x80ee, 0x80f5, 0x80f7, 0x80f9, 0x80fb, 0x80fe, 0x80ff, 0x8100, + 0x8101, 0x8103, 0x8104, 0x8105, 0x8107, 0x8108, 0x810b, 0x810c, + 0x8115, 0x8117, 0x8119, 0x811b, 0x811c, 0x811d, 0x811f, 0x8120, + 0x8121, 0x8122, 0x8123, 0x8124, 0x8125, 0x8126, 0x8127, 0x8128, + 0x8129, 0x812a, 0x812b, 0x812d, 0x812e, 0x8130, 0x8133, 0x8134, + 0x8135, 0x8137, 0x8139, 0x813a, 0x813b, 0x813c, 0x813d, 0x813f, + /* 0xc4 */ + 0x8140, 0x8141, 0x8142, 0x8143, 0x8144, 0x8145, 0x8147, 0x8149, + 0x814d, 0x814e, 0x814f, 0x8152, 0x8156, 0x8157, 0x8158, 0x815b, + 0x815c, 0x815d, 0x815e, 0x815f, 0x8161, 0x8162, 0x8163, 0x8164, + 0x8166, 0x8168, 0x816a, 0x816b, 0x816c, 0x816f, 0x8172, 0x8173, + 0x8175, 0x8176, 0x8177, 0x8178, 0x8181, 0x8183, 0x8184, 0x8185, + 0x8186, 0x8187, 0x8189, 0x818b, 0x818c, 0x818d, 0x818e, 0x8190, + 0x8192, 0x8193, 0x8194, 0x8195, 0x8196, 0x8197, 0x8199, 0x819a, + 0x819e, 0x819f, 0x81a0, 0x81a1, 0x81a2, 0x81a4, 0x81a5, 0x81a7, + 0x81a9, 0x81ab, 0x81ac, 0x81ad, 0x81ae, 0x81af, 0x81b0, 0x81b1, + 0x81b2, 0x81b4, 0x81b5, 0x81b6, 0x81b7, 0x81b8, 0x81b9, 0x81bc, + 0x81bd, 0x81be, 0x81bf, 0x81c4, 0x81c5, 0x81c7, 0x81c8, 0x81c9, + 0x81cb, 0x81cd, 0x81ce, 0x81cf, 0x81d0, 0x81d1, 0x81d2, 0x81d3, + /* 0xc5 */ + 0x81d4, 0x81d5, 0x81d6, 0x81d7, 0x81d8, 0x81d9, 0x81da, 0x81db, + 0x81dc, 0x81dd, 0x81de, 0x81df, 0x81e0, 0x81e1, 0x81e2, 0x81e4, + 0x81e5, 0x81e6, 0x81e8, 0x81e9, 0x81eb, 0x81ee, 0x81ef, 0x81f0, + 0x81f1, 0x81f2, 0x81f5, 0x81f6, 0x81f7, 0x81f8, 0x81f9, 0x81fa, + 0x81fd, 0x81ff, 0x8203, 0x8207, 0x8208, 0x8209, 0x820a, 0x820b, + 0x820e, 0x820f, 0x8211, 0x8213, 0x8215, 0x8216, 0x8217, 0x8218, + 0x8219, 0x821a, 0x821d, 0x8220, 0x8224, 0x8225, 0x8226, 0x8227, + 0x8229, 0x822e, 0x8232, 0x823a, 0x823c, 0x823d, 0x823f, 0x8240, + 0x8241, 0x8242, 0x8243, 0x8245, 0x8246, 0x8248, 0x824a, 0x824c, + 0x824d, 0x824e, 0x8250, 0x8251, 0x8252, 0x8253, 0x8254, 0x8255, + 0x8256, 0x8257, 0x8259, 0x825b, 0x825c, 0x825d, 0x825e, 0x8260, + 0x8261, 0x8262, 0x8263, 0x8264, 0x8265, 0x8266, 0x8267, 0x8269, + /* 0xc6 */ + 0x826a, 0x826b, 0x826c, 0x826d, 0x8271, 0x8275, 0x8276, 0x8277, + 0x8278, 0x827b, 0x827c, 0x8280, 0x8281, 0x8283, 0x8285, 0x8286, + 0x8287, 0x8289, 0x828c, 0x8290, 0x8293, 0x8294, 0x8295, 0x8296, + 0x829a, 0x829b, 0x829e, 0x82a0, 0x82a2, 0x82a3, 0x82a7, 0x82b2, + 0x82b5, 0x82b6, 0x82ba, 0x82bb, 0x82bc, 0x82bf, 0x82c0, 0x82c2, + 0x82c3, 0x82c5, 0x82c6, 0x82c9, 0x82d0, 0x82d6, 0x82d9, 0x82da, + 0x82dd, 0x82e2, 0x82e7, 0x82e8, 0x82e9, 0x82ea, 0x82ec, 0x82ed, + 0x82ee, 0x82f0, 0x82f2, 0x82f3, 0x82f5, 0x82f6, 0x82f8, 0x82fa, + 0x82fc, 0x82fd, 0x82fe, 0x82ff, 0x8300, 0x830a, 0x830b, 0x830d, + 0x8310, 0x8312, 0x8313, 0x8316, 0x8318, 0x8319, 0x831d, 0x831e, + 0x831f, 0x8320, 0x8321, 0x8322, 0x8323, 0x8324, 0x8325, 0x8326, + 0x8329, 0x832a, 0x832e, 0x8330, 0x8332, 0x8337, 0x833b, 0x833d, + /* 0xc7 */ + 0x833e, 0x833f, 0x8341, 0x8342, 0x8344, 0x8345, 0x8348, 0x834a, + 0x834b, 0x834c, 0x834d, 0x834e, 0x8353, 0x8355, 0x8356, 0x8357, + 0x8358, 0x8359, 0x835d, 0x8362, 0x8370, 0x8371, 0x8372, 0x8373, + 0x8374, 0x8375, 0x8376, 0x8379, 0x837a, 0x837e, 0x837f, 0x8380, + 0x8381, 0x8382, 0x8383, 0x8384, 0x8387, 0x8388, 0x838a, 0x838b, + 0x838c, 0x838d, 0x838f, 0x8390, 0x8391, 0x8394, 0x8395, 0x8396, + 0x8397, 0x8399, 0x839a, 0x839d, 0x839f, 0x83a1, 0x83a2, 0x83a3, + 0x83a4, 0x83a5, 0x83a6, 0x83a7, 0x83ac, 0x83ad, 0x83ae, 0x83af, + 0x83b5, 0x83bb, 0x83be, 0x83bf, 0x83c2, 0x83c3, 0x83c4, 0x83c6, + 0x83c8, 0x83c9, 0x83cb, 0x83cd, 0x83ce, 0x83d0, 0x83d1, 0x83d2, + 0x83d3, 0x83d5, 0x83d7, 0x83d9, 0x83da, 0x83db, 0x83de, 0x83e2, + 0x83e3, 0x83e4, 0x83e6, 0x83e7, 0x83e8, 0x83eb, 0x83ec, 0x83ed, + /* 0xc8 */ + 0x83ee, 0x83ef, 0x83f3, 0x83f4, 0x83f5, 0x83f6, 0x83f7, 0x83fa, + 0x83fb, 0x83fc, 0x83fe, 0x83ff, 0x8400, 0x8402, 0x8405, 0x8407, + 0x8408, 0x8409, 0x840a, 0x8410, 0x8412, 0x8413, 0x8414, 0x8415, + 0x8416, 0x8417, 0x8419, 0x841a, 0x841b, 0x841e, 0x841f, 0x8420, + 0x8421, 0x8422, 0x8423, 0x8429, 0x842a, 0x842b, 0x842c, 0x842d, + 0x842e, 0x842f, 0x8430, 0x8432, 0x8433, 0x8434, 0x8435, 0x8436, + 0x8437, 0x8439, 0x843a, 0x843b, 0x843e, 0x843f, 0x8440, 0x8441, + 0x8442, 0x8443, 0x8444, 0x8445, 0x8447, 0x8448, 0x8449, 0x844a, + 0x844b, 0x844c, 0x844d, 0x844e, 0x844f, 0x8450, 0x8452, 0x8453, + 0x8454, 0x8455, 0x8456, 0x8458, 0x845d, 0x845e, 0x845f, 0x8460, + 0x8462, 0x8464, 0x8465, 0x8466, 0x8467, 0x8468, 0x846a, 0x846e, + 0x846f, 0x8470, 0x8472, 0x8474, 0x8477, 0x8479, 0x847b, 0x847c, + /* 0xc9 */ + 0x847d, 0x847e, 0x847f, 0x8480, 0x8481, 0x8483, 0x8484, 0x8485, + 0x8486, 0x848a, 0x848d, 0x848f, 0x8490, 0x8491, 0x8492, 0x8493, + 0x8494, 0x8495, 0x8496, 0x8498, 0x849a, 0x849b, 0x849d, 0x849e, + 0x849f, 0x84a0, 0x84a2, 0x84a3, 0x84a4, 0x84a5, 0x84a6, 0x84a7, + 0x84a8, 0x84a9, 0x84aa, 0x84ab, 0x84ac, 0x84ad, 0x84ae, 0x84b0, + 0x84b1, 0x84b3, 0x84b5, 0x84b6, 0x84b7, 0x84bb, 0x84bc, 0x84be, + 0x84c0, 0x84c2, 0x84c3, 0x84c5, 0x84c6, 0x84c7, 0x84c8, 0x84cb, + 0x84cc, 0x84ce, 0x84cf, 0x84d2, 0x84d4, 0x84d5, 0x84d7, 0x84d8, + 0x84d9, 0x84da, 0x84db, 0x84dc, 0x84de, 0x84e1, 0x84e2, 0x84e4, + 0x84e7, 0x84e8, 0x84e9, 0x84ea, 0x84eb, 0x84ed, 0x84ee, 0x84ef, + 0x84f1, 0x84f2, 0x84f3, 0x84f4, 0x84f5, 0x84f6, 0x84f7, 0x84f8, + 0x84f9, 0x84fa, 0x84fb, 0x84fd, 0x84fe, 0x8500, 0x8501, 0x8502, + /* 0xca */ + 0x8503, 0x8504, 0x8505, 0x8506, 0x8507, 0x8508, 0x8509, 0x850a, + 0x850b, 0x850d, 0x850e, 0x850f, 0x8510, 0x8512, 0x8514, 0x8515, + 0x8516, 0x8518, 0x8519, 0x851b, 0x851c, 0x851d, 0x851e, 0x8520, + 0x8522, 0x8523, 0x8524, 0x8525, 0x8526, 0x8527, 0x8528, 0x8529, + 0x852a, 0x852d, 0x852e, 0x852f, 0x8530, 0x8531, 0x8532, 0x8533, + 0x8534, 0x8535, 0x8536, 0x853e, 0x853f, 0x8540, 0x8541, 0x8542, + 0x8544, 0x8545, 0x8546, 0x8547, 0x854b, 0x854c, 0x854d, 0x854e, + 0x854f, 0x8550, 0x8551, 0x8552, 0x8553, 0x8554, 0x8555, 0x8557, + 0x8558, 0x855a, 0x855b, 0x855c, 0x855d, 0x855f, 0x8560, 0x8561, + 0x8562, 0x8563, 0x8565, 0x8566, 0x8567, 0x8569, 0x856a, 0x856b, + 0x856c, 0x856d, 0x856e, 0x856f, 0x8570, 0x8571, 0x8573, 0x8575, + 0x8576, 0x8577, 0x8578, 0x857c, 0x857d, 0x857f, 0x8580, 0x8581, + /* 0xcb */ + 0x8582, 0x8583, 0x8586, 0x8588, 0x8589, 0x858a, 0x858b, 0x858c, + 0x858d, 0x858e, 0x8590, 0x8591, 0x8592, 0x8593, 0x8594, 0x8595, + 0x8596, 0x8597, 0x8598, 0x8599, 0x859a, 0x859d, 0x859e, 0x859f, + 0x85a0, 0x85a1, 0x85a2, 0x85a3, 0x85a5, 0x85a6, 0x85a7, 0x85a9, + 0x85ab, 0x85ac, 0x85ad, 0x85b1, 0x85b2, 0x85b3, 0x85b4, 0x85b5, + 0x85b6, 0x85b8, 0x85ba, 0x85bb, 0x85bc, 0x85bd, 0x85be, 0x85bf, + 0x85c0, 0x85c2, 0x85c3, 0x85c4, 0x85c5, 0x85c6, 0x85c7, 0x85c8, + 0x85ca, 0x85cb, 0x85cc, 0x85cd, 0x85ce, 0x85d1, 0x85d2, 0x85d4, + 0x85d6, 0x85d7, 0x85d8, 0x85d9, 0x85da, 0x85db, 0x85dd, 0x85de, + 0x85df, 0x85e0, 0x85e1, 0x85e2, 0x85e3, 0x85e5, 0x85e6, 0x85e7, + 0x85e8, 0x85ea, 0x85eb, 0x85ec, 0x85ed, 0x85ee, 0x85ef, 0x85f0, + 0x85f1, 0x85f2, 0x85f3, 0x85f4, 0x85f5, 0x85f6, 0x85f7, 0x85f8, + /* 0xcc */ + 0x85f9, 0x85fa, 0x85fc, 0x85fd, 0x85fe, 0x8600, 0x8601, 0x8602, + 0x8603, 0x8604, 0x8606, 0x8607, 0x8608, 0x8609, 0x860a, 0x860b, + 0x860c, 0x860d, 0x860e, 0x860f, 0x8610, 0x8612, 0x8613, 0x8614, + 0x8615, 0x8617, 0x8618, 0x8619, 0x861a, 0x861b, 0x861c, 0x861d, + 0x861e, 0x861f, 0x8620, 0x8621, 0x8622, 0x8623, 0x8624, 0x8625, + 0x8626, 0x8628, 0x862a, 0x862b, 0x862c, 0x862d, 0x862e, 0x862f, + 0x8630, 0x8631, 0x8632, 0x8633, 0x8634, 0x8635, 0x8636, 0x8637, + 0x8639, 0x863a, 0x863b, 0x863d, 0x863e, 0x863f, 0x8640, 0x8641, + 0x8642, 0x8643, 0x8644, 0x8645, 0x8646, 0x8647, 0x8648, 0x8649, + 0x864a, 0x864b, 0x864c, 0x8652, 0x8653, 0x8655, 0x8656, 0x8657, + 0x8658, 0x8659, 0x865b, 0x865c, 0x865d, 0x865f, 0x8660, 0x8661, + 0x8663, 0x8664, 0x8665, 0x8666, 0x8667, 0x8668, 0x8669, 0x866a, + /* 0xcd */ + 0x866d, 0x866f, 0x8670, 0x8672, 0x8673, 0x8674, 0x8675, 0x8676, + 0x8677, 0x8678, 0x8683, 0x8684, 0x8685, 0x8686, 0x8687, 0x8688, + 0x8689, 0x868e, 0x868f, 0x8690, 0x8691, 0x8692, 0x8694, 0x8696, + 0x8697, 0x8698, 0x8699, 0x869a, 0x869b, 0x869e, 0x869f, 0x86a0, + 0x86a1, 0x86a2, 0x86a5, 0x86a6, 0x86ab, 0x86ad, 0x86ae, 0x86b2, + 0x86b3, 0x86b7, 0x86b8, 0x86b9, 0x86bb, 0x86bc, 0x86bd, 0x86be, + 0x86bf, 0x86c1, 0x86c2, 0x86c3, 0x86c5, 0x86c8, 0x86cc, 0x86cd, + 0x86d2, 0x86d3, 0x86d5, 0x86d6, 0x86d7, 0x86da, 0x86dc, 0x86dd, + 0x86e0, 0x86e1, 0x86e2, 0x86e3, 0x86e5, 0x86e6, 0x86e7, 0x86e8, + 0x86ea, 0x86eb, 0x86ec, 0x86ef, 0x86f5, 0x86f6, 0x86f7, 0x86fa, + 0x86fb, 0x86fc, 0x86fd, 0x86ff, 0x8701, 0x8704, 0x8705, 0x8706, + 0x870b, 0x870c, 0x870e, 0x870f, 0x8710, 0x8711, 0x8714, 0x8716, + /* 0xce */ + 0x8719, 0x871b, 0x871d, 0x871f, 0x8720, 0x8724, 0x8726, 0x8727, + 0x8728, 0x872a, 0x872b, 0x872c, 0x872d, 0x872f, 0x8730, 0x8732, + 0x8733, 0x8735, 0x8736, 0x8738, 0x8739, 0x873a, 0x873c, 0x873d, + 0x8740, 0x8741, 0x8742, 0x8743, 0x8744, 0x8745, 0x8746, 0x874a, + 0x874b, 0x874d, 0x874f, 0x8750, 0x8751, 0x8752, 0x8754, 0x8755, + 0x8756, 0x8758, 0x875a, 0x875b, 0x875c, 0x875d, 0x875e, 0x875f, + 0x8761, 0x8762, 0x8766, 0x8767, 0x8768, 0x8769, 0x876a, 0x876b, + 0x876c, 0x876d, 0x876f, 0x8771, 0x8772, 0x8773, 0x8775, 0x8777, + 0x8778, 0x8779, 0x877a, 0x877f, 0x8780, 0x8781, 0x8784, 0x8786, + 0x8787, 0x8789, 0x878a, 0x878c, 0x878e, 0x878f, 0x8790, 0x8791, + 0x8792, 0x8794, 0x8795, 0x8796, 0x8798, 0x8799, 0x879a, 0x879b, + 0x879c, 0x879d, 0x879e, 0x87a0, 0x87a1, 0x87a2, 0x87a3, 0x87a4, + /* 0xcf */ + 0x87a5, 0x87a6, 0x87a7, 0x87a9, 0x87aa, 0x87ae, 0x87b0, 0x87b1, + 0x87b2, 0x87b4, 0x87b6, 0x87b7, 0x87b8, 0x87b9, 0x87bb, 0x87bc, + 0x87be, 0x87bf, 0x87c1, 0x87c2, 0x87c3, 0x87c4, 0x87c5, 0x87c7, + 0x87c8, 0x87c9, 0x87cc, 0x87cd, 0x87ce, 0x87cf, 0x87d0, 0x87d4, + 0x87d5, 0x87d6, 0x87d7, 0x87d8, 0x87d9, 0x87da, 0x87dc, 0x87dd, + 0x87de, 0x87df, 0x87e1, 0x87e2, 0x87e3, 0x87e4, 0x87e6, 0x87e7, + 0x87e8, 0x87e9, 0x87eb, 0x87ec, 0x87ed, 0x87ef, 0x87f0, 0x87f1, + 0x87f2, 0x87f3, 0x87f4, 0x87f5, 0x87f6, 0x87f7, 0x87f8, 0x87fa, + 0x87fb, 0x87fc, 0x87fd, 0x87ff, 0x8800, 0x8801, 0x8802, 0x8804, + 0x8805, 0x8806, 0x8807, 0x8808, 0x8809, 0x880b, 0x880c, 0x880d, + 0x880e, 0x880f, 0x8810, 0x8811, 0x8812, 0x8814, 0x8817, 0x8818, + 0x8819, 0x881a, 0x881c, 0x881d, 0x881e, 0x881f, 0x8820, 0x8823, + /* 0xd0 */ + 0x8824, 0x8825, 0x8826, 0x8827, 0x8828, 0x8829, 0x882a, 0x882b, + 0x882c, 0x882d, 0x882e, 0x882f, 0x8830, 0x8831, 0x8833, 0x8834, + 0x8835, 0x8836, 0x8837, 0x8838, 0x883a, 0x883b, 0x883d, 0x883e, + 0x883f, 0x8841, 0x8842, 0x8843, 0x8846, 0x8847, 0x8848, 0x8849, + 0x884a, 0x884b, 0x884e, 0x884f, 0x8850, 0x8851, 0x8852, 0x8853, + 0x8855, 0x8856, 0x8858, 0x885a, 0x885b, 0x885c, 0x885d, 0x885e, + 0x885f, 0x8860, 0x8866, 0x8867, 0x886a, 0x886d, 0x886f, 0x8871, + 0x8873, 0x8874, 0x8875, 0x8876, 0x8878, 0x8879, 0x887a, 0x887b, + 0x887c, 0x8880, 0x8883, 0x8886, 0x8887, 0x8889, 0x888a, 0x888c, + 0x888e, 0x888f, 0x8890, 0x8891, 0x8893, 0x8894, 0x8895, 0x8897, + 0x8898, 0x8899, 0x889a, 0x889b, 0x889d, 0x889e, 0x889f, 0x88a0, + 0x88a1, 0x88a3, 0x88a5, 0x88a6, 0x88a7, 0x88a8, 0x88a9, 0x88aa, + /* 0xd1 */ + 0x88ac, 0x88ae, 0x88af, 0x88b0, 0x88b2, 0x88b3, 0x88b4, 0x88b5, + 0x88b6, 0x88b8, 0x88b9, 0x88ba, 0x88bb, 0x88bd, 0x88be, 0x88bf, + 0x88c0, 0x88c3, 0x88c4, 0x88c7, 0x88c8, 0x88ca, 0x88cb, 0x88cc, + 0x88cd, 0x88cf, 0x88d0, 0x88d1, 0x88d3, 0x88d6, 0x88d7, 0x88da, + 0x88db, 0x88dc, 0x88dd, 0x88de, 0x88e0, 0x88e1, 0x88e6, 0x88e7, + 0x88e9, 0x88ea, 0x88eb, 0x88ec, 0x88ed, 0x88ee, 0x88ef, 0x88f2, + 0x88f5, 0x88f6, 0x88f7, 0x88fa, 0x88fb, 0x88fd, 0x88ff, 0x8900, + 0x8901, 0x8903, 0x8904, 0x8905, 0x8906, 0x8907, 0x8908, 0x8909, + 0x890b, 0x890c, 0x890d, 0x890e, 0x890f, 0x8911, 0x8914, 0x8915, + 0x8916, 0x8917, 0x8918, 0x891c, 0x891d, 0x891e, 0x891f, 0x8920, + 0x8922, 0x8923, 0x8924, 0x8926, 0x8927, 0x8928, 0x8929, 0x892c, + 0x892d, 0x892e, 0x892f, 0x8931, 0x8932, 0x8933, 0x8935, 0x8937, + /* 0xd2 */ + 0x8938, 0x8939, 0x893a, 0x893b, 0x893c, 0x893d, 0x893e, 0x893f, + 0x8940, 0x8942, 0x8943, 0x8945, 0x8946, 0x8947, 0x8948, 0x8949, + 0x894a, 0x894b, 0x894c, 0x894d, 0x894e, 0x894f, 0x8950, 0x8951, + 0x8952, 0x8953, 0x8954, 0x8955, 0x8956, 0x8957, 0x8958, 0x8959, + 0x895a, 0x895b, 0x895c, 0x895d, 0x8960, 0x8961, 0x8962, 0x8963, + 0x8964, 0x8965, 0x8967, 0x8968, 0x8969, 0x896a, 0x896b, 0x896c, + 0x896d, 0x896e, 0x896f, 0x8970, 0x8971, 0x8972, 0x8973, 0x8974, + 0x8975, 0x8976, 0x8977, 0x8978, 0x8979, 0x897a, 0x897c, 0x897d, + 0x897e, 0x8980, 0x8982, 0x8984, 0x8985, 0x8987, 0x8988, 0x8989, + 0x898a, 0x898b, 0x898c, 0x898d, 0x898e, 0x898f, 0x8990, 0x8991, + 0x8992, 0x8993, 0x8994, 0x8995, 0x8996, 0x8997, 0x8998, 0x8999, + 0x899a, 0x899b, 0x899c, 0x899d, 0x899e, 0x899f, 0x89a0, 0x89a1, + /* 0xd3 */ + 0x89a2, 0x89a3, 0x89a4, 0x89a5, 0x89a6, 0x89a7, 0x89a8, 0x89a9, + 0x89aa, 0x89ab, 0x89ac, 0x89ad, 0x89ae, 0x89af, 0x89b0, 0x89b1, + 0x89b2, 0x89b3, 0x89b4, 0x89b5, 0x89b6, 0x89b7, 0x89b8, 0x89b9, + 0x89ba, 0x89bb, 0x89bc, 0x89bd, 0x89be, 0x89bf, 0x89c0, 0x89c3, + 0x89cd, 0x89d3, 0x89d4, 0x89d5, 0x89d7, 0x89d8, 0x89d9, 0x89db, + 0x89dd, 0x89df, 0x89e0, 0x89e1, 0x89e2, 0x89e4, 0x89e7, 0x89e8, + 0x89e9, 0x89ea, 0x89ec, 0x89ed, 0x89ee, 0x89f0, 0x89f1, 0x89f2, + 0x89f4, 0x89f5, 0x89f6, 0x89f7, 0x89f8, 0x89f9, 0x89fa, 0x89fb, + 0x89fc, 0x89fd, 0x89fe, 0x89ff, 0x8a01, 0x8a02, 0x8a03, 0x8a04, + 0x8a05, 0x8a06, 0x8a08, 0x8a09, 0x8a0a, 0x8a0b, 0x8a0c, 0x8a0d, + 0x8a0e, 0x8a0f, 0x8a10, 0x8a11, 0x8a12, 0x8a13, 0x8a14, 0x8a15, + 0x8a16, 0x8a17, 0x8a18, 0x8a19, 0x8a1a, 0x8a1b, 0x8a1c, 0x8a1d, + /* 0xd4 */ + 0x8a1e, 0x8a1f, 0x8a20, 0x8a21, 0x8a22, 0x8a23, 0x8a24, 0x8a25, + 0x8a26, 0x8a27, 0x8a28, 0x8a29, 0x8a2a, 0x8a2b, 0x8a2c, 0x8a2d, + 0x8a2e, 0x8a2f, 0x8a30, 0x8a31, 0x8a32, 0x8a33, 0x8a34, 0x8a35, + 0x8a36, 0x8a37, 0x8a38, 0x8a39, 0x8a3a, 0x8a3b, 0x8a3c, 0x8a3d, + 0x8a3f, 0x8a40, 0x8a41, 0x8a42, 0x8a43, 0x8a44, 0x8a45, 0x8a46, + 0x8a47, 0x8a49, 0x8a4a, 0x8a4b, 0x8a4c, 0x8a4d, 0x8a4e, 0x8a4f, + 0x8a50, 0x8a51, 0x8a52, 0x8a53, 0x8a54, 0x8a55, 0x8a56, 0x8a57, + 0x8a58, 0x8a59, 0x8a5a, 0x8a5b, 0x8a5c, 0x8a5d, 0x8a5e, 0x8a5f, + 0x8a60, 0x8a61, 0x8a62, 0x8a63, 0x8a64, 0x8a65, 0x8a66, 0x8a67, + 0x8a68, 0x8a69, 0x8a6a, 0x8a6b, 0x8a6c, 0x8a6d, 0x8a6e, 0x8a6f, + 0x8a70, 0x8a71, 0x8a72, 0x8a73, 0x8a74, 0x8a75, 0x8a76, 0x8a77, + 0x8a78, 0x8a7a, 0x8a7b, 0x8a7c, 0x8a7d, 0x8a7e, 0x8a7f, 0x8a80, + /* 0xd5 */ + 0x8a81, 0x8a82, 0x8a83, 0x8a84, 0x8a85, 0x8a86, 0x8a87, 0x8a88, + 0x8a8b, 0x8a8c, 0x8a8d, 0x8a8e, 0x8a8f, 0x8a90, 0x8a91, 0x8a92, + 0x8a94, 0x8a95, 0x8a96, 0x8a97, 0x8a98, 0x8a99, 0x8a9a, 0x8a9b, + 0x8a9c, 0x8a9d, 0x8a9e, 0x8a9f, 0x8aa0, 0x8aa1, 0x8aa2, 0x8aa3, + 0x8aa4, 0x8aa5, 0x8aa6, 0x8aa7, 0x8aa8, 0x8aa9, 0x8aaa, 0x8aab, + 0x8aac, 0x8aad, 0x8aae, 0x8aaf, 0x8ab0, 0x8ab1, 0x8ab2, 0x8ab3, + 0x8ab4, 0x8ab5, 0x8ab6, 0x8ab7, 0x8ab8, 0x8ab9, 0x8aba, 0x8abb, + 0x8abc, 0x8abd, 0x8abe, 0x8abf, 0x8ac0, 0x8ac1, 0x8ac2, 0x8ac3, + 0x8ac4, 0x8ac5, 0x8ac6, 0x8ac7, 0x8ac8, 0x8ac9, 0x8aca, 0x8acb, + 0x8acc, 0x8acd, 0x8ace, 0x8acf, 0x8ad0, 0x8ad1, 0x8ad2, 0x8ad3, + 0x8ad4, 0x8ad5, 0x8ad6, 0x8ad7, 0x8ad8, 0x8ad9, 0x8ada, 0x8adb, + 0x8adc, 0x8add, 0x8ade, 0x8adf, 0x8ae0, 0x8ae1, 0x8ae2, 0x8ae3, + /* 0xd6 */ + 0x8ae4, 0x8ae5, 0x8ae6, 0x8ae7, 0x8ae8, 0x8ae9, 0x8aea, 0x8aeb, + 0x8aec, 0x8aed, 0x8aee, 0x8aef, 0x8af0, 0x8af1, 0x8af2, 0x8af3, + 0x8af4, 0x8af5, 0x8af6, 0x8af7, 0x8af8, 0x8af9, 0x8afa, 0x8afb, + 0x8afc, 0x8afd, 0x8afe, 0x8aff, 0x8b00, 0x8b01, 0x8b02, 0x8b03, + 0x8b04, 0x8b05, 0x8b06, 0x8b08, 0x8b09, 0x8b0a, 0x8b0b, 0x8b0c, + 0x8b0d, 0x8b0e, 0x8b0f, 0x8b10, 0x8b11, 0x8b12, 0x8b13, 0x8b14, + 0x8b15, 0x8b16, 0x8b17, 0x8b18, 0x8b19, 0x8b1a, 0x8b1b, 0x8b1c, + 0x8b1d, 0x8b1e, 0x8b1f, 0x8b20, 0x8b21, 0x8b22, 0x8b23, 0x8b24, + 0x8b25, 0x8b27, 0x8b28, 0x8b29, 0x8b2a, 0x8b2b, 0x8b2c, 0x8b2d, + 0x8b2e, 0x8b2f, 0x8b30, 0x8b31, 0x8b32, 0x8b33, 0x8b34, 0x8b35, + 0x8b36, 0x8b37, 0x8b38, 0x8b39, 0x8b3a, 0x8b3b, 0x8b3c, 0x8b3d, + 0x8b3e, 0x8b3f, 0x8b40, 0x8b41, 0x8b42, 0x8b43, 0x8b44, 0x8b45, + /* 0xd7 */ + 0x8b46, 0x8b47, 0x8b48, 0x8b49, 0x8b4a, 0x8b4b, 0x8b4c, 0x8b4d, + 0x8b4e, 0x8b4f, 0x8b50, 0x8b51, 0x8b52, 0x8b53, 0x8b54, 0x8b55, + 0x8b56, 0x8b57, 0x8b58, 0x8b59, 0x8b5a, 0x8b5b, 0x8b5c, 0x8b5d, + 0x8b5e, 0x8b5f, 0x8b60, 0x8b61, 0x8b62, 0x8b63, 0x8b64, 0x8b65, + 0x8b67, 0x8b68, 0x8b69, 0x8b6a, 0x8b6b, 0x8b6d, 0x8b6e, 0x8b6f, + 0x8b70, 0x8b71, 0x8b72, 0x8b73, 0x8b74, 0x8b75, 0x8b76, 0x8b77, + 0x8b78, 0x8b79, 0x8b7a, 0x8b7b, 0x8b7c, 0x8b7d, 0x8b7e, 0x8b7f, + 0x8b80, 0x8b81, 0x8b82, 0x8b83, 0x8b84, 0x8b85, 0x8b86, 0x8b87, + 0x8b88, 0x8b89, 0x8b8a, 0x8b8b, 0x8b8c, 0x8b8d, 0x8b8e, 0x8b8f, + 0x8b90, 0x8b91, 0x8b92, 0x8b93, 0x8b94, 0x8b95, 0x8b96, 0x8b97, + 0x8b98, 0x8b99, 0x8b9a, 0x8b9b, 0x8b9c, 0x8b9d, 0x8b9e, 0x8b9f, + 0x8bac, 0x8bb1, 0x8bbb, 0x8bc7, 0x8bd0, 0x8bea, 0x8c09, 0x8c1e, + /* 0xd8 */ + 0x8c38, 0x8c39, 0x8c3a, 0x8c3b, 0x8c3c, 0x8c3d, 0x8c3e, 0x8c3f, + 0x8c40, 0x8c42, 0x8c43, 0x8c44, 0x8c45, 0x8c48, 0x8c4a, 0x8c4b, + 0x8c4d, 0x8c4e, 0x8c4f, 0x8c50, 0x8c51, 0x8c52, 0x8c53, 0x8c54, + 0x8c56, 0x8c57, 0x8c58, 0x8c59, 0x8c5b, 0x8c5c, 0x8c5d, 0x8c5e, + 0x8c5f, 0x8c60, 0x8c63, 0x8c64, 0x8c65, 0x8c66, 0x8c67, 0x8c68, + 0x8c69, 0x8c6c, 0x8c6d, 0x8c6e, 0x8c6f, 0x8c70, 0x8c71, 0x8c72, + 0x8c74, 0x8c75, 0x8c76, 0x8c77, 0x8c7b, 0x8c7c, 0x8c7d, 0x8c7e, + 0x8c7f, 0x8c80, 0x8c81, 0x8c83, 0x8c84, 0x8c86, 0x8c87, 0x8c88, + 0x8c8b, 0x8c8d, 0x8c8e, 0x8c8f, 0x8c90, 0x8c91, 0x8c92, 0x8c93, + 0x8c95, 0x8c96, 0x8c97, 0x8c99, 0x8c9a, 0x8c9b, 0x8c9c, 0x8c9d, + 0x8c9e, 0x8c9f, 0x8ca0, 0x8ca1, 0x8ca2, 0x8ca3, 0x8ca4, 0x8ca5, + 0x8ca6, 0x8ca7, 0x8ca8, 0x8ca9, 0x8caa, 0x8cab, 0x8cac, 0x8cad, + /* 0xd9 */ + 0x8cae, 0x8caf, 0x8cb0, 0x8cb1, 0x8cb2, 0x8cb3, 0x8cb4, 0x8cb5, + 0x8cb6, 0x8cb7, 0x8cb8, 0x8cb9, 0x8cba, 0x8cbb, 0x8cbc, 0x8cbd, + 0x8cbe, 0x8cbf, 0x8cc0, 0x8cc1, 0x8cc2, 0x8cc3, 0x8cc4, 0x8cc5, + 0x8cc6, 0x8cc7, 0x8cc8, 0x8cc9, 0x8cca, 0x8ccb, 0x8ccc, 0x8ccd, + 0x8cce, 0x8ccf, 0x8cd0, 0x8cd1, 0x8cd2, 0x8cd3, 0x8cd4, 0x8cd5, + 0x8cd6, 0x8cd7, 0x8cd8, 0x8cd9, 0x8cda, 0x8cdb, 0x8cdc, 0x8cdd, + 0x8cde, 0x8cdf, 0x8ce0, 0x8ce1, 0x8ce2, 0x8ce3, 0x8ce4, 0x8ce5, + 0x8ce6, 0x8ce7, 0x8ce8, 0x8ce9, 0x8cea, 0x8ceb, 0x8cec, 0x8ced, + 0x8cee, 0x8cef, 0x8cf0, 0x8cf1, 0x8cf2, 0x8cf3, 0x8cf4, 0x8cf5, + 0x8cf6, 0x8cf7, 0x8cf8, 0x8cf9, 0x8cfa, 0x8cfb, 0x8cfc, 0x8cfd, + 0x8cfe, 0x8cff, 0x8d00, 0x8d01, 0x8d02, 0x8d03, 0x8d04, 0x8d05, + 0x8d06, 0x8d07, 0x8d08, 0x8d09, 0x8d0a, 0x8d0b, 0x8d0c, 0x8d0d, + /* 0xda */ + 0x8d0e, 0x8d0f, 0x8d10, 0x8d11, 0x8d12, 0x8d13, 0x8d14, 0x8d15, + 0x8d16, 0x8d17, 0x8d18, 0x8d19, 0x8d1a, 0x8d1b, 0x8d1c, 0x8d20, + 0x8d51, 0x8d52, 0x8d57, 0x8d5f, 0x8d65, 0x8d68, 0x8d69, 0x8d6a, + 0x8d6c, 0x8d6e, 0x8d6f, 0x8d71, 0x8d72, 0x8d78, 0x8d79, 0x8d7a, + 0x8d7b, 0x8d7c, 0x8d7d, 0x8d7e, 0x8d7f, 0x8d80, 0x8d82, 0x8d83, + 0x8d86, 0x8d87, 0x8d88, 0x8d89, 0x8d8c, 0x8d8d, 0x8d8e, 0x8d8f, + 0x8d90, 0x8d92, 0x8d93, 0x8d95, 0x8d96, 0x8d97, 0x8d98, 0x8d99, + 0x8d9a, 0x8d9b, 0x8d9c, 0x8d9d, 0x8d9e, 0x8da0, 0x8da1, 0x8da2, + 0x8da4, 0x8da5, 0x8da6, 0x8da7, 0x8da8, 0x8da9, 0x8daa, 0x8dab, + 0x8dac, 0x8dad, 0x8dae, 0x8daf, 0x8db0, 0x8db2, 0x8db6, 0x8db7, + 0x8db9, 0x8dbb, 0x8dbd, 0x8dc0, 0x8dc1, 0x8dc2, 0x8dc5, 0x8dc7, + 0x8dc8, 0x8dc9, 0x8dca, 0x8dcd, 0x8dd0, 0x8dd2, 0x8dd3, 0x8dd4, + /* 0xdb */ + 0x8dd5, 0x8dd8, 0x8dd9, 0x8ddc, 0x8de0, 0x8de1, 0x8de2, 0x8de5, + 0x8de6, 0x8de7, 0x8de9, 0x8ded, 0x8dee, 0x8df0, 0x8df1, 0x8df2, + 0x8df4, 0x8df6, 0x8dfc, 0x8dfe, 0x8dff, 0x8e00, 0x8e01, 0x8e02, + 0x8e03, 0x8e04, 0x8e06, 0x8e07, 0x8e08, 0x8e0b, 0x8e0d, 0x8e0e, + 0x8e10, 0x8e11, 0x8e12, 0x8e13, 0x8e15, 0x8e16, 0x8e17, 0x8e18, + 0x8e19, 0x8e1a, 0x8e1b, 0x8e1c, 0x8e20, 0x8e21, 0x8e24, 0x8e25, + 0x8e26, 0x8e27, 0x8e28, 0x8e2b, 0x8e2d, 0x8e30, 0x8e32, 0x8e33, + 0x8e34, 0x8e36, 0x8e37, 0x8e38, 0x8e3b, 0x8e3c, 0x8e3e, 0x8e3f, + 0x8e43, 0x8e45, 0x8e46, 0x8e4c, 0x8e4d, 0x8e4e, 0x8e4f, 0x8e50, + 0x8e53, 0x8e54, 0x8e55, 0x8e56, 0x8e57, 0x8e58, 0x8e5a, 0x8e5b, + 0x8e5c, 0x8e5d, 0x8e5e, 0x8e5f, 0x8e60, 0x8e61, 0x8e62, 0x8e63, + 0x8e64, 0x8e65, 0x8e67, 0x8e68, 0x8e6a, 0x8e6b, 0x8e6e, 0x8e71, + /* 0xdc */ + 0x8e73, 0x8e75, 0x8e77, 0x8e78, 0x8e79, 0x8e7a, 0x8e7b, 0x8e7d, + 0x8e7e, 0x8e80, 0x8e82, 0x8e83, 0x8e84, 0x8e86, 0x8e88, 0x8e89, + 0x8e8a, 0x8e8b, 0x8e8c, 0x8e8d, 0x8e8e, 0x8e91, 0x8e92, 0x8e93, + 0x8e95, 0x8e96, 0x8e97, 0x8e98, 0x8e99, 0x8e9a, 0x8e9b, 0x8e9d, + 0x8e9f, 0x8ea0, 0x8ea1, 0x8ea2, 0x8ea3, 0x8ea4, 0x8ea5, 0x8ea6, + 0x8ea7, 0x8ea8, 0x8ea9, 0x8eaa, 0x8ead, 0x8eae, 0x8eb0, 0x8eb1, + 0x8eb3, 0x8eb4, 0x8eb5, 0x8eb6, 0x8eb7, 0x8eb8, 0x8eb9, 0x8ebb, + 0x8ebc, 0x8ebd, 0x8ebe, 0x8ebf, 0x8ec0, 0x8ec1, 0x8ec2, 0x8ec3, + 0x8ec4, 0x8ec5, 0x8ec6, 0x8ec7, 0x8ec8, 0x8ec9, 0x8eca, 0x8ecb, + 0x8ecc, 0x8ecd, 0x8ecf, 0x8ed0, 0x8ed1, 0x8ed2, 0x8ed3, 0x8ed4, + 0x8ed5, 0x8ed6, 0x8ed7, 0x8ed8, 0x8ed9, 0x8eda, 0x8edb, 0x8edc, + 0x8edd, 0x8ede, 0x8edf, 0x8ee0, 0x8ee1, 0x8ee2, 0x8ee3, 0x8ee4, + /* 0xdd */ + 0x8ee5, 0x8ee6, 0x8ee7, 0x8ee8, 0x8ee9, 0x8eea, 0x8eeb, 0x8eec, + 0x8eed, 0x8eee, 0x8eef, 0x8ef0, 0x8ef1, 0x8ef2, 0x8ef3, 0x8ef4, + 0x8ef5, 0x8ef6, 0x8ef7, 0x8ef8, 0x8ef9, 0x8efa, 0x8efb, 0x8efc, + 0x8efd, 0x8efe, 0x8eff, 0x8f00, 0x8f01, 0x8f02, 0x8f03, 0x8f04, + 0x8f05, 0x8f06, 0x8f07, 0x8f08, 0x8f09, 0x8f0a, 0x8f0b, 0x8f0c, + 0x8f0d, 0x8f0e, 0x8f0f, 0x8f10, 0x8f11, 0x8f12, 0x8f13, 0x8f14, + 0x8f15, 0x8f16, 0x8f17, 0x8f18, 0x8f19, 0x8f1a, 0x8f1b, 0x8f1c, + 0x8f1d, 0x8f1e, 0x8f1f, 0x8f20, 0x8f21, 0x8f22, 0x8f23, 0x8f24, + 0x8f25, 0x8f26, 0x8f27, 0x8f28, 0x8f29, 0x8f2a, 0x8f2b, 0x8f2c, + 0x8f2d, 0x8f2e, 0x8f2f, 0x8f30, 0x8f31, 0x8f32, 0x8f33, 0x8f34, + 0x8f35, 0x8f36, 0x8f37, 0x8f38, 0x8f39, 0x8f3a, 0x8f3b, 0x8f3c, + 0x8f3d, 0x8f3e, 0x8f3f, 0x8f40, 0x8f41, 0x8f42, 0x8f43, 0x8f44, + /* 0xde */ + 0x8f45, 0x8f46, 0x8f47, 0x8f48, 0x8f49, 0x8f4a, 0x8f4b, 0x8f4c, + 0x8f4d, 0x8f4e, 0x8f4f, 0x8f50, 0x8f51, 0x8f52, 0x8f53, 0x8f54, + 0x8f55, 0x8f56, 0x8f57, 0x8f58, 0x8f59, 0x8f5a, 0x8f5b, 0x8f5c, + 0x8f5d, 0x8f5e, 0x8f5f, 0x8f60, 0x8f61, 0x8f62, 0x8f63, 0x8f64, + 0x8f65, 0x8f6a, 0x8f80, 0x8f8c, 0x8f92, 0x8f9d, 0x8fa0, 0x8fa1, + 0x8fa2, 0x8fa4, 0x8fa5, 0x8fa6, 0x8fa7, 0x8faa, 0x8fac, 0x8fad, + 0x8fae, 0x8faf, 0x8fb2, 0x8fb3, 0x8fb4, 0x8fb5, 0x8fb7, 0x8fb8, + 0x8fba, 0x8fbb, 0x8fbc, 0x8fbf, 0x8fc0, 0x8fc3, 0x8fc6, 0x8fc9, + 0x8fca, 0x8fcb, 0x8fcc, 0x8fcd, 0x8fcf, 0x8fd2, 0x8fd6, 0x8fd7, + 0x8fda, 0x8fe0, 0x8fe1, 0x8fe3, 0x8fe7, 0x8fec, 0x8fef, 0x8ff1, + 0x8ff2, 0x8ff4, 0x8ff5, 0x8ff6, 0x8ffa, 0x8ffb, 0x8ffc, 0x8ffe, + 0x8fff, 0x9007, 0x9008, 0x900c, 0x900e, 0x9013, 0x9015, 0x9018, + /* 0xdf */ + 0x9019, 0x901c, 0x9023, 0x9024, 0x9025, 0x9027, 0x9028, 0x9029, + 0x902a, 0x902b, 0x902c, 0x9030, 0x9031, 0x9032, 0x9033, 0x9034, + 0x9037, 0x9039, 0x903a, 0x903d, 0x903f, 0x9040, 0x9043, 0x9045, + 0x9046, 0x9048, 0x9049, 0x904a, 0x904b, 0x904c, 0x904e, 0x9054, + 0x9055, 0x9056, 0x9059, 0x905a, 0x905c, 0x905d, 0x905e, 0x905f, + 0x9060, 0x9061, 0x9064, 0x9066, 0x9067, 0x9069, 0x906a, 0x906b, + 0x906c, 0x906f, 0x9070, 0x9071, 0x9072, 0x9073, 0x9076, 0x9077, + 0x9078, 0x9079, 0x907a, 0x907b, 0x907c, 0x907e, 0x9081, 0x9084, + 0x9085, 0x9086, 0x9087, 0x9089, 0x908a, 0x908c, 0x908d, 0x908e, + 0x908f, 0x9090, 0x9092, 0x9094, 0x9096, 0x9098, 0x909a, 0x909c, + 0x909e, 0x909f, 0x90a0, 0x90a4, 0x90a5, 0x90a7, 0x90a8, 0x90a9, + 0x90ab, 0x90ad, 0x90b2, 0x90b7, 0x90bc, 0x90bd, 0x90bf, 0x90c0, + /* 0xe0 */ + 0x90c2, 0x90c3, 0x90c6, 0x90c8, 0x90c9, 0x90cb, 0x90cc, 0x90cd, + 0x90d2, 0x90d4, 0x90d5, 0x90d6, 0x90d8, 0x90d9, 0x90da, 0x90de, + 0x90df, 0x90e0, 0x90e3, 0x90e4, 0x90e5, 0x90e9, 0x90ea, 0x90ec, + 0x90ee, 0x90f0, 0x90f1, 0x90f2, 0x90f3, 0x90f5, 0x90f6, 0x90f7, + 0x90f9, 0x90fa, 0x90fb, 0x90fc, 0x90ff, 0x9100, 0x9101, 0x9103, + 0x9105, 0x9106, 0x9107, 0x9108, 0x9109, 0x910a, 0x910b, 0x910c, + 0x910d, 0x910e, 0x910f, 0x9110, 0x9111, 0x9112, 0x9113, 0x9114, + 0x9115, 0x9116, 0x9117, 0x9118, 0x911a, 0x911b, 0x911c, 0x911d, + 0x911f, 0x9120, 0x9121, 0x9124, 0x9125, 0x9126, 0x9127, 0x9128, + 0x9129, 0x912a, 0x912b, 0x912c, 0x912d, 0x912e, 0x9130, 0x9132, + 0x9133, 0x9134, 0x9135, 0x9136, 0x9137, 0x9138, 0x913a, 0x913b, + 0x913c, 0x913d, 0x913e, 0x913f, 0x9140, 0x9141, 0x9142, 0x9144, + /* 0xe1 */ + 0x9145, 0x9147, 0x9148, 0x9151, 0x9153, 0x9154, 0x9155, 0x9156, + 0x9158, 0x9159, 0x915b, 0x915c, 0x915f, 0x9160, 0x9166, 0x9167, + 0x9168, 0x916b, 0x916d, 0x9173, 0x917a, 0x917b, 0x917c, 0x9180, + 0x9181, 0x9182, 0x9183, 0x9184, 0x9186, 0x9188, 0x918a, 0x918e, + 0x918f, 0x9193, 0x9194, 0x9195, 0x9196, 0x9197, 0x9198, 0x9199, + 0x919c, 0x919d, 0x919e, 0x919f, 0x91a0, 0x91a1, 0x91a4, 0x91a5, + 0x91a6, 0x91a7, 0x91a8, 0x91a9, 0x91ab, 0x91ac, 0x91b0, 0x91b1, + 0x91b2, 0x91b3, 0x91b6, 0x91b7, 0x91b8, 0x91b9, 0x91bb, 0x91bc, + 0x91bd, 0x91be, 0x91bf, 0x91c0, 0x91c1, 0x91c2, 0x91c3, 0x91c4, + 0x91c5, 0x91c6, 0x91c8, 0x91cb, 0x91d0, 0x91d2, 0x91d3, 0x91d4, + 0x91d5, 0x91d6, 0x91d7, 0x91d8, 0x91d9, 0x91da, 0x91db, 0x91dd, + 0x91de, 0x91df, 0x91e0, 0x91e1, 0x91e2, 0x91e3, 0x91e4, 0x91e5, + /* 0xe2 */ + 0x91e6, 0x91e7, 0x91e8, 0x91e9, 0x91ea, 0x91eb, 0x91ec, 0x91ed, + 0x91ee, 0x91ef, 0x91f0, 0x91f1, 0x91f2, 0x91f3, 0x91f4, 0x91f5, + 0x91f6, 0x91f7, 0x91f8, 0x91f9, 0x91fa, 0x91fb, 0x91fc, 0x91fd, + 0x91fe, 0x91ff, 0x9200, 0x9201, 0x9202, 0x9203, 0x9204, 0x9205, + 0x9206, 0x9207, 0x9208, 0x9209, 0x920a, 0x920b, 0x920c, 0x920d, + 0x920e, 0x920f, 0x9210, 0x9211, 0x9212, 0x9213, 0x9214, 0x9215, + 0x9216, 0x9217, 0x9218, 0x9219, 0x921a, 0x921b, 0x921c, 0x921d, + 0x921e, 0x921f, 0x9220, 0x9221, 0x9222, 0x9223, 0x9224, 0x9225, + 0x9226, 0x9227, 0x9228, 0x9229, 0x922a, 0x922b, 0x922c, 0x922d, + 0x922e, 0x922f, 0x9230, 0x9231, 0x9232, 0x9233, 0x9234, 0x9235, + 0x9236, 0x9237, 0x9238, 0x9239, 0x923a, 0x923b, 0x923c, 0x923d, + 0x923e, 0x923f, 0x9240, 0x9241, 0x9242, 0x9243, 0x9244, 0x9245, + /* 0xe3 */ + 0x9246, 0x9247, 0x9248, 0x9249, 0x924a, 0x924b, 0x924c, 0x924d, + 0x924e, 0x924f, 0x9250, 0x9251, 0x9252, 0x9253, 0x9254, 0x9255, + 0x9256, 0x9257, 0x9258, 0x9259, 0x925a, 0x925b, 0x925c, 0x925d, + 0x925e, 0x925f, 0x9260, 0x9261, 0x9262, 0x9263, 0x9264, 0x9265, + 0x9266, 0x9267, 0x9268, 0x9269, 0x926a, 0x926b, 0x926c, 0x926d, + 0x926e, 0x926f, 0x9270, 0x9271, 0x9272, 0x9273, 0x9275, 0x9276, + 0x9277, 0x9278, 0x9279, 0x927a, 0x927b, 0x927c, 0x927d, 0x927e, + 0x927f, 0x9280, 0x9281, 0x9282, 0x9283, 0x9284, 0x9285, 0x9286, + 0x9287, 0x9288, 0x9289, 0x928a, 0x928b, 0x928c, 0x928d, 0x928f, + 0x9290, 0x9291, 0x9292, 0x9293, 0x9294, 0x9295, 0x9296, 0x9297, + 0x9298, 0x9299, 0x929a, 0x929b, 0x929c, 0x929d, 0x929e, 0x929f, + 0x92a0, 0x92a1, 0x92a2, 0x92a3, 0x92a4, 0x92a5, 0x92a6, 0x92a7, + /* 0xe4 */ + 0x92a8, 0x92a9, 0x92aa, 0x92ab, 0x92ac, 0x92ad, 0x92af, 0x92b0, + 0x92b1, 0x92b2, 0x92b3, 0x92b4, 0x92b5, 0x92b6, 0x92b7, 0x92b8, + 0x92b9, 0x92ba, 0x92bb, 0x92bc, 0x92bd, 0x92be, 0x92bf, 0x92c0, + 0x92c1, 0x92c2, 0x92c3, 0x92c4, 0x92c5, 0x92c6, 0x92c7, 0x92c9, + 0x92ca, 0x92cb, 0x92cc, 0x92cd, 0x92ce, 0x92cf, 0x92d0, 0x92d1, + 0x92d2, 0x92d3, 0x92d4, 0x92d5, 0x92d6, 0x92d7, 0x92d8, 0x92d9, + 0x92da, 0x92db, 0x92dc, 0x92dd, 0x92de, 0x92df, 0x92e0, 0x92e1, + 0x92e2, 0x92e3, 0x92e4, 0x92e5, 0x92e6, 0x92e7, 0x92e8, 0x92e9, + 0x92ea, 0x92eb, 0x92ec, 0x92ed, 0x92ee, 0x92ef, 0x92f0, 0x92f1, + 0x92f2, 0x92f3, 0x92f4, 0x92f5, 0x92f6, 0x92f7, 0x92f8, 0x92f9, + 0x92fa, 0x92fb, 0x92fc, 0x92fd, 0x92fe, 0x92ff, 0x9300, 0x9301, + 0x9302, 0x9303, 0x9304, 0x9305, 0x9306, 0x9307, 0x9308, 0x9309, + /* 0xe5 */ + 0x930a, 0x930b, 0x930c, 0x930d, 0x930e, 0x930f, 0x9310, 0x9311, + 0x9312, 0x9313, 0x9314, 0x9315, 0x9316, 0x9317, 0x9318, 0x9319, + 0x931a, 0x931b, 0x931c, 0x931d, 0x931e, 0x931f, 0x9320, 0x9321, + 0x9322, 0x9323, 0x9324, 0x9325, 0x9326, 0x9327, 0x9328, 0x9329, + 0x932a, 0x932b, 0x932c, 0x932d, 0x932e, 0x932f, 0x9330, 0x9331, + 0x9332, 0x9333, 0x9334, 0x9335, 0x9336, 0x9337, 0x9338, 0x9339, + 0x933a, 0x933b, 0x933c, 0x933d, 0x933f, 0x9340, 0x9341, 0x9342, + 0x9343, 0x9344, 0x9345, 0x9346, 0x9347, 0x9348, 0x9349, 0x934a, + 0x934b, 0x934c, 0x934d, 0x934e, 0x934f, 0x9350, 0x9351, 0x9352, + 0x9353, 0x9354, 0x9355, 0x9356, 0x9357, 0x9358, 0x9359, 0x935a, + 0x935b, 0x935c, 0x935d, 0x935e, 0x935f, 0x9360, 0x9361, 0x9362, + 0x9363, 0x9364, 0x9365, 0x9366, 0x9367, 0x9368, 0x9369, 0x936b, + /* 0xe6 */ + 0x936c, 0x936d, 0x936e, 0x936f, 0x9370, 0x9371, 0x9372, 0x9373, + 0x9374, 0x9375, 0x9376, 0x9377, 0x9378, 0x9379, 0x937a, 0x937b, + 0x937c, 0x937d, 0x937e, 0x937f, 0x9380, 0x9381, 0x9382, 0x9383, + 0x9384, 0x9385, 0x9386, 0x9387, 0x9388, 0x9389, 0x938a, 0x938b, + 0x938c, 0x938d, 0x938e, 0x9390, 0x9391, 0x9392, 0x9393, 0x9394, + 0x9395, 0x9396, 0x9397, 0x9398, 0x9399, 0x939a, 0x939b, 0x939c, + 0x939d, 0x939e, 0x939f, 0x93a0, 0x93a1, 0x93a2, 0x93a3, 0x93a4, + 0x93a5, 0x93a6, 0x93a7, 0x93a8, 0x93a9, 0x93aa, 0x93ab, 0x93ac, + 0x93ad, 0x93ae, 0x93af, 0x93b0, 0x93b1, 0x93b2, 0x93b3, 0x93b4, + 0x93b5, 0x93b6, 0x93b7, 0x93b8, 0x93b9, 0x93ba, 0x93bb, 0x93bc, + 0x93bd, 0x93be, 0x93bf, 0x93c0, 0x93c1, 0x93c2, 0x93c3, 0x93c4, + 0x93c5, 0x93c6, 0x93c7, 0x93c8, 0x93c9, 0x93cb, 0x93cc, 0x93cd, + /* 0xe7 */ + 0x93ce, 0x93cf, 0x93d0, 0x93d1, 0x93d2, 0x93d3, 0x93d4, 0x93d5, + 0x93d7, 0x93d8, 0x93d9, 0x93da, 0x93db, 0x93dc, 0x93dd, 0x93de, + 0x93df, 0x93e0, 0x93e1, 0x93e2, 0x93e3, 0x93e4, 0x93e5, 0x93e6, + 0x93e7, 0x93e8, 0x93e9, 0x93ea, 0x93eb, 0x93ec, 0x93ed, 0x93ee, + 0x93ef, 0x93f0, 0x93f1, 0x93f2, 0x93f3, 0x93f4, 0x93f5, 0x93f6, + 0x93f7, 0x93f8, 0x93f9, 0x93fa, 0x93fb, 0x93fc, 0x93fd, 0x93fe, + 0x93ff, 0x9400, 0x9401, 0x9402, 0x9403, 0x9404, 0x9405, 0x9406, + 0x9407, 0x9408, 0x9409, 0x940a, 0x940b, 0x940c, 0x940d, 0x940e, + 0x940f, 0x9410, 0x9411, 0x9412, 0x9413, 0x9414, 0x9415, 0x9416, + 0x9417, 0x9418, 0x9419, 0x941a, 0x941b, 0x941c, 0x941d, 0x941e, + 0x941f, 0x9420, 0x9421, 0x9422, 0x9423, 0x9424, 0x9425, 0x9426, + 0x9427, 0x9428, 0x9429, 0x942a, 0x942b, 0x942c, 0x942d, 0x942e, + /* 0xe8 */ + 0x942f, 0x9430, 0x9431, 0x9432, 0x9433, 0x9434, 0x9435, 0x9436, + 0x9437, 0x9438, 0x9439, 0x943a, 0x943b, 0x943c, 0x943d, 0x943f, + 0x9440, 0x9441, 0x9442, 0x9443, 0x9444, 0x9445, 0x9446, 0x9447, + 0x9448, 0x9449, 0x944a, 0x944b, 0x944c, 0x944d, 0x944e, 0x944f, + 0x9450, 0x9451, 0x9452, 0x9453, 0x9454, 0x9455, 0x9456, 0x9457, + 0x9458, 0x9459, 0x945a, 0x945b, 0x945c, 0x945d, 0x945e, 0x945f, + 0x9460, 0x9461, 0x9462, 0x9463, 0x9464, 0x9465, 0x9466, 0x9467, + 0x9468, 0x9469, 0x946a, 0x946c, 0x946d, 0x946e, 0x946f, 0x9470, + 0x9471, 0x9472, 0x9473, 0x9474, 0x9475, 0x9476, 0x9477, 0x9478, + 0x9479, 0x947a, 0x947b, 0x947c, 0x947d, 0x947e, 0x947f, 0x9480, + 0x9481, 0x9482, 0x9483, 0x9484, 0x9491, 0x9496, 0x9498, 0x94c7, + 0x94cf, 0x94d3, 0x94d4, 0x94da, 0x94e6, 0x94fb, 0x951c, 0x9520, + /* 0xe9 */ + 0x9527, 0x9533, 0x953d, 0x9543, 0x9548, 0x954b, 0x9555, 0x955a, + 0x9560, 0x956e, 0x9574, 0x9575, 0x9577, 0x9578, 0x9579, 0x957a, + 0x957b, 0x957c, 0x957d, 0x957e, 0x9580, 0x9581, 0x9582, 0x9583, + 0x9584, 0x9585, 0x9586, 0x9587, 0x9588, 0x9589, 0x958a, 0x958b, + 0x958c, 0x958d, 0x958e, 0x958f, 0x9590, 0x9591, 0x9592, 0x9593, + 0x9594, 0x9595, 0x9596, 0x9597, 0x9598, 0x9599, 0x959a, 0x959b, + 0x959c, 0x959d, 0x959e, 0x959f, 0x95a0, 0x95a1, 0x95a2, 0x95a3, + 0x95a4, 0x95a5, 0x95a6, 0x95a7, 0x95a8, 0x95a9, 0x95aa, 0x95ab, + 0x95ac, 0x95ad, 0x95ae, 0x95af, 0x95b0, 0x95b1, 0x95b2, 0x95b3, + 0x95b4, 0x95b5, 0x95b6, 0x95b7, 0x95b8, 0x95b9, 0x95ba, 0x95bb, + 0x95bc, 0x95bd, 0x95be, 0x95bf, 0x95c0, 0x95c1, 0x95c2, 0x95c3, + 0x95c4, 0x95c5, 0x95c6, 0x95c7, 0x95c8, 0x95c9, 0x95ca, 0x95cb, + /* 0xea */ + 0x95cc, 0x95cd, 0x95ce, 0x95cf, 0x95d0, 0x95d1, 0x95d2, 0x95d3, + 0x95d4, 0x95d5, 0x95d6, 0x95d7, 0x95d8, 0x95d9, 0x95da, 0x95db, + 0x95dc, 0x95dd, 0x95de, 0x95df, 0x95e0, 0x95e1, 0x95e2, 0x95e3, + 0x95e4, 0x95e5, 0x95e6, 0x95e7, 0x95ec, 0x95ff, 0x9607, 0x9613, + 0x9618, 0x961b, 0x961e, 0x9620, 0x9623, 0x9624, 0x9625, 0x9626, + 0x9627, 0x9628, 0x9629, 0x962b, 0x962c, 0x962d, 0x962f, 0x9630, + 0x9637, 0x9638, 0x9639, 0x963a, 0x963e, 0x9641, 0x9643, 0x964a, + 0x964e, 0x964f, 0x9651, 0x9652, 0x9653, 0x9656, 0x9657, 0x9658, + 0x9659, 0x965a, 0x965c, 0x965d, 0x965e, 0x9660, 0x9663, 0x9665, + 0x9666, 0x966b, 0x966d, 0x966e, 0x966f, 0x9670, 0x9671, 0x9673, + 0x9678, 0x9679, 0x967a, 0x967b, 0x967c, 0x967d, 0x967e, 0x967f, + 0x9680, 0x9681, 0x9682, 0x9683, 0x9684, 0x9687, 0x9689, 0x968a, + /* 0xeb */ + 0x968c, 0x968e, 0x9691, 0x9692, 0x9693, 0x9695, 0x9696, 0x969a, + 0x969b, 0x969d, 0x969e, 0x969f, 0x96a0, 0x96a1, 0x96a2, 0x96a3, + 0x96a4, 0x96a5, 0x96a6, 0x96a8, 0x96a9, 0x96aa, 0x96ab, 0x96ac, + 0x96ad, 0x96ae, 0x96af, 0x96b1, 0x96b2, 0x96b4, 0x96b5, 0x96b7, + 0x96b8, 0x96ba, 0x96bb, 0x96bf, 0x96c2, 0x96c3, 0x96c8, 0x96ca, + 0x96cb, 0x96d0, 0x96d1, 0x96d3, 0x96d4, 0x96d6, 0x96d7, 0x96d8, + 0x96d9, 0x96da, 0x96db, 0x96dc, 0x96dd, 0x96de, 0x96df, 0x96e1, + 0x96e2, 0x96e3, 0x96e4, 0x96e5, 0x96e6, 0x96e7, 0x96eb, 0x96ec, + 0x96ed, 0x96ee, 0x96f0, 0x96f1, 0x96f2, 0x96f4, 0x96f5, 0x96f8, + 0x96fa, 0x96fb, 0x96fc, 0x96fd, 0x96ff, 0x9702, 0x9703, 0x9705, + 0x970a, 0x970b, 0x970c, 0x9710, 0x9711, 0x9712, 0x9714, 0x9715, + 0x9717, 0x9718, 0x9719, 0x971a, 0x971b, 0x971d, 0x971f, 0x9720, + /* 0xec */ + 0x9721, 0x9722, 0x9723, 0x9724, 0x9725, 0x9726, 0x9727, 0x9728, + 0x9729, 0x972b, 0x972c, 0x972e, 0x972f, 0x9731, 0x9733, 0x9734, + 0x9735, 0x9736, 0x9737, 0x973a, 0x973b, 0x973c, 0x973d, 0x973f, + 0x9740, 0x9741, 0x9742, 0x9743, 0x9744, 0x9745, 0x9746, 0x9747, + 0x9748, 0x9749, 0x974a, 0x974b, 0x974c, 0x974d, 0x974e, 0x974f, + 0x9750, 0x9751, 0x9754, 0x9755, 0x9757, 0x9758, 0x975a, 0x975c, + 0x975d, 0x975f, 0x9763, 0x9764, 0x9766, 0x9767, 0x9768, 0x976a, + 0x976b, 0x976c, 0x976d, 0x976e, 0x976f, 0x9770, 0x9771, 0x9772, + 0x9775, 0x9777, 0x9778, 0x9779, 0x977a, 0x977b, 0x977d, 0x977e, + 0x977f, 0x9780, 0x9781, 0x9782, 0x9783, 0x9784, 0x9786, 0x9787, + 0x9788, 0x9789, 0x978a, 0x978c, 0x978e, 0x978f, 0x9790, 0x9793, + 0x9795, 0x9796, 0x9797, 0x9799, 0x979a, 0x979b, 0x979c, 0x979d, + /* 0xed */ + 0x979e, 0x979f, 0x97a1, 0x97a2, 0x97a4, 0x97a5, 0x97a6, 0x97a7, + 0x97a8, 0x97a9, 0x97aa, 0x97ac, 0x97ae, 0x97b0, 0x97b1, 0x97b3, + 0x97b5, 0x97b6, 0x97b7, 0x97b8, 0x97b9, 0x97ba, 0x97bb, 0x97bc, + 0x97bd, 0x97be, 0x97bf, 0x97c0, 0x97c1, 0x97c2, 0x97c3, 0x97c4, + 0x97c5, 0x97c6, 0x97c7, 0x97c8, 0x97c9, 0x97ca, 0x97cb, 0x97cc, + 0x97cd, 0x97ce, 0x97cf, 0x97d0, 0x97d1, 0x97d2, 0x97d3, 0x97d4, + 0x97d5, 0x97d6, 0x97d7, 0x97d8, 0x97d9, 0x97da, 0x97db, 0x97dc, + 0x97dd, 0x97de, 0x97df, 0x97e0, 0x97e1, 0x97e2, 0x97e3, 0x97e4, + 0x97e5, 0x97e8, 0x97ee, 0x97ef, 0x97f0, 0x97f1, 0x97f2, 0x97f4, + 0x97f7, 0x97f8, 0x97f9, 0x97fa, 0x97fb, 0x97fc, 0x97fd, 0x97fe, + 0x97ff, 0x9800, 0x9801, 0x9802, 0x9803, 0x9804, 0x9805, 0x9806, + 0x9807, 0x9808, 0x9809, 0x980a, 0x980b, 0x980c, 0x980d, 0x980e, + /* 0xee */ + 0x980f, 0x9810, 0x9811, 0x9812, 0x9813, 0x9814, 0x9815, 0x9816, + 0x9817, 0x9818, 0x9819, 0x981a, 0x981b, 0x981c, 0x981d, 0x981e, + 0x981f, 0x9820, 0x9821, 0x9822, 0x9823, 0x9824, 0x9825, 0x9826, + 0x9827, 0x9828, 0x9829, 0x982a, 0x982b, 0x982c, 0x982d, 0x982e, + 0x982f, 0x9830, 0x9831, 0x9832, 0x9833, 0x9834, 0x9835, 0x9836, + 0x9837, 0x9838, 0x9839, 0x983a, 0x983b, 0x983c, 0x983d, 0x983e, + 0x983f, 0x9840, 0x9841, 0x9842, 0x9843, 0x9844, 0x9845, 0x9846, + 0x9847, 0x9848, 0x9849, 0x984a, 0x984b, 0x984c, 0x984d, 0x984e, + 0x984f, 0x9850, 0x9851, 0x9852, 0x9853, 0x9854, 0x9855, 0x9856, + 0x9857, 0x9858, 0x9859, 0x985a, 0x985b, 0x985c, 0x985d, 0x985e, + 0x985f, 0x9860, 0x9861, 0x9862, 0x9863, 0x9864, 0x9865, 0x9866, + 0x9867, 0x9868, 0x9869, 0x986a, 0x986b, 0x986c, 0x986d, 0x986e, + /* 0xef */ + 0x986f, 0x9870, 0x9871, 0x9872, 0x9873, 0x9874, 0x988b, 0x988e, + 0x9892, 0x9895, 0x9899, 0x98a3, 0x98a8, 0x98a9, 0x98aa, 0x98ab, + 0x98ac, 0x98ad, 0x98ae, 0x98af, 0x98b0, 0x98b1, 0x98b2, 0x98b3, + 0x98b4, 0x98b5, 0x98b6, 0x98b7, 0x98b8, 0x98b9, 0x98ba, 0x98bb, + 0x98bc, 0x98bd, 0x98be, 0x98bf, 0x98c0, 0x98c1, 0x98c2, 0x98c3, + 0x98c4, 0x98c5, 0x98c6, 0x98c7, 0x98c8, 0x98c9, 0x98ca, 0x98cb, + 0x98cc, 0x98cd, 0x98cf, 0x98d0, 0x98d4, 0x98d6, 0x98d7, 0x98db, + 0x98dc, 0x98dd, 0x98e0, 0x98e1, 0x98e2, 0x98e3, 0x98e4, 0x98e5, + 0x98e6, 0x98e9, 0x98ea, 0x98eb, 0x98ec, 0x98ed, 0x98ee, 0x98ef, + 0x98f0, 0x98f1, 0x98f2, 0x98f3, 0x98f4, 0x98f5, 0x98f6, 0x98f7, + 0x98f8, 0x98f9, 0x98fa, 0x98fb, 0x98fc, 0x98fd, 0x98fe, 0x98ff, + 0x9900, 0x9901, 0x9902, 0x9903, 0x9904, 0x9905, 0x9906, 0x9907, + /* 0xf0 */ + 0x9908, 0x9909, 0x990a, 0x990b, 0x990c, 0x990e, 0x990f, 0x9911, + 0x9912, 0x9913, 0x9914, 0x9915, 0x9916, 0x9917, 0x9918, 0x9919, + 0x991a, 0x991b, 0x991c, 0x991d, 0x991e, 0x991f, 0x9920, 0x9921, + 0x9922, 0x9923, 0x9924, 0x9925, 0x9926, 0x9927, 0x9928, 0x9929, + 0x992a, 0x992b, 0x992c, 0x992d, 0x992f, 0x9930, 0x9931, 0x9932, + 0x9933, 0x9934, 0x9935, 0x9936, 0x9937, 0x9938, 0x9939, 0x993a, + 0x993b, 0x993c, 0x993d, 0x993e, 0x993f, 0x9940, 0x9941, 0x9942, + 0x9943, 0x9944, 0x9945, 0x9946, 0x9947, 0x9948, 0x9949, 0x994a, + 0x994b, 0x994c, 0x994d, 0x994e, 0x994f, 0x9950, 0x9951, 0x9952, + 0x9953, 0x9956, 0x9957, 0x9958, 0x9959, 0x995a, 0x995b, 0x995c, + 0x995d, 0x995e, 0x995f, 0x9960, 0x9961, 0x9962, 0x9964, 0x9966, + 0x9973, 0x9978, 0x9979, 0x997b, 0x997e, 0x9982, 0x9983, 0x9989, + /* 0xf1 */ + 0x998c, 0x998e, 0x999a, 0x999b, 0x999c, 0x999d, 0x999e, 0x999f, + 0x99a0, 0x99a1, 0x99a2, 0x99a3, 0x99a4, 0x99a6, 0x99a7, 0x99a9, + 0x99aa, 0x99ab, 0x99ac, 0x99ad, 0x99ae, 0x99af, 0x99b0, 0x99b1, + 0x99b2, 0x99b3, 0x99b4, 0x99b5, 0x99b6, 0x99b7, 0x99b8, 0x99b9, + 0x99ba, 0x99bb, 0x99bc, 0x99bd, 0x99be, 0x99bf, 0x99c0, 0x99c1, + 0x99c2, 0x99c3, 0x99c4, 0x99c5, 0x99c6, 0x99c7, 0x99c8, 0x99c9, + 0x99ca, 0x99cb, 0x99cc, 0x99cd, 0x99ce, 0x99cf, 0x99d0, 0x99d1, + 0x99d2, 0x99d3, 0x99d4, 0x99d5, 0x99d6, 0x99d7, 0x99d8, 0x99d9, + 0x99da, 0x99db, 0x99dc, 0x99dd, 0x99de, 0x99df, 0x99e0, 0x99e1, + 0x99e2, 0x99e3, 0x99e4, 0x99e5, 0x99e6, 0x99e7, 0x99e8, 0x99e9, + 0x99ea, 0x99eb, 0x99ec, 0x99ed, 0x99ee, 0x99ef, 0x99f0, 0x99f1, + 0x99f2, 0x99f3, 0x99f4, 0x99f5, 0x99f6, 0x99f7, 0x99f8, 0x99f9, + /* 0xf2 */ + 0x99fa, 0x99fb, 0x99fc, 0x99fd, 0x99fe, 0x99ff, 0x9a00, 0x9a01, + 0x9a02, 0x9a03, 0x9a04, 0x9a05, 0x9a06, 0x9a07, 0x9a08, 0x9a09, + 0x9a0a, 0x9a0b, 0x9a0c, 0x9a0d, 0x9a0e, 0x9a0f, 0x9a10, 0x9a11, + 0x9a12, 0x9a13, 0x9a14, 0x9a15, 0x9a16, 0x9a17, 0x9a18, 0x9a19, + 0x9a1a, 0x9a1b, 0x9a1c, 0x9a1d, 0x9a1e, 0x9a1f, 0x9a20, 0x9a21, + 0x9a22, 0x9a23, 0x9a24, 0x9a25, 0x9a26, 0x9a27, 0x9a28, 0x9a29, + 0x9a2a, 0x9a2b, 0x9a2c, 0x9a2d, 0x9a2e, 0x9a2f, 0x9a30, 0x9a31, + 0x9a32, 0x9a33, 0x9a34, 0x9a35, 0x9a36, 0x9a37, 0x9a38, 0x9a39, + 0x9a3a, 0x9a3b, 0x9a3c, 0x9a3d, 0x9a3e, 0x9a3f, 0x9a40, 0x9a41, + 0x9a42, 0x9a43, 0x9a44, 0x9a45, 0x9a46, 0x9a47, 0x9a48, 0x9a49, + 0x9a4a, 0x9a4b, 0x9a4c, 0x9a4d, 0x9a4e, 0x9a4f, 0x9a50, 0x9a51, + 0x9a52, 0x9a53, 0x9a54, 0x9a55, 0x9a56, 0x9a57, 0x9a58, 0x9a59, + /* 0xf3 */ + 0x9a5a, 0x9a5b, 0x9a5c, 0x9a5d, 0x9a5e, 0x9a5f, 0x9a60, 0x9a61, + 0x9a62, 0x9a63, 0x9a64, 0x9a65, 0x9a66, 0x9a67, 0x9a68, 0x9a69, + 0x9a6a, 0x9a6b, 0x9a72, 0x9a83, 0x9a89, 0x9a8d, 0x9a8e, 0x9a94, + 0x9a95, 0x9a99, 0x9aa6, 0x9aa9, 0x9aaa, 0x9aab, 0x9aac, 0x9aad, + 0x9aae, 0x9aaf, 0x9ab2, 0x9ab3, 0x9ab4, 0x9ab5, 0x9ab9, 0x9abb, + 0x9abd, 0x9abe, 0x9abf, 0x9ac3, 0x9ac4, 0x9ac6, 0x9ac7, 0x9ac8, + 0x9ac9, 0x9aca, 0x9acd, 0x9ace, 0x9acf, 0x9ad0, 0x9ad2, 0x9ad4, + 0x9ad5, 0x9ad6, 0x9ad7, 0x9ad9, 0x9ada, 0x9adb, 0x9adc, 0x9add, + 0x9ade, 0x9ae0, 0x9ae2, 0x9ae3, 0x9ae4, 0x9ae5, 0x9ae7, 0x9ae8, + 0x9ae9, 0x9aea, 0x9aec, 0x9aee, 0x9af0, 0x9af1, 0x9af2, 0x9af3, + 0x9af4, 0x9af5, 0x9af6, 0x9af7, 0x9af8, 0x9afa, 0x9afc, 0x9afd, + 0x9afe, 0x9aff, 0x9b00, 0x9b01, 0x9b02, 0x9b04, 0x9b05, 0x9b06, + /* 0xf4 */ + 0x9b07, 0x9b09, 0x9b0a, 0x9b0b, 0x9b0c, 0x9b0d, 0x9b0e, 0x9b10, + 0x9b11, 0x9b12, 0x9b14, 0x9b15, 0x9b16, 0x9b17, 0x9b18, 0x9b19, + 0x9b1a, 0x9b1b, 0x9b1c, 0x9b1d, 0x9b1e, 0x9b20, 0x9b21, 0x9b22, + 0x9b24, 0x9b25, 0x9b26, 0x9b27, 0x9b28, 0x9b29, 0x9b2a, 0x9b2b, + 0x9b2c, 0x9b2d, 0x9b2e, 0x9b30, 0x9b31, 0x9b33, 0x9b34, 0x9b35, + 0x9b36, 0x9b37, 0x9b38, 0x9b39, 0x9b3a, 0x9b3d, 0x9b3e, 0x9b3f, + 0x9b40, 0x9b46, 0x9b4a, 0x9b4b, 0x9b4c, 0x9b4e, 0x9b50, 0x9b52, + 0x9b53, 0x9b55, 0x9b56, 0x9b57, 0x9b58, 0x9b59, 0x9b5a, 0x9b5b, + 0x9b5c, 0x9b5d, 0x9b5e, 0x9b5f, 0x9b60, 0x9b61, 0x9b62, 0x9b63, + 0x9b64, 0x9b65, 0x9b66, 0x9b67, 0x9b68, 0x9b69, 0x9b6a, 0x9b6b, + 0x9b6c, 0x9b6d, 0x9b6e, 0x9b6f, 0x9b70, 0x9b71, 0x9b72, 0x9b73, + 0x9b74, 0x9b75, 0x9b76, 0x9b77, 0x9b78, 0x9b79, 0x9b7a, 0x9b7b, + /* 0xf5 */ + 0x9b7c, 0x9b7d, 0x9b7e, 0x9b7f, 0x9b80, 0x9b81, 0x9b82, 0x9b83, + 0x9b84, 0x9b85, 0x9b86, 0x9b87, 0x9b88, 0x9b89, 0x9b8a, 0x9b8b, + 0x9b8c, 0x9b8d, 0x9b8e, 0x9b8f, 0x9b90, 0x9b91, 0x9b92, 0x9b93, + 0x9b94, 0x9b95, 0x9b96, 0x9b97, 0x9b98, 0x9b99, 0x9b9a, 0x9b9b, + 0x9b9c, 0x9b9d, 0x9b9e, 0x9b9f, 0x9ba0, 0x9ba1, 0x9ba2, 0x9ba3, + 0x9ba4, 0x9ba5, 0x9ba6, 0x9ba7, 0x9ba8, 0x9ba9, 0x9baa, 0x9bab, + 0x9bac, 0x9bad, 0x9bae, 0x9baf, 0x9bb0, 0x9bb1, 0x9bb2, 0x9bb3, + 0x9bb4, 0x9bb5, 0x9bb6, 0x9bb7, 0x9bb8, 0x9bb9, 0x9bba, 0x9bbb, + 0x9bbc, 0x9bbd, 0x9bbe, 0x9bbf, 0x9bc0, 0x9bc1, 0x9bc2, 0x9bc3, + 0x9bc4, 0x9bc5, 0x9bc6, 0x9bc7, 0x9bc8, 0x9bc9, 0x9bca, 0x9bcb, + 0x9bcc, 0x9bcd, 0x9bce, 0x9bcf, 0x9bd0, 0x9bd1, 0x9bd2, 0x9bd3, + 0x9bd4, 0x9bd5, 0x9bd6, 0x9bd7, 0x9bd8, 0x9bd9, 0x9bda, 0x9bdb, + /* 0xf6 */ + 0x9bdc, 0x9bdd, 0x9bde, 0x9bdf, 0x9be0, 0x9be1, 0x9be2, 0x9be3, + 0x9be4, 0x9be5, 0x9be6, 0x9be7, 0x9be8, 0x9be9, 0x9bea, 0x9beb, + 0x9bec, 0x9bed, 0x9bee, 0x9bef, 0x9bf0, 0x9bf1, 0x9bf2, 0x9bf3, + 0x9bf4, 0x9bf5, 0x9bf6, 0x9bf7, 0x9bf8, 0x9bf9, 0x9bfa, 0x9bfb, + 0x9bfc, 0x9bfd, 0x9bfe, 0x9bff, 0x9c00, 0x9c01, 0x9c02, 0x9c03, + 0x9c04, 0x9c05, 0x9c06, 0x9c07, 0x9c08, 0x9c09, 0x9c0a, 0x9c0b, + 0x9c0c, 0x9c0d, 0x9c0e, 0x9c0f, 0x9c10, 0x9c11, 0x9c12, 0x9c13, + 0x9c14, 0x9c15, 0x9c16, 0x9c17, 0x9c18, 0x9c19, 0x9c1a, 0x9c1b, + 0x9c1c, 0x9c1d, 0x9c1e, 0x9c1f, 0x9c20, 0x9c21, 0x9c22, 0x9c23, + 0x9c24, 0x9c25, 0x9c26, 0x9c27, 0x9c28, 0x9c29, 0x9c2a, 0x9c2b, + 0x9c2c, 0x9c2d, 0x9c2e, 0x9c2f, 0x9c30, 0x9c31, 0x9c32, 0x9c33, + 0x9c34, 0x9c35, 0x9c36, 0x9c37, 0x9c38, 0x9c39, 0x9c3a, 0x9c3b, + /* 0xf7 */ + 0x9c3c, 0x9c3d, 0x9c3e, 0x9c3f, 0x9c40, 0x9c41, 0x9c42, 0x9c43, + 0x9c44, 0x9c45, 0x9c46, 0x9c47, 0x9c48, 0x9c49, 0x9c4a, 0x9c4b, + 0x9c4c, 0x9c4d, 0x9c4e, 0x9c4f, 0x9c50, 0x9c51, 0x9c52, 0x9c53, + 0x9c54, 0x9c55, 0x9c56, 0x9c57, 0x9c58, 0x9c59, 0x9c5a, 0x9c5b, + 0x9c5c, 0x9c5d, 0x9c5e, 0x9c5f, 0x9c60, 0x9c61, 0x9c62, 0x9c63, + 0x9c64, 0x9c65, 0x9c66, 0x9c67, 0x9c68, 0x9c69, 0x9c6a, 0x9c6b, + 0x9c6c, 0x9c6d, 0x9c6e, 0x9c6f, 0x9c70, 0x9c71, 0x9c72, 0x9c73, + 0x9c74, 0x9c75, 0x9c76, 0x9c77, 0x9c78, 0x9c79, 0x9c7a, 0x9c7b, + 0x9c7d, 0x9c7e, 0x9c80, 0x9c83, 0x9c84, 0x9c89, 0x9c8a, 0x9c8c, + 0x9c8f, 0x9c93, 0x9c96, 0x9c97, 0x9c98, 0x9c99, 0x9c9d, 0x9caa, + 0x9cac, 0x9caf, 0x9cb9, 0x9cbe, 0x9cbf, 0x9cc0, 0x9cc1, 0x9cc2, + 0x9cc8, 0x9cc9, 0x9cd1, 0x9cd2, 0x9cda, 0x9cdb, 0x9ce0, 0x9ce1, + /* 0xf8 */ + 0x9ce3, 0x9ce4, 0x9ce5, 0x9ce6, 0x9ce7, 0x9ce8, 0x9ce9, 0x9cea, + 0x9ceb, 0x9cec, 0x9ced, 0x9cee, 0x9cef, 0x9cf0, 0x9cf1, 0x9cf2, + 0x9cf3, 0x9cf4, 0x9cf5, 0x9cf6, 0x9cf7, 0x9cf8, 0x9cf9, 0x9cfa, + 0x9cfb, 0x9cfc, 0x9cfd, 0x9cfe, 0x9cff, 0x9d00, 0x9d01, 0x9d02, + 0x9d03, 0x9d04, 0x9d05, 0x9d06, 0x9d07, 0x9d08, 0x9d09, 0x9d0a, + 0x9d0b, 0x9d0c, 0x9d0d, 0x9d0e, 0x9d0f, 0x9d10, 0x9d11, 0x9d12, + 0x9d13, 0x9d14, 0x9d15, 0x9d16, 0x9d17, 0x9d18, 0x9d19, 0x9d1a, + 0x9d1b, 0x9d1c, 0x9d1d, 0x9d1e, 0x9d1f, 0x9d20, 0x9d21, 0x9d22, + 0x9d23, 0x9d24, 0x9d25, 0x9d26, 0x9d27, 0x9d28, 0x9d29, 0x9d2a, + 0x9d2b, 0x9d2c, 0x9d2d, 0x9d2e, 0x9d2f, 0x9d30, 0x9d31, 0x9d32, + 0x9d33, 0x9d34, 0x9d35, 0x9d36, 0x9d37, 0x9d38, 0x9d39, 0x9d3a, + 0x9d3b, 0x9d3c, 0x9d3d, 0x9d3e, 0x9d3f, 0x9d40, 0x9d41, 0x9d42, + /* 0xf9 */ + 0x9d43, 0x9d44, 0x9d45, 0x9d46, 0x9d47, 0x9d48, 0x9d49, 0x9d4a, + 0x9d4b, 0x9d4c, 0x9d4d, 0x9d4e, 0x9d4f, 0x9d50, 0x9d51, 0x9d52, + 0x9d53, 0x9d54, 0x9d55, 0x9d56, 0x9d57, 0x9d58, 0x9d59, 0x9d5a, + 0x9d5b, 0x9d5c, 0x9d5d, 0x9d5e, 0x9d5f, 0x9d60, 0x9d61, 0x9d62, + 0x9d63, 0x9d64, 0x9d65, 0x9d66, 0x9d67, 0x9d68, 0x9d69, 0x9d6a, + 0x9d6b, 0x9d6c, 0x9d6d, 0x9d6e, 0x9d6f, 0x9d70, 0x9d71, 0x9d72, + 0x9d73, 0x9d74, 0x9d75, 0x9d76, 0x9d77, 0x9d78, 0x9d79, 0x9d7a, + 0x9d7b, 0x9d7c, 0x9d7d, 0x9d7e, 0x9d7f, 0x9d80, 0x9d81, 0x9d82, + 0x9d83, 0x9d84, 0x9d85, 0x9d86, 0x9d87, 0x9d88, 0x9d89, 0x9d8a, + 0x9d8b, 0x9d8c, 0x9d8d, 0x9d8e, 0x9d8f, 0x9d90, 0x9d91, 0x9d92, + 0x9d93, 0x9d94, 0x9d95, 0x9d96, 0x9d97, 0x9d98, 0x9d99, 0x9d9a, + 0x9d9b, 0x9d9c, 0x9d9d, 0x9d9e, 0x9d9f, 0x9da0, 0x9da1, 0x9da2, + /* 0xfa */ + 0x9da3, 0x9da4, 0x9da5, 0x9da6, 0x9da7, 0x9da8, 0x9da9, 0x9daa, + 0x9dab, 0x9dac, 0x9dad, 0x9dae, 0x9daf, 0x9db0, 0x9db1, 0x9db2, + 0x9db3, 0x9db4, 0x9db5, 0x9db6, 0x9db7, 0x9db8, 0x9db9, 0x9dba, + 0x9dbb, 0x9dbc, 0x9dbd, 0x9dbe, 0x9dbf, 0x9dc0, 0x9dc1, 0x9dc2, + 0x9dc3, 0x9dc4, 0x9dc5, 0x9dc6, 0x9dc7, 0x9dc8, 0x9dc9, 0x9dca, + 0x9dcb, 0x9dcc, 0x9dcd, 0x9dce, 0x9dcf, 0x9dd0, 0x9dd1, 0x9dd2, + 0x9dd3, 0x9dd4, 0x9dd5, 0x9dd6, 0x9dd7, 0x9dd8, 0x9dd9, 0x9dda, + 0x9ddb, 0x9ddc, 0x9ddd, 0x9dde, 0x9ddf, 0x9de0, 0x9de1, 0x9de2, + 0x9de3, 0x9de4, 0x9de5, 0x9de6, 0x9de7, 0x9de8, 0x9de9, 0x9dea, + 0x9deb, 0x9dec, 0x9ded, 0x9dee, 0x9def, 0x9df0, 0x9df1, 0x9df2, + 0x9df3, 0x9df4, 0x9df5, 0x9df6, 0x9df7, 0x9df8, 0x9df9, 0x9dfa, + 0x9dfb, 0x9dfc, 0x9dfd, 0x9dfe, 0x9dff, 0x9e00, 0x9e01, 0x9e02, + /* 0xfb */ + 0x9e03, 0x9e04, 0x9e05, 0x9e06, 0x9e07, 0x9e08, 0x9e09, 0x9e0a, + 0x9e0b, 0x9e0c, 0x9e0d, 0x9e0e, 0x9e0f, 0x9e10, 0x9e11, 0x9e12, + 0x9e13, 0x9e14, 0x9e15, 0x9e16, 0x9e17, 0x9e18, 0x9e19, 0x9e1a, + 0x9e1b, 0x9e1c, 0x9e1d, 0x9e1e, 0x9e24, 0x9e27, 0x9e2e, 0x9e30, + 0x9e34, 0x9e3b, 0x9e3c, 0x9e40, 0x9e4d, 0x9e50, 0x9e52, 0x9e53, + 0x9e54, 0x9e56, 0x9e59, 0x9e5d, 0x9e5f, 0x9e60, 0x9e61, 0x9e62, + 0x9e65, 0x9e6e, 0x9e6f, 0x9e72, 0x9e74, 0x9e75, 0x9e76, 0x9e77, + 0x9e78, 0x9e79, 0x9e7a, 0x9e7b, 0x9e7c, 0x9e7d, 0x9e80, 0x9e81, + 0x9e83, 0x9e84, 0x9e85, 0x9e86, 0x9e89, 0x9e8a, 0x9e8c, 0x9e8d, + 0x9e8e, 0x9e8f, 0x9e90, 0x9e91, 0x9e94, 0x9e95, 0x9e96, 0x9e97, + 0x9e98, 0x9e99, 0x9e9a, 0x9e9b, 0x9e9c, 0x9e9e, 0x9ea0, 0x9ea1, + 0x9ea2, 0x9ea3, 0x9ea4, 0x9ea5, 0x9ea7, 0x9ea8, 0x9ea9, 0x9eaa, + /* 0xfc */ + 0x9eab, 0x9eac, 0x9ead, 0x9eae, 0x9eaf, 0x9eb0, 0x9eb1, 0x9eb2, + 0x9eb3, 0x9eb5, 0x9eb6, 0x9eb7, 0x9eb9, 0x9eba, 0x9ebc, 0x9ebf, + 0x9ec0, 0x9ec1, 0x9ec2, 0x9ec3, 0x9ec5, 0x9ec6, 0x9ec7, 0x9ec8, + 0x9eca, 0x9ecb, 0x9ecc, 0x9ed0, 0x9ed2, 0x9ed3, 0x9ed5, 0x9ed6, + 0x9ed7, 0x9ed9, 0x9eda, 0x9ede, 0x9ee1, 0x9ee3, 0x9ee4, 0x9ee6, + 0x9ee8, 0x9eeb, 0x9eec, 0x9eed, 0x9eee, 0x9ef0, 0x9ef1, 0x9ef2, + 0x9ef3, 0x9ef4, 0x9ef5, 0x9ef6, 0x9ef7, 0x9ef8, 0x9efa, 0x9efd, + 0x9eff, 0x9f00, 0x9f01, 0x9f02, 0x9f03, 0x9f04, 0x9f05, 0x9f06, + 0x9f07, 0x9f08, 0x9f09, 0x9f0a, 0x9f0c, 0x9f0f, 0x9f11, 0x9f12, + 0x9f14, 0x9f15, 0x9f16, 0x9f18, 0x9f1a, 0x9f1b, 0x9f1c, 0x9f1d, + 0x9f1e, 0x9f1f, 0x9f21, 0x9f23, 0x9f24, 0x9f25, 0x9f26, 0x9f27, + 0x9f28, 0x9f29, 0x9f2a, 0x9f2b, 0x9f2d, 0x9f2e, 0x9f30, 0x9f31, + /* 0xfd */ + 0x9f32, 0x9f33, 0x9f34, 0x9f35, 0x9f36, 0x9f38, 0x9f3a, 0x9f3c, + 0x9f3f, 0x9f40, 0x9f41, 0x9f42, 0x9f43, 0x9f45, 0x9f46, 0x9f47, + 0x9f48, 0x9f49, 0x9f4a, 0x9f4b, 0x9f4c, 0x9f4d, 0x9f4e, 0x9f4f, + 0x9f52, 0x9f53, 0x9f54, 0x9f55, 0x9f56, 0x9f57, 0x9f58, 0x9f59, + 0x9f5a, 0x9f5b, 0x9f5c, 0x9f5d, 0x9f5e, 0x9f5f, 0x9f60, 0x9f61, + 0x9f62, 0x9f63, 0x9f64, 0x9f65, 0x9f66, 0x9f67, 0x9f68, 0x9f69, + 0x9f6a, 0x9f6b, 0x9f6c, 0x9f6d, 0x9f6e, 0x9f6f, 0x9f70, 0x9f71, + 0x9f72, 0x9f73, 0x9f74, 0x9f75, 0x9f76, 0x9f77, 0x9f78, 0x9f79, + 0x9f7a, 0x9f7b, 0x9f7c, 0x9f7d, 0x9f7e, 0x9f81, 0x9f82, 0x9f8d, + 0x9f8e, 0x9f8f, 0x9f90, 0x9f91, 0x9f92, 0x9f93, 0x9f94, 0x9f95, + 0x9f96, 0x9f97, 0x9f98, 0x9f9c, 0x9f9d, 0x9f9e, 0x9fa1, 0x9fa2, + 0x9fa3, 0x9fa4, 0x9fa5, 0xf92c, 0xf979, 0xf995, 0xf9e7, 0xf9f1, + /* 0xfe */ + 0xfa0c, 0xfa0d, 0xfa0e, 0xfa0f, 0xfa11, 0xfa13, 0xfa14, 0xfa18, + 0xfa1f, 0xfa20, 0xfa21, 0xfa23, 0xfa24, 0xfa27, 0xfa28, 0xfa29, +}; + +static int +gbkext2_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0xa8 && c1 <= 0xfe)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0x80 && c2 < 0xa1)) { + unsigned int i = 96 * (c1 - 0x81) + (c2 - (c2 >= 0x80 ? 0x41 : 0x40)); + unsigned short wc = 0xfffd; + { + if (i < 12016) + wc = gbkext2_2uni_pagea8[i-3744]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + diff --git a/graf2d/win32gdk/gdk/src/iconv/gbkext_inv.h b/graf2d/win32gdk/gdk/src/iconv/gbkext_inv.h new file mode 100644 index 0000000000000..45f57d9b762a4 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/gbkext_inv.h @@ -0,0 +1,2343 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GBK extensions + */ + +static const unsigned short gbkext_inv_2charset[14313] = { + 0xa840, 0xa841, 0xa842, 0xa95c, 0xa843, 0xa844, 0xa845, 0xa846, + 0xa847, 0xa848, 0xa959, 0xa849, 0xa84a, 0xa84b, 0xa84c, 0xa84d, + 0xa84e, 0xa84f, 0xa850, 0xa851, 0xa852, 0xa892, 0xa853, 0xa854, + 0xa855, 0xa856, 0xa857, 0xa858, 0xa859, 0xa85a, 0xa85b, 0xa85c, + 0xa85d, 0xa85e, 0xa85f, 0xa860, 0xa861, 0xa862, 0xa863, 0xa864, + 0xa865, 0xa866, 0xa867, 0xa868, 0xa869, 0xa86a, 0xa86b, 0xa86c, + 0xa86d, 0xa86e, 0xa86f, 0xa870, 0xa871, 0xa872, 0xa873, 0xa874, + 0xa875, 0xa876, 0xa877, 0xa878, 0xa879, 0xa87a, 0xa87b, 0xa87c, + 0xa87d, 0xa87e, 0xa880, 0xa881, 0xa882, 0xa883, 0xa884, 0xa885, + 0xa886, 0xa887, 0xa888, 0xa889, 0xa88a, 0xa88b, 0xa88c, 0xa88d, + 0xa88e, 0xa88f, 0xa890, 0xa891, 0xa965, 0xa996, 0xa893, 0xa894, + 0xa895, 0xa940, 0xa941, 0xa942, 0xa943, 0xa944, 0xa945, 0xa946, + 0xa947, 0xa948, 0xa961, 0xa962, 0xa966, 0xa967, 0xa960, 0xa963, + 0xa964, 0xa95a, 0xa949, 0xa94a, 0xa94b, 0xa94c, 0xa94d, 0xa94e, + 0xa94f, 0xa950, 0xa951, 0xa952, 0xa953, 0xa954, 0x8140, 0x8141, + 0x8142, 0x8143, 0x8144, 0x8145, 0x8146, 0x8147, 0x8148, 0x8149, + 0x814a, 0x814b, 0x814c, 0x814d, 0x814e, 0x814f, 0x8150, 0x8151, + 0x8152, 0x8153, 0x8154, 0x8155, 0x8156, 0x8157, 0x8158, 0x8159, + 0x815a, 0x815b, 0x815c, 0x815d, 0x815e, 0x815f, 0x8160, 0x8161, + 0x8162, 0x8163, 0x8164, 0x8165, 0x8166, 0x8167, 0x8168, 0x8169, + 0x816a, 0x816b, 0x816c, 0x816d, 0x816e, 0x816f, 0x8170, 0x8171, + 0x8172, 0x8173, 0x8174, 0x8175, 0x8176, 0x8177, 0x8178, 0x8179, + 0x817a, 0x817b, 0x817c, 0x817d, 0x817e, 0x8180, 0x8181, 0x8182, + 0x8183, 0x8184, 0x8185, 0x8186, 0x8187, 0x8188, 0x8189, 0x818a, + 0x818b, 0x818c, 0x818d, 0x818e, 0x818f, 0x8190, 0x8191, 0x8192, + 0x8193, 0x8194, 0x8195, 0x8196, 0x8197, 0x8198, 0x8199, 0x819a, + 0x819b, 0x819c, 0x819d, 0x819e, 0x819f, 0x81a0, 0x81a1, 0x81a2, + 0x81a3, 0x81a4, 0x81a5, 0x81a6, 0x81a7, 0x81a8, 0x81a9, 0x81aa, + 0x81ab, 0x81ac, 0x81ad, 0x81ae, 0x81af, 0x81b0, 0x81b1, 0x81b2, + 0x81b3, 0x81b4, 0x81b5, 0x81b6, 0x81b7, 0x81b8, 0x81b9, 0x81ba, + 0x81bb, 0x81bc, 0x81bd, 0x81be, 0x81bf, 0x81c0, 0x81c1, 0x81c2, + 0x81c3, 0x81c4, 0x81c5, 0x81c6, 0x81c7, 0x81c8, 0x81c9, 0x81ca, + 0x81cb, 0x81cc, 0x81cd, 0x81ce, 0x81cf, 0x81d0, 0x81d1, 0x81d2, + 0x81d3, 0x81d4, 0x81d5, 0x81d6, 0x81d7, 0x81d8, 0x81d9, 0x81da, + 0x81db, 0x81dc, 0x81dd, 0x81de, 0x81df, 0x81e0, 0x81e1, 0x81e2, + 0x81e3, 0x81e4, 0x81e5, 0x81e6, 0x81e7, 0x81e8, 0x81e9, 0x81ea, + 0x81eb, 0x81ec, 0x81ed, 0x81ee, 0x81ef, 0x81f0, 0x81f1, 0x81f2, + 0x81f3, 0x81f4, 0x81f5, 0x81f6, 0x81f7, 0x81f8, 0x81f9, 0x81fa, + 0x81fb, 0x81fc, 0x81fd, 0x81fe, 0x8240, 0x8241, 0x8242, 0x8243, + 0x8244, 0x8245, 0x8246, 0x8247, 0x8248, 0x8249, 0x824a, 0x824b, + 0x824c, 0x824d, 0x824e, 0x824f, 0x8250, 0x8251, 0x8252, 0x8253, + 0x8254, 0x8255, 0x8256, 0x8257, 0x8258, 0x8259, 0x825a, 0x825b, + 0x825c, 0x825d, 0x825e, 0x825f, 0x8260, 0x8261, 0x8262, 0x8263, + 0x8264, 0x8265, 0x8266, 0x8267, 0x8268, 0x8269, 0x826a, 0x826b, + 0x826c, 0x826d, 0x826e, 0x826f, 0x8270, 0x8271, 0x8272, 0x8273, + 0x8274, 0x8275, 0x8276, 0x8277, 0x8278, 0x8279, 0x827a, 0x827b, + 0x827c, 0x827d, 0x827e, 0x8280, 0x8281, 0x8282, 0x8283, 0x8284, + 0x8285, 0x8286, 0x8287, 0x8288, 0x8289, 0x828a, 0x828b, 0x828c, + 0x828d, 0x828e, 0x828f, 0x8290, 0x8291, 0x8292, 0x8293, 0x8294, + 0x8295, 0x8296, 0x8297, 0x8298, 0x8299, 0x829a, 0x829b, 0x829c, + 0x829d, 0x829e, 0x829f, 0x82a0, 0x82a1, 0x82a2, 0x82a3, 0x82a4, + 0x82a5, 0x82a6, 0x82a7, 0x82a8, 0x82a9, 0x82aa, 0x82ab, 0x82ac, + 0x82ad, 0x82ae, 0x82af, 0x82b0, 0x82b1, 0x82b2, 0x82b3, 0x82b4, + 0x82b5, 0x82b6, 0x82b7, 0x82b8, 0x82b9, 0x82ba, 0x82bb, 0x82bc, + 0x82bd, 0x82be, 0x82bf, 0x82c0, 0x82c1, 0x82c2, 0x82c3, 0x82c4, + 0x82c5, 0x82c6, 0x82c7, 0x82c8, 0x82c9, 0x82ca, 0x82cb, 0x82cc, + 0x82cd, 0x82ce, 0x82cf, 0x82d0, 0x82d1, 0x82d2, 0x82d3, 0x82d4, + 0x82d5, 0x82d6, 0x82d7, 0x82d8, 0x82d9, 0x82da, 0x82db, 0x82dc, + 0x82dd, 0x82de, 0x82df, 0x82e0, 0x82e1, 0x82e2, 0x82e3, 0x82e4, + 0x82e5, 0x82e6, 0x82e7, 0x82e8, 0x82e9, 0x82ea, 0x82eb, 0x82ec, + 0x82ed, 0x82ee, 0x82ef, 0x82f0, 0x82f1, 0x82f2, 0x82f3, 0x82f4, + 0x82f5, 0x82f6, 0x82f7, 0x82f8, 0x82f9, 0x82fa, 0x82fb, 0x82fc, + 0x82fd, 0x82fe, 0x8340, 0x8341, 0x8342, 0x8343, 0x8344, 0x8345, + 0x8346, 0x8347, 0x8348, 0x8349, 0x834a, 0x834b, 0x834c, 0x834d, + 0x834e, 0x834f, 0x8350, 0x8351, 0x8352, 0x8353, 0x8354, 0x8355, + 0x8356, 0x8357, 0x8358, 0x8359, 0x835a, 0x835b, 0x835c, 0x835d, + 0x835e, 0x835f, 0x8360, 0x8361, 0x8362, 0x8363, 0x8364, 0x8365, + 0x8366, 0x8367, 0x8368, 0x8369, 0x836a, 0x836b, 0x836c, 0x836d, + 0x836e, 0x836f, 0x8370, 0x8371, 0x8372, 0x8373, 0x8374, 0x8375, + 0x8376, 0x8377, 0x8378, 0x8379, 0x837a, 0x837b, 0x837c, 0x837d, + 0x837e, 0x8380, 0x8381, 0x8382, 0x8383, 0x8384, 0x8385, 0x8386, + 0x8387, 0x8388, 0x8389, 0x838a, 0x838b, 0x838c, 0x838d, 0x838e, + 0x838f, 0x8390, 0x8391, 0x8392, 0x8393, 0x8394, 0x8395, 0x8396, + 0x8397, 0x8398, 0x8399, 0x839a, 0x839b, 0x839c, 0x839d, 0x839e, + 0x839f, 0x83a0, 0x83a1, 0x83a2, 0x83a3, 0x83a4, 0x83a5, 0x83a6, + 0x83a7, 0x83a8, 0x83a9, 0x83aa, 0x83ab, 0x83ac, 0x83ad, 0x83ae, + 0x83af, 0x83b0, 0x83b1, 0x83b2, 0x83b3, 0x83b4, 0x83b5, 0x83b6, + 0x83b7, 0x83b8, 0x83b9, 0x83ba, 0x83bb, 0x83bc, 0x83bd, 0x83be, + 0x83bf, 0x83c0, 0x83c1, 0x83c2, 0x83c3, 0x83c4, 0x83c5, 0x83c6, + 0x83c7, 0x83c8, 0x83c9, 0x83ca, 0x83cb, 0x83cc, 0x83cd, 0x83ce, + 0x83cf, 0x83d0, 0x83d1, 0x83d2, 0x83d3, 0x83d4, 0x83d5, 0x83d6, + 0x83d7, 0x83d8, 0x83d9, 0x83da, 0x83db, 0x83dc, 0x83dd, 0x83de, + 0x83df, 0x83e0, 0x83e1, 0x83e2, 0x83e3, 0x83e4, 0x83e5, 0x83e6, + 0x83e7, 0x83e8, 0x83e9, 0x83ea, 0x83eb, 0x83ec, 0x83ed, 0x83ee, + 0x83ef, 0x83f0, 0x83f1, 0x83f2, 0x83f3, 0x83f4, 0x83f5, 0x83f6, + 0x83f7, 0x83f8, 0x83f9, 0x83fa, 0x83fb, 0x83fc, 0x83fd, 0x83fe, + 0x8440, 0x8441, 0x8442, 0x8443, 0x8444, 0x8445, 0x8446, 0x8447, + 0x8448, 0x8449, 0x844a, 0x844b, 0x844c, 0x844d, 0x844e, 0x844f, + 0x8450, 0x8451, 0x8452, 0x8453, 0x8454, 0x8455, 0x8456, 0x8457, + 0x8458, 0x8459, 0x845a, 0x845b, 0x845c, 0x845d, 0x845e, 0x845f, + 0x8460, 0x8461, 0x8462, 0x8463, 0x8464, 0x8465, 0x8466, 0x8467, + 0x8468, 0x8469, 0x846a, 0x846b, 0x846c, 0x846d, 0x846e, 0x846f, + 0x8470, 0x8471, 0x8472, 0x8473, 0x8474, 0x8475, 0x8476, 0x8477, + 0x8478, 0x8479, 0x847a, 0x847b, 0x847c, 0x847d, 0x847e, 0x8480, + 0x8481, 0x8482, 0x8483, 0x8484, 0x8485, 0x8486, 0x8487, 0x8488, + 0x8489, 0x848a, 0x848b, 0x848c, 0x848d, 0x848e, 0x848f, 0x8490, + 0x8491, 0x8492, 0x8493, 0x8494, 0x8495, 0x8496, 0x8497, 0x8498, + 0x8499, 0x849a, 0x849b, 0x849c, 0x849d, 0x849e, 0x849f, 0x84a0, + 0x84a1, 0x84a2, 0x84a3, 0x84a4, 0x84a5, 0x84a6, 0x84a7, 0x84a8, + 0x84a9, 0x84aa, 0x84ab, 0x84ac, 0x84ad, 0x84ae, 0x84af, 0x84b0, + 0x84b1, 0x84b2, 0x84b3, 0x84b4, 0x84b5, 0x84b6, 0x84b7, 0x84b8, + 0x84b9, 0x84ba, 0x84bb, 0x84bc, 0x84bd, 0x84be, 0x84bf, 0x84c0, + 0x84c1, 0x84c2, 0x84c3, 0x84c4, 0x84c5, 0x84c6, 0x84c7, 0x84c8, + 0x84c9, 0x84ca, 0x84cb, 0x84cc, 0x84cd, 0x84ce, 0x84cf, 0x84d0, + 0x84d1, 0x84d2, 0x84d3, 0x84d4, 0x84d5, 0x84d6, 0x84d7, 0x84d8, + 0x84d9, 0x84da, 0x84db, 0x84dc, 0x84dd, 0x84de, 0x84df, 0x84e0, + 0x84e1, 0x84e2, 0x84e3, 0x84e4, 0x84e5, 0x84e6, 0x84e7, 0x84e8, + 0x84e9, 0x84ea, 0x84eb, 0x84ec, 0x84ed, 0x84ee, 0x84ef, 0x84f0, + 0x84f1, 0x84f2, 0x84f3, 0x84f4, 0x84f5, 0x84f6, 0x84f7, 0x84f8, + 0x84f9, 0x84fa, 0x84fb, 0x84fc, 0x84fd, 0x84fe, 0x8540, 0x8541, + 0x8542, 0x8543, 0x8544, 0x8545, 0x8546, 0x8547, 0x8548, 0x8549, + 0x854a, 0x854b, 0x854c, 0x854d, 0x854e, 0x854f, 0x8550, 0x8551, + 0x8552, 0x8553, 0x8554, 0x8555, 0x8556, 0x8557, 0x8558, 0x8559, + 0x855a, 0x855b, 0x855c, 0x855d, 0x855e, 0x855f, 0x8560, 0x8561, + 0x8562, 0x8563, 0x8564, 0x8565, 0x8566, 0x8567, 0x8568, 0x8569, + 0x856a, 0x856b, 0x856c, 0x856d, 0x856e, 0x856f, 0x8570, 0x8571, + 0x8572, 0x8573, 0x8574, 0x8575, 0x8576, 0x8577, 0x8578, 0x8579, + 0x857a, 0x857b, 0x857c, 0x857d, 0x857e, 0x8580, 0x8581, 0x8582, + 0x8583, 0x8584, 0x8585, 0x8586, 0x8587, 0x8588, 0x8589, 0x858a, + 0x858b, 0x858c, 0x858d, 0x858e, 0x858f, 0x8590, 0x8591, 0x8592, + 0x8593, 0x8594, 0x8595, 0x8596, 0x8597, 0x8598, 0x8599, 0x859a, + 0x859b, 0x859c, 0x859d, 0x859e, 0x859f, 0x85a0, 0x85a1, 0x85a2, + 0x85a3, 0x85a4, 0x85a5, 0x85a6, 0x85a7, 0x85a8, 0x85a9, 0x85aa, + 0x85ab, 0x85ac, 0x85ad, 0x85ae, 0x85af, 0x85b0, 0x85b1, 0x85b2, + 0x85b3, 0x85b4, 0x85b5, 0x85b6, 0x85b7, 0x85b8, 0x85b9, 0x85ba, + 0x85bb, 0x85bc, 0x85bd, 0x85be, 0x85bf, 0x85c0, 0x85c1, 0x85c2, + 0x85c3, 0x85c4, 0x85c5, 0x85c6, 0x85c7, 0x85c8, 0x85c9, 0x85ca, + 0x85cb, 0x85cc, 0x85cd, 0x85ce, 0x85cf, 0x85d0, 0x85d1, 0x85d2, + 0x85d3, 0x85d4, 0x85d5, 0x85d6, 0x85d7, 0x85d8, 0x85d9, 0x85da, + 0x85db, 0x85dc, 0x85dd, 0x85de, 0x85df, 0x85e0, 0x85e1, 0x85e2, + 0x85e3, 0x85e4, 0x85e5, 0x85e6, 0x85e7, 0x85e8, 0x85e9, 0x85ea, + 0x85eb, 0x85ec, 0x85ed, 0x85ee, 0x85ef, 0x85f0, 0x85f1, 0x85f2, + 0x85f3, 0x85f4, 0x85f5, 0x85f6, 0x85f7, 0x85f8, 0x85f9, 0x85fa, + 0x85fb, 0x85fc, 0x85fd, 0x85fe, 0x8640, 0x8641, 0x8642, 0x8643, + 0x8644, 0x8645, 0x8646, 0x8647, 0x8648, 0x8649, 0x864a, 0x864b, + 0x864c, 0x864d, 0x864e, 0x864f, 0x8650, 0x8651, 0x8652, 0x8653, + 0x8654, 0x8655, 0x8656, 0x8657, 0x8658, 0x8659, 0x865a, 0x865b, + 0x865c, 0x865d, 0x865e, 0x865f, 0x8660, 0x8661, 0x8662, 0x8663, + 0x8664, 0x8665, 0x8666, 0x8667, 0x8668, 0x8669, 0x866a, 0x866b, + 0x866c, 0x866d, 0x866e, 0x866f, 0x8670, 0x8671, 0x8672, 0x8673, + 0x8674, 0x8675, 0x8676, 0x8677, 0x8678, 0x8679, 0x867a, 0x867b, + 0x867c, 0x867d, 0x867e, 0x8680, 0x8681, 0x8682, 0x8683, 0x8684, + 0x8685, 0x8686, 0x8687, 0x8688, 0x8689, 0x868a, 0x868b, 0x868c, + 0x868d, 0x868e, 0x868f, 0x8690, 0x8691, 0x8692, 0x8693, 0x8694, + 0x8695, 0x8696, 0x8697, 0x8698, 0x8699, 0x869a, 0x869b, 0x869c, + 0x869d, 0x869e, 0x869f, 0x86a0, 0x86a1, 0x86a2, 0x86a3, 0x86a4, + 0x86a5, 0x86a6, 0x86a7, 0x86a8, 0x86a9, 0x86aa, 0x86ab, 0x86ac, + 0x86ad, 0x86ae, 0x86af, 0x86b0, 0x86b1, 0x86b2, 0x86b3, 0x86b4, + 0x86b5, 0x86b6, 0x86b7, 0x86b8, 0x86b9, 0x86ba, 0x86bb, 0x86bc, + 0x86bd, 0x86be, 0x86bf, 0x86c0, 0x86c1, 0x86c2, 0x86c3, 0x86c4, + 0x86c5, 0x86c6, 0x86c7, 0x86c8, 0x86c9, 0x86ca, 0x86cb, 0x86cc, + 0x86cd, 0x86ce, 0x86cf, 0x86d0, 0x86d1, 0x86d2, 0x86d3, 0x86d4, + 0x86d5, 0x86d6, 0x86d7, 0x86d8, 0x86d9, 0x86da, 0x86db, 0x86dc, + 0x86dd, 0x86de, 0x86df, 0x86e0, 0x86e1, 0x86e2, 0x86e3, 0x86e4, + 0x86e5, 0x86e6, 0x86e7, 0x86e8, 0x86e9, 0x86ea, 0x86eb, 0x86ec, + 0x86ed, 0x86ee, 0x86ef, 0x86f0, 0x86f1, 0x86f2, 0x86f3, 0x86f4, + 0x86f5, 0x86f6, 0x86f7, 0x86f8, 0x86f9, 0x86fa, 0x86fb, 0x86fc, + 0x86fd, 0x86fe, 0x8740, 0x8741, 0x8742, 0x8743, 0x8744, 0x8745, + 0x8746, 0x8747, 0x8748, 0x8749, 0x874a, 0x874b, 0x874c, 0x874d, + 0x874e, 0x874f, 0x8750, 0x8751, 0x8752, 0x8753, 0x8754, 0x8755, + 0x8756, 0x8757, 0x8758, 0x8759, 0x875a, 0x875b, 0x875c, 0x875d, + 0x875e, 0x875f, 0x8760, 0x8761, 0x8762, 0x8763, 0x8764, 0x8765, + 0x8766, 0x8767, 0x8768, 0x8769, 0x876a, 0x876b, 0x876c, 0x876d, + 0x876e, 0x876f, 0x8770, 0x8771, 0x8772, 0x8773, 0x8774, 0x8775, + 0x8776, 0x8777, 0x8778, 0x8779, 0x877a, 0x877b, 0x877c, 0x877d, + 0x877e, 0x8780, 0x8781, 0x8782, 0x8783, 0x8784, 0x8785, 0x8786, + 0x8787, 0x8788, 0x8789, 0x878a, 0x878b, 0x878c, 0x878d, 0x878e, + 0x878f, 0x8790, 0x8791, 0x8792, 0x8793, 0x8794, 0x8795, 0x8796, + 0x8797, 0x8798, 0x8799, 0x879a, 0x879b, 0x879c, 0x879d, 0x879e, + 0x879f, 0x87a0, 0x87a1, 0x87a2, 0x87a3, 0x87a4, 0x87a5, 0x87a6, + 0x87a7, 0x87a8, 0x87a9, 0x87aa, 0x87ab, 0x87ac, 0x87ad, 0x87ae, + 0x87af, 0x87b0, 0x87b1, 0x87b2, 0x87b3, 0x87b4, 0x87b5, 0x87b6, + 0x87b7, 0x87b8, 0x87b9, 0x87ba, 0x87bb, 0x87bc, 0x87bd, 0x87be, + 0x87bf, 0x87c0, 0x87c1, 0x87c2, 0x87c3, 0x87c4, 0x87c5, 0x87c6, + 0x87c7, 0x87c8, 0x87c9, 0x87ca, 0x87cb, 0x87cc, 0x87cd, 0x87ce, + 0x87cf, 0x87d0, 0x87d1, 0x87d2, 0x87d3, 0x87d4, 0x87d5, 0x87d6, + 0x87d7, 0x87d8, 0x87d9, 0x87da, 0x87db, 0x87dc, 0x87dd, 0x87de, + 0x87df, 0x87e0, 0x87e1, 0x87e2, 0x87e3, 0x87e4, 0x87e5, 0x87e6, + 0x87e7, 0x87e8, 0x87e9, 0x87ea, 0x87eb, 0x87ec, 0x87ed, 0x87ee, + 0x87ef, 0x87f0, 0x87f1, 0x87f2, 0x87f3, 0x87f4, 0x87f5, 0x87f6, + 0x87f7, 0x87f8, 0x87f9, 0x87fa, 0x87fb, 0x87fc, 0x87fd, 0x87fe, + 0x8840, 0x8841, 0x8842, 0x8843, 0x8844, 0x8845, 0x8846, 0x8847, + 0x8848, 0x8849, 0x884a, 0x884b, 0x884c, 0x884d, 0x884e, 0x884f, + 0x8850, 0x8851, 0x8852, 0x8853, 0x8854, 0x8855, 0x8856, 0x8857, + 0x8858, 0x8859, 0x885a, 0x885b, 0x885c, 0x885d, 0x885e, 0x885f, + 0x8860, 0x8861, 0x8862, 0x8863, 0x8864, 0x8865, 0x8866, 0x8867, + 0x8868, 0x8869, 0x886a, 0x886b, 0x886c, 0x886d, 0x886e, 0x886f, + 0x8870, 0x8871, 0x8872, 0x8873, 0x8874, 0x8875, 0x8876, 0x8877, + 0x8878, 0x8879, 0x887a, 0x887b, 0x887c, 0x887d, 0x887e, 0x8880, + 0x8881, 0x8882, 0x8883, 0x8884, 0x8885, 0x8886, 0x8887, 0x8888, + 0x8889, 0x888a, 0x888b, 0x888c, 0x888d, 0x888e, 0x888f, 0x8890, + 0x8891, 0x8892, 0x8893, 0x8894, 0x8895, 0x8896, 0x8897, 0x8898, + 0x8899, 0x889a, 0x889b, 0x889c, 0x889d, 0x889e, 0x889f, 0x88a0, + 0x88a1, 0x88a2, 0x88a3, 0x88a4, 0x88a5, 0x88a6, 0x88a7, 0x88a8, + 0x88a9, 0x88aa, 0x88ab, 0x88ac, 0x88ad, 0x88ae, 0x88af, 0x88b0, + 0x88b1, 0x88b2, 0x88b3, 0x88b4, 0x88b5, 0x88b6, 0x88b7, 0x88b8, + 0x88b9, 0x88ba, 0x88bb, 0x88bc, 0x88bd, 0x88be, 0x88bf, 0x88c0, + 0x88c1, 0x88c2, 0x88c3, 0x88c4, 0x88c5, 0x88c6, 0x88c7, 0x88c8, + 0x88c9, 0x88ca, 0x88cb, 0x88cc, 0x88cd, 0x88ce, 0x88cf, 0x88d0, + 0x88d1, 0x88d2, 0x88d3, 0x88d4, 0x88d5, 0x88d6, 0x88d7, 0x88d8, + 0x88d9, 0x88da, 0x88db, 0x88dc, 0x88dd, 0x88de, 0x88df, 0x88e0, + 0x88e1, 0x88e2, 0x88e3, 0x88e4, 0x88e5, 0x88e6, 0x88e7, 0x88e8, + 0x88e9, 0x88ea, 0x88eb, 0x88ec, 0x88ed, 0x88ee, 0x88ef, 0x88f0, + 0x88f1, 0x88f2, 0x88f3, 0x88f4, 0x88f5, 0x88f6, 0x88f7, 0x88f8, + 0x88f9, 0x88fa, 0x88fb, 0x88fc, 0x88fd, 0x88fe, 0x8940, 0x8941, + 0x8942, 0x8943, 0x8944, 0x8945, 0x8946, 0x8947, 0x8948, 0x8949, + 0x894a, 0x894b, 0x894c, 0x894d, 0x894e, 0x894f, 0x8950, 0x8951, + 0x8952, 0x8953, 0x8954, 0x8955, 0x8956, 0x8957, 0x8958, 0x8959, + 0x895a, 0x895b, 0x895c, 0x895d, 0x895e, 0x895f, 0x8960, 0x8961, + 0x8962, 0x8963, 0x8964, 0x8965, 0x8966, 0x8967, 0x8968, 0x8969, + 0x896a, 0x896b, 0x896c, 0x896d, 0x896e, 0x896f, 0x8970, 0x8971, + 0x8972, 0x8973, 0x8974, 0x8975, 0x8976, 0x8977, 0x8978, 0x8979, + 0x897a, 0x897b, 0x897c, 0x897d, 0x897e, 0x8980, 0x8981, 0x8982, + 0x8983, 0x8984, 0x8985, 0x8986, 0x8987, 0x8988, 0x8989, 0x898a, + 0x898b, 0x898c, 0x898d, 0x898e, 0x898f, 0x8990, 0x8991, 0x8992, + 0x8993, 0x8994, 0x8995, 0x8996, 0x8997, 0x8998, 0x8999, 0x899a, + 0x899b, 0x899c, 0x899d, 0x899e, 0x899f, 0x89a0, 0x89a1, 0x89a2, + 0x89a3, 0x89a4, 0x89a5, 0x89a6, 0x89a7, 0x89a8, 0x89a9, 0x89aa, + 0x89ab, 0x89ac, 0x89ad, 0x89ae, 0x89af, 0x89b0, 0x89b1, 0x89b2, + 0x89b3, 0x89b4, 0x89b5, 0x89b6, 0x89b7, 0x89b8, 0x89b9, 0x89ba, + 0x89bb, 0x89bc, 0x89bd, 0x89be, 0x89bf, 0x89c0, 0x89c1, 0x89c2, + 0x89c3, 0x89c4, 0x89c5, 0x89c6, 0x89c7, 0x89c8, 0x89c9, 0x89ca, + 0x89cb, 0x89cc, 0x89cd, 0x89ce, 0x89cf, 0x89d0, 0x89d1, 0x89d2, + 0x89d3, 0x89d4, 0x89d5, 0x89d6, 0x89d7, 0x89d8, 0x89d9, 0x89da, + 0x89db, 0x89dc, 0x89dd, 0x89de, 0x89df, 0x89e0, 0x89e1, 0x89e2, + 0x89e3, 0x89e4, 0x89e5, 0x89e6, 0x89e7, 0x89e8, 0x89e9, 0x89ea, + 0x89eb, 0x89ec, 0x89ed, 0x89ee, 0x89ef, 0x89f0, 0x89f1, 0x89f2, + 0x89f3, 0x89f4, 0x89f5, 0x89f6, 0x89f7, 0x89f8, 0x89f9, 0x89fa, + 0x89fb, 0x89fc, 0x89fd, 0x89fe, 0x8a40, 0x8a41, 0x8a42, 0x8a43, + 0x8a44, 0x8a45, 0x8a46, 0x8a47, 0x8a48, 0x8a49, 0x8a4a, 0x8a4b, + 0x8a4c, 0x8a4d, 0x8a4e, 0x8a4f, 0x8a50, 0x8a51, 0x8a52, 0x8a53, + 0x8a54, 0x8a55, 0x8a56, 0x8a57, 0x8a58, 0x8a59, 0x8a5a, 0x8a5b, + 0x8a5c, 0x8a5d, 0x8a5e, 0x8a5f, 0x8a60, 0x8a61, 0x8a62, 0x8a63, + 0x8a64, 0x8a65, 0x8a66, 0x8a67, 0x8a68, 0x8a69, 0x8a6a, 0x8a6b, + 0x8a6c, 0x8a6d, 0x8a6e, 0x8a6f, 0x8a70, 0x8a71, 0x8a72, 0x8a73, + 0x8a74, 0x8a75, 0x8a76, 0x8a77, 0x8a78, 0x8a79, 0x8a7a, 0x8a7b, + 0x8a7c, 0x8a7d, 0x8a7e, 0x8a80, 0x8a81, 0x8a82, 0x8a83, 0x8a84, + 0x8a85, 0x8a86, 0x8a87, 0x8a88, 0x8a89, 0x8a8a, 0x8a8b, 0x8a8c, + 0x8a8d, 0x8a8e, 0x8a8f, 0x8a90, 0x8a91, 0x8a92, 0x8a93, 0x8a94, + 0x8a95, 0x8a96, 0x8a97, 0x8a98, 0x8a99, 0x8a9a, 0x8a9b, 0x8a9c, + 0x8a9d, 0x8a9e, 0x8a9f, 0x8aa0, 0x8aa1, 0x8aa2, 0x8aa3, 0x8aa4, + 0x8aa5, 0x8aa6, 0x8aa7, 0x8aa8, 0x8aa9, 0x8aaa, 0x8aab, 0x8aac, + 0x8aad, 0x8aae, 0x8aaf, 0x8ab0, 0x8ab1, 0x8ab2, 0x8ab3, 0x8ab4, + 0x8ab5, 0x8ab6, 0x8ab7, 0x8ab8, 0x8ab9, 0x8aba, 0x8abb, 0x8abc, + 0x8abd, 0x8abe, 0x8abf, 0x8ac0, 0x8ac1, 0x8ac2, 0x8ac3, 0x8ac4, + 0x8ac5, 0x8ac6, 0x8ac7, 0x8ac8, 0x8ac9, 0x8aca, 0x8acb, 0x8acc, + 0x8acd, 0x8ace, 0x8acf, 0x8ad0, 0x8ad1, 0x8ad2, 0x8ad3, 0x8ad4, + 0x8ad5, 0x8ad6, 0x8ad7, 0x8ad8, 0x8ad9, 0x8ada, 0x8adb, 0x8adc, + 0x8add, 0x8ade, 0x8adf, 0x8ae0, 0x8ae1, 0x8ae2, 0x8ae3, 0x8ae4, + 0x8ae5, 0x8ae6, 0x8ae7, 0x8ae8, 0x8ae9, 0x8aea, 0x8aeb, 0x8aec, + 0x8aed, 0x8aee, 0x8aef, 0x8af0, 0x8af1, 0x8af2, 0x8af3, 0x8af4, + 0x8af5, 0x8af6, 0x8af7, 0x8af8, 0x8af9, 0x8afa, 0x8afb, 0x8afc, + 0x8afd, 0x8afe, 0x8b40, 0x8b41, 0x8b42, 0x8b43, 0x8b44, 0x8b45, + 0x8b46, 0x8b47, 0x8b48, 0x8b49, 0x8b4a, 0x8b4b, 0x8b4c, 0x8b4d, + 0x8b4e, 0x8b4f, 0x8b50, 0x8b51, 0x8b52, 0x8b53, 0x8b54, 0x8b55, + 0x8b56, 0x8b57, 0x8b58, 0x8b59, 0x8b5a, 0x8b5b, 0x8b5c, 0x8b5d, + 0x8b5e, 0x8b5f, 0x8b60, 0x8b61, 0x8b62, 0x8b63, 0x8b64, 0x8b65, + 0x8b66, 0x8b67, 0x8b68, 0x8b69, 0x8b6a, 0x8b6b, 0x8b6c, 0x8b6d, + 0x8b6e, 0x8b6f, 0x8b70, 0x8b71, 0x8b72, 0x8b73, 0x8b74, 0x8b75, + 0x8b76, 0x8b77, 0x8b78, 0x8b79, 0x8b7a, 0x8b7b, 0x8b7c, 0x8b7d, + 0x8b7e, 0x8b80, 0x8b81, 0x8b82, 0x8b83, 0x8b84, 0x8b85, 0x8b86, + 0x8b87, 0x8b88, 0x8b89, 0x8b8a, 0x8b8b, 0x8b8c, 0x8b8d, 0x8b8e, + 0x8b8f, 0x8b90, 0x8b91, 0x8b92, 0x8b93, 0x8b94, 0x8b95, 0x8b96, + 0x8b97, 0x8b98, 0x8b99, 0x8b9a, 0x8b9b, 0x8b9c, 0x8b9d, 0x8b9e, + 0x8b9f, 0x8ba0, 0x8ba1, 0x8ba2, 0x8ba3, 0x8ba4, 0x8ba5, 0x8ba6, + 0x8ba7, 0x8ba8, 0x8ba9, 0x8baa, 0x8bab, 0x8bac, 0x8bad, 0x8bae, + 0x8baf, 0x8bb0, 0x8bb1, 0x8bb2, 0x8bb3, 0x8bb4, 0x8bb5, 0x8bb6, + 0x8bb7, 0x8bb8, 0x8bb9, 0x8bba, 0x8bbb, 0x8bbc, 0x8bbd, 0x8bbe, + 0x8bbf, 0x8bc0, 0x8bc1, 0x8bc2, 0x8bc3, 0x8bc4, 0x8bc5, 0x8bc6, + 0x8bc7, 0x8bc8, 0x8bc9, 0x8bca, 0x8bcb, 0x8bcc, 0x8bcd, 0x8bce, + 0x8bcf, 0x8bd0, 0x8bd1, 0x8bd2, 0x8bd3, 0x8bd4, 0x8bd5, 0x8bd6, + 0x8bd7, 0x8bd8, 0x8bd9, 0x8bda, 0x8bdb, 0x8bdc, 0x8bdd, 0x8bde, + 0x8bdf, 0x8be0, 0x8be1, 0x8be2, 0x8be3, 0x8be4, 0x8be5, 0x8be6, + 0x8be7, 0x8be8, 0x8be9, 0x8bea, 0x8beb, 0x8bec, 0x8bed, 0x8bee, + 0x8bef, 0x8bf0, 0x8bf1, 0x8bf2, 0x8bf3, 0x8bf4, 0x8bf5, 0x8bf6, + 0x8bf7, 0x8bf8, 0x8bf9, 0x8bfa, 0x8bfb, 0x8bfc, 0x8bfd, 0x8bfe, + 0x8c40, 0x8c41, 0x8c42, 0x8c43, 0x8c44, 0x8c45, 0x8c46, 0x8c47, + 0x8c48, 0x8c49, 0x8c4a, 0x8c4b, 0x8c4c, 0x8c4d, 0x8c4e, 0x8c4f, + 0x8c50, 0x8c51, 0x8c52, 0x8c53, 0x8c54, 0x8c55, 0x8c56, 0x8c57, + 0x8c58, 0x8c59, 0x8c5a, 0x8c5b, 0x8c5c, 0x8c5d, 0x8c5e, 0x8c5f, + 0x8c60, 0x8c61, 0x8c62, 0x8c63, 0x8c64, 0x8c65, 0x8c66, 0x8c67, + 0x8c68, 0x8c69, 0x8c6a, 0x8c6b, 0x8c6c, 0x8c6d, 0x8c6e, 0x8c6f, + 0x8c70, 0x8c71, 0x8c72, 0x8c73, 0x8c74, 0x8c75, 0x8c76, 0x8c77, + 0x8c78, 0x8c79, 0x8c7a, 0x8c7b, 0x8c7c, 0x8c7d, 0x8c7e, 0x8c80, + 0x8c81, 0x8c82, 0x8c83, 0x8c84, 0x8c85, 0x8c86, 0x8c87, 0x8c88, + 0x8c89, 0x8c8a, 0x8c8b, 0x8c8c, 0x8c8d, 0x8c8e, 0x8c8f, 0x8c90, + 0x8c91, 0x8c92, 0x8c93, 0x8c94, 0x8c95, 0x8c96, 0x8c97, 0x8c98, + 0x8c99, 0x8c9a, 0x8c9b, 0x8c9c, 0x8c9d, 0x8c9e, 0x8c9f, 0x8ca0, + 0x8ca1, 0x8ca2, 0x8ca3, 0x8ca4, 0x8ca5, 0x8ca6, 0x8ca7, 0x8ca8, + 0x8ca9, 0x8caa, 0x8cab, 0x8cac, 0x8cad, 0x8cae, 0x8caf, 0x8cb0, + 0x8cb1, 0x8cb2, 0x8cb3, 0x8cb4, 0x8cb5, 0x8cb6, 0x8cb7, 0x8cb8, + 0x8cb9, 0x8cba, 0x8cbb, 0x8cbc, 0x8cbd, 0x8cbe, 0x8cbf, 0x8cc0, + 0x8cc1, 0x8cc2, 0x8cc3, 0x8cc4, 0x8cc5, 0x8cc6, 0x8cc7, 0x8cc8, + 0x8cc9, 0x8cca, 0x8ccb, 0x8ccc, 0x8ccd, 0x8cce, 0x8ccf, 0x8cd0, + 0x8cd1, 0x8cd2, 0x8cd3, 0x8cd4, 0x8cd5, 0x8cd6, 0x8cd7, 0x8cd8, + 0x8cd9, 0x8cda, 0x8cdb, 0x8cdc, 0x8cdd, 0x8cde, 0x8cdf, 0x8ce0, + 0x8ce1, 0x8ce2, 0x8ce3, 0x8ce4, 0x8ce5, 0x8ce6, 0x8ce7, 0x8ce8, + 0x8ce9, 0x8cea, 0x8ceb, 0x8cec, 0x8ced, 0x8cee, 0x8cef, 0x8cf0, + 0x8cf1, 0x8cf2, 0x8cf3, 0x8cf4, 0x8cf5, 0x8cf6, 0x8cf7, 0x8cf8, + 0x8cf9, 0x8cfa, 0x8cfb, 0x8cfc, 0x8cfd, 0x8cfe, 0x8d40, 0x8d41, + 0x8d42, 0x8d43, 0x8d44, 0x8d45, 0x8d46, 0x8d47, 0x8d48, 0x8d49, + 0x8d4a, 0x8d4b, 0x8d4c, 0x8d4d, 0x8d4e, 0x8d4f, 0x8d50, 0x8d51, + 0x8d52, 0x8d53, 0x8d54, 0x8d55, 0x8d56, 0x8d57, 0x8d58, 0x8d59, + 0x8d5a, 0x8d5b, 0x8d5c, 0x8d5d, 0x8d5e, 0x8d5f, 0x8d60, 0x8d61, + 0x8d62, 0x8d63, 0x8d64, 0x8d65, 0x8d66, 0x8d67, 0x8d68, 0x8d69, + 0x8d6a, 0x8d6b, 0x8d6c, 0x8d6d, 0x8d6e, 0x8d6f, 0x8d70, 0x8d71, + 0x8d72, 0x8d73, 0x8d74, 0x8d75, 0x8d76, 0x8d77, 0x8d78, 0x8d79, + 0x8d7a, 0x8d7b, 0x8d7c, 0x8d7d, 0x8d7e, 0x8d80, 0x8d81, 0x8d82, + 0x8d83, 0x8d84, 0x8d85, 0x8d86, 0x8d87, 0x8d88, 0x8d89, 0x8d8a, + 0x8d8b, 0x8d8c, 0x8d8d, 0x8d8e, 0x8d8f, 0x8d90, 0x8d91, 0x8d92, + 0x8d93, 0x8d94, 0x8d95, 0x8d96, 0x8d97, 0x8d98, 0x8d99, 0x8d9a, + 0x8d9b, 0x8d9c, 0x8d9d, 0x8d9e, 0x8d9f, 0x8da0, 0x8da1, 0x8da2, + 0x8da3, 0x8da4, 0x8da5, 0x8da6, 0x8da7, 0x8da8, 0x8da9, 0x8daa, + 0x8dab, 0x8dac, 0x8dad, 0x8dae, 0x8daf, 0x8db0, 0x8db1, 0x8db2, + 0x8db3, 0x8db4, 0x8db5, 0x8db6, 0x8db7, 0x8db8, 0x8db9, 0x8dba, + 0x8dbb, 0x8dbc, 0x8dbd, 0x8dbe, 0x8dbf, 0x8dc0, 0x8dc1, 0x8dc2, + 0x8dc3, 0x8dc4, 0x8dc5, 0x8dc6, 0x8dc7, 0x8dc8, 0x8dc9, 0x8dca, + 0x8dcb, 0x8dcc, 0x8dcd, 0x8dce, 0x8dcf, 0x8dd0, 0x8dd1, 0x8dd2, + 0x8dd3, 0x8dd4, 0x8dd5, 0x8dd6, 0x8dd7, 0x8dd8, 0x8dd9, 0x8dda, + 0x8ddb, 0x8ddc, 0x8ddd, 0x8dde, 0x8ddf, 0x8de0, 0x8de1, 0x8de2, + 0x8de3, 0x8de4, 0x8de5, 0x8de6, 0x8de7, 0x8de8, 0x8de9, 0x8dea, + 0x8deb, 0x8dec, 0x8ded, 0x8dee, 0x8def, 0x8df0, 0x8df1, 0x8df2, + 0x8df3, 0x8df4, 0x8df5, 0x8df6, 0x8df7, 0x8df8, 0x8df9, 0x8dfa, + 0x8dfb, 0x8dfc, 0x8dfd, 0x8dfe, 0x8e40, 0x8e41, 0x8e42, 0x8e43, + 0x8e44, 0x8e45, 0x8e46, 0x8e47, 0x8e48, 0x8e49, 0x8e4a, 0x8e4b, + 0x8e4c, 0x8e4d, 0x8e4e, 0x8e4f, 0x8e50, 0x8e51, 0x8e52, 0x8e53, + 0x8e54, 0x8e55, 0x8e56, 0x8e57, 0x8e58, 0x8e59, 0x8e5a, 0x8e5b, + 0x8e5c, 0x8e5d, 0x8e5e, 0x8e5f, 0x8e60, 0x8e61, 0x8e62, 0x8e63, + 0x8e64, 0x8e65, 0x8e66, 0x8e67, 0x8e68, 0x8e69, 0x8e6a, 0x8e6b, + 0x8e6c, 0x8e6d, 0x8e6e, 0x8e6f, 0x8e70, 0x8e71, 0x8e72, 0x8e73, + 0x8e74, 0x8e75, 0x8e76, 0x8e77, 0x8e78, 0x8e79, 0x8e7a, 0x8e7b, + 0x8e7c, 0x8e7d, 0x8e7e, 0x8e80, 0x8e81, 0x8e82, 0x8e83, 0x8e84, + 0x8e85, 0x8e86, 0x8e87, 0x8e88, 0x8e89, 0x8e8a, 0x8e8b, 0x8e8c, + 0x8e8d, 0x8e8e, 0x8e8f, 0x8e90, 0x8e91, 0x8e92, 0x8e93, 0x8e94, + 0x8e95, 0x8e96, 0x8e97, 0x8e98, 0x8e99, 0x8e9a, 0x8e9b, 0x8e9c, + 0x8e9d, 0x8e9e, 0x8e9f, 0x8ea0, 0x8ea1, 0x8ea2, 0x8ea3, 0x8ea4, + 0x8ea5, 0x8ea6, 0x8ea7, 0x8ea8, 0x8ea9, 0x8eaa, 0x8eab, 0x8eac, + 0x8ead, 0x8eae, 0x8eaf, 0x8eb0, 0x8eb1, 0x8eb2, 0x8eb3, 0x8eb4, + 0x8eb5, 0x8eb6, 0x8eb7, 0x8eb8, 0x8eb9, 0x8eba, 0x8ebb, 0x8ebc, + 0x8ebd, 0x8ebe, 0x8ebf, 0x8ec0, 0x8ec1, 0x8ec2, 0x8ec3, 0x8ec4, + 0x8ec5, 0x8ec6, 0x8ec7, 0x8ec8, 0x8ec9, 0x8eca, 0x8ecb, 0x8ecc, + 0x8ecd, 0x8ece, 0x8ecf, 0x8ed0, 0x8ed1, 0x8ed2, 0x8ed3, 0x8ed4, + 0x8ed5, 0x8ed6, 0x8ed7, 0x8ed8, 0x8ed9, 0x8eda, 0x8edb, 0x8edc, + 0x8edd, 0x8ede, 0x8edf, 0x8ee0, 0x8ee1, 0x8ee2, 0x8ee3, 0x8ee4, + 0x8ee5, 0x8ee6, 0x8ee7, 0x8ee8, 0x8ee9, 0x8eea, 0x8eeb, 0x8eec, + 0x8eed, 0x8eee, 0x8eef, 0x8ef0, 0x8ef1, 0x8ef2, 0x8ef3, 0x8ef4, + 0x8ef5, 0x8ef6, 0x8ef7, 0x8ef8, 0x8ef9, 0x8efa, 0x8efb, 0x8efc, + 0x8efd, 0x8efe, 0x8f40, 0x8f41, 0x8f42, 0x8f43, 0x8f44, 0x8f45, + 0x8f46, 0x8f47, 0x8f48, 0x8f49, 0x8f4a, 0x8f4b, 0x8f4c, 0x8f4d, + 0x8f4e, 0x8f4f, 0x8f50, 0x8f51, 0x8f52, 0x8f53, 0x8f54, 0x8f55, + 0x8f56, 0x8f57, 0x8f58, 0x8f59, 0x8f5a, 0x8f5b, 0x8f5c, 0x8f5d, + 0x8f5e, 0x8f5f, 0x8f60, 0x8f61, 0x8f62, 0x8f63, 0x8f64, 0x8f65, + 0x8f66, 0x8f67, 0x8f68, 0x8f69, 0x8f6a, 0x8f6b, 0x8f6c, 0x8f6d, + 0x8f6e, 0x8f6f, 0x8f70, 0x8f71, 0x8f72, 0x8f73, 0x8f74, 0x8f75, + 0x8f76, 0x8f77, 0x8f78, 0x8f79, 0x8f7a, 0x8f7b, 0x8f7c, 0x8f7d, + 0x8f7e, 0x8f80, 0x8f81, 0x8f82, 0x8f83, 0x8f84, 0x8f85, 0x8f86, + 0x8f87, 0x8f88, 0x8f89, 0x8f8a, 0x8f8b, 0x8f8c, 0x8f8d, 0x8f8e, + 0x8f8f, 0x8f90, 0x8f91, 0x8f92, 0x8f93, 0x8f94, 0x8f95, 0x8f96, + 0x8f97, 0x8f98, 0x8f99, 0x8f9a, 0x8f9b, 0x8f9c, 0x8f9d, 0x8f9e, + 0x8f9f, 0x8fa0, 0x8fa1, 0x8fa2, 0x8fa3, 0x8fa4, 0x8fa5, 0x8fa6, + 0x8fa7, 0x8fa8, 0x8fa9, 0x8faa, 0x8fab, 0x8fac, 0x8fad, 0x8fae, + 0x8faf, 0x8fb0, 0x8fb1, 0x8fb2, 0x8fb3, 0x8fb4, 0x8fb5, 0x8fb6, + 0x8fb7, 0x8fb8, 0x8fb9, 0x8fba, 0x8fbb, 0x8fbc, 0x8fbd, 0x8fbe, + 0x8fbf, 0x8fc0, 0x8fc1, 0x8fc2, 0x8fc3, 0x8fc4, 0x8fc5, 0x8fc6, + 0x8fc7, 0x8fc8, 0x8fc9, 0x8fca, 0x8fcb, 0x8fcc, 0x8fcd, 0x8fce, + 0x8fcf, 0x8fd0, 0x8fd1, 0x8fd2, 0x8fd3, 0x8fd4, 0x8fd5, 0x8fd6, + 0x8fd7, 0x8fd8, 0x8fd9, 0x8fda, 0x8fdb, 0x8fdc, 0x8fdd, 0x8fde, + 0x8fdf, 0x8fe0, 0x8fe1, 0x8fe2, 0x8fe3, 0x8fe4, 0x8fe5, 0x8fe6, + 0x8fe7, 0x8fe8, 0x8fe9, 0x8fea, 0x8feb, 0x8fec, 0x8fed, 0x8fee, + 0x8fef, 0x8ff0, 0x8ff1, 0x8ff2, 0x8ff3, 0x8ff4, 0x8ff5, 0x8ff6, + 0x8ff7, 0x8ff8, 0x8ff9, 0x8ffa, 0x8ffb, 0x8ffc, 0x8ffd, 0x8ffe, + 0x9040, 0x9041, 0x9042, 0x9043, 0x9044, 0x9045, 0x9046, 0x9047, + 0x9048, 0x9049, 0x904a, 0x904b, 0x904c, 0x904d, 0x904e, 0x904f, + 0x9050, 0x9051, 0x9052, 0x9053, 0x9054, 0x9055, 0x9056, 0x9057, + 0x9058, 0x9059, 0x905a, 0x905b, 0x905c, 0x905d, 0x905e, 0x905f, + 0x9060, 0x9061, 0x9062, 0x9063, 0x9064, 0x9065, 0x9066, 0x9067, + 0x9068, 0x9069, 0x906a, 0x906b, 0x906c, 0x906d, 0x906e, 0x906f, + 0x9070, 0x9071, 0x9072, 0x9073, 0x9074, 0x9075, 0x9076, 0x9077, + 0x9078, 0x9079, 0x907a, 0x907b, 0x907c, 0x907d, 0x907e, 0x9080, + 0x9081, 0x9082, 0x9083, 0x9084, 0x9085, 0x9086, 0x9087, 0x9088, + 0x9089, 0x908a, 0x908b, 0x908c, 0x908d, 0x908e, 0x908f, 0x9090, + 0x9091, 0x9092, 0x9093, 0x9094, 0x9095, 0x9096, 0x9097, 0x9098, + 0x9099, 0x909a, 0x909b, 0x909c, 0x909d, 0x909e, 0x909f, 0x90a0, + 0x90a1, 0x90a2, 0x90a3, 0x90a4, 0x90a5, 0x90a6, 0x90a7, 0x90a8, + 0x90a9, 0x90aa, 0x90ab, 0x90ac, 0x90ad, 0x90ae, 0x90af, 0x90b0, + 0x90b1, 0x90b2, 0x90b3, 0x90b4, 0x90b5, 0x90b6, 0x90b7, 0x90b8, + 0x90b9, 0x90ba, 0x90bb, 0x90bc, 0x90bd, 0x90be, 0x90bf, 0x90c0, + 0x90c1, 0x90c2, 0x90c3, 0x90c4, 0x90c5, 0x90c6, 0x90c7, 0x90c8, + 0x90c9, 0x90ca, 0x90cb, 0x90cc, 0x90cd, 0x90ce, 0x90cf, 0x90d0, + 0x90d1, 0x90d2, 0x90d3, 0x90d4, 0x90d5, 0x90d6, 0x90d7, 0x90d8, + 0x90d9, 0x90da, 0x90db, 0x90dc, 0x90dd, 0x90de, 0x90df, 0x90e0, + 0x90e1, 0x90e2, 0x90e3, 0x90e4, 0x90e5, 0x90e6, 0x90e7, 0x90e8, + 0x90e9, 0x90ea, 0x90eb, 0x90ec, 0x90ed, 0x90ee, 0x90ef, 0x90f0, + 0x90f1, 0x90f2, 0x90f3, 0x90f4, 0x90f5, 0x90f6, 0x90f7, 0x90f8, + 0x90f9, 0x90fa, 0x90fb, 0x90fc, 0x90fd, 0x90fe, 0x9140, 0x9141, + 0x9142, 0x9143, 0x9144, 0x9145, 0x9146, 0x9147, 0x9148, 0x9149, + 0x914a, 0x914b, 0x914c, 0x914d, 0x914e, 0x914f, 0x9150, 0x9151, + 0x9152, 0x9153, 0x9154, 0x9155, 0x9156, 0x9157, 0x9158, 0x9159, + 0x915a, 0x915b, 0x915c, 0x915d, 0x915e, 0x915f, 0x9160, 0x9161, + 0x9162, 0x9163, 0x9164, 0x9165, 0x9166, 0x9167, 0x9168, 0x9169, + 0x916a, 0x916b, 0x916c, 0x916d, 0x916e, 0x916f, 0x9170, 0x9171, + 0x9172, 0x9173, 0x9174, 0x9175, 0x9176, 0x9177, 0x9178, 0x9179, + 0x917a, 0x917b, 0x917c, 0x917d, 0x917e, 0x9180, 0x9181, 0x9182, + 0x9183, 0x9184, 0x9185, 0x9186, 0x9187, 0x9188, 0x9189, 0x918a, + 0x918b, 0x918c, 0x918d, 0x918e, 0x918f, 0x9190, 0x9191, 0x9192, + 0x9193, 0x9194, 0x9195, 0x9196, 0x9197, 0x9198, 0x9199, 0x919a, + 0x919b, 0x919c, 0x919d, 0x919e, 0x919f, 0x91a0, 0x91a1, 0x91a2, + 0x91a3, 0x91a4, 0x91a5, 0x91a6, 0x91a7, 0x91a8, 0x91a9, 0x91aa, + 0x91ab, 0x91ac, 0x91ad, 0x91ae, 0x91af, 0x91b0, 0x91b1, 0x91b2, + 0x91b3, 0x91b4, 0x91b5, 0x91b6, 0x91b7, 0x91b8, 0x91b9, 0x91ba, + 0x91bb, 0x91bc, 0x91bd, 0x91be, 0x91bf, 0x91c0, 0x91c1, 0x91c2, + 0x91c3, 0x91c4, 0x91c5, 0x91c6, 0x91c7, 0x91c8, 0x91c9, 0x91ca, + 0x91cb, 0x91cc, 0x91cd, 0x91ce, 0x91cf, 0x91d0, 0x91d1, 0x91d2, + 0x91d3, 0x91d4, 0x91d5, 0x91d6, 0x91d7, 0x91d8, 0x91d9, 0x91da, + 0x91db, 0x91dc, 0x91dd, 0x91de, 0x91df, 0x91e0, 0x91e1, 0x91e2, + 0x91e3, 0x91e4, 0x91e5, 0x91e6, 0x91e7, 0x91e8, 0x91e9, 0x91ea, + 0x91eb, 0x91ec, 0x91ed, 0x91ee, 0x91ef, 0x91f0, 0x91f1, 0x91f2, + 0x91f3, 0x91f4, 0x91f5, 0x91f6, 0x91f7, 0x91f8, 0x91f9, 0x91fa, + 0x91fb, 0x91fc, 0x91fd, 0x91fe, 0x9240, 0x9241, 0x9242, 0x9243, + 0x9244, 0x9245, 0x9246, 0x9247, 0x9248, 0x9249, 0x924a, 0x924b, + 0x924c, 0x924d, 0x924e, 0x924f, 0x9250, 0x9251, 0x9252, 0x9253, + 0x9254, 0x9255, 0x9256, 0x9257, 0x9258, 0x9259, 0x925a, 0x925b, + 0x925c, 0x925d, 0x925e, 0x925f, 0x9260, 0x9261, 0x9262, 0x9263, + 0x9264, 0x9265, 0x9266, 0x9267, 0x9268, 0x9269, 0x926a, 0x926b, + 0x926c, 0x926d, 0x926e, 0x926f, 0x9270, 0x9271, 0x9272, 0x9273, + 0x9274, 0x9275, 0x9276, 0x9277, 0x9278, 0x9279, 0x927a, 0x927b, + 0x927c, 0x927d, 0x927e, 0x9280, 0x9281, 0x9282, 0x9283, 0x9284, + 0x9285, 0x9286, 0x9287, 0x9288, 0x9289, 0x928a, 0x928b, 0x928c, + 0x928d, 0x928e, 0x928f, 0x9290, 0x9291, 0x9292, 0x9293, 0x9294, + 0x9295, 0x9296, 0x9297, 0x9298, 0x9299, 0x929a, 0x929b, 0x929c, + 0x929d, 0x929e, 0x929f, 0x92a0, 0x92a1, 0x92a2, 0x92a3, 0x92a4, + 0x92a5, 0x92a6, 0x92a7, 0x92a8, 0x92a9, 0x92aa, 0x92ab, 0x92ac, + 0x92ad, 0x92ae, 0x92af, 0x92b0, 0x92b1, 0x92b2, 0x92b3, 0x92b4, + 0x92b5, 0x92b6, 0x92b7, 0x92b8, 0x92b9, 0x92ba, 0x92bb, 0x92bc, + 0x92bd, 0x92be, 0x92bf, 0x92c0, 0x92c1, 0x92c2, 0x92c3, 0x92c4, + 0x92c5, 0x92c6, 0x92c7, 0x92c8, 0x92c9, 0x92ca, 0x92cb, 0x92cc, + 0x92cd, 0x92ce, 0x92cf, 0x92d0, 0x92d1, 0x92d2, 0x92d3, 0x92d4, + 0x92d5, 0x92d6, 0x92d7, 0x92d8, 0x92d9, 0x92da, 0x92db, 0x92dc, + 0x92dd, 0x92de, 0x92df, 0x92e0, 0x92e1, 0x92e2, 0x92e3, 0x92e4, + 0x92e5, 0x92e6, 0x92e7, 0x92e8, 0x92e9, 0x92ea, 0x92eb, 0x92ec, + 0x92ed, 0x92ee, 0x92ef, 0x92f0, 0x92f1, 0x92f2, 0x92f3, 0x92f4, + 0x92f5, 0x92f6, 0x92f7, 0x92f8, 0x92f9, 0x92fa, 0x92fb, 0x92fc, + 0x92fd, 0x92fe, 0x9340, 0x9341, 0x9342, 0x9343, 0x9344, 0x9345, + 0x9346, 0x9347, 0x9348, 0x9349, 0x934a, 0x934b, 0x934c, 0x934d, + 0x934e, 0x934f, 0x9350, 0x9351, 0x9352, 0x9353, 0x9354, 0x9355, + 0x9356, 0x9357, 0x9358, 0x9359, 0x935a, 0x935b, 0x935c, 0x935d, + 0x935e, 0x935f, 0x9360, 0x9361, 0x9362, 0x9363, 0x9364, 0x9365, + 0x9366, 0x9367, 0x9368, 0x9369, 0x936a, 0x936b, 0x936c, 0x936d, + 0x936e, 0x936f, 0x9370, 0x9371, 0x9372, 0x9373, 0x9374, 0x9375, + 0x9376, 0x9377, 0x9378, 0x9379, 0x937a, 0x937b, 0x937c, 0x937d, + 0x937e, 0x9380, 0x9381, 0x9382, 0x9383, 0x9384, 0x9385, 0x9386, + 0x9387, 0x9388, 0x9389, 0x938a, 0x938b, 0x938c, 0x938d, 0x938e, + 0x938f, 0x9390, 0x9391, 0x9392, 0x9393, 0x9394, 0x9395, 0x9396, + 0x9397, 0x9398, 0x9399, 0x939a, 0x939b, 0x939c, 0x939d, 0x939e, + 0x939f, 0x93a0, 0x93a1, 0x93a2, 0x93a3, 0x93a4, 0x93a5, 0x93a6, + 0x93a7, 0x93a8, 0x93a9, 0x93aa, 0x93ab, 0x93ac, 0x93ad, 0x93ae, + 0x93af, 0x93b0, 0x93b1, 0x93b2, 0x93b3, 0x93b4, 0x93b5, 0x93b6, + 0x93b7, 0x93b8, 0x93b9, 0x93ba, 0x93bb, 0x93bc, 0x93bd, 0x93be, + 0x93bf, 0x93c0, 0x93c1, 0x93c2, 0x93c3, 0x93c4, 0x93c5, 0x93c6, + 0x93c7, 0x93c8, 0x93c9, 0x93ca, 0x93cb, 0x93cc, 0x93cd, 0x93ce, + 0x93cf, 0x93d0, 0x93d1, 0x93d2, 0x93d3, 0x93d4, 0x93d5, 0x93d6, + 0x93d7, 0x93d8, 0x93d9, 0x93da, 0x93db, 0x93dc, 0x93dd, 0x93de, + 0x93df, 0x93e0, 0x93e1, 0x93e2, 0x93e3, 0x93e4, 0x93e5, 0x93e6, + 0x93e7, 0x93e8, 0x93e9, 0x93ea, 0x93eb, 0x93ec, 0x93ed, 0x93ee, + 0x93ef, 0x93f0, 0x93f1, 0x93f2, 0x93f3, 0x93f4, 0x93f5, 0x93f6, + 0x93f7, 0x93f8, 0x93f9, 0x93fa, 0x93fb, 0x93fc, 0x93fd, 0x93fe, + 0x9440, 0x9441, 0x9442, 0x9443, 0x9444, 0x9445, 0x9446, 0x9447, + 0x9448, 0x9449, 0x944a, 0x944b, 0x944c, 0x944d, 0x944e, 0x944f, + 0x9450, 0x9451, 0x9452, 0x9453, 0x9454, 0x9455, 0x9456, 0x9457, + 0x9458, 0x9459, 0x945a, 0x945b, 0x945c, 0x945d, 0x945e, 0x945f, + 0x9460, 0x9461, 0x9462, 0x9463, 0x9464, 0x9465, 0x9466, 0x9467, + 0x9468, 0x9469, 0x946a, 0x946b, 0x946c, 0x946d, 0x946e, 0x946f, + 0x9470, 0x9471, 0x9472, 0x9473, 0x9474, 0x9475, 0x9476, 0x9477, + 0x9478, 0x9479, 0x947a, 0x947b, 0x947c, 0x947d, 0x947e, 0x9480, + 0x9481, 0x9482, 0x9483, 0x9484, 0x9485, 0x9486, 0x9487, 0x9488, + 0x9489, 0x948a, 0x948b, 0x948c, 0x948d, 0x948e, 0x948f, 0x9490, + 0x9491, 0x9492, 0x9493, 0x9494, 0x9495, 0x9496, 0x9497, 0x9498, + 0x9499, 0x949a, 0x949b, 0x949c, 0x949d, 0x949e, 0x949f, 0x94a0, + 0x94a1, 0x94a2, 0x94a3, 0x94a4, 0x94a5, 0x94a6, 0x94a7, 0x94a8, + 0x94a9, 0x94aa, 0x94ab, 0x94ac, 0x94ad, 0x94ae, 0x94af, 0x94b0, + 0x94b1, 0x94b2, 0x94b3, 0x94b4, 0x94b5, 0x94b6, 0x94b7, 0x94b8, + 0x94b9, 0x94ba, 0x94bb, 0x94bc, 0x94bd, 0x94be, 0x94bf, 0x94c0, + 0x94c1, 0x94c2, 0x94c3, 0x94c4, 0x94c5, 0x94c6, 0x94c7, 0x94c8, + 0x94c9, 0x94ca, 0x94cb, 0x94cc, 0x94cd, 0x94ce, 0x94cf, 0x94d0, + 0x94d1, 0x94d2, 0x94d3, 0x94d4, 0x94d5, 0x94d6, 0x94d7, 0x94d8, + 0x94d9, 0x94da, 0x94db, 0x94dc, 0x94dd, 0x94de, 0x94df, 0x94e0, + 0x94e1, 0x94e2, 0x94e3, 0x94e4, 0x94e5, 0x94e6, 0x94e7, 0x94e8, + 0x94e9, 0x94ea, 0x94eb, 0x94ec, 0x94ed, 0x94ee, 0x94ef, 0x94f0, + 0x94f1, 0x94f2, 0x94f3, 0x94f4, 0x94f5, 0x94f6, 0x94f7, 0x94f8, + 0x94f9, 0x94fa, 0x94fb, 0x94fc, 0x94fd, 0x94fe, 0x9540, 0x9541, + 0x9542, 0x9543, 0x9544, 0x9545, 0x9546, 0x9547, 0x9548, 0x9549, + 0x954a, 0x954b, 0x954c, 0x954d, 0x954e, 0x954f, 0x9550, 0x9551, + 0x9552, 0x9553, 0x9554, 0x9555, 0x9556, 0x9557, 0x9558, 0x9559, + 0x955a, 0x955b, 0x955c, 0x955d, 0x955e, 0x955f, 0x9560, 0x9561, + 0x9562, 0x9563, 0x9564, 0x9565, 0x9566, 0x9567, 0x9568, 0x9569, + 0x956a, 0x956b, 0x956c, 0x956d, 0x956e, 0x956f, 0x9570, 0x9571, + 0x9572, 0x9573, 0x9574, 0x9575, 0x9576, 0x9577, 0x9578, 0x9579, + 0x957a, 0x957b, 0x957c, 0x957d, 0x957e, 0x9580, 0x9581, 0x9582, + 0x9583, 0x9584, 0x9585, 0x9586, 0x9587, 0x9588, 0x9589, 0x958a, + 0x958b, 0x958c, 0x958d, 0x958e, 0x958f, 0x9590, 0x9591, 0x9592, + 0x9593, 0x9594, 0x9595, 0x9596, 0x9597, 0x9598, 0x9599, 0x959a, + 0x959b, 0x959c, 0x959d, 0x959e, 0x959f, 0x95a0, 0x95a1, 0x95a2, + 0x95a3, 0x95a4, 0x95a5, 0x95a6, 0x95a7, 0x95a8, 0x95a9, 0x95aa, + 0x95ab, 0x95ac, 0x95ad, 0x95ae, 0x95af, 0x95b0, 0x95b1, 0x95b2, + 0x95b3, 0x95b4, 0x95b5, 0x95b6, 0x95b7, 0x95b8, 0x95b9, 0x95ba, + 0x95bb, 0x95bc, 0x95bd, 0x95be, 0x95bf, 0x95c0, 0x95c1, 0x95c2, + 0x95c3, 0x95c4, 0x95c5, 0x95c6, 0x95c7, 0x95c8, 0x95c9, 0x95ca, + 0x95cb, 0x95cc, 0x95cd, 0x95ce, 0x95cf, 0x95d0, 0x95d1, 0x95d2, + 0x95d3, 0x95d4, 0x95d5, 0x95d6, 0x95d7, 0x95d8, 0x95d9, 0x95da, + 0x95db, 0x95dc, 0x95dd, 0x95de, 0x95df, 0x95e0, 0x95e1, 0x95e2, + 0x95e3, 0x95e4, 0x95e5, 0x95e6, 0x95e7, 0x95e8, 0x95e9, 0x95ea, + 0x95eb, 0x95ec, 0x95ed, 0x95ee, 0x95ef, 0x95f0, 0x95f1, 0x95f2, + 0x95f3, 0x95f4, 0x95f5, 0x95f6, 0x95f7, 0x95f8, 0x95f9, 0x95fa, + 0x95fb, 0x95fc, 0x95fd, 0x95fe, 0x9640, 0x9641, 0x9642, 0x9643, + 0x9644, 0x9645, 0x9646, 0x9647, 0x9648, 0x9649, 0x964a, 0x964b, + 0x964c, 0x964d, 0x964e, 0x964f, 0x9650, 0x9651, 0x9652, 0x9653, + 0x9654, 0x9655, 0x9656, 0x9657, 0x9658, 0x9659, 0x965a, 0x965b, + 0x965c, 0x965d, 0x965e, 0x965f, 0x9660, 0x9661, 0x9662, 0x9663, + 0x9664, 0x9665, 0x9666, 0x9667, 0x9668, 0x9669, 0x966a, 0x966b, + 0x966c, 0x966d, 0x966e, 0x966f, 0x9670, 0x9671, 0x9672, 0x9673, + 0x9674, 0x9675, 0x9676, 0x9677, 0x9678, 0x9679, 0x967a, 0x967b, + 0x967c, 0x967d, 0x967e, 0x9680, 0x9681, 0x9682, 0x9683, 0x9684, + 0x9685, 0x9686, 0x9687, 0x9688, 0x9689, 0x968a, 0x968b, 0x968c, + 0x968d, 0x968e, 0x968f, 0x9690, 0x9691, 0x9692, 0x9693, 0x9694, + 0x9695, 0x9696, 0x9697, 0x9698, 0x9699, 0x969a, 0x969b, 0x969c, + 0x969d, 0x969e, 0x969f, 0x96a0, 0x96a1, 0x96a2, 0x96a3, 0x96a4, + 0x96a5, 0x96a6, 0x96a7, 0x96a8, 0x96a9, 0x96aa, 0x96ab, 0x96ac, + 0x96ad, 0x96ae, 0x96af, 0x96b0, 0x96b1, 0x96b2, 0x96b3, 0x96b4, + 0x96b5, 0x96b6, 0x96b7, 0x96b8, 0x96b9, 0x96ba, 0x96bb, 0x96bc, + 0x96bd, 0x96be, 0x96bf, 0x96c0, 0x96c1, 0x96c2, 0x96c3, 0x96c4, + 0x96c5, 0x96c6, 0x96c7, 0x96c8, 0x96c9, 0x96ca, 0x96cb, 0x96cc, + 0x96cd, 0x96ce, 0x96cf, 0x96d0, 0x96d1, 0x96d2, 0x96d3, 0x96d4, + 0x96d5, 0x96d6, 0x96d7, 0x96d8, 0x96d9, 0x96da, 0x96db, 0x96dc, + 0x96dd, 0x96de, 0x96df, 0x96e0, 0x96e1, 0x96e2, 0x96e3, 0x96e4, + 0x96e5, 0x96e6, 0x96e7, 0x96e8, 0x96e9, 0x96ea, 0x96eb, 0x96ec, + 0x96ed, 0x96ee, 0x96ef, 0x96f0, 0x96f1, 0x96f2, 0x96f3, 0x96f4, + 0x96f5, 0x96f6, 0x96f7, 0x96f8, 0x96f9, 0x96fa, 0x96fb, 0x96fc, + 0x96fd, 0x96fe, 0x9740, 0x9741, 0x9742, 0x9743, 0x9744, 0x9745, + 0x9746, 0x9747, 0x9748, 0x9749, 0x974a, 0x974b, 0x974c, 0x974d, + 0x974e, 0x974f, 0x9750, 0x9751, 0x9752, 0x9753, 0x9754, 0x9755, + 0x9756, 0x9757, 0x9758, 0x9759, 0x975a, 0x975b, 0x975c, 0x975d, + 0x975e, 0x975f, 0x9760, 0x9761, 0x9762, 0x9763, 0x9764, 0x9765, + 0x9766, 0x9767, 0x9768, 0x9769, 0x976a, 0x976b, 0x976c, 0x976d, + 0x976e, 0x976f, 0x9770, 0x9771, 0x9772, 0x9773, 0x9774, 0x9775, + 0x9776, 0x9777, 0x9778, 0x9779, 0x977a, 0x977b, 0x977c, 0x977d, + 0x977e, 0x9780, 0x9781, 0x9782, 0x9783, 0x9784, 0x9785, 0x9786, + 0x9787, 0x9788, 0x9789, 0x978a, 0x978b, 0x978c, 0x978d, 0x978e, + 0x978f, 0x9790, 0x9791, 0x9792, 0x9793, 0x9794, 0x9795, 0x9796, + 0x9797, 0x9798, 0x9799, 0x979a, 0x979b, 0x979c, 0x979d, 0x979e, + 0x979f, 0x97a0, 0x97a1, 0x97a2, 0x97a3, 0x97a4, 0x97a5, 0x97a6, + 0x97a7, 0x97a8, 0x97a9, 0x97aa, 0x97ab, 0x97ac, 0x97ad, 0x97ae, + 0x97af, 0x97b0, 0x97b1, 0x97b2, 0x97b3, 0x97b4, 0x97b5, 0x97b6, + 0x97b7, 0x97b8, 0x97b9, 0x97ba, 0x97bb, 0x97bc, 0x97bd, 0x97be, + 0x97bf, 0x97c0, 0x97c1, 0x97c2, 0x97c3, 0x97c4, 0x97c5, 0x97c6, + 0x97c7, 0x97c8, 0x97c9, 0x97ca, 0x97cb, 0x97cc, 0x97cd, 0x97ce, + 0x97cf, 0x97d0, 0x97d1, 0x97d2, 0x97d3, 0x97d4, 0x97d5, 0x97d6, + 0x97d7, 0x97d8, 0x97d9, 0x97da, 0x97db, 0x97dc, 0x97dd, 0x97de, + 0x97df, 0x97e0, 0x97e1, 0x97e2, 0x97e3, 0x97e4, 0x97e5, 0x97e6, + 0x97e7, 0x97e8, 0x97e9, 0x97ea, 0x97eb, 0x97ec, 0x97ed, 0x97ee, + 0x97ef, 0x97f0, 0x97f1, 0x97f2, 0x97f3, 0x97f4, 0x97f5, 0x97f6, + 0x97f7, 0x97f8, 0x97f9, 0x97fa, 0x97fb, 0x97fc, 0x97fd, 0x97fe, + 0x9840, 0x9841, 0x9842, 0x9843, 0x9844, 0x9845, 0x9846, 0x9847, + 0x9848, 0x9849, 0x984a, 0x984b, 0x984c, 0x984d, 0x984e, 0x984f, + 0x9850, 0x9851, 0x9852, 0x9853, 0x9854, 0x9855, 0x9856, 0x9857, + 0x9858, 0x9859, 0x985a, 0x985b, 0x985c, 0x985d, 0x985e, 0x985f, + 0x9860, 0x9861, 0x9862, 0x9863, 0x9864, 0x9865, 0x9866, 0x9867, + 0x9868, 0x9869, 0x986a, 0x986b, 0x986c, 0x986d, 0x986e, 0x986f, + 0x9870, 0x9871, 0x9872, 0x9873, 0x9874, 0x9875, 0x9876, 0x9877, + 0x9878, 0x9879, 0x987a, 0x987b, 0x987c, 0x987d, 0x987e, 0x9880, + 0x9881, 0x9882, 0x9883, 0x9884, 0x9885, 0x9886, 0x9887, 0x9888, + 0x9889, 0x988a, 0x988b, 0x988c, 0x988d, 0x988e, 0x988f, 0x9890, + 0x9891, 0x9892, 0x9893, 0x9894, 0x9895, 0x9896, 0x9897, 0x9898, + 0x9899, 0x989a, 0x989b, 0x989c, 0x989d, 0x989e, 0x989f, 0x98a0, + 0x98a1, 0x98a2, 0x98a3, 0x98a4, 0x98a5, 0x98a6, 0x98a7, 0x98a8, + 0x98a9, 0x98aa, 0x98ab, 0x98ac, 0x98ad, 0x98ae, 0x98af, 0x98b0, + 0x98b1, 0x98b2, 0x98b3, 0x98b4, 0x98b5, 0x98b6, 0x98b7, 0x98b8, + 0x98b9, 0x98ba, 0x98bb, 0x98bc, 0x98bd, 0x98be, 0x98bf, 0x98c0, + 0x98c1, 0x98c2, 0x98c3, 0x98c4, 0x98c5, 0x98c6, 0x98c7, 0x98c8, + 0x98c9, 0x98ca, 0x98cb, 0x98cc, 0x98cd, 0x98ce, 0x98cf, 0x98d0, + 0x98d1, 0x98d2, 0x98d3, 0x98d4, 0x98d5, 0x98d6, 0x98d7, 0x98d8, + 0x98d9, 0x98da, 0x98db, 0x98dc, 0x98dd, 0x98de, 0x98df, 0x98e0, + 0x98e1, 0x98e2, 0x98e3, 0x98e4, 0x98e5, 0x98e6, 0x98e7, 0x98e8, + 0x98e9, 0x98ea, 0x98eb, 0x98ec, 0x98ed, 0x98ee, 0x98ef, 0x98f0, + 0x98f1, 0x98f2, 0x98f3, 0x98f4, 0x98f5, 0x98f6, 0x98f7, 0x98f8, + 0x98f9, 0x98fa, 0x98fb, 0x98fc, 0x98fd, 0x98fe, 0x9940, 0x9941, + 0x9942, 0x9943, 0x9944, 0x9945, 0x9946, 0x9947, 0x9948, 0x9949, + 0x994a, 0x994b, 0x994c, 0x994d, 0x994e, 0x994f, 0x9950, 0x9951, + 0x9952, 0x9953, 0x9954, 0x9955, 0x9956, 0x9957, 0x9958, 0x9959, + 0x995a, 0x995b, 0x995c, 0x995d, 0x995e, 0x995f, 0x9960, 0x9961, + 0x9962, 0x9963, 0x9964, 0x9965, 0x9966, 0x9967, 0x9968, 0x9969, + 0x996a, 0x996b, 0x996c, 0x996d, 0x996e, 0x996f, 0x9970, 0x9971, + 0x9972, 0x9973, 0x9974, 0x9975, 0x9976, 0x9977, 0x9978, 0x9979, + 0x997a, 0x997b, 0x997c, 0x997d, 0x997e, 0x9980, 0x9981, 0x9982, + 0x9983, 0x9984, 0x9985, 0x9986, 0x9987, 0x9988, 0x9989, 0x998a, + 0x998b, 0x998c, 0x998d, 0x998e, 0x998f, 0x9990, 0x9991, 0x9992, + 0x9993, 0x9994, 0x9995, 0x9996, 0x9997, 0x9998, 0x9999, 0x999a, + 0x999b, 0x999c, 0x999d, 0x999e, 0x999f, 0x99a0, 0x99a1, 0x99a2, + 0x99a3, 0x99a4, 0x99a5, 0x99a6, 0x99a7, 0x99a8, 0x99a9, 0x99aa, + 0x99ab, 0x99ac, 0x99ad, 0x99ae, 0x99af, 0x99b0, 0x99b1, 0x99b2, + 0x99b3, 0x99b4, 0x99b5, 0x99b6, 0x99b7, 0x99b8, 0x99b9, 0x99ba, + 0x99bb, 0x99bc, 0x99bd, 0x99be, 0x99bf, 0x99c0, 0x99c1, 0x99c2, + 0x99c3, 0x99c4, 0x99c5, 0x99c6, 0x99c7, 0x99c8, 0x99c9, 0x99ca, + 0x99cb, 0x99cc, 0x99cd, 0x99ce, 0x99cf, 0x99d0, 0x99d1, 0x99d2, + 0x99d3, 0x99d4, 0x99d5, 0x99d6, 0x99d7, 0x99d8, 0x99d9, 0x99da, + 0x99db, 0x99dc, 0x99dd, 0x99de, 0x99df, 0x99e0, 0x99e1, 0x99e2, + 0x99e3, 0x99e4, 0x99e5, 0x99e6, 0x99e7, 0x99e8, 0x99e9, 0x99ea, + 0x99eb, 0x99ec, 0x99ed, 0x99ee, 0x99ef, 0x99f0, 0x99f1, 0x99f2, + 0x99f3, 0x99f4, 0x99f5, 0x99f6, 0x99f7, 0x99f8, 0x99f9, 0x99fa, + 0x99fb, 0x99fc, 0x99fd, 0x99fe, 0x9a40, 0x9a41, 0x9a42, 0x9a43, + 0x9a44, 0x9a45, 0x9a46, 0x9a47, 0x9a48, 0x9a49, 0x9a4a, 0x9a4b, + 0x9a4c, 0x9a4d, 0x9a4e, 0x9a4f, 0x9a50, 0x9a51, 0x9a52, 0x9a53, + 0x9a54, 0x9a55, 0x9a56, 0x9a57, 0x9a58, 0x9a59, 0x9a5a, 0x9a5b, + 0x9a5c, 0x9a5d, 0x9a5e, 0x9a5f, 0x9a60, 0x9a61, 0x9a62, 0x9a63, + 0x9a64, 0x9a65, 0x9a66, 0x9a67, 0x9a68, 0x9a69, 0x9a6a, 0x9a6b, + 0x9a6c, 0x9a6d, 0x9a6e, 0x9a6f, 0x9a70, 0x9a71, 0x9a72, 0x9a73, + 0x9a74, 0x9a75, 0x9a76, 0x9a77, 0x9a78, 0x9a79, 0x9a7a, 0x9a7b, + 0x9a7c, 0x9a7d, 0x9a7e, 0x9a80, 0x9a81, 0x9a82, 0x9a83, 0x9a84, + 0x9a85, 0x9a86, 0x9a87, 0x9a88, 0x9a89, 0x9a8a, 0x9a8b, 0x9a8c, + 0x9a8d, 0x9a8e, 0x9a8f, 0x9a90, 0x9a91, 0x9a92, 0x9a93, 0x9a94, + 0x9a95, 0x9a96, 0x9a97, 0x9a98, 0x9a99, 0x9a9a, 0x9a9b, 0x9a9c, + 0x9a9d, 0x9a9e, 0x9a9f, 0x9aa0, 0x9aa1, 0x9aa2, 0x9aa3, 0x9aa4, + 0x9aa5, 0x9aa6, 0x9aa7, 0x9aa8, 0x9aa9, 0x9aaa, 0x9aab, 0x9aac, + 0x9aad, 0x9aae, 0x9aaf, 0x9ab0, 0x9ab1, 0x9ab2, 0x9ab3, 0x9ab4, + 0x9ab5, 0x9ab6, 0x9ab7, 0x9ab8, 0x9ab9, 0x9aba, 0x9abb, 0x9abc, + 0x9abd, 0x9abe, 0x9abf, 0x9ac0, 0x9ac1, 0x9ac2, 0x9ac3, 0x9ac4, + 0x9ac5, 0x9ac6, 0x9ac7, 0x9ac8, 0x9ac9, 0x9aca, 0x9acb, 0x9acc, + 0x9acd, 0x9ace, 0x9acf, 0x9ad0, 0x9ad1, 0x9ad2, 0x9ad3, 0x9ad4, + 0x9ad5, 0x9ad6, 0x9ad7, 0x9ad8, 0x9ad9, 0x9ada, 0x9adb, 0x9adc, + 0x9add, 0x9ade, 0x9adf, 0x9ae0, 0x9ae1, 0x9ae2, 0x9ae3, 0x9ae4, + 0x9ae5, 0x9ae6, 0x9ae7, 0x9ae8, 0x9ae9, 0x9aea, 0x9aeb, 0x9aec, + 0x9aed, 0x9aee, 0x9aef, 0x9af0, 0x9af1, 0x9af2, 0x9af3, 0x9af4, + 0x9af5, 0x9af6, 0x9af7, 0x9af8, 0x9af9, 0x9afa, 0x9afb, 0x9afc, + 0x9afd, 0x9afe, 0x9b40, 0x9b41, 0x9b42, 0x9b43, 0x9b44, 0x9b45, + 0x9b46, 0x9b47, 0x9b48, 0x9b49, 0x9b4a, 0x9b4b, 0x9b4c, 0x9b4d, + 0x9b4e, 0x9b4f, 0x9b50, 0x9b51, 0x9b52, 0x9b53, 0x9b54, 0x9b55, + 0x9b56, 0x9b57, 0x9b58, 0x9b59, 0x9b5a, 0x9b5b, 0x9b5c, 0x9b5d, + 0x9b5e, 0x9b5f, 0x9b60, 0x9b61, 0x9b62, 0x9b63, 0x9b64, 0x9b65, + 0x9b66, 0x9b67, 0x9b68, 0x9b69, 0x9b6a, 0x9b6b, 0x9b6c, 0x9b6d, + 0x9b6e, 0x9b6f, 0x9b70, 0x9b71, 0x9b72, 0x9b73, 0x9b74, 0x9b75, + 0x9b76, 0x9b77, 0x9b78, 0x9b79, 0x9b7a, 0x9b7b, 0x9b7c, 0x9b7d, + 0x9b7e, 0x9b80, 0x9b81, 0x9b82, 0x9b83, 0x9b84, 0x9b85, 0x9b86, + 0x9b87, 0x9b88, 0x9b89, 0x9b8a, 0x9b8b, 0x9b8c, 0x9b8d, 0x9b8e, + 0x9b8f, 0x9b90, 0x9b91, 0x9b92, 0x9b93, 0x9b94, 0x9b95, 0x9b96, + 0x9b97, 0x9b98, 0x9b99, 0x9b9a, 0x9b9b, 0x9b9c, 0x9b9d, 0x9b9e, + 0x9b9f, 0x9ba0, 0x9ba1, 0x9ba2, 0x9ba3, 0x9ba4, 0x9ba5, 0x9ba6, + 0x9ba7, 0x9ba8, 0x9ba9, 0x9baa, 0x9bab, 0x9bac, 0x9bad, 0x9bae, + 0x9baf, 0x9bb0, 0x9bb1, 0x9bb2, 0x9bb3, 0x9bb4, 0x9bb5, 0x9bb6, + 0x9bb7, 0x9bb8, 0x9bb9, 0x9bba, 0x9bbb, 0x9bbc, 0x9bbd, 0x9bbe, + 0x9bbf, 0x9bc0, 0x9bc1, 0x9bc2, 0x9bc3, 0x9bc4, 0x9bc5, 0x9bc6, + 0x9bc7, 0x9bc8, 0x9bc9, 0x9bca, 0x9bcb, 0x9bcc, 0x9bcd, 0x9bce, + 0x9bcf, 0x9bd0, 0x9bd1, 0x9bd2, 0x9bd3, 0x9bd4, 0x9bd5, 0x9bd6, + 0x9bd7, 0x9bd8, 0x9bd9, 0x9bda, 0x9bdb, 0x9bdc, 0x9bdd, 0x9bde, + 0x9bdf, 0x9be0, 0x9be1, 0x9be2, 0x9be3, 0x9be4, 0x9be5, 0x9be6, + 0x9be7, 0x9be8, 0x9be9, 0x9bea, 0x9beb, 0x9bec, 0x9bed, 0x9bee, + 0x9bef, 0x9bf0, 0x9bf1, 0x9bf2, 0x9bf3, 0x9bf4, 0x9bf5, 0x9bf6, + 0x9bf7, 0x9bf8, 0x9bf9, 0x9bfa, 0x9bfb, 0x9bfc, 0x9bfd, 0x9bfe, + 0x9c40, 0x9c41, 0x9c42, 0x9c43, 0x9c44, 0x9c45, 0x9c46, 0x9c47, + 0x9c48, 0x9c49, 0x9c4a, 0x9c4b, 0x9c4c, 0x9c4d, 0x9c4e, 0x9c4f, + 0x9c50, 0x9c51, 0x9c52, 0x9c53, 0x9c54, 0x9c55, 0x9c56, 0x9c57, + 0x9c58, 0x9c59, 0x9c5a, 0x9c5b, 0x9c5c, 0x9c5d, 0x9c5e, 0x9c5f, + 0x9c60, 0x9c61, 0x9c62, 0x9c63, 0x9c64, 0x9c65, 0x9c66, 0x9c67, + 0x9c68, 0x9c69, 0x9c6a, 0x9c6b, 0x9c6c, 0x9c6d, 0x9c6e, 0x9c6f, + 0x9c70, 0x9c71, 0x9c72, 0x9c73, 0x9c74, 0x9c75, 0x9c76, 0x9c77, + 0x9c78, 0x9c79, 0x9c7a, 0x9c7b, 0x9c7c, 0x9c7d, 0x9c7e, 0x9c80, + 0x9c81, 0x9c82, 0x9c83, 0x9c84, 0x9c85, 0x9c86, 0x9c87, 0x9c88, + 0x9c89, 0x9c8a, 0x9c8b, 0x9c8c, 0x9c8d, 0x9c8e, 0x9c8f, 0x9c90, + 0x9c91, 0x9c92, 0x9c93, 0x9c94, 0x9c95, 0x9c96, 0x9c97, 0x9c98, + 0x9c99, 0x9c9a, 0x9c9b, 0x9c9c, 0x9c9d, 0x9c9e, 0x9c9f, 0x9ca0, + 0x9ca1, 0x9ca2, 0x9ca3, 0x9ca4, 0x9ca5, 0x9ca6, 0x9ca7, 0x9ca8, + 0x9ca9, 0x9caa, 0x9cab, 0x9cac, 0x9cad, 0x9cae, 0x9caf, 0x9cb0, + 0x9cb1, 0x9cb2, 0x9cb3, 0x9cb4, 0x9cb5, 0x9cb6, 0x9cb7, 0x9cb8, + 0x9cb9, 0x9cba, 0x9cbb, 0x9cbc, 0x9cbd, 0x9cbe, 0x9cbf, 0x9cc0, + 0x9cc1, 0x9cc2, 0x9cc3, 0x9cc4, 0x9cc5, 0x9cc6, 0x9cc7, 0x9cc8, + 0x9cc9, 0x9cca, 0x9ccb, 0x9ccc, 0x9ccd, 0x9cce, 0x9ccf, 0x9cd0, + 0x9cd1, 0x9cd2, 0x9cd3, 0x9cd4, 0x9cd5, 0x9cd6, 0x9cd7, 0x9cd8, + 0x9cd9, 0x9cda, 0x9cdb, 0x9cdc, 0x9cdd, 0x9cde, 0x9cdf, 0x9ce0, + 0x9ce1, 0x9ce2, 0x9ce3, 0x9ce4, 0x9ce5, 0x9ce6, 0x9ce7, 0x9ce8, + 0x9ce9, 0x9cea, 0x9ceb, 0x9cec, 0x9ced, 0x9cee, 0x9cef, 0x9cf0, + 0x9cf1, 0x9cf2, 0x9cf3, 0x9cf4, 0x9cf5, 0x9cf6, 0x9cf7, 0x9cf8, + 0x9cf9, 0x9cfa, 0x9cfb, 0x9cfc, 0x9cfd, 0x9cfe, 0x9d40, 0x9d41, + 0x9d42, 0x9d43, 0x9d44, 0x9d45, 0x9d46, 0x9d47, 0x9d48, 0x9d49, + 0x9d4a, 0x9d4b, 0x9d4c, 0x9d4d, 0x9d4e, 0x9d4f, 0x9d50, 0x9d51, + 0x9d52, 0x9d53, 0x9d54, 0x9d55, 0x9d56, 0x9d57, 0x9d58, 0x9d59, + 0x9d5a, 0x9d5b, 0x9d5c, 0x9d5d, 0x9d5e, 0x9d5f, 0x9d60, 0x9d61, + 0x9d62, 0x9d63, 0x9d64, 0x9d65, 0x9d66, 0x9d67, 0x9d68, 0x9d69, + 0x9d6a, 0x9d6b, 0x9d6c, 0x9d6d, 0x9d6e, 0x9d6f, 0x9d70, 0x9d71, + 0x9d72, 0x9d73, 0x9d74, 0x9d75, 0x9d76, 0x9d77, 0x9d78, 0x9d79, + 0x9d7a, 0x9d7b, 0x9d7c, 0x9d7d, 0x9d7e, 0x9d80, 0x9d81, 0x9d82, + 0x9d83, 0x9d84, 0x9d85, 0x9d86, 0x9d87, 0x9d88, 0x9d89, 0x9d8a, + 0x9d8b, 0x9d8c, 0x9d8d, 0x9d8e, 0x9d8f, 0x9d90, 0x9d91, 0x9d92, + 0x9d93, 0x9d94, 0x9d95, 0x9d96, 0x9d97, 0x9d98, 0x9d99, 0x9d9a, + 0x9d9b, 0x9d9c, 0x9d9d, 0x9d9e, 0x9d9f, 0x9da0, 0x9da1, 0x9da2, + 0x9da3, 0x9da4, 0x9da5, 0x9da6, 0x9da7, 0x9da8, 0x9da9, 0x9daa, + 0x9dab, 0x9dac, 0x9dad, 0x9dae, 0x9daf, 0x9db0, 0x9db1, 0x9db2, + 0x9db3, 0x9db4, 0x9db5, 0x9db6, 0x9db7, 0x9db8, 0x9db9, 0x9dba, + 0x9dbb, 0x9dbc, 0x9dbd, 0x9dbe, 0x9dbf, 0x9dc0, 0x9dc1, 0x9dc2, + 0x9dc3, 0x9dc4, 0x9dc5, 0x9dc6, 0x9dc7, 0x9dc8, 0x9dc9, 0x9dca, + 0x9dcb, 0x9dcc, 0x9dcd, 0x9dce, 0x9dcf, 0x9dd0, 0x9dd1, 0x9dd2, + 0x9dd3, 0x9dd4, 0x9dd5, 0x9dd6, 0x9dd7, 0x9dd8, 0x9dd9, 0x9dda, + 0x9ddb, 0x9ddc, 0x9ddd, 0x9dde, 0x9ddf, 0x9de0, 0x9de1, 0x9de2, + 0x9de3, 0x9de4, 0x9de5, 0x9de6, 0x9de7, 0x9de8, 0x9de9, 0x9dea, + 0x9deb, 0x9dec, 0x9ded, 0x9dee, 0x9def, 0x9df0, 0x9df1, 0x9df2, + 0x9df3, 0x9df4, 0x9df5, 0x9df6, 0x9df7, 0x9df8, 0x9df9, 0x9dfa, + 0x9dfb, 0x9dfc, 0x9dfd, 0x9dfe, 0x9e40, 0x9e41, 0x9e42, 0x9e43, + 0x9e44, 0x9e45, 0x9e46, 0x9e47, 0x9e48, 0x9e49, 0x9e4a, 0x9e4b, + 0x9e4c, 0x9e4d, 0x9e4e, 0x9e4f, 0x9e50, 0x9e51, 0x9e52, 0x9e53, + 0x9e54, 0x9e55, 0x9e56, 0x9e57, 0x9e58, 0x9e59, 0x9e5a, 0x9e5b, + 0x9e5c, 0x9e5d, 0x9e5e, 0x9e5f, 0x9e60, 0x9e61, 0x9e62, 0x9e63, + 0x9e64, 0x9e65, 0x9e66, 0x9e67, 0x9e68, 0x9e69, 0x9e6a, 0x9e6b, + 0x9e6c, 0x9e6d, 0x9e6e, 0x9e6f, 0x9e70, 0x9e71, 0x9e72, 0x9e73, + 0x9e74, 0x9e75, 0x9e76, 0x9e77, 0x9e78, 0x9e79, 0x9e7a, 0x9e7b, + 0x9e7c, 0x9e7d, 0x9e7e, 0x9e80, 0x9e81, 0x9e82, 0x9e83, 0x9e84, + 0x9e85, 0x9e86, 0x9e87, 0x9e88, 0x9e89, 0x9e8a, 0x9e8b, 0x9e8c, + 0x9e8d, 0x9e8e, 0x9e8f, 0x9e90, 0x9e91, 0x9e92, 0x9e93, 0x9e94, + 0x9e95, 0x9e96, 0x9e97, 0x9e98, 0x9e99, 0x9e9a, 0x9e9b, 0x9e9c, + 0x9e9d, 0x9e9e, 0x9e9f, 0x9ea0, 0x9ea1, 0x9ea2, 0x9ea3, 0x9ea4, + 0x9ea5, 0x9ea6, 0x9ea7, 0x9ea8, 0x9ea9, 0x9eaa, 0x9eab, 0x9eac, + 0x9ead, 0x9eae, 0x9eaf, 0x9eb0, 0x9eb1, 0x9eb2, 0x9eb3, 0x9eb4, + 0x9eb5, 0x9eb6, 0x9eb7, 0x9eb8, 0x9eb9, 0x9eba, 0x9ebb, 0x9ebc, + 0x9ebd, 0x9ebe, 0x9ebf, 0x9ec0, 0x9ec1, 0x9ec2, 0x9ec3, 0x9ec4, + 0x9ec5, 0x9ec6, 0x9ec7, 0x9ec8, 0x9ec9, 0x9eca, 0x9ecb, 0x9ecc, + 0x9ecd, 0x9ece, 0x9ecf, 0x9ed0, 0x9ed1, 0x9ed2, 0x9ed3, 0x9ed4, + 0x9ed5, 0x9ed6, 0x9ed7, 0x9ed8, 0x9ed9, 0x9eda, 0x9edb, 0x9edc, + 0x9edd, 0x9ede, 0x9edf, 0x9ee0, 0x9ee1, 0x9ee2, 0x9ee3, 0x9ee4, + 0x9ee5, 0x9ee6, 0x9ee7, 0x9ee8, 0x9ee9, 0x9eea, 0x9eeb, 0x9eec, + 0x9eed, 0x9eee, 0x9eef, 0x9ef0, 0x9ef1, 0x9ef2, 0x9ef3, 0x9ef4, + 0x9ef5, 0x9ef6, 0x9ef7, 0x9ef8, 0x9ef9, 0x9efa, 0x9efb, 0x9efc, + 0x9efd, 0x9efe, 0x9f40, 0x9f41, 0x9f42, 0x9f43, 0x9f44, 0x9f45, + 0x9f46, 0x9f47, 0x9f48, 0x9f49, 0x9f4a, 0x9f4b, 0x9f4c, 0x9f4d, + 0x9f4e, 0x9f4f, 0x9f50, 0x9f51, 0x9f52, 0x9f53, 0x9f54, 0x9f55, + 0x9f56, 0x9f57, 0x9f58, 0x9f59, 0x9f5a, 0x9f5b, 0x9f5c, 0x9f5d, + 0x9f5e, 0x9f5f, 0x9f60, 0x9f61, 0x9f62, 0x9f63, 0x9f64, 0x9f65, + 0x9f66, 0x9f67, 0x9f68, 0x9f69, 0x9f6a, 0x9f6b, 0x9f6c, 0x9f6d, + 0x9f6e, 0x9f6f, 0x9f70, 0x9f71, 0x9f72, 0x9f73, 0x9f74, 0x9f75, + 0x9f76, 0x9f77, 0x9f78, 0x9f79, 0x9f7a, 0x9f7b, 0x9f7c, 0x9f7d, + 0x9f7e, 0x9f80, 0x9f81, 0x9f82, 0x9f83, 0x9f84, 0x9f85, 0x9f86, + 0x9f87, 0x9f88, 0x9f89, 0x9f8a, 0x9f8b, 0x9f8c, 0x9f8d, 0x9f8e, + 0x9f8f, 0x9f90, 0x9f91, 0x9f92, 0x9f93, 0x9f94, 0x9f95, 0x9f96, + 0x9f97, 0x9f98, 0x9f99, 0x9f9a, 0x9f9b, 0x9f9c, 0x9f9d, 0x9f9e, + 0x9f9f, 0x9fa0, 0x9fa1, 0x9fa2, 0x9fa3, 0x9fa4, 0x9fa5, 0x9fa6, + 0x9fa7, 0x9fa8, 0x9fa9, 0x9faa, 0x9fab, 0x9fac, 0x9fad, 0x9fae, + 0x9faf, 0x9fb0, 0x9fb1, 0x9fb2, 0x9fb3, 0x9fb4, 0x9fb5, 0x9fb6, + 0x9fb7, 0x9fb8, 0x9fb9, 0x9fba, 0x9fbb, 0x9fbc, 0x9fbd, 0x9fbe, + 0x9fbf, 0x9fc0, 0x9fc1, 0x9fc2, 0x9fc3, 0x9fc4, 0x9fc5, 0x9fc6, + 0x9fc7, 0x9fc8, 0x9fc9, 0x9fca, 0x9fcb, 0x9fcc, 0x9fcd, 0x9fce, + 0x9fcf, 0x9fd0, 0x9fd1, 0x9fd2, 0x9fd3, 0x9fd4, 0x9fd5, 0x9fd6, + 0x9fd7, 0x9fd8, 0x9fd9, 0x9fda, 0x9fdb, 0x9fdc, 0x9fdd, 0x9fde, + 0x9fdf, 0x9fe0, 0x9fe1, 0x9fe2, 0x9fe3, 0x9fe4, 0x9fe5, 0x9fe6, + 0x9fe7, 0x9fe8, 0x9fe9, 0x9fea, 0x9feb, 0x9fec, 0x9fed, 0x9fee, + 0x9fef, 0x9ff0, 0x9ff1, 0x9ff2, 0x9ff3, 0x9ff4, 0x9ff5, 0x9ff6, + 0x9ff7, 0x9ff8, 0x9ff9, 0x9ffa, 0x9ffb, 0x9ffc, 0x9ffd, 0x9ffe, + 0xa040, 0xa041, 0xa042, 0xa043, 0xa044, 0xa045, 0xa046, 0xa047, + 0xa048, 0xa049, 0xa04a, 0xa04b, 0xa04c, 0xa04d, 0xa04e, 0xa04f, + 0xa050, 0xa051, 0xa052, 0xa053, 0xa054, 0xa055, 0xa056, 0xa057, + 0xa058, 0xa059, 0xa05a, 0xa05b, 0xa05c, 0xa05d, 0xa05e, 0xa05f, + 0xa060, 0xa061, 0xa062, 0xa063, 0xa064, 0xa065, 0xa066, 0xa067, + 0xa068, 0xa069, 0xa06a, 0xa06b, 0xa06c, 0xa06d, 0xa06e, 0xa06f, + 0xa070, 0xa071, 0xa072, 0xa073, 0xa074, 0xa075, 0xa076, 0xa077, + 0xa078, 0xa079, 0xa07a, 0xa07b, 0xa07c, 0xa07d, 0xa07e, 0xa080, + 0xa081, 0xa082, 0xa083, 0xa084, 0xa085, 0xa086, 0xa087, 0xa088, + 0xa089, 0xa08a, 0xa08b, 0xa08c, 0xa08d, 0xa08e, 0xa08f, 0xa090, + 0xa091, 0xa092, 0xa093, 0xa094, 0xa095, 0xa096, 0xa097, 0xa098, + 0xa099, 0xa09a, 0xa09b, 0xa09c, 0xa09d, 0xa09e, 0xa09f, 0xa0a0, + 0xa0a1, 0xa0a2, 0xa0a3, 0xa0a4, 0xa0a5, 0xa0a6, 0xa0a7, 0xa0a8, + 0xa0a9, 0xa0aa, 0xa0ab, 0xa0ac, 0xa0ad, 0xa0ae, 0xa0af, 0xa0b0, + 0xa0b1, 0xa0b2, 0xa0b3, 0xa0b4, 0xa0b5, 0xa0b6, 0xa0b7, 0xa0b8, + 0xa0b9, 0xa0ba, 0xa0bb, 0xa0bc, 0xa0bd, 0xa0be, 0xa0bf, 0xa0c0, + 0xa0c1, 0xa0c2, 0xa0c3, 0xa0c4, 0xa0c5, 0xa0c6, 0xa0c7, 0xa0c8, + 0xa0c9, 0xa0ca, 0xa0cb, 0xa0cc, 0xa0cd, 0xa0ce, 0xa0cf, 0xa0d0, + 0xa0d1, 0xa0d2, 0xa0d3, 0xa0d4, 0xa0d5, 0xa0d6, 0xa0d7, 0xa0d8, + 0xa0d9, 0xa0da, 0xa0db, 0xa0dc, 0xa0dd, 0xa0de, 0xa0df, 0xa0e0, + 0xa0e1, 0xa0e2, 0xa0e3, 0xa0e4, 0xa0e5, 0xa0e6, 0xa0e7, 0xa0e8, + 0xa0e9, 0xa0ea, 0xa0eb, 0xa0ec, 0xa0ed, 0xa0ee, 0xa0ef, 0xa0f0, + 0xa0f1, 0xa0f2, 0xa0f3, 0xa0f4, 0xa0f5, 0xa0f6, 0xa0f7, 0xa0f8, + 0xa0f9, 0xa0fa, 0xa0fb, 0xa0fc, 0xa0fd, 0xa0fe, 0xaa40, 0xaa41, + 0xaa42, 0xaa43, 0xaa44, 0xaa45, 0xaa46, 0xaa47, 0xaa48, 0xaa49, + 0xaa4a, 0xaa4b, 0xaa4c, 0xaa4d, 0xaa4e, 0xaa4f, 0xaa50, 0xaa51, + 0xaa52, 0xaa53, 0xaa54, 0xaa55, 0xaa56, 0xaa57, 0xaa58, 0xaa59, + 0xaa5a, 0xaa5b, 0xaa5c, 0xaa5d, 0xaa5e, 0xaa5f, 0xaa60, 0xaa61, + 0xaa62, 0xaa63, 0xaa64, 0xaa65, 0xaa66, 0xaa67, 0xaa68, 0xaa69, + 0xaa6a, 0xaa6b, 0xaa6c, 0xaa6d, 0xaa6e, 0xaa6f, 0xaa70, 0xaa71, + 0xaa72, 0xaa73, 0xaa74, 0xaa75, 0xaa76, 0xaa77, 0xaa78, 0xaa79, + 0xaa7a, 0xaa7b, 0xaa7c, 0xaa7d, 0xaa7e, 0xaa80, 0xaa81, 0xaa82, + 0xaa83, 0xaa84, 0xaa85, 0xaa86, 0xaa87, 0xaa88, 0xaa89, 0xaa8a, + 0xaa8b, 0xaa8c, 0xaa8d, 0xaa8e, 0xaa8f, 0xaa90, 0xaa91, 0xaa92, + 0xaa93, 0xaa94, 0xaa95, 0xaa96, 0xaa97, 0xaa98, 0xaa99, 0xaa9a, + 0xaa9b, 0xaa9c, 0xaa9d, 0xaa9e, 0xaa9f, 0xaaa0, 0xab40, 0xab41, + 0xab42, 0xab43, 0xab44, 0xab45, 0xab46, 0xab47, 0xab48, 0xab49, + 0xab4a, 0xab4b, 0xab4c, 0xab4d, 0xab4e, 0xab4f, 0xab50, 0xab51, + 0xab52, 0xab53, 0xab54, 0xab55, 0xab56, 0xab57, 0xab58, 0xab59, + 0xab5a, 0xab5b, 0xab5c, 0xab5d, 0xab5e, 0xab5f, 0xab60, 0xab61, + 0xab62, 0xab63, 0xab64, 0xab65, 0xab66, 0xab67, 0xab68, 0xab69, + 0xab6a, 0xab6b, 0xab6c, 0xab6d, 0xab6e, 0xab6f, 0xab70, 0xab71, + 0xab72, 0xab73, 0xab74, 0xab75, 0xab76, 0xab77, 0xab78, 0xab79, + 0xab7a, 0xab7b, 0xab7c, 0xab7d, 0xab7e, 0xab80, 0xab81, 0xab82, + 0xab83, 0xab84, 0xab85, 0xab86, 0xab87, 0xab88, 0xab89, 0xab8a, + 0xab8b, 0xab8c, 0xab8d, 0xab8e, 0xab8f, 0xab90, 0xab91, 0xab92, + 0xab93, 0xab94, 0xab95, 0xab96, 0xab97, 0xab98, 0xab99, 0xab9a, + 0xab9b, 0xab9c, 0xab9d, 0xab9e, 0xab9f, 0xaba0, 0xac40, 0xac41, + 0xac42, 0xac43, 0xac44, 0xac45, 0xac46, 0xac47, 0xac48, 0xac49, + 0xac4a, 0xac4b, 0xac4c, 0xac4d, 0xac4e, 0xac4f, 0xac50, 0xac51, + 0xac52, 0xac53, 0xac54, 0xac55, 0xac56, 0xac57, 0xac58, 0xac59, + 0xac5a, 0xac5b, 0xac5c, 0xac5d, 0xac5e, 0xac5f, 0xac60, 0xac61, + 0xac62, 0xac63, 0xac64, 0xac65, 0xac66, 0xac67, 0xac68, 0xac69, + 0xac6a, 0xac6b, 0xac6c, 0xac6d, 0xac6e, 0xac6f, 0xac70, 0xac71, + 0xac72, 0xac73, 0xac74, 0xac75, 0xac76, 0xac77, 0xac78, 0xac79, + 0xac7a, 0xac7b, 0xac7c, 0xac7d, 0xac7e, 0xac80, 0xac81, 0xac82, + 0xac83, 0xac84, 0xac85, 0xac86, 0xac87, 0xac88, 0xac89, 0xac8a, + 0xac8b, 0xac8c, 0xac8d, 0xac8e, 0xac8f, 0xac90, 0xac91, 0xac92, + 0xac93, 0xac94, 0xac95, 0xac96, 0xac97, 0xac98, 0xac99, 0xac9a, + 0xac9b, 0xac9c, 0xac9d, 0xac9e, 0xac9f, 0xaca0, 0xad40, 0xad41, + 0xad42, 0xad43, 0xad44, 0xad45, 0xad46, 0xad47, 0xad48, 0xad49, + 0xad4a, 0xad4b, 0xad4c, 0xad4d, 0xad4e, 0xad4f, 0xad50, 0xad51, + 0xad52, 0xad53, 0xad54, 0xad55, 0xad56, 0xad57, 0xad58, 0xad59, + 0xad5a, 0xad5b, 0xad5c, 0xad5d, 0xad5e, 0xad5f, 0xad60, 0xad61, + 0xad62, 0xad63, 0xad64, 0xad65, 0xad66, 0xad67, 0xad68, 0xad69, + 0xad6a, 0xad6b, 0xad6c, 0xad6d, 0xad6e, 0xad6f, 0xad70, 0xad71, + 0xad72, 0xad73, 0xad74, 0xad75, 0xad76, 0xad77, 0xad78, 0xad79, + 0xad7a, 0xad7b, 0xad7c, 0xad7d, 0xad7e, 0xad80, 0xad81, 0xad82, + 0xad83, 0xad84, 0xad85, 0xad86, 0xad87, 0xad88, 0xad89, 0xad8a, + 0xad8b, 0xad8c, 0xad8d, 0xad8e, 0xad8f, 0xad90, 0xad91, 0xad92, + 0xad93, 0xad94, 0xad95, 0xad96, 0xad97, 0xad98, 0xad99, 0xad9a, + 0xad9b, 0xad9c, 0xad9d, 0xad9e, 0xad9f, 0xada0, 0xae40, 0xae41, + 0xae42, 0xae43, 0xae44, 0xae45, 0xae46, 0xae47, 0xae48, 0xae49, + 0xae4a, 0xae4b, 0xae4c, 0xae4d, 0xae4e, 0xae4f, 0xae50, 0xae51, + 0xae52, 0xae53, 0xae54, 0xae55, 0xae56, 0xae57, 0xae58, 0xae59, + 0xae5a, 0xae5b, 0xae5c, 0xae5d, 0xae5e, 0xae5f, 0xae60, 0xae61, + 0xae62, 0xae63, 0xae64, 0xae65, 0xae66, 0xae67, 0xae68, 0xae69, + 0xae6a, 0xae6b, 0xae6c, 0xae6d, 0xae6e, 0xae6f, 0xae70, 0xae71, + 0xae72, 0xae73, 0xae74, 0xae75, 0xae76, 0xae77, 0xae78, 0xae79, + 0xae7a, 0xae7b, 0xae7c, 0xae7d, 0xae7e, 0xae80, 0xae81, 0xae82, + 0xae83, 0xae84, 0xae85, 0xae86, 0xae87, 0xae88, 0xae89, 0xae8a, + 0xae8b, 0xae8c, 0xae8d, 0xae8e, 0xae8f, 0xae90, 0xae91, 0xae92, + 0xae93, 0xae94, 0xae95, 0xae96, 0xae97, 0xae98, 0xae99, 0xae9a, + 0xae9b, 0xae9c, 0xae9d, 0xae9e, 0xae9f, 0xaea0, 0xaf40, 0xaf41, + 0xaf42, 0xaf43, 0xaf44, 0xaf45, 0xaf46, 0xaf47, 0xaf48, 0xaf49, + 0xaf4a, 0xaf4b, 0xaf4c, 0xaf4d, 0xaf4e, 0xaf4f, 0xaf50, 0xaf51, + 0xaf52, 0xaf53, 0xaf54, 0xaf55, 0xaf56, 0xaf57, 0xaf58, 0xaf59, + 0xaf5a, 0xaf5b, 0xaf5c, 0xaf5d, 0xaf5e, 0xaf5f, 0xaf60, 0xaf61, + 0xaf62, 0xaf63, 0xaf64, 0xaf65, 0xaf66, 0xaf67, 0xaf68, 0xaf69, + 0xaf6a, 0xaf6b, 0xaf6c, 0xaf6d, 0xaf6e, 0xaf6f, 0xaf70, 0xaf71, + 0xaf72, 0xaf73, 0xaf74, 0xaf75, 0xaf76, 0xaf77, 0xaf78, 0xaf79, + 0xaf7a, 0xaf7b, 0xaf7c, 0xaf7d, 0xaf7e, 0xaf80, 0xaf81, 0xaf82, + 0xaf83, 0xaf84, 0xaf85, 0xaf86, 0xaf87, 0xaf88, 0xaf89, 0xaf8a, + 0xaf8b, 0xaf8c, 0xaf8d, 0xaf8e, 0xaf8f, 0xaf90, 0xaf91, 0xaf92, + 0xaf93, 0xaf94, 0xaf95, 0xaf96, 0xaf97, 0xaf98, 0xaf99, 0xaf9a, + 0xaf9b, 0xaf9c, 0xaf9d, 0xaf9e, 0xaf9f, 0xafa0, 0xb040, 0xb041, + 0xb042, 0xb043, 0xb044, 0xb045, 0xb046, 0xb047, 0xb048, 0xb049, + 0xb04a, 0xb04b, 0xb04c, 0xb04d, 0xb04e, 0xb04f, 0xb050, 0xb051, + 0xb052, 0xb053, 0xb054, 0xb055, 0xb056, 0xb057, 0xb058, 0xb059, + 0xb05a, 0xb05b, 0xb05c, 0xb05d, 0xb05e, 0xb05f, 0xb060, 0xb061, + 0xb062, 0xb063, 0xb064, 0xb065, 0xb066, 0xb067, 0xb068, 0xb069, + 0xb06a, 0xb06b, 0xb06c, 0xb06d, 0xb06e, 0xb06f, 0xb070, 0xb071, + 0xb072, 0xb073, 0xb074, 0xb075, 0xb076, 0xb077, 0xb078, 0xb079, + 0xb07a, 0xb07b, 0xb07c, 0xb07d, 0xb07e, 0xb080, 0xb081, 0xb082, + 0xb083, 0xb084, 0xb085, 0xb086, 0xb087, 0xb088, 0xb089, 0xb08a, + 0xb08b, 0xb08c, 0xb08d, 0xb08e, 0xb08f, 0xb090, 0xb091, 0xb092, + 0xb093, 0xb094, 0xb095, 0xb096, 0xb097, 0xb098, 0xb099, 0xb09a, + 0xb09b, 0xb09c, 0xb09d, 0xb09e, 0xb09f, 0xb0a0, 0xb140, 0xb141, + 0xb142, 0xb143, 0xb144, 0xb145, 0xb146, 0xb147, 0xb148, 0xb149, + 0xb14a, 0xb14b, 0xb14c, 0xb14d, 0xb14e, 0xb14f, 0xb150, 0xb151, + 0xb152, 0xb153, 0xb154, 0xb155, 0xb156, 0xb157, 0xb158, 0xb159, + 0xb15a, 0xb15b, 0xb15c, 0xb15d, 0xb15e, 0xb15f, 0xb160, 0xb161, + 0xb162, 0xb163, 0xb164, 0xb165, 0xb166, 0xb167, 0xb168, 0xb169, + 0xb16a, 0xb16b, 0xb16c, 0xb16d, 0xb16e, 0xb16f, 0xb170, 0xb171, + 0xb172, 0xb173, 0xb174, 0xb175, 0xb176, 0xb177, 0xb178, 0xb179, + 0xb17a, 0xb17b, 0xb17c, 0xb17d, 0xb17e, 0xb180, 0xb181, 0xb182, + 0xb183, 0xb184, 0xb185, 0xb186, 0xb187, 0xb188, 0xb189, 0xb18a, + 0xb18b, 0xb18c, 0xb18d, 0xb18e, 0xb18f, 0xb190, 0xb191, 0xb192, + 0xb193, 0xb194, 0xb195, 0xb196, 0xb197, 0xb198, 0xb199, 0xb19a, + 0xb19b, 0xb19c, 0xb19d, 0xb19e, 0xb19f, 0xb1a0, 0xb240, 0xb241, + 0xb242, 0xb243, 0xb244, 0xb245, 0xb246, 0xb247, 0xb248, 0xb249, + 0xb24a, 0xb24b, 0xb24c, 0xb24d, 0xb24e, 0xb24f, 0xb250, 0xb251, + 0xb252, 0xb253, 0xb254, 0xb255, 0xb256, 0xb257, 0xb258, 0xb259, + 0xb25a, 0xb25b, 0xb25c, 0xb25d, 0xb25e, 0xb25f, 0xb260, 0xb261, + 0xb262, 0xb263, 0xb264, 0xb265, 0xb266, 0xb267, 0xb268, 0xb269, + 0xb26a, 0xb26b, 0xb26c, 0xb26d, 0xb26e, 0xb26f, 0xb270, 0xb271, + 0xb272, 0xb273, 0xb274, 0xb275, 0xb276, 0xb277, 0xb278, 0xb279, + 0xb27a, 0xb27b, 0xb27c, 0xb27d, 0xb27e, 0xb280, 0xb281, 0xb282, + 0xb283, 0xb284, 0xb285, 0xb286, 0xb287, 0xb288, 0xb289, 0xb28a, + 0xb28b, 0xb28c, 0xb28d, 0xb28e, 0xb28f, 0xb290, 0xb291, 0xb292, + 0xb293, 0xb294, 0xb295, 0xb296, 0xb297, 0xb298, 0xb299, 0xb29a, + 0xb29b, 0xb29c, 0xb29d, 0xb29e, 0xb29f, 0xb2a0, 0xb340, 0xb341, + 0xb342, 0xb343, 0xb344, 0xb345, 0xb346, 0xb347, 0xb348, 0xb349, + 0xb34a, 0xb34b, 0xb34c, 0xb34d, 0xb34e, 0xb34f, 0xb350, 0xb351, + 0xb352, 0xb353, 0xb354, 0xb355, 0xb356, 0xb357, 0xb358, 0xb359, + 0xb35a, 0xb35b, 0xb35c, 0xb35d, 0xb35e, 0xb35f, 0xb360, 0xb361, + 0xb362, 0xb363, 0xb364, 0xb365, 0xb366, 0xb367, 0xb368, 0xb369, + 0xb36a, 0xb36b, 0xb36c, 0xb36d, 0xb36e, 0xb36f, 0xb370, 0xb371, + 0xb372, 0xb373, 0xb374, 0xb375, 0xb376, 0xb377, 0xb378, 0xb379, + 0xb37a, 0xb37b, 0xb37c, 0xb37d, 0xb37e, 0xb380, 0xb381, 0xb382, + 0xb383, 0xb384, 0xb385, 0xb386, 0xb387, 0xb388, 0xb389, 0xb38a, + 0xb38b, 0xb38c, 0xb38d, 0xb38e, 0xb38f, 0xb390, 0xb391, 0xb392, + 0xb393, 0xb394, 0xb395, 0xb396, 0xb397, 0xb398, 0xb399, 0xb39a, + 0xb39b, 0xb39c, 0xb39d, 0xb39e, 0xb39f, 0xb3a0, 0xb440, 0xb441, + 0xb442, 0xb443, 0xb444, 0xb445, 0xb446, 0xb447, 0xb448, 0xb449, + 0xb44a, 0xb44b, 0xb44c, 0xb44d, 0xb44e, 0xb44f, 0xb450, 0xb451, + 0xb452, 0xb453, 0xb454, 0xb455, 0xb456, 0xb457, 0xb458, 0xb459, + 0xb45a, 0xb45b, 0xb45c, 0xb45d, 0xb45e, 0xb45f, 0xb460, 0xb461, + 0xb462, 0xb463, 0xb464, 0xb465, 0xb466, 0xb467, 0xb468, 0xb469, + 0xb46a, 0xb46b, 0xb46c, 0xb46d, 0xb46e, 0xb46f, 0xb470, 0xb471, + 0xb472, 0xb473, 0xb474, 0xb475, 0xb476, 0xb477, 0xb478, 0xb479, + 0xb47a, 0xb47b, 0xb47c, 0xb47d, 0xb47e, 0xb480, 0xb481, 0xb482, + 0xb483, 0xb484, 0xb485, 0xb486, 0xb487, 0xb488, 0xb489, 0xb48a, + 0xb48b, 0xb48c, 0xb48d, 0xb48e, 0xb48f, 0xb490, 0xb491, 0xb492, + 0xb493, 0xb494, 0xb495, 0xb496, 0xb497, 0xb498, 0xb499, 0xb49a, + 0xb49b, 0xb49c, 0xb49d, 0xb49e, 0xb49f, 0xb4a0, 0xb540, 0xb541, + 0xb542, 0xb543, 0xb544, 0xb545, 0xb546, 0xb547, 0xb548, 0xb549, + 0xb54a, 0xb54b, 0xb54c, 0xb54d, 0xb54e, 0xb54f, 0xb550, 0xb551, + 0xb552, 0xb553, 0xb554, 0xb555, 0xb556, 0xb557, 0xb558, 0xb559, + 0xb55a, 0xb55b, 0xb55c, 0xb55d, 0xb55e, 0xb55f, 0xb560, 0xb561, + 0xb562, 0xb563, 0xb564, 0xb565, 0xb566, 0xb567, 0xb568, 0xb569, + 0xb56a, 0xb56b, 0xb56c, 0xb56d, 0xb56e, 0xb56f, 0xb570, 0xb571, + 0xb572, 0xb573, 0xb574, 0xb575, 0xb576, 0xb577, 0xb578, 0xb579, + 0xb57a, 0xb57b, 0xb57c, 0xb57d, 0xb57e, 0xb580, 0xb581, 0xb582, + 0xb583, 0xb584, 0xb585, 0xb586, 0xb587, 0xb588, 0xb589, 0xb58a, + 0xb58b, 0xb58c, 0xb58d, 0xb58e, 0xb58f, 0xb590, 0xb591, 0xb592, + 0xb593, 0xb594, 0xb595, 0xb596, 0xb597, 0xb598, 0xb599, 0xb59a, + 0xb59b, 0xb59c, 0xb59d, 0xb59e, 0xb59f, 0xb5a0, 0xb640, 0xb641, + 0xb642, 0xb643, 0xb644, 0xb645, 0xb646, 0xb647, 0xb648, 0xb649, + 0xb64a, 0xb64b, 0xb64c, 0xb64d, 0xb64e, 0xb64f, 0xb650, 0xb651, + 0xb652, 0xb653, 0xb654, 0xb655, 0xb656, 0xb657, 0xb658, 0xb659, + 0xb65a, 0xb65b, 0xb65c, 0xb65d, 0xb65e, 0xb65f, 0xb660, 0xb661, + 0xb662, 0xb663, 0xb664, 0xb665, 0xb666, 0xb667, 0xb668, 0xb669, + 0xb66a, 0xb66b, 0xb66c, 0xb66d, 0xb66e, 0xb66f, 0xb670, 0xb671, + 0xb672, 0xb673, 0xb674, 0xb675, 0xb676, 0xb677, 0xb678, 0xb679, + 0xb67a, 0xb67b, 0xb67c, 0xb67d, 0xb67e, 0xb680, 0xb681, 0xb682, + 0xb683, 0xb684, 0xb685, 0xb686, 0xb687, 0xb688, 0xb689, 0xb68a, + 0xb68b, 0xb68c, 0xb68d, 0xb68e, 0xb68f, 0xb690, 0xb691, 0xb692, + 0xb693, 0xb694, 0xb695, 0xb696, 0xb697, 0xb698, 0xb699, 0xb69a, + 0xb69b, 0xb69c, 0xb69d, 0xb69e, 0xb69f, 0xb6a0, 0xb740, 0xb741, + 0xb742, 0xb743, 0xb744, 0xb745, 0xb746, 0xb747, 0xb748, 0xb749, + 0xb74a, 0xb74b, 0xb74c, 0xb74d, 0xb74e, 0xb74f, 0xb750, 0xb751, + 0xb752, 0xb753, 0xb754, 0xb755, 0xb756, 0xb757, 0xb758, 0xb759, + 0xb75a, 0xb75b, 0xb75c, 0xb75d, 0xb75e, 0xb75f, 0xb760, 0xb761, + 0xb762, 0xb763, 0xb764, 0xb765, 0xb766, 0xb767, 0xb768, 0xb769, + 0xb76a, 0xb76b, 0xb76c, 0xb76d, 0xb76e, 0xb76f, 0xb770, 0xb771, + 0xb772, 0xb773, 0xb774, 0xb775, 0xb776, 0xb777, 0xb778, 0xb779, + 0xb77a, 0xb77b, 0xb77c, 0xb77d, 0xb77e, 0xb780, 0xb781, 0xb782, + 0xb783, 0xb784, 0xb785, 0xb786, 0xb787, 0xb788, 0xb789, 0xb78a, + 0xb78b, 0xb78c, 0xb78d, 0xb78e, 0xb78f, 0xb790, 0xb791, 0xb792, + 0xb793, 0xb794, 0xb795, 0xb796, 0xb797, 0xb798, 0xb799, 0xb79a, + 0xb79b, 0xb79c, 0xb79d, 0xb79e, 0xb79f, 0xb7a0, 0xb840, 0xb841, + 0xb842, 0xb843, 0xb844, 0xb845, 0xb846, 0xb847, 0xb848, 0xb849, + 0xb84a, 0xb84b, 0xb84c, 0xb84d, 0xb84e, 0xb84f, 0xb850, 0xb851, + 0xb852, 0xb853, 0xb854, 0xb855, 0xb856, 0xb857, 0xb858, 0xb859, + 0xb85a, 0xb85b, 0xb85c, 0xb85d, 0xb85e, 0xb85f, 0xb860, 0xb861, + 0xb862, 0xb863, 0xb864, 0xb865, 0xb866, 0xb867, 0xb868, 0xb869, + 0xb86a, 0xb86b, 0xb86c, 0xb86d, 0xb86e, 0xb86f, 0xb870, 0xb871, + 0xb872, 0xb873, 0xb874, 0xb875, 0xb876, 0xb877, 0xb878, 0xb879, + 0xb87a, 0xb87b, 0xb87c, 0xb87d, 0xb87e, 0xb880, 0xb881, 0xb882, + 0xb883, 0xb884, 0xb885, 0xb886, 0xb887, 0xb888, 0xb889, 0xb88a, + 0xb88b, 0xb88c, 0xb88d, 0xb88e, 0xb88f, 0xb890, 0xb891, 0xb892, + 0xb893, 0xb894, 0xb895, 0xb896, 0xb897, 0xb898, 0xb899, 0xb89a, + 0xb89b, 0xb89c, 0xb89d, 0xb89e, 0xb89f, 0xb8a0, 0xb940, 0xb941, + 0xb942, 0xb943, 0xb944, 0xb945, 0xb946, 0xb947, 0xb948, 0xb949, + 0xb94a, 0xb94b, 0xb94c, 0xb94d, 0xb94e, 0xb94f, 0xb950, 0xb951, + 0xb952, 0xb953, 0xb954, 0xb955, 0xb956, 0xb957, 0xb958, 0xb959, + 0xb95a, 0xb95b, 0xb95c, 0xb95d, 0xb95e, 0xb95f, 0xb960, 0xb961, + 0xb962, 0xb963, 0xb964, 0xb965, 0xb966, 0xb967, 0xb968, 0xb969, + 0xb96a, 0xb96b, 0xb96c, 0xb96d, 0xb96e, 0xb96f, 0xb970, 0xb971, + 0xb972, 0xb973, 0xb974, 0xb975, 0xb976, 0xb977, 0xb978, 0xb979, + 0xb97a, 0xb97b, 0xb97c, 0xb97d, 0xb97e, 0xb980, 0xb981, 0xb982, + 0xb983, 0xb984, 0xb985, 0xb986, 0xb987, 0xb988, 0xb989, 0xb98a, + 0xb98b, 0xb98c, 0xb98d, 0xb98e, 0xb98f, 0xb990, 0xb991, 0xb992, + 0xb993, 0xb994, 0xb995, 0xb996, 0xb997, 0xb998, 0xb999, 0xb99a, + 0xb99b, 0xb99c, 0xb99d, 0xb99e, 0xb99f, 0xb9a0, 0xba40, 0xba41, + 0xba42, 0xba43, 0xba44, 0xba45, 0xba46, 0xba47, 0xba48, 0xba49, + 0xba4a, 0xba4b, 0xba4c, 0xba4d, 0xba4e, 0xba4f, 0xba50, 0xba51, + 0xba52, 0xba53, 0xba54, 0xba55, 0xba56, 0xba57, 0xba58, 0xba59, + 0xba5a, 0xba5b, 0xba5c, 0xba5d, 0xba5e, 0xba5f, 0xba60, 0xba61, + 0xba62, 0xba63, 0xba64, 0xba65, 0xba66, 0xba67, 0xba68, 0xba69, + 0xba6a, 0xba6b, 0xba6c, 0xba6d, 0xba6e, 0xba6f, 0xba70, 0xba71, + 0xba72, 0xba73, 0xba74, 0xba75, 0xba76, 0xba77, 0xba78, 0xba79, + 0xba7a, 0xba7b, 0xba7c, 0xba7d, 0xba7e, 0xba80, 0xba81, 0xba82, + 0xba83, 0xba84, 0xba85, 0xba86, 0xba87, 0xba88, 0xba89, 0xba8a, + 0xba8b, 0xba8c, 0xba8d, 0xba8e, 0xba8f, 0xba90, 0xba91, 0xba92, + 0xba93, 0xba94, 0xba95, 0xba96, 0xba97, 0xba98, 0xba99, 0xba9a, + 0xba9b, 0xba9c, 0xba9d, 0xba9e, 0xba9f, 0xbaa0, 0xbb40, 0xbb41, + 0xbb42, 0xbb43, 0xbb44, 0xbb45, 0xbb46, 0xbb47, 0xbb48, 0xbb49, + 0xbb4a, 0xbb4b, 0xbb4c, 0xbb4d, 0xbb4e, 0xbb4f, 0xbb50, 0xbb51, + 0xbb52, 0xbb53, 0xbb54, 0xbb55, 0xbb56, 0xbb57, 0xbb58, 0xbb59, + 0xbb5a, 0xbb5b, 0xbb5c, 0xbb5d, 0xbb5e, 0xbb5f, 0xbb60, 0xbb61, + 0xbb62, 0xbb63, 0xbb64, 0xbb65, 0xbb66, 0xbb67, 0xbb68, 0xbb69, + 0xbb6a, 0xbb6b, 0xbb6c, 0xbb6d, 0xbb6e, 0xbb6f, 0xbb70, 0xbb71, + 0xbb72, 0xbb73, 0xbb74, 0xbb75, 0xbb76, 0xbb77, 0xbb78, 0xbb79, + 0xbb7a, 0xbb7b, 0xbb7c, 0xbb7d, 0xbb7e, 0xbb80, 0xbb81, 0xbb82, + 0xbb83, 0xbb84, 0xbb85, 0xbb86, 0xbb87, 0xbb88, 0xbb89, 0xbb8a, + 0xbb8b, 0xbb8c, 0xbb8d, 0xbb8e, 0xbb8f, 0xbb90, 0xbb91, 0xbb92, + 0xbb93, 0xbb94, 0xbb95, 0xbb96, 0xbb97, 0xbb98, 0xbb99, 0xbb9a, + 0xbb9b, 0xbb9c, 0xbb9d, 0xbb9e, 0xbb9f, 0xbba0, 0xbc40, 0xbc41, + 0xbc42, 0xbc43, 0xbc44, 0xbc45, 0xbc46, 0xbc47, 0xbc48, 0xbc49, + 0xbc4a, 0xbc4b, 0xbc4c, 0xbc4d, 0xbc4e, 0xbc4f, 0xbc50, 0xbc51, + 0xbc52, 0xbc53, 0xbc54, 0xbc55, 0xbc56, 0xbc57, 0xbc58, 0xbc59, + 0xbc5a, 0xbc5b, 0xbc5c, 0xbc5d, 0xbc5e, 0xbc5f, 0xbc60, 0xbc61, + 0xbc62, 0xbc63, 0xbc64, 0xbc65, 0xbc66, 0xbc67, 0xbc68, 0xbc69, + 0xbc6a, 0xbc6b, 0xbc6c, 0xbc6d, 0xbc6e, 0xbc6f, 0xbc70, 0xbc71, + 0xbc72, 0xbc73, 0xbc74, 0xbc75, 0xbc76, 0xbc77, 0xbc78, 0xbc79, + 0xbc7a, 0xbc7b, 0xbc7c, 0xbc7d, 0xbc7e, 0xbc80, 0xbc81, 0xbc82, + 0xbc83, 0xbc84, 0xbc85, 0xbc86, 0xbc87, 0xbc88, 0xbc89, 0xbc8a, + 0xbc8b, 0xbc8c, 0xbc8d, 0xbc8e, 0xbc8f, 0xbc90, 0xbc91, 0xbc92, + 0xbc93, 0xbc94, 0xbc95, 0xbc96, 0xbc97, 0xbc98, 0xbc99, 0xbc9a, + 0xbc9b, 0xbc9c, 0xbc9d, 0xbc9e, 0xbc9f, 0xbca0, 0xbd40, 0xbd41, + 0xbd42, 0xbd43, 0xbd44, 0xbd45, 0xbd46, 0xbd47, 0xbd48, 0xbd49, + 0xbd4a, 0xbd4b, 0xbd4c, 0xbd4d, 0xbd4e, 0xbd4f, 0xbd50, 0xbd51, + 0xbd52, 0xbd53, 0xbd54, 0xbd55, 0xbd56, 0xbd57, 0xbd58, 0xbd59, + 0xbd5a, 0xbd5b, 0xbd5c, 0xbd5d, 0xbd5e, 0xbd5f, 0xbd60, 0xbd61, + 0xbd62, 0xbd63, 0xbd64, 0xbd65, 0xbd66, 0xbd67, 0xbd68, 0xbd69, + 0xbd6a, 0xbd6b, 0xbd6c, 0xbd6d, 0xbd6e, 0xbd6f, 0xbd70, 0xbd71, + 0xbd72, 0xbd73, 0xbd74, 0xbd75, 0xbd76, 0xbd77, 0xbd78, 0xbd79, + 0xbd7a, 0xbd7b, 0xbd7c, 0xbd7d, 0xbd7e, 0xbd80, 0xbd81, 0xbd82, + 0xbd83, 0xbd84, 0xbd85, 0xbd86, 0xbd87, 0xbd88, 0xbd89, 0xbd8a, + 0xbd8b, 0xbd8c, 0xbd8d, 0xbd8e, 0xbd8f, 0xbd90, 0xbd91, 0xbd92, + 0xbd93, 0xbd94, 0xbd95, 0xbd96, 0xbd97, 0xbd98, 0xbd99, 0xbd9a, + 0xbd9b, 0xbd9c, 0xbd9d, 0xbd9e, 0xbd9f, 0xbda0, 0xbe40, 0xbe41, + 0xbe42, 0xbe43, 0xbe44, 0xbe45, 0xbe46, 0xbe47, 0xbe48, 0xbe49, + 0xbe4a, 0xbe4b, 0xbe4c, 0xbe4d, 0xbe4e, 0xbe4f, 0xbe50, 0xbe51, + 0xbe52, 0xbe53, 0xbe54, 0xbe55, 0xbe56, 0xbe57, 0xbe58, 0xbe59, + 0xbe5a, 0xbe5b, 0xbe5c, 0xbe5d, 0xbe5e, 0xbe5f, 0xbe60, 0xbe61, + 0xbe62, 0xbe63, 0xbe64, 0xbe65, 0xbe66, 0xbe67, 0xbe68, 0xbe69, + 0xbe6a, 0xbe6b, 0xbe6c, 0xbe6d, 0xbe6e, 0xbe6f, 0xbe70, 0xbe71, + 0xbe72, 0xbe73, 0xbe74, 0xbe75, 0xbe76, 0xbe77, 0xbe78, 0xbe79, + 0xbe7a, 0xbe7b, 0xbe7c, 0xbe7d, 0xbe7e, 0xbe80, 0xbe81, 0xbe82, + 0xbe83, 0xbe84, 0xbe85, 0xbe86, 0xbe87, 0xbe88, 0xbe89, 0xbe8a, + 0xbe8b, 0xbe8c, 0xbe8d, 0xbe8e, 0xbe8f, 0xbe90, 0xbe91, 0xbe92, + 0xbe93, 0xbe94, 0xbe95, 0xbe96, 0xbe97, 0xbe98, 0xbe99, 0xbe9a, + 0xbe9b, 0xbe9c, 0xbe9d, 0xbe9e, 0xbe9f, 0xbea0, 0xbf40, 0xbf41, + 0xbf42, 0xbf43, 0xbf44, 0xbf45, 0xbf46, 0xbf47, 0xbf48, 0xbf49, + 0xbf4a, 0xbf4b, 0xbf4c, 0xbf4d, 0xbf4e, 0xbf4f, 0xbf50, 0xbf51, + 0xbf52, 0xbf53, 0xbf54, 0xbf55, 0xbf56, 0xbf57, 0xbf58, 0xbf59, + 0xbf5a, 0xbf5b, 0xbf5c, 0xbf5d, 0xbf5e, 0xbf5f, 0xbf60, 0xbf61, + 0xbf62, 0xbf63, 0xbf64, 0xbf65, 0xbf66, 0xbf67, 0xbf68, 0xbf69, + 0xbf6a, 0xbf6b, 0xbf6c, 0xbf6d, 0xbf6e, 0xbf6f, 0xbf70, 0xbf71, + 0xbf72, 0xbf73, 0xbf74, 0xbf75, 0xbf76, 0xbf77, 0xbf78, 0xbf79, + 0xbf7a, 0xbf7b, 0xbf7c, 0xbf7d, 0xbf7e, 0xbf80, 0xbf81, 0xbf82, + 0xbf83, 0xbf84, 0xbf85, 0xbf86, 0xbf87, 0xbf88, 0xbf89, 0xbf8a, + 0xbf8b, 0xbf8c, 0xbf8d, 0xbf8e, 0xbf8f, 0xbf90, 0xbf91, 0xbf92, + 0xbf93, 0xbf94, 0xbf95, 0xbf96, 0xbf97, 0xbf98, 0xbf99, 0xbf9a, + 0xbf9b, 0xbf9c, 0xbf9d, 0xbf9e, 0xbf9f, 0xbfa0, 0xc040, 0xc041, + 0xc042, 0xc043, 0xc044, 0xc045, 0xc046, 0xc047, 0xc048, 0xc049, + 0xc04a, 0xc04b, 0xc04c, 0xc04d, 0xc04e, 0xc04f, 0xc050, 0xc051, + 0xc052, 0xc053, 0xc054, 0xc055, 0xc056, 0xc057, 0xc058, 0xc059, + 0xc05a, 0xc05b, 0xc05c, 0xc05d, 0xc05e, 0xc05f, 0xc060, 0xc061, + 0xc062, 0xc063, 0xc064, 0xc065, 0xc066, 0xc067, 0xc068, 0xc069, + 0xc06a, 0xc06b, 0xc06c, 0xc06d, 0xc06e, 0xc06f, 0xc070, 0xc071, + 0xc072, 0xc073, 0xc074, 0xc075, 0xc076, 0xc077, 0xc078, 0xc079, + 0xc07a, 0xc07b, 0xc07c, 0xc07d, 0xc07e, 0xc080, 0xc081, 0xc082, + 0xc083, 0xc084, 0xc085, 0xc086, 0xc087, 0xc088, 0xc089, 0xc08a, + 0xc08b, 0xc08c, 0xc08d, 0xc08e, 0xc08f, 0xc090, 0xc091, 0xc092, + 0xc093, 0xc094, 0xc095, 0xc096, 0xc097, 0xc098, 0xc099, 0xc09a, + 0xc09b, 0xc09c, 0xc09d, 0xc09e, 0xc09f, 0xc0a0, 0xc140, 0xc141, + 0xc142, 0xc143, 0xc144, 0xc145, 0xc146, 0xc147, 0xc148, 0xc149, + 0xc14a, 0xc14b, 0xc14c, 0xc14d, 0xc14e, 0xc14f, 0xc150, 0xc151, + 0xc152, 0xc153, 0xc154, 0xc155, 0xc156, 0xc157, 0xc158, 0xc159, + 0xc15a, 0xc15b, 0xc15c, 0xc15d, 0xc15e, 0xc15f, 0xc160, 0xc161, + 0xc162, 0xc163, 0xc164, 0xc165, 0xc166, 0xc167, 0xc168, 0xc169, + 0xc16a, 0xc16b, 0xc16c, 0xc16d, 0xc16e, 0xc16f, 0xc170, 0xc171, + 0xc172, 0xc173, 0xc174, 0xc175, 0xc176, 0xc177, 0xc178, 0xc179, + 0xc17a, 0xc17b, 0xc17c, 0xc17d, 0xc17e, 0xc180, 0xc181, 0xc182, + 0xc183, 0xc184, 0xc185, 0xc186, 0xc187, 0xc188, 0xc189, 0xc18a, + 0xc18b, 0xc18c, 0xc18d, 0xc18e, 0xc18f, 0xc190, 0xc191, 0xc192, + 0xc193, 0xc194, 0xc195, 0xc196, 0xc197, 0xc198, 0xc199, 0xc19a, + 0xc19b, 0xc19c, 0xc19d, 0xc19e, 0xc19f, 0xc1a0, 0xc240, 0xc241, + 0xc242, 0xc243, 0xc244, 0xc245, 0xc246, 0xc247, 0xc248, 0xc249, + 0xc24a, 0xc24b, 0xc24c, 0xc24d, 0xc24e, 0xc24f, 0xc250, 0xc251, + 0xc252, 0xc253, 0xc254, 0xc255, 0xc256, 0xc257, 0xc258, 0xc259, + 0xc25a, 0xc25b, 0xc25c, 0xc25d, 0xc25e, 0xc25f, 0xc260, 0xc261, + 0xc262, 0xc263, 0xc264, 0xc265, 0xc266, 0xc267, 0xc268, 0xc269, + 0xc26a, 0xc26b, 0xc26c, 0xc26d, 0xc26e, 0xc26f, 0xc270, 0xc271, + 0xc272, 0xc273, 0xc274, 0xc275, 0xc276, 0xc277, 0xc278, 0xc279, + 0xc27a, 0xc27b, 0xc27c, 0xc27d, 0xc27e, 0xc280, 0xc281, 0xc282, + 0xc283, 0xc284, 0xc285, 0xc286, 0xc287, 0xc288, 0xc289, 0xc28a, + 0xc28b, 0xc28c, 0xc28d, 0xc28e, 0xc28f, 0xc290, 0xc291, 0xc292, + 0xc293, 0xc294, 0xc295, 0xc296, 0xc297, 0xc298, 0xc299, 0xc29a, + 0xc29b, 0xc29c, 0xc29d, 0xc29e, 0xc29f, 0xc2a0, 0xc340, 0xc341, + 0xc342, 0xc343, 0xc344, 0xc345, 0xc346, 0xc347, 0xc348, 0xc349, + 0xc34a, 0xc34b, 0xc34c, 0xc34d, 0xc34e, 0xc34f, 0xc350, 0xc351, + 0xc352, 0xc353, 0xc354, 0xc355, 0xc356, 0xc357, 0xc358, 0xc359, + 0xc35a, 0xc35b, 0xc35c, 0xc35d, 0xc35e, 0xc35f, 0xc360, 0xc361, + 0xc362, 0xc363, 0xc364, 0xc365, 0xc366, 0xc367, 0xc368, 0xc369, + 0xc36a, 0xc36b, 0xc36c, 0xc36d, 0xc36e, 0xc36f, 0xc370, 0xc371, + 0xc372, 0xc373, 0xc374, 0xc375, 0xc376, 0xc377, 0xc378, 0xc379, + 0xc37a, 0xc37b, 0xc37c, 0xc37d, 0xc37e, 0xc380, 0xc381, 0xc382, + 0xc383, 0xc384, 0xc385, 0xc386, 0xc387, 0xc388, 0xc389, 0xc38a, + 0xc38b, 0xc38c, 0xc38d, 0xc38e, 0xc38f, 0xc390, 0xc391, 0xc392, + 0xc393, 0xc394, 0xc395, 0xc396, 0xc397, 0xc398, 0xc399, 0xc39a, + 0xc39b, 0xc39c, 0xc39d, 0xc39e, 0xc39f, 0xc3a0, 0xc440, 0xc441, + 0xc442, 0xc443, 0xc444, 0xc445, 0xc446, 0xc447, 0xc448, 0xc449, + 0xc44a, 0xc44b, 0xc44c, 0xc44d, 0xc44e, 0xc44f, 0xc450, 0xc451, + 0xc452, 0xc453, 0xc454, 0xc455, 0xc456, 0xc457, 0xc458, 0xc459, + 0xc45a, 0xc45b, 0xc45c, 0xc45d, 0xc45e, 0xc45f, 0xc460, 0xc461, + 0xc462, 0xc463, 0xc464, 0xc465, 0xc466, 0xc467, 0xc468, 0xc469, + 0xc46a, 0xc46b, 0xc46c, 0xc46d, 0xc46e, 0xc46f, 0xc470, 0xc471, + 0xc472, 0xc473, 0xc474, 0xc475, 0xc476, 0xc477, 0xc478, 0xc479, + 0xc47a, 0xc47b, 0xc47c, 0xc47d, 0xc47e, 0xc480, 0xc481, 0xc482, + 0xc483, 0xc484, 0xc485, 0xc486, 0xc487, 0xc488, 0xc489, 0xc48a, + 0xc48b, 0xc48c, 0xc48d, 0xc48e, 0xc48f, 0xc490, 0xc491, 0xc492, + 0xc493, 0xc494, 0xc495, 0xc496, 0xc497, 0xc498, 0xc499, 0xc49a, + 0xc49b, 0xc49c, 0xc49d, 0xc49e, 0xc49f, 0xc4a0, 0xc540, 0xc541, + 0xc542, 0xc543, 0xc544, 0xc545, 0xc546, 0xc547, 0xc548, 0xc549, + 0xc54a, 0xc54b, 0xc54c, 0xc54d, 0xc54e, 0xc54f, 0xc550, 0xc551, + 0xc552, 0xc553, 0xc554, 0xc555, 0xc556, 0xc557, 0xc558, 0xc559, + 0xc55a, 0xc55b, 0xc55c, 0xc55d, 0xc55e, 0xc55f, 0xc560, 0xc561, + 0xc562, 0xc563, 0xc564, 0xc565, 0xc566, 0xc567, 0xc568, 0xc569, + 0xc56a, 0xc56b, 0xc56c, 0xc56d, 0xc56e, 0xc56f, 0xc570, 0xc571, + 0xc572, 0xc573, 0xc574, 0xc575, 0xc576, 0xc577, 0xc578, 0xc579, + 0xc57a, 0xc57b, 0xc57c, 0xc57d, 0xc57e, 0xc580, 0xc581, 0xc582, + 0xc583, 0xc584, 0xc585, 0xc586, 0xc587, 0xc588, 0xc589, 0xc58a, + 0xc58b, 0xc58c, 0xc58d, 0xc58e, 0xc58f, 0xc590, 0xc591, 0xc592, + 0xc593, 0xc594, 0xc595, 0xc596, 0xc597, 0xc598, 0xc599, 0xc59a, + 0xc59b, 0xc59c, 0xc59d, 0xc59e, 0xc59f, 0xc5a0, 0xc640, 0xc641, + 0xc642, 0xc643, 0xc644, 0xc645, 0xc646, 0xc647, 0xc648, 0xc649, + 0xc64a, 0xc64b, 0xc64c, 0xc64d, 0xc64e, 0xc64f, 0xc650, 0xc651, + 0xc652, 0xc653, 0xc654, 0xc655, 0xc656, 0xc657, 0xc658, 0xc659, + 0xc65a, 0xc65b, 0xc65c, 0xc65d, 0xc65e, 0xc65f, 0xc660, 0xc661, + 0xc662, 0xc663, 0xc664, 0xc665, 0xc666, 0xc667, 0xc668, 0xc669, + 0xc66a, 0xc66b, 0xc66c, 0xc66d, 0xc66e, 0xc66f, 0xc670, 0xc671, + 0xc672, 0xc673, 0xc674, 0xc675, 0xc676, 0xc677, 0xc678, 0xc679, + 0xc67a, 0xc67b, 0xc67c, 0xc67d, 0xc67e, 0xc680, 0xc681, 0xc682, + 0xc683, 0xc684, 0xc685, 0xc686, 0xc687, 0xc688, 0xc689, 0xc68a, + 0xc68b, 0xc68c, 0xc68d, 0xc68e, 0xc68f, 0xc690, 0xc691, 0xc692, + 0xc693, 0xc694, 0xc695, 0xc696, 0xc697, 0xc698, 0xc699, 0xc69a, + 0xc69b, 0xc69c, 0xc69d, 0xc69e, 0xc69f, 0xc6a0, 0xc740, 0xc741, + 0xc742, 0xc743, 0xc744, 0xc745, 0xc746, 0xc747, 0xc748, 0xc749, + 0xc74a, 0xc74b, 0xc74c, 0xc74d, 0xc74e, 0xc74f, 0xc750, 0xc751, + 0xc752, 0xc753, 0xc754, 0xc755, 0xc756, 0xc757, 0xc758, 0xc759, + 0xc75a, 0xc75b, 0xc75c, 0xc75d, 0xc75e, 0xc75f, 0xc760, 0xc761, + 0xc762, 0xc763, 0xc764, 0xc765, 0xc766, 0xc767, 0xc768, 0xc769, + 0xc76a, 0xc76b, 0xc76c, 0xc76d, 0xc76e, 0xc76f, 0xc770, 0xc771, + 0xc772, 0xc773, 0xc774, 0xc775, 0xc776, 0xc777, 0xc778, 0xc779, + 0xc77a, 0xc77b, 0xc77c, 0xc77d, 0xc77e, 0xc780, 0xc781, 0xc782, + 0xc783, 0xc784, 0xc785, 0xc786, 0xc787, 0xc788, 0xc789, 0xc78a, + 0xc78b, 0xc78c, 0xc78d, 0xc78e, 0xc78f, 0xc790, 0xc791, 0xc792, + 0xc793, 0xc794, 0xc795, 0xc796, 0xc797, 0xc798, 0xc799, 0xc79a, + 0xc79b, 0xc79c, 0xc79d, 0xc79e, 0xc79f, 0xc7a0, 0xc840, 0xc841, + 0xc842, 0xc843, 0xc844, 0xc845, 0xc846, 0xc847, 0xc848, 0xc849, + 0xc84a, 0xc84b, 0xc84c, 0xc84d, 0xc84e, 0xc84f, 0xc850, 0xc851, + 0xc852, 0xc853, 0xc854, 0xc855, 0xc856, 0xc857, 0xc858, 0xc859, + 0xc85a, 0xc85b, 0xc85c, 0xc85d, 0xc85e, 0xc85f, 0xc860, 0xc861, + 0xc862, 0xc863, 0xc864, 0xc865, 0xc866, 0xc867, 0xc868, 0xc869, + 0xc86a, 0xc86b, 0xc86c, 0xc86d, 0xc86e, 0xc86f, 0xc870, 0xc871, + 0xc872, 0xc873, 0xc874, 0xc875, 0xc876, 0xc877, 0xc878, 0xc879, + 0xc87a, 0xc87b, 0xc87c, 0xc87d, 0xc87e, 0xc880, 0xc881, 0xc882, + 0xc883, 0xc884, 0xc885, 0xc886, 0xc887, 0xc888, 0xc889, 0xc88a, + 0xc88b, 0xc88c, 0xc88d, 0xc88e, 0xc88f, 0xc890, 0xc891, 0xc892, + 0xc893, 0xc894, 0xc895, 0xc896, 0xc897, 0xc898, 0xc899, 0xc89a, + 0xc89b, 0xc89c, 0xc89d, 0xc89e, 0xc89f, 0xc8a0, 0xc940, 0xc941, + 0xc942, 0xc943, 0xc944, 0xc945, 0xc946, 0xc947, 0xc948, 0xc949, + 0xc94a, 0xc94b, 0xc94c, 0xc94d, 0xc94e, 0xc94f, 0xc950, 0xc951, + 0xc952, 0xc953, 0xc954, 0xc955, 0xc956, 0xc957, 0xc958, 0xc959, + 0xc95a, 0xc95b, 0xc95c, 0xc95d, 0xc95e, 0xc95f, 0xc960, 0xc961, + 0xc962, 0xc963, 0xc964, 0xc965, 0xc966, 0xc967, 0xc968, 0xc969, + 0xc96a, 0xc96b, 0xc96c, 0xc96d, 0xc96e, 0xc96f, 0xc970, 0xc971, + 0xc972, 0xc973, 0xc974, 0xc975, 0xc976, 0xc977, 0xc978, 0xc979, + 0xc97a, 0xc97b, 0xc97c, 0xc97d, 0xc97e, 0xc980, 0xc981, 0xc982, + 0xc983, 0xc984, 0xc985, 0xc986, 0xc987, 0xc988, 0xc989, 0xc98a, + 0xc98b, 0xc98c, 0xc98d, 0xc98e, 0xc98f, 0xc990, 0xc991, 0xc992, + 0xc993, 0xc994, 0xc995, 0xc996, 0xc997, 0xc998, 0xc999, 0xc99a, + 0xc99b, 0xc99c, 0xc99d, 0xc99e, 0xc99f, 0xc9a0, 0xca40, 0xca41, + 0xca42, 0xca43, 0xca44, 0xca45, 0xca46, 0xca47, 0xca48, 0xca49, + 0xca4a, 0xca4b, 0xca4c, 0xca4d, 0xca4e, 0xca4f, 0xca50, 0xca51, + 0xca52, 0xca53, 0xca54, 0xca55, 0xca56, 0xca57, 0xca58, 0xca59, + 0xca5a, 0xca5b, 0xca5c, 0xca5d, 0xca5e, 0xca5f, 0xca60, 0xca61, + 0xca62, 0xca63, 0xca64, 0xca65, 0xca66, 0xca67, 0xca68, 0xca69, + 0xca6a, 0xca6b, 0xca6c, 0xca6d, 0xca6e, 0xca6f, 0xca70, 0xca71, + 0xca72, 0xca73, 0xca74, 0xca75, 0xca76, 0xca77, 0xca78, 0xca79, + 0xca7a, 0xca7b, 0xca7c, 0xca7d, 0xca7e, 0xca80, 0xca81, 0xca82, + 0xca83, 0xca84, 0xca85, 0xca86, 0xca87, 0xca88, 0xca89, 0xca8a, + 0xca8b, 0xca8c, 0xca8d, 0xca8e, 0xca8f, 0xca90, 0xca91, 0xca92, + 0xca93, 0xca94, 0xca95, 0xca96, 0xca97, 0xca98, 0xca99, 0xca9a, + 0xca9b, 0xca9c, 0xca9d, 0xca9e, 0xca9f, 0xcaa0, 0xcb40, 0xcb41, + 0xcb42, 0xcb43, 0xcb44, 0xcb45, 0xcb46, 0xcb47, 0xcb48, 0xcb49, + 0xcb4a, 0xcb4b, 0xcb4c, 0xcb4d, 0xcb4e, 0xcb4f, 0xcb50, 0xcb51, + 0xcb52, 0xcb53, 0xcb54, 0xcb55, 0xcb56, 0xcb57, 0xcb58, 0xcb59, + 0xcb5a, 0xcb5b, 0xcb5c, 0xcb5d, 0xcb5e, 0xcb5f, 0xcb60, 0xcb61, + 0xcb62, 0xcb63, 0xcb64, 0xcb65, 0xcb66, 0xcb67, 0xcb68, 0xcb69, + 0xcb6a, 0xcb6b, 0xcb6c, 0xcb6d, 0xcb6e, 0xcb6f, 0xcb70, 0xcb71, + 0xcb72, 0xcb73, 0xcb74, 0xcb75, 0xcb76, 0xcb77, 0xcb78, 0xcb79, + 0xcb7a, 0xcb7b, 0xcb7c, 0xcb7d, 0xcb7e, 0xcb80, 0xcb81, 0xcb82, + 0xcb83, 0xcb84, 0xcb85, 0xcb86, 0xcb87, 0xcb88, 0xcb89, 0xcb8a, + 0xcb8b, 0xcb8c, 0xcb8d, 0xcb8e, 0xcb8f, 0xcb90, 0xcb91, 0xcb92, + 0xcb93, 0xcb94, 0xcb95, 0xcb96, 0xcb97, 0xcb98, 0xcb99, 0xcb9a, + 0xcb9b, 0xcb9c, 0xcb9d, 0xcb9e, 0xcb9f, 0xcba0, 0xcc40, 0xcc41, + 0xcc42, 0xcc43, 0xcc44, 0xcc45, 0xcc46, 0xcc47, 0xcc48, 0xcc49, + 0xcc4a, 0xcc4b, 0xcc4c, 0xcc4d, 0xcc4e, 0xcc4f, 0xcc50, 0xcc51, + 0xcc52, 0xcc53, 0xcc54, 0xcc55, 0xcc56, 0xcc57, 0xcc58, 0xcc59, + 0xcc5a, 0xcc5b, 0xcc5c, 0xcc5d, 0xcc5e, 0xcc5f, 0xcc60, 0xcc61, + 0xcc62, 0xcc63, 0xcc64, 0xcc65, 0xcc66, 0xcc67, 0xcc68, 0xcc69, + 0xcc6a, 0xcc6b, 0xcc6c, 0xcc6d, 0xcc6e, 0xcc6f, 0xcc70, 0xcc71, + 0xcc72, 0xcc73, 0xcc74, 0xcc75, 0xcc76, 0xcc77, 0xcc78, 0xcc79, + 0xcc7a, 0xcc7b, 0xcc7c, 0xcc7d, 0xcc7e, 0xcc80, 0xcc81, 0xcc82, + 0xcc83, 0xcc84, 0xcc85, 0xcc86, 0xcc87, 0xcc88, 0xcc89, 0xcc8a, + 0xcc8b, 0xcc8c, 0xcc8d, 0xcc8e, 0xcc8f, 0xcc90, 0xcc91, 0xcc92, + 0xcc93, 0xcc94, 0xcc95, 0xcc96, 0xcc97, 0xcc98, 0xcc99, 0xcc9a, + 0xcc9b, 0xcc9c, 0xcc9d, 0xcc9e, 0xcc9f, 0xcca0, 0xcd40, 0xcd41, + 0xcd42, 0xcd43, 0xcd44, 0xcd45, 0xcd46, 0xcd47, 0xcd48, 0xcd49, + 0xcd4a, 0xcd4b, 0xcd4c, 0xcd4d, 0xcd4e, 0xcd4f, 0xcd50, 0xcd51, + 0xcd52, 0xcd53, 0xcd54, 0xcd55, 0xcd56, 0xcd57, 0xcd58, 0xcd59, + 0xcd5a, 0xcd5b, 0xcd5c, 0xcd5d, 0xcd5e, 0xcd5f, 0xcd60, 0xcd61, + 0xcd62, 0xcd63, 0xcd64, 0xcd65, 0xcd66, 0xcd67, 0xcd68, 0xcd69, + 0xcd6a, 0xcd6b, 0xcd6c, 0xcd6d, 0xcd6e, 0xcd6f, 0xcd70, 0xcd71, + 0xcd72, 0xcd73, 0xcd74, 0xcd75, 0xcd76, 0xcd77, 0xcd78, 0xcd79, + 0xcd7a, 0xcd7b, 0xcd7c, 0xcd7d, 0xcd7e, 0xcd80, 0xcd81, 0xcd82, + 0xcd83, 0xcd84, 0xcd85, 0xcd86, 0xcd87, 0xcd88, 0xcd89, 0xcd8a, + 0xcd8b, 0xcd8c, 0xcd8d, 0xcd8e, 0xcd8f, 0xcd90, 0xcd91, 0xcd92, + 0xcd93, 0xcd94, 0xcd95, 0xcd96, 0xcd97, 0xcd98, 0xcd99, 0xcd9a, + 0xcd9b, 0xcd9c, 0xcd9d, 0xcd9e, 0xcd9f, 0xcda0, 0xce40, 0xce41, + 0xce42, 0xce43, 0xce44, 0xce45, 0xce46, 0xce47, 0xce48, 0xce49, + 0xce4a, 0xce4b, 0xce4c, 0xce4d, 0xce4e, 0xce4f, 0xce50, 0xce51, + 0xce52, 0xce53, 0xce54, 0xce55, 0xce56, 0xce57, 0xce58, 0xce59, + 0xce5a, 0xce5b, 0xce5c, 0xce5d, 0xce5e, 0xce5f, 0xce60, 0xce61, + 0xce62, 0xce63, 0xce64, 0xce65, 0xce66, 0xce67, 0xce68, 0xce69, + 0xce6a, 0xce6b, 0xce6c, 0xce6d, 0xce6e, 0xce6f, 0xce70, 0xce71, + 0xce72, 0xce73, 0xce74, 0xce75, 0xce76, 0xce77, 0xce78, 0xce79, + 0xce7a, 0xce7b, 0xce7c, 0xce7d, 0xce7e, 0xce80, 0xce81, 0xce82, + 0xce83, 0xce84, 0xce85, 0xce86, 0xce87, 0xce88, 0xce89, 0xce8a, + 0xce8b, 0xce8c, 0xce8d, 0xce8e, 0xce8f, 0xce90, 0xce91, 0xce92, + 0xce93, 0xce94, 0xce95, 0xce96, 0xce97, 0xce98, 0xce99, 0xce9a, + 0xce9b, 0xce9c, 0xce9d, 0xce9e, 0xce9f, 0xcea0, 0xcf40, 0xcf41, + 0xcf42, 0xcf43, 0xcf44, 0xcf45, 0xcf46, 0xcf47, 0xcf48, 0xcf49, + 0xcf4a, 0xcf4b, 0xcf4c, 0xcf4d, 0xcf4e, 0xcf4f, 0xcf50, 0xcf51, + 0xcf52, 0xcf53, 0xcf54, 0xcf55, 0xcf56, 0xcf57, 0xcf58, 0xcf59, + 0xcf5a, 0xcf5b, 0xcf5c, 0xcf5d, 0xcf5e, 0xcf5f, 0xcf60, 0xcf61, + 0xcf62, 0xcf63, 0xcf64, 0xcf65, 0xcf66, 0xcf67, 0xcf68, 0xcf69, + 0xcf6a, 0xcf6b, 0xcf6c, 0xcf6d, 0xcf6e, 0xcf6f, 0xcf70, 0xcf71, + 0xcf72, 0xcf73, 0xcf74, 0xcf75, 0xcf76, 0xcf77, 0xcf78, 0xcf79, + 0xcf7a, 0xcf7b, 0xcf7c, 0xcf7d, 0xcf7e, 0xcf80, 0xcf81, 0xcf82, + 0xcf83, 0xcf84, 0xcf85, 0xcf86, 0xcf87, 0xcf88, 0xcf89, 0xcf8a, + 0xcf8b, 0xcf8c, 0xcf8d, 0xcf8e, 0xcf8f, 0xcf90, 0xcf91, 0xcf92, + 0xcf93, 0xcf94, 0xcf95, 0xcf96, 0xcf97, 0xcf98, 0xcf99, 0xcf9a, + 0xcf9b, 0xcf9c, 0xcf9d, 0xcf9e, 0xcf9f, 0xcfa0, 0xd040, 0xd041, + 0xd042, 0xd043, 0xd044, 0xd045, 0xd046, 0xd047, 0xd048, 0xd049, + 0xd04a, 0xd04b, 0xd04c, 0xd04d, 0xd04e, 0xd04f, 0xd050, 0xd051, + 0xd052, 0xd053, 0xd054, 0xd055, 0xd056, 0xd057, 0xd058, 0xd059, + 0xd05a, 0xd05b, 0xd05c, 0xd05d, 0xd05e, 0xd05f, 0xd060, 0xd061, + 0xd062, 0xd063, 0xd064, 0xd065, 0xd066, 0xd067, 0xd068, 0xd069, + 0xd06a, 0xd06b, 0xd06c, 0xd06d, 0xd06e, 0xd06f, 0xd070, 0xd071, + 0xd072, 0xd073, 0xd074, 0xd075, 0xd076, 0xd077, 0xd078, 0xd079, + 0xd07a, 0xd07b, 0xd07c, 0xd07d, 0xd07e, 0xd080, 0xd081, 0xd082, + 0xd083, 0xd084, 0xd085, 0xd086, 0xd087, 0xd088, 0xd089, 0xd08a, + 0xd08b, 0xd08c, 0xd08d, 0xd08e, 0xd08f, 0xd090, 0xd091, 0xd092, + 0xd093, 0xd094, 0xd095, 0xd096, 0xd097, 0xd098, 0xd099, 0xd09a, + 0xd09b, 0xd09c, 0xd09d, 0xd09e, 0xd09f, 0xd0a0, 0xd140, 0xd141, + 0xd142, 0xd143, 0xd144, 0xd145, 0xd146, 0xd147, 0xd148, 0xd149, + 0xd14a, 0xd14b, 0xd14c, 0xd14d, 0xd14e, 0xd14f, 0xd150, 0xd151, + 0xd152, 0xd153, 0xd154, 0xd155, 0xd156, 0xd157, 0xd158, 0xd159, + 0xd15a, 0xd15b, 0xd15c, 0xd15d, 0xd15e, 0xd15f, 0xd160, 0xd161, + 0xd162, 0xd163, 0xd164, 0xd165, 0xd166, 0xd167, 0xd168, 0xd169, + 0xd16a, 0xd16b, 0xd16c, 0xd16d, 0xd16e, 0xd16f, 0xd170, 0xd171, + 0xd172, 0xd173, 0xd174, 0xd175, 0xd176, 0xd177, 0xd178, 0xd179, + 0xd17a, 0xd17b, 0xd17c, 0xd17d, 0xd17e, 0xd180, 0xd181, 0xd182, + 0xd183, 0xd184, 0xd185, 0xd186, 0xd187, 0xd188, 0xd189, 0xd18a, + 0xd18b, 0xd18c, 0xd18d, 0xd18e, 0xd18f, 0xd190, 0xd191, 0xd192, + 0xd193, 0xd194, 0xd195, 0xd196, 0xd197, 0xd198, 0xd199, 0xd19a, + 0xd19b, 0xd19c, 0xd19d, 0xd19e, 0xd19f, 0xd1a0, 0xd240, 0xd241, + 0xd242, 0xd243, 0xd244, 0xd245, 0xd246, 0xd247, 0xd248, 0xd249, + 0xd24a, 0xd24b, 0xd24c, 0xd24d, 0xd24e, 0xd24f, 0xd250, 0xd251, + 0xd252, 0xd253, 0xd254, 0xd255, 0xd256, 0xd257, 0xd258, 0xd259, + 0xd25a, 0xd25b, 0xd25c, 0xd25d, 0xd25e, 0xd25f, 0xd260, 0xd261, + 0xd262, 0xd263, 0xd264, 0xd265, 0xd266, 0xd267, 0xd268, 0xd269, + 0xd26a, 0xd26b, 0xd26c, 0xd26d, 0xd26e, 0xd26f, 0xd270, 0xd271, + 0xd272, 0xd273, 0xd274, 0xd275, 0xd276, 0xd277, 0xd278, 0xd279, + 0xd27a, 0xd27b, 0xd27c, 0xd27d, 0xd27e, 0xd280, 0xd281, 0xd282, + 0xd283, 0xd284, 0xd285, 0xd286, 0xd287, 0xd288, 0xd289, 0xd28a, + 0xd28b, 0xd28c, 0xd28d, 0xd28e, 0xd28f, 0xd290, 0xd291, 0xd292, + 0xd293, 0xd294, 0xd295, 0xd296, 0xd297, 0xd298, 0xd299, 0xd29a, + 0xd29b, 0xd29c, 0xd29d, 0xd29e, 0xd29f, 0xd2a0, 0xd340, 0xd341, + 0xd342, 0xd343, 0xd344, 0xd345, 0xd346, 0xd347, 0xd348, 0xd349, + 0xd34a, 0xd34b, 0xd34c, 0xd34d, 0xd34e, 0xd34f, 0xd350, 0xd351, + 0xd352, 0xd353, 0xd354, 0xd355, 0xd356, 0xd357, 0xd358, 0xd359, + 0xd35a, 0xd35b, 0xd35c, 0xd35d, 0xd35e, 0xd35f, 0xd360, 0xd361, + 0xd362, 0xd363, 0xd364, 0xd365, 0xd366, 0xd367, 0xd368, 0xd369, + 0xd36a, 0xd36b, 0xd36c, 0xd36d, 0xd36e, 0xd36f, 0xd370, 0xd371, + 0xd372, 0xd373, 0xd374, 0xd375, 0xd376, 0xd377, 0xd378, 0xd379, + 0xd37a, 0xd37b, 0xd37c, 0xd37d, 0xd37e, 0xd380, 0xd381, 0xd382, + 0xd383, 0xd384, 0xd385, 0xd386, 0xd387, 0xd388, 0xd389, 0xd38a, + 0xd38b, 0xd38c, 0xd38d, 0xd38e, 0xd38f, 0xd390, 0xd391, 0xd392, + 0xd393, 0xd394, 0xd395, 0xd396, 0xd397, 0xd398, 0xd399, 0xd39a, + 0xd39b, 0xd39c, 0xd39d, 0xd39e, 0xd39f, 0xd3a0, 0xd440, 0xd441, + 0xd442, 0xd443, 0xd444, 0xd445, 0xd446, 0xd447, 0xd448, 0xd449, + 0xd44a, 0xd44b, 0xd44c, 0xd44d, 0xd44e, 0xd44f, 0xd450, 0xd451, + 0xd452, 0xd453, 0xd454, 0xd455, 0xd456, 0xd457, 0xd458, 0xd459, + 0xd45a, 0xd45b, 0xd45c, 0xd45d, 0xd45e, 0xd45f, 0xd460, 0xd461, + 0xd462, 0xd463, 0xd464, 0xd465, 0xd466, 0xd467, 0xd468, 0xd469, + 0xd46a, 0xd46b, 0xd46c, 0xd46d, 0xd46e, 0xd46f, 0xd470, 0xd471, + 0xd472, 0xd473, 0xd474, 0xd475, 0xd476, 0xd477, 0xd478, 0xd479, + 0xd47a, 0xd47b, 0xd47c, 0xd47d, 0xd47e, 0xd480, 0xd481, 0xd482, + 0xd483, 0xd484, 0xd485, 0xd486, 0xd487, 0xd488, 0xd489, 0xd48a, + 0xd48b, 0xd48c, 0xd48d, 0xd48e, 0xd48f, 0xd490, 0xd491, 0xd492, + 0xd493, 0xd494, 0xd495, 0xd496, 0xd497, 0xd498, 0xd499, 0xd49a, + 0xd49b, 0xd49c, 0xd49d, 0xd49e, 0xd49f, 0xd4a0, 0xd540, 0xd541, + 0xd542, 0xd543, 0xd544, 0xd545, 0xd546, 0xd547, 0xd548, 0xd549, + 0xd54a, 0xd54b, 0xd54c, 0xd54d, 0xd54e, 0xd54f, 0xd550, 0xd551, + 0xd552, 0xd553, 0xd554, 0xd555, 0xd556, 0xd557, 0xd558, 0xd559, + 0xd55a, 0xd55b, 0xd55c, 0xd55d, 0xd55e, 0xd55f, 0xd560, 0xd561, + 0xd562, 0xd563, 0xd564, 0xd565, 0xd566, 0xd567, 0xd568, 0xd569, + 0xd56a, 0xd56b, 0xd56c, 0xd56d, 0xd56e, 0xd56f, 0xd570, 0xd571, + 0xd572, 0xd573, 0xd574, 0xd575, 0xd576, 0xd577, 0xd578, 0xd579, + 0xd57a, 0xd57b, 0xd57c, 0xd57d, 0xd57e, 0xd580, 0xd581, 0xd582, + 0xd583, 0xd584, 0xd585, 0xd586, 0xd587, 0xd588, 0xd589, 0xd58a, + 0xd58b, 0xd58c, 0xd58d, 0xd58e, 0xd58f, 0xd590, 0xd591, 0xd592, + 0xd593, 0xd594, 0xd595, 0xd596, 0xd597, 0xd598, 0xd599, 0xd59a, + 0xd59b, 0xd59c, 0xd59d, 0xd59e, 0xd59f, 0xd5a0, 0xd640, 0xd641, + 0xd642, 0xd643, 0xd644, 0xd645, 0xd646, 0xd647, 0xd648, 0xd649, + 0xd64a, 0xd64b, 0xd64c, 0xd64d, 0xd64e, 0xd64f, 0xd650, 0xd651, + 0xd652, 0xd653, 0xd654, 0xd655, 0xd656, 0xd657, 0xd658, 0xd659, + 0xd65a, 0xd65b, 0xd65c, 0xd65d, 0xd65e, 0xd65f, 0xd660, 0xd661, + 0xd662, 0xd663, 0xd664, 0xd665, 0xd666, 0xd667, 0xd668, 0xd669, + 0xd66a, 0xd66b, 0xd66c, 0xd66d, 0xd66e, 0xd66f, 0xd670, 0xd671, + 0xd672, 0xd673, 0xd674, 0xd675, 0xd676, 0xd677, 0xd678, 0xd679, + 0xd67a, 0xd67b, 0xd67c, 0xd67d, 0xd67e, 0xd680, 0xd681, 0xd682, + 0xd683, 0xd684, 0xd685, 0xd686, 0xd687, 0xd688, 0xd689, 0xd68a, + 0xd68b, 0xd68c, 0xd68d, 0xd68e, 0xd68f, 0xd690, 0xd691, 0xd692, + 0xd693, 0xd694, 0xd695, 0xd696, 0xd697, 0xd698, 0xd699, 0xd69a, + 0xd69b, 0xd69c, 0xd69d, 0xd69e, 0xd69f, 0xd6a0, 0xd740, 0xd741, + 0xd742, 0xd743, 0xd744, 0xd745, 0xd746, 0xd747, 0xd748, 0xd749, + 0xd74a, 0xd74b, 0xd74c, 0xd74d, 0xd74e, 0xd74f, 0xd750, 0xd751, + 0xd752, 0xd753, 0xd754, 0xd755, 0xd756, 0xd757, 0xd758, 0xd759, + 0xd75a, 0xd75b, 0xd75c, 0xd75d, 0xd75e, 0xd75f, 0xd760, 0xd761, + 0xd762, 0xd763, 0xd764, 0xd765, 0xd766, 0xd767, 0xd768, 0xd769, + 0xd76a, 0xd76b, 0xd76c, 0xd76d, 0xd76e, 0xd76f, 0xd770, 0xd771, + 0xd772, 0xd773, 0xd774, 0xd775, 0xd776, 0xd777, 0xd778, 0xd779, + 0xd77a, 0xd77b, 0xd77c, 0xd77d, 0xd77e, 0xd780, 0xd781, 0xd782, + 0xd783, 0xd784, 0xd785, 0xd786, 0xd787, 0xd788, 0xd789, 0xd78a, + 0xd78b, 0xd78c, 0xd78d, 0xd78e, 0xd78f, 0xd790, 0xd791, 0xd792, + 0xd793, 0xd794, 0xd795, 0xd796, 0xd797, 0xd798, 0xd799, 0xd79a, + 0xd79b, 0xd79c, 0xd79d, 0xd79e, 0xd79f, 0xd7a0, 0xd840, 0xd841, + 0xd842, 0xd843, 0xd844, 0xd845, 0xd846, 0xd847, 0xd848, 0xd849, + 0xd84a, 0xd84b, 0xd84c, 0xd84d, 0xd84e, 0xd84f, 0xd850, 0xd851, + 0xd852, 0xd853, 0xd854, 0xd855, 0xd856, 0xd857, 0xd858, 0xd859, + 0xd85a, 0xd85b, 0xd85c, 0xd85d, 0xd85e, 0xd85f, 0xd860, 0xd861, + 0xd862, 0xd863, 0xd864, 0xd865, 0xd866, 0xd867, 0xd868, 0xd869, + 0xd86a, 0xd86b, 0xd86c, 0xd86d, 0xd86e, 0xd86f, 0xd870, 0xd871, + 0xd872, 0xd873, 0xd874, 0xd875, 0xd876, 0xd877, 0xd878, 0xd879, + 0xd87a, 0xd87b, 0xd87c, 0xd87d, 0xd87e, 0xd880, 0xd881, 0xd882, + 0xd883, 0xd884, 0xd885, 0xd886, 0xd887, 0xd888, 0xd889, 0xd88a, + 0xd88b, 0xd88c, 0xd88d, 0xd88e, 0xd88f, 0xd890, 0xd891, 0xd892, + 0xd893, 0xd894, 0xd895, 0xd896, 0xd897, 0xd898, 0xd899, 0xd89a, + 0xd89b, 0xd89c, 0xd89d, 0xd89e, 0xd89f, 0xd8a0, 0xd940, 0xd941, + 0xd942, 0xd943, 0xd944, 0xd945, 0xd946, 0xd947, 0xd948, 0xd949, + 0xd94a, 0xd94b, 0xd94c, 0xd94d, 0xd94e, 0xd94f, 0xd950, 0xd951, + 0xd952, 0xd953, 0xd954, 0xd955, 0xd956, 0xd957, 0xd958, 0xd959, + 0xd95a, 0xd95b, 0xd95c, 0xd95d, 0xd95e, 0xd95f, 0xd960, 0xd961, + 0xd962, 0xd963, 0xd964, 0xd965, 0xd966, 0xd967, 0xd968, 0xd969, + 0xd96a, 0xd96b, 0xd96c, 0xd96d, 0xd96e, 0xd96f, 0xd970, 0xd971, + 0xd972, 0xd973, 0xd974, 0xd975, 0xd976, 0xd977, 0xd978, 0xd979, + 0xd97a, 0xd97b, 0xd97c, 0xd97d, 0xd97e, 0xd980, 0xd981, 0xd982, + 0xd983, 0xd984, 0xd985, 0xd986, 0xd987, 0xd988, 0xd989, 0xd98a, + 0xd98b, 0xd98c, 0xd98d, 0xd98e, 0xd98f, 0xd990, 0xd991, 0xd992, + 0xd993, 0xd994, 0xd995, 0xd996, 0xd997, 0xd998, 0xd999, 0xd99a, + 0xd99b, 0xd99c, 0xd99d, 0xd99e, 0xd99f, 0xd9a0, 0xda40, 0xda41, + 0xda42, 0xda43, 0xda44, 0xda45, 0xda46, 0xda47, 0xda48, 0xda49, + 0xda4a, 0xda4b, 0xda4c, 0xda4d, 0xda4e, 0xda4f, 0xda50, 0xda51, + 0xda52, 0xda53, 0xda54, 0xda55, 0xda56, 0xda57, 0xda58, 0xda59, + 0xda5a, 0xda5b, 0xda5c, 0xda5d, 0xda5e, 0xda5f, 0xda60, 0xda61, + 0xda62, 0xda63, 0xda64, 0xda65, 0xda66, 0xda67, 0xda68, 0xda69, + 0xda6a, 0xda6b, 0xda6c, 0xda6d, 0xda6e, 0xda6f, 0xda70, 0xda71, + 0xda72, 0xda73, 0xda74, 0xda75, 0xda76, 0xda77, 0xda78, 0xda79, + 0xda7a, 0xda7b, 0xda7c, 0xda7d, 0xda7e, 0xda80, 0xda81, 0xda82, + 0xda83, 0xda84, 0xda85, 0xda86, 0xda87, 0xda88, 0xda89, 0xda8a, + 0xda8b, 0xda8c, 0xda8d, 0xda8e, 0xda8f, 0xda90, 0xda91, 0xda92, + 0xda93, 0xda94, 0xda95, 0xda96, 0xda97, 0xda98, 0xda99, 0xda9a, + 0xda9b, 0xda9c, 0xda9d, 0xda9e, 0xda9f, 0xdaa0, 0xdb40, 0xdb41, + 0xdb42, 0xdb43, 0xdb44, 0xdb45, 0xdb46, 0xdb47, 0xdb48, 0xdb49, + 0xdb4a, 0xdb4b, 0xdb4c, 0xdb4d, 0xdb4e, 0xdb4f, 0xdb50, 0xdb51, + 0xdb52, 0xdb53, 0xdb54, 0xdb55, 0xdb56, 0xdb57, 0xdb58, 0xdb59, + 0xdb5a, 0xdb5b, 0xdb5c, 0xdb5d, 0xdb5e, 0xdb5f, 0xdb60, 0xdb61, + 0xdb62, 0xdb63, 0xdb64, 0xdb65, 0xdb66, 0xdb67, 0xdb68, 0xdb69, + 0xdb6a, 0xdb6b, 0xdb6c, 0xdb6d, 0xdb6e, 0xdb6f, 0xdb70, 0xdb71, + 0xdb72, 0xdb73, 0xdb74, 0xdb75, 0xdb76, 0xdb77, 0xdb78, 0xdb79, + 0xdb7a, 0xdb7b, 0xdb7c, 0xdb7d, 0xdb7e, 0xdb80, 0xdb81, 0xdb82, + 0xdb83, 0xdb84, 0xdb85, 0xdb86, 0xdb87, 0xdb88, 0xdb89, 0xdb8a, + 0xdb8b, 0xdb8c, 0xdb8d, 0xdb8e, 0xdb8f, 0xdb90, 0xdb91, 0xdb92, + 0xdb93, 0xdb94, 0xdb95, 0xdb96, 0xdb97, 0xdb98, 0xdb99, 0xdb9a, + 0xdb9b, 0xdb9c, 0xdb9d, 0xdb9e, 0xdb9f, 0xdba0, 0xdc40, 0xdc41, + 0xdc42, 0xdc43, 0xdc44, 0xdc45, 0xdc46, 0xdc47, 0xdc48, 0xdc49, + 0xdc4a, 0xdc4b, 0xdc4c, 0xdc4d, 0xdc4e, 0xdc4f, 0xdc50, 0xdc51, + 0xdc52, 0xdc53, 0xdc54, 0xdc55, 0xdc56, 0xdc57, 0xdc58, 0xdc59, + 0xdc5a, 0xdc5b, 0xdc5c, 0xdc5d, 0xdc5e, 0xdc5f, 0xdc60, 0xdc61, + 0xdc62, 0xdc63, 0xdc64, 0xdc65, 0xdc66, 0xdc67, 0xdc68, 0xdc69, + 0xdc6a, 0xdc6b, 0xdc6c, 0xdc6d, 0xdc6e, 0xdc6f, 0xdc70, 0xdc71, + 0xdc72, 0xdc73, 0xdc74, 0xdc75, 0xdc76, 0xdc77, 0xdc78, 0xdc79, + 0xdc7a, 0xdc7b, 0xdc7c, 0xdc7d, 0xdc7e, 0xdc80, 0xdc81, 0xdc82, + 0xdc83, 0xdc84, 0xdc85, 0xdc86, 0xdc87, 0xdc88, 0xdc89, 0xdc8a, + 0xdc8b, 0xdc8c, 0xdc8d, 0xdc8e, 0xdc8f, 0xdc90, 0xdc91, 0xdc92, + 0xdc93, 0xdc94, 0xdc95, 0xdc96, 0xdc97, 0xdc98, 0xdc99, 0xdc9a, + 0xdc9b, 0xdc9c, 0xdc9d, 0xdc9e, 0xdc9f, 0xdca0, 0xdd40, 0xdd41, + 0xdd42, 0xdd43, 0xdd44, 0xdd45, 0xdd46, 0xdd47, 0xdd48, 0xdd49, + 0xdd4a, 0xdd4b, 0xdd4c, 0xdd4d, 0xdd4e, 0xdd4f, 0xdd50, 0xdd51, + 0xdd52, 0xdd53, 0xdd54, 0xdd55, 0xdd56, 0xdd57, 0xdd58, 0xdd59, + 0xdd5a, 0xdd5b, 0xdd5c, 0xdd5d, 0xdd5e, 0xdd5f, 0xdd60, 0xdd61, + 0xdd62, 0xdd63, 0xdd64, 0xdd65, 0xdd66, 0xdd67, 0xdd68, 0xdd69, + 0xdd6a, 0xdd6b, 0xdd6c, 0xdd6d, 0xdd6e, 0xdd6f, 0xdd70, 0xdd71, + 0xdd72, 0xdd73, 0xdd74, 0xdd75, 0xdd76, 0xdd77, 0xdd78, 0xdd79, + 0xdd7a, 0xdd7b, 0xdd7c, 0xdd7d, 0xdd7e, 0xdd80, 0xdd81, 0xdd82, + 0xdd83, 0xdd84, 0xdd85, 0xdd86, 0xdd87, 0xdd88, 0xdd89, 0xdd8a, + 0xdd8b, 0xdd8c, 0xdd8d, 0xdd8e, 0xdd8f, 0xdd90, 0xdd91, 0xdd92, + 0xdd93, 0xdd94, 0xdd95, 0xdd96, 0xdd97, 0xdd98, 0xdd99, 0xdd9a, + 0xdd9b, 0xdd9c, 0xdd9d, 0xdd9e, 0xdd9f, 0xdda0, 0xde40, 0xde41, + 0xde42, 0xde43, 0xde44, 0xde45, 0xde46, 0xde47, 0xde48, 0xde49, + 0xde4a, 0xde4b, 0xde4c, 0xde4d, 0xde4e, 0xde4f, 0xde50, 0xde51, + 0xde52, 0xde53, 0xde54, 0xde55, 0xde56, 0xde57, 0xde58, 0xde59, + 0xde5a, 0xde5b, 0xde5c, 0xde5d, 0xde5e, 0xde5f, 0xde60, 0xde61, + 0xde62, 0xde63, 0xde64, 0xde65, 0xde66, 0xde67, 0xde68, 0xde69, + 0xde6a, 0xde6b, 0xde6c, 0xde6d, 0xde6e, 0xde6f, 0xde70, 0xde71, + 0xde72, 0xde73, 0xde74, 0xde75, 0xde76, 0xde77, 0xde78, 0xde79, + 0xde7a, 0xde7b, 0xde7c, 0xde7d, 0xde7e, 0xde80, 0xde81, 0xde82, + 0xde83, 0xde84, 0xde85, 0xde86, 0xde87, 0xde88, 0xde89, 0xde8a, + 0xde8b, 0xde8c, 0xde8d, 0xde8e, 0xde8f, 0xde90, 0xde91, 0xde92, + 0xde93, 0xde94, 0xde95, 0xde96, 0xde97, 0xde98, 0xde99, 0xde9a, + 0xde9b, 0xde9c, 0xde9d, 0xde9e, 0xde9f, 0xdea0, 0xdf40, 0xdf41, + 0xdf42, 0xdf43, 0xdf44, 0xdf45, 0xdf46, 0xdf47, 0xdf48, 0xdf49, + 0xdf4a, 0xdf4b, 0xdf4c, 0xdf4d, 0xdf4e, 0xdf4f, 0xdf50, 0xdf51, + 0xdf52, 0xdf53, 0xdf54, 0xdf55, 0xdf56, 0xdf57, 0xdf58, 0xdf59, + 0xdf5a, 0xdf5b, 0xdf5c, 0xdf5d, 0xdf5e, 0xdf5f, 0xdf60, 0xdf61, + 0xdf62, 0xdf63, 0xdf64, 0xdf65, 0xdf66, 0xdf67, 0xdf68, 0xdf69, + 0xdf6a, 0xdf6b, 0xdf6c, 0xdf6d, 0xdf6e, 0xdf6f, 0xdf70, 0xdf71, + 0xdf72, 0xdf73, 0xdf74, 0xdf75, 0xdf76, 0xdf77, 0xdf78, 0xdf79, + 0xdf7a, 0xdf7b, 0xdf7c, 0xdf7d, 0xdf7e, 0xdf80, 0xdf81, 0xdf82, + 0xdf83, 0xdf84, 0xdf85, 0xdf86, 0xdf87, 0xdf88, 0xdf89, 0xdf8a, + 0xdf8b, 0xdf8c, 0xdf8d, 0xdf8e, 0xdf8f, 0xdf90, 0xdf91, 0xdf92, + 0xdf93, 0xdf94, 0xdf95, 0xdf96, 0xdf97, 0xdf98, 0xdf99, 0xdf9a, + 0xdf9b, 0xdf9c, 0xdf9d, 0xdf9e, 0xdf9f, 0xdfa0, 0xe040, 0xe041, + 0xe042, 0xe043, 0xe044, 0xe045, 0xe046, 0xe047, 0xe048, 0xe049, + 0xe04a, 0xe04b, 0xe04c, 0xe04d, 0xe04e, 0xe04f, 0xe050, 0xe051, + 0xe052, 0xe053, 0xe054, 0xe055, 0xe056, 0xe057, 0xe058, 0xe059, + 0xe05a, 0xe05b, 0xe05c, 0xe05d, 0xe05e, 0xe05f, 0xe060, 0xe061, + 0xe062, 0xe063, 0xe064, 0xe065, 0xe066, 0xe067, 0xe068, 0xe069, + 0xe06a, 0xe06b, 0xe06c, 0xe06d, 0xe06e, 0xe06f, 0xe070, 0xe071, + 0xe072, 0xe073, 0xe074, 0xe075, 0xe076, 0xe077, 0xe078, 0xe079, + 0xe07a, 0xe07b, 0xe07c, 0xe07d, 0xe07e, 0xe080, 0xe081, 0xe082, + 0xe083, 0xe084, 0xe085, 0xe086, 0xe087, 0xe088, 0xe089, 0xe08a, + 0xe08b, 0xe08c, 0xe08d, 0xe08e, 0xe08f, 0xe090, 0xe091, 0xe092, + 0xe093, 0xe094, 0xe095, 0xe096, 0xe097, 0xe098, 0xe099, 0xe09a, + 0xe09b, 0xe09c, 0xe09d, 0xe09e, 0xe09f, 0xe0a0, 0xe140, 0xe141, + 0xe142, 0xe143, 0xe144, 0xe145, 0xe146, 0xe147, 0xe148, 0xe149, + 0xe14a, 0xe14b, 0xe14c, 0xe14d, 0xe14e, 0xe14f, 0xe150, 0xe151, + 0xe152, 0xe153, 0xe154, 0xe155, 0xe156, 0xe157, 0xe158, 0xe159, + 0xe15a, 0xe15b, 0xe15c, 0xe15d, 0xe15e, 0xe15f, 0xe160, 0xe161, + 0xe162, 0xe163, 0xe164, 0xe165, 0xe166, 0xe167, 0xe168, 0xe169, + 0xe16a, 0xe16b, 0xe16c, 0xe16d, 0xe16e, 0xe16f, 0xe170, 0xe171, + 0xe172, 0xe173, 0xe174, 0xe175, 0xe176, 0xe177, 0xe178, 0xe179, + 0xe17a, 0xe17b, 0xe17c, 0xe17d, 0xe17e, 0xe180, 0xe181, 0xe182, + 0xe183, 0xe184, 0xe185, 0xe186, 0xe187, 0xe188, 0xe189, 0xe18a, + 0xe18b, 0xe18c, 0xe18d, 0xe18e, 0xe18f, 0xe190, 0xe191, 0xe192, + 0xe193, 0xe194, 0xe195, 0xe196, 0xe197, 0xe198, 0xe199, 0xe19a, + 0xe19b, 0xe19c, 0xe19d, 0xe19e, 0xe19f, 0xe1a0, 0xe240, 0xe241, + 0xe242, 0xe243, 0xe244, 0xe245, 0xe246, 0xe247, 0xe248, 0xe249, + 0xe24a, 0xe24b, 0xe24c, 0xe24d, 0xe24e, 0xe24f, 0xe250, 0xe251, + 0xe252, 0xe253, 0xe254, 0xe255, 0xe256, 0xe257, 0xe258, 0xe259, + 0xe25a, 0xe25b, 0xe25c, 0xe25d, 0xe25e, 0xe25f, 0xe260, 0xe261, + 0xe262, 0xe263, 0xe264, 0xe265, 0xe266, 0xe267, 0xe268, 0xe269, + 0xe26a, 0xe26b, 0xe26c, 0xe26d, 0xe26e, 0xe26f, 0xe270, 0xe271, + 0xe272, 0xe273, 0xe274, 0xe275, 0xe276, 0xe277, 0xe278, 0xe279, + 0xe27a, 0xe27b, 0xe27c, 0xe27d, 0xe27e, 0xe280, 0xe281, 0xe282, + 0xe283, 0xe284, 0xe285, 0xe286, 0xe287, 0xe288, 0xe289, 0xe28a, + 0xe28b, 0xe28c, 0xe28d, 0xe28e, 0xe28f, 0xe290, 0xe291, 0xe292, + 0xe293, 0xe294, 0xe295, 0xe296, 0xe297, 0xe298, 0xe299, 0xe29a, + 0xe29b, 0xe29c, 0xe29d, 0xe29e, 0xe29f, 0xe2a0, 0xe340, 0xe341, + 0xe342, 0xe343, 0xe344, 0xe345, 0xe346, 0xe347, 0xe348, 0xe349, + 0xe34a, 0xe34b, 0xe34c, 0xe34d, 0xe34e, 0xe34f, 0xe350, 0xe351, + 0xe352, 0xe353, 0xe354, 0xe355, 0xe356, 0xe357, 0xe358, 0xe359, + 0xe35a, 0xe35b, 0xe35c, 0xe35d, 0xe35e, 0xe35f, 0xe360, 0xe361, + 0xe362, 0xe363, 0xe364, 0xe365, 0xe366, 0xe367, 0xe368, 0xe369, + 0xe36a, 0xe36b, 0xe36c, 0xe36d, 0xe36e, 0xe36f, 0xe370, 0xe371, + 0xe372, 0xe373, 0xe374, 0xe375, 0xe376, 0xe377, 0xe378, 0xe379, + 0xe37a, 0xe37b, 0xe37c, 0xe37d, 0xe37e, 0xe380, 0xe381, 0xe382, + 0xe383, 0xe384, 0xe385, 0xe386, 0xe387, 0xe388, 0xe389, 0xe38a, + 0xe38b, 0xe38c, 0xe38d, 0xe38e, 0xe38f, 0xe390, 0xe391, 0xe392, + 0xe393, 0xe394, 0xe395, 0xe396, 0xe397, 0xe398, 0xe399, 0xe39a, + 0xe39b, 0xe39c, 0xe39d, 0xe39e, 0xe39f, 0xe3a0, 0xe440, 0xe441, + 0xe442, 0xe443, 0xe444, 0xe445, 0xe446, 0xe447, 0xe448, 0xe449, + 0xe44a, 0xe44b, 0xe44c, 0xe44d, 0xe44e, 0xe44f, 0xe450, 0xe451, + 0xe452, 0xe453, 0xe454, 0xe455, 0xe456, 0xe457, 0xe458, 0xe459, + 0xe45a, 0xe45b, 0xe45c, 0xe45d, 0xe45e, 0xe45f, 0xe460, 0xe461, + 0xe462, 0xe463, 0xe464, 0xe465, 0xe466, 0xe467, 0xe468, 0xe469, + 0xe46a, 0xe46b, 0xe46c, 0xe46d, 0xe46e, 0xe46f, 0xe470, 0xe471, + 0xe472, 0xe473, 0xe474, 0xe475, 0xe476, 0xe477, 0xe478, 0xe479, + 0xe47a, 0xe47b, 0xe47c, 0xe47d, 0xe47e, 0xe480, 0xe481, 0xe482, + 0xe483, 0xe484, 0xe485, 0xe486, 0xe487, 0xe488, 0xe489, 0xe48a, + 0xe48b, 0xe48c, 0xe48d, 0xe48e, 0xe48f, 0xe490, 0xe491, 0xe492, + 0xe493, 0xe494, 0xe495, 0xe496, 0xe497, 0xe498, 0xe499, 0xe49a, + 0xe49b, 0xe49c, 0xe49d, 0xe49e, 0xe49f, 0xe4a0, 0xe540, 0xe541, + 0xe542, 0xe543, 0xe544, 0xe545, 0xe546, 0xe547, 0xe548, 0xe549, + 0xe54a, 0xe54b, 0xe54c, 0xe54d, 0xe54e, 0xe54f, 0xe550, 0xe551, + 0xe552, 0xe553, 0xe554, 0xe555, 0xe556, 0xe557, 0xe558, 0xe559, + 0xe55a, 0xe55b, 0xe55c, 0xe55d, 0xe55e, 0xe55f, 0xe560, 0xe561, + 0xe562, 0xe563, 0xe564, 0xe565, 0xe566, 0xe567, 0xe568, 0xe569, + 0xe56a, 0xe56b, 0xe56c, 0xe56d, 0xe56e, 0xe56f, 0xe570, 0xe571, + 0xe572, 0xe573, 0xe574, 0xe575, 0xe576, 0xe577, 0xe578, 0xe579, + 0xe57a, 0xe57b, 0xe57c, 0xe57d, 0xe57e, 0xe580, 0xe581, 0xe582, + 0xe583, 0xe584, 0xe585, 0xe586, 0xe587, 0xe588, 0xe589, 0xe58a, + 0xe58b, 0xe58c, 0xe58d, 0xe58e, 0xe58f, 0xe590, 0xe591, 0xe592, + 0xe593, 0xe594, 0xe595, 0xe596, 0xe597, 0xe598, 0xe599, 0xe59a, + 0xe59b, 0xe59c, 0xe59d, 0xe59e, 0xe59f, 0xe5a0, 0xe640, 0xe641, + 0xe642, 0xe643, 0xe644, 0xe645, 0xe646, 0xe647, 0xe648, 0xe649, + 0xe64a, 0xe64b, 0xe64c, 0xe64d, 0xe64e, 0xe64f, 0xe650, 0xe651, + 0xe652, 0xe653, 0xe654, 0xe655, 0xe656, 0xe657, 0xe658, 0xe659, + 0xe65a, 0xe65b, 0xe65c, 0xe65d, 0xe65e, 0xe65f, 0xe660, 0xe661, + 0xe662, 0xe663, 0xe664, 0xe665, 0xe666, 0xe667, 0xe668, 0xe669, + 0xe66a, 0xe66b, 0xe66c, 0xe66d, 0xe66e, 0xe66f, 0xe670, 0xe671, + 0xe672, 0xe673, 0xe674, 0xe675, 0xe676, 0xe677, 0xe678, 0xe679, + 0xe67a, 0xe67b, 0xe67c, 0xe67d, 0xe67e, 0xe680, 0xe681, 0xe682, + 0xe683, 0xe684, 0xe685, 0xe686, 0xe687, 0xe688, 0xe689, 0xe68a, + 0xe68b, 0xe68c, 0xe68d, 0xe68e, 0xe68f, 0xe690, 0xe691, 0xe692, + 0xe693, 0xe694, 0xe695, 0xe696, 0xe697, 0xe698, 0xe699, 0xe69a, + 0xe69b, 0xe69c, 0xe69d, 0xe69e, 0xe69f, 0xe6a0, 0xe740, 0xe741, + 0xe742, 0xe743, 0xe744, 0xe745, 0xe746, 0xe747, 0xe748, 0xe749, + 0xe74a, 0xe74b, 0xe74c, 0xe74d, 0xe74e, 0xe74f, 0xe750, 0xe751, + 0xe752, 0xe753, 0xe754, 0xe755, 0xe756, 0xe757, 0xe758, 0xe759, + 0xe75a, 0xe75b, 0xe75c, 0xe75d, 0xe75e, 0xe75f, 0xe760, 0xe761, + 0xe762, 0xe763, 0xe764, 0xe765, 0xe766, 0xe767, 0xe768, 0xe769, + 0xe76a, 0xe76b, 0xe76c, 0xe76d, 0xe76e, 0xe76f, 0xe770, 0xe771, + 0xe772, 0xe773, 0xe774, 0xe775, 0xe776, 0xe777, 0xe778, 0xe779, + 0xe77a, 0xe77b, 0xe77c, 0xe77d, 0xe77e, 0xe780, 0xe781, 0xe782, + 0xe783, 0xe784, 0xe785, 0xe786, 0xe787, 0xe788, 0xe789, 0xe78a, + 0xe78b, 0xe78c, 0xe78d, 0xe78e, 0xe78f, 0xe790, 0xe791, 0xe792, + 0xe793, 0xe794, 0xe795, 0xe796, 0xe797, 0xe798, 0xe799, 0xe79a, + 0xe79b, 0xe79c, 0xe79d, 0xe79e, 0xe79f, 0xe7a0, 0xe840, 0xe841, + 0xe842, 0xe843, 0xe844, 0xe845, 0xe846, 0xe847, 0xe848, 0xe849, + 0xe84a, 0xe84b, 0xe84c, 0xe84d, 0xe84e, 0xe84f, 0xe850, 0xe851, + 0xe852, 0xe853, 0xe854, 0xe855, 0xe856, 0xe857, 0xe858, 0xe859, + 0xe85a, 0xe85b, 0xe85c, 0xe85d, 0xe85e, 0xe85f, 0xe860, 0xe861, + 0xe862, 0xe863, 0xe864, 0xe865, 0xe866, 0xe867, 0xe868, 0xe869, + 0xe86a, 0xe86b, 0xe86c, 0xe86d, 0xe86e, 0xe86f, 0xe870, 0xe871, + 0xe872, 0xe873, 0xe874, 0xe875, 0xe876, 0xe877, 0xe878, 0xe879, + 0xe87a, 0xe87b, 0xe87c, 0xe87d, 0xe87e, 0xe880, 0xe881, 0xe882, + 0xe883, 0xe884, 0xe885, 0xe886, 0xe887, 0xe888, 0xe889, 0xe88a, + 0xe88b, 0xe88c, 0xe88d, 0xe88e, 0xe88f, 0xe890, 0xe891, 0xe892, + 0xe893, 0xe894, 0xe895, 0xe896, 0xe897, 0xe898, 0xe899, 0xe89a, + 0xe89b, 0xe89c, 0xe89d, 0xe89e, 0xe89f, 0xe8a0, 0xe940, 0xe941, + 0xe942, 0xe943, 0xe944, 0xe945, 0xe946, 0xe947, 0xe948, 0xe949, + 0xe94a, 0xe94b, 0xe94c, 0xe94d, 0xe94e, 0xe94f, 0xe950, 0xe951, + 0xe952, 0xe953, 0xe954, 0xe955, 0xe956, 0xe957, 0xe958, 0xe959, + 0xe95a, 0xe95b, 0xe95c, 0xe95d, 0xe95e, 0xe95f, 0xe960, 0xe961, + 0xe962, 0xe963, 0xe964, 0xe965, 0xe966, 0xe967, 0xe968, 0xe969, + 0xe96a, 0xe96b, 0xe96c, 0xe96d, 0xe96e, 0xe96f, 0xe970, 0xe971, + 0xe972, 0xe973, 0xe974, 0xe975, 0xe976, 0xe977, 0xe978, 0xe979, + 0xe97a, 0xe97b, 0xe97c, 0xe97d, 0xe97e, 0xe980, 0xe981, 0xe982, + 0xe983, 0xe984, 0xe985, 0xe986, 0xe987, 0xe988, 0xe989, 0xe98a, + 0xe98b, 0xe98c, 0xe98d, 0xe98e, 0xe98f, 0xe990, 0xe991, 0xe992, + 0xe993, 0xe994, 0xe995, 0xe996, 0xe997, 0xe998, 0xe999, 0xe99a, + 0xe99b, 0xe99c, 0xe99d, 0xe99e, 0xe99f, 0xe9a0, 0xea40, 0xea41, + 0xea42, 0xea43, 0xea44, 0xea45, 0xea46, 0xea47, 0xea48, 0xea49, + 0xea4a, 0xea4b, 0xea4c, 0xea4d, 0xea4e, 0xea4f, 0xea50, 0xea51, + 0xea52, 0xea53, 0xea54, 0xea55, 0xea56, 0xea57, 0xea58, 0xea59, + 0xea5a, 0xea5b, 0xea5c, 0xea5d, 0xea5e, 0xea5f, 0xea60, 0xea61, + 0xea62, 0xea63, 0xea64, 0xea65, 0xea66, 0xea67, 0xea68, 0xea69, + 0xea6a, 0xea6b, 0xea6c, 0xea6d, 0xea6e, 0xea6f, 0xea70, 0xea71, + 0xea72, 0xea73, 0xea74, 0xea75, 0xea76, 0xea77, 0xea78, 0xea79, + 0xea7a, 0xea7b, 0xea7c, 0xea7d, 0xea7e, 0xea80, 0xea81, 0xea82, + 0xea83, 0xea84, 0xea85, 0xea86, 0xea87, 0xea88, 0xea89, 0xea8a, + 0xea8b, 0xea8c, 0xea8d, 0xea8e, 0xea8f, 0xea90, 0xea91, 0xea92, + 0xea93, 0xea94, 0xea95, 0xea96, 0xea97, 0xea98, 0xea99, 0xea9a, + 0xea9b, 0xea9c, 0xea9d, 0xea9e, 0xea9f, 0xeaa0, 0xeb40, 0xeb41, + 0xeb42, 0xeb43, 0xeb44, 0xeb45, 0xeb46, 0xeb47, 0xeb48, 0xeb49, + 0xeb4a, 0xeb4b, 0xeb4c, 0xeb4d, 0xeb4e, 0xeb4f, 0xeb50, 0xeb51, + 0xeb52, 0xeb53, 0xeb54, 0xeb55, 0xeb56, 0xeb57, 0xeb58, 0xeb59, + 0xeb5a, 0xeb5b, 0xeb5c, 0xeb5d, 0xeb5e, 0xeb5f, 0xeb60, 0xeb61, + 0xeb62, 0xeb63, 0xeb64, 0xeb65, 0xeb66, 0xeb67, 0xeb68, 0xeb69, + 0xeb6a, 0xeb6b, 0xeb6c, 0xeb6d, 0xeb6e, 0xeb6f, 0xeb70, 0xeb71, + 0xeb72, 0xeb73, 0xeb74, 0xeb75, 0xeb76, 0xeb77, 0xeb78, 0xeb79, + 0xeb7a, 0xeb7b, 0xeb7c, 0xeb7d, 0xeb7e, 0xeb80, 0xeb81, 0xeb82, + 0xeb83, 0xeb84, 0xeb85, 0xeb86, 0xeb87, 0xeb88, 0xeb89, 0xeb8a, + 0xeb8b, 0xeb8c, 0xeb8d, 0xeb8e, 0xeb8f, 0xeb90, 0xeb91, 0xeb92, + 0xeb93, 0xeb94, 0xeb95, 0xeb96, 0xeb97, 0xeb98, 0xeb99, 0xeb9a, + 0xeb9b, 0xeb9c, 0xeb9d, 0xeb9e, 0xeb9f, 0xeba0, 0xec40, 0xec41, + 0xec42, 0xec43, 0xec44, 0xec45, 0xec46, 0xec47, 0xec48, 0xec49, + 0xec4a, 0xec4b, 0xec4c, 0xec4d, 0xec4e, 0xec4f, 0xec50, 0xec51, + 0xec52, 0xec53, 0xec54, 0xec55, 0xec56, 0xec57, 0xec58, 0xec59, + 0xec5a, 0xec5b, 0xec5c, 0xec5d, 0xec5e, 0xec5f, 0xec60, 0xec61, + 0xec62, 0xec63, 0xec64, 0xec65, 0xec66, 0xec67, 0xec68, 0xec69, + 0xec6a, 0xec6b, 0xec6c, 0xec6d, 0xec6e, 0xec6f, 0xec70, 0xec71, + 0xec72, 0xec73, 0xec74, 0xec75, 0xec76, 0xec77, 0xec78, 0xec79, + 0xec7a, 0xec7b, 0xec7c, 0xec7d, 0xec7e, 0xec80, 0xec81, 0xec82, + 0xec83, 0xec84, 0xec85, 0xec86, 0xec87, 0xec88, 0xec89, 0xec8a, + 0xec8b, 0xec8c, 0xec8d, 0xec8e, 0xec8f, 0xec90, 0xec91, 0xec92, + 0xec93, 0xec94, 0xec95, 0xec96, 0xec97, 0xec98, 0xec99, 0xec9a, + 0xec9b, 0xec9c, 0xec9d, 0xec9e, 0xec9f, 0xeca0, 0xed40, 0xed41, + 0xed42, 0xed43, 0xed44, 0xed45, 0xed46, 0xed47, 0xed48, 0xed49, + 0xed4a, 0xed4b, 0xed4c, 0xed4d, 0xed4e, 0xed4f, 0xed50, 0xed51, + 0xed52, 0xed53, 0xed54, 0xed55, 0xed56, 0xed57, 0xed58, 0xed59, + 0xed5a, 0xed5b, 0xed5c, 0xed5d, 0xed5e, 0xed5f, 0xed60, 0xed61, + 0xed62, 0xed63, 0xed64, 0xed65, 0xed66, 0xed67, 0xed68, 0xed69, + 0xed6a, 0xed6b, 0xed6c, 0xed6d, 0xed6e, 0xed6f, 0xed70, 0xed71, + 0xed72, 0xed73, 0xed74, 0xed75, 0xed76, 0xed77, 0xed78, 0xed79, + 0xed7a, 0xed7b, 0xed7c, 0xed7d, 0xed7e, 0xed80, 0xed81, 0xed82, + 0xed83, 0xed84, 0xed85, 0xed86, 0xed87, 0xed88, 0xed89, 0xed8a, + 0xed8b, 0xed8c, 0xed8d, 0xed8e, 0xed8f, 0xed90, 0xed91, 0xed92, + 0xed93, 0xed94, 0xed95, 0xed96, 0xed97, 0xed98, 0xed99, 0xed9a, + 0xed9b, 0xed9c, 0xed9d, 0xed9e, 0xed9f, 0xeda0, 0xee40, 0xee41, + 0xee42, 0xee43, 0xee44, 0xee45, 0xee46, 0xee47, 0xee48, 0xee49, + 0xee4a, 0xee4b, 0xee4c, 0xee4d, 0xee4e, 0xee4f, 0xee50, 0xee51, + 0xee52, 0xee53, 0xee54, 0xee55, 0xee56, 0xee57, 0xee58, 0xee59, + 0xee5a, 0xee5b, 0xee5c, 0xee5d, 0xee5e, 0xee5f, 0xee60, 0xee61, + 0xee62, 0xee63, 0xee64, 0xee65, 0xee66, 0xee67, 0xee68, 0xee69, + 0xee6a, 0xee6b, 0xee6c, 0xee6d, 0xee6e, 0xee6f, 0xee70, 0xee71, + 0xee72, 0xee73, 0xee74, 0xee75, 0xee76, 0xee77, 0xee78, 0xee79, + 0xee7a, 0xee7b, 0xee7c, 0xee7d, 0xee7e, 0xee80, 0xee81, 0xee82, + 0xee83, 0xee84, 0xee85, 0xee86, 0xee87, 0xee88, 0xee89, 0xee8a, + 0xee8b, 0xee8c, 0xee8d, 0xee8e, 0xee8f, 0xee90, 0xee91, 0xee92, + 0xee93, 0xee94, 0xee95, 0xee96, 0xee97, 0xee98, 0xee99, 0xee9a, + 0xee9b, 0xee9c, 0xee9d, 0xee9e, 0xee9f, 0xeea0, 0xef40, 0xef41, + 0xef42, 0xef43, 0xef44, 0xef45, 0xef46, 0xef47, 0xef48, 0xef49, + 0xef4a, 0xef4b, 0xef4c, 0xef4d, 0xef4e, 0xef4f, 0xef50, 0xef51, + 0xef52, 0xef53, 0xef54, 0xef55, 0xef56, 0xef57, 0xef58, 0xef59, + 0xef5a, 0xef5b, 0xef5c, 0xef5d, 0xef5e, 0xef5f, 0xef60, 0xef61, + 0xef62, 0xef63, 0xef64, 0xef65, 0xef66, 0xef67, 0xef68, 0xef69, + 0xef6a, 0xef6b, 0xef6c, 0xef6d, 0xef6e, 0xef6f, 0xef70, 0xef71, + 0xef72, 0xef73, 0xef74, 0xef75, 0xef76, 0xef77, 0xef78, 0xef79, + 0xef7a, 0xef7b, 0xef7c, 0xef7d, 0xef7e, 0xef80, 0xef81, 0xef82, + 0xef83, 0xef84, 0xef85, 0xef86, 0xef87, 0xef88, 0xef89, 0xef8a, + 0xef8b, 0xef8c, 0xef8d, 0xef8e, 0xef8f, 0xef90, 0xef91, 0xef92, + 0xef93, 0xef94, 0xef95, 0xef96, 0xef97, 0xef98, 0xef99, 0xef9a, + 0xef9b, 0xef9c, 0xef9d, 0xef9e, 0xef9f, 0xefa0, 0xf040, 0xf041, + 0xf042, 0xf043, 0xf044, 0xf045, 0xf046, 0xf047, 0xf048, 0xf049, + 0xf04a, 0xf04b, 0xf04c, 0xf04d, 0xf04e, 0xf04f, 0xf050, 0xf051, + 0xf052, 0xf053, 0xf054, 0xf055, 0xf056, 0xf057, 0xf058, 0xf059, + 0xf05a, 0xf05b, 0xf05c, 0xf05d, 0xf05e, 0xf05f, 0xf060, 0xf061, + 0xf062, 0xf063, 0xf064, 0xf065, 0xf066, 0xf067, 0xf068, 0xf069, + 0xf06a, 0xf06b, 0xf06c, 0xf06d, 0xf06e, 0xf06f, 0xf070, 0xf071, + 0xf072, 0xf073, 0xf074, 0xf075, 0xf076, 0xf077, 0xf078, 0xf079, + 0xf07a, 0xf07b, 0xf07c, 0xf07d, 0xf07e, 0xf080, 0xf081, 0xf082, + 0xf083, 0xf084, 0xf085, 0xf086, 0xf087, 0xf088, 0xf089, 0xf08a, + 0xf08b, 0xf08c, 0xf08d, 0xf08e, 0xf08f, 0xf090, 0xf091, 0xf092, + 0xf093, 0xf094, 0xf095, 0xf096, 0xf097, 0xf098, 0xf099, 0xf09a, + 0xf09b, 0xf09c, 0xf09d, 0xf09e, 0xf09f, 0xf0a0, 0xf140, 0xf141, + 0xf142, 0xf143, 0xf144, 0xf145, 0xf146, 0xf147, 0xf148, 0xf149, + 0xf14a, 0xf14b, 0xf14c, 0xf14d, 0xf14e, 0xf14f, 0xf150, 0xf151, + 0xf152, 0xf153, 0xf154, 0xf155, 0xf156, 0xf157, 0xf158, 0xf159, + 0xf15a, 0xf15b, 0xf15c, 0xf15d, 0xf15e, 0xf15f, 0xf160, 0xf161, + 0xf162, 0xf163, 0xf164, 0xf165, 0xf166, 0xf167, 0xf168, 0xf169, + 0xf16a, 0xf16b, 0xf16c, 0xf16d, 0xf16e, 0xf16f, 0xf170, 0xf171, + 0xf172, 0xf173, 0xf174, 0xf175, 0xf176, 0xf177, 0xf178, 0xf179, + 0xf17a, 0xf17b, 0xf17c, 0xf17d, 0xf17e, 0xf180, 0xf181, 0xf182, + 0xf183, 0xf184, 0xf185, 0xf186, 0xf187, 0xf188, 0xf189, 0xf18a, + 0xf18b, 0xf18c, 0xf18d, 0xf18e, 0xf18f, 0xf190, 0xf191, 0xf192, + 0xf193, 0xf194, 0xf195, 0xf196, 0xf197, 0xf198, 0xf199, 0xf19a, + 0xf19b, 0xf19c, 0xf19d, 0xf19e, 0xf19f, 0xf1a0, 0xf240, 0xf241, + 0xf242, 0xf243, 0xf244, 0xf245, 0xf246, 0xf247, 0xf248, 0xf249, + 0xf24a, 0xf24b, 0xf24c, 0xf24d, 0xf24e, 0xf24f, 0xf250, 0xf251, + 0xf252, 0xf253, 0xf254, 0xf255, 0xf256, 0xf257, 0xf258, 0xf259, + 0xf25a, 0xf25b, 0xf25c, 0xf25d, 0xf25e, 0xf25f, 0xf260, 0xf261, + 0xf262, 0xf263, 0xf264, 0xf265, 0xf266, 0xf267, 0xf268, 0xf269, + 0xf26a, 0xf26b, 0xf26c, 0xf26d, 0xf26e, 0xf26f, 0xf270, 0xf271, + 0xf272, 0xf273, 0xf274, 0xf275, 0xf276, 0xf277, 0xf278, 0xf279, + 0xf27a, 0xf27b, 0xf27c, 0xf27d, 0xf27e, 0xf280, 0xf281, 0xf282, + 0xf283, 0xf284, 0xf285, 0xf286, 0xf287, 0xf288, 0xf289, 0xf28a, + 0xf28b, 0xf28c, 0xf28d, 0xf28e, 0xf28f, 0xf290, 0xf291, 0xf292, + 0xf293, 0xf294, 0xf295, 0xf296, 0xf297, 0xf298, 0xf299, 0xf29a, + 0xf29b, 0xf29c, 0xf29d, 0xf29e, 0xf29f, 0xf2a0, 0xf340, 0xf341, + 0xf342, 0xf343, 0xf344, 0xf345, 0xf346, 0xf347, 0xf348, 0xf349, + 0xf34a, 0xf34b, 0xf34c, 0xf34d, 0xf34e, 0xf34f, 0xf350, 0xf351, + 0xf352, 0xf353, 0xf354, 0xf355, 0xf356, 0xf357, 0xf358, 0xf359, + 0xf35a, 0xf35b, 0xf35c, 0xf35d, 0xf35e, 0xf35f, 0xf360, 0xf361, + 0xf362, 0xf363, 0xf364, 0xf365, 0xf366, 0xf367, 0xf368, 0xf369, + 0xf36a, 0xf36b, 0xf36c, 0xf36d, 0xf36e, 0xf36f, 0xf370, 0xf371, + 0xf372, 0xf373, 0xf374, 0xf375, 0xf376, 0xf377, 0xf378, 0xf379, + 0xf37a, 0xf37b, 0xf37c, 0xf37d, 0xf37e, 0xf380, 0xf381, 0xf382, + 0xf383, 0xf384, 0xf385, 0xf386, 0xf387, 0xf388, 0xf389, 0xf38a, + 0xf38b, 0xf38c, 0xf38d, 0xf38e, 0xf38f, 0xf390, 0xf391, 0xf392, + 0xf393, 0xf394, 0xf395, 0xf396, 0xf397, 0xf398, 0xf399, 0xf39a, + 0xf39b, 0xf39c, 0xf39d, 0xf39e, 0xf39f, 0xf3a0, 0xf440, 0xf441, + 0xf442, 0xf443, 0xf444, 0xf445, 0xf446, 0xf447, 0xf448, 0xf449, + 0xf44a, 0xf44b, 0xf44c, 0xf44d, 0xf44e, 0xf44f, 0xf450, 0xf451, + 0xf452, 0xf453, 0xf454, 0xf455, 0xf456, 0xf457, 0xf458, 0xf459, + 0xf45a, 0xf45b, 0xf45c, 0xf45d, 0xf45e, 0xf45f, 0xf460, 0xf461, + 0xf462, 0xf463, 0xf464, 0xf465, 0xf466, 0xf467, 0xf468, 0xf469, + 0xf46a, 0xf46b, 0xf46c, 0xf46d, 0xf46e, 0xf46f, 0xf470, 0xf471, + 0xf472, 0xf473, 0xf474, 0xf475, 0xf476, 0xf477, 0xf478, 0xf479, + 0xf47a, 0xf47b, 0xf47c, 0xf47d, 0xf47e, 0xf480, 0xf481, 0xf482, + 0xf483, 0xf484, 0xf485, 0xf486, 0xf487, 0xf488, 0xf489, 0xf48a, + 0xf48b, 0xf48c, 0xf48d, 0xf48e, 0xf48f, 0xf490, 0xf491, 0xf492, + 0xf493, 0xf494, 0xf495, 0xf496, 0xf497, 0xf498, 0xf499, 0xf49a, + 0xf49b, 0xf49c, 0xf49d, 0xf49e, 0xf49f, 0xf4a0, 0xf540, 0xf541, + 0xf542, 0xf543, 0xf544, 0xf545, 0xf546, 0xf547, 0xf548, 0xf549, + 0xf54a, 0xf54b, 0xf54c, 0xf54d, 0xf54e, 0xf54f, 0xf550, 0xf551, + 0xf552, 0xf553, 0xf554, 0xf555, 0xf556, 0xf557, 0xf558, 0xf559, + 0xf55a, 0xf55b, 0xf55c, 0xf55d, 0xf55e, 0xf55f, 0xf560, 0xf561, + 0xf562, 0xf563, 0xf564, 0xf565, 0xf566, 0xf567, 0xf568, 0xf569, + 0xf56a, 0xf56b, 0xf56c, 0xf56d, 0xf56e, 0xf56f, 0xf570, 0xf571, + 0xf572, 0xf573, 0xf574, 0xf575, 0xf576, 0xf577, 0xf578, 0xf579, + 0xf57a, 0xf57b, 0xf57c, 0xf57d, 0xf57e, 0xf580, 0xf581, 0xf582, + 0xf583, 0xf584, 0xf585, 0xf586, 0xf587, 0xf588, 0xf589, 0xf58a, + 0xf58b, 0xf58c, 0xf58d, 0xf58e, 0xf58f, 0xf590, 0xf591, 0xf592, + 0xf593, 0xf594, 0xf595, 0xf596, 0xf597, 0xf598, 0xf599, 0xf59a, + 0xf59b, 0xf59c, 0xf59d, 0xf59e, 0xf59f, 0xf5a0, 0xf640, 0xf641, + 0xf642, 0xf643, 0xf644, 0xf645, 0xf646, 0xf647, 0xf648, 0xf649, + 0xf64a, 0xf64b, 0xf64c, 0xf64d, 0xf64e, 0xf64f, 0xf650, 0xf651, + 0xf652, 0xf653, 0xf654, 0xf655, 0xf656, 0xf657, 0xf658, 0xf659, + 0xf65a, 0xf65b, 0xf65c, 0xf65d, 0xf65e, 0xf65f, 0xf660, 0xf661, + 0xf662, 0xf663, 0xf664, 0xf665, 0xf666, 0xf667, 0xf668, 0xf669, + 0xf66a, 0xf66b, 0xf66c, 0xf66d, 0xf66e, 0xf66f, 0xf670, 0xf671, + 0xf672, 0xf673, 0xf674, 0xf675, 0xf676, 0xf677, 0xf678, 0xf679, + 0xf67a, 0xf67b, 0xf67c, 0xf67d, 0xf67e, 0xf680, 0xf681, 0xf682, + 0xf683, 0xf684, 0xf685, 0xf686, 0xf687, 0xf688, 0xf689, 0xf68a, + 0xf68b, 0xf68c, 0xf68d, 0xf68e, 0xf68f, 0xf690, 0xf691, 0xf692, + 0xf693, 0xf694, 0xf695, 0xf696, 0xf697, 0xf698, 0xf699, 0xf69a, + 0xf69b, 0xf69c, 0xf69d, 0xf69e, 0xf69f, 0xf6a0, 0xf740, 0xf741, + 0xf742, 0xf743, 0xf744, 0xf745, 0xf746, 0xf747, 0xf748, 0xf749, + 0xf74a, 0xf74b, 0xf74c, 0xf74d, 0xf74e, 0xf74f, 0xf750, 0xf751, + 0xf752, 0xf753, 0xf754, 0xf755, 0xf756, 0xf757, 0xf758, 0xf759, + 0xf75a, 0xf75b, 0xf75c, 0xf75d, 0xf75e, 0xf75f, 0xf760, 0xf761, + 0xf762, 0xf763, 0xf764, 0xf765, 0xf766, 0xf767, 0xf768, 0xf769, + 0xf76a, 0xf76b, 0xf76c, 0xf76d, 0xf76e, 0xf76f, 0xf770, 0xf771, + 0xf772, 0xf773, 0xf774, 0xf775, 0xf776, 0xf777, 0xf778, 0xf779, + 0xf77a, 0xf77b, 0xf77c, 0xf77d, 0xf77e, 0xf780, 0xf781, 0xf782, + 0xf783, 0xf784, 0xf785, 0xf786, 0xf787, 0xf788, 0xf789, 0xf78a, + 0xf78b, 0xf78c, 0xf78d, 0xf78e, 0xf78f, 0xf790, 0xf791, 0xf792, + 0xf793, 0xf794, 0xf795, 0xf796, 0xf797, 0xf798, 0xf799, 0xf79a, + 0xf79b, 0xf79c, 0xf79d, 0xf79e, 0xf79f, 0xf7a0, 0xf840, 0xf841, + 0xf842, 0xf843, 0xf844, 0xf845, 0xf846, 0xf847, 0xf848, 0xf849, + 0xf84a, 0xf84b, 0xf84c, 0xf84d, 0xf84e, 0xf84f, 0xf850, 0xf851, + 0xf852, 0xf853, 0xf854, 0xf855, 0xf856, 0xf857, 0xf858, 0xf859, + 0xf85a, 0xf85b, 0xf85c, 0xf85d, 0xf85e, 0xf85f, 0xf860, 0xf861, + 0xf862, 0xf863, 0xf864, 0xf865, 0xf866, 0xf867, 0xf868, 0xf869, + 0xf86a, 0xf86b, 0xf86c, 0xf86d, 0xf86e, 0xf86f, 0xf870, 0xf871, + 0xf872, 0xf873, 0xf874, 0xf875, 0xf876, 0xf877, 0xf878, 0xf879, + 0xf87a, 0xf87b, 0xf87c, 0xf87d, 0xf87e, 0xf880, 0xf881, 0xf882, + 0xf883, 0xf884, 0xf885, 0xf886, 0xf887, 0xf888, 0xf889, 0xf88a, + 0xf88b, 0xf88c, 0xf88d, 0xf88e, 0xf88f, 0xf890, 0xf891, 0xf892, + 0xf893, 0xf894, 0xf895, 0xf896, 0xf897, 0xf898, 0xf899, 0xf89a, + 0xf89b, 0xf89c, 0xf89d, 0xf89e, 0xf89f, 0xf8a0, 0xf940, 0xf941, + 0xf942, 0xf943, 0xf944, 0xf945, 0xf946, 0xf947, 0xf948, 0xf949, + 0xf94a, 0xf94b, 0xf94c, 0xf94d, 0xf94e, 0xf94f, 0xf950, 0xf951, + 0xf952, 0xf953, 0xf954, 0xf955, 0xf956, 0xf957, 0xf958, 0xf959, + 0xf95a, 0xf95b, 0xf95c, 0xf95d, 0xf95e, 0xf95f, 0xf960, 0xf961, + 0xf962, 0xf963, 0xf964, 0xf965, 0xf966, 0xf967, 0xf968, 0xf969, + 0xf96a, 0xf96b, 0xf96c, 0xf96d, 0xf96e, 0xf96f, 0xf970, 0xf971, + 0xf972, 0xf973, 0xf974, 0xf975, 0xf976, 0xf977, 0xf978, 0xf979, + 0xf97a, 0xf97b, 0xf97c, 0xf97d, 0xf97e, 0xf980, 0xf981, 0xf982, + 0xf983, 0xf984, 0xf985, 0xf986, 0xf987, 0xf988, 0xf989, 0xf98a, + 0xf98b, 0xf98c, 0xf98d, 0xf98e, 0xf98f, 0xf990, 0xf991, 0xf992, + 0xf993, 0xf994, 0xf995, 0xf996, 0xf997, 0xf998, 0xf999, 0xf99a, + 0xf99b, 0xf99c, 0xf99d, 0xf99e, 0xf99f, 0xf9a0, 0xfa40, 0xfa41, + 0xfa42, 0xfa43, 0xfa44, 0xfa45, 0xfa46, 0xfa47, 0xfa48, 0xfa49, + 0xfa4a, 0xfa4b, 0xfa4c, 0xfa4d, 0xfa4e, 0xfa4f, 0xfa50, 0xfa51, + 0xfa52, 0xfa53, 0xfa54, 0xfa55, 0xfa56, 0xfa57, 0xfa58, 0xfa59, + 0xfa5a, 0xfa5b, 0xfa5c, 0xfa5d, 0xfa5e, 0xfa5f, 0xfa60, 0xfa61, + 0xfa62, 0xfa63, 0xfa64, 0xfa65, 0xfa66, 0xfa67, 0xfa68, 0xfa69, + 0xfa6a, 0xfa6b, 0xfa6c, 0xfa6d, 0xfa6e, 0xfa6f, 0xfa70, 0xfa71, + 0xfa72, 0xfa73, 0xfa74, 0xfa75, 0xfa76, 0xfa77, 0xfa78, 0xfa79, + 0xfa7a, 0xfa7b, 0xfa7c, 0xfa7d, 0xfa7e, 0xfa80, 0xfa81, 0xfa82, + 0xfa83, 0xfa84, 0xfa85, 0xfa86, 0xfa87, 0xfa88, 0xfa89, 0xfa8a, + 0xfa8b, 0xfa8c, 0xfa8d, 0xfa8e, 0xfa8f, 0xfa90, 0xfa91, 0xfa92, + 0xfa93, 0xfa94, 0xfa95, 0xfa96, 0xfa97, 0xfa98, 0xfa99, 0xfa9a, + 0xfa9b, 0xfa9c, 0xfa9d, 0xfa9e, 0xfa9f, 0xfaa0, 0xfb40, 0xfb41, + 0xfb42, 0xfb43, 0xfb44, 0xfb45, 0xfb46, 0xfb47, 0xfb48, 0xfb49, + 0xfb4a, 0xfb4b, 0xfb4c, 0xfb4d, 0xfb4e, 0xfb4f, 0xfb50, 0xfb51, + 0xfb52, 0xfb53, 0xfb54, 0xfb55, 0xfb56, 0xfb57, 0xfb58, 0xfb59, + 0xfb5a, 0xfb5b, 0xfb5c, 0xfb5d, 0xfb5e, 0xfb5f, 0xfb60, 0xfb61, + 0xfb62, 0xfb63, 0xfb64, 0xfb65, 0xfb66, 0xfb67, 0xfb68, 0xfb69, + 0xfb6a, 0xfb6b, 0xfb6c, 0xfb6d, 0xfb6e, 0xfb6f, 0xfb70, 0xfb71, + 0xfb72, 0xfb73, 0xfb74, 0xfb75, 0xfb76, 0xfb77, 0xfb78, 0xfb79, + 0xfb7a, 0xfb7b, 0xfb7c, 0xfb7d, 0xfb7e, 0xfb80, 0xfb81, 0xfb82, + 0xfb83, 0xfb84, 0xfb85, 0xfb86, 0xfb87, 0xfb88, 0xfb89, 0xfb8a, + 0xfb8b, 0xfb8c, 0xfb8d, 0xfb8e, 0xfb8f, 0xfb90, 0xfb91, 0xfb92, + 0xfb93, 0xfb94, 0xfb95, 0xfb96, 0xfb97, 0xfb98, 0xfb99, 0xfb9a, + 0xfb9b, 0xfb9c, 0xfb9d, 0xfb9e, 0xfb9f, 0xfba0, 0xfc40, 0xfc41, + 0xfc42, 0xfc43, 0xfc44, 0xfc45, 0xfc46, 0xfc47, 0xfc48, 0xfc49, + 0xfc4a, 0xfc4b, 0xfc4c, 0xfc4d, 0xfc4e, 0xfc4f, 0xfc50, 0xfc51, + 0xfc52, 0xfc53, 0xfc54, 0xfc55, 0xfc56, 0xfc57, 0xfc58, 0xfc59, + 0xfc5a, 0xfc5b, 0xfc5c, 0xfc5d, 0xfc5e, 0xfc5f, 0xfc60, 0xfc61, + 0xfc62, 0xfc63, 0xfc64, 0xfc65, 0xfc66, 0xfc67, 0xfc68, 0xfc69, + 0xfc6a, 0xfc6b, 0xfc6c, 0xfc6d, 0xfc6e, 0xfc6f, 0xfc70, 0xfc71, + 0xfc72, 0xfc73, 0xfc74, 0xfc75, 0xfc76, 0xfc77, 0xfc78, 0xfc79, + 0xfc7a, 0xfc7b, 0xfc7c, 0xfc7d, 0xfc7e, 0xfc80, 0xfc81, 0xfc82, + 0xfc83, 0xfc84, 0xfc85, 0xfc86, 0xfc87, 0xfc88, 0xfc89, 0xfc8a, + 0xfc8b, 0xfc8c, 0xfc8d, 0xfc8e, 0xfc8f, 0xfc90, 0xfc91, 0xfc92, + 0xfc93, 0xfc94, 0xfc95, 0xfc96, 0xfc97, 0xfc98, 0xfc99, 0xfc9a, + 0xfc9b, 0xfc9c, 0xfc9d, 0xfc9e, 0xfc9f, 0xfca0, 0xfd40, 0xfd41, + 0xfd42, 0xfd43, 0xfd44, 0xfd45, 0xfd46, 0xfd47, 0xfd48, 0xfd49, + 0xfd4a, 0xfd4b, 0xfd4c, 0xfd4d, 0xfd4e, 0xfd4f, 0xfd50, 0xfd51, + 0xfd52, 0xfd53, 0xfd54, 0xfd55, 0xfd56, 0xfd57, 0xfd58, 0xfd59, + 0xfd5a, 0xfd5b, 0xfd5c, 0xfd5d, 0xfd5e, 0xfd5f, 0xfd60, 0xfd61, + 0xfd62, 0xfd63, 0xfd64, 0xfd65, 0xfd66, 0xfd67, 0xfd68, 0xfd69, + 0xfd6a, 0xfd6b, 0xfd6c, 0xfd6d, 0xfd6e, 0xfd6f, 0xfd70, 0xfd71, + 0xfd72, 0xfd73, 0xfd74, 0xfd75, 0xfd76, 0xfd77, 0xfd78, 0xfd79, + 0xfd7a, 0xfd7b, 0xfd7c, 0xfd7d, 0xfd7e, 0xfd80, 0xfd81, 0xfd82, + 0xfd83, 0xfd84, 0xfd85, 0xfd86, 0xfd87, 0xfd88, 0xfd89, 0xfd8a, + 0xfd8b, 0xfd8c, 0xfd8d, 0xfd8e, 0xfd8f, 0xfd90, 0xfd91, 0xfd92, + 0xfd93, 0xfd94, 0xfd95, 0xfd96, 0xfd97, 0xfd98, 0xfd99, 0xfd9a, + 0xfd9b, 0xfd9c, 0xfd9d, 0xfd9e, 0xfd9f, 0xfda0, 0xfe40, 0xfe41, + 0xfe42, 0xfe43, 0xfe44, 0xfe45, 0xfe46, 0xfe47, 0xfe48, 0xfe49, + 0xfe4a, 0xfe4b, 0xfe4c, 0xfe4d, 0xfe4e, 0xfe4f, 0xa955, 0xa968, + 0xa969, 0xa96a, 0xa96b, 0xa96c, 0xa96d, 0xa96e, 0xa96f, 0xa970, + 0xa971, 0xa972, 0xa973, 0xa974, 0xa975, 0xa976, 0xa977, 0xa978, + 0xa979, 0xa97a, 0xa97b, 0xa97c, 0xa97d, 0xa97e, 0xa980, 0xa981, + 0xa982, 0xa983, 0xa984, 0xa985, 0xa986, 0xa987, 0xa988, 0xa956, + 0xa957, +}; + +static const Summary16 gbkext_inv_uni2indx_page02[14] = { + /* 0x0200 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0c00 }, { 2, 0x0200 }, +}; +static const Summary16 gbkext_inv_uni2indx_page20[44] = { + /* 0x2000 */ + { 3, 0x0000 }, { 3, 0x0029 }, { 6, 0x0020 }, { 7, 0x0020 }, + { 8, 0x0000 }, { 8, 0x0000 }, { 8, 0x0000 }, { 8, 0x0000 }, + { 8, 0x0000 }, { 8, 0x0000 }, { 8, 0x0000 }, { 8, 0x0000 }, + { 8, 0x0000 }, { 8, 0x0000 }, { 8, 0x0000 }, { 8, 0x0000 }, + /* 0x2100 */ + { 8, 0x0220 }, { 10, 0x0000 }, { 10, 0x0002 }, { 11, 0x0000 }, + { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0000 }, { 11, 0x03c0 }, { 15, 0x0000 }, { 15, 0x0000 }, + { 15, 0x0000 }, { 15, 0x0000 }, { 15, 0x0000 }, { 15, 0x0000 }, + /* 0x2200 */ + { 15, 0x0000 }, { 15, 0x8020 }, { 17, 0x0008 }, { 18, 0x0000 }, + { 18, 0x0000 }, { 18, 0x0004 }, { 19, 0x00c0 }, { 21, 0x0000 }, + { 21, 0x0000 }, { 21, 0x0020 }, { 22, 0x0000 }, { 22, 0x8000 }, +}; +static const Summary16 gbkext_inv_uni2indx_page25[17] = { + /* 0x2500 */ + { 23, 0x0000 }, { 23, 0x0000 }, { 23, 0x0000 }, { 23, 0x0000 }, + { 23, 0x0000 }, { 23, 0xffff }, { 39, 0xffff }, { 55, 0x000f }, + { 59, 0xfffe }, { 74, 0x0038 }, { 77, 0x0000 }, { 77, 0x3000 }, + { 79, 0x0000 }, { 79, 0x0000 }, { 79, 0x003c }, { 83, 0x0000 }, + /* 0x2600 */ + { 83, 0x0200 }, +}; +static const Summary16 gbkext_inv_uni2indx_page30[16] = { + /* 0x3000 */ + { 84, 0x00c0 }, { 86, 0x6004 }, { 89, 0x03fe }, { 98, 0x0000 }, + { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x0000 }, + { 98, 0x0000 }, { 98, 0x7800 }, { 102, 0x0000 }, { 102, 0x0000 }, + { 102, 0x0000 }, { 102, 0x0000 }, { 102, 0x0000 }, { 102, 0x7000 }, +}; +static const Summary16 gbkext_inv_uni2indx_page32[30] = { + /* 0x3200 */ + { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x0002 }, + { 106, 0x0000 }, { 106, 0x0000 }, { 106, 0x0000 }, { 106, 0x0000 }, + { 106, 0x0000 }, { 106, 0x0000 }, { 106, 0x0008 }, { 107, 0x0000 }, + { 107, 0x0000 }, { 107, 0x0000 }, { 107, 0x0000 }, { 107, 0x0000 }, + /* 0x3300 */ + { 107, 0x0000 }, { 107, 0x0000 }, { 107, 0x0000 }, { 107, 0x0000 }, + { 107, 0x0000 }, { 107, 0x0000 }, { 107, 0x0000 }, { 107, 0x0000 }, + { 107, 0xc000 }, { 109, 0x7000 }, { 112, 0x0002 }, { 113, 0x0000 }, + { 113, 0x4010 }, { 115, 0x0026 }, +}; +static const Summary16 gbkext_inv_uni2indx_page4e[1307] = { + /* 0x4e00 */ + { 118, 0x8074 }, { 123, 0x8084 }, { 126, 0xc24b }, { 133, 0x10aa }, + { 138, 0x0457 }, { 144, 0x0ca2 }, { 149, 0xfdbc }, { 161, 0xbff4 }, + { 173, 0x04bf }, { 181, 0x72c1 }, { 188, 0x8408 }, { 191, 0x73d3 }, + { 201, 0x9100 }, { 204, 0x1c05 }, { 209, 0xe2c5 }, { 217, 0x5712 }, + /* 0x4f00 */ + { 224, 0x19fd }, { 234, 0x307c }, { 241, 0x730a }, { 248, 0xcaaa }, + { 256, 0x1fb7 }, { 267, 0x0054 }, { 270, 0x6d46 }, { 278, 0x27a6 }, + { 286, 0x54e7 }, { 295, 0xd76d }, { 306, 0x2816 }, { 311, 0x7fdf }, + { 325, 0x3bc7 }, { 335, 0x0a7c }, { 342, 0x18b5 }, { 349, 0xbaf5 }, + /* 0x5000 */ + { 360, 0x4fff }, { 373, 0x68eb }, { 382, 0x889d }, { 389, 0xabff }, + { 402, 0x2e77 }, { 412, 0xebdf }, { 425, 0xefdf }, { 439, 0x373f }, + { 450, 0xdede }, { 462, 0xffff }, { 478, 0xec57 }, { 488, 0xf3fb }, + { 501, 0x7fff }, { 516, 0xfbbf }, { 530, 0x8f3f }, { 541, 0xf7d7 }, + /* 0x5100 */ + { 554, 0xf73f }, { 567, 0xfffb }, { 582, 0xfffd }, { 597, 0x7fff }, + { 612, 0xd484 }, { 618, 0xeb8d }, { 628, 0x86db }, { 637, 0xc404 }, + { 641, 0xccd8 }, { 649, 0xe51b }, { 658, 0x67ca }, { 667, 0xc710 }, + { 673, 0x652e }, { 681, 0xd7fd }, { 694, 0x57ec }, { 704, 0x4096 }, + /* 0x5200 */ + { 709, 0x9a30 }, { 715, 0xd039 }, { 722, 0x94ee }, { 731, 0x5036 }, + { 737, 0xcbf0 }, { 746, 0xafac }, { 756, 0x795d }, { 766, 0x5ffb }, + { 779, 0xfef9 }, { 792, 0x17f6 }, { 802, 0xc0f0 }, { 808, 0x3ff1 }, + { 819, 0xf577 }, { 831, 0x7eba }, { 842, 0xffef }, { 857, 0x39fe }, + /* 0x5300 */ + { 868, 0x5e9e }, { 878, 0xd91e }, { 887, 0xbbb4 }, { 897, 0x31ff }, + { 908, 0x3855 }, { 915, 0x2b11 }, { 921, 0x3520 }, { 926, 0x7a44 }, + { 933, 0xc58b }, { 941, 0x5adf }, { 952, 0xbc93 }, { 961, 0x77bf }, + { 974, 0xc0f9 }, { 982, 0x742d }, { 990, 0x0086 }, { 993, 0xc410 }, + /* 0x5400 */ + { 997, 0x08a5 }, { 1002, 0x1710 }, { 1007, 0x0434 }, { 1011, 0xa4c9 }, + { 1018, 0xf2b6 }, { 1028, 0xe402 }, { 1033, 0xfeab }, { 1045, 0xc611 }, + { 1051, 0x27aa }, { 1059, 0xd18a }, { 1066, 0x4027 }, { 1071, 0x56e5 }, + { 1080, 0x0c28 }, { 1084, 0x0940 }, { 1087, 0x981f }, { 1095, 0x4bf3 }, + /* 0x5500 */ + { 1105, 0x7d3d }, { 1116, 0xf7ec }, { 1128, 0x2b62 }, { 1135, 0x2f74 }, + { 1144, 0xf9a5 }, { 1154, 0xef9e }, { 1166, 0x8b0d }, { 1173, 0xa61f }, + { 1182, 0x7060 }, { 1187, 0x4ced }, { 1196, 0xff7f }, { 1211, 0x9555 }, + { 1219, 0xcdcf }, { 1230, 0x4fa1 }, { 1238, 0x6285 }, { 1244, 0x9f53 }, + /* 0x5600 */ + { 1254, 0x2cfc }, { 1263, 0x36ff }, { 1275, 0xcf67 }, { 1286, 0x75a9 }, + { 1295, 0x8fff }, { 1308, 0xec6f }, { 1319, 0xe0eb }, { 1328, 0xe7bd }, + { 1340, 0x3f9f }, { 1352, 0xfff7 }, { 1367, 0x7ff7 }, { 1381, 0xef7f }, + { 1395, 0xfbff }, { 1410, 0x136f }, { 1419, 0xd7e8 }, { 1429, 0x19cc }, + /* 0x5700 */ + { 1436, 0xf8a7 }, { 1446, 0x6fff }, { 1460, 0x08f7 }, { 1468, 0xb1f6 }, + { 1478, 0x0b7a }, { 1486, 0x037c }, { 1493, 0x50ac }, { 1499, 0xe737 }, + { 1510, 0xe783 }, { 1519, 0xf7f3 }, { 1532, 0x9520 }, { 1537, 0xfeeb }, + { 1550, 0x37f3 }, { 1561, 0x58cb }, { 1569, 0x5fee }, { 1581, 0xd8ef }, + /* 0x5800 */ + { 1592, 0xd73a }, { 1602, 0xbddd }, { 1614, 0xfbec }, { 1626, 0xffde }, + { 1640, 0xcfef }, { 1653, 0xbeed }, { 1665, 0xe7df }, { 1678, 0xbfff }, + { 1693, 0xfdd4 }, { 1704, 0x39f3 }, { 1714, 0xfcff }, { 1728, 0xefff }, + { 1743, 0xffdd }, { 1757, 0xffdd }, { 1771, 0xa7ef }, { 1783, 0xfdb6 }, + /* 0x5900 */ + { 1795, 0x5f6b }, { 1806, 0x698f }, { 1815, 0x114f }, { 1822, 0xe86d }, + { 1831, 0x3469 }, { 1838, 0xfa0d }, { 1847, 0xffda }, { 1860, 0xdca7 }, + { 1870, 0xda21 }, { 1877, 0xbd33 }, { 1887, 0x30c7 }, { 1894, 0xb5fb }, + { 1906, 0xf3bf }, { 1919, 0xca60 }, { 1925, 0xeed7 }, { 1937, 0x75ff }, + /* 0x5a00 */ + { 1950, 0xec05 }, { 1957, 0x6ef5 }, { 1968, 0xfdd6 }, { 1980, 0xefa9 }, + { 1991, 0xf9be }, { 2003, 0xfbdf }, { 2017, 0xfb7b }, { 2030, 0x7b0f }, + { 2040, 0xffff }, { 2056, 0xf3fb }, { 2069, 0xfbff }, { 2084, 0xbed3 }, + { 2095, 0xedf9 }, { 2107, 0xeeab }, { 2118, 0xf5b4 }, { 2128, 0xfffd }, + /* 0x5b00 */ + { 2143, 0xfdff }, { 2158, 0xff3f }, { 2172, 0xffff }, { 2188, 0xff6b }, + { 2201, 0xfffe }, { 2216, 0x4044 }, { 2219, 0xe983 }, { 2227, 0xdbd4 }, + { 2237, 0x6444 }, { 2242, 0x8057 }, { 2248, 0xf380 }, { 2255, 0x1c86 }, + { 2261, 0xef0b }, { 2271, 0x1ff2 }, { 2281, 0xbecd }, { 2292, 0x60fe }, + /* 0x5c00 */ + { 2301, 0x79ad }, { 2311, 0xca8d }, { 2319, 0xef4b }, { 2330, 0x00ed }, + { 2336, 0x30d8 }, { 2342, 0xbddc }, { 2353, 0x3f94 }, { 2362, 0x79fd }, + { 2374, 0xcef9 }, { 2385, 0xe02c }, { 2391, 0xc5f3 }, { 2401, 0x5e55 }, + { 2410, 0xf7ed }, { 2423, 0xfdfb }, { 2437, 0xda8d }, { 2446, 0xf7fe }, + /* 0x5d00 */ + { 2460, 0xbf33 }, { 2471, 0xb7af }, { 2483, 0x9d2f }, { 2493, 0x9fef }, + { 2506, 0xe37f }, { 2518, 0xd6ff }, { 2531, 0x65ff }, { 2543, 0xffef }, + { 2558, 0xfffb }, { 2573, 0xddff }, { 2587, 0xffff }, { 2603, 0xff7f }, + { 2618, 0xdfdf }, { 2632, 0x97ff }, { 2645, 0x3419 }, { 2651, 0x9f61 }, + /* 0x5e00 */ + { 2660, 0x6e91 }, { 2668, 0xc08c }, { 2673, 0x9f3f }, { 2685, 0xc67d }, + { 2695, 0xefcb }, { 2707, 0xb7cf }, { 2719, 0xfff9 }, { 2733, 0x42a3 }, + { 2739, 0x732e }, { 2748, 0x2904 }, { 2752, 0xdf1e }, { 2763, 0xbc17 }, + { 2772, 0xf9ff }, { 2786, 0xf7b1 }, { 2797, 0xfaff }, { 2811, 0x3b2f }, + /* 0x5f00 */ + { 2821, 0x72e0 }, { 2828, 0x7655 }, { 2837, 0x591e }, { 2845, 0xe9fd }, + { 2857, 0xfffe }, { 2872, 0xde12 }, { 2880, 0xc9a9 }, { 2888, 0xe574 }, + { 2897, 0xe048 }, { 2902, 0xec5a }, { 2911, 0x9afd }, { 2922, 0xcf5f }, + { 2934, 0x4d87 }, { 2942, 0xdc38 }, { 2950, 0x936c }, { 2958, 0x16dd }, + /* 0x6000 */ + { 2967, 0x1b80 }, { 2972, 0xc58b }, { 2980, 0x701c }, { 2986, 0x67df }, + { 2998, 0xd7f1 }, { 3009, 0xd9da }, { 3019, 0x4063 }, { 3024, 0x40b6 }, + { 3030, 0xcde7 }, { 3041, 0x53ab }, { 3050, 0x46b6 }, { 3058, 0xe6e9 }, + { 3068, 0xf39f }, { 3080, 0x4add }, { 3089, 0x043e }, { 3095, 0xf9a6 }, + /* 0x6100 */ + { 3105, 0x1cbc }, { 3113, 0x7bdf }, { 3126, 0xf726 }, { 3136, 0x7fff }, + { 3151, 0xaaff }, { 3163, 0xdfdd }, { 3176, 0xfe7b }, { 3189, 0xff5e }, + { 3202, 0xb7ff }, { 3216, 0xdfef }, { 3230, 0xec7f }, { 3242, 0xbf7f }, + { 3256, 0xf2fb }, { 3268, 0xffe9 }, { 3281, 0xffbf }, { 3296, 0x7fdf }, + /* 0x6200 */ + { 3310, 0x02bf }, { 3318, 0x7218 }, { 3324, 0xabc9 }, { 3333, 0x1f67 }, + { 3343, 0x8474 }, { 3349, 0xf6e1 }, { 3359, 0x0137 }, { 3365, 0x2db6 }, + { 3374, 0xf9ee }, { 3386, 0x7211 }, { 3392, 0xe6c8 }, { 3400, 0x45dd }, + { 3409, 0x880b }, { 3414, 0x6022 }, { 3418, 0x0c13 }, { 3423, 0x0f25 }, + /* 0x6300 */ + { 3430, 0xbc79 }, { 3440, 0x13bd }, { 3449, 0x72c0 }, { 3455, 0xd9fb }, + { 3467, 0x0593 }, { 3473, 0x3fde }, { 3485, 0x9d71 }, { 3494, 0xf33d }, + { 3505, 0x287a }, { 3512, 0xfeba }, { 3524, 0x8852 }, { 3529, 0xaa66 }, + { 3537, 0x1daf }, { 3547, 0xbfba }, { 3559, 0xd9f4 }, { 3569, 0x5eab }, + /* 0x6400 */ + { 3579, 0x67d8 }, { 3588, 0xa7e6 }, { 3598, 0xcbbc }, { 3608, 0x5bef }, + { 3620, 0xfa0d }, { 3629, 0xbeeb }, { 3641, 0xdd7f }, { 3654, 0xf8ff }, + { 3667, 0xff4b }, { 3679, 0xbd99 }, { 3689, 0x8def }, { 3700, 0xea5e }, + { 3710, 0x9fda }, { 3721, 0xbe7a }, { 3732, 0xffab }, { 3745, 0xffff }, + /* 0x6500 */ + { 3761, 0xfdfe }, { 3775, 0xfefb }, { 3789, 0x37df }, { 3801, 0x348f }, + { 3809, 0x6cdf }, { 3820, 0x959d }, { 3829, 0xe7b3 }, { 3840, 0xff6a }, + { 3852, 0xe77f }, { 3865, 0x6574 }, { 3873, 0x554d }, { 3881, 0xcdfe }, + { 3893, 0x2785 }, { 3900, 0xff3b }, { 3913, 0x0c1a }, { 3918, 0xfb3c }, + /* 0x6600 */ + { 3929, 0x2bb2 }, { 3937, 0x5dc7 }, { 3947, 0x5e5e }, { 3957, 0xaf8d }, + { 3967, 0x67f5 }, { 3978, 0x7b03 }, { 3986, 0x3ead }, { 3996, 0xbb2e }, + { 4006, 0xef6b }, { 4018, 0xdf3d }, { 4030, 0xbe7f }, { 4043, 0xbdef }, + { 4056, 0xffff }, { 4072, 0xc5ff }, { 4084, 0xfdbf }, { 4098, 0x2d62 }, + /* 0x6700 */ + { 4105, 0xd0fe }, { 4115, 0x574e }, { 4124, 0x42bf }, { 4133, 0xdbcd }, + { 4144, 0x2cb2 }, { 4151, 0x2fb4 }, { 4160, 0x58dc }, { 4168, 0x2f52 }, + { 4176, 0xf56d }, { 4187, 0x8a5e }, { 4195, 0x5253 }, { 4202, 0xfe16 }, + { 4212, 0x7fe5 }, { 4224, 0x88e0 }, { 4229, 0x6dda }, { 4239, 0x5fe4 }, + /* 0x6800 */ + { 4249, 0x205e }, { 4255, 0xdf35 }, { 4266, 0xf9fd }, { 4279, 0x8c73 }, + { 4287, 0xa880 }, { 4291, 0xffc4 }, { 4302, 0xf400 }, { 4307, 0xff2f }, + { 4320, 0x7f95 }, { 4331, 0xff77 }, { 4345, 0x5e3b }, { 4355, 0xffd6 }, + { 4368, 0xd5fa }, { 4379, 0xfadb }, { 4391, 0xbff6 }, { 4404, 0xe9dc }, + /* 0x6900 */ + { 4414, 0x97dd }, { 4425, 0x7ffa }, { 4438, 0xdfee }, { 4451, 0x5dee }, + { 4462, 0xfffb }, { 4477, 0x9b6f }, { 4488, 0xb7b6 }, { 4499, 0xec7d }, + { 4510, 0xdc2a }, { 4518, 0xe6cf }, { 4529, 0xd67f }, { 4541, 0xf76d }, + { 4553, 0xabfd }, { 4565, 0x77ee }, { 4577, 0xdffe }, { 4591, 0x5ffb }, + /* 0x6a00 */ + { 4604, 0xfbff }, { 4619, 0x7e7f }, { 4632, 0x7afd }, { 4644, 0x9fdd }, + { 4656, 0xff6f }, { 4670, 0xf4fe }, { 4682, 0xffdd }, { 4696, 0xedfd }, + { 4709, 0xbfee }, { 4722, 0xff7c }, { 4735, 0xe5fe }, { 4747, 0xffff }, + { 4763, 0xffff }, { 4779, 0xffff }, { 4795, 0xffff }, { 4811, 0xffff }, + /* 0x6b00 */ + { 4827, 0xffff }, { 4843, 0xffff }, { 4859, 0xff60 }, { 4869, 0xb97b }, + { 4880, 0xed37 }, { 4891, 0xfdff }, { 4906, 0xfb03 }, { 4915, 0xe5ff }, + { 4928, 0xd121 }, { 4934, 0xf3b3 }, { 4945, 0xfbfd }, { 4959, 0x7f47 }, + { 4970, 0x57d9 }, { 4980, 0xf503 }, { 4988, 0x73fd }, { 5000, 0xddd7 }, + /* 0x6c00 */ + { 5012, 0x5f1f }, { 5023, 0x7084 }, { 5028, 0x3829 }, { 5034, 0xdeca }, + { 5044, 0xf938 }, { 5053, 0x074e }, { 5060, 0xf8ec }, { 5070, 0x9daa }, + { 5079, 0x6c91 }, { 5086, 0x75e6 }, { 5096, 0x9105 }, { 5101, 0x04f1 }, + { 5107, 0xe9cf }, { 5118, 0xb706 }, { 5126, 0x32d0 }, { 5132, 0x8214 }, + /* 0x6d00 */ + { 5136, 0xa76d }, { 5146, 0xb17b }, { 5156, 0xb35f }, { 5167, 0x85d1 }, + { 5174, 0x1215 }, { 5179, 0xa9e1 }, { 5187, 0x39b6 }, { 5196, 0xee6f }, + { 5208, 0xacdb }, { 5218, 0x17c5 }, { 5226, 0x3024 }, { 5230, 0x7edb }, + { 5242, 0xe70e }, { 5251, 0x9cbd }, { 5261, 0xa7ac }, { 5270, 0xe575 }, + /* 0x6e00 */ + { 5280, 0x8bdf }, { 5291, 0xdb2c }, { 5300, 0x55c4 }, { 5307, 0xfaeb }, + { 5319, 0x9fe7 }, { 5331, 0x76a7 }, { 5341, 0xb7ff }, { 5355, 0x3fff }, + { 5369, 0x7d97 }, { 5380, 0x6efe }, { 5392, 0x7b5b }, { 5403, 0xd329 }, + { 5411, 0x7779 }, { 5422, 0x3b45 }, { 5430, 0xfc88 }, { 5438, 0xfdef }, + /* 0x6f00 */ + { 5452, 0x7dbb }, { 5464, 0xffc7 }, { 5477, 0x51ee }, { 5486, 0xbfb5 }, + { 5498, 0xd73f }, { 5510, 0xaeff }, { 5523, 0x9fbb }, { 5535, 0xeaeb }, + { 5546, 0x8cef }, { 5556, 0xefff }, { 5571, 0xff7d }, { 5585, 0xfdb7 }, + { 5598, 0xfdfa }, { 5611, 0xbff9 }, { 5624, 0x3ffc }, { 5636, 0xffff }, + /* 0x7000 */ + { 5652, 0xffff }, { 5668, 0xf3fd }, { 5681, 0xfff7 }, { 5696, 0xfddf }, + { 5710, 0x6fff }, { 5724, 0xbfff }, { 5739, 0x47ff }, { 5751, 0x2e9e }, + { 5760, 0xb9de }, { 5771, 0xcd8b }, { 5780, 0x07ff }, { 5791, 0xc475 }, + { 5799, 0xfaf0 }, { 5809, 0x74ff }, { 5821, 0x442f }, { 5828, 0xdd7f }, + /* 0x7100 */ + { 5841, 0xf9ff }, { 5855, 0xf896 }, { 5864, 0x7fbf }, { 5878, 0xffbc }, + { 5891, 0xabdf }, { 5903, 0xafff }, { 5917, 0xbe2f }, { 5928, 0xdaf3 }, + { 5939, 0x7bef }, { 5952, 0x7cef }, { 5964, 0xeefe }, { 5977, 0xfdd7 }, + { 5990, 0xbff7 }, { 6004, 0xffcf }, { 6018, 0xbf5e }, { 6030, 0xfdff }, + /* 0x7200 */ + { 6045, 0xffbf }, { 6060, 0xdfff }, { 6075, 0xeaff }, { 6088, 0x541c }, + { 6094, 0xce7f }, { 6106, 0x55bb }, { 6116, 0x3d39 }, { 6125, 0x39db }, + { 6135, 0x53ec }, { 6144, 0x7ffb }, { 6158, 0x4fff }, { 6171, 0xfc2e }, + { 6181, 0x9ee1 }, { 6190, 0xbd7a }, { 6201, 0x0cfc }, { 6209, 0xe260 }, + /* 0x7300 */ + { 6215, 0xbbf5 }, { 6227, 0x8717 }, { 6235, 0xa1d9 }, { 6243, 0x3c6d }, + { 6252, 0xdfff }, { 6267, 0xff7a }, { 6280, 0x4ffe }, { 6292, 0xbfff }, + { 6307, 0xb56f }, { 6318, 0x77bd }, { 6330, 0x35fb }, { 6341, 0xf372 }, + { 6351, 0x58fa }, { 6360, 0xbdfc }, { 6372, 0xdd5e }, { 6383, 0xfffb }, + /* 0x7400 */ + { 6398, 0x7997 }, { 6408, 0xf3fe }, { 6421, 0xaa9b }, { 6430, 0xef86 }, + { 6440, 0xfffd }, { 6455, 0x215f }, { 6463, 0xdfff }, { 6478, 0xbf3e }, + { 6490, 0xb774 }, { 6500, 0xaffe }, { 6513, 0xfc7f }, { 6526, 0xfbff }, + { 6541, 0xffff }, { 6557, 0xaffb }, { 6570, 0x3fa2 }, { 6579, 0x7f2f }, + /* 0x7500 */ + { 6591, 0x5fef }, { 6604, 0x68f5 }, { 6613, 0x44df }, { 6622, 0xb250 }, + { 6628, 0x26de }, { 6637, 0xe1ef }, { 6648, 0xfb9f }, { 6661, 0x7ceb }, + { 6672, 0x77b7 }, { 6684, 0x5929 }, { 6691, 0x27c4 }, { 6698, 0x8cc0 }, + { 6703, 0xd843 }, { 6710, 0xb68b }, { 6719, 0xf223 }, { 6727, 0x6dec }, + /* 0x7600 */ + { 6737, 0xebd4 }, { 6747, 0x745e }, { 6756, 0xd18a }, { 6763, 0x2ec6 }, + { 6771, 0xcff6 }, { 6783, 0xafaf }, { 6795, 0x77f7 }, { 6808, 0x96ff }, + { 6820, 0xb62b }, { 6829, 0xfdb5 }, { 6841, 0xbfef }, { 6855, 0x7fe9 }, + { 6867, 0x1a9b }, { 6875, 0x7628 }, { 6882, 0x3fdf }, { 6895, 0xace9 }, + /* 0x7700 */ + { 6904, 0xd46d }, { 6913, 0x79ff }, { 6926, 0x5cba }, { 6935, 0xea1f }, + { 6945, 0xff74 }, { 6957, 0xf3fc }, { 6969, 0xe691 }, { 6977, 0x1dff }, + { 6989, 0x8fce }, { 6999, 0x7ff9 }, { 7012, 0xe95a }, { 7021, 0x57d6 }, + { 7031, 0xdfff }, { 7046, 0xe77f }, { 7059, 0x8553 }, { 7066, 0x1eb7 }, + /* 0x7800 */ + { 7076, 0xcdf8 }, { 7086, 0x4a29 }, { 7092, 0xcd17 }, { 7101, 0xa06e }, + { 7108, 0xaf5e }, { 7119, 0xdf1a }, { 7129, 0x83ff }, { 7140, 0xef7f }, + { 7154, 0x8d7f }, { 7165, 0x6275 }, { 7173, 0xff55 }, { 7185, 0xbde0 }, + { 7194, 0xf1dd }, { 7205, 0xfdce }, { 7217, 0xeeff }, { 7231, 0xfb6b }, + /* 0x7900 */ + { 7243, 0xffdd }, { 7257, 0xbff7 }, { 7271, 0xffef }, { 7286, 0xa3ef }, + { 7297, 0xfcbc }, { 7308, 0x0337 }, { 7315, 0x5e5a }, { 7324, 0xfa7f }, + { 7337, 0x7bcc }, { 7347, 0xfbff }, { 7362, 0xff7f }, { 7377, 0x91f7 }, + { 7387, 0xd5b4 }, { 7396, 0x7ed9 }, { 7407, 0x5527 }, { 7415, 0xd6fe }, + /* 0x7a00 */ + { 7427, 0x97b2 }, { 7436, 0xbb6f }, { 7448, 0xfff6 }, { 7462, 0x4577 }, + { 7471, 0xffbf }, { 7486, 0xff7d }, { 7500, 0xffff }, { 7516, 0x782e }, + { 7524, 0xdea4 }, { 7533, 0x4e19 }, { 7540, 0xce9e }, { 7550, 0x7ff7 }, + { 7564, 0xf7ff }, { 7579, 0x3dbf }, { 7591, 0x5f96 }, { 7601, 0x59ff }, + /* 0x7b00 */ + { 7613, 0x72a7 }, { 7622, 0xb5cd }, { 7632, 0xa28e }, { 7639, 0xaaf5 }, + { 7649, 0x655f }, { 7659, 0xd2a8 }, { 7666, 0xbffa }, { 7679, 0xb559 }, + { 7688, 0xdfde }, { 7701, 0xcf4e }, { 7711, 0xc039 }, { 7717, 0xfeed }, + { 7730, 0xef3d }, { 7742, 0xd9f5 }, { 7753, 0xbb9d }, { 7764, 0xaf7d }, + /* 0x7c00 */ + { 7776, 0x677f }, { 7788, 0x7fbf }, { 7802, 0xfb3f }, { 7815, 0x7eff }, + { 7829, 0xdffc }, { 7842, 0xffff }, { 7858, 0xffff }, { 7874, 0xc7e7 }, + { 7885, 0xfdff }, { 7900, 0x0e59 }, { 7907, 0xbbcb }, { 7918, 0x8df1 }, + { 7927, 0xca5d }, { 7936, 0x6d1f }, { 7946, 0x7efe }, { 7959, 0xf6ff }, + /* 0x7d00 */ + { 7973, 0xfbff }, { 7988, 0xffff }, { 8004, 0x777a }, { 8015, 0xffff }, + { 8031, 0xffff }, { 8047, 0xffff }, { 8063, 0xbfff }, { 8078, 0xff7f }, + { 8093, 0xffff }, { 8109, 0xffff }, { 8125, 0xbfbf }, { 8139, 0xffff }, + { 8155, 0xffff }, { 8171, 0xffff }, { 8187, 0xffff }, { 8203, 0xffff }, + /* 0x7e00 */ + { 8219, 0xffff }, { 8235, 0xffff }, { 8251, 0xffff }, { 8267, 0xf7ff }, + { 8282, 0xff7d }, { 8296, 0xffff }, { 8312, 0xffff }, { 8328, 0xffff }, + { 8344, 0xfffb }, { 8359, 0x77ff }, { 8373, 0x4000 }, { 8374, 0x1810 }, + { 8377, 0x0000 }, { 8377, 0x0040 }, { 8378, 0x1010 }, { 8380, 0x0200 }, + /* 0x7f00 */ + { 8381, 0x0400 }, { 8382, 0x4001 }, { 8384, 0x0000 }, { 8384, 0xfa80 }, + { 8391, 0xffcb }, { 8404, 0x7a4c }, { 8412, 0xb8f9 }, { 8422, 0xbde9 }, + { 8433, 0xabfd }, { 8445, 0x1bef }, { 8456, 0x7f6d }, { 8468, 0x4cfa }, + { 8477, 0xabdd }, { 8488, 0x7ecf }, { 8500, 0xbd9c }, { 8510, 0xe7f4 }, + /* 0x8000 */ + { 8521, 0xc784 }, { 8528, 0xec0a }, { 8535, 0xf81a }, { 8543, 0x5615 }, + { 8550, 0xc3b3 }, { 8559, 0xfaeb }, { 8571, 0xf9ff }, { 8585, 0x7ffd }, + { 8599, 0xe526 }, { 8607, 0x42b7 }, { 8615, 0x11c8 }, { 8620, 0x0b69 }, + { 8627, 0x8fa0 }, { 8634, 0x813f }, { 8642, 0x404d }, { 8647, 0xcaa0 }, + /* 0x8100 */ + { 8653, 0x19bb }, { 8662, 0xbaa0 }, { 8669, 0x6fff }, { 8683, 0xbeb9 }, + { 8694, 0xe2bf }, { 8705, 0xf9c4 }, { 8714, 0x9d5e }, { 8724, 0x01ec }, + { 8730, 0x7afa }, { 8741, 0xc6fd }, { 8752, 0xfab7 }, { 8764, 0xf3f7 }, + { 8777, 0xebb0 }, { 8786, 0xffff }, { 8802, 0xcb77 }, { 8813, 0xa7e7 }, + /* 0x8200 */ + { 8824, 0xcf88 }, { 8832, 0x27ea }, { 8841, 0x42f1 }, { 8848, 0xb404 }, + { 8853, 0x756f }, { 8864, 0x7aff }, { 8877, 0x3eff }, { 8890, 0x19e2 }, + { 8897, 0x12eb }, { 8905, 0x4c79 }, { 8913, 0x008d }, { 8917, 0x9c64 }, + { 8924, 0x026d }, { 8930, 0x2641 }, { 8935, 0x7784 }, { 8943, 0xf56d }, + /* 0x8300 */ + { 8954, 0x2c01 }, { 8958, 0xe34d }, { 8967, 0x467f }, { 8977, 0xe885 }, + { 8984, 0x7d36 }, { 8994, 0x23e8 }, { 9001, 0x0004 }, { 9002, 0xc67f }, + { 9013, 0xbd9f }, { 9025, 0xa6f3 }, { 9035, 0xf0fe }, { 9046, 0xc820 }, + { 9050, 0x6b5c }, { 9059, 0x4eaf }, { 9069, 0xf9dc }, { 9080, 0xdcf8 }, + /* 0x8400 */ + { 9090, 0x07a5 }, { 9097, 0xcefd }, { 9109, 0xfe0f }, { 9120, 0xcefd }, + { 9132, 0xffbf }, { 9147, 0xe17d }, { 9157, 0xc5f5 }, { 9167, 0xfa95 }, + { 9177, 0xa47b }, { 9186, 0xed7f }, { 9199, 0x7ffd }, { 9213, 0x58eb }, + { 9222, 0xd9ed }, { 9233, 0x5fb4 }, { 9243, 0xef96 }, { 9254, 0x6ffe }, + /* 0x8500 */ + { 9267, 0xefff }, { 9282, 0x7b75 }, { 9293, 0xe7fd }, { 9306, 0xc07f }, + { 9315, 0xf8f7 }, { 9327, 0xbdbf }, { 9340, 0xfeef }, { 9354, 0xb1eb }, + { 9364, 0x7f4f }, { 9376, 0xe7ff }, { 9390, 0x3aef }, { 9401, 0xfd7e }, + { 9414, 0x7dfd }, { 9427, 0xefd6 }, { 9439, 0xfdef }, { 9453, 0x77ff }, + /* 0x8600 */ + { 9467, 0xffdf }, { 9482, 0xffbd }, { 9496, 0xfd7f }, { 9510, 0xeeff }, + { 9524, 0x1fff }, { 9537, 0xbbec }, { 9548, 0xa7fb }, { 9560, 0x01fd }, + { 9568, 0xc3f8 }, { 9577, 0xcfd7 }, { 9589, 0x6867 }, { 9597, 0xfb8c }, + { 9607, 0x312e }, { 9614, 0x34ec }, { 9622, 0x9def }, { 9634, 0xbce0 }, + /* 0x8700 */ + { 9642, 0xd872 }, { 9650, 0xaa53 }, { 9658, 0xbdd1 }, { 9668, 0x376d }, + { 9678, 0xac7f }, { 9689, 0xfd77 }, { 9702, 0xbfc6 }, { 9713, 0x87ae }, + { 9722, 0xd6d3 }, { 9732, 0x7f77 }, { 9745, 0x46ff }, { 9756, 0xdbd7 }, + { 9768, 0xf3be }, { 9780, 0xf7f1 }, { 9792, 0xbbde }, { 9804, 0xbdff }, + /* 0x8800 */ + { 9818, 0xfbf7 }, { 9832, 0xf797 }, { 9844, 0xfff9 }, { 9858, 0xedfb }, + { 9871, 0xcfce }, { 9882, 0xfd6f }, { 9895, 0xa4c1 }, { 9901, 0x1f7a }, + { 9911, 0xd6c9 }, { 9920, 0xefbb }, { 9933, 0xd7eb }, { 9945, 0xef7d }, + { 9958, 0xbd99 }, { 9968, 0x7ccb }, { 9978, 0xfec3 }, { 9989, 0xace4 }, + /* 0x8900 */ + { 9997, 0xfbfb }, { 10011, 0xf1f2 }, { 10021, 0xf3dd }, { 10033, 0xffae }, + { 10046, 0xffed }, { 10060, 0x3fff }, { 10074, 0xffbf }, { 10089, 0x77ff }, + { 10103, 0xffb5 }, { 10116, 0xffff }, { 10132, 0xffff }, { 10148, 0xffff }, + { 10164, 0x2009 }, { 10167, 0xabb8 }, { 10176, 0x7797 }, { 10187, 0xfff7 }, + /* 0x8a00 */ + { 10202, 0xff7e }, { 10216, 0xffff }, { 10232, 0xffff }, { 10248, 0xbfff }, + { 10263, 0xfeff }, { 10278, 0xffff }, { 10294, 0xffff }, { 10310, 0xfdff }, + { 10325, 0xf9ff }, { 10339, 0xfff7 }, { 10354, 0xffff }, { 10370, 0xffff }, + { 10386, 0xffff }, { 10402, 0xffff }, { 10418, 0xffff }, { 10434, 0xffff }, + /* 0x8b00 */ + { 10450, 0xff7f }, { 10465, 0xffff }, { 10481, 0xffbf }, { 10496, 0xffff }, + { 10512, 0xffff }, { 10528, 0xffff }, { 10544, 0xefbf }, { 10558, 0xffff }, + { 10574, 0xffff }, { 10590, 0xffff }, { 10606, 0x1000 }, { 10607, 0x0802 }, + { 10609, 0x0080 }, { 10610, 0x0001 }, { 10611, 0x0400 }, { 10612, 0x0000 }, + /* 0x8c00 */ + { 10612, 0x0200 }, { 10613, 0x4000 }, { 10614, 0x0000 }, { 10614, 0xff00 }, + { 10622, 0xed3d }, { 10633, 0xfbdf }, { 10647, 0xf3f9 }, { 10659, 0xf8f7 }, + { 10671, 0xe9db }, { 10682, 0xfeef }, { 10696, 0xffff }, { 10712, 0xffff }, + { 10728, 0xffff }, { 10744, 0xffff }, { 10760, 0xffff }, { 10776, 0xffff }, + /* 0x8d00 */ + { 10792, 0xffff }, { 10808, 0x1fff }, { 10821, 0x0001 }, { 10822, 0x0000 }, + { 10822, 0x0000 }, { 10822, 0x8086 }, { 10826, 0xd720 }, { 10833, 0xff06 }, + { 10843, 0xf3cd }, { 10854, 0x7fed }, { 10867, 0xfff7 }, { 10882, 0x2ac5 }, + { 10889, 0x27a7 }, { 10898, 0x133d }, { 10906, 0x62e7 }, { 10915, 0xd057 }, + /* 0x8e00 */ + { 10923, 0x69df }, { 10934, 0x1fef }, { 10946, 0x29f3 }, { 10955, 0xd9dd }, + { 10966, 0xf068 }, { 10973, 0xfdf9 }, { 10986, 0x4dbf }, { 10997, 0x6faa }, + { 11007, 0x7f5d }, { 11019, 0xafee }, { 11031, 0x67ff }, { 11044, 0xfbfb }, + { 11058, 0xbfff }, { 11073, 0xffff }, { 11089, 0xffff }, { 11105, 0xffff }, + /* 0x8f00 */ + { 11121, 0xffff }, { 11137, 0xffff }, { 11153, 0xffff }, { 11169, 0xffff }, + { 11185, 0xffff }, { 11201, 0xffff }, { 11217, 0x043f }, { 11224, 0x0000 }, + { 11224, 0x1001 }, { 11226, 0x2004 }, { 11228, 0xf4f7 }, { 11240, 0x9dbc }, + { 11250, 0xbe49 }, { 11259, 0x04c4 }, { 11263, 0x908b }, { 11269, 0xdc76 }, + /* 0x9000 */ + { 11279, 0x5180 }, { 11283, 0x1328 }, { 11288, 0x1fb8 }, { 11297, 0xa69f }, + { 11307, 0x5f69 }, { 11317, 0xf670 }, { 11326, 0x9ed3 }, { 11336, 0x5fcf }, + { 11348, 0xf6f2 }, { 11359, 0xd555 }, { 11368, 0x2bb1 }, { 11376, 0xb084 }, + { 11381, 0x3b4d }, { 11390, 0xc774 }, { 11399, 0x5639 }, { 11407, 0x9eef }, + /* 0x9100 */ + { 11419, 0xffeb }, { 11433, 0xbdff }, { 11447, 0x7ff3 }, { 11460, 0xfdfd }, + { 11474, 0x01b7 }, { 11481, 0x9b7a }, { 11491, 0x29c1 }, { 11497, 0x1c08 }, + { 11501, 0xc55f }, { 11511, 0xf3f8 }, { 11522, 0x1bf3 }, { 11532, 0xfbcf }, + { 11545, 0x097f }, { 11554, 0xeffd }, { 11568, 0xffff }, { 11584, 0xffff }, + /* 0x9200 */ + { 11600, 0xffff }, { 11616, 0xffff }, { 11632, 0xffff }, { 11648, 0xffff }, + { 11664, 0xffff }, { 11680, 0xffff }, { 11696, 0xffff }, { 11712, 0xffef }, + { 11727, 0xbfff }, { 11742, 0xffff }, { 11758, 0xbfff }, { 11773, 0xffff }, + { 11789, 0xfeff }, { 11804, 0xffff }, { 11820, 0xffff }, { 11836, 0xffff }, + /* 0x9300 */ + { 11852, 0xffff }, { 11868, 0xffff }, { 11884, 0xffff }, { 11900, 0xbfff }, + { 11915, 0xffff }, { 11931, 0xffff }, { 11947, 0xfbff }, { 11962, 0xffff }, + { 11978, 0x7fff }, { 11993, 0xffff }, { 12009, 0xffff }, { 12025, 0xffff }, + { 12041, 0xfbff }, { 12056, 0xffbf }, { 12071, 0xffff }, { 12087, 0xffff }, + /* 0x9400 */ + { 12103, 0xffff }, { 12119, 0xffff }, { 12135, 0xffff }, { 12151, 0xbfff }, + { 12166, 0xffff }, { 12182, 0xffff }, { 12198, 0xf7ff }, { 12213, 0xffff }, + { 12229, 0x001f }, { 12234, 0x0142 }, { 12237, 0x0000 }, { 12237, 0x0000 }, + { 12237, 0x8080 }, { 12239, 0x0418 }, { 12242, 0x0040 }, { 12243, 0x0800 }, + /* 0x9500 */ + { 12244, 0x0000 }, { 12244, 0x1000 }, { 12245, 0x0081 }, { 12247, 0x2008 }, + { 12249, 0x0908 }, { 12252, 0x0420 }, { 12254, 0x4001 }, { 12256, 0x7fb0 }, + { 12266, 0xffff }, { 12282, 0xffff }, { 12298, 0xffff }, { 12314, 0xffff }, + { 12330, 0xffff }, { 12346, 0xffff }, { 12362, 0x10ff }, { 12371, 0x8000 }, + /* 0x9600 */ + { 12372, 0x0080 }, { 12373, 0x4908 }, { 12377, 0xbbf9 }, { 12389, 0x4781 }, + { 12395, 0xc40a }, { 12400, 0x77ce }, { 12411, 0xe869 }, { 12419, 0xff0b }, + { 12430, 0x569f }, { 12440, 0xec6e }, { 12450, 0xff7f }, { 12465, 0x8db6 }, + { 12474, 0x0d0c }, { 12479, 0xffdb }, { 12493, 0x78fe }, { 12504, 0xbd37 }, + /* 0x9700 */ + { 12515, 0x1c2c }, { 12521, 0xafb7 }, { 12533, 0xdbff }, { 12547, 0xbcfa }, + { 12558, 0xffff }, { 12574, 0xb5b3 }, { 12584, 0xfdd8 }, { 12595, 0xefa7 }, + { 12607, 0xd7df }, { 12620, 0xfee9 }, { 12632, 0x57f6 }, { 12643, 0xffeb }, + { 12657, 0xffff }, { 12673, 0xffff }, { 12689, 0xc13f }, { 12698, 0xff97 }, + /* 0x9800 */ + { 12711, 0xffff }, { 12727, 0xffff }, { 12743, 0xffff }, { 12759, 0xffff }, + { 12775, 0xffff }, { 12791, 0xffff }, { 12807, 0xffff }, { 12823, 0x001f }, + { 12828, 0x4800 }, { 12830, 0x0224 }, { 12833, 0xff08 }, { 12842, 0xffff }, + { 12858, 0xbfff }, { 12873, 0x38d1 }, { 12880, 0xfe7f }, { 12894, 0xffff }, + /* 0x9900 */ + { 12910, 0xdfff }, { 12925, 0xfffe }, { 12940, 0xbfff }, { 12955, 0xffff }, + { 12971, 0xffff }, { 12987, 0xffcf }, { 13001, 0x0057 }, { 13006, 0x4b08 }, + { 13011, 0x520c }, { 13016, 0xfc00 }, { 13022, 0xfedf }, { 13036, 0xffff }, + { 13052, 0xffff }, { 13068, 0xffff }, { 13084, 0xffff }, { 13100, 0xffff }, + /* 0x9a00 */ + { 13116, 0xffff }, { 13132, 0xffff }, { 13148, 0xffff }, { 13164, 0xffff }, + { 13180, 0xffff }, { 13196, 0xffff }, { 13212, 0x0fff }, { 13224, 0x0004 }, + { 13225, 0x6208 }, { 13229, 0x0230 }, { 13232, 0xfe40 }, { 13240, 0xea3c }, + { 13249, 0xe7d8 }, { 13259, 0x7ef5 }, { 13271, 0x57bd }, { 13282, 0xf5ff }, + /* 0x9b00 */ + { 13296, 0x7ef7 }, { 13309, 0x7ff7 }, { 13323, 0x7ff7 }, { 13337, 0xe7fb }, + { 13350, 0x5c41 }, { 13356, 0xffed }, { 13370, 0xffff }, { 13386, 0xffff }, + { 13402, 0xffff }, { 13418, 0xffff }, { 13434, 0xffff }, { 13450, 0xffff }, + { 13466, 0xffff }, { 13482, 0xffff }, { 13498, 0xffff }, { 13514, 0xffff }, + /* 0x9c00 */ + { 13530, 0xffff }, { 13546, 0xffff }, { 13562, 0xffff }, { 13578, 0xffff }, + { 13594, 0xffff }, { 13610, 0xffff }, { 13626, 0xffff }, { 13642, 0x6fff }, + { 13656, 0x9619 }, { 13663, 0x23c8 }, { 13669, 0x9400 }, { 13672, 0xc200 }, + { 13675, 0x0307 }, { 13680, 0x0c06 }, { 13684, 0xfffb }, { 13699, 0xffff }, + /* 0x9d00 */ + { 13715, 0xffff }, { 13731, 0xffff }, { 13747, 0xffff }, { 13763, 0xffff }, + { 13779, 0xffff }, { 13795, 0xffff }, { 13811, 0xffff }, { 13827, 0xffff }, + { 13843, 0xffff }, { 13859, 0xffff }, { 13875, 0xffff }, { 13891, 0xffff }, + { 13907, 0xffff }, { 13923, 0xffff }, { 13939, 0xffff }, { 13955, 0xffff }, + /* 0x9e00 */ + { 13971, 0xffff }, { 13987, 0x7fff }, { 14002, 0x4090 }, { 14005, 0x1811 }, + { 14009, 0x2001 }, { 14011, 0xa25d }, { 14019, 0xc027 }, { 14025, 0x3ff4 }, + { 14036, 0xf67b }, { 14048, 0x5ff3 }, { 14060, 0xffbf }, { 14075, 0x96ef }, + { 14086, 0x1def }, { 14097, 0x46ed }, { 14106, 0x795a }, { 14115, 0xa5ff }, + /* 0x9f00 */ + { 14127, 0x97ff }, { 14140, 0xfd76 }, { 14152, 0x6ffa }, { 14164, 0x957f }, + { 14175, 0xffef }, { 14190, 0xfffc }, { 14204, 0xffff }, { 14220, 0x7fff }, + { 14235, 0xe006 }, { 14240, 0x71ff }, { 14252, 0x003e }, +}; +static const Summary16 gbkext_inv_uni2indx_pagef9[19] = { + /* 0xf900 */ + { 14257, 0x0000 }, { 14257, 0x0000 }, { 14257, 0x1000 }, { 14258, 0x0000 }, + { 14258, 0x0000 }, { 14258, 0x0000 }, { 14258, 0x0000 }, { 14258, 0x0200 }, + { 14259, 0x0000 }, { 14259, 0x0020 }, { 14260, 0x0000 }, { 14260, 0x0000 }, + { 14260, 0x0000 }, { 14260, 0x0000 }, { 14260, 0x0080 }, { 14261, 0x0002 }, + /* 0xfa00 */ + { 14262, 0xf000 }, { 14266, 0x811a }, { 14271, 0x039b }, +}; +static const Summary16 gbkext_inv_uni2indx_pagefe[31] = { + /* 0xfe00 */ + { 14278, 0x0000 }, { 14278, 0x0000 }, { 14278, 0x0000 }, { 14278, 0x0001 }, + { 14279, 0xfe00 }, { 14286, 0xfef7 }, { 14300, 0x0f7f }, { 14311, 0x0000 }, + { 14311, 0x0000 }, { 14311, 0x0000 }, { 14311, 0x0000 }, { 14311, 0x0000 }, + { 14311, 0x0000 }, { 14311, 0x0000 }, { 14311, 0x0000 }, { 14311, 0x0000 }, + /* 0xff00 */ + { 14311, 0x0000 }, { 14311, 0x0000 }, { 14311, 0x0000 }, { 14311, 0x0000 }, + { 14311, 0x0000 }, { 14311, 0x0000 }, { 14311, 0x0000 }, { 14311, 0x0000 }, + { 14311, 0x0000 }, { 14311, 0x0000 }, { 14311, 0x0000 }, { 14311, 0x0000 }, + { 14311, 0x0000 }, { 14311, 0x0000 }, { 14311, 0x0014 }, +}; + +static int +gbkext_inv_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc >= 0x0200 && wc < 0x02e0) + summary = &gbkext_inv_uni2indx_page02[(wc>>4)-0x020]; + else if (wc >= 0x2000 && wc < 0x22c0) + summary = &gbkext_inv_uni2indx_page20[(wc>>4)-0x200]; + else if (wc >= 0x2500 && wc < 0x2610) + summary = &gbkext_inv_uni2indx_page25[(wc>>4)-0x250]; + else if (wc >= 0x3000 && wc < 0x3100) + summary = &gbkext_inv_uni2indx_page30[(wc>>4)-0x300]; + else if (wc >= 0x3200 && wc < 0x33e0) + summary = &gbkext_inv_uni2indx_page32[(wc>>4)-0x320]; + else if (wc >= 0x4e00 && wc < 0x9fb0) + summary = &gbkext_inv_uni2indx_page4e[(wc>>4)-0x4e0]; + else if (wc >= 0xf900 && wc < 0xfa30) + summary = &gbkext_inv_uni2indx_pagef9[(wc>>4)-0xf90]; + else if (wc >= 0xfe00 && wc < 0xfff0) + summary = &gbkext_inv_uni2indx_pagefe[(wc>>4)-0xfe0]; + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = gbkext_inv_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/georgian_academy.h b/graf2d/win32gdk/gdk/src/iconv/georgian_academy.h new file mode 100644 index 0000000000000..ddbe57806d1cb --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/georgian_academy.h @@ -0,0 +1,106 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GEORGIAN-ACADEMY + */ + +static const unsigned short georgian_academy_2uni[32] = { + /* 0x80 */ + 0x0080, 0x0081, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, + 0x02c6, 0x2030, 0x0160, 0x2039, 0x0152, 0x008d, 0x008e, 0x008f, + /* 0x90 */ + 0x0090, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0x02dc, 0x2122, 0x0161, 0x203a, 0x0153, 0x009d, 0x009e, 0x0178, +}; + +static int +georgian_academy_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c >= 0x80 && c < 0xa0) + *pwc = (ucs4_t) georgian_academy_2uni[c-0x80]; + else if (c >= 0xc0 && c < 0xe7) + *pwc = (ucs4_t) c + 0x1010; + else + *pwc = (ucs4_t) c; + return 1; +} + +static const unsigned char georgian_academy_page00[32] = { + 0x80, 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x8d, 0x8e, 0x8f, /* 0x88-0x8f */ + 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x9d, 0x9e, 0x00, /* 0x98-0x9f */ +}; +static const unsigned char georgian_academy_page01[72] = { + 0x00, 0x00, 0x8c, 0x9c, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x8a, 0x9a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x9f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x83, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char georgian_academy_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char georgian_academy_page20[48] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; + +static int +georgian_academy_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x0080 && wc < 0x00a0) + c = georgian_academy_page00[wc-0x0080]; + else if ((wc >= 0x00a0 && wc < 0x00c0) || (wc >= 0x00e7 && wc < 0x0100)) + c = wc; + else if (wc >= 0x0150 && wc < 0x0198) + c = georgian_academy_page01[wc-0x0150]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = georgian_academy_page02[wc-0x02c0]; + else if (wc >= 0x10d0 && wc < 0x10f7) + c = wc-0x1010; + else if (wc >= 0x2010 && wc < 0x2040) + c = georgian_academy_page20[wc-0x2010]; + else if (wc == 0x2122) + c = 0x99; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/georgian_ps.h b/graf2d/win32gdk/gdk/src/iconv/georgian_ps.h new file mode 100644 index 0000000000000..e23dbae1cd087 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/georgian_ps.h @@ -0,0 +1,123 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * GEORGIAN-PS + */ + +static const unsigned short georgian_ps_2uni_1[32] = { + /* 0x80 */ + 0x0080, 0x0081, 0x201a, 0x0192, 0x201e, 0x2026, 0x2020, 0x2021, + 0x02c6, 0x2030, 0x0160, 0x2039, 0x0152, 0x008d, 0x008e, 0x008f, + /* 0x90 */ + 0x0090, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0x02dc, 0x2122, 0x0161, 0x203a, 0x0153, 0x009d, 0x009e, 0x0178, +}; +static const unsigned short georgian_ps_2uni_2[39] = { + /* 0xc0 */ + 0x10d0, 0x10d1, 0x10d2, 0x10d3, 0x10d4, 0x10d5, 0x10d6, 0x10f1, + 0x10d7, 0x10d8, 0x10d9, 0x10da, 0x10db, 0x10dc, 0x10f2, 0x10dd, + /* 0xd0 */ + 0x10de, 0x10df, 0x10e0, 0x10e1, 0x10e2, 0x10f3, 0x10e3, 0x10e4, + 0x10e5, 0x10e6, 0x10e7, 0x10e8, 0x10e9, 0x10ea, 0x10eb, 0x10ec, + /* 0xe0 */ + 0x10ed, 0x10ee, 0x10f4, 0x10ef, 0x10f0, 0x10f5, +}; + +static int +georgian_ps_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c >= 0x80 && c < 0xa0) + *pwc = (ucs4_t) georgian_ps_2uni_1[c-0x80]; + else if (c >= 0xc0 && c < 0xe6) + *pwc = (ucs4_t) georgian_ps_2uni_2[c-0xc0]; + else + *pwc = (ucs4_t) c; + return 1; +} + +static const unsigned char georgian_ps_page00[32] = { + 0x80, 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x8d, 0x8e, 0x8f, /* 0x88-0x8f */ + 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x9d, 0x9e, 0x00, /* 0x98-0x9f */ +}; +static const unsigned char georgian_ps_page01[72] = { + 0x00, 0x00, 0x8c, 0x9c, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x8a, 0x9a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x9f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x83, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char georgian_ps_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char georgian_ps_page10[40] = { + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc8, /* 0xd0-0xd7 */ + 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xcf, 0xd0, 0xd1, /* 0xd8-0xdf */ + 0xd2, 0xd3, 0xd4, 0xd6, 0xd7, 0xd8, 0xd9, 0xda, /* 0xe0-0xe7 */ + 0xdb, 0xdc, 0xdd, 0xde, 0xdf, 0xe0, 0xe1, 0xe3, /* 0xe8-0xef */ + 0xe4, 0xc7, 0xce, 0xd5, 0xe2, 0xe5, 0x00, 0x00, /* 0xf0-0xf7 */ +}; +static const unsigned char georgian_ps_page20[48] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; + +static int +georgian_ps_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x0080 && wc < 0x00a0) + c = georgian_ps_page00[wc-0x0080]; + else if ((wc >= 0x00a0 && wc < 0x00c0) || (wc >= 0x00e6 && wc < 0x0100)) + c = wc; + else if (wc >= 0x0150 && wc < 0x0198) + c = georgian_ps_page01[wc-0x0150]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = georgian_ps_page02[wc-0x02c0]; + else if (wc >= 0x10d0 && wc < 0x10f8) + c = georgian_ps_page10[wc-0x10d0]; + else if (wc >= 0x2010 && wc < 0x2040) + c = georgian_ps_page20[wc-0x2010]; + else if (wc == 0x2122) + c = 0x99; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/hkscs1999.h b/graf2d/win32gdk/gdk/src/iconv/hkscs1999.h new file mode 100644 index 0000000000000..3732763396858 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/hkscs1999.h @@ -0,0 +1,3005 @@ +/* + * Copyright (C) 1999-2006 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * HKSCS:1999 + */ + +static const unsigned short hkscs1999_2uni_page88[627] = { + /* 0x88 */ + 0x06c0, 0x06c1, 0x06c2, 0x06c3, 0x06c4, 0x720c, 0x06c5, 0x71d1, + 0x71cd, 0x06c6, 0x06c7, 0x71cb, 0x8c68, 0x06c8, 0x71ca, 0x06c9, + 0x06ca, 0x06cb, 0x06cc, 0x720e, 0x06cd, 0x06ce, 0x0080, 0x0041, + 0x010d, 0x0040, 0x0092, 0x0049, 0x009a, 0x0048, 0x00cc, 0x0053, + 0x0111, 0x0052, 0x70fd, 0x02be, 0x70fd, 0x02c0, 0x004a, 0x0081, + 0x0061, 0x010e, 0x0060, 0x0151, 0x0093, 0x0069, 0x009b, 0x0068, + 0x00ab, 0x006d, 0x0110, 0x006c, 0x00cd, 0x0073, 0x0112, 0x0072, + 0x00eb, 0x007a, 0x0114, 0x0079, 0x0116, 0x0118, 0x011a, 0x011c, + 0x007c, 0x70fd, 0x02bf, 0x70fd, 0x02c1, 0x006a, 0x0161, 0x041a, + 0x041b, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + /* 0x89 */ + 0xf029, 0x8005, 0x70fd, 0x374a, 0x70fd, 0x70fd, 0x207d, 0x40dd, + 0x6dce, 0x62df, 0x70fd, 0x70fd, 0xd275, 0x36d1, 0x215a, 0x2168, + 0x21e8, 0x2396, 0x23b4, 0x23dc, 0x2424, 0x24e1, 0x24e8, 0x257b, + 0x258e, 0x2611, 0x2618, 0x2922, 0x2b30, 0x2b44, 0x2b47, 0x2b72, + 0x2b74, 0x2da6, 0x2dde, 0x2ddf, 0x2eda, 0x30c6, 0x327b, 0x37c9, + 0x3a3e, 0x3a44, 0x3aa5, 0x3f8e, 0x42bc, 0x4735, 0x50a4, 0x50ac, + 0x50ba, 0x50c7, 0x50cf, 0x50df, 0x5106, 0x5137, 0x547a, 0x54cf, + 0x556f, 0x5b46, 0x5d3e, 0x5d62, 0x60a6, 0x60a7, 0x60ae, 0x4611, + 0x4efc, 0x4fcd, 0x3b86, 0x4cc9, 0x2467, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x628c, 0x4ab8, 0x625e, 0x52bc, 0x70fd, 0x5e4b, 0x52f6, + 0x78e7, 0x70fd, 0x70fd, 0x529f, 0x6f47, 0x1f8d, 0x6e49, 0x6e8c, + 0x1efe, 0xebb6, 0xcd4e, 0x6e8a, 0xee73, 0x0901, 0x70fd, 0x409a, + 0x543e, 0x4719, 0x70fd, 0x1c11, 0x6b6c, 0x6b8f, 0x7019, 0x4b87, + 0xdcac, 0x8a8a, 0x7650, 0x9526, 0x2064, 0x20c1, 0x20c0, 0x20c7, + 0x20ff, 0x212b, 0x2177, 0x078c, 0x21fd, 0x1148, 0x2243, 0x22c8, + 0x07bd, 0x07d3, 0x07e5, 0x23c6, 0x2b45, 0x241b, 0x243c, 0x2445, + 0x20c9, 0x24b9, 0x24d0, 0x2567, 0x0907, 0x25e9, 0x0891, 0x25f0, + 0x0893, 0x2602, 0x2663, 0x08ad, 0x08b2, 0x09c1, 0x26d3, 0x26e3, + 0x26f4, 0x26f9, 0x2710, 0x272f, 0x2758, 0x2763, 0x2768, 0x08d8, + 0x277f, 0x08e5, 0x08ff, 0x2817, 0x0905, + /* 0x8a */ + 0xd784, 0x2765, 0x70fd, 0x7b02, 0x7bd5, 0xb42b, 0x27d0, 0x96c6, + 0x0d2c, 0x7401, 0x5f86, 0xb138, 0xe665, 0x1353, 0xd97e, 0x497a, + 0x9638, 0x0d74, 0x1ad5, 0xda1d, 0xc7b2, 0xb16a, 0x371d, 0x7c3c, + 0x7e74, 0x7b95, 0x7fb4, 0x36cd, 0x5fbe, 0x7d56, 0x7acb, 0x7e24, + 0x96a9, 0xdad6, 0xaa13, 0x70fd, 0x7c06, 0xe9cd, 0xd9a9, 0x1af4, + 0xb227, 0x96c2, 0x6bb2, 0x0da7, 0xe6f4, 0x12ed, 0x0846, 0xb587, + 0xe754, 0xd3c8, 0x9744, 0x6dee, 0x6915, 0x70fd, 0x16d9, 0xbfe5, + 0x36f4, 0x2723, 0x974c, 0x95ca, 0x7f37, 0x0d3b, 0x7f2f, 0xc49a, + 0xc4d6, 0xd4a0, 0x372a, 0xb392, 0x7b03, 0x5fa8, 0x8de1, 0xe14c, + 0x7731, 0x70fd, 0x1b0b, 0x7269, 0x12fa, 0x2ab3, 0x978d, 0x70fd, + 0xaac8, 0x75bc, 0xbfd7, 0x7e0c, 0x7c56, 0x27b9, 0x13bb, 0x16ba, + 0x70fd, 0x1d74, 0x94e6, 0x7f5d, 0x53aa, 0x69f5, 0x7c5c, 0x35b9, + 0x0d3e, 0x9275, 0x5f00, 0x28e1, 0x36bc, 0x1143, 0x70fd, 0xf101, + 0x7cc9, 0x950f, 0x96c9, 0x70fd, 0x7f88, 0xa142, 0x0cd2, 0x0d46, + 0xdb1b, 0x08b8, 0xbdc9, 0x8d07, 0x2892, 0x7df1, 0x96b2, 0xe720, + 0x07fc, 0x3e7d, 0xb1bb, 0x70fd, 0x70fd, 0xd0f4, 0x988b, 0x8e48, + 0xf15b, 0xe24d, 0x7d3a, 0x7af4, 0xc5dc, 0x5193, 0x7f8f, 0x9303, + 0x9439, 0x093b, 0xb4a3, 0x7d4c, 0x7e4d, 0x7d6a, 0x1293, 0x7df0, + 0x7c07, 0x800f, 0x7d0c, 0x70fd, 0x7d6b, 0x7a69, 0x7c08, 0x7f80, + 0x7ffd, 0x12f9, 0x9196, 0x3672, 0x7e6d, + /* 0x8b */ + 0x9d34, 0xd1b9, 0x95ce, 0x7c3e, 0x7c3f, 0x9651, 0x9655, 0x0d58, + 0x7d58, 0x7f87, 0x7dee, 0xf132, 0xc890, 0xe252, 0xe2d9, 0xe24a, + 0x66aa, 0x270c, 0x54c4, 0x27f9, 0x70fd, 0xec83, 0x6d26, 0x6bb6, + 0xd29e, 0x97ee, 0x4340, 0x536d, 0x52ec, 0x2e5c, 0xc3b2, 0x5334, + 0x0ad7, 0x259f, 0xd97d, 0x62b6, 0x7dba, 0x7ccf, 0x7d37, 0x7dbb, + 0x091d, 0xb16b, 0x0949, 0x7b96, 0x28ef, 0x92b5, 0x7f89, 0x7cd0, + 0x7d38, 0x7f38, 0x8008, 0xda87, 0x8315, 0x7d39, 0xb1d0, 0x97a4, + 0x2c94, 0x7edd, 0x7ede, 0x7fb5, 0x7fb6, 0x29dc, 0x7cd1, 0xd214, + 0xdb4d, 0x7e75, 0x7d3b, 0xb47e, 0x0a43, 0x7e76, 0x8040, 0xb598, + 0xefbd, 0xae5a, 0x867a, 0xa6b7, 0xdafc, 0x2ad9, 0x24a8, 0x095a, + 0xb8bd, 0x4db2, 0x2da8, 0x1b00, 0x1dec, 0x6fa7, 0x1ce7, 0x6d1f, + 0x6c8d, 0xbb74, 0x9abd, 0x283b, 0x0932, 0x28c9, 0x2068, 0x2b42, + 0x8901, 0xf238, 0x6851, 0x7186, 0x209b, 0x20fb, 0x087e, 0x2e63, + 0x3191, 0x3204, 0x0c3a, 0x348c, 0x3775, 0x3dba, 0x3e75, 0x3e7a, + 0x426c, 0x442b, 0x206c, 0x44ad, 0xad69, 0x5152, 0x4b3b, 0x4ef9, + 0x5153, 0xc12a, 0x0801, 0x70fd, 0xc1cb, 0x5202, 0x5280, 0xc412, + 0xc711, 0x259d, 0x59e4, 0x5b41, 0xd3b2, 0x5d20, 0x5e5d, 0x6585, + 0x6678, 0x667f, 0x66e8, 0xe30f, 0x68e6, 0x6975, 0x69ce, 0x69de, + 0x6a63, 0xe790, 0x6d7c, 0x6e9f, 0x6f44, 0x3daf, 0x7047, 0x2077, + 0x7187, 0x671d, 0x3477, 0x65a2, +}; +static const unsigned short hkscs1999_2uni_page8d[3140] = { + /* 0x8d */ + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x2f7e, 0x2f88, 0x2f96, 0x10fc, 0x0b4f, 0x2fe4, 0x2ff9, 0x0b60, + 0x0b78, 0x3082, 0x30fd, 0x3165, 0x31c3, 0x0c48, 0x0c54, 0x0c7f, + 0x0c8d, 0x3317, 0x337d, 0x2f25, 0x0cc9, 0x33f7, 0x33f9, 0x340f, + 0x0cf8, 0x346c, 0x34d0, 0x3525, 0x3558, 0x0d38, 0x28f1, 0x0d43, + 0x3622, 0x363b, 0x3647, 0x369a, 0x0d8b, 0x3700, 0x2f55, 0x2861, + 0x701f, 0x0dd7, 0x37c6, 0x0dfd, 0x383f, 0x3893, 0x0e32, 0x38d2, + 0x0e62, 0x3956, 0x0e82, 0x39e4, 0x3a40, 0x0e98, 0x3a8a, 0x3ac4, + 0x0eb2, 0x0eb1, 0x0ebb, 0x3b49, 0x3b83, 0x445c, 0x3ba4, 0x3bdf, + 0x3bc5, 0x0efc, 0x3c16, 0x0f1d, 0x3ca5, 0x3cb4, 0x3cb1, 0x3cc2, + 0x0f2c, 0x3cd9, 0x0f32, 0x3ceb, 0x3cf5, 0x3d14, 0x3d36, 0x3dc1, + 0x3e01, 0x3e2a, 0x3eb5, 0x3eea, 0x0fcb, 0x3f42, 0x3f46, 0x3f66, + 0x3fc1, 0x0fef, 0x3fe4, 0x3ff1, 0x4015, 0x4018, 0x4029, 0x4086, + 0xdfc0, 0x40bb, 0x40e2, 0x40da, 0x6fff, 0x40e8, 0x40e9, 0x4124, + 0x4134, 0x1046, 0xa481, 0x4181, 0x41be, 0x106a, 0x1075, 0x43b7, + 0x2ed9, 0x108a, 0x422c, 0x1091, 0x4250, 0x4254, 0x426f, 0x427f, + 0x4289, 0x73e5, 0x16c1, 0x0931, 0x7d98, + /* 0x8e */ + 0xa417, 0x29fe, 0xcc13, 0x433e, 0xb920, 0x098e, 0x3be2, 0xe1e9, + 0x2db4, 0x4c49, 0xb9a1, 0xe659, 0x4c65, 0x4c7d, 0xba6c, 0x4cbb, + 0x4cb0, 0x4cc2, 0x4cc3, 0x43d1, 0xc30d, 0x14ca, 0x4cda, 0x4cdd, + 0x4cea, 0x14ef, 0x26f2, 0xbc01, 0x4d0b, 0x4d55, 0x4d29, 0xb5ce, + 0xbcfe, 0x4da2, 0x4d6f, 0x559c, 0xbbb4, 0xc9bf, 0x4dd0, 0x5621, + 0x4d92, 0x70fd, 0xbd20, 0x10ad, 0xbc65, 0x5692, 0x4dfa, 0x70fd, + 0x4e35, 0xbcc1, 0x4e44, 0x4e83, 0xad02, 0x4ea6, 0x38bd, 0xaab8, + 0x4ec9, 0x4ec7, 0x4ee6, 0x4e74, 0x4ef3, 0x4ef5, 0x70fd, 0x5067, + 0x181d, 0xcb84, 0x4f5d, 0xcc16, 0x468d, 0x4f89, 0x4fab, 0x4335, + 0x4fb3, 0x70fd, 0xa597, 0xbf69, 0x4fe4, 0x1013, 0x4ff5, 0x8639, + 0x4fe5, 0xdbed, 0x70fd, 0xc021, 0xc05a, 0x506e, 0x5092, 0x162b, + 0x656c, 0x5027, 0x5140, 0x5141, 0x5147, 0x4b36, 0xc150, 0x6ae1, + 0x5197, 0xc1d1, 0x51a3, 0x84a1, 0x7168, 0x185c, 0xa066, 0x1803, + 0xdbba, 0x51fa, 0xc309, 0x70fd, 0x5208, 0x521d, 0x70fd, 0x522f, + 0xedc7, 0xca03, 0x523b, 0x523c, 0x5261, 0x9214, 0x1c89, 0xc426, + 0xa363, 0xc4a8, 0x3965, 0x52a7, 0xe048, 0x5307, 0x531a, 0x2af0, + 0x91f6, 0x3ebf, 0xc318, 0xb2f8, 0x3727, 0x834a, 0x5418, 0x869e, + 0x3c93, 0xaee5, 0xaf15, 0x177a, 0x5429, 0x7a0d, 0xc812, 0xa2fe, + 0x2239, 0x83bd, 0x56e2, 0x5562, 0xc84a, 0xae27, 0x9e30, 0x85b3, + 0xa378, 0x54aa, 0x3b5b, 0xf2d4, 0x14db, + /* 0x8f */ + 0x574b, 0x54d0, 0x551a, 0x7cd6, 0x85f4, 0x0a01, 0x9afd, 0x9e5a, + 0x547b, 0x54e2, 0x5518, 0xa3cb, 0xcae3, 0xc845, 0xc8d7, 0x9ece, + 0x10bf, 0x551d, 0x282c, 0x5585, 0x180b, 0xcae5, 0x55ac, 0x70fd, + 0x55d3, 0x07be, 0xcc14, 0x3c97, 0x575a, 0x07d6, 0xcb82, 0x98ef, + 0x5658, 0xbbe4, 0x5671, 0x10d3, 0x17e4, 0x3ce7, 0x564a, 0xa275, + 0x4b58, 0x70fd, 0xc8d6, 0xcbb7, 0xcb83, 0x56de, 0x70fd, 0x5591, + 0x17a0, 0x5693, 0x56e4, 0xbc91, 0x1540, 0xbcc0, 0x1843, 0x5734, + 0x2d32, 0xcbd9, 0x1827, 0x5773, 0x1816, 0x39ff, 0x57d6, 0xdde5, + 0xddfb, 0x5781, 0xcdc8, 0x57c2, 0x8402, 0xce0d, 0xf2f2, 0x186a, + 0x57e8, 0x0988, 0x86e2, 0x2637, 0xcfda, 0x583e, 0x58f1, 0xee38, + 0x596e, 0x9627, 0x5931, 0x595a, 0x598f, 0x28a1, 0x582c, 0x3a96, + 0x190f, 0x59c5, 0x59c6, 0xd160, 0xa339, 0xd164, 0x59de, 0x5a1c, + 0x195b, 0x5a34, 0x5a35, 0x3601, 0x5a45, 0x4977, 0xd24f, 0x5b07, + 0x5b0a, 0x70fd, 0x70fd, 0x5b27, 0x5b3c, 0xe025, 0x5b67, 0xd424, + 0xd5bd, 0x5c1c, 0x4993, 0x62fe, 0x5c10, 0xd559, 0x4ce9, 0xd63a, + 0xa4cf, 0x1a13, 0xd638, 0x437c, 0x5c8c, 0x5c9f, 0xb630, 0xb6e5, + 0x5cbf, 0x5ccc, 0x5ccd, 0x5c29, 0xaefa, 0x5d10, 0x5d1b, 0x5c2f, + 0x851f, 0x1915, 0x59cf, 0x5ddb, 0xd754, 0xd78f, 0xf314, 0x0a65, + 0xd753, 0x5e16, 0xd798, 0xd7bd, 0x5e52, 0x5e43, 0x8750, 0x5e1b, + 0x425c, 0x5e51, 0xb089, 0x11d0, 0x70fd, + /* 0x90 */ + 0x5ee9, 0xd8c2, 0x7ed4, 0xae0a, 0x0ebc, 0xda7c, 0xce4c, 0x4ce7, + 0x5fed, 0x5ff6, 0x6003, 0x63d4, 0x6059, 0x606d, 0xdbe5, 0xdc52, + 0x60e5, 0x6403, 0xef9f, 0x7950, 0x60f3, 0x1c2a, 0xdfde, 0xdd3d, + 0xa33b, 0x3138, 0x9be2, 0x6139, 0xed94, 0xde3c, 0xdd01, 0x8ee5, + 0x0cc0, 0xcc17, 0x6177, 0xdd3c, 0xd5be, 0x61a1, 0xdd6c, 0xddcb, + 0x61e8, 0xde93, 0x6204, 0xde66, 0x61ee, 0x70fd, 0x6267, 0x0e30, + 0x62a9, 0x62c4, 0x4eac, 0xdf33, 0x8b09, 0x630e, 0x3edf, 0x6341, + 0x6362, 0xb739, 0x70fd, 0xe0c6, 0xa25b, 0xe10c, 0xb75b, 0x7bf1, + 0x642c, 0x646b, 0xe0e1, 0xe1eb, 0x428f, 0x2d03, 0xe0e2, 0xe0e5, + 0x1c65, 0x6344, 0xe1ec, 0xe239, 0xe1ff, 0x6473, 0x655b, 0x5ffc, + 0x6685, 0x66a6, 0x6526, 0x66a0, 0x41f6, 0x15b9, 0x917a, 0xde58, + 0x813c, 0xa3ae, 0x1cdf, 0x3e5c, 0x677b, 0x6796, 0x146c, 0x67a3, + 0xcc15, 0x341a, 0x67b6, 0x4af5, 0xe0e0, 0x67bd, 0x260c, 0x1ca1, + 0xc9f8, 0x7334, 0xc290, 0xe46f, 0xe4a5, 0xaf51, 0x8755, 0x9c8a, + 0x6831, 0x5802, 0x6836, 0x1d0f, 0x183d, 0x1885, 0xaf69, 0x4275, + 0x2d81, 0x681b, 0x70fd, 0xe595, 0x6857, 0x2d8a, 0xe5ab, 0x685f, + 0x6525, 0x2310, 0x9a37, 0x9a3c, 0x6889, 0x689f, 0x68b1, 0x68be, + 0x68c0, 0x68d2, 0x68e0, 0xb66c, 0x68ee, 0x461c, 0xe5f3, 0x70fd, + 0x68f5, 0xe5dd, 0xd47a, 0x1d91, 0x6934, 0x6933, 0x694b, 0x6966, + 0x0e4e, 0xceb5, 0x1051, 0x76b0, 0xa69c, + /* 0x91 */ + 0xb886, 0x69ca, 0x69b7, 0x69c8, 0x69c7, 0x1dbf, 0xca67, 0x8513, + 0x27f0, 0x69e1, 0x69e6, 0x69ec, 0x6478, 0x6a39, 0xaea9, 0x1e32, + 0xe7d7, 0xe885, 0x6af5, 0x6b0c, 0x6b3b, 0x6b10, 0x6b58, 0xb8a5, + 0x0a04, 0xe471, 0xea55, 0x6be0, 0x6be2, 0xea05, 0x6bf4, 0x1ece, + 0x6c14, 0x6c2d, 0xddc0, 0x2274, 0x6c34, 0xc768, 0x0c03, 0x99fd, + 0x6c50, 0x6c40, 0xeafe, 0x2c85, 0x86a3, 0x6c8e, 0xa78b, 0x6d02, + 0x6cff, 0x6d0c, 0xec28, 0x6e54, 0xed37, 0xeed2, 0xeeeb, 0xee21, + 0xee63, 0xef1f, 0x6dfe, 0x6e03, 0xee74, 0x6e8e, 0x3ac8, 0x6e44, + 0x8d9b, 0xeed3, 0xef60, 0x877b, 0xef73, 0x6db9, 0xedf9, 0xefb4, + 0x6f10, 0x6f15, 0x6f1e, 0x6f22, 0x1ff4, 0x6f2a, 0x6f2f, 0xa8a4, + 0x6f41, 0x0ea0, 0x0d25, 0x101d, 0x2172, 0x0afe, 0xe22b, 0x6f82, + 0x6f88, 0x1e56, 0x6524, 0xcae2, 0x6f97, 0x70fd, 0x6fb9, 0x28df, + 0x28ca, 0x6fc5, 0x6ab8, 0xe44b, 0x68f2, 0x567f, 0x6fe2, 0x6fe9, + 0x4cdc, 0x700e, 0x4416, 0x1e7e, 0xadf5, 0xae3b, 0x4377, 0xae78, + 0xa888, 0xaed1, 0x459e, 0xe1da, 0x873a, 0x4b9f, 0xdf7e, 0xe336, + 0x6469, 0x64f3, 0xe044, 0x63ec, 0x6481, 0x64cb, 0xdf6c, 0xa9f9, + 0x4417, 0x11eb, 0x4972, 0x4c43, 0x42d0, 0xa9b3, 0xa938, 0x437e, + 0x862f, 0x42a3, 0x86fe, 0x9e99, 0x11c7, 0x86c5, 0xb62f, 0x8638, + 0x0a62, 0x853b, 0x8679, 0x0a21, 0x85b4, 0x8711, 0xbecb, 0x0a63, + 0x8500, 0x299b, 0xaea5, 0x82be, 0x8168, + /* 0x92 */ + 0x8286, 0x8376, 0x5703, 0x9fa6, 0x70fd, 0x5655, 0xae14, 0xcea5, + 0xa3b1, 0xb6dc, 0xa43b, 0xcd92, 0x17f4, 0x9fee, 0xe91d, 0xcc66, + 0x3a39, 0x0a73, 0x0f55, 0x10e7, 0x2aac, 0x8762, 0x3a50, 0x1357, + 0xa03f, 0xa621, 0xa5cb, 0xa64f, 0xc961, 0x270b, 0x28de, 0xc471, + 0x28d2, 0x7e9f, 0x7a68, 0x7ccd, 0x64c6, 0xe113, 0x649c, 0x2138, + 0x236b, 0x0b59, 0xa976, 0x20fc, 0x7525, 0x743f, 0x218b, 0x21ca, + 0xb7d1, 0x2ca8, 0x726b, 0x748b, 0x0cd9, 0x73ca, 0x74d4, 0x0775, + 0x2169, 0x7380, 0xe3b3, 0x7335, 0x5c5a, 0x72cc, 0x20d8, 0x230d, + 0x234d, 0x21e2, 0x2143, 0xae8e, 0xa3ca, 0x2182, 0x226e, 0x22ac, + 0x22c1, 0x220c, 0x2225, 0x2298, 0x233c, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x4076, 0x9e95, 0xa3b9, 0xa3ff, 0x3fb2, 0x86c4, 0xa3c9, + 0x23e8, 0x2403, 0x7660, 0x17dd, 0x7563, 0x7552, 0x7551, 0x5eba, + 0xe09c, 0x770e, 0x2499, 0x24e4, 0x77f3, 0x2521, 0x70fd, 0x197a, + 0x438c, 0xa8cc, 0x7ae0, 0xae2c, 0x7fa4, 0x3c11, 0x7cdd, 0x70fd, + 0x11de, 0x4699, 0x4614, 0x4656, 0x4598, 0x1e4e, 0xaf3c, 0xa5cd, + 0x2610, 0x08c4, 0x440f, 0xa609, 0x27f4, 0x7405, 0x270d, 0x7a86, + 0x295d, 0x635d, 0x67f4, 0x6466, 0x2a1d, 0x29cd, 0x29bf, 0x097e, + 0x2b0b, 0x2cd9, 0xe046, 0x853a, 0x85af, 0x8550, 0x2c6c, 0x2bf8, + 0x638f, 0x2cbe, 0x2d0f, 0x2c52, 0xba06, 0x8833, 0x86a1, 0xa7d5, + 0x0a35, 0x3f45, 0x4643, 0x2c61, 0xbe03, + /* 0x93 */ + 0x2cc1, 0xe1d7, 0x74d3, 0x64e0, 0x468c, 0x81c3, 0x4305, 0x1c72, + 0x6508, 0xdffb, 0x64bd, 0x0ae0, 0x2e5e, 0x2ede, 0x309e, 0x3088, + 0x87d6, 0x87bc, 0xa1ee, 0x310d, 0x2d8f, 0x8743, 0x8744, 0x0a41, + 0x86e0, 0x0a1d, 0x853e, 0x0a13, 0x532a, 0xe047, 0x8a7a, 0x9db2, + 0xdfa8, 0x314c, 0x314e, 0x8767, 0x85eb, 0x2cab, 0x857b, 0x2d84, + 0x57d4, 0xd17d, 0x59e0, 0x32be, 0x9360, 0x912b, 0x321b, 0x11b8, + 0x90ef, 0x90fe, 0xe448, 0xccb3, 0x3400, 0x713e, 0x7146, 0x911b, + 0x33d9, 0x33d8, 0x32b5, 0x969b, 0x9707, 0xabd4, 0xe50d, 0x36b1, + 0xab65, 0x95aa, 0x0d69, 0x9562, 0x9d90, 0xe86a, 0x9878, 0x3577, + 0xf09b, 0x36f6, 0x3571, 0x3611, 0xae63, 0x9767, 0x34e4, 0x96a1, + 0x367b, 0x37ab, 0x3bb2, 0x0f34, 0x9a0e, 0x9c2d, 0xae09, 0x9c2b, + 0x274d, 0x9c60, 0x8719, 0xe5ff, 0x390e, 0x9c09, 0x9b33, 0x0e20, + 0x1490, 0xb704, 0xe122, 0xb70f, 0x853c, 0xb6db, 0xb625, 0x4aee, + 0x9a83, 0x866a, 0x9bb4, 0x07a4, 0x9b8f, 0x9b02, 0xa809, 0x38ce, + 0xca64, 0x38ab, 0x1e53, 0x3870, 0xd370, 0x8aab, 0x38a3, 0x9c52, + 0x9c61, 0x385e, 0xb972, 0x0c11, 0xa13a, 0xa0bc, 0x0ed9, 0xa0a2, + 0x9d3e, 0x46d0, 0x0ed6, 0x39cf, 0xab2a, 0x3af6, 0x3a5e, 0x0f04, + 0x3cfe, 0x0ba3, 0xa0d5, 0xa9c7, 0x3c73, 0x3c92, 0x3d09, 0x3d45, + 0x8752, 0x3751, 0x3ad8, 0x3c8c, 0x0f17, 0x3cba, 0x3d97, 0xa500, + 0xa25a, 0x64a0, 0x63f2, 0xe1ea, 0xe0cb, + /* 0x94 */ + 0x6389, 0xd8de, 0xdfdc, 0x6567, 0x3fe5, 0x410b, 0xae6c, 0x70fd, + 0xa4bf, 0x108f, 0x4004, 0xa57c, 0x2c7d, 0x400a, 0x2a87, 0x3f64, + 0x4a42, 0x433b, 0xa85a, 0xa7b6, 0x42f1, 0x4450, 0x4487, 0x4494, + 0xac4f, 0xac25, 0x23b9, 0xaf24, 0x766b, 0x467a, 0xa438, 0x9f5f, + 0xaeca, 0xad97, 0xbf21, 0x1206, 0x11b1, 0xaf5f, 0xe223, 0xa475, + 0x32e7, 0x11f3, 0x46cc, 0x463c, 0x6487, 0x4637, 0x179f, 0xcb2a, + 0x1851, 0x4783, 0x1263, 0xb099, 0xb0c6, 0x1258, 0x4755, 0x4873, + 0xf0c6, 0x0e59, 0x4668, 0xe0cc, 0xae2b, 0xae0e, 0x0e3b, 0x10cd, + 0xaece, 0x11ff, 0xae45, 0xad73, 0x62fa, 0x2972, 0x6442, 0xe0e3, + 0x86a4, 0x231f, 0xb4e1, 0xb4a7, 0x4978, 0x9bb2, 0x490e, 0x490f, + 0x497b, 0xab97, 0xa081, 0x0d9e, 0xad70, 0x4638, 0x469b, 0x11bf, + 0xaf3a, 0xaf47, 0x13c8, 0xaf16, 0xc0ae, 0x6407, 0xb701, 0x4a1e, + 0x4a8d, 0x4a88, 0x4ad2, 0x45d0, 0x4b59, 0xd281, 0xb863, 0x140e, + 0x70fd, 0x5696, 0x4ba5, 0x3c6d, 0xa43a, 0x4c3a, 0x4bf4, 0x146e, + 0x8526, 0x1432, 0x6335, 0x4bf1, 0x7c0c, 0xae0c, 0x7359, 0xa33a, + 0x85ae, 0x08d7, 0x27ab, 0x08b0, 0x09ea, 0x7294, 0x7acd, 0x4ce2, + 0x2c99, 0x91f5, 0xbaef, 0xbadc, 0x2c4d, 0x731b, 0x4af0, 0x2c6a, + 0xbbc6, 0x4cfe, 0x14f9, 0x4e5d, 0x4e6d, 0x1511, 0xbbb3, 0xbe3c, + 0xbe26, 0x4ecd, 0xae79, 0x85f0, 0x4e8e, 0x4e7c, 0x4eae, 0x3cf2, + 0x4fdc, 0x5007, 0x4fd3, 0x514e, 0xc121, + /* 0x95 */ + 0xc05c, 0xd648, 0x4f97, 0xbe02, 0x156a, 0xc8b5, 0x7856, 0x3a16, + 0x714e, 0x9ecf, 0x2a04, 0xc292, 0xc278, 0xade2, 0x51dd, 0x4d27, + 0x77ac, 0xbb29, 0xbd43, 0x4d0c, 0xbd8e, 0x6ae6, 0x5805, 0x6b63, + 0x3c5c, 0x9d7f, 0x0d22, 0xae77, 0xc3ed, 0x6b1f, 0xc3e0, 0x5680, + 0xce67, 0xca11, 0x17ea, 0x5337, 0x1702, 0x52c6, 0x5309, 0x5342, + 0xc574, 0x69c3, 0xc802, 0x5462, 0x5465, 0xc811, 0x5653, 0xcae7, + 0x57d0, 0xcf1b, 0x2cc6, 0x147f, 0x8680, 0x2d6b, 0x86e1, 0x2d24, + 0x8718, 0x5860, 0xf2fc, 0xa30f, 0x59ad, 0xd022, 0x2c42, 0x59ee, + 0x2185, 0x5a07, 0x5a3f, 0x5a66, 0x5ae5, 0x5acd, 0xb803, 0x5ad4, + 0xd2c5, 0xd2c4, 0xe1f5, 0xe1d9, 0xe19c, 0xdff9, 0x11ad, 0x56a3, + 0x19f5, 0x19cf, 0x0b32, 0x5bbd, 0x5b9c, 0xe608, 0x318d, 0x632b, + 0xa7c4, 0x3814, 0x4329, 0x42c4, 0x8685, 0x6ded, 0x5ddf, 0x5e29, + 0xd7dc, 0x2bda, 0x49c3, 0x2c30, 0x166e, 0x0a14, 0x5f6a, 0x5fe7, + 0xb009, 0x6070, 0x608a, 0x15f4, 0x3e98, 0x41bb, 0x8ee1, 0x1b9b, + 0x4179, 0x408b, 0x861a, 0x6ce9, 0x09f5, 0xadaf, 0x61fb, 0x70fd, + 0x27b1, 0x1c06, 0x62bb, 0x6504, 0xe04b, 0x1362, 0xe0fc, 0x6527, + 0xe21d, 0xe23b, 0x56e5, 0x5bab, 0x6699, 0x66a7, 0x6697, 0x6696, + 0xe2b4, 0x4645, 0x11c2, 0xad7f, 0xaec2, 0xa92a, 0x11e7, 0x9ba5, + 0x678f, 0xe3e7, 0xe366, 0xe365, 0x11cc, 0xae6d, 0xaef8, 0xa52e, + 0x4612, 0x466b, 0x11fc, 0x6841, 0xe470, + /* 0x96 */ + 0x3a87, 0x1d1d, 0xe453, 0xb91f, 0x70fd, 0x6468, 0xdf89, 0xe226, + 0xe12f, 0xc23e, 0x63ba, 0x2d51, 0x5ce9, 0x1c3c, 0x45f9, 0xa75b, + 0x689b, 0x6871, 0x6a38, 0x7de6, 0x3001, 0xe1c5, 0xaf32, 0x691f, + 0xe65a, 0x63f6, 0xe6d7, 0x62e5, 0x17c0, 0xe150, 0xaee7, 0xe164, + 0x69dc, 0xe045, 0x1200, 0x632a, 0x1c25, 0x5614, 0x6a3b, 0x6a4d, + 0xd606, 0x10fd, 0x6a9b, 0x1e2f, 0x6aaa, 0x6b5c, 0xe165, 0xb988, + 0x3ccf, 0x6b21, 0x2d3e, 0x6b2f, 0xe871, 0x1e50, 0xe8c8, 0x6abc, + 0x1e7d, 0x1e57, 0x647d, 0x2ab2, 0x81c2, 0x2a62, 0xae38, 0x83a8, + 0x4a44, 0x921f, 0xa338, 0x3b05, 0x107d, 0x6558, 0x0c67, 0x3390, + 0x9281, 0x946b, 0x3347, 0x6d4f, 0x6d53, 0x6d7b, 0x6d35, 0x6d10, + 0x6c7f, 0x6ccf, 0xebed, 0x6c9f, 0xef35, 0xee3e, 0x6da1, 0x1f6e, + 0xa644, 0x6e98, 0x1f70, 0x6d8c, 0xeef4, 0xee2d, 0xee33, 0xe8af, + 0x6e25, 0x56bd, 0xcb52, 0xcd1f, 0xc8c2, 0x57bc, 0x1833, 0xcae4, + 0xcbc4, 0xcb30, 0x5620, 0x57ae, 0xcb40, 0xa0d7, 0xbfa4, 0x4be2, + 0x9e9c, 0x9f40, 0x1c2d, 0xae5e, 0x1062, 0x64db, 0x63be, 0x6448, + 0x737f, 0x4ab9, 0x6377, 0x654d, 0x2224, 0x0780, 0x61a4, 0xb6dd, + 0x4a3d, 0x4a54, 0x4ab6, 0x4a4b, 0x8597, 0x9b49, 0xadc1, 0x09da, + 0x21b2, 0x41da, 0x41d9, 0x70fd, 0x421e, 0x2654, 0xa6f5, 0x29fb, + 0x2b33, 0x29ca, 0x6d96, 0x2a17, 0x4334, 0x07ef, 0xa6ec, 0x43eb, + 0xc980, 0xb2d7, 0x70fd, 0x85f5, 0xe049, + /* 0x97 */ + 0x334c, 0x2d0e, 0x2c4b, 0x15bc, 0xa9c8, 0x0a6c, 0x1e3b, 0xdffc, + 0x64bb, 0x64b8, 0x8716, 0x7ddd, 0x5672, 0xca00, 0x82d3, 0xa83a, + 0x9626, 0xa901, 0x2bd4, 0xa337, 0xc501, 0x4fa8, 0xc05b, 0xbfe4, + 0xae39, 0xae0b, 0xdffa, 0x63e5, 0x45e2, 0x11e9, 0x46b4, 0xe163, + 0x86df, 0x11e1, 0xaf33, 0x3d18, 0x45f3, 0x45fb, 0x11d6, 0xaebe, + 0xaf14, 0x8619, 0xaee6, 0x7467, 0x82e4, 0xae65, 0x4648, 0xad96, + 0x42a5, 0xadf6, 0x6384, 0x45e6, 0x645f, 0x75be, 0x6431, 0xe0ce, + 0xe016, 0x6486, 0xe1e7, 0xb755, 0x1c35, 0xe082, 0x436b, 0xadc3, + 0x7bbf, 0x28e4, 0x769a, 0x7aab, 0x7b78, 0x2742, 0x4bc4, 0x863a, + 0x4ffe, 0x8502, 0xaed0, 0x8692, 0x182e, 0x6501, 0x0a4a, 0xe0c0, + 0xae2d, 0x2bf0, 0x86ff, 0x86c3, 0xd084, 0x2ce1, 0x0a22, 0xa2db, + 0x09f0, 0x635f, 0x2cb9, 0xe081, 0x86a2, 0x6474, 0x0fcd, 0x79b4, + 0x1d56, 0x0cca, 0x2334, 0x1069, 0x104c, 0x825c, 0x4375, 0x15fb, + 0xda98, 0x400f, 0xe4a4, 0x17eb, 0x3f97, 0xd80f, 0x4267, 0x3eef, + 0x0fd6, 0xa52d, 0xa3ad, 0x4002, 0x410c, 0x106f, 0x74b5, 0x4751, + 0x09fc, 0x0808, 0x1980, 0x11da, 0x1b71, 0x2c04, 0x636e, 0x1c3e, + 0x6081, 0xe21c, 0xc900, 0x2a52, 0x2a08, 0x0a16, 0x8312, 0x42fe, + 0xa8a2, 0xaef1, 0x9963, 0x8170, 0x8f3d, 0x3af9, 0x3ba7, 0x8258, + 0x9de5, 0xd6b4, 0x9fdf, 0xe083, 0xa0d6, 0x9d3a, 0xb05f, 0x3c5a, + 0x9fad, 0xc9f7, 0x563e, 0x17df, 0x17ce, + /* 0x98 */ + 0xca66, 0xca91, 0xc9c2, 0xcd1e, 0x4117, 0xce49, 0x553d, 0x857a, + 0x55ed, 0xc9c0, 0xcd93, 0x861b, 0x2bc9, 0x2cc2, 0x85f3, 0x2ca1, + 0x2cb1, 0x8745, 0xa73c, 0x0a6d, 0x2c2f, 0x857c, 0x0a07, 0x438e, + 0x6490, 0x38da, 0xa7e5, 0x2cae, 0x2c6b, 0xa7d3, 0x3c6b, 0xa439, + 0xd276, 0xa99b, 0xa80a, 0x431d, 0xa799, 0xdfe1, 0x21f0, 0xca68, + 0x2f02, 0xaa0e, 0xd80d, 0xa8fd, 0x3c4c, 0xa796, 0x81c4, 0x42a6, + 0x4333, 0xa929, 0x10a5, 0x3f1f, 0xf1e5, 0xaecf, 0x5065, 0x2c2b, + 0x2f6f, 0x10f3, 0x319c, 0xaedd, 0x861f, 0x4fa4, 0x5626, 0x26c5, + 0xa1fa, 0x9c80, 0x72d4, 0x29be, 0x7815, 0x7699, 0x12e5, 0x8c1e, + 0xefb6, 0x4203, 0xe51b, 0x2fb0, 0x458f, 0x4ed3, 0xe059, 0xe5e0, + 0x2208, 0x51e7, 0x44cd, 0x4510, 0xd5f4, 0x4538, 0x4539, 0xb876, + 0x4541, 0x4548, 0x11a9, 0xd618, 0x61ac, 0x43f5, 0xad72, 0x45e1, + 0x53f6, 0x11ca, 0x490c, 0x11d1, 0x3ee2, 0x293d, 0x4619, 0x461e, + 0x461f, 0x11e2, 0x11f0, 0x11f4, 0x11fa, 0x46d3, 0x120e, 0x1253, + 0x4742, 0x476d, 0x4772, 0x478d, 0x127c, 0x47c8, 0x47dc, 0x12c0, + 0x484d, 0x12d7, 0x4874, 0x12dc, 0x487a, 0xb29c, 0x4388, 0x2863, + 0x5b00, 0x2aa9, 0x131d, 0x4943, 0x1339, 0x39a1, 0x1345, 0x091b, + 0x4998, 0x136a, 0x136f, 0x2e9e, 0x49be, 0x49cb, 0x2b32, 0x4a18, + 0x42b9, 0x4a1c, 0x13a8, 0x4a39, 0x4a47, 0x4a51, 0x4a66, 0x5648, + 0xb6b5, 0x4b33, 0x3a43, 0x4b32, 0x1403, + /* 0x99 */ + 0x1409, 0x4b91, 0x4b99, 0x60fb, 0x4c06, 0x60fc, 0x1467, 0x4c91, + 0x14b2, 0x4cbc, 0x5479, 0x14c4, 0x4ccf, 0x4cdb, 0x14cf, 0x2061, + 0x4d62, 0x4d6c, 0x4d7b, 0x4e12, 0x4e1b, 0x1560, 0x157a, 0x4e7b, + 0x4e9c, 0x158c, 0x4eb8, 0x1594, 0x4eed, 0x60d3, 0x42c0, 0x7b8f, + 0x4fcf, 0x4fd4, 0x4fd0, 0x4ffd, 0x51ae, 0x51b4, 0x449f, 0x1697, + 0x5220, 0x5225, 0x4d39, 0x522e, 0x5231, 0x5254, 0x10cc, 0x29f4, + 0x42a0, 0x52b7, 0x52e9, 0x16ed, 0x530c, 0x452a, 0x530e, 0x5312, + 0x4760, 0x5314, 0x1701, 0x0e79, 0x5356, 0x5359, 0x535a, 0x1713, + 0x2a7a, 0x537c, 0x5384, 0x1725, 0x5393, 0x172d, 0x53a5, 0x2a2f, + 0x53c1, 0x53e4, 0x5454, 0x178f, 0x54a6, 0x5476, 0x54ca, 0x54d8, + 0x54ff, 0x17b0, 0x5557, 0x6769, 0x3bca, 0x5605, 0x42f5, 0x5664, + 0x3323, 0x5688, 0x1804, 0x56be, 0x56e1, 0x56f8, 0x5710, 0x5738, + 0x5752, 0x183b, 0x576f, 0x5770, 0x57a0, 0x1877, 0x5832, 0x5852, + 0x5872, 0x58af, 0x6745, 0x590b, 0x1906, 0x1917, 0x5a2e, 0x5a7f, + 0x5aa4, 0x5ac7, 0x5b11, 0xd467, 0x5ba9, 0x5bb8, 0x5c14, 0x5c34, + 0x5d91, 0x5e14, 0x5e32, 0x5e5c, 0x1a98, 0x2a9f, 0x5f03, 0x1aed, + 0x212e, 0x5f7a, 0x2818, 0x2994, 0x5fb1, 0x2835, 0x5ff0, 0x1b37, + 0x600e, 0x6022, 0x6024, 0x602d, 0x6032, 0x60f7, 0x6101, 0x610a, + 0x610c, 0x6173, 0x6ac4, 0x1bad, 0x69e0, 0x6313, 0x1c1e, 0x6328, + 0x6358, 0x636b, 0x63b1, 0x63ae, 0x63bf, + /* 0x9a */ + 0x63e3, 0x63eb, 0x63f3, 0x63f4, 0x63fd, 0x6443, 0x6484, 0x64ad, + 0x1c45, 0x1c51, 0x6f3f, 0x6517, 0x2541, 0x651d, 0x652d, 0x653e, + 0x1c6a, 0x6554, 0x6579, 0x662d, 0x66a2, 0x1ca7, 0x66f4, 0x6733, + 0x1ce5, 0x39e0, 0x1d24, 0x6840, 0x1d35, 0x68b2, 0x68c2, 0x2894, + 0x1da4, 0x3328, 0x69b9, 0x1dd9, 0x69f1, 0x2a84, 0x6a0e, 0x6a19, + 0x23f4, 0x6a1c, 0x6a37, 0x6a42, 0x6a5d, 0x6a62, 0x1e30, 0x6ac5, + 0x1e5d, 0x6b3c, 0x6c0f, 0x4c83, 0x6c69, 0x6c81, 0x6cdd, 0x6cf1, + 0x6cf4, 0x1f2d, 0x6d20, 0x0aaf, 0x8902, 0x6dc9, 0x6d3a, 0x6f7e, + 0x2890, 0x6e13, 0x6e3d, 0x6e40, 0x6e7c, 0x65f6, 0x60f6, 0x6efb, + 0x6f2c, 0x6f31, 0x6f3d, 0x6f46, 0x65dc, 0x6f62, 0x6f71, 0x6f78, + 0x4cc8, 0x6fc4, 0x7194, 0x7377, 0x7460, 0x3b5a, 0x65c3, 0x2bec, + 0x7597, 0x2a80, 0x65c1, 0x0af9, 0x7655, 0x7695, 0x76f6, 0x84fa, + 0x2997, 0x4373, 0x79c2, 0x79cd, 0x7a7f, 0x26aa, 0xf1fb, 0x7a8b, + 0x26de, 0x7abb, 0x7afb, 0x7b13, 0x7b25, 0x7b3c, 0x3327, 0x7b4d, + 0x28ba, 0x7b75, 0x7b9d, 0x7bad, 0x7c2f, 0x7c72, 0x7c88, 0x3b95, + 0x6d2f, 0x5925, 0x7cc4, 0x7cce, 0x7d97, 0x7e50, 0x7ded, 0x7d33, + 0x2e60, 0x7e7c, 0x304b, 0x7f1c, 0x7f0f, 0x7f36, 0x395e, 0x7f3b, + 0x7f48, 0x7f56, 0x0987, 0x7f7f, 0x7f93, 0x7fef, 0x7ffb, 0x25a4, + 0x56ad, 0x81a3, 0x8235, 0x81f6, 0x5d01, 0x83f7, 0x8459, 0x8603, + 0x8607, 0x20b8, 0x42bb, 0x866d, 0x87aa, + /* 0x9b */ + 0x886d, 0x8885, 0x896a, 0x89b0, 0x89ec, 0x8b48, 0x3503, 0x8b55, + 0x8b95, 0x4398, 0x3a95, 0x8c85, 0x3c29, 0x0a08, 0x8ebc, 0x8f57, + 0x8f7a, 0x922a, 0x9371, 0x944f, 0x54fd, 0x9467, 0x9493, 0x9515, + 0x5b25, 0x9528, 0x60e0, 0x954e, 0x68b8, 0x957f, 0x6947, 0x6bbd, + 0x964c, 0x70fd, 0x9688, 0x96b7, 0xbbe8, 0x9708, 0x9712, 0x97b7, + 0x9795, 0x9842, 0x9934, 0x994c, 0x99b3, 0x99e6, 0x9c9f, 0x9d1e, + 0x31f1, 0x3888, 0x38ff, 0xd579, 0x9e67, 0x9ef3, 0x70fd, 0xae3a, + 0x70fd, 0x9f1a, 0xa016, 0x70fd, 0x7406, 0x2af5, 0x394e, 0x3b58, + 0xa1a7, 0xd1d7, 0xbf22, 0xa391, 0xa3f9, 0xd17e, 0x8cda, 0x1bd0, + 0x1d78, 0xa659, 0xe09a, 0xa82e, 0xa84d, 0xa57b, 0xa874, 0xa8d6, + 0xaec5, 0x764a, 0x2412, 0x7691, 0x2bdf, 0x8b28, 0x0efe, 0xa2bf, + 0xa944, 0xaa16, 0x29c8, 0xab74, 0x0cdb, 0xac2f, 0xdda8, 0xe949, + 0x0aa2, 0x8e03, 0x5cde, 0xe14e, 0x70fd, 0xacd2, 0xad7b, 0xae95, + 0x4409, 0xaf40, 0x7b38, 0x2ba5, 0xb225, 0xb2c6, 0x7779, 0x601a, + 0xb36c, 0x24cf, 0x297f, 0x4371, 0xb559, 0xb619, 0xa48a, 0xaf27, + 0x27fc, 0xb646, 0xb66e, 0xc892, 0x70fd, 0x07b3, 0xb6bf, 0xd1b2, + 0xb6de, 0x1a18, 0xb6e2, 0xb6e6, 0xb907, 0xadbf, 0xb95d, 0x22a6, + 0x083b, 0x9d0c, 0x70fd, 0xb9c3, 0x1a7c, 0xdf48, 0xbaee, 0xbb89, + 0xbc06, 0x8a50, 0x29e1, 0x4351, 0x70fd, 0xc002, 0xd6d2, 0x6196, + 0xc0b2, 0xb2da, 0x5ce2, 0xc282, 0xc2ca, + /* 0x9c */ + 0x2f9b, 0xc937, 0x70fd, 0xc304, 0x875c, 0x5c6a, 0xae76, 0xc308, + 0xa52f, 0xc352, 0x1e80, 0xc3ff, 0xc475, 0x921b, 0x6565, 0xb921, + 0x33d5, 0x2c67, 0xf28d, 0x70fd, 0x28f9, 0xaa61, 0xc4bc, 0x20aa, + 0xadb4, 0x6756, 0x3fcf, 0xc9fd, 0x0958, 0x5af7, 0xc559, 0xc62e, + 0xc291, 0xc61e, 0x70fd, 0xc687, 0x4d42, 0xe480, 0x7911, 0xc6e6, + 0x70fd, 0xc6f9, 0x4c45, 0x70fd, 0xc7ba, 0x6b26, 0xc7ed, 0x099f, + 0xc2e9, 0x7121, 0x4b83, 0xc7f4, 0xc89b, 0x2f6c, 0x9e19, 0x70fd, + 0xc8dd, 0x19d0, 0xc9e4, 0x473b, 0x59e5, 0xcaee, 0x2af6, 0x0a5c, + 0x90cd, 0xcd8b, 0xcecd, 0x0f94, 0xcf40, 0xcf45, 0x6381, 0x8dba, + 0xcf4b, 0x6430, 0xcfa6, 0xae50, 0x3e79, 0x659f, 0xd050, 0x7db8, + 0x59a7, 0x5a75, 0x9426, 0xdcb3, 0x85f1, 0x40b8, 0xaeaa, 0x8660, + 0x0ce4, 0x09f9, 0x70fd, 0x70fd, 0x183f, 0x38f6, 0xeaad, 0xe824, + 0x5ac3, 0xd30c, 0xd358, 0x2916, 0x13df, 0x844a, 0x0ce1, 0xa02f, + 0xd9a8, 0x8285, 0x43ad, 0x5566, 0xd4dd, 0xe568, 0x70fd, 0x1f77, + 0xcdef, 0xdfab, 0xd4fd, 0xd50a, 0xd60b, 0xd766, 0xa6ba, 0x4d43, + 0x4b7e, 0xd8c9, 0x41b5, 0xefdf, 0x3c43, 0xdb98, 0x25e2, 0xcb47, + 0x64bf, 0x3a76, 0x685d, 0xda2f, 0xd8e3, 0xc775, 0x82ad, 0x9baf, + 0xd908, 0x2fc5, 0xe230, 0xd943, 0x2955, 0x6923, 0xdf49, 0x2feb, + 0xae08, 0x37fe, 0x3c15, 0x2612, 0xaf25, 0xa4c1, 0x0f51, 0x3976, + 0xd950, 0xd9b4, 0xd9ee, 0x8c21, 0xda0f, + /* 0x9d */ + 0xda49, 0xda6f, 0xda9a, 0xdb86, 0xdbaf, 0xdc0a, 0x090a, 0xdca8, + 0xde2a, 0x1bfa, 0x3626, 0xdf56, 0x4a08, 0x6355, 0xdfb8, 0x16f2, + 0xdfe7, 0x16df, 0xdfe8, 0xe146, 0xe1d4, 0x2c38, 0xe209, 0x70fd, + 0xe405, 0xe4ac, 0x70fd, 0xe4d0, 0xe4fc, 0x10f7, 0xe51e, 0xaf4a, + 0x6110, 0x448f, 0x28cb, 0xe667, 0xe6e9, 0xe6b0, 0xe6b8, 0xe732, + 0xe851, 0xe8c9, 0xe8ea, 0xe943, 0xe9a8, 0xea0e, 0xeb1a, 0xeb5b, + 0x509f, 0xecb8, 0xece3, 0x1f64, 0x6647, 0xef93, 0x43a2, 0xefff, + 0x2011, 0x6152, 0xf0cb, 0x201c, 0x7b5c, 0x60fe, 0x2801, 0x60fa, + 0x8ff0, 0x60f9, 0xaf13, 0x1809, 0x507f, 0x4156, 0x3cf1, 0x212a, + 0x0824, 0xe12c, 0xd39d, 0x0a7a, 0x5fc0, 0x8635, 0xd8e4, 0xe16c, + 0xe199, 0xd53e, 0xc46f, 0x10eb, 0xd1d5, 0xa277, 0xb7b5, 0xba16, + 0x20da, 0xbe01, 0xc118, 0x28ff, 0x7d2d, 0x5f4e, 0x2dad, 0xa3c8, + 0xb05e, 0x361e, 0x70fd, 0x8636, 0x86bb, 0x3770, 0x286d, 0xbc4a, + 0x265a, 0xb5d1, 0x10c6, 0xeb58, 0x1f3d, 0x2862, 0x285e, 0x5149, + 0xbe58, 0x2bb5, 0xa2c0, 0x58f0, 0x205c, 0x7eaa, 0x7c09, 0x9fba, + 0x5317, 0x6dde, 0x5e58, 0x483b, 0x6d45, 0x484e, 0x49b9, 0x6445, + 0x2672, 0x5348, 0x54f7, 0x2865, 0x5332, 0x5618, 0x52bd, 0x282a, + 0x4b62, 0x2883, 0x2656, 0x7d5d, 0x090e, 0x2845, 0x2831, 0x3931, + 0xdb62, 0x096d, 0x4734, 0x2830, 0x27fa, 0x26d7, 0x27b2, 0x7b01, + 0x7b56, 0x3110, 0xb448, 0x7d36, 0x9662, + /* 0x9e */ + 0x7d62, 0x6f2b, 0x4f5a, 0x281e, 0x7f35, 0x34dd, 0x686d, 0x26d4, + 0x5e0d, 0x43f6, 0x6276, 0x363c, 0x35f9, 0x363e, 0x27a9, 0x9583, + 0x6d72, 0x98b3, 0x23da, 0x081f, 0x7c67, 0x23e7, 0x268d, 0x275e, + 0x2753, 0x4866, 0x5f6d, 0xc64a, 0x47b1, 0x52b6, 0x5984, 0x5906, + 0x5a47, 0x53b6, 0x561c, 0x7f81, 0x17ec, 0x4504, 0xac06, 0x2dd0, + 0x550b, 0xc653, 0x28bb, 0x91f4, 0xd72f, 0xa6e3, 0xd773, 0xcc10, + 0xcf76, 0x6270, 0x8099, 0x6308, 0xa2bc, 0xf1a9, 0x7d6c, 0x7db9, + 0x4466, 0x89e2, 0x1a4e, 0xb302, 0xd8b9, 0x7eab, 0x13fa, 0x6d5d, + 0x375f, 0x97a0, 0x1bf3, 0xaca0, 0xeb3c, 0x7eac, 0x7cca, 0x70fd, + 0xd123, 0x7ead, 0x70fd, 0xbf88, 0x8047, 0x43a3, 0x508e, 0x6dd0, + 0x205a, 0x2044, 0x08b7, 0x2d4d, 0x3ef2, 0x25a7, 0x09ec, 0x0d1c, + 0x25bd, 0x09e5, 0xab18, 0x2ada, 0xafae, 0x542d, 0x268b, 0x29ea, + 0xbad5, 0x78b9, 0x70fd, 0x0d92, 0x8fa5, 0x4574, 0xec6c, 0x1fc9, + 0x6ced, 0xa2be, 0xecf0, 0x1f1b, 0xb2e9, 0xe69e, 0xed5e, 0x565c, + 0xa336, 0xcf72, 0xc573, 0xa020, 0x356e, 0x4f25, 0xa437, 0xa3ac, + 0x0d6a, 0x6148, 0x250c, 0x1174, 0x09ba, 0x18e9, 0x754e, 0x4840, + 0x2d30, 0x7d76, 0x4a7a, 0xd86e, 0x2ae7, 0x13bf, 0x28bc, 0x6c8b, + 0x2fb4, 0x4854, 0xf074, 0x6f05, 0x1fa1, 0x70fd, 0x0b3b, 0x3359, + 0x9a5a, 0xa932, 0x70fd, 0x289d, 0x8169, 0x29e7, 0xade3, 0xebc6, + 0x2474, 0xcdee, 0x08ed, 0x70fd, 0x6dfc, + /* 0x9f */ + 0x4e56, 0x6c39, 0x2a1e, 0x85ac, 0x2e93, 0x3713, 0xe650, 0xc1b5, + 0xcea4, 0x586d, 0x7be8, 0xca62, 0xaf62, 0x7c31, 0x70fd, 0x243e, + 0x8b8f, 0x2fce, 0x6803, 0x8a91, 0x6f01, 0x618c, 0x4d1f, 0x6c02, + 0x2f11, 0x4da3, 0x34a8, 0x3575, 0x6bff, 0x4dcf, 0x6c2a, 0x4e7e, + 0x70fd, 0x4e42, 0x4e86, 0x6d15, 0x4dfc, 0x6c09, 0x70fd, 0x6d1b, + 0xadbe, 0x6fda, 0x27b3, 0x2e03, 0x223d, 0x6f18, 0x2232, 0x24a0, + 0x1106, 0x2511, 0x29a7, 0x2296, 0x2bf7, 0x3052, 0x68c8, 0x6e2b, + 0x609c, 0x26a9, 0x68b4, 0x6a40, 0x68ba, 0x256c, 0x3370, 0x3b6c, + 0x261a, 0x6d0a, 0x6d82, 0x1efb, 0x6741, 0x3bc0, 0x22e6, 0x4746, + 0x85ad, 0x6ada, 0x24b3, 0x70fd, 0x6259, 0x6781, 0x625c, 0x70fd, + 0x6251, 0xe397, 0x35bf, 0xca63, 0x3d0a, 0x2851, 0x628e, 0x477a, + 0x34c5, 0x74bc, 0x454f, 0x4e70, 0xbc21, 0xa2bd, 0x70fd, 0xad99, + 0x48d6, 0x6c9d, 0x206a, 0x7b94, 0x55be, 0x59c2, 0x70fd, 0x2e8a, + 0x3c00, 0x70fd, 0x29ba, 0x245f, 0x3035, 0x210e, 0x3e71, 0x72b2, + 0x2179, 0x26dc, 0x271a, 0x24da, 0x5ec2, 0x093e, 0x70fd, 0x0933, + 0x70fd, 0x3d92, 0x627c, 0x7025, 0x6c97, 0x692e, 0x69b4, 0x6bba, + 0x6f28, 0x6f04, 0x437a, 0x4d14, 0x70fd, 0x3e3a, 0x5998, 0x5178, + 0x70fd, 0x2860, 0xf14a, 0x5fb7, 0x6fd3, 0x70fd, 0x5f14, 0x5f8f, + 0x6e9c, 0x5f41, 0x34c2, 0xdbfd, 0x5f68, 0x5fb5, 0x4cd3, 0xaef7, + 0x4c3e, 0x4ad8, 0x3f2a, 0x5be7, 0x4807, + /* 0xa0 */ + 0xe05a, 0x6fa6, 0x3f0e, 0x5956, 0x47c3, 0xefb2, 0x4a53, 0xf200, + 0x5e4c, 0x44e2, 0x4571, 0x5cad, 0x4502, 0x46f1, 0x5e2b, 0xaf3b, + 0x57ef, 0x31fa, 0x5a20, 0x17b7, 0x70fd, 0x867b, 0xcb45, 0x70fd, + 0x5bfe, 0x905b, 0x70fd, 0x333d, 0x4867, 0x6bd7, 0x6dc4, 0x646e, + 0x6c8f, 0x5975, 0x70fd, 0x70fd, 0x5e37, 0x452c, 0x6821, 0x6cb0, + 0x0916, 0x44b2, 0x1ec7, 0x4e51, 0x6a4a, 0xc059, 0x3399, 0x1ec4, + 0x6f16, 0x33bd, 0x70fd, 0x299f, 0x33af, 0x34e6, 0x3479, 0x70fd, + 0x0d9c, 0x3422, 0x25ea, 0x9d35, 0x35a4, 0x3a42, 0x0912, 0x2f97, + 0xe1c2, 0x611a, 0xe339, 0x70fd, 0x2319, 0x8a06, 0x4b06, 0x2572, + 0x6738, 0x7dfb, 0x1365, 0x70fd, 0x49fe, 0x70fd, 0x4ec2, 0xbe9a, + 0x4eda, 0x4c2d, 0x5266, 0x5263, 0x4f4d, 0x4705, 0x46f2, 0x5b14, + 0x541a, 0x394c, 0x5262, 0xd086, 0x525b, 0x46f0, 0x5303, 0x4924, + 0x5b09, 0xc58c, 0x4753, 0xcc11, 0x5929, 0x594e, 0x53c8, 0x590c, + 0x5bc9, 0x5ded, 0x5cc3, 0x492b, 0x46f8, 0x56da, 0x0975, 0x3bf2, + 0x5ee6, 0x70fd, 0x5b29, 0x70fd, 0x3ff9, 0x5941, 0xa551, 0x46e7, + 0x10db, 0x4376, 0x32e4, 0x33dc, 0x0fd1, 0x70fd, 0x32b7, 0x70fd, + 0x5171, 0xe12d, 0x70fd, 0x3329, 0x1e3e, 0x2460, 0x0f58, 0xa287, + 0xbe57, 0xd1d6, 0xb6b1, 0x8784, 0x81be, 0xe883, 0xcb1c, 0xcded, + 0x2f01, 0xc0ad, 0xe00f, 0x9f77, 0x71ee, 0xc606, 0xb24e, 0x1862, + 0x2d5f, 0xc1cc, 0x6fd0, 0x6f26, 0xc12b, +}; +static const unsigned short hkscs1999_2uni_pagec6[471] = { + /* 0xc6 */ + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x0460, + 0x0461, 0x0462, 0x0463, 0x0464, 0x0465, 0x0466, 0x0467, 0x0468, + 0x0469, 0x0474, 0x0475, 0x0476, 0x0477, 0x0478, 0x0479, 0x047a, + 0x047b, 0x047c, 0x047d, 0x0370, 0x0371, 0x0372, 0x0373, 0x0374, + 0x0375, 0x0376, 0x0377, 0x0378, 0x0379, 0x2076, 0x207f, 0x20c5, + 0x20e0, 0x23c2, 0x23d6, 0x23eb, 0x2539, 0x2578, 0x25a9, 0x25f6, + 0x2b4a, 0x2dc0, 0x301b, 0x05b3, 0x30bf, 0x70fd, 0x3190, 0x31a1, + 0x3774, 0x70fd, 0x4792, 0x70fd, 0x60f5, 0x70fd, 0x0028, 0x01c6, + 0x06bd, 0x06be, 0x065d, 0x065e, 0x70fd, 0x70fd, 0x05c5, 0x05c6, + 0x05c7, 0x06bc, 0x70bb, 0x70bd, 0x04fd, 0x0601, 0x0602, 0x0603, + 0x0604, 0x0605, 0x0606, 0x0607, 0x0608, 0x0609, 0x060a, 0x060b, + 0x060c, 0x060d, 0x060e, 0x060f, 0x0610, 0x0611, 0x0612, 0x0613, + 0x0614, 0x0615, 0x0616, 0x0617, 0x0618, + /* 0xc7 */ + 0x0619, 0x061a, 0x061b, 0x061c, 0x061d, 0x061e, 0x061f, 0x0620, + 0x0621, 0x0622, 0x0623, 0x0624, 0x0625, 0x0626, 0x0627, 0x0628, + 0x0629, 0x062a, 0x062b, 0x062c, 0x062d, 0x062e, 0x062f, 0x0630, + 0x0631, 0x0632, 0x0633, 0x0634, 0x0635, 0x0636, 0x0637, 0x0638, + 0x0639, 0x063a, 0x063b, 0x063c, 0x063d, 0x063e, 0x063f, 0x0640, + 0x0641, 0x0642, 0x0643, 0x0644, 0x0645, 0x0646, 0x0647, 0x0648, + 0x0649, 0x064a, 0x064b, 0x064c, 0x064d, 0x064e, 0x064f, 0x0650, + 0x0651, 0x0652, 0x0653, 0x0661, 0x0662, 0x0663, 0x0664, 0x0665, + 0x0666, 0x0667, 0x0668, 0x0669, 0x066a, 0x066b, 0x066c, 0x066d, + 0x066e, 0x066f, 0x0670, 0x0671, 0x0672, 0x0673, 0x0674, 0x0675, + 0x0676, 0x0677, 0x0678, 0x0679, 0x067a, 0x067b, 0x067c, 0x067d, + 0x067e, 0x067f, 0x0680, 0x0681, 0x0682, 0x0683, 0x0684, 0x0685, + 0x0686, 0x0687, 0x0688, 0x0689, 0x068a, 0x068b, 0x068c, 0x068d, + 0x068e, 0x068f, 0x0690, 0x0691, 0x0692, 0x0693, 0x0694, 0x0695, + 0x0696, 0x0697, 0x0698, 0x0699, 0x069a, 0x069b, 0x069c, 0x069d, + 0x069e, 0x069f, 0x06a0, 0x06a1, 0x06a2, 0x06a3, 0x06a4, 0x06a5, + 0x06a6, 0x06a7, 0x06a8, 0x06a9, 0x06aa, 0x06ab, 0x06ac, 0x06ad, + 0x06ae, 0x06af, 0x06b0, 0x06b1, 0x06b2, 0x06b3, 0x06b4, 0x06b5, + 0x06b6, 0x0210, 0x0211, 0x0212, 0x0213, 0x0214, 0x0215, 0x0201, + 0x0216, 0x0217, 0x0218, 0x0219, 0x021a, + /* 0xc8 */ + 0x021b, 0x021c, 0x021d, 0x021e, 0x021f, 0x0220, 0x0221, 0x0222, + 0x0223, 0x0224, 0x0225, 0x0226, 0x0227, 0x0228, 0x0229, 0x022a, + 0x022b, 0x022c, 0x022d, 0x022e, 0x022f, 0x0230, 0x0231, 0x0232, + 0x0233, 0x0234, 0x0235, 0x0251, 0x0236, 0x0237, 0x0238, 0x0239, + 0x023a, 0x023b, 0x023c, 0x023d, 0x023e, 0x023f, 0x0240, 0x0241, + 0x0242, 0x0243, 0x0244, 0x0245, 0x0246, 0x0247, 0x0248, 0x0249, + 0x024a, 0x024b, 0x024c, 0x024d, 0x024e, 0x024f, 0x03e7, 0x03b8, + 0x03b9, 0x06cf, 0x71cc, 0x209a, 0x718a, 0x2442, 0x1791, 0x7030, + 0x23c8, 0x7031, 0xd187, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70e2, 0x70e4, 0x7087, 0x7082, 0x0731, + 0x0316, 0x0321, 0x065b, 0x065c, 0x0500, 0x0504, 0x0506, 0x0507, + 0x0508, 0x050a, 0x050c, 0x050d, 0x0515, 0x051c, 0x051d, 0x0525, + 0x0527, 0x052a, 0x052c, 0x052e, 0x0536, 0x053c, 0x053e, 0x0546, + 0x054a, 0x054c, 0x054d, 0x054f, 0x0556, 0x0557, 0x055e, 0x0563, + 0x70fd, 0x70fd, 0x70fd, 0x0183, 0x0150, 0x015b, 0x0154, 0x0175, + 0x00d3, 0x0078, 0x00cb, 0x018a, 0x016a, +}; +static const unsigned short hkscs1999_2uni_pagef9[942] = { + /* 0xf9 */ + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x70fd, + 0x70fd, 0x70fd, 0x70fd, 0x70fd, 0x4a81, 0x63b9, 0x5a4f, 0x2afb, + 0x3292, 0x4ea7, 0x2d3a, 0x0494, 0x04a6, 0x0497, 0x04a0, 0x04ac, + 0x04a3, 0x049a, 0x04a9, 0x049d, 0x0492, 0x04a4, 0x0495, 0x049e, + 0x04aa, 0x04a1, 0x0498, 0x04a7, 0x049b, 0x0493, 0x04a5, 0x0496, + 0x049f, 0x04ab, 0x04a2, 0x0499, 0x04a8, 0x049c, 0x0491, 0x0490, + 0x04ad, 0x04ae, 0x04b0, 0x04af, 0x70ed, + /* 0xfa */ + 0x75c7, 0x63db, 0x765f, 0xa505, 0x574c, 0x15b5, 0x45ef, 0x23f5, + 0x0989, 0xadc2, 0xdfe4, 0x6444, 0x881b, 0x54ee, 0xa288, 0x4a3c, + 0x3984, 0x351f, 0xadb3, 0xdfaa, 0x7360, 0xc8f3, 0x81c5, 0x21eb, + 0x902d, 0x2248, 0xca69, 0xd584, 0x9f00, 0xaf31, 0x9053, 0x70fd, + 0x743e, 0x31e4, 0x7440, 0x7407, 0x40db, 0x74df, 0x70fd, 0x2341, + 0x07ba, 0x234e, 0x696c, 0x0a83, 0x5616, 0xae24, 0x7547, 0x23a0, + 0x9cf4, 0x23aa, 0x7abf, 0x8d3c, 0x73a5, 0x9070, 0x760e, 0x9bb3, + 0x87c3, 0x2dc2, 0x58fd, 0x7633, 0xa259, 0x23f2, 0x23f8, 0x6db4, + 0x2409, 0x240f, 0x2411, 0x0fdc, 0x2413, 0xaf26, 0x23f3, 0x2422, + 0x2582, 0x242d, 0x55cd, 0x3b7e, 0xa02d, 0x31bb, 0x244b, 0x2466, + 0x247c, 0x24f5, 0x2497, 0x24d4, 0x24f9, 0x2505, 0x4e15, 0x5742, + 0x2520, 0x57cd, 0xc853, 0x70fd, 0xe0de, 0x2789, 0x40d9, 0xa4c0, + 0x7894, 0xa52c, 0x2573, 0x70fd, 0x7aa2, 0x3f0b, 0x8566, 0x3a5b, + 0x45d5, 0x328a, 0x11aa, 0x0c0c, 0x8528, 0x43dd, 0x17a2, 0x25ad, + 0x25b4, 0xde2b, 0x25be, 0x70fd, 0x8416, 0x8453, 0x49e6, 0x25d3, + 0xe09b, 0x25e0, 0x25eb, 0x25ee, 0x45a7, 0xb8f2, 0x1259, 0x459c, + 0x2601, 0x2605, 0x3e89, 0x2089, 0x2a3e, 0x2619, 0x0deb, 0x7a4f, + 0x2620, 0xa52b, 0x97a3, 0x2636, 0x7b37, 0x2653, 0x4279, 0x276b, + 0x3897, 0x3f9b, 0x26ad, 0xc893, 0x7c34, 0x279d, 0x26cf, 0x26e4, + 0x1aa6, 0x854d, 0x7d9d, 0x10b4, 0x7c0d, + /* 0xfb */ + 0xdfbc, 0x9198, 0x2787, 0x1fad, 0x266f, 0x4617, 0x27c6, 0x27e9, + 0x70fd, 0x8717, 0xa57a, 0x1852, 0xa975, 0x38f3, 0x7f74, 0x2877, + 0x390d, 0x9c0a, 0x38e4, 0x38ed, 0x288d, 0x288f, 0x4af1, 0x2931, + 0x6887, 0x263e, 0x2940, 0x292f, 0x292d, 0xe166, 0x0963, 0x810f, + 0x2986, 0xa6e5, 0x3eae, 0x428b, 0x2982, 0x09f1, 0xc9be, 0x2a26, + 0x82d6, 0x2a43, 0x8314, 0xa8a3, 0x2a66, 0xaff5, 0x2a9c, 0x2aea, + 0x08a1, 0x2b20, 0x2b1c, 0x80fc, 0x2b3b, 0x2e3f, 0x2983, 0xee90, + 0xa7b8, 0x64d3, 0x08e1, 0x2b5f, 0x3ae6, 0x0a03, 0x4059, 0x847e, + 0x2c64, 0x2793, 0x84d2, 0x5705, 0x2c09, 0x7c0e, 0xc9c1, 0xca6a, + 0x861c, 0x2c19, 0x863b, 0x85f2, 0xcae6, 0x3fb1, 0x8668, 0x8515, + 0x2c39, 0xcb85, 0x2ceb, 0x2ca3, 0x0a26, 0xae29, 0x70fd, 0x0a48, + 0x2cd6, 0x4665, 0x2d13, 0xcce1, 0x9094, 0x1085, 0x8751, 0x0a72, + 0x84f8, 0x30c3, 0x2510, 0x2db6, 0x37c8, 0x2dbc, 0xd50e, 0x1304, + 0x1b5d, 0x72c4, 0x2e15, 0x33a0, 0x8874, 0xba8c, 0x7625, 0x2e33, + 0x2ddd, 0x1fd0, 0x2e45, 0x88c4, 0x2e53, 0x45ce, 0x2e54, 0x89e5, + 0xc868, 0x2e89, 0x1bdd, 0x2ec5, 0x2f29, 0x2f2f, 0x2fcb, 0x8ab9, + 0x8af7, 0x2f50, 0x2f58, 0x2f86, 0x8b24, 0x2efa, 0x3017, 0x54fc, + 0x0b6d, 0xad81, 0x8c89, 0x8db3, 0x5487, 0x0b76, 0x0f02, 0x306e, + 0x3cca, 0x70fd, 0x30ba, 0xa9fc, 0x7b93, 0x25e6, 0x20f7, 0x70fd, + 0x25e8, 0x85b1, 0x3049, 0x3134, 0xdcc2, + /* 0xfc */ + 0x3139, 0x313b, 0x0be0, 0x313c, 0x3a7e, 0x651b, 0x314d, 0x7281, + 0xf254, 0x0e1e, 0x1bae, 0x81fa, 0x317a, 0xc648, 0x8f50, 0x70fd, + 0x8fb1, 0x31a3, 0x68bd, 0xcbae, 0x31b2, 0x6440, 0xe036, 0x31e7, + 0x2ff6, 0x105f, 0xb510, 0x8bea, 0xce38, 0x9168, 0x62d6, 0x735e, + 0xe029, 0x3271, 0x38c5, 0x86b7, 0x0ca3, 0x10c7, 0x0979, 0x29d0, + 0x92b4, 0x4b71, 0x1140, 0x32de, 0x70fd, 0x32f3, 0xae02, 0xae0f, + 0xd553, 0x46a4, 0x2321, 0x2ce0, 0x33a4, 0x5624, 0x3382, 0xf266, + 0xcc12, 0x33c1, 0x2434, 0x76d6, 0x33c7, 0x2dea, 0xa4f7, 0x935f, + 0x3413, 0xe19d, 0xe8dd, 0x3410, 0x0c72, 0x9480, 0x93c1, 0x3263, + 0x339c, 0x375e, 0x35cb, 0x7218, 0x3505, 0x85b0, 0x3515, 0x980d, + 0x35ac, 0xae5f, 0x0d57, 0x3678, 0x3638, 0x824e, 0x863c, 0x70fd, + 0x418a, 0x9836, 0x6914, 0xa5cc, 0xb89d, 0x3721, 0x3725, 0x657b, + 0x0da6, 0x367a, 0x0d97, 0x378d, 0x4116, 0xaea8, 0xaea3, 0x37c5, + 0x37ad, 0x379f, 0x99fe, 0x37f5, 0xadc0, 0x1df7, 0x3811, 0x13d8, + 0x8669, 0x3820, 0x3823, 0x321f, 0x9d40, 0x3858, 0x9b77, 0x9b78, + 0x3884, 0x9b24, 0x9b25, 0x388b, 0x7d35, 0x38a7, 0xb4a6, 0x38b3, + 0x70fd, 0x8afd, 0x9bb1, 0xddb4, 0x9b48, 0xb5d3, 0x49c5, 0x93f7, + 0x6aa4, 0x3942, 0xa8dc, 0xaea1, 0x0e6b, 0x3c3a, 0xa0c2, 0x70fd, + 0x39a7, 0x39a2, 0xa70d, 0xe4ad, 0x3a17, 0x17e9, 0x3a62, 0x4050, + 0x633c, 0x3a41, 0x9d26, 0xcae0, 0x3a9d, + /* 0xfd */ + 0x9daf, 0x3c21, 0x3c4b, 0xe0df, 0x3bb3, 0x3b03, 0x9ecd, 0x3b41, + 0x3b40, 0x1032, 0x0d41, 0x9f3c, 0x0ec0, 0x39ec, 0x3ba1, 0xe04a, + 0x15fc, 0x3b76, 0x3bd8, 0x0ee1, 0x7489, 0x5563, 0x22d0, 0x3c39, + 0x9f59, 0x8d6a, 0x3c85, 0xa003, 0x3cdd, 0x0f33, 0x39f1, 0x3d08, + 0xe55c, 0x0f4d, 0x3d5d, 0x7863, 0x331e, 0x3d75, 0x3db4, 0x92cd, + 0x40b5, 0xa1db, 0x7475, 0x8798, 0x0a80, 0x2661, 0xa21a, 0x3e21, + 0xa43c, 0x3e1c, 0x3e77, 0x8fcb, 0xad71, 0xc891, 0x3e9a, 0x5426, + 0x3eb9, 0xa33c, 0x17c5, 0xa33d, 0xa6e4, 0xad8c, 0xad80, 0xa289, + 0x0a25, 0x0feb, 0x7bf2, 0x6c83, 0x9b79, 0x8fd1, 0x518f, 0x3a77, + 0xca65, 0xcae1, 0xcb2b, 0x3fd6, 0x3f9c, 0x407c, 0x4104, 0xadff, + 0xa5c5, 0xcbb2, 0x5733, 0xccb4, 0x2407, 0x70fd, 0x70fd, 0x562e, + 0xe121, 0x70fd, 0xa3af, 0x4653, 0xa4c2, 0x4bcc, 0x404f, 0x2cd1, + 0x99cb, 0x41f8, 0x0a4d, 0x419d, 0xa3b0, 0x40fa, 0x8357, 0xa57d, + 0x1855, 0x64f0, 0x4144, 0x415c, 0x104e, 0x4174, 0xe530, 0x103b, + 0x419f, 0xa684, 0x41d3, 0xa5d1, 0xa695, 0xa579, 0xa530, 0xa4f4, + 0xa67f, 0x241f, 0xa696, 0xa697, 0xa680, 0xc0dd, 0x424b, 0x427e, + 0x42a7, 0x4281, 0x42cc, 0x42d5, 0x42d6, 0x42df, 0x1404, 0x10e8, + 0x43b4, 0x4396, 0xa7b7, 0x432b, 0x4345, 0x2cc8, 0x434a, 0x70fd, + 0x2edc, 0xa8a5, 0x434f, 0x6462, 0xa801, 0x432c, 0xa99a, 0xaea7, + 0xaea2, 0x43ba, 0xe1e8, 0x42bd, 0x440e, + /* 0xfe */ + 0x6542, 0x4415, 0x2b51, 0x6543, 0x4424, 0x6441, 0xb785, 0x442e, + 0x4440, 0xadf4, 0x3afd, 0x4455, 0x4457, 0x1155, 0x99c4, 0x3a4d, + 0x413d, 0x4482, 0x70fd, 0x452b, 0xace3, 0xdeeb, 0x1bed, 0xdec4, + 0x4528, 0x452e, 0x45cf, 0x45aa, 0x7afa, 0xc7ee, 0x45c9, 0x4649, + 0xa722, 0x8527, 0xaea4, 0x3863, 0x0a05, 0xae37, 0xae0d, 0xae7b, + 0x45f7, 0x4615, 0x3b43, 0xaea6, 0x4639, 0x7643, 0x11d7, 0x70fd, + 0x93ad, 0x4660, 0xe3b2, 0x4647, 0x45e4, 0x4676, 0x55b9, 0x466c, + 0x0a70, 0x4674, 0x64f1, 0x3c6c, 0x4682, 0x1c53, 0xaf0c, 0xa69f, + 0xaef9, 0xe18f, 0x2d86, 0xe203, 0x86de, 0x46c8, 0x87c8, 0x470e, + 0x70fd, 0x471e, 0xe3d9, 0x888b, 0x2e17, 0xe3ac, 0x6485, 0x474d, + 0x474a, 0x4767, 0x476e, 0xb2c2, 0x1204, 0xb0d3, 0x478e, 0x465d, + 0x479e, 0x47b4, 0x4802, 0x482c, 0x4851, 0x484f, 0x486f, 0x4876, + 0xc275, 0x4890, 0x53ef, 0x0b38, 0xc6d1, 0xc6ce, 0x48a1, 0x48a5, + 0x48b7, 0x48cc, 0xccdf, 0x5662, 0xb3dd, 0xb47d, 0x8adc, 0x491e, + 0x4926, 0x4940, 0x36ef, 0xb4e0, 0x4958, 0x9c2c, 0x49af, 0xdf64, + 0xdf68, 0x8501, 0x49f4, 0x70fd, 0x8236, 0xae92, 0x3b0a, 0x4aaf, + 0x4ac7, 0x4ad3, 0x67a5, 0x4b2e, 0xb760, 0x4ad7, 0x4b34, 0x4ab1, + 0xd18c, 0x60f8, 0x5a04, 0xe12b, 0xbfc3, 0x911c, 0x4b86, 0x5a80, + 0x3b42, 0x4b80, 0xb957, 0x4b9d, 0xd639, 0x4b3c, 0x4ba9, 0x402a, + 0xce66, 0x11a8, 0x4bc6, 0xe4cd, 0x4bd4, +}; + +static const ucs4_t hkscs1999_2uni_upages[973] = { + 0x00080, 0x000c0, 0x00100, 0x00140, 0x001c0, 0x00240, 0x00280, 0x002c0, + 0x00400, 0x00440, 0x01e80, 0x01ec0, 0x02100, 0x02140, 0x02180, 0x021c0, + 0x023c0, 0x02440, 0x02540, 0x02700, 0x02e80, 0x02ec0, 0x02f00, 0x03000, + 0x03040, 0x03080, 0x030c0, 0x031c0, 0x03200, 0x03400, 0x03440, 0x03480, + 0x034c0, 0x03500, 0x03540, 0x03580, 0x035c0, 0x03600, 0x03640, 0x03680, + 0x036c0, 0x03700, 0x03740, 0x03780, 0x037c0, 0x03800, 0x03840, 0x03880, + 0x038c0, 0x03900, 0x03940, 0x03980, 0x039c0, 0x03a00, 0x03a40, 0x03a80, + 0x03ac0, 0x03b00, 0x03b40, 0x03b80, 0x03bc0, 0x03c00, 0x03c40, 0x03cc0, + 0x03d00, 0x03d40, 0x03d80, 0x03dc0, 0x03e00, 0x03e40, 0x03e80, 0x03ec0, + 0x03f00, 0x03f40, 0x03f80, 0x03fc0, 0x04000, 0x04040, 0x04080, 0x040c0, + 0x04100, 0x04140, 0x04180, 0x041c0, 0x04200, 0x04240, 0x04280, 0x042c0, + 0x04300, 0x04340, 0x04380, 0x043c0, 0x04400, 0x04440, 0x04480, 0x044c0, + 0x04500, 0x04540, 0x04580, 0x045c0, 0x04600, 0x04640, 0x04680, 0x046c0, + 0x04700, 0x04740, 0x04780, 0x047c0, 0x04800, 0x04840, 0x04880, 0x048c0, + 0x04900, 0x04940, 0x04980, 0x049c0, 0x04a00, 0x04a80, 0x04ac0, 0x04b00, + 0x04b40, 0x04b80, 0x04bc0, 0x04c00, 0x04c40, 0x04c80, 0x04cc0, 0x04d00, + 0x04d80, 0x04e00, 0x04e40, 0x04e80, 0x04ec0, 0x04f00, 0x04f40, 0x04f80, + 0x04fc0, 0x05000, 0x05040, 0x05080, 0x050c0, 0x05100, 0x05140, 0x05180, + 0x051c0, 0x05200, 0x05240, 0x05280, 0x052c0, 0x05300, 0x05340, 0x05380, + 0x053c0, 0x05400, 0x05440, 0x05480, 0x054c0, 0x05500, 0x05540, 0x05580, + 0x055c0, 0x05600, 0x05640, 0x05680, 0x056c0, 0x05700, 0x05740, 0x05780, + 0x057c0, 0x05800, 0x05840, 0x05880, 0x058c0, 0x05900, 0x05940, 0x05980, + 0x059c0, 0x05a00, 0x05a40, 0x05a80, 0x05ac0, 0x05b00, 0x05b40, 0x05b80, + 0x05bc0, 0x05c00, 0x05c40, 0x05c80, 0x05cc0, 0x05d00, 0x05d40, 0x05d80, + 0x05dc0, 0x05e00, 0x05e40, 0x05e80, 0x05ec0, 0x05f00, 0x05f40, 0x05f80, + 0x05fc0, 0x06000, 0x06040, 0x06080, 0x060c0, 0x06100, 0x06140, 0x06180, + 0x061c0, 0x06200, 0x06240, 0x06280, 0x062c0, 0x06300, 0x06340, 0x06380, + 0x063c0, 0x06400, 0x06440, 0x06480, 0x064c0, 0x06500, 0x06540, 0x06580, + 0x065c0, 0x06600, 0x06640, 0x06680, 0x066c0, 0x06700, 0x06740, 0x06780, + 0x067c0, 0x06800, 0x06840, 0x06880, 0x068c0, 0x06900, 0x06940, 0x06980, + 0x069c0, 0x06a00, 0x06a40, 0x06a80, 0x06ac0, 0x06b00, 0x06b40, 0x06b80, + 0x06bc0, 0x06c00, 0x06c40, 0x06c80, 0x06cc0, 0x06d00, 0x06d40, 0x06d80, + 0x06e00, 0x06e40, 0x06e80, 0x06ec0, 0x06f00, 0x06f40, 0x06f80, 0x06fc0, + 0x07000, 0x07040, 0x07080, 0x070c0, 0x07100, 0x07140, 0x07180, 0x071c0, + 0x07200, 0x07240, 0x07280, 0x072c0, 0x07300, 0x07340, 0x07380, 0x073c0, + 0x07400, 0x07440, 0x07480, 0x074c0, 0x07500, 0x07540, 0x07580, 0x075c0, + 0x07600, 0x07640, 0x07680, 0x076c0, 0x07700, 0x07740, 0x07780, 0x077c0, + 0x07800, 0x07840, 0x07880, 0x078c0, 0x07900, 0x07940, 0x07980, 0x079c0, + 0x07a00, 0x07a40, 0x07a80, 0x07ac0, 0x07b00, 0x07b40, 0x07b80, 0x07bc0, + 0x07c00, 0x07c40, 0x07c80, 0x07cc0, 0x07d00, 0x07d40, 0x07d80, 0x07dc0, + 0x07e00, 0x07e40, 0x07e80, 0x07ec0, 0x07f00, 0x07f40, 0x07f80, 0x07fc0, + 0x08000, 0x08040, 0x08080, 0x080c0, 0x08100, 0x08140, 0x08180, 0x081c0, + 0x08200, 0x08240, 0x08280, 0x082c0, 0x08300, 0x08340, 0x08380, 0x083c0, + 0x08400, 0x08440, 0x08480, 0x084c0, 0x08500, 0x08540, 0x085c0, 0x08600, + 0x08640, 0x08680, 0x086c0, 0x08740, 0x08780, 0x087c0, 0x08800, 0x08840, + 0x08880, 0x088c0, 0x08900, 0x08940, 0x08980, 0x089c0, 0x08a00, 0x08a40, + 0x08a80, 0x08ac0, 0x08b00, 0x08b40, 0x08b80, 0x08bc0, 0x08c40, 0x08c80, + 0x08cc0, 0x08d00, 0x08d40, 0x08d80, 0x08dc0, 0x08e00, 0x08e40, 0x08e80, + 0x08ec0, 0x08f00, 0x08f40, 0x08f80, 0x08fc0, 0x09000, 0x09040, 0x09080, + 0x090c0, 0x09140, 0x09180, 0x091c0, 0x09200, 0x09240, 0x09280, 0x092c0, + 0x09300, 0x09340, 0x09380, 0x093c0, 0x09400, 0x09440, 0x09480, 0x094c0, + 0x09500, 0x09540, 0x09580, 0x095c0, 0x09600, 0x09640, 0x09680, 0x096c0, + 0x09700, 0x09740, 0x09780, 0x097c0, 0x09800, 0x09840, 0x09880, 0x098c0, + 0x09900, 0x09940, 0x09980, 0x099c0, 0x09a00, 0x09a40, 0x09a80, 0x09ac0, + 0x09b00, 0x09b40, 0x09b80, 0x09bc0, 0x09c00, 0x09c40, 0x09d00, 0x09d40, + 0x09d80, 0x09dc0, 0x09e00, 0x09e40, 0x09e80, 0x09ec0, 0x09f00, 0x09f40, + 0x09f80, 0x0f900, 0x0ff00, 0x0ffc0, 0x20000, 0x20040, 0x20080, 0x200c0, + 0x20100, 0x20180, 0x201c0, 0x20200, 0x20240, 0x20280, 0x202c0, 0x20300, + 0x20340, 0x20380, 0x203c0, 0x20400, 0x20440, 0x20480, 0x204c0, 0x20540, + 0x20580, 0x205c0, 0x20600, 0x20640, 0x20700, 0x20740, 0x20800, 0x20840, + 0x208c0, 0x20900, 0x20940, 0x209c0, 0x20a00, 0x20a40, 0x20a80, 0x20ac0, + 0x20b00, 0x20b80, 0x20bc0, 0x20c00, 0x20c40, 0x20c80, 0x20cc0, 0x20d00, + 0x20d40, 0x20d80, 0x20dc0, 0x20e00, 0x20e40, 0x20e80, 0x20ec0, 0x20f00, + 0x20f40, 0x20f80, 0x20fc0, 0x21000, 0x21040, 0x21080, 0x210c0, 0x21100, + 0x21140, 0x21180, 0x211c0, 0x21200, 0x21240, 0x21280, 0x212c0, 0x21300, + 0x21340, 0x21380, 0x213c0, 0x21400, 0x21440, 0x21480, 0x214c0, 0x21540, + 0x21580, 0x21600, 0x21640, 0x21680, 0x216c0, 0x21700, 0x21740, 0x21780, + 0x217c0, 0x21800, 0x21840, 0x21880, 0x218c0, 0x21900, 0x21940, 0x21980, + 0x219c0, 0x21a00, 0x21a40, 0x21b40, 0x21bc0, 0x21c00, 0x21c40, 0x21c80, + 0x21d40, 0x21d80, 0x21dc0, 0x21e00, 0x21e80, 0x21ec0, 0x21f00, 0x21f40, + 0x21f80, 0x21fc0, 0x22040, 0x22080, 0x220c0, 0x22100, 0x22140, 0x22180, + 0x221c0, 0x22200, 0x22240, 0x22300, 0x22380, 0x223c0, 0x22440, 0x22480, + 0x224c0, 0x22500, 0x22540, 0x22580, 0x22600, 0x22640, 0x22680, 0x226c0, + 0x22700, 0x22740, 0x22780, 0x227c0, 0x22800, 0x22840, 0x22880, 0x228c0, + 0x22900, 0x22940, 0x22980, 0x22a40, 0x22ac0, 0x22b00, 0x22b40, 0x22bc0, + 0x22c00, 0x22c40, 0x22c80, 0x22cc0, 0x22d00, 0x22d40, 0x22d80, 0x22dc0, + 0x22e00, 0x22e40, 0x22e80, 0x22ec0, 0x22f40, 0x22fc0, 0x23000, 0x23040, + 0x23080, 0x230c0, 0x23100, 0x23140, 0x23180, 0x231c0, 0x23200, 0x23240, + 0x23280, 0x232c0, 0x23300, 0x23380, 0x233c0, 0x23400, 0x23440, 0x234c0, + 0x23500, 0x23540, 0x23580, 0x235c0, 0x23600, 0x23640, 0x23680, 0x236c0, + 0x23700, 0x23740, 0x23780, 0x237c0, 0x23800, 0x239c0, 0x23a80, 0x23ac0, + 0x23b40, 0x23c80, 0x23cc0, 0x23d40, 0x23d80, 0x23dc0, 0x23e00, 0x23e80, + 0x23ec0, 0x23f00, 0x23f40, 0x23f80, 0x23fc0, 0x24000, 0x24040, 0x24080, + 0x240c0, 0x24100, 0x24140, 0x24180, 0x241c0, 0x24200, 0x24240, 0x24280, + 0x242c0, 0x24300, 0x24340, 0x24380, 0x243c0, 0x24400, 0x24440, 0x24480, + 0x244c0, 0x24500, 0x24540, 0x245c0, 0x24600, 0x24640, 0x24680, 0x246c0, + 0x24700, 0x24780, 0x247c0, 0x24800, 0x24880, 0x248c0, 0x24900, 0x24940, + 0x24980, 0x249c0, 0x24a00, 0x24a40, 0x24a80, 0x24ac0, 0x24b40, 0x24bc0, + 0x24c00, 0x24c80, 0x24cc0, 0x24d00, 0x24d80, 0x24dc0, 0x24e00, 0x24e40, + 0x24e80, 0x24f00, 0x24f40, 0x24f80, 0x24fc0, 0x25000, 0x25040, 0x25080, + 0x25100, 0x25140, 0x251c0, 0x25200, 0x25240, 0x25280, 0x252c0, 0x25300, + 0x25400, 0x25440, 0x25500, 0x25540, 0x25580, 0x255c0, 0x25600, 0x25640, + 0x25680, 0x256c0, 0x25700, 0x25740, 0x257c0, 0x25840, 0x258c0, 0x25900, + 0x25940, 0x25980, 0x259c0, 0x25a80, 0x25ac0, 0x25b40, 0x25b80, 0x25bc0, + 0x25c00, 0x25c40, 0x25c80, 0x25cc0, 0x25d00, 0x25d40, 0x25e00, 0x25e40, + 0x25e80, 0x25ec0, 0x25f00, 0x25f40, 0x25fc0, 0x26000, 0x26040, 0x26080, + 0x26100, 0x26140, 0x26180, 0x261c0, 0x26240, 0x262c0, 0x26300, 0x26340, + 0x26380, 0x263c0, 0x26400, 0x26440, 0x26480, 0x26500, 0x26540, 0x26580, + 0x26600, 0x26680, 0x266c0, 0x26700, 0x26740, 0x26780, 0x267c0, 0x26800, + 0x26840, 0x26880, 0x268c0, 0x26900, 0x26940, 0x26980, 0x269c0, 0x26a00, + 0x26a40, 0x26b00, 0x26b40, 0x26b80, 0x26bc0, 0x26c00, 0x26c40, 0x26c80, + 0x26cc0, 0x26d00, 0x26d40, 0x26d80, 0x26dc0, 0x26e00, 0x26e40, 0x26e80, + 0x26ec0, 0x26f00, 0x26f40, 0x26f80, 0x26fc0, 0x27000, 0x27040, 0x27080, + 0x270c0, 0x27100, 0x27140, 0x271c0, 0x27200, 0x27280, 0x272c0, 0x27380, + 0x27400, 0x27440, 0x27480, 0x27540, 0x27580, 0x275c0, 0x27600, 0x27640, + 0x27680, 0x27700, 0x27740, 0x27780, 0x277c0, 0x27840, 0x27880, 0x278c0, + 0x27900, 0x27940, 0x27980, 0x279c0, 0x27a00, 0x27a40, 0x27a80, 0x27ac0, + 0x27b00, 0x27b40, 0x27bc0, 0x27c00, 0x27d00, 0x27d40, 0x27d80, 0x27dc0, + 0x27e40, 0x27f00, 0x27fc0, 0x28000, 0x28040, 0x28080, 0x280c0, 0x28100, + 0x28140, 0x28180, 0x28200, 0x28240, 0x28280, 0x282c0, 0x28300, 0x28340, + 0x28380, 0x28400, 0x28440, 0x28480, 0x28500, 0x28540, 0x285c0, 0x28600, + 0x28680, 0x286c0, 0x28700, 0x28800, 0x28900, 0x28940, 0x28980, 0x289c0, + 0x28a00, 0x28a40, 0x28a80, 0x28ac0, 0x28b00, 0x28b40, 0x28b80, 0x28bc0, + 0x28c00, 0x28cc0, 0x28d00, 0x28d80, 0x28e00, 0x28e40, 0x28e80, 0x28ec0, + 0x28fc0, 0x29080, 0x290c0, 0x29100, 0x29140, 0x29180, 0x291c0, 0x29400, + 0x29440, 0x294c0, 0x29580, 0x295c0, 0x29700, 0x297c0, 0x29800, 0x29840, + 0x29880, 0x298c0, 0x29900, 0x29940, 0x29980, 0x299c0, 0x29a00, 0x29a40, + 0x29b00, 0x29bc0, 0x29c80, 0x29d00, 0x29d40, 0x29d80, 0x29dc0, 0x29e00, + 0x29e40, 0x29e80, 0x29ec0, 0x29f00, 0x29f80, 0x29fc0, 0x2a000, 0x2a080, + 0x2a0c0, 0x2a100, 0x2a140, 0x2a180, 0x2a1c0, 0x2a200, 0x2a280, 0x2a2c0, + 0x2a380, 0x2a400, 0x2a440, 0x2a5c0, 0x2a600, 0x2a640, 0x2a680, 0x2f800, + 0x2f840, 0x2f880, 0x2f8c0, 0x2f980, 0x2f9c0, +}; + +static int +hkscs1999_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x88 && c1 <= 0x8b) || (c1 >= 0x8d && c1 <= 0xa0) || (c1 >= 0xc6 && c1 <= 0xc8) || (c1 >= 0xf9 && c1 <= 0xfe)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0xa1 && c2 < 0xff)) { + unsigned int i = 157 * (c1 - 0x80) + (c2 - (c2 >= 0xa1 ? 0x62 : 0x40)); + ucs4_t wc = 0xfffd; + unsigned short swc; + if (i < 2041) { + if (i < 1883) + swc = hkscs1999_2uni_page88[i-1256], + wc = hkscs1999_2uni_upages[swc>>6] | (swc & 0x3f); + } else if (i < 10990) { + if (i < 5181) + swc = hkscs1999_2uni_page8d[i-2041], + wc = hkscs1999_2uni_upages[swc>>6] | (swc & 0x3f); + } else if (i < 18997) { + if (i < 11461) + swc = hkscs1999_2uni_pagec6[i-10990], + wc = hkscs1999_2uni_upages[swc>>6] | (swc & 0x3f); + } else { + if (i < 19939) + swc = hkscs1999_2uni_pagef9[i-18997], + wc = hkscs1999_2uni_upages[swc>>6] | (swc & 0x3f); + } + if (wc != 0xfffd) { + *pwc = wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short hkscs1999_2charset[4698] = { + 0xc6d8, 0x8859, 0x8857, 0x885d, 0x885b, 0x8866, 0x8861, 0x885f, + 0x886a, 0x8868, 0x886f, 0x886d, 0x88a7, 0x8873, 0x8871, 0x8877, + 0x8875, 0xc8fb, 0x887b, 0x8879, 0x88a2, 0x8856, 0x8867, 0x885a, + 0x886c, 0x885c, 0x886e, 0x8870, 0xc8fc, 0x885e, 0x8874, 0xc8fa, + 0x8878, 0x8858, 0x8869, 0x8872, 0x8860, 0x8876, 0x887a, 0x887c, + 0x887d, 0x887e, 0x88a1, 0xc8f6, 0x886b, 0xc8f8, 0xc8f7, 0x88a8, + 0xc8fe, 0xc8f9, 0xc8f5, 0xc8fd, 0xc6d9, 0xc7f9, 0xc7f3, 0xc7f4, + 0xc7f5, 0xc7f6, 0xc7f7, 0xc7f8, 0xc7fa, 0xc7fb, 0xc7fc, 0xc7fd, + 0xc7fe, 0xc840, 0xc841, 0xc842, 0xc843, 0xc844, 0xc845, 0xc846, + 0xc847, 0xc848, 0xc849, 0xc84a, 0xc84b, 0xc84c, 0xc84d, 0xc84e, + 0xc84f, 0xc850, 0xc851, 0xc852, 0xc853, 0xc854, 0xc855, 0xc856, + 0xc857, 0xc858, 0xc859, 0xc85a, 0xc85c, 0xc85d, 0xc85e, 0xc85f, + 0xc860, 0xc861, 0xc862, 0xc863, 0xc864, 0xc865, 0xc866, 0xc867, + 0xc868, 0xc869, 0xc86a, 0xc86b, 0xc86c, 0xc86d, 0xc86e, 0xc86f, + 0xc870, 0xc871, 0xc872, 0xc873, 0xc874, 0xc875, 0xc85b, 0x8863, + 0x88a4, 0x8865, 0x88a6, 0xc8d2, 0xc8d3, 0xc6b5, 0xc6b6, 0xc6b7, + 0xc6b8, 0xc6b9, 0xc6ba, 0xc6bb, 0xc6bc, 0xc6bd, 0xc6be, 0xc877, + 0xc878, 0xc876, 0x88a9, 0x88aa, 0xc6a1, 0xc6a2, 0xc6a3, 0xc6a4, + 0xc6a5, 0xc6a6, 0xc6a7, 0xc6a8, 0xc6a9, 0xc6aa, 0xc6ab, 0xc6ac, + 0xc6ad, 0xc6ae, 0xc6af, 0xc6b0, 0xc6b1, 0xc6b2, 0xc6b3, 0xc6b4, + 0xf9f9, 0xf9f8, 0xf9e6, 0xf9ef, 0xf9dd, 0xf9e8, 0xf9f1, 0xf9df, + 0xf9ec, 0xf9f5, 0xf9e3, 0xf9ee, 0xf9f7, 0xf9e5, 0xf9e9, 0xf9f2, + 0xf9e0, 0xf9eb, 0xf9f4, 0xf9e2, 0xf9e7, 0xf9f0, 0xf9de, 0xf9ed, + 0xf9f6, 0xf9e4, 0xf9ea, 0xf9f3, 0xf9e1, 0xf9fa, 0xf9fb, 0xf9fd, + 0xf9fc, 0xc6e6, 0xc8d6, 0xc8d7, 0xc8d8, 0xc8d9, 0xc8da, 0xc8db, + 0xc8dc, 0xc8dd, 0xc8de, 0xc8df, 0xc8e0, 0xc8e1, 0xc8e2, 0xc8e3, + 0xc8e4, 0xc8e5, 0xc8e6, 0xc8e7, 0xc8e8, 0xc8e9, 0xc8ea, 0xc8eb, + 0xc8ec, 0xc8ed, 0xc8ee, 0xc8ef, 0xc8f0, 0xc8f1, 0xc6cd, 0xc6e0, + 0xc6e1, 0xc6e2, 0xc6e7, 0xc6e8, 0xc6e9, 0xc6ea, 0xc6eb, 0xc6ec, + 0xc6ed, 0xc6ee, 0xc6ef, 0xc6f0, 0xc6f1, 0xc6f2, 0xc6f3, 0xc6f4, + 0xc6f5, 0xc6f6, 0xc6f7, 0xc6f8, 0xc6f9, 0xc6fa, 0xc6fb, 0xc6fc, + 0xc6fd, 0xc6fe, 0xc740, 0xc741, 0xc742, 0xc743, 0xc744, 0xc745, + 0xc746, 0xc747, 0xc748, 0xc749, 0xc74a, 0xc74b, 0xc74c, 0xc74d, + 0xc74e, 0xc74f, 0xc750, 0xc751, 0xc752, 0xc753, 0xc754, 0xc755, + 0xc756, 0xc757, 0xc758, 0xc759, 0xc75a, 0xc75b, 0xc75c, 0xc75d, + 0xc75e, 0xc75f, 0xc760, 0xc761, 0xc762, 0xc763, 0xc764, 0xc765, + 0xc766, 0xc767, 0xc768, 0xc769, 0xc76a, 0xc76b, 0xc76c, 0xc76d, + 0xc76e, 0xc76f, 0xc770, 0xc771, 0xc772, 0xc773, 0xc774, 0xc775, + 0xc776, 0xc777, 0xc778, 0xc779, 0xc77a, 0xc8d4, 0xc8d5, 0xc6dc, + 0xc6dd, 0xc77b, 0xc77c, 0xc77d, 0xc77e, 0xc7a1, 0xc7a2, 0xc7a3, + 0xc7a4, 0xc7a5, 0xc7a6, 0xc7a7, 0xc7a8, 0xc7a9, 0xc7aa, 0xc7ab, + 0xc7ac, 0xc7ad, 0xc7ae, 0xc7af, 0xc7b0, 0xc7b1, 0xc7b2, 0xc7b3, + 0xc7b4, 0xc7b5, 0xc7b6, 0xc7b7, 0xc7b8, 0xc7b9, 0xc7ba, 0xc7bb, + 0xc7bc, 0xc7bd, 0xc7be, 0xc7bf, 0xc7c0, 0xc7c1, 0xc7c2, 0xc7c3, + 0xc7c4, 0xc7c5, 0xc7c6, 0xc7c7, 0xc7c8, 0xc7c9, 0xc7ca, 0xc7cb, + 0xc7cc, 0xc7cd, 0xc7ce, 0xc7cf, 0xc7d0, 0xc7d1, 0xc7d2, 0xc7d3, + 0xc7d4, 0xc7d5, 0xc7d6, 0xc7d7, 0xc7d8, 0xc7d9, 0xc7da, 0xc7db, + 0xc7dc, 0xc7dd, 0xc7de, 0xc7df, 0xc7e0, 0xc7e1, 0xc7e2, 0xc7e3, + 0xc7e4, 0xc7e5, 0xc7e6, 0xc7e7, 0xc7e8, 0xc7e9, 0xc7ea, 0xc7eb, + 0xc7ec, 0xc7ed, 0xc7ee, 0xc7ef, 0xc7f0, 0xc7f1, 0xc7f2, 0xc6e3, + 0xc6da, 0xc6db, 0x8840, 0x8841, 0x8842, 0x8843, 0x8844, 0x8846, + 0x8849, 0x884a, 0x884d, 0x884f, 0x8850, 0x8851, 0x8852, 0x8854, + 0x8855, 0xc879, 0xc8d1, 0x9277, 0x96df, 0x89d5, 0x93cd, 0x9bdf, + 0xfa68, 0x89da, 0x8f59, 0x89db, 0x8f5d, 0x89dc, 0x96f7, 0x8ada, + 0x8bdc, 0x97db, 0x9e53, 0x9daa, 0x9bea, 0x8a6e, 0x8bc8, 0x89e8, + 0x89ea, 0xfb70, 0x89ed, 0x94dd, 0x89ee, 0x9eb4, 0x8ad3, 0x92db, + 0x94db, 0x89f9, 0xfb7a, 0x89fb, 0x9efc, 0x89fc, 0x89bf, 0x89fe, + 0x89e6, 0x9d46, 0x9dee, 0xa07e, 0xa068, 0x98e9, 0x8b68, 0x8dfd, + 0x8bbe, 0x9fd9, 0x8aeb, 0x9fd7, 0x8b6a, 0x9c5c, 0x8bb1, 0xfb5e, + 0x9df3, 0xa0d0, 0xfc66, 0x92e9, 0x9aec, 0x8fab, 0xfa48, 0x8e45, + 0x9c6f, 0x9ede, 0x89ef, 0x96e9, 0x9ebb, 0x94de, 0x9eb8, 0x97ba, + 0xfb65, 0x95d6, 0x9cbb, 0x97da, 0x8f45, 0xfb7d, 0x9158, 0xfe64, + 0x9856, 0x9b4d, 0x935b, 0x95c7, 0x97e7, 0x9359, 0x91f5, 0x97b8, + 0xfda2, 0xfbb6, 0x92fa, 0x9357, 0x8ba6, 0xfbb9, 0x97b0, 0xfdc4, + 0x9ca1, 0x91f2, 0x91f9, 0x8ff1, 0x9745, 0x9853, 0xfe78, 0xfbc1, + 0x9251, 0x9dad, 0xfd6c, 0xfa6b, 0x9bc2, 0x9a7b, 0x8b60, 0x934b, + 0x9abd, 0x91b7, 0x95b4, 0xfec5, 0x9ef0, 0x8d64, 0x9269, 0x8d67, + 0xfbea, 0xfbef, 0x8d68, 0x93eb, 0xfc42, 0x9166, 0xfacd, 0x93dd, + 0x8bcc, 0x8d6d, 0x8d6e, 0x96a8, 0xfca6, 0x8d6f, 0x8d70, 0xfc64, + 0x9060, 0x8d74, 0x97c3, 0x8ad0, 0x9274, 0x9bbe, 0x9cc8, 0x9cba, + 0x8d78, 0x9eb9, 0x955a, 0x91b4, 0x8a48, 0x8d7d, 0x8a7d, 0x8ac2, + 0xfd4a, 0x8da1, 0x8ad1, 0xfcb4, 0x8b47, 0x93a4, 0x9eda, 0x8a51, + 0x8da6, 0x9ec5, 0xfcc4, 0xa078, 0x94b5, 0xfcc2, 0x8a6b, 0x8dab, + 0xfae8, 0x8dad, 0xfc49, 0x93c1, 0x906f, 0x8db0, 0x947e, 0x90fa, + 0x9479, 0x8db2, 0xfcee, 0x997b, 0x8db4, 0x8db7, 0x91b3, 0x8dbb, + 0x8dba, 0x8dbc, 0x9044, 0xfd4c, 0x93e4, 0x93e0, 0xfd53, 0x8dc3, + 0x9bb8, 0xfbf0, 0x93e9, 0x93f6, 0x8dc5, 0x8dca, 0x8dcc, 0xfd5d, + 0x93b5, 0xfd61, 0x9cf8, 0x9252, 0xa0e8, 0x9ca5, 0x8dd6, 0x97c0, + 0xa0de, 0x97d2, 0xfaa5, 0xfda3, 0x8ddb, 0x8eaf, 0x91b5, 0xfd49, + 0xfdd1, 0x8deb, 0x97c6, 0xfdce, 0x90fc, 0xfc59, 0x96d6, 0x97c5, + 0x8def, 0x97d7, 0x8df0, 0x96a6, 0xfbbf, 0x8df3, 0x9449, 0x8df5, + 0x9872, 0x8e6b, 0xfafd, 0x8f50, 0x9dcc, 0xfc65, 0x996e, 0x94a1, + 0x8f63, 0xa0da, 0x9253, 0xfde9, 0x9db5, 0x9879, 0x9d5d, 0x8d63, + 0x9669, 0x9f70, 0xfc6a, 0x8ac7, 0x89d7, 0xfe4d, 0x9edd, 0xfefb, + 0x98bc, 0xfacc, 0x95b0, 0x9464, 0x936f, 0x94b9, 0x95ec, 0x91ee, + 0x98c3, 0x95f6, 0x8ffd, 0x98c5, 0x9766, 0xfe6e, 0x97dd, 0x92d2, + 0x9761, 0x98cb, 0x95f0, 0x975d, 0x91e3, 0x98cc, 0x9469, 0x98cd, + 0x98ce, 0x95fc, 0x94a3, 0x9662, 0xfeb6, 0x9463, 0x98d0, 0x98d1, + 0x9475, 0xfae0, 0x9472, 0x98d6, 0x8af0, 0x98d9, 0x98db, 0x98dd, + 0x98a8, 0x8a6d, 0x8afb, 0x8aae, 0xfbc9, 0x98e4, 0x98e6, 0x98e8, + 0x8a4d, 0x9257, 0x95df, 0xa0ac, 0x98eb, 0x98ec, 0x98f4, 0x8ab8, + 0x9ee7, 0x94bc, 0xfcd1, 0x9cc6, 0x9e7e, 0x98fe, 0xfde8, 0x9940, + 0x94c9, 0x94d3, 0x9946, 0x90c0, 0x94d1, 0x9573, 0x93c2, 0x9948, + 0x994b, 0x8e55, 0x994e, 0x8efe, 0x8e59, 0x94ec, 0x94ef, 0x8f74, + 0x9955, 0x9544, 0x9956, 0x9959, 0x995b, 0xfa45, 0x90b7, 0x9743, + 0x95cd, 0x97c9, 0xfd50, 0x8eb9, 0x95c6, 0x9967, 0x8ab9, 0x8dfc, + 0x8a76, 0x9d51, 0x9973, 0x9d4f, 0x997a, 0x9564, 0x99a1, 0x99a5, + 0x99a7, 0x8eed, 0x99ad, 0xc87e, 0x946e, 0x8f70, 0xfad0, 0x99b3, + 0xa053, 0x965c, 0xfd7a, 0x97fe, 0x92bd, 0x97fd, 0x8f64, 0xfcf7, + 0x9562, 0x97cd, 0x9e64, 0x924c, 0x8ec9, 0x99bc, 0x9da5, 0x8f54, + 0x8f7c, 0x8ea2, 0x8f7a, 0x97ae, 0x96c8, 0x99c3, 0x90d6, 0x9cbe, + 0x8f76, 0x9470, 0xfb4b, 0xfdca, 0x8ec7, 0xa0f9, 0x8fa9, 0x99c7, + 0x90d7, 0x9edf, 0x99ce, 0x8fba, 0x8feb, 0x99cf, 0x8fc2, 0x92c9, + 0x97dc, 0x95b3, 0x9c79, 0x95b2, 0x8fdb, 0x9be3, 0x9e7a, 0x9bee, + 0x99de, 0xfafa, 0x8a52, 0x99e1, 0x8a67, 0x8bb5, 0x8aac, 0x99e9, + 0xfbca, 0x97de, 0x95d1, 0x99f5, 0xfc4a, 0x9ba9, 0xfbdc, 0xfe56, + 0x9ea4, 0x9d49, 0x95db, 0x89c5, 0x99f8, 0x9664, 0x9055, 0x96d4, + 0x977c, 0x964d, 0x97e1, 0x9a48, 0x9a49, 0xfe7d, 0x90aa, 0x9a50, + 0x9347, 0x8ed8, 0x90c9, 0x9a55, 0x90bc, 0x9a58, 0x8bb8, 0x90d5, + 0x9641, 0x9a5a, 0x9a5c, 0x97c2, 0x8abb, 0x9baa, 0x90f5, 0x9a60, + 0x9145, 0x9a63, 0x8bb6, 0xfccf, 0x966b, 0x9a6e, 0x914f, 0x9746, + 0xa0e6, 0x92d7, 0x9675, 0x93d4, 0x91bb, 0x9679, 0x9a70, 0x9678, + 0x91cd, 0x9c4a, 0xa06f, 0xa06a, 0x915f, 0x9fa5, 0x89ba, 0x9ecd, + 0x9a79, 0x9dce, 0x9d73, 0x96b9, 0x96bc, 0x9cd1, 0x89b7, 0x9eee, + 0xfb43, 0x9ec9, 0xfbd3, 0x91ae, 0x9d78, 0x9d7b, 0x9eb3, 0x9eb2, + 0x9dd6, 0x994f, 0x89ce, 0x8bc0, 0x9fc4, 0x8bd4, 0xc6bf, 0x8bf9, + 0x8946, 0xc6c0, 0xfae5, 0xc87b, 0x8bc6, 0x9c57, 0x9afb, 0x89d0, + 0x89cf, 0xc6c1, 0x89d1, 0x89e2, 0x927e, 0x9dba, 0xc6c2, 0xfbf8, + 0x8bc7, 0x926b, 0x89d2, 0x9fcf, 0x9da9, 0x89d3, 0x99e2, 0x9267, + 0x92a4, 0x894e, 0x894f, 0x9278, 0x91b6, 0x89d4, 0x9fd2, 0x92a7, + 0x95a2, 0x926e, 0x96ea, 0x926f, 0x92a3, 0x8950, 0xfa57, 0x9866, + 0x89d6, 0x98b2, 0x92ab, 0x96de, 0x92ac, 0x9f6e, 0x8ef2, 0x9f6c, + 0x89d8, 0xfa59, 0x92a8, 0x9163, 0x9f73, 0x92ad, 0x9be9, 0x92a9, + 0x92aa, 0x89d9, 0xfd56, 0x9fa8, 0x92a1, 0x90e3, 0xa0a6, 0x94ab, + 0xfc72, 0x97c4, 0x92ae, 0xfa67, 0x92a2, 0xfa69, 0x9268, 0x8951, + 0xfa6f, 0xfa71, 0x8952, 0x945a, 0xc6c3, 0x89dd, 0xc8a2, 0xc6c4, + 0x9e52, 0x8953, 0x9e55, 0x92ba, 0xc6c5, 0xfa7d, 0xfaa8, 0x9a68, + 0xfa47, 0xfa7e, 0x92bb, 0xfdb6, 0xfaa2, 0xfaa3, 0xfaa4, 0x9bb4, + 0xfaa6, 0x89df, 0xfddb, 0xfaa9, 0x8954, 0xfaab, 0xfc7a, 0x89e0, + 0x9f4f, 0xc87d, 0x89e1, 0xfab0, 0x9fcd, 0xa0e7, 0xfab1, 0x89a6, + 0x9efa, 0xfab2, 0xfab4, 0x92c4, 0x9f6f, 0x8bb0, 0x9fac, 0x89e3, + 0x9bd3, 0x89e4, 0xfab5, 0x9fd5, 0x8955, 0x92c5, 0x8956, 0xfab3, + 0xfab6, 0xfab7, 0x9edc, 0xfbc4, 0x9f71, 0xfaba, 0x92c7, 0xc6c6, + 0x9a4c, 0x89e5, 0x9f7d, 0xa0a9, 0xfac4, 0xc6c7, 0x8957, 0xfaaa, + 0x8958, 0x8be3, 0x8b61, 0x9af1, 0x9eb7, 0xc6c8, 0xfad1, 0xfad2, + 0x9eba, 0xfad4, 0xfad9, 0xfadb, 0x9ce0, 0xfbf7, 0xfbfa, 0x89e7, + 0xa07a, 0xfadc, 0xfadd, 0x89e9, 0xc6c9, 0xfae2, 0x89eb, 0xfae3, + 0x90c8, 0x92da, 0x8959, 0x9cf5, 0x895a, 0xfae7, 0x9fa2, 0xfaea, + 0xfaed, 0x8fad, 0xfb59, 0xfaef, 0x96ef, 0x9dec, 0x9dca, 0xfd6d, + 0x89ec, 0xfb44, 0x9de2, 0x9ec0, 0x9e56, 0x9f79, 0x9ac7, 0xfaf4, + 0x98a1, 0xfaf8, 0x89f0, 0x9e47, 0x9df7, 0x9fd3, 0x9aca, 0x89f1, + 0xfaf9, 0x8e5a, 0x89f2, 0x89f3, 0x925d, 0x8b51, 0x92e0, 0x89f4, + 0x9fd4, 0x8a79, 0x89f5, 0x97a7, 0x93ba, 0x9e58, 0x89f6, 0x9e57, + 0x89f7, 0x8a41, 0x89f8, 0xfaf1, 0x89fa, 0xfb42, 0xfabf, 0xfba3, + 0xfaf7, 0x9e4e, 0x94dc, 0x95da, 0x9df8, 0x9f6a, 0x8ab7, 0xfb46, + 0x8a46, 0xfb47, 0x9148, 0x92de, 0x8b53, 0x9df6, 0x9bda, 0x9d7e, + 0x89fd, 0x99e4, 0x9e43, 0x9de9, 0x8f52, 0x9df5, 0x9df0, 0x99e7, + 0x8bbd, 0x9def, 0x9fb7, 0x9dd0, 0x9feb, 0x8da9, 0x9dcf, 0x98e1, + 0x9de5, 0x9dc8, 0xfb4f, 0x9deb, 0xfb54, 0xfb55, 0x9aa2, 0x8ad6, + 0x9a5f, 0x9ef5, 0x8fb7, 0x9ad2, 0x9e6a, 0x9ee8, 0x8bbf, 0x91c2, + 0x9d62, 0x9260, 0x925e, 0x91c1, 0x8ac5, 0x97a3, 0x8b6c, 0x8d7e, + 0x9c54, 0x9dbd, 0x9cc5, 0x895b, 0xfb5c, 0xfb5b, 0xfb57, 0x98c7, + 0xfb5a, 0x9cee, 0x92e2, 0x94a7, 0x9bd4, 0xfb64, 0xfb76, 0xfb60, + 0x99e5, 0x9ac2, 0x91fb, 0xa073, 0x9f72, 0x9fcc, 0x98a5, 0x92e8, + 0x9bbc, 0x96f3, 0x92e7, 0xfc67, 0x8b7d, 0x9bf4, 0x9ef7, 0x9ec1, + 0x996f, 0x96f1, 0x8e41, 0x954a, 0x97e6, 0x96f5, 0x92e6, 0x9f42, + 0xfb67, 0x99a9, 0xfae6, 0xfb69, 0x97e5, 0x967d, 0xfb6c, 0x99a2, + 0x9abb, 0x9a65, 0x944e, 0xfb6e, 0x99df, 0x98e3, 0x9254, 0x967b, + 0x8aaf, 0x8baf, 0x9ebd, 0x9ee6, 0xfb6f, 0x8ee1, 0x9b7d, 0x9c7e, + 0xf9d9, 0x92ea, 0xfb72, 0xfb71, 0x895c, 0x98f0, 0x96f2, 0xfb74, + 0x8bc1, 0x895d, 0x89de, 0x895e, 0xc6ca, 0xfe42, 0xfb7b, 0x895f, + 0x8960, 0x9bcd, 0x9dd3, 0x984c, 0x9752, 0x95c3, 0x9bb6, 0x9ab9, + 0x97b3, 0x9f74, 0x92f1, 0x97df, 0xfba6, 0xfbab, 0x9877, 0x9854, + 0x95c5, 0x9d55, 0xfbb2, 0x957e, 0x9742, 0x94e6, 0x92f5, 0x92fd, + 0xfba2, 0x9c51, 0x94e9, 0x985c, 0x92f0, 0x944c, 0x916b, 0x8b78, + 0x94e2, 0x984f, 0xfbb5, 0x9271, 0x9365, 0x985b, 0x9850, 0x97bc, + 0x92f3, 0x9340, 0x984d, 0x9572, 0xfdef, 0xfdc1, 0xfbba, 0x92eb, + 0xfc73, 0x97b7, 0xfbb4, 0x90a7, 0x9741, 0x92f4, 0xfbbc, 0x9577, + 0x9ee2, 0x8f78, 0xf9dc, 0x9672, 0x9eb5, 0x964b, 0xa0fa, 0x9575, + 0x90da, 0x9367, 0xfea4, 0x90df, 0x9354, 0x8961, 0x8bb4, 0x9dc0, + 0x8e48, 0xfbc5, 0xfbc7, 0xc6cb, 0xfa79, 0x9e67, 0xfbd2, 0x8962, + 0x8963, 0xfc7d, 0x9f6b, 0xfbcc, 0xfeae, 0xfbd1, 0xfb75, 0xfbd4, + 0xfbd6, 0xfbd8, 0x8b5d, 0x934c, 0x9ae2, 0x8bc9, 0xfbdb, 0x9fc9, + 0x9f44, 0x98ed, 0xfbdd, 0x8df2, 0x8964, 0xfdf2, 0x934d, 0xfbe7, + 0xa0f2, 0x9868, 0x9f58, 0x8d73, 0xfbde, 0xfbdf, 0xfbe3, 0x8da8, + 0xfbe4, 0x9c75, 0x9878, 0x8d60, 0xfbe5, 0x8d61, 0x8d62, 0xa0a1, + 0x9c40, 0x98ad, 0x9eea, 0x9ceb, 0xfbe0, 0x9f51, 0x8d65, 0x9cf1, + 0xfc58, 0x8d66, 0x9654, 0xfbe8, 0xc6cc, 0x9fce, 0xfbfc, 0x9ae4, + 0x9f75, 0xfbf1, 0x8d69, 0x934f, 0x934e, 0xfbf4, 0xc6ce, 0xfbc3, + 0x8965, 0x8d6a, 0x9353, 0x9dfb, 0xfbfd, 0x9059, 0xfc40, 0xfc41, + 0xfc43, 0x9361, 0xfc46, 0x9362, 0x8d6b, 0xfc4c, 0x95b8, 0xc6d0, + 0x8bca, 0x987a, 0xc6d1, 0xfc51, 0xfc54, 0xfaaf, 0x8d6c, 0xfa61, + 0xfc57, 0x9b70, 0xa051, 0x8bcb, 0x936e, 0xfcd5, 0xfca9, 0xfc61, + 0x8966, 0xfacb, 0xf9da, 0x937a, 0xa0e0, 0x936b, 0xfc6b, 0xa0dc, + 0x9468, 0xfc6d, 0x8d71, 0xfd64, 0x99ba, 0x9ad0, 0x9a61, 0xa0e5, + 0xa05b, 0x96ac, 0x9740, 0x9ef1, 0x9f7e, 0x8d72, 0xfc76, 0x96a9, + 0xa06e, 0xfcaa, 0xfbcd, 0xfc74, 0xa074, 0xa071, 0xfc79, 0xfc7c, + 0x9c50, 0x9379, 0x9378, 0xa0dd, 0x8d75, 0x8d76, 0x9374, 0x8d77, + 0xfca5, 0xfca2, 0x90c3, 0xa079, 0x8d79, 0x8bfc, 0xa076, 0x8bcd, + 0x9f5a, 0x9ff4, 0x9fba, 0x8d7a, 0x9e45, 0x93b0, 0xa075, 0x9b46, + 0xfcae, 0xfcb0, 0xfa51, 0x8d7b, 0x8d7c, 0x9ed6, 0x93ac, 0x9f5b, + 0x93a9, 0xa07c, 0xfcb2, 0x8ac1, 0x9fb4, 0xfcac, 0x9e4c, 0x8fc5, + 0x93ad, 0x9dc3, 0x8da2, 0x9d4a, 0xfcb6, 0x8da3, 0x9e4b, 0x9e4d, + 0x8da4, 0x8afd, 0xfcb5, 0xfcc3, 0x93b2, 0x8da5, 0x93a1, 0x8ac6, + 0x8a5b, 0x894d, 0xfed4, 0x8a78, 0x93ab, 0x8da7, 0x9f45, 0x8a56, + 0xfcbf, 0xfcc0, 0x8ee6, 0x8aa4, 0x8943, 0x93f3, 0xfcab, 0x9ea2, + 0x9dc7, 0xc6d2, 0x8bce, 0xfcc5, 0xfccb, 0x93b3, 0xfcca, 0xfcc9, + 0x8dac, 0xfbc6, 0x8967, 0xfccd, 0x9cf3, 0xfcd0, 0x95bb, 0xfcd3, + 0xfcd4, 0x8dae, 0xfcd7, 0x93db, 0xfe63, 0x93d5, 0xfcda, 0x9b71, + 0xfcdd, 0x8daf, 0xfaf2, 0x93d8, 0xfcdf, 0x93d3, 0xfce1, 0x8e76, + 0xfc62, 0x93d1, 0x8db1, 0x9859, 0xfb52, 0xfb53, 0xfb4d, 0x9cbf, + 0x9b72, 0xfb50, 0x93be, 0x9df1, 0xfceb, 0xa0bb, 0x9b7e, 0x8db3, + 0x9ae8, 0x8edc, 0x9cf9, 0xfa50, 0x98e7, 0xfcf3, 0xfcf2, 0x93e5, + 0x9a59, 0x8db5, 0xfd4d, 0xfd5e, 0x8f7d, 0x9547, 0xfcf6, 0x9250, + 0x8968, 0x8db6, 0xfcfb, 0xa07d, 0x98fc, 0x8969, 0xfe4f, 0x9256, + 0xfac9, 0x93e8, 0xfcf8, 0x9ce3, 0xfda9, 0xfc44, 0x9640, 0x8db8, + 0x9b4a, 0x8fb9, 0xfcfe, 0x896a, 0x8db9, 0x917e, 0x93f4, 0xfb7c, + 0x93e7, 0x97ef, 0xfe4a, 0xfd45, 0x96a5, 0xfee0, 0xfd48, 0xfd47, + 0xfef2, 0xfe6a, 0x8dbd, 0x9ba1, 0x9ab7, 0x8efc, 0x9fa1, 0xfd51, + 0xfaad, 0x8dbe, 0x89a4, 0x9ad9, 0xfd4e, 0x8dc0, 0x97f0, 0x93b4, + 0xfd44, 0x9fa7, 0x8dc2, 0x99b6, 0xfd52, 0x8dc1, 0x8e46, 0xa0d1, + 0x9fca, 0x92cf, 0x9cf4, 0x8dc4, 0xfd41, 0x9b4c, 0xfd57, 0xfcef, + 0x9cde, 0xfd42, 0x986c, 0x97f9, 0x9558, 0x985e, 0xfe7b, 0x94cd, + 0x93ee, 0xfd5a, 0x93f5, 0x93ef, 0x8eea, 0x8f5b, 0x8dc6, 0x8dc8, + 0x8dc7, 0x93f7, 0x8dc9, 0xfbf2, 0x9670, 0x8dcb, 0xfd5c, 0x8f65, + 0x8dcd, 0x9da8, 0x94f9, 0x8dce, 0x93ea, 0xfd5f, 0x93f0, 0x9fb6, + 0x8dcf, 0x9763, 0x8dd0, 0x93f1, 0xfd62, 0xfd65, 0x9fdb, 0x93f8, + 0x8bf7, 0xfd66, 0x8bcf, 0x8dd1, 0x8dd2, 0xfd71, 0xfd6f, 0x8dd3, + 0x9fe7, 0x90bd, 0x9fd0, 0x8bd0, 0xfd72, 0x9cae, 0x8bd1, 0x8adb, + 0xfae4, 0x95ce, 0xfd76, 0xfb62, 0x8dd4, 0xfd78, 0x8ee3, 0x9076, + 0x98c6, 0x8dd5, 0x97d1, 0x9eb6, 0xfac7, 0xa042, 0x9873, 0x9ffc, + 0x8dd7, 0x92fb, 0x8dd8, 0x944f, 0x8dd9, 0x896b, 0x97ce, 0xfaf3, + 0xfdae, 0xfbaf, 0x92b7, 0x8dda, 0x9c5a, 0xfdad, 0x8ddc, 0x9444, + 0x8ddd, 0xa0d6, 0x97d5, 0x944a, 0x944d, 0x97cb, 0x8dde, 0x8ddf, + 0x8de0, 0xfef9, 0xfdc0, 0xfcf9, 0xfb7e, 0x92b3, 0xfdaf, 0x8de1, + 0x95d3, 0x89c1, 0xfd68, 0x9cb7, 0x8de3, 0xfac0, 0x8de5, 0xfa64, + 0x8947, 0x8de4, 0x8de7, 0x8de8, 0xfdc7, 0xfdb0, 0x9445, 0x97d6, + 0xfcc6, 0x9844, 0x8de9, 0x8dea, 0xfe50, 0xfdcc, 0x9da7, 0xfdcd, + 0xfdcf, 0x95d2, 0x8ded, 0xfcba, 0xfdc5, 0xfdd2, 0x9cdc, 0x95cf, + 0x8dee, 0xfdd4, 0x96ec, 0x96eb, 0x90b6, 0xfdc3, 0x98ab, 0x96ee, + 0x8df4, 0xfde0, 0x8df6, 0x8df7, 0x8ffa, 0x97d0, 0x8bd2, 0x8df8, + 0x90d9, 0xfaf0, 0xfde1, 0x8df9, 0xfde3, 0x8dfa, 0xfb63, 0x90a6, + 0x9970, 0x91eb, 0x9770, 0x986f, 0xfde2, 0x98f2, 0x9afc, 0x896c, + 0xfdfd, 0x995e, 0x95bd, 0xfde4, 0x91e6, 0xfde5, 0xfde6, 0xfde7, + 0x9454, 0x99b8, 0x97e9, 0x9346, 0x9863, 0x95bc, 0xfded, 0xfdf7, + 0x9870, 0x96f6, 0x8ea9, 0x9451, 0x8e43, 0x8b5a, 0xfdee, 0xfdf0, + 0xfdf4, 0x9bf5, 0x977e, 0x9bd5, 0x9ac3, 0x97c8, 0xa0db, 0x91d0, + 0x9fe4, 0x8fdd, 0x91e9, 0x98e0, 0x92ca, 0x9857, 0xfdeb, 0x9b49, + 0x9d76, 0x9eaf, 0x9ccc, 0xfdea, 0x8df1, 0xfdfb, 0x8e53, 0xfacf, + 0x96f9, 0x98bf, 0x9e49, 0x9bca, 0xfdfe, 0x92dc, 0xfe41, 0x91cc, + 0x91e2, 0xfe44, 0x8bd3, 0xfe47, 0xfe48, 0x9455, 0xfe4b, 0xfe4c, + 0x8dbf, 0x9e78, 0xfe51, 0x9456, 0x9d61, 0x9457, 0x9966, 0x8bd5, + 0xa069, 0x98b4, 0xa049, 0xa04c, 0x9e65, 0x98b5, 0xfe58, 0x9975, + 0xfe53, 0xa065, 0xfe59, 0x98b7, 0x98b8, 0x98ba, 0x98bb, 0x9fbc, + 0xa04a, 0x9ec7, 0x98ae, 0x92d6, 0xfae1, 0x91d4, 0xfade, 0xfe5b, + 0xfe5e, 0xfbd7, 0xfe5a, 0x94c5, 0xfaca, 0x98c1, 0x975c, 0xfe74, + 0x9773, 0xfa46, 0x9764, 0xfe68, 0x964e, 0x9765, 0x89a1, 0x95fa, + 0x92d4, 0xfe69, 0xfb45, 0x98c8, 0x90ef, 0x98c9, 0x98ca, 0x946d, + 0x94b7, 0xfe6c, 0x946b, 0x92fc, 0x95eb, 0xfe73, 0x976e, 0xfe5f, + 0xfdbd, 0x92d5, 0xfeb9, 0xfe71, 0xfbbb, 0x947a, 0x95fb, 0xfe77, + 0xfe79, 0xfe75, 0x945d, 0xfe7c, 0x9344, 0x8ea6, 0x92d3, 0x94b8, + 0xfc71, 0x975e, 0xfea7, 0x946a, 0x93e3, 0x98cf, 0xa0d9, 0xa0bf, + 0xa04d, 0xa0b8, 0xa0ce, 0xa0b7, 0xfea9, 0x89c3, 0xfeab, 0x9df4, + 0x896d, 0x9c7b, 0x98d2, 0x9fa9, 0xfeb2, 0xfeb1, 0x97d9, 0xa0c4, + 0x9476, 0x9978, 0xfeb3, 0x98d3, 0xfeb4, 0x98d4, 0x9fb9, 0x9471, + 0x98d5, 0xfeb8, 0xc6d4, 0xfeba, 0x9e5c, 0xfebb, 0xa044, 0x98d7, + 0x98d8, 0xfebc, 0x9ffe, 0xfebd, 0x9ddd, 0x9ee1, 0x98da, 0x9ddf, + 0xfebf, 0xfebe, 0x9eeb, 0x9e59, 0xa05c, 0xfec0, 0x9477, 0x98dc, + 0xfec1, 0x98de, 0xfec3, 0xfec8, 0xfec9, 0xfeca, 0xfecb, 0x9fc2, + 0x98c4, 0x94b0, 0x94b1, 0xfed1, 0xa0c1, 0xfed2, 0xa0cd, 0xfed3, + 0x98e5, 0xfed6, 0x91e4, 0x8fc7, 0x94ae, 0x8a4f, 0x94b2, 0x8fd4, + 0x98ea, 0xfed8, 0x9de0, 0x98ee, 0x95c4, 0xfce8, 0x98ef, 0xfad8, + 0xfedc, 0xa0ae, 0x9d4c, 0x98f1, 0x98f3, 0x94c1, 0x98f5, 0xfa4f, + 0x96e2, 0x9450, 0x96a2, 0x98f6, 0x96e5, 0x98f7, 0xa046, 0x96e3, + 0x98f8, 0x9ee4, 0xf9d6, 0x94c3, 0x94c2, 0xfee1, 0xfee9, 0x96e4, + 0x89ac, 0x96db, 0xfee2, 0x94c4, 0xfee3, 0xfee7, 0x9ffb, 0x93c9, + 0x94e8, 0xfb56, 0x90c5, 0xa0a8, 0xfee5, 0x98fd, 0x98fb, 0xfee8, + 0x8ebf, 0x8bd8, 0xfef7, 0x8f68, 0x94c6, 0x9dea, 0xfc69, 0x9cda, + 0xfef3, 0x9c72, 0xfef0, 0x89c9, 0x9941, 0x9942, 0xfef5, 0x91d7, + 0x94cc, 0xfef8, 0x97a8, 0xfefc, 0xfdbf, 0xfefe, 0x96d1, 0x94d5, + 0x94d0, 0x9944, 0xa0b3, 0x94cf, 0x9ffa, 0x91e5, 0x9c6a, 0x8e49, + 0x8e4c, 0x8e4d, 0x9a73, 0x9947, 0x8e50, 0x8e4f, 0x9949, 0x8e51, + 0x8e52, 0x9ab2, 0x89a5, 0x994c, 0x9ff8, 0x8e56, 0x994d, 0x91ca, + 0x8e57, 0x94e1, 0x9047, 0x8fd8, 0x8e58, 0x94eb, 0x8e5c, 0x9553, + 0x9fe5, 0x9f56, 0x954f, 0x8e5e, 0x996a, 0x9c64, 0x9cd9, 0x8e5d, + 0x9950, 0x9951, 0x8e62, 0x9952, 0x8e68, 0x8e61, 0x9f59, 0x8bb3, + 0x9f5d, 0x8e66, 0x8e6e, 0x9f64, 0x9953, 0xfab8, 0x9954, 0x8e70, + 0x9f61, 0x8e72, 0xa06b, 0x9f40, 0x94ed, 0x94ee, 0x9fbd, 0x8e7b, + 0x9957, 0x94f7, 0x9f5f, 0x8e73, 0x9f62, 0x94f6, 0x9958, 0x8e75, + 0xf9db, 0x9072, 0x94f8, 0x995a, 0xa0b0, 0x8e79, 0x8e78, 0x94f3, + 0x98af, 0xa0b2, 0x8e7a, 0x995c, 0x8e7c, 0x8e7d, 0x8bd9, 0x89a2, + 0x9ed7, 0xa0b6, 0x9e42, 0x8ea4, 0x8ea7, 0x9542, 0x987d, 0x9755, + 0x8ea8, 0x8eaa, 0x89a3, 0x9960, 0x9962, 0x94fc, 0x9961, 0x94fa, + 0x8eae, 0x8eb2, 0x8eb0, 0x9963, 0x97aa, 0x94fb, 0x8ebb, 0x9876, + 0x8ea1, 0x8eb7, 0x9da6, 0x9eb0, 0x8eb8, 0x9d70, 0x896e, 0x896f, + 0x8970, 0x8971, 0x8972, 0x8973, 0x8974, 0x8975, 0x8ebc, 0x8ebd, + 0x8ebe, 0x9dd1, 0x94fd, 0x8bd7, 0x8bda, 0xa0e2, 0x9fe9, 0xfda8, + 0x8ae7, 0x8ec2, 0x8ec4, 0x9964, 0x9965, 0x954e, 0x98b3, 0x8ecb, + 0x8bdf, 0x8ece, 0x8ecf, 0x9968, 0x9969, 0x996b, 0x8ed1, 0x996c, + 0x8ed4, 0x8ed5, 0x996d, 0xa0be, 0x8ed6, 0xa0bc, 0xa0b5, 0xa0b4, + 0x8be0, 0x89b5, 0x8edd, 0x9e5d, 0x9971, 0x89ae, 0x9de8, 0x9565, + 0x9972, 0x8b5c, 0x89b1, 0xa0c0, 0x8edf, 0x9566, 0x9974, 0x9976, + 0x9977, 0x9979, 0x9dda, 0x8ee0, 0x935c, 0x9de6, 0x8b5f, 0x9563, + 0x9567, 0x9de3, 0x997c, 0x997d, 0x997e, 0x8b5b, 0x99a3, 0x99a4, + 0x99a6, 0x99a8, 0x8abe, 0x9e61, 0x99aa, 0xa0c8, 0x99ab, 0xfec4, + 0x98c2, 0x8ee8, 0xa0ba, 0xfd77, 0x8eee, 0x9ebf, 0x89c2, 0x99ac, + 0x956b, 0x956c, 0x99af, 0x994a, 0x8976, 0x8f48, 0xfbee, 0x99ae, + 0x8efb, 0x8b52, 0x99b0, 0x8977, 0x8f41, 0x99b1, 0x8f49, 0xfa4d, + 0x9de4, 0xfbe9, 0x9b54, 0x99b2, 0x9e68, 0x8f4a, 0x8f42, 0x8f51, + 0x9846, 0x99b4, 0x8ef5, 0xfd55, 0x9ccd, 0x8978, 0x8f53, 0x8f6f, + 0x8e63, 0x8f56, 0xfe76, 0x9fc6, 0xfaac, 0x8f58, 0x9848, 0x99b7, + 0x9665, 0xfa6c, 0x9de7, 0x9e62, 0x96cc, 0x8e67, 0xfc75, 0x987e, + 0xfdb9, 0x97fc, 0x98f9, 0x8f66, 0x956e, 0x9245, 0x8f60, 0x9ed1, + 0xfecd, 0x99b9, 0x8f62, 0x974c, 0x91c7, 0x955f, 0x99bb, 0x8e6d, + 0x8f71, 0x94cb, 0x95b1, 0x9af2, 0x96c3, 0x99bd, 0xa0cf, 0x8f6d, + 0x99be, 0x8ef4, 0x8f72, 0x95e4, 0x99bf, 0x9242, 0xfba5, 0x99c0, + 0xfdb4, 0x8f77, 0x99c1, 0xfab9, 0x8f40, 0xfa44, 0x99c2, 0x8f5c, + 0x99c4, 0x99c5, 0x8f7b, 0x8fa3, 0x99c6, 0x96cd, 0x96c7, 0x8fa5, + 0xfabb, 0x9570, 0x9368, 0x8f7e, 0x8faa, 0xa050, 0x90d3, 0x9556, + 0x8fb8, 0x99c8, 0x8faf, 0x99c9, 0x9579, 0x9f49, 0x99ca, 0x99cb, + 0x9dd5, 0x8fb0, 0xfa7a, 0x9e5f, 0x99cd, 0xa0c9, 0x9adb, 0xa0c6, + 0x8fb4, 0xa0d7, 0xa0c7, 0xa043, 0x8fb5, 0x8fb2, 0xa061, 0x9e5e, + 0x8fb6, 0x9fe8, 0x9cb2, 0x957c, 0x9fc7, 0x8fbb, 0x8fbc, 0x8fec, + 0x8fc0, 0x936a, 0x8be4, 0x9c7c, 0x95a1, 0xfeec, 0x95a3, 0x8fc1, + 0xa052, 0x99d0, 0x8fc3, 0x8fc4, 0x95a4, 0x8fc6, 0x9e60, 0xf9d8, + 0x95a5, 0x9cb3, 0x99d1, 0xfef1, 0x99d2, 0x9cc2, 0x99d3, 0x95a7, + 0x95a9, 0x95a6, 0x9c5d, 0x98e2, 0x8fc9, 0xa0c2, 0x8fca, 0x99d4, + 0xa0b9, 0x9b58, 0x8fcd, 0xa0d4, 0x8fce, 0x8be5, 0x8979, 0x8fd0, + 0x95b6, 0x99d6, 0x95e5, 0x99d7, 0x95b5, 0xa0ca, 0x9ffd, 0xa058, + 0x8fd6, 0x99d8, 0x8fd3, 0x8fe5, 0x8fe9, 0x99d9, 0x927c, 0x9c45, + 0x8fde, 0x8fdf, 0xa04b, 0x8fe2, 0xa0cc, 0x8fe3, 0x8fe4, 0x9bc4, + 0x9bfc, 0x964c, 0x9af6, 0x8fe7, 0x8fe8, 0x8be7, 0x897a, 0x897b, + 0x99da, 0x8fed, 0x95c0, 0xa0cb, 0x9e48, 0x99db, 0x8ff3, 0x8ff9, + 0x95c1, 0xa04e, 0x99dc, 0xa064, 0x8ff7, 0x89b0, 0xa048, 0x8ffb, + 0x8ff6, 0x9ddc, 0x99dd, 0x8be8, 0x92c1, 0x9fd6, 0xa0d2, 0x9040, + 0x8ac4, 0x99e0, 0x9ff0, 0x9ff3, 0x9dbf, 0x9ff6, 0x95c8, 0x9e5a, + 0x99e3, 0x8a4a, 0x9ff1, 0x8aa7, 0x99e6, 0x9ff7, 0x9fed, 0x8a5c, + 0x9dae, 0x95c9, 0x9048, 0x99e8, 0x9049, 0x90b1, 0x904a, 0x99ea, + 0x9bd1, 0x99eb, 0x99ec, 0x99ed, 0x99ee, 0x904c, 0x904d, 0x95cb, + 0x97e2, 0x95cc, 0x9f78, 0x897c, 0x897d, 0x897e, 0x995d, 0x9b5a, + 0x9050, 0x9054, 0xc6d6, 0x9aa8, 0x99ef, 0xfeeb, 0x9da3, 0x9da1, + 0x9943, 0x9945, 0x9d7d, 0x99f0, 0x99f1, 0x99f2, 0x9d60, 0xa0a3, + 0x905b, 0x9edb, 0x9d79, 0x99f3, 0x9062, 0x9f55, 0x9bf9, 0x9065, + 0x96e0, 0x98be, 0x9068, 0x906c, 0x95d8, 0x906a, 0x9fb2, 0x9fae, + 0x9fb0, 0x89ad, 0x906e, 0x9e71, 0x9e4a, 0x9fdc, 0x89ab, 0x9fb8, + 0x9070, 0x8b63, 0x95dc, 0x9071, 0xfc5e, 0x8949, 0x965b, 0x94a6, + 0x8fd5, 0x9e73, 0x9075, 0x99f7, 0x99f9, 0x9663, 0x95b9, 0x94d4, + 0xfcfa, 0x9077, 0x90ab, 0x9d4d, 0x99fa, 0x92e3, 0x97bb, 0x9078, + 0x99fb, 0x97e0, 0x96dc, 0x9ca8, 0x9772, 0x9440, 0x92f2, 0x99fd, + 0x99fc, 0xf9d7, 0x964a, 0x96d8, 0x99fe, 0x904b, 0xfa41, 0x9a40, + 0x975b, 0x9a41, 0x91dd, 0x93fc, 0x9a42, 0x9a43, 0x9659, 0x9a44, + 0x9051, 0x94bf, 0x90a2, 0x9cab, 0x9776, 0xfc55, 0xfe45, 0x94a8, + 0x9a45, 0xfa4b, 0x9de1, 0x96d9, 0x9774, 0xfdf5, 0x92e5, 0x9645, + 0x91da, 0x90a3, 0xa05f, 0x90af, 0x97bf, 0x914c, 0x967a, 0x91de, + 0x9a46, 0xfeb0, 0x9779, 0x946c, 0x9858, 0x9266, 0x93fb, 0x9a47, + 0x9749, 0x9748, 0x934a, 0x9ce2, 0x9264, 0x91df, 0xfb79, 0x96d7, + 0x9343, 0xfdcb, 0xfe7a, 0x91db, 0x97af, 0x95dd, 0x9348, 0x9a4b, + 0xfc45, 0x9a4d, 0x91bc, 0x90e2, 0x90b4, 0x95e1, 0x9a4e, 0x9a4f, + 0xfe40, 0xfe43, 0x96dd, 0x9a51, 0x96a7, 0x90b0, 0x9c4e, 0x9443, + 0x8eba, 0x9a52, 0xfcc1, 0x8be9, 0x9caf, 0x8bfd, 0x9abc, 0x9ab8, + 0x9aae, 0x9aa7, 0x9a53, 0x9d74, 0x8bea, 0x8beb, 0x90b2, 0x95e9, + 0x95e8, 0x95e6, 0x90b5, 0x9a54, 0x90b3, 0x95e7, 0x8b50, 0x8bec, + 0x9a56, 0x8bfb, 0x9a57, 0xa0aa, 0x9fa6, 0x99cc, 0x9c59, 0x99b5, + 0x90be, 0x9faf, 0x95f2, 0x90bf, 0x90c1, 0xfee4, 0x90c4, 0x90c7, + 0x92e4, 0x9f52, 0x90db, 0xa066, 0x90d2, 0x90d4, 0x9a5b, 0x95fd, + 0x8bc4, 0x90de, 0x9ce4, 0x90e1, 0x9e46, 0x9651, 0xfb58, 0x90e6, + 0x9650, 0x90e7, 0x90e8, 0x9a5d, 0x9f7a, 0x9b5c, 0x9f7c, 0xfc52, + 0x90e9, 0x90ea, 0x9a5e, 0x9f76, 0x90eb, 0x90ec, 0x8bee, 0x90ee, + 0x91c6, 0x90f2, 0xfcbc, 0x8a74, 0x9657, 0x9cef, 0x9fdf, 0x90f7, + 0x90f6, 0x9b5e, 0x90f8, 0x90f9, 0xfa6a, 0x8bef, 0x9fe0, 0x9142, + 0x9a62, 0x9569, 0x9144, 0x9143, 0x9141, 0x8bf0, 0x9660, 0x8bf1, + 0x99f6, 0x9149, 0x914a, 0x914b, 0x9a64, 0x8abf, 0x9a66, 0x9a67, + 0x9a69, 0x9a6a, 0x9652, 0x914d, 0x9666, 0x9f7b, 0x9a6b, 0xa06c, + 0x9667, 0x9a6c, 0x9a6d, 0x8bf2, 0x966a, 0xfcea, 0x966c, 0x91c4, + 0x9677, 0x99f4, 0x9a6f, 0x9fab, 0x8ec1, 0x9555, 0x9152, 0x9153, + 0x9155, 0x955d, 0x9671, 0x9c6d, 0x9673, 0x9154, 0x9a71, 0x9156, + 0x966d, 0x9557, 0x89c6, 0x89c7, 0x8a6a, 0x8b57, 0x9fe1, 0x9b5f, + 0xa05d, 0x915b, 0x915c, 0x915e, 0x9f5c, 0x9f57, 0x9f65, 0x9a72, + 0x9160, 0x9f5e, 0x9161, 0x9164, 0x9f41, 0x9169, 0x9168, 0x9a74, + 0x96b2, 0x9a75, 0xfda5, 0x9ee9, 0x8bba, 0x916d, 0xa060, 0x9fde, + 0x9fc3, 0x96b5, 0xa067, 0x96b3, 0x9a76, 0x95d5, 0x9eca, 0x9a77, + 0x9a78, 0x9170, 0x916f, 0x9fa3, 0x9171, 0x96b1, 0x9f63, 0x9f67, + 0x8bb9, 0x9a7a, 0x8b56, 0x9ada, 0x96b0, 0x9a7e, 0x9dde, 0x96ad, + 0x96ae, 0x9ea1, 0x9e50, 0x96af, 0x8bf4, 0x9fa4, 0x96bd, 0x96f4, + 0x96b8, 0xfaa1, 0x91a7, 0xa05e, 0x9a7d, 0x8948, 0x9eb1, 0x9ddb, + 0x95bf, 0x8a73, 0x9efe, 0x917a, 0x917b, 0x9aa3, 0x96c2, 0x9f77, + 0x9aa4, 0x9aa5, 0x91a1, 0x89b8, 0x9173, 0x9aa6, 0x89bd, 0x89b9, + 0x917d, 0x96bb, 0x9ff2, 0x8bf5, 0x9aa9, 0x9f54, 0x9fe3, 0x9eed, + 0x91aa, 0x91ab, 0xa070, 0x9f6d, 0x91ac, 0x91ad, 0xa0fd, 0x9fe2, + 0x91af, 0x9e41, 0x9aaa, 0x91b0, 0x9aab, 0x9aac, 0x9a4a, 0x91b2, + 0x8bf6, 0x9aad, 0x89b6, 0x9aaf, 0x9ab0, 0x9ab1, 0x9aa1, 0x91b9, + 0x91ba, 0x91be, 0xa041, 0x8bb7, 0x91c0, 0x9ab3, 0x91c3, 0xa0fc, + 0x9fee, 0x9f69, 0x91c8, 0x91c9, 0x8de6, 0x91cb, 0x89c8, 0x8daa, + 0x9fdd, 0xc8a1, 0xc8a3, 0x8bf8, 0xc8d0, 0xc8cf, 0xc6e4, 0xc6e5, + 0xc8cd, 0xc8ce, 0xf9fe, 0x9c71, 0x9375, 0x9376, 0x9548, 0x8ec6, + 0x8bc5, 0x8bfa, 0xc87c, 0x9ab4, 0x884e, 0x884b, 0xc87a, 0x8848, + 0x8847, 0xa0f6, 0x8845, 0x8853, 0xfcad, 0x8aad, 0x9272, 0xfc47, + 0x94df, 0x9fd1, 0xfbcb, 0x927d, 0x98a4, 0x94e7, 0x90cb, 0x927b, + 0x94d8, 0xfc5f, 0xfa54, 0x9ab5, 0x96da, 0x9279, 0xfa74, 0x9275, + 0x8dfb, 0x8a49, 0x92df, 0x9b7c, 0xfa63, 0xfa60, 0x926d, 0xfa62, + 0x9ab6, 0x976b, 0xfd6a, 0xfd54, 0x9273, 0x97d8, 0x9fbb, 0x9342, + 0x9276, 0xfa65, 0x926c, 0xfa6e, 0x9ee0, 0x92c0, 0x92bf, 0x92be, + 0x9aba, 0x8ab3, 0x9775, 0xfa40, 0xfa76, 0xfbd0, 0xfa7b, 0xfe6d, + 0x9bb3, 0x89cc, 0x9abe, 0xfa42, 0x92bc, 0x945c, 0x9bb5, 0x9abf, + 0x98a7, 0x97a4, 0x90fd, 0xfc7b, 0x9ac0, 0x92c3, 0x8aaa, 0x9bd0, + 0x9550, 0x92c6, 0x98a6, 0x9546, 0xfd63, 0xfac2, 0x9ec3, 0x89b2, + 0x9c66, 0x9053, 0x97c1, 0x9ac4, 0x9ac5, 0x8eef, 0xfae9, 0x9262, + 0x8af7, 0x9ac6, 0x92e1, 0x9ac9, 0xfac6, 0x97a5, 0x9acb, 0xfa72, + 0x8a5e, 0x94e0, 0x92cc, 0x8ae5, 0xfe5c, 0x9acc, 0x9df9, 0x8a43, + 0x8aa6, 0x9acd, 0x9ace, 0xfaee, 0x9bcc, 0x9acf, 0x9ad1, 0x9dfa, + 0x9d7c, 0x9ad3, 0x97a6, 0x995f, 0xfbf6, 0x9fc5, 0x8a59, 0x8b6b, + 0x9ad4, 0x9ad5, 0x97a2, 0x8a44, 0x9f4a, 0x90a1, 0xfda4, 0x8a64, + 0x8af2, 0x8af8, 0x9dd8, 0x94d6, 0xfafe, 0xfba7, 0x9ad6, 0x9f4d, + 0xfaf6, 0x8a57, 0x8b43, 0x8b44, 0x8ab6, 0x8ac0, 0x9e54, 0x9ad7, + 0x9ad8, 0x9adc, 0x8aca, 0x9ea8, 0x9263, 0x9add, 0x8b65, 0x8b6f, + 0x8b7e, 0x8f43, 0x92d0, 0x8af4, 0x9dbe, 0x9ae1, 0xfcde, 0x9dfd, + 0x8b66, 0x8b70, 0x8b75, 0x8ae4, 0x8ba4, 0x8aed, 0x8a5d, 0x8b48, + 0x9ded, 0x9e40, 0x8aef, 0x8af6, 0x9e76, 0x9ee3, 0x9ade, 0x8dfe, + 0xfafc, 0x9cb1, 0x9e77, 0x8b64, 0x8b67, 0x974b, 0x9653, 0x9ae0, + 0x8b4a, 0x8af1, 0x8ad7, 0xa0ab, 0x8ab5, 0x8a5f, 0x8aee, 0x9adf, + 0x8afe, 0x8a58, 0x8ba3, 0x8ba7, 0x9ae3, 0x9261, 0x9dd7, 0x9e7d, + 0x9ea7, 0x9eab, 0x9042, 0x8b79, 0x8b7a, 0x9ae6, 0x9ae5, 0x8a7e, + 0x9e44, 0x9ae7, 0x8a7c, 0x8b71, 0x9ae9, 0x9aea, 0x9aeb, 0x8abd, + 0xfb4e, 0x9aed, 0x8af9, 0x9e63, 0x8b49, 0x8ace, 0x8b6e, 0x8ae8, + 0x9aee, 0x92ce, 0x8a5a, 0x8b7b, 0x8b7c, 0x9aef, 0x9af0, 0x8afa, + 0x8941, 0x8b72, 0x8af3, 0x8ba8, 0x9eae, 0x9e72, 0xfb73, 0xfb5f, + 0x90ba, 0x91fe, 0x9ef6, 0x97ed, 0x9af3, 0xa0ee, 0x967c, 0x9345, + 0x986e, 0xfa56, 0x9af5, 0xfc4b, 0x9af4, 0xfede, 0xfcb7, 0x97f1, + 0x97c7, 0x9ccb, 0x9240, 0x9ce8, 0x91fd, 0x974e, 0xfb68, 0x976c, + 0x97e8, 0xfb6a, 0x8b74, 0x8ee7, 0xfdc8, 0x9241, 0x96a1, 0x8ef3, + 0x9af7, 0x8fa6, 0xfad6, 0x9cc7, 0xfad7, 0x9af8, 0xfba1, 0x8ec5, + 0xfba4, 0xfbc2, 0x9ac1, 0x91fa, 0xfedb, 0x97ab, 0x9147, 0xfbb1, + 0x8fea, 0x94d2, 0xfe61, 0xface, 0x92ed, 0x91f3, 0x93c6, 0x935a, + 0xfafb, 0x92ef, 0xfac8, 0x9847, 0x9366, 0x9855, 0x96e6, 0x9f43, + 0x9faa, 0x94da, 0x92ee, 0xfcaf, 0xfbfb, 0x8ef9, 0x91f6, 0x9364, + 0x94f5, 0x9cb6, 0xfbad, 0x984e, 0x8f44, 0x96fd, 0x9af9, 0x9afa, + 0x9769, 0x95d4, 0x984b, 0xfbaa, 0x987c, 0x91ea, 0x9daf, 0x9dc5, + 0x91f1, 0x8eb1, 0x97a9, 0xfbac, 0xfcb8, 0x9cb9, 0xfbb0, 0xfcd2, + 0x93cb, 0x9afd, 0x91f4, 0x8bac, 0xa055, 0x9574, 0x95be, 0x97ad, + 0x8ee9, 0x92f8, 0x97be, 0x916c, 0x94aa, 0xfc63, 0x9dc6, 0x97b5, + 0x92b8, 0x91ef, 0xfea6, 0x9760, 0x9358, 0x9576, 0x8fac, 0x91ec, + 0x97b4, 0x91f7, 0x974a, 0xfb49, 0x9578, 0x93bc, 0x91d6, 0x9355, + 0x9356, 0x9851, 0x8ff8, 0xfbc0, 0x93f2, 0x90d0, 0x9c44, 0x9255, + 0x9363, 0x91a5, 0xa0ed, 0xfd6b, 0x9afe, 0x9351, 0xfa78, 0xfea8, + 0x9350, 0xfa4c, 0x92f7, 0x9b40, 0xfbce, 0x9b41, 0xfead, 0xfbd5, + 0x8bc2, 0x9a7c, 0x9b42, 0x9b43, 0x9e79, 0xfbd9, 0x9b44, 0xa0a7, + 0x9bf3, 0x935e, 0x89cb, 0x9f53, 0x93d7, 0xfbe1, 0xfed0, 0xfbe2, + 0xfce3, 0x9074, 0xfbe6, 0x9bb7, 0x9b45, 0x9b47, 0x9f50, 0x9b48, + 0xfc5b, 0x98a9, 0x9cfd, 0x884c, 0x9b4b, 0xfbec, 0x9ba8, 0x8ad5, + 0xfa73, 0xfd59, 0x91a2, 0xfbed, 0x9ca9, 0x8aa8, 0x9bc3, 0x8ae1, + 0x9b4e, 0x95d0, 0x905f, 0x97ee, 0xfc4e, 0x9b4f, 0x9b50, 0x9ec6, + 0xfc50, 0xfd73, 0xfda7, 0x9da2, 0xfa58, 0xfa5e, 0xa059, 0xfa75, + 0xfbbe, 0x9ca2, 0x9370, 0x9371, 0x9377, 0xfeef, 0x936d, 0xfc5d, + 0x90b8, 0x8afc, 0xfb41, 0x9e6b, 0x94e3, 0x8ee2, 0x8ed7, 0x9c4d, + 0x96a3, 0x9b51, 0x8ac3, 0x96aa, 0xfc68, 0x8b6d, 0xfd67, 0x8ae9, + 0xfca1, 0x936c, 0x9b52, 0xfe70, 0xfca8, 0xfce9, 0x9cb4, 0x8aea, + 0x9b53, 0x9b55, 0x96ab, 0xfca7, 0x9b56, 0x8abc, 0x8acb, 0x9b57, + 0x89cd, 0x9b59, 0x9b5b, 0x93a5, 0x9b5d, 0x9e4f, 0x93a3, 0x8a7b, + 0x8b42, 0x9750, 0x8fb3, 0x8a50, 0x9b60, 0x8b45, 0x8b46, 0x9dfe, + 0x9b62, 0x937b, 0x93b1, 0x8a60, 0x8ad8, 0x9b63, 0x8a69, 0x8a47, + 0x8acc, 0x937c, 0x9b65, 0x9b66, 0x8a72, 0x8a7a, 0x93af, 0x8ab0, + 0x9b68, 0x9ea3, 0xfaec, 0x8b77, 0x9b67, 0x8b59, 0xfcb1, 0xfcbb, + 0x9b69, 0x93a8, 0x8ae0, 0x9e51, 0x8f5f, 0x9b6a, 0x9b6b, 0x97ec, + 0x9b6c, 0xfe4e, 0xfdc2, 0x9b6d, 0x9167, 0xfccc, 0x93b6, 0x90e4, + 0x90e5, 0x9ef2, 0x93ca, 0x8bbc, 0x8f46, 0x93cf, 0xfcdb, 0xfcdc, + 0x93c0, 0xfce6, 0x96e7, 0xfcd8, 0xfcd9, 0xfda6, 0x93ce, 0x95f1, + 0x9ce9, 0xfce4, 0x94af, 0xfa77, 0x93cc, 0x905a, 0x93bf, 0xfb51, + 0x93b9, 0xfed7, 0x93b7, 0x93d9, 0x93bb, 0x93da, 0x98a3, 0x90d1, + 0x9b6e, 0xfa70, 0x9beb, 0x9b6f, 0xfcfc, 0x8b40, 0xa07b, 0x97f7, + 0x93e2, 0xfcd6, 0x9559, 0x93a6, 0xfd40, 0x935f, 0x97f2, 0x9c76, + 0x8ef8, 0x8f47, 0x9b74, 0x92b4, 0x91ed, 0x96d2, 0xfd46, 0x8f4f, + 0x9549, 0x9b75, 0xfa5c, 0x9b79, 0xfd4b, 0x96d3, 0xfd58, 0x945f, + 0xa0f5, 0x9243, 0x97fa, 0x9dd9, 0x97f4, 0x924d, 0xfd5b, 0x9b7a, + 0x9ed5, 0xfaae, 0x9cc9, 0x9258, 0x8ec8, 0x94b4, 0x93e1, 0x93df, + 0xfcf0, 0x93ec, 0x97f6, 0x96cf, 0x93de, 0x8acf, 0x9ba2, 0xfd69, + 0x9352, 0x98a2, 0xfd6e, 0xfa7c, 0x93fa, 0x907c, 0x8f67, 0x9db7, + 0xa0e9, 0xfa4e, 0xfda1, 0x9e74, 0x9fbf, 0x9ecb, 0x9bb9, 0x9dd4, + 0x97b9, 0x8ef1, 0x957b, 0x9ed2, 0x9753, 0x96a4, 0x8fbe, 0x94d9, + 0x9058, 0xfd79, 0xfd7b, 0x8eda, 0x8efa, 0x9ba5, 0x9ed9, 0x97d4, + 0x90bb, 0xfdbc, 0xfdc6, 0x9248, 0x92b5, 0x9dc1, 0x92b9, 0x92a6, + 0x8f4b, 0x9ba6, 0x92b6, 0x8e40, 0x9ed8, 0x945e, 0x985f, 0x94ce, + 0x924a, 0xfd70, 0x9467, 0x8dec, 0x9bd8, 0x9448, 0xfac1, 0x9cf7, + 0xfdbe, 0x8fda, 0xfdd9, 0xfc7e, 0x93f9, 0xfa43, 0xfaeb, 0xfac3, + 0x97d3, 0x95f9, 0x9c48, 0xfdd8, 0xa0d8, 0xfdd7, 0xfb4a, 0x9baf, + 0x944b, 0xfdc9, 0x8eac, 0xfdb2, 0x925a, 0xfcbd, 0x92d9, 0xfdd5, + 0x92dd, 0x9259, 0x96ba, 0x925b, 0x9bab, 0xfdda, 0xfdde, 0xfdd3, + 0xfdd6, 0xfddc, 0xfddd, 0x90fe, 0xfea1, 0x8bad, 0x9cd8, 0x9e6d, + 0xfd7c, 0xfb61, 0x96f8, 0x96f0, 0xfcf4, 0xfe60, 0x9852, 0x964f, + 0x916e, 0x986d, 0x9864, 0x9453, 0xfdec, 0xfb78, 0x95ba, 0x985d, + 0x92f9, 0x985a, 0xfdf6, 0x93d0, 0x9862, 0x9bad, 0x974f, 0x9bae, + 0x9452, 0x9bb0, 0x91d2, 0x97ea, 0xfb6b, 0x91b1, 0xfdf3, 0x92cb, + 0x9bb1, 0xfcec, 0x986b, 0x9751, 0x9871, 0x95ef, 0x9ef3, 0x91e8, + 0x9bba, 0xfb4c, 0x926a, 0xfdf8, 0x9861, 0x91e7, 0x93ed, 0x9744, + 0x91e1, 0xfbf5, 0x9869, 0x8a62, 0x9bbb, 0x9c55, 0x8e77, 0x8ab2, + 0x9ebc, 0x93e6, 0x93a2, 0x9bbd, 0x94b3, 0x937d, 0x9e66, 0x9459, + 0x9bbf, 0x9458, 0x9ea5, 0x9bc7, 0xfe54, 0x8e74, 0x8bd6, 0x94b6, + 0xfd74, 0x98c0, 0x94a5, 0x9bc8, 0x95ed, 0xfd7e, 0xfbeb, 0xfd7d, + 0x976f, 0x9461, 0x9fc1, 0x95d7, 0xfa52, 0x9c58, 0x9f68, 0x9be7, + 0xfcce, 0x96e8, 0xfa49, 0x97a1, 0x954d, 0x9ef8, 0xfe49, 0x91ce, + 0x9771, 0xfdb1, 0xfc6e, 0x9cf2, 0x93b8, 0x9043, 0x9759, 0x94d7, + 0xfe66, 0x947d, 0xfc6f, 0x9246, 0xfa6d, 0x8ef7, 0xfbb7, 0x947c, + 0x92cd, 0x97b2, 0xfe65, 0x967e, 0x9758, 0x9b77, 0x91cf, 0x94a4, + 0x9cad, 0x8bab, 0x96d5, 0xfcb3, 0x93ae, 0x976d, 0x9446, 0x95f7, + 0x9c46, 0x955b, 0x91d1, 0x94f4, 0xfe67, 0x92a5, 0xfedf, 0x9bc9, + 0xfced, 0xfdfa, 0xfcc8, 0xfe62, 0x91fc, 0xfe6b, 0xfdf9, 0xfcc7, + 0x914e, 0x9cb8, 0x9767, 0x95ee, 0x9bb2, 0x9460, 0x94a2, 0x9875, + 0x97ac, 0x91d3, 0x987b, 0x8eeb, 0x976a, 0x965e, 0x97eb, 0x9ff9, + 0x95f8, 0xfea2, 0x8fe6, 0xfe7e, 0x9da4, 0x9768, 0x8eec, 0x94bd, + 0x945b, 0x9cf6, 0xfaa7, 0x9bd9, 0xfa5d, 0x9656, 0x9762, 0x94ba, + 0xa04f, 0x92d8, 0x9bcb, 0x94bb, 0x9d5f, 0x90cf, 0x9465, 0x9f4c, + 0x90d8, 0x9ebe, 0xfb6d, 0x95ca, 0x9dc2, 0x97f8, 0x8ffc, 0x9473, + 0x9474, 0xfeb7, 0x8a4b, 0x8a55, 0x8b69, 0x8adc, 0x8b76, 0x9bce, + 0x8a68, 0xa0f8, 0x98df, 0xfeb5, 0x9bcf, 0x96fb, 0x9bfb, 0x9ece, + 0x8ee5, 0x9e7b, 0x9bd2, 0x8aa5, 0xfece, 0x8a45, 0x9dfc, 0xfecf, + 0x8ba5, 0x8aec, 0xfce0, 0x94ad, 0xfed5, 0x94ac, 0xfc5a, 0x9bd6, + 0x8a6f, 0x8ba9, 0x8e5f, 0x9dcb, 0xfce7, 0x9bd7, 0x93c8, 0x91f0, + 0x8fe0, 0x9bdb, 0x90ed, 0x9bdc, 0xa0ec, 0x98fa, 0x9be0, 0x93c7, + 0x9249, 0x96e1, 0x9be2, 0x9be4, 0x8fe1, 0x9be5, 0x94c0, 0x93c3, + 0x93c5, 0x9079, 0x977b, 0x907e, 0xfee6, 0xfe46, 0x9db8, 0x9270, + 0x95a8, 0x94c8, 0x98b9, 0x9140, 0xfcbe, 0x9157, 0x8bb2, 0xfadf, + 0x9be6, 0x9643, 0x8e44, 0x9c4f, 0xfef4, 0x9be8, 0x93dc, 0x966f, + 0x8e4a, 0x9bed, 0x92f6, 0x9db9, 0x8e4e, 0xfbcf, 0x9ec2, 0x94e5, + 0x9bf0, 0x94e4, 0x9551, 0x8bbb, 0x9bf1, 0x94f0, 0x8e64, 0x94ea, + 0x8f61, 0x9b64, 0x8e5b, 0x9bf2, 0x9fbe, 0x9dc9, 0x8e6c, 0x8f73, + 0x8f75, 0x8e71, 0x8e60, 0x8e6a, 0x9552, 0x9554, 0x8ad4, 0x9dbb, + 0x9543, 0x92fe, 0x94f2, 0x94f1, 0xa0ea, 0x9dd2, 0xa0b1, 0x91f8, + 0x9462, 0x9ba4, 0x8ead, 0x9ead, 0x96d0, 0xfeee, 0x8ab4, 0x9757, + 0x8a77, 0x9bf7, 0x8eb5, 0xa06d, 0x8eb6, 0x9756, 0x9540, 0xa0f3, + 0x94be, 0x9bfa, 0xfddf, 0x9dbc, 0x94fe, 0x8bdb, 0xa0fe, 0x8ec0, + 0x9f47, 0x8bde, 0xa0fb, 0x8ec3, 0x9649, 0xfec2, 0x954c, 0x9bfd, + 0x90cc, 0x9c60, 0x954b, 0x9bfe, 0x9c70, 0x9c43, 0x9c47, 0x8ecc, + 0x8e54, 0x8ee4, 0x9c49, 0x8b5e, 0x955e, 0x955c, 0x9c4b, 0x8be1, + 0x8ed9, 0x9db4, 0x925f, 0x9c4c, 0x8aa1, 0x8edb, 0x9c56, 0x8aa2, + 0x9754, 0x9c5e, 0x9ed4, 0x9568, 0xa0c3, 0x8ae6, 0xa0f7, 0x9c61, + 0x9c5f, 0xfc4d, 0x9e5b, 0x9e69, 0x9c63, 0xfec7, 0xfec6, 0x9c67, + 0x9c69, 0x8be2, 0x9165, 0x9ce7, 0x8a54, 0x9c6c, 0x9c6e, 0xfe5d, + 0x9c73, 0x956a, 0x956d, 0x8ef0, 0x8f4d, 0x8ef6, 0xfabc, 0xfbda, + 0x8b4c, 0xfd75, 0x9bdd, 0xfaf5, 0x9c74, 0x9545, 0x96c6, 0x8f6a, + 0x8f4e, 0x9c78, 0xfa55, 0x97e4, 0x9c41, 0x925c, 0x96fa, 0xfb66, + 0x8e65, 0x9849, 0xfba8, 0x9842, 0x9c7a, 0x97fb, 0x90ca, 0x9c5b, + 0x974d, 0x8ed3, 0x9561, 0x9f4b, 0x9fb5, 0x93d2, 0xfdaa, 0x9840, + 0x9146, 0x9867, 0xfa5a, 0xfba9, 0x9841, 0xfcfd, 0xfdab, 0x91bd, + 0x8f4c, 0x96c9, 0x8f55, 0xfbae, 0x956f, 0x9c7d, 0xa0f0, 0x946f, + 0xfdac, 0x96cb, 0x96ce, 0xa056, 0x9ce1, 0x96c4, 0x8f5e, 0x8f6c, + 0x8ea3, 0xfbb3, 0xfc53, 0xfdb3, 0x8f6b, 0x96ca, 0x8f79, 0x9e6f, + 0xa0c5, 0xfc78, 0x8e42, 0x8f5a, 0x90c2, 0x8ea5, 0x9061, 0x924f, + 0x9373, 0xfdb5, 0xfecc, 0xfbbd, 0x9843, 0x96c5, 0x89bc, 0x9ca3, + 0x924b, 0x984a, 0x8fa4, 0xa0f1, 0x9efb, 0x9cd2, 0x8fa7, 0xfc5c, + 0x9845, 0x9046, 0xfefa, 0x9560, 0x9f48, 0x9247, 0x90fb, 0x9ca4, + 0x9571, 0x9ca6, 0x9ca7, 0x9caa, 0x9ed3, 0x9e70, 0x9cac, 0x8fae, + 0x957d, 0x9cb0, 0x97b6, 0xa0bd, 0x8adf, 0x9eaa, 0x8fbd, 0x8fbf, + 0x9369, 0x9ba7, 0xc8a4, 0xfeea, 0x9be1, 0x8b41, 0x9db6, 0xa0eb, + 0x9ba3, 0x8ba1, 0x8fc8, 0x894c, 0x9860, 0x94c7, 0x8b58, 0x95ab, + 0x95aa, 0x9cc3, 0x9cc4, 0x93d6, 0x9dac, 0x8be6, 0x8a71, 0x8fd1, + 0x99d5, 0x90f4, 0x8aa3, 0x9cce, 0x9cd4, 0x9cd5, 0xfbc8, 0x9db3, + 0xfc70, 0x8fd7, 0x9b73, 0xfa5b, 0x8fd2, 0x9064, 0x98b6, 0x9668, + 0x9cd6, 0x98bd, 0x8fdc, 0xfef6, 0x8fd9, 0x9541, 0x97f3, 0x9bf8, + 0x9e6c, 0x8ff2, 0x8fee, 0x9cd7, 0x9e6e, 0x8a40, 0x8fef, 0x8ff4, + 0x8ff5, 0x95c2, 0x986a, 0x97cf, 0x9ee5, 0x9e7c, 0x9041, 0x9cdb, + 0x9441, 0x9ce6, 0x9db0, 0x9cea, 0x9ced, 0x9cfa, 0x8b62, 0x8a4e, + 0x9cca, 0x8a66, 0x9cfb, 0x9cfc, 0x9cfe, 0x8a53, 0x9ce5, 0x9d40, + 0x9d41, 0x9045, 0x8b73, 0x97ca, 0x9d42, 0x8a61, 0x8bae, 0x8ad2, + 0x8ba2, 0x9df2, 0x9d43, 0x9cdf, 0x9d44, 0x8eca, 0x904e, 0x8eb3, + 0x9ff5, 0x9d45, 0x904f, 0x9d47, 0x89ca, 0x9cb5, 0xfbfe, 0x905e, + 0x9063, 0x9057, 0x9066, 0x9bc0, 0xfce5, 0x9162, 0x9067, 0x8fa1, + 0x8fa2, 0x9d48, 0xfad3, 0x905d, 0x90b9, 0x906b, 0x9069, 0xfe57, + 0xfe55, 0x9073, 0x9bef, 0x9cf0, 0x9d4b, 0xfed9, 0xfeda, 0x91e0, + 0x91d8, 0x9646, 0x9360, 0xfa53, 0x9cd3, 0x9d4e, 0xfb40, 0x8de2, + 0x9442, 0x9056, 0x9865, 0xfa4a, 0x9d50, 0x9d52, 0x95af, 0x975a, + 0x9349, 0x9747, 0xa0f4, 0x9778, 0x8fcf, 0xfc60, 0xfc56, 0x91dc, + 0x9661, 0x92ec, 0x935d, 0x8ede, 0x96fe, 0xfd4f, 0x95de, 0x98b0, + 0xa040, 0x97bd, 0x977d, 0x97f5, 0x9bac, 0xfada, 0x92c2, 0x97b1, + 0x907b, 0x93fe, 0x947b, 0x9777, 0xfabe, 0xfd43, 0x90c6, 0x90a4, + 0x90a8, 0x94a9, 0x90a9, 0x95e0, 0x907d, 0x9265, 0xfdba, 0x93c4, + 0xfeed, 0x9dab, 0xa0e3, 0x9648, 0x9d53, 0x8aa9, 0x9bc5, 0x965d, + 0x975f, 0x965f, 0x966e, 0xfb5d, 0x9db1, 0xfea3, 0x9db2, 0x95ae, + 0xfca3, 0xa0a2, 0x9655, 0x9d54, 0x9341, 0x95ad, 0x91d5, 0x977a, + 0xfdfc, 0x8e47, 0x93fd, 0x90a5, 0x90ac, 0x95ac, 0x90ae, 0xfea5, + 0x9d56, 0x97e3, 0x95e2, 0x9466, 0x9647, 0x91b8, 0x9cec, 0x90ad, + 0x95e3, 0x8b4f, 0x8ae3, 0x8b4d, 0x95ea, 0x8b4e, 0x8bed, 0x91d9, + 0xa0a4, 0x95f5, 0x95f4, 0x9fb3, 0xfeaf, 0xfe72, 0x927a, 0xfeac, + 0x95f3, 0x9d58, 0x9372, 0x91c5, 0x9642, 0x90cd, 0x95fe, 0x9159, + 0x9c65, 0x97cc, 0x90ce, 0x9d59, 0xfcf5, 0xfefd, 0x9d5b, 0x9d5c, + 0x937e, 0x98ac, 0x9d5e, 0xfdd0, 0xfd60, 0x9ccf, 0x90dd, 0x90e0, + 0x90f3, 0x98b1, 0x90f0, 0x93bd, 0x95b7, 0x9f46, 0x8e4b, 0x9658, + 0x8a4c, 0x9d63, 0x9ecf, 0x9d65, 0x9d66, 0x965a, 0x9d64, 0x8a6c, + 0x8ad9, 0x9d67, 0x8a70, 0x8bf3, 0x9150, 0x9cc1, 0x9d68, 0x93a7, + 0x9674, 0xa0ef, 0x9151, 0x96c1, 0x9676, 0x9d69, 0xfca4, 0x9d6a, + 0x924e, 0x9d6b, 0x9bc1, 0x9d6c, 0x8a65, 0x915d, 0x9d6d, 0x915a, + 0x9cc0, 0x916a, 0x9d6e, 0x9ea6, 0x9dcd, 0x9d6f, 0x89bb, 0x9ef9, + 0x96b4, 0x9172, 0x9ec8, 0x8b55, 0x9d71, 0x9d72, 0x9ecc, 0x9174, + 0x9ed0, 0x905c, 0x8ed2, 0x91a8, 0x9177, 0x96bf, 0x96c0, 0x8fb1, + 0x96b7, 0x9178, 0x89be, 0x917c, 0xfb77, 0x9175, 0x91a3, 0x9176, + 0x96be, 0x9179, 0x96b6, 0x91a4, 0x91a6, 0x9d75, 0x9052, 0xa045, + 0x91a9, 0x98aa, 0x8baa, 0x9cdd, 0x9d77, 0x8940, 0x9eec, 0x93aa, + 0x9478, 0x9d7a, 0x8ac9, 0x8b4b, 0x9fec, 0x8ae2, 0x9e75, 0x9874, + 0x9ac8, 0xa047, 0x8bc3, 0xfc48, 0xfc77, 0x9c52, 0x8efd, 0x8fa8, + 0x957a, 0x8ff0, +}; + +static const Summary16 hkscs1999_uni2indx_page00[45] = { + /* 0x0000 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0100 }, { 1, 0x0000 }, + { 1, 0x0703 }, { 6, 0x000c }, { 8, 0x3703 }, { 15, 0x170c }, + /* 0x0100 */ + { 21, 0x0003 }, { 23, 0x0c0c }, { 27, 0x0800 }, { 28, 0x0000 }, + { 28, 0x3800 }, { 31, 0x0008 }, { 32, 0x0800 }, { 33, 0x0000 }, + { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0000 }, + { 33, 0x6000 }, { 35, 0x1557 }, { 43, 0x0000 }, { 43, 0x0000 }, + /* 0x0200 */ + { 43, 0x0000 }, { 43, 0x0000 }, { 43, 0x0000 }, { 43, 0x0000 }, + { 43, 0x0000 }, { 43, 0x0813 }, { 47, 0x0402 }, { 49, 0x0020 }, + { 50, 0x0408 }, { 52, 0x0000 }, { 52, 0x0000 }, { 52, 0x0000 }, + { 52, 0x0040 }, +}; +static const Summary16 hkscs1999_uni2indx_page04[6] = { + /* 0x0400 */ + { 53, 0x0002 }, { 54, 0xffff }, { 70, 0xffff }, { 86, 0xffff }, + { 102, 0xffff }, { 118, 0x0002 }, +}; +static const Summary16 hkscs1999_uni2indx_page1e[13] = { + /* 0x1e00 */ + { 119, 0x0000 }, { 119, 0x0000 }, { 119, 0x0000 }, { 119, 0x0000 }, + { 119, 0x0000 }, { 119, 0x0000 }, { 119, 0x0000 }, { 119, 0x0000 }, + { 119, 0x0000 }, { 119, 0x0000 }, { 119, 0x0000 }, { 119, 0xc000 }, + { 121, 0x0003 }, +}; +static const Summary16 hkscs1999_uni2indx_page21[15] = { + /* 0x2100 */ + { 123, 0x0000 }, { 123, 0x0040 }, { 124, 0x0002 }, { 125, 0x0000 }, + { 125, 0x0000 }, { 125, 0x0000 }, { 125, 0x0000 }, { 125, 0x03ff }, + { 135, 0x0000 }, { 135, 0x0000 }, { 135, 0x0000 }, { 135, 0x0300 }, + { 137, 0x0000 }, { 137, 0x0000 }, { 137, 0x0080 }, +}; +static const Summary16 hkscs1999_uni2indx_page23[40] = { + /* 0x2300 */ + { 138, 0x0000 }, { 138, 0x0000 }, { 138, 0x0000 }, { 138, 0x0000 }, + { 138, 0x0000 }, { 138, 0x0000 }, { 138, 0x0000 }, { 138, 0x0000 }, + { 138, 0x0000 }, { 138, 0x0000 }, { 138, 0x0000 }, { 138, 0x0000 }, + { 138, 0x0000 }, { 138, 0x0c00 }, { 140, 0x0000 }, { 140, 0x0000 }, + /* 0x2400 */ + { 140, 0x0000 }, { 140, 0x0000 }, { 140, 0x0000 }, { 140, 0x0000 }, + { 140, 0x0000 }, { 140, 0x0000 }, { 140, 0x03ff }, { 150, 0x3ff0 }, + { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, + { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, + /* 0x2500 */ + { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, { 160, 0x0000 }, + { 160, 0x0000 }, { 160, 0xffff }, { 176, 0xffff }, { 192, 0x0001 }, +}; +static const Summary16 hkscs1999_uni2indx_page27[4] = { + /* 0x2700 */ + { 193, 0x0000 }, { 193, 0x0000 }, { 193, 0x0000 }, { 193, 0x2000 }, +}; +static const Summary16 hkscs1999_uni2indx_page2e[68] = { + /* 0x2e00 */ + { 194, 0x0000 }, { 194, 0x0000 }, { 194, 0x0000 }, { 194, 0x0000 }, + { 194, 0x0000 }, { 194, 0x0000 }, { 194, 0x0000 }, { 194, 0x0000 }, + { 194, 0x35d1 }, { 202, 0x3020 }, { 205, 0x54a0 }, { 210, 0x5040 }, + { 213, 0xb440 }, { 218, 0x40c0 }, { 221, 0x0008 }, { 222, 0x0000 }, + /* 0x2f00 */ + { 222, 0x0000 }, { 222, 0x0000 }, { 222, 0x0000 }, { 222, 0x0008 }, + { 223, 0x0000 }, { 223, 0x0000 }, { 223, 0x0000 }, { 223, 0x0000 }, + { 223, 0x0000 }, { 223, 0x0000 }, { 223, 0x0000 }, { 223, 0x0000 }, + { 223, 0x0000 }, { 223, 0x0000 }, { 223, 0x0000 }, { 223, 0x0000 }, + /* 0x3000 */ + { 223, 0x00e0 }, { 226, 0x0000 }, { 226, 0x0000 }, { 226, 0x0000 }, + { 226, 0xfffe }, { 241, 0xffff }, { 257, 0xffff }, { 273, 0xffff }, + { 289, 0xffff }, { 305, 0x780f }, { 313, 0xfffe }, { 328, 0xffff }, + { 344, 0xffff }, { 360, 0xffff }, { 376, 0xffff }, { 392, 0x707f }, + /* 0x3100 */ + { 402, 0x0000 }, { 402, 0x0000 }, { 402, 0x0000 }, { 402, 0x0000 }, + { 402, 0x0000 }, { 402, 0x0000 }, { 402, 0x0000 }, { 402, 0x0000 }, + { 402, 0x0000 }, { 402, 0x0000 }, { 402, 0x0000 }, { 402, 0x0000 }, + { 402, 0xffff }, { 418, 0x0000 }, { 418, 0x0000 }, { 418, 0x0000 }, + /* 0x3200 */ + { 418, 0x0000 }, { 418, 0x0000 }, { 418, 0x0000 }, { 418, 0x0002 }, +}; +static const Summary16 hkscs1999_uni2indx_page34[1724] = { + /* 0x3400 */ + { 419, 0x0000 }, { 419, 0x0000 }, { 419, 0x0000 }, { 419, 0x0020 }, + { 420, 0x1001 }, { 422, 0x0000 }, { 422, 0x0010 }, { 423, 0x6408 }, + { 427, 0x0000 }, { 427, 0x0048 }, { 429, 0x8020 }, { 431, 0x1000 }, + { 432, 0x0102 }, { 434, 0x8000 }, { 435, 0x0010 }, { 436, 0x0800 }, + /* 0x3500 */ + { 437, 0x0040 }, { 438, 0x0000 }, { 438, 0x0000 }, { 438, 0x4000 }, + { 439, 0x0000 }, { 439, 0x000a }, { 441, 0x2002 }, { 443, 0x0185 }, + { 447, 0x0010 }, { 448, 0x0180 }, { 450, 0x2022 }, { 453, 0x8000 }, + { 454, 0x44a2 }, { 459, 0x2844 }, { 463, 0x0000 }, { 463, 0x480e }, + /* 0x3600 */ + { 468, 0x0200 }, { 469, 0x0500 }, { 471, 0x2008 }, { 473, 0x4220 }, + { 476, 0x4380 }, { 480, 0x8000 }, { 481, 0x0000 }, { 481, 0x0400 }, + { 482, 0x0002 }, { 483, 0x0400 }, { 484, 0x1420 }, { 487, 0x1223 }, + { 492, 0x01ba }, { 498, 0x2058 }, { 502, 0x0066 }, { 506, 0x0020 }, + /* 0x3700 */ + { 507, 0x250a }, { 512, 0x1000 }, { 513, 0x302c }, { 518, 0x040d }, + { 522, 0x0009 }, { 524, 0x0000 }, { 524, 0x8004 }, { 526, 0x0000 }, + { 526, 0x0000 }, { 526, 0x0080 }, { 527, 0x0001 }, { 528, 0x4200 }, + { 530, 0x0000 }, { 530, 0x0000 }, { 530, 0x0000 }, { 530, 0x0904 }, + /* 0x3800 */ + { 533, 0x8000 }, { 534, 0x0200 }, { 535, 0x2001 }, { 537, 0x0140 }, + { 539, 0x0000 }, { 539, 0x0000 }, { 539, 0x0008 }, { 540, 0x0000 }, + { 540, 0x0000 }, { 540, 0x0000 }, { 540, 0x0001 }, { 541, 0x0000 }, + { 541, 0x1008 }, { 543, 0x0002 }, { 544, 0x0000 }, { 544, 0x0400 }, + /* 0x3900 */ + { 545, 0x0100 }, { 546, 0x0010 }, { 547, 0x0080 }, { 548, 0x8004 }, + { 550, 0x2000 }, { 551, 0x0000 }, { 551, 0x0008 }, { 552, 0x0000 }, + { 552, 0x0601 }, { 555, 0x0a04 }, { 558, 0x0012 }, { 560, 0x0100 }, + { 561, 0x0000 }, { 561, 0x1000 }, { 562, 0x1024 }, { 565, 0x4900 }, + /* 0x3a00 */ + { 568, 0x004a }, { 571, 0x0180 }, { 573, 0x0600 }, { 575, 0x0010 }, + { 576, 0x0800 }, { 577, 0x5084 }, { 581, 0x00c0 }, { 583, 0x0000 }, + { 583, 0x0000 }, { 583, 0x0080 }, { 584, 0x0800 }, { 585, 0x2000 }, + { 586, 0x0000 }, { 586, 0x4000 }, { 587, 0x0001 }, { 588, 0x0805 }, + /* 0x3b00 */ + { 591, 0x4000 }, { 592, 0x0200 }, { 593, 0x0804 }, { 595, 0x0200 }, + { 596, 0x0004 }, { 597, 0x0100 }, { 598, 0x0001 }, { 599, 0x1806 }, + { 603, 0x0001 }, { 604, 0x0240 }, { 606, 0x0002 }, { 607, 0x5000 }, + { 609, 0x0014 }, { 611, 0x2080 }, { 613, 0x1000 }, { 614, 0x001c }, + /* 0x3c00 */ + { 617, 0x2000 }, { 618, 0x0122 }, { 621, 0x0000 }, { 621, 0x0000 }, + { 621, 0x0000 }, { 621, 0x0010 }, { 622, 0x0000 }, { 622, 0x0000 }, + { 622, 0x0000 }, { 622, 0x0000 }, { 622, 0x0000 }, { 622, 0x0000 }, + { 622, 0x2800 }, { 624, 0x1042 }, { 627, 0x8800 }, { 629, 0x0000 }, + /* 0x3d00 */ + { 629, 0x0000 }, { 629, 0x2008 }, { 631, 0x0000 }, { 631, 0x0804 }, + { 633, 0x5040 }, { 636, 0x8002 }, { 638, 0x8604 }, { 642, 0x2020 }, + { 644, 0x8420 }, { 647, 0x0002 }, { 648, 0x2020 }, { 650, 0x8010 }, + { 652, 0x30c0 }, { 656, 0x0808 }, { 658, 0x0980 }, { 661, 0x3088 }, + /* 0x3e00 */ + { 665, 0x0040 }, { 666, 0x0000 }, { 666, 0x0000 }, { 666, 0x0000 }, + { 666, 0x0109 }, { 669, 0x0020 }, { 670, 0x0000 }, { 670, 0x0010 }, + { 671, 0x0000 }, { 671, 0x0000 }, { 671, 0x2700 }, { 675, 0x8102 }, + { 678, 0x1484 }, { 682, 0x44c3 }, { 688, 0x0a86 }, { 693, 0x9419 }, + /* 0x3f00 */ + { 699, 0x4051 }, { 703, 0x0000 }, { 703, 0x0000 }, { 703, 0x0000 }, + { 703, 0x0000 }, { 703, 0x0308 }, { 706, 0x0008 }, { 707, 0x1000 }, + { 708, 0x0000 }, { 708, 0x0008 }, { 709, 0x0000 }, { 709, 0x0000 }, + { 709, 0x0001 }, { 710, 0x1080 }, { 712, 0x2020 }, { 714, 0x0600 }, + /* 0x4000 */ + { 716, 0x0010 }, { 717, 0x2000 }, { 718, 0x0000 }, { 718, 0x0200 }, + { 719, 0x0020 }, { 720, 0x0088 }, { 722, 0x8424 }, { 726, 0x0000 }, + { 726, 0x0000 }, { 726, 0x0000 }, { 726, 0x0100 }, { 727, 0x8800 }, + { 729, 0x0100 }, { 730, 0x8100 }, { 732, 0x0000 }, { 732, 0x0400 }, + /* 0x4100 */ + { 733, 0x4218 }, { 737, 0x0000 }, { 737, 0x0000 }, { 737, 0x0004 }, + { 738, 0x0000 }, { 738, 0x0000 }, { 738, 0x5080 }, { 741, 0x8000 }, + { 742, 0x0000 }, { 742, 0x0001 }, { 743, 0x0000 }, { 743, 0x0004 }, + { 744, 0x8410 }, { 747, 0x0800 }, { 748, 0x8000 }, { 749, 0x0200 }, + /* 0x4200 */ + { 750, 0x0000 }, { 750, 0x0002 }, { 751, 0x0000 }, { 751, 0x0000 }, + { 751, 0x0001 }, { 752, 0x0000 }, { 752, 0x0401 }, { 754, 0x0400 }, + { 755, 0x1000 }, { 756, 0x0010 }, { 757, 0x0000 }, { 757, 0x1220 }, + { 760, 0x0000 }, { 760, 0x0000 }, { 760, 0x0000 }, { 760, 0x1810 }, + /* 0x4300 */ + { 763, 0x0000 }, { 763, 0x0000 }, { 763, 0x0800 }, { 764, 0x0000 }, + { 764, 0x0000 }, { 764, 0x0000 }, { 764, 0x4000 }, { 765, 0x0000 }, + { 765, 0x0000 }, { 765, 0x0080 }, { 766, 0x0000 }, { 766, 0x0400 }, + { 767, 0x0002 }, { 768, 0x8200 }, { 770, 0x2000 }, { 771, 0x0004 }, + /* 0x4400 */ + { 772, 0x0006 }, { 774, 0x0008 }, { 775, 0x2020 }, { 777, 0x0000 }, + { 777, 0x0000 }, { 777, 0x0000 }, { 777, 0x0000 }, { 777, 0x0400 }, + { 778, 0x8000 }, { 779, 0x8002 }, { 781, 0x0005 }, { 783, 0x0081 }, + { 785, 0x4021 }, { 788, 0xa000 }, { 790, 0x1e10 }, { 795, 0x0010 }, + /* 0x4500 */ + { 796, 0x0a18 }, { 800, 0x2040 }, { 802, 0x4080 }, { 804, 0xa808 }, + { 808, 0x0008 }, { 809, 0x1026 }, { 813, 0x0404 }, { 815, 0x0080 }, + { 816, 0x0020 }, { 817, 0x0000 }, { 817, 0x0000 }, { 817, 0x0000 }, + { 817, 0x0000 }, { 817, 0x0000 }, { 817, 0x0200 }, { 818, 0x0000 }, + /* 0x4600 */ + { 818, 0x8040 }, { 820, 0x00a0 }, { 822, 0x0000 }, { 822, 0x0000 }, + { 822, 0x0000 }, { 822, 0x0800 }, { 823, 0x0000 }, { 823, 0x0400 }, + { 824, 0x0001 }, { 825, 0x0000 }, { 825, 0x0000 }, { 825, 0x0000 }, + { 825, 0x8000 }, { 826, 0x0001 }, { 827, 0x0000 }, { 827, 0x0020 }, + /* 0x4700 */ + { 828, 0x0000 }, { 828, 0x0108 }, { 830, 0x0000 }, { 830, 0x0000 }, + { 830, 0x4000 }, { 831, 0x0000 }, { 831, 0x0000 }, { 831, 0x1000 }, + { 832, 0x0000 }, { 832, 0x0100 }, { 833, 0x0040 }, { 834, 0x0000 }, + { 834, 0x0000 }, { 834, 0x0020 }, { 835, 0x2000 }, { 836, 0x0010 }, + /* 0x4800 */ + { 837, 0x0801 }, { 839, 0x0000 }, { 839, 0x0000 }, { 839, 0x0080 }, + { 840, 0x0000 }, { 840, 0x2000 }, { 841, 0x0000 }, { 841, 0x0002 }, + { 842, 0x0000 }, { 842, 0x0800 }, { 843, 0x6000 }, { 845, 0x0000 }, + { 845, 0x0000 }, { 845, 0x2001 }, { 847, 0x2000 }, { 848, 0x0408 }, + /* 0x4900 */ + { 850, 0x0040 }, { 851, 0x4002 }, { 853, 0x2420 }, { 856, 0x5020 }, + { 859, 0x0020 }, { 860, 0x000a }, { 862, 0x0420 }, { 864, 0x0004 }, + { 865, 0x0200 }, { 866, 0x0000 }, { 866, 0x0082 }, { 868, 0x0000 }, + { 868, 0x0000 }, { 868, 0x8000 }, { 869, 0x00a0 }, { 871, 0x0000 }, + /* 0x4a00 */ + { 871, 0x8000 }, { 872, 0x2000 }, { 873, 0x0010 }, { 874, 0x0020 }, + { 875, 0x0000 }, { 875, 0x0000 }, { 875, 0x0000 }, { 875, 0x0000 }, + { 875, 0x0000 }, { 875, 0x0040 }, { 876, 0x0000 }, { 876, 0x0110 }, + { 878, 0x0000 }, { 878, 0x0002 }, { 879, 0x0010 }, { 880, 0x8000 }, + /* 0x4b00 */ + { 881, 0x0000 }, { 881, 0x0200 }, { 882, 0x1000 }, { 883, 0x0080 }, + { 884, 0x0000 }, { 884, 0x0000 }, { 884, 0x8000 }, { 885, 0x4805 }, + { 889, 0x4000 }, { 890, 0x20c9 }, { 895, 0x0000 }, { 895, 0x6000 }, + { 897, 0x0001 }, { 898, 0x0000 }, { 898, 0x0000 }, { 898, 0x0000 }, + /* 0x4c00 */ + { 898, 0x4090 }, { 901, 0x0000 }, { 901, 0x0000 }, { 901, 0x4800 }, + { 903, 0x0000 }, { 903, 0x0800 }, { 904, 0x2000 }, { 905, 0x2000 }, + { 906, 0x0000 }, { 906, 0x0000 }, { 906, 0x4010 }, { 908, 0x0081 }, + { 910, 0x2000 }, { 911, 0x0000 }, { 911, 0x2002 }, { 913, 0x0000 }, + /* 0x4d00 */ + { 913, 0x0200 }, { 914, 0x0001 }, { 915, 0x0000 }, { 915, 0x0010 }, + { 916, 0x0000 }, { 916, 0x0000 }, { 916, 0x0000 }, { 916, 0x0000 }, + { 916, 0x0000 }, { 916, 0x1002 }, { 918, 0x0000 }, { 918, 0x0000 }, + { 918, 0x0000 }, { 918, 0x0000 }, { 918, 0x0000 }, { 918, 0x0000 }, + /* 0x4e00 */ + { 918, 0x0010 }, { 919, 0x1400 }, { 921, 0x1512 }, { 926, 0xa0c0 }, + { 930, 0x0200 }, { 931, 0x0c00 }, { 933, 0x0400 }, { 934, 0x0100 }, + { 935, 0x02a3 }, { 940, 0x0500 }, { 942, 0x0001 }, { 943, 0x9880 }, + { 947, 0x4000 }, { 948, 0x0000 }, { 948, 0x4c00 }, { 951, 0x0100 }, + /* 0x4f00 */ + { 952, 0x0008 }, { 953, 0x0400 }, { 954, 0x0300 }, { 956, 0x0284 }, + { 959, 0x0824 }, { 962, 0x0000 }, { 962, 0x0000 }, { 962, 0x0004 }, + { 963, 0x0400 }, { 964, 0x0000 }, { 964, 0x0904 }, { 967, 0x2001 }, + { 969, 0x1100 }, { 971, 0x0000 }, { 971, 0x0030 }, { 973, 0x2204 }, + /* 0x5000 */ + { 976, 0x0108 }, { 978, 0x0000 }, { 978, 0x4000 }, { 979, 0x0010 }, + { 980, 0x0000 }, { 980, 0x0140 }, { 982, 0x1040 }, { 984, 0x0000 }, + { 984, 0x0102 }, { 986, 0x0001 }, { 987, 0x0040 }, { 988, 0x0000 }, + { 988, 0x2000 }, { 989, 0x8201 }, { 992, 0x0002 }, { 993, 0x1010 }, + /* 0x5100 */ + { 995, 0x6002 }, { 998, 0x0000 }, { 998, 0x0800 }, { 999, 0x0000 }, + { 999, 0x0000 }, { 999, 0x0040 }, { 1000, 0x0401 }, { 1002, 0x0210 }, + { 1004, 0x0144 }, { 1007, 0x1440 }, { 1010, 0x0980 }, { 1013, 0x013c }, + { 1018, 0x8288 }, { 1022, 0x880e }, { 1027, 0x2014 }, { 1030, 0x5010 }, + /* 0x5200 */ + { 1033, 0x0824 }, { 1036, 0x8000 }, { 1037, 0x00c1 }, { 1040, 0x1010 }, + { 1042, 0x0000 }, { 1042, 0x0280 }, { 1044, 0x0101 }, { 1046, 0x0208 }, + { 1048, 0x8000 }, { 1049, 0x0411 }, { 1052, 0x0112 }, { 1055, 0x0220 }, + { 1057, 0x1020 }, { 1059, 0x0003 }, { 1061, 0x0003 }, { 1063, 0x0200 }, + /* 0x5300 */ + { 1064, 0x0002 }, { 1065, 0x0000 }, { 1065, 0x1080 }, { 1067, 0x090c }, + { 1071, 0x4004 }, { 1073, 0xa000 }, { 1075, 0x2290 }, { 1079, 0x6010 }, + { 1082, 0x0000 }, { 1082, 0x0008 }, { 1083, 0x4f45 }, { 1091, 0x0041 }, + { 1093, 0x1026 }, { 1097, 0x0707 }, { 1103, 0x0001 }, { 1104, 0x40c0 }, + /* 0x5400 */ + { 1107, 0x0000 }, { 1107, 0x0458 }, { 1111, 0x800a }, { 1114, 0x0004 }, + { 1115, 0x2800 }, { 1117, 0x0000 }, { 1117, 0x2600 }, { 1120, 0x0000 }, + { 1120, 0x8020 }, { 1122, 0x5098 }, { 1127, 0x0018 }, { 1129, 0x0214 }, + { 1132, 0x3800 }, { 1135, 0x0401 }, { 1137, 0x8008 }, { 1139, 0x0000 }, + /* 0x5500 */ + { 1139, 0x2004 }, { 1141, 0x4108 }, { 1144, 0x0928 }, { 1148, 0x8000 }, + { 1149, 0x0280 }, { 1151, 0x2008 }, { 1153, 0x0a00 }, { 1155, 0x020e }, + { 1159, 0x0040 }, { 1160, 0x0001 }, { 1161, 0x0200 }, { 1162, 0x1611 }, + { 1167, 0x0002 }, { 1168, 0x4180 }, { 1171, 0x1400 }, { 1173, 0x0823 }, + /* 0x5600 */ + { 1177, 0x0020 }, { 1178, 0x4002 }, { 1180, 0x202f }, { 1186, 0x0080 }, + { 1187, 0xa008 }, { 1190, 0x2015 }, { 1194, 0x0002 }, { 1195, 0x1c00 }, + { 1198, 0x0e00 }, { 1201, 0xc004 }, { 1204, 0x8012 }, { 1207, 0x8202 }, + { 1210, 0x0000 }, { 1210, 0x0040 }, { 1211, 0xa004 }, { 1214, 0x2002 }, + /* 0x5700 */ + { 1216, 0x0001 }, { 1217, 0x2020 }, { 1219, 0x0000 }, { 1219, 0x8004 }, + { 1221, 0x004c }, { 1224, 0x8890 }, { 1228, 0x0080 }, { 1229, 0xc400 }, + { 1232, 0x2500 }, { 1235, 0x1001 }, { 1237, 0x0482 }, { 1240, 0x4810 }, + { 1243, 0x0110 }, { 1245, 0x6080 }, { 1248, 0x8040 }, { 1250, 0x4000 }, + /* 0x5800 */ + { 1251, 0x0008 }, { 1252, 0x0004 }, { 1253, 0x0044 }, { 1255, 0x0400 }, + { 1256, 0x0091 }, { 1259, 0x9000 }, { 1261, 0x1200 }, { 1263, 0x000c }, + { 1265, 0x0000 }, { 1265, 0x0600 }, { 1267, 0x0480 }, { 1269, 0x0861 }, + { 1273, 0x0800 }, { 1274, 0x1000 }, { 1275, 0x0001 }, { 1276, 0x080d }, + /* 0x5900 */ + { 1280, 0x04b4 }, { 1285, 0x8002 }, { 1287, 0x0000 }, { 1287, 0x0014 }, + { 1289, 0x0000 }, { 1289, 0x0000 }, { 1289, 0x0020 }, { 1290, 0x0020 }, + { 1291, 0x0200 }, { 1292, 0x8410 }, { 1295, 0x1000 }, { 1296, 0x0181 }, + { 1299, 0x0210 }, { 1301, 0x0200 }, { 1302, 0x8800 }, { 1304, 0x0301 }, + /* 0x5a00 */ + { 1307, 0x2804 }, { 1310, 0x0004 }, { 1311, 0x1c92 }, { 1317, 0x2000 }, + { 1318, 0x0020 }, { 1319, 0x0210 }, { 1321, 0x490a }, { 1326, 0x4202 }, + { 1329, 0x0146 }, { 1333, 0x0242 }, { 1336, 0x0803 }, { 1339, 0x0000 }, + { 1339, 0xc008 }, { 1342, 0x0008 }, { 1343, 0x0010 }, { 1344, 0x4405 }, + /* 0x5b00 */ + { 1348, 0x2000 }, { 1349, 0x8002 }, { 1351, 0x0800 }, { 1352, 0x0000 }, + { 1352, 0x8452 }, { 1357, 0x0000 }, { 1357, 0x2140 }, { 1360, 0x1050 }, + { 1363, 0x0005 }, { 1365, 0xe001 }, { 1369, 0x0400 }, { 1370, 0x0000 }, + { 1370, 0x0008 }, { 1371, 0x00a0 }, { 1373, 0x0000 }, { 1373, 0x8008 }, + /* 0x5c00 */ + { 1375, 0x0020 }, { 1376, 0x5018 }, { 1380, 0x0009 }, { 1382, 0x0000 }, + { 1382, 0x0600 }, { 1384, 0x4008 }, { 1386, 0x0000 }, { 1386, 0x0000 }, + { 1386, 0x0020 }, { 1387, 0x5600 }, { 1391, 0x0000 }, { 1391, 0x0400 }, + { 1392, 0x0006 }, { 1394, 0x0002 }, { 1395, 0x8220 }, { 1398, 0x0000 }, + /* 0x5d00 */ + { 1398, 0x0000 }, { 1398, 0x0121 }, { 1401, 0x9000 }, { 1403, 0x4000 }, + { 1404, 0x0140 }, { 1406, 0x08c0 }, { 1409, 0x0000 }, { 1409, 0x0011 }, + { 1411, 0x4820 }, { 1414, 0x0000 }, { 1414, 0x0810 }, { 1416, 0x0240 }, + { 1418, 0x0002 }, { 1419, 0x0880 }, { 1421, 0x0000 }, { 1421, 0x0020 }, + /* 0x5e00 */ + { 1422, 0x0a00 }, { 1424, 0x0004 }, { 1425, 0x4000 }, { 1426, 0x0000 }, + { 1426, 0x0104 }, { 1428, 0x4000 }, { 1429, 0x0000 }, { 1429, 0x8400 }, + { 1431, 0x0048 }, { 1433, 0x0000 }, { 1433, 0x0000 }, { 1433, 0x2000 }, + { 1434, 0x2000 }, { 1435, 0x0001 }, { 1436, 0x0000 }, { 1436, 0x1b10 }, + /* 0x5f00 */ + { 1441, 0x7000 }, { 1444, 0x0000 }, { 1444, 0x0020 }, { 1445, 0x0400 }, + { 1446, 0x2000 }, { 1447, 0x1003 }, { 1450, 0x000a }, { 1452, 0x0804 }, + { 1454, 0x0008 }, { 1455, 0x0000 }, { 1455, 0x0090 }, { 1457, 0x0402 }, + { 1459, 0x0010 }, { 1460, 0x8800 }, { 1462, 0x0000 }, { 1462, 0x0000 }, + /* 0x6000 */ + { 1462, 0x0000 }, { 1462, 0x0000 }, { 1462, 0x0008 }, { 1463, 0x0802 }, + { 1465, 0x0400 }, { 1466, 0x0004 }, { 1467, 0x0000 }, { 1467, 0x40a0 }, + { 1470, 0x0000 }, { 1470, 0x4000 }, { 1471, 0x0090 }, { 1473, 0x0008 }, + { 1474, 0x0000 }, { 1474, 0x4080 }, { 1476, 0x0388 }, { 1480, 0x2000 }, + /* 0x6100 */ + { 1481, 0x1080 }, { 1483, 0x0200 }, { 1484, 0x0000 }, { 1484, 0x2001 }, + { 1486, 0x0004 }, { 1487, 0x1201 }, { 1490, 0x8011 }, { 1493, 0x2000 }, + { 1494, 0x0082 }, { 1496, 0x1320 }, { 1500, 0x0000 }, { 1500, 0x0280 }, + { 1502, 0x8001 }, { 1504, 0x0409 }, { 1507, 0x0004 }, { 1508, 0x0000 }, + /* 0x6200 */ + { 1508, 0x0000 }, { 1508, 0x0000 }, { 1508, 0x1000 }, { 1509, 0x0280 }, + { 1511, 0x1000 }, { 1512, 0x0000 }, { 1512, 0x0100 }, { 1513, 0x0000 }, + { 1513, 0x0024 }, { 1515, 0x2001 }, { 1517, 0x0050 }, { 1519, 0x0000 }, + { 1519, 0x0028 }, { 1521, 0x8020 }, { 1523, 0x0020 }, { 1524, 0x0000 }, + /* 0x6300 */ + { 1524, 0x0000 }, { 1524, 0x0100 }, { 1525, 0x4000 }, { 1526, 0x00a2 }, + { 1529, 0x0000 }, { 1529, 0x0000 }, { 1529, 0x1010 }, { 1531, 0x8200 }, + { 1533, 0x0800 }, { 1534, 0x0000 }, { 1534, 0x0000 }, { 1534, 0x0200 }, + { 1535, 0x0002 }, { 1536, 0x4002 }, { 1538, 0x0044 }, { 1540, 0x5900 }, + /* 0x6400 */ + { 1544, 0x0080 }, { 1545, 0x0000 }, { 1545, 0x0000 }, { 1545, 0x0d04 }, + { 1549, 0x0000 }, { 1549, 0x0400 }, { 1550, 0x0000 }, { 1550, 0x1002 }, + { 1552, 0x2000 }, { 1553, 0x0002 }, { 1554, 0x8000 }, { 1555, 0x0050 }, + { 1557, 0x0001 }, { 1558, 0x2008 }, { 1560, 0x04a2 }, { 1564, 0x0000 }, + /* 0x6500 */ + { 1564, 0x0400 }, { 1565, 0xc002 }, { 1568, 0x0000 }, { 1568, 0x0031 }, + { 1571, 0x2000 }, { 1572, 0x8000 }, { 1573, 0x2800 }, { 1575, 0x0000 }, + { 1575, 0x0360 }, { 1579, 0x0000 }, { 1579, 0x0000 }, { 1579, 0x4020 }, + { 1581, 0x0000 }, { 1581, 0x0012 }, { 1583, 0x0009 }, { 1585, 0x8000 }, + /* 0x6600 */ + { 1586, 0x0000 }, { 1586, 0x4100 }, { 1588, 0x0008 }, { 1589, 0x0001 }, + { 1590, 0x0910 }, { 1593, 0x0088 }, { 1595, 0x0888 }, { 1598, 0x2008 }, + { 1600, 0x4020 }, { 1602, 0x0404 }, { 1604, 0x2010 }, { 1606, 0x8048 }, + { 1609, 0x6000 }, { 1611, 0x0000 }, { 1611, 0x0000 }, { 1611, 0x0002 }, + /* 0x6700 */ + { 1612, 0x5004 }, { 1615, 0x4040 }, { 1617, 0x0020 }, { 1618, 0x0040 }, + { 1619, 0x0010 }, { 1620, 0x0000 }, { 1620, 0x0086 }, { 1623, 0x0000 }, + { 1623, 0x8000 }, { 1624, 0x0000 }, { 1624, 0x1011 }, { 1627, 0x8002 }, + { 1629, 0x0000 }, { 1629, 0x00c0 }, { 1631, 0x0000 }, { 1631, 0x4200 }, + /* 0x6800 */ + { 1633, 0x201f }, { 1639, 0x4801 }, { 1642, 0x0004 }, { 1643, 0x40c0 }, + { 1646, 0x0480 }, { 1648, 0x2060 }, { 1651, 0x0020 }, { 1652, 0x0000 }, + { 1652, 0x0110 }, { 1654, 0x0100 }, { 1655, 0x0040 }, { 1656, 0x2240 }, + { 1659, 0x0428 }, { 1662, 0x0000 }, { 1662, 0x0000 }, { 1662, 0x0000 }, + /* 0x6900 */ + { 1662, 0x020f }, { 1667, 0x0d00 }, { 1670, 0x1000 }, { 1671, 0x4040 }, + { 1673, 0x0048 }, { 1675, 0x0020 }, { 1676, 0x0092 }, { 1679, 0x000c }, + { 1681, 0x0421 }, { 1684, 0x8100 }, { 1686, 0x0004 }, { 1687, 0x0004 }, + { 1688, 0x0001 }, { 1689, 0x0062 }, { 1692, 0x0202 }, { 1694, 0x0600 }, + /* 0x6a00 */ + { 1696, 0x1808 }, { 1699, 0x1400 }, { 1701, 0x3800 }, { 1704, 0x0008 }, + { 1705, 0x1020 }, { 1707, 0x008c }, { 1710, 0x0020 }, { 1711, 0x0412 }, + { 1714, 0x8404 }, { 1717, 0x2200 }, { 1719, 0x0880 }, { 1721, 0x4026 }, + { 1725, 0x0700 }, { 1728, 0x0110 }, { 1730, 0x0000 }, { 1730, 0x0040 }, + /* 0x6b00 */ + { 1731, 0x0020 }, { 1732, 0x2000 }, { 1733, 0x0000 }, { 1733, 0x0020 }, + { 1734, 0x0000 }, { 1734, 0x0084 }, { 1736, 0x8000 }, { 1737, 0x0410 }, + { 1739, 0x0002 }, { 1740, 0x0000 }, { 1740, 0x0000 }, { 1740, 0x0000 }, + { 1740, 0x0002 }, { 1741, 0x1000 }, { 1742, 0x0402 }, { 1744, 0x0400 }, + /* 0x6c00 */ + { 1745, 0x0000 }, { 1745, 0x1000 }, { 1746, 0x0000 }, { 1746, 0x26a2 }, + { 1752, 0x0200 }, { 1753, 0x0500 }, { 1755, 0x4000 }, { 1756, 0x8220 }, + { 1759, 0x0000 }, { 1759, 0x8000 }, { 1760, 0x8404 }, { 1763, 0x0004 }, + { 1764, 0x4800 }, { 1766, 0x8000 }, { 1767, 0x0400 }, { 1768, 0x0000 }, + /* 0x6d00 */ + { 1768, 0x0064 }, { 1771, 0x0000 }, { 1771, 0x0050 }, { 1773, 0x0000 }, + { 1773, 0x4000 }, { 1774, 0x1880 }, { 1777, 0x0000 }, { 1777, 0x0006 }, + { 1779, 0x8002 }, { 1781, 0x0040 }, { 1782, 0x0030 }, { 1784, 0x0202 }, + { 1786, 0x0000 }, { 1786, 0x0000 }, { 1786, 0x0000 }, { 1786, 0x0000 }, + /* 0x6e00 */ + { 1786, 0x8414 }, { 1790, 0x0120 }, { 1792, 0x0600 }, { 1794, 0x0000 }, + { 1794, 0x8000 }, { 1795, 0x0201 }, { 1797, 0x0000 }, { 1797, 0x1040 }, + { 1799, 0x0840 }, { 1801, 0x0400 }, { 1802, 0x0000 }, { 1802, 0x0920 }, + { 1805, 0x0000 }, { 1805, 0x2e00 }, { 1809, 0x0304 }, { 1812, 0x0400 }, + /* 0x6f00 */ + { 1813, 0x1810 }, { 1816, 0x00c0 }, { 1818, 0x0010 }, { 1819, 0x2010 }, + { 1821, 0x0010 }, { 1822, 0x1040 }, { 1824, 0x0000 }, { 1824, 0x0210 }, + { 1826, 0x0402 }, { 1828, 0xa000 }, { 1830, 0x0000 }, { 1830, 0x4820 }, + { 1833, 0x0000 }, { 1833, 0x0608 }, { 1836, 0x0000 }, { 1836, 0x0140 }, + /* 0x7000 */ + { 1838, 0x0008 }, { 1839, 0x4000 }, { 1840, 0x1000 }, { 1841, 0x0000 }, + { 1841, 0x0800 }, { 1842, 0x1011 }, { 1845, 0x9080 }, { 1848, 0xc220 }, + { 1852, 0x8a02 }, { 1856, 0x0000 }, { 1856, 0x00e9 }, { 1861, 0x3a00 }, + { 1865, 0x1011 }, { 1868, 0x8061 }, { 1872, 0x0000 }, { 1872, 0x4022 }, + /* 0x7100 */ + { 1875, 0x0020 }, { 1876, 0x2000 }, { 1877, 0x1a00 }, { 1880, 0x4838 }, + { 1885, 0x8421 }, { 1889, 0x0002 }, { 1890, 0x0800 }, { 1891, 0x54ea }, + { 1899, 0x5100 }, { 1902, 0x0140 }, { 1904, 0x200c }, { 1907, 0x0490 }, + { 1910, 0x0000 }, { 1910, 0x2002 }, { 1912, 0x0800 }, { 1913, 0x0060 }, + /* 0x7200 */ + { 1915, 0xc200 }, { 1918, 0x00e0 }, { 1921, 0x4810 }, { 1924, 0x0000 }, + { 1924, 0x0001 }, { 1925, 0x10a1 }, { 1929, 0x0040 }, { 1930, 0x0000 }, + { 1930, 0x8084 }, { 1933, 0x8010 }, { 1935, 0x2000 }, { 1936, 0x0004 }, + { 1937, 0x2000 }, { 1938, 0x0000 }, { 1938, 0x0004 }, { 1939, 0x0000 }, + /* 0x7300 */ + { 1939, 0x0014 }, { 1941, 0x0001 }, { 1942, 0x5d00 }, { 1947, 0x0300 }, + { 1949, 0x8102 }, { 1952, 0x0000 }, { 1952, 0x0000 }, { 1952, 0x0012 }, + { 1954, 0x8000 }, { 1955, 0x5100 }, { 1958, 0x0480 }, { 1960, 0x0000 }, + { 1960, 0xc200 }, { 1963, 0x0021 }, { 1965, 0x8056 }, { 1970, 0x0a88 }, + /* 0x7400 */ + { 1974, 0x0000 }, { 1974, 0xd2b6 }, { 1983, 0x0000 }, { 1983, 0x1380 }, + { 1987, 0x03a8 }, { 1992, 0x2048 }, { 1995, 0x1921 }, { 2000, 0x0450 }, + { 2003, 0x3004 }, { 2006, 0x0a00 }, { 2008, 0x0010 }, { 2009, 0x0010 }, + { 2010, 0x1100 }, { 2012, 0x0009 }, { 2014, 0x0080 }, { 2015, 0x0107 }, + /* 0x7500 */ + { 2019, 0x4020 }, { 2021, 0x4200 }, { 2023, 0x0000 }, { 2023, 0x0830 }, + { 2026, 0x2444 }, { 2030, 0x002a }, { 2033, 0x6081 }, { 2037, 0x0404 }, + { 2039, 0x6008 }, { 2042, 0x4004 }, { 2044, 0x0000 }, { 2044, 0x0012 }, + { 2046, 0x0108 }, { 2048, 0x1000 }, { 2049, 0x0000 }, { 2049, 0x0000 }, + /* 0x7600 */ + { 2049, 0x0084 }, { 2051, 0x0000 }, { 2051, 0x1000 }, { 2052, 0x0800 }, + { 2053, 0xe001 }, { 2057, 0x0012 }, { 2059, 0x80c0 }, { 2062, 0x0458 }, + { 2066, 0x0000 }, { 2066, 0x0001 }, { 2067, 0x0022 }, { 2069, 0x0080 }, + { 2070, 0x1000 }, { 2071, 0x0040 }, { 2072, 0x0000 }, { 2072, 0x0000 }, + /* 0x7700 */ + { 2072, 0xd000 }, { 2075, 0x4000 }, { 2076, 0x0850 }, { 2079, 0x0000 }, + { 2079, 0x0009 }, { 2081, 0x0100 }, { 2082, 0x0000 }, { 2082, 0x0d84 }, + { 2087, 0x0000 }, { 2087, 0x0108 }, { 2089, 0x8000 }, { 2090, 0x4200 }, + { 2092, 0x0828 }, { 2095, 0x0000 }, { 2095, 0x0040 }, { 2096, 0x4010 }, + /* 0x7800 */ + { 2098, 0x0100 }, { 2099, 0x5100 }, { 2102, 0x0000 }, { 2102, 0x3200 }, + { 2105, 0x0894 }, { 2109, 0x001a }, { 2112, 0x0040 }, { 2113, 0x0400 }, + { 2114, 0x2102 }, { 2117, 0x0000 }, { 2117, 0x8000 }, { 2118, 0x0342 }, + { 2122, 0x0080 }, { 2123, 0x018c }, { 2127, 0x4000 }, { 2128, 0x0023 }, + /* 0x7900 */ + { 2131, 0x0040 }, { 2132, 0x0000 }, { 2132, 0x4000 }, { 2133, 0x185c }, + { 2139, 0x0000 }, { 2139, 0x0300 }, { 2141, 0x0004 }, { 2142, 0x4002 }, + { 2144, 0x00c9 }, { 2148, 0xa202 }, { 2152, 0x0220 }, { 2154, 0x0000 }, + { 2154, 0x1050 }, { 2157, 0x0010 }, { 2158, 0x0004 }, { 2159, 0x0012 }, + /* 0x7a00 */ + { 2161, 0x0040 }, { 2162, 0x0000 }, { 2162, 0x2000 }, { 2163, 0x4400 }, + { 2165, 0x0228 }, { 2168, 0x0000 }, { 2168, 0x0020 }, { 2169, 0x2000 }, + { 2170, 0x0008 }, { 2171, 0x0002 }, { 2172, 0x0000 }, { 2172, 0x1801 }, + { 2175, 0x830c }, { 2180, 0x3c08 }, { 2185, 0x0684 }, { 2189, 0x4000 }, + /* 0x7b00 */ + { 2190, 0x1800 }, { 2192, 0x8010 }, { 2194, 0x0280 }, { 2196, 0x0200 }, + { 2197, 0x000c }, { 2199, 0x0020 }, { 2200, 0x9004 }, { 2203, 0x0800 }, + { 2204, 0x0000 }, { 2204, 0x0004 }, { 2205, 0x000c }, { 2207, 0x0004 }, + { 2208, 0x8000 }, { 2209, 0x0001 }, { 2210, 0x0000 }, { 2210, 0x1400 }, + /* 0x7c00 */ + { 2212, 0x0000 }, { 2212, 0x0824 }, { 2215, 0x0000 }, { 2215, 0x0020 }, + { 2216, 0x0014 }, { 2218, 0x2042 }, { 2221, 0x2000 }, { 2222, 0x5811 }, + { 2227, 0x4048 }, { 2230, 0x1000 }, { 2231, 0x50c0 }, { 2235, 0x0100 }, + { 2236, 0x2284 }, { 2240, 0x0408 }, { 2242, 0x2040 }, { 2244, 0x1228 }, + /* 0x7d00 */ + { 2248, 0x0000 }, { 2248, 0x0000 }, { 2248, 0x0020 }, { 2249, 0x0000 }, + { 2249, 0x2000 }, { 2250, 0x2400 }, { 2252, 0x0000 }, { 2252, 0x0000 }, + { 2252, 0x0200 }, { 2253, 0x0080 }, { 2254, 0x0910 }, { 2257, 0x0008 }, + { 2258, 0xa000 }, { 2260, 0x1019 }, { 2264, 0x0030 }, { 2266, 0x6020 }, + /* 0x7e00 */ + { 2269, 0x0080 }, { 2270, 0x0000 }, { 2270, 0x0080 }, { 2271, 0x0000 }, + { 2271, 0x0000 }, { 2271, 0x0000 }, { 2271, 0x40a0 }, { 2274, 0x8000 }, + { 2275, 0x4000 }, { 2276, 0x8004 }, { 2278, 0x1010 }, { 2280, 0x0400 }, + { 2281, 0x8080 }, { 2283, 0x8000 }, { 2284, 0x0000 }, { 2284, 0x0000 }, + /* 0x7f00 */ + { 2284, 0x0040 }, { 2285, 0x0000 }, { 2285, 0x0000 }, { 2285, 0x0080 }, + { 2286, 0x4283 }, { 2291, 0x000c }, { 2293, 0x0000 }, { 2293, 0x0102 }, + { 2295, 0x8000 }, { 2296, 0x0088 }, { 2298, 0x4008 }, { 2300, 0x0010 }, + { 2301, 0x0000 }, { 2301, 0x2000 }, { 2302, 0x0080 }, { 2303, 0x0400 }, + /* 0x8000 */ + { 2304, 0x0104 }, { 2306, 0x2000 }, { 2307, 0xc021 }, { 2311, 0x1802 }, + { 2314, 0x0000 }, { 2314, 0x0810 }, { 2316, 0x004e }, { 2320, 0x0000 }, + { 2320, 0x0001 }, { 2321, 0x8000 }, { 2322, 0x0080 }, { 2323, 0x30c0 }, + { 2327, 0x0040 }, { 2328, 0x0000 }, { 2328, 0x1200 }, { 2330, 0x0040 }, + /* 0x8100 */ + { 2331, 0x5288 }, { 2336, 0x0494 }, { 2340, 0x0400 }, { 2341, 0x0094 }, + { 2344, 0x0104 }, { 2346, 0x0640 }, { 2349, 0x2000 }, { 2350, 0x1000 }, + { 2351, 0x0010 }, { 2352, 0x0008 }, { 2353, 0x0420 }, { 2355, 0x0040 }, + { 2356, 0x0102 }, { 2358, 0x0000 }, { 2358, 0x8010 }, { 2360, 0x0040 }, + /* 0x8200 */ + { 2361, 0x0000 }, { 2361, 0x0500 }, { 2363, 0x2240 }, { 2366, 0x4000 }, + { 2367, 0x0000 }, { 2367, 0x0010 }, { 2368, 0x0024 }, { 2370, 0x0e40 }, + { 2374, 0x0080 }, { 2375, 0x0000 }, { 2375, 0x0440 }, { 2377, 0x0000 }, + { 2377, 0x8410 }, { 2380, 0x0101 }, { 2382, 0x4004 }, { 2384, 0xb080 }, + /* 0x8300 */ + { 2388, 0x0800 }, { 2389, 0x2500 }, { 2392, 0x0000 }, { 2392, 0x2000 }, + { 2393, 0x0000 }, { 2393, 0x0080 }, { 2394, 0x804c }, { 2398, 0x0000 }, + { 2398, 0x0020 }, { 2399, 0x1002 }, { 2401, 0x1000 }, { 2402, 0x4200 }, + { 2404, 0x2000 }, { 2405, 0x0008 }, { 2406, 0x2000 }, { 2407, 0x0000 }, + /* 0x8400 */ + { 2407, 0x0020 }, { 2408, 0x1150 }, { 2412, 0x4053 }, { 2417, 0x4000 }, + { 2418, 0x0500 }, { 2420, 0x1128 }, { 2424, 0x0014 }, { 2426, 0x8006 }, + { 2429, 0x0101 }, { 2431, 0x004c }, { 2434, 0x2008 }, { 2436, 0x6000 }, + { 2438, 0x0000 }, { 2438, 0x4400 }, { 2440, 0x0036 }, { 2444, 0x0100 }, + /* 0x8500 */ + { 2445, 0x0028 }, { 2447, 0x0001 }, { 2448, 0x0000 }, { 2448, 0x0118 }, + { 2451, 0x1804 }, { 2454, 0x0404 }, { 2456, 0x8000 }, { 2457, 0x0009 }, + { 2459, 0x0000 }, { 2459, 0x0000 }, { 2459, 0x0000 }, { 2459, 0x0000 }, + { 2459, 0x0002 }, { 2460, 0x0000 }, { 2460, 0x4001 }, { 2462, 0x1000 }, + /* 0x8600 */ + { 2463, 0x2004 }, { 2465, 0x0051 }, { 2468, 0x8100 }, { 2470, 0x0000 }, + { 2470, 0x0024 }, { 2472, 0x0000 }, { 2472, 0x1000 }, { 2473, 0x4004 }, + { 2475, 0x0000 }, { 2475, 0x0004 }, { 2476, 0x2001 }, { 2478, 0x0004 }, + { 2479, 0x0000 }, { 2479, 0x0000 }, { 2479, 0x8000 }, { 2480, 0x0000 }, + /* 0x8700 */ + { 2480, 0x0000 }, { 2480, 0x0000 }, { 2480, 0x0000 }, { 2480, 0x0000 }, + { 2480, 0x0000 }, { 2480, 0x0000 }, { 2480, 0x0000 }, { 2480, 0x2003 }, + { 2483, 0x1840 }, { 2486, 0x0000 }, { 2486, 0x0220 }, { 2488, 0x0002 }, + { 2489, 0x4002 }, { 2491, 0x0440 }, { 2493, 0x4000 }, { 2494, 0x0020 }, + /* 0x8800 */ + { 2495, 0x8010 }, { 2497, 0x0100 }, { 2498, 0x2080 }, { 2500, 0x0000 }, + { 2500, 0x8064 }, { 2504, 0x4000 }, { 2505, 0x4031 }, { 2509, 0x0000 }, + { 2509, 0x0090 }, { 2511, 0x1000 }, { 2512, 0x4001 }, { 2514, 0x8030 }, + { 2517, 0x80a0 }, { 2520, 0x0000 }, { 2520, 0x0040 }, { 2521, 0x8020 }, + /* 0x8900 */ + { 2523, 0x0001 }, { 2524, 0x0000 }, { 2524, 0x0010 }, { 2525, 0x0000 }, + { 2525, 0x2088 }, { 2528, 0x0010 }, { 2529, 0x0020 }, { 2530, 0x0080 }, + { 2531, 0x0681 }, { 2535, 0x0012 }, { 2537, 0x02a0 }, { 2540, 0x1000 }, + { 2541, 0x0042 }, { 2543, 0x0000 }, { 2543, 0x0080 }, { 2544, 0x0000 }, + /* 0x8a00 */ + { 2544, 0x0000 }, { 2544, 0x1000 }, { 2545, 0x0a00 }, { 2547, 0x2100 }, + { 2549, 0x0200 }, { 2550, 0x0000 }, { 2550, 0x0080 }, { 2551, 0x4000 }, + { 2552, 0x0000 }, { 2552, 0x1011 }, { 2555, 0x8200 }, { 2557, 0x0010 }, + { 2558, 0x0000 }, { 2558, 0x0400 }, { 2559, 0x0400 }, { 2560, 0x0000 }, + /* 0x8b00 */ + { 2560, 0x1000 }, { 2561, 0x8000 }, { 2562, 0x2000 }, { 2563, 0x8000 }, + { 2564, 0x3008 }, { 2567, 0x4000 }, { 2568, 0x0204 }, { 2570, 0x0000 }, + { 2570, 0x0002 }, { 2571, 0x0801 }, { 2573, 0x0001 }, { 2574, 0x4000 }, + { 2575, 0x0000 }, { 2575, 0x0000 }, { 2575, 0x0004 }, { 2576, 0x0000 }, + /* 0x8c00 */ + { 2576, 0x0000 }, { 2576, 0x0000 }, { 2576, 0x0000 }, { 2576, 0x0000 }, + { 2576, 0x0000 }, { 2576, 0x0002 }, { 2577, 0x0000 }, { 2577, 0x0000 }, + { 2577, 0x0000 }, { 2577, 0x8800 }, { 2579, 0x2000 }, { 2580, 0x0000 }, + { 2580, 0x2000 }, { 2581, 0x0850 }, { 2584, 0x0a00 }, { 2586, 0x0084 }, + /* 0x8d00 */ + { 2588, 0x1808 }, { 2591, 0x3106 }, { 2596, 0x0000 }, { 2596, 0x0000 }, + { 2596, 0x0000 }, { 2596, 0x0000 }, { 2596, 0x0000 }, { 2596, 0x0400 }, + { 2597, 0x0004 }, { 2598, 0x0000 }, { 2598, 0x0240 }, { 2600, 0x0000 }, + { 2600, 0x0009 }, { 2602, 0x0010 }, { 2603, 0x0000 }, { 2603, 0x0000 }, + /* 0x8e00 */ + { 2603, 0x4002 }, { 2605, 0x0000 }, { 2605, 0x2500 }, { 2608, 0x0400 }, + { 2609, 0x8040 }, { 2611, 0x0000 }, { 2611, 0x0100 }, { 2612, 0x40a2 }, + { 2616, 0x0001 }, { 2617, 0x0000 }, { 2617, 0x2080 }, { 2619, 0x1041 }, + { 2622, 0x4008 }, { 2624, 0x0400 }, { 2625, 0x2014 }, { 2628, 0x0004 }, + /* 0x8f00 */ + { 2629, 0x0000 }, { 2629, 0x0200 }, { 2630, 0x2000 }, { 2631, 0x0001 }, + { 2632, 0x0402 }, { 2634, 0x1000 }, { 2635, 0x40c0 }, { 2638, 0x0000 }, + { 2638, 0x0000 }, { 2638, 0x0008 }, { 2639, 0x0021 }, { 2641, 0x5fe8 }, + { 2651, 0x1402 }, { 2654, 0x0401 }, { 2656, 0x0000 }, { 2656, 0x0200 }, + /* 0x9000 */ + { 2657, 0x0100 }, { 2658, 0x0004 }, { 2659, 0x0000 }, { 2659, 0x0088 }, + { 2661, 0x1000 }, { 2662, 0x0040 }, { 2663, 0x1012 }, { 2666, 0x0000 }, + { 2666, 0x0000 }, { 2666, 0x0000 }, { 2666, 0x4100 }, { 2668, 0x0800 }, + { 2669, 0x0010 }, { 2670, 0x0000 }, { 2670, 0x0000 }, { 2670, 0x0000 }, + /* 0x9100 */ + { 2670, 0x0000 }, { 2670, 0x0000 }, { 2670, 0x0000 }, { 2670, 0x0000 }, + { 2670, 0x0000 }, { 2670, 0x5202 }, { 2674, 0x0080 }, { 2675, 0x1041 }, + { 2678, 0x5000 }, { 2680, 0x0000 }, { 2680, 0x0200 }, { 2681, 0x0840 }, + { 2683, 0x0010 }, { 2684, 0x8040 }, { 2686, 0x0020 }, { 2687, 0x4400 }, + /* 0x9200 */ + { 2689, 0x4100 }, { 2691, 0x0008 }, { 2692, 0x0d00 }, { 2695, 0x1020 }, + { 2697, 0x0012 }, { 2699, 0xa120 }, { 2703, 0x4804 }, { 2706, 0x0080 }, + { 2707, 0x8212 }, { 2711, 0x0000 }, { 2711, 0x4000 }, { 2712, 0xc602 }, + { 2717, 0x0000 }, { 2717, 0x0810 }, { 2719, 0x1828 }, { 2723, 0x205c }, + /* 0x9300 */ + { 2728, 0x0088 }, { 2730, 0x0000 }, { 2730, 0x1000 }, { 2731, 0x0003 }, + { 2733, 0x013f }, { 2740, 0x8000 }, { 2741, 0x4b44 }, { 2747, 0x2118 }, + { 2751, 0x00f2 }, { 2756, 0x1001 }, { 2758, 0x2001 }, { 2760, 0xa900 }, + { 2764, 0x0840 }, { 2766, 0x0808 }, { 2768, 0x0001 }, { 2769, 0x000b }, + /* 0x9400 */ + { 2772, 0x0112 }, { 2775, 0x2880 }, { 2778, 0x20f0 }, { 2783, 0x4000 }, + { 2784, 0x200c }, { 2787, 0x0910 }, { 2790, 0x10a0 }, { 2793, 0x0a00 }, + { 2795, 0x0020 }, { 2796, 0x8000 }, { 2797, 0x0004 }, { 2798, 0x0000 }, + { 2798, 0x000a }, { 2800, 0x1000 }, { 2801, 0x0000 }, { 2801, 0x0040 }, + /* 0x9500 */ + { 2802, 0x0000 }, { 2802, 0x0000 }, { 2802, 0x2000 }, { 2803, 0x0000 }, + { 2803, 0x0080 }, { 2804, 0x0000 }, { 2804, 0x0000 }, { 2804, 0x8100 }, + { 2806, 0x0020 }, { 2807, 0x02c0 }, { 2810, 0x04c5 }, { 2815, 0x0000 }, + { 2815, 0x0000 }, { 2815, 0x0000 }, { 2815, 0x0100 }, { 2816, 0x0010 }, + /* 0x9600 */ + { 2817, 0x0000 }, { 2817, 0x2000 }, { 2818, 0x0000 }, { 2818, 0x0108 }, + { 2820, 0x0022 }, { 2822, 0x0040 }, { 2823, 0x0200 }, { 2824, 0x0800 }, + { 2825, 0x8002 }, { 2827, 0x0040 }, { 2828, 0x0028 }, { 2830, 0x2040 }, + { 2832, 0x0000 }, { 2832, 0x0000 }, { 2832, 0x0000 }, { 2832, 0x0010 }, + /* 0x9700 */ + { 2833, 0x0008 }, { 2834, 0x0800 }, { 2835, 0x0002 }, { 2836, 0x0042 }, + { 2838, 0x0003 }, { 2840, 0xa082 }, { 2844, 0x2000 }, { 2845, 0x0002 }, + { 2846, 0x0280 }, { 2848, 0x8800 }, { 2850, 0x0000 }, { 2850, 0x6516 }, + { 2857, 0x0105 }, { 2860, 0x0004 }, { 2861, 0x4041 }, { 2864, 0x0024 }, + /* 0x9800 */ + { 2866, 0x0000 }, { 2866, 0x8030 }, { 2869, 0x4008 }, { 2871, 0x0018 }, + { 2873, 0x0880 }, { 2875, 0x0000 }, { 2875, 0x1040 }, { 2877, 0x0020 }, + { 2878, 0x0000 }, { 2878, 0x0000 }, { 2878, 0x0000 }, { 2878, 0x0290 }, + { 2881, 0x4588 }, { 2886, 0x5000 }, { 2888, 0x1043 }, { 2892, 0x0022 }, + /* 0x9900 */ + { 2894, 0x4000 }, { 2895, 0x1200 }, { 2897, 0x0000 }, { 2897, 0x0b80 }, + { 2901, 0x2405 }, { 2905, 0x2000 }, { 2906, 0x000c }, { 2908, 0x0000 }, + { 2908, 0x0000 }, { 2908, 0x0800 }, { 2909, 0x0410 }, { 2911, 0x1100 }, + { 2913, 0x0030 }, { 2915, 0x0400 }, { 2916, 0x0042 }, { 2918, 0x0020 }, + /* 0x9a00 */ + { 2919, 0x1000 }, { 2920, 0x8001 }, { 2922, 0x8042 }, { 2925, 0x1800 }, + { 2927, 0x0000 }, { 2927, 0x1100 }, { 2929, 0x1008 }, { 2931, 0x0000 }, + { 2931, 0x8000 }, { 2932, 0x0000 }, { 2932, 0x0000 }, { 2932, 0x2444 }, + { 2936, 0x0000 }, { 2936, 0x0080 }, { 2937, 0x0005 }, { 2939, 0x8010 }, + /* 0x9b00 */ + { 2941, 0x8204 }, { 2944, 0x0010 }, { 2945, 0x2400 }, { 2947, 0x0210 }, + { 2949, 0x0001 }, { 2950, 0x0001 }, { 2951, 0x0200 }, { 2952, 0x8000 }, + { 2953, 0xe80a }, { 2959, 0xa080 }, { 2962, 0x0000 }, { 2962, 0x0001 }, + { 2963, 0x8000 }, { 2964, 0x2000 }, { 2965, 0x2200 }, { 2967, 0x8012 }, + /* 0x9c00 */ + { 2970, 0x1404 }, { 2973, 0x8821 }, { 2977, 0x8041 }, { 2980, 0x0420 }, + { 2982, 0x8020 }, { 2984, 0x2008 }, { 2986, 0x0000 }, { 2986, 0x1804 }, + { 2989, 0x0000 }, { 2989, 0x0000 }, { 2989, 0x0000 }, { 2989, 0x0000 }, + { 2989, 0x0000 }, { 2989, 0x0000 }, { 2989, 0x0000 }, { 2989, 0x0000 }, + /* 0x9d00 */ + { 2989, 0x1004 }, { 2991, 0x0040 }, { 2992, 0x0002 }, { 2993, 0x0210 }, + { 2995, 0x4210 }, { 2998, 0x4001 }, { 3000, 0x6000 }, { 3002, 0x5000 }, + { 3004, 0x0008 }, { 3005, 0x0008 }, { 3006, 0x0820 }, { 3008, 0x2000 }, + { 3009, 0x0211 }, { 3012, 0x0010 }, { 3013, 0x0000 }, { 3013, 0x1000 }, + /* 0x9e00 */ + { 3014, 0x5400 }, { 3017, 0x9100 }, { 3020, 0x0000 }, { 3020, 0x0000 }, + { 3020, 0x0000 }, { 3020, 0x0000 }, { 3020, 0x0000 }, { 3020, 0x0800 }, + { 3021, 0x0032 }, { 3024, 0x4161 }, { 3029, 0x9d44 }, { 3036, 0xa002 }, + { 3039, 0x00d2 }, { 3043, 0x0000 }, { 3043, 0x0004 }, { 3044, 0x4102 }, + /* 0x9f00 */ + { 3047, 0x0104 }, { 3049, 0x0080 }, { 3050, 0x00c0 }, { 3052, 0x0200 }, + { 3053, 0x0030 }, { 3055, 0x0409 }, { 3058, 0x0204 }, { 3060, 0x8000 }, + { 3061, 0x4000 }, { 3062, 0x8200 }, { 3064, 0x0020 }, { 3065, 0x0003 }, +}; +static const Summary16 hkscs1999_uni2indx_pagef9[1] = { + /* 0xf900 */ + { 3067, 0x0080 }, +}; +static const Summary16 hkscs1999_uni2indx_pageff[15] = { + /* 0xff00 */ + { 3068, 0x0084 }, { 3070, 0x0000 }, { 3070, 0x0000 }, { 3070, 0x2800 }, + { 3072, 0x0000 }, { 3072, 0x0000 }, { 3072, 0x0000 }, { 3072, 0x0000 }, + { 3072, 0x0000 }, { 3072, 0x0000 }, { 3072, 0x0000 }, { 3072, 0x0000 }, + { 3072, 0x0000 }, { 3072, 0x0000 }, { 3072, 0x2014 }, +}; +static const Summary16 hkscs1999_uni2indx_page200[2335] = { + /* 0x20000 */ + { 3075, 0x0000 }, { 3075, 0x0000 }, { 3075, 0x0002 }, { 3076, 0x4000 }, + { 3077, 0x4040 }, { 3079, 0x0000 }, { 3079, 0x0100 }, { 3080, 0x0000 }, + { 3080, 0x04c0 }, { 3083, 0x0010 }, { 3084, 0x0000 }, { 3084, 0x0000 }, + { 3084, 0x3c00 }, { 3088, 0x0002 }, { 3089, 0x4000 }, { 3090, 0x0000 }, + /* 0x20100 */ + { 3090, 0x5000 }, { 3092, 0x0100 }, { 3093, 0x0000 }, { 3093, 0x0000 }, + { 3093, 0x0000 }, { 3093, 0x0000 }, { 3093, 0x0000 }, { 3093, 0x0000 }, + { 3093, 0x0000 }, { 3093, 0x0000 }, { 3093, 0x0a00 }, { 3095, 0x0000 }, + { 3095, 0x0002 }, { 3096, 0x0010 }, { 3097, 0x0000 }, { 3097, 0x0004 }, + /* 0x20200 */ + { 3098, 0x1010 }, { 3100, 0x0010 }, { 3101, 0x0000 }, { 3101, 0x0000 }, + { 3101, 0x0000 }, { 3101, 0x0800 }, { 3102, 0x0000 }, { 3102, 0x0030 }, + { 3104, 0x0000 }, { 3104, 0x4200 }, { 3106, 0x0001 }, { 3107, 0x8080 }, + { 3109, 0x0001 }, { 3110, 0x0000 }, { 3110, 0x0020 }, { 3111, 0x0000 }, + /* 0x20300 */ + { 3111, 0x0400 }, { 3112, 0x0000 }, { 3112, 0x0020 }, { 3113, 0x0000 }, + { 3113, 0x00e2 }, { 3117, 0x0000 }, { 3117, 0x0000 }, { 3117, 0xc000 }, + { 3119, 0x0001 }, { 3120, 0x0000 }, { 3120, 0x0081 }, { 3122, 0x0020 }, + { 3123, 0x0a00 }, { 3125, 0x0000 }, { 3125, 0x0000 }, { 3125, 0x1020 }, + /* 0x20400 */ + { 3127, 0x0000 }, { 3127, 0x8018 }, { 3130, 0x0000 }, { 3130, 0x0000 }, + { 3130, 0x0000 }, { 3130, 0x0000 }, { 3130, 0x0020 }, { 3131, 0x0000 }, + { 3131, 0x4080 }, { 3133, 0x0006 }, { 3135, 0x0008 }, { 3136, 0x0000 }, + { 3136, 0x0000 }, { 3136, 0x0080 }, { 3137, 0x0000 }, { 3137, 0x5000 }, + /* 0x20500 */ + { 3139, 0x0000 }, { 3139, 0x0000 }, { 3139, 0x0000 }, { 3139, 0x0000 }, + { 3139, 0x0080 }, { 3140, 0x0000 }, { 3140, 0x0000 }, { 3140, 0x0000 }, + { 3140, 0x4000 }, { 3141, 0x0000 }, { 3141, 0x0020 }, { 3142, 0x0008 }, + { 3143, 0x0408 }, { 3145, 0x8021 }, { 3148, 0x0801 }, { 3150, 0x0000 }, + /* 0x20600 */ + { 3150, 0x0000 }, { 3150, 0x0622 }, { 3154, 0x0000 }, { 3154, 0x0001 }, + { 3155, 0x0000 }, { 3155, 0x0040 }, { 3156, 0x0000 }, { 3156, 0x0040 }, + { 3157, 0x0000 }, { 3157, 0x0000 }, { 3157, 0x0000 }, { 3157, 0x0000 }, + { 3157, 0x0000 }, { 3157, 0x0000 }, { 3157, 0x0000 }, { 3157, 0x0000 }, + /* 0x20700 */ + { 3157, 0x4000 }, { 3158, 0x0000 }, { 3158, 0x0000 }, { 3158, 0x0002 }, + { 3159, 0x0000 }, { 3159, 0x0000 }, { 3159, 0x0000 }, { 3159, 0x0200 }, + { 3160, 0x0000 }, { 3160, 0x0000 }, { 3160, 0x0000 }, { 3160, 0x0000 }, + { 3160, 0x0000 }, { 3160, 0x0000 }, { 3160, 0x0000 }, { 3160, 0x0000 }, + /* 0x20800 */ + { 3160, 0x0000 }, { 3160, 0x0000 }, { 3160, 0x1000 }, { 3161, 0x0000 }, + { 3161, 0x0000 }, { 3161, 0x0000 }, { 3161, 0x0000 }, { 3161, 0x0008 }, + { 3162, 0x0000 }, { 3162, 0x0000 }, { 3162, 0x0000 }, { 3162, 0x0000 }, + { 3162, 0x0000 }, { 3162, 0x0020 }, { 3163, 0x0000 }, { 3163, 0x0000 }, + /* 0x20900 */ + { 3163, 0x0000 }, { 3163, 0x0040 }, { 3164, 0x0008 }, { 3165, 0x0000 }, + { 3165, 0x0000 }, { 3165, 0x0010 }, { 3166, 0x0000 }, { 3166, 0x0200 }, + { 3167, 0x0000 }, { 3167, 0x0000 }, { 3167, 0x0000 }, { 3167, 0x0000 }, + { 3167, 0x0000 }, { 3167, 0x0000 }, { 3167, 0x0080 }, { 3168, 0x0000 }, + /* 0x20a00 */ + { 3168, 0x0000 }, { 3168, 0x0002 }, { 3169, 0x0000 }, { 3169, 0x0000 }, + { 3169, 0x0000 }, { 3169, 0x0001 }, { 3170, 0x0000 }, { 3170, 0x0000 }, + { 3170, 0x0000 }, { 3170, 0x0000 }, { 3170, 0x0000 }, { 3170, 0x0010 }, + { 3171, 0x2004 }, { 3173, 0x0000 }, { 3173, 0x0000 }, { 3173, 0x0000 }, + /* 0x20b00 */ + { 3173, 0x2000 }, { 3174, 0x0000 }, { 3174, 0x0000 }, { 3174, 0x0000 }, + { 3174, 0x0000 }, { 3174, 0x0000 }, { 3174, 0x0000 }, { 3174, 0x0000 }, + { 3174, 0x8000 }, { 3175, 0x0000 }, { 3175, 0x0300 }, { 3177, 0x8000 }, + { 3178, 0x0840 }, { 3180, 0x0000 }, { 3180, 0x0804 }, { 3182, 0x8800 }, + /* 0x20c00 */ + { 3184, 0x2800 }, { 3186, 0x0000 }, { 3186, 0x0001 }, { 3187, 0x0c10 }, + { 3190, 0x000e }, { 3193, 0x0008 }, { 3194, 0x0020 }, { 3195, 0x1180 }, + { 3198, 0x2000 }, { 3199, 0x1040 }, { 3201, 0x0000 }, { 3201, 0x0120 }, + { 3203, 0x8000 }, { 3204, 0x2078 }, { 3209, 0x2000 }, { 3210, 0x8000 }, + /* 0x20d00 */ + { 3211, 0x0000 }, { 3211, 0x0020 }, { 3212, 0x0100 }, { 3213, 0x0006 }, + { 3215, 0x73c0 }, { 3222, 0x0000 }, { 3222, 0x8000 }, { 3223, 0xd012 }, + { 3228, 0x0000 }, { 3228, 0x1040 }, { 3230, 0x0080 }, { 3231, 0x0004 }, + { 3232, 0x0100 }, { 3233, 0x0000 }, { 3233, 0x0000 }, { 3233, 0x0000 }, + /* 0x20e00 */ + { 3233, 0xe610 }, { 3239, 0x2043 }, { 3243, 0x0000 }, { 3243, 0x0000 }, + { 3243, 0x1000 }, { 3244, 0x0000 }, { 3244, 0x2000 }, { 3245, 0x0fe8 }, + { 3253, 0x1000 }, { 3254, 0x2140 }, { 3257, 0x1c04 }, { 3261, 0x0040 }, + { 3262, 0x0000 }, { 3262, 0x2180 }, { 3265, 0x0000 }, { 3265, 0x0f00 }, + /* 0x20f00 */ + { 3269, 0x0000 }, { 3269, 0x2000 }, { 3270, 0x6040 }, { 3273, 0x0803 }, + { 3276, 0x1000 }, { 3277, 0x0000 }, { 3277, 0x0010 }, { 3278, 0x0000 }, + { 3278, 0x2000 }, { 3279, 0x0001 }, { 3280, 0x2000 }, { 3281, 0x1070 }, + { 3285, 0x0000 }, { 3285, 0x8000 }, { 3286, 0x3c00 }, { 3290, 0x0000 }, + /* 0x21000 */ + { 3290, 0x0000 }, { 3290, 0x6010 }, { 3293, 0x0000 }, { 3293, 0x0000 }, + { 3293, 0x8000 }, { 3294, 0x1000 }, { 3295, 0x8000 }, { 3296, 0x09e0 }, + { 3301, 0x0100 }, { 3302, 0x2040 }, { 3304, 0x0000 }, { 3304, 0x8010 }, + { 3306, 0x8383 }, { 3312, 0x0008 }, { 3313, 0x0010 }, { 3314, 0x0070 }, + /* 0x21100 */ + { 3317, 0x0000 }, { 3317, 0x0000 }, { 3317, 0x8000 }, { 3318, 0x2800 }, + { 3320, 0x8120 }, { 3323, 0x0000 }, { 3323, 0x0000 }, { 3323, 0x0000 }, + { 3323, 0x0081 }, { 3325, 0x0000 }, { 3325, 0x0000 }, { 3325, 0x0000 }, + { 3325, 0x0000 }, { 3325, 0x0200 }, { 3326, 0x0000 }, { 3326, 0x0000 }, + /* 0x21200 */ + { 3326, 0x0000 }, { 3326, 0x0000 }, { 3326, 0x0000 }, { 3326, 0x1000 }, + { 3327, 0x8000 }, { 3328, 0x0000 }, { 3328, 0x0000 }, { 3328, 0x1000 }, + { 3329, 0x0000 }, { 3329, 0x0000 }, { 3329, 0x0300 }, { 3331, 0x0001 }, + { 3332, 0x0000 }, { 3332, 0x0000 }, { 3332, 0x0008 }, { 3333, 0x4000 }, + /* 0x21300 */ + { 3334, 0x003c }, { 3338, 0x0000 }, { 3338, 0x0000 }, { 3338, 0x0440 }, + { 3340, 0x0000 }, { 3340, 0x0000 }, { 3340, 0x0000 }, { 3340, 0x0060 }, + { 3342, 0x4000 }, { 3343, 0x1100 }, { 3345, 0x0000 }, { 3345, 0x0000 }, + { 3345, 0x0060 }, { 3347, 0x0000 }, { 3347, 0x2000 }, { 3348, 0x4000 }, + /* 0x21400 */ + { 3349, 0x0000 }, { 3349, 0x0048 }, { 3351, 0x0010 }, { 3352, 0x0000 }, + { 3352, 0x0000 }, { 3352, 0x0034 }, { 3355, 0x0000 }, { 3355, 0x0000 }, + { 3355, 0x0400 }, { 3356, 0x0080 }, { 3357, 0x0000 }, { 3357, 0x0040 }, + { 3358, 0x0000 }, { 3358, 0x0000 }, { 3358, 0x0100 }, { 3359, 0x2000 }, + /* 0x21500 */ + { 3360, 0x0000 }, { 3360, 0x0000 }, { 3360, 0x0000 }, { 3360, 0x0000 }, + { 3360, 0x0000 }, { 3360, 0x0000 }, { 3360, 0x0000 }, { 3360, 0x0080 }, + { 3361, 0x0004 }, { 3362, 0x0040 }, { 3363, 0x0000 }, { 3363, 0x0000 }, + { 3363, 0x0000 }, { 3363, 0x0000 }, { 3363, 0x0000 }, { 3363, 0x0000 }, + /* 0x21600 */ + { 3363, 0x0400 }, { 3364, 0x0208 }, { 3366, 0x0000 }, { 3366, 0x4000 }, + { 3367, 0x0000 }, { 3367, 0x0000 }, { 3367, 0x0002 }, { 3368, 0x0000 }, + { 3368, 0x0000 }, { 3368, 0x0004 }, { 3369, 0x0000 }, { 3369, 0x0500 }, + { 3371, 0x0007 }, { 3374, 0x8028 }, { 3377, 0x01c0 }, { 3380, 0x5c00 }, + /* 0x21700 */ + { 3384, 0x2000 }, { 3385, 0x0001 }, { 3386, 0x0040 }, { 3387, 0x1c00 }, + { 3390, 0x0000 }, { 3390, 0x0080 }, { 3391, 0xf000 }, { 3395, 0x001b }, + { 3399, 0x0000 }, { 3399, 0x0000 }, { 3399, 0x0800 }, { 3400, 0x003f }, + { 3406, 0x0088 }, { 3408, 0x9e00 }, { 3413, 0x8000 }, { 3414, 0x1f60 }, + /* 0x21800 */ + { 3421, 0x0000 }, { 3421, 0x0000 }, { 3421, 0x2701 }, { 3426, 0x0e00 }, + { 3429, 0x0021 }, { 3431, 0x4004 }, { 3433, 0x001e }, { 3437, 0x0880 }, + { 3439, 0x0038 }, { 3442, 0xc000 }, { 3444, 0x0007 }, { 3447, 0xc000 }, + { 3449, 0x0000 }, { 3449, 0x03c2 }, { 3454, 0x0000 }, { 3454, 0x0400 }, + /* 0x21900 */ + { 3455, 0x0038 }, { 3458, 0x1027 }, { 3463, 0x0084 }, { 3465, 0x0800 }, + { 3466, 0x0010 }, { 3467, 0x0100 }, { 3468, 0x0400 }, { 3469, 0x1000 }, + { 3470, 0x0108 }, { 3472, 0x0040 }, { 3473, 0x0000 }, { 3473, 0x0000 }, + { 3473, 0x0000 }, { 3473, 0x0800 }, { 3474, 0x0000 }, { 3474, 0x0008 }, + /* 0x21a00 */ + { 3475, 0x0000 }, { 3475, 0x0000 }, { 3475, 0x2000 }, { 3476, 0x0010 }, + { 3477, 0x0820 }, { 3479, 0x0000 }, { 3479, 0x0000 }, { 3479, 0x0000 }, + { 3479, 0x0000 }, { 3479, 0x0000 }, { 3479, 0x0000 }, { 3479, 0x0000 }, + { 3479, 0x0000 }, { 3479, 0x0000 }, { 3479, 0x0000 }, { 3479, 0x0000 }, + /* 0x21b00 */ + { 3479, 0x0000 }, { 3479, 0x0000 }, { 3479, 0x0000 }, { 3479, 0x0000 }, + { 3479, 0x0010 }, { 3480, 0x0000 }, { 3480, 0x0000 }, { 3480, 0x0000 }, + { 3480, 0x0000 }, { 3480, 0x0000 }, { 3480, 0x0000 }, { 3480, 0x0000 }, + { 3480, 0x0006 }, { 3482, 0x0000 }, { 3482, 0x0000 }, { 3482, 0x0000 }, + /* 0x21c00 */ + { 3482, 0x0000 }, { 3482, 0x0000 }, { 3482, 0x0400 }, { 3483, 0x0000 }, + { 3483, 0x0000 }, { 3483, 0x0000 }, { 3483, 0x0000 }, { 3483, 0x0001 }, + { 3484, 0x0000 }, { 3484, 0x0000 }, { 3484, 0x1024 }, { 3487, 0x0000 }, + { 3487, 0x0000 }, { 3487, 0x0000 }, { 3487, 0x0000 }, { 3487, 0x0000 }, + /* 0x21d00 */ + { 3487, 0x0000 }, { 3487, 0x0000 }, { 3487, 0x0000 }, { 3487, 0x0000 }, + { 3487, 0x0040 }, { 3488, 0x0000 }, { 3488, 0x0000 }, { 3488, 0x0000 }, + { 3488, 0x0000 }, { 3488, 0x0001 }, { 3489, 0x0000 }, { 3489, 0x0400 }, + { 3490, 0x0400 }, { 3491, 0x0002 }, { 3492, 0x0800 }, { 3493, 0x0200 }, + /* 0x21e00 */ + { 3494, 0x0000 }, { 3494, 0x1000 }, { 3495, 0x0000 }, { 3495, 0x2080 }, + { 3497, 0x0000 }, { 3497, 0x0000 }, { 3497, 0x0000 }, { 3497, 0x0000 }, + { 3497, 0x0200 }, { 3498, 0x0000 }, { 3498, 0x0110 }, { 3500, 0x0000 }, + { 3500, 0x0100 }, { 3501, 0x0020 }, { 3502, 0x0000 }, { 3502, 0x0000 }, + /* 0x21f00 */ + { 3502, 0x8000 }, { 3503, 0x0020 }, { 3504, 0x0000 }, { 3504, 0x0000 }, + { 3504, 0x0000 }, { 3504, 0x0000 }, { 3504, 0x0400 }, { 3505, 0x0000 }, + { 3505, 0x0000 }, { 3505, 0x4000 }, { 3506, 0x0002 }, { 3507, 0x0000 }, + { 3507, 0x0000 }, { 3507, 0x0000 }, { 3507, 0x0100 }, { 3508, 0x0000 }, + /* 0x22000 */ + { 3508, 0x0000 }, { 3508, 0x0000 }, { 3508, 0x0000 }, { 3508, 0x0000 }, + { 3508, 0x0220 }, { 3510, 0x0000 }, { 3510, 0x0000 }, { 3510, 0x0000 }, + { 3510, 0x0000 }, { 3510, 0x0400 }, { 3511, 0x0000 }, { 3511, 0x0000 }, + { 3511, 0x0080 }, { 3512, 0x0000 }, { 3512, 0x0000 }, { 3512, 0x1000 }, + /* 0x22100 */ + { 3513, 0x0000 }, { 3513, 0x0000 }, { 3513, 0x0400 }, { 3514, 0x0000 }, + { 3514, 0x0000 }, { 3514, 0x0800 }, { 3515, 0x0000 }, { 3515, 0x0408 }, + { 3517, 0x0000 }, { 3517, 0x0000 }, { 3517, 0x0002 }, { 3518, 0x0000 }, + { 3518, 0x0008 }, { 3519, 0x0000 }, { 3519, 0x0000 }, { 3519, 0x0000 }, + /* 0x22200 */ + { 3519, 0x0100 }, { 3520, 0x0000 }, { 3520, 0x0000 }, { 3520, 0x0000 }, + { 3520, 0x0000 }, { 3520, 0x0000 }, { 3520, 0x0000 }, { 3520, 0x1000 }, + { 3521, 0x0000 }, { 3521, 0x0000 }, { 3521, 0x0000 }, { 3521, 0x0000 }, + { 3521, 0x0000 }, { 3521, 0x0000 }, { 3521, 0x0000 }, { 3521, 0x0000 }, + /* 0x22300 */ + { 3521, 0x0000 }, { 3521, 0x0000 }, { 3521, 0x0022 }, { 3523, 0x0000 }, + { 3523, 0x0000 }, { 3523, 0x0000 }, { 3523, 0x0000 }, { 3523, 0x0000 }, + { 3523, 0x0000 }, { 3523, 0x0000 }, { 3523, 0x0000 }, { 3523, 0x2000 }, + { 3524, 0x0000 }, { 3524, 0x0081 }, { 3526, 0x0000 }, { 3526, 0x0400 }, + /* 0x22400 */ + { 3527, 0x0000 }, { 3527, 0x0000 }, { 3527, 0x0000 }, { 3527, 0x0000 }, + { 3527, 0x0000 }, { 3527, 0x0000 }, { 3527, 0x0020 }, { 3528, 0x0002 }, + { 3529, 0x0800 }, { 3530, 0x0002 }, { 3531, 0x0000 }, { 3531, 0x0001 }, + { 3532, 0x0000 }, { 3532, 0x0000 }, { 3532, 0x2000 }, { 3533, 0x0000 }, + /* 0x22500 */ + { 3533, 0x0000 }, { 3533, 0x0808 }, { 3535, 0x0000 }, { 3535, 0x0001 }, + { 3536, 0x0000 }, { 3536, 0x0010 }, { 3537, 0x0000 }, { 3537, 0x0000 }, + { 3537, 0x2000 }, { 3538, 0x0000 }, { 3538, 0x8000 }, { 3539, 0x4000 }, + { 3540, 0x0000 }, { 3540, 0x0000 }, { 3540, 0x0000 }, { 3540, 0x0000 }, + /* 0x22600 */ + { 3540, 0x0000 }, { 3540, 0x1800 }, { 3542, 0x0800 }, { 3543, 0x0000 }, + { 3543, 0x0000 }, { 3543, 0x0000 }, { 3543, 0x0100 }, { 3544, 0x0400 }, + { 3545, 0x0000 }, { 3545, 0x0140 }, { 3547, 0x0000 }, { 3547, 0x0000 }, + { 3547, 0x0000 }, { 3547, 0x0000 }, { 3547, 0x0000 }, { 3547, 0x0070 }, + /* 0x22700 */ + { 3550, 0x0000 }, { 3550, 0x8810 }, { 3553, 0x0400 }, { 3554, 0x0000 }, + { 3554, 0x0000 }, { 3554, 0x0000 }, { 3554, 0x0000 }, { 3554, 0x0020 }, + { 3555, 0x0002 }, { 3556, 0x0000 }, { 3556, 0x0000 }, { 3556, 0x0030 }, + { 3558, 0x2000 }, { 3559, 0x0000 }, { 3559, 0x0000 }, { 3559, 0x0000 }, + /* 0x22800 */ + { 3559, 0x0008 }, { 3560, 0x0000 }, { 3560, 0x0000 }, { 3560, 0x0000 }, + { 3560, 0x0000 }, { 3560, 0x8000 }, { 3561, 0x0001 }, { 3562, 0x0002 }, + { 3563, 0x0000 }, { 3563, 0x0000 }, { 3563, 0x2000 }, { 3564, 0x0000 }, + { 3564, 0x0002 }, { 3565, 0x0000 }, { 3565, 0x0000 }, { 3565, 0x0080 }, + /* 0x22900 */ + { 3566, 0x0000 }, { 3566, 0x0000 }, { 3566, 0x0040 }, { 3567, 0x0200 }, + { 3568, 0x8000 }, { 3569, 0x0000 }, { 3569, 0x0880 }, { 3571, 0x0000 }, + { 3571, 0x0001 }, { 3572, 0x0008 }, { 3573, 0x0000 }, { 3573, 0x0000 }, + { 3573, 0x0000 }, { 3573, 0x0000 }, { 3573, 0x0000 }, { 3573, 0x0000 }, + /* 0x22a00 */ + { 3573, 0x0000 }, { 3573, 0x0000 }, { 3573, 0x0000 }, { 3573, 0x0000 }, + { 3573, 0x0000 }, { 3573, 0x0000 }, { 3573, 0x0040 }, { 3574, 0x0000 }, + { 3574, 0x0000 }, { 3574, 0x0000 }, { 3574, 0x0000 }, { 3574, 0x0000 }, + { 3574, 0x8000 }, { 3575, 0x0020 }, { 3576, 0x0140 }, { 3578, 0x0000 }, + /* 0x22b00 */ + { 3578, 0x4000 }, { 3579, 0x0000 }, { 3579, 0x0004 }, { 3580, 0x8000 }, + { 3581, 0x0008 }, { 3582, 0x0000 }, { 3582, 0x0400 }, { 3583, 0x0000 }, + { 3583, 0x0000 }, { 3583, 0x0000 }, { 3583, 0x0000 }, { 3583, 0x0000 }, + { 3583, 0x4400 }, { 3585, 0x0000 }, { 3585, 0x0000 }, { 3585, 0x0000 }, + /* 0x22c00 */ + { 3585, 0x0000 }, { 3585, 0x0000 }, { 3585, 0x00c0 }, { 3587, 0x0100 }, + { 3588, 0x1000 }, { 3589, 0x0022 }, { 3591, 0x0004 }, { 3592, 0x0000 }, + { 3592, 0x0100 }, { 3593, 0x0800 }, { 3594, 0x0202 }, { 3596, 0x0084 }, + { 3598, 0x0244 }, { 3601, 0x0000 }, { 3601, 0x0000 }, { 3601, 0x0000 }, + /* 0x22d00 */ + { 3601, 0x0180 }, { 3603, 0x0004 }, { 3604, 0x0000 }, { 3604, 0x0000 }, + { 3604, 0x1010 }, { 3606, 0x0000 }, { 3606, 0x0080 }, { 3607, 0x0000 }, + { 3607, 0x2000 }, { 3608, 0x0020 }, { 3609, 0x0019 }, { 3612, 0x0080 }, + { 3613, 0x0000 }, { 3613, 0x0000 }, { 3613, 0x4000 }, { 3614, 0x0000 }, + /* 0x22e00 */ + { 3614, 0x2000 }, { 3615, 0x0000 }, { 3615, 0x0000 }, { 3615, 0x0040 }, + { 3616, 0x0004 }, { 3617, 0x0000 }, { 3617, 0x0000 }, { 3617, 0x0100 }, + { 3618, 0x0800 }, { 3619, 0x0000 }, { 3619, 0x0000 }, { 3619, 0x0008 }, + { 3620, 0x0000 }, { 3620, 0x0000 }, { 3620, 0x8000 }, { 3621, 0x0000 }, + /* 0x22f00 */ + { 3621, 0x0000 }, { 3621, 0x0000 }, { 3621, 0x0000 }, { 3621, 0x0000 }, + { 3621, 0x0000 }, { 3621, 0x0000 }, { 3621, 0x0000 }, { 3621, 0x0010 }, + { 3622, 0x0000 }, { 3622, 0x0000 }, { 3622, 0x0000 }, { 3622, 0x0000 }, + { 3622, 0x1000 }, { 3623, 0x0000 }, { 3623, 0x0008 }, { 3624, 0x0000 }, + /* 0x23000 */ + { 3624, 0x0000 }, { 3624, 0x0000 }, { 3624, 0x0000 }, { 3624, 0x0008 }, + { 3625, 0x0810 }, { 3627, 0x0000 }, { 3627, 0x0040 }, { 3628, 0x6000 }, + { 3630, 0x4000 }, { 3631, 0x0000 }, { 3631, 0x0000 }, { 3631, 0x1080 }, + { 3633, 0x0000 }, { 3633, 0x0400 }, { 3634, 0x0000 }, { 3634, 0x0000 }, + /* 0x23100 */ + { 3634, 0x0008 }, { 3635, 0x0000 }, { 3635, 0x0000 }, { 3635, 0x2000 }, + { 3636, 0x0000 }, { 3636, 0x0000 }, { 3636, 0x0000 }, { 3636, 0x2000 }, + { 3637, 0x0004 }, { 3638, 0x0000 }, { 3638, 0x0030 }, { 3640, 0x0008 }, + { 3641, 0x0300 }, { 3643, 0x0000 }, { 3643, 0x0000 }, { 3643, 0x0380 }, + /* 0x23200 */ + { 3646, 0x8000 }, { 3647, 0x0000 }, { 3647, 0x8020 }, { 3649, 0x001e }, + { 3653, 0x0000 }, { 3653, 0x0000 }, { 3653, 0x0004 }, { 3654, 0x0000 }, + { 3654, 0x0600 }, { 3656, 0x0000 }, { 3656, 0x3800 }, { 3659, 0x0000 }, + { 3659, 0x0000 }, { 3659, 0x0004 }, { 3660, 0x0003 }, { 3662, 0x0000 }, + /* 0x23300 */ + { 3662, 0x0401 }, { 3664, 0x8000 }, { 3665, 0x0000 }, { 3665, 0x0000 }, + { 3665, 0x0000 }, { 3665, 0x0000 }, { 3665, 0x0000 }, { 3665, 0x0000 }, + { 3665, 0x0000 }, { 3665, 0x0000 }, { 3665, 0x0000 }, { 3665, 0x0010 }, + { 3666, 0x1000 }, { 3667, 0x4000 }, { 3668, 0x0040 }, { 3669, 0x4430 }, + /* 0x23400 */ + { 3673, 0x0001 }, { 3674, 0x0000 }, { 3674, 0x0000 }, { 3674, 0x8000 }, + { 3675, 0x0000 }, { 3675, 0x0001 }, { 3676, 0x8000 }, { 3677, 0x0004 }, + { 3678, 0x0000 }, { 3678, 0x0000 }, { 3678, 0x0000 }, { 3678, 0x0000 }, + { 3678, 0x0000 }, { 3678, 0x0000 }, { 3678, 0x0020 }, { 3679, 0x0000 }, + /* 0x23500 */ + { 3679, 0x0000 }, { 3679, 0x0200 }, { 3680, 0x0000 }, { 3680, 0x0001 }, + { 3681, 0x0000 }, { 3681, 0x0400 }, { 3682, 0x0080 }, { 3683, 0x0000 }, + { 3683, 0x0000 }, { 3683, 0x1220 }, { 3686, 0x0000 }, { 3686, 0x0000 }, + { 3686, 0xe000 }, { 3689, 0x0000 }, { 3689, 0x0000 }, { 3689, 0x0008 }, + /* 0x23600 */ + { 3690, 0x0001 }, { 3691, 0x0400 }, { 3692, 0x0000 }, { 3692, 0x1000 }, + { 3693, 0x0001 }, { 3694, 0x8200 }, { 3696, 0x0000 }, { 3696, 0x0080 }, + { 3697, 0x0000 }, { 3697, 0x0000 }, { 3697, 0x2040 }, { 3699, 0x0400 }, + { 3700, 0x0000 }, { 3700, 0x8000 }, { 3701, 0x4000 }, { 3702, 0x0000 }, + /* 0x23700 */ + { 3702, 0x0008 }, { 3703, 0x0040 }, { 3704, 0xa001 }, { 3707, 0x8000 }, + { 3708, 0x0000 }, { 3708, 0x0000 }, { 3708, 0x0040 }, { 3709, 0x0000 }, + { 3709, 0x0002 }, { 3710, 0x0000 }, { 3710, 0x0004 }, { 3711, 0x1000 }, + { 3712, 0x0004 }, { 3713, 0x00e0 }, { 3716, 0x0000 }, { 3716, 0x0000 }, + /* 0x23800 */ + { 3716, 0x0000 }, { 3716, 0x0000 }, { 3716, 0x0000 }, { 3716, 0x0400 }, + { 3717, 0x0000 }, { 3717, 0x0000 }, { 3717, 0x0000 }, { 3717, 0x0000 }, + { 3717, 0x0000 }, { 3717, 0x0000 }, { 3717, 0x0000 }, { 3717, 0x0000 }, + { 3717, 0x0000 }, { 3717, 0x0000 }, { 3717, 0x0000 }, { 3717, 0x0000 }, + /* 0x23900 */ + { 3717, 0x0000 }, { 3717, 0x0000 }, { 3717, 0x0000 }, { 3717, 0x0000 }, + { 3717, 0x0000 }, { 3717, 0x0000 }, { 3717, 0x0000 }, { 3717, 0x0000 }, + { 3717, 0x0000 }, { 3717, 0x0000 }, { 3717, 0x0000 }, { 3717, 0x0000 }, + { 3717, 0x0004 }, { 3718, 0x0000 }, { 3718, 0x0000 }, { 3718, 0x0000 }, + /* 0x23a00 */ + { 3718, 0x0000 }, { 3718, 0x0000 }, { 3718, 0x0000 }, { 3718, 0x0000 }, + { 3718, 0x0000 }, { 3718, 0x0000 }, { 3718, 0x0000 }, { 3718, 0x0000 }, + { 3718, 0x0000 }, { 3718, 0x0000 }, { 3718, 0x0080 }, { 3719, 0x0000 }, + { 3719, 0x0000 }, { 3719, 0x0800 }, { 3720, 0x4000 }, { 3721, 0x0400 }, + /* 0x23b00 */ + { 3722, 0x0000 }, { 3722, 0x0000 }, { 3722, 0x0000 }, { 3722, 0x0000 }, + { 3722, 0x0000 }, { 3722, 0x0400 }, { 3723, 0x0000 }, { 3723, 0x0000 }, + { 3723, 0x0000 }, { 3723, 0x0000 }, { 3723, 0x0000 }, { 3723, 0x0000 }, + { 3723, 0x0000 }, { 3723, 0x0000 }, { 3723, 0x0000 }, { 3723, 0x0000 }, + /* 0x23c00 */ + { 3723, 0x0000 }, { 3723, 0x0000 }, { 3723, 0x0000 }, { 3723, 0x0000 }, + { 3723, 0x0000 }, { 3723, 0x0000 }, { 3723, 0x0000 }, { 3723, 0x0000 }, + { 3723, 0x0000 }, { 3723, 0x0e00 }, { 3726, 0x0000 }, { 3726, 0x00a0 }, + { 3728, 0x0380 }, { 3731, 0x0000 }, { 3731, 0x0000 }, { 3731, 0xf000 }, + /* 0x23d00 */ + { 3735, 0x0000 }, { 3735, 0x0000 }, { 3735, 0x0000 }, { 3735, 0x0000 }, + { 3735, 0x0001 }, { 3736, 0x0800 }, { 3737, 0x0000 }, { 3737, 0x4000 }, + { 3738, 0x8000 }, { 3739, 0x0000 }, { 3739, 0x0000 }, { 3739, 0x3fc0 }, + { 3747, 0x0000 }, { 3747, 0x0000 }, { 3747, 0x0008 }, { 3748, 0x0100 }, + /* 0x23e00 */ + { 3749, 0x0000 }, { 3749, 0x0002 }, { 3750, 0xf000 }, { 3754, 0x0203 }, + { 3757, 0x0000 }, { 3757, 0x0000 }, { 3757, 0x0000 }, { 3757, 0x0000 }, + { 3757, 0x0f00 }, { 3761, 0x0000 }, { 3761, 0x0000 }, { 3761, 0x8200 }, + { 3763, 0x0000 }, { 3763, 0x0080 }, { 3764, 0x0000 }, { 3764, 0x1f80 }, + /* 0x23f00 */ + { 3770, 0x0000 }, { 3770, 0x0000 }, { 3770, 0x0000 }, { 3770, 0x0020 }, + { 3771, 0x0402 }, { 3773, 0x0000 }, { 3773, 0x0000 }, { 3773, 0x8000 }, + { 3774, 0x8007 }, { 3778, 0x0000 }, { 3778, 0x0000 }, { 3778, 0x0090 }, + { 3780, 0x0021 }, { 3782, 0x0000 }, { 3782, 0xf800 }, { 3787, 0x0001 }, + /* 0x24000 */ + { 3788, 0x0000 }, { 3788, 0x0002 }, { 3789, 0x0000 }, { 3789, 0x3e00 }, + { 3794, 0x0000 }, { 3794, 0x0080 }, { 3795, 0x0000 }, { 3795, 0x0000 }, + { 3795, 0x3820 }, { 3799, 0x0002 }, { 3800, 0x0000 }, { 3800, 0x0000 }, + { 3800, 0x0200 }, { 3801, 0x0000 }, { 3801, 0x0002 }, { 3802, 0x0000 }, + /* 0x24100 */ + { 3802, 0x8010 }, { 3804, 0x0200 }, { 3805, 0x0000 }, { 3805, 0x8000 }, + { 3806, 0x0011 }, { 3808, 0x90e0 }, { 3813, 0x0000 }, { 3813, 0x0480 }, + { 3815, 0x0000 }, { 3815, 0x0000 }, { 3815, 0x1038 }, { 3819, 0x0020 }, + { 3820, 0x2000 }, { 3821, 0x0000 }, { 3821, 0x0004 }, { 3822, 0x1000 }, + /* 0x24200 */ + { 3823, 0x0000 }, { 3823, 0x0800 }, { 3824, 0x0000 }, { 3824, 0x0000 }, + { 3824, 0x0800 }, { 3825, 0x0240 }, { 3827, 0x0000 }, { 3827, 0x01c0 }, + { 3830, 0x0010 }, { 3831, 0x0028 }, { 3833, 0x0020 }, { 3834, 0x0000 }, + { 3834, 0x0602 }, { 3837, 0x0000 }, { 3837, 0x4000 }, { 3838, 0x0400 }, + /* 0x24300 */ + { 3839, 0x2000 }, { 3840, 0x0400 }, { 3841, 0x0000 }, { 3841, 0x0010 }, + { 3842, 0x0100 }, { 3843, 0x0000 }, { 3843, 0x003c }, { 3847, 0x0000 }, + { 3847, 0x1000 }, { 3848, 0x1040 }, { 3850, 0x0000 }, { 3850, 0x2000 }, + { 3851, 0x0002 }, { 3852, 0x0000 }, { 3852, 0x0600 }, { 3854, 0x0104 }, + /* 0x24400 */ + { 3856, 0x0010 }, { 3857, 0x0000 }, { 3857, 0x0000 }, { 3857, 0x0060 }, + { 3859, 0x0000 }, { 3859, 0x0c00 }, { 3861, 0x0000 }, { 3861, 0x0008 }, + { 3862, 0x0180 }, { 3864, 0x0000 }, { 3864, 0x0000 }, { 3864, 0x1200 }, + { 3866, 0x4000 }, { 3867, 0x0048 }, { 3869, 0x0000 }, { 3869, 0x0000 }, + /* 0x24500 */ + { 3869, 0x0000 }, { 3869, 0x0000 }, { 3869, 0x0002 }, { 3870, 0x0000 }, + { 3870, 0x0000 }, { 3870, 0x0000 }, { 3870, 0x0000 }, { 3870, 0x0100 }, + { 3871, 0x0000 }, { 3871, 0x0000 }, { 3871, 0x0000 }, { 3871, 0x0000 }, + { 3871, 0x0100 }, { 3872, 0x0000 }, { 3872, 0x0000 }, { 3872, 0x0000 }, + /* 0x24600 */ + { 3872, 0x0000 }, { 3872, 0x0100 }, { 3873, 0x0400 }, { 3874, 0x0000 }, + { 3874, 0x0000 }, { 3874, 0x0000 }, { 3874, 0x0020 }, { 3875, 0x0010 }, + { 3876, 0x0000 }, { 3876, 0x0080 }, { 3877, 0x0000 }, { 3877, 0x0000 }, + { 3877, 0x0000 }, { 3877, 0x0010 }, { 3878, 0x0000 }, { 3878, 0x0000 }, + /* 0x24700 */ + { 3878, 0x0040 }, { 3879, 0x0000 }, { 3879, 0x8020 }, { 3881, 0x0000 }, + { 3881, 0x0000 }, { 3881, 0x0000 }, { 3881, 0x0000 }, { 3881, 0x0000 }, + { 3881, 0x8000 }, { 3882, 0x0000 }, { 3882, 0x0000 }, { 3882, 0x0000 }, + { 3882, 0x0000 }, { 3882, 0x0000 }, { 3882, 0x0001 }, { 3883, 0x0000 }, + /* 0x24800 */ + { 3883, 0x0000 }, { 3883, 0x0004 }, { 3884, 0x0008 }, { 3885, 0x0000 }, + { 3885, 0x0000 }, { 3885, 0x0000 }, { 3885, 0x0000 }, { 3885, 0x0000 }, + { 3885, 0x0004 }, { 3886, 0x0000 }, { 3886, 0x0000 }, { 3886, 0x0000 }, + { 3886, 0x0000 }, { 3886, 0x0000 }, { 3886, 0x0200 }, { 3887, 0x880f }, + /* 0x24900 */ + { 3893, 0x1003 }, { 3896, 0x02c0 }, { 3899, 0x8000 }, { 3900, 0xc018 }, + { 3904, 0x000f }, { 3908, 0x0000 }, { 3908, 0x000c }, { 3910, 0x8070 }, + { 3914, 0xff04 }, { 3923, 0x0010 }, { 3924, 0x3a90 }, { 3930, 0x0f80 }, + { 3935, 0x0020 }, { 3936, 0xc401 }, { 3940, 0x3028 }, { 3944, 0x0bc0 }, + /* 0x24a00 */ + { 3949, 0x4000 }, { 3950, 0x0024 }, { 3952, 0x07fe }, { 3962, 0x4000 }, + { 3963, 0xc424 }, { 3968, 0x2003 }, { 3971, 0x00e0 }, { 3974, 0x0782 }, + { 3979, 0x1000 }, { 3980, 0x0078 }, { 3984, 0x00f0 }, { 3988, 0x1c0e }, + { 3994, 0x0481 }, { 3997, 0x8002 }, { 3999, 0x0204 }, { 4001, 0x0000 }, + /* 0x24b00 */ + { 4001, 0x0000 }, { 4001, 0x0000 }, { 4001, 0x0000 }, { 4001, 0x0000 }, + { 4001, 0x0000 }, { 4001, 0x0000 }, { 4001, 0x4000 }, { 4002, 0x0000 }, + { 4002, 0x0000 }, { 4002, 0x0000 }, { 4002, 0x0000 }, { 4002, 0x0000 }, + { 4002, 0x0000 }, { 4002, 0x0000 }, { 4002, 0x0000 }, { 4002, 0x0020 }, + /* 0x24c00 */ + { 4003, 0x0200 }, { 4004, 0x0000 }, { 4004, 0x0000 }, { 4004, 0x0000 }, + { 4004, 0x0000 }, { 4004, 0x0000 }, { 4004, 0x0000 }, { 4004, 0x0000 }, + { 4004, 0x0000 }, { 4004, 0xc000 }, { 4006, 0x0000 }, { 4006, 0x0000 }, + { 4006, 0x0200 }, { 4007, 0x0200 }, { 4008, 0x0000 }, { 4008, 0x0000 }, + /* 0x24d00 */ + { 4008, 0x0040 }, { 4009, 0x0008 }, { 4010, 0x0000 }, { 4010, 0x0000 }, + { 4010, 0x0000 }, { 4010, 0x0000 }, { 4010, 0x0000 }, { 4010, 0x0000 }, + { 4010, 0x0000 }, { 4010, 0x0000 }, { 4010, 0x0000 }, { 4010, 0x0100 }, + { 4011, 0x0000 }, { 4011, 0x0000 }, { 4011, 0x0c00 }, { 4013, 0x0000 }, + /* 0x24e00 */ + { 4013, 0x0000 }, { 4013, 0x0000 }, { 4013, 0x0000 }, { 4013, 0x0800 }, + { 4014, 0x0000 }, { 4014, 0x0001 }, { 4015, 0x0000 }, { 4015, 0x0000 }, + { 4015, 0x0000 }, { 4015, 0x0000 }, { 4015, 0x00a0 }, { 4017, 0x0000 }, + { 4017, 0x0000 }, { 4017, 0x0000 }, { 4017, 0x0000 }, { 4017, 0x0000 }, + /* 0x24f00 */ + { 4017, 0x4000 }, { 4018, 0x0000 }, { 4018, 0x0000 }, { 4018, 0x0000 }, + { 4018, 0x0000 }, { 4018, 0x1000 }, { 4019, 0x0000 }, { 4019, 0x0000 }, + { 4019, 0x0044 }, { 4021, 0x0480 }, { 4023, 0x0200 }, { 4024, 0x0100 }, + { 4025, 0x0004 }, { 4026, 0x0000 }, { 4026, 0x0000 }, { 4026, 0x0000 }, + /* 0x25000 */ + { 4026, 0x0000 }, { 4026, 0x0000 }, { 4026, 0x1000 }, { 4027, 0x0000 }, + { 4027, 0x0000 }, { 4027, 0x0004 }, { 4028, 0x0000 }, { 4028, 0x0000 }, + { 4028, 0x0000 }, { 4028, 0x2000 }, { 4029, 0x0000 }, { 4029, 0x0000 }, + { 4029, 0x0000 }, { 4029, 0x0000 }, { 4029, 0x0000 }, { 4029, 0x0000 }, + /* 0x25100 */ + { 4029, 0x0000 }, { 4029, 0x0000 }, { 4029, 0x0800 }, { 4030, 0x0000 }, + { 4030, 0x0100 }, { 4031, 0x0000 }, { 4031, 0x0000 }, { 4031, 0x6000 }, + { 4033, 0x0000 }, { 4033, 0x0000 }, { 4033, 0x0000 }, { 4033, 0x0000 }, + { 4033, 0x0000 }, { 4033, 0x0000 }, { 4033, 0x00c8 }, { 4036, 0x0000 }, + /* 0x25200 */ + { 4036, 0x0000 }, { 4036, 0x0000 }, { 4036, 0x0003 }, { 4038, 0x0000 }, + { 4038, 0x0000 }, { 4038, 0x0001 }, { 4039, 0x0000 }, { 4039, 0x0000 }, + { 4039, 0x0000 }, { 4039, 0x0200 }, { 4040, 0x0000 }, { 4040, 0x0000 }, + { 4040, 0x0080 }, { 4041, 0x0100 }, { 4042, 0x0000 }, { 4042, 0x0000 }, + /* 0x25300 */ + { 4042, 0x4000 }, { 4043, 0x000a }, { 4045, 0x0000 }, { 4045, 0x0000 }, + { 4045, 0x0000 }, { 4045, 0x0000 }, { 4045, 0x0000 }, { 4045, 0x0000 }, + { 4045, 0x0000 }, { 4045, 0x0000 }, { 4045, 0x0000 }, { 4045, 0x0000 }, + { 4045, 0x0000 }, { 4045, 0x0000 }, { 4045, 0x0000 }, { 4045, 0x0000 }, + /* 0x25400 */ + { 4045, 0x0000 }, { 4045, 0x0200 }, { 4046, 0x8020 }, { 4048, 0x0001 }, + { 4049, 0x0040 }, { 4050, 0x0000 }, { 4050, 0x5000 }, { 4052, 0x0000 }, + { 4052, 0x0000 }, { 4052, 0x0000 }, { 4052, 0x0000 }, { 4052, 0x0000 }, + { 4052, 0x0000 }, { 4052, 0x0000 }, { 4052, 0x0000 }, { 4052, 0x0000 }, + /* 0x25500 */ + { 4052, 0x0000 }, { 4052, 0x0000 }, { 4052, 0x0000 }, { 4052, 0x8022 }, + { 4055, 0x0000 }, { 4055, 0x7800 }, { 4059, 0x0064 }, { 4062, 0x0000 }, + { 4062, 0x8012 }, { 4065, 0x0000 }, { 4065, 0x0000 }, { 4065, 0x0200 }, + { 4066, 0x0000 }, { 4066, 0x0820 }, { 4068, 0x0001 }, { 4069, 0x0000 }, + /* 0x25600 */ + { 4069, 0x0020 }, { 4070, 0x0000 }, { 4070, 0x0000 }, { 4070, 0x0020 }, + { 4071, 0x0000 }, { 4071, 0x0002 }, { 4072, 0x0000 }, { 4072, 0x0000 }, + { 4072, 0x0008 }, { 4073, 0x0000 }, { 4073, 0x0000 }, { 4073, 0x0000 }, + { 4073, 0x0000 }, { 4073, 0x0000 }, { 4073, 0x0008 }, { 4074, 0x0040 }, + /* 0x25700 */ + { 4075, 0x0040 }, { 4076, 0x2000 }, { 4077, 0x0020 }, { 4078, 0x2000 }, + { 4079, 0x0000 }, { 4079, 0x0000 }, { 4079, 0x0000 }, { 4079, 0x0004 }, + { 4080, 0x0000 }, { 4080, 0x0000 }, { 4080, 0x0000 }, { 4080, 0x0000 }, + { 4080, 0x0080 }, { 4081, 0x8000 }, { 4082, 0x0003 }, { 4084, 0x0000 }, + /* 0x25800 */ + { 4084, 0x0000 }, { 4084, 0x0000 }, { 4084, 0x0000 }, { 4084, 0x0000 }, + { 4084, 0x0000 }, { 4084, 0x2080 }, { 4086, 0x0000 }, { 4086, 0x0004 }, + { 4087, 0x0000 }, { 4087, 0x0000 }, { 4087, 0x0000 }, { 4087, 0x0000 }, + { 4087, 0x0100 }, { 4088, 0x0000 }, { 4088, 0x0002 }, { 4089, 0x0000 }, + /* 0x25900 */ + { 4089, 0x0008 }, { 4090, 0x0000 }, { 4090, 0x0000 }, { 4090, 0x0000 }, + { 4090, 0x0040 }, { 4091, 0x0040 }, { 4092, 0x0000 }, { 4092, 0x0000 }, + { 4092, 0x0000 }, { 4092, 0x0000 }, { 4092, 0x1000 }, { 4093, 0x0000 }, + { 4093, 0x1000 }, { 4094, 0x0000 }, { 4094, 0x0000 }, { 4094, 0x0000 }, + /* 0x25a00 */ + { 4094, 0x0000 }, { 4094, 0x0000 }, { 4094, 0x0000 }, { 4094, 0x0000 }, + { 4094, 0x0000 }, { 4094, 0x0000 }, { 4094, 0x0000 }, { 4094, 0x0000 }, + { 4094, 0x0000 }, { 4094, 0x1020 }, { 4096, 0xc000 }, { 4098, 0x0000 }, + { 4098, 0x0000 }, { 4098, 0x0000 }, { 4098, 0x0200 }, { 4099, 0x0000 }, + /* 0x25b00 */ + { 4099, 0x0000 }, { 4099, 0x0000 }, { 4099, 0x0000 }, { 4099, 0x0000 }, + { 4099, 0x0000 }, { 4099, 0x0000 }, { 4099, 0x0000 }, { 4099, 0x0010 }, + { 4100, 0x0200 }, { 4101, 0x0000 }, { 4101, 0x0000 }, { 4101, 0x0018 }, + { 4103, 0x0040 }, { 4104, 0x0000 }, { 4104, 0x0110 }, { 4106, 0x0000 }, + /* 0x25c00 */ + { 4106, 0x0042 }, { 4108, 0x0000 }, { 4108, 0x0002 }, { 4109, 0x0000 }, + { 4109, 0x0400 }, { 4110, 0x0000 }, { 4110, 0x0020 }, { 4111, 0x0000 }, + { 4111, 0x0000 }, { 4111, 0x0002 }, { 4112, 0x0000 }, { 4112, 0x0000 }, + { 4112, 0x0003 }, { 4114, 0x0000 }, { 4114, 0x0000 }, { 4114, 0x4000 }, + /* 0x25d00 */ + { 4115, 0x0000 }, { 4115, 0x0000 }, { 4115, 0x0001 }, { 4116, 0x0000 }, + { 4116, 0x0008 }, { 4117, 0x0000 }, { 4117, 0x0000 }, { 4117, 0x0000 }, + { 4117, 0x0000 }, { 4117, 0x0000 }, { 4117, 0x0000 }, { 4117, 0x0000 }, + { 4117, 0x0000 }, { 4117, 0x0000 }, { 4117, 0x0000 }, { 4117, 0x0000 }, + /* 0x25e00 */ + { 4117, 0x4000 }, { 4118, 0x0000 }, { 4118, 0x0000 }, { 4118, 0x0000 }, + { 4118, 0x0200 }, { 4119, 0x0000 }, { 4119, 0x0000 }, { 4119, 0x0000 }, + { 4119, 0x000e }, { 4122, 0x0000 }, { 4122, 0x0040 }, { 4123, 0x1000 }, + { 4124, 0x0000 }, { 4124, 0x0180 }, { 4126, 0x0000 }, { 4126, 0x0000 }, + /* 0x25f00 */ + { 4126, 0x0000 }, { 4126, 0x0400 }, { 4127, 0x0000 }, { 4127, 0x0000 }, + { 4127, 0x0800 }, { 4128, 0x0000 }, { 4128, 0x0000 }, { 4128, 0x0000 }, + { 4128, 0x0000 }, { 4128, 0x0000 }, { 4128, 0x0000 }, { 4128, 0x0000 }, + { 4128, 0x0000 }, { 4128, 0x0000 }, { 4128, 0x0006 }, { 4130, 0x0000 }, + /* 0x26000 */ + { 4130, 0x0000 }, { 4130, 0x0000 }, { 4130, 0x0200 }, { 4131, 0x0000 }, + { 4131, 0x0100 }, { 4132, 0x0000 }, { 4132, 0x0010 }, { 4133, 0x0000 }, + { 4133, 0x0008 }, { 4134, 0x0080 }, { 4135, 0x0030 }, { 4137, 0x0000 }, + { 4137, 0x0000 }, { 4137, 0x0000 }, { 4137, 0x0000 }, { 4137, 0x0000 }, + /* 0x26100 */ + { 4137, 0x0004 }, { 4138, 0x0000 }, { 4138, 0x0002 }, { 4139, 0x0000 }, + { 4139, 0x0000 }, { 4139, 0x1e00 }, { 4143, 0x0000 }, { 4143, 0x0000 }, + { 4143, 0x0000 }, { 4143, 0x0000 }, { 4143, 0x6000 }, { 4145, 0x0004 }, + { 4146, 0x0000 }, { 4146, 0x2000 }, { 4147, 0x0000 }, { 4147, 0x0000 }, + /* 0x26200 */ + { 4147, 0x0000 }, { 4147, 0x0000 }, { 4147, 0x0000 }, { 4147, 0x0000 }, + { 4147, 0x0000 }, { 4147, 0x0100 }, { 4148, 0x0c02 }, { 4151, 0x0000 }, + { 4151, 0x0000 }, { 4151, 0x0000 }, { 4151, 0x0000 }, { 4151, 0x0000 }, + { 4151, 0x0000 }, { 4151, 0x0001 }, { 4152, 0x0000 }, { 4152, 0x0000 }, + /* 0x26300 */ + { 4152, 0x0000 }, { 4152, 0x0000 }, { 4152, 0x0000 }, { 4152, 0x0020 }, + { 4153, 0x1800 }, { 4155, 0x0002 }, { 4156, 0x0000 }, { 4156, 0x0000 }, + { 4156, 0x0000 }, { 4156, 0x0000 }, { 4156, 0x0000 }, { 4156, 0x4000 }, + { 4157, 0x0000 }, { 4157, 0x0000 }, { 4157, 0x0000 }, { 4157, 0x0120 }, + /* 0x26400 */ + { 4159, 0x0004 }, { 4160, 0x0007 }, { 4163, 0x0000 }, { 4163, 0x0000 }, + { 4163, 0x0400 }, { 4164, 0x0000 }, { 4164, 0x0200 }, { 4165, 0x0000 }, + { 4165, 0x2310 }, { 4169, 0x0100 }, { 4170, 0x0000 }, { 4170, 0x0000 }, + { 4170, 0x0000 }, { 4170, 0x0000 }, { 4170, 0x0000 }, { 4170, 0x0000 }, + /* 0x26500 */ + { 4170, 0x0000 }, { 4170, 0x0004 }, { 4171, 0x0000 }, { 4171, 0x0000 }, + { 4171, 0x0000 }, { 4171, 0x0000 }, { 4171, 0x0000 }, { 4171, 0x0004 }, + { 4172, 0x0000 }, { 4172, 0x0000 }, { 4172, 0x2001 }, { 4174, 0x8000 }, + { 4175, 0x0000 }, { 4175, 0x0000 }, { 4175, 0x0000 }, { 4175, 0x0000 }, + /* 0x26600 */ + { 4175, 0x0000 }, { 4175, 0x0004 }, { 4176, 0x0040 }, { 4177, 0x0000 }, + { 4177, 0x0000 }, { 4177, 0x0000 }, { 4177, 0x0000 }, { 4177, 0x0000 }, + { 4177, 0x0000 }, { 4177, 0x0000 }, { 4177, 0x8000 }, { 4178, 0x0022 }, + { 4180, 0x0000 }, { 4180, 0x0400 }, { 4181, 0x0100 }, { 4182, 0x1000 }, + /* 0x26700 */ + { 4183, 0x0000 }, { 4183, 0x0040 }, { 4184, 0x0000 }, { 4184, 0x0000 }, + { 4184, 0x0002 }, { 4185, 0x0000 }, { 4185, 0x0000 }, { 4185, 0x0000 }, + { 4185, 0x0000 }, { 4185, 0x0200 }, { 4186, 0x0000 }, { 4186, 0x0018 }, + { 4188, 0x1000 }, { 4189, 0x0000 }, { 4189, 0x0000 }, { 4189, 0x0000 }, + /* 0x26800 */ + { 4189, 0x0000 }, { 4189, 0x1000 }, { 4190, 0x0000 }, { 4190, 0x0000 }, + { 4190, 0x0040 }, { 4191, 0x4000 }, { 4192, 0x4000 }, { 4193, 0x0000 }, + { 4193, 0x0500 }, { 4195, 0x0008 }, { 4196, 0x0000 }, { 4196, 0x0000 }, + { 4196, 0x0080 }, { 4197, 0x0000 }, { 4197, 0x0000 }, { 4197, 0x0000 }, + /* 0x26900 */ + { 4197, 0x4000 }, { 4198, 0x0002 }, { 4199, 0x0040 }, { 4200, 0x0200 }, + { 4201, 0x0000 }, { 4201, 0x0002 }, { 4202, 0x0000 }, { 4202, 0x0000 }, + { 4202, 0x0000 }, { 4202, 0x0000 }, { 4202, 0x0100 }, { 4203, 0x0020 }, + { 4204, 0x0000 }, { 4204, 0x0000 }, { 4204, 0x0000 }, { 4204, 0x0404 }, + /* 0x26a00 */ + { 4206, 0x0000 }, { 4206, 0x0000 }, { 4206, 0x6000 }, { 4208, 0x0010 }, + { 4209, 0x0004 }, { 4210, 0x0006 }, { 4212, 0x0000 }, { 4212, 0x0000 }, + { 4212, 0x0000 }, { 4212, 0x0000 }, { 4212, 0x0000 }, { 4212, 0x0000 }, + { 4212, 0x0000 }, { 4212, 0x0000 }, { 4212, 0x0000 }, { 4212, 0x0000 }, + /* 0x26b00 */ + { 4212, 0x0420 }, { 4214, 0x0008 }, { 4215, 0x0100 }, { 4216, 0x0000 }, + { 4216, 0x0000 }, { 4216, 0x080f }, { 4221, 0x0000 }, { 4221, 0x0020 }, + { 4222, 0x0004 }, { 4223, 0x20c0 }, { 4226, 0x0000 }, { 4226, 0x0008 }, + { 4227, 0x0001 }, { 4228, 0x0000 }, { 4228, 0x0000 }, { 4228, 0x0080 }, + /* 0x26c00 */ + { 4229, 0x0000 }, { 4229, 0x0000 }, { 4229, 0x0002 }, { 4230, 0x0000 }, + { 4230, 0x0001 }, { 4231, 0x0000 }, { 4231, 0x0000 }, { 4231, 0xc000 }, + { 4233, 0x0007 }, { 4236, 0x0000 }, { 4236, 0x0010 }, { 4237, 0x2180 }, + { 4240, 0x0009 }, { 4242, 0x0002 }, { 4243, 0x0000 }, { 4243, 0x0000 }, + /* 0x26d00 */ + { 4243, 0x0000 }, { 4243, 0x0000 }, { 4243, 0x07fc }, { 4252, 0x0000 }, + { 4252, 0x0000 }, { 4252, 0x0002 }, { 4253, 0x0000 }, { 4253, 0x0000 }, + { 4253, 0x0000 }, { 4253, 0x0000 }, { 4253, 0x40ff }, { 4262, 0x0000 }, + { 4262, 0x0000 }, { 4262, 0x1000 }, { 4263, 0x0c00 }, { 4265, 0x0001 }, + /* 0x26e00 */ + { 4266, 0x00a1 }, { 4269, 0x0004 }, { 4270, 0x0000 }, { 4270, 0x0000 }, + { 4270, 0x003c }, { 4274, 0x0000 }, { 4274, 0x4000 }, { 4275, 0x0084 }, + { 4277, 0x0010 }, { 4278, 0x0200 }, { 4279, 0x0000 }, { 4279, 0x0000 }, + { 4279, 0x0000 }, { 4279, 0x00ff }, { 4287, 0x0000 }, { 4287, 0x0000 }, + /* 0x26f00 */ + { 4287, 0x0000 }, { 4287, 0x0000 }, { 4287, 0x0040 }, { 4288, 0x0000 }, + { 4288, 0x0000 }, { 4288, 0x0000 }, { 4288, 0x0000 }, { 4288, 0x0018 }, + { 4290, 0x0000 }, { 4290, 0x8000 }, { 4291, 0x0002 }, { 4292, 0x0000 }, + { 4292, 0x0000 }, { 4292, 0xc000 }, { 4294, 0x0000 }, { 4294, 0x0000 }, + /* 0x27000 */ + { 4294, 0x4000 }, { 4295, 0x0000 }, { 4295, 0x0000 }, { 4295, 0x0000 }, + { 4295, 0x0800 }, { 4296, 0x000c }, { 4298, 0x0000 }, { 4298, 0x0000 }, + { 4298, 0x0100 }, { 4299, 0x0000 }, { 4299, 0xe000 }, { 4302, 0x0000 }, + { 4302, 0x2000 }, { 4303, 0x0000 }, { 4303, 0x0000 }, { 4303, 0x0100 }, + /* 0x27100 */ + { 4304, 0x1200 }, { 4306, 0x0000 }, { 4306, 0x00c0 }, { 4308, 0x0000 }, + { 4308, 0x0000 }, { 4308, 0x0000 }, { 4308, 0x0030 }, { 4310, 0x0020 }, + { 4311, 0x0000 }, { 4311, 0x0000 }, { 4311, 0x0000 }, { 4311, 0x0000 }, + { 4311, 0x2000 }, { 4312, 0x0000 }, { 4312, 0x0000 }, { 4312, 0x0000 }, + /* 0x27200 */ + { 4312, 0x0000 }, { 4312, 0x0800 }, { 4313, 0x0000 }, { 4313, 0x0000 }, + { 4313, 0x0000 }, { 4313, 0x0000 }, { 4313, 0x0000 }, { 4313, 0x0000 }, + { 4313, 0x0821 }, { 4316, 0x0000 }, { 4316, 0x0000 }, { 4316, 0x0044 }, + { 4318, 0x0000 }, { 4318, 0x0000 }, { 4318, 0x0040 }, { 4319, 0x0000 }, + /* 0x27300 */ + { 4319, 0x0000 }, { 4319, 0x0000 }, { 4319, 0x0000 }, { 4319, 0x0000 }, + { 4319, 0x0000 }, { 4319, 0x0000 }, { 4319, 0x0000 }, { 4319, 0x0000 }, + { 4319, 0x0000 }, { 4319, 0x0400 }, { 4320, 0x0000 }, { 4320, 0x0000 }, + { 4320, 0x0000 }, { 4320, 0x0000 }, { 4320, 0x0000 }, { 4320, 0x0000 }, + /* 0x27400 */ + { 4320, 0x0000 }, { 4320, 0x0000 }, { 4320, 0x0004 }, { 4321, 0x0000 }, + { 4321, 0x0000 }, { 4321, 0x0001 }, { 4322, 0x0000 }, { 4322, 0x0000 }, + { 4322, 0x0050 }, { 4324, 0x0000 }, { 4324, 0x0000 }, { 4324, 0x0000 }, + { 4324, 0x0000 }, { 4324, 0x0000 }, { 4324, 0x0000 }, { 4324, 0x0000 }, + /* 0x27500 */ + { 4324, 0x0000 }, { 4324, 0x0000 }, { 4324, 0x0000 }, { 4324, 0x0000 }, + { 4324, 0x0000 }, { 4324, 0x0000 }, { 4324, 0x0000 }, { 4324, 0x0010 }, + { 4325, 0x0000 }, { 4325, 0x0000 }, { 4325, 0x0008 }, { 4326, 0x0000 }, + { 4326, 0x0000 }, { 4326, 0x0000 }, { 4326, 0x0011 }, { 4328, 0x6000 }, + /* 0x27600 */ + { 4330, 0x1080 }, { 4332, 0x0000 }, { 4332, 0x0000 }, { 4332, 0x0204 }, + { 4334, 0x0000 }, { 4334, 0x00e0 }, { 4337, 0x0000 }, { 4337, 0x0000 }, + { 4337, 0x0000 }, { 4337, 0x0010 }, { 4338, 0x0000 }, { 4338, 0x0000 }, + { 4338, 0x0000 }, { 4338, 0x0000 }, { 4338, 0x0000 }, { 4338, 0x0000 }, + /* 0x27700 */ + { 4338, 0x8000 }, { 4339, 0x0000 }, { 4339, 0x0000 }, { 4339, 0x0060 }, + { 4341, 0x0002 }, { 4342, 0x4000 }, { 4343, 0x0000 }, { 4343, 0x0000 }, + { 4343, 0x0030 }, { 4345, 0x0000 }, { 4345, 0x0000 }, { 4345, 0x0000 }, + { 4345, 0x1000 }, { 4346, 0x0000 }, { 4346, 0x0000 }, { 4346, 0x0000 }, + /* 0x27800 */ + { 4346, 0x0000 }, { 4346, 0x0000 }, { 4346, 0x0000 }, { 4346, 0x0000 }, + { 4346, 0x0000 }, { 4346, 0x0100 }, { 4347, 0x0000 }, { 4347, 0x0001 }, + { 4348, 0x0000 }, { 4348, 0x2000 }, { 4349, 0x0000 }, { 4349, 0x0004 }, + { 4350, 0x0100 }, { 4351, 0x0000 }, { 4351, 0x0000 }, { 4351, 0x0000 }, + /* 0x27900 */ + { 4351, 0x0000 }, { 4351, 0x0000 }, { 4351, 0x0010 }, { 4352, 0x0000 }, + { 4352, 0x0000 }, { 4352, 0x0000 }, { 4352, 0x0080 }, { 4353, 0x0400 }, + { 4354, 0x0000 }, { 4354, 0x0000 }, { 4354, 0x0001 }, { 4355, 0x0000 }, + { 4355, 0x0000 }, { 4355, 0x2000 }, { 4356, 0x0000 }, { 4356, 0x2000 }, + /* 0x27a00 */ + { 4357, 0x4400 }, { 4359, 0x0000 }, { 4359, 0x0000 }, { 4359, 0x4000 }, + { 4360, 0x0000 }, { 4360, 0x0208 }, { 4362, 0x0000 }, { 4362, 0x0200 }, + { 4363, 0x0010 }, { 4364, 0x0000 }, { 4364, 0x0000 }, { 4364, 0x6000 }, + { 4366, 0x0000 }, { 4366, 0x0000 }, { 4366, 0x0000 }, { 4366, 0x0010 }, + /* 0x27b00 */ + { 4367, 0x0840 }, { 4369, 0x0100 }, { 4370, 0x0000 }, { 4370, 0x0700 }, + { 4373, 0x0100 }, { 4374, 0x0000 }, { 4374, 0x0000 }, { 4374, 0x0000 }, + { 4374, 0x0000 }, { 4374, 0x0000 }, { 4374, 0x0000 }, { 4374, 0x0000 }, + { 4374, 0x0000 }, { 4374, 0x0000 }, { 4374, 0x0000 }, { 4374, 0x0010 }, + /* 0x27c00 */ + { 4375, 0x0000 }, { 4375, 0x0004 }, { 4376, 0x0000 }, { 4376, 0x0000 }, + { 4376, 0x0000 }, { 4376, 0x0000 }, { 4376, 0x0000 }, { 4376, 0x0000 }, + { 4376, 0x0000 }, { 4376, 0x0000 }, { 4376, 0x0000 }, { 4376, 0x0000 }, + { 4376, 0x0000 }, { 4376, 0x0000 }, { 4376, 0x0000 }, { 4376, 0x0000 }, + /* 0x27d00 */ + { 4376, 0x0000 }, { 4376, 0x0000 }, { 4376, 0x8000 }, { 4377, 0x0000 }, + { 4377, 0x0000 }, { 4377, 0x0018 }, { 4379, 0x0040 }, { 4380, 0x0008 }, + { 4381, 0x8010 }, { 4383, 0x0100 }, { 4384, 0x0000 }, { 4384, 0x2000 }, + { 4385, 0x0000 }, { 4385, 0x1000 }, { 4386, 0x0000 }, { 4386, 0x0000 }, + /* 0x27e00 */ + { 4386, 0x0000 }, { 4386, 0x0000 }, { 4386, 0x0000 }, { 4386, 0x0000 }, + { 4386, 0xa000 }, { 4388, 0x0000 }, { 4388, 0x0000 }, { 4388, 0x0000 }, + { 4388, 0x0000 }, { 4388, 0x0000 }, { 4388, 0x0000 }, { 4388, 0x0000 }, + { 4388, 0x0000 }, { 4388, 0x0000 }, { 4388, 0x0000 }, { 4388, 0x0000 }, + /* 0x27f00 */ + { 4388, 0x0000 }, { 4388, 0x0000 }, { 4388, 0x4000 }, { 4389, 0x0000 }, + { 4389, 0x0000 }, { 4389, 0x0000 }, { 4389, 0x0000 }, { 4389, 0x0000 }, + { 4389, 0x0000 }, { 4389, 0x0000 }, { 4389, 0x0000 }, { 4389, 0x0000 }, + { 4389, 0x0000 }, { 4389, 0x0000 }, { 4389, 0x0000 }, { 4389, 0x0200 }, + /* 0x28000 */ + { 4390, 0x0204 }, { 4392, 0x4000 }, { 4393, 0x0018 }, { 4395, 0x0000 }, + { 4395, 0x0100 }, { 4396, 0x0000 }, { 4396, 0x0000 }, { 4396, 0x0000 }, + { 4396, 0x0008 }, { 4397, 0x0001 }, { 4398, 0x0000 }, { 4398, 0x6000 }, + { 4400, 0x0000 }, { 4400, 0x0000 }, { 4400, 0x0300 }, { 4402, 0x0010 }, + /* 0x28100 */ + { 4403, 0x0000 }, { 4403, 0x0000 }, { 4403, 0x4000 }, { 4404, 0x0000 }, + { 4404, 0x8000 }, { 4405, 0x2000 }, { 4406, 0x8000 }, { 4407, 0x0000 }, + { 4407, 0x0200 }, { 4408, 0x0000 }, { 4408, 0x8000 }, { 4409, 0x1000 }, + { 4410, 0x0000 }, { 4410, 0x0000 }, { 4410, 0x0000 }, { 4410, 0x0000 }, + /* 0x28200 */ + { 4410, 0x0080 }, { 4411, 0x0500 }, { 4413, 0x0000 }, { 4413, 0x0000 }, + { 4413, 0x0000 }, { 4413, 0x0040 }, { 4414, 0x0000 }, { 4414, 0x1000 }, + { 4415, 0x0000 }, { 4415, 0x0800 }, { 4416, 0x0000 }, { 4416, 0x0000 }, + { 4416, 0x2000 }, { 4417, 0x0000 }, { 4417, 0x0004 }, { 4418, 0x0000 }, + /* 0x28300 */ + { 4418, 0x0040 }, { 4419, 0x0100 }, { 4420, 0x8000 }, { 4421, 0x0400 }, + { 4422, 0x0000 }, { 4422, 0x0000 }, { 4422, 0x2020 }, { 4424, 0x2000 }, + { 4425, 0x0400 }, { 4426, 0x0000 }, { 4426, 0x0000 }, { 4426, 0x0000 }, + { 4426, 0x0000 }, { 4426, 0x0000 }, { 4426, 0x0000 }, { 4426, 0x0000 }, + /* 0x28400 */ + { 4426, 0x0000 }, { 4426, 0x0004 }, { 4427, 0x0000 }, { 4427, 0x0000 }, + { 4427, 0x0000 }, { 4427, 0x0000 }, { 4427, 0x1100 }, { 4429, 0x0008 }, + { 4430, 0x0004 }, { 4431, 0x0000 }, { 4431, 0x0000 }, { 4431, 0x0000 }, + { 4431, 0x0000 }, { 4431, 0x0000 }, { 4431, 0x0000 }, { 4431, 0x0000 }, + /* 0x28500 */ + { 4431, 0x0002 }, { 4432, 0x0000 }, { 4432, 0x0000 }, { 4432, 0x3000 }, + { 4434, 0x0000 }, { 4434, 0x0000 }, { 4434, 0x1000 }, { 4435, 0x0000 }, + { 4435, 0x0000 }, { 4435, 0x0000 }, { 4435, 0x0000 }, { 4435, 0x0000 }, + { 4435, 0x0000 }, { 4435, 0x0000 }, { 4435, 0x0100 }, { 4436, 0x0010 }, + /* 0x28600 */ + { 4437, 0x0801 }, { 4439, 0x0000 }, { 4439, 0x0020 }, { 4440, 0x0800 }, + { 4441, 0x0000 }, { 4441, 0x0000 }, { 4441, 0x0000 }, { 4441, 0x0000 }, + { 4441, 0x0000 }, { 4441, 0x0000 }, { 4441, 0x0c00 }, { 4443, 0x1000 }, + { 4444, 0x0000 }, { 4444, 0x0100 }, { 4445, 0x0040 }, { 4446, 0x0000 }, + /* 0x28700 */ + { 4446, 0x0000 }, { 4446, 0x0008 }, { 4447, 0x0000 }, { 4447, 0x0000 }, + { 4447, 0x0000 }, { 4447, 0x0000 }, { 4447, 0x0000 }, { 4447, 0x0000 }, + { 4447, 0x0000 }, { 4447, 0x0000 }, { 4447, 0x0000 }, { 4447, 0x0000 }, + { 4447, 0x0000 }, { 4447, 0x0000 }, { 4447, 0x0000 }, { 4447, 0x0000 }, + /* 0x28800 */ + { 4447, 0x0010 }, { 4448, 0x0000 }, { 4448, 0x0800 }, { 4449, 0x0000 }, + { 4449, 0x0000 }, { 4449, 0x0000 }, { 4449, 0x0000 }, { 4449, 0x0000 }, + { 4449, 0x0000 }, { 4449, 0x0000 }, { 4449, 0x0000 }, { 4449, 0x0000 }, + { 4449, 0x0000 }, { 4449, 0x0000 }, { 4449, 0x0000 }, { 4449, 0x0000 }, + /* 0x28900 */ + { 4449, 0x0000 }, { 4449, 0x0000 }, { 4449, 0x0000 }, { 4449, 0x0008 }, + { 4450, 0x0300 }, { 4452, 0x0040 }, { 4453, 0x1110 }, { 4456, 0x4000 }, + { 4457, 0x0200 }, { 4458, 0x0000 }, { 4458, 0x0d00 }, { 4461, 0x1100 }, + { 4463, 0x0001 }, { 4464, 0x5000 }, { 4466, 0x0192 }, { 4470, 0x1e00 }, + /* 0x28a00 */ + { 4474, 0x8000 }, { 4475, 0x0040 }, { 4476, 0x0220 }, { 4478, 0x0040 }, + { 4479, 0x0ff0 }, { 4487, 0x0600 }, { 4489, 0x0000 }, { 4489, 0x0000 }, + { 4489, 0x000e }, { 4492, 0x1c00 }, { 4495, 0x0000 }, { 4495, 0x0000 }, + { 4495, 0x5841 }, { 4500, 0xc000 }, { 4502, 0x002f }, { 4507, 0x1000 }, + /* 0x28b00 */ + { 4508, 0x1000 }, { 4509, 0x0008 }, { 4510, 0xb806 }, { 4516, 0x0000 }, + { 4516, 0x5040 }, { 4519, 0x0001 }, { 4520, 0x1078 }, { 4525, 0x0000 }, + { 4525, 0x8000 }, { 4526, 0x3200 }, { 4529, 0x0000 }, { 4529, 0x0000 }, + { 4529, 0x0024 }, { 4531, 0x0690 }, { 4535, 0x1f80 }, { 4541, 0x8020 }, + /* 0x28c00 */ + { 4543, 0x0208 }, { 4545, 0x3000 }, { 4547, 0x0848 }, { 4550, 0x0a01 }, + { 4553, 0x0000 }, { 4553, 0x0000 }, { 4553, 0x0000 }, { 4553, 0x0000 }, + { 4553, 0x0000 }, { 4553, 0x0000 }, { 4553, 0x0000 }, { 4553, 0x0000 }, + { 4553, 0x2400 }, { 4555, 0x0004 }, { 4556, 0x0000 }, { 4556, 0x0000 }, + /* 0x28d00 */ + { 4556, 0x0000 }, { 4556, 0x0000 }, { 4556, 0x0000 }, { 4556, 0x0010 }, + { 4557, 0x0000 }, { 4557, 0x0000 }, { 4557, 0x0000 }, { 4557, 0x0000 }, + { 4557, 0x0000 }, { 4557, 0x0200 }, { 4558, 0x0000 }, { 4558, 0x0000 }, + { 4558, 0x0000 }, { 4558, 0x0000 }, { 4558, 0x0000 }, { 4558, 0x0000 }, + /* 0x28e00 */ + { 4558, 0x8000 }, { 4559, 0x0000 }, { 4559, 0x0000 }, { 4559, 0x0240 }, + { 4561, 0x0000 }, { 4561, 0x0000 }, { 4561, 0x0060 }, { 4563, 0x0000 }, + { 4563, 0x0000 }, { 4563, 0x0080 }, { 4564, 0x1000 }, { 4565, 0x000c }, + { 4567, 0x0000 }, { 4567, 0x0200 }, { 4568, 0x0080 }, { 4569, 0x0000 }, + /* 0x28f00 */ + { 4569, 0x0000 }, { 4569, 0x0000 }, { 4569, 0x0000 }, { 4569, 0x0000 }, + { 4569, 0x0000 }, { 4569, 0x0000 }, { 4569, 0x0000 }, { 4569, 0x0000 }, + { 4569, 0x0000 }, { 4569, 0x0000 }, { 4569, 0x0000 }, { 4569, 0x0000 }, + { 4569, 0x0020 }, { 4570, 0x0000 }, { 4570, 0x0000 }, { 4570, 0x0000 }, + /* 0x29000 */ + { 4570, 0x0000 }, { 4570, 0x0000 }, { 4570, 0x0000 }, { 4570, 0x0000 }, + { 4570, 0x0000 }, { 4570, 0x0000 }, { 4570, 0x0000 }, { 4570, 0x0000 }, + { 4570, 0x0900 }, { 4572, 0x0008 }, { 4573, 0x8000 }, { 4574, 0x0003 }, + { 4576, 0x0001 }, { 4577, 0x0000 }, { 4577, 0x3030 }, { 4581, 0x0000 }, + /* 0x29100 */ + { 4581, 0x2000 }, { 4582, 0x0001 }, { 4583, 0x0000 }, { 4583, 0x1000 }, + { 4584, 0x2000 }, { 4585, 0x4800 }, { 4587, 0x0000 }, { 4587, 0x0001 }, + { 4588, 0x0000 }, { 4588, 0x1000 }, { 4589, 0x0100 }, { 4590, 0x0000 }, + { 4590, 0x0000 }, { 4590, 0x0020 }, { 4591, 0x0800 }, +}; +static const Summary16 hkscs1999_uni2indx_page294[32] = { + /* 0x29400 */ + { 4592, 0x0000 }, { 4592, 0x2000 }, { 4593, 0x0001 }, { 4594, 0x8008 }, + { 4596, 0x0100 }, { 4597, 0x0000 }, { 4597, 0x0000 }, { 4597, 0x0000 }, + { 4597, 0x0000 }, { 4597, 0x0000 }, { 4597, 0x0000 }, { 4597, 0x0000 }, + { 4597, 0x0000 }, { 4597, 0x0601 }, { 4600, 0x00a0 }, { 4602, 0x0000 }, + /* 0x29500 */ + { 4602, 0x0000 }, { 4602, 0x0000 }, { 4602, 0x0000 }, { 4602, 0x0000 }, + { 4602, 0x0000 }, { 4602, 0x0000 }, { 4602, 0x0000 }, { 4602, 0x0000 }, + { 4602, 0x0000 }, { 4602, 0x4000 }, { 4603, 0x0000 }, { 4603, 0x0101 }, + { 4605, 0x0000 }, { 4605, 0x0080 }, { 4606, 0x0200 }, { 4607, 0x0010 }, +}; +static const Summary16 hkscs1999_uni2indx_page297[251] = { + /* 0x29700 */ + { 4608, 0x0000 }, { 4608, 0x0000 }, { 4608, 0x0001 }, { 4609, 0x0004 }, + { 4610, 0x0000 }, { 4610, 0x0000 }, { 4610, 0x0000 }, { 4610, 0x0000 }, + { 4610, 0x0000 }, { 4610, 0x0000 }, { 4610, 0x0000 }, { 4610, 0x0000 }, + { 4610, 0x0000 }, { 4610, 0x0010 }, { 4611, 0x0000 }, { 4611, 0x0000 }, + /* 0x29800 */ + { 4611, 0x0000 }, { 4611, 0x0001 }, { 4612, 0x0000 }, { 4612, 0x0000 }, + { 4612, 0x0000 }, { 4612, 0x0080 }, { 4613, 0x0000 }, { 4613, 0x0000 }, + { 4613, 0x0000 }, { 4613, 0x0000 }, { 4613, 0x0010 }, { 4614, 0x0000 }, + { 4614, 0x0000 }, { 4614, 0x0002 }, { 4615, 0x0400 }, { 4616, 0x0002 }, + /* 0x29900 */ + { 4617, 0x0028 }, { 4619, 0x0000 }, { 4619, 0x8000 }, { 4620, 0x0000 }, + { 4620, 0x0300 }, { 4622, 0x2000 }, { 4623, 0x0400 }, { 4624, 0x0000 }, + { 4624, 0x0000 }, { 4624, 0x2000 }, { 4625, 0x0000 }, { 4625, 0x0000 }, + { 4625, 0x0208 }, { 4627, 0x0000 }, { 4627, 0x0000 }, { 4627, 0x0000 }, + /* 0x29a00 */ + { 4627, 0x0000 }, { 4627, 0x0000 }, { 4627, 0x0100 }, { 4628, 0x0000 }, + { 4628, 0x2000 }, { 4629, 0x0000 }, { 4629, 0x0000 }, { 4629, 0x0000 }, + { 4629, 0x0000 }, { 4629, 0x0000 }, { 4629, 0x0000 }, { 4629, 0x0000 }, + { 4629, 0x0000 }, { 4629, 0x0000 }, { 4629, 0x0000 }, { 4629, 0x0000 }, + /* 0x29b00 */ + { 4629, 0x4020 }, { 4631, 0x0000 }, { 4631, 0x0000 }, { 4631, 0x0000 }, + { 4631, 0x0000 }, { 4631, 0x0000 }, { 4631, 0x0000 }, { 4631, 0x0000 }, + { 4631, 0x0000 }, { 4631, 0x0000 }, { 4631, 0x0000 }, { 4631, 0x0000 }, + { 4631, 0x0000 }, { 4631, 0x0020 }, { 4632, 0x0000 }, { 4632, 0x0000 }, + /* 0x29c00 */ + { 4632, 0x0000 }, { 4632, 0x0000 }, { 4632, 0x0000 }, { 4632, 0x0000 }, + { 4632, 0x0000 }, { 4632, 0x0000 }, { 4632, 0x0000 }, { 4632, 0x0000 }, + { 4632, 0x0000 }, { 4632, 0x0000 }, { 4632, 0x2000 }, { 4633, 0x0000 }, + { 4633, 0x0000 }, { 4633, 0x0000 }, { 4633, 0x0000 }, { 4633, 0x0000 }, + /* 0x29d00 */ + { 4633, 0x0000 }, { 4633, 0x0000 }, { 4633, 0x0000 }, { 4633, 0x4000 }, + { 4634, 0x0000 }, { 4634, 0x0400 }, { 4635, 0x0000 }, { 4635, 0x1000 }, + { 4636, 0x0000 }, { 4636, 0x0900 }, { 4638, 0x0000 }, { 4638, 0x0000 }, + { 4638, 0x0000 }, { 4638, 0x0000 }, { 4638, 0x0000 }, { 4638, 0x0040 }, + /* 0x29e00 */ + { 4639, 0x0040 }, { 4640, 0x0000 }, { 4640, 0x2000 }, { 4641, 0x0000 }, + { 4641, 0x0000 }, { 4641, 0x0000 }, { 4641, 0x0100 }, { 4642, 0x0000 }, + { 4642, 0x0000 }, { 4642, 0x0000 }, { 4642, 0x1000 }, { 4643, 0x0000 }, + { 4643, 0x0008 }, { 4644, 0x0000 }, { 4644, 0x0000 }, { 4644, 0x0100 }, + /* 0x29f00 */ + { 4645, 0x0000 }, { 4645, 0x0000 }, { 4645, 0x0008 }, { 4646, 0x0001 }, + { 4647, 0x0000 }, { 4647, 0x0000 }, { 4647, 0x0000 }, { 4647, 0x0000 }, + { 4647, 0x0000 }, { 4647, 0x0000 }, { 4647, 0x0000 }, { 4647, 0x0080 }, + { 4648, 0x0000 }, { 4648, 0x4000 }, { 4649, 0x0000 }, { 4649, 0x0000 }, + /* 0x2a000 */ + { 4649, 0x0000 }, { 4649, 0x0010 }, { 4650, 0x0000 }, { 4650, 0x0000 }, + { 4650, 0x0000 }, { 4650, 0x0000 }, { 4650, 0x0000 }, { 4650, 0x0000 }, + { 4650, 0x0080 }, { 4651, 0x0000 }, { 4651, 0x0000 }, { 4651, 0x0200 }, + { 4652, 0x0000 }, { 4652, 0x0000 }, { 4652, 0x2002 }, { 4654, 0x4108 }, + /* 0x2a100 */ + { 4657, 0x0000 }, { 4657, 0x0000 }, { 4657, 0x0008 }, { 4658, 0x0018 }, + { 4660, 0x0000 }, { 4660, 0x0001 }, { 4661, 0x0000 }, { 4661, 0x0000 }, + { 4661, 0x0000 }, { 4661, 0x000c }, { 4663, 0x0800 }, { 4664, 0x0010 }, + { 4665, 0x0000 }, { 4665, 0x8000 }, { 4666, 0x0000 }, { 4666, 0x0020 }, + /* 0x2a200 */ + { 4667, 0x0000 }, { 4667, 0x0000 }, { 4667, 0x0001 }, { 4668, 0x0008 }, + { 4669, 0x0000 }, { 4669, 0x0000 }, { 4669, 0x0000 }, { 4669, 0x0000 }, + { 4669, 0x0000 }, { 4669, 0x8008 }, { 4671, 0x0000 }, { 4671, 0x2054 }, + { 4675, 0x0000 }, { 4675, 0x8000 }, { 4676, 0x0000 }, { 4676, 0x8000 }, + /* 0x2a300 */ + { 4677, 0x0000 }, { 4677, 0x0000 }, { 4677, 0x0000 }, { 4677, 0x0000 }, + { 4677, 0x0000 }, { 4677, 0x0000 }, { 4677, 0x0000 }, { 4677, 0x0000 }, + { 4677, 0x0000 }, { 4677, 0x0000 }, { 4677, 0x0200 }, { 4678, 0x0000 }, + { 4678, 0x0000 }, { 4678, 0x0000 }, { 4678, 0x0000 }, { 4678, 0x0000 }, + /* 0x2a400 */ + { 4678, 0x0000 }, { 4678, 0x0000 }, { 4678, 0x0000 }, { 4678, 0x0010 }, + { 4679, 0x0000 }, { 4679, 0x0800 }, { 4680, 0x0000 }, { 4680, 0x0000 }, + { 4680, 0x0000 }, { 4680, 0x0000 }, { 4680, 0x0000 }, { 4680, 0x0000 }, + { 4680, 0x0000 }, { 4680, 0x0000 }, { 4680, 0x0000 }, { 4680, 0x0000 }, + /* 0x2a500 */ + { 4680, 0x0000 }, { 4680, 0x0000 }, { 4680, 0x0000 }, { 4680, 0x0000 }, + { 4680, 0x0000 }, { 4680, 0x0000 }, { 4680, 0x0000 }, { 4680, 0x0000 }, + { 4680, 0x0000 }, { 4680, 0x0000 }, { 4680, 0x0000 }, { 4680, 0x0000 }, + { 4680, 0x0840 }, { 4682, 0x0000 }, { 4682, 0x0000 }, { 4682, 0x0000 }, + /* 0x2a600 */ + { 4682, 0x0002 }, { 4683, 0x0000 }, { 4683, 0x0000 }, { 4683, 0x0004 }, + { 4684, 0x0400 }, { 4685, 0x0800 }, { 4686, 0x0000 }, { 4686, 0x0000 }, + { 4686, 0x0000 }, { 4686, 0x0000 }, { 4686, 0x0200 }, +}; +static const Summary16 hkscs1999_uni2indx_page2f8[30] = { + /* 0x2f800 */ + { 4687, 0x0000 }, { 4687, 0x0000 }, { 4687, 0x0020 }, { 4688, 0x0800 }, + { 4689, 0x0001 }, { 4690, 0x0000 }, { 4690, 0x0000 }, { 4690, 0x0100 }, + { 4691, 0x0000 }, { 4691, 0x0010 }, { 4692, 0x0040 }, { 4693, 0x0000 }, + { 4693, 0x2000 }, { 4694, 0x0000 }, { 4694, 0x0000 }, { 4694, 0x0000 }, + /* 0x2f900 */ + { 4694, 0x0000 }, { 4694, 0x0000 }, { 4694, 0x0000 }, { 4694, 0x0000 }, + { 4694, 0x0000 }, { 4694, 0x0000 }, { 4694, 0x0000 }, { 4694, 0x0000 }, + { 4694, 0x0000 }, { 4694, 0x0010 }, { 4695, 0x0000 }, { 4695, 0x1004 }, + { 4697, 0x0000 }, { 4697, 0x0010 }, +}; + +static int +hkscs1999_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc >= 0x0000 && wc < 0x02d0) + summary = &hkscs1999_uni2indx_page00[(wc>>4)]; + else if (wc >= 0x0400 && wc < 0x0460) + summary = &hkscs1999_uni2indx_page04[(wc>>4)-0x040]; + else if (wc >= 0x1e00 && wc < 0x1ed0) + summary = &hkscs1999_uni2indx_page1e[(wc>>4)-0x1e0]; + else if (wc >= 0x2100 && wc < 0x21f0) + summary = &hkscs1999_uni2indx_page21[(wc>>4)-0x210]; + else if (wc >= 0x2300 && wc < 0x2580) + summary = &hkscs1999_uni2indx_page23[(wc>>4)-0x230]; + else if (wc >= 0x2700 && wc < 0x2740) + summary = &hkscs1999_uni2indx_page27[(wc>>4)-0x270]; + else if (wc >= 0x2e00 && wc < 0x3240) + summary = &hkscs1999_uni2indx_page2e[(wc>>4)-0x2e0]; + else if (wc >= 0x3400 && wc < 0x9fc0) + summary = &hkscs1999_uni2indx_page34[(wc>>4)-0x340]; + else if (wc >= 0xf900 && wc < 0xf910) + summary = &hkscs1999_uni2indx_pagef9[(wc>>4)-0xf90]; + else if (wc >= 0xff00 && wc < 0xfff0) + summary = &hkscs1999_uni2indx_pageff[(wc>>4)-0xff0]; + else if (wc >= 0x20000 && wc < 0x291f0) + summary = &hkscs1999_uni2indx_page200[(wc>>4)-0x2000]; + else if (wc >= 0x29400 && wc < 0x29600) + summary = &hkscs1999_uni2indx_page294[(wc>>4)-0x2940]; + else if (wc >= 0x29700 && wc < 0x2a6b0) + summary = &hkscs1999_uni2indx_page297[(wc>>4)-0x2970]; + else if (wc >= 0x2f800 && wc < 0x2f9e0) + summary = &hkscs1999_uni2indx_page2f8[(wc>>4)-0x2f80]; + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = hkscs1999_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/hkscs2001.h b/graf2d/win32gdk/gdk/src/iconv/hkscs2001.h new file mode 100644 index 0000000000000..66642cf9cc6bc --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/hkscs2001.h @@ -0,0 +1,683 @@ +/* + * Copyright (C) 1999-2006 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * HKSCS:2001 + */ + +static const unsigned short hkscs2001_2uni_page8c[123] = { + /* 0x8c */ + 0x0a3b, 0x1cfe, 0x5273, 0x37a6, 0x02c9, 0x2d8f, 0x414e, 0x1d77, + 0x12f5, 0x0620, 0x45cd, 0x0059, 0x4830, 0x1622, 0x4f32, 0x30a7, + 0x31f6, 0x1e91, 0x1819, 0x20ba, 0x3e81, 0x5307, 0x018b, 0x3a80, + 0x0610, 0x24e4, 0x2102, 0x0bae, 0x4d0f, 0x0409, 0x1a63, 0x54ba, + 0x0523, 0x2c0f, 0x38fd, 0x252a, 0x5147, 0x4fea, 0x3455, 0x1d4d, + 0x0c24, 0x3c7e, 0x33f4, 0x22d9, 0x4ee3, 0x37a7, 0x23dd, 0x08a3, + 0x09f0, 0x0abc, 0x082f, 0x0917, 0x37a8, 0x0d34, 0x288b, 0x0f92, + 0x0fd0, 0x3bb6, 0x1492, 0x1499, 0x15c2, 0x3d12, 0x178b, 0x3ff9, + 0x1919, 0x1a43, 0x4063, 0x1bff, 0x38fd, 0x1f00, 0x4205, 0x208c, + 0x03db, 0x4413, 0x1115, 0x21b9, 0x2e83, 0x47a4, 0x4695, 0x2593, + 0x26ec, 0x27c3, 0x296c, 0x2af8, 0x2b97, 0x37a9, 0x2d90, 0x37aa, + 0x2fb9, 0x37ab, 0x30cf, 0x2b5f, 0x36e0, 0x3221, 0x37ac, 0x50b9, + 0x393f, 0x0471, 0x05a2, 0x101a, 0x38fd, 0x38fd, 0x38fd, 0x3568, + 0x186b, 0x0576, 0x0e3d, 0x38fd, 0x2bd6, 0x437b, 0x2abf, 0x4c0d, + 0x0781, 0x4a74, 0x137b, 0x4915, 0x4bbe, 0x37ad, 0x37ae, 0x1196, + 0x37af, 0x38fd, 0x295b, +}; + +static const ucs4_t hkscs2001_2uni_upages[85] = { + 0x03500, 0x03c00, 0x03d00, 0x03e00, 0x04000, 0x04200, 0x04b00, 0x04c00, + 0x04e00, 0x04f00, 0x05000, 0x05100, 0x05300, 0x05400, 0x05700, 0x05800, + 0x05a00, 0x05b00, 0x05c00, 0x05d00, 0x05e00, 0x05f00, 0x06100, 0x06500, + 0x06700, 0x06900, 0x06a00, 0x06c00, 0x06d00, 0x07000, 0x07100, 0x07200, + 0x07300, 0x07400, 0x07600, 0x07700, 0x07800, 0x07a00, 0x07b00, 0x07c00, + 0x07d00, 0x07e00, 0x08200, 0x08500, 0x08600, 0x08800, 0x08b00, 0x08e00, + 0x08f00, 0x09100, 0x09200, 0x09300, 0x09700, 0x09800, 0x09900, 0x09f00, + 0x0ff00, 0x21400, 0x21900, 0x21d00, 0x22000, 0x22700, 0x23200, 0x23300, + 0x23c00, 0x24100, 0x24500, 0x24900, 0x24a00, 0x25100, 0x25600, 0x25c00, + 0x25d00, 0x26b00, 0x26d00, 0x26f00, 0x27100, 0x28700, 0x28900, 0x28a00, + 0x28d00, 0x29900, 0x29c00, 0x2a100, 0x2a200, +}; + +static int +hkscs2001_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 == 0x8c)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0xa1 && c2 < 0xff)) { + unsigned int i = 157 * (c1 - 0x80) + (c2 - (c2 >= 0xa1 ? 0x62 : 0x40)); + ucs4_t wc = 0xfffd; + unsigned short swc; + { + if (i < 2007) + swc = hkscs2001_2uni_page8c[i-1884], + wc = hkscs2001_2uni_upages[swc>>8] | (swc & 0xff); + } + if (wc != 0xfffd) { + *pwc = wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short hkscs2001_2charset[116] = { + 0x8c4b, 0x8c56, 0x8c44, 0x8caa, 0x8c5d, 0x8cc3, 0x8c60, 0x8ccb, + 0x8cc4, 0x8c58, 0x8c49, 0x8cd2, 0x8c72, 0x8c6f, 0x8c73, 0x8c70, + 0x8c40, 0x8c71, 0x8c5b, 0x8c68, 0x8c75, 0x8ccc, 0x8c77, 0x8c78, + 0x8cc5, 0x8cac, 0x8cd9, 0x8c48, 0x8cd4, 0x8c7a, 0x8c7b, 0x8c7c, + 0x8c4d, 0x8c7e, 0x8c52, 0x8cca, 0x8ca2, 0x8ca3, 0x8c5e, 0x8ca5, + 0x8c41, 0x8c67, 0x8c47, 0x8c51, 0x8ca7, 0x8ca9, 0x8c53, 0x8c5a, + 0x8cad, 0x8c6b, 0x8c6e, 0x8c59, 0x8c63, 0x8cb1, 0x8cb2, 0x8cb3, + 0x8c76, 0x8cdc, 0x8cb4, 0x8cd0, 0x8cb5, 0x8cbd, 0x8cb6, 0x8cce, + 0x8c61, 0x8c45, 0x8cb8, 0x8cae, 0x8cba, 0x8c4f, 0x8cbc, 0x8c50, + 0x8cbf, 0x8c6a, 0x8c66, 0x8cc9, 0x8cbe, 0x8c43, 0x8c6d, 0x8c74, + 0x8cb7, 0x8cb9, 0x8cbb, 0x8cc0, 0x8cd7, 0x8cd8, 0x8cda, 0x8cc2, + 0x8c57, 0x8c79, 0x8c69, 0x8c7d, 0x8c54, 0x8ca1, 0x8ca4, 0x8c46, + 0x8ca8, 0x8ccf, 0x8cab, 0x8c4a, 0x8cb0, 0x8caf, 0x8c4c, 0x8cd5, + 0x8cd3, 0x8cd6, 0x8cd1, 0x8c5c, 0x8c6c, 0x8c4e, 0x8c65, 0x8cc1, + 0x8c64, 0x8c42, 0x8c55, 0x8c5f, +}; + +static const Summary16 hkscs2001_uni2indx_page35[6] = { + /* 0x3500 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0200 }, +}; +static const Summary16 hkscs2001_uni2indx_page3c[46] = { + /* 0x3c00 */ + { 1, 0x0000 }, { 1, 0x0000 }, { 1, 0x0000 }, { 1, 0x0000 }, + { 1, 0x0000 }, { 1, 0x0000 }, { 1, 0x0000 }, { 1, 0x0000 }, + { 1, 0x0800 }, { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, + { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, + /* 0x3d00 */ + { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, + { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, + { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0000 }, + { 2, 0x0200 }, { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, + /* 0x3e00 */ + { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, + { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, + { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, + { 3, 0x0000 }, { 3, 0x0800 }, +}; +static const Summary16 hkscs2001_uni2indx_page40[8] = { + /* 0x4000 */ + { 4, 0x0200 }, { 5, 0x0000 }, { 5, 0x0000 }, { 5, 0x0000 }, + { 5, 0x0000 }, { 5, 0x0000 }, { 5, 0x0000 }, { 5, 0x0002 }, +}; +static const Summary16 hkscs2001_uni2indx_page42[11] = { + /* 0x4200 */ + { 6, 0x0000 }, { 6, 0x0000 }, { 6, 0x0008 }, { 7, 0x0000 }, + { 7, 0x0000 }, { 7, 0x0000 }, { 7, 0x0000 }, { 7, 0x0040 }, + { 8, 0x0000 }, { 8, 0x0000 }, { 8, 0x0004 }, +}; +static const Summary16 hkscs2001_uni2indx_page4b[25] = { + /* 0x4b00 */ + { 9, 0x0000 }, { 9, 0x0001 }, { 10, 0x0001 }, { 11, 0x0000 }, + { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + /* 0x4c00 */ + { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0002 }, +}; +static const Summary16 hkscs2001_uni2indx_page4e[59] = { + /* 0x4e00 */ + { 12, 0x0000 }, { 12, 0x0000 }, { 12, 0x8000 }, { 13, 0x0000 }, + { 13, 0x0000 }, { 13, 0x0000 }, { 13, 0x0000 }, { 13, 0x0000 }, + { 13, 0x0000 }, { 13, 0x0000 }, { 13, 0x0008 }, { 14, 0x0000 }, + { 14, 0x0000 }, { 14, 0x0000 }, { 14, 0x0000 }, { 14, 0x0000 }, + /* 0x4f00 */ + { 14, 0x0000 }, { 14, 0x0080 }, { 15, 0x0000 }, { 15, 0x0000 }, + { 15, 0x0000 }, { 15, 0x0000 }, { 15, 0x0000 }, { 15, 0x0000 }, + { 15, 0x0000 }, { 15, 0x0000 }, { 15, 0x0000 }, { 15, 0x0000 }, + { 15, 0x0000 }, { 15, 0x0000 }, { 15, 0x0000 }, { 15, 0x0001 }, + /* 0x5000 */ + { 16, 0x0000 }, { 16, 0x0000 }, { 16, 0x0000 }, { 16, 0x0800 }, + { 17, 0x0000 }, { 17, 0x0000 }, { 17, 0x0000 }, { 17, 0x0000 }, + { 17, 0x0000 }, { 17, 0x0000 }, { 17, 0x0000 }, { 17, 0x1000 }, + { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x0000 }, + /* 0x5100 */ + { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x0000 }, + { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x0000 }, + { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x4000 }, +}; +static const Summary16 hkscs2001_uni2indx_page53[20] = { + /* 0x5300 */ + { 19, 0x0000 }, { 19, 0x0000 }, { 19, 0x0010 }, { 20, 0x0000 }, + { 20, 0x0000 }, { 20, 0x0000 }, { 20, 0x0000 }, { 20, 0x0000 }, + { 20, 0x0000 }, { 20, 0x0000 }, { 20, 0x0000 }, { 20, 0x0000 }, + { 20, 0x0000 }, { 20, 0x0000 }, { 20, 0x0000 }, { 20, 0x0000 }, + /* 0x5400 */ + { 20, 0x0000 }, { 20, 0x0000 }, { 20, 0x0000 }, { 20, 0x0010 }, +}; +static const Summary16 hkscs2001_uni2indx_page57[30] = { + /* 0x5700 */ + { 21, 0x0000 }, { 21, 0x0000 }, { 21, 0x0000 }, { 21, 0x2000 }, + { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, + { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, + { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, + /* 0x5800 */ + { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, + { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, { 22, 0x0000 }, + { 22, 0x0000 }, { 22, 0x0004 }, { 23, 0x0000 }, { 23, 0x0000 }, + { 23, 0x0000 }, { 23, 0x0001 }, +}; +static const Summary16 hkscs2001_uni2indx_page5a[93] = { + /* 0x5a00 */ + { 24, 0x0000 }, { 24, 0x0400 }, { 25, 0x0000 }, { 25, 0x0000 }, + { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x0000 }, + { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x0000 }, + { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x0000 }, + /* 0x5b00 */ + { 25, 0x0000 }, { 25, 0x0020 }, { 26, 0x0000 }, { 26, 0x0000 }, + { 26, 0x0000 }, { 26, 0x0000 }, { 26, 0x0000 }, { 26, 0x0000 }, + { 26, 0x0000 }, { 26, 0x0040 }, { 27, 0x0000 }, { 27, 0x0000 }, + { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x0000 }, + /* 0x5c00 */ + { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x0000 }, + { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x0000 }, + { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x0000 }, + { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x0020 }, + /* 0x5d00 */ + { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0000 }, + { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0800 }, + { 29, 0x0000 }, { 29, 0x0000 }, { 29, 0x0000 }, { 29, 0x0000 }, + { 29, 0x0000 }, { 29, 0x0000 }, { 29, 0x0000 }, { 29, 0x0000 }, + /* 0x5e00 */ + { 29, 0x0000 }, { 29, 0x0000 }, { 29, 0x0000 }, { 29, 0x0000 }, + { 29, 0x0000 }, { 29, 0x0000 }, { 29, 0x0000 }, { 29, 0x0000 }, + { 29, 0x0000 }, { 29, 0x0204 }, { 31, 0x0000 }, { 31, 0x0000 }, + { 31, 0x0000 }, { 31, 0x0000 }, { 31, 0x0000 }, { 31, 0x0000 }, + /* 0x5f00 */ + { 31, 0x0000 }, { 31, 0x0000 }, { 31, 0x0000 }, { 31, 0x0000 }, + { 31, 0x0000 }, { 31, 0x0000 }, { 31, 0x0000 }, { 31, 0x0000 }, + { 31, 0x0000 }, { 31, 0x0000 }, { 31, 0x0000 }, { 31, 0x0000 }, + { 31, 0x0004 }, +}; +static const Summary16 hkscs2001_uni2indx_page61[3] = { + /* 0x6100 */ + { 32, 0x0000 }, { 32, 0x0000 }, { 32, 0x0004 }, +}; +static const Summary16 hkscs2001_uni2indx_page65[9] = { + /* 0x6500 */ + { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0000 }, + { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0000 }, { 33, 0x0000 }, + { 33, 0x0800 }, +}; +static const Summary16 hkscs2001_uni2indx_page67[7] = { + /* 0x6700 */ + { 34, 0x0000 }, { 34, 0x0200 }, { 35, 0x0000 }, { 35, 0x0000 }, + { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0800 }, +}; +static const Summary16 hkscs2001_uni2indx_page69[23] = { + /* 0x6900 */ + { 36, 0x0000 }, { 36, 0x0200 }, { 37, 0x0000 }, { 37, 0x0000 }, + { 37, 0x0000 }, { 37, 0x0000 }, { 37, 0x0000 }, { 37, 0x0000 }, + { 37, 0x0000 }, { 37, 0x0000 }, { 37, 0x0000 }, { 37, 0x0000 }, + { 37, 0x0000 }, { 37, 0x0000 }, { 37, 0x0000 }, { 37, 0x0000 }, + /* 0x6a00 */ + { 37, 0x0000 }, { 37, 0x0000 }, { 37, 0x0000 }, { 37, 0x0000 }, + { 37, 0x0008 }, { 38, 0x0000 }, { 38, 0x0008 }, +}; +static const Summary16 hkscs2001_uni2indx_page6c[32] = { + /* 0x6c00 */ + { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, + { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, + { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, + { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x8000 }, + /* 0x6d00 */ + { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0000 }, + { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0000 }, + { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0000 }, + { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x0000 }, { 40, 0x4000 }, +}; +static const Summary16 hkscs2001_uni2indx_page70[76] = { + /* 0x7000 */ + { 41, 0x0000 }, { 41, 0x0000 }, { 41, 0x0000 }, { 41, 0x0000 }, + { 41, 0x2000 }, { 42, 0x0000 }, { 42, 0x0000 }, { 42, 0x0080 }, + { 43, 0x0000 }, { 43, 0x0000 }, { 43, 0x0000 }, { 43, 0x0000 }, + { 43, 0x0000 }, { 43, 0x0000 }, { 43, 0x0000 }, { 43, 0x0000 }, + /* 0x7100 */ + { 43, 0x0000 }, { 43, 0x0000 }, { 43, 0x0000 }, { 43, 0x0000 }, + { 43, 0x0000 }, { 43, 0x0000 }, { 43, 0x0000 }, { 43, 0x0000 }, + { 43, 0x0000 }, { 43, 0x0002 }, { 44, 0x0000 }, { 44, 0x0000 }, + { 44, 0x0000 }, { 44, 0x0000 }, { 44, 0x0000 }, { 44, 0x0000 }, + /* 0x7200 */ + { 44, 0x0001 }, { 45, 0x0000 }, { 45, 0x0000 }, { 45, 0x0000 }, + { 45, 0x0000 }, { 45, 0x0000 }, { 45, 0x0000 }, { 45, 0x0000 }, + { 45, 0x0000 }, { 45, 0x0000 }, { 45, 0x0000 }, { 45, 0x0000 }, + { 45, 0x0000 }, { 45, 0x0000 }, { 45, 0x0000 }, { 45, 0x0000 }, + /* 0x7300 */ + { 45, 0x0000 }, { 45, 0x0000 }, { 45, 0x0000 }, { 45, 0x0000 }, + { 45, 0x0000 }, { 45, 0x0000 }, { 45, 0x0000 }, { 45, 0x0000 }, + { 45, 0x1000 }, { 46, 0x0000 }, { 46, 0x0000 }, { 46, 0x0400 }, + { 47, 0x0000 }, { 47, 0x0000 }, { 47, 0x0000 }, { 47, 0x0000 }, + /* 0x7400 */ + { 47, 0x0004 }, { 48, 0x0000 }, { 48, 0x0000 }, { 48, 0x0000 }, + { 48, 0x0000 }, { 48, 0x0000 }, { 48, 0x0000 }, { 48, 0x0000 }, + { 48, 0x0000 }, { 48, 0x0000 }, { 48, 0x0000 }, { 48, 0x0200 }, +}; +static const Summary16 hkscs2001_uni2indx_page76[47] = { + /* 0x7600 */ + { 49, 0x0000 }, { 49, 0x0000 }, { 49, 0x0000 }, { 49, 0x0000 }, + { 49, 0x0000 }, { 49, 0x0000 }, { 49, 0x0000 }, { 49, 0x0000 }, + { 49, 0x0000 }, { 49, 0x0000 }, { 49, 0x0000 }, { 49, 0x0000 }, + { 49, 0x0000 }, { 49, 0x0200 }, { 50, 0x0000 }, { 50, 0x0000 }, + /* 0x7700 */ + { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, + { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, + { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, + { 50, 0x0000 }, { 50, 0x2000 }, { 51, 0x0000 }, { 51, 0x0000 }, + /* 0x7800 */ + { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0000 }, + { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0000 }, + { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0000 }, + { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0010 }, +}; +static const Summary16 hkscs2001_uni2indx_page7a[71] = { + /* 0x7a00 */ + { 52, 0x0000 }, { 52, 0x0000 }, { 52, 0x0400 }, { 53, 0x0000 }, + { 53, 0x0000 }, { 53, 0x0000 }, { 53, 0x0000 }, { 53, 0x0000 }, + { 53, 0x0000 }, { 53, 0x0008 }, { 54, 0x0000 }, { 54, 0x0000 }, + { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x0000 }, + /* 0x7b00 */ + { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x0000 }, + { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x0000 }, + { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x0000 }, + { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x1000 }, { 55, 0x0000 }, + /* 0x7c00 */ + { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0000 }, + { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0000 }, + { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0000 }, + { 55, 0x0008 }, { 56, 0x0000 }, { 56, 0x0000 }, { 56, 0x0000 }, + /* 0x7d00 */ + { 56, 0x0000 }, { 56, 0x0000 }, { 56, 0x0000 }, { 56, 0x0000 }, + { 56, 0x0000 }, { 56, 0x0000 }, { 56, 0x0000 }, { 56, 0x0000 }, + { 56, 0x0800 }, { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, + { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, + /* 0x7e00 */ + { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, + { 57, 0x0000 }, { 57, 0x0800 }, { 58, 0x1000 }, +}; +static const Summary16 hkscs2001_uni2indx_page82[16] = { + /* 0x8200 */ + { 59, 0x0000 }, { 59, 0x0000 }, { 59, 0x0000 }, { 59, 0x0000 }, + { 59, 0x0000 }, { 59, 0x0000 }, { 59, 0x0000 }, { 59, 0x0000 }, + { 59, 0x0000 }, { 59, 0x0000 }, { 59, 0x0000 }, { 59, 0x8000 }, + { 60, 0x0000 }, { 60, 0x0000 }, { 60, 0x0000 }, { 60, 0x0100 }, +}; +static const Summary16 hkscs2001_uni2indx_page85[17] = { + /* 0x8500 */ + { 61, 0x0000 }, { 61, 0x0000 }, { 61, 0x0000 }, { 61, 0x0000 }, + { 61, 0x0000 }, { 61, 0x8000 }, { 62, 0x0000 }, { 62, 0x0000 }, + { 62, 0x0000 }, { 62, 0x0080 }, { 63, 0x0000 }, { 63, 0x0000 }, + { 63, 0x0000 }, { 63, 0x0040 }, { 64, 0x0000 }, { 64, 0x0000 }, + /* 0x8600 */ + { 64, 0x8000 }, +}; +static const Summary16 hkscs2001_uni2indx_page88[10] = { + /* 0x8800 */ + { 65, 0x0000 }, { 65, 0x0000 }, { 65, 0x0000 }, { 65, 0x0000 }, + { 65, 0x0000 }, { 65, 0x0000 }, { 65, 0x0000 }, { 65, 0x0000 }, + { 65, 0x8000 }, { 66, 0x0001 }, +}; +static const Summary16 hkscs2001_uni2indx_page8b[9] = { + /* 0x8b00 */ + { 67, 0x0000 }, { 67, 0x0000 }, { 67, 0x0000 }, { 67, 0x0000 }, + { 67, 0x0000 }, { 67, 0x0000 }, { 67, 0x0000 }, { 67, 0x0000 }, + { 67, 0x0008 }, +}; +static const Summary16 hkscs2001_uni2indx_page8e[29] = { + /* 0x8e00 */ + { 68, 0x0000 }, { 68, 0x0000 }, { 68, 0x0000 }, { 68, 0x0000 }, + { 68, 0x0000 }, { 68, 0x0000 }, { 68, 0x0000 }, { 68, 0x0000 }, + { 68, 0x0000 }, { 68, 0x0000 }, { 68, 0x0000 }, { 68, 0x0200 }, + { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0000 }, + /* 0x8f00 */ + { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0000 }, + { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0000 }, + { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0080 }, { 70, 0x0000 }, + { 70, 0x8000 }, +}; +static const Summary16 hkscs2001_uni2indx_page91[48] = { + /* 0x9100 */ + { 71, 0x0000 }, { 71, 0x0000 }, { 71, 0x0000 }, { 71, 0x0000 }, + { 71, 0x0000 }, { 71, 0x0000 }, { 71, 0x0000 }, { 71, 0x0000 }, + { 71, 0x0000 }, { 71, 0x0000 }, { 71, 0x0000 }, { 71, 0x0000 }, + { 71, 0x0000 }, { 71, 0x0000 }, { 71, 0x0000 }, { 71, 0x0040 }, + /* 0x9200 */ + { 72, 0x0000 }, { 72, 0x0000 }, { 72, 0x0002 }, { 73, 0x0000 }, + { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, + { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, + { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, + /* 0x9300 */ + { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, + { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, + { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, + { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0010 }, +}; +static const Summary16 hkscs2001_uni2indx_page97[47] = { + /* 0x9700 */ + { 74, 0x0000 }, { 74, 0x0000 }, { 74, 0x0000 }, { 74, 0x0000 }, + { 74, 0x0000 }, { 74, 0x0020 }, { 75, 0x0000 }, { 75, 0x0000 }, + { 75, 0x0000 }, { 75, 0x0000 }, { 75, 0x0000 }, { 75, 0x0000 }, + { 75, 0x0000 }, { 75, 0x0000 }, { 75, 0x0000 }, { 75, 0x0000 }, + /* 0x9800 */ + { 75, 0x0000 }, { 75, 0x0000 }, { 75, 0x0000 }, { 75, 0x0000 }, + { 75, 0x0000 }, { 75, 0x0000 }, { 75, 0x0100 }, { 76, 0x0000 }, + { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, + { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, + /* 0x9900 */ + { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, + { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, + { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, + { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0001 }, +}; +static const Summary16 hkscs2001_uni2indx_page9f[11] = { + /* 0x9f00 */ + { 77, 0x0000 }, { 77, 0x0000 }, { 77, 0x0000 }, { 77, 0x0000 }, + { 77, 0x0000 }, { 77, 0x0000 }, { 77, 0x0000 }, { 77, 0x0000 }, + { 77, 0x0000 }, { 77, 0x0000 }, { 77, 0xffc0 }, +}; +static const Summary16 hkscs2001_uni2indx_page214[4] = { + /* 0x21400 */ + { 87, 0x0000 }, { 87, 0x0000 }, { 87, 0x0000 }, { 87, 0x8000 }, +}; +static const Summary16 hkscs2001_uni2indx_page219[9] = { + /* 0x21900 */ + { 88, 0x0000 }, { 88, 0x0000 }, { 88, 0x0000 }, { 88, 0x0000 }, + { 88, 0x0000 }, { 88, 0x0000 }, { 88, 0x0000 }, { 88, 0x0000 }, + { 88, 0x0001 }, +}; +static const Summary16 hkscs2001_uni2indx_page21d[12] = { + /* 0x21d00 */ + { 89, 0x0000 }, { 89, 0x0000 }, { 89, 0x0000 }, { 89, 0x0000 }, + { 89, 0x0000 }, { 89, 0x0000 }, { 89, 0x0000 }, { 89, 0x0000 }, + { 89, 0x0000 }, { 89, 0x0000 }, { 89, 0x0000 }, { 89, 0x0040 }, +}; +static const Summary16 hkscs2001_uni2indx_page220[8] = { + /* 0x22000 */ + { 90, 0x0000 }, { 90, 0x0000 }, { 90, 0x0000 }, { 90, 0x0000 }, + { 90, 0x0000 }, { 90, 0x0000 }, { 90, 0x0000 }, { 90, 0x4000 }, +}; +static const Summary16 hkscs2001_uni2indx_page227[2] = { + /* 0x22700 */ + { 91, 0x0000 }, { 91, 0x0004 }, +}; +static const Summary16 hkscs2001_uni2indx_page232[32] = { + /* 0x23200 */ + { 92, 0x0000 }, { 92, 0x0000 }, { 92, 0x0000 }, { 92, 0x0000 }, + { 92, 0x0000 }, { 92, 0x0000 }, { 92, 0x0000 }, { 92, 0x0000 }, + { 92, 0x0002 }, { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, + { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, + /* 0x23300 */ + { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, + { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, + { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, + { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0200 }, +}; +static const Summary16 hkscs2001_uni2indx_page23c[7] = { + /* 0x23c00 */ + { 94, 0x0000 }, { 94, 0x0000 }, { 94, 0x0000 }, { 94, 0x0000 }, + { 94, 0x0000 }, { 94, 0x0000 }, { 94, 0x0008 }, +}; +static const Summary16 hkscs2001_uni2indx_page241[5] = { + /* 0x24100 */ + { 95, 0x0000 }, { 95, 0x0000 }, { 95, 0x0000 }, { 95, 0x0000 }, + { 95, 0x4000 }, +}; +static const Summary16 hkscs2001_uni2indx_page245[1] = { + /* 0x24500 */ + { 96, 0x0020 }, +}; +static const Summary16 hkscs2001_uni2indx_page249[18] = { + /* 0x24900 */ + { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, + { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0800 }, + { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x0000 }, + { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x0000 }, + /* 0x24a00 */ + { 98, 0x0000 }, { 98, 0x0008 }, +}; +static const Summary16 hkscs2001_uni2indx_page251[13] = { + /* 0x25100 */ + { 99, 0x0000 }, { 99, 0x0000 }, { 99, 0x0000 }, { 99, 0x0000 }, + { 99, 0x0000 }, { 99, 0x0000 }, { 99, 0x0000 }, { 99, 0x0000 }, + { 99, 0x0000 }, { 99, 0x0000 }, { 99, 0x0000 }, { 99, 0x0000 }, + { 99, 0x2000 }, +}; +static const Summary16 hkscs2001_uni2indx_page256[10] = { + /* 0x25600 */ + { 100, 0x0000 }, { 100, 0x0000 }, { 100, 0x0000 }, { 100, 0x0000 }, + { 100, 0x0000 }, { 100, 0x0000 }, { 100, 0x0000 }, { 100, 0x0000 }, + { 100, 0x0000 }, { 100, 0x0020 }, +}; +static const Summary16 hkscs2001_uni2indx_page25c[20] = { + /* 0x25c00 */ + { 101, 0x0000 }, { 101, 0x0000 }, { 101, 0x0000 }, { 101, 0x0000 }, + { 101, 0x0000 }, { 101, 0x0000 }, { 101, 0x0000 }, { 101, 0x0000 }, + { 101, 0x0000 }, { 101, 0x0000 }, { 101, 0x0010 }, { 102, 0x0000 }, + { 102, 0x0000 }, { 102, 0x0000 }, { 102, 0x0000 }, { 102, 0x0000 }, + /* 0x25d00 */ + { 102, 0x0000 }, { 102, 0x0000 }, { 102, 0x0000 }, { 102, 0x0001 }, +}; +static const Summary16 hkscs2001_uni2indx_page26b[2] = { + /* 0x26b00 */ + { 103, 0x0000 }, { 103, 0x0020 }, +}; +static const Summary16 hkscs2001_uni2indx_page26d[8] = { + /* 0x26d00 */ + { 104, 0x0000 }, { 104, 0x0000 }, { 104, 0x0000 }, { 104, 0x0000 }, + { 104, 0x0000 }, { 104, 0x0000 }, { 104, 0x0000 }, { 104, 0x0010 }, +}; +static const Summary16 hkscs2001_uni2indx_page26f[12] = { + /* 0x26f00 */ + { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x0000 }, + { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x0000 }, + { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x4000 }, +}; +static const Summary16 hkscs2001_uni2indx_page271[1] = { + /* 0x27100 */ + { 106, 0x2000 }, +}; +static const Summary16 hkscs2001_uni2indx_page287[1] = { + /* 0x28700 */ + { 107, 0x8000 }, +}; +static const Summary16 hkscs2001_uni2indx_page289[31] = { + /* 0x28900 */ + { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0000 }, + { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0000 }, + { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0000 }, + { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0008 }, { 109, 0x0000 }, + /* 0x28a00 */ + { 109, 0x0000 }, { 109, 0x0000 }, { 109, 0x0000 }, { 109, 0x0004 }, + { 110, 0x0000 }, { 110, 0x0000 }, { 110, 0x0000 }, { 110, 0x0000 }, + { 110, 0x0000 }, { 110, 0x0000 }, { 110, 0x0000 }, { 110, 0x0000 }, + { 110, 0x0000 }, { 110, 0x0000 }, { 110, 0x0400 }, +}; +static const Summary16 hkscs2001_uni2indx_page28d[12] = { + /* 0x28d00 */ + { 111, 0x0000 }, { 111, 0x0000 }, { 111, 0x0000 }, { 111, 0x0000 }, + { 111, 0x0000 }, { 111, 0x0000 }, { 111, 0x0000 }, { 111, 0x0000 }, + { 111, 0x0000 }, { 111, 0x0000 }, { 111, 0x0000 }, { 111, 0x0200 }, +}; +static const Summary16 hkscs2001_uni2indx_page299[5] = { + /* 0x29900 */ + { 112, 0x0000 }, { 112, 0x0000 }, { 112, 0x0000 }, { 112, 0x0000 }, + { 112, 0x0080 }, +}; +static const Summary16 hkscs2001_uni2indx_page29c[8] = { + /* 0x29c00 */ + { 113, 0x0000 }, { 113, 0x0000 }, { 113, 0x0000 }, { 113, 0x0000 }, + { 113, 0x0000 }, { 113, 0x0000 }, { 113, 0x0000 }, { 113, 0x0008 }, +}; +static const Summary16 hkscs2001_uni2indx_page2a1[28] = { + /* 0x2a100 */ + { 114, 0x0080 }, { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, + { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, + { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, + { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, + /* 0x2a200 */ + { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, + { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, + { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0400 }, +}; + +static int +hkscs2001_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc < 0x9f00) { + if (wc < 0x6900) { + if (wc >= 0x3500 && wc < 0x3560) + summary = &hkscs2001_uni2indx_page35[(wc>>4)-0x350]; + else if (wc >= 0x3c00 && wc < 0x3ee0) + summary = &hkscs2001_uni2indx_page3c[(wc>>4)-0x3c0]; + else if (wc >= 0x4000 && wc < 0x4080) + summary = &hkscs2001_uni2indx_page40[(wc>>4)-0x400]; + else if (wc >= 0x4200 && wc < 0x42b0) + summary = &hkscs2001_uni2indx_page42[(wc>>4)-0x420]; + else if (wc >= 0x4b00 && wc < 0x4c90) + summary = &hkscs2001_uni2indx_page4b[(wc>>4)-0x4b0]; + else if (wc >= 0x4e00 && wc < 0x51b0) + summary = &hkscs2001_uni2indx_page4e[(wc>>4)-0x4e0]; + else if (wc >= 0x5300 && wc < 0x5440) + summary = &hkscs2001_uni2indx_page53[(wc>>4)-0x530]; + else if (wc >= 0x5700 && wc < 0x58e0) + summary = &hkscs2001_uni2indx_page57[(wc>>4)-0x570]; + else if (wc >= 0x5a00 && wc < 0x5fd0) + summary = &hkscs2001_uni2indx_page5a[(wc>>4)-0x5a0]; + else if (wc >= 0x6100 && wc < 0x6130) + summary = &hkscs2001_uni2indx_page61[(wc>>4)-0x610]; + else if (wc >= 0x6500 && wc < 0x6590) + summary = &hkscs2001_uni2indx_page65[(wc>>4)-0x650]; + else if (wc >= 0x6700 && wc < 0x6770) + summary = &hkscs2001_uni2indx_page67[(wc>>4)-0x670]; + } else { + if (wc >= 0x6900 && wc < 0x6a70) + summary = &hkscs2001_uni2indx_page69[(wc>>4)-0x690]; + else if (wc >= 0x6c00 && wc < 0x6e00) + summary = &hkscs2001_uni2indx_page6c[(wc>>4)-0x6c0]; + else if (wc >= 0x7000 && wc < 0x74c0) + summary = &hkscs2001_uni2indx_page70[(wc>>4)-0x700]; + else if (wc >= 0x7600 && wc < 0x78f0) + summary = &hkscs2001_uni2indx_page76[(wc>>4)-0x760]; + else if (wc >= 0x7a00 && wc < 0x7e70) + summary = &hkscs2001_uni2indx_page7a[(wc>>4)-0x7a0]; + else if (wc >= 0x8200 && wc < 0x8300) + summary = &hkscs2001_uni2indx_page82[(wc>>4)-0x820]; + else if (wc >= 0x8500 && wc < 0x8610) + summary = &hkscs2001_uni2indx_page85[(wc>>4)-0x850]; + else if (wc >= 0x8800 && wc < 0x88a0) + summary = &hkscs2001_uni2indx_page88[(wc>>4)-0x880]; + else if (wc >= 0x8b00 && wc < 0x8b90) + summary = &hkscs2001_uni2indx_page8b[(wc>>4)-0x8b0]; + else if (wc >= 0x8e00 && wc < 0x8fd0) + summary = &hkscs2001_uni2indx_page8e[(wc>>4)-0x8e0]; + else if (wc >= 0x9100 && wc < 0x9400) + summary = &hkscs2001_uni2indx_page91[(wc>>4)-0x910]; + else if (wc >= 0x9700 && wc < 0x99f0) + summary = &hkscs2001_uni2indx_page97[(wc>>4)-0x970]; + } + } else { + if (wc < 0x25600) { + if (wc >= 0x9f00 && wc < 0x9fb0) + summary = &hkscs2001_uni2indx_page9f[(wc>>4)-0x9f0]; + else if (wc >= 0x21400 && wc < 0x21440) + summary = &hkscs2001_uni2indx_page214[(wc>>4)-0x2140]; + else if (wc >= 0x21900 && wc < 0x21990) + summary = &hkscs2001_uni2indx_page219[(wc>>4)-0x2190]; + else if (wc >= 0x21d00 && wc < 0x21dc0) + summary = &hkscs2001_uni2indx_page21d[(wc>>4)-0x21d0]; + else if (wc >= 0x22000 && wc < 0x22080) + summary = &hkscs2001_uni2indx_page220[(wc>>4)-0x2200]; + else if (wc >= 0x22700 && wc < 0x22720) + summary = &hkscs2001_uni2indx_page227[(wc>>4)-0x2270]; + else if (wc >= 0x23200 && wc < 0x23400) + summary = &hkscs2001_uni2indx_page232[(wc>>4)-0x2320]; + else if (wc >= 0x23c00 && wc < 0x23c70) + summary = &hkscs2001_uni2indx_page23c[(wc>>4)-0x23c0]; + else if (wc >= 0x24100 && wc < 0x24150) + summary = &hkscs2001_uni2indx_page241[(wc>>4)-0x2410]; + else if (wc >= 0x24500 && wc < 0x24510) + summary = &hkscs2001_uni2indx_page245[(wc>>4)-0x2450]; + else if (wc >= 0x24900 && wc < 0x24a20) + summary = &hkscs2001_uni2indx_page249[(wc>>4)-0x2490]; + else if (wc >= 0x25100 && wc < 0x251d0) + summary = &hkscs2001_uni2indx_page251[(wc>>4)-0x2510]; + } else { + if (wc >= 0x25600 && wc < 0x256a0) + summary = &hkscs2001_uni2indx_page256[(wc>>4)-0x2560]; + else if (wc >= 0x25c00 && wc < 0x25d40) + summary = &hkscs2001_uni2indx_page25c[(wc>>4)-0x25c0]; + else if (wc >= 0x26b00 && wc < 0x26b20) + summary = &hkscs2001_uni2indx_page26b[(wc>>4)-0x26b0]; + else if (wc >= 0x26d00 && wc < 0x26d80) + summary = &hkscs2001_uni2indx_page26d[(wc>>4)-0x26d0]; + else if (wc >= 0x26f00 && wc < 0x26fc0) + summary = &hkscs2001_uni2indx_page26f[(wc>>4)-0x26f0]; + else if (wc >= 0x27100 && wc < 0x27110) + summary = &hkscs2001_uni2indx_page271[(wc>>4)-0x2710]; + else if (wc >= 0x28700 && wc < 0x28710) + summary = &hkscs2001_uni2indx_page287[(wc>>4)-0x2870]; + else if (wc >= 0x28900 && wc < 0x28af0) + summary = &hkscs2001_uni2indx_page289[(wc>>4)-0x2890]; + else if (wc >= 0x28d00 && wc < 0x28dc0) + summary = &hkscs2001_uni2indx_page28d[(wc>>4)-0x28d0]; + else if (wc >= 0x29900 && wc < 0x29950) + summary = &hkscs2001_uni2indx_page299[(wc>>4)-0x2990]; + else if (wc >= 0x29c00 && wc < 0x29c80) + summary = &hkscs2001_uni2indx_page29c[(wc>>4)-0x29c0]; + else if (wc >= 0x2a100 && wc < 0x2a2c0) + summary = &hkscs2001_uni2indx_page2a1[(wc>>4)-0x2a10]; + } + } + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = hkscs2001_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/hkscs2004.h b/graf2d/win32gdk/gdk/src/iconv/hkscs2004.h new file mode 100644 index 0000000000000..d5ab99748cadc --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/hkscs2004.h @@ -0,0 +1,679 @@ +/* + * Copyright (C) 1999-2006 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * HKSCS:2004 + */ + +static const unsigned short hkscs2004_2uni_page87[58] = { + /* 0x87 */ + 0x0af0, 0x1032, 0x0d03, 0x0ca6, 0x0c78, 0x4167, 0x1177, 0x0cb3, + 0x44b1, 0x10e2, 0x44c5, 0x0595, 0x0e36, 0x0e44, 0x1047, 0x1040, + 0x39bf, 0x3417, 0x4252, 0x3f8b, 0x40d2, 0x1057, 0x4d51, 0x0e4f, + 0x0cda, 0x1085, 0x446c, 0x1107, 0x0fa4, 0x0da1, 0x3d23, 0x1e25, + 0x3c54, 0x2d63, 0x3606, 0x3761, 0x1a4d, 0x13fb, 0x28fd, 0x2195, + 0x141d, 0x47b9, 0x06f4, 0x2534, 0x43ef, 0x16db, 0x2e5e, 0x15a4, + 0x0125, 0x4bb0, 0x15d1, 0x16b7, 0x17fc, 0x1b6e, 0x2393, 0x4a45, + 0x1f61, 0x1f9d, +}; +static const unsigned short hkscs2004_2uni_page8c[189] = { + /* 0x8c */ + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x2b6f, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, 0x28fd, + 0x28fd, 0x1ae7, 0x28fd, 0x1c57, 0x20ca, 0x0688, 0x0bc3, 0x3256, + 0x3196, 0x0a9a, 0x0c36, 0x28fd, 0x17d5, 0x351a, 0x24f9, 0x1778, + 0x0612, 0x3351, 0x1878, 0x27b2, 0x1d57, 0x0c58, 0x38ec, 0x2f23, + 0x1077, 0x0478, 0x004a, 0x29a4, 0x3e41, 0x24cc, 0x12b4, 0x2a39, + 0x14bf, 0x226c, 0x2656, 0x49fa, 0x193b, + /* 0x8d */ + 0x2c9f, 0x28fd, 0x30c1, 0x466d, 0x0902, 0x0dbb, 0x4879, 0x0707, + 0x27b3, 0x4cb5, 0x08f8, 0x02d6, 0x0df7, 0x3e46, 0x097c, 0x45b2, + 0x42ff, 0x0c6d, 0x03d4, 0x3b9a, 0x0c61, 0x0c1b, 0x1189, 0x107b, + 0x1176, 0x0cea, 0x07c8, 0x3a0f, 0x0161, 0x0bde, 0x0bbd, 0x09ed, +}; + +static const ucs4_t hkscs2004_2uni_upages[78] = { + 0x03400, 0x03600, 0x03700, 0x03800, 0x03900, 0x03b00, 0x03d00, 0x03f00, + 0x04000, 0x04100, 0x04300, 0x04400, 0x04500, 0x04600, 0x04700, 0x04a00, + 0x04c00, 0x04d00, 0x04f00, 0x05600, 0x05900, 0x05a00, 0x05b00, 0x05c00, + 0x05d00, 0x05f00, 0x06600, 0x06700, 0x06e00, 0x07100, 0x07200, 0x07400, + 0x07900, 0x07d00, 0x08100, 0x08500, 0x08a00, 0x09700, 0x09800, 0x09f00, + 0x0ff00, 0x20100, 0x20200, 0x20a00, 0x20b00, 0x21a00, 0x21d00, 0x21e00, + 0x22100, 0x22700, 0x23200, 0x23500, 0x23600, 0x23b00, 0x23e00, 0x23f00, + 0x24000, 0x24200, 0x24b00, 0x25400, 0x25a00, 0x26b00, 0x26c00, 0x26e00, + 0x27000, 0x27200, 0x27300, 0x27b00, 0x27c00, 0x28600, 0x28900, 0x28b00, + 0x29000, 0x29800, 0x29900, 0x29e00, 0x2a100, 0x2a300, +}; + +static int +hkscs2004_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 == 0x87) || (c1 >= 0x8c && c1 <= 0x8d)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 < 0x7f) || (c2 >= 0xa1 && c2 < 0xff)) { + unsigned int i = 157 * (c1 - 0x80) + (c2 - (c2 >= 0xa1 ? 0x62 : 0x40)); + ucs4_t wc = 0xfffd; + unsigned short swc; + if (i < 1884) { + if (i < 1157) + swc = hkscs2004_2uni_page87[i-1099], + wc = hkscs2004_2uni_upages[swc>>8] | (swc & 0xff); + } else { + if (i < 2073) + swc = hkscs2004_2uni_page8c[i-1884], + wc = hkscs2004_2uni_upages[swc>>8] | (swc & 0xff); + } + if (wc != 0xfffd) { + *pwc = wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short hkscs2004_2charset[123] = { + 0x8cf4, 0x8770, 0x8d5c, 0x8d4b, 0x8d52, 0x8cf3, 0x874b, 0x8cea, + 0x8cdf, 0x876a, 0x8d47, 0x8d5a, 0x8d4a, 0x8d44, 0x8d4e, 0x8d5f, + 0x8ce3, 0x8740, 0x8d5e, 0x8ce0, 0x8d5d, 0x8d55, 0x8ce4, 0x8cef, + 0x8d54, 0x8d51, 0x8744, 0x8743, 0x8747, 0x8758, 0x8d59, 0x8742, + 0x875d, 0x8d45, 0x8d4c, 0x874c, 0x874d, 0x8757, 0x875c, 0x8741, + 0x874f, 0x874e, 0x8755, 0x8cf2, 0x8d57, 0x8759, 0x8749, 0x875b, + 0x8d58, 0x8746, 0x8d56, 0x8cf8, 0x8765, 0x8768, 0x8cfa, 0x876f, + 0x8772, 0x8773, 0x876d, 0x8ce9, 0x8ce6, 0x8774, 0x8cec, 0x8cfe, + 0x8764, 0x8cdb, 0x8775, 0x8cdd, 0x8cee, 0x875f, 0x8778, 0x8779, + 0x8cde, 0x8767, 0x8cfb, 0x8776, 0x8cf7, 0x8ce8, 0x876b, 0x8cfc, + 0x8ced, 0x8d48, 0x8cf5, 0x8cf9, 0x8c62, 0x8d40, 0x8761, 0x876e, + 0x8cf1, 0x8d42, 0x8ce2, 0x8ce1, 0x8ceb, 0x8751, 0x8ce7, 0x8762, + 0x8763, 0x8cf0, 0x8750, 0x8d5b, 0x8d53, 0x8760, 0x875e, 0x8cf6, + 0x8d4d, 0x8753, 0x8754, 0x8745, 0x8752, 0x8d50, 0x876c, 0x875a, + 0x8748, 0x874a, 0x8d4f, 0x8d43, 0x8769, 0x8d46, 0x8cfd, 0x8777, + 0x8771, 0x8d49, 0x8756, +}; + +static const Summary16 hkscs2004_uni2indx_page34[5] = { + /* 0x3400 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0400 }, +}; +static const Summary16 hkscs2004_uni2indx_page36[56] = { + /* 0x3600 */ + { 1, 0x0000 }, { 1, 0x0000 }, { 1, 0x0020 }, { 2, 0x0000 }, + { 2, 0x0000 }, { 2, 0x0000 }, { 2, 0x0002 }, { 3, 0x0000 }, + { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, + { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, + /* 0x3700 */ + { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, + { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, + { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, { 3, 0x0000 }, + { 3, 0x0000 }, { 3, 0x0040 }, { 4, 0x0000 }, { 4, 0x0000 }, + /* 0x3800 */ + { 4, 0x0000 }, { 4, 0x0000 }, { 4, 0x0000 }, { 4, 0x0000 }, + { 4, 0x0000 }, { 4, 0x0000 }, { 4, 0x0000 }, { 4, 0x0000 }, + { 4, 0x0000 }, { 4, 0x0000 }, { 4, 0x0000 }, { 4, 0x0000 }, + { 4, 0x0000 }, { 4, 0x0010 }, { 5, 0x0000 }, { 5, 0x0000 }, + /* 0x3900 */ + { 5, 0x0000 }, { 5, 0x0000 }, { 5, 0x0000 }, { 5, 0x0000 }, + { 5, 0x0000 }, { 5, 0x0000 }, { 5, 0x0000 }, { 5, 0x0100 }, +}; +static const Summary16 hkscs2004_uni2indx_page3b[10] = { + /* 0x3b00 */ + { 6, 0x0000 }, { 6, 0x0000 }, { 6, 0x0000 }, { 6, 0x0000 }, + { 6, 0x0000 }, { 6, 0x0000 }, { 6, 0x0000 }, { 6, 0x0000 }, + { 6, 0x0000 }, { 6, 0x0020 }, +}; +static const Summary16 hkscs2004_uni2indx_page3d[16] = { + /* 0x3d00 */ + { 7, 0x0000 }, { 7, 0x0004 }, { 8, 0x0000 }, { 8, 0x0000 }, + { 8, 0x0000 }, { 8, 0x0000 }, { 8, 0x0000 }, { 8, 0x0000 }, + { 8, 0x0100 }, { 9, 0x0000 }, { 9, 0x0000 }, { 9, 0x0000 }, + { 9, 0x0000 }, { 9, 0x0000 }, { 9, 0x0000 }, { 9, 0x0010 }, +}; +static const Summary16 hkscs2004_uni2indx_page3f[47] = { + /* 0x3f00 */ + { 10, 0x0080 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0100 }, { 12, 0x0000 }, { 12, 0x0000 }, { 12, 0x0000 }, + /* 0x4000 */ + { 12, 0x0000 }, { 12, 0x0000 }, { 12, 0x0000 }, { 12, 0x0000 }, + { 12, 0x0000 }, { 12, 0x0000 }, { 12, 0x0000 }, { 12, 0x0000 }, + { 12, 0x0000 }, { 12, 0x0000 }, { 12, 0x0000 }, { 12, 0x0000 }, + { 12, 0x0000 }, { 12, 0x0000 }, { 12, 0x0000 }, { 12, 0x0100 }, + /* 0x4100 */ + { 13, 0x0004 }, { 14, 0x0000 }, { 14, 0x0000 }, { 14, 0x0000 }, + { 14, 0x0000 }, { 14, 0x0000 }, { 14, 0x0000 }, { 14, 0x1000 }, + { 15, 0x0000 }, { 15, 0x0000 }, { 15, 0x0000 }, { 15, 0x0000 }, + { 15, 0x0000 }, { 15, 0x0000 }, { 15, 0x2000 }, +}; +static const Summary16 hkscs2004_uni2indx_page43[69] = { + /* 0x4300 */ + { 16, 0x0000 }, { 16, 0x0000 }, { 16, 0x0000 }, { 16, 0x0000 }, + { 16, 0x0000 }, { 16, 0x0000 }, { 16, 0x0000 }, { 16, 0x0000 }, + { 16, 0x0000 }, { 16, 0x0400 }, { 17, 0x0000 }, { 17, 0x0000 }, + { 17, 0x0000 }, { 17, 0x0000 }, { 17, 0x0000 }, { 17, 0x0001 }, + /* 0x4400 */ + { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x0000 }, + { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x0000 }, + { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x0000 }, { 18, 0x2000 }, + { 19, 0x0008 }, { 20, 0x4000 }, { 21, 0x0000 }, { 21, 0x0000 }, + /* 0x4500 */ + { 21, 0x0000 }, { 21, 0x0800 }, { 22, 0x0000 }, { 22, 0x0040 }, + { 23, 0x0000 }, { 23, 0x0100 }, { 24, 0x2002 }, { 26, 0x0100 }, + { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x0040 }, { 28, 0x0008 }, + { 29, 0x0000 }, { 29, 0x0400 }, { 30, 0x0400 }, { 31, 0x0000 }, + /* 0x4600 */ + { 31, 0x0008 }, { 32, 0x0000 }, { 32, 0x0000 }, { 32, 0x0000 }, + { 32, 0x0000 }, { 32, 0x0000 }, { 32, 0x0000 }, { 32, 0x0000 }, + { 32, 0x0000 }, { 32, 0x0000 }, { 32, 0x0002 }, { 33, 0x0800 }, + { 34, 0x0000 }, { 34, 0x0000 }, { 34, 0x0000 }, { 34, 0x0080 }, + /* 0x4700 */ + { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0000 }, { 35, 0x0040 }, + { 36, 0x8010 }, +}; +static const Summary16 hkscs2004_uni2indx_page4a[11] = { + /* 0x4a00 */ + { 38, 0x0000 }, { 38, 0x0000 }, { 38, 0x0000 }, { 38, 0x0000 }, + { 38, 0x0000 }, { 38, 0x0000 }, { 38, 0x0000 }, { 38, 0x0000 }, + { 38, 0x0000 }, { 38, 0x0000 }, { 38, 0x0010 }, +}; +static const Summary16 hkscs2004_uni2indx_page4c[25] = { + /* 0x4c00 */ + { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0000 }, { 39, 0x0004 }, + { 40, 0x0081 }, { 42, 0x0080 }, { 43, 0x0000 }, { 43, 0x0880 }, + { 45, 0x0020 }, { 46, 0x0000 }, { 46, 0x0000 }, { 46, 0x0000 }, + { 46, 0x0000 }, { 46, 0x0000 }, { 46, 0x0004 }, { 47, 0x0000 }, + /* 0x4d00 */ + { 47, 0x0080 }, { 48, 0x0000 }, { 48, 0x0000 }, { 48, 0x0000 }, + { 48, 0x0000 }, { 48, 0x0000 }, { 48, 0x0000 }, { 48, 0x00c0 }, + { 50, 0x0200 }, +}; +static const Summary16 hkscs2004_uni2indx_page4f[12] = { + /* 0x4f00 */ + { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0000 }, + { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0000 }, + { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0000 }, { 51, 0x0010 }, +}; +static const Summary16 hkscs2004_uni2indx_page56[16] = { + /* 0x5600 */ + { 52, 0x0000 }, { 52, 0x0000 }, { 52, 0x0000 }, { 52, 0x0000 }, + { 52, 0x0000 }, { 52, 0x0000 }, { 52, 0x0000 }, { 52, 0x0000 }, + { 52, 0x0000 }, { 52, 0x0000 }, { 52, 0x0000 }, { 52, 0x0000 }, + { 52, 0x0000 }, { 52, 0x0000 }, { 52, 0x0000 }, { 52, 0x0800 }, +}; +static const Summary16 hkscs2004_uni2indx_page59[72] = { + /* 0x5900 */ + { 53, 0x0000 }, { 53, 0x2000 }, { 54, 0x0000 }, { 54, 0x0000 }, + { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x0000 }, + { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x0000 }, { 54, 0x8000 }, + { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0000 }, + /* 0x5a00 */ + { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0000 }, + { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0000 }, + { 55, 0x0000 }, { 55, 0x0000 }, { 55, 0x0010 }, { 56, 0x0000 }, + { 56, 0x0000 }, { 56, 0x0002 }, { 57, 0x0000 }, { 57, 0x0000 }, + /* 0x5b00 */ + { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, + { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, + { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0080 }, + { 58, 0x0000 }, { 58, 0x0800 }, { 59, 0x0000 }, { 59, 0x0000 }, + /* 0x5c00 */ + { 59, 0x0000 }, { 59, 0x0000 }, { 59, 0x0000 }, { 59, 0x0000 }, + { 59, 0x0000 }, { 59, 0x0000 }, { 59, 0x0000 }, { 59, 0x0100 }, + { 60, 0x0000 }, { 60, 0x0000 }, { 60, 0x0000 }, { 60, 0x0000 }, + { 60, 0x0000 }, { 60, 0x0020 }, { 61, 0x0000 }, { 61, 0x1000 }, + /* 0x5d00 */ + { 62, 0x0000 }, { 62, 0x0000 }, { 62, 0x0000 }, { 62, 0x0000 }, + { 62, 0x0000 }, { 62, 0x0000 }, { 62, 0x0000 }, { 62, 0x0100 }, +}; +static const Summary16 hkscs2004_uni2indx_page5f[4] = { + /* 0x5f00 */ + { 63, 0x0000 }, { 63, 0x0000 }, { 63, 0x0000 }, { 63, 0x0800 }, +}; +static const Summary16 hkscs2004_uni2indx_page66[23] = { + /* 0x6600 */ + { 64, 0x0000 }, { 64, 0x0000 }, { 64, 0x0000 }, { 64, 0x0000 }, + { 64, 0x2000 }, { 65, 0x0000 }, { 65, 0x0000 }, { 65, 0x0000 }, + { 65, 0x0000 }, { 65, 0x0000 }, { 65, 0x0000 }, { 65, 0x0000 }, + { 65, 0x0000 }, { 65, 0x0000 }, { 65, 0x0080 }, { 66, 0x0000 }, + /* 0x6700 */ + { 66, 0x0000 }, { 66, 0x0000 }, { 66, 0x0000 }, { 66, 0x0000 }, + { 66, 0x0000 }, { 66, 0x0000 }, { 66, 0x4000 }, +}; +static const Summary16 hkscs2004_uni2indx_page6e[6] = { + /* 0x6e00 */ + { 67, 0x0000 }, { 67, 0x0000 }, { 67, 0x0000 }, { 67, 0x0000 }, + { 67, 0x0000 }, { 67, 0x0080 }, +}; +static const Summary16 hkscs2004_uni2indx_page71[19] = { + /* 0x7100 */ + { 68, 0x0000 }, { 68, 0x0000 }, { 68, 0x0000 }, { 68, 0x0000 }, + { 68, 0x0000 }, { 68, 0x0080 }, { 69, 0x0000 }, { 69, 0x0000 }, + { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0000 }, + { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0000 }, + /* 0x7200 */ + { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0020 }, +}; +static const Summary16 hkscs2004_uni2indx_page74[10] = { + /* 0x7400 */ + { 70, 0x0000 }, { 70, 0x0000 }, { 70, 0x0000 }, { 70, 0x0000 }, + { 70, 0x0000 }, { 70, 0x0000 }, { 70, 0x0002 }, { 71, 0x0000 }, + { 71, 0x0000 }, { 71, 0x2000 }, +}; +static const Summary16 hkscs2004_uni2indx_page79[13] = { + /* 0x7900 */ + { 72, 0x0000 }, { 72, 0x0000 }, { 72, 0x0000 }, { 72, 0x0000 }, + { 72, 0x0000 }, { 72, 0x0000 }, { 72, 0x0000 }, { 72, 0x0000 }, + { 72, 0x0000 }, { 72, 0x0000 }, { 72, 0x0000 }, { 72, 0x0000 }, + { 72, 0x0400 }, +}; +static const Summary16 hkscs2004_uni2indx_page7d[10] = { + /* 0x7d00 */ + { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, + { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, { 73, 0x0000 }, + { 73, 0x0000 }, { 73, 0x0020 }, +}; +static const Summary16 hkscs2004_uni2indx_page81[7] = { + /* 0x8100 */ + { 74, 0x0000 }, { 74, 0x0000 }, { 74, 0x0000 }, { 74, 0x0000 }, + { 74, 0x0000 }, { 74, 0x0000 }, { 74, 0x1000 }, +}; +static const Summary16 hkscs2004_uni2indx_page85[10] = { + /* 0x8500 */ + { 75, 0x0000 }, { 75, 0x0000 }, { 75, 0x0000 }, { 75, 0x0000 }, + { 75, 0x0000 }, { 75, 0x0000 }, { 75, 0x0000 }, { 75, 0x0000 }, + { 75, 0x0000 }, { 75, 0x0008 }, +}; +static const Summary16 hkscs2004_uni2indx_page8a[16] = { + /* 0x8a00 */ + { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, + { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, + { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, { 76, 0x0000 }, + { 76, 0x1000 }, { 77, 0x0000 }, { 77, 0x0000 }, { 77, 0x0200 }, +}; +static const Summary16 hkscs2004_uni2indx_page97[22] = { + /* 0x9700 */ + { 78, 0x0000 }, { 78, 0x0000 }, { 78, 0x0000 }, { 78, 0x0010 }, + { 79, 0x0000 }, { 79, 0x0000 }, { 79, 0x0000 }, { 79, 0x0000 }, + { 79, 0x0000 }, { 79, 0x0000 }, { 79, 0x0000 }, { 79, 0x0000 }, + { 79, 0x0000 }, { 79, 0x0000 }, { 79, 0x0000 }, { 79, 0x0000 }, + /* 0x9800 */ + { 79, 0x0000 }, { 79, 0x0000 }, { 79, 0x0000 }, { 79, 0x0000 }, + { 79, 0x0000 }, { 79, 0x0040 }, +}; +static const Summary16 hkscs2004_uni2indx_page9f[12] = { + /* 0x9f00 */ + { 80, 0x0000 }, { 80, 0x0000 }, { 80, 0x0000 }, { 80, 0x0000 }, + { 80, 0x0000 }, { 80, 0x0000 }, { 80, 0x0000 }, { 80, 0x0000 }, + { 80, 0x0000 }, { 80, 0x0000 }, { 80, 0x0000 }, { 80, 0x000c }, +}; +static const Summary16 hkscs2004_uni2indx_page201[20] = { + /* 0x20100 */ + { 82, 0x0000 }, { 82, 0x0000 }, { 82, 0x0000 }, { 82, 0x0000 }, + { 82, 0x0000 }, { 82, 0x0000 }, { 82, 0x0000 }, { 82, 0x0000 }, + { 82, 0x0000 }, { 82, 0x0000 }, { 82, 0x0010 }, { 83, 0x0000 }, + { 83, 0x0000 }, { 83, 0x0000 }, { 83, 0x0000 }, { 83, 0x0000 }, + /* 0x20200 */ + { 83, 0x0000 }, { 83, 0x0000 }, { 83, 0x0000 }, { 83, 0x0200 }, +}; +static const Summary16 hkscs2004_uni2indx_page20a[26] = { + /* 0x20a00 */ + { 84, 0x0000 }, { 84, 0x0000 }, { 84, 0x0000 }, { 84, 0x0000 }, + { 84, 0x0000 }, { 84, 0x0000 }, { 84, 0x8000 }, { 85, 0x0000 }, + { 85, 0x0000 }, { 85, 0x0000 }, { 85, 0x0000 }, { 85, 0x0000 }, + { 85, 0x0000 }, { 85, 0x0000 }, { 85, 0x0000 }, { 85, 0x0000 }, + /* 0x20b00 */ + { 85, 0x0000 }, { 85, 0x0000 }, { 85, 0x0000 }, { 85, 0x0000 }, + { 85, 0x0000 }, { 85, 0x0000 }, { 85, 0x0000 }, { 85, 0x0000 }, + { 85, 0x0000 }, { 85, 0x8000 }, +}; +static const Summary16 hkscs2004_uni2indx_page21a[7] = { + /* 0x21a00 */ + { 86, 0x0000 }, { 86, 0x0000 }, { 86, 0x0000 }, { 86, 0x0000 }, + { 86, 0x0000 }, { 86, 0x0000 }, { 86, 0x0008 }, +}; +static const Summary16 hkscs2004_uni2indx_page21d[19] = { + /* 0x21d00 */ + { 87, 0x0000 }, { 87, 0x0000 }, { 87, 0x0000 }, { 87, 0x0000 }, + { 87, 0x0000 }, { 87, 0x4000 }, { 88, 0x0000 }, { 88, 0x0000 }, + { 88, 0x0000 }, { 88, 0x0000 }, { 88, 0x0000 }, { 88, 0x0000 }, + { 88, 0x0000 }, { 88, 0x0000 }, { 88, 0x0000 }, { 88, 0x0000 }, + /* 0x21e00 */ + { 88, 0x0000 }, { 88, 0x0000 }, { 88, 0x0008 }, +}; +static const Summary16 hkscs2004_uni2indx_page221[13] = { + /* 0x22100 */ + { 89, 0x0000 }, { 89, 0x0000 }, { 89, 0x0000 }, { 89, 0x0000 }, + { 89, 0x0000 }, { 89, 0x0000 }, { 89, 0x0000 }, { 89, 0x0000 }, + { 89, 0x0000 }, { 89, 0x0000 }, { 89, 0x0000 }, { 89, 0x0000 }, + { 89, 0x0002 }, +}; +static const Summary16 hkscs2004_uni2indx_page227[10] = { + /* 0x22700 */ + { 90, 0x0000 }, { 90, 0x0000 }, { 90, 0x0000 }, { 90, 0x0000 }, + { 90, 0x0000 }, { 90, 0x0000 }, { 90, 0x0000 }, { 90, 0x0000 }, + { 90, 0x0000 }, { 90, 0x0040 }, +}; +static const Summary16 hkscs2004_uni2indx_page232[6] = { + /* 0x23200 */ + { 91, 0x0000 }, { 91, 0x0000 }, { 91, 0x0000 }, { 91, 0x0000 }, + { 91, 0x0000 }, { 91, 0x0040 }, +}; +static const Summary16 hkscs2004_uni2indx_page235[18] = { + /* 0x23500 */ + { 92, 0x0000 }, { 92, 0x0000 }, { 92, 0x0000 }, { 92, 0x0000 }, + { 92, 0x0000 }, { 92, 0x0002 }, { 93, 0x0000 }, { 93, 0x0000 }, + { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, + { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, { 93, 0x0000 }, + /* 0x23600 */ + { 93, 0x0000 }, { 93, 0x0080 }, +}; +static const Summary16 hkscs2004_uni2indx_page23b[2] = { + /* 0x23b00 */ + { 94, 0x0000 }, { 94, 0x0400 }, +}; +static const Summary16 hkscs2004_uni2indx_page23e[47] = { + /* 0x23e00 */ + { 95, 0x0040 }, { 96, 0x0000 }, { 96, 0x0000 }, { 96, 0x0000 }, + { 96, 0x0000 }, { 96, 0x0000 }, { 96, 0x0000 }, { 96, 0x0000 }, + { 96, 0x0000 }, { 96, 0x0000 }, { 96, 0x0000 }, { 96, 0x0000 }, + { 96, 0x0000 }, { 96, 0x0000 }, { 96, 0x0000 }, { 96, 0x0000 }, + /* 0x23f00 */ + { 96, 0x0000 }, { 96, 0x0000 }, { 96, 0x0000 }, { 96, 0x0000 }, + { 96, 0x0000 }, { 96, 0x0000 }, { 96, 0x0002 }, { 97, 0x0000 }, + { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, + { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, + /* 0x24000 */ + { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, + { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, + { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x0000 }, + { 97, 0x0000 }, { 97, 0x0000 }, { 97, 0x1000 }, +}; +static const Summary16 hkscs2004_uni2indx_page242[12] = { + /* 0x24200 */ + { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x0000 }, + { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x0000 }, + { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x0000 }, { 98, 0x8000 }, +}; +static const Summary16 hkscs2004_uni2indx_page24b[1] = { + /* 0x24b00 */ + { 99, 0x8000 }, +}; +static const Summary16 hkscs2004_uni2indx_page254[10] = { + /* 0x25400 */ + { 100, 0x0000 }, { 100, 0x0000 }, { 100, 0x0000 }, { 100, 0x0000 }, + { 100, 0x0000 }, { 100, 0x0000 }, { 100, 0x0000 }, { 100, 0x0000 }, + { 100, 0x0000 }, { 100, 0x0400 }, +}; +static const Summary16 hkscs2004_uni2indx_page25a[6] = { + /* 0x25a00 */ + { 101, 0x0000 }, { 101, 0x0000 }, { 101, 0x0000 }, { 101, 0x0000 }, + { 101, 0x0000 }, { 101, 0x0010 }, +}; +static const Summary16 hkscs2004_uni2indx_page26b[21] = { + /* 0x26b00 */ + { 102, 0x0000 }, { 102, 0x0000 }, { 102, 0x0008 }, { 103, 0x0000 }, + { 103, 0x0000 }, { 103, 0x0000 }, { 103, 0x0000 }, { 103, 0x0000 }, + { 103, 0x0000 }, { 103, 0x0000 }, { 103, 0x0000 }, { 103, 0x0000 }, + { 103, 0x0000 }, { 103, 0x0000 }, { 103, 0x0000 }, { 103, 0x0000 }, + /* 0x26c00 */ + { 103, 0x0000 }, { 103, 0x0000 }, { 103, 0x0000 }, { 103, 0x0000 }, + { 103, 0x0042 }, +}; +static const Summary16 hkscs2004_uni2indx_page26e[9] = { + /* 0x26e00 */ + { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x0000 }, + { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x0000 }, + { 105, 0x0800 }, +}; +static const Summary16 hkscs2004_uni2indx_page270[14] = { + /* 0x27000 */ + { 106, 0x0000 }, { 106, 0x0000 }, { 106, 0x0000 }, { 106, 0x0000 }, + { 106, 0x0000 }, { 106, 0x0000 }, { 106, 0x0000 }, { 106, 0x0000 }, + { 106, 0x0000 }, { 106, 0x0000 }, { 106, 0x0000 }, { 106, 0x0000 }, + { 106, 0x0000 }, { 106, 0x0004 }, +}; +static const Summary16 hkscs2004_uni2indx_page272[32] = { + /* 0x27200 */ + { 107, 0x0000 }, { 107, 0x0000 }, { 107, 0x0000 }, { 107, 0x0000 }, + { 107, 0x0000 }, { 107, 0x0000 }, { 107, 0x0080 }, { 108, 0x0000 }, + { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0000 }, + { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0000 }, + /* 0x27300 */ + { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0000 }, { 108, 0x0000 }, + { 108, 0x0000 }, { 108, 0x0004 }, { 109, 0x0000 }, { 109, 0x0000 }, + { 109, 0x0000 }, { 109, 0x0000 }, { 109, 0x0000 }, { 109, 0x0000 }, + { 109, 0x0000 }, { 109, 0x0000 }, { 109, 0x0000 }, { 109, 0x8000 }, +}; +static const Summary16 hkscs2004_uni2indx_page27b[29] = { + /* 0x27b00 */ + { 110, 0x0000 }, { 110, 0x0000 }, { 110, 0x0000 }, { 110, 0x0000 }, + { 110, 0x0000 }, { 110, 0x0000 }, { 110, 0x0000 }, { 110, 0x0000 }, + { 110, 0x0000 }, { 110, 0x0000 }, { 110, 0x0000 }, { 110, 0x0000 }, + { 110, 0x0000 }, { 110, 0x0000 }, { 110, 0x8000 }, { 111, 0x0000 }, + /* 0x27c00 */ + { 111, 0x0000 }, { 111, 0x0000 }, { 111, 0x0000 }, { 111, 0x0000 }, + { 111, 0x0000 }, { 111, 0x0000 }, { 111, 0x1000 }, { 112, 0x0000 }, + { 112, 0x0000 }, { 112, 0x0000 }, { 112, 0x0000 }, { 112, 0x0002 }, + { 113, 0x0020 }, +}; +static const Summary16 hkscs2004_uni2indx_page286[12] = { + /* 0x28600 */ + { 114, 0x0000 }, { 114, 0x0000 }, { 114, 0x0000 }, { 114, 0x0000 }, + { 114, 0x0000 }, { 114, 0x0000 }, { 114, 0x0000 }, { 114, 0x0000 }, + { 114, 0x0000 }, { 114, 0x0000 }, { 114, 0x0000 }, { 114, 0x0004 }, +}; +static const Summary16 hkscs2004_uni2indx_page289[7] = { + /* 0x28900 */ + { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x0000 }, + { 115, 0x0000 }, { 115, 0x0000 }, { 115, 0x2000 }, +}; +static const Summary16 hkscs2004_uni2indx_page28b[12] = { + /* 0x28b00 */ + { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0000 }, + { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0000 }, + { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0200 }, +}; +static const Summary16 hkscs2004_uni2indx_page290[8] = { + /* 0x29000 */ + { 117, 0x0000 }, { 117, 0x0000 }, { 117, 0x0000 }, { 117, 0x0000 }, + { 117, 0x0000 }, { 117, 0x0000 }, { 117, 0x0000 }, { 117, 0x0200 }, +}; +static const Summary16 hkscs2004_uni2indx_page298[21] = { + /* 0x29800 */ + { 118, 0x0000 }, { 118, 0x0000 }, { 118, 0x0000 }, { 118, 0x0000 }, + { 118, 0x0000 }, { 118, 0x0000 }, { 118, 0x0000 }, { 118, 0x0000 }, + { 118, 0x0000 }, { 118, 0x0000 }, { 118, 0x0000 }, { 118, 0x0000 }, + { 118, 0x0000 }, { 118, 0x0000 }, { 118, 0x0000 }, { 118, 0x0400 }, + /* 0x29900 */ + { 119, 0x0000 }, { 119, 0x0000 }, { 119, 0x0000 }, { 119, 0x0000 }, + { 119, 0x0020 }, +}; +static const Summary16 hkscs2004_uni2indx_page29e[12] = { + /* 0x29e00 */ + { 120, 0x0000 }, { 120, 0x0000 }, { 120, 0x0000 }, { 120, 0x0000 }, + { 120, 0x0000 }, { 120, 0x0000 }, { 120, 0x0000 }, { 120, 0x0000 }, + { 120, 0x0000 }, { 120, 0x0000 }, { 120, 0x0000 }, { 120, 0x0001 }, +}; +static const Summary16 hkscs2004_uni2indx_page2a1[12] = { + /* 0x2a100 */ + { 121, 0x0000 }, { 121, 0x0000 }, { 121, 0x0000 }, { 121, 0x0000 }, + { 121, 0x0000 }, { 121, 0x0000 }, { 121, 0x0000 }, { 121, 0x0000 }, + { 121, 0x0000 }, { 121, 0x0000 }, { 121, 0x0000 }, { 121, 0x0020 }, +}; +static const Summary16 hkscs2004_uni2indx_page2a3[6] = { + /* 0x2a300 */ + { 122, 0x0000 }, { 122, 0x0000 }, { 122, 0x0000 }, { 122, 0x0000 }, + { 122, 0x0000 }, { 122, 0x0002 }, +}; + +static int +hkscs2004_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc < 0x21a00) { + if (wc < 0x6e00) { + if (wc >= 0x3400 && wc < 0x3450) + summary = &hkscs2004_uni2indx_page34[(wc>>4)-0x340]; + else if (wc >= 0x3600 && wc < 0x3980) + summary = &hkscs2004_uni2indx_page36[(wc>>4)-0x360]; + else if (wc >= 0x3b00 && wc < 0x3ba0) + summary = &hkscs2004_uni2indx_page3b[(wc>>4)-0x3b0]; + else if (wc >= 0x3d00 && wc < 0x3e00) + summary = &hkscs2004_uni2indx_page3d[(wc>>4)-0x3d0]; + else if (wc >= 0x3f00 && wc < 0x41f0) + summary = &hkscs2004_uni2indx_page3f[(wc>>4)-0x3f0]; + else if (wc >= 0x4300 && wc < 0x4750) + summary = &hkscs2004_uni2indx_page43[(wc>>4)-0x430]; + else if (wc >= 0x4a00 && wc < 0x4ab0) + summary = &hkscs2004_uni2indx_page4a[(wc>>4)-0x4a0]; + else if (wc >= 0x4c00 && wc < 0x4d90) + summary = &hkscs2004_uni2indx_page4c[(wc>>4)-0x4c0]; + else if (wc >= 0x4f00 && wc < 0x4fc0) + summary = &hkscs2004_uni2indx_page4f[(wc>>4)-0x4f0]; + else if (wc >= 0x5600 && wc < 0x5700) + summary = &hkscs2004_uni2indx_page56[(wc>>4)-0x560]; + else if (wc >= 0x5900 && wc < 0x5d80) + summary = &hkscs2004_uni2indx_page59[(wc>>4)-0x590]; + else if (wc >= 0x5f00 && wc < 0x5f40) + summary = &hkscs2004_uni2indx_page5f[(wc>>4)-0x5f0]; + else if (wc >= 0x6600 && wc < 0x6770) + summary = &hkscs2004_uni2indx_page66[(wc>>4)-0x660]; + } else { + if (wc >= 0x6e00 && wc < 0x6e60) + summary = &hkscs2004_uni2indx_page6e[(wc>>4)-0x6e0]; + else if (wc >= 0x7100 && wc < 0x7230) + summary = &hkscs2004_uni2indx_page71[(wc>>4)-0x710]; + else if (wc >= 0x7400 && wc < 0x74a0) + summary = &hkscs2004_uni2indx_page74[(wc>>4)-0x740]; + else if (wc >= 0x7900 && wc < 0x79d0) + summary = &hkscs2004_uni2indx_page79[(wc>>4)-0x790]; + else if (wc >= 0x7d00 && wc < 0x7da0) + summary = &hkscs2004_uni2indx_page7d[(wc>>4)-0x7d0]; + else if (wc >= 0x8100 && wc < 0x8170) + summary = &hkscs2004_uni2indx_page81[(wc>>4)-0x810]; + else if (wc >= 0x8500 && wc < 0x85a0) + summary = &hkscs2004_uni2indx_page85[(wc>>4)-0x850]; + else if (wc >= 0x8a00 && wc < 0x8b00) + summary = &hkscs2004_uni2indx_page8a[(wc>>4)-0x8a0]; + else if (wc >= 0x9700 && wc < 0x9860) + summary = &hkscs2004_uni2indx_page97[(wc>>4)-0x970]; + else if (wc >= 0x9f00 && wc < 0x9fc0) + summary = &hkscs2004_uni2indx_page9f[(wc>>4)-0x9f0]; + else if (wc >= 0x20100 && wc < 0x20240) + summary = &hkscs2004_uni2indx_page201[(wc>>4)-0x2010]; + else if (wc >= 0x20a00 && wc < 0x20ba0) + summary = &hkscs2004_uni2indx_page20a[(wc>>4)-0x20a0]; + } + } else { + if (wc < 0x26b00) { + if (wc >= 0x21a00 && wc < 0x21a70) + summary = &hkscs2004_uni2indx_page21a[(wc>>4)-0x21a0]; + else if (wc >= 0x21d00 && wc < 0x21e30) + summary = &hkscs2004_uni2indx_page21d[(wc>>4)-0x21d0]; + else if (wc >= 0x22100 && wc < 0x221d0) + summary = &hkscs2004_uni2indx_page221[(wc>>4)-0x2210]; + else if (wc >= 0x22700 && wc < 0x227a0) + summary = &hkscs2004_uni2indx_page227[(wc>>4)-0x2270]; + else if (wc >= 0x23200 && wc < 0x23260) + summary = &hkscs2004_uni2indx_page232[(wc>>4)-0x2320]; + else if (wc >= 0x23500 && wc < 0x23620) + summary = &hkscs2004_uni2indx_page235[(wc>>4)-0x2350]; + else if (wc >= 0x23b00 && wc < 0x23b20) + summary = &hkscs2004_uni2indx_page23b[(wc>>4)-0x23b0]; + else if (wc >= 0x23e00 && wc < 0x240f0) + summary = &hkscs2004_uni2indx_page23e[(wc>>4)-0x23e0]; + else if (wc >= 0x24200 && wc < 0x242c0) + summary = &hkscs2004_uni2indx_page242[(wc>>4)-0x2420]; + else if (wc >= 0x24b00 && wc < 0x24b10) + summary = &hkscs2004_uni2indx_page24b[(wc>>4)-0x24b0]; + else if (wc >= 0x25400 && wc < 0x254a0) + summary = &hkscs2004_uni2indx_page254[(wc>>4)-0x2540]; + else if (wc >= 0x25a00 && wc < 0x25a60) + summary = &hkscs2004_uni2indx_page25a[(wc>>4)-0x25a0]; + } else { + if (wc >= 0x26b00 && wc < 0x26c50) + summary = &hkscs2004_uni2indx_page26b[(wc>>4)-0x26b0]; + else if (wc >= 0x26e00 && wc < 0x26e90) + summary = &hkscs2004_uni2indx_page26e[(wc>>4)-0x26e0]; + else if (wc >= 0x27000 && wc < 0x270e0) + summary = &hkscs2004_uni2indx_page270[(wc>>4)-0x2700]; + else if (wc >= 0x27200 && wc < 0x27400) + summary = &hkscs2004_uni2indx_page272[(wc>>4)-0x2720]; + else if (wc >= 0x27b00 && wc < 0x27cd0) + summary = &hkscs2004_uni2indx_page27b[(wc>>4)-0x27b0]; + else if (wc >= 0x28600 && wc < 0x286c0) + summary = &hkscs2004_uni2indx_page286[(wc>>4)-0x2860]; + else if (wc >= 0x28900 && wc < 0x28970) + summary = &hkscs2004_uni2indx_page289[(wc>>4)-0x2890]; + else if (wc >= 0x28b00 && wc < 0x28bc0) + summary = &hkscs2004_uni2indx_page28b[(wc>>4)-0x28b0]; + else if (wc >= 0x29000 && wc < 0x29080) + summary = &hkscs2004_uni2indx_page290[(wc>>4)-0x2900]; + else if (wc >= 0x29800 && wc < 0x29950) + summary = &hkscs2004_uni2indx_page298[(wc>>4)-0x2980]; + else if (wc >= 0x29e00 && wc < 0x29ec0) + summary = &hkscs2004_uni2indx_page29e[(wc>>4)-0x29e0]; + else if (wc >= 0x2a100 && wc < 0x2a1c0) + summary = &hkscs2004_uni2indx_page2a1[(wc>>4)-0x2a10]; + else if (wc >= 0x2a300 && wc < 0x2a360) + summary = &hkscs2004_uni2indx_page2a3[(wc>>4)-0x2a30]; + } + } + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = hkscs2004_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/hp_roman8.h b/graf2d/win32gdk/gdk/src/iconv/hp_roman8.h new file mode 100644 index 0000000000000..da776ed087138 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/hp_roman8.h @@ -0,0 +1,119 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * HP-ROMAN8 + */ + +static const unsigned short hp_roman8_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x00c0, 0x00c2, 0x00c8, 0x00ca, 0x00cb, 0x00ce, 0x00cf, + 0x00b4, 0x02cb, 0x02c6, 0x00a8, 0x02dc, 0x00d9, 0x00db, 0x20a4, + /* 0xb0 */ + 0x00af, 0x00dd, 0x00fd, 0x00b0, 0x00c7, 0x00e7, 0x00d1, 0x00f1, + 0x00a1, 0x00bf, 0x00a4, 0x00a3, 0x00a5, 0x00a7, 0x0192, 0x00a2, + /* 0xc0 */ + 0x00e2, 0x00ea, 0x00f4, 0x00fb, 0x00e1, 0x00e9, 0x00f3, 0x00fa, + 0x00e0, 0x00e8, 0x00f2, 0x00f9, 0x00e4, 0x00eb, 0x00f6, 0x00fc, + /* 0xd0 */ + 0x00c5, 0x00ee, 0x00d8, 0x00c6, 0x00e5, 0x00ed, 0x00f8, 0x00e6, + 0x00c4, 0x00ec, 0x00d6, 0x00dc, 0x00c9, 0x00ef, 0x00df, 0x00d4, + /* 0xe0 */ + 0x00c1, 0x00c3, 0x00e3, 0x00d0, 0x00f0, 0x00cd, 0x00cc, 0x00d3, + 0x00d2, 0x00d5, 0x00f5, 0x0160, 0x0161, 0x00da, 0x0178, 0x00ff, + /* 0xf0 */ + 0x00de, 0x00fe, 0x00b7, 0x00b5, 0x00b6, 0x00be, 0x2014, 0x00bc, + 0x00bd, 0x00aa, 0x00ba, 0x00ab, 0x25a0, 0x00bb, 0x00b1, 0xfffd, +}; + +static int +hp_roman8_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = hp_roman8_2uni[c-0xa0]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char hp_roman8_page00[96] = { + 0xa0, 0xb8, 0xbf, 0xbb, 0xba, 0xbc, 0x00, 0xbd, /* 0xa0-0xa7 */ + 0xab, 0x00, 0xf9, 0xfb, 0x00, 0x00, 0x00, 0xb0, /* 0xa8-0xaf */ + 0xb3, 0xfe, 0x00, 0x00, 0xa8, 0xf3, 0xf4, 0xf2, /* 0xb0-0xb7 */ + 0x00, 0x00, 0xfa, 0xfd, 0xf7, 0xf8, 0xf5, 0xb9, /* 0xb8-0xbf */ + 0xa1, 0xe0, 0xa2, 0xe1, 0xd8, 0xd0, 0xd3, 0xb4, /* 0xc0-0xc7 */ + 0xa3, 0xdc, 0xa4, 0xa5, 0xe6, 0xe5, 0xa6, 0xa7, /* 0xc8-0xcf */ + 0xe3, 0xb6, 0xe8, 0xe7, 0xdf, 0xe9, 0xda, 0x00, /* 0xd0-0xd7 */ + 0xd2, 0xad, 0xed, 0xae, 0xdb, 0xb1, 0xf0, 0xde, /* 0xd8-0xdf */ + 0xc8, 0xc4, 0xc0, 0xe2, 0xcc, 0xd4, 0xd7, 0xb5, /* 0xe0-0xe7 */ + 0xc9, 0xc5, 0xc1, 0xcd, 0xd9, 0xd5, 0xd1, 0xdd, /* 0xe8-0xef */ + 0xe4, 0xb7, 0xca, 0xc6, 0xc2, 0xea, 0xce, 0x00, /* 0xf0-0xf7 */ + 0xd6, 0xcb, 0xc7, 0xc3, 0xcf, 0xb2, 0xf1, 0xef, /* 0xf8-0xff */ +}; +static const unsigned char hp_roman8_page01[56] = { + 0xeb, 0xec, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0xee, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0xbe, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char hp_roman8_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xaa, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0xa9, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0xac, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ +}; + +static int +hp_roman8_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = hp_roman8_page00[wc-0x00a0]; + else if (wc >= 0x0160 && wc < 0x0198) + c = hp_roman8_page01[wc-0x0160]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = hp_roman8_page02[wc-0x02c0]; + else if (wc == 0x2014) + c = 0xf6; + else if (wc == 0x20a4) + c = 0xaf; + else if (wc == 0x25a0) + c = 0xfc; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/hz.h b/graf2d/win32gdk/gdk/src/iconv/hz.h new file mode 100644 index 0000000000000..db0b4b11dc7ce --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/hz.h @@ -0,0 +1,163 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * HZ + */ + +/* Specification: RFC 1842, RFC 1843 */ + +/* + * The state is 1 in GB mode, 0 in ASCII mode. + */ + +static int +hz_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + state_t state = conv->istate; + unsigned int count = 0; + unsigned char c; + for (;;) { + c = *s; + if (c == '~') { + if (n < count+2) + goto none; + c = s[1]; + if (state == 0) { + if (c == '~') { + *pwc = (ucs4_t) '~'; + conv->istate = state; + return count+2; + } + if (c == '{') { + state = 1; + s += 2; count += 2; + if (n < count+1) + goto none; + continue; + } + if (c == '\n') { + s += 2; count += 2; + if (n < count+1) + goto none; + continue; + } + } else { + if (c == '}') { + state = 0; + s += 2; count += 2; + if (n < count+1) + goto none; + continue; + } + } + goto ilseq; + } + break; + } + if (state == 0) { + *pwc = (ucs4_t) c; + conv->istate = state; + return count+1; + } else { + int ret; + if (n < count+2) + goto none; + ret = gb2312_mbtowc(conv,pwc,s,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + conv->istate = state; + return count+2; + } + +none: + conv->istate = state; + return RET_TOOFEW(count); + +ilseq: + conv->istate = state; + return RET_SHIFT_ILSEQ(count); +} + +static int +hz_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + state_t state = conv->ostate; + unsigned char buf[2]; + int ret; + + /* Code set 0 (ASCII or GB 1988-89) */ + ret = ascii_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] < 0x80) { + int count = (state ? 3 : 1); + if (n < count) + return RET_TOOSMALL; + if (state) { + r[0] = '~'; + r[1] = '}'; + r += 2; + state = 0; + } + r[0] = buf[0]; + conv->ostate = state; + return count; + } + } + + /* Code set 1 (GB 2312-1980) */ + ret = gb2312_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + int count = (state ? 2 : 4); + if (n < count) + return RET_TOOSMALL; + if (!state) { + r[0] = '~'; + r[1] = '{'; + r += 2; + state = 1; + } + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = state; + return count; + } + } + + return RET_ILUNI; +} + +static int +hz_reset (conv_t conv, unsigned char *r, int n) +{ + state_t state = conv->ostate; + if (state) { + if (n < 2) + return RET_TOOSMALL; + r[0] = '~'; + r[1] = '}'; + /* conv->ostate = 0; will be done by the caller */ + return 2; + } else + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iconv.c b/graf2d/win32gdk/gdk/src/iconv/iconv.c new file mode 100644 index 0000000000000..a7f7aef748055 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iconv.c @@ -0,0 +1,592 @@ +/* + * Copyright (C) 1999-2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +#include <iconv.h> + +#include <stdlib.h> +#include <string.h> +#include "config.h" +#include "localcharset.h" + +#if ENABLE_EXTRA +/* + * Consider all system dependent encodings, for any system, + * and the extra encodings. + */ +#define USE_AIX +#define USE_OSF1 +#define USE_DOS +#define USE_EXTRA +#else +/* + * Consider those system dependent encodings that are needed for the + * current system. + */ +#ifdef _AIX +#define USE_AIX +#endif +#if defined(__osf__) || defined(VMS) +#define USE_OSF1 +#endif +#if defined(__DJGPP__) || (defined(_WIN32) && (defined(_MSC_VER) || defined(__MINGW32__))) +#define USE_DOS +#endif +#endif + +/* + * Data type for general conversion loop. + */ +struct loop_funcs { + size_t (*loop_convert) (iconv_t icd, + const char* * inbuf, size_t *inbytesleft, + char* * outbuf, size_t *outbytesleft); + size_t (*loop_reset) (iconv_t icd, + char* * outbuf, size_t *outbytesleft); +}; + +/* + * Converters. + */ +#include "converters.h" + +/* + * Transliteration tables. + */ +#include "cjk_variants.h" +#include "translit.h" + +/* + * Table of all supported encodings. + */ +struct encoding { + struct mbtowc_funcs ifuncs; /* conversion multibyte -> unicode */ + struct wctomb_funcs ofuncs; /* conversion unicode -> multibyte */ + int oflags; /* flags for unicode -> multibyte conversion */ +}; +#define DEFALIAS(xxx_alias,xxx) /* nothing */ +enum { +#define DEFENCODING(xxx_names,xxx,xxx_ifuncs1,xxx_ifuncs2,xxx_ofuncs1,xxx_ofuncs2) \ + ei_##xxx , +#include "encodings.def" +#ifdef USE_AIX +# include "encodings_aix.def" +#endif +#ifdef USE_OSF1 +# include "encodings_osf1.def" +#endif +#ifdef USE_DOS +# include "encodings_dos.def" +#endif +#ifdef USE_EXTRA +# include "encodings_extra.def" +#endif +#include "encodings_local.def" +#undef DEFENCODING +ei_for_broken_compilers_that_dont_like_trailing_commas +}; +#include "flags.h" +static struct encoding const all_encodings[] = { +#define DEFENCODING(xxx_names,xxx,xxx_ifuncs1,xxx_ifuncs2,xxx_ofuncs1,xxx_ofuncs2) \ + { xxx_ifuncs1,xxx_ifuncs2, xxx_ofuncs1,xxx_ofuncs2, ei_##xxx##_oflags }, +#include "encodings.def" +#ifdef USE_AIX +# include "encodings_aix.def" +#endif +#ifdef USE_OSF1 +# include "encodings_osf1.def" +#endif +#ifdef USE_DOS +# include "encodings_dos.def" +#endif +#ifdef USE_EXTRA +# include "encodings_extra.def" +#endif +#undef DEFENCODING +#define DEFENCODING(xxx_names,xxx,xxx_ifuncs1,xxx_ifuncs2,xxx_ofuncs1,xxx_ofuncs2) \ + { xxx_ifuncs1,xxx_ifuncs2, xxx_ofuncs1,xxx_ofuncs2, 0 }, +#include "encodings_local.def" +#undef DEFENCODING +}; +#undef DEFALIAS + +/* + * Conversion loops. + */ +#include "loops.h" + +/* + * Alias lookup function. + * Defines + * struct alias { int name; unsigned int encoding_index; }; + * const struct alias * aliases_lookup (const char *str, unsigned int len); + * #define MAX_WORD_LENGTH ... + */ +#if defined _AIX +# include "aliases_sysaix.h" +#elif defined hpux || defined __hpux +# include "aliases_syshpux.h" +#elif defined __osf__ +# include "aliases_sysosf1.h" +#elif defined __sun +# include "aliases_syssolaris.h" +#else +# include "aliases.h" +#endif + +/* + * System dependent alias lookup function. + * Defines + * const struct alias * aliases2_lookup (const char *str); + */ +#if defined(USE_AIX) || defined(USE_OSF1) || defined(USE_DOS) || defined(USE_EXTRA) /* || ... */ +struct stringpool2_t { +#define S(tag,name,encoding_index) char stringpool_##tag[sizeof(name)]; +#include "aliases2.h" +#undef S +}; +static const struct stringpool2_t stringpool2_contents = { +#define S(tag,name,encoding_index) name, +#include "aliases2.h" +#undef S +}; +#define stringpool2 ((const char *) &stringpool2_contents) +static const struct alias sysdep_aliases[] = { +#define S(tag,name,encoding_index) { (int)(long)&((struct stringpool2_t *)0)->stringpool_##tag, encoding_index }, +#include "aliases2.h" +#undef S +}; +#ifdef __GNUC__ +__inline +#endif +const struct alias * +aliases2_lookup (register const char *str) +{ + const struct alias * ptr; + unsigned int count; + for (ptr = sysdep_aliases, count = sizeof(sysdep_aliases)/sizeof(sysdep_aliases[0]); count > 0; ptr++, count--) + if (!strcmp(str, stringpool2 + ptr->name)) + return ptr; + return NULL; +} +#else +#define aliases2_lookup(str) NULL +#define stringpool2 NULL +#endif + +#if 0 +/* Like !strcasecmp, except that the both strings can be assumed to be ASCII + and the first string can be assumed to be in uppercase. */ +static int strequal (const char* str1, const char* str2) +{ + unsigned char c1; + unsigned char c2; + for (;;) { + c1 = * (unsigned char *) str1++; + c2 = * (unsigned char *) str2++; + if (c1 == 0) + break; + if (c2 >= 'a' && c2 <= 'z') + c2 -= 'a'-'A'; + if (c1 != c2) + break; + } + return (c1 == c2); +} +#endif + +iconv_t iconv_open (const char* tocode, const char* fromcode) +{ + struct conv_struct * cd; + unsigned int from_index; + int from_wchar; + unsigned int to_index; + int to_wchar; + int transliterate; + int discard_ilseq; + +#include "iconv_open1.h" + + cd = (struct conv_struct *) malloc(from_wchar != to_wchar + ? sizeof(struct wchar_conv_struct) + : sizeof(struct conv_struct)); + if (cd == NULL) { + errno = ENOMEM; + return (iconv_t)(-1); + } + +#include "iconv_open2.h" + + return (iconv_t)cd; +invalid: + errno = EINVAL; + return (iconv_t)(-1); +} + +size_t iconv (iconv_t icd, + const char* * inbuf, size_t *inbytesleft, + char* * outbuf, size_t *outbytesleft) +{ + conv_t cd = (conv_t) icd; + if (inbuf == NULL || *inbuf == NULL) + return cd->lfuncs.loop_reset(icd,outbuf,outbytesleft); + else + return cd->lfuncs.loop_convert(icd, + (const char* *)inbuf,inbytesleft, + outbuf,outbytesleft); +} + +int iconv_close (iconv_t icd) +{ + conv_t cd = (conv_t) icd; + free(cd); + return 0; +} + +#ifndef LIBICONV_PLUG + +/* + * Verify that a 'struct conv_struct' and a 'struct wchar_conv_struct' each + * fit in an iconv_allocation_t. + * If this verification fails, iconv_allocation_t must be made larger and + * the major version in LIBICONV_VERSION_INFO must be bumped. + * Currently 'struct conv_struct' has 21 integer/pointer fields, and + * 'struct wchar_conv_struct' additionally has an 'mbstate_t' field. + */ +typedef int verify_size_1[2 * (sizeof (struct conv_struct) <= sizeof (iconv_allocation_t)) - 1]; +typedef int verify_size_2[2 * (sizeof (struct wchar_conv_struct) <= sizeof (iconv_allocation_t)) - 1]; + +int iconv_open_into (const char* tocode, const char* fromcode, + iconv_allocation_t* resultp) +{ + struct conv_struct * cd; + unsigned int from_index; + int from_wchar; + unsigned int to_index; + int to_wchar; + int transliterate; + int discard_ilseq; + +#include "iconv_open1.h" + + cd = (struct conv_struct *) resultp; + +#include "iconv_open2.h" + + return 0; +invalid: + errno = EINVAL; + return -1; +} + +int iconvctl (iconv_t icd, int request, void* argument) +{ + conv_t cd = (conv_t) icd; + switch (request) { + case ICONV_TRIVIALP: + *(int *)argument = + ((cd->lfuncs.loop_convert == unicode_loop_convert + && cd->iindex == cd->oindex) + || cd->lfuncs.loop_convert == wchar_id_loop_convert + ? 1 : 0); + return 0; + case ICONV_GET_TRANSLITERATE: + *(int *)argument = cd->transliterate; + return 0; + case ICONV_SET_TRANSLITERATE: + cd->transliterate = (*(const int *)argument ? 1 : 0); + return 0; + case ICONV_GET_DISCARD_ILSEQ: + *(int *)argument = cd->discard_ilseq; + return 0; + case ICONV_SET_DISCARD_ILSEQ: + cd->discard_ilseq = (*(const int *)argument ? 1 : 0); + return 0; + case ICONV_SET_HOOKS: + if (argument != NULL) { + cd->hooks = *(const struct iconv_hooks *)argument; + } else { + cd->hooks.uc_hook = NULL; + cd->hooks.wc_hook = NULL; + cd->hooks.data = NULL; + } + return 0; + case ICONV_SET_FALLBACKS: + if (argument != NULL) { + cd->fallbacks = *(const struct iconv_fallbacks *)argument; + } else { + cd->fallbacks.mb_to_uc_fallback = NULL; + cd->fallbacks.uc_to_mb_fallback = NULL; + cd->fallbacks.mb_to_wc_fallback = NULL; + cd->fallbacks.wc_to_mb_fallback = NULL; + cd->fallbacks.data = NULL; + } + return 0; + default: + errno = EINVAL; + return -1; + } +} + +/* An alias after its name has been converted from 'int' to 'const char*'. */ +struct nalias { const char* name; unsigned int encoding_index; }; + +static int compare_by_index (const void * arg1, const void * arg2) +{ + const struct nalias * alias1 = (const struct nalias *) arg1; + const struct nalias * alias2 = (const struct nalias *) arg2; + return (int)alias1->encoding_index - (int)alias2->encoding_index; +} + +static int compare_by_name (const void * arg1, const void * arg2) +{ + const char * name1 = *(const char **)arg1; + const char * name2 = *(const char **)arg2; + /* Compare alphabetically, but put "CS" names at the end. */ + int sign = strcmp(name1,name2); + if (sign != 0) { + sign = ((name1[0]=='C' && name1[1]=='S') - (name2[0]=='C' && name2[1]=='S')) + * 4 + (sign >= 0 ? 1 : -1); + } + return sign; +} + +void iconvlist (int (*do_one) (unsigned int namescount, + const char * const * names, + void* data), + void* data) +{ +#define aliascount1 sizeof(aliases)/sizeof(aliases[0]) +#ifndef aliases2_lookup +#define aliascount2 sizeof(sysdep_aliases)/sizeof(sysdep_aliases[0]) +#else +#define aliascount2 0 +#endif +#define aliascount (aliascount1+aliascount2) + struct nalias aliasbuf[aliascount]; + const char * namesbuf[aliascount]; + size_t num_aliases; + { + /* Put all existing aliases into a buffer. */ + size_t i; + size_t j; + j = 0; + for (i = 0; i < aliascount1; i++) { + const struct alias * p = &aliases[i]; + if (p->name >= 0 + && p->encoding_index != ei_local_char + && p->encoding_index != ei_local_wchar_t) { + aliasbuf[j].name = stringpool + p->name; + aliasbuf[j].encoding_index = p->encoding_index; + j++; + } + } +#ifndef aliases2_lookup + for (i = 0; i < aliascount2; i++) { + aliasbuf[j].name = stringpool2 + sysdep_aliases[i].name; + aliasbuf[j].encoding_index = sysdep_aliases[i].encoding_index; + j++; + } +#endif + num_aliases = j; + } + /* Sort by encoding_index. */ + if (num_aliases > 1) + qsort(aliasbuf, num_aliases, sizeof(struct nalias), compare_by_index); + { + /* Process all aliases with the same encoding_index together. */ + size_t j; + j = 0; + while (j < num_aliases) { + unsigned int ei = aliasbuf[j].encoding_index; + size_t i = 0; + do + namesbuf[i++] = aliasbuf[j++].name; + while (j < num_aliases && aliasbuf[j].encoding_index == ei); + if (i > 1) + qsort((void *) namesbuf, i, sizeof(const char *), compare_by_name); + /* Call the callback. */ + if (do_one(i,namesbuf,data)) + break; + } + } +#undef aliascount +#undef aliascount2 +#undef aliascount1 +} + +/* + * Table of canonical names of encodings. + * Instead of strings, it contains offsets into stringpool and stringpool2. + */ +static const unsigned short all_canonical[] = { +#if defined _AIX +# include "canonical_sysaix.h" +#elif defined hpux || defined __hpux +# include "canonical_syshpux.h" +#elif defined __osf__ +# include "canonical_sysosf1.h" +#elif defined __sun +# include "canonical_syssolaris.h" +#else +# include "canonical.h" +#endif +#ifdef USE_AIX +# if defined _AIX +# include "canonical_aix_sysaix.h" +# else +# include "canonical_aix.h" +# endif +#endif +#ifdef USE_OSF1 +# if defined __osf__ +# include "canonical_osf1_sysosf1.h" +# else +# include "canonical_osf1.h" +# endif +#endif +#ifdef USE_DOS +# include "canonical_dos.h" +#endif +#ifdef USE_EXTRA +# include "canonical_extra.h" +#endif +#if defined _AIX +# include "canonical_local_sysaix.h" +#elif defined hpux || defined __hpux +# include "canonical_local_syshpux.h" +#elif defined __osf__ +# include "canonical_local_sysosf1.h" +#elif defined __sun +# include "canonical_local_syssolaris.h" +#else +# include "canonical_local.h" +#endif +}; + +const char * iconv_canonicalize (const char * name) +{ + const char* code; + char buf[MAX_WORD_LENGTH+10+1]; + const char* cp; + char* bp; + const struct alias * ap; + unsigned int count; + unsigned int index; + const char* pool; + + /* Before calling aliases_lookup, convert the input string to upper case, + * and check whether it's entirely ASCII (we call gperf with option "-7" + * to achieve a smaller table) and non-empty. If it's not entirely ASCII, + * or if it's too long, it is not a valid encoding name. + */ + for (code = name;;) { + /* Search code in the table. */ + for (cp = code, bp = buf, count = MAX_WORD_LENGTH+10+1; ; cp++, bp++) { + unsigned char c = * (unsigned char *) cp; + if (c >= 0x80) + goto invalid; + if (c >= 'a' && c <= 'z') + c -= 'a'-'A'; + *bp = c; + if (c == '\0') + break; + if (--count == 0) + goto invalid; + } + for (;;) { + if (bp-buf >= 10 && memcmp(bp-10,"//TRANSLIT",10)==0) { + bp -= 10; + *bp = '\0'; + continue; + } + if (bp-buf >= 8 && memcmp(bp-8,"//IGNORE",8)==0) { + bp -= 8; + *bp = '\0'; + continue; + } + break; + } + if (buf[0] == '\0') { + code = locale_charset(); + /* Avoid an endless loop that could occur when using an older version + of localcharset.c. */ + if (code[0] == '\0') + goto invalid; + continue; + } + pool = stringpool; + ap = aliases_lookup(buf,bp-buf); + if (ap == NULL) { + pool = stringpool2; + ap = aliases2_lookup(buf); + if (ap == NULL) + goto invalid; + } + if (ap->encoding_index == ei_local_char) { + code = locale_charset(); + /* Avoid an endless loop that could occur when using an older version + of localcharset.c. */ + if (code[0] == '\0') + goto invalid; + continue; + } + if (ap->encoding_index == ei_local_wchar_t) { + /* On systems which define __STDC_ISO_10646__, wchar_t is Unicode. + This is also the case on native Woe32 systems. */ +#if __STDC_ISO_10646__ || ((defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__) + if (sizeof(wchar_t) == 4) { + index = ei_ucs4internal; + break; + } + if (sizeof(wchar_t) == 2) { + index = ei_ucs2internal; + break; + } + if (sizeof(wchar_t) == 1) { + index = ei_iso8859_1; + break; + } +#endif + } + index = ap->encoding_index; + break; + } + return all_canonical[index] + pool; + invalid: + return name; +} + +int _libiconv_version = _LIBICONV_VERSION; + +#if defined __FreeBSD__ && !defined __gnu_freebsd__ +/* GNU libiconv is the native FreeBSD iconv implementation since 2002. + It wants to define the symbols 'iconv_open', 'iconv', 'iconv_close'. */ +#define strong_alias(name, aliasname) _strong_alias(name, aliasname) +#define _strong_alias(name, aliasname) \ + extern __typeof (name) aliasname __attribute__ ((alias (#name))); +#undef iconv_open +#undef iconv +#undef iconv_close +strong_alias (libiconv_open, iconv_open) +strong_alias (libiconv, iconv) +strong_alias (libiconv_close, iconv_close) +#endif + +#endif diff --git a/graf2d/win32gdk/gdk/src/iconv/iconv.h b/graf2d/win32gdk/gdk/src/iconv/iconv.h new file mode 100644 index 0000000000000..ef3e3e9c1e12d --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iconv.h @@ -0,0 +1,242 @@ +/* Copyright (C) 1999-2003, 2005-2006, 2008-2009 Free Software Foundation, Inc. + This file is part of the GNU LIBICONV Library. + + The GNU LIBICONV Library is free software; you can redistribute it + and/or modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either version 2 + of the License, or (at your option) any later version. + + The GNU LIBICONV Library is distributed in the hope that it will be + useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with the GNU LIBICONV Library; see the file COPYING.LIB. + If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + Fifth Floor, Boston, MA 02110-1301, USA. */ + +/* When installed, this file is called "iconv.h". */ + +#ifndef _LIBICONV_H +#define _LIBICONV_H + +#define _LIBICONV_VERSION 0x010D /* version number: (major<<8) + minor */ + +#if BUILDING_LIBICONV +#define LIBICONV_DLL_EXPORTED __declspec(dllexport) +#elif USING_STATIC_LIBICONV +#define LIBICONV_DLL_EXPORTED +#else +#define LIBICONV_DLL_EXPORTED __declspec(dllimport) +#endif +extern LIBICONV_DLL_EXPORTED int _libiconv_version; /* Likewise */ + +/* We would like to #include any system header file which could define + iconv_t, 1. in order to eliminate the risk that the user gets compilation + errors because some other system header file includes /usr/include/iconv.h + which defines iconv_t or declares iconv after this file, 2. when compiling + for LIBICONV_PLUG, we need the proper iconv_t type in order to produce + binary compatible code. + But gcc's #include_next is not portable. Thus, once libiconv's iconv.h + has been installed in /usr/local/include, there is no way any more to + include the original /usr/include/iconv.h. We simply have to get away + without it. + Ad 1. The risk that a system header file does + #include "iconv.h" or #include_next "iconv.h" + is small. They all do #include <iconv.h>. + Ad 2. The iconv_t type is a pointer type in all cases I have seen. (It + has to be a scalar type because (iconv_t)(-1) is a possible return value + from iconv_open().) */ + +/* Define iconv_t ourselves. */ +#undef iconv_t +#define iconv_t libiconv_t +typedef void* iconv_t; + +/* Get size_t declaration. + Get wchar_t declaration if it exists. */ +#include <stddef.h> + +/* Get errno declaration and values. */ +#include <errno.h> +/* Some systems, like SunOS 4, don't have EILSEQ. Some systems, like BSD/OS, + have EILSEQ in a different header. On these systems, define EILSEQ + ourselves. */ +#ifndef EILSEQ +#define EILSEQ @EILSEQ@ +#endif + + +#ifdef __cplusplus +extern "C" { +#endif + + +/* Allocates descriptor for code conversion from encoding ‘fromcode’ to + encoding ‘tocode’. */ +#ifndef LIBICONV_PLUG +#define iconv_open libiconv_open +#endif +extern LIBICONV_DLL_EXPORTED iconv_t iconv_open (const char* tocode, const char* fromcode); + +/* Converts, using conversion descriptor ‘cd’, at most ‘*inbytesleft’ bytes + starting at ‘*inbuf’, writing at most ‘*outbytesleft’ bytes starting at + ‘*outbuf’. + Decrements ‘*inbytesleft’ and increments ‘*inbuf’ by the same amount. + Decrements ‘*outbytesleft’ and increments ‘*outbuf’ by the same amount. */ +#ifndef LIBICONV_PLUG +#define iconv libiconv +#endif +extern LIBICONV_DLL_EXPORTED size_t iconv (iconv_t cd, const char* * inbuf, size_t *inbytesleft, char* * outbuf, size_t *outbytesleft); + +/* Frees resources allocated for conversion descriptor ‘cd’. */ +#ifndef LIBICONV_PLUG +#define iconv_close libiconv_close +#endif +extern LIBICONV_DLL_EXPORTED int iconv_close (iconv_t cd); + + +#ifndef LIBICONV_PLUG + +/* Nonstandard extensions. */ + +#if USE_MBSTATE_T +#if BROKEN_WCHAR_H +/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before + <wchar.h>. + BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be + included before <wchar.h>. */ +#include <stddef.h> +#include <stdio.h> +#include <time.h> +#endif +#include <wchar.h> +#endif + +/* A type that holds all memory needed by a conversion descriptor. + A pointer to such an object can be used as an iconv_t. */ +typedef struct { + void* dummy1[28]; +#if USE_MBSTATE_T + mbstate_t dummy2; +#endif +} iconv_allocation_t; + +/* Allocates descriptor for code conversion from encoding ‘fromcode’ to + encoding ‘tocode’ into preallocated memory. Returns an error indicator + (0 or -1 with errno set). */ +#define iconv_open_into libiconv_open_into +extern LIBICONV_DLL_EXPORTED int iconv_open_into (const char* tocode, const char* fromcode, + iconv_allocation_t* resultp); + +/* Control of attributes. */ +#define iconvctl libiconvctl +extern LIBICONV_DLL_EXPORTED int iconvctl (iconv_t cd, int request, void* argument); + +/* Hook performed after every successful conversion of a Unicode character. */ +typedef void (*iconv_unicode_char_hook) (unsigned int uc, void* data); +/* Hook performed after every successful conversion of a wide character. */ +typedef void (*iconv_wide_char_hook) (wchar_t wc, void* data); +/* Set of hooks. */ +struct iconv_hooks { + iconv_unicode_char_hook uc_hook; + iconv_wide_char_hook wc_hook; + void* data; +}; + +/* Fallback function. Invoked when a small number of bytes could not be + converted to a Unicode character. This function should process all + bytes from inbuf and may produce replacement Unicode characters by calling + the write_replacement callback repeatedly. */ +typedef void (*iconv_unicode_mb_to_uc_fallback) + (const char* inbuf, size_t inbufsize, + void (*write_replacement) (const unsigned int *buf, size_t buflen, + void* callback_arg), + void* callback_arg, + void* data); +/* Fallback function. Invoked when a Unicode character could not be converted + to the target encoding. This function should process the character and + may produce replacement bytes (in the target encoding) by calling the + write_replacement callback repeatedly. */ +typedef void (*iconv_unicode_uc_to_mb_fallback) + (unsigned int code, + void (*write_replacement) (const char *buf, size_t buflen, + void* callback_arg), + void* callback_arg, + void* data); +#if HAVE_WCHAR_T +/* Fallback function. Invoked when a number of bytes could not be converted to + a wide character. This function should process all bytes from inbuf and may + produce replacement wide characters by calling the write_replacement + callback repeatedly. */ +typedef void (*iconv_wchar_mb_to_wc_fallback) + (const char* inbuf, size_t inbufsize, + void (*write_replacement) (const wchar_t *buf, size_t buflen, + void* callback_arg), + void* callback_arg, + void* data); +/* Fallback function. Invoked when a wide character could not be converted to + the target encoding. This function should process the character and may + produce replacement bytes (in the target encoding) by calling the + write_replacement callback repeatedly. */ +typedef void (*iconv_wchar_wc_to_mb_fallback) + (wchar_t code, + void (*write_replacement) (const char *buf, size_t buflen, + void* callback_arg), + void* callback_arg, + void* data); +#else +/* If the wchar_t type does not exist, these two fallback functions are never + invoked. Their argument list therefore does not matter. */ +typedef void (*iconv_wchar_mb_to_wc_fallback) (); +typedef void (*iconv_wchar_wc_to_mb_fallback) (); +#endif +/* Set of fallbacks. */ +struct iconv_fallbacks { + iconv_unicode_mb_to_uc_fallback mb_to_uc_fallback; + iconv_unicode_uc_to_mb_fallback uc_to_mb_fallback; + iconv_wchar_mb_to_wc_fallback mb_to_wc_fallback; + iconv_wchar_wc_to_mb_fallback wc_to_mb_fallback; + void* data; +}; + +/* Requests for iconvctl. */ +#define ICONV_TRIVIALP 0 /* int *argument */ +#define ICONV_GET_TRANSLITERATE 1 /* int *argument */ +#define ICONV_SET_TRANSLITERATE 2 /* const int *argument */ +#define ICONV_GET_DISCARD_ILSEQ 3 /* int *argument */ +#define ICONV_SET_DISCARD_ILSEQ 4 /* const int *argument */ +#define ICONV_SET_HOOKS 5 /* const struct iconv_hooks *argument */ +#define ICONV_SET_FALLBACKS 6 /* const struct iconv_fallbacks *argument */ + +/* Listing of locale independent encodings. */ +#define iconvlist libiconvlist +extern LIBICONV_DLL_EXPORTED void iconvlist (int (*do_one) (unsigned int namescount, + const char * const * names, + void* data), + void* data); + +/* Canonicalize an encoding name. + The result is either a canonical encoding name, or name itself. */ +extern LIBICONV_DLL_EXPORTED const char * iconv_canonicalize (const char * name); + +/* Support for relocatable packages. */ + +/* Sets the original and the current installation prefix of the package. + Relocation simply replaces a pathname starting with the original prefix + by the corresponding pathname with the current prefix instead. Both + prefixes should be directory names without trailing slash (i.e. use "" + instead of "/"). */ +extern LIBICONV_DLL_EXPORTED void libiconv_set_relocation_prefix (const char *orig_prefix, + const char *curr_prefix); + +#endif + + +#ifdef __cplusplus +} +#endif + + +#endif /* _LIBICONV_H */ diff --git a/graf2d/win32gdk/gdk/src/iconv/iconv_open1.h b/graf2d/win32gdk/gdk/src/iconv/iconv_open1.h new file mode 100644 index 0000000000000..8a77014c3dbc7 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iconv_open1.h @@ -0,0 +1,201 @@ +/* + * Copyright (C) 1999-2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* Part 1 of iconv_open. + Input: const char* tocode, const char* fromcode. + Output: + unsigned int from_index; + int from_wchar; + unsigned int to_index; + int to_wchar; + int transliterate; + int discard_ilseq; + Jumps to 'invalid' in case of errror. + */ +{ + char buf[MAX_WORD_LENGTH+10+1]; + const char* cp; + char* bp; + const struct alias * ap; + unsigned int count; + + transliterate = 0; + discard_ilseq = 0; + + /* Before calling aliases_lookup, convert the input string to upper case, + * and check whether it's entirely ASCII (we call gperf with option "-7" + * to achieve a smaller table) and non-empty. If it's not entirely ASCII, + * or if it's too long, it is not a valid encoding name. + */ + for (to_wchar = 0;;) { + /* Search tocode in the table. */ + for (cp = tocode, bp = buf, count = MAX_WORD_LENGTH+10+1; ; cp++, bp++) { + unsigned char c = * (unsigned char *) cp; + if (c >= 0x80) + goto invalid; + if (c >= 'a' && c <= 'z') + c -= 'a'-'A'; + *bp = c; + if (c == '\0') + break; + if (--count == 0) + goto invalid; + } + for (;;) { + if (bp-buf >= 10 && memcmp(bp-10,"//TRANSLIT",10)==0) { + bp -= 10; + *bp = '\0'; + transliterate = 1; + continue; + } + if (bp-buf >= 8 && memcmp(bp-8,"//IGNORE",8)==0) { + bp -= 8; + *bp = '\0'; + discard_ilseq = 1; + continue; + } + break; + } + if (buf[0] == '\0') { + tocode = locale_charset(); + /* Avoid an endless loop that could occur when using an older version + of localcharset.c. */ + if (tocode[0] == '\0') + goto invalid; + continue; + } + ap = aliases_lookup(buf,bp-buf); + if (ap == NULL) { + ap = aliases2_lookup(buf); + if (ap == NULL) + goto invalid; + } + if (ap->encoding_index == ei_local_char) { + tocode = locale_charset(); + /* Avoid an endless loop that could occur when using an older version + of localcharset.c. */ + if (tocode[0] == '\0') + goto invalid; + continue; + } + if (ap->encoding_index == ei_local_wchar_t) { + /* On systems which define __STDC_ISO_10646__, wchar_t is Unicode. + This is also the case on native Woe32 systems. */ +#if __STDC_ISO_10646__ || ((defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__) + if (sizeof(wchar_t) == 4) { + to_index = ei_ucs4internal; + break; + } + if (sizeof(wchar_t) == 2) { + to_index = ei_ucs2internal; + break; + } + if (sizeof(wchar_t) == 1) { + to_index = ei_iso8859_1; + break; + } +#endif +#if HAVE_MBRTOWC + to_wchar = 1; + tocode = locale_charset(); + continue; +#endif + goto invalid; + } + to_index = ap->encoding_index; + break; + } + for (from_wchar = 0;;) { + /* Search fromcode in the table. */ + for (cp = fromcode, bp = buf, count = MAX_WORD_LENGTH+10+1; ; cp++, bp++) { + unsigned char c = * (unsigned char *) cp; + if (c >= 0x80) + goto invalid; + if (c >= 'a' && c <= 'z') + c -= 'a'-'A'; + *bp = c; + if (c == '\0') + break; + if (--count == 0) + goto invalid; + } + for (;;) { + if (bp-buf >= 10 && memcmp(bp-10,"//TRANSLIT",10)==0) { + bp -= 10; + *bp = '\0'; + continue; + } + if (bp-buf >= 8 && memcmp(bp-8,"//IGNORE",8)==0) { + bp -= 8; + *bp = '\0'; + continue; + } + break; + } + if (buf[0] == '\0') { + fromcode = locale_charset(); + /* Avoid an endless loop that could occur when using an older version + of localcharset.c. */ + if (fromcode[0] == '\0') + goto invalid; + continue; + } + ap = aliases_lookup(buf,bp-buf); + if (ap == NULL) { + ap = aliases2_lookup(buf); + if (ap == NULL) + goto invalid; + } + if (ap->encoding_index == ei_local_char) { + fromcode = locale_charset(); + /* Avoid an endless loop that could occur when using an older version + of localcharset.c. */ + if (fromcode[0] == '\0') + goto invalid; + continue; + } + if (ap->encoding_index == ei_local_wchar_t) { + /* On systems which define __STDC_ISO_10646__, wchar_t is Unicode. + This is also the case on native Woe32 systems. */ +#if __STDC_ISO_10646__ || ((defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__) + if (sizeof(wchar_t) == 4) { + from_index = ei_ucs4internal; + break; + } + if (sizeof(wchar_t) == 2) { + from_index = ei_ucs2internal; + break; + } + if (sizeof(wchar_t) == 1) { + from_index = ei_iso8859_1; + break; + } +#endif +#if HAVE_WCRTOMB + from_wchar = 1; + fromcode = locale_charset(); + continue; +#endif + goto invalid; + } + from_index = ap->encoding_index; + break; + } +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iconv_open2.h b/graf2d/win32gdk/gdk/src/iconv/iconv_open2.h new file mode 100644 index 0000000000000..6d6296f05b383 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iconv_open2.h @@ -0,0 +1,89 @@ +/* + * Copyright (C) 1999-2009 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* Part 2 of iconv_open. + Input: + struct conv_struct * cd; + unsigned int from_index; + int from_wchar; + unsigned int to_index; + int to_wchar; + int transliterate; + int discard_ilseq; + Output: none. + Side effects: Fills cd. + */ + + cd->iindex = from_index; + cd->ifuncs = all_encodings[from_index].ifuncs; + cd->oindex = to_index; + cd->ofuncs = all_encodings[to_index].ofuncs; + cd->oflags = all_encodings[to_index].oflags; + /* Initialize the loop functions. */ +#if HAVE_MBRTOWC + if (to_wchar) { +#if HAVE_WCRTOMB + if (from_wchar) { + cd->lfuncs.loop_convert = wchar_id_loop_convert; + cd->lfuncs.loop_reset = wchar_id_loop_reset; + } else +#endif + { + cd->lfuncs.loop_convert = wchar_to_loop_convert; + cd->lfuncs.loop_reset = wchar_to_loop_reset; + } + } else +#endif + { +#if HAVE_WCRTOMB + if (from_wchar) { + cd->lfuncs.loop_convert = wchar_from_loop_convert; + cd->lfuncs.loop_reset = wchar_from_loop_reset; + } else +#endif + { + cd->lfuncs.loop_convert = unicode_loop_convert; + cd->lfuncs.loop_reset = unicode_loop_reset; + } + } + /* Initialize the states. */ + memset(&cd->istate,'\0',sizeof(state_t)); + memset(&cd->ostate,'\0',sizeof(state_t)); + /* Initialize the operation flags. */ + cd->transliterate = transliterate; + cd->discard_ilseq = discard_ilseq; + #ifndef LIBICONV_PLUG + cd->fallbacks.mb_to_uc_fallback = NULL; + cd->fallbacks.uc_to_mb_fallback = NULL; + cd->fallbacks.mb_to_wc_fallback = NULL; + cd->fallbacks.wc_to_mb_fallback = NULL; + cd->fallbacks.data = NULL; + cd->hooks.uc_hook = NULL; + cd->hooks.wc_hook = NULL; + cd->hooks.data = NULL; + #endif + /* Initialize additional fields. */ + if (from_wchar != to_wchar) { + struct wchar_conv_struct * wcd = (struct wchar_conv_struct *) cd; +#if HAVE_WCRTOMB || HAVE_MBRTOWC + memset(&wcd->state,'\0',sizeof(mbstate_t)); +#endif + } + /* Done. */ diff --git a/graf2d/win32gdk/gdk/src/iconv/iso2022_cn.h b/graf2d/win32gdk/gdk/src/iconv/iso2022_cn.h new file mode 100644 index 0000000000000..d7e3e393a561b --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso2022_cn.h @@ -0,0 +1,324 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-2022-CN + */ + +/* Specification: RFC 1922 */ + +#define ESC 0x1b +#define SO 0x0e +#define SI 0x0f + +/* + * The state is composed of one of the following values + */ +#define STATE_ASCII 0 +#define STATE_TWOBYTE 1 +/* + * and one of the following values, << 8 + */ +#define STATE2_NONE 0 +#define STATE2_DESIGNATED_GB2312 1 +#define STATE2_DESIGNATED_CNS11643_1 2 +/* + * and one of the following values, << 16 + */ +#define STATE3_NONE 0 +#define STATE3_DESIGNATED_CNS11643_2 1 + +#define SPLIT_STATE \ + unsigned int state1 = state & 0xff, state2 = (state >> 8) & 0xff, state3 = state >> 16 +#define COMBINE_STATE \ + state = (state3 << 16) | (state2 << 8) | state1 + +static int +iso2022_cn_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + state_t state = conv->istate; + SPLIT_STATE; + int count = 0; + unsigned char c; + for (;;) { + c = *s; + if (c == ESC) { + if (n < count+4) + goto none; + if (s[1] == '$') { + if (s[2] == ')') { + if (s[3] == 'A') { + state2 = STATE2_DESIGNATED_GB2312; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + if (s[3] == 'G') { + state2 = STATE2_DESIGNATED_CNS11643_1; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + } + if (s[2] == '*') { + if (s[3] == 'H') { + state3 = STATE3_DESIGNATED_CNS11643_2; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + } + } + if (s[1] == 'N') { + switch (state3) { + case STATE3_NONE: + goto ilseq; + case STATE3_DESIGNATED_CNS11643_2: + if (s[2] < 0x80 && s[3] < 0x80) { + int ret = cns11643_2_mbtowc(conv,pwc,s+2,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+4; + } else + goto ilseq; + default: abort(); + } + } + goto ilseq; + } + if (c == SO) { + if (state2 != STATE2_DESIGNATED_GB2312 && state2 != STATE2_DESIGNATED_CNS11643_1) + goto ilseq; + state1 = STATE_TWOBYTE; + s++; count++; + if (n < count+1) + goto none; + continue; + } + if (c == SI) { + state1 = STATE_ASCII; + s++; count++; + if (n < count+1) + goto none; + continue; + } + break; + } + switch (state1) { + case STATE_ASCII: + if (c < 0x80) { + int ret = ascii_mbtowc(conv,pwc,s,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + if (*pwc == 0x000a || *pwc == 0x000d) { + state2 = STATE2_NONE; state3 = STATE3_NONE; + } + COMBINE_STATE; + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_TWOBYTE: + if (n < count+2) + goto none; + if (s[0] < 0x80 && s[1] < 0x80) { + int ret; + switch (state2) { + case STATE2_NONE: + goto ilseq; + case STATE2_DESIGNATED_GB2312: + ret = gb2312_mbtowc(conv,pwc,s,2); break; + case STATE2_DESIGNATED_CNS11643_1: + ret = cns11643_1_mbtowc(conv,pwc,s,2); break; + default: abort(); + } + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+2; + } else + goto ilseq; + default: abort(); + } + +none: + COMBINE_STATE; + conv->istate = state; + return RET_TOOFEW(count); + +ilseq: + COMBINE_STATE; + conv->istate = state; + return RET_SHIFT_ILSEQ(count); +} + +static int +iso2022_cn_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + state_t state = conv->ostate; + SPLIT_STATE; + unsigned char buf[3]; + int ret; + + /* There is no need to handle Unicode 3.1 tag characters and to look for + "zh-CN" or "zh-TW" tags, because GB2312 and CNS11643 are disjoint. */ + + /* Try ASCII. */ + ret = ascii_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] < 0x80) { + int count = (state1 == STATE_ASCII ? 1 : 2); + if (n < count) + return RET_TOOSMALL; + if (state1 != STATE_ASCII) { + r[0] = SI; + r += 1; + state1 = STATE_ASCII; + } + r[0] = buf[0]; + if (wc == 0x000a || wc == 0x000d) { + state2 = STATE2_NONE; state3 = STATE3_NONE; + } + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + /* Try GB 2312-1980. */ + ret = gb2312_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + int count = (state2 == STATE2_DESIGNATED_GB2312 ? 0 : 4) + (state1 == STATE_TWOBYTE ? 0 : 1) + 2; + if (n < count) + return RET_TOOSMALL; + if (state2 != STATE2_DESIGNATED_GB2312) { + r[0] = ESC; + r[1] = '$'; + r[2] = ')'; + r[3] = 'A'; + r += 4; + state2 = STATE2_DESIGNATED_GB2312; + } + if (state1 != STATE_TWOBYTE) { + r[0] = SO; + r += 1; + state1 = STATE_TWOBYTE; + } + r[0] = buf[0]; + r[1] = buf[1]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + ret = cns11643_wctomb(conv,buf,wc,3); + if (ret != RET_ILUNI) { + if (ret != 3) abort(); + + /* Try CNS 11643-1992 Plane 1. */ + if (buf[0] == 1 && buf[1] < 0x80 && buf[2] < 0x80) { + int count = (state2 == STATE2_DESIGNATED_CNS11643_1 ? 0 : 4) + (state1 == STATE_TWOBYTE ? 0 : 1) + 2; + if (n < count) + return RET_TOOSMALL; + if (state2 != STATE2_DESIGNATED_CNS11643_1) { + r[0] = ESC; + r[1] = '$'; + r[2] = ')'; + r[3] = 'G'; + r += 4; + state2 = STATE2_DESIGNATED_CNS11643_1; + } + if (state1 != STATE_TWOBYTE) { + r[0] = SO; + r += 1; + state1 = STATE_TWOBYTE; + } + r[0] = buf[1]; + r[1] = buf[2]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + + /* Try CNS 11643-1992 Plane 2. */ + if (buf[0] == 2 && buf[1] < 0x80 && buf[2] < 0x80) { + int count = (state3 == STATE3_DESIGNATED_CNS11643_2 ? 0 : 4) + 4; + if (n < count) + return RET_TOOSMALL; + if (state3 != STATE3_DESIGNATED_CNS11643_2) { + r[0] = ESC; + r[1] = '$'; + r[2] = '*'; + r[3] = 'H'; + r += 4; + state3 = STATE3_DESIGNATED_CNS11643_2; + } + r[0] = ESC; + r[1] = 'N'; + r[2] = buf[1]; + r[3] = buf[2]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + return RET_ILUNI; +} + +static int +iso2022_cn_reset (conv_t conv, unsigned char *r, int n) +{ + state_t state = conv->ostate; + SPLIT_STATE; + (void)state2; + (void)state3; + if (state1 != STATE_ASCII) { + if (n < 1) + return RET_TOOSMALL; + r[0] = SI; + /* conv->ostate = 0; will be done by the caller */ + return 1; + } else + return 0; +} + +#undef COMBINE_STATE +#undef SPLIT_STATE +#undef STATE3_DESIGNATED_CNS11643_2 +#undef STATE3_NONE +#undef STATE2_DESIGNATED_CNS11643_1 +#undef STATE2_DESIGNATED_GB2312 +#undef STATE2_NONE +#undef STATE_TWOBYTE +#undef STATE_ASCII diff --git a/graf2d/win32gdk/gdk/src/iconv/iso2022_cnext.h b/graf2d/win32gdk/gdk/src/iconv/iso2022_cnext.h new file mode 100644 index 0000000000000..f8488709db092 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso2022_cnext.h @@ -0,0 +1,590 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-2022-CN-EXT + */ + +/* Specification: RFC 1922 */ + +#define ESC 0x1b +#define SO 0x0e +#define SI 0x0f + +/* + * The state is composed of one of the following values + */ +#define STATE_ASCII 0 +#define STATE_TWOBYTE 1 +/* + * and one of the following values, << 8 + */ +#define STATE2_NONE 0 +#define STATE2_DESIGNATED_GB2312 1 +#define STATE2_DESIGNATED_CNS11643_1 2 +#define STATE2_DESIGNATED_ISO_IR_165 3 +/* + * and one of the following values, << 16 + */ +#define STATE3_NONE 0 +#define STATE3_DESIGNATED_CNS11643_2 1 +/* + * and one of the following values, << 24 + */ +#define STATE4_NONE 0 +#define STATE4_DESIGNATED_CNS11643_3 1 +#define STATE4_DESIGNATED_CNS11643_4 2 +#define STATE4_DESIGNATED_CNS11643_5 3 +#define STATE4_DESIGNATED_CNS11643_6 4 +#define STATE4_DESIGNATED_CNS11643_7 5 + +#define SPLIT_STATE \ + unsigned int state1 = state & 0xff, state2 = (state >> 8) & 0xff, state3 = (state >> 16) & 0xff, state4 = state >> 24 +#define COMBINE_STATE \ + state = (state4 << 24) | (state3 << 16) | (state2 << 8) | state1 + +static int +iso2022_cn_ext_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + state_t state = conv->istate; + SPLIT_STATE; + int count = 0; + unsigned char c; + for (;;) { + c = *s; + if (c == ESC) { + if (n < count+4) + goto none; + if (s[1] == '$') { + if (s[2] == ')') { + if (s[3] == 'A') { + state2 = STATE2_DESIGNATED_GB2312; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + if (s[3] == 'G') { + state2 = STATE2_DESIGNATED_CNS11643_1; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + if (s[3] == 'E') { + state2 = STATE2_DESIGNATED_ISO_IR_165; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + } + if (s[2] == '*') { + if (s[3] == 'H') { + state3 = STATE3_DESIGNATED_CNS11643_2; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + } + if (s[2] == '+') { + if (s[3] == 'I') { + state4 = STATE4_DESIGNATED_CNS11643_3; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + if (s[3] == 'J') { + state4 = STATE4_DESIGNATED_CNS11643_4; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + if (s[3] == 'K') { + state4 = STATE4_DESIGNATED_CNS11643_5; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + if (s[3] == 'L') { + state4 = STATE4_DESIGNATED_CNS11643_6; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + if (s[3] == 'M') { + state4 = STATE4_DESIGNATED_CNS11643_7; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + } + } + if (s[1] == 'N') { + switch (state3) { + case STATE3_NONE: + goto ilseq; + case STATE3_DESIGNATED_CNS11643_2: + if (s[2] < 0x80 && s[3] < 0x80) { + int ret = cns11643_2_mbtowc(conv,pwc,s+2,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+4; + } else + goto ilseq; + default: abort(); + } + } + if (s[1] == 'O') { + switch (state4) { + case STATE4_NONE: + goto ilseq; + case STATE4_DESIGNATED_CNS11643_3: + if (s[2] < 0x80 && s[3] < 0x80) { + int ret = cns11643_3_mbtowc(conv,pwc,s+2,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+4; + } else + goto ilseq; + case STATE4_DESIGNATED_CNS11643_4: + if (s[2] < 0x80 && s[3] < 0x80) { + int ret = cns11643_4_mbtowc(conv,pwc,s+2,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+4; + } else + goto ilseq; + case STATE4_DESIGNATED_CNS11643_5: + if (s[2] < 0x80 && s[3] < 0x80) { + int ret = cns11643_5_mbtowc(conv,pwc,s+2,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+4; + } else + goto ilseq; + case STATE4_DESIGNATED_CNS11643_6: + if (s[2] < 0x80 && s[3] < 0x80) { + int ret = cns11643_6_mbtowc(conv,pwc,s+2,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+4; + } else + goto ilseq; + case STATE4_DESIGNATED_CNS11643_7: + if (s[2] < 0x80 && s[3] < 0x80) { + int ret = cns11643_7_mbtowc(conv,pwc,s+2,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+4; + } else + goto ilseq; + default: abort(); + } + } + goto ilseq; + } + if (c == SO) { + if (state2 != STATE2_DESIGNATED_GB2312 && state2 != STATE2_DESIGNATED_CNS11643_1 && state2 != STATE2_DESIGNATED_ISO_IR_165) + goto ilseq; + state1 = STATE_TWOBYTE; + s++; count++; + if (n < count+1) + goto none; + continue; + } + if (c == SI) { + state1 = STATE_ASCII; + s++; count++; + if (n < count+1) + goto none; + continue; + } + break; + } + switch (state1) { + case STATE_ASCII: + if (c < 0x80) { + int ret = ascii_mbtowc(conv,pwc,s,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + if (*pwc == 0x000a || *pwc == 0x000d) { + state2 = STATE2_NONE; state3 = STATE3_NONE; state4 = STATE3_NONE; + } + COMBINE_STATE; + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_TWOBYTE: + if (n < count+2) + goto none; + if (s[0] < 0x80 && s[1] < 0x80) { + int ret; + switch (state2) { + case STATE2_NONE: + goto ilseq; + case STATE2_DESIGNATED_GB2312: + ret = gb2312_mbtowc(conv,pwc,s,2); break; + case STATE2_DESIGNATED_CNS11643_1: + ret = cns11643_1_mbtowc(conv,pwc,s,2); break; + case STATE2_DESIGNATED_ISO_IR_165: + ret = isoir165_mbtowc(conv,pwc,s,2); break; + default: abort(); + } + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+2; + } else + goto ilseq; + default: abort(); + } + +none: + COMBINE_STATE; + conv->istate = state; + return RET_TOOFEW(count); + +ilseq: + COMBINE_STATE; + conv->istate = state; + return RET_SHIFT_ILSEQ(count); +} + +static int +iso2022_cn_ext_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + state_t state = conv->ostate; + SPLIT_STATE; + unsigned char buf[3]; + int ret; + + /* There is no need to handle Unicode 3.1 tag characters and to look for + "zh-CN" or "zh-TW" tags, because GB2312 and CNS11643 are disjoint. */ + + /* Try ASCII. */ + ret = ascii_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] < 0x80) { + int count = (state1 == STATE_ASCII ? 1 : 2); + if (n < count) + return RET_TOOSMALL; + if (state1 != STATE_ASCII) { + r[0] = SI; + r += 1; + state1 = STATE_ASCII; + } + r[0] = buf[0]; + if (wc == 0x000a || wc == 0x000d) { + state2 = STATE2_NONE; state3 = STATE3_NONE; state4 = STATE3_NONE; + } + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + /* Try GB 2312-1980. */ + ret = gb2312_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + int count = (state2 == STATE2_DESIGNATED_GB2312 ? 0 : 4) + (state1 == STATE_TWOBYTE ? 0 : 1) + 2; + if (n < count) + return RET_TOOSMALL; + if (state2 != STATE2_DESIGNATED_GB2312) { + r[0] = ESC; + r[1] = '$'; + r[2] = ')'; + r[3] = 'A'; + r += 4; + state2 = STATE2_DESIGNATED_GB2312; + } + if (state1 != STATE_TWOBYTE) { + r[0] = SO; + r += 1; + state1 = STATE_TWOBYTE; + } + r[0] = buf[0]; + r[1] = buf[1]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + ret = cns11643_wctomb(conv,buf,wc,3); + if (ret != RET_ILUNI) { + if (ret != 3) abort(); + + /* Try CNS 11643-1992 Plane 1. */ + if (buf[0] == 1 && buf[1] < 0x80 && buf[2] < 0x80) { + int count = (state2 == STATE2_DESIGNATED_CNS11643_1 ? 0 : 4) + (state1 == STATE_TWOBYTE ? 0 : 1) + 2; + if (n < count) + return RET_TOOSMALL; + if (state2 != STATE2_DESIGNATED_CNS11643_1) { + r[0] = ESC; + r[1] = '$'; + r[2] = ')'; + r[3] = 'G'; + r += 4; + state2 = STATE2_DESIGNATED_CNS11643_1; + } + if (state1 != STATE_TWOBYTE) { + r[0] = SO; + r += 1; + state1 = STATE_TWOBYTE; + } + r[0] = buf[1]; + r[1] = buf[2]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + + /* Try CNS 11643-1992 Plane 2. */ + if (buf[0] == 2 && buf[1] < 0x80 && buf[2] < 0x80) { + int count = (state3 == STATE3_DESIGNATED_CNS11643_2 ? 0 : 4) + 4; + if (n < count) + return RET_TOOSMALL; + if (state3 != STATE3_DESIGNATED_CNS11643_2) { + r[0] = ESC; + r[1] = '$'; + r[2] = '*'; + r[3] = 'H'; + r += 4; + state3 = STATE3_DESIGNATED_CNS11643_2; + } + r[0] = ESC; + r[1] = 'N'; + r[2] = buf[1]; + r[3] = buf[2]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + + /* Try CNS 11643-1992 Plane 3. */ + if (buf[0] == 3 && buf[1] < 0x80 && buf[2] < 0x80) { + int count = (state4 == STATE4_DESIGNATED_CNS11643_3 ? 0 : 4) + 4; + if (n < count) + return RET_TOOSMALL; + if (state4 != STATE4_DESIGNATED_CNS11643_3) { + r[0] = ESC; + r[1] = '$'; + r[2] = '+'; + r[3] = 'I'; + r += 4; + state4 = STATE4_DESIGNATED_CNS11643_3; + } + r[0] = ESC; + r[1] = 'O'; + r[2] = buf[1]; + r[3] = buf[2]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + + /* Try CNS 11643-1992 Plane 4. */ + if (buf[0] == 4 && buf[1] < 0x80 && buf[2] < 0x80) { + int count = (state4 == STATE4_DESIGNATED_CNS11643_4 ? 0 : 4) + 4; + if (n < count) + return RET_TOOSMALL; + if (state4 != STATE4_DESIGNATED_CNS11643_4) { + r[0] = ESC; + r[1] = '$'; + r[2] = '+'; + r[3] = 'J'; + r += 4; + state4 = STATE4_DESIGNATED_CNS11643_4; + } + r[0] = ESC; + r[1] = 'O'; + r[2] = buf[1]; + r[3] = buf[2]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + + /* Try CNS 11643-1992 Plane 5. */ + if (buf[0] == 5 && buf[1] < 0x80 && buf[2] < 0x80) { + int count = (state4 == STATE4_DESIGNATED_CNS11643_5 ? 0 : 4) + 4; + if (n < count) + return RET_TOOSMALL; + if (state4 != STATE4_DESIGNATED_CNS11643_5) { + r[0] = ESC; + r[1] = '$'; + r[2] = '+'; + r[3] = 'K'; + r += 4; + state4 = STATE4_DESIGNATED_CNS11643_5; + } + r[0] = ESC; + r[1] = 'O'; + r[2] = buf[1]; + r[3] = buf[2]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + + /* Try CNS 11643-1992 Plane 6. */ + if (buf[0] == 6 && buf[1] < 0x80 && buf[2] < 0x80) { + int count = (state4 == STATE4_DESIGNATED_CNS11643_6 ? 0 : 4) + 4; + if (n < count) + return RET_TOOSMALL; + if (state4 != STATE4_DESIGNATED_CNS11643_6) { + r[0] = ESC; + r[1] = '$'; + r[2] = '+'; + r[3] = 'L'; + r += 4; + state4 = STATE4_DESIGNATED_CNS11643_6; + } + r[0] = ESC; + r[1] = 'O'; + r[2] = buf[1]; + r[3] = buf[2]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + + /* Try CNS 11643-1992 Plane 7. */ + if (buf[0] == 7 && buf[1] < 0x80 && buf[2] < 0x80) { + int count = (state4 == STATE4_DESIGNATED_CNS11643_7 ? 0 : 4) + 4; + if (n < count) + return RET_TOOSMALL; + if (state4 != STATE4_DESIGNATED_CNS11643_7) { + r[0] = ESC; + r[1] = '$'; + r[2] = '+'; + r[3] = 'M'; + r += 4; + state4 = STATE4_DESIGNATED_CNS11643_7; + } + r[0] = ESC; + r[1] = 'O'; + r[2] = buf[1]; + r[3] = buf[2]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + + } + + /* Try ISO-IR-165. */ + ret = isoir165_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + int count = (state2 == STATE2_DESIGNATED_ISO_IR_165 ? 0 : 4) + (state1 == STATE_TWOBYTE ? 0 : 1) + 2; + if (n < count) + return RET_TOOSMALL; + if (state2 != STATE2_DESIGNATED_ISO_IR_165) { + r[0] = ESC; + r[1] = '$'; + r[2] = ')'; + r[3] = 'E'; + r += 4; + state2 = STATE2_DESIGNATED_ISO_IR_165; + } + if (state1 != STATE_TWOBYTE) { + r[0] = SO; + r += 1; + state1 = STATE_TWOBYTE; + } + r[0] = buf[0]; + r[1] = buf[1]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + return RET_ILUNI; +} + +static int +iso2022_cn_ext_reset (conv_t conv, unsigned char *r, int n) +{ + state_t state = conv->ostate; + SPLIT_STATE; + (void)state2; + (void)state3; + (void)state4; + if (state1 != STATE_ASCII) { + if (n < 1) + return RET_TOOSMALL; + r[0] = SI; + /* conv->ostate = 0; will be done by the caller */ + return 1; + } else + return 0; +} + +#undef COMBINE_STATE +#undef SPLIT_STATE +#undef STATE4_DESIGNATED_CNS11643_7 +#undef STATE4_DESIGNATED_CNS11643_6 +#undef STATE4_DESIGNATED_CNS11643_5 +#undef STATE4_DESIGNATED_CNS11643_4 +#undef STATE4_DESIGNATED_CNS11643_3 +#undef STATE4_NONE +#undef STATE3_DESIGNATED_CNS11643_2 +#undef STATE3_NONE +#undef STATE2_DESIGNATED_ISO_IR_165 +#undef STATE2_DESIGNATED_CNS11643_1 +#undef STATE2_DESIGNATED_GB2312 +#undef STATE2_NONE +#undef STATE_TWOBYTE +#undef STATE_ASCII diff --git a/graf2d/win32gdk/gdk/src/iconv/iso2022_jp.h b/graf2d/win32gdk/gdk/src/iconv/iso2022_jp.h new file mode 100644 index 0000000000000..1c8abec1bb331 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso2022_jp.h @@ -0,0 +1,216 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-2022-JP + */ + +/* Specification: RFC 1468 */ + +#define ESC 0x1b + +/* + * The state can be one of the following values. + */ +#define STATE_ASCII 0 +#define STATE_JISX0201ROMAN 1 +#define STATE_JISX0208 2 + +static int +iso2022_jp_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + state_t state = conv->istate; + int count = 0; + unsigned char c; + for (;;) { + c = *s; + if (c == ESC) { + if (n < count+3) + goto none; + if (s[1] == '(') { + if (s[2] == 'B') { + state = STATE_ASCII; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + if (s[2] == 'J') { + state = STATE_JISX0201ROMAN; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + goto ilseq; + } + if (s[1] == '$') { + if (s[2] == '@' || s[2] == 'B') { + /* We don't distinguish JIS X 0208-1978 and JIS X 0208-1983. */ + state = STATE_JISX0208; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + goto ilseq; + } + goto ilseq; + } + break; + } + switch (state) { + case STATE_ASCII: + if (c < 0x80) { + int ret = ascii_mbtowc(conv,pwc,s,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_JISX0201ROMAN: + if (c < 0x80) { + int ret = jisx0201_mbtowc(conv,pwc,s,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_JISX0208: + if (n < count+2) + goto none; + if (s[0] < 0x80 && s[1] < 0x80) { + int ret = jisx0208_mbtowc(conv,pwc,s,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + conv->istate = state; + return count+2; + } else + goto ilseq; + default: abort(); + } + +none: + conv->istate = state; + return RET_TOOFEW(count); + +ilseq: + conv->istate = state; + return RET_SHIFT_ILSEQ(count); +} + +static int +iso2022_jp_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + state_t state = conv->ostate; + unsigned char buf[2]; + int ret; + + /* Try ASCII. */ + ret = ascii_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] < 0x80) { + int count = (state == STATE_ASCII ? 1 : 4); + if (n < count) + return RET_TOOSMALL; + if (state != STATE_ASCII) { + r[0] = ESC; + r[1] = '('; + r[2] = 'B'; + r += 3; + state = STATE_ASCII; + } + r[0] = buf[0]; + conv->ostate = state; + return count; + } + } + + /* Try JIS X 0201-1976 Roman. */ + ret = jisx0201_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] < 0x80) { + int count = (state == STATE_JISX0201ROMAN ? 1 : 4); + if (n < count) + return RET_TOOSMALL; + if (state != STATE_JISX0201ROMAN) { + r[0] = ESC; + r[1] = '('; + r[2] = 'J'; + r += 3; + state = STATE_JISX0201ROMAN; + } + r[0] = buf[0]; + conv->ostate = state; + return count; + } + } + + /* Try JIS X 0208-1990 in place of JIS X 0208-1978 and JIS X 0208-1983. */ + ret = jisx0208_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + int count = (state == STATE_JISX0208 ? 2 : 5); + if (n < count) + return RET_TOOSMALL; + if (state != STATE_JISX0208) { + r[0] = ESC; + r[1] = '$'; + r[2] = 'B'; + r += 3; + state = STATE_JISX0208; + } + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = state; + return count; + } + } + + return RET_ILUNI; +} + +static int +iso2022_jp_reset (conv_t conv, unsigned char *r, int n) +{ + state_t state = conv->ostate; + if (state != STATE_ASCII) { + if (n < 3) + return RET_TOOSMALL; + r[0] = ESC; + r[1] = '('; + r[2] = 'B'; + /* conv->ostate = 0; will be done by the caller */ + return 3; + } else + return 0; +} + +#undef STATE_JISX0208 +#undef STATE_JISX0201ROMAN +#undef STATE_ASCII diff --git a/graf2d/win32gdk/gdk/src/iconv/iso2022_jp1.h b/graf2d/win32gdk/gdk/src/iconv/iso2022_jp1.h new file mode 100644 index 0000000000000..c3094740f9a1b --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso2022_jp1.h @@ -0,0 +1,264 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-2022-JP-1 + */ + +/* Specification: RFC 2237 */ + +#define ESC 0x1b + +/* + * The state can be one of the following values. + */ +#define STATE_ASCII 0 +#define STATE_JISX0201ROMAN 1 +#define STATE_JISX0208 2 +#define STATE_JISX0212 3 + +static int +iso2022_jp1_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + state_t state = conv->istate; + int count = 0; + unsigned char c; + for (;;) { + c = *s; + if (c == ESC) { + if (n < count+3) + goto none; + if (s[1] == '(') { + if (s[2] == 'B') { + state = STATE_ASCII; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + if (s[2] == 'J') { + state = STATE_JISX0201ROMAN; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + goto ilseq; + } + if (s[1] == '$') { + if (s[2] == '@' || s[2] == 'B') { + /* We don't distinguish JIS X 0208-1978 and JIS X 0208-1983. */ + state = STATE_JISX0208; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + if (s[2] == '(') { + if (n < count+4) + goto none; + if (s[3] == 'D') { + state = STATE_JISX0212; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + } + goto ilseq; + } + goto ilseq; + } + break; + } + switch (state) { + case STATE_ASCII: + if (c < 0x80) { + int ret = ascii_mbtowc(conv,pwc,s,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_JISX0201ROMAN: + if (c < 0x80) { + int ret = jisx0201_mbtowc(conv,pwc,s,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_JISX0208: + if (n < count+2) + goto none; + if (s[0] < 0x80 && s[1] < 0x80) { + int ret = jisx0208_mbtowc(conv,pwc,s,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + conv->istate = state; + return count+2; + } else + goto ilseq; + case STATE_JISX0212: + if (n < count+2) + goto none; + if (s[0] < 0x80 && s[1] < 0x80) { + int ret = jisx0212_mbtowc(conv,pwc,s,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + conv->istate = state; + return count+2; + } else + goto ilseq; + default: abort(); + } + +none: + conv->istate = state; + return RET_TOOFEW(count); + +ilseq: + conv->istate = state; + return RET_SHIFT_ILSEQ(count); +} + +static int +iso2022_jp1_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + state_t state = conv->ostate; + unsigned char buf[2]; + int ret; + + /* Try ASCII. */ + ret = ascii_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] < 0x80) { + int count = (state == STATE_ASCII ? 1 : 4); + if (n < count) + return RET_TOOSMALL; + if (state != STATE_ASCII) { + r[0] = ESC; + r[1] = '('; + r[2] = 'B'; + r += 3; + state = STATE_ASCII; + } + r[0] = buf[0]; + conv->ostate = state; + return count; + } + } + + /* Try JIS X 0201-1976 Roman. */ + ret = jisx0201_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] < 0x80) { + int count = (state == STATE_JISX0201ROMAN ? 1 : 4); + if (n < count) + return RET_TOOSMALL; + if (state != STATE_JISX0201ROMAN) { + r[0] = ESC; + r[1] = '('; + r[2] = 'J'; + r += 3; + state = STATE_JISX0201ROMAN; + } + r[0] = buf[0]; + conv->ostate = state; + return count; + } + } + + /* Try JIS X 0208-1990 in place of JIS X 0208-1978 and JIS X 0208-1983. */ + ret = jisx0208_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + int count = (state == STATE_JISX0208 ? 2 : 5); + if (n < count) + return RET_TOOSMALL; + if (state != STATE_JISX0208) { + r[0] = ESC; + r[1] = '$'; + r[2] = 'B'; + r += 3; + state = STATE_JISX0208; + } + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = state; + return count; + } + } + + /* Try JIS X 0212-1990. */ + ret = jisx0212_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + int count = (state == STATE_JISX0212 ? 2 : 6); + if (n < count) + return RET_TOOSMALL; + if (state != STATE_JISX0212) { + r[0] = ESC; + r[1] = '$'; + r[2] = '('; + r[3] = 'D'; + r += 4; + state = STATE_JISX0212; + } + r[0] = buf[0]; + r[1] = buf[1]; + conv->ostate = state; + return count; + } + } + + return RET_ILUNI; +} + +static int +iso2022_jp1_reset (conv_t conv, unsigned char *r, int n) +{ + state_t state = conv->ostate; + if (state != STATE_ASCII) { + if (n < 3) + return RET_TOOSMALL; + r[0] = ESC; + r[1] = '('; + r[2] = 'B'; + /* conv->ostate = 0; will be done by the caller */ + return 3; + } else + return 0; +} + +#undef STATE_JISX0212 +#undef STATE_JISX0208 +#undef STATE_JISX0201ROMAN +#undef STATE_ASCII diff --git a/graf2d/win32gdk/gdk/src/iconv/iso2022_jp2.h b/graf2d/win32gdk/gdk/src/iconv/iso2022_jp2.h new file mode 100644 index 0000000000000..5e3ca41555a54 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso2022_jp2.h @@ -0,0 +1,693 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-2022-JP-2 + */ + +/* Specification: RFC 1554 */ +/* ESC '(' 'I' for JISX0201 Katakana is an extension not found in RFC 1554 or + CJK.INF, but implemented in glibc-2.1 and qt-2.0. */ + +#define ESC 0x1b + +/* + * The state is composed of one of the following values + */ +#define STATE_ASCII 0 +#define STATE_JISX0201ROMAN 1 +#define STATE_JISX0201KATAKANA 2 +#define STATE_JISX0208 3 +#define STATE_JISX0212 4 +#define STATE_GB2312 5 +#define STATE_KSC5601 6 +/* + * and one of the following values, << 8 + */ +#define STATE_G2_NONE 0 +#define STATE_G2_ISO8859_1 1 +#define STATE_G2_ISO8859_7 2 + +#define SPLIT_STATE \ + unsigned int state1 = state & 0xff, state2 = state >> 8 +#define COMBINE_STATE \ + state = (state2 << 8) | state1 + +static int +iso2022_jp2_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + state_t state = conv->istate; + SPLIT_STATE; + int count = 0; + unsigned char c; + for (;;) { + c = *s; + if (c == ESC) { + if (n < count+3) + goto none; + if (s[1] == '(') { + if (s[2] == 'B') { + state1 = STATE_ASCII; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + if (s[2] == 'J') { + state1 = STATE_JISX0201ROMAN; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + if (s[2] == 'I') { + state1 = STATE_JISX0201KATAKANA; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + goto ilseq; + } + if (s[1] == '$') { + if (s[2] == '@' || s[2] == 'B') { + /* We don't distinguish JIS X 0208-1978 and JIS X 0208-1983. */ + state1 = STATE_JISX0208; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + if (s[2] == 'A') { + state1 = STATE_GB2312; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + if (s[2] == '(') { + if (n < count+4) + goto none; + if (s[3] == 'D') { + state1 = STATE_JISX0212; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + if (s[3] == 'C') { + state1 = STATE_KSC5601; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + goto ilseq; + } + goto ilseq; + } + if (s[1] == '.') { + if (n < count+3) + goto none; + if (s[2] == 'A') { + state2 = STATE_G2_ISO8859_1; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + if (s[2] == 'F') { + state2 = STATE_G2_ISO8859_7; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + goto ilseq; + } + if (s[1] == 'N') { + switch (state2) { + case STATE_G2_NONE: + goto ilseq; + case STATE_G2_ISO8859_1: + if (s[2] < 0x80) { + unsigned char buf = s[2]+0x80; + int ret = iso8859_1_mbtowc(conv,pwc,&buf,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + COMBINE_STATE; + conv->istate = state; + return count+3; + } else + goto ilseq; + case STATE_G2_ISO8859_7: + if (s[2] < 0x80) { + unsigned char buf = s[2]+0x80; + int ret = iso8859_7_mbtowc(conv,pwc,&buf,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + COMBINE_STATE; + conv->istate = state; + return count+3; + } else + goto ilseq; + default: abort(); + } + } + goto ilseq; + } + break; + } + switch (state1) { + case STATE_ASCII: + if (c < 0x80) { + int ret = ascii_mbtowc(conv,pwc,s,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + if (*pwc == 0x000a || *pwc == 0x000d) + state2 = STATE_G2_NONE; + COMBINE_STATE; + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_JISX0201ROMAN: + if (c < 0x80) { + int ret = jisx0201_mbtowc(conv,pwc,s,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + if (*pwc == 0x000a || *pwc == 0x000d) + state2 = STATE_G2_NONE; + COMBINE_STATE; + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_JISX0201KATAKANA: + if (c < 0x80) { + unsigned char buf = c+0x80; + int ret = jisx0201_mbtowc(conv,pwc,&buf,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + COMBINE_STATE; + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_JISX0208: + if (n < count+2) + goto none; + if (s[0] < 0x80 && s[1] < 0x80) { + int ret = jisx0208_mbtowc(conv,pwc,s,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+2; + } else + goto ilseq; + case STATE_JISX0212: + if (n < count+2) + goto none; + if (s[0] < 0x80 && s[1] < 0x80) { + int ret = jisx0212_mbtowc(conv,pwc,s,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+2; + } else + goto ilseq; + case STATE_GB2312: + if (n < count+2) + goto none; + if (s[0] < 0x80 && s[1] < 0x80) { + int ret = gb2312_mbtowc(conv,pwc,s,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+2; + } else + goto ilseq; + case STATE_KSC5601: + if (n < count+2) + goto none; + if (s[0] < 0x80 && s[1] < 0x80) { + int ret = ksc5601_mbtowc(conv,pwc,s,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+2; + } else + goto ilseq; + default: abort(); + } + +none: + COMBINE_STATE; + conv->istate = state; + return RET_TOOFEW(count); + +ilseq: + COMBINE_STATE; + conv->istate = state; + return RET_SHIFT_ILSEQ(count); +} + +#undef COMBINE_STATE +#undef SPLIT_STATE + +/* + * The state can also contain one of the following values, << 16. + * Values >= STATE_TAG_LANGUAGE are temporary tag parsing states. + */ +#define STATE_TAG_NONE 0 +#define STATE_TAG_LANGUAGE 4 +#define STATE_TAG_LANGUAGE_j 5 +#define STATE_TAG_LANGUAGE_ja 1 +#define STATE_TAG_LANGUAGE_k 6 +#define STATE_TAG_LANGUAGE_ko 2 +#define STATE_TAG_LANGUAGE_z 7 +#define STATE_TAG_LANGUAGE_zh 3 + +#define SPLIT_STATE \ + unsigned int state1 = state & 0xff, state2 = (state >> 8) & 0xff, state3 = state >> 16 +#define COMBINE_STATE \ + state = (state3 << 16) | (state2 << 8) | state1 + +static int +iso2022_jp2_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + state_t state = conv->ostate; + SPLIT_STATE; + unsigned char buf[2]; + int ret; + /* This defines the conversion preferences depending on the current + langauge tag. */ + enum conversion { none = 0, european, japanese, chinese, korean, other }; + static const unsigned int conversion_lists[STATE_TAG_LANGUAGE] = { + /* STATE_TAG_NONE */ + japanese + (european << 3) + (chinese << 6) + (korean << 9) + (other << 12), + /* STATE_TAG_LANGUAGE_ja */ + japanese + (european << 3) + (chinese << 6) + (korean << 9) + (other << 12), + /* STATE_TAG_LANGUAGE_ko */ + korean + (european << 3) + (japanese << 6) + (chinese << 9) + (other << 12), + /* STATE_TAG_LANGUAGE_zh */ + chinese + (european << 3) + (japanese << 6) + (korean << 9) + (other << 12) + }; + unsigned int conversion_list; + + /* Handle Unicode tag characters (range U+E0000..U+E007F). */ + if ((wc >> 7) == (0xe0000 >> 7)) { + char c = wc & 0x7f; + if (c >= 'A' && c <= 'Z') + c += 'a'-'A'; + switch (c) { + case 0x01: + state3 = STATE_TAG_LANGUAGE; + COMBINE_STATE; + conv->ostate = state; + return 0; + case 'j': + if (state3 == STATE_TAG_LANGUAGE) { + state3 = STATE_TAG_LANGUAGE_j; + COMBINE_STATE; + conv->ostate = state; + return 0; + } + break; + case 'a': + if (state3 == STATE_TAG_LANGUAGE_j) { + state3 = STATE_TAG_LANGUAGE_ja; + COMBINE_STATE; + conv->ostate = state; + return 0; + } + break; + case 'k': + if (state3 == STATE_TAG_LANGUAGE) { + state3 = STATE_TAG_LANGUAGE_k; + COMBINE_STATE; + conv->ostate = state; + return 0; + } + break; + case 'o': + if (state3 == STATE_TAG_LANGUAGE_k) { + state3 = STATE_TAG_LANGUAGE_ko; + COMBINE_STATE; + conv->ostate = state; + return 0; + } + break; + case 'z': + if (state3 == STATE_TAG_LANGUAGE) { + state3 = STATE_TAG_LANGUAGE_z; + COMBINE_STATE; + conv->ostate = state; + return 0; + } + break; + case 'h': + if (state3 == STATE_TAG_LANGUAGE_z) { + state3 = STATE_TAG_LANGUAGE_zh; + COMBINE_STATE; + conv->ostate = state; + return 0; + } + break; + case 0x7f: + state3 = STATE_TAG_NONE; + COMBINE_STATE; + conv->ostate = state; + return 0; + default: + break; + } + /* Other tag characters reset the tag parsing state or are ignored. */ + if (state3 >= STATE_TAG_LANGUAGE) + state3 = STATE_TAG_NONE; + COMBINE_STATE; + conv->ostate = state; + return 0; + } + if (state3 >= STATE_TAG_LANGUAGE) + state3 = STATE_TAG_NONE; + + /* Try ASCII. */ + ret = ascii_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] < 0x80) { + int count = (state1 == STATE_ASCII ? 1 : 4); + if (n < count) + return RET_TOOSMALL; + if (state1 != STATE_ASCII) { + r[0] = ESC; + r[1] = '('; + r[2] = 'B'; + r += 3; + state1 = STATE_ASCII; + } + r[0] = buf[0]; + if (wc == 0x000a || wc == 0x000d) + state2 = STATE_G2_NONE; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + conversion_list = conversion_lists[state3]; + + do { + switch (conversion_list & ((1 << 3) - 1)) { + + case european: + + /* Try ISO-8859-1. */ + ret = iso8859_1_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] >= 0x80) { + int count = (state2 == STATE_G2_ISO8859_1 ? 3 : 6); + if (n < count) + return RET_TOOSMALL; + if (state2 != STATE_G2_ISO8859_1) { + r[0] = ESC; + r[1] = '.'; + r[2] = 'A'; + r += 3; + state2 = STATE_G2_ISO8859_1; + } + r[0] = ESC; + r[1] = 'N'; + r[2] = buf[0]-0x80; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + /* Try ISO-8859-7. */ + ret = iso8859_7_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] >= 0x80) { + int count = (state2 == STATE_G2_ISO8859_7 ? 3 : 6); + if (n < count) + return RET_TOOSMALL; + if (state2 != STATE_G2_ISO8859_7) { + r[0] = ESC; + r[1] = '.'; + r[2] = 'F'; + r += 3; + state2 = STATE_G2_ISO8859_7; + } + r[0] = ESC; + r[1] = 'N'; + r[2] = buf[0]-0x80; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + break; + + case japanese: + + /* Try JIS X 0201-1976 Roman. */ + ret = jisx0201_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] < 0x80) { + int count = (state1 == STATE_JISX0201ROMAN ? 1 : 4); + if (n < count) + return RET_TOOSMALL; + if (state1 != STATE_JISX0201ROMAN) { + r[0] = ESC; + r[1] = '('; + r[2] = 'J'; + r += 3; + state1 = STATE_JISX0201ROMAN; + } + r[0] = buf[0]; + if (wc == 0x000a || wc == 0x000d) + state2 = STATE_G2_NONE; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + /* Try JIS X 0208-1990 in place of JIS X 0208-1978 and + JIS X 0208-1983. */ + ret = jisx0208_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + int count = (state1 == STATE_JISX0208 ? 2 : 5); + if (n < count) + return RET_TOOSMALL; + if (state1 != STATE_JISX0208) { + r[0] = ESC; + r[1] = '$'; + r[2] = 'B'; + r += 3; + state1 = STATE_JISX0208; + } + r[0] = buf[0]; + r[1] = buf[1]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + /* Try JIS X 0212-1990. */ + ret = jisx0212_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + int count = (state1 == STATE_JISX0212 ? 2 : 6); + if (n < count) + return RET_TOOSMALL; + if (state1 != STATE_JISX0212) { + r[0] = ESC; + r[1] = '$'; + r[2] = '('; + r[3] = 'D'; + r += 4; + state1 = STATE_JISX0212; + } + r[0] = buf[0]; + r[1] = buf[1]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + break; + + case chinese: + + /* Try GB 2312-1980. */ + ret = gb2312_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + int count = (state1 == STATE_GB2312 ? 2 : 5); + if (n < count) + return RET_TOOSMALL; + if (state1 != STATE_GB2312) { + r[0] = ESC; + r[1] = '$'; + r[2] = 'A'; + r += 3; + state1 = STATE_GB2312; + } + r[0] = buf[0]; + r[1] = buf[1]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + break; + + case korean: + + /* Try KS C 5601-1992. */ + ret = ksc5601_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + int count = (state1 == STATE_KSC5601 ? 2 : 6); + if (n < count) + return RET_TOOSMALL; + if (state1 != STATE_KSC5601) { + r[0] = ESC; + r[1] = '$'; + r[2] = '('; + r[3] = 'C'; + r += 4; + state1 = STATE_KSC5601; + } + r[0] = buf[0]; + r[1] = buf[1]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + break; + + case other: + + /* Try JIS X 0201-1976 Kana. This is not officially part of + ISO-2022-JP-2, according to RFC 1554. Therefore we try this + only after all other attempts. */ + ret = jisx0201_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] >= 0x80) { + int count = (state1 == STATE_JISX0201KATAKANA ? 1 : 4); + if (n < count) + return RET_TOOSMALL; + if (state1 != STATE_JISX0201KATAKANA) { + r[0] = ESC; + r[1] = '('; + r[2] = 'I'; + r += 3; + state1 = STATE_JISX0201KATAKANA; + } + r[0] = buf[0]-0x80; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + break; + + default: + abort(); + } + + conversion_list = conversion_list >> 3; + } while (conversion_list != 0); + + return RET_ILUNI; +} + +static int +iso2022_jp2_reset (conv_t conv, unsigned char *r, int n) +{ + state_t state = conv->ostate; + SPLIT_STATE; + (void)state2; + (void)state3; + if (state1 != STATE_ASCII) { + if (n < 3) + return RET_TOOSMALL; + r[0] = ESC; + r[1] = '('; + r[2] = 'B'; + /* conv->ostate = 0; will be done by the caller */ + return 3; + } else + return 0; +} + +#undef COMBINE_STATE +#undef SPLIT_STATE +#undef STATE_TAG_LANGUAGE_zh +#undef STATE_TAG_LANGUAGE_z +#undef STATE_TAG_LANGUAGE_ko +#undef STATE_TAG_LANGUAGE_k +#undef STATE_TAG_LANGUAGE_ja +#undef STATE_TAG_LANGUAGE_j +#undef STATE_TAG_LANGUAGE +#undef STATE_TAG_NONE +#undef STATE_G2_ISO8859_7 +#undef STATE_G2_ISO8859_1 +#undef STATE_G2_NONE +#undef STATE_KSC5601 +#undef STATE_GB2312 +#undef STATE_JISX0212 +#undef STATE_JISX0208 +#undef STATE_JISX0201KATAKANA +#undef STATE_JISX0201ROMAN +#undef STATE_ASCII diff --git a/graf2d/win32gdk/gdk/src/iconv/iso2022_jp3.h b/graf2d/win32gdk/gdk/src/iconv/iso2022_jp3.h new file mode 100644 index 0000000000000..58cea1bb34827 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso2022_jp3.h @@ -0,0 +1,538 @@ +/* + * Copyright (C) 1999-2004, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-2022-JP-3 + */ + +#include "jisx0213.h" + +#define ESC 0x1b + +/* + * The state is composed of one of the following values + */ +#define STATE_ASCII 0 /* Esc ( B */ +#define STATE_JISX0201ROMAN 1 /* Esc ( J */ +#define STATE_JISX0201KATAKANA 2 /* Esc ( I */ +#define STATE_JISX0208 3 /* Esc $ @ or Esc $ B */ +#define STATE_JISX02131 4 /* Esc $ ( O or Esc $ ( Q*/ +#define STATE_JISX02132 5 /* Esc $ ( P */ + +/* + * In the ISO-2022-JP-3 to UCS-4 direction, the state also holds the last + * character to be output, shifted by 3 bits. + */ + +static int +iso2022_jp3_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + ucs4_t last_wc = conv->istate >> 3; + if (last_wc) { + /* Output the buffered character. */ + conv->istate &= 7; + *pwc = last_wc; + return 0; /* Don't advance the input pointer. */ + } else { + state_t state = conv->istate; + int count = 0; + unsigned char c; + for (;;) { + c = *s; + if (c == ESC) { + if (n < count+3) + goto none; + if (s[1] == '(') { + if (s[2] == 'B') { + state = STATE_ASCII; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + if (s[2] == 'J') { + state = STATE_JISX0201ROMAN; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + if (s[2] == 'I') { + state = STATE_JISX0201KATAKANA; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + goto ilseq; + } + if (s[1] == '$') { + if (s[2] == '@' || s[2] == 'B') { + /* We don't distinguish JIS X 0208-1978 and JIS X 0208-1983. */ + state = STATE_JISX0208; + s += 3; count += 3; + if (n < count+1) + goto none; + continue; + } + if (s[2] == '(') { + if (n < count+4) + goto none; + if (s[3] == 'O' || s[3] == 'Q') { + state = STATE_JISX02131; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + if (s[3] == 'P') { + state = STATE_JISX02132; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + } + goto ilseq; + } + goto ilseq; + } + break; + } + switch (state) { + case STATE_ASCII: + if (c < 0x80) { + int ret = ascii_mbtowc(conv,pwc,s,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_JISX0201ROMAN: + if (c < 0x80) { + int ret = jisx0201_mbtowc(conv,pwc,s,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_JISX0201KATAKANA: + if (c < 0x80) { + unsigned char buf = c+0x80; + int ret = jisx0201_mbtowc(conv,pwc,&buf,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_JISX0208: + if (n < count+2) + goto none; + if (s[0] < 0x80 && s[1] < 0x80) { + int ret = jisx0208_mbtowc(conv,pwc,s,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + conv->istate = state; + return count+2; + } else + goto ilseq; + case STATE_JISX02131: + case STATE_JISX02132: + if (n < count+2) + goto none; + if (s[0] < 0x80 && s[1] < 0x80) { + ucs4_t wc = jisx0213_to_ucs4(((state-STATE_JISX02131+1)<<8)+s[0],s[1]); + if (wc) { + if (wc < 0x80) { + /* It's a combining character. */ + ucs4_t wc1 = jisx0213_to_ucs_combining[wc - 1][0]; + ucs4_t wc2 = jisx0213_to_ucs_combining[wc - 1][1]; + /* We cannot output two Unicode characters at once. So, + output the first character and buffer the second one. */ + *pwc = wc1; + conv->istate = (wc2 << 3) | state; + } else { + *pwc = wc; + conv->istate = state; + } + return count+2; + } + } + goto ilseq; + default: abort(); + } + none: + conv->istate = state; + return RET_TOOFEW(count); + + ilseq: + conv->istate = state; + return RET_SHIFT_ILSEQ(count); + } +} + +static int +iso2022_jp3_flushwc (conv_t conv, ucs4_t *pwc) +{ + ucs4_t last_wc = conv->istate >> 3; + if (last_wc) { + /* Output the buffered character. */ + conv->istate &= 7; + *pwc = last_wc; + return 1; + } else + return 0; +} + +/* + * In the UCS-4 to ISO-2022-JP-3 direction, the state also holds the last two + * bytes to be output, shifted by 3 bits, and the STATE_xxxxx value that was + * effective before this buffered character, shifted by 19 bits. + */ + +/* Composition tables for each of the relevant combining characters. */ +static const struct { unsigned short base; unsigned short composed; } iso2022_jp3_comp_table_data[] = { +#define iso2022_jp3_comp_table02e5_idx 0 +#define iso2022_jp3_comp_table02e5_len 1 + { 0x2b64, 0x2b65 }, /* 0x12B65 = 0x12B64 U+02E5 */ +#define iso2022_jp3_comp_table02e9_idx (iso2022_jp3_comp_table02e5_idx+iso2022_jp3_comp_table02e5_len) +#define iso2022_jp3_comp_table02e9_len 1 + { 0x2b60, 0x2b66 }, /* 0x12B66 = 0x12B60 U+02E9 */ +#define iso2022_jp3_comp_table0300_idx (iso2022_jp3_comp_table02e9_idx+iso2022_jp3_comp_table02e9_len) +#define iso2022_jp3_comp_table0300_len 5 + { 0x295c, 0x2b44 }, /* 0x12B44 = 0x1295C U+0300 */ + { 0x2b38, 0x2b48 }, /* 0x12B48 = 0x12B38 U+0300 */ + { 0x2b37, 0x2b4a }, /* 0x12B4A = 0x12B37 U+0300 */ + { 0x2b30, 0x2b4c }, /* 0x12B4C = 0x12B30 U+0300 */ + { 0x2b43, 0x2b4e }, /* 0x12B4E = 0x12B43 U+0300 */ +#define iso2022_jp3_comp_table0301_idx (iso2022_jp3_comp_table0300_idx+iso2022_jp3_comp_table0300_len) +#define iso2022_jp3_comp_table0301_len 4 + { 0x2b38, 0x2b49 }, /* 0x12B49 = 0x12B38 U+0301 */ + { 0x2b37, 0x2b4b }, /* 0x12B4B = 0x12B37 U+0301 */ + { 0x2b30, 0x2b4d }, /* 0x12B4D = 0x12B30 U+0301 */ + { 0x2b43, 0x2b4f }, /* 0x12B4F = 0x12B43 U+0301 */ +#define iso2022_jp3_comp_table309a_idx (iso2022_jp3_comp_table0301_idx+iso2022_jp3_comp_table0301_len) +#define iso2022_jp3_comp_table309a_len 14 + { 0x242b, 0x2477 }, /* 0x12477 = 0x1242B U+309A */ + { 0x242d, 0x2478 }, /* 0x12478 = 0x1242D U+309A */ + { 0x242f, 0x2479 }, /* 0x12479 = 0x1242F U+309A */ + { 0x2431, 0x247a }, /* 0x1247A = 0x12431 U+309A */ + { 0x2433, 0x247b }, /* 0x1247B = 0x12433 U+309A */ + { 0x252b, 0x2577 }, /* 0x12577 = 0x1252B U+309A */ + { 0x252d, 0x2578 }, /* 0x12578 = 0x1252D U+309A */ + { 0x252f, 0x2579 }, /* 0x12579 = 0x1252F U+309A */ + { 0x2531, 0x257a }, /* 0x1257A = 0x12531 U+309A */ + { 0x2533, 0x257b }, /* 0x1257B = 0x12533 U+309A */ + { 0x253b, 0x257c }, /* 0x1257C = 0x1253B U+309A */ + { 0x2544, 0x257d }, /* 0x1257D = 0x12544 U+309A */ + { 0x2548, 0x257e }, /* 0x1257E = 0x12548 U+309A */ + { 0x2675, 0x2678 }, /* 0x12678 = 0x12675 U+309A */ +}; + +#define SPLIT_STATE \ + unsigned short lasttwo = state >> 3; state_t prevstate = state >> 19; state &= 7 +#define COMBINE_STATE \ + state |= (prevstate << 19) | (lasttwo << 3) +#define COMBINE_STATE_NO_LASTTWO \ + /* assume lasttwo == 0, then prevstate is ignored */ + +static int +iso2022_jp3_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + int count = 0; + unsigned char buf[2]; + unsigned short jch; + int ret; + state_t state = conv->ostate; + SPLIT_STATE; + + if (lasttwo) { + /* Attempt to combine the last character with this one. */ + unsigned int idx; + unsigned int len; + + if (wc == 0x02e5) + idx = iso2022_jp3_comp_table02e5_idx, + len = iso2022_jp3_comp_table02e5_len; + else if (wc == 0x02e9) + idx = iso2022_jp3_comp_table02e9_idx, + len = iso2022_jp3_comp_table02e9_len; + else if (wc == 0x0300) + idx = iso2022_jp3_comp_table0300_idx, + len = iso2022_jp3_comp_table0300_len; + else if (wc == 0x0301) + idx = iso2022_jp3_comp_table0301_idx, + len = iso2022_jp3_comp_table0301_len; + else if (wc == 0x309a) + idx = iso2022_jp3_comp_table309a_idx, + len = iso2022_jp3_comp_table309a_len; + else + goto not_combining; + + do + if (iso2022_jp3_comp_table_data[idx].base == lasttwo) + break; + while (++idx, --len > 0); + + if (len > 0) { + /* Output the combined character. */ + /* We know the combined character is in JISX0213 plane 1, but + the buffered character may have been in JISX0208 or in + JISX0213 plane 1. */ + count = (state != STATE_JISX02131 ? 4 : 0) + 2; + if (n < count) + return RET_TOOSMALL; + if (state != STATE_JISX02131) { + r[0] = ESC; + r[1] = '$'; + r[2] = '('; + r[3] = 'Q'; + r += 4; + state = STATE_JISX02131; + } + lasttwo = iso2022_jp3_comp_table_data[idx].composed; + r[0] = (lasttwo >> 8) & 0xff; + r[1] = lasttwo & 0xff; + COMBINE_STATE_NO_LASTTWO; + conv->ostate = state; + return count; + } + + not_combining: + /* Output the buffered character. */ + /* We know it is in JISX0208 or in JISX0213 plane 1. */ + count = (prevstate != state ? 3 : 0) + 2; + if (n < count) + return RET_TOOSMALL; + if (prevstate != state) { + if (state != STATE_JISX0208) abort(); + r[0] = ESC; + r[1] = '$'; + r[2] = 'B'; + r += 3; + } + r[0] = (lasttwo >> 8) & 0xff; + r[1] = lasttwo & 0xff; + r += 2; + } + + /* Try ASCII. */ + ret = ascii_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] < 0x80) { + count += (state == STATE_ASCII ? 1 : 4); + if (n < count) + return RET_TOOSMALL; + if (state != STATE_ASCII) { + r[0] = ESC; + r[1] = '('; + r[2] = 'B'; + r += 3; + state = STATE_ASCII; + } + r[0] = buf[0]; + COMBINE_STATE_NO_LASTTWO; + conv->ostate = state; + return count; + } + } + + /* Try JIS X 0201-1976 Roman. */ + ret = jisx0201_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] < 0x80) { + count += (state == STATE_JISX0201ROMAN ? 1 : 4); + if (n < count) + return RET_TOOSMALL; + if (state != STATE_JISX0201ROMAN) { + r[0] = ESC; + r[1] = '('; + r[2] = 'J'; + r += 3; + state = STATE_JISX0201ROMAN; + } + r[0] = buf[0]; + COMBINE_STATE_NO_LASTTWO; + conv->ostate = state; + return count; + } + } + + jch = ucs4_to_jisx0213(wc); + + /* Try JIS X 0208-1990 in place of JIS X 0208-1978 and JIS X 0208-1983. */ + ret = jisx0208_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + if (jch & 0x0080) { + /* A possible match in comp_table_data. Buffer it. */ + prevstate = state; + lasttwo = jch & 0x7f7f; + state = STATE_JISX0208; + COMBINE_STATE; + conv->ostate = state; + return count; + } else { + count += (state == STATE_JISX0208 ? 2 : 5); + if (n < count) + return RET_TOOSMALL; + if (state != STATE_JISX0208) { + r[0] = ESC; + r[1] = '$'; + r[2] = 'B'; + r += 3; + state = STATE_JISX0208; + } + r[0] = buf[0]; + r[1] = buf[1]; + COMBINE_STATE_NO_LASTTWO; + conv->ostate = state; + return count; + } + } + } + + /* Try JISX 0213 plane 1 and JISX 0213 plane 2. */ + if (jch != 0) { + if (jch & 0x8000) { + /* JISX 0213 plane 2. */ + if (state != STATE_JISX02132) { + count += 4; + if (n < count) + return RET_TOOSMALL; + r[0] = ESC; + r[1] = '$'; + r[2] = '('; + r[3] = 'P'; + r += 4; + state = STATE_JISX02132; + } + } else { + /* JISX 0213 plane 1. */ + if (state != STATE_JISX02131) { + count += 4; + if (n < count) + return RET_TOOSMALL; + r[0] = ESC; + r[1] = '$'; + r[2] = '('; + r[3] = 'Q'; + r += 4; + state = STATE_JISX02131; + } + } + if (jch & 0x0080) { + /* A possible match in comp_table_data. We have to buffer it. */ + /* We know it's a JISX 0213 plane 1 character. */ + if (jch & 0x8000) abort(); + prevstate = state; + lasttwo = jch & 0x7f7f; + COMBINE_STATE; + conv->ostate = state; + return count; + } + count += 2; + if (n < count) + return RET_TOOSMALL; + r[0] = (jch >> 8) & 0x7f; + r[1] = jch & 0x7f; + COMBINE_STATE_NO_LASTTWO; + conv->ostate = state; + return count; + } + + /* Try JIS X 0201-1976 Katakana. This is not officially part of + ISO-2022-JP-3. Therefore we try it after all other attempts. */ + ret = jisx0201_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] >= 0x80) { + count += (state == STATE_JISX0201KATAKANA ? 1 : 4); + if (n < count) + return RET_TOOSMALL; + if (state != STATE_JISX0201KATAKANA) { + r[0] = ESC; + r[1] = '('; + r[2] = 'I'; + r += 3; + state = STATE_JISX0201KATAKANA; + } + r[0] = buf[0]-0x80; + COMBINE_STATE_NO_LASTTWO; + conv->ostate = state; + return count; + } + } + + return RET_ILUNI; +} + +static int +iso2022_jp3_reset (conv_t conv, unsigned char *r, int n) +{ + state_t state = conv->ostate; + SPLIT_STATE; + { + int count = + (lasttwo ? (prevstate != state ? 3 : 0) + 2 : 0) + + (state != STATE_ASCII ? 3 : 0); + if (n < count) + return RET_TOOSMALL; + if (lasttwo) { + if (prevstate != state) { + if (state != STATE_JISX0208) abort(); + r[0] = ESC; + r[1] = '$'; + r[2] = 'B'; + r += 3; + } + r[0] = (lasttwo >> 8) & 0xff; + r[1] = lasttwo & 0xff; + r += 2; + } + if (state != STATE_ASCII) { + r[0] = ESC; + r[1] = '('; + r[2] = 'B'; + } + /* conv->ostate = 0; will be done by the caller */ + return count; + } +} + +#undef COMBINE_STATE_NO_LASTTWO +#undef COMBINE_STATE +#undef SPLIT_STATE +#undef STATE_JISX02132 +#undef STATE_JISX02131 +#undef STATE_JISX0208 +#undef STATE_JISX0201KATAKANA +#undef STATE_JISX0201ROMAN +#undef STATE_ASCII diff --git a/graf2d/win32gdk/gdk/src/iconv/iso2022_kr.h b/graf2d/win32gdk/gdk/src/iconv/iso2022_kr.h new file mode 100644 index 0000000000000..8045d4e5e1018 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso2022_kr.h @@ -0,0 +1,222 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-2022-KR + */ + +/* Specification: RFC 1557 */ + +/* Note: CJK.INF says the SO designator needs to appear only once at the + beginning of a text, but to decrease the risk of ambiguities, when + producing ISO-2022-KR, we repeat the designator in every line containing + SO characters. RFC 1557 does not mandate this. */ + +#define ESC 0x1b +#define SO 0x0e +#define SI 0x0f + +/* + * The state is composed of one of the following values + */ +#define STATE_ASCII 0 +#define STATE_TWOBYTE 1 +/* + * and one of the following values, << 8 + */ +#define STATE2_NONE 0 +#define STATE2_DESIGNATED_KSC5601 1 + +#define SPLIT_STATE \ + unsigned int state1 = state & 0xff, state2 = state >> 8 +#define COMBINE_STATE \ + state = (state2 << 8) | state1 + +static int +iso2022_kr_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + state_t state = conv->istate; + SPLIT_STATE; + int count = 0; + unsigned char c; + for (;;) { + c = *s; + if (c == ESC) { + if (n < count+4) + goto none; + if (s[1] == '$') { + if (s[2] == ')') { + if (s[3] == 'C') { + state2 = STATE2_DESIGNATED_KSC5601; + s += 4; count += 4; + if (n < count+1) + goto none; + continue; + } + } + } + goto ilseq; + } + if (c == SO) { + if (state2 != STATE2_DESIGNATED_KSC5601) + goto ilseq; + state1 = STATE_TWOBYTE; + s++; count++; + if (n < count+1) + goto none; + continue; + } + if (c == SI) { + state1 = STATE_ASCII; + s++; count++; + if (n < count+1) + goto none; + continue; + } + break; + } + switch (state1) { + case STATE_ASCII: + if (c < 0x80) { + int ret = ascii_mbtowc(conv,pwc,s,1); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 1) abort(); +#if 0 /* Accept ISO-2022-KR according to CJK.INF. */ + if (*pwc == 0x000a || *pwc == 0x000d) + state2 = STATE2_NONE; +#endif + COMBINE_STATE; + conv->istate = state; + return count+1; + } else + goto ilseq; + case STATE_TWOBYTE: + if (n < count+2) + goto none; + if (state2 != STATE2_DESIGNATED_KSC5601) abort(); + if (s[0] < 0x80 && s[1] < 0x80) { + int ret = ksc5601_mbtowc(conv,pwc,s,2); + if (ret == RET_ILSEQ) + goto ilseq; + if (ret != 2) abort(); + COMBINE_STATE; + conv->istate = state; + return count+2; + } else + goto ilseq; + default: abort(); + } + +none: + COMBINE_STATE; + conv->istate = state; + return RET_TOOFEW(count); + +ilseq: + COMBINE_STATE; + conv->istate = state; + return RET_SHIFT_ILSEQ(count); +} + +static int +iso2022_kr_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + state_t state = conv->ostate; + SPLIT_STATE; + unsigned char buf[2]; + int ret; + + /* Try ASCII. */ + ret = ascii_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] < 0x80) { + int count = (state1 == STATE_ASCII ? 1 : 2); + if (n < count) + return RET_TOOSMALL; + if (state1 != STATE_ASCII) { + r[0] = SI; + r += 1; + state1 = STATE_ASCII; + } + r[0] = buf[0]; + if (wc == 0x000a || wc == 0x000d) + state2 = STATE2_NONE; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + /* Try KS C 5601-1992. */ + ret = ksc5601_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (buf[0] < 0x80 && buf[1] < 0x80) { + int count = (state2 == STATE2_DESIGNATED_KSC5601 ? 0 : 4) + (state1 == STATE_TWOBYTE ? 0 : 1) + 2; + if (n < count) + return RET_TOOSMALL; + if (state2 != STATE2_DESIGNATED_KSC5601) { + r[0] = ESC; + r[1] = '$'; + r[2] = ')'; + r[3] = 'C'; + r += 4; + state2 = STATE2_DESIGNATED_KSC5601; + } + if (state1 != STATE_TWOBYTE) { + r[0] = SO; + r += 1; + state1 = STATE_TWOBYTE; + } + r[0] = buf[0]; + r[1] = buf[1]; + COMBINE_STATE; + conv->ostate = state; + return count; + } + } + + return RET_ILUNI; +} + +static int +iso2022_kr_reset (conv_t conv, unsigned char *r, int n) +{ + state_t state = conv->ostate; + SPLIT_STATE; + (void)state2; + if (state1 != STATE_ASCII) { + if (n < 1) + return RET_TOOSMALL; + r[0] = SI; + /* conv->ostate = 0; will be done by the caller */ + return 1; + } else + return 0; +} + +#undef COMBINE_STATE +#undef SPLIT_STATE +#undef STATE2_DESIGNATED_KSC5601 +#undef STATE2_NONE +#undef STATE_TWOBYTE +#undef STATE_ASCII diff --git a/graf2d/win32gdk/gdk/src/iconv/iso646_cn.h b/graf2d/win32gdk/gdk/src/iconv/iso646_cn.h new file mode 100644 index 0000000000000..a571ce713aca5 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso646_cn.h @@ -0,0 +1,58 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO646-CN + * also known as GB_1988-80 + */ + +static int +iso646_cn_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + if (c == 0x24) + *pwc = (ucs4_t) 0x00a5; + else if (c == 0x7e) + *pwc = (ucs4_t) 0x203e; + else + *pwc = (ucs4_t) c; + return 1; + } + return RET_ILSEQ; +} + +static int +iso646_cn_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x0080 && !(wc == 0x0024 || wc == 0x007e)) { + *r = wc; + return 1; + } + if (wc == 0x00a5) { + *r = 0x24; + return 1; + } + if (wc == 0x203e) { + *r = 0x7e; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso646_jp.h b/graf2d/win32gdk/gdk/src/iconv/iso646_jp.h new file mode 100644 index 0000000000000..7cc3abd040e22 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso646_jp.h @@ -0,0 +1,60 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO646-JP + * also known as JIS_C6220-1969-RO + */ + +/* This is the lower half of JIS_X0201. */ + +static int +iso646_jp_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + if (c == 0x5c) + *pwc = (ucs4_t) 0x00a5; + else if (c == 0x7e) + *pwc = (ucs4_t) 0x203e; + else + *pwc = (ucs4_t) c; + return 1; + } + return RET_ILSEQ; +} + +static int +iso646_jp_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x0080 && !(wc == 0x005c || wc == 0x007e)) { + *r = wc; + return 1; + } + if (wc == 0x00a5) { + *r = 0x5c; + return 1; + } + if (wc == 0x203e) { + *r = 0x7e; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_1.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_1.h new file mode 100644 index 0000000000000..53469164b17d5 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_1.h @@ -0,0 +1,41 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-1 + */ + +static int +iso8859_1_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + *pwc = (ucs4_t) c; + return 1; +} + +static int +iso8859_1_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x0100) { + *r = wc; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_10.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_10.h new file mode 100644 index 0000000000000..49b3f6ad3d53d --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_10.h @@ -0,0 +1,106 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-10 + */ + +static const unsigned short iso8859_10_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x0104, 0x0112, 0x0122, 0x012a, 0x0128, 0x0136, 0x00a7, + 0x013b, 0x0110, 0x0160, 0x0166, 0x017d, 0x00ad, 0x016a, 0x014a, + /* 0xb0 */ + 0x00b0, 0x0105, 0x0113, 0x0123, 0x012b, 0x0129, 0x0137, 0x00b7, + 0x013c, 0x0111, 0x0161, 0x0167, 0x017e, 0x2015, 0x016b, 0x014b, + /* 0xc0 */ + 0x0100, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x012e, + 0x010c, 0x00c9, 0x0118, 0x00cb, 0x0116, 0x00cd, 0x00ce, 0x00cf, + /* 0xd0 */ + 0x00d0, 0x0145, 0x014c, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x0168, + 0x00d8, 0x0172, 0x00da, 0x00db, 0x00dc, 0x00dd, 0x00de, 0x00df, + /* 0xe0 */ + 0x0101, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x012f, + 0x010d, 0x00e9, 0x0119, 0x00eb, 0x0117, 0x00ed, 0x00ee, 0x00ef, + /* 0xf0 */ + 0x00f0, 0x0146, 0x014d, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x0169, + 0x00f8, 0x0173, 0x00fa, 0x00fb, 0x00fc, 0x00fd, 0x00fe, 0x0138, +}; + +static int +iso8859_10_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) iso8859_10_2uni[c-0xa0]; + return 1; +} + +static const unsigned char iso8859_10_page00[224] = { + 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa7, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xad, 0x00, 0x00, /* 0xa8-0xaf */ + 0xb0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb7, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0x00, /* 0xc0-0xc7 */ + 0x00, 0xc9, 0x00, 0xcb, 0x00, 0xcd, 0xce, 0xcf, /* 0xc8-0xcf */ + 0xd0, 0x00, 0x00, 0xd3, 0xd4, 0xd5, 0xd6, 0x00, /* 0xd0-0xd7 */ + 0xd8, 0x00, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xdf, /* 0xd8-0xdf */ + 0x00, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0x00, /* 0xe0-0xe7 */ + 0x00, 0xe9, 0x00, 0xeb, 0x00, 0xed, 0xee, 0xef, /* 0xe8-0xef */ + 0xf0, 0x00, 0x00, 0xf3, 0xf4, 0xf5, 0xf6, 0x00, /* 0xf0-0xf7 */ + 0xf8, 0x00, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0x00, /* 0xf8-0xff */ + /* 0x0100 */ + 0xc0, 0xe0, 0x00, 0x00, 0xa1, 0xb1, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xc8, 0xe8, 0x00, 0x00, /* 0x08-0x0f */ + 0xa9, 0xb9, 0xa2, 0xb2, 0x00, 0x00, 0xcc, 0xec, /* 0x10-0x17 */ + 0xca, 0xea, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0xa3, 0xb3, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0xa5, 0xb5, 0xa4, 0xb4, 0x00, 0x00, 0xc7, 0xe7, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa6, 0xb6, /* 0x30-0x37 */ + 0xff, 0x00, 0x00, 0xa8, 0xb8, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xd1, 0xf1, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0xaf, 0xbf, 0xd2, 0xf2, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xaa, 0xba, 0x00, 0x00, 0x00, 0x00, 0xab, 0xbb, /* 0x60-0x67 */ + 0xd7, 0xf7, 0xae, 0xbe, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0xd9, 0xf9, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xac, 0xbc, 0x00, /* 0x78-0x7f */ +}; + +static int +iso8859_10_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0180) + c = iso8859_10_page00[wc-0x00a0]; + else if (wc == 0x2015) + c = 0xbd; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_11.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_11.h new file mode 100644 index 0000000000000..ef8b1a66c551e --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_11.h @@ -0,0 +1,52 @@ +/* + * Copyright (C) 1999-2004 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-11 + */ + +static int +iso8859_11_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa1) { + *pwc = (ucs4_t) c; + return 1; + } + else if (c <= 0xfb && !(c >= 0xdb && c <= 0xde)) { + *pwc = (ucs4_t) (c + 0x0d60); + return 1; + } + return RET_ILSEQ; +} + +static int +iso8859_11_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x00a1) { + *r = wc; + return 1; + } + else if (wc >= 0x0e01 && wc <= 0x0e5b && !(wc >= 0x0e3b && wc <= 0x0e3e)) { + *r = wc-0x0d60; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_13.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_13.h new file mode 100644 index 0000000000000..2fadc7b8b41f7 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_13.h @@ -0,0 +1,109 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-13 + */ + +static const unsigned short iso8859_13_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x201d, 0x00a2, 0x00a3, 0x00a4, 0x201e, 0x00a6, 0x00a7, + 0x00d8, 0x00a9, 0x0156, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00c6, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x201c, 0x00b5, 0x00b6, 0x00b7, + 0x00f8, 0x00b9, 0x0157, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00e6, + /* 0xc0 */ + 0x0104, 0x012e, 0x0100, 0x0106, 0x00c4, 0x00c5, 0x0118, 0x0112, + 0x010c, 0x00c9, 0x0179, 0x0116, 0x0122, 0x0136, 0x012a, 0x013b, + /* 0xd0 */ + 0x0160, 0x0143, 0x0145, 0x00d3, 0x014c, 0x00d5, 0x00d6, 0x00d7, + 0x0172, 0x0141, 0x015a, 0x016a, 0x00dc, 0x017b, 0x017d, 0x00df, + /* 0xe0 */ + 0x0105, 0x012f, 0x0101, 0x0107, 0x00e4, 0x00e5, 0x0119, 0x0113, + 0x010d, 0x00e9, 0x017a, 0x0117, 0x0123, 0x0137, 0x012b, 0x013c, + /* 0xf0 */ + 0x0161, 0x0144, 0x0146, 0x00f3, 0x014d, 0x00f5, 0x00f6, 0x00f7, + 0x0173, 0x0142, 0x015b, 0x016b, 0x00fc, 0x017c, 0x017e, 0x2019, +}; + +static int +iso8859_13_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) iso8859_13_2uni[c-0xa0]; + return 1; +} + +static const unsigned char iso8859_13_page00[224] = { + 0xa0, 0x00, 0xa2, 0xa3, 0xa4, 0x00, 0xa6, 0xa7, /* 0xa0-0xa7 */ + 0x00, 0xa9, 0x00, 0xab, 0xac, 0xad, 0xae, 0x00, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0xb2, 0xb3, 0x00, 0xb5, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0x00, 0xb9, 0x00, 0xbb, 0xbc, 0xbd, 0xbe, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0xc4, 0xc5, 0xaf, 0x00, /* 0xc0-0xc7 */ + 0x00, 0xc9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0xd3, 0x00, 0xd5, 0xd6, 0xd7, /* 0xd0-0xd7 */ + 0xa8, 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0xdf, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0xe4, 0xe5, 0xbf, 0x00, /* 0xe0-0xe7 */ + 0x00, 0xe9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0xf3, 0x00, 0xf5, 0xf6, 0xf7, /* 0xf0-0xf7 */ + 0xb8, 0x00, 0x00, 0x00, 0xfc, 0x00, 0x00, 0x00, /* 0xf8-0xff */ + /* 0x0100 */ + 0xc2, 0xe2, 0x00, 0x00, 0xc0, 0xe0, 0xc3, 0xe3, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xc8, 0xe8, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0xc7, 0xe7, 0x00, 0x00, 0xcb, 0xeb, /* 0x10-0x17 */ + 0xc6, 0xe6, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0xcc, 0xec, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0xce, 0xee, 0x00, 0x00, 0xc1, 0xe1, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xcd, 0xed, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0xcf, 0xef, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0xd9, 0xf9, 0xd1, 0xf1, 0xd2, 0xf2, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0xd4, 0xf4, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xaa, 0xba, /* 0x50-0x57 */ + 0x00, 0x00, 0xda, 0xfa, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xd0, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0xdb, 0xfb, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0xd8, 0xf8, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0xca, 0xea, 0xdd, 0xfd, 0xde, 0xfe, 0x00, /* 0x78-0x7f */ +}; +static const unsigned char iso8859_13_page20[8] = { + 0x00, 0xff, 0x00, 0x00, 0xb4, 0xa1, 0xa5, 0x00, /* 0x18-0x1f */ +}; + +static int +iso8859_13_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0180) + c = iso8859_13_page00[wc-0x00a0]; + else if (wc >= 0x2018 && wc < 0x2020) + c = iso8859_13_page20[wc-0x2018]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_14.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_14.h new file mode 100644 index 0000000000000..01c9cdd950941 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_14.h @@ -0,0 +1,127 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-14 + */ + +static const unsigned short iso8859_14_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x1e02, 0x1e03, 0x00a3, 0x010a, 0x010b, 0x1e0a, 0x00a7, + 0x1e80, 0x00a9, 0x1e82, 0x1e0b, 0x1ef2, 0x00ad, 0x00ae, 0x0178, + /* 0xb0 */ + 0x1e1e, 0x1e1f, 0x0120, 0x0121, 0x1e40, 0x1e41, 0x00b6, 0x1e56, + 0x1e81, 0x1e57, 0x1e83, 0x1e60, 0x1ef3, 0x1e84, 0x1e85, 0x1e61, + /* 0xc0 */ + 0x00c0, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x00c7, + 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, + /* 0xd0 */ + 0x0174, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x1e6a, + 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x00dd, 0x0176, 0x00df, + /* 0xe0 */ + 0x00e0, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x00e7, + 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, + /* 0xf0 */ + 0x0175, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x1e6b, + 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x00fd, 0x0177, 0x00ff, +}; + +static int +iso8859_14_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c >= 0xa0) + *pwc = (ucs4_t) iso8859_14_2uni[c-0xa0]; + else + *pwc = (ucs4_t) c; + return 1; +} + +static const unsigned char iso8859_14_page00[96] = { + 0xa0, 0x00, 0x00, 0xa3, 0x00, 0x00, 0x00, 0xa7, /* 0xa0-0xa7 */ + 0x00, 0xa9, 0x00, 0x00, 0x00, 0xad, 0xae, 0x00, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb6, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0xc0-0xc7 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0xc8-0xcf */ + 0x00, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0x00, /* 0xd0-0xd7 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0x00, 0xdf, /* 0xd8-0xdf */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0xe0-0xe7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0xe8-0xef */ + 0x00, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0x00, /* 0xf0-0xf7 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0x00, 0xff, /* 0xf8-0xff */ +}; +static const unsigned char iso8859_14_page01_0[32] = { + 0x00, 0x00, 0xa4, 0xa5, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0xb2, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char iso8859_14_page01_1[16] = { + 0x00, 0x00, 0x00, 0x00, 0xd0, 0xf0, 0xde, 0xfe, /* 0x70-0x77 */ + 0xaf, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ +}; +static const unsigned char iso8859_14_page1e_0[136] = { + 0x00, 0x00, 0xa1, 0xa2, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0xa6, 0xab, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb0, 0xb1, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0xb4, 0xb5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb7, 0xb9, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xbb, 0xbf, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0xd7, 0xf7, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0xa8, 0xb8, 0xaa, 0xba, 0xbd, 0xbe, 0x00, 0x00, /* 0x80-0x87 */ +}; +static const unsigned char iso8859_14_page1e_1[8] = { + 0x00, 0x00, 0xac, 0xbc, 0x00, 0x00, 0x00, 0x00, /* 0xf0-0xf7 */ +}; + +static int +iso8859_14_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = iso8859_14_page00[wc-0x00a0]; + else if (wc >= 0x0108 && wc < 0x0128) + c = iso8859_14_page01_0[wc-0x0108]; + else if (wc >= 0x0170 && wc < 0x0180) + c = iso8859_14_page01_1[wc-0x0170]; + else if (wc >= 0x1e00 && wc < 0x1e88) + c = iso8859_14_page1e_0[wc-0x1e00]; + else if (wc >= 0x1ef0 && wc < 0x1ef8) + c = iso8859_14_page1e_1[wc-0x1ef0]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_15.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_15.h new file mode 100644 index 0000000000000..24de90d7d31fe --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_15.h @@ -0,0 +1,81 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-15 + */ + +static const unsigned short iso8859_15_2uni[32] = { + /* 0xa0 */ + 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x20ac, 0x00a5, 0x0160, 0x00a7, + 0x0161, 0x00a9, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x017d, 0x00b5, 0x00b6, 0x00b7, + 0x017e, 0x00b9, 0x00ba, 0x00bb, 0x0152, 0x0153, 0x0178, 0x00bf, +}; + +static int +iso8859_15_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c >= 0xa0 && c < 0xc0) + *pwc = (ucs4_t) iso8859_15_2uni[c-0xa0]; + else + *pwc = (ucs4_t) c; + return 1; +} + +static const unsigned char iso8859_15_page00[32] = { + 0xa0, 0xa1, 0xa2, 0xa3, 0x00, 0xa5, 0x00, 0xa7, /* 0xa0-0xa7 */ + 0x00, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0xb2, 0xb3, 0x00, 0xb5, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0x00, 0xb9, 0xba, 0xbb, 0x00, 0x00, 0x00, 0xbf, /* 0xb8-0xbf */ +}; +static const unsigned char iso8859_15_page01[48] = { + 0x00, 0x00, 0xbc, 0xbd, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xa6, 0xa8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0xbe, 0x00, 0x00, 0x00, 0x00, 0xb4, 0xb8, 0x00, /* 0x78-0x7f */ +}; + +static int +iso8859_15_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = iso8859_15_page00[wc-0x00a0]; + else if (wc >= 0x00c0 && wc < 0x0100) + c = wc; + else if (wc >= 0x0150 && wc < 0x0180) + c = iso8859_15_page01[wc-0x0150]; + else if (wc == 0x20ac) + c = 0xa4; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_16.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_16.h new file mode 100644 index 0000000000000..200471840f45a --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_16.h @@ -0,0 +1,116 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-16 + */ + +static const unsigned short iso8859_16_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x0104, 0x0105, 0x0141, 0x20ac, 0x201e, 0x0160, 0x00a7, + 0x0161, 0x00a9, 0x0218, 0x00ab, 0x0179, 0x00ad, 0x017a, 0x017b, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x010c, 0x0142, 0x017d, 0x201d, 0x00b6, 0x00b7, + 0x017e, 0x010d, 0x0219, 0x00bb, 0x0152, 0x0153, 0x0178, 0x017c, + /* 0xc0 */ + 0x00c0, 0x00c1, 0x00c2, 0x0102, 0x00c4, 0x0106, 0x00c6, 0x00c7, + 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, + /* 0xd0 */ + 0x0110, 0x0143, 0x00d2, 0x00d3, 0x00d4, 0x0150, 0x00d6, 0x015a, + 0x0170, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x0118, 0x021a, 0x00df, + /* 0xe0 */ + 0x00e0, 0x00e1, 0x00e2, 0x0103, 0x00e4, 0x0107, 0x00e6, 0x00e7, + 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, + /* 0xf0 */ + 0x0111, 0x0144, 0x00f2, 0x00f3, 0x00f4, 0x0151, 0x00f6, 0x015b, + 0x0171, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x0119, 0x021b, 0x00ff, +}; + +static int +iso8859_16_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) iso8859_16_2uni[c-0xa0]; + return 1; +} + +static const unsigned char iso8859_16_page00[224] = { + 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa7, /* 0xa0-0xa7 */ + 0x00, 0xa9, 0x00, 0xab, 0x00, 0xad, 0x00, 0x00, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0x00, 0x00, 0x00, 0x00, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xbb, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0xc0, 0xc1, 0xc2, 0x00, 0xc4, 0x00, 0xc6, 0xc7, /* 0xc0-0xc7 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0xc8-0xcf */ + 0x00, 0x00, 0xd2, 0xd3, 0xd4, 0x00, 0xd6, 0x00, /* 0xd0-0xd7 */ + 0x00, 0xd9, 0xda, 0xdb, 0xdc, 0x00, 0x00, 0xdf, /* 0xd8-0xdf */ + 0xe0, 0xe1, 0xe2, 0x00, 0xe4, 0x00, 0xe6, 0xe7, /* 0xe0-0xe7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0xe8-0xef */ + 0x00, 0x00, 0xf2, 0xf3, 0xf4, 0x00, 0xf6, 0x00, /* 0xf0-0xf7 */ + 0x00, 0xf9, 0xfa, 0xfb, 0xfc, 0x00, 0x00, 0xff, /* 0xf8-0xff */ + /* 0x0100 */ + 0x00, 0x00, 0xc3, 0xe3, 0xa1, 0xa2, 0xc5, 0xe5, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xb2, 0xb9, 0x00, 0x00, /* 0x08-0x0f */ + 0xd0, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xdd, 0xfd, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0xa3, 0xb3, 0xd1, 0xf1, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xd5, 0xf5, 0xbc, 0xbd, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0xd7, 0xf7, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xa6, 0xa8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0xd8, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0xbe, 0xac, 0xae, 0xaf, 0xbf, 0xb4, 0xb8, 0x00, /* 0x78-0x7f */ +}; +static const unsigned char iso8859_16_page02[8] = { + 0xaa, 0xba, 0xde, 0xfe, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ +}; +static const unsigned char iso8859_16_page20[8] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0xb5, 0xa5, 0x00, /* 0x18-0x1f */ +}; + +static int +iso8859_16_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0180) + c = iso8859_16_page00[wc-0x00a0]; + else if (wc >= 0x0218 && wc < 0x0220) + c = iso8859_16_page02[wc-0x0218]; + else if (wc >= 0x2018 && wc < 0x2020) + c = iso8859_16_page20[wc-0x2018]; + else if (wc == 0x20ac) + c = 0xa4; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_2.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_2.h new file mode 100644 index 0000000000000..9ad4d4aa5deec --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_2.h @@ -0,0 +1,112 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-2 + */ + +static const unsigned short iso8859_2_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x0104, 0x02d8, 0x0141, 0x00a4, 0x013d, 0x015a, 0x00a7, + 0x00a8, 0x0160, 0x015e, 0x0164, 0x0179, 0x00ad, 0x017d, 0x017b, + /* 0xb0 */ + 0x00b0, 0x0105, 0x02db, 0x0142, 0x00b4, 0x013e, 0x015b, 0x02c7, + 0x00b8, 0x0161, 0x015f, 0x0165, 0x017a, 0x02dd, 0x017e, 0x017c, + /* 0xc0 */ + 0x0154, 0x00c1, 0x00c2, 0x0102, 0x00c4, 0x0139, 0x0106, 0x00c7, + 0x010c, 0x00c9, 0x0118, 0x00cb, 0x011a, 0x00cd, 0x00ce, 0x010e, + /* 0xd0 */ + 0x0110, 0x0143, 0x0147, 0x00d3, 0x00d4, 0x0150, 0x00d6, 0x00d7, + 0x0158, 0x016e, 0x00da, 0x0170, 0x00dc, 0x00dd, 0x0162, 0x00df, + /* 0xe0 */ + 0x0155, 0x00e1, 0x00e2, 0x0103, 0x00e4, 0x013a, 0x0107, 0x00e7, + 0x010d, 0x00e9, 0x0119, 0x00eb, 0x011b, 0x00ed, 0x00ee, 0x010f, + /* 0xf0 */ + 0x0111, 0x0144, 0x0148, 0x00f3, 0x00f4, 0x0151, 0x00f6, 0x00f7, + 0x0159, 0x016f, 0x00fa, 0x0171, 0x00fc, 0x00fd, 0x0163, 0x02d9, +}; + +static int +iso8859_2_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) iso8859_2_2uni[c-0xa0]; + return 1; +} + +static const unsigned char iso8859_2_page00[224] = { + 0xa0, 0x00, 0x00, 0x00, 0xa4, 0x00, 0x00, 0xa7, /* 0xa0-0xa7 */ + 0xa8, 0x00, 0x00, 0x00, 0x00, 0xad, 0x00, 0x00, /* 0xa8-0xaf */ + 0xb0, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0xb8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0xc1, 0xc2, 0x00, 0xc4, 0x00, 0x00, 0xc7, /* 0xc0-0xc7 */ + 0x00, 0xc9, 0x00, 0xcb, 0x00, 0xcd, 0xce, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0xd3, 0xd4, 0x00, 0xd6, 0xd7, /* 0xd0-0xd7 */ + 0x00, 0x00, 0xda, 0x00, 0xdc, 0xdd, 0x00, 0xdf, /* 0xd8-0xdf */ + 0x00, 0xe1, 0xe2, 0x00, 0xe4, 0x00, 0x00, 0xe7, /* 0xe0-0xe7 */ + 0x00, 0xe9, 0x00, 0xeb, 0x00, 0xed, 0xee, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0xf3, 0xf4, 0x00, 0xf6, 0xf7, /* 0xf0-0xf7 */ + 0x00, 0x00, 0xfa, 0x00, 0xfc, 0xfd, 0x00, 0x00, /* 0xf8-0xff */ + /* 0x0100 */ + 0x00, 0x00, 0xc3, 0xe3, 0xa1, 0xb1, 0xc6, 0xe6, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xc8, 0xe8, 0xcf, 0xef, /* 0x08-0x0f */ + 0xd0, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xca, 0xea, 0xcc, 0xec, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0xc5, 0xe5, 0x00, 0x00, 0xa5, 0xb5, 0x00, /* 0x38-0x3f */ + 0x00, 0xa3, 0xb3, 0xd1, 0xf1, 0x00, 0x00, 0xd2, /* 0x40-0x47 */ + 0xf2, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xd5, 0xf5, 0x00, 0x00, 0xc0, 0xe0, 0x00, 0x00, /* 0x50-0x57 */ + 0xd8, 0xf8, 0xa6, 0xb6, 0x00, 0x00, 0xaa, 0xba, /* 0x58-0x5f */ + 0xa9, 0xb9, 0xde, 0xfe, 0xab, 0xbb, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd9, 0xf9, /* 0x68-0x6f */ + 0xdb, 0xfb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0xac, 0xbc, 0xaf, 0xbf, 0xae, 0xbe, 0x00, /* 0x78-0x7f */ +}; +static const unsigned char iso8859_2_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb7, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0xa2, 0xff, 0x00, 0xb2, 0x00, 0xbd, 0x00, 0x00, /* 0xd8-0xdf */ +}; + +static int +iso8859_2_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0180) + c = iso8859_2_page00[wc-0x00a0]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = iso8859_2_page02[wc-0x02c0]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_3.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_3.h new file mode 100644 index 0000000000000..308e0b0d64936 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_3.h @@ -0,0 +1,118 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-3 + */ + +static const unsigned short iso8859_3_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x0126, 0x02d8, 0x00a3, 0x00a4, 0xfffd, 0x0124, 0x00a7, + 0x00a8, 0x0130, 0x015e, 0x011e, 0x0134, 0x00ad, 0xfffd, 0x017b, + /* 0xb0 */ + 0x00b0, 0x0127, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x0125, 0x00b7, + 0x00b8, 0x0131, 0x015f, 0x011f, 0x0135, 0x00bd, 0xfffd, 0x017c, + /* 0xc0 */ + 0x00c0, 0x00c1, 0x00c2, 0xfffd, 0x00c4, 0x010a, 0x0108, 0x00c7, + 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, + /* 0xd0 */ + 0xfffd, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x0120, 0x00d6, 0x00d7, + 0x011c, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x016c, 0x015c, 0x00df, + /* 0xe0 */ + 0x00e0, 0x00e1, 0x00e2, 0xfffd, 0x00e4, 0x010b, 0x0109, 0x00e7, + 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, + /* 0xf0 */ + 0xfffd, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x0121, 0x00f6, 0x00f7, + 0x011d, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x016d, 0x015d, 0x02d9, +}; + +static int +iso8859_3_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = iso8859_3_2uni[c-0xa0]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char iso8859_3_page00[96] = { + 0xa0, 0x00, 0x00, 0xa3, 0xa4, 0x00, 0x00, 0xa7, /* 0xa0-0xa7 */ + 0xa8, 0x00, 0x00, 0x00, 0x00, 0xad, 0x00, 0x00, /* 0xa8-0xaf */ + 0xb0, 0x00, 0xb2, 0xb3, 0xb4, 0xb5, 0x00, 0xb7, /* 0xb0-0xb7 */ + 0xb8, 0x00, 0x00, 0x00, 0x00, 0xbd, 0x00, 0x00, /* 0xb8-0xbf */ + 0xc0, 0xc1, 0xc2, 0x00, 0xc4, 0x00, 0x00, 0xc7, /* 0xc0-0xc7 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0xc8-0xcf */ + 0x00, 0xd1, 0xd2, 0xd3, 0xd4, 0x00, 0xd6, 0xd7, /* 0xd0-0xd7 */ + 0x00, 0xd9, 0xda, 0xdb, 0xdc, 0x00, 0x00, 0xdf, /* 0xd8-0xdf */ + 0xe0, 0xe1, 0xe2, 0x00, 0xe4, 0x00, 0x00, 0xe7, /* 0xe0-0xe7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0xe8-0xef */ + 0x00, 0xf1, 0xf2, 0xf3, 0xf4, 0x00, 0xf6, 0xf7, /* 0xf0-0xf7 */ + 0x00, 0xf9, 0xfa, 0xfb, 0xfc, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; +static const unsigned char iso8859_3_page01[120] = { + 0xc6, 0xe6, 0xc5, 0xe5, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0xd8, 0xf8, 0xab, 0xbb, /* 0x18-0x1f */ + 0xd5, 0xf5, 0x00, 0x00, 0xa6, 0xb6, 0xa1, 0xb1, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0xa9, 0xb9, 0x00, 0x00, 0xac, 0xbc, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0xde, 0xfe, 0xaa, 0xba, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0xdd, 0xfd, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0xaf, 0xbf, 0x00, 0x00, 0x00, /* 0x78-0x7f */ +}; +static const unsigned char iso8859_3_page02[8] = { + 0xa2, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ +}; + +static int +iso8859_3_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = iso8859_3_page00[wc-0x00a0]; + else if (wc >= 0x0108 && wc < 0x0180) + c = iso8859_3_page01[wc-0x0108]; + else if (wc >= 0x02d8 && wc < 0x02e0) + c = iso8859_3_page02[wc-0x02d8]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_4.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_4.h new file mode 100644 index 0000000000000..51e17786563e2 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_4.h @@ -0,0 +1,112 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-4 + */ + +static const unsigned short iso8859_4_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x0104, 0x0138, 0x0156, 0x00a4, 0x0128, 0x013b, 0x00a7, + 0x00a8, 0x0160, 0x0112, 0x0122, 0x0166, 0x00ad, 0x017d, 0x00af, + /* 0xb0 */ + 0x00b0, 0x0105, 0x02db, 0x0157, 0x00b4, 0x0129, 0x013c, 0x02c7, + 0x00b8, 0x0161, 0x0113, 0x0123, 0x0167, 0x014a, 0x017e, 0x014b, + /* 0xc0 */ + 0x0100, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x012e, + 0x010c, 0x00c9, 0x0118, 0x00cb, 0x0116, 0x00cd, 0x00ce, 0x012a, + /* 0xd0 */ + 0x0110, 0x0145, 0x014c, 0x0136, 0x00d4, 0x00d5, 0x00d6, 0x00d7, + 0x00d8, 0x0172, 0x00da, 0x00db, 0x00dc, 0x0168, 0x016a, 0x00df, + /* 0xe0 */ + 0x0101, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x012f, + 0x010d, 0x00e9, 0x0119, 0x00eb, 0x0117, 0x00ed, 0x00ee, 0x012b, + /* 0xf0 */ + 0x0111, 0x0146, 0x014d, 0x0137, 0x00f4, 0x00f5, 0x00f6, 0x00f7, + 0x00f8, 0x0173, 0x00fa, 0x00fb, 0x00fc, 0x0169, 0x016b, 0x02d9, +}; + +static int +iso8859_4_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) iso8859_4_2uni[c-0xa0]; + return 1; +} + +static const unsigned char iso8859_4_page00[224] = { + 0xa0, 0x00, 0x00, 0x00, 0xa4, 0x00, 0x00, 0xa7, /* 0xa0-0xa7 */ + 0xa8, 0x00, 0x00, 0x00, 0x00, 0xad, 0x00, 0xaf, /* 0xa8-0xaf */ + 0xb0, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0xb8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0x00, /* 0xc0-0xc7 */ + 0x00, 0xc9, 0x00, 0xcb, 0x00, 0xcd, 0xce, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0xd4, 0xd5, 0xd6, 0xd7, /* 0xd0-0xd7 */ + 0xd8, 0x00, 0xda, 0xdb, 0xdc, 0x00, 0x00, 0xdf, /* 0xd8-0xdf */ + 0x00, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0x00, /* 0xe0-0xe7 */ + 0x00, 0xe9, 0x00, 0xeb, 0x00, 0xed, 0xee, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x00, 0xf4, 0xf5, 0xf6, 0xf7, /* 0xf0-0xf7 */ + 0xf8, 0x00, 0xfa, 0xfb, 0xfc, 0x00, 0x00, 0x00, /* 0xf8-0xff */ + /* 0x0100 */ + 0xc0, 0xe0, 0x00, 0x00, 0xa1, 0xb1, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xc8, 0xe8, 0x00, 0x00, /* 0x08-0x0f */ + 0xd0, 0xf0, 0xaa, 0xba, 0x00, 0x00, 0xcc, 0xec, /* 0x10-0x17 */ + 0xca, 0xea, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0xab, 0xbb, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0xa5, 0xb5, 0xcf, 0xef, 0x00, 0x00, 0xc7, 0xe7, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd3, 0xf3, /* 0x30-0x37 */ + 0xa2, 0x00, 0x00, 0xa6, 0xb6, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xd1, 0xf1, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0xbd, 0xbf, 0xd2, 0xf2, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa3, 0xb3, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xa9, 0xb9, 0x00, 0x00, 0x00, 0x00, 0xac, 0xbc, /* 0x60-0x67 */ + 0xdd, 0xfd, 0xde, 0xfe, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0xd9, 0xf9, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xae, 0xbe, 0x00, /* 0x78-0x7f */ +}; +static const unsigned char iso8859_4_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb7, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0xff, 0x00, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ +}; + +static int +iso8859_4_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0180) + c = iso8859_4_page00[wc-0x00a0]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = iso8859_4_page02[wc-0x02c0]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_5.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_5.h new file mode 100644 index 0000000000000..6b836055ac6ad --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_5.h @@ -0,0 +1,95 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-5 + */ + +static const unsigned short iso8859_5_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x0401, 0x0402, 0x0403, 0x0404, 0x0405, 0x0406, 0x0407, + 0x0408, 0x0409, 0x040a, 0x040b, 0x040c, 0x00ad, 0x040e, 0x040f, + /* 0xb0 */ + 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, + 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, 0x041f, + /* 0xc0 */ + 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, 0x0427, + 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, 0x042f, + /* 0xd0 */ + 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0436, 0x0437, + 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, + /* 0xe0 */ + 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, + 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x044f, + /* 0xf0 */ + 0x2116, 0x0451, 0x0452, 0x0453, 0x0454, 0x0455, 0x0456, 0x0457, + 0x0458, 0x0459, 0x045a, 0x045b, 0x045c, 0x00a7, 0x045e, 0x045f, +}; + +static int +iso8859_5_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) iso8859_5_2uni[c-0xa0]; + return 1; +} + +static const unsigned char iso8859_5_page00[16] = { + 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfd, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xad, 0x00, 0x00, /* 0xa8-0xaf */ +}; +static const unsigned char iso8859_5_page04[96] = { + 0x00, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, /* 0x00-0x07 */ + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0x00, 0xae, 0xaf, /* 0x08-0x0f */ + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, /* 0x10-0x17 */ + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, /* 0x18-0x1f */ + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x20-0x27 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x28-0x2f */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0x30-0x37 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xdf, /* 0x38-0x3f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x40-0x47 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x48-0x4f */ + 0x00, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0x50-0x57 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0x00, 0xfe, 0xff, /* 0x58-0x5f */ +}; + +static int +iso8859_5_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00b0) + c = iso8859_5_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x0460) + c = iso8859_5_page04[wc-0x0400]; + else if (wc == 0x2116) + c = 0xf0; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_6.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_6.h new file mode 100644 index 0000000000000..8d311994093e0 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_6.h @@ -0,0 +1,98 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-6 + */ + +static const unsigned short iso8859_6_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0xfffd, 0xfffd, 0xfffd, 0x00a4, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x060c, 0x00ad, 0xfffd, 0xfffd, + /* 0xb0 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x061b, 0xfffd, 0xfffd, 0xfffd, 0x061f, + /* 0xc0 */ + 0xfffd, 0x0621, 0x0622, 0x0623, 0x0624, 0x0625, 0x0626, 0x0627, + 0x0628, 0x0629, 0x062a, 0x062b, 0x062c, 0x062d, 0x062e, 0x062f, + /* 0xd0 */ + 0x0630, 0x0631, 0x0632, 0x0633, 0x0634, 0x0635, 0x0636, 0x0637, + 0x0638, 0x0639, 0x063a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xe0 */ + 0x0640, 0x0641, 0x0642, 0x0643, 0x0644, 0x0645, 0x0646, 0x0647, + 0x0648, 0x0649, 0x064a, 0x064b, 0x064c, 0x064d, 0x064e, 0x064f, + /* 0xf0 */ + 0x0650, 0x0651, 0x0652, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, +}; + +static int +iso8859_6_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = iso8859_6_2uni[c-0xa0]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char iso8859_6_page00[16] = { + 0xa0, 0x00, 0x00, 0x00, 0xa4, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xad, 0x00, 0x00, /* 0xa8-0xaf */ +}; +static const unsigned char iso8859_6_page06[80] = { + 0x00, 0x00, 0x00, 0x00, 0xac, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0xbb, 0x00, 0x00, 0x00, 0xbf, /* 0x18-0x1f */ + 0x00, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x20-0x27 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x28-0x2f */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0x30-0x37 */ + 0xd8, 0xd9, 0xda, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x40-0x47 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x48-0x4f */ + 0xf0, 0xf1, 0xf2, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ +}; + +static int +iso8859_6_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00b0) + c = iso8859_6_page00[wc-0x00a0]; + else if (wc >= 0x0608 && wc < 0x0658) + c = iso8859_6_page06[wc-0x0608]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_7.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_7.h new file mode 100644 index 0000000000000..0825ef5cd9eaa --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_7.h @@ -0,0 +1,111 @@ +/* + * Copyright (C) 1999-2004 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-7 + */ + +static const unsigned short iso8859_7_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x2018, 0x2019, 0x00a3, 0x20ac, 0x20af, 0x00a6, 0x00a7, + 0x00a8, 0x00a9, 0x037a, 0x00ab, 0x00ac, 0x00ad, 0xfffd, 0x2015, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x0384, 0x0385, 0x0386, 0x00b7, + 0x0388, 0x0389, 0x038a, 0x00bb, 0x038c, 0x00bd, 0x038e, 0x038f, + /* 0xc0 */ + 0x0390, 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, + 0x0398, 0x0399, 0x039a, 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, + /* 0xd0 */ + 0x03a0, 0x03a1, 0xfffd, 0x03a3, 0x03a4, 0x03a5, 0x03a6, 0x03a7, + 0x03a8, 0x03a9, 0x03aa, 0x03ab, 0x03ac, 0x03ad, 0x03ae, 0x03af, + /* 0xe0 */ + 0x03b0, 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, + 0x03b8, 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, + /* 0xf0 */ + 0x03c0, 0x03c1, 0x03c2, 0x03c3, 0x03c4, 0x03c5, 0x03c6, 0x03c7, + 0x03c8, 0x03c9, 0x03ca, 0x03cb, 0x03cc, 0x03cd, 0x03ce, 0xfffd, +}; + +static int +iso8859_7_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = iso8859_7_2uni[c-0xa0]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char iso8859_7_page00[32] = { + 0xa0, 0x00, 0x00, 0xa3, 0x00, 0x00, 0xa6, 0xa7, /* 0xa0-0xa7 */ + 0xa8, 0xa9, 0x00, 0xab, 0xac, 0xad, 0x00, 0x00, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0xb2, 0xb3, 0x00, 0x00, 0x00, 0xb7, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xbb, 0x00, 0xbd, 0x00, 0x00, /* 0xb8-0xbf */ +}; +static const unsigned char iso8859_7_page03[88] = { + 0x00, 0x00, 0xaa, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0xb5, 0xb6, 0x00, /* 0x80-0x87 */ + 0xb8, 0xb9, 0xba, 0x00, 0xbc, 0x00, 0xbe, 0xbf, /* 0x88-0x8f */ + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x90-0x97 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x98-0x9f */ + 0xd0, 0xd1, 0x00, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0xa0-0xa7 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xdf, /* 0xa8-0xaf */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0xb0-0xb7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0xb8-0xbf */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0xc0-0xc7 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0x00, /* 0xc8-0xcf */ +}; +static const unsigned char iso8859_7_page20[16] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0xaf, 0x00, 0x00, /* 0x10-0x17 */ + 0xa1, 0xa2, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ +}; + +static int +iso8859_7_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = iso8859_7_page00[wc-0x00a0]; + else if (wc >= 0x0378 && wc < 0x03d0) + c = iso8859_7_page03[wc-0x0378]; + else if (wc >= 0x2010 && wc < 0x2020) + c = iso8859_7_page20[wc-0x2010]; + else if (wc == 0x20ac) + c = 0xa4; + else if (wc == 0x20af) + c = 0xa5; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_8.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_8.h new file mode 100644 index 0000000000000..6184846ea13b5 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_8.h @@ -0,0 +1,107 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-8 + */ + +static const unsigned short iso8859_8_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0xfffd, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, 0x00a7, + 0x00a8, 0x00a9, 0x00d7, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, + 0x00b8, 0x00b9, 0x00f7, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0xfffd, + /* 0xc0 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xd0 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x2017, + /* 0xe0 */ + 0x05d0, 0x05d1, 0x05d2, 0x05d3, 0x05d4, 0x05d5, 0x05d6, 0x05d7, + 0x05d8, 0x05d9, 0x05da, 0x05db, 0x05dc, 0x05dd, 0x05de, 0x05df, + /* 0xf0 */ + 0x05e0, 0x05e1, 0x05e2, 0x05e3, 0x05e4, 0x05e5, 0x05e6, 0x05e7, + 0x05e8, 0x05e9, 0x05ea, 0xfffd, 0xfffd, 0x200e, 0x200f, 0xfffd, +}; + +static int +iso8859_8_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c >= 0xa0) { + unsigned short wc = iso8859_8_2uni[c-0xa0]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + else { + *pwc = (ucs4_t) c; + return 1; + } + return RET_ILSEQ; +} + +static const unsigned char iso8859_8_page00[88] = { + 0xa0, 0x00, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, /* 0xa0-0xa7 */ + 0xa8, 0xa9, 0x00, 0xab, 0xac, 0xad, 0xae, 0xaf, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0xb8, 0xb9, 0x00, 0xbb, 0xbc, 0xbd, 0xbe, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xaa, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xba, /* 0xf0-0xf7 */ +}; +static const unsigned char iso8859_8_page05[32] = { + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0xd0-0xd7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0xd8-0xdf */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0xe0-0xe7 */ + 0xf8, 0xf9, 0xfa, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ +}; +static const unsigned char iso8859_8_page20[16] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfd, 0xfe, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xdf, /* 0x10-0x17 */ +}; + +static int +iso8859_8_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00f8) + c = iso8859_8_page00[wc-0x00a0]; + else if (wc >= 0x05d0 && wc < 0x05f0) + c = iso8859_8_page05[wc-0x05d0]; + else if (wc >= 0x2008 && wc < 0x2018) + c = iso8859_8_page20[wc-0x2008]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/iso8859_9.h b/graf2d/win32gdk/gdk/src/iconv/iso8859_9.h new file mode 100644 index 0000000000000..7dbd37d233ccb --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/iso8859_9.h @@ -0,0 +1,85 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-8859-9 + */ + +static const unsigned short iso8859_9_2uni[48] = { + /* 0xd0 */ + 0x011e, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x00d7, + 0x00d8, 0x00d9, 0x00da, 0x00db, 0x00dc, 0x0130, 0x015e, 0x00df, + /* 0xe0 */ + 0x00e0, 0x00e1, 0x00e2, 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x00e7, + 0x00e8, 0x00e9, 0x00ea, 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, + /* 0xf0 */ + 0x011f, 0x00f1, 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x00f7, + 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x0131, 0x015f, 0x00ff, +}; + +static int +iso8859_9_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c >= 0xd0) + *pwc = (ucs4_t) iso8859_9_2uni[c-0xd0]; + else + *pwc = (ucs4_t) c; + return 1; +} + +static const unsigned char iso8859_9_page00[48] = { + 0x00, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0xd0-0xd7 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0x00, 0x00, 0xdf, /* 0xd8-0xdf */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0xe0-0xe7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0xe8-0xef */ + 0x00, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0xf0-0xf7 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0x00, 0x00, 0xff, /* 0xf8-0xff */ +}; +static const unsigned char iso8859_9_page01[72] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd0, 0xf0, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0xdd, 0xfd, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xde, 0xfe, /* 0x58-0x5f */ +}; + +static int +iso8859_9_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00d0) { + *r = wc; + return 1; + } + else if (wc >= 0x00d0 && wc < 0x0100) + c = iso8859_9_page00[wc-0x00d0]; + else if (wc >= 0x0118 && wc < 0x0160) + c = iso8859_9_page01[wc-0x0118]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/isoir165.h b/graf2d/win32gdk/gdk/src/iconv/isoir165.h new file mode 100644 index 0000000000000..4d6e9ffa0301a --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/isoir165.h @@ -0,0 +1,159 @@ +/* + * Copyright (C) 1999-2001, 2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-IR-165 + */ + +/* + * ISO-IR-165 is an extension of GB 2312, consisting of: + * 1. GB 6345.1-86 corrections: + * Two corrections to GB 2312, at 0x2367 and 0x6F71. + * 2. GB 6345.1-86 additions: + * - 6 new full-width pinyin characters in row 0x28. + * - ISO646-CN in row 0x2A. + * - 32 half-width pinyin characters in row 0x2B. + * 3. GB 8565.2-88 additions: + * - 50 characters in row 0x2D. + * - 92 characters in row 0x2E. + * - 93 characters in row 0x2F. + * - 470 characters in rows 0x7A-0x7E. + * 4. ISO-IR-165 additions: + * - 22 characters in row 0x26. + * - 94 characters in row 0x2C. + * - 44 new characters in row 0x2D. + * - 1 new character in row 0x2F. + * + * The conversion table was created from the following sources: + * Ad 1. The 0x2367 correction is already integrated in the unicode.org + * GB2312.TXT table. The 0x6F71 mapping is the same in the unicode.org + * GB2312.TXT and UNIHAN.TXT table and in Koichi Yasuoka's Uni2GB table, + * so we assume it's correct. + * The unicode.org UNIHAN.TXT table about GB 8565 is not usable: it has + * extraneous code points at rows 0x28, 0x2C, 0x2D. Note also that it does + * not list the 69 non-hanzi in row 0x2F. Moreover, it has the characters + * 0x2F7A-0x2F7D shifted down by one to 0x2F79-0x2F7C. + * Therefore we take the GB8565 and ISO-IR-165 data from Koichi Yasuoka's + * Uni2GB table. + * Ad 1. Yasuoka maps 0x2367 to U+0261 (small script g) and 0x2840 to U+FF47 + * (full-width small normal g). While coherent with ISO-IR's 165.pdf, + * this disagrees with Ken Lunde's book: He says that ISO-IR-165 + * includes the GB6345 correction, i.e. maps 0x2367 to U+FF47 or U+0067 + * and _not_ to U+0261 (small script g). + * To overcome the confusion, we just map both 0x2367 and 0x2840 to + * U+FF47. + * Ad 2. Row 0x28: Add a mapping from 0x283F to U+01F9. + * Row 0x2A: Mapping is well-known, also present in Koichi Yasuoka's + * table. + * Row 0x2B: Typed in by hand from appendix E in Ken Lunde's book. + * When converting from Unicode to ISO-IR-165, prefer the half-width + * range 0x2B{21..40} to the full-width range 0x28{21..40}. + * Ad 3. Rows 0x2D, 0x2E: Both Koichi Yasuoka's Uni2GB table and the UNIHAN.TXT + * data for GB 8565 agree here. + * Row 0x2F: Taken from Koichi Yasuoka's Uni2GB table. + * Rows 0x7A-0x7E: Koichi Yasuoka's Uni2GB table and the UNIHAN.TXT + * data for GB 8565 agree here mostly. Differences: + * 0x7C38 -> U+6F26 or U+527A ? We choose U+6F26. + * 0x7C5A -> U+7A40 or U+6996 ? We choose U+6996. + * Ad 4. Row 0x26: Mapping unknown. + * Rows 0x2C, 0x2D: Both Koichi Yasuoka's Uni2GB table and the UNIHAN.TXT + * data for GB 8565 (!) agree here. + * Row 0x2F: Taken from Koichi Yasuoka's Uni2GB table. + */ + +#include "isoir165ext.h" + +static int +isoir165_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + int ret; + + /* Map full-width pinyin (row 0x28) like half-width pinyin (row 0x2B). */ + if (s[0] == 0x28) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 <= 0x40) { + unsigned char buf[2]; + buf[0] = 0x2b; + buf[1] = c2; + ret = isoir165ext_mbtowc(conv,pwc,buf,2); + if (ret != RET_ILSEQ) + return ret; + } + } + } + /* Try the GB2312 -> Unicode table. */ + ret = gb2312_mbtowc(conv,pwc,s,n); + if (ret != RET_ILSEQ) + return ret; + /* Row 0x2A is GB_1988-80. */ + if (s[0] == 0x2a) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + int ret = iso646_cn_mbtowc(conv,pwc,s+1,1); + if (ret != 1) abort(); + return 2; + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + /* Try the ISO-IR-165 extensions -> Unicode table. */ + ret = isoir165ext_mbtowc(conv,pwc,s,n); + return ret; +} + +static int +isoir165_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Try the Unicode -> GB2312 table. */ + ret = gb2312_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (!(buf[0] == 0x28 && buf[1] >= 0x21 && buf[1] <= 0x40)) { + if (n >= 2) { + r[0] = buf[0]; + r[1] = buf[1]; + return 2; + } + return RET_TOOSMALL; + } + } + /* Row 0x2A is GB_1988-80. */ + ret = iso646_cn_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + if (ret != 1) abort(); + if (buf[0] >= 0x21 && buf[0] < 0x7f) { + if (n >= 2) { + r[0] = 0x2a; + r[1] = buf[0]; + return 2; + } + return RET_TOOSMALL; + } + } + /* Try the Unicode -> ISO-IR-165 extensions table. */ + ret = isoir165ext_wctomb(conv,r,wc,n); + return ret; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/isoir165ext.h b/graf2d/win32gdk/gdk/src/iconv/isoir165ext.h new file mode 100644 index 0000000000000..0bc811ac30104 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/isoir165ext.h @@ -0,0 +1,800 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * ISO-IR-165 extensions + */ + +static const unsigned short isoir165ext_2uni_page2b[470] = { + /* 0x2b */ + 0x1fb1, 0x03ac, 0x1fb0, 0x1f70, 0x0113, 0x00e9, 0x011b, 0x00e8, + 0x012b, 0x00ed, 0x01d0, 0x00ec, 0x014d, 0x00f3, 0x01d2, 0x00f2, + 0x016b, 0x00fa, 0x01d4, 0x00f9, 0x01d6, 0x01d8, 0x01da, 0x01dc, + 0x00fc, 0x00ea, 0x03b1, 0x1e3f, 0x0144, 0x0148, 0x01f9, 0xff47, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x2c */ + 0x53be, 0x4eb8, 0x4f3e, 0x501e, 0x50c7, 0x9118, 0x6c98, 0x6cdc, + 0x6cc3, 0x6e5d, 0x6ea6, 0x6eeb, 0x6fa5, 0x6165, 0x5ea4, 0x9618, + 0x5848, 0x8453, 0x7cf5, 0x5f07, 0x6294, 0x647d, 0x725a, 0x5574, + 0x55a4, 0x5640, 0x5684, 0x5d1f, 0x72c9, 0x998c, 0x59de, 0x59fd, + 0x5a5e, 0x7ebb, 0x7ee4, 0x7ef9, 0x9a99, 0x71cf, 0x6245, 0x624a, + 0x797c, 0x739a, 0x742b, 0x7488, 0x74aa, 0x74d8, 0x6767, 0x6ab5, + 0x71ca, 0x6ba3, 0x8f80, 0x8f92, 0x8d5f, 0x9b36, 0x72a8, 0x87a3, + 0x8152, 0x6b38, 0x98d0, 0x8897, 0x88af, 0x8955, 0x770a, 0x94da, + 0x955a, 0x9560, 0x9e24, 0x9e40, 0x9e50, 0x9e5d, 0x9e60, 0x870e, + 0x7b5c, 0x7fd9, 0x7fef, 0x7e44, 0x8e45, 0x8e36, 0x8e62, 0x8e5c, + 0x9778, 0x9b46, 0x9f2b, 0x9f41, 0x7526, 0x4e26, 0x8bac, 0x8129, + 0x5091, 0x50cd, 0x52b9, 0x89d4, 0x5557, 0x94c7, + /* 0x2d */ + 0x9496, 0x9498, 0x94cf, 0x94d3, 0x94d4, 0x94e6, 0x9533, 0x951c, + 0x9520, 0x9527, 0x953d, 0x9543, 0x956e, 0x9574, 0x9c80, 0x9c84, + 0x9c8a, 0x9c93, 0x9c96, 0x9c97, 0x9c98, 0x9c99, 0x9cbf, 0x9cc0, + 0x9cc1, 0x9cd2, 0x9cdb, 0x9ce0, 0x9ce3, 0x9770, 0x977a, 0x97a1, + 0x97ae, 0x97a8, 0x9964, 0x9966, 0x9978, 0x9979, 0x997b, 0x997e, + 0x9982, 0x9983, 0x998e, 0x9b10, 0x9b18, 0x65a2, 0x9e80, 0x911c, + 0x9e91, 0x9f12, 0x52f3, 0x6c96, 0x6d44, 0x6e1b, 0x6e67, 0x6f82, + 0x6fec, 0x60ae, 0x5ec8, 0x8ffa, 0x577f, 0x5586, 0x849e, 0x8460, + 0x5c05, 0x5e0b, 0x5d11, 0x5d19, 0x5dd6, 0x59b3, 0x5aae, 0x9a94, + 0x658f, 0x709e, 0x7551, 0x71ff, 0x691d, 0x6a11, 0x68bf, 0x6607, + 0x668e, 0x6673, 0x6c25, 0x7652, 0x778b, 0x76ea, 0x9895, 0x8780, + 0x882d, 0x7b87, 0x7c50, 0x8ead, 0x9575, 0x65c2, + /* 0x2e */ + 0x5390, 0x79b8, 0x4f15, 0x4f21, 0x4f3b, 0x4fa2, 0x50a4, 0x5092, + 0x530a, 0x51c3, 0x51a8, 0x8d20, 0x5787, 0x579a, 0x5795, 0x57eb, + 0x585d, 0x585a, 0x5871, 0x5895, 0x5c30, 0x5f0c, 0x5f0d, 0x5f0e, + 0x5c72, 0x5cc7, 0x5fac, 0x5f68, 0x5f5f, 0x5a12, 0x5a65, 0x5a84, + 0x5ac4, 0x7394, 0x73ea, 0x73ee, 0x7437, 0x7415, 0x7454, 0x6799, + 0x686c, 0x68f8, 0x69fe, 0x72e2, 0x6667, 0x8d52, 0x89c3, 0x89cd, + 0x6427, 0x6477, 0x6c1d, 0x813f, 0x6b54, 0x98d6, 0x707a, 0x70f1, + 0x7120, 0x6153, 0x6c87, 0x6dad, 0x6e81, 0x6eb5, 0x6f94, 0x6f9b, + 0x793d, 0x794e, 0x7806, 0x7859, 0x7894, 0x78dc, 0x7903, 0x7a16, + 0x7a5e, 0x75e0, 0x7adc, 0x7676, 0x9892, 0x7bf2, 0x7c30, 0x7c5d, + 0x9c9d, 0x7cac, 0x8278, 0x83d1, 0x84ea, 0x7fc0, 0x7f1e, 0x8e21, + 0x8e53, 0x9754, 0x9f0c, 0x94fb, 0xfffd, 0xfffd, + /* 0x2f */ + 0x32c0, 0x32c1, 0x32c2, 0x32c3, 0x32c4, 0x32c5, 0x32c6, 0x32c7, + 0x32c8, 0x32c9, 0x32ca, 0x32cb, 0x33e0, 0x33e1, 0x33e2, 0x33e3, + 0x33e4, 0x33e5, 0x33e6, 0x33e7, 0x33e8, 0x33e9, 0x33ea, 0x33eb, + 0x33ec, 0x33ed, 0x33ee, 0x33ef, 0x33f0, 0x33f1, 0x33f2, 0x33f3, + 0x33f4, 0x33f5, 0x33f6, 0x33f7, 0x33f8, 0x33f9, 0x33fa, 0x33fb, + 0x33fc, 0x33fd, 0x33fe, 0x3358, 0x3359, 0x335a, 0x335b, 0x335c, + 0x335d, 0x335e, 0x335f, 0x3360, 0x3361, 0x3362, 0x3363, 0x3364, + 0x3365, 0x3366, 0x3367, 0x3368, 0x3369, 0x336a, 0x336b, 0x336c, + 0x336d, 0x336e, 0x336f, 0x3370, 0x3037, 0x90a8, 0x965e, 0x5842, + 0x5803, 0x6c3e, 0x6d29, 0x6ee7, 0x8534, 0x84c6, 0x633c, 0x5d05, + 0x7f10, 0x7eec, 0x7287, 0x712e, 0x8218, 0x8216, 0x756c, 0x75f3, + 0x9b25, 0x8980, 0x7ca6, 0x4e85, 0x5570, 0x91c6, +}; +static const unsigned short isoir165ext_2uni_page7a[470] = { + /* 0x7a */ + 0x4e0f, 0x673f, 0x4e42, 0x752a, 0x592c, 0x9ee1, 0x8652, 0x531c, + 0x5187, 0x518f, 0x50f0, 0x4f0b, 0x4f23, 0x4f03, 0x4f61, 0x4f7a, + 0x4f6b, 0x4feb, 0x4ff5, 0x5034, 0x5022, 0x4ff6, 0x5072, 0x4eb6, + 0x51ae, 0x5910, 0x6bda, 0x522c, 0x5232, 0x4fb4, 0x5298, 0x52bb, + 0x52bc, 0x52cd, 0x52da, 0x52f7, 0x53c6, 0x53c7, 0x5770, 0x576c, + 0x57b1, 0x579f, 0x579e, 0x57be, 0x57cc, 0x580e, 0x580c, 0x57f5, + 0x5809, 0x583c, 0x5843, 0x5845, 0x5846, 0x583d, 0x5853, 0x5888, + 0x5884, 0x58f8, 0x56ad, 0x5940, 0x5953, 0x596d, 0x5c2a, 0x54a5, + 0x551d, 0x5536, 0x556f, 0x554d, 0x569a, 0x569c, 0x56f7, 0x5710, + 0x5719, 0x5e17, 0x5e21, 0x5e28, 0x5e6a, 0x5c74, 0x5c7c, 0x5ca8, + 0x5c9e, 0x5cc3, 0x5cd3, 0x5ce3, 0x5ce7, 0x5cff, 0x5d04, 0x5d00, + 0x5d1a, 0x5d0c, 0x5d4e, 0x5d5a, 0x5d85, 0x5d93, + /* 0x7b */ + 0x5d92, 0x5dc2, 0x5dc9, 0x8852, 0x5faf, 0x5906, 0x65a8, 0x7241, + 0x7242, 0x5ebc, 0x5ecb, 0x95ec, 0x95ff, 0x8a1a, 0x9607, 0x9613, + 0x961b, 0x5bac, 0x5ba7, 0x5c5d, 0x5f22, 0x59ee, 0x5a7c, 0x5a96, + 0x5a73, 0x5a9e, 0x5aad, 0x5ada, 0x5aea, 0x5b1b, 0x5b56, 0x9a72, + 0x9a83, 0x9a89, 0x9a8d, 0x9a8e, 0x9a95, 0x9aa6, 0x7395, 0x7399, + 0x73a0, 0x73b1, 0x73a5, 0x73a6, 0x73d6, 0x73f0, 0x73fd, 0x73e3, + 0x7424, 0x740e, 0x7407, 0x73f6, 0x73fa, 0x7432, 0x742f, 0x7444, + 0x7442, 0x7471, 0x7478, 0x7462, 0x7486, 0x749f, 0x74a0, 0x7498, + 0x74b2, 0x97e8, 0x6745, 0x679f, 0x677b, 0x67c8, 0x67ee, 0x684b, + 0x68a0, 0x6812, 0x681f, 0x686a, 0x68bc, 0x68fb, 0x686f, 0x68b1, + 0x68c1, 0x68eb, 0x6913, 0x68d1, 0x6911, 0x68d3, 0x68ec, 0x692b, + 0x68e8, 0x69be, 0x6969, 0x6940, 0x696f, 0x695f, + /* 0x7c */ + 0x6962, 0x6935, 0x6959, 0x69bc, 0x69c5, 0x69da, 0x69dc, 0x6a0b, + 0x69e5, 0x6a66, 0x6a96, 0x6ab4, 0x72dd, 0x5cf1, 0x7314, 0x733a, + 0x6b95, 0x5f67, 0x80fe, 0x74fb, 0x7503, 0x655c, 0x6569, 0x6f26, + 0x65f8, 0x65fb, 0x6609, 0x663d, 0x6662, 0x665e, 0x666c, 0x668d, + 0x668b, 0x8d51, 0x8d57, 0x7263, 0x7277, 0x63b1, 0x6261, 0x6260, + 0x6283, 0x62e4, 0x62c3, 0x631c, 0x6326, 0x63af, 0x63fe, 0x6422, + 0x6412, 0x64ed, 0x6713, 0x6718, 0x8158, 0x81d1, 0x98cf, 0x98d4, + 0x98d7, 0x6996, 0x7098, 0x70dc, 0x70fa, 0x710c, 0x711c, 0x71cb, + 0x721f, 0x70dd, 0x659d, 0x6246, 0x6017, 0x60c7, 0x60d3, 0x60b0, + 0x60d9, 0x6114, 0x6c3f, 0x6c67, 0x6c84, 0x6c9a, 0x6c6d, 0x6ca8, + 0x6cc6, 0x6cb5, 0x6d49, 0x6d38, 0x6d11, 0x6d3a, 0x6d28, 0x6d50, + 0x6d34, 0x6d55, 0x6d61, 0x6da2, 0x6d65, 0x6d5b, + /* 0x7d */ + 0x6d64, 0x6db4, 0x6e9a, 0x6e5c, 0x6e72, 0x6ea0, 0x6e87, 0x6e8e, + 0x6ec9, 0x6ec3, 0x6f37, 0x6ed8, 0x6eea, 0x6f56, 0x6f75, 0x6f5f, + 0x6fb4, 0x6fbc, 0x7014, 0x700d, 0x700c, 0x703c, 0x7943, 0x7947, + 0x794a, 0x7950, 0x7972, 0x7998, 0x79a0, 0x79a4, 0x77fc, 0x77fb, + 0x7822, 0x7820, 0x7841, 0x785a, 0x7875, 0x78b6, 0x78e1, 0x7933, + 0x8a5f, 0x76fb, 0x771b, 0x772c, 0x7786, 0x77ab, 0x77ad, 0x7564, + 0x756f, 0x6983, 0x7f7d, 0x76dd, 0x76e6, 0x76ec, 0x7521, 0x79fe, + 0x7a44, 0x767f, 0x769e, 0x9e27, 0x9e2e, 0x9e30, 0x9e34, 0x9e4d, + 0x9e52, 0x9e53, 0x9e54, 0x9e56, 0x9e59, 0x9e61, 0x9e62, 0x9e65, + 0x9e6f, 0x9e74, 0x75a2, 0x7604, 0x7608, 0x761d, 0x7ad1, 0x7a85, + 0x7a8e, 0x7aa3, 0x7ab8, 0x7abe, 0x77de, 0x8030, 0x988b, 0x988e, + 0x9899, 0x98a3, 0x8683, 0x8705, 0x8758, 0x87cf, + /* 0x7e */ + 0x87e2, 0x880b, 0x80d4, 0x7f4d, 0x7b4a, 0x7b4e, 0x7b7f, 0x7b93, + 0x7bef, 0x7c09, 0x7bf0, 0x7c15, 0x7c03, 0x7c20, 0x823a, 0x8886, + 0x88aa, 0x88c0, 0x88c8, 0x8926, 0x8976, 0x7f91, 0x8283, 0x82bc, + 0x82a7, 0x8313, 0x82fe, 0x8300, 0x835d, 0x8345, 0x8344, 0x831d, + 0x83a6, 0x8399, 0x83fe, 0x841a, 0x83fc, 0x8429, 0x8439, 0x84a8, + 0x84cf, 0x849f, 0x84c2, 0x84f7, 0x8570, 0x85b3, 0x85a2, 0x96d8, + 0x85b8, 0x85e0, 0x7fda, 0x7eae, 0x7eb4, 0x7ebc, 0x7ed6, 0x7f0a, + 0x5b43, 0x8d6a, 0x5245, 0x8c68, 0x8c6e, 0x8c6d, 0x8e16, 0x8e26, + 0x8e27, 0x8e50, 0x9098, 0x90a0, 0x90bd, 0x90c8, 0x90c3, 0x90da, + 0x90ff, 0x911a, 0x910c, 0x9120, 0x9142, 0x8fb5, 0x90e4, 0x8c86, + 0x89f1, 0x8bb1, 0x8bbb, 0x8bc7, 0x8bea, 0x8c09, 0x8c1e, 0x9702, + 0x68d0, 0x7306, 0x9f81, 0x9f82, 0x92c6, 0x9491, +}; + +static int +isoir165ext_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x2b && c1 <= 0x2f) || (c1 >= 0x7a && c1 <= 0x7e)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + unsigned short wc = 0xfffd; + if (i < 8366) { + if (i < 1410) + wc = isoir165ext_2uni_page2b[i-940]; + } else { + if (i < 8836) + wc = isoir165ext_2uni_page7a[i-8366]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short isoir165ext_2charset[876] = { + 0x2b28, 0x2b26, 0x2b3a, 0x2b2c, 0x2b2a, 0x2b30, 0x2b2e, 0x2b34, + 0x2b32, 0x2b39, 0x2b25, 0x2b27, 0x2b29, 0x2b3d, 0x2b3e, 0x2b2d, + 0x2b31, 0x2b2b, 0x2b2f, 0x2b33, 0x2b35, 0x2b36, 0x2b37, 0x2b38, + 0x2b3f, 0x2b22, 0x2b3b, 0x2b3c, 0x2b24, 0x2b23, 0x2b21, 0x2f65, + 0x2f21, 0x2f22, 0x2f23, 0x2f24, 0x2f25, 0x2f26, 0x2f27, 0x2f28, + 0x2f29, 0x2f2a, 0x2f2b, 0x2f2c, 0x2f4c, 0x2f4d, 0x2f4e, 0x2f4f, + 0x2f50, 0x2f51, 0x2f52, 0x2f53, 0x2f54, 0x2f55, 0x2f56, 0x2f57, + 0x2f58, 0x2f59, 0x2f5a, 0x2f5b, 0x2f5c, 0x2f5d, 0x2f5e, 0x2f5f, + 0x2f60, 0x2f61, 0x2f62, 0x2f63, 0x2f64, 0x2f2d, 0x2f2e, 0x2f2f, + 0x2f30, 0x2f31, 0x2f32, 0x2f33, 0x2f34, 0x2f35, 0x2f36, 0x2f37, + 0x2f38, 0x2f39, 0x2f3a, 0x2f3b, 0x2f3c, 0x2f3d, 0x2f3e, 0x2f3f, + 0x2f40, 0x2f41, 0x2f42, 0x2f43, 0x2f44, 0x2f45, 0x2f46, 0x2f47, + 0x2f48, 0x2f49, 0x2f4a, 0x2f4b, 0x7a21, 0x2c76, 0x7a23, 0x2f7c, + 0x7a38, 0x2c22, 0x7a2e, 0x7a2c, 0x2e23, 0x2e24, 0x7a2d, 0x2e25, + 0x2c23, 0x7a2f, 0x7a31, 0x7a30, 0x2e26, 0x7a3e, 0x7a32, 0x7a33, + 0x7a36, 0x2c24, 0x7a35, 0x7a34, 0x7a37, 0x2c79, 0x2e28, 0x2e27, + 0x2c25, 0x2c7a, 0x7a2b, 0x7a29, 0x7a2a, 0x2e2b, 0x7a39, 0x2e2a, + 0x7a3c, 0x7a3d, 0x7e5b, 0x7a3f, 0x2c7b, 0x7a40, 0x7a41, 0x7a42, + 0x7a43, 0x2d53, 0x7a44, 0x2e29, 0x7a28, 0x2e21, 0x2c21, 0x7a45, + 0x7a46, 0x7a60, 0x7a61, 0x7a62, 0x7a64, 0x2c7d, 0x7a63, 0x2f7d, + 0x2c38, 0x2d5e, 0x2c39, 0x2c3a, 0x2c3b, 0x7a65, 0x7a66, 0x7a5b, + 0x7a67, 0x7a68, 0x7a69, 0x7a48, 0x7a47, 0x2d5d, 0x2e2d, 0x2e2f, + 0x2e2e, 0x7a4b, 0x7a4a, 0x7a49, 0x7a4c, 0x7a4d, 0x2e30, 0x7a50, + 0x2f69, 0x7a51, 0x7a4f, 0x7a4e, 0x7a52, 0x7a56, 0x2f68, 0x7a53, + 0x7a54, 0x7a55, 0x2c31, 0x7a57, 0x2e32, 0x2e31, 0x2e33, 0x7a59, + 0x7a58, 0x2e34, 0x7a5a, 0x7b26, 0x7a3a, 0x7a25, 0x7a5c, 0x7a5d, + 0x7a5e, 0x2d66, 0x2c3f, 0x7b36, 0x2c40, 0x2e3e, 0x2c41, 0x2e3f, + 0x7b39, 0x7b37, 0x2e40, 0x7b38, 0x7b3a, 0x7b3b, 0x2d67, 0x2e41, + 0x7b3c, 0x7b3d, 0x7b3e, 0x7e59, 0x7b3f, 0x7b33, 0x7b32, 0x2d61, + 0x7a5f, 0x2e35, 0x7b34, 0x2e39, 0x7a6e, 0x7a6f, 0x7a71, 0x7a70, + 0x7a72, 0x2e3a, 0x7a73, 0x7a74, 0x7a75, 0x7c2e, 0x7a76, 0x7a78, + 0x7a77, 0x2f70, 0x7a7a, 0x2d63, 0x2d64, 0x7a79, 0x2c3c, 0x7a7b, + 0x7a7c, 0x7a7d, 0x7b21, 0x7a7e, 0x7b22, 0x7b23, 0x2d65, 0x2d62, + 0x7a6a, 0x7a6b, 0x7a6c, 0x7a6d, 0x2c2f, 0x7b2a, 0x2d5b, 0x7b2b, + 0x2c34, 0x2e36, 0x2e37, 0x2e38, 0x7b35, 0x2e3d, 0x7c32, 0x2e3c, + 0x2e3b, 0x7b25, 0x7c65, 0x2d5a, 0x7c68, 0x7c66, 0x7c67, 0x7c69, + 0x7c6a, 0x2e5a, 0x2c2e, 0x2c47, 0x7c64, 0x2c48, 0x7c48, 0x7c47, + 0x7c49, 0x2c35, 0x7c4b, 0x7c4a, 0x7c4c, 0x7c4d, 0x2f6f, 0x7c4e, + 0x7c46, 0x7c4f, 0x7c51, 0x7c50, 0x2e51, 0x2e52, 0x2c36, 0x7c52, + 0x7c36, 0x7c37, 0x2d69, 0x7c63, 0x2d4e, 0x7b27, 0x2d7e, 0x7c39, + 0x7c3a, 0x2d70, 0x7c3b, 0x7c3c, 0x7c3e, 0x7c3d, 0x2e4d, 0x7c3f, + 0x2d72, 0x7c41, 0x7c40, 0x2d71, 0x7c53, 0x7c54, 0x7a22, 0x7b63, + 0x2c4f, 0x7b65, 0x2e48, 0x7b64, 0x7b66, 0x7b67, 0x7b6a, 0x7b6b, + 0x7b68, 0x7b6c, 0x2e49, 0x7b6f, 0x7b69, 0x7b70, 0x7b6d, 0x2d6f, + 0x7b71, 0x7e79, 0x7b74, 0x7b76, 0x7b79, 0x7b72, 0x7b77, 0x2e4a, + 0x7b6e, 0x7b75, 0x7b73, 0x2d6d, 0x7b78, 0x7c22, 0x7b7c, 0x7c23, + 0x7b7e, 0x7c21, 0x7b7b, 0x7b7d, 0x7d52, 0x7c5a, 0x7c24, 0x7b7a, + 0x7c25, 0x7c26, 0x7c27, 0x7c29, 0x2e4b, 0x7c28, 0x2d6e, 0x7c2a, + 0x7c2b, 0x7c2c, 0x2c50, 0x2c5a, 0x2e55, 0x7c31, 0x2c52, 0x7a3b, + 0x2e53, 0x2d73, 0x2f6a, 0x7c6b, 0x7c6c, 0x7c6f, 0x7c6d, 0x2e5b, + 0x2d54, 0x2c27, 0x7c6e, 0x7c70, 0x7c72, 0x2c29, 0x7c71, 0x2c28, + 0x7c75, 0x7c77, 0x2f6b, 0x7c79, 0x7c74, 0x7c76, 0x2d55, 0x7c73, + 0x7c78, 0x7c7a, 0x7c7e, 0x7c7b, 0x7d21, 0x7c7d, 0x7c7c, 0x2e5c, + 0x7d22, 0x2d56, 0x7d24, 0x2c2a, 0x2d57, 0x7d25, 0x2e5d, 0x7d27, + 0x7d28, 0x7d23, 0x7d26, 0x2c2b, 0x2e5e, 0x7d2a, 0x7d29, 0x7d2c, + 0x2f6c, 0x7d2d, 0x2c2c, 0x7c38, 0x7d2b, 0x7d2e, 0x7d30, 0x7d2f, + 0x2d58, 0x2e5f, 0x2e60, 0x2c2d, 0x7d31, 0x7d32, 0x2d59, 0x7d35, + 0x7d34, 0x7d33, 0x7d36, 0x2e57, 0x7c5b, 0x2d6a, 0x7c5c, 0x7c62, + 0x2e58, 0x7c5d, 0x7c5e, 0x7c5f, 0x2e59, 0x2f74, 0x2c51, 0x7c60, + 0x2c46, 0x2d6c, 0x7c61, 0x7b28, 0x7b29, 0x2c37, 0x7c44, 0x7c45, + 0x2f73, 0x2c57, 0x2c3d, 0x7c2d, 0x2e4c, 0x7e7a, 0x7c2f, 0x7c30, + 0x2e42, 0x7b47, 0x7b48, 0x2c4a, 0x7b49, 0x7b4b, 0x7b4c, 0x7b4a, + 0x7b4d, 0x7b50, 0x2e43, 0x2e44, 0x7b4e, 0x7b54, 0x7b55, 0x7b4f, + 0x7b53, 0x7b52, 0x2e46, 0x7b51, 0x2c4b, 0x7b57, 0x7b56, 0x2e45, + 0x7b59, 0x7b58, 0x2e47, 0x7b5c, 0x7b5a, 0x7b5b, 0x7b5d, 0x2c4c, + 0x7b60, 0x7b5e, 0x7b5f, 0x2c4d, 0x7b61, 0x2c4e, 0x7c34, 0x7c35, + 0x7d57, 0x2c75, 0x7a24, 0x2d6b, 0x7d50, 0x2f77, 0x7d51, 0x7d6b, + 0x2e6a, 0x2f78, 0x7d6c, 0x7d6d, 0x7d6e, 0x2d74, 0x2e6c, 0x7d5a, + 0x7d5b, 0x7d54, 0x7d55, 0x2d76, 0x7d56, 0x7d4a, 0x2c5f, 0x7d4b, + 0x7d4c, 0x7d4d, 0x2d75, 0x7d4e, 0x7d4f, 0x7d75, 0x7d40, 0x7d3f, + 0x2e63, 0x7d42, 0x7d41, 0x7d43, 0x2e64, 0x7d44, 0x7d45, 0x2e65, + 0x7d46, 0x2e66, 0x7d47, 0x2e67, 0x7d48, 0x2e61, 0x7d37, 0x7d38, + 0x7d39, 0x2e62, 0x7d3a, 0x7d3b, 0x2c49, 0x7d3c, 0x7d3d, 0x7d3e, + 0x2e22, 0x7d58, 0x2e68, 0x7d59, 0x2e69, 0x7d70, 0x7d71, 0x7d72, + 0x7d73, 0x7d74, 0x7d6f, 0x2e6b, 0x7e25, 0x7e26, 0x2c69, 0x7e27, + 0x2d7a, 0x7e28, 0x7e29, 0x7e2b, 0x2e6e, 0x7e2d, 0x7e2a, 0x7e2c, + 0x7e2e, 0x2e6f, 0x2d7b, 0x2e70, 0x2f7b, 0x2e72, 0x2c33, 0x2c6c, + 0x7e54, 0x7e55, 0x2c42, 0x7e56, 0x7e57, 0x2c43, 0x2f72, 0x2c44, + 0x7e58, 0x2f71, 0x2e77, 0x7e24, 0x7d53, 0x7e36, 0x2e76, 0x2c6a, + 0x7e53, 0x2c6b, 0x7d76, 0x7e23, 0x7c33, 0x2c78, 0x2e54, 0x2c59, + 0x7c55, 0x7c56, 0x2f76, 0x2f75, 0x7e2f, 0x2e73, 0x7e37, 0x7e39, + 0x7e38, 0x7e3b, 0x7e3c, 0x7e3a, 0x7e40, 0x7e3f, 0x7e3e, 0x7e3d, + 0x7e42, 0x7e41, 0x2e74, 0x7e45, 0x7e43, 0x7e44, 0x7e46, 0x7e47, + 0x2c32, 0x2d60, 0x2d5f, 0x7e4a, 0x7e48, 0x7e4b, 0x2f6e, 0x7e49, + 0x2e75, 0x7e4c, 0x2f6d, 0x7e4d, 0x7e4f, 0x7e4e, 0x7e51, 0x7e52, + 0x7a27, 0x7d7b, 0x7d7c, 0x2c68, 0x7d7d, 0x2d78, 0x2c58, 0x7d7e, + 0x7e21, 0x7e22, 0x2d79, 0x7b24, 0x7e30, 0x2c5c, 0x7e31, 0x2c5d, + 0x7e32, 0x7e33, 0x7e34, 0x2c5e, 0x7e35, 0x2f7a, 0x2e4f, 0x2e50, + 0x2c7c, 0x7e71, 0x7b2e, 0x7d49, 0x2c77, 0x7e72, 0x7e73, 0x7e74, + 0x7e75, 0x7e76, 0x7e77, 0x7e5c, 0x7e5e, 0x7e5d, 0x7e70, 0x2e2c, + 0x7c42, 0x2e4e, 0x7c43, 0x2c55, 0x7e5a, 0x7e5f, 0x2e78, 0x7e60, + 0x7e61, 0x2c6e, 0x2c6d, 0x7e62, 0x2e79, 0x2c70, 0x2c6f, 0x2d7c, + 0x2c53, 0x2c54, 0x7e6e, 0x2d5c, 0x7e63, 0x7e64, 0x2f66, 0x7e65, + 0x7e67, 0x7e66, 0x7e68, 0x7e6f, 0x7e69, 0x7e6b, 0x2c26, 0x7e6a, + 0x2d50, 0x7e6c, 0x7e6d, 0x2f7e, 0x7e7d, 0x7e7e, 0x2d21, 0x2d22, + 0x2c7e, 0x2d23, 0x2d24, 0x2d25, 0x2c60, 0x2d26, 0x2e7c, 0x2d28, + 0x2d29, 0x2d2a, 0x2d27, 0x2d2b, 0x2d2c, 0x2c61, 0x2c62, 0x2d2d, + 0x2d2e, 0x2d7d, 0x7b2c, 0x7b2d, 0x7b2f, 0x7b30, 0x2c30, 0x7b31, + 0x2f67, 0x7e50, 0x7e78, 0x2e7a, 0x2d3e, 0x2c71, 0x2d3f, 0x2d40, + 0x2d42, 0x2d41, 0x7b62, 0x7d77, 0x7d78, 0x2e6d, 0x2d77, 0x7d79, + 0x7d7a, 0x7c57, 0x2c5b, 0x7c58, 0x2e56, 0x7c59, 0x2d43, 0x2d44, + 0x2d45, 0x2d46, 0x2d47, 0x2d48, 0x2d49, 0x2d4a, 0x2c3e, 0x2d4b, + 0x7b40, 0x7b41, 0x7b42, 0x7b43, 0x7b44, 0x2d68, 0x7b45, 0x2c45, + 0x7b46, 0x2d4c, 0x2d4d, 0x2f79, 0x2c56, 0x2c72, 0x2d2f, 0x2d30, + 0x2d31, 0x2d32, 0x2d33, 0x2d34, 0x2d35, 0x2d36, 0x2e71, 0x2d37, + 0x2d38, 0x2d39, 0x2d3a, 0x2d3b, 0x2d3c, 0x2d3d, 0x2c63, 0x7d5c, + 0x7d5d, 0x7d5e, 0x7d5f, 0x2c64, 0x7d60, 0x2c65, 0x7d61, 0x7d62, + 0x7d63, 0x7d64, 0x7d65, 0x2c66, 0x2c67, 0x7d66, 0x7d67, 0x7d68, + 0x7d69, 0x7d6a, 0x2d4f, 0x2d51, 0x7a26, 0x2e7b, 0x2d52, 0x2c73, + 0x2c74, 0x7e7b, 0x7e7c, 0x2b40, +}; + +static const Summary16 isoir165ext_uni2indx_page00[32] = { + /* 0x0000 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x3700 }, { 5, 0x160c }, + /* 0x0100 */ + { 10, 0x0000 }, { 10, 0x0808 }, { 12, 0x0800 }, { 13, 0x0000 }, + { 13, 0x2110 }, { 16, 0x0000 }, { 16, 0x0800 }, { 17, 0x0000 }, + { 17, 0x0000 }, { 17, 0x0000 }, { 17, 0x0000 }, { 17, 0x0000 }, + { 17, 0x0000 }, { 17, 0x1555 }, { 24, 0x0000 }, { 24, 0x0200 }, +}; +static const Summary16 isoir165ext_uni2indx_page03[12] = { + /* 0x0300 */ + { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x0000 }, + { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x0000 }, + { 25, 0x0000 }, { 25, 0x0000 }, { 25, 0x1000 }, { 26, 0x0002 }, +}; +static const Summary16 isoir165ext_uni2indx_page1e[28] = { + /* 0x1e00 */ + { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x0000 }, { 27, 0x8000 }, + { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0000 }, + { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0000 }, + { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0000 }, + /* 0x1f00 */ + { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0000 }, + { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0000 }, { 28, 0x0001 }, + { 29, 0x0000 }, { 29, 0x0000 }, { 29, 0x0000 }, { 29, 0x0003 }, +}; +static const Summary16 isoir165ext_uni2indx_page30[4] = { + /* 0x3000 */ + { 31, 0x0000 }, { 31, 0x0000 }, { 31, 0x0000 }, { 31, 0x0080 }, +}; +static const Summary16 isoir165ext_uni2indx_page32[32] = { + /* 0x3200 */ + { 32, 0x0000 }, { 32, 0x0000 }, { 32, 0x0000 }, { 32, 0x0000 }, + { 32, 0x0000 }, { 32, 0x0000 }, { 32, 0x0000 }, { 32, 0x0000 }, + { 32, 0x0000 }, { 32, 0x0000 }, { 32, 0x0000 }, { 32, 0x0000 }, + { 32, 0x0fff }, { 44, 0x0000 }, { 44, 0x0000 }, { 44, 0x0000 }, + /* 0x3300 */ + { 44, 0x0000 }, { 44, 0x0000 }, { 44, 0x0000 }, { 44, 0x0000 }, + { 44, 0x0000 }, { 44, 0xff00 }, { 52, 0xffff }, { 68, 0x0001 }, + { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0x0000 }, + { 69, 0x0000 }, { 69, 0x0000 }, { 69, 0xffff }, { 85, 0x7fff }, +}; +static const Summary16 isoir165ext_uni2indx_page4e[752] = { + /* 0x4e00 */ + { 100, 0x8000 }, { 101, 0x0000 }, { 101, 0x0040 }, { 102, 0x0000 }, + { 102, 0x0004 }, { 103, 0x0000 }, { 103, 0x0000 }, { 103, 0x0000 }, + { 103, 0x0020 }, { 104, 0x0000 }, { 104, 0x0000 }, { 104, 0x0140 }, + { 106, 0x0000 }, { 106, 0x0000 }, { 106, 0x0000 }, { 106, 0x0000 }, + /* 0x4f00 */ + { 106, 0x0808 }, { 108, 0x0020 }, { 109, 0x000a }, { 111, 0x4800 }, + { 113, 0x0000 }, { 113, 0x0000 }, { 113, 0x0802 }, { 115, 0x0400 }, + { 116, 0x0000 }, { 116, 0x0000 }, { 116, 0x0004 }, { 117, 0x0010 }, + { 118, 0x0000 }, { 118, 0x0000 }, { 118, 0x0800 }, { 119, 0x0060 }, + /* 0x5000 */ + { 121, 0x0000 }, { 121, 0x4000 }, { 122, 0x0004 }, { 123, 0x0010 }, + { 124, 0x0000 }, { 124, 0x0000 }, { 124, 0x0000 }, { 124, 0x0004 }, + { 125, 0x0000 }, { 125, 0x0006 }, { 127, 0x0010 }, { 128, 0x0000 }, + { 128, 0x2080 }, { 130, 0x0000 }, { 130, 0x0000 }, { 130, 0x0001 }, + /* 0x5100 */ + { 131, 0x0000 }, { 131, 0x0000 }, { 131, 0x0000 }, { 131, 0x0000 }, + { 131, 0x0000 }, { 131, 0x0000 }, { 131, 0x0000 }, { 131, 0x0000 }, + { 131, 0x8080 }, { 133, 0x0000 }, { 133, 0x4100 }, { 135, 0x0000 }, + { 135, 0x0008 }, { 136, 0x0000 }, { 136, 0x0000 }, { 136, 0x0000 }, + /* 0x5200 */ + { 136, 0x0000 }, { 136, 0x0000 }, { 136, 0x1000 }, { 137, 0x0004 }, + { 138, 0x0020 }, { 139, 0x0000 }, { 139, 0x0000 }, { 139, 0x0000 }, + { 139, 0x0000 }, { 139, 0x0100 }, { 140, 0x0000 }, { 140, 0x1a00 }, + { 143, 0x2000 }, { 144, 0x0400 }, { 145, 0x0000 }, { 145, 0x0088 }, + /* 0x5300 */ + { 147, 0x0400 }, { 148, 0x1000 }, { 149, 0x0000 }, { 149, 0x0000 }, + { 149, 0x0000 }, { 149, 0x0000 }, { 149, 0x0000 }, { 149, 0x0000 }, + { 149, 0x0000 }, { 149, 0x0001 }, { 150, 0x0000 }, { 150, 0x4000 }, + { 151, 0x00c0 }, { 153, 0x0000 }, { 153, 0x0000 }, { 153, 0x0000 }, + /* 0x5400 */ + { 153, 0x0000 }, { 153, 0x0000 }, { 153, 0x0000 }, { 153, 0x0000 }, + { 153, 0x0000 }, { 153, 0x0000 }, { 153, 0x0000 }, { 153, 0x0000 }, + { 153, 0x0000 }, { 153, 0x0000 }, { 153, 0x0020 }, { 154, 0x0000 }, + { 154, 0x0000 }, { 154, 0x0000 }, { 154, 0x0000 }, { 154, 0x0000 }, + /* 0x5500 */ + { 154, 0x0000 }, { 154, 0x2000 }, { 155, 0x0000 }, { 155, 0x0040 }, + { 156, 0x2000 }, { 157, 0x0080 }, { 158, 0x8000 }, { 159, 0x0011 }, + { 161, 0x0040 }, { 162, 0x0000 }, { 162, 0x0010 }, { 163, 0x0000 }, + { 163, 0x0000 }, { 163, 0x0000 }, { 163, 0x0000 }, { 163, 0x0000 }, + /* 0x5600 */ + { 163, 0x0000 }, { 163, 0x0000 }, { 163, 0x0000 }, { 163, 0x0000 }, + { 163, 0x0001 }, { 164, 0x0000 }, { 164, 0x0000 }, { 164, 0x0000 }, + { 164, 0x0010 }, { 165, 0x1400 }, { 167, 0x2000 }, { 168, 0x0000 }, + { 168, 0x0000 }, { 168, 0x0000 }, { 168, 0x0000 }, { 168, 0x0080 }, + /* 0x5700 */ + { 169, 0x0000 }, { 169, 0x0201 }, { 171, 0x0000 }, { 171, 0x0000 }, + { 171, 0x0000 }, { 171, 0x0000 }, { 171, 0x1000 }, { 172, 0x8001 }, + { 174, 0x0080 }, { 175, 0xc420 }, { 179, 0x0000 }, { 179, 0x4002 }, + { 181, 0x1000 }, { 182, 0x0000 }, { 182, 0x0800 }, { 183, 0x0020 }, + /* 0x5800 */ + { 184, 0x5208 }, { 188, 0x0000 }, { 188, 0x0000 }, { 188, 0x3000 }, + { 190, 0x016c }, { 195, 0x2408 }, { 198, 0x0000 }, { 198, 0x0002 }, + { 199, 0x0110 }, { 201, 0x0020 }, { 202, 0x0000 }, { 202, 0x0000 }, + { 202, 0x0000 }, { 202, 0x0000 }, { 202, 0x0000 }, { 202, 0x0100 }, + /* 0x5900 */ + { 203, 0x0040 }, { 204, 0x0001 }, { 205, 0x1000 }, { 206, 0x0000 }, + { 206, 0x0001 }, { 207, 0x0008 }, { 208, 0x2000 }, { 209, 0x0000 }, + { 209, 0x0000 }, { 209, 0x0000 }, { 209, 0x0000 }, { 209, 0x0008 }, + { 210, 0x0000 }, { 210, 0x4000 }, { 211, 0x4000 }, { 212, 0x2000 }, + /* 0x5a00 */ + { 213, 0x0000 }, { 213, 0x0004 }, { 214, 0x0000 }, { 214, 0x0000 }, + { 214, 0x0000 }, { 214, 0x4000 }, { 215, 0x0020 }, { 216, 0x1008 }, + { 218, 0x0010 }, { 219, 0x4040 }, { 221, 0x6000 }, { 223, 0x0000 }, + { 223, 0x0010 }, { 224, 0x0400 }, { 225, 0x0400 }, { 226, 0x0000 }, + /* 0x5b00 */ + { 226, 0x0000 }, { 226, 0x0800 }, { 227, 0x0000 }, { 227, 0x0000 }, + { 227, 0x0008 }, { 228, 0x0040 }, { 229, 0x0000 }, { 229, 0x0000 }, + { 229, 0x0000 }, { 229, 0x0000 }, { 229, 0x1080 }, { 231, 0x0000 }, + { 231, 0x0000 }, { 231, 0x0000 }, { 231, 0x0000 }, { 231, 0x0000 }, + /* 0x5c00 */ + { 231, 0x0020 }, { 232, 0x0000 }, { 232, 0x0400 }, { 233, 0x0001 }, + { 234, 0x0000 }, { 234, 0x2000 }, { 235, 0x0000 }, { 235, 0x1014 }, + { 238, 0x0000 }, { 238, 0x4000 }, { 239, 0x0100 }, { 240, 0x0000 }, + { 240, 0x0088 }, { 242, 0x0008 }, { 243, 0x0088 }, { 245, 0x8002 }, + /* 0x5d00 */ + { 247, 0x1031 }, { 251, 0x8602 }, { 255, 0x0000 }, { 255, 0x0000 }, + { 255, 0x4000 }, { 256, 0x0400 }, { 257, 0x0000 }, { 257, 0x0000 }, + { 257, 0x0020 }, { 258, 0x000c }, { 260, 0x0000 }, { 260, 0x0000 }, + { 260, 0x0204 }, { 262, 0x0040 }, { 263, 0x0000 }, { 263, 0x0000 }, + /* 0x5e00 */ + { 263, 0x0800 }, { 264, 0x0080 }, { 265, 0x0102 }, { 267, 0x0000 }, + { 267, 0x0000 }, { 267, 0x0000 }, { 267, 0x0400 }, { 268, 0x0000 }, + { 268, 0x0000 }, { 268, 0x0000 }, { 268, 0x0010 }, { 269, 0x1000 }, + { 270, 0x0900 }, { 272, 0x0000 }, { 272, 0x0000 }, { 272, 0x0000 }, + /* 0x5f00 */ + { 272, 0x7080 }, { 276, 0x0000 }, { 276, 0x0004 }, { 277, 0x0000 }, + { 277, 0x0000 }, { 277, 0x8000 }, { 278, 0x0180 }, { 280, 0x0000 }, + { 280, 0x0000 }, { 280, 0x0000 }, { 280, 0x9000 }, { 282, 0x0000 }, + { 282, 0x0000 }, { 282, 0x0000 }, { 282, 0x0000 }, { 282, 0x0000 }, + /* 0x6000 */ + { 282, 0x0000 }, { 282, 0x0080 }, { 283, 0x0000 }, { 283, 0x0000 }, + { 283, 0x0000 }, { 283, 0x0000 }, { 283, 0x0000 }, { 283, 0x0000 }, + { 283, 0x0000 }, { 283, 0x0000 }, { 283, 0x4000 }, { 284, 0x0001 }, + { 285, 0x0080 }, { 286, 0x0208 }, { 288, 0x0000 }, { 288, 0x0000 }, + /* 0x6100 */ + { 288, 0x0000 }, { 288, 0x0010 }, { 289, 0x0000 }, { 289, 0x0000 }, + { 289, 0x0000 }, { 289, 0x0008 }, { 290, 0x0020 }, { 291, 0x0000 }, + { 291, 0x0000 }, { 291, 0x0000 }, { 291, 0x0000 }, { 291, 0x0000 }, + { 291, 0x0000 }, { 291, 0x0000 }, { 291, 0x0000 }, { 291, 0x0000 }, + /* 0x6200 */ + { 291, 0x0000 }, { 291, 0x0000 }, { 291, 0x0000 }, { 291, 0x0000 }, + { 291, 0x0460 }, { 294, 0x0000 }, { 294, 0x0003 }, { 296, 0x0000 }, + { 296, 0x0008 }, { 297, 0x0010 }, { 298, 0x0000 }, { 298, 0x0000 }, + { 298, 0x0008 }, { 299, 0x0000 }, { 299, 0x0010 }, { 300, 0x0000 }, + /* 0x6300 */ + { 300, 0x0000 }, { 300, 0x1000 }, { 301, 0x0040 }, { 302, 0x1000 }, + { 303, 0x0000 }, { 303, 0x0000 }, { 303, 0x0000 }, { 303, 0x0000 }, + { 303, 0x0000 }, { 303, 0x0000 }, { 303, 0x8000 }, { 304, 0x0002 }, + { 305, 0x0000 }, { 305, 0x0000 }, { 305, 0x0000 }, { 305, 0x4000 }, + /* 0x6400 */ + { 306, 0x0000 }, { 306, 0x0004 }, { 307, 0x0084 }, { 309, 0x0000 }, + { 309, 0x0000 }, { 309, 0x0000 }, { 309, 0x0000 }, { 309, 0x2080 }, + { 311, 0x0000 }, { 311, 0x0000 }, { 311, 0x0000 }, { 311, 0x0000 }, + { 311, 0x0000 }, { 311, 0x0000 }, { 311, 0x2000 }, { 312, 0x0000 }, + /* 0x6500 */ + { 312, 0x0000 }, { 312, 0x0000 }, { 312, 0x0000 }, { 312, 0x0000 }, + { 312, 0x0000 }, { 312, 0x1000 }, { 313, 0x0200 }, { 314, 0x0000 }, + { 314, 0x8000 }, { 315, 0x2000 }, { 316, 0x0104 }, { 318, 0x0000 }, + { 318, 0x0004 }, { 319, 0x0000 }, { 319, 0x0000 }, { 319, 0x0900 }, + /* 0x6600 */ + { 321, 0x0280 }, { 323, 0x0000 }, { 323, 0x0000 }, { 323, 0x2000 }, + { 324, 0x0000 }, { 324, 0x4000 }, { 325, 0x1084 }, { 328, 0x0008 }, + { 329, 0x6800 }, { 332, 0x0000 }, { 332, 0x0000 }, { 332, 0x0000 }, + { 332, 0x0000 }, { 332, 0x0000 }, { 332, 0x0000 }, { 332, 0x0000 }, + /* 0x6700 */ + { 332, 0x0000 }, { 332, 0x0108 }, { 334, 0x0000 }, { 334, 0x8000 }, + { 335, 0x0020 }, { 336, 0x0000 }, { 336, 0x0080 }, { 337, 0x0800 }, + { 338, 0x0000 }, { 338, 0x8200 }, { 340, 0x0000 }, { 340, 0x0000 }, + { 340, 0x0100 }, { 341, 0x0000 }, { 341, 0x4000 }, { 342, 0x0000 }, + /* 0x6800 */ + { 342, 0x0000 }, { 342, 0x8004 }, { 344, 0x0000 }, { 344, 0x0000 }, + { 344, 0x0800 }, { 345, 0x0000 }, { 345, 0x9400 }, { 348, 0x0000 }, + { 348, 0x0000 }, { 348, 0x0000 }, { 348, 0x0001 }, { 349, 0x9002 }, + { 352, 0x0002 }, { 353, 0x000b }, { 356, 0x1900 }, { 359, 0x0900 }, + /* 0x6900 */ + { 361, 0x0000 }, { 361, 0x200a }, { 364, 0x0800 }, { 365, 0x0020 }, + { 366, 0x0001 }, { 367, 0x8200 }, { 369, 0x8204 }, { 372, 0x0000 }, + { 372, 0x0008 }, { 373, 0x0040 }, { 374, 0x0000 }, { 374, 0x5000 }, + { 376, 0x0020 }, { 377, 0x1400 }, { 379, 0x0020 }, { 380, 0x4000 }, + /* 0x6a00 */ + { 381, 0x0800 }, { 382, 0x0002 }, { 383, 0x0000 }, { 383, 0x0000 }, + { 383, 0x0000 }, { 383, 0x0000 }, { 383, 0x0040 }, { 384, 0x0000 }, + { 384, 0x0000 }, { 384, 0x0040 }, { 385, 0x0000 }, { 385, 0x0030 }, + { 387, 0x0000 }, { 387, 0x0000 }, { 387, 0x0000 }, { 387, 0x0000 }, + /* 0x6b00 */ + { 387, 0x0000 }, { 387, 0x0000 }, { 387, 0x0000 }, { 387, 0x0100 }, + { 388, 0x0000 }, { 388, 0x0010 }, { 389, 0x0000 }, { 389, 0x0000 }, + { 389, 0x0000 }, { 389, 0x0020 }, { 390, 0x0008 }, { 391, 0x0000 }, + { 391, 0x0000 }, { 391, 0x0400 }, { 392, 0x0000 }, { 392, 0x0000 }, + /* 0x6c00 */ + { 392, 0x0000 }, { 392, 0x2000 }, { 393, 0x0020 }, { 394, 0xc000 }, + { 396, 0x0000 }, { 396, 0x0000 }, { 396, 0x2080 }, { 398, 0x0000 }, + { 398, 0x0090 }, { 400, 0x0540 }, { 403, 0x0100 }, { 404, 0x0020 }, + { 405, 0x0048 }, { 407, 0x1000 }, { 408, 0x0000 }, { 408, 0x0000 }, + /* 0x6d00 */ + { 408, 0x0000 }, { 408, 0x0002 }, { 409, 0x0300 }, { 411, 0x0510 }, + { 414, 0x0210 }, { 416, 0x0821 }, { 419, 0x0032 }, { 422, 0x0000 }, + { 422, 0x0000 }, { 422, 0x0000 }, { 422, 0x2004 }, { 424, 0x0010 }, + { 425, 0x0000 }, { 425, 0x0000 }, { 425, 0x0000 }, { 425, 0x0000 }, + /* 0x6e00 */ + { 425, 0x0000 }, { 425, 0x0800 }, { 426, 0x0000 }, { 426, 0x0000 }, + { 426, 0x0000 }, { 426, 0x3000 }, { 428, 0x0080 }, { 429, 0x0004 }, + { 430, 0x4082 }, { 433, 0x0400 }, { 434, 0x0041 }, { 436, 0x0020 }, + { 437, 0x0208 }, { 439, 0x0100 }, { 440, 0x0c80 }, { 443, 0x0000 }, + /* 0x6f00 */ + { 443, 0x0000 }, { 443, 0x0000 }, { 443, 0x0040 }, { 444, 0x0080 }, + { 445, 0x0000 }, { 445, 0x8040 }, { 447, 0x0000 }, { 447, 0x0020 }, + { 448, 0x0004 }, { 449, 0x0810 }, { 451, 0x0020 }, { 452, 0x1010 }, + { 454, 0x0000 }, { 454, 0x0000 }, { 454, 0x1000 }, { 455, 0x0000 }, + /* 0x7000 */ + { 455, 0x3000 }, { 457, 0x0010 }, { 458, 0x0000 }, { 458, 0x1000 }, + { 459, 0x0000 }, { 459, 0x0000 }, { 459, 0x0000 }, { 459, 0x0400 }, + { 460, 0x0000 }, { 460, 0x4100 }, { 462, 0x0000 }, { 462, 0x0000 }, + { 462, 0x0000 }, { 462, 0x3000 }, { 464, 0x0000 }, { 464, 0x0402 }, + /* 0x7100 */ + { 466, 0x1000 }, { 467, 0x1000 }, { 468, 0x4001 }, { 470, 0x0000 }, + { 470, 0x0000 }, { 470, 0x0000 }, { 470, 0x0000 }, { 470, 0x0000 }, + { 470, 0x0000 }, { 470, 0x0000 }, { 470, 0x0000 }, { 470, 0x0000 }, + { 470, 0x8c00 }, { 473, 0x0000 }, { 473, 0x0000 }, { 473, 0x8000 }, + /* 0x7200 */ + { 474, 0x0000 }, { 474, 0x8000 }, { 475, 0x0000 }, { 475, 0x0000 }, + { 475, 0x0006 }, { 477, 0x0400 }, { 478, 0x0008 }, { 479, 0x0080 }, + { 480, 0x0080 }, { 481, 0x0000 }, { 481, 0x0100 }, { 482, 0x0000 }, + { 482, 0x0200 }, { 483, 0x2000 }, { 484, 0x0004 }, { 485, 0x0000 }, + /* 0x7300 */ + { 485, 0x0040 }, { 486, 0x0010 }, { 487, 0x0000 }, { 487, 0x0400 }, + { 488, 0x0000 }, { 488, 0x0000 }, { 488, 0x0000 }, { 488, 0x0000 }, + { 488, 0x0000 }, { 488, 0x0630 }, { 492, 0x0061 }, { 495, 0x0002 }, + { 496, 0x0000 }, { 496, 0x0040 }, { 497, 0x4408 }, { 500, 0x2441 }, + /* 0x7400 */ + { 504, 0x4080 }, { 506, 0x0020 }, { 507, 0x8810 }, { 510, 0x0084 }, + { 512, 0x0014 }, { 514, 0x0010 }, { 515, 0x0004 }, { 516, 0x0102 }, + { 518, 0x0140 }, { 520, 0x8100 }, { 522, 0x0401 }, { 524, 0x0004 }, + { 525, 0x0000 }, { 525, 0x0100 }, { 526, 0x0000 }, { 526, 0x0800 }, + /* 0x7500 */ + { 527, 0x0008 }, { 528, 0x0000 }, { 528, 0x0442 }, { 531, 0x0000 }, + { 531, 0x0000 }, { 531, 0x0002 }, { 532, 0x9010 }, { 535, 0x0000 }, + { 535, 0x0000 }, { 535, 0x0000 }, { 535, 0x0004 }, { 536, 0x0000 }, + { 536, 0x0000 }, { 536, 0x0000 }, { 536, 0x0001 }, { 537, 0x0008 }, + /* 0x7600 */ + { 538, 0x0110 }, { 540, 0x2000 }, { 541, 0x0000 }, { 541, 0x0000 }, + { 541, 0x0000 }, { 541, 0x0004 }, { 542, 0x0000 }, { 542, 0x8040 }, + { 544, 0x0000 }, { 544, 0x4000 }, { 545, 0x0000 }, { 545, 0x0000 }, + { 545, 0x0000 }, { 545, 0x2000 }, { 546, 0x1440 }, { 549, 0x0800 }, + /* 0x7700 */ + { 550, 0x0400 }, { 551, 0x0800 }, { 552, 0x1000 }, { 553, 0x0000 }, + { 553, 0x0000 }, { 553, 0x0000 }, { 553, 0x0000 }, { 553, 0x0000 }, + { 553, 0x0840 }, { 555, 0x0000 }, { 555, 0x2800 }, { 557, 0x0000 }, + { 557, 0x0000 }, { 557, 0x4000 }, { 558, 0x0000 }, { 558, 0x1800 }, + /* 0x7800 */ + { 560, 0x0040 }, { 561, 0x0000 }, { 561, 0x0005 }, { 563, 0x0000 }, + { 563, 0x0002 }, { 564, 0x0600 }, { 566, 0x0000 }, { 566, 0x0020 }, + { 567, 0x0000 }, { 567, 0x0010 }, { 568, 0x0000 }, { 568, 0x0040 }, + { 569, 0x0000 }, { 569, 0x1000 }, { 570, 0x0002 }, { 571, 0x0000 }, + /* 0x7900 */ + { 571, 0x0008 }, { 572, 0x0000 }, { 572, 0x0000 }, { 572, 0x2008 }, + { 574, 0x4488 }, { 578, 0x0001 }, { 579, 0x0000 }, { 579, 0x1004 }, + { 581, 0x0000 }, { 581, 0x0100 }, { 582, 0x0011 }, { 584, 0x0100 }, + { 585, 0x0000 }, { 585, 0x0000 }, { 585, 0x0000 }, { 585, 0x4000 }, + /* 0x7a00 */ + { 586, 0x0000 }, { 586, 0x0040 }, { 587, 0x0000 }, { 587, 0x0000 }, + { 587, 0x0010 }, { 588, 0x4000 }, { 589, 0x0000 }, { 589, 0x0000 }, + { 589, 0x4020 }, { 591, 0x0000 }, { 591, 0x0008 }, { 592, 0x4100 }, + { 594, 0x0000 }, { 594, 0x1002 }, { 596, 0x0000 }, { 596, 0x0000 }, + /* 0x7b00 */ + { 596, 0x0000 }, { 596, 0x0000 }, { 596, 0x0000 }, { 596, 0x0000 }, + { 596, 0x4400 }, { 598, 0x1000 }, { 599, 0x0000 }, { 599, 0x8000 }, + { 600, 0x0080 }, { 601, 0x0008 }, { 602, 0x0000 }, { 602, 0x0000 }, + { 602, 0x0000 }, { 602, 0x0000 }, { 602, 0x8000 }, { 603, 0x0005 }, + /* 0x7c00 */ + { 605, 0x0208 }, { 607, 0x0020 }, { 608, 0x0001 }, { 609, 0x0001 }, + { 610, 0x0000 }, { 610, 0x2001 }, { 612, 0x0000 }, { 612, 0x0000 }, + { 612, 0x0000 }, { 612, 0x0000 }, { 612, 0x1040 }, { 614, 0x0000 }, + { 614, 0x0000 }, { 614, 0x0000 }, { 614, 0x0000 }, { 614, 0x0020 }, +}; +static const Summary16 isoir165ext_uni2indx_page7e[333] = { + /* 0x7e00 */ + { 615, 0x0000 }, { 615, 0x0000 }, { 615, 0x0000 }, { 615, 0x0000 }, + { 615, 0x0010 }, { 616, 0x0000 }, { 616, 0x0000 }, { 616, 0x0000 }, + { 616, 0x0000 }, { 616, 0x0000 }, { 616, 0x4000 }, { 617, 0x1810 }, + { 620, 0x0000 }, { 620, 0x0040 }, { 621, 0x1010 }, { 623, 0x0200 }, + /* 0x7f00 */ + { 624, 0x0400 }, { 625, 0x4001 }, { 627, 0x0000 }, { 627, 0x0000 }, + { 627, 0x2000 }, { 628, 0x0000 }, { 628, 0x0000 }, { 628, 0x2000 }, + { 629, 0x0000 }, { 629, 0x0002 }, { 630, 0x0000 }, { 630, 0x0000 }, + { 630, 0x0001 }, { 631, 0x0600 }, { 633, 0x8000 }, { 634, 0x0000 }, + /* 0x8000 */ + { 634, 0x0000 }, { 634, 0x0000 }, { 634, 0x0000 }, { 634, 0x0001 }, + { 635, 0x0000 }, { 635, 0x0000 }, { 635, 0x0000 }, { 635, 0x0000 }, + { 635, 0x0000 }, { 635, 0x0000 }, { 635, 0x0000 }, { 635, 0x0000 }, + { 635, 0x0000 }, { 635, 0x0010 }, { 636, 0x0000 }, { 636, 0x4000 }, + /* 0x8100 */ + { 637, 0x0000 }, { 637, 0x0000 }, { 637, 0x0200 }, { 638, 0x8000 }, + { 639, 0x0000 }, { 639, 0x0104 }, { 641, 0x0000 }, { 641, 0x0000 }, + { 641, 0x0000 }, { 641, 0x0000 }, { 641, 0x0000 }, { 641, 0x0000 }, + { 641, 0x0000 }, { 641, 0x0002 }, { 642, 0x0000 }, { 642, 0x0000 }, + /* 0x8200 */ + { 642, 0x0000 }, { 642, 0x0140 }, { 644, 0x0000 }, { 644, 0x0400 }, + { 645, 0x0000 }, { 645, 0x0000 }, { 645, 0x0000 }, { 645, 0x0100 }, + { 646, 0x0008 }, { 647, 0x0000 }, { 647, 0x0080 }, { 648, 0x1000 }, + { 649, 0x0000 }, { 649, 0x0000 }, { 649, 0x0000 }, { 649, 0x4000 }, + /* 0x8300 */ + { 650, 0x0001 }, { 651, 0x2008 }, { 653, 0x0000 }, { 653, 0x0000 }, + { 653, 0x0030 }, { 655, 0x2000 }, { 656, 0x0000 }, { 656, 0x0000 }, + { 656, 0x0000 }, { 656, 0x0200 }, { 657, 0x0040 }, { 658, 0x0000 }, + { 658, 0x0000 }, { 658, 0x0002 }, { 659, 0x0000 }, { 659, 0x5000 }, + /* 0x8400 */ + { 661, 0x0000 }, { 661, 0x0400 }, { 662, 0x0200 }, { 663, 0x0200 }, + { 664, 0x0000 }, { 664, 0x0008 }, { 665, 0x0001 }, { 666, 0x0000 }, + { 666, 0x0000 }, { 666, 0xc000 }, { 668, 0x0100 }, { 669, 0x0000 }, + { 669, 0x8044 }, { 672, 0x0000 }, { 672, 0x0400 }, { 673, 0x0080 }, + /* 0x8500 */ + { 674, 0x0000 }, { 674, 0x0000 }, { 674, 0x0000 }, { 674, 0x0010 }, + { 675, 0x0000 }, { 675, 0x0000 }, { 675, 0x0000 }, { 675, 0x0001 }, + { 676, 0x0000 }, { 676, 0x0000 }, { 676, 0x0004 }, { 677, 0x0108 }, + { 679, 0x0000 }, { 679, 0x0000 }, { 679, 0x0001 }, { 680, 0x0000 }, + /* 0x8600 */ + { 680, 0x0000 }, { 680, 0x0000 }, { 680, 0x0000 }, { 680, 0x0000 }, + { 680, 0x0000 }, { 680, 0x0004 }, { 681, 0x0000 }, { 681, 0x0000 }, + { 681, 0x0008 }, { 682, 0x0000 }, { 682, 0x0000 }, { 682, 0x0000 }, + { 682, 0x0000 }, { 682, 0x0000 }, { 682, 0x0000 }, { 682, 0x0000 }, + /* 0x8700 */ + { 682, 0x4020 }, { 684, 0x0000 }, { 684, 0x0000 }, { 684, 0x0000 }, + { 684, 0x0000 }, { 684, 0x0100 }, { 685, 0x0000 }, { 685, 0x0000 }, + { 685, 0x0001 }, { 686, 0x0000 }, { 686, 0x0008 }, { 687, 0x0000 }, + { 687, 0x8000 }, { 688, 0x0000 }, { 688, 0x0004 }, { 689, 0x0000 }, + /* 0x8800 */ + { 689, 0x0800 }, { 690, 0x0000 }, { 690, 0x2000 }, { 691, 0x0000 }, + { 691, 0x0000 }, { 691, 0x0004 }, { 692, 0x0000 }, { 692, 0x0000 }, + { 692, 0x0040 }, { 693, 0x0080 }, { 694, 0x8400 }, { 696, 0x0000 }, + { 696, 0x0101 }, { 698, 0x0000 }, { 698, 0x0000 }, { 698, 0x0000 }, + /* 0x8900 */ + { 698, 0x0000 }, { 698, 0x0000 }, { 698, 0x0040 }, { 699, 0x0000 }, + { 699, 0x0000 }, { 699, 0x0020 }, { 700, 0x0000 }, { 700, 0x0040 }, + { 701, 0x0001 }, { 702, 0x0000 }, { 702, 0x0000 }, { 702, 0x0000 }, + { 702, 0x2008 }, { 704, 0x0010 }, { 705, 0x0000 }, { 705, 0x0002 }, + /* 0x8a00 */ + { 706, 0x0000 }, { 706, 0x0400 }, { 707, 0x0000 }, { 707, 0x0000 }, + { 707, 0x0000 }, { 707, 0x8000 }, { 708, 0x0000 }, { 708, 0x0000 }, + { 708, 0x0000 }, { 708, 0x0000 }, { 708, 0x0000 }, { 708, 0x0000 }, + { 708, 0x0000 }, { 708, 0x0000 }, { 708, 0x0000 }, { 708, 0x0000 }, + /* 0x8b00 */ + { 708, 0x0000 }, { 708, 0x0000 }, { 708, 0x0000 }, { 708, 0x0000 }, + { 708, 0x0000 }, { 708, 0x0000 }, { 708, 0x0000 }, { 708, 0x0000 }, + { 708, 0x0000 }, { 708, 0x0000 }, { 708, 0x1000 }, { 709, 0x0802 }, + { 711, 0x0080 }, { 712, 0x0000 }, { 712, 0x0400 }, { 713, 0x0000 }, + /* 0x8c00 */ + { 713, 0x0200 }, { 714, 0x4000 }, { 715, 0x0000 }, { 715, 0x0000 }, + { 715, 0x0000 }, { 715, 0x0000 }, { 715, 0x6100 }, { 718, 0x0000 }, + { 718, 0x0040 }, { 719, 0x0000 }, { 719, 0x0000 }, { 719, 0x0000 }, + { 719, 0x0000 }, { 719, 0x0000 }, { 719, 0x0000 }, { 719, 0x0000 }, + /* 0x8d00 */ + { 719, 0x0000 }, { 719, 0x0000 }, { 719, 0x0001 }, { 720, 0x0000 }, + { 720, 0x0000 }, { 720, 0x8086 }, { 724, 0x0400 }, { 725, 0x0000 }, + { 725, 0x0000 }, { 725, 0x0000 }, { 725, 0x0000 }, { 725, 0x0000 }, + { 725, 0x0000 }, { 725, 0x0000 }, { 725, 0x0000 }, { 725, 0x0000 }, + /* 0x8e00 */ + { 725, 0x0000 }, { 725, 0x0040 }, { 726, 0x00c2 }, { 729, 0x0040 }, + { 730, 0x0020 }, { 731, 0x1009 }, { 734, 0x0004 }, { 735, 0x0000 }, + { 735, 0x0000 }, { 735, 0x0000 }, { 735, 0x2000 }, { 736, 0x0000 }, + { 736, 0x0000 }, { 736, 0x0000 }, { 736, 0x0000 }, { 736, 0x0000 }, + /* 0x8f00 */ + { 736, 0x0000 }, { 736, 0x0000 }, { 736, 0x0000 }, { 736, 0x0000 }, + { 736, 0x0000 }, { 736, 0x0000 }, { 736, 0x0000 }, { 736, 0x0000 }, + { 736, 0x0001 }, { 737, 0x0004 }, { 738, 0x0000 }, { 738, 0x0020 }, + { 739, 0x0000 }, { 739, 0x0000 }, { 739, 0x0000 }, { 739, 0x0400 }, + /* 0x9000 */ + { 740, 0x0000 }, { 740, 0x0000 }, { 740, 0x0000 }, { 740, 0x0000 }, + { 740, 0x0000 }, { 740, 0x0000 }, { 740, 0x0000 }, { 740, 0x0000 }, + { 740, 0x0000 }, { 740, 0x0100 }, { 741, 0x0101 }, { 743, 0x2000 }, + { 744, 0x0108 }, { 746, 0x0400 }, { 747, 0x0010 }, { 748, 0x8000 }, + /* 0x9100 */ + { 749, 0x1000 }, { 750, 0x1500 }, { 753, 0x0001 }, { 754, 0x0000 }, + { 754, 0x0004 }, { 755, 0x0000 }, { 755, 0x0000 }, { 755, 0x0000 }, + { 755, 0x0000 }, { 755, 0x0000 }, { 755, 0x0000 }, { 755, 0x0000 }, + { 755, 0x0040 }, { 756, 0x0000 }, { 756, 0x0000 }, { 756, 0x0000 }, + /* 0x9200 */ + { 756, 0x0000 }, { 756, 0x0000 }, { 756, 0x0000 }, { 756, 0x0000 }, + { 756, 0x0000 }, { 756, 0x0000 }, { 756, 0x0000 }, { 756, 0x0000 }, + { 756, 0x0000 }, { 756, 0x0000 }, { 756, 0x0000 }, { 756, 0x0000 }, + { 756, 0x0040 }, +}; +static const Summary16 isoir165ext_uni2indx_page94[143] = { + /* 0x9400 */ + { 757, 0x0000 }, { 757, 0x0000 }, { 757, 0x0000 }, { 757, 0x0000 }, + { 757, 0x0000 }, { 757, 0x0000 }, { 757, 0x0000 }, { 757, 0x0000 }, + { 757, 0x0000 }, { 757, 0x0142 }, { 760, 0x0000 }, { 760, 0x0000 }, + { 760, 0x8080 }, { 762, 0x0418 }, { 765, 0x0040 }, { 766, 0x0800 }, + /* 0x9500 */ + { 767, 0x0000 }, { 767, 0x1000 }, { 768, 0x0081 }, { 770, 0x2008 }, + { 772, 0x0008 }, { 773, 0x0400 }, { 774, 0x4001 }, { 776, 0x0030 }, + { 778, 0x0000 }, { 778, 0x0000 }, { 778, 0x0000 }, { 778, 0x0000 }, + { 778, 0x0000 }, { 778, 0x0000 }, { 778, 0x1000 }, { 779, 0x8000 }, + /* 0x9600 */ + { 780, 0x0080 }, { 781, 0x0908 }, { 784, 0x0000 }, { 784, 0x0000 }, + { 784, 0x0000 }, { 784, 0x4000 }, { 785, 0x0000 }, { 785, 0x0000 }, + { 785, 0x0000 }, { 785, 0x0000 }, { 785, 0x0000 }, { 785, 0x0000 }, + { 785, 0x0000 }, { 785, 0x0100 }, { 786, 0x0000 }, { 786, 0x0000 }, + /* 0x9700 */ + { 786, 0x0004 }, { 787, 0x0000 }, { 787, 0x0000 }, { 787, 0x0000 }, + { 787, 0x0000 }, { 787, 0x0010 }, { 788, 0x0000 }, { 788, 0x0501 }, + { 791, 0x0000 }, { 791, 0x0000 }, { 791, 0x4102 }, { 794, 0x0000 }, + { 794, 0x0000 }, { 794, 0x0000 }, { 794, 0x0100 }, { 795, 0x0000 }, + /* 0x9800 */ + { 795, 0x0000 }, { 795, 0x0000 }, { 795, 0x0000 }, { 795, 0x0000 }, + { 795, 0x0000 }, { 795, 0x0000 }, { 795, 0x0000 }, { 795, 0x0000 }, + { 795, 0x4800 }, { 797, 0x0224 }, { 800, 0x0008 }, { 801, 0x0000 }, + { 801, 0x8000 }, { 802, 0x00d1 }, { 806, 0x0000 }, { 806, 0x0000 }, + /* 0x9900 */ + { 806, 0x0000 }, { 806, 0x0000 }, { 806, 0x0000 }, { 806, 0x0000 }, + { 806, 0x0000 }, { 806, 0x0000 }, { 806, 0x0050 }, { 808, 0x4b00 }, + { 812, 0x500c }, { 816, 0x0000 }, { 816, 0x0000 }, { 816, 0x0000 }, + { 816, 0x0000 }, { 816, 0x0000 }, { 816, 0x0000 }, { 816, 0x0000 }, + /* 0x9a00 */ + { 816, 0x0000 }, { 816, 0x0000 }, { 816, 0x0000 }, { 816, 0x0000 }, + { 816, 0x0000 }, { 816, 0x0000 }, { 816, 0x0000 }, { 816, 0x0004 }, + { 817, 0x6208 }, { 821, 0x0230 }, { 824, 0x0040 }, { 825, 0x0000 }, + { 825, 0x0000 }, { 825, 0x0000 }, { 825, 0x0000 }, { 825, 0x0000 }, + /* 0x9b00 */ + { 825, 0x0000 }, { 825, 0x0101 }, { 827, 0x0020 }, { 828, 0x0040 }, + { 829, 0x0040 }, { 830, 0x0000 }, { 830, 0x0000 }, { 830, 0x0000 }, + { 830, 0x0000 }, { 830, 0x0000 }, { 830, 0x0000 }, { 830, 0x0000 }, + { 830, 0x0000 }, { 830, 0x0000 }, { 830, 0x0000 }, { 830, 0x0000 }, + /* 0x9c00 */ + { 830, 0x0000 }, { 830, 0x0000 }, { 830, 0x0000 }, { 830, 0x0000 }, + { 830, 0x0000 }, { 830, 0x0000 }, { 830, 0x0000 }, { 830, 0x0000 }, + { 830, 0x0411 }, { 833, 0x23c8 }, { 839, 0x0000 }, { 839, 0x8000 }, + { 840, 0x0003 }, { 842, 0x0804 }, { 844, 0x0009 }, +}; +static const Summary16 isoir165ext_uni2indx_page9e[25] = { + /* 0x9e00 */ + { 846, 0x0000 }, { 846, 0x0000 }, { 846, 0x4090 }, { 849, 0x0011 }, + { 851, 0x2001 }, { 853, 0x225d }, { 860, 0x8027 }, { 865, 0x0010 }, + { 866, 0x0001 }, { 867, 0x0002 }, { 868, 0x0000 }, { 868, 0x0000 }, + { 868, 0x0000 }, { 868, 0x0000 }, { 868, 0x0002 }, { 869, 0x0000 }, + /* 0x9f00 */ + { 869, 0x1000 }, { 870, 0x0004 }, { 871, 0x0800 }, { 872, 0x0000 }, + { 872, 0x0002 }, { 873, 0x0000 }, { 873, 0x0000 }, { 873, 0x0000 }, + { 873, 0x0006 }, +}; +static const Summary16 isoir165ext_uni2indx_pageff[5] = { + /* 0xff00 */ + { 875, 0x0000 }, { 875, 0x0000 }, { 875, 0x0000 }, { 875, 0x0000 }, + { 875, 0x0080 }, +}; + +static int +isoir165ext_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc >= 0x0000 && wc < 0x0200) + summary = &isoir165ext_uni2indx_page00[(wc>>4)]; + else if (wc >= 0x0300 && wc < 0x03c0) + summary = &isoir165ext_uni2indx_page03[(wc>>4)-0x030]; + else if (wc >= 0x1e00 && wc < 0x1fc0) + summary = &isoir165ext_uni2indx_page1e[(wc>>4)-0x1e0]; + else if (wc >= 0x3000 && wc < 0x3040) + summary = &isoir165ext_uni2indx_page30[(wc>>4)-0x300]; + else if (wc >= 0x3200 && wc < 0x3400) + summary = &isoir165ext_uni2indx_page32[(wc>>4)-0x320]; + else if (wc >= 0x4e00 && wc < 0x7d00) + summary = &isoir165ext_uni2indx_page4e[(wc>>4)-0x4e0]; + else if (wc >= 0x7e00 && wc < 0x92d0) + summary = &isoir165ext_uni2indx_page7e[(wc>>4)-0x7e0]; + else if (wc >= 0x9400 && wc < 0x9cf0) + summary = &isoir165ext_uni2indx_page94[(wc>>4)-0x940]; + else if (wc >= 0x9e00 && wc < 0x9f90) + summary = &isoir165ext_uni2indx_page9e[(wc>>4)-0x9e0]; + else if (wc >= 0xff00 && wc < 0xff50) + summary = &isoir165ext_uni2indx_pageff[(wc>>4)-0xff0]; + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = isoir165ext_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/java.h b/graf2d/win32gdk/gdk/src/iconv/java.h new file mode 100644 index 0000000000000..4d4485f54f1d9 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/java.h @@ -0,0 +1,137 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * JAVA + * This is ISO 8859-1 with \uXXXX escape sequences, denoting Unicode BMP + * characters. Consecutive pairs of \uXXXX escape sequences in the surrogate + * range, as in UTF-16, denote Unicode characters outside the BMP. + */ + +static int +java_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c; + ucs4_t wc, wc2; + int i; + + c = s[0]; + if (c != '\\') { + *pwc = c; + return 1; + } + if (n < 2) + return RET_TOOFEW(0); + if (s[1] != 'u') + goto simply_backslash; + wc = 0; + for (i = 2; i < 6; i++) { + if (n <= i) + return RET_TOOFEW(0); + c = s[i]; + if (c >= '0' && c <= '9') + c -= '0'; + else if (c >= 'A' && c <= 'Z') + c -= 'A'-10; + else if (c >= 'a' && c <= 'z') + c -= 'a'-10; + else + goto simply_backslash; + wc |= (ucs4_t) c << (4 * (5-i)); + } + if (!(wc >= 0xd800 && wc < 0xe000)) { + *pwc = wc; + return 6; + } + if (wc >= 0xdc00) + goto simply_backslash; + if (n < 7) + return RET_TOOFEW(0); + if (s[6] != '\\') + goto simply_backslash; + if (n < 8) + return RET_TOOFEW(0); + if (s[7] != 'u') + goto simply_backslash; + wc2 = 0; + for (i = 8; i < 12; i++) { + if (n <= i) + return RET_TOOFEW(0); + c = s[i]; + if (c >= '0' && c <= '9') + c -= '0'; + else if (c >= 'A' && c <= 'Z') + c -= 'A'-10; + else if (c >= 'a' && c <= 'z') + c -= 'a'-10; + else + goto simply_backslash; + wc2 |= (ucs4_t) c << (4 * (11-i)); + } + if (!(wc2 >= 0xdc00 && wc2 < 0xe000)) + goto simply_backslash; + *pwc = 0x10000 + ((wc - 0xd800) << 10) + (wc2 - 0xdc00); + return 12; +simply_backslash: + *pwc = '\\'; + return 1; +} + +static int +java_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x80) { + *r = wc; + return 1; + } else if (wc < 0x10000) { + if (n >= 6) { + unsigned int i; + r[0] = '\\'; + r[1] = 'u'; + i = (wc >> 12) & 0x0f; r[2] = (i < 10 ? '0'+i : 'a'-10+i); + i = (wc >> 8) & 0x0f; r[3] = (i < 10 ? '0'+i : 'a'-10+i); + i = (wc >> 4) & 0x0f; r[4] = (i < 10 ? '0'+i : 'a'-10+i); + i = wc & 0x0f; r[5] = (i < 10 ? '0'+i : 'a'-10+i); + return 6; + } else + return RET_TOOSMALL; + } else if (wc < 0x110000) { + if (n >= 12) { + ucs4_t wc1 = 0xd800 + ((wc - 0x10000) >> 10); + ucs4_t wc2 = 0xdc00 + ((wc - 0x10000) & 0x3ff); + unsigned int i; + r[0] = '\\'; + r[1] = 'u'; + i = (wc1 >> 12) & 0x0f; r[2] = (i < 10 ? '0'+i : 'a'-10+i); + i = (wc1 >> 8) & 0x0f; r[3] = (i < 10 ? '0'+i : 'a'-10+i); + i = (wc1 >> 4) & 0x0f; r[4] = (i < 10 ? '0'+i : 'a'-10+i); + i = wc1 & 0x0f; r[5] = (i < 10 ? '0'+i : 'a'-10+i); + r[6] = '\\'; + r[7] = 'u'; + i = (wc2 >> 12) & 0x0f; r[8] = (i < 10 ? '0'+i : 'a'-10+i); + i = (wc2 >> 8) & 0x0f; r[9] = (i < 10 ? '0'+i : 'a'-10+i); + i = (wc2 >> 4) & 0x0f; r[10] = (i < 10 ? '0'+i : 'a'-10+i); + i = wc2 & 0x0f; r[11] = (i < 10 ? '0'+i : 'a'-10+i); + return 12; + } else + return RET_TOOSMALL; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/jisx0201.h b/graf2d/win32gdk/gdk/src/iconv/jisx0201.h new file mode 100644 index 0000000000000..d58c1d59569a9 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/jisx0201.h @@ -0,0 +1,66 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * JISX0201.1976-0 + */ + +static int +jisx0201_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + if (c == 0x5c) + *pwc = (ucs4_t) 0x00a5; + else if (c == 0x7e) + *pwc = (ucs4_t) 0x203e; + else + *pwc = (ucs4_t) c; + return 1; + } else { + if (c >= 0xa1 && c < 0xe0) { + *pwc = (ucs4_t) c + 0xfec0; + return 1; + } + } + return RET_ILSEQ; +} + +static int +jisx0201_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x0080 && !(wc == 0x005c || wc == 0x007e)) { + *r = wc; + return 1; + } + if (wc == 0x00a5) { + *r = 0x5c; + return 1; + } + if (wc == 0x203e) { + *r = 0x7e; + return 1; + } + if (wc >= 0xff61 && wc < 0xffa0) { + *r = wc - 0xfec0; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/jisx0208.h b/graf2d/win32gdk/gdk/src/iconv/jisx0208.h new file mode 100644 index 0000000000000..755b8ba6a5caf --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/jisx0208.h @@ -0,0 +1,2415 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * JISX0208.1990-0 + */ + +static const unsigned short jisx0208_2uni_page21[690] = { + /* 0x21 */ + 0x3000, 0x3001, 0x3002, 0xff0c, 0xff0e, 0x30fb, 0xff1a, 0xff1b, + 0xff1f, 0xff01, 0x309b, 0x309c, 0x00b4, 0xff40, 0x00a8, 0xff3e, + 0xffe3, 0xff3f, 0x30fd, 0x30fe, 0x309d, 0x309e, 0x3003, 0x4edd, + 0x3005, 0x3006, 0x3007, 0x30fc, 0x2015, 0x2010, 0xff0f, 0xff3c, + 0x301c, 0x2016, 0xff5c, 0x2026, 0x2025, 0x2018, 0x2019, 0x201c, + 0x201d, 0xff08, 0xff09, 0x3014, 0x3015, 0xff3b, 0xff3d, 0xff5b, + 0xff5d, 0x3008, 0x3009, 0x300a, 0x300b, 0x300c, 0x300d, 0x300e, + 0x300f, 0x3010, 0x3011, 0xff0b, 0x2212, 0x00b1, 0x00d7, 0x00f7, + 0xff1d, 0x2260, 0xff1c, 0xff1e, 0x2266, 0x2267, 0x221e, 0x2234, + 0x2642, 0x2640, 0x00b0, 0x2032, 0x2033, 0x2103, 0xffe5, 0xff04, + 0x00a2, 0x00a3, 0xff05, 0xff03, 0xff06, 0xff0a, 0xff20, 0x00a7, + 0x2606, 0x2605, 0x25cb, 0x25cf, 0x25ce, 0x25c7, + /* 0x22 */ + 0x25c6, 0x25a1, 0x25a0, 0x25b3, 0x25b2, 0x25bd, 0x25bc, 0x203b, + 0x3012, 0x2192, 0x2190, 0x2191, 0x2193, 0x3013, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x2208, 0x220b, 0x2286, 0x2287, 0x2282, 0x2283, 0x222a, + 0x2229, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x2227, 0x2228, 0x00ac, 0x21d2, 0x21d4, 0x2200, 0x2203, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0x2220, 0x22a5, 0x2312, 0x2202, 0x2207, + 0x2261, 0x2252, 0x226a, 0x226b, 0x221a, 0x223d, 0x221d, 0x2235, + 0x222b, 0x222c, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x212b, 0x2030, 0x266f, 0x266d, 0x266a, 0x2020, 0x2021, + 0x00b6, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x25ef, + /* 0x23 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xff10, + 0xff11, 0xff12, 0xff13, 0xff14, 0xff15, 0xff16, 0xff17, 0xff18, + 0xff19, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xff21, 0xff22, 0xff23, 0xff24, 0xff25, 0xff26, 0xff27, 0xff28, + 0xff29, 0xff2a, 0xff2b, 0xff2c, 0xff2d, 0xff2e, 0xff2f, 0xff30, + 0xff31, 0xff32, 0xff33, 0xff34, 0xff35, 0xff36, 0xff37, 0xff38, + 0xff39, 0xff3a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xff41, 0xff42, 0xff43, 0xff44, 0xff45, 0xff46, 0xff47, 0xff48, + 0xff49, 0xff4a, 0xff4b, 0xff4c, 0xff4d, 0xff4e, 0xff4f, 0xff50, + 0xff51, 0xff52, 0xff53, 0xff54, 0xff55, 0xff56, 0xff57, 0xff58, + 0xff59, 0xff5a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x24 */ + 0x3041, 0x3042, 0x3043, 0x3044, 0x3045, 0x3046, 0x3047, 0x3048, + 0x3049, 0x304a, 0x304b, 0x304c, 0x304d, 0x304e, 0x304f, 0x3050, + 0x3051, 0x3052, 0x3053, 0x3054, 0x3055, 0x3056, 0x3057, 0x3058, + 0x3059, 0x305a, 0x305b, 0x305c, 0x305d, 0x305e, 0x305f, 0x3060, + 0x3061, 0x3062, 0x3063, 0x3064, 0x3065, 0x3066, 0x3067, 0x3068, + 0x3069, 0x306a, 0x306b, 0x306c, 0x306d, 0x306e, 0x306f, 0x3070, + 0x3071, 0x3072, 0x3073, 0x3074, 0x3075, 0x3076, 0x3077, 0x3078, + 0x3079, 0x307a, 0x307b, 0x307c, 0x307d, 0x307e, 0x307f, 0x3080, + 0x3081, 0x3082, 0x3083, 0x3084, 0x3085, 0x3086, 0x3087, 0x3088, + 0x3089, 0x308a, 0x308b, 0x308c, 0x308d, 0x308e, 0x308f, 0x3090, + 0x3091, 0x3092, 0x3093, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x25 */ + 0x30a1, 0x30a2, 0x30a3, 0x30a4, 0x30a5, 0x30a6, 0x30a7, 0x30a8, + 0x30a9, 0x30aa, 0x30ab, 0x30ac, 0x30ad, 0x30ae, 0x30af, 0x30b0, + 0x30b1, 0x30b2, 0x30b3, 0x30b4, 0x30b5, 0x30b6, 0x30b7, 0x30b8, + 0x30b9, 0x30ba, 0x30bb, 0x30bc, 0x30bd, 0x30be, 0x30bf, 0x30c0, + 0x30c1, 0x30c2, 0x30c3, 0x30c4, 0x30c5, 0x30c6, 0x30c7, 0x30c8, + 0x30c9, 0x30ca, 0x30cb, 0x30cc, 0x30cd, 0x30ce, 0x30cf, 0x30d0, + 0x30d1, 0x30d2, 0x30d3, 0x30d4, 0x30d5, 0x30d6, 0x30d7, 0x30d8, + 0x30d9, 0x30da, 0x30db, 0x30dc, 0x30dd, 0x30de, 0x30df, 0x30e0, + 0x30e1, 0x30e2, 0x30e3, 0x30e4, 0x30e5, 0x30e6, 0x30e7, 0x30e8, + 0x30e9, 0x30ea, 0x30eb, 0x30ec, 0x30ed, 0x30ee, 0x30ef, 0x30f0, + 0x30f1, 0x30f2, 0x30f3, 0x30f4, 0x30f5, 0x30f6, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x26 */ + 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, 0x0398, + 0x0399, 0x039a, 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, 0x03a0, + 0x03a1, 0x03a3, 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, 0x03b8, + 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, 0x03c0, + 0x03c1, 0x03c3, 0x03c4, 0x03c5, 0x03c6, 0x03c7, 0x03c8, 0x03c9, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x27 */ + 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0401, 0x0416, + 0x0417, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, + 0x041f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, + 0x0427, 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, + 0x042f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0451, 0x0436, + 0x0437, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, + 0x043f, 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, + 0x0447, 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, + 0x044f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x28 */ + 0x2500, 0x2502, 0x250c, 0x2510, 0x2518, 0x2514, 0x251c, 0x252c, + 0x2524, 0x2534, 0x253c, 0x2501, 0x2503, 0x250f, 0x2513, 0x251b, + 0x2517, 0x2523, 0x2533, 0x252b, 0x253b, 0x254b, 0x2520, 0x252f, + 0x2528, 0x2537, 0x253f, 0x251d, 0x2530, 0x2525, 0x2538, 0x2542, +}; +static const unsigned short jisx0208_2uni_page30[6398] = { + /* 0x30 */ + 0x4e9c, 0x5516, 0x5a03, 0x963f, 0x54c0, 0x611b, 0x6328, 0x59f6, + 0x9022, 0x8475, 0x831c, 0x7a50, 0x60aa, 0x63e1, 0x6e25, 0x65ed, + 0x8466, 0x82a6, 0x9bf5, 0x6893, 0x5727, 0x65a1, 0x6271, 0x5b9b, + 0x59d0, 0x867b, 0x98f4, 0x7d62, 0x7dbe, 0x9b8e, 0x6216, 0x7c9f, + 0x88b7, 0x5b89, 0x5eb5, 0x6309, 0x6697, 0x6848, 0x95c7, 0x978d, + 0x674f, 0x4ee5, 0x4f0a, 0x4f4d, 0x4f9d, 0x5049, 0x56f2, 0x5937, + 0x59d4, 0x5a01, 0x5c09, 0x60df, 0x610f, 0x6170, 0x6613, 0x6905, + 0x70ba, 0x754f, 0x7570, 0x79fb, 0x7dad, 0x7def, 0x80c3, 0x840e, + 0x8863, 0x8b02, 0x9055, 0x907a, 0x533b, 0x4e95, 0x4ea5, 0x57df, + 0x80b2, 0x90c1, 0x78ef, 0x4e00, 0x58f1, 0x6ea2, 0x9038, 0x7a32, + 0x8328, 0x828b, 0x9c2f, 0x5141, 0x5370, 0x54bd, 0x54e1, 0x56e0, + 0x59fb, 0x5f15, 0x98f2, 0x6deb, 0x80e4, 0x852d, + /* 0x31 */ + 0x9662, 0x9670, 0x96a0, 0x97fb, 0x540b, 0x53f3, 0x5b87, 0x70cf, + 0x7fbd, 0x8fc2, 0x96e8, 0x536f, 0x9d5c, 0x7aba, 0x4e11, 0x7893, + 0x81fc, 0x6e26, 0x5618, 0x5504, 0x6b1d, 0x851a, 0x9c3b, 0x59e5, + 0x53a9, 0x6d66, 0x74dc, 0x958f, 0x5642, 0x4e91, 0x904b, 0x96f2, + 0x834f, 0x990c, 0x53e1, 0x55b6, 0x5b30, 0x5f71, 0x6620, 0x66f3, + 0x6804, 0x6c38, 0x6cf3, 0x6d29, 0x745b, 0x76c8, 0x7a4e, 0x9834, + 0x82f1, 0x885b, 0x8a60, 0x92ed, 0x6db2, 0x75ab, 0x76ca, 0x99c5, + 0x60a6, 0x8b01, 0x8d8a, 0x95b2, 0x698e, 0x53ad, 0x5186, 0x5712, + 0x5830, 0x5944, 0x5bb4, 0x5ef6, 0x6028, 0x63a9, 0x63f4, 0x6cbf, + 0x6f14, 0x708e, 0x7114, 0x7159, 0x71d5, 0x733f, 0x7e01, 0x8276, + 0x82d1, 0x8597, 0x9060, 0x925b, 0x9d1b, 0x5869, 0x65bc, 0x6c5a, + 0x7525, 0x51f9, 0x592e, 0x5965, 0x5f80, 0x5fdc, + /* 0x32 */ + 0x62bc, 0x65fa, 0x6a2a, 0x6b27, 0x6bb4, 0x738b, 0x7fc1, 0x8956, + 0x9d2c, 0x9d0e, 0x9ec4, 0x5ca1, 0x6c96, 0x837b, 0x5104, 0x5c4b, + 0x61b6, 0x81c6, 0x6876, 0x7261, 0x4e59, 0x4ffa, 0x5378, 0x6069, + 0x6e29, 0x7a4f, 0x97f3, 0x4e0b, 0x5316, 0x4eee, 0x4f55, 0x4f3d, + 0x4fa1, 0x4f73, 0x52a0, 0x53ef, 0x5609, 0x590f, 0x5ac1, 0x5bb6, + 0x5be1, 0x79d1, 0x6687, 0x679c, 0x67b6, 0x6b4c, 0x6cb3, 0x706b, + 0x73c2, 0x798d, 0x79be, 0x7a3c, 0x7b87, 0x82b1, 0x82db, 0x8304, + 0x8377, 0x83ef, 0x83d3, 0x8766, 0x8ab2, 0x5629, 0x8ca8, 0x8fe6, + 0x904e, 0x971e, 0x868a, 0x4fc4, 0x5ce8, 0x6211, 0x7259, 0x753b, + 0x81e5, 0x82bd, 0x86fe, 0x8cc0, 0x96c5, 0x9913, 0x99d5, 0x4ecb, + 0x4f1a, 0x89e3, 0x56de, 0x584a, 0x58ca, 0x5efb, 0x5feb, 0x602a, + 0x6094, 0x6062, 0x61d0, 0x6212, 0x62d0, 0x6539, + /* 0x33 */ + 0x9b41, 0x6666, 0x68b0, 0x6d77, 0x7070, 0x754c, 0x7686, 0x7d75, + 0x82a5, 0x87f9, 0x958b, 0x968e, 0x8c9d, 0x51f1, 0x52be, 0x5916, + 0x54b3, 0x5bb3, 0x5d16, 0x6168, 0x6982, 0x6daf, 0x788d, 0x84cb, + 0x8857, 0x8a72, 0x93a7, 0x9ab8, 0x6d6c, 0x99a8, 0x86d9, 0x57a3, + 0x67ff, 0x86ce, 0x920e, 0x5283, 0x5687, 0x5404, 0x5ed3, 0x62e1, + 0x64b9, 0x683c, 0x6838, 0x6bbb, 0x7372, 0x78ba, 0x7a6b, 0x899a, + 0x89d2, 0x8d6b, 0x8f03, 0x90ed, 0x95a3, 0x9694, 0x9769, 0x5b66, + 0x5cb3, 0x697d, 0x984d, 0x984e, 0x639b, 0x7b20, 0x6a2b, 0x6a7f, + 0x68b6, 0x9c0d, 0x6f5f, 0x5272, 0x559d, 0x6070, 0x62ec, 0x6d3b, + 0x6e07, 0x6ed1, 0x845b, 0x8910, 0x8f44, 0x4e14, 0x9c39, 0x53f6, + 0x691b, 0x6a3a, 0x9784, 0x682a, 0x515c, 0x7ac3, 0x84b2, 0x91dc, + 0x938c, 0x565b, 0x9d28, 0x6822, 0x8305, 0x8431, + /* 0x34 */ + 0x7ca5, 0x5208, 0x82c5, 0x74e6, 0x4e7e, 0x4f83, 0x51a0, 0x5bd2, + 0x520a, 0x52d8, 0x52e7, 0x5dfb, 0x559a, 0x582a, 0x59e6, 0x5b8c, + 0x5b98, 0x5bdb, 0x5e72, 0x5e79, 0x60a3, 0x611f, 0x6163, 0x61be, + 0x63db, 0x6562, 0x67d1, 0x6853, 0x68fa, 0x6b3e, 0x6b53, 0x6c57, + 0x6f22, 0x6f97, 0x6f45, 0x74b0, 0x7518, 0x76e3, 0x770b, 0x7aff, + 0x7ba1, 0x7c21, 0x7de9, 0x7f36, 0x7ff0, 0x809d, 0x8266, 0x839e, + 0x89b3, 0x8acc, 0x8cab, 0x9084, 0x9451, 0x9593, 0x9591, 0x95a2, + 0x9665, 0x97d3, 0x9928, 0x8218, 0x4e38, 0x542b, 0x5cb8, 0x5dcc, + 0x73a9, 0x764c, 0x773c, 0x5ca9, 0x7feb, 0x8d0b, 0x96c1, 0x9811, + 0x9854, 0x9858, 0x4f01, 0x4f0e, 0x5371, 0x559c, 0x5668, 0x57fa, + 0x5947, 0x5b09, 0x5bc4, 0x5c90, 0x5e0c, 0x5e7e, 0x5fcc, 0x63ee, + 0x673a, 0x65d7, 0x65e2, 0x671f, 0x68cb, 0x68c4, + /* 0x35 */ + 0x6a5f, 0x5e30, 0x6bc5, 0x6c17, 0x6c7d, 0x757f, 0x7948, 0x5b63, + 0x7a00, 0x7d00, 0x5fbd, 0x898f, 0x8a18, 0x8cb4, 0x8d77, 0x8ecc, + 0x8f1d, 0x98e2, 0x9a0e, 0x9b3c, 0x4e80, 0x507d, 0x5100, 0x5993, + 0x5b9c, 0x622f, 0x6280, 0x64ec, 0x6b3a, 0x72a0, 0x7591, 0x7947, + 0x7fa9, 0x87fb, 0x8abc, 0x8b70, 0x63ac, 0x83ca, 0x97a0, 0x5409, + 0x5403, 0x55ab, 0x6854, 0x6a58, 0x8a70, 0x7827, 0x6775, 0x9ecd, + 0x5374, 0x5ba2, 0x811a, 0x8650, 0x9006, 0x4e18, 0x4e45, 0x4ec7, + 0x4f11, 0x53ca, 0x5438, 0x5bae, 0x5f13, 0x6025, 0x6551, 0x673d, + 0x6c42, 0x6c72, 0x6ce3, 0x7078, 0x7403, 0x7a76, 0x7aae, 0x7b08, + 0x7d1a, 0x7cfe, 0x7d66, 0x65e7, 0x725b, 0x53bb, 0x5c45, 0x5de8, + 0x62d2, 0x62e0, 0x6319, 0x6e20, 0x865a, 0x8a31, 0x8ddd, 0x92f8, + 0x6f01, 0x79a6, 0x9b5a, 0x4ea8, 0x4eab, 0x4eac, + /* 0x36 */ + 0x4f9b, 0x4fa0, 0x50d1, 0x5147, 0x7af6, 0x5171, 0x51f6, 0x5354, + 0x5321, 0x537f, 0x53eb, 0x55ac, 0x5883, 0x5ce1, 0x5f37, 0x5f4a, + 0x602f, 0x6050, 0x606d, 0x631f, 0x6559, 0x6a4b, 0x6cc1, 0x72c2, + 0x72ed, 0x77ef, 0x80f8, 0x8105, 0x8208, 0x854e, 0x90f7, 0x93e1, + 0x97ff, 0x9957, 0x9a5a, 0x4ef0, 0x51dd, 0x5c2d, 0x6681, 0x696d, + 0x5c40, 0x66f2, 0x6975, 0x7389, 0x6850, 0x7c81, 0x50c5, 0x52e4, + 0x5747, 0x5dfe, 0x9326, 0x65a4, 0x6b23, 0x6b3d, 0x7434, 0x7981, + 0x79bd, 0x7b4b, 0x7dca, 0x82b9, 0x83cc, 0x887f, 0x895f, 0x8b39, + 0x8fd1, 0x91d1, 0x541f, 0x9280, 0x4e5d, 0x5036, 0x53e5, 0x533a, + 0x72d7, 0x7396, 0x77e9, 0x82e6, 0x8eaf, 0x99c6, 0x99c8, 0x99d2, + 0x5177, 0x611a, 0x865e, 0x55b0, 0x7a7a, 0x5076, 0x5bd3, 0x9047, + 0x9685, 0x4e32, 0x6adb, 0x91e7, 0x5c51, 0x5c48, + /* 0x37 */ + 0x6398, 0x7a9f, 0x6c93, 0x9774, 0x8f61, 0x7aaa, 0x718a, 0x9688, + 0x7c82, 0x6817, 0x7e70, 0x6851, 0x936c, 0x52f2, 0x541b, 0x85ab, + 0x8a13, 0x7fa4, 0x8ecd, 0x90e1, 0x5366, 0x8888, 0x7941, 0x4fc2, + 0x50be, 0x5211, 0x5144, 0x5553, 0x572d, 0x73ea, 0x578b, 0x5951, + 0x5f62, 0x5f84, 0x6075, 0x6176, 0x6167, 0x61a9, 0x63b2, 0x643a, + 0x656c, 0x666f, 0x6842, 0x6e13, 0x7566, 0x7a3d, 0x7cfb, 0x7d4c, + 0x7d99, 0x7e4b, 0x7f6b, 0x830e, 0x834a, 0x86cd, 0x8a08, 0x8a63, + 0x8b66, 0x8efd, 0x981a, 0x9d8f, 0x82b8, 0x8fce, 0x9be8, 0x5287, + 0x621f, 0x6483, 0x6fc0, 0x9699, 0x6841, 0x5091, 0x6b20, 0x6c7a, + 0x6f54, 0x7a74, 0x7d50, 0x8840, 0x8a23, 0x6708, 0x4ef6, 0x5039, + 0x5026, 0x5065, 0x517c, 0x5238, 0x5263, 0x55a7, 0x570f, 0x5805, + 0x5acc, 0x5efa, 0x61b2, 0x61f8, 0x62f3, 0x6372, + /* 0x38 */ + 0x691c, 0x6a29, 0x727d, 0x72ac, 0x732e, 0x7814, 0x786f, 0x7d79, + 0x770c, 0x80a9, 0x898b, 0x8b19, 0x8ce2, 0x8ed2, 0x9063, 0x9375, + 0x967a, 0x9855, 0x9a13, 0x9e78, 0x5143, 0x539f, 0x53b3, 0x5e7b, + 0x5f26, 0x6e1b, 0x6e90, 0x7384, 0x73fe, 0x7d43, 0x8237, 0x8a00, + 0x8afa, 0x9650, 0x4e4e, 0x500b, 0x53e4, 0x547c, 0x56fa, 0x59d1, + 0x5b64, 0x5df1, 0x5eab, 0x5f27, 0x6238, 0x6545, 0x67af, 0x6e56, + 0x72d0, 0x7cca, 0x88b4, 0x80a1, 0x80e1, 0x83f0, 0x864e, 0x8a87, + 0x8de8, 0x9237, 0x96c7, 0x9867, 0x9f13, 0x4e94, 0x4e92, 0x4f0d, + 0x5348, 0x5449, 0x543e, 0x5a2f, 0x5f8c, 0x5fa1, 0x609f, 0x68a7, + 0x6a8e, 0x745a, 0x7881, 0x8a9e, 0x8aa4, 0x8b77, 0x9190, 0x4e5e, + 0x9bc9, 0x4ea4, 0x4f7c, 0x4faf, 0x5019, 0x5016, 0x5149, 0x516c, + 0x529f, 0x52b9, 0x52fe, 0x539a, 0x53e3, 0x5411, + /* 0x39 */ + 0x540e, 0x5589, 0x5751, 0x57a2, 0x597d, 0x5b54, 0x5b5d, 0x5b8f, + 0x5de5, 0x5de7, 0x5df7, 0x5e78, 0x5e83, 0x5e9a, 0x5eb7, 0x5f18, + 0x6052, 0x614c, 0x6297, 0x62d8, 0x63a7, 0x653b, 0x6602, 0x6643, + 0x66f4, 0x676d, 0x6821, 0x6897, 0x69cb, 0x6c5f, 0x6d2a, 0x6d69, + 0x6e2f, 0x6e9d, 0x7532, 0x7687, 0x786c, 0x7a3f, 0x7ce0, 0x7d05, + 0x7d18, 0x7d5e, 0x7db1, 0x8015, 0x8003, 0x80af, 0x80b1, 0x8154, + 0x818f, 0x822a, 0x8352, 0x884c, 0x8861, 0x8b1b, 0x8ca2, 0x8cfc, + 0x90ca, 0x9175, 0x9271, 0x783f, 0x92fc, 0x95a4, 0x964d, 0x9805, + 0x9999, 0x9ad8, 0x9d3b, 0x525b, 0x52ab, 0x53f7, 0x5408, 0x58d5, + 0x62f7, 0x6fe0, 0x8c6a, 0x8f5f, 0x9eb9, 0x514b, 0x523b, 0x544a, + 0x56fd, 0x7a40, 0x9177, 0x9d60, 0x9ed2, 0x7344, 0x6f09, 0x8170, + 0x7511, 0x5ffd, 0x60da, 0x9aa8, 0x72db, 0x8fbc, + /* 0x3a */ + 0x6b64, 0x9803, 0x4eca, 0x56f0, 0x5764, 0x58be, 0x5a5a, 0x6068, + 0x61c7, 0x660f, 0x6606, 0x6839, 0x68b1, 0x6df7, 0x75d5, 0x7d3a, + 0x826e, 0x9b42, 0x4e9b, 0x4f50, 0x53c9, 0x5506, 0x5d6f, 0x5de6, + 0x5dee, 0x67fb, 0x6c99, 0x7473, 0x7802, 0x8a50, 0x9396, 0x88df, + 0x5750, 0x5ea7, 0x632b, 0x50b5, 0x50ac, 0x518d, 0x6700, 0x54c9, + 0x585e, 0x59bb, 0x5bb0, 0x5f69, 0x624d, 0x63a1, 0x683d, 0x6b73, + 0x6e08, 0x707d, 0x91c7, 0x7280, 0x7815, 0x7826, 0x796d, 0x658e, + 0x7d30, 0x83dc, 0x88c1, 0x8f09, 0x969b, 0x5264, 0x5728, 0x6750, + 0x7f6a, 0x8ca1, 0x51b4, 0x5742, 0x962a, 0x583a, 0x698a, 0x80b4, + 0x54b2, 0x5d0e, 0x57fc, 0x7895, 0x9dfa, 0x4f5c, 0x524a, 0x548b, + 0x643e, 0x6628, 0x6714, 0x67f5, 0x7a84, 0x7b56, 0x7d22, 0x932f, + 0x685c, 0x9bad, 0x7b39, 0x5319, 0x518a, 0x5237, + /* 0x3b */ + 0x5bdf, 0x62f6, 0x64ae, 0x64e6, 0x672d, 0x6bba, 0x85a9, 0x96d1, + 0x7690, 0x9bd6, 0x634c, 0x9306, 0x9bab, 0x76bf, 0x6652, 0x4e09, + 0x5098, 0x53c2, 0x5c71, 0x60e8, 0x6492, 0x6563, 0x685f, 0x71e6, + 0x73ca, 0x7523, 0x7b97, 0x7e82, 0x8695, 0x8b83, 0x8cdb, 0x9178, + 0x9910, 0x65ac, 0x66ab, 0x6b8b, 0x4ed5, 0x4ed4, 0x4f3a, 0x4f7f, + 0x523a, 0x53f8, 0x53f2, 0x55e3, 0x56db, 0x58eb, 0x59cb, 0x59c9, + 0x59ff, 0x5b50, 0x5c4d, 0x5e02, 0x5e2b, 0x5fd7, 0x601d, 0x6307, + 0x652f, 0x5b5c, 0x65af, 0x65bd, 0x65e8, 0x679d, 0x6b62, 0x6b7b, + 0x6c0f, 0x7345, 0x7949, 0x79c1, 0x7cf8, 0x7d19, 0x7d2b, 0x80a2, + 0x8102, 0x81f3, 0x8996, 0x8a5e, 0x8a69, 0x8a66, 0x8a8c, 0x8aee, + 0x8cc7, 0x8cdc, 0x96cc, 0x98fc, 0x6b6f, 0x4e8b, 0x4f3c, 0x4f8d, + 0x5150, 0x5b57, 0x5bfa, 0x6148, 0x6301, 0x6642, + /* 0x3c */ + 0x6b21, 0x6ecb, 0x6cbb, 0x723e, 0x74bd, 0x75d4, 0x78c1, 0x793a, + 0x800c, 0x8033, 0x81ea, 0x8494, 0x8f9e, 0x6c50, 0x9e7f, 0x5f0f, + 0x8b58, 0x9d2b, 0x7afa, 0x8ef8, 0x5b8d, 0x96eb, 0x4e03, 0x53f1, + 0x57f7, 0x5931, 0x5ac9, 0x5ba4, 0x6089, 0x6e7f, 0x6f06, 0x75be, + 0x8cea, 0x5b9f, 0x8500, 0x7be0, 0x5072, 0x67f4, 0x829d, 0x5c61, + 0x854a, 0x7e1e, 0x820e, 0x5199, 0x5c04, 0x6368, 0x8d66, 0x659c, + 0x716e, 0x793e, 0x7d17, 0x8005, 0x8b1d, 0x8eca, 0x906e, 0x86c7, + 0x90aa, 0x501f, 0x52fa, 0x5c3a, 0x6753, 0x707c, 0x7235, 0x914c, + 0x91c8, 0x932b, 0x82e5, 0x5bc2, 0x5f31, 0x60f9, 0x4e3b, 0x53d6, + 0x5b88, 0x624b, 0x6731, 0x6b8a, 0x72e9, 0x73e0, 0x7a2e, 0x816b, + 0x8da3, 0x9152, 0x9996, 0x5112, 0x53d7, 0x546a, 0x5bff, 0x6388, + 0x6a39, 0x7dac, 0x9700, 0x56da, 0x53ce, 0x5468, + /* 0x3d */ + 0x5b97, 0x5c31, 0x5dde, 0x4fee, 0x6101, 0x62fe, 0x6d32, 0x79c0, + 0x79cb, 0x7d42, 0x7e4d, 0x7fd2, 0x81ed, 0x821f, 0x8490, 0x8846, + 0x8972, 0x8b90, 0x8e74, 0x8f2f, 0x9031, 0x914b, 0x916c, 0x96c6, + 0x919c, 0x4ec0, 0x4f4f, 0x5145, 0x5341, 0x5f93, 0x620e, 0x67d4, + 0x6c41, 0x6e0b, 0x7363, 0x7e26, 0x91cd, 0x9283, 0x53d4, 0x5919, + 0x5bbf, 0x6dd1, 0x795d, 0x7e2e, 0x7c9b, 0x587e, 0x719f, 0x51fa, + 0x8853, 0x8ff0, 0x4fca, 0x5cfb, 0x6625, 0x77ac, 0x7ae3, 0x821c, + 0x99ff, 0x51c6, 0x5faa, 0x65ec, 0x696f, 0x6b89, 0x6df3, 0x6e96, + 0x6f64, 0x76fe, 0x7d14, 0x5de1, 0x9075, 0x9187, 0x9806, 0x51e6, + 0x521d, 0x6240, 0x6691, 0x66d9, 0x6e1a, 0x5eb6, 0x7dd2, 0x7f72, + 0x66f8, 0x85af, 0x85f7, 0x8af8, 0x52a9, 0x53d9, 0x5973, 0x5e8f, + 0x5f90, 0x6055, 0x92e4, 0x9664, 0x50b7, 0x511f, + /* 0x3e */ + 0x52dd, 0x5320, 0x5347, 0x53ec, 0x54e8, 0x5546, 0x5531, 0x5617, + 0x5968, 0x59be, 0x5a3c, 0x5bb5, 0x5c06, 0x5c0f, 0x5c11, 0x5c1a, + 0x5e84, 0x5e8a, 0x5ee0, 0x5f70, 0x627f, 0x6284, 0x62db, 0x638c, + 0x6377, 0x6607, 0x660c, 0x662d, 0x6676, 0x677e, 0x68a2, 0x6a1f, + 0x6a35, 0x6cbc, 0x6d88, 0x6e09, 0x6e58, 0x713c, 0x7126, 0x7167, + 0x75c7, 0x7701, 0x785d, 0x7901, 0x7965, 0x79f0, 0x7ae0, 0x7b11, + 0x7ca7, 0x7d39, 0x8096, 0x83d6, 0x848b, 0x8549, 0x885d, 0x88f3, + 0x8a1f, 0x8a3c, 0x8a54, 0x8a73, 0x8c61, 0x8cde, 0x91a4, 0x9266, + 0x937e, 0x9418, 0x969c, 0x9798, 0x4e0a, 0x4e08, 0x4e1e, 0x4e57, + 0x5197, 0x5270, 0x57ce, 0x5834, 0x58cc, 0x5b22, 0x5e38, 0x60c5, + 0x64fe, 0x6761, 0x6756, 0x6d44, 0x72b6, 0x7573, 0x7a63, 0x84b8, + 0x8b72, 0x91b8, 0x9320, 0x5631, 0x57f4, 0x98fe, + /* 0x3f */ + 0x62ed, 0x690d, 0x6b96, 0x71ed, 0x7e54, 0x8077, 0x8272, 0x89e6, + 0x98df, 0x8755, 0x8fb1, 0x5c3b, 0x4f38, 0x4fe1, 0x4fb5, 0x5507, + 0x5a20, 0x5bdd, 0x5be9, 0x5fc3, 0x614e, 0x632f, 0x65b0, 0x664b, + 0x68ee, 0x699b, 0x6d78, 0x6df1, 0x7533, 0x75b9, 0x771f, 0x795e, + 0x79e6, 0x7d33, 0x81e3, 0x82af, 0x85aa, 0x89aa, 0x8a3a, 0x8eab, + 0x8f9b, 0x9032, 0x91dd, 0x9707, 0x4eba, 0x4ec1, 0x5203, 0x5875, + 0x58ec, 0x5c0b, 0x751a, 0x5c3d, 0x814e, 0x8a0a, 0x8fc5, 0x9663, + 0x976d, 0x7b25, 0x8acf, 0x9808, 0x9162, 0x56f3, 0x53a8, 0x9017, + 0x5439, 0x5782, 0x5e25, 0x63a8, 0x6c34, 0x708a, 0x7761, 0x7c8b, + 0x7fe0, 0x8870, 0x9042, 0x9154, 0x9310, 0x9318, 0x968f, 0x745e, + 0x9ac4, 0x5d07, 0x5d69, 0x6570, 0x67a2, 0x8da8, 0x96db, 0x636e, + 0x6749, 0x6919, 0x83c5, 0x9817, 0x96c0, 0x88fe, + /* 0x40 */ + 0x6f84, 0x647a, 0x5bf8, 0x4e16, 0x702c, 0x755d, 0x662f, 0x51c4, + 0x5236, 0x52e2, 0x59d3, 0x5f81, 0x6027, 0x6210, 0x653f, 0x6574, + 0x661f, 0x6674, 0x68f2, 0x6816, 0x6b63, 0x6e05, 0x7272, 0x751f, + 0x76db, 0x7cbe, 0x8056, 0x58f0, 0x88fd, 0x897f, 0x8aa0, 0x8a93, + 0x8acb, 0x901d, 0x9192, 0x9752, 0x9759, 0x6589, 0x7a0e, 0x8106, + 0x96bb, 0x5e2d, 0x60dc, 0x621a, 0x65a5, 0x6614, 0x6790, 0x77f3, + 0x7a4d, 0x7c4d, 0x7e3e, 0x810a, 0x8cac, 0x8d64, 0x8de1, 0x8e5f, + 0x78a9, 0x5207, 0x62d9, 0x63a5, 0x6442, 0x6298, 0x8a2d, 0x7a83, + 0x7bc0, 0x8aac, 0x96ea, 0x7d76, 0x820c, 0x8749, 0x4ed9, 0x5148, + 0x5343, 0x5360, 0x5ba3, 0x5c02, 0x5c16, 0x5ddd, 0x6226, 0x6247, + 0x64b0, 0x6813, 0x6834, 0x6cc9, 0x6d45, 0x6d17, 0x67d3, 0x6f5c, + 0x714e, 0x717d, 0x65cb, 0x7a7f, 0x7bad, 0x7dda, + /* 0x41 */ + 0x7e4a, 0x7fa8, 0x817a, 0x821b, 0x8239, 0x85a6, 0x8a6e, 0x8cce, + 0x8df5, 0x9078, 0x9077, 0x92ad, 0x9291, 0x9583, 0x9bae, 0x524d, + 0x5584, 0x6f38, 0x7136, 0x5168, 0x7985, 0x7e55, 0x81b3, 0x7cce, + 0x564c, 0x5851, 0x5ca8, 0x63aa, 0x66fe, 0x66fd, 0x695a, 0x72d9, + 0x758f, 0x758e, 0x790e, 0x7956, 0x79df, 0x7c97, 0x7d20, 0x7d44, + 0x8607, 0x8a34, 0x963b, 0x9061, 0x9f20, 0x50e7, 0x5275, 0x53cc, + 0x53e2, 0x5009, 0x55aa, 0x58ee, 0x594f, 0x723d, 0x5b8b, 0x5c64, + 0x531d, 0x60e3, 0x60f3, 0x635c, 0x6383, 0x633f, 0x63bb, 0x64cd, + 0x65e9, 0x66f9, 0x5de3, 0x69cd, 0x69fd, 0x6f15, 0x71e5, 0x4e89, + 0x75e9, 0x76f8, 0x7a93, 0x7cdf, 0x7dcf, 0x7d9c, 0x8061, 0x8349, + 0x8358, 0x846c, 0x84bc, 0x85fb, 0x88c5, 0x8d70, 0x9001, 0x906d, + 0x9397, 0x971c, 0x9a12, 0x50cf, 0x5897, 0x618e, + /* 0x42 */ + 0x81d3, 0x8535, 0x8d08, 0x9020, 0x4fc3, 0x5074, 0x5247, 0x5373, + 0x606f, 0x6349, 0x675f, 0x6e2c, 0x8db3, 0x901f, 0x4fd7, 0x5c5e, + 0x8cca, 0x65cf, 0x7d9a, 0x5352, 0x8896, 0x5176, 0x63c3, 0x5b58, + 0x5b6b, 0x5c0a, 0x640d, 0x6751, 0x905c, 0x4ed6, 0x591a, 0x592a, + 0x6c70, 0x8a51, 0x553e, 0x5815, 0x59a5, 0x60f0, 0x6253, 0x67c1, + 0x8235, 0x6955, 0x9640, 0x99c4, 0x9a28, 0x4f53, 0x5806, 0x5bfe, + 0x8010, 0x5cb1, 0x5e2f, 0x5f85, 0x6020, 0x614b, 0x6234, 0x66ff, + 0x6cf0, 0x6ede, 0x80ce, 0x817f, 0x82d4, 0x888b, 0x8cb8, 0x9000, + 0x902e, 0x968a, 0x9edb, 0x9bdb, 0x4ee3, 0x53f0, 0x5927, 0x7b2c, + 0x918d, 0x984c, 0x9df9, 0x6edd, 0x7027, 0x5353, 0x5544, 0x5b85, + 0x6258, 0x629e, 0x62d3, 0x6ca2, 0x6fef, 0x7422, 0x8a17, 0x9438, + 0x6fc1, 0x8afe, 0x8338, 0x51e7, 0x86f8, 0x53ea, + /* 0x43 */ + 0x53e9, 0x4f46, 0x9054, 0x8fb0, 0x596a, 0x8131, 0x5dfd, 0x7aea, + 0x8fbf, 0x68da, 0x8c37, 0x72f8, 0x9c48, 0x6a3d, 0x8ab0, 0x4e39, + 0x5358, 0x5606, 0x5766, 0x62c5, 0x63a2, 0x65e6, 0x6b4e, 0x6de1, + 0x6e5b, 0x70ad, 0x77ed, 0x7aef, 0x7baa, 0x7dbb, 0x803d, 0x80c6, + 0x86cb, 0x8a95, 0x935b, 0x56e3, 0x58c7, 0x5f3e, 0x65ad, 0x6696, + 0x6a80, 0x6bb5, 0x7537, 0x8ac7, 0x5024, 0x77e5, 0x5730, 0x5f1b, + 0x6065, 0x667a, 0x6c60, 0x75f4, 0x7a1a, 0x7f6e, 0x81f4, 0x8718, + 0x9045, 0x99b3, 0x7bc9, 0x755c, 0x7af9, 0x7b51, 0x84c4, 0x9010, + 0x79e9, 0x7a92, 0x8336, 0x5ae1, 0x7740, 0x4e2d, 0x4ef2, 0x5b99, + 0x5fe0, 0x62bd, 0x663c, 0x67f1, 0x6ce8, 0x866b, 0x8877, 0x8a3b, + 0x914e, 0x92f3, 0x99d0, 0x6a17, 0x7026, 0x732a, 0x82e7, 0x8457, + 0x8caf, 0x4e01, 0x5146, 0x51cb, 0x558b, 0x5bf5, + /* 0x44 */ + 0x5e16, 0x5e33, 0x5e81, 0x5f14, 0x5f35, 0x5f6b, 0x5fb4, 0x61f2, + 0x6311, 0x66a2, 0x671d, 0x6f6e, 0x7252, 0x753a, 0x773a, 0x8074, + 0x8139, 0x8178, 0x8776, 0x8abf, 0x8adc, 0x8d85, 0x8df3, 0x929a, + 0x9577, 0x9802, 0x9ce5, 0x52c5, 0x6357, 0x76f4, 0x6715, 0x6c88, + 0x73cd, 0x8cc3, 0x93ae, 0x9673, 0x6d25, 0x589c, 0x690e, 0x69cc, + 0x8ffd, 0x939a, 0x75db, 0x901a, 0x585a, 0x6802, 0x63b4, 0x69fb, + 0x4f43, 0x6f2c, 0x67d8, 0x8fbb, 0x8526, 0x7db4, 0x9354, 0x693f, + 0x6f70, 0x576a, 0x58f7, 0x5b2c, 0x7d2c, 0x722a, 0x540a, 0x91e3, + 0x9db4, 0x4ead, 0x4f4e, 0x505c, 0x5075, 0x5243, 0x8c9e, 0x5448, + 0x5824, 0x5b9a, 0x5e1d, 0x5e95, 0x5ead, 0x5ef7, 0x5f1f, 0x608c, + 0x62b5, 0x633a, 0x63d0, 0x68af, 0x6c40, 0x7887, 0x798e, 0x7a0b, + 0x7de0, 0x8247, 0x8a02, 0x8ae6, 0x8e44, 0x9013, + /* 0x45 */ + 0x90b8, 0x912d, 0x91d8, 0x9f0e, 0x6ce5, 0x6458, 0x64e2, 0x6575, + 0x6ef4, 0x7684, 0x7b1b, 0x9069, 0x93d1, 0x6eba, 0x54f2, 0x5fb9, + 0x64a4, 0x8f4d, 0x8fed, 0x9244, 0x5178, 0x586b, 0x5929, 0x5c55, + 0x5e97, 0x6dfb, 0x7e8f, 0x751c, 0x8cbc, 0x8ee2, 0x985b, 0x70b9, + 0x4f1d, 0x6bbf, 0x6fb1, 0x7530, 0x96fb, 0x514e, 0x5410, 0x5835, + 0x5857, 0x59ac, 0x5c60, 0x5f92, 0x6597, 0x675c, 0x6e21, 0x767b, + 0x83df, 0x8ced, 0x9014, 0x90fd, 0x934d, 0x7825, 0x783a, 0x52aa, + 0x5ea6, 0x571f, 0x5974, 0x6012, 0x5012, 0x515a, 0x51ac, 0x51cd, + 0x5200, 0x5510, 0x5854, 0x5858, 0x5957, 0x5b95, 0x5cf6, 0x5d8b, + 0x60bc, 0x6295, 0x642d, 0x6771, 0x6843, 0x68bc, 0x68df, 0x76d7, + 0x6dd8, 0x6e6f, 0x6d9b, 0x706f, 0x71c8, 0x5f53, 0x75d8, 0x7977, + 0x7b49, 0x7b54, 0x7b52, 0x7cd6, 0x7d71, 0x5230, + /* 0x46 */ + 0x8463, 0x8569, 0x85e4, 0x8a0e, 0x8b04, 0x8c46, 0x8e0f, 0x9003, + 0x900f, 0x9419, 0x9676, 0x982d, 0x9a30, 0x95d8, 0x50cd, 0x52d5, + 0x540c, 0x5802, 0x5c0e, 0x61a7, 0x649e, 0x6d1e, 0x77b3, 0x7ae5, + 0x80f4, 0x8404, 0x9053, 0x9285, 0x5ce0, 0x9d07, 0x533f, 0x5f97, + 0x5fb3, 0x6d9c, 0x7279, 0x7763, 0x79bf, 0x7be4, 0x6bd2, 0x72ec, + 0x8aad, 0x6803, 0x6a61, 0x51f8, 0x7a81, 0x6934, 0x5c4a, 0x9cf6, + 0x82eb, 0x5bc5, 0x9149, 0x701e, 0x5678, 0x5c6f, 0x60c7, 0x6566, + 0x6c8c, 0x8c5a, 0x9041, 0x9813, 0x5451, 0x66c7, 0x920d, 0x5948, + 0x90a3, 0x5185, 0x4e4d, 0x51ea, 0x8599, 0x8b0e, 0x7058, 0x637a, + 0x934b, 0x6962, 0x99b4, 0x7e04, 0x7577, 0x5357, 0x6960, 0x8edf, + 0x96e3, 0x6c5d, 0x4e8c, 0x5c3c, 0x5f10, 0x8fe9, 0x5302, 0x8cd1, + 0x8089, 0x8679, 0x5eff, 0x65e5, 0x4e73, 0x5165, + /* 0x47 */ + 0x5982, 0x5c3f, 0x97ee, 0x4efb, 0x598a, 0x5fcd, 0x8a8d, 0x6fe1, + 0x79b0, 0x7962, 0x5be7, 0x8471, 0x732b, 0x71b1, 0x5e74, 0x5ff5, + 0x637b, 0x649a, 0x71c3, 0x7c98, 0x4e43, 0x5efc, 0x4e4b, 0x57dc, + 0x56a2, 0x60a9, 0x6fc3, 0x7d0d, 0x80fd, 0x8133, 0x81bf, 0x8fb2, + 0x8997, 0x86a4, 0x5df4, 0x628a, 0x64ad, 0x8987, 0x6777, 0x6ce2, + 0x6d3e, 0x7436, 0x7834, 0x5a46, 0x7f75, 0x82ad, 0x99ac, 0x4ff3, + 0x5ec3, 0x62dd, 0x6392, 0x6557, 0x676f, 0x76c3, 0x724c, 0x80cc, + 0x80ba, 0x8f29, 0x914d, 0x500d, 0x57f9, 0x5a92, 0x6885, 0x6973, + 0x7164, 0x72fd, 0x8cb7, 0x58f2, 0x8ce0, 0x966a, 0x9019, 0x877f, + 0x79e4, 0x77e7, 0x8429, 0x4f2f, 0x5265, 0x535a, 0x62cd, 0x67cf, + 0x6cca, 0x767d, 0x7b94, 0x7c95, 0x8236, 0x8584, 0x8feb, 0x66dd, + 0x6f20, 0x7206, 0x7e1b, 0x83ab, 0x99c1, 0x9ea6, + /* 0x48 */ + 0x51fd, 0x7bb1, 0x7872, 0x7bb8, 0x8087, 0x7b48, 0x6ae8, 0x5e61, + 0x808c, 0x7551, 0x7560, 0x516b, 0x9262, 0x6e8c, 0x767a, 0x9197, + 0x9aea, 0x4f10, 0x7f70, 0x629c, 0x7b4f, 0x95a5, 0x9ce9, 0x567a, + 0x5859, 0x86e4, 0x96bc, 0x4f34, 0x5224, 0x534a, 0x53cd, 0x53db, + 0x5e06, 0x642c, 0x6591, 0x677f, 0x6c3e, 0x6c4e, 0x7248, 0x72af, + 0x73ed, 0x7554, 0x7e41, 0x822c, 0x85e9, 0x8ca9, 0x7bc4, 0x91c6, + 0x7169, 0x9812, 0x98ef, 0x633d, 0x6669, 0x756a, 0x76e4, 0x78d0, + 0x8543, 0x86ee, 0x532a, 0x5351, 0x5426, 0x5983, 0x5e87, 0x5f7c, + 0x60b2, 0x6249, 0x6279, 0x62ab, 0x6590, 0x6bd4, 0x6ccc, 0x75b2, + 0x76ae, 0x7891, 0x79d8, 0x7dcb, 0x7f77, 0x80a5, 0x88ab, 0x8ab9, + 0x8cbb, 0x907f, 0x975e, 0x98db, 0x6a0b, 0x7c38, 0x5099, 0x5c3e, + 0x5fae, 0x6787, 0x6bd8, 0x7435, 0x7709, 0x7f8e, + /* 0x49 */ + 0x9f3b, 0x67ca, 0x7a17, 0x5339, 0x758b, 0x9aed, 0x5f66, 0x819d, + 0x83f1, 0x8098, 0x5f3c, 0x5fc5, 0x7562, 0x7b46, 0x903c, 0x6867, + 0x59eb, 0x5a9b, 0x7d10, 0x767e, 0x8b2c, 0x4ff5, 0x5f6a, 0x6a19, + 0x6c37, 0x6f02, 0x74e2, 0x7968, 0x8868, 0x8a55, 0x8c79, 0x5edf, + 0x63cf, 0x75c5, 0x79d2, 0x82d7, 0x9328, 0x92f2, 0x849c, 0x86ed, + 0x9c2d, 0x54c1, 0x5f6c, 0x658c, 0x6d5c, 0x7015, 0x8ca7, 0x8cd3, + 0x983b, 0x654f, 0x74f6, 0x4e0d, 0x4ed8, 0x57e0, 0x592b, 0x5a66, + 0x5bcc, 0x51a8, 0x5e03, 0x5e9c, 0x6016, 0x6276, 0x6577, 0x65a7, + 0x666e, 0x6d6e, 0x7236, 0x7b26, 0x8150, 0x819a, 0x8299, 0x8b5c, + 0x8ca0, 0x8ce6, 0x8d74, 0x961c, 0x9644, 0x4fae, 0x64ab, 0x6b66, + 0x821e, 0x8461, 0x856a, 0x90e8, 0x5c01, 0x6953, 0x98a8, 0x847a, + 0x8557, 0x4f0f, 0x526f, 0x5fa9, 0x5e45, 0x670d, + /* 0x4a */ + 0x798f, 0x8179, 0x8907, 0x8986, 0x6df5, 0x5f17, 0x6255, 0x6cb8, + 0x4ecf, 0x7269, 0x9b92, 0x5206, 0x543b, 0x5674, 0x58b3, 0x61a4, + 0x626e, 0x711a, 0x596e, 0x7c89, 0x7cde, 0x7d1b, 0x96f0, 0x6587, + 0x805e, 0x4e19, 0x4f75, 0x5175, 0x5840, 0x5e63, 0x5e73, 0x5f0a, + 0x67c4, 0x4e26, 0x853d, 0x9589, 0x965b, 0x7c73, 0x9801, 0x50fb, + 0x58c1, 0x7656, 0x78a7, 0x5225, 0x77a5, 0x8511, 0x7b86, 0x504f, + 0x5909, 0x7247, 0x7bc7, 0x7de8, 0x8fba, 0x8fd4, 0x904d, 0x4fbf, + 0x52c9, 0x5a29, 0x5f01, 0x97ad, 0x4fdd, 0x8217, 0x92ea, 0x5703, + 0x6355, 0x6b69, 0x752b, 0x88dc, 0x8f14, 0x7a42, 0x52df, 0x5893, + 0x6155, 0x620a, 0x66ae, 0x6bcd, 0x7c3f, 0x83e9, 0x5023, 0x4ff8, + 0x5305, 0x5446, 0x5831, 0x5949, 0x5b9d, 0x5cf0, 0x5cef, 0x5d29, + 0x5e96, 0x62b1, 0x6367, 0x653e, 0x65b9, 0x670b, + /* 0x4b */ + 0x6cd5, 0x6ce1, 0x70f9, 0x7832, 0x7e2b, 0x80de, 0x82b3, 0x840c, + 0x84ec, 0x8702, 0x8912, 0x8a2a, 0x8c4a, 0x90a6, 0x92d2, 0x98fd, + 0x9cf3, 0x9d6c, 0x4e4f, 0x4ea1, 0x508d, 0x5256, 0x574a, 0x59a8, + 0x5e3d, 0x5fd8, 0x5fd9, 0x623f, 0x66b4, 0x671b, 0x67d0, 0x68d2, + 0x5192, 0x7d21, 0x80aa, 0x81a8, 0x8b00, 0x8c8c, 0x8cbf, 0x927e, + 0x9632, 0x5420, 0x982c, 0x5317, 0x50d5, 0x535c, 0x58a8, 0x64b2, + 0x6734, 0x7267, 0x7766, 0x7a46, 0x91e6, 0x52c3, 0x6ca1, 0x6b86, + 0x5800, 0x5e4c, 0x5954, 0x672c, 0x7ffb, 0x51e1, 0x76c6, 0x6469, + 0x78e8, 0x9b54, 0x9ebb, 0x57cb, 0x59b9, 0x6627, 0x679a, 0x6bce, + 0x54e9, 0x69d9, 0x5e55, 0x819c, 0x6795, 0x9baa, 0x67fe, 0x9c52, + 0x685d, 0x4ea6, 0x4fe3, 0x53c8, 0x62b9, 0x672b, 0x6cab, 0x8fc4, + 0x4fad, 0x7e6d, 0x9ebf, 0x4e07, 0x6162, 0x6e80, + /* 0x4c */ + 0x6f2b, 0x8513, 0x5473, 0x672a, 0x9b45, 0x5df3, 0x7b95, 0x5cac, + 0x5bc6, 0x871c, 0x6e4a, 0x84d1, 0x7a14, 0x8108, 0x5999, 0x7c8d, + 0x6c11, 0x7720, 0x52d9, 0x5922, 0x7121, 0x725f, 0x77db, 0x9727, + 0x9d61, 0x690b, 0x5a7f, 0x5a18, 0x51a5, 0x540d, 0x547d, 0x660e, + 0x76df, 0x8ff7, 0x9298, 0x9cf4, 0x59ea, 0x725d, 0x6ec5, 0x514d, + 0x68c9, 0x7dbf, 0x7dec, 0x9762, 0x9eba, 0x6478, 0x6a21, 0x8302, + 0x5984, 0x5b5f, 0x6bdb, 0x731b, 0x76f2, 0x7db2, 0x8017, 0x8499, + 0x5132, 0x6728, 0x9ed9, 0x76ee, 0x6762, 0x52ff, 0x9905, 0x5c24, + 0x623b, 0x7c7e, 0x8cb0, 0x554f, 0x60b6, 0x7d0b, 0x9580, 0x5301, + 0x4e5f, 0x51b6, 0x591c, 0x723a, 0x8036, 0x91ce, 0x5f25, 0x77e2, + 0x5384, 0x5f79, 0x7d04, 0x85ac, 0x8a33, 0x8e8d, 0x9756, 0x67f3, + 0x85ae, 0x9453, 0x6109, 0x6108, 0x6cb9, 0x7652, + /* 0x4d */ + 0x8aed, 0x8f38, 0x552f, 0x4f51, 0x512a, 0x52c7, 0x53cb, 0x5ba5, + 0x5e7d, 0x60a0, 0x6182, 0x63d6, 0x6709, 0x67da, 0x6e67, 0x6d8c, + 0x7336, 0x7337, 0x7531, 0x7950, 0x88d5, 0x8a98, 0x904a, 0x9091, + 0x90f5, 0x96c4, 0x878d, 0x5915, 0x4e88, 0x4f59, 0x4e0e, 0x8a89, + 0x8f3f, 0x9810, 0x50ad, 0x5e7c, 0x5996, 0x5bb9, 0x5eb8, 0x63da, + 0x63fa, 0x64c1, 0x66dc, 0x694a, 0x69d8, 0x6d0b, 0x6eb6, 0x7194, + 0x7528, 0x7aaf, 0x7f8a, 0x8000, 0x8449, 0x84c9, 0x8981, 0x8b21, + 0x8e0a, 0x9065, 0x967d, 0x990a, 0x617e, 0x6291, 0x6b32, 0x6c83, + 0x6d74, 0x7fcc, 0x7ffc, 0x6dc0, 0x7f85, 0x87ba, 0x88f8, 0x6765, + 0x83b1, 0x983c, 0x96f7, 0x6d1b, 0x7d61, 0x843d, 0x916a, 0x4e71, + 0x5375, 0x5d50, 0x6b04, 0x6feb, 0x85cd, 0x862d, 0x89a7, 0x5229, + 0x540f, 0x5c65, 0x674e, 0x68a8, 0x7406, 0x7483, + /* 0x4e */ + 0x75e2, 0x88cf, 0x88e1, 0x91cc, 0x96e2, 0x9678, 0x5f8b, 0x7387, + 0x7acb, 0x844e, 0x63a0, 0x7565, 0x5289, 0x6d41, 0x6e9c, 0x7409, + 0x7559, 0x786b, 0x7c92, 0x9686, 0x7adc, 0x9f8d, 0x4fb6, 0x616e, + 0x65c5, 0x865c, 0x4e86, 0x4eae, 0x50da, 0x4e21, 0x51cc, 0x5bee, + 0x6599, 0x6881, 0x6dbc, 0x731f, 0x7642, 0x77ad, 0x7a1c, 0x7ce7, + 0x826f, 0x8ad2, 0x907c, 0x91cf, 0x9675, 0x9818, 0x529b, 0x7dd1, + 0x502b, 0x5398, 0x6797, 0x6dcb, 0x71d0, 0x7433, 0x81e8, 0x8f2a, + 0x96a3, 0x9c57, 0x9e9f, 0x7460, 0x5841, 0x6d99, 0x7d2f, 0x985e, + 0x4ee4, 0x4f36, 0x4f8b, 0x51b7, 0x52b1, 0x5dba, 0x601c, 0x73b2, + 0x793c, 0x82d3, 0x9234, 0x96b7, 0x96f6, 0x970a, 0x9e97, 0x9f62, + 0x66a6, 0x6b74, 0x5217, 0x52a3, 0x70c8, 0x88c2, 0x5ec9, 0x604b, + 0x6190, 0x6f23, 0x7149, 0x7c3e, 0x7df4, 0x806f, + /* 0x4f */ + 0x84ee, 0x9023, 0x932c, 0x5442, 0x9b6f, 0x6ad3, 0x7089, 0x8cc2, + 0x8def, 0x9732, 0x52b4, 0x5a41, 0x5eca, 0x5f04, 0x6717, 0x697c, + 0x6994, 0x6d6a, 0x6f0f, 0x7262, 0x72fc, 0x7bed, 0x8001, 0x807e, + 0x874b, 0x90ce, 0x516d, 0x9e93, 0x7984, 0x808b, 0x9332, 0x8ad6, + 0x502d, 0x548c, 0x8a71, 0x6b6a, 0x8cc4, 0x8107, 0x60d1, 0x67a0, + 0x9df2, 0x4e99, 0x4e98, 0x9c10, 0x8a6b, 0x85c1, 0x8568, 0x6900, + 0x6e7e, 0x7897, 0x8155, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x50 */ + 0x5f0c, 0x4e10, 0x4e15, 0x4e2a, 0x4e31, 0x4e36, 0x4e3c, 0x4e3f, + 0x4e42, 0x4e56, 0x4e58, 0x4e82, 0x4e85, 0x8c6b, 0x4e8a, 0x8212, + 0x5f0d, 0x4e8e, 0x4e9e, 0x4e9f, 0x4ea0, 0x4ea2, 0x4eb0, 0x4eb3, + 0x4eb6, 0x4ece, 0x4ecd, 0x4ec4, 0x4ec6, 0x4ec2, 0x4ed7, 0x4ede, + 0x4eed, 0x4edf, 0x4ef7, 0x4f09, 0x4f5a, 0x4f30, 0x4f5b, 0x4f5d, + 0x4f57, 0x4f47, 0x4f76, 0x4f88, 0x4f8f, 0x4f98, 0x4f7b, 0x4f69, + 0x4f70, 0x4f91, 0x4f6f, 0x4f86, 0x4f96, 0x5118, 0x4fd4, 0x4fdf, + 0x4fce, 0x4fd8, 0x4fdb, 0x4fd1, 0x4fda, 0x4fd0, 0x4fe4, 0x4fe5, + 0x501a, 0x5028, 0x5014, 0x502a, 0x5025, 0x5005, 0x4f1c, 0x4ff6, + 0x5021, 0x5029, 0x502c, 0x4ffe, 0x4fef, 0x5011, 0x5006, 0x5043, + 0x5047, 0x6703, 0x5055, 0x5050, 0x5048, 0x505a, 0x5056, 0x506c, + 0x5078, 0x5080, 0x509a, 0x5085, 0x50b4, 0x50b2, + /* 0x51 */ + 0x50c9, 0x50ca, 0x50b3, 0x50c2, 0x50d6, 0x50de, 0x50e5, 0x50ed, + 0x50e3, 0x50ee, 0x50f9, 0x50f5, 0x5109, 0x5101, 0x5102, 0x5116, + 0x5115, 0x5114, 0x511a, 0x5121, 0x513a, 0x5137, 0x513c, 0x513b, + 0x513f, 0x5140, 0x5152, 0x514c, 0x5154, 0x5162, 0x7af8, 0x5169, + 0x516a, 0x516e, 0x5180, 0x5182, 0x56d8, 0x518c, 0x5189, 0x518f, + 0x5191, 0x5193, 0x5195, 0x5196, 0x51a4, 0x51a6, 0x51a2, 0x51a9, + 0x51aa, 0x51ab, 0x51b3, 0x51b1, 0x51b2, 0x51b0, 0x51b5, 0x51bd, + 0x51c5, 0x51c9, 0x51db, 0x51e0, 0x8655, 0x51e9, 0x51ed, 0x51f0, + 0x51f5, 0x51fe, 0x5204, 0x520b, 0x5214, 0x520e, 0x5227, 0x522a, + 0x522e, 0x5233, 0x5239, 0x524f, 0x5244, 0x524b, 0x524c, 0x525e, + 0x5254, 0x526a, 0x5274, 0x5269, 0x5273, 0x527f, 0x527d, 0x528d, + 0x5294, 0x5292, 0x5271, 0x5288, 0x5291, 0x8fa8, + /* 0x52 */ + 0x8fa7, 0x52ac, 0x52ad, 0x52bc, 0x52b5, 0x52c1, 0x52cd, 0x52d7, + 0x52de, 0x52e3, 0x52e6, 0x98ed, 0x52e0, 0x52f3, 0x52f5, 0x52f8, + 0x52f9, 0x5306, 0x5308, 0x7538, 0x530d, 0x5310, 0x530f, 0x5315, + 0x531a, 0x5323, 0x532f, 0x5331, 0x5333, 0x5338, 0x5340, 0x5346, + 0x5345, 0x4e17, 0x5349, 0x534d, 0x51d6, 0x535e, 0x5369, 0x536e, + 0x5918, 0x537b, 0x5377, 0x5382, 0x5396, 0x53a0, 0x53a6, 0x53a5, + 0x53ae, 0x53b0, 0x53b6, 0x53c3, 0x7c12, 0x96d9, 0x53df, 0x66fc, + 0x71ee, 0x53ee, 0x53e8, 0x53ed, 0x53fa, 0x5401, 0x543d, 0x5440, + 0x542c, 0x542d, 0x543c, 0x542e, 0x5436, 0x5429, 0x541d, 0x544e, + 0x548f, 0x5475, 0x548e, 0x545f, 0x5471, 0x5477, 0x5470, 0x5492, + 0x547b, 0x5480, 0x5476, 0x5484, 0x5490, 0x5486, 0x54c7, 0x54a2, + 0x54b8, 0x54a5, 0x54ac, 0x54c4, 0x54c8, 0x54a8, + /* 0x53 */ + 0x54ab, 0x54c2, 0x54a4, 0x54be, 0x54bc, 0x54d8, 0x54e5, 0x54e6, + 0x550f, 0x5514, 0x54fd, 0x54ee, 0x54ed, 0x54fa, 0x54e2, 0x5539, + 0x5540, 0x5563, 0x554c, 0x552e, 0x555c, 0x5545, 0x5556, 0x5557, + 0x5538, 0x5533, 0x555d, 0x5599, 0x5580, 0x54af, 0x558a, 0x559f, + 0x557b, 0x557e, 0x5598, 0x559e, 0x55ae, 0x557c, 0x5583, 0x55a9, + 0x5587, 0x55a8, 0x55da, 0x55c5, 0x55df, 0x55c4, 0x55dc, 0x55e4, + 0x55d4, 0x5614, 0x55f7, 0x5616, 0x55fe, 0x55fd, 0x561b, 0x55f9, + 0x564e, 0x5650, 0x71df, 0x5634, 0x5636, 0x5632, 0x5638, 0x566b, + 0x5664, 0x562f, 0x566c, 0x566a, 0x5686, 0x5680, 0x568a, 0x56a0, + 0x5694, 0x568f, 0x56a5, 0x56ae, 0x56b6, 0x56b4, 0x56c2, 0x56bc, + 0x56c1, 0x56c3, 0x56c0, 0x56c8, 0x56ce, 0x56d1, 0x56d3, 0x56d7, + 0x56ee, 0x56f9, 0x5700, 0x56ff, 0x5704, 0x5709, + /* 0x54 */ + 0x5708, 0x570b, 0x570d, 0x5713, 0x5718, 0x5716, 0x55c7, 0x571c, + 0x5726, 0x5737, 0x5738, 0x574e, 0x573b, 0x5740, 0x574f, 0x5769, + 0x57c0, 0x5788, 0x5761, 0x577f, 0x5789, 0x5793, 0x57a0, 0x57b3, + 0x57a4, 0x57aa, 0x57b0, 0x57c3, 0x57c6, 0x57d4, 0x57d2, 0x57d3, + 0x580a, 0x57d6, 0x57e3, 0x580b, 0x5819, 0x581d, 0x5872, 0x5821, + 0x5862, 0x584b, 0x5870, 0x6bc0, 0x5852, 0x583d, 0x5879, 0x5885, + 0x58b9, 0x589f, 0x58ab, 0x58ba, 0x58de, 0x58bb, 0x58b8, 0x58ae, + 0x58c5, 0x58d3, 0x58d1, 0x58d7, 0x58d9, 0x58d8, 0x58e5, 0x58dc, + 0x58e4, 0x58df, 0x58ef, 0x58fa, 0x58f9, 0x58fb, 0x58fc, 0x58fd, + 0x5902, 0x590a, 0x5910, 0x591b, 0x68a6, 0x5925, 0x592c, 0x592d, + 0x5932, 0x5938, 0x593e, 0x7ad2, 0x5955, 0x5950, 0x594e, 0x595a, + 0x5958, 0x5962, 0x5960, 0x5967, 0x596c, 0x5969, + /* 0x55 */ + 0x5978, 0x5981, 0x599d, 0x4f5e, 0x4fab, 0x59a3, 0x59b2, 0x59c6, + 0x59e8, 0x59dc, 0x598d, 0x59d9, 0x59da, 0x5a25, 0x5a1f, 0x5a11, + 0x5a1c, 0x5a09, 0x5a1a, 0x5a40, 0x5a6c, 0x5a49, 0x5a35, 0x5a36, + 0x5a62, 0x5a6a, 0x5a9a, 0x5abc, 0x5abe, 0x5acb, 0x5ac2, 0x5abd, + 0x5ae3, 0x5ad7, 0x5ae6, 0x5ae9, 0x5ad6, 0x5afa, 0x5afb, 0x5b0c, + 0x5b0b, 0x5b16, 0x5b32, 0x5ad0, 0x5b2a, 0x5b36, 0x5b3e, 0x5b43, + 0x5b45, 0x5b40, 0x5b51, 0x5b55, 0x5b5a, 0x5b5b, 0x5b65, 0x5b69, + 0x5b70, 0x5b73, 0x5b75, 0x5b78, 0x6588, 0x5b7a, 0x5b80, 0x5b83, + 0x5ba6, 0x5bb8, 0x5bc3, 0x5bc7, 0x5bc9, 0x5bd4, 0x5bd0, 0x5be4, + 0x5be6, 0x5be2, 0x5bde, 0x5be5, 0x5beb, 0x5bf0, 0x5bf6, 0x5bf3, + 0x5c05, 0x5c07, 0x5c08, 0x5c0d, 0x5c13, 0x5c20, 0x5c22, 0x5c28, + 0x5c38, 0x5c39, 0x5c41, 0x5c46, 0x5c4e, 0x5c53, + /* 0x56 */ + 0x5c50, 0x5c4f, 0x5b71, 0x5c6c, 0x5c6e, 0x4e62, 0x5c76, 0x5c79, + 0x5c8c, 0x5c91, 0x5c94, 0x599b, 0x5cab, 0x5cbb, 0x5cb6, 0x5cbc, + 0x5cb7, 0x5cc5, 0x5cbe, 0x5cc7, 0x5cd9, 0x5ce9, 0x5cfd, 0x5cfa, + 0x5ced, 0x5d8c, 0x5cea, 0x5d0b, 0x5d15, 0x5d17, 0x5d5c, 0x5d1f, + 0x5d1b, 0x5d11, 0x5d14, 0x5d22, 0x5d1a, 0x5d19, 0x5d18, 0x5d4c, + 0x5d52, 0x5d4e, 0x5d4b, 0x5d6c, 0x5d73, 0x5d76, 0x5d87, 0x5d84, + 0x5d82, 0x5da2, 0x5d9d, 0x5dac, 0x5dae, 0x5dbd, 0x5d90, 0x5db7, + 0x5dbc, 0x5dc9, 0x5dcd, 0x5dd3, 0x5dd2, 0x5dd6, 0x5ddb, 0x5deb, + 0x5df2, 0x5df5, 0x5e0b, 0x5e1a, 0x5e19, 0x5e11, 0x5e1b, 0x5e36, + 0x5e37, 0x5e44, 0x5e43, 0x5e40, 0x5e4e, 0x5e57, 0x5e54, 0x5e5f, + 0x5e62, 0x5e64, 0x5e47, 0x5e75, 0x5e76, 0x5e7a, 0x9ebc, 0x5e7f, + 0x5ea0, 0x5ec1, 0x5ec2, 0x5ec8, 0x5ed0, 0x5ecf, + /* 0x57 */ + 0x5ed6, 0x5ee3, 0x5edd, 0x5eda, 0x5edb, 0x5ee2, 0x5ee1, 0x5ee8, + 0x5ee9, 0x5eec, 0x5ef1, 0x5ef3, 0x5ef0, 0x5ef4, 0x5ef8, 0x5efe, + 0x5f03, 0x5f09, 0x5f5d, 0x5f5c, 0x5f0b, 0x5f11, 0x5f16, 0x5f29, + 0x5f2d, 0x5f38, 0x5f41, 0x5f48, 0x5f4c, 0x5f4e, 0x5f2f, 0x5f51, + 0x5f56, 0x5f57, 0x5f59, 0x5f61, 0x5f6d, 0x5f73, 0x5f77, 0x5f83, + 0x5f82, 0x5f7f, 0x5f8a, 0x5f88, 0x5f91, 0x5f87, 0x5f9e, 0x5f99, + 0x5f98, 0x5fa0, 0x5fa8, 0x5fad, 0x5fbc, 0x5fd6, 0x5ffb, 0x5fe4, + 0x5ff8, 0x5ff1, 0x5fdd, 0x60b3, 0x5fff, 0x6021, 0x6060, 0x6019, + 0x6010, 0x6029, 0x600e, 0x6031, 0x601b, 0x6015, 0x602b, 0x6026, + 0x600f, 0x603a, 0x605a, 0x6041, 0x606a, 0x6077, 0x605f, 0x604a, + 0x6046, 0x604d, 0x6063, 0x6043, 0x6064, 0x6042, 0x606c, 0x606b, + 0x6059, 0x6081, 0x608d, 0x60e7, 0x6083, 0x609a, + /* 0x58 */ + 0x6084, 0x609b, 0x6096, 0x6097, 0x6092, 0x60a7, 0x608b, 0x60e1, + 0x60b8, 0x60e0, 0x60d3, 0x60b4, 0x5ff0, 0x60bd, 0x60c6, 0x60b5, + 0x60d8, 0x614d, 0x6115, 0x6106, 0x60f6, 0x60f7, 0x6100, 0x60f4, + 0x60fa, 0x6103, 0x6121, 0x60fb, 0x60f1, 0x610d, 0x610e, 0x6147, + 0x613e, 0x6128, 0x6127, 0x614a, 0x613f, 0x613c, 0x612c, 0x6134, + 0x613d, 0x6142, 0x6144, 0x6173, 0x6177, 0x6158, 0x6159, 0x615a, + 0x616b, 0x6174, 0x616f, 0x6165, 0x6171, 0x615f, 0x615d, 0x6153, + 0x6175, 0x6199, 0x6196, 0x6187, 0x61ac, 0x6194, 0x619a, 0x618a, + 0x6191, 0x61ab, 0x61ae, 0x61cc, 0x61ca, 0x61c9, 0x61f7, 0x61c8, + 0x61c3, 0x61c6, 0x61ba, 0x61cb, 0x7f79, 0x61cd, 0x61e6, 0x61e3, + 0x61f6, 0x61fa, 0x61f4, 0x61ff, 0x61fd, 0x61fc, 0x61fe, 0x6200, + 0x6208, 0x6209, 0x620d, 0x620c, 0x6214, 0x621b, + /* 0x59 */ + 0x621e, 0x6221, 0x622a, 0x622e, 0x6230, 0x6232, 0x6233, 0x6241, + 0x624e, 0x625e, 0x6263, 0x625b, 0x6260, 0x6268, 0x627c, 0x6282, + 0x6289, 0x627e, 0x6292, 0x6293, 0x6296, 0x62d4, 0x6283, 0x6294, + 0x62d7, 0x62d1, 0x62bb, 0x62cf, 0x62ff, 0x62c6, 0x64d4, 0x62c8, + 0x62dc, 0x62cc, 0x62ca, 0x62c2, 0x62c7, 0x629b, 0x62c9, 0x630c, + 0x62ee, 0x62f1, 0x6327, 0x6302, 0x6308, 0x62ef, 0x62f5, 0x6350, + 0x633e, 0x634d, 0x641c, 0x634f, 0x6396, 0x638e, 0x6380, 0x63ab, + 0x6376, 0x63a3, 0x638f, 0x6389, 0x639f, 0x63b5, 0x636b, 0x6369, + 0x63be, 0x63e9, 0x63c0, 0x63c6, 0x63e3, 0x63c9, 0x63d2, 0x63f6, + 0x63c4, 0x6416, 0x6434, 0x6406, 0x6413, 0x6426, 0x6436, 0x651d, + 0x6417, 0x6428, 0x640f, 0x6467, 0x646f, 0x6476, 0x644e, 0x652a, + 0x6495, 0x6493, 0x64a5, 0x64a9, 0x6488, 0x64bc, + /* 0x5a */ + 0x64da, 0x64d2, 0x64c5, 0x64c7, 0x64bb, 0x64d8, 0x64c2, 0x64f1, + 0x64e7, 0x8209, 0x64e0, 0x64e1, 0x62ac, 0x64e3, 0x64ef, 0x652c, + 0x64f6, 0x64f4, 0x64f2, 0x64fa, 0x6500, 0x64fd, 0x6518, 0x651c, + 0x6505, 0x6524, 0x6523, 0x652b, 0x6534, 0x6535, 0x6537, 0x6536, + 0x6538, 0x754b, 0x6548, 0x6556, 0x6555, 0x654d, 0x6558, 0x655e, + 0x655d, 0x6572, 0x6578, 0x6582, 0x6583, 0x8b8a, 0x659b, 0x659f, + 0x65ab, 0x65b7, 0x65c3, 0x65c6, 0x65c1, 0x65c4, 0x65cc, 0x65d2, + 0x65db, 0x65d9, 0x65e0, 0x65e1, 0x65f1, 0x6772, 0x660a, 0x6603, + 0x65fb, 0x6773, 0x6635, 0x6636, 0x6634, 0x661c, 0x664f, 0x6644, + 0x6649, 0x6641, 0x665e, 0x665d, 0x6664, 0x6667, 0x6668, 0x665f, + 0x6662, 0x6670, 0x6683, 0x6688, 0x668e, 0x6689, 0x6684, 0x6698, + 0x669d, 0x66c1, 0x66b9, 0x66c9, 0x66be, 0x66bc, + /* 0x5b */ + 0x66c4, 0x66b8, 0x66d6, 0x66da, 0x66e0, 0x663f, 0x66e6, 0x66e9, + 0x66f0, 0x66f5, 0x66f7, 0x670f, 0x6716, 0x671e, 0x6726, 0x6727, + 0x9738, 0x672e, 0x673f, 0x6736, 0x6741, 0x6738, 0x6737, 0x6746, + 0x675e, 0x6760, 0x6759, 0x6763, 0x6764, 0x6789, 0x6770, 0x67a9, + 0x677c, 0x676a, 0x678c, 0x678b, 0x67a6, 0x67a1, 0x6785, 0x67b7, + 0x67ef, 0x67b4, 0x67ec, 0x67b3, 0x67e9, 0x67b8, 0x67e4, 0x67de, + 0x67dd, 0x67e2, 0x67ee, 0x67b9, 0x67ce, 0x67c6, 0x67e7, 0x6a9c, + 0x681e, 0x6846, 0x6829, 0x6840, 0x684d, 0x6832, 0x684e, 0x68b3, + 0x682b, 0x6859, 0x6863, 0x6877, 0x687f, 0x689f, 0x688f, 0x68ad, + 0x6894, 0x689d, 0x689b, 0x6883, 0x6aae, 0x68b9, 0x6874, 0x68b5, + 0x68a0, 0x68ba, 0x690f, 0x688d, 0x687e, 0x6901, 0x68ca, 0x6908, + 0x68d8, 0x6922, 0x6926, 0x68e1, 0x690c, 0x68cd, + /* 0x5c */ + 0x68d4, 0x68e7, 0x68d5, 0x6936, 0x6912, 0x6904, 0x68d7, 0x68e3, + 0x6925, 0x68f9, 0x68e0, 0x68ef, 0x6928, 0x692a, 0x691a, 0x6923, + 0x6921, 0x68c6, 0x6979, 0x6977, 0x695c, 0x6978, 0x696b, 0x6954, + 0x697e, 0x696e, 0x6939, 0x6974, 0x693d, 0x6959, 0x6930, 0x6961, + 0x695e, 0x695d, 0x6981, 0x696a, 0x69b2, 0x69ae, 0x69d0, 0x69bf, + 0x69c1, 0x69d3, 0x69be, 0x69ce, 0x5be8, 0x69ca, 0x69dd, 0x69bb, + 0x69c3, 0x69a7, 0x6a2e, 0x6991, 0x69a0, 0x699c, 0x6995, 0x69b4, + 0x69de, 0x69e8, 0x6a02, 0x6a1b, 0x69ff, 0x6b0a, 0x69f9, 0x69f2, + 0x69e7, 0x6a05, 0x69b1, 0x6a1e, 0x69ed, 0x6a14, 0x69eb, 0x6a0a, + 0x6a12, 0x6ac1, 0x6a23, 0x6a13, 0x6a44, 0x6a0c, 0x6a72, 0x6a36, + 0x6a78, 0x6a47, 0x6a62, 0x6a59, 0x6a66, 0x6a48, 0x6a38, 0x6a22, + 0x6a90, 0x6a8d, 0x6aa0, 0x6a84, 0x6aa2, 0x6aa3, + /* 0x5d */ + 0x6a97, 0x8617, 0x6abb, 0x6ac3, 0x6ac2, 0x6ab8, 0x6ab3, 0x6aac, + 0x6ade, 0x6ad1, 0x6adf, 0x6aaa, 0x6ada, 0x6aea, 0x6afb, 0x6b05, + 0x8616, 0x6afa, 0x6b12, 0x6b16, 0x9b31, 0x6b1f, 0x6b38, 0x6b37, + 0x76dc, 0x6b39, 0x98ee, 0x6b47, 0x6b43, 0x6b49, 0x6b50, 0x6b59, + 0x6b54, 0x6b5b, 0x6b5f, 0x6b61, 0x6b78, 0x6b79, 0x6b7f, 0x6b80, + 0x6b84, 0x6b83, 0x6b8d, 0x6b98, 0x6b95, 0x6b9e, 0x6ba4, 0x6baa, + 0x6bab, 0x6baf, 0x6bb2, 0x6bb1, 0x6bb3, 0x6bb7, 0x6bbc, 0x6bc6, + 0x6bcb, 0x6bd3, 0x6bdf, 0x6bec, 0x6beb, 0x6bf3, 0x6bef, 0x9ebe, + 0x6c08, 0x6c13, 0x6c14, 0x6c1b, 0x6c24, 0x6c23, 0x6c5e, 0x6c55, + 0x6c62, 0x6c6a, 0x6c82, 0x6c8d, 0x6c9a, 0x6c81, 0x6c9b, 0x6c7e, + 0x6c68, 0x6c73, 0x6c92, 0x6c90, 0x6cc4, 0x6cf1, 0x6cd3, 0x6cbd, + 0x6cd7, 0x6cc5, 0x6cdd, 0x6cae, 0x6cb1, 0x6cbe, + /* 0x5e */ + 0x6cba, 0x6cdb, 0x6cef, 0x6cd9, 0x6cea, 0x6d1f, 0x884d, 0x6d36, + 0x6d2b, 0x6d3d, 0x6d38, 0x6d19, 0x6d35, 0x6d33, 0x6d12, 0x6d0c, + 0x6d63, 0x6d93, 0x6d64, 0x6d5a, 0x6d79, 0x6d59, 0x6d8e, 0x6d95, + 0x6fe4, 0x6d85, 0x6df9, 0x6e15, 0x6e0a, 0x6db5, 0x6dc7, 0x6de6, + 0x6db8, 0x6dc6, 0x6dec, 0x6dde, 0x6dcc, 0x6de8, 0x6dd2, 0x6dc5, + 0x6dfa, 0x6dd9, 0x6de4, 0x6dd5, 0x6dea, 0x6dee, 0x6e2d, 0x6e6e, + 0x6e2e, 0x6e19, 0x6e72, 0x6e5f, 0x6e3e, 0x6e23, 0x6e6b, 0x6e2b, + 0x6e76, 0x6e4d, 0x6e1f, 0x6e43, 0x6e3a, 0x6e4e, 0x6e24, 0x6eff, + 0x6e1d, 0x6e38, 0x6e82, 0x6eaa, 0x6e98, 0x6ec9, 0x6eb7, 0x6ed3, + 0x6ebd, 0x6eaf, 0x6ec4, 0x6eb2, 0x6ed4, 0x6ed5, 0x6e8f, 0x6ea5, + 0x6ec2, 0x6e9f, 0x6f41, 0x6f11, 0x704c, 0x6eec, 0x6ef8, 0x6efe, + 0x6f3f, 0x6ef2, 0x6f31, 0x6eef, 0x6f32, 0x6ecc, + /* 0x5f */ + 0x6f3e, 0x6f13, 0x6ef7, 0x6f86, 0x6f7a, 0x6f78, 0x6f81, 0x6f80, + 0x6f6f, 0x6f5b, 0x6ff3, 0x6f6d, 0x6f82, 0x6f7c, 0x6f58, 0x6f8e, + 0x6f91, 0x6fc2, 0x6f66, 0x6fb3, 0x6fa3, 0x6fa1, 0x6fa4, 0x6fb9, + 0x6fc6, 0x6faa, 0x6fdf, 0x6fd5, 0x6fec, 0x6fd4, 0x6fd8, 0x6ff1, + 0x6fee, 0x6fdb, 0x7009, 0x700b, 0x6ffa, 0x7011, 0x7001, 0x700f, + 0x6ffe, 0x701b, 0x701a, 0x6f74, 0x701d, 0x7018, 0x701f, 0x7030, + 0x703e, 0x7032, 0x7051, 0x7063, 0x7099, 0x7092, 0x70af, 0x70f1, + 0x70ac, 0x70b8, 0x70b3, 0x70ae, 0x70df, 0x70cb, 0x70dd, 0x70d9, + 0x7109, 0x70fd, 0x711c, 0x7119, 0x7165, 0x7155, 0x7188, 0x7166, + 0x7162, 0x714c, 0x7156, 0x716c, 0x718f, 0x71fb, 0x7184, 0x7195, + 0x71a8, 0x71ac, 0x71d7, 0x71b9, 0x71be, 0x71d2, 0x71c9, 0x71d4, + 0x71ce, 0x71e0, 0x71ec, 0x71e7, 0x71f5, 0x71fc, + /* 0x60 */ + 0x71f9, 0x71ff, 0x720d, 0x7210, 0x721b, 0x7228, 0x722d, 0x722c, + 0x7230, 0x7232, 0x723b, 0x723c, 0x723f, 0x7240, 0x7246, 0x724b, + 0x7258, 0x7274, 0x727e, 0x7282, 0x7281, 0x7287, 0x7292, 0x7296, + 0x72a2, 0x72a7, 0x72b9, 0x72b2, 0x72c3, 0x72c6, 0x72c4, 0x72ce, + 0x72d2, 0x72e2, 0x72e0, 0x72e1, 0x72f9, 0x72f7, 0x500f, 0x7317, + 0x730a, 0x731c, 0x7316, 0x731d, 0x7334, 0x732f, 0x7329, 0x7325, + 0x733e, 0x734e, 0x734f, 0x9ed8, 0x7357, 0x736a, 0x7368, 0x7370, + 0x7378, 0x7375, 0x737b, 0x737a, 0x73c8, 0x73b3, 0x73ce, 0x73bb, + 0x73c0, 0x73e5, 0x73ee, 0x73de, 0x74a2, 0x7405, 0x746f, 0x7425, + 0x73f8, 0x7432, 0x743a, 0x7455, 0x743f, 0x745f, 0x7459, 0x7441, + 0x745c, 0x7469, 0x7470, 0x7463, 0x746a, 0x7476, 0x747e, 0x748b, + 0x749e, 0x74a7, 0x74ca, 0x74cf, 0x74d4, 0x73f1, + /* 0x61 */ + 0x74e0, 0x74e3, 0x74e7, 0x74e9, 0x74ee, 0x74f2, 0x74f0, 0x74f1, + 0x74f8, 0x74f7, 0x7504, 0x7503, 0x7505, 0x750c, 0x750e, 0x750d, + 0x7515, 0x7513, 0x751e, 0x7526, 0x752c, 0x753c, 0x7544, 0x754d, + 0x754a, 0x7549, 0x755b, 0x7546, 0x755a, 0x7569, 0x7564, 0x7567, + 0x756b, 0x756d, 0x7578, 0x7576, 0x7586, 0x7587, 0x7574, 0x758a, + 0x7589, 0x7582, 0x7594, 0x759a, 0x759d, 0x75a5, 0x75a3, 0x75c2, + 0x75b3, 0x75c3, 0x75b5, 0x75bd, 0x75b8, 0x75bc, 0x75b1, 0x75cd, + 0x75ca, 0x75d2, 0x75d9, 0x75e3, 0x75de, 0x75fe, 0x75ff, 0x75fc, + 0x7601, 0x75f0, 0x75fa, 0x75f2, 0x75f3, 0x760b, 0x760d, 0x7609, + 0x761f, 0x7627, 0x7620, 0x7621, 0x7622, 0x7624, 0x7634, 0x7630, + 0x763b, 0x7647, 0x7648, 0x7646, 0x765c, 0x7658, 0x7661, 0x7662, + 0x7668, 0x7669, 0x766a, 0x7667, 0x766c, 0x7670, + /* 0x62 */ + 0x7672, 0x7676, 0x7678, 0x767c, 0x7680, 0x7683, 0x7688, 0x768b, + 0x768e, 0x7696, 0x7693, 0x7699, 0x769a, 0x76b0, 0x76b4, 0x76b8, + 0x76b9, 0x76ba, 0x76c2, 0x76cd, 0x76d6, 0x76d2, 0x76de, 0x76e1, + 0x76e5, 0x76e7, 0x76ea, 0x862f, 0x76fb, 0x7708, 0x7707, 0x7704, + 0x7729, 0x7724, 0x771e, 0x7725, 0x7726, 0x771b, 0x7737, 0x7738, + 0x7747, 0x775a, 0x7768, 0x776b, 0x775b, 0x7765, 0x777f, 0x777e, + 0x7779, 0x778e, 0x778b, 0x7791, 0x77a0, 0x779e, 0x77b0, 0x77b6, + 0x77b9, 0x77bf, 0x77bc, 0x77bd, 0x77bb, 0x77c7, 0x77cd, 0x77d7, + 0x77da, 0x77dc, 0x77e3, 0x77ee, 0x77fc, 0x780c, 0x7812, 0x7926, + 0x7820, 0x792a, 0x7845, 0x788e, 0x7874, 0x7886, 0x787c, 0x789a, + 0x788c, 0x78a3, 0x78b5, 0x78aa, 0x78af, 0x78d1, 0x78c6, 0x78cb, + 0x78d4, 0x78be, 0x78bc, 0x78c5, 0x78ca, 0x78ec, + /* 0x63 */ + 0x78e7, 0x78da, 0x78fd, 0x78f4, 0x7907, 0x7912, 0x7911, 0x7919, + 0x792c, 0x792b, 0x7940, 0x7960, 0x7957, 0x795f, 0x795a, 0x7955, + 0x7953, 0x797a, 0x797f, 0x798a, 0x799d, 0x79a7, 0x9f4b, 0x79aa, + 0x79ae, 0x79b3, 0x79b9, 0x79ba, 0x79c9, 0x79d5, 0x79e7, 0x79ec, + 0x79e1, 0x79e3, 0x7a08, 0x7a0d, 0x7a18, 0x7a19, 0x7a20, 0x7a1f, + 0x7980, 0x7a31, 0x7a3b, 0x7a3e, 0x7a37, 0x7a43, 0x7a57, 0x7a49, + 0x7a61, 0x7a62, 0x7a69, 0x9f9d, 0x7a70, 0x7a79, 0x7a7d, 0x7a88, + 0x7a97, 0x7a95, 0x7a98, 0x7a96, 0x7aa9, 0x7ac8, 0x7ab0, 0x7ab6, + 0x7ac5, 0x7ac4, 0x7abf, 0x9083, 0x7ac7, 0x7aca, 0x7acd, 0x7acf, + 0x7ad5, 0x7ad3, 0x7ad9, 0x7ada, 0x7add, 0x7ae1, 0x7ae2, 0x7ae6, + 0x7aed, 0x7af0, 0x7b02, 0x7b0f, 0x7b0a, 0x7b06, 0x7b33, 0x7b18, + 0x7b19, 0x7b1e, 0x7b35, 0x7b28, 0x7b36, 0x7b50, + /* 0x64 */ + 0x7b7a, 0x7b04, 0x7b4d, 0x7b0b, 0x7b4c, 0x7b45, 0x7b75, 0x7b65, + 0x7b74, 0x7b67, 0x7b70, 0x7b71, 0x7b6c, 0x7b6e, 0x7b9d, 0x7b98, + 0x7b9f, 0x7b8d, 0x7b9c, 0x7b9a, 0x7b8b, 0x7b92, 0x7b8f, 0x7b5d, + 0x7b99, 0x7bcb, 0x7bc1, 0x7bcc, 0x7bcf, 0x7bb4, 0x7bc6, 0x7bdd, + 0x7be9, 0x7c11, 0x7c14, 0x7be6, 0x7be5, 0x7c60, 0x7c00, 0x7c07, + 0x7c13, 0x7bf3, 0x7bf7, 0x7c17, 0x7c0d, 0x7bf6, 0x7c23, 0x7c27, + 0x7c2a, 0x7c1f, 0x7c37, 0x7c2b, 0x7c3d, 0x7c4c, 0x7c43, 0x7c54, + 0x7c4f, 0x7c40, 0x7c50, 0x7c58, 0x7c5f, 0x7c64, 0x7c56, 0x7c65, + 0x7c6c, 0x7c75, 0x7c83, 0x7c90, 0x7ca4, 0x7cad, 0x7ca2, 0x7cab, + 0x7ca1, 0x7ca8, 0x7cb3, 0x7cb2, 0x7cb1, 0x7cae, 0x7cb9, 0x7cbd, + 0x7cc0, 0x7cc5, 0x7cc2, 0x7cd8, 0x7cd2, 0x7cdc, 0x7ce2, 0x9b3b, + 0x7cef, 0x7cf2, 0x7cf4, 0x7cf6, 0x7cfa, 0x7d06, + /* 0x65 */ + 0x7d02, 0x7d1c, 0x7d15, 0x7d0a, 0x7d45, 0x7d4b, 0x7d2e, 0x7d32, + 0x7d3f, 0x7d35, 0x7d46, 0x7d73, 0x7d56, 0x7d4e, 0x7d72, 0x7d68, + 0x7d6e, 0x7d4f, 0x7d63, 0x7d93, 0x7d89, 0x7d5b, 0x7d8f, 0x7d7d, + 0x7d9b, 0x7dba, 0x7dae, 0x7da3, 0x7db5, 0x7dc7, 0x7dbd, 0x7dab, + 0x7e3d, 0x7da2, 0x7daf, 0x7ddc, 0x7db8, 0x7d9f, 0x7db0, 0x7dd8, + 0x7ddd, 0x7de4, 0x7dde, 0x7dfb, 0x7df2, 0x7de1, 0x7e05, 0x7e0a, + 0x7e23, 0x7e21, 0x7e12, 0x7e31, 0x7e1f, 0x7e09, 0x7e0b, 0x7e22, + 0x7e46, 0x7e66, 0x7e3b, 0x7e35, 0x7e39, 0x7e43, 0x7e37, 0x7e32, + 0x7e3a, 0x7e67, 0x7e5d, 0x7e56, 0x7e5e, 0x7e59, 0x7e5a, 0x7e79, + 0x7e6a, 0x7e69, 0x7e7c, 0x7e7b, 0x7e83, 0x7dd5, 0x7e7d, 0x8fae, + 0x7e7f, 0x7e88, 0x7e89, 0x7e8c, 0x7e92, 0x7e90, 0x7e93, 0x7e94, + 0x7e96, 0x7e8e, 0x7e9b, 0x7e9c, 0x7f38, 0x7f3a, + /* 0x66 */ + 0x7f45, 0x7f4c, 0x7f4d, 0x7f4e, 0x7f50, 0x7f51, 0x7f55, 0x7f54, + 0x7f58, 0x7f5f, 0x7f60, 0x7f68, 0x7f69, 0x7f67, 0x7f78, 0x7f82, + 0x7f86, 0x7f83, 0x7f88, 0x7f87, 0x7f8c, 0x7f94, 0x7f9e, 0x7f9d, + 0x7f9a, 0x7fa3, 0x7faf, 0x7fb2, 0x7fb9, 0x7fae, 0x7fb6, 0x7fb8, + 0x8b71, 0x7fc5, 0x7fc6, 0x7fca, 0x7fd5, 0x7fd4, 0x7fe1, 0x7fe6, + 0x7fe9, 0x7ff3, 0x7ff9, 0x98dc, 0x8006, 0x8004, 0x800b, 0x8012, + 0x8018, 0x8019, 0x801c, 0x8021, 0x8028, 0x803f, 0x803b, 0x804a, + 0x8046, 0x8052, 0x8058, 0x805a, 0x805f, 0x8062, 0x8068, 0x8073, + 0x8072, 0x8070, 0x8076, 0x8079, 0x807d, 0x807f, 0x8084, 0x8086, + 0x8085, 0x809b, 0x8093, 0x809a, 0x80ad, 0x5190, 0x80ac, 0x80db, + 0x80e5, 0x80d9, 0x80dd, 0x80c4, 0x80da, 0x80d6, 0x8109, 0x80ef, + 0x80f1, 0x811b, 0x8129, 0x8123, 0x812f, 0x814b, + /* 0x67 */ + 0x968b, 0x8146, 0x813e, 0x8153, 0x8151, 0x80fc, 0x8171, 0x816e, + 0x8165, 0x8166, 0x8174, 0x8183, 0x8188, 0x818a, 0x8180, 0x8182, + 0x81a0, 0x8195, 0x81a4, 0x81a3, 0x815f, 0x8193, 0x81a9, 0x81b0, + 0x81b5, 0x81be, 0x81b8, 0x81bd, 0x81c0, 0x81c2, 0x81ba, 0x81c9, + 0x81cd, 0x81d1, 0x81d9, 0x81d8, 0x81c8, 0x81da, 0x81df, 0x81e0, + 0x81e7, 0x81fa, 0x81fb, 0x81fe, 0x8201, 0x8202, 0x8205, 0x8207, + 0x820a, 0x820d, 0x8210, 0x8216, 0x8229, 0x822b, 0x8238, 0x8233, + 0x8240, 0x8259, 0x8258, 0x825d, 0x825a, 0x825f, 0x8264, 0x8262, + 0x8268, 0x826a, 0x826b, 0x822e, 0x8271, 0x8277, 0x8278, 0x827e, + 0x828d, 0x8292, 0x82ab, 0x829f, 0x82bb, 0x82ac, 0x82e1, 0x82e3, + 0x82df, 0x82d2, 0x82f4, 0x82f3, 0x82fa, 0x8393, 0x8303, 0x82fb, + 0x82f9, 0x82de, 0x8306, 0x82dc, 0x8309, 0x82d9, + /* 0x68 */ + 0x8335, 0x8334, 0x8316, 0x8332, 0x8331, 0x8340, 0x8339, 0x8350, + 0x8345, 0x832f, 0x832b, 0x8317, 0x8318, 0x8385, 0x839a, 0x83aa, + 0x839f, 0x83a2, 0x8396, 0x8323, 0x838e, 0x8387, 0x838a, 0x837c, + 0x83b5, 0x8373, 0x8375, 0x83a0, 0x8389, 0x83a8, 0x83f4, 0x8413, + 0x83eb, 0x83ce, 0x83fd, 0x8403, 0x83d8, 0x840b, 0x83c1, 0x83f7, + 0x8407, 0x83e0, 0x83f2, 0x840d, 0x8422, 0x8420, 0x83bd, 0x8438, + 0x8506, 0x83fb, 0x846d, 0x842a, 0x843c, 0x855a, 0x8484, 0x8477, + 0x846b, 0x84ad, 0x846e, 0x8482, 0x8469, 0x8446, 0x842c, 0x846f, + 0x8479, 0x8435, 0x84ca, 0x8462, 0x84b9, 0x84bf, 0x849f, 0x84d9, + 0x84cd, 0x84bb, 0x84da, 0x84d0, 0x84c1, 0x84c6, 0x84d6, 0x84a1, + 0x8521, 0x84ff, 0x84f4, 0x8517, 0x8518, 0x852c, 0x851f, 0x8515, + 0x8514, 0x84fc, 0x8540, 0x8563, 0x8558, 0x8548, + /* 0x69 */ + 0x8541, 0x8602, 0x854b, 0x8555, 0x8580, 0x85a4, 0x8588, 0x8591, + 0x858a, 0x85a8, 0x856d, 0x8594, 0x859b, 0x85ea, 0x8587, 0x859c, + 0x8577, 0x857e, 0x8590, 0x85c9, 0x85ba, 0x85cf, 0x85b9, 0x85d0, + 0x85d5, 0x85dd, 0x85e5, 0x85dc, 0x85f9, 0x860a, 0x8613, 0x860b, + 0x85fe, 0x85fa, 0x8606, 0x8622, 0x861a, 0x8630, 0x863f, 0x864d, + 0x4e55, 0x8654, 0x865f, 0x8667, 0x8671, 0x8693, 0x86a3, 0x86a9, + 0x86aa, 0x868b, 0x868c, 0x86b6, 0x86af, 0x86c4, 0x86c6, 0x86b0, + 0x86c9, 0x8823, 0x86ab, 0x86d4, 0x86de, 0x86e9, 0x86ec, 0x86df, + 0x86db, 0x86ef, 0x8712, 0x8706, 0x8708, 0x8700, 0x8703, 0x86fb, + 0x8711, 0x8709, 0x870d, 0x86f9, 0x870a, 0x8734, 0x873f, 0x8737, + 0x873b, 0x8725, 0x8729, 0x871a, 0x8760, 0x875f, 0x8778, 0x874c, + 0x874e, 0x8774, 0x8757, 0x8768, 0x876e, 0x8759, + /* 0x6a */ + 0x8753, 0x8763, 0x876a, 0x8805, 0x87a2, 0x879f, 0x8782, 0x87af, + 0x87cb, 0x87bd, 0x87c0, 0x87d0, 0x96d6, 0x87ab, 0x87c4, 0x87b3, + 0x87c7, 0x87c6, 0x87bb, 0x87ef, 0x87f2, 0x87e0, 0x880f, 0x880d, + 0x87fe, 0x87f6, 0x87f7, 0x880e, 0x87d2, 0x8811, 0x8816, 0x8815, + 0x8822, 0x8821, 0x8831, 0x8836, 0x8839, 0x8827, 0x883b, 0x8844, + 0x8842, 0x8852, 0x8859, 0x885e, 0x8862, 0x886b, 0x8881, 0x887e, + 0x889e, 0x8875, 0x887d, 0x88b5, 0x8872, 0x8882, 0x8897, 0x8892, + 0x88ae, 0x8899, 0x88a2, 0x888d, 0x88a4, 0x88b0, 0x88bf, 0x88b1, + 0x88c3, 0x88c4, 0x88d4, 0x88d8, 0x88d9, 0x88dd, 0x88f9, 0x8902, + 0x88fc, 0x88f4, 0x88e8, 0x88f2, 0x8904, 0x890c, 0x890a, 0x8913, + 0x8943, 0x891e, 0x8925, 0x892a, 0x892b, 0x8941, 0x8944, 0x893b, + 0x8936, 0x8938, 0x894c, 0x891d, 0x8960, 0x895e, + /* 0x6b */ + 0x8966, 0x8964, 0x896d, 0x896a, 0x896f, 0x8974, 0x8977, 0x897e, + 0x8983, 0x8988, 0x898a, 0x8993, 0x8998, 0x89a1, 0x89a9, 0x89a6, + 0x89ac, 0x89af, 0x89b2, 0x89ba, 0x89bd, 0x89bf, 0x89c0, 0x89da, + 0x89dc, 0x89dd, 0x89e7, 0x89f4, 0x89f8, 0x8a03, 0x8a16, 0x8a10, + 0x8a0c, 0x8a1b, 0x8a1d, 0x8a25, 0x8a36, 0x8a41, 0x8a5b, 0x8a52, + 0x8a46, 0x8a48, 0x8a7c, 0x8a6d, 0x8a6c, 0x8a62, 0x8a85, 0x8a82, + 0x8a84, 0x8aa8, 0x8aa1, 0x8a91, 0x8aa5, 0x8aa6, 0x8a9a, 0x8aa3, + 0x8ac4, 0x8acd, 0x8ac2, 0x8ada, 0x8aeb, 0x8af3, 0x8ae7, 0x8ae4, + 0x8af1, 0x8b14, 0x8ae0, 0x8ae2, 0x8af7, 0x8ade, 0x8adb, 0x8b0c, + 0x8b07, 0x8b1a, 0x8ae1, 0x8b16, 0x8b10, 0x8b17, 0x8b20, 0x8b33, + 0x97ab, 0x8b26, 0x8b2b, 0x8b3e, 0x8b28, 0x8b41, 0x8b4c, 0x8b4f, + 0x8b4e, 0x8b49, 0x8b56, 0x8b5b, 0x8b5a, 0x8b6b, + /* 0x6c */ + 0x8b5f, 0x8b6c, 0x8b6f, 0x8b74, 0x8b7d, 0x8b80, 0x8b8c, 0x8b8e, + 0x8b92, 0x8b93, 0x8b96, 0x8b99, 0x8b9a, 0x8c3a, 0x8c41, 0x8c3f, + 0x8c48, 0x8c4c, 0x8c4e, 0x8c50, 0x8c55, 0x8c62, 0x8c6c, 0x8c78, + 0x8c7a, 0x8c82, 0x8c89, 0x8c85, 0x8c8a, 0x8c8d, 0x8c8e, 0x8c94, + 0x8c7c, 0x8c98, 0x621d, 0x8cad, 0x8caa, 0x8cbd, 0x8cb2, 0x8cb3, + 0x8cae, 0x8cb6, 0x8cc8, 0x8cc1, 0x8ce4, 0x8ce3, 0x8cda, 0x8cfd, + 0x8cfa, 0x8cfb, 0x8d04, 0x8d05, 0x8d0a, 0x8d07, 0x8d0f, 0x8d0d, + 0x8d10, 0x9f4e, 0x8d13, 0x8ccd, 0x8d14, 0x8d16, 0x8d67, 0x8d6d, + 0x8d71, 0x8d73, 0x8d81, 0x8d99, 0x8dc2, 0x8dbe, 0x8dba, 0x8dcf, + 0x8dda, 0x8dd6, 0x8dcc, 0x8ddb, 0x8dcb, 0x8dea, 0x8deb, 0x8ddf, + 0x8de3, 0x8dfc, 0x8e08, 0x8e09, 0x8dff, 0x8e1d, 0x8e1e, 0x8e10, + 0x8e1f, 0x8e42, 0x8e35, 0x8e30, 0x8e34, 0x8e4a, + /* 0x6d */ + 0x8e47, 0x8e49, 0x8e4c, 0x8e50, 0x8e48, 0x8e59, 0x8e64, 0x8e60, + 0x8e2a, 0x8e63, 0x8e55, 0x8e76, 0x8e72, 0x8e7c, 0x8e81, 0x8e87, + 0x8e85, 0x8e84, 0x8e8b, 0x8e8a, 0x8e93, 0x8e91, 0x8e94, 0x8e99, + 0x8eaa, 0x8ea1, 0x8eac, 0x8eb0, 0x8ec6, 0x8eb1, 0x8ebe, 0x8ec5, + 0x8ec8, 0x8ecb, 0x8edb, 0x8ee3, 0x8efc, 0x8efb, 0x8eeb, 0x8efe, + 0x8f0a, 0x8f05, 0x8f15, 0x8f12, 0x8f19, 0x8f13, 0x8f1c, 0x8f1f, + 0x8f1b, 0x8f0c, 0x8f26, 0x8f33, 0x8f3b, 0x8f39, 0x8f45, 0x8f42, + 0x8f3e, 0x8f4c, 0x8f49, 0x8f46, 0x8f4e, 0x8f57, 0x8f5c, 0x8f62, + 0x8f63, 0x8f64, 0x8f9c, 0x8f9f, 0x8fa3, 0x8fad, 0x8faf, 0x8fb7, + 0x8fda, 0x8fe5, 0x8fe2, 0x8fea, 0x8fef, 0x9087, 0x8ff4, 0x9005, + 0x8ff9, 0x8ffa, 0x9011, 0x9015, 0x9021, 0x900d, 0x901e, 0x9016, + 0x900b, 0x9027, 0x9036, 0x9035, 0x9039, 0x8ff8, + /* 0x6e */ + 0x904f, 0x9050, 0x9051, 0x9052, 0x900e, 0x9049, 0x903e, 0x9056, + 0x9058, 0x905e, 0x9068, 0x906f, 0x9076, 0x96a8, 0x9072, 0x9082, + 0x907d, 0x9081, 0x9080, 0x908a, 0x9089, 0x908f, 0x90a8, 0x90af, + 0x90b1, 0x90b5, 0x90e2, 0x90e4, 0x6248, 0x90db, 0x9102, 0x9112, + 0x9119, 0x9132, 0x9130, 0x914a, 0x9156, 0x9158, 0x9163, 0x9165, + 0x9169, 0x9173, 0x9172, 0x918b, 0x9189, 0x9182, 0x91a2, 0x91ab, + 0x91af, 0x91aa, 0x91b5, 0x91b4, 0x91ba, 0x91c0, 0x91c1, 0x91c9, + 0x91cb, 0x91d0, 0x91d6, 0x91df, 0x91e1, 0x91db, 0x91fc, 0x91f5, + 0x91f6, 0x921e, 0x91ff, 0x9214, 0x922c, 0x9215, 0x9211, 0x925e, + 0x9257, 0x9245, 0x9249, 0x9264, 0x9248, 0x9295, 0x923f, 0x924b, + 0x9250, 0x929c, 0x9296, 0x9293, 0x929b, 0x925a, 0x92cf, 0x92b9, + 0x92b7, 0x92e9, 0x930f, 0x92fa, 0x9344, 0x932e, + /* 0x6f */ + 0x9319, 0x9322, 0x931a, 0x9323, 0x933a, 0x9335, 0x933b, 0x935c, + 0x9360, 0x937c, 0x936e, 0x9356, 0x93b0, 0x93ac, 0x93ad, 0x9394, + 0x93b9, 0x93d6, 0x93d7, 0x93e8, 0x93e5, 0x93d8, 0x93c3, 0x93dd, + 0x93d0, 0x93c8, 0x93e4, 0x941a, 0x9414, 0x9413, 0x9403, 0x9407, + 0x9410, 0x9436, 0x942b, 0x9435, 0x9421, 0x943a, 0x9441, 0x9452, + 0x9444, 0x945b, 0x9460, 0x9462, 0x945e, 0x946a, 0x9229, 0x9470, + 0x9475, 0x9477, 0x947d, 0x945a, 0x947c, 0x947e, 0x9481, 0x947f, + 0x9582, 0x9587, 0x958a, 0x9594, 0x9596, 0x9598, 0x9599, 0x95a0, + 0x95a8, 0x95a7, 0x95ad, 0x95bc, 0x95bb, 0x95b9, 0x95be, 0x95ca, + 0x6ff6, 0x95c3, 0x95cd, 0x95cc, 0x95d5, 0x95d4, 0x95d6, 0x95dc, + 0x95e1, 0x95e5, 0x95e2, 0x9621, 0x9628, 0x962e, 0x962f, 0x9642, + 0x964c, 0x964f, 0x964b, 0x9677, 0x965c, 0x965e, + /* 0x70 */ + 0x965d, 0x965f, 0x9666, 0x9672, 0x966c, 0x968d, 0x9698, 0x9695, + 0x9697, 0x96aa, 0x96a7, 0x96b1, 0x96b2, 0x96b0, 0x96b4, 0x96b6, + 0x96b8, 0x96b9, 0x96ce, 0x96cb, 0x96c9, 0x96cd, 0x894d, 0x96dc, + 0x970d, 0x96d5, 0x96f9, 0x9704, 0x9706, 0x9708, 0x9713, 0x970e, + 0x9711, 0x970f, 0x9716, 0x9719, 0x9724, 0x972a, 0x9730, 0x9739, + 0x973d, 0x973e, 0x9744, 0x9746, 0x9748, 0x9742, 0x9749, 0x975c, + 0x9760, 0x9764, 0x9766, 0x9768, 0x52d2, 0x976b, 0x9771, 0x9779, + 0x9785, 0x977c, 0x9781, 0x977a, 0x9786, 0x978b, 0x978f, 0x9790, + 0x979c, 0x97a8, 0x97a6, 0x97a3, 0x97b3, 0x97b4, 0x97c3, 0x97c6, + 0x97c8, 0x97cb, 0x97dc, 0x97ed, 0x9f4f, 0x97f2, 0x7adf, 0x97f6, + 0x97f5, 0x980f, 0x980c, 0x9838, 0x9824, 0x9821, 0x9837, 0x983d, + 0x9846, 0x984f, 0x984b, 0x986b, 0x986f, 0x9870, + /* 0x71 */ + 0x9871, 0x9874, 0x9873, 0x98aa, 0x98af, 0x98b1, 0x98b6, 0x98c4, + 0x98c3, 0x98c6, 0x98e9, 0x98eb, 0x9903, 0x9909, 0x9912, 0x9914, + 0x9918, 0x9921, 0x991d, 0x991e, 0x9924, 0x9920, 0x992c, 0x992e, + 0x993d, 0x993e, 0x9942, 0x9949, 0x9945, 0x9950, 0x994b, 0x9951, + 0x9952, 0x994c, 0x9955, 0x9997, 0x9998, 0x99a5, 0x99ad, 0x99ae, + 0x99bc, 0x99df, 0x99db, 0x99dd, 0x99d8, 0x99d1, 0x99ed, 0x99ee, + 0x99f1, 0x99f2, 0x99fb, 0x99f8, 0x9a01, 0x9a0f, 0x9a05, 0x99e2, + 0x9a19, 0x9a2b, 0x9a37, 0x9a45, 0x9a42, 0x9a40, 0x9a43, 0x9a3e, + 0x9a55, 0x9a4d, 0x9a5b, 0x9a57, 0x9a5f, 0x9a62, 0x9a65, 0x9a64, + 0x9a69, 0x9a6b, 0x9a6a, 0x9aad, 0x9ab0, 0x9abc, 0x9ac0, 0x9acf, + 0x9ad1, 0x9ad3, 0x9ad4, 0x9ade, 0x9adf, 0x9ae2, 0x9ae3, 0x9ae6, + 0x9aef, 0x9aeb, 0x9aee, 0x9af4, 0x9af1, 0x9af7, + /* 0x72 */ + 0x9afb, 0x9b06, 0x9b18, 0x9b1a, 0x9b1f, 0x9b22, 0x9b23, 0x9b25, + 0x9b27, 0x9b28, 0x9b29, 0x9b2a, 0x9b2e, 0x9b2f, 0x9b32, 0x9b44, + 0x9b43, 0x9b4f, 0x9b4d, 0x9b4e, 0x9b51, 0x9b58, 0x9b74, 0x9b93, + 0x9b83, 0x9b91, 0x9b96, 0x9b97, 0x9b9f, 0x9ba0, 0x9ba8, 0x9bb4, + 0x9bc0, 0x9bca, 0x9bb9, 0x9bc6, 0x9bcf, 0x9bd1, 0x9bd2, 0x9be3, + 0x9be2, 0x9be4, 0x9bd4, 0x9be1, 0x9c3a, 0x9bf2, 0x9bf1, 0x9bf0, + 0x9c15, 0x9c14, 0x9c09, 0x9c13, 0x9c0c, 0x9c06, 0x9c08, 0x9c12, + 0x9c0a, 0x9c04, 0x9c2e, 0x9c1b, 0x9c25, 0x9c24, 0x9c21, 0x9c30, + 0x9c47, 0x9c32, 0x9c46, 0x9c3e, 0x9c5a, 0x9c60, 0x9c67, 0x9c76, + 0x9c78, 0x9ce7, 0x9cec, 0x9cf0, 0x9d09, 0x9d08, 0x9ceb, 0x9d03, + 0x9d06, 0x9d2a, 0x9d26, 0x9daf, 0x9d23, 0x9d1f, 0x9d44, 0x9d15, + 0x9d12, 0x9d41, 0x9d3f, 0x9d3e, 0x9d46, 0x9d48, + /* 0x73 */ + 0x9d5d, 0x9d5e, 0x9d64, 0x9d51, 0x9d50, 0x9d59, 0x9d72, 0x9d89, + 0x9d87, 0x9dab, 0x9d6f, 0x9d7a, 0x9d9a, 0x9da4, 0x9da9, 0x9db2, + 0x9dc4, 0x9dc1, 0x9dbb, 0x9db8, 0x9dba, 0x9dc6, 0x9dcf, 0x9dc2, + 0x9dd9, 0x9dd3, 0x9df8, 0x9de6, 0x9ded, 0x9def, 0x9dfd, 0x9e1a, + 0x9e1b, 0x9e1e, 0x9e75, 0x9e79, 0x9e7d, 0x9e81, 0x9e88, 0x9e8b, + 0x9e8c, 0x9e92, 0x9e95, 0x9e91, 0x9e9d, 0x9ea5, 0x9ea9, 0x9eb8, + 0x9eaa, 0x9ead, 0x9761, 0x9ecc, 0x9ece, 0x9ecf, 0x9ed0, 0x9ed4, + 0x9edc, 0x9ede, 0x9edd, 0x9ee0, 0x9ee5, 0x9ee8, 0x9eef, 0x9ef4, + 0x9ef6, 0x9ef7, 0x9ef9, 0x9efb, 0x9efc, 0x9efd, 0x9f07, 0x9f08, + 0x76b7, 0x9f15, 0x9f21, 0x9f2c, 0x9f3e, 0x9f4a, 0x9f52, 0x9f54, + 0x9f63, 0x9f5f, 0x9f60, 0x9f61, 0x9f66, 0x9f67, 0x9f6c, 0x9f6a, + 0x9f77, 0x9f72, 0x9f76, 0x9f95, 0x9f9c, 0x9fa0, + /* 0x74 */ + 0x582f, 0x69c7, 0x9059, 0x7464, 0x51dc, 0x7199, +}; + +static int +jisx0208_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x21 && c1 <= 0x28) || (c1 >= 0x30 && c1 <= 0x74)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + unsigned short wc = 0xfffd; + if (i < 1410) { + if (i < 690) + wc = jisx0208_2uni_page21[i]; + } else { + if (i < 7808) + wc = jisx0208_2uni_page30[i-1410]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short jisx0208_2charset[6879] = { + 0x2171, 0x2172, 0x2178, 0x212f, 0x224c, 0x216b, 0x215e, 0x212d, + 0x2279, 0x215f, 0x2160, 0x2621, 0x2622, 0x2623, 0x2624, 0x2625, + 0x2626, 0x2627, 0x2628, 0x2629, 0x262a, 0x262b, 0x262c, 0x262d, + 0x262e, 0x262f, 0x2630, 0x2631, 0x2632, 0x2633, 0x2634, 0x2635, + 0x2636, 0x2637, 0x2638, 0x2641, 0x2642, 0x2643, 0x2644, 0x2645, + 0x2646, 0x2647, 0x2648, 0x2649, 0x264a, 0x264b, 0x264c, 0x264d, + 0x264e, 0x264f, 0x2650, 0x2651, 0x2652, 0x2653, 0x2654, 0x2655, + 0x2656, 0x2657, 0x2658, 0x2727, 0x2721, 0x2722, 0x2723, 0x2724, + 0x2725, 0x2726, 0x2728, 0x2729, 0x272a, 0x272b, 0x272c, 0x272d, + 0x272e, 0x272f, 0x2730, 0x2731, 0x2732, 0x2733, 0x2734, 0x2735, + 0x2736, 0x2737, 0x2738, 0x2739, 0x273a, 0x273b, 0x273c, 0x273d, + 0x273e, 0x273f, 0x2740, 0x2741, 0x2751, 0x2752, 0x2753, 0x2754, + 0x2755, 0x2756, 0x2758, 0x2759, 0x275a, 0x275b, 0x275c, 0x275d, + 0x275e, 0x275f, 0x2760, 0x2761, 0x2762, 0x2763, 0x2764, 0x2765, + 0x2766, 0x2767, 0x2768, 0x2769, 0x276a, 0x276b, 0x276c, 0x276d, + 0x276e, 0x276f, 0x2770, 0x2771, 0x2757, 0x213e, 0x213d, 0x2142, + 0x2146, 0x2147, 0x2148, 0x2149, 0x2277, 0x2278, 0x2145, 0x2144, + 0x2273, 0x216c, 0x216d, 0x2228, 0x216e, 0x2272, 0x222b, 0x222c, + 0x222a, 0x222d, 0x224d, 0x224e, 0x224f, 0x225f, 0x2250, 0x2260, + 0x223a, 0x223b, 0x215d, 0x2265, 0x2267, 0x2167, 0x225c, 0x224a, + 0x224b, 0x2241, 0x2240, 0x2269, 0x226a, 0x2168, 0x2268, 0x2266, + 0x2262, 0x2162, 0x2261, 0x2165, 0x2166, 0x2263, 0x2264, 0x223e, + 0x223f, 0x223c, 0x223d, 0x225d, 0x225e, 0x2821, 0x282c, 0x2822, + 0x282d, 0x2823, 0x282e, 0x2824, 0x282f, 0x2826, 0x2831, 0x2825, + 0x2830, 0x2827, 0x283c, 0x2837, 0x2832, 0x2829, 0x283e, 0x2839, + 0x2834, 0x2828, 0x2838, 0x283d, 0x2833, 0x282a, 0x283a, 0x283f, + 0x2835, 0x282b, 0x283b, 0x2840, 0x2836, 0x2223, 0x2222, 0x2225, + 0x2224, 0x2227, 0x2226, 0x2221, 0x217e, 0x217b, 0x217d, 0x217c, + 0x227e, 0x217a, 0x2179, 0x216a, 0x2169, 0x2276, 0x2275, 0x2274, + 0x2121, 0x2122, 0x2123, 0x2137, 0x2139, 0x213a, 0x213b, 0x2152, + 0x2153, 0x2154, 0x2155, 0x2156, 0x2157, 0x2158, 0x2159, 0x215a, + 0x215b, 0x2229, 0x222e, 0x214c, 0x214d, 0x2141, 0x2421, 0x2422, + 0x2423, 0x2424, 0x2425, 0x2426, 0x2427, 0x2428, 0x2429, 0x242a, + 0x242b, 0x242c, 0x242d, 0x242e, 0x242f, 0x2430, 0x2431, 0x2432, + 0x2433, 0x2434, 0x2435, 0x2436, 0x2437, 0x2438, 0x2439, 0x243a, + 0x243b, 0x243c, 0x243d, 0x243e, 0x243f, 0x2440, 0x2441, 0x2442, + 0x2443, 0x2444, 0x2445, 0x2446, 0x2447, 0x2448, 0x2449, 0x244a, + 0x244b, 0x244c, 0x244d, 0x244e, 0x244f, 0x2450, 0x2451, 0x2452, + 0x2453, 0x2454, 0x2455, 0x2456, 0x2457, 0x2458, 0x2459, 0x245a, + 0x245b, 0x245c, 0x245d, 0x245e, 0x245f, 0x2460, 0x2461, 0x2462, + 0x2463, 0x2464, 0x2465, 0x2466, 0x2467, 0x2468, 0x2469, 0x246a, + 0x246b, 0x246c, 0x246d, 0x246e, 0x246f, 0x2470, 0x2471, 0x2472, + 0x2473, 0x212b, 0x212c, 0x2135, 0x2136, 0x2521, 0x2522, 0x2523, + 0x2524, 0x2525, 0x2526, 0x2527, 0x2528, 0x2529, 0x252a, 0x252b, + 0x252c, 0x252d, 0x252e, 0x252f, 0x2530, 0x2531, 0x2532, 0x2533, + 0x2534, 0x2535, 0x2536, 0x2537, 0x2538, 0x2539, 0x253a, 0x253b, + 0x253c, 0x253d, 0x253e, 0x253f, 0x2540, 0x2541, 0x2542, 0x2543, + 0x2544, 0x2545, 0x2546, 0x2547, 0x2548, 0x2549, 0x254a, 0x254b, + 0x254c, 0x254d, 0x254e, 0x254f, 0x2550, 0x2551, 0x2552, 0x2553, + 0x2554, 0x2555, 0x2556, 0x2557, 0x2558, 0x2559, 0x255a, 0x255b, + 0x255c, 0x255d, 0x255e, 0x255f, 0x2560, 0x2561, 0x2562, 0x2563, + 0x2564, 0x2565, 0x2566, 0x2567, 0x2568, 0x2569, 0x256a, 0x256b, + 0x256c, 0x256d, 0x256e, 0x256f, 0x2570, 0x2571, 0x2572, 0x2573, + 0x2574, 0x2575, 0x2576, 0x2126, 0x213c, 0x2133, 0x2134, 0x306c, + 0x437a, 0x3c37, 0x4b7c, 0x3e66, 0x3b30, 0x3e65, 0x323c, 0x4954, + 0x4d3f, 0x5022, 0x312f, 0x336e, 0x5023, 0x4024, 0x5242, 0x3556, + 0x4a3a, 0x3e67, 0x4e3e, 0x4a42, 0x5024, 0x4366, 0x5025, 0x367a, + 0x5026, 0x345d, 0x4330, 0x3c67, 0x5027, 0x5028, 0x5029, 0x4735, + 0x3557, 0x4737, 0x4663, 0x3843, 0x4b33, 0x6949, 0x502a, 0x3e68, + 0x502b, 0x3235, 0x3665, 0x3870, 0x4c69, 0x5626, 0x4d70, 0x467d, + 0x3425, 0x3535, 0x502c, 0x502d, 0x4e3b, 0x4d3d, 0x4168, 0x502f, + 0x3b76, 0x4673, 0x5032, 0x313e, 0x385f, 0x385e, 0x3066, 0x4f4b, + 0x4f4a, 0x3a33, 0x3021, 0x5033, 0x5034, 0x5035, 0x4b34, 0x5036, + 0x3872, 0x3067, 0x4b72, 0x357c, 0x357d, 0x357e, 0x4462, 0x4e3c, + 0x5037, 0x5038, 0x5039, 0x3f4d, 0x3d3a, 0x3f4e, 0x503e, 0x503c, + 0x503d, 0x3558, 0x3a23, 0x3270, 0x503b, 0x503a, 0x4a29, 0x3b46, + 0x3b45, 0x423e, 0x503f, 0x4955, 0x4067, 0x2138, 0x5040, 0x5042, + 0x4265, 0x4e61, 0x304a, 0x5041, 0x323e, 0x3644, 0x4367, 0x376f, + 0x5043, 0x4724, 0x346b, 0x5044, 0x304b, 0x3860, 0x346c, 0x497a, + 0x4832, 0x3559, 0x3271, 0x5067, 0x4541, 0x476c, 0x5046, 0x483c, + 0x4e62, 0x3f2d, 0x3b47, 0x3b77, 0x3240, 0x4451, 0x4322, 0x504a, + 0x304c, 0x4463, 0x3d3b, 0x3a34, 0x4d24, 0x424e, 0x323f, 0x5049, + 0x4d3e, 0x5045, 0x5047, 0x3a6e, 0x5048, 0x5524, 0x5050, 0x5053, + 0x5051, 0x3242, 0x4a3b, 0x504b, 0x504f, 0x3873, 0x3b48, 0x3426, + 0x5054, 0x504c, 0x4e63, 0x3b78, 0x504d, 0x5052, 0x5055, 0x504e, + 0x3621, 0x304d, 0x3622, 0x3241, 0x5525, 0x4b79, 0x496e, 0x3874, + 0x3f2f, 0x4e37, 0x4a58, 0x3738, 0x4225, 0x3264, 0x3d53, 0x5059, + 0x505e, 0x505c, 0x5057, 0x422f, 0x505a, 0x505d, 0x505b, 0x4a5d, + 0x5058, 0x3f2e, 0x4b73, 0x505f, 0x5060, 0x3d24, 0x506d, 0x4750, + 0x4936, 0x5068, 0x4a70, 0x3236, 0x506c, 0x5066, 0x506f, 0x4152, + 0x3844, 0x475c, 0x6047, 0x506e, 0x455d, 0x5063, 0x3876, 0x3875, + 0x5061, 0x3c5a, 0x5069, 0x4a6f, 0x434d, 0x5065, 0x3771, 0x5062, + 0x506a, 0x5064, 0x4e51, 0x506b, 0x4f41, 0x3666, 0x3770, 0x5070, + 0x5071, 0x5075, 0x304e, 0x4a50, 0x5074, 0x5073, 0x5077, 0x5076, + 0x4464, 0x3772, 0x5078, 0x3c45, 0x4226, 0x4465, 0x3676, 0x5079, + 0x3536, 0x507a, 0x507c, 0x4b35, 0x3766, 0x3b31, 0x4877, 0x507b, + 0x3a45, 0x4d43, 0x507e, 0x5123, 0x507d, 0x3a44, 0x3d7d, 0x3739, + 0x5124, 0x364f, 0x5121, 0x5122, 0x462f, 0x417c, 0x3623, 0x4b4d, + 0x5125, 0x4e3d, 0x5126, 0x5129, 0x5127, 0x414e, 0x5128, 0x512a, + 0x512c, 0x512b, 0x4a48, 0x3537, 0x512e, 0x512f, 0x322f, 0x512d, + 0x3c74, 0x5132, 0x5131, 0x5130, 0x5056, 0x5133, 0x3d7e, 0x5134, + 0x4d25, 0x4c59, 0x5136, 0x5135, 0x5138, 0x5137, 0x5139, 0x513a, + 0x3074, 0x3835, 0x373b, 0x3d3c, 0x437b, 0x3624, 0x4068, 0x3877, + 0x396e, 0x513c, 0x4c48, 0x4546, 0x3b79, 0x513b, 0x513d, 0x455e, + 0x3375, 0x513e, 0x467e, 0x4134, 0x5140, 0x5141, 0x482c, 0x3878, + 0x4f3b, 0x5142, 0x3626, 0x4a3c, 0x4236, 0x3671, 0x4535, 0x3773, + 0x5143, 0x5144, 0x4662, 0x315f, 0x5147, 0x3a7d, 0x5146, 0x3a46, + 0x5148, 0x666e, 0x5149, 0x4b41, 0x514a, 0x514b, 0x514c, 0x3e69, + 0x3c4c, 0x3427, 0x514f, 0x514d, 0x4c3d, 0x514e, 0x495a, 0x5150, + 0x5151, 0x5152, 0x455f, 0x5156, 0x5154, 0x5155, 0x5153, 0x3a63, + 0x5157, 0x4c6a, 0x4e64, 0x5158, 0x4028, 0x5159, 0x3d5a, 0x515a, + 0x437c, 0x4e3f, 0x4560, 0x5245, 0x515b, 0x7425, 0x3645, 0x515c, + 0x4b5e, 0x3d68, 0x427c, 0x515e, 0x4664, 0x515f, 0x5160, 0x332e, + 0x5161, 0x3627, 0x464c, 0x317a, 0x3d50, 0x4821, 0x5162, 0x4561, + 0x3f4f, 0x5163, 0x4a2c, 0x405a, 0x3422, 0x3429, 0x5164, 0x5166, + 0x373a, 0x5165, 0x4e73, 0x3d69, 0x483d, 0x4a4c, 0x5167, 0x4d78, + 0x5168, 0x5169, 0x457e, 0x516a, 0x4029, 0x3a7e, 0x3774, 0x516b, + 0x3b49, 0x396f, 0x4466, 0x516d, 0x4227, 0x3a6f, 0x516e, 0x516f, + 0x4130, 0x516c, 0x5171, 0x4b36, 0x3964, 0x5170, 0x3775, 0x3a5e, + 0x476d, 0x5174, 0x5172, 0x497b, 0x3e6a, 0x517b, 0x3364, 0x5175, + 0x5173, 0x414f, 0x5177, 0x5176, 0x3344, 0x3760, 0x517c, 0x4e2d, + 0x5178, 0x517d, 0x517a, 0x5179, 0x4e4f, 0x3879, 0x3243, 0x4e74, + 0x3d75, 0x4558, 0x3965, 0x5222, 0x5223, 0x4e65, 0x4f2b, 0x5225, + 0x387a, 0x5224, 0x332f, 0x5226, 0x4b56, 0x443c, 0x4d26, 0x4a59, + 0x5227, 0x7055, 0x4630, 0x5228, 0x342a, 0x4c33, 0x3e21, 0x5229, + 0x4a67, 0x522d, 0x402a, 0x522a, 0x3650, 0x522b, 0x342b, 0x372e, + 0x522e, 0x522f, 0x5230, 0x5231, 0x3c5b, 0x387b, 0x4c5e, 0x4c68, + 0x4677, 0x4a71, 0x5232, 0x5233, 0x5235, 0x5237, 0x5236, 0x5238, + 0x323d, 0x4b4c, 0x3a7c, 0x5239, 0x4159, 0x3e22, 0x3629, 0x523a, + 0x485b, 0x523b, 0x523c, 0x523d, 0x523e, 0x4924, 0x3668, 0x3065, + 0x463f, 0x523f, 0x3d3d, 0x4069, 0x5241, 0x5240, 0x3e23, 0x3861, + 0x5243, 0x483e, 0x5244, 0x485c, 0x4234, 0x426e, 0x3628, 0x466e, + 0x4331, 0x476e, 0x4b4e, 0x5246, 0x406a, 0x3735, 0x5247, 0x5248, + 0x312c, 0x3075, 0x346d, 0x4228, 0x3551, 0x4d71, 0x524b, 0x3237, + 0x524a, 0x362a, 0x524c, 0x4c71, 0x524d, 0x4e52, 0x387c, 0x3836, + 0x524e, 0x5250, 0x524f, 0x3f5f, 0x3139, 0x315e, 0x5251, 0x5252, + 0x3837, 0x5253, 0x356e, 0x3b32, 0x5254, 0x4b74, 0x3a35, 0x355a, + 0x4d27, 0x4150, 0x483f, 0x3c7d, 0x3d47, 0x3c68, 0x3c75, 0x3d76, + 0x4840, 0x5257, 0x3143, 0x4151, 0x387d, 0x3845, 0x3667, 0x525b, + 0x4321, 0x427e, 0x362b, 0x3e24, 0x525c, 0x525a, 0x3244, 0x4266, + 0x3c38, 0x3b4b, 0x3126, 0x3370, 0x3966, 0x3b4a, 0x525d, 0x525e, + 0x3549, 0x3346, 0x3967, 0x3548, 0x445f, 0x3125, 0x4631, 0x4c3e, + 0x3921, 0x4d79, 0x4547, 0x387e, 0x372f, 0x5267, 0x3663, 0x4b4a, + 0x485d, 0x5266, 0x345e, 0x5261, 0x5262, 0x5264, 0x5265, 0x355b, + 0x3f61, 0x4a2d, 0x5263, 0x525f, 0x3863, 0x5260, 0x4f24, 0x4a72, + 0x4468, 0x3862, 0x3970, 0x5268, 0x465d, 0x526c, 0x3c7e, 0x3c76, + 0x526f, 0x526d, 0x4c23, 0x526a, 0x5273, 0x526e, 0x5271, 0x3846, + 0x4c3f, 0x5272, 0x5274, 0x5276, 0x3a70, 0x4f42, 0x526b, 0x5269, + 0x5275, 0x5270, 0x5278, 0x5323, 0x527a, 0x527e, 0x5321, 0x527b, + 0x533e, 0x3a69, 0x3331, 0x5279, 0x5325, 0x3076, 0x5324, 0x3025, + 0x494a, 0x5322, 0x527c, 0x5277, 0x527d, 0x3a48, 0x5326, 0x3077, + 0x532f, 0x5327, 0x5328, 0x3e25, 0x4b69, 0x532d, 0x532c, 0x452f, + 0x532e, 0x532b, 0x3134, 0x3a36, 0x3f30, 0x5329, 0x4562, 0x532a, + 0x3022, 0x5334, 0x4d23, 0x3e27, 0x533a, 0x5339, 0x5330, 0x4243, + 0x5331, 0x426f, 0x5336, 0x3e26, 0x5333, 0x4c64, 0x373c, 0x5337, + 0x5338, 0x5335, 0x533b, 0x5332, 0x5341, 0x5346, 0x5342, 0x533d, + 0x5347, 0x4131, 0x5349, 0x3922, 0x533f, 0x437d, 0x5343, 0x533c, + 0x342d, 0x346e, 0x3365, 0x5344, 0x5340, 0x3776, 0x534a, 0x5348, + 0x4153, 0x354a, 0x362c, 0x5345, 0x3674, 0x3144, 0x534e, 0x534c, + 0x5427, 0x5351, 0x534b, 0x534f, 0x534d, 0x3b4c, 0x5350, 0x5353, + 0x5358, 0x5356, 0x5355, 0x4332, 0x3245, 0x5352, 0x5354, 0x3e28, + 0x3133, 0x5357, 0x325e, 0x5362, 0x3e7c, 0x535e, 0x535c, 0x535d, + 0x535f, 0x313d, 0x4139, 0x5359, 0x535a, 0x337a, 0x5361, 0x346f, + 0x5364, 0x5360, 0x5363, 0x4a2e, 0x4655, 0x4838, 0x5366, 0x5365, + 0x3345, 0x5367, 0x536a, 0x5369, 0x5368, 0x4739, 0x536b, 0x536c, + 0x536e, 0x536d, 0x5370, 0x5373, 0x5371, 0x536f, 0x5372, 0x5374, + 0x5375, 0x5376, 0x5377, 0x5378, 0x5145, 0x3c7c, 0x3b4d, 0x3273, + 0x3078, 0x4344, 0x5379, 0x3a24, 0x304f, 0x3f5e, 0x537a, 0x3847, + 0x3971, 0x537c, 0x537b, 0x4a60, 0x537d, 0x5421, 0x537e, 0x5422, + 0x5423, 0x3777, 0x3160, 0x5424, 0x5426, 0x5425, 0x5428, 0x455a, + 0x5429, 0x3035, 0x3a5f, 0x373d, 0x434f, 0x542a, 0x542b, 0x542d, + 0x542e, 0x3a64, 0x3651, 0x4b37, 0x542c, 0x542f, 0x3a41, 0x3923, + 0x5433, 0x3a25, 0x4333, 0x5430, 0x445a, 0x5434, 0x3f62, 0x5432, + 0x5435, 0x373f, 0x5436, 0x5437, 0x3924, 0x3340, 0x5439, 0x543a, + 0x543b, 0x5438, 0x5431, 0x543c, 0x543d, 0x4b64, 0x3e6b, 0x543f, + 0x5440, 0x543e, 0x5442, 0x4738, 0x3068, 0x4956, 0x5443, 0x3e7d, + 0x3c39, 0x475d, 0x3470, 0x3a6b, 0x4b59, 0x4632, 0x3778, 0x424f, + 0x5441, 0x5444, 0x4244, 0x5445, 0x5446, 0x5448, 0x4469, 0x342e, + 0x7421, 0x3161, 0x4a73, 0x3e6c, 0x4548, 0x3a66, 0x544e, 0x4a3d, + 0x4e5d, 0x3274, 0x544a, 0x413a, 0x544d, 0x4563, 0x4549, 0x4564, + 0x4839, 0x444d, 0x3a49, 0x5449, 0x3176, 0x4536, 0x544b, 0x5447, + 0x3f50, 0x544f, 0x3d4e, 0x362d, 0x5450, 0x4a68, 0x417d, 0x4446, + 0x5452, 0x4b4f, 0x5453, 0x5458, 0x4a2f, 0x5457, 0x5451, 0x5454, + 0x5456, 0x3a26, 0x4a49, 0x5459, 0x4345, 0x3275, 0x3e6d, 0x545b, + 0x545a, 0x3968, 0x545c, 0x545e, 0x545d, 0x5460, 0x5455, 0x5462, + 0x5461, 0x545f, 0x3b4e, 0x3f51, 0x4154, 0x5463, 0x403c, 0x306d, + 0x4764, 0x445b, 0x5465, 0x5464, 0x5466, 0x5467, 0x5468, 0x5469, + 0x4a51, 0x546a, 0x3246, 0x546b, 0x4d3c, 0x3330, 0x5249, 0x3d48, + 0x423f, 0x546c, 0x4c6b, 0x4c34, 0x546e, 0x4267, 0x4537, 0x4240, + 0x4957, 0x546f, 0x5470, 0x317b, 0x3c3a, 0x5471, 0x3050, 0x5472, + 0x5473, 0x3162, 0x3471, 0x4660, 0x4a74, 0x5477, 0x4155, 0x5476, + 0x3740, 0x4b5b, 0x5475, 0x4565, 0x5479, 0x5478, 0x547b, 0x547a, + 0x317c, 0x547c, 0x3e29, 0x547e, 0x4325, 0x547d, 0x4a33, 0x3d77, + 0x455b, 0x5521, 0x3925, 0x5522, 0x4721, 0x485e, 0x4c51, 0x4725, + 0x552b, 0x3538, 0x4d45, 0x4c2f, 0x562c, 0x5523, 0x5526, 0x4245, + 0x4b38, 0x454a, 0x5527, 0x4b65, 0x3a4a, 0x3e2a, 0x5528, 0x3b50, + 0x3b4f, 0x3039, 0x3848, 0x402b, 0x3051, 0x552c, 0x552d, 0x552a, + 0x3138, 0x342f, 0x5529, 0x4c45, 0x4931, 0x3028, 0x3079, 0x3b51, + 0x3052, 0x3023, 0x5532, 0x5530, 0x4c3c, 0x5533, 0x5531, 0x552f, + 0x3f31, 0x552e, 0x4a5a, 0x3864, 0x5537, 0x5538, 0x3e2b, 0x5534, + 0x4f2c, 0x474c, 0x5536, 0x3a27, 0x5539, 0x4958, 0x553a, 0x5535, + 0x4c3b, 0x475e, 0x553b, 0x4932, 0x553c, 0x5540, 0x553d, 0x3247, + 0x553f, 0x3c3b, 0x553e, 0x3779, 0x554c, 0x5545, 0x5542, 0x4364, + 0x5541, 0x5543, 0x5544, 0x5546, 0x5547, 0x3472, 0x5549, 0x5548, + 0x554a, 0x3e6e, 0x554d, 0x445c, 0x3145, 0x554b, 0x554e, 0x554f, + 0x5552, 0x5550, 0x5551, 0x3b52, 0x5553, 0x3926, 0x5554, 0x3b7a, + 0x4238, 0x5555, 0x5556, 0x3b5a, 0x3927, 0x4c52, 0x3528, 0x3849, + 0x5557, 0x3358, 0x5558, 0x4239, 0x5559, 0x5623, 0x555a, 0x555b, + 0x555c, 0x555e, 0x555f, 0x5560, 0x4270, 0x3127, 0x3c69, 0x3042, + 0x4157, 0x3430, 0x3c35, 0x3928, 0x4566, 0x3d21, 0x3431, 0x4368, + 0x446a, 0x3038, 0x3539, 0x4a75, 0x3c42, 0x3552, 0x406b, 0x3c3c, + 0x4d28, 0x5561, 0x355c, 0x3a4b, 0x3332, 0x3163, 0x3e2c, 0x3248, + 0x5562, 0x4d46, 0x3d49, 0x3c64, 0x5563, 0x3473, 0x4652, 0x4c29, + 0x5564, 0x5565, 0x4959, 0x5567, 0x3428, 0x3677, 0x5566, 0x3432, + 0x3f32, 0x556b, 0x3b21, 0x3249, 0x556a, 0x5568, 0x556c, 0x5569, + 0x472b, 0x5c4d, 0x3f33, 0x556d, 0x4e40, 0x556e, 0x5570, 0x437e, + 0x556f, 0x4023, 0x3b7b, 0x4250, 0x3c77, 0x4975, 0x406c, 0x3c4d, + 0x5571, 0x3e2d, 0x5572, 0x5573, 0x3053, 0x423a, 0x3f52, 0x5574, + 0x4633, 0x3e2e, 0x3e2f, 0x5575, 0x406d, 0x3e30, 0x5576, 0x5577, + 0x4c60, 0x5578, 0x3646, 0x3d22, 0x5579, 0x557a, 0x3c5c, 0x3f2c, + 0x4674, 0x3f54, 0x4878, 0x4722, 0x3649, 0x557b, 0x356f, 0x557c, + 0x367e, 0x464f, 0x3230, 0x3b53, 0x557d, 0x5622, 0x5621, 0x367d, + 0x557e, 0x4538, 0x4230, 0x454b, 0x3c48, 0x4158, 0x4d7a, 0x5624, + 0x5625, 0x4656, 0x3b33, 0x5627, 0x5628, 0x5629, 0x3474, 0x562a, + 0x562b, 0x322c, 0x413b, 0x3464, 0x562d, 0x4c28, 0x4252, 0x3359, + 0x562f, 0x5631, 0x345f, 0x562e, 0x5630, 0x5633, 0x5632, 0x5634, + 0x5635, 0x463d, 0x362e, 0x3265, 0x5636, 0x563b, 0x5639, 0x4a77, + 0x4a76, 0x4567, 0x5638, 0x3d54, 0x5637, 0x3f72, 0x563c, 0x3a6a, + 0x5642, 0x5643, 0x563d, 0x3333, 0x563e, 0x5647, 0x5646, 0x5645, + 0x5641, 0x5640, 0x5644, 0x4a78, 0x564b, 0x5648, 0x564a, 0x4d72, + 0x5649, 0x563f, 0x3f73, 0x564c, 0x3a37, 0x564d, 0x564e, 0x5651, + 0x5650, 0x564f, 0x4568, 0x563a, 0x5657, 0x5653, 0x5652, 0x5654, + 0x5655, 0x5658, 0x4e66, 0x5659, 0x5656, 0x565a, 0x3460, 0x565b, + 0x565d, 0x565c, 0x565e, 0x565f, 0x406e, 0x3d23, 0x3d64, 0x4163, + 0x3929, 0x3a38, 0x392a, 0x3570, 0x5660, 0x3a39, 0x384a, 0x5661, + 0x4c26, 0x4743, 0x5662, 0x392b, 0x342c, 0x4327, 0x3652, 0x3b54, + 0x495b, 0x4841, 0x5663, 0x3475, 0x5666, 0x4421, 0x5665, 0x5664, + 0x5667, 0x446b, 0x3f63, 0x3b55, 0x404a, 0x4253, 0x3522, 0x4422, + 0x5668, 0x5669, 0x3e6f, 0x4b39, 0x566c, 0x566b, 0x566a, 0x497d, + 0x5673, 0x4b5a, 0x566d, 0x566f, 0x4b6b, 0x566e, 0x5670, 0x4828, + 0x5671, 0x4a3e, 0x5672, 0x3433, 0x4a3f, 0x472f, 0x5674, 0x5675, + 0x392c, 0x3434, 0x5676, 0x3838, 0x4d44, 0x4d29, 0x3476, 0x5678, + 0x4423, 0x392d, 0x3e31, 0x485f, 0x3e32, 0x3d78, 0x446c, 0x4a79, + 0x4539, 0x392e, 0x495c, 0x5679, 0x4559, 0x3a42, 0x384b, 0x446d, + 0x3043, 0x3d6e, 0x392f, 0x4d47, 0x567a, 0x567b, 0x4751, 0x567c, + 0x4e77, 0x4f2d, 0x567e, 0x567d, 0x3347, 0x5721, 0x5724, 0x5725, + 0x5723, 0x4940, 0x3e33, 0x5727, 0x5726, 0x5722, 0x5728, 0x5729, + 0x572a, 0x572d, 0x572b, 0x572c, 0x572e, 0x3164, 0x446e, 0x572f, + 0x377a, 0x3276, 0x4736, 0x5730, 0x467b, 0x4a5b, 0x5731, 0x4f2e, + 0x5732, 0x4a40, 0x5735, 0x5021, 0x5031, 0x3c30, 0x4675, 0x5736, + 0x355d, 0x4424, 0x307a, 0x5737, 0x4a26, 0x3930, 0x4350, 0x446f, + 0x4c6f, 0x3839, 0x384c, 0x5738, 0x5739, 0x573f, 0x3c65, 0x4425, + 0x362f, 0x573a, 0x492b, 0x4346, 0x573b, 0x573c, 0x3630, 0x573d, + 0x573e, 0x5740, 0x4576, 0x5741, 0x5742, 0x5743, 0x5734, 0x5733, + 0x5744, 0x3741, 0x4927, 0x3a4c, 0x4937, 0x4426, 0x494b, 0x5745, + 0x3e34, 0x3146, 0x5746, 0x5747, 0x4c72, 0x4860, 0x574a, 0x317d, + 0x402c, 0x5749, 0x5748, 0x3742, 0x4254, 0x574e, 0x574c, 0x574b, + 0x4e27, 0x3865, 0x3d79, 0x574d, 0x454c, 0x3d3e, 0x4640, 0x5751, + 0x5750, 0x574f, 0x5752, 0x3866, 0x5753, 0x497c, 0x3d5b, 0x5754, + 0x4879, 0x4641, 0x4427, 0x4530, 0x5755, 0x352b, 0x3f34, 0x492c, + 0x3477, 0x4726, 0x5756, 0x3b56, 0x4b3a, 0x4b3b, 0x317e, 0x575b, + 0x4369, 0x5758, 0x3277, 0x582d, 0x575a, 0x4730, 0x5759, 0x5757, + 0x397a, 0x575d, 0x5763, 0x5769, 0x5761, 0x455c, 0x5766, 0x495d, + 0x5760, 0x5765, 0x4e67, 0x3b57, 0x4255, 0x575e, 0x355e, 0x5768, + 0x402d, 0x3165, 0x5762, 0x3278, 0x5767, 0x3631, 0x5764, 0x576a, + 0x576c, 0x5776, 0x5774, 0x5771, 0x5770, 0x4e78, 0x5772, 0x3632, + 0x3931, 0x3d7a, 0x5779, 0x576b, 0x576f, 0x575f, 0x327a, 0x5773, + 0x5775, 0x4351, 0x3a28, 0x3238, 0x576d, 0x5778, 0x5777, 0x3633, + 0x4229, 0x3366, 0x3743, 0x576e, 0x577a, 0x577d, 0x5821, 0x3c3d, + 0x5827, 0x4470, 0x577b, 0x5825, 0x3279, 0x5823, 0x5824, 0x577e, + 0x5822, 0x3867, 0x4d2a, 0x3435, 0x3159, 0x5826, 0x473a, 0x302d, + 0x4861, 0x575c, 0x582c, 0x5830, 0x4c65, 0x5829, 0x4569, 0x582e, + 0x3e70, 0x582f, 0x4657, 0x4f47, 0x582b, 0x5831, 0x397b, 0x404b, + 0x3054, 0x582a, 0x5828, 0x415a, 0x577c, 0x3b34, 0x4246, 0x583d, + 0x415b, 0x5838, 0x5835, 0x5836, 0x3c66, 0x5839, 0x583c, 0x5837, + 0x3d25, 0x583a, 0x5834, 0x4c7c, 0x4c7b, 0x583e, 0x583f, 0x3055, + 0x5833, 0x3672, 0x3026, 0x3436, 0x583b, 0x5843, 0x5842, 0x5847, + 0x5848, 0x5846, 0x5849, 0x5841, 0x5845, 0x584a, 0x584b, 0x5840, + 0x3b7c, 0x5844, 0x4256, 0x3932, 0x5832, 0x3f35, 0x5858, 0x4a69, + 0x584e, 0x584f, 0x5850, 0x5857, 0x5856, 0x4b7d, 0x3437, 0x5854, + 0x3745, 0x3334, 0x5851, 0x4e38, 0x5853, 0x3056, 0x5855, 0x584c, + 0x5852, 0x5859, 0x3744, 0x584d, 0x4d5d, 0x4d2b, 0x585c, 0x5860, + 0x417e, 0x4e79, 0x5861, 0x585e, 0x585b, 0x585a, 0x585f, 0x4a30, + 0x4634, 0x3746, 0x5862, 0x585d, 0x5863, 0x377b, 0x3231, 0x586b, + 0x3438, 0x5869, 0x586a, 0x3a29, 0x5868, 0x5866, 0x5865, 0x586c, + 0x5864, 0x586e, 0x327b, 0x5870, 0x586f, 0x4428, 0x5873, 0x5871, + 0x5867, 0x377c, 0x5872, 0x5876, 0x5875, 0x5877, 0x5874, 0x5878, + 0x5879, 0x587a, 0x4a6a, 0x587c, 0x587b, 0x3d3f, 0x402e, 0x3266, + 0x327c, 0x587d, 0x303f, 0x404c, 0x587e, 0x6c43, 0x5921, 0x3761, + 0x5922, 0x406f, 0x5923, 0x5924, 0x353a, 0x5925, 0x5926, 0x5927, + 0x4257, 0x384d, 0x4c61, 0x4b3c, 0x3d6a, 0x5928, 0x4070, 0x6e3d, + 0x4862, 0x3c6a, 0x3a4d, 0x5929, 0x4247, 0x4a27, 0x4271, 0x592c, + 0x592a, 0x592d, 0x592b, 0x592e, 0x4a31, 0x3037, 0x495e, 0x4863, + 0x592f, 0x5932, 0x3e35, 0x353b, 0x5930, 0x5937, 0x3e36, 0x5931, + 0x4744, 0x4d5e, 0x5933, 0x5934, 0x5938, 0x456a, 0x5935, 0x3933, + 0x405e, 0x5946, 0x4834, 0x4272, 0x4864, 0x5a2d, 0x4a7a, 0x4471, + 0x4b75, 0x593b, 0x3221, 0x436a, 0x5944, 0x4334, 0x593e, 0x5945, + 0x5940, 0x5947, 0x5943, 0x5942, 0x476f, 0x593c, 0x327d, 0x593a, + 0x3571, 0x4273, 0x5936, 0x5939, 0x3934, 0x405b, 0x3e37, 0x5941, + 0x4752, 0x3572, 0x3348, 0x3367, 0x3f21, 0x5949, 0x594e, 0x594a, + 0x377d, 0x594f, 0x3b22, 0x3969, 0x3d26, 0x593d, 0x3b7d, 0x594c, + 0x3b58, 0x594d, 0x3044, 0x5948, 0x4429, 0x3573, 0x3634, 0x594b, + 0x3027, 0x3a43, 0x3f36, 0x4472, 0x4854, 0x5951, 0x415e, 0x422a, + 0x3b2b, 0x5952, 0x5954, 0x5950, 0x4a61, 0x443d, 0x415c, 0x4a7b, + 0x3c4e, 0x5960, 0x595f, 0x3f78, 0x377e, 0x5959, 0x3e39, 0x4668, + 0x4731, 0x5957, 0x415d, 0x3c78, 0x595c, 0x3e38, 0x5956, 0x595b, + 0x4753, 0x5955, 0x3721, 0x335d, 0x595d, 0x4e2b, 0x3a4e, 0x4335, + 0x595a, 0x405c, 0x3935, 0x3f64, 0x3166, 0x413c, 0x5958, 0x3545, + 0x3747, 0x444f, 0x595e, 0x415f, 0x5961, 0x5963, 0x4237, 0x5969, + 0x5964, 0x5966, 0x4941, 0x4473, 0x5967, 0x4d2c, 0x4d48, 0x3439, + 0x302e, 0x5965, 0x5962, 0x3478, 0x3167, 0x5968, 0x4d49, 0x596c, + 0x423b, 0x5973, 0x596d, 0x596a, 0x5971, 0x5953, 0x596e, 0x5972, + 0x4842, 0x456b, 0x596b, 0x596f, 0x3748, 0x3a71, 0x405d, 0x5977, + 0x4526, 0x5974, 0x4b60, 0x5975, 0x5976, 0x4c4e, 0x4022, 0x3762, + 0x597d, 0x3b35, 0x597a, 0x5979, 0x4732, 0x4635, 0x4531, 0x597b, + 0x597c, 0x496f, 0x4745, 0x3b23, 0x4071, 0x4b50, 0x3349, 0x5a25, + 0x597e, 0x4d4a, 0x5a27, 0x5a23, 0x5a24, 0x4160, 0x5a22, 0x593f, + 0x5a26, 0x5a21, 0x5a2b, 0x5a2c, 0x4527, 0x5a2e, 0x3b24, 0x5a29, + 0x353c, 0x5a2f, 0x5a28, 0x5a33, 0x5a32, 0x5a31, 0x5a34, 0x5a36, + 0x3e71, 0x5a35, 0x5a39, 0x5a37, 0x5a38, 0x5970, 0x5a3b, 0x5a3a, + 0x5978, 0x5a3c, 0x5a30, 0x3b59, 0x5a3d, 0x5a3e, 0x5a40, 0x5a3f, + 0x5a41, 0x327e, 0x3936, 0x4a7c, 0x402f, 0x384e, 0x5a43, 0x5a46, + 0x4952, 0x355f, 0x5a45, 0x5a44, 0x4754, 0x5a47, 0x3635, 0x5a49, + 0x5a48, 0x343a, 0x3b36, 0x4658, 0x3749, 0x3f74, 0x5a4a, 0x4030, + 0x4528, 0x495f, 0x5a4b, 0x5a4c, 0x5a4d, 0x4a38, 0x555d, 0x4046, + 0x494c, 0x3a58, 0x4865, 0x4843, 0x454d, 0x4e41, 0x5a4f, 0x3c50, + 0x5a50, 0x3036, 0x3654, 0x404d, 0x4960, 0x5a51, 0x3b42, 0x4347, + 0x3b5b, 0x3f37, 0x5a52, 0x4a7d, 0x3177, 0x3b5c, 0x5a55, 0x5a53, + 0x5a56, 0x4e39, 0x5a54, 0x407b, 0x5a57, 0x4232, 0x5a58, 0x347a, + 0x5a5a, 0x5a59, 0x5a5b, 0x5a5c, 0x347b, 0x467c, 0x4336, 0x356c, + 0x3b5d, 0x4161, 0x3d5c, 0x3030, 0x5a5d, 0x3222, 0x5a61, 0x3937, + 0x5a60, 0x3a2b, 0x3e3a, 0x5a5f, 0x3e3b, 0x4c40, 0x3a2a, 0x3057, + 0x404e, 0x5a66, 0x4031, 0x3147, 0x3d55, 0x4b66, 0x3a72, 0x3e3c, + 0x4027, 0x5a65, 0x5a63, 0x5a64, 0x436b, 0x5b26, 0x5a6a, 0x3b7e, + 0x3938, 0x5a68, 0x5a69, 0x3f38, 0x5a67, 0x3b2f, 0x5a6c, 0x5a6b, + 0x5a70, 0x5a71, 0x5a6d, 0x3322, 0x5a6e, 0x5a6f, 0x4855, 0x4961, + 0x374a, 0x5a72, 0x4032, 0x3e3d, 0x4352, 0x3647, 0x5a73, 0x5a77, + 0x324b, 0x5a74, 0x5a76, 0x5a75, 0x3d6b, 0x4348, 0x3045, 0x5a78, + 0x5a79, 0x442a, 0x4e71, 0x3b43, 0x4a6b, 0x4b3d, 0x5b22, 0x5a7b, + 0x5a7e, 0x5a7d, 0x5a7a, 0x5b21, 0x465e, 0x5a7c, 0x5b23, 0x3d6c, + 0x5b24, 0x4d4b, 0x4778, 0x5b25, 0x5b27, 0x5b28, 0x5b29, 0x364a, + 0x3148, 0x3939, 0x5b2a, 0x5b2b, 0x3d71, 0x4162, 0x5258, 0x413e, + 0x413d, 0x4258, 0x3a47, 0x5072, 0x376e, 0x4d2d, 0x4a7e, 0x497e, + 0x5b2c, 0x3a73, 0x443f, 0x5b2d, 0x4f2f, 0x4b3e, 0x442b, 0x5b2e, + 0x347c, 0x5b2f, 0x5b30, 0x4c5a, 0x4c24, 0x4b76, 0x4b5c, 0x3b25, + 0x5b32, 0x3c6b, 0x4b51, 0x5b34, 0x5b37, 0x5b36, 0x3479, 0x3560, + 0x5b33, 0x5b35, 0x5b38, 0x3f79, 0x4d7b, 0x3049, 0x3a60, 0x423c, + 0x3c5d, 0x3e73, 0x5b3b, 0x454e, 0x5b39, 0x422b, 0x5b3a, 0x3e72, + 0x4c5d, 0x5b3c, 0x5b3d, 0x4d68, 0x5b42, 0x393a, 0x4755, 0x5b3f, + 0x456c, 0x5a5e, 0x5a62, 0x354f, 0x4747, 0x5b41, 0x3e3e, 0x4844, + 0x5b47, 0x487a, 0x5b3e, 0x5b44, 0x5b43, 0x404f, 0x4b6d, 0x4e53, + 0x4b67, 0x324c, 0x3b5e, 0x4f48, 0x5b46, 0x3f75, 0x5b45, 0x5b40, + 0x384f, 0x5b4c, 0x5b4a, 0x324d, 0x5b48, 0x5b4e, 0x5b54, 0x4248, + 0x4a41, 0x5b56, 0x4922, 0x5b55, 0x4770, 0x4b3f, 0x343b, 0x4077, + 0x3d40, 0x4453, 0x4d2e, 0x5b51, 0x5b50, 0x5b52, 0x5b4f, 0x5b57, + 0x5b4d, 0x5b4b, 0x5b53, 0x5b49, 0x436c, 0x4c78, 0x3c46, 0x3a74, + 0x3a3a, 0x4b6f, 0x3341, 0x444e, 0x464a, 0x3149, 0x4072, 0x4034, + 0x372a, 0x5b59, 0x393b, 0x337c, 0x5b5b, 0x3374, 0x5b61, 0x5b5e, + 0x4073, 0x334b, 0x3a2c, 0x334a, 0x3a4f, 0x5b5c, 0x3765, 0x374b, + 0x456d, 0x5b5a, 0x3046, 0x5b5d, 0x5b5f, 0x364d, 0x372c, 0x343c, + 0x354b, 0x5b62, 0x3a79, 0x4b71, 0x3b37, 0x5b63, 0x4930, 0x5b6f, + 0x3233, 0x5b64, 0x5b75, 0x5b65, 0x4e42, 0x5b6c, 0x475f, 0x5b74, + 0x5b67, 0x3034, 0x5b69, 0x393c, 0x5b6b, 0x5b6a, 0x5b66, 0x5b71, + 0x3e3f, 0x546d, 0x3868, 0x4d7c, 0x5b68, 0x4474, 0x3323, 0x3a2d, + 0x5b60, 0x5b70, 0x3361, 0x5b6e, 0x5b72, 0x456e, 0x347e, 0x5c32, + 0x4c49, 0x5b77, 0x347d, 0x5b7e, 0x4b40, 0x5c21, 0x5c23, 0x5c27, + 0x5b79, 0x432a, 0x456f, 0x5c2b, 0x5b7c, 0x5c28, 0x5c22, 0x3f39, + 0x5c2c, 0x4033, 0x5c2a, 0x343d, 0x4f50, 0x5b76, 0x5c26, 0x3058, + 0x5b78, 0x4c3a, 0x5b7d, 0x3f22, 0x4447, 0x5b73, 0x5c25, 0x3f7a, + 0x5c2f, 0x3371, 0x3821, 0x5c31, 0x5b7a, 0x5c30, 0x5c29, 0x5b7b, + 0x5c2d, 0x5c2e, 0x5c3f, 0x464e, 0x5c24, 0x5c3b, 0x5c3d, 0x4458, + 0x4d4c, 0x4976, 0x5c38, 0x424a, 0x5c3e, 0x413f, 0x5c35, 0x5c42, + 0x5c41, 0x466f, 0x5c40, 0x466a, 0x5c44, 0x5c37, 0x3648, 0x5c3a, + 0x3d5d, 0x4760, 0x5c3c, 0x364b, 0x5c34, 0x5c36, 0x5c33, 0x4f30, + 0x335a, 0x5c39, 0x5c43, 0x3335, 0x3a67, 0x315d, 0x5c54, 0x4f31, + 0x5c57, 0x3f3a, 0x5c56, 0x5c55, 0x5c52, 0x5c46, 0x5c63, 0x5c45, + 0x5c58, 0x5c50, 0x5c4b, 0x5c48, 0x5c49, 0x5c51, 0x7422, 0x5c4e, + 0x393d, 0x4448, 0x4164, 0x5c4c, 0x5c47, 0x5c4a, 0x4d4d, 0x4b6a, + 0x5c4f, 0x5c59, 0x5c61, 0x5c5a, 0x5c67, 0x5c65, 0x5c60, 0x5c5f, + 0x4450, 0x4165, 0x5c5d, 0x5c5b, 0x5c62, 0x5c68, 0x4875, 0x5c6e, + 0x5c69, 0x5c6c, 0x5c66, 0x4374, 0x4938, 0x5c5c, 0x5c64, 0x3e40, + 0x4c4f, 0x5c78, 0x5c6b, 0x3822, 0x3223, 0x335f, 0x5c53, 0x3e41, + 0x5c70, 0x5c77, 0x3c79, 0x3372, 0x432e, 0x5c6d, 0x5c72, 0x5c76, + 0x3636, 0x354c, 0x5c74, 0x3521, 0x464b, 0x5c73, 0x5c75, 0x5c6f, + 0x5c71, 0x3360, 0x4349, 0x5c7c, 0x5c7a, 0x3869, 0x5c79, 0x5d21, + 0x5b58, 0x5c7b, 0x5c7d, 0x5c7e, 0x5d2c, 0x5d28, 0x5b6d, 0x5d27, + 0x5d26, 0x5d23, 0x5c6a, 0x5d25, 0x5d24, 0x5d2a, 0x4f26, 0x5d2d, + 0x367b, 0x5d29, 0x5d2b, 0x4827, 0x5d2e, 0x5d32, 0x5d2f, 0x4d73, + 0x5d30, 0x5c5e, 0x5d33, 0x5d34, 0x3135, 0x5d36, 0x3767, 0x3c21, + 0x3655, 0x3224, 0x4d5f, 0x5d38, 0x5d37, 0x5d3a, 0x353d, 0x3656, + 0x343e, 0x5d3d, 0x5d3c, 0x5d3e, 0x324e, 0x4337, 0x5d3f, 0x343f, + 0x5d41, 0x5d40, 0x5d42, 0x5d43, 0x5d44, 0x3b5f, 0x4035, 0x3a21, + 0x4970, 0x4a62, 0x4f44, 0x3b75, 0x3a50, 0x4e72, 0x5d45, 0x5d46, + 0x3b60, 0x5d47, 0x5d48, 0x5d4a, 0x5d49, 0x4b58, 0x3d5e, 0x3c6c, + 0x3b44, 0x5d4b, 0x5d4d, 0x3f23, 0x5d4c, 0x5d4e, 0x5d4f, 0x5d50, + 0x5d51, 0x5d52, 0x5d54, 0x5d53, 0x5d55, 0x3225, 0x434a, 0x5d56, + 0x3b26, 0x334c, 0x5d57, 0x4542, 0x544c, 0x3523, 0x5d58, 0x5d59, + 0x4a6c, 0x4b68, 0x4647, 0x5d5a, 0x4866, 0x487b, 0x4c53, 0x5d5b, + 0x5d5d, 0x5d5c, 0x5d5f, 0x5d5e, 0x5d61, 0x3b61, 0x4c31, 0x5d62, + 0x5d63, 0x3524, 0x5d64, 0x5d66, 0x5d65, 0x3f65, 0x4939, 0x314a, + 0x4845, 0x4475, 0x3d41, 0x3561, 0x4846, 0x3c2e, 0x5d68, 0x3440, + 0x3178, 0x4672, 0x5d67, 0x393e, 0x4353, 0x5d69, 0x5d71, 0x5d6a, + 0x4241, 0x3562, 0x5d72, 0x3768, 0x3525, 0x5d70, 0x5d6e, 0x5d6b, + 0x4d60, 0x4440, 0x4659, 0x5d6c, 0x5d74, 0x5d73, 0x3723, 0x322d, + 0x3a3b, 0x5d6d, 0x5d6f, 0x4b57, 0x4274, 0x4b77, 0x5d7c, 0x5d7d, + 0x324f, 0x4a28, 0x4c7d, 0x5e21, 0x3c23, 0x3e42, 0x5d78, 0x5d7e, + 0x3168, 0x3637, 0x5d75, 0x5d7a, 0x4074, 0x4771, 0x4867, 0x5d77, + 0x4b21, 0x5d79, 0x5e24, 0x5e22, 0x5d7b, 0x4b22, 0x4748, 0x3563, + 0x4525, 0x436d, 0x5e25, 0x5e23, 0x4259, 0x5d76, 0x314b, 0x4d4e, + 0x5e30, 0x5e2f, 0x4076, 0x5e2c, 0x4d6c, 0x4636, 0x5e26, 0x4445, + 0x314c, 0x393f, 0x5e29, 0x3d27, 0x5e2e, 0x5e2d, 0x5e28, 0x5e2b, + 0x3368, 0x5e2a, 0x4749, 0x4e2e, 0x3e74, 0x4075, 0x5e36, 0x5e34, + 0x494d, 0x5e31, 0x5e33, 0x313a, 0x3940, 0x4f32, 0x333d, 0x4962, + 0x4d61, 0x3324, 0x3f3b, 0x5e35, 0x5e3a, 0x3e43, 0x4d30, 0x5e37, + 0x5e32, 0x5e38, 0x4e5e, 0x4573, 0x4642, 0x3336, 0x3155, 0x5e3e, + 0x5e41, 0x4e43, 0x4d64, 0x5e48, 0x5e42, 0x5e3f, 0x4e54, 0x5e45, + 0x3d4a, 0x5e47, 0x5e4c, 0x4571, 0x5e4a, 0x5e44, 0x4338, 0x5e4b, + 0x5e40, 0x5e46, 0x5e4d, 0x307c, 0x5e43, 0x5e4e, 0x3f3c, 0x3d5f, + 0x4a25, 0x3a2e, 0x5e3b, 0x5e49, 0x453a, 0x4036, 0x3369, 0x3a51, + 0x3e44, 0x5e3d, 0x3d42, 0x374c, 0x5e3c, 0x5e52, 0x3d6d, 0x383a, + 0x5e61, 0x5e5b, 0x3574, 0x454f, 0x5e56, 0x5e5f, 0x302f, 0x3132, + 0x3239, 0x5e58, 0x422c, 0x5e4f, 0x5e51, 0x3941, 0x5e62, 0x5e5d, + 0x5e55, 0x5e5c, 0x4c2b, 0x5e5a, 0x5e5e, 0x3850, 0x3e45, 0x4339, + 0x5e54, 0x4d2f, 0x5e57, 0x5e50, 0x4572, 0x5e53, 0x5e59, 0x4f51, + 0x3c3e, 0x4b7e, 0x5e63, 0x482e, 0x5e6f, 0x383b, 0x3d60, 0x5e65, + 0x4e2f, 0x3942, 0x5e72, 0x306e, 0x5e70, 0x5e64, 0x5e6a, 0x5e6c, + 0x4d4f, 0x5e67, 0x452e, 0x5e69, 0x5e71, 0x5e6b, 0x4c47, 0x5e66, + 0x3c22, 0x5e7e, 0x336a, 0x5e68, 0x5e6d, 0x5e6e, 0x426c, 0x425a, + 0x5e76, 0x5e7c, 0x5e7a, 0x4529, 0x5f23, 0x5e77, 0x5e78, 0x5e60, + 0x3579, 0x493a, 0x3c3f, 0x3977, 0x4f33, 0x5e74, 0x5f22, 0x3169, + 0x4166, 0x4779, 0x3441, 0x4e7a, 0x4c21, 0x4452, 0x5e7b, 0x5e7d, + 0x4132, 0x5f21, 0x5e79, 0x5e73, 0x3443, 0x3769, 0x5f2f, 0x5f2a, + 0x4078, 0x3363, 0x3d61, 0x5f33, 0x5f2c, 0x442c, 0x5f29, 0x4459, + 0x5f4c, 0x5f26, 0x5f25, 0x5f2e, 0x5f28, 0x5f27, 0x5f2d, 0x4021, + 0x5f24, 0x5f30, 0x5f31, 0x3442, 0x5f36, 0x5f35, 0x5f37, 0x5f3a, + 0x4543, 0x5f34, 0x5f38, 0x3763, 0x4279, 0x5f32, 0x473b, 0x5f39, + 0x5f3e, 0x5f3c, 0x5f3f, 0x5f42, 0x5f3b, 0x396a, 0x4728, 0x5e39, + 0x4d74, 0x5f3d, 0x5f41, 0x4275, 0x5f40, 0x5f2b, 0x6f69, 0x5f45, + 0x5f49, 0x5f47, 0x5f43, 0x5f44, 0x5f48, 0x5f46, 0x494e, 0x5f4e, + 0x5f4b, 0x5f4a, 0x5f4d, 0x4654, 0x5f4f, 0x4375, 0x426d, 0x4025, + 0x5f50, 0x5f52, 0x5f51, 0x5e75, 0x5f53, 0x4667, 0x5f54, 0x3250, + 0x4574, 0x3325, 0x3564, 0x3c5e, 0x3a52, 0x4f27, 0x3f66, 0x316a, + 0x5f56, 0x5f55, 0x5f59, 0x433a, 0x5f5c, 0x5f57, 0x5f5b, 0x5f5a, + 0x4540, 0x3059, 0x4e75, 0x5f5e, 0x3128, 0x5f60, 0x5f5f, 0x5f5d, + 0x5f58, 0x4b23, 0x5f62, 0x5f61, 0x316b, 0x5f64, 0x4a32, 0x5f63, + 0x4c35, 0x3e47, 0x4133, 0x3e46, 0x4e7b, 0x5f6a, 0x4079, 0x5f66, + 0x5f6b, 0x316c, 0x5f69, 0x4761, 0x5f65, 0x5f68, 0x3e48, 0x4851, + 0x5f6c, 0x3c51, 0x407a, 0x5f6f, 0x5f67, 0x3727, 0x5f6d, 0x4d50, + 0x5f70, 0x7426, 0x3d4f, 0x5f71, 0x5f72, 0x472e, 0x5f74, 0x5f75, + 0x4733, 0x4575, 0x5f77, 0x5f79, 0x4e55, 0x5f76, 0x5f78, 0x316d, + 0x5f73, 0x535b, 0x5f7a, 0x4167, 0x3b38, 0x5f7c, 0x5f7b, 0x3f24, + 0x5259, 0x5f7d, 0x6021, 0x5f6e, 0x5f7e, 0x6022, 0x477a, 0x6023, + 0x6024, 0x6025, 0x6026, 0x445e, 0x6028, 0x6027, 0x6029, 0x602a, + 0x3c5f, 0x4963, 0x4c6c, 0x602b, 0x602c, 0x4156, 0x3c24, 0x602d, + 0x602e, 0x602f, 0x4a52, 0x4847, 0x6030, 0x4757, 0x442d, 0x6031, + 0x3267, 0x356d, 0x4c46, 0x4c36, 0x3234, 0x4f34, 0x4b52, 0x4a2a, + 0x4037, 0x6032, 0x4643, 0x3823, 0x6033, 0x3a54, 0x6035, 0x6034, + 0x6036, 0x6037, 0x6038, 0x353e, 0x6039, 0x603a, 0x3824, 0x4848, + 0x603c, 0x3e75, 0x603b, 0x3638, 0x603d, 0x603f, 0x603e, 0x6040, + 0x3851, 0x6041, 0x3669, 0x4140, 0x397d, 0x6043, 0x6044, 0x6042, + 0x3c6d, 0x4648, 0x3639, 0x6046, 0x432c, 0x6045, 0x4f35, 0x4762, + 0x6049, 0x604b, 0x6048, 0x4c54, 0x604a, 0x604c, 0x4e44, 0x6050, + 0x604f, 0x4376, 0x472d, 0x3825, 0x604e, 0x604d, 0x4d31, 0x4d32, + 0x6051, 0x316e, 0x3976, 0x3b62, 0x6052, 0x6053, 0x6055, 0x3d43, + 0x6057, 0x6056, 0x6058, 0x334d, 0x605a, 0x6059, 0x605c, 0x605b, + 0x383c, 0x4e28, 0x364c, 0x3226, 0x366a, 0x3461, 0x4e68, 0x605e, + 0x6060, 0x6061, 0x3251, 0x605d, 0x3b39, 0x4441, 0x605f, 0x6064, + 0x3c6e, 0x6062, 0x373e, 0x4849, 0x6063, 0x607e, 0x6069, 0x383d, + 0x3565, 0x6066, 0x4d7d, 0x4e30, 0x4276, 0x6068, 0x606a, 0x4e56, + 0x3657, 0x487c, 0x474a, 0x606b, 0x606d, 0x6070, 0x606c, 0x606f, + 0x386a, 0x314d, 0x6071, 0x3f70, 0x606e, 0x4e5c, 0x6074, 0x7424, + 0x6072, 0x6075, 0x6067, 0x6073, 0x3a3c, 0x6076, 0x6077, 0x4d7e, + 0x6078, 0x6079, 0x6065, 0x607a, 0x3444, 0x3c25, 0x607b, 0x607c, + 0x607d, 0x313b, 0x6121, 0x493b, 0x6122, 0x3424, 0x6123, 0x6124, + 0x6125, 0x6127, 0x6128, 0x6126, 0x4953, 0x612a, 0x6129, 0x612c, + 0x612b, 0x612d, 0x612e, 0x6130, 0x612f, 0x3979, 0x6132, 0x6131, + 0x3445, 0x3f53, 0x453c, 0x6133, 0x4038, 0x3b3a, 0x3179, 0x6134, + 0x4d51, 0x4a63, 0x6135, 0x4544, 0x4d33, 0x3943, 0x3f3d, 0x434b, + 0x5234, 0x442e, 0x3268, 0x6136, 0x6137, 0x613c, 0x613a, 0x6139, + 0x5a42, 0x3326, 0x6138, 0x305a, 0x482a, 0x484a, 0x4e31, 0x613d, + 0x613b, 0x435c, 0x4026, 0x482b, 0x492d, 0x613f, 0x4e2c, 0x374d, + 0x6140, 0x613e, 0x4856, 0x6141, 0x6142, 0x305b, 0x3e76, 0x6147, + 0x6144, 0x466d, 0x6143, 0x3526, 0x614a, 0x6145, 0x6146, 0x6149, + 0x6148, 0x4925, 0x4142, 0x4141, 0x353f, 0x614b, 0x614c, 0x614d, + 0x614f, 0x614e, 0x3156, 0x6157, 0x4868, 0x6151, 0x6153, 0x6155, + 0x3f3e, 0x6156, 0x6154, 0x3c40, 0x6150, 0x6152, 0x4942, 0x3e49, + 0x6159, 0x6158, 0x615a, 0x3c26, 0x3a2f, 0x4577, 0x615b, 0x444b, + 0x615d, 0x4e21, 0x615c, 0x4169, 0x6162, 0x6164, 0x6165, 0x4354, + 0x6163, 0x6160, 0x615e, 0x615f, 0x6161, 0x6168, 0x6166, 0x6167, + 0x6169, 0x616b, 0x616c, 0x616d, 0x616e, 0x616a, 0x6170, 0x616f, + 0x6171, 0x4e45, 0x6174, 0x6172, 0x6173, 0x3462, 0x4c7e, 0x4a4a, + 0x6176, 0x6175, 0x6177, 0x6178, 0x617c, 0x6179, 0x617a, 0x617b, + 0x617d, 0x617e, 0x6221, 0x6222, 0x6223, 0x482f, 0x4550, 0x6224, + 0x4772, 0x4934, 0x6225, 0x6226, 0x452a, 0x3327, 0x3944, 0x6227, + 0x6228, 0x6229, 0x3b29, 0x622b, 0x622a, 0x622c, 0x622d, 0x4869, + 0x622e, 0x622f, 0x7369, 0x6230, 0x6231, 0x6232, 0x3b2e, 0x6233, + 0x4756, 0x4b5f, 0x314e, 0x3157, 0x6234, 0x6236, 0x6235, 0x4570, + 0x4039, 0x5d39, 0x6237, 0x4c41, 0x6238, 0x3446, 0x4857, 0x6239, + 0x623a, 0x623b, 0x4c5c, 0x4c55, 0x443e, 0x416a, 0x623d, 0x3d62, + 0x3e4a, 0x6240, 0x623f, 0x623e, 0x487d, 0x3447, 0x3829, 0x6246, + 0x6243, 0x3f3f, 0x4c32, 0x6242, 0x6244, 0x6245, 0x6241, 0x6247, + 0x6248, 0x442f, 0x3463, 0x4365, 0x6249, 0x624a, 0x624d, 0x3f67, + 0x4644, 0x624e, 0x4b53, 0x624b, 0x624c, 0x6251, 0x6250, 0x624f, + 0x6253, 0x6252, 0x6254, 0x6256, 0x6255, 0x4a4d, 0x3d56, 0x4e46, + 0x6257, 0x4637, 0x6258, 0x6259, 0x625d, 0x625b, 0x625c, 0x625a, + 0x625e, 0x625f, 0x6260, 0x6261, 0x4c37, 0x6262, 0x4c70, 0x6263, + 0x434e, 0x476a, 0x366b, 0x433b, 0x6264, 0x363a, 0x4050, 0x6265, + 0x3a3d, 0x6266, 0x6267, 0x3826, 0x3a55, 0x6269, 0x4556, 0x3a56, + 0x354e, 0x4b24, 0x474b, 0x4557, 0x395c, 0x626b, 0x3e4b, 0x4e32, + 0x3945, 0x3827, 0x4823, 0x626d, 0x626f, 0x386b, 0x626e, 0x4476, + 0x6271, 0x3337, 0x626c, 0x486a, 0x3130, 0x3a6c, 0x4f52, 0x6270, + 0x6272, 0x4a4b, 0x4059, 0x6274, 0x6275, 0x6273, 0x334e, 0x627b, + 0x627a, 0x3c27, 0x627c, 0x6277, 0x627d, 0x6278, 0x4858, 0x6276, + 0x6279, 0x6322, 0x6321, 0x4b61, 0x627e, 0x306b, 0x6324, 0x6323, + 0x3e4c, 0x6325, 0x4143, 0x6327, 0x6326, 0x6328, 0x6268, 0x626a, + 0x632a, 0x6329, 0x3c28, 0x4e69, 0x3c52, 0x632b, 0x3737, 0x3540, + 0x3527, 0x3b63, 0x4d34, 0x6331, 0x6330, 0x4144, 0x632d, 0x632f, + 0x3d4b, 0x3f40, 0x632e, 0x632c, 0x472a, 0x3e4d, 0x493c, 0x3a57, + 0x4578, 0x6332, 0x6333, 0x6349, 0x3658, 0x4f3d, 0x4135, 0x6334, + 0x3252, 0x4477, 0x4a21, 0x6335, 0x357a, 0x6336, 0x6338, 0x6339, + 0x4729, 0x633a, 0x633b, 0x633c, 0x3659, 0x3253, 0x4645, 0x3d28, + 0x3b64, 0x633d, 0x3d29, 0x324a, 0x4943, 0x633e, 0x486b, 0x4145, + 0x6341, 0x6342, 0x4769, 0x3f41, 0x633f, 0x4361, 0x6340, 0x3e4e, + 0x305c, 0x3529, 0x6343, 0x4478, 0x6344, 0x4047, 0x4c2d, 0x4923, + 0x6345, 0x6346, 0x4355, 0x4e47, 0x6348, 0x6347, 0x3c6f, 0x634a, + 0x3070, 0x634d, 0x634b, 0x3254, 0x374e, 0x634c, 0x3946, 0x3972, + 0x4a66, 0x634e, 0x4b54, 0x6350, 0x4051, 0x314f, 0x323a, 0x302c, + 0x634f, 0x6351, 0x6352, 0x3e77, 0x6353, 0x334f, 0x6355, 0x376a, + 0x3566, 0x6356, 0x3675, 0x6357, 0x407c, 0x464d, 0x4060, 0x3a75, + 0x6358, 0x4362, 0x416b, 0x635a, 0x635c, 0x6359, 0x635b, 0x3722, + 0x635d, 0x3726, 0x3567, 0x4d52, 0x635f, 0x6360, 0x312e, 0x6363, + 0x3376, 0x6362, 0x6361, 0x6365, 0x635e, 0x6366, 0x4e29, 0x6367, + 0x6368, 0x5474, 0x636a, 0x6369, 0x636b, 0x636c, 0x4e35, 0x636d, + 0x706f, 0x3e4f, 0x636e, 0x636f, 0x3d57, 0x4638, 0x6370, 0x4328, + 0x6371, 0x433c, 0x6372, 0x3625, 0x513f, 0x435d, 0x3c33, 0x3448, + 0x6373, 0x6422, 0x6376, 0x3568, 0x6375, 0x6424, 0x6374, 0x3e50, + 0x6378, 0x6379, 0x452b, 0x637a, 0x335e, 0x3f5a, 0x4964, 0x637c, + 0x4268, 0x6377, 0x637b, 0x637d, 0x3a7b, 0x6426, 0x492e, 0x4826, + 0x4579, 0x365a, 0x6425, 0x6423, 0x4835, 0x637e, 0x435e, 0x457b, + 0x457a, 0x3a76, 0x6438, 0x6428, 0x642a, 0x642d, 0x642e, 0x642b, + 0x642c, 0x6429, 0x6427, 0x6421, 0x4a4f, 0x3255, 0x6435, 0x6432, + 0x6437, 0x6436, 0x4773, 0x4c27, 0x3b3b, 0x6430, 0x6439, 0x6434, + 0x6433, 0x642f, 0x6431, 0x3449, 0x433d, 0x407d, 0x4822, 0x643e, + 0x4824, 0x4061, 0x643b, 0x484f, 0x643f, 0x4a53, 0x435b, 0x643a, + 0x643c, 0x643d, 0x6440, 0x3c44, 0x4646, 0x6445, 0x6444, 0x6441, + 0x4f36, 0x644a, 0x644e, 0x644b, 0x6447, 0x6448, 0x644d, 0x6442, + 0x5255, 0x6449, 0x6443, 0x644c, 0x6452, 0x344a, 0x644f, 0x6450, + 0x6451, 0x6454, 0x6453, 0x4876, 0x6455, 0x4e7c, 0x4a6d, 0x645a, + 0x6457, 0x6456, 0x4052, 0x6459, 0x645b, 0x6458, 0x645f, 0x645c, + 0x645d, 0x6446, 0x645e, 0x6460, 0x6461, 0x4a46, 0x6462, 0x4c62, + 0x364e, 0x3729, 0x6463, 0x4a34, 0x3f68, 0x4c30, 0x6464, 0x4e33, + 0x4774, 0x4146, 0x4734, 0x3d4d, 0x3040, 0x6469, 0x6467, 0x6465, + 0x3421, 0x3e51, 0x646a, 0x6468, 0x6466, 0x646e, 0x646d, 0x646c, + 0x646b, 0x646f, 0x6470, 0x403a, 0x6471, 0x6473, 0x6472, 0x3852, + 0x4138, 0x6475, 0x457c, 0x6474, 0x6476, 0x4a35, 0x416c, 0x3947, + 0x6477, 0x4e48, 0x6479, 0x647a, 0x647b, 0x647c, 0x3b65, 0x647d, + 0x374f, 0x356a, 0x352a, 0x6521, 0x4c73, 0x3948, 0x647e, 0x6524, + 0x4c66, 0x473c, 0x4933, 0x3d63, 0x6523, 0x3c53, 0x3949, 0x3b66, + 0x3569, 0x4a36, 0x6522, 0x4147, 0x4b42, 0x3a77, 0x3b67, 0x445d, + 0x6527, 0x4e5f, 0x3a59, 0x6528, 0x3f42, 0x652a, 0x3e52, 0x3a30, + 0x6529, 0x3d2a, 0x383e, 0x4148, 0x6525, 0x652b, 0x6526, 0x3750, + 0x652e, 0x6532, 0x376b, 0x652d, 0x6536, 0x394a, 0x4d6d, 0x303c, + 0x6533, 0x356b, 0x6530, 0x6531, 0x457d, 0x652f, 0x652c, 0x3328, + 0x4064, 0x3828, 0x6538, 0x6535, 0x6537, 0x6534, 0x3751, 0x4233, + 0x6539, 0x416e, 0x6546, 0x6542, 0x653c, 0x6540, 0x3c7a, 0x305d, + 0x653b, 0x6543, 0x6547, 0x394b, 0x4c56, 0x4456, 0x653d, 0x6545, + 0x653a, 0x433e, 0x653f, 0x303d, 0x4c4a, 0x653e, 0x365b, 0x486c, + 0x416d, 0x4e50, 0x3d6f, 0x656e, 0x6548, 0x407e, 0x6544, 0x6549, + 0x654b, 0x4479, 0x654e, 0x654a, 0x4a54, 0x344b, 0x4c4b, 0x305e, + 0x654d, 0x4e7d, 0x654c, 0x316f, 0x466c, 0x654f, 0x6556, 0x6550, + 0x6557, 0x6553, 0x477b, 0x3c4a, 0x6555, 0x6552, 0x6558, 0x6551, + 0x3d44, 0x4b25, 0x3d4c, 0x6554, 0x6560, 0x655c, 0x655f, 0x655d, + 0x6561, 0x655b, 0x6541, 0x4053, 0x484b, 0x655e, 0x6559, 0x4121, + 0x3752, 0x3d2b, 0x3f25, 0x4136, 0x6564, 0x6566, 0x6567, 0x6563, + 0x6565, 0x655a, 0x6562, 0x656a, 0x6569, 0x4b7a, 0x372b, 0x6568, + 0x656c, 0x656b, 0x656f, 0x6571, 0x3b3c, 0x656d, 0x6572, 0x6573, + 0x6574, 0x657a, 0x453b, 0x6576, 0x6575, 0x6577, 0x6578, 0x6579, + 0x657b, 0x657c, 0x344c, 0x657d, 0x657e, 0x6621, 0x6622, 0x6623, + 0x6624, 0x6625, 0x6626, 0x6628, 0x6627, 0x6629, 0x662a, 0x662b, + 0x662e, 0x662c, 0x662d, 0x3a61, 0x3753, 0x4356, 0x4833, 0x3d70, + 0x474d, 0x486d, 0x662f, 0x586d, 0x6630, 0x6632, 0x4d65, 0x6631, + 0x6634, 0x6633, 0x4d53, 0x6635, 0x487e, 0x6636, 0x6639, 0x6638, + 0x6637, 0x663a, 0x3732, 0x4122, 0x3541, 0x663e, 0x663b, 0x663c, + 0x663f, 0x6640, 0x663d, 0x3129, 0x3227, 0x6642, 0x6643, 0x6644, + 0x4d62, 0x3d2c, 0x6646, 0x6645, 0x3f69, 0x6647, 0x6648, 0x6649, + 0x3465, 0x344d, 0x664a, 0x664b, 0x4b5d, 0x4d63, 0x4d54, 0x4f37, + 0x394d, 0x664e, 0x3c54, 0x664d, 0x664f, 0x3c29, 0x4251, 0x6650, + 0x394c, 0x4c57, 0x6651, 0x6652, 0x6653, 0x6654, 0x6655, 0x3c2a, + 0x4c6d, 0x6657, 0x433f, 0x6656, 0x6659, 0x6658, 0x665a, 0x403b, + 0x665b, 0x665c, 0x4a39, 0x665d, 0x416f, 0x665e, 0x665f, 0x4e7e, + 0x6662, 0x6661, 0x6660, 0x4430, 0x6663, 0x3f26, 0x6664, 0x6665, + 0x4f38, 0x6666, 0x6667, 0x6669, 0x6668, 0x4825, 0x4679, 0x4f3e, + 0x4829, 0x666b, 0x3e53, 0x492a, 0x666c, 0x666a, 0x344e, 0x3854, + 0x3b68, 0x486e, 0x382a, 0x4b43, 0x666f, 0x666d, 0x394e, 0x394f, + 0x3069, 0x3a68, 0x4759, 0x305f, 0x6674, 0x4340, 0x4758, 0x425b, + 0x6676, 0x6672, 0x6675, 0x6670, 0x6673, 0x4b26, 0x3855, 0x307d, + 0x6671, 0x6678, 0x6679, 0x4639, 0x363b, 0x6726, 0x473d, 0x3b69, + 0x363c, 0x4048, 0x4f46, 0x4c2e, 0x6677, 0x4054, 0x3553, 0x667a, + 0x667c, 0x667b, 0x667d, 0x4326, 0x473e, 0x4431, 0x6723, 0x6722, + 0x667e, 0x3f55, 0x4965, 0x6725, 0x6724, 0x3950, 0x4f53, 0x6735, + 0x6729, 0x672a, 0x3c70, 0x6728, 0x3978, 0x6727, 0x672b, 0x4432, + 0x4a22, 0x4123, 0x425c, 0x672f, 0x6730, 0x672c, 0x672d, 0x672e, + 0x3951, 0x6736, 0x6732, 0x4966, 0x4b6c, 0x4928, 0x6731, 0x6734, + 0x6733, 0x4b44, 0x6737, 0x6738, 0x4137, 0x6739, 0x673b, 0x673f, + 0x673c, 0x673a, 0x473f, 0x673d, 0x673e, 0x3232, 0x6745, 0x6740, + 0x6741, 0x6742, 0x4221, 0x6744, 0x6743, 0x6746, 0x6747, 0x6748, + 0x3f43, 0x3269, 0x6749, 0x4e57, 0x3c2b, 0x3d2d, 0x3b6a, 0x4357, + 0x674a, 0x674b, 0x3131, 0x674c, 0x674d, 0x674e, 0x674f, 0x6750, + 0x363d, 0x5a2a, 0x6751, 0x4065, 0x6752, 0x3c4b, 0x6753, 0x5030, + 0x6754, 0x4a5e, 0x345c, 0x4124, 0x3d58, 0x4971, 0x3d2e, 0x6755, + 0x3952, 0x6756, 0x484c, 0x6764, 0x6758, 0x4249, 0x4775, 0x383f, + 0x6757, 0x4125, 0x6759, 0x447a, 0x675b, 0x675a, 0x675d, 0x675c, + 0x675e, 0x6760, 0x675f, 0x344f, 0x6761, 0x6762, 0x6763, 0x3a31, + 0x4e49, 0x6765, 0x3f27, 0x3170, 0x6766, 0x6767, 0x6768, 0x3072, + 0x6769, 0x676a, 0x4967, 0x3c47, 0x676c, 0x3329, 0x3032, 0x676b, + 0x676e, 0x474e, 0x3f44, 0x3256, 0x4b27, 0x375d, 0x365c, 0x676d, + 0x326a, 0x3423, 0x3171, 0x6772, 0x4e6a, 0x425d, 0x4944, 0x677e, + 0x3257, 0x677c, 0x677a, 0x6771, 0x676f, 0x6770, 0x3c63, 0x366c, + 0x4377, 0x4651, 0x3151, 0x6774, 0x6773, 0x6779, 0x6775, 0x6778, + 0x4c50, 0x6777, 0x3258, 0x337d, 0x677b, 0x677d, 0x3754, 0x6823, + 0x682c, 0x682d, 0x302b, 0x6834, 0x3071, 0x682b, 0x682a, 0x6825, + 0x6824, 0x6822, 0x6821, 0x4363, 0x427b, 0x6827, 0x6826, 0x6829, + 0x4170, 0x3755, 0x3141, 0x6828, 0x3953, 0x4171, 0x683a, 0x683b, + 0x3259, 0x322e, 0x6838, 0x682e, 0x6836, 0x683d, 0x6837, 0x6835, + 0x6776, 0x6833, 0x682f, 0x3450, 0x6831, 0x683c, 0x6832, 0x683e, + 0x6830, 0x477c, 0x4d69, 0x6839, 0x684f, 0x6847, 0x3f7b, 0x3546, + 0x365d, 0x6842, 0x325b, 0x3e54, 0x6845, 0x3a5a, 0x4551, 0x684a, + 0x4a6e, 0x6841, 0x325a, 0x3856, 0x4929, 0x684b, 0x683f, 0x6848, + 0x6852, 0x6843, 0x6844, 0x463a, 0x6849, 0x6846, 0x4b28, 0x684c, + 0x3060, 0x6840, 0x684e, 0x684d, 0x476b, 0x6854, 0x685f, 0x337e, + 0x6862, 0x6850, 0x6855, 0x4d6e, 0x685e, 0x4d55, 0x4e2a, 0x4378, + 0x336b, 0x4972, 0x6864, 0x4621, 0x3031, 0x685d, 0x6859, 0x4172, + 0x6853, 0x685b, 0x6860, 0x472c, 0x302a, 0x6858, 0x6861, 0x4978, + 0x685c, 0x6857, 0x3e55, 0x3d2f, 0x3c2c, 0x4c58, 0x4947, 0x6867, + 0x6870, 0x685a, 0x3377, 0x3e78, 0x6865, 0x686a, 0x4173, 0x6866, + 0x686d, 0x435f, 0x686e, 0x4d56, 0x6863, 0x3338, 0x6869, 0x686c, + 0x4c2c, 0x686f, 0x6868, 0x686b, 0x4b29, 0x4f21, 0x6873, 0x687a, + 0x6872, 0x3c43, 0x6851, 0x4a4e, 0x4c22, 0x6879, 0x6878, 0x6874, + 0x6875, 0x3136, 0x6877, 0x6871, 0x4455, 0x6876, 0x307e, 0x4222, + 0x4a43, 0x687b, 0x6921, 0x4859, 0x687e, 0x3e56, 0x3c49, 0x6923, + 0x363e, 0x6924, 0x4979, 0x687d, 0x6856, 0x687c, 0x4f4f, 0x4622, + 0x4973, 0x692b, 0x6931, 0x6932, 0x6925, 0x4776, 0x692f, 0x6927, + 0x6929, 0x6933, 0x6928, 0x692c, 0x3172, 0x4665, 0x692d, 0x6930, + 0x6926, 0x4126, 0x692a, 0x3b27, 0x3f45, 0x3730, 0x4c74, 0x4c79, + 0x3d72, 0x6937, 0x6935, 0x4f4e, 0x6934, 0x4d75, 0x6936, 0x6938, + 0x6939, 0x693c, 0x693a, 0x4623, 0x693b, 0x484d, 0x692e, 0x3d73, + 0x693d, 0x6942, 0x4174, 0x6941, 0x6922, 0x6943, 0x4149, 0x693e, + 0x6940, 0x693f, 0x5d31, 0x5d22, 0x6945, 0x6944, 0x4d76, 0x623c, + 0x6946, 0x6947, 0x6948, 0x3857, 0x3554, 0x694a, 0x515d, 0x3575, + 0x4e3a, 0x3673, 0x694b, 0x694c, 0x436e, 0x694d, 0x467a, 0x303a, + 0x3263, 0x6952, 0x6953, 0x694e, 0x3b3d, 0x694f, 0x4742, 0x6950, + 0x6951, 0x695b, 0x6955, 0x6958, 0x6954, 0x6956, 0x6957, 0x3c58, + 0x6959, 0x4341, 0x3756, 0x3342, 0x695c, 0x333f, 0x6961, 0x695d, + 0x6960, 0x483a, 0x695e, 0x695f, 0x4948, 0x485a, 0x6962, 0x427d, + 0x696c, 0x6968, 0x326b, 0x6966, 0x4b2a, 0x6967, 0x6964, 0x6965, + 0x696a, 0x696d, 0x696b, 0x6969, 0x6963, 0x4358, 0x6974, 0x4c2a, + 0x6972, 0x6973, 0x696e, 0x6970, 0x6971, 0x696f, 0x4066, 0x4f39, + 0x6978, 0x6979, 0x6a21, 0x3f2a, 0x697b, 0x697e, 0x6976, 0x6975, + 0x6a22, 0x325c, 0x697c, 0x6a23, 0x697d, 0x697a, 0x4433, 0x6977, + 0x4768, 0x6a27, 0x4d3b, 0x6a26, 0x6a25, 0x6a2e, 0x6a28, 0x6a30, + 0x4d66, 0x6a33, 0x6a2a, 0x6a2b, 0x6a2f, 0x6a32, 0x6a31, 0x6a29, + 0x6a2c, 0x6a3d, 0x6a36, 0x6a34, 0x6a35, 0x6a3a, 0x6a3b, 0x332a, + 0x3542, 0x6a39, 0x6a24, 0x6a38, 0x6a3c, 0x6a37, 0x6a3e, 0x6a40, + 0x6a3f, 0x6a42, 0x6a41, 0x695a, 0x6a46, 0x6a43, 0x6a44, 0x6a45, + 0x6a47, 0x376c, 0x6a49, 0x6a48, 0x3d30, 0x3954, 0x5e27, 0x6a4a, + 0x3d51, 0x3339, 0x6a4b, 0x3152, 0x3e57, 0x6a4c, 0x3955, 0x6a4d, + 0x3061, 0x493d, 0x6a4e, 0x3f6a, 0x6a55, 0x6a52, 0x436f, 0x6a53, + 0x6a50, 0x365e, 0x6a4f, 0x6a56, 0x3736, 0x425e, 0x6a5c, 0x6a58, + 0x4235, 0x6a57, 0x6a5a, 0x6a51, 0x6a5b, 0x6a5d, 0x486f, 0x6a59, + 0x6a5e, 0x6a60, 0x3853, 0x6a54, 0x3041, 0x6a5f, 0x3a5b, 0x4e76, + 0x6a61, 0x6a62, 0x4175, 0x4e22, 0x6a63, 0x4d35, 0x6a64, 0x6a65, + 0x4a64, 0x6a66, 0x3a40, 0x4e23, 0x6a6b, 0x6a6c, 0x3e58, 0x6a6a, + 0x4d67, 0x6a67, 0x6a69, 0x403d, 0x3f7e, 0x6a68, 0x6a6d, 0x4a23, + 0x6a6f, 0x6a6e, 0x336c, 0x4b2b, 0x6a70, 0x6a7c, 0x6a72, 0x6a73, + 0x6a74, 0x6a75, 0x6a79, 0x6a7a, 0x6a78, 0x6a76, 0x6a71, 0x6a77, + 0x6a7b, 0x7037, 0x3228, 0x6a7e, 0x365f, 0x6a7d, 0x6b22, 0x6b21, + 0x6b24, 0x6b23, 0x6b25, 0x3d31, 0x6b26, 0x6b27, 0x6b28, 0x403e, + 0x4d57, 0x6b29, 0x4a24, 0x4746, 0x6b2a, 0x6b2b, 0x382b, 0x352c, + 0x6b2c, 0x3b6b, 0x4741, 0x6b2d, 0x3350, 0x6b2e, 0x6b30, 0x4d77, + 0x6b2f, 0x3f46, 0x6b31, 0x6b32, 0x6b33, 0x3451, 0x6b34, 0x6b35, + 0x6b36, 0x6b37, 0x3351, 0x6b38, 0x6b39, 0x6b3a, 0x3272, 0x3f28, + 0x6b3b, 0x6b3c, 0x6b3d, 0x3840, 0x447b, 0x6b3e, 0x3757, 0x3f56, + 0x6b41, 0x4624, 0x6b40, 0x3731, 0x6b3f, 0x4277, 0x352d, 0x6b42, + 0x6b43, 0x3e59, 0x376d, 0x6b44, 0x4b2c, 0x405f, 0x3576, 0x4c75, + 0x414a, 0x6b45, 0x3f47, 0x4370, 0x3e5a, 0x6b46, 0x6b49, 0x6b4a, + 0x3a3e, 0x4242, 0x6b48, 0x3e5b, 0x493e, 0x6b47, 0x3b6c, 0x3153, + 0x6b4e, 0x3758, 0x3b6e, 0x3b6d, 0x4f4d, 0x6b4d, 0x6b4c, 0x4127, + 0x354d, 0x4f43, 0x333a, 0x3e5c, 0x6b4b, 0x6b50, 0x6b51, 0x6b4f, + 0x3858, 0x4d40, 0x3b6f, 0x4727, 0x6b54, 0x4040, 0x4342, 0x4d36, + 0x6b57, 0x386c, 0x403f, 0x6b53, 0x6b58, 0x386d, 0x6b55, 0x6b56, + 0x6b52, 0x4062, 0x4649, 0x432f, 0x325d, 0x4870, 0x3543, 0x4434, + 0x6b5b, 0x6b59, 0x434c, 0x4041, 0x3452, 0x6b5a, 0x3f5b, 0x4e4a, + 0x4f40, 0x6b5c, 0x6b67, 0x4435, 0x6b66, 0x6b63, 0x6b6b, 0x6b64, + 0x6b60, 0x447c, 0x6b5f, 0x6b5d, 0x4d21, 0x3b70, 0x6b61, 0x6b5e, + 0x6b65, 0x3d74, 0x3841, 0x427a, 0x4b45, 0x315a, 0x3062, 0x4625, + 0x6b69, 0x6b68, 0x4666, 0x6b6d, 0x6b62, 0x6b6c, 0x6b6e, 0x382c, + 0x6b6a, 0x3956, 0x3c55, 0x6b6f, 0x4d58, 0x6b72, 0x6b75, 0x6b73, + 0x4935, 0x6b70, 0x3660, 0x6b74, 0x6b76, 0x6b7a, 0x6b77, 0x6b79, + 0x6b78, 0x6b7b, 0x3c31, 0x6b7d, 0x6b7c, 0x4968, 0x6c21, 0x3759, + 0x6b7e, 0x6c22, 0x6c23, 0x3544, 0x6641, 0x3e79, 0x6c24, 0x386e, + 0x6c25, 0x6c26, 0x3b3e, 0x5a4e, 0x6c27, 0x6c28, 0x3d32, 0x6c29, + 0x6c2a, 0x6c2b, 0x6c2c, 0x6c2d, 0x432b, 0x6c2e, 0x6c30, 0x6c2f, + 0x4626, 0x6c31, 0x4b2d, 0x6c32, 0x6c33, 0x6c34, 0x6c35, 0x465a, + 0x3e5d, 0x6c36, 0x396b, 0x502e, 0x6c37, 0x6c38, 0x493f, 0x6c39, + 0x6c41, 0x6c3a, 0x6c3c, 0x6c3b, 0x6c3d, 0x4b46, 0x6c3e, 0x6c3f, + 0x6c40, 0x6c42, 0x332d, 0x4467, 0x4969, 0x3a62, 0x3957, 0x494f, + 0x325f, 0x484e, 0x6c45, 0x3453, 0x4055, 0x6c44, 0x6c49, 0x4379, + 0x4c63, 0x6c47, 0x6c48, 0x352e, 0x6c4a, 0x4763, 0x425f, 0x4871, + 0x453d, 0x6c46, 0x4b47, 0x326c, 0x6c4c, 0x4f28, 0x4442, 0x4f45, + 0x3b71, 0x6c4b, 0x4231, 0x6c5c, 0x4128, 0x4678, 0x4950, 0x6c4f, + 0x3b3f, 0x3b72, 0x3e5e, 0x4765, 0x382d, 0x6c4e, 0x6c4d, 0x496a, + 0x3c41, 0x4552, 0x6c51, 0x6c52, 0x3958, 0x6c50, 0x6c53, 0x6c54, + 0x6c56, 0x4223, 0x6c55, 0x3466, 0x6c58, 0x6c57, 0x6c59, 0x6c5b, + 0x6c5d, 0x6c5e, 0x4056, 0x3c4f, 0x6c5f, 0x3352, 0x6c60, 0x4176, + 0x6c61, 0x6c62, 0x496b, 0x352f, 0x6c63, 0x4436, 0x315b, 0x6c64, + 0x3c71, 0x3f76, 0x422d, 0x6c67, 0x6c66, 0x6c65, 0x6c6d, 0x6c6b, + 0x6c68, 0x6c6a, 0x6c69, 0x6c6c, 0x3577, 0x6c70, 0x4057, 0x6c71, + 0x3859, 0x6c6e, 0x6c6f, 0x4f29, 0x4437, 0x4129, 0x6c72, 0x6c75, + 0x6c73, 0x6c74, 0x4d59, 0x4627, 0x6c78, 0x6c76, 0x6c77, 0x6c79, + 0x6d29, 0x6c7c, 0x6c7d, 0x6c7b, 0x6c7a, 0x447d, 0x6d21, 0x6d25, + 0x6d22, 0x6c7e, 0x6d23, 0x6d24, 0x6d2b, 0x6d26, 0x4058, 0x6d28, + 0x6d2a, 0x6d27, 0x6d2d, 0x3d33, 0x6d2c, 0x6d2e, 0x6d2f, 0x6d32, + 0x6d31, 0x6d30, 0x6d34, 0x6d33, 0x4c76, 0x6d36, 0x6d35, 0x6d37, + 0x6d38, 0x6d3a, 0x6d39, 0x3f48, 0x6d3b, 0x366d, 0x6d3c, 0x6d3e, + 0x6d3f, 0x6d40, 0x6d3d, 0x6d41, 0x3c56, 0x6d42, 0x3530, 0x3733, + 0x382e, 0x6d43, 0x4670, 0x453e, 0x6d44, 0x6d47, 0x3c34, 0x6d46, + 0x6d45, 0x375a, 0x6d48, 0x3353, 0x6d4a, 0x3a5c, 0x6d49, 0x6d52, + 0x6d4c, 0x6d4e, 0x4a65, 0x6d4b, 0x6d4d, 0x6d51, 0x6d4f, 0x3531, + 0x6d50, 0x6d53, 0x475a, 0x4e58, 0x3d34, 0x6d54, 0x4d22, 0x6d56, + 0x6d55, 0x6d59, 0x4d41, 0x6d58, 0x336d, 0x6d57, 0x6d5c, 0x6d5b, + 0x6d5a, 0x4532, 0x6d5d, 0x6d5e, 0x6d5f, 0x396c, 0x3725, 0x6d60, + 0x6d61, 0x6d62, 0x3f49, 0x6d63, 0x3c2d, 0x6d64, 0x6d65, 0x5221, + 0x517e, 0x6d66, 0x6570, 0x6d67, 0x4324, 0x3f2b, 0x4740, 0x6d68, + 0x4a55, 0x4454, 0x397e, 0x4329, 0x312a, 0x4b78, 0x3f57, 0x375e, + 0x3661, 0x4a56, 0x6d69, 0x6d6b, 0x6d6a, 0x3260, 0x4676, 0x6d6c, + 0x4777, 0x4533, 0x6d6d, 0x3d52, 0x6d6f, 0x4c42, 0x6d7e, 0x6d71, + 0x6d72, 0x4449, 0x4260, 0x4177, 0x4628, 0x6d70, 0x3555, 0x6d79, + 0x6d76, 0x6e25, 0x4629, 0x4360, 0x6d73, 0x447e, 0x4553, 0x6d74, + 0x6d78, 0x3f60, 0x4767, 0x444c, 0x4042, 0x6d77, 0x422e, 0x4224, + 0x6d75, 0x3029, 0x4f22, 0x6d7a, 0x4261, 0x3d35, 0x3f4a, 0x6d7c, + 0x6d7b, 0x306f, 0x6d7d, 0x492f, 0x6e27, 0x465b, 0x3f6b, 0x4359, + 0x3678, 0x6e26, 0x4d37, 0x313f, 0x4a57, 0x3261, 0x6e21, 0x6e22, + 0x6e23, 0x6e24, 0x463b, 0x4323, 0x3063, 0x6e28, 0x6e29, 0x7423, + 0x423d, 0x6e2a, 0x3173, 0x414c, 0x382f, 0x4d5a, 0x6e2b, 0x452c, + 0x4178, 0x3c57, 0x6e2c, 0x6e2f, 0x3d65, 0x6e2d, 0x412b, 0x412a, + 0x3064, 0x4e4b, 0x6e31, 0x4872, 0x6e33, 0x6e32, 0x6e30, 0x6364, + 0x3454, 0x6d6e, 0x6e35, 0x6e34, 0x6e36, 0x4d38, 0x4661, 0x4b2e, + 0x6e37, 0x3c59, 0x6e38, 0x6e39, 0x6e3a, 0x4521, 0x306a, 0x3959, + 0x4f3a, 0x6e3e, 0x3734, 0x6e3b, 0x6e3c, 0x4974, 0x3354, 0x4d39, + 0x363f, 0x4554, 0x6e3f, 0x6e40, 0x6e41, 0x4522, 0x6e43, 0x6e42, + 0x4653, 0x6e44, 0x3d36, 0x3c60, 0x475b, 0x4371, 0x3c72, 0x3f6c, + 0x6e45, 0x6e46, 0x3f5d, 0x6e47, 0x6e48, 0x6e49, 0x4d6f, 0x3d37, + 0x6e4b, 0x6e4a, 0x395a, 0x3973, 0x3b40, 0x6e4e, 0x3d66, 0x6e4d, + 0x6e4c, 0x4269, 0x386f, 0x4043, 0x4830, 0x3d39, 0x6e4f, 0x3e5f, + 0x6e52, 0x6e50, 0x6e51, 0x6e54, 0x6e53, 0x3e7a, 0x6e55, 0x6e56, + 0x6e57, 0x4850, 0x3a53, 0x3c61, 0x6e58, 0x6e59, 0x4e24, 0x3d45, + 0x4c6e, 0x4e4c, 0x6e5a, 0x3662, 0x6e5b, 0x4523, 0x6e5e, 0x3378, + 0x3f4b, 0x6e5c, 0x6e5d, 0x4460, 0x4b55, 0x367c, 0x6e60, 0x6e61, + 0x6e5f, 0x6e63, 0x465f, 0x3343, 0x6e67, 0x6e64, 0x6e66, 0x6e62, + 0x6f4f, 0x6e65, 0x4e6b, 0x385a, 0x6e6f, 0x4534, 0x6e6a, 0x6e6d, + 0x6e6b, 0x6e70, 0x6e71, 0x6e69, 0x6e76, 0x3174, 0x6e68, 0x482d, + 0x6e6c, 0x3e60, 0x395b, 0x4b48, 0x3664, 0x3d46, 0x463c, 0x412d, + 0x6e74, 0x6e6e, 0x6e73, 0x4c43, 0x4438, 0x6e75, 0x6e72, 0x412c, + 0x6e79, 0x6e78, 0x6e77, 0x4b2f, 0x3d7b, 0x6e7a, 0x4a5f, 0x3154, + 0x4946, 0x4372, 0x3578, 0x6e7c, 0x395d, 0x3b2c, 0x6e7b, 0x3f6d, + 0x3f6e, 0x6f21, 0x6f23, 0x3e7b, 0x6f22, 0x6f24, 0x3653, 0x4945, + 0x3c62, 0x4f23, 0x6e7e, 0x3a78, 0x4f3f, 0x6f26, 0x6f25, 0x6f27, + 0x6e7d, 0x4669, 0x4555, 0x4457, 0x6f2c, 0x4343, 0x6f28, 0x6f29, + 0x372d, 0x6f2b, 0x3830, 0x6f2a, 0x3e61, 0x3379, 0x6f30, 0x3a3f, + 0x4179, 0x444a, 0x333b, 0x6f2e, 0x6f2f, 0x4443, 0x6f2d, 0x6f31, + 0x6f37, 0x6f3a, 0x6f39, 0x452d, 0x6f32, 0x6f33, 0x6f36, 0x6f38, + 0x3640, 0x6f3b, 0x6f35, 0x6f34, 0x6f3f, 0x6f40, 0x6f41, 0x6f3e, + 0x6f3d, 0x3e62, 0x462a, 0x6f3c, 0x6f45, 0x6f43, 0x6f44, 0x6f42, + 0x4278, 0x6f46, 0x6f47, 0x6f49, 0x3455, 0x6f48, 0x4c7a, 0x6f54, + 0x6f4a, 0x6f4d, 0x6f4b, 0x6f4c, 0x6f4e, 0x6f50, 0x6f51, 0x6f52, + 0x6f55, 0x6f53, 0x6f56, 0x6f58, 0x6f57, 0x4439, 0x4c67, 0x6f59, + 0x412e, 0x6f5a, 0x4a44, 0x6f5b, 0x332b, 0x313c, 0x3457, 0x3456, + 0x6f5c, 0x6f5d, 0x6f5e, 0x6f5f, 0x6f60, 0x3458, 0x3355, 0x395e, + 0x4836, 0x6f62, 0x6f61, 0x6f63, 0x315c, 0x6f66, 0x6f65, 0x6f64, + 0x6f67, 0x6f6a, 0x3047, 0x6f68, 0x6f6c, 0x6f6b, 0x6f6e, 0x6f6d, + 0x6f6f, 0x462e, 0x6f70, 0x6f71, 0x6f73, 0x6f72, 0x496c, 0x6f74, + 0x6f75, 0x3a65, 0x6f76, 0x6f77, 0x4b49, 0x414b, 0x3024, 0x424b, + 0x6f78, 0x496d, 0x6f7b, 0x6f79, 0x395f, 0x6f7a, 0x3842, 0x4a45, + 0x6f7d, 0x7021, 0x6f7e, 0x7022, 0x3121, 0x3f58, 0x3d7c, 0x3459, + 0x7023, 0x4766, 0x7025, 0x3122, 0x7024, 0x4444, 0x4e4d, 0x462b, + 0x6f7c, 0x4e26, 0x3831, 0x4d5b, 0x3679, 0x4e34, 0x3728, 0x4262, + 0x6721, 0x7026, 0x332c, 0x3f6f, 0x3356, 0x7028, 0x7029, 0x7027, + 0x3764, 0x3a5d, 0x3e63, 0x3123, 0x4e59, 0x702b, 0x6e2e, 0x702a, + 0x702e, 0x702c, 0x702d, 0x702f, 0x7030, 0x4e6c, 0x7031, 0x7032, + 0x4049, 0x483b, 0x3f7d, 0x3467, 0x4d3a, 0x326d, 0x3d38, 0x385b, + 0x7035, 0x7034, 0x3b73, 0x7036, 0x7033, 0x3b28, 0x703a, 0x6a2d, + 0x5256, 0x3f77, 0x7038, 0x4e25, 0x4671, 0x312b, 0x4063, 0x3c36, + 0x4a37, 0x3140, 0x4e6d, 0x4d6b, 0x703b, 0x4545, 0x3c7b, 0x703c, + 0x703d, 0x3f4c, 0x703e, 0x4e6e, 0x7039, 0x7040, 0x7042, 0x7041, + 0x703f, 0x7043, 0x7044, 0x417a, 0x3262, 0x7045, 0x4c38, 0x7046, + 0x7047, 0x4f2a, 0x5b31, 0x7048, 0x7049, 0x704a, 0x704e, 0x704b, + 0x704c, 0x704d, 0x704f, 0x4044, 0x4c77, 0x4045, 0x7050, 0x4873, + 0x7051, 0x7353, 0x4c4c, 0x7052, 0x7053, 0x7054, 0x3357, 0x7056, + 0x3f59, 0x7057, 0x3724, 0x7058, 0x705c, 0x705a, 0x705b, 0x3373, + 0x7059, 0x705d, 0x705e, 0x3048, 0x705f, 0x7060, 0x3e64, 0x7061, + 0x3547, 0x7064, 0x7063, 0x7062, 0x6b71, 0x4a5c, 0x7065, 0x7066, + 0x7067, 0x7068, 0x7069, 0x706a, 0x345a, 0x706b, 0x706c, 0x4723, + 0x706e, 0x323b, 0x7071, 0x7070, 0x3124, 0x3641, 0x4a47, 0x443a, + 0x3a22, 0x3960, 0x3d67, 0x3f5c, 0x7073, 0x7072, 0x4d42, 0x3468, + 0x4852, 0x465c, 0x3f7c, 0x4e4e, 0x375b, 0x7076, 0x7075, 0x4b4b, + 0x462c, 0x3150, 0x7077, 0x7074, 0x4951, 0x4d6a, 0x7078, 0x7079, + 0x707b, 0x426a, 0x335b, 0x335c, 0x707a, 0x3469, 0x3832, 0x346a, + 0x453f, 0x4e60, 0x385c, 0x707c, 0x707d, 0x707e, 0x7121, 0x7123, + 0x7122, 0x4977, 0x7124, 0x7125, 0x7126, 0x7127, 0x7129, 0x7128, + 0x712a, 0x4874, 0x664c, 0x3f29, 0x3532, 0x712b, 0x712c, 0x522c, + 0x5d3b, 0x4853, 0x307b, 0x303b, 0x3b74, 0x4b30, 0x3e7e, 0x712d, + 0x4c5f, 0x712e, 0x4d5c, 0x3142, 0x3b41, 0x712f, 0x326e, 0x7130, + 0x7131, 0x7133, 0x7134, 0x7136, 0x7132, 0x7135, 0x345b, 0x7137, + 0x7138, 0x7139, 0x713a, 0x713b, 0x713d, 0x713c, 0x713f, 0x7142, + 0x713e, 0x7140, 0x7141, 0x7143, 0x3642, 0x3c73, 0x7144, 0x7145, + 0x3961, 0x7146, 0x333e, 0x474f, 0x7147, 0x7148, 0x435a, 0x466b, + 0x7149, 0x477d, 0x424c, 0x3158, 0x366e, 0x366f, 0x4373, 0x714e, + 0x3670, 0x326f, 0x714d, 0x714b, 0x714c, 0x714a, 0x7158, 0x714f, + 0x7150, 0x7151, 0x7152, 0x7154, 0x7153, 0x3d59, 0x7155, 0x7157, + 0x3533, 0x7156, 0x417b, 0x3833, 0x7159, 0x424d, 0x715a, 0x462d, + 0x715b, 0x7160, 0x715e, 0x715d, 0x715f, 0x715c, 0x7162, 0x7161, + 0x7164, 0x3643, 0x7163, 0x7165, 0x7166, 0x7168, 0x7167, 0x7169, + 0x716b, 0x716a, 0x397c, 0x716c, 0x716d, 0x333c, 0x716e, 0x716f, + 0x3f71, 0x7170, 0x7171, 0x7172, 0x7173, 0x3962, 0x7174, 0x7175, + 0x7176, 0x7177, 0x7178, 0x4831, 0x717a, 0x4926, 0x717b, 0x7179, + 0x717d, 0x717c, 0x717e, 0x7221, 0x7222, 0x7223, 0x7224, 0x7225, + 0x7226, 0x7227, 0x7228, 0x7229, 0x722a, 0x722b, 0x722c, 0x722d, + 0x722e, 0x5d35, 0x722f, 0x6478, 0x3534, 0x3321, 0x3a32, 0x7231, + 0x7230, 0x4c25, 0x7233, 0x7234, 0x7232, 0x7235, 0x4b62, 0x7236, + 0x357b, 0x4f25, 0x7237, 0x7239, 0x303e, 0x723a, 0x4a2b, 0x7238, + 0x723b, 0x723c, 0x723d, 0x723e, 0x723f, 0x4b6e, 0x3b2d, 0x3a7a, + 0x412f, 0x7240, 0x7243, 0x7241, 0x7244, 0x3871, 0x7242, 0x7245, + 0x7246, 0x7247, 0x724b, 0x3b2a, 0x4264, 0x724c, 0x7249, 0x7248, + 0x724a, 0x375f, 0x7250, 0x724f, 0x724e, 0x3033, 0x725a, 0x7256, + 0x7257, 0x7253, 0x7259, 0x7255, 0x3362, 0x4f4c, 0x7258, 0x7254, + 0x7252, 0x7251, 0x725c, 0x725f, 0x725e, 0x725d, 0x4949, 0x725b, + 0x3073, 0x7260, 0x7262, 0x336f, 0x724d, 0x3137, 0x7264, 0x7263, + 0x7261, 0x432d, 0x4b70, 0x4e5a, 0x7265, 0x7266, 0x7267, 0x7268, + 0x7269, 0x443b, 0x726a, 0x4837, 0x726f, 0x726b, 0x726c, 0x4b31, + 0x4c44, 0x4650, 0x7270, 0x7271, 0x463e, 0x726e, 0x726d, 0x322a, + 0x7279, 0x7278, 0x3175, 0x7276, 0x7275, 0x7273, 0x337b, 0x7272, + 0x3c32, 0x3229, 0x3963, 0x727c, 0x727b, 0x727a, 0x7277, 0x727d, + 0x727e, 0x7325, 0x7324, 0x7326, 0x312d, 0x7321, 0x7322, 0x3974, + 0x4c39, 0x7323, 0x4b32, 0x732b, 0x7327, 0x732c, 0x7329, 0x7328, + 0x375c, 0x732d, 0x732e, 0x732f, 0x732a, 0x7274, 0x7330, 0x4461, + 0x7334, 0x7335, 0x7333, 0x7332, 0x7338, 0x7331, 0x7336, 0x7337, + 0x733a, 0x7339, 0x733c, 0x733d, 0x733e, 0x4f49, 0x733b, 0x426b, + 0x3a6d, 0x733f, 0x7340, 0x7341, 0x7342, 0x7343, 0x3834, 0x7344, + 0x7345, 0x3c2f, 0x7346, 0x7347, 0x7348, 0x7349, 0x734c, 0x734a, + 0x4f3c, 0x734b, 0x4e6f, 0x734d, 0x4e5b, 0x734e, 0x477e, 0x734f, + 0x7351, 0x7352, 0x7350, 0x396d, 0x4c4d, 0x4b63, 0x5677, 0x5d60, + 0x4b7b, 0x322b, 0x7354, 0x3550, 0x7355, 0x7356, 0x7357, 0x3975, + 0x7358, 0x6054, 0x4c5b, 0x4263, 0x7359, 0x735b, 0x735a, 0x735c, + 0x735d, 0x735e, 0x735f, 0x7360, 0x7361, 0x7362, 0x7363, 0x7364, + 0x7365, 0x7366, 0x7367, 0x7368, 0x4524, 0x385d, 0x736a, 0x414d, + 0x736b, 0x736c, 0x4921, 0x736d, 0x736e, 0x6337, 0x6c5a, 0x706d, + 0x736f, 0x7370, 0x7372, 0x7373, 0x7374, 0x4e70, 0x7371, 0x7375, + 0x7376, 0x7378, 0x7377, 0x737a, 0x737b, 0x7379, 0x4e36, 0x737c, + 0x737d, 0x6354, 0x737e, 0x212a, 0x2174, 0x2170, 0x2173, 0x2175, + 0x214a, 0x214b, 0x2176, 0x215c, 0x2124, 0x2125, 0x213f, 0x2330, + 0x2331, 0x2332, 0x2333, 0x2334, 0x2335, 0x2336, 0x2337, 0x2338, + 0x2339, 0x2127, 0x2128, 0x2163, 0x2161, 0x2164, 0x2129, 0x2177, + 0x2341, 0x2342, 0x2343, 0x2344, 0x2345, 0x2346, 0x2347, 0x2348, + 0x2349, 0x234a, 0x234b, 0x234c, 0x234d, 0x234e, 0x234f, 0x2350, + 0x2351, 0x2352, 0x2353, 0x2354, 0x2355, 0x2356, 0x2357, 0x2358, + 0x2359, 0x235a, 0x214e, 0x2140, 0x214f, 0x2130, 0x2132, 0x212e, + 0x2361, 0x2362, 0x2363, 0x2364, 0x2365, 0x2366, 0x2367, 0x2368, + 0x2369, 0x236a, 0x236b, 0x236c, 0x236d, 0x236e, 0x236f, 0x2370, + 0x2371, 0x2372, 0x2373, 0x2374, 0x2375, 0x2376, 0x2377, 0x2378, + 0x2379, 0x237a, 0x2150, 0x2143, 0x2151, 0x2131, 0x216f, +}; + +static const Summary16 jisx0208_uni2indx_page00[16] = { + /* 0x0000 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x118c }, { 5, 0x0053 }, + { 9, 0x0000 }, { 9, 0x0080 }, { 10, 0x0000 }, { 10, 0x0080 }, +}; +static const Summary16 jisx0208_uni2indx_page03[22] = { + /* 0x0300 */ + { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, { 11, 0x0000 }, + { 11, 0x0000 }, { 11, 0xfffe }, { 26, 0x03fb }, { 35, 0xfffe }, + { 50, 0x03fb }, { 59, 0x0000 }, { 59, 0x0000 }, { 59, 0x0000 }, + /* 0x0400 */ + { 59, 0x0002 }, { 60, 0xffff }, { 76, 0xffff }, { 92, 0xffff }, + { 108, 0xffff }, { 124, 0x0002 }, +}; +static const Summary16 jisx0208_uni2indx_page20[50] = { + /* 0x2000 */ + { 125, 0x0000 }, { 125, 0x3361 }, { 132, 0x0063 }, { 136, 0x080d }, + { 140, 0x0000 }, { 140, 0x0000 }, { 140, 0x0000 }, { 140, 0x0000 }, + { 140, 0x0000 }, { 140, 0x0000 }, { 140, 0x0000 }, { 140, 0x0000 }, + { 140, 0x0000 }, { 140, 0x0000 }, { 140, 0x0000 }, { 140, 0x0000 }, + /* 0x2100 */ + { 140, 0x0008 }, { 141, 0x0000 }, { 141, 0x0800 }, { 142, 0x0000 }, + { 142, 0x0000 }, { 142, 0x0000 }, { 142, 0x0000 }, { 142, 0x0000 }, + { 142, 0x0000 }, { 142, 0x000f }, { 146, 0x0000 }, { 146, 0x0000 }, + { 146, 0x0000 }, { 146, 0x0014 }, { 148, 0x0000 }, { 148, 0x0000 }, + /* 0x2200 */ + { 148, 0x098d }, { 154, 0x6404 }, { 158, 0x1f81 }, { 165, 0x2030 }, + { 168, 0x0000 }, { 168, 0x0004 }, { 169, 0x0cc3 }, { 175, 0x0000 }, + { 175, 0x00cc }, { 179, 0x0000 }, { 179, 0x0020 }, { 180, 0x0000 }, + { 180, 0x0000 }, { 180, 0x0000 }, { 180, 0x0000 }, { 180, 0x0000 }, + /* 0x2300 */ + { 180, 0x0000 }, { 180, 0x0004 }, +}; +static const Summary16 jisx0208_uni2indx_page25[23] = { + /* 0x2500 */ + { 181, 0x900f }, { 187, 0x3999 }, { 195, 0x9939 }, { 203, 0x9999 }, + { 211, 0x0804 }, { 213, 0x0000 }, { 213, 0x0000 }, { 213, 0x0000 }, + { 213, 0x0000 }, { 213, 0x0000 }, { 213, 0x0003 }, { 215, 0x300c }, + { 219, 0xc8c0 }, { 224, 0x0000 }, { 224, 0x8000 }, { 225, 0x0000 }, + /* 0x2600 */ + { 225, 0x0060 }, { 227, 0x0000 }, { 227, 0x0000 }, { 227, 0x0000 }, + { 227, 0x0005 }, { 229, 0x0000 }, { 229, 0xa400 }, +}; +static const Summary16 jisx0208_uni2indx_page30[16] = { + /* 0x3000 */ + { 232, 0xffef }, { 247, 0x103f }, { 254, 0x0000 }, { 254, 0x0000 }, + { 254, 0xfffe }, { 269, 0xffff }, { 285, 0xffff }, { 301, 0xffff }, + { 317, 0xffff }, { 333, 0x780f }, { 341, 0xfffe }, { 356, 0xffff }, + { 372, 0xffff }, { 388, 0xffff }, { 404, 0xffff }, { 420, 0x787f }, +}; +static const Summary16 jisx0208_uni2indx_page4e[1307] = { + /* 0x4e00 */ + { 431, 0x6f8b }, { 441, 0x43f3 }, { 450, 0x2442 }, { 454, 0x9b46 }, + { 462, 0xe82c }, { 469, 0xe3e0 }, { 477, 0x0004 }, { 478, 0x400a }, + { 481, 0x5f65 }, { 491, 0xdb36 }, { 501, 0x7977 }, { 512, 0x0449 }, + { 516, 0xecd7 }, { 527, 0xe3f0 }, { 536, 0x6038 }, { 541, 0x08c5 }, + /* 0x4f00 */ + { 546, 0xe602 }, { 552, 0x3403 }, { 557, 0x8000 }, { 558, 0x3551 }, + { 565, 0xe0c8 }, { 571, 0x7eab }, { 582, 0x8200 }, { 584, 0x9869 }, + { 591, 0xa948 }, { 597, 0x2942 }, { 602, 0xe803 }, { 608, 0x8060 }, + { 611, 0x441c }, { 616, 0xad93 }, { 625, 0xc03a }, { 631, 0x4568 }, + /* 0x5000 */ + { 637, 0xaa60 }, { 643, 0x8656 }, { 650, 0x3f7a }, { 661, 0x0240 }, + { 663, 0x8388 }, { 668, 0x1461 }, { 673, 0x1020 }, { 675, 0x2174 }, + { 681, 0x2021 }, { 684, 0x0702 }, { 688, 0x3000 }, { 690, 0x40bc }, + { 696, 0xa624 }, { 702, 0x4462 }, { 707, 0x60a8 }, { 712, 0x0a20 }, + /* 0x5100 */ + { 715, 0x0217 }, { 720, 0x8574 }, { 727, 0x0402 }, { 729, 0x9c84 }, + { 735, 0x7bfb }, { 748, 0x1415 }, { 753, 0x7f24 }, { 762, 0x11e2 }, + { 768, 0xb665 }, { 777, 0x02ef }, { 785, 0x1f75 }, { 795, 0x20ff }, + { 804, 0x3a70 }, { 811, 0x3840 }, { 815, 0x26c3 }, { 822, 0x6763 }, + /* 0x5200 */ + { 831, 0x4dd9 }, { 840, 0x2092 }, { 844, 0x46b0 }, { 850, 0x0fc9 }, + { 858, 0xbc98 }, { 866, 0x4850 }, { 870, 0x8638 }, { 876, 0xa03f }, + { 884, 0x2388 }, { 889, 0x8816 }, { 894, 0x3e09 }, { 901, 0x5232 }, + { 907, 0x22aa }, { 913, 0xe3a4 }, { 921, 0x00dd }, { 927, 0xc72c }, + /* 0x5300 */ + { 935, 0xa166 }, { 942, 0x26e1 }, { 949, 0x840b }, { 954, 0x8f0a }, + { 961, 0x27eb }, { 971, 0x559e }, { 980, 0xc241 }, { 985, 0x89bb }, + { 994, 0x0014 }, { 996, 0x8540 }, { 1000, 0x6361 }, { 1007, 0x0849 }, + { 1011, 0x7f0c }, { 1020, 0x8ad0 }, { 1026, 0xff3e }, { 1039, 0x05cf }, + /* 0x5400 */ + { 1047, 0xff1a }, { 1058, 0xa803 }, { 1063, 0x7a41 }, { 1070, 0x7b40 }, + { 1077, 0x4745 }, { 1084, 0x8002 }, { 1086, 0x0500 }, { 1088, 0x38eb }, + { 1097, 0xd851 }, { 1104, 0x0005 }, { 1106, 0x9934 }, { 1113, 0x710c }, + { 1119, 0x0397 }, { 1126, 0x0100 }, { 1127, 0x6366 }, { 1135, 0x2404 }, + /* 0x5500 */ + { 1138, 0x80d0 }, { 1142, 0x0051 }, { 1145, 0xc000 }, { 1147, 0x430a }, + { 1152, 0x9071 }, { 1158, 0x30c8 }, { 1163, 0x0008 }, { 1164, 0x5800 }, + { 1167, 0x0e99 }, { 1174, 0xf700 }, { 1181, 0x5f80 }, { 1188, 0x0041 }, + { 1190, 0x00b0 }, { 1193, 0x9410 }, { 1197, 0x0018 }, { 1199, 0x6280 }, + /* 0x5600 */ + { 1203, 0x0240 }, { 1205, 0x09d0 }, { 1210, 0x8200 }, { 1212, 0x0156 }, + { 1217, 0x5004 }, { 1220, 0x0801 }, { 1222, 0x1d10 }, { 1227, 0x0510 }, + { 1230, 0x84c1 }, { 1235, 0x0010 }, { 1236, 0x4025 }, { 1240, 0x1050 }, + { 1243, 0x410f }, { 1249, 0x4d8a }, { 1256, 0x4009 }, { 1259, 0xa60d }, + /* 0x5700 */ + { 1266, 0xab19 }, { 1274, 0x914c }, { 1280, 0x21c0 }, { 1284, 0x0981 }, + { 1288, 0xc485 }, { 1294, 0x0003 }, { 1296, 0x0652 }, { 1301, 0x8000 }, + { 1302, 0x0b04 }, { 1306, 0x0008 }, { 1307, 0x041d }, { 1312, 0x0009 }, + { 1314, 0x4849 }, { 1319, 0x905c }, { 1325, 0x0009 }, { 1327, 0x1690 }, + /* 0x5800 */ + { 1332, 0x0c65 }, { 1338, 0x2220 }, { 1341, 0x8412 }, { 1345, 0x2433 }, + { 1351, 0x0c03 }, { 1355, 0x4796 }, { 1363, 0x0a04 }, { 1366, 0x4225 }, + { 1371, 0x0028 }, { 1373, 0x9088 }, { 1377, 0x4900 }, { 1380, 0x4f08 }, + { 1386, 0x14a2 }, { 1391, 0xd3aa }, { 1400, 0xd830 }, { 1406, 0x3e87 }, + /* 0x5900 */ + { 1415, 0x8604 }, { 1419, 0x1f61 }, { 1427, 0x7ea4 }, { 1436, 0x4186 }, + { 1441, 0xc390 }, { 1447, 0x05b3 }, { 1454, 0x57a5 }, { 1463, 0x2118 }, + { 1467, 0x241e }, { 1473, 0x2a48 }, { 1478, 0x1128 }, { 1482, 0x4a04 }, + { 1486, 0x0a40 }, { 1489, 0x161b }, { 1496, 0x0d60 }, { 1501, 0x8840 }, + /* 0x5a00 */ + { 1504, 0x020a }, { 1507, 0x9502 }, { 1512, 0x8221 }, { 1516, 0x1060 }, + { 1519, 0x0243 }, { 1523, 0x0400 }, { 1524, 0x1444 }, { 1528, 0x8000 }, + { 1529, 0x0000 }, { 1529, 0x0c04 }, { 1532, 0x0000 }, { 1532, 0x7000 }, + { 1535, 0x1a06 }, { 1540, 0x00c1 }, { 1543, 0x024a }, { 1547, 0x0c00 }, + /* 0x5b00 */ + { 1549, 0x1a00 }, { 1552, 0x0040 }, { 1553, 0x1404 }, { 1556, 0x4045 }, + { 1560, 0x0029 }, { 1563, 0xbdb3 }, { 1574, 0x0a78 }, { 1580, 0x052b }, + { 1586, 0xbba9 }, { 1596, 0xbfa0 }, { 1605, 0x407c }, { 1611, 0x8379 }, + { 1619, 0x12fc }, { 1627, 0xe81d }, { 1635, 0x4bf6 }, { 1645, 0xc569 }, + /* 0x5c00 */ + { 1653, 0xeff6 }, { 1666, 0x044a }, { 1670, 0x2115 }, { 1675, 0xff02 }, + { 1684, 0xed63 }, { 1694, 0x402b }, { 1699, 0xd033 }, { 1706, 0x0242 }, + { 1709, 0x1000 }, { 1710, 0x0013 }, { 1713, 0x1b02 }, { 1718, 0x59ca }, + { 1726, 0x00a0 }, { 1728, 0x0200 }, { 1729, 0xa703 }, { 1736, 0x2c41 }, + /* 0x5d00 */ + { 1741, 0x4880 }, { 1744, 0x8ff2 }, { 1754, 0x0204 }, { 1756, 0x0000 }, + { 1756, 0x5800 }, { 1759, 0x1005 }, { 1762, 0x9200 }, { 1765, 0x0048 }, + { 1767, 0x1894 }, { 1772, 0x2001 }, { 1774, 0x5004 }, { 1777, 0x3480 }, + { 1781, 0x3200 }, { 1784, 0x684c }, { 1790, 0x49ea }, { 1798, 0x68be }, + /* 0x5e00 */ + { 1807, 0x184c }, { 1812, 0x2e42 }, { 1818, 0xa820 }, { 1822, 0x21c9 }, + { 1828, 0x50b9 }, { 1835, 0x80b0 }, { 1839, 0x001e }, { 1843, 0xff7c }, + { 1856, 0x849a }, { 1862, 0x14e0 }, { 1867, 0x28c1 }, { 1872, 0x01e0 }, + { 1876, 0x870e }, { 1883, 0xac49 }, { 1890, 0x130f }, { 1897, 0xdddb }, + /* 0x5f00 */ + { 1909, 0xbe1a }, { 1918, 0x89fb }, { 1928, 0xa2e0 }, { 1934, 0x51a2 }, + { 1940, 0x5502 }, { 1945, 0x32ca }, { 1952, 0x3e46 }, { 1960, 0x928b }, + { 1967, 0x1dbf }, { 1978, 0x438f }, { 1986, 0x6703 }, { 1993, 0x3218 }, + { 1998, 0x3028 }, { 2002, 0x33c0 }, { 2008, 0x0811 }, { 2011, 0xa923 }, + /* 0x6000 */ + { 2018, 0xc000 }, { 2020, 0x3a65 }, { 2028, 0x8fe3 }, { 2038, 0x0402 }, + { 2040, 0x2c4e }, { 2047, 0x8625 }, { 2053, 0xbf3d }, { 2065, 0x00a1 }, + { 2068, 0x3a1a }, { 2075, 0x8cd4 }, { 2082, 0x06c9 }, { 2088, 0x317c }, + { 2096, 0x00e0 }, { 2099, 0x950a }, { 2105, 0x018b }, { 2110, 0x0edb }, + /* 0x6100 */ + { 2119, 0xe34b }, { 2128, 0x8c20 }, { 2132, 0x1182 }, { 2136, 0xf010 }, + { 2141, 0x7d94 }, { 2150, 0xa728 }, { 2157, 0xc9ac }, { 2165, 0x40fb }, + { 2173, 0x4484 }, { 2177, 0x0653 }, { 2183, 0x5a90 }, { 2189, 0x4444 }, + { 2193, 0x3fc8 }, { 2202, 0x0001 }, { 2203, 0x0048 }, { 2205, 0xf5d4 }, + /* 0x6200 */ + { 2215, 0x7701 }, { 2222, 0xec57 }, { 2232, 0xc442 }, { 2237, 0x891d }, + { 2244, 0x6b83 }, { 2252, 0x4928 }, { 2257, 0x4109 }, { 2261, 0xd242 }, + { 2267, 0x061d }, { 2273, 0x59fe }, { 2284, 0x1800 }, { 2286, 0x3a22 }, + { 2292, 0xb7e4 }, { 2302, 0x3b9f }, { 2313, 0xf003 }, { 2319, 0xc0ea }, + /* 0x6300 */ + { 2326, 0x1386 }, { 2332, 0x8202 }, { 2335, 0x8980 }, { 2339, 0xe400 }, + { 2343, 0xb200 }, { 2347, 0x10a1 }, { 2351, 0x4b80 }, { 2356, 0x0cc4 }, + { 2361, 0xd309 }, { 2368, 0x8944 }, { 2373, 0x1faf }, { 2384, 0x4834 }, + { 2389, 0x8259 }, { 2395, 0x0c45 }, { 2400, 0x420a }, { 2404, 0x0450 }, + /* 0x6400 */ + { 2407, 0xa040 }, { 2410, 0x10c8 }, { 2414, 0x3140 }, { 2418, 0x4450 }, + { 2422, 0x4004 }, { 2424, 0x0100 }, { 2425, 0x8280 }, { 2428, 0x0540 }, + { 2431, 0x0108 }, { 2433, 0x442c }, { 2438, 0x6a30 }, { 2444, 0x1a05 }, + { 2449, 0x20a6 }, { 2454, 0x0514 }, { 2458, 0x90cf }, { 2466, 0x6456 }, + /* 0x6500 */ + { 2473, 0x0021 }, { 2475, 0x3100 }, { 2478, 0x9c18 }, { 2484, 0xcbf0 }, + { 2493, 0xa120 }, { 2497, 0x63e2 }, { 2505, 0x104c }, { 2509, 0x01b5 }, + { 2515, 0x538c }, { 2522, 0x9a83 }, { 2529, 0xb8b2 }, { 2537, 0x3281 }, + { 2542, 0x987a }, { 2550, 0x0a84 }, { 2554, 0x33e7 }, { 2564, 0x0c02 }, + /* 0x6600 */ + { 2567, 0xd4cc }, { 2575, 0x9018 }, { 2579, 0xa1a1 }, { 2585, 0x9070 }, + { 2590, 0x8a1e }, { 2597, 0xe004 }, { 2601, 0xc3d4 }, { 2609, 0x0451 }, + { 2613, 0x439a }, { 2620, 0x21c2 }, { 2625, 0x4844 }, { 2629, 0x5310 }, + { 2634, 0x0292 }, { 2638, 0x3640 }, { 2643, 0x0241 }, { 2646, 0xf3bd }, + /* 0x6700 */ + { 2658, 0xab09 }, { 2665, 0xe8f0 }, { 2673, 0x7dc0 }, { 2681, 0xa5d2 }, + { 2689, 0xc242 }, { 2694, 0xd24b }, { 2702, 0xa43f }, { 2711, 0xd0af }, + { 2720, 0x1aa0 }, { 2725, 0x34a1 }, { 2731, 0x8247 }, { 2737, 0x03d8 }, + { 2743, 0xc452 }, { 2749, 0x651b }, { 2757, 0xd294 }, { 2764, 0xc83a }, + /* 0x6800 */ + { 2771, 0x001c }, { 2774, 0x40c8 }, { 2778, 0x0e06 }, { 2783, 0x3314 }, + { 2789, 0x614f }, { 2797, 0xb21b }, { 2805, 0x0088 }, { 2807, 0xc0d0 }, + { 2812, 0xa02a }, { 2817, 0xa898 }, { 2823, 0xa1c5 }, { 2830, 0x166b }, + { 2838, 0x2e50 }, { 2844, 0x85b4 }, { 2851, 0xc08b }, { 2857, 0x0604 }, + /* 0x6900 */ + { 2860, 0xf933 }, { 2870, 0x1e04 }, { 2875, 0x056e }, { 2882, 0xa251 }, + { 2888, 0x0400 }, { 2889, 0x7638 }, { 2897, 0xec07 }, { 2905, 0x73b8 }, + { 2914, 0x4406 }, { 2918, 0x1832 }, { 2923, 0x4081 }, { 2926, 0xc816 }, + { 2932, 0x7c8a }, { 2940, 0x6309 }, { 2946, 0x2980 }, { 2950, 0xaa04 }, + /* 0x6a00 */ + { 2955, 0x1c24 }, { 2960, 0xca9c }, { 2968, 0x4e0e }, { 2975, 0x2760 }, + { 2981, 0x0990 }, { 2985, 0x8300 }, { 2988, 0x0046 }, { 2991, 0x8104 }, + { 2994, 0x6011 }, { 2998, 0x1081 }, { 3001, 0x540d }, { 3007, 0x0908 }, + { 3010, 0x000e }, { 3013, 0xcc0a }, { 3019, 0x0500 }, { 3021, 0x0c00 }, + /* 0x6b00 */ + { 3023, 0x0430 }, { 3026, 0xa044 }, { 3030, 0x008b }, { 3034, 0x6784 }, + { 3041, 0x5288 }, { 3046, 0x8a19 }, { 3052, 0x865e }, { 3060, 0x8b18 }, + { 3066, 0x2e59 }, { 3074, 0x4160 }, { 3078, 0x8c10 }, { 3082, 0x9cbe }, + { 3092, 0x6861 }, { 3098, 0x891c }, { 3104, 0x9800 }, { 3107, 0x0008 }, + /* 0x6c00 */ + { 3108, 0x8100 }, { 3110, 0x089a }, { 3115, 0x0018 }, { 3117, 0x4190 }, + { 3121, 0x4007 }, { 3125, 0xe4a1 }, { 3132, 0x0505 }, { 3136, 0x640d }, + { 3142, 0x310e }, { 3148, 0x0e4d }, { 3155, 0x4806 }, { 3159, 0xff0a }, + { 3169, 0x1632 }, { 3175, 0x2aa8 }, { 3181, 0x852e }, { 3188, 0x000b }, + /* 0x6d00 */ + { 3191, 0x1800 }, { 3193, 0xca84 }, { 3199, 0x0e20 }, { 3203, 0x696c }, + { 3211, 0x0032 }, { 3214, 0x1600 }, { 3217, 0x5658 }, { 3224, 0x0390 }, + { 3228, 0x5120 }, { 3232, 0x1a28 }, { 3237, 0x8000 }, { 3238, 0x1124 }, + { 3242, 0x18e1 }, { 3248, 0x4326 }, { 3254, 0x5d52 }, { 3262, 0x0eaa }, + /* 0x6e00 */ + { 3269, 0x0fa0 }, { 3275, 0xae28 }, { 3282, 0xfa7b }, { 3294, 0x4500 }, + { 3297, 0x6408 }, { 3301, 0x8940 }, { 3305, 0xc880 }, { 3309, 0xc044 }, + { 3313, 0x9005 }, { 3317, 0xb141 }, { 3323, 0x8424 }, { 3327, 0x24c4 }, + { 3332, 0x1a34 }, { 3338, 0x603a }, { 3344, 0x9000 }, { 3346, 0xc194 }, + /* 0x6f00 */ + { 3352, 0x8246 }, { 3357, 0x003a }, { 3361, 0x180d }, { 3366, 0xc106 }, + { 3371, 0x0022 }, { 3373, 0x9910 }, { 3378, 0xe050 }, { 3383, 0x1511 }, + { 3388, 0x4057 }, { 3394, 0x0082 }, { 3396, 0x041a }, { 3400, 0x020a }, + { 3403, 0x004f }, { 3408, 0x8930 }, { 3413, 0xd813 }, { 3420, 0x444a }, + /* 0x7000 */ + { 3425, 0x8a02 }, { 3429, 0xed22 }, { 3437, 0x10c0 }, { 3440, 0x4005 }, + { 3443, 0x1000 }, { 3444, 0x0102 }, { 3446, 0x8808 }, { 3449, 0x3101 }, + { 3453, 0x4600 }, { 3456, 0x0204 }, { 3458, 0xf000 }, { 3462, 0x0708 }, + { 3466, 0x8900 }, { 3469, 0xa200 }, { 3472, 0x0000 }, { 3472, 0x2202 }, + /* 0x7100 */ + { 3475, 0x0200 }, { 3476, 0x1610 }, { 3480, 0x0042 }, { 3482, 0x1040 }, + { 3484, 0x5200 }, { 3487, 0x0260 }, { 3490, 0x52f4 }, { 3498, 0x2000 }, + { 3499, 0x8510 }, { 3503, 0x8230 }, { 3507, 0x1100 }, { 3509, 0x4202 }, + { 3512, 0x4308 }, { 3516, 0x80b5 }, { 3522, 0x70e1 }, { 3529, 0x9a20 }, + /* 0x7200 */ + { 3534, 0x2040 }, { 3536, 0x0801 }, { 3538, 0x3500 }, { 3542, 0xfc65 }, + { 3552, 0x19c1 }, { 3558, 0xab04 }, { 3564, 0x0286 }, { 3568, 0x6214 }, + { 3573, 0x0087 }, { 3577, 0x0044 }, { 3579, 0x9085 }, { 3584, 0x0244 }, + { 3587, 0x405c }, { 3592, 0x0a85 }, { 3597, 0x3207 }, { 3603, 0x3380 }, + /* 0x7300 */ + { 3608, 0x0400 }, { 3609, 0xb8c0 }, { 3615, 0xce20 }, { 3621, 0xc0d0 }, + { 3626, 0xc030 }, { 3630, 0x0080 }, { 3631, 0x0508 }, { 3634, 0x0d25 }, + { 3640, 0x0a90 }, { 3644, 0x0040 }, { 3645, 0x0200 }, { 3646, 0x080c }, + { 3649, 0x6505 }, { 3655, 0x4000 }, { 3656, 0x6421 }, { 3661, 0x4102 }, + /* 0x7400 */ + { 3664, 0x0268 }, { 3668, 0x0000 }, { 3668, 0x0024 }, { 3670, 0x847c }, + { 3677, 0x0002 }, { 3678, 0xde20 }, { 3685, 0x8619 }, { 3691, 0x4049 }, + { 3695, 0x0808 }, { 3697, 0x4000 }, { 3698, 0x0084 }, { 3700, 0x2001 }, + { 3702, 0x8400 }, { 3704, 0x1010 }, { 3706, 0x42cd }, { 3713, 0x01c7 }, + /* 0x7500 */ + { 3719, 0x7038 }, { 3725, 0xd52a }, { 3733, 0x1968 }, { 3739, 0x1d8f }, + { 3748, 0xbe50 }, { 3756, 0x3e12 }, { 3763, 0x2ef5 }, { 3773, 0x81d9 }, + { 3780, 0xcec4 }, { 3788, 0x2412 }, { 3792, 0x0828 }, { 3795, 0x732e }, + { 3804, 0x24ac }, { 3810, 0x4b34 }, { 3817, 0x020c }, { 3820, 0xd41d }, + /* 0x7600 */ + { 3828, 0x2a02 }, { 3832, 0x8000 }, { 3833, 0x0097 }, { 3838, 0x0811 }, + { 3841, 0x11c4 }, { 3846, 0x1144 }, { 3850, 0x1786 }, { 3857, 0x7d45 }, + { 3866, 0x49d9 }, { 3874, 0x0649 }, { 3879, 0x4000 }, { 3880, 0x8791 }, + { 3887, 0x254c }, { 3893, 0xd8c4 }, { 3900, 0x44ba }, { 3907, 0x4914 }, + /* 0x7700 */ + { 3912, 0x1b92 }, { 3919, 0xc800 }, { 3922, 0x0271 }, { 3927, 0x1580 }, + { 3931, 0x0081 }, { 3933, 0x0c00 }, { 3935, 0x096a }, { 3941, 0xc200 }, + { 3944, 0x4800 }, { 3946, 0x4002 }, { 3948, 0x3021 }, { 3952, 0xba49 }, + { 3960, 0x2080 }, { 3962, 0x1c80 }, { 3966, 0xe2ac }, { 3974, 0x1008 }, + /* 0x7800 */ + { 3976, 0x1004 }, { 3978, 0x0034 }, { 3981, 0x00e1 }, { 3985, 0x8414 }, + { 3989, 0x0020 }, { 3990, 0x2000 }, { 3991, 0x9800 }, { 3994, 0x1014 }, + { 3997, 0x70c2 }, { 4003, 0x04aa }, { 4008, 0x8688 }, { 4013, 0x5420 }, + { 4017, 0x0c62 }, { 4022, 0x0413 }, { 4026, 0x9180 }, { 4030, 0x2010 }, + /* 0x7900 */ + { 4032, 0x4082 }, { 4035, 0x0206 }, { 4038, 0x1c40 }, { 4042, 0x5400 }, + { 4045, 0x0383 }, { 4050, 0xe4e9 }, { 4059, 0x2125 }, { 4064, 0x8480 }, + { 4067, 0xe433 }, { 4075, 0x2000 }, { 4076, 0x44c0 }, { 4080, 0xe609 }, + { 4087, 0x0a03 }, { 4091, 0x8126 }, { 4096, 0x12da }, { 4103, 0x0801 }, + /* 0x7a00 */ + { 4105, 0x6901 }, { 4110, 0x9790 }, { 4117, 0x4001 }, { 4119, 0xf886 }, + { 4127, 0xe24d }, { 4135, 0x0081 }, { 4137, 0x0a0e }, { 4142, 0xa651 }, + { 4149, 0x011a }, { 4153, 0x81ec }, { 4160, 0xc600 }, { 4164, 0x8441 }, + { 4168, 0xadb8 }, { 4177, 0xb62c }, { 4185, 0xa46f }, { 4194, 0x8741 }, + /* 0x7b00 */ + { 4200, 0x8d54 }, { 4207, 0x4b02 }, { 4212, 0x1161 }, { 4217, 0x0268 }, + { 4221, 0xbb60 }, { 4229, 0x2057 }, { 4235, 0x50a0 }, { 4239, 0x0433 }, + { 4244, 0xa8c0 }, { 4249, 0xb7b4 }, { 4259, 0x2402 }, { 4262, 0x0112 }, + { 4265, 0x9ad3 }, { 4274, 0x2000 }, { 4275, 0x2271 }, { 4281, 0x00c8 }, + /* 0x7c00 */ + { 4284, 0x2081 }, { 4287, 0x809e }, { 4293, 0x0c8a }, { 4298, 0xe180 }, + { 4303, 0xb009 }, { 4308, 0x8151 }, { 4313, 0x1031 }, { 4317, 0x4028 }, + { 4320, 0x2a0e }, { 4326, 0x89a5 }, { 4333, 0x69b6 }, { 4342, 0x620e }, + { 4348, 0x4425 }, { 4353, 0xd144 }, { 4359, 0x8085 }, { 4363, 0x4d54 }, + /* 0x7d00 */ + { 4370, 0x2c75 }, { 4378, 0x1fb1 }, { 4387, 0xd807 }, { 4394, 0x862d }, + { 4401, 0xd87c }, { 4410, 0x4841 }, { 4414, 0x414e }, { 4420, 0x226e }, + { 4427, 0x8200 }, { 4429, 0x9e08 }, { 4435, 0xf80c }, { 4442, 0xed37 }, + { 4453, 0x8c80 }, { 4457, 0x7526 }, { 4465, 0x9313 }, { 4472, 0x0814 }, + /* 0x7e00 */ + { 4475, 0x0e32 }, { 4481, 0xc804 }, { 4485, 0x484e }, { 4491, 0x6ea6 }, + { 4500, 0x2c4a }, { 4506, 0x6670 }, { 4513, 0x26c0 }, { 4518, 0xba01 }, + { 4524, 0xd30c }, { 4531, 0x185d }, { 4538, 0x0000 }, { 4538, 0x0000 }, + { 4538, 0x0000 }, { 4538, 0x0000 }, { 4538, 0x0000 }, { 4538, 0x0000 }, + /* 0x7f00 */ + { 4538, 0x0000 }, { 4538, 0x0000 }, { 4538, 0x0000 }, { 4538, 0x0540 }, + { 4541, 0x7020 }, { 4545, 0x8133 }, { 4551, 0x4f81 }, { 4558, 0x03a5 }, + { 4564, 0x55ec }, { 4573, 0x6410 }, { 4577, 0xc318 }, { 4583, 0x2344 }, + { 4588, 0x1462 }, { 4593, 0x0034 }, { 4596, 0x0a43 }, { 4601, 0x1a09 }, + /* 0x8000 */ + { 4606, 0x187b }, { 4614, 0x13a5 }, { 4621, 0x0102 }, { 4623, 0xa848 }, + { 4628, 0x0440 }, { 4630, 0xc544 }, { 4636, 0x8106 }, { 4640, 0xe2dd }, + { 4650, 0x1af0 }, { 4657, 0x2d48 }, { 4663, 0xb626 }, { 4671, 0x0416 }, + { 4675, 0x5058 }, { 4680, 0x6e40 }, { 4686, 0x8032 }, { 4690, 0x3112 }, + /* 0x8100 */ + { 4695, 0x07e4 }, { 4702, 0x0c00 }, { 4704, 0x8208 }, { 4707, 0x420a }, + { 4711, 0x4840 }, { 4714, 0x803b }, { 4720, 0x4860 }, { 4724, 0x8713 }, + { 4731, 0x850d }, { 4737, 0x3428 }, { 4742, 0x0319 }, { 4747, 0xe529 }, + { 4755, 0x2345 }, { 4761, 0x870a }, { 4767, 0x25a9 }, { 4774, 0x5c18 }, + /* 0x8200 */ + { 4780, 0x77a6 }, { 4790, 0xd9c5 }, { 4799, 0x5e00 }, { 4804, 0x03e8 }, + { 4810, 0x0081 }, { 4812, 0xa700 }, { 4817, 0xcd54 }, { 4825, 0x41c6 }, + { 4831, 0x2800 }, { 4833, 0xa204 }, { 4837, 0xb860 }, { 4843, 0x2b0a }, + { 4849, 0x0020 }, { 4850, 0xda9e }, { 4860, 0x08ea }, { 4866, 0x0e1a }, + /* 0x8300 */ + { 4872, 0x427c }, { 4879, 0x11c0 }, { 4883, 0x8908 }, { 4887, 0x0376 }, + { 4894, 0x8621 }, { 4899, 0x0105 }, { 4902, 0x0000 }, { 4902, 0x18a8 }, + { 4907, 0x46a0 }, { 4912, 0xc448 }, { 4917, 0x0d05 }, { 4922, 0x2022 }, + { 4925, 0x5422 }, { 4930, 0x9148 }, { 4935, 0x8a01 }, { 4939, 0x2897 }, + /* 0x8400 */ + { 4946, 0x7898 }, { 4953, 0x0008 }, { 4954, 0x1605 }, { 4959, 0x3122 }, + { 4964, 0x4240 }, { 4967, 0x0880 }, { 4969, 0xfa4e }, { 4979, 0x06a2 }, + { 4984, 0x0814 }, { 4987, 0x9211 }, { 4992, 0x2002 }, { 4994, 0x9b04 }, + { 5000, 0x2e52 }, { 5007, 0x0643 }, { 5012, 0x5000 }, { 5014, 0x9010 }, + /* 0x8500 */ + { 5017, 0x0041 }, { 5019, 0x85ba }, { 5027, 0x3042 }, { 5031, 0x2020 }, + { 5033, 0x4f0b }, { 5041, 0x05a0 }, { 5045, 0x2708 }, { 5050, 0x4080 }, + { 5052, 0x0591 }, { 5057, 0x1a93 }, { 5064, 0xdf50 }, { 5073, 0x0600 }, + { 5075, 0xa202 }, { 5079, 0x3021 }, { 5083, 0x0630 }, { 5087, 0x4e80 }, + /* 0x8600 */ + { 5092, 0x0cc4 }, { 5097, 0x04c8 }, { 5101, 0xa004 }, { 5104, 0x8001 }, + { 5106, 0x6000 }, { 5108, 0xd431 }, { 5115, 0x0880 }, { 5117, 0x0a02 }, + { 5120, 0x1c00 }, { 5123, 0x0028 }, { 5125, 0x8e18 }, { 5131, 0x0041 }, + { 5133, 0x6ad0 }, { 5140, 0xca10 }, { 5145, 0xf210 }, { 5151, 0x4b00 }, + /* 0x8700 */ + { 5155, 0x274d }, { 5163, 0x1506 }, { 5168, 0x0220 }, { 5170, 0x8890 }, + { 5174, 0x5a00 }, { 5178, 0x82a8 }, { 5183, 0x4549 }, { 5189, 0x8150 }, + { 5193, 0x2004 }, { 5195, 0x8000 }, { 5196, 0x8804 }, { 5199, 0x2c08 }, + { 5203, 0x08d1 }, { 5208, 0x0005 }, { 5210, 0x8001 }, { 5212, 0x4ac4 }, + /* 0x8800 */ + { 5218, 0xe020 }, { 5222, 0x0062 }, { 5225, 0x008e }, { 5229, 0x0a42 }, + { 5233, 0x3055 }, { 5239, 0x6a8c }, { 5246, 0x090e }, { 5251, 0xe0a5 }, + { 5258, 0x2906 }, { 5263, 0x42c4 }, { 5268, 0x4814 }, { 5272, 0x80b3 }, + { 5278, 0x803e }, { 5284, 0xb330 }, { 5291, 0x0102 }, { 5293, 0x731c }, + /* 0x8900 */ + { 5301, 0x1494 }, { 5306, 0x600d }, { 5311, 0x0c20 }, { 5314, 0x0940 }, + { 5317, 0x301a }, { 5322, 0xc040 }, { 5325, 0xa451 }, { 5331, 0xc094 }, + { 5336, 0x8dca }, { 5344, 0x05c8 }, { 5349, 0x96c2 }, { 5356, 0xa40c }, + { 5361, 0x0001 }, { 5362, 0x3404 }, { 5366, 0x00c8 }, { 5369, 0x0110 }, + /* 0x8a00 */ + { 5371, 0x550d }, { 5378, 0xa9c9 }, { 5386, 0x2428 }, { 5390, 0x1c5a }, + { 5397, 0x0142 }, { 5400, 0x4837 }, { 5407, 0x7a4d }, { 5416, 0x100f }, + { 5421, 0x32b4 }, { 5428, 0x452a }, { 5434, 0x317b }, { 5443, 0x9205 }, + { 5448, 0xb894 }, { 5455, 0x5c44 }, { 5461, 0x68d7 }, { 5470, 0x458a }, + /* 0x8b00 */ + { 5476, 0x5097 }, { 5483, 0x2ed1 }, { 5491, 0x1943 }, { 5497, 0x4208 }, + { 5500, 0xd202 }, { 5505, 0x9d40 }, { 5511, 0x9840 }, { 5515, 0x2097 }, + { 5521, 0x5409 }, { 5526, 0x064d }, { 5532, 0x0000 }, { 5532, 0x0000 }, + { 5532, 0x0000 }, { 5532, 0x0000 }, { 5532, 0x0000 }, { 5532, 0x0000 }, + /* 0x8c00 */ + { 5532, 0x0000 }, { 5532, 0x0000 }, { 5532, 0x0000 }, { 5532, 0x8480 }, + { 5535, 0x5542 }, { 5541, 0x0421 }, { 5544, 0x1c06 }, { 5549, 0x1700 }, + { 5553, 0x7624 }, { 5560, 0x6110 }, { 5564, 0xff87 }, { 5576, 0xb9dd }, + { 5587, 0x659f }, { 5597, 0x5c0a }, { 5603, 0x245d }, { 5610, 0x3c00 }, + /* 0x8d00 */ + { 5614, 0xadb0 }, { 5622, 0x0059 }, { 5626, 0x0000 }, { 5626, 0x0000 }, + { 5626, 0x0000 }, { 5626, 0x0000 }, { 5626, 0x28d0 }, { 5631, 0x009b }, + { 5636, 0x0422 }, { 5639, 0x0200 }, { 5640, 0x0108 }, { 5642, 0x4408 }, + { 5645, 0x9804 }, { 5649, 0xac40 }, { 5654, 0x8d0a }, { 5660, 0x9028 }, + /* 0x8e00 */ + { 5664, 0x8700 }, { 5668, 0xe001 }, { 5672, 0x0400 }, { 5673, 0x0031 }, + { 5676, 0x1794 }, { 5683, 0x8221 }, { 5687, 0x0019 }, { 5690, 0x1054 }, + { 5694, 0x2cb2 }, { 5701, 0x021a }, { 5705, 0x9c02 }, { 5710, 0x4003 }, + { 5713, 0x3d60 }, { 5720, 0x8804 }, { 5723, 0x080c }, { 5726, 0x7900 }, + /* 0x8f00 */ + { 5731, 0x1628 }, { 5736, 0xba3c }, { 5745, 0x8640 }, { 5749, 0xcb08 }, + { 5755, 0x7274 }, { 5763, 0x9080 }, { 5766, 0x001e }, { 5770, 0x0000 }, + { 5770, 0x0000 }, { 5770, 0xd800 }, { 5774, 0xe188 }, { 5780, 0x9c87 }, + { 5788, 0x4034 }, { 5792, 0x0412 }, { 5795, 0xae64 }, { 5803, 0x2791 }, + /* 0x9000 */ + { 5810, 0xe86b }, { 5819, 0xe6fb }, { 5831, 0x408f }, { 5837, 0x5366 }, + { 5845, 0xeea6 }, { 5855, 0x537f }, { 5866, 0xe32b }, { 5875, 0xb5e4 }, + { 5884, 0x869f }, { 5893, 0x0002 }, { 5894, 0x8548 }, { 5899, 0x0122 }, + { 5902, 0x4402 }, { 5905, 0x0800 }, { 5906, 0x2116 }, { 5911, 0x20a0 }, + /* 0x9100 */ + { 5914, 0x0004 }, { 5915, 0x0204 }, { 5917, 0x2000 }, { 5918, 0x0005 }, + { 5920, 0x7e00 }, { 5926, 0x0154 }, { 5930, 0x162c }, { 5936, 0x01ac }, + { 5941, 0x2a84 }, { 5946, 0x1085 }, { 5950, 0x8c14 }, { 5955, 0x0530 }, + { 5959, 0xfbc3 }, { 5970, 0xb943 }, { 5978, 0x00ca }, { 5982, 0x9060 }, + /* 0x9200 */ + { 5986, 0x6000 }, { 5988, 0x4032 }, { 5992, 0x1200 }, { 5994, 0x8090 }, + { 5997, 0x0b30 }, { 6002, 0x4c81 }, { 6007, 0x0054 }, { 6010, 0x4002 }, + { 6012, 0x0029 }, { 6015, 0x1d6a }, { 6023, 0x2000 }, { 6024, 0x0280 }, + { 6026, 0x8000 }, { 6027, 0x0004 }, { 6028, 0x2610 }, { 6032, 0x150c }, + /* 0x9300 */ + { 6037, 0x8040 }, { 6039, 0x0701 }, { 6043, 0xd94d }, { 6052, 0x0c24 }, + { 6056, 0x2810 }, { 6059, 0x1850 }, { 6063, 0x5001 }, { 6066, 0x5020 }, + { 6069, 0x1000 }, { 6070, 0x04d0 }, { 6074, 0x7080 }, { 6078, 0x0201 }, + { 6080, 0x0108 }, { 6082, 0x21c3 }, { 6088, 0x0132 }, { 6092, 0x0000 }, + /* 0x9400 */ + { 6092, 0x0088 }, { 6094, 0x0719 }, { 6100, 0x0802 }, { 6102, 0x0560 }, + { 6106, 0x0012 }, { 6108, 0x4c0e }, { 6114, 0x0405 }, { 6117, 0xf0a1 }, + { 6124, 0x0002 }, { 6125, 0x0000 }, { 6125, 0x0000 }, { 6125, 0x0000 }, + { 6125, 0x0000 }, { 6125, 0x0000 }, { 6125, 0x0000 }, { 6125, 0x0000 }, + /* 0x9500 */ + { 6125, 0x0000 }, { 6125, 0x0000 }, { 6125, 0x0000 }, { 6125, 0x0000 }, + { 6125, 0x0000 }, { 6125, 0x0000 }, { 6125, 0x0000 }, { 6125, 0x0080 }, + { 6126, 0x8e8d }, { 6134, 0x035a }, { 6140, 0x21bd }, { 6148, 0x5a04 }, + { 6153, 0x3488 }, { 6158, 0x1170 }, { 6163, 0x0026 }, { 6166, 0x0000 }, + /* 0x9600 */ + { 6166, 0x0000 }, { 6166, 0x1000 }, { 6167, 0xc502 }, { 6172, 0x8804 }, + { 6175, 0xb815 }, { 6182, 0xf801 }, { 6188, 0x147c }, { 6195, 0x25ed }, + { 6204, 0xed60 }, { 6212, 0x1bb0 }, { 6219, 0x0589 }, { 6224, 0x1bd7 }, + { 6234, 0x7af3 }, { 6245, 0x1a62 }, { 6251, 0x0d0c }, { 6256, 0x0ac5 }, + /* 0x9700 */ + { 6262, 0xe5d1 }, { 6271, 0x524a }, { 6277, 0x0490 }, { 6280, 0x6305 }, + { 6286, 0x0354 }, { 6291, 0x5244 }, { 6296, 0x2b57 }, { 6305, 0x1612 }, + { 6310, 0xa872 }, { 6317, 0x1101 }, { 6320, 0x2949 }, { 6326, 0x0018 }, + { 6328, 0x0948 }, { 6332, 0x1008 }, { 6334, 0x6000 }, { 6336, 0x886c }, + /* 0x9800 */ + { 6342, 0x916e }, { 6350, 0x058f }, { 6357, 0x3012 }, { 6361, 0x3990 }, + { 6367, 0xf840 }, { 6373, 0x4930 }, { 6378, 0x8880 }, { 6381, 0x001b }, + { 6385, 0x0000 }, { 6385, 0x0000 }, { 6385, 0x8500 }, { 6388, 0x0042 }, + { 6390, 0x0058 }, { 6393, 0x9800 }, { 6396, 0xea04 }, { 6402, 0x7014 }, + /* 0x9900 */ + { 6407, 0x1628 }, { 6412, 0x611d }, { 6419, 0x5113 }, { 6425, 0x6000 }, + { 6427, 0x1a24 }, { 6432, 0x00a7 }, { 6437, 0x0000 }, { 6437, 0x0000 }, + { 6437, 0x0000 }, { 6437, 0x03c0 }, { 6441, 0x7120 }, { 6446, 0x1018 }, + { 6449, 0x0172 }, { 6454, 0xa927 }, { 6462, 0x6004 }, { 6465, 0x8906 }, + /* 0x9a00 */ + { 6470, 0xc022 }, { 6474, 0x020c }, { 6477, 0x0900 }, { 6479, 0x4081 }, + { 6482, 0x202d }, { 6487, 0x8ca0 }, { 6492, 0x0e34 }, { 6498, 0x0000 }, + { 6498, 0x0000 }, { 6498, 0x0000 }, { 6498, 0x2100 }, { 6500, 0x1101 }, + { 6503, 0x8011 }, { 6506, 0xc11a }, { 6512, 0xec4c }, { 6520, 0x0892 }, + /* 0x9b00 */ + { 6524, 0x0040 }, { 6525, 0x8500 }, { 6528, 0xc7ac }, { 6537, 0x1806 }, + { 6541, 0xe03e }, { 6549, 0x0512 }, { 6553, 0x8000 }, { 6554, 0x0010 }, + { 6555, 0x4008 }, { 6557, 0x80ce }, { 6563, 0x6d01 }, { 6569, 0x0210 }, + { 6571, 0x8641 }, { 6576, 0x0856 }, { 6581, 0x011e }, { 6586, 0x0027 }, + /* 0x9c00 */ + { 6590, 0x3750 }, { 6597, 0x083d }, { 6603, 0xe032 }, { 6609, 0x4e05 }, + { 6615, 0x01c0 }, { 6618, 0x0484 }, { 6621, 0x0081 }, { 6623, 0x0140 }, + { 6625, 0x0000 }, { 6625, 0x0000 }, { 6625, 0x0000 }, { 6625, 0x0000 }, + { 6625, 0x0000 }, { 6625, 0x0000 }, { 6625, 0x1aa0 }, { 6630, 0x0059 }, + /* 0x9d00 */ + { 6634, 0x43c8 }, { 6640, 0x8824 }, { 6644, 0x1d48 }, { 6650, 0xc800 }, + { 6653, 0x0152 }, { 6657, 0x7203 }, { 6663, 0x9013 }, { 6668, 0x0404 }, + { 6670, 0x8280 }, { 6673, 0x0400 }, { 6674, 0x8a10 }, { 6678, 0x0d14 }, + { 6683, 0x8056 }, { 6688, 0x0208 }, { 6690, 0xa040 }, { 6693, 0x2704 }, + /* 0x9e00 */ + { 6698, 0x0000 }, { 6698, 0x4c00 }, { 6701, 0x0000 }, { 6701, 0x0000 }, + { 6701, 0x0000 }, { 6701, 0x0000 }, { 6701, 0x0000 }, { 6701, 0xa320 }, + { 6706, 0x1902 }, { 6710, 0xa0ae }, { 6717, 0x2660 }, { 6722, 0xdf00 }, + { 6729, 0xf010 }, { 6734, 0x7b15 }, { 6743, 0x8121 }, { 6747, 0x3ad0 }, + /* 0x9f00 */ + { 6754, 0x4180 }, { 6757, 0x0028 }, { 6759, 0x1003 }, { 6762, 0x4800 }, + { 6764, 0xcc00 }, { 6768, 0x8014 }, { 6771, 0x14cf }, { 6779, 0x00c4 }, + { 6782, 0x2000 }, { 6783, 0x3020 }, { 6786, 0x0001 }, +}; +static const Summary16 jisx0208_uni2indx_pageff[15] = { + /* 0xff00 */ + { 6787, 0xdf7a }, { 6799, 0xffff }, { 6815, 0xffff }, { 6831, 0xffff }, + { 6847, 0xffff }, { 6863, 0x3fff }, { 6877, 0x0000 }, { 6877, 0x0000 }, + { 6877, 0x0000 }, { 6877, 0x0000 }, { 6877, 0x0000 }, { 6877, 0x0000 }, + { 6877, 0x0000 }, { 6877, 0x0000 }, { 6877, 0x0028 }, +}; + +static int +jisx0208_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc >= 0x0000 && wc < 0x0100) + summary = &jisx0208_uni2indx_page00[(wc>>4)]; + else if (wc >= 0x0300 && wc < 0x0460) + summary = &jisx0208_uni2indx_page03[(wc>>4)-0x030]; + else if (wc >= 0x2000 && wc < 0x2320) + summary = &jisx0208_uni2indx_page20[(wc>>4)-0x200]; + else if (wc >= 0x2500 && wc < 0x2670) + summary = &jisx0208_uni2indx_page25[(wc>>4)-0x250]; + else if (wc >= 0x3000 && wc < 0x3100) + summary = &jisx0208_uni2indx_page30[(wc>>4)-0x300]; + else if (wc >= 0x4e00 && wc < 0x9fb0) + summary = &jisx0208_uni2indx_page4e[(wc>>4)-0x4e0]; + else if (wc >= 0xff00 && wc < 0xfff0) + summary = &jisx0208_uni2indx_pageff[(wc>>4)-0xff0]; + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = jisx0208_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/jisx0212.h b/graf2d/win32gdk/gdk/src/iconv/jisx0212.h new file mode 100644 index 0000000000000..371dbb152ccfe --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/jisx0212.h @@ -0,0 +1,2189 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * JISX0212.1990-0 + */ + +static const unsigned short jisx0212_2uni_page22[81] = { + /* 0x22 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x02d8, 0x02c7, + 0x00b8, 0x02d9, 0x02dd, 0x00af, 0x02db, 0x02da, 0xff5e, 0x0384, + 0x0385, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x00a1, 0x00a6, 0x00bf, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0x00ba, 0x00aa, 0x00a9, 0x00ae, 0x2122, 0x00a4, + 0x2116, +}; +static const unsigned short jisx0212_2uni_page26[188] = { + /* 0x26 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x0386, 0x0388, 0x0389, 0x038a, 0x03aa, 0xfffd, 0x038c, 0xfffd, + 0x038e, 0x03ab, 0xfffd, 0x038f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x03ac, 0x03ad, 0x03ae, 0x03af, 0x03ca, 0x0390, 0x03cc, 0x03c2, + 0x03cd, 0x03cb, 0x03b0, 0x03ce, 0xfffd, 0xfffd, + /* 0x27 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x0402, 0x0403, 0x0404, 0x0405, 0x0406, 0x0407, 0x0408, + 0x0409, 0x040a, 0x040b, 0x040c, 0x040e, 0x040f, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0x0452, 0x0453, 0x0454, 0x0455, 0x0456, 0x0457, 0x0458, + 0x0459, 0x045a, 0x045b, 0x045c, 0x045e, 0x045f, +}; +static const unsigned short jisx0212_2uni_page29[275] = { + /* 0x29 */ + 0x00c6, 0x0110, 0xfffd, 0x0126, 0xfffd, 0x0132, 0xfffd, 0x0141, + 0x013f, 0xfffd, 0x014a, 0x00d8, 0x0152, 0xfffd, 0x0166, 0x00de, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x00e6, 0x0111, 0x00f0, 0x0127, 0x0131, 0x0133, 0x0138, 0x0142, + 0x0140, 0x0149, 0x014b, 0x00f8, 0x0153, 0x00df, 0x0167, 0x00fe, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x2a */ + 0x00c1, 0x00c0, 0x00c4, 0x00c2, 0x0102, 0x01cd, 0x0100, 0x0104, + 0x00c5, 0x00c3, 0x0106, 0x0108, 0x010c, 0x00c7, 0x010a, 0x010e, + 0x00c9, 0x00c8, 0x00cb, 0x00ca, 0x011a, 0x0116, 0x0112, 0x0118, + 0xfffd, 0x011c, 0x011e, 0x0122, 0x0120, 0x0124, 0x00cd, 0x00cc, + 0x00cf, 0x00ce, 0x01cf, 0x0130, 0x012a, 0x012e, 0x0128, 0x0134, + 0x0136, 0x0139, 0x013d, 0x013b, 0x0143, 0x0147, 0x0145, 0x00d1, + 0x00d3, 0x00d2, 0x00d6, 0x00d4, 0x01d1, 0x0150, 0x014c, 0x00d5, + 0x0154, 0x0158, 0x0156, 0x015a, 0x015c, 0x0160, 0x015e, 0x0164, + 0x0162, 0x00da, 0x00d9, 0x00dc, 0x00db, 0x016c, 0x01d3, 0x0170, + 0x016a, 0x0172, 0x016e, 0x0168, 0x01d7, 0x01db, 0x01d9, 0x01d5, + 0x0174, 0x00dd, 0x0178, 0x0176, 0x0179, 0x017d, 0x017b, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x2b */ + 0x00e1, 0x00e0, 0x00e4, 0x00e2, 0x0103, 0x01ce, 0x0101, 0x0105, + 0x00e5, 0x00e3, 0x0107, 0x0109, 0x010d, 0x00e7, 0x010b, 0x010f, + 0x00e9, 0x00e8, 0x00eb, 0x00ea, 0x011b, 0x0117, 0x0113, 0x0119, + 0x01f5, 0x011d, 0x011f, 0xfffd, 0x0121, 0x0125, 0x00ed, 0x00ec, + 0x00ef, 0x00ee, 0x01d0, 0xfffd, 0x012b, 0x012f, 0x0129, 0x0135, + 0x0137, 0x013a, 0x013e, 0x013c, 0x0144, 0x0148, 0x0146, 0x00f1, + 0x00f3, 0x00f2, 0x00f6, 0x00f4, 0x01d2, 0x0151, 0x014d, 0x00f5, + 0x0155, 0x0159, 0x0157, 0x015b, 0x015d, 0x0161, 0x015f, 0x0165, + 0x0163, 0x00fa, 0x00f9, 0x00fc, 0x00fb, 0x016d, 0x01d4, 0x0171, + 0x016b, 0x0173, 0x016f, 0x0169, 0x01d8, 0x01dc, 0x01da, 0x01d6, + 0x0175, 0x00fd, 0x00ff, 0x0177, 0x017a, 0x017e, 0x017c, +}; +static const unsigned short jisx0212_2uni_page30[5801] = { + /* 0x30 */ + 0x4e02, 0x4e04, 0x4e05, 0x4e0c, 0x4e12, 0x4e1f, 0x4e23, 0x4e24, + 0x4e28, 0x4e2b, 0x4e2e, 0x4e2f, 0x4e30, 0x4e35, 0x4e40, 0x4e41, + 0x4e44, 0x4e47, 0x4e51, 0x4e5a, 0x4e5c, 0x4e63, 0x4e68, 0x4e69, + 0x4e74, 0x4e75, 0x4e79, 0x4e7f, 0x4e8d, 0x4e96, 0x4e97, 0x4e9d, + 0x4eaf, 0x4eb9, 0x4ec3, 0x4ed0, 0x4eda, 0x4edb, 0x4ee0, 0x4ee1, + 0x4ee2, 0x4ee8, 0x4eef, 0x4ef1, 0x4ef3, 0x4ef5, 0x4efd, 0x4efe, + 0x4eff, 0x4f00, 0x4f02, 0x4f03, 0x4f08, 0x4f0b, 0x4f0c, 0x4f12, + 0x4f15, 0x4f16, 0x4f17, 0x4f19, 0x4f2e, 0x4f31, 0x4f60, 0x4f33, + 0x4f35, 0x4f37, 0x4f39, 0x4f3b, 0x4f3e, 0x4f40, 0x4f42, 0x4f48, + 0x4f49, 0x4f4b, 0x4f4c, 0x4f52, 0x4f54, 0x4f56, 0x4f58, 0x4f5f, + 0x4f63, 0x4f6a, 0x4f6c, 0x4f6e, 0x4f71, 0x4f77, 0x4f78, 0x4f79, + 0x4f7a, 0x4f7d, 0x4f7e, 0x4f81, 0x4f82, 0x4f84, + /* 0x31 */ + 0x4f85, 0x4f89, 0x4f8a, 0x4f8c, 0x4f8e, 0x4f90, 0x4f92, 0x4f93, + 0x4f94, 0x4f97, 0x4f99, 0x4f9a, 0x4f9e, 0x4f9f, 0x4fb2, 0x4fb7, + 0x4fb9, 0x4fbb, 0x4fbc, 0x4fbd, 0x4fbe, 0x4fc0, 0x4fc1, 0x4fc5, + 0x4fc6, 0x4fc8, 0x4fc9, 0x4fcb, 0x4fcc, 0x4fcd, 0x4fcf, 0x4fd2, + 0x4fdc, 0x4fe0, 0x4fe2, 0x4ff0, 0x4ff2, 0x4ffc, 0x4ffd, 0x4fff, + 0x5000, 0x5001, 0x5004, 0x5007, 0x500a, 0x500c, 0x500e, 0x5010, + 0x5013, 0x5017, 0x5018, 0x501b, 0x501c, 0x501d, 0x501e, 0x5022, + 0x5027, 0x502e, 0x5030, 0x5032, 0x5033, 0x5035, 0x5040, 0x5041, + 0x5042, 0x5045, 0x5046, 0x504a, 0x504c, 0x504e, 0x5051, 0x5052, + 0x5053, 0x5057, 0x5059, 0x505f, 0x5060, 0x5062, 0x5063, 0x5066, + 0x5067, 0x506a, 0x506d, 0x5070, 0x5071, 0x503b, 0x5081, 0x5083, + 0x5084, 0x5086, 0x508a, 0x508e, 0x508f, 0x5090, + /* 0x32 */ + 0x5092, 0x5093, 0x5094, 0x5096, 0x509b, 0x509c, 0x509e, 0x509f, + 0x50a0, 0x50a1, 0x50a2, 0x50aa, 0x50af, 0x50b0, 0x50b9, 0x50ba, + 0x50bd, 0x50c0, 0x50c3, 0x50c4, 0x50c7, 0x50cc, 0x50ce, 0x50d0, + 0x50d3, 0x50d4, 0x50d8, 0x50dc, 0x50dd, 0x50df, 0x50e2, 0x50e4, + 0x50e6, 0x50e8, 0x50e9, 0x50ef, 0x50f1, 0x50f6, 0x50fa, 0x50fe, + 0x5103, 0x5106, 0x5107, 0x5108, 0x510b, 0x510c, 0x510d, 0x510e, + 0x50f2, 0x5110, 0x5117, 0x5119, 0x511b, 0x511c, 0x511d, 0x511e, + 0x5123, 0x5127, 0x5128, 0x512c, 0x512d, 0x512f, 0x5131, 0x5133, + 0x5134, 0x5135, 0x5138, 0x5139, 0x5142, 0x514a, 0x514f, 0x5153, + 0x5155, 0x5157, 0x5158, 0x515f, 0x5164, 0x5166, 0x517e, 0x5183, + 0x5184, 0x518b, 0x518e, 0x5198, 0x519d, 0x51a1, 0x51a3, 0x51ad, + 0x51b8, 0x51ba, 0x51bc, 0x51be, 0x51bf, 0x51c2, + /* 0x33 */ + 0x51c8, 0x51cf, 0x51d1, 0x51d2, 0x51d3, 0x51d5, 0x51d8, 0x51de, + 0x51e2, 0x51e5, 0x51ee, 0x51f2, 0x51f3, 0x51f4, 0x51f7, 0x5201, + 0x5202, 0x5205, 0x5212, 0x5213, 0x5215, 0x5216, 0x5218, 0x5222, + 0x5228, 0x5231, 0x5232, 0x5235, 0x523c, 0x5245, 0x5249, 0x5255, + 0x5257, 0x5258, 0x525a, 0x525c, 0x525f, 0x5260, 0x5261, 0x5266, + 0x526e, 0x5277, 0x5278, 0x5279, 0x5280, 0x5282, 0x5285, 0x528a, + 0x528c, 0x5293, 0x5295, 0x5296, 0x5297, 0x5298, 0x529a, 0x529c, + 0x52a4, 0x52a5, 0x52a6, 0x52a7, 0x52af, 0x52b0, 0x52b6, 0x52b7, + 0x52b8, 0x52ba, 0x52bb, 0x52bd, 0x52c0, 0x52c4, 0x52c6, 0x52c8, + 0x52cc, 0x52cf, 0x52d1, 0x52d4, 0x52d6, 0x52db, 0x52dc, 0x52e1, + 0x52e5, 0x52e8, 0x52e9, 0x52ea, 0x52ec, 0x52f0, 0x52f1, 0x52f4, + 0x52f6, 0x52f7, 0x5300, 0x5303, 0x530a, 0x530b, + /* 0x34 */ + 0x530c, 0x5311, 0x5313, 0x5318, 0x531b, 0x531c, 0x531e, 0x531f, + 0x5325, 0x5327, 0x5328, 0x5329, 0x532b, 0x532c, 0x532d, 0x5330, + 0x5332, 0x5335, 0x533c, 0x533d, 0x533e, 0x5342, 0x534c, 0x534b, + 0x5359, 0x535b, 0x5361, 0x5363, 0x5365, 0x536c, 0x536d, 0x5372, + 0x5379, 0x537e, 0x5383, 0x5387, 0x5388, 0x538e, 0x5393, 0x5394, + 0x5399, 0x539d, 0x53a1, 0x53a4, 0x53aa, 0x53ab, 0x53af, 0x53b2, + 0x53b4, 0x53b5, 0x53b7, 0x53b8, 0x53ba, 0x53bd, 0x53c0, 0x53c5, + 0x53cf, 0x53d2, 0x53d3, 0x53d5, 0x53da, 0x53dd, 0x53de, 0x53e0, + 0x53e6, 0x53e7, 0x53f5, 0x5402, 0x5413, 0x541a, 0x5421, 0x5427, + 0x5428, 0x542a, 0x542f, 0x5431, 0x5434, 0x5435, 0x5443, 0x5444, + 0x5447, 0x544d, 0x544f, 0x545e, 0x5462, 0x5464, 0x5466, 0x5467, + 0x5469, 0x546b, 0x546d, 0x546e, 0x5474, 0x547f, + /* 0x35 */ + 0x5481, 0x5483, 0x5485, 0x5488, 0x5489, 0x548d, 0x5491, 0x5495, + 0x5496, 0x549c, 0x549f, 0x54a1, 0x54a6, 0x54a7, 0x54a9, 0x54aa, + 0x54ad, 0x54ae, 0x54b1, 0x54b7, 0x54b9, 0x54ba, 0x54bb, 0x54bf, + 0x54c6, 0x54ca, 0x54cd, 0x54ce, 0x54e0, 0x54ea, 0x54ec, 0x54ef, + 0x54f6, 0x54fc, 0x54fe, 0x54ff, 0x5500, 0x5501, 0x5505, 0x5508, + 0x5509, 0x550c, 0x550d, 0x550e, 0x5515, 0x552a, 0x552b, 0x5532, + 0x5535, 0x5536, 0x553b, 0x553c, 0x553d, 0x5541, 0x5547, 0x5549, + 0x554a, 0x554d, 0x5550, 0x5551, 0x5558, 0x555a, 0x555b, 0x555e, + 0x5560, 0x5561, 0x5564, 0x5566, 0x557f, 0x5581, 0x5582, 0x5586, + 0x5588, 0x558e, 0x558f, 0x5591, 0x5592, 0x5593, 0x5594, 0x5597, + 0x55a3, 0x55a4, 0x55ad, 0x55b2, 0x55bf, 0x55c1, 0x55c3, 0x55c6, + 0x55c9, 0x55cb, 0x55cc, 0x55ce, 0x55d1, 0x55d2, + /* 0x36 */ + 0x55d3, 0x55d7, 0x55d8, 0x55db, 0x55de, 0x55e2, 0x55e9, 0x55f6, + 0x55ff, 0x5605, 0x5608, 0x560a, 0x560d, 0x560e, 0x560f, 0x5610, + 0x5611, 0x5612, 0x5619, 0x562c, 0x5630, 0x5633, 0x5635, 0x5637, + 0x5639, 0x563b, 0x563c, 0x563d, 0x563f, 0x5640, 0x5641, 0x5643, + 0x5644, 0x5646, 0x5649, 0x564b, 0x564d, 0x564f, 0x5654, 0x565e, + 0x5660, 0x5661, 0x5662, 0x5663, 0x5666, 0x5669, 0x566d, 0x566f, + 0x5671, 0x5672, 0x5675, 0x5684, 0x5685, 0x5688, 0x568b, 0x568c, + 0x5695, 0x5699, 0x569a, 0x569d, 0x569e, 0x569f, 0x56a6, 0x56a7, + 0x56a8, 0x56a9, 0x56ab, 0x56ac, 0x56ad, 0x56b1, 0x56b3, 0x56b7, + 0x56be, 0x56c5, 0x56c9, 0x56ca, 0x56cb, 0x56cf, 0x56d0, 0x56cc, + 0x56cd, 0x56d9, 0x56dc, 0x56dd, 0x56df, 0x56e1, 0x56e4, 0x56e5, + 0x56e6, 0x56e7, 0x56e8, 0x56f1, 0x56eb, 0x56ed, + /* 0x37 */ + 0x56f6, 0x56f7, 0x5701, 0x5702, 0x5707, 0x570a, 0x570c, 0x5711, + 0x5715, 0x571a, 0x571b, 0x571d, 0x5720, 0x5722, 0x5723, 0x5724, + 0x5725, 0x5729, 0x572a, 0x572c, 0x572e, 0x572f, 0x5733, 0x5734, + 0x573d, 0x573e, 0x573f, 0x5745, 0x5746, 0x574c, 0x574d, 0x5752, + 0x5762, 0x5765, 0x5767, 0x5768, 0x576b, 0x576d, 0x576e, 0x576f, + 0x5770, 0x5771, 0x5773, 0x5774, 0x5775, 0x5777, 0x5779, 0x577a, + 0x577b, 0x577c, 0x577e, 0x5781, 0x5783, 0x578c, 0x5794, 0x5797, + 0x5799, 0x579a, 0x579c, 0x579d, 0x579e, 0x579f, 0x57a1, 0x5795, + 0x57a7, 0x57a8, 0x57a9, 0x57ac, 0x57b8, 0x57bd, 0x57c7, 0x57c8, + 0x57cc, 0x57cf, 0x57d5, 0x57dd, 0x57de, 0x57e4, 0x57e6, 0x57e7, + 0x57e9, 0x57ed, 0x57f0, 0x57f5, 0x57f6, 0x57f8, 0x57fd, 0x57fe, + 0x57ff, 0x5803, 0x5804, 0x5808, 0x5809, 0x57e1, + /* 0x38 */ + 0x580c, 0x580d, 0x581b, 0x581e, 0x581f, 0x5820, 0x5826, 0x5827, + 0x582d, 0x5832, 0x5839, 0x583f, 0x5849, 0x584c, 0x584d, 0x584f, + 0x5850, 0x5855, 0x585f, 0x5861, 0x5864, 0x5867, 0x5868, 0x5878, + 0x587c, 0x587f, 0x5880, 0x5881, 0x5887, 0x5888, 0x5889, 0x588a, + 0x588c, 0x588d, 0x588f, 0x5890, 0x5894, 0x5896, 0x589d, 0x58a0, + 0x58a1, 0x58a2, 0x58a6, 0x58a9, 0x58b1, 0x58b2, 0x58c4, 0x58bc, + 0x58c2, 0x58c8, 0x58cd, 0x58ce, 0x58d0, 0x58d2, 0x58d4, 0x58d6, + 0x58da, 0x58dd, 0x58e1, 0x58e2, 0x58e9, 0x58f3, 0x5905, 0x5906, + 0x590b, 0x590c, 0x5912, 0x5913, 0x5914, 0x8641, 0x591d, 0x5921, + 0x5923, 0x5924, 0x5928, 0x592f, 0x5930, 0x5933, 0x5935, 0x5936, + 0x593f, 0x5943, 0x5946, 0x5952, 0x5953, 0x5959, 0x595b, 0x595d, + 0x595e, 0x595f, 0x5961, 0x5963, 0x596b, 0x596d, + /* 0x39 */ + 0x596f, 0x5972, 0x5975, 0x5976, 0x5979, 0x597b, 0x597c, 0x598b, + 0x598c, 0x598e, 0x5992, 0x5995, 0x5997, 0x599f, 0x59a4, 0x59a7, + 0x59ad, 0x59ae, 0x59af, 0x59b0, 0x59b3, 0x59b7, 0x59ba, 0x59bc, + 0x59c1, 0x59c3, 0x59c4, 0x59c8, 0x59ca, 0x59cd, 0x59d2, 0x59dd, + 0x59de, 0x59df, 0x59e3, 0x59e4, 0x59e7, 0x59ee, 0x59ef, 0x59f1, + 0x59f2, 0x59f4, 0x59f7, 0x5a00, 0x5a04, 0x5a0c, 0x5a0d, 0x5a0e, + 0x5a12, 0x5a13, 0x5a1e, 0x5a23, 0x5a24, 0x5a27, 0x5a28, 0x5a2a, + 0x5a2d, 0x5a30, 0x5a44, 0x5a45, 0x5a47, 0x5a48, 0x5a4c, 0x5a50, + 0x5a55, 0x5a5e, 0x5a63, 0x5a65, 0x5a67, 0x5a6d, 0x5a77, 0x5a7a, + 0x5a7b, 0x5a7e, 0x5a8b, 0x5a90, 0x5a93, 0x5a96, 0x5a99, 0x5a9c, + 0x5a9e, 0x5a9f, 0x5aa0, 0x5aa2, 0x5aa7, 0x5aac, 0x5ab1, 0x5ab2, + 0x5ab3, 0x5ab5, 0x5ab8, 0x5aba, 0x5abb, 0x5abf, + /* 0x3a */ + 0x5ac4, 0x5ac6, 0x5ac8, 0x5acf, 0x5ada, 0x5adc, 0x5ae0, 0x5ae5, + 0x5aea, 0x5aee, 0x5af5, 0x5af6, 0x5afd, 0x5b00, 0x5b01, 0x5b08, + 0x5b17, 0x5b34, 0x5b19, 0x5b1b, 0x5b1d, 0x5b21, 0x5b25, 0x5b2d, + 0x5b38, 0x5b41, 0x5b4b, 0x5b4c, 0x5b52, 0x5b56, 0x5b5e, 0x5b68, + 0x5b6e, 0x5b6f, 0x5b7c, 0x5b7d, 0x5b7e, 0x5b7f, 0x5b81, 0x5b84, + 0x5b86, 0x5b8a, 0x5b8e, 0x5b90, 0x5b91, 0x5b93, 0x5b94, 0x5b96, + 0x5ba8, 0x5ba9, 0x5bac, 0x5bad, 0x5baf, 0x5bb1, 0x5bb2, 0x5bb7, + 0x5bba, 0x5bbc, 0x5bc0, 0x5bc1, 0x5bcd, 0x5bcf, 0x5bd6, 0x5bd7, + 0x5bd8, 0x5bd9, 0x5bda, 0x5be0, 0x5bef, 0x5bf1, 0x5bf4, 0x5bfd, + 0x5c0c, 0x5c17, 0x5c1e, 0x5c1f, 0x5c23, 0x5c26, 0x5c29, 0x5c2b, + 0x5c2c, 0x5c2e, 0x5c30, 0x5c32, 0x5c35, 0x5c36, 0x5c59, 0x5c5a, + 0x5c5c, 0x5c62, 0x5c63, 0x5c67, 0x5c68, 0x5c69, + /* 0x3b */ + 0x5c6d, 0x5c70, 0x5c74, 0x5c75, 0x5c7a, 0x5c7b, 0x5c7c, 0x5c7d, + 0x5c87, 0x5c88, 0x5c8a, 0x5c8f, 0x5c92, 0x5c9d, 0x5c9f, 0x5ca0, + 0x5ca2, 0x5ca3, 0x5ca6, 0x5caa, 0x5cb2, 0x5cb4, 0x5cb5, 0x5cba, + 0x5cc9, 0x5ccb, 0x5cd2, 0x5cdd, 0x5cd7, 0x5cee, 0x5cf1, 0x5cf2, + 0x5cf4, 0x5d01, 0x5d06, 0x5d0d, 0x5d12, 0x5d2b, 0x5d23, 0x5d24, + 0x5d26, 0x5d27, 0x5d31, 0x5d34, 0x5d39, 0x5d3d, 0x5d3f, 0x5d42, + 0x5d43, 0x5d46, 0x5d48, 0x5d55, 0x5d51, 0x5d59, 0x5d4a, 0x5d5f, + 0x5d60, 0x5d61, 0x5d62, 0x5d64, 0x5d6a, 0x5d6d, 0x5d70, 0x5d79, + 0x5d7a, 0x5d7e, 0x5d7f, 0x5d81, 0x5d83, 0x5d88, 0x5d8a, 0x5d92, + 0x5d93, 0x5d94, 0x5d95, 0x5d99, 0x5d9b, 0x5d9f, 0x5da0, 0x5da7, + 0x5dab, 0x5db0, 0x5db4, 0x5db8, 0x5db9, 0x5dc3, 0x5dc7, 0x5dcb, + 0x5dd0, 0x5dce, 0x5dd8, 0x5dd9, 0x5de0, 0x5de4, + /* 0x3c */ + 0x5de9, 0x5df8, 0x5df9, 0x5e00, 0x5e07, 0x5e0d, 0x5e12, 0x5e14, + 0x5e15, 0x5e18, 0x5e1f, 0x5e20, 0x5e2e, 0x5e28, 0x5e32, 0x5e35, + 0x5e3e, 0x5e4b, 0x5e50, 0x5e49, 0x5e51, 0x5e56, 0x5e58, 0x5e5b, + 0x5e5c, 0x5e5e, 0x5e68, 0x5e6a, 0x5e6b, 0x5e6c, 0x5e6d, 0x5e6e, + 0x5e70, 0x5e80, 0x5e8b, 0x5e8e, 0x5ea2, 0x5ea4, 0x5ea5, 0x5ea8, + 0x5eaa, 0x5eac, 0x5eb1, 0x5eb3, 0x5ebd, 0x5ebe, 0x5ebf, 0x5ec6, + 0x5ecc, 0x5ecb, 0x5ece, 0x5ed1, 0x5ed2, 0x5ed4, 0x5ed5, 0x5edc, + 0x5ede, 0x5ee5, 0x5eeb, 0x5f02, 0x5f06, 0x5f07, 0x5f08, 0x5f0e, + 0x5f19, 0x5f1c, 0x5f1d, 0x5f21, 0x5f22, 0x5f23, 0x5f24, 0x5f28, + 0x5f2b, 0x5f2c, 0x5f2e, 0x5f30, 0x5f34, 0x5f36, 0x5f3b, 0x5f3d, + 0x5f3f, 0x5f40, 0x5f44, 0x5f45, 0x5f47, 0x5f4d, 0x5f50, 0x5f54, + 0x5f58, 0x5f5b, 0x5f60, 0x5f63, 0x5f64, 0x5f67, + /* 0x3d */ + 0x5f6f, 0x5f72, 0x5f74, 0x5f75, 0x5f78, 0x5f7a, 0x5f7d, 0x5f7e, + 0x5f89, 0x5f8d, 0x5f8f, 0x5f96, 0x5f9c, 0x5f9d, 0x5fa2, 0x5fa7, + 0x5fab, 0x5fa4, 0x5fac, 0x5faf, 0x5fb0, 0x5fb1, 0x5fb8, 0x5fc4, + 0x5fc7, 0x5fc8, 0x5fc9, 0x5fcb, 0x5fd0, 0x5fd1, 0x5fd2, 0x5fd3, + 0x5fd4, 0x5fde, 0x5fe1, 0x5fe2, 0x5fe8, 0x5fe9, 0x5fea, 0x5fec, + 0x5fed, 0x5fee, 0x5fef, 0x5ff2, 0x5ff3, 0x5ff6, 0x5ffa, 0x5ffc, + 0x6007, 0x600a, 0x600d, 0x6013, 0x6014, 0x6017, 0x6018, 0x601a, + 0x601f, 0x6024, 0x602d, 0x6033, 0x6035, 0x6040, 0x6047, 0x6048, + 0x6049, 0x604c, 0x6051, 0x6054, 0x6056, 0x6057, 0x605d, 0x6061, + 0x6067, 0x6071, 0x607e, 0x607f, 0x6082, 0x6086, 0x6088, 0x608a, + 0x608e, 0x6091, 0x6093, 0x6095, 0x6098, 0x609d, 0x609e, 0x60a2, + 0x60a4, 0x60a5, 0x60a8, 0x60b0, 0x60b1, 0x60b7, + /* 0x3e */ + 0x60bb, 0x60be, 0x60c2, 0x60c4, 0x60c8, 0x60c9, 0x60ca, 0x60cb, + 0x60ce, 0x60cf, 0x60d4, 0x60d5, 0x60d9, 0x60db, 0x60dd, 0x60de, + 0x60e2, 0x60e5, 0x60f2, 0x60f5, 0x60f8, 0x60fc, 0x60fd, 0x6102, + 0x6107, 0x610a, 0x610c, 0x6110, 0x6111, 0x6112, 0x6113, 0x6114, + 0x6116, 0x6117, 0x6119, 0x611c, 0x611e, 0x6122, 0x612a, 0x612b, + 0x6130, 0x6131, 0x6135, 0x6136, 0x6137, 0x6139, 0x6141, 0x6145, + 0x6146, 0x6149, 0x615e, 0x6160, 0x616c, 0x6172, 0x6178, 0x617b, + 0x617c, 0x617f, 0x6180, 0x6181, 0x6183, 0x6184, 0x618b, 0x618d, + 0x6192, 0x6193, 0x6197, 0x6198, 0x619c, 0x619d, 0x619f, 0x61a0, + 0x61a5, 0x61a8, 0x61aa, 0x61ad, 0x61b8, 0x61b9, 0x61bc, 0x61c0, + 0x61c1, 0x61c2, 0x61ce, 0x61cf, 0x61d5, 0x61dc, 0x61dd, 0x61de, + 0x61df, 0x61e1, 0x61e2, 0x61e7, 0x61e9, 0x61e5, + /* 0x3f */ + 0x61ec, 0x61ed, 0x61ef, 0x6201, 0x6203, 0x6204, 0x6207, 0x6213, + 0x6215, 0x621c, 0x6220, 0x6222, 0x6223, 0x6227, 0x6229, 0x622b, + 0x6239, 0x623d, 0x6242, 0x6243, 0x6244, 0x6246, 0x624c, 0x6250, + 0x6251, 0x6252, 0x6254, 0x6256, 0x625a, 0x625c, 0x6264, 0x626d, + 0x626f, 0x6273, 0x627a, 0x627d, 0x628d, 0x628e, 0x628f, 0x6290, + 0x62a6, 0x62a8, 0x62b3, 0x62b6, 0x62b7, 0x62ba, 0x62be, 0x62bf, + 0x62c4, 0x62ce, 0x62d5, 0x62d6, 0x62da, 0x62ea, 0x62f2, 0x62f4, + 0x62fc, 0x62fd, 0x6303, 0x6304, 0x630a, 0x630b, 0x630d, 0x6310, + 0x6313, 0x6316, 0x6318, 0x6329, 0x632a, 0x632d, 0x6335, 0x6336, + 0x6339, 0x633c, 0x6341, 0x6342, 0x6343, 0x6344, 0x6346, 0x634a, + 0x634b, 0x634e, 0x6352, 0x6353, 0x6354, 0x6358, 0x635b, 0x6365, + 0x6366, 0x636c, 0x636d, 0x6371, 0x6374, 0x6375, + /* 0x40 */ + 0x6378, 0x637c, 0x637d, 0x637f, 0x6382, 0x6384, 0x6387, 0x638a, + 0x6390, 0x6394, 0x6395, 0x6399, 0x639a, 0x639e, 0x63a4, 0x63a6, + 0x63ad, 0x63ae, 0x63af, 0x63bd, 0x63c1, 0x63c5, 0x63c8, 0x63ce, + 0x63d1, 0x63d3, 0x63d4, 0x63d5, 0x63dc, 0x63e0, 0x63e5, 0x63ea, + 0x63ec, 0x63f2, 0x63f3, 0x63f5, 0x63f8, 0x63f9, 0x6409, 0x640a, + 0x6410, 0x6412, 0x6414, 0x6418, 0x641e, 0x6420, 0x6422, 0x6424, + 0x6425, 0x6429, 0x642a, 0x642f, 0x6430, 0x6435, 0x643d, 0x643f, + 0x644b, 0x644f, 0x6451, 0x6452, 0x6453, 0x6454, 0x645a, 0x645b, + 0x645c, 0x645d, 0x645f, 0x6460, 0x6461, 0x6463, 0x646d, 0x6473, + 0x6474, 0x647b, 0x647d, 0x6485, 0x6487, 0x648f, 0x6490, 0x6491, + 0x6498, 0x6499, 0x649b, 0x649d, 0x649f, 0x64a1, 0x64a3, 0x64a6, + 0x64a8, 0x64ac, 0x64b3, 0x64bd, 0x64be, 0x64bf, + /* 0x41 */ + 0x64c4, 0x64c9, 0x64ca, 0x64cb, 0x64cc, 0x64ce, 0x64d0, 0x64d1, + 0x64d5, 0x64d7, 0x64e4, 0x64e5, 0x64e9, 0x64ea, 0x64ed, 0x64f0, + 0x64f5, 0x64f7, 0x64fb, 0x64ff, 0x6501, 0x6504, 0x6508, 0x6509, + 0x650a, 0x650f, 0x6513, 0x6514, 0x6516, 0x6519, 0x651b, 0x651e, + 0x651f, 0x6522, 0x6526, 0x6529, 0x652e, 0x6531, 0x653a, 0x653c, + 0x653d, 0x6543, 0x6547, 0x6549, 0x6550, 0x6552, 0x6554, 0x655f, + 0x6560, 0x6567, 0x656b, 0x657a, 0x657d, 0x6581, 0x6585, 0x658a, + 0x6592, 0x6595, 0x6598, 0x659d, 0x65a0, 0x65a3, 0x65a6, 0x65ae, + 0x65b2, 0x65b3, 0x65b4, 0x65bf, 0x65c2, 0x65c8, 0x65c9, 0x65ce, + 0x65d0, 0x65d4, 0x65d6, 0x65d8, 0x65df, 0x65f0, 0x65f2, 0x65f4, + 0x65f5, 0x65f9, 0x65fe, 0x65ff, 0x6600, 0x6604, 0x6608, 0x6609, + 0x660d, 0x6611, 0x6612, 0x6615, 0x6616, 0x661d, + /* 0x42 */ + 0x661e, 0x6621, 0x6622, 0x6623, 0x6624, 0x6626, 0x6629, 0x662a, + 0x662b, 0x662c, 0x662e, 0x6630, 0x6631, 0x6633, 0x6639, 0x6637, + 0x6640, 0x6645, 0x6646, 0x664a, 0x664c, 0x6651, 0x664e, 0x6657, + 0x6658, 0x6659, 0x665b, 0x665c, 0x6660, 0x6661, 0x66fb, 0x666a, + 0x666b, 0x666c, 0x667e, 0x6673, 0x6675, 0x667f, 0x6677, 0x6678, + 0x6679, 0x667b, 0x6680, 0x667c, 0x668b, 0x668c, 0x668d, 0x6690, + 0x6692, 0x6699, 0x669a, 0x669b, 0x669c, 0x669f, 0x66a0, 0x66a4, + 0x66ad, 0x66b1, 0x66b2, 0x66b5, 0x66bb, 0x66bf, 0x66c0, 0x66c2, + 0x66c3, 0x66c8, 0x66cc, 0x66ce, 0x66cf, 0x66d4, 0x66db, 0x66df, + 0x66e8, 0x66eb, 0x66ec, 0x66ee, 0x66fa, 0x6705, 0x6707, 0x670e, + 0x6713, 0x6719, 0x671c, 0x6720, 0x6722, 0x6733, 0x673e, 0x6745, + 0x6747, 0x6748, 0x674c, 0x6754, 0x6755, 0x675d, + /* 0x43 */ + 0x6766, 0x676c, 0x676e, 0x6774, 0x6776, 0x677b, 0x6781, 0x6784, + 0x678e, 0x678f, 0x6791, 0x6793, 0x6796, 0x6798, 0x6799, 0x679b, + 0x67b0, 0x67b1, 0x67b2, 0x67b5, 0x67bb, 0x67bc, 0x67bd, 0x67f9, + 0x67c0, 0x67c2, 0x67c3, 0x67c5, 0x67c8, 0x67c9, 0x67d2, 0x67d7, + 0x67d9, 0x67dc, 0x67e1, 0x67e6, 0x67f0, 0x67f2, 0x67f6, 0x67f7, + 0x6852, 0x6814, 0x6819, 0x681d, 0x681f, 0x6828, 0x6827, 0x682c, + 0x682d, 0x682f, 0x6830, 0x6831, 0x6833, 0x683b, 0x683f, 0x6844, + 0x6845, 0x684a, 0x684c, 0x6855, 0x6857, 0x6858, 0x685b, 0x686b, + 0x686e, 0x686f, 0x6870, 0x6871, 0x6872, 0x6875, 0x6879, 0x687a, + 0x687b, 0x687c, 0x6882, 0x6884, 0x6886, 0x6888, 0x6896, 0x6898, + 0x689a, 0x689c, 0x68a1, 0x68a3, 0x68a5, 0x68a9, 0x68aa, 0x68ae, + 0x68b2, 0x68bb, 0x68c5, 0x68c8, 0x68cc, 0x68cf, + /* 0x44 */ + 0x68d0, 0x68d1, 0x68d3, 0x68d6, 0x68d9, 0x68dc, 0x68dd, 0x68e5, + 0x68e8, 0x68ea, 0x68eb, 0x68ec, 0x68ed, 0x68f0, 0x68f1, 0x68f5, + 0x68f6, 0x68fb, 0x68fc, 0x68fd, 0x6906, 0x6909, 0x690a, 0x6910, + 0x6911, 0x6913, 0x6916, 0x6917, 0x6931, 0x6933, 0x6935, 0x6938, + 0x693b, 0x6942, 0x6945, 0x6949, 0x694e, 0x6957, 0x695b, 0x6963, + 0x6964, 0x6965, 0x6966, 0x6968, 0x6969, 0x696c, 0x6970, 0x6971, + 0x6972, 0x697a, 0x697b, 0x697f, 0x6980, 0x698d, 0x6992, 0x6996, + 0x6998, 0x69a1, 0x69a5, 0x69a6, 0x69a8, 0x69ab, 0x69ad, 0x69af, + 0x69b7, 0x69b8, 0x69ba, 0x69bc, 0x69c5, 0x69c8, 0x69d1, 0x69d6, + 0x69d7, 0x69e2, 0x69e5, 0x69ee, 0x69ef, 0x69f1, 0x69f3, 0x69f5, + 0x69fe, 0x6a00, 0x6a01, 0x6a03, 0x6a0f, 0x6a11, 0x6a15, 0x6a1a, + 0x6a1d, 0x6a20, 0x6a24, 0x6a28, 0x6a30, 0x6a32, + /* 0x45 */ + 0x6a34, 0x6a37, 0x6a3b, 0x6a3e, 0x6a3f, 0x6a45, 0x6a46, 0x6a49, + 0x6a4a, 0x6a4e, 0x6a50, 0x6a51, 0x6a52, 0x6a55, 0x6a56, 0x6a5b, + 0x6a64, 0x6a67, 0x6a6a, 0x6a71, 0x6a73, 0x6a7e, 0x6a81, 0x6a83, + 0x6a86, 0x6a87, 0x6a89, 0x6a8b, 0x6a91, 0x6a9b, 0x6a9d, 0x6a9e, + 0x6a9f, 0x6aa5, 0x6aab, 0x6aaf, 0x6ab0, 0x6ab1, 0x6ab4, 0x6abd, + 0x6abe, 0x6abf, 0x6ac6, 0x6ac9, 0x6ac8, 0x6acc, 0x6ad0, 0x6ad4, + 0x6ad5, 0x6ad6, 0x6adc, 0x6add, 0x6ae4, 0x6ae7, 0x6aec, 0x6af0, + 0x6af1, 0x6af2, 0x6afc, 0x6afd, 0x6b02, 0x6b03, 0x6b06, 0x6b07, + 0x6b09, 0x6b0f, 0x6b10, 0x6b11, 0x6b17, 0x6b1b, 0x6b1e, 0x6b24, + 0x6b28, 0x6b2b, 0x6b2c, 0x6b2f, 0x6b35, 0x6b36, 0x6b3b, 0x6b3f, + 0x6b46, 0x6b4a, 0x6b4d, 0x6b52, 0x6b56, 0x6b58, 0x6b5d, 0x6b60, + 0x6b67, 0x6b6b, 0x6b6e, 0x6b70, 0x6b75, 0x6b7d, + /* 0x46 */ + 0x6b7e, 0x6b82, 0x6b85, 0x6b97, 0x6b9b, 0x6b9f, 0x6ba0, 0x6ba2, + 0x6ba3, 0x6ba8, 0x6ba9, 0x6bac, 0x6bad, 0x6bae, 0x6bb0, 0x6bb8, + 0x6bb9, 0x6bbd, 0x6bbe, 0x6bc3, 0x6bc4, 0x6bc9, 0x6bcc, 0x6bd6, + 0x6bda, 0x6be1, 0x6be3, 0x6be6, 0x6be7, 0x6bee, 0x6bf1, 0x6bf7, + 0x6bf9, 0x6bff, 0x6c02, 0x6c04, 0x6c05, 0x6c09, 0x6c0d, 0x6c0e, + 0x6c10, 0x6c12, 0x6c19, 0x6c1f, 0x6c26, 0x6c27, 0x6c28, 0x6c2c, + 0x6c2e, 0x6c33, 0x6c35, 0x6c36, 0x6c3a, 0x6c3b, 0x6c3f, 0x6c4a, + 0x6c4b, 0x6c4d, 0x6c4f, 0x6c52, 0x6c54, 0x6c59, 0x6c5b, 0x6c5c, + 0x6c6b, 0x6c6d, 0x6c6f, 0x6c74, 0x6c76, 0x6c78, 0x6c79, 0x6c7b, + 0x6c85, 0x6c86, 0x6c87, 0x6c89, 0x6c94, 0x6c95, 0x6c97, 0x6c98, + 0x6c9c, 0x6c9f, 0x6cb0, 0x6cb2, 0x6cb4, 0x6cc2, 0x6cc6, 0x6ccd, + 0x6ccf, 0x6cd0, 0x6cd1, 0x6cd2, 0x6cd4, 0x6cd6, + /* 0x47 */ + 0x6cda, 0x6cdc, 0x6ce0, 0x6ce7, 0x6ce9, 0x6ceb, 0x6cec, 0x6cee, + 0x6cf2, 0x6cf4, 0x6d04, 0x6d07, 0x6d0a, 0x6d0e, 0x6d0f, 0x6d11, + 0x6d13, 0x6d1a, 0x6d26, 0x6d27, 0x6d28, 0x6c67, 0x6d2e, 0x6d2f, + 0x6d31, 0x6d39, 0x6d3c, 0x6d3f, 0x6d57, 0x6d5e, 0x6d5f, 0x6d61, + 0x6d65, 0x6d67, 0x6d6f, 0x6d70, 0x6d7c, 0x6d82, 0x6d87, 0x6d91, + 0x6d92, 0x6d94, 0x6d96, 0x6d97, 0x6d98, 0x6daa, 0x6dac, 0x6db4, + 0x6db7, 0x6db9, 0x6dbd, 0x6dbf, 0x6dc4, 0x6dc8, 0x6dca, 0x6dce, + 0x6dcf, 0x6dd6, 0x6ddb, 0x6ddd, 0x6ddf, 0x6de0, 0x6de2, 0x6de5, + 0x6de9, 0x6def, 0x6df0, 0x6df4, 0x6df6, 0x6dfc, 0x6e00, 0x6e04, + 0x6e1e, 0x6e22, 0x6e27, 0x6e32, 0x6e36, 0x6e39, 0x6e3b, 0x6e3c, + 0x6e44, 0x6e45, 0x6e48, 0x6e49, 0x6e4b, 0x6e4f, 0x6e51, 0x6e52, + 0x6e53, 0x6e54, 0x6e57, 0x6e5c, 0x6e5d, 0x6e5e, + /* 0x48 */ + 0x6e62, 0x6e63, 0x6e68, 0x6e73, 0x6e7b, 0x6e7d, 0x6e8d, 0x6e93, + 0x6e99, 0x6ea0, 0x6ea7, 0x6ead, 0x6eae, 0x6eb1, 0x6eb3, 0x6ebb, + 0x6ebf, 0x6ec0, 0x6ec1, 0x6ec3, 0x6ec7, 0x6ec8, 0x6eca, 0x6ecd, + 0x6ece, 0x6ecf, 0x6eeb, 0x6eed, 0x6eee, 0x6ef9, 0x6efb, 0x6efd, + 0x6f04, 0x6f08, 0x6f0a, 0x6f0c, 0x6f0d, 0x6f16, 0x6f18, 0x6f1a, + 0x6f1b, 0x6f26, 0x6f29, 0x6f2a, 0x6f2f, 0x6f30, 0x6f33, 0x6f36, + 0x6f3b, 0x6f3c, 0x6f2d, 0x6f4f, 0x6f51, 0x6f52, 0x6f53, 0x6f57, + 0x6f59, 0x6f5a, 0x6f5d, 0x6f5e, 0x6f61, 0x6f62, 0x6f68, 0x6f6c, + 0x6f7d, 0x6f7e, 0x6f83, 0x6f87, 0x6f88, 0x6f8b, 0x6f8c, 0x6f8d, + 0x6f90, 0x6f92, 0x6f93, 0x6f94, 0x6f96, 0x6f9a, 0x6f9f, 0x6fa0, + 0x6fa5, 0x6fa6, 0x6fa7, 0x6fa8, 0x6fae, 0x6faf, 0x6fb0, 0x6fb5, + 0x6fb6, 0x6fbc, 0x6fc5, 0x6fc7, 0x6fc8, 0x6fca, + /* 0x49 */ + 0x6fda, 0x6fde, 0x6fe8, 0x6fe9, 0x6ff0, 0x6ff5, 0x6ff9, 0x6ffc, + 0x6ffd, 0x7000, 0x7005, 0x7006, 0x7007, 0x700d, 0x7017, 0x7020, + 0x7023, 0x702f, 0x7034, 0x7037, 0x7039, 0x703c, 0x7043, 0x7044, + 0x7048, 0x7049, 0x704a, 0x704b, 0x7054, 0x7055, 0x705d, 0x705e, + 0x704e, 0x7064, 0x7065, 0x706c, 0x706e, 0x7075, 0x7076, 0x707e, + 0x7081, 0x7085, 0x7086, 0x7094, 0x7095, 0x7096, 0x7097, 0x7098, + 0x709b, 0x70a4, 0x70ab, 0x70b0, 0x70b1, 0x70b4, 0x70b7, 0x70ca, + 0x70d1, 0x70d3, 0x70d4, 0x70d5, 0x70d6, 0x70d8, 0x70dc, 0x70e4, + 0x70fa, 0x7103, 0x7104, 0x7105, 0x7106, 0x7107, 0x710b, 0x710c, + 0x710f, 0x711e, 0x7120, 0x712b, 0x712d, 0x712f, 0x7130, 0x7131, + 0x7138, 0x7141, 0x7145, 0x7146, 0x7147, 0x714a, 0x714b, 0x7150, + 0x7152, 0x7157, 0x715a, 0x715c, 0x715e, 0x7160, + /* 0x4a */ + 0x7168, 0x7179, 0x7180, 0x7185, 0x7187, 0x718c, 0x7192, 0x719a, + 0x719b, 0x71a0, 0x71a2, 0x71af, 0x71b0, 0x71b2, 0x71b3, 0x71ba, + 0x71bf, 0x71c0, 0x71c1, 0x71c4, 0x71cb, 0x71cc, 0x71d3, 0x71d6, + 0x71d9, 0x71da, 0x71dc, 0x71f8, 0x71fe, 0x7200, 0x7207, 0x7208, + 0x7209, 0x7213, 0x7217, 0x721a, 0x721d, 0x721f, 0x7224, 0x722b, + 0x722f, 0x7234, 0x7238, 0x7239, 0x7241, 0x7242, 0x7243, 0x7245, + 0x724e, 0x724f, 0x7250, 0x7253, 0x7255, 0x7256, 0x725a, 0x725c, + 0x725e, 0x7260, 0x7263, 0x7268, 0x726b, 0x726e, 0x726f, 0x7271, + 0x7277, 0x7278, 0x727b, 0x727c, 0x727f, 0x7284, 0x7289, 0x728d, + 0x728e, 0x7293, 0x729b, 0x72a8, 0x72ad, 0x72ae, 0x72b1, 0x72b4, + 0x72be, 0x72c1, 0x72c7, 0x72c9, 0x72cc, 0x72d5, 0x72d6, 0x72d8, + 0x72df, 0x72e5, 0x72f3, 0x72f4, 0x72fa, 0x72fb, + /* 0x4b */ + 0x72fe, 0x7302, 0x7304, 0x7305, 0x7307, 0x730b, 0x730d, 0x7312, + 0x7313, 0x7318, 0x7319, 0x731e, 0x7322, 0x7324, 0x7327, 0x7328, + 0x732c, 0x7331, 0x7332, 0x7335, 0x733a, 0x733b, 0x733d, 0x7343, + 0x734d, 0x7350, 0x7352, 0x7356, 0x7358, 0x735d, 0x735e, 0x735f, + 0x7360, 0x7366, 0x7367, 0x7369, 0x736b, 0x736c, 0x736e, 0x736f, + 0x7371, 0x7377, 0x7379, 0x737c, 0x7380, 0x7381, 0x7383, 0x7385, + 0x7386, 0x738e, 0x7390, 0x7393, 0x7395, 0x7397, 0x7398, 0x739c, + 0x739e, 0x739f, 0x73a0, 0x73a2, 0x73a5, 0x73a6, 0x73aa, 0x73ab, + 0x73ad, 0x73b5, 0x73b7, 0x73b9, 0x73bc, 0x73bd, 0x73bf, 0x73c5, + 0x73c6, 0x73c9, 0x73cb, 0x73cc, 0x73cf, 0x73d2, 0x73d3, 0x73d6, + 0x73d9, 0x73dd, 0x73e1, 0x73e3, 0x73e6, 0x73e7, 0x73e9, 0x73f4, + 0x73f5, 0x73f7, 0x73f9, 0x73fa, 0x73fb, 0x73fd, + /* 0x4c */ + 0x73ff, 0x7400, 0x7401, 0x7404, 0x7407, 0x740a, 0x7411, 0x741a, + 0x741b, 0x7424, 0x7426, 0x7428, 0x7429, 0x742a, 0x742b, 0x742c, + 0x742d, 0x742e, 0x742f, 0x7430, 0x7431, 0x7439, 0x7440, 0x7443, + 0x7444, 0x7446, 0x7447, 0x744b, 0x744d, 0x7451, 0x7452, 0x7457, + 0x745d, 0x7462, 0x7466, 0x7467, 0x7468, 0x746b, 0x746d, 0x746e, + 0x7471, 0x7472, 0x7480, 0x7481, 0x7485, 0x7486, 0x7487, 0x7489, + 0x748f, 0x7490, 0x7491, 0x7492, 0x7498, 0x7499, 0x749a, 0x749c, + 0x749f, 0x74a0, 0x74a1, 0x74a3, 0x74a6, 0x74a8, 0x74a9, 0x74aa, + 0x74ab, 0x74ae, 0x74af, 0x74b1, 0x74b2, 0x74b5, 0x74b9, 0x74bb, + 0x74bf, 0x74c8, 0x74c9, 0x74cc, 0x74d0, 0x74d3, 0x74d8, 0x74da, + 0x74db, 0x74de, 0x74df, 0x74e4, 0x74e8, 0x74ea, 0x74eb, 0x74ef, + 0x74f4, 0x74fa, 0x74fb, 0x74fc, 0x74ff, 0x7506, + /* 0x4d */ + 0x7512, 0x7516, 0x7517, 0x7520, 0x7521, 0x7524, 0x7527, 0x7529, + 0x752a, 0x752f, 0x7536, 0x7539, 0x753d, 0x753e, 0x753f, 0x7540, + 0x7543, 0x7547, 0x7548, 0x754e, 0x7550, 0x7552, 0x7557, 0x755e, + 0x755f, 0x7561, 0x756f, 0x7571, 0x7579, 0x757a, 0x757b, 0x757c, + 0x757d, 0x757e, 0x7581, 0x7585, 0x7590, 0x7592, 0x7593, 0x7595, + 0x7599, 0x759c, 0x75a2, 0x75a4, 0x75b4, 0x75ba, 0x75bf, 0x75c0, + 0x75c1, 0x75c4, 0x75c6, 0x75cc, 0x75ce, 0x75cf, 0x75d7, 0x75dc, + 0x75df, 0x75e0, 0x75e1, 0x75e4, 0x75e7, 0x75ec, 0x75ee, 0x75ef, + 0x75f1, 0x75f9, 0x7600, 0x7602, 0x7603, 0x7604, 0x7607, 0x7608, + 0x760a, 0x760c, 0x760f, 0x7612, 0x7613, 0x7615, 0x7616, 0x7619, + 0x761b, 0x761c, 0x761d, 0x761e, 0x7623, 0x7625, 0x7626, 0x7629, + 0x762d, 0x7632, 0x7633, 0x7635, 0x7638, 0x7639, + /* 0x4e */ + 0x763a, 0x763c, 0x764a, 0x7640, 0x7641, 0x7643, 0x7644, 0x7645, + 0x7649, 0x764b, 0x7655, 0x7659, 0x765f, 0x7664, 0x7665, 0x766d, + 0x766e, 0x766f, 0x7671, 0x7674, 0x7681, 0x7685, 0x768c, 0x768d, + 0x7695, 0x769b, 0x769c, 0x769d, 0x769f, 0x76a0, 0x76a2, 0x76a3, + 0x76a4, 0x76a5, 0x76a6, 0x76a7, 0x76a8, 0x76aa, 0x76ad, 0x76bd, + 0x76c1, 0x76c5, 0x76c9, 0x76cb, 0x76cc, 0x76ce, 0x76d4, 0x76d9, + 0x76e0, 0x76e6, 0x76e8, 0x76ec, 0x76f0, 0x76f1, 0x76f6, 0x76f9, + 0x76fc, 0x7700, 0x7706, 0x770a, 0x770e, 0x7712, 0x7714, 0x7715, + 0x7717, 0x7719, 0x771a, 0x771c, 0x7722, 0x7728, 0x772d, 0x772e, + 0x772f, 0x7734, 0x7735, 0x7736, 0x7739, 0x773d, 0x773e, 0x7742, + 0x7745, 0x7746, 0x774a, 0x774d, 0x774e, 0x774f, 0x7752, 0x7756, + 0x7757, 0x775c, 0x775e, 0x775f, 0x7760, 0x7762, + /* 0x4f */ + 0x7764, 0x7767, 0x776a, 0x776c, 0x7770, 0x7772, 0x7773, 0x7774, + 0x777a, 0x777d, 0x7780, 0x7784, 0x778c, 0x778d, 0x7794, 0x7795, + 0x7796, 0x779a, 0x779f, 0x77a2, 0x77a7, 0x77aa, 0x77ae, 0x77af, + 0x77b1, 0x77b5, 0x77be, 0x77c3, 0x77c9, 0x77d1, 0x77d2, 0x77d5, + 0x77d9, 0x77de, 0x77df, 0x77e0, 0x77e4, 0x77e6, 0x77ea, 0x77ec, + 0x77f0, 0x77f1, 0x77f4, 0x77f8, 0x77fb, 0x7805, 0x7806, 0x7809, + 0x780d, 0x780e, 0x7811, 0x781d, 0x7821, 0x7822, 0x7823, 0x782d, + 0x782e, 0x7830, 0x7835, 0x7837, 0x7843, 0x7844, 0x7847, 0x7848, + 0x784c, 0x784e, 0x7852, 0x785c, 0x785e, 0x7860, 0x7861, 0x7863, + 0x7864, 0x7868, 0x786a, 0x786e, 0x787a, 0x787e, 0x788a, 0x788f, + 0x7894, 0x7898, 0x78a1, 0x789d, 0x789e, 0x789f, 0x78a4, 0x78a8, + 0x78ac, 0x78ad, 0x78b0, 0x78b1, 0x78b2, 0x78b3, + /* 0x50 */ + 0x78bb, 0x78bd, 0x78bf, 0x78c7, 0x78c8, 0x78c9, 0x78cc, 0x78ce, + 0x78d2, 0x78d3, 0x78d5, 0x78d6, 0x78e4, 0x78db, 0x78df, 0x78e0, + 0x78e1, 0x78e6, 0x78ea, 0x78f2, 0x78f3, 0x7900, 0x78f6, 0x78f7, + 0x78fa, 0x78fb, 0x78ff, 0x7906, 0x790c, 0x7910, 0x791a, 0x791c, + 0x791e, 0x791f, 0x7920, 0x7925, 0x7927, 0x7929, 0x792d, 0x7931, + 0x7934, 0x7935, 0x793b, 0x793d, 0x793f, 0x7944, 0x7945, 0x7946, + 0x794a, 0x794b, 0x794f, 0x7951, 0x7954, 0x7958, 0x795b, 0x795c, + 0x7967, 0x7969, 0x796b, 0x7972, 0x7979, 0x797b, 0x797c, 0x797e, + 0x798b, 0x798c, 0x7991, 0x7993, 0x7994, 0x7995, 0x7996, 0x7998, + 0x799b, 0x799c, 0x79a1, 0x79a8, 0x79a9, 0x79ab, 0x79af, 0x79b1, + 0x79b4, 0x79b8, 0x79bb, 0x79c2, 0x79c4, 0x79c7, 0x79c8, 0x79ca, + 0x79cf, 0x79d4, 0x79d6, 0x79da, 0x79dd, 0x79de, + /* 0x51 */ + 0x79e0, 0x79e2, 0x79e5, 0x79ea, 0x79eb, 0x79ed, 0x79f1, 0x79f8, + 0x79fc, 0x7a02, 0x7a03, 0x7a07, 0x7a09, 0x7a0a, 0x7a0c, 0x7a11, + 0x7a15, 0x7a1b, 0x7a1e, 0x7a21, 0x7a27, 0x7a2b, 0x7a2d, 0x7a2f, + 0x7a30, 0x7a34, 0x7a35, 0x7a38, 0x7a39, 0x7a3a, 0x7a44, 0x7a45, + 0x7a47, 0x7a48, 0x7a4c, 0x7a55, 0x7a56, 0x7a59, 0x7a5c, 0x7a5d, + 0x7a5f, 0x7a60, 0x7a65, 0x7a67, 0x7a6a, 0x7a6d, 0x7a75, 0x7a78, + 0x7a7e, 0x7a80, 0x7a82, 0x7a85, 0x7a86, 0x7a8a, 0x7a8b, 0x7a90, + 0x7a91, 0x7a94, 0x7a9e, 0x7aa0, 0x7aa3, 0x7aac, 0x7ab3, 0x7ab5, + 0x7ab9, 0x7abb, 0x7abc, 0x7ac6, 0x7ac9, 0x7acc, 0x7ace, 0x7ad1, + 0x7adb, 0x7ae8, 0x7ae9, 0x7aeb, 0x7aec, 0x7af1, 0x7af4, 0x7afb, + 0x7afd, 0x7afe, 0x7b07, 0x7b14, 0x7b1f, 0x7b23, 0x7b27, 0x7b29, + 0x7b2a, 0x7b2b, 0x7b2d, 0x7b2e, 0x7b2f, 0x7b30, + /* 0x52 */ + 0x7b31, 0x7b34, 0x7b3d, 0x7b3f, 0x7b40, 0x7b41, 0x7b47, 0x7b4e, + 0x7b55, 0x7b60, 0x7b64, 0x7b66, 0x7b69, 0x7b6a, 0x7b6d, 0x7b6f, + 0x7b72, 0x7b73, 0x7b77, 0x7b84, 0x7b89, 0x7b8e, 0x7b90, 0x7b91, + 0x7b96, 0x7b9b, 0x7b9e, 0x7ba0, 0x7ba5, 0x7bac, 0x7baf, 0x7bb0, + 0x7bb2, 0x7bb5, 0x7bb6, 0x7bba, 0x7bbb, 0x7bbc, 0x7bbd, 0x7bc2, + 0x7bc5, 0x7bc8, 0x7bca, 0x7bd4, 0x7bd6, 0x7bd7, 0x7bd9, 0x7bda, + 0x7bdb, 0x7be8, 0x7bea, 0x7bf2, 0x7bf4, 0x7bf5, 0x7bf8, 0x7bf9, + 0x7bfa, 0x7bfc, 0x7bfe, 0x7c01, 0x7c02, 0x7c03, 0x7c04, 0x7c06, + 0x7c09, 0x7c0b, 0x7c0c, 0x7c0e, 0x7c0f, 0x7c19, 0x7c1b, 0x7c20, + 0x7c25, 0x7c26, 0x7c28, 0x7c2c, 0x7c31, 0x7c33, 0x7c34, 0x7c36, + 0x7c39, 0x7c3a, 0x7c46, 0x7c4a, 0x7c55, 0x7c51, 0x7c52, 0x7c53, + 0x7c59, 0x7c5a, 0x7c5b, 0x7c5c, 0x7c5d, 0x7c5e, + /* 0x53 */ + 0x7c61, 0x7c63, 0x7c67, 0x7c69, 0x7c6d, 0x7c6e, 0x7c70, 0x7c72, + 0x7c79, 0x7c7c, 0x7c7d, 0x7c86, 0x7c87, 0x7c8f, 0x7c94, 0x7c9e, + 0x7ca0, 0x7ca6, 0x7cb0, 0x7cb6, 0x7cb7, 0x7cba, 0x7cbb, 0x7cbc, + 0x7cbf, 0x7cc4, 0x7cc7, 0x7cc8, 0x7cc9, 0x7ccd, 0x7ccf, 0x7cd3, + 0x7cd4, 0x7cd5, 0x7cd7, 0x7cd9, 0x7cda, 0x7cdd, 0x7ce6, 0x7ce9, + 0x7ceb, 0x7cf5, 0x7d03, 0x7d07, 0x7d08, 0x7d09, 0x7d0f, 0x7d11, + 0x7d12, 0x7d13, 0x7d16, 0x7d1d, 0x7d1e, 0x7d23, 0x7d26, 0x7d2a, + 0x7d2d, 0x7d31, 0x7d3c, 0x7d3d, 0x7d3e, 0x7d40, 0x7d41, 0x7d47, + 0x7d48, 0x7d4d, 0x7d51, 0x7d53, 0x7d57, 0x7d59, 0x7d5a, 0x7d5c, + 0x7d5d, 0x7d65, 0x7d67, 0x7d6a, 0x7d70, 0x7d78, 0x7d7a, 0x7d7b, + 0x7d7f, 0x7d81, 0x7d82, 0x7d83, 0x7d85, 0x7d86, 0x7d88, 0x7d8b, + 0x7d8c, 0x7d8d, 0x7d91, 0x7d96, 0x7d97, 0x7d9d, + /* 0x54 */ + 0x7d9e, 0x7da6, 0x7da7, 0x7daa, 0x7db3, 0x7db6, 0x7db7, 0x7db9, + 0x7dc2, 0x7dc3, 0x7dc4, 0x7dc5, 0x7dc6, 0x7dcc, 0x7dcd, 0x7dce, + 0x7dd7, 0x7dd9, 0x7e00, 0x7de2, 0x7de5, 0x7de6, 0x7dea, 0x7deb, + 0x7ded, 0x7df1, 0x7df5, 0x7df6, 0x7df9, 0x7dfa, 0x7e08, 0x7e10, + 0x7e11, 0x7e15, 0x7e17, 0x7e1c, 0x7e1d, 0x7e20, 0x7e27, 0x7e28, + 0x7e2c, 0x7e2d, 0x7e2f, 0x7e33, 0x7e36, 0x7e3f, 0x7e44, 0x7e45, + 0x7e47, 0x7e4e, 0x7e50, 0x7e52, 0x7e58, 0x7e5f, 0x7e61, 0x7e62, + 0x7e65, 0x7e6b, 0x7e6e, 0x7e6f, 0x7e73, 0x7e78, 0x7e7e, 0x7e81, + 0x7e86, 0x7e87, 0x7e8a, 0x7e8d, 0x7e91, 0x7e95, 0x7e98, 0x7e9a, + 0x7e9d, 0x7e9e, 0x7f3c, 0x7f3b, 0x7f3d, 0x7f3e, 0x7f3f, 0x7f43, + 0x7f44, 0x7f47, 0x7f4f, 0x7f52, 0x7f53, 0x7f5b, 0x7f5c, 0x7f5d, + 0x7f61, 0x7f63, 0x7f64, 0x7f65, 0x7f66, 0x7f6d, + /* 0x55 */ + 0x7f71, 0x7f7d, 0x7f7e, 0x7f7f, 0x7f80, 0x7f8b, 0x7f8d, 0x7f8f, + 0x7f90, 0x7f91, 0x7f96, 0x7f97, 0x7f9c, 0x7fa1, 0x7fa2, 0x7fa6, + 0x7faa, 0x7fad, 0x7fb4, 0x7fbc, 0x7fbf, 0x7fc0, 0x7fc3, 0x7fc8, + 0x7fce, 0x7fcf, 0x7fdb, 0x7fdf, 0x7fe3, 0x7fe5, 0x7fe8, 0x7fec, + 0x7fee, 0x7fef, 0x7ff2, 0x7ffa, 0x7ffd, 0x7ffe, 0x7fff, 0x8007, + 0x8008, 0x800a, 0x800d, 0x800e, 0x800f, 0x8011, 0x8013, 0x8014, + 0x8016, 0x801d, 0x801e, 0x801f, 0x8020, 0x8024, 0x8026, 0x802c, + 0x802e, 0x8030, 0x8034, 0x8035, 0x8037, 0x8039, 0x803a, 0x803c, + 0x803e, 0x8040, 0x8044, 0x8060, 0x8064, 0x8066, 0x806d, 0x8071, + 0x8075, 0x8081, 0x8088, 0x808e, 0x809c, 0x809e, 0x80a6, 0x80a7, + 0x80ab, 0x80b8, 0x80b9, 0x80c8, 0x80cd, 0x80cf, 0x80d2, 0x80d4, + 0x80d5, 0x80d7, 0x80d8, 0x80e0, 0x80ed, 0x80ee, + /* 0x56 */ + 0x80f0, 0x80f2, 0x80f3, 0x80f6, 0x80f9, 0x80fa, 0x80fe, 0x8103, + 0x810b, 0x8116, 0x8117, 0x8118, 0x811c, 0x811e, 0x8120, 0x8124, + 0x8127, 0x812c, 0x8130, 0x8135, 0x813a, 0x813c, 0x8145, 0x8147, + 0x814a, 0x814c, 0x8152, 0x8157, 0x8160, 0x8161, 0x8167, 0x8168, + 0x8169, 0x816d, 0x816f, 0x8177, 0x8181, 0x8190, 0x8184, 0x8185, + 0x8186, 0x818b, 0x818e, 0x8196, 0x8198, 0x819b, 0x819e, 0x81a2, + 0x81ae, 0x81b2, 0x81b4, 0x81bb, 0x81cb, 0x81c3, 0x81c5, 0x81ca, + 0x81ce, 0x81cf, 0x81d5, 0x81d7, 0x81db, 0x81dd, 0x81de, 0x81e1, + 0x81e4, 0x81eb, 0x81ec, 0x81f0, 0x81f1, 0x81f2, 0x81f5, 0x81f6, + 0x81f8, 0x81f9, 0x81fd, 0x81ff, 0x8200, 0x8203, 0x820f, 0x8213, + 0x8214, 0x8219, 0x821a, 0x821d, 0x8221, 0x8222, 0x8228, 0x8232, + 0x8234, 0x823a, 0x8243, 0x8244, 0x8245, 0x8246, + /* 0x57 */ + 0x824b, 0x824e, 0x824f, 0x8251, 0x8256, 0x825c, 0x8260, 0x8263, + 0x8267, 0x826d, 0x8274, 0x827b, 0x827d, 0x827f, 0x8280, 0x8281, + 0x8283, 0x8284, 0x8287, 0x8289, 0x828a, 0x828e, 0x8291, 0x8294, + 0x8296, 0x8298, 0x829a, 0x829b, 0x82a0, 0x82a1, 0x82a3, 0x82a4, + 0x82a7, 0x82a8, 0x82a9, 0x82aa, 0x82ae, 0x82b0, 0x82b2, 0x82b4, + 0x82b7, 0x82ba, 0x82bc, 0x82be, 0x82bf, 0x82c6, 0x82d0, 0x82d5, + 0x82da, 0x82e0, 0x82e2, 0x82e4, 0x82e8, 0x82ea, 0x82ed, 0x82ef, + 0x82f6, 0x82f7, 0x82fd, 0x82fe, 0x8300, 0x8301, 0x8307, 0x8308, + 0x830a, 0x830b, 0x8354, 0x831b, 0x831d, 0x831e, 0x831f, 0x8321, + 0x8322, 0x832c, 0x832d, 0x832e, 0x8330, 0x8333, 0x8337, 0x833a, + 0x833c, 0x833d, 0x8342, 0x8343, 0x8344, 0x8347, 0x834d, 0x834e, + 0x8351, 0x8355, 0x8356, 0x8357, 0x8370, 0x8378, + /* 0x58 */ + 0x837d, 0x837f, 0x8380, 0x8382, 0x8384, 0x8386, 0x838d, 0x8392, + 0x8394, 0x8395, 0x8398, 0x8399, 0x839b, 0x839c, 0x839d, 0x83a6, + 0x83a7, 0x83a9, 0x83ac, 0x83be, 0x83bf, 0x83c0, 0x83c7, 0x83c9, + 0x83cf, 0x83d0, 0x83d1, 0x83d4, 0x83dd, 0x8353, 0x83e8, 0x83ea, + 0x83f6, 0x83f8, 0x83f9, 0x83fc, 0x8401, 0x8406, 0x840a, 0x840f, + 0x8411, 0x8415, 0x8419, 0x83ad, 0x842f, 0x8439, 0x8445, 0x8447, + 0x8448, 0x844a, 0x844d, 0x844f, 0x8451, 0x8452, 0x8456, 0x8458, + 0x8459, 0x845a, 0x845c, 0x8460, 0x8464, 0x8465, 0x8467, 0x846a, + 0x8470, 0x8473, 0x8474, 0x8476, 0x8478, 0x847c, 0x847d, 0x8481, + 0x8485, 0x8492, 0x8493, 0x8495, 0x849e, 0x84a6, 0x84a8, 0x84a9, + 0x84aa, 0x84af, 0x84b1, 0x84b4, 0x84ba, 0x84bd, 0x84be, 0x84c0, + 0x84c2, 0x84c7, 0x84c8, 0x84cc, 0x84cf, 0x84d3, + /* 0x59 */ + 0x84dc, 0x84e7, 0x84ea, 0x84ef, 0x84f0, 0x84f1, 0x84f2, 0x84f7, + 0x8532, 0x84fa, 0x84fb, 0x84fd, 0x8502, 0x8503, 0x8507, 0x850c, + 0x850e, 0x8510, 0x851c, 0x851e, 0x8522, 0x8523, 0x8524, 0x8525, + 0x8527, 0x852a, 0x852b, 0x852f, 0x8533, 0x8534, 0x8536, 0x853f, + 0x8546, 0x854f, 0x8550, 0x8551, 0x8552, 0x8553, 0x8556, 0x8559, + 0x855c, 0x855d, 0x855e, 0x855f, 0x8560, 0x8561, 0x8562, 0x8564, + 0x856b, 0x856f, 0x8579, 0x857a, 0x857b, 0x857d, 0x857f, 0x8581, + 0x8585, 0x8586, 0x8589, 0x858b, 0x858c, 0x858f, 0x8593, 0x8598, + 0x859d, 0x859f, 0x85a0, 0x85a2, 0x85a5, 0x85a7, 0x85b4, 0x85b6, + 0x85b7, 0x85b8, 0x85bc, 0x85bd, 0x85be, 0x85bf, 0x85c2, 0x85c7, + 0x85ca, 0x85cb, 0x85ce, 0x85ad, 0x85d8, 0x85da, 0x85df, 0x85e0, + 0x85e6, 0x85e8, 0x85ed, 0x85f3, 0x85f6, 0x85fc, + /* 0x5a */ + 0x85ff, 0x8600, 0x8604, 0x8605, 0x860d, 0x860e, 0x8610, 0x8611, + 0x8612, 0x8618, 0x8619, 0x861b, 0x861e, 0x8621, 0x8627, 0x8629, + 0x8636, 0x8638, 0x863a, 0x863c, 0x863d, 0x8640, 0x8642, 0x8646, + 0x8652, 0x8653, 0x8656, 0x8657, 0x8658, 0x8659, 0x865d, 0x8660, + 0x8661, 0x8662, 0x8663, 0x8664, 0x8669, 0x866c, 0x866f, 0x8675, + 0x8676, 0x8677, 0x867a, 0x868d, 0x8691, 0x8696, 0x8698, 0x869a, + 0x869c, 0x86a1, 0x86a6, 0x86a7, 0x86a8, 0x86ad, 0x86b1, 0x86b3, + 0x86b4, 0x86b5, 0x86b7, 0x86b8, 0x86b9, 0x86bf, 0x86c0, 0x86c1, + 0x86c3, 0x86c5, 0x86d1, 0x86d2, 0x86d5, 0x86d7, 0x86da, 0x86dc, + 0x86e0, 0x86e3, 0x86e5, 0x86e7, 0x8688, 0x86fa, 0x86fc, 0x86fd, + 0x8704, 0x8705, 0x8707, 0x870b, 0x870e, 0x870f, 0x8710, 0x8713, + 0x8714, 0x8719, 0x871e, 0x871f, 0x8721, 0x8723, + /* 0x5b */ + 0x8728, 0x872e, 0x872f, 0x8731, 0x8732, 0x8739, 0x873a, 0x873c, + 0x873d, 0x873e, 0x8740, 0x8743, 0x8745, 0x874d, 0x8758, 0x875d, + 0x8761, 0x8764, 0x8765, 0x876f, 0x8771, 0x8772, 0x877b, 0x8783, + 0x8784, 0x8785, 0x8786, 0x8787, 0x8788, 0x8789, 0x878b, 0x878c, + 0x8790, 0x8793, 0x8795, 0x8797, 0x8798, 0x8799, 0x879e, 0x87a0, + 0x87a3, 0x87a7, 0x87ac, 0x87ad, 0x87ae, 0x87b1, 0x87b5, 0x87be, + 0x87bf, 0x87c1, 0x87c8, 0x87c9, 0x87ca, 0x87ce, 0x87d5, 0x87d6, + 0x87d9, 0x87da, 0x87dc, 0x87df, 0x87e2, 0x87e3, 0x87e4, 0x87ea, + 0x87eb, 0x87ed, 0x87f1, 0x87f3, 0x87f8, 0x87fa, 0x87ff, 0x8801, + 0x8803, 0x8806, 0x8809, 0x880a, 0x880b, 0x8810, 0x8819, 0x8812, + 0x8813, 0x8814, 0x8818, 0x881a, 0x881b, 0x881c, 0x881e, 0x881f, + 0x8828, 0x882d, 0x882e, 0x8830, 0x8832, 0x8835, + /* 0x5c */ + 0x883a, 0x883c, 0x8841, 0x8843, 0x8845, 0x8848, 0x8849, 0x884a, + 0x884b, 0x884e, 0x8851, 0x8855, 0x8856, 0x8858, 0x885a, 0x885c, + 0x885f, 0x8860, 0x8864, 0x8869, 0x8871, 0x8879, 0x887b, 0x8880, + 0x8898, 0x889a, 0x889b, 0x889c, 0x889f, 0x88a0, 0x88a8, 0x88aa, + 0x88ba, 0x88bd, 0x88be, 0x88c0, 0x88ca, 0x88cb, 0x88cc, 0x88cd, + 0x88ce, 0x88d1, 0x88d2, 0x88d3, 0x88db, 0x88de, 0x88e7, 0x88ef, + 0x88f0, 0x88f1, 0x88f5, 0x88f7, 0x8901, 0x8906, 0x890d, 0x890e, + 0x890f, 0x8915, 0x8916, 0x8918, 0x8919, 0x891a, 0x891c, 0x8920, + 0x8926, 0x8927, 0x8928, 0x8930, 0x8931, 0x8932, 0x8935, 0x8939, + 0x893a, 0x893e, 0x8940, 0x8942, 0x8945, 0x8946, 0x8949, 0x894f, + 0x8952, 0x8957, 0x895a, 0x895b, 0x895c, 0x8961, 0x8962, 0x8963, + 0x896b, 0x896e, 0x8970, 0x8973, 0x8975, 0x897a, + /* 0x5d */ + 0x897b, 0x897c, 0x897d, 0x8989, 0x898d, 0x8990, 0x8994, 0x8995, + 0x899b, 0x899c, 0x899f, 0x89a0, 0x89a5, 0x89b0, 0x89b4, 0x89b5, + 0x89b6, 0x89b7, 0x89bc, 0x89d4, 0x89d5, 0x89d6, 0x89d7, 0x89d8, + 0x89e5, 0x89e9, 0x89eb, 0x89ed, 0x89f1, 0x89f3, 0x89f6, 0x89f9, + 0x89fd, 0x89ff, 0x8a04, 0x8a05, 0x8a07, 0x8a0f, 0x8a11, 0x8a12, + 0x8a14, 0x8a15, 0x8a1e, 0x8a20, 0x8a22, 0x8a24, 0x8a26, 0x8a2b, + 0x8a2c, 0x8a2f, 0x8a35, 0x8a37, 0x8a3d, 0x8a3e, 0x8a40, 0x8a43, + 0x8a45, 0x8a47, 0x8a49, 0x8a4d, 0x8a4e, 0x8a53, 0x8a56, 0x8a57, + 0x8a58, 0x8a5c, 0x8a5d, 0x8a61, 0x8a65, 0x8a67, 0x8a75, 0x8a76, + 0x8a77, 0x8a79, 0x8a7a, 0x8a7b, 0x8a7e, 0x8a7f, 0x8a80, 0x8a83, + 0x8a86, 0x8a8b, 0x8a8f, 0x8a90, 0x8a92, 0x8a96, 0x8a97, 0x8a99, + 0x8a9f, 0x8aa7, 0x8aa9, 0x8aae, 0x8aaf, 0x8ab3, + /* 0x5e */ + 0x8ab6, 0x8ab7, 0x8abb, 0x8abe, 0x8ac3, 0x8ac6, 0x8ac8, 0x8ac9, + 0x8aca, 0x8ad1, 0x8ad3, 0x8ad4, 0x8ad5, 0x8ad7, 0x8add, 0x8adf, + 0x8aec, 0x8af0, 0x8af4, 0x8af5, 0x8af6, 0x8afc, 0x8aff, 0x8b05, + 0x8b06, 0x8b0b, 0x8b11, 0x8b1c, 0x8b1e, 0x8b1f, 0x8b0a, 0x8b2d, + 0x8b30, 0x8b37, 0x8b3c, 0x8b42, 0x8b43, 0x8b44, 0x8b45, 0x8b46, + 0x8b48, 0x8b52, 0x8b53, 0x8b54, 0x8b59, 0x8b4d, 0x8b5e, 0x8b63, + 0x8b6d, 0x8b76, 0x8b78, 0x8b79, 0x8b7c, 0x8b7e, 0x8b81, 0x8b84, + 0x8b85, 0x8b8b, 0x8b8d, 0x8b8f, 0x8b94, 0x8b95, 0x8b9c, 0x8b9e, + 0x8b9f, 0x8c38, 0x8c39, 0x8c3d, 0x8c3e, 0x8c45, 0x8c47, 0x8c49, + 0x8c4b, 0x8c4f, 0x8c51, 0x8c53, 0x8c54, 0x8c57, 0x8c58, 0x8c5b, + 0x8c5d, 0x8c59, 0x8c63, 0x8c64, 0x8c66, 0x8c68, 0x8c69, 0x8c6d, + 0x8c73, 0x8c75, 0x8c76, 0x8c7b, 0x8c7e, 0x8c86, + /* 0x5f */ + 0x8c87, 0x8c8b, 0x8c90, 0x8c92, 0x8c93, 0x8c99, 0x8c9b, 0x8c9c, + 0x8ca4, 0x8cb9, 0x8cba, 0x8cc5, 0x8cc6, 0x8cc9, 0x8ccb, 0x8ccf, + 0x8cd6, 0x8cd5, 0x8cd9, 0x8cdd, 0x8ce1, 0x8ce8, 0x8cec, 0x8cef, + 0x8cf0, 0x8cf2, 0x8cf5, 0x8cf7, 0x8cf8, 0x8cfe, 0x8cff, 0x8d01, + 0x8d03, 0x8d09, 0x8d12, 0x8d17, 0x8d1b, 0x8d65, 0x8d69, 0x8d6c, + 0x8d6e, 0x8d7f, 0x8d82, 0x8d84, 0x8d88, 0x8d8d, 0x8d90, 0x8d91, + 0x8d95, 0x8d9e, 0x8d9f, 0x8da0, 0x8da6, 0x8dab, 0x8dac, 0x8daf, + 0x8db2, 0x8db5, 0x8db7, 0x8db9, 0x8dbb, 0x8dc0, 0x8dc5, 0x8dc6, + 0x8dc7, 0x8dc8, 0x8dca, 0x8dce, 0x8dd1, 0x8dd4, 0x8dd5, 0x8dd7, + 0x8dd9, 0x8de4, 0x8de5, 0x8de7, 0x8dec, 0x8df0, 0x8dbc, 0x8df1, + 0x8df2, 0x8df4, 0x8dfd, 0x8e01, 0x8e04, 0x8e05, 0x8e06, 0x8e0b, + 0x8e11, 0x8e14, 0x8e16, 0x8e20, 0x8e21, 0x8e22, + /* 0x60 */ + 0x8e23, 0x8e26, 0x8e27, 0x8e31, 0x8e33, 0x8e36, 0x8e37, 0x8e38, + 0x8e39, 0x8e3d, 0x8e40, 0x8e41, 0x8e4b, 0x8e4d, 0x8e4e, 0x8e4f, + 0x8e54, 0x8e5b, 0x8e5c, 0x8e5d, 0x8e5e, 0x8e61, 0x8e62, 0x8e69, + 0x8e6c, 0x8e6d, 0x8e6f, 0x8e70, 0x8e71, 0x8e79, 0x8e7a, 0x8e7b, + 0x8e82, 0x8e83, 0x8e89, 0x8e90, 0x8e92, 0x8e95, 0x8e9a, 0x8e9b, + 0x8e9d, 0x8e9e, 0x8ea2, 0x8ea7, 0x8ea9, 0x8ead, 0x8eae, 0x8eb3, + 0x8eb5, 0x8eba, 0x8ebb, 0x8ec0, 0x8ec1, 0x8ec3, 0x8ec4, 0x8ec7, + 0x8ecf, 0x8ed1, 0x8ed4, 0x8edc, 0x8ee8, 0x8eee, 0x8ef0, 0x8ef1, + 0x8ef7, 0x8ef9, 0x8efa, 0x8eed, 0x8f00, 0x8f02, 0x8f07, 0x8f08, + 0x8f0f, 0x8f10, 0x8f16, 0x8f17, 0x8f18, 0x8f1e, 0x8f20, 0x8f21, + 0x8f23, 0x8f25, 0x8f27, 0x8f28, 0x8f2c, 0x8f2d, 0x8f2e, 0x8f34, + 0x8f35, 0x8f36, 0x8f37, 0x8f3a, 0x8f40, 0x8f41, + /* 0x61 */ + 0x8f43, 0x8f47, 0x8f4f, 0x8f51, 0x8f52, 0x8f53, 0x8f54, 0x8f55, + 0x8f58, 0x8f5d, 0x8f5e, 0x8f65, 0x8f9d, 0x8fa0, 0x8fa1, 0x8fa4, + 0x8fa5, 0x8fa6, 0x8fb5, 0x8fb6, 0x8fb8, 0x8fbe, 0x8fc0, 0x8fc1, + 0x8fc6, 0x8fca, 0x8fcb, 0x8fcd, 0x8fd0, 0x8fd2, 0x8fd3, 0x8fd5, + 0x8fe0, 0x8fe3, 0x8fe4, 0x8fe8, 0x8fee, 0x8ff1, 0x8ff5, 0x8ff6, + 0x8ffb, 0x8ffe, 0x9002, 0x9004, 0x9008, 0x900c, 0x9018, 0x901b, + 0x9028, 0x9029, 0x902f, 0x902a, 0x902c, 0x902d, 0x9033, 0x9034, + 0x9037, 0x903f, 0x9043, 0x9044, 0x904c, 0x905b, 0x905d, 0x9062, + 0x9066, 0x9067, 0x906c, 0x9070, 0x9074, 0x9079, 0x9085, 0x9088, + 0x908b, 0x908c, 0x908e, 0x9090, 0x9095, 0x9097, 0x9098, 0x9099, + 0x909b, 0x90a0, 0x90a1, 0x90a2, 0x90a5, 0x90b0, 0x90b2, 0x90b3, + 0x90b4, 0x90b6, 0x90bd, 0x90cc, 0x90be, 0x90c3, + /* 0x62 */ + 0x90c4, 0x90c5, 0x90c7, 0x90c8, 0x90d5, 0x90d7, 0x90d8, 0x90d9, + 0x90dc, 0x90dd, 0x90df, 0x90e5, 0x90d2, 0x90f6, 0x90eb, 0x90ef, + 0x90f0, 0x90f4, 0x90fe, 0x90ff, 0x9100, 0x9104, 0x9105, 0x9106, + 0x9108, 0x910d, 0x9110, 0x9114, 0x9116, 0x9117, 0x9118, 0x911a, + 0x911c, 0x911e, 0x9120, 0x9125, 0x9122, 0x9123, 0x9127, 0x9129, + 0x912e, 0x912f, 0x9131, 0x9134, 0x9136, 0x9137, 0x9139, 0x913a, + 0x913c, 0x913d, 0x9143, 0x9147, 0x9148, 0x914f, 0x9153, 0x9157, + 0x9159, 0x915a, 0x915b, 0x9161, 0x9164, 0x9167, 0x916d, 0x9174, + 0x9179, 0x917a, 0x917b, 0x9181, 0x9183, 0x9185, 0x9186, 0x918a, + 0x918e, 0x9191, 0x9193, 0x9194, 0x9195, 0x9198, 0x919e, 0x91a1, + 0x91a6, 0x91a8, 0x91ac, 0x91ad, 0x91ae, 0x91b0, 0x91b1, 0x91b2, + 0x91b3, 0x91b6, 0x91bb, 0x91bc, 0x91bd, 0x91bf, + /* 0x63 */ + 0x91c2, 0x91c3, 0x91c5, 0x91d3, 0x91d4, 0x91d7, 0x91d9, 0x91da, + 0x91de, 0x91e4, 0x91e5, 0x91e9, 0x91ea, 0x91ec, 0x91ed, 0x91ee, + 0x91ef, 0x91f0, 0x91f1, 0x91f7, 0x91f9, 0x91fb, 0x91fd, 0x9200, + 0x9201, 0x9204, 0x9205, 0x9206, 0x9207, 0x9209, 0x920a, 0x920c, + 0x9210, 0x9212, 0x9213, 0x9216, 0x9218, 0x921c, 0x921d, 0x9223, + 0x9224, 0x9225, 0x9226, 0x9228, 0x922e, 0x922f, 0x9230, 0x9233, + 0x9235, 0x9236, 0x9238, 0x9239, 0x923a, 0x923c, 0x923e, 0x9240, + 0x9242, 0x9243, 0x9246, 0x9247, 0x924a, 0x924d, 0x924e, 0x924f, + 0x9251, 0x9258, 0x9259, 0x925c, 0x925d, 0x9260, 0x9261, 0x9265, + 0x9267, 0x9268, 0x9269, 0x926e, 0x926f, 0x9270, 0x9275, 0x9276, + 0x9277, 0x9278, 0x9279, 0x927b, 0x927c, 0x927d, 0x927f, 0x9288, + 0x9289, 0x928a, 0x928d, 0x928e, 0x9292, 0x9297, + /* 0x64 */ + 0x9299, 0x929f, 0x92a0, 0x92a4, 0x92a5, 0x92a7, 0x92a8, 0x92ab, + 0x92af, 0x92b2, 0x92b6, 0x92b8, 0x92ba, 0x92bb, 0x92bc, 0x92bd, + 0x92bf, 0x92c0, 0x92c1, 0x92c2, 0x92c3, 0x92c5, 0x92c6, 0x92c7, + 0x92c8, 0x92cb, 0x92cc, 0x92cd, 0x92ce, 0x92d0, 0x92d3, 0x92d5, + 0x92d7, 0x92d8, 0x92d9, 0x92dc, 0x92dd, 0x92df, 0x92e0, 0x92e1, + 0x92e3, 0x92e5, 0x92e7, 0x92e8, 0x92ec, 0x92ee, 0x92f0, 0x92f9, + 0x92fb, 0x92ff, 0x9300, 0x9302, 0x9308, 0x930d, 0x9311, 0x9314, + 0x9315, 0x931c, 0x931d, 0x931e, 0x931f, 0x9321, 0x9324, 0x9325, + 0x9327, 0x9329, 0x932a, 0x9333, 0x9334, 0x9336, 0x9337, 0x9347, + 0x9348, 0x9349, 0x9350, 0x9351, 0x9352, 0x9355, 0x9357, 0x9358, + 0x935a, 0x935e, 0x9364, 0x9365, 0x9367, 0x9369, 0x936a, 0x936d, + 0x936f, 0x9370, 0x9371, 0x9373, 0x9374, 0x9376, + /* 0x65 */ + 0x937a, 0x937d, 0x937f, 0x9380, 0x9381, 0x9382, 0x9388, 0x938a, + 0x938b, 0x938d, 0x938f, 0x9392, 0x9395, 0x9398, 0x939b, 0x939e, + 0x93a1, 0x93a3, 0x93a4, 0x93a6, 0x93a8, 0x93ab, 0x93b4, 0x93b5, + 0x93b6, 0x93ba, 0x93a9, 0x93c1, 0x93c4, 0x93c5, 0x93c6, 0x93c7, + 0x93c9, 0x93ca, 0x93cb, 0x93cc, 0x93cd, 0x93d3, 0x93d9, 0x93dc, + 0x93de, 0x93df, 0x93e2, 0x93e6, 0x93e7, 0x93f9, 0x93f7, 0x93f8, + 0x93fa, 0x93fb, 0x93fd, 0x9401, 0x9402, 0x9404, 0x9408, 0x9409, + 0x940d, 0x940e, 0x940f, 0x9415, 0x9416, 0x9417, 0x941f, 0x942e, + 0x942f, 0x9431, 0x9432, 0x9433, 0x9434, 0x943b, 0x943f, 0x943d, + 0x9443, 0x9445, 0x9448, 0x944a, 0x944c, 0x9455, 0x9459, 0x945c, + 0x945f, 0x9461, 0x9463, 0x9468, 0x946b, 0x946d, 0x946e, 0x946f, + 0x9471, 0x9472, 0x9484, 0x9483, 0x9578, 0x9579, + /* 0x66 */ + 0x957e, 0x9584, 0x9588, 0x958c, 0x958d, 0x958e, 0x959d, 0x959e, + 0x959f, 0x95a1, 0x95a6, 0x95a9, 0x95ab, 0x95ac, 0x95b4, 0x95b6, + 0x95ba, 0x95bd, 0x95bf, 0x95c6, 0x95c8, 0x95c9, 0x95cb, 0x95d0, + 0x95d1, 0x95d2, 0x95d3, 0x95d9, 0x95da, 0x95dd, 0x95de, 0x95df, + 0x95e0, 0x95e4, 0x95e6, 0x961d, 0x961e, 0x9622, 0x9624, 0x9625, + 0x9626, 0x962c, 0x9631, 0x9633, 0x9637, 0x9638, 0x9639, 0x963a, + 0x963c, 0x963d, 0x9641, 0x9652, 0x9654, 0x9656, 0x9657, 0x9658, + 0x9661, 0x966e, 0x9674, 0x967b, 0x967c, 0x967e, 0x967f, 0x9681, + 0x9682, 0x9683, 0x9684, 0x9689, 0x9691, 0x9696, 0x969a, 0x969d, + 0x969f, 0x96a4, 0x96a5, 0x96a6, 0x96a9, 0x96ae, 0x96af, 0x96b3, + 0x96ba, 0x96ca, 0x96d2, 0x5db2, 0x96d8, 0x96da, 0x96dd, 0x96de, + 0x96df, 0x96e9, 0x96ef, 0x96f1, 0x96fa, 0x9702, + /* 0x67 */ + 0x9703, 0x9705, 0x9709, 0x971a, 0x971b, 0x971d, 0x9721, 0x9722, + 0x9723, 0x9728, 0x9731, 0x9733, 0x9741, 0x9743, 0x974a, 0x974e, + 0x974f, 0x9755, 0x9757, 0x9758, 0x975a, 0x975b, 0x9763, 0x9767, + 0x976a, 0x976e, 0x9773, 0x9776, 0x9777, 0x9778, 0x977b, 0x977d, + 0x977f, 0x9780, 0x9789, 0x9795, 0x9796, 0x9797, 0x9799, 0x979a, + 0x979e, 0x979f, 0x97a2, 0x97ac, 0x97ae, 0x97b1, 0x97b2, 0x97b5, + 0x97b6, 0x97b8, 0x97b9, 0x97ba, 0x97bc, 0x97be, 0x97bf, 0x97c1, + 0x97c4, 0x97c5, 0x97c7, 0x97c9, 0x97ca, 0x97cc, 0x97cd, 0x97ce, + 0x97d0, 0x97d1, 0x97d4, 0x97d7, 0x97d8, 0x97d9, 0x97dd, 0x97de, + 0x97e0, 0x97db, 0x97e1, 0x97e4, 0x97ef, 0x97f1, 0x97f4, 0x97f7, + 0x97f8, 0x97fa, 0x9807, 0x980a, 0x9819, 0x980d, 0x980e, 0x9814, + 0x9816, 0x981c, 0x981e, 0x9820, 0x9823, 0x9826, + /* 0x68 */ + 0x982b, 0x982e, 0x982f, 0x9830, 0x9832, 0x9833, 0x9835, 0x9825, + 0x983e, 0x9844, 0x9847, 0x984a, 0x9851, 0x9852, 0x9853, 0x9856, + 0x9857, 0x9859, 0x985a, 0x9862, 0x9863, 0x9865, 0x9866, 0x986a, + 0x986c, 0x98ab, 0x98ad, 0x98ae, 0x98b0, 0x98b4, 0x98b7, 0x98b8, + 0x98ba, 0x98bb, 0x98bf, 0x98c2, 0x98c5, 0x98c8, 0x98cc, 0x98e1, + 0x98e3, 0x98e5, 0x98e6, 0x98e7, 0x98ea, 0x98f3, 0x98f6, 0x9902, + 0x9907, 0x9908, 0x9911, 0x9915, 0x9916, 0x9917, 0x991a, 0x991b, + 0x991c, 0x991f, 0x9922, 0x9926, 0x9927, 0x992b, 0x9931, 0x9932, + 0x9933, 0x9934, 0x9935, 0x9939, 0x993a, 0x993b, 0x993c, 0x9940, + 0x9941, 0x9946, 0x9947, 0x9948, 0x994d, 0x994e, 0x9954, 0x9958, + 0x9959, 0x995b, 0x995c, 0x995e, 0x995f, 0x9960, 0x999b, 0x999d, + 0x999f, 0x99a6, 0x99b0, 0x99b1, 0x99b2, 0x99b5, + /* 0x69 */ + 0x99b9, 0x99ba, 0x99bd, 0x99bf, 0x99c3, 0x99c9, 0x99d3, 0x99d4, + 0x99d9, 0x99da, 0x99dc, 0x99de, 0x99e7, 0x99ea, 0x99eb, 0x99ec, + 0x99f0, 0x99f4, 0x99f5, 0x99f9, 0x99fd, 0x99fe, 0x9a02, 0x9a03, + 0x9a04, 0x9a0b, 0x9a0c, 0x9a10, 0x9a11, 0x9a16, 0x9a1e, 0x9a20, + 0x9a22, 0x9a23, 0x9a24, 0x9a27, 0x9a2d, 0x9a2e, 0x9a33, 0x9a35, + 0x9a36, 0x9a38, 0x9a47, 0x9a41, 0x9a44, 0x9a4a, 0x9a4b, 0x9a4c, + 0x9a4e, 0x9a51, 0x9a54, 0x9a56, 0x9a5d, 0x9aaa, 0x9aac, 0x9aae, + 0x9aaf, 0x9ab2, 0x9ab4, 0x9ab5, 0x9ab6, 0x9ab9, 0x9abb, 0x9abe, + 0x9abf, 0x9ac1, 0x9ac3, 0x9ac6, 0x9ac8, 0x9ace, 0x9ad0, 0x9ad2, + 0x9ad5, 0x9ad6, 0x9ad7, 0x9adb, 0x9adc, 0x9ae0, 0x9ae4, 0x9ae5, + 0x9ae7, 0x9ae9, 0x9aec, 0x9af2, 0x9af3, 0x9af5, 0x9af9, 0x9afa, + 0x9afd, 0x9aff, 0x9b00, 0x9b01, 0x9b02, 0x9b03, + /* 0x6a */ + 0x9b04, 0x9b05, 0x9b08, 0x9b09, 0x9b0b, 0x9b0c, 0x9b0d, 0x9b0e, + 0x9b10, 0x9b12, 0x9b16, 0x9b19, 0x9b1b, 0x9b1c, 0x9b20, 0x9b26, + 0x9b2b, 0x9b2d, 0x9b33, 0x9b34, 0x9b35, 0x9b37, 0x9b39, 0x9b3a, + 0x9b3d, 0x9b48, 0x9b4b, 0x9b4c, 0x9b55, 0x9b56, 0x9b57, 0x9b5b, + 0x9b5e, 0x9b61, 0x9b63, 0x9b65, 0x9b66, 0x9b68, 0x9b6a, 0x9b6b, + 0x9b6c, 0x9b6d, 0x9b6e, 0x9b73, 0x9b75, 0x9b77, 0x9b78, 0x9b79, + 0x9b7f, 0x9b80, 0x9b84, 0x9b85, 0x9b86, 0x9b87, 0x9b89, 0x9b8a, + 0x9b8b, 0x9b8d, 0x9b8f, 0x9b90, 0x9b94, 0x9b9a, 0x9b9d, 0x9b9e, + 0x9ba6, 0x9ba7, 0x9ba9, 0x9bac, 0x9bb0, 0x9bb1, 0x9bb2, 0x9bb7, + 0x9bb8, 0x9bbb, 0x9bbc, 0x9bbe, 0x9bbf, 0x9bc1, 0x9bc7, 0x9bc8, + 0x9bce, 0x9bd0, 0x9bd7, 0x9bd8, 0x9bdd, 0x9bdf, 0x9be5, 0x9be7, + 0x9bea, 0x9beb, 0x9bef, 0x9bf3, 0x9bf7, 0x9bf8, + /* 0x6b */ + 0x9bf9, 0x9bfa, 0x9bfd, 0x9bff, 0x9c00, 0x9c02, 0x9c0b, 0x9c0f, + 0x9c11, 0x9c16, 0x9c18, 0x9c19, 0x9c1a, 0x9c1c, 0x9c1e, 0x9c22, + 0x9c23, 0x9c26, 0x9c27, 0x9c28, 0x9c29, 0x9c2a, 0x9c31, 0x9c35, + 0x9c36, 0x9c37, 0x9c3d, 0x9c41, 0x9c43, 0x9c44, 0x9c45, 0x9c49, + 0x9c4a, 0x9c4e, 0x9c4f, 0x9c50, 0x9c53, 0x9c54, 0x9c56, 0x9c58, + 0x9c5b, 0x9c5d, 0x9c5e, 0x9c5f, 0x9c63, 0x9c69, 0x9c6a, 0x9c5c, + 0x9c6b, 0x9c68, 0x9c6e, 0x9c70, 0x9c72, 0x9c75, 0x9c77, 0x9c7b, + 0x9ce6, 0x9cf2, 0x9cf7, 0x9cf9, 0x9d0b, 0x9d02, 0x9d11, 0x9d17, + 0x9d18, 0x9d1c, 0x9d1d, 0x9d1e, 0x9d2f, 0x9d30, 0x9d32, 0x9d33, + 0x9d34, 0x9d3a, 0x9d3c, 0x9d45, 0x9d3d, 0x9d42, 0x9d43, 0x9d47, + 0x9d4a, 0x9d53, 0x9d54, 0x9d5f, 0x9d63, 0x9d62, 0x9d65, 0x9d69, + 0x9d6a, 0x9d6b, 0x9d70, 0x9d76, 0x9d77, 0x9d7b, + /* 0x6c */ + 0x9d7c, 0x9d7e, 0x9d83, 0x9d84, 0x9d86, 0x9d8a, 0x9d8d, 0x9d8e, + 0x9d92, 0x9d93, 0x9d95, 0x9d96, 0x9d97, 0x9d98, 0x9da1, 0x9daa, + 0x9dac, 0x9dae, 0x9db1, 0x9db5, 0x9db9, 0x9dbc, 0x9dbf, 0x9dc3, + 0x9dc7, 0x9dc9, 0x9dca, 0x9dd4, 0x9dd5, 0x9dd6, 0x9dd7, 0x9dda, + 0x9dde, 0x9ddf, 0x9de0, 0x9de5, 0x9de7, 0x9de9, 0x9deb, 0x9dee, + 0x9df0, 0x9df3, 0x9df4, 0x9dfe, 0x9e0a, 0x9e02, 0x9e07, 0x9e0e, + 0x9e10, 0x9e11, 0x9e12, 0x9e15, 0x9e16, 0x9e19, 0x9e1c, 0x9e1d, + 0x9e7a, 0x9e7b, 0x9e7c, 0x9e80, 0x9e82, 0x9e83, 0x9e84, 0x9e85, + 0x9e87, 0x9e8e, 0x9e8f, 0x9e96, 0x9e98, 0x9e9b, 0x9e9e, 0x9ea4, + 0x9ea8, 0x9eac, 0x9eae, 0x9eaf, 0x9eb0, 0x9eb3, 0x9eb4, 0x9eb5, + 0x9ec6, 0x9ec8, 0x9ecb, 0x9ed5, 0x9edf, 0x9ee4, 0x9ee7, 0x9eec, + 0x9eed, 0x9eee, 0x9ef0, 0x9ef1, 0x9ef2, 0x9ef5, + /* 0x6d */ + 0x9ef8, 0x9eff, 0x9f02, 0x9f03, 0x9f09, 0x9f0f, 0x9f10, 0x9f11, + 0x9f12, 0x9f14, 0x9f16, 0x9f17, 0x9f19, 0x9f1a, 0x9f1b, 0x9f1f, + 0x9f22, 0x9f26, 0x9f2a, 0x9f2b, 0x9f2f, 0x9f31, 0x9f32, 0x9f34, + 0x9f37, 0x9f39, 0x9f3a, 0x9f3c, 0x9f3d, 0x9f3f, 0x9f41, 0x9f43, + 0x9f44, 0x9f45, 0x9f46, 0x9f47, 0x9f53, 0x9f55, 0x9f56, 0x9f57, + 0x9f58, 0x9f5a, 0x9f5d, 0x9f5e, 0x9f68, 0x9f69, 0x9f6d, 0x9f6e, + 0x9f6f, 0x9f70, 0x9f71, 0x9f73, 0x9f75, 0x9f7a, 0x9f7d, 0x9f8f, + 0x9f90, 0x9f91, 0x9f92, 0x9f94, 0x9f96, 0x9f97, 0x9f9e, 0x9fa1, + 0x9fa2, 0x9fa3, 0x9fa5, +}; + +static int +jisx0212_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 == 0x22) || (c1 >= 0x26 && c1 <= 0x27) || (c1 >= 0x29 && c1 <= 0x2b) || (c1 >= 0x30 && c1 <= 0x6d)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + unsigned short wc = 0xfffd; + if (i < 470) { + if (i < 175) + wc = jisx0212_2uni_page22[i-94]; + } else if (i < 752) { + if (i < 658) + wc = jisx0212_2uni_page26[i-470]; + } else if (i < 1410) { + if (i < 1027) + wc = jisx0212_2uni_page29[i-752]; + } else { + if (i < 7211) + wc = jisx0212_2uni_page30[i-1410]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short jisx0212_2charset[6067] = { + 0x2242, 0x2270, 0x2243, 0x226d, 0x226c, 0x226e, 0x2234, 0x2231, + 0x226b, 0x2244, 0x2a22, 0x2a21, 0x2a24, 0x2a2a, 0x2a23, 0x2a29, + 0x2921, 0x2a2e, 0x2a32, 0x2a31, 0x2a34, 0x2a33, 0x2a40, 0x2a3f, + 0x2a42, 0x2a41, 0x2a50, 0x2a52, 0x2a51, 0x2a54, 0x2a58, 0x2a53, + 0x292c, 0x2a63, 0x2a62, 0x2a65, 0x2a64, 0x2a72, 0x2930, 0x294e, + 0x2b22, 0x2b21, 0x2b24, 0x2b2a, 0x2b23, 0x2b29, 0x2941, 0x2b2e, + 0x2b32, 0x2b31, 0x2b34, 0x2b33, 0x2b40, 0x2b3f, 0x2b42, 0x2b41, + 0x2943, 0x2b50, 0x2b52, 0x2b51, 0x2b54, 0x2b58, 0x2b53, 0x294c, + 0x2b63, 0x2b62, 0x2b65, 0x2b64, 0x2b72, 0x2950, 0x2b73, 0x2a27, + 0x2b27, 0x2a25, 0x2b25, 0x2a28, 0x2b28, 0x2a2b, 0x2b2b, 0x2a2c, + 0x2b2c, 0x2a2f, 0x2b2f, 0x2a2d, 0x2b2d, 0x2a30, 0x2b30, 0x2922, + 0x2942, 0x2a37, 0x2b37, 0x2a36, 0x2b36, 0x2a38, 0x2b38, 0x2a35, + 0x2b35, 0x2a3a, 0x2b3a, 0x2a3b, 0x2b3b, 0x2a3d, 0x2b3d, 0x2a3c, + 0x2a3e, 0x2b3e, 0x2924, 0x2944, 0x2a47, 0x2b47, 0x2a45, 0x2b45, + 0x2a46, 0x2b46, 0x2a44, 0x2945, 0x2926, 0x2946, 0x2a48, 0x2b48, + 0x2a49, 0x2b49, 0x2947, 0x2a4a, 0x2b4a, 0x2a4c, 0x2b4c, 0x2a4b, + 0x2b4b, 0x2929, 0x2949, 0x2928, 0x2948, 0x2a4d, 0x2b4d, 0x2a4f, + 0x2b4f, 0x2a4e, 0x2b4e, 0x294a, 0x292b, 0x294b, 0x2a57, 0x2b57, + 0x2a56, 0x2b56, 0x292d, 0x294d, 0x2a59, 0x2b59, 0x2a5b, 0x2b5b, + 0x2a5a, 0x2b5a, 0x2a5c, 0x2b5c, 0x2a5d, 0x2b5d, 0x2a5f, 0x2b5f, + 0x2a5e, 0x2b5e, 0x2a61, 0x2b61, 0x2a60, 0x2b60, 0x292f, 0x294f, + 0x2a6c, 0x2b6c, 0x2a69, 0x2b69, 0x2a66, 0x2b66, 0x2a6b, 0x2b6b, + 0x2a68, 0x2b68, 0x2a6a, 0x2b6a, 0x2a71, 0x2b71, 0x2a74, 0x2b74, + 0x2a73, 0x2a75, 0x2b75, 0x2a77, 0x2b77, 0x2a76, 0x2b76, 0x2a26, + 0x2b26, 0x2a43, 0x2b43, 0x2a55, 0x2b55, 0x2a67, 0x2b67, 0x2a70, + 0x2b70, 0x2a6d, 0x2b6d, 0x2a6f, 0x2b6f, 0x2a6e, 0x2b6e, 0x2b39, + 0x2230, 0x222f, 0x2232, 0x2236, 0x2235, 0x2233, 0x2238, 0x2239, + 0x2661, 0x2662, 0x2663, 0x2664, 0x2667, 0x2669, 0x266c, 0x2676, + 0x2665, 0x266a, 0x2671, 0x2672, 0x2673, 0x2674, 0x267b, 0x2678, + 0x2675, 0x267a, 0x2677, 0x2679, 0x267c, 0x2742, 0x2743, 0x2744, + 0x2745, 0x2746, 0x2747, 0x2748, 0x2749, 0x274a, 0x274b, 0x274c, + 0x274d, 0x274e, 0x2772, 0x2773, 0x2774, 0x2775, 0x2776, 0x2777, + 0x2778, 0x2779, 0x277a, 0x277b, 0x277c, 0x277d, 0x277e, 0x2271, + 0x226f, 0x3021, 0x3022, 0x3023, 0x3024, 0x3025, 0x3026, 0x3027, + 0x3028, 0x3029, 0x302a, 0x302b, 0x302c, 0x302d, 0x302e, 0x302f, + 0x3030, 0x3031, 0x3032, 0x3033, 0x3034, 0x3035, 0x3036, 0x3037, + 0x3038, 0x3039, 0x303a, 0x303b, 0x303c, 0x303d, 0x303e, 0x303f, + 0x3040, 0x3041, 0x3042, 0x3043, 0x3044, 0x3045, 0x3046, 0x3047, + 0x3048, 0x3049, 0x304a, 0x304b, 0x304c, 0x304d, 0x304e, 0x304f, + 0x3050, 0x3051, 0x3052, 0x3053, 0x3054, 0x3055, 0x3056, 0x3057, + 0x3058, 0x3059, 0x305a, 0x305b, 0x305c, 0x305d, 0x305e, 0x3060, + 0x3061, 0x3062, 0x3063, 0x3064, 0x3065, 0x3066, 0x3067, 0x3068, + 0x3069, 0x306a, 0x306b, 0x306c, 0x306d, 0x306e, 0x306f, 0x3070, + 0x305f, 0x3071, 0x3072, 0x3073, 0x3074, 0x3075, 0x3076, 0x3077, + 0x3078, 0x3079, 0x307a, 0x307b, 0x307c, 0x307d, 0x307e, 0x3121, + 0x3122, 0x3123, 0x3124, 0x3125, 0x3126, 0x3127, 0x3128, 0x3129, + 0x312a, 0x312b, 0x312c, 0x312d, 0x312e, 0x312f, 0x3130, 0x3131, + 0x3132, 0x3133, 0x3134, 0x3135, 0x3136, 0x3137, 0x3138, 0x3139, + 0x313a, 0x313b, 0x313c, 0x313d, 0x313e, 0x313f, 0x3140, 0x3141, + 0x3142, 0x3143, 0x3144, 0x3145, 0x3146, 0x3147, 0x3148, 0x3149, + 0x314a, 0x314b, 0x314c, 0x314d, 0x314e, 0x314f, 0x3150, 0x3151, + 0x3152, 0x3153, 0x3154, 0x3155, 0x3156, 0x3157, 0x3158, 0x3159, + 0x315a, 0x315b, 0x315c, 0x315d, 0x315e, 0x3176, 0x315f, 0x3160, + 0x3161, 0x3162, 0x3163, 0x3164, 0x3165, 0x3166, 0x3167, 0x3168, + 0x3169, 0x316a, 0x316b, 0x316c, 0x316d, 0x316e, 0x316f, 0x3170, + 0x3171, 0x3172, 0x3173, 0x3174, 0x3175, 0x3177, 0x3178, 0x3179, + 0x317a, 0x317b, 0x317c, 0x317d, 0x317e, 0x3221, 0x3222, 0x3223, + 0x3224, 0x3225, 0x3226, 0x3227, 0x3228, 0x3229, 0x322a, 0x322b, + 0x322c, 0x322d, 0x322e, 0x322f, 0x3230, 0x3231, 0x3232, 0x3233, + 0x3234, 0x3235, 0x3236, 0x3237, 0x3238, 0x3239, 0x323a, 0x323b, + 0x323c, 0x323d, 0x323e, 0x323f, 0x3240, 0x3241, 0x3242, 0x3243, + 0x3244, 0x3245, 0x3251, 0x3246, 0x3247, 0x3248, 0x3249, 0x324a, + 0x324b, 0x324c, 0x324d, 0x324e, 0x324f, 0x3250, 0x3252, 0x3253, + 0x3254, 0x3255, 0x3256, 0x3257, 0x3258, 0x3259, 0x325a, 0x325b, + 0x325c, 0x325d, 0x325e, 0x325f, 0x3260, 0x3261, 0x3262, 0x3263, + 0x3264, 0x3265, 0x3266, 0x3267, 0x3268, 0x3269, 0x326a, 0x326b, + 0x326c, 0x326d, 0x326e, 0x326f, 0x3270, 0x3271, 0x3272, 0x3273, + 0x3274, 0x3275, 0x3276, 0x3277, 0x3278, 0x3279, 0x327a, 0x327b, + 0x327c, 0x327d, 0x327e, 0x3321, 0x3322, 0x3323, 0x3324, 0x3325, + 0x3326, 0x3327, 0x3328, 0x3329, 0x332a, 0x332b, 0x332c, 0x332d, + 0x332e, 0x332f, 0x3330, 0x3331, 0x3332, 0x3333, 0x3334, 0x3335, + 0x3336, 0x3337, 0x3338, 0x3339, 0x333a, 0x333b, 0x333c, 0x333d, + 0x333e, 0x333f, 0x3340, 0x3341, 0x3342, 0x3343, 0x3344, 0x3345, + 0x3346, 0x3347, 0x3348, 0x3349, 0x334a, 0x334b, 0x334c, 0x334d, + 0x334e, 0x334f, 0x3350, 0x3351, 0x3352, 0x3353, 0x3354, 0x3355, + 0x3356, 0x3357, 0x3358, 0x3359, 0x335a, 0x335b, 0x335c, 0x335d, + 0x335e, 0x335f, 0x3360, 0x3361, 0x3362, 0x3363, 0x3364, 0x3365, + 0x3366, 0x3367, 0x3368, 0x3369, 0x336a, 0x336b, 0x336c, 0x336d, + 0x336e, 0x336f, 0x3370, 0x3371, 0x3372, 0x3373, 0x3374, 0x3375, + 0x3376, 0x3377, 0x3378, 0x3379, 0x337a, 0x337b, 0x337c, 0x337d, + 0x337e, 0x3421, 0x3422, 0x3423, 0x3424, 0x3425, 0x3426, 0x3427, + 0x3428, 0x3429, 0x342a, 0x342b, 0x342c, 0x342d, 0x342e, 0x342f, + 0x3430, 0x3431, 0x3432, 0x3433, 0x3434, 0x3435, 0x3436, 0x3438, + 0x3437, 0x3439, 0x343a, 0x343b, 0x343c, 0x343d, 0x343e, 0x343f, + 0x3440, 0x3441, 0x3442, 0x3443, 0x3444, 0x3445, 0x3446, 0x3447, + 0x3448, 0x3449, 0x344a, 0x344b, 0x344c, 0x344d, 0x344e, 0x344f, + 0x3450, 0x3451, 0x3452, 0x3453, 0x3454, 0x3455, 0x3456, 0x3457, + 0x3458, 0x3459, 0x345a, 0x345b, 0x345c, 0x345d, 0x345e, 0x345f, + 0x3460, 0x3461, 0x3462, 0x3463, 0x3464, 0x3465, 0x3466, 0x3467, + 0x3468, 0x3469, 0x346a, 0x346b, 0x346c, 0x346d, 0x346e, 0x346f, + 0x3470, 0x3471, 0x3472, 0x3473, 0x3474, 0x3475, 0x3476, 0x3477, + 0x3478, 0x3479, 0x347a, 0x347b, 0x347c, 0x347d, 0x347e, 0x3521, + 0x3522, 0x3523, 0x3524, 0x3525, 0x3526, 0x3527, 0x3528, 0x3529, + 0x352a, 0x352b, 0x352c, 0x352d, 0x352e, 0x352f, 0x3530, 0x3531, + 0x3532, 0x3533, 0x3534, 0x3535, 0x3536, 0x3537, 0x3538, 0x3539, + 0x353a, 0x353b, 0x353c, 0x353d, 0x353e, 0x353f, 0x3540, 0x3541, + 0x3542, 0x3543, 0x3544, 0x3545, 0x3546, 0x3547, 0x3548, 0x3549, + 0x354a, 0x354b, 0x354c, 0x354d, 0x354e, 0x354f, 0x3550, 0x3551, + 0x3552, 0x3553, 0x3554, 0x3555, 0x3556, 0x3557, 0x3558, 0x3559, + 0x355a, 0x355b, 0x355c, 0x355d, 0x355e, 0x355f, 0x3560, 0x3561, + 0x3562, 0x3563, 0x3564, 0x3565, 0x3566, 0x3567, 0x3568, 0x3569, + 0x356a, 0x356b, 0x356c, 0x356d, 0x356e, 0x356f, 0x3570, 0x3571, + 0x3572, 0x3573, 0x3574, 0x3575, 0x3576, 0x3577, 0x3578, 0x3579, + 0x357a, 0x357b, 0x357c, 0x357d, 0x357e, 0x3621, 0x3622, 0x3623, + 0x3624, 0x3625, 0x3626, 0x3627, 0x3628, 0x3629, 0x362a, 0x362b, + 0x362c, 0x362d, 0x362e, 0x362f, 0x3630, 0x3631, 0x3632, 0x3633, + 0x3634, 0x3635, 0x3636, 0x3637, 0x3638, 0x3639, 0x363a, 0x363b, + 0x363c, 0x363d, 0x363e, 0x363f, 0x3640, 0x3641, 0x3642, 0x3643, + 0x3644, 0x3645, 0x3646, 0x3647, 0x3648, 0x3649, 0x364a, 0x364b, + 0x364c, 0x364d, 0x364e, 0x364f, 0x3650, 0x3651, 0x3652, 0x3653, + 0x3654, 0x3655, 0x3656, 0x3657, 0x3658, 0x3659, 0x365a, 0x365b, + 0x365c, 0x365d, 0x365e, 0x365f, 0x3660, 0x3661, 0x3662, 0x3663, + 0x3664, 0x3665, 0x3666, 0x3667, 0x3668, 0x3669, 0x366a, 0x366b, + 0x366c, 0x366d, 0x3670, 0x3671, 0x366e, 0x366f, 0x3672, 0x3673, + 0x3674, 0x3675, 0x3676, 0x3677, 0x3678, 0x3679, 0x367a, 0x367b, + 0x367d, 0x367e, 0x367c, 0x3721, 0x3722, 0x3723, 0x3724, 0x3725, + 0x3726, 0x3727, 0x3728, 0x3729, 0x372a, 0x372b, 0x372c, 0x372d, + 0x372e, 0x372f, 0x3730, 0x3731, 0x3732, 0x3733, 0x3734, 0x3735, + 0x3736, 0x3737, 0x3738, 0x3739, 0x373a, 0x373b, 0x373c, 0x373d, + 0x373e, 0x373f, 0x3740, 0x3741, 0x3742, 0x3743, 0x3744, 0x3745, + 0x3746, 0x3747, 0x3748, 0x3749, 0x374a, 0x374b, 0x374c, 0x374d, + 0x374e, 0x374f, 0x3750, 0x3751, 0x3752, 0x3753, 0x3754, 0x3755, + 0x3756, 0x3757, 0x3760, 0x3758, 0x3759, 0x375a, 0x375b, 0x375c, + 0x375d, 0x375e, 0x375f, 0x3761, 0x3762, 0x3763, 0x3764, 0x3765, + 0x3766, 0x3767, 0x3768, 0x3769, 0x376a, 0x376b, 0x376c, 0x376d, + 0x377e, 0x376e, 0x376f, 0x3770, 0x3771, 0x3772, 0x3773, 0x3774, + 0x3775, 0x3776, 0x3777, 0x3778, 0x3779, 0x377a, 0x377b, 0x377c, + 0x377d, 0x3821, 0x3822, 0x3823, 0x3824, 0x3825, 0x3826, 0x3827, + 0x3828, 0x3829, 0x382a, 0x382b, 0x382c, 0x382d, 0x382e, 0x382f, + 0x3830, 0x3831, 0x3832, 0x3833, 0x3834, 0x3835, 0x3836, 0x3837, + 0x3838, 0x3839, 0x383a, 0x383b, 0x383c, 0x383d, 0x383e, 0x383f, + 0x3840, 0x3841, 0x3842, 0x3843, 0x3844, 0x3845, 0x3846, 0x3847, + 0x3848, 0x3849, 0x384a, 0x384b, 0x384c, 0x384d, 0x384e, 0x3850, + 0x3851, 0x384f, 0x3852, 0x3853, 0x3854, 0x3855, 0x3856, 0x3857, + 0x3858, 0x3859, 0x385a, 0x385b, 0x385c, 0x385d, 0x385e, 0x385f, + 0x3860, 0x3861, 0x3862, 0x3863, 0x3864, 0x3865, 0x3867, 0x3868, + 0x3869, 0x386a, 0x386b, 0x386c, 0x386d, 0x386e, 0x386f, 0x3870, + 0x3871, 0x3872, 0x3873, 0x3874, 0x3875, 0x3876, 0x3877, 0x3878, + 0x3879, 0x387a, 0x387b, 0x387c, 0x387d, 0x387e, 0x3921, 0x3922, + 0x3923, 0x3924, 0x3925, 0x3926, 0x3927, 0x3928, 0x3929, 0x392a, + 0x392b, 0x392c, 0x392d, 0x392e, 0x392f, 0x3930, 0x3931, 0x3932, + 0x3933, 0x3934, 0x3935, 0x3936, 0x3937, 0x3938, 0x3939, 0x393a, + 0x393b, 0x393c, 0x393d, 0x393e, 0x393f, 0x3940, 0x3941, 0x3942, + 0x3943, 0x3944, 0x3945, 0x3946, 0x3947, 0x3948, 0x3949, 0x394a, + 0x394b, 0x394c, 0x394d, 0x394e, 0x394f, 0x3950, 0x3951, 0x3952, + 0x3953, 0x3954, 0x3955, 0x3956, 0x3957, 0x3958, 0x3959, 0x395a, + 0x395b, 0x395c, 0x395d, 0x395e, 0x395f, 0x3960, 0x3961, 0x3962, + 0x3963, 0x3964, 0x3965, 0x3966, 0x3967, 0x3968, 0x3969, 0x396a, + 0x396b, 0x396c, 0x396d, 0x396e, 0x396f, 0x3970, 0x3971, 0x3972, + 0x3973, 0x3974, 0x3975, 0x3976, 0x3977, 0x3978, 0x3979, 0x397a, + 0x397b, 0x397c, 0x397d, 0x397e, 0x3a21, 0x3a22, 0x3a23, 0x3a24, + 0x3a25, 0x3a26, 0x3a27, 0x3a28, 0x3a29, 0x3a2a, 0x3a2b, 0x3a2c, + 0x3a2d, 0x3a2e, 0x3a2f, 0x3a30, 0x3a31, 0x3a33, 0x3a34, 0x3a35, + 0x3a36, 0x3a37, 0x3a38, 0x3a32, 0x3a39, 0x3a3a, 0x3a3b, 0x3a3c, + 0x3a3d, 0x3a3e, 0x3a3f, 0x3a40, 0x3a41, 0x3a42, 0x3a43, 0x3a44, + 0x3a45, 0x3a46, 0x3a47, 0x3a48, 0x3a49, 0x3a4a, 0x3a4b, 0x3a4c, + 0x3a4d, 0x3a4e, 0x3a4f, 0x3a50, 0x3a51, 0x3a52, 0x3a53, 0x3a54, + 0x3a55, 0x3a56, 0x3a57, 0x3a58, 0x3a59, 0x3a5a, 0x3a5b, 0x3a5c, + 0x3a5d, 0x3a5e, 0x3a5f, 0x3a60, 0x3a61, 0x3a62, 0x3a63, 0x3a64, + 0x3a65, 0x3a66, 0x3a67, 0x3a68, 0x3a69, 0x3a6a, 0x3a6b, 0x3a6c, + 0x3a6d, 0x3a6e, 0x3a6f, 0x3a70, 0x3a71, 0x3a72, 0x3a73, 0x3a74, + 0x3a75, 0x3a76, 0x3a77, 0x3a78, 0x3a79, 0x3a7a, 0x3a7b, 0x3a7c, + 0x3a7d, 0x3a7e, 0x3b21, 0x3b22, 0x3b23, 0x3b24, 0x3b25, 0x3b26, + 0x3b27, 0x3b28, 0x3b29, 0x3b2a, 0x3b2b, 0x3b2c, 0x3b2d, 0x3b2e, + 0x3b2f, 0x3b30, 0x3b31, 0x3b32, 0x3b33, 0x3b34, 0x3b35, 0x3b36, + 0x3b37, 0x3b38, 0x3b39, 0x3b3a, 0x3b3b, 0x3b3d, 0x3b3c, 0x3b3e, + 0x3b3f, 0x3b40, 0x3b41, 0x3b42, 0x3b43, 0x3b44, 0x3b45, 0x3b47, + 0x3b48, 0x3b49, 0x3b4a, 0x3b46, 0x3b4b, 0x3b4c, 0x3b4d, 0x3b4e, + 0x3b4f, 0x3b50, 0x3b51, 0x3b52, 0x3b53, 0x3b57, 0x3b55, 0x3b54, + 0x3b56, 0x3b58, 0x3b59, 0x3b5a, 0x3b5b, 0x3b5c, 0x3b5d, 0x3b5e, + 0x3b5f, 0x3b60, 0x3b61, 0x3b62, 0x3b63, 0x3b64, 0x3b65, 0x3b66, + 0x3b67, 0x3b68, 0x3b69, 0x3b6a, 0x3b6b, 0x3b6c, 0x3b6d, 0x3b6e, + 0x3b6f, 0x3b70, 0x3b71, 0x3b72, 0x6674, 0x3b73, 0x3b74, 0x3b75, + 0x3b76, 0x3b77, 0x3b78, 0x3b7a, 0x3b79, 0x3b7b, 0x3b7c, 0x3b7d, + 0x3b7e, 0x3c21, 0x3c22, 0x3c23, 0x3c24, 0x3c25, 0x3c26, 0x3c27, + 0x3c28, 0x3c29, 0x3c2a, 0x3c2b, 0x3c2c, 0x3c2e, 0x3c2d, 0x3c2f, + 0x3c30, 0x3c31, 0x3c34, 0x3c32, 0x3c33, 0x3c35, 0x3c36, 0x3c37, + 0x3c38, 0x3c39, 0x3c3a, 0x3c3b, 0x3c3c, 0x3c3d, 0x3c3e, 0x3c3f, + 0x3c40, 0x3c41, 0x3c42, 0x3c43, 0x3c44, 0x3c45, 0x3c46, 0x3c47, + 0x3c48, 0x3c49, 0x3c4a, 0x3c4b, 0x3c4c, 0x3c4d, 0x3c4e, 0x3c4f, + 0x3c50, 0x3c52, 0x3c51, 0x3c53, 0x3c54, 0x3c55, 0x3c56, 0x3c57, + 0x3c58, 0x3c59, 0x3c5a, 0x3c5b, 0x3c5c, 0x3c5d, 0x3c5e, 0x3c5f, + 0x3c60, 0x3c61, 0x3c62, 0x3c63, 0x3c64, 0x3c65, 0x3c66, 0x3c67, + 0x3c68, 0x3c69, 0x3c6a, 0x3c6b, 0x3c6c, 0x3c6d, 0x3c6e, 0x3c6f, + 0x3c70, 0x3c71, 0x3c72, 0x3c73, 0x3c74, 0x3c75, 0x3c76, 0x3c77, + 0x3c78, 0x3c79, 0x3c7a, 0x3c7b, 0x3c7c, 0x3c7d, 0x3c7e, 0x3d21, + 0x3d22, 0x3d23, 0x3d24, 0x3d25, 0x3d26, 0x3d27, 0x3d28, 0x3d29, + 0x3d2a, 0x3d2b, 0x3d2c, 0x3d2d, 0x3d2e, 0x3d2f, 0x3d32, 0x3d30, + 0x3d31, 0x3d33, 0x3d34, 0x3d35, 0x3d36, 0x3d37, 0x3d38, 0x3d39, + 0x3d3a, 0x3d3b, 0x3d3c, 0x3d3d, 0x3d3e, 0x3d3f, 0x3d40, 0x3d41, + 0x3d42, 0x3d43, 0x3d44, 0x3d45, 0x3d46, 0x3d47, 0x3d48, 0x3d49, + 0x3d4a, 0x3d4b, 0x3d4c, 0x3d4d, 0x3d4e, 0x3d4f, 0x3d50, 0x3d51, + 0x3d52, 0x3d53, 0x3d54, 0x3d55, 0x3d56, 0x3d57, 0x3d58, 0x3d59, + 0x3d5a, 0x3d5b, 0x3d5c, 0x3d5d, 0x3d5e, 0x3d5f, 0x3d60, 0x3d61, + 0x3d62, 0x3d63, 0x3d64, 0x3d65, 0x3d66, 0x3d67, 0x3d68, 0x3d69, + 0x3d6a, 0x3d6b, 0x3d6c, 0x3d6d, 0x3d6e, 0x3d6f, 0x3d70, 0x3d71, + 0x3d72, 0x3d73, 0x3d74, 0x3d75, 0x3d76, 0x3d77, 0x3d78, 0x3d79, + 0x3d7a, 0x3d7b, 0x3d7c, 0x3d7d, 0x3d7e, 0x3e21, 0x3e22, 0x3e23, + 0x3e24, 0x3e25, 0x3e26, 0x3e27, 0x3e28, 0x3e29, 0x3e2a, 0x3e2b, + 0x3e2c, 0x3e2d, 0x3e2e, 0x3e2f, 0x3e30, 0x3e31, 0x3e32, 0x3e33, + 0x3e34, 0x3e35, 0x3e36, 0x3e37, 0x3e38, 0x3e39, 0x3e3a, 0x3e3b, + 0x3e3c, 0x3e3d, 0x3e3e, 0x3e3f, 0x3e40, 0x3e41, 0x3e42, 0x3e43, + 0x3e44, 0x3e45, 0x3e46, 0x3e47, 0x3e48, 0x3e49, 0x3e4a, 0x3e4b, + 0x3e4c, 0x3e4d, 0x3e4e, 0x3e4f, 0x3e50, 0x3e51, 0x3e52, 0x3e53, + 0x3e54, 0x3e55, 0x3e56, 0x3e57, 0x3e58, 0x3e59, 0x3e5a, 0x3e5b, + 0x3e5c, 0x3e5d, 0x3e5e, 0x3e5f, 0x3e60, 0x3e61, 0x3e62, 0x3e63, + 0x3e64, 0x3e65, 0x3e66, 0x3e67, 0x3e68, 0x3e69, 0x3e6a, 0x3e6b, + 0x3e6c, 0x3e6d, 0x3e6e, 0x3e6f, 0x3e70, 0x3e71, 0x3e72, 0x3e73, + 0x3e74, 0x3e75, 0x3e76, 0x3e77, 0x3e78, 0x3e79, 0x3e7a, 0x3e7b, + 0x3e7e, 0x3e7c, 0x3e7d, 0x3f21, 0x3f22, 0x3f23, 0x3f24, 0x3f25, + 0x3f26, 0x3f27, 0x3f28, 0x3f29, 0x3f2a, 0x3f2b, 0x3f2c, 0x3f2d, + 0x3f2e, 0x3f2f, 0x3f30, 0x3f31, 0x3f32, 0x3f33, 0x3f34, 0x3f35, + 0x3f36, 0x3f37, 0x3f38, 0x3f39, 0x3f3a, 0x3f3b, 0x3f3c, 0x3f3d, + 0x3f3e, 0x3f3f, 0x3f40, 0x3f41, 0x3f42, 0x3f43, 0x3f44, 0x3f45, + 0x3f46, 0x3f47, 0x3f48, 0x3f49, 0x3f4a, 0x3f4b, 0x3f4c, 0x3f4d, + 0x3f4e, 0x3f4f, 0x3f50, 0x3f51, 0x3f52, 0x3f53, 0x3f54, 0x3f55, + 0x3f56, 0x3f57, 0x3f58, 0x3f59, 0x3f5a, 0x3f5b, 0x3f5c, 0x3f5d, + 0x3f5e, 0x3f5f, 0x3f60, 0x3f61, 0x3f62, 0x3f63, 0x3f64, 0x3f65, + 0x3f66, 0x3f67, 0x3f68, 0x3f69, 0x3f6a, 0x3f6b, 0x3f6c, 0x3f6d, + 0x3f6e, 0x3f6f, 0x3f70, 0x3f71, 0x3f72, 0x3f73, 0x3f74, 0x3f75, + 0x3f76, 0x3f77, 0x3f78, 0x3f79, 0x3f7a, 0x3f7b, 0x3f7c, 0x3f7d, + 0x3f7e, 0x4021, 0x4022, 0x4023, 0x4024, 0x4025, 0x4026, 0x4027, + 0x4028, 0x4029, 0x402a, 0x402b, 0x402c, 0x402d, 0x402e, 0x402f, + 0x4030, 0x4031, 0x4032, 0x4033, 0x4034, 0x4035, 0x4036, 0x4037, + 0x4038, 0x4039, 0x403a, 0x403b, 0x403c, 0x403d, 0x403e, 0x403f, + 0x4040, 0x4041, 0x4042, 0x4043, 0x4044, 0x4045, 0x4046, 0x4047, + 0x4048, 0x4049, 0x404a, 0x404b, 0x404c, 0x404d, 0x404e, 0x404f, + 0x4050, 0x4051, 0x4052, 0x4053, 0x4054, 0x4055, 0x4056, 0x4057, + 0x4058, 0x4059, 0x405a, 0x405b, 0x405c, 0x405d, 0x405e, 0x405f, + 0x4060, 0x4061, 0x4062, 0x4063, 0x4064, 0x4065, 0x4066, 0x4067, + 0x4068, 0x4069, 0x406a, 0x406b, 0x406c, 0x406d, 0x406e, 0x406f, + 0x4070, 0x4071, 0x4072, 0x4073, 0x4074, 0x4075, 0x4076, 0x4077, + 0x4078, 0x4079, 0x407a, 0x407b, 0x407c, 0x407d, 0x407e, 0x4121, + 0x4122, 0x4123, 0x4124, 0x4125, 0x4126, 0x4127, 0x4128, 0x4129, + 0x412a, 0x412b, 0x412c, 0x412d, 0x412e, 0x412f, 0x4130, 0x4131, + 0x4132, 0x4133, 0x4134, 0x4135, 0x4136, 0x4137, 0x4138, 0x4139, + 0x413a, 0x413b, 0x413c, 0x413d, 0x413e, 0x413f, 0x4140, 0x4141, + 0x4142, 0x4143, 0x4144, 0x4145, 0x4146, 0x4147, 0x4148, 0x4149, + 0x414a, 0x414b, 0x414c, 0x414d, 0x414e, 0x414f, 0x4150, 0x4151, + 0x4152, 0x4153, 0x4154, 0x4155, 0x4156, 0x4157, 0x4158, 0x4159, + 0x415a, 0x415b, 0x415c, 0x415d, 0x415e, 0x415f, 0x4160, 0x4161, + 0x4162, 0x4163, 0x4164, 0x4165, 0x4166, 0x4167, 0x4168, 0x4169, + 0x416a, 0x416b, 0x416c, 0x416d, 0x416e, 0x416f, 0x4170, 0x4171, + 0x4172, 0x4173, 0x4174, 0x4175, 0x4176, 0x4177, 0x4178, 0x4179, + 0x417a, 0x417b, 0x417c, 0x417d, 0x417e, 0x4221, 0x4222, 0x4223, + 0x4224, 0x4225, 0x4226, 0x4227, 0x4228, 0x4229, 0x422a, 0x422b, + 0x422c, 0x422d, 0x422e, 0x4230, 0x422f, 0x4231, 0x4232, 0x4233, + 0x4234, 0x4235, 0x4237, 0x4236, 0x4238, 0x4239, 0x423a, 0x423b, + 0x423c, 0x423d, 0x423e, 0x4240, 0x4241, 0x4242, 0x4244, 0x4245, + 0x4247, 0x4248, 0x4249, 0x424a, 0x424c, 0x4243, 0x4246, 0x424b, + 0x424d, 0x424e, 0x424f, 0x4250, 0x4251, 0x4252, 0x4253, 0x4254, + 0x4255, 0x4256, 0x4257, 0x4258, 0x4259, 0x425a, 0x425b, 0x425c, + 0x425d, 0x425e, 0x425f, 0x4260, 0x4261, 0x4262, 0x4263, 0x4264, + 0x4265, 0x4266, 0x4267, 0x4268, 0x4269, 0x426a, 0x426b, 0x426c, + 0x426d, 0x423f, 0x426e, 0x426f, 0x4270, 0x4271, 0x4272, 0x4273, + 0x4274, 0x4275, 0x4276, 0x4277, 0x4278, 0x4279, 0x427a, 0x427b, + 0x427c, 0x427d, 0x427e, 0x4321, 0x4322, 0x4323, 0x4324, 0x4325, + 0x4326, 0x4327, 0x4328, 0x4329, 0x432a, 0x432b, 0x432c, 0x432d, + 0x432e, 0x432f, 0x4330, 0x4331, 0x4332, 0x4333, 0x4334, 0x4335, + 0x4336, 0x4337, 0x4339, 0x433a, 0x433b, 0x433c, 0x433d, 0x433e, + 0x433f, 0x4340, 0x4341, 0x4342, 0x4343, 0x4344, 0x4345, 0x4346, + 0x4347, 0x4348, 0x4338, 0x434a, 0x434b, 0x434c, 0x434d, 0x434f, + 0x434e, 0x4350, 0x4351, 0x4352, 0x4353, 0x4354, 0x4355, 0x4356, + 0x4357, 0x4358, 0x4359, 0x435a, 0x435b, 0x4349, 0x435c, 0x435d, + 0x435e, 0x435f, 0x4360, 0x4361, 0x4362, 0x4363, 0x4364, 0x4365, + 0x4366, 0x4367, 0x4368, 0x4369, 0x436a, 0x436b, 0x436c, 0x436d, + 0x436e, 0x436f, 0x4370, 0x4371, 0x4372, 0x4373, 0x4374, 0x4375, + 0x4376, 0x4377, 0x4378, 0x4379, 0x437a, 0x437b, 0x437c, 0x437d, + 0x437e, 0x4421, 0x4422, 0x4423, 0x4424, 0x4425, 0x4426, 0x4427, + 0x4428, 0x4429, 0x442a, 0x442b, 0x442c, 0x442d, 0x442e, 0x442f, + 0x4430, 0x4431, 0x4432, 0x4433, 0x4434, 0x4435, 0x4436, 0x4437, + 0x4438, 0x4439, 0x443a, 0x443b, 0x443c, 0x443d, 0x443e, 0x443f, + 0x4440, 0x4441, 0x4442, 0x4443, 0x4444, 0x4445, 0x4446, 0x4447, + 0x4448, 0x4449, 0x444a, 0x444b, 0x444c, 0x444d, 0x444e, 0x444f, + 0x4450, 0x4451, 0x4452, 0x4453, 0x4454, 0x4455, 0x4456, 0x4457, + 0x4458, 0x4459, 0x445a, 0x445b, 0x445c, 0x445d, 0x445e, 0x445f, + 0x4460, 0x4461, 0x4462, 0x4463, 0x4464, 0x4465, 0x4466, 0x4467, + 0x4468, 0x4469, 0x446a, 0x446b, 0x446c, 0x446d, 0x446e, 0x446f, + 0x4470, 0x4471, 0x4472, 0x4473, 0x4474, 0x4475, 0x4476, 0x4477, + 0x4478, 0x4479, 0x447a, 0x447b, 0x447c, 0x447d, 0x447e, 0x4521, + 0x4522, 0x4523, 0x4524, 0x4525, 0x4526, 0x4527, 0x4528, 0x4529, + 0x452a, 0x452b, 0x452c, 0x452d, 0x452e, 0x452f, 0x4530, 0x4531, + 0x4532, 0x4533, 0x4534, 0x4535, 0x4536, 0x4537, 0x4538, 0x4539, + 0x453a, 0x453b, 0x453c, 0x453d, 0x453e, 0x453f, 0x4540, 0x4541, + 0x4542, 0x4543, 0x4544, 0x4545, 0x4546, 0x4547, 0x4548, 0x4549, + 0x454a, 0x454b, 0x454d, 0x454c, 0x454e, 0x454f, 0x4550, 0x4551, + 0x4552, 0x4553, 0x4554, 0x4555, 0x4556, 0x4557, 0x4558, 0x4559, + 0x455a, 0x455b, 0x455c, 0x455d, 0x455e, 0x455f, 0x4560, 0x4561, + 0x4562, 0x4563, 0x4564, 0x4565, 0x4566, 0x4567, 0x4568, 0x4569, + 0x456a, 0x456b, 0x456c, 0x456d, 0x456e, 0x456f, 0x4570, 0x4571, + 0x4572, 0x4573, 0x4574, 0x4575, 0x4576, 0x4577, 0x4578, 0x4579, + 0x457a, 0x457b, 0x457c, 0x457d, 0x457e, 0x4621, 0x4622, 0x4623, + 0x4624, 0x4625, 0x4626, 0x4627, 0x4628, 0x4629, 0x462a, 0x462b, + 0x462c, 0x462d, 0x462e, 0x462f, 0x4630, 0x4631, 0x4632, 0x4633, + 0x4634, 0x4635, 0x4636, 0x4637, 0x4638, 0x4639, 0x463a, 0x463b, + 0x463c, 0x463d, 0x463e, 0x463f, 0x4640, 0x4641, 0x4642, 0x4643, + 0x4644, 0x4645, 0x4646, 0x4647, 0x4648, 0x4649, 0x464a, 0x464b, + 0x464c, 0x464d, 0x464e, 0x464f, 0x4650, 0x4651, 0x4652, 0x4653, + 0x4654, 0x4655, 0x4656, 0x4657, 0x4658, 0x4659, 0x465a, 0x465b, + 0x465c, 0x465d, 0x465e, 0x465f, 0x4660, 0x4736, 0x4661, 0x4662, + 0x4663, 0x4664, 0x4665, 0x4666, 0x4667, 0x4668, 0x4669, 0x466a, + 0x466b, 0x466c, 0x466d, 0x466e, 0x466f, 0x4670, 0x4671, 0x4672, + 0x4673, 0x4674, 0x4675, 0x4676, 0x4677, 0x4678, 0x4679, 0x467a, + 0x467b, 0x467c, 0x467d, 0x467e, 0x4721, 0x4722, 0x4723, 0x4724, + 0x4725, 0x4726, 0x4727, 0x4728, 0x4729, 0x472a, 0x472b, 0x472c, + 0x472d, 0x472e, 0x472f, 0x4730, 0x4731, 0x4732, 0x4733, 0x4734, + 0x4735, 0x4737, 0x4738, 0x4739, 0x473a, 0x473b, 0x473c, 0x473d, + 0x473e, 0x473f, 0x4740, 0x4741, 0x4742, 0x4743, 0x4744, 0x4745, + 0x4746, 0x4747, 0x4748, 0x4749, 0x474a, 0x474b, 0x474c, 0x474d, + 0x474e, 0x474f, 0x4750, 0x4751, 0x4752, 0x4753, 0x4754, 0x4755, + 0x4756, 0x4757, 0x4758, 0x4759, 0x475a, 0x475b, 0x475c, 0x475d, + 0x475e, 0x475f, 0x4760, 0x4761, 0x4762, 0x4763, 0x4764, 0x4765, + 0x4766, 0x4767, 0x4768, 0x4769, 0x476a, 0x476b, 0x476c, 0x476d, + 0x476e, 0x476f, 0x4770, 0x4771, 0x4772, 0x4773, 0x4774, 0x4775, + 0x4776, 0x4777, 0x4778, 0x4779, 0x477a, 0x477b, 0x477c, 0x477d, + 0x477e, 0x4821, 0x4822, 0x4823, 0x4824, 0x4825, 0x4826, 0x4827, + 0x4828, 0x4829, 0x482a, 0x482b, 0x482c, 0x482d, 0x482e, 0x482f, + 0x4830, 0x4831, 0x4832, 0x4833, 0x4834, 0x4835, 0x4836, 0x4837, + 0x4838, 0x4839, 0x483a, 0x483b, 0x483c, 0x483d, 0x483e, 0x483f, + 0x4840, 0x4841, 0x4842, 0x4843, 0x4844, 0x4845, 0x4846, 0x4847, + 0x4848, 0x4849, 0x484a, 0x484b, 0x484c, 0x4853, 0x484d, 0x484e, + 0x484f, 0x4850, 0x4851, 0x4852, 0x4854, 0x4855, 0x4856, 0x4857, + 0x4858, 0x4859, 0x485a, 0x485b, 0x485c, 0x485d, 0x485e, 0x485f, + 0x4860, 0x4861, 0x4862, 0x4863, 0x4864, 0x4865, 0x4866, 0x4867, + 0x4868, 0x4869, 0x486a, 0x486b, 0x486c, 0x486d, 0x486e, 0x486f, + 0x4870, 0x4871, 0x4872, 0x4873, 0x4874, 0x4875, 0x4876, 0x4877, + 0x4878, 0x4879, 0x487a, 0x487b, 0x487c, 0x487d, 0x487e, 0x4921, + 0x4922, 0x4923, 0x4924, 0x4925, 0x4926, 0x4927, 0x4928, 0x4929, + 0x492a, 0x492b, 0x492c, 0x492d, 0x492e, 0x492f, 0x4930, 0x4931, + 0x4932, 0x4933, 0x4934, 0x4935, 0x4936, 0x4937, 0x4938, 0x4939, + 0x493a, 0x493b, 0x493c, 0x4941, 0x493d, 0x493e, 0x493f, 0x4940, + 0x4942, 0x4943, 0x4944, 0x4945, 0x4946, 0x4947, 0x4948, 0x4949, + 0x494a, 0x494b, 0x494c, 0x494d, 0x494e, 0x494f, 0x4950, 0x4951, + 0x4952, 0x4953, 0x4954, 0x4955, 0x4956, 0x4957, 0x4958, 0x4959, + 0x495a, 0x495b, 0x495c, 0x495d, 0x495e, 0x495f, 0x4960, 0x4961, + 0x4962, 0x4963, 0x4964, 0x4965, 0x4966, 0x4967, 0x4968, 0x4969, + 0x496a, 0x496b, 0x496c, 0x496d, 0x496e, 0x496f, 0x4970, 0x4971, + 0x4972, 0x4973, 0x4974, 0x4975, 0x4976, 0x4977, 0x4978, 0x4979, + 0x497a, 0x497b, 0x497c, 0x497d, 0x497e, 0x4a21, 0x4a22, 0x4a23, + 0x4a24, 0x4a25, 0x4a26, 0x4a27, 0x4a28, 0x4a29, 0x4a2a, 0x4a2b, + 0x4a2c, 0x4a2d, 0x4a2e, 0x4a2f, 0x4a30, 0x4a31, 0x4a32, 0x4a33, + 0x4a34, 0x4a35, 0x4a36, 0x4a37, 0x4a38, 0x4a39, 0x4a3a, 0x4a3b, + 0x4a3c, 0x4a3d, 0x4a3e, 0x4a3f, 0x4a40, 0x4a41, 0x4a42, 0x4a43, + 0x4a44, 0x4a45, 0x4a46, 0x4a47, 0x4a48, 0x4a49, 0x4a4a, 0x4a4b, + 0x4a4c, 0x4a4d, 0x4a4e, 0x4a4f, 0x4a50, 0x4a51, 0x4a52, 0x4a53, + 0x4a54, 0x4a55, 0x4a56, 0x4a57, 0x4a58, 0x4a59, 0x4a5a, 0x4a5b, + 0x4a5c, 0x4a5d, 0x4a5e, 0x4a5f, 0x4a60, 0x4a61, 0x4a62, 0x4a63, + 0x4a64, 0x4a65, 0x4a66, 0x4a67, 0x4a68, 0x4a69, 0x4a6a, 0x4a6b, + 0x4a6c, 0x4a6d, 0x4a6e, 0x4a6f, 0x4a70, 0x4a71, 0x4a72, 0x4a73, + 0x4a74, 0x4a75, 0x4a76, 0x4a77, 0x4a78, 0x4a79, 0x4a7a, 0x4a7b, + 0x4a7c, 0x4a7d, 0x4a7e, 0x4b21, 0x4b22, 0x4b23, 0x4b24, 0x4b25, + 0x4b26, 0x4b27, 0x4b28, 0x4b29, 0x4b2a, 0x4b2b, 0x4b2c, 0x4b2d, + 0x4b2e, 0x4b2f, 0x4b30, 0x4b31, 0x4b32, 0x4b33, 0x4b34, 0x4b35, + 0x4b36, 0x4b37, 0x4b38, 0x4b39, 0x4b3a, 0x4b3b, 0x4b3c, 0x4b3d, + 0x4b3e, 0x4b3f, 0x4b40, 0x4b41, 0x4b42, 0x4b43, 0x4b44, 0x4b45, + 0x4b46, 0x4b47, 0x4b48, 0x4b49, 0x4b4a, 0x4b4b, 0x4b4c, 0x4b4d, + 0x4b4e, 0x4b4f, 0x4b50, 0x4b51, 0x4b52, 0x4b53, 0x4b54, 0x4b55, + 0x4b56, 0x4b57, 0x4b58, 0x4b59, 0x4b5a, 0x4b5b, 0x4b5c, 0x4b5d, + 0x4b5e, 0x4b5f, 0x4b60, 0x4b61, 0x4b62, 0x4b63, 0x4b64, 0x4b65, + 0x4b66, 0x4b67, 0x4b68, 0x4b69, 0x4b6a, 0x4b6b, 0x4b6c, 0x4b6d, + 0x4b6e, 0x4b6f, 0x4b70, 0x4b71, 0x4b72, 0x4b73, 0x4b74, 0x4b75, + 0x4b76, 0x4b77, 0x4b78, 0x4b79, 0x4b7a, 0x4b7b, 0x4b7c, 0x4b7d, + 0x4b7e, 0x4c21, 0x4c22, 0x4c23, 0x4c24, 0x4c25, 0x4c26, 0x4c27, + 0x4c28, 0x4c29, 0x4c2a, 0x4c2b, 0x4c2c, 0x4c2d, 0x4c2e, 0x4c2f, + 0x4c30, 0x4c31, 0x4c32, 0x4c33, 0x4c34, 0x4c35, 0x4c36, 0x4c37, + 0x4c38, 0x4c39, 0x4c3a, 0x4c3b, 0x4c3c, 0x4c3d, 0x4c3e, 0x4c3f, + 0x4c40, 0x4c41, 0x4c42, 0x4c43, 0x4c44, 0x4c45, 0x4c46, 0x4c47, + 0x4c48, 0x4c49, 0x4c4a, 0x4c4b, 0x4c4c, 0x4c4d, 0x4c4e, 0x4c4f, + 0x4c50, 0x4c51, 0x4c52, 0x4c53, 0x4c54, 0x4c55, 0x4c56, 0x4c57, + 0x4c58, 0x4c59, 0x4c5a, 0x4c5b, 0x4c5c, 0x4c5d, 0x4c5e, 0x4c5f, + 0x4c60, 0x4c61, 0x4c62, 0x4c63, 0x4c64, 0x4c65, 0x4c66, 0x4c67, + 0x4c68, 0x4c69, 0x4c6a, 0x4c6b, 0x4c6c, 0x4c6d, 0x4c6e, 0x4c6f, + 0x4c70, 0x4c71, 0x4c72, 0x4c73, 0x4c74, 0x4c75, 0x4c76, 0x4c77, + 0x4c78, 0x4c79, 0x4c7a, 0x4c7b, 0x4c7c, 0x4c7d, 0x4c7e, 0x4d21, + 0x4d22, 0x4d23, 0x4d24, 0x4d25, 0x4d26, 0x4d27, 0x4d28, 0x4d29, + 0x4d2a, 0x4d2b, 0x4d2c, 0x4d2d, 0x4d2e, 0x4d2f, 0x4d30, 0x4d31, + 0x4d32, 0x4d33, 0x4d34, 0x4d35, 0x4d36, 0x4d37, 0x4d38, 0x4d39, + 0x4d3a, 0x4d3b, 0x4d3c, 0x4d3d, 0x4d3e, 0x4d3f, 0x4d40, 0x4d41, + 0x4d42, 0x4d43, 0x4d44, 0x4d45, 0x4d46, 0x4d47, 0x4d48, 0x4d49, + 0x4d4a, 0x4d4b, 0x4d4c, 0x4d4d, 0x4d4e, 0x4d4f, 0x4d50, 0x4d51, + 0x4d52, 0x4d53, 0x4d54, 0x4d55, 0x4d56, 0x4d57, 0x4d58, 0x4d59, + 0x4d5a, 0x4d5b, 0x4d5c, 0x4d5d, 0x4d5e, 0x4d5f, 0x4d60, 0x4d61, + 0x4d62, 0x4d63, 0x4d64, 0x4d65, 0x4d66, 0x4d67, 0x4d68, 0x4d69, + 0x4d6a, 0x4d6b, 0x4d6c, 0x4d6d, 0x4d6e, 0x4d6f, 0x4d70, 0x4d71, + 0x4d72, 0x4d73, 0x4d74, 0x4d75, 0x4d76, 0x4d77, 0x4d78, 0x4d79, + 0x4d7a, 0x4d7b, 0x4d7c, 0x4d7d, 0x4d7e, 0x4e21, 0x4e22, 0x4e24, + 0x4e25, 0x4e26, 0x4e27, 0x4e28, 0x4e29, 0x4e23, 0x4e2a, 0x4e2b, + 0x4e2c, 0x4e2d, 0x4e2e, 0x4e2f, 0x4e30, 0x4e31, 0x4e32, 0x4e33, + 0x4e34, 0x4e35, 0x4e36, 0x4e37, 0x4e38, 0x4e39, 0x4e3a, 0x4e3b, + 0x4e3c, 0x4e3d, 0x4e3e, 0x4e3f, 0x4e40, 0x4e41, 0x4e42, 0x4e43, + 0x4e44, 0x4e45, 0x4e46, 0x4e47, 0x4e48, 0x4e49, 0x4e4a, 0x4e4b, + 0x4e4c, 0x4e4d, 0x4e4e, 0x4e4f, 0x4e50, 0x4e51, 0x4e52, 0x4e53, + 0x4e54, 0x4e55, 0x4e56, 0x4e57, 0x4e58, 0x4e59, 0x4e5a, 0x4e5b, + 0x4e5c, 0x4e5d, 0x4e5e, 0x4e5f, 0x4e60, 0x4e61, 0x4e62, 0x4e63, + 0x4e64, 0x4e65, 0x4e66, 0x4e67, 0x4e68, 0x4e69, 0x4e6a, 0x4e6b, + 0x4e6c, 0x4e6d, 0x4e6e, 0x4e6f, 0x4e70, 0x4e71, 0x4e72, 0x4e73, + 0x4e74, 0x4e75, 0x4e76, 0x4e77, 0x4e78, 0x4e79, 0x4e7a, 0x4e7b, + 0x4e7c, 0x4e7d, 0x4e7e, 0x4f21, 0x4f22, 0x4f23, 0x4f24, 0x4f25, + 0x4f26, 0x4f27, 0x4f28, 0x4f29, 0x4f2a, 0x4f2b, 0x4f2c, 0x4f2d, + 0x4f2e, 0x4f2f, 0x4f30, 0x4f31, 0x4f32, 0x4f33, 0x4f34, 0x4f35, + 0x4f36, 0x4f37, 0x4f38, 0x4f39, 0x4f3a, 0x4f3b, 0x4f3c, 0x4f3d, + 0x4f3e, 0x4f3f, 0x4f40, 0x4f41, 0x4f42, 0x4f43, 0x4f44, 0x4f45, + 0x4f46, 0x4f47, 0x4f48, 0x4f49, 0x4f4a, 0x4f4b, 0x4f4c, 0x4f4d, + 0x4f4e, 0x4f4f, 0x4f50, 0x4f51, 0x4f52, 0x4f53, 0x4f54, 0x4f55, + 0x4f56, 0x4f57, 0x4f58, 0x4f59, 0x4f5a, 0x4f5b, 0x4f5c, 0x4f5d, + 0x4f5e, 0x4f5f, 0x4f60, 0x4f61, 0x4f62, 0x4f63, 0x4f64, 0x4f65, + 0x4f66, 0x4f67, 0x4f68, 0x4f69, 0x4f6a, 0x4f6b, 0x4f6c, 0x4f6d, + 0x4f6e, 0x4f6f, 0x4f70, 0x4f71, 0x4f72, 0x4f74, 0x4f75, 0x4f76, + 0x4f73, 0x4f77, 0x4f78, 0x4f79, 0x4f7a, 0x4f7b, 0x4f7c, 0x4f7d, + 0x4f7e, 0x5021, 0x5022, 0x5023, 0x5024, 0x5025, 0x5026, 0x5027, + 0x5028, 0x5029, 0x502a, 0x502b, 0x502c, 0x502e, 0x502f, 0x5030, + 0x5031, 0x502d, 0x5032, 0x5033, 0x5034, 0x5035, 0x5037, 0x5038, + 0x5039, 0x503a, 0x503b, 0x5036, 0x503c, 0x503d, 0x503e, 0x503f, + 0x5040, 0x5041, 0x5042, 0x5043, 0x5044, 0x5045, 0x5046, 0x5047, + 0x5048, 0x5049, 0x504a, 0x504b, 0x504c, 0x504d, 0x504e, 0x504f, + 0x5050, 0x5051, 0x5052, 0x5053, 0x5054, 0x5055, 0x5056, 0x5057, + 0x5058, 0x5059, 0x505a, 0x505b, 0x505c, 0x505d, 0x505e, 0x505f, + 0x5060, 0x5061, 0x5062, 0x5063, 0x5064, 0x5065, 0x5066, 0x5067, + 0x5068, 0x5069, 0x506a, 0x506b, 0x506c, 0x506d, 0x506e, 0x506f, + 0x5070, 0x5071, 0x5072, 0x5073, 0x5074, 0x5075, 0x5076, 0x5077, + 0x5078, 0x5079, 0x507a, 0x507b, 0x507c, 0x507d, 0x507e, 0x5121, + 0x5122, 0x5123, 0x5124, 0x5125, 0x5126, 0x5127, 0x5128, 0x5129, + 0x512a, 0x512b, 0x512c, 0x512d, 0x512e, 0x512f, 0x5130, 0x5131, + 0x5132, 0x5133, 0x5134, 0x5135, 0x5136, 0x5137, 0x5138, 0x5139, + 0x513a, 0x513b, 0x513c, 0x513d, 0x513e, 0x513f, 0x5140, 0x5141, + 0x5142, 0x5143, 0x5144, 0x5145, 0x5146, 0x5147, 0x5148, 0x5149, + 0x514a, 0x514b, 0x514c, 0x514d, 0x514e, 0x514f, 0x5150, 0x5151, + 0x5152, 0x5153, 0x5154, 0x5155, 0x5156, 0x5157, 0x5158, 0x5159, + 0x515a, 0x515b, 0x515c, 0x515d, 0x515e, 0x515f, 0x5160, 0x5161, + 0x5162, 0x5163, 0x5164, 0x5165, 0x5166, 0x5167, 0x5168, 0x5169, + 0x516a, 0x516b, 0x516c, 0x516d, 0x516e, 0x516f, 0x5170, 0x5171, + 0x5172, 0x5173, 0x5174, 0x5175, 0x5176, 0x5177, 0x5178, 0x5179, + 0x517a, 0x517b, 0x517c, 0x517d, 0x517e, 0x5221, 0x5222, 0x5223, + 0x5224, 0x5225, 0x5226, 0x5227, 0x5228, 0x5229, 0x522a, 0x522b, + 0x522c, 0x522d, 0x522e, 0x522f, 0x5230, 0x5231, 0x5232, 0x5233, + 0x5234, 0x5235, 0x5236, 0x5237, 0x5238, 0x5239, 0x523a, 0x523b, + 0x523c, 0x523d, 0x523e, 0x523f, 0x5240, 0x5241, 0x5242, 0x5243, + 0x5244, 0x5245, 0x5246, 0x5247, 0x5248, 0x5249, 0x524a, 0x524b, + 0x524c, 0x524d, 0x524e, 0x524f, 0x5250, 0x5251, 0x5252, 0x5253, + 0x5254, 0x5255, 0x5256, 0x5257, 0x5258, 0x5259, 0x525a, 0x525b, + 0x525c, 0x525d, 0x525e, 0x525f, 0x5260, 0x5261, 0x5262, 0x5263, + 0x5264, 0x5265, 0x5266, 0x5267, 0x5268, 0x5269, 0x526a, 0x526b, + 0x526c, 0x526d, 0x526e, 0x526f, 0x5270, 0x5271, 0x5272, 0x5273, + 0x5274, 0x5276, 0x5277, 0x5278, 0x5275, 0x5279, 0x527a, 0x527b, + 0x527c, 0x527d, 0x527e, 0x5321, 0x5322, 0x5323, 0x5324, 0x5325, + 0x5326, 0x5327, 0x5328, 0x5329, 0x532a, 0x532b, 0x532c, 0x532d, + 0x532e, 0x532f, 0x5330, 0x5331, 0x5332, 0x5333, 0x5334, 0x5335, + 0x5336, 0x5337, 0x5338, 0x5339, 0x533a, 0x533b, 0x533c, 0x533d, + 0x533e, 0x533f, 0x5340, 0x5341, 0x5342, 0x5343, 0x5344, 0x5345, + 0x5346, 0x5347, 0x5348, 0x5349, 0x534a, 0x534b, 0x534c, 0x534d, + 0x534e, 0x534f, 0x5350, 0x5351, 0x5352, 0x5353, 0x5354, 0x5355, + 0x5356, 0x5357, 0x5358, 0x5359, 0x535a, 0x535b, 0x535c, 0x535d, + 0x535e, 0x535f, 0x5360, 0x5361, 0x5362, 0x5363, 0x5364, 0x5365, + 0x5366, 0x5367, 0x5368, 0x5369, 0x536a, 0x536b, 0x536c, 0x536d, + 0x536e, 0x536f, 0x5370, 0x5371, 0x5372, 0x5373, 0x5374, 0x5375, + 0x5376, 0x5377, 0x5378, 0x5379, 0x537a, 0x537b, 0x537c, 0x537d, + 0x537e, 0x5421, 0x5422, 0x5423, 0x5424, 0x5425, 0x5426, 0x5427, + 0x5428, 0x5429, 0x542a, 0x542b, 0x542c, 0x542d, 0x542e, 0x542f, + 0x5430, 0x5431, 0x5432, 0x5434, 0x5435, 0x5436, 0x5437, 0x5438, + 0x5439, 0x543a, 0x543b, 0x543c, 0x543d, 0x543e, 0x5433, 0x543f, + 0x5440, 0x5441, 0x5442, 0x5443, 0x5444, 0x5445, 0x5446, 0x5447, + 0x5448, 0x5449, 0x544a, 0x544b, 0x544c, 0x544d, 0x544e, 0x544f, + 0x5450, 0x5451, 0x5452, 0x5453, 0x5454, 0x5455, 0x5456, 0x5457, + 0x5458, 0x5459, 0x545a, 0x545b, 0x545c, 0x545d, 0x545e, 0x545f, + 0x5460, 0x5461, 0x5462, 0x5463, 0x5464, 0x5465, 0x5466, 0x5467, + 0x5468, 0x5469, 0x546a, 0x546c, 0x546b, 0x546d, 0x546e, 0x546f, + 0x5470, 0x5471, 0x5472, 0x5473, 0x5474, 0x5475, 0x5476, 0x5477, + 0x5478, 0x5479, 0x547a, 0x547b, 0x547c, 0x547d, 0x547e, 0x5521, + 0x5522, 0x5523, 0x5524, 0x5525, 0x5526, 0x5527, 0x5528, 0x5529, + 0x552a, 0x552b, 0x552c, 0x552d, 0x552e, 0x552f, 0x5530, 0x5531, + 0x5532, 0x5533, 0x5534, 0x5535, 0x5536, 0x5537, 0x5538, 0x5539, + 0x553a, 0x553b, 0x553c, 0x553d, 0x553e, 0x553f, 0x5540, 0x5541, + 0x5542, 0x5543, 0x5544, 0x5545, 0x5546, 0x5547, 0x5548, 0x5549, + 0x554a, 0x554b, 0x554c, 0x554d, 0x554e, 0x554f, 0x5550, 0x5551, + 0x5552, 0x5553, 0x5554, 0x5555, 0x5556, 0x5557, 0x5558, 0x5559, + 0x555a, 0x555b, 0x555c, 0x555d, 0x555e, 0x555f, 0x5560, 0x5561, + 0x5562, 0x5563, 0x5564, 0x5565, 0x5566, 0x5567, 0x5568, 0x5569, + 0x556a, 0x556b, 0x556c, 0x556d, 0x556e, 0x556f, 0x5570, 0x5571, + 0x5572, 0x5573, 0x5574, 0x5575, 0x5576, 0x5577, 0x5578, 0x5579, + 0x557a, 0x557b, 0x557c, 0x557d, 0x557e, 0x5621, 0x5622, 0x5623, + 0x5624, 0x5625, 0x5626, 0x5627, 0x5628, 0x5629, 0x562a, 0x562b, + 0x562c, 0x562d, 0x562e, 0x562f, 0x5630, 0x5631, 0x5632, 0x5633, + 0x5634, 0x5635, 0x5636, 0x5637, 0x5638, 0x5639, 0x563a, 0x563b, + 0x563c, 0x563d, 0x563e, 0x563f, 0x5640, 0x5641, 0x5642, 0x5643, + 0x5644, 0x5645, 0x5647, 0x5648, 0x5649, 0x564a, 0x564b, 0x5646, + 0x564c, 0x564d, 0x564e, 0x564f, 0x5650, 0x5651, 0x5652, 0x5653, + 0x5654, 0x5656, 0x5657, 0x5658, 0x5655, 0x5659, 0x565a, 0x565b, + 0x565c, 0x565d, 0x565e, 0x565f, 0x5660, 0x5661, 0x5662, 0x5663, + 0x5664, 0x5665, 0x5666, 0x5667, 0x5668, 0x5669, 0x566a, 0x566b, + 0x566c, 0x566d, 0x566e, 0x566f, 0x5670, 0x5671, 0x5672, 0x5673, + 0x5674, 0x5675, 0x5676, 0x5677, 0x5678, 0x5679, 0x567a, 0x567b, + 0x567c, 0x567d, 0x567e, 0x5721, 0x5722, 0x5723, 0x5724, 0x5725, + 0x5726, 0x5727, 0x5728, 0x5729, 0x572a, 0x572b, 0x572c, 0x572d, + 0x572e, 0x572f, 0x5730, 0x5731, 0x5732, 0x5733, 0x5734, 0x5735, + 0x5736, 0x5737, 0x5738, 0x5739, 0x573a, 0x573b, 0x573c, 0x573d, + 0x573e, 0x573f, 0x5740, 0x5741, 0x5742, 0x5743, 0x5744, 0x5745, + 0x5746, 0x5747, 0x5748, 0x5749, 0x574a, 0x574b, 0x574c, 0x574d, + 0x574e, 0x574f, 0x5750, 0x5751, 0x5752, 0x5753, 0x5754, 0x5755, + 0x5756, 0x5757, 0x5758, 0x5759, 0x575a, 0x575b, 0x575c, 0x575d, + 0x575e, 0x575f, 0x5760, 0x5761, 0x5762, 0x5764, 0x5765, 0x5766, + 0x5767, 0x5768, 0x5769, 0x576a, 0x576b, 0x576c, 0x576d, 0x576e, + 0x576f, 0x5770, 0x5771, 0x5772, 0x5773, 0x5774, 0x5775, 0x5776, + 0x5777, 0x5778, 0x5779, 0x583e, 0x5763, 0x577a, 0x577b, 0x577c, + 0x577d, 0x577e, 0x5821, 0x5822, 0x5823, 0x5824, 0x5825, 0x5826, + 0x5827, 0x5828, 0x5829, 0x582a, 0x582b, 0x582c, 0x582d, 0x582e, + 0x582f, 0x5830, 0x5831, 0x5832, 0x5833, 0x584c, 0x5834, 0x5835, + 0x5836, 0x5837, 0x5838, 0x5839, 0x583a, 0x583b, 0x583c, 0x583d, + 0x583f, 0x5840, 0x5841, 0x5842, 0x5843, 0x5844, 0x5845, 0x5846, + 0x5847, 0x5848, 0x5849, 0x584a, 0x584b, 0x584d, 0x584e, 0x584f, + 0x5850, 0x5851, 0x5852, 0x5853, 0x5854, 0x5855, 0x5856, 0x5857, + 0x5858, 0x5859, 0x585a, 0x585b, 0x585c, 0x585d, 0x585e, 0x585f, + 0x5860, 0x5861, 0x5862, 0x5863, 0x5864, 0x5865, 0x5866, 0x5867, + 0x5868, 0x5869, 0x586a, 0x586b, 0x586c, 0x586d, 0x586e, 0x586f, + 0x5870, 0x5871, 0x5872, 0x5873, 0x5874, 0x5875, 0x5876, 0x5877, + 0x5878, 0x5879, 0x587a, 0x587b, 0x587c, 0x587d, 0x587e, 0x5921, + 0x5922, 0x5923, 0x5924, 0x5925, 0x5926, 0x5927, 0x5928, 0x592a, + 0x592b, 0x592c, 0x592d, 0x592e, 0x592f, 0x5930, 0x5931, 0x5932, + 0x5933, 0x5934, 0x5935, 0x5936, 0x5937, 0x5938, 0x5939, 0x593a, + 0x593b, 0x593c, 0x5929, 0x593d, 0x593e, 0x593f, 0x5940, 0x5941, + 0x5942, 0x5943, 0x5944, 0x5945, 0x5946, 0x5947, 0x5948, 0x5949, + 0x594a, 0x594b, 0x594c, 0x594d, 0x594e, 0x594f, 0x5950, 0x5951, + 0x5952, 0x5953, 0x5954, 0x5955, 0x5956, 0x5957, 0x5958, 0x5959, + 0x595a, 0x595b, 0x595c, 0x595d, 0x595e, 0x595f, 0x5960, 0x5961, + 0x5962, 0x5963, 0x5964, 0x5965, 0x5966, 0x5974, 0x5967, 0x5968, + 0x5969, 0x596a, 0x596b, 0x596c, 0x596d, 0x596e, 0x596f, 0x5970, + 0x5971, 0x5972, 0x5973, 0x5975, 0x5976, 0x5977, 0x5978, 0x5979, + 0x597a, 0x597b, 0x597c, 0x597d, 0x597e, 0x5a21, 0x5a22, 0x5a23, + 0x5a24, 0x5a25, 0x5a26, 0x5a27, 0x5a28, 0x5a29, 0x5a2a, 0x5a2b, + 0x5a2c, 0x5a2d, 0x5a2e, 0x5a2f, 0x5a30, 0x5a31, 0x5a32, 0x5a33, + 0x5a34, 0x5a35, 0x5a36, 0x3866, 0x5a37, 0x5a38, 0x5a39, 0x5a3a, + 0x5a3b, 0x5a3c, 0x5a3d, 0x5a3e, 0x5a3f, 0x5a40, 0x5a41, 0x5a42, + 0x5a43, 0x5a44, 0x5a45, 0x5a46, 0x5a47, 0x5a48, 0x5a49, 0x5a4a, + 0x5a4b, 0x5a6d, 0x5a4c, 0x5a4d, 0x5a4e, 0x5a4f, 0x5a50, 0x5a51, + 0x5a52, 0x5a53, 0x5a54, 0x5a55, 0x5a56, 0x5a57, 0x5a58, 0x5a59, + 0x5a5a, 0x5a5b, 0x5a5c, 0x5a5d, 0x5a5e, 0x5a5f, 0x5a60, 0x5a61, + 0x5a62, 0x5a63, 0x5a64, 0x5a65, 0x5a66, 0x5a67, 0x5a68, 0x5a69, + 0x5a6a, 0x5a6b, 0x5a6c, 0x5a6e, 0x5a6f, 0x5a70, 0x5a71, 0x5a72, + 0x5a73, 0x5a74, 0x5a75, 0x5a76, 0x5a77, 0x5a78, 0x5a79, 0x5a7a, + 0x5a7b, 0x5a7c, 0x5a7d, 0x5a7e, 0x5b21, 0x5b22, 0x5b23, 0x5b24, + 0x5b25, 0x5b26, 0x5b27, 0x5b28, 0x5b29, 0x5b2a, 0x5b2b, 0x5b2c, + 0x5b2d, 0x5b2e, 0x5b2f, 0x5b30, 0x5b31, 0x5b32, 0x5b33, 0x5b34, + 0x5b35, 0x5b36, 0x5b37, 0x5b38, 0x5b39, 0x5b3a, 0x5b3b, 0x5b3c, + 0x5b3d, 0x5b3e, 0x5b3f, 0x5b40, 0x5b41, 0x5b42, 0x5b43, 0x5b44, + 0x5b45, 0x5b46, 0x5b47, 0x5b48, 0x5b49, 0x5b4a, 0x5b4b, 0x5b4c, + 0x5b4d, 0x5b4e, 0x5b4f, 0x5b50, 0x5b51, 0x5b52, 0x5b53, 0x5b54, + 0x5b55, 0x5b56, 0x5b57, 0x5b58, 0x5b59, 0x5b5a, 0x5b5b, 0x5b5c, + 0x5b5d, 0x5b5e, 0x5b5f, 0x5b60, 0x5b61, 0x5b62, 0x5b63, 0x5b64, + 0x5b65, 0x5b66, 0x5b67, 0x5b68, 0x5b69, 0x5b6a, 0x5b6b, 0x5b6c, + 0x5b6d, 0x5b6e, 0x5b70, 0x5b71, 0x5b72, 0x5b73, 0x5b6f, 0x5b74, + 0x5b75, 0x5b76, 0x5b77, 0x5b78, 0x5b79, 0x5b7a, 0x5b7b, 0x5b7c, + 0x5b7d, 0x5b7e, 0x5c21, 0x5c22, 0x5c23, 0x5c24, 0x5c25, 0x5c26, + 0x5c27, 0x5c28, 0x5c29, 0x5c2a, 0x5c2b, 0x5c2c, 0x5c2d, 0x5c2e, + 0x5c2f, 0x5c30, 0x5c31, 0x5c32, 0x5c33, 0x5c34, 0x5c35, 0x5c36, + 0x5c37, 0x5c38, 0x5c39, 0x5c3a, 0x5c3b, 0x5c3c, 0x5c3d, 0x5c3e, + 0x5c3f, 0x5c40, 0x5c41, 0x5c42, 0x5c43, 0x5c44, 0x5c45, 0x5c46, + 0x5c47, 0x5c48, 0x5c49, 0x5c4a, 0x5c4b, 0x5c4c, 0x5c4d, 0x5c4e, + 0x5c4f, 0x5c50, 0x5c51, 0x5c52, 0x5c53, 0x5c54, 0x5c55, 0x5c56, + 0x5c57, 0x5c58, 0x5c59, 0x5c5a, 0x5c5b, 0x5c5c, 0x5c5d, 0x5c5e, + 0x5c5f, 0x5c60, 0x5c61, 0x5c62, 0x5c63, 0x5c64, 0x5c65, 0x5c66, + 0x5c67, 0x5c68, 0x5c69, 0x5c6a, 0x5c6b, 0x5c6c, 0x5c6d, 0x5c6e, + 0x5c6f, 0x5c70, 0x5c71, 0x5c72, 0x5c73, 0x5c74, 0x5c75, 0x5c76, + 0x5c77, 0x5c78, 0x5c79, 0x5c7a, 0x5c7b, 0x5c7c, 0x5c7d, 0x5c7e, + 0x5d21, 0x5d22, 0x5d23, 0x5d24, 0x5d25, 0x5d26, 0x5d27, 0x5d28, + 0x5d29, 0x5d2a, 0x5d2b, 0x5d2c, 0x5d2d, 0x5d2e, 0x5d2f, 0x5d30, + 0x5d31, 0x5d32, 0x5d33, 0x5d34, 0x5d35, 0x5d36, 0x5d37, 0x5d38, + 0x5d39, 0x5d3a, 0x5d3b, 0x5d3c, 0x5d3d, 0x5d3e, 0x5d3f, 0x5d40, + 0x5d41, 0x5d42, 0x5d43, 0x5d44, 0x5d45, 0x5d46, 0x5d47, 0x5d48, + 0x5d49, 0x5d4a, 0x5d4b, 0x5d4c, 0x5d4d, 0x5d4e, 0x5d4f, 0x5d50, + 0x5d51, 0x5d52, 0x5d53, 0x5d54, 0x5d55, 0x5d56, 0x5d57, 0x5d58, + 0x5d59, 0x5d5a, 0x5d5b, 0x5d5c, 0x5d5d, 0x5d5e, 0x5d5f, 0x5d60, + 0x5d61, 0x5d62, 0x5d63, 0x5d64, 0x5d65, 0x5d66, 0x5d67, 0x5d68, + 0x5d69, 0x5d6a, 0x5d6b, 0x5d6c, 0x5d6d, 0x5d6e, 0x5d6f, 0x5d70, + 0x5d71, 0x5d72, 0x5d73, 0x5d74, 0x5d75, 0x5d76, 0x5d77, 0x5d78, + 0x5d79, 0x5d7a, 0x5d7b, 0x5d7c, 0x5d7d, 0x5d7e, 0x5e21, 0x5e22, + 0x5e23, 0x5e24, 0x5e25, 0x5e26, 0x5e27, 0x5e28, 0x5e29, 0x5e2a, + 0x5e2b, 0x5e2c, 0x5e2d, 0x5e2e, 0x5e2f, 0x5e30, 0x5e31, 0x5e32, + 0x5e33, 0x5e34, 0x5e35, 0x5e36, 0x5e37, 0x5e38, 0x5e39, 0x5e3f, + 0x5e3a, 0x5e3b, 0x5e3c, 0x5e3d, 0x5e3e, 0x5e40, 0x5e41, 0x5e42, + 0x5e43, 0x5e44, 0x5e45, 0x5e46, 0x5e47, 0x5e48, 0x5e49, 0x5e4e, + 0x5e4a, 0x5e4b, 0x5e4c, 0x5e4d, 0x5e4f, 0x5e50, 0x5e51, 0x5e52, + 0x5e53, 0x5e54, 0x5e55, 0x5e56, 0x5e57, 0x5e58, 0x5e59, 0x5e5a, + 0x5e5b, 0x5e5c, 0x5e5d, 0x5e5e, 0x5e5f, 0x5e60, 0x5e61, 0x5e62, + 0x5e63, 0x5e64, 0x5e65, 0x5e66, 0x5e67, 0x5e68, 0x5e69, 0x5e6a, + 0x5e6b, 0x5e6c, 0x5e6d, 0x5e6e, 0x5e6f, 0x5e72, 0x5e70, 0x5e71, + 0x5e73, 0x5e74, 0x5e75, 0x5e76, 0x5e77, 0x5e78, 0x5e79, 0x5e7a, + 0x5e7b, 0x5e7c, 0x5e7d, 0x5e7e, 0x5f21, 0x5f22, 0x5f23, 0x5f24, + 0x5f25, 0x5f26, 0x5f27, 0x5f28, 0x5f29, 0x5f2a, 0x5f2b, 0x5f2c, + 0x5f2d, 0x5f2e, 0x5f2f, 0x5f30, 0x5f32, 0x5f31, 0x5f33, 0x5f34, + 0x5f35, 0x5f36, 0x5f37, 0x5f38, 0x5f39, 0x5f3a, 0x5f3b, 0x5f3c, + 0x5f3d, 0x5f3e, 0x5f3f, 0x5f40, 0x5f41, 0x5f42, 0x5f43, 0x5f44, + 0x5f45, 0x5f46, 0x5f47, 0x5f48, 0x5f49, 0x5f4a, 0x5f4b, 0x5f4c, + 0x5f4d, 0x5f4e, 0x5f4f, 0x5f50, 0x5f51, 0x5f52, 0x5f53, 0x5f54, + 0x5f55, 0x5f56, 0x5f57, 0x5f58, 0x5f59, 0x5f5a, 0x5f5b, 0x5f5c, + 0x5f5d, 0x5f6f, 0x5f5e, 0x5f5f, 0x5f60, 0x5f61, 0x5f62, 0x5f63, + 0x5f64, 0x5f65, 0x5f66, 0x5f67, 0x5f68, 0x5f69, 0x5f6a, 0x5f6b, + 0x5f6c, 0x5f6d, 0x5f6e, 0x5f70, 0x5f71, 0x5f72, 0x5f73, 0x5f74, + 0x5f75, 0x5f76, 0x5f77, 0x5f78, 0x5f79, 0x5f7a, 0x5f7b, 0x5f7c, + 0x5f7d, 0x5f7e, 0x6021, 0x6022, 0x6023, 0x6024, 0x6025, 0x6026, + 0x6027, 0x6028, 0x6029, 0x602a, 0x602b, 0x602c, 0x602d, 0x602e, + 0x602f, 0x6030, 0x6031, 0x6032, 0x6033, 0x6034, 0x6035, 0x6036, + 0x6037, 0x6038, 0x6039, 0x603a, 0x603b, 0x603c, 0x603d, 0x603e, + 0x603f, 0x6040, 0x6041, 0x6042, 0x6043, 0x6044, 0x6045, 0x6046, + 0x6047, 0x6048, 0x6049, 0x604a, 0x604b, 0x604c, 0x604d, 0x604e, + 0x604f, 0x6050, 0x6051, 0x6052, 0x6053, 0x6054, 0x6055, 0x6056, + 0x6057, 0x6058, 0x6059, 0x605a, 0x605b, 0x605c, 0x605d, 0x6064, + 0x605e, 0x605f, 0x6060, 0x6061, 0x6062, 0x6063, 0x6065, 0x6066, + 0x6067, 0x6068, 0x6069, 0x606a, 0x606b, 0x606c, 0x606d, 0x606e, + 0x606f, 0x6070, 0x6071, 0x6072, 0x6073, 0x6074, 0x6075, 0x6076, + 0x6077, 0x6078, 0x6079, 0x607a, 0x607b, 0x607c, 0x607d, 0x607e, + 0x6121, 0x6122, 0x6123, 0x6124, 0x6125, 0x6126, 0x6127, 0x6128, + 0x6129, 0x612a, 0x612b, 0x612c, 0x612d, 0x612e, 0x612f, 0x6130, + 0x6131, 0x6132, 0x6133, 0x6134, 0x6135, 0x6136, 0x6137, 0x6138, + 0x6139, 0x613a, 0x613b, 0x613c, 0x613d, 0x613e, 0x613f, 0x6140, + 0x6141, 0x6142, 0x6143, 0x6144, 0x6145, 0x6146, 0x6147, 0x6148, + 0x6149, 0x614a, 0x614b, 0x614c, 0x614d, 0x614e, 0x614f, 0x6150, + 0x6151, 0x6152, 0x6154, 0x6155, 0x6156, 0x6153, 0x6157, 0x6158, + 0x6159, 0x615a, 0x615b, 0x615c, 0x615d, 0x615e, 0x615f, 0x6160, + 0x6161, 0x6162, 0x6163, 0x6164, 0x6165, 0x6166, 0x6167, 0x6168, + 0x6169, 0x616a, 0x616b, 0x616c, 0x616d, 0x616e, 0x616f, 0x6170, + 0x6171, 0x6172, 0x6173, 0x6174, 0x6175, 0x6176, 0x6177, 0x6178, + 0x6179, 0x617a, 0x617b, 0x617d, 0x617e, 0x6221, 0x6222, 0x6223, + 0x6224, 0x617c, 0x622d, 0x6225, 0x6226, 0x6227, 0x6228, 0x6229, + 0x622a, 0x622b, 0x622c, 0x622f, 0x6230, 0x6231, 0x6232, 0x622e, + 0x6233, 0x6234, 0x6235, 0x6236, 0x6237, 0x6238, 0x6239, 0x623a, + 0x623b, 0x623c, 0x623d, 0x623e, 0x623f, 0x6240, 0x6241, 0x6242, + 0x6243, 0x6245, 0x6246, 0x6244, 0x6247, 0x6248, 0x6249, 0x624a, + 0x624b, 0x624c, 0x624d, 0x624e, 0x624f, 0x6250, 0x6251, 0x6252, + 0x6253, 0x6254, 0x6255, 0x6256, 0x6257, 0x6258, 0x6259, 0x625a, + 0x625b, 0x625c, 0x625d, 0x625e, 0x625f, 0x6260, 0x6261, 0x6262, + 0x6263, 0x6264, 0x6265, 0x6266, 0x6267, 0x6268, 0x6269, 0x626a, + 0x626b, 0x626c, 0x626d, 0x626e, 0x626f, 0x6270, 0x6271, 0x6272, + 0x6273, 0x6274, 0x6275, 0x6276, 0x6277, 0x6278, 0x6279, 0x627a, + 0x627b, 0x627c, 0x627d, 0x627e, 0x6321, 0x6322, 0x6323, 0x6324, + 0x6325, 0x6326, 0x6327, 0x6328, 0x6329, 0x632a, 0x632b, 0x632c, + 0x632d, 0x632e, 0x632f, 0x6330, 0x6331, 0x6332, 0x6333, 0x6334, + 0x6335, 0x6336, 0x6337, 0x6338, 0x6339, 0x633a, 0x633b, 0x633c, + 0x633d, 0x633e, 0x633f, 0x6340, 0x6341, 0x6342, 0x6343, 0x6344, + 0x6345, 0x6346, 0x6347, 0x6348, 0x6349, 0x634a, 0x634b, 0x634c, + 0x634d, 0x634e, 0x634f, 0x6350, 0x6351, 0x6352, 0x6353, 0x6354, + 0x6355, 0x6356, 0x6357, 0x6358, 0x6359, 0x635a, 0x635b, 0x635c, + 0x635d, 0x635e, 0x635f, 0x6360, 0x6361, 0x6362, 0x6363, 0x6364, + 0x6365, 0x6366, 0x6367, 0x6368, 0x6369, 0x636a, 0x636b, 0x636c, + 0x636d, 0x636e, 0x636f, 0x6370, 0x6371, 0x6372, 0x6373, 0x6374, + 0x6375, 0x6376, 0x6377, 0x6378, 0x6379, 0x637a, 0x637b, 0x637c, + 0x637d, 0x637e, 0x6421, 0x6422, 0x6423, 0x6424, 0x6425, 0x6426, + 0x6427, 0x6428, 0x6429, 0x642a, 0x642b, 0x642c, 0x642d, 0x642e, + 0x642f, 0x6430, 0x6431, 0x6432, 0x6433, 0x6434, 0x6435, 0x6436, + 0x6437, 0x6438, 0x6439, 0x643a, 0x643b, 0x643c, 0x643d, 0x643e, + 0x643f, 0x6440, 0x6441, 0x6442, 0x6443, 0x6444, 0x6445, 0x6446, + 0x6447, 0x6448, 0x6449, 0x644a, 0x644b, 0x644c, 0x644d, 0x644e, + 0x644f, 0x6450, 0x6451, 0x6452, 0x6453, 0x6454, 0x6455, 0x6456, + 0x6457, 0x6458, 0x6459, 0x645a, 0x645b, 0x645c, 0x645d, 0x645e, + 0x645f, 0x6460, 0x6461, 0x6462, 0x6463, 0x6464, 0x6465, 0x6466, + 0x6467, 0x6468, 0x6469, 0x646a, 0x646b, 0x646c, 0x646d, 0x646e, + 0x646f, 0x6470, 0x6471, 0x6472, 0x6473, 0x6474, 0x6475, 0x6476, + 0x6477, 0x6478, 0x6479, 0x647a, 0x647b, 0x647c, 0x647d, 0x647e, + 0x6521, 0x6522, 0x6523, 0x6524, 0x6525, 0x6526, 0x6527, 0x6528, + 0x6529, 0x652a, 0x652b, 0x652c, 0x652d, 0x652e, 0x652f, 0x6530, + 0x6531, 0x6532, 0x6533, 0x6534, 0x6535, 0x653b, 0x6536, 0x6537, + 0x6538, 0x6539, 0x653a, 0x653c, 0x653d, 0x653e, 0x653f, 0x6540, + 0x6541, 0x6542, 0x6543, 0x6544, 0x6545, 0x6546, 0x6547, 0x6548, + 0x6549, 0x654a, 0x654b, 0x654c, 0x654d, 0x654f, 0x6550, 0x654e, + 0x6551, 0x6552, 0x6553, 0x6554, 0x6555, 0x6556, 0x6557, 0x6558, + 0x6559, 0x655a, 0x655b, 0x655c, 0x655d, 0x655e, 0x655f, 0x6560, + 0x6561, 0x6562, 0x6563, 0x6564, 0x6565, 0x6566, 0x6568, 0x6567, + 0x6569, 0x656a, 0x656b, 0x656c, 0x656d, 0x656e, 0x656f, 0x6570, + 0x6571, 0x6572, 0x6573, 0x6574, 0x6575, 0x6576, 0x6577, 0x6578, + 0x6579, 0x657a, 0x657c, 0x657b, 0x657d, 0x657e, 0x6621, 0x6622, + 0x6623, 0x6624, 0x6625, 0x6626, 0x6627, 0x6628, 0x6629, 0x662a, + 0x662b, 0x662c, 0x662d, 0x662e, 0x662f, 0x6630, 0x6631, 0x6632, + 0x6633, 0x6634, 0x6635, 0x6636, 0x6637, 0x6638, 0x6639, 0x663a, + 0x663b, 0x663c, 0x663d, 0x663e, 0x663f, 0x6640, 0x6641, 0x6642, + 0x6643, 0x6644, 0x6645, 0x6646, 0x6647, 0x6648, 0x6649, 0x664a, + 0x664b, 0x664c, 0x664d, 0x664e, 0x664f, 0x6650, 0x6651, 0x6652, + 0x6653, 0x6654, 0x6655, 0x6656, 0x6657, 0x6658, 0x6659, 0x665a, + 0x665b, 0x665c, 0x665d, 0x665e, 0x665f, 0x6660, 0x6661, 0x6662, + 0x6663, 0x6664, 0x6665, 0x6666, 0x6667, 0x6668, 0x6669, 0x666a, + 0x666b, 0x666c, 0x666d, 0x666e, 0x666f, 0x6670, 0x6671, 0x6672, + 0x6673, 0x6675, 0x6676, 0x6677, 0x6678, 0x6679, 0x667a, 0x667b, + 0x667c, 0x667d, 0x667e, 0x6721, 0x6722, 0x6723, 0x6724, 0x6725, + 0x6726, 0x6727, 0x6728, 0x6729, 0x672a, 0x672b, 0x672c, 0x672d, + 0x672e, 0x672f, 0x6730, 0x6731, 0x6732, 0x6733, 0x6734, 0x6735, + 0x6736, 0x6737, 0x6738, 0x6739, 0x673a, 0x673b, 0x673c, 0x673d, + 0x673e, 0x673f, 0x6740, 0x6741, 0x6742, 0x6743, 0x6744, 0x6745, + 0x6746, 0x6747, 0x6748, 0x6749, 0x674a, 0x674b, 0x674c, 0x674d, + 0x674e, 0x674f, 0x6750, 0x6751, 0x6752, 0x6753, 0x6754, 0x6755, + 0x6756, 0x6757, 0x6758, 0x6759, 0x675a, 0x675b, 0x675c, 0x675d, + 0x675e, 0x675f, 0x6760, 0x6761, 0x6762, 0x6763, 0x6764, 0x6765, + 0x6766, 0x676a, 0x6767, 0x6768, 0x6769, 0x676b, 0x676c, 0x676d, + 0x676e, 0x676f, 0x6770, 0x6771, 0x6772, 0x6773, 0x6774, 0x6776, + 0x6777, 0x6778, 0x6779, 0x6775, 0x677a, 0x677b, 0x677c, 0x677d, + 0x6828, 0x677e, 0x6821, 0x6822, 0x6823, 0x6824, 0x6825, 0x6826, + 0x6827, 0x6829, 0x682a, 0x682b, 0x682c, 0x682d, 0x682e, 0x682f, + 0x6830, 0x6831, 0x6832, 0x6833, 0x6834, 0x6835, 0x6836, 0x6837, + 0x6838, 0x6839, 0x683a, 0x683b, 0x683c, 0x683d, 0x683e, 0x683f, + 0x6840, 0x6841, 0x6842, 0x6843, 0x6844, 0x6845, 0x6846, 0x6847, + 0x6848, 0x6849, 0x684a, 0x684b, 0x684c, 0x684d, 0x684e, 0x684f, + 0x6850, 0x6851, 0x6852, 0x6853, 0x6854, 0x6855, 0x6856, 0x6857, + 0x6858, 0x6859, 0x685a, 0x685b, 0x685c, 0x685d, 0x685e, 0x685f, + 0x6860, 0x6861, 0x6862, 0x6863, 0x6864, 0x6865, 0x6866, 0x6867, + 0x6868, 0x6869, 0x686a, 0x686b, 0x686c, 0x686d, 0x686e, 0x686f, + 0x6870, 0x6871, 0x6872, 0x6873, 0x6874, 0x6875, 0x6876, 0x6877, + 0x6878, 0x6879, 0x687a, 0x687b, 0x687c, 0x687d, 0x687e, 0x6921, + 0x6922, 0x6923, 0x6924, 0x6925, 0x6926, 0x6927, 0x6928, 0x6929, + 0x692a, 0x692b, 0x692c, 0x692d, 0x692e, 0x692f, 0x6930, 0x6931, + 0x6932, 0x6933, 0x6934, 0x6935, 0x6936, 0x6937, 0x6938, 0x6939, + 0x693a, 0x693b, 0x693c, 0x693d, 0x693e, 0x693f, 0x6940, 0x6941, + 0x6942, 0x6943, 0x6944, 0x6945, 0x6946, 0x6947, 0x6948, 0x6949, + 0x694a, 0x694c, 0x694d, 0x694b, 0x694e, 0x694f, 0x6950, 0x6951, + 0x6952, 0x6953, 0x6954, 0x6955, 0x6956, 0x6957, 0x6958, 0x6959, + 0x695a, 0x695b, 0x695c, 0x695d, 0x695e, 0x695f, 0x6960, 0x6961, + 0x6962, 0x6963, 0x6964, 0x6965, 0x6966, 0x6967, 0x6968, 0x6969, + 0x696a, 0x696b, 0x696c, 0x696d, 0x696e, 0x696f, 0x6970, 0x6971, + 0x6972, 0x6973, 0x6974, 0x6975, 0x6976, 0x6977, 0x6978, 0x6979, + 0x697a, 0x697b, 0x697c, 0x697d, 0x697e, 0x6a21, 0x6a22, 0x6a23, + 0x6a24, 0x6a25, 0x6a26, 0x6a27, 0x6a28, 0x6a29, 0x6a2a, 0x6a2b, + 0x6a2c, 0x6a2d, 0x6a2e, 0x6a2f, 0x6a30, 0x6a31, 0x6a32, 0x6a33, + 0x6a34, 0x6a35, 0x6a36, 0x6a37, 0x6a38, 0x6a39, 0x6a3a, 0x6a3b, + 0x6a3c, 0x6a3d, 0x6a3e, 0x6a3f, 0x6a40, 0x6a41, 0x6a42, 0x6a43, + 0x6a44, 0x6a45, 0x6a46, 0x6a47, 0x6a48, 0x6a49, 0x6a4a, 0x6a4b, + 0x6a4c, 0x6a4d, 0x6a4e, 0x6a4f, 0x6a50, 0x6a51, 0x6a52, 0x6a53, + 0x6a54, 0x6a55, 0x6a56, 0x6a57, 0x6a58, 0x6a59, 0x6a5a, 0x6a5b, + 0x6a5c, 0x6a5d, 0x6a5e, 0x6a5f, 0x6a60, 0x6a61, 0x6a62, 0x6a63, + 0x6a64, 0x6a65, 0x6a66, 0x6a67, 0x6a68, 0x6a69, 0x6a6a, 0x6a6b, + 0x6a6c, 0x6a6d, 0x6a6e, 0x6a6f, 0x6a70, 0x6a71, 0x6a72, 0x6a73, + 0x6a74, 0x6a75, 0x6a76, 0x6a77, 0x6a78, 0x6a79, 0x6a7a, 0x6a7b, + 0x6a7c, 0x6a7d, 0x6a7e, 0x6b21, 0x6b22, 0x6b23, 0x6b24, 0x6b25, + 0x6b26, 0x6b27, 0x6b28, 0x6b29, 0x6b2a, 0x6b2b, 0x6b2c, 0x6b2d, + 0x6b2e, 0x6b2f, 0x6b30, 0x6b31, 0x6b32, 0x6b33, 0x6b34, 0x6b35, + 0x6b36, 0x6b37, 0x6b38, 0x6b39, 0x6b3a, 0x6b3b, 0x6b3c, 0x6b3d, + 0x6b3e, 0x6b3f, 0x6b40, 0x6b41, 0x6b42, 0x6b43, 0x6b44, 0x6b45, + 0x6b46, 0x6b47, 0x6b48, 0x6b49, 0x6b50, 0x6b4a, 0x6b4b, 0x6b4c, + 0x6b4d, 0x6b52, 0x6b4e, 0x6b4f, 0x6b51, 0x6b53, 0x6b54, 0x6b55, + 0x6b56, 0x6b57, 0x6b58, 0x6b59, 0x6b5a, 0x6b5b, 0x6b5c, 0x6b5e, + 0x6b5d, 0x6b5f, 0x6b60, 0x6b61, 0x6b62, 0x6b63, 0x6b64, 0x6b65, + 0x6b66, 0x6b67, 0x6b68, 0x6b69, 0x6b6a, 0x6b6b, 0x6b6d, 0x6b6e, + 0x6b6f, 0x6b6c, 0x6b70, 0x6b71, 0x6b72, 0x6b73, 0x6b74, 0x6b76, + 0x6b75, 0x6b77, 0x6b78, 0x6b79, 0x6b7a, 0x6b7b, 0x6b7c, 0x6b7d, + 0x6b7e, 0x6c21, 0x6c22, 0x6c23, 0x6c24, 0x6c25, 0x6c26, 0x6c27, + 0x6c28, 0x6c29, 0x6c2a, 0x6c2b, 0x6c2c, 0x6c2d, 0x6c2e, 0x6c2f, + 0x6c30, 0x6c31, 0x6c32, 0x6c33, 0x6c34, 0x6c35, 0x6c36, 0x6c37, + 0x6c38, 0x6c39, 0x6c3a, 0x6c3b, 0x6c3c, 0x6c3d, 0x6c3e, 0x6c3f, + 0x6c40, 0x6c41, 0x6c42, 0x6c43, 0x6c44, 0x6c45, 0x6c46, 0x6c47, + 0x6c48, 0x6c49, 0x6c4a, 0x6c4b, 0x6c4c, 0x6c4e, 0x6c4f, 0x6c4d, + 0x6c50, 0x6c51, 0x6c52, 0x6c53, 0x6c54, 0x6c55, 0x6c56, 0x6c57, + 0x6c58, 0x6c59, 0x6c5a, 0x6c5b, 0x6c5c, 0x6c5d, 0x6c5e, 0x6c5f, + 0x6c60, 0x6c61, 0x6c62, 0x6c63, 0x6c64, 0x6c65, 0x6c66, 0x6c67, + 0x6c68, 0x6c69, 0x6c6a, 0x6c6b, 0x6c6c, 0x6c6d, 0x6c6e, 0x6c6f, + 0x6c70, 0x6c71, 0x6c72, 0x6c73, 0x6c74, 0x6c75, 0x6c76, 0x6c77, + 0x6c78, 0x6c79, 0x6c7a, 0x6c7b, 0x6c7c, 0x6c7d, 0x6c7e, 0x6d21, + 0x6d22, 0x6d23, 0x6d24, 0x6d25, 0x6d26, 0x6d27, 0x6d28, 0x6d29, + 0x6d2a, 0x6d2b, 0x6d2c, 0x6d2d, 0x6d2e, 0x6d2f, 0x6d30, 0x6d31, + 0x6d32, 0x6d33, 0x6d34, 0x6d35, 0x6d36, 0x6d37, 0x6d38, 0x6d39, + 0x6d3a, 0x6d3b, 0x6d3c, 0x6d3d, 0x6d3e, 0x6d3f, 0x6d40, 0x6d41, + 0x6d42, 0x6d43, 0x6d44, 0x6d45, 0x6d46, 0x6d47, 0x6d48, 0x6d49, + 0x6d4a, 0x6d4b, 0x6d4c, 0x6d4d, 0x6d4e, 0x6d4f, 0x6d50, 0x6d51, + 0x6d52, 0x6d53, 0x6d54, 0x6d55, 0x6d56, 0x6d57, 0x6d58, 0x6d59, + 0x6d5a, 0x6d5b, 0x6d5c, 0x6d5d, 0x6d5e, 0x6d5f, 0x6d60, 0x6d61, + 0x6d62, 0x6d63, 0x2237, +}; + +static const Summary16 jisx0212_uni2indx_page00[70] = { + /* 0x0000 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0xc652 }, { 7, 0x8500 }, + { 10, 0xffff }, { 26, 0xff7e }, { 40, 0xffff }, { 56, 0xff7f }, + /* 0x0100 */ + { 71, 0xffff }, { 87, 0xffcf }, { 101, 0xcff7 }, { 114, 0xffff }, + { 130, 0x3fff }, { 144, 0xffff }, { 160, 0xffff }, { 176, 0x7fff }, + { 191, 0x0000 }, { 191, 0x0000 }, { 191, 0x0000 }, { 191, 0x0000 }, + { 191, 0xe000 }, { 194, 0x1fff }, { 207, 0x0000 }, { 207, 0x0020 }, + /* 0x0200 */ + { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, + { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, + { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, { 208, 0x0000 }, + { 208, 0x0080 }, { 209, 0x2f00 }, { 214, 0x0000 }, { 214, 0x0000 }, + /* 0x0300 */ + { 214, 0x0000 }, { 214, 0x0000 }, { 214, 0x0000 }, { 214, 0x0000 }, + { 214, 0x0000 }, { 214, 0x0000 }, { 214, 0x0000 }, { 214, 0x0000 }, + { 214, 0xd770 }, { 223, 0x0001 }, { 224, 0xfc00 }, { 230, 0x0001 }, + { 231, 0x7c04 }, { 237, 0x0000 }, { 237, 0x0000 }, { 237, 0x0000 }, + /* 0x0400 */ + { 237, 0xdffc }, { 250, 0x0000 }, { 250, 0x0000 }, { 250, 0x0000 }, + { 250, 0x0000 }, { 250, 0xdffc }, +}; +static const Summary16 jisx0212_uni2indx_page21[3] = { + /* 0x2100 */ + { 263, 0x0000 }, { 263, 0x0040 }, { 264, 0x0004 }, +}; +static const Summary16 jisx0212_uni2indx_page4e[1307] = { + /* 0x4e00 */ + { 265, 0x1034 }, { 269, 0x8004 }, { 271, 0xc918 }, { 277, 0x0021 }, + { 279, 0x0093 }, { 283, 0x1402 }, { 286, 0x0308 }, { 289, 0x8230 }, + { 293, 0x2000 }, { 294, 0x20c0 }, { 297, 0x8000 }, { 298, 0x0200 }, + { 299, 0x0008 }, { 300, 0x0c01 }, { 303, 0x8107 }, { 308, 0xe02a }, + /* 0x4f00 */ + { 314, 0x190d }, { 320, 0x02e4 }, { 325, 0x4000 }, { 326, 0x4aaa }, + { 333, 0x1b05 }, { 339, 0x8154 }, { 344, 0x5409 }, { 349, 0x6782 }, + { 356, 0x5636 }, { 364, 0xc69d }, { 373, 0x0000 }, { 373, 0x7a84 }, + { 380, 0xbb63 }, { 390, 0x1004 }, { 392, 0x0005 }, { 394, 0xb005 }, + /* 0x5000 */ + { 399, 0x5493 }, { 406, 0x7989 }, { 414, 0x4084 }, { 417, 0x082d }, + { 422, 0x5467 }, { 430, 0x828e }, { 436, 0x24cd }, { 443, 0x0003 }, + { 445, 0xc45a }, { 452, 0xd85d }, { 461, 0x8407 }, { 466, 0x2601 }, + { 470, 0x5099 }, { 476, 0xb119 }, { 483, 0x8354 }, { 489, 0x4446 }, + /* 0x5100 */ + { 494, 0x79c8 }, { 502, 0x7a81 }, { 509, 0xb188 }, { 515, 0x033a }, + { 521, 0x8404 }, { 524, 0x81a8 }, { 529, 0x0050 }, { 531, 0x4000 }, + { 532, 0x4818 }, { 536, 0x2100 }, { 538, 0x200a }, { 541, 0xd500 }, + { 546, 0x8104 }, { 549, 0x412e }, { 555, 0x4024 }, { 558, 0x009c }, + /* 0x5200 */ + { 562, 0x0026 }, { 565, 0x016c }, { 570, 0x0104 }, { 572, 0x1026 }, + { 576, 0x0220 }, { 578, 0x95a0 }, { 584, 0x4043 }, { 588, 0x0380 }, + { 591, 0x1425 }, { 596, 0x15e8 }, { 603, 0x80f0 }, { 608, 0x2dc1 }, + { 615, 0x9151 }, { 621, 0x1852 }, { 626, 0x1722 }, { 632, 0x00d3 }, + /* 0x5300 */ + { 637, 0x1c09 }, { 642, 0xd90a }, { 649, 0x3ba0 }, { 656, 0x7025 }, + { 662, 0x1804 }, { 665, 0x0a00 }, { 667, 0x302a }, { 672, 0x4204 }, + { 675, 0x4188 }, { 679, 0x2218 }, { 683, 0x8c12 }, { 688, 0x25b4 }, + { 695, 0x8021 }, { 698, 0x642c }, { 704, 0x00c1 }, { 707, 0x0020 }, + /* 0x5400 */ + { 708, 0x0004 }, { 709, 0x0408 }, { 711, 0x8582 }, { 716, 0x0032 }, + { 719, 0xa098 }, { 724, 0x4000 }, { 725, 0x6ad4 }, { 733, 0x8010 }, + { 735, 0x232a }, { 741, 0x9062 }, { 746, 0x66c2 }, { 753, 0x8e82 }, + { 759, 0x6440 }, { 763, 0x0000 }, { 763, 0x9401 }, { 767, 0xd040 }, + /* 0x5500 */ + { 771, 0x7323 }, { 779, 0x0020 }, { 780, 0x0c00 }, { 782, 0x3864 }, + { 788, 0x2682 }, { 793, 0x4d03 }, { 799, 0x0053 }, { 803, 0x8000 }, + { 804, 0xc146 }, { 810, 0x009e }, { 815, 0x2018 }, { 818, 0x8004 }, + { 820, 0x5a4a }, { 827, 0x498e }, { 834, 0x0204 }, { 836, 0x8040 }, + /* 0x5600 */ + { 838, 0xe520 }, { 844, 0x0207 }, { 848, 0x1000 }, { 849, 0xbaa9 }, + { 858, 0xaa5b }, { 867, 0x4010 }, { 869, 0xa24f }, { 877, 0x0026 }, + { 880, 0x1930 }, { 885, 0xe620 }, { 891, 0x3bc0 }, { 898, 0x408a }, + { 902, 0xbe20 }, { 909, 0xb201 }, { 914, 0x29f2 }, { 922, 0x00c2 }, + /* 0x5700 */ + { 925, 0x1486 }, { 930, 0x2c22 }, { 935, 0xd63d }, { 945, 0xe018 }, + { 950, 0x3060 }, { 954, 0x0004 }, { 955, 0xe9a4 }, { 963, 0x5ebb }, + { 974, 0x100a }, { 977, 0xf6b0 }, { 986, 0x1382 }, { 991, 0x2100 }, + { 993, 0x9180 }, { 997, 0x6020 }, { 1000, 0x22d2 }, { 1006, 0xe161 }, + /* 0x5800 */ + { 1013, 0x3318 }, { 1019, 0xc800 }, { 1022, 0x20c1 }, { 1026, 0x8204 }, + { 1029, 0xb200 }, { 1033, 0x8021 }, { 1036, 0x0192 }, { 1040, 0x9100 }, + { 1043, 0xb783 }, { 1052, 0x2051 }, { 1056, 0x0247 }, { 1061, 0x1006 }, + { 1064, 0x6114 }, { 1069, 0x2455 }, { 1075, 0x0206 }, { 1078, 0x0008 }, + /* 0x5900 */ + { 1079, 0x1860 }, { 1083, 0x201c }, { 1087, 0x811a }, { 1092, 0x8069 }, + { 1097, 0x0048 }, { 1099, 0xea0c }, { 1106, 0xa80a }, { 1111, 0x1a64 }, + { 1117, 0x5800 }, { 1120, 0x80a4 }, { 1124, 0xe090 }, { 1129, 0x1489 }, + { 1134, 0x251a }, { 1140, 0xe004 }, { 1144, 0xc098 }, { 1149, 0x0096 }, + /* 0x5a00 */ + { 1153, 0x7011 }, { 1158, 0x400c }, { 1161, 0x2598 }, { 1167, 0x0001 }, + { 1168, 0x11b0 }, { 1173, 0x4021 }, { 1176, 0x20a8 }, { 1180, 0x4c80 }, + { 1184, 0x0800 }, { 1185, 0xd249 }, { 1192, 0x1085 }, { 1196, 0x8d2e }, + { 1204, 0x8150 }, { 1208, 0x1400 }, { 1210, 0x4421 }, { 1214, 0x2060 }, + /* 0x5b00 */ + { 1217, 0x0103 }, { 1220, 0x2a80 }, { 1224, 0x2022 }, { 1227, 0x0110 }, + { 1229, 0x1802 }, { 1232, 0x4044 }, { 1235, 0xc100 }, { 1238, 0xf000 }, + { 1242, 0x4452 }, { 1247, 0x005b }, { 1252, 0xb300 }, { 1257, 0x1486 }, + { 1262, 0xa003 }, { 1266, 0x07c0 }, { 1271, 0x8001 }, { 1273, 0x2012 }, + /* 0x5c00 */ + { 1276, 0x1000 }, { 1277, 0xc080 }, { 1280, 0x5a48 }, { 1286, 0x0065 }, + { 1290, 0x0000 }, { 1290, 0x1600 }, { 1293, 0x238c }, { 1299, 0x3c31 }, + { 1306, 0x8580 }, { 1310, 0xa004 }, { 1313, 0x044d }, { 1318, 0x0434 }, + { 1322, 0x0a00 }, { 1324, 0x2084 }, { 1327, 0x4000 }, { 1328, 0x0016 }, + /* 0x5d00 */ + { 1331, 0x2042 }, { 1334, 0x0004 }, { 1335, 0x08d8 }, { 1340, 0xa212 }, + { 1345, 0x054c }, { 1350, 0x8222 }, { 1354, 0x2417 }, { 1360, 0xc601 }, + { 1365, 0x050a }, { 1369, 0x8a3c }, { 1376, 0x0881 }, { 1379, 0x0315 }, + { 1384, 0x4888 }, { 1388, 0x0301 }, { 1391, 0x0211 }, { 1394, 0x0300 }, + /* 0x5e00 */ + { 1396, 0x2081 }, { 1399, 0x8134 }, { 1404, 0x4101 }, { 1407, 0x4024 }, + { 1410, 0x0a00 }, { 1412, 0x5943 }, { 1419, 0x7d00 }, { 1425, 0x0001 }, + { 1426, 0x4801 }, { 1429, 0x0000 }, { 1429, 0x1534 }, { 1435, 0xe00a }, + { 1440, 0x5840 }, { 1444, 0x5036 }, { 1450, 0x0820 }, { 1452, 0x0000 }, + /* 0x5f00 */ + { 1452, 0x41c4 }, { 1457, 0x3200 }, { 1460, 0x591e }, { 1468, 0xa851 }, + { 1474, 0x20b1 }, { 1479, 0x0911 }, { 1483, 0x8099 }, { 1488, 0x6534 }, + { 1495, 0xa200 }, { 1498, 0x3040 }, { 1501, 0x9894 }, { 1507, 0x0103 }, + { 1510, 0x0b90 }, { 1515, 0x401f }, { 1521, 0xf706 }, { 1530, 0x144c }, + /* 0x6000 */ + { 1535, 0x2480 }, { 1538, 0x8598 }, { 1544, 0x2010 }, { 1546, 0x0028 }, + { 1548, 0x1381 }, { 1553, 0x20d2 }, { 1558, 0x0082 }, { 1560, 0xc002 }, + { 1563, 0x4544 }, { 1568, 0x612a }, { 1574, 0x0134 }, { 1578, 0x4883 }, + { 1583, 0xcf14 }, { 1591, 0x6a30 }, { 1597, 0x0024 }, { 1599, 0x3124 }, + /* 0x6100 */ + { 1604, 0x1484 }, { 1608, 0x52df }, { 1618, 0x0c04 }, { 1621, 0x02e3 }, + { 1627, 0x0262 }, { 1631, 0x4000 }, { 1632, 0x1001 }, { 1634, 0x9904 }, + { 1639, 0x281b }, { 1645, 0xb18c }, { 1652, 0x2521 }, { 1657, 0x1300 }, + { 1660, 0xc007 }, { 1665, 0xf020 }, { 1670, 0xb2a6 }, { 1678, 0x0000 }, + /* 0x6200 */ + { 1678, 0x009a }, { 1682, 0x1028 }, { 1685, 0x0a8d }, { 1691, 0x2200 }, + { 1693, 0x105c }, { 1698, 0x1457 }, { 1705, 0xa010 }, { 1708, 0x2408 }, + { 1711, 0xe000 }, { 1714, 0x0001 }, { 1715, 0x0140 }, { 1717, 0xc4c8 }, + { 1723, 0x4010 }, { 1725, 0x0460 }, { 1728, 0x0400 }, { 1729, 0x3014 }, + /* 0x6300 */ + { 1733, 0x2c18 }, { 1738, 0x0149 }, { 1742, 0x2600 }, { 1745, 0x1260 }, + { 1749, 0x4c5e }, { 1757, 0x091c }, { 1762, 0x3060 }, { 1766, 0xb132 }, + { 1773, 0x0494 }, { 1777, 0x4631 }, { 1783, 0xe050 }, { 1788, 0x2000 }, + { 1789, 0x4122 }, { 1793, 0x103a }, { 1798, 0x1421 }, { 1802, 0x032c }, + /* 0x6400 */ + { 1807, 0x0600 }, { 1809, 0x4115 }, { 1814, 0x8635 }, { 1821, 0xa021 }, + { 1825, 0x8800 }, { 1827, 0xbc1e }, { 1836, 0x200b }, { 1840, 0x2818 }, + { 1844, 0x80a0 }, { 1847, 0xab03 }, { 1854, 0x114a }, { 1859, 0xe008 }, + { 1863, 0x5e10 }, { 1869, 0x00a3 }, { 1873, 0x2630 }, { 1878, 0x88a1 }, + /* 0x6500 */ + { 1883, 0x8712 }, { 1889, 0xca58 }, { 1896, 0x4244 }, { 1900, 0x3402 }, + { 1904, 0x0288 }, { 1907, 0x8015 }, { 1911, 0x0881 }, { 1914, 0x2400 }, + { 1916, 0x0422 }, { 1919, 0x2124 }, { 1923, 0x4049 }, { 1927, 0x801c }, + { 1931, 0x4304 }, { 1935, 0x8151 }, { 1940, 0x0000 }, { 1940, 0xc235 }, + /* 0x6600 */ + { 1947, 0x2311 }, { 1952, 0x6066 }, { 1958, 0x5e5e }, { 1968, 0x028b }, + { 1973, 0x5461 }, { 1979, 0x1b82 }, { 1985, 0x1c03 }, { 1990, 0xdba8 }, + { 1999, 0x3801 }, { 2003, 0x9e05 }, { 2010, 0x2011 }, { 2013, 0x8826 }, + { 2018, 0xd10d }, { 2025, 0x8810 }, { 2028, 0x5900 }, { 2032, 0x0c00 }, + /* 0x6700 */ + { 2034, 0x40a0 }, { 2037, 0x1208 }, { 2040, 0x0005 }, { 2042, 0x4008 }, + { 2044, 0x11a0 }, { 2048, 0x2030 }, { 2051, 0x5040 }, { 2054, 0x0850 }, + { 2057, 0xc012 }, { 2061, 0x0b4a }, { 2067, 0x0000 }, { 2067, 0x3827 }, + { 2074, 0x032d }, { 2080, 0x1284 }, { 2084, 0x0042 }, { 2086, 0x02c5 }, + /* 0x6800 */ + { 2091, 0x0000 }, { 2091, 0xa210 }, { 2095, 0xb180 }, { 2100, 0x880b }, + { 2105, 0x1430 }, { 2109, 0x09a4 }, { 2114, 0xc800 }, { 2117, 0x1e27 }, + { 2125, 0x0154 }, { 2129, 0x1540 }, { 2133, 0x462a }, { 2139, 0x0804 }, + { 2141, 0x9120 }, { 2145, 0x324b }, { 2152, 0x3d20 }, { 2158, 0x3863 }, + /* 0x6900 */ + { 2165, 0x0640 }, { 2168, 0x00cb }, { 2173, 0x0000 }, { 2173, 0x092a }, + { 2178, 0x4224 }, { 2182, 0x0880 }, { 2184, 0x1378 }, { 2191, 0x8c07 }, + { 2197, 0x2001 }, { 2199, 0x0144 }, { 2202, 0xa962 }, { 2209, 0x1580 }, + { 2213, 0x0120 }, { 2215, 0x00c2 }, { 2218, 0xc024 }, { 2222, 0x402a }, + /* 0x6a00 */ + { 2226, 0x800b }, { 2230, 0x2422 }, { 2234, 0x0111 }, { 2237, 0xc895 }, + { 2244, 0x4660 }, { 2249, 0x0867 }, { 2255, 0x0490 }, { 2258, 0x400a }, + { 2261, 0x0aca }, { 2267, 0xe802 }, { 2272, 0x8820 }, { 2275, 0xe013 }, + { 2281, 0x1340 }, { 2285, 0x3071 }, { 2291, 0x1090 }, { 2294, 0x3007 }, + /* 0x6b00 */ + { 2299, 0x82cc }, { 2305, 0x4883 }, { 2310, 0x9910 }, { 2315, 0x8860 }, + { 2319, 0x2440 }, { 2322, 0x2144 }, { 2326, 0x4881 }, { 2330, 0x6021 }, + { 2334, 0x0024 }, { 2336, 0x8880 }, { 2339, 0x730d }, { 2347, 0x6301 }, + { 2352, 0x1218 }, { 2356, 0x0440 }, { 2358, 0x40ca }, { 2363, 0x8282 }, + /* 0x6c00 */ + { 2367, 0x6234 }, { 2373, 0x8205 }, { 2377, 0x51c0 }, { 2382, 0x8c68 }, + { 2388, 0xac00 }, { 2392, 0x1a14 }, { 2397, 0xa880 }, { 2401, 0x0b50 }, + { 2406, 0x02e0 }, { 2410, 0x91b0 }, { 2416, 0x0000 }, { 2416, 0x0015 }, + { 2419, 0xa044 }, { 2423, 0x1457 }, { 2430, 0x5a81 }, { 2436, 0x0014 }, + /* 0x6d00 */ + { 2438, 0xc490 }, { 2443, 0x040a }, { 2446, 0xc1c0 }, { 2451, 0x9202 }, + { 2455, 0x0000 }, { 2455, 0xc080 }, { 2458, 0x80a2 }, { 2462, 0x1001 }, + { 2464, 0x0084 }, { 2466, 0x01d6 }, { 2472, 0x1400 }, { 2474, 0xa290 }, + { 2479, 0xc510 }, { 2484, 0xa840 }, { 2488, 0x8225 }, { 2493, 0x1051 }, + /* 0x6e00 */ + { 2497, 0x0011 }, { 2499, 0x4000 }, { 2500, 0x0084 }, { 2502, 0x1a44 }, + { 2507, 0x8b30 }, { 2513, 0x709e }, { 2521, 0x010c }, { 2524, 0x2808 }, + { 2527, 0x2000 }, { 2528, 0x0208 }, { 2530, 0x6081 }, { 2534, 0x880a }, + { 2538, 0xe58b }, { 2547, 0x0000 }, { 2547, 0x6800 }, { 2550, 0x2a00 }, + /* 0x6f00 */ + { 2553, 0x3510 }, { 2558, 0x0d40 }, { 2562, 0xa640 }, { 2567, 0x1849 }, + { 2572, 0x8000 }, { 2573, 0x668e }, { 2581, 0x1106 }, { 2585, 0x6000 }, + { 2587, 0x3988 }, { 2593, 0x845d }, { 2600, 0xc1e1 }, { 2607, 0x1061 }, + { 2611, 0x05a0 }, { 2615, 0x4400 }, { 2617, 0x0300 }, { 2619, 0x3221 }, + /* 0x7000 */ + { 2624, 0x20e1 }, { 2629, 0x0080 }, { 2630, 0x8009 }, { 2633, 0x1290 }, + { 2637, 0x4f18 }, { 2644, 0x6030 }, { 2648, 0x5030 }, { 2652, 0x4060 }, + { 2655, 0x0062 }, { 2658, 0x09f0 }, { 2664, 0x0810 }, { 2666, 0x0093 }, + { 2670, 0x0400 }, { 2671, 0x117a }, { 2678, 0x0010 }, { 2679, 0x0400 }, + /* 0x7100 */ + { 2680, 0x98f8 }, { 2688, 0x4000 }, { 2689, 0xa801 }, { 2693, 0x0103 }, + { 2696, 0x0ce2 }, { 2702, 0x5485 }, { 2708, 0x0101 }, { 2710, 0x0200 }, + { 2711, 0x10a1 }, { 2715, 0x0c04 }, { 2718, 0x8005 }, { 2721, 0x840d }, + { 2726, 0x1813 }, { 2731, 0x1648 }, { 2736, 0x0000 }, { 2736, 0x4100 }, + /* 0x7200 */ + { 2738, 0x0381 }, { 2742, 0xa488 }, { 2747, 0x8810 }, { 2750, 0x0310 }, + { 2753, 0xc02e }, { 2759, 0x5469 }, { 2766, 0xc909 }, { 2772, 0x9982 }, + { 2778, 0x6210 }, { 2782, 0x0808 }, { 2784, 0x6100 }, { 2787, 0x4012 }, + { 2790, 0x1282 }, { 2794, 0x8160 }, { 2798, 0x0020 }, { 2799, 0x4c18 }, + /* 0x7300 */ + { 2804, 0x28b4 }, { 2810, 0x430c }, { 2815, 0x1194 }, { 2820, 0x2c26 }, + { 2826, 0x2008 }, { 2828, 0xe145 }, { 2835, 0xdac1 }, { 2843, 0x1282 }, + { 2847, 0x406b }, { 2853, 0xd1a9 }, { 2861, 0x2c65 }, { 2868, 0xb2a0 }, + { 2874, 0x9a60 }, { 2880, 0x224c }, { 2885, 0x02ca }, { 2890, 0xaeb0 }, + /* 0x7400 */ + { 2898, 0x0493 }, { 2903, 0x0c02 }, { 2906, 0xff50 }, { 2916, 0x0203 }, + { 2919, 0x28d9 }, { 2926, 0x2086 }, { 2930, 0x69c4 }, { 2937, 0x0006 }, + { 2939, 0x82e3 }, { 2946, 0x9707 }, { 2954, 0xcf4b }, { 2964, 0x8a26 }, + { 2970, 0x1300 }, { 2973, 0xcd09 }, { 2980, 0x8d10 }, { 2985, 0x9c10 }, + /* 0x7500 */ + { 2990, 0x0040 }, { 2991, 0x00c4 }, { 2994, 0x8693 }, { 3001, 0xe240 }, + { 3006, 0x4189 }, { 3011, 0xc085 }, { 3016, 0x8002 }, { 3018, 0x7e02 }, + { 3025, 0x0022 }, { 3027, 0x122d }, { 3033, 0x0014 }, { 3035, 0x8410 }, + { 3038, 0xd053 }, { 3045, 0x9080 }, { 3048, 0xd093 }, { 3055, 0x0202 }, + /* 0x7600 */ + { 3057, 0x959d }, { 3066, 0x7a6c }, { 3075, 0x2268 }, { 3080, 0x172c }, + { 3087, 0x0e3b }, { 3095, 0x8220 }, { 3098, 0xe030 }, { 3103, 0x0012 }, + { 3105, 0x3022 }, { 3109, 0xb820 }, { 3114, 0x25fd }, { 3124, 0x2000 }, + { 3125, 0x5a22 }, { 3131, 0x0210 }, { 3133, 0x1141 }, { 3137, 0x1243 }, + /* 0x7700 */ + { 3142, 0x4441 }, { 3146, 0x16b4 }, { 3153, 0xe104 }, { 3158, 0x6270 }, + { 3164, 0xe464 }, { 3171, 0xd0c4 }, { 3177, 0x1495 }, { 3183, 0x241d }, + { 3189, 0x3011 }, { 3193, 0x8470 }, { 3198, 0xc484 }, { 3203, 0x4022 }, + { 3206, 0x0208 }, { 3208, 0xc226 }, { 3214, 0x1451 }, { 3219, 0x0913 }, + /* 0x7800 */ + { 3224, 0x6260 }, { 3229, 0x2002 }, { 3231, 0x600e }, { 3236, 0x00a1 }, + { 3239, 0x5198 }, { 3245, 0x5004 }, { 3248, 0x451b }, { 3255, 0x4400 }, + { 3257, 0x8400 }, { 3259, 0xe110 }, { 3264, 0x3112 }, { 3269, 0xa80f }, + { 3276, 0x5380 }, { 3281, 0x886c }, { 3287, 0x0453 }, { 3292, 0x8ccc }, + /* 0x7900 */ + { 3299, 0x1041 }, { 3302, 0xd401 }, { 3307, 0x22a1 }, { 3312, 0xa832 }, + { 3318, 0x8c70 }, { 3324, 0x1912 }, { 3329, 0x0a80 }, { 3332, 0x5a04 }, + { 3337, 0x1800 }, { 3339, 0x197a }, { 3347, 0x8b02 }, { 3352, 0x0912 }, + { 3356, 0x8594 }, { 3362, 0x6450 }, { 3367, 0x2c25 }, { 3373, 0x1102 }, + /* 0x7a00 */ + { 3376, 0x168c }, { 3382, 0x4822 }, { 3386, 0xa882 }, { 3391, 0x0731 }, + { 3397, 0x11b0 }, { 3402, 0xb260 }, { 3408, 0x24a1 }, { 3413, 0x4120 }, + { 3416, 0x0c65 }, { 3422, 0x4013 }, { 3426, 0x1009 }, { 3429, 0x1a28 }, + { 3434, 0x5240 }, { 3438, 0x0802 }, { 3440, 0x1b00 }, { 3444, 0x6812 }, + /* 0x7b00 */ + { 3449, 0x0080 }, { 3450, 0x8010 }, { 3452, 0xee88 }, { 3460, 0xa013 }, + { 3465, 0x4083 }, { 3469, 0x0020 }, { 3470, 0xa651 }, { 3477, 0x008c }, + { 3480, 0x4210 }, { 3483, 0x4843 }, { 3488, 0x9021 }, { 3492, 0x3c65 }, + { 3500, 0x0524 }, { 3504, 0x0ed0 }, { 3510, 0x0500 }, { 3512, 0x5734 }, + /* 0x7c00 */ + { 3520, 0xda5e }, { 3530, 0x0a00 }, { 3532, 0x1161 }, { 3537, 0x065a }, + { 3543, 0x0440 }, { 3545, 0x7e2e }, { 3555, 0x628a }, { 3561, 0x3205 }, + { 3566, 0x80c0 }, { 3569, 0x4010 }, { 3571, 0x0041 }, { 3573, 0x9cc1 }, + { 3580, 0xa390 }, { 3586, 0x26b8 }, { 3593, 0x0a40 }, { 3596, 0x0020 }, + /* 0x7d00 */ + { 3597, 0x8388 }, { 3602, 0x604e }, { 3608, 0x2448 }, { 3612, 0x7002 }, + { 3616, 0x2183 }, { 3621, 0x368a }, { 3628, 0x04a0 }, { 3631, 0x8d01 }, + { 3636, 0x396e }, { 3645, 0x60c2 }, { 3650, 0x04c0 }, { 3653, 0x02c8 }, + { 3657, 0x707c }, { 3665, 0x0280 }, { 3667, 0x2c64 }, { 3673, 0x0662 }, + /* 0x7e00 */ + { 3678, 0x0101 }, { 3680, 0x30a3 }, { 3686, 0xb181 }, { 3692, 0x8048 }, + { 3695, 0x40b0 }, { 3699, 0x8105 }, { 3703, 0xc826 }, { 3709, 0x4108 }, + { 3712, 0x24c2 }, { 3717, 0x6522 }, { 3723, 0x0000 }, { 3723, 0x0000 }, + { 3723, 0x0000 }, { 3723, 0x0000 }, { 3723, 0x0000 }, { 3723, 0x0000 }, + /* 0x7f00 */ + { 3723, 0x0000 }, { 3723, 0x0000 }, { 3723, 0x0000 }, { 3723, 0xf800 }, + { 3728, 0x8098 }, { 3732, 0x380c }, { 3737, 0x207a }, { 3743, 0xe002 }, + { 3747, 0xa801 }, { 3751, 0x10c3 }, { 3756, 0x2446 }, { 3761, 0x9010 }, + { 3764, 0xc109 }, { 3769, 0x8800 }, { 3771, 0xd128 }, { 3777, 0xe404 }, + /* 0x8000 */ + { 3782, 0xe580 }, { 3788, 0xe05a }, { 3795, 0x5051 }, { 3800, 0x56b1 }, + { 3808, 0x0011 }, { 3810, 0x0000 }, { 3810, 0x2051 }, { 3814, 0x0022 }, + { 3816, 0x4102 }, { 3819, 0x5000 }, { 3821, 0x08c0 }, { 3824, 0x0300 }, + { 3826, 0xa100 }, { 3829, 0x01b4 }, { 3834, 0x6001 }, { 3837, 0x464d }, + /* 0x8100 */ + { 3844, 0x0808 }, { 3846, 0x51c0 }, { 3851, 0x1091 }, { 3855, 0x1421 }, + { 3859, 0x14a0 }, { 3863, 0x0084 }, { 3865, 0xa383 }, { 3872, 0x0080 }, + { 3873, 0x4872 }, { 3879, 0x4941 }, { 3884, 0x4004 }, { 3886, 0x0814 }, + { 3889, 0xcc28 }, { 3895, 0x68a0 }, { 3900, 0x1812 }, { 3904, 0xa367 }, + /* 0x8200 */ + { 3913, 0x8009 }, { 3916, 0x2618 }, { 3921, 0x0106 }, { 3924, 0x0414 }, + { 3927, 0xc878 }, { 3934, 0x1042 }, { 3937, 0x2089 }, { 3941, 0xa810 }, + { 3945, 0x469b }, { 3953, 0x0d52 }, { 3959, 0x479b }, { 3968, 0xd495 }, + { 3976, 0x0040 }, { 3977, 0x0421 }, { 3980, 0xa515 }, { 3987, 0x60c0 }, + /* 0x8300 */ + { 3991, 0x0d83 }, { 3997, 0xe800 }, { 4001, 0x7006 }, { 4006, 0x3489 }, + { 4012, 0x609c }, { 4018, 0x00fa }, { 4024, 0x0000 }, { 4024, 0xa101 }, + { 4028, 0x2055 }, { 4033, 0x3b34 }, { 4041, 0x32c0 }, { 4046, 0xc000 }, + { 4048, 0x8281 }, { 4052, 0x2013 }, { 4056, 0x0500 }, { 4058, 0x1340 }, + /* 0x8400 */ + { 4062, 0x8442 }, { 4066, 0x0222 }, { 4069, 0x8000 }, { 4070, 0x0200 }, + { 4071, 0xa5a0 }, { 4077, 0x1746 }, { 4084, 0x04b1 }, { 4089, 0x3159 }, + { 4096, 0x0022 }, { 4098, 0x402c }, { 4102, 0x8740 }, { 4107, 0x6412 }, + { 4112, 0x9185 }, { 4118, 0x1008 }, { 4120, 0x8480 }, { 4123, 0x2c87 }, + /* 0x8500 */ + { 4130, 0x508c }, { 4135, 0x5001 }, { 4138, 0x8cbc }, { 4146, 0x805c }, + { 4151, 0x8040 }, { 4153, 0xf24f }, { 4163, 0x8817 }, { 4169, 0xae00 }, + { 4174, 0x9a62 }, { 4181, 0xa108 }, { 4185, 0x20a5 }, { 4190, 0xf1d0 }, + { 4198, 0x4c84 }, { 4203, 0x8500 }, { 4206, 0x2141 }, { 4210, 0x9048 }, + /* 0x8600 */ + { 4214, 0x6031 }, { 4219, 0x4b07 }, { 4226, 0x0282 }, { 4229, 0x3540 }, + { 4234, 0x0047 }, { 4238, 0x23cc }, { 4245, 0x921f }, { 4253, 0x04e0 }, + { 4257, 0x2100 }, { 4259, 0x1542 }, { 4264, 0x21c2 }, { 4269, 0x83ba }, + { 4277, 0x002b }, { 4281, 0x14a6 }, { 4287, 0x00a9 }, { 4291, 0x3400 }, + /* 0x8700 */ + { 4294, 0xc8b0 }, { 4300, 0xc219 }, { 4306, 0xc10a }, { 4311, 0x7606 }, + { 4318, 0x2029 }, { 4322, 0x2100 }, { 4324, 0x8032 }, { 4328, 0x0806 }, + { 4331, 0x1bf8 }, { 4340, 0x43a9 }, { 4347, 0x7089 }, { 4353, 0xc022 }, + { 4357, 0x4702 }, { 4362, 0x9660 }, { 4368, 0x2c1c }, { 4374, 0x850a }, + /* 0x8800 */ + { 4379, 0x0e4a }, { 4385, 0xdf1d }, { 4396, 0x6100 }, { 4399, 0x1425 }, + { 4404, 0x4f2a }, { 4412, 0x9562 }, { 4419, 0x0211 }, { 4422, 0x0a02 }, + { 4425, 0x0001 }, { 4426, 0x9d00 }, { 4431, 0x0501 }, { 4434, 0x6400 }, + { 4437, 0x7c01 }, { 4443, 0x480e }, { 4448, 0x8080 }, { 4450, 0x00a3 }, + /* 0x8900 */ + { 4454, 0xe042 }, { 4459, 0x1760 }, { 4465, 0x01c1 }, { 4469, 0x4627 }, + { 4476, 0x8265 }, { 4482, 0x1c84 }, { 4487, 0x480e }, { 4492, 0x3c29 }, + { 4499, 0x2200 }, { 4501, 0x9831 }, { 4507, 0x0021 }, { 4509, 0x10f1 }, + { 4515, 0x0000 }, { 4515, 0x01f0 }, { 4520, 0x2a20 }, { 4524, 0xa24a }, + /* 0x8a00 */ + { 4530, 0x80b0 }, { 4534, 0x4036 }, { 4539, 0x9855 }, { 4546, 0x60a0 }, + { 4550, 0x62a9 }, { 4557, 0x31c8 }, { 4563, 0x00a2 }, { 4566, 0xcee0 }, + { 4574, 0x8849 }, { 4579, 0x82c5 }, { 4585, 0xc280 }, { 4589, 0x48c8 }, + { 4594, 0x0748 }, { 4599, 0xa0ba }, { 4606, 0x1000 }, { 4607, 0x9071 }, + /* 0x8b00 */ + { 4613, 0x0c60 }, { 4617, 0xd002 }, { 4621, 0x2000 }, { 4622, 0x1081 }, + { 4625, 0x217c }, { 4632, 0x421c }, { 4637, 0x2008 }, { 4639, 0x5340 }, + { 4644, 0xa832 }, { 4650, 0xd030 }, { 4655, 0x0000 }, { 4655, 0x0000 }, + { 4655, 0x0000 }, { 4655, 0x0000 }, { 4655, 0x0000 }, { 4655, 0x0000 }, + /* 0x8c00 */ + { 4655, 0x0000 }, { 4655, 0x0000 }, { 4655, 0x0000 }, { 4655, 0x6300 }, + { 4659, 0x8aa0 }, { 4664, 0x2b9a }, { 4672, 0x2358 }, { 4678, 0x4868 }, + { 4683, 0x08c0 }, { 4686, 0x1a0d }, { 4692, 0x0010 }, { 4693, 0x0600 }, + { 4695, 0x8a60 }, { 4700, 0x2260 }, { 4704, 0x9102 }, { 4708, 0xc1a5 }, + /* 0x8d00 */ + { 4715, 0x020a }, { 4718, 0x0884 }, { 4721, 0x0000 }, { 4721, 0x0000 }, + { 4721, 0x0000 }, { 4721, 0x0000 }, { 4721, 0x5220 }, { 4725, 0x8000 }, + { 4726, 0x2114 }, { 4730, 0xc023 }, { 4735, 0x9841 }, { 4740, 0x1aa4 }, + { 4746, 0x45e1 }, { 4753, 0x02b2 }, { 4758, 0x10b0 }, { 4762, 0x2017 }, + /* 0x8e00 */ + { 4767, 0x0872 }, { 4772, 0x0052 }, { 4775, 0x00cf }, { 4781, 0x23ca }, + { 4788, 0xe803 }, { 4794, 0x7810 }, { 4799, 0xb206 }, { 4805, 0x0e03 }, + { 4810, 0x020c }, { 4813, 0x6c25 }, { 4820, 0x6284 }, { 4825, 0x0c28 }, + { 4829, 0x809b }, { 4835, 0x1012 }, { 4838, 0x6100 }, { 4841, 0x0683 }, + /* 0x8f00 */ + { 4846, 0x8185 }, { 4851, 0x41c1 }, { 4856, 0x71ab }, { 4865, 0x04f0 }, + { 4870, 0x808b }, { 4875, 0x613e }, { 4883, 0x0020 }, { 4884, 0x0000 }, + { 4884, 0x0000 }, { 4884, 0x2000 }, { 4885, 0x0073 }, { 4890, 0x4160 }, + { 4894, 0x2c43 }, { 4900, 0x002d }, { 4904, 0x4119 }, { 4909, 0x4862 }, + /* 0x9000 */ + { 4914, 0x1114 }, { 4918, 0x0900 }, { 4920, 0xb700 }, { 4926, 0x8098 }, + { 4930, 0x1018 }, { 4933, 0x2800 }, { 4935, 0x10c4 }, { 4939, 0x0211 }, + { 4942, 0x5920 }, { 4947, 0x0ba1 }, { 4953, 0x0027 }, { 4957, 0x605d }, + { 4964, 0x11b8 }, { 4970, 0xb3a4 }, { 4978, 0x8820 }, { 4981, 0xc051 }, + /* 0x9100 */ + { 4986, 0x2171 }, { 4992, 0x55d1 }, { 5000, 0xc2ad }, { 5008, 0x36d2 }, + { 5016, 0x8188 }, { 5020, 0x0e88 }, { 5025, 0x2092 }, { 5029, 0x0e10 }, + { 5033, 0x446a }, { 5039, 0x413a }, { 5045, 0x7142 }, { 5051, 0xb84f }, + { 5060, 0x002c }, { 5063, 0x4698 }, { 5069, 0xf630 }, { 5077, 0x2a83 }, + /* 0x9200 */ + { 5083, 0x16f3 }, { 5092, 0x314d }, { 5099, 0xc178 }, { 5106, 0x5769 }, + { 5115, 0xe4cd }, { 5124, 0x3302 }, { 5129, 0xc3a3 }, { 5137, 0xbbe1 }, + { 5147, 0x6700 }, { 5152, 0x8284 }, { 5156, 0x89b1 }, { 5163, 0xbd44 }, + { 5171, 0x79ef }, { 5183, 0xb3a9 }, { 5192, 0x51ab }, { 5200, 0x8a01 }, + /* 0x9300 */ + { 5204, 0x2105 }, { 5208, 0xf032 }, { 5215, 0x06b2 }, { 5221, 0x00d8 }, + { 5225, 0x0380 }, { 5228, 0x45a7 }, { 5236, 0xa6b0 }, { 5243, 0xa45b }, + { 5251, 0xad07 }, { 5259, 0x4924 }, { 5264, 0x0b5a }, { 5271, 0x0470 }, + { 5275, 0x3ef2 }, { 5285, 0xd208 }, { 5290, 0x00c4 }, { 5293, 0x2f80 }, + /* 0x9400 */ + { 5299, 0xe316 }, { 5307, 0x80e0 }, { 5311, 0xc000 }, { 5313, 0xa81e }, + { 5320, 0x1528 }, { 5325, 0x9220 }, { 5329, 0xe90a }, { 5336, 0x0006 }, + { 5338, 0x0018 }, { 5340, 0x0000 }, { 5340, 0x0000 }, { 5340, 0x0000 }, + { 5340, 0x0000 }, { 5340, 0x0000 }, { 5340, 0x0000 }, { 5340, 0x0000 }, + /* 0x9500 */ + { 5340, 0x0000 }, { 5340, 0x0000 }, { 5340, 0x0000 }, { 5340, 0x0000 }, + { 5340, 0x0000 }, { 5340, 0x0000 }, { 5340, 0x0000 }, { 5340, 0x4300 }, + { 5343, 0x7110 }, { 5348, 0xe000 }, { 5351, 0x1a42 }, { 5356, 0xa450 }, + { 5361, 0x0b40 }, { 5365, 0xe60f }, { 5374, 0x0051 }, { 5377, 0x0000 }, + /* 0x9600 */ + { 5377, 0x0000 }, { 5377, 0x6000 }, { 5379, 0x1074 }, { 5384, 0x378a }, + { 5392, 0x0002 }, { 5393, 0x01d4 }, { 5398, 0x4002 }, { 5400, 0xd810 }, + { 5405, 0x021e }, { 5410, 0xa442 }, { 5415, 0xc270 }, { 5421, 0x0408 }, + { 5423, 0x0400 }, { 5424, 0xe504 }, { 5430, 0x8200 }, { 5432, 0x0402 }, + /* 0x9700 */ + { 5434, 0x022c }, { 5438, 0x2c00 }, { 5441, 0x010e }, { 5445, 0x000a }, + { 5447, 0xc40a }, { 5452, 0x0da0 }, { 5457, 0x4488 }, { 5461, 0xa9c8 }, + { 5468, 0x0201 }, { 5470, 0xc6e0 }, { 5477, 0x5004 }, { 5480, 0xd766 }, + { 5490, 0x76b2 }, { 5499, 0x6b93 }, { 5508, 0x8013 }, { 5512, 0x0592 }, + /* 0x9800 */ + { 5517, 0x6480 }, { 5521, 0x5250 }, { 5526, 0xc869 }, { 5533, 0x402d }, + { 5538, 0x0490 }, { 5541, 0x06ce }, { 5548, 0x146c }, { 5554, 0x0000 }, + { 5554, 0x0000 }, { 5554, 0x0000 }, { 5554, 0x6800 }, { 5557, 0x8d91 }, + { 5564, 0x1124 }, { 5568, 0x0000 }, { 5568, 0x04ea }, { 5574, 0x0048 }, + /* 0x9900 */ + { 5576, 0x0184 }, { 5579, 0x9ce2 }, { 5587, 0x08c4 }, { 5591, 0x1e3e }, + { 5600, 0x61c3 }, { 5607, 0xdb10 }, { 5614, 0x0001 }, { 5615, 0x0000 }, + { 5615, 0x0000 }, { 5615, 0xa800 }, { 5618, 0x0040 }, { 5619, 0xa627 }, + { 5627, 0x0208 }, { 5629, 0x5618 }, { 5635, 0x1c80 }, { 5639, 0x6231 }, + /* 0x9a00 */ + { 5645, 0x181c }, { 5650, 0x4043 }, { 5654, 0x609d }, { 5661, 0x0168 }, + { 5665, 0x5c92 }, { 5672, 0x2052 }, { 5676, 0x0000 }, { 5676, 0x0000 }, + { 5676, 0x0000 }, { 5676, 0x0000 }, { 5676, 0xd400 }, { 5680, 0xca74 }, + { 5688, 0x414a }, { 5693, 0x18e5 }, { 5700, 0x12b1 }, { 5706, 0xa62c }, + /* 0x9b00 */ + { 5713, 0x7b3f }, { 5725, 0x1a45 }, { 5731, 0x2841 }, { 5735, 0x26b8 }, + { 5742, 0x1900 }, { 5745, 0x48e0 }, { 5750, 0x7d6a }, { 5760, 0x83a8 }, + { 5766, 0xaef1 }, { 5776, 0x6411 }, { 5781, 0x12c0 }, { 5785, 0xd987 }, + { 5794, 0x4182 }, { 5798, 0xa181 }, { 5803, 0x8ca0 }, { 5808, 0xa788 }, + /* 0x9c00 */ + { 5815, 0x8805 }, { 5819, 0x5742 }, { 5826, 0x07cc }, { 5833, 0x20e2 }, + { 5838, 0xc63a }, { 5846, 0xf959 }, { 5856, 0x4f08 }, { 5862, 0x08a5 }, + { 5867, 0x0000 }, { 5867, 0x0000 }, { 5867, 0x0000 }, { 5867, 0x0000 }, + { 5867, 0x0000 }, { 5867, 0x0000 }, { 5867, 0x0040 }, { 5868, 0x0284 }, + /* 0x9d00 */ + { 5871, 0x0804 }, { 5873, 0x7182 }, { 5879, 0x8000 }, { 5880, 0x341d }, + { 5887, 0x04ac }, { 5892, 0x8018 }, { 5895, 0x0e2c }, { 5901, 0x58c1 }, + { 5907, 0x6458 }, { 5913, 0x01ec }, { 5919, 0x5402 }, { 5923, 0x9222 }, + { 5928, 0x0688 }, { 5932, 0xc4f0 }, { 5939, 0x4aa1 }, { 5945, 0x4019 }, + /* 0x9e00 */ + { 5949, 0x4484 }, { 5953, 0x3267 }, { 5961, 0x0000 }, { 5961, 0x0000 }, + { 5961, 0x0000 }, { 5961, 0x0000 }, { 5961, 0x0000 }, { 5961, 0x1c00 }, + { 5964, 0xc0bd }, { 5972, 0x4940 }, { 5976, 0xd110 }, { 5981, 0x0039 }, + { 5985, 0x0940 }, { 5988, 0x8020 }, { 5990, 0x7090 }, { 5995, 0x8127 }, + /* 0x9f00 */ + { 6001, 0x820c }, { 6005, 0x8ed7 }, { 6015, 0x8c44 }, { 6020, 0xb696 }, + { 6029, 0x00fa }, { 6035, 0x65e8 }, { 6043, 0xe300 }, { 6048, 0x242b }, + { 6054, 0x8000 }, { 6055, 0x40d7 }, { 6062, 0x002e }, +}; +static const Summary16 jisx0212_uni2indx_pageff[6] = { + /* 0xff00 */ + { 6066, 0x0000 }, { 6066, 0x0000 }, { 6066, 0x0000 }, { 6066, 0x0000 }, + { 6066, 0x0000 }, { 6066, 0x4000 }, +}; + +static int +jisx0212_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc >= 0x0000 && wc < 0x0460) + summary = &jisx0212_uni2indx_page00[(wc>>4)]; + else if (wc >= 0x2100 && wc < 0x2130) + summary = &jisx0212_uni2indx_page21[(wc>>4)-0x210]; + else if (wc >= 0x4e00 && wc < 0x9fb0) + summary = &jisx0212_uni2indx_page4e[(wc>>4)-0x4e0]; + else if (wc >= 0xff00 && wc < 0xff60) + summary = &jisx0212_uni2indx_pageff[(wc>>4)-0xff0]; + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = jisx0212_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/jisx0213.h b/graf2d/win32gdk/gdk/src/iconv/jisx0213.h new file mode 100644 index 0000000000000..98468c464496f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/jisx0213.h @@ -0,0 +1,5924 @@ +/* + * Copyright (C) 1999-2004 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * JISX0213:2000 + */ + +#ifndef _JISX0213_H +#define _JISX0213_H + +/* JISX0213 plane 1 (= ISO-IR-233) characters are in the range + 0x{21..7E}{21..7E}. + JISX0213 plane 2 (= ISO-IR-229) characters are in the range + 0x{21,23..25,28,2C..2F,6E..7E}{21..7E}. + Together this makes 120 rows of 94 characters. +*/ + +static const unsigned short jisx0213_to_ucs_combining[][2] = { + { 0x304b, 0x309a }, + { 0x304d, 0x309a }, + { 0x304f, 0x309a }, + { 0x3051, 0x309a }, + { 0x3053, 0x309a }, + { 0x30ab, 0x309a }, + { 0x30ad, 0x309a }, + { 0x30af, 0x309a }, + { 0x30b1, 0x309a }, + { 0x30b3, 0x309a }, + { 0x30bb, 0x309a }, + { 0x30c4, 0x309a }, + { 0x30c8, 0x309a }, + { 0x31f7, 0x309a }, + { 0x00e6, 0x0300 }, + { 0x0254, 0x0300 }, + { 0x0254, 0x0301 }, + { 0x028c, 0x0300 }, + { 0x028c, 0x0301 }, + { 0x0259, 0x0300 }, + { 0x0259, 0x0301 }, + { 0x025a, 0x0300 }, + { 0x025a, 0x0301 }, + { 0x02e9, 0x02e5 }, + { 0x02e5, 0x02e9 }, +}; + +static const unsigned short jisx0213_to_ucs_main[120 * 94] = { + /* 0x12121..0x1217E */ + 0x1000, 0x1001, 0x1002, 0x830c, 0x830e, 0x10fb, 0x831a, 0x831b, + 0x831f, 0x8301, 0x109b, 0x109c, 0x00b4, 0x8340, 0x00a8, 0x833e, + 0x83e3, 0x833f, 0x10fd, 0x10fe, 0x109d, 0x109e, 0x1003, 0x2edd, + 0x1005, 0x1006, 0x1007, 0x10fc, 0x0714, 0x0710, 0x830f, 0x833c, + 0x101c, 0x0716, 0x835c, 0x0726, 0x0725, 0x0718, 0x0719, 0x071c, + 0x071d, 0x8308, 0x8309, 0x1014, 0x1015, 0x833b, 0x833d, 0x835b, + 0x835d, 0x1008, 0x1009, 0x100a, 0x100b, 0x100c, 0x100d, 0x100e, + 0x100f, 0x1010, 0x1011, 0x830b, 0x0912, 0x00b1, 0x00d7, 0x00f7, + 0x831d, 0x0960, 0x831c, 0x831e, 0x0966, 0x0967, 0x091e, 0x0934, + 0x0d42, 0x0d40, 0x00b0, 0x0732, 0x0733, 0x0803, 0x83e5, 0x8304, + 0x00a2, 0x00a3, 0x8305, 0x8303, 0x8306, 0x830a, 0x8320, 0x00a7, + 0x0d06, 0x0d05, 0x0ccb, 0x0ccf, 0x0cce, 0x0cc7, + /* 0x12221..0x1227E */ + 0x0cc6, 0x0ca1, 0x0ca0, 0x0cb3, 0x0cb2, 0x0cbd, 0x0cbc, 0x073b, + 0x1012, 0x0892, 0x0890, 0x0891, 0x0893, 0x1013, 0x8307, 0x8302, + 0x830d, 0x835e, 0x1033, 0x1034, 0x1035, 0x103b, 0x103c, 0x10ff, + 0x109f, 0x0908, 0x090b, 0x0986, 0x0987, 0x0982, 0x0983, 0x092a, + 0x0929, 0x0984, 0x0985, 0x098a, 0x098b, 0x0909, 0x0905, 0x0a05, + 0x0a06, 0x0927, 0x0928, 0x00ac, 0x08d2, 0x08d4, 0x0900, 0x0903, + 0x0995, 0x0996, 0x0997, 0x0925, 0x0926, 0x835f, 0x8360, 0x1018, + 0x1019, 0x1016, 0x1017, 0x0920, 0x09a5, 0x0a12, 0x0902, 0x0907, + 0x0961, 0x0952, 0x096a, 0x096b, 0x091a, 0x093d, 0x091d, 0x0935, + 0x092b, 0x092c, 0x0962, 0x0943, 0x0945, 0x0948, 0x0976, 0x0977, + 0x0894, 0x082b, 0x0730, 0x0d6f, 0x0d6d, 0x0d6a, 0x0720, 0x0721, + 0x00b6, 0x0d6e, 0x0d6b, 0x0d6c, 0x0d69, 0x0cef, + /* 0x12321..0x1237E */ + 0x0cb7, 0x0cb6, 0x0cc1, 0x0cc0, 0x0897, 0x0898, 0x0896, 0x0899, + 0x08c4, 0x08e8, 0x08e6, 0x08e7, 0x08e9, 0x0f34, 0x0f35, 0x8310, + 0x8311, 0x8312, 0x8313, 0x8314, 0x8315, 0x8316, 0x8317, 0x8318, + 0x8319, 0x0fbf, 0x0cc9, 0x103d, 0x8246, 0x8245, 0x0ce6, 0x0722, + 0x8321, 0x8322, 0x8323, 0x8324, 0x8325, 0x8326, 0x8327, 0x8328, + 0x8329, 0x832a, 0x832b, 0x832c, 0x832d, 0x832e, 0x832f, 0x8330, + 0x8331, 0x8332, 0x8333, 0x8334, 0x8335, 0x8336, 0x8337, 0x8338, + 0x8339, 0x833a, 0x0913, 0x0835, 0x080f, 0x13cb, 0x0813, 0x0827, + 0x8341, 0x8342, 0x8343, 0x8344, 0x8345, 0x8346, 0x8347, 0x8348, + 0x8349, 0x834a, 0x834b, 0x834c, 0x834d, 0x834e, 0x834f, 0x8350, + 0x8351, 0x8352, 0x8353, 0x8354, 0x8355, 0x8356, 0x8357, 0x8358, + 0x8359, 0x835a, 0x10a0, 0x0713, 0x0ffa, 0x0ffb, + /* 0x12421..0x1247E */ + 0x1041, 0x1042, 0x1043, 0x1044, 0x1045, 0x1046, 0x1047, 0x1048, + 0x1049, 0x104a, 0x104b, 0x104c, 0x104d, 0x104e, 0x104f, 0x1050, + 0x1051, 0x1052, 0x1053, 0x1054, 0x1055, 0x1056, 0x1057, 0x1058, + 0x1059, 0x105a, 0x105b, 0x105c, 0x105d, 0x105e, 0x105f, 0x1060, + 0x1061, 0x1062, 0x1063, 0x1064, 0x1065, 0x1066, 0x1067, 0x1068, + 0x1069, 0x106a, 0x106b, 0x106c, 0x106d, 0x106e, 0x106f, 0x1070, + 0x1071, 0x1072, 0x1073, 0x1074, 0x1075, 0x1076, 0x1077, 0x1078, + 0x1079, 0x107a, 0x107b, 0x107c, 0x107d, 0x107e, 0x107f, 0x1080, + 0x1081, 0x1082, 0x1083, 0x1084, 0x1085, 0x1086, 0x1087, 0x1088, + 0x1089, 0x108a, 0x108b, 0x108c, 0x108d, 0x108e, 0x108f, 0x1090, + 0x1091, 0x1092, 0x1093, 0x1094, 0x1095, 0x1096, 0x0001, 0x0002, + 0x0003, 0x0004, 0x0005, 0x0000, 0x0000, 0x0000, + /* 0x12521..0x1257E */ + 0x10a1, 0x10a2, 0x10a3, 0x10a4, 0x10a5, 0x10a6, 0x10a7, 0x10a8, + 0x10a9, 0x10aa, 0x10ab, 0x10ac, 0x10ad, 0x10ae, 0x10af, 0x10b0, + 0x10b1, 0x10b2, 0x10b3, 0x10b4, 0x10b5, 0x10b6, 0x10b7, 0x10b8, + 0x10b9, 0x10ba, 0x10bb, 0x10bc, 0x10bd, 0x10be, 0x10bf, 0x10c0, + 0x10c1, 0x10c2, 0x10c3, 0x10c4, 0x10c5, 0x10c6, 0x10c7, 0x10c8, + 0x10c9, 0x10ca, 0x10cb, 0x10cc, 0x10cd, 0x10ce, 0x10cf, 0x10d0, + 0x10d1, 0x10d2, 0x10d3, 0x10d4, 0x10d5, 0x10d6, 0x10d7, 0x10d8, + 0x10d9, 0x10da, 0x10db, 0x10dc, 0x10dd, 0x10de, 0x10df, 0x10e0, + 0x10e1, 0x10e2, 0x10e3, 0x10e4, 0x10e5, 0x10e6, 0x10e7, 0x10e8, + 0x10e9, 0x10ea, 0x10eb, 0x10ec, 0x10ed, 0x10ee, 0x10ef, 0x10f0, + 0x10f1, 0x10f2, 0x10f3, 0x10f4, 0x10f5, 0x10f6, 0x0006, 0x0007, + 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, + /* 0x12621..0x1267E */ + 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, 0x0398, + 0x0399, 0x039a, 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, 0x03a0, + 0x03a1, 0x03a3, 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, + 0x0d64, 0x0d60, 0x0d62, 0x0d66, 0x0d61, 0x0d65, 0x0d67, 0x0d63, + 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, 0x03b8, + 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, 0x03c0, + 0x03c1, 0x03c3, 0x03c4, 0x03c5, 0x03c6, 0x03c7, 0x03c8, 0x03c9, + 0x03c2, 0x0bf5, 0x0bf6, 0x0bf7, 0x0bf8, 0x0bf9, 0x0bfa, 0x0bfb, + 0x0bfc, 0x0bfd, 0x0bfe, 0x0d16, 0x0d17, 0x1020, 0x0d0e, 0x0d00, + 0x0d01, 0x0d02, 0x0d03, 0x0d68, 0x0cb1, 0x11f0, 0x11f1, 0x11f2, + 0x11f3, 0x11f4, 0x11f5, 0x11f6, 0x11f7, 0x11f8, 0x11f9, 0x000e, + 0x11fa, 0x11fb, 0x11fc, 0x11fd, 0x11fe, 0x11ff, + /* 0x12721..0x1277E */ + 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0401, 0x0416, + 0x0417, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, + 0x041f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, + 0x0427, 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, + 0x042f, 0x0abe, 0x0abf, 0x0ac0, 0x0ac1, 0x0ac2, 0x0ac3, 0x0ac4, + 0x0ac5, 0x0ac6, 0x0ac7, 0x0ac8, 0x0ac9, 0x0aca, 0x0acb, 0x0acc, + 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0451, 0x0436, + 0x0437, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, + 0x043f, 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, + 0x0447, 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, + 0x044f, 0x10f7, 0x10f8, 0x10f9, 0x10fa, 0x09da, 0x09db, 0x0853, + 0x0854, 0x0855, 0x0e13, 0x0a18, 0x0b23, 0x0ace, + /* 0x12821..0x1287E */ + 0x0c00, 0x0c02, 0x0c0c, 0x0c10, 0x0c18, 0x0c14, 0x0c1c, 0x0c2c, + 0x0c24, 0x0c34, 0x0c3c, 0x0c01, 0x0c03, 0x0c0f, 0x0c13, 0x0c1b, + 0x0c17, 0x0c23, 0x0c33, 0x0c2b, 0x0c3b, 0x0c4b, 0x0c20, 0x0c2f, + 0x0c28, 0x0c37, 0x0c3f, 0x0c1d, 0x0c30, 0x0c25, 0x0c38, 0x0c42, + 0x1251, 0x1252, 0x1253, 0x1254, 0x1255, 0x1256, 0x1257, 0x1258, + 0x1259, 0x125a, 0x125b, 0x125c, 0x125d, 0x125e, 0x125f, 0x12b1, + 0x12b2, 0x12b3, 0x12b4, 0x12b5, 0x12b6, 0x12b7, 0x12b8, 0x12b9, + 0x12ba, 0x12bb, 0x12bc, 0x12bd, 0x12be, 0x12bf, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0cd0, 0x0cd1, + 0x0cd2, 0x0cd3, 0x073c, 0x0747, 0x0748, 0x0749, 0x01cd, 0x01ce, + 0x01d0, 0x053e, 0x053f, 0x01f8, 0x01f9, 0x01d1, 0x01d2, 0x01d4, + 0x01d6, 0x01d8, 0x01da, 0x01dc, 0x0000, 0x0000, + /* 0x12921..0x1297E */ + 0x07ac, 0x00a0, 0x00a1, 0x00a4, 0x00a6, 0x00a9, 0x00aa, 0x00ab, + 0x00ad, 0x00ae, 0x00af, 0x00b2, 0x00b3, 0x00b7, 0x00b8, 0x00b9, + 0x00ba, 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf, 0x00c0, 0x00c1, + 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c6, 0x00c7, 0x00c8, 0x00c9, + 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, 0x00d0, 0x00d1, + 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x00d8, 0x00d9, 0x00da, + 0x00db, 0x00dc, 0x00dd, 0x00de, 0x00df, 0x00e0, 0x00e1, 0x00e2, + 0x00e3, 0x00e4, 0x00e5, 0x00e6, 0x00e7, 0x00e8, 0x00e9, 0x00ea, + 0x00eb, 0x00ec, 0x00ed, 0x00ee, 0x00ef, 0x00f0, 0x00f1, 0x00f2, + 0x00f3, 0x00f4, 0x00f5, 0x00f6, 0x00f8, 0x00f9, 0x00fa, 0x00fb, + 0x00fc, 0x00fd, 0x00fe, 0x00ff, 0x0100, 0x012a, 0x016a, 0x0112, + 0x014c, 0x0101, 0x012b, 0x016b, 0x0113, 0x014d, + /* 0x12A21..0x12A7E */ + 0x0104, 0x02d8, 0x0141, 0x013d, 0x015a, 0x0160, 0x015e, 0x0164, + 0x0179, 0x017d, 0x017b, 0x0105, 0x02db, 0x0142, 0x013e, 0x015b, + 0x02c7, 0x0161, 0x015f, 0x0165, 0x017a, 0x02dd, 0x017e, 0x017c, + 0x0154, 0x0102, 0x0139, 0x0106, 0x010c, 0x0118, 0x011a, 0x010e, + 0x0143, 0x0147, 0x0150, 0x0158, 0x016e, 0x0170, 0x0162, 0x0155, + 0x0103, 0x013a, 0x0107, 0x010d, 0x0119, 0x011b, 0x010f, 0x0111, + 0x0144, 0x0148, 0x0151, 0x0159, 0x016f, 0x0171, 0x0163, 0x02d9, + 0x0108, 0x011c, 0x0124, 0x0134, 0x015c, 0x016c, 0x0109, 0x011d, + 0x0125, 0x0135, 0x015d, 0x016d, 0x0271, 0x028b, 0x027e, 0x0283, + 0x0292, 0x026c, 0x026e, 0x0279, 0x0288, 0x0256, 0x0273, 0x027d, + 0x0282, 0x0290, 0x027b, 0x026d, 0x025f, 0x0272, 0x029d, 0x028e, + 0x0261, 0x014b, 0x0270, 0x0281, 0x0127, 0x0295, + /* 0x12B21..0x12B7E */ + 0x0294, 0x0266, 0x0298, 0x01c2, 0x0253, 0x0257, 0x0284, 0x0260, + 0x0193, 0x0153, 0x0152, 0x0268, 0x0289, 0x0258, 0x0275, 0x0259, + 0x025c, 0x025e, 0x0250, 0x026f, 0x028a, 0x0264, 0x028c, 0x0254, + 0x0251, 0x0252, 0x028d, 0x0265, 0x02a2, 0x02a1, 0x0255, 0x0291, + 0x027a, 0x0267, 0x025a, 0x000f, 0x01fd, 0x0670, 0x0671, 0x0010, + 0x0011, 0x0012, 0x0013, 0x0014, 0x0015, 0x0016, 0x0017, 0x0672, + 0x0673, 0x0361, 0x02c8, 0x02cc, 0x02d0, 0x02d1, 0x0306, 0x073f, + 0x030b, 0x0301, 0x0304, 0x0300, 0x030f, 0x030c, 0x0302, 0x02e5, + 0x02e6, 0x02e7, 0x02e8, 0x02e9, 0x0018, 0x0019, 0x0325, 0x032c, + 0x0339, 0x031c, 0x031f, 0x0320, 0x0308, 0x033d, 0x0329, 0x032f, + 0x02de, 0x0324, 0x0330, 0x033c, 0x0334, 0x031d, 0x031e, 0x0318, + 0x0319, 0x032a, 0x033a, 0x033b, 0x0303, 0x031a, + /* 0x12C21..0x12C7E */ + 0x0e76, 0x0e77, 0x0e78, 0x0e79, 0x0e7a, 0x0e7b, 0x0e7c, 0x0e7d, + 0x0e7e, 0x0e7f, 0x0beb, 0x0bec, 0x0bed, 0x0bee, 0x0bef, 0x0bf0, + 0x0bf1, 0x0bf2, 0x0bf3, 0x0bf4, 0x0870, 0x0871, 0x0872, 0x0873, + 0x0874, 0x0875, 0x0876, 0x0877, 0x0878, 0x0879, 0x087a, 0x087b, + 0x0bd0, 0x0bd1, 0x0bd2, 0x0bd3, 0x0bd4, 0x0bd5, 0x0bd6, 0x0bd7, + 0x0bd8, 0x0bd9, 0x0bda, 0x0bdb, 0x0bdc, 0x0bdd, 0x0bde, 0x0bdf, + 0x0be0, 0x0be1, 0x0be2, 0x0be3, 0x0be4, 0x0be5, 0x0be6, 0x0be7, + 0x0be8, 0x0be9, 0x12d0, 0x12d1, 0x12d2, 0x12d3, 0x12d4, 0x12d5, + 0x12d6, 0x12d7, 0x12d8, 0x12d9, 0x12da, 0x12db, 0x12dc, 0x12dd, + 0x12de, 0x12df, 0x12e0, 0x12e1, 0x12e2, 0x12e3, 0x12fa, 0x12e9, + 0x12e5, 0x12ed, 0x12ec, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0751, 0x0742, + /* 0x12D21..0x12D7E */ + 0x0b60, 0x0b61, 0x0b62, 0x0b63, 0x0b64, 0x0b65, 0x0b66, 0x0b67, + 0x0b68, 0x0b69, 0x0b6a, 0x0b6b, 0x0b6c, 0x0b6d, 0x0b6e, 0x0b6f, + 0x0b70, 0x0b71, 0x0b72, 0x0b73, 0x0860, 0x0861, 0x0862, 0x0863, + 0x0864, 0x0865, 0x0866, 0x0867, 0x0868, 0x0869, 0x086a, 0x1349, + 0x1314, 0x1322, 0x134d, 0x1318, 0x1327, 0x1303, 0x1336, 0x1351, + 0x1357, 0x130d, 0x1326, 0x1323, 0x132b, 0x134a, 0x133b, 0x139c, + 0x139d, 0x139e, 0x138e, 0x138f, 0x13c4, 0x13a1, 0x086b, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x137b, 0x101d, + 0x101f, 0x0816, 0x13cd, 0x0821, 0x12a4, 0x12a5, 0x12a6, 0x12a7, + 0x12a8, 0x1231, 0x1232, 0x1239, 0x137e, 0x137d, 0x137c, 0x0000, + 0x0000, 0x0000, 0x092e, 0x0000, 0x0000, 0x0000, 0x0000, 0x091f, + 0x09bf, 0x0000, 0x0000, 0x0000, 0x0e56, 0x0d1e, + /* 0x12E21..0x12E7E */ + 0x2ff1, 0x840b, 0x1402, 0x2e28, 0x2e2f, 0x2e30, 0x2e8d, 0x2ee1, + 0x2efd, 0x2eff, 0x2f03, 0x2f0b, 0x2f60, 0x2f48, 0x2f49, 0x2f56, + 0x2f5f, 0x2f6a, 0x2f6c, 0x2f7e, 0x2f8a, 0x2f94, 0x2f97, 0x8130, + 0x2fc9, 0x2fe0, 0x3001, 0x3002, 0x300e, 0x3018, 0x3027, 0x302e, + 0x3040, 0x303b, 0x3041, 0x3094, 0x30cc, 0x30f2, 0x30d0, 0x30e6, + 0x8131, 0x3106, 0x3103, 0x310b, 0x311e, 0x3135, 0x314a, 0x8132, + 0x3155, 0x3157, 0x14b5, 0x319d, 0x31c3, 0x31ca, 0x31de, 0x31e2, + 0x31ee, 0x3201, 0x14db, 0x3213, 0x3215, 0x3249, 0x3257, 0x3261, + 0x3293, 0x32c8, 0x8133, 0x32cc, 0x32d0, 0x32d6, 0x32db, 0x8134, + 0x32f0, 0x32fb, 0x3300, 0x3307, 0x331c, 0x8135, 0x3361, 0x3363, + 0x337d, 0x3393, 0x339d, 0x33b2, 0x3412, 0x3427, 0x344d, 0x349c, + 0x346b, 0x3474, 0x347f, 0x3488, 0x3496, 0x34a1, + /* 0x12F21..0x12F7E */ + 0x34a9, 0x34c6, 0x34ff, 0x350e, 0x352b, 0x3535, 0x3550, 0x355e, + 0x3581, 0x3586, 0x358e, 0x8136, 0x35ad, 0x35ce, 0x8137, 0x3608, + 0x360e, 0x363b, 0x3649, 0x3676, 0x3666, 0x8138, 0x366f, 0x3671, + 0x3672, 0x3699, 0x369e, 0x36a9, 0x36ac, 0x36b3, 0x36c9, 0x36ca, + 0x370a, 0x923d, 0x3721, 0x372f, 0x3733, 0x3734, 0x3770, 0x3777, + 0x377c, 0x379c, 0x810f, 0x931b, 0x37b8, 0x37c7, 0x37c8, 0x37cf, + 0x37e4, 0x37ed, 0x37f5, 0x37f6, 0x37ff, 0x3809, 0x8110, 0x3861, + 0x3864, 0x8139, 0x387c, 0x3889, 0x389e, 0x813a, 0x38a9, 0x946e, + 0x38d2, 0x38ce, 0x38d4, 0x38da, 0x38e0, 0x38e9, 0x390c, 0x6641, + 0x395d, 0x396d, 0x398b, 0x3992, 0x39a4, 0x39c3, 0x39d2, 0x39dd, + 0x3a13, 0x3a23, 0x3a67, 0x3a6d, 0x3a77, 0x3a7e, 0x3a84, 0x3a9e, + 0x3aa7, 0x3ac4, 0x98bd, 0x3b19, 0x3b25, 0x325d, + /* 0x13021..0x1307E */ + 0x2e9c, 0x3516, 0x3a03, 0x763f, 0x34c0, 0x411b, 0x4328, 0x39f6, + 0x7022, 0x6475, 0x631c, 0x5a50, 0x40aa, 0x43e1, 0x4e25, 0x45ed, + 0x6466, 0x62a6, 0x7bf5, 0x4893, 0x3727, 0x45a1, 0x4271, 0x3b9b, + 0x39d0, 0x667b, 0x78f4, 0x5d62, 0x5dbe, 0x7b8e, 0x4216, 0x5c9f, + 0x68b7, 0x3b89, 0x3eb5, 0x4309, 0x4697, 0x4848, 0x75c7, 0x778d, + 0x474f, 0x2ee5, 0x2f0a, 0x2f4d, 0x2f9d, 0x3049, 0x36f2, 0x3937, + 0x39d4, 0x3a01, 0x3c09, 0x40df, 0x410f, 0x4170, 0x4613, 0x4905, + 0x50ba, 0x554f, 0x5570, 0x59fb, 0x5dad, 0x5def, 0x60c3, 0x640e, + 0x6863, 0x6b02, 0x7055, 0x707a, 0x333b, 0x2e95, 0x2ea5, 0x37df, + 0x60b2, 0x70c1, 0x58ef, 0x2e00, 0x38f1, 0x4ea2, 0x7038, 0x5a32, + 0x6328, 0x628b, 0x7c2f, 0x3141, 0x3370, 0x34bd, 0x34e1, 0x36e0, + 0x39fb, 0x3f15, 0x78f2, 0x4deb, 0x60e4, 0x652d, + /* 0x13121..0x1317E */ + 0x7662, 0x7670, 0x76a0, 0x77fb, 0x340b, 0x33f3, 0x3b87, 0x50cf, + 0x5fbd, 0x6fc2, 0x76e8, 0x336f, 0x7d5c, 0x5aba, 0x2e11, 0x5893, + 0x61fc, 0x4e26, 0x3618, 0x3504, 0x4b1d, 0x651a, 0x7c3b, 0x39e5, + 0x33a9, 0x4d66, 0x54dc, 0x758f, 0x3642, 0x2e91, 0x704b, 0x76f2, + 0x634f, 0x790c, 0x33e1, 0x35b6, 0x3b30, 0x3f71, 0x4620, 0x46f3, + 0x4804, 0x4c38, 0x4cf3, 0x4d29, 0x545b, 0x56c8, 0x5a4e, 0x7834, + 0x62f1, 0x685b, 0x6a60, 0x72ed, 0x4db2, 0x55ab, 0x56ca, 0x79c5, + 0x40a6, 0x6b01, 0x6d8a, 0x75b2, 0x498e, 0x33ad, 0x3186, 0x3712, + 0x3830, 0x3944, 0x3bb4, 0x3ef6, 0x4028, 0x43a9, 0x43f4, 0x4cbf, + 0x4f14, 0x508e, 0x5114, 0x5159, 0x51d5, 0x533f, 0x5e01, 0x6276, + 0x62d1, 0x6597, 0x7060, 0x725b, 0x7d1b, 0x3869, 0x45bc, 0x4c5a, + 0x5525, 0x31f9, 0x392e, 0x3965, 0x3f80, 0x3fdc, + /* 0x13221..0x1327E */ + 0x42bc, 0x45fa, 0x4a2a, 0x4b27, 0x4bb4, 0x538b, 0x5fc1, 0x6956, + 0x7d2c, 0x7d0e, 0x7ec4, 0x3ca1, 0x4c96, 0x637b, 0x3104, 0x3c4b, + 0x41b6, 0x61c6, 0x4876, 0x5261, 0x2e59, 0x2ffa, 0x3378, 0x4069, + 0x4e29, 0x5a4f, 0x77f3, 0x2e0b, 0x3316, 0x2eee, 0x2f55, 0x2f3d, + 0x2fa1, 0x2f73, 0x32a0, 0x33ef, 0x3609, 0x390f, 0x3ac1, 0x3bb6, + 0x3be1, 0x59d1, 0x4687, 0x479c, 0x47b6, 0x4b4c, 0x4cb3, 0x506b, + 0x53c2, 0x598d, 0x59be, 0x5a3c, 0x5b87, 0x62b1, 0x62db, 0x6304, + 0x6377, 0x63ef, 0x63d3, 0x6766, 0x6ab2, 0x3629, 0x6ca8, 0x6fe6, + 0x704e, 0x771e, 0x668a, 0x2fc4, 0x3ce8, 0x4211, 0x5259, 0x553b, + 0x61e5, 0x62bd, 0x66fe, 0x6cc0, 0x76c5, 0x7913, 0x79d5, 0x2ecb, + 0x2f1a, 0x69e3, 0x36de, 0x384a, 0x38ca, 0x3efb, 0x3feb, 0x402a, + 0x4094, 0x4062, 0x41d0, 0x4212, 0x42d0, 0x4539, + /* 0x13321..0x1337E */ + 0x7b41, 0x4666, 0x48b0, 0x4d77, 0x5070, 0x554c, 0x5686, 0x5d75, + 0x62a5, 0x67f9, 0x758b, 0x768e, 0x6c9d, 0x31f1, 0x32be, 0x3916, + 0x34b3, 0x3bb3, 0x3d16, 0x4168, 0x4982, 0x4daf, 0x588d, 0x64cb, + 0x6857, 0x6a72, 0x73a7, 0x7ab8, 0x4d6c, 0x79a8, 0x66d9, 0x37a3, + 0x47ff, 0x66ce, 0x720e, 0x3283, 0x3687, 0x3404, 0x3ed3, 0x42e1, + 0x44b9, 0x483c, 0x4838, 0x4bbb, 0x5372, 0x58ba, 0x5a6b, 0x699a, + 0x69d2, 0x6d6b, 0x6f03, 0x70ed, 0x75a3, 0x7694, 0x7769, 0x3b66, + 0x3cb3, 0x497d, 0x784d, 0x784e, 0x439b, 0x5b20, 0x4a2b, 0x4a7f, + 0x48b6, 0x7c0d, 0x4f5f, 0x3272, 0x359d, 0x4070, 0x42ec, 0x4d3b, + 0x4e07, 0x4ed1, 0x645b, 0x6910, 0x6f44, 0x2e14, 0x7c39, 0x33f6, + 0x491b, 0x4a3a, 0x7784, 0x482a, 0x315c, 0x5ac3, 0x64b2, 0x71dc, + 0x738c, 0x365b, 0x7d28, 0x4822, 0x6305, 0x6431, + /* 0x13421..0x1347E */ + 0x5ca5, 0x3208, 0x62c5, 0x54e6, 0x2e7e, 0x2f83, 0x31a0, 0x3bd2, + 0x320a, 0x32d8, 0x32e7, 0x3dfb, 0x359a, 0x382a, 0x39e6, 0x3b8c, + 0x3b98, 0x3bdb, 0x3e72, 0x3e79, 0x40a3, 0x411f, 0x4163, 0x41be, + 0x43db, 0x4562, 0x47d1, 0x4853, 0x48fa, 0x4b3e, 0x4b53, 0x4c57, + 0x4f22, 0x4f97, 0x4f45, 0x54b0, 0x5518, 0x56e3, 0x570b, 0x5aff, + 0x5ba1, 0x5c21, 0x5de9, 0x5f36, 0x5ff0, 0x609d, 0x6266, 0x639e, + 0x69b3, 0x6acc, 0x6cab, 0x7084, 0x7451, 0x7593, 0x7591, 0x75a2, + 0x7665, 0x77d3, 0x7928, 0x6218, 0x2e38, 0x342b, 0x3cb8, 0x3dcc, + 0x53a9, 0x564c, 0x573c, 0x3ca9, 0x5feb, 0x6d0b, 0x76c1, 0x7811, + 0x7854, 0x7858, 0x2f01, 0x2f0e, 0x3371, 0x359c, 0x3668, 0x37fa, + 0x3947, 0x3b09, 0x3bc4, 0x3c90, 0x3e0c, 0x3e7e, 0x3fcc, 0x43ee, + 0x473a, 0x45d7, 0x45e2, 0x471f, 0x48cb, 0x48c4, + /* 0x13521..0x1357E */ + 0x4a5f, 0x3e30, 0x4bc5, 0x4c17, 0x4c7d, 0x557f, 0x5948, 0x3b63, + 0x5a00, 0x5d00, 0x3fbd, 0x698f, 0x6a18, 0x6cb4, 0x6d77, 0x6ecc, + 0x6f1d, 0x78e2, 0x7a0e, 0x7b3c, 0x2e80, 0x307d, 0x3100, 0x3993, + 0x3b9c, 0x422f, 0x4280, 0x44ec, 0x4b3a, 0x52a0, 0x5591, 0x5947, + 0x5fa9, 0x67fb, 0x6abc, 0x6b70, 0x43ac, 0x63ca, 0x77a0, 0x3409, + 0x3403, 0x35ab, 0x4854, 0x4a58, 0x6a70, 0x5827, 0x4775, 0x7ecd, + 0x3374, 0x3ba2, 0x611a, 0x6650, 0x7006, 0x2e18, 0x2e45, 0x2ec7, + 0x2f11, 0x33ca, 0x3438, 0x3bae, 0x3f13, 0x4025, 0x4551, 0x473d, + 0x4c42, 0x4c72, 0x4ce3, 0x5078, 0x5403, 0x5a76, 0x5aae, 0x5b08, + 0x5d1a, 0x5cfe, 0x5d66, 0x45e7, 0x525b, 0x33bb, 0x3c45, 0x3de8, + 0x42d2, 0x42e0, 0x4319, 0x4e20, 0x665a, 0x6a31, 0x6ddd, 0x72f8, + 0x4f01, 0x59a6, 0x7b5a, 0x2ea8, 0x2eab, 0x2eac, + /* 0x13621..0x1367E */ + 0x2f9b, 0x2fa0, 0x30d1, 0x3147, 0x5af6, 0x3171, 0x31f6, 0x3354, + 0x3321, 0x337f, 0x33eb, 0x35ac, 0x3883, 0x3ce1, 0x3f37, 0x3f4a, + 0x402f, 0x4050, 0x406d, 0x431f, 0x4559, 0x4a4b, 0x4cc1, 0x52c2, + 0x52ed, 0x57ef, 0x60f8, 0x6105, 0x6208, 0x654e, 0x70f7, 0x73e1, + 0x77ff, 0x7957, 0x7a5a, 0x2ef0, 0x31dd, 0x3c2d, 0x4681, 0x496d, + 0x3c40, 0x46f2, 0x4975, 0x5389, 0x4850, 0x5c81, 0x30c5, 0x32e4, + 0x3747, 0x3dfe, 0x7326, 0x45a4, 0x4b23, 0x4b3d, 0x5434, 0x5981, + 0x59bd, 0x5b4b, 0x5dca, 0x62b9, 0x63cc, 0x687f, 0x695f, 0x6b39, + 0x6fd1, 0x71d1, 0x341f, 0x7280, 0x2e5d, 0x3036, 0x33e5, 0x333a, + 0x52d7, 0x5396, 0x57e9, 0x62e6, 0x6eaf, 0x79c6, 0x79c8, 0x79d2, + 0x3177, 0x411a, 0x665e, 0x35b0, 0x5a7a, 0x3076, 0x3bd3, 0x7047, + 0x7685, 0x2e32, 0x4adb, 0x71e7, 0x3c51, 0x3c48, + /* 0x13721..0x1377E */ + 0x4398, 0x5a9f, 0x4c93, 0x7774, 0x6f61, 0x5aaa, 0x518a, 0x7688, + 0x5c82, 0x4817, 0x5e70, 0x4851, 0x736c, 0x32f2, 0x341b, 0x65ab, + 0x6a13, 0x5fa4, 0x6ecd, 0x70e1, 0x3366, 0x6888, 0x5941, 0x2fc2, + 0x30be, 0x3211, 0x3144, 0x3553, 0x372d, 0x53ea, 0x378b, 0x3951, + 0x3f62, 0x3f84, 0x4075, 0x4176, 0x4167, 0x41a9, 0x43b2, 0x443a, + 0x456c, 0x466f, 0x4842, 0x4e13, 0x5566, 0x5a3d, 0x5cfb, 0x5d4c, + 0x5d99, 0x5e4b, 0x5f6b, 0x630e, 0x634a, 0x66cd, 0x6a08, 0x6a63, + 0x6b66, 0x6efd, 0x781a, 0x7d8f, 0x62b8, 0x6fce, 0x7be8, 0x3287, + 0x421f, 0x4483, 0x4fc0, 0x7699, 0x4841, 0x3091, 0x4b20, 0x4c7a, + 0x4f54, 0x5a74, 0x5d50, 0x6840, 0x6a23, 0x4708, 0x2ef6, 0x3039, + 0x3026, 0x3065, 0x317c, 0x3238, 0x3263, 0x35a7, 0x370f, 0x3805, + 0x3acc, 0x3efa, 0x41b2, 0x41f8, 0x42f3, 0x4372, + /* 0x13821..0x1387E */ + 0x491c, 0x4a29, 0x527d, 0x52ac, 0x532e, 0x5814, 0x586f, 0x5d79, + 0x570c, 0x60a9, 0x698b, 0x6b19, 0x6ce2, 0x6ed2, 0x7063, 0x7375, + 0x767a, 0x7855, 0x7a13, 0x7e78, 0x3143, 0x339f, 0x33b3, 0x3e7b, + 0x3f26, 0x4e1b, 0x4e90, 0x5384, 0x53fe, 0x5d43, 0x6237, 0x6a00, + 0x6afa, 0x7650, 0x2e4e, 0x300b, 0x33e4, 0x347c, 0x36fa, 0x39d1, + 0x3b64, 0x3df1, 0x3eab, 0x3f27, 0x4238, 0x4545, 0x47af, 0x4e56, + 0x52d0, 0x5cca, 0x68b4, 0x60a1, 0x60e1, 0x63f0, 0x664e, 0x6a87, + 0x6de8, 0x7237, 0x76c7, 0x7867, 0x7f13, 0x2e94, 0x2e92, 0x2f0d, + 0x3348, 0x3449, 0x343e, 0x3a2f, 0x3f8c, 0x3fa1, 0x409f, 0x48a7, + 0x4a8e, 0x545a, 0x5881, 0x6a9e, 0x6aa4, 0x6b77, 0x7190, 0x2e5e, + 0x7bc9, 0x2ea4, 0x2f7c, 0x2faf, 0x3019, 0x3016, 0x3149, 0x316c, + 0x329f, 0x32b9, 0x32fe, 0x339a, 0x33e3, 0x3411, + /* 0x13921..0x1397E */ + 0x340e, 0x3589, 0x3751, 0x37a2, 0x397d, 0x3b54, 0x3b5d, 0x3b8f, + 0x3de5, 0x3de7, 0x3df7, 0x3e78, 0x3e83, 0x3e9a, 0x3eb7, 0x3f18, + 0x4052, 0x414c, 0x4297, 0x42d8, 0x43a7, 0x453b, 0x4602, 0x4643, + 0x46f4, 0x476d, 0x4821, 0x4897, 0x49cb, 0x4c5f, 0x4d2a, 0x4d69, + 0x4e2f, 0x4e9d, 0x5532, 0x5687, 0x586c, 0x5a3f, 0x5ce0, 0x5d05, + 0x5d18, 0x5d5e, 0x5db1, 0x6015, 0x6003, 0x60af, 0x60b1, 0x6154, + 0x618f, 0x622a, 0x6352, 0x684c, 0x6861, 0x6b1b, 0x6ca2, 0x6cfc, + 0x70ca, 0x7175, 0x7271, 0x583f, 0x72fc, 0x75a4, 0x764d, 0x7805, + 0x7999, 0x7ad8, 0x7d3b, 0x325b, 0x32ab, 0x33f7, 0x3408, 0x38d5, + 0x42f7, 0x4fe0, 0x6c6a, 0x6f5f, 0x7eb9, 0x314b, 0x323b, 0x344a, + 0x36fd, 0x5a40, 0x7177, 0x7d60, 0x7ed2, 0x5344, 0x4f09, 0x6170, + 0x5511, 0x3ffd, 0x40da, 0x7aa8, 0x52db, 0x6fbc, + /* 0x13A21..0x13A7E */ + 0x4b64, 0x7803, 0x2eca, 0x36f0, 0x3764, 0x38be, 0x3a5a, 0x4068, + 0x41c7, 0x460f, 0x4606, 0x4839, 0x48b1, 0x4df7, 0x55d5, 0x5d3a, + 0x626e, 0x7b42, 0x2e9b, 0x2f50, 0x33c9, 0x3506, 0x3d6f, 0x3de6, + 0x3dee, 0x47fb, 0x4c99, 0x5473, 0x5802, 0x6a50, 0x7396, 0x68df, + 0x3750, 0x3ea7, 0x432b, 0x30b5, 0x30ac, 0x318d, 0x4700, 0x34c9, + 0x385e, 0x39bb, 0x3bb0, 0x3f69, 0x424d, 0x43a1, 0x483d, 0x4b73, + 0x4e08, 0x507d, 0x71c7, 0x5280, 0x5815, 0x5826, 0x596d, 0x458e, + 0x5d30, 0x63dc, 0x68c1, 0x6f09, 0x769b, 0x3264, 0x3728, 0x4750, + 0x5f6a, 0x6ca1, 0x31b4, 0x3742, 0x762a, 0x383a, 0x498a, 0x60b4, + 0x34b2, 0x3d0e, 0x37fc, 0x5895, 0x7dfa, 0x2f5c, 0x324a, 0x348b, + 0x443e, 0x4628, 0x4714, 0x47f5, 0x5a84, 0x5b56, 0x5d22, 0x732f, + 0x485c, 0x7bad, 0x5b39, 0x3319, 0x318a, 0x3237, + /* 0x13B21..0x13B7E */ + 0x3bdf, 0x42f6, 0x44ae, 0x44e6, 0x472d, 0x4bba, 0x65a9, 0x76d1, + 0x5690, 0x7bd6, 0x434c, 0x7306, 0x7bab, 0x56bf, 0x4652, 0x2e09, + 0x3098, 0x33c2, 0x3c71, 0x40e8, 0x4492, 0x4563, 0x485f, 0x51e6, + 0x53ca, 0x5523, 0x5b97, 0x5e82, 0x6695, 0x6b83, 0x6cdb, 0x7178, + 0x7910, 0x45ac, 0x46ab, 0x4b8b, 0x2ed5, 0x2ed4, 0x2f3a, 0x2f7f, + 0x323a, 0x33f8, 0x33f2, 0x35e3, 0x36db, 0x38eb, 0x39cb, 0x39c9, + 0x39ff, 0x3b50, 0x3c4d, 0x3e02, 0x3e2b, 0x3fd7, 0x401d, 0x4307, + 0x452f, 0x3b5c, 0x45af, 0x45bd, 0x45e8, 0x479d, 0x4b62, 0x4b7b, + 0x4c0f, 0x5345, 0x5949, 0x59c1, 0x5cf8, 0x5d19, 0x5d2b, 0x60a2, + 0x6102, 0x61f3, 0x6996, 0x6a5e, 0x6a69, 0x6a66, 0x6a8c, 0x6aee, + 0x6cc7, 0x6cdc, 0x76cc, 0x78fc, 0x4b6f, 0x2e8b, 0x2f3c, 0x2f8d, + 0x3150, 0x3b57, 0x3bfa, 0x4148, 0x4301, 0x4642, + /* 0x13C21..0x13C7E */ + 0x4b21, 0x4ecb, 0x4cbb, 0x523e, 0x54bd, 0x55d4, 0x58c1, 0x593a, + 0x600c, 0x6033, 0x61ea, 0x6494, 0x6f9e, 0x4c50, 0x7e7f, 0x3f0f, + 0x6b58, 0x7d2b, 0x5afa, 0x6ef8, 0x3b8d, 0x76eb, 0x2e03, 0x33f1, + 0x37f7, 0x3931, 0x3ac9, 0x3ba4, 0x4089, 0x4e7f, 0x4f06, 0x55be, + 0x6cea, 0x3b9f, 0x6500, 0x5be0, 0x3072, 0x47f4, 0x629d, 0x3c61, + 0x654a, 0x5e1e, 0x620e, 0x3199, 0x3c04, 0x4368, 0x6d66, 0x459c, + 0x516e, 0x593e, 0x5d17, 0x6005, 0x6b1d, 0x6eca, 0x706e, 0x66c7, + 0x70aa, 0x301f, 0x32fa, 0x3c3a, 0x4753, 0x507c, 0x5235, 0x714c, + 0x71c8, 0x732b, 0x62e5, 0x3bc2, 0x3f31, 0x40f9, 0x2e3b, 0x33d6, + 0x3b88, 0x424b, 0x4731, 0x4b8a, 0x52e9, 0x53e0, 0x5a2e, 0x616b, + 0x6da3, 0x7152, 0x7996, 0x3112, 0x33d7, 0x346a, 0x3bff, 0x4388, + 0x4a39, 0x5dac, 0x7700, 0x36da, 0x33ce, 0x3468, + /* 0x13D21..0x13D7E */ + 0x3b97, 0x3c31, 0x3dde, 0x2fee, 0x4101, 0x42fe, 0x4d32, 0x59c0, + 0x59cb, 0x5d42, 0x5e4d, 0x5fd2, 0x61ed, 0x621f, 0x6490, 0x6846, + 0x6972, 0x6b90, 0x6e74, 0x6f2f, 0x7031, 0x714b, 0x716c, 0x76c6, + 0x719c, 0x2ec0, 0x2f4f, 0x3145, 0x3341, 0x3f93, 0x420e, 0x47d4, + 0x4c41, 0x4e0b, 0x5363, 0x5e26, 0x71cd, 0x7283, 0x33d4, 0x3919, + 0x3bbf, 0x4dd1, 0x595d, 0x5e2e, 0x5c9b, 0x387e, 0x519f, 0x31fa, + 0x6853, 0x6ff0, 0x2fca, 0x3cfb, 0x4625, 0x57ac, 0x5ae3, 0x621c, + 0x79ff, 0x31c6, 0x3faa, 0x45ec, 0x496f, 0x4b89, 0x4df3, 0x4e96, + 0x4f64, 0x56fe, 0x5d14, 0x3de1, 0x7075, 0x7187, 0x7806, 0x31e6, + 0x321d, 0x4240, 0x4691, 0x46d9, 0x4e1a, 0x3eb6, 0x5dd2, 0x5f72, + 0x46f8, 0x65af, 0x65f7, 0x6af8, 0x32a9, 0x33d9, 0x3973, 0x3e8f, + 0x3f90, 0x4055, 0x72e4, 0x7664, 0x30b7, 0x311f, + /* 0x13E21..0x13E7E */ + 0x32dd, 0x3320, 0x3347, 0x33ec, 0x34e8, 0x3546, 0x3531, 0x3617, + 0x3968, 0x39be, 0x3a3c, 0x3bb5, 0x3c06, 0x3c0f, 0x3c11, 0x3c1a, + 0x3e84, 0x3e8a, 0x3ee0, 0x3f70, 0x427f, 0x4284, 0x42db, 0x438c, + 0x4377, 0x4607, 0x460c, 0x462d, 0x4676, 0x477e, 0x48a2, 0x4a1f, + 0x4a35, 0x4cbc, 0x4d88, 0x4e09, 0x4e58, 0x513c, 0x5126, 0x5167, + 0x55c7, 0x5701, 0x585d, 0x5901, 0x5965, 0x59f0, 0x5ae0, 0x5b11, + 0x5ca7, 0x5d39, 0x6096, 0x63d6, 0x648b, 0x6549, 0x685d, 0x68f3, + 0x6a1f, 0x6a3c, 0x6a54, 0x6a73, 0x6c61, 0x6cde, 0x71a4, 0x7266, + 0x737e, 0x7418, 0x769c, 0x7798, 0x2e0a, 0x2e08, 0x2e1e, 0x2e57, + 0x3197, 0x3270, 0x37ce, 0x3834, 0x38cc, 0x3b22, 0x3e38, 0x40c5, + 0x44fe, 0x4761, 0x4756, 0x4d44, 0x52b6, 0x5573, 0x5a63, 0x64b8, + 0x6b72, 0x71b8, 0x7320, 0x3631, 0x37f4, 0x78fe, + /* 0x13F21..0x13F7E */ + 0x42ed, 0x490d, 0x4b96, 0x51ed, 0x5e54, 0x6077, 0x6272, 0x69e6, + 0x78df, 0x6755, 0x6fb1, 0x3c3b, 0x2f38, 0x2fe1, 0x2fb5, 0x3507, + 0x3a20, 0x3bdd, 0x3be9, 0x3fc3, 0x414e, 0x432f, 0x45b0, 0x464b, + 0x48ee, 0x499b, 0x4d78, 0x4df1, 0x5533, 0x55b9, 0x571f, 0x595e, + 0x59e6, 0x5d33, 0x61e3, 0x62af, 0x65aa, 0x69aa, 0x6a3a, 0x6eab, + 0x6f9b, 0x7032, 0x71dd, 0x7707, 0x2eba, 0x2ec1, 0x3203, 0x3875, + 0x38ec, 0x3c0b, 0x551a, 0x3c3d, 0x614e, 0x6a0a, 0x6fc5, 0x7663, + 0x776d, 0x5b25, 0x6acf, 0x7808, 0x7162, 0x36f3, 0x33a8, 0x7017, + 0x3439, 0x3782, 0x3e25, 0x43a8, 0x4c34, 0x508a, 0x5761, 0x5c8b, + 0x5fe0, 0x6870, 0x7042, 0x7154, 0x7310, 0x7318, 0x768f, 0x545e, + 0x7ac4, 0x3d07, 0x3d69, 0x4570, 0x47a2, 0x6da8, 0x76db, 0x436e, + 0x4749, 0x4919, 0x63c5, 0x7817, 0x76c0, 0x68fe, + /* 0x14021..0x1407E */ + 0x4f84, 0x447a, 0x3bf8, 0x2e16, 0x502c, 0x555d, 0x462f, 0x31c4, + 0x3236, 0x32e2, 0x39d3, 0x3f81, 0x4027, 0x4210, 0x453f, 0x4574, + 0x461f, 0x4674, 0x48f2, 0x4816, 0x4b63, 0x4e05, 0x5272, 0x551f, + 0x56db, 0x5cbe, 0x6056, 0x38f0, 0x68fd, 0x697f, 0x6aa0, 0x6a93, + 0x6acb, 0x701d, 0x7192, 0x7752, 0x7759, 0x4589, 0x5a0e, 0x6106, + 0x76bb, 0x3e2d, 0x40dc, 0x421a, 0x45a5, 0x4614, 0x4790, 0x57f3, + 0x5a4d, 0x5c4d, 0x5e3e, 0x610a, 0x6cac, 0x6d64, 0x6de1, 0x6e5f, + 0x58a9, 0x3207, 0x42d9, 0x43a5, 0x4442, 0x4298, 0x6a2d, 0x5a83, + 0x5bc0, 0x6aac, 0x76ea, 0x5d76, 0x620c, 0x6749, 0x2ed9, 0x3148, + 0x3343, 0x3360, 0x3ba3, 0x3c02, 0x3c16, 0x3ddd, 0x4226, 0x4247, + 0x44b0, 0x4813, 0x4834, 0x4cc9, 0x4d45, 0x4d17, 0x47d3, 0x4f5c, + 0x514e, 0x517d, 0x45cb, 0x5a7f, 0x5bad, 0x5dda, + /* 0x14121..0x1417E */ + 0x5e4a, 0x5fa8, 0x617a, 0x621b, 0x6239, 0x65a6, 0x6a6e, 0x6cce, + 0x6df5, 0x7078, 0x7077, 0x72ad, 0x7291, 0x7583, 0x7bae, 0x324d, + 0x3584, 0x4f38, 0x5136, 0x3168, 0x5985, 0x5e55, 0x61b3, 0x5cce, + 0x364c, 0x3851, 0x3ca8, 0x43aa, 0x46fe, 0x46fd, 0x495a, 0x52d9, + 0x558f, 0x558e, 0x590e, 0x5956, 0x59df, 0x5c97, 0x5d20, 0x5d44, + 0x6607, 0x6a34, 0x763b, 0x7061, 0x7f20, 0x30e7, 0x3275, 0x33cc, + 0x33e2, 0x3009, 0x35aa, 0x38ee, 0x394f, 0x523d, 0x3b8b, 0x3c64, + 0x331d, 0x40e3, 0x40f3, 0x435c, 0x4383, 0x433f, 0x43bb, 0x44cd, + 0x45e9, 0x46f9, 0x3de3, 0x49cd, 0x49fd, 0x4f15, 0x51e5, 0x2e89, + 0x55e9, 0x56f8, 0x5a93, 0x5cdf, 0x5dcf, 0x5d9c, 0x6061, 0x6349, + 0x6358, 0x646c, 0x64bc, 0x65fb, 0x68c5, 0x6d70, 0x7001, 0x706d, + 0x7397, 0x771c, 0x7a12, 0x30cf, 0x3897, 0x418e, + /* 0x14221..0x1427E */ + 0x61d3, 0x6535, 0x6d08, 0x7020, 0x2fc3, 0x3074, 0x3247, 0x3373, + 0x406f, 0x4349, 0x475f, 0x4e2c, 0x6db3, 0x701f, 0x2fd7, 0x3c5e, + 0x6cca, 0x45cf, 0x5d9a, 0x3352, 0x6896, 0x3176, 0x43c3, 0x3b58, + 0x3b6b, 0x3c0a, 0x440d, 0x4751, 0x705c, 0x2ed6, 0x391a, 0x392a, + 0x4c70, 0x6a51, 0x353e, 0x3815, 0x39a5, 0x40f0, 0x4253, 0x47c1, + 0x6235, 0x4955, 0x7640, 0x79c4, 0x7a28, 0x2f53, 0x3806, 0x3bfe, + 0x6010, 0x3cb1, 0x3e2f, 0x3f85, 0x4020, 0x414b, 0x4234, 0x46ff, + 0x4cf0, 0x4ede, 0x60ce, 0x617f, 0x62d4, 0x688b, 0x6cb8, 0x7000, + 0x702e, 0x768a, 0x7edb, 0x7bdb, 0x2ee3, 0x33f0, 0x3927, 0x5b2c, + 0x718d, 0x784c, 0x7df9, 0x4edd, 0x5027, 0x3353, 0x3544, 0x3b85, + 0x4258, 0x429e, 0x42d3, 0x4ca2, 0x4fef, 0x5422, 0x6a17, 0x7438, + 0x4fc1, 0x6afe, 0x6338, 0x31e7, 0x66f8, 0x33ea, + /* 0x14321..0x1437E */ + 0x33e9, 0x2f46, 0x7054, 0x6fb0, 0x396a, 0x6131, 0x3dfd, 0x5aea, + 0x6fbf, 0x48da, 0x6c37, 0x52f8, 0x7c48, 0x4a3d, 0x6ab0, 0x2e39, + 0x3358, 0x3606, 0x3766, 0x42c5, 0x43a2, 0x45e6, 0x4b4e, 0x4de1, + 0x4e5b, 0x50ad, 0x57ed, 0x5aef, 0x5baa, 0x5dbb, 0x603d, 0x60c6, + 0x66cb, 0x6a95, 0x735b, 0x36e3, 0x38c7, 0x3f3e, 0x45ad, 0x4696, + 0x4a80, 0x4bb5, 0x5537, 0x6ac7, 0x3024, 0x57e5, 0x3730, 0x3f1b, + 0x4065, 0x467a, 0x4c60, 0x55f4, 0x5a1a, 0x5f6e, 0x61f4, 0x6718, + 0x7045, 0x79b3, 0x5bc9, 0x555c, 0x5af9, 0x5b51, 0x64c4, 0x7010, + 0x59e9, 0x5a92, 0x6336, 0x3ae1, 0x5740, 0x2e2d, 0x2ef2, 0x3b99, + 0x3fe0, 0x42bd, 0x463c, 0x47f1, 0x4ce8, 0x666b, 0x6877, 0x6a3b, + 0x714e, 0x72f3, 0x79d0, 0x4a17, 0x5026, 0x532a, 0x62e7, 0x6457, + 0x6caf, 0x2e01, 0x3146, 0x31cb, 0x358b, 0x3bf5, + /* 0x14421..0x1447E */ + 0x3e16, 0x3e33, 0x3e81, 0x3f14, 0x3f35, 0x3f6b, 0x3fb4, 0x41f2, + 0x4311, 0x46a2, 0x471d, 0x4f6e, 0x5252, 0x553a, 0x573a, 0x6074, + 0x6139, 0x6178, 0x6776, 0x6abf, 0x6adc, 0x6d85, 0x6df3, 0x729a, + 0x7577, 0x7802, 0x7ce5, 0x32c5, 0x4357, 0x56f4, 0x4715, 0x4c88, + 0x53cd, 0x6cc3, 0x73ae, 0x7673, 0x4d25, 0x389c, 0x490e, 0x49cc, + 0x6ffd, 0x739a, 0x55db, 0x701a, 0x385a, 0x4802, 0x43b4, 0x49fb, + 0x2f43, 0x4f2c, 0x47d8, 0x6fbb, 0x6526, 0x5db4, 0x7354, 0x493f, + 0x4f70, 0x376a, 0x38f7, 0x3b2c, 0x5d2c, 0x522a, 0x340a, 0x71e3, + 0x7db4, 0x2ead, 0x2f4e, 0x305c, 0x3075, 0x3243, 0x6c9e, 0x3448, + 0x3824, 0x3b9a, 0x3e1d, 0x3e95, 0x3ead, 0x3ef7, 0x3f1f, 0x408c, + 0x42b5, 0x433a, 0x43d0, 0x48af, 0x4c40, 0x5887, 0x598e, 0x5a0b, + 0x5de0, 0x6247, 0x6a02, 0x6ae6, 0x6e44, 0x7013, + /* 0x14521..0x1457E */ + 0x70b8, 0x712d, 0x71d8, 0x7f0e, 0x4ce5, 0x4458, 0x44e2, 0x4575, + 0x4ef4, 0x5684, 0x5b1b, 0x7069, 0x73d1, 0x4eba, 0x34f2, 0x3fb9, + 0x44a4, 0x6f4d, 0x6fed, 0x7244, 0x3178, 0x386b, 0x3929, 0x3c55, + 0x3e97, 0x4dfb, 0x5e8f, 0x551c, 0x6cbc, 0x6ee2, 0x785b, 0x50b9, + 0x2f1d, 0x4bbf, 0x4fb1, 0x5530, 0x76fb, 0x314e, 0x3410, 0x3835, + 0x3857, 0x39ac, 0x3c60, 0x3f92, 0x4597, 0x475c, 0x4e21, 0x567b, + 0x63df, 0x6ced, 0x7014, 0x70fd, 0x734d, 0x5825, 0x583a, 0x32aa, + 0x3ea6, 0x371f, 0x3974, 0x4012, 0x3012, 0x315a, 0x31ac, 0x31cd, + 0x3200, 0x3510, 0x3854, 0x3858, 0x3957, 0x3b95, 0x3cf6, 0x3d8b, + 0x40bc, 0x4295, 0x442d, 0x4771, 0x4843, 0x48bc, 0x48df, 0x56d7, + 0x4dd8, 0x4e6f, 0x4d9b, 0x506f, 0x51c8, 0x3f53, 0x55d8, 0x5977, + 0x5b49, 0x5b54, 0x5b52, 0x5cd6, 0x5d71, 0x3230, + /* 0x14621..0x1467E */ + 0x6463, 0x6569, 0x65e4, 0x6a0e, 0x6b04, 0x6c46, 0x6e0f, 0x7003, + 0x700f, 0x7419, 0x7676, 0x782d, 0x7a30, 0x75d8, 0x30cd, 0x32d5, + 0x340c, 0x3802, 0x3c0e, 0x41a7, 0x449e, 0x4d1e, 0x57b3, 0x5ae5, + 0x60f4, 0x6404, 0x7053, 0x7285, 0x3ce0, 0x7d07, 0x333f, 0x3f97, + 0x3fb3, 0x4d9c, 0x5279, 0x5763, 0x59bf, 0x5be4, 0x4bd2, 0x52ec, + 0x6aad, 0x4803, 0x4a61, 0x31f8, 0x5a81, 0x4934, 0x3c4a, 0x7cf6, + 0x62eb, 0x3bc5, 0x7149, 0x501e, 0x3678, 0x3c6f, 0x40c7, 0x4566, + 0x4c8c, 0x6c5a, 0x7041, 0x7813, 0x3451, 0x46c7, 0x720d, 0x3948, + 0x70a3, 0x3185, 0x2e4d, 0x31ea, 0x6599, 0x6b0e, 0x5058, 0x437a, + 0x734b, 0x4962, 0x79b4, 0x5e04, 0x5577, 0x3357, 0x4960, 0x6edf, + 0x76e3, 0x4c5d, 0x2e8c, 0x3c3c, 0x3f10, 0x6fe9, 0x3302, 0x6cd1, + 0x6089, 0x6679, 0x3eff, 0x45e5, 0x2e73, 0x3165, + /* 0x14721..0x1477E */ + 0x3982, 0x3c3f, 0x77ee, 0x2efb, 0x398a, 0x3fcd, 0x6a8d, 0x4fe1, + 0x59b0, 0x5962, 0x3be7, 0x6471, 0x532b, 0x51b1, 0x3e74, 0x3ff5, + 0x437b, 0x449a, 0x51c3, 0x5c98, 0x2e43, 0x3efc, 0x2e4b, 0x37dc, + 0x36a2, 0x40a9, 0x4fc3, 0x5d0d, 0x60fd, 0x6133, 0x61bf, 0x6fb2, + 0x6997, 0x66a4, 0x3df4, 0x428a, 0x44ad, 0x6987, 0x4777, 0x4ce2, + 0x4d3e, 0x5436, 0x5834, 0x3a46, 0x5f75, 0x62ad, 0x79ac, 0x2ff3, + 0x3ec3, 0x42dd, 0x4392, 0x4557, 0x476f, 0x56c3, 0x524c, 0x60cc, + 0x60ba, 0x6f29, 0x714d, 0x300d, 0x37f9, 0x3a92, 0x4885, 0x4973, + 0x5164, 0x52fd, 0x6cb7, 0x38f2, 0x6ce0, 0x766a, 0x7019, 0x677f, + 0x59e4, 0x57e7, 0x6429, 0x2f2f, 0x3265, 0x335a, 0x42cd, 0x47cf, + 0x4cca, 0x567d, 0x5b94, 0x5c95, 0x6236, 0x6584, 0x6feb, 0x46dd, + 0x4f20, 0x5206, 0x5e1b, 0x63ab, 0x79c1, 0x7ea6, + /* 0x14821..0x1487E */ + 0x31fd, 0x5bb1, 0x5872, 0x5bb8, 0x6087, 0x5b48, 0x4ae8, 0x3e61, + 0x608c, 0x5551, 0x5560, 0x316b, 0x7262, 0x4e8c, 0x567a, 0x7197, + 0x7aea, 0x2f10, 0x5f70, 0x429c, 0x5b4f, 0x75a5, 0x7ce9, 0x367a, + 0x3859, 0x66e4, 0x76bc, 0x2f34, 0x3224, 0x334a, 0x33cd, 0x33db, + 0x3e06, 0x442c, 0x4591, 0x477f, 0x4c3e, 0x4c4e, 0x5248, 0x52af, + 0x53ed, 0x5554, 0x5e41, 0x622c, 0x65e9, 0x6ca9, 0x5bc4, 0x71c6, + 0x5169, 0x7812, 0x78ef, 0x433d, 0x4669, 0x556a, 0x56e4, 0x58d0, + 0x6543, 0x66ee, 0x332a, 0x3351, 0x3426, 0x3983, 0x3e87, 0x3f7c, + 0x40b2, 0x4249, 0x4279, 0x42ab, 0x4590, 0x4bd4, 0x4ccc, 0x55b2, + 0x56ae, 0x5891, 0x59d8, 0x5dcb, 0x5f77, 0x60a5, 0x68ab, 0x6ab9, + 0x6cbb, 0x707f, 0x775e, 0x78db, 0x4a0b, 0x5c38, 0x3099, 0x3c3e, + 0x3fae, 0x4787, 0x4bd8, 0x5435, 0x5709, 0x5f8e, + /* 0x14921..0x1497E */ + 0x7f3b, 0x47ca, 0x5a17, 0x3339, 0x558b, 0x7aed, 0x3f66, 0x619d, + 0x63f1, 0x6098, 0x3f3c, 0x3fc5, 0x5562, 0x5b46, 0x703c, 0x4867, + 0x39eb, 0x3a9b, 0x5d10, 0x567e, 0x6b2c, 0x2ff5, 0x3f6a, 0x4a19, + 0x4c37, 0x4f02, 0x54e2, 0x5968, 0x6868, 0x6a55, 0x6c79, 0x3edf, + 0x43cf, 0x55c5, 0x59d2, 0x62d7, 0x7328, 0x72f2, 0x649c, 0x66ed, + 0x7c2d, 0x34c1, 0x3f6c, 0x458c, 0x4d5c, 0x5015, 0x6ca7, 0x6cd3, + 0x783b, 0x454f, 0x54f6, 0x2e0d, 0x2ed8, 0x37e0, 0x392b, 0x3a66, + 0x3bcc, 0x31a8, 0x3e03, 0x3e9c, 0x4016, 0x4276, 0x4577, 0x45a7, + 0x466e, 0x4d6e, 0x5236, 0x5b26, 0x6150, 0x619a, 0x6299, 0x6b5c, + 0x6ca0, 0x6ce6, 0x6d74, 0x761c, 0x7644, 0x2fae, 0x44ab, 0x4b66, + 0x621e, 0x6461, 0x656a, 0x70e8, 0x3c01, 0x4953, 0x78a8, 0x647a, + 0x6557, 0x2f0f, 0x326f, 0x3fa9, 0x3e45, 0x470d, + /* 0x14A21..0x14A7E */ + 0x598f, 0x6179, 0x6907, 0x6986, 0x4df5, 0x3f17, 0x4255, 0x4cb8, + 0x2ecf, 0x5269, 0x7b92, 0x3206, 0x343b, 0x3674, 0x38b3, 0x41a4, + 0x426e, 0x511a, 0x396e, 0x5c89, 0x5cde, 0x5d1b, 0x76f0, 0x4587, + 0x605e, 0x2e19, 0x2f75, 0x3175, 0x3840, 0x3e63, 0x3e73, 0x3f0a, + 0x47c4, 0x2e26, 0x653d, 0x7589, 0x765b, 0x5c73, 0x7801, 0x30fb, + 0x38c1, 0x5656, 0x58a7, 0x3225, 0x57a5, 0x6511, 0x5b86, 0x304f, + 0x3909, 0x5247, 0x5bc7, 0x5de8, 0x6fba, 0x6fd4, 0x704d, 0x2fbf, + 0x32c9, 0x3a29, 0x3f01, 0x77ad, 0x2fdd, 0x6217, 0x72ea, 0x3703, + 0x4355, 0x4b69, 0x552b, 0x68dc, 0x6f14, 0x5a42, 0x32df, 0x3893, + 0x4155, 0x420a, 0x46ae, 0x4bcd, 0x5c3f, 0x63e9, 0x3023, 0x2ff8, + 0x3305, 0x3446, 0x3831, 0x3949, 0x3b9d, 0x3cf0, 0x3cef, 0x3d29, + 0x3e96, 0x42b1, 0x4367, 0x453e, 0x45b9, 0x470b, + /* 0x14B21..0x14B7E */ + 0x4cd5, 0x4ce1, 0x50f9, 0x5832, 0x5e2b, 0x60de, 0x62b3, 0x640c, + 0x64ec, 0x6702, 0x6912, 0x6a2a, 0x6c4a, 0x70a6, 0x72d2, 0x78fd, + 0x7cf3, 0x7d6c, 0x2e4f, 0x2ea1, 0x308d, 0x3256, 0x374a, 0x39a8, + 0x3e3d, 0x3fd8, 0x3fd9, 0x423f, 0x46b4, 0x471b, 0x47d0, 0x48d2, + 0x3192, 0x5d21, 0x60aa, 0x61a8, 0x6b00, 0x6c8c, 0x6cbf, 0x727e, + 0x7632, 0x3420, 0x782c, 0x3317, 0x30d5, 0x335c, 0x38a8, 0x44b2, + 0x4734, 0x5267, 0x5766, 0x5a46, 0x71e6, 0x32c3, 0x4ca1, 0x4b86, + 0x3800, 0x3e4c, 0x3954, 0x472c, 0x5ffb, 0x31e1, 0x56c6, 0x4469, + 0x58e8, 0x7b54, 0x7ebb, 0x37cb, 0x39b9, 0x4627, 0x479a, 0x4bce, + 0x34e9, 0x49d9, 0x3e55, 0x619c, 0x4795, 0x7baa, 0x47fe, 0x7c52, + 0x485d, 0x2ea6, 0x2fe3, 0x33c8, 0x42b9, 0x472b, 0x4cab, 0x6fc4, + 0x2fad, 0x5e6d, 0x7ebf, 0x2e07, 0x4162, 0x4e80, + /* 0x14C21..0x14C7E */ + 0x4f2b, 0x6513, 0x3473, 0x472a, 0x7b45, 0x3df3, 0x5b95, 0x3cac, + 0x3bc6, 0x671c, 0x4e4a, 0x64d1, 0x5a14, 0x6108, 0x3999, 0x5c8d, + 0x4c11, 0x5720, 0x32d9, 0x3922, 0x5121, 0x525f, 0x57db, 0x7727, + 0x7d61, 0x490b, 0x3a7f, 0x3a18, 0x31a5, 0x340d, 0x347d, 0x460e, + 0x56df, 0x6ff7, 0x7298, 0x7cf4, 0x39ea, 0x525d, 0x4ec5, 0x314d, + 0x48c9, 0x5dbf, 0x5dec, 0x7762, 0x7eba, 0x4478, 0x4a21, 0x6302, + 0x3984, 0x3b5f, 0x4bdb, 0x531b, 0x56f2, 0x5db2, 0x6017, 0x6499, + 0x3132, 0x4728, 0x7ed9, 0x56ee, 0x4762, 0x32ff, 0x7905, 0x3c24, + 0x423b, 0x5c7e, 0x6cb0, 0x354f, 0x40b6, 0x5d0b, 0x7580, 0x3301, + 0x2e5f, 0x31b6, 0x391c, 0x523a, 0x6036, 0x71ce, 0x3f25, 0x57e2, + 0x3384, 0x3f79, 0x5d04, 0x65ac, 0x6a33, 0x6e8d, 0x7756, 0x47f3, + 0x65ae, 0x7453, 0x4109, 0x4108, 0x4cb9, 0x5652, + /* 0x14D21..0x14D7E */ + 0x6aed, 0x6f38, 0x352f, 0x2f51, 0x312a, 0x32c7, 0x33cb, 0x3ba5, + 0x3e7d, 0x40a0, 0x4182, 0x43d6, 0x4709, 0x47da, 0x4e67, 0x4d8c, + 0x5336, 0x5337, 0x5531, 0x5950, 0x68d5, 0x6a98, 0x704a, 0x7091, + 0x70f5, 0x76c4, 0x678d, 0x3915, 0x2e88, 0x2f59, 0x2e0e, 0x6a89, + 0x6f3f, 0x7810, 0x30ad, 0x3e7c, 0x3996, 0x3bb9, 0x3eb8, 0x43da, + 0x43fa, 0x44c1, 0x46dc, 0x494a, 0x49d8, 0x4d0b, 0x4eb6, 0x5194, + 0x5528, 0x5aaf, 0x5f8a, 0x6000, 0x6449, 0x64c9, 0x6981, 0x6b21, + 0x6e0a, 0x7065, 0x767d, 0x790a, 0x417e, 0x4291, 0x4b32, 0x4c83, + 0x4d74, 0x5fcc, 0x5ffc, 0x4dc0, 0x5f85, 0x67ba, 0x68f8, 0x4765, + 0x63b1, 0x783c, 0x76f7, 0x4d1b, 0x5d61, 0x643d, 0x716a, 0x2e71, + 0x3375, 0x3d50, 0x4b04, 0x4feb, 0x65cd, 0x662d, 0x69a7, 0x3229, + 0x340f, 0x3c65, 0x474e, 0x48a8, 0x5406, 0x5483, + /* 0x14E21..0x14E7E */ + 0x55e2, 0x68cf, 0x68e1, 0x71cc, 0x76e2, 0x7678, 0x3f8b, 0x5387, + 0x5acb, 0x644e, 0x43a0, 0x5565, 0x3289, 0x4d41, 0x4e9c, 0x5409, + 0x5559, 0x586b, 0x5c92, 0x7686, 0x5adc, 0x7f8d, 0x2fb6, 0x416e, + 0x45c5, 0x665c, 0x2e86, 0x2eae, 0x30da, 0x2e21, 0x31cc, 0x3bee, + 0x4599, 0x4881, 0x4dbc, 0x531f, 0x5642, 0x57ad, 0x5a1c, 0x5ce7, + 0x626f, 0x6ad2, 0x707c, 0x71cf, 0x7675, 0x7818, 0x329b, 0x5dd1, + 0x302b, 0x3398, 0x4797, 0x4dcb, 0x51d0, 0x5433, 0x61e8, 0x6f2a, + 0x76a3, 0x7c57, 0x7e9f, 0x5460, 0x3841, 0x4d99, 0x5d2f, 0x785e, + 0x2ee4, 0x2f36, 0x2f8b, 0x31b7, 0x32b1, 0x3dba, 0x401c, 0x53b2, + 0x593c, 0x62d3, 0x7234, 0x76b7, 0x76f6, 0x770a, 0x7e97, 0x7f62, + 0x46a6, 0x4b74, 0x3217, 0x32a3, 0x50c8, 0x68c2, 0x3ec9, 0x404b, + 0x4190, 0x4f23, 0x5149, 0x5c3e, 0x5df4, 0x606f, + /* 0x14F21..0x14F7E */ + 0x64ee, 0x7023, 0x732c, 0x3442, 0x7b6f, 0x4ad3, 0x5089, 0x6cc2, + 0x6def, 0x7732, 0x32b4, 0x3a41, 0x3eca, 0x3f04, 0x4717, 0x497c, + 0x4994, 0x4d6a, 0x4f0f, 0x5262, 0x52fc, 0x5bed, 0x6001, 0x607e, + 0x674b, 0x70ce, 0x316d, 0x7e93, 0x5984, 0x608b, 0x7332, 0x6ad6, + 0x302d, 0x348c, 0x6a71, 0x4b6a, 0x6cc4, 0x6107, 0x40d1, 0x47a0, + 0x7df2, 0x2e99, 0x2e98, 0x7c10, 0x6a6b, 0x65c1, 0x6568, 0x4900, + 0x4e7e, 0x5897, 0x6155, 0x8e9f, 0x3b41, 0x3b56, 0x3b7d, 0x3b93, + 0x3bd8, 0x3bec, 0x3c12, 0x3c1e, 0x3c23, 0x3c2b, 0x178d, 0x3c62, + 0x813b, 0x813c, 0x96b4, 0x3c7a, 0x3c8f, 0x3c9f, 0x3ca3, 0x3caa, + 0x3cba, 0x3ccb, 0x3cd0, 0x3cd2, 0x3cf4, 0x9c34, 0x17e2, 0x3d0d, + 0x3d27, 0x8111, 0x3d46, 0x3d47, 0x3d53, 0x3d4a, 0x3d6d, 0x3d81, + 0x3da0, 0x3da4, 0x3da7, 0x3db8, 0x3dcb, 0x341e, + /* 0x15021..0x1507E */ + 0x3f0c, 0x2e10, 0x2e15, 0x2e2a, 0x2e31, 0x2e36, 0x2e3c, 0x2e3f, + 0x2e42, 0x2e56, 0x2e58, 0x2e82, 0x2e85, 0x6c6b, 0x2e8a, 0x6212, + 0x3f0d, 0x2e8e, 0x2e9e, 0x2e9f, 0x2ea0, 0x2ea2, 0x2eb0, 0x2eb3, + 0x2eb6, 0x2ece, 0x2ecd, 0x2ec4, 0x2ec6, 0x2ec2, 0x2ed7, 0x2ede, + 0x2eed, 0x2edf, 0x2ef7, 0x2f09, 0x2f5a, 0x2f30, 0x2f5b, 0x2f5d, + 0x2f57, 0x2f47, 0x2f76, 0x2f88, 0x2f8f, 0x2f98, 0x2f7b, 0x2f69, + 0x2f70, 0x2f91, 0x2f6f, 0x2f86, 0x2f96, 0x3118, 0x2fd4, 0x2fdf, + 0x2fce, 0x2fd8, 0x2fdb, 0x2fd1, 0x2fda, 0x2fd0, 0x2fe4, 0x2fe5, + 0x301a, 0x3028, 0x3014, 0x302a, 0x3025, 0x3005, 0x2f1c, 0x2ff6, + 0x3021, 0x3029, 0x302c, 0x2ffe, 0x2fef, 0x3011, 0x3006, 0x3043, + 0x3047, 0x4703, 0x3055, 0x3050, 0x3048, 0x305a, 0x3056, 0x306c, + 0x3078, 0x3080, 0x309a, 0x3085, 0x30b4, 0x30b2, + /* 0x15121..0x1517E */ + 0x30c9, 0x30ca, 0x30b3, 0x30c2, 0x30d6, 0x30de, 0x30e5, 0x30ed, + 0x30e3, 0x30ee, 0x30f9, 0x30f5, 0x3109, 0x3101, 0x3102, 0x3116, + 0x3115, 0x3114, 0x311a, 0x3121, 0x313a, 0x3137, 0x313c, 0x313b, + 0x313f, 0x3140, 0x3152, 0x314c, 0x3154, 0x3162, 0x5af8, 0x3169, + 0x316a, 0x316e, 0x3180, 0x3182, 0x36d8, 0x318c, 0x3189, 0x318f, + 0x3191, 0x3193, 0x3195, 0x3196, 0x31a4, 0x31a6, 0x31a2, 0x31a9, + 0x31aa, 0x31ab, 0x31b3, 0x31b1, 0x31b2, 0x31b0, 0x31b5, 0x31bd, + 0x31c5, 0x31c9, 0x31db, 0x31e0, 0x6655, 0x31e9, 0x31ed, 0x31f0, + 0x31f5, 0x31fe, 0x3204, 0x320b, 0x3214, 0x320e, 0x3227, 0x322a, + 0x322e, 0x3233, 0x3239, 0x324f, 0x3244, 0x324b, 0x324c, 0x325e, + 0x3254, 0x326a, 0x3274, 0x3269, 0x3273, 0x327f, 0x327d, 0x328d, + 0x3294, 0x3292, 0x3271, 0x3288, 0x3291, 0x6fa8, + /* 0x15221..0x1527E */ + 0x6fa7, 0x32ac, 0x32ad, 0x32bc, 0x32b5, 0x32c1, 0x32cd, 0x32d7, + 0x32de, 0x32e3, 0x32e6, 0x78ed, 0x32e0, 0x32f3, 0x32f5, 0x32f8, + 0x32f9, 0x3306, 0x3308, 0x5538, 0x330d, 0x3310, 0x330f, 0x3315, + 0x331a, 0x3323, 0x332f, 0x3331, 0x3333, 0x3338, 0x3340, 0x3346, + 0x3345, 0x2e17, 0x3349, 0x334d, 0x31d6, 0x335e, 0x3369, 0x336e, + 0x3918, 0x337b, 0x3377, 0x3382, 0x3396, 0x33a0, 0x33a6, 0x33a5, + 0x33ae, 0x33b0, 0x33b6, 0x33c3, 0x5c12, 0x76d9, 0x33df, 0x46fc, + 0x51ee, 0x33ee, 0x33e8, 0x33ed, 0x33fa, 0x3401, 0x343d, 0x3440, + 0x342c, 0x342d, 0x343c, 0x342e, 0x3436, 0x3429, 0x341d, 0x344e, + 0x348f, 0x3475, 0x348e, 0x345f, 0x3471, 0x3477, 0x3470, 0x3492, + 0x347b, 0x3480, 0x3476, 0x3484, 0x3490, 0x3486, 0x34c7, 0x34a2, + 0x34b8, 0x34a5, 0x34ac, 0x34c4, 0x34c8, 0x34a8, + /* 0x15321..0x1537E */ + 0x34ab, 0x34c2, 0x34a4, 0x34be, 0x34bc, 0x34d8, 0x34e5, 0x34e6, + 0x350f, 0x3514, 0x34fd, 0x34ee, 0x34ed, 0x34fa, 0x34e2, 0x3539, + 0x3540, 0x3563, 0x354c, 0x352e, 0x355c, 0x3545, 0x3556, 0x3557, + 0x3538, 0x3533, 0x355d, 0x3599, 0x3580, 0x34af, 0x358a, 0x359f, + 0x357b, 0x357e, 0x3598, 0x359e, 0x35ae, 0x357c, 0x3583, 0x35a9, + 0x3587, 0x35a8, 0x35da, 0x35c5, 0x35df, 0x35c4, 0x35dc, 0x35e4, + 0x35d4, 0x3614, 0x35f7, 0x3616, 0x35fe, 0x35fd, 0x361b, 0x35f9, + 0x364e, 0x3650, 0x51df, 0x3634, 0x3636, 0x3632, 0x3638, 0x366b, + 0x3664, 0x362f, 0x366c, 0x366a, 0x3686, 0x3680, 0x368a, 0x36a0, + 0x3694, 0x368f, 0x36a5, 0x36ae, 0x36b6, 0x36b4, 0x36c2, 0x36bc, + 0x36c1, 0x36c3, 0x36c0, 0x36c8, 0x36ce, 0x36d1, 0x36d3, 0x36d7, + 0x36ee, 0x36f9, 0x3700, 0x36ff, 0x3704, 0x3709, + /* 0x15421..0x1547E */ + 0x3708, 0x370b, 0x370d, 0x3713, 0x3718, 0x3716, 0x35c7, 0x371c, + 0x3726, 0x3737, 0x3738, 0x374e, 0x373b, 0x3740, 0x374f, 0x3769, + 0x37c0, 0x3788, 0x3761, 0x377f, 0x3789, 0x3793, 0x37a0, 0x37b3, + 0x37a4, 0x37aa, 0x37b0, 0x37c3, 0x37c6, 0x37d4, 0x37d2, 0x37d3, + 0x380a, 0x37d6, 0x37e3, 0x380b, 0x3819, 0x381d, 0x3872, 0x3821, + 0x3862, 0x384b, 0x3870, 0x4bc0, 0x3852, 0x383d, 0x3879, 0x3885, + 0x38b9, 0x389f, 0x38ab, 0x38ba, 0x38de, 0x38bb, 0x38b8, 0x38ae, + 0x38c5, 0x38d3, 0x38d1, 0x38d7, 0x38d9, 0x38d8, 0x38e5, 0x38dc, + 0x38e4, 0x38df, 0x38ef, 0x38fa, 0x38f9, 0x38fb, 0x38fc, 0x38fd, + 0x3902, 0x390a, 0x3910, 0x391b, 0x48a6, 0x3925, 0x392c, 0x392d, + 0x3932, 0x3938, 0x393e, 0x5ad2, 0x3955, 0x3950, 0x394e, 0x395a, + 0x3958, 0x3962, 0x3960, 0x3967, 0x396c, 0x3969, + /* 0x15521..0x1557E */ + 0x3978, 0x3981, 0x399d, 0x2f5e, 0x2fab, 0x39a3, 0x39b2, 0x39c6, + 0x39e8, 0x39dc, 0x398d, 0x39d9, 0x39da, 0x3a25, 0x3a1f, 0x3a11, + 0x3a1c, 0x3a09, 0x3a1a, 0x3a40, 0x3a6c, 0x3a49, 0x3a35, 0x3a36, + 0x3a62, 0x3a6a, 0x3a9a, 0x3abc, 0x3abe, 0x3acb, 0x3ac2, 0x3abd, + 0x3ae3, 0x3ad7, 0x3ae6, 0x3ae9, 0x3ad6, 0x3afa, 0x3afb, 0x3b0c, + 0x3b0b, 0x3b16, 0x3b32, 0x3ad0, 0x3b2a, 0x3b36, 0x3b3e, 0x3b43, + 0x3b45, 0x3b40, 0x3b51, 0x3b55, 0x3b5a, 0x3b5b, 0x3b65, 0x3b69, + 0x3b70, 0x3b73, 0x3b75, 0x3b78, 0x4588, 0x3b7a, 0x3b80, 0x3b83, + 0x3ba6, 0x3bb8, 0x3bc3, 0x3bc7, 0x3bc9, 0x3bd4, 0x3bd0, 0x3be4, + 0x3be6, 0x3be2, 0x3bde, 0x3be5, 0x3beb, 0x3bf0, 0x3bf6, 0x3bf3, + 0x3c05, 0x3c07, 0x3c08, 0x3c0d, 0x3c13, 0x3c20, 0x3c22, 0x3c28, + 0x3c38, 0x3c39, 0x3c41, 0x3c46, 0x3c4e, 0x3c53, + /* 0x15621..0x1567E */ + 0x3c50, 0x3c4f, 0x3b71, 0x3c6c, 0x3c6e, 0x2e62, 0x3c76, 0x3c79, + 0x3c8c, 0x3c91, 0x3c94, 0x399b, 0x3cab, 0x3cbb, 0x3cb6, 0x3cbc, + 0x3cb7, 0x3cc5, 0x3cbe, 0x3cc7, 0x3cd9, 0x3ce9, 0x3cfd, 0x3cfa, + 0x3ced, 0x3d8c, 0x3cea, 0x3d0b, 0x3d15, 0x3d17, 0x3d5c, 0x3d1f, + 0x3d1b, 0x3d11, 0x3d14, 0x3d22, 0x3d1a, 0x3d19, 0x3d18, 0x3d4c, + 0x3d52, 0x3d4e, 0x3d4b, 0x3d6c, 0x3d73, 0x3d76, 0x3d87, 0x3d84, + 0x3d82, 0x3da2, 0x3d9d, 0x3dac, 0x3dae, 0x3dbd, 0x3d90, 0x3db7, + 0x3dbc, 0x3dc9, 0x3dcd, 0x3dd3, 0x3dd2, 0x3dd6, 0x3ddb, 0x3deb, + 0x3df2, 0x3df5, 0x3e0b, 0x3e1a, 0x3e19, 0x3e11, 0x3e1b, 0x3e36, + 0x3e37, 0x3e44, 0x3e43, 0x3e40, 0x3e4e, 0x3e57, 0x3e54, 0x3e5f, + 0x3e62, 0x3e64, 0x3e47, 0x3e75, 0x3e76, 0x3e7a, 0x7ebc, 0x3e7f, + 0x3ea0, 0x3ec1, 0x3ec2, 0x3ec8, 0x3ed0, 0x3ecf, + /* 0x15721..0x1577E */ + 0x3ed6, 0x3ee3, 0x3edd, 0x3eda, 0x3edb, 0x3ee2, 0x3ee1, 0x3ee8, + 0x3ee9, 0x3eec, 0x3ef1, 0x3ef3, 0x3ef0, 0x3ef4, 0x3ef8, 0x3efe, + 0x3f03, 0x3f09, 0x3f5d, 0x3f5c, 0x3f0b, 0x3f11, 0x3f16, 0x3f29, + 0x3f2d, 0x3f38, 0x3f41, 0x3f48, 0x3f4c, 0x3f4e, 0x3f2f, 0x3f51, + 0x3f56, 0x3f57, 0x3f59, 0x3f61, 0x3f6d, 0x3f73, 0x3f77, 0x3f83, + 0x3f82, 0x3f7f, 0x3f8a, 0x3f88, 0x3f91, 0x3f87, 0x3f9e, 0x3f99, + 0x3f98, 0x3fa0, 0x3fa8, 0x3fad, 0x3fbc, 0x3fd6, 0x3ffb, 0x3fe4, + 0x3ff8, 0x3ff1, 0x3fdd, 0x40b3, 0x3fff, 0x4021, 0x4060, 0x4019, + 0x4010, 0x4029, 0x400e, 0x4031, 0x401b, 0x4015, 0x402b, 0x4026, + 0x400f, 0x403a, 0x405a, 0x4041, 0x406a, 0x4077, 0x405f, 0x404a, + 0x4046, 0x404d, 0x4063, 0x4043, 0x4064, 0x4042, 0x406c, 0x406b, + 0x4059, 0x4081, 0x408d, 0x40e7, 0x4083, 0x409a, + /* 0x15821..0x1587E */ + 0x4084, 0x409b, 0x4096, 0x4097, 0x4092, 0x40a7, 0x408b, 0x40e1, + 0x40b8, 0x40e0, 0x40d3, 0x40b4, 0x3ff0, 0x40bd, 0x40c6, 0x40b5, + 0x40d8, 0x414d, 0x4115, 0x4106, 0x40f6, 0x40f7, 0x4100, 0x40f4, + 0x40fa, 0x4103, 0x4121, 0x40fb, 0x40f1, 0x410d, 0x410e, 0x4147, + 0x413e, 0x4128, 0x4127, 0x414a, 0x413f, 0x413c, 0x412c, 0x4134, + 0x413d, 0x4142, 0x4144, 0x4173, 0x4177, 0x4158, 0x4159, 0x415a, + 0x416b, 0x4174, 0x416f, 0x4165, 0x4171, 0x415f, 0x415d, 0x4153, + 0x4175, 0x4199, 0x4196, 0x4187, 0x41ac, 0x4194, 0x419a, 0x418a, + 0x4191, 0x41ab, 0x41ae, 0x41cc, 0x41ca, 0x41c9, 0x41f7, 0x41c8, + 0x41c3, 0x41c6, 0x41ba, 0x41cb, 0x5f79, 0x41cd, 0x41e6, 0x41e3, + 0x41f6, 0x41fa, 0x41f4, 0x41ff, 0x41fd, 0x41fc, 0x41fe, 0x4200, + 0x4208, 0x4209, 0x420d, 0x420c, 0x4214, 0x421b, + /* 0x15921..0x1597E */ + 0x421e, 0x4221, 0x422a, 0x422e, 0x4230, 0x4232, 0x4233, 0x4241, + 0x424e, 0x425e, 0x4263, 0x425b, 0x4260, 0x4268, 0x427c, 0x4282, + 0x4289, 0x427e, 0x4292, 0x4293, 0x4296, 0x42d4, 0x4283, 0x4294, + 0x42d7, 0x42d1, 0x42bb, 0x42cf, 0x42ff, 0x42c6, 0x44d4, 0x42c8, + 0x42dc, 0x42cc, 0x42ca, 0x42c2, 0x42c7, 0x429b, 0x42c9, 0x430c, + 0x42ee, 0x42f1, 0x4327, 0x4302, 0x4308, 0x42ef, 0x42f5, 0x4350, + 0x433e, 0x434d, 0x441c, 0x434f, 0x4396, 0x438e, 0x4380, 0x43ab, + 0x4376, 0x43a3, 0x438f, 0x4389, 0x439f, 0x43b5, 0x436b, 0x4369, + 0x43be, 0x43e9, 0x43c0, 0x43c6, 0x43e3, 0x43c9, 0x43d2, 0x43f6, + 0x43c4, 0x4416, 0x4434, 0x4406, 0x4413, 0x4426, 0x4436, 0x451d, + 0x4417, 0x4428, 0x440f, 0x4467, 0x446f, 0x4476, 0x444e, 0x452a, + 0x4495, 0x4493, 0x44a5, 0x44a9, 0x4488, 0x44bc, + /* 0x15A21..0x15A7E */ + 0x44da, 0x44d2, 0x44c5, 0x44c7, 0x44bb, 0x44d8, 0x44c2, 0x44f1, + 0x44e7, 0x6209, 0x44e0, 0x44e1, 0x42ac, 0x44e3, 0x44ef, 0x452c, + 0x44f6, 0x44f4, 0x44f2, 0x44fa, 0x4500, 0x44fd, 0x4518, 0x451c, + 0x4505, 0x4524, 0x4523, 0x452b, 0x4534, 0x4535, 0x4537, 0x4536, + 0x4538, 0x554b, 0x4548, 0x4556, 0x4555, 0x454d, 0x4558, 0x455e, + 0x455d, 0x4572, 0x4578, 0x4582, 0x4583, 0x6b8a, 0x459b, 0x459f, + 0x45ab, 0x45b7, 0x45c3, 0x45c6, 0x45c1, 0x45c4, 0x45cc, 0x45d2, + 0x45db, 0x45d9, 0x45e0, 0x45e1, 0x45f1, 0x4772, 0x460a, 0x4603, + 0x45fb, 0x4773, 0x4635, 0x4636, 0x4634, 0x461c, 0x464f, 0x4644, + 0x4649, 0x4641, 0x465e, 0x465d, 0x4664, 0x4667, 0x4668, 0x465f, + 0x4662, 0x4670, 0x4683, 0x4688, 0x468e, 0x4689, 0x4684, 0x4698, + 0x469d, 0x46c1, 0x46b9, 0x46c9, 0x46be, 0x46bc, + /* 0x15B21..0x15B7E */ + 0x46c4, 0x46b8, 0x46d6, 0x46da, 0x46e0, 0x463f, 0x46e6, 0x46e9, + 0x46f0, 0x46f5, 0x46f7, 0x470f, 0x4716, 0x471e, 0x4726, 0x4727, + 0x7738, 0x472e, 0x473f, 0x4736, 0x4741, 0x4738, 0x4737, 0x4746, + 0x475e, 0x4760, 0x4759, 0x4763, 0x4764, 0x4789, 0x4770, 0x47a9, + 0x477c, 0x476a, 0x478c, 0x478b, 0x47a6, 0x47a1, 0x4785, 0x47b7, + 0x47ef, 0x47b4, 0x47ec, 0x47b3, 0x47e9, 0x47b8, 0x47e4, 0x47de, + 0x47dd, 0x47e2, 0x47ee, 0x47b9, 0x47ce, 0x47c6, 0x47e7, 0x4a9c, + 0x481e, 0x4846, 0x4829, 0x4840, 0x484d, 0x4832, 0x484e, 0x48b3, + 0x482b, 0x4859, 0x4863, 0x4877, 0x487f, 0x489f, 0x488f, 0x48ad, + 0x4894, 0x489d, 0x489b, 0x4883, 0x4aae, 0x48b9, 0x4874, 0x48b5, + 0x48a0, 0x48ba, 0x490f, 0x488d, 0x487e, 0x4901, 0x48ca, 0x4908, + 0x48d8, 0x4922, 0x4926, 0x48e1, 0x490c, 0x48cd, + /* 0x15C21..0x15C7E */ + 0x48d4, 0x48e7, 0x48d5, 0x4936, 0x4912, 0x4904, 0x48d7, 0x48e3, + 0x4925, 0x48f9, 0x48e0, 0x48ef, 0x4928, 0x492a, 0x491a, 0x4923, + 0x4921, 0x48c6, 0x4979, 0x4977, 0x495c, 0x4978, 0x496b, 0x4954, + 0x497e, 0x496e, 0x4939, 0x4974, 0x493d, 0x4959, 0x4930, 0x4961, + 0x495e, 0x495d, 0x4981, 0x496a, 0x49b2, 0x49ae, 0x49d0, 0x49bf, + 0x49c1, 0x49d3, 0x49be, 0x49ce, 0x3be8, 0x49ca, 0x49dd, 0x49bb, + 0x49c3, 0x49a7, 0x4a2e, 0x4991, 0x49a0, 0x499c, 0x4995, 0x49b4, + 0x49de, 0x49e8, 0x4a02, 0x4a1b, 0x49ff, 0x4b0a, 0x49f9, 0x49f2, + 0x49e7, 0x4a05, 0x49b1, 0x4a1e, 0x49ed, 0x4a14, 0x49eb, 0x4a0a, + 0x4a12, 0x4ac1, 0x4a23, 0x4a13, 0x4a44, 0x4a0c, 0x4a72, 0x4a36, + 0x4a78, 0x4a47, 0x4a62, 0x4a59, 0x4a66, 0x4a48, 0x4a38, 0x4a22, + 0x4a90, 0x4a8d, 0x4aa0, 0x4a84, 0x4aa2, 0x4aa3, + /* 0x15D21..0x15D7E */ + 0x4a97, 0x6617, 0x4abb, 0x4ac3, 0x4ac2, 0x4ab8, 0x4ab3, 0x4aac, + 0x4ade, 0x4ad1, 0x4adf, 0x4aaa, 0x4ada, 0x4aea, 0x4afb, 0x4b05, + 0x6616, 0x4afa, 0x4b12, 0x4b16, 0x7b31, 0x4b1f, 0x4b38, 0x4b37, + 0x56dc, 0x4b39, 0x78ee, 0x4b47, 0x4b43, 0x4b49, 0x4b50, 0x4b59, + 0x4b54, 0x4b5b, 0x4b5f, 0x4b61, 0x4b78, 0x4b79, 0x4b7f, 0x4b80, + 0x4b84, 0x4b83, 0x4b8d, 0x4b98, 0x4b95, 0x4b9e, 0x4ba4, 0x4baa, + 0x4bab, 0x4baf, 0x4bb2, 0x4bb1, 0x4bb3, 0x4bb7, 0x4bbc, 0x4bc6, + 0x4bcb, 0x4bd3, 0x4bdf, 0x4bec, 0x4beb, 0x4bf3, 0x4bef, 0x7ebe, + 0x4c08, 0x4c13, 0x4c14, 0x4c1b, 0x4c24, 0x4c23, 0x4c5e, 0x4c55, + 0x4c62, 0x4c6a, 0x4c82, 0x4c8d, 0x4c9a, 0x4c81, 0x4c9b, 0x4c7e, + 0x4c68, 0x4c73, 0x4c92, 0x4c90, 0x4cc4, 0x4cf1, 0x4cd3, 0x4cbd, + 0x4cd7, 0x4cc5, 0x4cdd, 0x4cae, 0x4cb1, 0x4cbe, + /* 0x15E21..0x15E7E */ + 0x4cba, 0x4cdb, 0x4cef, 0x4cd9, 0x4cea, 0x4d1f, 0x684d, 0x4d36, + 0x4d2b, 0x4d3d, 0x4d38, 0x4d19, 0x4d35, 0x4d33, 0x4d12, 0x4d0c, + 0x4d63, 0x4d93, 0x4d64, 0x4d5a, 0x4d79, 0x4d59, 0x4d8e, 0x4d95, + 0x4fe4, 0x4d85, 0x4df9, 0x4e15, 0x4e0a, 0x4db5, 0x4dc7, 0x4de6, + 0x4db8, 0x4dc6, 0x4dec, 0x4dde, 0x4dcc, 0x4de8, 0x4dd2, 0x4dc5, + 0x4dfa, 0x4dd9, 0x4de4, 0x4dd5, 0x4dea, 0x4dee, 0x4e2d, 0x4e6e, + 0x4e2e, 0x4e19, 0x4e72, 0x4e5f, 0x4e3e, 0x4e23, 0x4e6b, 0x4e2b, + 0x4e76, 0x4e4d, 0x4e1f, 0x4e43, 0x4e3a, 0x4e4e, 0x4e24, 0x4eff, + 0x4e1d, 0x4e38, 0x4e82, 0x4eaa, 0x4e98, 0x4ec9, 0x4eb7, 0x4ed3, + 0x4ebd, 0x4eaf, 0x4ec4, 0x4eb2, 0x4ed4, 0x4ed5, 0x4e8f, 0x4ea5, + 0x4ec2, 0x4e9f, 0x4f41, 0x4f11, 0x504c, 0x4eec, 0x4ef8, 0x4efe, + 0x4f3f, 0x4ef2, 0x4f31, 0x4eef, 0x4f32, 0x4ecc, + /* 0x15F21..0x15F7E */ + 0x4f3e, 0x4f13, 0x4ef7, 0x4f86, 0x4f7a, 0x4f78, 0x4f81, 0x4f80, + 0x4f6f, 0x4f5b, 0x4ff3, 0x4f6d, 0x4f82, 0x4f7c, 0x4f58, 0x4f8e, + 0x4f91, 0x4fc2, 0x4f66, 0x4fb3, 0x4fa3, 0x4fa1, 0x4fa4, 0x4fb9, + 0x4fc6, 0x4faa, 0x4fdf, 0x4fd5, 0x4fec, 0x4fd4, 0x4fd8, 0x4ff1, + 0x4fee, 0x4fdb, 0x5009, 0x500b, 0x4ffa, 0x5011, 0x5001, 0x500f, + 0x4ffe, 0x501b, 0x501a, 0x4f74, 0x501d, 0x5018, 0x501f, 0x5030, + 0x503e, 0x5032, 0x5051, 0x5063, 0x5099, 0x5092, 0x50af, 0x50f1, + 0x50ac, 0x50b8, 0x50b3, 0x50ae, 0x50df, 0x50cb, 0x50dd, 0x50d9, + 0x5109, 0x50fd, 0x511c, 0x5119, 0x5165, 0x5155, 0x5188, 0x5166, + 0x5162, 0x514c, 0x5156, 0x516c, 0x518f, 0x51fb, 0x5184, 0x5195, + 0x51a8, 0x51ac, 0x51d7, 0x51b9, 0x51be, 0x51d2, 0x51c9, 0x51d4, + 0x51ce, 0x51e0, 0x51ec, 0x51e7, 0x51f5, 0x51fc, + /* 0x16021..0x1607E */ + 0x51f9, 0x51ff, 0x520d, 0x5210, 0x521b, 0x5228, 0x522d, 0x522c, + 0x5230, 0x5232, 0x523b, 0x523c, 0x523f, 0x5240, 0x5246, 0x524b, + 0x5258, 0x5274, 0x527e, 0x5282, 0x5281, 0x5287, 0x5292, 0x5296, + 0x52a2, 0x52a7, 0x52b9, 0x52b2, 0x52c3, 0x52c6, 0x52c4, 0x52ce, + 0x52d2, 0x52e2, 0x52e0, 0x52e1, 0x52f9, 0x52f7, 0x300f, 0x5317, + 0x530a, 0x531c, 0x5316, 0x531d, 0x5334, 0x532f, 0x5329, 0x5325, + 0x533e, 0x534e, 0x534f, 0x7ed8, 0x5357, 0x536a, 0x5368, 0x5370, + 0x5378, 0x5375, 0x537b, 0x537a, 0x53c8, 0x53b3, 0x53ce, 0x53bb, + 0x53c0, 0x53e5, 0x53ee, 0x53de, 0x54a2, 0x5405, 0x546f, 0x5425, + 0x53f8, 0x5432, 0x543a, 0x5455, 0x543f, 0x545f, 0x5459, 0x5441, + 0x545c, 0x5469, 0x5470, 0x5463, 0x546a, 0x5476, 0x547e, 0x548b, + 0x549e, 0x54a7, 0x54ca, 0x54cf, 0x54d4, 0x53f1, + /* 0x16121..0x1617E */ + 0x54e0, 0x54e3, 0x54e7, 0x54e9, 0x54ee, 0x54f2, 0x54f0, 0x54f1, + 0x54f8, 0x54f7, 0x5504, 0x5503, 0x5505, 0x550c, 0x550e, 0x550d, + 0x5515, 0x5513, 0x551e, 0x5526, 0x552c, 0x553c, 0x5544, 0x554d, + 0x554a, 0x5549, 0x555b, 0x5546, 0x555a, 0x5569, 0x5564, 0x5567, + 0x556b, 0x556d, 0x5578, 0x5576, 0x5586, 0x5587, 0x5574, 0x558a, + 0x5589, 0x5582, 0x5594, 0x559a, 0x559d, 0x55a5, 0x55a3, 0x55c2, + 0x55b3, 0x55c3, 0x55b5, 0x55bd, 0x55b8, 0x55bc, 0x55b1, 0x55cd, + 0x55ca, 0x55d2, 0x55d9, 0x55e3, 0x55de, 0x55fe, 0x55ff, 0x55fc, + 0x5601, 0x55f0, 0x55fa, 0x55f2, 0x55f3, 0x560b, 0x560d, 0x5609, + 0x561f, 0x5627, 0x5620, 0x5621, 0x5622, 0x5624, 0x5634, 0x5630, + 0x563b, 0x5647, 0x5648, 0x5646, 0x565c, 0x5658, 0x5661, 0x5662, + 0x5668, 0x5669, 0x566a, 0x5667, 0x566c, 0x5670, + /* 0x16221..0x1627E */ + 0x5672, 0x5676, 0x5678, 0x567c, 0x5680, 0x5683, 0x5688, 0x568b, + 0x568e, 0x5696, 0x5693, 0x5699, 0x569a, 0x56b0, 0x56b4, 0x56b8, + 0x56b9, 0x56ba, 0x56c2, 0x56cd, 0x56d6, 0x56d2, 0x56de, 0x56e1, + 0x56e5, 0x56e7, 0x56ea, 0x662f, 0x56fb, 0x5708, 0x5707, 0x5704, + 0x5729, 0x5724, 0x571e, 0x5725, 0x5726, 0x571b, 0x5737, 0x5738, + 0x5747, 0x575a, 0x5768, 0x576b, 0x575b, 0x5765, 0x577f, 0x577e, + 0x5779, 0x578e, 0x578b, 0x5791, 0x57a0, 0x579e, 0x57b0, 0x57b6, + 0x57b9, 0x57bf, 0x57bc, 0x57bd, 0x57bb, 0x57c7, 0x57cd, 0x57d7, + 0x57da, 0x57dc, 0x57e3, 0x57ee, 0x57fc, 0x580c, 0x5812, 0x5926, + 0x5820, 0x592a, 0x5845, 0x588e, 0x5874, 0x5886, 0x587c, 0x589a, + 0x588c, 0x58a3, 0x58b5, 0x58aa, 0x58af, 0x58d1, 0x58c6, 0x58cb, + 0x58d4, 0x58be, 0x58bc, 0x58c5, 0x58ca, 0x58ec, + /* 0x16321..0x1637E */ + 0x58e7, 0x58da, 0x58fd, 0x58f4, 0x5907, 0x5912, 0x5911, 0x5919, + 0x592c, 0x592b, 0x5940, 0x5960, 0x5957, 0x595f, 0x595a, 0x5955, + 0x5953, 0x597a, 0x597f, 0x598a, 0x599d, 0x59a7, 0x7f4b, 0x59aa, + 0x59ae, 0x59b3, 0x59b9, 0x59ba, 0x59c9, 0x59d5, 0x59e7, 0x59ec, + 0x59e1, 0x59e3, 0x5a08, 0x5a0d, 0x5a18, 0x5a19, 0x5a20, 0x5a1f, + 0x5980, 0x5a31, 0x5a3b, 0x5a3e, 0x5a37, 0x5a43, 0x5a57, 0x5a49, + 0x5a61, 0x5a62, 0x5a69, 0x7f9d, 0x5a70, 0x5a79, 0x5a7d, 0x5a88, + 0x5a97, 0x5a95, 0x5a98, 0x5a96, 0x5aa9, 0x5ac8, 0x5ab0, 0x5ab6, + 0x5ac5, 0x5ac4, 0x5abf, 0x7083, 0x5ac7, 0x5aca, 0x5acd, 0x5acf, + 0x5ad5, 0x5ad3, 0x5ad9, 0x5ada, 0x5add, 0x5ae1, 0x5ae2, 0x5ae6, + 0x5aed, 0x5af0, 0x5b02, 0x5b0f, 0x5b0a, 0x5b06, 0x5b33, 0x5b18, + 0x5b19, 0x5b1e, 0x5b35, 0x5b28, 0x5b36, 0x5b50, + /* 0x16421..0x1647E */ + 0x5b7a, 0x5b04, 0x5b4d, 0x5b0b, 0x5b4c, 0x5b45, 0x5b75, 0x5b65, + 0x5b74, 0x5b67, 0x5b70, 0x5b71, 0x5b6c, 0x5b6e, 0x5b9d, 0x5b98, + 0x5b9f, 0x5b8d, 0x5b9c, 0x5b9a, 0x5b8b, 0x5b92, 0x5b8f, 0x5b5d, + 0x5b99, 0x5bcb, 0x5bc1, 0x5bcc, 0x5bcf, 0x5bb4, 0x5bc6, 0x5bdd, + 0x5be9, 0x5c11, 0x5c14, 0x5be6, 0x5be5, 0x5c60, 0x5c00, 0x5c07, + 0x5c13, 0x5bf3, 0x5bf7, 0x5c17, 0x5c0d, 0x5bf6, 0x5c23, 0x5c27, + 0x5c2a, 0x5c1f, 0x5c37, 0x5c2b, 0x5c3d, 0x5c4c, 0x5c43, 0x5c54, + 0x5c4f, 0x5c40, 0x5c50, 0x5c58, 0x5c5f, 0x5c64, 0x5c56, 0x5c65, + 0x5c6c, 0x5c75, 0x5c83, 0x5c90, 0x5ca4, 0x5cad, 0x5ca2, 0x5cab, + 0x5ca1, 0x5ca8, 0x5cb3, 0x5cb2, 0x5cb1, 0x5cae, 0x5cb9, 0x5cbd, + 0x5cc0, 0x5cc5, 0x5cc2, 0x5cd8, 0x5cd2, 0x5cdc, 0x5ce2, 0x7b3b, + 0x5cef, 0x5cf2, 0x5cf4, 0x5cf6, 0x5cfa, 0x5d06, + /* 0x16521..0x1657E */ + 0x5d02, 0x5d1c, 0x5d15, 0x5d0a, 0x5d45, 0x5d4b, 0x5d2e, 0x5d32, + 0x5d3f, 0x5d35, 0x5d46, 0x5d73, 0x5d56, 0x5d4e, 0x5d72, 0x5d68, + 0x5d6e, 0x5d4f, 0x5d63, 0x5d93, 0x5d89, 0x5d5b, 0x5d8f, 0x5d7d, + 0x5d9b, 0x5dba, 0x5dae, 0x5da3, 0x5db5, 0x5dc7, 0x5dbd, 0x5dab, + 0x5e3d, 0x5da2, 0x5daf, 0x5ddc, 0x5db8, 0x5d9f, 0x5db0, 0x5dd8, + 0x5ddd, 0x5de4, 0x5dde, 0x5dfb, 0x5df2, 0x5de1, 0x5e05, 0x5e0a, + 0x5e23, 0x5e21, 0x5e12, 0x5e31, 0x5e1f, 0x5e09, 0x5e0b, 0x5e22, + 0x5e46, 0x5e66, 0x5e3b, 0x5e35, 0x5e39, 0x5e43, 0x5e37, 0x5e32, + 0x5e3a, 0x5e67, 0x5e5d, 0x5e56, 0x5e5e, 0x5e59, 0x5e5a, 0x5e79, + 0x5e6a, 0x5e69, 0x5e7c, 0x5e7b, 0x5e83, 0x5dd5, 0x5e7d, 0x6fae, + 0x5e7f, 0x5e88, 0x5e89, 0x5e8c, 0x5e92, 0x5e90, 0x5e93, 0x5e94, + 0x5e96, 0x5e8e, 0x5e9b, 0x5e9c, 0x5f38, 0x5f3a, + /* 0x16621..0x1667E */ + 0x5f45, 0x5f4c, 0x5f4d, 0x5f4e, 0x5f50, 0x5f51, 0x5f55, 0x5f54, + 0x5f58, 0x5f5f, 0x5f60, 0x5f68, 0x5f69, 0x5f67, 0x5f78, 0x5f82, + 0x5f86, 0x5f83, 0x5f88, 0x5f87, 0x5f8c, 0x5f94, 0x5f9e, 0x5f9d, + 0x5f9a, 0x5fa3, 0x5faf, 0x5fb2, 0x5fb9, 0x5fae, 0x5fb6, 0x5fb8, + 0x6b71, 0x5fc5, 0x5fc6, 0x5fca, 0x5fd5, 0x5fd4, 0x5fe1, 0x5fe6, + 0x5fe9, 0x5ff3, 0x5ff9, 0x78dc, 0x6006, 0x6004, 0x600b, 0x6012, + 0x6018, 0x6019, 0x601c, 0x6021, 0x6028, 0x603f, 0x603b, 0x604a, + 0x6046, 0x6052, 0x6058, 0x605a, 0x605f, 0x6062, 0x6068, 0x6073, + 0x6072, 0x6070, 0x6076, 0x6079, 0x607d, 0x607f, 0x6084, 0x6086, + 0x6085, 0x609b, 0x6093, 0x609a, 0x60ad, 0x3190, 0x60ac, 0x60db, + 0x60e5, 0x60d9, 0x60dd, 0x60c4, 0x60da, 0x60d6, 0x6109, 0x60ef, + 0x60f1, 0x611b, 0x6129, 0x6123, 0x612f, 0x614b, + /* 0x16721..0x1677E */ + 0x768b, 0x6146, 0x613e, 0x6153, 0x6151, 0x60fc, 0x6171, 0x616e, + 0x6165, 0x6166, 0x6174, 0x6183, 0x6188, 0x618a, 0x6180, 0x6182, + 0x61a0, 0x6195, 0x61a4, 0x61a3, 0x615f, 0x6193, 0x61a9, 0x61b0, + 0x61b5, 0x61be, 0x61b8, 0x61bd, 0x61c0, 0x61c2, 0x61ba, 0x61c9, + 0x61cd, 0x61d1, 0x61d9, 0x61d8, 0x61c8, 0x61da, 0x61df, 0x61e0, + 0x61e7, 0x61fa, 0x61fb, 0x61fe, 0x6201, 0x6202, 0x6205, 0x6207, + 0x620a, 0x620d, 0x6210, 0x6216, 0x6229, 0x622b, 0x6238, 0x6233, + 0x6240, 0x6259, 0x6258, 0x625d, 0x625a, 0x625f, 0x6264, 0x6262, + 0x6268, 0x626a, 0x626b, 0x622e, 0x6271, 0x6277, 0x6278, 0x627e, + 0x628d, 0x6292, 0x62ab, 0x629f, 0x62bb, 0x62ac, 0x62e1, 0x62e3, + 0x62df, 0x62d2, 0x62f4, 0x62f3, 0x62fa, 0x6393, 0x6303, 0x62fb, + 0x62f9, 0x62de, 0x6306, 0x62dc, 0x6309, 0x62d9, + /* 0x16821..0x1687E */ + 0x6335, 0x6334, 0x6316, 0x6332, 0x6331, 0x6340, 0x6339, 0x6350, + 0x6345, 0x632f, 0x632b, 0x6317, 0x6318, 0x6385, 0x639a, 0x63aa, + 0x639f, 0x63a2, 0x6396, 0x6323, 0x638e, 0x6387, 0x638a, 0x637c, + 0x63b5, 0x6373, 0x6375, 0x63a0, 0x6389, 0x63a8, 0x63f4, 0x6413, + 0x63eb, 0x63ce, 0x63fd, 0x6403, 0x63d8, 0x640b, 0x63c1, 0x63f7, + 0x6407, 0x63e0, 0x63f2, 0x640d, 0x6422, 0x6420, 0x63bd, 0x6438, + 0x6506, 0x63fb, 0x646d, 0x642a, 0x643c, 0x655a, 0x6484, 0x6477, + 0x646b, 0x64ad, 0x646e, 0x6482, 0x6469, 0x6446, 0x642c, 0x646f, + 0x6479, 0x6435, 0x64ca, 0x6462, 0x64b9, 0x64bf, 0x649f, 0x64d9, + 0x64cd, 0x64bb, 0x64da, 0x64d0, 0x64c1, 0x64c6, 0x64d6, 0x64a1, + 0x6521, 0x64ff, 0x64f4, 0x6517, 0x6518, 0x652c, 0x651f, 0x6515, + 0x6514, 0x64fc, 0x6540, 0x6563, 0x6558, 0x6548, + /* 0x16921..0x1697E */ + 0x6541, 0x6602, 0x654b, 0x6555, 0x6580, 0x65a4, 0x6588, 0x6591, + 0x658a, 0x65a8, 0x656d, 0x6594, 0x659b, 0x65ea, 0x6587, 0x659c, + 0x6577, 0x657e, 0x6590, 0x65c9, 0x65ba, 0x65cf, 0x65b9, 0x65d0, + 0x65d5, 0x65dd, 0x65e5, 0x65dc, 0x65f9, 0x660a, 0x6613, 0x660b, + 0x65fe, 0x65fa, 0x6606, 0x6622, 0x661a, 0x6630, 0x663f, 0x664d, + 0x2e55, 0x6654, 0x665f, 0x6667, 0x6671, 0x6693, 0x66a3, 0x66a9, + 0x66aa, 0x668b, 0x668c, 0x66b6, 0x66af, 0x66c4, 0x66c6, 0x66b0, + 0x66c9, 0x6823, 0x66ab, 0x66d4, 0x66de, 0x66e9, 0x66ec, 0x66df, + 0x66db, 0x66ef, 0x6712, 0x6706, 0x6708, 0x6700, 0x6703, 0x66fb, + 0x6711, 0x6709, 0x670d, 0x66f9, 0x670a, 0x6734, 0x673f, 0x6737, + 0x673b, 0x6725, 0x6729, 0x671a, 0x6760, 0x675f, 0x6778, 0x674c, + 0x674e, 0x6774, 0x6757, 0x6768, 0x676e, 0x6759, + /* 0x16A21..0x16A7E */ + 0x6753, 0x6763, 0x676a, 0x6805, 0x67a2, 0x679f, 0x6782, 0x67af, + 0x67cb, 0x67bd, 0x67c0, 0x67d0, 0x76d6, 0x67ab, 0x67c4, 0x67b3, + 0x67c7, 0x67c6, 0x67bb, 0x67ef, 0x67f2, 0x67e0, 0x680f, 0x680d, + 0x67fe, 0x67f6, 0x67f7, 0x680e, 0x67d2, 0x6811, 0x6816, 0x6815, + 0x6822, 0x6821, 0x6831, 0x6836, 0x6839, 0x6827, 0x683b, 0x6844, + 0x6842, 0x6852, 0x6859, 0x685e, 0x6862, 0x686b, 0x6881, 0x687e, + 0x689e, 0x6875, 0x687d, 0x68b5, 0x6872, 0x6882, 0x6897, 0x6892, + 0x68ae, 0x6899, 0x68a2, 0x688d, 0x68a4, 0x68b0, 0x68bf, 0x68b1, + 0x68c3, 0x68c4, 0x68d4, 0x68d8, 0x68d9, 0x68dd, 0x68f9, 0x6902, + 0x68fc, 0x68f4, 0x68e8, 0x68f2, 0x6904, 0x690c, 0x690a, 0x6913, + 0x6943, 0x691e, 0x6925, 0x692a, 0x692b, 0x6941, 0x6944, 0x693b, + 0x6936, 0x6938, 0x694c, 0x691d, 0x6960, 0x695e, + /* 0x16B21..0x16B7E */ + 0x6966, 0x6964, 0x696d, 0x696a, 0x696f, 0x6974, 0x6977, 0x697e, + 0x6983, 0x6988, 0x698a, 0x6993, 0x6998, 0x69a1, 0x69a9, 0x69a6, + 0x69ac, 0x69af, 0x69b2, 0x69ba, 0x69bd, 0x69bf, 0x69c0, 0x69da, + 0x69dc, 0x69dd, 0x69e7, 0x69f4, 0x69f8, 0x6a03, 0x6a16, 0x6a10, + 0x6a0c, 0x6a1b, 0x6a1d, 0x6a25, 0x6a36, 0x6a41, 0x6a5b, 0x6a52, + 0x6a46, 0x6a48, 0x6a7c, 0x6a6d, 0x6a6c, 0x6a62, 0x6a85, 0x6a82, + 0x6a84, 0x6aa8, 0x6aa1, 0x6a91, 0x6aa5, 0x6aa6, 0x6a9a, 0x6aa3, + 0x6ac4, 0x6acd, 0x6ac2, 0x6ada, 0x6aeb, 0x6af3, 0x6ae7, 0x6ae4, + 0x6af1, 0x6b14, 0x6ae0, 0x6ae2, 0x6af7, 0x6ade, 0x6adb, 0x6b0c, + 0x6b07, 0x6b1a, 0x6ae1, 0x6b16, 0x6b10, 0x6b17, 0x6b20, 0x6b33, + 0x77ab, 0x6b26, 0x6b2b, 0x6b3e, 0x6b28, 0x6b41, 0x6b4c, 0x6b4f, + 0x6b4e, 0x6b49, 0x6b56, 0x6b5b, 0x6b5a, 0x6b6b, + /* 0x16C21..0x16C7E */ + 0x6b5f, 0x6b6c, 0x6b6f, 0x6b74, 0x6b7d, 0x6b80, 0x6b8c, 0x6b8e, + 0x6b92, 0x6b93, 0x6b96, 0x6b99, 0x6b9a, 0x6c3a, 0x6c41, 0x6c3f, + 0x6c48, 0x6c4c, 0x6c4e, 0x6c50, 0x6c55, 0x6c62, 0x6c6c, 0x6c78, + 0x6c7a, 0x6c82, 0x6c89, 0x6c85, 0x6c8a, 0x6c8d, 0x6c8e, 0x6c94, + 0x6c7c, 0x6c98, 0x421d, 0x6cad, 0x6caa, 0x6cbd, 0x6cb2, 0x6cb3, + 0x6cae, 0x6cb6, 0x6cc8, 0x6cc1, 0x6ce4, 0x6ce3, 0x6cda, 0x6cfd, + 0x6cfa, 0x6cfb, 0x6d04, 0x6d05, 0x6d0a, 0x6d07, 0x6d0f, 0x6d0d, + 0x6d10, 0x7f4e, 0x6d13, 0x6ccd, 0x6d14, 0x6d16, 0x6d67, 0x6d6d, + 0x6d71, 0x6d73, 0x6d81, 0x6d99, 0x6dc2, 0x6dbe, 0x6dba, 0x6dcf, + 0x6dda, 0x6dd6, 0x6dcc, 0x6ddb, 0x6dcb, 0x6dea, 0x6deb, 0x6ddf, + 0x6de3, 0x6dfc, 0x6e08, 0x6e09, 0x6dff, 0x6e1d, 0x6e1e, 0x6e10, + 0x6e1f, 0x6e42, 0x6e35, 0x6e30, 0x6e34, 0x6e4a, + /* 0x16D21..0x16D7E */ + 0x6e47, 0x6e49, 0x6e4c, 0x6e50, 0x6e48, 0x6e59, 0x6e64, 0x6e60, + 0x6e2a, 0x6e63, 0x6e55, 0x6e76, 0x6e72, 0x6e7c, 0x6e81, 0x6e87, + 0x6e85, 0x6e84, 0x6e8b, 0x6e8a, 0x6e93, 0x6e91, 0x6e94, 0x6e99, + 0x6eaa, 0x6ea1, 0x6eac, 0x6eb0, 0x6ec6, 0x6eb1, 0x6ebe, 0x6ec5, + 0x6ec8, 0x6ecb, 0x6edb, 0x6ee3, 0x6efc, 0x6efb, 0x6eeb, 0x6efe, + 0x6f0a, 0x6f05, 0x6f15, 0x6f12, 0x6f19, 0x6f13, 0x6f1c, 0x6f1f, + 0x6f1b, 0x6f0c, 0x6f26, 0x6f33, 0x6f3b, 0x6f39, 0x6f45, 0x6f42, + 0x6f3e, 0x6f4c, 0x6f49, 0x6f46, 0x6f4e, 0x6f57, 0x6f5c, 0x6f62, + 0x6f63, 0x6f64, 0x6f9c, 0x6f9f, 0x6fa3, 0x6fad, 0x6faf, 0x6fb7, + 0x6fda, 0x6fe5, 0x6fe2, 0x6fea, 0x6fef, 0x7087, 0x6ff4, 0x7005, + 0x6ff9, 0x6ffa, 0x7011, 0x7015, 0x7021, 0x700d, 0x701e, 0x7016, + 0x700b, 0x7027, 0x7036, 0x7035, 0x7039, 0x6ff8, + /* 0x16E21..0x16E7E */ + 0x704f, 0x7050, 0x7051, 0x7052, 0x700e, 0x7049, 0x703e, 0x7056, + 0x7058, 0x705e, 0x7068, 0x706f, 0x7076, 0x76a8, 0x7072, 0x7082, + 0x707d, 0x7081, 0x7080, 0x708a, 0x7089, 0x708f, 0x70a8, 0x70af, + 0x70b1, 0x70b5, 0x70e2, 0x70e4, 0x4248, 0x70db, 0x7102, 0x7112, + 0x7119, 0x7132, 0x7130, 0x714a, 0x7156, 0x7158, 0x7163, 0x7165, + 0x7169, 0x7173, 0x7172, 0x718b, 0x7189, 0x7182, 0x71a2, 0x71ab, + 0x71af, 0x71aa, 0x71b5, 0x71b4, 0x71ba, 0x71c0, 0x71c1, 0x71c9, + 0x71cb, 0x71d0, 0x71d6, 0x71df, 0x71e1, 0x71db, 0x71fc, 0x71f5, + 0x71f6, 0x721e, 0x71ff, 0x7214, 0x722c, 0x7215, 0x7211, 0x725e, + 0x7257, 0x7245, 0x7249, 0x7264, 0x7248, 0x7295, 0x723f, 0x724b, + 0x7250, 0x729c, 0x7296, 0x7293, 0x729b, 0x725a, 0x72cf, 0x72b9, + 0x72b7, 0x72e9, 0x730f, 0x72fa, 0x7344, 0x732e, + /* 0x16F21..0x16F7E */ + 0x7319, 0x7322, 0x731a, 0x7323, 0x733a, 0x7335, 0x733b, 0x735c, + 0x7360, 0x737c, 0x736e, 0x7356, 0x73b0, 0x73ac, 0x73ad, 0x7394, + 0x73b9, 0x73d6, 0x73d7, 0x73e8, 0x73e5, 0x73d8, 0x73c3, 0x73dd, + 0x73d0, 0x73c8, 0x73e4, 0x741a, 0x7414, 0x7413, 0x7403, 0x7407, + 0x7410, 0x7436, 0x742b, 0x7435, 0x7421, 0x743a, 0x7441, 0x7452, + 0x7444, 0x745b, 0x7460, 0x7462, 0x745e, 0x746a, 0x7229, 0x7470, + 0x7475, 0x7477, 0x747d, 0x745a, 0x747c, 0x747e, 0x7481, 0x747f, + 0x7582, 0x7587, 0x758a, 0x7594, 0x7596, 0x7598, 0x7599, 0x75a0, + 0x75a8, 0x75a7, 0x75ad, 0x75bc, 0x75bb, 0x75b9, 0x75be, 0x75ca, + 0x4ff6, 0x75c3, 0x75cd, 0x75cc, 0x75d5, 0x75d4, 0x75d6, 0x75dc, + 0x75e1, 0x75e5, 0x75e2, 0x7621, 0x7628, 0x762e, 0x762f, 0x7642, + 0x764c, 0x764f, 0x764b, 0x7677, 0x765c, 0x765e, + /* 0x17021..0x1707E */ + 0x765d, 0x765f, 0x7666, 0x7672, 0x766c, 0x768d, 0x7698, 0x7695, + 0x7697, 0x76aa, 0x76a7, 0x76b1, 0x76b2, 0x76b0, 0x76b4, 0x76b6, + 0x76b8, 0x76b9, 0x76ce, 0x76cb, 0x76c9, 0x76cd, 0x694d, 0x76dc, + 0x770d, 0x76d5, 0x76f9, 0x7704, 0x7706, 0x7708, 0x7713, 0x770e, + 0x7711, 0x770f, 0x7716, 0x7719, 0x7724, 0x772a, 0x7730, 0x7739, + 0x773d, 0x773e, 0x7744, 0x7746, 0x7748, 0x7742, 0x7749, 0x775c, + 0x7760, 0x7764, 0x7766, 0x7768, 0x32d2, 0x776b, 0x7771, 0x7779, + 0x7785, 0x777c, 0x7781, 0x777a, 0x7786, 0x778b, 0x778f, 0x7790, + 0x779c, 0x77a8, 0x77a6, 0x77a3, 0x77b3, 0x77b4, 0x77c3, 0x77c6, + 0x77c8, 0x77cb, 0x77dc, 0x77ed, 0x7f4f, 0x77f2, 0x5adf, 0x77f6, + 0x77f5, 0x780f, 0x780c, 0x7838, 0x7824, 0x7821, 0x7837, 0x783d, + 0x7846, 0x784f, 0x784b, 0x786b, 0x786f, 0x7870, + /* 0x17121..0x1717E */ + 0x7871, 0x7874, 0x7873, 0x78aa, 0x78af, 0x78b1, 0x78b6, 0x78c4, + 0x78c3, 0x78c6, 0x78e9, 0x78eb, 0x7903, 0x7909, 0x7912, 0x7914, + 0x7918, 0x7921, 0x791d, 0x791e, 0x7924, 0x7920, 0x792c, 0x792e, + 0x793d, 0x793e, 0x7942, 0x7949, 0x7945, 0x7950, 0x794b, 0x7951, + 0x7952, 0x794c, 0x7955, 0x7997, 0x7998, 0x79a5, 0x79ad, 0x79ae, + 0x79bc, 0x79df, 0x79db, 0x79dd, 0x79d8, 0x79d1, 0x79ed, 0x79ee, + 0x79f1, 0x79f2, 0x79fb, 0x79f8, 0x7a01, 0x7a0f, 0x7a05, 0x79e2, + 0x7a19, 0x7a2b, 0x7a37, 0x7a45, 0x7a42, 0x7a40, 0x7a43, 0x7a3e, + 0x7a55, 0x7a4d, 0x7a5b, 0x7a57, 0x7a5f, 0x7a62, 0x7a65, 0x7a64, + 0x7a69, 0x7a6b, 0x7a6a, 0x7aad, 0x7ab0, 0x7abc, 0x7ac0, 0x7acf, + 0x7ad1, 0x7ad3, 0x7ad4, 0x7ade, 0x7adf, 0x7ae2, 0x7ae3, 0x7ae6, + 0x7aef, 0x7aeb, 0x7aee, 0x7af4, 0x7af1, 0x7af7, + /* 0x17221..0x1727E */ + 0x7afb, 0x7b06, 0x7b18, 0x7b1a, 0x7b1f, 0x7b22, 0x7b23, 0x7b25, + 0x7b27, 0x7b28, 0x7b29, 0x7b2a, 0x7b2e, 0x7b2f, 0x7b32, 0x7b44, + 0x7b43, 0x7b4f, 0x7b4d, 0x7b4e, 0x7b51, 0x7b58, 0x7b74, 0x7b93, + 0x7b83, 0x7b91, 0x7b96, 0x7b97, 0x7b9f, 0x7ba0, 0x7ba8, 0x7bb4, + 0x7bc0, 0x7bca, 0x7bb9, 0x7bc6, 0x7bcf, 0x7bd1, 0x7bd2, 0x7be3, + 0x7be2, 0x7be4, 0x7bd4, 0x7be1, 0x7c3a, 0x7bf2, 0x7bf1, 0x7bf0, + 0x7c15, 0x7c14, 0x7c09, 0x7c13, 0x7c0c, 0x7c06, 0x7c08, 0x7c12, + 0x7c0a, 0x7c04, 0x7c2e, 0x7c1b, 0x7c25, 0x7c24, 0x7c21, 0x7c30, + 0x7c47, 0x7c32, 0x7c46, 0x7c3e, 0x7c5a, 0x7c60, 0x7c67, 0x7c76, + 0x7c78, 0x7ce7, 0x7cec, 0x7cf0, 0x7d09, 0x7d08, 0x7ceb, 0x7d03, + 0x7d06, 0x7d2a, 0x7d26, 0x7daf, 0x7d23, 0x7d1f, 0x7d44, 0x7d15, + 0x7d12, 0x7d41, 0x7d3f, 0x7d3e, 0x7d46, 0x7d48, + /* 0x17321..0x1737E */ + 0x7d5d, 0x7d5e, 0x7d64, 0x7d51, 0x7d50, 0x7d59, 0x7d72, 0x7d89, + 0x7d87, 0x7dab, 0x7d6f, 0x7d7a, 0x7d9a, 0x7da4, 0x7da9, 0x7db2, + 0x7dc4, 0x7dc1, 0x7dbb, 0x7db8, 0x7dba, 0x7dc6, 0x7dcf, 0x7dc2, + 0x7dd9, 0x7dd3, 0x7df8, 0x7de6, 0x7ded, 0x7def, 0x7dfd, 0x7e1a, + 0x7e1b, 0x7e1e, 0x7e75, 0x7e79, 0x7e7d, 0x7e81, 0x7e88, 0x7e8b, + 0x7e8c, 0x7e92, 0x7e95, 0x7e91, 0x7e9d, 0x7ea5, 0x7ea9, 0x7eb8, + 0x7eaa, 0x7ead, 0x7761, 0x7ecc, 0x7ece, 0x7ecf, 0x7ed0, 0x7ed4, + 0x7edc, 0x7ede, 0x7edd, 0x7ee0, 0x7ee5, 0x7ee8, 0x7eef, 0x7ef4, + 0x7ef6, 0x7ef7, 0x7ef9, 0x7efb, 0x7efc, 0x7efd, 0x7f07, 0x7f08, + 0x56b7, 0x7f15, 0x7f21, 0x7f2c, 0x7f3e, 0x7f4a, 0x7f52, 0x7f54, + 0x7f63, 0x7f5f, 0x7f60, 0x7f61, 0x7f66, 0x7f67, 0x7f6c, 0x7f6a, + 0x7f77, 0x7f72, 0x7f76, 0x7f95, 0x7f9c, 0x7fa0, + /* 0x17421..0x1747E */ + 0x382f, 0x49c7, 0x7059, 0x5464, 0x31dc, 0x5199, 0x3653, 0x3de2, + 0x3e14, 0x3e18, 0x3e58, 0x3e5e, 0x3ebe, 0x8028, 0x3ecb, 0x3ef9, + 0x3f00, 0x3f02, 0x3f07, 0x3f1d, 0x3f23, 0x3f34, 0x3f36, 0x3f3d, + 0x3f40, 0x3f45, 0x3f54, 0x3f58, 0x3f64, 0x3f67, 0x3f7d, 0x3f89, + 0x3f9c, 0x3fa7, 0x3faf, 0x3fb5, 0x3fb7, 0x3fc9, 0x3fde, 0x3fe1, + 0x3fe9, 0x400d, 0x4014, 0x4018, 0x4033, 0x4035, 0x4047, 0x813d, + 0x409d, 0x409e, 0x40cb, 0x40d4, 0x40d5, 0x40dd, 0x40f8, 0x411c, + 0x412b, 0x4130, 0x4137, 0x813e, 0x418d, 0x813f, 0x41bc, 0x41b9, + 0x8140, 0x4222, 0x423e, 0x4243, 0x4256, 0x425a, 0x426f, 0x4285, + 0x42c4, 0x42d6, 0x42fc, 0x430a, 0x4318, 0x4339, 0x4343, 0x4365, + 0x437c, 0x43e5, 0x43ed, 0x43f5, 0x4410, 0x4414, 0x4422, 0x4479, + 0x4451, 0x4460, 0x446d, 0x44ce, 0x44be, 0x44bf, + /* 0x17521..0x1757E */ + 0x44c4, 0x44ca, 0x44d0, 0x44f7, 0x44fb, 0x4522, 0x4529, 0x8141, + 0x4567, 0x459d, 0x8142, 0x4600, 0x4609, 0x4615, 0x461e, 0x463a, + 0x4622, 0x4624, 0x462b, 0x4630, 0x4631, 0x4633, 0x46fb, 0x4648, + 0x464c, 0xa8c4, 0x4659, 0x465a, 0x4661, 0x4665, 0x4673, 0x4677, + 0x4678, 0x468d, 0x8143, 0x46a0, 0x46b2, 0x46bb, 0x46c6, 0x46c8, + 0x1b22, 0x46db, 0x46e8, 0x46fa, 0x4713, 0x8029, 0x4733, 0x4766, + 0x4747, 0x4748, 0x477b, 0x4781, 0x4793, 0x4798, 0x479b, 0x47bb, + 0x47f9, 0x47c0, 0x47d7, 0x47fc, 0x4801, 0x4852, 0x481d, 0x482c, + 0x4831, 0x485b, 0x4872, 0x4875, 0x8144, 0x48a3, 0x48a5, 0x48b2, + 0x48c8, 0x48d0, 0x48e8, 0x48ed, 0x48f0, 0x48f1, 0x48fc, 0x490a, + 0x4949, 0xabc4, 0x4935, 0x4942, 0x4957, 0x4963, 0x4964, 0x4968, + 0x4980, 0x8114, 0x49a5, 0x49ad, 0x49cf, 0x1bb6, + /* 0x17621..0x1767E */ + 0x1bc3, 0x49e2, 0x49e9, 0x49ea, 0x49f5, 0x49f6, 0x4a0f, 0x4a15, + 0xad3f, 0x4a3b, 0x4a3e, 0x4a45, 0x4a50, 0x4a56, 0x4a5b, 0x4a6b, + 0x4a73, 0xad63, 0x4a89, 0x4a94, 0x4a9d, 0x4a9e, 0x4aa5, 0x4ae4, + 0x4ae7, 0x1c0f, 0x801d, 0x4b1b, 0x4b1e, 0x4b2c, 0x4b35, 0x4b46, + 0x4b56, 0x4b60, 0x4b65, 0x4b67, 0x4b77, 0x4b82, 0x4ba9, 0x4bad, + 0x8070, 0x4bcf, 0x4bd6, 0x4bd7, 0x4bff, 0x4c05, 0x4c10, 0x4c33, + 0x4c59, 0x4c5c, 0x4caa, 0x4c74, 0x4c76, 0x4c85, 0x4c86, 0x4c98, + 0x4c9c, 0x4cfb, 0x4cc6, 0x4cd4, 0x4ce0, 0x4ceb, 0x4cee, 0xb0fe, + 0x4d04, 0x4d0e, 0x4d2e, 0x4d31, 0x4d39, 0x4d3f, 0x4d58, 0x4d65, + 0x8145, 0x4d82, 0x4d87, 0x4d89, 0x4d94, 0x4daa, 0x4dac, 0x4dbf, + 0x4dc4, 0x4dd6, 0x4dda, 0x4ddb, 0x4ddd, 0x4dfc, 0x8146, 0x4e34, + 0x4e44, 0x4e5c, 0x4e5e, 0x4eab, 0x4eb1, 0x4ec1, + /* 0x17721..0x1777E */ + 0x4ec7, 0x4ece, 0x4f10, 0x4f1a, 0x8147, 0x4f2a, 0x4f2f, 0x4f33, + 0x4f51, 0x4f59, 0x4f5e, 0x4f61, 0x4f62, 0x4f7e, 0x4f88, 0x4f8c, + 0x4f8d, 0x4f94, 0x4fa0, 0x4fa7, 0x4fb6, 0x4fbc, 0x4fc7, 0x4fca, + 0x4ff9, 0x4ff0, 0x4ff5, 0x5005, 0x5006, 0x5028, 0x504a, 0x505d, + 0x505e, 0x504e, 0x5064, 0x5075, 0x5085, 0x50a4, 0x50ab, 0x50b7, + 0x50d4, 0x50d8, 0x50e4, 0x510f, 0x512b, 0x511e, 0x5120, 0x512e, + 0x5130, 0x5146, 0x5147, 0x5151, 0x8148, 0x5152, 0x515c, 0x5160, + 0x5168, 0x8115, 0x5185, 0x5187, 0x5192, 0x51c1, 0x51ba, 0x51c4, + 0x51fe, 0x5200, 0x5215, 0x5255, 0x5256, 0x1e3f, 0x528d, 0x529b, + 0x52be, 0x52c0, 0x52fb, 0xb7f1, 0x5327, 0x5328, 0x8116, 0x5350, + 0x5366, 0x537c, 0x5395, 0x539f, 0x53a0, 0x53a2, 0x53a6, 0x53ab, + 0x53c9, 0x53cf, 0x53d6, 0x53d9, 0x53e3, 0x53e9, + /* 0x17821..0x1787E */ + 0x5407, 0x540a, 0x541a, 0x541b, 0x814a, 0x5426, 0x5428, 0x542a, + 0x542b, 0x542c, 0x542e, 0x542f, 0x5430, 0x5444, 0x5446, 0x5447, + 0x544b, 0x5457, 0x5462, 0x546b, 0x546d, 0x5486, 0x5487, 0x5489, + 0x5498, 0x549c, 0x549f, 0x54a3, 0x5490, 0x54a6, 0x54a8, 0x54a9, + 0x54b5, 0x54bf, 0x54c8, 0x54c9, 0x54da, 0x54ff, 0x5501, 0x5517, + 0x552f, 0x556f, 0x5579, 0x5592, 0x1f72, 0x55ce, 0x55e4, 0x5600, + 0x5602, 0x5608, 0x5615, 0x5616, 0x5619, 0x561e, 0x562d, 0x5635, + 0x5643, 0x564b, 0x5664, 0x5665, 0x566d, 0x566f, 0x5671, 0x5681, + 0x569b, 0x569d, 0x569e, 0x56a6, 0x56aa, 0x56b6, 0x56c5, 0x56cc, + 0x56ce, 0x56d4, 0x56e6, 0x56f1, 0x56fc, 0x570a, 0x5719, 0x5734, + 0x5736, 0x5746, 0x574d, 0x574e, 0x575c, 0x575f, 0x5762, 0x577a, + 0x5780, 0x5794, 0x57aa, 0x57e0, 0x582d, 0xc18e, + /* 0x17921..0x1797E */ + 0x5843, 0x584e, 0x584f, 0x5851, 0x5868, 0x586e, 0x814b, 0x58b0, + 0xc20e, 0x58ad, 0x58e4, 0x58f2, 0x5900, 0x58f7, 0x591c, 0x592e, + 0x5931, 0x5934, 0x814c, 0x814d, 0x5945, 0x5946, 0x814e, 0x814f, + 0x8150, 0x595c, 0x8151, 0x8119, 0x811a, 0x5979, 0x8152, 0x8153, + 0x811b, 0x5998, 0x59b1, 0x59b8, 0x59c8, 0x59ca, 0xc371, 0x59d4, + 0x59de, 0x59eb, 0x59ed, 0x5a03, 0x8154, 0x5a39, 0x5a5d, 0x5a6d, + 0x8155, 0x5a85, 0x5aa0, 0xc4c4, 0x5ab3, 0x5abb, 0x5ace, 0x5aeb, + 0x5afd, 0x5b12, 0x5b2d, 0x5b3b, 0x5b47, 0x5b4e, 0x5b60, 0x5b6d, + 0x5b6f, 0x5b72, 0x5b9e, 0x8156, 0x5bd7, 0x5bd9, 0x5c01, 0x5c31, + 0x5c1e, 0x5c20, 0x5c33, 0x5c36, 0x2264, 0xc7a1, 0x5c59, 0x5c6d, + 0x5c79, 0x5c8f, 0x5c94, 0x5ca0, 0x5cbc, 0x5cd5, 0x5cd9, 0x5cdd, + 0x5d07, 0x5d08, 0x5d13, 0x5d1d, 0x5d23, 0x5d31, + /* 0x17A21..0x17A7E */ + 0x5d41, 0x5d48, 0x5d53, 0x5d5c, 0x5d7a, 0x5d83, 0x5d8b, 0x5da0, + 0x5da6, 0x5dc2, 0x5dcc, 0x5dd6, 0x5de3, 0x8157, 0x5e28, 0x5e08, + 0x5e11, 0x5e15, 0x8159, 0x5e47, 0x5e52, 0x5e61, 0x5e8a, 0x5e8d, + 0x5f47, 0x815a, 0x5f91, 0x5f97, 0x5fbf, 0x5fce, 0x5fdb, 0x5fdf, + 0x5fec, 0x5fee, 0x5ffa, 0x815b, 0x6014, 0x6026, 0x6035, 0x6037, + 0x603c, 0x60ca, 0x60d7, 0x60e0, 0x60f3, 0x6118, 0x614a, 0x6160, + 0x6167, 0x6168, 0x616d, 0x61bb, 0x61ca, 0x61cf, 0x61d7, 0x815c, + 0x2453, 0x245b, 0x6260, 0x6274, 0xd2ff, 0x628e, 0x62a1, 0x62a3, + 0x62a4, 0x62a9, 0x62ae, 0x62b7, 0x62be, 0x62bf, 0x62c6, 0x62d5, + 0x62fd, 0x62fe, 0x6300, 0x6301, 0x6362, 0x6322, 0x632d, 0x633a, + 0x6343, 0x6347, 0x6351, 0x6355, 0x637d, 0x6386, 0x6392, 0x6398, + 0x63a7, 0x63a9, 0x63bf, 0x63c0, 0x63c7, 0x63cf, + /* 0x17B21..0x17B7E */ + 0x63d1, 0x63e1, 0x63ea, 0x6401, 0x6406, 0x640a, 0x815f, 0x6448, + 0x645f, 0x6470, 0x6473, 0x6485, 0x649e, 0x64af, 0x64b4, 0x64ba, + 0x64c0, 0x64c2, 0xd440, 0x6532, 0x651e, 0x6523, 0x652f, 0x6559, + 0x6564, 0x811f, 0x65ad, 0x657a, 0x658c, 0x658f, 0x65a2, 0x65b0, + 0x65cb, 0x65ce, 0x65ed, 0x6612, 0x65ff, 0x6604, 0x6605, 0x6610, + 0xd674, 0x6618, 0x6629, 0x6638, 0x6657, 0x665b, 0x8036, 0x6662, + 0x259d, 0x666c, 0x6675, 0x6698, 0x66b8, 0x66fa, 0x66fc, 0x66fd, + 0x670b, 0x6771, 0x6787, 0x6788, 0x67ac, 0x67ad, 0x67b5, 0x25ea, + 0x67d6, 0x67ec, 0x6806, 0x680a, 0x6810, 0x6814, 0x681f, 0x6898, + 0x68aa, 0x68ca, 0x68ce, 0xd884, 0x68f5, 0x691c, 0x8160, 0x6918, + 0x6919, 0x691a, 0x6927, 0x6930, 0x6932, 0x6939, 0x6940, 0x6994, + 0x8161, 0x69d4, 0x69e5, 0x69f6, 0x6a12, 0x6a15, + /* 0x17C21..0x17C7E */ + 0x6a22, 0x6a37, 0x6a47, 0x6a4e, 0x6a5d, 0x6a61, 0x6a75, 0x6a79, + 0x6aa7, 0x6ad0, 0x6adf, 0x6af4, 0x6af6, 0x8122, 0x8162, 0x8163, + 0x6b46, 0x6b54, 0x6b59, 0x6b69, 0x6b9d, 0x6c49, 0x6c68, 0x8164, + 0x6ce1, 0x6cf4, 0x6cf8, 0x6cfe, 0x8165, 0x6d12, 0x6d1b, 0x6daf, + 0x6dce, 0x6dd1, 0x6dd7, 0x6e20, 0x6e23, 0x6e3d, 0x6e70, 0x6e7b, + 0xe177, 0x6ec0, 0x2844, 0x6efa, 0x6f1e, 0x6f2d, 0x6f36, 0x6f54, + 0xe24d, 0x6fa6, 0x6fb5, 0x6fe4, 0x6fe8, 0x6fee, 0x7008, 0x702d, + 0x8167, 0x7088, 0x7095, 0x7097, 0x7099, 0x709b, 0x70a2, 0x70b3, + 0x70be, 0x70c4, 0x70c5, 0x70c7, 0x70d7, 0x70dd, 0x70de, 0x70ef, + 0x70f4, 0x8126, 0x7114, 0x7115, 0x7116, 0x7122, 0x7123, 0x7127, + 0x712f, 0x7131, 0x7134, 0x713d, 0x7148, 0x715b, 0x7183, 0x719e, + 0x71ac, 0x71b1, 0x71bc, 0x71d7, 0x71fb, 0x71e4, + /* 0x17D21..0x17D7E */ + 0x71e5, 0x71ed, 0x71f1, 0x7207, 0x7210, 0x7238, 0x7239, 0x723a, + 0x723c, 0x7240, 0x7243, 0x724f, 0x7278, 0x7288, 0x72c2, 0x72cb, + 0x72cc, 0x72d3, 0x72e0, 0x72ff, 0x7304, 0x731f, 0x7321, 0x7325, + 0x7348, 0x7349, 0x734a, 0x7364, 0x7365, 0x736a, 0x7370, 0x739b, + 0x73a3, 0x73ba, 0x73c6, 0x73de, 0x73df, 0x7404, 0x73fd, 0x7433, + 0x744a, 0x7463, 0x746b, 0x7471, 0x7472, 0x758e, 0x759f, 0x75a6, + 0x75a9, 0x75ac, 0x75b6, 0x75bd, 0x75cb, 0x75d0, 0x75d3, 0x29b0, + 0x75da, 0x75de, 0x7658, 0x7684, 0x80dc, 0x769d, 0x76a4, 0x76a5, + 0x76d2, 0x76de, 0x8168, 0x76e9, 0x76ef, 0x7733, 0x773b, 0x774d, + 0x774e, 0x774f, 0x775a, 0x776e, 0x7773, 0x7795, 0x77ae, 0x77ba, + 0x77c1, 0x77c9, 0x77de, 0x77db, 0x77f4, 0x8169, 0x780a, 0x781e, + 0x782b, 0x7830, 0x816a, 0x7852, 0x7853, 0x7856, + /* 0x17E21..0x17E7E */ + 0x7857, 0x7859, 0x785a, 0x80d0, 0x7865, 0x786c, 0x78ba, 0x78c8, + 0x78e7, 0x7958, 0x799e, 0x7a02, 0x7a03, 0x7a24, 0x7a2d, 0x7a2e, + 0x7a38, 0x7a4a, 0x7a4e, 0x7a52, 0x7ab6, 0x7ac1, 0x7ac3, 0x7ace, + 0x7ad6, 0x7af9, 0x7b02, 0x7b08, 0x7b20, 0x2c17, 0x7b2d, 0x7b5e, + 0x7b79, 0x7b66, 0x7b72, 0x7b75, 0x7b84, 0x7b8a, 0x7b8f, 0x7b9e, + 0x7ba7, 0x7bc1, 0x7bce, 0x7be5, 0x7bf8, 0x7bfd, 0x7c00, 0x7c23, + 0x7c41, 0x7c4f, 0x7c50, 0x7c53, 0x7c63, 0x7c65, 0x7c77, 0x7d1d, + 0x7d1e, 0x7d43, 0x7d47, 0x7d52, 0x7d63, 0x7d70, 0x7d7c, 0x7d8a, + 0x7d96, 0x7dc0, 0x7dac, 0x7dbc, 0x7dd7, 0xf690, 0x7de7, 0x7e07, + 0x7e15, 0x7e7c, 0x7e9e, 0x7ea4, 0x7eac, 0x7eaf, 0x7eb4, 0x7eb5, + 0x7ec3, 0x7ed1, 0x7f10, 0x7f39, 0x7f57, 0x7f90, 0x7f94, 0x7f97, + 0x7fa2, 0x39f8, 0x3c5b, 0x3e77, 0x5626, 0x5e6b, + /* 0x22121..0x2217E */ + 0x8489, 0x2e02, 0x2e0f, 0x2e12, 0x2e29, 0x2e2b, 0x2e2e, 0x2e40, + 0x2e47, 0x2e48, 0x84a2, 0x2e51, 0x1406, 0x84a4, 0x2e5a, 0x2e69, + 0x2e9d, 0x142c, 0x142e, 0x2eb9, 0x2ebb, 0x8522, 0x2ebc, 0x2ec3, + 0x2ec8, 0x2ed0, 0x2eeb, 0x2eda, 0x2ef1, 0x2ef5, 0x2f00, 0x2f16, + 0x2f64, 0x2f37, 0x2f3e, 0x2f54, 0x2f58, 0x8593, 0x2f77, 0x2f78, + 0x2f7a, 0x2f7d, 0x2f82, 0x2f85, 0x2f92, 0x2f9a, 0x2fe6, 0x2fb2, + 0x2fbe, 0x2fc5, 0x2fcb, 0x2fcf, 0x2fd2, 0x146a, 0x2ff2, 0x3000, + 0x3010, 0x3013, 0x301c, 0x301e, 0x3022, 0x1468, 0x3042, 0x3046, + 0x304e, 0x3053, 0x3057, 0x3063, 0x3066, 0x306a, 0x3070, 0x30a3, + 0x3088, 0x3092, 0x3093, 0x3095, 0x3096, 0x309c, 0x30aa, 0x862b, + 0x30b1, 0x30ba, 0x30bb, 0x30c4, 0x30c7, 0x30f3, 0x8681, 0x30ce, + 0x8671, 0x30d4, 0x30d9, 0x30e1, 0x30e9, 0x1492, + /* 0x22321..0x2237E */ + 0x3108, 0x86f9, 0x3117, 0x311b, 0x874a, 0x3160, 0x8809, 0x3173, + 0x3183, 0x318b, 0x14bc, 0x3198, 0x31a3, 0x31ad, 0x14c7, 0x31bc, + 0x88d6, 0x8928, 0x31f3, 0x31f4, 0x3202, 0x3212, 0x3216, 0x8a4f, + 0x3255, 0x325c, 0x326c, 0x3277, 0x3284, 0x3282, 0x8b07, 0x3298, + 0x8b3a, 0x32a4, 0x32a6, 0x32af, 0x32ba, 0x32bb, 0x32ca, 0x151f, + 0x32d1, 0x8bb9, 0x32f7, 0x330a, 0x330b, 0x3324, 0x3335, 0x333e, + 0x3342, 0x8c7c, 0x8c9d, 0x3367, 0x336c, 0x337a, 0x33a4, 0x33b4, + 0x8dd3, 0x33b7, 0x33c0, 0x8e1d, 0x155d, 0x155e, 0x33d5, 0x33da, + 0x1563, 0x33f4, 0x33f5, 0x3455, 0x3424, 0x3428, 0x156e, 0x3443, + 0x3462, 0x3466, 0x346c, 0x348a, 0x348d, 0x3495, 0x34a0, 0x34a6, + 0x34ad, 0x34ae, 0x34b7, 0x34ba, 0x34bf, 0x34c3, 0x8f45, 0x34ec, + 0x34ef, 0x34f1, 0x34f3, 0x3500, 0x3501, 0x3509, + /* 0x22421..0x2247E */ + 0x353c, 0x3541, 0x15a6, 0x3547, 0x354a, 0x15a8, 0x3560, 0x3561, + 0x3564, 0x8fe1, 0x357d, 0x3582, 0x3588, 0x3591, 0x15c5, 0x35d2, + 0x9095, 0x906d, 0x35bf, 0x35c9, 0x35cc, 0x35d1, 0x35dd, 0x15da, + 0x35e2, 0x9064, 0x35e9, 0x3628, 0x915f, 0x3607, 0x3610, 0x3630, + 0x3637, 0x15f4, 0x363d, 0x363f, 0x3640, 0x3647, 0x365e, 0x3660, + 0x366d, 0x1605, 0x3688, 0x368c, 0x3695, 0x369a, 0x369d, 0x36a8, + 0x36ad, 0x36b2, 0x36c5, 0x36cd, 0x36df, 0x36e8, 0x36f6, 0x36f7, + 0x9201, 0x3715, 0x3723, 0x9255, 0x3729, 0x927b, 0x3745, 0x3746, + 0x374c, 0x374d, 0x9274, 0x3768, 0x376f, 0x3773, 0x3774, 0x3775, + 0x377b, 0x92e4, 0x92d7, 0x37ac, 0x379a, 0x379d, 0x379e, 0x37a8, + 0x37d7, 0x92fd, 0x37cc, 0x9336, 0x9344, 0x37de, 0x37e6, 0x37f0, + 0x164a, 0x37f8, 0x37fb, 0x37fd, 0x3804, 0x381e, + /* 0x22521..0x2257E */ + 0x3820, 0x3827, 0x3832, 0x3839, 0x93c4, 0x3849, 0x384c, 0x3867, + 0x388a, 0x388b, 0x388d, 0x388f, 0x3890, 0x3894, 0x389d, 0x38aa, + 0x38b1, 0x946d, 0x38c3, 0x38cd, 0x38e2, 0x38f3, 0x38f4, 0x3905, + 0x3906, 0x390b, 0x390d, 0x3914, 0x3924, 0x95d7, 0x1691, 0x393d, + 0x1699, 0x3946, 0x1696, 0xd329, 0x395b, 0x395f, 0x9647, 0x3975, + 0x3976, 0x397c, 0x399f, 0x39ae, 0x39bc, 0x39c8, 0x39cd, 0x39de, + 0x39e3, 0x39e4, 0x39e7, 0x39ee, 0x9706, 0x9742, 0x16cf, 0x3a0c, + 0x3a0d, 0x3a17, 0x3a27, 0x3a2d, 0x3a55, 0x3a65, 0x3a7a, 0x3a8b, + 0x3a9c, 0x3a9f, 0x3aa0, 0x3aa2, 0x3ab1, 0x3ab3, 0x3ab5, 0x3aba, + 0x3abf, 0x3ada, 0x3adc, 0x3ae0, 0x3ae5, 0x3af0, 0x3aee, 0x3af5, + 0x3b00, 0x3b08, 0x3b17, 0x3b34, 0x3b2d, 0x3b4c, 0x3b52, 0x3b68, + 0x3b6f, 0x3b7c, 0x3b7f, 0x3b81, 0x3b84, 0x99c3, + /* 0x22821..0x2287E */ + 0x3b96, 0x3bac, 0x1761, 0x3bc0, 0x1762, 0x3bce, 0x3bd6, 0x176c, + 0x176b, 0x3bf1, 0x3bfd, 0x1775, 0x3c03, 0x3c29, 0x3c30, 0x9a56, + 0x3c5f, 0x3c63, 0x3c67, 0x3c68, 0x3c69, 0x3c70, 0x9b2d, 0x9b45, + 0x3c7c, 0x9b78, 0x9b62, 0x3c88, 0x3c8a, 0x17c1, 0x9ba1, 0x9b9c, + 0x3ca0, 0x3ca2, 0x3ca6, 0x3ca7, 0x9b92, 0x3cad, 0x3cb5, 0x9bb7, + 0x3cc9, 0x9be0, 0x9c33, 0x3d06, 0x3d10, 0x3d2b, 0x3d1d, 0x3d20, + 0x3d24, 0x3d26, 0x3d31, 0x3d39, 0x3d42, 0x17e8, 0x3d61, 0x3d6a, + 0x17f4, 0x3d70, 0x9d1e, 0x17fd, 0x3d88, 0x1800, 0x3d92, 0x3d94, + 0x3d97, 0x3d99, 0x3db0, 0x3db2, 0x3db4, 0x9d76, 0x3db9, 0x3dd1, + 0x3dd7, 0x3dd8, 0x3de0, 0x9dfa, 0x3de4, 0x3de9, 0x182f, 0x3e00, + 0x1836, 0x3e12, 0x3e15, 0x1840, 0x3e1f, 0x3e2e, 0x3e3e, 0x3e49, + 0x185c, 0x3e56, 0x1861, 0x3e6b, 0x3e6c, 0x3e6d, + /* 0x22C21..0x22C7E */ + 0x3e6e, 0x9e7b, 0x3ea5, 0x3eaa, 0x3eac, 0x3eb9, 0x3ebf, 0x3ec6, + 0x3ed2, 0x3ed9, 0xa01e, 0x3efd, 0x3f08, 0x3f0e, 0x3f1c, 0xa0ad, + 0x3f1e, 0x3f47, 0x3f63, 0x3f72, 0x3f7e, 0x3f8f, 0x3fa2, 0x3fa4, + 0x3fb8, 0x3fc4, 0x18fa, 0x3fc7, 0x3fcb, 0x3fd2, 0x3fd3, 0x3fd4, + 0x3fe2, 0x3fee, 0x3fef, 0x3ff3, 0x3ffc, 0x1917, 0x4017, 0x4022, + 0x4024, 0x191a, 0x404c, 0x407f, 0x408a, 0x4095, 0x40a8, 0xa1f3, + 0x40b0, 0x40b1, 0x40be, 0x40c8, 0x40d9, 0x40db, 0x40ee, 0x40f2, + 0x40f5, 0x4110, 0x4112, 0x4113, 0x4119, 0x411e, 0x413a, 0x196f, + 0x4141, 0x4146, 0x4160, 0x417c, 0xa25b, 0x4192, 0x4193, 0x4197, + 0x4198, 0x41a5, 0x41a8, 0x41ad, 0xa2ab, 0x41d5, 0x41dd, 0x41df, + 0x41f5, 0xa38f, 0x4215, 0x4223, 0x4229, 0x4246, 0x424c, 0x4251, + 0x4252, 0x4261, 0x4264, 0x427b, 0x426d, 0x4273, + /* 0x22D21..0x22D7E */ + 0x4299, 0x42a6, 0x42d5, 0xa4b8, 0x42fd, 0x4303, 0x430d, 0x4310, + 0xa54f, 0xa550, 0x4332, 0x4335, 0x433b, 0x433c, 0x4341, 0x4344, + 0x434e, 0xa546, 0x4359, 0xa61d, 0xa5a6, 0x436c, 0x4384, 0x4399, + 0xa624, 0x4394, 0x43bd, 0x43f7, 0x43d4, 0x43d5, 0x43dc, 0x43e0, + 0x43eb, 0x43ec, 0x43f2, 0x4409, 0x441e, 0x4425, 0x4429, 0x442f, + 0x445a, 0x445b, 0x445d, 0x4473, 0x447d, 0x4487, 0x4491, 0x449d, + 0x449f, 0x44cb, 0x44cc, 0x44d5, 0x44d7, 0xa7e1, 0x44e4, 0x44e5, + 0x44ff, 0x4504, 0x1a6e, 0x450f, 0x4514, 0x4516, 0x1a73, 0x451e, + 0x4532, 0x4544, 0x4554, 0x456b, 0x457a, 0x4581, 0x4584, 0x4585, + 0x458a, 0x45b2, 0x45b5, 0x45b8, 0x45bf, 0x45c2, 0x45c9, 0x45d4, + 0x1ad6, 0x45f2, 0x45f9, 0x45fc, 0x4604, 0x4608, 0x4621, 0x462a, + 0x4645, 0x4651, 0x464e, 0x1aea, 0xa8c3, 0x4657, + /* 0x22E21..0x22E7E */ + 0x465b, 0x4663, 0xa8f5, 0xa8b6, 0x466a, 0x466b, 0x466c, 0x466d, + 0x467b, 0x4680, 0x4690, 0x4692, 0x4699, 0x1b0e, 0x46ad, 0x46b1, + 0x46b5, 0x1b1a, 0x46bf, 0x1b1c, 0x46ec, 0x1ad7, 0x4701, 0x4705, + 0x4712, 0xa972, 0x4719, 0xa9d3, 0xa9d2, 0x474c, 0x474d, 0x4754, + 0x475d, 0xa9d0, 0xa9e4, 0xa9d5, 0x4774, 0x4776, 0xa9da, 0x4792, + 0xa9df, 0x6363, 0x4810, 0x47b0, 0x47b2, 0x47c3, 0x47c8, 0x47d2, + 0x47d9, 0x47db, 0x47f0, 0x47f7, 0xaa4a, 0xaa51, 0xaa4b, 0x4818, + 0x481f, 0x482d, 0xaa65, 0x4833, 0x483b, 0x483e, 0x4844, 0x4845, + 0x4849, 0x484c, 0x4855, 0x4857, 0x1b77, 0x486b, 0x486e, 0x487a, + 0x487c, 0x4882, 0x4890, 0x4896, 0x1b6d, 0x4898, 0x4899, 0x489a, + 0x489c, 0x48aa, 0x48ab, 0x48b4, 0x48bb, 0x48fb, 0xaae4, 0xab5a, + 0x8113, 0x48c3, 0x48c5, 0x48cc, 0x48cf, 0x48d6, + /* 0x22F21..0x22F7E */ + 0x48d9, 0x48e4, 0x48e5, 0x48ec, 0x48f7, 0x4903, 0x4907, 0x1b87, + 0x1b88, 0xab94, 0x493b, 0x1b8d, 0x4946, 0x4969, 0x496c, 0x4972, + 0x497a, 0x497f, 0x4992, 0x1ba4, 0x4996, 0x4998, 0x49a6, 0x49b0, + 0x49b7, 0x49ba, 0x49bc, 0x49c0, 0x49d1, 0x49d6, 0xac39, 0xac47, + 0x4a30, 0xac38, 0xac3a, 0x49e3, 0x49ee, 0x49ef, 0x49f3, 0x1bcd, + 0x49f4, 0x49fe, 0x4a11, 0x4a1a, 0x4a1d, 0xad1c, 0x4a32, 0x4a33, + 0x4a34, 0x4a3f, 0x4a46, 0x4a49, 0x4a7a, 0x4a4e, 0x4a52, 0x4a64, + 0xad0c, 0x4a7e, 0x4a83, 0x4a8b, 0x1bf0, 0x4a91, 0x4a9f, 0x4aa1, + 0xad64, 0x4aab, 0x4abd, 0x4ac6, 0x4ad4, 0x4ad0, 0x4adc, 0x4add, + 0xadff, 0xade7, 0x4aec, 0x4af1, 0x4af2, 0x4af3, 0x4afd, 0xae24, + 0x4b0b, 0x4b0f, 0x4b10, 0x4b11, 0xae3d, 0x4b17, 0x1c26, 0x4b2f, + 0x4b4a, 0x4b58, 0x4b6c, 0x4b75, 0x4b7a, 0x4b81, + /* 0x26E21..0x26E7E */ + 0x4b9b, 0x4bae, 0xaf98, 0x4bbd, 0x4bbe, 0x4bc7, 0x4bc8, 0x4bc9, + 0x4bda, 0x4be6, 0x4be7, 0x4bee, 0x4bf1, 0x4c02, 0x4c0a, 0x4c0e, + 0x4c35, 0x4c36, 0x4c3a, 0xb07f, 0x4c3f, 0x4c4d, 0x4c5b, 0x4c6d, + 0x4c84, 0x4c89, 0x1cc3, 0x4c94, 0x4c95, 0x4c97, 0x4cad, 0x4cc2, + 0x4cd0, 0x1cd2, 0x4cd6, 0x4cda, 0x4cdc, 0x4ce9, 0x4cec, 0x4ced, + 0xb100, 0x4d00, 0x4d0a, 0x4d24, 0x4d26, 0x4d27, 0x4c67, 0x4d2f, + 0x4d3c, 0x4d5b, 0x4d5e, 0x4d60, 0x4d70, 0x4d80, 0x4d81, 0x4d8a, + 0x4d8d, 0x4d91, 0x4d98, 0xb140, 0x4e17, 0xb1fa, 0xb1f9, 0xb1d3, + 0x4dab, 0x4dae, 0x4db4, 0x4dc2, 0x4d34, 0x4dc8, 0x4dce, 0x4dcf, + 0x4dd0, 0x4ddf, 0x4de9, 0x4df6, 0x4e36, 0x4e1e, 0x4e22, 0x4e27, + 0x1d11, 0x4e32, 0x4e3c, 0x4e48, 0x4e49, 0x4e4b, 0x4e4c, 0x4e4f, + 0x4e51, 0x4e53, 0x4e54, 0x4e57, 0x4e63, 0x1d1e, + /* 0x26F21..0x26F7E */ + 0x4e93, 0x4ea7, 0x4eb4, 0x4ebf, 0x4ec3, 0x4eca, 0x4ed9, 0x4f35, + 0x4eeb, 0x4ef9, 0x4efb, 0x4f0a, 0x4f0c, 0x4f18, 0x4f25, 0x4f36, + 0x4f3c, 0xb27e, 0x4f52, 0x4f57, 0x4f5a, 0x4f60, 0x4f68, 0x4f98, + 0x4f7d, 0x4f90, 0x4f96, 0x4fbe, 0x4f9f, 0x4fa5, 0x4faf, 0x1d64, + 0x4fb5, 0x4fc8, 0x4fc9, 0x4fda, 0x4fde, 0x4fe9, 0xb396, 0x4ffc, + 0x5000, 0x5007, 0x500a, 0x5023, 0xb403, 0x5039, 0x503a, 0x503c, + 0x5043, 0x5047, 0x504b, 0x1d9a, 0x5054, 0x5065, 0x5069, 0x506c, + 0x506e, 0x5076, 0x507e, 0x5081, 0x5086, 0x5095, 0x5097, 0x50bb, + 0xb4c6, 0x509f, 0x50b1, 0xb4fe, 0x50ec, 0x50ca, 0x50d1, 0x50d3, + 0x50dc, 0x5103, 0x5104, 0x5106, 0x5107, 0x5108, 0x510c, 0x1dc0, + 0x512f, 0x5131, 0x5150, 0x514a, 0x5153, 0x515e, 0x1dd4, 0x5196, + 0x5180, 0x519b, 0x51a0, 0x51a2, 0x51ae, 0x51af, + /* 0x27021..0x2707E */ + 0x51b3, 0xb5bc, 0x51cb, 0x51d3, 0x51d9, 0x51dc, 0x5207, 0x1e05, + 0x8149, 0x522b, 0x5234, 0x5238, 0x5239, 0x2e2c, 0x5242, 0x5253, + 0x5257, 0x5263, 0xb629, 0x526e, 0x526f, 0x5278, 0x527f, 0x528e, + 0xb6a5, 0x52ad, 0x52ae, 0x52b0, 0x52b1, 0x52c1, 0x1e60, 0x52cc, + 0x1e66, 0x1e68, 0x52f3, 0x52fa, 0x5307, 0x5312, 0x5318, 0x5319, + 0x1e83, 0x5339, 0x532c, 0x5331, 0x5333, 0x533d, 0x5352, 0x1e94, + 0x536b, 0x536c, 0xb896, 0x536e, 0x536f, 0x5371, 0x5377, 0x5381, + 0x5385, 0x538a, 0x5394, 0x5398, 0x539c, 0x539e, 0x53a5, 0x53a8, + 0x53b5, 0x53b7, 0x53b9, 0x53bc, 0x53bf, 0x53c5, 0x53cb, 0x53e1, + 0x53e7, 0x53f9, 0x5413, 0x53fa, 0x5401, 0x5424, 0x5431, 0x5439, + 0x5453, 0x5440, 0x5443, 0x544d, 0x5452, 0x545d, 0x5471, 0x5481, + 0x5485, 0x5488, 0xb94d, 0x5492, 0x5497, 0x5499, + /* 0x27121..0x2717E */ + 0x54a0, 0x54a1, 0x54a5, 0x54aa, 0x54ab, 0x54b9, 0x54bb, 0x54ba, + 0x54d6, 0x54d8, 0x54de, 0x54ef, 0x54eb, 0xba56, 0x54fa, 0xba6f, + 0x5520, 0x5524, 0x552a, 0x1f57, 0xbb16, 0x553d, 0x553e, 0x5540, + 0x5548, 0x554e, 0x5550, 0x5552, 0x556c, 0x5572, 0x5571, 0x557a, + 0x557d, 0x557e, 0x5581, 0xbc14, 0x558c, 0x1f75, 0x55a2, 0x1f77, + 0x55b0, 0x55b7, 0x55bf, 0x55c0, 0x55c6, 0x55cf, 0x55d3, 0x55dd, + 0x55df, 0x55e0, 0x55e7, 0x55ec, 0x55ee, 0x55f1, 0x55f9, 0x5603, + 0x5618, 0x5607, 0x560f, 0x1fae, 0xbd0e, 0x5613, 0x561b, 0x561c, + 0xbd37, 0x5625, 0x5628, 0x563c, 0x5633, 0xbd6a, 0x1fc9, 0x5641, + 0xbd8b, 0x5649, 0x5655, 0x1fd7, 0x566e, 0x5695, 0x569c, 0x56a1, + 0x56a0, 0x56a7, 0x56a8, 0x56af, 0xbe4a, 0x56c9, 0xbe55, 0x56e8, + 0x56ec, 0xbf22, 0x5717, 0x571a, 0x572d, 0x5735, + /* 0x27221..0x2727E */ + 0xbfa9, 0x2039, 0xbfe5, 0xbfcd, 0x5758, 0x5760, 0x576a, 0xc01e, + 0x5772, 0x577c, 0x577d, 0xc04c, 0x2058, 0x579a, 0x579f, 0x57a2, + 0x57a4, 0x57a9, 0x57de, 0x57df, 0x57e4, 0x57e6, 0x57ea, 0x57ec, + 0x2093, 0x57f0, 0x57f4, 0x57fb, 0xc12e, 0x5805, 0x5806, 0x5809, + 0x580d, 0x5819, 0x5821, 0x582c, 0x5847, 0x5864, 0x586a, 0xc1d9, + 0x588a, 0x5894, 0x58a4, 0x589d, 0x589e, 0x589f, 0x58bb, 0x58c8, + 0x58cc, 0x58ce, 0x58d5, 0x58e0, 0x58e1, 0x58e6, 0x58f9, 0x58fa, + 0x58fb, 0x58fe, 0xc2a7, 0x5910, 0x591b, 0x5930, 0x5925, 0x593b, + 0x594a, 0x5958, 0x595b, 0x2105, 0x5967, 0x5972, 0x5994, 0x5995, + 0x5996, 0x599b, 0x59a1, 0x59a9, 0x59b4, 0x59bb, 0x59c2, 0x59c7, + 0x59cc, 0x59cd, 0x59d6, 0x2148, 0xc3a9, 0xc3b4, 0x214f, 0x5a0a, + 0x5a11, 0x5a15, 0x5a1b, 0x5a1e, 0x2163, 0x5a2d, + /* 0x27321..0x2737E */ + 0x5a38, 0x5a47, 0x5a4c, 0x5a56, 0x5a59, 0x5a5c, 0x5a5f, 0x5a60, + 0x5a67, 0x5a6a, 0x5a75, 0x5a78, 0x5a82, 0x5a8a, 0x5a90, 0x5aa3, + 0x5aac, 0xc4d4, 0x21b4, 0x5ab9, 0x5abc, 0x5abe, 0x21bf, 0x5acc, + 0x5ad1, 0x5ae7, 0x5ae8, 0x5af4, 0xc5e4, 0xc5e3, 0x5b07, 0xc5f1, + 0x5b3d, 0x5b27, 0x5b2a, 0x5b2e, 0x5b2f, 0x5b31, 0x21e6, 0x21f3, + 0x5b7f, 0x5b41, 0x21ee, 0x5b55, 0x5b79, 0x5b64, 0x5b66, 0x5b69, + 0x5b73, 0xc632, 0x2207, 0x5b90, 0x5b91, 0x5b9b, 0x220e, 0x5baf, + 0x5bb5, 0x5bbc, 0x5bc5, 0x5bca, 0xc6cb, 0xc6e4, 0x5bd4, 0x5bd6, + 0x5bda, 0x5bea, 0x5bf0, 0x5c03, 0x5c0b, 0x5c0e, 0x5c0f, 0x5c26, + 0x5c45, 0x5c4a, 0x5c51, 0x5c57, 0x5c5e, 0x5c61, 0x5c69, 0x5c6e, + 0x5c6f, 0x5c70, 0xc82e, 0xc856, 0xc865, 0x5ca6, 0xc862, 0x5cb6, + 0x5cb7, 0x5cbf, 0xc8d8, 0x5cc4, 0xc8c2, 0x5cc8, + /* 0x27421..0x2747E */ + 0x5ccd, 0xc8e8, 0x5cd7, 0xc923, 0x5ce6, 0x5ceb, 0xc95c, 0x5cf5, + 0x5d03, 0x5d09, 0x22c6, 0x5d12, 0x5d1e, 0xc9e0, 0xc9d4, 0x5d3d, + 0x5d3e, 0x5d40, 0x5d47, 0xca0c, 0xc9fb, 0x22d6, 0x5d59, 0x5d5a, + 0x5d6a, 0x5d70, 0x22dd, 0x5d7f, 0xca17, 0x5d86, 0x5d88, 0x5d8c, + 0x5d97, 0xca60, 0x5d9d, 0x5da7, 0x5daa, 0x5db6, 0x5db7, 0x5dc0, + 0x5dd7, 0x5dd9, 0x5de6, 0x5df1, 0x5df9, 0x2302, 0xcaed, 0x8158, + 0x5e10, 0x5e17, 0x5e1d, 0x5e20, 0x5e27, 0x5e2c, 0x5e45, 0x5e73, + 0x5e75, 0x5e7e, 0x5e86, 0x5e87, 0x232b, 0x5e91, 0x5e98, 0x5e9a, + 0x2343, 0x5f3c, 0x5f3b, 0x5f3e, 0x5f43, 0x5f44, 0x5f4f, 0x14c1, + 0xcb70, 0x5f52, 0xcb86, 0x5f61, 0x5f63, 0x5f64, 0x5f6d, 0x5f7d, + 0x5f7e, 0xcc4c, 0x5f90, 0x317b, 0xb10e, 0x5f96, 0x5f9c, 0x5fad, + 0xcd02, 0x5fc3, 0x5fcf, 0x5fe3, 0x5fe5, 0x5fef, + /* 0x27521..0x2757E */ + 0x5ff2, 0x6002, 0x600a, 0x6008, 0x600e, 0x6011, 0x6016, 0x6024, + 0x602c, 0x6030, 0x6043, 0x6066, 0x6071, 0x6075, 0x607b, 0x6099, + 0x609c, 0x60a4, 0x60a7, 0x60b8, 0xce7e, 0x60c5, 0x60d5, 0x60d8, + 0x60e6, 0xceb0, 0x610d, 0x60f5, 0x60fb, 0x23ee, 0x6135, 0x6116, + 0x611e, 0x23f0, 0x6124, 0x6127, 0x612c, 0xcf1d, 0x613d, 0x2408, + 0x6169, 0x2417, 0x6181, 0x241c, 0x6184, 0x6185, 0x2422, 0x6198, + 0x61b2, 0x61c1, 0x61c3, 0x61d6, 0x61db, 0xd0dd, 0x61e4, 0xd0ea, + 0x61ec, 0xd151, 0x61fd, 0x61ff, 0xd16f, 0x6204, 0xd1dd, 0x6219, + 0x6221, 0x6222, 0xd21e, 0x6232, 0x6234, 0x623c, 0x6246, 0x6249, + 0x6245, 0xd258, 0x624b, 0x2476, 0x624f, 0x247a, 0x6257, 0xd28c, + 0x625c, 0x6263, 0xd2b7, 0x815d, 0x815e, 0x6279, 0x2491, 0x627d, + 0x627f, 0x6283, 0x628a, 0x6293, 0x62a7, 0x62a8, + /* 0x27621..0x2767E */ + 0x62b2, 0x62b4, 0x62ba, 0x62bc, 0x62e2, 0x62e8, 0x62f7, 0x6307, + 0x6308, 0x630c, 0x6354, 0x631b, 0x631d, 0x6330, 0x633c, 0x6344, + 0x6357, 0x24be, 0x637f, 0x24d4, 0x24b3, 0x638d, 0x6394, 0x6395, + 0x639b, 0x639d, 0x63c9, 0x63d0, 0x63d4, 0x63dd, 0x63e5, 0x63f9, + 0x640f, 0x6411, 0x6415, 0xd373, 0x6417, 0x6439, 0x644a, 0x644f, + 0x6451, 0x6452, 0x6459, 0x645a, 0x645c, 0xd3dd, 0x6465, 0x6476, + 0x6478, 0x647c, 0x6481, 0x250d, 0x64dc, 0x6497, 0x64a6, 0x64be, + 0x2508, 0x64ce, 0x64cf, 0x64d3, 0xd465, 0x64e7, 0x64ea, 0x64ef, + 0x64f0, 0x64f1, 0x64fa, 0x64fd, 0x650c, 0x651b, 0x6524, 0x6525, + 0x652b, 0x6534, 0x654f, 0x656f, 0x2525, 0x2543, 0x653e, 0x6551, + 0x6553, 0x655e, 0x6561, 0x6562, 0xd594, 0x657b, 0x657d, 0x657f, + 0x6581, 0x6586, 0x6593, 0x659d, 0x659f, 0xd5f8, + /* 0x27721..0x2777E */ + 0xd5f6, 0xd5f7, 0x65b7, 0x65bc, 0x65c7, 0x65ca, 0x65d8, 0x65d9, + 0x65df, 0x65e1, 0x65e6, 0x65f6, 0x6600, 0x6611, 0x661e, 0x6621, + 0x6624, 0x6627, 0xd68d, 0x6639, 0x663c, 0xd6b9, 0x6640, 0x8120, + 0x6653, 0x6656, 0x666f, 0x6677, 0x667a, 0x6687, 0x6689, 0x668d, + 0x6691, 0x669c, 0x669d, 0x66a8, 0x8121, 0x66b1, 0x66b3, 0x66c1, + 0x66c3, 0x66d1, 0x66d5, 0x66d7, 0x66e3, 0x66e6, 0x25b8, 0x6705, + 0x6707, 0x670e, 0x6710, 0x6713, 0x6719, 0x671f, 0x6721, 0x6723, + 0x6731, 0x673a, 0x673e, 0x6740, 0x6743, 0x6751, 0x6758, 0x6764, + 0x6765, 0x6772, 0x677c, 0xd75b, 0xd75a, 0x67a7, 0x6789, 0x678b, + 0x6793, 0x67a0, 0xd77e, 0x25e5, 0x67be, 0xd790, 0x67c1, 0x67ce, + 0x67f5, 0x67df, 0xd7c9, 0x67e3, 0x67e5, 0x67e6, 0x67ea, 0x67eb, + 0x67ed, 0x6801, 0x6803, 0x680b, 0x6813, 0x6828, + /* 0x27821..0x2787E */ + 0x682e, 0x6832, 0x683c, 0x260f, 0x684a, 0x6858, 0x685f, 0x6864, + 0xd815, 0xd814, 0x6869, 0xd831, 0x686f, 0x68a0, 0x68bc, 0x68bd, + 0x68be, 0x68c0, 0x68d2, 0xd893, 0x68d1, 0x68d3, 0x68db, 0x68f0, + 0x68f1, 0x2641, 0x6901, 0xd90e, 0x6937, 0xd923, 0x6942, 0x6945, + 0x6949, 0xd952, 0x2665, 0x6962, 0x6980, 0x6989, 0x6990, 0x699f, + 0x69b0, 0x69b7, 0x69d6, 0x69d8, 0x69eb, 0x26a1, 0x69f1, 0x69f3, + 0x69fd, 0x69ff, 0x26af, 0x6a11, 0x6a14, 0xda85, 0x6a21, 0x6a35, + 0x6a3e, 0x6a45, 0x6a4d, 0x6a58, 0x6aae, 0x6a90, 0x6ab7, 0x6abe, + 0x6ad7, 0x6afc, 0xdb84, 0x6b0a, 0x6b05, 0x6b0d, 0x6b1c, 0x6b1f, + 0x6b2d, 0x6b43, 0x270c, 0x6b51, 0x6b5e, 0x6b76, 0x6b7f, 0x6b81, + 0x6b8b, 0x6b94, 0x6b95, 0x6b9c, 0x6b9e, 0x6c39, 0xdcb3, 0x6c3d, + 0xdcbe, 0xdcc7, 0x6c45, 0x6c47, 0x6c4f, 0x6c54, + /* 0x27921..0x2797E */ + 0x6c57, 0x6c69, 0x6c6d, 0x6c73, 0xddb8, 0x6c93, 0x6c92, 0x6c99, + 0x2764, 0x6c9b, 0x6ca4, 0x6cd6, 0x6cd5, 0x6cd9, 0xde20, 0x6cf0, + 0x6cf1, 0xde90, 0x6d09, 0x6d0e, 0x6d6c, 0x6d84, 0x6d95, 0x6da6, + 0xdfb7, 0x6dc6, 0x6dc8, 0x6dd9, 0x6dec, 0x6e0c, 0x27fd, 0x6dfd, + 0x6e06, 0xe08a, 0x6e14, 0x6e16, 0x6e21, 0x6e22, 0x6e27, 0xe0bb, + 0x2816, 0x6e36, 0x6e39, 0x6e4b, 0x6e54, 0x6e62, 0x6e6c, 0x6e6d, + 0x6e6f, 0x6e98, 0x6e9e, 0x6eae, 0x6eb3, 0x6eb5, 0x6eb6, 0x6ebb, + 0xe182, 0x6ed1, 0x6ed4, 0x284e, 0x6ef9, 0xe1f3, 0x6f00, 0x6f08, + 0x6f17, 0x6f2b, 0x6f40, 0x6f4a, 0x6f58, 0xe28c, 0x6fa4, 0x6fb4, + 0x8166, 0x6fb6, 0xe2d5, 0x6fc1, 0x6fc6, 0x8124, 0x6fca, 0x6fcd, + 0x6fd3, 0x6fd5, 0x6fe0, 0x6ff1, 0x6ff5, 0x6ffb, 0x7002, 0x700c, + 0x7037, 0xe36b, 0x7043, 0x7044, 0x705d, 0xe3c8, + /* 0x27A21..0x27A7E */ + 0xe3c9, 0x7085, 0x708c, 0x7090, 0x761d, 0x70a1, 0x28b5, 0x70b0, + 0x70b6, 0x70c3, 0x70c8, 0xe4d7, 0x70dc, 0x70df, 0xe4fa, 0x70f6, + 0x70f2, 0x7100, 0x70eb, 0x70fe, 0x70ff, 0x7104, 0x7106, 0x7118, + 0x711c, 0x711e, 0x7137, 0x7139, 0x713a, 0x7146, 0x7147, 0x7157, + 0x7159, 0x7161, 0x7164, 0x7174, 0x7179, 0x7185, 0x718e, 0x71a8, + 0x71ae, 0x71b3, 0x71b6, 0x71c3, 0x71c4, 0x71da, 0xe549, 0xe546, + 0x71ec, 0x71ee, 0x7201, 0x720a, 0x7216, 0x7217, 0xe56b, 0x7233, + 0x7242, 0x7247, 0x724a, 0x724e, 0x7251, 0x7256, 0x7259, 0x7260, + 0x7261, 0x7265, 0x7267, 0x7268, 0xe587, 0xe588, 0x727c, 0x727d, + 0x727f, 0x7289, 0x728d, 0x7297, 0x7299, 0x729f, 0x72a7, 0x72ab, + 0xe5ba, 0xe5bb, 0x72b2, 0x72bf, 0x72c0, 0x72c6, 0x72ce, 0x72d0, + 0x72d7, 0x72d9, 0x72e5, 0x72e7, 0x7311, 0xe61e, + /* 0x27B21..0x27B7E */ + 0xe629, 0x72f7, 0x72f9, 0x72fb, 0x7302, 0x730d, 0x7315, 0x731d, + 0x731e, 0x7327, 0x7329, 0xe671, 0xe643, 0x7347, 0x7351, 0x7357, + 0x735a, 0x736b, 0x7371, 0x7373, 0x73a1, 0xe699, 0xe6cd, 0x7388, + 0x738b, 0x738f, 0x739e, 0x73f5, 0xe6e4, 0xe6dd, 0x73f1, 0x73c1, + 0x73c7, 0x73dc, 0x73e2, 0x73e7, 0x7409, 0x740f, 0x7416, 0x7417, + 0x73fb, 0x7432, 0x7434, 0x743b, 0x7445, 0xe7c1, 0xe7ef, 0x746d, + 0x746f, 0x7578, 0x7579, 0x7586, 0x758c, 0x758d, 0xe810, 0x75ab, + 0x75b4, 0xe871, 0x75c8, 0xe8fb, 0xe91f, 0x762c, 0x7633, 0x7634, + 0xe936, 0x763c, 0x7641, 0x7661, 0xe989, 0x7682, 0xe9eb, 0x769a, + 0xea32, 0x29e7, 0x76a9, 0x76af, 0x76b3, 0x76ba, 0x76bd, 0x29fa, + 0xeaf8, 0x76d8, 0x76da, 0x76dd, 0x2a04, 0x7714, 0x7723, 0x2a29, + 0x7736, 0x7741, 0x7747, 0x7755, 0x7757, 0x775b, + /* 0x27C21..0x27C7E */ + 0x776a, 0xeba0, 0xebb1, 0x7796, 0x779a, 0x779e, 0x77a2, 0x77b1, + 0x77b2, 0x77be, 0x77cc, 0x77d1, 0x77d4, 0x77d8, 0x77d9, 0x77e1, + 0x77f1, 0x7804, 0x780d, 0x780e, 0x7814, 0x7816, 0x2abc, 0xec90, + 0x7823, 0x7832, 0x7833, 0x7825, 0x7847, 0x7866, 0x78ab, 0x78ad, + 0x78b0, 0xedcf, 0x78b7, 0x78b8, 0x78bb, 0x78bc, 0x78bf, 0x78c2, + 0x78c7, 0x78cb, 0x78e0, 0xee7f, 0x78e1, 0x78e3, 0x78e5, 0x78ea, + 0x78f0, 0x78f1, 0x78f3, 0x7908, 0x2b3b, 0xeef0, 0x7916, 0x7917, + 0xef19, 0x791a, 0x791b, 0x791c, 0xef50, 0x7931, 0x7932, 0x7933, + 0x793a, 0x793b, 0x793c, 0x7940, 0x7941, 0x7946, 0x794d, 0x794e, + 0x795c, 0x795f, 0x7960, 0x79a3, 0x79a6, 0x79b9, 0x79bd, 0x79bf, + 0x79c3, 0x79c9, 0x79d4, 0x79d9, 0x79de, 0xf0c6, 0x79f0, 0x79f9, + 0x79fc, 0x7a0a, 0x7a11, 0x7a16, 0x7a1a, 0x7a20, + /* 0x27D21..0x27D7E */ + 0x7a31, 0x7a36, 0x7a44, 0x7a4c, 0x7a58, 0x2bc2, 0x7aaf, 0x2bca, + 0x7ab7, 0x2bd2, 0x7ab9, 0xf172, 0x7ac6, 0x7ad0, 0x7ad2, 0x7ad5, + 0x2be8, 0x7adc, 0x7ae0, 0x7ae5, 0x7ae9, 0x7b03, 0x7b0c, 0x7b10, + 0x7b12, 0x7b16, 0x7b1c, 0x7b2b, 0x7b33, 0x7b3d, 0x2c20, 0x7b4b, + 0x7b63, 0x7b65, 0x7b6b, 0x7b6c, 0x7b73, 0x7b76, 0x7b77, 0x7ba6, + 0x7bac, 0x7bb1, 0xf2db, 0xf33d, 0x7bb2, 0x7bb8, 0x7bbe, 0x7bc7, + 0x7bf3, 0x7bd8, 0x7bdd, 0x7be7, 0x7bea, 0x7beb, 0x7bef, 0x7bee, + 0xf315, 0x7bfa, 0xf38a, 0x7bf7, 0xf349, 0x7c16, 0x7c18, 0x7c19, + 0x7c1a, 0x7c1d, 0x7c22, 0x7c27, 0x7c29, 0x7c2a, 0xf3c4, 0x7c31, + 0x7c36, 0x7c37, 0x7c45, 0x7c5c, 0xf3e9, 0x7c49, 0x7c4a, 0xf3db, + 0x7c54, 0x7c58, 0x7c5b, 0x7c5d, 0x7c5f, 0x7c69, 0x7c6a, 0x7c6b, + 0x7c6d, 0x7c6e, 0x7c70, 0x7c72, 0x7c75, 0x7c7a, + /* 0x27E21..0x27E7E */ + 0x7ce6, 0x7cf2, 0x7d0b, 0x7d02, 0xf4ce, 0x7d11, 0x7d17, 0x7d18, + 0xf52f, 0x2cc4, 0xf51a, 0x7d32, 0x2cd1, 0x7d42, 0x7d4a, 0x7d5f, + 0x7d62, 0xf5f9, 0x7d69, 0x7d6b, 0xf582, 0x7d73, 0x7d76, 0x7d77, + 0x7d7e, 0x7d84, 0x7d8d, 0x7d99, 0x7da1, 0x7dbf, 0x7db5, 0x7db9, + 0x7dbd, 0x7dc3, 0x7dc7, 0x7dc9, 0x7dd6, 0x7dda, 0x7ddf, 0x7de0, + 0x7de3, 0x7df4, 0x2d07, 0x7e0a, 0x7e02, 0x7e0d, 0x7e19, 0x7e1c, + 0x7e1d, 0x7e7b, 0x9f18, 0x7e80, 0x7e85, 0x7e9b, 0x7ea8, 0xf70c, + 0x7ebd, 0xf7b7, 0x7edf, 0x7ee7, 0x7eee, 0x7eff, 0x7f02, 0x2d77, + 0x7f03, 0x7f17, 0x7f19, 0x7f2f, 0x7f37, 0x7f3a, 0x7f3d, 0x7f41, + 0x7f45, 0x7f46, 0x7f53, 0x7f55, 0x7f58, 0xf8f1, 0x7f5d, 0xf902, + 0x7f69, 0xf91a, 0x7f6d, 0x7f70, 0x7f75, 0xf9b2, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, +}; + +static const ucs4_t jisx0213_to_ucs_pagestart[] = { + 0x0000, 0x0100, 0x0200, 0x0300, 0x0400, 0x1e00, 0x1f00, 0x2000, + 0x2100, 0x2200, 0x2300, 0x2400, 0x2500, 0x2600, 0x2700, 0x2900, + 0x3000, 0x3100, 0x3200, 0x3300, 0x3400, 0x3500, 0x3600, 0x3700, + 0x3800, 0x3900, 0x3a00, 0x3b00, 0x3c00, 0x3d00, 0x3e00, 0x3f00, + 0x4000, 0x4100, 0x4200, 0x4300, 0x4400, 0x4500, 0x4600, 0x4700, + 0x4800, 0x4900, 0x4a00, 0x4b00, 0x4c00, 0x4d00, 0x4e00, 0x4f00, + 0x5000, 0x5100, 0x5200, 0x5300, 0x5400, 0x5500, 0x5600, 0x5700, + 0x5800, 0x5900, 0x5a00, 0x5b00, 0x5c00, 0x5d00, 0x5e00, 0x5f00, + 0x6000, 0x6100, 0x6200, 0x6300, 0x6400, 0x6500, 0x6600, 0x6700, + 0x6800, 0x6900, 0x6a00, 0x6b00, 0x6c00, 0x6d00, 0x6e00, 0x6f00, + 0x7000, 0x7100, 0x7200, 0x7300, 0x7400, 0x7500, 0x7600, 0x7700, + 0x7800, 0x7900, 0x7a00, 0x7b00, 0x7c00, 0x7d00, 0x7e00, 0x7f00, + 0x8000, 0x8100, 0x8200, 0x8300, 0x8400, 0x8500, 0x8600, 0x8700, + 0x8800, 0x8900, 0x8a00, 0x8b00, 0x8c00, 0x8d00, 0x8e00, 0x8f00, + 0x9000, 0x9100, 0x9200, 0x9300, 0x9400, 0x9500, 0x9600, 0x9700, + 0x9800, 0x9900, 0x9a00, 0x9b00, 0x9c00, 0x9d00, 0x9e00, 0x9f00, + 0xf900, 0xfa00, 0xfe00, 0xff00, 0x20000, 0x20180, 0x20300, 0x20400, + 0x20500, 0x20600, 0x20700, 0x20800, 0x20900, 0x20a00, 0x20b00, 0x20d00, + 0x20e00, 0x20f00, 0x21200, 0x21300, 0x21400, 0x21500, 0x21600, 0x21700, + 0x21800, 0x21900, 0x21c00, 0x21d00, 0x21e00, 0x21f00, 0x22100, 0x22200, + 0x22300, 0x22600, 0x22800, 0x22900, 0x22a00, 0x22b00, 0x22c00, 0x22d00, + 0x23100, 0x23300, 0x23400, 0x23500, 0x23600, 0x23700, 0x23800, 0x23a00, + 0x23c00, 0x23d00, 0x23f00, 0x24000, 0x24100, 0x24300, 0x24600, 0x24700, + 0x24800, 0x24a00, 0x24b00, 0x24c00, 0x24d00, 0x24e00, 0x25000, 0x25100, + 0x25200, 0x25400, 0x25500, 0x25700, 0x25900, 0x25a00, 0x25b80, 0x25d00, + 0x25e00, 0x25f00, 0x26000, 0x26200, 0x26300, 0x26400, 0x26600, 0x26700, + 0x26800, 0x26900, 0x26a00, 0x26c00, 0x26e00, 0x26f00, 0x27080, 0x27380, + 0x27600, 0x27700, 0x27900, 0x27a00, 0x27b00, 0x27c00, 0x27d80, 0x27f00, + 0x28000, 0x28200, 0x28380, 0x28500, 0x28600, 0x28900, 0x28a00, 0x28b00, + 0x28d00, 0x28e00, 0x28f00, 0x29200, 0x29400, 0x29500, 0x29600, 0x29700, + 0x29800, 0x29a00, 0x29d00, 0x29e00, 0x29f00, 0x2a000, 0x2a100, 0x2a380, + 0x2a500, 0x2a600, +}; + +static const short jisx0213_from_ucs_level1[2715] = { + -1, -1, 0, 1, 2, 3, 4, 5, + -1, 6, 7, 8, 9, 10, 11, 12, + 13, 14, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 15, -1, -1, -1, -1, 16, -1, -1, + 17, 18, 19, -1, 20, 21, 22, 23, + 24, 25, 26, 27, 28, -1, 29, 30, + 31, 32, -1, 33, 34, 35, 36, 37, + 38, 39, -1, -1, 40, 41, -1, -1, + -1, -1, -1, -1, 42, -1, 43, 44, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 45, 46, 47, 48, -1, -1, -1, 49, + 50, 51, 52, 53, 54, 55, 56, 57, + 58, 59, 60, 61, 62, 63, 64, 65, + 66, 67, 68, 69, -1, 70, 71, 72, + 73, 74, -1, 75, 76, 77, -1, -1, + -1, 78, -1, 79, 80, 81, 82, 83, + 84, -1, -1, 85, 86, 87, 88, 89, + 90, 91, 92, -1, -1, 93, 94, 95, + 96, 97, 98, -1, 99, 100, 101, 102, + 103, 104, -1, 105, 106, 107, -1, 108, + 109, 110, 111, 112, 113, 114, 115, 116, + 117, 118, 119, -1, 120, 121, -1, 122, + 123, 124, 125, -1, -1, -1, 126, 127, + 128, -1, 129, -1, 130, -1, -1, 131, + 132, -1, -1, 133, 134, 135, -1, -1, + 136, 137, 138, 139, 140, 141, 142, 143, + 144, 145, 146, 147, 148, 149, 150, 151, + 152, 153, 154, 155, 156, 157, 158, 159, + 160, 161, 162, 163, 164, 165, 166, 167, + 168, 169, 170, 171, 172, 173, 174, 175, + 176, 177, 178, 179, 180, 181, 182, 183, + 184, 185, 186, 187, 188, 189, 190, 191, + 192, 193, 194, 195, 196, 197, 198, 199, + 200, 201, 202, 203, 204, 205, 206, 207, + 208, 209, 210, 211, 212, 213, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, 231, + 232, 233, 234, 235, 236, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 246, 247, + 248, 249, 250, 251, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 261, 262, 263, + 264, 265, 266, 267, 268, 269, 270, 271, + 272, 273, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, 286, 287, + 288, 289, 290, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, + 312, 313, 314, 315, 316, 317, 318, 319, + 320, 321, 322, 323, 324, 325, 326, 327, + 328, 329, 330, -1, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, + 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, 363, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, 374, + 375, 376, 377, 378, 379, 380, 381, -1, + 382, 383, 384, 385, 386, 387, 388, 389, + 390, 391, 392, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, 410, 411, 412, 413, + 414, 415, 416, -1, -1, 417, 418, 419, + 420, 421, 422, 423, 424, 425, 426, 427, + 428, 429, 430, 431, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, 443, + 444, 445, -1, 446, 447, 448, 449, 450, + 451, 452, 453, 454, 455, 456, 457, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 458, 459, -1, 460, + 461, 462, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 463, -1, -1, 464, 465, -1, 466, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 467, -1, 468, -1, -1, -1, 469, -1, + 470, -1, -1, -1, 471, 472, 473, 474, + -1, 475, -1, -1, 476, -1, -1, 477, + 478, -1, -1, -1, -1, 479, -1, -1, + 480, -1, 481, -1, -1, 482, 483, -1, + -1, -1, -1, 484, 485, -1, 486, -1, + -1, -1, -1, -1, -1, 487, -1, 488, + -1, 489, 490, -1, -1, 491, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 492, 493, -1, 494, 495, 496, -1, 497, + -1, 498, -1, -1, -1, -1, -1, 499, + -1, 500, 501, -1, 502, 503, -1, -1, + -1, -1, 504, -1, -1, -1, -1, 505, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, 506, -1, -1, 507, 508, 509, 510, + 511, -1, -1, -1, 512, 513, -1, 514, + -1, -1, -1, -1, -1, 515, -1, -1, + 516, -1, -1, -1, 517, -1, 518, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 519, -1, -1, -1, -1, + -1, 520, 521, -1, -1, -1, 522, -1, + -1, -1, 523, -1, -1, 524, 525, -1, + 526, -1, -1, -1, -1, -1, -1, 527, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 528, 529, + -1, -1, -1, -1, -1, 530, -1, 531, + -1, 532, -1, 533, -1, 534, 535, 536, + 537, 538, -1, -1, 539, 540, -1, 541, + 542, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 543, -1, -1, -1, -1, -1, + -1, 544, -1, 545, 546, 547, -1, 548, + -1, -1, -1, -1, -1, 549, -1, -1, + -1, -1, 550, -1, 551, -1, -1, 552, + -1, -1, -1, -1, -1, -1, 553, -1, + -1, -1, -1, -1, -1, -1, -1, -1, + 554, -1, 555, -1, -1, -1, -1, 556, + -1, -1, 557, -1, -1, -1, -1, -1, + -1, 558, -1, -1, -1, 559, -1, -1, + 560, -1, -1, -1, 561, -1, -1, -1, + 562, 563, 564, -1, -1, -1, -1, -1, + -1, 565, -1, -1, 566, -1, 567, 568, + 569, 570, -1, -1, -1, -1, -1, -1, + 571, -1, 572, 573, 574, -1, 575, -1, + -1, -1, -1, -1, -1, 576, 577, -1, + -1, -1, -1, -1, -1, -1, -1, 578, + -1, -1, -1, 579, -1, -1, 580, -1, + -1, 581, -1, -1, -1, -1, 582, -1, + 583, 584, -1, 585, 586, 587, -1, 588, + 589, 590, -1, 591, -1, -1, -1, -1, + -1, 592, 593, -1, -1, 594, -1, -1, + 595, -1, -1, -1, -1, -1, -1, -1, + -1, 596, 597, -1, 598, -1, -1, -1, + -1, -1, -1, 599, -1, 600, -1, 601, + 602, 603, 604, 605, -1, -1, -1, -1, + 606, 607, -1, 608, -1, -1, -1, -1, + -1, 609, -1, -1, -1, -1, 610, 611, + -1, -1, -1, 612, 613, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 614, + 615, 616, -1, -1, -1, -1, -1, -1, + 617, -1, 618, -1, 619, 620, -1, -1, + -1, -1, -1, -1, -1, -1, 621, -1, + -1, -1, 622, -1, -1, -1, 623, 624, + -1, -1, 625, -1, -1, -1, 626, -1, + 627, -1, -1, -1, -1, -1, 628, -1, + -1, -1, 629, -1, -1, -1, -1, -1, + -1, 630, 631, 632, -1, -1, -1, 633, + 634, 635, -1, -1, -1, 636, -1, 637, + -1, -1, -1, 638, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 639, 640, -1, + 641, 642, 643, 644, -1, -1, -1, 645, + -1, -1, -1, -1, 646, 647, -1, 648, + 649, -1, 650, 651, 652, -1, -1, 653, + -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 654, -1, -1, -1, -1, -1, + -1, -1, 655, -1, -1, -1, -1, 656, + -1, 657, -1, 658, 659, 660, -1, -1, + -1, -1, -1, 661, -1, -1, -1, -1, + -1, 662, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 663, + 664, 665, 666, 667, -1, -1, -1, 668, + 669, -1, 670, 671, -1, -1, 672, -1, + -1, -1, -1, -1, -1, -1, 673, -1, + 674, -1, -1, -1, -1, -1, -1, 675, + 676, -1, 677, +}; + +static const unsigned short jisx0213_from_ucs_level2_data[] = { + /* 0x0080 */ + 0x2922, 0x2923, 0x2171, 0x2172, 0x2924, 0x2925, 0x2178, 0x212f, + 0x2926, 0x2927, 0x2928, 0x224c, 0x2929, 0x292a, 0x292b, 0x216b, + 0x215e, 0x292c, 0x292d, 0x212d, 0x2279, 0x292e, 0x292f, 0x2930, + 0x2931, 0x2932, 0x2933, 0x2934, 0x2935, 0x2936, + /* 0x00C0 */ + 0x2937, 0x2938, 0x2939, 0x293a, 0x293b, 0x293c, 0x293d, 0x293e, + 0x293f, 0x2940, 0x2941, 0x2942, 0x2943, 0x2944, 0x2945, 0x2946, + 0x2947, 0x2948, 0x2949, 0x294a, 0x294b, 0x294c, 0x294d, 0x215f, + 0x294e, 0x294f, 0x2950, 0x2951, 0x2952, 0x2953, 0x2954, 0x2955, + 0x2956, 0x2957, 0x2958, 0x2959, 0x295a, 0x295b, 0x29dc, 0x295d, + 0x295e, 0x295f, 0x2960, 0x2961, 0x2962, 0x2963, 0x2964, 0x2965, + 0x2966, 0x2967, 0x2968, 0x2969, 0x296a, 0x296b, 0x296c, 0x2160, + 0x296d, 0x296e, 0x296f, 0x2970, 0x2971, 0x2972, 0x2973, 0x2974, + /* 0x0100 */ + 0x2975, 0x297a, 0x2a3a, 0x2a49, 0x2a21, 0x2a2c, 0x2a3c, 0x2a4b, + 0x2a59, 0x2a5f, 0x2a3d, 0x2a4c, 0x2a40, 0x2a4f, 0x2a50, 0x2978, + 0x297d, 0x2a3e, 0x2a4d, 0x2a3f, 0x2a4e, 0x2a5a, 0x2a60, 0x2a5b, + 0x2a61, 0x2a7d, 0x2976, 0x297b, 0x2a5c, 0x2a62, 0x2a3b, 0x2a4a, + 0x2a24, 0x2a2f, + /* 0x0140 */ + 0x2a23, 0x2a2e, 0x2a41, 0x2a51, 0x2a42, 0x2a52, 0x2a7a, 0x2979, + 0x297e, 0x2a43, 0x2a53, 0x2b2b, 0x2b2a, 0x2a39, 0x2a48, 0x2a44, + 0x2a54, 0x2a25, 0x2a30, 0x2a5d, 0x2a63, 0x2a27, 0x2a33, 0x2a26, + 0x2a32, 0x2a47, 0x2a57, 0x2a28, 0x2a34, 0x2977, 0x297c, 0x2a5e, + 0x2a64, 0x2a45, 0x2a55, 0x2a46, 0x2a56, 0x2a29, 0x2a35, 0x2a2b, + 0x2a38, 0x2a2a, 0x2a37, + /* 0x0180 */ + 0x2b29, + /* 0x01C0 */ + 0x2b24, 0x286f, 0x2870, 0x2871, 0x2876, 0x2877, 0x2878, 0x2879, + 0x287a, 0x287b, 0x287c, 0x2874, 0x2875, 0x2b45, + /* 0x0240 */ + 0x2b33, 0x2b39, 0x2b3a, 0x2b25, 0x2bb8, 0x2b3f, 0x2a6e, 0x2b26, + 0x2b2e, 0x2bb0, 0x2bc3, 0x2b31, 0x2b32, 0x2a75, 0x2b28, 0x2a79, + 0x2b36, 0x2b3c, 0x2b22, 0x2b42, 0x2b2c, 0x2a6a, 0x2a74, 0x2a6b, + 0x2b34, 0x2a7b, 0x2a65, 0x2a76, 0x2a6f, 0x2b2f, 0x2a6c, 0x2b41, + 0x2a73, 0x2a70, 0x2a67, + /* 0x0280 */ + 0x2a7c, 0x2a71, 0x2a68, 0x2b27, 0x2a6d, 0x2b2d, 0x2b35, 0x2a66, + 0x2bb7, 0x2b3b, 0x2a78, 0x2a72, 0x2b40, 0x2a69, 0x2b21, 0x2a7e, + 0x2b23, 0x2a77, 0x2b3e, 0x2b3d, + /* 0x02C0 */ + 0x2a31, 0x2b53, 0x2b54, 0x2b55, 0x2b56, 0x2a22, 0x2a58, 0x2a2d, + 0x2a36, 0x2b71, 0x2be0, 0x2b61, 0x2b62, 0x2b63, 0x2be4, + /* 0x0300 */ + 0x2b5c, 0x2b5a, 0x2b5f, 0x2b7d, 0x2b5b, 0x2b57, 0x2b6d, 0x2b59, + 0x2b5e, 0x2b5d, 0x2b78, 0x2b79, 0x2b7e, 0x2b6a, 0x2b76, 0x2b77, + 0x2b6b, 0x2b6c, 0x2b72, 0x2b67, 0x2b6f, 0x2b7a, 0x2b68, 0x2b70, + 0x2b73, 0x2b75, 0x2b69, 0x2b7b, 0x2b7c, 0x2b74, 0x2b6e, + /* 0x0340 */ + 0x2b52, + /* 0x0380 */ + 0x2621, 0x2622, 0x2623, 0x2624, 0x2625, 0x2626, 0x2627, 0x2628, + 0x2629, 0x262a, 0x262b, 0x262c, 0x262d, 0x262e, 0x262f, 0x2630, + 0x2631, 0x2632, 0x2633, 0x2634, 0x2635, 0x2636, 0x2637, 0x2638, + 0x2641, 0x2642, 0x2643, 0x2644, 0x2645, 0x2646, 0x2647, 0x2648, + 0x2649, 0x264a, 0x264b, 0x264c, 0x264d, 0x264e, 0x264f, + /* 0x03C0 */ + 0x2650, 0x2651, 0x2659, 0x2652, 0x2653, 0x2654, 0x2655, 0x2656, + 0x2657, 0x2658, + /* 0x0400 */ + 0x2727, 0x2721, 0x2722, 0x2723, 0x2724, 0x2725, 0x2726, 0x2728, + 0x2729, 0x272a, 0x272b, 0x272c, 0x272d, 0x272e, 0x272f, 0x2730, + 0x2731, 0x2732, 0x2733, 0x2734, 0x2735, 0x2736, 0x2737, 0x2738, + 0x2739, 0x273a, 0x273b, 0x273c, 0x273d, 0x273e, 0x273f, 0x2740, + 0x2741, 0x2751, 0x2752, 0x2753, 0x2754, 0x2755, 0x2756, 0x2758, + 0x2759, 0x275a, 0x275b, 0x275c, 0x275d, 0x275e, 0x275f, 0x2760, + 0x2761, + /* 0x0440 */ + 0x2762, 0x2763, 0x2764, 0x2765, 0x2766, 0x2767, 0x2768, 0x2769, + 0x276a, 0x276b, 0x276c, 0x276d, 0x276e, 0x276f, 0x2770, 0x2771, + 0x2757, + /* 0x1E00 */ + 0x2872, 0x2873, + /* 0x1F40 */ + 0x2b46, 0x2b47, 0x2b50, 0x2b51, + /* 0x2000 */ + 0x213e, 0x237c, 0x213d, 0x2142, 0x2146, 0x2147, 0x2148, 0x2149, + 0x2277, 0x2278, 0x2340, 0x2145, 0x2144, 0x2273, 0x216c, 0x216d, + 0x2228, 0x286b, 0x2b58, + /* 0x2040 */ + 0x2c7e, 0x286c, 0x286d, 0x286e, 0x2c7d, + /* 0x2080 */ + 0x2921, + /* 0x2100 */ + 0x216e, 0x235d, 0x235f, 0x2d62, 0x2d64, 0x2360, 0x2272, 0x235c, + /* 0x2140 */ + 0x2778, 0x2779, 0x277a, 0x2d35, 0x2d36, 0x2d37, 0x2d38, 0x2d39, + 0x2d3a, 0x2d3b, 0x2d3c, 0x2d3d, 0x2d3e, 0x2d3f, 0x2d57, 0x2c35, + 0x2c36, 0x2c37, 0x2c38, 0x2c39, 0x2c3a, 0x2c3b, 0x2c3c, 0x2c3d, + 0x2c3e, 0x2c3f, 0x2c40, + /* 0x2180 */ + 0x222b, 0x222c, 0x222a, 0x222d, 0x2271, 0x2327, 0x2325, 0x2326, + 0x2328, + /* 0x21C0 */ + 0x2329, 0x224d, 0x224e, 0x232b, 0x232c, 0x232a, 0x232d, + /* 0x2200 */ + 0x224f, 0x225f, 0x2250, 0x2247, 0x2260, 0x223a, 0x2246, 0x223b, + 0x215d, 0x235b, 0x2265, 0x2267, 0x2167, 0x2d78, 0x225c, 0x2254, + 0x2255, 0x224a, 0x224b, 0x2241, 0x2240, 0x2269, 0x226a, 0x2d73, + 0x2168, 0x2268, 0x2266, + /* 0x2240 */ + 0x226c, 0x226d, 0x226e, 0x2262, 0x2162, 0x2261, 0x226b, 0x2165, + 0x2166, 0x2263, 0x2264, 0x226f, 0x2270, + /* 0x2280 */ + 0x223e, 0x223f, 0x2242, 0x2243, 0x223c, 0x223d, 0x2244, 0x2245, + 0x2251, 0x2252, 0x2253, 0x225d, 0x2d79, + /* 0x22C0 */ + 0x2776, 0x2777, + /* 0x2300 */ + 0x2248, 0x2249, 0x225e, 0x277c, + /* 0x2380 */ + 0x2742, 0x2743, + /* 0x23C0 */ + 0x2744, 0x2745, 0x2746, 0x2747, 0x2748, 0x2749, 0x274a, 0x274b, + 0x274c, 0x274d, 0x274e, 0x274f, 0x2750, 0x277e, + /* 0x2400 */ + 0x277d, + /* 0x2440 */ + 0x2d21, 0x2d22, 0x2d23, 0x2d24, 0x2d25, 0x2d26, 0x2d27, 0x2d28, + 0x2d29, 0x2d2a, 0x2d2b, 0x2d2c, 0x2d2d, 0x2d2e, 0x2d2f, 0x2d30, + 0x2d31, 0x2d32, 0x2d33, 0x2d34, + /* 0x24C0 */ + 0x2c41, 0x2c42, 0x2c43, 0x2c44, 0x2c45, 0x2c46, 0x2c47, 0x2c48, + 0x2c49, 0x2c4a, 0x2c4b, 0x2c4c, 0x2c4d, 0x2c4e, 0x2c4f, 0x2c50, + 0x2c51, 0x2c52, 0x2c53, 0x2c54, 0x2c55, 0x2c56, 0x2c57, 0x2c58, + 0x2c59, 0x2c5a, 0x2c2b, 0x2c2c, 0x2c2d, 0x2c2e, 0x2c2f, 0x2c30, + 0x2c31, 0x2c32, 0x2c33, 0x2c34, 0x265a, 0x265b, 0x265c, 0x265d, + 0x265e, 0x265f, 0x2660, 0x2661, 0x2662, 0x2663, + /* 0x2500 */ + 0x2821, 0x282c, 0x2822, 0x282d, 0x2823, 0x282e, 0x2824, 0x282f, + 0x2826, 0x2831, 0x2825, 0x2830, 0x2827, 0x283c, 0x2837, 0x2832, + 0x2829, 0x283e, 0x2839, 0x2834, 0x2828, 0x2838, 0x283d, 0x2833, + 0x282a, 0x283a, 0x283f, 0x2835, 0x282b, 0x283b, + /* 0x2540 */ + 0x2840, 0x2836, + /* 0x2580 */ + 0x2223, 0x2222, 0x266d, 0x2225, 0x2224, 0x2322, 0x2321, 0x2227, + 0x2226, + /* 0x25C0 */ + 0x2324, 0x2323, 0x2221, 0x217e, 0x233b, 0x217b, 0x217d, 0x217c, + 0x2867, 0x2868, 0x2869, 0x286a, 0x233f, 0x227e, + /* 0x2600 */ + 0x2668, 0x2669, 0x266a, 0x266b, 0x217a, 0x2179, 0x2667, 0x2664, + 0x2665, 0x2d7e, + /* 0x2640 */ + 0x216a, 0x2169, 0x263a, 0x263d, 0x263b, 0x2640, 0x2639, 0x263e, + 0x263c, 0x263f, 0x266c, 0x227d, 0x2276, 0x227b, 0x227c, 0x2275, + 0x227a, 0x2274, + /* 0x2700 */ + 0x277b, + /* 0x2740 */ + 0x2d7d, 0x2c21, 0x2c22, 0x2c23, 0x2c24, 0x2c25, 0x2c26, 0x2c27, + 0x2c28, 0x2c29, 0x2c2a, + /* 0x2900 */ + 0x232e, 0x232f, + /* 0x2980 */ + 0x233a, + /* 0x29C0 */ + 0x237d, 0x237e, + /* 0x3000 */ + 0x2121, 0x2122, 0x2123, 0x2137, 0x2139, 0x213a, 0x213b, 0x2152, + 0x2153, 0x2154, 0x2155, 0x2156, 0x2157, 0x2158, 0x2159, 0x215a, + 0x215b, 0x2229, 0x222e, 0x214c, 0x214d, 0x225a, 0x225b, 0x2258, + 0x2259, 0x2141, 0x2d60, 0x2d61, 0x2666, 0x2233, 0x2234, 0x2235, + 0x2236, 0x2237, 0x233c, + /* 0x3040 */ + 0x2421, 0x2422, 0x2423, 0x2424, 0x2425, 0x2426, 0x2427, 0x2428, + 0x2429, 0x242a, 0x24ab, 0x242c, 0x24ad, 0x242e, 0x24af, 0x2430, + 0x24b1, 0x2432, 0x24b3, 0x2434, 0x2435, 0x2436, 0x2437, 0x2438, + 0x2439, 0x243a, 0x243b, 0x243c, 0x243d, 0x243e, 0x243f, 0x2440, + 0x2441, 0x2442, 0x2443, 0x2444, 0x2445, 0x2446, 0x2447, 0x2448, + 0x2449, 0x244a, 0x244b, 0x244c, 0x244d, 0x244e, 0x244f, 0x2450, + 0x2451, 0x2452, 0x2453, 0x2454, 0x2455, 0x2456, 0x2457, 0x2458, + 0x2459, 0x245a, 0x245b, 0x245c, 0x245d, 0x245e, 0x245f, + /* 0x3080 */ + 0x2460, 0x2461, 0x2462, 0x2463, 0x2464, 0x2465, 0x2466, 0x2467, + 0x2468, 0x2469, 0x246a, 0x246b, 0x246c, 0x246d, 0x246e, 0x246f, + 0x2470, 0x2471, 0x2472, 0x2473, 0x2474, 0x2475, 0x2476, 0x212b, + 0x212c, 0x2135, 0x2136, 0x2239, 0x237b, 0x2521, 0x2522, 0x2523, + 0x2524, 0x2525, 0x2526, 0x2527, 0x2528, 0x2529, 0x252a, 0x25ab, + 0x252c, 0x25ad, 0x252e, 0x25af, 0x2530, 0x25b1, 0x2532, 0x25b3, + 0x2534, 0x2535, 0x2536, 0x2537, 0x2538, 0x2539, 0x253a, 0x25bb, + 0x253c, 0x253d, 0x253e, 0x253f, + /* 0x30C0 */ + 0x2540, 0x2541, 0x2542, 0x2543, 0x25c4, 0x2545, 0x2546, 0x2547, + 0x25c8, 0x2549, 0x254a, 0x254b, 0x254c, 0x254d, 0x254e, 0x254f, + 0x2550, 0x2551, 0x2552, 0x2553, 0x2554, 0x2555, 0x2556, 0x2557, + 0x2558, 0x2559, 0x255a, 0x255b, 0x255c, 0x255d, 0x255e, 0x255f, + 0x2560, 0x2561, 0x2562, 0x2563, 0x2564, 0x2565, 0x2566, 0x2567, + 0x2568, 0x2569, 0x256a, 0x256b, 0x256c, 0x256d, 0x256e, 0x256f, + 0x2570, 0x2571, 0x2572, 0x2573, 0x2574, 0x2575, 0x2576, 0x2772, + 0x2773, 0x2774, 0x2775, 0x2126, 0x213c, 0x2133, 0x2134, 0x2238, + /* 0x31C0 */ + 0x266e, 0x266f, 0x2670, 0x2671, 0x2672, 0x2673, 0x2674, 0x26f5, + 0x2676, 0x2677, 0x2679, 0x267a, 0x267b, 0x267c, 0x267d, 0x267e, + /* 0x3200 */ + 0x2d6a, 0x2d6b, 0x2d6c, + /* 0x3240 */ + 0x2841, 0x2842, 0x2843, 0x2844, 0x2845, 0x2846, 0x2847, 0x2848, + 0x2849, 0x284a, 0x284b, 0x284c, 0x284d, 0x284e, 0x284f, + /* 0x3280 */ + 0x2d65, 0x2d66, 0x2d67, 0x2d68, 0x2d69, 0x2850, 0x2851, 0x2852, + 0x2853, 0x2854, 0x2855, 0x2856, 0x2857, 0x2858, 0x2859, 0x285a, + 0x285b, 0x285c, 0x285d, 0x285e, + /* 0x32C0 */ + 0x2c5b, 0x2c5c, 0x2c5d, 0x2c5e, 0x2c5f, 0x2c60, 0x2c61, 0x2c62, + 0x2c63, 0x2c64, 0x2c65, 0x2c66, 0x2c67, 0x2c68, 0x2c69, 0x2c6a, + 0x2c6b, 0x2c6c, 0x2c6d, 0x2c6e, 0x2c71, 0x2c70, 0x2c73, 0x2c72, + 0x2c6f, + /* 0x3300 */ + 0x2d46, 0x2d4a, 0x2d41, 0x2d44, 0x2d42, 0x2d4c, 0x2d4b, 0x2d45, + 0x2d4d, 0x2d47, 0x2d4f, + /* 0x3340 */ + 0x2d40, 0x2d4e, 0x2d43, 0x2d48, 0x2d49, 0x2d5f, 0x2d6f, 0x2d6e, + 0x2d6d, + /* 0x3380 */ + 0x2d53, 0x2d54, 0x2d50, 0x2d51, 0x2d52, 0x2d56, + /* 0x33C0 */ + 0x2d55, 0x235e, 0x2d63, + /* 0x3400 */ + 0x2e23, 0xa12d, 0xa132, 0xa133, + /* 0x3440 */ + 0xa15e, 0xa156, + /* 0x3480 */ + 0xa17e, 0x2e53, 0xa32b, + /* 0x34C0 */ + 0xf468, 0xa32f, 0x2e5b, + /* 0x3500 */ + 0xa348, + /* 0x3540 */ + 0xa35d, 0xa35e, 0xa361, 0xa367, + /* 0x3580 */ + 0xa423, 0xa426, + /* 0x35C0 */ + 0xa42f, 0xa438, 0xa442, + /* 0x3600 */ + 0xa44a, + /* 0x3640 */ + 0xa479, + /* 0x3680 */ + 0xa53f, 0xa543, 0xa541, + /* 0x36C0 */ + 0xa557, + /* 0x3740 */ + 0xa823, 0xa825, 0xa829, 0xa828, 0xa82c, + /* 0x3780 */ + 0x4f5f, + /* 0x37C0 */ + 0xa83e, 0x4f6f, 0xa856, 0xa859, 0xa85c, + /* 0x3800 */ + 0xa85e, 0xa86f, 0xa871, + /* 0x3840 */ + 0xa874, 0xa879, 0xa87b, + /* 0x38C0 */ + 0xac3b, + /* 0x3900 */ + 0xac46, 0xac4a, + /* 0x3940 */ + 0xac60, + /* 0x3A40 */ + 0xad5b, 0xad5f, + /* 0x3AC0 */ + 0xad71, 0xae36, 0xad7c, + /* 0x3B00 */ + 0xae2e, 0xae32, 0xae34, 0x7549, + /* 0x3B40 */ + 0xae6d, 0xae65, + /* 0x3B80 */ + 0xaf28, 0xaf29, 0xaf2c, 0xaf34, 0x757e, + /* 0x3BC0 */ + 0x7621, 0xaf48, 0xaf5d, + /* 0x3C00 */ + 0x763a, 0xaf77, + /* 0x3CC0 */ + 0xee3b, 0xee42, + /* 0x3D00 */ + 0xee71, 0xee7e, + /* 0x3D40 */ + 0xef40, + /* 0x3D80 */ + 0xef54, + /* 0x3DC0 */ + 0xef70, 0xef77, + /* 0x3E00 */ + 0xf028, 0x7766, + /* 0x3E40 */ + 0xf03f, 0xf041, 0xf042, + /* 0x3E80 */ + 0xf049, 0xf050, + /* 0x3F40 */ + 0xf134, 0x784d, 0xf146, 0xf148, + /* 0x3F80 */ + 0xf15c, + /* 0x3FC0 */ + 0xf167, 0xf16c, + /* 0x4000 */ + 0xf222, + /* 0x4040 */ + 0xf22d, + /* 0x4080 */ + 0xf239, + /* 0x4100 */ + 0xf264, + /* 0x4140 */ + 0xf274, 0xf277, 0xf27d, + /* 0x4180 */ + 0xf333, 0xf337, + /* 0x41C0 */ + 0xf347, 0xf34b, 0xf348, + /* 0x4200 */ + 0xf353, 0xf357, + /* 0x4240 */ + 0x796d, + /* 0x42C0 */ + 0xf42b, 0xf436, 0xf43b, + /* 0x4300 */ + 0xf44e, 0xf45d, + /* 0x4340 */ + 0xf461, + /* 0x43C0 */ + 0xf53e, 0xf542, + /* 0x4400 */ + 0xf548, 0xf54a, 0xf54c, 0xf54f, + /* 0x4440 */ + 0x7a59, 0x7a5a, 0xf56c, 0xf56e, + /* 0x4480 */ + 0xf577, 0xf635, 0xf632, + /* 0x44C0 */ + 0xf634, + /* 0x4500 */ + 0xf659, 0xf654, 0xf66d, + /* 0x4540 */ + 0xf66e, + /* 0x4580 */ + 0x7b51, 0xf74f, + /* 0x45C0 */ + 0xf76c, 0x7b60, + /* 0x4600 */ + 0xf824, + /* 0x4640 */ + 0xf83a, 0xf843, + /* 0x4680 */ + 0xf84e, 0xf853, + /* 0x4700 */ + 0xf86b, + /* 0x4740 */ + 0xf929, + /* 0x47C0 */ + 0xf93f, + /* 0x4800 */ + 0xf949, + /* 0x4840 */ + 0x7c4b, 0xf95c, + /* 0x4880 */ + 0xfa27, + /* 0x4980 */ + 0x7d58, + /* 0x49C0 */ + 0xfb6a, 0xfb70, + /* 0x4A00 */ + 0xfb75, 0xfb78, + /* 0x4A80 */ + 0xfc37, + /* 0x4B00 */ + 0xfc55, + /* 0x4BC0 */ + 0xfd26, 0xfd28, 0xfd2a, 0xfd31, + /* 0x4C00 */ + 0x7e3e, 0xfd3f, + /* 0x4CC0 */ + 0xfe2a, 0xfe2d, + /* 0x4D00 */ + 0xfe4b, + /* 0x4D40 */ + 0xfe60, + /* 0x4E00 */ + 0x306c, 0x437a, 0xa122, 0x3c37, 0x4b7c, 0x3e66, 0x3b30, 0x3e65, + 0x323c, 0x4954, 0x4d3f, 0xa123, 0x5022, 0x312f, 0xa124, 0x336e, + 0x5023, 0x4024, 0x5242, 0x3556, 0x4a3a, 0x3e67, 0x4e3e, 0x4a42, + 0x2e24, 0xa125, 0x5024, 0xa126, 0xf02e, 0x4366, 0xa127, 0x2e25, + 0x2e26, 0x5025, 0x367a, 0x5026, 0x345d, 0x4330, 0x3c67, 0x5027, + 0x5028, + /* 0x4E40 */ + 0xa128, 0x5029, 0x4735, 0x3557, 0xa129, 0xa12a, 0x4737, 0x4663, + 0x3843, 0x4b33, 0xa12c, 0x6949, 0x502a, 0x3e68, 0x502b, 0x3235, + 0xa12f, 0x3665, 0x3870, 0x4c69, 0x5626, 0xa130, 0x4d70, 0x467d, + 0x3425, + /* 0x4E80 */ + 0x3535, 0x502c, 0x502d, 0x4e3b, 0x4d3d, 0x4168, 0x502f, 0x3b76, + 0x4673, 0x2e27, 0x5032, 0x313e, 0x385f, 0x385e, 0x3066, 0x4f4b, + 0x4f4a, 0x3a33, 0x3021, 0xa131, 0x5033, 0x5034, 0x5035, 0x4b34, + 0x5036, 0x3872, 0x3067, 0x4b72, 0x357c, 0x357d, 0x357e, 0x4462, + 0x4e3c, 0x5037, 0x5038, 0x5039, 0xa134, 0x3f4d, 0xa135, 0xa137, + /* 0x4EC0 */ + 0x3d3a, 0x3f4e, 0x503e, 0xa138, 0x503c, 0x503d, 0x3558, 0xa139, + 0x3a23, 0x3270, 0x503b, 0x503a, 0x4a29, 0xa13a, 0x3b46, 0x3b45, + 0x423e, 0x503f, 0x4955, 0x4067, 0xa13c, 0x2138, 0x5040, 0x5042, + 0x2e28, 0x4265, 0x4e61, 0x304a, 0xa13b, 0x5041, 0x323e, 0x3644, + 0xa13d, 0x4367, 0xa13e, 0x376f, 0x5043, 0x4724, 0x2e29, 0x2e2a, + /* 0x4F00 */ + 0xa13f, 0x346b, 0x2e2b, 0x5044, 0x304b, 0x2e2c, 0x3860, 0x346c, + 0x497a, 0x4832, 0x3559, 0xa140, 0x3271, 0x5067, 0x4541, 0x476c, + 0x5046, 0x483c, 0x4e62, 0xa142, 0x3f2d, 0x3b47, 0x3b77, 0x3240, + 0xa143, + /* 0x4F40 */ + 0x4451, 0x4322, 0x504a, 0x2e2e, 0x2e2f, 0x304c, 0x4463, 0x3d3b, + 0x3a34, 0x4d24, 0x424e, 0xa144, 0x323f, 0x2e30, 0x5049, 0xa145, + 0x4d3e, 0x5045, 0x5047, 0x3a6e, 0x5048, 0x5524, 0x2e31, 0x2e2d, + 0xa141, 0x5050, 0x2e32, 0x2e33, 0x5053, 0x5051, 0x3242, 0x4a3b, + 0x504b, 0xa147, 0xa148, 0xa149, 0x504f, 0x3873, 0xa14a, 0x2e34, + 0x3b48, + /* 0x4F80 */ + 0xa14b, 0x3426, 0xa14c, 0x5054, 0x504c, 0x2e35, 0x4e63, 0x3b78, + 0x504d, 0x5052, 0xa14d, 0x2e36, 0x5055, 0x2e37, 0x504e, 0xa14e, + 0x3621, 0x304d, 0x3622, 0x3241, 0x5525, 0x4b79, 0x496e, 0x3874, + 0xa150, 0x3f2f, 0x4e37, 0xa151, 0x4a58, + /* 0x4FC0 */ + 0x3738, 0x4225, 0x3264, 0xa152, 0x2e39, 0x3d53, 0xa153, 0x5059, + 0xa154, 0x505e, 0x505c, 0xa155, 0x5057, 0x422f, 0x505a, 0x505d, + 0x505b, 0x4a5d, 0x5058, 0x2e3a, 0x3f2e, 0x4b73, 0x505f, 0x5060, + 0xa14f, 0x3d24, 0x506d, 0x2e21, 0xa157, 0x4750, 0x4936, 0x5068, + 0x4a70, 0x3236, 0x506c, + /* 0x5000 */ + 0xa158, 0x2e3b, 0x2e3c, 0x5066, 0x506f, 0x4152, 0x3844, 0x475c, + 0x2e3d, 0x6047, 0xa159, 0x506e, 0x455d, 0xa15a, 0x5063, 0x3876, + 0x2e3e, 0x3875, 0x5061, 0xa15b, 0xa15c, 0x3c5a, 0x5069, 0xa15d, + 0x4a6f, 0x434d, 0x5065, 0x3771, 0x2e3f, 0x5062, 0x506a, 0x5064, + 0x4e51, 0x506b, 0x4f41, 0x2e40, 0x3666, 0x3770, 0x2e42, + /* 0x5040 */ + 0x2e41, 0x2e43, 0xa15f, 0x5070, 0xa160, 0x5071, 0x5075, 0x304e, + 0xa161, 0x4a50, 0x5074, 0xa162, 0x5073, 0x5077, 0xa163, 0x5076, + 0x4464, 0xa164, 0x3772, 0xa165, 0xa166, 0x5078, 0xa167, 0x3c45, + 0x4226, 0x4465, 0x3676, 0x5079, 0x3536, + /* 0x5080 */ + 0x507a, 0x507c, 0xa169, 0x4b35, 0x3766, 0xa16a, 0xa16b, 0x2e44, + 0xa16c, 0xa16d, 0x3b31, 0x4877, 0x507b, 0xa16e, 0xa168, 0xa16f, + 0x3a45, 0x4d43, 0xa171, 0x507e, 0x5123, 0x507d, 0x3a44, 0x3d7d, + 0xa172, 0xa173, 0x3739, + /* 0x50C0 */ + 0x5124, 0xa174, 0x364f, 0xa175, 0x5121, 0x5122, 0x2e45, 0x462f, + 0xa178, 0x417c, 0x2e47, 0x3623, 0xa17a, 0x4b4d, 0x5125, 0xa17b, + 0x4e3d, 0x5126, 0xa17c, 0x5129, 0x5127, 0x2e48, 0x414e, 0xa17d, + 0x5128, 0x512a, 0x2e46, 0xa176, 0x512c, 0x512b, 0x4a48, + /* 0x5100 */ + 0x3537, 0x512e, 0x512f, 0x2e4b, 0x322f, 0x2e4a, 0xa321, 0x512d, + 0x2e4c, 0x3c74, 0x5132, 0x5131, 0x5130, 0xa323, 0x5056, 0x5133, + 0xa324, 0x2e4d, 0x3d7e, 0x5134, 0x4d25, 0x4c59, 0x2e4e, 0x5136, + 0x5135, 0x5138, 0x5137, 0x5139, + /* 0x5140 */ + 0x513a, 0x3074, 0x3835, 0x373b, 0x3d3c, 0x437b, 0x3624, 0x4068, + 0x3877, 0x2e4f, 0x396e, 0x513c, 0x4c48, 0x4546, 0x3b79, 0x513b, + 0x513d, 0x2e51, 0x2e52, 0x455e, 0x3375, 0xa326, 0x513e, 0x467e, + 0x4134, 0x5140, 0x5141, 0x482c, 0x3878, 0x4f3b, 0x5142, 0x3626, + 0xa328, 0x4a3c, 0x4236, 0x3671, 0x4535, 0xf474, 0x3773, + /* 0x5180 */ + 0x5143, 0x5144, 0xa329, 0x4662, 0x315f, 0x5147, 0x3a7d, 0xa32a, + 0x5146, 0x3a46, 0x5148, 0x666e, 0x5149, 0x4b41, 0x514a, 0x514b, + 0x514c, 0x3e69, 0xa32c, 0x3c4c, 0x2e54, 0x3427, 0x514f, 0xa32d, + 0x514d, 0x4c3d, 0x514e, 0x495a, 0x5150, 0x5151, 0x5152, 0x455f, + 0xa32e, 0x5156, 0x5154, 0x5155, 0x5153, 0x3a63, 0x5157, 0x4c6a, + 0x4e64, 0xa330, 0x5158, + /* 0x51C0 */ + 0x2e55, 0x4028, 0x5159, 0x3d5a, 0x515a, 0x2e56, 0x437c, 0x4e3f, + 0x4560, 0x5245, 0x515b, 0x7425, 0x3645, 0x2e57, 0x515c, 0x4b5e, + 0x2e58, 0x3d68, 0x427c, 0x515e, 0x4664, 0x515f, 0x2e59, 0x5160, + 0x332e, 0xa333, 0xa334, 0x5161, 0x3627, 0x464c, 0x317a, 0x3d50, + 0x4821, 0x5162, + /* 0x5200 */ + 0x4561, 0x2e5a, 0xa335, 0x3f4f, 0x5163, 0x4a2c, 0x405a, 0x3422, + 0x3429, 0x5164, 0x5166, 0x373a, 0xa336, 0x2e5c, 0x5165, 0x2e5d, + 0xa337, 0x4e73, 0x3d69, 0x483d, 0x4a4c, 0x5167, 0x4d78, 0x5168, + 0x5169, 0x457e, 0x516a, 0x4029, 0x3a7e, 0x3774, 0x516b, 0x3b49, + 0x396f, + /* 0x5240 */ + 0x4466, 0x516d, 0x4227, 0x2e5e, 0x3a6f, 0x516e, 0x516f, 0x4130, + 0x516c, 0x5171, 0xa339, 0x4b36, 0x2e5f, 0x3964, 0xa33a, 0x2f7e, + 0x5170, 0x2e60, 0x3775, 0x3a5e, 0x476d, 0x5174, 0x5172, 0xa33b, + 0x497b, 0x3e6a, 0x517b, 0x3364, 0x5175, 0x5173, 0x414f, 0xa33c, + 0x5177, 0x5176, + /* 0x5280 */ + 0xa33e, 0x3344, 0xa33d, 0x3760, 0x517c, 0x4e2d, 0x5178, 0x517d, + 0x517a, 0x2e61, 0x5179, 0xa340, 0x4e4f, 0x3879, 0x3243, 0x4e74, + 0xa342, 0xa343, 0x3d75, 0x4558, 0x3965, 0x5222, 0x5223, 0xa344, + 0x4e65, 0x4f2b, 0x5225, 0x387a, 0xa345, 0xa346, 0x5224, 0x332f, + /* 0x52C0 */ + 0x5226, 0x4b56, 0x443c, 0x4d26, 0x2e62, 0x4a59, 0xa347, 0x2e64, + 0x5227, 0x2e65, 0xa349, 0x7055, 0x4630, 0x2e66, 0x5228, 0x342a, + 0x4c33, 0x2e67, 0x3e21, 0x5229, 0x4a67, 0x522d, 0x402a, 0x522a, + 0x3650, 0x522b, 0x342b, 0x2e69, 0x372e, 0x522e, 0x522f, 0xa34b, + 0x5230, 0x5231, 0x3c5b, 0x2e6a, 0x387b, 0x4c5e, + /* 0x5300 */ + 0x2e6b, 0x4c68, 0x4677, 0x4a71, 0x5232, 0x2e6c, 0x5233, 0xa34c, + 0xa34d, 0x5235, 0x5237, 0x5236, 0x5238, 0x323d, 0x4b4c, 0x3a7c, + 0x5239, 0x2e6d, 0x4159, 0x3e22, 0x3629, 0x523a, 0xa34e, 0x485b, + 0x523b, 0x523c, 0x523d, 0xa34f, 0x523e, 0x4924, 0x3668, 0x3065, + 0xa350, 0x463f, + /* 0x5340 */ + 0x523f, 0x3d3d, 0xa351, 0x4069, 0x5241, 0x5240, 0x3e23, 0x3861, + 0x5243, 0x483e, 0x5244, 0x485c, 0x4234, 0x426e, 0x3628, 0x466e, + 0x4331, 0x476e, 0x4b4e, 0x5246, 0x406a, 0x2e6f, 0x2e70, 0x3735, + 0xa354, 0x5247, 0xa355, 0x5248, 0x312c, 0x3075, 0x346d, 0x4228, + 0x3551, 0x4d71, 0x524b, 0x3237, 0xa356, 0x524a, 0x2e71, 0x362a, + /* 0x5380 */ + 0x524c, 0x4c71, 0x2e72, 0x524d, 0x4e52, 0x387c, 0x2e73, 0x3836, + 0x524e, 0xa357, 0x5250, 0x524f, 0x3f5f, 0x3139, 0x315e, 0x5251, + 0x5252, 0x2e74, 0x3837, 0xa358, 0x5253, 0xa35a, 0x356e, + /* 0x53C0 */ + 0xa35b, 0x3b32, 0x5254, 0x4b74, 0x3a35, 0x355a, 0x4d27, 0x4150, + 0x483f, 0x3c7d, 0x3d47, 0xa35f, 0x3c68, 0x3c75, 0x3d76, 0xa360, + 0x4840, 0x5257, 0x3143, 0x4151, 0x387d, 0x3845, 0x3667, 0x525b, + 0x4321, 0x427e, 0x362b, 0x3e24, 0x525c, 0x525a, 0x3244, 0x4266, + 0x3c38, 0x3b4b, 0x3126, 0xa362, 0xa363, 0x3370, 0x3966, 0x3b4a, + 0x525d, + /* 0x5400 */ + 0x525e, 0x3549, 0x3346, 0x3967, 0x3548, 0x445f, 0x3125, 0x4631, + 0x4c3e, 0x3921, 0x4d79, 0x4547, 0x387e, 0x2e75, 0x372f, 0x5267, + 0x4f7e, 0x3663, 0x4b4a, 0xa365, 0x485d, 0x2e76, 0xa366, 0x5266, + 0x345e, 0x5261, 0x5262, 0x5264, 0x5265, 0x355b, 0x3f61, 0x4a2d, + 0x5263, 0x525f, 0x3863, + /* 0x5440 */ + 0x5260, 0x4f24, 0xa368, 0x4a72, 0x4468, 0x3862, 0x3970, 0x2e77, + 0x5268, 0x465d, 0xa364, 0x526c, 0xa369, 0xa36a, 0x3c7e, 0x3c76, + 0x2e79, 0xa36b, 0x526f, 0x526d, 0x4c23, 0x2e7a, 0x526a, 0x5273, + 0x526e, 0x5271, 0x3846, 0x4c3f, 0x2e7b, + /* 0x5480 */ + 0x5272, 0x5274, 0x5276, 0x2e7c, 0xa36c, 0x3a70, 0x4f42, 0xa36d, + 0x526b, 0x5269, 0x5275, 0x5270, 0xa36e, 0x2e7d, 0x2e78, 0xa36f, + 0x2e7e, 0x5278, 0x5323, 0x527a, 0xa370, 0x527e, 0x2f21, 0x5321, + 0x527b, 0xa371, 0xa372, 0x533e, 0x3a69, 0x3331, 0xa373, 0x5279, + 0xa374, 0x5325, 0x3076, 0x5324, 0xa375, + /* 0x54C0 */ + 0x3025, 0x494a, 0x5322, 0xa376, 0x527c, 0x2f22, 0x5277, 0x527d, + 0x3a48, 0x5326, 0x3077, 0x532f, 0x5327, 0x5328, 0x3e25, 0x4b69, + 0xa378, 0x532d, 0x532c, 0xa379, 0xa37a, 0x452f, 0xa37b, 0x532e, + 0x532b, 0x2f23, + /* 0x5500 */ + 0xa37c, 0xa37d, 0x3134, 0x3a36, 0x3f30, 0xa37e, 0x2f24, 0x5329, + 0x4562, 0x532a, 0x3022, 0x2f25, 0x5334, 0x4d23, 0x3e27, 0x533a, + 0x2f26, 0x5339, 0x5330, 0xa421, 0x4243, + /* 0x5540 */ + 0x5331, 0xa422, 0x426f, 0x5336, 0x3e26, 0xa424, 0xa425, 0x5333, + 0x4c64, 0x2f27, 0x373c, 0x5337, 0x5338, 0x5335, 0x533b, 0x2f28, + 0xa427, 0xa428, 0x5332, 0xa429, 0x5341, 0x5346, 0xa42b, 0x5342, + /* 0x5580 */ + 0x533d, 0x2f29, 0xa42c, 0x5347, 0x4131, 0x2f2a, 0x5349, 0xa42d, + 0x3922, 0x533f, 0x437d, 0x2f2b, 0xa42e, 0x5343, 0x533c, 0x342d, + 0x346e, 0x3365, 0x5344, 0x5340, 0x3776, 0x534a, 0x5348, 0x4153, + 0x354a, 0x362c, 0x2f2d, 0x5345, 0x3674, 0x3144, 0xa433, + /* 0x55C0 */ + 0x534e, 0x534c, 0x5427, 0xa434, 0xa435, 0x2f2e, 0xa436, 0xa430, + 0x5351, 0x534b, 0x534f, 0xa437, 0x534d, 0xa439, 0x3b4c, 0x5350, + 0xa43b, 0x5353, 0x5358, 0x5356, 0x5355, + /* 0x5600 */ + 0x4332, 0xa43e, 0x2f30, 0x3245, 0x2f31, 0xa43f, 0x5352, 0x5354, + 0x3e28, 0x3133, 0x5357, 0xa43c, 0x325e, 0x5362, 0xa440, 0x3e7c, + 0x535e, 0x535c, 0x535d, 0xa441, 0x535f, 0x2f32, 0xa443, 0xa444, + /* 0x5640 */ + 0xa445, 0x313d, 0xa446, 0x2f33, 0x4139, 0x5359, 0x535a, 0x7427, + 0x337a, 0xa447, 0xa448, 0x5361, 0x2f35, 0x346f, 0x5364, 0x5360, + 0x5363, 0xa449, 0x2f37, 0x2f38, 0x2f39, 0x4a2e, 0x2f34, 0x4655, + 0x4838, + /* 0x5680 */ + 0x5366, 0x5365, 0x3345, 0xa44b, 0x5367, 0xa44c, 0x536a, 0x5369, + 0xa44d, 0x2f3a, 0xa44e, 0xa44f, 0x2f3b, 0x5368, 0x4739, 0x536b, + 0xa450, 0x2f3c, 0x2f3d, 0xa451, 0x536c, 0xa452, 0x2f3e, 0x536e, + 0x536d, 0x5370, + /* 0x56C0 */ + 0x5373, 0x5371, 0x536f, 0x5372, 0xa453, 0x5374, 0x2f3f, 0x2f40, + 0xa454, 0x5375, 0x5376, 0x5377, 0x5378, 0x5145, 0x3c7c, 0x3b4d, + 0x3273, 0xa455, 0x3078, 0x4344, 0xa456, 0x5379, 0x3a24, 0x304f, + 0x3f5e, 0xa457, 0xa458, 0x537a, 0x3847, 0x3971, 0x537c, + /* 0x5700 */ + 0x537b, 0x4a60, 0x537d, 0x5421, 0x537e, 0x2f41, 0x5422, 0x5423, + 0x3777, 0x3160, 0x5424, 0xa45a, 0x5426, 0x5425, 0x5428, 0x455a, + 0x2f43, 0xa45b, 0x5429, 0x3035, 0x3a5f, 0xa45d, 0x373d, 0x2f44, + 0x434f, 0x2f45, 0x2f46, 0x542a, 0x542b, 0x542d, + /* 0x5740 */ + 0x542e, 0x3a64, 0xa45f, 0xa460, 0x3651, 0x4b37, 0xa461, 0xa462, + 0x542c, 0x542f, 0x3a41, 0x3923, 0x5433, 0x3a25, 0x4333, 0xa464, + 0x5430, 0x445a, 0xa465, 0x2f47, 0xa466, 0xa467, 0xa468, 0x2f48, + 0xa469, 0x2f49, 0x5434, + /* 0x5780 */ + 0x3f62, 0x5432, 0x5435, 0x373f, 0x5436, 0xa46d, 0x2f4a, 0xa46e, + 0xa46f, 0x5437, 0x3924, 0x3340, 0x5439, 0xa470, 0x543a, 0xa46c, + 0x543b, 0x5438, 0x2f4d, + /* 0x57C0 */ + 0x5431, 0x543c, 0x543d, 0x2f4e, 0x2f4f, 0x4b64, 0xa473, 0x3e6b, + 0x2f50, 0x543f, 0x5440, 0x543e, 0x5442, 0xa471, 0x4738, 0xa476, + 0x3068, 0x4956, 0x5443, 0x2f51, 0xa477, 0x2f52, 0xa478, 0x3e7d, + 0x2f53, 0x2f54, 0x3c39, 0xa47a, 0x475d, 0x3470, 0xa47b, 0x3a6b, + 0xa47c, 0x2f55, + /* 0x5800 */ + 0x4b59, 0x4632, 0xa47d, 0x3778, 0x424f, 0x2f56, 0x5441, 0x5444, + 0x4244, 0x5445, 0x5446, 0xa47e, 0xa521, 0x5448, 0x4469, 0xa522, + 0x342e, 0x7421, 0x3161, 0x4a73, 0xa523, 0x3e6c, 0x4548, 0xa524, + 0x3a66, 0x544e, + /* 0x5840 */ + 0x4a3d, 0x4e5d, 0xa526, 0x3274, 0x544a, 0xa527, 0x413a, 0x544d, + 0x4563, 0x4549, 0x4564, 0x4839, 0x444d, 0x3a49, 0x2f58, 0x5449, + 0x2f59, 0xa528, 0x3176, 0x4536, 0x544b, 0x5447, 0x3f50, 0x544f, + 0x2f5b, 0x3d4e, + /* 0x5880 */ + 0x362d, 0x5450, 0x2f5c, 0xa529, 0xa52a, 0xa52b, 0xa52c, 0xa52d, + 0x4a68, 0xa52e, 0x417d, 0x4446, 0xa52f, 0x2f5d, 0x5452, 0x4b4f, + 0x2f5f, 0xa530, 0x5453, 0x5458, 0xa531, 0x4a2f, 0x5457, 0x5451, + 0x5454, 0x5456, 0x3a26, + /* 0x58C0 */ + 0x4a49, 0xa533, 0x5459, 0x4345, 0x3275, 0x3e6d, 0xa534, 0x2f62, + 0x545b, 0x2f61, 0x545a, 0x2f63, 0x3968, 0x545c, 0x545e, 0x545d, + 0x2f64, 0x5460, 0x5455, 0x5462, 0x2f65, 0xa535, 0x5461, 0x545f, + 0x2f66, 0x3b4e, 0x3f51, 0x4154, 0x5463, 0x403c, 0x306d, 0x4764, + 0xa536, 0xa537, 0x445b, 0x5465, 0x5464, 0x5466, 0x5467, 0x5468, + /* 0x5900 */ + 0x5469, 0xa538, 0xa539, 0x4a51, 0x546a, 0xa53a, 0x2f67, 0xa53b, + 0x3246, 0x546b, 0xa53c, 0x4d3c, 0x3330, 0x5249, 0x3d48, 0x423f, + 0x546c, 0x4c6b, 0x4c34, 0xa53d, 0x546e, 0x4267, 0x4537, 0x4240, + 0x4957, 0x546f, 0x5470, 0x317b, 0x3c3a, 0x5471, 0x3050, 0x5472, + 0xa540, 0x5473, + /* 0x5940 */ + 0x3162, 0xa542, 0x3471, 0x4660, 0x4a74, 0x5477, 0x4155, 0x5476, + 0x3740, 0x4b5b, 0x5475, 0x4565, 0x5479, 0x5478, 0xa545, 0x2f69, + 0xa546, 0x547b, 0x547a, 0x317c, 0x547c, 0x3e29, 0x547e, 0x4325, + 0x547d, 0x2f6a, 0x4a33, 0x3d77, 0x455b, 0xa548, 0xa549, 0x5521, + 0xa54a, 0x3925, + /* 0x5980 */ + 0x5522, 0x4721, 0x485e, 0x4c51, 0x4725, 0x2f6b, 0x552b, 0x2f6c, + 0x3538, 0x4d45, 0x4c2f, 0x562c, 0x5523, 0xa54b, 0x5526, 0x2f6d, + 0x4245, 0x4b38, 0x454a, 0xa54c, 0x5527, 0x4b65, 0x3a4a, 0xa54d, + 0x3e2a, + /* 0x59C0 */ + 0x2f6e, 0x5528, 0xa54e, 0x3b50, 0x3b4f, 0xa54f, 0x3039, 0x3848, + 0x2f6f, 0x402b, 0x3051, 0x552c, 0x552d, 0x552a, 0x2f70, 0xa550, + 0xa551, 0xa552, 0x3138, 0x342f, 0xa553, 0x5529, 0x4c45, 0x4931, + 0xa554, 0x3028, 0x7e7a, 0x3079, 0x3b51, + /* 0x5A00 */ + 0x3052, 0x3023, 0x5532, 0xa558, 0xa559, 0x5530, 0x2f71, 0xa55a, + 0x4c3c, 0x5533, 0x5531, 0x552f, 0x3f31, 0x2f72, 0x552e, 0xa55b, + 0x4a5a, 0xa55c, 0x3864, 0x5537, 0x5538, 0x3e2b, + /* 0x5A40 */ + 0x5534, 0x4f2c, 0x474c, 0x5536, 0xa55d, 0x3a27, 0x5539, 0xa55e, + 0x4958, 0x2f73, 0x553a, 0x5535, 0x2f74, 0x2f75, 0xa55f, 0x2f76, + 0x4c3b, + /* 0x5A80 */ + 0x2f77, 0xa560, 0x475e, 0x553b, 0x4932, 0xa561, 0x2f78, 0xa562, + 0xa563, 0xa564, 0x2f79, 0xa565, 0xa566, 0xa567, 0xa568, 0x553c, + 0x5540, 0x553d, 0xa569, + /* 0x5AC0 */ + 0x3247, 0x553f, 0x2f7a, 0x3c3b, 0x553e, 0x3779, 0x554c, 0x5545, + 0x5542, 0xa56a, 0xa56b, 0xa56c, 0x4364, 0x5541, 0xa56d, 0x5543, + 0x5544, 0xa56f, 0xa56e, 0xa570, 0x5546, 0x5547, + /* 0x5B00 */ + 0xa571, 0xa572, 0x3472, 0x5549, 0x5548, 0x554a, 0xa573, 0x2f7c, + 0x3e6e, 0x2f7d, 0x554d, 0x445c, 0xa575, 0x3145, 0x554b, 0xa574, + 0x554e, 0x554f, + /* 0x5B40 */ + 0x5552, 0x4f55, 0x5550, 0x5551, 0xa576, 0x3b52, 0x5553, 0xa577, + 0x3926, 0x5554, 0x4f56, 0x3b7a, 0x4238, 0x5555, 0x5556, 0x3b5a, + 0x3927, 0x4c52, 0x3528, 0x3849, 0x5557, 0x3358, 0xa578, 0x5558, + 0x4239, 0xa579, 0x5559, 0x5623, 0x555a, 0x555b, 0x555c, 0x555e, + 0xa57a, 0x4f57, 0xa57b, + /* 0x5B80 */ + 0x555f, 0xa57c, 0x5560, 0xa57d, 0x4270, 0x3127, 0x3c69, 0x3042, + 0x4157, 0x3430, 0x3c35, 0x3928, 0x4f58, 0x4566, 0xa821, 0x3d21, + 0x3431, 0x4368, 0x446a, 0x3038, 0x3539, 0x4a75, 0x3c42, 0x3552, + 0x406b, 0x3c3c, 0x4d28, 0x5561, 0xa822, 0x355c, 0x3a4b, 0x3332, + 0x3163, 0x3e2c, 0x3248, 0x5562, 0x4d46, 0x3d49, + /* 0x5BC0 */ + 0xa824, 0x3c64, 0x5563, 0x3473, 0x4652, 0x4c29, 0x5564, 0x5565, + 0x4959, 0xa826, 0x5567, 0x3428, 0x3677, 0x5566, 0xa827, 0x4f59, + 0x3432, 0x3f32, 0x556b, 0x3b21, 0x3249, 0x556a, 0x5568, 0x556c, + 0x5569, 0x472b, 0x5c4d, 0x3f33, 0x556d, 0x4f5a, 0x4e40, 0x556e, + 0xa82a, 0x5570, 0x437e, 0x556f, 0x4023, 0x3b7b, 0xa82b, 0x4250, + 0x3c77, + /* 0x5C00 */ + 0x4975, 0x406c, 0xa82d, 0x3c4d, 0x5571, 0x3e2d, 0x5572, 0x5573, + 0x3053, 0x423a, 0x3f52, 0x5574, 0x4633, 0x3e2e, 0x3e2f, 0x4f5b, + 0x5575, 0x406d, 0x3e30, 0x4f5c, 0x5576, 0x5577, 0x4f5d, 0x4c60, + 0x5578, 0xa82e, 0x4f5e, 0x3646, 0xa82f, 0x3d22, 0x5579, 0x557a, + 0x3c5c, 0x3f2c, 0x4674, 0x3f54, 0x4878, 0x4722, + /* 0x5C40 */ + 0x3649, 0x557b, 0x356f, 0x557c, 0x367e, 0x464f, 0x3230, 0x3b53, + 0x557d, 0x5622, 0x5621, 0x367d, 0x557e, 0x4538, 0x7e7b, 0x4230, + 0xa831, 0x454b, 0x3c48, 0x4f60, 0xa832, 0x4158, 0x4d7a, 0xa833, + 0xa834, 0xa835, 0x5624, 0x5625, 0x4656, 0xa836, 0x3b33, 0x5627, + 0x5628, 0x4f64, 0xa839, + /* 0x5C80 */ + 0xa83c, 0xa83d, 0x5629, 0x4f65, 0x3474, 0x562a, 0x562b, 0x4f66, + 0xa841, 0x322c, 0xa842, 0x4f67, 0xa843, 0xa844, 0x413b, 0x3464, + 0x4f68, 0x562d, 0x4c28, 0xa846, 0x4252, 0x3359, 0xa847, 0x562f, + 0x5631, 0x345f, 0x4f69, 0x562e, 0x5630, 0x5633, + /* 0x5CC0 */ + 0x5632, 0x5634, 0xa849, 0x4f6a, 0x4f6b, 0x4f6c, 0x5635, 0x463d, + 0x362e, 0x3265, 0x5636, 0x563b, 0x5639, 0x4a77, 0x4a76, 0x4f6d, + 0x4567, 0x5638, 0x3d54, 0x5637, + /* 0x5D00 */ + 0xa84c, 0x3f72, 0x563c, 0x4f70, 0x3a6a, 0xa84d, 0x5642, 0x5643, + 0x563d, 0x3333, 0x563e, 0x5647, 0x5646, 0x5645, 0x5641, 0xa84f, + 0x5640, 0xa850, 0x5644, 0xa851, 0xa852, 0x4f71, 0x4a78, 0xa84e, + 0xa853, 0xa854, + /* 0x5D40 */ + 0xa855, 0x4f73, 0x4f74, 0x4f76, 0x564b, 0x5648, 0x564a, 0x4d72, + 0x5649, 0x4f75, 0x563f, 0xa857, 0x3f73, 0xa858, 0x564c, 0x4f77, + 0x3a37, 0xa85a, 0x564d, 0x564e, + /* 0x5D80 */ + 0x4f78, 0x5651, 0x5650, 0x564f, 0xa85d, 0x4568, 0x563a, 0x5657, + 0xa85f, 0xa860, 0xa861, 0xa862, 0x5653, 0x4f79, 0x5652, 0x4f7a, + 0x4f7b, 0x5654, 0x5655, 0xa863, 0xa864, 0xa865, 0x5658, 0x4f7c, + 0xa867, 0x4e66, 0x5659, 0x5656, + /* 0x5DC0 */ + 0x565a, 0x4f7d, 0x3460, 0x565b, 0xa868, 0x565d, 0x565c, 0x565e, + 0xa869, 0xa86a, 0x565f, 0x406e, 0x3d23, 0xa86b, 0x3d64, 0x7428, + 0x4163, 0xa86d, 0x3929, 0x3a38, 0x392a, 0x3570, 0xa86e, 0x5660, + 0x3a39, 0x384a, 0x5661, 0x4c26, 0x4743, 0x5662, 0x392b, 0x342c, + 0x4327, 0x3652, + /* 0x5E00 */ + 0xa870, 0x3b54, 0x495b, 0x4841, 0x5663, 0x3475, 0x5666, 0xa872, + 0x7429, 0xa873, 0x4421, 0x742a, 0x5665, 0x5664, 0x5667, 0x446b, + 0xa875, 0x3f63, 0x3b55, 0x404a, 0xa876, 0x4253, 0x3522, 0x4422, + 0x5668, 0x5669, 0x3e6f, 0x4b39, 0xa877, + /* 0x5E40 */ + 0x566c, 0x566b, 0x566a, 0x497d, 0x5673, 0xa878, 0x4b5a, 0x566d, + 0x566f, 0x4b6b, 0xa87a, 0x566e, 0x742b, 0x742c, 0x5670, 0x4828, + 0x5671, 0x4a3e, 0x5672, 0xa87c, 0xa87d, 0xa87e, 0xac21, 0x3433, + 0x4a3f, 0x472f, 0x5674, 0x5675, 0x7e7c, 0x392c, 0x3434, 0x5676, + 0x3838, 0x4d44, 0x4d29, 0x3476, 0x5678, + /* 0x5E80 */ + 0x4423, 0x392d, 0x3e31, 0x485f, 0x3e32, 0x3d78, 0x446c, 0x4a79, + 0x4539, 0x392e, 0x495c, 0x5679, 0xac23, 0x4559, 0x3a42, 0xac24, + 0x384b, 0xac25, 0x446d, 0x3043, 0x3d6e, 0x392f, 0x4d47, 0xac26, + 0x742d, 0xac27, + /* 0x5EC0 */ + 0x567a, 0x567b, 0x4751, 0xac28, 0x567c, 0x4e77, 0x4f2d, 0x742f, + 0x567e, 0x567d, 0xac29, 0x3347, 0x5721, 0xac2a, 0x5724, 0x5725, + 0x5723, 0x4940, 0x3e33, 0x5727, 0x5726, 0x5722, 0x5728, 0x5729, + 0x572a, 0x572d, 0x572b, 0x572c, 0x572e, 0x3164, 0x446e, 0x572f, + 0x7430, 0x377a, 0x3276, 0x4736, 0xac2c, 0x5730, 0x467b, + /* 0x5F00 */ + 0x7431, 0x4a5b, 0x7432, 0x5731, 0x4f2e, 0x7433, 0xac2d, 0x5732, + 0x4a40, 0x5735, 0x5021, 0x5031, 0xac2e, 0x3c30, 0x4675, 0x5736, + 0x355d, 0x4424, 0x307a, 0x5737, 0x4a26, 0x3930, 0x4350, 0xac2f, + 0x7434, 0xac31, 0x446f, 0x7435, 0x4c6f, 0x3839, 0x384c, 0x5738, + 0x5739, 0x573f, 0x3c65, 0x7436, 0x4425, 0x7437, 0x362f, 0x573a, + 0x492b, 0x7438, 0x4346, + /* 0x5F40 */ + 0x7439, 0x573b, 0x743a, 0xac32, 0x573c, 0x3630, 0x573d, 0x573e, + 0x5740, 0x4576, 0x743b, 0x5741, 0x5742, 0x743c, 0x5743, 0x5734, + 0x5733, 0x5744, 0x3741, 0xac33, 0x743d, 0x4927, 0x743e, 0x3a4c, + 0x4937, 0x4426, 0x494b, 0x5745, 0x3e34, 0x3146, 0xac34, 0x5746, + 0x5747, 0x4c72, 0x4860, 0x743f, 0xac35, 0x574a, + /* 0x5F80 */ + 0x317d, 0x402c, 0x5749, 0x5748, 0x3742, 0x4254, 0x574e, 0x574c, + 0x7440, 0x574b, 0x4e27, 0x3865, 0xac36, 0x3d79, 0x574d, 0x454c, + 0x3d3e, 0x4640, 0x5751, 0x5750, 0x7441, 0x574f, 0x5752, 0x3866, + 0xac37, 0xac38, 0x7442, 0x5753, 0x497c, 0x3d5b, 0x5754, 0x4879, + 0x7443, 0x4641, 0x4427, 0x7444, 0x7445, 0xac39, 0x4530, 0x5755, + 0x352b, + /* 0x5FC0 */ + 0x3f34, 0xac3a, 0x492c, 0xac3c, 0x7446, 0xac3d, 0x3477, 0x4726, + 0xac3e, 0xac3f, 0xac40, 0x5756, 0x3b56, 0x4b3a, 0x4b3b, 0x317e, + 0x575b, 0x7447, 0x4369, 0x7448, 0xac41, 0x5758, 0x7449, 0x3277, + 0xac42, 0xac43, 0x582d, 0x575a, 0xac44, 0x4730, 0x5759, 0x5757, + 0xac45, 0x397a, 0x575d, + /* 0x6000 */ + 0x744a, 0x5763, 0x5769, 0x5761, 0x455c, 0x744b, 0x5766, 0x495d, + 0xac47, 0x744c, 0x5760, 0x5765, 0x4e67, 0x3b57, 0x4255, 0x575e, + 0xac48, 0xac49, 0x355e, 0x5768, 0x402d, 0x3165, 0x5762, 0x3278, + 0x5767, 0x3631, 0x5764, 0x744d, 0x744e, 0x576a, + /* 0x6040 */ + 0x576c, 0x5776, 0x5774, 0x5771, 0x744f, 0x5770, 0x4e78, 0xac4b, + 0x5772, 0x3632, 0x3931, 0x3d7a, 0x5779, 0x576b, 0x576f, 0x575f, + 0x327a, 0x5773, 0x5775, 0x4351, 0x3a28, 0x3238, 0x576d, 0x5778, + 0x5777, 0x3633, 0x4229, 0x3366, 0x3743, 0x576e, 0xac4c, + /* 0x6080 */ + 0x577a, 0x577d, 0x5821, 0x3c3d, 0xac4d, 0x5827, 0x4470, 0x577b, + 0x5825, 0x3279, 0xac4e, 0x5823, 0x5824, 0x577e, 0x5822, 0x7451, + 0x7452, 0x3867, 0x4d2a, 0x3435, 0x3159, 0x5826, 0xac4f, 0x473a, + 0x302d, 0xac51, 0xac52, 0x4861, 0x575c, 0x582c, 0x5830, 0x4c65, + 0x5829, 0x4569, 0x582e, 0xac53, + /* 0x60C0 */ + 0x3e70, 0x582f, 0x4657, 0xac54, 0x7453, 0x4f47, 0x582b, 0x7454, + 0x7455, 0x5831, 0xac55, 0x397b, 0xac56, 0x404b, 0x7456, 0x3054, + 0x582a, 0x5828, 0x415a, 0x577c, 0x3b34, 0xac57, 0x4246, 0x583d, + 0xac58, 0x415b, 0x5838, 0xac59, 0x5835, 0x5836, 0x7457, 0x3c66, + 0x5839, 0x583c, + /* 0x6100 */ + 0x5837, 0x3d25, 0x583a, 0x5834, 0x4c7c, 0x4c7b, 0x583e, 0x583f, + 0x3055, 0xac5a, 0xac5b, 0xac5c, 0x5833, 0xac5d, 0x3672, 0x3026, + 0x7458, 0xac5e, 0x3436, 0x583b, 0x5843, 0x5842, 0x7459, 0x5847, + 0x745a, 0x5848, 0x745b, 0xac5f, 0x5846, 0x5849, 0x5841, 0x5845, + /* 0x6140 */ + 0xac61, 0x584a, 0x584b, 0xac62, 0x5840, 0x3b7c, 0x5844, 0x4256, + 0x3932, 0x5832, 0x3f35, 0x5858, 0x4a69, 0x584e, 0x584f, 0x5850, + 0x5857, 0x5856, 0xac63, 0x4b7d, 0x3437, 0x5854, 0x3745, 0x3334, + 0x5851, 0x4e38, 0x5853, 0x3056, 0x5855, 0x584c, 0x5852, 0x5859, + 0x3744, 0x584d, 0xac64, 0x4d5d, + /* 0x6180 */ + 0x4d2b, 0x585c, 0x5860, 0x745d, 0x417e, 0x4e79, 0x5861, 0xac66, + 0xac67, 0x585e, 0x585b, 0xac68, 0xac69, 0x585a, 0x585f, 0x4a30, + 0xac6a, 0x4634, 0xac6b, 0x3746, 0x5862, 0x585d, 0xac6c, 0x5863, + 0x377b, 0x3231, 0x7460, 0x586b, 0x745f, 0x3438, + /* 0x61C0 */ + 0x5869, 0x586a, 0x3a29, 0x5868, 0x5866, 0x5865, 0x586c, 0x5864, + 0x586e, 0x327b, 0xac6e, 0xac6f, 0xac70, 0x5870, 0x586f, 0x4428, + 0x5873, 0xac71, 0x5871, 0x5867, 0x377c, 0x5872, 0x5876, 0x5875, + 0x5877, 0x5874, + /* 0x6200 */ + 0x5878, 0x5879, 0x587a, 0x4a6a, 0x587c, 0x587b, 0x3d3f, 0x402e, + 0x3266, 0x327c, 0x587d, 0xac73, 0x303f, 0x404c, 0x587e, 0x6c43, + 0x5921, 0x3761, 0x5922, 0x7462, 0xac74, 0x406f, 0xac75, 0x5923, + 0x5924, 0x353a, 0x5925, 0x5926, 0x5927, 0x4257, 0x384d, 0x4c61, + 0x7463, 0x4b3c, + /* 0x6240 */ + 0x3d6a, 0x5928, 0x7464, 0xac76, 0x4070, 0x6e3d, 0x4862, 0x3c6a, + 0xac77, 0x3a4d, 0x5929, 0xac78, 0xac79, 0x4247, 0x4a27, 0x7465, + 0x4271, 0x7466, 0x592c, 0x592a, 0x592d, 0xac7a, 0x592b, 0xac7b, + 0x592e, 0xac7d, 0x4a31, 0x7467, 0x3037, 0xac7e, 0x495e, 0x4863, + 0xac7c, 0x592f, 0x5932, 0x3e35, + /* 0x6280 */ + 0x353b, 0x5930, 0x5937, 0x3e36, 0x7468, 0x5931, 0x4744, 0x4d5e, + 0x5933, 0x5934, 0x5938, 0x456a, 0x5935, 0x3933, 0x405e, 0xad21, + 0x5946, 0x4834, 0x4272, 0xad22, 0x4864, 0x5a2d, 0x4a7a, 0x4471, + 0x4b75, 0x593b, 0x3221, 0x436a, + /* 0x62C0 */ + 0x5944, 0x7469, 0x4334, 0x593e, 0x5945, 0x5940, 0x5947, 0x5943, + 0x5942, 0x476f, 0x593c, 0x327d, 0x593a, 0x3571, 0x4273, 0x5936, + 0xad23, 0x746a, 0x5939, 0x3934, 0x405b, 0x3e37, 0x5941, 0x4752, + 0x3572, 0x3348, 0x3367, 0x3f21, 0x5949, 0x594e, 0x594a, 0x377d, + 0x594f, 0x3b22, 0x3969, 0x746b, 0xad25, 0x3d26, 0x593d, + /* 0x6300 */ + 0x3b7d, 0x594c, 0xad26, 0x3b58, 0x594d, 0x3044, 0x746c, 0x5948, + 0xad27, 0xad28, 0x4429, 0x746d, 0x3573, 0x3634, 0x594b, 0x3027, + 0x3a43, 0x3f36, 0xad2b, 0xad2c, 0x746e, 0x4472, 0xad2d, 0xad2e, + 0x4854, 0x5951, 0x415e, + /* 0x6340 */ + 0xad2f, 0x746f, 0xad30, 0x422a, 0x3b2b, 0x5952, 0xad31, 0x5954, + 0x5950, 0x4a61, 0x443d, 0xad33, 0x415c, 0x7470, 0x4a7b, 0x3c4e, + 0x5960, 0x595f, 0xad36, 0x3f78, 0x377e, 0x5959, 0x3e39, 0x4668, + 0x4731, 0x7471, + /* 0x6380 */ + 0x5957, 0x415d, 0xad37, 0x3c78, 0x595c, 0x3e38, 0x5956, 0x595b, + 0x4753, 0xad3a, 0x5955, 0x3721, 0xad38, 0x335d, 0x595d, 0x4e2b, + 0x3a4e, 0x4335, 0x595a, 0x405c, 0x3935, 0x3f64, 0x3166, 0x413c, + 0x5958, 0x3545, 0x3747, 0x444f, 0x595e, 0x415f, 0xad3b, 0x5961, + /* 0x63C0 */ + 0x5963, 0x4237, 0x5969, 0x5964, 0x5966, 0x4941, 0x4473, 0x5967, + 0xad3d, 0xad3e, 0x4d2c, 0x4d48, 0x3439, 0xad3f, 0xad40, 0x302e, + 0x5965, 0x7472, 0x5962, 0xad41, 0xad42, 0x7473, 0x3478, 0xad43, + 0x3167, 0x7474, 0x5968, 0xad3c, 0x4d49, + /* 0x6400 */ + 0x596c, 0xad44, 0x423b, 0x5973, 0x7475, 0x596d, 0x7476, 0x596a, + 0x5971, 0x5953, 0xad45, 0x7477, 0xad46, 0x596e, 0x5972, 0xad47, + 0x4842, 0x456b, 0xad48, 0x596b, 0x596f, 0x3748, 0x3a71, + /* 0x6440 */ + 0x405d, 0x5977, 0x7479, 0x4526, 0xad49, 0xad4a, 0xad4b, 0x747a, + 0x5974, 0x4b60, 0x747b, 0x5975, 0xad4c, 0x5976, 0x4c4e, 0x7478, + 0x4022, 0xad4d, + /* 0x6480 */ + 0x3762, 0xad4e, 0x597d, 0xad4f, 0x3b35, 0x597a, 0x5979, 0x4732, + 0xad50, 0x4635, 0xad51, 0x4531, 0x597b, 0x597c, 0x496f, 0x4745, + 0x3b23, 0x4071, 0x4b50, 0x3349, 0x5a25, 0x597e, 0x747d, 0x747e, + /* 0x64C0 */ + 0x4d4a, 0x5a27, 0x7521, 0x5a23, 0x5a24, 0x7522, 0xad52, 0xad53, + 0x4160, 0x747c, 0x7523, 0x5a22, 0x593f, 0xad54, 0xad55, 0x5a26, + 0x5a21, 0x5a2b, 0x5a2c, 0x4527, 0x5a2e, 0xad57, 0xad58, 0x3b24, + 0x5a29, 0x353c, 0x5a2f, 0x5a28, 0x5a33, 0x5a32, 0x5a31, 0x7524, + 0x5a34, 0x7525, 0x5a36, 0x3e71, 0xad59, + /* 0x6500 */ + 0x5a35, 0xad5a, 0x5a39, 0xad5c, 0xad5d, 0xad5e, 0x5a37, 0x5a38, + 0x5970, 0xad60, 0x7526, 0x5a3b, 0x5a3a, 0x7527, 0x5978, 0x5a3c, + 0x5a30, 0x3b59, 0xad61, 0x5a3d, 0x5a3e, 0x5a40, 0x5a3f, 0x5a41, + 0x327e, 0x3936, 0x4a7c, 0x402f, + /* 0x6540 */ + 0xad62, 0x384e, 0x5a43, 0x5a46, 0x4952, 0x355f, 0xad63, 0x5a45, + 0x5a44, 0x4754, 0x5a47, 0x3635, 0x5a49, 0x5a48, 0x343a, 0x3b36, + 0x4658, 0x7529, 0xad64, 0x3749, 0x3f74, 0x5a4a, 0x4030, 0x4528, + 0x495f, 0x5a4b, 0xad65, + /* 0x6580 */ + 0xad66, 0x5a4c, 0x5a4d, 0xad67, 0xad68, 0x4a38, 0x555d, 0x4046, + 0xad69, 0x494c, 0x3a58, 0x4865, 0x4843, 0x454d, 0x4e41, 0x5a4f, + 0x3c50, 0x752a, 0x5a50, 0x3036, 0x3654, 0x404d, 0x4960, 0x5a51, + 0x3b42, 0x4347, 0x3b5b, 0x3f37, 0xad6a, 0xad6b, 0x5a52, 0xad6c, + 0x4a7d, 0x3177, 0x3b5c, 0xad6d, + /* 0x65C0 */ + 0x5a55, 0xad6e, 0x5a53, 0x5a56, 0x4e39, 0x5a54, 0xad6f, 0x407b, + 0x5a57, 0x4232, 0x5a58, 0xad70, 0x347a, 0x5a5a, 0x5a59, 0x5a5b, + 0x5a5c, 0x347b, 0x467c, 0x4336, 0x356c, 0x3b5d, 0x4161, 0x3d5c, + 0x3030, 0x5a5d, 0xad72, 0xad73, 0x3222, 0x5a61, 0xad74, + /* 0x6600 */ + 0x752c, 0x3937, 0x5a60, 0xad75, 0x3a2b, 0x3e3a, 0xad76, 0x752d, + 0x5a5f, 0x3e3b, 0x4c40, 0x3a2a, 0x3057, 0x404e, 0x752e, 0x5a66, + 0x752f, 0x4031, 0x3147, 0xad77, 0x7531, 0x7532, 0x3d55, 0x4b66, + 0x3a72, 0xad78, 0x7533, 0x3e3c, 0x4027, 0x7534, 0x7535, 0x7536, + 0x5a65, 0x5a63, 0x5a64, 0x7530, 0x436b, 0x5b26, + /* 0x6640 */ + 0x5a6a, 0x3b7e, 0x3938, 0x5a68, 0xad79, 0x7538, 0x5a69, 0x3f38, + 0x7539, 0xad7b, 0x5a67, 0xad7a, 0x3b2f, 0xad7e, 0x753b, 0x753c, + 0xae21, 0x5a6c, 0x5a6b, 0x5a70, 0x753d, 0x5a71, 0xae22, 0x5a6d, + 0x753e, 0x3322, 0x5a6e, 0x5a6f, 0x4855, 0xae25, 0xae26, 0xae27, + 0xae28, 0x4961, 0x374a, 0x5a72, 0x753f, 0x4032, 0x3e3d, 0x7540, + 0x7541, 0x4352, 0xae29, + /* 0x6680 */ + 0xae2a, 0x3647, 0x5a73, 0x5a77, 0x324b, 0x5a74, 0x5a76, 0x7542, + 0x5a75, 0xae2b, 0x3d6b, 0xae2c, 0x4348, 0x3045, 0x5a78, 0xae2d, + 0x5a79, 0x7544, 0x442a, 0x4e71, 0x3b43, 0xae2f, 0x4a6b, 0xae30, + 0x7545, 0x4b3d, 0xae31, 0x5b22, 0x5a7b, 0x7546, 0x5a7e, 0x5a7d, + 0xae33, + /* 0x66C0 */ + 0x5a7a, 0x5b21, 0x7547, 0x465e, 0x7548, 0x5a7c, 0x5b23, 0x3d6c, + 0x5b24, 0x754a, 0x4d4b, 0x4778, 0x5b25, 0x5b27, 0x754b, 0x5b28, + 0xae35, 0x5b29, 0x364a, 0x3148, 0x3939, 0x5b2a, 0x5b2b, 0x3d71, + 0x4162, 0x754c, 0x7537, 0x5258, 0x413e, 0x413d, 0x4258, + /* 0x6700 */ + 0x3a47, 0xae37, 0x5072, 0xae38, 0x376e, 0x4d2d, 0x4a7e, 0x497e, + 0x5b2c, 0xae39, 0x754d, 0x3a73, 0x443f, 0x5b2d, 0x4f2f, 0xae3b, + 0x4b3e, 0x442b, 0x5b2e, 0x347c, 0x5b2f, 0x5b30, 0x4c5a, 0x4c24, + 0x4b76, 0x4b5c, 0x3b25, 0x5b32, 0x3c6b, 0x754f, 0x4b51, 0x5b34, + 0x5b37, 0x5b36, 0x3479, 0x3560, 0x5b33, + /* 0x6740 */ + 0x5b35, 0x5b38, 0x7551, 0x7552, 0x3f79, 0xae3e, 0xae3f, 0x4d7b, + 0x3049, 0x3a60, 0x423c, 0x3c5d, 0xae40, 0x3e73, 0x5b3b, 0x454e, + 0xae41, 0x5b39, 0x422b, 0x5b3a, 0x3e72, 0x4c5d, 0x5b3c, 0x5b3d, + 0x4d68, 0x7550, 0x5b42, 0x393a, 0x4755, 0x5b3f, 0x456c, 0x5a5e, + 0x5a62, 0xae45, 0x354f, 0xae46, 0x4747, 0x7553, 0x5b41, 0x3e3e, + 0x4844, + /* 0x6780 */ + 0x7554, 0x5b47, 0x487a, 0x5b3e, 0x5b44, 0x5b43, 0x404f, 0xae48, + 0x7555, 0x4b6d, 0x4e53, 0x7556, 0x4b67, 0x7557, 0x324c, 0x3b5e, + 0x4f48, 0x5b46, 0x3f75, 0x5b45, 0x5b40, 0x384f, 0xae4c, 0xae4d, + 0x5b4c, 0x5b4a, 0x324d, 0x5b48, 0x5b4e, 0x5b54, 0x7558, + /* 0x67C0 */ + 0x755a, 0x4248, 0xae4e, 0x4a41, 0x5b56, 0xae4f, 0x4922, 0x5b55, + 0x4770, 0x4b3f, 0x343b, 0xae50, 0x4077, 0x3d40, 0x755b, 0x4453, + 0xae51, 0x4d2e, 0xae52, 0x5b51, 0x5b50, 0x5b52, 0x5b4f, 0x5b57, + 0x5b4d, 0x5b4b, 0x5b53, 0x5b49, 0xae53, 0x436c, 0x4c78, 0x3c46, + 0x3a74, 0xae54, 0x7559, 0x3a3a, 0x755c, 0x4b6f, 0x3341, + /* 0x6800 */ + 0x755d, 0x444e, 0x464a, 0x3149, 0xae4b, 0x4072, 0x4034, 0x372a, + 0xae58, 0x755f, 0x5b59, 0xae59, 0x393b, 0x337c, 0x5b5b, 0x3374, + 0x5b61, 0x7560, 0xae5a, 0x7561, 0x5b5e, 0xae5c, 0x4073, 0x334b, + 0x3a2c, 0xae5d, 0x334a, 0x3a4f, 0xae5e, + /* 0x6840 */ + 0x5b5c, 0x3765, 0x374b, 0x456d, 0xae5f, 0xae60, 0x5b5a, 0x3046, + 0xae61, 0xae62, 0x5b5d, 0x5b5f, 0x364d, 0x372c, 0x755e, 0x343c, + 0x354b, 0xae63, 0xae64, 0x5b62, 0x7562, 0x3a79, 0x4b71, 0x3b37, + 0x5b63, 0x4930, 0xae66, 0xae67, 0x7563, 0x5b6f, 0x7564, 0x3233, + 0x5b64, 0xae68, 0xae69, 0x5b75, 0x5b65, + /* 0x6880 */ + 0x4e42, 0xae6a, 0x5b6c, 0x475f, 0x5b74, 0x5b67, 0xae6b, 0x3034, + 0x5b69, 0xae6c, 0x393c, 0xae6e, 0xae6f, 0xae70, 0x5b6b, 0xae71, + 0x5b6a, 0x5b66, 0x5b71, 0x3e3f, 0x7566, 0x7567, 0x546d, 0x3868, + 0x4d7c, 0xae72, 0xae73, 0x5b68, 0x4474, 0x3323, 0x3a2d, 0x7568, + 0x5b60, 0xae74, 0x5b70, 0x3361, 0x5b6e, 0x5b72, 0xae75, 0x456e, + /* 0x68C0 */ + 0xae7a, 0x347e, 0xae7b, 0x5c32, 0x7569, 0x4c49, 0x5b77, 0x347d, + 0xae7c, 0x5b7e, 0xae7d, 0x756a, 0x4b40, 0x5c21, 0x5c23, 0xae7e, + 0x5c27, 0x5b79, 0xaf21, 0x432a, 0x456f, 0x5c2b, 0x5b7c, 0x5c28, + 0xaf22, 0xaf23, 0x5c22, 0x756b, 0xaf24, 0x756c, 0x3f39, 0x5c2c, + 0x756d, 0x756e, 0x4033, 0xaf25, 0x5c2a, 0x343d, 0xae76, 0x756f, + /* 0x6900 */ + 0x4f50, 0x5b76, 0xaf26, 0x5c26, 0x3058, 0xaf27, 0x5b78, 0x7570, + 0x4c3a, 0x5b7d, 0x3f22, 0x4447, 0x5b73, 0x5c25, 0x3f7a, 0x5c2f, + 0x3371, 0x3821, 0x5c31, 0x5b7a, 0x5c30, 0x5c29, 0x5b7b, 0x5c2d, + 0x5c2e, 0x5c3f, 0x464e, 0x7573, 0x5c24, 0x5c3b, 0xaf2b, 0x5c3d, + 0x4458, + /* 0x6940 */ + 0x7574, 0xaf2d, 0x7571, 0x4d4c, 0x4976, 0x5c38, 0x424a, 0x7575, + 0x5c3e, 0x413f, 0x5c35, 0x5c42, 0x5c41, 0x466f, 0x5c40, 0x466a, + 0x7576, 0x7577, 0x7578, 0xaf2e, 0x5c44, 0x5c37, 0xaf2f, 0x3648, + 0x5c3a, 0x3d5d, 0xaf30, 0x4760, 0x5c3c, 0x364b, 0x5c34, 0x5c36, + 0x5c33, 0xaf31, 0x4f30, 0x335a, 0x5c39, 0xaf32, + /* 0x6980 */ + 0x7579, 0x5c43, 0x3335, 0x3a67, 0x315d, 0x5c54, 0xaf33, 0x4f31, + 0x5c57, 0xaf35, 0xaf36, 0x3f3a, 0x5c56, 0x5c55, 0x757b, 0xaf37, + 0x5c52, 0x757c, 0x5c46, 0xaf38, 0x5c63, 0x5c45, 0x5c58, 0xaf39, + 0xaf3a, 0x5c50, 0xaf3b, 0x5c4b, 0x5c48, + /* 0x69C0 */ + 0xaf3c, 0x5c49, 0x5c51, 0x7422, 0x5c4e, 0x393d, 0x4448, 0x4164, + 0x5c4c, 0x757d, 0x5c47, 0xaf3d, 0x5c4a, 0xaf3e, 0x4d4d, 0x4b6a, + 0x5c4f, 0x5c59, 0x7622, 0xaf44, 0x5c61, 0x5c5a, 0x7623, 0x7624, + 0x5c67, 0x5c65, 0xaf45, 0xaf46, 0x5c60, 0xaf47, 0xaf49, 0x7625, + 0x7626, 0x5c5f, 0x4450, 0x4165, 0xaf4a, 0x5c5d, + /* 0x6A00 */ + 0x5c5b, 0x5c62, 0x5c68, 0x4875, 0x5c6e, 0x7627, 0xaf4b, 0x5c69, + 0x5c6c, 0x5c66, 0x7628, 0x4374, 0x4938, 0xaf4c, 0x5c5c, 0xaf4d, + 0x5c64, 0x3e40, 0x4c4f, 0x5c78, 0x5c6b, 0x3822, 0x3223, 0x335f, + 0x5c53, 0xaf41, 0xaf4f, 0xaf50, 0xaf51, 0x3e41, 0x5c70, 0x5c77, + 0x3c79, 0x3372, 0x762a, 0x432e, 0x762b, 0xaf52, + /* 0x6A40 */ + 0x5c6d, 0x762c, 0xaf53, 0x5c72, 0x5c76, 0xaf54, 0x3636, 0xaf56, + 0x762d, 0xaf57, 0x762e, 0x354c, 0x5c74, 0x762f, 0x3521, 0x464b, + 0x5c73, 0xaf58, 0x5c75, 0x7630, 0x5c6f, 0x7631, 0x5c71, 0xaf55, + 0xaf5a, 0x3360, + /* 0x6A80 */ + 0x4349, 0xaf5b, 0x5c7c, 0x7633, 0xaf5c, 0x5c7a, 0x3869, 0x5c79, + 0xaf5e, 0x7634, 0x5d21, 0x5b58, 0x7635, 0x7636, 0xaf5f, 0x5c7b, + 0xaf60, 0x5c7d, 0x5c7e, 0x7637, 0x5d2c, 0xaf62, 0x5d28, 0x5b6d, + 0x5d27, 0x5d26, 0x5d23, 0xaf63, + /* 0x6AC0 */ + 0x5c6a, 0x5d25, 0x5d24, 0xaf64, 0xaf66, 0x5d2a, 0x4f26, 0xaf65, + 0x5d2d, 0x367b, 0xaf67, 0xaf68, 0x5d29, 0x5d2b, 0x7638, 0x7639, + 0x4827, 0x5d2e, 0xaf6b, 0xaf6c, 0xaf6d, 0xaf6e, 0x5d32, 0x5d2f, + 0xaf6f, + /* 0x6B00 */ + 0x4d73, 0x5d30, 0x5c5e, 0xaf71, 0xaf72, 0xaf73, 0xaf74, 0x5d33, + 0x5d34, 0xaf76, 0x763c, 0x3135, 0x763d, 0x5d36, 0x3767, 0x3c21, + 0x3655, 0x3224, 0x763e, 0xaf78, 0x4d5f, 0x763f, 0x5d38, 0x5d37, + 0x5d3a, 0x353d, 0x3656, 0x343e, + /* 0x6B40 */ + 0x5d3d, 0x7640, 0x5d3c, 0x5d3e, 0xaf79, 0x324e, 0x4337, 0x5d3f, + 0x343f, 0x5d41, 0x7641, 0xaf7a, 0x5d40, 0x5d42, 0x5d43, 0x7642, + 0x5d44, 0x3b5f, 0x4035, 0x3a21, 0x7643, 0x4970, 0x7644, 0x4a62, + 0x4f44, 0xaf7b, 0x3b75, 0x3a50, 0x4e72, 0xaf7c, 0x7645, 0x5d45, + 0x5d46, 0xaf7d, 0x3b60, 0x5d47, + /* 0x6B80 */ + 0x5d48, 0xaf7e, 0x7646, 0x5d4a, 0x5d49, 0x4b58, 0x3d5e, 0x3c6c, + 0x3b44, 0x5d4b, 0x5d4d, 0x3f23, 0x5d4c, 0xee21, 0x5d4e, 0x5d4f, + 0x7647, 0x5d50, 0x5d51, 0x7648, 0xee22, 0x5d52, 0x5d54, 0x5d53, + 0x5d55, 0x3225, 0x434a, 0x5d56, 0x3b26, 0x334c, 0x5d57, 0xee24, + 0xee25, 0x4542, + /* 0x6BC0 */ + 0x544c, 0x3523, 0x5d58, 0xee26, 0xee27, 0xee28, 0x5d59, 0x4a6c, + 0x4b68, 0x764a, 0x4647, 0x5d5a, 0x4866, 0x764b, 0x764c, 0x487b, + 0xee29, 0x4c53, 0x5d5b, 0xee2a, 0xee2b, 0x5d5d, 0x5d5c, 0xee2c, + 0x5d5f, 0xee2d, 0x5d5e, 0x764d, + /* 0x6C00 */ + 0xee2e, 0x764e, 0x5d61, 0xee2f, 0xee30, 0x3b61, 0x764f, 0x4c31, + 0x5d62, 0x5d63, 0x3524, 0x5d64, 0x5d66, 0x5d65, 0x7650, 0x3f65, + 0xee31, 0xee32, 0x4939, 0x314a, 0xee33, 0x4845, 0xee35, + /* 0x6C40 */ + 0x4475, 0x3d41, 0x3561, 0xee36, 0x4846, 0x3c2e, 0x5d68, 0x3440, + 0x7651, 0x3178, 0xee37, 0x7652, 0x4672, 0x5d67, 0x393e, 0x4353, + 0x5d69, 0xee4f, 0x5d71, 0x5d6a, 0xee38, 0x4241, 0x3562, 0x5d72, + 0x7654, 0x7655, 0x3768, 0x3525, 0x5d70, + /* 0x6C80 */ + 0x5d6e, 0x5d6b, 0x4d60, 0xee39, 0x7656, 0x7657, 0x4440, 0xee3a, + 0x4659, 0x5d6c, 0x5d74, 0x5d73, 0x3723, 0xee3c, 0xee3d, 0x322d, + 0xee3e, 0x7658, 0x3a3b, 0x5d6d, 0x5d6f, 0x7659, 0x4b57, 0x4274, + 0x7653, 0x4b77, 0xee3f, 0x5d7c, 0x5d7d, 0x324f, 0x4a28, 0x4c7d, + 0x5e21, 0x3c23, 0x3e42, 0x5d78, 0x5d7e, 0x3168, + /* 0x6CC0 */ + 0x3637, 0xee40, 0x5d75, 0x5d7a, 0x765b, 0x4074, 0x4771, 0x4867, + 0xee41, 0x5d77, 0x765c, 0x4b21, 0xee43, 0x5d79, 0x5e24, 0xee44, + 0x5e22, 0xee45, 0x5d7b, 0x765d, 0x4b22, 0x4748, 0x3563, 0x4525, + 0x436d, 0xee46, 0x5e25, 0x765e, 0xee47, 0xee48, 0x765f, 0x5e23, + 0x4259, 0x5d76, 0x314b, 0x765a, + /* 0x6D00 */ + 0xee4a, 0x7661, 0xee4b, 0x4d4e, 0x5e30, 0x7662, 0x5e2f, 0x4076, + 0x5e2c, 0x4d6c, 0x4636, 0x5e26, 0xee4c, 0x4445, 0xee4d, 0xee4e, + 0x314c, 0x393f, 0x5e29, 0x7663, 0xee50, 0x7664, 0x3d27, 0x5e2e, + 0xee65, 0x5e2d, 0x5e28, 0x5e2b, 0x7665, 0x3368, 0xee51, 0x5e2a, + 0x4749, 0x7666, + /* 0x6D40 */ + 0x4e2e, 0x3e74, 0x4075, 0x7667, 0x5e36, 0x5e34, 0xee52, 0x494d, + 0xee53, 0xee54, 0x5e31, 0x5e33, 0x7668, 0x313a, 0x3940, 0x4f32, + 0x333d, 0x4962, 0xee55, 0x4d61, 0x3324, 0x3f3b, 0x5e35, + /* 0x6D80 */ + 0xee56, 0xee57, 0x766a, 0x5e3a, 0x766b, 0x3e43, 0x766c, 0xee58, + 0x4d30, 0xee59, 0x5e37, 0xee5a, 0x5e32, 0x766d, 0x5e38, 0xee5b, + 0x4e5e, 0x4573, 0x4642, 0x766e, 0xee61, 0x766f, 0xee62, 0x3336, + 0x3155, 0xee63, 0x5e3e, 0x5e41, 0x4e43, 0x7670, + /* 0x6DC0 */ + 0x4d64, 0xee64, 0x7671, 0x5e48, 0x5e42, 0x5e3f, 0xee66, 0x4e54, + 0x5e45, 0xee67, 0xee68, 0xee69, 0x3d4a, 0x5e47, 0x5e4c, 0x7672, + 0x4571, 0x5e4a, 0x7673, 0x7674, 0x7675, 0x5e44, 0xee6a, 0x4338, + 0x5e4b, 0x5e40, 0x5e46, 0xee6b, 0x5e4d, 0x307c, 0x5e43, 0x5e4e, + 0x3f3c, 0x3d5f, 0x4a25, 0xee6c, 0x3a2e, 0x5e3b, 0x5e49, 0x453a, + 0x7676, + /* 0x6E00 */ + 0x4036, 0x3369, 0x3a51, 0x3e44, 0x5e3d, 0x3d42, 0x374c, 0x5e3c, + 0xee5d, 0x5e52, 0x3d6d, 0x383a, 0x5e61, 0xee6e, 0x5e5b, 0x3574, + 0x454f, 0xee6f, 0x5e56, 0x5e5f, 0x302f, 0x3132, 0xee70, 0x3239, + 0x5e58, 0x422c, 0x5e4f, 0x5e51, 0x3941, 0xee72, 0x7678, 0xee6d, + 0x5e62, 0x5e5d, 0xee73, 0x5e55, + /* 0x6E40 */ + 0x5e5c, 0x7679, 0xee74, 0xee75, 0x4c2b, 0xee76, 0xee77, 0x5e5a, + 0x5e5e, 0xee78, 0xee79, 0xee7a, 0xee7b, 0x3850, 0xee7c, 0x3e45, + 0x4339, 0x767a, 0x767b, 0x5e54, 0xee7d, 0x4d2f, 0x5e57, 0x5e50, + 0x4572, 0x5e53, 0x5e59, 0x4f51, 0x3c3e, + /* 0x6E80 */ + 0x4b7e, 0x5e63, 0x482e, 0x5e6f, 0x383b, 0xef21, 0x3d60, 0x5e65, + 0x4e2f, 0x3942, 0x5e72, 0x306e, 0x5e70, 0xef22, 0x5e64, 0x767c, + 0x5e6a, 0x767d, 0x5e6c, 0xef23, 0x4d4f, 0x5e67, 0x452e, 0x5e69, + 0xef24, + /* 0x6EC0 */ + 0x767e, 0x5e71, 0xef25, 0x5e6b, 0x4c47, 0x7721, 0x5e66, 0xef26, + 0x3c22, 0x5e7e, 0x7722, 0x336a, 0x5e68, 0x5e6d, 0x5e6e, 0xef27, + 0x426c, 0x425a, 0xef29, 0x5e76, 0x5e7c, 0x5e7a, 0x4529, 0x5f23, + 0x5e77, 0xef2a, 0xef2b, 0x5e78, 0x5e60, + /* 0x6F00 */ + 0x3579, 0x493a, 0x3c3f, 0x3977, 0xef2c, 0xef2d, 0x4f33, 0x7723, + 0x5e74, 0x5f22, 0x3169, 0x4166, 0xef2e, 0x7724, 0x4779, 0x3441, + 0x4e7a, 0xef2f, 0x7726, 0x4c21, 0x4452, 0x7727, 0x5e7b, 0x5e7d, + 0x7728, 0xef28, 0xef30, 0x4132, 0xef31, 0x5f21, 0x5e79, + /* 0x6F40 */ + 0x5e73, 0x3443, 0x7729, 0xef33, 0x3769, 0xef34, 0x5f2f, 0x772a, + 0xef35, 0x5f2a, 0x4078, 0x772b, 0x3363, 0xef36, 0x772c, 0x772d, + 0x3d61, 0x5f33, 0xef37, 0x5f2c, 0x442c, 0x5f29, 0x4459, 0x5f4c, + 0x5f26, 0x5f25, 0x5f2e, 0xef39, 0x772e, + /* 0x6F80 */ + 0x5f28, 0x5f27, 0x5f2d, 0x4021, 0x5f24, 0x772f, 0x7730, 0x7731, + 0x5f30, 0xef3a, 0x5f31, 0x7732, 0xef3b, 0x3442, 0xef38, 0xef3d, + 0x7733, 0x5f36, 0x5f35, 0x5f37, 0xef3e, 0x7734, 0x5f3a, 0xef3f, + 0x4543, 0x5f34, 0xef41, 0x7735, 0x5f38, 0x7736, 0xef3c, + /* 0x6FC0 */ + 0x3763, 0x4279, 0x5f32, 0x473b, 0x5f39, 0x7737, 0xef42, 0xef43, + 0x7738, 0x5f3e, 0x5f3c, 0x5f3f, 0xef44, 0x5f42, 0xef45, 0x5f3b, + 0x396a, 0x4728, 0x5e39, 0xef46, 0x4d74, 0x5f3d, 0x5f41, 0x4275, + 0x773a, 0x5f40, 0x5f2b, 0x773b, 0x6f69, 0x7739, 0x5f45, 0xef48, + 0x5f49, + /* 0x7000 */ + 0xef49, 0x5f47, 0x773c, 0x773d, 0xef4a, 0x5f43, 0xef4b, 0x5f44, + 0x5f48, 0x5f46, 0x494e, 0x5f4e, 0x5f4b, 0x5f4a, 0x5f4d, 0x4654, + 0x5f4f, 0xef4c, 0x4375, 0x426d, 0x773e, 0x4025, 0x5f50, 0x5f52, + 0xef4e, 0xef4f, 0xef50, 0x5f51, + /* 0x7040 */ + 0xef51, 0xef52, 0x773f, 0xef53, 0x5e75, 0x7742, 0x5f53, 0xef55, + 0x4667, 0x7740, 0x7741, 0x5f54, 0x7743, 0xef56, 0xef57, 0x3250, + 0xef58, 0xef59, 0x4574, 0x3325, 0x7744, 0xef5a, 0x3564, 0x3c5e, + 0x3a52, 0xef5b, + /* 0x7080 */ + 0xef5c, 0x7745, 0xef5d, 0x4f27, 0x3f66, 0x316a, 0x5f56, 0xef5e, + 0xef5f, 0x5f55, 0xef62, 0x7746, 0x7747, 0x5f59, 0x433a, 0x5f5c, + 0x5f57, 0xef63, 0x5f5b, 0x7748, 0x5f5a, 0x4540, 0x3059, 0xef60, + /* 0x70C0 */ + 0x4e75, 0xef66, 0x5f5e, 0x3128, 0xef67, 0xef68, 0x7749, 0x774a, + 0x5f60, 0xef69, 0x5f5f, 0x5f5d, 0x774b, 0xef65, 0x5f58, 0x4b23, + 0x5f62, + /* 0x7100 */ + 0xef6a, 0xef6b, 0xef6c, 0xef6d, 0xef6e, 0x5f61, 0xef6f, 0x774c, + 0x316b, 0x5f64, 0x4a32, 0x5f63, 0x774e, 0x774f, 0x4c35, 0x3e47, + 0x774d, 0x7750, 0xef71, 0x7751, 0xef72, 0x4133, 0x3e46, + /* 0x7140 */ + 0x7752, 0x7753, 0x4e7b, 0xef74, 0x5f6a, 0x4079, 0xef73, 0x7754, + 0x7756, 0xef75, 0x5f66, 0x5f6b, 0x316c, 0x7757, 0xef76, 0x7758, + 0x5f69, 0x4761, 0x5f65, 0x5f68, 0x3e48, 0x7759, 0x4851, 0x5f6c, + 0x3c51, 0x407a, + /* 0x7180 */ + 0xef79, 0x5f6f, 0x775b, 0x775c, 0x5f67, 0x3727, 0x5f6d, 0x775d, + 0x4d50, 0x5f70, 0xef78, 0x7426, 0xef7a, 0x3d4f, 0xef7b, 0xef7c, + 0x5f71, 0x5f72, 0xef7d, 0xef7e, 0x472e, 0xf021, 0x5f74, 0x775f, + 0x5f75, + /* 0x71C0 */ + 0x775e, 0x4733, 0x7760, 0x4575, 0x5f77, 0xf023, 0x5f79, 0x4e55, + 0x5f76, 0xf024, 0x5f78, 0x316d, 0x5f73, 0xf025, 0xf026, 0x535b, + 0x5f7a, 0x4167, 0x3b38, 0x5f7c, 0x5f7b, 0x3f24, 0x5259, 0x5f7d, + 0x6021, 0x5f6e, 0x5f7e, 0x7761, 0x6022, + /* 0x7200 */ + 0x7762, 0x477a, 0xf027, 0x6023, 0x6024, 0x7763, 0x6025, 0x6026, + 0x445e, 0xf02a, 0x6028, 0x6027, 0x6029, 0x602a, 0xf02b, 0x3c5f, + 0x4963, 0xf02c, 0xf02d, 0x4c6c, 0x602b, 0x602c, 0x4156, 0x3c24, + 0x602d, + /* 0x7240 */ + 0x602e, 0xf02f, 0x602f, 0x4a52, 0x4847, 0x6030, 0x4757, 0x442d, + 0xf030, 0x7764, 0x7765, 0xf031, 0x6031, 0x3267, 0x356d, 0x4c46, + 0x4c36, 0x3234, 0x4f34, 0xf032, 0x4b52, 0x4a2a, 0xf034, 0xf035, + 0x4037, 0x6032, 0xf036, 0x4643, 0x3823, 0x6033, 0xf037, + /* 0x7280 */ + 0x3a54, 0x6035, 0x6034, 0x6036, 0x7767, 0xf038, 0x6037, 0x6038, + 0x7768, 0x353e, 0x6039, 0x603a, 0x3824, 0xf03a, 0xf03b, 0x4848, + 0xf03c, 0xf03d, 0x603c, 0x3e75, 0x603b, 0x7769, + /* 0x72C0 */ + 0x776a, 0xf03e, 0x3638, 0x603d, 0x603f, 0x603e, 0xf040, 0x6040, + 0x3851, 0x6041, 0x3669, 0x4140, 0x397d, 0x6043, 0x6044, 0x6042, + 0x3c6d, 0x4648, 0x3639, 0xf043, 0x6046, 0x432c, 0x6045, 0xf044, + 0x776b, 0x4f35, 0x4762, + /* 0x7300 */ + 0xf045, 0x6049, 0xf046, 0x604b, 0x6048, 0xf047, 0xf048, 0x4c54, + 0x604a, 0x604c, 0x4e44, 0x6050, 0x776d, 0x776e, 0x604f, 0x4376, + 0x472d, 0xf04b, 0x3825, 0x604e, 0xf04c, 0xf04d, 0x604d, 0x4d31, + 0x4d32, 0xf04a, 0xf04e, 0x6051, 0x316e, + /* 0x7340 */ + 0x3976, 0x3b62, 0x6052, 0x6053, 0x7770, 0xf04f, 0x6055, 0x3d43, + 0x7771, 0x6057, 0x6056, 0xf051, 0xf052, 0xf054, 0xf055, 0x6058, + 0xf056, 0x334d, 0x605a, 0xf057, 0x6059, 0x605c, 0x605b, 0x7772, + /* 0x7380 */ + 0xf058, 0x383c, 0xf059, 0x4e28, 0x364c, 0xf05a, 0x3226, 0xf05b, + 0x7773, 0x366a, 0xf05c, 0xf05d, 0xf05e, 0x7774, 0x7775, 0x7776, + 0xf05f, 0x7777, 0xf060, 0x3461, 0x7778, 0x4e68, 0x605e, 0xf061, + 0xf062, 0xf063, 0x6060, 0xf064, 0xf065, + /* 0x73C0 */ + 0x6061, 0x3251, 0xf066, 0x605d, 0x7779, 0x3b39, 0xf067, 0x4441, + 0x605f, 0x777a, 0x777b, 0x777c, 0x6064, 0x3c6e, 0xf068, 0x777d, + 0x6062, 0xf069, 0x777e, 0x373e, 0x4849, 0x6063, 0x607e, 0x6069, + 0xf06a, 0xf06c, 0x383d, + /* 0x7400 */ + 0xf06d, 0x3565, 0x6066, 0x4d7d, 0x7821, 0x4e30, 0x7822, 0xf06b, + 0x7823, 0x7824, 0x4276, 0xf06e, 0x6068, 0x7826, 0x7827, 0x7828, + 0x7829, 0x782a, 0x782b, 0x782c, 0x782d, 0xf06f, 0x606a, 0x4e56, + 0x3657, 0x487c, 0x474a, 0xf070, 0x606b, 0x606d, + /* 0x7440 */ + 0xf072, 0x6070, 0xf073, 0x782e, 0x782f, 0x7830, 0x7831, 0xf074, + 0xf075, 0xf071, 0x606c, 0x7832, 0x606f, 0x386a, 0x314d, 0x6071, + 0xf076, 0x3f70, 0x606e, 0x4e5c, 0x7833, 0x6074, 0x7424, 0x6072, + 0x6075, 0x7834, 0x7835, 0x6067, 0x6073, 0xf077, 0x3a3c, 0x6076, + 0x6077, + /* 0x7480 */ + 0xf078, 0x4d7e, 0xf079, 0x7836, 0x7837, 0xf07a, 0x7838, 0x6078, + 0x783d, 0xf07c, 0xf07d, 0x7839, 0xf07e, 0x783a, 0x6079, 0x783b, + 0xf121, 0xf122, 0x6065, 0x783c, 0xf123, 0x783e, 0x607a, 0x783f, + 0x7840, 0xf124, 0xf125, 0x3444, 0x7841, 0xf126, 0xf128, 0xf127, + 0x3c25, 0x7842, + /* 0x74C0 */ + 0x7843, 0x7844, 0x607b, 0x607c, 0x607d, 0xf129, 0xf12a, 0x7845, + 0x313b, 0xf12b, 0x6121, 0x493b, 0x6122, 0x3424, 0x6123, 0x6124, + 0xf12d, 0x6125, 0xf12c, 0x6127, 0x6128, 0x6126, 0x4953, 0x612a, + 0x6129, 0xf12f, 0x7846, + /* 0x7500 */ + 0x7847, 0x612c, 0x612b, 0x612d, 0x612e, 0x6130, 0x612f, 0x3979, + 0x6132, 0x6131, 0x7848, 0x3445, 0x3f53, 0x453c, 0x6133, 0x4038, + 0xf131, 0x3b3a, 0xf132, 0x3179, 0x6134, 0x4d51, 0xf133, 0x4a63, + 0x6135, 0x7849, 0x4544, 0x4d33, 0x3943, 0x3f3d, 0x434b, 0x5234, + 0x442e, 0x3268, 0x6136, 0xf136, 0xf137, + /* 0x7540 */ + 0xf138, 0x6137, 0x613c, 0xf139, 0x613a, 0x6139, 0x5a42, 0x3326, + 0x6138, 0xf13a, 0x305a, 0xf13b, 0x482a, 0xf13c, 0x484a, 0x4e31, + 0x613d, 0x613b, 0x435c, 0x4026, 0x482b, 0x492d, 0x613f, 0x4e2c, + 0x374d, 0x6140, 0x613e, 0x4856, 0x6141, 0xf13d, 0x6142, 0x784a, + 0x305b, 0xf13f, 0xf13e, 0x3e76, 0x6147, 0x6144, 0x466d, 0x6143, + 0x784b, 0xf140, 0xf141, 0xf142, 0x3526, + /* 0x7580 */ + 0xf143, 0x614a, 0x6145, 0x6146, 0x6149, 0x6148, 0x4925, 0xf145, + 0x4142, 0x4141, 0x353f, 0x784c, 0x614b, 0x614c, 0x614d, 0xf147, + 0x614f, 0x614e, 0x3156, 0xf149, 0x6157, 0x4868, 0x6151, 0x6153, + 0xf14a, 0x6155, 0x3f3e, 0x6156, 0x6154, 0x3c40, 0xf14b, + /* 0x75C0 */ + 0xf14c, 0x6150, 0x6152, 0x4942, 0xf14d, 0x3e49, 0x6159, 0x6158, + 0x784e, 0xf14e, 0x615a, 0xf14f, 0x3c26, 0x3a2f, 0x4577, 0x615b, + 0x444b, 0xf150, 0x615d, 0xf151, 0xf152, 0x4e21, 0x615c, 0x784f, + 0xf153, 0x4169, 0xf154, 0xf155, 0x6162, 0xf156, 0x6164, 0x6165, + 0x4354, 0xf157, 0x6163, 0x6160, 0x615e, 0x615f, + /* 0x7600 */ + 0x7850, 0x6161, 0x7851, 0xf158, 0xf15a, 0x7852, 0x6168, 0x6166, + 0x6167, 0xf15b, 0xf15e, 0x7853, 0x7854, 0xf159, 0x7855, 0xf15f, + 0xf160, 0x7856, 0x6169, 0x616b, 0x616c, 0x616d, 0x616e, 0xf162, + 0x7e7d, 0x616a, 0xf163, 0x7857, 0x6170, 0xf165, 0x616f, 0x7858, + 0x6171, 0xf164, + /* 0x7640 */ + 0xf168, 0x4e45, 0x7859, 0x6174, 0x6172, 0x6173, 0xf16a, 0x785a, + 0x3462, 0x4c7e, 0xf16b, 0x4a4a, 0x6176, 0x6175, 0x6177, 0x6178, + 0x785b, 0x785c, 0x617c, 0x6179, 0x617a, 0x617b, 0x617d, 0x785d, + 0xf16d, 0x785e, 0x617e, 0x785f, 0x6221, 0x6222, 0x6223, 0x482f, + 0x4550, 0x6224, 0x4772, 0x4934, + /* 0x7680 */ + 0x6225, 0x7860, 0x6226, 0x452a, 0x3327, 0x3944, 0x6227, 0x6228, + 0x6229, 0x3b29, 0x622b, 0xf16e, 0x622a, 0x622c, 0x622d, 0x7861, + 0xf16f, 0x7862, 0x7863, 0xf171, 0xf170, 0x7864, 0xf172, 0xf173, + 0x7865, 0x4869, 0xf174, 0x622e, 0x622f, 0x7866, 0x7369, 0x6230, + 0x6231, 0x6232, 0x3b2e, + /* 0x76C0 */ + 0x6233, 0x4756, 0x7867, 0x4b5f, 0x314e, 0xf176, 0x3157, 0x7868, + 0x6234, 0x7869, 0x6236, 0x786a, 0x6235, 0x4570, 0x4039, 0x5d39, + 0x6237, 0x4c41, 0x6238, 0x3446, 0x4857, 0x6239, 0x786b, 0x623a, + 0xf178, 0x623b, 0xf179, 0x4c5c, 0x786c, 0x4c55, 0x443e, 0x416a, + 0x623d, 0x786d, 0x3d62, + /* 0x7700 */ + 0x3e4a, 0x6240, 0x623f, 0x623e, 0x487d, 0x786e, 0x3447, 0x3829, + 0xf17b, 0x786f, 0xf17c, 0x6246, 0x6243, 0x3f3f, 0x4c32, 0x6242, + 0x6244, 0x6245, 0x6241, 0xf17d, 0x7870, 0xf17e, 0x7871, 0x6247, + 0x6248, 0x442f, 0x3463, + /* 0x7740 */ + 0x4365, 0x7872, 0x6249, 0x7873, 0x7874, 0xf225, 0x624a, 0x624d, + 0x7875, 0x7876, 0xf226, 0x3f67, 0x7877, 0x4644, 0x624e, 0x4b53, + 0x624b, 0xf227, 0x624c, 0xf229, 0x6251, 0x7878, 0xf22a, 0xf22b, + 0x6250, 0x624f, + /* 0x7780 */ + 0x7879, 0x6253, 0x6252, 0x6254, 0x787a, 0xf22e, 0x6256, 0xf22f, + 0x6255, 0xf230, 0xf231, 0x4a4d, 0xf232, 0x787b, 0x3d56, 0x4e46, + 0x6257, 0x4637, 0x6258, 0x6259, 0x625d, 0x625b, 0x625c, 0x625a, + /* 0x77C0 */ + 0x625e, 0x625f, 0x6260, 0x6261, 0x4c37, 0x6262, 0xf233, 0xf234, + 0x787c, 0x4c70, 0x6263, 0xf235, 0x434e, 0xf236, 0x476a, 0x366b, + 0xf237, 0xf238, 0x433b, 0x6264, 0x363a, 0xf23a, 0x4050, 0xf23b, + 0xf23c, 0x6265, + /* 0x7800 */ + 0x3a3d, 0xf23e, 0xf23f, 0xf240, 0x6266, 0xf241, 0x6267, 0x3826, + 0x3a55, 0xf242, 0x6269, 0xf243, 0x4556, 0x3a56, 0x354e, 0xf244, + 0x787d, 0x4b24, 0x474b, 0x4557, 0x395c, + /* 0x7840 */ + 0x7921, 0x626b, 0xf245, 0x7922, 0x7923, 0x7924, 0x3e4b, 0xf246, + 0x7925, 0xf247, 0x4e32, 0x3945, 0x7926, 0x3827, 0x4823, 0x626d, + 0x626f, + /* 0x7880 */ + 0x386b, 0x626e, 0x4476, 0xf249, 0x6271, 0x3337, 0x626c, 0x486a, + 0x3130, 0xf24a, 0x3a6c, 0x4f52, 0x6270, 0xf24c, 0xf24d, 0xf24e, + 0x6272, 0xf24b, 0x4a4b, 0x4059, 0x6274, 0x792a, 0x6275, 0x7928, + 0x6273, 0x334e, 0xf24f, 0x627b, 0x627a, + /* 0x78C0 */ + 0x3c27, 0x627c, 0x6277, 0xf250, 0x627d, 0x6278, 0xf251, 0xf252, + 0x4858, 0x6276, 0x6279, 0xf253, 0x6322, 0xf254, 0xf255, 0x792b, + 0xf256, 0x6321, 0x4b61, 0x627e, 0x306b, 0x792c, 0x6324, 0x792e, + 0xf257, 0xf258, 0xf259, 0x6323, 0xf25a, + /* 0x7900 */ + 0x792d, 0x3e4c, 0x6325, 0x4143, 0xf25c, 0x6327, 0x6326, 0x6328, + 0xf25d, 0x792f, 0xf25f, 0x6268, 0x626a, 0x632a, 0x6329, 0x7930, + 0xf25e, 0x7931, 0x7932, 0x3c28, 0xf260, 0x4e69, 0x3c52, + /* 0x7940 */ + 0x632b, 0x3737, 0x7935, 0x7936, 0x3540, 0x3527, 0x3b63, 0xf261, + 0x4d34, 0x6331, 0x6330, 0x4144, 0x632d, 0xf262, 0x632f, 0xf263, + 0x793a, 0x3d4b, 0x3f40, 0x632e, 0x632c, 0x472a, 0x3e4d, 0xf265, + 0x493c, 0x3a57, 0xf266, 0x4578, 0x793e, 0x6332, 0x6333, + /* 0x7980 */ + 0x6349, 0x3658, 0x4f3d, 0x4135, 0x6334, 0x3252, 0x4477, 0x4a21, + 0xf267, 0xf268, 0xf269, 0x7942, 0xf26a, 0x6335, 0xf26b, 0x357a, + 0x6336, 0xf26c, 0x6338, 0x6339, 0x4729, 0x7943, 0x633a, 0xf26d, + 0x7944, 0x633b, 0x633c, 0xf26e, 0x3659, 0x3253, 0x4645, + /* 0x79C0 */ + 0x3d28, 0x3b64, 0xf26f, 0xf270, 0x7945, 0x633d, 0x7946, 0x3d29, + 0xf271, 0xf272, 0x324a, 0x4943, 0x7948, 0x633e, 0xf273, 0x486b, + 0x7949, 0x4145, 0x6341, 0x6342, 0x4769, 0x3f41, 0x633f, 0x4361, + 0x794a, 0x6340, 0x794b, 0x3e4e, 0x305c, + /* 0x7A00 */ + 0x3529, 0x794c, 0x6343, 0xf278, 0x4478, 0x6344, 0x4047, 0xf279, + 0x4c2d, 0xf27a, 0x4923, 0x6345, 0x6346, 0x4355, 0xf27b, 0x4e47, + 0xf27c, 0x6348, 0x6347, 0xf27e, 0x3c6f, 0x634a, 0x3070, 0x634d, + 0xf321, 0x794e, 0x634b, 0x3254, 0x374e, 0x634c, 0x3946, + /* 0x7A40 */ + 0x3972, 0x4a66, 0x634e, 0x4b54, 0xf322, 0x6350, 0xf323, 0x4051, + 0x314f, 0x323a, 0x302c, 0xf324, 0x634f, 0xf325, 0xf326, 0x794f, + 0xf327, 0xf328, 0x6351, 0x6352, 0x3e77, 0xf329, 0x6353, 0xf32a, + 0x334f, 0x7950, 0x6355, 0x376a, 0xf32b, 0x3566, 0xf32c, 0x6356, + 0x3675, 0x6357, 0x407c, + /* 0x7A80 */ + 0x464d, 0xf32d, 0x4060, 0x3a75, 0x7952, 0x6358, 0xf32e, 0xf32f, + 0x4362, 0x416b, 0x635a, 0x635c, 0x6359, 0x635b, 0x3722, 0x7953, + 0xf330, 0x635d, 0x3726, 0xf331, 0x3567, 0x4d52, 0x635f, 0x7955, + 0x6360, 0xf334, 0x312e, 0x7956, 0xf335, 0xf336, 0x6363, + /* 0x7AC0 */ + 0x3376, 0x6362, 0x6361, 0x6365, 0x635e, 0x6366, 0x4e29, 0xf338, + 0x6367, 0x7957, 0x6368, 0xf339, 0x5474, 0x636a, 0x6369, 0x636b, + 0x636c, 0x4e35, 0x636d, 0x706f, 0x3e4f, 0x636e, 0x636f, 0x3d57, + 0x4638, 0x6370, 0xf33a, 0xf33b, 0x4328, 0x7958, 0x6371, 0x433c, + 0x6372, 0xf33c, 0x3625, 0x513f, 0x435d, 0x3c33, 0x7959, 0x3448, + /* 0x7B00 */ + 0x6373, 0x6422, 0x6376, 0xf33f, 0x3568, 0x6375, 0x6424, 0x6374, + 0x3e50, 0x795a, 0x6378, 0x6379, 0x452b, 0x637a, 0x335e, 0x3f5a, + 0x4964, 0xf342, 0x637c, 0xf343, 0x4268, 0x795b, 0xf344, 0xf345, + 0xf346, 0x6377, 0x637b, 0x637d, 0x3a7b, 0x795c, 0xf341, + /* 0x7B40 */ + 0xf34a, 0x6426, 0x492e, 0x795d, 0x4826, 0x4579, 0x365a, 0x6425, + 0x6423, 0x795e, 0x4835, 0x637e, 0x435e, 0x457b, 0x457a, 0xf34c, + 0x3a76, 0x6438, 0x795f, 0xf34e, 0x6428, 0xf34f, 0x642a, 0xf350, + 0x642d, 0x7960, 0x642e, 0x7961, 0x642b, 0x642c, 0x7962, 0xf351, + 0x6429, 0x6427, 0xf34d, 0x6421, 0xf349, + /* 0x7B80 */ + 0x4a4f, 0x3255, 0x6435, 0x6432, 0x6437, 0xf354, 0xf355, 0x6436, + 0x4773, 0x4c27, 0x3b3b, 0x6430, 0x6439, 0x6434, 0xf356, 0x6433, + 0x642f, 0x7963, 0x6431, 0x3449, 0x433d, 0x407d, 0xf358, 0x4822, + 0x643e, 0xf359, 0x4824, 0xf35a, + /* 0x7BC0 */ + 0x4061, 0x643b, 0x484f, 0xf35b, 0x643f, 0x4a53, 0x435b, 0xf35c, + 0x643a, 0x643c, 0x643d, 0xf35f, 0xf360, 0x7965, 0x7966, 0xf361, + 0x6440, 0x3c44, 0x4646, 0x6445, 0x6444, 0x6441, 0xf362, 0x4f36, + 0xf363, 0x644a, 0x644e, 0x644b, + /* 0x7C00 */ + 0x6447, 0x7967, 0xf364, 0x6448, 0xf365, 0x644d, 0xf366, 0xf367, + 0x6442, 0x5255, 0x6449, 0x6443, 0x644c, 0x7969, 0x6452, 0x796a, + 0x344a, 0x644f, 0xf368, 0x6450, 0x6451, 0x6454, 0x7968, 0x796b, + 0x796c, 0x6453, 0x4876, 0x6455, 0x4e7c, 0x4a6d, + /* 0x7C40 */ + 0x645a, 0x6457, 0xf369, 0xf36a, 0x6456, 0x4052, 0x6459, 0x645b, + 0xf36b, 0x6458, 0x645f, 0xf36c, 0x645c, 0x796f, 0xf36d, 0x645d, + 0x6446, 0xf36e, 0x645e, 0x6460, 0xf36f, 0x6461, 0x7970, 0xf370, + 0xf371, 0xf372, 0x4a46, 0x6462, 0x7971, 0x4c62, + /* 0x7C80 */ + 0x364e, 0x3729, 0x6463, 0x4a34, 0x3f68, 0x4c30, 0x7972, 0x6464, + 0x4e33, 0x7973, 0x4774, 0x4146, 0x4734, 0x3d4d, 0x3040, 0x7974, + 0x6469, 0x6467, 0x6465, 0x3421, 0xf376, 0x3e51, 0x646a, 0x6468, + 0x6466, 0x646e, 0x646d, 0x646c, 0x646b, 0xf378, 0xf379, 0x646f, + 0x7975, 0x6470, 0x403a, 0xf37a, + /* 0x7CC0 */ + 0x6471, 0x6473, 0xf37c, 0x6472, 0xf37e, 0x3852, 0xf421, 0x4138, + 0x6475, 0x7976, 0x457c, 0xf423, 0x6474, 0x7977, 0x6476, 0x7978, + 0x4a35, 0x416c, 0x3947, 0x6477, 0xf425, 0x4e48, 0xf426, 0x6479, + 0x647a, 0x647b, 0xf428, 0x647c, 0x3b65, 0x647d, 0x374f, 0x356a, + /* 0x7D00 */ + 0x352a, 0x6521, 0xf429, 0x4c73, 0x3948, 0x647e, 0x7979, 0x797a, + 0xf42a, 0x6524, 0x4c66, 0x473c, 0x4933, 0xf42c, 0x797b, 0x3d63, + 0x6523, 0x3c53, 0x3949, 0x3b66, 0x3569, 0x4a36, 0x6522, 0x797c, + 0xf42d, 0x4147, 0x4b42, 0x3a77, 0x797d, 0x3b67, 0x445d, 0x6527, + 0x4e5f, 0x3a59, 0x797e, 0x6528, 0x3f42, 0x652a, 0x3e52, 0x3a30, + 0xf430, 0xf431, 0x6529, + /* 0x7D40 */ + 0xf432, 0x7a21, 0x3d2a, 0x383e, 0x4148, 0x6525, 0x652b, 0xf433, + 0x7a22, 0x6526, 0x3750, 0x652e, 0x6532, 0x376b, 0x7a23, 0x652d, + 0xf437, 0xf438, 0x6536, 0x7a24, 0x394a, 0x4d6d, 0x303c, 0x6533, + 0x356b, 0x6530, 0xf439, 0x6531, 0xf43a, 0x457d, 0x652f, 0x652c, + 0x3328, 0x4064, 0x3828, 0x7a25, 0x6538, 0xf43c, + /* 0x7D80 */ + 0x7a26, 0xf43e, 0xf43f, 0x6535, 0x7a27, 0xf440, 0x6537, 0x6534, + 0xf441, 0x3751, 0x4233, 0x6539, 0x416e, 0xf443, 0x6546, 0x7a28, + 0x6542, 0x653c, 0x7a29, 0xf444, 0xf445, 0x6540, 0x3c7a, 0x305d, + 0x653b, 0x6543, 0x6547, 0x394b, 0x4c56, 0x4456, 0x653d, 0xf446, + 0xf447, 0x6545, 0x653a, 0x433e, 0x653f, 0x303d, 0x4c4a, + /* 0x7DC0 */ + 0xf448, 0x7a2a, 0x653e, 0x365b, 0x486c, 0x7a2b, 0x416d, 0x4e50, + 0x3d6f, 0x656e, 0x7a2c, 0xf449, 0x6548, 0xf44a, 0x407e, 0x6544, + 0x6549, 0x654b, 0x4479, 0x654e, 0x7a2d, 0x654a, 0xf44b, 0x4a54, + 0x344b, 0x4c4b, 0x305e, 0xf44c, 0x654d, 0x4e7d, 0xf44d, 0x654c, + /* 0x7E00 */ + 0x316f, 0x466c, 0x654f, 0x7a30, 0x6556, 0x6550, 0x6557, 0xf451, + 0x7a31, 0x6553, 0x7a32, 0xf452, 0x477b, 0xf453, 0x3c4a, 0x6555, + 0xf454, 0x6552, 0x6558, 0x6551, 0x3d44, 0xf455, 0x7a2f, 0x4b25, + 0xf456, 0x3d4c, 0x6554, 0x6560, 0x655c, 0x655f, 0x655d, 0x6561, + 0x655b, 0x6541, 0x4053, + /* 0x7E40 */ + 0x484b, 0x655e, 0xf457, 0x6559, 0x7a34, 0x4121, 0x3752, 0x3d2b, + 0x7a35, 0x3f25, 0x4136, 0x6564, 0x6566, 0x6567, 0x6563, 0x6565, + 0x7a36, 0x655a, 0x6562, 0x656a, 0x6569, 0x7e7e, 0x4b7a, 0x372b, + 0xf458, 0xf459, 0x6568, 0x656c, 0x656b, 0x656f, 0xf45a, 0x6571, + /* 0x7E80 */ + 0x3b3c, 0x656d, 0xf45b, 0xf45c, 0x6572, 0x6573, 0x7a37, 0x6574, + 0x7a38, 0x657a, 0x453b, 0x6576, 0xf45e, 0x6575, 0x6577, 0x6578, + 0x6579, 0xf45f, 0xf460, 0x657b, 0x657c, + /* 0x7F00 */ + 0x344c, 0x657d, 0x657e, 0xf463, 0xf462, 0xf464, + /* 0x7F40 */ + 0xf465, 0xf466, 0x6621, 0x7a39, 0x6622, 0x6623, 0x6624, 0xf467, + 0x6625, 0x6626, 0xf46a, 0x6628, 0x6627, 0x6629, 0x662a, 0x662b, + 0xf46c, 0xf46d, 0xf46e, 0x662e, 0x662c, 0x662d, 0x3a61, 0x3753, + 0xf46f, 0x4356, 0x4833, 0x3d70, 0x474d, 0x486d, 0x662f, 0x586d, + 0xf470, 0xf471, + /* 0x7F80 */ + 0x6630, 0x6632, 0x4d65, 0x6631, 0x6634, 0x6633, 0x4d53, 0x6635, + 0x487e, 0xf473, 0x7a3b, 0x6636, 0xf476, 0x7a3c, 0x6639, 0xf477, + 0x6638, 0x6637, 0x663a, 0x3732, 0x4122, 0x3541, 0xf478, 0x663e, + 0x663b, 0x663c, 0x663f, 0x6640, 0x663d, 0x3129, 0x7a3d, + /* 0x7FC0 */ + 0x3227, 0xf47a, 0x6642, 0x6643, 0x6644, 0x4d62, 0x7a3e, 0xf47b, + 0x3d2c, 0x6646, 0x6645, 0x7a3f, 0x7a40, 0x3f69, 0x6647, 0xf47c, + 0xf47d, 0x6648, 0x6649, 0x3465, 0x7a41, 0x7a42, 0xf47e, 0x344d, + 0xf521, 0x664a, 0x664b, 0x7a43, 0x4b5d, 0x4d63, + /* 0x8000 */ + 0x4d54, 0x4f37, 0xf522, 0x394d, 0x664e, 0x3c54, 0x664d, 0xf524, + 0xf523, 0x664f, 0x3c29, 0xf525, 0x4251, 0xf526, 0x6650, 0x7a45, + 0x394c, 0xf527, 0x4c57, 0x6651, 0x6652, 0x6653, 0x6654, 0xf528, + 0x7a46, 0x6655, 0xf529, 0xf52a, 0x3c2a, 0x7a47, 0x4c6d, 0x7a48, + 0x6657, 0x7a49, 0x433f, 0x6656, + /* 0x8040 */ + 0xf52b, 0x6659, 0x6658, 0x665a, 0x403b, 0x665b, 0x665c, 0x4a39, + 0x665d, 0x416f, 0x665e, 0xf52c, 0x665f, 0x4e7e, 0x6662, 0xf52d, + 0x6661, 0x6660, 0x4430, 0xf52e, 0x6663, 0x3f26, 0x6664, 0xf52f, + 0x6665, 0x4f38, 0x6666, + /* 0x8080 */ + 0x6667, 0x6669, 0x6668, 0x4825, 0x4679, 0x4f3e, 0x4829, 0x666b, + 0x3e53, 0x492a, 0xf530, 0x666c, 0x666a, 0xf531, 0x344e, 0x3854, + 0x3b68, 0xf532, 0x486e, 0xf533, 0x382a, 0x4b43, 0x666f, 0x666d, + 0x394e, 0x394f, 0x3069, 0x3a68, 0xf534, 0x4759, + /* 0x80C0 */ + 0x305f, 0x6674, 0xf536, 0x4340, 0x7a4a, 0x4758, 0x425b, 0xf537, + 0x6676, 0x7a4b, 0xf538, 0x6672, 0x6675, 0x6670, 0x6673, 0x4b26, + 0x7a4c, 0x3855, 0x307d, 0x6671, 0xf539, 0x6678, 0x6679, 0x7a4d, + 0x4639, 0xf53c, 0x363b, 0xf53d, 0x6726, 0x473d, + /* 0x8100 */ + 0x3b69, 0x363c, 0x4048, 0x4f46, 0x4c2e, 0x6677, 0x4054, 0xf53b, + 0xf540, 0x7a4e, 0x3553, 0x667a, 0xf541, 0x667c, 0xf543, 0xf544, + 0x667b, 0xf545, 0x667d, 0x4326, 0x473e, 0xf53f, 0x4431, 0xf547, + 0x6723, + /* 0x8140 */ + 0x6722, 0x7a4f, 0x667e, 0x3f55, 0x4965, 0x6725, 0x6724, 0x3950, + 0x4f53, 0x6735, 0x7a50, 0x6729, 0x672a, 0x7a51, 0x7a52, 0xf549, + 0x3c70, 0x7a53, 0x6728, 0x3978, 0x6727, 0x672b, 0x4432, 0x4a22, + 0x4123, 0x425c, + /* 0x8180 */ + 0x672f, 0xf54b, 0x6730, 0x672c, 0xf54d, 0xf54e, 0x672d, 0x672e, + 0x3951, 0x6736, 0x6732, 0xf550, 0x4966, 0x4b6c, 0x4928, 0x6731, + 0x6734, 0x6733, 0x4b44, 0x6737, 0x6738, 0xf551, 0x4137, 0x6739, + 0x673b, 0x673f, 0x7a54, 0x673c, 0x673a, 0x473f, + /* 0x81C0 */ + 0x673d, 0xf552, 0x673e, 0xf553, 0x3232, 0x6745, 0x6740, 0x7a55, + 0x6741, 0x7a56, 0x6742, 0x4221, 0xf554, 0x7a57, 0x6744, 0x6743, + 0x6746, 0xf555, 0x6747, 0x6748, 0x3f43, 0xf557, 0x3269, 0x6749, + 0x4e57, 0x3c2b, 0xf559, 0x3d2d, 0x3b6a, 0x4357, 0x674a, 0x674b, + 0x3131, 0xf55b, 0x674c, 0xf55c, + /* 0x8200 */ + 0x674d, 0x674e, 0xf55e, 0x674f, 0x6750, 0x363d, 0x5a2a, 0x6751, + 0x4065, 0x6752, 0x3c4b, 0x6753, 0x5030, 0x6754, 0x4a5e, 0x345c, + 0xf560, 0x4124, 0x3d58, 0x4971, 0x3d2e, 0xf561, 0xf562, 0x6755, + 0x3952, 0x6756, 0x484c, 0x6764, 0xf564, 0x6758, 0xf565, 0x4249, + 0x4775, 0x383f, 0x6757, 0x4125, 0xf566, + /* 0x8240 */ + 0x6759, 0xf569, 0xf567, 0x447a, 0xf568, 0xf56b, 0xf56d, 0xf56f, + 0x675b, 0x675a, 0x675d, 0xf571, 0x675c, 0x675e, 0x7a5b, 0x6760, + 0xf572, 0x675f, 0x344f, 0x6761, 0x6762, 0x6763, 0x3a31, 0x4e49, + 0x6765, 0x3f27, 0x7a5c, 0x3170, 0x6766, 0x6767, 0xf576, 0xf578, + 0x6768, 0xf579, + /* 0x8280 */ + 0xf57a, 0xf57b, 0x3072, 0x6769, 0x7a5e, 0x676a, 0xf57c, 0x4967, + 0x3c47, 0x676c, 0x7a5f, 0x7a60, 0x7a61, 0x3329, 0x3032, 0xf57d, + 0xf57e, 0x7a62, 0x676b, 0x676e, 0x474e, 0x7a63, 0x3f44, 0x3256, + 0xf621, 0x4b27, 0xf622, 0x7a64, 0x375d, 0x365c, 0xf623, 0x676d, + 0xf624, 0x326a, 0x7a65, 0x7a66, + /* 0x82C0 */ + 0x3423, 0x7a67, 0x3171, 0x6772, 0x4e6a, 0x425d, 0x7a68, 0x4944, + 0x677e, 0x3257, 0x677c, 0x677a, 0x6771, 0x676f, 0xf625, 0x6770, + 0x3c63, 0x366c, 0x4377, 0xf626, 0x4651, 0x3151, 0x6774, 0x6773, + 0xf627, 0x6779, 0x6775, 0x6778, 0x7a69, 0x7a6a, + /* 0x8300 */ + 0x7a6b, 0x7a6c, 0x4c50, 0x6777, 0x3258, 0x337d, 0x677b, 0xf628, + 0xf629, 0x677d, 0xf62a, 0x3754, 0x6823, 0x682c, 0x682d, 0xf62c, + 0x302b, 0xf62d, 0x7a6e, 0x6834, 0x3071, 0x682b, 0x7a6f, 0x682a, + 0xf62e, 0x6825, 0x6824, 0x6822, 0x6821, 0x4363, 0x427b, 0x6827, + 0x7a70, 0xf62f, + /* 0x8340 */ + 0x6826, 0x7a71, 0xf630, 0x6829, 0x7a72, 0x4170, 0x3755, 0x3141, + 0x6828, 0x7a73, 0x3953, 0xf62b, 0x7a74, 0xf631, 0x4171, 0x7a6d, + 0xae4a, 0x683a, 0x683b, 0x3259, 0x322e, 0x6838, 0x7a75, 0xf633, + /* 0x8380 */ + 0x682e, 0x7a76, 0x6836, 0x683d, 0x6837, 0xf636, 0x6835, 0x7a77, + 0x6776, 0xf637, 0xf638, 0x6833, 0x7a78, 0x682f, 0xf639, 0xf63a, + 0x3450, 0x6831, 0x683c, 0x6832, 0x7a79, 0x683e, 0x7a7a, 0x6830, + 0x477c, 0x4d69, 0x6839, 0x684f, 0x7a7b, + /* 0x83C0 */ + 0x7a7c, 0x6847, 0x3f7b, 0x7a7d, 0xf63b, 0x3546, 0x365d, 0x6842, + 0x7a7e, 0xf63c, 0x7b21, 0x325b, 0xf63d, 0x3e54, 0x6845, 0x3a5a, + 0xf63e, 0x4551, 0x684a, 0x7b22, 0xf63f, 0x4a6e, 0x7b23, 0x6841, + 0x325a, 0x3856, 0x4929, 0x684b, 0x683f, 0x6848, 0xf640, 0x6852, + 0x6843, + /* 0x8400 */ + 0x7b24, 0x6844, 0x463a, 0x7b25, 0x6849, 0x7b26, 0x6846, 0x4b28, + 0x684c, 0x3060, 0xf641, 0xf642, 0x6840, 0xf643, 0xf645, 0x684e, + 0x684d, 0x476b, 0x6854, 0x685f, 0x337e, 0x6862, 0x6850, 0xf646, + 0x6855, 0x4d6e, + /* 0x8440 */ + 0x685e, 0x7b28, 0x4d55, 0xf647, 0x4e2a, 0xf648, 0xf649, 0xf64a, + 0x4378, 0xf64b, 0xf64c, 0x336b, 0xf64d, 0x7b29, 0x4972, 0x6864, + 0x4621, 0xf64f, 0x3031, 0x685d, 0x6859, 0x4172, 0x6853, 0x685b, + 0x6860, 0x7b2a, 0x472c, 0x7b2b, 0x302a, 0xf650, 0x6858, 0xf651, + 0x6861, 0x4978, 0xf652, + /* 0x8480 */ + 0xf653, 0x685c, 0x6857, 0x7b2c, 0x3e55, 0x3d2f, 0x3c2c, 0xf656, + 0x4c58, 0x4947, 0x7b2d, 0x6867, 0x6870, 0xf657, 0x685a, 0x7b2e, + 0x3377, 0x7b2f, 0x3e78, 0x6865, 0x7b30, 0x686a, 0x4173, 0xf658, + 0x6866, + /* 0x84C0 */ + 0x7b31, 0x686d, 0x7b32, 0x435f, 0x686e, 0x4d56, 0x6863, 0x3338, + 0x6869, 0xf65a, 0xf65b, 0x686c, 0x4c2c, 0xf65c, 0x686f, 0x6868, + 0x686b, 0xf655, 0xf65e, 0xf65f, 0x4b29, 0x4f21, 0xf660, 0xf661, + 0xf662, 0x6873, 0xf663, 0x687a, 0xf664, 0x6872, + /* 0x8500 */ + 0x3c43, 0x6851, 0xf665, 0x4a4e, 0x4c22, 0x6879, 0x6878, 0x6874, + 0x6875, 0x3136, 0xf666, 0x7b35, 0x6877, 0x6871, 0x7b36, 0xf667, + 0xf668, 0x4455, 0xf669, 0x6876, 0x307e, 0x7b37, 0x7b34, 0xf66a, + 0x4222, 0x4a43, 0xf66f, + /* 0x8540 */ + 0x687b, 0x6921, 0x4859, 0x687e, 0x3e56, 0x3c49, 0x6923, 0x363e, + 0xf66b, 0xf670, 0xf671, 0x6924, 0x4979, 0x687d, 0x7b38, 0x6856, + 0xf672, 0xf673, 0xf674, 0x687c, 0x7b39, 0x4f4f, 0x4622, 0x4973, + 0x692b, 0xf66c, 0x6931, 0x7b3c, 0xf676, 0xf677, 0x6932, 0xf678, + /* 0x8580 */ + 0x6925, 0xf679, 0x4776, 0xf67a, 0x692f, 0x6927, 0x6929, 0x7b3d, + 0x7b3e, 0x6933, 0x6928, 0xf67b, 0x692c, 0x3172, 0x4665, 0x692d, + 0x6930, 0xf67c, 0xf67d, 0x7b3f, 0x6926, 0x4126, 0x692a, 0x3b27, + 0x3f45, 0x3730, 0x4c74, 0x7b3b, 0x4c79, 0x3d72, 0x7b40, 0xf723, + 0x6937, 0x6935, 0xf724, + /* 0x85C0 */ + 0x4f4e, 0xf725, 0x6934, 0xf726, 0x7b41, 0x4d75, 0x7b42, 0x6936, + 0x6938, 0x6939, 0xf727, 0xf728, 0x693c, 0x693a, 0xf729, 0xf72a, + 0x4623, 0x693b, 0xf72b, 0x484d, 0x692e, 0x7b43, 0xf72c, 0x3d73, + 0x693d, 0x6942, 0x4174, 0x6941, 0x7b45, + /* 0x8600 */ + 0xf72d, 0x6922, 0x7b46, 0x7b47, 0x6943, 0x4149, 0x693e, 0x6940, + 0x7b48, 0xf72e, 0x7b44, 0x693f, 0x5d31, 0x5d22, 0x7b4a, 0x6945, + 0xf72f, 0xf730, 0x6944, 0xf731, 0xf732, 0x7b4b, 0x4d76, 0x623c, + 0x6946, 0x7b4c, 0xf734, 0xf735, 0x6947, + /* 0x8640 */ + 0xf737, 0x2f68, 0x6948, 0x3857, 0x3554, 0xf739, 0x694a, 0x515d, + 0xf73a, 0x7b4d, 0x3575, 0x7b4e, 0x4e3a, 0x3673, 0x694b, 0x7b50, + 0x694c, 0x436e, 0x7b52, 0xf73b, 0x694d, 0x7b53, 0xf73c, 0x467a, + 0xf73d, 0x303a, + /* 0x8680 */ + 0xf73e, 0xf73f, 0x3263, 0x6952, 0x6953, 0xf740, 0xf741, 0x694e, + 0x3b3d, 0x7b54, 0xf742, 0xf743, 0x694f, 0x4742, 0xf744, 0x6950, + 0x6951, 0x695b, 0x6955, 0x6958, 0xf746, 0xf747, 0x6954, 0x7b55, + /* 0x86C0 */ + 0xf748, 0xf749, 0x6956, 0x6957, 0x3c58, 0x6959, 0x4341, 0x3756, + 0x3342, 0xf74a, 0x695c, 0xf74b, 0xf74c, 0x333f, 0x6961, 0x695d, + 0x6960, 0xf74d, 0x483a, 0xf74e, 0x695e, 0x695f, 0x4948, 0x485a, + 0x6962, 0x427d, 0x696c, 0x7b56, 0x6968, 0x7b57, 0x7b58, 0x326b, + /* 0x8700 */ + 0x6966, 0x4b2a, 0x6967, 0xf750, 0x6964, 0xf751, 0x6965, 0x696a, + 0x696d, 0x7b59, 0x696b, 0xf752, 0xf753, 0x6969, 0x6963, 0xf754, + 0x4358, 0xf755, 0x6974, 0x4c2a, 0xf756, 0xf757, 0xf758, 0x6972, + 0x6973, 0xf759, 0x696e, 0x6970, 0xf75a, 0x6971, 0xf75b, 0x696f, + /* 0x8740 */ + 0xf75c, 0xf75d, 0x4066, 0x4f39, 0x6978, 0x6979, 0xf75e, 0x6a21, + 0x3f2a, 0x697b, 0xf75f, 0x697e, 0x6976, 0x6975, 0x6a22, 0xf760, + 0xf761, 0x325c, 0x697c, 0x6a23, 0x697d, 0x7b5a, 0xf762, 0x697a, + 0x4433, 0x6977, 0xf763, 0x4768, + /* 0x8780 */ + 0x6a27, 0x7b5b, 0x7b5c, 0xf767, 0xf768, 0x4d3b, 0xf769, 0x6a26, + 0xf76a, 0x6a25, 0xf766, 0x6a2e, 0x7b5d, 0x7b5e, 0x6a28, 0x6a30, + 0x7b5f, 0x4d66, 0x6a33, 0x6a2a, 0xf76d, + /* 0x87C0 */ + 0x6a2b, 0xf76f, 0x6a2f, 0x6a32, 0x6a31, 0x6a29, 0xf770, 0x6a2c, + 0x6a3d, 0x7b61, 0xf772, 0x6a36, 0xf774, 0xf775, 0xf776, 0xf777, + 0xf778, 0x7b62, 0xf779, 0x6a34, 0x6a35, 0xf771, 0x6a3a, 0x6a3b, + 0x332a, 0x3542, 0x6a39, + /* 0x8800 */ + 0xf77a, 0xf77b, 0x6a24, 0x7b63, 0x7b64, 0xf77c, 0x6a38, 0x6a3c, + 0x6a37, 0x7b65, 0x6a3e, 0xf77d, 0x7b66, 0x6a40, 0x6a3f, 0x7b67, + 0x6a42, 0x6a41, 0x695a, 0x6a46, 0xf77e, 0xf821, 0x6a43, 0xf822, + 0x6a44, 0x6a45, 0x6a47, 0xf823, + /* 0x8840 */ + 0x376c, 0x6a49, 0x6a48, 0x3d30, 0xf825, 0x3954, 0x5e27, 0x6a4a, + 0x3d51, 0x3339, 0xf826, 0x6a4b, 0x3152, 0x3e57, 0x6a4c, 0xf827, + 0x3955, 0x6a4d, 0x3061, 0xf828, 0x493d, 0xf82b, 0x6a4e, 0xf82d, + 0x3f6a, 0x6a55, 0x6a52, 0x436f, 0x6a53, 0x6a50, 0x365e, + /* 0x8880 */ + 0x6a4f, 0x6a56, 0x3736, 0x425e, 0x6a5c, 0x6a58, 0x4235, 0x6a57, + 0x7b68, 0x6a5a, 0x6a51, 0xf82e, 0x6a5b, 0x6a5d, 0x7b69, 0x486f, + 0x6a59, 0x6a5e, 0x6a60, 0x3853, 0x6a54, 0x3041, 0xf82f, 0xf830, + 0xf831, 0x6a5f, + /* 0x88C0 */ + 0xf832, 0x3a5b, 0x4e76, 0x6a61, 0x6a62, 0x4175, 0x7b6a, 0x7b6b, + 0x4e22, 0xf835, 0xf833, 0xf836, 0x6a63, 0x4d35, 0x6a64, 0x6a65, + 0xf837, 0x4a64, 0x6a66, 0x3a40, 0x4e23, 0x6a6b, 0xf838, 0xf839, + 0x6a6c, 0x3e58, 0x6a6a, 0x7b6d, 0x4d67, 0x6a67, 0x6a69, 0x403d, + 0x3f7e, + /* 0x8900 */ + 0xf83b, 0x6a68, 0x6a6d, 0x4a23, 0x6a6f, 0x6a6e, 0x336c, 0x4b2b, + 0x6a70, 0x7b70, 0x7b71, 0x7b72, 0x7b6e, 0x6a7c, 0x6a72, 0x6a73, + 0x7b73, 0x6a74, 0x6a75, 0x7b74, 0x7b75, 0x6a79, 0xf83d, 0x6a7a, + 0x7b76, 0x6a78, + /* 0x8940 */ + 0x7b77, 0x6a76, 0xf83f, 0x6a71, 0x6a77, 0xf840, 0xf841, 0x6a7b, + 0x7037, 0x3228, 0x6a7e, 0x365f, 0x6a7d, 0xf844, 0x6b22, 0x6b21, + 0x6b24, 0x6b23, 0x6b25, 0x3d31, 0x6b26, 0x6b27, 0x6b28, 0x403e, + /* 0x8980 */ + 0xf845, 0x4d57, 0x6b29, 0x4a24, 0x4746, 0x6b2a, 0xf846, 0x6b2b, + 0x382b, 0x352c, 0xf847, 0x6b2c, 0x7b78, 0x3b6b, 0x4741, 0x6b2d, + 0x3350, 0xf848, 0x6b2e, 0x6b30, 0x4d77, 0x6b2f, 0x3f46, 0x6b31, + 0x6b32, 0xf849, 0x6b33, 0x3451, 0xf84a, 0x6b34, 0x6b35, 0x6b36, + /* 0x89C0 */ + 0x6b37, 0x3351, 0x7b7a, 0xf84b, 0xf84c, 0x6b38, 0x6b39, 0x6b3a, + 0x3272, 0x7b7b, 0x3f28, 0x6b3b, 0xf84d, 0xf84f, 0xf850, 0x6b3c, + 0x7b7c, 0x6b3d, 0xf851, 0xf852, + /* 0x8A00 */ + 0x3840, 0x447b, 0x6b3e, 0x3757, 0x3f56, 0x6b41, 0x4624, 0x6b40, + 0xf854, 0x7b7d, 0x3731, 0xf855, 0x7b7e, 0x6b3f, 0x4277, 0x352d, + 0x6b42, 0x6b43, 0x3e59, 0xf857, 0x7c21, 0x376d, 0x6b44, 0x4b2c, + 0x405f, 0x3576, 0x4c75, 0x414a, 0xf858, 0x6b45, 0x7c22, 0x3f47, + 0x4370, 0x3e5a, 0xf859, + /* 0x8A40 */ + 0x6b46, 0xf85a, 0x6b49, 0x7c23, 0x6b4a, 0xf85b, 0x7c24, 0x3a3e, + 0x4242, 0x6b48, 0x3e5b, 0x493e, 0xf85c, 0x6b47, 0x7c25, 0x3b6c, + 0x3153, 0x7c26, 0x6b4e, 0x3758, 0x3b6e, 0x3b6d, 0x4f4d, 0x6b4d, + 0x6b4c, 0x4127, 0x354d, 0x4f43, 0x333a, 0x3e5c, 0x7c27, 0x7c28, + 0x6b4b, + /* 0x8A80 */ + 0x6b50, 0x6b51, 0x6b4f, 0x3858, 0x4d40, 0x3b6f, 0x4727, 0xf85e, + 0x6b54, 0x4040, 0x4342, 0x4d36, 0x6b57, 0x386c, 0x403f, 0x6b53, + 0x6b58, 0x386d, 0x6b55, 0x6b56, 0x7c29, 0x6b52, 0x4062, 0x4649, + 0xf85d, 0x432f, 0x325d, 0xf85f, 0x4870, 0x3543, 0xf860, 0x4434, + /* 0x8AC0 */ + 0x6b5b, 0x6b59, 0x434c, 0x4041, 0x3452, 0x6b5a, 0x3f5b, 0x7c2a, + 0x4e4a, 0x4f40, 0xf861, 0x6b5c, 0x6b67, 0x4435, 0x6b66, 0x7c2b, + 0x6b63, 0x6b6b, 0x6b64, 0x6b60, 0x447c, 0x6b5f, 0x6b5d, 0x4d21, + 0x3b70, 0x6b61, 0x6b5e, 0x7c2c, 0x7c2d, 0x6b65, 0x3d74, 0x3841, + 0xf862, 0x427a, + /* 0x8B00 */ + 0x4b45, 0x315a, 0x3062, 0x4625, 0xf865, 0x6b69, 0xf864, 0x6b68, + 0xf866, 0x4666, 0x6b6d, 0x6b62, 0x6b6c, 0x6b6e, 0x382c, 0x6b6a, + 0x3956, 0xf867, 0x3c55, 0xf868, 0x6b6f, 0x4d58, 0x6b72, 0x6b75, + 0x6b73, 0x4935, 0xf869, 0x6b70, 0x3660, 0x6b74, + /* 0x8B40 */ + 0x6b76, 0xf86a, 0x7c31, 0x6b7a, 0x6b77, 0x6b79, 0x6b78, 0xf86c, + 0x7c32, 0x6b7b, 0x3c31, 0x7c33, 0x6b7d, 0x6b7c, 0x4968, 0xf86d, + 0x6c21, 0x3759, 0x7c34, 0x6b7e, 0x6c22, 0x6c23, 0x3544, 0x6641, + 0x3e79, 0x6c24, 0xf86e, 0x386e, 0x6c25, 0xf86f, + /* 0x8B80 */ + 0x6c26, 0xf870, 0x3b3e, 0x5a4e, 0xf871, 0x6c27, 0x6c28, 0x3d32, + 0x6c29, 0x6c2a, 0xf872, 0xf873, 0x6c2b, 0x6c2c, 0x6c2d, 0xf874, + 0x7c35, 0xf875, + /* 0x8C00 */ + 0x432b, 0xf876, 0x6c2e, 0xf878, 0x6c30, + /* 0x8C40 */ + 0x6c2f, 0xf87b, 0x4626, 0xf87c, 0x6c31, 0x7c36, 0x4b2d, 0x6c32, + 0x6c33, 0xf87d, 0x6c34, 0xf87e, 0x6c35, 0xf921, 0x465a, 0x3e5d, + 0x6c36, 0x7c37, 0xf922, 0x396b, 0x502e, 0x6c37, 0xf923, 0xf924, + 0x6c38, 0x493f, 0x6c39, 0x6c41, + /* 0x8C80 */ + 0x6c3a, 0x6c3c, 0x6c3b, 0x6c3d, 0x4b46, 0x6c3e, 0x6c3f, 0xf927, + 0xf926, 0x6c40, 0x6c42, 0xf928, 0xf92a, 0x332d, 0x4467, 0x4969, + 0x3a62, 0x3957, 0xf92b, 0x494f, 0x325f, 0x484e, 0x6c45, 0x3453, + 0x4055, 0x6c44, 0x6c49, 0x4379, 0x4c63, 0x6c47, 0x6c48, 0x352e, + 0x6c4a, 0x4763, 0x425f, 0x4871, 0x453d, 0x6c46, 0x4b47, + /* 0x8CC0 */ + 0x326c, 0x6c4c, 0x4f28, 0x4442, 0x4f45, 0x3b71, 0x6c4b, 0x4231, + 0x6c5c, 0x4128, 0x4678, 0x4950, 0xf92d, 0xf92c, 0xf92e, 0x6c4f, + 0x3b3f, 0x3b72, 0x3e5e, 0x4765, 0x7c39, 0x382d, 0x6c4e, 0x6c4d, + 0x496a, 0x3c41, 0x4552, 0xf930, 0xf931, 0x7c3a, 0x7c3b, 0x6c51, + 0x6c52, 0x3958, 0x6c50, 0x7c3c, + /* 0x8D00 */ + 0x6c53, 0x6c54, 0x6c56, 0x4223, 0xf933, 0x6c55, 0x3466, 0x6c58, + 0xf934, 0x6c57, 0x6c59, 0x7c3e, 0x6c5b, 0x6c5d, 0x6c5e, 0x7c3f, + /* 0x8D40 */ + 0x4056, 0x3c4f, 0x6c5f, 0x3352, 0xf935, 0x6c60, 0x4176, 0x6c61, + 0x6c62, 0x496b, 0x352f, + /* 0x8D80 */ + 0x6c63, 0xf936, 0x4436, 0x315b, 0xf937, 0x6c64, 0x3c71, 0xf938, + 0x3f76, 0x7c40, 0x422d, 0x6c67, 0x6c66, + /* 0x8DC0 */ + 0x6c65, 0xf93a, 0xf93b, 0x6c6d, 0x6c6b, 0x7c41, 0x6c68, 0x7c42, + 0x6c6a, 0x7c43, 0xf93c, 0x6c69, 0x6c6c, 0x3577, 0x6c70, 0x4057, + 0x6c71, 0x3859, 0x6c6e, 0x6c6f, 0xf93d, 0x4f29, 0x4437, 0x4129, + 0x6c72, 0xf940, 0x6c75, + /* 0x8E00 */ + 0xf941, 0x6c73, 0x6c74, 0x4d59, 0xf93e, 0x4627, 0x6c78, 0xf943, + 0xf944, 0x6c76, 0x6c77, 0x6c79, 0x7c44, 0xf945, 0xf946, 0x7c45, + 0xf947, 0x6d29, 0x6c7c, 0x6c7d, 0x6c7b, 0xf94a, 0xf94b, 0x7c46, + /* 0x8E40 */ + 0x6c7a, 0x447d, 0x6d21, 0x6d25, 0x6d22, 0x6c7e, 0xf94c, 0x6d23, + 0x6d24, 0xf94d, 0x6d2b, 0x6d26, 0x4058, 0x6d28, 0xf94e, 0x6d2a, + 0x6d27, 0xf94f, 0xf950, 0xf951, 0x7c47, 0x6d2d, 0x3d33, 0x6d2c, + 0x7c48, 0x6d2e, + /* 0x8E80 */ + 0x6d2f, 0x6d32, 0x6d31, 0x6d30, 0x6d34, 0x6d33, 0x4c76, 0x6d36, + 0x6d35, 0x6d37, 0xf952, 0x6d38, 0xf953, 0x6d3a, 0x6d39, 0x3f48, + 0x6d3b, 0xf954, 0x366d, 0x6d3c, 0x6d3e, 0xf955, 0xf956, 0xf957, + 0xf958, 0x6d3f, + /* 0x8EC0 */ + 0x7c4a, 0x6d40, 0x6d3d, 0x6d41, 0x3c56, 0x6d42, 0x3530, 0x3733, + 0xf95a, 0x382e, 0xf95b, 0x6d43, 0x4670, 0x453e, 0x6d44, 0x6d47, + 0x3c34, 0xf95d, 0x7c4c, 0x6d46, 0x6d45, 0x375a, 0x6d48, + /* 0x8F00 */ + 0xf95f, 0x3353, 0x6d4a, 0xf960, 0x3a5c, 0x6d49, 0x6d52, 0x6d4c, + 0x6d4e, 0x4a65, 0x6d4b, 0xf961, 0x6d4d, 0x6d51, 0x6d4f, 0x3531, + 0x7c4d, 0x6d50, 0x6d53, 0x475a, 0x4e58, 0xf962, 0x7c4e, 0x3d34, + 0x6d54, 0x7c4f, 0x4d22, 0x6d56, 0x6d55, 0x6d59, 0x4d41, + /* 0x8F40 */ + 0xf963, 0x6d58, 0x336d, 0x6d57, 0x6d5c, 0x6d5b, 0xf964, 0x6d5a, + 0x4532, 0x6d5d, 0x7c50, 0x6d5e, 0xf965, 0x6d5f, 0x396c, 0x3725, + 0x6d60, 0x6d61, 0x6d62, + /* 0x8F80 */ + 0x3f49, 0x6d63, 0x3c2d, 0x6d64, 0x6d65, 0xf967, 0x7c52, 0x5221, + 0x517e, 0x6d66, 0x6570, 0x6d67, 0x4324, 0x3f2b, 0x4740, 0xf968, + 0x7c53, 0xf96a, 0x6d68, 0x4a55, 0x4454, 0x397e, 0x4329, + /* 0x8FC0 */ + 0xf96c, 0x312a, 0x4b78, 0x3f57, 0xf96d, 0xf96f, 0xf970, 0x375e, + 0x3661, 0xf971, 0x4a56, 0xf972, 0x6d69, 0xf973, 0x6d6b, 0x7c54, + 0x6d6a, 0x3260, 0x7c55, 0x4676, 0x6d6c, 0x4777, 0x4533, 0x7c56, + 0x6d6d, 0x3d52, 0xf974, 0x6d6f, 0xf975, 0x4c42, 0x6d7e, 0x6d71, + 0x6d72, 0xf976, 0x4449, + /* 0x9000 */ + 0x4260, 0x4177, 0xf977, 0x4628, 0x6d70, 0x3555, 0x7c57, 0x6d79, + 0xf978, 0x6d76, 0x6e25, 0x4629, 0x4360, 0x6d73, 0x447e, 0x4553, + 0x6d74, 0x6d78, 0x3f60, 0x4767, 0x444c, 0x4042, 0x6d77, 0x422e, + 0x4224, 0x6d75, 0x3029, 0x4f22, 0x6d7a, 0x7c58, 0x4261, 0x3d35, + 0x3f4a, 0x6d7c, 0x6d7b, 0xf979, 0x306f, 0x6d7d, 0x492f, 0x6e27, + /* 0x9040 */ + 0x465b, 0x3f6b, 0xf97b, 0xf97c, 0x4359, 0x3678, 0x6e26, 0x4d37, + 0x313f, 0x4a57, 0x3261, 0x6e21, 0x6e22, 0x6e23, 0x6e24, 0x463b, + 0x4323, 0x3063, 0x6e28, 0x6e29, 0x7423, 0x423d, 0xf97d, 0x6e2a, + 0x3173, 0x414c, 0x382f, 0x4d5a, 0x6e2b, 0x452c, 0x4178, 0x3c57, + 0x6e2c, 0x6e2f, 0x3d65, 0x6e2d, 0x412b, 0x412a, 0x3064, 0x4e4b, + 0x6e31, 0x4872, + /* 0x9080 */ + 0x6e33, 0x6e32, 0x6e30, 0x6364, 0x3454, 0xfa22, 0x6d6e, 0x7c5a, + 0x6e35, 0x6e34, 0xfa23, 0x6e36, 0xfa24, 0x4d38, 0x7c5b, 0x7c5c, + 0x7c5d, 0x7c5e, 0xfa26, 0x7c5f, 0x4661, 0x4b2e, 0x6e37, 0x3c59, + 0x6e38, 0xfa28, 0x6e39, 0x7c60, 0x6e3a, 0xfa29, 0x4521, 0x7c61, + /* 0x90C0 */ + 0x306a, 0xfa2a, 0x7c62, 0x7c63, 0x7c64, 0xfa2b, 0x3959, 0x4f3a, + 0x7c65, 0x6e3e, 0xfa2d, 0x7c66, 0x7c67, 0xfa2e, 0x3734, 0x6e3b, + 0x6e3c, 0x4974, 0xfa33, 0x3354, 0x7c68, 0xfa31, 0x7c69, 0x4d39, + 0xfa30, 0x363f, 0x4554, 0xfa34, 0xfa35, + /* 0x9100 */ + 0xfa32, 0x6e3f, 0xfa36, 0xfa37, 0x6e40, 0x7c6b, 0x7c6c, 0x7c6d, + 0xfa38, 0x6e41, 0xfa39, 0xfa3a, 0x7c6e, 0x7c6f, 0x7c70, 0x4522, + 0x7c71, 0x6e43, 0x7c72, 0x6e42, 0x7c73, 0xfa3b, 0xfa3c, 0xfa3d, + 0x7c74, + /* 0x9140 */ + 0xfa3e, 0xfa3f, 0x7c75, 0x4653, 0x6e44, 0x3d36, 0x3c60, 0x475b, + 0x4371, 0x3c72, 0x3f6c, 0x6e45, 0xfa40, 0x6e46, 0xfa41, 0x7c76, + 0xfa42, 0x3f5d, 0x6e47, 0xfa43, 0x6e48, 0x6e49, 0x4d6f, 0x3d37, + 0x6e4b, 0x6e4a, 0xfa44, 0x395a, 0x3973, 0x3b40, 0xfa45, + /* 0x9180 */ + 0x6e4e, 0x7c77, 0xfa46, 0x3d66, 0x6e4d, 0x6e4c, 0x4269, 0xfa47, + 0x386f, 0x4043, 0x4830, 0x3d39, 0x7c78, 0x6e4f, 0x3e5f, 0xfa48, + 0x6e52, 0x6e50, 0x7c79, 0xfa49, 0x6e51, 0x7c7a, 0xfa4a, 0x6e54, + 0x6e53, 0xfa4b, 0x3e7a, 0x6e55, 0x7c7b, + /* 0x91C0 */ + 0x6e56, 0x6e57, 0xfa4c, 0xfa4d, 0x4850, 0x3a53, 0x3c61, 0x6e58, + 0x6e59, 0x4e24, 0x3d45, 0x4c6e, 0x4e4c, 0x6e5a, 0x3662, 0x6e5b, + 0x7c7c, 0x4523, 0xfa4e, 0x6e5e, 0x3378, 0x3f4b, 0x6e5c, 0x6e5d, + 0x4460, 0x7c7e, 0x7d21, 0x4b55, 0x367c, 0xfa51, 0x7d22, 0xfa52, + 0x7d23, 0x6e60, 0x6e61, 0x7c7d, 0x6e5f, 0x6e63, + /* 0x9200 */ + 0xfa53, 0x7d24, 0xfa54, 0x465f, 0x3343, 0x7d25, 0x6e67, 0x6e64, + 0x6e66, 0xfa55, 0xfa56, 0x6e62, 0x6f4f, 0x6e65, 0xfa58, 0x4e6b, + 0x385a, 0x7d26, 0x7d27, 0x7d28, 0x7d29, 0x6e6f, + /* 0x9240 */ + 0x7d2a, 0xfa59, 0x7d2b, 0x4534, 0x6e6a, 0xfa5a, 0x6e6d, 0x6e6b, + 0xfa5b, 0x6e70, 0xfa5c, 0x7d2c, 0x6e71, 0xfa5d, 0xfa5e, 0x6e69, + 0xfa5f, 0x6e76, 0x3174, 0x6e68, 0xfa60, 0xfa61, 0x482d, 0x6e6c, + 0xfa62, 0x3e60, 0xfa63, 0xfa64, 0x395b, 0x7d2d, 0xfa67, 0xfa68, + 0x4b48, 0xfa69, + /* 0x9280 */ + 0x3664, 0x3d46, 0x463c, 0x7d2e, 0xfa6a, 0xfa6b, 0x412d, 0x6e74, + 0x6e6e, 0x6e73, 0xfa6c, 0x4c43, 0xfa6d, 0x4438, 0x6e75, 0x6e72, + 0xfa6e, 0xfa6f, 0xfa70, 0x412c, 0xfa73, 0x6e79, 0x6e78, 0xfa74, + /* 0x92C0 */ + 0xfa75, 0x7d2f, 0xfa76, 0x7d30, 0x7d31, 0xfa77, 0x6e77, 0xfa78, + 0x4b2f, 0x7d32, 0xfa79, 0xfa7a, 0x7d33, 0x3d7b, 0xfa7b, 0xfa7c, + 0x6e7a, 0x4a5f, 0x3154, 0x4946, 0x4372, 0xfb22, 0x3578, 0xfb23, + 0x6e7c, 0xfb24, 0x395d, 0x7d34, + /* 0x9300 */ + 0xfb25, 0x7d35, 0x3b2c, 0xfb26, 0x6e7b, 0x3f6d, 0xfa7d, 0xfb27, + 0x3f6e, 0x6f21, 0x6f23, 0xfb28, 0xfb29, 0x7d36, 0x3e7b, 0x7d37, + 0x6f22, 0x6f24, 0x7d38, 0x3653, 0xfb2a, 0x4945, 0xfb2b, 0x3c62, + 0x4f23, 0x6e7e, 0x3a78, 0x4f3f, 0x6f26, 0x6f25, 0x6f27, + /* 0x9340 */ + 0x6e7d, 0xfb2e, 0x7d39, 0x7d3a, 0x7d3b, 0x4669, 0x4555, 0xfb2f, + 0x4457, 0x6f2c, 0xfb30, 0xfb31, 0x4343, 0x6f28, 0x6f29, 0x7d3c, + 0x7d3d, 0x7d3e, 0xfb32, 0x372d, 0x6f2b, 0x7d3f, 0xfb33, 0xfb34, + 0x3830, 0x6f2a, 0x3e61, + /* 0x9380 */ + 0xfb38, 0xfb39, 0x3379, 0xfb3a, 0x6f30, 0x3a3f, 0x4179, 0x444a, + 0x7d40, 0xfb3b, 0xfb35, 0x7d41, 0x333b, 0x6f2e, 0x6f2f, 0x4443, + 0x6f2d, 0x6f31, 0x7d42, + /* 0x93C0 */ + 0xfb40, 0x6f37, 0x7d43, 0xfb41, 0x6f3a, 0x6f39, 0x452d, 0x6f32, + 0x6f33, 0x6f36, 0xfb42, 0x6f38, 0x7d44, 0x7d45, 0x3640, 0xfb43, + 0x6f3b, 0x6f35, 0xfb44, 0x6f34, 0xfb3f, 0xfb3c, 0xfb49, 0x7d47, + /* 0x9400 */ + 0x6f3f, 0x7d46, 0x6f40, 0xfb45, 0xfb46, 0x6f41, 0x6f3e, 0x6f3d, + 0xfb47, 0xfb48, 0x3e62, 0x462a, 0x6f3c, 0x6f45, 0x6f43, 0xfb4a, + 0x7d48, 0xfb4b, 0x6f44, 0x6f42, 0x4278, 0x6f46, 0xfb4c, + /* 0x9440 */ + 0x6f47, 0x6f49, 0xfb4d, 0x7d49, 0x3455, 0x6f48, 0x4c7a, 0x6f54, + 0x6f4a, 0x6f4d, 0x6f4b, 0x6f4c, 0x7d4a, 0x6f4e, 0x7d4b, 0xfb50, + 0xfb51, 0x6f50, 0x7d4c, 0x7d4d, 0x6f51, 0x6f52, 0x6f55, 0x6f53, + 0x6f56, 0x6f58, + /* 0x9480 */ + 0x6f57, + /* 0x9540 */ + 0x4439, 0xfb52, 0xfb53, + /* 0x9580 */ + 0x4c67, 0x6f59, 0x412e, 0xfb54, 0x6f5a, 0x4a44, 0x6f5b, 0x332b, + 0xfb55, 0xfb56, 0x7d4e, 0x313c, 0x3457, 0x3456, 0x6f5c, 0x6f5d, + 0x6f5e, 0x6f5f, 0x7d4f, 0x6f60, 0x3458, 0x3355, 0x395e, 0x4836, + 0x7d50, 0x6f62, 0x6f61, 0x7d51, 0xfb58, 0x7d52, 0x6f63, 0x315c, + 0xfb59, 0x7d53, 0x6f66, 0x6f65, 0x6f64, 0x7d54, 0x6f67, + /* 0x95C0 */ + 0x6f6a, 0x3047, 0xfb5b, 0x6f68, 0x7d55, 0x6f6c, 0x6f6b, 0x7d56, + 0x7d57, 0x6f6e, 0x6f6d, 0x6f6f, 0x462e, 0x7d59, 0x6f70, 0x7d5a, + 0x6f71, 0x6f73, 0x6f72, + /* 0x9600 */ + 0x496c, 0xfa25, 0x6f74, 0x6f75, 0x3a65, 0xfb5e, 0x6f76, 0x6f77, + 0x4b49, 0xfb5f, 0xfb60, 0x414b, 0xfb62, 0x3024, + /* 0x9640 */ + 0x424b, 0xfb63, 0x6f78, 0x496d, 0x6f7b, 0x6f79, 0x395f, 0x6f7a, + 0x3842, 0x7d5b, 0x4a45, 0x6f7d, 0x7021, 0x6f7e, 0x7022, 0xfb64, + 0x3121, 0x3f58, 0x3d7c, 0x3459, 0x7023, 0x4766, 0x7025, 0x3122, + 0x7024, 0x4444, 0x4e4d, 0x462b, 0x6f7c, 0x4e26, 0x3831, 0x4d5b, + /* 0x9680 */ + 0xfb66, 0x7d5c, 0x3679, 0x4e34, 0x3728, 0x4262, 0x6721, 0x7026, + 0x332c, 0x3f6f, 0x3356, 0x7028, 0x7029, 0x7027, 0x3764, 0xfb68, + 0x3a5d, 0x3e63, 0x7d5e, 0x3123, 0x4e59, 0x7d5f, 0x7d60, 0x702b, + 0x6e2e, 0xfb6b, 0x702a, 0xfb6c, 0x702e, 0x702c, 0x702d, 0xfb6d, + 0x702f, 0x7030, 0x4e6c, 0x7031, 0x7032, 0xfb6e, 0x4049, 0x483b, + 0xfb6f, + /* 0x96C0 */ + 0x3f7d, 0x3467, 0x4d3a, 0x326d, 0x3d38, 0x385b, 0x7035, 0x7034, + 0x3b73, 0x7036, 0x7033, 0x3b28, 0x7d61, 0x703a, 0x6a2d, 0xfb72, + 0x5256, 0xfb73, 0x3f77, 0x7038, 0xfb74, 0x7d62, 0x4e25, 0x4671, + 0x312b, 0x7d64, 0x4063, 0x3c36, 0x7d65, 0x4a37, 0x3140, 0x4e6d, + 0x4d6b, 0x703b, 0x4545, + /* 0x9700 */ + 0x3c7b, 0x703c, 0x703d, 0x3f4c, 0x703e, 0x4e6e, 0x7039, 0x7040, + 0x7042, 0x7041, 0x703f, 0xfb76, 0x7043, 0x7044, 0x417a, 0x3262, + 0xfb77, 0x7045, 0x4c38, 0x7046, 0x7047, 0x4f2a, 0x7d66, 0xfb79, + 0x5b31, 0x7048, 0x7d67, 0x7049, 0x704a, + /* 0x9740 */ + 0xfb7a, 0x704e, 0x704b, 0x704c, 0xfb7b, 0x704d, 0x704f, 0x7d68, + 0x7d69, 0x7d6a, 0x4044, 0xfb7c, 0x4c77, 0xfb7d, 0x4045, 0x7d6b, + 0xfb7e, 0x7050, 0x4873, 0x7051, 0x7353, 0x4c4c, 0x7052, 0x7053, + 0x7054, 0x3357, 0xfc21, 0x7056, 0x3f59, 0x7d6c, 0x7057, 0x7d6d, + 0x3724, 0x7058, 0x705c, 0x705a, + /* 0x9780 */ + 0x705b, 0x3373, 0x7059, 0x705d, 0x705e, 0x3048, 0x705f, 0x7060, + 0x7d6e, 0xfc24, 0x3e64, 0xfc25, 0x7061, 0xfc26, 0x3547, 0xfc27, + 0x7064, 0x7063, 0x7062, 0x6b71, 0x4a5c, 0x7d6f, 0xfc28, 0xfc29, + 0x7065, 0x7066, 0x7d70, 0xfc2a, + /* 0x97C0 */ + 0x7d71, 0x7067, 0x7068, 0x7069, 0x7d72, 0x706a, 0xfc2b, 0xfc2c, + 0x345a, 0xfc2d, 0xfc2e, 0xfc2f, 0x7d74, 0x706b, 0x7d73, 0xfc30, + 0x706c, 0x4723, 0xfc31, 0x706e, 0x323b, 0x7d75, 0x7071, 0x7070, + 0x3124, 0x3641, + /* 0x9800 */ + 0x4a47, 0x443a, 0x3a22, 0xfc32, 0x3960, 0x3d67, 0x3f5c, 0x7d77, + 0x7073, 0xfc33, 0xfc34, 0x7072, 0x4d42, 0x3468, 0x4852, 0x465c, + 0xfc35, 0xfc36, 0x3f7c, 0x4e4e, 0x375b, 0x7d78, 0x7076, 0xfc39, + 0x7075, 0xfc3c, 0x7d79, 0x4b4b, 0x462c, 0x7d7a, 0xfc3a, 0xfc3b, + 0x3150, 0x7077, 0x7074, 0x4951, 0x4d6a, 0x7078, + /* 0x9840 */ + 0x7079, 0xfc3d, 0x707b, 0x426a, 0x335b, 0x335c, 0x707a, 0x7d7c, + 0x7d7d, 0x3469, 0x3832, 0x7d7e, 0x7e21, 0x346a, 0x7e22, 0x7e23, + 0x453f, 0x4e60, 0x7e25, 0xfc3e, 0x385c, 0x707c, 0x7e26, 0x707d, + 0x707e, 0x7121, 0x7123, 0x7122, + /* 0x9880 */ + 0x4977, 0x7124, 0xfc3f, 0xfc40, 0x7125, 0xfc41, 0x7126, 0x7127, + 0xfc43, 0xfc44, 0x7e27, 0xfc45, 0xfc46, 0xfc47, + /* 0x98C0 */ + 0xfc48, 0x7129, 0x7128, 0x712a, 0xfc49, 0x7e28, 0xfc4a, 0x4874, + 0x664c, 0x3f29, 0xfc4b, 0xfc4d, 0x3532, 0xfc4e, 0xfc4f, 0x7e29, + 0x712b, 0xfc50, 0x712c, 0x522c, 0x5d3b, 0x4853, 0xfc51, 0xfc52, + 0x307b, 0xfc53, 0x303b, 0x3b74, 0x4b30, 0x3e7e, + /* 0x9900 */ + 0x712d, 0x4c5f, 0xfc54, 0x712e, 0x4d5c, 0x3142, 0x3b41, 0x712f, + 0x326e, 0x7130, 0xfc57, 0xfc58, 0x7131, 0xfc5a, 0xfc5b, 0xfc5c, + 0x7133, 0x7134, 0x7136, 0x7132, 0x7135, 0x345b, 0x7137, 0x7138, + 0xfc5e, 0xfc5f, 0xfc60, 0xfc61, 0xfc62, 0xfc63, 0x7139, 0x713a, + /* 0x9940 */ + 0xfc64, 0xfc65, 0x713b, 0x713d, 0xfc66, 0x713c, 0x713f, 0x7142, + 0xfc67, 0xfc68, 0x713e, 0x7140, 0x7141, 0x7143, 0x3642, 0x7e2a, + 0xfc69, 0xfc6a, 0xfc6b, + /* 0x9980 */ + 0x3c73, 0x7144, 0x7145, 0x3961, 0x7e2b, 0xfc6c, 0x7146, 0xfc6d, + 0x333e, 0x474f, 0x7147, 0x7148, 0x435a, 0x466b, 0xfc6e, 0x7149, + 0xfc6f, 0xfc70, + /* 0x99C0 */ + 0x477d, 0xfc71, 0x424c, 0x3158, 0x366e, 0x366f, 0xfc72, 0x4373, + 0x714e, 0x3670, 0xfc73, 0x326f, 0x714d, 0xfc74, 0x714b, 0x714c, + 0xfc75, 0x714a, 0x7158, 0x714f, 0x7150, 0xfc77, 0x7151, 0x7152, + 0x7154, 0xfc78, 0x7153, 0xfc79, 0x3d59, + /* 0x9A00 */ + 0x7155, 0x7e2c, 0x7e2d, 0x7157, 0xfc7a, 0x3533, 0x7156, 0xfc7b, + 0x417b, 0x3833, 0xfc7c, 0x7159, 0xfc7d, 0xfc7e, 0x7e2e, 0x424d, + 0x715a, 0x7e2f, 0x7e30, 0x462d, 0xfd21, 0xfd22, 0x715b, 0x7e31, + 0x7160, + /* 0x9A40 */ + 0x715e, 0x715d, 0x715f, 0xfd23, 0x715c, 0x7e32, 0xfd24, 0x7162, + 0x7e33, 0x7e34, 0x7161, 0x7164, 0xfd25, 0x3643, 0x7163, 0x7165, + 0x7166, 0x7168, 0x7167, 0x7169, 0x716b, 0x716a, + /* 0x9A80 */ + 0x397c, 0x716c, 0xfd27, 0x716d, 0x7e35, 0xfd29, 0x333c, 0xfd2b, + 0x716e, + /* 0x9AC0 */ + 0x716f, 0x7e36, 0x7e37, 0x3f71, 0xfd2d, 0x7e38, 0x7170, 0xfd2e, + 0x7171, 0xfd2f, 0x7172, 0x7173, 0xfd30, 0x7e39, 0x3962, 0xfd32, + 0x7174, 0x7175, 0xfd33, 0x7176, 0x7177, 0xfd34, 0x7178, 0xfd35, + 0x4831, 0x717a, 0x4926, 0x717b, 0x7179, 0x717d, 0x717c, 0x717e, + 0x7e3a, 0x7221, + /* 0x9B00 */ + 0x7e3b, 0xfd36, 0x7222, 0x7e3c, 0xfd37, 0xfd38, 0xfd39, 0xfd3a, + 0x7223, 0x7224, 0xfd3b, 0x7225, 0x7e3d, 0x7226, 0x7227, 0x7228, + 0x7229, 0x722a, 0x722b, 0x722c, 0xfd3c, 0x7e3f, 0x722d, 0x722e, + 0x5d35, 0x722f, 0xfd3d, 0x6478, 0x3534, 0xfd3e, + /* 0x9B40 */ + 0x3321, 0x3a32, 0x7231, 0x7230, 0x4c25, 0xfd40, 0x7233, 0x7234, + 0x7232, 0x7235, 0x4b62, 0x7236, 0x357b, 0x7e40, 0xfd41, 0xfd42, + 0x7e42, 0xfd43, 0xfd44, 0x4f25, 0x7e43, 0xfd45, 0x7237, 0x7e44, + 0xfd46, 0xfd47, 0x7e41, + /* 0x9B80 */ + 0x7239, 0x7e45, 0x7e46, 0x303e, 0x7e47, 0x723a, 0x4a2b, 0x7238, + 0x723b, 0x723c, 0x7e48, 0x723d, 0x723e, 0xfd48, 0x7e49, 0x723f, + 0x4b6e, 0x3b2d, 0xfd49, 0x3a7a, 0x412f, 0xfd4a, 0xfd4d, 0x7240, + 0xfd4e, 0x7243, 0xfd4f, + /* 0x9BC0 */ + 0x7241, 0x7e4a, 0x7244, 0xfd50, 0x3871, 0x7242, 0x7e4b, 0x7245, + 0x7246, 0x7247, 0x724b, 0x3b2a, 0xfd52, 0x4264, 0xfd53, 0x724c, + 0x7249, 0x7248, 0x724a, 0x7e4c, 0xfd54, 0x375f, 0xfd55, 0xfd56, + 0xfd58, 0xfd57, 0x7250, 0x724f, 0x724e, 0xfd51, 0x3033, 0xfd5c, + 0x7e4d, 0xfd5a, 0x7e4e, + /* 0x9C00 */ + 0x7e4f, 0x725a, 0x7256, 0x7257, 0x7253, 0x7259, 0x7255, 0x3362, + 0x4f4c, 0x7258, 0x7254, 0x7252, 0x7251, 0xfd5e, 0xfd5f, 0xfd60, + 0xfd61, 0x725c, 0xfd62, 0x725f, 0xfd63, 0x7e50, 0x725e, 0x725d, + 0xfd64, 0xfd65, 0xfd66, 0x4949, 0x725b, 0x3073, 0x7260, 0xfd68, + 0x7262, 0xfd69, 0xfd6a, 0x336f, 0x724d, 0x3137, 0x7264, + /* 0x9C40 */ + 0x7e51, 0xfd6b, 0x7263, 0x7261, 0x432d, 0xfd6e, 0xfd6f, 0x7e52, + 0x7e53, 0x4b70, 0x7e54, 0xfd71, 0x4e5a, 0xfd72, 0x7265, 0xfd73, + 0xfd6c, 0xfd74, 0xfd75, 0x7266, 0x7e55, 0x7e56, 0x7267, 0xfd76, + 0xfd77, 0xfd78, 0xfd79, 0xfd7a, 0xfd7b, 0xfd7c, 0xfd7d, 0x7268, + 0x7e57, 0x7269, 0xfd7e, + /* 0x9CC0 */ + 0x443b, 0xfe21, 0x726a, 0x4837, 0x726f, 0x726b, 0x726c, 0xfe22, + 0x4b31, 0x4c44, 0x4650, + /* 0x9D00 */ + 0xfe24, 0x7270, 0x7271, 0x463e, 0x726e, 0x726d, 0xfe23, 0x322a, + 0xfe26, 0x7279, 0x7278, 0xfe27, 0xfe28, 0x3175, 0x7e58, 0x7e59, + 0x7276, 0x7275, 0x7273, 0x337b, 0x7272, 0x3c32, 0x3229, 0xfe2c, + 0x3963, 0x727c, 0x727b, + /* 0x9D40 */ + 0x727a, 0xfe2e, 0x7e5a, 0x7277, 0x727d, 0x7e5b, 0x727e, 0xfe2f, + 0x7325, 0x7324, 0x7e5c, 0x7326, 0x312d, 0x7321, 0x7322, 0xfe30, + 0x3974, 0x4c39, 0xfe31, 0x7e5d, 0x7323, 0xfe33, 0xfe34, 0x4b32, + 0x732b, 0x7e5e, 0x7327, 0xfe36, 0xfe37, 0xfe38, 0x732c, 0x7e5f, + 0xfe39, + /* 0x9D80 */ + 0xfe3a, 0x7329, 0x7328, 0x7e60, 0xfe3b, 0x375c, 0x7e61, 0xfe3c, + 0x732d, 0xfe3d, 0x732e, 0x732f, 0x732a, 0x7e63, 0x7274, 0x7330, + 0x4461, 0xfe3f, 0x7334, 0xfe40, 0x7335, 0x7333, 0x7e64, 0xfe41, + 0xfe3e, + /* 0x9DC0 */ + 0x7e62, 0x7332, 0x7338, 0xfe42, 0x7331, 0x7336, 0xfe43, 0xfe44, + 0x7337, 0x733a, 0xfe45, 0x7e65, 0x7339, 0xfe46, 0xfe47, 0xfe48, + 0xfe49, 0x733c, 0x7e67, 0x733d, 0x733e, 0x4f49, 0xfe4a, 0x733b, + 0x426b, 0x3a6d, 0x733f, + /* 0x9E00 */ + 0xfe4d, 0x7e68, 0xfe4c, 0xfe4e, 0x7e69, 0xfe4f, 0x7340, 0x7341, + 0xfe50, 0xfe51, 0x7342, + /* 0x9E40 */ + 0x7343, 0x3834, 0x7344, 0xfe52, 0x7e6a, 0x7345, 0x3c2f, + /* 0x9E80 */ + 0xfe54, 0x7346, 0xfe55, 0x7347, 0x7348, 0x7349, 0x734c, 0x734a, + 0x4f3c, 0x734b, 0x4e6f, 0xfe56, 0x734d, 0x7e6b, 0x4e5b, 0x7e6c, + 0x734e, 0x477e, 0xfe57, 0x734f, 0x7351, 0x7e6d, 0x7352, 0x7e6e, + 0x7e6f, 0x7e70, 0x7350, 0x396d, 0x4c4d, 0x4b63, 0x5677, 0xfe59, + 0x5d60, 0x4b7b, + /* 0x9EC0 */ + 0x7e71, 0x322b, 0x7354, 0x3550, 0x7355, 0x7356, 0x7357, 0x7e72, + 0x3975, 0x7358, 0x6054, 0x4c5b, 0x4263, 0x7359, 0x735b, 0x735a, + 0xfe5b, 0x735c, 0x735d, 0xfe5c, 0x735e, 0xfe5d, 0x735f, 0x7360, + 0x7361, 0x7362, 0x7363, 0x7364, 0x7365, 0x7366, 0xfe5e, + /* 0x9F00 */ + 0xfe5f, 0xfe61, 0x7367, 0x7368, 0x4524, 0x7e73, 0x385d, 0x736a, + 0xfe62, 0xfe63, 0x414d, 0x736b, 0x736c, 0xfe64, 0xfe65, 0x7e74, + 0xfe66, 0x4921, 0xfe67, 0x736d, + /* 0x9F40 */ + 0xfe68, 0xfe69, 0xfe6a, 0x736e, 0x6337, 0x6c5a, 0x706d, 0x736f, + 0xfe6b, 0x7370, 0xfe6c, 0x7e75, 0xfe6d, 0xfe6f, 0x7372, 0x7373, + 0x7374, 0x4e70, 0x7371, 0x7375, 0x7376, 0xfe71, 0x7378, 0x7377, + 0xfe73, 0xfe74, 0x737a, 0xfe75, 0x737b, 0x7379, + /* 0x9F80 */ + 0x4e36, 0x7e76, 0x7e77, 0x737c, 0x7e78, 0x737d, 0x6354, 0x737e, + 0x7e79, + /* 0xF900 */ + 0x763b, 0x742e, 0x754e, 0x7b4f, + /* 0xF940 */ + 0x7649, + /* 0xF9C0 */ + 0x7e24, 0x7d5d, + /* 0xFA00 */ + 0x2f4b, 0x2f57, 0x4f72, 0xae79, 0x757a, 0x775a, 0x776f, 0x793c, + 0x793d, 0x7941, 0x7b3a, 0xf738, 0xf745, 0x7c2e, 0xf96e, 0x7c6a, + 0x2e38, 0x2e49, 0x2e50, 0x2e63, 0x2e68, 0x2e6e, 0x2f2c, 0x2f2f, + 0x2f36, 0x2f5a, 0x2f5e, 0x4f61, 0x4f62, 0x7450, 0x745c, 0x745e, + /* 0xFA40 */ + 0x7461, 0x7528, 0x752b, 0x7543, 0x7565, 0x7669, 0x7677, 0x7725, + 0x7755, 0xf029, 0x7825, 0x7927, 0x7933, 0x7934, 0x7937, 0x7938, + 0x7939, 0x793b, 0x793f, 0x7940, 0x794d, 0x7951, 0x7964, 0x7a2e, + 0xf450, 0x7a33, 0x7a3a, 0x7a44, 0x7a58, 0xf574, 0xf575, 0x7b27, + 0x7b6f, 0x7b79, 0x7c2f, 0x7c30, 0x7c38, 0x7c3d, 0xf969, 0x7c59, + 0x7d63, 0x7d76, 0x7d7b, + /* 0xFE40 */ + 0x233e, 0x233d, + /* 0xFF00 */ + 0x212a, 0x2230, 0x2174, 0x2170, 0x2173, 0x2175, 0x222f, 0x214a, + 0x214b, 0x2176, 0x215c, 0x2124, 0x2231, 0x2125, 0x213f, 0x2330, + 0x2331, 0x2332, 0x2333, 0x2334, 0x2335, 0x2336, 0x2337, 0x2338, + 0x2339, 0x2127, 0x2128, 0x2163, 0x2161, 0x2164, 0x2129, 0x2177, + 0x2341, 0x2342, 0x2343, 0x2344, 0x2345, 0x2346, 0x2347, 0x2348, + 0x2349, 0x234a, 0x234b, 0x234c, 0x234d, 0x234e, 0x234f, 0x2350, + 0x2351, 0x2352, 0x2353, 0x2354, 0x2355, 0x2356, 0x2357, 0x2358, + 0x2359, 0x235a, 0x214e, 0x2140, 0x214f, 0x2130, 0x2132, + /* 0xFF40 */ + 0x212e, 0x2361, 0x2362, 0x2363, 0x2364, 0x2365, 0x2366, 0x2367, + 0x2368, 0x2369, 0x236a, 0x236b, 0x236c, 0x236d, 0x236e, 0x236f, + 0x2370, 0x2371, 0x2372, 0x2373, 0x2374, 0x2375, 0x2376, 0x2377, + 0x2378, 0x2379, 0x237a, 0x2150, 0x2143, 0x2151, 0x2232, 0x2256, + 0x2257, + /* 0xFFC0 */ + 0x2131, 0x216f, + /* 0x20000 */ + 0x2e22, + /* 0x20080 */ + 0xa121, 0xa12b, 0xa12e, + /* 0x20180 */ + 0xa136, + /* 0x20200 */ + 0xa146, + /* 0x20300 */ + 0xa170, + /* 0x20340 */ + 0xa179, + /* 0x20380 */ + 0xa177, + /* 0x203C0 */ + 0xa322, + /* 0x20440 */ + 0xa325, + /* 0x20500 */ + 0xa327, + /* 0x205C0 */ + 0xa331, + /* 0x20600 */ + 0xa332, + /* 0x20740 */ + 0xa338, + /* 0x20800 */ + 0xa33f, 0xa341, + /* 0x20880 */ + 0xa34a, + /* 0x20940 */ + 0xa352, + /* 0x20980 */ + 0xa353, + /* 0x20AC0 */ + 0xa359, + /* 0x20B00 */ + 0xa35c, + /* 0x20B80 */ + 0x4f54, + /* 0x20D40 */ + 0xa377, + /* 0x20DC0 */ + 0xa42a, + /* 0x20E40 */ + 0xa43a, 0xa432, + /* 0x20E80 */ + 0xa431, + /* 0x20F40 */ + 0xa43d, + /* 0x21200 */ + 0xa459, 0x2f42, + /* 0x21240 */ + 0xa45c, 0xa463, 0xa45e, + /* 0x212C0 */ + 0xa46b, 0xa46a, 0xa472, + /* 0x21300 */ + 0x2f4c, 0xa474, + /* 0x21340 */ + 0xa475, + /* 0x213C0 */ + 0xa525, + /* 0x21440 */ + 0xa532, 0x2f60, + /* 0x215C0 */ + 0xa53e, + /* 0x21640 */ + 0xa547, + /* 0x21680 */ + 0x4f63, + /* 0x21700 */ + 0xa555, + /* 0x21740 */ + 0xa556, + /* 0x21880 */ + 0x2f7b, + /* 0x219C0 */ + 0xa57e, + /* 0x21C40 */ + 0xa830, + /* 0x21D00 */ + 0xa837, + /* 0x21D40 */ + 0xa838, 0xa83b, 0xa83a, + /* 0x21D80 */ + 0xa845, 0xa840, 0xa83f, 0xa848, + /* 0x21DC0 */ + 0xa84a, + /* 0x21E00 */ + 0xa84b, 0x4f6e, + /* 0x21F00 */ + 0xa85b, + /* 0x21F40 */ + 0xa866, + /* 0x21FC0 */ + 0xa86c, + /* 0x22140 */ + 0xac22, + /* 0x22200 */ + 0xfe53, + /* 0x22300 */ + 0xac2b, + /* 0x22380 */ + 0xac30, + /* 0x226C0 */ + 0xac50, + /* 0x22840 */ + 0xac65, + /* 0x22880 */ + 0xac6d, + /* 0x22980 */ + 0xac72, + /* 0x22A80 */ + 0xad24, + /* 0x22B40 */ + 0xad32, 0xad29, 0xad2a, + /* 0x22B80 */ + 0xad35, + /* 0x22C00 */ + 0xad34, 0xad39, + /* 0x22DC0 */ + 0xad56, + /* 0x23180 */ + 0xae24, + /* 0x231C0 */ + 0xad7d, 0x753a, 0xae23, + /* 0x23340 */ + 0xae3a, + /* 0x233C0 */ + 0xae42, 0xae3d, 0xae3c, 0xae44, 0xae47, 0xae49, 0xae43, + /* 0x23440 */ + 0xae55, 0xae57, 0xae56, 0xae5b, + /* 0x234C0 */ + 0xae77, + /* 0x23540 */ + 0xae78, + /* 0x23580 */ + 0xaf2a, + /* 0x235C0 */ + 0x7572, + /* 0x23600 */ + 0xaf42, 0xaf3f, 0xaf43, + /* 0x23640 */ + 0xaf40, + /* 0x23700 */ + 0xaf59, 0xaf4e, 0x7629, + /* 0x23740 */ + 0x7632, 0xaf61, + /* 0x237C0 */ + 0xaf6a, 0xaf69, + /* 0x23800 */ + 0xaf70, 0xaf75, + /* 0x23A80 */ + 0xee23, + /* 0x23C40 */ + 0xee34, + /* 0x23CC0 */ + 0x7660, + /* 0x23D00 */ + 0xee49, 0xf475, + /* 0x23D40 */ + 0xee5c, + /* 0x23DC0 */ + 0xee60, 0xee5f, 0xee5e, + /* 0x23F40 */ + 0xef32, + /* 0x24080 */ + 0xef47, + /* 0x24100 */ + 0xef4d, + /* 0x241C0 */ + 0xef61, 0xef64, + /* 0x24380 */ + 0xf022, + /* 0x24600 */ + 0xf033, + /* 0x24680 */ + 0xf039, + /* 0x247C0 */ + 0x776c, + /* 0x24880 */ + 0xf053, + /* 0x24A40 */ + 0xf07b, + /* 0x24B40 */ + 0xf12e, 0xf130, + /* 0x24C00 */ + 0xf135, + /* 0x24D00 */ + 0xf144, + /* 0x24E00 */ + 0xf15d, 0xf161, + /* 0x24E40 */ + 0xf166, + /* 0x24E80 */ + 0xf169, + /* 0x25040 */ + 0xf175, 0xf177, + /* 0x25100 */ + 0xf17a, + /* 0x25180 */ + 0xf221, + /* 0x251C0 */ + 0xf224, 0xf223, + /* 0x25200 */ + 0xf228, + /* 0x25240 */ + 0xf22c, + /* 0x25400 */ + 0xf23d, + /* 0x25480 */ + 0x787e, + /* 0x254C0 */ + 0xf248, + /* 0x25500 */ + 0x7929, + /* 0x25580 */ + 0xf25b, + /* 0x25740 */ + 0x7947, + /* 0x25780 */ + 0xf275, 0xf276, + /* 0x259C0 */ + 0x7954, 0xf332, + /* 0x25AC0 */ + 0xf33e, 0xf33d, 0xf340, + /* 0x25B80 */ + 0xf352, + /* 0x25C40 */ + 0xf35d, 0xf35e, + /* 0x25D80 */ + 0x796e, + /* 0x25E00 */ + 0xf373, + /* 0x25E40 */ + 0xf374, 0xf377, 0xf375, + /* 0x25EC0 */ + 0xf37d, 0xf37b, 0xf422, + /* 0x25F00 */ + 0xf424, + /* 0x25F40 */ + 0xf427, + /* 0x25FC0 */ + 0xf42f, 0xf42e, 0xf435, + /* 0x26000 */ + 0xf434, 0xf43d, + /* 0x26040 */ + 0xf442, + /* 0x260C0 */ + 0xf44f, + /* 0x26240 */ + 0xf469, + /* 0x26280 */ + 0xf46b, + /* 0x26340 */ + 0xf472, + /* 0x26400 */ + 0xf479, + /* 0x26640 */ + 0xf535, + /* 0x26680 */ + 0xf53a, + /* 0x26700 */ + 0xf546, + /* 0x268C0 */ + 0xf556, 0xf558, + /* 0x26940 */ + 0xf55a, 0xf55d, + /* 0x269C0 */ + 0xf55f, + /* 0x26A00 */ + 0xf563, + /* 0x26A40 */ + 0xf56a, + /* 0x26A80 */ + 0xf570, 0xf573, + /* 0x26AC0 */ + 0x7a5d, + /* 0x26C00 */ + 0xa544, + /* 0x26C40 */ + 0xf644, + /* 0x26CC0 */ + 0xf64e, + /* 0x26E40 */ + 0x7b33, 0xf65d, + /* 0x26F80 */ + 0xf675, + /* 0x26FC0 */ + 0xf721, 0xf722, 0xf67e, + /* 0x270C0 */ + 0x7b49, + /* 0x27100 */ + 0xf733, 0xf736, + /* 0x273C0 */ + 0xf765, 0xf764, 0xf76b, + /* 0x27400 */ + 0xf76e, + /* 0x27440 */ + 0xf773, + /* 0x27600 */ + 0xf82a, 0xf829, 0xf82c, + /* 0x27680 */ + 0x7b6c, 0xf834, + /* 0x27700 */ + 0xf83c, 0xf83e, + /* 0x27740 */ + 0xf842, + /* 0x27980 */ + 0xf856, + /* 0x27A80 */ + 0xf863, + /* 0x27B80 */ + 0xf877, 0xf879, + /* 0x27BC0 */ + 0xf87a, + /* 0x27C80 */ + 0xf925, + /* 0x27D80 */ + 0xf92f, + /* 0x27E00 */ + 0xf932, + /* 0x27F80 */ + 0xf939, + /* 0x28080 */ + 0xf942, 0xf948, + /* 0x28240 */ + 0x7c49, + /* 0x28280 */ + 0xf959, + /* 0x282C0 */ + 0xf95e, + /* 0x283C0 */ + 0x7c51, + /* 0x28400 */ + 0xf966, + /* 0x28440 */ + 0xf96b, + /* 0x28540 */ + 0xf97a, + /* 0x285C0 */ + 0xf97e, 0xfa21, + /* 0x286C0 */ + 0xfa2c, 0xfa2f, + /* 0x28940 */ + 0xfa50, 0xfa4f, 0xfa57, + /* 0x28980 */ + 0xfa65, 0xfa66, 0xfa71, 0xfa72, + /* 0x28A00 */ + 0xfa7e, 0xfb21, + /* 0x28A40 */ + 0xfb2d, 0xfb2c, + /* 0x28A80 */ + 0xfb36, + /* 0x28AC0 */ + 0xfb37, 0xfb3e, 0xfb3d, + /* 0x28BC0 */ + 0xfb4e, 0xfb4f, + /* 0x28D00 */ + 0xfb57, + /* 0x28D40 */ + 0xfb5a, + /* 0x28DC0 */ + 0xfb5c, + /* 0x28E00 */ + 0xfb5d, 0xfb61, + /* 0x28E80 */ + 0xfb65, + /* 0x28EC0 */ + 0xfb67, + /* 0x28F00 */ + 0xfb69, + /* 0x28FC0 */ + 0xfb71, + /* 0x29280 */ + 0xfc22, 0xfc23, + /* 0x29480 */ + 0xfc38, + /* 0x295C0 */ + 0xfc42, + /* 0x29640 */ + 0xfc4c, + /* 0x296C0 */ + 0xfc56, + /* 0x29700 */ + 0xfc59, + /* 0x29740 */ + 0xfc5d, + /* 0x298C0 */ + 0xfc76, + /* 0x29A40 */ + 0xfd2c, + /* 0x29DC0 */ + 0xfd4b, + /* 0x29E00 */ + 0xfd59, 0xfd4c, + /* 0x29E40 */ + 0xfd5d, + /* 0x29E80 */ + 0xfd5b, + /* 0x29EC0 */ + 0xfd67, 0xfd70, 0xfd6d, + /* 0x29FC0 */ + 0xfe25, + /* 0x2A000 */ + 0xfe2b, 0xfe29, + /* 0x2A080 */ + 0xfe35, + /* 0x2A0C0 */ + 0xfe32, + /* 0x2A180 */ + 0x7e66, + /* 0x2A380 */ + 0xfe58, + /* 0x2A400 */ + 0xfe5a, + /* 0x2A5C0 */ + 0xfe6e, + /* 0x2A600 */ + 0xfe70, 0xfe72, + /* 0x2A680 */ + 0xfe76, +}; + +static const Summary16 jisx0213_from_ucs_level2_2indx[] = { + /* 0x0080 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0xffdf }, { 15, 0xffdf }, + /* 0x00C0 */ + { 30, 0xffff }, { 46, 0xffff }, { 62, 0xffff }, { 78, 0xffff }, + /* 0x0100 */ + { 94, 0xf3ff }, { 108, 0x3f0e }, { 117, 0x0cb0 }, { 122, 0x6630 }, + /* 0x0140 */ + { 128, 0x399e }, { 137, 0xff3f }, { 151, 0xfc3f }, { 163, 0x7e03 }, + /* 0x0180 */ + { 171, 0x0000 }, { 171, 0x0008 }, { 172, 0x0000 }, { 172, 0x0000 }, + /* 0x01C0 */ + { 172, 0x6004 }, { 175, 0x1557 }, { 183, 0x0000 }, { 183, 0x2300 }, + /* 0x0240 */ + { 186, 0x0000 }, { 186, 0xd7ff }, { 200, 0xf1f3 }, { 211, 0x6e2f }, + /* 0x0280 */ + { 221, 0x7f1e }, { 232, 0x2137 }, { 239, 0x0006 }, { 241, 0x0000 }, + /* 0x02C0 */ + { 241, 0x1180 }, { 244, 0x6b03 }, { 251, 0x03e0 }, { 256, 0x0000 }, + /* 0x0300 */ + { 256, 0x995f }, { 266, 0xf700 }, { 273, 0x9631 }, { 280, 0x3e11 }, + /* 0x0340 */ + { 287, 0x0000 }, { 287, 0x0000 }, { 287, 0x0002 }, { 288, 0x0000 }, + /* 0x0380 */ + { 288, 0x0000 }, { 288, 0xfffe }, { 303, 0x03fb }, { 312, 0xfffe }, + /* 0x03C0 */ + { 327, 0x03ff }, { 337, 0x0000 }, { 337, 0x0000 }, { 337, 0x0000 }, + /* 0x0400 */ + { 337, 0x0002 }, { 338, 0xffff }, { 354, 0xffff }, { 370, 0xffff }, + /* 0x0440 */ + { 386, 0xffff }, { 402, 0x0002 }, { 403, 0x0000 }, { 403, 0x0000 }, + /* 0x1E00 */ + { 403, 0x0000 }, { 403, 0x0000 }, { 403, 0x0000 }, { 403, 0xc000 }, + /* 0x1F40 */ + { 405, 0x0000 }, { 405, 0x0000 }, { 405, 0x0000 }, { 405, 0x000f }, + /* 0x2000 */ + { 409, 0x0000 }, { 409, 0x3359 }, { 417, 0x0067 }, { 422, 0x980d }, + /* 0x2040 */ + { 428, 0x0384 }, { 432, 0x0002 }, { 433, 0x0000 }, { 433, 0x0000 }, + /* 0x2080 */ + { 433, 0x0000 }, { 433, 0x0000 }, { 433, 0x1000 }, { 434, 0x0000 }, + /* 0x2100 */ + { 434, 0x8008 }, { 436, 0x0048 }, { 438, 0x0882 }, { 441, 0x0020 }, + /* 0x2140 */ + { 442, 0x0000 }, { 442, 0x0038 }, { 445, 0x0fff }, { 457, 0x0fff }, + /* 0x2180 */ + { 469, 0x0000 }, { 469, 0x03df }, { 478, 0x0000 }, { 478, 0x0000 }, + /* 0x21C0 */ + { 478, 0x0010 }, { 479, 0x0014 }, { 481, 0x03c0 }, { 485, 0x0000 }, + /* 0x2200 */ + { 485, 0x0bad }, { 493, 0xe40c }, { 499, 0x5fe1 }, { 509, 0x2030 }, + /* 0x2240 */ + { 512, 0x0128 }, { 515, 0x0004 }, { 516, 0x0cc7 }, { 523, 0x00c0 }, + /* 0x2280 */ + { 525, 0x0cfc }, { 533, 0x00e0 }, { 536, 0x0020 }, { 537, 0x8000 }, + /* 0x22C0 */ + { 538, 0x0000 }, { 538, 0x0c00 }, { 540, 0x0000 }, { 540, 0x0000 }, + /* 0x2300 */ + { 540, 0x0060 }, { 542, 0x0104 }, { 544, 0x0000 }, { 544, 0x0000 }, + /* 0x2380 */ + { 544, 0x0000 }, { 544, 0x0000 }, { 544, 0x0000 }, { 544, 0xc000 }, + /* 0x23C0 */ + { 546, 0x5fff }, { 560, 0x0000 }, { 560, 0x0000 }, { 560, 0x0000 }, + /* 0x2400 */ + { 560, 0x0000 }, { 560, 0x0000 }, { 560, 0x0008 }, { 561, 0x0000 }, + /* 0x2440 */ + { 561, 0x0000 }, { 561, 0x0000 }, { 561, 0xffff }, { 577, 0x000f }, + /* 0x24C0 */ + { 581, 0x0000 }, { 581, 0xffff }, { 597, 0xfbff }, { 612, 0x7fff }, + /* 0x2500 */ + { 627, 0x900f }, { 633, 0x3999 }, { 641, 0x9939 }, { 649, 0x9999 }, + /* 0x2540 */ + { 657, 0x0804 }, { 659, 0x0000 }, { 659, 0x0000 }, { 659, 0x0000 }, + /* 0x2580 */ + { 659, 0x0000 }, { 659, 0x0000 }, { 659, 0x0003 }, { 661, 0x30ce }, + /* 0x25C0 */ + { 668, 0xcac3 }, { 676, 0x000f }, { 680, 0x8040 }, { 682, 0x0000 }, + /* 0x2600 */ + { 682, 0x406f }, { 689, 0x40c0 }, { 692, 0x0000 }, { 692, 0x0000 }, + /* 0x2640 */ + { 692, 0x0005 }, { 694, 0x0000 }, { 694, 0xffff }, { 710, 0x0000 }, + /* 0x2700 */ + { 710, 0x0000 }, { 710, 0x0008 }, { 711, 0x0000 }, { 711, 0x0000 }, + /* 0x2740 */ + { 711, 0x0000 }, { 711, 0x0040 }, { 712, 0x0000 }, { 712, 0xffc0 }, + /* 0x2900 */ + { 722, 0x0000 }, { 722, 0x0000 }, { 722, 0x0000 }, { 722, 0x0030 }, + /* 0x2980 */ + { 724, 0x0000 }, { 724, 0x0000 }, { 724, 0x0000 }, { 724, 0x8000 }, + /* 0x29C0 */ + { 725, 0x0000 }, { 725, 0x0000 }, { 725, 0x0000 }, { 725, 0x0c00 }, + /* 0x3000 */ + { 727, 0xffef }, { 742, 0xb3ff }, { 755, 0x0001 }, { 756, 0x3838 }, + /* 0x3040 */ + { 762, 0xfffe }, { 777, 0xffff }, { 793, 0xffff }, { 809, 0xffff }, + /* 0x3080 */ + { 825, 0xffff }, { 841, 0xf87f }, { 853, 0xffff }, { 869, 0xffff }, + /* 0x30C0 */ + { 885, 0xffff }, { 901, 0xffff }, { 917, 0xffff }, { 933, 0xffff }, + /* 0x31C0 */ + { 949, 0x0000 }, { 949, 0x0000 }, { 949, 0x0000 }, { 949, 0xffff }, + /* 0x3200 */ + { 965, 0x0000 }, { 965, 0x0000 }, { 965, 0x0000 }, { 965, 0x0206 }, + /* 0x3240 */ + { 968, 0x0000 }, { 968, 0xfffe }, { 983, 0x0000 }, { 983, 0x0000 }, + /* 0x3280 */ + { 983, 0x0000 }, { 983, 0x0000 }, { 983, 0x01f0 }, { 988, 0xfffe }, + /* 0x32C0 */ + { 1003, 0x0000 }, { 1003, 0xffff }, { 1019, 0x322f }, { 1027, 0x0400 }, + /* 0x3300 */ + { 1028, 0x2008 }, { 1030, 0x0110 }, { 1032, 0x08cc }, { 1037, 0x0840 }, + /* 0x3340 */ + { 1039, 0x2600 }, { 1042, 0x0082 }, { 1044, 0x0000 }, { 1044, 0x7800 }, + /* 0x3380 */ + { 1048, 0xc000 }, { 1050, 0x7000 }, { 1053, 0x0002 }, { 1054, 0x0000 }, + /* 0x33C0 */ + { 1054, 0x2810 }, { 1057, 0x0000 }, { 1057, 0x0000 }, { 1057, 0x0000 }, + /* 0x3400 */ + { 1057, 0x0044 }, { 1059, 0x0000 }, { 1059, 0x5000 }, { 1061, 0x0000 }, + /* 0x3440 */ + { 1061, 0x0000 }, { 1061, 0x0000 }, { 1061, 0x0500 }, { 1063, 0x0000 }, + /* 0x3480 */ + { 1063, 0x0000 }, { 1063, 0x0004 }, { 1064, 0x0000 }, { 1064, 0x1020 }, + /* 0x34C0 */ + { 1066, 0x0082 }, { 1068, 0x0800 }, { 1069, 0x0000 }, { 1069, 0x0000 }, + /* 0x3500 */ + { 1069, 0x0000 }, { 1069, 0x8000 }, { 1070, 0x0000 }, { 1070, 0x0000 }, + /* 0x3540 */ + { 1070, 0x0000 }, { 1070, 0x6000 }, { 1072, 0x4008 }, { 1074, 0x0000 }, + /* 0x3580 */ + { 1074, 0x0000 }, { 1074, 0x0000 }, { 1074, 0x0140 }, { 1076, 0x0000 }, + /* 0x35C0 */ + { 1076, 0x0020 }, { 1077, 0x0400 }, { 1078, 0x0000 }, { 1078, 0x0010 }, + /* 0x3600 */ + { 1079, 0x0020 }, { 1080, 0x0000 }, { 1080, 0x0000 }, { 1080, 0x0000 }, + /* 0x3640 */ + { 1080, 0x0400 }, { 1081, 0x0000 }, { 1081, 0x0000 }, { 1081, 0x0000 }, + /* 0x3680 */ + { 1081, 0x0000 }, { 1081, 0x0242 }, { 1084, 0x0000 }, { 1084, 0x0000 }, + /* 0x36C0 */ + { 1084, 0x8000 }, { 1085, 0x0000 }, { 1085, 0x0000 }, { 1085, 0x0000 }, + /* 0x3740 */ + { 1085, 0x0000 }, { 1085, 0x0000 }, { 1085, 0x1806 }, { 1089, 0x0020 }, + /* 0x3780 */ + { 1090, 0x2000 }, { 1091, 0x0000 }, { 1091, 0x0000 }, { 1091, 0x0000 }, + /* 0x37C0 */ + { 1091, 0x0002 }, { 1092, 0x0000 }, { 1092, 0x0104 }, { 1094, 0x2010 }, + /* 0x3800 */ + { 1096, 0x0001 }, { 1097, 0x0000 }, { 1097, 0x8000 }, { 1098, 0x0040 }, + /* 0x3840 */ + { 1099, 0x0001 }, { 1100, 0x1000 }, { 1101, 0x0002 }, { 1102, 0x0000 }, + /* 0x38C0 */ + { 1102, 0x0000 }, { 1102, 0x0000 }, { 1102, 0x0000 }, { 1102, 0x0400 }, + /* 0x3900 */ + { 1103, 0x0000 }, { 1103, 0x0480 }, { 1105, 0x0000 }, { 1105, 0x0000 }, + /* 0x3940 */ + { 1105, 0x0000 }, { 1105, 0x0000 }, { 1105, 0x8000 }, { 1106, 0x0000 }, + /* 0x3A40 */ + { 1106, 0x0000 }, { 1106, 0x0000 }, { 1106, 0x4000 }, { 1107, 0x0008 }, + /* 0x3AC0 */ + { 1108, 0x0000 }, { 1108, 0x00c0 }, { 1110, 0x0400 }, { 1111, 0x0000 }, + /* 0x3B00 */ + { 1111, 0x4000 }, { 1112, 0x1400 }, { 1114, 0x0004 }, { 1115, 0x0000 }, + /* 0x3B40 */ + { 1115, 0x0000 }, { 1115, 0x0000 }, { 1115, 0x2000 }, { 1116, 0x0080 }, + /* 0x3B80 */ + { 1117, 0x2180 }, { 1120, 0x0000 }, { 1120, 0x0010 }, { 1121, 0x0040 }, + /* 0x3BC0 */ + { 1122, 0x2008 }, { 1124, 0x0000 }, { 1124, 0x0000 }, { 1124, 0x0001 }, + /* 0x3C00 */ + { 1125, 0x8000 }, { 1126, 0x0000 }, { 1126, 0x0040 }, { 1127, 0x0000 }, + /* 0x3CC0 */ + { 1127, 0x0008 }, { 1128, 0x0004 }, { 1129, 0x0000 }, { 1129, 0x0000 }, + /* 0x3D00 */ + { 1129, 0x0000 }, { 1129, 0x4002 }, { 1131, 0x0000 }, { 1131, 0x0000 }, + /* 0x3D40 */ + { 1131, 0x0000 }, { 1131, 0x0000 }, { 1131, 0x0010 }, { 1132, 0x0000 }, + /* 0x3D80 */ + { 1132, 0x0000 }, { 1132, 0x0400 }, { 1133, 0x0000 }, { 1133, 0x0000 }, + /* 0x3DC0 */ + { 1133, 0x0001 }, { 1134, 0x0010 }, { 1135, 0x0000 }, { 1135, 0x0000 }, + /* 0x3E00 */ + { 1135, 0x0020 }, { 1136, 0x0000 }, { 1136, 0x0000 }, { 1136, 0x8000 }, + /* 0x3E40 */ + { 1137, 0x0000 }, { 1137, 0x0000 }, { 1137, 0x0141 }, { 1140, 0x0000 }, + /* 0x3E80 */ + { 1140, 0x0008 }, { 1141, 0x0010 }, { 1142, 0x0000 }, { 1142, 0x0000 }, + /* 0x3F40 */ + { 1142, 0x0000 }, { 1142, 0x0080 }, { 1143, 0x0000 }, { 1143, 0x00a4 }, + /* 0x3F80 */ + { 1146, 0x0000 }, { 1146, 0x0000 }, { 1146, 0x4000 }, { 1147, 0x0000 }, + /* 0x3FC0 */ + { 1147, 0x0200 }, { 1148, 0x0080 }, { 1149, 0x0000 }, { 1149, 0x0000 }, + /* 0x4000 */ + { 1149, 0x0000 }, { 1149, 0x0000 }, { 1149, 0x0000 }, { 1149, 0x0200 }, + /* 0x4040 */ + { 1150, 0x0000 }, { 1150, 0x0100 }, { 1151, 0x0000 }, { 1151, 0x0000 }, + /* 0x4080 */ + { 1151, 0x0000 }, { 1151, 0x0008 }, { 1152, 0x0000 }, { 1152, 0x0000 }, + /* 0x4100 */ + { 1152, 0x0020 }, { 1153, 0x0000 }, { 1153, 0x0000 }, { 1153, 0x0000 }, + /* 0x4140 */ + { 1153, 0x8100 }, { 1155, 0x0000 }, { 1155, 0x0008 }, { 1156, 0x0000 }, + /* 0x4180 */ + { 1156, 0x0000 }, { 1156, 0x0000 }, { 1156, 0x0000 }, { 1156, 0x8010 }, + /* 0x41C0 */ + { 1158, 0x0000 }, { 1158, 0x0000 }, { 1158, 0x4040 }, { 1160, 0x0008 }, + /* 0x4200 */ + { 1161, 0x4080 }, { 1163, 0x0000 }, { 1163, 0x0000 }, { 1163, 0x0000 }, + /* 0x4240 */ + { 1163, 0x0000 }, { 1163, 0x0000 }, { 1163, 0x0010 }, { 1164, 0x0000 }, + /* 0x42C0 */ + { 1164, 0x0040 }, { 1165, 0x2040 }, { 1167, 0x0000 }, { 1167, 0x0000 }, + /* 0x4300 */ + { 1167, 0x0004 }, { 1168, 0x0000 }, { 1168, 0x0800 }, { 1169, 0x0000 }, + /* 0x4340 */ + { 1169, 0x0008 }, { 1170, 0x0000 }, { 1170, 0x0000 }, { 1170, 0x0000 }, + /* 0x43C0 */ + { 1170, 0x0000 }, { 1170, 0x0000 }, { 1170, 0x4000 }, { 1171, 0x0001 }, + /* 0x4400 */ + { 1172, 0x0100 }, { 1173, 0x1080 }, { 1175, 0x0004 }, { 1176, 0x0000 }, + /* 0x4440 */ + { 1176, 0x0000 }, { 1176, 0x0808 }, { 1178, 0x0000 }, { 1178, 0x0440 }, + /* 0x4480 */ + { 1180, 0x0000 }, { 1180, 0x0002 }, { 1181, 0x0000 }, { 1181, 0x4008 }, + /* 0x44C0 */ + { 1183, 0x0000 }, { 1183, 0x0010 }, { 1184, 0x0000 }, { 1184, 0x0000 }, + /* 0x4500 */ + { 1184, 0x2100 }, { 1186, 0x0000 }, { 1186, 0x0020 }, { 1187, 0x0000 }, + /* 0x4540 */ + { 1187, 0x0008 }, { 1188, 0x0000 }, { 1188, 0x0000 }, { 1188, 0x0000 }, + /* 0x4580 */ + { 1188, 0x0000 }, { 1188, 0x2000 }, { 1189, 0x0000 }, { 1189, 0x0100 }, + /* 0x45C0 */ + { 1190, 0x0000 }, { 1190, 0x0000 }, { 1190, 0x0420 }, { 1192, 0x0000 }, + /* 0x4600 */ + { 1192, 0x8000 }, { 1193, 0x0000 }, { 1193, 0x0000 }, { 1193, 0x0000 }, + /* 0x4640 */ + { 1193, 0x0002 }, { 1194, 0x0000 }, { 1194, 0x0020 }, { 1195, 0x0000 }, + /* 0x4680 */ + { 1195, 0x0000 }, { 1195, 0x0000 }, { 1195, 0x8002 }, { 1197, 0x0000 }, + /* 0x4700 */ + { 1197, 0x1000 }, { 1198, 0x0000 }, { 1198, 0x0000 }, { 1198, 0x0000 }, + /* 0x4740 */ + { 1198, 0x0000 }, { 1198, 0x0000 }, { 1198, 0x0010 }, { 1199, 0x0000 }, + /* 0x47C0 */ + { 1199, 0x0000 }, { 1199, 0x0000 }, { 1199, 0x0000 }, { 1199, 0x2000 }, + /* 0x4800 */ + { 1200, 0x0000 }, { 1200, 0x0040 }, { 1201, 0x0000 }, { 1201, 0x0000 }, + /* 0x4840 */ + { 1201, 0x4010 }, { 1203, 0x0000 }, { 1203, 0x0000 }, { 1203, 0x0000 }, + /* 0x4880 */ + { 1203, 0x0000 }, { 1203, 0x0000 }, { 1203, 0x0000 }, { 1203, 0x0020 }, + /* 0x4980 */ + { 1204, 0x0000 }, { 1204, 0x0000 }, { 1204, 0x0000 }, { 1204, 0x0001 }, + /* 0x49C0 */ + { 1205, 0x0000 }, { 1205, 0x0000 }, { 1205, 0x0080 }, { 1206, 0x0400 }, + /* 0x4A00 */ + { 1207, 0x0010 }, { 1208, 0x0000 }, { 1208, 0x0200 }, { 1209, 0x0000 }, + /* 0x4A80 */ + { 1209, 0x0000 }, { 1209, 0x0000 }, { 1209, 0x0000 }, { 1209, 0x1000 }, + /* 0x4B00 */ + { 1210, 0x0000 }, { 1210, 0x0000 }, { 1210, 0x0000 }, { 1210, 0x0800 }, + /* 0x4BC0 */ + { 1211, 0x0404 }, { 1213, 0x0004 }, { 1214, 0x0100 }, { 1215, 0x0000 }, + /* 0x4C00 */ + { 1215, 0x0000 }, { 1215, 0x0080 }, { 1216, 0x0001 }, { 1217, 0x0000 }, + /* 0x4CC0 */ + { 1217, 0x0010 }, { 1218, 0x0002 }, { 1219, 0x0000 }, { 1219, 0x0000 }, + /* 0x4D00 */ + { 1219, 0x0080 }, { 1220, 0x0000 }, { 1220, 0x0000 }, { 1220, 0x0000 }, + /* 0x4D40 */ + { 1220, 0x0000 }, { 1220, 0x0000 }, { 1220, 0x0000 }, { 1220, 0x0080 }, + /* 0x4E00 */ + { 1221, 0xef8f }, { 1233, 0x43f7 }, { 1243, 0xff42 }, { 1253, 0x9b47 }, + /* 0x4E40 */ + { 1262, 0xe9ad }, { 1272, 0xe7e2 }, { 1282, 0x0204 }, { 1284, 0x400a }, + /* 0x4E80 */ + { 1287, 0x7f65 }, { 1298, 0xfb36 }, { 1309, 0x7977 }, { 1320, 0x1e49 }, + /* 0x4EC0 */ + { 1327, 0xeddf }, { 1340, 0xe7f1 }, { 1351, 0x683a }, { 1358, 0xa8e7 }, + /* 0x4F00 */ + { 1367, 0xee0b }, { 1376, 0x3443 }, { 1382, 0x8000 }, { 1383, 0x75d1 }, + /* 0x4F40 */ + { 1392, 0xe3c8 }, { 1400, 0xfffb }, { 1415, 0x9611 }, { 1421, 0xfde9 }, + /* 0x4F80 */ + { 1433, 0xad6c }, { 1442, 0x2dd6 }, { 1451, 0xe803 }, { 1457, 0xc064 }, + /* 0x4FC0 */ + { 1462, 0xce3c }, { 1471, 0xad97 }, { 1481, 0xc07b }, { 1489, 0x456e }, + /* 0x5000 */ + { 1497, 0xea67 }, { 1507, 0xd75f }, { 1519, 0x7ffe }, { 1533, 0x0a40 }, + /* 0x5040 */ + { 1536, 0xc3cf }, { 1546, 0x14e9 }, { 1553, 0x1468 }, { 1558, 0x2175 }, + /* 0x5080 */ + { 1565, 0x2121 }, { 1569, 0x177e }, { 1579, 0x3408 }, { 1583, 0x4cbe }, + /* 0x50C0 */ + { 1592, 0xf6b4 }, { 1602, 0x4673 }, { 1610, 0x62ea }, { 1618, 0x0a2c }, + /* 0x5100 */ + { 1623, 0x0b5f }, { 1632, 0xcdf4 }, { 1642, 0x0402 }, { 1644, 0x9ca4 }, + /* 0x5140 */ + { 1651, 0x7ffb }, { 1665, 0x14b5 }, { 1672, 0x7f25 }, { 1682, 0x19ea }, + /* 0x5180 */ + { 1690, 0xbe6d }, { 1701, 0x23ef }, { 1711, 0x3f7d }, { 1723, 0x30ff }, + /* 0x51C0 */ + { 1733, 0x3e78 }, { 1742, 0x7840 }, { 1747, 0x66c7 }, { 1756, 0x677b }, + /* 0x5200 */ + { 1767, 0x4ddf }, { 1778, 0x20fe }, { 1786, 0x46b0 }, { 1792, 0x0fc9 }, + /* 0x5240 */ + { 1800, 0xbe98 }, { 1809, 0x78f0 }, { 1817, 0x963a }, { 1825, 0xa0bf }, + /* 0x5280 */ + { 1834, 0x239c }, { 1841, 0x891e }, { 1848, 0xbe59 }, { 1858, 0x5e32 }, + /* 0x52C0 */ + { 1866, 0x37aa }, { 1875, 0xebe7 }, { 1887, 0x00dd }, { 1893, 0xcfad }, + /* 0x5300 */ + { 1904, 0xade7 }, { 1915, 0x36e1 }, { 1923, 0x841b }, { 1929, 0xcf2a }, + /* 0x5340 */ + { 1938, 0x27ef }, { 1949, 0x559e }, { 1958, 0xd2cb }, { 1967, 0xadbb }, + /* 0x5380 */ + { 1978, 0x0014 }, { 1980, 0xa548 }, { 1986, 0x6371 }, { 1994, 0x08dd }, + /* 0x53C0 */ + { 2001, 0x7f0d }, { 2011, 0x8ef0 }, { 2019, 0xff3e }, { 2032, 0x05ff }, + /* 0x5400 */ + { 2042, 0xff1a }, { 2053, 0xe807 }, { 2060, 0x7bd1 }, { 2070, 0x7b40 }, + /* 0x5440 */ + { 2077, 0x674d }, { 2086, 0x8022 }, { 2089, 0x1d44 }, { 2095, 0xb8fb }, + /* 0x5480 */ + { 2106, 0xfd51 }, { 2116, 0x1065 }, { 2121, 0xfb77 }, { 2134, 0xf58c }, + /* 0x54C0 */ + { 2143, 0x03df }, { 2152, 0x0100 }, { 2153, 0xf366 }, { 2163, 0xa40e }, + /* 0x5500 */ + { 2169, 0xc2d3 }, { 2177, 0x0051 }, { 2180, 0xc800 }, { 2183, 0x532a }, + /* 0x5540 */ + { 2190, 0x94f3 }, { 2199, 0x70c9 }, { 2206, 0x001b }, { 2210, 0x7800 }, + /* 0x5580 */ + { 2214, 0x4fdf }, { 2226, 0xf702 }, { 2234, 0x7f80 }, { 2242, 0x8041 }, + /* 0x55C0 */ + { 2245, 0x52b0 }, { 2251, 0xb416 }, { 2258, 0x021c }, { 2262, 0x6280 }, + /* 0x5600 */ + { 2266, 0x43c0 }, { 2271, 0x09d1 }, { 2277, 0x8300 }, { 2280, 0xa9d7 }, + /* 0x5640 */ + { 2290, 0x5285 }, { 2296, 0x4809 }, { 2300, 0xbd51 }, { 2309, 0x0556 }, + /* 0x5680 */ + { 2315, 0x95c1 }, { 2322, 0x6630 }, { 2328, 0x7325 }, { 2336, 0x105c }, + /* 0x56C0 */ + { 2341, 0x672f }, { 2351, 0xcd8a }, { 2359, 0x4109 }, { 2363, 0xa6cd }, + /* 0x5700 */ + { 2372, 0xaf19 }, { 2381, 0x916c }, { 2388, 0xa3ca }, { 2396, 0x0999 }, + /* 0x5740 */ + { 2402, 0xf4e5 }, { 2412, 0x0003 }, { 2414, 0x8752 }, { 2421, 0x98b9 }, + /* 0x5780 */ + { 2429, 0x0b04 }, { 2433, 0x7408 }, { 2438, 0x151d }, { 2445, 0x0109 }, + /* 0x57C0 */ + { 2448, 0xd9c9 }, { 2457, 0xd0dc }, { 2465, 0x2059 }, { 2470, 0xbff1 }, + /* 0x5800 */ + { 2482, 0x0e75 }, { 2490, 0x6220 }, { 2494, 0x8493 }, { 2500, 0x2637 }, + /* 0x5840 */ + { 2508, 0x1e03 }, { 2514, 0x4796 }, { 2522, 0x0a96 }, { 2528, 0x5225 }, + /* 0x5880 */ + { 2534, 0xae28 }, { 2541, 0xf099 }, { 2549, 0x4f00 }, { 2554, 0x4f0a }, + /* 0x58C0 */ + { 2561, 0x74aa }, { 2569, 0xd7be }, { 2581, 0xda35 }, { 2590, 0x3e9f }, + /* 0x5900 */ + { 2601, 0xbe64 }, { 2610, 0x1f71 }, { 2619, 0x7eb4 }, { 2629, 0x6186 }, + /* 0x5940 */ + { 2635, 0xc3d0 }, { 2642, 0xadb3 }, { 2652, 0x77a5 }, { 2662, 0x3178 }, + /* 0x5980 */ + { 2669, 0x2c1e }, { 2676, 0xaa4c }, { 2683, 0x5138 }, { 2689, 0x5a04 }, + /* 0x59C0 */ + { 2694, 0x2b48 }, { 2700, 0x761f }, { 2710, 0x4df8 }, { 2719, 0x8940 }, + /* 0x5A00 */ + { 2723, 0x320a }, { 2728, 0x958a }, { 2735, 0xa2a9 }, { 2742, 0x1060 }, + /* 0x5A40 */ + { 2745, 0x0243 }, { 2749, 0x0420 }, { 2751, 0x34e4 }, { 2758, 0xc480 }, + /* 0x5A80 */ + { 2762, 0x0810 }, { 2764, 0xdc04 }, { 2770, 0x0085 }, { 2773, 0xf42a }, + /* 0x5AC0 */ + { 2781, 0x1a16 }, { 2787, 0x14c1 }, { 2792, 0x426b }, { 2799, 0x0c21 }, + /* 0x5B00 */ + { 2803, 0x1b01 }, { 2808, 0x02c0 }, { 2811, 0x3424 }, { 2816, 0x4055 }, + /* 0x5B40 */ + { 2821, 0x102b }, { 2826, 0xbdf7 }, { 2839, 0x8b78 }, { 2847, 0xb52b }, + /* 0x5B80 */ + { 2856, 0xbbbb }, { 2868, 0xbfe8 }, { 2879, 0x507c }, { 2886, 0x8379 }, + /* 0x5BC0 */ + { 2894, 0x52fd }, { 2904, 0xe95d }, { 2914, 0x5bf6 }, { 2925, 0xe56b }, + /* 0x5C00 */ + { 2935, 0xeffe }, { 2949, 0x444e }, { 2955, 0x2b1d }, { 2963, 0xff03 }, + /* 0x5C40 */ + { 2973, 0xed63 }, { 2983, 0xc82b }, { 2990, 0xd3bf }, { 3002, 0x1643 }, + /* 0x5C80 */ + { 3008, 0x9500 }, { 3012, 0x8013 }, { 3016, 0x3fcf }, { 3028, 0x5dea }, + /* 0x5CC0 */ + { 3038, 0x0aa0 }, { 3042, 0x0205 }, { 3045, 0xa703 }, { 3052, 0x2c51 }, + /* 0x5D00 */ + { 3058, 0x68c0 }, { 3063, 0xaff3 }, { 3075, 0x0ad5 }, { 3082, 0x0202 }, + /* 0x5D40 */ + { 3084, 0x5cc4 }, { 3091, 0x100d }, { 3095, 0xb602 }, { 3101, 0x0049 }, + /* 0x5D80 */ + { 3104, 0x1996 }, { 3111, 0x2295 }, { 3117, 0x5095 }, { 3123, 0x3795 }, + /* 0x5DC0 */ + { 3132, 0x3a00 }, { 3136, 0x69ce }, { 3145, 0x4bff }, { 3157, 0x68be }, + /* 0x5E00 */ + { 3166, 0x184d }, { 3172, 0xaf76 }, { 3183, 0xe820 }, { 3188, 0x61c9 }, + /* 0x5E40 */ + { 3195, 0x52b9 }, { 3203, 0xc1f0 }, { 3210, 0x781e }, { 3218, 0xfffc }, + /* 0x5E80 */ + { 3232, 0x849a }, { 3238, 0x14e0 }, { 3243, 0x3ce1 }, { 3251, 0xc3e0 }, + /* 0x5EC0 */ + { 3258, 0x8f4e }, { 3267, 0xae4d }, { 3276, 0x130f }, { 3283, 0xffdb }, + /* 0x5F00 */ + { 3297, 0xff9f }, { 3311, 0xf9fb }, { 3324, 0xa2e8 }, { 3331, 0x71f2 }, + /* 0x5F40 */ + { 3340, 0x55a3 }, { 3348, 0x33da }, { 3357, 0x3ede }, { 3368, 0xf28f }, + /* 0x5F80 */ + { 3378, 0x9fbf }, { 3391, 0x538f }, { 3400, 0xe797 }, { 3411, 0x33b8 }, + /* 0x5FC0 */ + { 3419, 0x3ab8 }, { 3427, 0x73dc }, { 3437, 0xca17 }, { 3445, 0xb92b }, + /* 0x6000 */ + { 3454, 0xe000 }, { 3457, 0x3bf5 }, { 3468, 0x8ff7 }, { 3480, 0x042a }, + /* 0x6040 */ + { 3484, 0x3cce }, { 3493, 0x8625 }, { 3499, 0xbf3d }, { 3511, 0x80a1 }, + /* 0x6080 */ + { 3515, 0x3e1a }, { 3523, 0xecf4 }, { 3533, 0x07c9 }, { 3540, 0x717f }, + /* 0x60C0 */ + { 3551, 0x09e0 }, { 3556, 0xbf3a }, { 3567, 0x418b }, { 3573, 0x0fff }, + /* 0x6100 */ + { 3585, 0xe34b }, { 3594, 0xde2d }, { 3604, 0x1982 }, { 3609, 0xf491 }, + /* 0x6140 */ + { 3617, 0x7dd6 }, { 3628, 0xa728 }, { 3635, 0xc9ad }, { 3644, 0x50fb }, + /* 0x6180 */ + { 3653, 0x6484 }, { 3658, 0x07df }, { 3668, 0x7bb0 }, { 3677, 0x5644 }, + /* 0x61C0 */ + { 3683, 0x3fc8 }, { 3692, 0xa021 }, { 3696, 0x0048 }, { 3698, 0xf5f4 }, + /* 0x6200 */ + { 3709, 0x7701 }, { 3716, 0xec77 }, { 3727, 0xc64e }, { 3735, 0xc91d }, + /* 0x6240 */ + { 3743, 0x7bcb }, { 3754, 0x4d6e }, { 3763, 0xe11b }, { 3771, 0xda4a }, + /* 0x6280 */ + { 3779, 0x063d }, { 3786, 0x5bfe }, { 3798, 0x1840 }, { 3801, 0x3a22 }, + /* 0x62C0 */ + { 3807, 0xb7f4 }, { 3818, 0x3bff }, { 3831, 0xf003 }, { 3837, 0xf0ea }, + /* 0x6300 */ + { 3846, 0x378e }, { 3855, 0x8303 }, { 3860, 0x8980 }, { 3864, 0xfe24 }, + /* 0x6340 */ + { 3873, 0xf21a }, { 3881, 0x12a1 }, { 3886, 0x5ba0 }, { 3893, 0x1cc4 }, + /* 0x6380 */ + { 3899, 0xd319 }, { 3907, 0x8b54 }, { 3914, 0x1faf }, { 3925, 0x6834 }, + /* 0x63C0 */ + { 3931, 0x8259 }, { 3937, 0x1c75 }, { 3945, 0x7a2b }, { 3954, 0x04f4 }, + /* 0x6400 */ + { 3960, 0xa240 }, { 3964, 0x50d9 }, { 3971, 0xb364 }, { 3979, 0x4450 }, + /* 0x6440 */ + { 3983, 0x4004 }, { 3985, 0x2d02 }, { 3990, 0xa281 }, { 3995, 0x2748 }, + /* 0x6480 */ + { 4001, 0x0188 }, { 4004, 0xe42e }, { 4012, 0x6a30 }, { 4018, 0xda05 }, + /* 0x64C0 */ + { 4025, 0x7cb6 }, { 4035, 0x05b5 }, { 4042, 0x90ff }, { 4052, 0xecd6 }, + /* 0x6500 */ + { 4062, 0x8031 }, { 4066, 0x7150 }, { 4072, 0x9e1c }, { 4080, 0xcbf4 }, + /* 0x6540 */ + { 4090, 0xa130 }, { 4095, 0x63f2 }, { 4104, 0x18cc }, { 4110, 0x05b5 }, + /* 0x6580 */ + { 4117, 0x57be }, { 4128, 0xba83 }, { 4136, 0xb8b2 }, { 4144, 0xb3a5 }, + /* 0x65C0 */ + { 4153, 0x9a7e }, { 4163, 0x0a94 }, { 4168, 0x33e7 }, { 4178, 0x1e06 }, + /* 0x6600 */ + { 4184, 0xd7dd }, { 4196, 0xd038 }, { 4202, 0xadb7 }, { 4213, 0x947b }, + /* 0x6640 */ + { 4222, 0xdb3e }, { 4233, 0xee86 }, { 4242, 0xfffe }, { 4257, 0x0dd9 }, + /* 0x6680 */ + { 4265, 0x639b }, { 4274, 0x23c7 }, { 4282, 0x6845 }, { 4288, 0xdb36 }, + /* 0x66C0 */ + { 4298, 0x03d2 }, { 4304, 0x3e40 }, { 4310, 0x1341 }, { 4315, 0xffbd }, + /* 0x6700 */ + { 4329, 0xab2b }, { 4338, 0xeafc }, { 4349, 0x7dc0 }, { 4357, 0xa5da }, + /* 0x6740 */ + { 4366, 0xf3c2 }, { 4375, 0xf25b }, { 4385, 0xa47f }, { 4395, 0xd8ff }, + /* 0x6780 */ + { 4407, 0x1aa2 }, { 4413, 0x3dad }, { 4423, 0x8247 }, { 4429, 0x0bdd }, + /* 0x67C0 */ + { 4438, 0xc55b }, { 4447, 0x6f9f }, { 4459, 0xd294 }, { 4466, 0xdabb }, + /* 0x6800 */ + { 4477, 0x001e }, { 4481, 0xe1c9 }, { 4489, 0x3e06 }, { 4496, 0x7b1e }, + /* 0x6840 */ + { 4506, 0x737f }, { 4518, 0xbabf }, { 4530, 0x4888 }, { 4534, 0xd4f4 }, + /* 0x6880 */ + { 4543, 0xa02e }, { 4549, 0xbfd9 }, { 4561, 0xaded }, { 4572, 0x1e7f }, + /* 0x68C0 */ + { 4583, 0xbf78 }, { 4594, 0x87f5 }, { 4604, 0xf1bb }, { 4615, 0x1e87 }, + /* 0x6900 */ + { 4623, 0xfdbb }, { 4636, 0x1e04 }, { 4641, 0x056e }, { 4648, 0xaa71 }, + /* 0x6940 */ + { 4656, 0x0644 }, { 4660, 0x76b8 }, { 4669, 0xff1f }, { 4682, 0xf7bc }, + /* 0x6980 */ + { 4694, 0x4407 }, { 4699, 0x1976 }, { 4707, 0x60e1 }, { 4713, 0xdc97 }, + /* 0x69C0 */ + { 4723, 0xfc8b }, { 4733, 0x634b }, { 4741, 0xef8c }, { 4751, 0xea7c }, + /* 0x6A00 */ + { 4761, 0x9c24 }, { 4767, 0xeebe }, { 4779, 0x4e0e }, { 4786, 0xef7d }, + /* 0x6A40 */ + { 4799, 0x4bf0 }, { 4807, 0x8b45 }, { 4814, 0x0856 }, { 4819, 0xc50c }, + /* 0x6A80 */ + { 4825, 0x6a19 }, { 4832, 0xf093 }, { 4840, 0x5c2f }, { 4849, 0x2908 }, + /* 0x6AC0 */ + { 4853, 0x004e }, { 4857, 0xfc1b }, { 4867, 0x1590 }, { 4872, 0x2c0e }, + /* 0x6B00 */ + { 4878, 0x8c30 }, { 4883, 0xe8c7 }, { 4892, 0x908b }, { 4898, 0x67a4 }, + /* 0x6B40 */ + { 4906, 0x56c8 }, { 4913, 0x8b59 }, { 4921, 0x96ff }, { 4933, 0x8fb8 }, + /* 0x6B80 */ + { 4942, 0x2e5f }, { 4952, 0x4960 }, { 4957, 0xee10 }, { 4964, 0xfcbe }, + /* 0x6BC0 */ + { 4976, 0xebe1 }, { 4986, 0x8ddc }, { 4995, 0xd8c0 }, { 5001, 0x800a }, + /* 0x6C00 */ + { 5004, 0xc524 }, { 5010, 0x089b }, { 5016, 0x0018 }, { 5018, 0xc5f8 }, + /* 0x6C40 */ + { 5027, 0x6007 }, { 5032, 0xfea1 }, { 5042, 0x2585 }, { 5048, 0x645d }, + /* 0x6C80 */ + { 5056, 0x337e }, { 5066, 0x1ffd }, { 5078, 0x6c06 }, { 5084, 0xff0a }, + /* 0x6CC0 */ + { 5094, 0x1676 }, { 5102, 0x3ef9 }, { 5113, 0xff2f }, { 5126, 0x080b }, + /* 0x6D00 */ + { 5130, 0x5c11 }, { 5136, 0xca84 }, { 5142, 0xcef0 }, { 5151, 0xfb7e }, + /* 0x6D40 */ + { 5164, 0x0032 }, { 5167, 0x5f00 }, { 5173, 0x5679 }, { 5182, 0x0391 }, + /* 0x6D80 */ + { 5187, 0x77a7 }, { 5198, 0x1b3a }, { 5206, 0xdc00 }, { 5211, 0x9134 }, + /* 0x6DC0 */ + { 5217, 0xd9f5 }, { 5228, 0xef67 }, { 5240, 0x5f52 }, { 5249, 0x1eea }, + /* 0x6E00 */ + { 5258, 0x0fa0 }, { 5264, 0xeea8 }, { 5273, 0xfaff }, { 5287, 0x5554 }, + /* 0x6E40 */ + { 5294, 0xff18 }, { 5304, 0xd9da }, { 5314, 0xc888 }, { 5319, 0xc044 }, + /* 0x6E80 */ + { 5323, 0x9005 }, { 5327, 0xb149 }, { 5334, 0x8ca4 }, { 5340, 0xa4d6 }, + /* 0x6EC0 */ + { 5348, 0x5ebe }, { 5359, 0x623a }, { 5366, 0x9800 }, { 5369, 0xcb94 }, + /* 0x6F00 */ + { 5377, 0x9646 }, { 5384, 0x053b }, { 5391, 0x9c2d }, { 5399, 0xd16e }, + /* 0x6F40 */ + { 5408, 0x0022 }, { 5410, 0xdf96 }, { 5421, 0xe157 }, { 5430, 0x7511 }, + /* 0x6F80 */ + { 5437, 0x7157 }, { 5446, 0x81d3 }, { 5453, 0x84bb }, { 5461, 0x526a }, + /* 0x6FC0 */ + { 5468, 0x07cf }, { 5477, 0xcd30 }, { 5484, 0xda13 }, { 5492, 0x566b }, + /* 0x7000 */ + { 5501, 0x8ee3 }, { 5510, 0xed22 }, { 5518, 0x11c8 }, { 5523, 0x5605 }, + /* 0x7040 */ + { 5529, 0x5c88 }, { 5535, 0x6112 }, { 5540, 0xda38 }, { 5548, 0x7161 }, + /* 0x7080 */ + { 5555, 0x4662 }, { 5561, 0x82a4 }, { 5566, 0xf810 }, { 5572, 0x0f8a }, + /* 0x70C0 */ + { 5579, 0x8d00 }, { 5583, 0xb31a }, { 5591, 0x1010 }, { 5593, 0x2202 }, + /* 0x7100 */ + { 5596, 0x93d8 }, { 5604, 0x5610 }, { 5609, 0xc843 }, { 5615, 0x1043 }, + /* 0x7140 */ + { 5619, 0x56c0 }, { 5625, 0x526f }, { 5634, 0x53f5 }, { 5644, 0x2000 }, + /* 0x7180 */ + { 5645, 0x85b1 }, { 5652, 0x8a74 }, { 5659, 0xd105 }, { 5665, 0x460a }, + /* 0x71C0 */ + { 5670, 0x4b1a }, { 5677, 0x92bd }, { 5686, 0x70e1 }, { 5693, 0xda20 }, + /* 0x7200 */ + { 5699, 0x20c1 }, { 5703, 0x0821 }, { 5706, 0x3d00 }, { 5711, 0xff75 }, + /* 0x7240 */ + { 5724, 0x19c5 }, { 5731, 0xabec }, { 5741, 0xc28e }, { 5748, 0xe314 }, + /* 0x7280 */ + { 5755, 0x6087 }, { 5761, 0x0844 }, { 5764, 0xf085 }, { 5771, 0x4247 }, + /* 0x72C0 */ + { 5777, 0x505f }, { 5785, 0x0a85 }, { 5790, 0x3207 }, { 5796, 0x3f88 }, + /* 0x7300 */ + { 5804, 0x0480 }, { 5806, 0xbbc4 }, { 5815, 0xdfa0 }, { 5824, 0xe2da }, + /* 0x7340 */ + { 5833, 0xc030 }, { 5837, 0x0085 }, { 5840, 0xdd48 }, { 5848, 0x1da7 }, + /* 0x7380 */ + { 5857, 0x0eb2 }, { 5864, 0xd170 }, { 5871, 0x0b65 }, { 5878, 0x9aac }, + /* 0x73C0 */ + { 5886, 0xef25 }, { 5896, 0x4240 }, { 5899, 0x66ab }, { 5908, 0x4702 }, + /* 0x7400 */ + { 5913, 0x06ea }, { 5920, 0x0c08 }, { 5923, 0xdd74 }, { 5933, 0x867f }, + /* 0x7440 */ + { 5943, 0x28db }, { 5951, 0xfeac }, { 5962, 0xae1d }, { 5971, 0x404b }, + /* 0x7480 */ + { 5976, 0x0bea }, { 5984, 0xd385 }, { 5992, 0x0fef }, { 6003, 0xae21 }, + /* 0x74C0 */ + { 6010, 0x8700 }, { 6014, 0x5550 }, { 6020, 0xcacd }, { 6029, 0x85c7 }, + /* 0x7500 */ + { 6037, 0x703a }, { 6044, 0xd5aa }, { 6053, 0x9d79 }, { 6063, 0x7d8f }, + /* 0x7540 */ + { 6074, 0xff51 }, { 6085, 0x3e17 }, { 6094, 0xbef5 }, { 6106, 0xe7df }, + /* 0x7580 */ + { 6119, 0xdec6 }, { 6129, 0x2416 }, { 6134, 0x082c }, { 6138, 0xf3af }, + /* 0x75C0 */ + { 6150, 0xe4ed }, { 6160, 0xeb3c }, { 6170, 0x529d }, { 6178, 0xd61f }, + /* 0x7600 */ + { 6188, 0xab8f }, { 6198, 0xdb68 }, { 6207, 0x21f7 }, { 6216, 0x1839 }, + /* 0x7640 */ + { 6222, 0x1bce }, { 6231, 0x1164 }, { 6236, 0xf7b6 }, { 6248, 0x7d47 }, + /* 0x7680 */ + { 6258, 0x49db }, { 6267, 0x7e69 }, { 6277, 0xc5c3 }, { 6285, 0x87d1 }, + /* 0x76C0 */ + { 6293, 0x776c }, { 6303, 0xd8d4 }, { 6311, 0x55fa }, { 6321, 0x5916 }, + /* 0x7700 */ + { 6328, 0x1f92 }, { 6336, 0xce80 }, { 6342, 0x2271 }, { 6348, 0x15f0 }, + /* 0x7740 */ + { 6355, 0x60c1 }, { 6360, 0x9d00 }, { 6365, 0x0d6f }, { 6374, 0xf604 }, + /* 0x7780 */ + { 6381, 0x4801 }, { 6384, 0xc412 }, { 6389, 0x3635 }, { 6397, 0xba49 }, + /* 0x77C0 */ + { 6405, 0x2080 }, { 6407, 0xdc80 }, { 6413, 0xf6fd }, { 6426, 0x1819 }, + /* 0x7800 */ + { 6431, 0x3264 }, { 6437, 0x0234 }, { 6441, 0x30e3 }, { 6448, 0x8414 }, + /* 0x7840 */ + { 6452, 0xc0a8 }, { 6457, 0x2002 }, { 6459, 0xdd10 }, { 6466, 0x1014 }, + /* 0x7880 */ + { 6469, 0x74c2 }, { 6476, 0xe4ba }, { 6485, 0xa698 }, { 6492, 0x5c21 }, + /* 0x78C0 */ + { 6498, 0x5d62 }, { 6506, 0x0433 }, { 6511, 0x91d3 }, { 6519, 0x6e94 }, + /* 0x7900 */ + { 6527, 0x4083 }, { 6531, 0x1a07 }, { 6537, 0x5c60 }, { 6543, 0x5c13 }, + /* 0x7940 */ + { 6550, 0x07e3 }, { 6558, 0xfde9 }, { 6570, 0x21a5 }, { 6576, 0x8684 }, + /* 0x7980 */ + { 6581, 0xe433 }, { 6589, 0x2970 }, { 6595, 0x46c2 }, { 6601, 0xef1b }, + /* 0x79C0 */ + { 6612, 0x3f87 }, { 6622, 0xc176 }, { 6630, 0x3ada }, { 6639, 0x0801 }, + /* 0x7A00 */ + { 6641, 0x6d09 }, { 6648, 0xdfb2 }, { 6659, 0x6001 }, { 6662, 0xfb86 }, + /* 0x7A40 */ + { 6672, 0xf2cd }, { 6682, 0xb2c1 }, { 6689, 0x2e8f }, { 6698, 0xa771 }, + /* 0x7A80 */ + { 6707, 0x053e }, { 6714, 0x81ed }, { 6722, 0xd609 }, { 6729, 0xde49 }, + /* 0x7AC0 */ + { 6738, 0xfdb8 }, { 6749, 0xb62e }, { 6758, 0xadef }, { 6770, 0xa751 }, + /* 0x7B00 */ + { 6778, 0x8dd4 }, { 6786, 0x4b06 }, { 6792, 0xf5e1 }, { 6802, 0x2a6a }, + /* 0x7B40 */ + { 6809, 0xfbe2 }, { 6820, 0x2077 }, { 6827, 0xf2f1 }, { 6837, 0x863f }, + /* 0x7B80 */ + { 6846, 0xa8c0 }, { 6851, 0xffb7 }, { 6865, 0xa402 }, { 6869, 0x1132 }, + /* 0x7BC0 */ + { 6874, 0x9ef3 }, { 6885, 0x26d0 }, { 6891, 0x2671 }, { 6898, 0x00c9 }, + /* 0x7C00 */ + { 6902, 0xe88b }, { 6910, 0xc09e }, { 6917, 0x0ccb }, { 6924, 0xe1ca }, + /* 0x7C40 */ + { 6932, 0xb429 }, { 6939, 0xc3d3 }, { 6948, 0xf233 }, { 6957, 0x4229 }, + /* 0x7C80 */ + { 6962, 0xaa0e }, { 6969, 0x89b5 }, { 6977, 0x69f7 }, { 6988, 0xf2ce }, + /* 0x7CC0 */ + { 6998, 0x6535 }, { 7006, 0xf3e4 }, { 7016, 0x88c5 }, { 7022, 0x4d74 }, + /* 0x7D00 */ + { 7030, 0x2ffd }, { 7042, 0x7fbd }, { 7055, 0xd80f }, { 7063, 0xe62f }, + /* 0x7D40 */ + { 7073, 0xd9ff }, { 7086, 0x5e49 }, { 7094, 0x454e }, { 7101, 0xa66f }, + /* 0x7D80 */ + { 7111, 0x9b48 }, { 7118, 0xbe88 }, { 7126, 0xfccd }, { 7137, 0xedf7 }, + /* 0x7DC0 */ + { 7150, 0x9c85 }, { 7157, 0x77e6 }, { 7168, 0x935b }, { 7177, 0x0a16 }, + /* 0x7E00 */ + { 7182, 0x0f32 }, { 7189, 0xe8a7 }, { 7198, 0x59cf }, { 7208, 0x6ea6 }, + /* 0x7E40 */ + { 7217, 0x2cea }, { 7225, 0x6674 }, { 7233, 0x2ec2 }, { 7240, 0xfa29 }, + /* 0x7E80 */ + { 7249, 0xf7cc }, { 7260, 0x1d5f }, { 7270, 0x0000 }, { 7270, 0x0000 }, + /* 0x7F00 */ + { 7270, 0x0000 }, { 7270, 0x0000 }, { 7270, 0x0000 }, { 7270, 0x5d40 }, + /* 0x7F40 */ + { 7276, 0xf0b8 }, { 7284, 0x8137 }, { 7291, 0x6f9b }, { 7302, 0x63a5 }, + /* 0x7F80 */ + { 7310, 0x55ec }, { 7319, 0x74d3 }, { 7328, 0xe318 }, { 7335, 0xa344 }, + /* 0x7FC0 */ + { 7341, 0xd46a }, { 7349, 0x8834 }, { 7354, 0xda6b }, { 7364, 0x1e0d }, + /* 0x8000 */ + { 7371, 0x5d7f }, { 7383, 0x13f7 }, { 7393, 0x1152 }, { 7398, 0xb8e9 }, + /* 0x8040 */ + { 7407, 0x0448 }, { 7410, 0xc544 }, { 7416, 0x8146 }, { 7421, 0xeaff }, + /* 0x8080 */ + { 7434, 0x1af0 }, { 7441, 0x3f48 }, { 7449, 0xb6b6 }, { 7459, 0x0516 }, + /* 0x80C0 */ + { 7464, 0x5478 }, { 7471, 0x6fe0 }, { 7480, 0x8073 }, { 7486, 0x393a }, + /* 0x8100 */ + { 7494, 0x27e4 }, { 7502, 0x4d40 }, { 7507, 0x9298 }, { 7513, 0x622a }, + /* 0x8140 */ + { 7519, 0x4c40 }, { 7523, 0x803b }, { 7529, 0x6be1 }, { 7538, 0x8713 }, + /* 0x8180 */ + { 7545, 0x853f }, { 7554, 0x3528 }, { 7560, 0x0319 }, { 7565, 0xed2d }, + /* 0x81C0 */ + { 7575, 0xa74f }, { 7585, 0x8fca }, { 7594, 0x35b9 }, { 7603, 0xfc18 }, + /* 0x8200 */ + { 7611, 0x77b6 }, { 7622, 0xdbc5 }, { 7632, 0x5e06 }, { 7639, 0x13fc }, + /* 0x8240 */ + { 7648, 0x8ae1 }, { 7655, 0xb780 }, { 7662, 0xcd5d }, { 7672, 0xe3d6 }, + /* 0x8280 */ + { 7682, 0x6c08 }, { 7687, 0xa20c }, { 7692, 0xfbfa }, { 7705, 0xff9e }, + /* 0x82C0 */ + { 7718, 0x0060 }, { 7720, 0xdabe }, { 7731, 0x09ee }, { 7739, 0x6e9a }, + /* 0x8300 */ + { 7748, 0x53ff }, { 7760, 0x39c0 }, { 7766, 0xa90c }, { 7772, 0x1777 }, + /* 0x8340 */ + { 7782, 0x86b9 }, { 7790, 0x01b7 }, { 7797, 0x000c }, { 7799, 0xb8a8 }, + /* 0x8380 */ + { 7806, 0x66e0 }, { 7813, 0xed7c }, { 7824, 0x0f85 }, { 7831, 0xa022 }, + /* 0x83C0 */ + { 7835, 0xd6a3 }, { 7844, 0xb15b }, { 7853, 0x8e23 }, { 7860, 0x2a97 }, + /* 0x8400 */ + { 7868, 0xfcda }, { 7879, 0x00aa }, { 7883, 0x1605 }, { 7888, 0x3322 }, + /* 0x8440 */ + { 7894, 0xc740 }, { 7900, 0x9e86 }, { 7908, 0xfa6e }, { 7919, 0x17eb }, + /* 0x8480 */ + { 7929, 0x0836 }, { 7934, 0xd291 }, { 7941, 0xa042 }, { 7945, 0xdf14 }, + /* 0x84C0 */ + { 7954, 0xee57 }, { 7965, 0x164b }, { 7972, 0xd480 }, { 7977, 0xb413 }, + /* 0x8500 */ + { 7984, 0x1041 }, { 7987, 0xcdba }, { 7997, 0xb87a }, { 8006, 0x6034 }, + /* 0x8540 */ + { 8011, 0xcf0b }, { 8020, 0x47aa }, { 8028, 0xa71e }, { 8037, 0xec80 }, + /* 0x8580 */ + { 8043, 0x95d3 }, { 8052, 0xba9b }, { 8062, 0xff54 }, { 8073, 0x1681 }, + /* 0x85C0 */ + { 8078, 0xee82 }, { 8086, 0xb321 }, { 8093, 0x2672 }, { 8100, 0xcec0 }, + /* 0x8600 */ + { 8107, 0x0cf5 }, { 8115, 0x45cf }, { 8124, 0xa296 }, { 8131, 0x9301 }, + /* 0x8640 */ + { 8136, 0x6003 }, { 8140, 0xdcf9 }, { 8151, 0x9884 }, { 8156, 0x0ea2 }, + /* 0x8680 */ + { 8162, 0x3e80 }, { 8168, 0x312a }, { 8174, 0x8f18 }, { 8181, 0x014b }, + /* 0x86C0 */ + { 8186, 0x6ada }, { 8195, 0xcab2 }, { 8203, 0xf258 }, { 8211, 0x7f00 }, + /* 0x8700 */ + { 8218, 0x6fed }, { 8230, 0x970f }, { 8239, 0x022a }, { 8243, 0xcc92 }, + /* 0x8740 */ + { 8250, 0x5a09 }, { 8256, 0x83aa }, { 8263, 0x4579 }, { 8271, 0x9156 }, + /* 0x8780 */ + { 8278, 0x2b84 }, { 8284, 0x8008 }, { 8286, 0xb885 }, { 8293, 0x6c28 }, + /* 0x87C0 */ + { 8299, 0x48d3 }, { 8306, 0x8045 }, { 8310, 0xbc69 }, { 8319, 0x4ae4 }, + /* 0x8800 */ + { 8326, 0xec6a }, { 8335, 0x807b }, { 8342, 0x418e }, { 8348, 0x1a46 }, + /* 0x8840 */ + { 8354, 0x3455 }, { 8361, 0xeb8c }, { 8370, 0x8b1e }, { 8378, 0xe0a5 }, + /* 0x8880 */ + { 8385, 0x2906 }, { 8390, 0x43c4 }, { 8396, 0x4c15 }, { 8402, 0xf0b3 }, + /* 0x88C0 */ + { 8411, 0xc43f }, { 8420, 0xbb3e }, { 8431, 0x0102 }, { 8433, 0x733f }, + /* 0x8900 */ + { 8444, 0x1496 }, { 8450, 0x770d }, { 8459, 0x0ca0 }, { 8463, 0x0bc5 }, + /* 0x8940 */ + { 8470, 0x323f }, { 8479, 0xc040 }, { 8482, 0xa455 }, { 8489, 0xc094 }, + /* 0x8980 */ + { 8494, 0x8fcb }, { 8504, 0x85d9 }, { 8512, 0x96c2 }, { 8519, 0xa48d }, + /* 0x89C0 */ + { 8526, 0x0001 }, { 8527, 0x3554 }, { 8534, 0x08e8 }, { 8539, 0xa15a }, + /* 0x8A00 */ + { 8546, 0x550d }, { 8553, 0xa9ff }, { 8565, 0x242e }, { 8571, 0x5cfa }, + /* 0x8A40 */ + { 8581, 0x61e2 }, { 8588, 0x6937 }, { 8597, 0x7a4f }, { 8607, 0x122f }, + /* 0x8A80 */ + { 8614, 0x32b4 }, { 8621, 0x452b }, { 8628, 0x71fb }, { 8639, 0xd285 }, + /* 0x8AC0 */ + { 8646, 0xb894 }, { 8653, 0xdcc5 }, { 8662, 0x68d7 }, { 8671, 0x55da }, + /* 0x8B00 */ + { 8680, 0x74b7 }, { 8690, 0xbed1 }, { 8700, 0x3943 }, { 8707, 0x4208 }, + /* 0x8B40 */ + { 8710, 0xd24a }, { 8717, 0xdf52 }, { 8727, 0x9a40 }, { 8732, 0xa0d7 }, + /* 0x8B80 */ + { 8740, 0x5c0b }, { 8747, 0x767d }, { 8758, 0x0000 }, { 8758, 0x0000 }, + /* 0x8C00 */ + { 8758, 0x0000 }, { 8758, 0x0000 }, { 8758, 0x0000 }, { 8758, 0xa680 }, + /* 0x8C40 */ + { 8763, 0xd7e2 }, { 8773, 0x04b1 }, { 8778, 0x3f06 }, { 8786, 0x1708 }, + /* 0x8C80 */ + { 8791, 0x7624 }, { 8798, 0x6b1c }, { 8806, 0xff97 }, { 8819, 0xb9dd }, + /* 0x8CC0 */ + { 8830, 0x659f }, { 8840, 0x5e6a }, { 8849, 0x245f }, { 8857, 0x7d13 }, + /* 0x8D00 */ + { 8866, 0xefb0 }, { 8876, 0x085d }, { 8882, 0x0000 }, { 8882, 0x0000 }, + /* 0x8D40 */ + { 8882, 0x0000 }, { 8882, 0x0000 }, { 8882, 0x38d0 }, { 8888, 0x009b }, + /* 0x8D80 */ + { 8893, 0x0432 }, { 8897, 0x0220 }, { 8899, 0x8148 }, { 8903, 0x4408 }, + /* 0x8DC0 */ + { 8906, 0xd944 }, { 8913, 0xaec2 }, { 8921, 0x9d0a }, { 8928, 0xb028 }, + /* 0x8E00 */ + { 8933, 0x9740 }, { 8939, 0xe051 }, { 8945, 0x048f }, { 8951, 0x2271 }, + /* 0x8E40 */ + { 8957, 0x1f94 }, { 8965, 0x8231 }, { 8970, 0xb01d }, { 8977, 0x1855 }, + /* 0x8E80 */ + { 8983, 0x2cb2 }, { 8990, 0x431a }, { 8996, 0xdc02 }, { 9002, 0x486b }, + /* 0x8EC0 */ + { 9009, 0x3d61 }, { 9017, 0x8816 }, { 9022, 0x080c }, { 9025, 0x7f00 }, + /* 0x8F00 */ + { 9032, 0x1729 }, { 9039, 0xfabc }, { 9050, 0xae40 }, { 9056, 0xcb48 }, + /* 0x8F40 */ + { 9063, 0x7675 }, { 9073, 0x9190 }, { 9078, 0x001e }, { 9082, 0x0000 }, + /* 0x8F80 */ + { 9082, 0x0000 }, { 9082, 0xd800 }, { 9086, 0xe1d8 }, { 9094, 0x9cf7 }, + /* 0x8FC0 */ + { 9105, 0x6476 }, { 9113, 0x043a }, { 9118, 0xef75 }, { 9130, 0x2fb3 }, + /* 0x9000 */ + { 9140, 0xf96f }, { 9152, 0xe6fb }, { 9164, 0x608f }, { 9171, 0x53e6 }, + /* 0x9040 */ + { 9180, 0xeebe }, { 9192, 0x737f }, { 9204, 0xe32b }, { 9213, 0xb5e4 }, + /* 0x9080 */ + { 9222, 0x97bf }, { 9234, 0x0aa3 }, { 9240, 0x854e }, { 9247, 0x416b }, + /* 0x90C0 */ + { 9254, 0x45ba }, { 9262, 0xf880 }, { 9268, 0xa916 }, { 9275, 0xe0f4 }, + /* 0x9100 */ + { 9283, 0x0055 }, { 9287, 0x5374 }, { 9295, 0xa08c }, { 9300, 0x2697 }, + /* 0x9140 */ + { 9308, 0x7fc0 }, { 9317, 0x0bd4 }, { 9324, 0x163e }, { 9332, 0x03bc }, + /* 0x9180 */ + { 9339, 0x6aac }, { 9347, 0x5085 }, { 9352, 0xdd14 }, { 9360, 0x157a }, + /* 0x91C0 */ + { 9368, 0xfbdb }, { 9381, 0xbdc3 }, { 9391, 0x70fa }, { 9400, 0x9862 }, + /* 0x9200 */ + { 9406, 0x6482 }, { 9411, 0x40f3 }, { 9418, 0x1200 }, { 9420, 0x9798 }, + /* 0x9240 */ + { 9428, 0xcfbd }, { 9440, 0x4ec3 }, { 9448, 0x01f7 }, { 9456, 0xf102 }, + /* 0x9280 */ + { 9462, 0x2329 }, { 9468, 0x9fea }, { 9479, 0x2880 }, { 9482, 0x8284 }, + /* 0x92C0 */ + { 9486, 0xd845 }, { 9493, 0x028d }, { 9498, 0x26b1 }, { 9505, 0x9f8c }, + /* 0x9300 */ + { 9514, 0xa054 }, { 9519, 0xe723 }, { 9528, 0xdbef }, { 9541, 0x0c24 }, + /* 0x9340 */ + { 9545, 0x2f90 }, { 9552, 0x1cd2 }, { 9559, 0x5c31 }, { 9566, 0x502b }, + /* 0x9380 */ + { 9572, 0x9900 }, { 9576, 0x4cd0 }, { 9582, 0x708a }, { 9588, 0x0601 }, + /* 0x93C0 */ + { 9591, 0x01ca }, { 9596, 0xf1c3 }, { 9605, 0x01b6 }, { 9611, 0x2822 }, + /* 0x9400 */ + { 9615, 0x8298 }, { 9620, 0x07d9 }, { 9628, 0x0802 }, { 9630, 0x0d7c }, + /* 0x9440 */ + { 9638, 0x0432 }, { 9642, 0x4c0e }, { 9648, 0xac0d }, { 9655, 0xf0a7 }, + /* 0x9480 */ + { 9664, 0x0002 }, { 9665, 0x0000 }, { 9665, 0x0000 }, { 9665, 0x0000 }, + /* 0x9540 */ + { 9665, 0x0000 }, { 9665, 0x0000 }, { 9665, 0x0000 }, { 9665, 0x0380 }, + /* 0x9580 */ + { 9668, 0xfecd }, { 9680, 0x835a }, { 9687, 0x3bfd }, { 9699, 0x7a54 }, + /* 0x95C0 */ + { 9707, 0x3d88 }, { 9714, 0x5579 }, { 9723, 0x0026 }, { 9726, 0x0000 }, + /* 0x9600 */ + { 9726, 0x0000 }, { 9726, 0x3000 }, { 9728, 0xd502 }, { 9734, 0x981c }, + /* 0x9640 */ + { 9740, 0xb817 }, { 9748, 0xf901 }, { 9755, 0x147e }, { 9763, 0x25ed }, + /* 0x9680 */ + { 9772, 0xed74 }, { 9782, 0x3fb0 }, { 9791, 0x87b9 }, { 9800, 0x3fdf }, + /* 0x96C0 */ + { 9813, 0x7af3 }, { 9824, 0x7f66 }, { 9835, 0x8f0c }, { 9842, 0x0ac5 }, + /* 0x9700 */ + { 9848, 0xe5d1 }, { 9857, 0x525a }, { 9864, 0x0498 }, { 9868, 0x6b4d }, + /* 0x9740 */ + { 9877, 0xe3d6 }, { 9887, 0x5ee4 }, { 9896, 0x6f57 }, { 9907, 0x161a }, + /* 0x9780 */ + { 9913, 0xa872 }, { 9920, 0x5561 }, { 9927, 0x694d }, { 9935, 0x441e }, + /* 0x97C0 */ + { 9941, 0x1b4a }, { 9948, 0x5b1a }, { 9956, 0x6002 }, { 9959, 0x887e }, + /* 0x9800 */ + { 9967, 0xf57e }, { 9979, 0x45df }, { 9989, 0x383a }, { 9996, 0x399d }, + /* 0x9840 */ + { 10005, 0xf8c0 }, { 10012, 0x4ffc }, { 10023, 0x98e0 }, { 10029, 0x001b }, + /* 0x9880 */ + { 10033, 0x0000 }, { 10033, 0x0000 }, { 10033, 0xad00 }, { 10038, 0x9dc3 }, + /* 0x98C0 */ + { 10047, 0x09dc }, { 10054, 0x9800 }, { 10057, 0xeeaf }, { 10069, 0x701f }, + /* 0x9900 */ + { 10077, 0x1728 }, { 10083, 0x7ddd }, { 10095, 0x5113 }, { 10101, 0x7c0e }, + /* 0x9940 */ + { 10109, 0x7a67 }, { 10119, 0x91a7 }, { 10127, 0x0001 }, { 10128, 0x0000 }, + /* 0x9980 */ + { 10128, 0x0000 }, { 10128, 0x43c0 }, { 10133, 0x7168 }, { 10140, 0xb218 }, + /* 0x99C0 */ + { 10146, 0x037a }, { 10153, 0xeb37 }, { 10164, 0x6004 }, { 10167, 0x9b07 }, + /* 0x9A00 */ + { 10175, 0xc42e }, { 10182, 0x064e }, { 10188, 0x6911 }, { 10194, 0x41c3 }, + /* 0x9A40 */ + { 10200, 0x743d }, { 10209, 0x8da4 }, { 10216, 0x0e34 }, { 10222, 0x0000 }, + /* 0x9A80 */ + { 10222, 0x0000 }, { 10222, 0x0000 }, { 10222, 0xa100 }, { 10225, 0x13c1 }, + /* 0x9AC0 */ + { 10231, 0xc05b }, { 10238, 0xd17f }, { 10249, 0xee6d }, { 10260, 0x0a92 }, + /* 0x9B00 */ + { 10265, 0x114c }, { 10270, 0x9545 }, { 10277, 0xefad }, { 10289, 0x380e }, + /* 0x9B40 */ + { 10295, 0xe83e }, { 10304, 0x4512 }, { 10309, 0x9868 }, { 10315, 0x02fc }, + /* 0x9B80 */ + { 10322, 0xc418 }, { 10327, 0xc0ce }, { 10334, 0x7dc1 }, { 10343, 0x4316 }, + /* 0x9BC0 */ + { 10349, 0xc6c3 }, { 10357, 0x2956 }, { 10364, 0xcdbe }, { 10375, 0x25af }, + /* 0x9C00 */ + { 10384, 0x3751 }, { 10392, 0x2f7d }, { 10403, 0xe6be }, { 10414, 0x4ec7 }, + /* 0x9C40 */ + { 10423, 0x87e2 }, { 10431, 0xbd9d }, { 10442, 0x6ea9 }, { 10451, 0x05e5 }, + /* 0x9CC0 */ + { 10458, 0x0000 }, { 10458, 0x0000 }, { 10458, 0x1ae0 }, { 10464, 0x005d }, + /* 0x9D00 */ + { 10469, 0x4bcc }, { 10477, 0xe9a6 }, { 10486, 0x1d48 }, { 10492, 0xc804 }, + /* 0x9D40 */ + { 10496, 0x05de }, { 10504, 0xf207 }, { 10512, 0x9a1f }, { 10521, 0x54cd }, + /* 0x9D80 */ + { 10529, 0xa690 }, { 10535, 0x0640 }, { 10538, 0x9a12 }, { 10544, 0xbf34 }, + /* 0x9DC0 */ + { 10554, 0x82df }, { 10563, 0x86c8 }, { 10569, 0xa0c9 }, { 10575, 0x2714 }, + /* 0x9E00 */ + { 10581, 0x2484 }, { 10585, 0x7e20 }, { 10592, 0x0000 }, { 10592, 0x0000 }, + /* 0x9E40 */ + { 10592, 0x0000 }, { 10592, 0x0000 }, { 10592, 0x0000 }, { 10592, 0xbb20 }, + /* 0x9E80 */ + { 10599, 0x1923 }, { 10605, 0xe8ae }, { 10614, 0xb770 }, { 10623, 0xff30 }, + /* 0x9EC0 */ + { 10633, 0xf018 }, { 10639, 0xfb17 }, { 10650, 0xc1a1 }, { 10656, 0xbad0 }, + /* 0x9F00 */ + { 10664, 0x418c }, { 10669, 0x02a9 }, { 10674, 0x9003 }, { 10678, 0x6e80 }, + /* 0x9F40 */ + { 10684, 0xcc62 }, { 10691, 0xa1bc }, { 10699, 0x36cf }, { 10709, 0x00e5 }, + /* 0x9F80 */ + { 10714, 0x2000 }, { 10715, 0x30b1 }, { 10721, 0x0005 }, { 10723, 0x0000 }, + /* 0xF900 */ + { 10723, 0x0000 }, { 10723, 0x2000 }, { 10724, 0x0300 }, { 10726, 0x0040 }, + /* 0xF940 */ + { 10727, 0x0000 }, { 10727, 0x0000 }, { 10727, 0x0000 }, { 10727, 0x0001 }, + /* 0xF9C0 */ + { 10728, 0x0000 }, { 10728, 0x1001 }, { 10730, 0x0000 }, { 10730, 0x0000 }, + /* 0xFA00 */ + { 10730, 0x8000 }, { 10731, 0x8e7b }, { 10741, 0x0057 }, { 10746, 0xffff }, + /* 0xFA40 */ + { 10762, 0xffff }, { 10778, 0xffff }, { 10794, 0x07ff }, { 10805, 0x0000 }, + /* 0xFE40 */ + { 10805, 0x0060 }, { 10807, 0x0000 }, { 10807, 0x0000 }, { 10807, 0x0000 }, + /* 0xFF00 */ + { 10807, 0xfffe }, { 10822, 0xffff }, { 10838, 0xffff }, { 10854, 0xffff }, + /* 0xFF40 */ + { 10870, 0xffff }, { 10886, 0xffff }, { 10902, 0x0001 }, { 10903, 0x0000 }, + /* 0xFFC0 */ + { 10903, 0x0000 }, { 10903, 0x0000 }, { 10903, 0x0028 }, { 10905, 0x0000 }, + /* 0x20000 */ + { 10905, 0x0800 }, { 10906, 0x0000 }, { 10906, 0x0000 }, { 10906, 0x0000 }, + /* 0x20080 */ + { 10906, 0x0200 }, { 10907, 0x0000 }, { 10907, 0x0014 }, { 10909, 0x0000 }, + /* 0x20180 */ + { 10909, 0x0000 }, { 10909, 0x0000 }, { 10909, 0x0004 }, { 10910, 0x0000 }, + /* 0x20200 */ + { 10910, 0x0000 }, { 10910, 0x0008 }, { 10911, 0x0000 }, { 10911, 0x0000 }, + /* 0x20300 */ + { 10911, 0x0000 }, { 10911, 0x0000 }, { 10911, 0x0800 }, { 10912, 0x0000 }, + /* 0x20340 */ + { 10912, 0x0000 }, { 10912, 0x0000 }, { 10912, 0x0000 }, { 10912, 0x0002 }, + /* 0x20380 */ + { 10913, 0x0002 }, { 10914, 0x0000 }, { 10914, 0x0000 }, { 10914, 0x0000 }, + /* 0x203C0 */ + { 10914, 0x0000 }, { 10914, 0x0000 }, { 10914, 0x0000 }, { 10914, 0x0200 }, + /* 0x20440 */ + { 10915, 0x0400 }, { 10916, 0x0000 }, { 10916, 0x0000 }, { 10916, 0x0000 }, + /* 0x20500 */ + { 10916, 0x0200 }, { 10917, 0x0000 }, { 10917, 0x0000 }, { 10917, 0x0000 }, + /* 0x205C0 */ + { 10917, 0x0000 }, { 10917, 0x0040 }, { 10918, 0x0000 }, { 10918, 0x0000 }, + /* 0x20600 */ + { 10918, 0x0000 }, { 10918, 0x0000 }, { 10918, 0x0100 }, { 10919, 0x0000 }, + /* 0x20740 */ + { 10919, 0x8000 }, { 10920, 0x0000 }, { 10920, 0x0000 }, { 10920, 0x0000 }, + /* 0x20800 */ + { 10920, 0x0080 }, { 10921, 0x0000 }, { 10921, 0x0000 }, { 10921, 0x0400 }, + /* 0x20880 */ + { 10922, 0x0000 }, { 10922, 0x0000 }, { 10922, 0x0000 }, { 10922, 0x0200 }, + /* 0x20940 */ + { 10923, 0x0000 }, { 10923, 0x0000 }, { 10923, 0x0000 }, { 10923, 0x1000 }, + /* 0x20980 */ + { 10924, 0x0000 }, { 10924, 0x2000 }, { 10925, 0x0000 }, { 10925, 0x0000 }, + /* 0x20AC0 */ + { 10925, 0x0000 }, { 10925, 0x0008 }, { 10926, 0x0000 }, { 10926, 0x0000 }, + /* 0x20B00 */ + { 10926, 0x0000 }, { 10926, 0x2000 }, { 10927, 0x0000 }, { 10927, 0x0000 }, + /* 0x20B80 */ + { 10927, 0x0000 }, { 10927, 0x8000 }, { 10928, 0x0000 }, { 10928, 0x0000 }, + /* 0x20D40 */ + { 10928, 0x0020 }, { 10929, 0x0000 }, { 10929, 0x0000 }, { 10929, 0x0000 }, + /* 0x20DC0 */ + { 10929, 0x0000 }, { 10929, 0x0000 }, { 10929, 0x0002 }, { 10930, 0x0000 }, + /* 0x20E40 */ + { 10930, 0x0000 }, { 10930, 0x0000 }, { 10930, 0x2010 }, { 10932, 0x0000 }, + /* 0x20E80 */ + { 10932, 0x0000 }, { 10932, 0x0020 }, { 10933, 0x0000 }, { 10933, 0x0000 }, + /* 0x20F40 */ + { 10933, 0x0000 }, { 10933, 0x8000 }, { 10934, 0x0000 }, { 10934, 0x0000 }, + /* 0x21200 */ + { 10934, 0x0002 }, { 10935, 0x0000 }, { 10935, 0x0000 }, { 10935, 0x2000 }, + /* 0x21240 */ + { 10936, 0x0000 }, { 10936, 0x0020 }, { 10937, 0x0000 }, { 10937, 0x0810 }, + /* 0x212C0 */ + { 10939, 0x0000 }, { 10939, 0x0080 }, { 10940, 0x0010 }, { 10941, 0x2000 }, + /* 0x21300 */ + { 10942, 0x0000 }, { 10942, 0x0800 }, { 10943, 0x0000 }, { 10943, 0x0040 }, + /* 0x21340 */ + { 10944, 0x0010 }, { 10945, 0x0000 }, { 10945, 0x0000 }, { 10945, 0x0000 }, + /* 0x213C0 */ + { 10945, 0x0010 }, { 10946, 0x0000 }, { 10946, 0x0000 }, { 10946, 0x0000 }, + /* 0x21440 */ + { 10946, 0x0000 }, { 10946, 0x0000 }, { 10946, 0x6000 }, { 10948, 0x0000 }, + /* 0x215C0 */ + { 10948, 0x0000 }, { 10948, 0x0080 }, { 10949, 0x0000 }, { 10949, 0x0000 }, + /* 0x21640 */ + { 10949, 0x0080 }, { 10950, 0x0000 }, { 10950, 0x0000 }, { 10950, 0x0000 }, + /* 0x21680 */ + { 10950, 0x0000 }, { 10950, 0x0000 }, { 10950, 0x0000 }, { 10950, 0x0010 }, + /* 0x21700 */ + { 10951, 0x0040 }, { 10952, 0x0000 }, { 10952, 0x0000 }, { 10952, 0x0000 }, + /* 0x21740 */ + { 10952, 0x0004 }, { 10953, 0x0000 }, { 10953, 0x0000 }, { 10953, 0x0000 }, + /* 0x21880 */ + { 10953, 0x0000 }, { 10953, 0x0000 }, { 10953, 0x0000 }, { 10953, 0x2000 }, + /* 0x219C0 */ + { 10954, 0x0008 }, { 10955, 0x0000 }, { 10955, 0x0000 }, { 10955, 0x0000 }, + /* 0x21C40 */ + { 10955, 0x0000 }, { 10955, 0x0040 }, { 10956, 0x0000 }, { 10956, 0x0000 }, + /* 0x21D00 */ + { 10956, 0x0000 }, { 10956, 0x0000 }, { 10956, 0x2000 }, { 10957, 0x0000 }, + /* 0x21D40 */ + { 10957, 0x0020 }, { 10958, 0x0000 }, { 10958, 0x0004 }, { 10959, 0x0100 }, + /* 0x21D80 */ + { 10960, 0x0000 }, { 10960, 0x1004 }, { 10962, 0x0002 }, { 10963, 0x0080 }, + /* 0x21DC0 */ + { 10964, 0x0000 }, { 10964, 0x0000 }, { 10964, 0x0001 }, { 10965, 0x0000 }, + /* 0x21E00 */ + { 10965, 0x0000 }, { 10965, 0x0000 }, { 10965, 0x0000 }, { 10965, 0x0018 }, + /* 0x21F00 */ + { 10967, 0x0000 }, { 10967, 0x4000 }, { 10968, 0x0000 }, { 10968, 0x0000 }, + /* 0x21F40 */ + { 10968, 0x0000 }, { 10968, 0x0000 }, { 10968, 0x0000 }, { 10968, 0x0040 }, + /* 0x21FC0 */ + { 10969, 0x0000 }, { 10969, 0x0000 }, { 10969, 0x0000 }, { 10969, 0x0400 }, + /* 0x22140 */ + { 10970, 0x0000 }, { 10970, 0x0000 }, { 10970, 0x0000 }, { 10970, 0x0800 }, + /* 0x22200 */ + { 10971, 0x0000 }, { 10971, 0x0100 }, { 10972, 0x0000 }, { 10972, 0x0000 }, + /* 0x22300 */ + { 10972, 0x0000 }, { 10972, 0x4000 }, { 10973, 0x0000 }, { 10973, 0x0000 }, + /* 0x22380 */ + { 10973, 0x0000 }, { 10973, 0x0000 }, { 10973, 0x2000 }, { 10974, 0x0000 }, + /* 0x226C0 */ + { 10974, 0x0000 }, { 10974, 0x0000 }, { 10974, 0x0000 }, { 10974, 0x0008 }, + /* 0x22840 */ + { 10975, 0x0000 }, { 10975, 0x0800 }, { 10976, 0x0000 }, { 10976, 0x0000 }, + /* 0x22880 */ + { 10976, 0x0000 }, { 10976, 0x0000 }, { 10976, 0x0800 }, { 10977, 0x0000 }, + /* 0x22980 */ + { 10977, 0x8000 }, { 10978, 0x0000 }, { 10978, 0x0000 }, { 10978, 0x0000 }, + /* 0x22A80 */ + { 10978, 0x0000 }, { 10978, 0x0000 }, { 10978, 0x0000 }, { 10978, 0x0100 }, + /* 0x22B40 */ + { 10979, 0x8040 }, { 10981, 0x0001 }, { 10982, 0x0000 }, { 10982, 0x0000 }, + /* 0x22B80 */ + { 10982, 0x0000 }, { 10982, 0x0000 }, { 10982, 0x0040 }, { 10983, 0x0000 }, + /* 0x22C00 */ + { 10983, 0x0000 }, { 10983, 0x2000 }, { 10984, 0x0010 }, { 10985, 0x0000 }, + /* 0x22DC0 */ + { 10985, 0x0000 }, { 10985, 0x0000 }, { 10985, 0x0002 }, { 10986, 0x0000 }, + /* 0x23180 */ + { 10986, 0x0000 }, { 10986, 0x0000 }, { 10986, 0x0000 }, { 10986, 0x0040 }, + /* 0x231C0 */ + { 10987, 0x0018 }, { 10989, 0x0000 }, { 10989, 0x0000 }, { 10989, 0x0020 }, + /* 0x23340 */ + { 10990, 0x0000 }, { 10990, 0x0000 }, { 10990, 0x0000 }, { 10990, 0x0004 }, + /* 0x233C0 */ + { 10991, 0x0000 }, { 10991, 0x842d }, { 10997, 0x0010 }, { 10998, 0x0000 }, + /* 0x23440 */ + { 10998, 0x0c00 }, { 11000, 0x0002 }, { 11001, 0x0020 }, { 11002, 0x0000 }, + /* 0x234C0 */ + { 11002, 0x0000 }, { 11002, 0x0000 }, { 11002, 0x0010 }, { 11003, 0x0000 }, + /* 0x23540 */ + { 11003, 0x0000 }, { 11003, 0x0400 }, { 11004, 0x0000 }, { 11004, 0x0000 }, + /* 0x23580 */ + { 11004, 0x0000 }, { 11004, 0x0010 }, { 11005, 0x0000 }, { 11005, 0x0000 }, + /* 0x235C0 */ + { 11005, 0x0010 }, { 11006, 0x0000 }, { 11006, 0x0000 }, { 11006, 0x0000 }, + /* 0x23600 */ + { 11006, 0x0000 }, { 11006, 0x0000 }, { 11006, 0x0000 }, { 11006, 0x0700 }, + /* 0x23640 */ + { 11009, 0x0080 }, { 11010, 0x0000 }, { 11010, 0x0000 }, { 11010, 0x0000 }, + /* 0x23700 */ + { 11010, 0x1000 }, { 11011, 0x1000 }, { 11012, 0x0000 }, { 11012, 0x8000 }, + /* 0x23740 */ + { 11013, 0x0000 }, { 11013, 0x0000 }, { 11013, 0x0018 }, { 11015, 0x0000 }, + /* 0x237C0 */ + { 11015, 0x0000 }, { 11015, 0x0000 }, { 11015, 0x0080 }, { 11016, 0x8000 }, + /* 0x23800 */ + { 11017, 0x0000 }, { 11017, 0x0000 }, { 11017, 0x0010 }, { 11018, 0x2000 }, + /* 0x23A80 */ + { 11019, 0x0000 }, { 11019, 0x0100 }, { 11020, 0x0000 }, { 11020, 0x0000 }, + /* 0x23C40 */ + { 11020, 0x0000 }, { 11020, 0x0000 }, { 11020, 0x0000 }, { 11020, 0x8000 }, + /* 0x23CC0 */ + { 11021, 0x0000 }, { 11021, 0x0000 }, { 11021, 0x0000 }, { 11021, 0x4000 }, + /* 0x23D00 */ + { 11022, 0x4001 }, { 11024, 0x0000 }, { 11024, 0x0000 }, { 11024, 0x0000 }, + /* 0x23D40 */ + { 11024, 0x0001 }, { 11025, 0x0000 }, { 11025, 0x0000 }, { 11025, 0x0000 }, + /* 0x23DC0 */ + { 11025, 0x0000 }, { 11025, 0x0008 }, { 11026, 0x0000 }, { 11026, 0x0600 }, + /* 0x23F40 */ + { 11028, 0x0000 }, { 11028, 0x0000 }, { 11028, 0x0000 }, { 11028, 0x4000 }, + /* 0x24080 */ + { 11029, 0x0000 }, { 11029, 0x0040 }, { 11030, 0x0000 }, { 11030, 0x0000 }, + /* 0x24100 */ + { 11030, 0x0008 }, { 11031, 0x0000 }, { 11031, 0x0000 }, { 11031, 0x0000 }, + /* 0x241C0 */ + { 11031, 0x0040 }, { 11032, 0x0000 }, { 11032, 0x0000 }, { 11032, 0x4000 }, + /* 0x24380 */ + { 11033, 0x0000 }, { 11033, 0x0000 }, { 11033, 0x0000 }, { 11033, 0x1000 }, + /* 0x24600 */ + { 11034, 0x0000 }, { 11034, 0x0000 }, { 11034, 0x0200 }, { 11035, 0x0000 }, + /* 0x24680 */ + { 11035, 0x0000 }, { 11035, 0x0000 }, { 11035, 0x0020 }, { 11036, 0x0000 }, + /* 0x247C0 */ + { 11036, 0x0000 }, { 11036, 0x0000 }, { 11036, 0x0000 }, { 11036, 0x0002 }, + /* 0x24880 */ + { 11037, 0x0000 }, { 11037, 0x0040 }, { 11038, 0x0000 }, { 11038, 0x0000 }, + /* 0x24A40 */ + { 11038, 0x2000 }, { 11039, 0x0000 }, { 11039, 0x0000 }, { 11039, 0x0000 }, + /* 0x24B40 */ + { 11039, 0x0000 }, { 11039, 0x0040 }, { 11040, 0x8000 }, { 11041, 0x0000 }, + /* 0x24C00 */ + { 11041, 0x0000 }, { 11041, 0x0040 }, { 11042, 0x0000 }, { 11042, 0x0000 }, + /* 0x24D00 */ + { 11042, 0x0000 }, { 11042, 0x0010 }, { 11043, 0x0000 }, { 11043, 0x0000 }, + /* 0x24E00 */ + { 11043, 0x4000 }, { 11044, 0x0000 }, { 11044, 0x0000 }, { 11044, 0x0080 }, + /* 0x24E40 */ + { 11045, 0x0000 }, { 11045, 0x0000 }, { 11045, 0x0400 }, { 11046, 0x0000 }, + /* 0x24E80 */ + { 11046, 0x0800 }, { 11047, 0x0000 }, { 11047, 0x0000 }, { 11047, 0x0000 }, + /* 0x25040 */ + { 11047, 0x0400 }, { 11048, 0x0020 }, { 11049, 0x0000 }, { 11049, 0x0000 }, + /* 0x25100 */ + { 11049, 0x0000 }, { 11049, 0x0000 }, { 11049, 0x0004 }, { 11050, 0x0000 }, + /* 0x25180 */ + { 11050, 0x0000 }, { 11050, 0x0000 }, { 11050, 0x0200 }, { 11051, 0x0000 }, + /* 0x251C0 */ + { 11051, 0x2000 }, { 11052, 0x0000 }, { 11052, 0x0020 }, { 11053, 0x0000 }, + /* 0x25200 */ + { 11053, 0x0000 }, { 11053, 0x4000 }, { 11054, 0x0000 }, { 11054, 0x0000 }, + /* 0x25240 */ + { 11054, 0x1000 }, { 11055, 0x0000 }, { 11055, 0x0000 }, { 11055, 0x0000 }, + /* 0x25400 */ + { 11055, 0x0000 }, { 11055, 0x0000 }, { 11055, 0x4000 }, { 11056, 0x0000 }, + /* 0x25480 */ + { 11056, 0x4000 }, { 11057, 0x0000 }, { 11057, 0x0000 }, { 11057, 0x0000 }, + /* 0x254C0 */ + { 11057, 0x0000 }, { 11057, 0x0200 }, { 11058, 0x0000 }, { 11058, 0x0000 }, + /* 0x25500 */ + { 11058, 0x4000 }, { 11059, 0x0000 }, { 11059, 0x0000 }, { 11059, 0x0000 }, + /* 0x25580 */ + { 11059, 0x0000 }, { 11059, 0x0000 }, { 11059, 0x0080 }, { 11060, 0x0000 }, + /* 0x25740 */ + { 11060, 0x0000 }, { 11060, 0x0000 }, { 11060, 0x0000 }, { 11060, 0x0002 }, + /* 0x25780 */ + { 11061, 0x0000 }, { 11061, 0x0000 }, { 11061, 0x0200 }, { 11062, 0x0010 }, + /* 0x259C0 */ + { 11063, 0x0010 }, { 11064, 0x0010 }, { 11065, 0x0000 }, { 11065, 0x0000 }, + /* 0x25AC0 */ + { 11065, 0x0000 }, { 11065, 0x0000 }, { 11065, 0x0018 }, { 11067, 0x0002 }, + /* 0x25B80 */ + { 11068, 0x0000 }, { 11068, 0x0000 }, { 11068, 0x0000 }, { 11068, 0x0004 }, + /* 0x25C40 */ + { 11069, 0x0800 }, { 11070, 0x0000 }, { 11070, 0x0010 }, { 11071, 0x0000 }, + /* 0x25D80 */ + { 11071, 0x0000 }, { 11071, 0x0000 }, { 11071, 0x0002 }, { 11072, 0x0000 }, + /* 0x25E00 */ + { 11072, 0x0000 }, { 11072, 0x0000 }, { 11072, 0x4000 }, { 11073, 0x0000 }, + /* 0x25E40 */ + { 11073, 0x0000 }, { 11073, 0x0040 }, { 11074, 0x0024 }, { 11076, 0x0000 }, + /* 0x25EC0 */ + { 11076, 0x0004 }, { 11077, 0x0100 }, { 11078, 0x0100 }, { 11079, 0x0000 }, + /* 0x25F00 */ + { 11079, 0x0000 }, { 11079, 0x0000 }, { 11079, 0x0008 }, { 11080, 0x0000 }, + /* 0x25F40 */ + { 11080, 0x0000 }, { 11080, 0x1000 }, { 11081, 0x0000 }, { 11081, 0x0000 }, + /* 0x25FC0 */ + { 11081, 0x0000 }, { 11081, 0x0010 }, { 11082, 0x0001 }, { 11083, 0x0800 }, + /* 0x26000 */ + { 11084, 0x1000 }, { 11085, 0x0080 }, { 11086, 0x0000 }, { 11086, 0x0000 }, + /* 0x26040 */ + { 11086, 0x0000 }, { 11086, 0x0000 }, { 11086, 0x0001 }, { 11087, 0x0000 }, + /* 0x260C0 */ + { 11087, 0x0000 }, { 11087, 0x0000 }, { 11087, 0x2000 }, { 11088, 0x0000 }, + /* 0x26240 */ + { 11088, 0x0000 }, { 11088, 0x0000 }, { 11088, 0x0000 }, { 11088, 0x0001 }, + /* 0x26280 */ + { 11089, 0x0040 }, { 11090, 0x0000 }, { 11090, 0x0000 }, { 11090, 0x0000 }, + /* 0x26340 */ + { 11090, 0x1000 }, { 11091, 0x0000 }, { 11091, 0x0000 }, { 11091, 0x0000 }, + /* 0x26400 */ + { 11091, 0x0004 }, { 11092, 0x0000 }, { 11092, 0x0000 }, { 11092, 0x0000 }, + /* 0x26640 */ + { 11092, 0x0000 }, { 11092, 0x0000 }, { 11092, 0x0000 }, { 11092, 0x4000 }, + /* 0x26680 */ + { 11093, 0x0000 }, { 11093, 0x0000 }, { 11093, 0x0000 }, { 11093, 0x0001 }, + /* 0x26700 */ + { 11094, 0x0000 }, { 11094, 0x2000 }, { 11095, 0x0000 }, { 11095, 0x0000 }, + /* 0x268C0 */ + { 11095, 0x0000 }, { 11095, 0x2000 }, { 11096, 0x0400 }, { 11097, 0x0000 }, + /* 0x26940 */ + { 11097, 0x0000 }, { 11097, 0x0002 }, { 11098, 0x8000 }, { 11099, 0x0000 }, + /* 0x269C0 */ + { 11099, 0x0000 }, { 11099, 0x2000 }, { 11100, 0x0000 }, { 11100, 0x0000 }, + /* 0x26A00 */ + { 11100, 0x0000 }, { 11100, 0x4000 }, { 11101, 0x0000 }, { 11101, 0x0000 }, + /* 0x26A40 */ + { 11101, 0x0000 }, { 11101, 0x0100 }, { 11102, 0x0000 }, { 11102, 0x0000 }, + /* 0x26A80 */ + { 11102, 0x1000 }, { 11103, 0x0000 }, { 11103, 0x0000 }, { 11103, 0x0080 }, + /* 0x26AC0 */ + { 11104, 0x0000 }, { 11104, 0x0000 }, { 11104, 0x0000 }, { 11104, 0x8000 }, + /* 0x26C00 */ + { 11105, 0x0000 }, { 11105, 0x0000 }, { 11105, 0x0200 }, { 11106, 0x0000 }, + /* 0x26C40 */ + { 11106, 0x0000 }, { 11106, 0x0000 }, { 11106, 0x0000 }, { 11106, 0x0008 }, + /* 0x26CC0 */ + { 11107, 0x0000 }, { 11107, 0x2000 }, { 11108, 0x0000 }, { 11108, 0x0000 }, + /* 0x26E40 */ + { 11108, 0x0001 }, { 11109, 0x0000 }, { 11109, 0x0020 }, { 11110, 0x0000 }, + /* 0x26F80 */ + { 11110, 0x0000 }, { 11110, 0x0010 }, { 11111, 0x0000 }, { 11111, 0x0000 }, + /* 0x26FC0 */ + { 11111, 0x0000 }, { 11111, 0x0000 }, { 11111, 0x0000 }, { 11111, 0x01c0 }, + /* 0x270C0 */ + { 11114, 0x0000 }, { 11114, 0x0000 }, { 11114, 0x0000 }, { 11114, 0x0010 }, + /* 0x27100 */ + { 11115, 0x2000 }, { 11116, 0x0000 }, { 11116, 0x0000 }, { 11116, 0x0200 }, + /* 0x273C0 */ + { 11117, 0x0000 }, { 11117, 0x0c00 }, { 11119, 0x0000 }, { 11119, 0x4000 }, + /* 0x27400 */ + { 11120, 0x0000 }, { 11120, 0x0001 }, { 11121, 0x0000 }, { 11121, 0x0000 }, + /* 0x27440 */ + { 11121, 0x0200 }, { 11122, 0x0000 }, { 11122, 0x0000 }, { 11122, 0x0000 }, + /* 0x27600 */ + { 11122, 0x0000 }, { 11122, 0x0030 }, { 11124, 0x0000 }, { 11124, 0x0002 }, + /* 0x27680 */ + { 11125, 0x0010 }, { 11126, 0x0008 }, { 11127, 0x0000 }, { 11127, 0x0000 }, + /* 0x27700 */ + { 11127, 0x4000 }, { 11128, 0x0000 }, { 11128, 0x0008 }, { 11129, 0x0000 }, + /* 0x27740 */ + { 11129, 0x0000 }, { 11129, 0x0004 }, { 11130, 0x0000 }, { 11130, 0x0000 }, + /* 0x27980 */ + { 11130, 0x0020 }, { 11131, 0x0000 }, { 11131, 0x0000 }, { 11131, 0x0000 }, + /* 0x27A80 */ + { 11131, 0x0010 }, { 11132, 0x0000 }, { 11132, 0x0000 }, { 11132, 0x0000 }, + /* 0x27B80 */ + { 11132, 0x0000 }, { 11132, 0x0000 }, { 11132, 0x0000 }, { 11132, 0x4008 }, + /* 0x27BC0 */ + { 11134, 0x0080 }, { 11135, 0x0000 }, { 11135, 0x0000 }, { 11135, 0x0000 }, + /* 0x27C80 */ + { 11135, 0x0000 }, { 11135, 0x0000 }, { 11135, 0x0000 }, { 11135, 0x0100 }, + /* 0x27D80 */ + { 11136, 0x0000 }, { 11136, 0x0000 }, { 11136, 0x0001 }, { 11137, 0x0000 }, + /* 0x27E00 */ + { 11137, 0x0000 }, { 11137, 0x0001 }, { 11138, 0x0000 }, { 11138, 0x0000 }, + /* 0x27F80 */ + { 11138, 0x0000 }, { 11138, 0x0000 }, { 11138, 0x0000 }, { 11138, 0x0080 }, + /* 0x28080 */ + { 11139, 0x0400 }, { 11140, 0x0000 }, { 11140, 0x0000 }, { 11140, 0x0800 }, + /* 0x28240 */ + { 11141, 0x0000 }, { 11141, 0x0000 }, { 11141, 0x0000 }, { 11141, 0x0080 }, + /* 0x28280 */ + { 11142, 0x0004 }, { 11143, 0x0000 }, { 11143, 0x0000 }, { 11143, 0x0000 }, + /* 0x282C0 */ + { 11143, 0x0000 }, { 11143, 0x0000 }, { 11143, 0x0000 }, { 11143, 0x0008 }, + /* 0x283C0 */ + { 11144, 0x2000 }, { 11145, 0x0000 }, { 11145, 0x0000 }, { 11145, 0x0000 }, + /* 0x28400 */ + { 11145, 0x1000 }, { 11146, 0x0000 }, { 11146, 0x0000 }, { 11146, 0x0000 }, + /* 0x28440 */ + { 11146, 0x0000 }, { 11146, 0x0020 }, { 11147, 0x0000 }, { 11147, 0x0000 }, + /* 0x28540 */ + { 11147, 0x0000 }, { 11147, 0x0000 }, { 11147, 0x0800 }, { 11148, 0x0000 }, + /* 0x285C0 */ + { 11148, 0x0300 }, { 11150, 0x0000 }, { 11150, 0x0000 }, { 11150, 0x0000 }, + /* 0x286C0 */ + { 11150, 0x0000 }, { 11150, 0x0080 }, { 11151, 0x0000 }, { 11151, 0x0400 }, + /* 0x28940 */ + { 11152, 0x0240 }, { 11154, 0x0000 }, { 11154, 0x0800 }, { 11155, 0x0000 }, + /* 0x28980 */ + { 11155, 0x0180 }, { 11157, 0x0000 }, { 11157, 0x0000 }, { 11157, 0x0c00 }, + /* 0x28A00 */ + { 11159, 0x0000 }, { 11159, 0x4000 }, { 11160, 0x0200 }, { 11161, 0x0000 }, + /* 0x28A40 */ + { 11161, 0x0008 }, { 11162, 0x0000 }, { 11162, 0x0000 }, { 11162, 0x0002 }, + /* 0x28A80 */ + { 11163, 0x0000 }, { 11163, 0x0200 }, { 11164, 0x0000 }, { 11164, 0x0000 }, + /* 0x28AC0 */ + { 11164, 0x2000 }, { 11165, 0x2000 }, { 11166, 0x0010 }, { 11167, 0x0000 }, + /* 0x28BC0 */ + { 11167, 0x0002 }, { 11168, 0x0000 }, { 11168, 0x8000 }, { 11169, 0x0000 }, + /* 0x28D00 */ + { 11169, 0x0000 }, { 11169, 0x0001 }, { 11170, 0x0000 }, { 11170, 0x0000 }, + /* 0x28D40 */ + { 11170, 0x0000 }, { 11170, 0x0000 }, { 11170, 0x0000 }, { 11170, 0x0002 }, + /* 0x28DC0 */ + { 11171, 0x0000 }, { 11171, 0x0000 }, { 11171, 0x0000 }, { 11171, 0x0800 }, + /* 0x28E00 */ + { 11172, 0x0000 }, { 11172, 0x8000 }, { 11173, 0x0000 }, { 11173, 0x0040 }, + /* 0x28E80 */ + { 11174, 0x0200 }, { 11175, 0x0000 }, { 11175, 0x0000 }, { 11175, 0x0000 }, + /* 0x28EC0 */ + { 11175, 0x0000 }, { 11175, 0x0000 }, { 11175, 0x0800 }, { 11176, 0x0000 }, + /* 0x28F00 */ + { 11176, 0x0000 }, { 11176, 0x0000 }, { 11176, 0x0000 }, { 11176, 0x0004 }, + /* 0x28FC0 */ + { 11177, 0x0000 }, { 11177, 0x0000 }, { 11177, 0x0000 }, { 11177, 0x0100 }, + /* 0x29280 */ + { 11178, 0x0000 }, { 11178, 0x0000 }, { 11178, 0x0001 }, { 11179, 0x0002 }, + /* 0x29480 */ + { 11180, 0x0000 }, { 11180, 0x0001 }, { 11181, 0x0000 }, { 11181, 0x0000 }, + /* 0x295C0 */ + { 11181, 0x8000 }, { 11182, 0x0000 }, { 11182, 0x0000 }, { 11182, 0x0000 }, + /* 0x29640 */ + { 11182, 0x0000 }, { 11182, 0x0000 }, { 11182, 0x0000 }, { 11182, 0x8000 }, + /* 0x296C0 */ + { 11183, 0x0000 }, { 11183, 0x0000 }, { 11183, 0x0000 }, { 11183, 0x0001 }, + /* 0x29700 */ + { 11184, 0x0000 }, { 11184, 0x0200 }, { 11185, 0x0000 }, { 11185, 0x0000 }, + /* 0x29740 */ + { 11185, 0x0000 }, { 11185, 0x0001 }, { 11186, 0x0000 }, { 11186, 0x0000 }, + /* 0x298C0 */ + { 11186, 0x0040 }, { 11187, 0x0000 }, { 11187, 0x0000 }, { 11187, 0x0000 }, + /* 0x29A40 */ + { 11187, 0x0000 }, { 11187, 0x0000 }, { 11187, 0x0000 }, { 11187, 0x0004 }, + /* 0x29DC0 */ + { 11188, 0x0000 }, { 11188, 0x0800 }, { 11189, 0x0000 }, { 11189, 0x0000 }, + /* 0x29E00 */ + { 11189, 0x0000 }, { 11189, 0x0020 }, { 11190, 0x0000 }, { 11190, 0x2000 }, + /* 0x29E40 */ + { 11191, 0x0200 }, { 11192, 0x0000 }, { 11192, 0x0000 }, { 11192, 0x0000 }, + /* 0x29E80 */ + { 11192, 0x0400 }, { 11193, 0x0000 }, { 11193, 0x0000 }, { 11193, 0x0000 }, + /* 0x29EC0 */ + { 11193, 0x0010 }, { 11194, 0x0800 }, { 11195, 0x0200 }, { 11196, 0x0000 }, + /* 0x29FC0 */ + { 11196, 0x4000 }, { 11197, 0x0000 }, { 11197, 0x0000 }, { 11197, 0x0000 }, + /* 0x2A000 */ + { 11197, 0x0000 }, { 11197, 0x0400 }, { 11198, 0x8000 }, { 11199, 0x0000 }, + /* 0x2A080 */ + { 11199, 0x0004 }, { 11200, 0x0000 }, { 11200, 0x0000 }, { 11200, 0x0000 }, + /* 0x2A0C0 */ + { 11200, 0x0000 }, { 11200, 0x0000 }, { 11200, 0x0000 }, { 11200, 0x0200 }, + /* 0x2A180 */ + { 11201, 0x0000 }, { 11201, 0x0001 }, { 11202, 0x0000 }, { 11202, 0x0000 }, + /* 0x2A380 */ + { 11202, 0x1000 }, { 11203, 0x0000 }, { 11203, 0x0000 }, { 11203, 0x0000 }, + /* 0x2A400 */ + { 11203, 0x0000 }, { 11203, 0x0000 }, { 11203, 0x0000 }, { 11203, 0x0080 }, + /* 0x2A5C0 */ + { 11204, 0x0000 }, { 11204, 0x0000 }, { 11204, 0x0000 }, { 11204, 0x0002 }, + /* 0x2A600 */ + { 11205, 0x0004 }, { 11206, 0x0400 }, { 11207, 0x0000 }, { 11207, 0x0000 }, + /* 0x2A680 */ + { 11207, 0x0000 }, { 11207, 0x0000 }, { 11207, 0x0000 }, { 11207, 0x0004 }, +}; + +#ifdef __GNUC__ +__inline +#else +#ifdef __cplusplus +inline +#endif +#endif +static ucs4_t jisx0213_to_ucs4 (unsigned int row, unsigned int col) +{ + ucs4_t val; + + if (row >= 0x121 && row <= 0x17e) + row -= 289; + else if (row == 0x221) + row -= 451; + else if (row >= 0x223 && row <= 0x225) + row -= 452; + else if (row == 0x228) + row -= 454; + else if (row >= 0x22c && row <= 0x22f) + row -= 457; + else if (row >= 0x26e && row <= 0x27e) + row -= 519; + else + return 0x0000; + + if (col >= 0x21 && col <= 0x7e) + col -= 0x21; + else + return 0x0000; + + val = jisx0213_to_ucs_main[row * 94 + col]; + val = jisx0213_to_ucs_pagestart[val >> 8] + (val & 0xff); + if (val == 0xfffd) + val = 0x0000; + return val; +} + +#ifdef __GNUC__ +__inline +#else +#ifdef __cplusplus +inline +#endif +#endif +static unsigned short ucs4_to_jisx0213 (ucs4_t ucs) +{ + if (ucs < (sizeof(jisx0213_from_ucs_level1)/sizeof(jisx0213_from_ucs_level1[0])) << 6) { + int index1 = jisx0213_from_ucs_level1[ucs >> 6]; + if (index1 >= 0) { + const Summary16 *summary = &jisx0213_from_ucs_level2_2indx[((index1 << 6) + (ucs & 0x3f)) >> 4]; + unsigned short used = summary->used; + unsigned int i = ucs & 0x0f; + if (used & ((unsigned short) 1 << i)) { + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + return jisx0213_from_ucs_level2_data[summary->indx + used]; + }; + }; + } + return 0x0000; +} + +#endif /* _JISX0213_H */ diff --git a/graf2d/win32gdk/gdk/src/iconv/johab.h b/graf2d/win32gdk/gdk/src/iconv/johab.h new file mode 100644 index 0000000000000..fb2c17f59e23e --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/johab.h @@ -0,0 +1,139 @@ +/* + * Copyright (C) 1999-2001, 2007 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * JOHAB + */ + +/* + Conversion between JOHAB codes (s1,s2) and KSX1001 codes (c1,c2): + Example. (s1,s2) = 0xD931, (c1,c2) = 0x2121. + (s1,s2) = 0xDEF1, (c1,c2) = 0x2C71. + (s1,s2) = 0xE031, (c1,c2) = 0x4A21. + (s1,s2) = 0xF9FE, (c1,c2) = 0x7D7E. + 0xD9 <= s1 <= 0xDE || 0xE0 <= s1 <= 0xF9, + 0x31 <= s2 <= 0x7E || 0x91 <= s2 <= 0xFE, + 0x21 <= c1 <= 0x2C || 0x4A <= c1 <= 0x7D, + 0x21 <= c2 <= 0x7E. + Invariant: + 94*(s1 < 0xE0 ? 2*s1-0x1B2 : 2*s1-0x197) + (s2 < 0x91 ? s2-0x31 : s2-0x43) + = 94*(c1-0x21)+(c2-0x21) + Conversion (s1,s2) -> (c1,c2): + t1 := (s1 < 0xE0 ? 2*s1-0x1B2 : 2*s1-0x197) + t2 := (s2 < 0x91 ? s2-0x31 : s2-0x43) + c1 := t1 + (t2 < 0x5E ? 0 : 1) + 0x21 + c2 := (t2 < 0x5E ? t2 : t2-0x5E) + 0x21 + Conversion (c1,c2) -> (s1,s2): + t := (c1 < 0x4A ? (c1-0x21+0x1B2) : (c1-0x21+0x197)) + s1 := t >> 1 + t2 := (t & 1) * 0x5E + (c2 - 0x21) + s2 := (t2 < 0x4E ? t2+0x31 : t2+0x43) + */ + +static int +johab_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + if (c == 0x5c) + *pwc = (ucs4_t) 0x20a9; + else + *pwc = (ucs4_t) c; + return 1; + } else if (c < 0xd8) { + return johab_hangul_mbtowc(conv,pwc,s,n); + } else { + unsigned char s1, s2; + s1 = c; + if ((s1 >= 0xd9 && s1 <= 0xde) || (s1 >= 0xe0 && s1 <= 0xf9)) { + if (n < 2) + return RET_TOOFEW(0); + s2 = s[1]; + if ((s2 >= 0x31 && s2 <= 0x7e) || (s2 >= 0x91 && s2 <= 0xfe)) { + /* In KSC 5601, now KS X 1001, the region s1 = 0xDA, 0xA1 <= s2 <= 0xD3 + contains the 51 Jamo (Hangul letters). But in the Johab encoding, + they have been moved to the Hangul section, see + johab_hangul_page31. */ + if (!(s1 == 0xda && (s2 >= 0xa1 && s2 <= 0xd3))) { + unsigned char t1 = (s1 < 0xe0 ? 2*(s1-0xd9) : 2*s1-0x197); + unsigned char t2 = (s2 < 0x91 ? s2-0x31 : s2-0x43); + unsigned char buf[2]; + buf[0] = t1 + (t2 < 0x5e ? 0 : 1) + 0x21; + buf[1] = (t2 < 0x5e ? t2 : t2-0x5e) + 0x21; + return ksc5601_mbtowc(conv,pwc,buf,2); + } + } + } + return RET_ILSEQ; + } +} + +static int +johab_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Try ASCII variation. */ + if (wc < 0x0080 && wc != 0x005c) { + *r = wc; + return 1; + } + if (wc == 0x20a9) { + *r = 0x5c; + return 1; + } + + /* Try JOHAB Hangul table before KSC5601 table, because the KSC5601 table + contains some (2350 out of 11172) Hangul syllables (rows 0x30XX..0x48XX), + and we want the search to return the JOHAB Hangul table entry. */ + + /* Try JOHAB Hangul. */ + ret = johab_hangul_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + r[0] = buf[0]; + r[1] = buf[1]; + return 2; + } + + /* Try KSC5601, now KS X 1001. */ + ret = ksc5601_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + unsigned char c1, c2; + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + c1 = buf[0]; + c2 = buf[1]; + if (((c1 >= 0x21 && c1 <= 0x2c) || (c1 >= 0x4a && c1 <= 0x7d)) + && (c2 >= 0x21 && c2 <= 0x7e)) { + unsigned int t = (c1 < 0x4A ? (c1-0x21+0x1B2) : (c1-0x21+0x197)); + unsigned char t2 = ((t & 1) ? 0x5e : 0) + (c2 - 0x21); + r[0] = t >> 1; + r[1] = (t2 < 0x4e ? t2+0x31 : t2+0x43); + return 2; + } + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/johab_hangul.h b/graf2d/win32gdk/gdk/src/iconv/johab_hangul.h new file mode 100644 index 0000000000000..68368dff1e70d --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/johab_hangul.h @@ -0,0 +1,262 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * JOHAB Hangul + * + * Ken Lunde writes in his "CJKV Information Processing" book, p. 114: + * "Hangul can be composed of two or three jamo (some jamo are considered + * compound). Johab uses 19 initial jamo (consonants), 21 medial jamo (vowels) + * and 27 final jamo (consonants; 28 when you include the "fill" character + * for Hangul containing only two jamo). Multiplying these numbers results in + * 11172." + * + * Structure of the Johab encoding (see p. 181-184): + * bit 15 = 1 + * bit 14..10 = initial jamo, only 19+1 out of 32 possible values are used + * bit 9..5 = medial jamo, only 21+1 out of 32 possible values are used + * bit 4..0 = final jamo, only 27+1 out of 32 possible values are used + * + * Structure of the Unicode encoding: + * grep '^0x\([8-C]...\|D[0-7]..\)' unicode.org-mappings/EASTASIA/KSC/JOHAB.TXT + * You see that all characters there are marked "HANGUL LETTER" or "HANGUL + * SYLLABLE". If you eliminate the "HANGUL LETTER"s, the table is sorted + * in ascending order according to Johab encoding and according to the Unicode + * encoding. Now look a little more carefully, and you see that the following + * formula holds: + * unicode == 0xAC00 + * + 21 * 28 * (jamo_initial_index[(johab >> 10) & 31] - 1) + * + 28 * (jamo_medial_index[(johab >> 5) & 31] - 1) + * + jamo_final_index[johab & 31] + * where the index tables are defined as below. + */ + +/* Tables mapping 5-bit groups to jamo letters. */ +/* Note that Jamo XX = UHC 0xA4A0+XX = Unicode 0x3130+XX */ +#define NONE 0xfd +#define FILL 0xff +static const unsigned char jamo_initial[32] = { + NONE, FILL, 0x01, 0x02, 0x04, 0x07, 0x08, 0x09, + 0x11, 0x12, 0x13, 0x15, 0x16, 0x17, 0x18, 0x19, + 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, NONE, NONE, NONE, + NONE, NONE, NONE, NONE, NONE, NONE, NONE, NONE, +}; +static const unsigned char jamo_medial[32] = { + NONE, NONE, FILL, 0x1f, 0x20, 0x21, 0x22, 0x23, + NONE, NONE, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, + NONE, NONE, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + NONE, NONE, 0x30, 0x31, 0x32, 0x33, NONE, NONE, +}; +static const unsigned char jamo_final[32] = { + NONE, FILL, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, NONE, 0x12, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, NONE, NONE, +}; +/* Same as jamo_final, except that it excludes characters already + contained in jamo_initial. 11 characters instead of 27. */ +static const unsigned char jamo_final_notinitial[32] = { + NONE, NONE, NONE, NONE, 0x03, NONE, 0x05, 0x06, + NONE, NONE, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, NONE, NONE, NONE, 0x14, NONE, NONE, NONE, + NONE, NONE, NONE, NONE, NONE, NONE, NONE, NONE, +}; + +/* Tables mapping 5-bit groups to packed indices. */ +#define none -1 +#define fill 0 +static const signed char jamo_initial_index[32] = { + none, fill, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, + 0x0f, 0x10, 0x11, 0x12, 0x13, none, none, none, + none, none, none, none, none, none, none, none, +}; +static const signed char jamo_medial_index[32] = { + none, none, fill, 0x01, 0x02, 0x03, 0x04, 0x05, + none, none, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, + none, none, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, + none, none, 0x12, 0x13, 0x14, 0x15, none, none, +}; +static const signed char jamo_final_index[32] = { + none, fill, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, + 0x0f, 0x10, none, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, none, none, +}; + +static int +johab_hangul_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x84 && c1 <= 0xd3)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x41 && c2 < 0x7f) || (c2 >= 0x81 && c2 < 0xff)) { + unsigned int johab = (c1 << 8) | c2; + unsigned int bitspart1 = (johab >> 10) & 31; + unsigned int bitspart2 = (johab >> 5) & 31; + unsigned int bitspart3 = johab & 31; + int index1 = jamo_initial_index[bitspart1]; + int index2 = jamo_medial_index[bitspart2]; + int index3 = jamo_final_index[bitspart3]; + /* Exclude "none" values. */ + if (index1 >= 0 && index2 >= 0 && index3 >= 0) { + /* Deal with "fill" values in initial or medial position. */ + if (index1 == fill) { + if (index2 == fill) { + unsigned char jamo3 = jamo_final_notinitial[bitspart3]; + if (jamo3 != NONE) { + *pwc = (ucs4_t) 0x3130 + jamo3; + return 2; + } + } else if (index3 == fill) { + unsigned char jamo2 = jamo_medial[bitspart2]; + if (jamo2 != NONE && jamo2 != FILL) { + *pwc = (ucs4_t) 0x3130 + jamo2; + return 2; + } + } + /* Syllables composed only of medial and final don't exist. */ + } else if (index2 == fill) { + if (index3 == fill) { + unsigned char jamo1 = jamo_initial[bitspart1]; + if (jamo1 != NONE && jamo1 != FILL) { + *pwc = (ucs4_t) 0x3130 + jamo1; + return 2; + } + } + /* Syllables composed only of initial and final don't exist. */ + } else { + /* index1 and index2 are not fill, but index3 may be fill. */ + /* Nothing more to exclude. All 11172 code points are valid. */ + *pwc = 0xac00 + ((index1 - 1) * 21 + (index2 - 1)) * 28 + index3; + return 2; + } + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +/* 51 Jamo: 19 initial, 21 medial, 11 final not initial. */ +static const unsigned short johab_hangul_page31[51] = { + 0x8841, 0x8c41, 0x8444, 0x9041, 0x8446, 0x8447, 0x9441, /*0x30-0x37*/ + 0x9841, 0x9c41, 0x844a, 0x844b, 0x844c, 0x844d, 0x844e, 0x844f, /*0x38-0x3f*/ + 0x8450, 0xa041, 0xa441, 0xa841, 0x8454, 0xac41, 0xb041, 0xb441, /*0x40-0x47*/ + 0xb841, 0xbc41, 0xc041, 0xc441, 0xc841, 0xcc41, 0xd041, 0x8461, /*0x48-0x4f*/ + 0x8481, 0x84a1, 0x84c1, 0x84e1, 0x8541, 0x8561, 0x8581, 0x85a1, /*0x50-0x57*/ + 0x85c1, 0x85e1, 0x8641, 0x8661, 0x8681, 0x86a1, 0x86c1, 0x86e1, /*0x58-0x5f*/ + 0x8741, 0x8761, 0x8781, 0x87a1, /*0x60-0x67*/ +}; + +/* Tables mapping packed indices to 5-bit groups. */ +/* index1+1 = jamo_initial_index[bitspart1] <==> + bitspart1 = jamo_initial_index_inverse[index1] */ +static const char jamo_initial_index_inverse[19] = { + 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, +}; +/* index2+1 = jamo_medial_index[bitspart2] <==> + bitspart2 = jamo_medial_index_inverse[index2] */ +static const char jamo_medial_index_inverse[21] = { + 0x03, 0x04, 0x05, 0x06, 0x07, + 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x1a, 0x1b, 0x1c, 0x1d, +}; +/* index3 = jamo_final_index[bitspart3] <==> + bitspart3 = jamo_final_index_inverse[index3] */ +static const char jamo_final_index_inverse[28] = { + 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, +}; + +static int +johab_hangul_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + if (wc >= 0x3131 && wc < 0x3164) { + unsigned short c = johab_hangul_page31[wc-0x3131]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } else if (wc >= 0xac00 && wc < 0xd7a4) { + unsigned int index1; + unsigned int index2; + unsigned int index3; + unsigned short c; + unsigned int tmp = wc - 0xac00; + index3 = tmp % 28; tmp = tmp / 28; + index2 = tmp % 21; tmp = tmp / 21; + index1 = tmp; + c = (((((1 << 5) + | jamo_initial_index_inverse[index1]) << 5) + | jamo_medial_index_inverse[index2]) << 5) + | jamo_final_index_inverse[index3]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} + +/* + * Decomposition of JOHAB Hangul in one to three Johab Jamo elements. + */ + +/* Decompose wc into r[0..2], and return the number of resulting Jamo elements. + Return RET_ILUNI if decomposition is not possible. */ + +static int johab_hangul_decompose (conv_t conv, ucs4_t* r, ucs4_t wc) +{ + unsigned char buf[2]; + int ret = johab_hangul_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + unsigned int hangul = (buf[0] << 8) | buf[1]; + unsigned char jamo1 = jamo_initial[(hangul >> 10) & 31]; + unsigned char jamo2 = jamo_medial[(hangul >> 5) & 31]; + unsigned char jamo3 = jamo_final[hangul & 31]; + if ((hangul >> 15) != 1) abort(); + if (jamo1 != NONE && jamo2 != NONE && jamo3 != NONE) { + /* They are not all three == FILL because that would correspond to + johab = 0x8441, which doesn't exist. */ + ucs4_t* p = r; + if (jamo1 != FILL) + *p++ = 0x3130 + jamo1; + if (jamo2 != FILL) + *p++ = 0x3130 + jamo2; + if (jamo3 != FILL) + *p++ = 0x3130 + jamo3; + return p-r; + } + } + return RET_ILUNI; +} + +#undef fill +#undef none +#undef FILL +#undef NONE diff --git a/graf2d/win32gdk/gdk/src/iconv/koi8_r.h b/graf2d/win32gdk/gdk/src/iconv/koi8_r.h new file mode 100644 index 0000000000000..3e435368f1964 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/koi8_r.h @@ -0,0 +1,153 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * KOI8-R + */ + +/* Specification: RFC 1489 */ + +static const unsigned short koi8_r_2uni[128] = { + /* 0x80 */ + 0x2500, 0x2502, 0x250c, 0x2510, 0x2514, 0x2518, 0x251c, 0x2524, + 0x252c, 0x2534, 0x253c, 0x2580, 0x2584, 0x2588, 0x258c, 0x2590, + /* 0x90 */ + 0x2591, 0x2592, 0x2593, 0x2320, 0x25a0, 0x2219, 0x221a, 0x2248, + 0x2264, 0x2265, 0x00a0, 0x2321, 0x00b0, 0x00b2, 0x00b7, 0x00f7, + /* 0xa0 */ + 0x2550, 0x2551, 0x2552, 0x0451, 0x2553, 0x2554, 0x2555, 0x2556, + 0x2557, 0x2558, 0x2559, 0x255a, 0x255b, 0x255c, 0x255d, 0x255e, + /* 0xb0 */ + 0x255f, 0x2560, 0x2561, 0x0401, 0x2562, 0x2563, 0x2564, 0x2565, + 0x2566, 0x2567, 0x2568, 0x2569, 0x256a, 0x256b, 0x256c, 0x00a9, + /* 0xc0 */ + 0x044e, 0x0430, 0x0431, 0x0446, 0x0434, 0x0435, 0x0444, 0x0433, + 0x0445, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, + /* 0xd0 */ + 0x043f, 0x044f, 0x0440, 0x0441, 0x0442, 0x0443, 0x0436, 0x0432, + 0x044c, 0x044b, 0x0437, 0x0448, 0x044d, 0x0449, 0x0447, 0x044a, + /* 0xe0 */ + 0x042e, 0x0410, 0x0411, 0x0426, 0x0414, 0x0415, 0x0424, 0x0413, + 0x0425, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, + /* 0xf0 */ + 0x041f, 0x042f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0416, 0x0412, + 0x042c, 0x042b, 0x0417, 0x0428, 0x042d, 0x0429, 0x0427, 0x042a, +}; + +static int +koi8_r_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) koi8_r_2uni[c-0x80]; + return 1; +} + +static const unsigned char koi8_r_page00[88] = { + 0x9a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0xbf, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x9c, 0x00, 0x9d, 0x00, 0x00, 0x00, 0x00, 0x9e, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9f, /* 0xf0-0xf7 */ +}; +static const unsigned char koi8_r_page04[88] = { + 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xe1, 0xe2, 0xf7, 0xe7, 0xe4, 0xe5, 0xf6, 0xfa, /* 0x10-0x17 */ + 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, 0xf0, /* 0x18-0x1f */ + 0xf2, 0xf3, 0xf4, 0xf5, 0xe6, 0xe8, 0xe3, 0xfe, /* 0x20-0x27 */ + 0xfb, 0xfd, 0xff, 0xf9, 0xf8, 0xfc, 0xe0, 0xf1, /* 0x28-0x2f */ + 0xc1, 0xc2, 0xd7, 0xc7, 0xc4, 0xc5, 0xd6, 0xda, /* 0x30-0x37 */ + 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, 0xd0, /* 0x38-0x3f */ + 0xd2, 0xd3, 0xd4, 0xd5, 0xc6, 0xc8, 0xc3, 0xde, /* 0x40-0x47 */ + 0xdb, 0xdd, 0xdf, 0xd9, 0xd8, 0xdc, 0xc0, 0xd1, /* 0x48-0x4f */ + 0x00, 0xa3, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ +}; +static const unsigned char koi8_r_page22[80] = { + 0x00, 0x95, 0x96, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x97, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x98, 0x99, 0x00, 0x00, /* 0x60-0x67 */ +}; +static const unsigned char koi8_r_page23[8] = { + 0x93, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char koi8_r_page25[168] = { + 0x80, 0x00, 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x82, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x83, 0x00, 0x00, 0x00, 0x84, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x85, 0x00, 0x00, 0x00, 0x86, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x87, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x89, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x8a, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xa0, 0xa1, 0xa2, 0xa4, 0xa5, 0xa6, 0xa7, 0xa8, /* 0x50-0x57 */ + 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, 0xb0, /* 0x58-0x5f */ + 0xb1, 0xb2, 0xb4, 0xb5, 0xb6, 0xb7, 0xb8, 0xb9, /* 0x60-0x67 */ + 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x8b, 0x00, 0x00, 0x00, 0x8c, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x8d, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x8f, 0x90, 0x91, 0x92, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x94, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +koi8_r_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00f8) + c = koi8_r_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x0458) + c = koi8_r_page04[wc-0x0400]; + else if (wc >= 0x2218 && wc < 0x2268) + c = koi8_r_page22[wc-0x2218]; + else if (wc >= 0x2320 && wc < 0x2328) + c = koi8_r_page23[wc-0x2320]; + else if (wc >= 0x2500 && wc < 0x25a8) + c = koi8_r_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/koi8_ru.h b/graf2d/win32gdk/gdk/src/iconv/koi8_ru.h new file mode 100644 index 0000000000000..e43ae72032229 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/koi8_ru.h @@ -0,0 +1,159 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * KOI8-RU + */ + +static const unsigned short koi8_ru_2uni[128] = { + /* 0x80 */ + 0x2500, 0x2502, 0x250c, 0x2510, 0x2514, 0x2518, 0x251c, 0x2524, + 0x252c, 0x2534, 0x253c, 0x2580, 0x2584, 0x2588, 0x258c, 0x2590, + /* 0x90 */ + 0x2591, 0x2592, 0x2593, 0x2320, 0x25a0, 0x2219, 0x221a, 0x2248, + 0x2264, 0x2265, 0x00a0, 0x2321, 0x00b0, 0x00b2, 0x00b7, 0x00f7, + /* 0xa0 */ + 0x2550, 0x2551, 0x2552, 0x0451, 0x0454, 0x2554, 0x0456, 0x0457, + 0x2557, 0x2558, 0x2559, 0x255a, 0x255b, 0x0491, 0x045e, 0x255e, + /* 0xb0 */ + 0x255f, 0x2560, 0x2561, 0x0401, 0x0404, 0x2563, 0x0406, 0x0407, + 0x2566, 0x2567, 0x2568, 0x2569, 0x256a, 0x0490, 0x040e, 0x00a9, + /* 0xc0 */ + 0x044e, 0x0430, 0x0431, 0x0446, 0x0434, 0x0435, 0x0444, 0x0433, + 0x0445, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, + /* 0xd0 */ + 0x043f, 0x044f, 0x0440, 0x0441, 0x0442, 0x0443, 0x0436, 0x0432, + 0x044c, 0x044b, 0x0437, 0x0448, 0x044d, 0x0449, 0x0447, 0x044a, + /* 0xe0 */ + 0x042e, 0x0410, 0x0411, 0x0426, 0x0414, 0x0415, 0x0424, 0x0413, + 0x0425, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, + /* 0xf0 */ + 0x041f, 0x042f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0416, 0x0412, + 0x042c, 0x042b, 0x0417, 0x0428, 0x042d, 0x0429, 0x0427, 0x042a, +}; + +static int +koi8_ru_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) koi8_ru_2uni[c-0x80]; + return 1; +} + +static const unsigned char koi8_ru_page00[88] = { + 0x9a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0xbf, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x9c, 0x00, 0x9d, 0x00, 0x00, 0x00, 0x00, 0x9e, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9f, /* 0xf0-0xf7 */ +}; +static const unsigned char koi8_ru_page04[152] = { + 0x00, 0xb3, 0x00, 0x00, 0xb4, 0x00, 0xb6, 0xb7, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xbe, 0x00, /* 0x08-0x0f */ + 0xe1, 0xe2, 0xf7, 0xe7, 0xe4, 0xe5, 0xf6, 0xfa, /* 0x10-0x17 */ + 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, 0xf0, /* 0x18-0x1f */ + 0xf2, 0xf3, 0xf4, 0xf5, 0xe6, 0xe8, 0xe3, 0xfe, /* 0x20-0x27 */ + 0xfb, 0xfd, 0xff, 0xf9, 0xf8, 0xfc, 0xe0, 0xf1, /* 0x28-0x2f */ + 0xc1, 0xc2, 0xd7, 0xc7, 0xc4, 0xc5, 0xd6, 0xda, /* 0x30-0x37 */ + 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, 0xd0, /* 0x38-0x3f */ + 0xd2, 0xd3, 0xd4, 0xd5, 0xc6, 0xc8, 0xc3, 0xde, /* 0x40-0x47 */ + 0xdb, 0xdd, 0xdf, 0xd9, 0xd8, 0xdc, 0xc0, 0xd1, /* 0x48-0x4f */ + 0x00, 0xa3, 0x00, 0x00, 0xa4, 0x00, 0xa6, 0xa7, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xae, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xbd, 0xad, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char koi8_ru_page22[80] = { + 0x00, 0x95, 0x96, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x97, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x98, 0x99, 0x00, 0x00, /* 0x60-0x67 */ +}; +static const unsigned char koi8_ru_page23[8] = { + 0x93, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char koi8_ru_page25[168] = { + 0x80, 0x00, 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x82, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x83, 0x00, 0x00, 0x00, 0x84, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x85, 0x00, 0x00, 0x00, 0x86, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x87, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x89, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x8a, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xa0, 0xa1, 0xa2, 0x00, 0xa5, 0x00, 0x00, 0xa8, /* 0x50-0x57 */ + 0xa9, 0xaa, 0xab, 0xac, 0x00, 0x00, 0xaf, 0xb0, /* 0x58-0x5f */ + 0xb1, 0xb2, 0x00, 0xb5, 0x00, 0x00, 0xb8, 0xb9, /* 0x60-0x67 */ + 0xba, 0xbb, 0xbc, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x8b, 0x00, 0x00, 0x00, 0x8c, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x8d, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x8f, 0x90, 0x91, 0x92, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x94, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +koi8_ru_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00f8) + c = koi8_ru_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x0498) + c = koi8_ru_page04[wc-0x0400]; + else if (wc >= 0x2218 && wc < 0x2268) + c = koi8_ru_page22[wc-0x2218]; + else if (wc >= 0x2320 && wc < 0x2328) + c = koi8_ru_page23[wc-0x2320]; + else if (wc >= 0x2500 && wc < 0x25a8) + c = koi8_ru_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/koi8_t.h b/graf2d/win32gdk/gdk/src/iconv/koi8_t.h new file mode 100644 index 0000000000000..0f7a5685294b7 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/koi8_t.h @@ -0,0 +1,143 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * KOI8-T + */ + +static const unsigned short koi8_t_2uni[128] = { + /* 0x80 */ + 0x049b, 0x0493, 0x201a, 0x0492, 0x201e, 0x2026, 0x2020, 0x2021, + 0xfffd, 0x2030, 0x04b3, 0x2039, 0x04b2, 0x04b7, 0x04b6, 0xfffd, + /* 0x90 */ + 0x049a, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0xfffd, 0x2122, 0xfffd, 0x203a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xa0 */ + 0xfffd, 0x04ef, 0x04ee, 0x0451, 0x00a4, 0x04e3, 0x00a6, 0x00a7, + 0xfffd, 0xfffd, 0xfffd, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0xfffd, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x00b2, 0x0401, 0xfffd, 0x04e2, 0x00b6, 0x00b7, + 0xfffd, 0x2116, 0xfffd, 0x00bb, 0xfffd, 0xfffd, 0xfffd, 0x00a9, + /* 0xc0 */ + 0x044e, 0x0430, 0x0431, 0x0446, 0x0434, 0x0435, 0x0444, 0x0433, + 0x0445, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, + /* 0xd0 */ + 0x043f, 0x044f, 0x0440, 0x0441, 0x0442, 0x0443, 0x0436, 0x0432, + 0x044c, 0x044b, 0x0437, 0x0448, 0x044d, 0x0449, 0x0447, 0x044a, + /* 0xe0 */ + 0x042e, 0x0410, 0x0411, 0x0426, 0x0414, 0x0415, 0x0424, 0x0413, + 0x0425, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, + /* 0xf0 */ + 0x041f, 0x042f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0416, 0x0412, + 0x042c, 0x042b, 0x0417, 0x0428, 0x042d, 0x0429, 0x0427, 0x042a, +}; + +static int +koi8_t_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = koi8_t_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char koi8_t_page00[32] = { + 0x00, 0x00, 0x00, 0x00, 0xa4, 0x00, 0xa6, 0xa7, /* 0xa0-0xa7 */ + 0x00, 0xbf, 0x00, 0xab, 0xac, 0xad, 0xae, 0x00, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0xb2, 0x00, 0x00, 0x00, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xbb, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ +}; +static const unsigned char koi8_t_page04[240] = { + 0x00, 0xb3, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xe1, 0xe2, 0xf7, 0xe7, 0xe4, 0xe5, 0xf6, 0xfa, /* 0x10-0x17 */ + 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, 0xf0, /* 0x18-0x1f */ + 0xf2, 0xf3, 0xf4, 0xf5, 0xe6, 0xe8, 0xe3, 0xfe, /* 0x20-0x27 */ + 0xfb, 0xfd, 0xff, 0xf9, 0xf8, 0xfc, 0xe0, 0xf1, /* 0x28-0x2f */ + 0xc1, 0xc2, 0xd7, 0xc7, 0xc4, 0xc5, 0xd6, 0xda, /* 0x30-0x37 */ + 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, 0xd0, /* 0x38-0x3f */ + 0xd2, 0xd3, 0xd4, 0xd5, 0xc6, 0xc8, 0xc3, 0xde, /* 0x40-0x47 */ + 0xdb, 0xdd, 0xdf, 0xd9, 0xd8, 0xdc, 0xc0, 0xd1, /* 0x48-0x4f */ + 0x00, 0xa3, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x83, 0x81, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x90, 0x80, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0x00, 0x8c, 0x8a, 0x00, 0x00, 0x8e, 0x8d, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x00, 0x00, 0xb5, 0xa5, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa2, 0xa1, /* 0xe8-0xef */ +}; +static const unsigned char koi8_t_page20[48] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; +static const unsigned char koi8_t_page21[24] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb9, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x99, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; + +static int +koi8_t_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = koi8_t_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x04f0) + c = koi8_t_page04[wc-0x0400]; + else if (wc >= 0x2010 && wc < 0x2040) + c = koi8_t_page20[wc-0x2010]; + else if (wc >= 0x2110 && wc < 0x2128) + c = koi8_t_page21[wc-0x2110]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/koi8_u.h b/graf2d/win32gdk/gdk/src/iconv/koi8_u.h new file mode 100644 index 0000000000000..0637d5854f4e1 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/koi8_u.h @@ -0,0 +1,161 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * KOI8-U + */ + +/* Specification: RFC 2319 */ + +static const unsigned short koi8_u_2uni[128] = { + /* 0x80 */ + 0x2500, 0x2502, 0x250c, 0x2510, 0x2514, 0x2518, 0x251c, 0x2524, + 0x252c, 0x2534, 0x253c, 0x2580, 0x2584, 0x2588, 0x258c, 0x2590, + /* 0x90 */ + 0x2591, 0x2592, 0x2593, 0x2320, 0x25a0, 0x2219, 0x221a, 0x2248, + 0x2264, 0x2265, 0x00a0, 0x2321, 0x00b0, 0x00b2, 0x00b7, 0x00f7, + /* 0xa0 */ + 0x2550, 0x2551, 0x2552, 0x0451, 0x0454, 0x2554, 0x0456, 0x0457, + 0x2557, 0x2558, 0x2559, 0x255a, 0x255b, 0x0491, 0x255d, 0x255e, + /* 0xb0 */ + 0x255f, 0x2560, 0x2561, 0x0401, 0x0404, 0x2563, 0x0406, 0x0407, + 0x2566, 0x2567, 0x2568, 0x2569, 0x256a, 0x0490, 0x256c, 0x00a9, + /* 0xc0 */ + 0x044e, 0x0430, 0x0431, 0x0446, 0x0434, 0x0435, 0x0444, 0x0433, + 0x0445, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, + /* 0xd0 */ + 0x043f, 0x044f, 0x0440, 0x0441, 0x0442, 0x0443, 0x0436, 0x0432, + 0x044c, 0x044b, 0x0437, 0x0448, 0x044d, 0x0449, 0x0447, 0x044a, + /* 0xe0 */ + 0x042e, 0x0410, 0x0411, 0x0426, 0x0414, 0x0415, 0x0424, 0x0413, + 0x0425, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, + /* 0xf0 */ + 0x041f, 0x042f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0416, 0x0412, + 0x042c, 0x042b, 0x0417, 0x0428, 0x042d, 0x0429, 0x0427, 0x042a, +}; + +static int +koi8_u_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) koi8_u_2uni[c-0x80]; + return 1; +} + +static const unsigned char koi8_u_page00[88] = { + 0x9a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0xbf, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x9c, 0x00, 0x9d, 0x00, 0x00, 0x00, 0x00, 0x9e, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9f, /* 0xf0-0xf7 */ +}; +static const unsigned char koi8_u_page04[152] = { + 0x00, 0xb3, 0x00, 0x00, 0xb4, 0x00, 0xb6, 0xb7, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xe1, 0xe2, 0xf7, 0xe7, 0xe4, 0xe5, 0xf6, 0xfa, /* 0x10-0x17 */ + 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, 0xf0, /* 0x18-0x1f */ + 0xf2, 0xf3, 0xf4, 0xf5, 0xe6, 0xe8, 0xe3, 0xfe, /* 0x20-0x27 */ + 0xfb, 0xfd, 0xff, 0xf9, 0xf8, 0xfc, 0xe0, 0xf1, /* 0x28-0x2f */ + 0xc1, 0xc2, 0xd7, 0xc7, 0xc4, 0xc5, 0xd6, 0xda, /* 0x30-0x37 */ + 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, 0xd0, /* 0x38-0x3f */ + 0xd2, 0xd3, 0xd4, 0xd5, 0xc6, 0xc8, 0xc3, 0xde, /* 0x40-0x47 */ + 0xdb, 0xdd, 0xdf, 0xd9, 0xd8, 0xdc, 0xc0, 0xd1, /* 0x48-0x4f */ + 0x00, 0xa3, 0x00, 0x00, 0xa4, 0x00, 0xa6, 0xa7, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xbd, 0xad, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char koi8_u_page22[80] = { + 0x00, 0x95, 0x96, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x97, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x98, 0x99, 0x00, 0x00, /* 0x60-0x67 */ +}; +static const unsigned char koi8_u_page23[8] = { + 0x93, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char koi8_u_page25[168] = { + 0x80, 0x00, 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x82, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x83, 0x00, 0x00, 0x00, 0x84, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x85, 0x00, 0x00, 0x00, 0x86, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x87, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x89, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x8a, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0xa0, 0xa1, 0xa2, 0x00, 0xa5, 0x00, 0x00, 0xa8, /* 0x50-0x57 */ + 0xa9, 0xaa, 0xab, 0xac, 0x00, 0xae, 0xaf, 0xb0, /* 0x58-0x5f */ + 0xb1, 0xb2, 0x00, 0xb5, 0x00, 0x00, 0xb8, 0xb9, /* 0x60-0x67 */ + 0xba, 0xbb, 0xbc, 0x00, 0xbe, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x8b, 0x00, 0x00, 0x00, 0x8c, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x8d, 0x00, 0x00, 0x00, 0x8e, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x8f, 0x90, 0x91, 0x92, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x94, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ +}; + +static int +koi8_u_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00f8) + c = koi8_u_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x0498) + c = koi8_u_page04[wc-0x0400]; + else if (wc >= 0x2218 && wc < 0x2268) + c = koi8_u_page22[wc-0x2218]; + else if (wc >= 0x2320 && wc < 0x2328) + c = koi8_u_page23[wc-0x2320]; + else if (wc >= 0x2500 && wc < 0x25a8) + c = koi8_u_page25[wc-0x2500]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/ksc5601.h b/graf2d/win32gdk/gdk/src/iconv/ksc5601.h new file mode 100644 index 0000000000000..fd166232176cf --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ksc5601.h @@ -0,0 +1,3022 @@ +/* + * Copyright (C) 1999-2007 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * KSC5601.1987-0, now KS X 1001:2002 + */ + +static const unsigned short ksc5601_2uni_page21[1115] = { + /* 0x21 */ + 0x3000, 0x3001, 0x3002, 0x00b7, 0x2025, 0x2026, 0x00a8, 0x3003, + 0x00ad, 0x2015, 0x2225, 0xff3c, 0x223c, 0x2018, 0x2019, 0x201c, + 0x201d, 0x3014, 0x3015, 0x3008, 0x3009, 0x300a, 0x300b, 0x300c, + 0x300d, 0x300e, 0x300f, 0x3010, 0x3011, 0x00b1, 0x00d7, 0x00f7, + 0x2260, 0x2264, 0x2265, 0x221e, 0x2234, 0x00b0, 0x2032, 0x2033, + 0x2103, 0x212b, 0xffe0, 0xffe1, 0xffe5, 0x2642, 0x2640, 0x2220, + 0x22a5, 0x2312, 0x2202, 0x2207, 0x2261, 0x2252, 0x00a7, 0x203b, + 0x2606, 0x2605, 0x25cb, 0x25cf, 0x25ce, 0x25c7, 0x25c6, 0x25a1, + 0x25a0, 0x25b3, 0x25b2, 0x25bd, 0x25bc, 0x2192, 0x2190, 0x2191, + 0x2193, 0x2194, 0x3013, 0x226a, 0x226b, 0x221a, 0x223d, 0x221d, + 0x2235, 0x222b, 0x222c, 0x2208, 0x220b, 0x2286, 0x2287, 0x2282, + 0x2283, 0x222a, 0x2229, 0x2227, 0x2228, 0xffe2, + /* 0x22 */ + 0x21d2, 0x21d4, 0x2200, 0x2203, 0x00b4, 0xff5e, 0x02c7, 0x02d8, + 0x02dd, 0x02da, 0x02d9, 0x00b8, 0x02db, 0x00a1, 0x00bf, 0x02d0, + 0x222e, 0x2211, 0x220f, 0x00a4, 0x2109, 0x2030, 0x25c1, 0x25c0, + 0x25b7, 0x25b6, 0x2664, 0x2660, 0x2661, 0x2665, 0x2667, 0x2663, + 0x2299, 0x25c8, 0x25a3, 0x25d0, 0x25d1, 0x2592, 0x25a4, 0x25a5, + 0x25a8, 0x25a7, 0x25a6, 0x25a9, 0x2668, 0x260f, 0x260e, 0x261c, + 0x261e, 0x00b6, 0x2020, 0x2021, 0x2195, 0x2197, 0x2199, 0x2196, + 0x2198, 0x266d, 0x2669, 0x266a, 0x266c, 0x327f, 0x321c, 0x2116, + 0x33c7, 0x2122, 0x33c2, 0x33d8, 0x2121, 0x20ac, 0x00ae, 0x327e, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x23 */ + 0xff01, 0xff02, 0xff03, 0xff04, 0xff05, 0xff06, 0xff07, 0xff08, + 0xff09, 0xff0a, 0xff0b, 0xff0c, 0xff0d, 0xff0e, 0xff0f, 0xff10, + 0xff11, 0xff12, 0xff13, 0xff14, 0xff15, 0xff16, 0xff17, 0xff18, + 0xff19, 0xff1a, 0xff1b, 0xff1c, 0xff1d, 0xff1e, 0xff1f, 0xff20, + 0xff21, 0xff22, 0xff23, 0xff24, 0xff25, 0xff26, 0xff27, 0xff28, + 0xff29, 0xff2a, 0xff2b, 0xff2c, 0xff2d, 0xff2e, 0xff2f, 0xff30, + 0xff31, 0xff32, 0xff33, 0xff34, 0xff35, 0xff36, 0xff37, 0xff38, + 0xff39, 0xff3a, 0xff3b, 0xffe6, 0xff3d, 0xff3e, 0xff3f, 0xff40, + 0xff41, 0xff42, 0xff43, 0xff44, 0xff45, 0xff46, 0xff47, 0xff48, + 0xff49, 0xff4a, 0xff4b, 0xff4c, 0xff4d, 0xff4e, 0xff4f, 0xff50, + 0xff51, 0xff52, 0xff53, 0xff54, 0xff55, 0xff56, 0xff57, 0xff58, + 0xff59, 0xff5a, 0xff5b, 0xff5c, 0xff5d, 0xffe3, + /* 0x24 */ + 0x3131, 0x3132, 0x3133, 0x3134, 0x3135, 0x3136, 0x3137, 0x3138, + 0x3139, 0x313a, 0x313b, 0x313c, 0x313d, 0x313e, 0x313f, 0x3140, + 0x3141, 0x3142, 0x3143, 0x3144, 0x3145, 0x3146, 0x3147, 0x3148, + 0x3149, 0x314a, 0x314b, 0x314c, 0x314d, 0x314e, 0x314f, 0x3150, + 0x3151, 0x3152, 0x3153, 0x3154, 0x3155, 0x3156, 0x3157, 0x3158, + 0x3159, 0x315a, 0x315b, 0x315c, 0x315d, 0x315e, 0x315f, 0x3160, + 0x3161, 0x3162, 0x3163, 0x3164, 0x3165, 0x3166, 0x3167, 0x3168, + 0x3169, 0x316a, 0x316b, 0x316c, 0x316d, 0x316e, 0x316f, 0x3170, + 0x3171, 0x3172, 0x3173, 0x3174, 0x3175, 0x3176, 0x3177, 0x3178, + 0x3179, 0x317a, 0x317b, 0x317c, 0x317d, 0x317e, 0x317f, 0x3180, + 0x3181, 0x3182, 0x3183, 0x3184, 0x3185, 0x3186, 0x3187, 0x3188, + 0x3189, 0x318a, 0x318b, 0x318c, 0x318d, 0x318e, + /* 0x25 */ + 0x2170, 0x2171, 0x2172, 0x2173, 0x2174, 0x2175, 0x2176, 0x2177, + 0x2178, 0x2179, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x2160, + 0x2161, 0x2162, 0x2163, 0x2164, 0x2165, 0x2166, 0x2167, 0x2168, + 0x2169, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x0391, 0x0392, 0x0393, 0x0394, 0x0395, 0x0396, 0x0397, 0x0398, + 0x0399, 0x039a, 0x039b, 0x039c, 0x039d, 0x039e, 0x039f, 0x03a0, + 0x03a1, 0x03a3, 0x03a4, 0x03a5, 0x03a6, 0x03a7, 0x03a8, 0x03a9, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x03b1, 0x03b2, 0x03b3, 0x03b4, 0x03b5, 0x03b6, 0x03b7, 0x03b8, + 0x03b9, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03be, 0x03bf, 0x03c0, + 0x03c1, 0x03c3, 0x03c4, 0x03c5, 0x03c6, 0x03c7, 0x03c8, 0x03c9, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x26 */ + 0x2500, 0x2502, 0x250c, 0x2510, 0x2518, 0x2514, 0x251c, 0x252c, + 0x2524, 0x2534, 0x253c, 0x2501, 0x2503, 0x250f, 0x2513, 0x251b, + 0x2517, 0x2523, 0x2533, 0x252b, 0x253b, 0x254b, 0x2520, 0x252f, + 0x2528, 0x2537, 0x253f, 0x251d, 0x2530, 0x2525, 0x2538, 0x2542, + 0x2512, 0x2511, 0x251a, 0x2519, 0x2516, 0x2515, 0x250e, 0x250d, + 0x251e, 0x251f, 0x2521, 0x2522, 0x2526, 0x2527, 0x2529, 0x252a, + 0x252d, 0x252e, 0x2531, 0x2532, 0x2535, 0x2536, 0x2539, 0x253a, + 0x253d, 0x253e, 0x2540, 0x2541, 0x2543, 0x2544, 0x2545, 0x2546, + 0x2547, 0x2548, 0x2549, 0x254a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x27 */ + 0x3395, 0x3396, 0x3397, 0x2113, 0x3398, 0x33c4, 0x33a3, 0x33a4, + 0x33a5, 0x33a6, 0x3399, 0x339a, 0x339b, 0x339c, 0x339d, 0x339e, + 0x339f, 0x33a0, 0x33a1, 0x33a2, 0x33ca, 0x338d, 0x338e, 0x338f, + 0x33cf, 0x3388, 0x3389, 0x33c8, 0x33a7, 0x33a8, 0x33b0, 0x33b1, + 0x33b2, 0x33b3, 0x33b4, 0x33b5, 0x33b6, 0x33b7, 0x33b8, 0x33b9, + 0x3380, 0x3381, 0x3382, 0x3383, 0x3384, 0x33ba, 0x33bb, 0x33bc, + 0x33bd, 0x33be, 0x33bf, 0x3390, 0x3391, 0x3392, 0x3393, 0x3394, + 0x2126, 0x33c0, 0x33c1, 0x338a, 0x338b, 0x338c, 0x33d6, 0x33c5, + 0x33ad, 0x33ae, 0x33af, 0x33db, 0x33a9, 0x33aa, 0x33ab, 0x33ac, + 0x33dd, 0x33d0, 0x33d3, 0x33c3, 0x33c9, 0x33dc, 0x33c6, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x28 */ + 0x00c6, 0x00d0, 0x00aa, 0x0126, 0xfffd, 0x0132, 0xfffd, 0x013f, + 0x0141, 0x00d8, 0x0152, 0x00ba, 0x00de, 0x0166, 0x014a, 0xfffd, + 0x3260, 0x3261, 0x3262, 0x3263, 0x3264, 0x3265, 0x3266, 0x3267, + 0x3268, 0x3269, 0x326a, 0x326b, 0x326c, 0x326d, 0x326e, 0x326f, + 0x3270, 0x3271, 0x3272, 0x3273, 0x3274, 0x3275, 0x3276, 0x3277, + 0x3278, 0x3279, 0x327a, 0x327b, 0x24d0, 0x24d1, 0x24d2, 0x24d3, + 0x24d4, 0x24d5, 0x24d6, 0x24d7, 0x24d8, 0x24d9, 0x24da, 0x24db, + 0x24dc, 0x24dd, 0x24de, 0x24df, 0x24e0, 0x24e1, 0x24e2, 0x24e3, + 0x24e4, 0x24e5, 0x24e6, 0x24e7, 0x24e8, 0x24e9, 0x2460, 0x2461, + 0x2462, 0x2463, 0x2464, 0x2465, 0x2466, 0x2467, 0x2468, 0x2469, + 0x246a, 0x246b, 0x246c, 0x246d, 0x246e, 0x00bd, 0x2153, 0x2154, + 0x00bc, 0x00be, 0x215b, 0x215c, 0x215d, 0x215e, + /* 0x29 */ + 0x00e6, 0x0111, 0x00f0, 0x0127, 0x0131, 0x0133, 0x0138, 0x0140, + 0x0142, 0x00f8, 0x0153, 0x00df, 0x00fe, 0x0167, 0x014b, 0x0149, + 0x3200, 0x3201, 0x3202, 0x3203, 0x3204, 0x3205, 0x3206, 0x3207, + 0x3208, 0x3209, 0x320a, 0x320b, 0x320c, 0x320d, 0x320e, 0x320f, + 0x3210, 0x3211, 0x3212, 0x3213, 0x3214, 0x3215, 0x3216, 0x3217, + 0x3218, 0x3219, 0x321a, 0x321b, 0x249c, 0x249d, 0x249e, 0x249f, + 0x24a0, 0x24a1, 0x24a2, 0x24a3, 0x24a4, 0x24a5, 0x24a6, 0x24a7, + 0x24a8, 0x24a9, 0x24aa, 0x24ab, 0x24ac, 0x24ad, 0x24ae, 0x24af, + 0x24b0, 0x24b1, 0x24b2, 0x24b3, 0x24b4, 0x24b5, 0x2474, 0x2475, + 0x2476, 0x2477, 0x2478, 0x2479, 0x247a, 0x247b, 0x247c, 0x247d, + 0x247e, 0x247f, 0x2480, 0x2481, 0x2482, 0x00b9, 0x00b2, 0x00b3, + 0x2074, 0x207f, 0x2081, 0x2082, 0x2083, 0x2084, + /* 0x2a */ + 0x3041, 0x3042, 0x3043, 0x3044, 0x3045, 0x3046, 0x3047, 0x3048, + 0x3049, 0x304a, 0x304b, 0x304c, 0x304d, 0x304e, 0x304f, 0x3050, + 0x3051, 0x3052, 0x3053, 0x3054, 0x3055, 0x3056, 0x3057, 0x3058, + 0x3059, 0x305a, 0x305b, 0x305c, 0x305d, 0x305e, 0x305f, 0x3060, + 0x3061, 0x3062, 0x3063, 0x3064, 0x3065, 0x3066, 0x3067, 0x3068, + 0x3069, 0x306a, 0x306b, 0x306c, 0x306d, 0x306e, 0x306f, 0x3070, + 0x3071, 0x3072, 0x3073, 0x3074, 0x3075, 0x3076, 0x3077, 0x3078, + 0x3079, 0x307a, 0x307b, 0x307c, 0x307d, 0x307e, 0x307f, 0x3080, + 0x3081, 0x3082, 0x3083, 0x3084, 0x3085, 0x3086, 0x3087, 0x3088, + 0x3089, 0x308a, 0x308b, 0x308c, 0x308d, 0x308e, 0x308f, 0x3090, + 0x3091, 0x3092, 0x3093, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x2b */ + 0x30a1, 0x30a2, 0x30a3, 0x30a4, 0x30a5, 0x30a6, 0x30a7, 0x30a8, + 0x30a9, 0x30aa, 0x30ab, 0x30ac, 0x30ad, 0x30ae, 0x30af, 0x30b0, + 0x30b1, 0x30b2, 0x30b3, 0x30b4, 0x30b5, 0x30b6, 0x30b7, 0x30b8, + 0x30b9, 0x30ba, 0x30bb, 0x30bc, 0x30bd, 0x30be, 0x30bf, 0x30c0, + 0x30c1, 0x30c2, 0x30c3, 0x30c4, 0x30c5, 0x30c6, 0x30c7, 0x30c8, + 0x30c9, 0x30ca, 0x30cb, 0x30cc, 0x30cd, 0x30ce, 0x30cf, 0x30d0, + 0x30d1, 0x30d2, 0x30d3, 0x30d4, 0x30d5, 0x30d6, 0x30d7, 0x30d8, + 0x30d9, 0x30da, 0x30db, 0x30dc, 0x30dd, 0x30de, 0x30df, 0x30e0, + 0x30e1, 0x30e2, 0x30e3, 0x30e4, 0x30e5, 0x30e6, 0x30e7, 0x30e8, + 0x30e9, 0x30ea, 0x30eb, 0x30ec, 0x30ed, 0x30ee, 0x30ef, 0x30f0, + 0x30f1, 0x30f2, 0x30f3, 0x30f4, 0x30f5, 0x30f6, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0x2c */ + 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0401, 0x0416, + 0x0417, 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, + 0x041f, 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, + 0x0427, 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, + 0x042f, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0451, 0x0436, + 0x0437, 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, + 0x043f, 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, + 0x0447, 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, + 0x044f, +}; +static const unsigned short ksc5601_2uni_page30[2350] = { + /* 0x30 */ + 0xac00, 0xac01, 0xac04, 0xac07, 0xac08, 0xac09, 0xac0a, 0xac10, + 0xac11, 0xac12, 0xac13, 0xac14, 0xac15, 0xac16, 0xac17, 0xac19, + 0xac1a, 0xac1b, 0xac1c, 0xac1d, 0xac20, 0xac24, 0xac2c, 0xac2d, + 0xac2f, 0xac30, 0xac31, 0xac38, 0xac39, 0xac3c, 0xac40, 0xac4b, + 0xac4d, 0xac54, 0xac58, 0xac5c, 0xac70, 0xac71, 0xac74, 0xac77, + 0xac78, 0xac7a, 0xac80, 0xac81, 0xac83, 0xac84, 0xac85, 0xac86, + 0xac89, 0xac8a, 0xac8b, 0xac8c, 0xac90, 0xac94, 0xac9c, 0xac9d, + 0xac9f, 0xaca0, 0xaca1, 0xaca8, 0xaca9, 0xacaa, 0xacac, 0xacaf, + 0xacb0, 0xacb8, 0xacb9, 0xacbb, 0xacbc, 0xacbd, 0xacc1, 0xacc4, + 0xacc8, 0xaccc, 0xacd5, 0xacd7, 0xace0, 0xace1, 0xace4, 0xace7, + 0xace8, 0xacea, 0xacec, 0xacef, 0xacf0, 0xacf1, 0xacf3, 0xacf5, + 0xacf6, 0xacfc, 0xacfd, 0xad00, 0xad04, 0xad06, + /* 0x31 */ + 0xad0c, 0xad0d, 0xad0f, 0xad11, 0xad18, 0xad1c, 0xad20, 0xad29, + 0xad2c, 0xad2d, 0xad34, 0xad35, 0xad38, 0xad3c, 0xad44, 0xad45, + 0xad47, 0xad49, 0xad50, 0xad54, 0xad58, 0xad61, 0xad63, 0xad6c, + 0xad6d, 0xad70, 0xad73, 0xad74, 0xad75, 0xad76, 0xad7b, 0xad7c, + 0xad7d, 0xad7f, 0xad81, 0xad82, 0xad88, 0xad89, 0xad8c, 0xad90, + 0xad9c, 0xad9d, 0xada4, 0xadb7, 0xadc0, 0xadc1, 0xadc4, 0xadc8, + 0xadd0, 0xadd1, 0xadd3, 0xaddc, 0xade0, 0xade4, 0xadf8, 0xadf9, + 0xadfc, 0xadff, 0xae00, 0xae01, 0xae08, 0xae09, 0xae0b, 0xae0d, + 0xae14, 0xae30, 0xae31, 0xae34, 0xae37, 0xae38, 0xae3a, 0xae40, + 0xae41, 0xae43, 0xae45, 0xae46, 0xae4a, 0xae4c, 0xae4d, 0xae4e, + 0xae50, 0xae54, 0xae56, 0xae5c, 0xae5d, 0xae5f, 0xae60, 0xae61, + 0xae65, 0xae68, 0xae69, 0xae6c, 0xae70, 0xae78, + /* 0x32 */ + 0xae79, 0xae7b, 0xae7c, 0xae7d, 0xae84, 0xae85, 0xae8c, 0xaebc, + 0xaebd, 0xaebe, 0xaec0, 0xaec4, 0xaecc, 0xaecd, 0xaecf, 0xaed0, + 0xaed1, 0xaed8, 0xaed9, 0xaedc, 0xaee8, 0xaeeb, 0xaeed, 0xaef4, + 0xaef8, 0xaefc, 0xaf07, 0xaf08, 0xaf0d, 0xaf10, 0xaf2c, 0xaf2d, + 0xaf30, 0xaf32, 0xaf34, 0xaf3c, 0xaf3d, 0xaf3f, 0xaf41, 0xaf42, + 0xaf43, 0xaf48, 0xaf49, 0xaf50, 0xaf5c, 0xaf5d, 0xaf64, 0xaf65, + 0xaf79, 0xaf80, 0xaf84, 0xaf88, 0xaf90, 0xaf91, 0xaf95, 0xaf9c, + 0xafb8, 0xafb9, 0xafbc, 0xafc0, 0xafc7, 0xafc8, 0xafc9, 0xafcb, + 0xafcd, 0xafce, 0xafd4, 0xafdc, 0xafe8, 0xafe9, 0xaff0, 0xaff1, + 0xaff4, 0xaff8, 0xb000, 0xb001, 0xb004, 0xb00c, 0xb010, 0xb014, + 0xb01c, 0xb01d, 0xb028, 0xb044, 0xb045, 0xb048, 0xb04a, 0xb04c, + 0xb04e, 0xb053, 0xb054, 0xb055, 0xb057, 0xb059, + /* 0x33 */ + 0xb05d, 0xb07c, 0xb07d, 0xb080, 0xb084, 0xb08c, 0xb08d, 0xb08f, + 0xb091, 0xb098, 0xb099, 0xb09a, 0xb09c, 0xb09f, 0xb0a0, 0xb0a1, + 0xb0a2, 0xb0a8, 0xb0a9, 0xb0ab, 0xb0ac, 0xb0ad, 0xb0ae, 0xb0af, + 0xb0b1, 0xb0b3, 0xb0b4, 0xb0b5, 0xb0b8, 0xb0bc, 0xb0c4, 0xb0c5, + 0xb0c7, 0xb0c8, 0xb0c9, 0xb0d0, 0xb0d1, 0xb0d4, 0xb0d8, 0xb0e0, + 0xb0e5, 0xb108, 0xb109, 0xb10b, 0xb10c, 0xb110, 0xb112, 0xb113, + 0xb118, 0xb119, 0xb11b, 0xb11c, 0xb11d, 0xb123, 0xb124, 0xb125, + 0xb128, 0xb12c, 0xb134, 0xb135, 0xb137, 0xb138, 0xb139, 0xb140, + 0xb141, 0xb144, 0xb148, 0xb150, 0xb151, 0xb154, 0xb155, 0xb158, + 0xb15c, 0xb160, 0xb178, 0xb179, 0xb17c, 0xb180, 0xb182, 0xb188, + 0xb189, 0xb18b, 0xb18d, 0xb192, 0xb193, 0xb194, 0xb198, 0xb19c, + 0xb1a8, 0xb1cc, 0xb1d0, 0xb1d4, 0xb1dc, 0xb1dd, + /* 0x34 */ + 0xb1df, 0xb1e8, 0xb1e9, 0xb1ec, 0xb1f0, 0xb1f9, 0xb1fb, 0xb1fd, + 0xb204, 0xb205, 0xb208, 0xb20b, 0xb20c, 0xb214, 0xb215, 0xb217, + 0xb219, 0xb220, 0xb234, 0xb23c, 0xb258, 0xb25c, 0xb260, 0xb268, + 0xb269, 0xb274, 0xb275, 0xb27c, 0xb284, 0xb285, 0xb289, 0xb290, + 0xb291, 0xb294, 0xb298, 0xb299, 0xb29a, 0xb2a0, 0xb2a1, 0xb2a3, + 0xb2a5, 0xb2a6, 0xb2aa, 0xb2ac, 0xb2b0, 0xb2b4, 0xb2c8, 0xb2c9, + 0xb2cc, 0xb2d0, 0xb2d2, 0xb2d8, 0xb2d9, 0xb2db, 0xb2dd, 0xb2e2, + 0xb2e4, 0xb2e5, 0xb2e6, 0xb2e8, 0xb2eb, 0xb2ec, 0xb2ed, 0xb2ee, + 0xb2ef, 0xb2f3, 0xb2f4, 0xb2f5, 0xb2f7, 0xb2f8, 0xb2f9, 0xb2fa, + 0xb2fb, 0xb2ff, 0xb300, 0xb301, 0xb304, 0xb308, 0xb310, 0xb311, + 0xb313, 0xb314, 0xb315, 0xb31c, 0xb354, 0xb355, 0xb356, 0xb358, + 0xb35b, 0xb35c, 0xb35e, 0xb35f, 0xb364, 0xb365, + /* 0x35 */ + 0xb367, 0xb369, 0xb36b, 0xb36e, 0xb370, 0xb371, 0xb374, 0xb378, + 0xb380, 0xb381, 0xb383, 0xb384, 0xb385, 0xb38c, 0xb390, 0xb394, + 0xb3a0, 0xb3a1, 0xb3a8, 0xb3ac, 0xb3c4, 0xb3c5, 0xb3c8, 0xb3cb, + 0xb3cc, 0xb3ce, 0xb3d0, 0xb3d4, 0xb3d5, 0xb3d7, 0xb3d9, 0xb3db, + 0xb3dd, 0xb3e0, 0xb3e4, 0xb3e8, 0xb3fc, 0xb410, 0xb418, 0xb41c, + 0xb420, 0xb428, 0xb429, 0xb42b, 0xb434, 0xb450, 0xb451, 0xb454, + 0xb458, 0xb460, 0xb461, 0xb463, 0xb465, 0xb46c, 0xb480, 0xb488, + 0xb49d, 0xb4a4, 0xb4a8, 0xb4ac, 0xb4b5, 0xb4b7, 0xb4b9, 0xb4c0, + 0xb4c4, 0xb4c8, 0xb4d0, 0xb4d5, 0xb4dc, 0xb4dd, 0xb4e0, 0xb4e3, + 0xb4e4, 0xb4e6, 0xb4ec, 0xb4ed, 0xb4ef, 0xb4f1, 0xb4f8, 0xb514, + 0xb515, 0xb518, 0xb51b, 0xb51c, 0xb524, 0xb525, 0xb527, 0xb528, + 0xb529, 0xb52a, 0xb530, 0xb531, 0xb534, 0xb538, + /* 0x36 */ + 0xb540, 0xb541, 0xb543, 0xb544, 0xb545, 0xb54b, 0xb54c, 0xb54d, + 0xb550, 0xb554, 0xb55c, 0xb55d, 0xb55f, 0xb560, 0xb561, 0xb5a0, + 0xb5a1, 0xb5a4, 0xb5a8, 0xb5aa, 0xb5ab, 0xb5b0, 0xb5b1, 0xb5b3, + 0xb5b4, 0xb5b5, 0xb5bb, 0xb5bc, 0xb5bd, 0xb5c0, 0xb5c4, 0xb5cc, + 0xb5cd, 0xb5cf, 0xb5d0, 0xb5d1, 0xb5d8, 0xb5ec, 0xb610, 0xb611, + 0xb614, 0xb618, 0xb625, 0xb62c, 0xb634, 0xb648, 0xb664, 0xb668, + 0xb69c, 0xb69d, 0xb6a0, 0xb6a4, 0xb6ab, 0xb6ac, 0xb6b1, 0xb6d4, + 0xb6f0, 0xb6f4, 0xb6f8, 0xb700, 0xb701, 0xb705, 0xb728, 0xb729, + 0xb72c, 0xb72f, 0xb730, 0xb738, 0xb739, 0xb73b, 0xb744, 0xb748, + 0xb74c, 0xb754, 0xb755, 0xb760, 0xb764, 0xb768, 0xb770, 0xb771, + 0xb773, 0xb775, 0xb77c, 0xb77d, 0xb780, 0xb784, 0xb78c, 0xb78d, + 0xb78f, 0xb790, 0xb791, 0xb792, 0xb796, 0xb797, + /* 0x37 */ + 0xb798, 0xb799, 0xb79c, 0xb7a0, 0xb7a8, 0xb7a9, 0xb7ab, 0xb7ac, + 0xb7ad, 0xb7b4, 0xb7b5, 0xb7b8, 0xb7c7, 0xb7c9, 0xb7ec, 0xb7ed, + 0xb7f0, 0xb7f4, 0xb7fc, 0xb7fd, 0xb7ff, 0xb800, 0xb801, 0xb807, + 0xb808, 0xb809, 0xb80c, 0xb810, 0xb818, 0xb819, 0xb81b, 0xb81d, + 0xb824, 0xb825, 0xb828, 0xb82c, 0xb834, 0xb835, 0xb837, 0xb838, + 0xb839, 0xb840, 0xb844, 0xb851, 0xb853, 0xb85c, 0xb85d, 0xb860, + 0xb864, 0xb86c, 0xb86d, 0xb86f, 0xb871, 0xb878, 0xb87c, 0xb88d, + 0xb8a8, 0xb8b0, 0xb8b4, 0xb8b8, 0xb8c0, 0xb8c1, 0xb8c3, 0xb8c5, + 0xb8cc, 0xb8d0, 0xb8d4, 0xb8dd, 0xb8df, 0xb8e1, 0xb8e8, 0xb8e9, + 0xb8ec, 0xb8f0, 0xb8f8, 0xb8f9, 0xb8fb, 0xb8fd, 0xb904, 0xb918, + 0xb920, 0xb93c, 0xb93d, 0xb940, 0xb944, 0xb94c, 0xb94f, 0xb951, + 0xb958, 0xb959, 0xb95c, 0xb960, 0xb968, 0xb969, + /* 0x38 */ + 0xb96b, 0xb96d, 0xb974, 0xb975, 0xb978, 0xb97c, 0xb984, 0xb985, + 0xb987, 0xb989, 0xb98a, 0xb98d, 0xb98e, 0xb9ac, 0xb9ad, 0xb9b0, + 0xb9b4, 0xb9bc, 0xb9bd, 0xb9bf, 0xb9c1, 0xb9c8, 0xb9c9, 0xb9cc, + 0xb9ce, 0xb9cf, 0xb9d0, 0xb9d1, 0xb9d2, 0xb9d8, 0xb9d9, 0xb9db, + 0xb9dd, 0xb9de, 0xb9e1, 0xb9e3, 0xb9e4, 0xb9e5, 0xb9e8, 0xb9ec, + 0xb9f4, 0xb9f5, 0xb9f7, 0xb9f8, 0xb9f9, 0xb9fa, 0xba00, 0xba01, + 0xba08, 0xba15, 0xba38, 0xba39, 0xba3c, 0xba40, 0xba42, 0xba48, + 0xba49, 0xba4b, 0xba4d, 0xba4e, 0xba53, 0xba54, 0xba55, 0xba58, + 0xba5c, 0xba64, 0xba65, 0xba67, 0xba68, 0xba69, 0xba70, 0xba71, + 0xba74, 0xba78, 0xba83, 0xba84, 0xba85, 0xba87, 0xba8c, 0xbaa8, + 0xbaa9, 0xbaab, 0xbaac, 0xbab0, 0xbab2, 0xbab8, 0xbab9, 0xbabb, + 0xbabd, 0xbac4, 0xbac8, 0xbad8, 0xbad9, 0xbafc, + /* 0x39 */ + 0xbb00, 0xbb04, 0xbb0d, 0xbb0f, 0xbb11, 0xbb18, 0xbb1c, 0xbb20, + 0xbb29, 0xbb2b, 0xbb34, 0xbb35, 0xbb36, 0xbb38, 0xbb3b, 0xbb3c, + 0xbb3d, 0xbb3e, 0xbb44, 0xbb45, 0xbb47, 0xbb49, 0xbb4d, 0xbb4f, + 0xbb50, 0xbb54, 0xbb58, 0xbb61, 0xbb63, 0xbb6c, 0xbb88, 0xbb8c, + 0xbb90, 0xbba4, 0xbba8, 0xbbac, 0xbbb4, 0xbbb7, 0xbbc0, 0xbbc4, + 0xbbc8, 0xbbd0, 0xbbd3, 0xbbf8, 0xbbf9, 0xbbfc, 0xbbff, 0xbc00, + 0xbc02, 0xbc08, 0xbc09, 0xbc0b, 0xbc0c, 0xbc0d, 0xbc0f, 0xbc11, + 0xbc14, 0xbc15, 0xbc16, 0xbc17, 0xbc18, 0xbc1b, 0xbc1c, 0xbc1d, + 0xbc1e, 0xbc1f, 0xbc24, 0xbc25, 0xbc27, 0xbc29, 0xbc2d, 0xbc30, + 0xbc31, 0xbc34, 0xbc38, 0xbc40, 0xbc41, 0xbc43, 0xbc44, 0xbc45, + 0xbc49, 0xbc4c, 0xbc4d, 0xbc50, 0xbc5d, 0xbc84, 0xbc85, 0xbc88, + 0xbc8b, 0xbc8c, 0xbc8e, 0xbc94, 0xbc95, 0xbc97, + /* 0x3a */ + 0xbc99, 0xbc9a, 0xbca0, 0xbca1, 0xbca4, 0xbca7, 0xbca8, 0xbcb0, + 0xbcb1, 0xbcb3, 0xbcb4, 0xbcb5, 0xbcbc, 0xbcbd, 0xbcc0, 0xbcc4, + 0xbccd, 0xbccf, 0xbcd0, 0xbcd1, 0xbcd5, 0xbcd8, 0xbcdc, 0xbcf4, + 0xbcf5, 0xbcf6, 0xbcf8, 0xbcfc, 0xbd04, 0xbd05, 0xbd07, 0xbd09, + 0xbd10, 0xbd14, 0xbd24, 0xbd2c, 0xbd40, 0xbd48, 0xbd49, 0xbd4c, + 0xbd50, 0xbd58, 0xbd59, 0xbd64, 0xbd68, 0xbd80, 0xbd81, 0xbd84, + 0xbd87, 0xbd88, 0xbd89, 0xbd8a, 0xbd90, 0xbd91, 0xbd93, 0xbd95, + 0xbd99, 0xbd9a, 0xbd9c, 0xbda4, 0xbdb0, 0xbdb8, 0xbdd4, 0xbdd5, + 0xbdd8, 0xbddc, 0xbde9, 0xbdf0, 0xbdf4, 0xbdf8, 0xbe00, 0xbe03, + 0xbe05, 0xbe0c, 0xbe0d, 0xbe10, 0xbe14, 0xbe1c, 0xbe1d, 0xbe1f, + 0xbe44, 0xbe45, 0xbe48, 0xbe4c, 0xbe4e, 0xbe54, 0xbe55, 0xbe57, + 0xbe59, 0xbe5a, 0xbe5b, 0xbe60, 0xbe61, 0xbe64, + /* 0x3b */ + 0xbe68, 0xbe6a, 0xbe70, 0xbe71, 0xbe73, 0xbe74, 0xbe75, 0xbe7b, + 0xbe7c, 0xbe7d, 0xbe80, 0xbe84, 0xbe8c, 0xbe8d, 0xbe8f, 0xbe90, + 0xbe91, 0xbe98, 0xbe99, 0xbea8, 0xbed0, 0xbed1, 0xbed4, 0xbed7, + 0xbed8, 0xbee0, 0xbee3, 0xbee4, 0xbee5, 0xbeec, 0xbf01, 0xbf08, + 0xbf09, 0xbf18, 0xbf19, 0xbf1b, 0xbf1c, 0xbf1d, 0xbf40, 0xbf41, + 0xbf44, 0xbf48, 0xbf50, 0xbf51, 0xbf55, 0xbf94, 0xbfb0, 0xbfc5, + 0xbfcc, 0xbfcd, 0xbfd0, 0xbfd4, 0xbfdc, 0xbfdf, 0xbfe1, 0xc03c, + 0xc051, 0xc058, 0xc05c, 0xc060, 0xc068, 0xc069, 0xc090, 0xc091, + 0xc094, 0xc098, 0xc0a0, 0xc0a1, 0xc0a3, 0xc0a5, 0xc0ac, 0xc0ad, + 0xc0af, 0xc0b0, 0xc0b3, 0xc0b4, 0xc0b5, 0xc0b6, 0xc0bc, 0xc0bd, + 0xc0bf, 0xc0c0, 0xc0c1, 0xc0c5, 0xc0c8, 0xc0c9, 0xc0cc, 0xc0d0, + 0xc0d8, 0xc0d9, 0xc0db, 0xc0dc, 0xc0dd, 0xc0e4, + /* 0x3c */ + 0xc0e5, 0xc0e8, 0xc0ec, 0xc0f4, 0xc0f5, 0xc0f7, 0xc0f9, 0xc100, + 0xc104, 0xc108, 0xc110, 0xc115, 0xc11c, 0xc11d, 0xc11e, 0xc11f, + 0xc120, 0xc123, 0xc124, 0xc126, 0xc127, 0xc12c, 0xc12d, 0xc12f, + 0xc130, 0xc131, 0xc136, 0xc138, 0xc139, 0xc13c, 0xc140, 0xc148, + 0xc149, 0xc14b, 0xc14c, 0xc14d, 0xc154, 0xc155, 0xc158, 0xc15c, + 0xc164, 0xc165, 0xc167, 0xc168, 0xc169, 0xc170, 0xc174, 0xc178, + 0xc185, 0xc18c, 0xc18d, 0xc18e, 0xc190, 0xc194, 0xc196, 0xc19c, + 0xc19d, 0xc19f, 0xc1a1, 0xc1a5, 0xc1a8, 0xc1a9, 0xc1ac, 0xc1b0, + 0xc1bd, 0xc1c4, 0xc1c8, 0xc1cc, 0xc1d4, 0xc1d7, 0xc1d8, 0xc1e0, + 0xc1e4, 0xc1e8, 0xc1f0, 0xc1f1, 0xc1f3, 0xc1fc, 0xc1fd, 0xc200, + 0xc204, 0xc20c, 0xc20d, 0xc20f, 0xc211, 0xc218, 0xc219, 0xc21c, + 0xc21f, 0xc220, 0xc228, 0xc229, 0xc22b, 0xc22d, + /* 0x3d */ + 0xc22f, 0xc231, 0xc232, 0xc234, 0xc248, 0xc250, 0xc251, 0xc254, + 0xc258, 0xc260, 0xc265, 0xc26c, 0xc26d, 0xc270, 0xc274, 0xc27c, + 0xc27d, 0xc27f, 0xc281, 0xc288, 0xc289, 0xc290, 0xc298, 0xc29b, + 0xc29d, 0xc2a4, 0xc2a5, 0xc2a8, 0xc2ac, 0xc2ad, 0xc2b4, 0xc2b5, + 0xc2b7, 0xc2b9, 0xc2dc, 0xc2dd, 0xc2e0, 0xc2e3, 0xc2e4, 0xc2eb, + 0xc2ec, 0xc2ed, 0xc2ef, 0xc2f1, 0xc2f6, 0xc2f8, 0xc2f9, 0xc2fb, + 0xc2fc, 0xc300, 0xc308, 0xc309, 0xc30c, 0xc30d, 0xc313, 0xc314, + 0xc315, 0xc318, 0xc31c, 0xc324, 0xc325, 0xc328, 0xc329, 0xc345, + 0xc368, 0xc369, 0xc36c, 0xc370, 0xc372, 0xc378, 0xc379, 0xc37c, + 0xc37d, 0xc384, 0xc388, 0xc38c, 0xc3c0, 0xc3d8, 0xc3d9, 0xc3dc, + 0xc3df, 0xc3e0, 0xc3e2, 0xc3e8, 0xc3e9, 0xc3ed, 0xc3f4, 0xc3f5, + 0xc3f8, 0xc408, 0xc410, 0xc424, 0xc42c, 0xc430, + /* 0x3e */ + 0xc434, 0xc43c, 0xc43d, 0xc448, 0xc464, 0xc465, 0xc468, 0xc46c, + 0xc474, 0xc475, 0xc479, 0xc480, 0xc494, 0xc49c, 0xc4b8, 0xc4bc, + 0xc4e9, 0xc4f0, 0xc4f1, 0xc4f4, 0xc4f8, 0xc4fa, 0xc4ff, 0xc500, + 0xc501, 0xc50c, 0xc510, 0xc514, 0xc51c, 0xc528, 0xc529, 0xc52c, + 0xc530, 0xc538, 0xc539, 0xc53b, 0xc53d, 0xc544, 0xc545, 0xc548, + 0xc549, 0xc54a, 0xc54c, 0xc54d, 0xc54e, 0xc553, 0xc554, 0xc555, + 0xc557, 0xc558, 0xc559, 0xc55d, 0xc55e, 0xc560, 0xc561, 0xc564, + 0xc568, 0xc570, 0xc571, 0xc573, 0xc574, 0xc575, 0xc57c, 0xc57d, + 0xc580, 0xc584, 0xc587, 0xc58c, 0xc58d, 0xc58f, 0xc591, 0xc595, + 0xc597, 0xc598, 0xc59c, 0xc5a0, 0xc5a9, 0xc5b4, 0xc5b5, 0xc5b8, + 0xc5b9, 0xc5bb, 0xc5bc, 0xc5bd, 0xc5be, 0xc5c4, 0xc5c5, 0xc5c6, + 0xc5c7, 0xc5c8, 0xc5c9, 0xc5ca, 0xc5cc, 0xc5ce, + /* 0x3f */ + 0xc5d0, 0xc5d1, 0xc5d4, 0xc5d8, 0xc5e0, 0xc5e1, 0xc5e3, 0xc5e5, + 0xc5ec, 0xc5ed, 0xc5ee, 0xc5f0, 0xc5f4, 0xc5f6, 0xc5f7, 0xc5fc, + 0xc5fd, 0xc5fe, 0xc5ff, 0xc600, 0xc601, 0xc605, 0xc606, 0xc607, + 0xc608, 0xc60c, 0xc610, 0xc618, 0xc619, 0xc61b, 0xc61c, 0xc624, + 0xc625, 0xc628, 0xc62c, 0xc62d, 0xc62e, 0xc630, 0xc633, 0xc634, + 0xc635, 0xc637, 0xc639, 0xc63b, 0xc640, 0xc641, 0xc644, 0xc648, + 0xc650, 0xc651, 0xc653, 0xc654, 0xc655, 0xc65c, 0xc65d, 0xc660, + 0xc66c, 0xc66f, 0xc671, 0xc678, 0xc679, 0xc67c, 0xc680, 0xc688, + 0xc689, 0xc68b, 0xc68d, 0xc694, 0xc695, 0xc698, 0xc69c, 0xc6a4, + 0xc6a5, 0xc6a7, 0xc6a9, 0xc6b0, 0xc6b1, 0xc6b4, 0xc6b8, 0xc6b9, + 0xc6ba, 0xc6c0, 0xc6c1, 0xc6c3, 0xc6c5, 0xc6cc, 0xc6cd, 0xc6d0, + 0xc6d4, 0xc6dc, 0xc6dd, 0xc6e0, 0xc6e1, 0xc6e8, + /* 0x40 */ + 0xc6e9, 0xc6ec, 0xc6f0, 0xc6f8, 0xc6f9, 0xc6fd, 0xc704, 0xc705, + 0xc708, 0xc70c, 0xc714, 0xc715, 0xc717, 0xc719, 0xc720, 0xc721, + 0xc724, 0xc728, 0xc730, 0xc731, 0xc733, 0xc735, 0xc737, 0xc73c, + 0xc73d, 0xc740, 0xc744, 0xc74a, 0xc74c, 0xc74d, 0xc74f, 0xc751, + 0xc752, 0xc753, 0xc754, 0xc755, 0xc756, 0xc757, 0xc758, 0xc75c, + 0xc760, 0xc768, 0xc76b, 0xc774, 0xc775, 0xc778, 0xc77c, 0xc77d, + 0xc77e, 0xc783, 0xc784, 0xc785, 0xc787, 0xc788, 0xc789, 0xc78a, + 0xc78e, 0xc790, 0xc791, 0xc794, 0xc796, 0xc797, 0xc798, 0xc79a, + 0xc7a0, 0xc7a1, 0xc7a3, 0xc7a4, 0xc7a5, 0xc7a6, 0xc7ac, 0xc7ad, + 0xc7b0, 0xc7b4, 0xc7bc, 0xc7bd, 0xc7bf, 0xc7c0, 0xc7c1, 0xc7c8, + 0xc7c9, 0xc7cc, 0xc7ce, 0xc7d0, 0xc7d8, 0xc7dd, 0xc7e4, 0xc7e8, + 0xc7ec, 0xc800, 0xc801, 0xc804, 0xc808, 0xc80a, + /* 0x41 */ + 0xc810, 0xc811, 0xc813, 0xc815, 0xc816, 0xc81c, 0xc81d, 0xc820, + 0xc824, 0xc82c, 0xc82d, 0xc82f, 0xc831, 0xc838, 0xc83c, 0xc840, + 0xc848, 0xc849, 0xc84c, 0xc84d, 0xc854, 0xc870, 0xc871, 0xc874, + 0xc878, 0xc87a, 0xc880, 0xc881, 0xc883, 0xc885, 0xc886, 0xc887, + 0xc88b, 0xc88c, 0xc88d, 0xc894, 0xc89d, 0xc89f, 0xc8a1, 0xc8a8, + 0xc8bc, 0xc8bd, 0xc8c4, 0xc8c8, 0xc8cc, 0xc8d4, 0xc8d5, 0xc8d7, + 0xc8d9, 0xc8e0, 0xc8e1, 0xc8e4, 0xc8f5, 0xc8fc, 0xc8fd, 0xc900, + 0xc904, 0xc905, 0xc906, 0xc90c, 0xc90d, 0xc90f, 0xc911, 0xc918, + 0xc92c, 0xc934, 0xc950, 0xc951, 0xc954, 0xc958, 0xc960, 0xc961, + 0xc963, 0xc96c, 0xc970, 0xc974, 0xc97c, 0xc988, 0xc989, 0xc98c, + 0xc990, 0xc998, 0xc999, 0xc99b, 0xc99d, 0xc9c0, 0xc9c1, 0xc9c4, + 0xc9c7, 0xc9c8, 0xc9ca, 0xc9d0, 0xc9d1, 0xc9d3, + /* 0x42 */ + 0xc9d5, 0xc9d6, 0xc9d9, 0xc9da, 0xc9dc, 0xc9dd, 0xc9e0, 0xc9e2, + 0xc9e4, 0xc9e7, 0xc9ec, 0xc9ed, 0xc9ef, 0xc9f0, 0xc9f1, 0xc9f8, + 0xc9f9, 0xc9fc, 0xca00, 0xca08, 0xca09, 0xca0b, 0xca0c, 0xca0d, + 0xca14, 0xca18, 0xca29, 0xca4c, 0xca4d, 0xca50, 0xca54, 0xca5c, + 0xca5d, 0xca5f, 0xca60, 0xca61, 0xca68, 0xca7d, 0xca84, 0xca98, + 0xcabc, 0xcabd, 0xcac0, 0xcac4, 0xcacc, 0xcacd, 0xcacf, 0xcad1, + 0xcad3, 0xcad8, 0xcad9, 0xcae0, 0xcaec, 0xcaf4, 0xcb08, 0xcb10, + 0xcb14, 0xcb18, 0xcb20, 0xcb21, 0xcb41, 0xcb48, 0xcb49, 0xcb4c, + 0xcb50, 0xcb58, 0xcb59, 0xcb5d, 0xcb64, 0xcb78, 0xcb79, 0xcb9c, + 0xcbb8, 0xcbd4, 0xcbe4, 0xcbe7, 0xcbe9, 0xcc0c, 0xcc0d, 0xcc10, + 0xcc14, 0xcc1c, 0xcc1d, 0xcc21, 0xcc22, 0xcc27, 0xcc28, 0xcc29, + 0xcc2c, 0xcc2e, 0xcc30, 0xcc38, 0xcc39, 0xcc3b, + /* 0x43 */ + 0xcc3c, 0xcc3d, 0xcc3e, 0xcc44, 0xcc45, 0xcc48, 0xcc4c, 0xcc54, + 0xcc55, 0xcc57, 0xcc58, 0xcc59, 0xcc60, 0xcc64, 0xcc66, 0xcc68, + 0xcc70, 0xcc75, 0xcc98, 0xcc99, 0xcc9c, 0xcca0, 0xcca8, 0xcca9, + 0xccab, 0xccac, 0xccad, 0xccb4, 0xccb5, 0xccb8, 0xccbc, 0xccc4, + 0xccc5, 0xccc7, 0xccc9, 0xccd0, 0xccd4, 0xcce4, 0xccec, 0xccf0, + 0xcd01, 0xcd08, 0xcd09, 0xcd0c, 0xcd10, 0xcd18, 0xcd19, 0xcd1b, + 0xcd1d, 0xcd24, 0xcd28, 0xcd2c, 0xcd39, 0xcd5c, 0xcd60, 0xcd64, + 0xcd6c, 0xcd6d, 0xcd6f, 0xcd71, 0xcd78, 0xcd88, 0xcd94, 0xcd95, + 0xcd98, 0xcd9c, 0xcda4, 0xcda5, 0xcda7, 0xcda9, 0xcdb0, 0xcdc4, + 0xcdcc, 0xcdd0, 0xcde8, 0xcdec, 0xcdf0, 0xcdf8, 0xcdf9, 0xcdfb, + 0xcdfd, 0xce04, 0xce08, 0xce0c, 0xce14, 0xce19, 0xce20, 0xce21, + 0xce24, 0xce28, 0xce30, 0xce31, 0xce33, 0xce35, + /* 0x44 */ + 0xce58, 0xce59, 0xce5c, 0xce5f, 0xce60, 0xce61, 0xce68, 0xce69, + 0xce6b, 0xce6d, 0xce74, 0xce75, 0xce78, 0xce7c, 0xce84, 0xce85, + 0xce87, 0xce89, 0xce90, 0xce91, 0xce94, 0xce98, 0xcea0, 0xcea1, + 0xcea3, 0xcea4, 0xcea5, 0xceac, 0xcead, 0xcec1, 0xcee4, 0xcee5, + 0xcee8, 0xceeb, 0xceec, 0xcef4, 0xcef5, 0xcef7, 0xcef8, 0xcef9, + 0xcf00, 0xcf01, 0xcf04, 0xcf08, 0xcf10, 0xcf11, 0xcf13, 0xcf15, + 0xcf1c, 0xcf20, 0xcf24, 0xcf2c, 0xcf2d, 0xcf2f, 0xcf30, 0xcf31, + 0xcf38, 0xcf54, 0xcf55, 0xcf58, 0xcf5c, 0xcf64, 0xcf65, 0xcf67, + 0xcf69, 0xcf70, 0xcf71, 0xcf74, 0xcf78, 0xcf80, 0xcf85, 0xcf8c, + 0xcfa1, 0xcfa8, 0xcfb0, 0xcfc4, 0xcfe0, 0xcfe1, 0xcfe4, 0xcfe8, + 0xcff0, 0xcff1, 0xcff3, 0xcff5, 0xcffc, 0xd000, 0xd004, 0xd011, + 0xd018, 0xd02d, 0xd034, 0xd035, 0xd038, 0xd03c, + /* 0x45 */ + 0xd044, 0xd045, 0xd047, 0xd049, 0xd050, 0xd054, 0xd058, 0xd060, + 0xd06c, 0xd06d, 0xd070, 0xd074, 0xd07c, 0xd07d, 0xd081, 0xd0a4, + 0xd0a5, 0xd0a8, 0xd0ac, 0xd0b4, 0xd0b5, 0xd0b7, 0xd0b9, 0xd0c0, + 0xd0c1, 0xd0c4, 0xd0c8, 0xd0c9, 0xd0d0, 0xd0d1, 0xd0d3, 0xd0d4, + 0xd0d5, 0xd0dc, 0xd0dd, 0xd0e0, 0xd0e4, 0xd0ec, 0xd0ed, 0xd0ef, + 0xd0f0, 0xd0f1, 0xd0f8, 0xd10d, 0xd130, 0xd131, 0xd134, 0xd138, + 0xd13a, 0xd140, 0xd141, 0xd143, 0xd144, 0xd145, 0xd14c, 0xd14d, + 0xd150, 0xd154, 0xd15c, 0xd15d, 0xd15f, 0xd161, 0xd168, 0xd16c, + 0xd17c, 0xd184, 0xd188, 0xd1a0, 0xd1a1, 0xd1a4, 0xd1a8, 0xd1b0, + 0xd1b1, 0xd1b3, 0xd1b5, 0xd1ba, 0xd1bc, 0xd1c0, 0xd1d8, 0xd1f4, + 0xd1f8, 0xd207, 0xd209, 0xd210, 0xd22c, 0xd22d, 0xd230, 0xd234, + 0xd23c, 0xd23d, 0xd23f, 0xd241, 0xd248, 0xd25c, + /* 0x46 */ + 0xd264, 0xd280, 0xd281, 0xd284, 0xd288, 0xd290, 0xd291, 0xd295, + 0xd29c, 0xd2a0, 0xd2a4, 0xd2ac, 0xd2b1, 0xd2b8, 0xd2b9, 0xd2bc, + 0xd2bf, 0xd2c0, 0xd2c2, 0xd2c8, 0xd2c9, 0xd2cb, 0xd2d4, 0xd2d8, + 0xd2dc, 0xd2e4, 0xd2e5, 0xd2f0, 0xd2f1, 0xd2f4, 0xd2f8, 0xd300, + 0xd301, 0xd303, 0xd305, 0xd30c, 0xd30d, 0xd30e, 0xd310, 0xd314, + 0xd316, 0xd31c, 0xd31d, 0xd31f, 0xd320, 0xd321, 0xd325, 0xd328, + 0xd329, 0xd32c, 0xd330, 0xd338, 0xd339, 0xd33b, 0xd33c, 0xd33d, + 0xd344, 0xd345, 0xd37c, 0xd37d, 0xd380, 0xd384, 0xd38c, 0xd38d, + 0xd38f, 0xd390, 0xd391, 0xd398, 0xd399, 0xd39c, 0xd3a0, 0xd3a8, + 0xd3a9, 0xd3ab, 0xd3ad, 0xd3b4, 0xd3b8, 0xd3bc, 0xd3c4, 0xd3c5, + 0xd3c8, 0xd3c9, 0xd3d0, 0xd3d8, 0xd3e1, 0xd3e3, 0xd3ec, 0xd3ed, + 0xd3f0, 0xd3f4, 0xd3fc, 0xd3fd, 0xd3ff, 0xd401, + /* 0x47 */ + 0xd408, 0xd41d, 0xd440, 0xd444, 0xd45c, 0xd460, 0xd464, 0xd46d, + 0xd46f, 0xd478, 0xd479, 0xd47c, 0xd47f, 0xd480, 0xd482, 0xd488, + 0xd489, 0xd48b, 0xd48d, 0xd494, 0xd4a9, 0xd4cc, 0xd4d0, 0xd4d4, + 0xd4dc, 0xd4df, 0xd4e8, 0xd4ec, 0xd4f0, 0xd4f8, 0xd4fb, 0xd4fd, + 0xd504, 0xd508, 0xd50c, 0xd514, 0xd515, 0xd517, 0xd53c, 0xd53d, + 0xd540, 0xd544, 0xd54c, 0xd54d, 0xd54f, 0xd551, 0xd558, 0xd559, + 0xd55c, 0xd560, 0xd565, 0xd568, 0xd569, 0xd56b, 0xd56d, 0xd574, + 0xd575, 0xd578, 0xd57c, 0xd584, 0xd585, 0xd587, 0xd588, 0xd589, + 0xd590, 0xd5a5, 0xd5c8, 0xd5c9, 0xd5cc, 0xd5d0, 0xd5d2, 0xd5d8, + 0xd5d9, 0xd5db, 0xd5dd, 0xd5e4, 0xd5e5, 0xd5e8, 0xd5ec, 0xd5f4, + 0xd5f5, 0xd5f7, 0xd5f9, 0xd600, 0xd601, 0xd604, 0xd608, 0xd610, + 0xd611, 0xd613, 0xd614, 0xd615, 0xd61c, 0xd620, + /* 0x48 */ + 0xd624, 0xd62d, 0xd638, 0xd639, 0xd63c, 0xd640, 0xd645, 0xd648, + 0xd649, 0xd64b, 0xd64d, 0xd651, 0xd654, 0xd655, 0xd658, 0xd65c, + 0xd667, 0xd669, 0xd670, 0xd671, 0xd674, 0xd683, 0xd685, 0xd68c, + 0xd68d, 0xd690, 0xd694, 0xd69d, 0xd69f, 0xd6a1, 0xd6a8, 0xd6ac, + 0xd6b0, 0xd6b9, 0xd6bb, 0xd6c4, 0xd6c5, 0xd6c8, 0xd6cc, 0xd6d1, + 0xd6d4, 0xd6d7, 0xd6d9, 0xd6e0, 0xd6e4, 0xd6e8, 0xd6f0, 0xd6f5, + 0xd6fc, 0xd6fd, 0xd700, 0xd704, 0xd711, 0xd718, 0xd719, 0xd71c, + 0xd720, 0xd728, 0xd729, 0xd72b, 0xd72d, 0xd734, 0xd735, 0xd738, + 0xd73c, 0xd744, 0xd747, 0xd749, 0xd750, 0xd751, 0xd754, 0xd756, + 0xd757, 0xd758, 0xd759, 0xd760, 0xd761, 0xd763, 0xd765, 0xd769, + 0xd76c, 0xd770, 0xd774, 0xd77c, 0xd77d, 0xd781, 0xd788, 0xd789, + 0xd78c, 0xd790, 0xd798, 0xd799, 0xd79b, 0xd79d, +}; +static const unsigned short ksc5601_2uni_page4a[4888] = { + /* 0x4a */ + 0x4f3d, 0x4f73, 0x5047, 0x50f9, 0x52a0, 0x53ef, 0x5475, 0x54e5, + 0x5609, 0x5ac1, 0x5bb6, 0x6687, 0x67b6, 0x67b7, 0x67ef, 0x6b4c, + 0x73c2, 0x75c2, 0x7a3c, 0x82db, 0x8304, 0x8857, 0x8888, 0x8a36, + 0x8cc8, 0x8dcf, 0x8efb, 0x8fe6, 0x99d5, 0x523b, 0x5374, 0x5404, + 0x606a, 0x6164, 0x6bbc, 0x73cf, 0x811a, 0x89ba, 0x89d2, 0x95a3, + 0x4f83, 0x520a, 0x58be, 0x5978, 0x59e6, 0x5e72, 0x5e79, 0x61c7, + 0x63c0, 0x6746, 0x67ec, 0x687f, 0x6f97, 0x764e, 0x770b, 0x78f5, + 0x7a08, 0x7aff, 0x7c21, 0x809d, 0x826e, 0x8271, 0x8aeb, 0x9593, + 0x4e6b, 0x559d, 0x66f7, 0x6e34, 0x78a3, 0x7aed, 0x845b, 0x8910, + 0x874e, 0x97a8, 0x52d8, 0x574e, 0x582a, 0x5d4c, 0x611f, 0x61be, + 0x6221, 0x6562, 0x67d1, 0x6a44, 0x6e1b, 0x7518, 0x75b3, 0x76e3, + 0x77b0, 0x7d3a, 0x90af, 0x9451, 0x9452, 0x9f95, + /* 0x4b */ + 0x5323, 0x5cac, 0x7532, 0x80db, 0x9240, 0x9598, 0x525b, 0x5808, + 0x59dc, 0x5ca1, 0x5d17, 0x5eb7, 0x5f3a, 0x5f4a, 0x6177, 0x6c5f, + 0x757a, 0x7586, 0x7ce0, 0x7d73, 0x7db1, 0x7f8c, 0x8154, 0x8221, + 0x8591, 0x8941, 0x8b1b, 0x92fc, 0x964d, 0x9c47, 0x4ecb, 0x4ef7, + 0x500b, 0x51f1, 0x584f, 0x6137, 0x613e, 0x6168, 0x6539, 0x69ea, + 0x6f11, 0x75a5, 0x7686, 0x76d6, 0x7b87, 0x82a5, 0x84cb, 0xf900, + 0x93a7, 0x958b, 0x5580, 0x5ba2, 0x5751, 0xf901, 0x7cb3, 0x7fb9, + 0x91b5, 0x5028, 0x53bb, 0x5c45, 0x5de8, 0x62d2, 0x636e, 0x64da, + 0x64e7, 0x6e20, 0x70ac, 0x795b, 0x8ddd, 0x8e1e, 0xf902, 0x907d, + 0x9245, 0x92f8, 0x4e7e, 0x4ef6, 0x5065, 0x5dfe, 0x5efa, 0x6106, + 0x6957, 0x8171, 0x8654, 0x8e47, 0x9375, 0x9a2b, 0x4e5e, 0x5091, + 0x6770, 0x6840, 0x5109, 0x528d, 0x5292, 0x6aa2, + /* 0x4c */ + 0x77bc, 0x9210, 0x9ed4, 0x52ab, 0x602f, 0x8ff2, 0x5048, 0x61a9, + 0x63ed, 0x64ca, 0x683c, 0x6a84, 0x6fc0, 0x8188, 0x89a1, 0x9694, + 0x5805, 0x727d, 0x72ac, 0x7504, 0x7d79, 0x7e6d, 0x80a9, 0x898b, + 0x8b74, 0x9063, 0x9d51, 0x6289, 0x6c7a, 0x6f54, 0x7d50, 0x7f3a, + 0x8a23, 0x517c, 0x614a, 0x7b9d, 0x8b19, 0x9257, 0x938c, 0x4eac, + 0x4fd3, 0x501e, 0x50be, 0x5106, 0x52c1, 0x52cd, 0x537f, 0x5770, + 0x5883, 0x5e9a, 0x5f91, 0x6176, 0x61ac, 0x64ce, 0x656c, 0x666f, + 0x66bb, 0x66f4, 0x6897, 0x6d87, 0x7085, 0x70f1, 0x749f, 0x74a5, + 0x74ca, 0x75d9, 0x786c, 0x78ec, 0x7adf, 0x7af6, 0x7d45, 0x7d93, + 0x8015, 0x803f, 0x811b, 0x8396, 0x8b66, 0x8f15, 0x9015, 0x93e1, + 0x9803, 0x9838, 0x9a5a, 0x9be8, 0x4fc2, 0x5553, 0x583a, 0x5951, + 0x5b63, 0x5c46, 0x60b8, 0x6212, 0x6842, 0x68b0, + /* 0x4d */ + 0x68e8, 0x6eaa, 0x754c, 0x7678, 0x78ce, 0x7a3d, 0x7cfb, 0x7e6b, + 0x7e7c, 0x8a08, 0x8aa1, 0x8c3f, 0x968e, 0x9dc4, 0x53e4, 0x53e9, + 0x544a, 0x5471, 0x56fa, 0x59d1, 0x5b64, 0x5c3b, 0x5eab, 0x62f7, + 0x6537, 0x6545, 0x6572, 0x66a0, 0x67af, 0x69c1, 0x6cbd, 0x75fc, + 0x7690, 0x777e, 0x7a3f, 0x7f94, 0x8003, 0x80a1, 0x818f, 0x82e6, + 0x82fd, 0x83f0, 0x85c1, 0x8831, 0x88b4, 0x8aa5, 0xf903, 0x8f9c, + 0x932e, 0x96c7, 0x9867, 0x9ad8, 0x9f13, 0x54ed, 0x659b, 0x66f2, + 0x688f, 0x7a40, 0x8c37, 0x9d60, 0x56f0, 0x5764, 0x5d11, 0x6606, + 0x68b1, 0x68cd, 0x6efe, 0x7428, 0x889e, 0x9be4, 0x6c68, 0xf904, + 0x9aa8, 0x4f9b, 0x516c, 0x5171, 0x529f, 0x5b54, 0x5de5, 0x6050, + 0x606d, 0x62f1, 0x63a7, 0x653b, 0x73d9, 0x7a7a, 0x86a3, 0x8ca2, + 0x978f, 0x4e32, 0x5be1, 0x6208, 0x679c, 0x74dc, + /* 0x4e */ + 0x79d1, 0x83d3, 0x8a87, 0x8ab2, 0x8de8, 0x904e, 0x934b, 0x9846, + 0x5ed3, 0x69e8, 0x85ff, 0x90ed, 0xf905, 0x51a0, 0x5b98, 0x5bec, + 0x6163, 0x68fa, 0x6b3e, 0x704c, 0x742f, 0x74d8, 0x7ba1, 0x7f50, + 0x83c5, 0x89c0, 0x8cab, 0x95dc, 0x9928, 0x522e, 0x605d, 0x62ec, + 0x9002, 0x4f8a, 0x5149, 0x5321, 0x58d9, 0x5ee3, 0x66e0, 0x6d38, + 0x709a, 0x72c2, 0x73d6, 0x7b50, 0x80f1, 0x945b, 0x5366, 0x639b, + 0x7f6b, 0x4e56, 0x5080, 0x584a, 0x58de, 0x602a, 0x6127, 0x62d0, + 0x69d0, 0x9b41, 0x5b8f, 0x7d18, 0x80b1, 0x8f5f, 0x4ea4, 0x50d1, + 0x54ac, 0x55ac, 0x5b0c, 0x5da0, 0x5de7, 0x652a, 0x654e, 0x6821, + 0x6a4b, 0x72e1, 0x768e, 0x77ef, 0x7d5e, 0x7ff9, 0x81a0, 0x854e, + 0x86df, 0x8f03, 0x8f4e, 0x90ca, 0x9903, 0x9a55, 0x9bab, 0x4e18, + 0x4e45, 0x4e5d, 0x4ec7, 0x4ff1, 0x5177, 0x52fe, + /* 0x4f */ + 0x5340, 0x53e3, 0x53e5, 0x548e, 0x5614, 0x5775, 0x57a2, 0x5bc7, + 0x5d87, 0x5ed0, 0x61fc, 0x62d8, 0x6551, 0x67b8, 0x67e9, 0x69cb, + 0x6b50, 0x6bc6, 0x6bec, 0x6c42, 0x6e9d, 0x7078, 0x72d7, 0x7396, + 0x7403, 0x77bf, 0x77e9, 0x7a76, 0x7d7f, 0x8009, 0x81fc, 0x8205, + 0x820a, 0x82df, 0x8862, 0x8b33, 0x8cfc, 0x8ec0, 0x9011, 0x90b1, + 0x9264, 0x92b6, 0x99d2, 0x9a45, 0x9ce9, 0x9dd7, 0x9f9c, 0x570b, + 0x5c40, 0x83ca, 0x97a0, 0x97ab, 0x9eb4, 0x541b, 0x7a98, 0x7fa4, + 0x88d9, 0x8ecd, 0x90e1, 0x5800, 0x5c48, 0x6398, 0x7a9f, 0x5bae, + 0x5f13, 0x7a79, 0x7aae, 0x828e, 0x8eac, 0x5026, 0x5238, 0x52f8, + 0x5377, 0x5708, 0x62f3, 0x6372, 0x6b0a, 0x6dc3, 0x7737, 0x53a5, + 0x7357, 0x8568, 0x8e76, 0x95d5, 0x673a, 0x6ac3, 0x6f70, 0x8a6d, + 0x8ecc, 0x994b, 0xf906, 0x6677, 0x6b78, 0x8cb4, + /* 0x50 */ + 0x9b3c, 0xf907, 0x53eb, 0x572d, 0x594e, 0x63c6, 0x69fb, 0x73ea, + 0x7845, 0x7aba, 0x7ac5, 0x7cfe, 0x8475, 0x898f, 0x8d73, 0x9035, + 0x95a8, 0x52fb, 0x5747, 0x7547, 0x7b60, 0x83cc, 0x921e, 0xf908, + 0x6a58, 0x514b, 0x524b, 0x5287, 0x621f, 0x68d8, 0x6975, 0x9699, + 0x50c5, 0x52a4, 0x52e4, 0x61c3, 0x65a4, 0x6839, 0x69ff, 0x747e, + 0x7b4b, 0x82b9, 0x83eb, 0x89b2, 0x8b39, 0x8fd1, 0x9949, 0xf909, + 0x4eca, 0x5997, 0x64d2, 0x6611, 0x6a8e, 0x7434, 0x7981, 0x79bd, + 0x82a9, 0x887e, 0x887f, 0x895f, 0xf90a, 0x9326, 0x4f0b, 0x53ca, + 0x6025, 0x6271, 0x6c72, 0x7d1a, 0x7d66, 0x4e98, 0x5162, 0x77dc, + 0x80af, 0x4f01, 0x4f0e, 0x5176, 0x5180, 0x55dc, 0x5668, 0x573b, + 0x57fa, 0x57fc, 0x5914, 0x5947, 0x5993, 0x5bc4, 0x5c90, 0x5d0e, + 0x5df1, 0x5e7e, 0x5fcc, 0x6280, 0x65d7, 0x65e3, + /* 0x51 */ + 0x671e, 0x671f, 0x675e, 0x68cb, 0x68c4, 0x6a5f, 0x6b3a, 0x6c23, + 0x6c7d, 0x6c82, 0x6dc7, 0x7398, 0x7426, 0x742a, 0x7482, 0x74a3, + 0x7578, 0x757f, 0x7881, 0x78ef, 0x7941, 0x7947, 0x7948, 0x797a, + 0x7b95, 0x7d00, 0x7dba, 0x7f88, 0x8006, 0x802d, 0x808c, 0x8a18, + 0x8b4f, 0x8c48, 0x8d77, 0x9321, 0x9324, 0x98e2, 0x9951, 0x9a0e, + 0x9a0f, 0x9a65, 0x9e92, 0x7dca, 0x4f76, 0x5409, 0x62ee, 0x6854, + 0x91d1, 0x55ab, 0x513a, 0xf90b, 0xf90c, 0x5a1c, 0x61e6, 0xf90d, + 0x62cf, 0x62ff, 0xf90e, 0xf90f, 0xf910, 0xf911, 0xf912, 0xf913, + 0x90a3, 0xf914, 0xf915, 0xf916, 0xf917, 0xf918, 0x8afe, 0xf919, + 0xf91a, 0xf91b, 0xf91c, 0x6696, 0xf91d, 0x7156, 0xf91e, 0xf91f, + 0x96e3, 0xf920, 0x634f, 0x637a, 0x5357, 0xf921, 0x678f, 0x6960, + 0x6e73, 0xf922, 0x7537, 0xf923, 0xf924, 0xf925, + /* 0x52 */ + 0x7d0d, 0xf926, 0xf927, 0x8872, 0x56ca, 0x5a18, 0xf928, 0xf929, + 0xf92a, 0xf92b, 0xf92c, 0x4e43, 0xf92d, 0x5167, 0x5948, 0x67f0, + 0x8010, 0xf92e, 0x5973, 0x5e74, 0x649a, 0x79ca, 0x5ff5, 0x606c, + 0x62c8, 0x637b, 0x5be7, 0x5bd7, 0x52aa, 0xf92f, 0x5974, 0x5f29, + 0x6012, 0xf930, 0xf931, 0xf932, 0x7459, 0xf933, 0xf934, 0xf935, + 0xf936, 0xf937, 0xf938, 0x99d1, 0xf939, 0xf93a, 0xf93b, 0xf93c, + 0xf93d, 0xf93e, 0xf93f, 0xf940, 0xf941, 0xf942, 0xf943, 0x6fc3, + 0xf944, 0xf945, 0x81bf, 0x8fb2, 0x60f1, 0xf946, 0xf947, 0x8166, + 0xf948, 0xf949, 0x5c3f, 0xf94a, 0xf94b, 0xf94c, 0xf94d, 0xf94e, + 0xf94f, 0xf950, 0xf951, 0x5ae9, 0x8a25, 0x677b, 0x7d10, 0xf952, + 0xf953, 0xf954, 0xf955, 0xf956, 0xf957, 0x80fd, 0xf958, 0xf959, + 0x5c3c, 0x6ce5, 0x533f, 0x6eba, 0x591a, 0x8336, + /* 0x53 */ + 0x4e39, 0x4eb6, 0x4f46, 0x55ae, 0x5718, 0x58c7, 0x5f56, 0x65b7, + 0x65e6, 0x6a80, 0x6bb5, 0x6e4d, 0x77ed, 0x7aef, 0x7c1e, 0x7dde, + 0x86cb, 0x8892, 0x9132, 0x935b, 0x64bb, 0x6fbe, 0x737a, 0x75b8, + 0x9054, 0x5556, 0x574d, 0x61ba, 0x64d4, 0x66c7, 0x6de1, 0x6e5b, + 0x6f6d, 0x6fb9, 0x75f0, 0x8043, 0x81bd, 0x8541, 0x8983, 0x8ac7, + 0x8b5a, 0x931f, 0x6c93, 0x7553, 0x7b54, 0x8e0f, 0x905d, 0x5510, + 0x5802, 0x5858, 0x5e62, 0x6207, 0x649e, 0x68e0, 0x7576, 0x7cd6, + 0x87b3, 0x9ee8, 0x4ee3, 0x5788, 0x576e, 0x5927, 0x5c0d, 0x5cb1, + 0x5e36, 0x5f85, 0x6234, 0x64e1, 0x73b3, 0x81fa, 0x888b, 0x8cb8, + 0x968a, 0x9edb, 0x5b85, 0x5fb7, 0x60b3, 0x5012, 0x5200, 0x5230, + 0x5716, 0x5835, 0x5857, 0x5c0e, 0x5c60, 0x5cf6, 0x5d8b, 0x5ea6, + 0x5f92, 0x60bc, 0x6311, 0x6389, 0x6417, 0x6843, + /* 0x54 */ + 0x68f9, 0x6ac2, 0x6dd8, 0x6e21, 0x6ed4, 0x6fe4, 0x71fe, 0x76dc, + 0x7779, 0x79b1, 0x7a3b, 0x8404, 0x89a9, 0x8ced, 0x8df3, 0x8e48, + 0x9003, 0x9014, 0x9053, 0x90fd, 0x934d, 0x9676, 0x97dc, 0x6bd2, + 0x7006, 0x7258, 0x72a2, 0x7368, 0x7763, 0x79bf, 0x7be4, 0x7e9b, + 0x8b80, 0x58a9, 0x60c7, 0x6566, 0x65fd, 0x66be, 0x6c8c, 0x711e, + 0x71c9, 0x8c5a, 0x9813, 0x4e6d, 0x7a81, 0x4edd, 0x51ac, 0x51cd, + 0x52d5, 0x540c, 0x61a7, 0x6771, 0x6850, 0x68df, 0x6d1e, 0x6f7c, + 0x75bc, 0x77b3, 0x7ae5, 0x80f4, 0x8463, 0x9285, 0x515c, 0x6597, + 0x675c, 0x6793, 0x75d8, 0x7ac7, 0x8373, 0xf95a, 0x8c46, 0x9017, + 0x982d, 0x5c6f, 0x81c0, 0x829a, 0x9041, 0x906f, 0x920d, 0x5f97, + 0x5d9d, 0x6a59, 0x71c8, 0x767b, 0x7b49, 0x85e4, 0x8b04, 0x9127, + 0x9a30, 0x5587, 0x61f6, 0xf95b, 0x7669, 0x7f85, + /* 0x55 */ + 0x863f, 0x87ba, 0x88f8, 0x908f, 0xf95c, 0x6d1b, 0x70d9, 0x73de, + 0x7d61, 0x843d, 0xf95d, 0x916a, 0x99f1, 0xf95e, 0x4e82, 0x5375, + 0x6b04, 0x6b12, 0x703e, 0x721b, 0x862d, 0x9e1e, 0x524c, 0x8fa3, + 0x5d50, 0x64e5, 0x652c, 0x6b16, 0x6feb, 0x7c43, 0x7e9c, 0x85cd, + 0x8964, 0x89bd, 0x62c9, 0x81d8, 0x881f, 0x5eca, 0x6717, 0x6d6a, + 0x72fc, 0x7405, 0x746f, 0x8782, 0x90de, 0x4f86, 0x5d0d, 0x5fa0, + 0x840a, 0x51b7, 0x63a0, 0x7565, 0x4eae, 0x5006, 0x5169, 0x51c9, + 0x6881, 0x6a11, 0x7cae, 0x7cb1, 0x7ce7, 0x826f, 0x8ad2, 0x8f1b, + 0x91cf, 0x4fb6, 0x5137, 0x52f5, 0x5442, 0x5eec, 0x616e, 0x623e, + 0x65c5, 0x6ada, 0x6ffe, 0x792a, 0x85dc, 0x8823, 0x95ad, 0x9a62, + 0x9a6a, 0x9e97, 0x9ece, 0x529b, 0x66c6, 0x6b77, 0x701d, 0x792b, + 0x8f62, 0x9742, 0x6190, 0x6200, 0x6523, 0x6f23, + /* 0x56 */ + 0x7149, 0x7489, 0x7df4, 0x806f, 0x84ee, 0x8f26, 0x9023, 0x934a, + 0x51bd, 0x5217, 0x52a3, 0x6d0c, 0x70c8, 0x88c2, 0x5ec9, 0x6582, + 0x6bae, 0x6fc2, 0x7c3e, 0x7375, 0x4ee4, 0x4f36, 0x56f9, 0xf95f, + 0x5cba, 0x5dba, 0x601c, 0x73b2, 0x7b2d, 0x7f9a, 0x7fce, 0x8046, + 0x901e, 0x9234, 0x96f6, 0x9748, 0x9818, 0x9f61, 0x4f8b, 0x6fa7, + 0x79ae, 0x91b4, 0x96b7, 0x52de, 0xf960, 0x6488, 0x64c4, 0x6ad3, + 0x6f5e, 0x7018, 0x7210, 0x76e7, 0x8001, 0x8606, 0x865c, 0x8def, + 0x8f05, 0x9732, 0x9b6f, 0x9dfa, 0x9e75, 0x788c, 0x797f, 0x7da0, + 0x83c9, 0x9304, 0x9e7f, 0x9e93, 0x8ad6, 0x58df, 0x5f04, 0x6727, + 0x7027, 0x74cf, 0x7c60, 0x807e, 0x5121, 0x7028, 0x7262, 0x78ca, + 0x8cc2, 0x8cda, 0x8cf4, 0x96f7, 0x4e86, 0x50da, 0x5bee, 0x5ed6, + 0x6599, 0x71ce, 0x7642, 0x77ad, 0x804a, 0x84fc, + /* 0x57 */ + 0x907c, 0x9b27, 0x9f8d, 0x58d8, 0x5a41, 0x5c62, 0x6a13, 0x6dda, + 0x6f0f, 0x763b, 0x7d2f, 0x7e37, 0x851e, 0x8938, 0x93e4, 0x964b, + 0x5289, 0x65d2, 0x67f3, 0x69b4, 0x6d41, 0x6e9c, 0x700f, 0x7409, + 0x7460, 0x7559, 0x7624, 0x786b, 0x8b2c, 0x985e, 0x516d, 0x622e, + 0x9678, 0x4f96, 0x502b, 0x5d19, 0x6dea, 0x7db8, 0x8f2a, 0x5f8b, + 0x6144, 0x6817, 0xf961, 0x9686, 0x52d2, 0x808b, 0x51dc, 0x51cc, + 0x695e, 0x7a1c, 0x7dbe, 0x83f1, 0x9675, 0x4fda, 0x5229, 0x5398, + 0x540f, 0x550e, 0x5c65, 0x60a7, 0x674e, 0x68a8, 0x6d6c, 0x7281, + 0x72f8, 0x7406, 0x7483, 0xf962, 0x75e2, 0x7c6c, 0x7f79, 0x7fb8, + 0x8389, 0x88cf, 0x88e1, 0x91cc, 0x91d0, 0x96e2, 0x9bc9, 0x541d, + 0x6f7e, 0x71d0, 0x7498, 0x85fa, 0x8eaa, 0x96a3, 0x9c57, 0x9e9f, + 0x6797, 0x6dcb, 0x7433, 0x81e8, 0x9716, 0x782c, + /* 0x58 */ + 0x7acb, 0x7b20, 0x7c92, 0x6469, 0x746a, 0x75f2, 0x78bc, 0x78e8, + 0x99ac, 0x9b54, 0x9ebb, 0x5bde, 0x5e55, 0x6f20, 0x819c, 0x83ab, + 0x9088, 0x4e07, 0x534d, 0x5a29, 0x5dd2, 0x5f4e, 0x6162, 0x633d, + 0x6669, 0x66fc, 0x6eff, 0x6f2b, 0x7063, 0x779e, 0x842c, 0x8513, + 0x883b, 0x8f13, 0x9945, 0x9c3b, 0x551c, 0x62b9, 0x672b, 0x6cab, + 0x8309, 0x896a, 0x977a, 0x4ea1, 0x5984, 0x5fd8, 0x5fd9, 0x671b, + 0x7db2, 0x7f54, 0x8292, 0x832b, 0x83bd, 0x8f1e, 0x9099, 0x57cb, + 0x59b9, 0x5a92, 0x5bd0, 0x6627, 0x679a, 0x6885, 0x6bcf, 0x7164, + 0x7f75, 0x8cb7, 0x8ce3, 0x9081, 0x9b45, 0x8108, 0x8c8a, 0x964c, + 0x9a40, 0x9ea5, 0x5b5f, 0x6c13, 0x731b, 0x76f2, 0x76df, 0x840c, + 0x51aa, 0x8993, 0x514d, 0x5195, 0x52c9, 0x68c9, 0x6c94, 0x7704, + 0x7720, 0x7dbf, 0x7dec, 0x9762, 0x9eb5, 0x6ec5, + /* 0x59 */ + 0x8511, 0x51a5, 0x540d, 0x547d, 0x660e, 0x669d, 0x6927, 0x6e9f, + 0x76bf, 0x7791, 0x8317, 0x84c2, 0x879f, 0x9169, 0x9298, 0x9cf4, + 0x8882, 0x4fae, 0x5192, 0x52df, 0x59c6, 0x5e3d, 0x6155, 0x6478, + 0x6479, 0x66ae, 0x67d0, 0x6a21, 0x6bcd, 0x6bdb, 0x725f, 0x7261, + 0x7441, 0x7738, 0x77db, 0x8017, 0x82bc, 0x8305, 0x8b00, 0x8b28, + 0x8c8c, 0x6728, 0x6c90, 0x7267, 0x76ee, 0x7766, 0x7a46, 0x9da9, + 0x6b7f, 0x6c92, 0x5922, 0x6726, 0x8499, 0x536f, 0x5893, 0x5999, + 0x5edf, 0x63cf, 0x6634, 0x6773, 0x6e3a, 0x732b, 0x7ad7, 0x82d7, + 0x9328, 0x52d9, 0x5deb, 0x61ae, 0x61cb, 0x620a, 0x62c7, 0x64ab, + 0x65e0, 0x6959, 0x6b66, 0x6bcb, 0x7121, 0x73f7, 0x755d, 0x7e46, + 0x821e, 0x8302, 0x856a, 0x8aa3, 0x8cbf, 0x9727, 0x9d61, 0x58a8, + 0x9ed8, 0x5011, 0x520e, 0x543b, 0x554f, 0x6587, + /* 0x5a */ + 0x6c76, 0x7d0a, 0x7d0b, 0x805e, 0x868a, 0x9580, 0x96ef, 0x52ff, + 0x6c95, 0x7269, 0x5473, 0x5a9a, 0x5c3e, 0x5d4b, 0x5f4c, 0x5fae, + 0x672a, 0x68b6, 0x6963, 0x6e3c, 0x6e44, 0x7709, 0x7c73, 0x7f8e, + 0x8587, 0x8b0e, 0x8ff7, 0x9761, 0x9ef4, 0x5cb7, 0x60b6, 0x610d, + 0x61ab, 0x654f, 0x65fb, 0x65fc, 0x6c11, 0x6cef, 0x739f, 0x73c9, + 0x7de1, 0x9594, 0x5bc6, 0x871c, 0x8b10, 0x525d, 0x535a, 0x62cd, + 0x640f, 0x64b2, 0x6734, 0x6a38, 0x6cca, 0x73c0, 0x749e, 0x7b94, + 0x7c95, 0x7e1b, 0x818a, 0x8236, 0x8584, 0x8feb, 0x96f9, 0x99c1, + 0x4f34, 0x534a, 0x53cd, 0x53db, 0x62cc, 0x642c, 0x6500, 0x6591, + 0x69c3, 0x6cee, 0x6f58, 0x73ed, 0x7554, 0x7622, 0x76e4, 0x76fc, + 0x78d0, 0x78fb, 0x792c, 0x7d46, 0x822c, 0x87e0, 0x8fd4, 0x9812, + 0x98ef, 0x52c3, 0x62d4, 0x64a5, 0x6e24, 0x6f51, + /* 0x5b */ + 0x767c, 0x8dcb, 0x91b1, 0x9262, 0x9aee, 0x9b43, 0x5023, 0x508d, + 0x574a, 0x59a8, 0x5c28, 0x5e47, 0x5f77, 0x623f, 0x653e, 0x65b9, + 0x65c1, 0x6609, 0x678b, 0x699c, 0x6ec2, 0x78c5, 0x7d21, 0x80aa, + 0x8180, 0x822b, 0x82b3, 0x84a1, 0x868c, 0x8a2a, 0x8b17, 0x90a6, + 0x9632, 0x9f90, 0x500d, 0x4ff3, 0xf963, 0x57f9, 0x5f98, 0x62dc, + 0x6392, 0x676f, 0x6e43, 0x7119, 0x76c3, 0x80cc, 0x80da, 0x88f4, + 0x88f5, 0x8919, 0x8ce0, 0x8f29, 0x914d, 0x966a, 0x4f2f, 0x4f70, + 0x5e1b, 0x67cf, 0x6822, 0x767d, 0x767e, 0x9b44, 0x5e61, 0x6a0a, + 0x7169, 0x71d4, 0x756a, 0xf964, 0x7e41, 0x8543, 0x85e9, 0x98dc, + 0x4f10, 0x7b4f, 0x7f70, 0x95a5, 0x51e1, 0x5e06, 0x68b5, 0x6c3e, + 0x6c4e, 0x6cdb, 0x72af, 0x7bc4, 0x8303, 0x6cd5, 0x743a, 0x50fb, + 0x5288, 0x58c1, 0x64d8, 0x6a97, 0x74a7, 0x7656, + /* 0x5c */ + 0x78a7, 0x8617, 0x95e2, 0x9739, 0xf965, 0x535e, 0x5f01, 0x8b8a, + 0x8fa8, 0x8faf, 0x908a, 0x5225, 0x77a5, 0x9c49, 0x9f08, 0x4e19, + 0x5002, 0x5175, 0x5c5b, 0x5e77, 0x661e, 0x663a, 0x67c4, 0x68c5, + 0x70b3, 0x7501, 0x75c5, 0x79c9, 0x7add, 0x8f27, 0x9920, 0x9a08, + 0x4fdd, 0x5821, 0x5831, 0x5bf6, 0x666e, 0x6b65, 0x6d11, 0x6e7a, + 0x6f7d, 0x73e4, 0x752b, 0x83e9, 0x88dc, 0x8913, 0x8b5c, 0x8f14, + 0x4f0f, 0x50d5, 0x5310, 0x535c, 0x5b93, 0x5fa9, 0x670d, 0x798f, + 0x8179, 0x832f, 0x8514, 0x8907, 0x8986, 0x8f39, 0x8f3b, 0x99a5, + 0x9c12, 0x672c, 0x4e76, 0x4ff8, 0x5949, 0x5c01, 0x5cef, 0x5cf0, + 0x6367, 0x68d2, 0x70fd, 0x71a2, 0x742b, 0x7e2b, 0x84ec, 0x8702, + 0x9022, 0x92d2, 0x9cf3, 0x4e0d, 0x4ed8, 0x4fef, 0x5085, 0x5256, + 0x526f, 0x5426, 0x5490, 0x57e0, 0x592b, 0x5a66, + /* 0x5d */ + 0x5b5a, 0x5b75, 0x5bcc, 0x5e9c, 0xf966, 0x6276, 0x6577, 0x65a7, + 0x6d6e, 0x6ea5, 0x7236, 0x7b26, 0x7c3f, 0x7f36, 0x8150, 0x8151, + 0x819a, 0x8240, 0x8299, 0x83a9, 0x8a03, 0x8ca0, 0x8ce6, 0x8cfb, + 0x8d74, 0x8dba, 0x90e8, 0x91dc, 0x961c, 0x9644, 0x99d9, 0x9ce7, + 0x5317, 0x5206, 0x5429, 0x5674, 0x58b3, 0x5954, 0x596e, 0x5fff, + 0x61a4, 0x626e, 0x6610, 0x6c7e, 0x711a, 0x76c6, 0x7c89, 0x7cde, + 0x7d1b, 0x82ac, 0x8cc1, 0x96f0, 0xf967, 0x4f5b, 0x5f17, 0x5f7f, + 0x62c2, 0x5d29, 0x670b, 0x68da, 0x787c, 0x7e43, 0x9d6c, 0x4e15, + 0x5099, 0x5315, 0x532a, 0x5351, 0x5983, 0x5a62, 0x5e87, 0x60b2, + 0x618a, 0x6249, 0x6279, 0x6590, 0x6787, 0x69a7, 0x6bd4, 0x6bd6, + 0x6bd7, 0x6bd8, 0x6cb8, 0xf968, 0x7435, 0x75fa, 0x7812, 0x7891, + 0x79d5, 0x79d8, 0x7c83, 0x7dcb, 0x7fe1, 0x80a5, + /* 0x5e */ + 0x813e, 0x81c2, 0x83f2, 0x871a, 0x88e8, 0x8ab9, 0x8b6c, 0x8cbb, + 0x9119, 0x975e, 0x98db, 0x9f3b, 0x56ac, 0x5b2a, 0x5f6c, 0x658c, + 0x6ab3, 0x6baf, 0x6d5c, 0x6ff1, 0x7015, 0x725d, 0x73ad, 0x8ca7, + 0x8cd3, 0x983b, 0x6191, 0x6c37, 0x8058, 0x9a01, 0x4e4d, 0x4e8b, + 0x4e9b, 0x4ed5, 0x4f3a, 0x4f3c, 0x4f7f, 0x4fdf, 0x50ff, 0x53f2, + 0x53f8, 0x5506, 0x55e3, 0x56db, 0x58eb, 0x5962, 0x5a11, 0x5beb, + 0x5bfa, 0x5c04, 0x5df3, 0x5e2b, 0x5f99, 0x601d, 0x6368, 0x659c, + 0x65af, 0x67f6, 0x67fb, 0x68ad, 0x6b7b, 0x6c99, 0x6cd7, 0x6e23, + 0x7009, 0x7345, 0x7802, 0x793e, 0x7940, 0x7960, 0x79c1, 0x7be9, + 0x7d17, 0x7d72, 0x8086, 0x820d, 0x838e, 0x84d1, 0x86c7, 0x88df, + 0x8a50, 0x8a5e, 0x8b1d, 0x8cdc, 0x8d66, 0x8fad, 0x90aa, 0x98fc, + 0x99df, 0x9e9d, 0x524a, 0xf969, 0x6714, 0xf96a, + /* 0x5f */ + 0x5098, 0x522a, 0x5c71, 0x6563, 0x6c55, 0x73ca, 0x7523, 0x759d, + 0x7b97, 0x849c, 0x9178, 0x9730, 0x4e77, 0x6492, 0x6bba, 0x715e, + 0x85a9, 0x4e09, 0xf96b, 0x6749, 0x68ee, 0x6e17, 0x829f, 0x8518, + 0x886b, 0x63f7, 0x6f81, 0x9212, 0x98af, 0x4e0a, 0x50b7, 0x50cf, + 0x511f, 0x5546, 0x55aa, 0x5617, 0x5b40, 0x5c19, 0x5ce0, 0x5e38, + 0x5e8a, 0x5ea0, 0x5ec2, 0x60f3, 0x6851, 0x6a61, 0x6e58, 0x723d, + 0x7240, 0x72c0, 0x76f8, 0x7965, 0x7bb1, 0x7fd4, 0x88f3, 0x89f4, + 0x8a73, 0x8c61, 0x8cde, 0x971c, 0x585e, 0x74bd, 0x8cfd, 0x55c7, + 0xf96c, 0x7a61, 0x7d22, 0x8272, 0x7272, 0x751f, 0x7525, 0xf96d, + 0x7b19, 0x5885, 0x58fb, 0x5dbc, 0x5e8f, 0x5eb6, 0x5f90, 0x6055, + 0x6292, 0x637f, 0x654d, 0x6691, 0x66d9, 0x66f8, 0x6816, 0x68f2, + 0x7280, 0x745e, 0x7b6e, 0x7d6e, 0x7dd6, 0x7f72, + /* 0x60 */ + 0x80e5, 0x8212, 0x85af, 0x897f, 0x8a93, 0x901d, 0x92e4, 0x9ecd, + 0x9f20, 0x5915, 0x596d, 0x5e2d, 0x60dc, 0x6614, 0x6673, 0x6790, + 0x6c50, 0x6dc5, 0x6f5f, 0x77f3, 0x78a9, 0x84c6, 0x91cb, 0x932b, + 0x4ed9, 0x50ca, 0x5148, 0x5584, 0x5b0b, 0x5ba3, 0x6247, 0x657e, + 0x65cb, 0x6e32, 0x717d, 0x7401, 0x7444, 0x7487, 0x74bf, 0x766c, + 0x79aa, 0x7dda, 0x7e55, 0x7fa8, 0x817a, 0x81b3, 0x8239, 0x861a, + 0x87ec, 0x8a75, 0x8de3, 0x9078, 0x9291, 0x9425, 0x994d, 0x9bae, + 0x5368, 0x5c51, 0x6954, 0x6cc4, 0x6d29, 0x6e2b, 0x820c, 0x859b, + 0x893b, 0x8a2d, 0x8aaa, 0x96ea, 0x9f67, 0x5261, 0x66b9, 0x6bb2, + 0x7e96, 0x87fe, 0x8d0d, 0x9583, 0x965d, 0x651d, 0x6d89, 0x71ee, + 0xf96e, 0x57ce, 0x59d3, 0x5bac, 0x6027, 0x60fa, 0x6210, 0x661f, + 0x665f, 0x7329, 0x73f9, 0x76db, 0x7701, 0x7b6c, + /* 0x61 */ + 0x8056, 0x8072, 0x8165, 0x8aa0, 0x9192, 0x4e16, 0x52e2, 0x6b72, + 0x6d17, 0x7a05, 0x7b39, 0x7d30, 0xf96f, 0x8cb0, 0x53ec, 0x562f, + 0x5851, 0x5bb5, 0x5c0f, 0x5c11, 0x5de2, 0x6240, 0x6383, 0x6414, + 0x662d, 0x68b3, 0x6cbc, 0x6d88, 0x6eaf, 0x701f, 0x70a4, 0x71d2, + 0x7526, 0x758f, 0x758e, 0x7619, 0x7b11, 0x7be0, 0x7c2b, 0x7d20, + 0x7d39, 0x852c, 0x856d, 0x8607, 0x8a34, 0x900d, 0x9061, 0x90b5, + 0x92b7, 0x97f6, 0x9a37, 0x4fd7, 0x5c6c, 0x675f, 0x6d91, 0x7c9f, + 0x7e8c, 0x8b16, 0x8d16, 0x901f, 0x5b6b, 0x5dfd, 0x640d, 0x84c0, + 0x905c, 0x98e1, 0x7387, 0x5b8b, 0x609a, 0x677e, 0x6dde, 0x8a1f, + 0x8aa6, 0x9001, 0x980c, 0x5237, 0xf970, 0x7051, 0x788e, 0x9396, + 0x8870, 0x91d7, 0x4fee, 0x53d7, 0x55fd, 0x56da, 0x5782, 0x58fd, + 0x5ac2, 0x5b88, 0x5cab, 0x5cc0, 0x5e25, 0x6101, + /* 0x62 */ + 0x620d, 0x624b, 0x6388, 0x641c, 0x6536, 0x6578, 0x6a39, 0x6b8a, + 0x6c34, 0x6d19, 0x6f31, 0x71e7, 0x72e9, 0x7378, 0x7407, 0x74b2, + 0x7626, 0x7761, 0x79c0, 0x7a57, 0x7aea, 0x7cb9, 0x7d8f, 0x7dac, + 0x7e61, 0x7f9e, 0x8129, 0x8331, 0x8490, 0x84da, 0x85ea, 0x8896, + 0x8ab0, 0x8b90, 0x8f38, 0x9042, 0x9083, 0x916c, 0x9296, 0x92b9, + 0x968b, 0x96a7, 0x96a8, 0x96d6, 0x9700, 0x9808, 0x9996, 0x9ad3, + 0x9b1a, 0x53d4, 0x587e, 0x5919, 0x5b70, 0x5bbf, 0x6dd1, 0x6f5a, + 0x719f, 0x7421, 0x74b9, 0x8085, 0x83fd, 0x5de1, 0x5f87, 0x5faa, + 0x6042, 0x65ec, 0x6812, 0x696f, 0x6a53, 0x6b89, 0x6d35, 0x6df3, + 0x73e3, 0x76fe, 0x77ac, 0x7b4d, 0x7d14, 0x8123, 0x821c, 0x8340, + 0x84f4, 0x8563, 0x8a62, 0x8ac4, 0x9187, 0x931e, 0x9806, 0x99b4, + 0x620c, 0x8853, 0x8ff0, 0x9265, 0x5d07, 0x5d27, + /* 0x63 */ + 0x5d69, 0x745f, 0x819d, 0x8768, 0x6fd5, 0x62fe, 0x7fd2, 0x8936, + 0x8972, 0x4e1e, 0x4e58, 0x50e7, 0x52dd, 0x5347, 0x627f, 0x6607, + 0x7e69, 0x8805, 0x965e, 0x4f8d, 0x5319, 0x5636, 0x59cb, 0x5aa4, + 0x5c38, 0x5c4e, 0x5c4d, 0x5e02, 0x5f11, 0x6043, 0x65bd, 0x662f, + 0x6642, 0x67be, 0x67f4, 0x731c, 0x77e2, 0x793a, 0x7fc5, 0x8494, + 0x84cd, 0x8996, 0x8a66, 0x8a69, 0x8ae1, 0x8c55, 0x8c7a, 0x57f4, + 0x5bd4, 0x5f0f, 0x606f, 0x62ed, 0x690d, 0x6b96, 0x6e5c, 0x7184, + 0x7bd2, 0x8755, 0x8b58, 0x8efe, 0x98df, 0x98fe, 0x4f38, 0x4f81, + 0x4fe1, 0x547b, 0x5a20, 0x5bb8, 0x613c, 0x65b0, 0x6668, 0x71fc, + 0x7533, 0x795e, 0x7d33, 0x814e, 0x81e3, 0x8398, 0x85aa, 0x85ce, + 0x8703, 0x8a0a, 0x8eab, 0x8f9b, 0xf971, 0x8fc5, 0x5931, 0x5ba4, + 0x5be6, 0x6089, 0x5be9, 0x5c0b, 0x5fc3, 0x6c81, + /* 0x64 */ + 0xf972, 0x6df1, 0x700b, 0x751a, 0x82af, 0x8af6, 0x4ec0, 0x5341, + 0xf973, 0x96d9, 0x6c0f, 0x4e9e, 0x4fc4, 0x5152, 0x555e, 0x5a25, + 0x5ce8, 0x6211, 0x7259, 0x82bd, 0x83aa, 0x86fe, 0x8859, 0x8a1d, + 0x963f, 0x96c5, 0x9913, 0x9d09, 0x9d5d, 0x580a, 0x5cb3, 0x5dbd, + 0x5e44, 0x60e1, 0x6115, 0x63e1, 0x6a02, 0x6e25, 0x9102, 0x9354, + 0x984e, 0x9c10, 0x9f77, 0x5b89, 0x5cb8, 0x6309, 0x664f, 0x6848, + 0x773c, 0x96c1, 0x978d, 0x9854, 0x9b9f, 0x65a1, 0x8b01, 0x8ecb, + 0x95bc, 0x5535, 0x5ca9, 0x5dd6, 0x5eb5, 0x6697, 0x764c, 0x83f4, + 0x95c7, 0x58d3, 0x62bc, 0x72ce, 0x9d28, 0x4ef0, 0x592e, 0x600f, + 0x663b, 0x6b83, 0x79e7, 0x9d26, 0x5393, 0x54c0, 0x57c3, 0x5d16, + 0x611b, 0x66d6, 0x6daf, 0x788d, 0x827e, 0x9698, 0x9744, 0x5384, + 0x627c, 0x6396, 0x6db2, 0x7e0a, 0x814b, 0x984d, + /* 0x65 */ + 0x6afb, 0x7f4c, 0x9daf, 0x9e1a, 0x4e5f, 0x503b, 0x51b6, 0x591c, + 0x60f9, 0x63f6, 0x6930, 0x723a, 0x8036, 0xf974, 0x91ce, 0x5f31, + 0xf975, 0xf976, 0x7d04, 0x82e5, 0x846f, 0x84bb, 0x85e5, 0x8e8d, + 0xf977, 0x4f6f, 0xf978, 0xf979, 0x58e4, 0x5b43, 0x6059, 0x63da, + 0x6518, 0x656d, 0x6698, 0xf97a, 0x694a, 0x6a23, 0x6d0b, 0x7001, + 0x716c, 0x75d2, 0x760d, 0x79b3, 0x7a70, 0xf97b, 0x7f8a, 0xf97c, + 0x8944, 0xf97d, 0x8b93, 0x91c0, 0x967d, 0xf97e, 0x990a, 0x5704, + 0x5fa1, 0x65bc, 0x6f01, 0x7600, 0x79a6, 0x8a9e, 0x99ad, 0x9b5a, + 0x9f6c, 0x5104, 0x61b6, 0x6291, 0x6a8d, 0x81c6, 0x5043, 0x5830, + 0x5f66, 0x7109, 0x8a00, 0x8afa, 0x5b7c, 0x8616, 0x4ffa, 0x513c, + 0x56b4, 0x5944, 0x63a9, 0x6df9, 0x5daa, 0x696d, 0x5186, 0x4e88, + 0x4f59, 0xf97f, 0xf980, 0xf981, 0x5982, 0xf982, + /* 0x66 */ + 0xf983, 0x6b5f, 0x6c5d, 0xf984, 0x74b5, 0x7916, 0xf985, 0x8207, + 0x8245, 0x8339, 0x8f3f, 0x8f5d, 0xf986, 0x9918, 0xf987, 0xf988, + 0xf989, 0x4ea6, 0xf98a, 0x57df, 0x5f79, 0x6613, 0xf98b, 0xf98c, + 0x75ab, 0x7e79, 0x8b6f, 0xf98d, 0x9006, 0x9a5b, 0x56a5, 0x5827, + 0x59f8, 0x5a1f, 0x5bb4, 0xf98e, 0x5ef6, 0xf98f, 0xf990, 0x6350, + 0x633b, 0xf991, 0x693d, 0x6c87, 0x6cbf, 0x6d8e, 0x6d93, 0x6df5, + 0x6f14, 0xf992, 0x70df, 0x7136, 0x7159, 0xf993, 0x71c3, 0x71d5, + 0xf994, 0x784f, 0x786f, 0xf995, 0x7b75, 0x7de3, 0xf996, 0x7e2f, + 0xf997, 0x884d, 0x8edf, 0xf998, 0xf999, 0xf99a, 0x925b, 0xf99b, + 0x9cf6, 0xf99c, 0xf99d, 0xf99e, 0x6085, 0x6d85, 0xf99f, 0x71b1, + 0xf9a0, 0xf9a1, 0x95b1, 0x53ad, 0xf9a2, 0xf9a3, 0xf9a4, 0x67d3, + 0xf9a5, 0x708e, 0x7130, 0x7430, 0x8276, 0x82d2, + /* 0x67 */ + 0xf9a6, 0x95bb, 0x9ae5, 0x9e7d, 0x66c4, 0xf9a7, 0x71c1, 0x8449, + 0xf9a8, 0xf9a9, 0x584b, 0xf9aa, 0xf9ab, 0x5db8, 0x5f71, 0xf9ac, + 0x6620, 0x668e, 0x6979, 0x69ae, 0x6c38, 0x6cf3, 0x6e36, 0x6f41, + 0x6fda, 0x701b, 0x702f, 0x7150, 0x71df, 0x7370, 0xf9ad, 0x745b, + 0xf9ae, 0x74d4, 0x76c8, 0x7a4e, 0x7e93, 0xf9af, 0xf9b0, 0x82f1, + 0x8a60, 0x8fce, 0xf9b1, 0x9348, 0xf9b2, 0x9719, 0xf9b3, 0xf9b4, + 0x4e42, 0x502a, 0xf9b5, 0x5208, 0x53e1, 0x66f3, 0x6c6d, 0x6fca, + 0x730a, 0x777f, 0x7a62, 0x82ae, 0x85dd, 0x8602, 0xf9b6, 0x88d4, + 0x8a63, 0x8b7d, 0x8c6b, 0xf9b7, 0x92b3, 0xf9b8, 0x9713, 0x9810, + 0x4e94, 0x4f0d, 0x4fc9, 0x50b2, 0x5348, 0x543e, 0x5433, 0x55da, + 0x5862, 0x58ba, 0x5967, 0x5a1b, 0x5be4, 0x609f, 0xf9b9, 0x61ca, + 0x6556, 0x65ff, 0x6664, 0x68a7, 0x6c5a, 0x6fb3, + /* 0x68 */ + 0x70cf, 0x71ac, 0x7352, 0x7b7d, 0x8708, 0x8aa4, 0x9c32, 0x9f07, + 0x5c4b, 0x6c83, 0x7344, 0x7389, 0x923a, 0x6eab, 0x7465, 0x761f, + 0x7a69, 0x7e15, 0x860a, 0x5140, 0x58c5, 0x64c1, 0x74ee, 0x7515, + 0x7670, 0x7fc1, 0x9095, 0x96cd, 0x9954, 0x6e26, 0x74e6, 0x7aa9, + 0x7aaa, 0x81e5, 0x86d9, 0x8778, 0x8a1b, 0x5a49, 0x5b8c, 0x5b9b, + 0x68a1, 0x6900, 0x6d63, 0x73a9, 0x7413, 0x742c, 0x7897, 0x7de9, + 0x7feb, 0x8118, 0x8155, 0x839e, 0x8c4c, 0x962e, 0x9811, 0x66f0, + 0x5f80, 0x65fa, 0x6789, 0x6c6a, 0x738b, 0x502d, 0x5a03, 0x6b6a, + 0x77ee, 0x5916, 0x5d6c, 0x5dcd, 0x7325, 0x754f, 0xf9ba, 0xf9bb, + 0x50e5, 0x51f9, 0x582f, 0x592d, 0x5996, 0x59da, 0x5be5, 0xf9bc, + 0xf9bd, 0x5da2, 0x62d7, 0x6416, 0x6493, 0x64fe, 0xf9be, 0x66dc, + 0xf9bf, 0x6a48, 0xf9c0, 0x71ff, 0x7464, 0xf9c1, + /* 0x69 */ + 0x7a88, 0x7aaf, 0x7e47, 0x7e5e, 0x8000, 0x8170, 0xf9c2, 0x87ef, + 0x8981, 0x8b20, 0x9059, 0xf9c3, 0x9080, 0x9952, 0x617e, 0x6b32, + 0x6d74, 0x7e1f, 0x8925, 0x8fb1, 0x4fd1, 0x50ad, 0x5197, 0x52c7, + 0x57c7, 0x5889, 0x5bb9, 0x5eb8, 0x6142, 0x6995, 0x6d8c, 0x6e67, + 0x6eb6, 0x7194, 0x7462, 0x7528, 0x752c, 0x8073, 0x8338, 0x84c9, + 0x8e0a, 0x9394, 0x93de, 0xf9c4, 0x4e8e, 0x4f51, 0x5076, 0x512a, + 0x53c8, 0x53cb, 0x53f3, 0x5b87, 0x5bd3, 0x5c24, 0x611a, 0x6182, + 0x65f4, 0x725b, 0x7397, 0x7440, 0x76c2, 0x7950, 0x7991, 0x79b9, + 0x7d06, 0x7fbd, 0x828b, 0x85d5, 0x865e, 0x8fc2, 0x9047, 0x90f5, + 0x91ea, 0x9685, 0x96e8, 0x96e9, 0x52d6, 0x5f67, 0x65ed, 0x6631, + 0x682f, 0x715c, 0x7a36, 0x90c1, 0x980a, 0x4e91, 0xf9c5, 0x6a52, + 0x6b9e, 0x6f90, 0x7189, 0x8018, 0x82b8, 0x8553, + /* 0x6a */ + 0x904b, 0x9695, 0x96f2, 0x97fb, 0x851a, 0x9b31, 0x4e90, 0x718a, + 0x96c4, 0x5143, 0x539f, 0x54e1, 0x5713, 0x5712, 0x57a3, 0x5a9b, + 0x5ac4, 0x5bc3, 0x6028, 0x613f, 0x63f4, 0x6c85, 0x6d39, 0x6e72, + 0x6e90, 0x7230, 0x733f, 0x7457, 0x82d1, 0x8881, 0x8f45, 0x9060, + 0xf9c6, 0x9662, 0x9858, 0x9d1b, 0x6708, 0x8d8a, 0x925e, 0x4f4d, + 0x5049, 0x50de, 0x5371, 0x570d, 0x59d4, 0x5a01, 0x5c09, 0x6170, + 0x6690, 0x6e2d, 0x7232, 0x744b, 0x7def, 0x80c3, 0x840e, 0x8466, + 0x853f, 0x875f, 0x885b, 0x8918, 0x8b02, 0x9055, 0x97cb, 0x9b4f, + 0x4e73, 0x4f91, 0x5112, 0x516a, 0xf9c7, 0x552f, 0x55a9, 0x5b7a, + 0x5ba5, 0x5e7c, 0x5e7d, 0x5ebe, 0x60a0, 0x60df, 0x6108, 0x6109, + 0x63c4, 0x6538, 0x6709, 0xf9c8, 0x67d4, 0x67da, 0xf9c9, 0x6961, + 0x6962, 0x6cb9, 0x6d27, 0xf9ca, 0x6e38, 0xf9cb, + /* 0x6b */ + 0x6fe1, 0x7336, 0x7337, 0xf9cc, 0x745c, 0x7531, 0xf9cd, 0x7652, + 0xf9ce, 0xf9cf, 0x7dad, 0x81fe, 0x8438, 0x88d5, 0x8a98, 0x8adb, + 0x8aed, 0x8e30, 0x8e42, 0x904a, 0x903e, 0x907a, 0x9149, 0x91c9, + 0x936e, 0xf9d0, 0xf9d1, 0x5809, 0xf9d2, 0x6bd3, 0x8089, 0x80b2, + 0xf9d3, 0xf9d4, 0x5141, 0x596b, 0x5c39, 0xf9d5, 0xf9d6, 0x6f64, + 0x73a7, 0x80e4, 0x8d07, 0xf9d7, 0x9217, 0x958f, 0xf9d8, 0xf9d9, + 0xf9da, 0xf9db, 0x807f, 0x620e, 0x701c, 0x7d68, 0x878d, 0xf9dc, + 0x57a0, 0x6069, 0x6147, 0x6bb7, 0x8abe, 0x9280, 0x96b1, 0x4e59, + 0x541f, 0x6deb, 0x852d, 0x9670, 0x97f3, 0x98ee, 0x63d6, 0x6ce3, + 0x9091, 0x51dd, 0x61c9, 0x81ba, 0x9df9, 0x4f9d, 0x501a, 0x5100, + 0x5b9c, 0x610f, 0x61ff, 0x64ec, 0x6905, 0x6bc5, 0x7591, 0x77e3, + 0x7fa9, 0x8264, 0x858f, 0x87fb, 0x8863, 0x8abc, + /* 0x6c */ + 0x8b70, 0x91ab, 0x4e8c, 0x4ee5, 0x4f0a, 0xf9dd, 0xf9de, 0x5937, + 0x59e8, 0xf9df, 0x5df2, 0x5f1b, 0x5f5b, 0x6021, 0xf9e0, 0xf9e1, + 0xf9e2, 0xf9e3, 0x723e, 0x73e5, 0xf9e4, 0x7570, 0x75cd, 0xf9e5, + 0x79fb, 0xf9e6, 0x800c, 0x8033, 0x8084, 0x82e1, 0x8351, 0xf9e7, + 0xf9e8, 0x8cbd, 0x8cb3, 0x9087, 0xf9e9, 0xf9ea, 0x98f4, 0x990c, + 0xf9eb, 0xf9ec, 0x7037, 0x76ca, 0x7fca, 0x7fcc, 0x7ffc, 0x8b1a, + 0x4eba, 0x4ec1, 0x5203, 0x5370, 0xf9ed, 0x54bd, 0x56e0, 0x59fb, + 0x5bc5, 0x5f15, 0x5fcd, 0x6e6e, 0xf9ee, 0xf9ef, 0x7d6a, 0x8335, + 0xf9f0, 0x8693, 0x8a8d, 0xf9f1, 0x976d, 0x9777, 0xf9f2, 0xf9f3, + 0x4e00, 0x4f5a, 0x4f7e, 0x58f9, 0x65e5, 0x6ea2, 0x9038, 0x93b0, + 0x99b9, 0x4efb, 0x58ec, 0x598a, 0x59d9, 0x6041, 0xf9f4, 0xf9f5, + 0x7a14, 0xf9f6, 0x834f, 0x8cc3, 0x5165, 0x5344, + /* 0x6d */ + 0xf9f7, 0xf9f8, 0xf9f9, 0x4ecd, 0x5269, 0x5b55, 0x82bf, 0x4ed4, + 0x523a, 0x54a8, 0x59c9, 0x59ff, 0x5b50, 0x5b57, 0x5b5c, 0x6063, + 0x6148, 0x6ecb, 0x7099, 0x716e, 0x7386, 0x74f7, 0x75b5, 0x78c1, + 0x7d2b, 0x8005, 0x81ea, 0x8328, 0x8517, 0x85c9, 0x8aee, 0x8cc7, + 0x96cc, 0x4f5c, 0x52fa, 0x56bc, 0x65ab, 0x6628, 0x707c, 0x70b8, + 0x7235, 0x7dbd, 0x828d, 0x914c, 0x96c0, 0x9d72, 0x5b71, 0x68e7, + 0x6b98, 0x6f7a, 0x76de, 0x5c91, 0x66ab, 0x6f5b, 0x7bb4, 0x7c2a, + 0x8836, 0x96dc, 0x4e08, 0x4ed7, 0x5320, 0x5834, 0x58bb, 0x58ef, + 0x596c, 0x5c07, 0x5e33, 0x5e84, 0x5f35, 0x638c, 0x66b2, 0x6756, + 0x6a1f, 0x6aa3, 0x6b0c, 0x6f3f, 0x7246, 0xf9fa, 0x7350, 0x748b, + 0x7ae0, 0x7ca7, 0x8178, 0x81df, 0x81e7, 0x838a, 0x846c, 0x8523, + 0x8594, 0x85cf, 0x88dd, 0x8d13, 0x91ac, 0x9577, + /* 0x6e */ + 0x969c, 0x518d, 0x54c9, 0x5728, 0x5bb0, 0x624d, 0x6750, 0x683d, + 0x6893, 0x6e3d, 0x6ed3, 0x707d, 0x7e21, 0x88c1, 0x8ca1, 0x8f09, + 0x9f4b, 0x9f4e, 0x722d, 0x7b8f, 0x8acd, 0x931a, 0x4f47, 0x4f4e, + 0x5132, 0x5480, 0x59d0, 0x5e95, 0x62b5, 0x6775, 0x696e, 0x6a17, + 0x6cae, 0x6e1a, 0x72d9, 0x732a, 0x75bd, 0x7bb8, 0x7d35, 0x82e7, + 0x83f9, 0x8457, 0x85f7, 0x8a5b, 0x8caf, 0x8e87, 0x9019, 0x90b8, + 0x96ce, 0x9f5f, 0x52e3, 0x540a, 0x5ae1, 0x5bc2, 0x6458, 0x6575, + 0x6ef4, 0x72c4, 0xf9fb, 0x7684, 0x7a4d, 0x7b1b, 0x7c4d, 0x7e3e, + 0x7fdf, 0x837b, 0x8b2b, 0x8cca, 0x8d64, 0x8de1, 0x8e5f, 0x8fea, + 0x8ff9, 0x9069, 0x93d1, 0x4f43, 0x4f7a, 0x50b3, 0x5168, 0x5178, + 0x524d, 0x526a, 0x5861, 0x587c, 0x5960, 0x5c08, 0x5c55, 0x5edb, + 0x609b, 0x6230, 0x6813, 0x6bbf, 0x6c08, 0x6fb1, + /* 0x6f */ + 0x714e, 0x7420, 0x7530, 0x7538, 0x7551, 0x7672, 0x7b4c, 0x7b8b, + 0x7bad, 0x7bc6, 0x7e8f, 0x8a6e, 0x8f3e, 0x8f49, 0x923f, 0x9293, + 0x9322, 0x942b, 0x96fb, 0x985a, 0x986b, 0x991e, 0x5207, 0x622a, + 0x6298, 0x6d59, 0x7664, 0x7aca, 0x7bc0, 0x7d76, 0x5360, 0x5cbe, + 0x5e97, 0x6f38, 0x70b9, 0x7c98, 0x9711, 0x9b8e, 0x9ede, 0x63a5, + 0x647a, 0x8776, 0x4e01, 0x4e95, 0x4ead, 0x505c, 0x5075, 0x5448, + 0x59c3, 0x5b9a, 0x5e40, 0x5ead, 0x5ef7, 0x5f81, 0x60c5, 0x633a, + 0x653f, 0x6574, 0x65cc, 0x6676, 0x6678, 0x67fe, 0x6968, 0x6a89, + 0x6b63, 0x6c40, 0x6dc0, 0x6de8, 0x6e1f, 0x6e5e, 0x701e, 0x70a1, + 0x738e, 0x73fd, 0x753a, 0x775b, 0x7887, 0x798e, 0x7a0b, 0x7a7d, + 0x7cbe, 0x7d8e, 0x8247, 0x8a02, 0x8aea, 0x8c9e, 0x912d, 0x914a, + 0x91d8, 0x9266, 0x92cc, 0x9320, 0x9706, 0x9756, + /* 0x70 */ + 0x975c, 0x9802, 0x9f0e, 0x5236, 0x5291, 0x557c, 0x5824, 0x5e1d, + 0x5f1f, 0x608c, 0x63d0, 0x68af, 0x6fdf, 0x796d, 0x7b2c, 0x81cd, + 0x85ba, 0x88fd, 0x8af8, 0x8e44, 0x918d, 0x9664, 0x969b, 0x973d, + 0x984c, 0x9f4a, 0x4fce, 0x5146, 0x51cb, 0x52a9, 0x5632, 0x5f14, + 0x5f6b, 0x63aa, 0x64cd, 0x65e9, 0x6641, 0x66fa, 0x66f9, 0x671d, + 0x689d, 0x68d7, 0x69fd, 0x6f15, 0x6f6e, 0x7167, 0x71e5, 0x722a, + 0x74aa, 0x773a, 0x7956, 0x795a, 0x79df, 0x7a20, 0x7a95, 0x7c97, + 0x7cdf, 0x7d44, 0x7e70, 0x8087, 0x85fb, 0x86a4, 0x8a54, 0x8abf, + 0x8d99, 0x8e81, 0x9020, 0x906d, 0x91e3, 0x963b, 0x96d5, 0x9ce5, + 0x65cf, 0x7c07, 0x8db3, 0x93c3, 0x5b58, 0x5c0a, 0x5352, 0x62d9, + 0x731d, 0x5027, 0x5b97, 0x5f9e, 0x60b0, 0x616b, 0x68d5, 0x6dd9, + 0x742e, 0x7a2e, 0x7d42, 0x7d9c, 0x7e31, 0x816b, + /* 0x71 */ + 0x8e2a, 0x8e35, 0x937e, 0x9418, 0x4f50, 0x5750, 0x5de6, 0x5ea7, + 0x632b, 0x7f6a, 0x4e3b, 0x4f4f, 0x4f8f, 0x505a, 0x59dd, 0x80c4, + 0x546a, 0x5468, 0x55fe, 0x594f, 0x5b99, 0x5dde, 0x5eda, 0x665d, + 0x6731, 0x67f1, 0x682a, 0x6ce8, 0x6d32, 0x6e4a, 0x6f8d, 0x70b7, + 0x73e0, 0x7587, 0x7c4c, 0x7d02, 0x7d2c, 0x7da2, 0x821f, 0x86db, + 0x8a3b, 0x8a85, 0x8d70, 0x8e8a, 0x8f33, 0x9031, 0x914e, 0x9152, + 0x9444, 0x99d0, 0x7af9, 0x7ca5, 0x4fca, 0x5101, 0x51c6, 0x57c8, + 0x5bef, 0x5cfb, 0x6659, 0x6a3d, 0x6d5a, 0x6e96, 0x6fec, 0x710c, + 0x756f, 0x7ae3, 0x8822, 0x9021, 0x9075, 0x96cb, 0x99ff, 0x8301, + 0x4e2d, 0x4ef2, 0x8846, 0x91cd, 0x537d, 0x6adb, 0x696b, 0x6c41, + 0x847a, 0x589e, 0x618e, 0x66fe, 0x62ef, 0x70dd, 0x7511, 0x75c7, + 0x7e52, 0x84b8, 0x8b49, 0x8d08, 0x4e4b, 0x53ea, + /* 0x72 */ + 0x54ab, 0x5730, 0x5740, 0x5fd7, 0x6301, 0x6307, 0x646f, 0x652f, + 0x65e8, 0x667a, 0x679d, 0x67b3, 0x6b62, 0x6c60, 0x6c9a, 0x6f2c, + 0x77e5, 0x7825, 0x7949, 0x7957, 0x7d19, 0x80a2, 0x8102, 0x81f3, + 0x829d, 0x82b7, 0x8718, 0x8a8c, 0xf9fc, 0x8d04, 0x8dbe, 0x9072, + 0x76f4, 0x7a19, 0x7a37, 0x7e54, 0x8077, 0x5507, 0x55d4, 0x5875, + 0x632f, 0x6422, 0x6649, 0x664b, 0x686d, 0x699b, 0x6b84, 0x6d25, + 0x6eb1, 0x73cd, 0x7468, 0x74a1, 0x755b, 0x75b9, 0x76e1, 0x771e, + 0x778b, 0x79e6, 0x7e09, 0x7e1d, 0x81fb, 0x852f, 0x8897, 0x8a3a, + 0x8cd1, 0x8eeb, 0x8fb0, 0x9032, 0x93ad, 0x9663, 0x9673, 0x9707, + 0x4f84, 0x53f1, 0x59ea, 0x5ac9, 0x5e19, 0x684e, 0x74c6, 0x75be, + 0x79e9, 0x7a92, 0x81a3, 0x86ed, 0x8cea, 0x8dcc, 0x8fed, 0x659f, + 0x6715, 0xf9fd, 0x57f7, 0x6f57, 0x7ddd, 0x8f2f, + /* 0x73 */ + 0x93f6, 0x96c6, 0x5fb5, 0x61f2, 0x6f84, 0x4e14, 0x4f98, 0x501f, + 0x53c9, 0x55df, 0x5d6f, 0x5dee, 0x6b21, 0x6b64, 0x78cb, 0x7b9a, + 0xf9fe, 0x8e49, 0x8eca, 0x906e, 0x6349, 0x643e, 0x7740, 0x7a84, + 0x932f, 0x947f, 0x9f6a, 0x64b0, 0x6faf, 0x71e6, 0x74a8, 0x74da, + 0x7ac4, 0x7c12, 0x7e82, 0x7cb2, 0x7e98, 0x8b9a, 0x8d0a, 0x947d, + 0x9910, 0x994c, 0x5239, 0x5bdf, 0x64e6, 0x672d, 0x7d2e, 0x50ed, + 0x53c3, 0x5879, 0x6158, 0x6159, 0x61fa, 0x65ac, 0x7ad9, 0x8b92, + 0x8b96, 0x5009, 0x5021, 0x5275, 0x5531, 0x5a3c, 0x5ee0, 0x5f70, + 0x6134, 0x655e, 0x660c, 0x6636, 0x66a2, 0x69cd, 0x6ec4, 0x6f32, + 0x7316, 0x7621, 0x7a93, 0x8139, 0x8259, 0x83d6, 0x84bc, 0x50b5, + 0x57f0, 0x5bc0, 0x5be8, 0x5f69, 0x63a1, 0x7826, 0x7db5, 0x83dc, + 0x8521, 0x91c7, 0x91f5, 0x518a, 0x67f5, 0x7b56, + /* 0x74 */ + 0x8cac, 0x51c4, 0x59bb, 0x60bd, 0x8655, 0x501c, 0xf9ff, 0x5254, + 0x5c3a, 0x617d, 0x621a, 0x62d3, 0x64f2, 0x65a5, 0x6ecc, 0x7620, + 0x810a, 0x8e60, 0x965f, 0x96bb, 0x4edf, 0x5343, 0x5598, 0x5929, + 0x5ddd, 0x64c5, 0x6cc9, 0x6dfa, 0x7394, 0x7a7f, 0x821b, 0x85a6, + 0x8ce4, 0x8e10, 0x9077, 0x91e7, 0x95e1, 0x9621, 0x97c6, 0x51f8, + 0x54f2, 0x5586, 0x5fb9, 0x64a4, 0x6f88, 0x7db4, 0x8f1f, 0x8f4d, + 0x9435, 0x50c9, 0x5c16, 0x6cbe, 0x6dfb, 0x751b, 0x77bb, 0x7c3d, + 0x7c64, 0x8a79, 0x8ac2, 0x581e, 0x59be, 0x5e16, 0x6377, 0x7252, + 0x758a, 0x776b, 0x8adc, 0x8cbc, 0x8f12, 0x5ef3, 0x6674, 0x6df8, + 0x807d, 0x83c1, 0x8acb, 0x9751, 0x9bd6, 0xfa00, 0x5243, 0x66ff, + 0x6d95, 0x6eef, 0x7de0, 0x8ae6, 0x902e, 0x905e, 0x9ad4, 0x521d, + 0x527f, 0x54e8, 0x6194, 0x6284, 0x62db, 0x68a2, + /* 0x75 */ + 0x6912, 0x695a, 0x6a35, 0x7092, 0x7126, 0x785d, 0x7901, 0x790e, + 0x79d2, 0x7a0d, 0x8096, 0x8278, 0x82d5, 0x8349, 0x8549, 0x8c82, + 0x8d85, 0x9162, 0x918b, 0x91ae, 0x4fc3, 0x56d1, 0x71ed, 0x77d7, + 0x8700, 0x89f8, 0x5bf8, 0x5fd6, 0x6751, 0x90a8, 0x53e2, 0x585a, + 0x5bf5, 0x60a4, 0x6181, 0x6460, 0x7e3d, 0x8070, 0x8525, 0x9283, + 0x64ae, 0x50ac, 0x5d14, 0x6700, 0x589c, 0x62bd, 0x63a8, 0x690e, + 0x6978, 0x6a1e, 0x6e6b, 0x76ba, 0x79cb, 0x82bb, 0x8429, 0x8acf, + 0x8da8, 0x8ffd, 0x9112, 0x914b, 0x919c, 0x9310, 0x9318, 0x939a, + 0x96db, 0x9a36, 0x9c0d, 0x4e11, 0x755c, 0x795d, 0x7afa, 0x7b51, + 0x7bc9, 0x7e2e, 0x84c4, 0x8e59, 0x8e74, 0x8ef8, 0x9010, 0x6625, + 0x693f, 0x7443, 0x51fa, 0x672e, 0x9edc, 0x5145, 0x5fe0, 0x6c96, + 0x87f2, 0x885d, 0x8877, 0x60b4, 0x81b5, 0x8403, + /* 0x76 */ + 0x8d05, 0x53d6, 0x5439, 0x5634, 0x5a36, 0x5c31, 0x708a, 0x7fe0, + 0x805a, 0x8106, 0x81ed, 0x8da3, 0x9189, 0x9a5f, 0x9df2, 0x5074, + 0x4ec4, 0x53a0, 0x60fb, 0x6e2c, 0x5c64, 0x4f88, 0x5024, 0x55e4, + 0x5cd9, 0x5e5f, 0x6065, 0x6894, 0x6cbb, 0x6dc4, 0x71be, 0x75d4, + 0x75f4, 0x7661, 0x7a1a, 0x7a49, 0x7dc7, 0x7dfb, 0x7f6e, 0x81f4, + 0x86a9, 0x8f1c, 0x96c9, 0x99b3, 0x9f52, 0x5247, 0x52c5, 0x98ed, + 0x89aa, 0x4e03, 0x67d2, 0x6f06, 0x4fb5, 0x5be2, 0x6795, 0x6c88, + 0x6d78, 0x741b, 0x7827, 0x91dd, 0x937c, 0x87c4, 0x79e4, 0x7a31, + 0x5feb, 0x4ed6, 0x54a4, 0x553e, 0x58ae, 0x59a5, 0x60f0, 0x6253, + 0x62d6, 0x6736, 0x6955, 0x8235, 0x9640, 0x99b1, 0x99dd, 0x502c, + 0x5353, 0x5544, 0x577c, 0xfa01, 0x6258, 0xfa02, 0x64e2, 0x666b, + 0x67dd, 0x6fc1, 0x6fef, 0x7422, 0x7438, 0x8a17, + /* 0x77 */ + 0x9438, 0x5451, 0x5606, 0x5766, 0x5f48, 0x619a, 0x6b4e, 0x7058, + 0x70ad, 0x7dbb, 0x8a95, 0x596a, 0x812b, 0x63a2, 0x7708, 0x803d, + 0x8caa, 0x5854, 0x642d, 0x69bb, 0x5b95, 0x5e11, 0x6e6f, 0xfa03, + 0x8569, 0x514c, 0x53f0, 0x592a, 0x6020, 0x614b, 0x6b86, 0x6c70, + 0x6cf0, 0x7b1e, 0x80ce, 0x82d4, 0x8dc6, 0x90b0, 0x98b1, 0xfa04, + 0x64c7, 0x6fa4, 0x6491, 0x6504, 0x514e, 0x5410, 0x571f, 0x8a0e, + 0x615f, 0x6876, 0xfa05, 0x75db, 0x7b52, 0x7d71, 0x901a, 0x5806, + 0x69cc, 0x817f, 0x892a, 0x9000, 0x9839, 0x5078, 0x5957, 0x59ac, + 0x6295, 0x900f, 0x9b2a, 0x615d, 0x7279, 0x95d6, 0x5761, 0x5a46, + 0x5df4, 0x628a, 0x64ad, 0x64fa, 0x6777, 0x6ce2, 0x6d3e, 0x722c, + 0x7436, 0x7834, 0x7f77, 0x82ad, 0x8ddb, 0x9817, 0x5224, 0x5742, + 0x677f, 0x7248, 0x74e3, 0x8ca9, 0x8fa6, 0x9211, + /* 0x78 */ + 0x962a, 0x516b, 0x53ed, 0x634c, 0x4f69, 0x5504, 0x6096, 0x6557, + 0x6c9b, 0x6d7f, 0x724c, 0x72fd, 0x7a17, 0x8987, 0x8c9d, 0x5f6d, + 0x6f8e, 0x70f9, 0x81a8, 0x610e, 0x4fbf, 0x504f, 0x6241, 0x7247, + 0x7bc7, 0x7de8, 0x7fe9, 0x904d, 0x97ad, 0x9a19, 0x8cb6, 0x576a, + 0x5e73, 0x67b0, 0x840d, 0x8a55, 0x5420, 0x5b16, 0x5e63, 0x5ee2, + 0x5f0a, 0x6583, 0x80ba, 0x853d, 0x9589, 0x965b, 0x4f48, 0x5305, + 0x530d, 0x530f, 0x5486, 0x54fa, 0x5703, 0x5e03, 0x6016, 0x629b, + 0x62b1, 0x6355, 0xfa06, 0x6ce1, 0x6d66, 0x75b1, 0x7832, 0x80de, + 0x812f, 0x82de, 0x8461, 0x84b2, 0x888d, 0x8912, 0x900b, 0x92ea, + 0x98fd, 0x9b91, 0x5e45, 0x66b4, 0x66dd, 0x7011, 0x7206, 0xfa07, + 0x4ff5, 0x527d, 0x5f6a, 0x6153, 0x6753, 0x6a19, 0x6f02, 0x74e2, + 0x7968, 0x8868, 0x8c79, 0x98c7, 0x98c4, 0x9a43, + /* 0x79 */ + 0x54c1, 0x7a1f, 0x6953, 0x8af7, 0x8c4a, 0x98a8, 0x99ae, 0x5f7c, + 0x62ab, 0x75b2, 0x76ae, 0x88ab, 0x907f, 0x9642, 0x5339, 0x5f3c, + 0x5fc5, 0x6ccc, 0x73cc, 0x7562, 0x758b, 0x7b46, 0x82fe, 0x999d, + 0x4e4f, 0x903c, 0x4e0b, 0x4f55, 0x53a6, 0x590f, 0x5ec8, 0x6630, + 0x6cb3, 0x7455, 0x8377, 0x8766, 0x8cc0, 0x9050, 0x971e, 0x9c15, + 0x58d1, 0x5b78, 0x8650, 0x8b14, 0x9db4, 0x5bd2, 0x6068, 0x608d, + 0x65f1, 0x6c57, 0x6f22, 0x6fa3, 0x701a, 0x7f55, 0x7ff0, 0x9591, + 0x9592, 0x9650, 0x97d3, 0x5272, 0x8f44, 0x51fd, 0x542b, 0x54b8, + 0x5563, 0x558a, 0x6abb, 0x6db5, 0x7dd8, 0x8266, 0x929c, 0x9677, + 0x9e79, 0x5408, 0x54c8, 0x76d2, 0x86e4, 0x95a4, 0x95d4, 0x965c, + 0x4ea2, 0x4f09, 0x59ee, 0x5ae6, 0x5df7, 0x6052, 0x6297, 0x676d, + 0x6841, 0x6c86, 0x6e2f, 0x7f38, 0x809b, 0x822a, + /* 0x7a */ + 0xfa08, 0xfa09, 0x9805, 0x4ea5, 0x5055, 0x54b3, 0x5793, 0x595a, + 0x5b69, 0x5bb3, 0x61c8, 0x6977, 0x6d77, 0x7023, 0x87f9, 0x89e3, + 0x8a72, 0x8ae7, 0x9082, 0x99ed, 0x9ab8, 0x52be, 0x6838, 0x5016, + 0x5e78, 0x674f, 0x8347, 0x884c, 0x4eab, 0x5411, 0x56ae, 0x73e6, + 0x9115, 0x97ff, 0x9909, 0x9957, 0x9999, 0x5653, 0x589f, 0x865b, + 0x8a31, 0x61b2, 0x6af6, 0x737b, 0x8ed2, 0x6b47, 0x96aa, 0x9a57, + 0x5955, 0x7200, 0x8d6b, 0x9769, 0x4fd4, 0x5cf4, 0x5f26, 0x61f8, + 0x665b, 0x6ceb, 0x70ab, 0x7384, 0x73b9, 0x73fe, 0x7729, 0x774d, + 0x7d43, 0x7d62, 0x7e23, 0x8237, 0x8852, 0xfa0a, 0x8ce2, 0x9249, + 0x986f, 0x5b51, 0x7a74, 0x8840, 0x9801, 0x5acc, 0x4fe0, 0x5354, + 0x593e, 0x5cfd, 0x633e, 0x6d79, 0x72f9, 0x8105, 0x8107, 0x83a2, + 0x92cf, 0x9830, 0x4ea8, 0x5144, 0x5211, 0x578b, + /* 0x7b */ + 0x5f62, 0x6cc2, 0x6ece, 0x7005, 0x7050, 0x70af, 0x7192, 0x73e9, + 0x7469, 0x834a, 0x87a2, 0x8861, 0x9008, 0x90a2, 0x93a3, 0x99a8, + 0x516e, 0x5f57, 0x60e0, 0x6167, 0x66b3, 0x8559, 0x8e4a, 0x91af, + 0x978b, 0x4e4e, 0x4e92, 0x547c, 0x58d5, 0x58fa, 0x597d, 0x5cb5, + 0x5f27, 0x6236, 0x6248, 0x660a, 0x6667, 0x6beb, 0x6d69, 0x6dcf, + 0x6e56, 0x6ef8, 0x6f94, 0x6fe0, 0x6fe9, 0x705d, 0x72d0, 0x7425, + 0x745a, 0x74e0, 0x7693, 0x795c, 0x7cca, 0x7e1e, 0x80e1, 0x82a6, + 0x846b, 0x84bf, 0x864e, 0x865f, 0x8774, 0x8b77, 0x8c6a, 0x93ac, + 0x9800, 0x9865, 0x60d1, 0x6216, 0x9177, 0x5a5a, 0x660f, 0x6df7, + 0x6e3e, 0x743f, 0x9b42, 0x5ffd, 0x60da, 0x7b0f, 0x54c4, 0x5f18, + 0x6c5e, 0x6cd3, 0x6d2a, 0x70d8, 0x7d05, 0x8679, 0x8a0c, 0x9d3b, + 0x5316, 0x548c, 0x5b05, 0x6a3a, 0x706b, 0x7575, + /* 0x7c */ + 0x798d, 0x79be, 0x82b1, 0x83ef, 0x8a71, 0x8b41, 0x8ca8, 0x9774, + 0xfa0b, 0x64f4, 0x652b, 0x78ba, 0x78bb, 0x7a6b, 0x4e38, 0x559a, + 0x5950, 0x5ba6, 0x5e7b, 0x60a3, 0x63db, 0x6b61, 0x6665, 0x6853, + 0x6e19, 0x7165, 0x74b0, 0x7d08, 0x9084, 0x9a69, 0x9c25, 0x6d3b, + 0x6ed1, 0x733e, 0x8c41, 0x95ca, 0x51f0, 0x5e4c, 0x5fa8, 0x604d, + 0x60f6, 0x6130, 0x614c, 0x6643, 0x6644, 0x69a5, 0x6cc1, 0x6e5f, + 0x6ec9, 0x6f62, 0x714c, 0x749c, 0x7687, 0x7bc1, 0x7c27, 0x8352, + 0x8757, 0x9051, 0x968d, 0x9ec3, 0x532f, 0x56de, 0x5efb, 0x5f8a, + 0x6062, 0x6094, 0x61f7, 0x6666, 0x6703, 0x6a9c, 0x6dee, 0x6fae, + 0x7070, 0x736a, 0x7e6a, 0x81be, 0x8334, 0x86d4, 0x8aa8, 0x8cc4, + 0x5283, 0x7372, 0x5b96, 0x6a6b, 0x9404, 0x54ee, 0x5686, 0x5b5d, + 0x6548, 0x6585, 0x66c9, 0x689f, 0x6d8d, 0x6dc6, + /* 0x7d */ + 0x723b, 0x80b4, 0x9175, 0x9a4d, 0x4faf, 0x5019, 0x539a, 0x540e, + 0x543c, 0x5589, 0x55c5, 0x5e3f, 0x5f8c, 0x673d, 0x7166, 0x73dd, + 0x9005, 0x52db, 0x52f3, 0x5864, 0x58ce, 0x7104, 0x718f, 0x71fb, + 0x85b0, 0x8a13, 0x6688, 0x85a8, 0x55a7, 0x6684, 0x714a, 0x8431, + 0x5349, 0x5599, 0x6bc1, 0x5f59, 0x5fbd, 0x63ee, 0x6689, 0x7147, + 0x8af1, 0x8f1d, 0x9ebe, 0x4f11, 0x643a, 0x70cb, 0x7566, 0x8667, + 0x6064, 0x8b4e, 0x9df8, 0x5147, 0x51f6, 0x5308, 0x6d36, 0x80f8, + 0x9ed1, 0x6615, 0x6b23, 0x7098, 0x75d5, 0x5403, 0x5c79, 0x7d07, + 0x8a16, 0x6b20, 0x6b3d, 0x6b46, 0x5438, 0x6070, 0x6d3d, 0x7fd5, + 0x8208, 0x50d6, 0x51de, 0x559c, 0x566b, 0x56cd, 0x59ec, 0x5b09, + 0x5e0c, 0x6199, 0x6198, 0x6231, 0x665e, 0x66e6, 0x7199, 0x71b9, + 0x71ba, 0x72a7, 0x79a7, 0x7a00, 0x7fb2, 0x8a70, +}; + +static int +ksc5601_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x21 && c1 <= 0x2c) || (c1 >= 0x30 && c1 <= 0x48) || (c1 >= 0x4a && c1 <= 0x7d)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if (c2 >= 0x21 && c2 < 0x7f) { + unsigned int i = 94 * (c1 - 0x21) + (c2 - 0x21); + unsigned short wc = 0xfffd; + if (i < 1410) { + if (i < 1115) + wc = ksc5601_2uni_page21[i]; + } else if (i < 3854) { + if (i < 3760) + wc = ksc5601_2uni_page30[i-1410]; + } else { + if (i < 8742) + wc = ksc5601_2uni_page4a[i-3854]; + } + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short ksc5601_2charset[8227] = { + 0x222e, 0x2234, 0x2157, 0x2127, 0x2823, 0x2129, 0x2267, 0x2146, + 0x213e, 0x2977, 0x2978, 0x2225, 0x2252, 0x2124, 0x222c, 0x2976, + 0x282c, 0x2879, 0x2876, 0x287a, 0x222f, 0x2821, 0x2822, 0x213f, + 0x282a, 0x282d, 0x292c, 0x2921, 0x2923, 0x2140, 0x292a, 0x292d, + 0x2922, 0x2824, 0x2924, 0x2925, 0x2826, 0x2926, 0x2927, 0x2828, + 0x2928, 0x2829, 0x2929, 0x2930, 0x282f, 0x292f, 0x282b, 0x292b, + 0x282e, 0x292e, 0x2227, 0x2230, 0x2228, 0x222b, 0x222a, 0x222d, + 0x2229, 0x2541, 0x2542, 0x2543, 0x2544, 0x2545, 0x2546, 0x2547, + 0x2548, 0x2549, 0x254a, 0x254b, 0x254c, 0x254d, 0x254e, 0x254f, + 0x2550, 0x2551, 0x2552, 0x2553, 0x2554, 0x2555, 0x2556, 0x2557, + 0x2558, 0x2561, 0x2562, 0x2563, 0x2564, 0x2565, 0x2566, 0x2567, + 0x2568, 0x2569, 0x256a, 0x256b, 0x256c, 0x256d, 0x256e, 0x256f, + 0x2570, 0x2571, 0x2572, 0x2573, 0x2574, 0x2575, 0x2576, 0x2577, + 0x2578, 0x2c27, 0x2c21, 0x2c22, 0x2c23, 0x2c24, 0x2c25, 0x2c26, + 0x2c28, 0x2c29, 0x2c2a, 0x2c2b, 0x2c2c, 0x2c2d, 0x2c2e, 0x2c2f, + 0x2c30, 0x2c31, 0x2c32, 0x2c33, 0x2c34, 0x2c35, 0x2c36, 0x2c37, + 0x2c38, 0x2c39, 0x2c3a, 0x2c3b, 0x2c3c, 0x2c3d, 0x2c3e, 0x2c3f, + 0x2c40, 0x2c41, 0x2c51, 0x2c52, 0x2c53, 0x2c54, 0x2c55, 0x2c56, + 0x2c58, 0x2c59, 0x2c5a, 0x2c5b, 0x2c5c, 0x2c5d, 0x2c5e, 0x2c5f, + 0x2c60, 0x2c61, 0x2c62, 0x2c63, 0x2c64, 0x2c65, 0x2c66, 0x2c67, + 0x2c68, 0x2c69, 0x2c6a, 0x2c6b, 0x2c6c, 0x2c6d, 0x2c6e, 0x2c6f, + 0x2c70, 0x2c71, 0x2c57, 0x212a, 0x212e, 0x212f, 0x2130, 0x2131, + 0x2253, 0x2254, 0x2125, 0x2126, 0x2236, 0x2147, 0x2148, 0x2158, + 0x2979, 0x297a, 0x297b, 0x297c, 0x297d, 0x297e, 0x2266, 0x2149, + 0x2235, 0x2724, 0x2260, 0x2265, 0x2262, 0x2759, 0x214a, 0x2877, + 0x2878, 0x287b, 0x287c, 0x287d, 0x287e, 0x2530, 0x2531, 0x2532, + 0x2533, 0x2534, 0x2535, 0x2536, 0x2537, 0x2538, 0x2539, 0x2521, + 0x2522, 0x2523, 0x2524, 0x2525, 0x2526, 0x2527, 0x2528, 0x2529, + 0x252a, 0x2167, 0x2168, 0x2166, 0x2169, 0x216a, 0x2255, 0x2258, + 0x2256, 0x2259, 0x2257, 0x2221, 0x2222, 0x2223, 0x2153, 0x2224, + 0x2154, 0x2174, 0x2175, 0x2233, 0x2232, 0x216e, 0x2170, 0x2144, + 0x2150, 0x212b, 0x217c, 0x217d, 0x217b, 0x217a, 0x2172, 0x2173, + 0x2231, 0x2145, 0x2171, 0x212d, 0x216f, 0x2156, 0x2141, 0x2155, + 0x2142, 0x2143, 0x216c, 0x216d, 0x2178, 0x2179, 0x2176, 0x2177, + 0x2241, 0x2151, 0x2152, 0x2867, 0x2868, 0x2869, 0x286a, 0x286b, + 0x286c, 0x286d, 0x286e, 0x286f, 0x2870, 0x2871, 0x2872, 0x2873, + 0x2874, 0x2875, 0x2967, 0x2968, 0x2969, 0x296a, 0x296b, 0x296c, + 0x296d, 0x296e, 0x296f, 0x2970, 0x2971, 0x2972, 0x2973, 0x2974, + 0x2975, 0x294d, 0x294e, 0x294f, 0x2950, 0x2951, 0x2952, 0x2953, + 0x2954, 0x2955, 0x2956, 0x2957, 0x2958, 0x2959, 0x295a, 0x295b, + 0x295c, 0x295d, 0x295e, 0x295f, 0x2960, 0x2961, 0x2962, 0x2963, + 0x2964, 0x2965, 0x2966, 0x284d, 0x284e, 0x284f, 0x2850, 0x2851, + 0x2852, 0x2853, 0x2854, 0x2855, 0x2856, 0x2857, 0x2858, 0x2859, + 0x285a, 0x285b, 0x285c, 0x285d, 0x285e, 0x285f, 0x2860, 0x2861, + 0x2862, 0x2863, 0x2864, 0x2865, 0x2866, 0x2621, 0x262c, 0x2622, + 0x262d, 0x2623, 0x2648, 0x2647, 0x262e, 0x2624, 0x2642, 0x2641, + 0x262f, 0x2626, 0x2646, 0x2645, 0x2631, 0x2625, 0x2644, 0x2643, + 0x2630, 0x2627, 0x263c, 0x2649, 0x264a, 0x2637, 0x264b, 0x264c, + 0x2632, 0x2629, 0x263e, 0x264d, 0x264e, 0x2639, 0x264f, 0x2650, + 0x2634, 0x2628, 0x2651, 0x2652, 0x2638, 0x263d, 0x2653, 0x2654, + 0x2633, 0x262a, 0x2655, 0x2656, 0x263a, 0x263f, 0x2657, 0x2658, + 0x2635, 0x262b, 0x2659, 0x265a, 0x263b, 0x265b, 0x265c, 0x2640, + 0x265d, 0x265e, 0x265f, 0x2660, 0x2661, 0x2662, 0x2663, 0x2664, + 0x2636, 0x2246, 0x2161, 0x2160, 0x2243, 0x2247, 0x2248, 0x224b, + 0x224a, 0x2249, 0x224c, 0x2163, 0x2162, 0x223a, 0x2239, 0x2165, + 0x2164, 0x2238, 0x2237, 0x215f, 0x215e, 0x2242, 0x215b, 0x215d, + 0x215c, 0x2244, 0x2245, 0x215a, 0x2159, 0x224f, 0x224e, 0x2250, + 0x2251, 0x214f, 0x214e, 0x223c, 0x223d, 0x2240, 0x223b, 0x223e, + 0x223f, 0x224d, 0x225b, 0x225c, 0x225d, 0x225a, 0x2121, 0x2122, + 0x2123, 0x2128, 0x2134, 0x2135, 0x2136, 0x2137, 0x2138, 0x2139, + 0x213a, 0x213b, 0x213c, 0x213d, 0x216b, 0x2132, 0x2133, 0x2a21, + 0x2a22, 0x2a23, 0x2a24, 0x2a25, 0x2a26, 0x2a27, 0x2a28, 0x2a29, + 0x2a2a, 0x2a2b, 0x2a2c, 0x2a2d, 0x2a2e, 0x2a2f, 0x2a30, 0x2a31, + 0x2a32, 0x2a33, 0x2a34, 0x2a35, 0x2a36, 0x2a37, 0x2a38, 0x2a39, + 0x2a3a, 0x2a3b, 0x2a3c, 0x2a3d, 0x2a3e, 0x2a3f, 0x2a40, 0x2a41, + 0x2a42, 0x2a43, 0x2a44, 0x2a45, 0x2a46, 0x2a47, 0x2a48, 0x2a49, + 0x2a4a, 0x2a4b, 0x2a4c, 0x2a4d, 0x2a4e, 0x2a4f, 0x2a50, 0x2a51, + 0x2a52, 0x2a53, 0x2a54, 0x2a55, 0x2a56, 0x2a57, 0x2a58, 0x2a59, + 0x2a5a, 0x2a5b, 0x2a5c, 0x2a5d, 0x2a5e, 0x2a5f, 0x2a60, 0x2a61, + 0x2a62, 0x2a63, 0x2a64, 0x2a65, 0x2a66, 0x2a67, 0x2a68, 0x2a69, + 0x2a6a, 0x2a6b, 0x2a6c, 0x2a6d, 0x2a6e, 0x2a6f, 0x2a70, 0x2a71, + 0x2a72, 0x2a73, 0x2b21, 0x2b22, 0x2b23, 0x2b24, 0x2b25, 0x2b26, + 0x2b27, 0x2b28, 0x2b29, 0x2b2a, 0x2b2b, 0x2b2c, 0x2b2d, 0x2b2e, + 0x2b2f, 0x2b30, 0x2b31, 0x2b32, 0x2b33, 0x2b34, 0x2b35, 0x2b36, + 0x2b37, 0x2b38, 0x2b39, 0x2b3a, 0x2b3b, 0x2b3c, 0x2b3d, 0x2b3e, + 0x2b3f, 0x2b40, 0x2b41, 0x2b42, 0x2b43, 0x2b44, 0x2b45, 0x2b46, + 0x2b47, 0x2b48, 0x2b49, 0x2b4a, 0x2b4b, 0x2b4c, 0x2b4d, 0x2b4e, + 0x2b4f, 0x2b50, 0x2b51, 0x2b52, 0x2b53, 0x2b54, 0x2b55, 0x2b56, + 0x2b57, 0x2b58, 0x2b59, 0x2b5a, 0x2b5b, 0x2b5c, 0x2b5d, 0x2b5e, + 0x2b5f, 0x2b60, 0x2b61, 0x2b62, 0x2b63, 0x2b64, 0x2b65, 0x2b66, + 0x2b67, 0x2b68, 0x2b69, 0x2b6a, 0x2b6b, 0x2b6c, 0x2b6d, 0x2b6e, + 0x2b6f, 0x2b70, 0x2b71, 0x2b72, 0x2b73, 0x2b74, 0x2b75, 0x2b76, + 0x2421, 0x2422, 0x2423, 0x2424, 0x2425, 0x2426, 0x2427, 0x2428, + 0x2429, 0x242a, 0x242b, 0x242c, 0x242d, 0x242e, 0x242f, 0x2430, + 0x2431, 0x2432, 0x2433, 0x2434, 0x2435, 0x2436, 0x2437, 0x2438, + 0x2439, 0x243a, 0x243b, 0x243c, 0x243d, 0x243e, 0x243f, 0x2440, + 0x2441, 0x2442, 0x2443, 0x2444, 0x2445, 0x2446, 0x2447, 0x2448, + 0x2449, 0x244a, 0x244b, 0x244c, 0x244d, 0x244e, 0x244f, 0x2450, + 0x2451, 0x2452, 0x2453, 0x2454, 0x2455, 0x2456, 0x2457, 0x2458, + 0x2459, 0x245a, 0x245b, 0x245c, 0x245d, 0x245e, 0x245f, 0x2460, + 0x2461, 0x2462, 0x2463, 0x2464, 0x2465, 0x2466, 0x2467, 0x2468, + 0x2469, 0x246a, 0x246b, 0x246c, 0x246d, 0x246e, 0x246f, 0x2470, + 0x2471, 0x2472, 0x2473, 0x2474, 0x2475, 0x2476, 0x2477, 0x2478, + 0x2479, 0x247a, 0x247b, 0x247c, 0x247d, 0x247e, 0x2931, 0x2932, + 0x2933, 0x2934, 0x2935, 0x2936, 0x2937, 0x2938, 0x2939, 0x293a, + 0x293b, 0x293c, 0x293d, 0x293e, 0x293f, 0x2940, 0x2941, 0x2942, + 0x2943, 0x2944, 0x2945, 0x2946, 0x2947, 0x2948, 0x2949, 0x294a, + 0x294b, 0x294c, 0x225f, 0x2831, 0x2832, 0x2833, 0x2834, 0x2835, + 0x2836, 0x2837, 0x2838, 0x2839, 0x283a, 0x283b, 0x283c, 0x283d, + 0x283e, 0x283f, 0x2840, 0x2841, 0x2842, 0x2843, 0x2844, 0x2845, + 0x2846, 0x2847, 0x2848, 0x2849, 0x284a, 0x284b, 0x284c, 0x2268, + 0x225e, 0x2749, 0x274a, 0x274b, 0x274c, 0x274d, 0x273a, 0x273b, + 0x275c, 0x275d, 0x275e, 0x2736, 0x2737, 0x2738, 0x2754, 0x2755, + 0x2756, 0x2757, 0x2758, 0x2721, 0x2722, 0x2723, 0x2725, 0x272b, + 0x272c, 0x272d, 0x272e, 0x272f, 0x2730, 0x2731, 0x2732, 0x2733, + 0x2734, 0x2727, 0x2728, 0x2729, 0x272a, 0x273d, 0x273e, 0x2765, + 0x2766, 0x2767, 0x2768, 0x2761, 0x2762, 0x2763, 0x273f, 0x2740, + 0x2741, 0x2742, 0x2743, 0x2744, 0x2745, 0x2746, 0x2747, 0x2748, + 0x274e, 0x274f, 0x2750, 0x2751, 0x2752, 0x2753, 0x275a, 0x275b, + 0x2263, 0x276c, 0x2726, 0x2760, 0x276f, 0x2261, 0x273c, 0x276d, + 0x2735, 0x2739, 0x276a, 0x276b, 0x275f, 0x2264, 0x2764, 0x276e, + 0x2769, 0x6c69, 0x6f4b, 0x7652, 0x5832, 0x6d5b, 0x5f32, 0x5f3e, + 0x793b, 0x5c74, 0x7564, 0x7326, 0x5d60, 0x6126, 0x4e78, 0x5c30, + 0x632a, 0x7169, 0x4d7a, 0x7c2f, 0x5321, 0x712b, 0x6751, 0x522c, + 0x4e79, 0x717d, 0x5e3f, 0x7b3a, 0x7939, 0x4e52, 0x632b, 0x6b60, + 0x4e7a, 0x4b77, 0x6525, 0x4a61, 0x544c, 0x6a61, 0x5c63, 0x5f2d, + 0x4b6b, 0x552f, 0x5675, 0x6578, 0x5e40, 0x6c23, 0x694d, 0x6a27, + 0x6976, 0x7b3b, 0x6769, 0x6f4c, 0x5066, 0x5e41, 0x642c, 0x584c, + 0x7971, 0x4e5f, 0x7a24, 0x6632, 0x7a7b, 0x7a3d, 0x4c48, 0x6f4d, + 0x5555, 0x5322, 0x6c51, 0x6427, 0x6c52, 0x7631, 0x4e7b, 0x5051, + 0x4b3f, 0x6d24, 0x6d28, 0x5e42, 0x7662, 0x6d5c, 0x5c75, 0x6039, + 0x544e, 0x7435, 0x535b, 0x5635, 0x6c24, 0x6466, 0x716a, 0x4b6c, + 0x4b40, 0x6c72, 0x506a, 0x7972, 0x6c25, 0x505f, 0x676a, 0x506b, + 0x5c51, 0x5b69, 0x7d4c, 0x5b57, 0x5a61, 0x5636, 0x635f, 0x5e43, + 0x5e44, 0x4a21, 0x6e6c, 0x5323, 0x6e37, 0x784f, 0x6a48, 0x6e38, + 0x712c, 0x7125, 0x694e, 0x793c, 0x6579, 0x6c6a, 0x5d56, 0x6d42, + 0x7825, 0x653a, 0x5b58, 0x4a22, 0x514d, 0x6e6d, 0x6c6b, 0x5e45, + 0x6360, 0x4a49, 0x7269, 0x554e, 0x7636, 0x4e42, 0x5647, 0x6334, + 0x712d, 0x6a62, 0x5742, 0x7327, 0x4d6a, 0x6b6e, 0x5932, 0x7d25, + 0x7655, 0x5562, 0x7835, 0x4c75, 0x7535, 0x642d, 0x676b, 0x7155, + 0x703b, 0x6935, 0x4c49, 0x7a55, 0x6154, 0x5756, 0x5c41, 0x5e46, + 0x7a6f, 0x6361, 0x6173, 0x5c76, 0x4e7c, 0x5b44, 0x7871, 0x5c64, + 0x656f, 0x5c31, 0x5556, 0x735a, 0x4b41, 0x5b43, 0x597a, 0x536e, + 0x7a38, 0x7d26, 0x6b6f, 0x7426, 0x4c4a, 0x7328, 0x735b, 0x5b27, + 0x7637, 0x4f66, 0x7072, 0x4b5a, 0x6752, 0x5743, 0x7670, 0x685e, + 0x6526, 0x6567, 0x4a23, 0x4c27, 0x6a49, 0x7836, 0x7a25, 0x712e, + 0x6f4e, 0x4b6d, 0x7630, 0x6f4f, 0x694f, 0x775e, 0x4e53, 0x5c77, + 0x5b28, 0x4b78, 0x5f21, 0x5d61, 0x754a, 0x6936, 0x676c, 0x6e6e, + 0x7370, 0x5f3f, 0x4c4b, 0x5041, 0x7452, 0x603a, 0x5f40, 0x4e60, + 0x5c52, 0x7d6a, 0x5676, 0x6a4a, 0x6869, 0x632c, 0x7350, 0x4a24, + 0x5b78, 0x5e47, 0x6b70, 0x7156, 0x6562, 0x4c4c, 0x4b7b, 0x6a63, + 0x5f41, 0x566d, 0x6950, 0x6e39, 0x5563, 0x5153, 0x6570, 0x6834, + 0x6b43, 0x6a2a, 0x7a7c, 0x7576, 0x703c, 0x7d54, 0x603b, 0x4e43, + 0x503a, 0x773a, 0x5873, 0x774d, 0x642e, 0x545f, 0x5067, 0x6c7d, + 0x522e, 0x6e6f, 0x5557, 0x6a64, 0x7822, 0x4d6b, 0x573f, 0x7b31, + 0x4d6c, 0x5c32, 0x506c, 0x4e7d, 0x6e70, 0x4c42, 0x506d, 0x6577, + 0x737c, 0x6e22, 0x5933, 0x5874, 0x6937, 0x4e2e, 0x5922, 0x5871, + 0x544f, 0x6527, 0x5552, 0x5629, 0x7422, 0x7157, 0x5558, 0x703d, + 0x5750, 0x5450, 0x574f, 0x6b6a, 0x7d6b, 0x5b6d, 0x7c45, 0x4b42, + 0x7d55, 0x7448, 0x686a, 0x7573, 0x795e, 0x536f, 0x6c53, 0x5d42, + 0x6f37, 0x6754, 0x4a4a, 0x597b, 0x7a7d, 0x562a, 0x7478, 0x7777, + 0x5c2c, 0x5757, 0x5f22, 0x4e3e, 0x5370, 0x7024, 0x616c, 0x4f67, + 0x734b, 0x6d29, 0x4a3e, 0x746f, 0x764e, 0x5e7b, 0x503b, 0x5537, + 0x6e71, 0x7428, 0x5c78, 0x4b27, 0x5a4e, 0x6066, 0x6d25, 0x6e72, + 0x5c79, 0x795c, 0x735c, 0x7872, 0x7479, 0x7c71, 0x503c, 0x5b79, + 0x5731, 0x4b7c, 0x7025, 0x4b7d, 0x5574, 0x4d6d, 0x4a25, 0x562b, + 0x5042, 0x703e, 0x523d, 0x4c24, 0x7a36, 0x4c4d, 0x5a7a, 0x764f, + 0x6938, 0x5875, 0x4c4e, 0x574d, 0x5451, 0x696d, 0x4a6b, 0x5962, + 0x7d32, 0x632d, 0x564c, 0x5934, 0x6127, 0x6e53, 0x5043, 0x7d33, + 0x5564, 0x4f68, 0x6d43, 0x5032, 0x4e7e, 0x5a28, 0x7850, 0x7d56, + 0x7851, 0x7852, 0x5c53, 0x5d62, 0x7b79, 0x5d41, 0x6335, 0x6d5d, + 0x4e44, 0x4b21, 0x5d63, 0x7c5d, 0x792f, 0x527b, 0x4f21, 0x6428, + 0x7436, 0x6c7e, 0x632e, 0x676d, 0x7d41, 0x5a62, 0x5833, 0x5d64, + 0x706f, 0x7671, 0x7a70, 0x5175, 0x5a4f, 0x5c54, 0x5c26, 0x6f3f, + 0x4e4f, 0x6059, 0x5956, 0x6c54, 0x6a4b, 0x4a3f, 0x5530, 0x4f69, + 0x716d, 0x4c4f, 0x6478, 0x646d, 0x5758, 0x7d27, 0x6a2b, 0x7632, + 0x4f70, 0x793d, 0x6674, 0x4b5b, 0x7351, 0x6951, 0x7329, 0x5060, + 0x6952, 0x5a63, 0x6252, 0x7622, 0x6174, 0x5a64, 0x6755, 0x753f, + 0x4f22, 0x4d2f, 0x4f23, 0x4d30, 0x717e, 0x5023, 0x612f, 0x7823, + 0x4a26, 0x773b, 0x726a, 0x5e48, 0x6953, 0x5e49, 0x7d5e, 0x4a40, + 0x796a, 0x514e, 0x6e54, 0x5452, 0x5923, 0x7d28, 0x5759, 0x774e, + 0x7a3e, 0x4f56, 0x5770, 0x6b61, 0x7845, 0x5c7a, 0x5d43, 0x795f, + 0x676f, 0x7d65, 0x7623, 0x597c, 0x7d29, 0x676e, 0x5565, 0x6f50, + 0x4d31, 0x7722, 0x7132, 0x7131, 0x4d32, 0x5a2b, 0x4a27, 0x6362, + 0x7b3c, 0x5924, 0x6e3a, 0x7853, 0x7b7a, 0x4f24, 0x5c7b, 0x7663, + 0x6d2a, 0x7221, 0x4e61, 0x7a26, 0x7960, 0x6c56, 0x646e, 0x7921, + 0x7b6f, 0x796b, 0x6e23, 0x6a2c, 0x4a28, 0x747a, 0x4d56, 0x7c76, + 0x7449, 0x7854, 0x7826, 0x5e4a, 0x7246, 0x575a, 0x5350, 0x5845, + 0x6a66, 0x735d, 0x645a, 0x7664, 0x7672, 0x5f42, 0x597d, 0x4c76, + 0x533a, 0x642f, 0x7961, 0x7026, 0x4b53, 0x603c, 0x744a, 0x547a, + 0x7d2a, 0x7962, 0x7437, 0x7d42, 0x7c30, 0x7d6c, 0x4a62, 0x7d3d, + 0x6a67, 0x5f43, 0x5152, 0x4e62, 0x5324, 0x7d2b, 0x5f60, 0x7247, + 0x6770, 0x506e, 0x732a, 0x5e4b, 0x7638, 0x6175, 0x7133, 0x7723, + 0x4a29, 0x4f25, 0x5f44, 0x6130, 0x703f, 0x7624, 0x6336, 0x7a46, + 0x506f, 0x7d6d, 0x5d44, 0x7c77, 0x663f, 0x5e2d, 0x7a3f, 0x6571, + 0x6d44, 0x5225, 0x7d6e, 0x7536, 0x6176, 0x5e4c, 0x7c5e, 0x6c57, + 0x4d5d, 0x5637, 0x4d33, 0x7855, 0x6558, 0x4f6a, 0x4f50, 0x6a4c, + 0x6a2e, 0x6a2d, 0x5371, 0x5325, 0x774f, 0x6e24, 0x5024, 0x7222, + 0x5070, 0x7223, 0x7778, 0x5033, 0x5b29, 0x533b, 0x4a6c, 0x7126, + 0x4b55, 0x7767, 0x4d5e, 0x7724, 0x7840, 0x535d, 0x4c50, 0x4f26, + 0x7673, 0x6177, 0x535c, 0x7a7e, 0x7a27, 0x6b59, 0x4f27, 0x6a2f, + 0x646f, 0x6939, 0x7158, 0x5858, 0x6072, 0x6634, 0x5c7c, 0x7371, + 0x6350, 0x727b, 0x5b46, 0x5071, 0x5072, 0x4f5c, 0x5351, 0x4c31, + 0x7758, 0x4b28, 0x6b3c, 0x643e, 0x745c, 0x5c42, 0x7027, 0x6640, + 0x4a6d, 0x686b, 0x6568, 0x5c43, 0x6d5e, 0x5372, 0x4c77, 0x4e54, + 0x672b, 0x4b43, 0x6131, 0x7732, 0x5373, 0x5352, 0x7540, 0x5f5d, + 0x6e73, 0x6771, 0x7d34, 0x7248, 0x7352, 0x6e74, 0x6253, 0x4c51, + 0x5f6a, 0x693a, 0x5957, 0x754d, 0x7172, 0x7a47, 0x5978, 0x5442, + 0x7665, 0x5d45, 0x6772, 0x6d5f, 0x4a4b, 0x5b7a, 0x6835, 0x5326, + 0x7d35, 0x7949, 0x6462, 0x7b3d, 0x5724, 0x4e45, 0x4e55, 0x5666, + 0x653d, 0x5e4d, 0x6c73, 0x6d60, 0x6c6c, 0x7b3e, 0x5f6b, 0x6178, + 0x793e, 0x5073, 0x602a, 0x6862, 0x6254, 0x527d, 0x6528, 0x5953, + 0x535e, 0x7438, 0x773c, 0x5c7d, 0x686c, 0x6467, 0x6377, 0x6c28, + 0x7a71, 0x6572, 0x5074, 0x522f, 0x5c65, 0x5025, 0x7134, 0x7c31, + 0x4c78, 0x5d46, 0x7a51, 0x775f, 0x7a28, 0x6e75, 0x5e4e, 0x6773, + 0x772c, 0x6b44, 0x6d61, 0x602b, 0x5d47, 0x5233, 0x523f, 0x4a4c, + 0x7b3f, 0x657d, 0x5d65, 0x584d, 0x6c74, 0x5075, 0x686d, 0x5052, + 0x5958, 0x7666, 0x5b2a, 0x7760, 0x5859, 0x7423, 0x745d, 0x6f51, + 0x5935, 0x6d2b, 0x6337, 0x6e3b, 0x4d34, 0x6073, 0x6a4d, 0x6c75, + 0x686e, 0x4b29, 0x712f, 0x4a4d, 0x6c29, 0x726b, 0x7d6f, 0x7973, + 0x6641, 0x6c58, 0x6d2c, 0x6a4e, 0x685f, 0x5e4f, 0x5226, 0x6774, + 0x5156, 0x6642, 0x6363, 0x6430, 0x5834, 0x7625, 0x735e, 0x5725, + 0x7768, 0x6846, 0x7b66, 0x5d66, 0x5c7e, 0x585a, 0x5a2c, 0x6a30, + 0x6338, 0x4a2a, 0x6179, 0x6a31, 0x726c, 0x7a6e, 0x6e55, 0x7974, + 0x526c, 0x7b7b, 0x7d70, 0x603d, 0x4e63, 0x7846, 0x5e2e, 0x5f45, + 0x653e, 0x6d2d, 0x7a6a, 0x4d6e, 0x6d26, 0x6d2e, 0x706d, 0x5d21, + 0x6d2f, 0x7c78, 0x586b, 0x4c79, 0x4d35, 0x7a29, 0x615d, 0x6255, + 0x6d4f, 0x5d22, 0x794a, 0x6a68, 0x656d, 0x536b, 0x6954, 0x617a, + 0x644c, 0x6164, 0x6847, 0x4e5b, 0x5c55, 0x7735, 0x7c73, 0x7073, + 0x4e2f, 0x7135, 0x6f52, 0x6848, 0x6b71, 0x4b54, 0x603e, 0x6378, + 0x6a69, 0x7c32, 0x6074, 0x4f60, 0x6e25, 0x7a2a, 0x6643, 0x6132, + 0x4a2b, 0x6364, 0x693b, 0x6256, 0x7372, 0x6e56, 0x6a32, 0x5076, + 0x6c59, 0x5a4b, 0x4f28, 0x5d23, 0x585b, 0x794e, 0x6955, 0x6351, + 0x523c, 0x582c, 0x734c, 0x4d7b, 0x7656, 0x6775, 0x686f, 0x6379, + 0x523b, 0x7373, 0x637b, 0x5e50, 0x4e30, 0x5677, 0x7159, 0x7541, + 0x5c44, 0x753b, 0x5e51, 0x5c66, 0x5e52, 0x6d62, 0x6e76, 0x6a4f, + 0x706e, 0x637c, 0x535f, 0x5374, 0x6133, 0x6134, 0x7453, 0x5f46, + 0x6956, 0x5b2b, 0x7626, 0x6339, 0x6b45, 0x7429, 0x4d36, 0x5279, + 0x5a2d, 0x5263, 0x4f51, 0x4b5c, 0x4c7a, 0x4f5d, 0x6829, 0x633b, + 0x633a, 0x605a, 0x6e77, 0x5c33, 0x5375, 0x5726, 0x7635, 0x575b, + 0x6155, 0x546a, 0x5f23, 0x7d5f, 0x5077, 0x6d54, 0x4b2a, 0x645b, + 0x617b, 0x4b22, 0x5360, 0x643f, 0x7b40, 0x5a3e, 0x644d, 0x5639, + 0x6f40, 0x617c, 0x7639, 0x5f47, 0x6431, 0x5c67, 0x5c68, 0x7a56, + 0x5376, 0x715a, 0x7a72, 0x627d, 0x554f, 0x5078, 0x4d5f, 0x754b, + 0x6470, 0x4b2b, 0x5744, 0x627e, 0x5d5a, 0x5a2e, 0x4a6e, 0x5539, + 0x6321, 0x6863, 0x732b, 0x4f29, 0x5377, 0x5471, 0x4e64, 0x6872, + 0x6575, 0x672e, 0x563a, 0x5f6c, 0x6440, 0x6864, 0x5835, 0x645c, + 0x7439, 0x7136, 0x625e, 0x6135, 0x4d6f, 0x7127, 0x4e65, 0x4b5d, + 0x5963, 0x732c, 0x5079, 0x6c2b, 0x5e53, 0x7769, 0x7975, 0x615e, + 0x4b6e, 0x633c, 0x7856, 0x5b6e, 0x7d71, 0x7736, 0x745e, 0x726d, + 0x5b59, 0x7028, 0x617d, 0x5e54, 0x602c, 0x6d63, 0x5361, 0x5f48, + 0x5936, 0x7d2c, 0x6f53, 0x6441, 0x786b, 0x5b2c, 0x7c46, 0x582d, + 0x763a, 0x5b5f, 0x5353, 0x7847, 0x4a4e, 0x7841, 0x5234, 0x5c34, + 0x7a39, 0x4a4f, 0x7c33, 0x6a6a, 0x6a6b, 0x507a, 0x6d64, 0x5d67, + 0x5f49, 0x5f6d, 0x6e3c, 0x6f41, 0x4c52, 0x5d24, 0x5f4a, 0x5378, + 0x7128, 0x4d37, 0x6f54, 0x645d, 0x5f6e, 0x4b2c, 0x693c, 0x6a6c, + 0x5f4b, 0x793f, 0x562f, 0x5546, 0x4f2a, 0x4e29, 0x5678, 0x7137, + 0x6e78, 0x5959, 0x735f, 0x7848, 0x4e46, 0x5566, 0x7466, 0x6645, + 0x6f55, 0x4b6f, 0x7c5f, 0x5c27, 0x5667, 0x7849, 0x6352, 0x633d, + 0x4f61, 0x7040, 0x6c5a, 0x5d57, 0x7b70, 0x6c2c, 0x7029, 0x7a57, + 0x7b41, 0x5240, 0x6530, 0x6d65, 0x4b2d, 0x7930, 0x7725, 0x4b2e, + 0x5a2f, 0x5836, 0x5327, 0x7b32, 0x7d44, 0x6c2d, 0x7b21, 0x6569, + 0x696e, 0x7374, 0x7873, 0x7041, 0x5e2f, 0x7830, 0x7360, 0x672f, + 0x5b2d, 0x6635, 0x7928, 0x5d58, 0x6859, 0x6f56, 0x5362, 0x625f, + 0x7c60, 0x5748, 0x7d2d, 0x5f6f, 0x4c53, 0x5379, 0x5470, 0x5b47, + 0x5e55, 0x7074, 0x5550, 0x6559, 0x7c47, 0x5c56, 0x6260, 0x5a30, + 0x7323, 0x536c, 0x744b, 0x7d45, 0x637d, 0x7931, 0x507b, 0x6c5b, + 0x753c, 0x7224, 0x584e, 0x584f, 0x7577, 0x7661, 0x5237, 0x7b6c, + 0x5d48, 0x6468, 0x5241, 0x7857, 0x563b, 0x5e56, 0x773d, 0x6c2e, + 0x5061, 0x6075, 0x6a33, 0x4e56, 0x4c25, 0x6c76, 0x6261, 0x633e, + 0x7c48, 0x4d70, 0x7976, 0x5f70, 0x653f, 0x4e3f, 0x7c61, 0x6d30, + 0x7d51, 0x763b, 0x794f, 0x6b5a, 0x4a41, 0x5238, 0x4d71, 0x6353, + 0x7d66, 0x666d, 0x637a, 0x702a, 0x7950, 0x7c62, 0x7827, 0x6165, + 0x6e79, 0x6776, 0x6a6d, 0x7c34, 0x7542, 0x575c, 0x7075, 0x5d68, + 0x536d, 0x757c, 0x5a3f, 0x4c7b, 0x537a, 0x7424, 0x6f57, 0x5443, + 0x7b63, 0x7b6d, 0x602d, 0x6a6e, 0x7b33, 0x6442, 0x7667, 0x525d, + 0x5f4c, 0x7c49, 0x6529, 0x6076, 0x7633, 0x617e, 0x4b70, 0x6a6f, + 0x6a70, 0x5a40, 0x7834, 0x6b72, 0x6443, 0x6957, 0x6471, 0x4a6f, + 0x4e57, 0x7c4a, 0x7361, 0x4b44, 0x6365, 0x4b45, 0x6a34, 0x693d, + 0x5749, 0x6b5b, 0x6d31, 0x4c43, 0x773e, 0x7c4b, 0x7874, 0x5937, + 0x7353, 0x7354, 0x7764, 0x7751, 0x5837, 0x4e31, 0x4a42, 0x7b34, + 0x4b46, 0x7076, 0x5567, 0x6a50, 0x4c54, 0x4b2f, 0x742a, 0x692f, + 0x7543, 0x6958, 0x5d69, 0x7173, 0x557b, 0x5e3b, 0x747b, 0x7d73, + 0x7d72, 0x7726, 0x5d49, 0x5453, 0x4c28, 0x5a41, 0x4c55, 0x5964, + 0x7a4a, 0x6563, 0x533c, 0x4a70, 0x5044, 0x4a50, 0x7a2b, 0x6b6b, + 0x6778, 0x5965, 0x5157, 0x7324, 0x547b, 0x7c63, 0x7a58, 0x7355, + 0x4f2b, 0x6b73, 0x557c, 0x5354, 0x4d7c, 0x5966, 0x6279, 0x6221, + 0x6b54, 0x6077, 0x6432, 0x4c7c, 0x7b64, 0x742b, 0x503d, 0x4a71, + 0x6f38, 0x5740, 0x6e7a, 0x7d74, 0x5363, 0x7b42, 0x5568, 0x5b2e, + 0x6136, 0x7837, 0x603f, 0x7b43, 0x5d6a, 0x6222, 0x6e26, 0x7668, + 0x7675, 0x5d4a, 0x5062, 0x5d26, 0x5d6b, 0x6479, 0x632f, 0x507c, + 0x747c, 0x4c3c, 0x776a, 0x6564, 0x5f71, 0x7761, 0x7977, 0x6f39, + 0x7858, 0x7929, 0x7859, 0x6e3d, 0x5846, 0x6463, 0x754e, 0x5d59, + 0x5967, 0x5239, 0x5543, 0x5a65, 0x5a50, 0x5159, 0x4e58, 0x4b5e, + 0x742c, 0x5a7b, 0x7669, 0x6873, 0x4f2c, 0x7070, 0x747d, 0x5b48, + 0x4e40, 0x6354, 0x514f, 0x7175, 0x4d72, 0x4f6b, 0x4d38, 0x6326, + 0x515a, 0x7225, 0x7226, 0x644e, 0x537b, 0x7129, 0x7249, 0x6f58, + 0x6649, 0x5838, 0x7a73, 0x7335, 0x7824, 0x5173, 0x6648, 0x785a, + 0x5c69, 0x5e57, 0x4b5f, 0x4f6c, 0x745f, 0x5174, 0x523a, 0x5f72, + 0x6137, 0x6223, 0x537c, 0x6d66, 0x5b49, 0x647a, 0x4f5e, 0x4e50, + 0x5553, 0x7375, 0x772e, 0x6f48, 0x4d73, 0x754f, 0x6573, 0x7042, + 0x4a51, 0x6a71, 0x5026, 0x595a, 0x702b, 0x6b67, 0x6540, 0x7c35, + 0x6444, 0x4c29, 0x7d46, 0x6a35, 0x652a, 0x5f3a, 0x615f, 0x5a51, + 0x6138, 0x6874, 0x537d, 0x6224, 0x724a, 0x5a66, 0x7733, 0x7d4d, + 0x7336, 0x6e57, 0x7544, 0x5824, 0x7227, 0x5938, 0x5939, 0x6f49, + 0x564e, 0x774b, 0x5f2e, 0x6875, 0x5235, 0x5355, 0x744c, 0x5a7c, + 0x5968, 0x776b, 0x7549, 0x733c, 0x5a52, 0x5335, 0x6836, 0x564f, + 0x743a, 0x7749, 0x4c2a, 0x7043, 0x4c56, 0x5053, 0x533d, 0x5b7b, + 0x4b60, 0x5364, 0x7677, 0x553a, 0x734d, 0x4b61, 0x6b74, 0x742d, + 0x7c2a, 0x776c, 0x6876, 0x5a67, 0x774c, 0x6541, 0x606e, 0x557d, + 0x4e66, 0x7c2b, 0x553b, 0x7228, 0x6225, 0x4d39, 0x6a72, 0x4b47, + 0x4d74, 0x5b2f, 0x6f59, 0x4d3a, 0x7c79, 0x5f73, 0x4e67, 0x5a42, + 0x4f2d, 0x6779, 0x7828, 0x7362, 0x4a72, 0x5f24, 0x5444, 0x4c57, + 0x6542, 0x4d3b, 0x6f5a, 0x6e58, 0x5d27, 0x6226, 0x6040, 0x5630, + 0x784a, 0x7c7a, 0x597e, 0x5e30, 0x5d6c, 0x5a68, 0x5460, 0x5679, + 0x4d57, 0x5e58, 0x7278, 0x6456, 0x5045, 0x742e, 0x5d28, 0x6d45, + 0x7356, 0x5e59, 0x6366, 0x5328, 0x5b30, 0x655a, 0x633f, 0x5b31, + 0x5569, 0x6041, 0x6f5b, 0x7069, 0x5732, 0x507d, 0x5969, 0x507e, + 0x6c6d, 0x5329, 0x7229, 0x7044, 0x6262, 0x696f, 0x7951, 0x6959, + 0x685a, 0x5a43, 0x5a44, 0x5445, 0x677a, 0x4d60, 0x6330, 0x5b32, + 0x7b44, 0x7363, 0x5925, 0x7b67, 0x5d4b, 0x5054, 0x6636, 0x602e, + 0x7d5a, 0x5c35, 0x6078, 0x6731, 0x7570, 0x585c, 0x6d46, 0x6139, + 0x6340, 0x7940, 0x6970, 0x595b, 0x7364, 0x5c36, 0x6469, 0x7045, + 0x6341, 0x7c4c, 0x7c4d, 0x724b, 0x724c, 0x644f, 0x715b, 0x7a59, + 0x7138, 0x7d75, 0x6079, 0x677b, 0x7c37, 0x7c64, 0x7b45, 0x6367, + 0x5839, 0x7678, 0x5c45, 0x4c58, 0x602f, 0x7467, 0x6f5c, 0x4f7c, + 0x6f5d, 0x722a, 0x7d3e, 0x4a2c, 0x7d3b, 0x7d47, 0x6732, 0x6a51, + 0x5f74, 0x516c, 0x645e, 0x6543, 0x5926, 0x4d3c, 0x7365, 0x6d55, + 0x593a, 0x6d67, 0x7b35, 0x786c, 0x6067, 0x4c59, 0x5446, 0x6725, + 0x5575, 0x533e, 0x7c7b, 0x6472, 0x5f75, 0x6878, 0x786d, 0x4e47, + 0x7d76, 0x6858, 0x4d58, 0x6756, 0x4c5a, 0x4a63, 0x5f76, 0x7047, + 0x7046, 0x583a, 0x7174, 0x7470, 0x754c, 0x7c65, 0x6a45, 0x6a73, + 0x5d5b, 0x5c57, 0x5e7d, 0x7279, 0x5547, 0x5850, 0x7048, 0x5121, + 0x5122, 0x5954, 0x5668, 0x594a, 0x5a31, 0x5847, 0x5c62, 0x734e, + 0x7574, 0x7139, 0x5a53, 0x766a, 0x4f75, 0x7d2e, 0x4a52, 0x5f34, + 0x575d, 0x7a3a, 0x6e27, 0x753d, 0x7875, 0x6d68, 0x5461, 0x5123, + 0x6156, 0x7978, 0x5b4a, 0x4b79, 0x5454, 0x595c, 0x6e3e, 0x776d, + 0x526e, 0x6166, 0x7779, 0x5d6d, 0x685b, 0x5b33, 0x5177, 0x6030, + 0x5462, 0x7657, 0x5779, 0x585d, 0x4d7d, 0x722b, 0x4d3d, 0x7842, + 0x722c, 0x4a2d, 0x4a2e, 0x4f2e, 0x6342, 0x5c37, 0x5b5a, 0x593b, + 0x4a73, 0x7653, 0x6678, 0x6a75, 0x6a76, 0x7679, 0x4f2f, 0x4a53, + 0x4a2f, 0x5230, 0x713a, 0x5733, 0x6343, 0x737d, 0x5e5a, 0x5e5b, + 0x6f5e, 0x6263, 0x6e7b, 0x5f77, 0x574a, 0x4e68, 0x5b5b, 0x713b, + 0x6971, 0x7a37, 0x5046, 0x4c2b, 0x6e28, 0x4b7a, 0x7979, 0x4c7d, + 0x537e, 0x6450, 0x726e, 0x5455, 0x5f4d, 0x7c38, 0x5150, 0x724d, + 0x7752, 0x4a54, 0x5559, 0x585e, 0x4d59, 0x6e29, 0x763c, 0x4c5b, + 0x7049, 0x7c7c, 0x6849, 0x747e, 0x677c, 0x575e, 0x5e5c, 0x702c, + 0x4c7e, 0x4d61, 0x613a, 0x5b6f, 0x5a32, 0x5125, 0x5c38, 0x5876, + 0x5124, 0x4d62, 0x5c6a, 0x7077, 0x704a, 0x503e, 0x5d5c, 0x5456, + 0x5356, 0x6d50, 0x4d21, 0x5f35, 0x5f78, 0x5421, 0x4e32, 0x684a, + 0x6b75, 0x6355, 0x7550, 0x7521, 0x5927, 0x652b, 0x664b, 0x7571, + 0x6545, 0x7923, 0x605b, 0x766b, 0x4b71, 0x596a, 0x7522, 0x5751, + 0x5178, 0x6a78, 0x6a79, 0x5a33, 0x6f5f, 0x716f, 0x6576, 0x6e3f, + 0x6264, 0x503f, 0x7a2c, 0x7551, 0x6733, 0x693e, 0x724e, 0x5b34, + 0x7c4e, 0x5d6e, 0x6734, 0x5734, 0x7734, 0x4d3e, 0x5a69, 0x4f30, + 0x7759, 0x7366, 0x4e59, 0x4e2a, 0x4b48, 0x5027, 0x704b, 0x5047, + 0x6445, 0x5b60, 0x555a, 0x5727, 0x6e40, 0x7876, 0x7552, 0x6d69, + 0x593c, 0x6546, 0x7523, 0x5a54, 0x6227, 0x7b7c, 0x715c, 0x4a74, + 0x687a, 0x4e69, 0x6978, 0x6265, 0x5039, 0x5472, 0x5126, 0x5f4e, + 0x7c74, 0x532a, 0x4c2c, 0x6f60, 0x6565, 0x5055, 0x5b7c, 0x7c66, + 0x4b7e, 0x6d6a, 0x5e31, 0x7963, 0x5422, 0x4f76, 0x5650, 0x556a, + 0x716e, 0x7a4b, 0x6521, 0x5531, 0x4f6d, 0x6d6b, 0x5532, 0x553c, + 0x7d62, 0x732d, 0x7d5b, 0x6930, 0x5127, 0x7d63, 0x4e33, 0x7d64, + 0x7a4e, 0x4a30, 0x7727, 0x4f31, 0x6622, 0x7c36, 0x722d, 0x6f61, + 0x732e, 0x5c46, 0x596b, 0x6860, 0x6128, 0x5576, 0x4f7d, 0x5e5d, + 0x5951, 0x646a, 0x724f, 0x773f, 0x6266, 0x6228, 0x6356, 0x6d51, + 0x6979, 0x5631, 0x5e32, 0x6068, 0x532b, 0x6b5c, 0x5f2f, 0x4a43, + 0x6e7c, 0x7d43, 0x6b76, 0x4f32, 0x596c, 0x593d, 0x585f, 0x5438, + 0x6b3e, 0x5d6f, 0x5d70, 0x5d71, 0x5d72, 0x593e, 0x7b46, 0x4f33, + 0x6e7d, 0x642b, 0x5a45, 0x586c, 0x5128, 0x6229, 0x5e3c, 0x6735, + 0x5b70, 0x6f62, 0x7170, 0x4f34, 0x5b71, 0x6031, 0x5f25, 0x7952, + 0x677d, 0x6623, 0x7b71, 0x4b30, 0x722e, 0x4d67, 0x685c, 0x6757, + 0x7740, 0x5063, 0x5a21, 0x4c3d, 0x5129, 0x5d4c, 0x637e, 0x512a, + 0x682a, 0x6a36, 0x797a, 0x664c, 0x7658, 0x5447, 0x594b, 0x5952, + 0x534b, 0x5877, 0x5a29, 0x7578, 0x5e5e, 0x722f, 0x7829, 0x5848, + 0x6e41, 0x7941, 0x5d73, 0x6a7a, 0x763d, 0x613b, 0x4d3f, 0x7454, + 0x664d, 0x7c4f, 0x7b22, 0x605c, 0x743b, 0x5a55, 0x7932, 0x7b72, + 0x5b76, 0x5e5f, 0x5b72, 0x785c, 0x776e, 0x6b68, 0x527a, 0x713c, + 0x7a5a, 0x5a6a, 0x5a46, 0x7741, 0x6736, 0x6547, 0x562c, 0x5c47, + 0x6129, 0x622a, 0x5526, 0x5457, 0x7250, 0x6a7b, 0x605d, 0x7b73, + 0x713d, 0x6267, 0x7d57, 0x4e48, 0x6a37, 0x7c40, 0x7d67, 0x776f, + 0x5735, 0x6f3a, 0x715d, 0x5e33, 0x684b, 0x785d, 0x7b47, 0x5548, + 0x575f, 0x5d29, 0x6931, 0x7a2d, 0x7659, 0x7a74, 0x782a, 0x666e, + 0x4c5c, 0x613c, 0x606f, 0x693f, 0x7c7d, 0x664e, 0x6157, 0x664f, + 0x7471, 0x6473, 0x647b, 0x7964, 0x6f63, 0x4f6e, 0x763e, 0x6032, + 0x7c7e, 0x512b, 0x577a, 0x7b48, 0x6257, 0x5423, 0x7078, 0x5728, + 0x6167, 0x533f, 0x6f64, 0x5745, 0x6b62, 0x7c67, 0x6422, 0x6268, + 0x6650, 0x7b68, 0x7468, 0x6574, 0x743c, 0x7455, 0x5f36, 0x7c39, + 0x6e42, 0x4a75, 0x6f65, 0x4b62, 0x5424, 0x5e60, 0x5a7d, 0x6446, + 0x683e, 0x605e, 0x7634, 0x6a52, 0x797b, 0x6042, 0x4a64, 0x6737, + 0x6a7d, 0x595d, 0x5a34, 0x6e2a, 0x7b69, 0x5b4b, 0x5a35, 0x713e, + 0x532c, 0x7b49, 0x5f4f, 0x5340, 0x6357, 0x6f66, 0x7c50, 0x6940, + 0x7553, 0x6c5c, 0x7737, 0x6a38, 0x5179, 0x5c48, 0x6a39, 0x715e, + 0x5736, 0x4f35, 0x5928, 0x6c6e, 0x5d2a, 0x4d22, 0x682e, 0x613d, + 0x7251, 0x6941, 0x527c, 0x5b35, 0x7367, 0x587e, 0x7c51, 0x6d32, + 0x742f, 0x7b23, 0x7c41, 0x6e2b, 0x5425, 0x7472, 0x6e59, 0x7b4a, + 0x4d63, 0x583b, 0x655b, 0x7877, 0x7654, 0x5729, 0x4b49, 0x6651, + 0x704c, 0x582e, 0x7953, 0x557e, 0x583c, 0x7230, 0x622b, 0x7368, + 0x6f42, 0x6d6c, 0x6738, 0x5a7e, 0x4c3e, 0x727c, 0x5a6b, 0x6258, + 0x6d56, 0x5651, 0x6033, 0x7c52, 0x6b48, 0x5341, 0x704d, 0x4f77, + 0x6d52, 0x5458, 0x5c49, 0x5771, 0x5f3b, 0x7325, 0x744d, 0x713f, + 0x7831, 0x697a, 0x7b4b, 0x4a55, 0x7954, 0x774a, 0x5648, 0x7c68, + 0x733d, 0x6e7e, 0x677e, 0x5342, 0x5336, 0x4c2d, 0x767a, 0x5632, + 0x5258, 0x6758, 0x6325, 0x6739, 0x702d, 0x7b4c, 0x6b21, 0x5426, + 0x7b4d, 0x553d, 0x715f, 0x767b, 0x5e34, 0x556b, 0x6548, 0x7b24, + 0x5439, 0x5e61, 0x6423, 0x5737, 0x786e, 0x5e35, 0x5652, 0x7955, + 0x673a, 0x6b55, 0x5577, 0x6f67, 0x613e, 0x7a2e, 0x5669, 0x566e, + 0x673b, 0x6c4b, 0x5533, 0x4e34, 0x7b25, 0x616e, 0x7728, 0x7b4e, + 0x583d, 0x7b7d, 0x7c69, 0x4f36, 0x6d47, 0x6e2c, 0x4c5d, 0x7627, + 0x667a, 0x7524, 0x7d5c, 0x6d33, 0x4e49, 0x6f68, 0x613f, 0x7a5b, + 0x4b63, 0x7729, 0x7b26, 0x5c39, 0x7140, 0x6d48, 0x6f43, 0x562d, + 0x7d4e, 0x6821, 0x7b74, 0x5527, 0x7176, 0x6653, 0x4c5e, 0x7832, + 0x5c6b, 0x7d36, 0x656a, 0x7160, 0x5b4c, 0x5d4d, 0x5448, 0x596d, + 0x7525, 0x667b, 0x6654, 0x7d48, 0x5621, 0x7d3f, 0x7c53, 0x6f21, + 0x673c, 0x516e, 0x6655, 0x6972, 0x5f30, 0x5860, 0x7c3a, 0x7d2f, + 0x704e, 0x5b61, 0x6549, 0x6d34, 0x6043, 0x6358, 0x697b, 0x6a28, + 0x7d37, 0x7b27, 0x6942, 0x7d77, 0x6259, 0x5c6c, 0x6822, 0x6670, + 0x7d78, 0x7d79, 0x763f, 0x6727, 0x6657, 0x5473, 0x5449, 0x567a, + 0x5772, 0x6140, 0x5b62, 0x6658, 0x673d, 0x704f, 0x733e, 0x622c, + 0x7537, 0x6070, 0x7d38, 0x6368, 0x5427, 0x687c, 0x7a52, 0x786f, + 0x5653, 0x5534, 0x7050, 0x7770, 0x6e33, 0x6a3a, 0x6a53, 0x6d49, + 0x5d2b, 0x652c, 0x7d21, 0x5f50, 0x6c33, 0x5f51, 0x6d6d, 0x7838, + 0x777a, 0x782b, 0x7460, 0x543a, 0x6433, 0x695a, 0x5e36, 0x593f, + 0x5940, 0x566f, 0x594c, 0x5a2a, 0x5f65, 0x7765, 0x4c32, 0x5f79, + 0x5760, 0x543b, 0x7d7a, 0x4c33, 0x5b73, 0x5f52, 0x4e4a, 0x6e5a, + 0x6464, 0x7b4f, 0x4f37, 0x6e43, 0x4e6a, 0x622d, 0x5761, 0x7a75, + 0x5549, 0x782c, 0x6759, 0x7369, 0x586d, 0x6344, 0x7071, 0x6865, + 0x607a, 0x6e44, 0x595e, 0x6b22, 0x6b23, 0x7c42, 0x6a3b, 0x682b, + 0x5e62, 0x6d6f, 0x6823, 0x4f71, 0x543c, 0x7c6a, 0x673e, 0x7c72, + 0x5634, 0x622e, 0x5337, 0x7a4c, 0x7a5c, 0x6d35, 0x6163, 0x682c, + 0x685d, 0x6f69, 0x743d, 0x4f38, 0x695b, 0x512c, 0x5a47, 0x6b49, + 0x684c, 0x5e37, 0x563c, 0x5365, 0x7a5d, 0x5a56, 0x4a31, 0x5a48, + 0x5f26, 0x7933, 0x7252, 0x4a44, 0x4e4b, 0x4d75, 0x7d30, 0x5528, + 0x7141, 0x6269, 0x5c4a, 0x6c34, 0x7a40, 0x7b28, 0x5028, 0x5a6c, + 0x596e, 0x607b, 0x6f6a, 0x7a5e, 0x6044, 0x4f39, 0x554a, 0x5762, + 0x622f, 0x5738, 0x684d, 0x765a, 0x6f22, 0x625a, 0x767c, 0x7b50, + 0x512d, 0x4d64, 0x512e, 0x5c6d, 0x684e, 0x7079, 0x4e35, 0x667c, + 0x577b, 0x5056, 0x5d75, 0x7771, 0x767d, 0x5b77, 0x7b6a, 0x695c, + 0x5941, 0x7572, 0x6045, 0x6a54, 0x7942, 0x6a3c, 0x5245, 0x7b51, + 0x6740, 0x6b25, 0x5f7a, 0x6322, 0x5739, 0x6943, 0x687d, 0x682f, + 0x7253, 0x7b29, 0x5825, 0x554b, 0x5048, 0x512f, 0x5763, 0x6046, + 0x5622, 0x6d70, 0x5773, 0x7c54, 0x5a57, 0x4c5f, 0x7254, 0x5130, + 0x4c60, 0x5b7d, 0x733f, 0x7051, 0x7c3b, 0x6230, 0x6625, 0x625b, + 0x5f5e, 0x6047, 0x726f, 0x4c61, 0x566a, 0x6742, 0x4e36, 0x7340, + 0x4d7e, 0x7b52, 0x7878, 0x777b, 0x683f, 0x6837, 0x6d36, 0x5c3a, + 0x4c34, 0x7177, 0x6838, 0x4a76, 0x6424, 0x7456, 0x5f66, 0x5f27, + 0x5f67, 0x6141, 0x6944, 0x5c4b, 0x6945, 0x6f23, 0x6b26, 0x4b23, + 0x6369, 0x517b, 0x6f24, 0x6f6b, 0x5034, 0x4d23, 0x6866, 0x6f25, + 0x534c, 0x5a6d, 0x573a, 0x7255, 0x7565, 0x596f, 0x7934, 0x5554, + 0x7d4f, 0x5b63, 0x7161, 0x6c36, 0x7b7e, 0x5357, 0x5131, 0x4b31, + 0x5132, 0x4b32, 0x7142, 0x7461, 0x7935, 0x6143, 0x6142, 0x6b77, + 0x5f28, 0x4b4a, 0x6639, 0x785e, 0x792a, 0x4a77, 0x6d37, 0x5338, + 0x7256, 0x5459, 0x6e45, 0x7270, 0x4a32, 0x5c3b, 0x7178, 0x6c37, + 0x654a, 0x7640, 0x7d5d, 0x5463, 0x4c62, 0x7754, 0x5765, 0x5343, + 0x5826, 0x7641, 0x5d76, 0x4d40, 0x655c, 0x654b, 0x6144, 0x6830, + 0x7430, 0x736a, 0x5a6e, 0x573b, 0x6231, 0x572a, 0x567b, 0x645f, + 0x4a56, 0x6b28, 0x5b7e, 0x7642, 0x6f3b, 0x547d, 0x6048, 0x6839, + 0x6f26, 0x4d24, 0x5474, 0x5b21, 0x5b5c, 0x5b5d, 0x6e5c, 0x4b4b, + 0x7c55, 0x4e6b, 0x4d41, 0x7b53, 0x792b, 0x7554, 0x5929, 0x695d, + 0x5b4d, 0x5d4e, 0x6743, 0x6c4c, 0x796c, 0x4b4c, 0x607c, 0x5428, + 0x6d53, 0x586f, 0x7257, 0x4a78, 0x5a6f, 0x5654, 0x594d, 0x586e, + 0x7241, 0x5f53, 0x5a70, 0x626a, 0x607d, 0x5878, 0x772f, 0x5a36, + 0x4a57, 0x7258, 0x5879, 0x7a5f, 0x4f6f, 0x5942, 0x7052, 0x6451, + 0x7337, 0x7a60, 0x6f6c, 0x6232, 0x543d, 0x594e, 0x7462, 0x5429, + 0x4d42, 0x675a, 0x7259, 0x592a, 0x583e, 0x5c2d, 0x626b, 0x567c, + 0x4a79, 0x545a, 0x7457, 0x4c21, 0x4f3a, 0x7538, 0x5943, 0x5068, + 0x6345, 0x6b78, 0x7231, 0x4f3b, 0x532d, 0x6861, 0x4e6c, 0x6034, + 0x5e63, 0x5d77, 0x7232, 0x7376, 0x765b, 0x577e, 0x785f, 0x7772, + 0x5029, 0x665a, 0x7526, 0x573c, 0x4c63, 0x665b, 0x5d5d, 0x5133, + 0x6f6d, 0x565e, 0x6474, 0x616f, 0x5d78, 0x684f, 0x4a65, 0x5c21, + 0x6035, 0x7c2c, 0x7c2d, 0x5827, 0x6d38, 0x5b36, 0x5670, 0x732f, + 0x4d25, 0x5a71, 0x5828, 0x4c64, 0x5134, 0x4a58, 0x5a72, 0x7527, + 0x7528, 0x6626, 0x556c, 0x5578, 0x5a73, 0x6346, 0x5e64, 0x5e65, + 0x5135, 0x5136, 0x5137, 0x7233, 0x695e, 0x7053, 0x7234, 0x7054, + 0x4b64, 0x7b54, 0x7566, 0x636a, 0x5e66, 0x5f54, 0x7879, 0x702e, + 0x5138, 0x565f, 0x5057, 0x7c21, 0x6f6e, 0x5c58, 0x695f, 0x655d, + 0x7d7b, 0x6049, 0x5649, 0x542a, 0x654c, 0x6960, 0x5058, 0x7c22, + 0x543e, 0x6233, 0x5e67, 0x5c3c, 0x5236, 0x7555, 0x4e21, 0x7529, + 0x5d79, 0x5d7a, 0x7055, 0x765f, 0x725a, 0x646b, 0x7271, 0x6c39, + 0x7d7c, 0x612a, 0x4a59, 0x6f6f, 0x752a, 0x6c79, 0x782d, 0x7242, + 0x7643, 0x5752, 0x7922, 0x7056, 0x707a, 0x7660, 0x6973, 0x7243, + 0x542b, 0x4a33, 0x4d26, 0x4d43, 0x4d5a, 0x594f, 0x7644, 0x6e5d, + 0x6744, 0x6234, 0x5f62, 0x675b, 0x6831, 0x7c2e, 0x654d, 0x7a6b, + 0x4f3c, 0x4f62, 0x4d76, 0x6f70, 0x743e, 0x544d, 0x7338, 0x6921, + 0x7272, 0x736b, 0x7057, 0x4f57, 0x4f5f, 0x6840, 0x6841, 0x4f63, + 0x6922, 0x502a, 0x7341, 0x502b, 0x5464, 0x6f3c, 0x5821, 0x595f, + 0x7357, 0x5c3d, 0x4c65, 0x6d71, 0x7162, 0x545b, 0x6235, 0x4a66, + 0x532e, 0x4c66, 0x7153, 0x7567, 0x4a5a, 0x7b6e, 0x6145, 0x5f69, + 0x6e5e, 0x7742, 0x5822, 0x5d2c, 0x702f, 0x563d, 0x612b, 0x7936, + 0x5475, 0x5049, 0x6f27, 0x626c, 0x5b6a, 0x4e4c, 0x7568, 0x7755, + 0x534d, 0x737e, 0x5035, 0x607e, 0x5f7b, 0x665d, 0x6824, 0x4b4d, + 0x6f28, 0x6e34, 0x5a58, 0x5139, 0x5f29, 0x7330, 0x4c44, 0x4e37, + 0x6f29, 0x5f55, 0x6d57, 0x6e46, 0x6f3d, 0x7c56, 0x5b74, 0x6f2a, + 0x7839, 0x7569, 0x6359, 0x6146, 0x543f, 0x5e68, 0x706a, 0x7342, + 0x532f, 0x4a5b, 0x7c57, 0x6d58, 0x6147, 0x7458, 0x5633, 0x5d2d, + 0x553e, 0x7143, 0x6e5f, 0x566b, 0x7459, 0x5766, 0x5a37, 0x5d7b, + 0x5d4f, 0x5823, 0x5a59, 0x7058, 0x6f44, 0x6158, 0x7154, 0x6d72, + 0x555b, 0x555c, 0x7344, 0x4b57, 0x6236, 0x6f71, 0x7b55, 0x5358, + 0x5d50, 0x7059, 0x4b33, 0x555d, 0x4d27, 0x502c, 0x513a, 0x7144, + 0x6533, 0x7b75, 0x6961, 0x7d60, 0x7c3c, 0x5a22, 0x5a23, 0x5221, + 0x526f, 0x626d, 0x5e69, 0x4e5c, 0x7235, 0x5064, 0x5d51, 0x6148, + 0x5b37, 0x5f63, 0x6d39, 0x7145, 0x734f, 0x572b, 0x612c, 0x636b, + 0x6e47, 0x6149, 0x4a7a, 0x707b, 0x7a61, 0x705a, 0x4c67, 0x5a74, + 0x4c3f, 0x4e6d, 0x5529, 0x7a62, 0x5065, 0x6b56, 0x6c5f, 0x5f7c, + 0x7756, 0x5e6a, 0x4b34, 0x6f3e, 0x4c35, 0x4f3d, 0x6f72, 0x6237, + 0x4c68, 0x707c, 0x5660, 0x7146, 0x6238, 0x6b2b, 0x4b35, 0x5851, + 0x744e, 0x7377, 0x5746, 0x513b, 0x772a, 0x6d4a, 0x5753, 0x587a, + 0x7645, 0x514c, 0x5d7c, 0x5f7d, 0x7965, 0x604a, 0x727d, 0x5330, + 0x7473, 0x5a49, 0x665e, 0x783a, 0x6850, 0x587b, 0x6a55, 0x5623, + 0x7646, 0x725b, 0x647c, 0x6832, 0x5a5a, 0x725c, 0x7b56, 0x6932, + 0x6e2d, 0x7a63, 0x5c6e, 0x756a, 0x6660, 0x707d, 0x572c, 0x7545, + 0x6e60, 0x5b65, 0x5d5e, 0x5970, 0x6923, 0x7179, 0x7244, 0x604b, + 0x6924, 0x6239, 0x6331, 0x7c6b, 0x4d28, 0x4c36, 0x705b, 0x663a, + 0x4d29, 0x7343, 0x6159, 0x6f2b, 0x6745, 0x6069, 0x7345, 0x5440, + 0x553f, 0x5d2e, 0x797c, 0x4c40, 0x6522, 0x4e38, 0x5852, 0x7956, + 0x712a, 0x4e51, 0x7647, 0x5b6b, 0x5f7e, 0x5861, 0x7773, 0x5767, + 0x547e, 0x513c, 0x654f, 0x4b36, 0x5a38, 0x4d44, 0x563e, 0x623a, + 0x4f58, 0x604c, 0x6b79, 0x7d7d, 0x5768, 0x4b58, 0x6962, 0x683a, + 0x6347, 0x6c4d, 0x6c4e, 0x563f, 0x6327, 0x5f56, 0x7d68, 0x6e61, + 0x7628, 0x5d7d, 0x783b, 0x6851, 0x7957, 0x4e6e, 0x6c4f, 0x6925, + 0x5655, 0x4d45, 0x6d3a, 0x513d, 0x4f3e, 0x6c3b, 0x5231, 0x4c69, + 0x5944, 0x697c, 0x513e, 0x6c3c, 0x652d, 0x7730, 0x4c6a, 0x5344, + 0x5640, 0x567d, 0x6121, 0x5e3d, 0x7629, 0x5a24, 0x5624, 0x7546, + 0x6122, 0x6946, 0x7245, 0x7469, 0x566c, 0x6b53, 0x6c3d, 0x625c, + 0x5e6b, 0x705c, 0x6b3f, 0x574e, 0x513f, 0x752b, 0x797d, 0x4a5c, + 0x4d46, 0x7236, 0x5d7e, 0x4c37, 0x5b38, 0x5069, 0x4e5d, 0x6b40, + 0x7d22, 0x784b, 0x6a56, 0x7130, 0x5b4e, 0x7743, 0x5b4f, 0x4b24, + 0x7860, 0x7b57, 0x6b4a, 0x6021, 0x4e4d, 0x545c, 0x7d58, 0x5276, + 0x7237, 0x7a76, 0x762a, 0x7a77, 0x5866, 0x7431, 0x6852, 0x4a45, + 0x4c6b, 0x626e, 0x623b, 0x772d, 0x7861, 0x736c, 0x5e21, 0x647d, + 0x636c, 0x5d2f, 0x5d30, 0x4b37, 0x6853, 0x6123, 0x5260, 0x707e, + 0x6926, 0x4b72, 0x6d73, 0x5c59, 0x604d, 0x775a, 0x5b39, 0x4c2e, + 0x5a5b, 0x4d47, 0x5d31, 0x582f, 0x6323, 0x4e6f, 0x7273, 0x7833, + 0x604e, 0x757d, 0x6b6c, 0x5345, 0x7c6c, 0x525b, 0x546b, 0x5e22, + 0x6566, 0x7030, 0x5544, 0x6d74, 0x636d, 0x6842, 0x6d75, 0x577c, + 0x6d3b, 0x762b, 0x7238, 0x7648, 0x5366, 0x725d, 0x4f3f, 0x6b2c, + 0x4f40, 0x6628, 0x7d69, 0x4f41, 0x605f, 0x5e6c, 0x6022, 0x743f, + 0x626f, 0x5971, 0x7147, 0x4b38, 0x797e, 0x5b3a, 0x5a75, 0x766c, + 0x5a5c, 0x7a64, 0x604f, 0x5d32, 0x6629, 0x6f73, 0x736d, 0x6b7a, + 0x7966, 0x4a5d, 0x555e, 0x4a5e, 0x5f64, 0x667d, 0x752c, 0x6475, + 0x6963, 0x6d4b, 0x4f64, 0x5853, 0x5d33, 0x546c, 0x7239, 0x5f37, + 0x4b4e, 0x7b58, 0x5059, 0x5d52, 0x7774, 0x675c, 0x6425, 0x7c23, + 0x5b3b, 0x723a, 0x697d, 0x504a, 0x7556, 0x5945, 0x6434, 0x6d27, + 0x6a3d, 0x667e, 0x7744, 0x752d, 0x5960, 0x4a34, 0x7862, 0x4f42, + 0x6c3e, 0x6534, 0x4d48, 0x6e48, 0x6748, 0x4d49, 0x7937, 0x7168, + 0x5972, 0x5b75, 0x4a35, 0x5946, 0x5849, 0x592b, 0x6d3c, 0x5854, + 0x5c5a, 0x623c, 0x7c6d, 0x6c60, 0x527e, 0x6947, 0x662a, 0x6270, + 0x7a3b, 0x752e, 0x7b2a, 0x6c7b, 0x6c3f, 0x7c58, 0x5465, 0x7943, + 0x6e62, 0x5769, 0x6d76, 0x5e6d, 0x4c6c, 0x636e, 0x6854, 0x7a78, + 0x5d34, 0x6435, 0x5830, 0x5855, 0x746a, 0x4e39, 0x5661, 0x4f52, + 0x5036, 0x4e22, 0x736e, 0x7378, 0x5c4c, 0x504b, 0x7c24, 0x4d4a, + 0x5754, 0x5e23, 0x6460, 0x6e49, 0x625d, 0x757e, 0x542c, 0x5551, + 0x5870, 0x7843, 0x6a57, 0x7557, 0x583f, 0x7d40, 0x6b2d, 0x552a, + 0x6728, 0x6e4a, 0x4a67, 0x7863, 0x545d, 0x6a58, 0x7b59, 0x6d77, + 0x6535, 0x502d, 0x7171, 0x623d, 0x6348, 0x5955, 0x5f2a, 0x5b3c, + 0x7864, 0x717a, 0x6536, 0x736f, 0x7b5a, 0x6160, 0x592c, 0x756b, + 0x6036, 0x6948, 0x4b4f, 0x6349, 0x5e6e, 0x623e, 0x5c6f, 0x5625, + 0x6271, 0x567e, 0x5921, 0x5840, 0x5c5b, 0x6d3d, 0x5f38, 0x6a25, + 0x572d, 0x7379, 0x6d78, 0x7547, 0x614a, 0x6b63, 0x725e, 0x784c, + 0x6a59, 0x5346, 0x5b66, 0x752f, 0x4e70, 0x697e, 0x7b36, 0x6272, + 0x4f72, 0x7739, 0x5973, 0x614b, 0x5a5d, 0x5a39, 0x6b7b, 0x4b39, + 0x6d79, 0x6060, 0x7440, 0x7d3c, 0x5f31, 0x636f, 0x6023, 0x7d39, + 0x7031, 0x4d4b, 0x6d3e, 0x5540, 0x6370, 0x6d7a, 0x6964, 0x556d, + 0x675d, 0x5476, 0x6537, 0x5b67, 0x623f, 0x6e4b, 0x5774, 0x705d, + 0x4e2b, 0x675e, 0x5656, 0x614c, 0x6833, 0x656e, 0x5c22, 0x6050, + 0x5535, 0x5521, 0x7b5b, 0x794b, 0x4b73, 0x7425, 0x7a48, 0x5657, + 0x6965, 0x7b5c, 0x7d50, 0x7b76, 0x5a25, 0x5b3d, 0x6c62, 0x4d77, + 0x705e, 0x7649, 0x5e6f, 0x5331, 0x7c6e, 0x6843, 0x7148, 0x4e71, + 0x796d, 0x7274, 0x6436, 0x7539, 0x5c70, 0x6371, 0x6825, 0x723b, + 0x5e24, 0x5a4c, 0x4a69, 0x635a, 0x7c59, 0x6a5a, 0x7944, 0x6324, + 0x7b5d, 0x6f4a, 0x6844, 0x554c, 0x6b57, 0x592d, 0x7b2b, 0x5359, + 0x5522, 0x765e, 0x5a76, 0x6051, 0x6928, 0x7579, 0x7a2f, 0x6b7c, + 0x606a, 0x6332, 0x5545, 0x7163, 0x556e, 0x4d4c, 0x6d59, 0x5841, + 0x7a6c, 0x716b, 0x7a3c, 0x6662, 0x7a65, 0x627a, 0x4a36, 0x6437, + 0x6a5b, 0x757a, 0x7b2c, 0x4f43, 0x6b7d, 0x787a, 0x5f39, 0x6171, + 0x5224, 0x757b, 0x505a, 0x505b, 0x6a3e, 0x5931, 0x4a37, 0x5367, + 0x7865, 0x5332, 0x6240, 0x725f, 0x4d65, 0x792c, 0x4d4d, 0x6e2e, + 0x562e, 0x576a, 0x6760, 0x6b2e, 0x4f59, 0x5c4d, 0x6d7b, 0x5e70, + 0x576b, 0x5e25, 0x5f57, 0x5b50, 0x5b51, 0x5523, 0x7032, 0x5c5c, + 0x4a68, 0x7866, 0x5c4e, 0x6a5c, 0x5b52, 0x6933, 0x775b, 0x6328, + 0x572e, 0x6061, 0x4b3a, 0x6551, 0x505c, 0x5541, 0x584a, 0x6329, + 0x6024, 0x6929, 0x5347, 0x5c5d, 0x782e, 0x4c38, 0x502e, 0x5872, + 0x634a, 0x4c2f, 0x542d, 0x7651, 0x504c, 0x4a46, 0x5542, 0x4e3a, + 0x4a47, 0x7a30, 0x5f58, 0x753a, 0x656b, 0x6f74, 0x5d35, 0x4d2a, + 0x6372, 0x7b77, 0x7750, 0x7d3a, 0x7d61, 0x767e, 0x5140, 0x6845, + 0x6438, 0x6168, 0x4c41, 0x526d, 0x5b3e, 0x6062, 0x7a49, 0x614d, + 0x4a38, 0x7260, 0x7149, 0x5e71, 0x705f, 0x7844, 0x6e4c, 0x5e72, + 0x6749, 0x6273, 0x6761, 0x634b, 0x634c, 0x4f78, 0x6f2c, 0x7d7e, + 0x7c25, 0x7a31, 0x5f59, 0x6052, 0x745a, 0x714a, 0x4e23, 0x723c, + 0x6c63, 0x6025, 0x772b, 0x6b2f, 0x655e, 0x6124, 0x4d2b, 0x5974, + 0x6826, 0x4d4e, 0x6169, 0x7c6f, 0x6063, 0x6241, 0x4e24, 0x5e26, + 0x6b7e, 0x6b5d, 0x7060, 0x745b, 0x6274, 0x5348, 0x746b, 0x6e35, + 0x7558, 0x555f, 0x5665, 0x6b30, 0x7463, 0x634d, 0x7474, 0x7a32, + 0x6f75, 0x4a5f, 0x6b31, 0x6d3f, 0x7d49, 0x6426, 0x7924, 0x7033, + 0x656c, 0x5167, 0x5947, 0x6457, 0x6a5d, 0x5477, 0x5a3a, 0x5a4d, + 0x794c, 0x615a, 0x5b3f, 0x4c45, 0x6c50, 0x4b3b, 0x5e73, 0x692a, + 0x5948, 0x6e63, 0x573d, 0x4f44, 0x504d, 0x7c26, 0x717b, 0x7d52, + 0x5141, 0x635b, 0x5349, 0x5c4f, 0x4c6d, 0x5e27, 0x663b, 0x6c21, + 0x4c39, 0x7b5e, 0x6762, 0x5441, 0x5c28, 0x6242, 0x7358, 0x6553, + 0x7359, 0x7346, 0x4d5b, 0x4d2c, 0x7c43, 0x5467, 0x5142, 0x7925, + 0x6855, 0x634e, 0x544a, 0x5f5a, 0x7b5f, 0x6763, 0x787b, 0x634f, + 0x7530, 0x5867, 0x5949, 0x782f, 0x6f76, 0x5d36, 0x6e2f, 0x4d78, + 0x5e38, 0x7c27, 0x777c, 0x7731, 0x4e3b, 0x7421, 0x6e4d, 0x612e, + 0x6c43, 0x4f7e, 0x783f, 0x5862, 0x5368, 0x5e28, 0x7464, 0x6c42, + 0x5975, 0x7945, 0x5d53, 0x5671, 0x6c7c, 0x7c70, 0x6d40, 0x4a39, + 0x6e64, 0x7261, 0x5e39, 0x5672, 0x5e74, 0x5f5b, 0x5b53, 0x7a67, + 0x5863, 0x7441, 0x5d37, 0x7275, 0x542e, 0x5673, 0x5d38, 0x4f45, + 0x5f5f, 0x723e, 0x7621, 0x6b4b, 0x717c, 0x7347, 0x606b, 0x6d7c, + 0x615b, 0x6e65, 0x5e75, 0x7a53, 0x714b, 0x502f, 0x5d39, 0x5143, + 0x7531, 0x6a46, 0x7061, 0x762c, 0x7559, 0x706b, 0x5d3a, 0x723f, + 0x7745, 0x5b22, 0x7276, 0x4a3a, 0x7775, 0x4b65, 0x6e66, 0x6053, + 0x4e25, 0x5658, 0x542f, 0x6949, 0x534e, 0x7442, 0x4b66, 0x7121, + 0x6b32, 0x7122, 0x6b33, 0x7034, 0x4b74, 0x5430, 0x7332, 0x7b37, + 0x756c, 0x6e67, 0x7432, 0x756d, 0x4f73, 0x7062, 0x6e4e, 0x714c, + 0x6538, 0x5775, 0x6373, 0x4f65, 0x4f46, 0x7333, 0x6458, 0x4f79, + 0x4f5a, 0x7a4d, 0x6663, 0x7262, 0x756e, 0x4a3b, 0x635c, 0x4e72, + 0x5659, 0x6e30, 0x7465, 0x5842, 0x5c50, 0x4c6e, 0x5560, 0x764a, + 0x7d4a, 0x5856, 0x744f, 0x5626, 0x5c3e, 0x5b54, 0x5747, 0x727e, + 0x714d, 0x6243, 0x5c5e, 0x5c5f, 0x6f2d, 0x662b, 0x795d, 0x6a3f, + 0x6f2e, 0x7450, 0x4e73, 0x662c, 0x4e5e, 0x5579, 0x6374, 0x4d50, + 0x5538, 0x777d, 0x5c29, 0x5e76, 0x5c2a, 0x7263, 0x6934, 0x525c, + 0x6966, 0x6376, 0x674a, 0x504e, 0x5a77, 0x4a3c, 0x6e68, 0x5a5e, + 0x7277, 0x627b, 0x4c26, 0x5a3b, 0x6e69, 0x755a, 0x775c, 0x616a, + 0x4e41, 0x5431, 0x7d31, 0x663d, 0x7b2d, 0x7867, 0x614e, 0x7762, + 0x756f, 0x4f47, 0x5432, 0x4c6f, 0x5468, 0x6e4f, 0x7757, 0x6026, + 0x5641, 0x615c, 0x7063, 0x7164, 0x5c71, 0x5627, 0x7475, 0x714e, + 0x7264, 0x5030, 0x6c6f, 0x793a, 0x6b35, 0x546d, 0x6244, 0x6967, + 0x6b34, 0x6a21, 0x783c, 0x4e26, 0x7946, 0x7c5a, 0x5433, 0x5339, + 0x6a5e, 0x692b, 0x6161, 0x534f, 0x7476, 0x6a40, 0x614f, 0x4c3a, + 0x6e6a, 0x7064, 0x7334, 0x546e, 0x7240, 0x7165, 0x7443, 0x6054, + 0x6b36, 0x5721, 0x4b68, 0x792d, 0x692d, 0x5864, 0x7a33, 0x6245, + 0x7c3d, 0x6c44, 0x5831, 0x5c2b, 0x5524, 0x6b69, 0x683b, 0x5857, + 0x7b2e, 0x5161, 0x5b40, 0x753e, 0x5e77, 0x4a7b, 0x7746, 0x4f48, + 0x6150, 0x6e50, 0x6974, 0x4e74, 0x554d, 0x4f5b, 0x5d3b, 0x4e2c, + 0x6968, 0x5434, 0x6447, 0x755b, 0x7a41, 0x5e29, 0x5478, 0x6f77, + 0x5333, 0x6b37, 0x6f78, 0x755c, 0x6d4c, 0x5b55, 0x714f, 0x7150, + 0x7532, 0x592e, 0x552c, 0x6246, 0x7d23, 0x7b65, 0x5f2b, 0x6275, + 0x762d, 0x7533, 0x7035, 0x6125, 0x755d, 0x6c22, 0x6d7d, 0x7534, + 0x7b38, 0x5b23, 0x564a, 0x4b59, 0x6554, 0x737a, 0x6b38, 0x6037, + 0x576c, 0x716c, 0x652f, 0x5561, 0x576d, 0x5151, 0x6172, 0x6f79, + 0x5d3c, 0x765c, 0x7065, 0x7444, 0x6969, 0x737b, 0x546f, 0x4c22, + 0x777e, 0x5f3c, 0x6b4d, 0x5037, 0x5642, 0x682d, 0x6f2f, 0x4b25, + 0x4b69, 0x7a68, 0x4c46, 0x6667, 0x6a47, 0x5b24, 0x4f49, 0x627c, + 0x6f7a, 0x6b5e, 0x7548, 0x545e, 0x6055, 0x6f30, 0x6247, 0x592f, + 0x7967, 0x6765, 0x4f4a, 0x6151, 0x6248, 0x6f7b, 0x7a79, 0x5c72, + 0x6027, 0x7868, 0x4b6a, 0x4b3c, 0x5662, 0x755e, 0x755f, 0x6e36, + 0x6276, 0x534a, 0x6f7c, 0x5144, 0x6f31, 0x5145, 0x505e, 0x5961, + 0x6038, 0x4d51, 0x7339, 0x674c, 0x5628, 0x4e27, 0x5435, 0x6448, + 0x5334, 0x6b39, 0x4b75, 0x765d, 0x7123, 0x4c47, 0x694a, 0x6170, + 0x7560, 0x7b2f, 0x4b51, 0x7b60, 0x7265, 0x6c70, 0x706c, 0x6e6b, + 0x694b, 0x4c70, 0x572f, 0x7321, 0x7c75, 0x7124, 0x6056, 0x6f32, + 0x7451, 0x7721, 0x7151, 0x4a7c, 0x4a7d, 0x4e4e, 0x7348, 0x733a, + 0x6d7e, 0x5a26, 0x606c, 0x784d, 0x4b52, 0x6b4e, 0x7958, 0x7959, + 0x4a60, 0x5a4a, 0x4b26, 0x4a48, 0x796e, 0x5b6c, 0x5031, 0x556f, + 0x6673, 0x6722, 0x6459, 0x6461, 0x7c44, 0x796f, 0x4f74, 0x7766, + 0x4e3c, 0x7445, 0x5c23, 0x5d3d, 0x7446, 0x7821, 0x6856, 0x5b41, + 0x7066, 0x6439, 0x766d, 0x792e, 0x5d3e, 0x5730, 0x5868, 0x4b3d, + 0x795a, 0x784e, 0x7970, 0x606d, 0x6333, 0x7433, 0x6a42, 0x7266, + 0x7036, 0x5b56, 0x6b64, 0x7267, 0x5755, 0x5436, 0x7968, 0x5741, + 0x6555, 0x696a, 0x574c, 0x5369, 0x6249, 0x7c5b, 0x4d2d, 0x4c30, + 0x6a22, 0x6476, 0x5040, 0x7037, 0x6e21, 0x5776, 0x624a, 0x624b, + 0x7a4f, 0x6b5f, 0x564b, 0x7434, 0x6d4d, 0x6452, 0x6a29, 0x643a, + 0x7322, 0x4d52, 0x764b, 0x7166, 0x6d41, 0x683c, 0x6e51, 0x7067, + 0x624c, 0x642a, 0x7561, 0x6d5a, 0x576e, 0x5171, 0x696b, 0x696c, + 0x6064, 0x5a27, 0x5d54, 0x6a23, 0x5643, 0x5674, 0x5a5f, 0x6f33, + 0x624d, 0x6f7d, 0x7268, 0x6f45, 0x6767, 0x577d, 0x674e, 0x5f5c, + 0x7947, 0x5976, 0x5f2c, 0x565a, 0x5c24, 0x7038, 0x557a, 0x6477, + 0x5644, 0x746c, 0x6f7e, 0x7021, 0x5e2a, 0x5a3c, 0x587c, 0x7a54, + 0x6c65, 0x7c28, 0x6c66, 0x584b, 0x7b39, 0x6453, 0x4d79, 0x4f53, + 0x4a6a, 0x4f54, 0x783d, 0x7447, 0x6a5f, 0x795b, 0x5437, 0x6b65, + 0x6152, 0x6a24, 0x7a42, 0x7b61, 0x7a6d, 0x7022, 0x4c71, 0x7a23, + 0x6277, 0x624e, 0x6975, 0x616b, 0x6768, 0x6857, 0x5a78, 0x544b, + 0x7776, 0x5645, 0x5469, 0x7a7a, 0x4c72, 0x775d, 0x5e3a, 0x4e28, + 0x7039, 0x647e, 0x6449, 0x6454, 0x6a43, 0x6f34, 0x573e, 0x7b62, + 0x4d53, 0x6f35, 0x7a69, 0x7926, 0x5f3d, 0x7747, 0x787d, 0x787c, + 0x5e2b, 0x5b68, 0x635d, 0x6162, 0x5146, 0x7650, 0x6b66, 0x5a79, + 0x6c47, 0x5e78, 0x7869, 0x635e, 0x4e75, 0x7a43, 0x6557, 0x6c48, + 0x7349, 0x643b, 0x662e, 0x6f36, 0x5c3f, 0x4e3d, 0x5843, 0x504f, + 0x4f7a, 0x734a, 0x6057, 0x5147, 0x692e, 0x683d, 0x7a44, 0x624f, + 0x7a45, 0x7938, 0x5c60, 0x7b30, 0x5829, 0x655f, 0x7927, 0x766e, + 0x764c, 0x6278, 0x6c71, 0x5a60, 0x7152, 0x524c, 0x4f4b, 0x4a3d, + 0x5d3f, 0x766f, 0x5e79, 0x7a34, 0x552d, 0x7167, 0x5e3e, 0x5c40, + 0x5148, 0x5149, 0x783e, 0x4b76, 0x5479, 0x7562, 0x6153, 0x5869, + 0x787e, 0x4f4c, 0x7d24, 0x4e76, 0x7a50, 0x4c73, 0x663e, 0x762e, + 0x5570, 0x514a, 0x7c3e, 0x5571, 0x4d69, 0x7a35, 0x6250, 0x7477, + 0x4d54, 0x6723, 0x5b25, 0x6251, 0x5722, 0x7763, 0x6a26, 0x5021, + 0x4e5a, 0x7b6b, 0x5b26, 0x5b5e, 0x5865, 0x6a60, 0x582a, 0x6560, + 0x565b, 0x6f46, 0x786a, 0x6455, 0x4e77, 0x6058, 0x576f, 0x746d, + 0x4d66, 0x4c74, 0x7563, 0x644a, 0x5c61, 0x7948, 0x7c3f, 0x6827, + 0x5844, 0x4b3e, 0x5c2e, 0x5777, 0x7068, 0x5d40, 0x4f4d, 0x5c73, + 0x5930, 0x6669, 0x643c, 0x6a44, 0x646c, 0x6465, 0x7b78, 0x4c3b, + 0x643d, 0x4d5c, 0x5977, 0x5d5f, 0x6d4e, 0x5950, 0x6523, 0x794d, + 0x4d2e, 0x4f4e, 0x762f, 0x7d53, 0x6b6d, 0x565c, 0x6524, 0x5536, + 0x565d, 0x7969, 0x6724, 0x5663, 0x514b, 0x5664, 0x5572, 0x5e7a, + 0x5778, 0x586a, 0x4f55, 0x587d, 0x582b, 0x7d4b, 0x7c5c, 0x6028, + 0x5573, 0x7d59, 0x4c23, 0x5979, 0x536a, 0x7575, 0x6f47, 0x535a, + 0x5a3d, 0x6828, 0x5c2f, 0x7023, 0x4d55, 0x6029, 0x5e2c, 0x703a, + 0x6e31, 0x6e32, 0x764d, 0x6e52, 0x5646, 0x6065, 0x733b, 0x6561, + 0x644b, 0x5723, 0x5b42, 0x4a7e, 0x4f4f, 0x3021, 0x3022, 0x3023, + 0x3024, 0x3025, 0x3026, 0x3027, 0x3028, 0x3029, 0x302a, 0x302b, + 0x302c, 0x302d, 0x302e, 0x302f, 0x3030, 0x3031, 0x3032, 0x3033, + 0x3034, 0x3035, 0x3036, 0x3037, 0x3038, 0x3039, 0x303a, 0x303b, + 0x303c, 0x303d, 0x303e, 0x303f, 0x3040, 0x3041, 0x3042, 0x3043, + 0x3044, 0x3045, 0x3046, 0x3047, 0x3048, 0x3049, 0x304a, 0x304b, + 0x304c, 0x304d, 0x304e, 0x304f, 0x3050, 0x3051, 0x3052, 0x3053, + 0x3054, 0x3055, 0x3056, 0x3057, 0x3058, 0x3059, 0x305a, 0x305b, + 0x305c, 0x305d, 0x305e, 0x305f, 0x3060, 0x3061, 0x3062, 0x3063, + 0x3064, 0x3065, 0x3066, 0x3067, 0x3068, 0x3069, 0x306a, 0x306b, + 0x306c, 0x306d, 0x306e, 0x306f, 0x3070, 0x3071, 0x3072, 0x3073, + 0x3074, 0x3075, 0x3076, 0x3077, 0x3078, 0x3079, 0x307a, 0x307b, + 0x307c, 0x307d, 0x307e, 0x3121, 0x3122, 0x3123, 0x3124, 0x3125, + 0x3126, 0x3127, 0x3128, 0x3129, 0x312a, 0x312b, 0x312c, 0x312d, + 0x312e, 0x312f, 0x3130, 0x3131, 0x3132, 0x3133, 0x3134, 0x3135, + 0x3136, 0x3137, 0x3138, 0x3139, 0x313a, 0x313b, 0x313c, 0x313d, + 0x313e, 0x313f, 0x3140, 0x3141, 0x3142, 0x3143, 0x3144, 0x3145, + 0x3146, 0x3147, 0x3148, 0x3149, 0x314a, 0x314b, 0x314c, 0x314d, + 0x314e, 0x314f, 0x3150, 0x3151, 0x3152, 0x3153, 0x3154, 0x3155, + 0x3156, 0x3157, 0x3158, 0x3159, 0x315a, 0x315b, 0x315c, 0x315d, + 0x315e, 0x315f, 0x3160, 0x3161, 0x3162, 0x3163, 0x3164, 0x3165, + 0x3166, 0x3167, 0x3168, 0x3169, 0x316a, 0x316b, 0x316c, 0x316d, + 0x316e, 0x316f, 0x3170, 0x3171, 0x3172, 0x3173, 0x3174, 0x3175, + 0x3176, 0x3177, 0x3178, 0x3179, 0x317a, 0x317b, 0x317c, 0x317d, + 0x317e, 0x3221, 0x3222, 0x3223, 0x3224, 0x3225, 0x3226, 0x3227, + 0x3228, 0x3229, 0x322a, 0x322b, 0x322c, 0x322d, 0x322e, 0x322f, + 0x3230, 0x3231, 0x3232, 0x3233, 0x3234, 0x3235, 0x3236, 0x3237, + 0x3238, 0x3239, 0x323a, 0x323b, 0x323c, 0x323d, 0x323e, 0x323f, + 0x3240, 0x3241, 0x3242, 0x3243, 0x3244, 0x3245, 0x3246, 0x3247, + 0x3248, 0x3249, 0x324a, 0x324b, 0x324c, 0x324d, 0x324e, 0x324f, + 0x3250, 0x3251, 0x3252, 0x3253, 0x3254, 0x3255, 0x3256, 0x3257, + 0x3258, 0x3259, 0x325a, 0x325b, 0x325c, 0x325d, 0x325e, 0x325f, + 0x3260, 0x3261, 0x3262, 0x3263, 0x3264, 0x3265, 0x3266, 0x3267, + 0x3268, 0x3269, 0x326a, 0x326b, 0x326c, 0x326d, 0x326e, 0x326f, + 0x3270, 0x3271, 0x3272, 0x3273, 0x3274, 0x3275, 0x3276, 0x3277, + 0x3278, 0x3279, 0x327a, 0x327b, 0x327c, 0x327d, 0x327e, 0x3321, + 0x3322, 0x3323, 0x3324, 0x3325, 0x3326, 0x3327, 0x3328, 0x3329, + 0x332a, 0x332b, 0x332c, 0x332d, 0x332e, 0x332f, 0x3330, 0x3331, + 0x3332, 0x3333, 0x3334, 0x3335, 0x3336, 0x3337, 0x3338, 0x3339, + 0x333a, 0x333b, 0x333c, 0x333d, 0x333e, 0x333f, 0x3340, 0x3341, + 0x3342, 0x3343, 0x3344, 0x3345, 0x3346, 0x3347, 0x3348, 0x3349, + 0x334a, 0x334b, 0x334c, 0x334d, 0x334e, 0x334f, 0x3350, 0x3351, + 0x3352, 0x3353, 0x3354, 0x3355, 0x3356, 0x3357, 0x3358, 0x3359, + 0x335a, 0x335b, 0x335c, 0x335d, 0x335e, 0x335f, 0x3360, 0x3361, + 0x3362, 0x3363, 0x3364, 0x3365, 0x3366, 0x3367, 0x3368, 0x3369, + 0x336a, 0x336b, 0x336c, 0x336d, 0x336e, 0x336f, 0x3370, 0x3371, + 0x3372, 0x3373, 0x3374, 0x3375, 0x3376, 0x3377, 0x3378, 0x3379, + 0x337a, 0x337b, 0x337c, 0x337d, 0x337e, 0x3421, 0x3422, 0x3423, + 0x3424, 0x3425, 0x3426, 0x3427, 0x3428, 0x3429, 0x342a, 0x342b, + 0x342c, 0x342d, 0x342e, 0x342f, 0x3430, 0x3431, 0x3432, 0x3433, + 0x3434, 0x3435, 0x3436, 0x3437, 0x3438, 0x3439, 0x343a, 0x343b, + 0x343c, 0x343d, 0x343e, 0x343f, 0x3440, 0x3441, 0x3442, 0x3443, + 0x3444, 0x3445, 0x3446, 0x3447, 0x3448, 0x3449, 0x344a, 0x344b, + 0x344c, 0x344d, 0x344e, 0x344f, 0x3450, 0x3451, 0x3452, 0x3453, + 0x3454, 0x3455, 0x3456, 0x3457, 0x3458, 0x3459, 0x345a, 0x345b, + 0x345c, 0x345d, 0x345e, 0x345f, 0x3460, 0x3461, 0x3462, 0x3463, + 0x3464, 0x3465, 0x3466, 0x3467, 0x3468, 0x3469, 0x346a, 0x346b, + 0x346c, 0x346d, 0x346e, 0x346f, 0x3470, 0x3471, 0x3472, 0x3473, + 0x3474, 0x3475, 0x3476, 0x3477, 0x3478, 0x3479, 0x347a, 0x347b, + 0x347c, 0x347d, 0x347e, 0x3521, 0x3522, 0x3523, 0x3524, 0x3525, + 0x3526, 0x3527, 0x3528, 0x3529, 0x352a, 0x352b, 0x352c, 0x352d, + 0x352e, 0x352f, 0x3530, 0x3531, 0x3532, 0x3533, 0x3534, 0x3535, + 0x3536, 0x3537, 0x3538, 0x3539, 0x353a, 0x353b, 0x353c, 0x353d, + 0x353e, 0x353f, 0x3540, 0x3541, 0x3542, 0x3543, 0x3544, 0x3545, + 0x3546, 0x3547, 0x3548, 0x3549, 0x354a, 0x354b, 0x354c, 0x354d, + 0x354e, 0x354f, 0x3550, 0x3551, 0x3552, 0x3553, 0x3554, 0x3555, + 0x3556, 0x3557, 0x3558, 0x3559, 0x355a, 0x355b, 0x355c, 0x355d, + 0x355e, 0x355f, 0x3560, 0x3561, 0x3562, 0x3563, 0x3564, 0x3565, + 0x3566, 0x3567, 0x3568, 0x3569, 0x356a, 0x356b, 0x356c, 0x356d, + 0x356e, 0x356f, 0x3570, 0x3571, 0x3572, 0x3573, 0x3574, 0x3575, + 0x3576, 0x3577, 0x3578, 0x3579, 0x357a, 0x357b, 0x357c, 0x357d, + 0x357e, 0x3621, 0x3622, 0x3623, 0x3624, 0x3625, 0x3626, 0x3627, + 0x3628, 0x3629, 0x362a, 0x362b, 0x362c, 0x362d, 0x362e, 0x362f, + 0x3630, 0x3631, 0x3632, 0x3633, 0x3634, 0x3635, 0x3636, 0x3637, + 0x3638, 0x3639, 0x363a, 0x363b, 0x363c, 0x363d, 0x363e, 0x363f, + 0x3640, 0x3641, 0x3642, 0x3643, 0x3644, 0x3645, 0x3646, 0x3647, + 0x3648, 0x3649, 0x364a, 0x364b, 0x364c, 0x364d, 0x364e, 0x364f, + 0x3650, 0x3651, 0x3652, 0x3653, 0x3654, 0x3655, 0x3656, 0x3657, + 0x3658, 0x3659, 0x365a, 0x365b, 0x365c, 0x365d, 0x365e, 0x365f, + 0x3660, 0x3661, 0x3662, 0x3663, 0x3664, 0x3665, 0x3666, 0x3667, + 0x3668, 0x3669, 0x366a, 0x366b, 0x366c, 0x366d, 0x366e, 0x366f, + 0x3670, 0x3671, 0x3672, 0x3673, 0x3674, 0x3675, 0x3676, 0x3677, + 0x3678, 0x3679, 0x367a, 0x367b, 0x367c, 0x367d, 0x367e, 0x3721, + 0x3722, 0x3723, 0x3724, 0x3725, 0x3726, 0x3727, 0x3728, 0x3729, + 0x372a, 0x372b, 0x372c, 0x372d, 0x372e, 0x372f, 0x3730, 0x3731, + 0x3732, 0x3733, 0x3734, 0x3735, 0x3736, 0x3737, 0x3738, 0x3739, + 0x373a, 0x373b, 0x373c, 0x373d, 0x373e, 0x373f, 0x3740, 0x3741, + 0x3742, 0x3743, 0x3744, 0x3745, 0x3746, 0x3747, 0x3748, 0x3749, + 0x374a, 0x374b, 0x374c, 0x374d, 0x374e, 0x374f, 0x3750, 0x3751, + 0x3752, 0x3753, 0x3754, 0x3755, 0x3756, 0x3757, 0x3758, 0x3759, + 0x375a, 0x375b, 0x375c, 0x375d, 0x375e, 0x375f, 0x3760, 0x3761, + 0x3762, 0x3763, 0x3764, 0x3765, 0x3766, 0x3767, 0x3768, 0x3769, + 0x376a, 0x376b, 0x376c, 0x376d, 0x376e, 0x376f, 0x3770, 0x3771, + 0x3772, 0x3773, 0x3774, 0x3775, 0x3776, 0x3777, 0x3778, 0x3779, + 0x377a, 0x377b, 0x377c, 0x377d, 0x377e, 0x3821, 0x3822, 0x3823, + 0x3824, 0x3825, 0x3826, 0x3827, 0x3828, 0x3829, 0x382a, 0x382b, + 0x382c, 0x382d, 0x382e, 0x382f, 0x3830, 0x3831, 0x3832, 0x3833, + 0x3834, 0x3835, 0x3836, 0x3837, 0x3838, 0x3839, 0x383a, 0x383b, + 0x383c, 0x383d, 0x383e, 0x383f, 0x3840, 0x3841, 0x3842, 0x3843, + 0x3844, 0x3845, 0x3846, 0x3847, 0x3848, 0x3849, 0x384a, 0x384b, + 0x384c, 0x384d, 0x384e, 0x384f, 0x3850, 0x3851, 0x3852, 0x3853, + 0x3854, 0x3855, 0x3856, 0x3857, 0x3858, 0x3859, 0x385a, 0x385b, + 0x385c, 0x385d, 0x385e, 0x385f, 0x3860, 0x3861, 0x3862, 0x3863, + 0x3864, 0x3865, 0x3866, 0x3867, 0x3868, 0x3869, 0x386a, 0x386b, + 0x386c, 0x386d, 0x386e, 0x386f, 0x3870, 0x3871, 0x3872, 0x3873, + 0x3874, 0x3875, 0x3876, 0x3877, 0x3878, 0x3879, 0x387a, 0x387b, + 0x387c, 0x387d, 0x387e, 0x3921, 0x3922, 0x3923, 0x3924, 0x3925, + 0x3926, 0x3927, 0x3928, 0x3929, 0x392a, 0x392b, 0x392c, 0x392d, + 0x392e, 0x392f, 0x3930, 0x3931, 0x3932, 0x3933, 0x3934, 0x3935, + 0x3936, 0x3937, 0x3938, 0x3939, 0x393a, 0x393b, 0x393c, 0x393d, + 0x393e, 0x393f, 0x3940, 0x3941, 0x3942, 0x3943, 0x3944, 0x3945, + 0x3946, 0x3947, 0x3948, 0x3949, 0x394a, 0x394b, 0x394c, 0x394d, + 0x394e, 0x394f, 0x3950, 0x3951, 0x3952, 0x3953, 0x3954, 0x3955, + 0x3956, 0x3957, 0x3958, 0x3959, 0x395a, 0x395b, 0x395c, 0x395d, + 0x395e, 0x395f, 0x3960, 0x3961, 0x3962, 0x3963, 0x3964, 0x3965, + 0x3966, 0x3967, 0x3968, 0x3969, 0x396a, 0x396b, 0x396c, 0x396d, + 0x396e, 0x396f, 0x3970, 0x3971, 0x3972, 0x3973, 0x3974, 0x3975, + 0x3976, 0x3977, 0x3978, 0x3979, 0x397a, 0x397b, 0x397c, 0x397d, + 0x397e, 0x3a21, 0x3a22, 0x3a23, 0x3a24, 0x3a25, 0x3a26, 0x3a27, + 0x3a28, 0x3a29, 0x3a2a, 0x3a2b, 0x3a2c, 0x3a2d, 0x3a2e, 0x3a2f, + 0x3a30, 0x3a31, 0x3a32, 0x3a33, 0x3a34, 0x3a35, 0x3a36, 0x3a37, + 0x3a38, 0x3a39, 0x3a3a, 0x3a3b, 0x3a3c, 0x3a3d, 0x3a3e, 0x3a3f, + 0x3a40, 0x3a41, 0x3a42, 0x3a43, 0x3a44, 0x3a45, 0x3a46, 0x3a47, + 0x3a48, 0x3a49, 0x3a4a, 0x3a4b, 0x3a4c, 0x3a4d, 0x3a4e, 0x3a4f, + 0x3a50, 0x3a51, 0x3a52, 0x3a53, 0x3a54, 0x3a55, 0x3a56, 0x3a57, + 0x3a58, 0x3a59, 0x3a5a, 0x3a5b, 0x3a5c, 0x3a5d, 0x3a5e, 0x3a5f, + 0x3a60, 0x3a61, 0x3a62, 0x3a63, 0x3a64, 0x3a65, 0x3a66, 0x3a67, + 0x3a68, 0x3a69, 0x3a6a, 0x3a6b, 0x3a6c, 0x3a6d, 0x3a6e, 0x3a6f, + 0x3a70, 0x3a71, 0x3a72, 0x3a73, 0x3a74, 0x3a75, 0x3a76, 0x3a77, + 0x3a78, 0x3a79, 0x3a7a, 0x3a7b, 0x3a7c, 0x3a7d, 0x3a7e, 0x3b21, + 0x3b22, 0x3b23, 0x3b24, 0x3b25, 0x3b26, 0x3b27, 0x3b28, 0x3b29, + 0x3b2a, 0x3b2b, 0x3b2c, 0x3b2d, 0x3b2e, 0x3b2f, 0x3b30, 0x3b31, + 0x3b32, 0x3b33, 0x3b34, 0x3b35, 0x3b36, 0x3b37, 0x3b38, 0x3b39, + 0x3b3a, 0x3b3b, 0x3b3c, 0x3b3d, 0x3b3e, 0x3b3f, 0x3b40, 0x3b41, + 0x3b42, 0x3b43, 0x3b44, 0x3b45, 0x3b46, 0x3b47, 0x3b48, 0x3b49, + 0x3b4a, 0x3b4b, 0x3b4c, 0x3b4d, 0x3b4e, 0x3b4f, 0x3b50, 0x3b51, + 0x3b52, 0x3b53, 0x3b54, 0x3b55, 0x3b56, 0x3b57, 0x3b58, 0x3b59, + 0x3b5a, 0x3b5b, 0x3b5c, 0x3b5d, 0x3b5e, 0x3b5f, 0x3b60, 0x3b61, + 0x3b62, 0x3b63, 0x3b64, 0x3b65, 0x3b66, 0x3b67, 0x3b68, 0x3b69, + 0x3b6a, 0x3b6b, 0x3b6c, 0x3b6d, 0x3b6e, 0x3b6f, 0x3b70, 0x3b71, + 0x3b72, 0x3b73, 0x3b74, 0x3b75, 0x3b76, 0x3b77, 0x3b78, 0x3b79, + 0x3b7a, 0x3b7b, 0x3b7c, 0x3b7d, 0x3b7e, 0x3c21, 0x3c22, 0x3c23, + 0x3c24, 0x3c25, 0x3c26, 0x3c27, 0x3c28, 0x3c29, 0x3c2a, 0x3c2b, + 0x3c2c, 0x3c2d, 0x3c2e, 0x3c2f, 0x3c30, 0x3c31, 0x3c32, 0x3c33, + 0x3c34, 0x3c35, 0x3c36, 0x3c37, 0x3c38, 0x3c39, 0x3c3a, 0x3c3b, + 0x3c3c, 0x3c3d, 0x3c3e, 0x3c3f, 0x3c40, 0x3c41, 0x3c42, 0x3c43, + 0x3c44, 0x3c45, 0x3c46, 0x3c47, 0x3c48, 0x3c49, 0x3c4a, 0x3c4b, + 0x3c4c, 0x3c4d, 0x3c4e, 0x3c4f, 0x3c50, 0x3c51, 0x3c52, 0x3c53, + 0x3c54, 0x3c55, 0x3c56, 0x3c57, 0x3c58, 0x3c59, 0x3c5a, 0x3c5b, + 0x3c5c, 0x3c5d, 0x3c5e, 0x3c5f, 0x3c60, 0x3c61, 0x3c62, 0x3c63, + 0x3c64, 0x3c65, 0x3c66, 0x3c67, 0x3c68, 0x3c69, 0x3c6a, 0x3c6b, + 0x3c6c, 0x3c6d, 0x3c6e, 0x3c6f, 0x3c70, 0x3c71, 0x3c72, 0x3c73, + 0x3c74, 0x3c75, 0x3c76, 0x3c77, 0x3c78, 0x3c79, 0x3c7a, 0x3c7b, + 0x3c7c, 0x3c7d, 0x3c7e, 0x3d21, 0x3d22, 0x3d23, 0x3d24, 0x3d25, + 0x3d26, 0x3d27, 0x3d28, 0x3d29, 0x3d2a, 0x3d2b, 0x3d2c, 0x3d2d, + 0x3d2e, 0x3d2f, 0x3d30, 0x3d31, 0x3d32, 0x3d33, 0x3d34, 0x3d35, + 0x3d36, 0x3d37, 0x3d38, 0x3d39, 0x3d3a, 0x3d3b, 0x3d3c, 0x3d3d, + 0x3d3e, 0x3d3f, 0x3d40, 0x3d41, 0x3d42, 0x3d43, 0x3d44, 0x3d45, + 0x3d46, 0x3d47, 0x3d48, 0x3d49, 0x3d4a, 0x3d4b, 0x3d4c, 0x3d4d, + 0x3d4e, 0x3d4f, 0x3d50, 0x3d51, 0x3d52, 0x3d53, 0x3d54, 0x3d55, + 0x3d56, 0x3d57, 0x3d58, 0x3d59, 0x3d5a, 0x3d5b, 0x3d5c, 0x3d5d, + 0x3d5e, 0x3d5f, 0x3d60, 0x3d61, 0x3d62, 0x3d63, 0x3d64, 0x3d65, + 0x3d66, 0x3d67, 0x3d68, 0x3d69, 0x3d6a, 0x3d6b, 0x3d6c, 0x3d6d, + 0x3d6e, 0x3d6f, 0x3d70, 0x3d71, 0x3d72, 0x3d73, 0x3d74, 0x3d75, + 0x3d76, 0x3d77, 0x3d78, 0x3d79, 0x3d7a, 0x3d7b, 0x3d7c, 0x3d7d, + 0x3d7e, 0x3e21, 0x3e22, 0x3e23, 0x3e24, 0x3e25, 0x3e26, 0x3e27, + 0x3e28, 0x3e29, 0x3e2a, 0x3e2b, 0x3e2c, 0x3e2d, 0x3e2e, 0x3e2f, + 0x3e30, 0x3e31, 0x3e32, 0x3e33, 0x3e34, 0x3e35, 0x3e36, 0x3e37, + 0x3e38, 0x3e39, 0x3e3a, 0x3e3b, 0x3e3c, 0x3e3d, 0x3e3e, 0x3e3f, + 0x3e40, 0x3e41, 0x3e42, 0x3e43, 0x3e44, 0x3e45, 0x3e46, 0x3e47, + 0x3e48, 0x3e49, 0x3e4a, 0x3e4b, 0x3e4c, 0x3e4d, 0x3e4e, 0x3e4f, + 0x3e50, 0x3e51, 0x3e52, 0x3e53, 0x3e54, 0x3e55, 0x3e56, 0x3e57, + 0x3e58, 0x3e59, 0x3e5a, 0x3e5b, 0x3e5c, 0x3e5d, 0x3e5e, 0x3e5f, + 0x3e60, 0x3e61, 0x3e62, 0x3e63, 0x3e64, 0x3e65, 0x3e66, 0x3e67, + 0x3e68, 0x3e69, 0x3e6a, 0x3e6b, 0x3e6c, 0x3e6d, 0x3e6e, 0x3e6f, + 0x3e70, 0x3e71, 0x3e72, 0x3e73, 0x3e74, 0x3e75, 0x3e76, 0x3e77, + 0x3e78, 0x3e79, 0x3e7a, 0x3e7b, 0x3e7c, 0x3e7d, 0x3e7e, 0x3f21, + 0x3f22, 0x3f23, 0x3f24, 0x3f25, 0x3f26, 0x3f27, 0x3f28, 0x3f29, + 0x3f2a, 0x3f2b, 0x3f2c, 0x3f2d, 0x3f2e, 0x3f2f, 0x3f30, 0x3f31, + 0x3f32, 0x3f33, 0x3f34, 0x3f35, 0x3f36, 0x3f37, 0x3f38, 0x3f39, + 0x3f3a, 0x3f3b, 0x3f3c, 0x3f3d, 0x3f3e, 0x3f3f, 0x3f40, 0x3f41, + 0x3f42, 0x3f43, 0x3f44, 0x3f45, 0x3f46, 0x3f47, 0x3f48, 0x3f49, + 0x3f4a, 0x3f4b, 0x3f4c, 0x3f4d, 0x3f4e, 0x3f4f, 0x3f50, 0x3f51, + 0x3f52, 0x3f53, 0x3f54, 0x3f55, 0x3f56, 0x3f57, 0x3f58, 0x3f59, + 0x3f5a, 0x3f5b, 0x3f5c, 0x3f5d, 0x3f5e, 0x3f5f, 0x3f60, 0x3f61, + 0x3f62, 0x3f63, 0x3f64, 0x3f65, 0x3f66, 0x3f67, 0x3f68, 0x3f69, + 0x3f6a, 0x3f6b, 0x3f6c, 0x3f6d, 0x3f6e, 0x3f6f, 0x3f70, 0x3f71, + 0x3f72, 0x3f73, 0x3f74, 0x3f75, 0x3f76, 0x3f77, 0x3f78, 0x3f79, + 0x3f7a, 0x3f7b, 0x3f7c, 0x3f7d, 0x3f7e, 0x4021, 0x4022, 0x4023, + 0x4024, 0x4025, 0x4026, 0x4027, 0x4028, 0x4029, 0x402a, 0x402b, + 0x402c, 0x402d, 0x402e, 0x402f, 0x4030, 0x4031, 0x4032, 0x4033, + 0x4034, 0x4035, 0x4036, 0x4037, 0x4038, 0x4039, 0x403a, 0x403b, + 0x403c, 0x403d, 0x403e, 0x403f, 0x4040, 0x4041, 0x4042, 0x4043, + 0x4044, 0x4045, 0x4046, 0x4047, 0x4048, 0x4049, 0x404a, 0x404b, + 0x404c, 0x404d, 0x404e, 0x404f, 0x4050, 0x4051, 0x4052, 0x4053, + 0x4054, 0x4055, 0x4056, 0x4057, 0x4058, 0x4059, 0x405a, 0x405b, + 0x405c, 0x405d, 0x405e, 0x405f, 0x4060, 0x4061, 0x4062, 0x4063, + 0x4064, 0x4065, 0x4066, 0x4067, 0x4068, 0x4069, 0x406a, 0x406b, + 0x406c, 0x406d, 0x406e, 0x406f, 0x4070, 0x4071, 0x4072, 0x4073, + 0x4074, 0x4075, 0x4076, 0x4077, 0x4078, 0x4079, 0x407a, 0x407b, + 0x407c, 0x407d, 0x407e, 0x4121, 0x4122, 0x4123, 0x4124, 0x4125, + 0x4126, 0x4127, 0x4128, 0x4129, 0x412a, 0x412b, 0x412c, 0x412d, + 0x412e, 0x412f, 0x4130, 0x4131, 0x4132, 0x4133, 0x4134, 0x4135, + 0x4136, 0x4137, 0x4138, 0x4139, 0x413a, 0x413b, 0x413c, 0x413d, + 0x413e, 0x413f, 0x4140, 0x4141, 0x4142, 0x4143, 0x4144, 0x4145, + 0x4146, 0x4147, 0x4148, 0x4149, 0x414a, 0x414b, 0x414c, 0x414d, + 0x414e, 0x414f, 0x4150, 0x4151, 0x4152, 0x4153, 0x4154, 0x4155, + 0x4156, 0x4157, 0x4158, 0x4159, 0x415a, 0x415b, 0x415c, 0x415d, + 0x415e, 0x415f, 0x4160, 0x4161, 0x4162, 0x4163, 0x4164, 0x4165, + 0x4166, 0x4167, 0x4168, 0x4169, 0x416a, 0x416b, 0x416c, 0x416d, + 0x416e, 0x416f, 0x4170, 0x4171, 0x4172, 0x4173, 0x4174, 0x4175, + 0x4176, 0x4177, 0x4178, 0x4179, 0x417a, 0x417b, 0x417c, 0x417d, + 0x417e, 0x4221, 0x4222, 0x4223, 0x4224, 0x4225, 0x4226, 0x4227, + 0x4228, 0x4229, 0x422a, 0x422b, 0x422c, 0x422d, 0x422e, 0x422f, + 0x4230, 0x4231, 0x4232, 0x4233, 0x4234, 0x4235, 0x4236, 0x4237, + 0x4238, 0x4239, 0x423a, 0x423b, 0x423c, 0x423d, 0x423e, 0x423f, + 0x4240, 0x4241, 0x4242, 0x4243, 0x4244, 0x4245, 0x4246, 0x4247, + 0x4248, 0x4249, 0x424a, 0x424b, 0x424c, 0x424d, 0x424e, 0x424f, + 0x4250, 0x4251, 0x4252, 0x4253, 0x4254, 0x4255, 0x4256, 0x4257, + 0x4258, 0x4259, 0x425a, 0x425b, 0x425c, 0x425d, 0x425e, 0x425f, + 0x4260, 0x4261, 0x4262, 0x4263, 0x4264, 0x4265, 0x4266, 0x4267, + 0x4268, 0x4269, 0x426a, 0x426b, 0x426c, 0x426d, 0x426e, 0x426f, + 0x4270, 0x4271, 0x4272, 0x4273, 0x4274, 0x4275, 0x4276, 0x4277, + 0x4278, 0x4279, 0x427a, 0x427b, 0x427c, 0x427d, 0x427e, 0x4321, + 0x4322, 0x4323, 0x4324, 0x4325, 0x4326, 0x4327, 0x4328, 0x4329, + 0x432a, 0x432b, 0x432c, 0x432d, 0x432e, 0x432f, 0x4330, 0x4331, + 0x4332, 0x4333, 0x4334, 0x4335, 0x4336, 0x4337, 0x4338, 0x4339, + 0x433a, 0x433b, 0x433c, 0x433d, 0x433e, 0x433f, 0x4340, 0x4341, + 0x4342, 0x4343, 0x4344, 0x4345, 0x4346, 0x4347, 0x4348, 0x4349, + 0x434a, 0x434b, 0x434c, 0x434d, 0x434e, 0x434f, 0x4350, 0x4351, + 0x4352, 0x4353, 0x4354, 0x4355, 0x4356, 0x4357, 0x4358, 0x4359, + 0x435a, 0x435b, 0x435c, 0x435d, 0x435e, 0x435f, 0x4360, 0x4361, + 0x4362, 0x4363, 0x4364, 0x4365, 0x4366, 0x4367, 0x4368, 0x4369, + 0x436a, 0x436b, 0x436c, 0x436d, 0x436e, 0x436f, 0x4370, 0x4371, + 0x4372, 0x4373, 0x4374, 0x4375, 0x4376, 0x4377, 0x4378, 0x4379, + 0x437a, 0x437b, 0x437c, 0x437d, 0x437e, 0x4421, 0x4422, 0x4423, + 0x4424, 0x4425, 0x4426, 0x4427, 0x4428, 0x4429, 0x442a, 0x442b, + 0x442c, 0x442d, 0x442e, 0x442f, 0x4430, 0x4431, 0x4432, 0x4433, + 0x4434, 0x4435, 0x4436, 0x4437, 0x4438, 0x4439, 0x443a, 0x443b, + 0x443c, 0x443d, 0x443e, 0x443f, 0x4440, 0x4441, 0x4442, 0x4443, + 0x4444, 0x4445, 0x4446, 0x4447, 0x4448, 0x4449, 0x444a, 0x444b, + 0x444c, 0x444d, 0x444e, 0x444f, 0x4450, 0x4451, 0x4452, 0x4453, + 0x4454, 0x4455, 0x4456, 0x4457, 0x4458, 0x4459, 0x445a, 0x445b, + 0x445c, 0x445d, 0x445e, 0x445f, 0x4460, 0x4461, 0x4462, 0x4463, + 0x4464, 0x4465, 0x4466, 0x4467, 0x4468, 0x4469, 0x446a, 0x446b, + 0x446c, 0x446d, 0x446e, 0x446f, 0x4470, 0x4471, 0x4472, 0x4473, + 0x4474, 0x4475, 0x4476, 0x4477, 0x4478, 0x4479, 0x447a, 0x447b, + 0x447c, 0x447d, 0x447e, 0x4521, 0x4522, 0x4523, 0x4524, 0x4525, + 0x4526, 0x4527, 0x4528, 0x4529, 0x452a, 0x452b, 0x452c, 0x452d, + 0x452e, 0x452f, 0x4530, 0x4531, 0x4532, 0x4533, 0x4534, 0x4535, + 0x4536, 0x4537, 0x4538, 0x4539, 0x453a, 0x453b, 0x453c, 0x453d, + 0x453e, 0x453f, 0x4540, 0x4541, 0x4542, 0x4543, 0x4544, 0x4545, + 0x4546, 0x4547, 0x4548, 0x4549, 0x454a, 0x454b, 0x454c, 0x454d, + 0x454e, 0x454f, 0x4550, 0x4551, 0x4552, 0x4553, 0x4554, 0x4555, + 0x4556, 0x4557, 0x4558, 0x4559, 0x455a, 0x455b, 0x455c, 0x455d, + 0x455e, 0x455f, 0x4560, 0x4561, 0x4562, 0x4563, 0x4564, 0x4565, + 0x4566, 0x4567, 0x4568, 0x4569, 0x456a, 0x456b, 0x456c, 0x456d, + 0x456e, 0x456f, 0x4570, 0x4571, 0x4572, 0x4573, 0x4574, 0x4575, + 0x4576, 0x4577, 0x4578, 0x4579, 0x457a, 0x457b, 0x457c, 0x457d, + 0x457e, 0x4621, 0x4622, 0x4623, 0x4624, 0x4625, 0x4626, 0x4627, + 0x4628, 0x4629, 0x462a, 0x462b, 0x462c, 0x462d, 0x462e, 0x462f, + 0x4630, 0x4631, 0x4632, 0x4633, 0x4634, 0x4635, 0x4636, 0x4637, + 0x4638, 0x4639, 0x463a, 0x463b, 0x463c, 0x463d, 0x463e, 0x463f, + 0x4640, 0x4641, 0x4642, 0x4643, 0x4644, 0x4645, 0x4646, 0x4647, + 0x4648, 0x4649, 0x464a, 0x464b, 0x464c, 0x464d, 0x464e, 0x464f, + 0x4650, 0x4651, 0x4652, 0x4653, 0x4654, 0x4655, 0x4656, 0x4657, + 0x4658, 0x4659, 0x465a, 0x465b, 0x465c, 0x465d, 0x465e, 0x465f, + 0x4660, 0x4661, 0x4662, 0x4663, 0x4664, 0x4665, 0x4666, 0x4667, + 0x4668, 0x4669, 0x466a, 0x466b, 0x466c, 0x466d, 0x466e, 0x466f, + 0x4670, 0x4671, 0x4672, 0x4673, 0x4674, 0x4675, 0x4676, 0x4677, + 0x4678, 0x4679, 0x467a, 0x467b, 0x467c, 0x467d, 0x467e, 0x4721, + 0x4722, 0x4723, 0x4724, 0x4725, 0x4726, 0x4727, 0x4728, 0x4729, + 0x472a, 0x472b, 0x472c, 0x472d, 0x472e, 0x472f, 0x4730, 0x4731, + 0x4732, 0x4733, 0x4734, 0x4735, 0x4736, 0x4737, 0x4738, 0x4739, + 0x473a, 0x473b, 0x473c, 0x473d, 0x473e, 0x473f, 0x4740, 0x4741, + 0x4742, 0x4743, 0x4744, 0x4745, 0x4746, 0x4747, 0x4748, 0x4749, + 0x474a, 0x474b, 0x474c, 0x474d, 0x474e, 0x474f, 0x4750, 0x4751, + 0x4752, 0x4753, 0x4754, 0x4755, 0x4756, 0x4757, 0x4758, 0x4759, + 0x475a, 0x475b, 0x475c, 0x475d, 0x475e, 0x475f, 0x4760, 0x4761, + 0x4762, 0x4763, 0x4764, 0x4765, 0x4766, 0x4767, 0x4768, 0x4769, + 0x476a, 0x476b, 0x476c, 0x476d, 0x476e, 0x476f, 0x4770, 0x4771, + 0x4772, 0x4773, 0x4774, 0x4775, 0x4776, 0x4777, 0x4778, 0x4779, + 0x477a, 0x477b, 0x477c, 0x477d, 0x477e, 0x4821, 0x4822, 0x4823, + 0x4824, 0x4825, 0x4826, 0x4827, 0x4828, 0x4829, 0x482a, 0x482b, + 0x482c, 0x482d, 0x482e, 0x482f, 0x4830, 0x4831, 0x4832, 0x4833, + 0x4834, 0x4835, 0x4836, 0x4837, 0x4838, 0x4839, 0x483a, 0x483b, + 0x483c, 0x483d, 0x483e, 0x483f, 0x4840, 0x4841, 0x4842, 0x4843, + 0x4844, 0x4845, 0x4846, 0x4847, 0x4848, 0x4849, 0x484a, 0x484b, + 0x484c, 0x484d, 0x484e, 0x484f, 0x4850, 0x4851, 0x4852, 0x4853, + 0x4854, 0x4855, 0x4856, 0x4857, 0x4858, 0x4859, 0x485a, 0x485b, + 0x485c, 0x485d, 0x485e, 0x485f, 0x4860, 0x4861, 0x4862, 0x4863, + 0x4864, 0x4865, 0x4866, 0x4867, 0x4868, 0x4869, 0x486a, 0x486b, + 0x486c, 0x486d, 0x486e, 0x486f, 0x4870, 0x4871, 0x4872, 0x4873, + 0x4874, 0x4875, 0x4876, 0x4877, 0x4878, 0x4879, 0x487a, 0x487b, + 0x487c, 0x487d, 0x487e, 0x4b50, 0x4b56, 0x4b67, 0x4d4f, 0x4d68, + 0x4e2d, 0x4f7b, 0x5022, 0x5038, 0x5050, 0x505d, 0x5154, 0x5155, + 0x5158, 0x515b, 0x515c, 0x515d, 0x515e, 0x515f, 0x5160, 0x5162, + 0x5163, 0x5164, 0x5165, 0x5166, 0x5168, 0x5169, 0x516a, 0x516b, + 0x516d, 0x516f, 0x5170, 0x5172, 0x5176, 0x517a, 0x517c, 0x517d, + 0x517e, 0x5222, 0x5223, 0x5227, 0x5228, 0x5229, 0x522a, 0x522b, + 0x522d, 0x5232, 0x523e, 0x5242, 0x5243, 0x5244, 0x5246, 0x5247, + 0x5248, 0x5249, 0x524a, 0x524b, 0x524d, 0x524e, 0x524f, 0x5250, + 0x5251, 0x5252, 0x5253, 0x5254, 0x5255, 0x5256, 0x5257, 0x5259, + 0x525a, 0x525e, 0x525f, 0x5261, 0x5262, 0x5264, 0x5265, 0x5266, + 0x5267, 0x5268, 0x5269, 0x526a, 0x526b, 0x5270, 0x5271, 0x5272, + 0x5273, 0x5274, 0x5275, 0x5277, 0x5278, 0x5466, 0x547c, 0x5525, + 0x552b, 0x552e, 0x5638, 0x564d, 0x574b, 0x5764, 0x5b45, 0x5b64, + 0x5c25, 0x5d25, 0x5d55, 0x5d74, 0x5e7c, 0x5e7e, 0x5f33, 0x5f61, + 0x5f68, 0x6071, 0x612d, 0x616d, 0x6375, 0x6421, 0x6429, 0x652e, + 0x6531, 0x6532, 0x6539, 0x653b, 0x653c, 0x6544, 0x654e, 0x6550, + 0x6552, 0x6556, 0x657a, 0x657b, 0x657c, 0x657e, 0x6621, 0x6624, + 0x6627, 0x662d, 0x662f, 0x6630, 0x6631, 0x6633, 0x6637, 0x6638, + 0x663c, 0x6644, 0x6646, 0x6647, 0x664a, 0x6652, 0x6656, 0x6659, + 0x665c, 0x665f, 0x6661, 0x6664, 0x6665, 0x6666, 0x6668, 0x666a, + 0x666b, 0x666c, 0x666f, 0x6671, 0x6672, 0x6675, 0x6676, 0x6677, + 0x6679, 0x6721, 0x6726, 0x6729, 0x672a, 0x672c, 0x672d, 0x6730, + 0x673f, 0x6741, 0x6746, 0x6747, 0x674b, 0x674d, 0x674f, 0x6750, + 0x6753, 0x675f, 0x6764, 0x6766, 0x6777, 0x6867, 0x6868, 0x6870, + 0x6871, 0x6877, 0x6879, 0x687b, 0x687e, 0x6927, 0x692c, 0x694c, + 0x6977, 0x6a41, 0x6a65, 0x6a74, 0x6a77, 0x6a7c, 0x6a7e, 0x6b24, + 0x6b27, 0x6b29, 0x6b2a, 0x6b3a, 0x6b3b, 0x6b3d, 0x6b41, 0x6b42, + 0x6b46, 0x6b47, 0x6b4c, 0x6b4f, 0x6b50, 0x6b51, 0x6b52, 0x6b58, + 0x6c26, 0x6c27, 0x6c2a, 0x6c2f, 0x6c30, 0x6c31, 0x6c32, 0x6c35, + 0x6c38, 0x6c3a, 0x6c40, 0x6c41, 0x6c45, 0x6c46, 0x6c49, 0x6c4a, + 0x6c55, 0x6c5d, 0x6c5e, 0x6c61, 0x6c64, 0x6c67, 0x6c68, 0x6c77, + 0x6c78, 0x6c7a, 0x6d21, 0x6d22, 0x6d23, 0x6d6e, 0x6e5b, 0x723d, + 0x727a, 0x7331, 0x7427, 0x746e, 0x7674, 0x7676, 0x7738, 0x7748, + 0x7753, 0x785b, 0x7870, 0x7a21, 0x7a22, 0x7a66, 0x7c29, 0x2321, + 0x2322, 0x2323, 0x2324, 0x2325, 0x2326, 0x2327, 0x2328, 0x2329, + 0x232a, 0x232b, 0x232c, 0x232d, 0x232e, 0x232f, 0x2330, 0x2331, + 0x2332, 0x2333, 0x2334, 0x2335, 0x2336, 0x2337, 0x2338, 0x2339, + 0x233a, 0x233b, 0x233c, 0x233d, 0x233e, 0x233f, 0x2340, 0x2341, + 0x2342, 0x2343, 0x2344, 0x2345, 0x2346, 0x2347, 0x2348, 0x2349, + 0x234a, 0x234b, 0x234c, 0x234d, 0x234e, 0x234f, 0x2350, 0x2351, + 0x2352, 0x2353, 0x2354, 0x2355, 0x2356, 0x2357, 0x2358, 0x2359, + 0x235a, 0x235b, 0x212c, 0x235d, 0x235e, 0x235f, 0x2360, 0x2361, + 0x2362, 0x2363, 0x2364, 0x2365, 0x2366, 0x2367, 0x2368, 0x2369, + 0x236a, 0x236b, 0x236c, 0x236d, 0x236e, 0x236f, 0x2370, 0x2371, + 0x2372, 0x2373, 0x2374, 0x2375, 0x2376, 0x2377, 0x2378, 0x2379, + 0x237a, 0x237b, 0x237c, 0x237d, 0x2226, 0x214b, 0x214c, 0x217e, + 0x237e, 0x214d, 0x235c, +}; + +static const Summary16 ksc5601_uni2indx_page00[70] = { + /* 0x0000 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x6592 }, { 7, 0xf7df }, + { 21, 0x0040 }, { 22, 0xc181 }, { 27, 0x0040 }, { 28, 0x4181 }, + /* 0x0100 */ + { 32, 0x0000 }, { 32, 0x0002 }, { 33, 0x00c0 }, { 35, 0x810e }, + { 40, 0x0e07 }, { 46, 0x000c }, { 48, 0x00c0 }, { 50, 0x0000 }, + { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, + { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, + /* 0x0200 */ + { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, + { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, + { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, { 50, 0x0000 }, + { 50, 0x0080 }, { 51, 0x2f01 }, { 57, 0x0000 }, { 57, 0x0000 }, + /* 0x0300 */ + { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, + { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, { 57, 0x0000 }, + { 57, 0x0000 }, { 57, 0xfffe }, { 72, 0x03fb }, { 81, 0xfffe }, + { 96, 0x03fb }, { 105, 0x0000 }, { 105, 0x0000 }, { 105, 0x0000 }, + /* 0x0400 */ + { 105, 0x0002 }, { 106, 0xffff }, { 122, 0xffff }, { 138, 0xffff }, + { 154, 0xffff }, { 170, 0x0002 }, +}; +static const Summary16 ksc5601_uni2indx_page20[103] = { + /* 0x2000 */ + { 171, 0x0000 }, { 171, 0x3320 }, { 176, 0x0063 }, { 180, 0x080d }, + { 184, 0x0000 }, { 184, 0x0000 }, { 184, 0x0000 }, { 184, 0x8010 }, + { 186, 0x001e }, { 190, 0x0000 }, { 190, 0x1000 }, { 191, 0x0000 }, + { 191, 0x0000 }, { 191, 0x0000 }, { 191, 0x0000 }, { 191, 0x0000 }, + /* 0x2100 */ + { 191, 0x0208 }, { 193, 0x0048 }, { 195, 0x0846 }, { 199, 0x0000 }, + { 199, 0x0000 }, { 199, 0x7818 }, { 205, 0x03ff }, { 215, 0x03ff }, + { 225, 0x0000 }, { 225, 0x03ff }, { 235, 0x0000 }, { 235, 0x0000 }, + { 235, 0x0000 }, { 235, 0x0014 }, { 237, 0x0000 }, { 237, 0x0000 }, + /* 0x2200 */ + { 237, 0x898d }, { 244, 0x6402 }, { 248, 0x5fa1 }, { 257, 0x3030 }, + { 261, 0x0000 }, { 261, 0x0004 }, { 262, 0x0c33 }, { 268, 0x0000 }, + { 268, 0x00cc }, { 272, 0x0200 }, { 273, 0x0020 }, { 274, 0x0000 }, + { 274, 0x0000 }, { 274, 0x0000 }, { 274, 0x0000 }, { 274, 0x0000 }, + /* 0x2300 */ + { 274, 0x0000 }, { 274, 0x0004 }, { 275, 0x0000 }, { 275, 0x0000 }, + { 275, 0x0000 }, { 275, 0x0000 }, { 275, 0x0000 }, { 275, 0x0000 }, + { 275, 0x0000 }, { 275, 0x0000 }, { 275, 0x0000 }, { 275, 0x0000 }, + { 275, 0x0000 }, { 275, 0x0000 }, { 275, 0x0000 }, { 275, 0x0000 }, + /* 0x2400 */ + { 275, 0x0000 }, { 275, 0x0000 }, { 275, 0x0000 }, { 275, 0x0000 }, + { 275, 0x0000 }, { 275, 0x0000 }, { 275, 0x7fff }, { 290, 0xfff0 }, + { 302, 0x0007 }, { 305, 0xf000 }, { 309, 0xffff }, { 325, 0x003f }, + { 331, 0x0000 }, { 331, 0xffff }, { 347, 0x03ff }, { 357, 0x0000 }, + /* 0x2500 */ + { 357, 0xf00f }, { 365, 0xffff }, { 381, 0xffff }, { 397, 0xffff }, + { 413, 0x0fff }, { 425, 0x0000 }, { 425, 0x0000 }, { 425, 0x0000 }, + { 425, 0x0000 }, { 425, 0x0004 }, { 426, 0x03fb }, { 435, 0x30cc }, + { 441, 0xc9c3 }, { 449, 0x0003 }, { 451, 0x0000 }, { 451, 0x0000 }, + /* 0x2600 */ + { 451, 0xc060 }, { 455, 0x5000 }, { 457, 0x0000 }, { 457, 0x0000 }, + { 457, 0x0005 }, { 459, 0x0000 }, { 459, 0x37bb }, +}; +static const Summary16 ksc5601_uni2indx_page30[62] = { + /* 0x3000 */ + { 470, 0xff0f }, { 482, 0x003b }, { 487, 0x0000 }, { 487, 0x0000 }, + { 487, 0xfffe }, { 502, 0xffff }, { 518, 0xffff }, { 534, 0xffff }, + { 550, 0xffff }, { 566, 0x000f }, { 570, 0xfffe }, { 585, 0xffff }, + { 601, 0xffff }, { 617, 0xffff }, { 633, 0xffff }, { 649, 0x007f }, + /* 0x3100 */ + { 656, 0x0000 }, { 656, 0x0000 }, { 656, 0x0000 }, { 656, 0xfffe }, + { 671, 0xffff }, { 687, 0xffff }, { 703, 0xffff }, { 719, 0xffff }, + { 735, 0x7fff }, { 750, 0x0000 }, { 750, 0x0000 }, { 750, 0x0000 }, + { 750, 0x0000 }, { 750, 0x0000 }, { 750, 0x0000 }, { 750, 0x0000 }, + /* 0x3200 */ + { 750, 0xffff }, { 766, 0x1fff }, { 779, 0x0000 }, { 779, 0x0000 }, + { 779, 0x0000 }, { 779, 0x0000 }, { 779, 0xffff }, { 795, 0xcfff }, + { 809, 0x0000 }, { 809, 0x0000 }, { 809, 0x0000 }, { 809, 0x0000 }, + { 809, 0x0000 }, { 809, 0x0000 }, { 809, 0x0000 }, { 809, 0x0000 }, + /* 0x3300 */ + { 809, 0x0000 }, { 809, 0x0000 }, { 809, 0x0000 }, { 809, 0x0000 }, + { 809, 0x0000 }, { 809, 0x0000 }, { 809, 0x0000 }, { 809, 0x0000 }, + { 809, 0xff1f }, { 822, 0xffff }, { 838, 0xffff }, { 854, 0xffff }, + { 870, 0x87ff }, { 882, 0x3949 }, +}; +static const Summary16 ksc5601_uni2indx_page4e[1306] = { + /* 0x4e00 */ + { 889, 0x2f8b }, { 898, 0x4372 }, { 905, 0x2000 }, { 906, 0x0b04 }, + { 910, 0xe82c }, { 917, 0xe340 }, { 923, 0x2800 }, { 925, 0x40c8 }, + { 929, 0x5944 }, { 935, 0x4937 }, { 943, 0x7976 }, { 953, 0x0440 }, + { 955, 0x2c93 }, { 962, 0xa3f0 }, { 970, 0x0038 }, { 973, 0x08c5 }, + /* 0x4f00 */ + { 978, 0xee02 }, { 985, 0x0003 }, { 987, 0x8000 }, { 988, 0x3550 }, + { 994, 0xe1c8 }, { 1001, 0x1e23 }, { 1008, 0x8200 }, { 1010, 0xc449 }, + { 1016, 0xad5a }, { 1025, 0x2942 }, { 1030, 0xc000 }, { 1032, 0x8060 }, + { 1035, 0x461c }, { 1041, 0xa49a }, { 1048, 0xc003 }, { 1052, 0x052a }, + /* 0x5000 */ + { 1057, 0x2a44 }, { 1062, 0xd646 }, { 1070, 0x3dda }, { 1080, 0x0800 }, + { 1081, 0x8388 }, { 1086, 0x1420 }, { 1089, 0x0020 }, { 1090, 0x0170 }, + { 1094, 0x2021 }, { 1097, 0x0302 }, { 1100, 0x3000 }, { 1102, 0x40ac }, + { 1107, 0x8620 }, { 1111, 0x4462 }, { 1116, 0x20a0 }, { 1119, 0x8a00 }, + /* 0x5100 */ + { 1122, 0x0253 }, { 1127, 0x8004 }, { 1129, 0x0402 }, { 1131, 0x1484 }, + { 1135, 0x7bfb }, { 1148, 0x1004 }, { 1150, 0x7fa4 }, { 1160, 0x11e2 }, + { 1166, 0x2441 }, { 1170, 0x00a4 }, { 1173, 0x1421 }, { 1177, 0x20c0 }, + { 1180, 0x3a50 }, { 1186, 0x7000 }, { 1189, 0x0002 }, { 1190, 0x2743 }, + /* 0x5200 */ + { 1197, 0x45c9 }, { 1204, 0x2082 }, { 1207, 0x4630 }, { 1212, 0x0fc1 }, + { 1219, 0x3c88 }, { 1225, 0x2850 }, { 1229, 0x8602 }, { 1233, 0xa024 }, + { 1237, 0x2388 }, { 1242, 0x8806 }, { 1246, 0x0e19 }, { 1252, 0x4000 }, + { 1253, 0x22aa }, { 1259, 0xeb64 }, { 1268, 0x001c }, { 1271, 0xcd28 }, + /* 0x5300 */ + { 1278, 0xa120 }, { 1282, 0x02e1 }, { 1287, 0x840b }, { 1292, 0x8200 }, + { 1294, 0x279b }, { 1303, 0x549e }, { 1311, 0x8141 }, { 1315, 0xa0b3 }, + { 1322, 0x0010 }, { 1323, 0x8508 }, { 1327, 0x2061 }, { 1331, 0x0800 }, + { 1332, 0x2f08 }, { 1338, 0x08d0 }, { 1342, 0xbe3e }, { 1353, 0x010f }, + /* 0x5400 */ + { 1358, 0xf718 }, { 1367, 0xa803 }, { 1372, 0x0a41 }, { 1376, 0x5b08 }, + { 1382, 0x0504 }, { 1385, 0x0002 }, { 1386, 0x0500 }, { 1388, 0x382a }, + { 1394, 0x5041 }, { 1398, 0x0001 }, { 1399, 0x1910 }, { 1403, 0x2108 }, + { 1406, 0x0313 }, { 1411, 0x0000 }, { 1411, 0x6122 }, { 1416, 0x0404 }, + /* 0x5500 */ + { 1418, 0x40d0 }, { 1422, 0x1001 }, { 1424, 0x8000 }, { 1425, 0x4022 }, + { 1428, 0x8050 }, { 1431, 0x4048 }, { 1434, 0x0008 }, { 1435, 0x1000 }, + { 1436, 0x06d1 }, { 1442, 0x3700 }, { 1447, 0x5e80 }, { 1453, 0x0000 }, + { 1453, 0x00a0 }, { 1455, 0x9410 }, { 1459, 0x0018 }, { 1461, 0x6000 }, + /* 0x5600 */ + { 1463, 0x0240 }, { 1465, 0x0090 }, { 1467, 0x8000 }, { 1468, 0x0054 }, + { 1471, 0x0000 }, { 1471, 0x0008 }, { 1472, 0x0900 }, { 1474, 0x0010 }, + { 1475, 0x0040 }, { 1476, 0x0000 }, { 1476, 0x5020 }, { 1479, 0x1010 }, + { 1481, 0x2400 }, { 1483, 0x4c02 }, { 1487, 0x0001 }, { 1488, 0x0601 }, + /* 0x5700 */ + { 1491, 0x2918 }, { 1496, 0x814c }, { 1501, 0x2100 }, { 1503, 0x0801 }, + { 1505, 0x6485 }, { 1511, 0x0003 }, { 1513, 0x4452 }, { 1518, 0x1021 }, + { 1521, 0x0904 }, { 1524, 0x0008 }, { 1525, 0x000d }, { 1528, 0x0000 }, + { 1528, 0x4988 }, { 1533, 0x8000 }, { 1534, 0x0001 }, { 1535, 0x1691 }, + /* 0x5800 */ + { 1541, 0x0765 }, { 1548, 0x4000 }, { 1549, 0x8492 }, { 1554, 0x0433 }, + { 1559, 0x8c00 }, { 1562, 0x4592 }, { 1568, 0x0016 }, { 1571, 0x5220 }, + { 1575, 0x0228 }, { 1578, 0xd008 }, { 1582, 0x4300 }, { 1585, 0x4c08 }, + { 1589, 0x40a2 }, { 1593, 0xc32a }, { 1600, 0x9810 }, { 1604, 0x2e00 }, + /* 0x5900 */ + { 1608, 0x8000 }, { 1609, 0x1670 }, { 1615, 0x6e84 }, { 1622, 0x4082 }, + { 1625, 0xc390 }, { 1631, 0x04b3 }, { 1637, 0x7c85 }, { 1645, 0x2118 }, + { 1649, 0x041c }, { 1653, 0x02c8 }, { 1657, 0x1120 }, { 1660, 0x4a00 }, + { 1663, 0x0a48 }, { 1667, 0x361b }, { 1675, 0x5540 }, { 1680, 0x8900 }, + /* 0x5a00 */ + { 1683, 0x000a }, { 1685, 0x9902 }, { 1690, 0x0221 }, { 1693, 0x1040 }, + { 1695, 0x0242 }, { 1698, 0x0400 }, { 1699, 0x0044 }, { 1701, 0x0000 }, + { 1701, 0x0000 }, { 1701, 0x0c04 }, { 1704, 0x0010 }, { 1705, 0x0000 }, + { 1705, 0x1216 }, { 1710, 0x0000 }, { 1710, 0x0242 }, { 1713, 0x0000 }, + /* 0x5b00 */ + { 1713, 0x1a20 }, { 1717, 0x0040 }, { 1718, 0x0400 }, { 1719, 0x0000 }, + { 1719, 0x0009 }, { 1721, 0xb5b3 }, { 1731, 0x0a18 }, { 1735, 0x1523 }, + { 1741, 0x9ba0 }, { 1748, 0x1fe8 }, { 1757, 0x507c }, { 1764, 0x8379 }, + { 1772, 0x10fd }, { 1780, 0xc09d }, { 1787, 0xdbf6 }, { 1799, 0x0560 }, + /* 0x5c00 */ + { 1803, 0xef92 }, { 1813, 0x0242 }, { 1816, 0x0110 }, { 1818, 0xdf02 }, + { 1826, 0x6961 }, { 1833, 0x0822 }, { 1836, 0x9035 }, { 1842, 0x0202 }, + { 1844, 0x0000 }, { 1844, 0x0003 }, { 1846, 0x1a02 }, { 1850, 0x45aa }, + { 1857, 0x0001 }, { 1858, 0x0200 }, { 1859, 0x8101 }, { 1862, 0x2851 }, + /* 0x5d00 */ + { 1867, 0x6080 }, { 1870, 0x02d2 }, { 1875, 0x0280 }, { 1877, 0x0000 }, + { 1877, 0x1800 }, { 1879, 0x0001 }, { 1880, 0x9200 }, { 1883, 0x0000 }, + { 1883, 0x0880 }, { 1885, 0x2000 }, { 1886, 0x0405 }, { 1889, 0x3500 }, + { 1893, 0x2000 }, { 1894, 0x6044 }, { 1898, 0x49e6 }, { 1906, 0x609e }, + /* 0x5e00 */ + { 1913, 0x104c }, { 1917, 0x2a42 }, { 1922, 0x2820 }, { 1925, 0xa148 }, + { 1930, 0x10b1 }, { 1935, 0x8020 }, { 1937, 0x000e }, { 1940, 0x7b9c }, + { 1950, 0x8490 }, { 1954, 0x14a0 }, { 1958, 0x28c1 }, { 1963, 0x41e0 }, + { 1968, 0x0704 }, { 1972, 0x8c49 }, { 1978, 0x100d }, { 1982, 0x0cc8 }, + /* 0x5f00 */ + { 1987, 0x8412 }, { 1991, 0x89ba }, { 1999, 0x02c0 }, { 2002, 0x1422 }, + { 2006, 0x5500 }, { 2010, 0x0ac0 }, { 2014, 0x3ec4 }, { 2022, 0x9283 }, + { 2028, 0x1ca3 }, { 2035, 0x4387 }, { 2042, 0x4703 }, { 2048, 0x22a0 }, + { 2052, 0x3028 }, { 2056, 0x03c0 }, { 2060, 0x0801 }, { 2062, 0xa020 }, + /* 0x6000 */ + { 2065, 0x8000 }, { 2066, 0x3044 }, { 2070, 0x85a3 }, { 2077, 0x0000 }, + { 2077, 0x200e }, { 2081, 0x2225 }, { 2086, 0xb73c }, { 2096, 0x0001 }, + { 2097, 0x3220 }, { 2101, 0x8c50 }, { 2106, 0x0099 }, { 2110, 0x315d }, + { 2118, 0x00a0 }, { 2120, 0x9402 }, { 2124, 0x0003 }, { 2126, 0x0e4b }, + /* 0x6100 */ + { 2133, 0xe342 }, { 2140, 0x8c20 }, { 2144, 0x0080 }, { 2145, 0xd091 }, + { 2151, 0x1d94 }, { 2158, 0xa328 }, { 2164, 0x499c }, { 2171, 0x60c1 }, + { 2176, 0x4406 }, { 2180, 0x0713 }, { 2186, 0x5a90 }, { 2192, 0x4444 }, + { 2196, 0x0f88 }, { 2202, 0x0000 }, { 2202, 0x0040 }, { 2203, 0x95c4 }, + /* 0x6200 */ + { 2210, 0x7581 }, { 2217, 0x8447 }, { 2223, 0x4402 }, { 2226, 0xc053 }, + { 2232, 0x2b83 }, { 2239, 0x0108 }, { 2241, 0x4000 }, { 2242, 0x9242 }, + { 2247, 0x0611 }, { 2251, 0x09a6 }, { 2257, 0x0800 }, { 2258, 0x3222 }, + { 2263, 0xb384 }, { 2270, 0x1bdd }, { 2280, 0xf000 }, { 2284, 0xc08a }, + /* 0x6300 */ + { 2289, 0x0282 }, { 2292, 0x0002 }, { 2293, 0x8800 }, { 2295, 0x6c00 }, + { 2299, 0x9200 }, { 2302, 0x0021 }, { 2304, 0x4180 }, { 2307, 0x8c84 }, + { 2312, 0x1308 }, { 2316, 0x0944 }, { 2320, 0x07a7 }, { 2328, 0x0000 }, + { 2328, 0x8051 }, { 2332, 0x0c41 }, { 2336, 0x6002 }, { 2339, 0x00d0 }, + /* 0x6400 */ + { 2342, 0xa000 }, { 2344, 0x10d0 }, { 2348, 0x3004 }, { 2351, 0x4400 }, + { 2353, 0x0000 }, { 2353, 0x0100 }, { 2354, 0x8201 }, { 2357, 0x0700 }, + { 2360, 0x0100 }, { 2361, 0x440e }, { 2366, 0x6830 }, { 2371, 0x0805 }, + { 2374, 0x64b2 }, { 2381, 0x0514 }, { 2385, 0x10e6 }, { 2391, 0x4414 }, + /* 0x6500 */ + { 2395, 0x0011 }, { 2397, 0x2100 }, { 2399, 0x9c08 }, { 2404, 0xcbc0 }, + { 2411, 0xe120 }, { 2416, 0x40c2 }, { 2420, 0x304c }, { 2425, 0x41b4 }, + { 2431, 0x10ac }, { 2436, 0x9a83 }, { 2443, 0x98b2 }, { 2450, 0x3281 }, + { 2455, 0x9822 }, { 2460, 0x0084 }, { 2462, 0x3369 }, { 2470, 0xbc12 }, + /* 0x6600 */ + { 2477, 0xd6c0 }, { 2484, 0xc03b }, { 2491, 0xa1a1 }, { 2497, 0x0c53 }, + { 2503, 0x8a1e }, { 2510, 0xea00 }, { 2515, 0xcbf0 }, { 2524, 0x05d8 }, + { 2530, 0x4390 }, { 2535, 0x21c3 }, { 2541, 0x4805 }, { 2545, 0x4a1c }, + { 2551, 0x02d0 }, { 2555, 0x3240 }, { 2559, 0x0041 }, { 2561, 0xd79d }, + /* 0x6700 */ + { 2572, 0x2b09 }, { 2578, 0xe8b0 }, { 2585, 0x7dc0 }, { 2593, 0x2452 }, + { 2598, 0xc240 }, { 2602, 0xd04b }, { 2609, 0xa000 }, { 2611, 0xc8ab }, + { 2619, 0x8a80 }, { 2623, 0x34a9 }, { 2630, 0x8000 }, { 2631, 0x41c9 }, + { 2637, 0x8010 }, { 2639, 0x241f }, { 2646, 0x9200 }, { 2649, 0x487b }, + /* 0x6800 */ + { 2657, 0x0000 }, { 2657, 0x00cc }, { 2661, 0x8406 }, { 2665, 0x3300 }, + { 2669, 0x410f }, { 2675, 0x001b }, { 2679, 0x2000 }, { 2680, 0x8040 }, + { 2682, 0x8022 }, { 2685, 0xa098 }, { 2690, 0xa186 }, { 2696, 0x006b }, + { 2701, 0x2a30 }, { 2706, 0x85a4 }, { 2712, 0x4181 }, { 2716, 0x0604 }, + /* 0x6900 */ + { 2719, 0x6021 }, { 2723, 0x0004 }, { 2724, 0x0080 }, { 2725, 0xa001 }, + { 2728, 0x0400 }, { 2729, 0x46b8 }, { 2736, 0xe90f }, { 2745, 0x03a0 }, + { 2749, 0x0000 }, { 2749, 0x1820 }, { 2752, 0x40a0 }, { 2755, 0x0810 }, + { 2757, 0x380a }, { 2762, 0x0001 }, { 2763, 0x0500 }, { 2765, 0xa800 }, + /* 0x6a00 */ + { 2768, 0x0404 }, { 2770, 0xc28a }, { 2776, 0x000a }, { 2778, 0x2720 }, + { 2783, 0x0910 }, { 2786, 0x830c }, { 2791, 0x0802 }, { 2793, 0x0000 }, + { 2793, 0x6211 }, { 2798, 0x1080 }, { 2800, 0x000c }, { 2802, 0x0808 }, + { 2804, 0x000c }, { 2806, 0x0c08 }, { 2809, 0x0000 }, { 2809, 0x0840 }, + /* 0x6b00 */ + { 2811, 0x1410 }, { 2814, 0x0044 }, { 2816, 0x000b }, { 2819, 0x6404 }, + { 2823, 0x50c0 }, { 2827, 0x8001 }, { 2829, 0x047e }, { 2836, 0x8984 }, + { 2841, 0x0658 }, { 2846, 0x4140 }, { 2849, 0xc000 }, { 2851, 0x94a4 }, + { 2857, 0xa862 }, { 2863, 0x09dc }, { 2870, 0x1800 }, { 2872, 0x0000 }, + /* 0x6c00 */ + { 2872, 0x8100 }, { 2874, 0x000a }, { 2876, 0x0008 }, { 2877, 0x4190 }, + { 2881, 0x4007 }, { 2885, 0xe4a1 }, { 2892, 0x2501 }, { 2896, 0x6445 }, + { 2902, 0x11ee }, { 2910, 0x0e7d }, { 2919, 0x4800 }, { 2921, 0xfb08 }, + { 2929, 0x1616 }, { 2935, 0x08a8 }, { 2939, 0xc92e }, { 2947, 0x0009 }, + /* 0x6d00 */ + { 2949, 0x1800 }, { 2951, 0x4a82 }, { 2956, 0x06a0 }, { 2960, 0x6b64 }, + { 2968, 0x0002 }, { 2969, 0x1600 }, { 2972, 0x5648 }, { 2978, 0x8390 }, + { 2983, 0x73a0 }, { 2990, 0x002a }, { 2993, 0x8000 }, { 2994, 0x0024 }, + { 2996, 0x88f9 }, { 3004, 0x4702 }, { 3009, 0x4d02 }, { 3014, 0x0faa }, + /* 0x6e00 */ + { 3022, 0x0000 }, { 3022, 0x8e80 }, { 3027, 0xb87b }, { 3037, 0x7554 }, + { 3045, 0x2418 }, { 3049, 0xd940 }, { 3055, 0xc880 }, { 3059, 0x040c }, + { 3062, 0x0000 }, { 3062, 0xb041 }, { 3067, 0x8c24 }, { 3072, 0x0442 }, + { 3075, 0x5a34 }, { 3082, 0x001a }, { 3085, 0x8000 }, { 3086, 0xc110 }, + /* 0x6f00 */ + { 3090, 0x8046 }, { 3094, 0x0032 }, { 3097, 0x180d }, { 3102, 0x8106 }, + { 3106, 0x0002 }, { 3107, 0xcd92 }, { 3115, 0x6014 }, { 3119, 0x7401 }, + { 3124, 0x6112 }, { 3129, 0x0091 }, { 3132, 0xc098 }, { 3137, 0x420a }, + { 3141, 0x040f }, { 3146, 0x8420 }, { 3149, 0x9a13 }, { 3156, 0x4002 }, + /* 0x7000 */ + { 3158, 0x8a62 }, { 3164, 0xfd22 }, { 3173, 0x8188 }, { 3177, 0x4080 }, + { 3179, 0x1000 }, { 3180, 0x2103 }, { 3184, 0x0808 }, { 3186, 0x3101 }, + { 3190, 0x4420 }, { 3193, 0x0704 }, { 3197, 0xb812 }, { 3203, 0x0388 }, + { 3207, 0x8900 }, { 3210, 0xa300 }, { 3214, 0x0000 }, { 3214, 0x2202 }, + /* 0x7100 */ + { 3217, 0x1210 }, { 3220, 0x4600 }, { 3223, 0x0042 }, { 3225, 0x0041 }, + { 3227, 0x5680 }, { 3232, 0x5241 }, { 3237, 0x52f0 }, { 3244, 0x2000 }, + { 3245, 0x8610 }, { 3249, 0x8214 }, { 3253, 0x1004 }, { 3255, 0x4602 }, + { 3259, 0x430a }, { 3264, 0x8035 }, { 3269, 0x60e0 }, { 3274, 0xd800 }, + /* 0x7200 */ + { 3278, 0x0041 }, { 3280, 0x0801 }, { 3282, 0x3400 }, { 3285, 0x6c65 }, + { 3293, 0x11c1 }, { 3298, 0xab04 }, { 3304, 0x0286 }, { 3308, 0x2204 }, + { 3311, 0x0003 }, { 3313, 0x0000 }, { 3313, 0x9084 }, { 3317, 0x0000 }, + { 3317, 0x4015 }, { 3321, 0x0281 }, { 3324, 0x0202 }, { 3326, 0x3300 }, + /* 0x7300 */ + { 3330, 0x0400 }, { 3331, 0x3840 }, { 3335, 0x0e20 }, { 3339, 0xc0c0 }, + { 3343, 0x0030 }, { 3345, 0x0085 }, { 3348, 0x0500 }, { 3350, 0x0d25 }, + { 3356, 0x4ad0 }, { 3362, 0x81d0 }, { 3367, 0x2280 }, { 3370, 0x020c }, + { 3373, 0xb605 }, { 3380, 0x6240 }, { 3384, 0x2679 }, { 3392, 0x6280 }, + /* 0x7400 */ + { 3396, 0x02ea }, { 3402, 0x0808 }, { 3404, 0xdd67 }, { 3415, 0x8579 }, + { 3423, 0x081b }, { 3428, 0xdea0 }, { 3436, 0x8735 }, { 3444, 0x4000 }, + { 3445, 0x0a8c }, { 3450, 0xd100 }, { 3454, 0x05aa }, { 3460, 0xa225 }, + { 3466, 0x8440 }, { 3469, 0x1510 }, { 3473, 0x404d }, { 3478, 0x0080 }, + /* 0x7500 */ + { 3479, 0x0012 }, { 3481, 0x8d22 }, { 3487, 0x1968 }, { 3493, 0x058f }, + { 3500, 0x9080 }, { 3503, 0x3a1a }, { 3510, 0x8464 }, { 3515, 0x8561 }, + { 3521, 0xccc0 }, { 3527, 0x2002 }, { 3529, 0x0820 }, { 3531, 0x732e }, + { 3540, 0x20a4 }, { 3544, 0x0b34 }, { 3550, 0x0004 }, { 3551, 0x1415 }, + /* 0x7600 */ + { 3556, 0x2001 }, { 3558, 0x8200 }, { 3560, 0x0057 }, { 3565, 0x0800 }, + { 3566, 0x5004 }, { 3569, 0x0044 }, { 3571, 0x1212 }, { 3575, 0x7905 }, + { 3582, 0x40d0 }, { 3586, 0x0009 }, { 3588, 0x4000 }, { 3589, 0x8400 }, + { 3591, 0x054c }, { 3596, 0xd844 }, { 3602, 0x409a }, { 3607, 0x5114 }, + /* 0x7700 */ + { 3612, 0x0b12 }, { 3617, 0x4000 }, { 3618, 0x0201 }, { 3620, 0x1580 }, + { 3624, 0x2001 }, { 3626, 0x0800 }, { 3627, 0x084a }, { 3631, 0xc200 }, + { 3634, 0x0800 }, { 3635, 0x4002 }, { 3637, 0x3020 }, { 3640, 0x9809 }, + { 3645, 0x0000 }, { 3645, 0x1880 }, { 3648, 0xe22c }, { 3655, 0x0008 }, + /* 0x7800 */ + { 3656, 0x0004 }, { 3657, 0x0004 }, { 3658, 0x10e0 }, { 3662, 0x0014 }, + { 3664, 0x8020 }, { 3666, 0x2000 }, { 3667, 0x9800 }, { 3670, 0x1000 }, + { 3671, 0x7082 }, { 3676, 0x0082 }, { 3678, 0x0288 }, { 3681, 0x1c00 }, + { 3684, 0x4c22 }, { 3689, 0x0001 }, { 3690, 0x9100 }, { 3693, 0x0820 }, + /* 0x7900 */ + { 3695, 0x4002 }, { 3697, 0x0040 }, { 3698, 0x1c00 }, { 3701, 0x4400 }, + { 3703, 0x0383 }, { 3708, 0x7cc1 }, { 3716, 0x2121 }, { 3720, 0x8400 }, + { 3722, 0xe002 }, { 3726, 0x0002 }, { 3727, 0x44c0 }, { 3731, 0xe20a }, + { 3737, 0x0e03 }, { 3742, 0x8126 }, { 3747, 0x02d0 }, { 3751, 0x0800 }, + /* 0x7a00 */ + { 3752, 0x2921 }, { 3757, 0x9690 }, { 3763, 0x4001 }, { 3765, 0xb8c2 }, + { 3772, 0x6241 }, { 3777, 0x0080 }, { 3778, 0x0a06 }, { 3782, 0xa651 }, + { 3789, 0x0112 }, { 3792, 0x812c }, { 3797, 0xc600 }, { 3801, 0x0400 }, + { 3802, 0x0cb0 }, { 3807, 0xa280 }, { 3811, 0xa429 }, { 3817, 0x8640 }, + /* 0x7b00 */ + { 3821, 0x8000 }, { 3822, 0x4a02 }, { 3826, 0x3041 }, { 3830, 0x0200 }, + { 3831, 0xba40 }, { 3837, 0x0057 }, { 3842, 0x5001 }, { 3845, 0x2020 }, + { 3847, 0x8880 }, { 3850, 0x24b0 }, { 3855, 0x2002 }, { 3857, 0x0112 }, + { 3860, 0x02d3 }, { 3866, 0x0004 }, { 3867, 0x0211 }, { 3870, 0x0000 }, + /* 0x7c00 */ + { 3870, 0x0080 }, { 3871, 0x4004 }, { 3873, 0x0c82 }, { 3877, 0xe000 }, + { 3880, 0x3008 }, { 3883, 0x0000 }, { 3883, 0x1011 }, { 3886, 0x0008 }, + { 3887, 0x0208 }, { 3889, 0x81a4 }, { 3894, 0x40a0 }, { 3897, 0x420e }, + { 3902, 0x0400 }, { 3903, 0xc040 }, { 3906, 0x0081 }, { 3908, 0x4800 }, + /* 0x7d00 */ + { 3910, 0x2df5 }, { 3920, 0x0f91 }, { 3927, 0xd807 }, { 3934, 0x0629 }, + { 3939, 0x007c }, { 3944, 0x4001 }, { 3946, 0x4546 }, { 3952, 0x824e }, + { 3958, 0xc000 }, { 3960, 0x1008 }, { 3962, 0x3005 }, { 3966, 0xed36 }, + { 3976, 0x0c80 }, { 3979, 0x6540 }, { 3984, 0x930b }, { 3991, 0x0810 }, + /* 0x7e00 */ + { 3993, 0x0600 }, { 3995, 0xe820 }, { 4000, 0xc80a }, { 4005, 0x6082 }, + { 4009, 0x00ca }, { 4013, 0x4034 }, { 4017, 0x2e02 }, { 4022, 0x1201 }, + { 4025, 0x9004 }, { 4028, 0x1948 }, { 4033, 0x0000 }, { 4033, 0x0000 }, + { 4033, 0x0000 }, { 4033, 0x0000 }, { 4033, 0x0000 }, { 4033, 0x0000 }, + /* 0x7f00 */ + { 4033, 0x0000 }, { 4033, 0x0000 }, { 4033, 0x0000 }, { 4033, 0x0540 }, + { 4036, 0x1000 }, { 4037, 0x0031 }, { 4040, 0x4c00 }, { 4043, 0x02a5 }, + { 4048, 0x5520 }, { 4053, 0x4410 }, { 4056, 0x0310 }, { 4059, 0x2304 }, + { 4063, 0x5422 }, { 4068, 0x8034 }, { 4072, 0x0a03 }, { 4076, 0x1201 }, + /* 0x8000 */ + { 4079, 0x126b }, { 4086, 0x01a1 }, { 4090, 0x2000 }, { 4091, 0xa048 }, + { 4095, 0x0448 }, { 4098, 0x4540 }, { 4102, 0x8000 }, { 4103, 0xe08d }, + { 4110, 0x1af0 }, { 4117, 0x2840 }, { 4120, 0x8626 }, { 4126, 0x0416 }, + { 4130, 0x5018 }, { 4134, 0x4c00 }, { 4137, 0x0032 }, { 4140, 0x2112 }, + /* 0x8100 */ + { 4144, 0x05e4 }, { 4150, 0x0d00 }, { 4153, 0x8a08 }, { 4157, 0x4200 }, + { 4159, 0x4800 }, { 4161, 0x0033 }, { 4165, 0x0860 }, { 4168, 0x8703 }, + { 4174, 0x8501 }, { 4178, 0x3400 }, { 4181, 0x0109 }, { 4184, 0xe428 }, + { 4190, 0x2045 }, { 4194, 0x8100 }, { 4196, 0x25a8 }, { 4202, 0x5c18 }, + /* 0x8200 */ + { 4208, 0x35a0 }, { 4214, 0xd804 }, { 4219, 0x1c02 }, { 4223, 0x02e0 }, + { 4227, 0x00a1 }, { 4230, 0x0200 }, { 4231, 0xc050 }, { 4235, 0x4146 }, + { 4240, 0x6800 }, { 4243, 0xa604 }, { 4248, 0xf260 }, { 4255, 0xbb8a }, + { 4264, 0x0000 }, { 4264, 0xc8b6 }, { 4272, 0x00e2 }, { 4276, 0x6002 }, + /* 0x8300 */ + { 4279, 0x023e }, { 4285, 0x0080 }, { 4286, 0x8900 }, { 4289, 0x0372 }, + { 4295, 0x8681 }, { 4300, 0x0006 }, { 4302, 0x0000 }, { 4302, 0x0888 }, + { 4305, 0x4600 }, { 4308, 0x4140 }, { 4311, 0x0e04 }, { 4315, 0x2000 }, + { 4316, 0x1622 }, { 4321, 0x1048 }, { 4324, 0x8a00 }, { 4327, 0x2217 }, + /* 0x8400 */ + { 4333, 0x7418 }, { 4339, 0x0000 }, { 4339, 0x1200 }, { 4341, 0x2102 }, + { 4344, 0x0200 }, { 4345, 0x0880 }, { 4347, 0x984a }, { 4353, 0x0420 }, + { 4355, 0x0000 }, { 4355, 0x1211 }, { 4359, 0x0002 }, { 4360, 0x9904 }, + { 4365, 0x2a55 }, { 4372, 0x0402 }, { 4374, 0x5000 }, { 4376, 0x1010 }, + /* 0x8500 */ + { 4378, 0x0000 }, { 4378, 0x459a }, { 4385, 0xb02a }, { 4391, 0xa000 }, + { 4393, 0x420a }, { 4397, 0x0208 }, { 4399, 0x2708 }, { 4404, 0x0000 }, + { 4404, 0x8090 }, { 4407, 0x0812 }, { 4410, 0x8740 }, { 4415, 0x0401 }, + { 4417, 0xe202 }, { 4422, 0x3020 }, { 4425, 0x0630 }, { 4429, 0x8c80 }, + /* 0x8600 */ + { 4433, 0x04c4 }, { 4437, 0x04c0 }, { 4440, 0x2000 }, { 4441, 0x8000 }, + { 4442, 0x4000 }, { 4443, 0xd831 }, { 4450, 0x0080 }, { 4451, 0x0200 }, + { 4452, 0x1400 }, { 4454, 0x0008 }, { 4455, 0x0218 }, { 4458, 0x0000 }, + { 4458, 0x0880 }, { 4460, 0x8a10 }, { 4464, 0x2010 }, { 4466, 0x4000 }, + /* 0x8700 */ + { 4467, 0x010d }, { 4471, 0x1500 }, { 4474, 0x0000 }, { 4474, 0x0000 }, + { 4474, 0x4000 }, { 4475, 0x80a0 }, { 4478, 0x0140 }, { 4480, 0x0150 }, + { 4483, 0x2004 }, { 4485, 0x8000 }, { 4486, 0x0004 }, { 4487, 0x0408 }, + { 4489, 0x0010 }, { 4490, 0x0000 }, { 4490, 0x9001 }, { 4493, 0x4a04 }, + /* 0x8800 */ + { 4497, 0x0020 }, { 4498, 0x8000 }, { 4499, 0x000c }, { 4501, 0x0842 }, + { 4504, 0x3041 }, { 4508, 0x2a8c }, { 4514, 0x090e }, { 4519, 0xc085 }, + { 4524, 0x2906 }, { 4529, 0x40c4 }, { 4533, 0x0800 }, { 4534, 0x0010 }, + { 4535, 0x8006 }, { 4538, 0xb230 }, { 4544, 0x0102 }, { 4546, 0x2138 }, + /* 0x8900 */ + { 4551, 0x0080 }, { 4552, 0x030d }, { 4557, 0x0420 }, { 4559, 0x0940 }, + { 4562, 0x0012 }, { 4564, 0x8000 }, { 4565, 0x0410 }, { 4567, 0x8004 }, + { 4569, 0x88ca }, { 4575, 0x0048 }, { 4577, 0x0602 }, { 4580, 0x2404 }, + { 4583, 0x0001 }, { 4584, 0x0004 }, { 4585, 0x0008 }, { 4586, 0x0110 }, + /* 0x8a00 */ + { 4588, 0x550d }, { 4595, 0xa9c8 }, { 4602, 0x2428 }, { 4606, 0x0c52 }, + { 4611, 0x0000 }, { 4611, 0x4831 }, { 4616, 0x624d }, { 4623, 0x022f }, + { 4629, 0x30a0 }, { 4633, 0x4128 }, { 4637, 0x057b }, { 4645, 0xd205 }, + { 4651, 0xa894 }, { 4657, 0x1844 }, { 4661, 0x6cc2 }, { 4668, 0x45c2 }, + /* 0x8b00 */ + { 4674, 0x4017 }, { 4679, 0x2ed1 }, { 4687, 0x1901 }, { 4691, 0x0208 }, + { 4693, 0xc202 }, { 4697, 0x1500 }, { 4700, 0x9040 }, { 4703, 0x2091 }, + { 4707, 0x0401 }, { 4709, 0x044d }, { 4714, 0x0000 }, { 4714, 0x0000 }, + { 4714, 0x0000 }, { 4714, 0x0000 }, { 4714, 0x0000 }, { 4714, 0x0000 }, + /* 0x8c00 */ + { 4714, 0x0000 }, { 4714, 0x0000 }, { 4714, 0x0000 }, { 4714, 0x8080 }, + { 4716, 0x1542 }, { 4721, 0x0420 }, { 4723, 0x0c02 }, { 4726, 0x0600 }, + { 4728, 0x1404 }, { 4731, 0x6000 }, { 4733, 0x9f87 }, { 4743, 0xb9d9 }, + { 4753, 0x059f }, { 4761, 0x540a }, { 4766, 0x245d }, { 4773, 0x3810 }, + /* 0x8d00 */ + { 4777, 0x25b0 }, { 4783, 0x0048 }, { 4785, 0x0000 }, { 4785, 0x0000 }, + { 4785, 0x0000 }, { 4785, 0x0000 }, { 4785, 0x0850 }, { 4788, 0x0099 }, + { 4792, 0x0420 }, { 4794, 0x0200 }, { 4795, 0x0108 }, { 4797, 0x4408 }, + { 4800, 0x9840 }, { 4804, 0x2800 }, { 4806, 0x810a }, { 4810, 0x0008 }, + /* 0x8e00 */ + { 4811, 0x8400 }, { 4813, 0x4001 }, { 4815, 0x0400 }, { 4816, 0x0021 }, + { 4818, 0x0794 }, { 4824, 0x8200 }, { 4826, 0x0001 }, { 4827, 0x0050 }, + { 4829, 0x2482 }, { 4833, 0x0000 }, { 4833, 0x1c00 }, { 4836, 0x0000 }, + { 4836, 0x3c01 }, { 4841, 0x8004 }, { 4843, 0x0800 }, { 4844, 0x4900 }, + /* 0x8f00 */ + { 4847, 0x0228 }, { 4850, 0xf83c }, { 4859, 0x86c0 }, { 4864, 0xcb08 }, + { 4870, 0x6230 }, { 4875, 0xa000 }, { 4877, 0x0004 }, { 4878, 0x0000 }, + { 4878, 0x0000 }, { 4878, 0x1800 }, { 4880, 0xa148 }, { 4885, 0x0007 }, + { 4888, 0x4024 }, { 4891, 0x0012 }, { 4893, 0x2c40 }, { 4897, 0x2285 }, + /* 0x9000 */ + { 4902, 0xa96f }, { 4912, 0xe6b3 }, { 4922, 0x400f }, { 4927, 0x5126 }, + { 4933, 0x6c86 }, { 4940, 0x723b }, { 4949, 0xe20b }, { 4956, 0xb5a4 }, + { 4964, 0x859f }, { 4973, 0x0222 }, { 4976, 0x854c }, { 4982, 0x0123 }, + { 4986, 0x0402 }, { 4988, 0x4000 }, { 4989, 0x2102 }, { 4992, 0x2020 }, + /* 0x9100 */ + { 4994, 0x0004 }, { 4995, 0x0224 }, { 4998, 0x2080 }, { 5000, 0x0004 }, + { 5001, 0x7e00 }, { 5007, 0x0004 }, { 5008, 0x1604 }, { 5012, 0x01a0 }, + { 5015, 0x2a80 }, { 5019, 0x1004 }, { 5021, 0xd800 }, { 5025, 0x0032 }, + { 5028, 0xfa81 }, { 5036, 0x3183 }, { 5042, 0x0488 }, { 5045, 0x0020 }, + /* 0x9200 */ + { 5046, 0x2000 }, { 5047, 0x4087 }, { 5052, 0x0000 }, { 5052, 0x8410 }, + { 5055, 0x0221 }, { 5058, 0x4880 }, { 5061, 0x0074 }, { 5065, 0x0000 }, + { 5065, 0x0029 }, { 5068, 0x114a }, { 5073, 0x0000 }, { 5073, 0x02c8 }, + { 5077, 0x9000 }, { 5079, 0x0004 }, { 5080, 0x0410 }, { 5082, 0x1100 }, + /* 0x9300 */ + { 5084, 0x0010 }, { 5085, 0xc501 }, { 5090, 0xc957 }, { 5099, 0x0000 }, + { 5099, 0x2d00 }, { 5103, 0x0810 }, { 5105, 0x4000 }, { 5106, 0x5020 }, + { 5109, 0x1000 }, { 5110, 0x0450 }, { 5113, 0x3088 }, { 5117, 0x0001 }, + { 5118, 0x0008 }, { 5119, 0x4002 }, { 5121, 0x0012 }, { 5123, 0x0040 }, + /* 0x9400 */ + { 5124, 0x0010 }, { 5125, 0x0100 }, { 5126, 0x0820 }, { 5128, 0x0120 }, + { 5130, 0x0010 }, { 5131, 0x0806 }, { 5134, 0x0000 }, { 5134, 0xa000 }, + { 5136, 0x0000 }, { 5136, 0x0000 }, { 5136, 0x0000 }, { 5136, 0x0000 }, + { 5136, 0x0000 }, { 5136, 0x0000 }, { 5136, 0x0000 }, { 5136, 0x0000 }, + /* 0x9500 */ + { 5136, 0x0000 }, { 5136, 0x0000 }, { 5136, 0x0000 }, { 5136, 0x0000 }, + { 5136, 0x0000 }, { 5136, 0x0000 }, { 5136, 0x0000 }, { 5136, 0x0080 }, + { 5137, 0x8a09 }, { 5142, 0x011e }, { 5147, 0x2138 }, { 5152, 0x1802 }, + { 5155, 0x0480 }, { 5157, 0x1070 }, { 5161, 0x0006 }, { 5163, 0x0000 }, + /* 0x9600 */ + { 5163, 0x0000 }, { 5163, 0x1000 }, { 5164, 0x4402 }, { 5167, 0x8804 }, + { 5170, 0x3815 }, { 5176, 0xf801 }, { 5182, 0x041c }, { 5186, 0x21e9 }, + { 5193, 0x6c60 }, { 5199, 0x1b30 }, { 5205, 0x0588 }, { 5209, 0x0882 }, + { 5212, 0x7af3 }, { 5223, 0x1a60 }, { 5228, 0x870c }, { 5234, 0x0ac5 }, + /* 0x9700 */ + { 5240, 0x00c1 }, { 5243, 0x524a }, { 5249, 0x0080 }, { 5250, 0x2205 }, + { 5254, 0x0114 }, { 5257, 0x5042 }, { 5261, 0x2206 }, { 5265, 0x0490 }, + { 5268, 0xa800 }, { 5271, 0x0000 }, { 5271, 0x2901 }, { 5275, 0x0000 }, + { 5275, 0x0840 }, { 5277, 0x1008 }, { 5279, 0x0000 }, { 5279, 0x8848 }, + /* 0x9800 */ + { 5283, 0x156f }, { 5292, 0x018f }, { 5298, 0x2000 }, { 5299, 0x0b01 }, + { 5303, 0x7040 }, { 5307, 0x4510 }, { 5311, 0x88a0 }, { 5315, 0x0000 }, + { 5315, 0x0000 }, { 5315, 0x0000 }, { 5315, 0x8100 }, { 5317, 0x0002 }, + { 5318, 0x0090 }, { 5320, 0x9800 }, { 5323, 0xe006 }, { 5328, 0x7010 }, + /* 0x9900 */ + { 5332, 0x1608 }, { 5336, 0x4109 }, { 5340, 0x0101 }, { 5342, 0x0000 }, + { 5342, 0x3a20 }, { 5347, 0x0096 }, { 5351, 0x0000 }, { 5351, 0x0000 }, + { 5351, 0x0000 }, { 5351, 0x2240 }, { 5354, 0x7120 }, { 5359, 0x021a }, + { 5363, 0x0002 }, { 5364, 0xa227 }, { 5371, 0x2000 }, { 5372, 0x8002 }, + /* 0x9a00 */ + { 5374, 0xc102 }, { 5378, 0x0200 }, { 5379, 0x0800 }, { 5380, 0x00c1 }, + { 5383, 0x2029 }, { 5387, 0x8ca0 }, { 5392, 0x0624 }, { 5396, 0x0000 }, + { 5396, 0x0000 }, { 5396, 0x0000 }, { 5396, 0x0100 }, { 5397, 0x0100 }, + { 5398, 0x0000 }, { 5398, 0x0118 }, { 5401, 0x4020 }, { 5403, 0x0000 }, + /* 0x9b00 */ + { 5403, 0x0000 }, { 5403, 0x0400 }, { 5404, 0x0480 }, { 5406, 0x1002 }, + { 5408, 0x803e }, { 5414, 0x0410 }, { 5416, 0x8000 }, { 5417, 0x0000 }, + { 5417, 0x4000 }, { 5418, 0x8002 }, { 5420, 0x4800 }, { 5422, 0x0000 }, + { 5422, 0x0200 }, { 5423, 0x0040 }, { 5424, 0x0110 }, { 5426, 0x0000 }, + /* 0x9c00 */ + { 5426, 0x2000 }, { 5427, 0x0025 }, { 5430, 0x0020 }, { 5431, 0x0804 }, + { 5433, 0x0280 }, { 5435, 0x0080 }, { 5436, 0x0000 }, { 5436, 0x0000 }, + { 5436, 0x0000 }, { 5436, 0x0000 }, { 5436, 0x0000 }, { 5436, 0x0000 }, + { 5436, 0x0000 }, { 5436, 0x0000 }, { 5436, 0x02a0 }, { 5439, 0x0058 }, + /* 0x9d00 */ + { 5442, 0x0200 }, { 5443, 0x0800 }, { 5444, 0x0140 }, { 5446, 0x0800 }, + { 5447, 0x0000 }, { 5447, 0x2002 }, { 5449, 0x1003 }, { 5452, 0x0004 }, + { 5453, 0x0000 }, { 5453, 0x0000 }, { 5453, 0x8200 }, { 5455, 0x0010 }, + { 5456, 0x0010 }, { 5457, 0x0080 }, { 5458, 0x0000 }, { 5458, 0x0704 }, + /* 0x9e00 */ + { 5462, 0x0000 }, { 5462, 0x4400 }, { 5464, 0x0000 }, { 5464, 0x0000 }, + { 5464, 0x0000 }, { 5464, 0x0000 }, { 5464, 0x0000 }, { 5464, 0xa220 }, + { 5468, 0x0000 }, { 5468, 0xa08c }, { 5473, 0x0020 }, { 5474, 0x4830 }, + { 5478, 0x6008 }, { 5481, 0x5912 }, { 5487, 0x0100 }, { 5488, 0x0010 }, + /* 0x9f00 */ + { 5489, 0x4180 }, { 5492, 0x0008 }, { 5493, 0x0001 }, { 5494, 0x0800 }, + { 5495, 0x4c00 }, { 5498, 0x8004 }, { 5500, 0x1482 }, { 5504, 0x0080 }, + { 5505, 0x2000 }, { 5506, 0x1021 }, +}; +static const Summary16 ksc5601_uni2indx_pageac[698] = { + /* 0xac00 */ + { 5509, 0x0793 }, { 5516, 0x3eff }, { 5529, 0xb011 }, { 5534, 0x1303 }, + { 5539, 0x2801 }, { 5542, 0x1110 }, { 5545, 0x0000 }, { 5545, 0x0593 }, + { 5551, 0x1e7b }, { 5561, 0xb011 }, { 5566, 0x9703 }, { 5573, 0x3b01 }, + { 5579, 0x1112 }, { 5583, 0x00a0 }, { 5585, 0x9593 }, { 5593, 0x306b }, + /* 0xad00 */ + { 5600, 0xb051 }, { 5606, 0x1102 }, { 5609, 0x3201 }, { 5613, 0x1130 }, + { 5617, 0x02b0 }, { 5621, 0x0111 }, { 5624, 0x300a }, { 5628, 0xb879 }, + { 5637, 0x1306 }, { 5642, 0x3001 }, { 5645, 0x0010 }, { 5646, 0x0080 }, + { 5647, 0x0113 }, { 5651, 0x100b }, { 5655, 0x0011 }, { 5657, 0x9300 }, + /* 0xae00 */ + { 5661, 0x2b03 }, { 5667, 0x0010 }, { 5668, 0x0000 }, { 5668, 0x0593 }, + { 5674, 0x746b }, { 5683, 0xb051 }, { 5689, 0x1323 }, { 5695, 0x3b01 }, + { 5701, 0x1030 }, { 5704, 0x0000 }, { 5704, 0x0000 }, { 5704, 0x7000 }, + { 5707, 0xb011 }, { 5712, 0x1303 }, { 5717, 0x2900 }, { 5720, 0x1110 }, + /* 0xaf00 */ + { 5723, 0x2180 }, { 5726, 0x0001 }, { 5727, 0x3000 }, { 5729, 0xb015 }, + { 5735, 0x030e }, { 5740, 0x3001 }, { 5743, 0x0030 }, { 5745, 0x0200 }, + { 5746, 0x0111 }, { 5749, 0x1023 }, { 5753, 0x0000 }, { 5753, 0x1300 }, + { 5756, 0x6b81 }, { 5763, 0x1010 }, { 5765, 0x0300 }, { 5767, 0x0113 }, + /* 0xb000 */ + { 5771, 0x1013 }, { 5775, 0x3011 }, { 5779, 0x0100 }, { 5780, 0x0000 }, + { 5780, 0x5530 }, { 5786, 0x22b8 }, { 5792, 0x0000 }, { 5792, 0x3000 }, + { 5794, 0xb011 }, { 5799, 0x9702 }, { 5805, 0xfb07 }, { 5815, 0x113a }, + { 5821, 0x03b0 }, { 5826, 0x0113 }, { 5830, 0x0021 }, { 5832, 0x0000 }, + /* 0xb100 */ + { 5832, 0x1b00 }, { 5836, 0x3b0d }, { 5844, 0x1138 }, { 5849, 0x03b0 }, + { 5854, 0x0113 }, { 5858, 0x1133 }, { 5864, 0x0001 }, { 5865, 0x1300 }, + { 5868, 0x2b05 }, { 5874, 0x111c }, { 5879, 0x0100 }, { 5880, 0x0000 }, + { 5880, 0x1000 }, { 5881, 0xb011 }, { 5886, 0x1300 }, { 5889, 0x2a01 }, + /* 0xb200 */ + { 5893, 0x1930 }, { 5898, 0x02b0 }, { 5902, 0x0001 }, { 5903, 0x1010 }, + { 5905, 0x0000 }, { 5905, 0x1100 }, { 5907, 0x0301 }, { 5910, 0x1030 }, + { 5913, 0x0230 }, { 5916, 0x0713 }, { 5922, 0x146b }, { 5929, 0x0011 }, + { 5931, 0x1300 }, { 5934, 0x2b05 }, { 5940, 0xf974 }, { 5950, 0x8fb8 }, + /* 0xb300 */ + { 5959, 0x0113 }, { 5963, 0x103b }, { 5969, 0x0000 }, { 5969, 0x0000 }, + { 5969, 0x0000 }, { 5969, 0xd970 }, { 5977, 0x4ab0 }, { 5983, 0x0113 }, + { 5987, 0x103b }, { 5993, 0x0011 }, { 5995, 0x1103 }, { 5999, 0x0000 }, + { 5999, 0x5930 }, { 6005, 0x2ab1 }, { 6012, 0x0111 }, { 6015, 0x1000 }, + /* 0xb400 */ + { 6016, 0x0000 }, { 6016, 0x1101 }, { 6019, 0x0b01 }, { 6023, 0x0010 }, + { 6024, 0x0000 }, { 6024, 0x0113 }, { 6028, 0x102b }, { 6033, 0x0000 }, + { 6033, 0x0101 }, { 6035, 0x2000 }, { 6036, 0x1110 }, { 6039, 0x02a0 }, + { 6042, 0x0111 }, { 6045, 0x3021 }, { 6049, 0xb059 }, { 6056, 0x0102 }, + /* 0xb500 */ + { 6058, 0x0000 }, { 6058, 0x1930 }, { 6063, 0x07b0 }, { 6069, 0x0113 }, + { 6073, 0x383b }, { 6081, 0xb011 }, { 6086, 0x0003 }, { 6088, 0x0000 }, + { 6088, 0x0000 }, { 6088, 0x0000 }, { 6088, 0x0d13 }, { 6094, 0x383b }, + { 6102, 0xb011 }, { 6107, 0x0103 }, { 6110, 0x1000 }, { 6111, 0x0000 }, + /* 0xb600 */ + { 6111, 0x0000 }, { 6111, 0x0113 }, { 6115, 0x1020 }, { 6117, 0x0010 }, + { 6118, 0x0100 }, { 6119, 0x0000 }, { 6119, 0x0110 }, { 6121, 0x0000 }, + { 6121, 0x0000 }, { 6121, 0x3000 }, { 6123, 0x1811 }, { 6127, 0x0002 }, + { 6128, 0x0000 }, { 6128, 0x0010 }, { 6129, 0x0000 }, { 6129, 0x0111 }, + /* 0xb700 */ + { 6132, 0x0023 }, { 6135, 0x0000 }, { 6135, 0x9300 }, { 6139, 0x0b01 }, + { 6143, 0x1110 }, { 6146, 0x0030 }, { 6148, 0x0111 }, { 6151, 0x302b }, + { 6157, 0xb011 }, { 6162, 0x13c7 }, { 6170, 0x3b01 }, { 6176, 0x0130 }, + { 6179, 0x0280 }, { 6181, 0x0000 }, { 6181, 0x3000 }, { 6183, 0xb011 }, + /* 0xb800 */ + { 6188, 0x1383 }, { 6194, 0x2b01 }, { 6199, 0x1130 }, { 6203, 0x03b0 }, + { 6208, 0x0011 }, { 6210, 0x300a }, { 6214, 0xb011 }, { 6219, 0x1102 }, + { 6222, 0x2000 }, { 6223, 0x0000 }, { 6223, 0x0100 }, { 6224, 0x0111 }, + { 6227, 0x102b }, { 6232, 0xa011 }, { 6236, 0x1302 }, { 6240, 0x2b01 }, + /* 0xb900 */ + { 6245, 0x0010 }, { 6246, 0x0100 }, { 6247, 0x0001 }, { 6248, 0x3000 }, + { 6250, 0x9011 }, { 6254, 0x1302 }, { 6258, 0x2b01 }, { 6263, 0x1130 }, + { 6267, 0x66b0 }, { 6274, 0x0000 }, { 6274, 0x3000 }, { 6276, 0xb011 }, + { 6281, 0xd302 }, { 6287, 0x6b07 }, { 6295, 0x113a }, { 6301, 0x07b0 }, + /* 0xba00 */ + { 6307, 0x0103 }, { 6310, 0x0020 }, { 6311, 0x0000 }, { 6311, 0x1300 }, + { 6314, 0x6b05 }, { 6321, 0x1138 }, { 6326, 0x03b0 }, { 6331, 0x0113 }, + { 6335, 0x10b8 }, { 6340, 0x0000 }, { 6340, 0x1b00 }, { 6344, 0x2b05 }, + { 6350, 0x0110 }, { 6352, 0x0300 }, { 6354, 0x0000 }, { 6354, 0x1000 }, + /* 0xbb00 */ + { 6355, 0xa011 }, { 6359, 0x1102 }, { 6362, 0x0a01 }, { 6365, 0x7970 }, + { 6373, 0xa2b0 }, { 6379, 0x0111 }, { 6382, 0x100a }, { 6385, 0x0000 }, + { 6385, 0x1100 }, { 6387, 0x0001 }, { 6388, 0x1110 }, { 6391, 0x0090 }, + { 6393, 0x0111 }, { 6396, 0x0009 }, { 6398, 0x0000 }, { 6398, 0x9300 }, + /* 0xbc00 */ + { 6402, 0xbb05 }, { 6410, 0xf9f2 }, { 6421, 0x22b0 }, { 6426, 0x0113 }, + { 6430, 0x323b }, { 6438, 0x2001 }, { 6440, 0x0000 }, { 6440, 0x0000 }, + { 6440, 0x5930 }, { 6446, 0x06b0 }, { 6451, 0x0193 }, { 6456, 0x303b }, + { 6463, 0xa011 }, { 6467, 0x1123 }, { 6472, 0x0000 }, { 6472, 0x1170 }, + /* 0xbd00 */ + { 6477, 0x02b0 }, { 6481, 0x0011 }, { 6483, 0x1010 }, { 6485, 0x0000 }, + { 6485, 0x1301 }, { 6489, 0x0301 }, { 6492, 0x0110 }, { 6494, 0x0000 }, + { 6494, 0x0793 }, { 6501, 0x162b }, { 6508, 0x0010 }, { 6509, 0x0101 }, + { 6511, 0x0000 }, { 6511, 0x1130 }, { 6515, 0x0200 }, { 6516, 0x0111 }, + /* 0xbe00 */ + { 6519, 0x3029 }, { 6524, 0xb011 }, { 6529, 0x0000 }, { 6529, 0x0000 }, + { 6529, 0x5130 }, { 6534, 0x0eb0 }, { 6540, 0x0513 }, { 6545, 0x383b }, + { 6553, 0xb011 }, { 6558, 0x0303 }, { 6562, 0x0100 }, { 6563, 0x0000 }, + { 6563, 0x0000 }, { 6563, 0x0193 }, { 6568, 0x1039 }, { 6573, 0x0000 }, + /* 0xbf00 */ + { 6573, 0x0302 }, { 6576, 0x3b00 }, { 6581, 0x0000 }, { 6581, 0x0000 }, + { 6581, 0x0113 }, { 6585, 0x0023 }, { 6588, 0x0000 }, { 6588, 0x0000 }, + { 6588, 0x0000 }, { 6588, 0x0010 }, { 6589, 0x0000 }, { 6589, 0x0001 }, + { 6590, 0x3020 }, { 6593, 0x9011 }, { 6597, 0x0002 }, { 6598, 0x0000 }, + /* 0xc000 */ + { 6598, 0x0000 }, { 6598, 0x0000 }, { 6598, 0x0000 }, { 6598, 0x1000 }, + { 6599, 0x0000 }, { 6599, 0x1102 }, { 6602, 0x0301 }, { 6605, 0x0000 }, + { 6605, 0x0000 }, { 6605, 0x0113 }, { 6609, 0xb02b }, { 6616, 0xb079 }, + { 6624, 0x1323 }, { 6630, 0x3b01 }, { 6636, 0x1130 }, { 6640, 0x02b0 }, + /* 0xc100 */ + { 6644, 0x0111 }, { 6647, 0xf021 }, { 6653, 0xb0d9 }, { 6661, 0x1343 }, + { 6667, 0x3b01 }, { 6673, 0x1130 }, { 6677, 0x03b0 }, { 6682, 0x0111 }, + { 6685, 0x7020 }, { 6689, 0xb051 }, { 6695, 0x1322 }, { 6700, 0x2001 }, + { 6702, 0x1110 }, { 6705, 0x0190 }, { 6708, 0x0111 }, { 6711, 0x300b }, + /* 0xc200 */ + { 6716, 0xb011 }, { 6721, 0x9302 }, { 6726, 0xab01 }, { 6732, 0x0016 }, + { 6735, 0x0100 }, { 6736, 0x0113 }, { 6740, 0x3021 }, { 6744, 0xb011 }, + { 6749, 0x0302 }, { 6752, 0x2901 }, { 6756, 0x3130 }, { 6761, 0x02b0 }, + { 6765, 0x0000 }, { 6765, 0x3000 }, { 6767, 0xb819 }, { 6774, 0x1b42 }, + /* 0xc300 */ + { 6780, 0x3301 }, { 6785, 0x1138 }, { 6790, 0x0330 }, { 6794, 0x0000 }, + { 6794, 0x0020 }, { 6795, 0x0000 }, { 6795, 0x1300 }, { 6798, 0x3305 }, + { 6804, 0x1110 }, { 6807, 0x0000 }, { 6807, 0x0000 }, { 6807, 0x0000 }, + { 6807, 0x0001 }, { 6808, 0x9300 }, { 6812, 0x2305 }, { 6817, 0x0130 }, + /* 0xc400 */ + { 6820, 0x0100 }, { 6821, 0x0001 }, { 6822, 0x1010 }, { 6824, 0x3011 }, + { 6828, 0x0100 }, { 6829, 0x0000 }, { 6829, 0x1130 }, { 6833, 0x0230 }, + { 6836, 0x0001 }, { 6837, 0x1010 }, { 6839, 0x0000 }, { 6839, 0x1100 }, + { 6841, 0x0000 }, { 6841, 0x0000 }, { 6841, 0x0200 }, { 6842, 0x8513 }, + /* 0xc500 */ + { 6848, 0x1003 }, { 6851, 0x1011 }, { 6854, 0x1300 }, { 6857, 0x2b01 }, + { 6862, 0x7730 }, { 6870, 0x63b8 }, { 6878, 0x0113 }, { 6882, 0x303b }, + { 6889, 0xb091 }, { 6895, 0x11a2 }, { 6900, 0x0201 }, { 6902, 0x7b30 }, + { 6910, 0x57f0 }, { 6919, 0x0113 }, { 6923, 0x702b }, { 6930, 0xf0d1 }, + /* 0xc600 */ + { 6938, 0x11e3 }, { 6945, 0x1b01 }, { 6950, 0x7130 }, { 6956, 0x0ab9 }, + { 6963, 0x0113 }, { 6967, 0x303b }, { 6974, 0x9001 }, { 6977, 0x1302 }, + { 6981, 0x2b01 }, { 6986, 0x1130 }, { 6990, 0x02b0 }, { 6994, 0x0713 }, + { 7000, 0x302b }, { 7006, 0x3011 }, { 7010, 0x1303 }, { 7015, 0x2301 }, + /* 0xc700 */ + { 7019, 0x1130 }, { 7023, 0x02b0 }, { 7027, 0x0113 }, { 7031, 0x30ab }, + { 7038, 0xb411 }, { 7044, 0x11fe }, { 7053, 0x0901 }, { 7056, 0x7130 }, + { 7062, 0x47b8 }, { 7070, 0x05d3 }, { 7077, 0x307b }, { 7085, 0xb011 }, + { 7090, 0x5303 }, { 7096, 0x2101 }, { 7099, 0x1110 }, { 7102, 0x0000 }, + /* 0xc800 */ + { 7102, 0x0513 }, { 7107, 0x306b }, { 7114, 0xb011 }, { 7119, 0x1102 }, + { 7122, 0x3301 }, { 7127, 0x0010 }, { 7128, 0x0000 }, { 7128, 0x0513 }, + { 7133, 0x38eb }, { 7142, 0xa010 }, { 7145, 0x0102 }, { 7147, 0x3000 }, + { 7149, 0x1110 }, { 7152, 0x02b0 }, { 7156, 0x0013 }, { 7159, 0x3020 }, + /* 0xc900 */ + { 7162, 0xb071 }, { 7169, 0x0102 }, { 7171, 0x1000 }, { 7172, 0x0010 }, + { 7173, 0x0000 }, { 7173, 0x0113 }, { 7177, 0x100b }, { 7181, 0x1011 }, + { 7184, 0x1300 }, { 7187, 0x2b01 }, { 7192, 0x0000 }, { 7192, 0x0000 }, + { 7192, 0x0593 }, { 7198, 0x366b }, { 7207, 0xb095 }, { 7214, 0x1303 }, + /* 0xca00 */ + { 7219, 0x3b01 }, { 7225, 0x0110 }, { 7227, 0x0200 }, { 7228, 0x0000 }, + { 7228, 0x3000 }, { 7230, 0xb011 }, { 7235, 0x0103 }, { 7238, 0x2000 }, + { 7239, 0x0010 }, { 7240, 0x0100 }, { 7241, 0x0000 }, { 7241, 0x3000 }, + { 7243, 0xb011 }, { 7248, 0x030a }, { 7252, 0x1001 }, { 7254, 0x0010 }, + /* 0xcb00 */ + { 7255, 0x0100 }, { 7256, 0x0111 }, { 7259, 0x0003 }, { 7261, 0x0000 }, + { 7261, 0x1302 }, { 7265, 0x2301 }, { 7269, 0x0010 }, { 7270, 0x0300 }, + { 7272, 0x0000 }, { 7272, 0x1000 }, { 7273, 0x0000 }, { 7273, 0x0100 }, + { 7274, 0x0000 }, { 7274, 0x0010 }, { 7275, 0x0290 }, { 7278, 0x0000 }, + /* 0xcc00 */ + { 7278, 0x3000 }, { 7280, 0x3011 }, { 7284, 0x5386 }, { 7291, 0x7b01 }, + { 7298, 0x1130 }, { 7302, 0x03b0 }, { 7307, 0x0151 }, { 7311, 0x0021 }, + { 7313, 0x0000 }, { 7313, 0x1300 }, { 7316, 0x3b01 }, { 7322, 0x1130 }, + { 7326, 0x02b0 }, { 7330, 0x0011 }, { 7332, 0x1010 }, { 7334, 0x0001 }, + /* 0xcd00 */ + { 7335, 0x1302 }, { 7339, 0x2b01 }, { 7344, 0x1110 }, { 7347, 0x0200 }, + { 7348, 0x0000 }, { 7348, 0x1000 }, { 7349, 0xb011 }, { 7354, 0x0102 }, + { 7356, 0x0100 }, { 7357, 0x1130 }, { 7361, 0x02b0 }, { 7365, 0x0001 }, + { 7366, 0x1010 }, { 7368, 0x0001 }, { 7369, 0x1100 }, { 7371, 0x2b01 }, + /* 0xce00 */ + { 7376, 0x1110 }, { 7379, 0x0210 }, { 7381, 0x0113 }, { 7385, 0x002b }, + { 7389, 0x0000 }, { 7389, 0x9300 }, { 7393, 0x2b03 }, { 7399, 0x1130 }, + { 7403, 0x02b0 }, { 7407, 0x0113 }, { 7411, 0x303b }, { 7418, 0x0000 }, + { 7418, 0x0002 }, { 7419, 0x0000 }, { 7419, 0x1930 }, { 7424, 0x03b0 }, + /* 0xcf00 */ + { 7429, 0x0113 }, { 7433, 0x102b }, { 7438, 0xb011 }, { 7443, 0x0103 }, + { 7446, 0x0000 }, { 7446, 0x1130 }, { 7450, 0x02b0 }, { 7454, 0x0113 }, + { 7458, 0x1021 }, { 7461, 0x0000 }, { 7461, 0x0102 }, { 7463, 0x0001 }, + { 7464, 0x0010 }, { 7465, 0x0000 }, { 7465, 0x0113 }, { 7469, 0x102b }, + /* 0xd000 */ + { 7474, 0x0011 }, { 7476, 0x0102 }, { 7478, 0x2000 }, { 7479, 0x1130 }, + { 7483, 0x02b0 }, { 7487, 0x0111 }, { 7490, 0x3001 }, { 7493, 0x3011 }, + { 7497, 0x0002 }, { 7498, 0x0000 }, { 7498, 0x1130 }, { 7502, 0x02b0 }, + { 7506, 0x0313 }, { 7511, 0x303b }, { 7518, 0xb011 }, { 7523, 0x0103 }, + /* 0xd100 */ + { 7526, 0x2000 }, { 7527, 0x0000 }, { 7527, 0x0000 }, { 7527, 0x0513 }, + { 7532, 0x303b }, { 7539, 0xb011 }, { 7544, 0x1102 }, { 7547, 0x1000 }, + { 7548, 0x0110 }, { 7550, 0x0000 }, { 7550, 0x0113 }, { 7554, 0x142b }, + { 7560, 0x0001 }, { 7561, 0x0100 }, { 7562, 0x0000 }, { 7562, 0x0110 }, + /* 0xd200 */ + { 7564, 0x0280 }, { 7566, 0x0001 }, { 7567, 0x3000 }, { 7569, 0xb011 }, + { 7574, 0x0102 }, { 7576, 0x1000 }, { 7577, 0x0010 }, { 7578, 0x0000 }, + { 7578, 0x0113 }, { 7582, 0x1023 }, { 7586, 0x1011 }, { 7589, 0x9302 }, + { 7594, 0x0b05 }, { 7599, 0x1110 }, { 7602, 0x0030 }, { 7604, 0x0113 }, + /* 0xd300 */ + { 7608, 0x702b }, { 7615, 0xb051 }, { 7621, 0x1323 }, { 7627, 0x3b01 }, + { 7633, 0x0030 }, { 7635, 0x0000 }, { 7635, 0x0000 }, { 7635, 0x3000 }, + { 7637, 0xb011 }, { 7642, 0x1303 }, { 7647, 0x2b01 }, { 7652, 0x1110 }, + { 7655, 0x0330 }, { 7659, 0x0101 }, { 7661, 0x300a }, { 7665, 0xb011 }, + /* 0xd400 */ + { 7670, 0x0102 }, { 7672, 0x2000 }, { 7673, 0x0000 }, { 7673, 0x0000 }, + { 7673, 0x0011 }, { 7675, 0x1000 }, { 7676, 0xa011 }, { 7680, 0x9300 }, + { 7684, 0x2b05 }, { 7690, 0x0010 }, { 7691, 0x0200 }, { 7692, 0x0000 }, + { 7692, 0x1000 }, { 7693, 0x9011 }, { 7697, 0x1100 }, { 7699, 0x2901 }, + /* 0xd500 */ + { 7703, 0x1110 }, { 7706, 0x00b0 }, { 7709, 0x0000 }, { 7709, 0x3000 }, + { 7711, 0xb011 }, { 7716, 0x1302 }, { 7720, 0x2b21 }, { 7726, 0x1130 }, + { 7730, 0x03b0 }, { 7735, 0x0001 }, { 7736, 0x0020 }, { 7737, 0x0000 }, + { 7737, 0x1300 }, { 7740, 0x2b05 }, { 7746, 0x1130 }, { 7750, 0x02b0 }, + /* 0xd600 */ + { 7754, 0x0113 }, { 7758, 0x103b }, { 7764, 0x2011 }, { 7767, 0x1300 }, + { 7770, 0x2b21 }, { 7776, 0x1132 }, { 7781, 0x0280 }, { 7783, 0x0013 }, + { 7786, 0x3028 }, { 7790, 0xa011 }, { 7794, 0x1102 }, { 7797, 0x0a01 }, + { 7800, 0x1130 }, { 7804, 0x0292 }, { 7808, 0x0111 }, { 7811, 0x3021 }, + /* 0xd700 */ + { 7815, 0x0011 }, { 7817, 0x1302 }, { 7821, 0x2b01 }, { 7826, 0x1130 }, + { 7830, 0x0290 }, { 7833, 0x03d3 }, { 7840, 0x122b }, { 7846, 0x3011 }, + { 7850, 0x1302 }, { 7854, 0x2b01 }, +}; +static const Summary16 ksc5601_uni2indx_pagef9[17] = { + /* 0xf900 */ + { 7859, 0xffff }, { 7875, 0xffff }, { 7891, 0xffff }, { 7907, 0xffff }, + { 7923, 0xffff }, { 7939, 0xffff }, { 7955, 0xffff }, { 7971, 0xffff }, + { 7987, 0xffff }, { 8003, 0xffff }, { 8019, 0xffff }, { 8035, 0xffff }, + { 8051, 0xffff }, { 8067, 0xffff }, { 8083, 0xffff }, { 8099, 0xffff }, + /* 0xfa00 */ + { 8115, 0x0fff }, +}; +static const Summary16 ksc5601_uni2indx_pageff[15] = { + /* 0xff00 */ + { 8127, 0xfffe }, { 8142, 0xffff }, { 8158, 0xffff }, { 8174, 0xffff }, + { 8190, 0xffff }, { 8206, 0x7fff }, { 8221, 0x0000 }, { 8221, 0x0000 }, + { 8221, 0x0000 }, { 8221, 0x0000 }, { 8221, 0x0000 }, { 8221, 0x0000 }, + { 8221, 0x0000 }, { 8221, 0x0000 }, { 8221, 0x006f }, +}; + +static int +ksc5601_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + const Summary16 *summary = NULL; + if (wc >= 0x0000 && wc < 0x0460) + summary = &ksc5601_uni2indx_page00[(wc>>4)]; + else if (wc >= 0x2000 && wc < 0x2670) + summary = &ksc5601_uni2indx_page20[(wc>>4)-0x200]; + else if (wc >= 0x3000 && wc < 0x33e0) + summary = &ksc5601_uni2indx_page30[(wc>>4)-0x300]; + else if (wc >= 0x4e00 && wc < 0x9fa0) + summary = &ksc5601_uni2indx_page4e[(wc>>4)-0x4e0]; + else if (wc >= 0xac00 && wc < 0xd7a0) + summary = &ksc5601_uni2indx_pageac[(wc>>4)-0xac0]; + else if (wc >= 0xf900 && wc < 0xfa10) + summary = &ksc5601_uni2indx_pagef9[(wc>>4)-0xf90]; + else if (wc >= 0xff00 && wc < 0xfff0) + summary = &ksc5601_uni2indx_pageff[(wc>>4)-0xff0]; + if (summary) { + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + c = ksc5601_2charset[summary->indx + used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/libiconv.rc b/graf2d/win32gdk/gdk/src/iconv/libiconv.rc new file mode 100644 index 0000000000000..effdb1eff2c5d --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/libiconv.rc @@ -0,0 +1,38 @@ +/* Resources for iconv.dll */ + +#include <winver.h> + +VS_VERSION_INFO VERSIONINFO + FILEVERSION 1,14,0,0 + PRODUCTVERSION 1,14,0,0 + FILEFLAGSMASK 0x3fL /* VS_FFI_FILEFLAGSMASK */ +#ifdef _DEBUG + FILEFLAGS 0x1L /* VS_FF_DEBUG */ +#else + FILEFLAGS 0x0L +#endif + FILEOS 0x10004L /* VOS_DOS_WINDOWS32 */ + FILETYPE 0x2L /* VFT_DLL */ + FILESUBTYPE 0x0L /* VFT2_UNKNOWN */ +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "04090000" /* Lang = US English, Charset = ASCII */ + BEGIN + VALUE "Comments", "This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License. You should have received a copy of the GNU Library General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA\0" + VALUE "CompanyName", "Free Software Foundation\0" + VALUE "FileDescription", "LGPLed libiconv for Windows NT/2000/XP/Vista and Windows 95/98/ME\0" + VALUE "FileVersion", PACKAGE_VERSION_STRING "\0" + VALUE "InternalName", "iconv.dll\0" + VALUE "LegalCopyright", "Copyright (C) 1999-2007\0" + VALUE "LegalTrademarks", "\0" + VALUE "OriginalFilename", "iconv.dll\0" + VALUE "ProductName", "libiconv: character set conversion library\0" + VALUE "ProductVersion", PACKAGE_VERSION_STRING "\0" + END + END + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x0409, 0 /* US English, ASCII */ + END +END diff --git a/graf2d/win32gdk/gdk/src/iconv/localcharset.c b/graf2d/win32gdk/gdk/src/iconv/localcharset.c new file mode 100644 index 0000000000000..31b0e93a369fe --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/localcharset.c @@ -0,0 +1,502 @@ +/* Determine a canonical name for the current locale's character encoding. + + Copyright (C) 2000-2006, 2008-2009 Free Software Foundation, Inc. + + This program is free software; you can redistribute it and/or modify it + under the terms of the GNU Library General Public License as published + by the Free Software Foundation; either version 2, or (at your option) + any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, + USA. */ + +/* Written by Bruno Haible <bruno@clisp.org>. */ + +#include <config.h> + +/* Specification. */ +#include "localcharset.h" + +#include <stddef.h> +#include <stdio.h> +#include <string.h> +#include <stdlib.h> + +#if defined __APPLE__ && defined __MACH__ && HAVE_LANGINFO_CODESET +# define DARWIN7 /* Darwin 7 or newer, i.e. MacOS X 10.3 or newer */ +#endif + +#if defined _WIN32 || defined __WIN32__ +# define WIN32_NATIVE +#endif + +#if defined __EMX__ +/* Assume EMX program runs on OS/2, even if compiled under DOS. */ +# ifndef OS2 +# define OS2 +# endif +#endif + +#if !defined WIN32_NATIVE +# if HAVE_LANGINFO_CODESET +# include <langinfo.h> +# else +# if 0 /* see comment below */ +# include <locale.h> +# endif +# endif +# ifdef __CYGWIN__ +# define WIN32_LEAN_AND_MEAN +# include <windows.h> +# endif +#elif defined WIN32_NATIVE +# define WIN32_LEAN_AND_MEAN +# include <windows.h> +#endif +#if defined OS2 +# define INCL_DOS +# include <os2.h> +#endif + +#if ENABLE_RELOCATABLE +# include "relocatable.h" +#else +# define relocate(pathname) (pathname) +#endif + +#if NOT_FOR_MSVC +/* Get LIBDIR. */ +#ifndef LIBDIR +# include "configmake.h" +#endif +#endif + +#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__ + /* Win32, Cygwin, OS/2, DOS */ +# define ISSLASH(C) ((C) == '/' || (C) == '\\') +#endif + +#ifndef DIRECTORY_SEPARATOR +# define DIRECTORY_SEPARATOR '/' +#endif + +#ifndef ISSLASH +# define ISSLASH(C) ((C) == DIRECTORY_SEPARATOR) +#endif + +#if HAVE_DECL_GETC_UNLOCKED +# undef getc +# define getc getc_unlocked +#endif + +/* The following static variable is declared 'volatile' to avoid a + possible multithread problem in the function get_charset_aliases. If we + are running in a threaded environment, and if two threads initialize + 'charset_aliases' simultaneously, both will produce the same value, + and everything will be ok if the two assignments to 'charset_aliases' + are atomic. But I don't know what will happen if the two assignments mix. */ +#if __STDC__ != 1 +# define volatile /* empty */ +#endif +/* Pointer to the contents of the charset.alias file, if it has already been + read, else NULL. Its format is: + ALIAS_1 '\0' CANONICAL_1 '\0' ... ALIAS_n '\0' CANONICAL_n '\0' '\0' */ +static const char * volatile charset_aliases; + +/* Return a pointer to the contents of the charset.alias file. */ +static const char * +get_charset_aliases (void) +{ + const char *cp; + + cp = charset_aliases; + if (cp == NULL) + { +#if !(defined DARWIN7 || defined VMS || defined WIN32_NATIVE || defined __CYGWIN__) + FILE *fp; + const char *dir; + const char *base = "charset.alias"; + char *file_name; + + /* Make it possible to override the charset.alias location. This is + necessary for running the testsuite before "make install". */ + dir = getenv ("CHARSETALIASDIR"); + if (dir == NULL || dir[0] == '\0') + dir = relocate (LIBDIR); + + /* Concatenate dir and base into freshly allocated file_name. */ + { + size_t dir_len = strlen (dir); + size_t base_len = strlen (base); + int add_slash = (dir_len > 0 && !ISSLASH (dir[dir_len - 1])); + file_name = (char *) malloc (dir_len + add_slash + base_len + 1); + if (file_name != NULL) + { + memcpy (file_name, dir, dir_len); + if (add_slash) + file_name[dir_len] = DIRECTORY_SEPARATOR; + memcpy (file_name + dir_len + add_slash, base, base_len + 1); + } + } + + if (file_name == NULL || (fp = fopen (file_name, "r")) == NULL) + /* Out of memory or file not found, treat it as empty. */ + cp = ""; + else + { + /* Parse the file's contents. */ + char *res_ptr = NULL; + size_t res_size = 0; + + for (;;) + { + int c; + char buf1[50+1]; + char buf2[50+1]; + size_t l1, l2; + char *old_res_ptr; + + c = getc (fp); + if (c == EOF) + break; + if (c == '\n' || c == ' ' || c == '\t') + continue; + if (c == '#') + { + /* Skip comment, to end of line. */ + do + c = getc (fp); + while (!(c == EOF || c == '\n')); + if (c == EOF) + break; + continue; + } + ungetc (c, fp); + if (fscanf (fp, "%50s %50s", buf1, buf2) < 2) + break; + l1 = strlen (buf1); + l2 = strlen (buf2); + old_res_ptr = res_ptr; + if (res_size == 0) + { + res_size = l1 + 1 + l2 + 1; + res_ptr = (char *) malloc (res_size + 1); + } + else + { + res_size += l1 + 1 + l2 + 1; + res_ptr = (char *) realloc (res_ptr, res_size + 1); + } + if (res_ptr == NULL) + { + /* Out of memory. */ + res_size = 0; + if (old_res_ptr != NULL) + free (old_res_ptr); + break; + } + strcpy (res_ptr + res_size - (l2 + 1) - (l1 + 1), buf1); + strcpy (res_ptr + res_size - (l2 + 1), buf2); + } + fclose (fp); + if (res_size == 0) + cp = ""; + else + { + *(res_ptr + res_size) = '\0'; + cp = res_ptr; + } + } + + if (file_name != NULL) + free (file_name); + +#else + +# if defined DARWIN7 + /* To avoid the trouble of installing a file that is shared by many + GNU packages -- many packaging systems have problems with this --, + simply inline the aliases here. */ + cp = "ISO8859-1" "\0" "ISO-8859-1" "\0" + "ISO8859-2" "\0" "ISO-8859-2" "\0" + "ISO8859-4" "\0" "ISO-8859-4" "\0" + "ISO8859-5" "\0" "ISO-8859-5" "\0" + "ISO8859-7" "\0" "ISO-8859-7" "\0" + "ISO8859-9" "\0" "ISO-8859-9" "\0" + "ISO8859-13" "\0" "ISO-8859-13" "\0" + "ISO8859-15" "\0" "ISO-8859-15" "\0" + "KOI8-R" "\0" "KOI8-R" "\0" + "KOI8-U" "\0" "KOI8-U" "\0" + "CP866" "\0" "CP866" "\0" + "CP949" "\0" "CP949" "\0" + "CP1131" "\0" "CP1131" "\0" + "CP1251" "\0" "CP1251" "\0" + "eucCN" "\0" "GB2312" "\0" + "GB2312" "\0" "GB2312" "\0" + "eucJP" "\0" "EUC-JP" "\0" + "eucKR" "\0" "EUC-KR" "\0" + "Big5" "\0" "BIG5" "\0" + "Big5HKSCS" "\0" "BIG5-HKSCS" "\0" + "GBK" "\0" "GBK" "\0" + "GB18030" "\0" "GB18030" "\0" + "SJIS" "\0" "SHIFT_JIS" "\0" + "ARMSCII-8" "\0" "ARMSCII-8" "\0" + "PT154" "\0" "PT154" "\0" + /*"ISCII-DEV" "\0" "?" "\0"*/ + "*" "\0" "UTF-8" "\0"; +# endif + +# if defined VMS + /* To avoid the troubles of an extra file charset.alias_vms in the + sources of many GNU packages, simply inline the aliases here. */ + /* The list of encodings is taken from the OpenVMS 7.3-1 documentation + "Compaq C Run-Time Library Reference Manual for OpenVMS systems" + section 10.7 "Handling Different Character Sets". */ + cp = "ISO8859-1" "\0" "ISO-8859-1" "\0" + "ISO8859-2" "\0" "ISO-8859-2" "\0" + "ISO8859-5" "\0" "ISO-8859-5" "\0" + "ISO8859-7" "\0" "ISO-8859-7" "\0" + "ISO8859-8" "\0" "ISO-8859-8" "\0" + "ISO8859-9" "\0" "ISO-8859-9" "\0" + /* Japanese */ + "eucJP" "\0" "EUC-JP" "\0" + "SJIS" "\0" "SHIFT_JIS" "\0" + "DECKANJI" "\0" "DEC-KANJI" "\0" + "SDECKANJI" "\0" "EUC-JP" "\0" + /* Chinese */ + "eucTW" "\0" "EUC-TW" "\0" + "DECHANYU" "\0" "DEC-HANYU" "\0" + "DECHANZI" "\0" "GB2312" "\0" + /* Korean */ + "DECKOREAN" "\0" "EUC-KR" "\0"; +# endif + +# if defined WIN32_NATIVE || defined __CYGWIN__ + /* To avoid the troubles of installing a separate file in the same + directory as the DLL and of retrieving the DLL's directory at + runtime, simply inline the aliases here. */ + + cp = "CP936" "\0" "GBK" "\0" + "CP1361" "\0" "JOHAB" "\0" + "CP20127" "\0" "ASCII" "\0" + "CP20866" "\0" "KOI8-R" "\0" + "CP20936" "\0" "GB2312" "\0" + "CP21866" "\0" "KOI8-RU" "\0" + "CP28591" "\0" "ISO-8859-1" "\0" + "CP28592" "\0" "ISO-8859-2" "\0" + "CP28593" "\0" "ISO-8859-3" "\0" + "CP28594" "\0" "ISO-8859-4" "\0" + "CP28595" "\0" "ISO-8859-5" "\0" + "CP28596" "\0" "ISO-8859-6" "\0" + "CP28597" "\0" "ISO-8859-7" "\0" + "CP28598" "\0" "ISO-8859-8" "\0" + "CP28599" "\0" "ISO-8859-9" "\0" + "CP28605" "\0" "ISO-8859-15" "\0" + "CP38598" "\0" "ISO-8859-8" "\0" + "CP51932" "\0" "EUC-JP" "\0" + "CP51936" "\0" "GB2312" "\0" + "CP51949" "\0" "EUC-KR" "\0" + "CP51950" "\0" "EUC-TW" "\0" + "CP54936" "\0" "GB18030" "\0" + "CP65001" "\0" "UTF-8" "\0"; +# endif +#endif + + charset_aliases = cp; + } + + return cp; +} + +/* Determine the current locale's character encoding, and canonicalize it + into one of the canonical names listed in config.charset. + The result must not be freed; it is statically allocated. + If the canonical name cannot be determined, the result is a non-canonical + name. */ + +#ifdef STATIC +STATIC +#endif +const char * +locale_charset (void) +{ + const char *codeset; + const char *aliases; + +#if !(defined WIN32_NATIVE || defined OS2) + +# if HAVE_LANGINFO_CODESET + + /* Most systems support nl_langinfo (CODESET) nowadays. */ + codeset = nl_langinfo (CODESET); + +# ifdef __CYGWIN__ + /* Cygwin 2006 does not have locales. nl_langinfo (CODESET) always + returns "US-ASCII". As long as this is not fixed, return the suffix + of the locale name from the environment variables (if present) or + the codepage as a number. */ + if (codeset != NULL && strcmp (codeset, "US-ASCII") == 0) + { + const char *locale; + static char buf[2 + 10 + 1]; + + locale = getenv ("LC_ALL"); + if (locale == NULL || locale[0] == '\0') + { + locale = getenv ("LC_CTYPE"); + if (locale == NULL || locale[0] == '\0') + locale = getenv ("LANG"); + } + if (locale != NULL && locale[0] != '\0') + { + /* If the locale name contains an encoding after the dot, return + it. */ + const char *dot = strchr (locale, '.'); + + if (dot != NULL) + { + const char *modifier; + + dot++; + /* Look for the possible @... trailer and remove it, if any. */ + modifier = strchr (dot, '@'); + if (modifier == NULL) + return dot; + if (modifier - dot < sizeof (buf)) + { + memcpy (buf, dot, modifier - dot); + buf [modifier - dot] = '\0'; + return buf; + } + } + } + + /* Woe32 has a function returning the locale's codepage as a number. */ + sprintf (buf, "CP%u", GetACP ()); + codeset = buf; + } +# endif + +# else + + /* On old systems which lack it, use setlocale or getenv. */ + const char *locale = NULL; + + /* But most old systems don't have a complete set of locales. Some + (like SunOS 4 or DJGPP) have only the C locale. Therefore we don't + use setlocale here; it would return "C" when it doesn't support the + locale name the user has set. */ +# if 0 + locale = setlocale (LC_CTYPE, NULL); +# endif + if (locale == NULL || locale[0] == '\0') + { + locale = getenv ("LC_ALL"); + if (locale == NULL || locale[0] == '\0') + { + locale = getenv ("LC_CTYPE"); + if (locale == NULL || locale[0] == '\0') + locale = getenv ("LANG"); + } + } + + /* On some old systems, one used to set locale = "iso8859_1". On others, + you set it to "language_COUNTRY.charset". In any case, we resolve it + through the charset.alias file. */ + codeset = locale; + +# endif + +#elif defined WIN32_NATIVE + + static char buf[2 + 10 + 1]; + + /* Woe32 has a function returning the locale's codepage as a number. */ + sprintf (buf, "CP%u", GetACP ()); + codeset = buf; + +#elif defined OS2 + + const char *locale; + static char buf[2 + 10 + 1]; + ULONG cp[3]; + ULONG cplen; + + /* Allow user to override the codeset, as set in the operating system, + with standard language environment variables. */ + locale = getenv ("LC_ALL"); + if (locale == NULL || locale[0] == '\0') + { + locale = getenv ("LC_CTYPE"); + if (locale == NULL || locale[0] == '\0') + locale = getenv ("LANG"); + } + if (locale != NULL && locale[0] != '\0') + { + /* If the locale name contains an encoding after the dot, return it. */ + const char *dot = strchr (locale, '.'); + + if (dot != NULL) + { + const char *modifier; + + dot++; + /* Look for the possible @... trailer and remove it, if any. */ + modifier = strchr (dot, '@'); + if (modifier == NULL) + return dot; + if (modifier - dot < sizeof (buf)) + { + memcpy (buf, dot, modifier - dot); + buf [modifier - dot] = '\0'; + return buf; + } + } + + /* Resolve through the charset.alias file. */ + codeset = locale; + } + else + { + /* OS/2 has a function returning the locale's codepage as a number. */ + if (DosQueryCp (sizeof (cp), cp, &cplen)) + codeset = ""; + else + { + sprintf (buf, "CP%u", cp[0]); + codeset = buf; + } + } + +#endif + + if (codeset == NULL) + /* The canonical name cannot be determined. */ + codeset = ""; + + /* Resolve alias. */ + for (aliases = get_charset_aliases (); + *aliases != '\0'; + aliases += strlen (aliases) + 1, aliases += strlen (aliases) + 1) + if (strcmp (codeset, aliases) == 0 + || (aliases[0] == '*' && aliases[1] == '\0')) + { + codeset = aliases + strlen (aliases) + 1; + break; + } + + /* Don't return an empty string. GNU libc and GNU libiconv interpret + the empty string as denoting "the locale's character encoding", + thus GNU libiconv would call this function a second time. */ + if (codeset[0] == '\0') + codeset = "ASCII"; + + return codeset; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/localcharset.h b/graf2d/win32gdk/gdk/src/iconv/localcharset.h new file mode 100644 index 0000000000000..32faedacdf4a1 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/localcharset.h @@ -0,0 +1,49 @@ +/* Determine a canonical name for the current locale's character encoding. + Copyright (C) 2000-2003 Free Software Foundation, Inc. + This file is part of the GNU CHARSET Library. + + This program is free software; you can redistribute it and/or modify it + under the terms of the GNU Library General Public License as published + by the Free Software Foundation; either version 2, or (at your option) + any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, + USA. */ + +#ifndef _LOCALCHARSET_H +#define _LOCALCHARSET_H + +#ifdef BUILDING_LIBCHARSET +#define LIBCHARSET_DLL_EXPORTED __declspec(dllexport) +#elif USING_STATIC_LIBICONV +#define LIBCHARSET_DLL_EXPORTED +#else +#define LIBCHARSET_DLL_EXPORTED __declspec(dllimport) +#endif + +#ifdef __cplusplus +extern "C" { +#endif + + +/* Determine the current locale's character encoding, and canonicalize it + into one of the canonical names listed in config.charset. + The result must not be freed; it is statically allocated. + If the canonical name cannot be determined, the result is a non-canonical + name. */ +extern LIBCHARSET_DLL_EXPORTED const char * locale_charset (void); + + +#ifdef __cplusplus +} +#endif + + +#endif /* _LOCALCHARSET_H */ diff --git a/graf2d/win32gdk/gdk/src/iconv/loop_unicode.h b/graf2d/win32gdk/gdk/src/iconv/loop_unicode.h new file mode 100644 index 0000000000000..1c787b5f7d5f4 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/loop_unicode.h @@ -0,0 +1,527 @@ +/* + * Copyright (C) 1999-2003, 2005-2006, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* This file defines the conversion loop via Unicode as a pivot encoding. */ + +/* Attempt to transliterate wc. Return code as in xxx_wctomb. */ +static int unicode_transliterate (conv_t cd, ucs4_t wc, + unsigned char* outptr, size_t outleft) +{ + if (cd->oflags & HAVE_HANGUL_JAMO) { + /* Decompose Hangul into Jamo. Use double-width Jamo (contained + in all Korean encodings and ISO-2022-JP-2), not half-width Jamo + (contained in Unicode only). */ + ucs4_t buf[3]; + int ret = johab_hangul_decompose(cd,buf,wc); + if (ret != RET_ILUNI) { + /* we know 1 <= ret <= 3 */ + state_t backup_state = cd->ostate; + unsigned char* backup_outptr = outptr; + size_t backup_outleft = outleft; + int i, sub_outcount; + for (i = 0; i < ret; i++) { + if (outleft == 0) { + sub_outcount = RET_TOOSMALL; + goto johab_hangul_failed; + } + sub_outcount = cd->ofuncs.xxx_wctomb(cd,outptr,buf[i],outleft); + if (sub_outcount <= RET_ILUNI) + goto johab_hangul_failed; + if (!(sub_outcount <= outleft)) abort(); + outptr += sub_outcount; outleft -= sub_outcount; + } + return outptr-backup_outptr; + johab_hangul_failed: + cd->ostate = backup_state; + outptr = backup_outptr; + outleft = backup_outleft; + if (sub_outcount != RET_ILUNI) + return RET_TOOSMALL; + } + } + { + /* Try to use a variant, but postfix it with + U+303E IDEOGRAPHIC VARIATION INDICATOR + (cf. Ken Lunde's "CJKV information processing", p. 188). */ + int indx = -1; + if (wc == 0x3006) + indx = 0; + else if (wc == 0x30f6) + indx = 1; + else if (wc >= 0x4e00 && wc < 0xa000) + indx = cjk_variants_indx[wc-0x4e00]; + if (indx >= 0) { + for (;; indx++) { + ucs4_t buf[2]; + unsigned short variant = cjk_variants[indx]; + unsigned short last = variant & 0x8000; + variant &= 0x7fff; + variant += 0x3000; + buf[0] = variant; buf[1] = 0x303e; + { + state_t backup_state = cd->ostate; + unsigned char* backup_outptr = outptr; + size_t backup_outleft = outleft; + int i, sub_outcount; + for (i = 0; i < 2; i++) { + if (outleft == 0) { + sub_outcount = RET_TOOSMALL; + goto variant_failed; + } + sub_outcount = cd->ofuncs.xxx_wctomb(cd,outptr,buf[i],outleft); + if (sub_outcount <= RET_ILUNI) + goto variant_failed; + if (!(sub_outcount <= outleft)) abort(); + outptr += sub_outcount; outleft -= sub_outcount; + } + return outptr-backup_outptr; + variant_failed: + cd->ostate = backup_state; + outptr = backup_outptr; + outleft = backup_outleft; + if (sub_outcount != RET_ILUNI) + return RET_TOOSMALL; + } + if (last) + break; + } + } + } + if (wc >= 0x2018 && wc <= 0x201a) { + /* Special case for quotation marks 0x2018, 0x2019, 0x201a */ + ucs4_t substitute = + (cd->oflags & HAVE_QUOTATION_MARKS + ? (wc == 0x201a ? 0x2018 : wc) + : (cd->oflags & HAVE_ACCENTS + ? (wc==0x2019 ? 0x00b4 : 0x0060) /* use accents */ + : 0x0027 /* use apostrophe */ + ) ); + int outcount = cd->ofuncs.xxx_wctomb(cd,outptr,substitute,outleft); + if (outcount != RET_ILUNI) + return outcount; + } + { + /* Use the transliteration table. */ + int indx = translit_index(wc); + if (indx >= 0) { + const unsigned int * cp = &translit_data[indx]; + unsigned int num = *cp++; + state_t backup_state = cd->ostate; + unsigned char* backup_outptr = outptr; + size_t backup_outleft = outleft; + unsigned int i; + int sub_outcount; + for (i = 0; i < num; i++) { + if (outleft == 0) { + sub_outcount = RET_TOOSMALL; + goto translit_failed; + } + sub_outcount = cd->ofuncs.xxx_wctomb(cd,outptr,cp[i],outleft); + if (sub_outcount == RET_ILUNI) + /* Recursive transliteration. */ + sub_outcount = unicode_transliterate(cd,cp[i],outptr,outleft); + if (sub_outcount <= RET_ILUNI) + goto translit_failed; + if (!(sub_outcount <= outleft)) abort(); + outptr += sub_outcount; outleft -= sub_outcount; + } + return outptr-backup_outptr; + translit_failed: + cd->ostate = backup_state; + outptr = backup_outptr; + outleft = backup_outleft; + if (sub_outcount != RET_ILUNI) + return RET_TOOSMALL; + } + } + return RET_ILUNI; +} + +#ifndef LIBICONV_PLUG + +struct uc_to_mb_fallback_locals { + unsigned char* l_outbuf; + size_t l_outbytesleft; + int l_errno; +}; + +static void uc_to_mb_write_replacement (const char *buf, size_t buflen, + void* callback_arg) +{ + struct uc_to_mb_fallback_locals * plocals = + (struct uc_to_mb_fallback_locals *) callback_arg; + /* Do nothing if already encountered an error in a previous call. */ + if (plocals->l_errno == 0) { + /* Attempt to copy the passed buffer to the output buffer. */ + if (plocals->l_outbytesleft < buflen) + plocals->l_errno = E2BIG; + else { + memcpy(plocals->l_outbuf, buf, buflen); + plocals->l_outbuf += buflen; + plocals->l_outbytesleft -= buflen; + } + } +} + +struct mb_to_uc_fallback_locals { + conv_t l_cd; + unsigned char* l_outbuf; + size_t l_outbytesleft; + int l_errno; +}; + +static void mb_to_uc_write_replacement (const unsigned int *buf, size_t buflen, + void* callback_arg) +{ + struct mb_to_uc_fallback_locals * plocals = + (struct mb_to_uc_fallback_locals *) callback_arg; + /* Do nothing if already encountered an error in a previous call. */ + if (plocals->l_errno == 0) { + /* Attempt to convert the passed buffer to the target encoding. */ + conv_t cd = plocals->l_cd; + unsigned char* outptr = plocals->l_outbuf; + size_t outleft = plocals->l_outbytesleft; + for (; buflen > 0; buf++, buflen--) { + ucs4_t wc = *buf; + int outcount; + if (outleft == 0) { + plocals->l_errno = E2BIG; + break; + } + outcount = cd->ofuncs.xxx_wctomb(cd,outptr,wc,outleft); + if (outcount != RET_ILUNI) + goto outcount_ok; + /* Handle Unicode tag characters (range U+E0000..U+E007F). */ + if ((wc >> 7) == (0xe0000 >> 7)) + goto outcount_zero; + /* Try transliteration. */ + if (cd->transliterate) { + outcount = unicode_transliterate(cd,wc,outptr,outleft); + if (outcount != RET_ILUNI) + goto outcount_ok; + } + if (cd->discard_ilseq) { + outcount = 0; + goto outcount_ok; + } + #ifndef LIBICONV_PLUG + else if (cd->fallbacks.uc_to_mb_fallback != NULL) { + struct uc_to_mb_fallback_locals locals; + locals.l_outbuf = outptr; + locals.l_outbytesleft = outleft; + locals.l_errno = 0; + cd->fallbacks.uc_to_mb_fallback(wc, + uc_to_mb_write_replacement, + &locals, + cd->fallbacks.data); + if (locals.l_errno != 0) { + plocals->l_errno = locals.l_errno; + break; + } + outptr = locals.l_outbuf; + outleft = locals.l_outbytesleft; + outcount = 0; + goto outcount_ok; + } + #endif + outcount = cd->ofuncs.xxx_wctomb(cd,outptr,0xFFFD,outleft); + if (outcount != RET_ILUNI) + goto outcount_ok; + plocals->l_errno = EILSEQ; + break; + outcount_ok: + if (outcount < 0) { + plocals->l_errno = E2BIG; + break; + } + #ifndef LIBICONV_PLUG + if (cd->hooks.uc_hook) + (*cd->hooks.uc_hook)(wc, cd->hooks.data); + #endif + if (!(outcount <= outleft)) abort(); + outptr += outcount; outleft -= outcount; + outcount_zero: ; + } + plocals->l_outbuf = outptr; + plocals->l_outbytesleft = outleft; + } +} + +#endif /* !LIBICONV_PLUG */ + +static size_t unicode_loop_convert (iconv_t icd, + const char* * inbuf, size_t *inbytesleft, + char* * outbuf, size_t *outbytesleft) +{ + conv_t cd = (conv_t) icd; + size_t result = 0; + const unsigned char* inptr = (const unsigned char*) *inbuf; + size_t inleft = *inbytesleft; + unsigned char* outptr = (unsigned char*) *outbuf; + size_t outleft = *outbytesleft; + while (inleft > 0) { + state_t last_istate = cd->istate; + ucs4_t wc; + int incount; + int outcount; + incount = cd->ifuncs.xxx_mbtowc(cd,&wc,inptr,inleft); + if (incount < 0) { + if ((unsigned int)(-1-incount) % 2 == (unsigned int)(-1-RET_ILSEQ) % 2) { + /* Case 1: invalid input, possibly after a shift sequence */ + incount = DECODE_SHIFT_ILSEQ(incount); + if (cd->discard_ilseq) { + switch (cd->iindex) { + case ei_ucs4: case ei_ucs4be: case ei_ucs4le: + case ei_utf32: case ei_utf32be: case ei_utf32le: + case ei_ucs4internal: case ei_ucs4swapped: + incount += 4; break; + case ei_ucs2: case ei_ucs2be: case ei_ucs2le: + case ei_utf16: case ei_utf16be: case ei_utf16le: + case ei_ucs2internal: case ei_ucs2swapped: + incount += 2; break; + default: + incount += 1; break; + } + goto outcount_zero; + } + #ifndef LIBICONV_PLUG + else if (cd->fallbacks.mb_to_uc_fallback != NULL) { + unsigned int incount2; + struct mb_to_uc_fallback_locals locals; + switch (cd->iindex) { + case ei_ucs4: case ei_ucs4be: case ei_ucs4le: + case ei_utf32: case ei_utf32be: case ei_utf32le: + case ei_ucs4internal: case ei_ucs4swapped: + incount2 = 4; break; + case ei_ucs2: case ei_ucs2be: case ei_ucs2le: + case ei_utf16: case ei_utf16be: case ei_utf16le: + case ei_ucs2internal: case ei_ucs2swapped: + incount2 = 2; break; + default: + incount2 = 1; break; + } + locals.l_cd = cd; + locals.l_outbuf = outptr; + locals.l_outbytesleft = outleft; + locals.l_errno = 0; + cd->fallbacks.mb_to_uc_fallback((const char*)inptr+incount, incount2, + mb_to_uc_write_replacement, + &locals, + cd->fallbacks.data); + if (locals.l_errno != 0) { + inptr += incount; inleft -= incount; + errno = locals.l_errno; + result = -1; + break; + } + incount += incount2; + outptr = locals.l_outbuf; + outleft = locals.l_outbytesleft; + result += 1; + goto outcount_zero; + } + #endif + inptr += incount; inleft -= incount; + errno = EILSEQ; + result = -1; + break; + } + if (incount == RET_TOOFEW(0)) { + /* Case 2: not enough bytes available to detect anything */ + errno = EINVAL; + result = -1; + break; + } + /* Case 3: k bytes read, but only a shift sequence */ + incount = DECODE_TOOFEW(incount); + } else { + /* Case 4: k bytes read, making up a wide character */ + if (outleft == 0) { + cd->istate = last_istate; + errno = E2BIG; + result = -1; + break; + } + outcount = cd->ofuncs.xxx_wctomb(cd,outptr,wc,outleft); + if (outcount != RET_ILUNI) + goto outcount_ok; + /* Handle Unicode tag characters (range U+E0000..U+E007F). */ + if ((wc >> 7) == (0xe0000 >> 7)) + goto outcount_zero; + /* Try transliteration. */ + result++; + if (cd->transliterate) { + outcount = unicode_transliterate(cd,wc,outptr,outleft); + if (outcount != RET_ILUNI) + goto outcount_ok; + } + if (cd->discard_ilseq) { + outcount = 0; + goto outcount_ok; + } + #ifndef LIBICONV_PLUG + else if (cd->fallbacks.uc_to_mb_fallback != NULL) { + struct uc_to_mb_fallback_locals locals; + locals.l_outbuf = outptr; + locals.l_outbytesleft = outleft; + locals.l_errno = 0; + cd->fallbacks.uc_to_mb_fallback(wc, + uc_to_mb_write_replacement, + &locals, + cd->fallbacks.data); + if (locals.l_errno != 0) { + cd->istate = last_istate; + errno = locals.l_errno; + return -1; + } + outptr = locals.l_outbuf; + outleft = locals.l_outbytesleft; + outcount = 0; + goto outcount_ok; + } + #endif + outcount = cd->ofuncs.xxx_wctomb(cd,outptr,0xFFFD,outleft); + if (outcount != RET_ILUNI) + goto outcount_ok; + cd->istate = last_istate; + errno = EILSEQ; + result = -1; + break; + outcount_ok: + if (outcount < 0) { + cd->istate = last_istate; + errno = E2BIG; + result = -1; + break; + } + #ifndef LIBICONV_PLUG + if (cd->hooks.uc_hook) + (*cd->hooks.uc_hook)(wc, cd->hooks.data); + #endif + if (!(outcount <= outleft)) abort(); + outptr += outcount; outleft -= outcount; + } + outcount_zero: + if (!(incount <= inleft)) abort(); + inptr += incount; inleft -= incount; + } + *inbuf = (const char*) inptr; + *inbytesleft = inleft; + *outbuf = (char*) outptr; + *outbytesleft = outleft; + return result; +} + +static size_t unicode_loop_reset (iconv_t icd, + char* * outbuf, size_t *outbytesleft) +{ + conv_t cd = (conv_t) icd; + if (outbuf == NULL || *outbuf == NULL) { + /* Reset the states. */ + memset(&cd->istate,'\0',sizeof(state_t)); + memset(&cd->ostate,'\0',sizeof(state_t)); + return 0; + } else { + size_t result = 0; + if (cd->ifuncs.xxx_flushwc) { + state_t last_istate = cd->istate; + ucs4_t wc; + if (cd->ifuncs.xxx_flushwc(cd, &wc)) { + unsigned char* outptr = (unsigned char*) *outbuf; + size_t outleft = *outbytesleft; + int outcount = cd->ofuncs.xxx_wctomb(cd,outptr,wc,outleft); + if (outcount != RET_ILUNI) + goto outcount_ok; + /* Handle Unicode tag characters (range U+E0000..U+E007F). */ + if ((wc >> 7) == (0xe0000 >> 7)) + goto outcount_zero; + /* Try transliteration. */ + result++; + if (cd->transliterate) { + outcount = unicode_transliterate(cd,wc,outptr,outleft); + if (outcount != RET_ILUNI) + goto outcount_ok; + } + if (cd->discard_ilseq) { + outcount = 0; + goto outcount_ok; + } + #ifndef LIBICONV_PLUG + else if (cd->fallbacks.uc_to_mb_fallback != NULL) { + struct uc_to_mb_fallback_locals locals; + locals.l_outbuf = outptr; + locals.l_outbytesleft = outleft; + locals.l_errno = 0; + cd->fallbacks.uc_to_mb_fallback(wc, + uc_to_mb_write_replacement, + &locals, + cd->fallbacks.data); + if (locals.l_errno != 0) { + cd->istate = last_istate; + errno = locals.l_errno; + return -1; + } + outptr = locals.l_outbuf; + outleft = locals.l_outbytesleft; + outcount = 0; + goto outcount_ok; + } + #endif + outcount = cd->ofuncs.xxx_wctomb(cd,outptr,0xFFFD,outleft); + if (outcount != RET_ILUNI) + goto outcount_ok; + cd->istate = last_istate; + errno = EILSEQ; + return -1; + outcount_ok: + if (outcount < 0) { + cd->istate = last_istate; + errno = E2BIG; + return -1; + } + #ifndef LIBICONV_PLUG + if (cd->hooks.uc_hook) + (*cd->hooks.uc_hook)(wc, cd->hooks.data); + #endif + if (!(outcount <= outleft)) abort(); + outptr += outcount; + outleft -= outcount; + outcount_zero: + *outbuf = (char*) outptr; + *outbytesleft = outleft; + } + } + if (cd->ofuncs.xxx_reset) { + unsigned char* outptr = (unsigned char*) *outbuf; + size_t outleft = *outbytesleft; + int outcount = cd->ofuncs.xxx_reset(cd,outptr,outleft); + if (outcount < 0) { + errno = E2BIG; + return -1; + } + if (!(outcount <= outleft)) abort(); + *outbuf = (char*) (outptr + outcount); + *outbytesleft = outleft - outcount; + } + memset(&cd->istate,'\0',sizeof(state_t)); + memset(&cd->ostate,'\0',sizeof(state_t)); + return result; + } +} diff --git a/graf2d/win32gdk/gdk/src/iconv/loop_wchar.h b/graf2d/win32gdk/gdk/src/iconv/loop_wchar.h new file mode 100644 index 0000000000000..30d5dbd076407 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/loop_wchar.h @@ -0,0 +1,458 @@ +/* + * Copyright (C) 2000-2002, 2005-2006, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* This file defines three conversion loops: + - from wchar_t to anything else, + - from anything else to wchar_t, + - from wchar_t to wchar_t. + */ + +#if HAVE_WCRTOMB || HAVE_MBRTOWC +# include <wchar.h> +# define BUF_SIZE 64 /* assume MB_LEN_MAX <= 64 */ + /* Some systems, like BeOS, have multibyte encodings but lack mbstate_t. */ + extern size_t mbrtowc (); +# ifdef mbstate_t +# define mbrtowc(pwc, s, n, ps) (mbrtowc)(pwc, s, n, 0) +# define mbsinit(ps) 1 +# endif +# ifndef mbsinit +# if !HAVE_MBSINIT +# define mbsinit(ps) 1 +# endif +# endif +#endif + +/* + * The first two conversion loops have an extended conversion descriptor. + */ +struct wchar_conv_struct { + struct conv_struct parent; +#if HAVE_WCRTOMB || HAVE_MBRTOWC + mbstate_t state; +#endif +}; + + +#if HAVE_WCRTOMB + +/* From wchar_t to anything else. */ + +#ifndef LIBICONV_PLUG + +#if 0 + +struct wc_to_mb_fallback_locals { + struct wchar_conv_struct * l_wcd; + char* l_outbuf; + size_t l_outbytesleft; + int l_errno; +}; + +/* A callback that writes a string given in the locale encoding. */ +static void wc_to_mb_write_replacement (const char *buf, size_t buflen, + void* callback_arg) +{ + struct wc_to_mb_fallback_locals * plocals = + (struct wc_to_mb_fallback_locals *) callback_arg; + /* Do nothing if already encountered an error in a previous call. */ + if (plocals->l_errno == 0) { + /* Attempt to convert the passed buffer to the target encoding. + Here we don't support characters split across multiple calls. */ + const char* bufptr = buf; + size_t bufleft = buflen; + size_t res = unicode_loop_convert(&plocals->l_wcd->parent, + &bufptr,&bufleft, + &plocals->l_outbuf,&plocals->l_outbytesleft); + if (res == (size_t)(-1)) { + if (errno == EILSEQ || errno == EINVAL) + /* Invalid buf contents. */ + plocals->l_errno = EILSEQ; + else if (errno == E2BIG) + /* Output buffer too small. */ + plocals->l_errno = E2BIG; + else + abort(); + } else { + /* Successful conversion. */ + if (bufleft > 0) + abort(); + } + } +} + +#else + +struct wc_to_mb_fallback_locals { + char* l_outbuf; + size_t l_outbytesleft; + int l_errno; +}; + +/* A callback that writes a string given in the target encoding. */ +static void wc_to_mb_write_replacement (const char *buf, size_t buflen, + void* callback_arg) +{ + struct wc_to_mb_fallback_locals * plocals = + (struct wc_to_mb_fallback_locals *) callback_arg; + /* Do nothing if already encountered an error in a previous call. */ + if (plocals->l_errno == 0) { + /* Attempt to copy the passed buffer to the output buffer. */ + if (plocals->l_outbytesleft < buflen) + plocals->l_errno = E2BIG; + else { + memcpy(plocals->l_outbuf, buf, buflen); + plocals->l_outbuf += buflen; + plocals->l_outbytesleft -= buflen; + } + } +} + +#endif + +#endif /* !LIBICONV_PLUG */ + +static size_t wchar_from_loop_convert (iconv_t icd, + const char* * inbuf, size_t *inbytesleft, + char* * outbuf, size_t *outbytesleft) +{ + struct wchar_conv_struct * wcd = (struct wchar_conv_struct *) icd; + size_t result = 0; + while (*inbytesleft >= sizeof(wchar_t)) { + const wchar_t * inptr = (const wchar_t *) *inbuf; + size_t inleft = *inbytesleft; + char buf[BUF_SIZE]; + mbstate_t state = wcd->state; + size_t bufcount = 0; + while (inleft >= sizeof(wchar_t)) { + /* Convert one wchar_t to multibyte representation. */ + size_t count = wcrtomb(buf+bufcount,*inptr,&state); + if (count == (size_t)(-1)) { + /* Invalid input. */ + if (wcd->parent.discard_ilseq) { + count = 0; + } + #ifndef LIBICONV_PLUG + else if (wcd->parent.fallbacks.wc_to_mb_fallback != NULL) { + /* Drop the contents of buf[] accumulated so far, and instead + pass all queued wide characters to the fallback handler. */ + struct wc_to_mb_fallback_locals locals; + const wchar_t * fallback_inptr; + #if 0 + locals.l_wcd = wcd; + #endif + locals.l_outbuf = *outbuf; + locals.l_outbytesleft = *outbytesleft; + locals.l_errno = 0; + for (fallback_inptr = (const wchar_t *) *inbuf; + fallback_inptr <= inptr; + fallback_inptr++) + wcd->parent.fallbacks.wc_to_mb_fallback(*fallback_inptr, + wc_to_mb_write_replacement, + &locals, + wcd->parent.fallbacks.data); + if (locals.l_errno != 0) { + errno = locals.l_errno; + return -1; + } + wcd->state = state; + *inbuf = (const char *) (inptr + 1); + *inbytesleft = inleft - sizeof(wchar_t); + *outbuf = locals.l_outbuf; + *outbytesleft = locals.l_outbytesleft; + result += 1; + break; + } + #endif + else { + errno = EILSEQ; + return -1; + } + } + inptr++; + inleft -= sizeof(wchar_t); + bufcount += count; + if (count == 0) { + /* Continue, append next wchar_t. */ + } else { + /* Attempt to convert the accumulated multibyte representations + to the target encoding. */ + const char* bufptr = buf; + size_t bufleft = bufcount; + char* outptr = *outbuf; + size_t outleft = *outbytesleft; + size_t res = unicode_loop_convert(&wcd->parent, + &bufptr,&bufleft, + &outptr,&outleft); + if (res == (size_t)(-1)) { + if (errno == EILSEQ) + /* Invalid input. */ + return -1; + else if (errno == E2BIG) + /* Output buffer too small. */ + return -1; + else if (errno == EINVAL) { + /* Continue, append next wchar_t, but avoid buffer overrun. */ + if (bufcount + MB_CUR_MAX > BUF_SIZE) + abort(); + } else + abort(); + } else { + /* Successful conversion. */ + wcd->state = state; + *inbuf = (const char *) inptr; + *inbytesleft = inleft; + *outbuf = outptr; + *outbytesleft = outleft; + result += res; + break; + } + } + } + } + return result; +} + +static size_t wchar_from_loop_reset (iconv_t icd, + char* * outbuf, size_t *outbytesleft) +{ + struct wchar_conv_struct * wcd = (struct wchar_conv_struct *) icd; + if (outbuf == NULL || *outbuf == NULL) { + /* Reset the states. */ + memset(&wcd->state,'\0',sizeof(mbstate_t)); + return unicode_loop_reset(&wcd->parent,NULL,NULL); + } else { + if (!mbsinit(&wcd->state)) { + mbstate_t state = wcd->state; + char buf[BUF_SIZE]; + size_t bufcount = wcrtomb(buf,(wchar_t)0,&state); + if (bufcount == (size_t)(-1) || bufcount == 0 || buf[bufcount-1] != '\0') + abort(); + else { + const char* bufptr = buf; + size_t bufleft = bufcount-1; + char* outptr = *outbuf; + size_t outleft = *outbytesleft; + size_t res = unicode_loop_convert(&wcd->parent, + &bufptr,&bufleft, + &outptr,&outleft); + if (res == (size_t)(-1)) { + if (errno == E2BIG) + return -1; + else + abort(); + } else { + res = unicode_loop_reset(&wcd->parent,&outptr,&outleft); + if (res == (size_t)(-1)) + return res; + else { + /* Successful. */ + wcd->state = state; + *outbuf = outptr; + *outbytesleft = outleft; + return 0; + } + } + } + } else + return unicode_loop_reset(&wcd->parent,outbuf,outbytesleft); + } +} + +#endif + + +#if HAVE_MBRTOWC + +/* From anything else to wchar_t. */ + +#ifndef LIBICONV_PLUG + +struct mb_to_wc_fallback_locals { + char* l_outbuf; + size_t l_outbytesleft; + int l_errno; +}; + +static void mb_to_wc_write_replacement (const wchar_t *buf, size_t buflen, + void* callback_arg) +{ + struct mb_to_wc_fallback_locals * plocals = + (struct mb_to_wc_fallback_locals *) callback_arg; + /* Do nothing if already encountered an error in a previous call. */ + if (plocals->l_errno == 0) { + /* Attempt to copy the passed buffer to the output buffer. */ + if (plocals->l_outbytesleft < sizeof(wchar_t)*buflen) + plocals->l_errno = E2BIG; + else { + for (; buflen > 0; buf++, buflen--) { + *(wchar_t*) plocals->l_outbuf = *buf; + plocals->l_outbuf += sizeof(wchar_t); + plocals->l_outbytesleft -= sizeof(wchar_t); + } + } + } +} + +#endif /* !LIBICONV_PLUG */ + +static size_t wchar_to_loop_convert (iconv_t icd, + const char* * inbuf, size_t *inbytesleft, + char* * outbuf, size_t *outbytesleft) +{ + struct wchar_conv_struct * wcd = (struct wchar_conv_struct *) icd; + size_t result = 0; + while (*inbytesleft > 0) { + size_t incount; + for (incount = 1; incount <= *inbytesleft; incount++) { + char buf[BUF_SIZE]; + const char* inptr = *inbuf; + size_t inleft = incount; + char* bufptr = buf; + size_t bufleft = BUF_SIZE; + size_t res = unicode_loop_convert(&wcd->parent, + &inptr,&inleft, + &bufptr,&bufleft); + if (res == (size_t)(-1)) { + if (errno == EILSEQ) + /* Invalid input. */ + return -1; + else if (errno == EINVAL) { + /* Incomplete input. Next try with one more input byte. */ + } else + /* E2BIG shouldn't occur. */ + abort(); + } else { + /* Successful conversion. */ + size_t bufcount = bufptr-buf; /* = BUF_SIZE-bufleft */ + mbstate_t state = wcd->state; + wchar_t wc; + res = mbrtowc(&wc,buf,bufcount,&state); + if (res == (size_t)(-2)) { + /* Next try with one more input byte. */ + } else { + if (res == (size_t)(-1)) { + /* Invalid input. */ + if (wcd->parent.discard_ilseq) { + } + #ifndef LIBICONV_PLUG + else if (wcd->parent.fallbacks.mb_to_wc_fallback != NULL) { + /* Drop the contents of buf[] accumulated so far, and instead + pass all queued chars to the fallback handler. */ + struct mb_to_wc_fallback_locals locals; + locals.l_outbuf = *outbuf; + locals.l_outbytesleft = *outbytesleft; + locals.l_errno = 0; + wcd->parent.fallbacks.mb_to_wc_fallback(*inbuf, incount, + mb_to_wc_write_replacement, + &locals, + wcd->parent.fallbacks.data); + if (locals.l_errno != 0) { + errno = locals.l_errno; + return -1; + } + /* Restoring the state is not needed because it is the initial + state anyway: For all known locale encodings, the multibyte + to wchar_t conversion doesn't have shift state, and we have + excluded partial accumulated characters. */ + /* wcd->state = state; */ + *inbuf += incount; + *inbytesleft -= incount; + *outbuf = locals.l_outbuf; + *outbytesleft = locals.l_outbytesleft; + result += 1; + break; + } + #endif + else + return -1; + } else { + if (*outbytesleft < sizeof(wchar_t)) { + errno = E2BIG; + return -1; + } + *(wchar_t*) *outbuf = wc; + /* Restoring the state is not needed because it is the initial + state anyway: For all known locale encodings, the multibyte + to wchar_t conversion doesn't have shift state, and we have + excluded partial accumulated characters. */ + /* wcd->state = state; */ + *outbuf += sizeof(wchar_t); + *outbytesleft -= sizeof(wchar_t); + } + *inbuf += incount; + *inbytesleft -= incount; + result += res; + break; + } + } + } + } + return result; +} + +static size_t wchar_to_loop_reset (iconv_t icd, + char* * outbuf, size_t *outbytesleft) +{ + struct wchar_conv_struct * wcd = (struct wchar_conv_struct *) icd; + size_t res = unicode_loop_reset(&wcd->parent,outbuf,outbytesleft); + if (res == (size_t)(-1)) + return res; + memset(&wcd->state,0,sizeof(mbstate_t)); + return 0; +} + +#endif + + +/* From wchar_t to wchar_t. */ + +static size_t wchar_id_loop_convert (iconv_t icd, + const char* * inbuf, size_t *inbytesleft, + char* * outbuf, size_t *outbytesleft) +{ + struct conv_struct * cd = (struct conv_struct *) icd; + const wchar_t* inptr = (const wchar_t*) *inbuf; + size_t inleft = *inbytesleft / sizeof(wchar_t); + wchar_t* outptr = (wchar_t*) *outbuf; + size_t outleft = *outbytesleft / sizeof(wchar_t); + size_t count = (inleft <= outleft ? inleft : outleft); + if (count > 0) { + *inbytesleft -= count * sizeof(wchar_t); + *outbytesleft -= count * sizeof(wchar_t); + do { + wchar_t wc = *inptr++; + *outptr++ = wc; + #ifndef LIBICONV_PLUG + if (cd->hooks.wc_hook) + (*cd->hooks.wc_hook)(wc, cd->hooks.data); + #endif + } while (--count > 0); + *inbuf = (const char*) inptr; + *outbuf = (char*) outptr; + } + return 0; +} + +static size_t wchar_id_loop_reset (iconv_t icd, + char* * outbuf, size_t *outbytesleft) +{ + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/loops.h b/graf2d/win32gdk/gdk/src/iconv/loops.h new file mode 100644 index 0000000000000..782cc0926d9fb --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/loops.h @@ -0,0 +1,25 @@ +/* + * Copyright (C) 2000 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* This file defines all the loops. */ + +#include "loop_unicode.h" +#include "loop_wchar.h" + diff --git a/graf2d/win32gdk/gdk/src/iconv/mac_arabic.h b/graf2d/win32gdk/gdk/src/iconv/mac_arabic.h new file mode 100644 index 0000000000000..9d05a1ab63bc3 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mac_arabic.h @@ -0,0 +1,132 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MacArabic + */ + +static const unsigned short mac_arabic_2uni[128] = { + /* 0x80 */ + 0x00c4, 0x00a0, 0x00c7, 0x00c9, 0x00d1, 0x00d6, 0x00dc, 0x00e1, + 0x00e0, 0x00e2, 0x00e4, 0x06ba, 0x00ab, 0x00e7, 0x00e9, 0x00e8, + /* 0x90 */ + 0x00ea, 0x00eb, 0x00ed, 0x2026, 0x00ee, 0x00ef, 0x00f1, 0x00f3, + 0x00bb, 0x00f4, 0x00f6, 0x00f7, 0x00fa, 0x00f9, 0x00fb, 0x00fc, + /* 0xa0 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x066a, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x060c, 0xfffd, 0xfffd, 0xfffd, + /* 0xb0 */ + 0x0660, 0x0661, 0x0662, 0x0663, 0x0664, 0x0665, 0x0666, 0x0667, + 0x0668, 0x0669, 0xfffd, 0x061b, 0xfffd, 0xfffd, 0xfffd, 0x061f, + /* 0xc0 */ + 0x066d, 0x0621, 0x0622, 0x0623, 0x0624, 0x0625, 0x0626, 0x0627, + 0x0628, 0x0629, 0x062a, 0x062b, 0x062c, 0x062d, 0x062e, 0x062f, + /* 0xd0 */ + 0x0630, 0x0631, 0x0632, 0x0633, 0x0634, 0x0635, 0x0636, 0x0637, + 0x0638, 0x0639, 0x063a, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xe0 */ + 0x0640, 0x0641, 0x0642, 0x0643, 0x0644, 0x0645, 0x0646, 0x0647, + 0x0648, 0x0649, 0x064a, 0x064b, 0x064c, 0x064d, 0x064e, 0x064f, + /* 0xf0 */ + 0x0650, 0x0651, 0x0652, 0x067e, 0x0679, 0x0686, 0x06d5, 0x06a4, + 0x06af, 0x0688, 0x0691, 0xfffd, 0xfffd, 0xfffd, 0x0698, 0x06d2, +}; + +static int +mac_arabic_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = mac_arabic_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char mac_arabic_page00[96] = { + 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x8c, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x82, /* 0xc0-0xc7 */ + 0x00, 0x83, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x84, 0x00, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x86, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x88, 0x87, 0x89, 0x00, 0x8a, 0x00, 0x00, 0x8d, /* 0xe0-0xe7 */ + 0x8f, 0x8e, 0x90, 0x91, 0x00, 0x92, 0x94, 0x95, /* 0xe8-0xef */ + 0x00, 0x96, 0x00, 0x97, 0x99, 0x00, 0x9a, 0x9b, /* 0xf0-0xf7 */ + 0x00, 0x9d, 0x9c, 0x9e, 0x9f, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; +static const unsigned char mac_arabic_page06[208] = { + 0x00, 0x00, 0x00, 0x00, 0xac, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0xbb, 0x00, 0x00, 0x00, 0xbf, /* 0x18-0x1f */ + 0x00, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x20-0x27 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x28-0x2f */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0x30-0x37 */ + 0xd8, 0xd9, 0xda, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x40-0x47 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x48-0x4f */ + 0xf0, 0xf1, 0xf2, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, /* 0x60-0x67 */ + 0xb8, 0xb9, 0xa5, 0x00, 0x00, 0xc0, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0xf4, 0x00, 0x00, 0x00, 0x00, 0xf3, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf5, 0x00, /* 0x80-0x87 */ + 0xf9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0xfa, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x00, 0x00, 0x00, 0x00, 0xf7, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x8b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0xff, 0x00, 0x00, 0xf6, 0x00, 0x00, /* 0xd0-0xd7 */ +}; + +static int +mac_arabic_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = mac_arabic_page00[wc-0x00a0]; + else if (wc >= 0x0608 && wc < 0x06d8) + c = mac_arabic_page06[wc-0x0608]; + else if (wc == 0x2026) + c = 0x93; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/mac_centraleurope.h b/graf2d/win32gdk/gdk/src/iconv/mac_centraleurope.h new file mode 100644 index 0000000000000..be030cfc81da3 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mac_centraleurope.h @@ -0,0 +1,139 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MacCentralEurope + */ + +static const unsigned short mac_centraleurope_2uni[128] = { + /* 0x80 */ + 0x00c4, 0x0100, 0x0101, 0x00c9, 0x0104, 0x00d6, 0x00dc, 0x00e1, + 0x0105, 0x010c, 0x00e4, 0x010d, 0x0106, 0x0107, 0x00e9, 0x0179, + /* 0x90 */ + 0x017a, 0x010e, 0x00ed, 0x010f, 0x0112, 0x0113, 0x0116, 0x00f3, + 0x0117, 0x00f4, 0x00f6, 0x00f5, 0x00fa, 0x011a, 0x011b, 0x00fc, + /* 0xa0 */ + 0x2020, 0x00b0, 0x0118, 0x00a3, 0x00a7, 0x2022, 0x00b6, 0x00df, + 0x00ae, 0x00a9, 0x2122, 0x0119, 0x00a8, 0x2260, 0x0123, 0x012e, + /* 0xb0 */ + 0x012f, 0x012a, 0x2264, 0x2265, 0x012b, 0x0136, 0x2202, 0x2211, + 0x0142, 0x013b, 0x013c, 0x013d, 0x013e, 0x0139, 0x013a, 0x0145, + /* 0xc0 */ + 0x0146, 0x0143, 0x00ac, 0x221a, 0x0144, 0x0147, 0x2206, 0x00ab, + 0x00bb, 0x2026, 0x00a0, 0x0148, 0x0150, 0x00d5, 0x0151, 0x014c, + /* 0xd0 */ + 0x2013, 0x2014, 0x201c, 0x201d, 0x2018, 0x2019, 0x00f7, 0x25ca, + 0x014d, 0x0154, 0x0155, 0x0158, 0x2039, 0x203a, 0x0159, 0x0156, + /* 0xe0 */ + 0x0157, 0x0160, 0x201a, 0x201e, 0x0161, 0x015a, 0x015b, 0x00c1, + 0x0164, 0x0165, 0x00cd, 0x017d, 0x017e, 0x016a, 0x00d3, 0x00d4, + /* 0xf0 */ + 0x016b, 0x016e, 0x00da, 0x016f, 0x0170, 0x0171, 0x0172, 0x0173, + 0x00dd, 0x00fd, 0x0137, 0x017b, 0x0141, 0x017c, 0x0122, 0x02c7, +}; + +static int +mac_centraleurope_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) mac_centraleurope_2uni[c-0x80]; + return 1; +} + +static const unsigned char mac_centraleurope_page00[224] = { + 0xca, 0x00, 0x00, 0xa3, 0x00, 0x00, 0x00, 0xa4, /* 0xa0-0xa7 */ + 0xac, 0xa9, 0x00, 0xc7, 0xc2, 0x00, 0xa8, 0x00, /* 0xa8-0xaf */ + 0xa1, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa6, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xc8, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0xe7, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x83, 0x00, 0x00, 0x00, 0xea, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0xee, 0xef, 0xcd, 0x85, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0xf2, 0x00, 0x86, 0xf8, 0x00, 0xa7, /* 0xd8-0xdf */ + 0x00, 0x87, 0x00, 0x00, 0x8a, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0x00, 0x8e, 0x00, 0x00, 0x00, 0x92, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x97, 0x99, 0x9b, 0x9a, 0xd6, /* 0xf0-0xf7 */ + 0x00, 0x00, 0x9c, 0x00, 0x9f, 0xf9, 0x00, 0x00, /* 0xf8-0xff */ + /* 0x0100 */ + 0x81, 0x82, 0x00, 0x00, 0x84, 0x88, 0x8c, 0x8d, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x89, 0x8b, 0x91, 0x93, /* 0x08-0x0f */ + 0x00, 0x00, 0x94, 0x95, 0x00, 0x00, 0x96, 0x98, /* 0x10-0x17 */ + 0xa2, 0xab, 0x9d, 0x9e, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0xfe, 0xae, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0xb1, 0xb4, 0x00, 0x00, 0xaf, 0xb0, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb5, 0xfa, /* 0x30-0x37 */ + 0x00, 0xbd, 0xbe, 0xb9, 0xba, 0xbb, 0xbc, 0x00, /* 0x38-0x3f */ + 0x00, 0xfc, 0xb8, 0xc1, 0xc4, 0xbf, 0xc0, 0xc5, /* 0x40-0x47 */ + 0xcb, 0x00, 0x00, 0x00, 0xcf, 0xd8, 0x00, 0x00, /* 0x48-0x4f */ + 0xcc, 0xce, 0x00, 0x00, 0xd9, 0xda, 0xdf, 0xe0, /* 0x50-0x57 */ + 0xdb, 0xde, 0xe5, 0xe6, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xe1, 0xe4, 0x00, 0x00, 0xe8, 0xe9, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0xed, 0xf0, 0x00, 0x00, 0xf1, 0xf3, /* 0x68-0x6f */ + 0xf4, 0xf5, 0xf6, 0xf7, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x8f, 0x90, 0xfb, 0xfd, 0xeb, 0xec, 0x00, /* 0x78-0x7f */ +}; +static const unsigned char mac_centraleurope_page20[48] = { + 0x00, 0x00, 0x00, 0xd0, 0xd1, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd4, 0xd5, 0xe2, 0x00, 0xd2, 0xd3, 0xe3, 0x00, /* 0x18-0x1f */ + 0xa0, 0x00, 0xa5, 0x00, 0x00, 0x00, 0xc9, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0xdc, 0xdd, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; +static const unsigned char mac_centraleurope_page22[32] = { + 0x00, 0x00, 0xb6, 0x00, 0x00, 0x00, 0xc6, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0xb7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ +}; +static const unsigned char mac_centraleurope_page22_1[8] = { + 0xad, 0x00, 0x00, 0x00, 0xb2, 0xb3, 0x00, 0x00, /* 0x60-0x67 */ +}; + +static int +mac_centraleurope_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0180) + c = mac_centraleurope_page00[wc-0x00a0]; + else if (wc == 0x02c7) + c = 0xff; + else if (wc >= 0x2010 && wc < 0x2040) + c = mac_centraleurope_page20[wc-0x2010]; + else if (wc == 0x2122) + c = 0xaa; + else if (wc >= 0x2200 && wc < 0x2220) + c = mac_centraleurope_page22[wc-0x2200]; + else if (wc >= 0x2260 && wc < 0x2268) + c = mac_centraleurope_page22_1[wc-0x2260]; + else if (wc == 0x25ca) + c = 0xd7; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/mac_croatian.h b/graf2d/win32gdk/gdk/src/iconv/mac_croatian.h new file mode 100644 index 0000000000000..582f3e05c0072 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mac_croatian.h @@ -0,0 +1,165 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MacCroatian + */ + +static const unsigned short mac_croatian_2uni[128] = { + /* 0x80 */ + 0x00c4, 0x00c5, 0x00c7, 0x00c9, 0x00d1, 0x00d6, 0x00dc, 0x00e1, + 0x00e0, 0x00e2, 0x00e4, 0x00e3, 0x00e5, 0x00e7, 0x00e9, 0x00e8, + /* 0x90 */ + 0x00ea, 0x00eb, 0x00ed, 0x00ec, 0x00ee, 0x00ef, 0x00f1, 0x00f3, + 0x00f2, 0x00f4, 0x00f6, 0x00f5, 0x00fa, 0x00f9, 0x00fb, 0x00fc, + /* 0xa0 */ + 0x2020, 0x00b0, 0x00a2, 0x00a3, 0x00a7, 0x2022, 0x00b6, 0x00df, + 0x00ae, 0x0160, 0x2122, 0x00b4, 0x00a8, 0x2260, 0x017d, 0x00d8, + /* 0xb0 */ + 0x221e, 0x00b1, 0x2264, 0x2265, 0x2206, 0x00b5, 0x2202, 0x2211, + 0x220f, 0x0161, 0x222b, 0x00aa, 0x00ba, 0x2126, 0x017e, 0x00f8, + /* 0xc0 */ + 0x00bf, 0x00a1, 0x00ac, 0x221a, 0x0192, 0x2248, 0x0106, 0x00ab, + 0x010c, 0x2026, 0x00a0, 0x00c0, 0x00c3, 0x00d5, 0x0152, 0x0153, + /* 0xd0 */ + 0x0110, 0x2014, 0x201c, 0x201d, 0x2018, 0x2019, 0x00f7, 0x25ca, + 0xfffd, 0x00a9, 0x2044, 0x00a4, 0x2039, 0x203a, 0x00c6, 0x00bb, + /* 0xe0 */ + 0x2013, 0x00b7, 0x201a, 0x201e, 0x2030, 0x00c2, 0x0107, 0x00c1, + 0x010d, 0x00c8, 0x00cd, 0x00ce, 0x00cf, 0x00cc, 0x00d3, 0x00d4, + /* 0xf0 */ + 0x0111, 0x00d2, 0x00da, 0x00db, 0x00d9, 0x0131, 0x02c6, 0x02dc, + 0x00af, 0x03c0, 0x00cb, 0x02da, 0x00b8, 0x00ca, 0x00e6, 0x02c7, +}; + +static int +mac_croatian_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = mac_croatian_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char mac_croatian_page00[248] = { + 0xca, 0xc1, 0xa2, 0xa3, 0xdb, 0x00, 0x00, 0xa4, /* 0xa0-0xa7 */ + 0xac, 0xd9, 0xbb, 0xc7, 0xc2, 0x00, 0xa8, 0xf8, /* 0xa8-0xaf */ + 0xa1, 0xb1, 0x00, 0x00, 0xab, 0xb5, 0xa6, 0xe1, /* 0xb0-0xb7 */ + 0xfc, 0x00, 0xbc, 0xdf, 0x00, 0x00, 0x00, 0xc0, /* 0xb8-0xbf */ + 0xcb, 0xe7, 0xe5, 0xcc, 0x80, 0x81, 0xde, 0x82, /* 0xc0-0xc7 */ + 0xe9, 0x83, 0xfd, 0xfa, 0xed, 0xea, 0xeb, 0xec, /* 0xc8-0xcf */ + 0x00, 0x84, 0xf1, 0xee, 0xef, 0xcd, 0x85, 0x00, /* 0xd0-0xd7 */ + 0xaf, 0xf4, 0xf2, 0xf3, 0x86, 0x00, 0x00, 0xa7, /* 0xd8-0xdf */ + 0x88, 0x87, 0x89, 0x8b, 0x8a, 0x8c, 0xfe, 0x8d, /* 0xe0-0xe7 */ + 0x8f, 0x8e, 0x90, 0x91, 0x93, 0x92, 0x94, 0x95, /* 0xe8-0xef */ + 0x00, 0x96, 0x98, 0x97, 0x99, 0x9b, 0x9a, 0xd6, /* 0xf0-0xf7 */ + 0xbf, 0x9d, 0x9c, 0x9e, 0x9f, 0x00, 0x00, 0x00, /* 0xf8-0xff */ + /* 0x0100 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc6, 0xe6, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0xc8, 0xe8, 0x00, 0x00, /* 0x08-0x0f */ + 0xd0, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0xce, 0xcf, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xa9, 0xb9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xae, 0xbe, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0xc4, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char mac_croatian_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf6, 0xff, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0xfb, 0x00, 0xf7, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char mac_croatian_page20[56] = { + 0x00, 0x00, 0x00, 0xe0, 0xd1, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd4, 0xd5, 0xe2, 0x00, 0xd2, 0xd3, 0xe3, 0x00, /* 0x18-0x1f */ + 0xa0, 0x00, 0xa5, 0x00, 0x00, 0x00, 0xc9, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0xe4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0xdc, 0xdd, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x40-0x47 */ +}; +static const unsigned char mac_croatian_page21[8] = { + 0x00, 0x00, 0xaa, 0x00, 0x00, 0x00, 0xbd, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char mac_croatian_page22[104] = { + 0x00, 0x00, 0xb6, 0x00, 0x00, 0x00, 0xb4, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb8, /* 0x08-0x0f */ + 0x00, 0xb7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, 0xb0, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0xba, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xc5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xad, 0x00, 0x00, 0x00, 0xb2, 0xb3, 0x00, 0x00, /* 0x60-0x67 */ +}; + +static int +mac_croatian_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0198) + c = mac_croatian_page00[wc-0x00a0]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = mac_croatian_page02[wc-0x02c0]; + else if (wc == 0x03c0) + c = 0xf9; + else if (wc >= 0x2010 && wc < 0x2048) + c = mac_croatian_page20[wc-0x2010]; + else if (wc >= 0x2120 && wc < 0x2128) + c = mac_croatian_page21[wc-0x2120]; + else if (wc >= 0x2200 && wc < 0x2268) + c = mac_croatian_page22[wc-0x2200]; + else if (wc == 0x25ca) + c = 0xd7; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/mac_cyrillic.h b/graf2d/win32gdk/gdk/src/iconv/mac_cyrillic.h new file mode 100644 index 0000000000000..a5b5972f28773 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mac_cyrillic.h @@ -0,0 +1,136 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MacCyrillic + */ + +static const unsigned short mac_cyrillic_2uni[128] = { + /* 0x80 */ + 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, + 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, 0x041f, + /* 0x90 */ + 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, 0x0427, + 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, 0x042f, + /* 0xa0 */ + 0x2020, 0x00b0, 0x00a2, 0x00a3, 0x00a7, 0x2022, 0x00b6, 0x0406, + 0x00ae, 0x00a9, 0x2122, 0x0402, 0x0452, 0x2260, 0x0403, 0x0453, + /* 0xb0 */ + 0x221e, 0x00b1, 0x2264, 0x2265, 0x0456, 0x00b5, 0x2202, 0x0408, + 0x0404, 0x0454, 0x0407, 0x0457, 0x0409, 0x0459, 0x040a, 0x045a, + /* 0xc0 */ + 0x0458, 0x0405, 0x00ac, 0x221a, 0x0192, 0x2248, 0x2206, 0x00ab, + 0x00bb, 0x2026, 0x00a0, 0x040b, 0x045b, 0x040c, 0x045c, 0x0455, + /* 0xd0 */ + 0x2013, 0x2014, 0x201c, 0x201d, 0x2018, 0x2019, 0x00f7, 0x201e, + 0x040e, 0x045e, 0x040f, 0x045f, 0x2116, 0x0401, 0x0451, 0x044f, + /* 0xe0 */ + 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0436, 0x0437, + 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, + /* 0xf0 */ + 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, + 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x00a4, +}; + +static int +mac_cyrillic_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c >= 0x80) + *pwc = (ucs4_t) mac_cyrillic_2uni[c-0x80]; + else + *pwc = (ucs4_t) c; + return 1; +} + +static const unsigned char mac_cyrillic_page00[32] = { + 0xca, 0x00, 0xa2, 0xa3, 0xff, 0x00, 0x00, 0xa4, /* 0xa0-0xa7 */ + 0x00, 0xa9, 0x00, 0xc7, 0xc2, 0x00, 0xa8, 0x00, /* 0xa8-0xaf */ + 0xa1, 0xb1, 0x00, 0x00, 0x00, 0xb5, 0xa6, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xc8, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ +}; +static const unsigned char mac_cyrillic_page04[96] = { + 0x00, 0xdd, 0xab, 0xae, 0xb8, 0xc1, 0xa7, 0xba, /* 0x00-0x07 */ + 0xb7, 0xbc, 0xbe, 0xcb, 0xcd, 0x00, 0xd8, 0xda, /* 0x08-0x0f */ + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, /* 0x10-0x17 */ + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, /* 0x18-0x1f */ + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, /* 0x20-0x27 */ + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, /* 0x28-0x2f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x30-0x37 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x38-0x3f */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0x40-0x47 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xdf, /* 0x48-0x4f */ + 0x00, 0xde, 0xac, 0xaf, 0xb9, 0xcf, 0xb4, 0xbb, /* 0x50-0x57 */ + 0xc0, 0xbd, 0xbf, 0xcc, 0xce, 0x00, 0xd9, 0xdb, /* 0x58-0x5f */ +}; +static const unsigned char mac_cyrillic_page20[24] = { + 0x00, 0x00, 0x00, 0xd0, 0xd1, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd4, 0xd5, 0x00, 0x00, 0xd2, 0xd3, 0xd7, 0x00, /* 0x18-0x1f */ + 0xa0, 0x00, 0xa5, 0x00, 0x00, 0x00, 0xc9, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char mac_cyrillic_page21[24] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xdc, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0xaa, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char mac_cyrillic_page22[104] = { + 0x00, 0x00, 0xb6, 0x00, 0x00, 0x00, 0xc6, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, 0xb0, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xc5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xad, 0x00, 0x00, 0x00, 0xb2, 0xb3, 0x00, 0x00, /* 0x60-0x67 */ +}; + +static int +mac_cyrillic_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = mac_cyrillic_page00[wc-0x00a0]; + else if (wc == 0x00f7) + c = 0xd6; + else if (wc == 0x0192) + c = 0xc4; + else if (wc >= 0x0400 && wc < 0x0460) + c = mac_cyrillic_page04[wc-0x0400]; + else if (wc >= 0x2010 && wc < 0x2028) + c = mac_cyrillic_page20[wc-0x2010]; + else if (wc >= 0x2110 && wc < 0x2128) + c = mac_cyrillic_page21[wc-0x2110]; + else if (wc >= 0x2200 && wc < 0x2268) + c = mac_cyrillic_page22[wc-0x2200]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/mac_greek.h b/graf2d/win32gdk/gdk/src/iconv/mac_greek.h new file mode 100644 index 0000000000000..3cc4ac29f8675 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mac_greek.h @@ -0,0 +1,135 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MacGreek + */ + +static const unsigned short mac_greek_2uni[128] = { + /* 0x80 */ + 0x00c4, 0x00b9, 0x00b2, 0x00c9, 0x00b3, 0x00d6, 0x00dc, 0x0385, + 0x00e0, 0x00e2, 0x00e4, 0x0384, 0x00a8, 0x00e7, 0x00e9, 0x00e8, + /* 0x90 */ + 0x00ea, 0x00eb, 0x00a3, 0x2122, 0x00ee, 0x00ef, 0x2022, 0x00bd, + 0x2030, 0x00f4, 0x00f6, 0x00a6, 0x00ad, 0x00f9, 0x00fb, 0x00fc, + /* 0xa0 */ + 0x2020, 0x0393, 0x0394, 0x0398, 0x039b, 0x039e, 0x03a0, 0x00df, + 0x00ae, 0x00a9, 0x03a3, 0x03aa, 0x00a7, 0x2260, 0x00b0, 0x0387, + /* 0xb0 */ + 0x0391, 0x00b1, 0x2264, 0x2265, 0x00a5, 0x0392, 0x0395, 0x0396, + 0x0397, 0x0399, 0x039a, 0x039c, 0x03a6, 0x03ab, 0x03a8, 0x03a9, + /* 0xc0 */ + 0x03ac, 0x039d, 0x00ac, 0x039f, 0x03a1, 0x2248, 0x03a4, 0x00ab, + 0x00bb, 0x2026, 0x00a0, 0x03a5, 0x03a7, 0x0386, 0x0388, 0x0153, + /* 0xd0 */ + 0x2013, 0x2015, 0x201c, 0x201d, 0x2018, 0x2019, 0x00f7, 0x0389, + 0x038a, 0x038c, 0x038e, 0x03ad, 0x03ae, 0x03af, 0x03cc, 0x038f, + /* 0xe0 */ + 0x03cd, 0x03b1, 0x03b2, 0x03c8, 0x03b4, 0x03b5, 0x03c6, 0x03b3, + 0x03b7, 0x03b9, 0x03be, 0x03ba, 0x03bb, 0x03bc, 0x03bd, 0x03bf, + /* 0xf0 */ + 0x03c0, 0x03ce, 0x03c1, 0x03c3, 0x03c4, 0x03b8, 0x03c9, 0x03c2, + 0x03c7, 0x03c5, 0x03b6, 0x03ca, 0x03cb, 0x0390, 0x03b0, 0xfffd, +}; + +static int +mac_greek_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = mac_greek_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char mac_greek_page00[96] = { + 0xca, 0x00, 0x00, 0x92, 0x00, 0xb4, 0x9b, 0xac, /* 0xa0-0xa7 */ + 0x8c, 0xa9, 0x00, 0xc7, 0xc2, 0x9c, 0xa8, 0x00, /* 0xa8-0xaf */ + 0xae, 0xb1, 0x82, 0x84, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x81, 0x00, 0xc8, 0x00, 0x97, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x83, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x86, 0x00, 0x00, 0xa7, /* 0xd8-0xdf */ + 0x88, 0x00, 0x89, 0x00, 0x8a, 0x00, 0x00, 0x8d, /* 0xe0-0xe7 */ + 0x8f, 0x8e, 0x90, 0x91, 0x00, 0x00, 0x94, 0x95, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x00, 0x99, 0x00, 0x9a, 0xd6, /* 0xf0-0xf7 */ + 0x00, 0x9d, 0x00, 0x9e, 0x9f, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; +static const unsigned char mac_greek_page03[80] = { + 0x00, 0x00, 0x00, 0x00, 0x8b, 0x87, 0xcd, 0xaf, /* 0x80-0x87 */ + 0xce, 0xd7, 0xd8, 0x00, 0xd9, 0x00, 0xda, 0xdf, /* 0x88-0x8f */ + 0xfd, 0xb0, 0xb5, 0xa1, 0xa2, 0xb6, 0xb7, 0xb8, /* 0x90-0x97 */ + 0xa3, 0xb9, 0xba, 0xa4, 0xbb, 0xc1, 0xa5, 0xc3, /* 0x98-0x9f */ + 0xa6, 0xc4, 0x00, 0xaa, 0xc6, 0xcb, 0xbc, 0xcc, /* 0xa0-0xa7 */ + 0xbe, 0xbf, 0xab, 0xbd, 0xc0, 0xdb, 0xdc, 0xdd, /* 0xa8-0xaf */ + 0xfe, 0xe1, 0xe2, 0xe7, 0xe4, 0xe5, 0xfa, 0xe8, /* 0xb0-0xb7 */ + 0xf5, 0xe9, 0xeb, 0xec, 0xed, 0xee, 0xea, 0xef, /* 0xb8-0xbf */ + 0xf0, 0xf2, 0xf7, 0xf3, 0xf4, 0xf9, 0xe6, 0xf8, /* 0xc0-0xc7 */ + 0xe3, 0xf6, 0xfb, 0xfc, 0xde, 0xe0, 0xf1, 0x00, /* 0xc8-0xcf */ +}; +static const unsigned char mac_greek_page20[40] = { + 0x00, 0x00, 0x00, 0xd0, 0x00, 0xd1, 0x00, 0x00, /* 0x10-0x17 */ + 0xd4, 0xd5, 0x00, 0x00, 0xd2, 0xd3, 0x00, 0x00, /* 0x18-0x1f */ + 0xa0, 0x00, 0x96, 0x00, 0x00, 0x00, 0xc9, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x98, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ +}; +static const unsigned char mac_greek_page22[32] = { + 0xc5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xad, 0x00, 0x00, 0x00, 0xb2, 0xb3, 0x00, 0x00, /* 0x60-0x67 */ +}; + +static int +mac_greek_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = mac_greek_page00[wc-0x00a0]; + else if (wc == 0x0153) + c = 0xcf; + else if (wc >= 0x0380 && wc < 0x03d0) + c = mac_greek_page03[wc-0x0380]; + else if (wc >= 0x2010 && wc < 0x2038) + c = mac_greek_page20[wc-0x2010]; + else if (wc == 0x2122) + c = 0x93; + else if (wc >= 0x2248 && wc < 0x2268) + c = mac_greek_page22[wc-0x2248]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/mac_hebrew.h b/graf2d/win32gdk/gdk/src/iconv/mac_hebrew.h new file mode 100644 index 0000000000000..c7f97bb6b1d01 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mac_hebrew.h @@ -0,0 +1,132 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MacHebrew + */ + +static const unsigned short mac_hebrew_2uni[128] = { + /* 0x80 */ + 0x00c4, 0xfb1f, 0x00c7, 0x00c9, 0x00d1, 0x00d6, 0x00dc, 0x00e1, + 0x00e0, 0x00e2, 0x00e4, 0x00e3, 0x00e5, 0x00e7, 0x00e9, 0x00e8, + /* 0x90 */ + 0x00ea, 0x00eb, 0x00ed, 0x00ec, 0x00ee, 0x00ef, 0x00f1, 0x00f3, + 0x00f2, 0x00f4, 0x00f6, 0x00f5, 0x00fa, 0x00f9, 0x00fb, 0x00fc, + /* 0xa0 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x20aa, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xb0 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, + /* 0xc0 */ + 0xfffd, 0x201e, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x05bc, 0xfb4b, + 0xfb35, 0x2026, 0x00a0, 0x05b8, 0x05b7, 0x05b5, 0x05b6, 0x05b4, + /* 0xd0 */ + 0x2013, 0x2014, 0x201c, 0x201d, 0x2018, 0x2019, 0xfb2a, 0xfb2b, + 0x05bf, 0x05b0, 0x05b2, 0x05b1, 0x05bb, 0x05b9, 0xfffd, 0x05b3, + /* 0xe0 */ + 0x05d0, 0x05d1, 0x05d2, 0x05d3, 0x05d4, 0x05d5, 0x05d6, 0x05d7, + 0x05d8, 0x05d9, 0x05da, 0x05db, 0x05dc, 0x05dd, 0x05de, 0x05df, + /* 0xf0 */ + 0x05e0, 0x05e1, 0x05e2, 0x05e3, 0x05e4, 0x05e5, 0x05e6, 0x05e7, + 0x05e8, 0x05e9, 0x05ea, 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0xfffd, +}; + +static int +mac_hebrew_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else if (c >= 0x80) { + unsigned short wc = mac_hebrew_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char mac_hebrew_page00[96] = { + 0xca, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x82, /* 0xc0-0xc7 */ + 0x00, 0x83, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x84, 0x00, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x86, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x88, 0x87, 0x89, 0x8b, 0x8a, 0x8c, 0x00, 0x8d, /* 0xe0-0xe7 */ + 0x8f, 0x8e, 0x90, 0x91, 0x93, 0x92, 0x94, 0x95, /* 0xe8-0xef */ + 0x00, 0x96, 0x98, 0x97, 0x99, 0x9b, 0x9a, 0x00, /* 0xf0-0xf7 */ + 0x00, 0x9d, 0x9c, 0x9e, 0x9f, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; +static const unsigned char mac_hebrew_page05[64] = { + 0xd9, 0xdb, 0xda, 0xdf, 0xcf, 0xcd, 0xce, 0xcc, /* 0xb0-0xb7 */ + 0xcb, 0xdd, 0x00, 0xdc, 0xc6, 0x00, 0x00, 0xd8, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0xd0-0xd7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0xd8-0xdf */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0xe0-0xe7 */ + 0xf8, 0xf9, 0xfa, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ +}; +static const unsigned char mac_hebrew_page20[24] = { + 0x00, 0x00, 0x00, 0xd0, 0xd1, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd4, 0xd5, 0x00, 0x00, 0xd2, 0xd3, 0xc1, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc9, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char mac_hebrew_pagefb[56] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0xd6, 0xd7, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc8, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0xc7, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ +}; + +static int +mac_hebrew_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = mac_hebrew_page00[wc-0x00a0]; + else if (wc >= 0x05b0 && wc < 0x05f0) + c = mac_hebrew_page05[wc-0x05b0]; + else if (wc >= 0x2010 && wc < 0x2028) + c = mac_hebrew_page20[wc-0x2010]; + else if (wc == 0x20aa) + c = 0xa6; + else if (wc >= 0xfb18 && wc < 0xfb50) + c = mac_hebrew_pagefb[wc-0xfb18]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/mac_iceland.h b/graf2d/win32gdk/gdk/src/iconv/mac_iceland.h new file mode 100644 index 0000000000000..b49f1642aff73 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mac_iceland.h @@ -0,0 +1,162 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MacIceland + */ + +static const unsigned short mac_iceland_2uni[128] = { + /* 0x80 */ + 0x00c4, 0x00c5, 0x00c7, 0x00c9, 0x00d1, 0x00d6, 0x00dc, 0x00e1, + 0x00e0, 0x00e2, 0x00e4, 0x00e3, 0x00e5, 0x00e7, 0x00e9, 0x00e8, + /* 0x90 */ + 0x00ea, 0x00eb, 0x00ed, 0x00ec, 0x00ee, 0x00ef, 0x00f1, 0x00f3, + 0x00f2, 0x00f4, 0x00f6, 0x00f5, 0x00fa, 0x00f9, 0x00fb, 0x00fc, + /* 0xa0 */ + 0x00dd, 0x00b0, 0x00a2, 0x00a3, 0x00a7, 0x2022, 0x00b6, 0x00df, + 0x00ae, 0x00a9, 0x2122, 0x00b4, 0x00a8, 0x2260, 0x00c6, 0x00d8, + /* 0xb0 */ + 0x221e, 0x00b1, 0x2264, 0x2265, 0x00a5, 0x00b5, 0x2202, 0x2211, + 0x220f, 0x03c0, 0x222b, 0x00aa, 0x00ba, 0x2126, 0x00e6, 0x00f8, + /* 0xc0 */ + 0x00bf, 0x00a1, 0x00ac, 0x221a, 0x0192, 0x2248, 0x2206, 0x00ab, + 0x00bb, 0x2026, 0x00a0, 0x00c0, 0x00c3, 0x00d5, 0x0152, 0x0153, + /* 0xd0 */ + 0x2013, 0x2014, 0x201c, 0x201d, 0x2018, 0x2019, 0x00f7, 0x25ca, + 0x00ff, 0x0178, 0x2044, 0x00a4, 0x00d0, 0x00f0, 0x00de, 0x00fe, + /* 0xe0 */ + 0x00fd, 0x00b7, 0x201a, 0x201e, 0x2030, 0x00c2, 0x00ca, 0x00c1, + 0x00cb, 0x00c8, 0x00cd, 0x00ce, 0x00cf, 0x00cc, 0x00d3, 0x00d4, + /* 0xf0 */ + 0xfffd, 0x00d2, 0x00da, 0x00db, 0x00d9, 0x0131, 0x02c6, 0x02dc, + 0x00af, 0x02d8, 0x02d9, 0x02da, 0x00b8, 0x02dd, 0x02db, 0x02c7, +}; + +static int +mac_iceland_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = mac_iceland_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char mac_iceland_page00[96] = { + 0xca, 0xc1, 0xa2, 0xa3, 0xdb, 0xb4, 0x00, 0xa4, /* 0xa0-0xa7 */ + 0xac, 0xa9, 0xbb, 0xc7, 0xc2, 0x00, 0xa8, 0xf8, /* 0xa8-0xaf */ + 0xa1, 0xb1, 0x00, 0x00, 0xab, 0xb5, 0xa6, 0xe1, /* 0xb0-0xb7 */ + 0xfc, 0x00, 0xbc, 0xc8, 0x00, 0x00, 0x00, 0xc0, /* 0xb8-0xbf */ + 0xcb, 0xe7, 0xe5, 0xcc, 0x80, 0x81, 0xae, 0x82, /* 0xc0-0xc7 */ + 0xe9, 0x83, 0xe6, 0xe8, 0xed, 0xea, 0xeb, 0xec, /* 0xc8-0xcf */ + 0xdc, 0x84, 0xf1, 0xee, 0xef, 0xcd, 0x85, 0x00, /* 0xd0-0xd7 */ + 0xaf, 0xf4, 0xf2, 0xf3, 0x86, 0xa0, 0xde, 0xa7, /* 0xd8-0xdf */ + 0x88, 0x87, 0x89, 0x8b, 0x8a, 0x8c, 0xbe, 0x8d, /* 0xe0-0xe7 */ + 0x8f, 0x8e, 0x90, 0x91, 0x93, 0x92, 0x94, 0x95, /* 0xe8-0xef */ + 0xdd, 0x96, 0x98, 0x97, 0x99, 0x9b, 0x9a, 0xd6, /* 0xf0-0xf7 */ + 0xbf, 0x9d, 0x9c, 0x9e, 0x9f, 0xe0, 0xdf, 0xd8, /* 0xf8-0xff */ +}; +static const unsigned char mac_iceland_page01[104] = { + 0x00, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0xce, 0xcf, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0xd9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0xc4, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char mac_iceland_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf6, 0xff, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0xf9, 0xfa, 0xfb, 0xfe, 0xf7, 0xfd, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char mac_iceland_page20[56] = { + 0x00, 0x00, 0x00, 0xd0, 0xd1, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd4, 0xd5, 0xe2, 0x00, 0xd2, 0xd3, 0xe3, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0xa5, 0x00, 0x00, 0x00, 0xc9, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0xe4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x40-0x47 */ +}; +static const unsigned char mac_iceland_page21[8] = { + 0x00, 0x00, 0xaa, 0x00, 0x00, 0x00, 0xbd, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char mac_iceland_page22[104] = { + 0x00, 0x00, 0xb6, 0x00, 0x00, 0x00, 0xc6, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb8, /* 0x08-0x0f */ + 0x00, 0xb7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, 0xb0, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0xba, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xc5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xad, 0x00, 0x00, 0x00, 0xb2, 0xb3, 0x00, 0x00, /* 0x60-0x67 */ +}; + +static int +mac_iceland_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = mac_iceland_page00[wc-0x00a0]; + else if (wc >= 0x0130 && wc < 0x0198) + c = mac_iceland_page01[wc-0x0130]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = mac_iceland_page02[wc-0x02c0]; + else if (wc == 0x03c0) + c = 0xb9; + else if (wc >= 0x2010 && wc < 0x2048) + c = mac_iceland_page20[wc-0x2010]; + else if (wc >= 0x2120 && wc < 0x2128) + c = mac_iceland_page21[wc-0x2120]; + else if (wc >= 0x2200 && wc < 0x2268) + c = mac_iceland_page22[wc-0x2200]; + else if (wc == 0x25ca) + c = 0xd7; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/mac_roman.h b/graf2d/win32gdk/gdk/src/iconv/mac_roman.h new file mode 100644 index 0000000000000..7a6d51aa0bc89 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mac_roman.h @@ -0,0 +1,167 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MacRoman + */ + +static const unsigned short mac_roman_2uni[128] = { + /* 0x80 */ + 0x00c4, 0x00c5, 0x00c7, 0x00c9, 0x00d1, 0x00d6, 0x00dc, 0x00e1, + 0x00e0, 0x00e2, 0x00e4, 0x00e3, 0x00e5, 0x00e7, 0x00e9, 0x00e8, + /* 0x90 */ + 0x00ea, 0x00eb, 0x00ed, 0x00ec, 0x00ee, 0x00ef, 0x00f1, 0x00f3, + 0x00f2, 0x00f4, 0x00f6, 0x00f5, 0x00fa, 0x00f9, 0x00fb, 0x00fc, + /* 0xa0 */ + 0x2020, 0x00b0, 0x00a2, 0x00a3, 0x00a7, 0x2022, 0x00b6, 0x00df, + 0x00ae, 0x00a9, 0x2122, 0x00b4, 0x00a8, 0x2260, 0x00c6, 0x00d8, + /* 0xb0 */ + 0x221e, 0x00b1, 0x2264, 0x2265, 0x00a5, 0x00b5, 0x2202, 0x2211, + 0x220f, 0x03c0, 0x222b, 0x00aa, 0x00ba, 0x2126, 0x00e6, 0x00f8, + /* 0xc0 */ + 0x00bf, 0x00a1, 0x00ac, 0x221a, 0x0192, 0x2248, 0x2206, 0x00ab, + 0x00bb, 0x2026, 0x00a0, 0x00c0, 0x00c3, 0x00d5, 0x0152, 0x0153, + /* 0xd0 */ + 0x2013, 0x2014, 0x201c, 0x201d, 0x2018, 0x2019, 0x00f7, 0x25ca, + 0x00ff, 0x0178, 0x2044, 0x00a4, 0x2039, 0x203a, 0xfb01, 0xfb02, + /* 0xe0 */ + 0x2021, 0x00b7, 0x201a, 0x201e, 0x2030, 0x00c2, 0x00ca, 0x00c1, + 0x00cb, 0x00c8, 0x00cd, 0x00ce, 0x00cf, 0x00cc, 0x00d3, 0x00d4, + /* 0xf0 */ + 0xfffd, 0x00d2, 0x00da, 0x00db, 0x00d9, 0x0131, 0x02c6, 0x02dc, + 0x00af, 0x02d8, 0x02d9, 0x02da, 0x00b8, 0x02dd, 0x02db, 0x02c7, +}; + +static int +mac_roman_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = mac_roman_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char mac_roman_page00[96] = { + 0xca, 0xc1, 0xa2, 0xa3, 0xdb, 0xb4, 0x00, 0xa4, /* 0xa0-0xa7 */ + 0xac, 0xa9, 0xbb, 0xc7, 0xc2, 0x00, 0xa8, 0xf8, /* 0xa8-0xaf */ + 0xa1, 0xb1, 0x00, 0x00, 0xab, 0xb5, 0xa6, 0xe1, /* 0xb0-0xb7 */ + 0xfc, 0x00, 0xbc, 0xc8, 0x00, 0x00, 0x00, 0xc0, /* 0xb8-0xbf */ + 0xcb, 0xe7, 0xe5, 0xcc, 0x80, 0x81, 0xae, 0x82, /* 0xc0-0xc7 */ + 0xe9, 0x83, 0xe6, 0xe8, 0xed, 0xea, 0xeb, 0xec, /* 0xc8-0xcf */ + 0x00, 0x84, 0xf1, 0xee, 0xef, 0xcd, 0x85, 0x00, /* 0xd0-0xd7 */ + 0xaf, 0xf4, 0xf2, 0xf3, 0x86, 0x00, 0x00, 0xa7, /* 0xd8-0xdf */ + 0x88, 0x87, 0x89, 0x8b, 0x8a, 0x8c, 0xbe, 0x8d, /* 0xe0-0xe7 */ + 0x8f, 0x8e, 0x90, 0x91, 0x93, 0x92, 0x94, 0x95, /* 0xe8-0xef */ + 0x00, 0x96, 0x98, 0x97, 0x99, 0x9b, 0x9a, 0xd6, /* 0xf0-0xf7 */ + 0xbf, 0x9d, 0x9c, 0x9e, 0x9f, 0x00, 0x00, 0xd8, /* 0xf8-0xff */ +}; +static const unsigned char mac_roman_page01[104] = { + 0x00, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0xce, 0xcf, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0xd9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0xc4, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char mac_roman_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf6, 0xff, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0xf9, 0xfa, 0xfb, 0xfe, 0xf7, 0xfd, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char mac_roman_page20[56] = { + 0x00, 0x00, 0x00, 0xd0, 0xd1, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd4, 0xd5, 0xe2, 0x00, 0xd2, 0xd3, 0xe3, 0x00, /* 0x18-0x1f */ + 0xa0, 0xe0, 0xa5, 0x00, 0x00, 0x00, 0xc9, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0xe4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0xdc, 0xdd, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x40-0x47 */ +}; +static const unsigned char mac_roman_page21[8] = { + 0x00, 0x00, 0xaa, 0x00, 0x00, 0x00, 0xbd, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char mac_roman_page22[104] = { + 0x00, 0x00, 0xb6, 0x00, 0x00, 0x00, 0xc6, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb8, /* 0x08-0x0f */ + 0x00, 0xb7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, 0xb0, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0xba, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xc5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xad, 0x00, 0x00, 0x00, 0xb2, 0xb3, 0x00, 0x00, /* 0x60-0x67 */ +}; +static const unsigned char mac_roman_pagefb[8] = { + 0x00, 0xde, 0xdf, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ +}; + +static int +mac_roman_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = mac_roman_page00[wc-0x00a0]; + else if (wc >= 0x0130 && wc < 0x0198) + c = mac_roman_page01[wc-0x0130]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = mac_roman_page02[wc-0x02c0]; + else if (wc == 0x03c0) + c = 0xb9; + else if (wc >= 0x2010 && wc < 0x2048) + c = mac_roman_page20[wc-0x2010]; + else if (wc >= 0x2120 && wc < 0x2128) + c = mac_roman_page21[wc-0x2120]; + else if (wc >= 0x2200 && wc < 0x2268) + c = mac_roman_page22[wc-0x2200]; + else if (wc == 0x25ca) + c = 0xd7; + else if (wc >= 0xfb00 && wc < 0xfb08) + c = mac_roman_pagefb[wc-0xfb00]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/mac_romania.h b/graf2d/win32gdk/gdk/src/iconv/mac_romania.h new file mode 100644 index 0000000000000..2d35562d89757 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mac_romania.h @@ -0,0 +1,165 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MacRomania + */ + +static const unsigned short mac_romania_2uni[128] = { + /* 0x80 */ + 0x00c4, 0x00c5, 0x00c7, 0x00c9, 0x00d1, 0x00d6, 0x00dc, 0x00e1, + 0x00e0, 0x00e2, 0x00e4, 0x00e3, 0x00e5, 0x00e7, 0x00e9, 0x00e8, + /* 0x90 */ + 0x00ea, 0x00eb, 0x00ed, 0x00ec, 0x00ee, 0x00ef, 0x00f1, 0x00f3, + 0x00f2, 0x00f4, 0x00f6, 0x00f5, 0x00fa, 0x00f9, 0x00fb, 0x00fc, + /* 0xa0 */ + 0x2020, 0x00b0, 0x00a2, 0x00a3, 0x00a7, 0x2022, 0x00b6, 0x00df, + 0x00ae, 0x00a9, 0x2122, 0x00b4, 0x00a8, 0x2260, 0x0102, 0x015e, + /* 0xb0 */ + 0x221e, 0x00b1, 0x2264, 0x2265, 0x00a5, 0x00b5, 0x2202, 0x2211, + 0x220f, 0x03c0, 0x222b, 0x00aa, 0x00ba, 0x2126, 0x0103, 0x015f, + /* 0xc0 */ + 0x00bf, 0x00a1, 0x00ac, 0x221a, 0x0192, 0x2248, 0x2206, 0x00ab, + 0x00bb, 0x2026, 0x00a0, 0x00c0, 0x00c3, 0x00d5, 0x0152, 0x0153, + /* 0xd0 */ + 0x2013, 0x2014, 0x201c, 0x201d, 0x2018, 0x2019, 0x00f7, 0x25ca, + 0x00ff, 0x0178, 0x2044, 0x00a4, 0x2039, 0x203a, 0x0162, 0x0163, + /* 0xe0 */ + 0x2021, 0x00b7, 0x201a, 0x201e, 0x2030, 0x00c2, 0x00ca, 0x00c1, + 0x00cb, 0x00c8, 0x00cd, 0x00ce, 0x00cf, 0x00cc, 0x00d3, 0x00d4, + /* 0xf0 */ + 0xfffd, 0x00d2, 0x00da, 0x00db, 0x00d9, 0x0131, 0x02c6, 0x02dc, + 0x00af, 0x02d8, 0x02d9, 0x02da, 0x00b8, 0x02dd, 0x02db, 0x02c7, +}; + +static int +mac_romania_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = mac_romania_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char mac_romania_page00[248] = { + 0xca, 0xc1, 0xa2, 0xa3, 0xdb, 0xb4, 0x00, 0xa4, /* 0xa0-0xa7 */ + 0xac, 0xa9, 0xbb, 0xc7, 0xc2, 0x00, 0xa8, 0xf8, /* 0xa8-0xaf */ + 0xa1, 0xb1, 0x00, 0x00, 0xab, 0xb5, 0xa6, 0xe1, /* 0xb0-0xb7 */ + 0xfc, 0x00, 0xbc, 0xc8, 0x00, 0x00, 0x00, 0xc0, /* 0xb8-0xbf */ + 0xcb, 0xe7, 0xe5, 0xcc, 0x80, 0x81, 0x00, 0x82, /* 0xc0-0xc7 */ + 0xe9, 0x83, 0xe6, 0xe8, 0xed, 0xea, 0xeb, 0xec, /* 0xc8-0xcf */ + 0x00, 0x84, 0xf1, 0xee, 0xef, 0xcd, 0x85, 0x00, /* 0xd0-0xd7 */ + 0x00, 0xf4, 0xf2, 0xf3, 0x86, 0x00, 0x00, 0xa7, /* 0xd8-0xdf */ + 0x88, 0x87, 0x89, 0x8b, 0x8a, 0x8c, 0x00, 0x8d, /* 0xe0-0xe7 */ + 0x8f, 0x8e, 0x90, 0x91, 0x93, 0x92, 0x94, 0x95, /* 0xe8-0xef */ + 0x00, 0x96, 0x98, 0x97, 0x99, 0x9b, 0x9a, 0xd6, /* 0xf0-0xf7 */ + 0x00, 0x9d, 0x9c, 0x9e, 0x9f, 0x00, 0x00, 0xd8, /* 0xf8-0xff */ + /* 0x0100 */ + 0x00, 0x00, 0xae, 0xbe, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0xce, 0xcf, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xaf, 0xbf, /* 0x58-0x5f */ + 0x00, 0x00, 0xde, 0xdf, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0xd9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0xc4, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char mac_romania_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf6, 0xff, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0xf9, 0xfa, 0xfb, 0xfe, 0xf7, 0xfd, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char mac_romania_page20[56] = { + 0x00, 0x00, 0x00, 0xd0, 0xd1, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd4, 0xd5, 0xe2, 0x00, 0xd2, 0xd3, 0xe3, 0x00, /* 0x18-0x1f */ + 0xa0, 0xe0, 0xa5, 0x00, 0x00, 0x00, 0xc9, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0xe4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0xdc, 0xdd, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0xda, 0x00, 0x00, 0x00, /* 0x40-0x47 */ +}; +static const unsigned char mac_romania_page21[8] = { + 0x00, 0x00, 0xaa, 0x00, 0x00, 0x00, 0xbd, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char mac_romania_page22[104] = { + 0x00, 0x00, 0xb6, 0x00, 0x00, 0x00, 0xc6, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb8, /* 0x08-0x0f */ + 0x00, 0xb7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, 0xb0, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0xba, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xc5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xad, 0x00, 0x00, 0x00, 0xb2, 0xb3, 0x00, 0x00, /* 0x60-0x67 */ +}; + +static int +mac_romania_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0198) + c = mac_romania_page00[wc-0x00a0]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = mac_romania_page02[wc-0x02c0]; + else if (wc == 0x03c0) + c = 0xb9; + else if (wc >= 0x2010 && wc < 0x2048) + c = mac_romania_page20[wc-0x2010]; + else if (wc >= 0x2120 && wc < 0x2128) + c = mac_romania_page21[wc-0x2120]; + else if (wc >= 0x2200 && wc < 0x2268) + c = mac_romania_page22[wc-0x2200]; + else if (wc == 0x25ca) + c = 0xd7; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/mac_thai.h b/graf2d/win32gdk/gdk/src/iconv/mac_thai.h new file mode 100644 index 0000000000000..74d15aaf7f576 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mac_thai.h @@ -0,0 +1,128 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MacThai + */ + +static const unsigned short mac_thai_2uni[128] = { + /* 0x80 */ + 0x00ab, 0x00bb, 0x2026, 0xf88c, 0xf88f, 0xf892, 0xf895, 0xf898, + 0xf88b, 0xf88e, 0xf891, 0xf894, 0xf897, 0x201c, 0x201d, 0xf899, + /* 0x90 */ + 0xfffd, 0x2022, 0xf884, 0xf889, 0xf885, 0xf886, 0xf887, 0xf888, + 0xf88a, 0xf88d, 0xf890, 0xf893, 0xf896, 0x2018, 0x2019, 0xfffd, + /* 0xa0 */ + 0x00a0, 0x0e01, 0x0e02, 0x0e03, 0x0e04, 0x0e05, 0x0e06, 0x0e07, + 0x0e08, 0x0e09, 0x0e0a, 0x0e0b, 0x0e0c, 0x0e0d, 0x0e0e, 0x0e0f, + /* 0xb0 */ + 0x0e10, 0x0e11, 0x0e12, 0x0e13, 0x0e14, 0x0e15, 0x0e16, 0x0e17, + 0x0e18, 0x0e19, 0x0e1a, 0x0e1b, 0x0e1c, 0x0e1d, 0x0e1e, 0x0e1f, + /* 0xc0 */ + 0x0e20, 0x0e21, 0x0e22, 0x0e23, 0x0e24, 0x0e25, 0x0e26, 0x0e27, + 0x0e28, 0x0e29, 0x0e2a, 0x0e2b, 0x0e2c, 0x0e2d, 0x0e2e, 0x0e2f, + /* 0xd0 */ + 0x0e30, 0x0e31, 0x0e32, 0x0e33, 0x0e34, 0x0e35, 0x0e36, 0x0e37, + 0x0e38, 0x0e39, 0x0e3a, 0xfeff, 0x200b, 0x2013, 0x2014, 0x0e3f, + /* 0xe0 */ + 0x0e40, 0x0e41, 0x0e42, 0x0e43, 0x0e44, 0x0e45, 0x0e46, 0x0e47, + 0x0e48, 0x0e49, 0x0e4a, 0x0e4b, 0x0e4c, 0x0e4d, 0x2122, 0x0e4f, + /* 0xf0 */ + 0x0e50, 0x0e51, 0x0e52, 0x0e53, 0x0e54, 0x0e55, 0x0e56, 0x0e57, + 0x0e58, 0x0e59, 0x00ae, 0x00a9, 0xfffd, 0xfffd, 0xfffd, 0xfffd, +}; + +static int +mac_thai_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = mac_thai_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char mac_thai_page00[32] = { + 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0xfb, 0x00, 0x80, 0x00, 0x00, 0xfa, 0x00, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x81, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ +}; +static const unsigned char mac_thai_page0e[96] = { + 0x00, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, /* 0x00-0x07 */ + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, /* 0x08-0x0f */ + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, /* 0x10-0x17 */ + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, /* 0x18-0x1f */ + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x20-0x27 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x28-0x2f */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0x30-0x37 */ + 0xd8, 0xd9, 0xda, 0x00, 0x00, 0x00, 0x00, 0xdf, /* 0x38-0x3f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x40-0x47 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0x00, 0xef, /* 0x48-0x4f */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0x50-0x57 */ + 0xf8, 0xf9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ +}; +static const unsigned char mac_thai_page20[32] = { + 0x00, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0xdd, 0xde, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x9d, 0x9e, 0x00, 0x00, 0x8d, 0x8e, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x91, 0x00, 0x00, 0x00, 0x82, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char mac_thai_pagef8[32] = { + 0x00, 0x00, 0x00, 0x00, 0x92, 0x94, 0x95, 0x96, /* 0x80-0x87 */ + 0x97, 0x93, 0x98, 0x88, 0x83, 0x99, 0x89, 0x84, /* 0x88-0x8f */ + 0x9a, 0x8a, 0x85, 0x9b, 0x8b, 0x86, 0x9c, 0x8c, /* 0x90-0x97 */ + 0x87, 0x8f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ +}; + +static int +mac_thai_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = mac_thai_page00[wc-0x00a0]; + else if (wc >= 0x0e00 && wc < 0x0e60) + c = mac_thai_page0e[wc-0x0e00]; + else if (wc >= 0x2008 && wc < 0x2028) + c = mac_thai_page20[wc-0x2008]; + else if (wc == 0x2122) + c = 0xee; + else if (wc >= 0xf880 && wc < 0xf8a0) + c = mac_thai_pagef8[wc-0xf880]; + else if (wc == 0xfeff) + c = 0xdb; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/mac_turkish.h b/graf2d/win32gdk/gdk/src/iconv/mac_turkish.h new file mode 100644 index 0000000000000..94f7d376b93f6 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mac_turkish.h @@ -0,0 +1,163 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MacTurkish + */ + +static const unsigned short mac_turkish_2uni[128] = { + /* 0x80 */ + 0x00c4, 0x00c5, 0x00c7, 0x00c9, 0x00d1, 0x00d6, 0x00dc, 0x00e1, + 0x00e0, 0x00e2, 0x00e4, 0x00e3, 0x00e5, 0x00e7, 0x00e9, 0x00e8, + /* 0x90 */ + 0x00ea, 0x00eb, 0x00ed, 0x00ec, 0x00ee, 0x00ef, 0x00f1, 0x00f3, + 0x00f2, 0x00f4, 0x00f6, 0x00f5, 0x00fa, 0x00f9, 0x00fb, 0x00fc, + /* 0xa0 */ + 0x2020, 0x00b0, 0x00a2, 0x00a3, 0x00a7, 0x2022, 0x00b6, 0x00df, + 0x00ae, 0x00a9, 0x2122, 0x00b4, 0x00a8, 0x2260, 0x00c6, 0x00d8, + /* 0xb0 */ + 0x221e, 0x00b1, 0x2264, 0x2265, 0x00a5, 0x00b5, 0x2202, 0x2211, + 0x220f, 0x03c0, 0x222b, 0x00aa, 0x00ba, 0x2126, 0x00e6, 0x00f8, + /* 0xc0 */ + 0x00bf, 0x00a1, 0x00ac, 0x221a, 0x0192, 0x2248, 0x2206, 0x00ab, + 0x00bb, 0x2026, 0x00a0, 0x00c0, 0x00c3, 0x00d5, 0x0152, 0x0153, + /* 0xd0 */ + 0x2013, 0x2014, 0x201c, 0x201d, 0x2018, 0x2019, 0x00f7, 0x25ca, + 0x00ff, 0x0178, 0x011e, 0x011f, 0x0130, 0x0131, 0x015e, 0x015f, + /* 0xe0 */ + 0x2021, 0x00b7, 0x201a, 0x201e, 0x2030, 0x00c2, 0x00ca, 0x00c1, + 0x00cb, 0x00c8, 0x00cd, 0x00ce, 0x00cf, 0x00cc, 0x00d3, 0x00d4, + /* 0xf0 */ + 0xfffd, 0x00d2, 0x00da, 0x00db, 0x00d9, 0xfffd, 0x02c6, 0x02dc, + 0x00af, 0x02d8, 0x02d9, 0x02da, 0x00b8, 0x02dd, 0x02db, 0x02c7, +}; + +static int +mac_turkish_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = mac_turkish_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char mac_turkish_page00[96] = { + 0xca, 0xc1, 0xa2, 0xa3, 0x00, 0xb4, 0x00, 0xa4, /* 0xa0-0xa7 */ + 0xac, 0xa9, 0xbb, 0xc7, 0xc2, 0x00, 0xa8, 0xf8, /* 0xa8-0xaf */ + 0xa1, 0xb1, 0x00, 0x00, 0xab, 0xb5, 0xa6, 0xe1, /* 0xb0-0xb7 */ + 0xfc, 0x00, 0xbc, 0xc8, 0x00, 0x00, 0x00, 0xc0, /* 0xb8-0xbf */ + 0xcb, 0xe7, 0xe5, 0xcc, 0x80, 0x81, 0xae, 0x82, /* 0xc0-0xc7 */ + 0xe9, 0x83, 0xe6, 0xe8, 0xed, 0xea, 0xeb, 0xec, /* 0xc8-0xcf */ + 0x00, 0x84, 0xf1, 0xee, 0xef, 0xcd, 0x85, 0x00, /* 0xd0-0xd7 */ + 0xaf, 0xf4, 0xf2, 0xf3, 0x86, 0x00, 0x00, 0xa7, /* 0xd8-0xdf */ + 0x88, 0x87, 0x89, 0x8b, 0x8a, 0x8c, 0xbe, 0x8d, /* 0xe0-0xe7 */ + 0x8f, 0x8e, 0x90, 0x91, 0x93, 0x92, 0x94, 0x95, /* 0xe8-0xef */ + 0x00, 0x96, 0x98, 0x97, 0x99, 0x9b, 0x9a, 0xd6, /* 0xf0-0xf7 */ + 0xbf, 0x9d, 0x9c, 0x9e, 0x9f, 0x00, 0x00, 0xd8, /* 0xf8-0xff */ +}; +static const unsigned char mac_turkish_page01[128] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xda, 0xdb, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0xdc, 0xdd, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0xce, 0xcf, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xde, 0xdf, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0xd9, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0xc4, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char mac_turkish_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf6, 0xff, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0xf9, 0xfa, 0xfb, 0xfe, 0xf7, 0xfd, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char mac_turkish_page20[40] = { + 0x00, 0x00, 0x00, 0xd0, 0xd1, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd4, 0xd5, 0xe2, 0x00, 0xd2, 0xd3, 0xe3, 0x00, /* 0x18-0x1f */ + 0xa0, 0xe0, 0xa5, 0x00, 0x00, 0x00, 0xc9, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0xe4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ +}; +static const unsigned char mac_turkish_page21[8] = { + 0x00, 0x00, 0xaa, 0x00, 0x00, 0x00, 0xbd, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char mac_turkish_page22[104] = { + 0x00, 0x00, 0xb6, 0x00, 0x00, 0x00, 0xc6, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb8, /* 0x08-0x0f */ + 0x00, 0xb7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, 0xb0, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0xba, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xc5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xad, 0x00, 0x00, 0x00, 0xb2, 0xb3, 0x00, 0x00, /* 0x60-0x67 */ +}; + +static int +mac_turkish_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = mac_turkish_page00[wc-0x00a0]; + else if (wc >= 0x0118 && wc < 0x0198) + c = mac_turkish_page01[wc-0x0118]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = mac_turkish_page02[wc-0x02c0]; + else if (wc == 0x03c0) + c = 0xb9; + else if (wc >= 0x2010 && wc < 0x2038) + c = mac_turkish_page20[wc-0x2010]; + else if (wc >= 0x2120 && wc < 0x2128) + c = mac_turkish_page21[wc-0x2120]; + else if (wc >= 0x2200 && wc < 0x2268) + c = mac_turkish_page22[wc-0x2200]; + else if (wc == 0x25ca) + c = 0xd7; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/mac_ukraine.h b/graf2d/win32gdk/gdk/src/iconv/mac_ukraine.h new file mode 100644 index 0000000000000..8ea17b09c9a99 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mac_ukraine.h @@ -0,0 +1,143 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MacUkraine + */ + +static const unsigned short mac_ukraine_2uni[128] = { + /* 0x80 */ + 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, + 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, 0x041f, + /* 0x90 */ + 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, 0x0427, + 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, 0x042f, + /* 0xa0 */ + 0x2020, 0x00b0, 0x0490, 0x00a3, 0x00a7, 0x2022, 0x00b6, 0x0406, + 0x00ae, 0x00a9, 0x2122, 0x0402, 0x0452, 0x2260, 0x0403, 0x0453, + /* 0xb0 */ + 0x221e, 0x00b1, 0x2264, 0x2265, 0x0456, 0x00b5, 0x0491, 0x0408, + 0x0404, 0x0454, 0x0407, 0x0457, 0x0409, 0x0459, 0x040a, 0x045a, + /* 0xc0 */ + 0x0458, 0x0405, 0x00ac, 0x221a, 0x0192, 0x2248, 0x2206, 0x00ab, + 0x00bb, 0x2026, 0x00a0, 0x040b, 0x045b, 0x040c, 0x045c, 0x0455, + /* 0xd0 */ + 0x2013, 0x2014, 0x201c, 0x201d, 0x2018, 0x2019, 0x00f7, 0x201e, + 0x040e, 0x045e, 0x040f, 0x045f, 0x2116, 0x0401, 0x0451, 0x044f, + /* 0xe0 */ + 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0436, 0x0437, + 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, + /* 0xf0 */ + 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, + 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x00a4, +}; + +static int +mac_ukraine_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c >= 0x80) + *pwc = (ucs4_t) mac_ukraine_2uni[c-0x80]; + else + *pwc = (ucs4_t) c; + return 1; +} + +static const unsigned char mac_ukraine_page00[32] = { + 0xca, 0x00, 0x00, 0xa3, 0xff, 0x00, 0x00, 0xa4, /* 0xa0-0xa7 */ + 0x00, 0xa9, 0x00, 0xc7, 0xc2, 0x00, 0xa8, 0x00, /* 0xa8-0xaf */ + 0xa1, 0xb1, 0x00, 0x00, 0x00, 0xb5, 0xa6, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xc8, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ +}; +static const unsigned char mac_ukraine_page04[152] = { + 0x00, 0xdd, 0xab, 0xae, 0xb8, 0xc1, 0xa7, 0xba, /* 0x00-0x07 */ + 0xb7, 0xbc, 0xbe, 0xcb, 0xcd, 0x00, 0xd8, 0xda, /* 0x08-0x0f */ + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, /* 0x10-0x17 */ + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, /* 0x18-0x1f */ + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, /* 0x20-0x27 */ + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, /* 0x28-0x2f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x30-0x37 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x38-0x3f */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0x40-0x47 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xdf, /* 0x48-0x4f */ + 0x00, 0xde, 0xac, 0xaf, 0xb9, 0xcf, 0xb4, 0xbb, /* 0x50-0x57 */ + 0xc0, 0xbd, 0xbf, 0xcc, 0xce, 0x00, 0xd9, 0xdb, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0xa2, 0xb6, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char mac_ukraine_page20[24] = { + 0x00, 0x00, 0x00, 0xd0, 0xd1, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0xd4, 0xd5, 0x00, 0x00, 0xd2, 0xd3, 0xd7, 0x00, /* 0x18-0x1f */ + 0xa0, 0x00, 0xa5, 0x00, 0x00, 0x00, 0xc9, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char mac_ukraine_page21[24] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xdc, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0xaa, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char mac_ukraine_page22[104] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc6, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0xc3, 0x00, 0x00, 0x00, 0xb0, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0xc5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0xad, 0x00, 0x00, 0x00, 0xb2, 0xb3, 0x00, 0x00, /* 0x60-0x67 */ +}; + +static int +mac_ukraine_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = mac_ukraine_page00[wc-0x00a0]; + else if (wc == 0x00f7) + c = 0xd6; + else if (wc == 0x0192) + c = 0xc4; + else if (wc >= 0x0400 && wc < 0x0498) + c = mac_ukraine_page04[wc-0x0400]; + else if (wc >= 0x2010 && wc < 0x2028) + c = mac_ukraine_page20[wc-0x2010]; + else if (wc >= 0x2110 && wc < 0x2128) + c = mac_ukraine_page21[wc-0x2110]; + else if (wc >= 0x2200 && wc < 0x2268) + c = mac_ukraine_page22[wc-0x2200]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/makefile.msc b/graf2d/win32gdk/gdk/src/iconv/makefile.msc new file mode 100644 index 0000000000000..f51f4d05f0ec8 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/makefile.msc @@ -0,0 +1,83 @@ +## Makefile for building the iconv dlls with Microsoft C +## Use: nmake -f makefile.msc + +## +## Used a writeup on the web to guide me: +## +## http://www.codeproject.com/Articles/302012/How-to-Build-libiconv-with-Microsoft-Visual-Studio +## + +ICONV_VER=1.3 + +################################################################ +# Flags +# See if debug is defined + +!IFNDEF DEBUG +# Full optimization: +OPTIMIZE = -O2 -MD +!ELSE +# Debugging: +OPTIMIZE = -Z7 -MDd +LINKDEBUG = /debug +!ENDIF + +# The CC flags depend if NMCXXFLAGS was passed in. If so, it overrides everything. + +# cl -? describes the options +#CC = cl -G5 -GF $(OPTIMIZE) -W3 -nologo +!if "$(NMCXXFLAGS)" == "" +CC = cl -GR $(OPTIMIZE) -W3 -nologo +!else +CC = cl -nologo $(NMCXXFLAGS) +!endif + +LDFLAGS = /link $(LINKDEBUG) + +# Check if nmake version is 8.xx or 9.xx +!if ([nmake /? 2>&1 | findstr /c:"Version 8\." > nul ] == 0) || \ + ([nmake /? 2>&1 | findstr /c:"Version 9\." > nul ] == 0) +MT_DLL = mt -nologo -manifest $@.manifest -outputresource:$@;2 +CLEAN_MT = -@erase /q $@.manifest >nul 2>&1 +!else +MT_DLL = +CLEAN_MT = +!endif + +# +# Basic C++ flags +# + +CFLAGS = -I. -DBUILDING_LIBICONV -DBUILDING_LIBCHARSET +#-DG_ENABLE_DEBUG -DHAVE_CONFIG_H -DGDK_VERSION=\"$(GTK_VER)\" +###################### + +all : \ + iconv-$(ICONV_VER).dll + +iconv_OBJECTS = \ + relocatable.obj \ + localcharset.obj \ + iconv.obj \ + +################ glib + +iconv-$(ICONV_VER).dll : $(iconv_OBJECTS) + $(CC) $(CFLAGS) -LD -Feiconv-$(ICONV_VER).dll $(iconv_OBJECTS) $(LIBICONV_LIBS) $(INTL_LIBS) user32.lib advapi32.lib wsock32.lib $(LDFLAGS) + $(MT_DLL) + $(CLEAN_MT) + +.c.obj : + $(CC) $(CFLAGS) -c $< + +################ other stuff + +clean:: + -@erase /q *.dll >nul 2>&1 + -@erase /q *.obj >nul 2>&1 + -@erase /q *.lib >nul 2>&1 + -@erase /q *.err >nul 2>&1 + -@erase /q *.res >nul 2>&1 + -@erase /q *.exp >nul 2>&1 + -@erase /q *.pdb >nul 2>&1 + -@erase /q *.ilk >nul 2>&1 diff --git a/graf2d/win32gdk/gdk/src/iconv/mulelao.h b/graf2d/win32gdk/gdk/src/iconv/mulelao.h new file mode 100644 index 0000000000000..abfb5cf0ee221 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/mulelao.h @@ -0,0 +1,96 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * MULELAO-1 + */ + +static const unsigned short mulelao_2uni[96] = { + /* 0xa0 */ + 0x00a0, 0x0e81, 0x0e82, 0xfffd, 0x0e84, 0xfffd, 0xfffd, 0x0e87, + 0x0e88, 0xfffd, 0x0e8a, 0xfffd, 0xfffd, 0x0e8d, 0xfffd, 0xfffd, + /* 0xb0 */ + 0xfffd, 0xfffd, 0xfffd, 0xfffd, 0x0e94, 0x0e95, 0x0e96, 0x0e97, + 0xfffd, 0x0e99, 0x0e9a, 0x0e9b, 0x0e9c, 0x0e9d, 0x0e9e, 0x0e9f, + /* 0xc0 */ + 0xfffd, 0x0ea1, 0x0ea2, 0x0ea3, 0xfffd, 0x0ea5, 0xfffd, 0x0ea7, + 0xfffd, 0xfffd, 0x0eaa, 0x0eab, 0xfffd, 0x0ead, 0x0eae, 0x0eaf, + /* 0xd0 */ + 0x0eb0, 0x0eb1, 0x0eb2, 0x0eb3, 0x0eb4, 0x0eb5, 0x0eb6, 0x0eb7, + 0x0eb8, 0x0eb9, 0xfffd, 0x0ebb, 0x0ebc, 0x0ebd, 0xfffd, 0xfffd, + /* 0xe0 */ + 0x0ec0, 0x0ec1, 0x0ec2, 0x0ec3, 0x0ec4, 0xfffd, 0x0ec6, 0xfffd, + 0x0ec8, 0x0ec9, 0x0eca, 0x0ecb, 0x0ecc, 0x0ecd, 0xfffd, 0xfffd, + /* 0xf0 */ + 0x0ed0, 0x0ed1, 0x0ed2, 0x0ed3, 0x0ed4, 0x0ed5, 0x0ed6, 0x0ed7, + 0x0ed8, 0x0ed9, 0xfffd, 0xfffd, 0x0edc, 0x0edd, 0xfffd, 0xfffd, +}; + +static int +mulelao_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0xa0) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = mulelao_2uni[c-0xa0]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char mulelao_page0e[96] = { + 0x00, 0xa1, 0xa2, 0x00, 0xa4, 0x00, 0x00, 0xa7, /* 0x80-0x87 */ + 0xa8, 0x00, 0xaa, 0x00, 0x00, 0xad, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x00, 0x00, 0xb4, 0xb5, 0xb6, 0xb7, /* 0x90-0x97 */ + 0x00, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, /* 0x98-0x9f */ + 0x00, 0xc1, 0xc2, 0xc3, 0x00, 0xc5, 0x00, 0xc7, /* 0xa0-0xa7 */ + 0x00, 0x00, 0xca, 0xcb, 0x00, 0xcd, 0xce, 0xcf, /* 0xa8-0xaf */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0xb0-0xb7 */ + 0xd8, 0xd9, 0x00, 0xdb, 0xdc, 0xdd, 0x00, 0x00, /* 0xb8-0xbf */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0x00, 0xe6, 0x00, /* 0xc0-0xc7 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0x00, 0x00, /* 0xc8-0xcf */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0xd0-0xd7 */ + 0xf8, 0xf9, 0x00, 0x00, 0xfc, 0xfd, 0x00, 0x00, /* 0xd8-0xdf */ +}; + +static int +mulelao_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x00a0) { + *r = wc; + return 1; + } + else if (wc == 0x00a0) + c = 0xa0; + else if (wc >= 0x0e80 && wc < 0x0ee0) + c = mulelao_page0e[wc-0x0e80]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/nextstep.h b/graf2d/win32gdk/gdk/src/iconv/nextstep.h new file mode 100644 index 0000000000000..ffe41b91700ae --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/nextstep.h @@ -0,0 +1,141 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * NEXTSTEP + */ + +static const unsigned short nextstep_2uni[128] = { + /* 0x80 */ + 0x00a0, 0x00c0, 0x00c1, 0x00c2, 0x00c3, 0x00c4, 0x00c5, 0x00c7, + 0x00c8, 0x00c9, 0x00ca, 0x00cb, 0x00cc, 0x00cd, 0x00ce, 0x00cf, + /* 0x90 */ + 0x00d0, 0x00d1, 0x00d2, 0x00d3, 0x00d4, 0x00d5, 0x00d6, 0x00d9, + 0x00da, 0x00db, 0x00dc, 0x00dd, 0x00de, 0x00b5, 0x00d7, 0x00f7, + /* 0xa0 */ + 0x00a9, 0x00a1, 0x00a2, 0x00a3, 0x2044, 0x00a5, 0x0192, 0x00a7, + 0x00a4, 0x2019, 0x201c, 0x00ab, 0x2039, 0x203a, 0xfb01, 0xfb02, + /* 0xb0 */ + 0x00ae, 0x2013, 0x2020, 0x2021, 0x00b7, 0x00a6, 0x00b6, 0x2022, + 0x201a, 0x201e, 0x201d, 0x00bb, 0x2026, 0x2030, 0x00ac, 0x00bf, + /* 0xc0 */ + 0x00b9, 0x02cb, 0x00b4, 0x02c6, 0x02dc, 0x00af, 0x02d8, 0x02d9, + 0x00a8, 0x00b2, 0x02da, 0x00b8, 0x00b3, 0x02dd, 0x02db, 0x02c7, + /* 0xd0 */ + 0x2014, 0x00b1, 0x00bc, 0x00bd, 0x00be, 0x00e0, 0x00e1, 0x00e2, + 0x00e3, 0x00e4, 0x00e5, 0x00e7, 0x00e8, 0x00e9, 0x00ea, 0x00eb, + /* 0xe0 */ + 0x00ec, 0x00c6, 0x00ed, 0x00aa, 0x00ee, 0x00ef, 0x00f0, 0x00f1, + 0x0141, 0x00d8, 0x0152, 0x00ba, 0x00f2, 0x00f3, 0x00f4, 0x00f5, + /* 0xf0 */ + 0x00f6, 0x00e6, 0x00f9, 0x00fa, 0x00fb, 0x0131, 0x00fc, 0x00fd, + 0x0142, 0x00f8, 0x0153, 0x00df, 0x00fe, 0x00ff, 0xfffd, 0xfffd, +}; + +static int +nextstep_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = nextstep_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char nextstep_page00[96] = { + 0x80, 0xa1, 0xa2, 0xa3, 0xa8, 0xa5, 0xb5, 0xa7, /* 0xa0-0xa7 */ + 0xc8, 0xa0, 0xe3, 0xab, 0xbe, 0x00, 0xb0, 0xc5, /* 0xa8-0xaf */ + 0x00, 0xd1, 0xc9, 0xcc, 0xc2, 0x9d, 0xb6, 0xb4, /* 0xb0-0xb7 */ + 0xcb, 0xc0, 0xeb, 0xbb, 0xd2, 0xd3, 0xd4, 0xbf, /* 0xb8-0xbf */ + 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0xe1, 0x87, /* 0xc0-0xc7 */ + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, /* 0xc8-0xcf */ + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x9e, /* 0xd0-0xd7 */ + 0xe9, 0x97, 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0xfb, /* 0xd8-0xdf */ + 0xd5, 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xf1, 0xdb, /* 0xe0-0xe7 */ + 0xdc, 0xdd, 0xde, 0xdf, 0xe0, 0xe2, 0xe4, 0xe5, /* 0xe8-0xef */ + 0xe6, 0xe7, 0xec, 0xed, 0xee, 0xef, 0xf0, 0x9f, /* 0xf0-0xf7 */ + 0xf9, 0xf2, 0xf3, 0xf4, 0xf6, 0xf7, 0xfc, 0xfd, /* 0xf8-0xff */ +}; +static const unsigned char nextstep_page01[104] = { + 0x00, 0xf5, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0xe8, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0xea, 0xfa, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0xa6, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ +}; +static const unsigned char nextstep_page02[32] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc3, 0xcf, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0xc1, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0xc6, 0xc7, 0xca, 0xce, 0xc4, 0xcd, 0x00, 0x00, /* 0xd8-0xdf */ +}; +static const unsigned char nextstep_page20[56] = { + 0x00, 0x00, 0x00, 0xb1, 0xd0, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0xa9, 0xb8, 0x00, 0xaa, 0xba, 0xb9, 0x00, /* 0x18-0x1f */ + 0xb2, 0xb3, 0xb7, 0x00, 0x00, 0x00, 0xbc, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0xbd, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0xac, 0xad, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0xa4, 0x00, 0x00, 0x00, /* 0x40-0x47 */ +}; +static const unsigned char nextstep_pagefb[8] = { + 0x00, 0xae, 0xaf, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ +}; + +static int +nextstep_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x0100) + c = nextstep_page00[wc-0x00a0]; + else if (wc >= 0x0130 && wc < 0x0198) + c = nextstep_page01[wc-0x0130]; + else if (wc >= 0x02c0 && wc < 0x02e0) + c = nextstep_page02[wc-0x02c0]; + else if (wc >= 0x2010 && wc < 0x2048) + c = nextstep_page20[wc-0x2010]; + else if (wc >= 0xfb00 && wc < 0xfb08) + c = nextstep_pagefb[wc-0xfb00]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/pt154.h b/graf2d/win32gdk/gdk/src/iconv/pt154.h new file mode 100644 index 0000000000000..36a5d84fc2495 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/pt154.h @@ -0,0 +1,118 @@ +/* + * Copyright (C) 1999-2005 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * PT154 + */ + +static const unsigned short pt154_2uni[64] = { + /* 0x80 */ + 0x0496, 0x0492, 0x04ee, 0x0493, 0x201e, 0x2026, 0x04b6, 0x04ae, + 0x04b2, 0x04af, 0x04a0, 0x04e2, 0x04a2, 0x049a, 0x04ba, 0x04b8, + /* 0x90 */ + 0x0497, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0x04b3, 0x04b7, 0x04a1, 0x04e3, 0x04a3, 0x049b, 0x04bb, 0x04b9, + /* 0xa0 */ + 0x00a0, 0x040e, 0x045e, 0x0408, 0x04e8, 0x0498, 0x04b0, 0x00a7, + 0x0401, 0x00a9, 0x04d8, 0x00ab, 0x00ac, 0x04ef, 0x00ae, 0x049c, + /* 0xb0 */ + 0x00b0, 0x04b1, 0x0406, 0x0456, 0x0499, 0x04e9, 0x00b6, 0x00b7, + 0x0451, 0x2116, 0x04d9, 0x00bb, 0x0458, 0x04aa, 0x04ab, 0x049d, +}; + +static int +pt154_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) + *pwc = (ucs4_t) c; + else if (c >= 0xc0) + *pwc = (ucs4_t) c + 0x0350; + else + *pwc = (ucs4_t) pt154_2uni[c-0x80]; + return 1; +} + +static const unsigned char pt154_page00[32] = { + 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa7, /* 0xa0-0xa7 */ + 0x00, 0xa9, 0x00, 0xab, 0xac, 0x00, 0xae, 0x00, /* 0xa8-0xaf */ + 0xb0, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xbb, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ +}; +static const unsigned char pt154_page04[240] = { + 0x00, 0xa8, 0x00, 0x00, 0x00, 0x00, 0xb2, 0x00, /* 0x00-0x07 */ + 0xa3, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa1, 0x00, /* 0x08-0x0f */ + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x10-0x17 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x18-0x1f */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0x20-0x27 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xdf, /* 0x28-0x2f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x30-0x37 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x38-0x3f */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0x40-0x47 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xff, /* 0x48-0x4f */ + 0x00, 0xb8, 0x00, 0x00, 0x00, 0x00, 0xb3, 0x00, /* 0x50-0x57 */ + 0xbc, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa2, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x81, 0x83, 0x00, 0x00, 0x80, 0x90, /* 0x90-0x97 */ + 0xa5, 0xb4, 0x8d, 0x9d, 0xaf, 0xbf, 0x00, 0x00, /* 0x98-0x9f */ + 0x8a, 0x9a, 0x8c, 0x9c, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0xbd, 0xbe, 0x00, 0x00, 0x87, 0x89, /* 0xa8-0xaf */ + 0xa6, 0xb1, 0x88, 0x98, 0x00, 0x00, 0x86, 0x99, /* 0xb0-0xb7 */ + 0x8f, 0x9f, 0x8e, 0x9e, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0xaa, 0xba, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x00, 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0xa4, 0xb5, 0x00, 0x00, 0x00, 0x00, 0x82, 0xad, /* 0xe8-0xef */ +}; +static const unsigned char pt154_page20[24] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x00, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ +}; + +static int +pt154_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = pt154_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x04f0) + c = pt154_page04[wc-0x0400]; + else if (wc >= 0x2010 && wc < 0x2028) + c = pt154_page20[wc-0x2010]; + else if (wc == 0x2116) + c = 0xb9; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/relocatable.c b/graf2d/win32gdk/gdk/src/iconv/relocatable.c new file mode 100644 index 0000000000000..bfbaaaca22d72 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/relocatable.c @@ -0,0 +1,493 @@ +/* Provide relocatable packages. + Copyright (C) 2003-2006, 2008 Free Software Foundation, Inc. + Written by Bruno Haible <bruno@clisp.org>, 2003. + + This program is free software; you can redistribute it and/or modify it + under the terms of the GNU General Public License as published + by the Free Software Foundation; either version 3, or (at your option) + any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU General Public + License along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, + USA. */ + + +/* Tell glibc's <stdio.h> to provide a prototype for getline(). + This must come before <config.h> because <config.h> may include + <features.h>, and once <features.h> has been included, it's too late. */ +#ifndef _GNU_SOURCE +# define _GNU_SOURCE 1 +#endif + +#include <config.h> + +/* Specification. */ +#include "relocatable.h" + +#if ENABLE_RELOCATABLE + +#include <stddef.h> +#include <stdio.h> +#include <stdlib.h> +#include <string.h> + +#ifdef NO_XMALLOC +# define xmalloc malloc +#else +# include "xalloc.h" +#endif + +#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ +# define WIN32_LEAN_AND_MEAN +# include <windows.h> +#endif + +#if DEPENDS_ON_LIBCHARSET +# include <libcharset.h> +#endif +#if DEPENDS_ON_LIBICONV && HAVE_ICONV +# include <iconv.h> +#endif +#if DEPENDS_ON_LIBINTL && ENABLE_NLS +# include <libintl.h> +#endif + +/* Faked cheap 'bool'. */ +#undef bool +#undef false +#undef true +#define bool int +#define false 0 +#define true 1 + +/* Pathname support. + ISSLASH(C) tests whether C is a directory separator character. + IS_PATH_WITH_DIR(P) tests whether P contains a directory specification. + */ +#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__ + /* Win32, Cygwin, OS/2, DOS */ +# define ISSLASH(C) ((C) == '/' || (C) == '\\') +# define HAS_DEVICE(P) \ + ((((P)[0] >= 'A' && (P)[0] <= 'Z') || ((P)[0] >= 'a' && (P)[0] <= 'z')) \ + && (P)[1] == ':') +# define IS_PATH_WITH_DIR(P) \ + (strchr (P, '/') != NULL || strchr (P, '\\') != NULL || HAS_DEVICE (P)) +# define FILE_SYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0) +#else + /* Unix */ +# define ISSLASH(C) ((C) == '/') +# define IS_PATH_WITH_DIR(P) (strchr (P, '/') != NULL) +# define FILE_SYSTEM_PREFIX_LEN(P) 0 +#endif + +/* Original installation prefix. */ +static char *orig_prefix; +static size_t orig_prefix_len; +/* Current installation prefix. */ +static char *curr_prefix; +static size_t curr_prefix_len; +/* These prefixes do not end in a slash. Anything that will be concatenated + to them must start with a slash. */ + +/* Sets the original and the current installation prefix of this module. + Relocation simply replaces a pathname starting with the original prefix + by the corresponding pathname with the current prefix instead. Both + prefixes should be directory names without trailing slash (i.e. use "" + instead of "/"). */ +static void +set_this_relocation_prefix (const char *orig_prefix_arg, + const char *curr_prefix_arg) +{ + if (orig_prefix_arg != NULL && curr_prefix_arg != NULL + /* Optimization: if orig_prefix and curr_prefix are equal, the + relocation is a nop. */ + && strcmp (orig_prefix_arg, curr_prefix_arg) != 0) + { + /* Duplicate the argument strings. */ + char *memory; + + orig_prefix_len = strlen (orig_prefix_arg); + curr_prefix_len = strlen (curr_prefix_arg); + memory = (char *) xmalloc (orig_prefix_len + 1 + curr_prefix_len + 1); +#ifdef NO_XMALLOC + if (memory != NULL) +#endif + { + memcpy (memory, orig_prefix_arg, orig_prefix_len + 1); + orig_prefix = memory; + memory += orig_prefix_len + 1; + memcpy (memory, curr_prefix_arg, curr_prefix_len + 1); + curr_prefix = memory; + return; + } + } + orig_prefix = NULL; + curr_prefix = NULL; + /* Don't worry about wasted memory here - this function is usually only + called once. */ +} + +/* Sets the original and the current installation prefix of the package. + Relocation simply replaces a pathname starting with the original prefix + by the corresponding pathname with the current prefix instead. Both + prefixes should be directory names without trailing slash (i.e. use "" + instead of "/"). */ +void +set_relocation_prefix (const char *orig_prefix_arg, const char *curr_prefix_arg) +{ + set_this_relocation_prefix (orig_prefix_arg, curr_prefix_arg); + + /* Now notify all dependent libraries. */ +#if DEPENDS_ON_LIBCHARSET + libcharset_set_relocation_prefix (orig_prefix_arg, curr_prefix_arg); +#endif +#if DEPENDS_ON_LIBICONV && HAVE_ICONV && _LIBICONV_VERSION >= 0x0109 + libiconv_set_relocation_prefix (orig_prefix_arg, curr_prefix_arg); +#endif +#if DEPENDS_ON_LIBINTL && ENABLE_NLS && defined libintl_set_relocation_prefix + libintl_set_relocation_prefix (orig_prefix_arg, curr_prefix_arg); +#endif +} + +#if !defined IN_LIBRARY || (defined PIC && defined INSTALLDIR) + +/* Convenience function: + Computes the current installation prefix, based on the original + installation prefix, the original installation directory of a particular + file, and the current pathname of this file. + Returns it, freshly allocated. Returns NULL upon failure. */ +#ifdef IN_LIBRARY +#define compute_curr_prefix local_compute_curr_prefix +static +#endif +char * +compute_curr_prefix (const char *orig_installprefix, + const char *orig_installdir, + const char *curr_pathname) +{ + char *curr_installdir; + const char *rel_installdir; + + if (curr_pathname == NULL) + return NULL; + + /* Determine the relative installation directory, relative to the prefix. + This is simply the difference between orig_installprefix and + orig_installdir. */ + if (strncmp (orig_installprefix, orig_installdir, strlen (orig_installprefix)) + != 0) + /* Shouldn't happen - nothing should be installed outside $(prefix). */ + return NULL; + rel_installdir = orig_installdir + strlen (orig_installprefix); + + /* Determine the current installation directory. */ + { + const char *p_base = curr_pathname + FILE_SYSTEM_PREFIX_LEN (curr_pathname); + const char *p = curr_pathname + strlen (curr_pathname); + char *q; + + while (p > p_base) + { + p--; + if (ISSLASH (*p)) + break; + } + + q = (char *) xmalloc (p - curr_pathname + 1); +#ifdef NO_XMALLOC + if (q == NULL) + return NULL; +#endif + memcpy (q, curr_pathname, p - curr_pathname); + q[p - curr_pathname] = '\0'; + curr_installdir = q; + } + + /* Compute the current installation prefix by removing the trailing + rel_installdir from it. */ + { + const char *rp = rel_installdir + strlen (rel_installdir); + const char *cp = curr_installdir + strlen (curr_installdir); + const char *cp_base = + curr_installdir + FILE_SYSTEM_PREFIX_LEN (curr_installdir); + + while (rp > rel_installdir && cp > cp_base) + { + bool same = false; + const char *rpi = rp; + const char *cpi = cp; + + while (rpi > rel_installdir && cpi > cp_base) + { + rpi--; + cpi--; + if (ISSLASH (*rpi) || ISSLASH (*cpi)) + { + if (ISSLASH (*rpi) && ISSLASH (*cpi)) + same = true; + break; + } + /* Do case-insensitive comparison if the filesystem is always or + often case-insensitive. It's better to accept the comparison + if the difference is only in case, rather than to fail. */ +#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__ + /* Win32, Cygwin, OS/2, DOS - case insignificant filesystem */ + if ((*rpi >= 'a' && *rpi <= 'z' ? *rpi - 'a' + 'A' : *rpi) + != (*cpi >= 'a' && *cpi <= 'z' ? *cpi - 'a' + 'A' : *cpi)) + break; +#else + if (*rpi != *cpi) + break; +#endif + } + if (!same) + break; + /* The last pathname component was the same. opi and cpi now point + to the slash before it. */ + rp = rpi; + cp = cpi; + } + + if (rp > rel_installdir) + { + /* Unexpected: The curr_installdir does not end with rel_installdir. */ + free (curr_installdir); + return NULL; + } + + { + size_t curr_prefix_len = cp - curr_installdir; + char *curr_prefix; + + curr_prefix = (char *) xmalloc (curr_prefix_len + 1); +#ifdef NO_XMALLOC + if (curr_prefix == NULL) + { + free (curr_installdir); + return NULL; + } +#endif + memcpy (curr_prefix, curr_installdir, curr_prefix_len); + curr_prefix[curr_prefix_len] = '\0'; + + free (curr_installdir); + + return curr_prefix; + } + } +} + +#endif /* !IN_LIBRARY || PIC */ + +#if defined PIC && defined INSTALLDIR + +/* Full pathname of shared library, or NULL. */ +static char *shared_library_fullname; + +#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ + +/* Determine the full pathname of the shared library when it is loaded. */ + +BOOL WINAPI +DllMain (HINSTANCE module_handle, DWORD event, LPVOID reserved) +{ + (void) reserved; + + if (event == DLL_PROCESS_ATTACH) + { + /* The DLL is being loaded into an application's address range. */ + static char location[MAX_PATH]; + + if (!GetModuleFileName (module_handle, location, sizeof (location))) + /* Shouldn't happen. */ + return FALSE; + + if (!IS_PATH_WITH_DIR (location)) + /* Shouldn't happen. */ + return FALSE; + + { +#if defined __CYGWIN__ + /* On Cygwin, we need to convert paths coming from Win32 system calls + to the Unix-like slashified notation. */ + static char location_as_posix_path[2 * MAX_PATH]; + /* There's no error return defined for cygwin_conv_to_posix_path. + See cygwin-api/func-cygwin-conv-to-posix-path.html. + Does it overflow the buffer of expected size MAX_PATH or does it + truncate the path? I don't know. Let's catch both. */ + cygwin_conv_to_posix_path (location, location_as_posix_path); + location_as_posix_path[MAX_PATH - 1] = '\0'; + if (strlen (location_as_posix_path) >= MAX_PATH - 1) + /* A sign of buffer overflow or path truncation. */ + return FALSE; + shared_library_fullname = strdup (location_as_posix_path); +#else + shared_library_fullname = strdup (location); +#endif + } + } + + return TRUE; +} + +#else /* Unix except Cygwin */ + +static void +find_shared_library_fullname () +{ +#if defined __linux__ && __GLIBC__ >= 2 + /* Linux has /proc/self/maps. glibc 2 has the getline() function. */ + FILE *fp; + + /* Open the current process' maps file. It describes one VMA per line. */ + fp = fopen ("/proc/self/maps", "r"); + if (fp) + { + unsigned long address = (unsigned long) &find_shared_library_fullname; + for (;;) + { + unsigned long start, end; + int c; + + if (fscanf (fp, "%lx-%lx", &start, &end) != 2) + break; + if (address >= start && address <= end - 1) + { + /* Found it. Now see if this line contains a filename. */ + while (c = getc (fp), c != EOF && c != '\n' && c != '/') + continue; + if (c == '/') + { + size_t size; + int len; + + ungetc (c, fp); + shared_library_fullname = NULL; size = 0; + len = getline (&shared_library_fullname, &size, fp); + if (len >= 0) + { + /* Success: filled shared_library_fullname. */ + if (len > 0 && shared_library_fullname[len - 1] == '\n') + shared_library_fullname[len - 1] = '\0'; + } + } + break; + } + while (c = getc (fp), c != EOF && c != '\n') + continue; + } + fclose (fp); + } +#endif +} + +#endif /* (WIN32 or Cygwin) / (Unix except Cygwin) */ + +/* Return the full pathname of the current shared library. + Return NULL if unknown. + Guaranteed to work only on Linux, Cygwin and Woe32. */ +static char * +get_shared_library_fullname () +{ +#if !(defined _WIN32 || defined __WIN32__ || defined __CYGWIN__) + static bool tried_find_shared_library_fullname; + if (!tried_find_shared_library_fullname) + { + find_shared_library_fullname (); + tried_find_shared_library_fullname = true; + } +#endif + return shared_library_fullname; +} + +#endif /* PIC */ + +/* Returns the pathname, relocated according to the current installation + directory. + The returned string is either PATHNAME unmodified or a freshly allocated + string that you can free with free() after casting it to 'char *'. */ +const char * +relocate (const char *pathname) +{ +#if defined PIC && defined INSTALLDIR + static int initialized; + + /* Initialization code for a shared library. */ + if (!initialized) + { + /* At this point, orig_prefix and curr_prefix likely have already been + set through the main program's set_program_name_and_installdir + function. This is sufficient in the case that the library has + initially been installed in the same orig_prefix. But we can do + better, to also cover the cases that 1. it has been installed + in a different prefix before being moved to orig_prefix and (later) + to curr_prefix, 2. unlike the program, it has not moved away from + orig_prefix. */ + const char *orig_installprefix = INSTALLPREFIX; + const char *orig_installdir = INSTALLDIR; + char *curr_prefix_better; + + curr_prefix_better = + compute_curr_prefix (orig_installprefix, orig_installdir, + get_shared_library_fullname ()); + + set_relocation_prefix (orig_installprefix, + curr_prefix_better != NULL + ? curr_prefix_better + : curr_prefix); + + if (curr_prefix_better != NULL) + free (curr_prefix_better); + + initialized = 1; + } +#endif + + /* Note: It is not necessary to perform case insensitive comparison here, + even for DOS-like filesystems, because the pathname argument was + typically created from the same Makefile variable as orig_prefix came + from. */ + if (orig_prefix != NULL && curr_prefix != NULL + && strncmp (pathname, orig_prefix, orig_prefix_len) == 0) + { + if (pathname[orig_prefix_len] == '\0') + { + /* pathname equals orig_prefix. */ + char *result = (char *) xmalloc (strlen (curr_prefix) + 1); + +#ifdef NO_XMALLOC + if (result != NULL) +#endif + { + strcpy (result, curr_prefix); + return result; + } + } + else if (ISSLASH (pathname[orig_prefix_len])) + { + /* pathname starts with orig_prefix. */ + const char *pathname_tail = &pathname[orig_prefix_len]; + char *result = + (char *) xmalloc (curr_prefix_len + strlen (pathname_tail) + 1); + +#ifdef NO_XMALLOC + if (result != NULL) +#endif + { + memcpy (result, curr_prefix, curr_prefix_len); + strcpy (result + curr_prefix_len, pathname_tail); + return result; + } + } + } + /* Nothing to relocate. */ + return pathname; +} + +#endif diff --git a/graf2d/win32gdk/gdk/src/iconv/relocatable.h b/graf2d/win32gdk/gdk/src/iconv/relocatable.h new file mode 100644 index 0000000000000..9d975b9d88dbc --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/relocatable.h @@ -0,0 +1,83 @@ +/* Provide relocatable packages. + Copyright (C) 2003, 2005, 2008 Free Software Foundation, Inc. + Written by Bruno Haible <bruno@clisp.org>, 2003. + + This program is free software; you can redistribute it and/or modify it + under the terms of the GNU General Public License as published + by the Free Software Foundation; either version 3, or (at your option) + any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU General Public + License along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, + USA. */ + +#ifndef _RELOCATABLE_H +#define _RELOCATABLE_H + +#ifdef __cplusplus +extern "C" { +#endif + + +/* This can be enabled through the configure --enable-relocatable option. */ +#if ENABLE_RELOCATABLE + +/* When building a DLL, we must export some functions. Note that because + this is a private .h file, we don't need to use __declspec(dllimport) + in any case. */ +#if HAVE_VISIBILITY && BUILDING_DLL +# define RELOCATABLE_DLL_EXPORTED __attribute__((__visibility__("default"))) +#elif defined _MSC_VER && BUILDING_DLL +# define RELOCATABLE_DLL_EXPORTED __declspec(dllexport) +#else +# define RELOCATABLE_DLL_EXPORTED +#endif + +/* Sets the original and the current installation prefix of the package. + Relocation simply replaces a pathname starting with the original prefix + by the corresponding pathname with the current prefix instead. Both + prefixes should be directory names without trailing slash (i.e. use "" + instead of "/"). */ +extern RELOCATABLE_DLL_EXPORTED void + set_relocation_prefix (const char *orig_prefix, + const char *curr_prefix); + +/* Returns the pathname, relocated according to the current installation + directory. + The returned string is either PATHNAME unmodified or a freshly allocated + string that you can free with free() after casting it to 'char *'. */ +extern const char * relocate (const char *pathname); + +/* Memory management: relocate() potentially allocates memory, because it has + to construct a fresh pathname. If this is a problem because your program + calls relocate() frequently, think about caching the result. Or free the + return value if it was different from the argument pathname. */ + +/* Convenience function: + Computes the current installation prefix, based on the original + installation prefix, the original installation directory of a particular + file, and the current pathname of this file. + Returns it, freshly allocated. Returns NULL upon failure. */ +extern char * compute_curr_prefix (const char *orig_installprefix, + const char *orig_installdir, + const char *curr_pathname); + +#else + +/* By default, we use the hardwired pathnames. */ +#define relocate(pathname) (pathname) + +#endif + + +#ifdef __cplusplus +} +#endif + +#endif /* _RELOCATABLE_H */ diff --git a/graf2d/win32gdk/gdk/src/iconv/riscos1.h b/graf2d/win32gdk/gdk/src/iconv/riscos1.h new file mode 100644 index 0000000000000..2ebc751341989 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/riscos1.h @@ -0,0 +1,96 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * RISCOS-LATIN1 + */ + +static const unsigned short riscos1_2uni[32] = { + /* 0x80 */ + 0x221a, 0x0174, 0x0175, 0x0083, 0x2573, 0x0176, 0x0177, 0x0087, + 0x21e6, 0x21e8, 0x21e9, 0x21e7, 0x2026, 0x2122, 0x2030, 0x2022, + /* 0x90 */ + 0x2018, 0x2019, 0x2039, 0x203a, 0x201c, 0x201d, 0x201e, 0x2013, + 0x2014, 0x2212, 0x0152, 0x0153, 0x2020, 0x2021, 0xfb01, 0xfb02, +}; + +static int +riscos1_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c >= 0x80 && c < 0xa0) + *pwc = (ucs4_t) riscos1_2uni[c-0x80]; + else + *pwc = (ucs4_t) c; + return 1; +} + +static const unsigned char riscos1_page01[40] = { + 0x00, 0x00, 0x9a, 0x9b, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x81, 0x82, 0x85, 0x86, /* 0x70-0x77 */ +}; +static const unsigned char riscos1_page20[48] = { + 0x00, 0x00, 0x00, 0x97, 0x98, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x90, 0x91, 0x00, 0x00, 0x94, 0x95, 0x96, 0x00, /* 0x18-0x1f */ + 0x9c, 0x9d, 0x8f, 0x00, 0x00, 0x00, 0x8c, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x8e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x92, 0x93, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; +static const unsigned char riscos1_page21[16] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x88, 0x8b, /* 0xe0-0xe7 */ + 0x89, 0x8a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ +}; +static const unsigned char riscos1_page22[16] = { + 0x00, 0x00, 0x99, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ +}; + +static int +riscos1_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080 || wc == 0x0083 || wc == 0x0087 || (wc >= 0x00a0 && wc < 0x0100)) { + *r = wc; + return 1; + } + else if (wc >= 0x0150 && wc < 0x0178) + c = riscos1_page01[wc-0x0150]; + else if (wc >= 0x2010 && wc < 0x2040) + c = riscos1_page20[wc-0x2010]; + else if (wc == 0x2122) + c = 0x8d; + else if (wc >= 0x21e0 && wc < 0x21f0) + c = riscos1_page21[wc-0x21e0]; + else if (wc >= 0x2210 && wc < 0x2220) + c = riscos1_page22[wc-0x2210]; + else if (wc == 0x2573) + c = 0x84; + else if (wc >= 0xfb01 && wc < 0xfb03) + c = wc-0xfa63; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/rk1048.h b/graf2d/win32gdk/gdk/src/iconv/rk1048.h new file mode 100644 index 0000000000000..0e1fde897134f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/rk1048.h @@ -0,0 +1,145 @@ +/* + * Copyright (C) 1999-2007 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * RK1048 + */ + +static const unsigned short rk1048_2uni[128] = { + /* 0x80 */ + 0x0402, 0x0403, 0x201a, 0x0453, 0x201e, 0x2026, 0x2020, 0x2021, + 0x20ac, 0x2030, 0x0409, 0x2039, 0x040a, 0x049a, 0x04ba, 0x040f, + /* 0x90 */ + 0x0452, 0x2018, 0x2019, 0x201c, 0x201d, 0x2022, 0x2013, 0x2014, + 0xfffd, 0x2122, 0x0459, 0x203a, 0x045a, 0x049b, 0x04bb, 0x045f, + /* 0xa0 */ + 0x00a0, 0x04b0, 0x04b1, 0x04d8, 0x00a4, 0x04e8, 0x00a6, 0x00a7, + 0x0401, 0x00a9, 0x0492, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x04ae, + /* 0xb0 */ + 0x00b0, 0x00b1, 0x0406, 0x0456, 0x04e9, 0x00b5, 0x00b6, 0x00b7, + 0x0451, 0x2116, 0x0493, 0x00bb, 0x04d9, 0x04a2, 0x04a3, 0x04af, + /* 0xc0 */ + 0x0410, 0x0411, 0x0412, 0x0413, 0x0414, 0x0415, 0x0416, 0x0417, + 0x0418, 0x0419, 0x041a, 0x041b, 0x041c, 0x041d, 0x041e, 0x041f, + /* 0xd0 */ + 0x0420, 0x0421, 0x0422, 0x0423, 0x0424, 0x0425, 0x0426, 0x0427, + 0x0428, 0x0429, 0x042a, 0x042b, 0x042c, 0x042d, 0x042e, 0x042f, + /* 0xe0 */ + 0x0430, 0x0431, 0x0432, 0x0433, 0x0434, 0x0435, 0x0436, 0x0437, + 0x0438, 0x0439, 0x043a, 0x043b, 0x043c, 0x043d, 0x043e, 0x043f, + /* 0xf0 */ + 0x0440, 0x0441, 0x0442, 0x0443, 0x0444, 0x0445, 0x0446, 0x0447, + 0x0448, 0x0449, 0x044a, 0x044b, 0x044c, 0x044d, 0x044e, 0x044f, +}; + +static int +rk1048_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else { + unsigned short wc = rk1048_2uni[c-0x80]; + if (wc != 0xfffd) { + *pwc = (ucs4_t) wc; + return 1; + } + } + return RET_ILSEQ; +} + +static const unsigned char rk1048_page00[32] = { + 0xa0, 0x00, 0x00, 0x00, 0xa4, 0x00, 0xa6, 0xa7, /* 0xa0-0xa7 */ + 0x00, 0xa9, 0x00, 0xab, 0xac, 0xad, 0xae, 0x00, /* 0xa8-0xaf */ + 0xb0, 0xb1, 0x00, 0x00, 0x00, 0xb5, 0xb6, 0xb7, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0xbb, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ +}; +static const unsigned char rk1048_page04[240] = { + 0x00, 0xa8, 0x80, 0x81, 0x00, 0x00, 0xb2, 0x00, /* 0x00-0x07 */ + 0x00, 0x8a, 0x8c, 0x00, 0x00, 0x00, 0x00, 0x8f, /* 0x08-0x0f */ + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, /* 0x10-0x17 */ + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, /* 0x18-0x1f */ + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, /* 0x20-0x27 */ + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xdf, /* 0x28-0x2f */ + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, /* 0x30-0x37 */ + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, /* 0x38-0x3f */ + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, /* 0x40-0x47 */ + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xff, /* 0x48-0x4f */ + 0x00, 0xb8, 0x90, 0x83, 0x00, 0x00, 0xb3, 0x00, /* 0x50-0x57 */ + 0x00, 0x9a, 0x9c, 0x00, 0x00, 0x00, 0x00, 0x9f, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0xaa, 0xba, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x8d, 0x9d, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0x00, 0x00, 0xbd, 0xbe, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xaf, 0xbf, /* 0xa8-0xaf */ + 0xa1, 0xa2, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x8e, 0x9e, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd0-0xd7 */ + 0xa3, 0xbc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0xa5, 0xb4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ +}; +static const unsigned char rk1048_page20[48] = { + 0x00, 0x00, 0x00, 0x96, 0x97, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x91, 0x92, 0x82, 0x00, 0x93, 0x94, 0x84, 0x00, /* 0x18-0x1f */ + 0x86, 0x87, 0x95, 0x00, 0x00, 0x00, 0x85, 0x00, /* 0x20-0x27 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x89, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x8b, 0x9b, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ +}; +static const unsigned char rk1048_page21[24] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb9, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x99, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; + +static int +rk1048_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x00c0) + c = rk1048_page00[wc-0x00a0]; + else if (wc >= 0x0400 && wc < 0x04f0) + c = rk1048_page04[wc-0x0400]; + else if (wc >= 0x2010 && wc < 0x2040) + c = rk1048_page20[wc-0x2010]; + else if (wc == 0x20ac) + c = 0x88; + else if (wc >= 0x2110 && wc < 0x2128) + c = rk1048_page21[wc-0x2110]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/shift_jisx0213.h b/graf2d/win32gdk/gdk/src/iconv/shift_jisx0213.h new file mode 100644 index 0000000000000..05f00b00b00a0 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/shift_jisx0213.h @@ -0,0 +1,310 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * SHIFT_JISX0213 + */ + +/* The structure of Shift_JISX0213 is as follows: + + 0x00..0x7F: ISO646-JP, an ASCII variant + + 0x{A1..DF}: JISX0201 Katakana. + + 0x{81..9F,E0..EF}{40..7E,80..FC}: JISX0213 plane 1. + + 0x{F0..FC}{40..7E,80..FC}: JISX0213 plane 2, with irregular row mapping. + + Note that some JISX0213 characters are not contained in Unicode 3.2 + and are therefore best represented as sequences of Unicode characters. +*/ + +#include "jisx0213.h" +#include "flushwc.h" + +static int +shift_jisx0213_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + ucs4_t last_wc = conv->istate; + if (last_wc) { + /* Output the buffered character. */ + conv->istate = 0; + *pwc = last_wc; + return 0; /* Don't advance the input pointer. */ + } else { + unsigned char c = *s; + if (c < 0x80) { + /* Plain ISO646-JP character. */ + if (c == 0x5c) + *pwc = (ucs4_t) 0x00a5; + else if (c == 0x7e) + *pwc = (ucs4_t) 0x203e; + else + *pwc = (ucs4_t) c; + return 1; + } else if (c >= 0xa1 && c <= 0xdf) { + *pwc = c + 0xfec0; + return 1; + } else { + if ((c >= 0x81 && c <= 0x9f) || (c >= 0xe0 && c <= 0xfc)) { + /* Two byte character. */ + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x40 && c2 <= 0x7e) || (c2 >= 0x80 && c2 <= 0xfc)) { + unsigned int c1; + ucs4_t wc; + /* Convert to row and column. */ + if (c < 0xe0) + c -= 0x81; + else + c -= 0xc1; + if (c2 < 0x80) + c2 -= 0x40; + else + c2 -= 0x41; + /* Now 0 <= c <= 0x3b, 0 <= c2 <= 0xbb. */ + c1 = 2 * c; + if (c2 >= 0x5e) + c2 -= 0x5e, c1++; + c2 += 0x21; + if (c1 >= 0x5e) { + /* Handling of JISX 0213 plane 2 rows. */ + if (c1 >= 0x67) + c1 += 230; + else if (c1 >= 0x63 || c1 == 0x5f) + c1 += 168; + else + c1 += 162; + } + wc = jisx0213_to_ucs4(0x121+c1,c2); + if (wc) { + if (wc < 0x80) { + /* It's a combining character. */ + ucs4_t wc1 = jisx0213_to_ucs_combining[wc - 1][0]; + ucs4_t wc2 = jisx0213_to_ucs_combining[wc - 1][1]; + /* We cannot output two Unicode characters at once. So, + output the first character and buffer the second one. */ + *pwc = wc1; + conv->istate = wc2; + } else + *pwc = wc; + return 2; + } + } + } else + return RET_TOOFEW(0); + } + return RET_ILSEQ; + } + } +} + +#define shift_jisx0213_flushwc normal_flushwc + +/* Composition tables for each of the relevant combining characters. */ +static const struct { unsigned short base; unsigned short composed; } shift_jisx0213_comp_table_data[] = { +#define shift_jisx0213_comp_table02e5_idx 0 +#define shift_jisx0213_comp_table02e5_len 1 + { 0x8684, 0x8685 }, /* 0x12B65 = 0x12B64 U+02E5 */ +#define shift_jisx0213_comp_table02e9_idx (shift_jisx0213_comp_table02e5_idx+shift_jisx0213_comp_table02e5_len) +#define shift_jisx0213_comp_table02e9_len 1 + { 0x8680, 0x8686 }, /* 0x12B66 = 0x12B60 U+02E9 */ +#define shift_jisx0213_comp_table0300_idx (shift_jisx0213_comp_table02e9_idx+shift_jisx0213_comp_table02e9_len) +#define shift_jisx0213_comp_table0300_len 5 + { 0x857b, 0x8663 }, /* 0x12B44 = 0x1295C U+0300 */ + { 0x8657, 0x8667 }, /* 0x12B48 = 0x12B38 U+0300 */ + { 0x8656, 0x8669 }, /* 0x12B4A = 0x12B37 U+0300 */ + { 0x864f, 0x866b }, /* 0x12B4C = 0x12B30 U+0300 */ + { 0x8662, 0x866d }, /* 0x12B4E = 0x12B43 U+0300 */ +#define shift_jisx0213_comp_table0301_idx (shift_jisx0213_comp_table0300_idx+shift_jisx0213_comp_table0300_len) +#define shift_jisx0213_comp_table0301_len 4 + { 0x8657, 0x8668 }, /* 0x12B49 = 0x12B38 U+0301 */ + { 0x8656, 0x866a }, /* 0x12B4B = 0x12B37 U+0301 */ + { 0x864f, 0x866c }, /* 0x12B4D = 0x12B30 U+0301 */ + { 0x8662, 0x866e }, /* 0x12B4F = 0x12B43 U+0301 */ +#define shift_jisx0213_comp_table309a_idx (shift_jisx0213_comp_table0301_idx+shift_jisx0213_comp_table0301_len) +#define shift_jisx0213_comp_table309a_len 14 + { 0x82a9, 0x82f5 }, /* 0x12477 = 0x1242B U+309A */ + { 0x82ab, 0x82f6 }, /* 0x12478 = 0x1242D U+309A */ + { 0x82ad, 0x82f7 }, /* 0x12479 = 0x1242F U+309A */ + { 0x82af, 0x82f8 }, /* 0x1247A = 0x12431 U+309A */ + { 0x82b1, 0x82f9 }, /* 0x1247B = 0x12433 U+309A */ + { 0x834a, 0x8397 }, /* 0x12577 = 0x1252B U+309A */ + { 0x834c, 0x8398 }, /* 0x12578 = 0x1252D U+309A */ + { 0x834e, 0x8399 }, /* 0x12579 = 0x1252F U+309A */ + { 0x8350, 0x839a }, /* 0x1257A = 0x12531 U+309A */ + { 0x8352, 0x839b }, /* 0x1257B = 0x12533 U+309A */ + { 0x835a, 0x839c }, /* 0x1257C = 0x1253B U+309A */ + { 0x8363, 0x839d }, /* 0x1257D = 0x12544 U+309A */ + { 0x8367, 0x839e }, /* 0x1257E = 0x12548 U+309A */ + { 0x83f3, 0x83f6 }, /* 0x12678 = 0x12675 U+309A */ +}; + +static int +shift_jisx0213_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + int count = 0; + unsigned short lasttwo = conv->ostate; + + if (lasttwo) { + /* Attempt to combine the last character with this one. */ + unsigned int idx; + unsigned int len; + + if (wc == 0x02e5) + idx = shift_jisx0213_comp_table02e5_idx, + len = shift_jisx0213_comp_table02e5_len; + else if (wc == 0x02e9) + idx = shift_jisx0213_comp_table02e9_idx, + len = shift_jisx0213_comp_table02e9_len; + else if (wc == 0x0300) + idx = shift_jisx0213_comp_table0300_idx, + len = shift_jisx0213_comp_table0300_len; + else if (wc == 0x0301) + idx = shift_jisx0213_comp_table0301_idx, + len = shift_jisx0213_comp_table0301_len; + else if (wc == 0x309a) + idx = shift_jisx0213_comp_table309a_idx, + len = shift_jisx0213_comp_table309a_len; + else + goto not_combining; + + do + if (shift_jisx0213_comp_table_data[idx].base == lasttwo) + break; + while (++idx, --len > 0); + + if (len > 0) { + /* Output the combined character. */ + if (n >= 2) { + lasttwo = shift_jisx0213_comp_table_data[idx].composed; + r[0] = (lasttwo >> 8) & 0xff; + r[1] = lasttwo & 0xff; + conv->ostate = 0; + return 2; + } else + return RET_TOOSMALL; + } + + not_combining: + /* Output the buffered character. */ + if (n < 2) + return RET_TOOSMALL; + r[0] = (lasttwo >> 8) & 0xff; + r[1] = lasttwo & 0xff; + r += 2; + count = 2; + } + + if (wc < 0x80 && wc != 0x5c && wc != 0x7e) { + /* Plain ISO646-JP character. */ + if (n > count) { + r[0] = (unsigned char) wc; + conv->ostate = 0; + return count+1; + } else + return RET_TOOSMALL; + } else if (wc == 0x00a5) { + if (n > count) { + r[0] = 0x5c; + conv->ostate = 0; + return count+1; + } else + return RET_TOOSMALL; + } else if (wc == 0x203e) { + if (n > count) { + r[0] = 0x7e; + conv->ostate = 0; + return count+1; + } else + return RET_TOOSMALL; + } else if (wc >= 0xff61 && wc <= 0xff9f) { + /* Half-width katakana. */ + if (n > count) { + r[0] = wc - 0xfec0; + conv->ostate = 0; + return count+1; + } else + return RET_TOOSMALL; + } else { + unsigned int s1, s2; + unsigned short jch = ucs4_to_jisx0213(wc); + if (jch != 0) { + /* Convert it to shifted representation. */ + s1 = jch >> 8; + s2 = jch & 0x7f; + s1 -= 0x21; + s2 -= 0x21; + if (s1 >= 0x5e) { + /* Handling of JISX 0213 plane 2 rows. */ + if (s1 >= 0xcd) /* rows 0x26E..0x27E */ + s1 -= 102; + else if (s1 >= 0x8b || s1 == 0x87) /* rows 0x228, 0x22C..0x22F */ + s1 -= 40; + else /* rows 0x221, 0x223..0x225 */ + s1 -= 34; + /* Now 0x5e <= s1 <= 0x77. */ + } + if (s1 & 1) + s2 += 0x5e; + s1 = s1 >> 1; + if (s1 < 0x1f) + s1 += 0x81; + else + s1 += 0xc1; + if (s2 < 0x3f) + s2 += 0x40; + else + s2 += 0x41; + if (jch & 0x0080) { + /* A possible match in comp_table_data. We have to buffer it. */ + /* We know it's a JISX 0213 plane 1 character. */ + if (jch & 0x8000) abort(); + conv->ostate = (s1 << 8) | s2; + return count+0; + } + /* Output the shifted representation. */ + if (n >= count+2) { + r[0] = s1; + r[1] = s2; + conv->ostate = 0; + return count+2; + } else + return RET_TOOSMALL; + } + return RET_ILUNI; + } +} + +static int +shift_jisx0213_reset (conv_t conv, unsigned char *r, int n) +{ + state_t lasttwo = conv->ostate; + + if (lasttwo) { + if (n < 2) + return RET_TOOSMALL; + r[0] = (lasttwo >> 8) & 0xff; + r[1] = lasttwo & 0xff; + /* conv->ostate = 0; will be done by the caller */ + return 2; + } else + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/sjis.h b/graf2d/win32gdk/gdk/src/iconv/sjis.h new file mode 100644 index 0000000000000..8244e3a87c3c0 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/sjis.h @@ -0,0 +1,132 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * SHIFT_JIS + */ + +/* + Conversion between SJIS codes (s1,s2) and JISX0208 codes (c1,c2): + Example. (s1,s2) = 0x8140, (c1,c2) = 0x2121. + 0x81 <= s1 <= 0x9F || 0xE0 <= s1 <= 0xEA, + 0x40 <= s2 <= 0x7E || 0x80 <= s2 <= 0xFC, + 0x21 <= c1 <= 0x74, 0x21 <= c2 <= 0x7E. + Invariant: + 94*2*(s1 < 0xE0 ? s1-0x81 : s1-0xC1) + (s2 < 0x80 ? s2-0x40 : s2-0x41) + = 94*(c1-0x21)+(c2-0x21) + Conversion (s1,s2) -> (c1,c2): + t1 := (s1 < 0xE0 ? s1-0x81 : s1-0xC1) + t2 := (s2 < 0x80 ? s2-0x40 : s2-0x41) + c1 := 2*t1 + (t2 < 0x5E ? 0 : 1) + 0x21 + c2 := (t2 < 0x5E ? t2 : t2-0x5E) + 0x21 + Conversion (c1,c2) -> (s1,s2): + t1 := (c1 - 0x21) >> 1 + t2 := ((c1 - 0x21) & 1) * 0x5E + (c2 - 0x21) + s1 := (t1 < 0x1F ? t1+0x81 : t1+0xC1) + s2 := (t2 < 0x3F ? t2+0x40 : t2+0x41) + */ + +static int +sjis_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80 || (c >= 0xa1 && c <= 0xdf)) + return jisx0201_mbtowc(conv,pwc,s,n); + else { + unsigned char s1, s2; + s1 = c; + if ((s1 >= 0x81 && s1 <= 0x9f) || (s1 >= 0xe0 && s1 <= 0xea)) { + if (n < 2) + return RET_TOOFEW(0); + s2 = s[1]; + if ((s2 >= 0x40 && s2 <= 0x7e) || (s2 >= 0x80 && s2 <= 0xfc)) { + unsigned char t1 = (s1 < 0xe0 ? s1-0x81 : s1-0xc1); + unsigned char t2 = (s2 < 0x80 ? s2-0x40 : s2-0x41); + unsigned char buf[2]; + buf[0] = 2*t1 + (t2 < 0x5e ? 0 : 1) + 0x21; + buf[1] = (t2 < 0x5e ? t2 : t2-0x5e) + 0x21; + return jisx0208_mbtowc(conv,pwc,buf,2); + } + } else if (s1 >= 0xf0 && s1 <= 0xf9) { + /* User-defined range. See + * Ken Lunde's "CJKV Information Processing", table 4-66, p. 206. */ + if (n < 2) + return RET_TOOFEW(0); + s2 = s[1]; + if ((s2 >= 0x40 && s2 <= 0x7e) || (s2 >= 0x80 && s2 <= 0xfc)) { + *pwc = 0xe000 + 188*(s1 - 0xf0) + (s2 < 0x80 ? s2-0x40 : s2-0x41); + return 2; + } + } + return RET_ILSEQ; + } +} + +static int +sjis_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char buf[2]; + int ret; + + /* Try JIS X 0201-1976. */ + ret = jisx0201_wctomb(conv,buf,wc,1); + if (ret != RET_ILUNI) { + unsigned char c; + if (ret != 1) abort(); + c = buf[0]; + if (c < 0x80 || (c >= 0xa1 && c <= 0xdf)) { + r[0] = c; + return 1; + } + } + + /* Try JIS X 0208-1990. */ + ret = jisx0208_wctomb(conv,buf,wc,2); + if (ret != RET_ILUNI) { + unsigned char c1, c2; + if (ret != 2) abort(); + if (n < 2) + return RET_TOOSMALL; + c1 = buf[0]; + c2 = buf[1]; + if ((c1 >= 0x21 && c1 <= 0x74) && (c2 >= 0x21 && c2 <= 0x7e)) { + unsigned char t1 = (c1 - 0x21) >> 1; + unsigned char t2 = (((c1 - 0x21) & 1) ? 0x5e : 0) + (c2 - 0x21); + r[0] = (t1 < 0x1f ? t1+0x81 : t1+0xc1); + r[1] = (t2 < 0x3f ? t2+0x40 : t2+0x41); + return 2; + } + } + + /* User-defined range. See + * Ken Lunde's "CJKV Information Processing", table 4-66, p. 206. */ + if (wc >= 0xe000 && wc < 0xe758) { + unsigned char c1, c2; + if (n < 2) + return RET_TOOSMALL; + c1 = (unsigned int) (wc - 0xe000) / 188; + c2 = (unsigned int) (wc - 0xe000) % 188; + r[0] = c1+0xf0; + r[1] = (c2 < 0x3f ? c2+0x40 : c2+0x41); + return 2; + } + + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/tcvn.h b/graf2d/win32gdk/gdk/src/iconv/tcvn.h new file mode 100644 index 0000000000000..abd5def22c5a9 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/tcvn.h @@ -0,0 +1,291 @@ +/* + * Copyright (C) 1999-2002, 2004 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * TCVN-5712 + */ + +#include "flushwc.h" +#include "vietcomb.h" + +static const unsigned char tcvn_comb_table[] = { + 0xb0, 0xb3, 0xb2, 0xb1, 0xb4, +}; + +/* The possible bases in viet_comp_table_data: + 0x0041..0x0045, 0x0047..0x0049, 0x004B..0x0050, 0x0052..0x0057, + 0x0059..0x005A, 0x0061..0x0065, 0x0067..0x0069, 0x006B..0x0070, + 0x0072..0x0077, 0x0079..0x007A, 0x00A5, 0x00C2, 0x00CA, 0x00D3..0x00D6, + 0x00DA, 0x00E2, 0x00EA, 0x00F3..0x00F6, 0x00FA, 0x0102..0x0103, + 0x0168..0x0169, 0x01A0..0x01A1, 0x01AF..0x01B0. */ +static const unsigned int tcvn_comp_bases[] = { + 0x06fdfbbe, 0x06fdfbbe, 0x00000000, 0x00000020, 0x04780404, 0x04780404, + 0x0000000c, 0x00000000, 0x00000000, 0x00000300, 0x00000000, 0x00018003 +}; + +static const unsigned short tcvn_2uni_1[24] = { + /* 0x00 */ + 0x0000, 0x00da, 0x1ee4, 0x0003, 0x1eea, 0x1eec, 0x1eee, 0x0007, + 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, + /* 0x10 */ + 0x0010, 0x1ee8, 0x1ef0, 0x1ef2, 0x1ef6, 0x1ef8, 0x00dd, 0x1ef4, +}; +static const unsigned short tcvn_2uni_2[128] = { + /* 0x80 */ + 0x00c0, 0x1ea2, 0x00c3, 0x00c1, 0x1ea0, 0x1eb6, 0x1eac, 0x00c8, + 0x1eba, 0x1ebc, 0x00c9, 0x1eb8, 0x1ec6, 0x00cc, 0x1ec8, 0x0128, + /* 0x90 */ + 0x00cd, 0x1eca, 0x00d2, 0x1ece, 0x00d5, 0x00d3, 0x1ecc, 0x1ed8, + 0x1edc, 0x1ede, 0x1ee0, 0x1eda, 0x1ee2, 0x00d9, 0x1ee6, 0x0168, + /* 0xa0 */ + 0x00a0, 0x0102, 0x00c2, 0x00ca, 0x00d4, 0x01a0, 0x01af, 0x0110, + 0x0103, 0x00e2, 0x00ea, 0x00f4, 0x01a1, 0x01b0, 0x0111, 0x1eb0, + /* 0xb0 */ + 0x0300, 0x0309, 0x0303, 0x0301, 0x0323, 0x00e0, 0x1ea3, 0x00e3, + 0x00e1, 0x1ea1, 0x1eb2, 0x1eb1, 0x1eb3, 0x1eb5, 0x1eaf, 0x1eb4, + /* 0xc0 */ + 0x1eae, 0x1ea6, 0x1ea8, 0x1eaa, 0x1ea4, 0x1ec0, 0x1eb7, 0x1ea7, + 0x1ea9, 0x1eab, 0x1ea5, 0x1ead, 0x00e8, 0x1ec2, 0x1ebb, 0x1ebd, + /* 0xd0 */ + 0x00e9, 0x1eb9, 0x1ec1, 0x1ec3, 0x1ec5, 0x1ebf, 0x1ec7, 0x00ec, + 0x1ec9, 0x1ec4, 0x1ebe, 0x1ed2, 0x0129, 0x00ed, 0x1ecb, 0x00f2, + /* 0xe0 */ + 0x1ed4, 0x1ecf, 0x00f5, 0x00f3, 0x1ecd, 0x1ed3, 0x1ed5, 0x1ed7, + 0x1ed1, 0x1ed9, 0x1edd, 0x1edf, 0x1ee1, 0x1edb, 0x1ee3, 0x00f9, + /* 0xf0 */ + 0x1ed6, 0x1ee7, 0x0169, 0x00fa, 0x1ee5, 0x1eeb, 0x1eed, 0x1eef, + 0x1ee9, 0x1ef1, 0x1ef3, 0x1ef7, 0x1ef9, 0x00fd, 0x1ef5, 0x1ed0, +}; + +/* In the TCVN to Unicode direction, the state contains a buffered + character, or 0 if none. */ + +static int +tcvn_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + unsigned short wc; + unsigned short last_wc; + if (c < 0x18) + wc = tcvn_2uni_1[c]; + else if (c < 0x80) + wc = c; + else + wc = tcvn_2uni_2[c-0x80]; + last_wc = conv->istate; + if (last_wc) { + if (wc >= 0x0300 && wc < 0x0340) { + /* See whether last_wc and wc can be combined. */ + unsigned int k; + unsigned int i1, i2; + switch (wc) { + case 0x0300: k = 0; break; + case 0x0301: k = 1; break; + case 0x0303: k = 2; break; + case 0x0309: k = 3; break; + case 0x0323: k = 4; break; + default: abort(); + } + i1 = viet_comp_table[k].idx; + i2 = i1 + viet_comp_table[k].len-1; + if (last_wc >= viet_comp_table_data[i1].base + && last_wc <= viet_comp_table_data[i2].base) { + unsigned int i; + for (;;) { + i = (i1+i2)>>1; + if (last_wc == viet_comp_table_data[i].base) + break; + if (last_wc < viet_comp_table_data[i].base) { + if (i1 == i) + goto not_combining; + i2 = i; + } else { + if (i1 != i) + i1 = i; + else { + i = i2; + if (last_wc == viet_comp_table_data[i].base) + break; + goto not_combining; + } + } + } + last_wc = viet_comp_table_data[i].composed; + /* Output the combined character. */ + conv->istate = 0; + *pwc = (ucs4_t) last_wc; + return 1; + } + } + not_combining: + /* Output the buffered character. */ + conv->istate = 0; + *pwc = (ucs4_t) last_wc; + return 0; /* Don't advance the input pointer. */ + } + if (wc >= 0x0041 && wc <= 0x01b0 + && ((tcvn_comp_bases[(wc - 0x0040) >> 5] >> (wc & 0x1f)) & 1)) { + /* wc is a possible match in viet_comp_table_data. Buffer it. */ + conv->istate = wc; + return RET_TOOFEW(1); + } else { + /* Output wc immediately. */ + *pwc = (ucs4_t) wc; + return 1; + } +} + +#define tcvn_flushwc normal_flushwc + +static const unsigned char tcvn_page00[96+184] = { + 0xa0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa8-0xaf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb8-0xbf */ + 0x80, 0x83, 0xa2, 0x82, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0x87, 0x8a, 0xa3, 0x00, 0x8d, 0x90, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x92, 0x95, 0xa4, 0x94, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x9d, 0x01, 0x00, 0x00, 0x16, 0x00, 0x00, /* 0xd8-0xdf */ + 0xb5, 0xb8, 0xa9, 0xb7, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0xcc, 0xd0, 0xaa, 0x00, 0xd7, 0xdd, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0xdf, 0xe3, 0xab, 0xe2, 0x00, 0x00, /* 0xf0-0xf7 */ + 0x00, 0xef, 0xf3, 0x00, 0x00, 0xfd, 0x00, 0x00, /* 0xf8-0xff */ + /* 0x0100 */ + 0x00, 0x00, 0xa1, 0xa8, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xa7, 0xae, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0x8f, 0xdc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x9f, 0xf2, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xa5, 0xac, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa6, /* 0xa8-0xaf */ + 0xad, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ +}; +static const unsigned char tcvn_page03[40] = { + 0xb0, 0xb3, 0x00, 0xb2, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0xb1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ +}; +static const unsigned char tcvn_page1e[96] = { + 0x84, 0xb9, 0x81, 0xb6, 0xc4, 0xca, 0xc1, 0xc7, /* 0xa0-0xa7 */ + 0xc2, 0xc8, 0xc3, 0xc9, 0x86, 0xcb, 0xc0, 0xbe, /* 0xa8-0xaf */ + 0xaf, 0xbb, 0xba, 0xbc, 0xbf, 0xbd, 0x85, 0xc6, /* 0xb0-0xb7 */ + 0x8b, 0xd1, 0x88, 0xce, 0x89, 0xcf, 0xda, 0xd5, /* 0xb8-0xbf */ + 0xc5, 0xd2, 0xcd, 0xd3, 0xd9, 0xd4, 0x8c, 0xd6, /* 0xc0-0xc7 */ + 0x8e, 0xd8, 0x91, 0xde, 0x96, 0xe4, 0x93, 0xe1, /* 0xc8-0xcf */ + 0xff, 0xe8, 0xdb, 0xe5, 0xe0, 0xe6, 0xf0, 0xe7, /* 0xd0-0xd7 */ + 0x97, 0xe9, 0x9b, 0xed, 0x98, 0xea, 0x99, 0xeb, /* 0xd8-0xdf */ + 0x9a, 0xec, 0x9c, 0xee, 0x02, 0xf4, 0x9e, 0xf1, /* 0xe0-0xe7 */ + 0x11, 0xf8, 0x04, 0xf5, 0x05, 0xf6, 0x06, 0xf7, /* 0xe8-0xef */ + 0x12, 0xf9, 0x13, 0xfa, 0x17, 0xfe, 0x14, 0xfb, /* 0xf0-0xf7 */ + 0x15, 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; + +static int +tcvn_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080 && (wc >= 0x0020 || (0x00fe0076 & (1 << wc)) == 0)) { + *r = wc; + return 1; + } + else if (wc >= 0x00a0 && wc < 0x01b8) + c = tcvn_page00[wc-0x00a0]; + else if (wc >= 0x0300 && wc < 0x0328) + c = tcvn_page03[wc-0x0300]; + else if (wc >= 0x0340 && wc < 0x0342) /* deprecated Vietnamese tone marks */ + c = tcvn_page03[wc-0x0340]; + else if (wc >= 0x1ea0 && wc < 0x1f00) + c = tcvn_page1e[wc-0x1ea0]; + if (c != 0) { + *r = c; + return 1; + } + /* Try compatibility or canonical decomposition. */ + { + /* Binary search through viet_decomp_table. */ + unsigned int i1 = 0; + unsigned int i2 = sizeof(viet_decomp_table)/sizeof(viet_decomp_table[0])-1; + if (wc >= viet_decomp_table[i1].composed + && wc <= viet_decomp_table[i2].composed) { + unsigned int i; + for (;;) { + /* Here i2 - i1 > 0. */ + i = (i1+i2)>>1; + if (wc == viet_decomp_table[i].composed) + break; + if (wc < viet_decomp_table[i].composed) { + if (i1 == i) + return RET_ILUNI; + /* Here i1 < i < i2. */ + i2 = i; + } else { + /* Here i1 <= i < i2. */ + if (i1 != i) + i1 = i; + else { + /* Here i2 - i1 = 1. */ + i = i2; + if (wc == viet_decomp_table[i].composed) + break; + else + return RET_ILUNI; + } + } + } + /* Found a compatibility or canonical decomposition. */ + wc = viet_decomp_table[i].base; + /* wc is one of 0x0020, 0x0041..0x005a, 0x0061..0x007a, 0x00a5, 0x00a8, + 0x00c2, 0x00c5..0x00c7, 0x00ca, 0x00cf, 0x00d3, 0x00d4, 0x00d6, + 0x00d8, 0x00da, 0x00dc, 0x00e2, 0x00e5..0x00e7, 0x00ea, 0x00ef, + 0x00f3, 0x00f4, 0x00f6, 0x00f8, 0x00fc, 0x0102, 0x0103, 0x01a0, + 0x01a1, 0x01af, 0x01b0. */ + if (wc < 0x0080) + c = wc; + else { + c = tcvn_page00[wc-0x00a0]; + if (c == 0) + return RET_ILUNI; + } + if (n < 2) + return RET_TOOSMALL; + r[0] = c; + r[1] = tcvn_comb_table[viet_decomp_table[i].comb1]; + return 2; + } + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/tds565.h b/graf2d/win32gdk/gdk/src/iconv/tds565.h new file mode 100644 index 0000000000000..479513fedf98f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/tds565.h @@ -0,0 +1,107 @@ +/* + * Copyright (C) 1999-2002 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * TDS565 + */ + +static const unsigned short tds565_2uni[64] = { + /* 0x40 */ + 0x0040, 0x0041, 0x0042, 0x00c7, 0x0044, 0x0045, 0x00c4, 0x0046, + 0x0047, 0x0048, 0x0049, 0x004a, 0x017d, 0x004b, 0x004c, 0x004d, + /* 0x50 */ + 0x004e, 0x0147, 0x004f, 0x00d6, 0x0050, 0x0052, 0x0053, 0x015e, + 0x0054, 0x0055, 0x00dc, 0x0057, 0x0059, 0x00dd, 0x005a, 0x005f, + /* 0x60 */ + 0x2116, 0x0061, 0x0062, 0x00e7, 0x0064, 0x0065, 0x00e4, 0x0066, + 0x0067, 0x0068, 0x0069, 0x006a, 0x017e, 0x006b, 0x006c, 0x006d, + /* 0x70 */ + 0x006e, 0x0148, 0x006f, 0x00f6, 0x0070, 0x0072, 0x0073, 0x015f, + 0x0074, 0x0075, 0x00fc, 0x0077, 0x0079, 0x00fd, 0x007a, 0x007f, +}; + +static int +tds565_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x40) { + *pwc = (ucs4_t) c; + return 1; + } + else if (c < 0x80) { + *pwc = (ucs4_t) tds565_2uni[c-0x40]; + return 1; + } + return RET_ILSEQ; +} + +static const unsigned char tds565_page00[64] = { + 0x40, 0x41, 0x42, 0x00, 0x44, 0x45, 0x47, 0x48, /* 0x40-0x47 */ + 0x49, 0x4a, 0x4b, 0x4d, 0x4e, 0x4f, 0x50, 0x52, /* 0x48-0x4f */ + 0x54, 0x00, 0x55, 0x56, 0x58, 0x59, 0x00, 0x5b, /* 0x50-0x57 */ + 0x00, 0x5c, 0x5e, 0x00, 0x00, 0x00, 0x00, 0x5f, /* 0x58-0x5f */ + 0x00, 0x61, 0x62, 0x00, 0x64, 0x65, 0x67, 0x68, /* 0x60-0x67 */ + 0x69, 0x6a, 0x6b, 0x6d, 0x6e, 0x6f, 0x70, 0x72, /* 0x68-0x6f */ + 0x74, 0x00, 0x75, 0x76, 0x78, 0x79, 0x00, 0x7b, /* 0x70-0x77 */ + 0x00, 0x7c, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x7f, /* 0x78-0x7f */ +}; +static const unsigned char tds565_page00_1[64] = { + 0x00, 0x00, 0x00, 0x00, 0x46, 0x00, 0x00, 0x43, /* 0xc0-0xc7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x53, 0x00, /* 0xd0-0xd7 */ + 0x00, 0x00, 0x00, 0x00, 0x5a, 0x5d, 0x00, 0x00, /* 0xd8-0xdf */ + 0x00, 0x00, 0x00, 0x00, 0x66, 0x00, 0x00, 0x63, /* 0xe0-0xe7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x73, 0x00, /* 0xf0-0xf7 */ + 0x00, 0x00, 0x00, 0x00, 0x7a, 0x7d, 0x00, 0x00, /* 0xf8-0xff */ +}; +static const unsigned char tds565_page01[64] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x51, /* 0x40-0x47 */ + 0x71, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x57, 0x77, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x4c, 0x6c, 0x00, /* 0x78-0x7f */ +}; + +static int +tds565_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0040) { + *r = wc; + return 1; + } + else if (wc >= 0x0040 && wc < 0x0080) + c = tds565_page00[wc-0x0040]; + else if (wc >= 0x00c0 && wc < 0x0100) + c = tds565_page00_1[wc-0x00c0]; + else if (wc >= 0x0140 && wc < 0x0180) + c = tds565_page01[wc-0x0140]; + else if (wc == 0x2116) + c = 0x60; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/tis620.h b/graf2d/win32gdk/gdk/src/iconv/tis620.h new file mode 100644 index 0000000000000..125e6dc80e70e --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/tis620.h @@ -0,0 +1,52 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * TIS620.2533-1 + */ + +static int +tis620_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x80) { + *pwc = (ucs4_t) c; + return 1; + } + else if (c >= 0xa1 && c <= 0xfb && !(c >= 0xdb && c <= 0xde)) { + *pwc = (ucs4_t) (c + 0x0d60); + return 1; + } + return RET_ILSEQ; +} + +static int +tis620_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x0080) { + *r = wc; + return 1; + } + else if (wc >= 0x0e01 && wc <= 0x0e5b && !(wc >= 0x0e3b && wc <= 0x0e3e)) { + *r = wc-0x0d60; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/translit.def b/graf2d/win32gdk/gdk/src/iconv/translit.def new file mode 100644 index 0000000000000..cbd329ee5361e --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/translit.def @@ -0,0 +1,3918 @@ +# Copyright (C) 1999-2003 Free Software Foundation, Inc. +# This file is part of the GNU LIBICONV Library. +# +# The GNU LIBICONV Library is free software; you can redistribute it +# and/or modify it under the terms of the GNU Library General Public +# License as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. +# +# The GNU LIBICONV Library is distributed in the hope that it will be +# useful, but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Library General Public License for more details. +# +# You should have received a copy of the GNU Library General Public +# License along with the GNU LIBICONV Library; see the file COPYING.LIB. +# If not, write to the Free Software Foundation, Inc., 51 Franklin Street, +# Fifth Floor, Boston, MA 02110-1301, USA. +# +# +# Definition of transliteration from Unicode to poorer character sets. +# +# This covers all of Markus Kuhn's TARGET1. +# +# The second column gives the transliteration. It is enclosed between tabs! +# +00A0 # NO-BREAK SPACE +00A1 ! # INVERTED EXCLAMATION MARK +00A2 c # CENT SIGN +00A3 lb # POUND SIGN +00A4 # CURRENCY SIGN +00A5 yen # YEN SIGN +00A6 | # BROKEN BAR +00A7 SS # SECTION SIGN +00A8 " # DIAERESIS +00A9 (c) # COPYRIGHT SIGN +00AA a # FEMININE ORDINAL INDICATOR +00AB << # LEFT-POINTING DOUBLE ANGLE QUOTATION MARK +00AC not # NOT SIGN +00AD - # SOFT HYPHEN +00AE (R) # REGISTERED SIGN +00AF # MACRON +00B0 ^0 # DEGREE SIGN +00B1 +/- # PLUS-MINUS SIGN +00B2 ^2 # SUPERSCRIPT TWO +00B3 ^3 # SUPERSCRIPT THREE +00B4 ' # ACUTE ACCENT +00B5 u # MICRO SIGN +00B6 P # PILCROW SIGN +00B7 . # MIDDLE DOT +00B8 , # CEDILLA +00B9 ^1 # SUPERSCRIPT ONE +00BA o # MASCULINE ORDINAL INDICATOR +00BB >> # RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK +00BC 1⁄4 # VULGAR FRACTION ONE QUARTER +00BD 1⁄2 # VULGAR FRACTION ONE HALF +00BE 3⁄4 # VULGAR FRACTION THREE QUARTERS +00BF ? # INVERTED QUESTION MARK +00C0 `A # LATIN CAPITAL LETTER A WITH GRAVE +00C1 ´A # LATIN CAPITAL LETTER A WITH ACUTE +00C2 ^A # LATIN CAPITAL LETTER A WITH CIRCUMFLEX +00C3 ~A # LATIN CAPITAL LETTER A WITH TILDE +00C4 "A # LATIN CAPITAL LETTER A WITH DIAERESIS +00C5 A # LATIN CAPITAL LETTER A WITH RING ABOVE +00C6 AE # LATIN CAPITAL LETTER AE +00C7 C # LATIN CAPITAL LETTER C WITH CEDILLA +00C8 `E # LATIN CAPITAL LETTER E WITH GRAVE +00C9 ´E # LATIN CAPITAL LETTER E WITH ACUTE +00CA ^E # LATIN CAPITAL LETTER E WITH CIRCUMFLEX +00CB "E # LATIN CAPITAL LETTER E WITH DIAERESIS +00CC `I # LATIN CAPITAL LETTER I WITH GRAVE +00CD ´I # LATIN CAPITAL LETTER I WITH ACUTE +00CE ^I # LATIN CAPITAL LETTER I WITH CIRCUMFLEX +00CF "I # LATIN CAPITAL LETTER I WITH DIAERESIS +00D0 D # LATIN CAPITAL LETTER ETH +00D1 ~N # LATIN CAPITAL LETTER N WITH TILDE +00D2 `O # LATIN CAPITAL LETTER O WITH GRAVE +00D3 ´O # LATIN CAPITAL LETTER O WITH ACUTE +00D4 ^O # LATIN CAPITAL LETTER O WITH CIRCUMFLEX +00D5 ~O # LATIN CAPITAL LETTER O WITH TILDE +00D6 "O # LATIN CAPITAL LETTER O WITH DIAERESIS +00D7 x # MULTIPLICATION SIGN +00D8 O # LATIN CAPITAL LETTER O WITH STROKE +00D9 `U # LATIN CAPITAL LETTER U WITH GRAVE +00DA ´U # LATIN CAPITAL LETTER U WITH ACUTE +00DB ^U # LATIN CAPITAL LETTER U WITH CIRCUMFLEX +00DC "U # LATIN CAPITAL LETTER U WITH DIAERESIS +00DD ´Y # LATIN CAPITAL LETTER Y WITH ACUTE +00DE Th # LATIN CAPITAL LETTER THORN +00DF ss # LATIN SMALL LETTER SHARP S +00E0 `a # LATIN SMALL LETTER A WITH GRAVE +00E1 ´a # LATIN SMALL LETTER A WITH ACUTE +00E2 ^a # LATIN SMALL LETTER A WITH CIRCUMFLEX +00E3 ~a # LATIN SMALL LETTER A WITH TILDE +00E4 "a # LATIN SMALL LETTER A WITH DIAERESIS +00E5 a # LATIN SMALL LETTER A WITH RING ABOVE +00E6 ae # LATIN SMALL LETTER AE +00E7 c # LATIN SMALL LETTER C WITH CEDILLA +00E8 `e # LATIN SMALL LETTER E WITH GRAVE +00E9 ´e # LATIN SMALL LETTER E WITH ACUTE +00EA ^e # LATIN SMALL LETTER E WITH CIRCUMFLEX +00EB "e # LATIN SMALL LETTER E WITH DIAERESIS +00EC `i # LATIN SMALL LETTER I WITH GRAVE +00ED ´i # LATIN SMALL LETTER I WITH ACUTE +00EE ^i # LATIN SMALL LETTER I WITH CIRCUMFLEX +00EF "i # LATIN SMALL LETTER I WITH DIAERESIS +00F0 d # LATIN SMALL LETTER ETH +00F1 ~n # LATIN SMALL LETTER N WITH TILDE +00F2 `o # LATIN SMALL LETTER O WITH GRAVE +00F3 ´o # LATIN SMALL LETTER O WITH ACUTE +00F4 ^o # LATIN SMALL LETTER O WITH CIRCUMFLEX +00F5 ~o # LATIN SMALL LETTER O WITH TILDE +00F6 "o # LATIN SMALL LETTER O WITH DIAERESIS +00F7 : # DIVISION SIGN +00F8 o # LATIN SMALL LETTER O WITH STROKE +00F9 `u # LATIN SMALL LETTER U WITH GRAVE +00FA ´u # LATIN SMALL LETTER U WITH ACUTE +00FB ^u # LATIN SMALL LETTER U WITH CIRCUMFLEX +00FC "u # LATIN SMALL LETTER U WITH DIAERESIS +00FD ´y # LATIN SMALL LETTER Y WITH ACUTE +00FE th # LATIN SMALL LETTER THORN +00FF "y # LATIN SMALL LETTER Y WITH DIAERESIS +0100 A # LATIN CAPITAL LETTER A WITH MACRON +0101 a # LATIN SMALL LETTER A WITH MACRON +0102 A # LATIN CAPITAL LETTER A WITH BREVE +0103 a # LATIN SMALL LETTER A WITH BREVE +0104 A # LATIN CAPITAL LETTER A WITH OGONEK +0105 a # LATIN SMALL LETTER A WITH OGONEK +0106 ´C # LATIN CAPITAL LETTER C WITH ACUTE +0107 ´c # LATIN SMALL LETTER C WITH ACUTE +0108 ^C # LATIN CAPITAL LETTER C WITH CIRCUMFLEX +0109 ^c # LATIN SMALL LETTER C WITH CIRCUMFLEX +010A C # LATIN CAPITAL LETTER C WITH DOT ABOVE +010B c # LATIN SMALL LETTER C WITH DOT ABOVE +010C C # LATIN CAPITAL LETTER C WITH CARON +010D c # LATIN SMALL LETTER C WITH CARON +010E D # LATIN CAPITAL LETTER D WITH CARON +010F d # LATIN SMALL LETTER D WITH CARON +0110 D # LATIN CAPITAL LETTER D WITH STROKE +0111 d # LATIN SMALL LETTER D WITH STROKE +0112 E # LATIN CAPITAL LETTER E WITH MACRON +0113 e # LATIN SMALL LETTER E WITH MACRON +0114 E # LATIN CAPITAL LETTER E WITH BREVE +0115 e # LATIN SMALL LETTER E WITH BREVE +0116 E # LATIN CAPITAL LETTER E WITH DOT ABOVE +0117 e # LATIN SMALL LETTER E WITH DOT ABOVE +0118 E # LATIN CAPITAL LETTER E WITH OGONEK +0119 e # LATIN SMALL LETTER E WITH OGONEK +011A E # LATIN CAPITAL LETTER E WITH CARON +011B e # LATIN SMALL LETTER E WITH CARON +011C ^G # LATIN CAPITAL LETTER G WITH CIRCUMFLEX +011D ^g # LATIN SMALL LETTER G WITH CIRCUMFLEX +011E G # LATIN CAPITAL LETTER G WITH BREVE +011F g # LATIN SMALL LETTER G WITH BREVE +0120 G # LATIN CAPITAL LETTER G WITH DOT ABOVE +0121 g # LATIN SMALL LETTER G WITH DOT ABOVE +0122 G # LATIN CAPITAL LETTER G WITH CEDILLA +0123 g # LATIN SMALL LETTER G WITH CEDILLA +0124 ^H # LATIN CAPITAL LETTER H WITH CIRCUMFLEX +0125 ^h # LATIN SMALL LETTER H WITH CIRCUMFLEX +0126 H # LATIN CAPITAL LETTER H WITH STROKE +0127 h # LATIN SMALL LETTER H WITH STROKE +0128 ~I # LATIN CAPITAL LETTER I WITH TILDE +0129 ~i # LATIN SMALL LETTER I WITH TILDE +012A I # LATIN CAPITAL LETTER I WITH MACRON +012B i # LATIN SMALL LETTER I WITH MACRON +012C I # LATIN CAPITAL LETTER I WITH BREVE +012D i # LATIN SMALL LETTER I WITH BREVE +012E I # LATIN CAPITAL LETTER I WITH OGONEK +012F i # LATIN SMALL LETTER I WITH OGONEK +0130 I # LATIN CAPITAL LETTER I WITH DOT ABOVE +0131 i # LATIN SMALL LETTER DOTLESS I +0132 IJ # LATIN CAPITAL LIGATURE IJ +0133 ij # LATIN SMALL LIGATURE IJ +0134 ^J # LATIN CAPITAL LETTER J WITH CIRCUMFLEX +0135 ^j # LATIN SMALL LETTER J WITH CIRCUMFLEX +0136 K # LATIN CAPITAL LETTER K WITH CEDILLA +0137 k # LATIN SMALL LETTER K WITH CEDILLA +0138 # LATIN SMALL LETTER KRA +0139 L # LATIN CAPITAL LETTER L WITH ACUTE +013A l # LATIN SMALL LETTER L WITH ACUTE +013B L # LATIN CAPITAL LETTER L WITH CEDILLA +013C l # LATIN SMALL LETTER L WITH CEDILLA +013D L # LATIN CAPITAL LETTER L WITH CARON +013E l # LATIN SMALL LETTER L WITH CARON +013F L # LATIN CAPITAL LETTER L WITH MIDDLE DOT +0140 l # LATIN SMALL LETTER L WITH MIDDLE DOT +0141 L # LATIN CAPITAL LETTER L WITH STROKE +0142 l # LATIN SMALL LETTER L WITH STROKE +0143 ´N # LATIN CAPITAL LETTER N WITH ACUTE +0144 ´n # LATIN SMALL LETTER N WITH ACUTE +0145 N # LATIN CAPITAL LETTER N WITH CEDILLA +0146 n # LATIN SMALL LETTER N WITH CEDILLA +0147 N # LATIN CAPITAL LETTER N WITH CARON +0148 n # LATIN SMALL LETTER N WITH CARON +0149 'n # LATIN SMALL LETTER N PRECEDED BY APOSTROPHE +014A # LATIN CAPITAL LETTER ENG +014B # LATIN SMALL LETTER ENG +014C O # LATIN CAPITAL LETTER O WITH MACRON +014D o # LATIN SMALL LETTER O WITH MACRON +014E O # LATIN CAPITAL LETTER O WITH BREVE +014F o # LATIN SMALL LETTER O WITH BREVE +0150 "O # LATIN CAPITAL LETTER O WITH DOUBLE ACUTE +0151 "o # LATIN SMALL LETTER O WITH DOUBLE ACUTE +0152 OE # LATIN CAPITAL LIGATURE OE +0153 oe # LATIN SMALL LIGATURE OE +0154 ´R # LATIN CAPITAL LETTER R WITH ACUTE +0155 ´r # LATIN SMALL LETTER R WITH ACUTE +0156 R # LATIN CAPITAL LETTER R WITH CEDILLA +0157 r # LATIN SMALL LETTER R WITH CEDILLA +0158 R # LATIN CAPITAL LETTER R WITH CARON +0159 r # LATIN SMALL LETTER R WITH CARON +015A ´S # LATIN CAPITAL LETTER S WITH ACUTE +015B ´s # LATIN SMALL LETTER S WITH ACUTE +015C ^S # LATIN CAPITAL LETTER S WITH CIRCUMFLEX +015D ^s # LATIN SMALL LETTER S WITH CIRCUMFLEX +015E S # LATIN CAPITAL LETTER S WITH CEDILLA +015F s # LATIN SMALL LETTER S WITH CEDILLA +0160 S # LATIN CAPITAL LETTER S WITH CARON +0161 s # LATIN SMALL LETTER S WITH CARON +0162 T # LATIN CAPITAL LETTER T WITH CEDILLA +0163 t # LATIN SMALL LETTER T WITH CEDILLA +0164 T # LATIN CAPITAL LETTER T WITH CARON +0165 t # LATIN SMALL LETTER T WITH CARON +0166 T # LATIN CAPITAL LETTER T WITH STROKE +0167 t # LATIN SMALL LETTER T WITH STROKE +0168 ~U # LATIN CAPITAL LETTER U WITH TILDE +0169 ~u # LATIN SMALL LETTER U WITH TILDE +016A U # LATIN CAPITAL LETTER U WITH MACRON +016B u # LATIN SMALL LETTER U WITH MACRON +016C U # LATIN CAPITAL LETTER U WITH BREVE +016D u # LATIN SMALL LETTER U WITH BREVE +016E U # LATIN CAPITAL LETTER U WITH RING ABOVE +016F u # LATIN SMALL LETTER U WITH RING ABOVE +0170 "U # LATIN CAPITAL LETTER U WITH DOUBLE ACUTE +0171 "u # LATIN SMALL LETTER U WITH DOUBLE ACUTE +0172 U # LATIN CAPITAL LETTER U WITH OGONEK +0173 u # LATIN SMALL LETTER U WITH OGONEK +0174 ^W # LATIN CAPITAL LETTER W WITH CIRCUMFLEX +0175 ^w # LATIN SMALL LETTER W WITH CIRCUMFLEX +0176 ^Y # LATIN CAPITAL LETTER Y WITH CIRCUMFLEX +0177 ^y # LATIN SMALL LETTER Y WITH CIRCUMFLEX +0178 "Y # LATIN CAPITAL LETTER Y WITH DIAERESIS +0179 ´Z # LATIN CAPITAL LETTER Z WITH ACUTE +017A ´z # LATIN SMALL LETTER Z WITH ACUTE +017B Z # LATIN CAPITAL LETTER Z WITH DOT ABOVE +017C z # LATIN SMALL LETTER Z WITH DOT ABOVE +017D Z # LATIN CAPITAL LETTER Z WITH CARON +017E z # LATIN SMALL LETTER Z WITH CARON +017F s # LATIN SMALL LETTER LONG S +018F # LATIN CAPITAL LETTER SCHWA +0192 f # LATIN SMALL LETTER F WITH HOOK +01C4 DŽ # LATIN CAPITAL LETTER DZ WITH CARON +01C5 Dž # LATIN CAPITAL LETTER D WITH SMALL LETTER Z WITH CARON +01C6 dž # LATIN SMALL LETTER DZ WITH CARON +01C7 LJ # LATIN CAPITAL LETTER LJ +01C8 Lj # LATIN CAPITAL LETTER L WITH SMALL LETTER J +01C9 lj # LATIN SMALL LETTER LJ +01CA NJ # LATIN CAPITAL LETTER NJ +01CB Nj # LATIN CAPITAL LETTER N WITH SMALL LETTER J +01CC nj # LATIN SMALL LETTER NJ +01F1 DZ # LATIN CAPITAL LETTER DZ +01F2 Dz # LATIN CAPITAL LETTER D WITH SMALL LETTER Z +01F3 dz # LATIN SMALL LETTER DZ +0218 S # LATIN CAPITAL LETTER S WITH COMMA BELOW +0219 s # LATIN SMALL LETTER S WITH COMMA BELOW +021A T # LATIN CAPITAL LETTER T WITH COMMA BELOW +021B t # LATIN SMALL LETTER T WITH COMMA BELOW +0259 # LATIN SMALL LETTER SCHWA +02B9 ′ # MODIFIER LETTER PRIME +02BA ″ # MODIFIER LETTER DOUBLE PRIME +02BB ‘ # MODIFIER LETTER TURNED COMMA +02BC ’ # MODIFIER LETTER APOSTROPHE +02BD ‛ # MODIFIER LETTER REVERSED COMMA +02C6 ^ # MODIFIER LETTER CIRCUMFLEX ACCENT +02C7 # CARON +02C8 ' # MODIFIER LETTER VERTICAL LINE +02C9 ¯ # MODIFIER LETTER MACRON +02CA ´ # MODIFIER LETTER ACUTE ACCENT +02CB ` # MODIFIER LETTER GRAVE ACCENT +02CD _ # MODIFIER LETTER LOW MACRON +02D8 # BREVE +02D9 # DOT ABOVE +02DA # RING ABOVE +02DB # OGONEK +02DC ~ # SMALL TILDE +02DD " # DOUBLE ACUTE ACCENT +0374 # GREEK NUMERAL SIGN +0375 # GREEK LOWER NUMERAL SIGN +037A # GREEK YPOGEGRAMMENI +037E # GREEK QUESTION MARK +0384 # GREEK TONOS +0385 # GREEK DIALYTIKA TONOS +0386 # GREEK CAPITAL LETTER ALPHA WITH TONOS +0387 # GREEK ANO TELEIA +0388 # GREEK CAPITAL LETTER EPSILON WITH TONOS +0389 # GREEK CAPITAL LETTER ETA WITH TONOS +038A # GREEK CAPITAL LETTER IOTA WITH TONOS +038C # GREEK CAPITAL LETTER OMICRON WITH TONOS +038E # GREEK CAPITAL LETTER UPSILON WITH TONOS +038F # GREEK CAPITAL LETTER OMEGA WITH TONOS +0390 # GREEK SMALL LETTER IOTA WITH DIALYTIKA AND TONOS +0391 # GREEK CAPITAL LETTER ALPHA +0392 # GREEK CAPITAL LETTER BETA +0393 # GREEK CAPITAL LETTER GAMMA +0394 # GREEK CAPITAL LETTER DELTA +0395 # GREEK CAPITAL LETTER EPSILON +0396 # GREEK CAPITAL LETTER ZETA +0397 # GREEK CAPITAL LETTER ETA +0398 # GREEK CAPITAL LETTER THETA +0399 # GREEK CAPITAL LETTER IOTA +039A # GREEK CAPITAL LETTER KAPPA +039B # GREEK CAPITAL LETTER LAMDA +039C # GREEK CAPITAL LETTER MU +039D # GREEK CAPITAL LETTER NU +039E # GREEK CAPITAL LETTER XI +039F # GREEK CAPITAL LETTER OMICRON +03A0 # GREEK CAPITAL LETTER PI +03A1 # GREEK CAPITAL LETTER RHO +03A3 # GREEK CAPITAL LETTER SIGMA +03A4 # GREEK CAPITAL LETTER TAU +03A5 # GREEK CAPITAL LETTER UPSILON +03A6 # GREEK CAPITAL LETTER PHI +03A7 # GREEK CAPITAL LETTER CHI +03A8 # GREEK CAPITAL LETTER PSI +03A9 # GREEK CAPITAL LETTER OMEGA +03AA # GREEK CAPITAL LETTER IOTA WITH DIALYTIKA +03AB # GREEK CAPITAL LETTER UPSILON WITH DIALYTIKA +03AC # GREEK SMALL LETTER ALPHA WITH TONOS +03AD # GREEK SMALL LETTER EPSILON WITH TONOS +03AE # GREEK SMALL LETTER ETA WITH TONOS +03AF # GREEK SMALL LETTER IOTA WITH TONOS +03B0 # GREEK SMALL LETTER UPSILON WITH DIALYTIKA AND TONOS +03B1 # GREEK SMALL LETTER ALPHA +03B2 # GREEK SMALL LETTER BETA +03B3 # GREEK SMALL LETTER GAMMA +03B4 # GREEK SMALL LETTER DELTA +03B5 # GREEK SMALL LETTER EPSILON +03B6 # GREEK SMALL LETTER ZETA +03B7 # GREEK SMALL LETTER ETA +03B8 # GREEK SMALL LETTER THETA +03B9 # GREEK SMALL LETTER IOTA +03BA # GREEK SMALL LETTER KAPPA +03BB # GREEK SMALL LETTER LAMDA +03BC # GREEK SMALL LETTER MU +03BD # GREEK SMALL LETTER NU +03BE # GREEK SMALL LETTER XI +03BF # GREEK SMALL LETTER OMICRON +03C0 # GREEK SMALL LETTER PI +03C1 # GREEK SMALL LETTER RHO +03C2 # GREEK SMALL LETTER FINAL SIGMA +03C3 # GREEK SMALL LETTER SIGMA +03C4 # GREEK SMALL LETTER TAU +03C5 # GREEK SMALL LETTER UPSILON +03C6 # GREEK SMALL LETTER PHI +03C7 # GREEK SMALL LETTER CHI +03C8 # GREEK SMALL LETTER PSI +03C9 # GREEK SMALL LETTER OMEGA +03CA # GREEK SMALL LETTER IOTA WITH DIALYTIKA +03CB # GREEK SMALL LETTER UPSILON WITH DIALYTIKA +03CC # GREEK SMALL LETTER OMICRON WITH TONOS +03CD # GREEK SMALL LETTER UPSILON WITH TONOS +03CE # GREEK SMALL LETTER OMEGA WITH TONOS +03D0 β # GREEK BETA SYMBOL +03D1 θ # GREEK THETA SYMBOL +03D2 Υ # GREEK UPSILON WITH HOOK SYMBOL +03D5 φ # GREEK PHI SYMBOL +03D6 π # GREEK PI SYMBOL +03F0 κ # GREEK KAPPA SYMBOL +03F1 ρ # GREEK RHO SYMBOL +03F2 ς # GREEK LUNATE SIGMA SYMBOL +03F4 Θ # GREEK CAPITAL THETA SYMBOL +03F5 ε # GREEK LUNATE EPSILON SYMBOL +03F9 Σ # GREEK CAPITAL LUNATE SIGMA SYMBOL +0401 # CYRILLIC CAPITAL LETTER IO +0402 # CYRILLIC CAPITAL LETTER DJE +0403 # CYRILLIC CAPITAL LETTER GJE +0404 # CYRILLIC CAPITAL LETTER UKRAINIAN IE +0405 # CYRILLIC CAPITAL LETTER DZE +0406 # CYRILLIC CAPITAL LETTER BYELORUSSIAN-UKRAINIAN I +0407 # CYRILLIC CAPITAL LETTER YI +0408 # CYRILLIC CAPITAL LETTER JE +0409 # CYRILLIC CAPITAL LETTER LJE +040A # CYRILLIC CAPITAL LETTER NJE +040B # CYRILLIC CAPITAL LETTER TSHE +040C # CYRILLIC CAPITAL LETTER KJE +040E # CYRILLIC CAPITAL LETTER SHORT U +040F # CYRILLIC CAPITAL LETTER DZHE +0410 # CYRILLIC CAPITAL LETTER A +0411 # CYRILLIC CAPITAL LETTER BE +0412 # CYRILLIC CAPITAL LETTER VE +0413 # CYRILLIC CAPITAL LETTER GHE +0414 # CYRILLIC CAPITAL LETTER DE +0415 # CYRILLIC CAPITAL LETTER IE +0416 # CYRILLIC CAPITAL LETTER ZHE +0417 # CYRILLIC CAPITAL LETTER ZE +0418 # CYRILLIC CAPITAL LETTER I +0419 # CYRILLIC CAPITAL LETTER SHORT I +041A # CYRILLIC CAPITAL LETTER KA +041B # CYRILLIC CAPITAL LETTER EL +041C # CYRILLIC CAPITAL LETTER EM +041D # CYRILLIC CAPITAL LETTER EN +041E # CYRILLIC CAPITAL LETTER O +041F # CYRILLIC CAPITAL LETTER PE +0420 # CYRILLIC CAPITAL LETTER ER +0421 # CYRILLIC CAPITAL LETTER ES +0422 # CYRILLIC CAPITAL LETTER TE +0423 # CYRILLIC CAPITAL LETTER U +0424 # CYRILLIC CAPITAL LETTER EF +0425 # CYRILLIC CAPITAL LETTER HA +0426 # CYRILLIC CAPITAL LETTER TSE +0427 # CYRILLIC CAPITAL LETTER CHE +0428 # CYRILLIC CAPITAL LETTER SHA +0429 # CYRILLIC CAPITAL LETTER SHCHA +042A # CYRILLIC CAPITAL LETTER HARD SIGN +042B # CYRILLIC CAPITAL LETTER YERU +042C # CYRILLIC CAPITAL LETTER SOFT SIGN +042D # CYRILLIC CAPITAL LETTER E +042E # CYRILLIC CAPITAL LETTER YU +042F # CYRILLIC CAPITAL LETTER YA +0430 # CYRILLIC SMALL LETTER A +0431 # CYRILLIC SMALL LETTER BE +0432 # CYRILLIC SMALL LETTER VE +0433 # CYRILLIC SMALL LETTER GHE +0434 # CYRILLIC SMALL LETTER DE +0435 # CYRILLIC SMALL LETTER IE +0436 # CYRILLIC SMALL LETTER ZHE +0437 # CYRILLIC SMALL LETTER ZE +0438 # CYRILLIC SMALL LETTER I +0439 # CYRILLIC SMALL LETTER SHORT I +043A # CYRILLIC SMALL LETTER KA +043B # CYRILLIC SMALL LETTER EL +043C # CYRILLIC SMALL LETTER EM +043D # CYRILLIC SMALL LETTER EN +043E # CYRILLIC SMALL LETTER O +043F # CYRILLIC SMALL LETTER PE +0440 # CYRILLIC SMALL LETTER ER +0441 # CYRILLIC SMALL LETTER ES +0442 # CYRILLIC SMALL LETTER TE +0443 # CYRILLIC SMALL LETTER U +0444 # CYRILLIC SMALL LETTER EF +0445 # CYRILLIC SMALL LETTER HA +0446 # CYRILLIC SMALL LETTER TSE +0447 # CYRILLIC SMALL LETTER CHE +0448 # CYRILLIC SMALL LETTER SHA +0449 # CYRILLIC SMALL LETTER SHCHA +044A # CYRILLIC SMALL LETTER HARD SIGN +044B # CYRILLIC SMALL LETTER YERU +044C # CYRILLIC SMALL LETTER SOFT SIGN +044D # CYRILLIC SMALL LETTER E +044E # CYRILLIC SMALL LETTER YU +044F # CYRILLIC SMALL LETTER YA +0451 # CYRILLIC SMALL LETTER IO +0452 # CYRILLIC SMALL LETTER DJE +0453 # CYRILLIC SMALL LETTER GJE +0454 # CYRILLIC SMALL LETTER UKRAINIAN IE +0455 # CYRILLIC SMALL LETTER DZE +0456 # CYRILLIC SMALL LETTER BYELORUSSIAN-UKRAINIAN I +0457 # CYRILLIC SMALL LETTER YI +0458 # CYRILLIC SMALL LETTER JE +0459 # CYRILLIC SMALL LETTER LJE +045A # CYRILLIC SMALL LETTER NJE +045B # CYRILLIC SMALL LETTER TSHE +045C # CYRILLIC SMALL LETTER KJE +045E # CYRILLIC SMALL LETTER SHORT U +045F # CYRILLIC SMALL LETTER DZHE +0490 # CYRILLIC CAPITAL LETTER GHE WITH UPTURN +0491 # CYRILLIC SMALL LETTER GHE WITH UPTURN +0587 եւ # ARMENIAN SMALL LIGATURE ECH YIWN +05D0 # HEBREW LETTER ALEF +05D1 # HEBREW LETTER BET +05D2 # HEBREW LETTER GIMEL +05D3 # HEBREW LETTER DALET +05D4 # HEBREW LETTER HE +05D5 # HEBREW LETTER VAV +05D6 # HEBREW LETTER ZAYIN +05D7 # HEBREW LETTER HET +05D8 # HEBREW LETTER TET +05D9 # HEBREW LETTER YOD +05DA # HEBREW LETTER FINAL KAF +05DB # HEBREW LETTER KAF +05DC # HEBREW LETTER LAMED +05DD # HEBREW LETTER FINAL MEM +05DE # HEBREW LETTER MEM +05DF # HEBREW LETTER FINAL NUN +05E0 # HEBREW LETTER NUN +05E1 # HEBREW LETTER SAMEKH +05E2 # HEBREW LETTER AYIN +05E3 # HEBREW LETTER FINAL PE +05E4 # HEBREW LETTER PE +05E5 # HEBREW LETTER FINAL TSADI +05E6 # HEBREW LETTER TSADI +05E7 # HEBREW LETTER QOF +05E8 # HEBREW LETTER RESH +05E9 # HEBREW LETTER SHIN +05EA # HEBREW LETTER TAV +05F0 וו # HEBREW LIGATURE YIDDISH DOUBLE VAV +05F1 וי # HEBREW LIGATURE YIDDISH VAV YOD +05F2 יי # HEBREW LIGATURE YIDDISH DOUBLE YOD +0675 اٴ # ARABIC LETTER HIGH HAMZA ALEF +0676 وٴ # ARABIC LETTER HIGH HAMZA WAW +0677 ۇٴ # ARABIC LETTER U WITH HAMZA ABOVE +0678 يٴ # ARABIC LETTER HIGH HAMZA YEH +0E33 ํา # THAI CHARACTER SARA AM +0EB3 ໍາ # LAO VOWEL SIGN AM +0EDC ຫນ # LAO HO NO +0EDD ຫມ # LAO HO MO +0F77 ྲཱྀ # TIBETAN VOWEL SIGN VOCALIC RR +0F79 ླཱྀ # TIBETAN VOWEL SIGN VOCALIC LL +1E02 B # LATIN CAPITAL LETTER B WITH DOT ABOVE +1E03 b # LATIN SMALL LETTER B WITH DOT ABOVE +1E0A D # LATIN CAPITAL LETTER D WITH DOT ABOVE +1E0B d # LATIN SMALL LETTER D WITH DOT ABOVE +1E1E F # LATIN CAPITAL LETTER F WITH DOT ABOVE +1E1F f # LATIN SMALL LETTER F WITH DOT ABOVE +1E40 M # LATIN CAPITAL LETTER M WITH DOT ABOVE +1E41 m # LATIN SMALL LETTER M WITH DOT ABOVE +1E56 P # LATIN CAPITAL LETTER P WITH DOT ABOVE +1E57 p # LATIN SMALL LETTER P WITH DOT ABOVE +1E60 S # LATIN CAPITAL LETTER S WITH DOT ABOVE +1E61 s # LATIN SMALL LETTER S WITH DOT ABOVE +1E6A T # LATIN CAPITAL LETTER T WITH DOT ABOVE +1E6B t # LATIN SMALL LETTER T WITH DOT ABOVE +1E80 `W # LATIN CAPITAL LETTER W WITH GRAVE +1E81 `w # LATIN SMALL LETTER W WITH GRAVE +1E82 ´W # LATIN CAPITAL LETTER W WITH ACUTE +1E83 ´w # LATIN SMALL LETTER W WITH ACUTE +1E84 "W # LATIN CAPITAL LETTER W WITH DIAERESIS +1E85 "w # LATIN SMALL LETTER W WITH DIAERESIS +1E9A aʾ # LATIN SMALL LETTER A WITH RIGHT HALF RING +1EF2 `Y # LATIN CAPITAL LETTER Y WITH GRAVE +1EF3 `y # LATIN SMALL LETTER Y WITH GRAVE +2002 # EN SPACE +2003 # EM SPACE +2004 # THREE-PER-EM SPACE +2005 # FOUR-PER-EM SPACE +2006 # SIX-PER-EM SPACE +2008 # PUNCTUATION SPACE +2009 # THIN SPACE +200A # HAIR SPACE +2010 - # HYPHEN +2011 - # NON-BREAKING HYPHEN +2012 - # FIGURE DASH +2013 - # EN DASH +2014 - # EM DASH +2015 - # HORIZONTAL BAR +2016 # DOUBLE VERTICAL LINE +2017 # DOUBLE LOW LINE +2018 ' # LEFT SINGLE QUOTATION MARK +2019 ' # RIGHT SINGLE QUOTATION MARK +201A , # SINGLE LOW-9 QUOTATION MARK +201B ' # SINGLE HIGH-REVERSED-9 QUOTATION MARK +201C " # LEFT DOUBLE QUOTATION MARK +201D " # RIGHT DOUBLE QUOTATION MARK +201E " # DOUBLE LOW-9 QUOTATION MARK +201F " # DOUBLE HIGH-REVERSED-9 QUOTATION MARK +2020 + # DAGGER +2021 # DOUBLE DAGGER +2022 o # BULLET +2024 . # ONE DOT LEADER +2025 .. # TWO DOT LEADER +2026 ... # HORIZONTAL ELLIPSIS +2030 o/oo # PER MILLE SIGN +2032 ´ # PRIME +2033 ´´ # DOUBLE PRIME +2034 ´´´ # TRIPLE PRIME +2036 ‵‵ # REVERSED DOUBLE PRIME +2037 ‵‵‵ # REVERSED TRIPLE PRIME +2039 < # SINGLE LEFT-POINTING ANGLE QUOTATION MARK +203A > # SINGLE RIGHT-POINTING ANGLE QUOTATION MARK +203C !! # DOUBLE EXCLAMATION MARK +203E # OVERLINE +2044 / # FRACTION SLASH +2047 ?? # DOUBLE QUESTION MARK +2048 ?! # QUESTION EXCLAMATION MARK +2049 !? # EXCLAMATION QUESTION MARK +2057 ´´´´ # QUADRUPLE PRIME +20A8 Rs # RUPEE SIGN +20AB Đồng # DONG SIGN +20AC EUR # EURO SIGN +2100 a/c # ACCOUNT OF +2101 a/s # ADDRESSED TO THE SUBJECT +2102 C # DOUBLE-STRUCK CAPITAL C +2103 °C # DEGREE CELSIUS +2105 c/o # CARE OF +2106 c/u # CADA UNA +2107 Ɛ # EULER CONSTANT +2109 °F # DEGREE FAHRENHEIT +210A g # SCRIPT SMALL G +210B H # SCRIPT CAPITAL H +210C H # BLACK-LETTER CAPITAL H +210D H # DOUBLE-STRUCK CAPITAL H +210E h # PLANCK CONSTANT +210F ħ # PLANCK CONSTANT OVER TWO PI +2110 I # SCRIPT CAPITAL I +2111 I # BLACK-LETTER CAPITAL I +2112 L # SCRIPT CAPITAL L +2113 l # SCRIPT SMALL L +2115 N # DOUBLE-STRUCK CAPITAL N +2116 No # NUMERO SIGN +2119 P # DOUBLE-STRUCK CAPITAL P +211A Q # DOUBLE-STRUCK CAPITAL Q +211B R # SCRIPT CAPITAL R +211C R # BLACK-LETTER CAPITAL R +211D R # DOUBLE-STRUCK CAPITAL R +2121 TEL # TELEPHONE SIGN +2122 TM # TRADE MARK SIGN +2124 Z # DOUBLE-STRUCK CAPITAL Z +2126 Ohm # OHM SIGN +2128 Z # BLACK-LETTER CAPITAL Z +212C B # SCRIPT CAPITAL B +212D C # BLACK-LETTER CAPITAL C +212E e # ESTIMATED SYMBOL +212F e # SCRIPT SMALL E +2130 E # SCRIPT CAPITAL E +2131 F # SCRIPT CAPITAL F +2133 M # SCRIPT CAPITAL M +2134 o # SCRIPT SMALL O +2135 א # ALEF SYMBOL +2136 ב # BET SYMBOL +2137 ג # GIMEL SYMBOL +2138 ד # DALET SYMBOL +2139 i # INFORMATION SOURCE +213B FAX # FACSIMILE SIGN +213D γ # DOUBLE-STRUCK SMALL GAMMA +213E Γ # DOUBLE-STRUCK CAPITAL GAMMA +213F Π # DOUBLE-STRUCK CAPITAL PI +2140 ∑ # DOUBLE-STRUCK N-ARY SUMMATION +2145 D # DOUBLE-STRUCK ITALIC CAPITAL D +2146 d # DOUBLE-STRUCK ITALIC SMALL D +2147 e # DOUBLE-STRUCK ITALIC SMALL E +2148 i # DOUBLE-STRUCK ITALIC SMALL I +2149 j # DOUBLE-STRUCK ITALIC SMALL J +2153 1⁄3 # VULGAR FRACTION ONE THIRD +2154 2⁄3 # VULGAR FRACTION TWO THIRDS +2155 1⁄5 # VULGAR FRACTION ONE FIFTH +2156 2⁄5 # VULGAR FRACTION TWO FIFTHS +2157 3⁄5 # VULGAR FRACTION THREE FIFTHS +2158 4⁄5 # VULGAR FRACTION FOUR FIFTHS +2159 1⁄6 # VULGAR FRACTION ONE SIXTH +215A 5⁄6 # VULGAR FRACTION FIVE SIXTHS +215B 1⁄8 # VULGAR FRACTION ONE EIGHTH +215C 3⁄8 # VULGAR FRACTION THREE EIGHTHS +215D 5⁄8 # VULGAR FRACTION FIVE EIGHTHS +215E 7⁄8 # VULGAR FRACTION SEVEN EIGHTHS +215F 1⁄ # FRACTION NUMERATOR ONE +2160 I # ROMAN NUMERAL ONE +2161 II # ROMAN NUMERAL TWO +2162 III # ROMAN NUMERAL THREE +2163 IV # ROMAN NUMERAL FOUR +2164 V # ROMAN NUMERAL FIVE +2165 VI # ROMAN NUMERAL SIX +2166 VII # ROMAN NUMERAL SEVEN +2167 VIII # ROMAN NUMERAL EIGHT +2168 IX # ROMAN NUMERAL NINE +2169 X # ROMAN NUMERAL TEN +216A XI # ROMAN NUMERAL ELEVEN +216B XII # ROMAN NUMERAL TWELVE +216C L # ROMAN NUMERAL FIFTY +216D C # ROMAN NUMERAL ONE HUNDRED +216E D # ROMAN NUMERAL FIVE HUNDRED +216F M # ROMAN NUMERAL ONE THOUSAND +2170 i # SMALL ROMAN NUMERAL ONE +2171 ii # SMALL ROMAN NUMERAL TWO +2172 iii # SMALL ROMAN NUMERAL THREE +2173 iv # SMALL ROMAN NUMERAL FOUR +2174 v # SMALL ROMAN NUMERAL FIVE +2175 vi # SMALL ROMAN NUMERAL SIX +2176 vii # SMALL ROMAN NUMERAL SEVEN +2177 viii # SMALL ROMAN NUMERAL EIGHT +2178 ix # SMALL ROMAN NUMERAL NINE +2179 x # SMALL ROMAN NUMERAL TEN +217A xi # SMALL ROMAN NUMERAL ELEVEN +217B xii # SMALL ROMAN NUMERAL TWELVE +217C l # SMALL ROMAN NUMERAL FIFTY +217D c # SMALL ROMAN NUMERAL ONE HUNDRED +217E d # SMALL ROMAN NUMERAL FIVE HUNDRED +217F m # SMALL ROMAN NUMERAL ONE THOUSAND +2190 <- # LEFTWARDS ARROW +2191 ^ # UPWARDS ARROW +2192 -> # RIGHTWARDS ARROW +2193 V # DOWNWARDS ARROW +2194 <-> # LEFT RIGHT ARROW +21D0 <= # LEFTWARDS DOUBLE ARROW +21D2 => # RIGHTWARDS DOUBLE ARROW +21D4 <=> # LEFT RIGHT DOUBLE ARROW +2212 - # MINUS SIGN +2215 / # DIVISION SLASH +2216 \ # SET MINUS +2217 * # ASTERISK OPERATOR +2219 • # BULLET OPERATOR +2223 | # DIVIDES +222C ∫∫ # DOUBLE INTEGRAL +222D ∫∫∫ # TRIPLE INTEGRAL +222F ∮∮ # SURFACE INTEGRAL +2230 ∮∮∮ # VOLUME INTEGRAL +2236 : # RATIO +223C ~ # TILDE OPERATOR +2260 /= # NOT EQUAL TO +2264 <= # LESS-THAN OR EQUAL TO +2265 >= # GREATER-THAN OR EQUAL TO +226A << # MUCH LESS-THAN +226B >> # MUCH GREATER-THAN +22C5 · # DOT OPERATOR +22D8 <<< # VERY MUCH LESS-THAN +22D9 >>> # VERY MUCH GREATER-THAN +22EF ··· # MIDLINE HORIZONTAL ELLIPSIS +2400 [NUL] # SYMBOL FOR NULL +2401 [SOH] # SYMBOL FOR START OF HEADING +2402 [STX] # SYMBOL FOR START OF TEXT +2403 [ETX] # SYMBOL FOR END OF TEXT +2404 [EOT] # SYMBOL FOR END OF TRANSMISSION +2405 [ENQ] # SYMBOL FOR ENQUIRY +2406 [ACK] # SYMBOL FOR ACKNOWLEDGE +2407 [BEL] # SYMBOL FOR BELL +2408 [BS] # SYMBOL FOR BACKSPACE +2409 [HT] # SYMBOL FOR HORIZONTAL TABULATION +240A [LF] # SYMBOL FOR LINE FEED +240B [VT] # SYMBOL FOR VERTICAL TABULATION +240C [FF] # SYMBOL FOR FORM FEED +240D [CR] # SYMBOL FOR CARRIAGE RETURN +240E [SO] # SYMBOL FOR SHIFT OUT +240F [SI] # SYMBOL FOR SHIFT IN +2410 [DLE] # SYMBOL FOR DATA LINK ESCAPE +2411 [DC1] # SYMBOL FOR DEVICE CONTROL ONE +2412 [DC2] # SYMBOL FOR DEVICE CONTROL TWO +2413 [DC3] # SYMBOL FOR DEVICE CONTROL THREE +2414 [DC4] # SYMBOL FOR DEVICE CONTROL FOUR +2415 [NAK] # SYMBOL FOR NEGATIVE ACKNOWLEDGE +2416 [SYN] # SYMBOL FOR SYNCHRONOUS IDLE +2417 [ETB] # SYMBOL FOR END OF TRANSMISSION BLOCK +2418 [CAN] # SYMBOL FOR CANCEL +2419 [EM] # SYMBOL FOR END OF MEDIUM +241A [SUB] # SYMBOL FOR SUBSTITUTE +241B [ESC] # SYMBOL FOR ESCAPE +241C [FS] # SYMBOL FOR FILE SEPARATOR +241D [GS] # SYMBOL FOR GROUP SEPARATOR +241E [RS] # SYMBOL FOR RECORD SEPARATOR +241F [US] # SYMBOL FOR UNIT SEPARATOR +2420 [SP] # SYMBOL FOR SPACE +2421 [DEL] # SYMBOL FOR DELETE +2424 [NL] # SYMBOL FOR NEWLINE +2460 (1) # CIRCLED DIGIT ONE +2461 (2) # CIRCLED DIGIT TWO +2462 (3) # CIRCLED DIGIT THREE +2463 (4) # CIRCLED DIGIT FOUR +2464 (5) # CIRCLED DIGIT FIVE +2465 (6) # CIRCLED DIGIT SIX +2466 (7) # CIRCLED DIGIT SEVEN +2467 (8) # CIRCLED DIGIT EIGHT +2468 (9) # CIRCLED DIGIT NINE +2469 (10) # CIRCLED NUMBER TEN +246A (11) # CIRCLED NUMBER ELEVEN +246B (12) # CIRCLED NUMBER TWELVE +246C (13) # CIRCLED NUMBER THIRTEEN +246D (14) # CIRCLED NUMBER FOURTEEN +246E (15) # CIRCLED NUMBER FIFTEEN +246F (16) # CIRCLED NUMBER SIXTEEN +2470 (17) # CIRCLED NUMBER SEVENTEEN +2471 (18) # CIRCLED NUMBER EIGHTEEN +2472 (19) # CIRCLED NUMBER NINETEEN +2473 (20) # CIRCLED NUMBER TWENTY +2474 (1) # PARENTHESIZED DIGIT ONE +2475 (2) # PARENTHESIZED DIGIT TWO +2476 (3) # PARENTHESIZED DIGIT THREE +2477 (4) # PARENTHESIZED DIGIT FOUR +2478 (5) # PARENTHESIZED DIGIT FIVE +2479 (6) # PARENTHESIZED DIGIT SIX +247A (7) # PARENTHESIZED DIGIT SEVEN +247B (8) # PARENTHESIZED DIGIT EIGHT +247C (9) # PARENTHESIZED DIGIT NINE +247D (10) # PARENTHESIZED NUMBER TEN +247E (11) # PARENTHESIZED NUMBER ELEVEN +247F (12) # PARENTHESIZED NUMBER TWELVE +2480 (13) # PARENTHESIZED NUMBER THIRTEEN +2481 (14) # PARENTHESIZED NUMBER FOURTEEN +2482 (15) # PARENTHESIZED NUMBER FIFTEEN +2483 (16) # PARENTHESIZED NUMBER SIXTEEN +2484 (17) # PARENTHESIZED NUMBER SEVENTEEN +2485 (18) # PARENTHESIZED NUMBER EIGHTEEN +2486 (19) # PARENTHESIZED NUMBER NINETEEN +2487 (20) # PARENTHESIZED NUMBER TWENTY +2488 1. # DIGIT ONE FULL STOP +2489 2. # DIGIT TWO FULL STOP +248A 3. # DIGIT THREE FULL STOP +248B 4. # DIGIT FOUR FULL STOP +248C 5. # DIGIT FIVE FULL STOP +248D 6. # DIGIT SIX FULL STOP +248E 7. # DIGIT SEVEN FULL STOP +248F 8. # DIGIT EIGHT FULL STOP +2490 9. # DIGIT NINE FULL STOP +2491 10. # NUMBER TEN FULL STOP +2492 11. # NUMBER ELEVEN FULL STOP +2493 12. # NUMBER TWELVE FULL STOP +2494 13. # NUMBER THIRTEEN FULL STOP +2495 14. # NUMBER FOURTEEN FULL STOP +2496 15. # NUMBER FIFTEEN FULL STOP +2497 16. # NUMBER SIXTEEN FULL STOP +2498 17. # NUMBER SEVENTEEN FULL STOP +2499 18. # NUMBER EIGHTEEN FULL STOP +249A 19. # NUMBER NINETEEN FULL STOP +249B 20. # NUMBER TWENTY FULL STOP +249C (a) # PARENTHESIZED LATIN SMALL LETTER A +249D (b) # PARENTHESIZED LATIN SMALL LETTER B +249E (c) # PARENTHESIZED LATIN SMALL LETTER C +249F (d) # PARENTHESIZED LATIN SMALL LETTER D +24A0 (e) # PARENTHESIZED LATIN SMALL LETTER E +24A1 (f) # PARENTHESIZED LATIN SMALL LETTER F +24A2 (g) # PARENTHESIZED LATIN SMALL LETTER G +24A3 (h) # PARENTHESIZED LATIN SMALL LETTER H +24A4 (i) # PARENTHESIZED LATIN SMALL LETTER I +24A5 (j) # PARENTHESIZED LATIN SMALL LETTER J +24A6 (k) # PARENTHESIZED LATIN SMALL LETTER K +24A7 (l) # PARENTHESIZED LATIN SMALL LETTER L +24A8 (m) # PARENTHESIZED LATIN SMALL LETTER M +24A9 (n) # PARENTHESIZED LATIN SMALL LETTER N +24AA (o) # PARENTHESIZED LATIN SMALL LETTER O +24AB (p) # PARENTHESIZED LATIN SMALL LETTER P +24AC (q) # PARENTHESIZED LATIN SMALL LETTER Q +24AD (r) # PARENTHESIZED LATIN SMALL LETTER R +24AE (s) # PARENTHESIZED LATIN SMALL LETTER S +24AF (t) # PARENTHESIZED LATIN SMALL LETTER T +24B0 (u) # PARENTHESIZED LATIN SMALL LETTER U +24B1 (v) # PARENTHESIZED LATIN SMALL LETTER V +24B2 (w) # PARENTHESIZED LATIN SMALL LETTER W +24B3 (x) # PARENTHESIZED LATIN SMALL LETTER X +24B4 (y) # PARENTHESIZED LATIN SMALL LETTER Y +24B5 (z) # PARENTHESIZED LATIN SMALL LETTER Z +24B6 (A) # CIRCLED LATIN CAPITAL LETTER A +24B7 (B) # CIRCLED LATIN CAPITAL LETTER B +24B8 (C) # CIRCLED LATIN CAPITAL LETTER C +24B9 (D) # CIRCLED LATIN CAPITAL LETTER D +24BA (E) # CIRCLED LATIN CAPITAL LETTER E +24BB (F) # CIRCLED LATIN CAPITAL LETTER F +24BC (G) # CIRCLED LATIN CAPITAL LETTER G +24BD (H) # CIRCLED LATIN CAPITAL LETTER H +24BE (I) # CIRCLED LATIN CAPITAL LETTER I +24BF (J) # CIRCLED LATIN CAPITAL LETTER J +24C0 (K) # CIRCLED LATIN CAPITAL LETTER K +24C1 (L) # CIRCLED LATIN CAPITAL LETTER L +24C2 (M) # CIRCLED LATIN CAPITAL LETTER M +24C3 (N) # CIRCLED LATIN CAPITAL LETTER N +24C4 (O) # CIRCLED LATIN CAPITAL LETTER O +24C5 (P) # CIRCLED LATIN CAPITAL LETTER P +24C6 (Q) # CIRCLED LATIN CAPITAL LETTER Q +24C7 (R) # CIRCLED LATIN CAPITAL LETTER R +24C8 (S) # CIRCLED LATIN CAPITAL LETTER S +24C9 (T) # CIRCLED LATIN CAPITAL LETTER T +24CA (U) # CIRCLED LATIN CAPITAL LETTER U +24CB (V) # CIRCLED LATIN CAPITAL LETTER V +24CC (W) # CIRCLED LATIN CAPITAL LETTER W +24CD (X) # CIRCLED LATIN CAPITAL LETTER X +24CE (Y) # CIRCLED LATIN CAPITAL LETTER Y +24CF (Z) # CIRCLED LATIN CAPITAL LETTER Z +24D0 (a) # CIRCLED LATIN SMALL LETTER A +24D1 (b) # CIRCLED LATIN SMALL LETTER B +24D2 (c) # CIRCLED LATIN SMALL LETTER C +24D3 (d) # CIRCLED LATIN SMALL LETTER D +24D4 (e) # CIRCLED LATIN SMALL LETTER E +24D5 (f) # CIRCLED LATIN SMALL LETTER F +24D6 (g) # CIRCLED LATIN SMALL LETTER G +24D7 (h) # CIRCLED LATIN SMALL LETTER H +24D8 (i) # CIRCLED LATIN SMALL LETTER I +24D9 (j) # CIRCLED LATIN SMALL LETTER J +24DA (k) # CIRCLED LATIN SMALL LETTER K +24DB (l) # CIRCLED LATIN SMALL LETTER L +24DC (m) # CIRCLED LATIN SMALL LETTER M +24DD (n) # CIRCLED LATIN SMALL LETTER N +24DE (o) # CIRCLED LATIN SMALL LETTER O +24DF (p) # CIRCLED LATIN SMALL LETTER P +24E0 (q) # CIRCLED LATIN SMALL LETTER Q +24E1 (r) # CIRCLED LATIN SMALL LETTER R +24E2 (s) # CIRCLED LATIN SMALL LETTER S +24E3 (t) # CIRCLED LATIN SMALL LETTER T +24E4 (u) # CIRCLED LATIN SMALL LETTER U +24E5 (v) # CIRCLED LATIN SMALL LETTER V +24E6 (w) # CIRCLED LATIN SMALL LETTER W +24E7 (x) # CIRCLED LATIN SMALL LETTER X +24E8 (y) # CIRCLED LATIN SMALL LETTER Y +24E9 (z) # CIRCLED LATIN SMALL LETTER Z +24EA (0) # CIRCLED DIGIT ZERO +2500 - # BOX DRAWINGS LIGHT HORIZONTAL +2502 | # BOX DRAWINGS LIGHT VERTICAL +250C + # BOX DRAWINGS LIGHT DOWN AND RIGHT +2510 + # BOX DRAWINGS LIGHT DOWN AND LEFT +2514 + # BOX DRAWINGS LIGHT UP AND RIGHT +2518 + # BOX DRAWINGS LIGHT UP AND LEFT +251C + # BOX DRAWINGS LIGHT VERTICAL AND RIGHT +2524 + # BOX DRAWINGS LIGHT VERTICAL AND LEFT +252C + # BOX DRAWINGS LIGHT DOWN AND HORIZONTAL +2534 + # BOX DRAWINGS LIGHT UP AND HORIZONTAL +253C + # BOX DRAWINGS LIGHT VERTICAL AND HORIZONTAL +2592 # MEDIUM SHADE +25AE # BLACK VERTICAL RECTANGLE +25C6 # BLACK DIAMOND +25E6 o # WHITE BULLET +266A # EIGHTH NOTE +2A0C ∫∫∫∫ # QUADRUPLE INTEGRAL OPERATOR +2A74 ::= # DOUBLE COLON EQUAL +2A75 == # TWO CONSECUTIVE EQUALS SIGNS +2A76 === # THREE CONSECUTIVE EQUALS SIGNS +2E9F 母 # CJK RADICAL MOTHER +2EF3 龟 # CJK RADICAL C-SIMPLIFIED TURTLE +2F00 一 # KANGXI RADICAL ONE +2F01 丨 # KANGXI RADICAL LINE +2F02 丶 # KANGXI RADICAL DOT +2F03 丿 # KANGXI RADICAL SLASH +2F04 乙 # KANGXI RADICAL SECOND +2F05 亅 # KANGXI RADICAL HOOK +2F06 二 # KANGXI RADICAL TWO +2F07 亠 # KANGXI RADICAL LID +2F08 人 # KANGXI RADICAL MAN +2F09 儿 # KANGXI RADICAL LEGS +2F0A 入 # KANGXI RADICAL ENTER +2F0B 八 # KANGXI RADICAL EIGHT +2F0C 冂 # KANGXI RADICAL DOWN BOX +2F0D 冖 # KANGXI RADICAL COVER +2F0E 冫 # KANGXI RADICAL ICE +2F0F 几 # KANGXI RADICAL TABLE +2F10 凵 # KANGXI RADICAL OPEN BOX +2F11 刀 # KANGXI RADICAL KNIFE +2F12 力 # KANGXI RADICAL POWER +2F13 勹 # KANGXI RADICAL WRAP +2F14 匕 # KANGXI RADICAL SPOON +2F15 匚 # KANGXI RADICAL RIGHT OPEN BOX +2F16 匸 # KANGXI RADICAL HIDING ENCLOSURE +2F17 十 # KANGXI RADICAL TEN +2F18 卜 # KANGXI RADICAL DIVINATION +2F19 卩 # KANGXI RADICAL SEAL +2F1A 厂 # KANGXI RADICAL CLIFF +2F1B 厶 # KANGXI RADICAL PRIVATE +2F1C 又 # KANGXI RADICAL AGAIN +2F1D 口 # KANGXI RADICAL MOUTH +2F1E 囗 # KANGXI RADICAL ENCLOSURE +2F1F 土 # KANGXI RADICAL EARTH +2F20 士 # KANGXI RADICAL SCHOLAR +2F21 夂 # KANGXI RADICAL GO +2F22 夊 # KANGXI RADICAL GO SLOWLY +2F23 夕 # KANGXI RADICAL EVENING +2F24 大 # KANGXI RADICAL BIG +2F25 女 # KANGXI RADICAL WOMAN +2F26 子 # KANGXI RADICAL CHILD +2F27 宀 # KANGXI RADICAL ROOF +2F28 寸 # KANGXI RADICAL INCH +2F29 小 # KANGXI RADICAL SMALL +2F2A 尢 # KANGXI RADICAL LAME +2F2B 尸 # KANGXI RADICAL CORPSE +2F2C 屮 # KANGXI RADICAL SPROUT +2F2D 山 # KANGXI RADICAL MOUNTAIN +2F2E 巛 # KANGXI RADICAL RIVER +2F2F 工 # KANGXI RADICAL WORK +2F30 己 # KANGXI RADICAL ONESELF +2F31 巾 # KANGXI RADICAL TURBAN +2F32 干 # KANGXI RADICAL DRY +2F33 幺 # KANGXI RADICAL SHORT THREAD +2F34 广 # KANGXI RADICAL DOTTED CLIFF +2F35 廴 # KANGXI RADICAL LONG STRIDE +2F36 廾 # KANGXI RADICAL TWO HANDS +2F37 弋 # KANGXI RADICAL SHOOT +2F38 弓 # KANGXI RADICAL BOW +2F39 彐 # KANGXI RADICAL SNOUT +2F3A 彡 # KANGXI RADICAL BRISTLE +2F3B 彳 # KANGXI RADICAL STEP +2F3C 心 # KANGXI RADICAL HEART +2F3D 戈 # KANGXI RADICAL HALBERD +2F3E 戶 # KANGXI RADICAL DOOR +2F3F 手 # KANGXI RADICAL HAND +2F40 支 # KANGXI RADICAL BRANCH +2F41 攴 # KANGXI RADICAL RAP +2F42 文 # KANGXI RADICAL SCRIPT +2F43 斗 # KANGXI RADICAL DIPPER +2F44 斤 # KANGXI RADICAL AXE +2F45 方 # KANGXI RADICAL SQUARE +2F46 无 # KANGXI RADICAL NOT +2F47 日 # KANGXI RADICAL SUN +2F48 曰 # KANGXI RADICAL SAY +2F49 月 # KANGXI RADICAL MOON +2F4A 木 # KANGXI RADICAL TREE +2F4B 欠 # KANGXI RADICAL LACK +2F4C 止 # KANGXI RADICAL STOP +2F4D 歹 # KANGXI RADICAL DEATH +2F4E 殳 # KANGXI RADICAL WEAPON +2F4F 毋 # KANGXI RADICAL DO NOT +2F50 比 # KANGXI RADICAL COMPARE +2F51 毛 # KANGXI RADICAL FUR +2F52 氏 # KANGXI RADICAL CLAN +2F53 气 # KANGXI RADICAL STEAM +2F54 水 # KANGXI RADICAL WATER +2F55 火 # KANGXI RADICAL FIRE +2F56 爪 # KANGXI RADICAL CLAW +2F57 父 # KANGXI RADICAL FATHER +2F58 爻 # KANGXI RADICAL DOUBLE X +2F59 爿 # KANGXI RADICAL HALF TREE TRUNK +2F5A 片 # KANGXI RADICAL SLICE +2F5B 牙 # KANGXI RADICAL FANG +2F5C 牛 # KANGXI RADICAL COW +2F5D 犬 # KANGXI RADICAL DOG +2F5E 玄 # KANGXI RADICAL PROFOUND +2F5F 玉 # KANGXI RADICAL JADE +2F60 瓜 # KANGXI RADICAL MELON +2F61 瓦 # KANGXI RADICAL TILE +2F62 甘 # KANGXI RADICAL SWEET +2F63 生 # KANGXI RADICAL LIFE +2F64 用 # KANGXI RADICAL USE +2F65 田 # KANGXI RADICAL FIELD +2F66 疋 # KANGXI RADICAL BOLT OF CLOTH +2F67 疒 # KANGXI RADICAL SICKNESS +2F68 癶 # KANGXI RADICAL DOTTED TENT +2F69 白 # KANGXI RADICAL WHITE +2F6A 皮 # KANGXI RADICAL SKIN +2F6B 皿 # KANGXI RADICAL DISH +2F6C 目 # KANGXI RADICAL EYE +2F6D 矛 # KANGXI RADICAL SPEAR +2F6E 矢 # KANGXI RADICAL ARROW +2F6F 石 # KANGXI RADICAL STONE +2F70 示 # KANGXI RADICAL SPIRIT +2F71 禸 # KANGXI RADICAL TRACK +2F72 禾 # KANGXI RADICAL GRAIN +2F73 穴 # KANGXI RADICAL CAVE +2F74 立 # KANGXI RADICAL STAND +2F75 竹 # KANGXI RADICAL BAMBOO +2F76 米 # KANGXI RADICAL RICE +2F77 糸 # KANGXI RADICAL SILK +2F78 缶 # KANGXI RADICAL JAR +2F79 网 # KANGXI RADICAL NET +2F7A 羊 # KANGXI RADICAL SHEEP +2F7B 羽 # KANGXI RADICAL FEATHER +2F7C 老 # KANGXI RADICAL OLD +2F7D 而 # KANGXI RADICAL AND +2F7E 耒 # KANGXI RADICAL PLOW +2F7F 耳 # KANGXI RADICAL EAR +2F80 聿 # KANGXI RADICAL BRUSH +2F81 肉 # KANGXI RADICAL MEAT +2F82 臣 # KANGXI RADICAL MINISTER +2F83 自 # KANGXI RADICAL SELF +2F84 至 # KANGXI RADICAL ARRIVE +2F85 臼 # KANGXI RADICAL MORTAR +2F86 舌 # KANGXI RADICAL TONGUE +2F87 舛 # KANGXI RADICAL OPPOSE +2F88 舟 # KANGXI RADICAL BOAT +2F89 艮 # KANGXI RADICAL STOPPING +2F8A 色 # KANGXI RADICAL COLOR +2F8B 艸 # KANGXI RADICAL GRASS +2F8C 虍 # KANGXI RADICAL TIGER +2F8D 虫 # KANGXI RADICAL INSECT +2F8E 血 # KANGXI RADICAL BLOOD +2F8F 行 # KANGXI RADICAL WALK ENCLOSURE +2F90 衣 # KANGXI RADICAL CLOTHES +2F91 襾 # KANGXI RADICAL WEST +2F92 見 # KANGXI RADICAL SEE +2F93 角 # KANGXI RADICAL HORN +2F94 言 # KANGXI RADICAL SPEECH +2F95 谷 # KANGXI RADICAL VALLEY +2F96 豆 # KANGXI RADICAL BEAN +2F97 豕 # KANGXI RADICAL PIG +2F98 豸 # KANGXI RADICAL BADGER +2F99 貝 # KANGXI RADICAL SHELL +2F9A 赤 # KANGXI RADICAL RED +2F9B 走 # KANGXI RADICAL RUN +2F9C 足 # KANGXI RADICAL FOOT +2F9D 身 # KANGXI RADICAL BODY +2F9E 車 # KANGXI RADICAL CART +2F9F 辛 # KANGXI RADICAL BITTER +2FA0 辰 # KANGXI RADICAL MORNING +2FA1 辵 # KANGXI RADICAL WALK +2FA2 邑 # KANGXI RADICAL CITY +2FA3 酉 # KANGXI RADICAL WINE +2FA4 釆 # KANGXI RADICAL DISTINGUISH +2FA5 里 # KANGXI RADICAL VILLAGE +2FA6 金 # KANGXI RADICAL GOLD +2FA7 長 # KANGXI RADICAL LONG +2FA8 門 # KANGXI RADICAL GATE +2FA9 阜 # KANGXI RADICAL MOUND +2FAA 隶 # KANGXI RADICAL SLAVE +2FAB 隹 # KANGXI RADICAL SHORT TAILED BIRD +2FAC 雨 # KANGXI RADICAL RAIN +2FAD 靑 # KANGXI RADICAL BLUE +2FAE 非 # KANGXI RADICAL WRONG +2FAF 面 # KANGXI RADICAL FACE +2FB0 革 # KANGXI RADICAL LEATHER +2FB1 韋 # KANGXI RADICAL TANNED LEATHER +2FB2 韭 # KANGXI RADICAL LEEK +2FB3 音 # KANGXI RADICAL SOUND +2FB4 頁 # KANGXI RADICAL LEAF +2FB5 風 # KANGXI RADICAL WIND +2FB6 飛 # KANGXI RADICAL FLY +2FB7 食 # KANGXI RADICAL EAT +2FB8 首 # KANGXI RADICAL HEAD +2FB9 香 # KANGXI RADICAL FRAGRANT +2FBA 馬 # KANGXI RADICAL HORSE +2FBB 骨 # KANGXI RADICAL BONE +2FBC 高 # KANGXI RADICAL TALL +2FBD 髟 # KANGXI RADICAL HAIR +2FBE 鬥 # KANGXI RADICAL FIGHT +2FBF 鬯 # KANGXI RADICAL SACRIFICIAL WINE +2FC0 鬲 # KANGXI RADICAL CAULDRON +2FC1 鬼 # KANGXI RADICAL GHOST +2FC2 魚 # KANGXI RADICAL FISH +2FC3 鳥 # KANGXI RADICAL BIRD +2FC4 鹵 # KANGXI RADICAL SALT +2FC5 鹿 # KANGXI RADICAL DEER +2FC6 麥 # KANGXI RADICAL WHEAT +2FC7 麻 # KANGXI RADICAL HEMP +2FC8 黃 # KANGXI RADICAL YELLOW +2FC9 黍 # KANGXI RADICAL MILLET +2FCA 黑 # KANGXI RADICAL BLACK +2FCB 黹 # KANGXI RADICAL EMBROIDERY +2FCC 黽 # KANGXI RADICAL FROG +2FCD 鼎 # KANGXI RADICAL TRIPOD +2FCE 鼓 # KANGXI RADICAL DRUM +2FCF 鼠 # KANGXI RADICAL RAT +2FD0 鼻 # KANGXI RADICAL NOSE +2FD1 齊 # KANGXI RADICAL EVEN +2FD2 齒 # KANGXI RADICAL TOOTH +2FD3 龍 # KANGXI RADICAL DRAGON +2FD4 龜 # KANGXI RADICAL TURTLE +2FD5 龠 # KANGXI RADICAL FLUTE +3000 # IDEOGRAPHIC SPACE +3036 〒 # CIRCLED POSTAL MARK +3038 十 # HANGZHOU NUMERAL TEN +3039 卄 # HANGZHOU NUMERAL TWENTY +303A 卅 # HANGZHOU NUMERAL THIRTY +3041 あ # HIRAGANA LETTER SMALL A +3043 い # HIRAGANA LETTER SMALL I +3045 う # HIRAGANA LETTER SMALL U +3047 え # HIRAGANA LETTER SMALL E +3049 お # HIRAGANA LETTER SMALL O +3063 つ # HIRAGANA LETTER SMALL TU +3083 や # HIRAGANA LETTER SMALL YA +3085 ゆ # HIRAGANA LETTER SMALL YU +3087 よ # HIRAGANA LETTER SMALL YO +308E わ # HIRAGANA LETTER SMALL WA +3095 か # HIRAGANA LETTER SMALL KA +3096 け # HIRAGANA LETTER SMALL KE +309B ゙ # KATAKANA-HIRAGANA VOICED SOUND MARK +309C ゚ # KATAKANA-HIRAGANA SEMI-VOICED SOUND MARK +30A0 = # KATAKANA-HIRAGANA DOUBLE HYPHEN +30A1 ア # KATAKANA LETTER SMALL A +30A3 イ # KATAKANA LETTER SMALL I +30A5 ウ # KATAKANA LETTER SMALL U +30A7 エ # KATAKANA LETTER SMALL E +30A9 オ # KATAKANA LETTER SMALL O +30C3 ツ # KATAKANA LETTER SMALL TU +30E3 ヤ # KATAKANA LETTER SMALL YA +30E5 ユ # KATAKANA LETTER SMALL YU +30E7 ヨ # KATAKANA LETTER SMALL YO +30EE ワ # KATAKANA LETTER SMALL WA +30F5 カ # KATAKANA LETTER SMALL KA +30F6 ケ # KATAKANA LETTER SMALL KE +3131 ᄀ # HANGUL LETTER KIYEOK +3132 ᄁ # HANGUL LETTER SSANGKIYEOK +3133 ᆪ # HANGUL LETTER KIYEOK-SIOS +3134 ᄂ # HANGUL LETTER NIEUN +3135 ᆬ # HANGUL LETTER NIEUN-CIEUC +3136 ᆭ # HANGUL LETTER NIEUN-HIEUH +3137 ᄃ # HANGUL LETTER TIKEUT +3138 ᄄ # HANGUL LETTER SSANGTIKEUT +3139 ᄅ # HANGUL LETTER RIEUL +313A ᆰ # HANGUL LETTER RIEUL-KIYEOK +313B ᆱ # HANGUL LETTER RIEUL-MIEUM +313C ᆲ # HANGUL LETTER RIEUL-PIEUP +313D ᆳ # HANGUL LETTER RIEUL-SIOS +313E ᆴ # HANGUL LETTER RIEUL-THIEUTH +313F ᆵ # HANGUL LETTER RIEUL-PHIEUPH +3140 ᄚ # HANGUL LETTER RIEUL-HIEUH +3141 ᄆ # HANGUL LETTER MIEUM +3142 ᄇ # HANGUL LETTER PIEUP +3143 ᄈ # HANGUL LETTER SSANGPIEUP +3144 ᄡ # HANGUL LETTER PIEUP-SIOS +3145 ᄉ # HANGUL LETTER SIOS +3146 ᄊ # HANGUL LETTER SSANGSIOS +3147 ᄋ # HANGUL LETTER IEUNG +3148 ᄌ # HANGUL LETTER CIEUC +3149 ᄍ # HANGUL LETTER SSANGCIEUC +314A ᄎ # HANGUL LETTER CHIEUCH +314B ᄏ # HANGUL LETTER KHIEUKH +314C ᄐ # HANGUL LETTER THIEUTH +314D ᄑ # HANGUL LETTER PHIEUPH +314E ᄒ # HANGUL LETTER HIEUH +314F ᅡ # HANGUL LETTER A +3150 ᅢ # HANGUL LETTER AE +3151 ᅣ # HANGUL LETTER YA +3152 ᅤ # HANGUL LETTER YAE +3153 ᅥ # HANGUL LETTER EO +3154 ᅦ # HANGUL LETTER E +3155 ᅧ # HANGUL LETTER YEO +3156 ᅨ # HANGUL LETTER YE +3157 ᅩ # HANGUL LETTER O +3158 ᅪ # HANGUL LETTER WA +3159 ᅫ # HANGUL LETTER WAE +315A ᅬ # HANGUL LETTER OE +315B ᅭ # HANGUL LETTER YO +315C ᅮ # HANGUL LETTER U +315D ᅯ # HANGUL LETTER WEO +315E ᅰ # HANGUL LETTER WE +315F ᅱ # HANGUL LETTER WI +3160 ᅲ # HANGUL LETTER YU +3161 ᅳ # HANGUL LETTER EU +3162 ᅴ # HANGUL LETTER YI +3163 ᅵ # HANGUL LETTER I +3164 ᅠ # HANGUL FILLER +3165 ᄔ # HANGUL LETTER SSANGNIEUN +3166 ᄕ # HANGUL LETTER NIEUN-TIKEUT +3167 ᇇ # HANGUL LETTER NIEUN-SIOS +3168 ᇈ # HANGUL LETTER NIEUN-PANSIOS +3169 ᇌ # HANGUL LETTER RIEUL-KIYEOK-SIOS +316A ᇎ # HANGUL LETTER RIEUL-TIKEUT +316B ᇓ # HANGUL LETTER RIEUL-PIEUP-SIOS +316C ᇗ # HANGUL LETTER RIEUL-PANSIOS +316D ᇙ # HANGUL LETTER RIEUL-YEORINHIEUH +316E ᄜ # HANGUL LETTER MIEUM-PIEUP +316F ᇝ # HANGUL LETTER MIEUM-SIOS +3170 ᇟ # HANGUL LETTER MIEUM-PANSIOS +3171 ᄝ # HANGUL LETTER KAPYEOUNMIEUM +3172 ᄞ # HANGUL LETTER PIEUP-KIYEOK +3173 ᄠ # HANGUL LETTER PIEUP-TIKEUT +3174 ᄢ # HANGUL LETTER PIEUP-SIOS-KIYEOK +3175 ᄣ # HANGUL LETTER PIEUP-SIOS-TIKEUT +3176 ᄧ # HANGUL LETTER PIEUP-CIEUC +3177 ᄩ # HANGUL LETTER PIEUP-THIEUTH +3178 ᄫ # HANGUL LETTER KAPYEOUNPIEUP +3179 ᄬ # HANGUL LETTER KAPYEOUNSSANGPIEUP +317A ᄭ # HANGUL LETTER SIOS-KIYEOK +317B ᄮ # HANGUL LETTER SIOS-NIEUN +317C ᄯ # HANGUL LETTER SIOS-TIKEUT +317D ᄲ # HANGUL LETTER SIOS-PIEUP +317E ᄶ # HANGUL LETTER SIOS-CIEUC +317F ᅀ # HANGUL LETTER PANSIOS +3180 ᅇ # HANGUL LETTER SSANGIEUNG +3181 ᅌ # HANGUL LETTER YESIEUNG +3182 ᇱ # HANGUL LETTER YESIEUNG-SIOS +3183 ᇲ # HANGUL LETTER YESIEUNG-PANSIOS +3184 ᅗ # HANGUL LETTER KAPYEOUNPHIEUPH +3185 ᅘ # HANGUL LETTER SSANGHIEUH +3186 ᅙ # HANGUL LETTER YEORINHIEUH +3187 ᆄ # HANGUL LETTER YO-YA +3188 ᆅ # HANGUL LETTER YO-YAE +3189 ᆈ # HANGUL LETTER YO-I +318A ᆑ # HANGUL LETTER YU-YEO +318B ᆒ # HANGUL LETTER YU-YE +318C ᆔ # HANGUL LETTER YU-I +318D ᆞ # HANGUL LETTER ARAEA +318E ᆡ # HANGUL LETTER ARAEAE +31F0 ク # KATAKANA LETTER SMALL KU +31F1 シ # KATAKANA LETTER SMALL SI +31F2 ス # KATAKANA LETTER SMALL SU +31F3 ト # KATAKANA LETTER SMALL TO +31F4 ヌ # KATAKANA LETTER SMALL NU +31F5 ハ # KATAKANA LETTER SMALL HA +31F6 ヒ # KATAKANA LETTER SMALL HI +31F7 フ # KATAKANA LETTER SMALL HU +31F8 ヘ # KATAKANA LETTER SMALL HE +31F9 ホ # KATAKANA LETTER SMALL HO +31FA ム # KATAKANA LETTER SMALL MU +31FB ラ # KATAKANA LETTER SMALL RA +31FC リ # KATAKANA LETTER SMALL RI +31FD ル # KATAKANA LETTER SMALL RU +31FE レ # KATAKANA LETTER SMALL RE +31FF ロ # KATAKANA LETTER SMALL RO +3200 (ᄀ) # PARENTHESIZED HANGUL KIYEOK +3201 (ᄂ) # PARENTHESIZED HANGUL NIEUN +3202 (ᄃ) # PARENTHESIZED HANGUL TIKEUT +3203 (ᄅ) # PARENTHESIZED HANGUL RIEUL +3204 (ᄆ) # PARENTHESIZED HANGUL MIEUM +3205 (ᄇ) # PARENTHESIZED HANGUL PIEUP +3206 (ᄉ) # PARENTHESIZED HANGUL SIOS +3207 (ᄋ) # PARENTHESIZED HANGUL IEUNG +3208 (ᄌ) # PARENTHESIZED HANGUL CIEUC +3209 (ᄎ) # PARENTHESIZED HANGUL CHIEUCH +320A (ᄏ) # PARENTHESIZED HANGUL KHIEUKH +320B (ᄐ) # PARENTHESIZED HANGUL THIEUTH +320C (ᄑ) # PARENTHESIZED HANGUL PHIEUPH +320D (ᄒ) # PARENTHESIZED HANGUL HIEUH +320E (가) # PARENTHESIZED HANGUL KIYEOK A +320F (나) # PARENTHESIZED HANGUL NIEUN A +3210 (다) # PARENTHESIZED HANGUL TIKEUT A +3211 (라) # PARENTHESIZED HANGUL RIEUL A +3212 (마) # PARENTHESIZED HANGUL MIEUM A +3213 (바) # PARENTHESIZED HANGUL PIEUP A +3214 (사) # PARENTHESIZED HANGUL SIOS A +3215 (아) # PARENTHESIZED HANGUL IEUNG A +3216 (자) # PARENTHESIZED HANGUL CIEUC A +3217 (차) # PARENTHESIZED HANGUL CHIEUCH A +3218 (카) # PARENTHESIZED HANGUL KHIEUKH A +3219 (타) # PARENTHESIZED HANGUL THIEUTH A +321A (파) # PARENTHESIZED HANGUL PHIEUPH A +321B (하) # PARENTHESIZED HANGUL HIEUH A +321C (주) # PARENTHESIZED HANGUL CIEUC U +321D (오전) # PARENTHESIZED KOREAN CHARACTER OJEON +321E (오후) # PARENTHESIZED KOREAN CHARACTER O HU +3220 (一) # PARENTHESIZED IDEOGRAPH ONE +3221 (二) # PARENTHESIZED IDEOGRAPH TWO +3222 (三) # PARENTHESIZED IDEOGRAPH THREE +3223 (四) # PARENTHESIZED IDEOGRAPH FOUR +3224 (五) # PARENTHESIZED IDEOGRAPH FIVE +3225 (六) # PARENTHESIZED IDEOGRAPH SIX +3226 (七) # PARENTHESIZED IDEOGRAPH SEVEN +3227 (八) # PARENTHESIZED IDEOGRAPH EIGHT +3228 (九) # PARENTHESIZED IDEOGRAPH NINE +3229 (十) # PARENTHESIZED IDEOGRAPH TEN +322A (月) # PARENTHESIZED IDEOGRAPH MOON +322B (火) # PARENTHESIZED IDEOGRAPH FIRE +322C (水) # PARENTHESIZED IDEOGRAPH WATER +322D (木) # PARENTHESIZED IDEOGRAPH WOOD +322E (金) # PARENTHESIZED IDEOGRAPH METAL +322F (土) # PARENTHESIZED IDEOGRAPH EARTH +3230 (日) # PARENTHESIZED IDEOGRAPH SUN +3231 (株) # PARENTHESIZED IDEOGRAPH STOCK +3232 (有) # PARENTHESIZED IDEOGRAPH HAVE +3233 (社) # PARENTHESIZED IDEOGRAPH SOCIETY +3234 (名) # PARENTHESIZED IDEOGRAPH NAME +3235 (特) # PARENTHESIZED IDEOGRAPH SPECIAL +3236 (財) # PARENTHESIZED IDEOGRAPH FINANCIAL +3237 (祝) # PARENTHESIZED IDEOGRAPH CONGRATULATION +3238 (労) # PARENTHESIZED IDEOGRAPH LABOR +3239 (代) # PARENTHESIZED IDEOGRAPH REPRESENT +323A (呼) # PARENTHESIZED IDEOGRAPH CALL +323B (学) # PARENTHESIZED IDEOGRAPH STUDY +323C (監) # PARENTHESIZED IDEOGRAPH SUPERVISE +323D (企) # PARENTHESIZED IDEOGRAPH ENTERPRISE +323E (資) # PARENTHESIZED IDEOGRAPH RESOURCE +323F (協) # PARENTHESIZED IDEOGRAPH ALLIANCE +3240 (祭) # PARENTHESIZED IDEOGRAPH FESTIVAL +3241 (休) # PARENTHESIZED IDEOGRAPH REST +3242 (自) # PARENTHESIZED IDEOGRAPH SELF +3243 (至) # PARENTHESIZED IDEOGRAPH REACH +3250 PTE # PARTNERSHIP SIGN +3251 (21) # CIRCLED NUMBER TWENTY ONE +3252 (22) # CIRCLED NUMBER TWENTY TWO +3253 (23) # CIRCLED NUMBER TWENTY THREE +3254 (24) # CIRCLED NUMBER TWENTY FOUR +3255 (25) # CIRCLED NUMBER TWENTY FIVE +3256 (26) # CIRCLED NUMBER TWENTY SIX +3257 (27) # CIRCLED NUMBER TWENTY SEVEN +3258 (28) # CIRCLED NUMBER TWENTY EIGHT +3259 (29) # CIRCLED NUMBER TWENTY NINE +325A (30) # CIRCLED NUMBER THIRTY +325B (31) # CIRCLED NUMBER THIRTY ONE +325C (32) # CIRCLED NUMBER THIRTY TWO +325D (33) # CIRCLED NUMBER THIRTY THREE +325E (34) # CIRCLED NUMBER THIRTY FOUR +325F (35) # CIRCLED NUMBER THIRTY FIVE +3260 (ᄀ) # CIRCLED HANGUL KIYEOK +3261 (ᄂ) # CIRCLED HANGUL NIEUN +3262 (ᄃ) # CIRCLED HANGUL TIKEUT +3263 (ᄅ) # CIRCLED HANGUL RIEUL +3264 (ᄆ) # CIRCLED HANGUL MIEUM +3265 (ᄇ) # CIRCLED HANGUL PIEUP +3266 (ᄉ) # CIRCLED HANGUL SIOS +3267 (ᄋ) # CIRCLED HANGUL IEUNG +3268 (ᄌ) # CIRCLED HANGUL CIEUC +3269 (ᄎ) # CIRCLED HANGUL CHIEUCH +326A (ᄏ) # CIRCLED HANGUL KHIEUKH +326B (ᄐ) # CIRCLED HANGUL THIEUTH +326C (ᄑ) # CIRCLED HANGUL PHIEUPH +326D (ᄒ) # CIRCLED HANGUL HIEUH +326E (가) # CIRCLED HANGUL KIYEOK A +326F (나) # CIRCLED HANGUL NIEUN A +3270 (다) # CIRCLED HANGUL TIKEUT A +3271 (라) # CIRCLED HANGUL RIEUL A +3272 (마) # CIRCLED HANGUL MIEUM A +3273 (바) # CIRCLED HANGUL PIEUP A +3274 (사) # CIRCLED HANGUL SIOS A +3275 (아) # CIRCLED HANGUL IEUNG A +3276 (자) # CIRCLED HANGUL CIEUC A +3277 (차) # CIRCLED HANGUL CHIEUCH A +3278 (카) # CIRCLED HANGUL KHIEUKH A +3279 (타) # CIRCLED HANGUL THIEUTH A +327A (파) # CIRCLED HANGUL PHIEUPH A +327B (하) # CIRCLED HANGUL HIEUH A +327C (참고) # CIRCLED KOREAN CHARACTER CHAMKO +327D (주의) # CIRCLED KOREAN CHARACTER JUEUI +3280 (一) # CIRCLED IDEOGRAPH ONE +3281 (二) # CIRCLED IDEOGRAPH TWO +3282 (三) # CIRCLED IDEOGRAPH THREE +3283 (四) # CIRCLED IDEOGRAPH FOUR +3284 (五) # CIRCLED IDEOGRAPH FIVE +3285 (六) # CIRCLED IDEOGRAPH SIX +3286 (七) # CIRCLED IDEOGRAPH SEVEN +3287 (八) # CIRCLED IDEOGRAPH EIGHT +3288 (九) # CIRCLED IDEOGRAPH NINE +3289 (十) # CIRCLED IDEOGRAPH TEN +328A (月) # CIRCLED IDEOGRAPH MOON +328B (火) # CIRCLED IDEOGRAPH FIRE +328C (水) # CIRCLED IDEOGRAPH WATER +328D (木) # CIRCLED IDEOGRAPH WOOD +328E (金) # CIRCLED IDEOGRAPH METAL +328F (土) # CIRCLED IDEOGRAPH EARTH +3290 (日) # CIRCLED IDEOGRAPH SUN +3291 (株) # CIRCLED IDEOGRAPH STOCK +3292 (有) # CIRCLED IDEOGRAPH HAVE +3293 (社) # CIRCLED IDEOGRAPH SOCIETY +3294 (名) # CIRCLED IDEOGRAPH NAME +3295 (特) # CIRCLED IDEOGRAPH SPECIAL +3296 (財) # CIRCLED IDEOGRAPH FINANCIAL +3297 (祝) # CIRCLED IDEOGRAPH CONGRATULATION +3298 (労) # CIRCLED IDEOGRAPH LABOR +3299 (秘) # CIRCLED IDEOGRAPH SECRET +329A (男) # CIRCLED IDEOGRAPH MALE +329B (女) # CIRCLED IDEOGRAPH FEMALE +329C (適) # CIRCLED IDEOGRAPH SUITABLE +329D (優) # CIRCLED IDEOGRAPH EXCELLENT +329E (印) # CIRCLED IDEOGRAPH PRINT +329F (注) # CIRCLED IDEOGRAPH ATTENTION +32A0 (項) # CIRCLED IDEOGRAPH ITEM +32A1 (休) # CIRCLED IDEOGRAPH REST +32A2 (写) # CIRCLED IDEOGRAPH COPY +32A3 (正) # CIRCLED IDEOGRAPH CORRECT +32A4 (上) # CIRCLED IDEOGRAPH HIGH +32A5 (中) # CIRCLED IDEOGRAPH CENTRE +32A6 (下) # CIRCLED IDEOGRAPH LOW +32A7 (左) # CIRCLED IDEOGRAPH LEFT +32A8 (右) # CIRCLED IDEOGRAPH RIGHT +32A9 (医) # CIRCLED IDEOGRAPH MEDICINE +32AA (宗) # CIRCLED IDEOGRAPH RELIGION +32AB (学) # CIRCLED IDEOGRAPH STUDY +32AC (監) # CIRCLED IDEOGRAPH SUPERVISE +32AD (企) # CIRCLED IDEOGRAPH ENTERPRISE +32AE (資) # CIRCLED IDEOGRAPH RESOURCE +32AF (協) # CIRCLED IDEOGRAPH ALLIANCE +32B0 (夜) # CIRCLED IDEOGRAPH NIGHT +32B1 (36) # CIRCLED NUMBER THIRTY SIX +32B2 (37) # CIRCLED NUMBER THIRTY SEVEN +32B3 (38) # CIRCLED NUMBER THIRTY EIGHT +32B4 (39) # CIRCLED NUMBER THIRTY NINE +32B5 (40) # CIRCLED NUMBER FORTY +32B6 (41) # CIRCLED NUMBER FORTY ONE +32B7 (42) # CIRCLED NUMBER FORTY TWO +32B8 (43) # CIRCLED NUMBER FORTY THREE +32B9 (44) # CIRCLED NUMBER FORTY FOUR +32BA (45) # CIRCLED NUMBER FORTY FIVE +32BB (46) # CIRCLED NUMBER FORTY SIX +32BC (47) # CIRCLED NUMBER FORTY SEVEN +32BD (48) # CIRCLED NUMBER FORTY EIGHT +32BE (49) # CIRCLED NUMBER FORTY NINE +32BF (50) # CIRCLED NUMBER FIFTY +32C0 1月 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR JANUARY +32C1 2月 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR FEBRUARY +32C2 3月 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR MARCH +32C3 4月 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR APRIL +32C4 5月 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR MAY +32C5 6月 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR JUNE +32C6 7月 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR JULY +32C7 8月 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR AUGUST +32C8 9月 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR SEPTEMBER +32C9 10月 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR OCTOBER +32CA 11月 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR NOVEMBER +32CB 12月 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DECEMBER +32CC Hg # SQUARE HG +32CD erg # SQUARE ERG +32CE eV # SQUARE EV +32CF LTD # LIMITED LIABILITY SIGN +32D0 (ア) # CIRCLED KATAKANA A +32D1 (イ) # CIRCLED KATAKANA I +32D2 (ウ) # CIRCLED KATAKANA U +32D3 (エ) # CIRCLED KATAKANA E +32D4 (オ) # CIRCLED KATAKANA O +32D5 (カ) # CIRCLED KATAKANA KA +32D6 (キ) # CIRCLED KATAKANA KI +32D7 (ク) # CIRCLED KATAKANA KU +32D8 (ケ) # CIRCLED KATAKANA KE +32D9 (コ) # CIRCLED KATAKANA KO +32DA (サ) # CIRCLED KATAKANA SA +32DB (シ) # CIRCLED KATAKANA SI +32DC (ス) # CIRCLED KATAKANA SU +32DD (セ) # CIRCLED KATAKANA SE +32DE (ソ) # CIRCLED KATAKANA SO +32DF (タ) # CIRCLED KATAKANA TA +32E0 (チ) # CIRCLED KATAKANA TI +32E1 (ツ) # CIRCLED KATAKANA TU +32E2 (テ) # CIRCLED KATAKANA TE +32E3 (ト) # CIRCLED KATAKANA TO +32E4 (ナ) # CIRCLED KATAKANA NA +32E5 (ニ) # CIRCLED KATAKANA NI +32E6 (ヌ) # CIRCLED KATAKANA NU +32E7 (ネ) # CIRCLED KATAKANA NE +32E8 (ノ) # CIRCLED KATAKANA NO +32E9 (ハ) # CIRCLED KATAKANA HA +32EA (ヒ) # CIRCLED KATAKANA HI +32EB (フ) # CIRCLED KATAKANA HU +32EC (ヘ) # CIRCLED KATAKANA HE +32ED (ホ) # CIRCLED KATAKANA HO +32EE (マ) # CIRCLED KATAKANA MA +32EF (ミ) # CIRCLED KATAKANA MI +32F0 (ム) # CIRCLED KATAKANA MU +32F1 (メ) # CIRCLED KATAKANA ME +32F2 (モ) # CIRCLED KATAKANA MO +32F3 (ヤ) # CIRCLED KATAKANA YA +32F4 (ユ) # CIRCLED KATAKANA YU +32F5 (ヨ) # CIRCLED KATAKANA YO +32F6 (ラ) # CIRCLED KATAKANA RA +32F7 (リ) # CIRCLED KATAKANA RI +32F8 (ル) # CIRCLED KATAKANA RU +32F9 (レ) # CIRCLED KATAKANA RE +32FA (ロ) # CIRCLED KATAKANA RO +32FB (ワ) # CIRCLED KATAKANA WA +32FC (ヰ) # CIRCLED KATAKANA WI +32FD (ヱ) # CIRCLED KATAKANA WE +32FE (ヲ) # CIRCLED KATAKANA WO +3300 アパート # SQUARE APAATO +3301 アルファ # SQUARE ARUHUA +3302 アンペア # SQUARE ANPEA +3303 アール # SQUARE AARU +3304 イニング # SQUARE ININGU +3305 インチ # SQUARE INTI +3306 ウォン # SQUARE UON +3307 エスクード # SQUARE ESUKUUDO +3308 エーカー # SQUARE EEKAA +3309 オンス # SQUARE ONSU +330A オーム # SQUARE OOMU +330B カイリ # SQUARE KAIRI +330C カラット # SQUARE KARATTO +330D カロリー # SQUARE KARORII +330E ガロン # SQUARE GARON +330F ガンマ # SQUARE GANMA +3310 ギガ # SQUARE GIGA +3311 ギニー # SQUARE GINII +3312 キュリー # SQUARE KYURII +3313 ギルダー # SQUARE GIRUDAA +3314 キロ # SQUARE KIRO +3315 キログラム # SQUARE KIROGURAMU +3316 キロメートル # SQUARE KIROMEETORU +3317 キロワット # SQUARE KIROWATTO +3318 グラム # SQUARE GURAMU +3319 グラムトン # SQUARE GURAMUTON +331A クルゼイロ # SQUARE KURUZEIRO +331B クローネ # SQUARE KUROONE +331C ケース # SQUARE KEESU +331D コルナ # SQUARE KORUNA +331E コーポ # SQUARE KOOPO +331F サイクル # SQUARE SAIKURU +3320 サンチーム # SQUARE SANTIIMU +3321 シリング # SQUARE SIRINGU +3322 センチ # SQUARE SENTI +3323 セント # SQUARE SENTO +3324 ダース # SQUARE DAASU +3325 デシ # SQUARE DESI +3326 ドル # SQUARE DORU +3327 トン # SQUARE TON +3328 ナノ # SQUARE NANO +3329 ノット # SQUARE NOTTO +332A ハイツ # SQUARE HAITU +332B パーセント # SQUARE PAASENTO +332C パーツ # SQUARE PAATU +332D バーレル # SQUARE BAARERU +332E ピアストル # SQUARE PIASUTORU +332F ピクル # SQUARE PIKURU +3330 ピコ # SQUARE PIKO +3331 ビル # SQUARE BIRU +3332 ファラッド # SQUARE HUARADDO +3333 フィート # SQUARE HUIITO +3334 ブッシェル # SQUARE BUSSYERU +3335 フラン # SQUARE HURAN +3336 ヘクタール # SQUARE HEKUTAARU +3337 ペソ # SQUARE PESO +3338 ペニヒ # SQUARE PENIHI +3339 ヘルツ # SQUARE HERUTU +333A ペンス # SQUARE PENSU +333B ページ # SQUARE PEEZI +333C ベータ # SQUARE BEETA +333D ポイント # SQUARE POINTO +333E ボルト # SQUARE BORUTO +333F ホン # SQUARE HON +3340 ポンド # SQUARE PONDO +3341 ホール # SQUARE HOORU +3342 ホーン # SQUARE HOON +3343 マイクロ # SQUARE MAIKURO +3344 マイル # SQUARE MAIRU +3345 マッハ # SQUARE MAHHA +3346 マルク # SQUARE MARUKU +3347 マンション # SQUARE MANSYON +3348 ミクロン # SQUARE MIKURON +3349 ミリ # SQUARE MIRI +334A ミリバール # SQUARE MIRIBAARU +334B メガ # SQUARE MEGA +334C メガトン # SQUARE MEGATON +334D メートル # SQUARE MEETORU +334E ヤード # SQUARE YAADO +334F ヤール # SQUARE YAARU +3350 ユアン # SQUARE YUAN +3351 リットル # SQUARE RITTORU +3352 リラ # SQUARE RIRA +3353 ルピー # SQUARE RUPII +3354 ルーブル # SQUARE RUUBURU +3355 レム # SQUARE REMU +3356 レントゲン # SQUARE RENTOGEN +3357 ワット # SQUARE WATTO +3358 0点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR ZERO +3359 1点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR ONE +335A 2点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR TWO +335B 3点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR THREE +335C 4点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR FOUR +335D 5点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR FIVE +335E 6点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR SIX +335F 7点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR SEVEN +3360 8点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR EIGHT +3361 9点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR NINE +3362 10点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR TEN +3363 11点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR ELEVEN +3364 12点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR TWELVE +3365 13点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR THIRTEEN +3366 14点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR FOURTEEN +3367 15点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR FIFTEEN +3368 16点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR SIXTEEN +3369 17点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR SEVENTEEN +336A 18点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR EIGHTEEN +336B 19点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR NINETEEN +336C 20点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR TWENTY +336D 21点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR TWENTY-ONE +336E 22点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR TWENTY-TWO +336F 23点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR TWENTY-THREE +3370 24点 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR HOUR TWENTY-FOUR +3371 hPa # SQUARE HPA +3372 da # SQUARE DA +3373 AU # SQUARE AU +3374 bar # SQUARE BAR +3375 oV # SQUARE OV +3376 pc # SQUARE PC +3377 dm # SQUARE DM +3378 dm^2 # SQUARE DM SQUARED +3379 dm^3 # SQUARE DM CUBED +337A IU # SQUARE IU +337B 平成 # SQUARE ERA NAME HEISEI +337C 昭和 # SQUARE ERA NAME SYOUWA +337D 大正 # SQUARE ERA NAME TAISYOU +337E 明治 # SQUARE ERA NAME MEIZI +337F 株式会社 # SQUARE CORPORATION +3380 pA # SQUARE PA AMPS +3381 nA # SQUARE NA +3382 μA # SQUARE MU A +3383 mA # SQUARE MA +3384 kA # SQUARE KA +3385 KB # SQUARE KB +3386 MB # SQUARE MB +3387 GB # SQUARE GB +3388 cal # SQUARE CAL +3389 kcal # SQUARE KCAL +338A pF # SQUARE PF +338B nF # SQUARE NF +338C μF # SQUARE MU F +338D μg # SQUARE MU G +338E mg # SQUARE MG +338F kg # SQUARE KG +3390 Hz # SQUARE HZ +3391 kHz # SQUARE KHZ +3392 MHz # SQUARE MHZ +3393 GHz # SQUARE GHZ +3394 THz # SQUARE THZ +3395 μl # SQUARE MU L +3396 ml # SQUARE ML +3397 dl # SQUARE DL +3398 kl # SQUARE KL +3399 fm # SQUARE FM +339A nm # SQUARE NM +339B μm # SQUARE MU M +339C mm # SQUARE MM +339D cm # SQUARE CM +339E km # SQUARE KM +339F mm^2 # SQUARE MM SQUARED +33A0 cm^2 # SQUARE CM SQUARED +33A1 m^2 # SQUARE M SQUARED +33A2 km^2 # SQUARE KM SQUARED +33A3 mm^3 # SQUARE MM CUBED +33A4 cm^3 # SQUARE CM CUBED +33A5 m^3 # SQUARE M CUBED +33A6 km^3 # SQUARE KM CUBED +33A7 m/s # SQUARE M OVER S +33A8 m/s^2 # SQUARE M OVER S SQUARED +33A9 Pa # SQUARE PA +33AA kPa # SQUARE KPA +33AB MPa # SQUARE MPA +33AC GPa # SQUARE GPA +33AD rad # SQUARE RAD +33AE rad/s # SQUARE RAD OVER S +33AF rad/s^2 # SQUARE RAD OVER S SQUARED +33B0 ps # SQUARE PS +33B1 ns # SQUARE NS +33B2 μs # SQUARE MU S +33B3 ms # SQUARE MS +33B4 pV # SQUARE PV +33B5 nV # SQUARE NV +33B6 μV # SQUARE MU V +33B7 mV # SQUARE MV +33B8 kV # SQUARE KV +33B9 MV # SQUARE MV MEGA +33BA pW # SQUARE PW +33BB nW # SQUARE NW +33BC μW # SQUARE MU W +33BD mW # SQUARE MW +33BE kW # SQUARE KW +33BF MW # SQUARE MW MEGA +33C0 kΩ # SQUARE K OHM +33C1 MΩ # SQUARE M OHM +33C2 a.m. # SQUARE AM +33C3 Bq # SQUARE BQ +33C4 cc # SQUARE CC +33C5 cd # SQUARE CD +33C6 C/kg # SQUARE C OVER KG +33C7 Co. # SQUARE CO +33C8 dB # SQUARE DB +33C9 Gy # SQUARE GY +33CA ha # SQUARE HA +33CB HP # SQUARE HP +33CC in # SQUARE IN +33CD KK # SQUARE KK +33CE KM # SQUARE KM CAPITAL +33CF kt # SQUARE KT +33D0 lm # SQUARE LM +33D1 ln # SQUARE LN +33D2 log # SQUARE LOG +33D3 lx # SQUARE LX +33D4 mb # SQUARE MB SMALL +33D5 mil # SQUARE MIL +33D6 mol # SQUARE MOL +33D7 PH # SQUARE PH +33D8 p.m. # SQUARE PM +33D9 PPM # SQUARE PPM +33DA PR # SQUARE PR +33DB sr # SQUARE SR +33DC Sv # SQUARE SV +33DD Wb # SQUARE WB +33DE V/m # SQUARE V OVER M +33DF A/m # SQUARE A OVER M +33FF gal # SQUARE GAL +33E0 1日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY ONE +33E1 2日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TWO +33E2 3日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY THREE +33E3 4日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY FOUR +33E4 5日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY FIVE +33E5 6日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY SIX +33E6 7日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY SEVEN +33E7 8日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY EIGHT +33E8 9日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY NINE +33E9 10日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TEN +33EA 11日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY ELEVEN +33EB 12日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TWELVE +33EC 13日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY THIRTEEN +33ED 14日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY FOURTEEN +33EE 15日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY FIFTEEN +33EF 16日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY SIXTEEN +33F0 17日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY SEVENTEEN +33F1 18日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY EIGHTEEN +33F2 19日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY NINETEEN +33F3 20日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TWENTY +33F4 21日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TWENTY-ONE +33F5 22日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TWENTY-TWO +33F6 23日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TWENTY-THREE +33F7 24日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TWENTY-FOUR +33F8 25日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TWENTY-FIVE +33F9 26日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TWENTY-SIX +33FA 27日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TWENTY-SEVEN +33FB 28日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TWENTY-EIGHT +33FC 29日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY TWENTY-NINE +33FD 30日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY THIRTY +33FE 31日 # IDEOGRAPHIC TELEGRAPH SYMBOL FOR DAY THIRTY-ONE +F900 豈 # CJK COMPATIBILITY IDEOGRAPH-F900 +F901 更 # CJK COMPATIBILITY IDEOGRAPH-F901 +F902 車 # CJK COMPATIBILITY IDEOGRAPH-F902 +F903 賈 # CJK COMPATIBILITY IDEOGRAPH-F903 +F904 滑 # CJK COMPATIBILITY IDEOGRAPH-F904 +F905 串 # CJK COMPATIBILITY IDEOGRAPH-F905 +F906 句 # CJK COMPATIBILITY IDEOGRAPH-F906 +F907 龜 # CJK COMPATIBILITY IDEOGRAPH-F907 +F908 龜 # CJK COMPATIBILITY IDEOGRAPH-F908 +F909 契 # CJK COMPATIBILITY IDEOGRAPH-F909 +F90A 金 # CJK COMPATIBILITY IDEOGRAPH-F90A +F90B 喇 # CJK COMPATIBILITY IDEOGRAPH-F90B +F90C 奈 # CJK COMPATIBILITY IDEOGRAPH-F90C +F90D 懶 # CJK COMPATIBILITY IDEOGRAPH-F90D +F90E 癩 # CJK COMPATIBILITY IDEOGRAPH-F90E +F90F 羅 # CJK COMPATIBILITY IDEOGRAPH-F90F +F910 蘿 # CJK COMPATIBILITY IDEOGRAPH-F910 +F911 螺 # CJK COMPATIBILITY IDEOGRAPH-F911 +F912 裸 # CJK COMPATIBILITY IDEOGRAPH-F912 +F913 邏 # CJK COMPATIBILITY IDEOGRAPH-F913 +F914 樂 # CJK COMPATIBILITY IDEOGRAPH-F914 +F915 洛 # CJK COMPATIBILITY IDEOGRAPH-F915 +F916 烙 # CJK COMPATIBILITY IDEOGRAPH-F916 +F917 珞 # CJK COMPATIBILITY IDEOGRAPH-F917 +F918 落 # CJK COMPATIBILITY IDEOGRAPH-F918 +F919 酪 # CJK COMPATIBILITY IDEOGRAPH-F919 +F91A 駱 # CJK COMPATIBILITY IDEOGRAPH-F91A +F91B 亂 # CJK COMPATIBILITY IDEOGRAPH-F91B +F91C 卵 # CJK COMPATIBILITY IDEOGRAPH-F91C +F91D 欄 # CJK COMPATIBILITY IDEOGRAPH-F91D +F91E 爛 # CJK COMPATIBILITY IDEOGRAPH-F91E +F91F 蘭 # CJK COMPATIBILITY IDEOGRAPH-F91F +F920 鸞 # CJK COMPATIBILITY IDEOGRAPH-F920 +F921 嵐 # CJK COMPATIBILITY IDEOGRAPH-F921 +F922 濫 # CJK COMPATIBILITY IDEOGRAPH-F922 +F923 藍 # CJK COMPATIBILITY IDEOGRAPH-F923 +F924 襤 # CJK COMPATIBILITY IDEOGRAPH-F924 +F925 拉 # CJK COMPATIBILITY IDEOGRAPH-F925 +F926 臘 # CJK COMPATIBILITY IDEOGRAPH-F926 +F927 蠟 # CJK COMPATIBILITY IDEOGRAPH-F927 +F928 廊 # CJK COMPATIBILITY IDEOGRAPH-F928 +F929 朗 # CJK COMPATIBILITY IDEOGRAPH-F929 +F92A 浪 # CJK COMPATIBILITY IDEOGRAPH-F92A +F92B 狼 # CJK COMPATIBILITY IDEOGRAPH-F92B +F92C 郎 # CJK COMPATIBILITY IDEOGRAPH-F92C +F92D 來 # CJK COMPATIBILITY IDEOGRAPH-F92D +F92E 冷 # CJK COMPATIBILITY IDEOGRAPH-F92E +F92F 勞 # CJK COMPATIBILITY IDEOGRAPH-F92F +F930 擄 # CJK COMPATIBILITY IDEOGRAPH-F930 +F931 櫓 # CJK COMPATIBILITY IDEOGRAPH-F931 +F932 爐 # CJK COMPATIBILITY IDEOGRAPH-F932 +F933 盧 # CJK COMPATIBILITY IDEOGRAPH-F933 +F934 老 # CJK COMPATIBILITY IDEOGRAPH-F934 +F935 蘆 # CJK COMPATIBILITY IDEOGRAPH-F935 +F936 虜 # CJK COMPATIBILITY IDEOGRAPH-F936 +F937 路 # CJK COMPATIBILITY IDEOGRAPH-F937 +F938 露 # CJK COMPATIBILITY IDEOGRAPH-F938 +F939 魯 # CJK COMPATIBILITY IDEOGRAPH-F939 +F93A 鷺 # CJK COMPATIBILITY IDEOGRAPH-F93A +F93B 碌 # CJK COMPATIBILITY IDEOGRAPH-F93B +F93C 祿 # CJK COMPATIBILITY IDEOGRAPH-F93C +F93D 綠 # CJK COMPATIBILITY IDEOGRAPH-F93D +F93E 菉 # CJK COMPATIBILITY IDEOGRAPH-F93E +F93F 錄 # CJK COMPATIBILITY IDEOGRAPH-F93F +F940 鹿 # CJK COMPATIBILITY IDEOGRAPH-F940 +F941 論 # CJK COMPATIBILITY IDEOGRAPH-F941 +F942 壟 # CJK COMPATIBILITY IDEOGRAPH-F942 +F943 弄 # CJK COMPATIBILITY IDEOGRAPH-F943 +F944 籠 # CJK COMPATIBILITY IDEOGRAPH-F944 +F945 聾 # CJK COMPATIBILITY IDEOGRAPH-F945 +F946 牢 # CJK COMPATIBILITY IDEOGRAPH-F946 +F947 磊 # CJK COMPATIBILITY IDEOGRAPH-F947 +F948 賂 # CJK COMPATIBILITY IDEOGRAPH-F948 +F949 雷 # CJK COMPATIBILITY IDEOGRAPH-F949 +F94A 壘 # CJK COMPATIBILITY IDEOGRAPH-F94A +F94B 屢 # CJK COMPATIBILITY IDEOGRAPH-F94B +F94C 樓 # CJK COMPATIBILITY IDEOGRAPH-F94C +F94D 淚 # CJK COMPATIBILITY IDEOGRAPH-F94D +F94E 漏 # CJK COMPATIBILITY IDEOGRAPH-F94E +F94F 累 # CJK COMPATIBILITY IDEOGRAPH-F94F +F950 縷 # CJK COMPATIBILITY IDEOGRAPH-F950 +F951 陋 # CJK COMPATIBILITY IDEOGRAPH-F951 +F952 勒 # CJK COMPATIBILITY IDEOGRAPH-F952 +F953 肋 # CJK COMPATIBILITY IDEOGRAPH-F953 +F954 凜 # CJK COMPATIBILITY IDEOGRAPH-F954 +F955 凌 # CJK COMPATIBILITY IDEOGRAPH-F955 +F956 稜 # CJK COMPATIBILITY IDEOGRAPH-F956 +F957 綾 # CJK COMPATIBILITY IDEOGRAPH-F957 +F958 菱 # CJK COMPATIBILITY IDEOGRAPH-F958 +F959 陵 # CJK COMPATIBILITY IDEOGRAPH-F959 +F95A 讀 # CJK COMPATIBILITY IDEOGRAPH-F95A +F95B 拏 # CJK COMPATIBILITY IDEOGRAPH-F95B +F95C 樂 # CJK COMPATIBILITY IDEOGRAPH-F95C +F95D 諾 # CJK COMPATIBILITY IDEOGRAPH-F95D +F95E 丹 # CJK COMPATIBILITY IDEOGRAPH-F95E +F95F 寧 # CJK COMPATIBILITY IDEOGRAPH-F95F +F960 怒 # CJK COMPATIBILITY IDEOGRAPH-F960 +F961 率 # CJK COMPATIBILITY IDEOGRAPH-F961 +F962 異 # CJK COMPATIBILITY IDEOGRAPH-F962 +F963 北 # CJK COMPATIBILITY IDEOGRAPH-F963 +F964 磻 # CJK COMPATIBILITY IDEOGRAPH-F964 +F965 便 # CJK COMPATIBILITY IDEOGRAPH-F965 +F966 復 # CJK COMPATIBILITY IDEOGRAPH-F966 +F967 不 # CJK COMPATIBILITY IDEOGRAPH-F967 +F968 泌 # CJK COMPATIBILITY IDEOGRAPH-F968 +F969 數 # CJK COMPATIBILITY IDEOGRAPH-F969 +F96A 索 # CJK COMPATIBILITY IDEOGRAPH-F96A +F96B 參 # CJK COMPATIBILITY IDEOGRAPH-F96B +F96C 塞 # CJK COMPATIBILITY IDEOGRAPH-F96C +F96D 省 # CJK COMPATIBILITY IDEOGRAPH-F96D +F96E 葉 # CJK COMPATIBILITY IDEOGRAPH-F96E +F96F 說 # CJK COMPATIBILITY IDEOGRAPH-F96F +F970 殺 # CJK COMPATIBILITY IDEOGRAPH-F970 +F971 辰 # CJK COMPATIBILITY IDEOGRAPH-F971 +F972 沈 # CJK COMPATIBILITY IDEOGRAPH-F972 +F973 拾 # CJK COMPATIBILITY IDEOGRAPH-F973 +F974 若 # CJK COMPATIBILITY IDEOGRAPH-F974 +F975 掠 # CJK COMPATIBILITY IDEOGRAPH-F975 +F976 略 # CJK COMPATIBILITY IDEOGRAPH-F976 +F977 亮 # CJK COMPATIBILITY IDEOGRAPH-F977 +F978 兩 # CJK COMPATIBILITY IDEOGRAPH-F978 +F979 凉 # CJK COMPATIBILITY IDEOGRAPH-F979 +F97A 梁 # CJK COMPATIBILITY IDEOGRAPH-F97A +F97B 糧 # CJK COMPATIBILITY IDEOGRAPH-F97B +F97C 良 # CJK COMPATIBILITY IDEOGRAPH-F97C +F97D 諒 # CJK COMPATIBILITY IDEOGRAPH-F97D +F97E 量 # CJK COMPATIBILITY IDEOGRAPH-F97E +F97F 勵 # CJK COMPATIBILITY IDEOGRAPH-F97F +F980 呂 # CJK COMPATIBILITY IDEOGRAPH-F980 +F981 女 # CJK COMPATIBILITY IDEOGRAPH-F981 +F982 廬 # CJK COMPATIBILITY IDEOGRAPH-F982 +F983 旅 # CJK COMPATIBILITY IDEOGRAPH-F983 +F984 濾 # CJK COMPATIBILITY IDEOGRAPH-F984 +F985 礪 # CJK COMPATIBILITY IDEOGRAPH-F985 +F986 閭 # CJK COMPATIBILITY IDEOGRAPH-F986 +F987 驪 # CJK COMPATIBILITY IDEOGRAPH-F987 +F988 麗 # CJK COMPATIBILITY IDEOGRAPH-F988 +F989 黎 # CJK COMPATIBILITY IDEOGRAPH-F989 +F98A 力 # CJK COMPATIBILITY IDEOGRAPH-F98A +F98B 曆 # CJK COMPATIBILITY IDEOGRAPH-F98B +F98C 歷 # CJK COMPATIBILITY IDEOGRAPH-F98C +F98D 轢 # CJK COMPATIBILITY IDEOGRAPH-F98D +F98E 年 # CJK COMPATIBILITY IDEOGRAPH-F98E +F98F 憐 # CJK COMPATIBILITY IDEOGRAPH-F98F +F990 戀 # CJK COMPATIBILITY IDEOGRAPH-F990 +F991 撚 # CJK COMPATIBILITY IDEOGRAPH-F991 +F992 漣 # CJK COMPATIBILITY IDEOGRAPH-F992 +F993 煉 # CJK COMPATIBILITY IDEOGRAPH-F993 +F994 璉 # CJK COMPATIBILITY IDEOGRAPH-F994 +F995 秊 # CJK COMPATIBILITY IDEOGRAPH-F995 +F996 練 # CJK COMPATIBILITY IDEOGRAPH-F996 +F997 聯 # CJK COMPATIBILITY IDEOGRAPH-F997 +F998 輦 # CJK COMPATIBILITY IDEOGRAPH-F998 +F999 蓮 # CJK COMPATIBILITY IDEOGRAPH-F999 +F99A 連 # CJK COMPATIBILITY IDEOGRAPH-F99A +F99B 鍊 # CJK COMPATIBILITY IDEOGRAPH-F99B +F99C 列 # CJK COMPATIBILITY IDEOGRAPH-F99C +F99D 劣 # CJK COMPATIBILITY IDEOGRAPH-F99D +F99E 咽 # CJK COMPATIBILITY IDEOGRAPH-F99E +F99F 烈 # CJK COMPATIBILITY IDEOGRAPH-F99F +F9A0 裂 # CJK COMPATIBILITY IDEOGRAPH-F9A0 +F9A1 說 # CJK COMPATIBILITY IDEOGRAPH-F9A1 +F9A2 廉 # CJK COMPATIBILITY IDEOGRAPH-F9A2 +F9A3 念 # CJK COMPATIBILITY IDEOGRAPH-F9A3 +F9A4 捻 # CJK COMPATIBILITY IDEOGRAPH-F9A4 +F9A5 殮 # CJK COMPATIBILITY IDEOGRAPH-F9A5 +F9A6 簾 # CJK COMPATIBILITY IDEOGRAPH-F9A6 +F9A7 獵 # CJK COMPATIBILITY IDEOGRAPH-F9A7 +F9A8 令 # CJK COMPATIBILITY IDEOGRAPH-F9A8 +F9A9 囹 # CJK COMPATIBILITY IDEOGRAPH-F9A9 +F9AA 寧 # CJK COMPATIBILITY IDEOGRAPH-F9AA +F9AB 嶺 # CJK COMPATIBILITY IDEOGRAPH-F9AB +F9AC 怜 # CJK COMPATIBILITY IDEOGRAPH-F9AC +F9AD 玲 # CJK COMPATIBILITY IDEOGRAPH-F9AD +F9AE 瑩 # CJK COMPATIBILITY IDEOGRAPH-F9AE +F9AF 羚 # CJK COMPATIBILITY IDEOGRAPH-F9AF +F9B0 聆 # CJK COMPATIBILITY IDEOGRAPH-F9B0 +F9B1 鈴 # CJK COMPATIBILITY IDEOGRAPH-F9B1 +F9B2 零 # CJK COMPATIBILITY IDEOGRAPH-F9B2 +F9B3 靈 # CJK COMPATIBILITY IDEOGRAPH-F9B3 +F9B4 領 # CJK COMPATIBILITY IDEOGRAPH-F9B4 +F9B5 例 # CJK COMPATIBILITY IDEOGRAPH-F9B5 +F9B6 禮 # CJK COMPATIBILITY IDEOGRAPH-F9B6 +F9B7 醴 # CJK COMPATIBILITY IDEOGRAPH-F9B7 +F9B8 隸 # CJK COMPATIBILITY IDEOGRAPH-F9B8 +F9B9 惡 # CJK COMPATIBILITY IDEOGRAPH-F9B9 +F9BA 了 # CJK COMPATIBILITY IDEOGRAPH-F9BA +F9BB 僚 # CJK COMPATIBILITY IDEOGRAPH-F9BB +F9BC 寮 # CJK COMPATIBILITY IDEOGRAPH-F9BC +F9BD 尿 # CJK COMPATIBILITY IDEOGRAPH-F9BD +F9BE 料 # CJK COMPATIBILITY IDEOGRAPH-F9BE +F9BF 樂 # CJK COMPATIBILITY IDEOGRAPH-F9BF +F9C0 燎 # CJK COMPATIBILITY IDEOGRAPH-F9C0 +F9C1 療 # CJK COMPATIBILITY IDEOGRAPH-F9C1 +F9C2 蓼 # CJK COMPATIBILITY IDEOGRAPH-F9C2 +F9C3 遼 # CJK COMPATIBILITY IDEOGRAPH-F9C3 +F9C4 龍 # CJK COMPATIBILITY IDEOGRAPH-F9C4 +F9C5 暈 # CJK COMPATIBILITY IDEOGRAPH-F9C5 +F9C6 阮 # CJK COMPATIBILITY IDEOGRAPH-F9C6 +F9C7 劉 # CJK COMPATIBILITY IDEOGRAPH-F9C7 +F9C8 杻 # CJK COMPATIBILITY IDEOGRAPH-F9C8 +F9C9 柳 # CJK COMPATIBILITY IDEOGRAPH-F9C9 +F9CA 流 # CJK COMPATIBILITY IDEOGRAPH-F9CA +F9CB 溜 # CJK COMPATIBILITY IDEOGRAPH-F9CB +F9CC 琉 # CJK COMPATIBILITY IDEOGRAPH-F9CC +F9CD 留 # CJK COMPATIBILITY IDEOGRAPH-F9CD +F9CE 硫 # CJK COMPATIBILITY IDEOGRAPH-F9CE +F9CF 紐 # CJK COMPATIBILITY IDEOGRAPH-F9CF +F9D0 類 # CJK COMPATIBILITY IDEOGRAPH-F9D0 +F9D1 六 # CJK COMPATIBILITY IDEOGRAPH-F9D1 +F9D2 戮 # CJK COMPATIBILITY IDEOGRAPH-F9D2 +F9D3 陸 # CJK COMPATIBILITY IDEOGRAPH-F9D3 +F9D4 倫 # CJK COMPATIBILITY IDEOGRAPH-F9D4 +F9D5 崙 # CJK COMPATIBILITY IDEOGRAPH-F9D5 +F9D6 淪 # CJK COMPATIBILITY IDEOGRAPH-F9D6 +F9D7 輪 # CJK COMPATIBILITY IDEOGRAPH-F9D7 +F9D8 律 # CJK COMPATIBILITY IDEOGRAPH-F9D8 +F9D9 慄 # CJK COMPATIBILITY IDEOGRAPH-F9D9 +F9DA 栗 # CJK COMPATIBILITY IDEOGRAPH-F9DA +F9DB 率 # CJK COMPATIBILITY IDEOGRAPH-F9DB +F9DC 隆 # CJK COMPATIBILITY IDEOGRAPH-F9DC +F9DD 利 # CJK COMPATIBILITY IDEOGRAPH-F9DD +F9DE 吏 # CJK COMPATIBILITY IDEOGRAPH-F9DE +F9DF 履 # CJK COMPATIBILITY IDEOGRAPH-F9DF +F9E0 易 # CJK COMPATIBILITY IDEOGRAPH-F9E0 +F9E1 李 # CJK COMPATIBILITY IDEOGRAPH-F9E1 +F9E2 梨 # CJK COMPATIBILITY IDEOGRAPH-F9E2 +F9E3 泥 # CJK COMPATIBILITY IDEOGRAPH-F9E3 +F9E4 理 # CJK COMPATIBILITY IDEOGRAPH-F9E4 +F9E5 痢 # CJK COMPATIBILITY IDEOGRAPH-F9E5 +F9E6 罹 # CJK COMPATIBILITY IDEOGRAPH-F9E6 +F9E7 裏 # CJK COMPATIBILITY IDEOGRAPH-F9E7 +F9E8 裡 # CJK COMPATIBILITY IDEOGRAPH-F9E8 +F9E9 里 # CJK COMPATIBILITY IDEOGRAPH-F9E9 +F9EA 離 # CJK COMPATIBILITY IDEOGRAPH-F9EA +F9EB 匿 # CJK COMPATIBILITY IDEOGRAPH-F9EB +F9EC 溺 # CJK COMPATIBILITY IDEOGRAPH-F9EC +F9ED 吝 # CJK COMPATIBILITY IDEOGRAPH-F9ED +F9EE 燐 # CJK COMPATIBILITY IDEOGRAPH-F9EE +F9EF 璘 # CJK COMPATIBILITY IDEOGRAPH-F9EF +F9F0 藺 # CJK COMPATIBILITY IDEOGRAPH-F9F0 +F9F1 隣 # CJK COMPATIBILITY IDEOGRAPH-F9F1 +F9F2 鱗 # CJK COMPATIBILITY IDEOGRAPH-F9F2 +F9F3 麟 # CJK COMPATIBILITY IDEOGRAPH-F9F3 +F9F4 林 # CJK COMPATIBILITY IDEOGRAPH-F9F4 +F9F5 淋 # CJK COMPATIBILITY IDEOGRAPH-F9F5 +F9F6 臨 # CJK COMPATIBILITY IDEOGRAPH-F9F6 +F9F7 立 # CJK COMPATIBILITY IDEOGRAPH-F9F7 +F9F8 笠 # CJK COMPATIBILITY IDEOGRAPH-F9F8 +F9F9 粒 # CJK COMPATIBILITY IDEOGRAPH-F9F9 +F9FA 狀 # CJK COMPATIBILITY IDEOGRAPH-F9FA +F9FB 炙 # CJK COMPATIBILITY IDEOGRAPH-F9FB +F9FC 識 # CJK COMPATIBILITY IDEOGRAPH-F9FC +F9FD 什 # CJK COMPATIBILITY IDEOGRAPH-F9FD +F9FE 茶 # CJK COMPATIBILITY IDEOGRAPH-F9FE +F9FF 刺 # CJK COMPATIBILITY IDEOGRAPH-F9FF +FA00 切 # CJK COMPATIBILITY IDEOGRAPH-FA00 +FA01 度 # CJK COMPATIBILITY IDEOGRAPH-FA01 +FA02 拓 # CJK COMPATIBILITY IDEOGRAPH-FA02 +FA03 糖 # CJK COMPATIBILITY IDEOGRAPH-FA03 +FA04 宅 # CJK COMPATIBILITY IDEOGRAPH-FA04 +FA05 洞 # CJK COMPATIBILITY IDEOGRAPH-FA05 +FA06 暴 # CJK COMPATIBILITY IDEOGRAPH-FA06 +FA07 輻 # CJK COMPATIBILITY IDEOGRAPH-FA07 +FA08 行 # CJK COMPATIBILITY IDEOGRAPH-FA08 +FA09 降 # CJK COMPATIBILITY IDEOGRAPH-FA09 +FA0A 見 # CJK COMPATIBILITY IDEOGRAPH-FA0A +FA0B 廓 # CJK COMPATIBILITY IDEOGRAPH-FA0B +FA0C 兀 # CJK COMPATIBILITY IDEOGRAPH-FA0C +FA0D 嗀 # CJK COMPATIBILITY IDEOGRAPH-FA0D +FA10 塚 # CJK COMPATIBILITY IDEOGRAPH-FA10 +FA12 晴 # CJK COMPATIBILITY IDEOGRAPH-FA12 +FA15 凞 # CJK COMPATIBILITY IDEOGRAPH-FA15 +FA16 猪 # CJK COMPATIBILITY IDEOGRAPH-FA16 +FA17 益 # CJK COMPATIBILITY IDEOGRAPH-FA17 +FA18 礼 # CJK COMPATIBILITY IDEOGRAPH-FA18 +FA19 神 # CJK COMPATIBILITY IDEOGRAPH-FA19 +FA1A 祥 # CJK COMPATIBILITY IDEOGRAPH-FA1A +FA1B 福 # CJK COMPATIBILITY IDEOGRAPH-FA1B +FA1C 靖 # CJK COMPATIBILITY IDEOGRAPH-FA1C +FA1D 精 # CJK COMPATIBILITY IDEOGRAPH-FA1D +FA1E 羽 # CJK COMPATIBILITY IDEOGRAPH-FA1E +FA20 蘒 # CJK COMPATIBILITY IDEOGRAPH-FA20 +FA22 諸 # CJK COMPATIBILITY IDEOGRAPH-FA22 +FA25 逸 # CJK COMPATIBILITY IDEOGRAPH-FA25 +FA26 都 # CJK COMPATIBILITY IDEOGRAPH-FA26 +FA2A 飯 # CJK COMPATIBILITY IDEOGRAPH-FA2A +FA2B 飼 # CJK COMPATIBILITY IDEOGRAPH-FA2B +FA2C 館 # CJK COMPATIBILITY IDEOGRAPH-FA2C +FA2D 鶴 # CJK COMPATIBILITY IDEOGRAPH-FA2D +FA30 侮 # CJK COMPATIBILITY IDEOGRAPH-FA30 +FA31 僧 # CJK COMPATIBILITY IDEOGRAPH-FA31 +FA32 免 # CJK COMPATIBILITY IDEOGRAPH-FA32 +FA33 勉 # CJK COMPATIBILITY IDEOGRAPH-FA33 +FA34 勤 # CJK COMPATIBILITY IDEOGRAPH-FA34 +FA35 卑 # CJK COMPATIBILITY IDEOGRAPH-FA35 +FA36 喝 # CJK COMPATIBILITY IDEOGRAPH-FA36 +FA37 嘆 # CJK COMPATIBILITY IDEOGRAPH-FA37 +FA38 器 # CJK COMPATIBILITY IDEOGRAPH-FA38 +FA39 塀 # CJK COMPATIBILITY IDEOGRAPH-FA39 +FA3A 墨 # CJK COMPATIBILITY IDEOGRAPH-FA3A +FA3B 層 # CJK COMPATIBILITY IDEOGRAPH-FA3B +FA3C 屮 # CJK COMPATIBILITY IDEOGRAPH-FA3C +FA3D 悔 # CJK COMPATIBILITY IDEOGRAPH-FA3D +FA3E 慨 # CJK COMPATIBILITY IDEOGRAPH-FA3E +FA3F 憎 # CJK COMPATIBILITY IDEOGRAPH-FA3F +FA40 懲 # CJK COMPATIBILITY IDEOGRAPH-FA40 +FA41 敏 # CJK COMPATIBILITY IDEOGRAPH-FA41 +FA42 既 # CJK COMPATIBILITY IDEOGRAPH-FA42 +FA43 暑 # CJK COMPATIBILITY IDEOGRAPH-FA43 +FA44 梅 # CJK COMPATIBILITY IDEOGRAPH-FA44 +FA45 海 # CJK COMPATIBILITY IDEOGRAPH-FA45 +FA46 渚 # CJK COMPATIBILITY IDEOGRAPH-FA46 +FA47 漢 # CJK COMPATIBILITY IDEOGRAPH-FA47 +FA48 煮 # CJK COMPATIBILITY IDEOGRAPH-FA48 +FA49 爫 # CJK COMPATIBILITY IDEOGRAPH-FA49 +FA4A 琢 # CJK COMPATIBILITY IDEOGRAPH-FA4A +FA4B 碑 # CJK COMPATIBILITY IDEOGRAPH-FA4B +FA4C 社 # CJK COMPATIBILITY IDEOGRAPH-FA4C +FA4D 祉 # CJK COMPATIBILITY IDEOGRAPH-FA4D +FA4E 祈 # CJK COMPATIBILITY IDEOGRAPH-FA4E +FA4F 祐 # CJK COMPATIBILITY IDEOGRAPH-FA4F +FA50 祖 # CJK COMPATIBILITY IDEOGRAPH-FA50 +FA51 祝 # CJK COMPATIBILITY IDEOGRAPH-FA51 +FA52 禍 # CJK COMPATIBILITY IDEOGRAPH-FA52 +FA53 禎 # CJK COMPATIBILITY IDEOGRAPH-FA53 +FA54 穀 # CJK COMPATIBILITY IDEOGRAPH-FA54 +FA55 突 # CJK COMPATIBILITY IDEOGRAPH-FA55 +FA56 節 # CJK COMPATIBILITY IDEOGRAPH-FA56 +FA57 練 # CJK COMPATIBILITY IDEOGRAPH-FA57 +FA58 縉 # CJK COMPATIBILITY IDEOGRAPH-FA58 +FA59 繁 # CJK COMPATIBILITY IDEOGRAPH-FA59 +FA5A 署 # CJK COMPATIBILITY IDEOGRAPH-FA5A +FA5B 者 # CJK COMPATIBILITY IDEOGRAPH-FA5B +FA5C 臭 # CJK COMPATIBILITY IDEOGRAPH-FA5C +FA5D 艹 # CJK COMPATIBILITY IDEOGRAPH-FA5D +FA5E 艹 # CJK COMPATIBILITY IDEOGRAPH-FA5E +FA5F 著 # CJK COMPATIBILITY IDEOGRAPH-FA5F +FA60 褐 # CJK COMPATIBILITY IDEOGRAPH-FA60 +FA61 視 # CJK COMPATIBILITY IDEOGRAPH-FA61 +FA62 謁 # CJK COMPATIBILITY IDEOGRAPH-FA62 +FA63 謹 # CJK COMPATIBILITY IDEOGRAPH-FA63 +FA64 賓 # CJK COMPATIBILITY IDEOGRAPH-FA64 +FA65 贈 # CJK COMPATIBILITY IDEOGRAPH-FA65 +FA66 辶 # CJK COMPATIBILITY IDEOGRAPH-FA66 +FA67 逸 # CJK COMPATIBILITY IDEOGRAPH-FA67 +FA68 難 # CJK COMPATIBILITY IDEOGRAPH-FA68 +FA69 響 # CJK COMPATIBILITY IDEOGRAPH-FA69 +FA6A 頻 # CJK COMPATIBILITY IDEOGRAPH-FA6A +FB00 ff # LATIN SMALL LIGATURE FF +FB01 fi # LATIN SMALL LIGATURE FI +FB02 fl # LATIN SMALL LIGATURE FL +FB03 ffi # LATIN SMALL LIGATURE FFI +FB04 ffl # LATIN SMALL LIGATURE FFL +FB05 ſt # LATIN SMALL LIGATURE LONG S T +FB06 st # LATIN SMALL LIGATURE ST +FB13 մն # ARMENIAN SMALL LIGATURE MEN NOW +FB14 մե # ARMENIAN SMALL LIGATURE MEN ECH +FB15 մի # ARMENIAN SMALL LIGATURE MEN INI +FB16 վն # ARMENIAN SMALL LIGATURE VEW NOW +FB17 մխ # ARMENIAN SMALL LIGATURE MEN XEH +FB20 ע # HEBREW LETTER ALTERNATIVE AYIN +FB21 א # HEBREW LETTER WIDE ALEF +FB22 ד # HEBREW LETTER WIDE DALET +FB23 ה # HEBREW LETTER WIDE HE +FB24 כ # HEBREW LETTER WIDE KAF +FB25 ל # HEBREW LETTER WIDE LAMED +FB26 ם # HEBREW LETTER WIDE FINAL MEM +FB27 ר # HEBREW LETTER WIDE RESH +FB28 ת # HEBREW LETTER WIDE TAV +FB29 + # HEBREW LETTER ALTERNATIVE PLUS SIGN +FB4F אל # HEBREW LIGATURE ALEF LAMED +FE49 ‾ # DASHED OVERLINE +FE4A ‾ # CENTRELINE OVERLINE +FE4B ‾ # WAVY OVERLINE +FE4C ‾ # DOUBLE WAVY OVERLINE +FE4D _ # DASHED LOW LINE +FE4E _ # CENTRELINE LOW LINE +FE4F _ # WAVY LOW LINE +FE50 , # SMALL COMMA +FE51 、 # SMALL IDEOGRAPHIC COMMA +FE52 . # SMALL FULL STOP +FE54 ; # SMALL SEMICOLON +FE55 : # SMALL COLON +FE56 ? # SMALL QUESTION MARK +FE57 ! # SMALL EXCLAMATION MARK +FE58 — # SMALL EM DASH +FE59 ( # SMALL LEFT PARENTHESIS +FE5A ) # SMALL RIGHT PARENTHESIS +FE5B { # SMALL LEFT CURLY BRACKET +FE5C } # SMALL RIGHT CURLY BRACKET +FE5D 〔 # SMALL LEFT TORTOISE SHELL BRACKET +FE5E 〕 # SMALL RIGHT TORTOISE SHELL BRACKET +FE5F # # SMALL NUMBER SIGN +FE60 & # SMALL AMPERSAND +FE61 * # SMALL ASTERISK +FE62 + # SMALL PLUS SIGN +FE63 - # SMALL HYPHEN-MINUS +FE64 < # SMALL LESS-THAN SIGN +FE65 > # SMALL GREATER-THAN SIGN +FE66 = # SMALL EQUALS SIGN +FE68 \ # SMALL REVERSE SOLIDUS +FE69 $ # SMALL DOLLAR SIGN +FE6A % # SMALL PERCENT SIGN +FE6B @ # SMALL COMMERCIAL AT +FF01 ! # FULLWIDTH EXCLAMATION MARK +FF02 " # FULLWIDTH QUOTATION MARK +FF03 # # FULLWIDTH NUMBER SIGN +FF04 $ # FULLWIDTH DOLLAR SIGN +FF05 % # FULLWIDTH PERCENT SIGN +FF06 & # FULLWIDTH AMPERSAND +FF07 ' # FULLWIDTH APOSTROPHE +FF08 ( # FULLWIDTH LEFT PARENTHESIS +FF09 ) # FULLWIDTH RIGHT PARENTHESIS +FF0A * # FULLWIDTH ASTERISK +FF0B + # FULLWIDTH PLUS SIGN +FF0C , # FULLWIDTH COMMA +FF0D - # FULLWIDTH HYPHEN-MINUS +FF0E . # FULLWIDTH FULL STOP +FF0F / # FULLWIDTH SOLIDUS +FF10 0 # FULLWIDTH DIGIT ZERO +FF11 1 # FULLWIDTH DIGIT ONE +FF12 2 # FULLWIDTH DIGIT TWO +FF13 3 # FULLWIDTH DIGIT THREE +FF14 4 # FULLWIDTH DIGIT FOUR +FF15 5 # FULLWIDTH DIGIT FIVE +FF16 6 # FULLWIDTH DIGIT SIX +FF17 7 # FULLWIDTH DIGIT SEVEN +FF18 8 # FULLWIDTH DIGIT EIGHT +FF19 9 # FULLWIDTH DIGIT NINE +FF1A : # FULLWIDTH COLON +FF1B ; # FULLWIDTH SEMICOLON +FF1C < # FULLWIDTH LESS-THAN SIGN +FF1D = # FULLWIDTH EQUALS SIGN +FF1E > # FULLWIDTH GREATER-THAN SIGN +FF1F ? # FULLWIDTH QUESTION MARK +FF20 @ # FULLWIDTH COMMERCIAL AT +FF21 A # FULLWIDTH LATIN CAPITAL LETTER A +FF22 B # FULLWIDTH LATIN CAPITAL LETTER B +FF23 C # FULLWIDTH LATIN CAPITAL LETTER C +FF24 D # FULLWIDTH LATIN CAPITAL LETTER D +FF25 E # FULLWIDTH LATIN CAPITAL LETTER E +FF26 F # FULLWIDTH LATIN CAPITAL LETTER F +FF27 G # FULLWIDTH LATIN CAPITAL LETTER G +FF28 H # FULLWIDTH LATIN CAPITAL LETTER H +FF29 I # FULLWIDTH LATIN CAPITAL LETTER I +FF2A J # FULLWIDTH LATIN CAPITAL LETTER J +FF2B K # FULLWIDTH LATIN CAPITAL LETTER K +FF2C L # FULLWIDTH LATIN CAPITAL LETTER L +FF2D M # FULLWIDTH LATIN CAPITAL LETTER M +FF2E N # FULLWIDTH LATIN CAPITAL LETTER N +FF2F O # FULLWIDTH LATIN CAPITAL LETTER O +FF30 P # FULLWIDTH LATIN CAPITAL LETTER P +FF31 Q # FULLWIDTH LATIN CAPITAL LETTER Q +FF32 R # FULLWIDTH LATIN CAPITAL LETTER R +FF33 S # FULLWIDTH LATIN CAPITAL LETTER S +FF34 T # FULLWIDTH LATIN CAPITAL LETTER T +FF35 U # FULLWIDTH LATIN CAPITAL LETTER U +FF36 V # FULLWIDTH LATIN CAPITAL LETTER V +FF37 W # FULLWIDTH LATIN CAPITAL LETTER W +FF38 X # FULLWIDTH LATIN CAPITAL LETTER X +FF39 Y # FULLWIDTH LATIN CAPITAL LETTER Y +FF3A Z # FULLWIDTH LATIN CAPITAL LETTER Z +FF3B [ # FULLWIDTH LEFT SQUARE BRACKET +FF3C \ # FULLWIDTH REVERSE SOLIDUS +FF3D ] # FULLWIDTH RIGHT SQUARE BRACKET +FF3E ^ # FULLWIDTH CIRCUMFLEX ACCENT +FF3F _ # FULLWIDTH LOW LINE +FF40 ` # FULLWIDTH GRAVE ACCENT +FF41 a # FULLWIDTH LATIN SMALL LETTER A +FF42 b # FULLWIDTH LATIN SMALL LETTER B +FF43 c # FULLWIDTH LATIN SMALL LETTER C +FF44 d # FULLWIDTH LATIN SMALL LETTER D +FF45 e # FULLWIDTH LATIN SMALL LETTER E +FF46 f # FULLWIDTH LATIN SMALL LETTER F +FF47 g # FULLWIDTH LATIN SMALL LETTER G +FF48 h # FULLWIDTH LATIN SMALL LETTER H +FF49 i # FULLWIDTH LATIN SMALL LETTER I +FF4A j # FULLWIDTH LATIN SMALL LETTER J +FF4B k # FULLWIDTH LATIN SMALL LETTER K +FF4C l # FULLWIDTH LATIN SMALL LETTER L +FF4D m # FULLWIDTH LATIN SMALL LETTER M +FF4E n # FULLWIDTH LATIN SMALL LETTER N +FF4F o # FULLWIDTH LATIN SMALL LETTER O +FF50 p # FULLWIDTH LATIN SMALL LETTER P +FF51 q # FULLWIDTH LATIN SMALL LETTER Q +FF52 r # FULLWIDTH LATIN SMALL LETTER R +FF53 s # FULLWIDTH LATIN SMALL LETTER S +FF54 t # FULLWIDTH LATIN SMALL LETTER T +FF55 u # FULLWIDTH LATIN SMALL LETTER U +FF56 v # FULLWIDTH LATIN SMALL LETTER V +FF57 w # FULLWIDTH LATIN SMALL LETTER W +FF58 x # FULLWIDTH LATIN SMALL LETTER X +FF59 y # FULLWIDTH LATIN SMALL LETTER Y +FF5A z # FULLWIDTH LATIN SMALL LETTER Z +FF5B { # FULLWIDTH LEFT CURLY BRACKET +FF5C | # FULLWIDTH VERTICAL LINE +FF5D } # FULLWIDTH RIGHT CURLY BRACKET +FF5E ~ # FULLWIDTH TILDE +FF5F ⦅ # FULLWIDTH LEFT WHITE PARENTHESIS +FF60 ⦆ # FULLWIDTH RIGHT WHITE PARENTHESIS +FF61 。 # HALFWIDTH IDEOGRAPHIC FULL STOP +FF62 「 # HALFWIDTH LEFT CORNER BRACKET +FF63 」 # HALFWIDTH RIGHT CORNER BRACKET +FF64 、 # HALFWIDTH IDEOGRAPHIC COMMA +FF65 ・ # HALFWIDTH KATAKANA MIDDLE DOT +FF66 ヲ # HALFWIDTH KATAKANA LETTER WO +FF67 ァ # HALFWIDTH KATAKANA LETTER SMALL A +FF68 ィ # HALFWIDTH KATAKANA LETTER SMALL I +FF69 ゥ # HALFWIDTH KATAKANA LETTER SMALL U +FF6A ェ # HALFWIDTH KATAKANA LETTER SMALL E +FF6B ォ # HALFWIDTH KATAKANA LETTER SMALL O +FF6C ャ # HALFWIDTH KATAKANA LETTER SMALL YA +FF6D ュ # HALFWIDTH KATAKANA LETTER SMALL YU +FF6E ョ # HALFWIDTH KATAKANA LETTER SMALL YO +FF6F ッ # HALFWIDTH KATAKANA LETTER SMALL TU +FF70 ー # HALFWIDTH KATAKANA-HIRAGANA PROLONGED SOUND MARK +FF71 ア # HALFWIDTH KATAKANA LETTER A +FF72 イ # HALFWIDTH KATAKANA LETTER I +FF73 ウ # HALFWIDTH KATAKANA LETTER U +FF74 エ # HALFWIDTH KATAKANA LETTER E +FF75 オ # HALFWIDTH KATAKANA LETTER O +FF76 カ # HALFWIDTH KATAKANA LETTER KA +FF77 キ # HALFWIDTH KATAKANA LETTER KI +FF78 ク # HALFWIDTH KATAKANA LETTER KU +FF79 ケ # HALFWIDTH KATAKANA LETTER KE +FF7A コ # HALFWIDTH KATAKANA LETTER KO +FF7B サ # HALFWIDTH KATAKANA LETTER SA +FF7C シ # HALFWIDTH KATAKANA LETTER SI +FF7D ス # HALFWIDTH KATAKANA LETTER SU +FF7E セ # HALFWIDTH KATAKANA LETTER SE +FF7F ソ # HALFWIDTH KATAKANA LETTER SO +FF80 タ # HALFWIDTH KATAKANA LETTER TA +FF81 チ # HALFWIDTH KATAKANA LETTER TI +FF82 ツ # HALFWIDTH KATAKANA LETTER TU +FF83 テ # HALFWIDTH KATAKANA LETTER TE +FF84 ト # HALFWIDTH KATAKANA LETTER TO +FF85 ナ # HALFWIDTH KATAKANA LETTER NA +FF86 ニ # HALFWIDTH KATAKANA LETTER NI +FF87 ヌ # HALFWIDTH KATAKANA LETTER NU +FF88 ネ # HALFWIDTH KATAKANA LETTER NE +FF89 ノ # HALFWIDTH KATAKANA LETTER NO +FF8A ハ # HALFWIDTH KATAKANA LETTER HA +FF8B ヒ # HALFWIDTH KATAKANA LETTER HI +FF8C フ # HALFWIDTH KATAKANA LETTER HU +FF8D ヘ # HALFWIDTH KATAKANA LETTER HE +FF8E ホ # HALFWIDTH KATAKANA LETTER HO +FF8F マ # HALFWIDTH KATAKANA LETTER MA +FF90 ミ # HALFWIDTH KATAKANA LETTER MI +FF91 ム # HALFWIDTH KATAKANA LETTER MU +FF92 メ # HALFWIDTH KATAKANA LETTER ME +FF93 モ # HALFWIDTH KATAKANA LETTER MO +FF94 ヤ # HALFWIDTH KATAKANA LETTER YA +FF95 ユ # HALFWIDTH KATAKANA LETTER YU +FF96 ヨ # HALFWIDTH KATAKANA LETTER YO +FF97 ラ # HALFWIDTH KATAKANA LETTER RA +FF98 リ # HALFWIDTH KATAKANA LETTER RI +FF99 ル # HALFWIDTH KATAKANA LETTER RU +FF9A レ # HALFWIDTH KATAKANA LETTER RE +FF9B ロ # HALFWIDTH KATAKANA LETTER RO +FF9C ワ # HALFWIDTH KATAKANA LETTER WA +FF9D ン # HALFWIDTH KATAKANA LETTER N +FF9E ゙ # HALFWIDTH KATAKANA VOICED SOUND MARK +FF9F ゚ # HALFWIDTH KATAKANA SEMI-VOICED SOUND MARK +FFA0 ㅤ # HALFWIDTH HANGUL FILLER +FFA1 ㄱ # HALFWIDTH HANGUL LETTER KIYEOK +FFA2 ㄲ # HALFWIDTH HANGUL LETTER SSANGKIYEOK +FFA3 ㄳ # HALFWIDTH HANGUL LETTER KIYEOK-SIOS +FFA4 ㄴ # HALFWIDTH HANGUL LETTER NIEUN +FFA5 ㄵ # HALFWIDTH HANGUL LETTER NIEUN-CIEUC +FFA6 ㄶ # HALFWIDTH HANGUL LETTER NIEUN-HIEUH +FFA7 ㄷ # HALFWIDTH HANGUL LETTER TIKEUT +FFA8 ㄸ # HALFWIDTH HANGUL LETTER SSANGTIKEUT +FFA9 ㄹ # HALFWIDTH HANGUL LETTER RIEUL +FFAA ㄺ # HALFWIDTH HANGUL LETTER RIEUL-KIYEOK +FFAB ㄻ # HALFWIDTH HANGUL LETTER RIEUL-MIEUM +FFAC ㄼ # HALFWIDTH HANGUL LETTER RIEUL-PIEUP +FFAD ㄽ # HALFWIDTH HANGUL LETTER RIEUL-SIOS +FFAE ㄾ # HALFWIDTH HANGUL LETTER RIEUL-THIEUTH +FFAF ㄿ # HALFWIDTH HANGUL LETTER RIEUL-PHIEUPH +FFB0 ㅀ # HALFWIDTH HANGUL LETTER RIEUL-HIEUH +FFB1 ㅁ # HALFWIDTH HANGUL LETTER MIEUM +FFB2 ㅂ # HALFWIDTH HANGUL LETTER PIEUP +FFB3 ㅃ # HALFWIDTH HANGUL LETTER SSANGPIEUP +FFB4 ㅄ # HALFWIDTH HANGUL LETTER PIEUP-SIOS +FFB5 ㅅ # HALFWIDTH HANGUL LETTER SIOS +FFB6 ㅆ # HALFWIDTH HANGUL LETTER SSANGSIOS +FFB7 ㅇ # HALFWIDTH HANGUL LETTER IEUNG +FFB8 ㅈ # HALFWIDTH HANGUL LETTER CIEUC +FFB9 ㅉ # HALFWIDTH HANGUL LETTER SSANGCIEUC +FFBA ㅊ # HALFWIDTH HANGUL LETTER CHIEUCH +FFBB ㅋ # HALFWIDTH HANGUL LETTER KHIEUKH +FFBC ㅌ # HALFWIDTH HANGUL LETTER THIEUTH +FFBD ㅍ # HALFWIDTH HANGUL LETTER PHIEUPH +FFBE ㅎ # HALFWIDTH HANGUL LETTER HIEUH +FFC2 ㅏ # HALFWIDTH HANGUL LETTER A +FFC3 ㅐ # HALFWIDTH HANGUL LETTER AE +FFC4 ㅑ # HALFWIDTH HANGUL LETTER YA +FFC5 ㅒ # HALFWIDTH HANGUL LETTER YAE +FFC6 ㅓ # HALFWIDTH HANGUL LETTER EO +FFC7 ㅔ # HALFWIDTH HANGUL LETTER E +FFCA ㅕ # HALFWIDTH HANGUL LETTER YEO +FFCB ㅖ # HALFWIDTH HANGUL LETTER YE +FFCC ㅗ # HALFWIDTH HANGUL LETTER O +FFCD ㅘ # HALFWIDTH HANGUL LETTER WA +FFCE ㅙ # HALFWIDTH HANGUL LETTER WAE +FFCF ㅚ # HALFWIDTH HANGUL LETTER OE +FFD2 ㅛ # HALFWIDTH HANGUL LETTER YO +FFD3 ㅜ # HALFWIDTH HANGUL LETTER U +FFD4 ㅝ # HALFWIDTH HANGUL LETTER WEO +FFD5 ㅞ # HALFWIDTH HANGUL LETTER WE +FFD6 ㅟ # HALFWIDTH HANGUL LETTER WI +FFD7 ㅠ # HALFWIDTH HANGUL LETTER YU +FFDA ㅡ # HALFWIDTH HANGUL LETTER EU +FFDB ㅢ # HALFWIDTH HANGUL LETTER YI +FFDC ㅣ # HALFWIDTH HANGUL LETTER I +FFE0 ¢ # FULLWIDTH CENT SIGN +FFE1 £ # FULLWIDTH POUND SIGN +FFE2 ¬ # FULLWIDTH NOT SIGN +FFE3 ¯ # FULLWIDTH MACRON +FFE4 ¦ # FULLWIDTH BROKEN BAR +FFE5 ¥ # FULLWIDTH YEN SIGN +FFE6 ₩ # FULLWIDTH WON SIGN +FFE8 │ # HALFWIDTH FORMS LIGHT VERTICAL +FFE9 ← # HALFWIDTH LEFTWARDS ARROW +FFEA ↑ # HALFWIDTH UPWARDS ARROW +FFEB → # HALFWIDTH RIGHTWARDS ARROW +FFEC ↓ # HALFWIDTH DOWNWARDS ARROW +FFED ■ # HALFWIDTH BLACK SQUARE +FFEE ○ # HALFWIDTH WHITE CIRCLE +1D400 A # MATHEMATICAL BOLD CAPITAL A +1D401 B # MATHEMATICAL BOLD CAPITAL B +1D402 C # MATHEMATICAL BOLD CAPITAL C +1D403 D # MATHEMATICAL BOLD CAPITAL D +1D404 E # MATHEMATICAL BOLD CAPITAL E +1D405 F # MATHEMATICAL BOLD CAPITAL F +1D406 G # MATHEMATICAL BOLD CAPITAL G +1D407 H # MATHEMATICAL BOLD CAPITAL H +1D408 I # MATHEMATICAL BOLD CAPITAL I +1D409 J # MATHEMATICAL BOLD CAPITAL J +1D40A K # MATHEMATICAL BOLD CAPITAL K +1D40B L # MATHEMATICAL BOLD CAPITAL L +1D40C M # MATHEMATICAL BOLD CAPITAL M +1D40D N # MATHEMATICAL BOLD CAPITAL N +1D40E O # MATHEMATICAL BOLD CAPITAL O +1D40F P # MATHEMATICAL BOLD CAPITAL P +1D410 Q # MATHEMATICAL BOLD CAPITAL Q +1D411 R # MATHEMATICAL BOLD CAPITAL R +1D412 S # MATHEMATICAL BOLD CAPITAL S +1D413 T # MATHEMATICAL BOLD CAPITAL T +1D414 U # MATHEMATICAL BOLD CAPITAL U +1D415 V # MATHEMATICAL BOLD CAPITAL V +1D416 W # MATHEMATICAL BOLD CAPITAL W +1D417 X # MATHEMATICAL BOLD CAPITAL X +1D418 Y # MATHEMATICAL BOLD CAPITAL Y +1D419 Z # MATHEMATICAL BOLD CAPITAL Z +1D41A a # MATHEMATICAL BOLD SMALL A +1D41B b # MATHEMATICAL BOLD SMALL B +1D41C c # MATHEMATICAL BOLD SMALL C +1D41D d # MATHEMATICAL BOLD SMALL D +1D41E e # MATHEMATICAL BOLD SMALL E +1D41F f # MATHEMATICAL BOLD SMALL F +1D420 g # MATHEMATICAL BOLD SMALL G +1D421 h # MATHEMATICAL BOLD SMALL H +1D422 i # MATHEMATICAL BOLD SMALL I +1D423 j # MATHEMATICAL BOLD SMALL J +1D424 k # MATHEMATICAL BOLD SMALL K +1D425 l # MATHEMATICAL BOLD SMALL L +1D426 m # MATHEMATICAL BOLD SMALL M +1D427 n # MATHEMATICAL BOLD SMALL N +1D428 o # MATHEMATICAL BOLD SMALL O +1D429 p # MATHEMATICAL BOLD SMALL P +1D42A q # MATHEMATICAL BOLD SMALL Q +1D42B r # MATHEMATICAL BOLD SMALL R +1D42C s # MATHEMATICAL BOLD SMALL S +1D42D t # MATHEMATICAL BOLD SMALL T +1D42E u # MATHEMATICAL BOLD SMALL U +1D42F v # MATHEMATICAL BOLD SMALL V +1D430 w # MATHEMATICAL BOLD SMALL W +1D431 x # MATHEMATICAL BOLD SMALL X +1D432 y # MATHEMATICAL BOLD SMALL Y +1D433 z # MATHEMATICAL BOLD SMALL Z +1D434 A # MATHEMATICAL ITALIC CAPITAL A +1D435 B # MATHEMATICAL ITALIC CAPITAL B +1D436 C # MATHEMATICAL ITALIC CAPITAL C +1D437 D # MATHEMATICAL ITALIC CAPITAL D +1D438 E # MATHEMATICAL ITALIC CAPITAL E +1D439 F # MATHEMATICAL ITALIC CAPITAL F +1D43A G # MATHEMATICAL ITALIC CAPITAL G +1D43B H # MATHEMATICAL ITALIC CAPITAL H +1D43C I # MATHEMATICAL ITALIC CAPITAL I +1D43D J # MATHEMATICAL ITALIC CAPITAL J +1D43E K # MATHEMATICAL ITALIC CAPITAL K +1D43F L # MATHEMATICAL ITALIC CAPITAL L +1D440 M # MATHEMATICAL ITALIC CAPITAL M +1D441 N # MATHEMATICAL ITALIC CAPITAL N +1D442 O # MATHEMATICAL ITALIC CAPITAL O +1D443 P # MATHEMATICAL ITALIC CAPITAL P +1D444 Q # MATHEMATICAL ITALIC CAPITAL Q +1D445 R # MATHEMATICAL ITALIC CAPITAL R +1D446 S # MATHEMATICAL ITALIC CAPITAL S +1D447 T # MATHEMATICAL ITALIC CAPITAL T +1D448 U # MATHEMATICAL ITALIC CAPITAL U +1D449 V # MATHEMATICAL ITALIC CAPITAL V +1D44A W # MATHEMATICAL ITALIC CAPITAL W +1D44B X # MATHEMATICAL ITALIC CAPITAL X +1D44C Y # MATHEMATICAL ITALIC CAPITAL Y +1D44D Z # MATHEMATICAL ITALIC CAPITAL Z +1D44E a # MATHEMATICAL ITALIC SMALL A +1D44F b # MATHEMATICAL ITALIC SMALL B +1D450 c # MATHEMATICAL ITALIC SMALL C +1D451 d # MATHEMATICAL ITALIC SMALL D +1D452 e # MATHEMATICAL ITALIC SMALL E +1D453 f # MATHEMATICAL ITALIC SMALL F +1D454 g # MATHEMATICAL ITALIC SMALL G +1D456 i # MATHEMATICAL ITALIC SMALL I +1D457 j # MATHEMATICAL ITALIC SMALL J +1D458 k # MATHEMATICAL ITALIC SMALL K +1D459 l # MATHEMATICAL ITALIC SMALL L +1D45A m # MATHEMATICAL ITALIC SMALL M +1D45B n # MATHEMATICAL ITALIC SMALL N +1D45C o # MATHEMATICAL ITALIC SMALL O +1D45D p # MATHEMATICAL ITALIC SMALL P +1D45E q # MATHEMATICAL ITALIC SMALL Q +1D45F r # MATHEMATICAL ITALIC SMALL R +1D460 s # MATHEMATICAL ITALIC SMALL S +1D461 t # MATHEMATICAL ITALIC SMALL T +1D462 u # MATHEMATICAL ITALIC SMALL U +1D463 v # MATHEMATICAL ITALIC SMALL V +1D464 w # MATHEMATICAL ITALIC SMALL W +1D465 x # MATHEMATICAL ITALIC SMALL X +1D466 y # MATHEMATICAL ITALIC SMALL Y +1D467 z # MATHEMATICAL ITALIC SMALL Z +1D468 A # MATHEMATICAL BOLD ITALIC CAPITAL A +1D469 B # MATHEMATICAL BOLD ITALIC CAPITAL B +1D46A C # MATHEMATICAL BOLD ITALIC CAPITAL C +1D46B D # MATHEMATICAL BOLD ITALIC CAPITAL D +1D46C E # MATHEMATICAL BOLD ITALIC CAPITAL E +1D46D F # MATHEMATICAL BOLD ITALIC CAPITAL F +1D46E G # MATHEMATICAL BOLD ITALIC CAPITAL G +1D46F H # MATHEMATICAL BOLD ITALIC CAPITAL H +1D470 I # MATHEMATICAL BOLD ITALIC CAPITAL I +1D471 J # MATHEMATICAL BOLD ITALIC CAPITAL J +1D472 K # MATHEMATICAL BOLD ITALIC CAPITAL K +1D473 L # MATHEMATICAL BOLD ITALIC CAPITAL L +1D474 M # MATHEMATICAL BOLD ITALIC CAPITAL M +1D475 N # MATHEMATICAL BOLD ITALIC CAPITAL N +1D476 O # MATHEMATICAL BOLD ITALIC CAPITAL O +1D477 P # MATHEMATICAL BOLD ITALIC CAPITAL P +1D478 Q # MATHEMATICAL BOLD ITALIC CAPITAL Q +1D479 R # MATHEMATICAL BOLD ITALIC CAPITAL R +1D47A S # MATHEMATICAL BOLD ITALIC CAPITAL S +1D47B T # MATHEMATICAL BOLD ITALIC CAPITAL T +1D47C U # MATHEMATICAL BOLD ITALIC CAPITAL U +1D47D V # MATHEMATICAL BOLD ITALIC CAPITAL V +1D47E W # MATHEMATICAL BOLD ITALIC CAPITAL W +1D47F X # MATHEMATICAL BOLD ITALIC CAPITAL X +1D480 Y # MATHEMATICAL BOLD ITALIC CAPITAL Y +1D481 Z # MATHEMATICAL BOLD ITALIC CAPITAL Z +1D482 a # MATHEMATICAL BOLD ITALIC SMALL A +1D483 b # MATHEMATICAL BOLD ITALIC SMALL B +1D484 c # MATHEMATICAL BOLD ITALIC SMALL C +1D485 d # MATHEMATICAL BOLD ITALIC SMALL D +1D486 e # MATHEMATICAL BOLD ITALIC SMALL E +1D487 f # MATHEMATICAL BOLD ITALIC SMALL F +1D488 g # MATHEMATICAL BOLD ITALIC SMALL G +1D489 h # MATHEMATICAL BOLD ITALIC SMALL H +1D48A i # MATHEMATICAL BOLD ITALIC SMALL I +1D48B j # MATHEMATICAL BOLD ITALIC SMALL J +1D48C k # MATHEMATICAL BOLD ITALIC SMALL K +1D48D l # MATHEMATICAL BOLD ITALIC SMALL L +1D48E m # MATHEMATICAL BOLD ITALIC SMALL M +1D48F n # MATHEMATICAL BOLD ITALIC SMALL N +1D490 o # MATHEMATICAL BOLD ITALIC SMALL O +1D491 p # MATHEMATICAL BOLD ITALIC SMALL P +1D492 q # MATHEMATICAL BOLD ITALIC SMALL Q +1D493 r # MATHEMATICAL BOLD ITALIC SMALL R +1D494 s # MATHEMATICAL BOLD ITALIC SMALL S +1D495 t # MATHEMATICAL BOLD ITALIC SMALL T +1D496 u # MATHEMATICAL BOLD ITALIC SMALL U +1D497 v # MATHEMATICAL BOLD ITALIC SMALL V +1D498 w # MATHEMATICAL BOLD ITALIC SMALL W +1D499 x # MATHEMATICAL BOLD ITALIC SMALL X +1D49A y # MATHEMATICAL BOLD ITALIC SMALL Y +1D49B z # MATHEMATICAL BOLD ITALIC SMALL Z +1D49C A # MATHEMATICAL SCRIPT CAPITAL A +1D49E C # MATHEMATICAL SCRIPT CAPITAL C +1D49F D # MATHEMATICAL SCRIPT CAPITAL D +1D4A2 G # MATHEMATICAL SCRIPT CAPITAL G +1D4A5 J # MATHEMATICAL SCRIPT CAPITAL J +1D4A6 K # MATHEMATICAL SCRIPT CAPITAL K +1D4A9 N # MATHEMATICAL SCRIPT CAPITAL N +1D4AA O # MATHEMATICAL SCRIPT CAPITAL O +1D4AB P # MATHEMATICAL SCRIPT CAPITAL P +1D4AC Q # MATHEMATICAL SCRIPT CAPITAL Q +1D4AE S # MATHEMATICAL SCRIPT CAPITAL S +1D4AF T # MATHEMATICAL SCRIPT CAPITAL T +1D4B0 U # MATHEMATICAL SCRIPT CAPITAL U +1D4B1 V # MATHEMATICAL SCRIPT CAPITAL V +1D4B2 W # MATHEMATICAL SCRIPT CAPITAL W +1D4B3 X # MATHEMATICAL SCRIPT CAPITAL X +1D4B4 Y # MATHEMATICAL SCRIPT CAPITAL Y +1D4B5 Z # MATHEMATICAL SCRIPT CAPITAL Z +1D4B6 a # MATHEMATICAL SCRIPT SMALL A +1D4B7 b # MATHEMATICAL SCRIPT SMALL B +1D4B8 c # MATHEMATICAL SCRIPT SMALL C +1D4B9 d # MATHEMATICAL SCRIPT SMALL D +1D4BB f # MATHEMATICAL SCRIPT SMALL F +1D4BD h # MATHEMATICAL SCRIPT SMALL H +1D4BE i # MATHEMATICAL SCRIPT SMALL I +1D4BF j # MATHEMATICAL SCRIPT SMALL J +1D4C0 k # MATHEMATICAL SCRIPT SMALL K +1D4C1 l # MATHEMATICAL SCRIPT SMALL L +1D4C2 m # MATHEMATICAL SCRIPT SMALL M +1D4C3 n # MATHEMATICAL SCRIPT SMALL N +1D4C5 p # MATHEMATICAL SCRIPT SMALL P +1D4C6 q # MATHEMATICAL SCRIPT SMALL Q +1D4C7 r # MATHEMATICAL SCRIPT SMALL R +1D4C8 s # MATHEMATICAL SCRIPT SMALL S +1D4C9 t # MATHEMATICAL SCRIPT SMALL T +1D4CA u # MATHEMATICAL SCRIPT SMALL U +1D4CB v # MATHEMATICAL SCRIPT SMALL V +1D4CC w # MATHEMATICAL SCRIPT SMALL W +1D4CD x # MATHEMATICAL SCRIPT SMALL X +1D4CE y # MATHEMATICAL SCRIPT SMALL Y +1D4CF z # MATHEMATICAL SCRIPT SMALL Z +1D4D0 A # MATHEMATICAL BOLD SCRIPT CAPITAL A +1D4D1 B # MATHEMATICAL BOLD SCRIPT CAPITAL B +1D4D2 C # MATHEMATICAL BOLD SCRIPT CAPITAL C +1D4D3 D # MATHEMATICAL BOLD SCRIPT CAPITAL D +1D4D4 E # MATHEMATICAL BOLD SCRIPT CAPITAL E +1D4D5 F # MATHEMATICAL BOLD SCRIPT CAPITAL F +1D4D6 G # MATHEMATICAL BOLD SCRIPT CAPITAL G +1D4D7 H # MATHEMATICAL BOLD SCRIPT CAPITAL H +1D4D8 I # MATHEMATICAL BOLD SCRIPT CAPITAL I +1D4D9 J # MATHEMATICAL BOLD SCRIPT CAPITAL J +1D4DA K # MATHEMATICAL BOLD SCRIPT CAPITAL K +1D4DB L # MATHEMATICAL BOLD SCRIPT CAPITAL L +1D4DC M # MATHEMATICAL BOLD SCRIPT CAPITAL M +1D4DD N # MATHEMATICAL BOLD SCRIPT CAPITAL N +1D4DE O # MATHEMATICAL BOLD SCRIPT CAPITAL O +1D4DF P # MATHEMATICAL BOLD SCRIPT CAPITAL P +1D4E0 Q # MATHEMATICAL BOLD SCRIPT CAPITAL Q +1D4E1 R # MATHEMATICAL BOLD SCRIPT CAPITAL R +1D4E2 S # MATHEMATICAL BOLD SCRIPT CAPITAL S +1D4E3 T # MATHEMATICAL BOLD SCRIPT CAPITAL T +1D4E4 U # MATHEMATICAL BOLD SCRIPT CAPITAL U +1D4E5 V # MATHEMATICAL BOLD SCRIPT CAPITAL V +1D4E6 W # MATHEMATICAL BOLD SCRIPT CAPITAL W +1D4E7 X # MATHEMATICAL BOLD SCRIPT CAPITAL X +1D4E8 Y # MATHEMATICAL BOLD SCRIPT CAPITAL Y +1D4E9 Z # MATHEMATICAL BOLD SCRIPT CAPITAL Z +1D4EA a # MATHEMATICAL BOLD SCRIPT SMALL A +1D4EB b # MATHEMATICAL BOLD SCRIPT SMALL B +1D4EC c # MATHEMATICAL BOLD SCRIPT SMALL C +1D4ED d # MATHEMATICAL BOLD SCRIPT SMALL D +1D4EE e # MATHEMATICAL BOLD SCRIPT SMALL E +1D4EF f # MATHEMATICAL BOLD SCRIPT SMALL F +1D4F0 g # MATHEMATICAL BOLD SCRIPT SMALL G +1D4F1 h # MATHEMATICAL BOLD SCRIPT SMALL H +1D4F2 i # MATHEMATICAL BOLD SCRIPT SMALL I +1D4F3 j # MATHEMATICAL BOLD SCRIPT SMALL J +1D4F4 k # MATHEMATICAL BOLD SCRIPT SMALL K +1D4F5 l # MATHEMATICAL BOLD SCRIPT SMALL L +1D4F6 m # MATHEMATICAL BOLD SCRIPT SMALL M +1D4F7 n # MATHEMATICAL BOLD SCRIPT SMALL N +1D4F8 o # MATHEMATICAL BOLD SCRIPT SMALL O +1D4F9 p # MATHEMATICAL BOLD SCRIPT SMALL P +1D4FA q # MATHEMATICAL BOLD SCRIPT SMALL Q +1D4FB r # MATHEMATICAL BOLD SCRIPT SMALL R +1D4FC s # MATHEMATICAL BOLD SCRIPT SMALL S +1D4FD t # MATHEMATICAL BOLD SCRIPT SMALL T +1D4FE u # MATHEMATICAL BOLD SCRIPT SMALL U +1D4FF v # MATHEMATICAL BOLD SCRIPT SMALL V +1D500 w # MATHEMATICAL BOLD SCRIPT SMALL W +1D501 x # MATHEMATICAL BOLD SCRIPT SMALL X +1D502 y # MATHEMATICAL BOLD SCRIPT SMALL Y +1D503 z # MATHEMATICAL BOLD SCRIPT SMALL Z +1D504 A # MATHEMATICAL FRAKTUR CAPITAL A +1D505 B # MATHEMATICAL FRAKTUR CAPITAL B +1D507 D # MATHEMATICAL FRAKTUR CAPITAL D +1D508 E # MATHEMATICAL FRAKTUR CAPITAL E +1D509 F # MATHEMATICAL FRAKTUR CAPITAL F +1D50A G # MATHEMATICAL FRAKTUR CAPITAL G +1D50D J # MATHEMATICAL FRAKTUR CAPITAL J +1D50E K # MATHEMATICAL FRAKTUR CAPITAL K +1D50F L # MATHEMATICAL FRAKTUR CAPITAL L +1D510 M # MATHEMATICAL FRAKTUR CAPITAL M +1D511 N # MATHEMATICAL FRAKTUR CAPITAL N +1D512 O # MATHEMATICAL FRAKTUR CAPITAL O +1D513 P # MATHEMATICAL FRAKTUR CAPITAL P +1D514 Q # MATHEMATICAL FRAKTUR CAPITAL Q +1D516 S # MATHEMATICAL FRAKTUR CAPITAL S +1D517 T # MATHEMATICAL FRAKTUR CAPITAL T +1D518 U # MATHEMATICAL FRAKTUR CAPITAL U +1D519 V # MATHEMATICAL FRAKTUR CAPITAL V +1D51A W # MATHEMATICAL FRAKTUR CAPITAL W +1D51B X # MATHEMATICAL FRAKTUR CAPITAL X +1D51C Y # MATHEMATICAL FRAKTUR CAPITAL Y +1D51E a # MATHEMATICAL FRAKTUR SMALL A +1D51F b # MATHEMATICAL FRAKTUR SMALL B +1D520 c # MATHEMATICAL FRAKTUR SMALL C +1D521 d # MATHEMATICAL FRAKTUR SMALL D +1D522 e # MATHEMATICAL FRAKTUR SMALL E +1D523 f # MATHEMATICAL FRAKTUR SMALL F +1D524 g # MATHEMATICAL FRAKTUR SMALL G +1D525 h # MATHEMATICAL FRAKTUR SMALL H +1D526 i # MATHEMATICAL FRAKTUR SMALL I +1D527 j # MATHEMATICAL FRAKTUR SMALL J +1D528 k # MATHEMATICAL FRAKTUR SMALL K +1D529 l # MATHEMATICAL FRAKTUR SMALL L +1D52A m # MATHEMATICAL FRAKTUR SMALL M +1D52B n # MATHEMATICAL FRAKTUR SMALL N +1D52C o # MATHEMATICAL FRAKTUR SMALL O +1D52D p # MATHEMATICAL FRAKTUR SMALL P +1D52E q # MATHEMATICAL FRAKTUR SMALL Q +1D52F r # MATHEMATICAL FRAKTUR SMALL R +1D530 s # MATHEMATICAL FRAKTUR SMALL S +1D531 t # MATHEMATICAL FRAKTUR SMALL T +1D532 u # MATHEMATICAL FRAKTUR SMALL U +1D533 v # MATHEMATICAL FRAKTUR SMALL V +1D534 w # MATHEMATICAL FRAKTUR SMALL W +1D535 x # MATHEMATICAL FRAKTUR SMALL X +1D536 y # MATHEMATICAL FRAKTUR SMALL Y +1D537 z # MATHEMATICAL FRAKTUR SMALL Z +1D538 A # MATHEMATICAL DOUBLE-STRUCK CAPITAL A +1D539 B # MATHEMATICAL DOUBLE-STRUCK CAPITAL B +1D53B D # MATHEMATICAL DOUBLE-STRUCK CAPITAL D +1D53C E # MATHEMATICAL DOUBLE-STRUCK CAPITAL E +1D53D F # MATHEMATICAL DOUBLE-STRUCK CAPITAL F +1D53E G # MATHEMATICAL DOUBLE-STRUCK CAPITAL G +1D540 I # MATHEMATICAL DOUBLE-STRUCK CAPITAL I +1D541 J # MATHEMATICAL DOUBLE-STRUCK CAPITAL J +1D542 K # MATHEMATICAL DOUBLE-STRUCK CAPITAL K +1D543 L # MATHEMATICAL DOUBLE-STRUCK CAPITAL L +1D544 M # MATHEMATICAL DOUBLE-STRUCK CAPITAL M +1D546 O # MATHEMATICAL DOUBLE-STRUCK CAPITAL O +1D54A S # MATHEMATICAL DOUBLE-STRUCK CAPITAL S +1D54B T # MATHEMATICAL DOUBLE-STRUCK CAPITAL T +1D54C U # MATHEMATICAL DOUBLE-STRUCK CAPITAL U +1D54D V # MATHEMATICAL DOUBLE-STRUCK CAPITAL V +1D54E W # MATHEMATICAL DOUBLE-STRUCK CAPITAL W +1D54F X # MATHEMATICAL DOUBLE-STRUCK CAPITAL X +1D550 Y # MATHEMATICAL DOUBLE-STRUCK CAPITAL Y +1D552 a # MATHEMATICAL DOUBLE-STRUCK SMALL A +1D553 b # MATHEMATICAL DOUBLE-STRUCK SMALL B +1D554 c # MATHEMATICAL DOUBLE-STRUCK SMALL C +1D555 d # MATHEMATICAL DOUBLE-STRUCK SMALL D +1D556 e # MATHEMATICAL DOUBLE-STRUCK SMALL E +1D557 f # MATHEMATICAL DOUBLE-STRUCK SMALL F +1D558 g # MATHEMATICAL DOUBLE-STRUCK SMALL G +1D559 h # MATHEMATICAL DOUBLE-STRUCK SMALL H +1D55A i # MATHEMATICAL DOUBLE-STRUCK SMALL I +1D55B j # MATHEMATICAL DOUBLE-STRUCK SMALL J +1D55C k # MATHEMATICAL DOUBLE-STRUCK SMALL K +1D55D l # MATHEMATICAL DOUBLE-STRUCK SMALL L +1D55E m # MATHEMATICAL DOUBLE-STRUCK SMALL M +1D55F n # MATHEMATICAL DOUBLE-STRUCK SMALL N +1D560 o # MATHEMATICAL DOUBLE-STRUCK SMALL O +1D561 p # MATHEMATICAL DOUBLE-STRUCK SMALL P +1D562 q # MATHEMATICAL DOUBLE-STRUCK SMALL Q +1D563 r # MATHEMATICAL DOUBLE-STRUCK SMALL R +1D564 s # MATHEMATICAL DOUBLE-STRUCK SMALL S +1D565 t # MATHEMATICAL DOUBLE-STRUCK SMALL T +1D566 u # MATHEMATICAL DOUBLE-STRUCK SMALL U +1D567 v # MATHEMATICAL DOUBLE-STRUCK SMALL V +1D568 w # MATHEMATICAL DOUBLE-STRUCK SMALL W +1D569 x # MATHEMATICAL DOUBLE-STRUCK SMALL X +1D56A y # MATHEMATICAL DOUBLE-STRUCK SMALL Y +1D56B z # MATHEMATICAL DOUBLE-STRUCK SMALL Z +1D56C A # MATHEMATICAL BOLD FRAKTUR CAPITAL A +1D56D B # MATHEMATICAL BOLD FRAKTUR CAPITAL B +1D56E C # MATHEMATICAL BOLD FRAKTUR CAPITAL C +1D56F D # MATHEMATICAL BOLD FRAKTUR CAPITAL D +1D570 E # MATHEMATICAL BOLD FRAKTUR CAPITAL E +1D571 F # MATHEMATICAL BOLD FRAKTUR CAPITAL F +1D572 G # MATHEMATICAL BOLD FRAKTUR CAPITAL G +1D573 H # MATHEMATICAL BOLD FRAKTUR CAPITAL H +1D574 I # MATHEMATICAL BOLD FRAKTUR CAPITAL I +1D575 J # MATHEMATICAL BOLD FRAKTUR CAPITAL J +1D576 K # MATHEMATICAL BOLD FRAKTUR CAPITAL K +1D577 L # MATHEMATICAL BOLD FRAKTUR CAPITAL L +1D578 M # MATHEMATICAL BOLD FRAKTUR CAPITAL M +1D579 N # MATHEMATICAL BOLD FRAKTUR CAPITAL N +1D57A O # MATHEMATICAL BOLD FRAKTUR CAPITAL O +1D57B P # MATHEMATICAL BOLD FRAKTUR CAPITAL P +1D57C Q # MATHEMATICAL BOLD FRAKTUR CAPITAL Q +1D57D R # MATHEMATICAL BOLD FRAKTUR CAPITAL R +1D57E S # MATHEMATICAL BOLD FRAKTUR CAPITAL S +1D57F T # MATHEMATICAL BOLD FRAKTUR CAPITAL T +1D580 U # MATHEMATICAL BOLD FRAKTUR CAPITAL U +1D581 V # MATHEMATICAL BOLD FRAKTUR CAPITAL V +1D582 W # MATHEMATICAL BOLD FRAKTUR CAPITAL W +1D583 X # MATHEMATICAL BOLD FRAKTUR CAPITAL X +1D584 Y # MATHEMATICAL BOLD FRAKTUR CAPITAL Y +1D585 Z # MATHEMATICAL BOLD FRAKTUR CAPITAL Z +1D586 a # MATHEMATICAL BOLD FRAKTUR SMALL A +1D587 b # MATHEMATICAL BOLD FRAKTUR SMALL B +1D588 c # MATHEMATICAL BOLD FRAKTUR SMALL C +1D589 d # MATHEMATICAL BOLD FRAKTUR SMALL D +1D58A e # MATHEMATICAL BOLD FRAKTUR SMALL E +1D58B f # MATHEMATICAL BOLD FRAKTUR SMALL F +1D58C g # MATHEMATICAL BOLD FRAKTUR SMALL G +1D58D h # MATHEMATICAL BOLD FRAKTUR SMALL H +1D58E i # MATHEMATICAL BOLD FRAKTUR SMALL I +1D58F j # MATHEMATICAL BOLD FRAKTUR SMALL J +1D590 k # MATHEMATICAL BOLD FRAKTUR SMALL K +1D591 l # MATHEMATICAL BOLD FRAKTUR SMALL L +1D592 m # MATHEMATICAL BOLD FRAKTUR SMALL M +1D593 n # MATHEMATICAL BOLD FRAKTUR SMALL N +1D594 o # MATHEMATICAL BOLD FRAKTUR SMALL O +1D595 p # MATHEMATICAL BOLD FRAKTUR SMALL P +1D596 q # MATHEMATICAL BOLD FRAKTUR SMALL Q +1D597 r # MATHEMATICAL BOLD FRAKTUR SMALL R +1D598 s # MATHEMATICAL BOLD FRAKTUR SMALL S +1D599 t # MATHEMATICAL BOLD FRAKTUR SMALL T +1D59A u # MATHEMATICAL BOLD FRAKTUR SMALL U +1D59B v # MATHEMATICAL BOLD FRAKTUR SMALL V +1D59C w # MATHEMATICAL BOLD FRAKTUR SMALL W +1D59D x # MATHEMATICAL BOLD FRAKTUR SMALL X +1D59E y # MATHEMATICAL BOLD FRAKTUR SMALL Y +1D59F z # MATHEMATICAL BOLD FRAKTUR SMALL Z +1D5A0 A # MATHEMATICAL SANS-SERIF CAPITAL A +1D5A1 B # MATHEMATICAL SANS-SERIF CAPITAL B +1D5A2 C # MATHEMATICAL SANS-SERIF CAPITAL C +1D5A3 D # MATHEMATICAL SANS-SERIF CAPITAL D +1D5A4 E # MATHEMATICAL SANS-SERIF CAPITAL E +1D5A5 F # MATHEMATICAL SANS-SERIF CAPITAL F +1D5A6 G # MATHEMATICAL SANS-SERIF CAPITAL G +1D5A7 H # MATHEMATICAL SANS-SERIF CAPITAL H +1D5A8 I # MATHEMATICAL SANS-SERIF CAPITAL I +1D5A9 J # MATHEMATICAL SANS-SERIF CAPITAL J +1D5AA K # MATHEMATICAL SANS-SERIF CAPITAL K +1D5AB L # MATHEMATICAL SANS-SERIF CAPITAL L +1D5AC M # MATHEMATICAL SANS-SERIF CAPITAL M +1D5AD N # MATHEMATICAL SANS-SERIF CAPITAL N +1D5AE O # MATHEMATICAL SANS-SERIF CAPITAL O +1D5AF P # MATHEMATICAL SANS-SERIF CAPITAL P +1D5B0 Q # MATHEMATICAL SANS-SERIF CAPITAL Q +1D5B1 R # MATHEMATICAL SANS-SERIF CAPITAL R +1D5B2 S # MATHEMATICAL SANS-SERIF CAPITAL S +1D5B3 T # MATHEMATICAL SANS-SERIF CAPITAL T +1D5B4 U # MATHEMATICAL SANS-SERIF CAPITAL U +1D5B5 V # MATHEMATICAL SANS-SERIF CAPITAL V +1D5B6 W # MATHEMATICAL SANS-SERIF CAPITAL W +1D5B7 X # MATHEMATICAL SANS-SERIF CAPITAL X +1D5B8 Y # MATHEMATICAL SANS-SERIF CAPITAL Y +1D5B9 Z # MATHEMATICAL SANS-SERIF CAPITAL Z +1D5BA a # MATHEMATICAL SANS-SERIF SMALL A +1D5BB b # MATHEMATICAL SANS-SERIF SMALL B +1D5BC c # MATHEMATICAL SANS-SERIF SMALL C +1D5BD d # MATHEMATICAL SANS-SERIF SMALL D +1D5BE e # MATHEMATICAL SANS-SERIF SMALL E +1D5BF f # MATHEMATICAL SANS-SERIF SMALL F +1D5C0 g # MATHEMATICAL SANS-SERIF SMALL G +1D5C1 h # MATHEMATICAL SANS-SERIF SMALL H +1D5C2 i # MATHEMATICAL SANS-SERIF SMALL I +1D5C3 j # MATHEMATICAL SANS-SERIF SMALL J +1D5C4 k # MATHEMATICAL SANS-SERIF SMALL K +1D5C5 l # MATHEMATICAL SANS-SERIF SMALL L +1D5C6 m # MATHEMATICAL SANS-SERIF SMALL M +1D5C7 n # MATHEMATICAL SANS-SERIF SMALL N +1D5C8 o # MATHEMATICAL SANS-SERIF SMALL O +1D5C9 p # MATHEMATICAL SANS-SERIF SMALL P +1D5CA q # MATHEMATICAL SANS-SERIF SMALL Q +1D5CB r # MATHEMATICAL SANS-SERIF SMALL R +1D5CC s # MATHEMATICAL SANS-SERIF SMALL S +1D5CD t # MATHEMATICAL SANS-SERIF SMALL T +1D5CE u # MATHEMATICAL SANS-SERIF SMALL U +1D5CF v # MATHEMATICAL SANS-SERIF SMALL V +1D5D0 w # MATHEMATICAL SANS-SERIF SMALL W +1D5D1 x # MATHEMATICAL SANS-SERIF SMALL X +1D5D2 y # MATHEMATICAL SANS-SERIF SMALL Y +1D5D3 z # MATHEMATICAL SANS-SERIF SMALL Z +1D5D4 A # MATHEMATICAL SANS-SERIF BOLD CAPITAL A +1D5D5 B # MATHEMATICAL SANS-SERIF BOLD CAPITAL B +1D5D6 C # MATHEMATICAL SANS-SERIF BOLD CAPITAL C +1D5D7 D # MATHEMATICAL SANS-SERIF BOLD CAPITAL D +1D5D8 E # MATHEMATICAL SANS-SERIF BOLD CAPITAL E +1D5D9 F # MATHEMATICAL SANS-SERIF BOLD CAPITAL F +1D5DA G # MATHEMATICAL SANS-SERIF BOLD CAPITAL G +1D5DB H # MATHEMATICAL SANS-SERIF BOLD CAPITAL H +1D5DC I # MATHEMATICAL SANS-SERIF BOLD CAPITAL I +1D5DD J # MATHEMATICAL SANS-SERIF BOLD CAPITAL J +1D5DE K # MATHEMATICAL SANS-SERIF BOLD CAPITAL K +1D5DF L # MATHEMATICAL SANS-SERIF BOLD CAPITAL L +1D5E0 M # MATHEMATICAL SANS-SERIF BOLD CAPITAL M +1D5E1 N # MATHEMATICAL SANS-SERIF BOLD CAPITAL N +1D5E2 O # MATHEMATICAL SANS-SERIF BOLD CAPITAL O +1D5E3 P # MATHEMATICAL SANS-SERIF BOLD CAPITAL P +1D5E4 Q # MATHEMATICAL SANS-SERIF BOLD CAPITAL Q +1D5E5 R # MATHEMATICAL SANS-SERIF BOLD CAPITAL R +1D5E6 S # MATHEMATICAL SANS-SERIF BOLD CAPITAL S +1D5E7 T # MATHEMATICAL SANS-SERIF BOLD CAPITAL T +1D5E8 U # MATHEMATICAL SANS-SERIF BOLD CAPITAL U +1D5E9 V # MATHEMATICAL SANS-SERIF BOLD CAPITAL V +1D5EA W # MATHEMATICAL SANS-SERIF BOLD CAPITAL W +1D5EB X # MATHEMATICAL SANS-SERIF BOLD CAPITAL X +1D5EC Y # MATHEMATICAL SANS-SERIF BOLD CAPITAL Y +1D5ED Z # MATHEMATICAL SANS-SERIF BOLD CAPITAL Z +1D5EE a # MATHEMATICAL SANS-SERIF BOLD SMALL A +1D5EF b # MATHEMATICAL SANS-SERIF BOLD SMALL B +1D5F0 c # MATHEMATICAL SANS-SERIF BOLD SMALL C +1D5F1 d # MATHEMATICAL SANS-SERIF BOLD SMALL D +1D5F2 e # MATHEMATICAL SANS-SERIF BOLD SMALL E +1D5F3 f # MATHEMATICAL SANS-SERIF BOLD SMALL F +1D5F4 g # MATHEMATICAL SANS-SERIF BOLD SMALL G +1D5F5 h # MATHEMATICAL SANS-SERIF BOLD SMALL H +1D5F6 i # MATHEMATICAL SANS-SERIF BOLD SMALL I +1D5F7 j # MATHEMATICAL SANS-SERIF BOLD SMALL J +1D5F8 k # MATHEMATICAL SANS-SERIF BOLD SMALL K +1D5F9 l # MATHEMATICAL SANS-SERIF BOLD SMALL L +1D5FA m # MATHEMATICAL SANS-SERIF BOLD SMALL M +1D5FB n # MATHEMATICAL SANS-SERIF BOLD SMALL N +1D5FC o # MATHEMATICAL SANS-SERIF BOLD SMALL O +1D5FD p # MATHEMATICAL SANS-SERIF BOLD SMALL P +1D5FE q # MATHEMATICAL SANS-SERIF BOLD SMALL Q +1D5FF r # MATHEMATICAL SANS-SERIF BOLD SMALL R +1D600 s # MATHEMATICAL SANS-SERIF BOLD SMALL S +1D601 t # MATHEMATICAL SANS-SERIF BOLD SMALL T +1D602 u # MATHEMATICAL SANS-SERIF BOLD SMALL U +1D603 v # MATHEMATICAL SANS-SERIF BOLD SMALL V +1D604 w # MATHEMATICAL SANS-SERIF BOLD SMALL W +1D605 x # MATHEMATICAL SANS-SERIF BOLD SMALL X +1D606 y # MATHEMATICAL SANS-SERIF BOLD SMALL Y +1D607 z # MATHEMATICAL SANS-SERIF BOLD SMALL Z +1D608 A # MATHEMATICAL SANS-SERIF ITALIC CAPITAL A +1D609 B # MATHEMATICAL SANS-SERIF ITALIC CAPITAL B +1D60A C # MATHEMATICAL SANS-SERIF ITALIC CAPITAL C +1D60B D # MATHEMATICAL SANS-SERIF ITALIC CAPITAL D +1D60C E # MATHEMATICAL SANS-SERIF ITALIC CAPITAL E +1D60D F # MATHEMATICAL SANS-SERIF ITALIC CAPITAL F +1D60E G # MATHEMATICAL SANS-SERIF ITALIC CAPITAL G +1D60F H # MATHEMATICAL SANS-SERIF ITALIC CAPITAL H +1D610 I # MATHEMATICAL SANS-SERIF ITALIC CAPITAL I +1D611 J # MATHEMATICAL SANS-SERIF ITALIC CAPITAL J +1D612 K # MATHEMATICAL SANS-SERIF ITALIC CAPITAL K +1D613 L # MATHEMATICAL SANS-SERIF ITALIC CAPITAL L +1D614 M # MATHEMATICAL SANS-SERIF ITALIC CAPITAL M +1D615 N # MATHEMATICAL SANS-SERIF ITALIC CAPITAL N +1D616 O # MATHEMATICAL SANS-SERIF ITALIC CAPITAL O +1D617 P # MATHEMATICAL SANS-SERIF ITALIC CAPITAL P +1D618 Q # MATHEMATICAL SANS-SERIF ITALIC CAPITAL Q +1D619 R # MATHEMATICAL SANS-SERIF ITALIC CAPITAL R +1D61A S # MATHEMATICAL SANS-SERIF ITALIC CAPITAL S +1D61B T # MATHEMATICAL SANS-SERIF ITALIC CAPITAL T +1D61C U # MATHEMATICAL SANS-SERIF ITALIC CAPITAL U +1D61D V # MATHEMATICAL SANS-SERIF ITALIC CAPITAL V +1D61E W # MATHEMATICAL SANS-SERIF ITALIC CAPITAL W +1D61F X # MATHEMATICAL SANS-SERIF ITALIC CAPITAL X +1D620 Y # MATHEMATICAL SANS-SERIF ITALIC CAPITAL Y +1D621 Z # MATHEMATICAL SANS-SERIF ITALIC CAPITAL Z +1D622 a # MATHEMATICAL SANS-SERIF ITALIC SMALL A +1D623 b # MATHEMATICAL SANS-SERIF ITALIC SMALL B +1D624 c # MATHEMATICAL SANS-SERIF ITALIC SMALL C +1D625 d # MATHEMATICAL SANS-SERIF ITALIC SMALL D +1D626 e # MATHEMATICAL SANS-SERIF ITALIC SMALL E +1D627 f # MATHEMATICAL SANS-SERIF ITALIC SMALL F +1D628 g # MATHEMATICAL SANS-SERIF ITALIC SMALL G +1D629 h # MATHEMATICAL SANS-SERIF ITALIC SMALL H +1D62A i # MATHEMATICAL SANS-SERIF ITALIC SMALL I +1D62B j # MATHEMATICAL SANS-SERIF ITALIC SMALL J +1D62C k # MATHEMATICAL SANS-SERIF ITALIC SMALL K +1D62D l # MATHEMATICAL SANS-SERIF ITALIC SMALL L +1D62E m # MATHEMATICAL SANS-SERIF ITALIC SMALL M +1D62F n # MATHEMATICAL SANS-SERIF ITALIC SMALL N +1D630 o # MATHEMATICAL SANS-SERIF ITALIC SMALL O +1D631 p # MATHEMATICAL SANS-SERIF ITALIC SMALL P +1D632 q # MATHEMATICAL SANS-SERIF ITALIC SMALL Q +1D633 r # MATHEMATICAL SANS-SERIF ITALIC SMALL R +1D634 s # MATHEMATICAL SANS-SERIF ITALIC SMALL S +1D635 t # MATHEMATICAL SANS-SERIF ITALIC SMALL T +1D636 u # MATHEMATICAL SANS-SERIF ITALIC SMALL U +1D637 v # MATHEMATICAL SANS-SERIF ITALIC SMALL V +1D638 w # MATHEMATICAL SANS-SERIF ITALIC SMALL W +1D639 x # MATHEMATICAL SANS-SERIF ITALIC SMALL X +1D63A y # MATHEMATICAL SANS-SERIF ITALIC SMALL Y +1D63B z # MATHEMATICAL SANS-SERIF ITALIC SMALL Z +1D63C A # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL A +1D63D B # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL B +1D63E C # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL C +1D63F D # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL D +1D640 E # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL E +1D641 F # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL F +1D642 G # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL G +1D643 H # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL H +1D644 I # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL I +1D645 J # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL J +1D646 K # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL K +1D647 L # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL L +1D648 M # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL M +1D649 N # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL N +1D64A O # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL O +1D64B P # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL P +1D64C Q # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL Q +1D64D R # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL R +1D64E S # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL S +1D64F T # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL T +1D650 U # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL U +1D651 V # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL V +1D652 W # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL W +1D653 X # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL X +1D654 Y # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL Y +1D655 Z # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL Z +1D656 a # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL A +1D657 b # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL B +1D658 c # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL C +1D659 d # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL D +1D65A e # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL E +1D65B f # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL F +1D65C g # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL G +1D65D h # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL H +1D65E i # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL I +1D65F j # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL J +1D660 k # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL K +1D661 l # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL L +1D662 m # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL M +1D663 n # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL N +1D664 o # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL O +1D665 p # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL P +1D666 q # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL Q +1D667 r # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL R +1D668 s # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL S +1D669 t # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL T +1D66A u # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL U +1D66B v # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL V +1D66C w # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL W +1D66D x # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL X +1D66E y # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL Y +1D66F z # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL Z +1D670 A # MATHEMATICAL MONOSPACE CAPITAL A +1D671 B # MATHEMATICAL MONOSPACE CAPITAL B +1D672 C # MATHEMATICAL MONOSPACE CAPITAL C +1D673 D # MATHEMATICAL MONOSPACE CAPITAL D +1D674 E # MATHEMATICAL MONOSPACE CAPITAL E +1D675 F # MATHEMATICAL MONOSPACE CAPITAL F +1D676 G # MATHEMATICAL MONOSPACE CAPITAL G +1D677 H # MATHEMATICAL MONOSPACE CAPITAL H +1D678 I # MATHEMATICAL MONOSPACE CAPITAL I +1D679 J # MATHEMATICAL MONOSPACE CAPITAL J +1D67A K # MATHEMATICAL MONOSPACE CAPITAL K +1D67B L # MATHEMATICAL MONOSPACE CAPITAL L +1D67C M # MATHEMATICAL MONOSPACE CAPITAL M +1D67D N # MATHEMATICAL MONOSPACE CAPITAL N +1D67E O # MATHEMATICAL MONOSPACE CAPITAL O +1D67F P # MATHEMATICAL MONOSPACE CAPITAL P +1D680 Q # MATHEMATICAL MONOSPACE CAPITAL Q +1D681 R # MATHEMATICAL MONOSPACE CAPITAL R +1D682 S # MATHEMATICAL MONOSPACE CAPITAL S +1D683 T # MATHEMATICAL MONOSPACE CAPITAL T +1D684 U # MATHEMATICAL MONOSPACE CAPITAL U +1D685 V # MATHEMATICAL MONOSPACE CAPITAL V +1D686 W # MATHEMATICAL MONOSPACE CAPITAL W +1D687 X # MATHEMATICAL MONOSPACE CAPITAL X +1D688 Y # MATHEMATICAL MONOSPACE CAPITAL Y +1D689 Z # MATHEMATICAL MONOSPACE CAPITAL Z +1D68A a # MATHEMATICAL MONOSPACE SMALL A +1D68B b # MATHEMATICAL MONOSPACE SMALL B +1D68C c # MATHEMATICAL MONOSPACE SMALL C +1D68D d # MATHEMATICAL MONOSPACE SMALL D +1D68E e # MATHEMATICAL MONOSPACE SMALL E +1D68F f # MATHEMATICAL MONOSPACE SMALL F +1D690 g # MATHEMATICAL MONOSPACE SMALL G +1D691 h # MATHEMATICAL MONOSPACE SMALL H +1D692 i # MATHEMATICAL MONOSPACE SMALL I +1D693 j # MATHEMATICAL MONOSPACE SMALL J +1D694 k # MATHEMATICAL MONOSPACE SMALL K +1D695 l # MATHEMATICAL MONOSPACE SMALL L +1D696 m # MATHEMATICAL MONOSPACE SMALL M +1D697 n # MATHEMATICAL MONOSPACE SMALL N +1D698 o # MATHEMATICAL MONOSPACE SMALL O +1D699 p # MATHEMATICAL MONOSPACE SMALL P +1D69A q # MATHEMATICAL MONOSPACE SMALL Q +1D69B r # MATHEMATICAL MONOSPACE SMALL R +1D69C s # MATHEMATICAL MONOSPACE SMALL S +1D69D t # MATHEMATICAL MONOSPACE SMALL T +1D69E u # MATHEMATICAL MONOSPACE SMALL U +1D69F v # MATHEMATICAL MONOSPACE SMALL V +1D6A0 w # MATHEMATICAL MONOSPACE SMALL W +1D6A1 x # MATHEMATICAL MONOSPACE SMALL X +1D6A2 y # MATHEMATICAL MONOSPACE SMALL Y +1D6A3 z # MATHEMATICAL MONOSPACE SMALL Z +1D6A8 Α # MATHEMATICAL BOLD CAPITAL ALPHA +1D6A9 Β # MATHEMATICAL BOLD CAPITAL BETA +1D6AA Γ # MATHEMATICAL BOLD CAPITAL GAMMA +1D6AB Δ # MATHEMATICAL BOLD CAPITAL DELTA +1D6AC Ε # MATHEMATICAL BOLD CAPITAL EPSILON +1D6AD Ζ # MATHEMATICAL BOLD CAPITAL ZETA +1D6AE Η # MATHEMATICAL BOLD CAPITAL ETA +1D6AF Θ # MATHEMATICAL BOLD CAPITAL THETA +1D6B0 Ι # MATHEMATICAL BOLD CAPITAL IOTA +1D6B1 Κ # MATHEMATICAL BOLD CAPITAL KAPPA +1D6B2 Λ # MATHEMATICAL BOLD CAPITAL LAMDA +1D6B3 Μ # MATHEMATICAL BOLD CAPITAL MU +1D6B4 Ν # MATHEMATICAL BOLD CAPITAL NU +1D6B5 Ξ # MATHEMATICAL BOLD CAPITAL XI +1D6B6 Ο # MATHEMATICAL BOLD CAPITAL OMICRON +1D6B7 Π # MATHEMATICAL BOLD CAPITAL PI +1D6B8 Ρ # MATHEMATICAL BOLD CAPITAL RHO +1D6B9 ϴ # MATHEMATICAL BOLD CAPITAL THETA SYMBOL +1D6BA Σ # MATHEMATICAL BOLD CAPITAL SIGMA +1D6BB Τ # MATHEMATICAL BOLD CAPITAL TAU +1D6BC Υ # MATHEMATICAL BOLD CAPITAL UPSILON +1D6BD Φ # MATHEMATICAL BOLD CAPITAL PHI +1D6BE Χ # MATHEMATICAL BOLD CAPITAL CHI +1D6BF Ψ # MATHEMATICAL BOLD CAPITAL PSI +1D6C0 Ω # MATHEMATICAL BOLD CAPITAL OMEGA +1D6C1 ∇ # MATHEMATICAL BOLD NABLA +1D6C2 α # MATHEMATICAL BOLD SMALL ALPHA +1D6C3 β # MATHEMATICAL BOLD SMALL BETA +1D6C4 γ # MATHEMATICAL BOLD SMALL GAMMA +1D6C5 δ # MATHEMATICAL BOLD SMALL DELTA +1D6C6 ε # MATHEMATICAL BOLD SMALL EPSILON +1D6C7 ζ # MATHEMATICAL BOLD SMALL ZETA +1D6C8 η # MATHEMATICAL BOLD SMALL ETA +1D6C9 θ # MATHEMATICAL BOLD SMALL THETA +1D6CA ι # MATHEMATICAL BOLD SMALL IOTA +1D6CB κ # MATHEMATICAL BOLD SMALL KAPPA +1D6CC λ # MATHEMATICAL BOLD SMALL LAMDA +1D6CD μ # MATHEMATICAL BOLD SMALL MU +1D6CE ν # MATHEMATICAL BOLD SMALL NU +1D6CF ξ # MATHEMATICAL BOLD SMALL XI +1D6D0 ο # MATHEMATICAL BOLD SMALL OMICRON +1D6D1 π # MATHEMATICAL BOLD SMALL PI +1D6D2 ρ # MATHEMATICAL BOLD SMALL RHO +1D6D3 ς # MATHEMATICAL BOLD SMALL FINAL SIGMA +1D6D4 σ # MATHEMATICAL BOLD SMALL SIGMA +1D6D5 τ # MATHEMATICAL BOLD SMALL TAU +1D6D6 υ # MATHEMATICAL BOLD SMALL UPSILON +1D6D7 φ # MATHEMATICAL BOLD SMALL PHI +1D6D8 χ # MATHEMATICAL BOLD SMALL CHI +1D6D9 ψ # MATHEMATICAL BOLD SMALL PSI +1D6DA ω # MATHEMATICAL BOLD SMALL OMEGA +1D6DB ∂ # MATHEMATICAL BOLD PARTIAL DIFFERENTIAL +1D6DC ϵ # MATHEMATICAL BOLD EPSILON SYMBOL +1D6DD ϑ # MATHEMATICAL BOLD THETA SYMBOL +1D6DE ϰ # MATHEMATICAL BOLD KAPPA SYMBOL +1D6DF ϕ # MATHEMATICAL BOLD PHI SYMBOL +1D6E0 ϱ # MATHEMATICAL BOLD RHO SYMBOL +1D6E1 ϖ # MATHEMATICAL BOLD PI SYMBOL +1D6E2 Α # MATHEMATICAL ITALIC CAPITAL ALPHA +1D6E3 Β # MATHEMATICAL ITALIC CAPITAL BETA +1D6E4 Γ # MATHEMATICAL ITALIC CAPITAL GAMMA +1D6E5 Δ # MATHEMATICAL ITALIC CAPITAL DELTA +1D6E6 Ε # MATHEMATICAL ITALIC CAPITAL EPSILON +1D6E7 Ζ # MATHEMATICAL ITALIC CAPITAL ZETA +1D6E8 Η # MATHEMATICAL ITALIC CAPITAL ETA +1D6E9 Θ # MATHEMATICAL ITALIC CAPITAL THETA +1D6EA Ι # MATHEMATICAL ITALIC CAPITAL IOTA +1D6EB Κ # MATHEMATICAL ITALIC CAPITAL KAPPA +1D6EC Λ # MATHEMATICAL ITALIC CAPITAL LAMDA +1D6ED Μ # MATHEMATICAL ITALIC CAPITAL MU +1D6EE Ν # MATHEMATICAL ITALIC CAPITAL NU +1D6EF Ξ # MATHEMATICAL ITALIC CAPITAL XI +1D6F0 Ο # MATHEMATICAL ITALIC CAPITAL OMICRON +1D6F1 Π # MATHEMATICAL ITALIC CAPITAL PI +1D6F2 Ρ # MATHEMATICAL ITALIC CAPITAL RHO +1D6F3 ϴ # MATHEMATICAL ITALIC CAPITAL THETA SYMBOL +1D6F4 Σ # MATHEMATICAL ITALIC CAPITAL SIGMA +1D6F5 Τ # MATHEMATICAL ITALIC CAPITAL TAU +1D6F6 Υ # MATHEMATICAL ITALIC CAPITAL UPSILON +1D6F7 Φ # MATHEMATICAL ITALIC CAPITAL PHI +1D6F8 Χ # MATHEMATICAL ITALIC CAPITAL CHI +1D6F9 Ψ # MATHEMATICAL ITALIC CAPITAL PSI +1D6FA Ω # MATHEMATICAL ITALIC CAPITAL OMEGA +1D6FB ∇ # MATHEMATICAL ITALIC NABLA +1D6FC α # MATHEMATICAL ITALIC SMALL ALPHA +1D6FD β # MATHEMATICAL ITALIC SMALL BETA +1D6FE γ # MATHEMATICAL ITALIC SMALL GAMMA +1D6FF δ # MATHEMATICAL ITALIC SMALL DELTA +1D700 ε # MATHEMATICAL ITALIC SMALL EPSILON +1D701 ζ # MATHEMATICAL ITALIC SMALL ZETA +1D702 η # MATHEMATICAL ITALIC SMALL ETA +1D703 θ # MATHEMATICAL ITALIC SMALL THETA +1D704 ι # MATHEMATICAL ITALIC SMALL IOTA +1D705 κ # MATHEMATICAL ITALIC SMALL KAPPA +1D706 λ # MATHEMATICAL ITALIC SMALL LAMDA +1D707 μ # MATHEMATICAL ITALIC SMALL MU +1D708 ν # MATHEMATICAL ITALIC SMALL NU +1D709 ξ # MATHEMATICAL ITALIC SMALL XI +1D70A ο # MATHEMATICAL ITALIC SMALL OMICRON +1D70B π # MATHEMATICAL ITALIC SMALL PI +1D70C ρ # MATHEMATICAL ITALIC SMALL RHO +1D70D ς # MATHEMATICAL ITALIC SMALL FINAL SIGMA +1D70E σ # MATHEMATICAL ITALIC SMALL SIGMA +1D70F τ # MATHEMATICAL ITALIC SMALL TAU +1D710 υ # MATHEMATICAL ITALIC SMALL UPSILON +1D711 φ # MATHEMATICAL ITALIC SMALL PHI +1D712 χ # MATHEMATICAL ITALIC SMALL CHI +1D713 ψ # MATHEMATICAL ITALIC SMALL PSI +1D714 ω # MATHEMATICAL ITALIC SMALL OMEGA +1D715 ∂ # MATHEMATICAL ITALIC PARTIAL DIFFERENTIAL +1D716 ϵ # MATHEMATICAL ITALIC EPSILON SYMBOL +1D717 ϑ # MATHEMATICAL ITALIC THETA SYMBOL +1D718 ϰ # MATHEMATICAL ITALIC KAPPA SYMBOL +1D719 ϕ # MATHEMATICAL ITALIC PHI SYMBOL +1D71A ϱ # MATHEMATICAL ITALIC RHO SYMBOL +1D71B ϖ # MATHEMATICAL ITALIC PI SYMBOL +1D71C Α # MATHEMATICAL BOLD ITALIC CAPITAL ALPHA +1D71D Β # MATHEMATICAL BOLD ITALIC CAPITAL BETA +1D71E Γ # MATHEMATICAL BOLD ITALIC CAPITAL GAMMA +1D71F Δ # MATHEMATICAL BOLD ITALIC CAPITAL DELTA +1D720 Ε # MATHEMATICAL BOLD ITALIC CAPITAL EPSILON +1D721 Ζ # MATHEMATICAL BOLD ITALIC CAPITAL ZETA +1D722 Η # MATHEMATICAL BOLD ITALIC CAPITAL ETA +1D723 Θ # MATHEMATICAL BOLD ITALIC CAPITAL THETA +1D724 Ι # MATHEMATICAL BOLD ITALIC CAPITAL IOTA +1D725 Κ # MATHEMATICAL BOLD ITALIC CAPITAL KAPPA +1D726 Λ # MATHEMATICAL BOLD ITALIC CAPITAL LAMDA +1D727 Μ # MATHEMATICAL BOLD ITALIC CAPITAL MU +1D728 Ν # MATHEMATICAL BOLD ITALIC CAPITAL NU +1D729 Ξ # MATHEMATICAL BOLD ITALIC CAPITAL XI +1D72A Ο # MATHEMATICAL BOLD ITALIC CAPITAL OMICRON +1D72B Π # MATHEMATICAL BOLD ITALIC CAPITAL PI +1D72C Ρ # MATHEMATICAL BOLD ITALIC CAPITAL RHO +1D72D ϴ # MATHEMATICAL BOLD ITALIC CAPITAL THETA SYMBOL +1D72E Σ # MATHEMATICAL BOLD ITALIC CAPITAL SIGMA +1D72F Τ # MATHEMATICAL BOLD ITALIC CAPITAL TAU +1D730 Υ # MATHEMATICAL BOLD ITALIC CAPITAL UPSILON +1D731 Φ # MATHEMATICAL BOLD ITALIC CAPITAL PHI +1D732 Χ # MATHEMATICAL BOLD ITALIC CAPITAL CHI +1D733 Ψ # MATHEMATICAL BOLD ITALIC CAPITAL PSI +1D734 Ω # MATHEMATICAL BOLD ITALIC CAPITAL OMEGA +1D735 ∇ # MATHEMATICAL BOLD ITALIC NABLA +1D736 α # MATHEMATICAL BOLD ITALIC SMALL ALPHA +1D737 β # MATHEMATICAL BOLD ITALIC SMALL BETA +1D738 γ # MATHEMATICAL BOLD ITALIC SMALL GAMMA +1D739 δ # MATHEMATICAL BOLD ITALIC SMALL DELTA +1D73A ε # MATHEMATICAL BOLD ITALIC SMALL EPSILON +1D73B ζ # MATHEMATICAL BOLD ITALIC SMALL ZETA +1D73C η # MATHEMATICAL BOLD ITALIC SMALL ETA +1D73D θ # MATHEMATICAL BOLD ITALIC SMALL THETA +1D73E ι # MATHEMATICAL BOLD ITALIC SMALL IOTA +1D73F κ # MATHEMATICAL BOLD ITALIC SMALL KAPPA +1D740 λ # MATHEMATICAL BOLD ITALIC SMALL LAMDA +1D741 μ # MATHEMATICAL BOLD ITALIC SMALL MU +1D742 ν # MATHEMATICAL BOLD ITALIC SMALL NU +1D743 ξ # MATHEMATICAL BOLD ITALIC SMALL XI +1D744 ο # MATHEMATICAL BOLD ITALIC SMALL OMICRON +1D745 π # MATHEMATICAL BOLD ITALIC SMALL PI +1D746 ρ # MATHEMATICAL BOLD ITALIC SMALL RHO +1D747 ς # MATHEMATICAL BOLD ITALIC SMALL FINAL SIGMA +1D748 σ # MATHEMATICAL BOLD ITALIC SMALL SIGMA +1D749 τ # MATHEMATICAL BOLD ITALIC SMALL TAU +1D74A υ # MATHEMATICAL BOLD ITALIC SMALL UPSILON +1D74B φ # MATHEMATICAL BOLD ITALIC SMALL PHI +1D74C χ # MATHEMATICAL BOLD ITALIC SMALL CHI +1D74D ψ # MATHEMATICAL BOLD ITALIC SMALL PSI +1D74E ω # MATHEMATICAL BOLD ITALIC SMALL OMEGA +1D74F ∂ # MATHEMATICAL BOLD ITALIC PARTIAL DIFFERENTIAL +1D750 ϵ # MATHEMATICAL BOLD ITALIC EPSILON SYMBOL +1D751 ϑ # MATHEMATICAL BOLD ITALIC THETA SYMBOL +1D752 ϰ # MATHEMATICAL BOLD ITALIC KAPPA SYMBOL +1D753 ϕ # MATHEMATICAL BOLD ITALIC PHI SYMBOL +1D754 ϱ # MATHEMATICAL BOLD ITALIC RHO SYMBOL +1D755 ϖ # MATHEMATICAL BOLD ITALIC PI SYMBOL +1D756 Α # MATHEMATICAL SANS-SERIF BOLD CAPITAL ALPHA +1D757 Β # MATHEMATICAL SANS-SERIF BOLD CAPITAL BETA +1D758 Γ # MATHEMATICAL SANS-SERIF BOLD CAPITAL GAMMA +1D759 Δ # MATHEMATICAL SANS-SERIF BOLD CAPITAL DELTA +1D75A Ε # MATHEMATICAL SANS-SERIF BOLD CAPITAL EPSILON +1D75B Ζ # MATHEMATICAL SANS-SERIF BOLD CAPITAL ZETA +1D75C Η # MATHEMATICAL SANS-SERIF BOLD CAPITAL ETA +1D75D Θ # MATHEMATICAL SANS-SERIF BOLD CAPITAL THETA +1D75E Ι # MATHEMATICAL SANS-SERIF BOLD CAPITAL IOTA +1D75F Κ # MATHEMATICAL SANS-SERIF BOLD CAPITAL KAPPA +1D760 Λ # MATHEMATICAL SANS-SERIF BOLD CAPITAL LAMDA +1D761 Μ # MATHEMATICAL SANS-SERIF BOLD CAPITAL MU +1D762 Ν # MATHEMATICAL SANS-SERIF BOLD CAPITAL NU +1D763 Ξ # MATHEMATICAL SANS-SERIF BOLD CAPITAL XI +1D764 Ο # MATHEMATICAL SANS-SERIF BOLD CAPITAL OMICRON +1D765 Π # MATHEMATICAL SANS-SERIF BOLD CAPITAL PI +1D766 Ρ # MATHEMATICAL SANS-SERIF BOLD CAPITAL RHO +1D767 ϴ # MATHEMATICAL SANS-SERIF BOLD CAPITAL THETA SYMBOL +1D768 Σ # MATHEMATICAL SANS-SERIF BOLD CAPITAL SIGMA +1D769 Τ # MATHEMATICAL SANS-SERIF BOLD CAPITAL TAU +1D76A Υ # MATHEMATICAL SANS-SERIF BOLD CAPITAL UPSILON +1D76B Φ # MATHEMATICAL SANS-SERIF BOLD CAPITAL PHI +1D76C Χ # MATHEMATICAL SANS-SERIF BOLD CAPITAL CHI +1D76D Ψ # MATHEMATICAL SANS-SERIF BOLD CAPITAL PSI +1D76E Ω # MATHEMATICAL SANS-SERIF BOLD CAPITAL OMEGA +1D76F ∇ # MATHEMATICAL SANS-SERIF BOLD NABLA +1D770 α # MATHEMATICAL SANS-SERIF BOLD SMALL ALPHA +1D771 β # MATHEMATICAL SANS-SERIF BOLD SMALL BETA +1D772 γ # MATHEMATICAL SANS-SERIF BOLD SMALL GAMMA +1D773 δ # MATHEMATICAL SANS-SERIF BOLD SMALL DELTA +1D774 ε # MATHEMATICAL SANS-SERIF BOLD SMALL EPSILON +1D775 ζ # MATHEMATICAL SANS-SERIF BOLD SMALL ZETA +1D776 η # MATHEMATICAL SANS-SERIF BOLD SMALL ETA +1D777 θ # MATHEMATICAL SANS-SERIF BOLD SMALL THETA +1D778 ι # MATHEMATICAL SANS-SERIF BOLD SMALL IOTA +1D779 κ # MATHEMATICAL SANS-SERIF BOLD SMALL KAPPA +1D77A λ # MATHEMATICAL SANS-SERIF BOLD SMALL LAMDA +1D77B μ # MATHEMATICAL SANS-SERIF BOLD SMALL MU +1D77C ν # MATHEMATICAL SANS-SERIF BOLD SMALL NU +1D77D ξ # MATHEMATICAL SANS-SERIF BOLD SMALL XI +1D77E ο # MATHEMATICAL SANS-SERIF BOLD SMALL OMICRON +1D77F π # MATHEMATICAL SANS-SERIF BOLD SMALL PI +1D780 ρ # MATHEMATICAL SANS-SERIF BOLD SMALL RHO +1D781 ς # MATHEMATICAL SANS-SERIF BOLD SMALL FINAL SIGMA +1D782 σ # MATHEMATICAL SANS-SERIF BOLD SMALL SIGMA +1D783 τ # MATHEMATICAL SANS-SERIF BOLD SMALL TAU +1D784 υ # MATHEMATICAL SANS-SERIF BOLD SMALL UPSILON +1D785 φ # MATHEMATICAL SANS-SERIF BOLD SMALL PHI +1D786 χ # MATHEMATICAL SANS-SERIF BOLD SMALL CHI +1D787 ψ # MATHEMATICAL SANS-SERIF BOLD SMALL PSI +1D788 ω # MATHEMATICAL SANS-SERIF BOLD SMALL OMEGA +1D789 ∂ # MATHEMATICAL SANS-SERIF BOLD PARTIAL DIFFERENTIAL +1D78A ϵ # MATHEMATICAL SANS-SERIF BOLD EPSILON SYMBOL +1D78B ϑ # MATHEMATICAL SANS-SERIF BOLD THETA SYMBOL +1D78C ϰ # MATHEMATICAL SANS-SERIF BOLD KAPPA SYMBOL +1D78D ϕ # MATHEMATICAL SANS-SERIF BOLD PHI SYMBOL +1D78E ϱ # MATHEMATICAL SANS-SERIF BOLD RHO SYMBOL +1D78F ϖ # MATHEMATICAL SANS-SERIF BOLD PI SYMBOL +1D790 Α # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL ALPHA +1D791 Β # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL BETA +1D792 Γ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL GAMMA +1D793 Δ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL DELTA +1D794 Ε # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL EPSILON +1D795 Ζ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL ZETA +1D796 Η # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL ETA +1D797 Θ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL THETA +1D798 Ι # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL IOTA +1D799 Κ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL KAPPA +1D79A Λ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL LAMDA +1D79B Μ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL MU +1D79C Ν # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL NU +1D79D Ξ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL XI +1D79E Ο # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL OMICRON +1D79F Π # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL PI +1D7A0 Ρ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL RHO +1D7A1 ϴ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL THETA SYMBOL +1D7A2 Σ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL SIGMA +1D7A3 Τ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL TAU +1D7A4 Υ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL UPSILON +1D7A5 Φ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL PHI +1D7A6 Χ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL CHI +1D7A7 Ψ # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL PSI +1D7A8 Ω # MATHEMATICAL SANS-SERIF BOLD ITALIC CAPITAL OMEGA +1D7A9 ∇ # MATHEMATICAL SANS-SERIF BOLD ITALIC NABLA +1D7AA α # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL ALPHA +1D7AB β # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL BETA +1D7AC γ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL GAMMA +1D7AD δ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL DELTA +1D7AE ε # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL EPSILON +1D7AF ζ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL ZETA +1D7B0 η # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL ETA +1D7B1 θ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL THETA +1D7B2 ι # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL IOTA +1D7B3 κ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL KAPPA +1D7B4 λ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL LAMDA +1D7B5 μ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL MU +1D7B6 ν # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL NU +1D7B7 ξ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL XI +1D7B8 ο # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL OMICRON +1D7B9 π # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL PI +1D7BA ρ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL RHO +1D7BB ς # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL FINAL SIGMA +1D7BC σ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL SIGMA +1D7BD τ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL TAU +1D7BE υ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL UPSILON +1D7BF φ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL PHI +1D7C0 χ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL CHI +1D7C1 ψ # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL PSI +1D7C2 ω # MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL OMEGA +1D7C3 ∂ # MATHEMATICAL SANS-SERIF BOLD ITALIC PARTIAL DIFFERENTIAL +1D7C4 ϵ # MATHEMATICAL SANS-SERIF BOLD ITALIC EPSILON SYMBOL +1D7C5 ϑ # MATHEMATICAL SANS-SERIF BOLD ITALIC THETA SYMBOL +1D7C6 ϰ # MATHEMATICAL SANS-SERIF BOLD ITALIC KAPPA SYMBOL +1D7C7 ϕ # MATHEMATICAL SANS-SERIF BOLD ITALIC PHI SYMBOL +1D7C8 ϱ # MATHEMATICAL SANS-SERIF BOLD ITALIC RHO SYMBOL +1D7C9 ϖ # MATHEMATICAL SANS-SERIF BOLD ITALIC PI SYMBOL +1D7CE 0 # MATHEMATICAL BOLD DIGIT ZERO +1D7CF 1 # MATHEMATICAL BOLD DIGIT ONE +1D7D0 2 # MATHEMATICAL BOLD DIGIT TWO +1D7D1 3 # MATHEMATICAL BOLD DIGIT THREE +1D7D2 4 # MATHEMATICAL BOLD DIGIT FOUR +1D7D3 5 # MATHEMATICAL BOLD DIGIT FIVE +1D7D4 6 # MATHEMATICAL BOLD DIGIT SIX +1D7D5 7 # MATHEMATICAL BOLD DIGIT SEVEN +1D7D6 8 # MATHEMATICAL BOLD DIGIT EIGHT +1D7D7 9 # MATHEMATICAL BOLD DIGIT NINE +1D7D8 0 # MATHEMATICAL DOUBLE-STRUCK DIGIT ZERO +1D7D9 1 # MATHEMATICAL DOUBLE-STRUCK DIGIT ONE +1D7DA 2 # MATHEMATICAL DOUBLE-STRUCK DIGIT TWO +1D7DB 3 # MATHEMATICAL DOUBLE-STRUCK DIGIT THREE +1D7DC 4 # MATHEMATICAL DOUBLE-STRUCK DIGIT FOUR +1D7DD 5 # MATHEMATICAL DOUBLE-STRUCK DIGIT FIVE +1D7DE 6 # MATHEMATICAL DOUBLE-STRUCK DIGIT SIX +1D7DF 7 # MATHEMATICAL DOUBLE-STRUCK DIGIT SEVEN +1D7E0 8 # MATHEMATICAL DOUBLE-STRUCK DIGIT EIGHT +1D7E1 9 # MATHEMATICAL DOUBLE-STRUCK DIGIT NINE +1D7E2 0 # MATHEMATICAL SANS-SERIF DIGIT ZERO +1D7E3 1 # MATHEMATICAL SANS-SERIF DIGIT ONE +1D7E4 2 # MATHEMATICAL SANS-SERIF DIGIT TWO +1D7E5 3 # MATHEMATICAL SANS-SERIF DIGIT THREE +1D7E6 4 # MATHEMATICAL SANS-SERIF DIGIT FOUR +1D7E7 5 # MATHEMATICAL SANS-SERIF DIGIT FIVE +1D7E8 6 # MATHEMATICAL SANS-SERIF DIGIT SIX +1D7E9 7 # MATHEMATICAL SANS-SERIF DIGIT SEVEN +1D7EA 8 # MATHEMATICAL SANS-SERIF DIGIT EIGHT +1D7EB 9 # MATHEMATICAL SANS-SERIF DIGIT NINE +1D7EC 0 # MATHEMATICAL SANS-SERIF BOLD DIGIT ZERO +1D7ED 1 # MATHEMATICAL SANS-SERIF BOLD DIGIT ONE +1D7EE 2 # MATHEMATICAL SANS-SERIF BOLD DIGIT TWO +1D7EF 3 # MATHEMATICAL SANS-SERIF BOLD DIGIT THREE +1D7F0 4 # MATHEMATICAL SANS-SERIF BOLD DIGIT FOUR +1D7F1 5 # MATHEMATICAL SANS-SERIF BOLD DIGIT FIVE +1D7F2 6 # MATHEMATICAL SANS-SERIF BOLD DIGIT SIX +1D7F3 7 # MATHEMATICAL SANS-SERIF BOLD DIGIT SEVEN +1D7F4 8 # MATHEMATICAL SANS-SERIF BOLD DIGIT EIGHT +1D7F5 9 # MATHEMATICAL SANS-SERIF BOLD DIGIT NINE +1D7F6 0 # MATHEMATICAL MONOSPACE DIGIT ZERO +1D7F7 1 # MATHEMATICAL MONOSPACE DIGIT ONE +1D7F8 2 # MATHEMATICAL MONOSPACE DIGIT TWO +1D7F9 3 # MATHEMATICAL MONOSPACE DIGIT THREE +1D7FA 4 # MATHEMATICAL MONOSPACE DIGIT FOUR +1D7FB 5 # MATHEMATICAL MONOSPACE DIGIT FIVE +1D7FC 6 # MATHEMATICAL MONOSPACE DIGIT SIX +1D7FD 7 # MATHEMATICAL MONOSPACE DIGIT SEVEN +1D7FE 8 # MATHEMATICAL MONOSPACE DIGIT EIGHT +1D7FF 9 # MATHEMATICAL MONOSPACE DIGIT NINE +2F800 丽 # CJK COMPATIBILITY IDEOGRAPH-2F800 +2F801 丸 # CJK COMPATIBILITY IDEOGRAPH-2F801 +2F802 乁 # CJK COMPATIBILITY IDEOGRAPH-2F802 +2F803 𠄢 # CJK COMPATIBILITY IDEOGRAPH-2F803 +2F804 你 # CJK COMPATIBILITY IDEOGRAPH-2F804 +2F805 侮 # CJK COMPATIBILITY IDEOGRAPH-2F805 +2F806 侻 # CJK COMPATIBILITY IDEOGRAPH-2F806 +2F807 倂 # CJK COMPATIBILITY IDEOGRAPH-2F807 +2F808 偺 # CJK COMPATIBILITY IDEOGRAPH-2F808 +2F809 備 # CJK COMPATIBILITY IDEOGRAPH-2F809 +2F80A 僧 # CJK COMPATIBILITY IDEOGRAPH-2F80A +2F80B 像 # CJK COMPATIBILITY IDEOGRAPH-2F80B +2F80C 㒞 # CJK COMPATIBILITY IDEOGRAPH-2F80C +2F80D 𠘺 # CJK COMPATIBILITY IDEOGRAPH-2F80D +2F80E 免 # CJK COMPATIBILITY IDEOGRAPH-2F80E +2F80F 兔 # CJK COMPATIBILITY IDEOGRAPH-2F80F +2F810 兤 # CJK COMPATIBILITY IDEOGRAPH-2F810 +2F811 具 # CJK COMPATIBILITY IDEOGRAPH-2F811 +2F812 𠔜 # CJK COMPATIBILITY IDEOGRAPH-2F812 +2F813 㒹 # CJK COMPATIBILITY IDEOGRAPH-2F813 +2F814 內 # CJK COMPATIBILITY IDEOGRAPH-2F814 +2F815 再 # CJK COMPATIBILITY IDEOGRAPH-2F815 +2F816 𠕋 # CJK COMPATIBILITY IDEOGRAPH-2F816 +2F817 冗 # CJK COMPATIBILITY IDEOGRAPH-2F817 +2F818 冤 # CJK COMPATIBILITY IDEOGRAPH-2F818 +2F819 仌 # CJK COMPATIBILITY IDEOGRAPH-2F819 +2F81A 冬 # CJK COMPATIBILITY IDEOGRAPH-2F81A +2F81B 况 # CJK COMPATIBILITY IDEOGRAPH-2F81B +2F81C 𩇟 # CJK COMPATIBILITY IDEOGRAPH-2F81C +2F81D 凵 # CJK COMPATIBILITY IDEOGRAPH-2F81D +2F81E 刃 # CJK COMPATIBILITY IDEOGRAPH-2F81E +2F81F 㓟 # CJK COMPATIBILITY IDEOGRAPH-2F81F +2F820 刻 # CJK COMPATIBILITY IDEOGRAPH-2F820 +2F821 剆 # CJK COMPATIBILITY IDEOGRAPH-2F821 +2F822 割 # CJK COMPATIBILITY IDEOGRAPH-2F822 +2F823 剷 # CJK COMPATIBILITY IDEOGRAPH-2F823 +2F824 㔕 # CJK COMPATIBILITY IDEOGRAPH-2F824 +2F825 勇 # CJK COMPATIBILITY IDEOGRAPH-2F825 +2F826 勉 # CJK COMPATIBILITY IDEOGRAPH-2F826 +2F827 勤 # CJK COMPATIBILITY IDEOGRAPH-2F827 +2F828 勺 # CJK COMPATIBILITY IDEOGRAPH-2F828 +2F829 包 # CJK COMPATIBILITY IDEOGRAPH-2F829 +2F82A 匆 # CJK COMPATIBILITY IDEOGRAPH-2F82A +2F82B 北 # CJK COMPATIBILITY IDEOGRAPH-2F82B +2F82C 卉 # CJK COMPATIBILITY IDEOGRAPH-2F82C +2F82D 卑 # CJK COMPATIBILITY IDEOGRAPH-2F82D +2F82E 博 # CJK COMPATIBILITY IDEOGRAPH-2F82E +2F82F 即 # CJK COMPATIBILITY IDEOGRAPH-2F82F +2F830 卽 # CJK COMPATIBILITY IDEOGRAPH-2F830 +2F831 卿 # CJK COMPATIBILITY IDEOGRAPH-2F831 +2F832 卿 # CJK COMPATIBILITY IDEOGRAPH-2F832 +2F833 卿 # CJK COMPATIBILITY IDEOGRAPH-2F833 +2F834 𠨬 # CJK COMPATIBILITY IDEOGRAPH-2F834 +2F835 灰 # CJK COMPATIBILITY IDEOGRAPH-2F835 +2F836 及 # CJK COMPATIBILITY IDEOGRAPH-2F836 +2F837 叟 # CJK COMPATIBILITY IDEOGRAPH-2F837 +2F838 𠭣 # CJK COMPATIBILITY IDEOGRAPH-2F838 +2F839 叫 # CJK COMPATIBILITY IDEOGRAPH-2F839 +2F83A 叱 # CJK COMPATIBILITY IDEOGRAPH-2F83A +2F83B 吆 # CJK COMPATIBILITY IDEOGRAPH-2F83B +2F83C 咞 # CJK COMPATIBILITY IDEOGRAPH-2F83C +2F83D 吸 # CJK COMPATIBILITY IDEOGRAPH-2F83D +2F83E 呈 # CJK COMPATIBILITY IDEOGRAPH-2F83E +2F83F 周 # CJK COMPATIBILITY IDEOGRAPH-2F83F +2F840 咢 # CJK COMPATIBILITY IDEOGRAPH-2F840 +2F841 哶 # CJK COMPATIBILITY IDEOGRAPH-2F841 +2F842 唐 # CJK COMPATIBILITY IDEOGRAPH-2F842 +2F843 啓 # CJK COMPATIBILITY IDEOGRAPH-2F843 +2F844 啣 # CJK COMPATIBILITY IDEOGRAPH-2F844 +2F845 善 # CJK COMPATIBILITY IDEOGRAPH-2F845 +2F846 善 # CJK COMPATIBILITY IDEOGRAPH-2F846 +2F847 喙 # CJK COMPATIBILITY IDEOGRAPH-2F847 +2F848 喫 # CJK COMPATIBILITY IDEOGRAPH-2F848 +2F849 喳 # CJK COMPATIBILITY IDEOGRAPH-2F849 +2F84A 嗂 # CJK COMPATIBILITY IDEOGRAPH-2F84A +2F84B 圖 # CJK COMPATIBILITY IDEOGRAPH-2F84B +2F84C 嘆 # CJK COMPATIBILITY IDEOGRAPH-2F84C +2F84D 圗 # CJK COMPATIBILITY IDEOGRAPH-2F84D +2F84E 噑 # CJK COMPATIBILITY IDEOGRAPH-2F84E +2F84F 噴 # CJK COMPATIBILITY IDEOGRAPH-2F84F +2F850 切 # CJK COMPATIBILITY IDEOGRAPH-2F850 +2F851 壮 # CJK COMPATIBILITY IDEOGRAPH-2F851 +2F852 城 # CJK COMPATIBILITY IDEOGRAPH-2F852 +2F853 埴 # CJK COMPATIBILITY IDEOGRAPH-2F853 +2F854 堍 # CJK COMPATIBILITY IDEOGRAPH-2F854 +2F855 型 # CJK COMPATIBILITY IDEOGRAPH-2F855 +2F856 堲 # CJK COMPATIBILITY IDEOGRAPH-2F856 +2F857 報 # CJK COMPATIBILITY IDEOGRAPH-2F857 +2F858 墬 # CJK COMPATIBILITY IDEOGRAPH-2F858 +2F859 𡓤 # CJK COMPATIBILITY IDEOGRAPH-2F859 +2F85A 売 # CJK COMPATIBILITY IDEOGRAPH-2F85A +2F85B 壷 # CJK COMPATIBILITY IDEOGRAPH-2F85B +2F85C 夆 # CJK COMPATIBILITY IDEOGRAPH-2F85C +2F85D 多 # CJK COMPATIBILITY IDEOGRAPH-2F85D +2F85E 夢 # CJK COMPATIBILITY IDEOGRAPH-2F85E +2F85F 奢 # CJK COMPATIBILITY IDEOGRAPH-2F85F +2F860 𡚨 # CJK COMPATIBILITY IDEOGRAPH-2F860 +2F861 𡛪 # CJK COMPATIBILITY IDEOGRAPH-2F861 +2F862 姬 # CJK COMPATIBILITY IDEOGRAPH-2F862 +2F863 娛 # CJK COMPATIBILITY IDEOGRAPH-2F863 +2F864 娧 # CJK COMPATIBILITY IDEOGRAPH-2F864 +2F865 姘 # CJK COMPATIBILITY IDEOGRAPH-2F865 +2F866 婦 # CJK COMPATIBILITY IDEOGRAPH-2F866 +2F867 㛮 # CJK COMPATIBILITY IDEOGRAPH-2F867 +2F868 㛼 # CJK COMPATIBILITY IDEOGRAPH-2F868 +2F869 嬈 # CJK COMPATIBILITY IDEOGRAPH-2F869 +2F86A 嬾 # CJK COMPATIBILITY IDEOGRAPH-2F86A +2F86B 嬾 # CJK COMPATIBILITY IDEOGRAPH-2F86B +2F86C 𡧈 # CJK COMPATIBILITY IDEOGRAPH-2F86C +2F86D 寃 # CJK COMPATIBILITY IDEOGRAPH-2F86D +2F86E 寘 # CJK COMPATIBILITY IDEOGRAPH-2F86E +2F86F 寧 # CJK COMPATIBILITY IDEOGRAPH-2F86F +2F870 寳 # CJK COMPATIBILITY IDEOGRAPH-2F870 +2F871 𡬘 # CJK COMPATIBILITY IDEOGRAPH-2F871 +2F872 寿 # CJK COMPATIBILITY IDEOGRAPH-2F872 +2F873 将 # CJK COMPATIBILITY IDEOGRAPH-2F873 +2F874 当 # CJK COMPATIBILITY IDEOGRAPH-2F874 +2F875 尢 # CJK COMPATIBILITY IDEOGRAPH-2F875 +2F876 㞁 # CJK COMPATIBILITY IDEOGRAPH-2F876 +2F877 屠 # CJK COMPATIBILITY IDEOGRAPH-2F877 +2F878 屮 # CJK COMPATIBILITY IDEOGRAPH-2F878 +2F879 峀 # CJK COMPATIBILITY IDEOGRAPH-2F879 +2F87A 岍 # CJK COMPATIBILITY IDEOGRAPH-2F87A +2F87B 𡷤 # CJK COMPATIBILITY IDEOGRAPH-2F87B +2F87C 嵃 # CJK COMPATIBILITY IDEOGRAPH-2F87C +2F87D 𡷦 # CJK COMPATIBILITY IDEOGRAPH-2F87D +2F87E 嵮 # CJK COMPATIBILITY IDEOGRAPH-2F87E +2F87F 嵫 # CJK COMPATIBILITY IDEOGRAPH-2F87F +2F880 嵼 # CJK COMPATIBILITY IDEOGRAPH-2F880 +2F881 巡 # CJK COMPATIBILITY IDEOGRAPH-2F881 +2F882 巢 # CJK COMPATIBILITY IDEOGRAPH-2F882 +2F883 㠯 # CJK COMPATIBILITY IDEOGRAPH-2F883 +2F884 巽 # CJK COMPATIBILITY IDEOGRAPH-2F884 +2F885 帨 # CJK COMPATIBILITY IDEOGRAPH-2F885 +2F886 帽 # CJK COMPATIBILITY IDEOGRAPH-2F886 +2F887 幩 # CJK COMPATIBILITY IDEOGRAPH-2F887 +2F888 㡢 # CJK COMPATIBILITY IDEOGRAPH-2F888 +2F889 𢆃 # CJK COMPATIBILITY IDEOGRAPH-2F889 +2F88A 㡼 # CJK COMPATIBILITY IDEOGRAPH-2F88A +2F88B 庰 # CJK COMPATIBILITY IDEOGRAPH-2F88B +2F88C 庳 # CJK COMPATIBILITY IDEOGRAPH-2F88C +2F88D 庶 # CJK COMPATIBILITY IDEOGRAPH-2F88D +2F88E 廊 # CJK COMPATIBILITY IDEOGRAPH-2F88E +2F88F 𪎒 # CJK COMPATIBILITY IDEOGRAPH-2F88F +2F890 廾 # CJK COMPATIBILITY IDEOGRAPH-2F890 +2F891 𢌱 # CJK COMPATIBILITY IDEOGRAPH-2F891 +2F892 𢌱 # CJK COMPATIBILITY IDEOGRAPH-2F892 +2F893 舁 # CJK COMPATIBILITY IDEOGRAPH-2F893 +2F894 弢 # CJK COMPATIBILITY IDEOGRAPH-2F894 +2F895 弢 # CJK COMPATIBILITY IDEOGRAPH-2F895 +2F896 㣇 # CJK COMPATIBILITY IDEOGRAPH-2F896 +2F897 𣊸 # CJK COMPATIBILITY IDEOGRAPH-2F897 +2F898 𦇚 # CJK COMPATIBILITY IDEOGRAPH-2F898 +2F899 形 # CJK COMPATIBILITY IDEOGRAPH-2F899 +2F89A 彫 # CJK COMPATIBILITY IDEOGRAPH-2F89A +2F89B 㣣 # CJK COMPATIBILITY IDEOGRAPH-2F89B +2F89C 徚 # CJK COMPATIBILITY IDEOGRAPH-2F89C +2F89D 忍 # CJK COMPATIBILITY IDEOGRAPH-2F89D +2F89E 志 # CJK COMPATIBILITY IDEOGRAPH-2F89E +2F89F 忹 # CJK COMPATIBILITY IDEOGRAPH-2F89F +2F8A0 悁 # CJK COMPATIBILITY IDEOGRAPH-2F8A0 +2F8A1 㤺 # CJK COMPATIBILITY IDEOGRAPH-2F8A1 +2F8A2 㤜 # CJK COMPATIBILITY IDEOGRAPH-2F8A2 +2F8A3 悔 # CJK COMPATIBILITY IDEOGRAPH-2F8A3 +2F8A4 𢛔 # CJK COMPATIBILITY IDEOGRAPH-2F8A4 +2F8A5 惇 # CJK COMPATIBILITY IDEOGRAPH-2F8A5 +2F8A6 慈 # CJK COMPATIBILITY IDEOGRAPH-2F8A6 +2F8A7 慌 # CJK COMPATIBILITY IDEOGRAPH-2F8A7 +2F8A8 慎 # CJK COMPATIBILITY IDEOGRAPH-2F8A8 +2F8A9 慌 # CJK COMPATIBILITY IDEOGRAPH-2F8A9 +2F8AA 慺 # CJK COMPATIBILITY IDEOGRAPH-2F8AA +2F8AB 憎 # CJK COMPATIBILITY IDEOGRAPH-2F8AB +2F8AC 憲 # CJK COMPATIBILITY IDEOGRAPH-2F8AC +2F8AD 憤 # CJK COMPATIBILITY IDEOGRAPH-2F8AD +2F8AE 憯 # CJK COMPATIBILITY IDEOGRAPH-2F8AE +2F8AF 懞 # CJK COMPATIBILITY IDEOGRAPH-2F8AF +2F8B0 懲 # CJK COMPATIBILITY IDEOGRAPH-2F8B0 +2F8B1 懶 # CJK COMPATIBILITY IDEOGRAPH-2F8B1 +2F8B2 成 # CJK COMPATIBILITY IDEOGRAPH-2F8B2 +2F8B3 戛 # CJK COMPATIBILITY IDEOGRAPH-2F8B3 +2F8B4 扝 # CJK COMPATIBILITY IDEOGRAPH-2F8B4 +2F8B5 抱 # CJK COMPATIBILITY IDEOGRAPH-2F8B5 +2F8B6 拔 # CJK COMPATIBILITY IDEOGRAPH-2F8B6 +2F8B7 捐 # CJK COMPATIBILITY IDEOGRAPH-2F8B7 +2F8B8 𢬌 # CJK COMPATIBILITY IDEOGRAPH-2F8B8 +2F8B9 挽 # CJK COMPATIBILITY IDEOGRAPH-2F8B9 +2F8BA 拼 # CJK COMPATIBILITY IDEOGRAPH-2F8BA +2F8BB 捨 # CJK COMPATIBILITY IDEOGRAPH-2F8BB +2F8BC 掃 # CJK COMPATIBILITY IDEOGRAPH-2F8BC +2F8BD 揤 # CJK COMPATIBILITY IDEOGRAPH-2F8BD +2F8BE 𢯱 # CJK COMPATIBILITY IDEOGRAPH-2F8BE +2F8BF 搢 # CJK COMPATIBILITY IDEOGRAPH-2F8BF +2F8C0 揅 # CJK COMPATIBILITY IDEOGRAPH-2F8C0 +2F8C1 掩 # CJK COMPATIBILITY IDEOGRAPH-2F8C1 +2F8C2 㨮 # CJK COMPATIBILITY IDEOGRAPH-2F8C2 +2F8C3 摩 # CJK COMPATIBILITY IDEOGRAPH-2F8C3 +2F8C4 摾 # CJK COMPATIBILITY IDEOGRAPH-2F8C4 +2F8C5 撝 # CJK COMPATIBILITY IDEOGRAPH-2F8C5 +2F8C6 摷 # CJK COMPATIBILITY IDEOGRAPH-2F8C6 +2F8C7 㩬 # CJK COMPATIBILITY IDEOGRAPH-2F8C7 +2F8C8 敏 # CJK COMPATIBILITY IDEOGRAPH-2F8C8 +2F8C9 敬 # CJK COMPATIBILITY IDEOGRAPH-2F8C9 +2F8CA 𣀊 # CJK COMPATIBILITY IDEOGRAPH-2F8CA +2F8CB 旣 # CJK COMPATIBILITY IDEOGRAPH-2F8CB +2F8CC 書 # CJK COMPATIBILITY IDEOGRAPH-2F8CC +2F8CD 晉 # CJK COMPATIBILITY IDEOGRAPH-2F8CD +2F8CE 㬙 # CJK COMPATIBILITY IDEOGRAPH-2F8CE +2F8CF 暑 # CJK COMPATIBILITY IDEOGRAPH-2F8CF +2F8D0 㬈 # CJK COMPATIBILITY IDEOGRAPH-2F8D0 +2F8D1 㫤 # CJK COMPATIBILITY IDEOGRAPH-2F8D1 +2F8D2 冒 # CJK COMPATIBILITY IDEOGRAPH-2F8D2 +2F8D3 冕 # CJK COMPATIBILITY IDEOGRAPH-2F8D3 +2F8D4 最 # CJK COMPATIBILITY IDEOGRAPH-2F8D4 +2F8D5 暜 # CJK COMPATIBILITY IDEOGRAPH-2F8D5 +2F8D6 肭 # CJK COMPATIBILITY IDEOGRAPH-2F8D6 +2F8D7 䏙 # CJK COMPATIBILITY IDEOGRAPH-2F8D7 +2F8D8 朗 # CJK COMPATIBILITY IDEOGRAPH-2F8D8 +2F8D9 望 # CJK COMPATIBILITY IDEOGRAPH-2F8D9 +2F8DA 朡 # CJK COMPATIBILITY IDEOGRAPH-2F8DA +2F8DB 杞 # CJK COMPATIBILITY IDEOGRAPH-2F8DB +2F8DC 杓 # CJK COMPATIBILITY IDEOGRAPH-2F8DC +2F8DD 𣏃 # CJK COMPATIBILITY IDEOGRAPH-2F8DD +2F8DE 㭉 # CJK COMPATIBILITY IDEOGRAPH-2F8DE +2F8DF 柺 # CJK COMPATIBILITY IDEOGRAPH-2F8DF +2F8E0 枅 # CJK COMPATIBILITY IDEOGRAPH-2F8E0 +2F8E1 桒 # CJK COMPATIBILITY IDEOGRAPH-2F8E1 +2F8E2 梅 # CJK COMPATIBILITY IDEOGRAPH-2F8E2 +2F8E3 𣑭 # CJK COMPATIBILITY IDEOGRAPH-2F8E3 +2F8E4 梎 # CJK COMPATIBILITY IDEOGRAPH-2F8E4 +2F8E5 栟 # CJK COMPATIBILITY IDEOGRAPH-2F8E5 +2F8E6 椔 # CJK COMPATIBILITY IDEOGRAPH-2F8E6 +2F8E7 㮝 # CJK COMPATIBILITY IDEOGRAPH-2F8E7 +2F8E8 楂 # CJK COMPATIBILITY IDEOGRAPH-2F8E8 +2F8E9 榣 # CJK COMPATIBILITY IDEOGRAPH-2F8E9 +2F8EA 槪 # CJK COMPATIBILITY IDEOGRAPH-2F8EA +2F8EB 檨 # CJK COMPATIBILITY IDEOGRAPH-2F8EB +2F8EC 𣚣 # CJK COMPATIBILITY IDEOGRAPH-2F8EC +2F8ED 櫛 # CJK COMPATIBILITY IDEOGRAPH-2F8ED +2F8EE 㰘 # CJK COMPATIBILITY IDEOGRAPH-2F8EE +2F8EF 次 # CJK COMPATIBILITY IDEOGRAPH-2F8EF +2F8F0 𣢧 # CJK COMPATIBILITY IDEOGRAPH-2F8F0 +2F8F1 歔 # CJK COMPATIBILITY IDEOGRAPH-2F8F1 +2F8F2 㱎 # CJK COMPATIBILITY IDEOGRAPH-2F8F2 +2F8F3 歲 # CJK COMPATIBILITY IDEOGRAPH-2F8F3 +2F8F4 殟 # CJK COMPATIBILITY IDEOGRAPH-2F8F4 +2F8F5 殺 # CJK COMPATIBILITY IDEOGRAPH-2F8F5 +2F8F6 殻 # CJK COMPATIBILITY IDEOGRAPH-2F8F6 +2F8F7 𣪍 # CJK COMPATIBILITY IDEOGRAPH-2F8F7 +2F8F8 𡴋 # CJK COMPATIBILITY IDEOGRAPH-2F8F8 +2F8F9 𣫺 # CJK COMPATIBILITY IDEOGRAPH-2F8F9 +2F8FA 汎 # CJK COMPATIBILITY IDEOGRAPH-2F8FA +2F8FB 𣲼 # CJK COMPATIBILITY IDEOGRAPH-2F8FB +2F8FC 沿 # CJK COMPATIBILITY IDEOGRAPH-2F8FC +2F8FD 泍 # CJK COMPATIBILITY IDEOGRAPH-2F8FD +2F8FE 汧 # CJK COMPATIBILITY IDEOGRAPH-2F8FE +2F8FF 洖 # CJK COMPATIBILITY IDEOGRAPH-2F8FF +2F900 派 # CJK COMPATIBILITY IDEOGRAPH-2F900 +2F901 海 # CJK COMPATIBILITY IDEOGRAPH-2F901 +2F902 流 # CJK COMPATIBILITY IDEOGRAPH-2F902 +2F903 浩 # CJK COMPATIBILITY IDEOGRAPH-2F903 +2F904 浸 # CJK COMPATIBILITY IDEOGRAPH-2F904 +2F905 涅 # CJK COMPATIBILITY IDEOGRAPH-2F905 +2F906 𣴞 # CJK COMPATIBILITY IDEOGRAPH-2F906 +2F907 洴 # CJK COMPATIBILITY IDEOGRAPH-2F907 +2F908 港 # CJK COMPATIBILITY IDEOGRAPH-2F908 +2F909 湮 # CJK COMPATIBILITY IDEOGRAPH-2F909 +2F90A 㴳 # CJK COMPATIBILITY IDEOGRAPH-2F90A +2F90B 滋 # CJK COMPATIBILITY IDEOGRAPH-2F90B +2F90C 滇 # CJK COMPATIBILITY IDEOGRAPH-2F90C +2F90D 𣻑 # CJK COMPATIBILITY IDEOGRAPH-2F90D +2F90E 淹 # CJK COMPATIBILITY IDEOGRAPH-2F90E +2F90F 潮 # CJK COMPATIBILITY IDEOGRAPH-2F90F +2F910 𣽞 # CJK COMPATIBILITY IDEOGRAPH-2F910 +2F911 𣾎 # CJK COMPATIBILITY IDEOGRAPH-2F911 +2F912 濆 # CJK COMPATIBILITY IDEOGRAPH-2F912 +2F913 瀹 # CJK COMPATIBILITY IDEOGRAPH-2F913 +2F914 瀞 # CJK COMPATIBILITY IDEOGRAPH-2F914 +2F915 瀛 # CJK COMPATIBILITY IDEOGRAPH-2F915 +2F916 㶖 # CJK COMPATIBILITY IDEOGRAPH-2F916 +2F917 灊 # CJK COMPATIBILITY IDEOGRAPH-2F917 +2F918 災 # CJK COMPATIBILITY IDEOGRAPH-2F918 +2F919 灷 # CJK COMPATIBILITY IDEOGRAPH-2F919 +2F91A 炭 # CJK COMPATIBILITY IDEOGRAPH-2F91A +2F91B 𠔥 # CJK COMPATIBILITY IDEOGRAPH-2F91B +2F91C 煅 # CJK COMPATIBILITY IDEOGRAPH-2F91C +2F91D 𤉣 # CJK COMPATIBILITY IDEOGRAPH-2F91D +2F91E 熜 # CJK COMPATIBILITY IDEOGRAPH-2F91E +2F91F 𤎫 # CJK COMPATIBILITY IDEOGRAPH-2F91F +2F920 爨 # CJK COMPATIBILITY IDEOGRAPH-2F920 +2F921 爵 # CJK COMPATIBILITY IDEOGRAPH-2F921 +2F922 牐 # CJK COMPATIBILITY IDEOGRAPH-2F922 +2F923 𤘈 # CJK COMPATIBILITY IDEOGRAPH-2F923 +2F924 犀 # CJK COMPATIBILITY IDEOGRAPH-2F924 +2F925 犕 # CJK COMPATIBILITY IDEOGRAPH-2F925 +2F926 𤜵 # CJK COMPATIBILITY IDEOGRAPH-2F926 +2F927 𤠔 # CJK COMPATIBILITY IDEOGRAPH-2F927 +2F928 獺 # CJK COMPATIBILITY IDEOGRAPH-2F928 +2F929 王 # CJK COMPATIBILITY IDEOGRAPH-2F929 +2F92A 㺬 # CJK COMPATIBILITY IDEOGRAPH-2F92A +2F92B 玥 # CJK COMPATIBILITY IDEOGRAPH-2F92B +2F92C 㺸 # CJK COMPATIBILITY IDEOGRAPH-2F92C +2F92D 㺸 # CJK COMPATIBILITY IDEOGRAPH-2F92D +2F92E 瑇 # CJK COMPATIBILITY IDEOGRAPH-2F92E +2F92F 瑜 # CJK COMPATIBILITY IDEOGRAPH-2F92F +2F930 瑱 # CJK COMPATIBILITY IDEOGRAPH-2F930 +2F931 璅 # CJK COMPATIBILITY IDEOGRAPH-2F931 +2F932 瓊 # CJK COMPATIBILITY IDEOGRAPH-2F932 +2F933 㼛 # CJK COMPATIBILITY IDEOGRAPH-2F933 +2F934 甤 # CJK COMPATIBILITY IDEOGRAPH-2F934 +2F935 𤰶 # CJK COMPATIBILITY IDEOGRAPH-2F935 +2F936 甾 # CJK COMPATIBILITY IDEOGRAPH-2F936 +2F937 𤲒 # CJK COMPATIBILITY IDEOGRAPH-2F937 +2F938 異 # CJK COMPATIBILITY IDEOGRAPH-2F938 +2F939 𢆟 # CJK COMPATIBILITY IDEOGRAPH-2F939 +2F93A 瘐 # CJK COMPATIBILITY IDEOGRAPH-2F93A +2F93B 𤾡 # CJK COMPATIBILITY IDEOGRAPH-2F93B +2F93C 𤾸 # CJK COMPATIBILITY IDEOGRAPH-2F93C +2F93D 𥁄 # CJK COMPATIBILITY IDEOGRAPH-2F93D +2F93E 㿼 # CJK COMPATIBILITY IDEOGRAPH-2F93E +2F93F 䀈 # CJK COMPATIBILITY IDEOGRAPH-2F93F +2F940 直 # CJK COMPATIBILITY IDEOGRAPH-2F940 +2F941 𥃳 # CJK COMPATIBILITY IDEOGRAPH-2F941 +2F942 𥃲 # CJK COMPATIBILITY IDEOGRAPH-2F942 +2F943 𥄙 # CJK COMPATIBILITY IDEOGRAPH-2F943 +2F944 𥄳 # CJK COMPATIBILITY IDEOGRAPH-2F944 +2F945 眞 # CJK COMPATIBILITY IDEOGRAPH-2F945 +2F946 真 # CJK COMPATIBILITY IDEOGRAPH-2F946 +2F947 真 # CJK COMPATIBILITY IDEOGRAPH-2F947 +2F948 睊 # CJK COMPATIBILITY IDEOGRAPH-2F948 +2F949 䀹 # CJK COMPATIBILITY IDEOGRAPH-2F949 +2F94A 瞋 # CJK COMPATIBILITY IDEOGRAPH-2F94A +2F94B 䁆 # CJK COMPATIBILITY IDEOGRAPH-2F94B +2F94C 䂖 # CJK COMPATIBILITY IDEOGRAPH-2F94C +2F94D 𥐝 # CJK COMPATIBILITY IDEOGRAPH-2F94D +2F94E 硎 # CJK COMPATIBILITY IDEOGRAPH-2F94E +2F94F 碌 # CJK COMPATIBILITY IDEOGRAPH-2F94F +2F950 磌 # CJK COMPATIBILITY IDEOGRAPH-2F950 +2F951 䃣 # CJK COMPATIBILITY IDEOGRAPH-2F951 +2F952 𥘦 # CJK COMPATIBILITY IDEOGRAPH-2F952 +2F953 祖 # CJK COMPATIBILITY IDEOGRAPH-2F953 +2F954 𥚚 # CJK COMPATIBILITY IDEOGRAPH-2F954 +2F955 𥛅 # CJK COMPATIBILITY IDEOGRAPH-2F955 +2F956 福 # CJK COMPATIBILITY IDEOGRAPH-2F956 +2F957 秫 # CJK COMPATIBILITY IDEOGRAPH-2F957 +2F958 䄯 # CJK COMPATIBILITY IDEOGRAPH-2F958 +2F959 穀 # CJK COMPATIBILITY IDEOGRAPH-2F959 +2F95A 穊 # CJK COMPATIBILITY IDEOGRAPH-2F95A +2F95B 穏 # CJK COMPATIBILITY IDEOGRAPH-2F95B +2F95C 𥥼 # CJK COMPATIBILITY IDEOGRAPH-2F95C +2F95D 𥪧 # CJK COMPATIBILITY IDEOGRAPH-2F95D +2F95E 𥪧 # CJK COMPATIBILITY IDEOGRAPH-2F95E +2F95F 竮 # CJK COMPATIBILITY IDEOGRAPH-2F95F +2F960 䈂 # CJK COMPATIBILITY IDEOGRAPH-2F960 +2F961 𥮫 # CJK COMPATIBILITY IDEOGRAPH-2F961 +2F962 篆 # CJK COMPATIBILITY IDEOGRAPH-2F962 +2F963 築 # CJK COMPATIBILITY IDEOGRAPH-2F963 +2F964 䈧 # CJK COMPATIBILITY IDEOGRAPH-2F964 +2F965 𥲀 # CJK COMPATIBILITY IDEOGRAPH-2F965 +2F966 糒 # CJK COMPATIBILITY IDEOGRAPH-2F966 +2F967 䊠 # CJK COMPATIBILITY IDEOGRAPH-2F967 +2F968 糨 # CJK COMPATIBILITY IDEOGRAPH-2F968 +2F969 糣 # CJK COMPATIBILITY IDEOGRAPH-2F969 +2F96A 紀 # CJK COMPATIBILITY IDEOGRAPH-2F96A +2F96B 𥾆 # CJK COMPATIBILITY IDEOGRAPH-2F96B +2F96C 絣 # CJK COMPATIBILITY IDEOGRAPH-2F96C +2F96D 䌁 # CJK COMPATIBILITY IDEOGRAPH-2F96D +2F96E 緇 # CJK COMPATIBILITY IDEOGRAPH-2F96E +2F96F 縂 # CJK COMPATIBILITY IDEOGRAPH-2F96F +2F970 繅 # CJK COMPATIBILITY IDEOGRAPH-2F970 +2F971 䌴 # CJK COMPATIBILITY IDEOGRAPH-2F971 +2F972 𦈨 # CJK COMPATIBILITY IDEOGRAPH-2F972 +2F973 𦉇 # CJK COMPATIBILITY IDEOGRAPH-2F973 +2F974 䍙 # CJK COMPATIBILITY IDEOGRAPH-2F974 +2F975 𦋙 # CJK COMPATIBILITY IDEOGRAPH-2F975 +2F976 罺 # CJK COMPATIBILITY IDEOGRAPH-2F976 +2F977 𦌾 # CJK COMPATIBILITY IDEOGRAPH-2F977 +2F978 羕 # CJK COMPATIBILITY IDEOGRAPH-2F978 +2F979 翺 # CJK COMPATIBILITY IDEOGRAPH-2F979 +2F97A 者 # CJK COMPATIBILITY IDEOGRAPH-2F97A +2F97B 𦓚 # CJK COMPATIBILITY IDEOGRAPH-2F97B +2F97C 𦔣 # CJK COMPATIBILITY IDEOGRAPH-2F97C +2F97D 聠 # CJK COMPATIBILITY IDEOGRAPH-2F97D +2F97E 𦖨 # CJK COMPATIBILITY IDEOGRAPH-2F97E +2F97F 聰 # CJK COMPATIBILITY IDEOGRAPH-2F97F +2F980 𣍟 # CJK COMPATIBILITY IDEOGRAPH-2F980 +2F981 䏕 # CJK COMPATIBILITY IDEOGRAPH-2F981 +2F982 育 # CJK COMPATIBILITY IDEOGRAPH-2F982 +2F983 脃 # CJK COMPATIBILITY IDEOGRAPH-2F983 +2F984 䐋 # CJK COMPATIBILITY IDEOGRAPH-2F984 +2F985 脾 # CJK COMPATIBILITY IDEOGRAPH-2F985 +2F986 媵 # CJK COMPATIBILITY IDEOGRAPH-2F986 +2F987 𦞧 # CJK COMPATIBILITY IDEOGRAPH-2F987 +2F988 𦞵 # CJK COMPATIBILITY IDEOGRAPH-2F988 +2F989 𣎓 # CJK COMPATIBILITY IDEOGRAPH-2F989 +2F98A 𣎜 # CJK COMPATIBILITY IDEOGRAPH-2F98A +2F98B 舁 # CJK COMPATIBILITY IDEOGRAPH-2F98B +2F98C 舄 # CJK COMPATIBILITY IDEOGRAPH-2F98C +2F98D 辞 # CJK COMPATIBILITY IDEOGRAPH-2F98D +2F98E 䑫 # CJK COMPATIBILITY IDEOGRAPH-2F98E +2F98F 芑 # CJK COMPATIBILITY IDEOGRAPH-2F98F +2F990 芋 # CJK COMPATIBILITY IDEOGRAPH-2F990 +2F991 芝 # CJK COMPATIBILITY IDEOGRAPH-2F991 +2F992 劳 # CJK COMPATIBILITY IDEOGRAPH-2F992 +2F993 花 # CJK COMPATIBILITY IDEOGRAPH-2F993 +2F994 芳 # CJK COMPATIBILITY IDEOGRAPH-2F994 +2F995 芽 # CJK COMPATIBILITY IDEOGRAPH-2F995 +2F996 苦 # CJK COMPATIBILITY IDEOGRAPH-2F996 +2F997 𦬼 # CJK COMPATIBILITY IDEOGRAPH-2F997 +2F998 若 # CJK COMPATIBILITY IDEOGRAPH-2F998 +2F999 茝 # CJK COMPATIBILITY IDEOGRAPH-2F999 +2F99A 荣 # CJK COMPATIBILITY IDEOGRAPH-2F99A +2F99B 莭 # CJK COMPATIBILITY IDEOGRAPH-2F99B +2F99C 茣 # CJK COMPATIBILITY IDEOGRAPH-2F99C +2F99D 莽 # CJK COMPATIBILITY IDEOGRAPH-2F99D +2F99E 菧 # CJK COMPATIBILITY IDEOGRAPH-2F99E +2F99F 著 # CJK COMPATIBILITY IDEOGRAPH-2F99F +2F9A0 荓 # CJK COMPATIBILITY IDEOGRAPH-2F9A0 +2F9A1 菊 # CJK COMPATIBILITY IDEOGRAPH-2F9A1 +2F9A2 菌 # CJK COMPATIBILITY IDEOGRAPH-2F9A2 +2F9A3 菜 # CJK COMPATIBILITY IDEOGRAPH-2F9A3 +2F9A4 𦰶 # CJK COMPATIBILITY IDEOGRAPH-2F9A4 +2F9A5 𦵫 # CJK COMPATIBILITY IDEOGRAPH-2F9A5 +2F9A6 𦳕 # CJK COMPATIBILITY IDEOGRAPH-2F9A6 +2F9A7 䔫 # CJK COMPATIBILITY IDEOGRAPH-2F9A7 +2F9A8 蓱 # CJK COMPATIBILITY IDEOGRAPH-2F9A8 +2F9A9 蓳 # CJK COMPATIBILITY IDEOGRAPH-2F9A9 +2F9AA 蔖 # CJK COMPATIBILITY IDEOGRAPH-2F9AA +2F9AB 𧏊 # CJK COMPATIBILITY IDEOGRAPH-2F9AB +2F9AC 蕤 # CJK COMPATIBILITY IDEOGRAPH-2F9AC +2F9AD 𦼬 # CJK COMPATIBILITY IDEOGRAPH-2F9AD +2F9AE 䕝 # CJK COMPATIBILITY IDEOGRAPH-2F9AE +2F9AF 䕡 # CJK COMPATIBILITY IDEOGRAPH-2F9AF +2F9B0 𦾱 # CJK COMPATIBILITY IDEOGRAPH-2F9B0 +2F9B1 𧃒 # CJK COMPATIBILITY IDEOGRAPH-2F9B1 +2F9B2 䕫 # CJK COMPATIBILITY IDEOGRAPH-2F9B2 +2F9B3 虐 # CJK COMPATIBILITY IDEOGRAPH-2F9B3 +2F9B4 虜 # CJK COMPATIBILITY IDEOGRAPH-2F9B4 +2F9B5 虧 # CJK COMPATIBILITY IDEOGRAPH-2F9B5 +2F9B6 虩 # CJK COMPATIBILITY IDEOGRAPH-2F9B6 +2F9B7 蚩 # CJK COMPATIBILITY IDEOGRAPH-2F9B7 +2F9B8 蚈 # CJK COMPATIBILITY IDEOGRAPH-2F9B8 +2F9B9 蜎 # CJK COMPATIBILITY IDEOGRAPH-2F9B9 +2F9BA 蛢 # CJK COMPATIBILITY IDEOGRAPH-2F9BA +2F9BB 蝹 # CJK COMPATIBILITY IDEOGRAPH-2F9BB +2F9BC 蜨 # CJK COMPATIBILITY IDEOGRAPH-2F9BC +2F9BD 蝫 # CJK COMPATIBILITY IDEOGRAPH-2F9BD +2F9BE 螆 # CJK COMPATIBILITY IDEOGRAPH-2F9BE +2F9BF 䗗 # CJK COMPATIBILITY IDEOGRAPH-2F9BF +2F9C0 蟡 # CJK COMPATIBILITY IDEOGRAPH-2F9C0 +2F9C1 蠁 # CJK COMPATIBILITY IDEOGRAPH-2F9C1 +2F9C2 䗹 # CJK COMPATIBILITY IDEOGRAPH-2F9C2 +2F9C3 衠 # CJK COMPATIBILITY IDEOGRAPH-2F9C3 +2F9C4 衣 # CJK COMPATIBILITY IDEOGRAPH-2F9C4 +2F9C5 𧙧 # CJK COMPATIBILITY IDEOGRAPH-2F9C5 +2F9C6 裗 # CJK COMPATIBILITY IDEOGRAPH-2F9C6 +2F9C7 裞 # CJK COMPATIBILITY IDEOGRAPH-2F9C7 +2F9C8 䘵 # CJK COMPATIBILITY IDEOGRAPH-2F9C8 +2F9C9 裺 # CJK COMPATIBILITY IDEOGRAPH-2F9C9 +2F9CA 㒻 # CJK COMPATIBILITY IDEOGRAPH-2F9CA +2F9CB 𧢮 # CJK COMPATIBILITY IDEOGRAPH-2F9CB +2F9CC 𧥦 # CJK COMPATIBILITY IDEOGRAPH-2F9CC +2F9CD 䚾 # CJK COMPATIBILITY IDEOGRAPH-2F9CD +2F9CE 䛇 # CJK COMPATIBILITY IDEOGRAPH-2F9CE +2F9CF 誠 # CJK COMPATIBILITY IDEOGRAPH-2F9CF +2F9D0 諭 # CJK COMPATIBILITY IDEOGRAPH-2F9D0 +2F9D1 變 # CJK COMPATIBILITY IDEOGRAPH-2F9D1 +2F9D2 豕 # CJK COMPATIBILITY IDEOGRAPH-2F9D2 +2F9D3 𧲨 # CJK COMPATIBILITY IDEOGRAPH-2F9D3 +2F9D4 貫 # CJK COMPATIBILITY IDEOGRAPH-2F9D4 +2F9D5 賁 # CJK COMPATIBILITY IDEOGRAPH-2F9D5 +2F9D6 贛 # CJK COMPATIBILITY IDEOGRAPH-2F9D6 +2F9D7 起 # CJK COMPATIBILITY IDEOGRAPH-2F9D7 +2F9D8 𧼯 # CJK COMPATIBILITY IDEOGRAPH-2F9D8 +2F9D9 𠠄 # CJK COMPATIBILITY IDEOGRAPH-2F9D9 +2F9DA 跋 # CJK COMPATIBILITY IDEOGRAPH-2F9DA +2F9DB 趼 # CJK COMPATIBILITY IDEOGRAPH-2F9DB +2F9DC 跰 # CJK COMPATIBILITY IDEOGRAPH-2F9DC +2F9DD 𠣞 # CJK COMPATIBILITY IDEOGRAPH-2F9DD +2F9DE 軔 # CJK COMPATIBILITY IDEOGRAPH-2F9DE +2F9DF 輸 # CJK COMPATIBILITY IDEOGRAPH-2F9DF +2F9E0 𨗒 # CJK COMPATIBILITY IDEOGRAPH-2F9E0 +2F9E1 𨗭 # CJK COMPATIBILITY IDEOGRAPH-2F9E1 +2F9E2 邔 # CJK COMPATIBILITY IDEOGRAPH-2F9E2 +2F9E3 郱 # CJK COMPATIBILITY IDEOGRAPH-2F9E3 +2F9E4 鄑 # CJK COMPATIBILITY IDEOGRAPH-2F9E4 +2F9E5 𨜮 # CJK COMPATIBILITY IDEOGRAPH-2F9E5 +2F9E6 鄛 # CJK COMPATIBILITY IDEOGRAPH-2F9E6 +2F9E7 鈸 # CJK COMPATIBILITY IDEOGRAPH-2F9E7 +2F9E8 鋗 # CJK COMPATIBILITY IDEOGRAPH-2F9E8 +2F9E9 鋘 # CJK COMPATIBILITY IDEOGRAPH-2F9E9 +2F9EA 鉼 # CJK COMPATIBILITY IDEOGRAPH-2F9EA +2F9EB 鏹 # CJK COMPATIBILITY IDEOGRAPH-2F9EB +2F9EC 鐕 # CJK COMPATIBILITY IDEOGRAPH-2F9EC +2F9ED 𨯺 # CJK COMPATIBILITY IDEOGRAPH-2F9ED +2F9EE 開 # CJK COMPATIBILITY IDEOGRAPH-2F9EE +2F9EF 䦕 # CJK COMPATIBILITY IDEOGRAPH-2F9EF +2F9F0 閷 # CJK COMPATIBILITY IDEOGRAPH-2F9F0 +2F9F1 𨵷 # CJK COMPATIBILITY IDEOGRAPH-2F9F1 +2F9F2 䧦 # CJK COMPATIBILITY IDEOGRAPH-2F9F2 +2F9F3 雃 # CJK COMPATIBILITY IDEOGRAPH-2F9F3 +2F9F4 嶲 # CJK COMPATIBILITY IDEOGRAPH-2F9F4 +2F9F5 霣 # CJK COMPATIBILITY IDEOGRAPH-2F9F5 +2F9F6 𩅅 # CJK COMPATIBILITY IDEOGRAPH-2F9F6 +2F9F7 𩈚 # CJK COMPATIBILITY IDEOGRAPH-2F9F7 +2F9F8 䩮 # CJK COMPATIBILITY IDEOGRAPH-2F9F8 +2F9F9 䩶 # CJK COMPATIBILITY IDEOGRAPH-2F9F9 +2F9FA 韠 # CJK COMPATIBILITY IDEOGRAPH-2F9FA +2F9FB 𩐊 # CJK COMPATIBILITY IDEOGRAPH-2F9FB +2F9FC 䪲 # CJK COMPATIBILITY IDEOGRAPH-2F9FC +2F9FD 𩒖 # CJK COMPATIBILITY IDEOGRAPH-2F9FD +2F9FE 頋 # CJK COMPATIBILITY IDEOGRAPH-2F9FE +2F9FF 頋 # CJK COMPATIBILITY IDEOGRAPH-2F9FF +2FA00 頩 # CJK COMPATIBILITY IDEOGRAPH-2FA00 +2FA01 𩖶 # CJK COMPATIBILITY IDEOGRAPH-2FA01 +2FA02 飢 # CJK COMPATIBILITY IDEOGRAPH-2FA02 +2FA03 䬳 # CJK COMPATIBILITY IDEOGRAPH-2FA03 +2FA04 餩 # CJK COMPATIBILITY IDEOGRAPH-2FA04 +2FA05 馧 # CJK COMPATIBILITY IDEOGRAPH-2FA05 +2FA06 駂 # CJK COMPATIBILITY IDEOGRAPH-2FA06 +2FA07 駾 # CJK COMPATIBILITY IDEOGRAPH-2FA07 +2FA08 䯎 # CJK COMPATIBILITY IDEOGRAPH-2FA08 +2FA09 𩬰 # CJK COMPATIBILITY IDEOGRAPH-2FA09 +2FA0A 鬒 # CJK COMPATIBILITY IDEOGRAPH-2FA0A +2FA0B 鱀 # CJK COMPATIBILITY IDEOGRAPH-2FA0B +2FA0C 鳽 # CJK COMPATIBILITY IDEOGRAPH-2FA0C +2FA0D 䳎 # CJK COMPATIBILITY IDEOGRAPH-2FA0D +2FA0E 䳭 # CJK COMPATIBILITY IDEOGRAPH-2FA0E +2FA0F 鵧 # CJK COMPATIBILITY IDEOGRAPH-2FA0F +2FA10 𪃎 # CJK COMPATIBILITY IDEOGRAPH-2FA10 +2FA11 䳸 # CJK COMPATIBILITY IDEOGRAPH-2FA11 +2FA12 𪄅 # CJK COMPATIBILITY IDEOGRAPH-2FA12 +2FA13 𪈎 # CJK COMPATIBILITY IDEOGRAPH-2FA13 +2FA14 𪊑 # CJK COMPATIBILITY IDEOGRAPH-2FA14 +2FA15 麻 # CJK COMPATIBILITY IDEOGRAPH-2FA15 +2FA16 䵖 # CJK COMPATIBILITY IDEOGRAPH-2FA16 +2FA17 黹 # CJK COMPATIBILITY IDEOGRAPH-2FA17 +2FA18 黾 # CJK COMPATIBILITY IDEOGRAPH-2FA18 +2FA19 鼅 # CJK COMPATIBILITY IDEOGRAPH-2FA19 +2FA1A 鼏 # CJK COMPATIBILITY IDEOGRAPH-2FA1A +2FA1B 鼖 # CJK COMPATIBILITY IDEOGRAPH-2FA1B +2FA1C 鼻 # CJK COMPATIBILITY IDEOGRAPH-2FA1C +2FA1D 𪘀 # CJK COMPATIBILITY IDEOGRAPH-2FA1D diff --git a/graf2d/win32gdk/gdk/src/iconv/translit.h b/graf2d/win32gdk/gdk/src/iconv/translit.h new file mode 100644 index 0000000000000..15aa447264198 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/translit.h @@ -0,0 +1,4411 @@ +/* + * Copyright (C) 1999-2003 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * Transliteration table + */ + +static const unsigned int translit_data[9116] = { + 1, ' ', + 1, '!', + 1, 'c', + 2, 'l', 'b', + 3, 'y', 'e', 'n', + 1, '|', + 2, 'S', 'S', + 1, '"', + 3, '(', 'c', ')', + 1, 'a', + 2, '<', '<', + 3, 'n', 'o', 't', + 1, '-', + 3, '(', 'R', ')', + 2, '^', '0', + 3, '+', '/', '-', + 2, '^', '2', + 2, '^', '3', + 1,'\'', + 1, 'u', + 1, 'P', + 1, '.', + 1, ',', + 2, '^', '1', + 1, 'o', + 2, '>', '>', + 5, ' ', '1',0x2044, '4', ' ', + 5, ' ', '1',0x2044, '2', ' ', + 5, ' ', '3',0x2044, '4', ' ', + 1, '?', + 2, '`', 'A', + 2,0xB4, 'A', + 2, '^', 'A', + 2, '~', 'A', + 2, '"', 'A', + 1, 'A', + 2, 'A', 'E', + 1, 'C', + 2, '`', 'E', + 2,0xB4, 'E', + 2, '^', 'E', + 2, '"', 'E', + 2, '`', 'I', + 2,0xB4, 'I', + 2, '^', 'I', + 2, '"', 'I', + 1, 'D', + 2, '~', 'N', + 2, '`', 'O', + 2,0xB4, 'O', + 2, '^', 'O', + 2, '~', 'O', + 2, '"', 'O', + 1, 'x', + 1, 'O', + 2, '`', 'U', + 2,0xB4, 'U', + 2, '^', 'U', + 2, '"', 'U', + 2,0xB4, 'Y', + 2, 'T', 'h', + 2, 's', 's', + 2, '`', 'a', + 2,0xB4, 'a', + 2, '^', 'a', + 2, '~', 'a', + 2, '"', 'a', + 1, 'a', + 2, 'a', 'e', + 1, 'c', + 2, '`', 'e', + 2,0xB4, 'e', + 2, '^', 'e', + 2, '"', 'e', + 2, '`', 'i', + 2,0xB4, 'i', + 2, '^', 'i', + 2, '"', 'i', + 1, 'd', + 2, '~', 'n', + 2, '`', 'o', + 2,0xB4, 'o', + 2, '^', 'o', + 2, '~', 'o', + 2, '"', 'o', + 1, ':', + 1, 'o', + 2, '`', 'u', + 2,0xB4, 'u', + 2, '^', 'u', + 2, '"', 'u', + 2,0xB4, 'y', + 2, 't', 'h', + 2, '"', 'y', + 1, 'A', + 1, 'a', + 1, 'A', + 1, 'a', + 1, 'A', + 1, 'a', + 2,0xB4, 'C', + 2,0xB4, 'c', + 2, '^', 'C', + 2, '^', 'c', + 1, 'C', + 1, 'c', + 1, 'C', + 1, 'c', + 1, 'D', + 1, 'd', + 1, 'D', + 1, 'd', + 1, 'E', + 1, 'e', + 1, 'E', + 1, 'e', + 1, 'E', + 1, 'e', + 1, 'E', + 1, 'e', + 1, 'E', + 1, 'e', + 2, '^', 'G', + 2, '^', 'g', + 1, 'G', + 1, 'g', + 1, 'G', + 1, 'g', + 1, 'G', + 1, 'g', + 2, '^', 'H', + 2, '^', 'h', + 1, 'H', + 1, 'h', + 2, '~', 'I', + 2, '~', 'i', + 1, 'I', + 1, 'i', + 1, 'I', + 1, 'i', + 1, 'I', + 1, 'i', + 1, 'I', + 1, 'i', + 2, 'I', 'J', + 2, 'i', 'j', + 2, '^', 'J', + 2, '^', 'j', + 1, 'K', + 1, 'k', + 1, 'L', + 1, 'l', + 1, 'L', + 1, 'l', + 1, 'L', + 1, 'l', + 1, 'L', + 1, 'l', + 1, 'L', + 1, 'l', + 2,0xB4, 'N', + 2,0xB4, 'n', + 1, 'N', + 1, 'n', + 1, 'N', + 1, 'n', + 2,'\'', 'n', + 1, 'O', + 1, 'o', + 1, 'O', + 1, 'o', + 2, '"', 'O', + 2, '"', 'o', + 2, 'O', 'E', + 2, 'o', 'e', + 2,0xB4, 'R', + 2,0xB4, 'r', + 1, 'R', + 1, 'r', + 1, 'R', + 1, 'r', + 2,0xB4, 'S', + 2,0xB4, 's', + 2, '^', 'S', + 2, '^', 's', + 1, 'S', + 1, 's', + 1, 'S', + 1, 's', + 1, 'T', + 1, 't', + 1, 'T', + 1, 't', + 1, 'T', + 1, 't', + 2, '~', 'U', + 2, '~', 'u', + 1, 'U', + 1, 'u', + 1, 'U', + 1, 'u', + 1, 'U', + 1, 'u', + 2, '"', 'U', + 2, '"', 'u', + 1, 'U', + 1, 'u', + 2, '^', 'W', + 2, '^', 'w', + 2, '^', 'Y', + 2, '^', 'y', + 2, '"', 'Y', + 2,0xB4, 'Z', + 2,0xB4, 'z', + 1, 'Z', + 1, 'z', + 1, 'Z', + 1, 'z', + 1, 's', + 1, 'f', + 2, 'D',0x017D, + 2, 'D',0x017E, + 2, 'd',0x017E, + 2, 'L', 'J', + 2, 'L', 'j', + 2, 'l', 'j', + 2, 'N', 'J', + 2, 'N', 'j', + 2, 'n', 'j', + 2, 'D', 'Z', + 2, 'D', 'z', + 2, 'd', 'z', + 1, 'S', + 1, 's', + 1, 'T', + 1, 't', + 1,0x2032, + 1,0x2033, + 1,0x2018, + 1,0x2019, + 1,0x201B, + 1, '^', + 1,'\'', + 1,0xAF, + 1,0xB4, + 1, '`', + 1, '_', + 1, '~', + 1, '"', + 1,0x03B2, + 1,0x03B8, + 1,0x03A5, + 1,0x03C6, + 1,0x03C0, + 1,0x03BA, + 1,0x03C1, + 1,0x03C2, + 1,0x0398, + 1,0x03B5, + 1,0x03A3, + 2,0x0565,0x0582, + 2,0x05D5,0x05D5, + 2,0x05D5,0x05D9, + 2,0x05D9,0x05D9, + 2,0x0627,0x0674, + 2,0x0648,0x0674, + 2,0x06C7,0x0674, + 2,0x064A,0x0674, + 2,0x0E4D,0x0E32, + 2,0x0ECD,0x0EB2, + 2,0x0EAB,0x0E99, + 2,0x0EAB,0x0EA1, + 2,0x0FB2,0x0F81, + 2,0x0FB3,0x0F81, + 1, 'B', + 1, 'b', + 1, 'D', + 1, 'd', + 1, 'F', + 1, 'f', + 1, 'M', + 1, 'm', + 1, 'P', + 1, 'p', + 1, 'S', + 1, 's', + 1, 'T', + 1, 't', + 2, '`', 'W', + 2, '`', 'w', + 2,0xB4, 'W', + 2,0xB4, 'w', + 2, '"', 'W', + 2, '"', 'w', + 2, 'a',0x02BE, + 2, '`', 'Y', + 2, '`', 'y', + 1, ' ', + 1, ' ', + 1, ' ', + 1, ' ', + 1, ' ', + 1, ' ', + 1, ' ', + 1, ' ', + 1, '-', + 1, '-', + 1, '-', + 1, '-', + 1, '-', + 1, '-', + 1,'\'', + 1,'\'', + 1, ',', + 1,'\'', + 1, '"', + 1, '"', + 1, '"', + 1, '"', + 1, '+', + 1, 'o', + 1, '.', + 2, '.', '.', + 3, '.', '.', '.', + 4, 'o', '/', 'o', 'o', + 1,0xB4, + 2,0xB4,0xB4, + 3,0xB4,0xB4,0xB4, + 2,0x2035,0x2035, + 3,0x2035,0x2035,0x2035, + 1, '<', + 1, '>', + 2, '!', '!', + 1, '/', + 2, '?', '?', + 2, '?', '!', + 2, '!', '?', + 4,0xB4,0xB4,0xB4,0xB4, + 2, 'R', 's', + 4,0x0110,0x1ED3, 'n', 'g', + 3, 'E', 'U', 'R', + 3, 'a', '/', 'c', + 3, 'a', '/', 's', + 1, 'C', + 2,0xB0, 'C', + 3, 'c', '/', 'o', + 3, 'c', '/', 'u', + 1,0x0190, + 2,0xB0, 'F', + 1, 'g', + 1, 'H', + 1, 'H', + 1, 'H', + 1, 'h', + 1,0x0127, + 1, 'I', + 1, 'I', + 1, 'L', + 1, 'l', + 1, 'N', + 2, 'N', 'o', + 1, 'P', + 1, 'Q', + 1, 'R', + 1, 'R', + 1, 'R', + 3, 'T', 'E', 'L', + 2, 'T', 'M', + 1, 'Z', + 3, 'O', 'h', 'm', + 1, 'Z', + 1, 'B', + 1, 'C', + 1, 'e', + 1, 'e', + 1, 'E', + 1, 'F', + 1, 'M', + 1, 'o', + 1,0x05D0, + 1,0x05D1, + 1,0x05D2, + 1,0x05D3, + 1, 'i', + 3, 'F', 'A', 'X', + 1,0x03B3, + 1,0x0393, + 1,0x03A0, + 1,0x2211, + 1, 'D', + 1, 'd', + 1, 'e', + 1, 'i', + 1, 'j', + 5, ' ', '1',0x2044, '3', ' ', + 5, ' ', '2',0x2044, '3', ' ', + 5, ' ', '1',0x2044, '5', ' ', + 5, ' ', '2',0x2044, '5', ' ', + 5, ' ', '3',0x2044, '5', ' ', + 5, ' ', '4',0x2044, '5', ' ', + 5, ' ', '1',0x2044, '6', ' ', + 5, ' ', '5',0x2044, '6', ' ', + 5, ' ', '1',0x2044, '8', ' ', + 5, ' ', '3',0x2044, '8', ' ', + 5, ' ', '5',0x2044, '8', ' ', + 5, ' ', '7',0x2044, '8', ' ', + 3, ' ', '1',0x2044, + 1, 'I', + 2, 'I', 'I', + 3, 'I', 'I', 'I', + 2, 'I', 'V', + 1, 'V', + 2, 'V', 'I', + 3, 'V', 'I', 'I', + 4, 'V', 'I', 'I', 'I', + 2, 'I', 'X', + 1, 'X', + 2, 'X', 'I', + 3, 'X', 'I', 'I', + 1, 'L', + 1, 'C', + 1, 'D', + 1, 'M', + 1, 'i', + 2, 'i', 'i', + 3, 'i', 'i', 'i', + 2, 'i', 'v', + 1, 'v', + 2, 'v', 'i', + 3, 'v', 'i', 'i', + 4, 'v', 'i', 'i', 'i', + 2, 'i', 'x', + 1, 'x', + 2, 'x', 'i', + 3, 'x', 'i', 'i', + 1, 'l', + 1, 'c', + 1, 'd', + 1, 'm', + 2, '<', '-', + 1, '^', + 2, '-', '>', + 1, 'V', + 3, '<', '-', '>', + 2, '<', '=', + 2, '=', '>', + 3, '<', '=', '>', + 1, '-', + 1, '/', + 1,'\\', + 1, '*', + 1,0x2022, + 1, '|', + 2,0x222B,0x222B, + 3,0x222B,0x222B,0x222B, + 2,0x222E,0x222E, + 3,0x222E,0x222E,0x222E, + 1, ':', + 1, '~', + 2, '/', '=', + 2, '<', '=', + 2, '>', '=', + 2, '<', '<', + 2, '>', '>', + 1,0xB7, + 3, '<', '<', '<', + 3, '>', '>', '>', + 3,0xB7,0xB7,0xB7, + 5, '[', 'N', 'U', 'L', ']', + 5, '[', 'S', 'O', 'H', ']', + 5, '[', 'S', 'T', 'X', ']', + 5, '[', 'E', 'T', 'X', ']', + 5, '[', 'E', 'O', 'T', ']', + 5, '[', 'E', 'N', 'Q', ']', + 5, '[', 'A', 'C', 'K', ']', + 5, '[', 'B', 'E', 'L', ']', + 4, '[', 'B', 'S', ']', + 4, '[', 'H', 'T', ']', + 4, '[', 'L', 'F', ']', + 4, '[', 'V', 'T', ']', + 4, '[', 'F', 'F', ']', + 4, '[', 'C', 'R', ']', + 4, '[', 'S', 'O', ']', + 4, '[', 'S', 'I', ']', + 5, '[', 'D', 'L', 'E', ']', + 5, '[', 'D', 'C', '1', ']', + 5, '[', 'D', 'C', '2', ']', + 5, '[', 'D', 'C', '3', ']', + 5, '[', 'D', 'C', '4', ']', + 5, '[', 'N', 'A', 'K', ']', + 5, '[', 'S', 'Y', 'N', ']', + 5, '[', 'E', 'T', 'B', ']', + 5, '[', 'C', 'A', 'N', ']', + 4, '[', 'E', 'M', ']', + 5, '[', 'S', 'U', 'B', ']', + 5, '[', 'E', 'S', 'C', ']', + 4, '[', 'F', 'S', ']', + 4, '[', 'G', 'S', ']', + 4, '[', 'R', 'S', ']', + 4, '[', 'U', 'S', ']', + 4, '[', 'S', 'P', ']', + 5, '[', 'D', 'E', 'L', ']', + 4, '[', 'N', 'L', ']', + 3, '(', '1', ')', + 3, '(', '2', ')', + 3, '(', '3', ')', + 3, '(', '4', ')', + 3, '(', '5', ')', + 3, '(', '6', ')', + 3, '(', '7', ')', + 3, '(', '8', ')', + 3, '(', '9', ')', + 4, '(', '1', '0', ')', + 4, '(', '1', '1', ')', + 4, '(', '1', '2', ')', + 4, '(', '1', '3', ')', + 4, '(', '1', '4', ')', + 4, '(', '1', '5', ')', + 4, '(', '1', '6', ')', + 4, '(', '1', '7', ')', + 4, '(', '1', '8', ')', + 4, '(', '1', '9', ')', + 4, '(', '2', '0', ')', + 3, '(', '1', ')', + 3, '(', '2', ')', + 3, '(', '3', ')', + 3, '(', '4', ')', + 3, '(', '5', ')', + 3, '(', '6', ')', + 3, '(', '7', ')', + 3, '(', '8', ')', + 3, '(', '9', ')', + 4, '(', '1', '0', ')', + 4, '(', '1', '1', ')', + 4, '(', '1', '2', ')', + 4, '(', '1', '3', ')', + 4, '(', '1', '4', ')', + 4, '(', '1', '5', ')', + 4, '(', '1', '6', ')', + 4, '(', '1', '7', ')', + 4, '(', '1', '8', ')', + 4, '(', '1', '9', ')', + 4, '(', '2', '0', ')', + 2, '1', '.', + 2, '2', '.', + 2, '3', '.', + 2, '4', '.', + 2, '5', '.', + 2, '6', '.', + 2, '7', '.', + 2, '8', '.', + 2, '9', '.', + 3, '1', '0', '.', + 3, '1', '1', '.', + 3, '1', '2', '.', + 3, '1', '3', '.', + 3, '1', '4', '.', + 3, '1', '5', '.', + 3, '1', '6', '.', + 3, '1', '7', '.', + 3, '1', '8', '.', + 3, '1', '9', '.', + 3, '2', '0', '.', + 3, '(', 'a', ')', + 3, '(', 'b', ')', + 3, '(', 'c', ')', + 3, '(', 'd', ')', + 3, '(', 'e', ')', + 3, '(', 'f', ')', + 3, '(', 'g', ')', + 3, '(', 'h', ')', + 3, '(', 'i', ')', + 3, '(', 'j', ')', + 3, '(', 'k', ')', + 3, '(', 'l', ')', + 3, '(', 'm', ')', + 3, '(', 'n', ')', + 3, '(', 'o', ')', + 3, '(', 'p', ')', + 3, '(', 'q', ')', + 3, '(', 'r', ')', + 3, '(', 's', ')', + 3, '(', 't', ')', + 3, '(', 'u', ')', + 3, '(', 'v', ')', + 3, '(', 'w', ')', + 3, '(', 'x', ')', + 3, '(', 'y', ')', + 3, '(', 'z', ')', + 3, '(', 'A', ')', + 3, '(', 'B', ')', + 3, '(', 'C', ')', + 3, '(', 'D', ')', + 3, '(', 'E', ')', + 3, '(', 'F', ')', + 3, '(', 'G', ')', + 3, '(', 'H', ')', + 3, '(', 'I', ')', + 3, '(', 'J', ')', + 3, '(', 'K', ')', + 3, '(', 'L', ')', + 3, '(', 'M', ')', + 3, '(', 'N', ')', + 3, '(', 'O', ')', + 3, '(', 'P', ')', + 3, '(', 'Q', ')', + 3, '(', 'R', ')', + 3, '(', 'S', ')', + 3, '(', 'T', ')', + 3, '(', 'U', ')', + 3, '(', 'V', ')', + 3, '(', 'W', ')', + 3, '(', 'X', ')', + 3, '(', 'Y', ')', + 3, '(', 'Z', ')', + 3, '(', 'a', ')', + 3, '(', 'b', ')', + 3, '(', 'c', ')', + 3, '(', 'd', ')', + 3, '(', 'e', ')', + 3, '(', 'f', ')', + 3, '(', 'g', ')', + 3, '(', 'h', ')', + 3, '(', 'i', ')', + 3, '(', 'j', ')', + 3, '(', 'k', ')', + 3, '(', 'l', ')', + 3, '(', 'm', ')', + 3, '(', 'n', ')', + 3, '(', 'o', ')', + 3, '(', 'p', ')', + 3, '(', 'q', ')', + 3, '(', 'r', ')', + 3, '(', 's', ')', + 3, '(', 't', ')', + 3, '(', 'u', ')', + 3, '(', 'v', ')', + 3, '(', 'w', ')', + 3, '(', 'x', ')', + 3, '(', 'y', ')', + 3, '(', 'z', ')', + 3, '(', '0', ')', + 1, '-', + 1, '|', + 1, '+', + 1, '+', + 1, '+', + 1, '+', + 1, '+', + 1, '+', + 1, '+', + 1, '+', + 1, '+', + 1, 'o', + 4,0x222B,0x222B,0x222B,0x222B, + 3, ':', ':', '=', + 2, '=', '=', + 3, '=', '=', '=', + 1,0x6BCD, + 1,0x9F9F, + 1,0x4E00, + 1,0x4E28, + 1,0x4E36, + 1,0x4E3F, + 1,0x4E59, + 1,0x4E85, + 1,0x4E8C, + 1,0x4EA0, + 1,0x4EBA, + 1,0x513F, + 1,0x5165, + 1,0x516B, + 1,0x5182, + 1,0x5196, + 1,0x51AB, + 1,0x51E0, + 1,0x51F5, + 1,0x5200, + 1,0x529B, + 1,0x52F9, + 1,0x5315, + 1,0x531A, + 1,0x5338, + 1,0x5341, + 1,0x535C, + 1,0x5369, + 1,0x5382, + 1,0x53B6, + 1,0x53C8, + 1,0x53E3, + 1,0x56D7, + 1,0x571F, + 1,0x58EB, + 1,0x5902, + 1,0x590A, + 1,0x5915, + 1,0x5927, + 1,0x5973, + 1,0x5B50, + 1,0x5B80, + 1,0x5BF8, + 1,0x5C0F, + 1,0x5C22, + 1,0x5C38, + 1,0x5C6E, + 1,0x5C71, + 1,0x5DDB, + 1,0x5DE5, + 1,0x5DF1, + 1,0x5DFE, + 1,0x5E72, + 1,0x5E7A, + 1,0x5E7F, + 1,0x5EF4, + 1,0x5EFE, + 1,0x5F0B, + 1,0x5F13, + 1,0x5F50, + 1,0x5F61, + 1,0x5F73, + 1,0x5FC3, + 1,0x6208, + 1,0x6236, + 1,0x624B, + 1,0x652F, + 1,0x6534, + 1,0x6587, + 1,0x6597, + 1,0x65A4, + 1,0x65B9, + 1,0x65E0, + 1,0x65E5, + 1,0x66F0, + 1,0x6708, + 1,0x6728, + 1,0x6B20, + 1,0x6B62, + 1,0x6B79, + 1,0x6BB3, + 1,0x6BCB, + 1,0x6BD4, + 1,0x6BDB, + 1,0x6C0F, + 1,0x6C14, + 1,0x6C34, + 1,0x706B, + 1,0x722A, + 1,0x7236, + 1,0x723B, + 1,0x723F, + 1,0x7247, + 1,0x7259, + 1,0x725B, + 1,0x72AC, + 1,0x7384, + 1,0x7389, + 1,0x74DC, + 1,0x74E6, + 1,0x7518, + 1,0x751F, + 1,0x7528, + 1,0x7530, + 1,0x758B, + 1,0x7592, + 1,0x7676, + 1,0x767D, + 1,0x76AE, + 1,0x76BF, + 1,0x76EE, + 1,0x77DB, + 1,0x77E2, + 1,0x77F3, + 1,0x793A, + 1,0x79B8, + 1,0x79BE, + 1,0x7A74, + 1,0x7ACB, + 1,0x7AF9, + 1,0x7C73, + 1,0x7CF8, + 1,0x7F36, + 1,0x7F51, + 1,0x7F8A, + 1,0x7FBD, + 1,0x8001, + 1,0x800C, + 1,0x8012, + 1,0x8033, + 1,0x807F, + 1,0x8089, + 1,0x81E3, + 1,0x81EA, + 1,0x81F3, + 1,0x81FC, + 1,0x820C, + 1,0x821B, + 1,0x821F, + 1,0x826E, + 1,0x8272, + 1,0x8278, + 1,0x864D, + 1,0x866B, + 1,0x8840, + 1,0x884C, + 1,0x8863, + 1,0x897E, + 1,0x898B, + 1,0x89D2, + 1,0x8A00, + 1,0x8C37, + 1,0x8C46, + 1,0x8C55, + 1,0x8C78, + 1,0x8C9D, + 1,0x8D64, + 1,0x8D70, + 1,0x8DB3, + 1,0x8EAB, + 1,0x8ECA, + 1,0x8F9B, + 1,0x8FB0, + 1,0x8FB5, + 1,0x9091, + 1,0x9149, + 1,0x91C6, + 1,0x91CC, + 1,0x91D1, + 1,0x9577, + 1,0x9580, + 1,0x961C, + 1,0x96B6, + 1,0x96B9, + 1,0x96E8, + 1,0x9751, + 1,0x975E, + 1,0x9762, + 1,0x9769, + 1,0x97CB, + 1,0x97ED, + 1,0x97F3, + 1,0x9801, + 1,0x98A8, + 1,0x98DB, + 1,0x98DF, + 1,0x9996, + 1,0x9999, + 1,0x99AC, + 1,0x9AA8, + 1,0x9AD8, + 1,0x9ADF, + 1,0x9B25, + 1,0x9B2F, + 1,0x9B32, + 1,0x9B3C, + 1,0x9B5A, + 1,0x9CE5, + 1,0x9E75, + 1,0x9E7F, + 1,0x9EA5, + 1,0x9EBB, + 1,0x9EC3, + 1,0x9ECD, + 1,0x9ED1, + 1,0x9EF9, + 1,0x9EFD, + 1,0x9F0E, + 1,0x9F13, + 1,0x9F20, + 1,0x9F3B, + 1,0x9F4A, + 1,0x9F52, + 1,0x9F8D, + 1,0x9F9C, + 1,0x9FA0, + 1, ' ', + 1,0x3012, + 1,0x5341, + 1,0x5344, + 1,0x5345, + 1,0x3042, + 1,0x3044, + 1,0x3046, + 1,0x3048, + 1,0x304A, + 1,0x3064, + 1,0x3084, + 1,0x3086, + 1,0x3088, + 1,0x308F, + 1,0x304B, + 1,0x3051, + 2, ' ',0x3099, + 2, ' ',0x309A, + 1, '=', + 1,0x30A2, + 1,0x30A4, + 1,0x30A6, + 1,0x30A8, + 1,0x30AA, + 1,0x30C4, + 1,0x30E4, + 1,0x30E6, + 1,0x30E8, + 1,0x30EF, + 1,0x30AB, + 1,0x30B1, + 1,0x1100, + 1,0x1101, + 1,0x11AA, + 1,0x1102, + 1,0x11AC, + 1,0x11AD, + 1,0x1103, + 1,0x1104, + 1,0x1105, + 1,0x11B0, + 1,0x11B1, + 1,0x11B2, + 1,0x11B3, + 1,0x11B4, + 1,0x11B5, + 1,0x111A, + 1,0x1106, + 1,0x1107, + 1,0x1108, + 1,0x1121, + 1,0x1109, + 1,0x110A, + 1,0x110B, + 1,0x110C, + 1,0x110D, + 1,0x110E, + 1,0x110F, + 1,0x1110, + 1,0x1111, + 1,0x1112, + 1,0x1161, + 1,0x1162, + 1,0x1163, + 1,0x1164, + 1,0x1165, + 1,0x1166, + 1,0x1167, + 1,0x1168, + 1,0x1169, + 1,0x116A, + 1,0x116B, + 1,0x116C, + 1,0x116D, + 1,0x116E, + 1,0x116F, + 1,0x1170, + 1,0x1171, + 1,0x1172, + 1,0x1173, + 1,0x1174, + 1,0x1175, + 1,0x1160, + 1,0x1114, + 1,0x1115, + 1,0x11C7, + 1,0x11C8, + 1,0x11CC, + 1,0x11CE, + 1,0x11D3, + 1,0x11D7, + 1,0x11D9, + 1,0x111C, + 1,0x11DD, + 1,0x11DF, + 1,0x111D, + 1,0x111E, + 1,0x1120, + 1,0x1122, + 1,0x1123, + 1,0x1127, + 1,0x1129, + 1,0x112B, + 1,0x112C, + 1,0x112D, + 1,0x112E, + 1,0x112F, + 1,0x1132, + 1,0x1136, + 1,0x1140, + 1,0x1147, + 1,0x114C, + 1,0x11F1, + 1,0x11F2, + 1,0x1157, + 1,0x1158, + 1,0x1159, + 1,0x1184, + 1,0x1185, + 1,0x1188, + 1,0x1191, + 1,0x1192, + 1,0x1194, + 1,0x119E, + 1,0x11A1, + 1,0x30AF, + 1,0x30B7, + 1,0x30B9, + 1,0x30C8, + 1,0x30CC, + 1,0x30CF, + 1,0x30D2, + 1,0x30D5, + 1,0x30D8, + 1,0x30DB, + 1,0x30E0, + 1,0x30E9, + 1,0x30EA, + 1,0x30EB, + 1,0x30EC, + 1,0x30ED, + 3, '(',0x1100, ')', + 3, '(',0x1102, ')', + 3, '(',0x1103, ')', + 3, '(',0x1105, ')', + 3, '(',0x1106, ')', + 3, '(',0x1107, ')', + 3, '(',0x1109, ')', + 3, '(',0x110B, ')', + 3, '(',0x110C, ')', + 3, '(',0x110E, ')', + 3, '(',0x110F, ')', + 3, '(',0x1110, ')', + 3, '(',0x1111, ')', + 3, '(',0x1112, ')', + 4, '(',0x1100,0x1161, ')', + 4, '(',0x1102,0x1161, ')', + 4, '(',0x1103,0x1161, ')', + 4, '(',0x1105,0x1161, ')', + 4, '(',0x1106,0x1161, ')', + 4, '(',0x1107,0x1161, ')', + 4, '(',0x1109,0x1161, ')', + 4, '(',0x110B,0x1161, ')', + 4, '(',0x110C,0x1161, ')', + 4, '(',0x110E,0x1161, ')', + 4, '(',0x110F,0x1161, ')', + 4, '(',0x1110,0x1161, ')', + 4, '(',0x1111,0x1161, ')', + 4, '(',0x1112,0x1161, ')', + 4, '(',0x110C,0x116E, ')', + 7, '(',0x110B,0x1169,0x110C,0x1165,0x11AB, ')', + 6, '(',0x110B,0x1169,0x1112,0x116E, ')', + 3, '(',0x4E00, ')', + 3, '(',0x4E8C, ')', + 3, '(',0x4E09, ')', + 3, '(',0x56DB, ')', + 3, '(',0x4E94, ')', + 3, '(',0x516D, ')', + 3, '(',0x4E03, ')', + 3, '(',0x516B, ')', + 3, '(',0x4E5D, ')', + 3, '(',0x5341, ')', + 3, '(',0x6708, ')', + 3, '(',0x706B, ')', + 3, '(',0x6C34, ')', + 3, '(',0x6728, ')', + 3, '(',0x91D1, ')', + 3, '(',0x571F, ')', + 3, '(',0x65E5, ')', + 3, '(',0x682A, ')', + 3, '(',0x6709, ')', + 3, '(',0x793E, ')', + 3, '(',0x540D, ')', + 3, '(',0x7279, ')', + 3, '(',0x8CA1, ')', + 3, '(',0x795D, ')', + 3, '(',0x52B4, ')', + 3, '(',0x4EE3, ')', + 3, '(',0x547C, ')', + 3, '(',0x5B66, ')', + 3, '(',0x76E3, ')', + 3, '(',0x4F01, ')', + 3, '(',0x8CC7, ')', + 3, '(',0x5354, ')', + 3, '(',0x796D, ')', + 3, '(',0x4F11, ')', + 3, '(',0x81EA, ')', + 3, '(',0x81F3, ')', + 3, 'P', 'T', 'E', + 4, '(', '2', '1', ')', + 4, '(', '2', '2', ')', + 4, '(', '2', '3', ')', + 4, '(', '2', '4', ')', + 4, '(', '2', '5', ')', + 4, '(', '2', '6', ')', + 4, '(', '2', '7', ')', + 4, '(', '2', '8', ')', + 4, '(', '2', '9', ')', + 4, '(', '3', '0', ')', + 4, '(', '3', '1', ')', + 4, '(', '3', '2', ')', + 4, '(', '3', '3', ')', + 4, '(', '3', '4', ')', + 4, '(', '3', '5', ')', + 3, '(',0x1100, ')', + 3, '(',0x1102, ')', + 3, '(',0x1103, ')', + 3, '(',0x1105, ')', + 3, '(',0x1106, ')', + 3, '(',0x1107, ')', + 3, '(',0x1109, ')', + 3, '(',0x110B, ')', + 3, '(',0x110C, ')', + 3, '(',0x110E, ')', + 3, '(',0x110F, ')', + 3, '(',0x1110, ')', + 3, '(',0x1111, ')', + 3, '(',0x1112, ')', + 4, '(',0x1100,0x1161, ')', + 4, '(',0x1102,0x1161, ')', + 4, '(',0x1103,0x1161, ')', + 4, '(',0x1105,0x1161, ')', + 4, '(',0x1106,0x1161, ')', + 4, '(',0x1107,0x1161, ')', + 4, '(',0x1109,0x1161, ')', + 4, '(',0x110B,0x1161, ')', + 4, '(',0x110C,0x1161, ')', + 4, '(',0x110E,0x1161, ')', + 4, '(',0x110F,0x1161, ')', + 4, '(',0x1110,0x1161, ')', + 4, '(',0x1111,0x1161, ')', + 4, '(',0x1112,0x1161, ')', + 7, '(',0x110E,0x1161,0x11B7,0x1100,0x1169, ')', + 6, '(',0x110C,0x116E,0x110B,0x1174, ')', + 3, '(',0x4E00, ')', + 3, '(',0x4E8C, ')', + 3, '(',0x4E09, ')', + 3, '(',0x56DB, ')', + 3, '(',0x4E94, ')', + 3, '(',0x516D, ')', + 3, '(',0x4E03, ')', + 3, '(',0x516B, ')', + 3, '(',0x4E5D, ')', + 3, '(',0x5341, ')', + 3, '(',0x6708, ')', + 3, '(',0x706B, ')', + 3, '(',0x6C34, ')', + 3, '(',0x6728, ')', + 3, '(',0x91D1, ')', + 3, '(',0x571F, ')', + 3, '(',0x65E5, ')', + 3, '(',0x682A, ')', + 3, '(',0x6709, ')', + 3, '(',0x793E, ')', + 3, '(',0x540D, ')', + 3, '(',0x7279, ')', + 3, '(',0x8CA1, ')', + 3, '(',0x795D, ')', + 3, '(',0x52B4, ')', + 3, '(',0x79D8, ')', + 3, '(',0x7537, ')', + 3, '(',0x5973, ')', + 3, '(',0x9069, ')', + 3, '(',0x512A, ')', + 3, '(',0x5370, ')', + 3, '(',0x6CE8, ')', + 3, '(',0x9805, ')', + 3, '(',0x4F11, ')', + 3, '(',0x5199, ')', + 3, '(',0x6B63, ')', + 3, '(',0x4E0A, ')', + 3, '(',0x4E2D, ')', + 3, '(',0x4E0B, ')', + 3, '(',0x5DE6, ')', + 3, '(',0x53F3, ')', + 3, '(',0x533B, ')', + 3, '(',0x5B97, ')', + 3, '(',0x5B66, ')', + 3, '(',0x76E3, ')', + 3, '(',0x4F01, ')', + 3, '(',0x8CC7, ')', + 3, '(',0x5354, ')', + 3, '(',0x591C, ')', + 4, '(', '3', '6', ')', + 4, '(', '3', '7', ')', + 4, '(', '3', '8', ')', + 4, '(', '3', '9', ')', + 4, '(', '4', '0', ')', + 4, '(', '4', '1', ')', + 4, '(', '4', '2', ')', + 4, '(', '4', '3', ')', + 4, '(', '4', '4', ')', + 4, '(', '4', '5', ')', + 4, '(', '4', '6', ')', + 4, '(', '4', '7', ')', + 4, '(', '4', '8', ')', + 4, '(', '4', '9', ')', + 4, '(', '5', '0', ')', + 2, '1',0x6708, + 2, '2',0x6708, + 2, '3',0x6708, + 2, '4',0x6708, + 2, '5',0x6708, + 2, '6',0x6708, + 2, '7',0x6708, + 2, '8',0x6708, + 2, '9',0x6708, + 3, '1', '0',0x6708, + 3, '1', '1',0x6708, + 3, '1', '2',0x6708, + 2, 'H', 'g', + 3, 'e', 'r', 'g', + 2, 'e', 'V', + 3, 'L', 'T', 'D', + 3, '(',0x30A2, ')', + 3, '(',0x30A4, ')', + 3, '(',0x30A6, ')', + 3, '(',0x30A8, ')', + 3, '(',0x30AA, ')', + 3, '(',0x30AB, ')', + 3, '(',0x30AD, ')', + 3, '(',0x30AF, ')', + 3, '(',0x30B1, ')', + 3, '(',0x30B3, ')', + 3, '(',0x30B5, ')', + 3, '(',0x30B7, ')', + 3, '(',0x30B9, ')', + 3, '(',0x30BB, ')', + 3, '(',0x30BD, ')', + 3, '(',0x30BF, ')', + 3, '(',0x30C1, ')', + 3, '(',0x30C4, ')', + 3, '(',0x30C6, ')', + 3, '(',0x30C8, ')', + 3, '(',0x30CA, ')', + 3, '(',0x30CB, ')', + 3, '(',0x30CC, ')', + 3, '(',0x30CD, ')', + 3, '(',0x30CE, ')', + 3, '(',0x30CF, ')', + 3, '(',0x30D2, ')', + 3, '(',0x30D5, ')', + 3, '(',0x30D8, ')', + 3, '(',0x30DB, ')', + 3, '(',0x30DE, ')', + 3, '(',0x30DF, ')', + 3, '(',0x30E0, ')', + 3, '(',0x30E1, ')', + 3, '(',0x30E2, ')', + 3, '(',0x30E4, ')', + 3, '(',0x30E6, ')', + 3, '(',0x30E8, ')', + 3, '(',0x30E9, ')', + 3, '(',0x30EA, ')', + 3, '(',0x30EB, ')', + 3, '(',0x30EC, ')', + 3, '(',0x30ED, ')', + 3, '(',0x30EF, ')', + 3, '(',0x30F0, ')', + 3, '(',0x30F1, ')', + 3, '(',0x30F2, ')', + 4,0x30A2,0x30D1,0x30FC,0x30C8, + 4,0x30A2,0x30EB,0x30D5,0x30A1, + 4,0x30A2,0x30F3,0x30DA,0x30A2, + 3,0x30A2,0x30FC,0x30EB, + 4,0x30A4,0x30CB,0x30F3,0x30B0, + 3,0x30A4,0x30F3,0x30C1, + 3,0x30A6,0x30A9,0x30F3, + 5,0x30A8,0x30B9,0x30AF,0x30FC,0x30C9, + 4,0x30A8,0x30FC,0x30AB,0x30FC, + 3,0x30AA,0x30F3,0x30B9, + 3,0x30AA,0x30FC,0x30E0, + 3,0x30AB,0x30A4,0x30EA, + 4,0x30AB,0x30E9,0x30C3,0x30C8, + 4,0x30AB,0x30ED,0x30EA,0x30FC, + 3,0x30AC,0x30ED,0x30F3, + 3,0x30AC,0x30F3,0x30DE, + 2,0x30AE,0x30AC, + 3,0x30AE,0x30CB,0x30FC, + 4,0x30AD,0x30E5,0x30EA,0x30FC, + 4,0x30AE,0x30EB,0x30C0,0x30FC, + 2,0x30AD,0x30ED, + 5,0x30AD,0x30ED,0x30B0,0x30E9,0x30E0, + 6,0x30AD,0x30ED,0x30E1,0x30FC,0x30C8,0x30EB, + 5,0x30AD,0x30ED,0x30EF,0x30C3,0x30C8, + 3,0x30B0,0x30E9,0x30E0, + 5,0x30B0,0x30E9,0x30E0,0x30C8,0x30F3, + 5,0x30AF,0x30EB,0x30BC,0x30A4,0x30ED, + 4,0x30AF,0x30ED,0x30FC,0x30CD, + 3,0x30B1,0x30FC,0x30B9, + 3,0x30B3,0x30EB,0x30CA, + 3,0x30B3,0x30FC,0x30DD, + 4,0x30B5,0x30A4,0x30AF,0x30EB, + 5,0x30B5,0x30F3,0x30C1,0x30FC,0x30E0, + 4,0x30B7,0x30EA,0x30F3,0x30B0, + 3,0x30BB,0x30F3,0x30C1, + 3,0x30BB,0x30F3,0x30C8, + 3,0x30C0,0x30FC,0x30B9, + 2,0x30C7,0x30B7, + 2,0x30C9,0x30EB, + 2,0x30C8,0x30F3, + 2,0x30CA,0x30CE, + 3,0x30CE,0x30C3,0x30C8, + 3,0x30CF,0x30A4,0x30C4, + 5,0x30D1,0x30FC,0x30BB,0x30F3,0x30C8, + 3,0x30D1,0x30FC,0x30C4, + 4,0x30D0,0x30FC,0x30EC,0x30EB, + 5,0x30D4,0x30A2,0x30B9,0x30C8,0x30EB, + 3,0x30D4,0x30AF,0x30EB, + 2,0x30D4,0x30B3, + 2,0x30D3,0x30EB, + 5,0x30D5,0x30A1,0x30E9,0x30C3,0x30C9, + 4,0x30D5,0x30A3,0x30FC,0x30C8, + 5,0x30D6,0x30C3,0x30B7,0x30A7,0x30EB, + 3,0x30D5,0x30E9,0x30F3, + 5,0x30D8,0x30AF,0x30BF,0x30FC,0x30EB, + 2,0x30DA,0x30BD, + 3,0x30DA,0x30CB,0x30D2, + 3,0x30D8,0x30EB,0x30C4, + 3,0x30DA,0x30F3,0x30B9, + 3,0x30DA,0x30FC,0x30B8, + 3,0x30D9,0x30FC,0x30BF, + 4,0x30DD,0x30A4,0x30F3,0x30C8, + 3,0x30DC,0x30EB,0x30C8, + 2,0x30DB,0x30F3, + 3,0x30DD,0x30F3,0x30C9, + 3,0x30DB,0x30FC,0x30EB, + 3,0x30DB,0x30FC,0x30F3, + 4,0x30DE,0x30A4,0x30AF,0x30ED, + 3,0x30DE,0x30A4,0x30EB, + 3,0x30DE,0x30C3,0x30CF, + 3,0x30DE,0x30EB,0x30AF, + 5,0x30DE,0x30F3,0x30B7,0x30E7,0x30F3, + 4,0x30DF,0x30AF,0x30ED,0x30F3, + 2,0x30DF,0x30EA, + 5,0x30DF,0x30EA,0x30D0,0x30FC,0x30EB, + 2,0x30E1,0x30AC, + 4,0x30E1,0x30AC,0x30C8,0x30F3, + 4,0x30E1,0x30FC,0x30C8,0x30EB, + 3,0x30E4,0x30FC,0x30C9, + 3,0x30E4,0x30FC,0x30EB, + 3,0x30E6,0x30A2,0x30F3, + 4,0x30EA,0x30C3,0x30C8,0x30EB, + 2,0x30EA,0x30E9, + 3,0x30EB,0x30D4,0x30FC, + 4,0x30EB,0x30FC,0x30D6,0x30EB, + 2,0x30EC,0x30E0, + 5,0x30EC,0x30F3,0x30C8,0x30B2,0x30F3, + 3,0x30EF,0x30C3,0x30C8, + 2, '0',0x70B9, + 2, '1',0x70B9, + 2, '2',0x70B9, + 2, '3',0x70B9, + 2, '4',0x70B9, + 2, '5',0x70B9, + 2, '6',0x70B9, + 2, '7',0x70B9, + 2, '8',0x70B9, + 2, '9',0x70B9, + 3, '1', '0',0x70B9, + 3, '1', '1',0x70B9, + 3, '1', '2',0x70B9, + 3, '1', '3',0x70B9, + 3, '1', '4',0x70B9, + 3, '1', '5',0x70B9, + 3, '1', '6',0x70B9, + 3, '1', '7',0x70B9, + 3, '1', '8',0x70B9, + 3, '1', '9',0x70B9, + 3, '2', '0',0x70B9, + 3, '2', '1',0x70B9, + 3, '2', '2',0x70B9, + 3, '2', '3',0x70B9, + 3, '2', '4',0x70B9, + 3, 'h', 'P', 'a', + 2, 'd', 'a', + 2, 'A', 'U', + 3, 'b', 'a', 'r', + 2, 'o', 'V', + 2, 'p', 'c', + 2, 'd', 'm', + 4, 'd', 'm', '^', '2', + 4, 'd', 'm', '^', '3', + 2, 'I', 'U', + 2,0x5E73,0x6210, + 2,0x662D,0x548C, + 2,0x5927,0x6B63, + 2,0x660E,0x6CBB, + 4,0x682A,0x5F0F,0x4F1A,0x793E, + 2, 'p', 'A', + 2, 'n', 'A', + 2,0x03BC, 'A', + 2, 'm', 'A', + 2, 'k', 'A', + 2, 'K', 'B', + 2, 'M', 'B', + 2, 'G', 'B', + 3, 'c', 'a', 'l', + 4, 'k', 'c', 'a', 'l', + 2, 'p', 'F', + 2, 'n', 'F', + 2,0x03BC, 'F', + 2,0x03BC, 'g', + 2, 'm', 'g', + 2, 'k', 'g', + 2, 'H', 'z', + 3, 'k', 'H', 'z', + 3, 'M', 'H', 'z', + 3, 'G', 'H', 'z', + 3, 'T', 'H', 'z', + 2,0x03BC, 'l', + 2, 'm', 'l', + 2, 'd', 'l', + 2, 'k', 'l', + 2, 'f', 'm', + 2, 'n', 'm', + 2,0x03BC, 'm', + 2, 'm', 'm', + 2, 'c', 'm', + 2, 'k', 'm', + 4, 'm', 'm', '^', '2', + 4, 'c', 'm', '^', '2', + 3, 'm', '^', '2', + 4, 'k', 'm', '^', '2', + 4, 'm', 'm', '^', '3', + 4, 'c', 'm', '^', '3', + 3, 'm', '^', '3', + 4, 'k', 'm', '^', '3', + 3, 'm', '/', 's', + 5, 'm', '/', 's', '^', '2', + 2, 'P', 'a', + 3, 'k', 'P', 'a', + 3, 'M', 'P', 'a', + 3, 'G', 'P', 'a', + 3, 'r', 'a', 'd', + 5, 'r', 'a', 'd', '/', 's', + 7, 'r', 'a', 'd', '/', 's', '^', '2', + 2, 'p', 's', + 2, 'n', 's', + 2,0x03BC, 's', + 2, 'm', 's', + 2, 'p', 'V', + 2, 'n', 'V', + 2,0x03BC, 'V', + 2, 'm', 'V', + 2, 'k', 'V', + 2, 'M', 'V', + 2, 'p', 'W', + 2, 'n', 'W', + 2,0x03BC, 'W', + 2, 'm', 'W', + 2, 'k', 'W', + 2, 'M', 'W', + 2, 'k',0x03A9, + 2, 'M',0x03A9, + 4, 'a', '.', 'm', '.', + 2, 'B', 'q', + 2, 'c', 'c', + 2, 'c', 'd', + 4, 'C', '/', 'k', 'g', + 3, 'C', 'o', '.', + 2, 'd', 'B', + 2, 'G', 'y', + 2, 'h', 'a', + 2, 'H', 'P', + 2, 'i', 'n', + 2, 'K', 'K', + 2, 'K', 'M', + 2, 'k', 't', + 2, 'l', 'm', + 2, 'l', 'n', + 3, 'l', 'o', 'g', + 2, 'l', 'x', + 2, 'm', 'b', + 3, 'm', 'i', 'l', + 3, 'm', 'o', 'l', + 2, 'P', 'H', + 4, 'p', '.', 'm', '.', + 3, 'P', 'P', 'M', + 2, 'P', 'R', + 2, 's', 'r', + 2, 'S', 'v', + 2, 'W', 'b', + 3, 'V', '/', 'm', + 3, 'A', '/', 'm', + 3, 'g', 'a', 'l', + 2, '1',0x65E5, + 2, '2',0x65E5, + 2, '3',0x65E5, + 2, '4',0x65E5, + 2, '5',0x65E5, + 2, '6',0x65E5, + 2, '7',0x65E5, + 2, '8',0x65E5, + 2, '9',0x65E5, + 3, '1', '0',0x65E5, + 3, '1', '1',0x65E5, + 3, '1', '2',0x65E5, + 3, '1', '3',0x65E5, + 3, '1', '4',0x65E5, + 3, '1', '5',0x65E5, + 3, '1', '6',0x65E5, + 3, '1', '7',0x65E5, + 3, '1', '8',0x65E5, + 3, '1', '9',0x65E5, + 3, '2', '0',0x65E5, + 3, '2', '1',0x65E5, + 3, '2', '2',0x65E5, + 3, '2', '3',0x65E5, + 3, '2', '4',0x65E5, + 3, '2', '5',0x65E5, + 3, '2', '6',0x65E5, + 3, '2', '7',0x65E5, + 3, '2', '8',0x65E5, + 3, '2', '9',0x65E5, + 3, '3', '0',0x65E5, + 3, '3', '1',0x65E5, + 1,0x8C48, + 1,0x66F4, + 1,0x8ECA, + 1,0x8CC8, + 1,0x6ED1, + 1,0x4E32, + 1,0x53E5, + 1,0x9F9C, + 1,0x9F9C, + 1,0x5951, + 1,0x91D1, + 1,0x5587, + 1,0x5948, + 1,0x61F6, + 1,0x7669, + 1,0x7F85, + 1,0x863F, + 1,0x87BA, + 1,0x88F8, + 1,0x908F, + 1,0x6A02, + 1,0x6D1B, + 1,0x70D9, + 1,0x73DE, + 1,0x843D, + 1,0x916A, + 1,0x99F1, + 1,0x4E82, + 1,0x5375, + 1,0x6B04, + 1,0x721B, + 1,0x862D, + 1,0x9E1E, + 1,0x5D50, + 1,0x6FEB, + 1,0x85CD, + 1,0x8964, + 1,0x62C9, + 1,0x81D8, + 1,0x881F, + 1,0x5ECA, + 1,0x6717, + 1,0x6D6A, + 1,0x72FC, + 1,0x90CE, + 1,0x4F86, + 1,0x51B7, + 1,0x52DE, + 1,0x64C4, + 1,0x6AD3, + 1,0x7210, + 1,0x76E7, + 1,0x8001, + 1,0x8606, + 1,0x865C, + 1,0x8DEF, + 1,0x9732, + 1,0x9B6F, + 1,0x9DFA, + 1,0x788C, + 1,0x797F, + 1,0x7DA0, + 1,0x83C9, + 1,0x9304, + 1,0x9E7F, + 1,0x8AD6, + 1,0x58DF, + 1,0x5F04, + 1,0x7C60, + 1,0x807E, + 1,0x7262, + 1,0x78CA, + 1,0x8CC2, + 1,0x96F7, + 1,0x58D8, + 1,0x5C62, + 1,0x6A13, + 1,0x6DDA, + 1,0x6F0F, + 1,0x7D2F, + 1,0x7E37, + 1,0x964B, + 1,0x52D2, + 1,0x808B, + 1,0x51DC, + 1,0x51CC, + 1,0x7A1C, + 1,0x7DBE, + 1,0x83F1, + 1,0x9675, + 1,0x8B80, + 1,0x62CF, + 1,0x6A02, + 1,0x8AFE, + 1,0x4E39, + 1,0x5BE7, + 1,0x6012, + 1,0x7387, + 1,0x7570, + 1,0x5317, + 1,0x78FB, + 1,0x4FBF, + 1,0x5FA9, + 1,0x4E0D, + 1,0x6CCC, + 1,0x6578, + 1,0x7D22, + 1,0x53C3, + 1,0x585E, + 1,0x7701, + 1,0x8449, + 1,0x8AAA, + 1,0x6BBA, + 1,0x8FB0, + 1,0x6C88, + 1,0x62FE, + 1,0x82E5, + 1,0x63A0, + 1,0x7565, + 1,0x4EAE, + 1,0x5169, + 1,0x51C9, + 1,0x6881, + 1,0x7CE7, + 1,0x826F, + 1,0x8AD2, + 1,0x91CF, + 1,0x52F5, + 1,0x5442, + 1,0x5973, + 1,0x5EEC, + 1,0x65C5, + 1,0x6FFE, + 1,0x792A, + 1,0x95AD, + 1,0x9A6A, + 1,0x9E97, + 1,0x9ECE, + 1,0x529B, + 1,0x66C6, + 1,0x6B77, + 1,0x8F62, + 1,0x5E74, + 1,0x6190, + 1,0x6200, + 1,0x649A, + 1,0x6F23, + 1,0x7149, + 1,0x7489, + 1,0x79CA, + 1,0x7DF4, + 1,0x806F, + 1,0x8F26, + 1,0x84EE, + 1,0x9023, + 1,0x934A, + 1,0x5217, + 1,0x52A3, + 1,0x54BD, + 1,0x70C8, + 1,0x88C2, + 1,0x8AAA, + 1,0x5EC9, + 1,0x5FF5, + 1,0x637B, + 1,0x6BAE, + 1,0x7C3E, + 1,0x7375, + 1,0x4EE4, + 1,0x56F9, + 1,0x5BE7, + 1,0x5DBA, + 1,0x601C, + 1,0x73B2, + 1,0x7469, + 1,0x7F9A, + 1,0x8046, + 1,0x9234, + 1,0x96F6, + 1,0x9748, + 1,0x9818, + 1,0x4F8B, + 1,0x79AE, + 1,0x91B4, + 1,0x96B8, + 1,0x60E1, + 1,0x4E86, + 1,0x50DA, + 1,0x5BEE, + 1,0x5C3F, + 1,0x6599, + 1,0x6A02, + 1,0x71CE, + 1,0x7642, + 1,0x84FC, + 1,0x907C, + 1,0x9F8D, + 1,0x6688, + 1,0x962E, + 1,0x5289, + 1,0x677B, + 1,0x67F3, + 1,0x6D41, + 1,0x6E9C, + 1,0x7409, + 1,0x7559, + 1,0x786B, + 1,0x7D10, + 1,0x985E, + 1,0x516D, + 1,0x622E, + 1,0x9678, + 1,0x502B, + 1,0x5D19, + 1,0x6DEA, + 1,0x8F2A, + 1,0x5F8B, + 1,0x6144, + 1,0x6817, + 1,0x7387, + 1,0x9686, + 1,0x5229, + 1,0x540F, + 1,0x5C65, + 1,0x6613, + 1,0x674E, + 1,0x68A8, + 1,0x6CE5, + 1,0x7406, + 1,0x75E2, + 1,0x7F79, + 1,0x88CF, + 1,0x88E1, + 1,0x91CC, + 1,0x96E2, + 1,0x533F, + 1,0x6EBA, + 1,0x541D, + 1,0x71D0, + 1,0x7498, + 1,0x85FA, + 1,0x96A3, + 1,0x9C57, + 1,0x9E9F, + 1,0x6797, + 1,0x6DCB, + 1,0x81E8, + 1,0x7ACB, + 1,0x7B20, + 1,0x7C92, + 1,0x72C0, + 1,0x7099, + 1,0x8B58, + 1,0x4EC0, + 1,0x8336, + 1,0x523A, + 1,0x5207, + 1,0x5EA6, + 1,0x62D3, + 1,0x7CD6, + 1,0x5B85, + 1,0x6D1E, + 1,0x66B4, + 1,0x8F3B, + 1,0x884C, + 1,0x964D, + 1,0x898B, + 1,0x5ED3, + 1,0x5140, + 1,0x55C0, + 1,0x585A, + 1,0x6674, + 1,0x51DE, + 1,0x732A, + 1,0x76CA, + 1,0x793C, + 1,0x795E, + 1,0x7965, + 1,0x798F, + 1,0x9756, + 1,0x7CBE, + 1,0x7FBD, + 1,0x8612, + 1,0x8AF8, + 1,0x9038, + 1,0x90FD, + 1,0x98EF, + 1,0x98FC, + 1,0x9928, + 1,0x9DB4, + 1,0x4FAE, + 1,0x50E7, + 1,0x514D, + 1,0x52C9, + 1,0x52E4, + 1,0x5351, + 1,0x559D, + 1,0x5606, + 1,0x5668, + 1,0x5840, + 1,0x58A8, + 1,0x5C64, + 1,0x5C6E, + 1,0x6094, + 1,0x6168, + 1,0x618E, + 1,0x61F2, + 1,0x654F, + 1,0x65E2, + 1,0x6691, + 1,0x6885, + 1,0x6D77, + 1,0x6E1A, + 1,0x6F22, + 1,0x716E, + 1,0x722B, + 1,0x7422, + 1,0x7891, + 1,0x793E, + 1,0x7949, + 1,0x7948, + 1,0x7950, + 1,0x7956, + 1,0x795D, + 1,0x798D, + 1,0x798E, + 1,0x7A40, + 1,0x7A81, + 1,0x7BC0, + 1,0x7DF4, + 1,0x7E09, + 1,0x7E41, + 1,0x7F72, + 1,0x8005, + 1,0x81ED, + 1,0x8279, + 1,0x8279, + 1,0x8457, + 1,0x8910, + 1,0x8996, + 1,0x8B01, + 1,0x8B39, + 1,0x8CD3, + 1,0x8D08, + 1,0x8FB6, + 1,0x9038, + 1,0x96E3, + 1,0x97FF, + 1,0x983B, + 2, 'f', 'f', + 2, 'f', 'i', + 2, 'f', 'l', + 3, 'f', 'f', 'i', + 3, 'f', 'f', 'l', + 2,0x017F, 't', + 2, 's', 't', + 2,0x0574,0x0576, + 2,0x0574,0x0565, + 2,0x0574,0x056B, + 2,0x057E,0x0576, + 2,0x0574,0x056D, + 1,0x05E2, + 1,0x05D0, + 1,0x05D3, + 1,0x05D4, + 1,0x05DB, + 1,0x05DC, + 1,0x05DD, + 1,0x05E8, + 1,0x05EA, + 1, '+', + 2,0x05D0,0x05DC, + 1,0x203E, + 1,0x203E, + 1,0x203E, + 1,0x203E, + 1, '_', + 1, '_', + 1, '_', + 1, ',', + 1,0x3001, + 1, '.', + 1, ';', + 1, ':', + 1, '?', + 1, '!', + 1,0x2014, + 1, '(', + 1, ')', + 1, '{', + 1, '}', + 1,0x3014, + 1,0x3015, + 1, '#', + 1, '&', + 1, '*', + 1, '+', + 1, '-', + 1, '<', + 1, '>', + 1, '=', + 1,'\\', + 1, '$', + 1, '%', + 1, '@', + 1, '!', + 1, '"', + 1, '#', + 1, '$', + 1, '%', + 1, '&', + 1,'\'', + 1, '(', + 1, ')', + 1, '*', + 1, '+', + 1, ',', + 1, '-', + 1, '.', + 1, '/', + 1, '0', + 1, '1', + 1, '2', + 1, '3', + 1, '4', + 1, '5', + 1, '6', + 1, '7', + 1, '8', + 1, '9', + 1, ':', + 1, ';', + 1, '<', + 1, '=', + 1, '>', + 1, '?', + 1, '@', + 1, 'A', + 1, 'B', + 1, 'C', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'H', + 1, 'I', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'R', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'Z', + 1, '[', + 1,'\\', + 1, ']', + 1, '^', + 1, '_', + 1, '`', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, '{', + 1, '|', + 1, '}', + 1, '~', + 1,0x2985, + 1,0x2986, + 1,0x3002, + 1,0x300C, + 1,0x300D, + 1,0x3001, + 1,0x30FB, + 1,0x30F2, + 1,0x30A1, + 1,0x30A3, + 1,0x30A5, + 1,0x30A7, + 1,0x30A9, + 1,0x30E3, + 1,0x30E5, + 1,0x30E7, + 1,0x30C3, + 1,0x30FC, + 1,0x30A2, + 1,0x30A4, + 1,0x30A6, + 1,0x30A8, + 1,0x30AA, + 1,0x30AB, + 1,0x30AD, + 1,0x30AF, + 1,0x30B1, + 1,0x30B3, + 1,0x30B5, + 1,0x30B7, + 1,0x30B9, + 1,0x30BB, + 1,0x30BD, + 1,0x30BF, + 1,0x30C1, + 1,0x30C4, + 1,0x30C6, + 1,0x30C8, + 1,0x30CA, + 1,0x30CB, + 1,0x30CC, + 1,0x30CD, + 1,0x30CE, + 1,0x30CF, + 1,0x30D2, + 1,0x30D5, + 1,0x30D8, + 1,0x30DB, + 1,0x30DE, + 1,0x30DF, + 1,0x30E0, + 1,0x30E1, + 1,0x30E2, + 1,0x30E4, + 1,0x30E6, + 1,0x30E8, + 1,0x30E9, + 1,0x30EA, + 1,0x30EB, + 1,0x30EC, + 1,0x30ED, + 1,0x30EF, + 1,0x30F3, + 1,0x3099, + 1,0x309A, + 1,0x3164, + 1,0x3131, + 1,0x3132, + 1,0x3133, + 1,0x3134, + 1,0x3135, + 1,0x3136, + 1,0x3137, + 1,0x3138, + 1,0x3139, + 1,0x313A, + 1,0x313B, + 1,0x313C, + 1,0x313D, + 1,0x313E, + 1,0x313F, + 1,0x3140, + 1,0x3141, + 1,0x3142, + 1,0x3143, + 1,0x3144, + 1,0x3145, + 1,0x3146, + 1,0x3147, + 1,0x3148, + 1,0x3149, + 1,0x314A, + 1,0x314B, + 1,0x314C, + 1,0x314D, + 1,0x314E, + 1,0x314F, + 1,0x3150, + 1,0x3151, + 1,0x3152, + 1,0x3153, + 1,0x3154, + 1,0x3155, + 1,0x3156, + 1,0x3157, + 1,0x3158, + 1,0x3159, + 1,0x315A, + 1,0x315B, + 1,0x315C, + 1,0x315D, + 1,0x315E, + 1,0x315F, + 1,0x3160, + 1,0x3161, + 1,0x3162, + 1,0x3163, + 1,0xA2, + 1,0xA3, + 1,0xAC, + 1,0xAF, + 1,0xA6, + 1,0xA5, + 1,0x20A9, + 1,0x2502, + 1,0x2190, + 1,0x2191, + 1,0x2192, + 1,0x2193, + 1,0x25A0, + 1,0x25CB, + 1, 'A', + 1, 'B', + 1, 'C', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'H', + 1, 'I', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'R', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'Z', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, 'A', + 1, 'B', + 1, 'C', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'H', + 1, 'I', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'R', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'Z', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, 'A', + 1, 'B', + 1, 'C', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'H', + 1, 'I', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'R', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'Z', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, 'A', + 1, 'C', + 1, 'D', + 1, 'G', + 1, 'J', + 1, 'K', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'Z', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'f', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, 'A', + 1, 'B', + 1, 'C', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'H', + 1, 'I', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'R', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'Z', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, 'A', + 1, 'B', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, 'A', + 1, 'B', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'I', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'O', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, 'A', + 1, 'B', + 1, 'C', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'H', + 1, 'I', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'R', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'Z', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, 'A', + 1, 'B', + 1, 'C', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'H', + 1, 'I', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'R', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'Z', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, 'A', + 1, 'B', + 1, 'C', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'H', + 1, 'I', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'R', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'Z', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, 'A', + 1, 'B', + 1, 'C', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'H', + 1, 'I', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'R', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'Z', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, 'A', + 1, 'B', + 1, 'C', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'H', + 1, 'I', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'R', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'Z', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1, 'A', + 1, 'B', + 1, 'C', + 1, 'D', + 1, 'E', + 1, 'F', + 1, 'G', + 1, 'H', + 1, 'I', + 1, 'J', + 1, 'K', + 1, 'L', + 1, 'M', + 1, 'N', + 1, 'O', + 1, 'P', + 1, 'Q', + 1, 'R', + 1, 'S', + 1, 'T', + 1, 'U', + 1, 'V', + 1, 'W', + 1, 'X', + 1, 'Y', + 1, 'Z', + 1, 'a', + 1, 'b', + 1, 'c', + 1, 'd', + 1, 'e', + 1, 'f', + 1, 'g', + 1, 'h', + 1, 'i', + 1, 'j', + 1, 'k', + 1, 'l', + 1, 'm', + 1, 'n', + 1, 'o', + 1, 'p', + 1, 'q', + 1, 'r', + 1, 's', + 1, 't', + 1, 'u', + 1, 'v', + 1, 'w', + 1, 'x', + 1, 'y', + 1, 'z', + 1,0x0391, + 1,0x0392, + 1,0x0393, + 1,0x0394, + 1,0x0395, + 1,0x0396, + 1,0x0397, + 1,0x0398, + 1,0x0399, + 1,0x039A, + 1,0x039B, + 1,0x039C, + 1,0x039D, + 1,0x039E, + 1,0x039F, + 1,0x03A0, + 1,0x03A1, + 1,0x03F4, + 1,0x03A3, + 1,0x03A4, + 1,0x03A5, + 1,0x03A6, + 1,0x03A7, + 1,0x03A8, + 1,0x03A9, + 1,0x2207, + 1,0x03B1, + 1,0x03B2, + 1,0x03B3, + 1,0x03B4, + 1,0x03B5, + 1,0x03B6, + 1,0x03B7, + 1,0x03B8, + 1,0x03B9, + 1,0x03BA, + 1,0x03BB, + 1,0x03BC, + 1,0x03BD, + 1,0x03BE, + 1,0x03BF, + 1,0x03C0, + 1,0x03C1, + 1,0x03C2, + 1,0x03C3, + 1,0x03C4, + 1,0x03C5, + 1,0x03C6, + 1,0x03C7, + 1,0x03C8, + 1,0x03C9, + 1,0x2202, + 1,0x03F5, + 1,0x03D1, + 1,0x03F0, + 1,0x03D5, + 1,0x03F1, + 1,0x03D6, + 1,0x0391, + 1,0x0392, + 1,0x0393, + 1,0x0394, + 1,0x0395, + 1,0x0396, + 1,0x0397, + 1,0x0398, + 1,0x0399, + 1,0x039A, + 1,0x039B, + 1,0x039C, + 1,0x039D, + 1,0x039E, + 1,0x039F, + 1,0x03A0, + 1,0x03A1, + 1,0x03F4, + 1,0x03A3, + 1,0x03A4, + 1,0x03A5, + 1,0x03A6, + 1,0x03A7, + 1,0x03A8, + 1,0x03A9, + 1,0x2207, + 1,0x03B1, + 1,0x03B2, + 1,0x03B3, + 1,0x03B4, + 1,0x03B5, + 1,0x03B6, + 1,0x03B7, + 1,0x03B8, + 1,0x03B9, + 1,0x03BA, + 1,0x03BB, + 1,0x03BC, + 1,0x03BD, + 1,0x03BE, + 1,0x03BF, + 1,0x03C0, + 1,0x03C1, + 1,0x03C2, + 1,0x03C3, + 1,0x03C4, + 1,0x03C5, + 1,0x03C6, + 1,0x03C7, + 1,0x03C8, + 1,0x03C9, + 1,0x2202, + 1,0x03F5, + 1,0x03D1, + 1,0x03F0, + 1,0x03D5, + 1,0x03F1, + 1,0x03D6, + 1,0x0391, + 1,0x0392, + 1,0x0393, + 1,0x0394, + 1,0x0395, + 1,0x0396, + 1,0x0397, + 1,0x0398, + 1,0x0399, + 1,0x039A, + 1,0x039B, + 1,0x039C, + 1,0x039D, + 1,0x039E, + 1,0x039F, + 1,0x03A0, + 1,0x03A1, + 1,0x03F4, + 1,0x03A3, + 1,0x03A4, + 1,0x03A5, + 1,0x03A6, + 1,0x03A7, + 1,0x03A8, + 1,0x03A9, + 1,0x2207, + 1,0x03B1, + 1,0x03B2, + 1,0x03B3, + 1,0x03B4, + 1,0x03B5, + 1,0x03B6, + 1,0x03B7, + 1,0x03B8, + 1,0x03B9, + 1,0x03BA, + 1,0x03BB, + 1,0x03BC, + 1,0x03BD, + 1,0x03BE, + 1,0x03BF, + 1,0x03C0, + 1,0x03C1, + 1,0x03C2, + 1,0x03C3, + 1,0x03C4, + 1,0x03C5, + 1,0x03C6, + 1,0x03C7, + 1,0x03C8, + 1,0x03C9, + 1,0x2202, + 1,0x03F5, + 1,0x03D1, + 1,0x03F0, + 1,0x03D5, + 1,0x03F1, + 1,0x03D6, + 1,0x0391, + 1,0x0392, + 1,0x0393, + 1,0x0394, + 1,0x0395, + 1,0x0396, + 1,0x0397, + 1,0x0398, + 1,0x0399, + 1,0x039A, + 1,0x039B, + 1,0x039C, + 1,0x039D, + 1,0x039E, + 1,0x039F, + 1,0x03A0, + 1,0x03A1, + 1,0x03F4, + 1,0x03A3, + 1,0x03A4, + 1,0x03A5, + 1,0x03A6, + 1,0x03A7, + 1,0x03A8, + 1,0x03A9, + 1,0x2207, + 1,0x03B1, + 1,0x03B2, + 1,0x03B3, + 1,0x03B4, + 1,0x03B5, + 1,0x03B6, + 1,0x03B7, + 1,0x03B8, + 1,0x03B9, + 1,0x03BA, + 1,0x03BB, + 1,0x03BC, + 1,0x03BD, + 1,0x03BE, + 1,0x03BF, + 1,0x03C0, + 1,0x03C1, + 1,0x03C2, + 1,0x03C3, + 1,0x03C4, + 1,0x03C5, + 1,0x03C6, + 1,0x03C7, + 1,0x03C8, + 1,0x03C9, + 1,0x2202, + 1,0x03F5, + 1,0x03D1, + 1,0x03F0, + 1,0x03D5, + 1,0x03F1, + 1,0x03D6, + 1,0x0391, + 1,0x0392, + 1,0x0393, + 1,0x0394, + 1,0x0395, + 1,0x0396, + 1,0x0397, + 1,0x0398, + 1,0x0399, + 1,0x039A, + 1,0x039B, + 1,0x039C, + 1,0x039D, + 1,0x039E, + 1,0x039F, + 1,0x03A0, + 1,0x03A1, + 1,0x03F4, + 1,0x03A3, + 1,0x03A4, + 1,0x03A5, + 1,0x03A6, + 1,0x03A7, + 1,0x03A8, + 1,0x03A9, + 1,0x2207, + 1,0x03B1, + 1,0x03B2, + 1,0x03B3, + 1,0x03B4, + 1,0x03B5, + 1,0x03B6, + 1,0x03B7, + 1,0x03B8, + 1,0x03B9, + 1,0x03BA, + 1,0x03BB, + 1,0x03BC, + 1,0x03BD, + 1,0x03BE, + 1,0x03BF, + 1,0x03C0, + 1,0x03C1, + 1,0x03C2, + 1,0x03C3, + 1,0x03C4, + 1,0x03C5, + 1,0x03C6, + 1,0x03C7, + 1,0x03C8, + 1,0x03C9, + 1,0x2202, + 1,0x03F5, + 1,0x03D1, + 1,0x03F0, + 1,0x03D5, + 1,0x03F1, + 1,0x03D6, + 1, '0', + 1, '1', + 1, '2', + 1, '3', + 1, '4', + 1, '5', + 1, '6', + 1, '7', + 1, '8', + 1, '9', + 1, '0', + 1, '1', + 1, '2', + 1, '3', + 1, '4', + 1, '5', + 1, '6', + 1, '7', + 1, '8', + 1, '9', + 1, '0', + 1, '1', + 1, '2', + 1, '3', + 1, '4', + 1, '5', + 1, '6', + 1, '7', + 1, '8', + 1, '9', + 1, '0', + 1, '1', + 1, '2', + 1, '3', + 1, '4', + 1, '5', + 1, '6', + 1, '7', + 1, '8', + 1, '9', + 1, '0', + 1, '1', + 1, '2', + 1, '3', + 1, '4', + 1, '5', + 1, '6', + 1, '7', + 1, '8', + 1, '9', + 1,0x4E3D, + 1,0x4E38, + 1,0x4E41, + 1,0x20122, + 1,0x4F60, + 1,0x4FAE, + 1,0x4FBB, + 1,0x5002, + 1,0x507A, + 1,0x5099, + 1,0x50E7, + 1,0x50CF, + 1,0x349E, + 1,0x2063A, + 1,0x514D, + 1,0x5154, + 1,0x5164, + 1,0x5177, + 1,0x2051C, + 1,0x34B9, + 1,0x5167, + 1,0x518D, + 1,0x2054B, + 1,0x5197, + 1,0x51A4, + 1,0x4ECC, + 1,0x51AC, + 1,0x51B5, + 1,0x291DF, + 1,0x51F5, + 1,0x5203, + 1,0x34DF, + 1,0x523B, + 1,0x5246, + 1,0x5272, + 1,0x5277, + 1,0x3515, + 1,0x52C7, + 1,0x52C9, + 1,0x52E4, + 1,0x52FA, + 1,0x5305, + 1,0x5306, + 1,0x5317, + 1,0x5349, + 1,0x5351, + 1,0x535A, + 1,0x5373, + 1,0x537D, + 1,0x537F, + 1,0x537F, + 1,0x537F, + 1,0x20A2C, + 1,0x7070, + 1,0x53CA, + 1,0x53DF, + 1,0x20B63, + 1,0x53EB, + 1,0x53F1, + 1,0x5406, + 1,0x549E, + 1,0x5438, + 1,0x5448, + 1,0x5468, + 1,0x54A2, + 1,0x54F6, + 1,0x5510, + 1,0x5553, + 1,0x5563, + 1,0x5584, + 1,0x5584, + 1,0x5599, + 1,0x55AB, + 1,0x55B3, + 1,0x55C2, + 1,0x5716, + 1,0x5606, + 1,0x5717, + 1,0x5651, + 1,0x5674, + 1,0x5207, + 1,0x58EE, + 1,0x57CE, + 1,0x57F4, + 1,0x580D, + 1,0x578B, + 1,0x5832, + 1,0x5831, + 1,0x58AC, + 1,0x214E4, + 1,0x58F2, + 1,0x58F7, + 1,0x5906, + 1,0x591A, + 1,0x5922, + 1,0x5962, + 1,0x216A8, + 1,0x216EA, + 1,0x59EC, + 1,0x5A1B, + 1,0x5A27, + 1,0x59D8, + 1,0x5A66, + 1,0x36EE, + 1,0x36FC, + 1,0x5B08, + 1,0x5B3E, + 1,0x5B3E, + 1,0x219C8, + 1,0x5BC3, + 1,0x5BD8, + 1,0x5BE7, + 1,0x5BF3, + 1,0x21B18, + 1,0x5BFF, + 1,0x5C06, + 1,0x5F53, + 1,0x5C22, + 1,0x3781, + 1,0x5C60, + 1,0x5C6E, + 1,0x5CC0, + 1,0x5C8D, + 1,0x21DE4, + 1,0x5D43, + 1,0x21DE6, + 1,0x5D6E, + 1,0x5D6B, + 1,0x5D7C, + 1,0x5DE1, + 1,0x5DE2, + 1,0x382F, + 1,0x5DFD, + 1,0x5E28, + 1,0x5E3D, + 1,0x5E69, + 1,0x3862, + 1,0x22183, + 1,0x387C, + 1,0x5EB0, + 1,0x5EB3, + 1,0x5EB6, + 1,0x5ECA, + 1,0x2A392, + 1,0x5EFE, + 1,0x22331, + 1,0x22331, + 1,0x8201, + 1,0x5F22, + 1,0x5F22, + 1,0x38C7, + 1,0x232B8, + 1,0x261DA, + 1,0x5F62, + 1,0x5F6B, + 1,0x38E3, + 1,0x5F9A, + 1,0x5FCD, + 1,0x5FD7, + 1,0x5FF9, + 1,0x6081, + 1,0x393A, + 1,0x391C, + 1,0x6094, + 1,0x226D4, + 1,0x60C7, + 1,0x6148, + 1,0x614C, + 1,0x614E, + 1,0x614C, + 1,0x617A, + 1,0x618E, + 1,0x61B2, + 1,0x61A4, + 1,0x61AF, + 1,0x61DE, + 1,0x61F2, + 1,0x61F6, + 1,0x6210, + 1,0x621B, + 1,0x625D, + 1,0x62B1, + 1,0x62D4, + 1,0x6350, + 1,0x22B0C, + 1,0x633D, + 1,0x62FC, + 1,0x6368, + 1,0x6383, + 1,0x63E4, + 1,0x22BF1, + 1,0x6422, + 1,0x63C5, + 1,0x63A9, + 1,0x3A2E, + 1,0x6469, + 1,0x647E, + 1,0x649D, + 1,0x6477, + 1,0x3A6C, + 1,0x654F, + 1,0x656C, + 1,0x2300A, + 1,0x65E3, + 1,0x66F8, + 1,0x6649, + 1,0x3B19, + 1,0x6691, + 1,0x3B08, + 1,0x3AE4, + 1,0x5192, + 1,0x5195, + 1,0x6700, + 1,0x669C, + 1,0x80AD, + 1,0x43D9, + 1,0x6717, + 1,0x671B, + 1,0x6721, + 1,0x675E, + 1,0x6753, + 1,0x233C3, + 1,0x3B49, + 1,0x67FA, + 1,0x6785, + 1,0x6852, + 1,0x6885, + 1,0x2346D, + 1,0x688E, + 1,0x681F, + 1,0x6914, + 1,0x3B9D, + 1,0x6942, + 1,0x69A3, + 1,0x69EA, + 1,0x6AA8, + 1,0x236A3, + 1,0x6ADB, + 1,0x3C18, + 1,0x6B21, + 1,0x238A7, + 1,0x6B54, + 1,0x3C4E, + 1,0x6B72, + 1,0x6B9F, + 1,0x6BBA, + 1,0x6BBB, + 1,0x23A8D, + 1,0x21D0B, + 1,0x23AFA, + 1,0x6C4E, + 1,0x23CBC, + 1,0x6CBF, + 1,0x6CCD, + 1,0x6C67, + 1,0x6D16, + 1,0x6D3E, + 1,0x6D77, + 1,0x6D41, + 1,0x6D69, + 1,0x6D78, + 1,0x6D85, + 1,0x23D1E, + 1,0x6D34, + 1,0x6E2F, + 1,0x6E6E, + 1,0x3D33, + 1,0x6ECB, + 1,0x6EC7, + 1,0x23ED1, + 1,0x6DF9, + 1,0x6F6E, + 1,0x23F5E, + 1,0x23F8E, + 1,0x6FC6, + 1,0x7039, + 1,0x701E, + 1,0x701B, + 1,0x3D96, + 1,0x704A, + 1,0x707D, + 1,0x7077, + 1,0x70AD, + 1,0x20525, + 1,0x7145, + 1,0x24263, + 1,0x719C, + 1,0x243AB, + 1,0x7228, + 1,0x7235, + 1,0x7250, + 1,0x24608, + 1,0x7280, + 1,0x7295, + 1,0x24735, + 1,0x24814, + 1,0x737A, + 1,0x738B, + 1,0x3EAC, + 1,0x73A5, + 1,0x3EB8, + 1,0x3EB8, + 1,0x7447, + 1,0x745C, + 1,0x7471, + 1,0x7485, + 1,0x74CA, + 1,0x3F1B, + 1,0x7524, + 1,0x24C36, + 1,0x753E, + 1,0x24C92, + 1,0x7570, + 1,0x2219F, + 1,0x7610, + 1,0x24FA1, + 1,0x24FB8, + 1,0x25044, + 1,0x3FFC, + 1,0x4008, + 1,0x76F4, + 1,0x250F3, + 1,0x250F2, + 1,0x25119, + 1,0x25133, + 1,0x771E, + 1,0x771F, + 1,0x771F, + 1,0x774A, + 1,0x4039, + 1,0x778B, + 1,0x4046, + 1,0x4096, + 1,0x2541D, + 1,0x784E, + 1,0x788C, + 1,0x78CC, + 1,0x40E3, + 1,0x25626, + 1,0x7956, + 1,0x2569A, + 1,0x256C5, + 1,0x798F, + 1,0x79EB, + 1,0x412F, + 1,0x7A40, + 1,0x7A4A, + 1,0x7A4F, + 1,0x2597C, + 1,0x25AA7, + 1,0x25AA7, + 1,0x7AEE, + 1,0x4202, + 1,0x25BAB, + 1,0x7BC6, + 1,0x7BC9, + 1,0x4227, + 1,0x25C80, + 1,0x7CD2, + 1,0x42A0, + 1,0x7CE8, + 1,0x7CE3, + 1,0x7D00, + 1,0x25F86, + 1,0x7D63, + 1,0x4301, + 1,0x7DC7, + 1,0x7E02, + 1,0x7E45, + 1,0x4334, + 1,0x26228, + 1,0x26247, + 1,0x4359, + 1,0x262D9, + 1,0x7F7A, + 1,0x2633E, + 1,0x7F95, + 1,0x7FFA, + 1,0x8005, + 1,0x264DA, + 1,0x26523, + 1,0x8060, + 1,0x265A8, + 1,0x8070, + 1,0x2335F, + 1,0x43D5, + 1,0x80B2, + 1,0x8103, + 1,0x440B, + 1,0x813E, + 1,0x5AB5, + 1,0x267A7, + 1,0x267B5, + 1,0x23393, + 1,0x2339C, + 1,0x8201, + 1,0x8204, + 1,0x8F9E, + 1,0x446B, + 1,0x8291, + 1,0x828B, + 1,0x829D, + 1,0x52B3, + 1,0x82B1, + 1,0x82B3, + 1,0x82BD, + 1,0x82E6, + 1,0x26B3C, + 1,0x82E5, + 1,0x831D, + 1,0x8363, + 1,0x83AD, + 1,0x8323, + 1,0x83BD, + 1,0x83E7, + 1,0x8457, + 1,0x8353, + 1,0x83CA, + 1,0x83CC, + 1,0x83DC, + 1,0x26C36, + 1,0x26D6B, + 1,0x26CD5, + 1,0x452B, + 1,0x84F1, + 1,0x84F3, + 1,0x8516, + 1,0x273CA, + 1,0x8564, + 1,0x26F2C, + 1,0x455D, + 1,0x4561, + 1,0x26FB1, + 1,0x270D2, + 1,0x456B, + 1,0x8650, + 1,0x865C, + 1,0x8667, + 1,0x8669, + 1,0x86A9, + 1,0x8688, + 1,0x870E, + 1,0x86E2, + 1,0x8779, + 1,0x8728, + 1,0x876B, + 1,0x8786, + 1,0x45D7, + 1,0x87E1, + 1,0x8801, + 1,0x45F9, + 1,0x8860, + 1,0x8863, + 1,0x27667, + 1,0x88D7, + 1,0x88DE, + 1,0x4635, + 1,0x88FA, + 1,0x34BB, + 1,0x278AE, + 1,0x27966, + 1,0x46BE, + 1,0x46C7, + 1,0x8AA0, + 1,0x8AED, + 1,0x8B8A, + 1,0x8C55, + 1,0x27CA8, + 1,0x8CAB, + 1,0x8CC1, + 1,0x8D1B, + 1,0x8D77, + 1,0x27F2F, + 1,0x20804, + 1,0x8DCB, + 1,0x8DBC, + 1,0x8DF0, + 1,0x208DE, + 1,0x8ED4, + 1,0x8F38, + 1,0x285D2, + 1,0x285ED, + 1,0x9094, + 1,0x90F1, + 1,0x9111, + 1,0x2872E, + 1,0x911B, + 1,0x9238, + 1,0x92D7, + 1,0x92D8, + 1,0x927C, + 1,0x93F9, + 1,0x9415, + 1,0x28BFA, + 1,0x958B, + 1,0x4995, + 1,0x95B7, + 1,0x28D77, + 1,0x49E6, + 1,0x96C3, + 1,0x5DB2, + 1,0x9723, + 1,0x29145, + 1,0x2921A, + 1,0x4A6E, + 1,0x4A76, + 1,0x97E0, + 1,0x2940A, + 1,0x4AB2, + 1,0x29496, + 1,0x980B, + 1,0x980B, + 1,0x9829, + 1,0x295B6, + 1,0x98E2, + 1,0x4B33, + 1,0x9929, + 1,0x99A7, + 1,0x99C2, + 1,0x99FE, + 1,0x4BCE, + 1,0x29B30, + 1,0x9B12, + 1,0x9C40, + 1,0x9CFD, + 1,0x4CCE, + 1,0x4CED, + 1,0x9D67, + 1,0x2A0CE, + 1,0x4CF8, + 1,0x2A105, + 1,0x2A20E, + 1,0x2A291, + 1,0x9EBB, + 1,0x4D56, + 1,0x9EF9, + 1,0x9EFE, + 1,0x9F05, + 1,0x9F0F, + 1,0x9F16, + 1,0x9F3B, + 1,0x2A600, +}; + +static const short translit_page00[344] = { + 0, 2, 4, 6, -1, 9, 13, 15, /* 0xa0-0xa7 */ + 18, 20, 24, 26, 29, 33, 35, -1, /* 0xa8-0xaf */ + 39, 42, 46, 49, 52, 54, 56, 58, /* 0xb0-0xb7 */ + 60, 62, 65, 67, 70, 76, 82, 88, /* 0xb8-0xbf */ + 90, 93, 96, 99, 102, 105, 107, 110, /* 0xc0-0xc7 */ + 112, 115, 118, 121, 124, 127, 130, 133, /* 0xc8-0xcf */ + 136, 138, 141, 144, 147, 150, 153, 156, /* 0xd0-0xd7 */ + 158, 160, 163, 166, 169, 172, 175, 178, /* 0xd8-0xdf */ + 181, 184, 187, 190, 193, 196, 198, 201, /* 0xe0-0xe7 */ + 203, 206, 209, 212, 215, 218, 221, 224, /* 0xe8-0xef */ + 227, 229, 232, 235, 238, 241, 244, 247, /* 0xf0-0xf7 */ + 249, 251, 254, 257, 260, 263, 266, 269, /* 0xf8-0xff */ + /* 0x0100 */ + 272, 274, 276, 278, 280, 282, 284, 287, /* 0x00-0x07 */ + 290, 293, 296, 298, 300, 302, 304, 306, /* 0x08-0x0f */ + 308, 310, 312, 314, 316, 318, 320, 322, /* 0x10-0x17 */ + 324, 326, 328, 330, 332, 335, 338, 340, /* 0x18-0x1f */ + 342, 344, 346, 348, 350, 353, 356, 358, /* 0x20-0x27 */ + 360, 363, 366, 368, 370, 372, 374, 376, /* 0x28-0x2f */ + 378, 380, 382, 385, 388, 391, 394, 396, /* 0x30-0x37 */ + -1, 398, 400, 402, 404, 406, 408, 410, /* 0x38-0x3f */ + 412, 414, 416, 418, 421, 424, 426, 428, /* 0x40-0x47 */ + 430, 432, -1, -1, 435, 437, 439, 441, /* 0x48-0x4f */ + 443, 446, 449, 452, 455, 458, 461, 463, /* 0x50-0x57 */ + 465, 467, 469, 472, 475, 478, 481, 483, /* 0x58-0x5f */ + 485, 487, 489, 491, 493, 495, 497, 499, /* 0x60-0x67 */ + 501, 504, 507, 509, 511, 513, 515, 517, /* 0x68-0x6f */ + 519, 522, 525, 527, 529, 532, 535, 538, /* 0x70-0x77 */ + 541, 544, 547, 550, 552, 554, 556, 558, /* 0x78-0x7f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x80-0x87 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x88-0x8f */ + -1, -1, 560, -1, -1, -1, -1, -1, /* 0x90-0x97 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x98-0x9f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xa0-0xa7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xa8-0xaf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xb0-0xb7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xb8-0xbf */ + -1, -1, -1, -1, 562, 565, 568, 571, /* 0xc0-0xc7 */ + 574, 577, 580, 583, 586, -1, -1, -1, /* 0xc8-0xcf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xd0-0xd7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xd8-0xdf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xe0-0xe7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xe8-0xef */ + -1, 589, 592, 595, -1, -1, -1, -1, /* 0xf0-0xf7 */ +}; +static const short translit_page02[8] = { + 598, 600, 602, 604, -1, -1, -1, -1, /* 0x18-0x1f */ +}; +static const short translit_page02_1[40] = { + -1, 606, 608, 610, 612, 614, -1, -1, /* 0xb8-0xbf */ + -1, -1, -1, -1, -1, -1, 616, -1, /* 0xc0-0xc7 */ + 618, 620, 622, 624, -1, 626, -1, -1, /* 0xc8-0xcf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xd0-0xd7 */ + -1, -1, -1, -1, 628, 630, -1, -1, /* 0xd8-0xdf */ +}; +static const short translit_page03[48] = { + 632, 634, 636, -1, -1, 638, 640, -1, /* 0xd0-0xd7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xd8-0xdf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xe0-0xe7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xe8-0xef */ + 642, 644, 646, -1, 648, 650, -1, -1, /* 0xf0-0xf7 */ + -1, 652, -1, -1, -1, -1, -1, -1, /* 0xf8-0xff */ +}; +static const short translit_page05[8] = { + 657, 660, 663, -1, -1, -1, -1, -1, /* 0xf0-0xf7 */ +}; +static const short translit_page06[16] = { + -1, -1, -1, -1, -1, 666, 669, 672, /* 0x70-0x77 */ + 675, -1, -1, -1, -1, -1, -1, -1, /* 0x78-0x7f */ +}; +static const short translit_page0e[48] = { + -1, -1, -1, 681, -1, -1, -1, -1, /* 0xb0-0xb7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xb8-0xbf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xc0-0xc7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xc8-0xcf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xd0-0xd7 */ + -1, -1, -1, -1, 684, 687, -1, -1, /* 0xd8-0xdf */ +}; +static const short translit_page0f[16] = { + -1, -1, -1, -1, -1, -1, -1, 690, /* 0x70-0x77 */ + -1, 693, -1, -1, -1, -1, -1, -1, /* 0x78-0x7f */ +}; +static const short translit_page1e[160] = { + -1, -1, 696, 698, -1, -1, -1, -1, /* 0x00-0x07 */ + -1, -1, 700, 702, -1, -1, -1, -1, /* 0x08-0x0f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x10-0x17 */ + -1, -1, -1, -1, -1, -1, 704, 706, /* 0x18-0x1f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x20-0x27 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x28-0x2f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x30-0x37 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x38-0x3f */ + 708, 710, -1, -1, -1, -1, -1, -1, /* 0x40-0x47 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x48-0x4f */ + -1, -1, -1, -1, -1, -1, 712, 714, /* 0x50-0x57 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x58-0x5f */ + 716, 718, -1, -1, -1, -1, -1, -1, /* 0x60-0x67 */ + -1, -1, 720, 722, -1, -1, -1, -1, /* 0x68-0x6f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x70-0x77 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x78-0x7f */ + 724, 727, 730, 733, 736, 739, -1, -1, /* 0x80-0x87 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x88-0x8f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x90-0x97 */ + -1, -1, 742, -1, -1, -1, -1, -1, /* 0x98-0x9f */ +}; +static const short translit_page1e_2[8] = { + -1, -1, 745, 748, -1, -1, -1, -1, /* 0xf0-0xf7 */ +}; +static const short translit_page20[88] = { + -1, -1, 751, 753, 755, 757, 759, -1, /* 0x00-0x07 */ + 761, 763, 765, -1, -1, -1, -1, -1, /* 0x08-0x0f */ + 767, 769, 771, 773, 775, 777, -1, -1, /* 0x10-0x17 */ + 779, 781, 783, 785, 787, 789, 791, 793, /* 0x18-0x1f */ + 795, -1, 797, -1, 799, 801, 804, -1, /* 0x20-0x27 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x28-0x2f */ + 808, -1, 813, 815, 818, -1, 822, 825, /* 0x30-0x37 */ + -1, 829, 831, -1, 833, -1, -1, -1, /* 0x38-0x3f */ + -1, -1, -1, -1, 836, -1, -1, 838, /* 0x40-0x47 */ + 841, 844, -1, -1, -1, -1, -1, -1, /* 0x48-0x4f */ + -1, -1, -1, -1, -1, -1, -1, 847, /* 0x50-0x57 */ +}; +static const short translit_page20_3[8] = { + 852, -1, -1, 855, 860, -1, -1, -1, /* 0xa8-0xaf */ +}; +static const short translit_page21[216] = { + 864, 868, 872, 874, -1, 877, 881, 885, /* 0x00-0x07 */ + -1, 887, 890, 892, 894, 896, 898, 900, /* 0x08-0x0f */ + 902, 904, 906, 908, -1, 910, 912, -1, /* 0x10-0x17 */ + -1, 915, 917, 919, 921, 923, -1, -1, /* 0x18-0x1f */ + -1, 925, 929, -1, 932, -1, 934, -1, /* 0x20-0x27 */ + 938, -1, -1, -1, 940, 942, 944, 946, /* 0x28-0x2f */ + 948, 950, -1, 952, 954, 956, 958, 960, /* 0x30-0x37 */ + 962, 964, -1, 966, -1, 970, 972, 974, /* 0x38-0x3f */ + 976, -1, -1, -1, -1, 978, 980, 982, /* 0x40-0x47 */ + 984, 986, -1, -1, -1, -1, -1, -1, /* 0x48-0x4f */ + -1, -1, -1, 988, 994, 1000, 1006, 1012, /* 0x50-0x57 */ + 1018, 1024, 1030, 1036, 1042, 1048, 1054, 1060, /* 0x58-0x5f */ + 1064, 1066, 1069, 1073, 1076, 1078, 1081, 1085, /* 0x60-0x67 */ + 1090, 1093, 1095, 1098, 1102, 1104, 1106, 1108, /* 0x68-0x6f */ + 1110, 1112, 1115, 1119, 1122, 1124, 1127, 1131, /* 0x70-0x77 */ + 1136, 1139, 1141, 1144, 1148, 1150, 1152, 1154, /* 0x78-0x7f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x80-0x87 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x88-0x8f */ + 1156, 1159, 1161, 1164, 1166, -1, -1, -1, /* 0x90-0x97 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x98-0x9f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xa0-0xa7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xa8-0xaf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xb0-0xb7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xb8-0xbf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xc0-0xc7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xc8-0xcf */ + 1170, -1, 1173, -1, 1176, -1, -1, -1, /* 0xd0-0xd7 */ +}; +static const short translit_page22[96] = { + -1, -1, 1180, -1, -1, 1182, 1184, 1186, /* 0x10-0x17 */ + -1, 1188, -1, -1, -1, -1, -1, -1, /* 0x18-0x1f */ + -1, -1, -1, 1190, -1, -1, -1, -1, /* 0x20-0x27 */ + -1, -1, -1, -1, 1192, 1195, -1, 1199, /* 0x28-0x2f */ + 1202, -1, -1, -1, -1, -1, 1206, -1, /* 0x30-0x37 */ + -1, -1, -1, -1, 1208, -1, -1, -1, /* 0x38-0x3f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x40-0x47 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x48-0x4f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x50-0x57 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x58-0x5f */ + 1210, -1, -1, -1, 1213, 1216, -1, -1, /* 0x60-0x67 */ + -1, -1, 1219, 1222, -1, -1, -1, -1, /* 0x68-0x6f */ +}; +static const short translit_page22_4[48] = { + -1, -1, -1, -1, -1, 1225, -1, -1, /* 0xc0-0xc7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xc8-0xcf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xd0-0xd7 */ + 1227, 1231, -1, -1, -1, -1, -1, -1, /* 0xd8-0xdf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xe0-0xe7 */ + -1, -1, -1, -1, -1, -1, -1, 1235, /* 0xe8-0xef */ +}; +static const short translit_page24[240] = { + 1239, 1245, 1251, 1257, 1263, 1269, 1275, 1281, /* 0x00-0x07 */ + 1287, 1292, 1297, 1302, 1307, 1312, 1317, 1322, /* 0x08-0x0f */ + 1327, 1333, 1339, 1345, 1351, 1357, 1363, 1369, /* 0x10-0x17 */ + 1375, 1381, 1386, 1392, 1398, 1403, 1408, 1413, /* 0x18-0x1f */ + 1418, 1423, -1, -1, 1429, -1, -1, -1, /* 0x20-0x27 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x28-0x2f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x30-0x37 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x38-0x3f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x40-0x47 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x48-0x4f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x50-0x57 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x58-0x5f */ + 1434, 1438, 1442, 1446, 1450, 1454, 1458, 1462, /* 0x60-0x67 */ + 1466, 1470, 1475, 1480, 1485, 1490, 1495, 1500, /* 0x68-0x6f */ + 1505, 1510, 1515, 1520, 1525, 1529, 1533, 1537, /* 0x70-0x77 */ + 1541, 1545, 1549, 1553, 1557, 1561, 1566, 1571, /* 0x78-0x7f */ + 1576, 1581, 1586, 1591, 1596, 1601, 1606, 1611, /* 0x80-0x87 */ + 1616, 1619, 1622, 1625, 1628, 1631, 1634, 1637, /* 0x88-0x8f */ + 1640, 1643, 1647, 1651, 1655, 1659, 1663, 1667, /* 0x90-0x97 */ + 1671, 1675, 1679, 1683, 1687, 1691, 1695, 1699, /* 0x98-0x9f */ + 1703, 1707, 1711, 1715, 1719, 1723, 1727, 1731, /* 0xa0-0xa7 */ + 1735, 1739, 1743, 1747, 1751, 1755, 1759, 1763, /* 0xa8-0xaf */ + 1767, 1771, 1775, 1779, 1783, 1787, 1791, 1795, /* 0xb0-0xb7 */ + 1799, 1803, 1807, 1811, 1815, 1819, 1823, 1827, /* 0xb8-0xbf */ + 1831, 1835, 1839, 1843, 1847, 1851, 1855, 1859, /* 0xc0-0xc7 */ + 1863, 1867, 1871, 1875, 1879, 1883, 1887, 1891, /* 0xc8-0xcf */ + 1895, 1899, 1903, 1907, 1911, 1915, 1919, 1923, /* 0xd0-0xd7 */ + 1927, 1931, 1935, 1939, 1943, 1947, 1951, 1955, /* 0xd8-0xdf */ + 1959, 1963, 1967, 1971, 1975, 1979, 1983, 1987, /* 0xe0-0xe7 */ + 1991, 1995, 1999, -1, -1, -1, -1, -1, /* 0xe8-0xef */ +}; +static const short translit_page25[64] = { + 2003, -1, 2005, -1, -1, -1, -1, -1, /* 0x00-0x07 */ + -1, -1, -1, -1, 2007, -1, -1, -1, /* 0x08-0x0f */ + 2009, -1, -1, -1, 2011, -1, -1, -1, /* 0x10-0x17 */ + 2013, -1, -1, -1, 2015, -1, -1, -1, /* 0x18-0x1f */ + -1, -1, -1, -1, 2017, -1, -1, -1, /* 0x20-0x27 */ + -1, -1, -1, -1, 2019, -1, -1, -1, /* 0x28-0x2f */ + -1, -1, -1, -1, 2021, -1, -1, -1, /* 0x30-0x37 */ + -1, -1, -1, -1, 2023, -1, -1, -1, /* 0x38-0x3f */ +}; +static const short translit_page2a[8] = { + -1, -1, -1, -1, 2032, 2036, 2039, -1, /* 0x70-0x77 */ +}; +static const short translit_page2f[216] = { + 2047, 2049, 2051, 2053, 2055, 2057, 2059, 2061, /* 0x00-0x07 */ + 2063, 2065, 2067, 2069, 2071, 2073, 2075, 2077, /* 0x08-0x0f */ + 2079, 2081, 2083, 2085, 2087, 2089, 2091, 2093, /* 0x10-0x17 */ + 2095, 2097, 2099, 2101, 2103, 2105, 2107, 2109, /* 0x18-0x1f */ + 2111, 2113, 2115, 2117, 2119, 2121, 2123, 2125, /* 0x20-0x27 */ + 2127, 2129, 2131, 2133, 2135, 2137, 2139, 2141, /* 0x28-0x2f */ + 2143, 2145, 2147, 2149, 2151, 2153, 2155, 2157, /* 0x30-0x37 */ + 2159, 2161, 2163, 2165, 2167, 2169, 2171, 2173, /* 0x38-0x3f */ + 2175, 2177, 2179, 2181, 2183, 2185, 2187, 2189, /* 0x40-0x47 */ + 2191, 2193, 2195, 2197, 2199, 2201, 2203, 2205, /* 0x48-0x4f */ + 2207, 2209, 2211, 2213, 2215, 2217, 2219, 2221, /* 0x50-0x57 */ + 2223, 2225, 2227, 2229, 2231, 2233, 2235, 2237, /* 0x58-0x5f */ + 2239, 2241, 2243, 2245, 2247, 2249, 2251, 2253, /* 0x60-0x67 */ + 2255, 2257, 2259, 2261, 2263, 2265, 2267, 2269, /* 0x68-0x6f */ + 2271, 2273, 2275, 2277, 2279, 2281, 2283, 2285, /* 0x70-0x77 */ + 2287, 2289, 2291, 2293, 2295, 2297, 2299, 2301, /* 0x78-0x7f */ + 2303, 2305, 2307, 2309, 2311, 2313, 2315, 2317, /* 0x80-0x87 */ + 2319, 2321, 2323, 2325, 2327, 2329, 2331, 2333, /* 0x88-0x8f */ + 2335, 2337, 2339, 2341, 2343, 2345, 2347, 2349, /* 0x90-0x97 */ + 2351, 2353, 2355, 2357, 2359, 2361, 2363, 2365, /* 0x98-0x9f */ + 2367, 2369, 2371, 2373, 2375, 2377, 2379, 2381, /* 0xa0-0xa7 */ + 2383, 2385, 2387, 2389, 2391, 2393, 2395, 2397, /* 0xa8-0xaf */ + 2399, 2401, 2403, 2405, 2407, 2409, 2411, 2413, /* 0xb0-0xb7 */ + 2415, 2417, 2419, 2421, 2423, 2425, 2427, 2429, /* 0xb8-0xbf */ + 2431, 2433, 2435, 2437, 2439, 2441, 2443, 2445, /* 0xc0-0xc7 */ + 2447, 2449, 2451, 2453, 2455, 2457, 2459, 2461, /* 0xc8-0xcf */ + 2463, 2465, 2467, 2469, 2471, 2473, -1, -1, /* 0xd0-0xd7 */ +}; +static const short translit_page30[248] = { + 2475, -1, -1, -1, -1, -1, -1, -1, /* 0x00-0x07 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x08-0x0f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x10-0x17 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x18-0x1f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x20-0x27 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x28-0x2f */ + -1, -1, -1, -1, -1, -1, 2477, -1, /* 0x30-0x37 */ + 2479, 2481, 2483, -1, -1, -1, -1, -1, /* 0x38-0x3f */ + -1, 2485, -1, 2487, -1, 2489, -1, 2491, /* 0x40-0x47 */ + -1, 2493, -1, -1, -1, -1, -1, -1, /* 0x48-0x4f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x50-0x57 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x58-0x5f */ + -1, -1, -1, 2495, -1, -1, -1, -1, /* 0x60-0x67 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x68-0x6f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x70-0x77 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x78-0x7f */ + -1, -1, -1, 2497, -1, 2499, -1, 2501, /* 0x80-0x87 */ + -1, -1, -1, -1, -1, -1, 2503, -1, /* 0x88-0x8f */ + -1, -1, -1, -1, -1, 2505, 2507, -1, /* 0x90-0x97 */ + -1, -1, -1, 2509, 2512, -1, -1, -1, /* 0x98-0x9f */ + 2515, 2517, -1, 2519, -1, 2521, -1, 2523, /* 0xa0-0xa7 */ + -1, 2525, -1, -1, -1, -1, -1, -1, /* 0xa8-0xaf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xb0-0xb7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xb8-0xbf */ + -1, -1, -1, 2527, -1, -1, -1, -1, /* 0xc0-0xc7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xc8-0xcf */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xd0-0xd7 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0xd8-0xdf */ + -1, -1, -1, 2529, -1, 2531, -1, 2533, /* 0xe0-0xe7 */ + -1, -1, -1, -1, -1, -1, 2535, -1, /* 0xe8-0xef */ + -1, -1, -1, -1, -1, 2537, 2539, -1, /* 0xf0-0xf7 */ +}; +static const short translit_page31[96] = { + -1, 2541, 2543, 2545, 2547, 2549, 2551, 2553, /* 0x30-0x37 */ + 2555, 2557, 2559, 2561, 2563, 2565, 2567, 2569, /* 0x38-0x3f */ + 2571, 2573, 2575, 2577, 2579, 2581, 2583, 2585, /* 0x40-0x47 */ + 2587, 2589, 2591, 2593, 2595, 2597, 2599, 2601, /* 0x48-0x4f */ + 2603, 2605, 2607, 2609, 2611, 2613, 2615, 2617, /* 0x50-0x57 */ + 2619, 2621, 2623, 2625, 2627, 2629, 2631, 2633, /* 0x58-0x5f */ + 2635, 2637, 2639, 2641, 2643, 2645, 2647, 2649, /* 0x60-0x67 */ + 2651, 2653, 2655, 2657, 2659, 2661, 2663, 2665, /* 0x68-0x6f */ + 2667, 2669, 2671, 2673, 2675, 2677, 2679, 2681, /* 0x70-0x77 */ + 2683, 2685, 2687, 2689, 2691, 2693, 2695, 2697, /* 0x78-0x7f */ + 2699, 2701, 2703, 2705, 2707, 2709, 2711, 2713, /* 0x80-0x87 */ + 2715, 2717, 2719, 2721, 2723, 2725, 2727, -1, /* 0x88-0x8f */ +}; +static const short translit_page31_5[528] = { + 2729, 2731, 2733, 2735, 2737, 2739, 2741, 2743, /* 0xf0-0xf7 */ + 2745, 2747, 2749, 2751, 2753, 2755, 2757, 2759, /* 0xf8-0xff */ + /* 0x3200 */ + 2761, 2765, 2769, 2773, 2777, 2781, 2785, 2789, /* 0x00-0x07 */ + 2793, 2797, 2801, 2805, 2809, 2813, 2817, 2822, /* 0x08-0x0f */ + 2827, 2832, 2837, 2842, 2847, 2852, 2857, 2862, /* 0x10-0x17 */ + 2867, 2872, 2877, 2882, 2887, 2892, 2900, -1, /* 0x18-0x1f */ + 2907, 2911, 2915, 2919, 2923, 2927, 2931, 2935, /* 0x20-0x27 */ + 2939, 2943, 2947, 2951, 2955, 2959, 2963, 2967, /* 0x28-0x2f */ + 2971, 2975, 2979, 2983, 2987, 2991, 2995, 2999, /* 0x30-0x37 */ + 3003, 3007, 3011, 3015, 3019, 3023, 3027, 3031, /* 0x38-0x3f */ + 3035, 3039, 3043, 3047, -1, -1, -1, -1, /* 0x40-0x47 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x48-0x4f */ + 3051, 3055, 3060, 3065, 3070, 3075, 3080, 3085, /* 0x50-0x57 */ + 3090, 3095, 3100, 3105, 3110, 3115, 3120, 3125, /* 0x58-0x5f */ + 3130, 3134, 3138, 3142, 3146, 3150, 3154, 3158, /* 0x60-0x67 */ + 3162, 3166, 3170, 3174, 3178, 3182, 3186, 3191, /* 0x68-0x6f */ + 3196, 3201, 3206, 3211, 3216, 3221, 3226, 3231, /* 0x70-0x77 */ + 3236, 3241, 3246, 3251, 3256, 3264, -1, -1, /* 0x78-0x7f */ + 3271, 3275, 3279, 3283, 3287, 3291, 3295, 3299, /* 0x80-0x87 */ + 3303, 3307, 3311, 3315, 3319, 3323, 3327, 3331, /* 0x88-0x8f */ + 3335, 3339, 3343, 3347, 3351, 3355, 3359, 3363, /* 0x90-0x97 */ + 3367, 3371, 3375, 3379, 3383, 3387, 3391, 3395, /* 0x98-0x9f */ + 3399, 3403, 3407, 3411, 3415, 3419, 3423, 3427, /* 0xa0-0xa7 */ + 3431, 3435, 3439, 3443, 3447, 3451, 3455, 3459, /* 0xa8-0xaf */ + 3463, 3467, 3472, 3477, 3482, 3487, 3492, 3497, /* 0xb0-0xb7 */ + 3502, 3507, 3512, 3517, 3522, 3527, 3532, 3537, /* 0xb8-0xbf */ + 3542, 3545, 3548, 3551, 3554, 3557, 3560, 3563, /* 0xc0-0xc7 */ + 3566, 3569, 3573, 3577, 3581, 3584, 3588, 3591, /* 0xc8-0xcf */ + 3595, 3599, 3603, 3607, 3611, 3615, 3619, 3623, /* 0xd0-0xd7 */ + 3627, 3631, 3635, 3639, 3643, 3647, 3651, 3655, /* 0xd8-0xdf */ + 3659, 3663, 3667, 3671, 3675, 3679, 3683, 3687, /* 0xe0-0xe7 */ + 3691, 3695, 3699, 3703, 3707, 3711, 3715, 3719, /* 0xe8-0xef */ + 3723, 3727, 3731, 3735, 3739, 3743, 3747, 3751, /* 0xf0-0xf7 */ + 3755, 3759, 3763, 3767, 3771, 3775, 3779, -1, /* 0xf8-0xff */ + /* 0x3300 */ + 3783, 3788, 3793, 3798, 3802, 3807, 3811, 3815, /* 0x00-0x07 */ + 3821, 3826, 3830, 3834, 3838, 3843, 3848, 3852, /* 0x08-0x0f */ + 3856, 3859, 3863, 3868, 3873, 3876, 3882, 3889, /* 0x10-0x17 */ + 3895, 3899, 3905, 3911, 3916, 3920, 3924, 3928, /* 0x18-0x1f */ + 3933, 3939, 3944, 3948, 3952, 3956, 3959, 3962, /* 0x20-0x27 */ + 3965, 3968, 3972, 3976, 3982, 3986, 3991, 3997, /* 0x28-0x2f */ + 4001, 4004, 4007, 4013, 4018, 4024, 4028, 4034, /* 0x30-0x37 */ + 4037, 4041, 4045, 4049, 4053, 4057, 4062, 4066, /* 0x38-0x3f */ + 4069, 4073, 4077, 4081, 4086, 4090, 4094, 4098, /* 0x40-0x47 */ + 4104, 4109, 4112, 4118, 4121, 4126, 4131, 4135, /* 0x48-0x4f */ + 4139, 4143, 4148, 4151, 4155, 4160, 4163, 4169, /* 0x50-0x57 */ + 4173, 4176, 4179, 4182, 4185, 4188, 4191, 4194, /* 0x58-0x5f */ + 4197, 4200, 4203, 4207, 4211, 4215, 4219, 4223, /* 0x60-0x67 */ + 4227, 4231, 4235, 4239, 4243, 4247, 4251, 4255, /* 0x68-0x6f */ + 4259, 4263, 4267, 4270, 4273, 4277, 4280, 4283, /* 0x70-0x77 */ + 4286, 4291, 4296, 4299, 4302, 4305, 4308, 4311, /* 0x78-0x7f */ + 4316, 4319, 4322, 4325, 4328, 4331, 4334, 4337, /* 0x80-0x87 */ + 4340, 4344, 4349, 4352, 4355, 4358, 4361, 4364, /* 0x88-0x8f */ + 4367, 4370, 4374, 4378, 4382, 4386, 4389, 4392, /* 0x90-0x97 */ + 4395, 4398, 4401, 4404, 4407, 4410, 4413, 4416, /* 0x98-0x9f */ + 4421, 4426, 4430, 4435, 4440, 4445, 4449, 4454, /* 0xa0-0xa7 */ + 4458, 4464, 4467, 4471, 4475, 4479, 4483, 4489, /* 0xa8-0xaf */ + 4497, 4500, 4503, 4506, 4509, 4512, 4515, 4518, /* 0xb0-0xb7 */ + 4521, 4524, 4527, 4530, 4533, 4536, 4539, 4542, /* 0xb8-0xbf */ + 4545, 4548, 4551, 4556, 4559, 4562, 4565, 4570, /* 0xc0-0xc7 */ + 4574, 4577, 4580, 4583, 4586, 4589, 4592, 4595, /* 0xc8-0xcf */ + 4598, 4601, 4604, 4608, 4611, 4614, 4618, 4622, /* 0xd0-0xd7 */ + 4625, 4630, 4634, 4637, 4640, 4643, 4646, 4650, /* 0xd8-0xdf */ + 4658, 4661, 4664, 4667, 4670, 4673, 4676, 4679, /* 0xe0-0xe7 */ + 4682, 4685, 4689, 4693, 4697, 4701, 4705, 4709, /* 0xe8-0xef */ + 4713, 4717, 4721, 4725, 4729, 4733, 4737, 4741, /* 0xf0-0xf7 */ + 4745, 4749, 4753, 4757, 4761, 4765, 4769, 4654, /* 0xf8-0xff */ +}; +static const short translit_pagef9[368] = { + 4773, 4775, 4777, 4779, 4781, 4783, 4785, 4787, /* 0x00-0x07 */ + 4789, 4791, 4793, 4795, 4797, 4799, 4801, 4803, /* 0x08-0x0f */ + 4805, 4807, 4809, 4811, 4813, 4815, 4817, 4819, /* 0x10-0x17 */ + 4821, 4823, 4825, 4827, 4829, 4831, 4833, 4835, /* 0x18-0x1f */ + 4837, 4839, 4841, 4843, 4845, 4847, 4849, 4851, /* 0x20-0x27 */ + 4853, 4855, 4857, 4859, 4861, 4863, 4865, 4867, /* 0x28-0x2f */ + 4869, 4871, 4873, 4875, 4877, 4879, 4881, 4883, /* 0x30-0x37 */ + 4885, 4887, 4889, 4891, 4893, 4895, 4897, 4899, /* 0x38-0x3f */ + 4901, 4903, 4905, 4907, 4909, 4911, 4913, 4915, /* 0x40-0x47 */ + 4917, 4919, 4921, 4923, 4925, 4927, 4929, 4931, /* 0x48-0x4f */ + 4933, 4935, 4937, 4939, 4941, 4943, 4945, 4947, /* 0x50-0x57 */ + 4949, 4951, 4953, 4955, 4957, 4959, 4961, 4963, /* 0x58-0x5f */ + 4965, 4967, 4969, 4971, 4973, 4975, 4977, 4979, /* 0x60-0x67 */ + 4981, 4983, 4985, 4987, 4989, 4991, 4993, 4995, /* 0x68-0x6f */ + 4997, 4999, 5001, 5003, 5005, 5007, 5009, 5011, /* 0x70-0x77 */ + 5013, 5015, 5017, 5019, 5021, 5023, 5025, 5027, /* 0x78-0x7f */ + 5029, 5031, 5033, 5035, 5037, 5039, 5041, 5043, /* 0x80-0x87 */ + 5045, 5047, 5049, 5051, 5053, 5055, 5057, 5059, /* 0x88-0x8f */ + 5061, 5063, 5065, 5067, 5069, 5071, 5073, 5075, /* 0x90-0x97 */ + 5077, 5079, 5081, 5083, 5085, 5087, 5089, 5091, /* 0x98-0x9f */ + 5093, 5095, 5097, 5099, 5101, 5103, 5105, 5107, /* 0xa0-0xa7 */ + 5109, 5111, 5113, 5115, 5117, 5119, 5121, 5123, /* 0xa8-0xaf */ + 5125, 5127, 5129, 5131, 5133, 5135, 5137, 5139, /* 0xb0-0xb7 */ + 5141, 5143, 5145, 5147, 5149, 5151, 5153, 5155, /* 0xb8-0xbf */ + 5157, 5159, 5161, 5163, 5165, 5167, 5169, 5171, /* 0xc0-0xc7 */ + 5173, 5175, 5177, 5179, 5181, 5183, 5185, 5187, /* 0xc8-0xcf */ + 5189, 5191, 5193, 5195, 5197, 5199, 5201, 5203, /* 0xd0-0xd7 */ + 5205, 5207, 5209, 5211, 5213, 5215, 5217, 5219, /* 0xd8-0xdf */ + 5221, 5223, 5225, 5227, 5229, 5231, 5233, 5235, /* 0xe0-0xe7 */ + 5237, 5239, 5241, 5243, 5245, 5247, 5249, 5251, /* 0xe8-0xef */ + 5253, 5255, 5257, 5259, 5261, 5263, 5265, 5267, /* 0xf0-0xf7 */ + 5269, 5271, 5273, 5275, 5277, 5279, 5281, 5283, /* 0xf8-0xff */ + /* 0xfa00 */ + 5285, 5287, 5289, 5291, 5293, 5295, 5297, 5299, /* 0x00-0x07 */ + 5301, 5303, 5305, 5307, 5309, 5311, -1, -1, /* 0x08-0x0f */ + 5313, -1, 5315, -1, -1, 5317, 5319, 5321, /* 0x10-0x17 */ + 5323, 5325, 5327, 5329, 5331, 5333, 5335, -1, /* 0x18-0x1f */ + 5337, -1, 5339, -1, -1, 5341, 5343, -1, /* 0x20-0x27 */ + -1, -1, 5345, 5347, 5349, 5351, -1, -1, /* 0x28-0x2f */ + 5353, 5355, 5357, 5359, 5361, 5363, 5365, 5367, /* 0x30-0x37 */ + 5369, 5371, 5373, 5375, 5377, 5379, 5381, 5383, /* 0x38-0x3f */ + 5385, 5387, 5389, 5391, 5393, 5395, 5397, 5399, /* 0x40-0x47 */ + 5401, 5403, 5405, 5407, 5409, 5411, 5413, 5415, /* 0x48-0x4f */ + 5417, 5419, 5421, 5423, 5425, 5427, 5429, 5431, /* 0x50-0x57 */ + 5433, 5435, 5437, 5439, 5441, 5443, 5445, 5447, /* 0x58-0x5f */ + 5449, 5451, 5453, 5455, 5457, 5459, 5461, 5463, /* 0x60-0x67 */ + 5465, 5467, 5469, -1, -1, -1, -1, -1, /* 0x68-0x6f */ +}; +static const short translit_pagefb[80] = { + 5471, 5474, 5477, 5480, 5484, 5488, 5491, -1, /* 0x00-0x07 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x08-0x0f */ + -1, -1, -1, 5494, 5497, 5500, 5503, 5506, /* 0x10-0x17 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x18-0x1f */ + 5509, 5511, 5513, 5515, 5517, 5519, 5521, 5523, /* 0x20-0x27 */ + 5525, 5527, -1, -1, -1, -1, -1, -1, /* 0x28-0x2f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x30-0x37 */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x38-0x3f */ + -1, -1, -1, -1, -1, -1, -1, -1, /* 0x40-0x47 */ + -1, -1, -1, -1, -1, -1, -1, 5529, /* 0x48-0x4f */ +}; +static const short translit_pagefe[40] = { + -1, 5532, 5534, 5536, 5538, 5540, 5542, 5544, /* 0x48-0x4f */ + 5546, 5548, 5550, -1, 5552, 5554, 5556, 5558, /* 0x50-0x57 */ + 5560, 5562, 5564, 5566, 5568, 5570, 5572, 5574, /* 0x58-0x5f */ + 5576, 5578, 5580, 5582, 5584, 5586, 5588, -1, /* 0x60-0x67 */ + 5590, 5592, 5594, 5596, -1, -1, -1, -1, /* 0x68-0x6f */ +}; +static const short translit_pageff[240] = { + -1, 5598, 5600, 5602, 5604, 5606, 5608, 5610, /* 0x00-0x07 */ + 5612, 5614, 5616, 5618, 5620, 5622, 5624, 5626, /* 0x08-0x0f */ + 5628, 5630, 5632, 5634, 5636, 5638, 5640, 5642, /* 0x10-0x17 */ + 5644, 5646, 5648, 5650, 5652, 5654, 5656, 5658, /* 0x18-0x1f */ + 5660, 5662, 5664, 5666, 5668, 5670, 5672, 5674, /* 0x20-0x27 */ + 5676, 5678, 5680, 5682, 5684, 5686, 5688, 5690, /* 0x28-0x2f */ + 5692, 5694, 5696, 5698, 5700, 5702, 5704, 5706, /* 0x30-0x37 */ + 5708, 5710, 5712, 5714, 5716, 5718, 5720, 5722, /* 0x38-0x3f */ + 5724, 5726, 5728, 5730, 5732, 5734, 5736, 5738, /* 0x40-0x47 */ + 5740, 5742, 5744, 5746, 5748, 5750, 5752, 5754, /* 0x48-0x4f */ + 5756, 5758, 5760, 5762, 5764, 5766, 5768, 5770, /* 0x50-0x57 */ + 5772, 5774, 5776, 5778, 5780, 5782, 5784, 5786, /* 0x58-0x5f */ + 5788, 5790, 5792, 5794, 5796, 5798, 5800, 5802, /* 0x60-0x67 */ + 5804, 5806, 5808, 5810, 5812, 5814, 5816, 5818, /* 0x68-0x6f */ + 5820, 5822, 5824, 5826, 5828, 5830, 5832, 5834, /* 0x70-0x77 */ + 5836, 5838, 5840, 5842, 5844, 5846, 5848, 5850, /* 0x78-0x7f */ + 5852, 5854, 5856, 5858, 5860, 5862, 5864, 5866, /* 0x80-0x87 */ + 5868, 5870, 5872, 5874, 5876, 5878, 5880, 5882, /* 0x88-0x8f */ + 5884, 5886, 5888, 5890, 5892, 5894, 5896, 5898, /* 0x90-0x97 */ + 5900, 5902, 5904, 5906, 5908, 5910, 5912, 5914, /* 0x98-0x9f */ + 5916, 5918, 5920, 5922, 5924, 5926, 5928, 5930, /* 0xa0-0xa7 */ + 5932, 5934, 5936, 5938, 5940, 5942, 5944, 5946, /* 0xa8-0xaf */ + 5948, 5950, 5952, 5954, 5956, 5958, 5960, 5962, /* 0xb0-0xb7 */ + 5964, 5966, 5968, 5970, 5972, 5974, 5976, -1, /* 0xb8-0xbf */ + -1, -1, 5978, 5980, 5982, 5984, 5986, 5988, /* 0xc0-0xc7 */ + -1, -1, 5990, 5992, 5994, 5996, 5998, 6000, /* 0xc8-0xcf */ + -1, -1, 6002, 6004, 6006, 6008, 6010, 6012, /* 0xd0-0xd7 */ + -1, -1, 6014, 6016, 6018, -1, -1, -1, /* 0xd8-0xdf */ + 6020, 6022, 6024, 6026, 6028, 6030, 6032, -1, /* 0xe0-0xe7 */ + 6034, 6036, 6038, 6040, 6042, 6044, 6046, -1, /* 0xe8-0xef */ +}; +static const short translit_page1d4[1024] = { + 6048, 6050, 6052, 6054, 6056, 6058, 6060, 6062, /* 0x00-0x07 */ + 6064, 6066, 6068, 6070, 6072, 6074, 6076, 6078, /* 0x08-0x0f */ + 6080, 6082, 6084, 6086, 6088, 6090, 6092, 6094, /* 0x10-0x17 */ + 6096, 6098, 6100, 6102, 6104, 6106, 6108, 6110, /* 0x18-0x1f */ + 6112, 6114, 6116, 6118, 6120, 6122, 6124, 6126, /* 0x20-0x27 */ + 6128, 6130, 6132, 6134, 6136, 6138, 6140, 6142, /* 0x28-0x2f */ + 6144, 6146, 6148, 6150, 6152, 6154, 6156, 6158, /* 0x30-0x37 */ + 6160, 6162, 6164, 6166, 6168, 6170, 6172, 6174, /* 0x38-0x3f */ + 6176, 6178, 6180, 6182, 6184, 6186, 6188, 6190, /* 0x40-0x47 */ + 6192, 6194, 6196, 6198, 6200, 6202, 6204, 6206, /* 0x48-0x4f */ + 6208, 6210, 6212, 6214, 6216, -1, 6218, 6220, /* 0x50-0x57 */ + 6222, 6224, 6226, 6228, 6230, 6232, 6234, 6236, /* 0x58-0x5f */ + 6238, 6240, 6242, 6244, 6246, 6248, 6250, 6252, /* 0x60-0x67 */ + 6254, 6256, 6258, 6260, 6262, 6264, 6266, 6268, /* 0x68-0x6f */ + 6270, 6272, 6274, 6276, 6278, 6280, 6282, 6284, /* 0x70-0x77 */ + 6286, 6288, 6290, 6292, 6294, 6296, 6298, 6300, /* 0x78-0x7f */ + 6302, 6304, 6306, 6308, 6310, 6312, 6314, 6316, /* 0x80-0x87 */ + 6318, 6320, 6322, 6324, 6326, 6328, 6330, 6332, /* 0x88-0x8f */ + 6334, 6336, 6338, 6340, 6342, 6344, 6346, 6348, /* 0x90-0x97 */ + 6350, 6352, 6354, 6356, 6358, -1, 6360, 6362, /* 0x98-0x9f */ + -1, -1, 6364, -1, -1, 6366, 6368, -1, /* 0xa0-0xa7 */ + -1, 6370, 6372, 6374, 6376, -1, 6378, 6380, /* 0xa8-0xaf */ + 6382, 6384, 6386, 6388, 6390, 6392, 6394, 6396, /* 0xb0-0xb7 */ + 6398, 6400, -1, 6402, -1, 6404, 6406, 6408, /* 0xb8-0xbf */ + 6410, 6412, 6414, 6416, -1, 6418, 6420, 6422, /* 0xc0-0xc7 */ + 6424, 6426, 6428, 6430, 6432, 6434, 6436, 6438, /* 0xc8-0xcf */ + 6440, 6442, 6444, 6446, 6448, 6450, 6452, 6454, /* 0xd0-0xd7 */ + 6456, 6458, 6460, 6462, 6464, 6466, 6468, 6470, /* 0xd8-0xdf */ + 6472, 6474, 6476, 6478, 6480, 6482, 6484, 6486, /* 0xe0-0xe7 */ + 6488, 6490, 6492, 6494, 6496, 6498, 6500, 6502, /* 0xe8-0xef */ + 6504, 6506, 6508, 6510, 6512, 6514, 6516, 6518, /* 0xf0-0xf7 */ + 6520, 6522, 6524, 6526, 6528, 6530, 6532, 6534, /* 0xf8-0xff */ + /* 0x1d500 */ + 6536, 6538, 6540, 6542, 6544, 6546, -1, 6548, /* 0x00-0x07 */ + 6550, 6552, 6554, -1, -1, 6556, 6558, 6560, /* 0x08-0x0f */ + 6562, 6564, 6566, 6568, 6570, -1, 6572, 6574, /* 0x10-0x17 */ + 6576, 6578, 6580, 6582, 6584, -1, 6586, 6588, /* 0x18-0x1f */ + 6590, 6592, 6594, 6596, 6598, 6600, 6602, 6604, /* 0x20-0x27 */ + 6606, 6608, 6610, 6612, 6614, 6616, 6618, 6620, /* 0x28-0x2f */ + 6622, 6624, 6626, 6628, 6630, 6632, 6634, 6636, /* 0x30-0x37 */ + 6638, 6640, -1, 6642, 6644, 6646, 6648, -1, /* 0x38-0x3f */ + 6650, 6652, 6654, 6656, 6658, -1, 6660, -1, /* 0x40-0x47 */ + -1, -1, 6662, 6664, 6666, 6668, 6670, 6672, /* 0x48-0x4f */ + 6674, -1, 6676, 6678, 6680, 6682, 6684, 6686, /* 0x50-0x57 */ + 6688, 6690, 6692, 6694, 6696, 6698, 6700, 6702, /* 0x58-0x5f */ + 6704, 6706, 6708, 6710, 6712, 6714, 6716, 6718, /* 0x60-0x67 */ + 6720, 6722, 6724, 6726, 6728, 6730, 6732, 6734, /* 0x68-0x6f */ + 6736, 6738, 6740, 6742, 6744, 6746, 6748, 6750, /* 0x70-0x77 */ + 6752, 6754, 6756, 6758, 6760, 6762, 6764, 6766, /* 0x78-0x7f */ + 6768, 6770, 6772, 6774, 6776, 6778, 6780, 6782, /* 0x80-0x87 */ + 6784, 6786, 6788, 6790, 6792, 6794, 6796, 6798, /* 0x88-0x8f */ + 6800, 6802, 6804, 6806, 6808, 6810, 6812, 6814, /* 0x90-0x97 */ + 6816, 6818, 6820, 6822, 6824, 6826, 6828, 6830, /* 0x98-0x9f */ + 6832, 6834, 6836, 6838, 6840, 6842, 6844, 6846, /* 0xa0-0xa7 */ + 6848, 6850, 6852, 6854, 6856, 6858, 6860, 6862, /* 0xa8-0xaf */ + 6864, 6866, 6868, 6870, 6872, 6874, 6876, 6878, /* 0xb0-0xb7 */ + 6880, 6882, 6884, 6886, 6888, 6890, 6892, 6894, /* 0xb8-0xbf */ + 6896, 6898, 6900, 6902, 6904, 6906, 6908, 6910, /* 0xc0-0xc7 */ + 6912, 6914, 6916, 6918, 6920, 6922, 6924, 6926, /* 0xc8-0xcf */ + 6928, 6930, 6932, 6934, 6936, 6938, 6940, 6942, /* 0xd0-0xd7 */ + 6944, 6946, 6948, 6950, 6952, 6954, 6956, 6958, /* 0xd8-0xdf */ + 6960, 6962, 6964, 6966, 6968, 6970, 6972, 6974, /* 0xe0-0xe7 */ + 6976, 6978, 6980, 6982, 6984, 6986, 6988, 6990, /* 0xe8-0xef */ + 6992, 6994, 6996, 6998, 7000, 7002, 7004, 7006, /* 0xf0-0xf7 */ + 7008, 7010, 7012, 7014, 7016, 7018, 7020, 7022, /* 0xf8-0xff */ + /* 0x1d600 */ + 7024, 7026, 7028, 7030, 7032, 7034, 7036, 7038, /* 0x00-0x07 */ + 7040, 7042, 7044, 7046, 7048, 7050, 7052, 7054, /* 0x08-0x0f */ + 7056, 7058, 7060, 7062, 7064, 7066, 7068, 7070, /* 0x10-0x17 */ + 7072, 7074, 7076, 7078, 7080, 7082, 7084, 7086, /* 0x18-0x1f */ + 7088, 7090, 7092, 7094, 7096, 7098, 7100, 7102, /* 0x20-0x27 */ + 7104, 7106, 7108, 7110, 7112, 7114, 7116, 7118, /* 0x28-0x2f */ + 7120, 7122, 7124, 7126, 7128, 7130, 7132, 7134, /* 0x30-0x37 */ + 7136, 7138, 7140, 7142, 7144, 7146, 7148, 7150, /* 0x38-0x3f */ + 7152, 7154, 7156, 7158, 7160, 7162, 7164, 7166, /* 0x40-0x47 */ + 7168, 7170, 7172, 7174, 7176, 7178, 7180, 7182, /* 0x48-0x4f */ + 7184, 7186, 7188, 7190, 7192, 7194, 7196, 7198, /* 0x50-0x57 */ + 7200, 7202, 7204, 7206, 7208, 7210, 7212, 7214, /* 0x58-0x5f */ + 7216, 7218, 7220, 7222, 7224, 7226, 7228, 7230, /* 0x60-0x67 */ + 7232, 7234, 7236, 7238, 7240, 7242, 7244, 7246, /* 0x68-0x6f */ + 7248, 7250, 7252, 7254, 7256, 7258, 7260, 7262, /* 0x70-0x77 */ + 7264, 7266, 7268, 7270, 7272, 7274, 7276, 7278, /* 0x78-0x7f */ + 7280, 7282, 7284, 7286, 7288, 7290, 7292, 7294, /* 0x80-0x87 */ + 7296, 7298, 7300, 7302, 7304, 7306, 7308, 7310, /* 0x88-0x8f */ + 7312, 7314, 7316, 7318, 7320, 7322, 7324, 7326, /* 0x90-0x97 */ + 7328, 7330, 7332, 7334, 7336, 7338, 7340, 7342, /* 0x98-0x9f */ + 7344, 7346, 7348, 7350, -1, -1, -1, -1, /* 0xa0-0xa7 */ + 7352, 7354, 7356, 7358, 7360, 7362, 7364, 7366, /* 0xa8-0xaf */ + 7368, 7370, 7372, 7374, 7376, 7378, 7380, 7382, /* 0xb0-0xb7 */ + 7384, 7386, 7388, 7390, 7392, 7394, 7396, 7398, /* 0xb8-0xbf */ + 7400, 7402, 7404, 7406, 7408, 7410, 7412, 7414, /* 0xc0-0xc7 */ + 7416, 7418, 7420, 7422, 7424, 7426, 7428, 7430, /* 0xc8-0xcf */ + 7432, 7434, 7436, 7438, 7440, 7442, 7444, 7446, /* 0xd0-0xd7 */ + 7448, 7450, 7452, 7454, 7456, 7458, 7460, 7462, /* 0xd8-0xdf */ + 7464, 7466, 7468, 7470, 7472, 7474, 7476, 7478, /* 0xe0-0xe7 */ + 7480, 7482, 7484, 7486, 7488, 7490, 7492, 7494, /* 0xe8-0xef */ + 7496, 7498, 7500, 7502, 7504, 7506, 7508, 7510, /* 0xf0-0xf7 */ + 7512, 7514, 7516, 7518, 7520, 7522, 7524, 7526, /* 0xf8-0xff */ + /* 0x1d700 */ + 7528, 7530, 7532, 7534, 7536, 7538, 7540, 7542, /* 0x00-0x07 */ + 7544, 7546, 7548, 7550, 7552, 7554, 7556, 7558, /* 0x08-0x0f */ + 7560, 7562, 7564, 7566, 7568, 7570, 7572, 7574, /* 0x10-0x17 */ + 7576, 7578, 7580, 7582, 7584, 7586, 7588, 7590, /* 0x18-0x1f */ + 7592, 7594, 7596, 7598, 7600, 7602, 7604, 7606, /* 0x20-0x27 */ + 7608, 7610, 7612, 7614, 7616, 7618, 7620, 7622, /* 0x28-0x2f */ + 7624, 7626, 7628, 7630, 7632, 7634, 7636, 7638, /* 0x30-0x37 */ + 7640, 7642, 7644, 7646, 7648, 7650, 7652, 7654, /* 0x38-0x3f */ + 7656, 7658, 7660, 7662, 7664, 7666, 7668, 7670, /* 0x40-0x47 */ + 7672, 7674, 7676, 7678, 7680, 7682, 7684, 7686, /* 0x48-0x4f */ + 7688, 7690, 7692, 7694, 7696, 7698, 7700, 7702, /* 0x50-0x57 */ + 7704, 7706, 7708, 7710, 7712, 7714, 7716, 7718, /* 0x58-0x5f */ + 7720, 7722, 7724, 7726, 7728, 7730, 7732, 7734, /* 0x60-0x67 */ + 7736, 7738, 7740, 7742, 7744, 7746, 7748, 7750, /* 0x68-0x6f */ + 7752, 7754, 7756, 7758, 7760, 7762, 7764, 7766, /* 0x70-0x77 */ + 7768, 7770, 7772, 7774, 7776, 7778, 7780, 7782, /* 0x78-0x7f */ + 7784, 7786, 7788, 7790, 7792, 7794, 7796, 7798, /* 0x80-0x87 */ + 7800, 7802, 7804, 7806, 7808, 7810, 7812, 7814, /* 0x88-0x8f */ + 7816, 7818, 7820, 7822, 7824, 7826, 7828, 7830, /* 0x90-0x97 */ + 7832, 7834, 7836, 7838, 7840, 7842, 7844, 7846, /* 0x98-0x9f */ + 7848, 7850, 7852, 7854, 7856, 7858, 7860, 7862, /* 0xa0-0xa7 */ + 7864, 7866, 7868, 7870, 7872, 7874, 7876, 7878, /* 0xa8-0xaf */ + 7880, 7882, 7884, 7886, 7888, 7890, 7892, 7894, /* 0xb0-0xb7 */ + 7896, 7898, 7900, 7902, 7904, 7906, 7908, 7910, /* 0xb8-0xbf */ + 7912, 7914, 7916, 7918, 7920, 7922, 7924, 7926, /* 0xc0-0xc7 */ + 7928, 7930, -1, -1, -1, -1, 7932, 7934, /* 0xc8-0xcf */ + 7936, 7938, 7940, 7942, 7944, 7946, 7948, 7950, /* 0xd0-0xd7 */ + 7952, 7954, 7956, 7958, 7960, 7962, 7964, 7966, /* 0xd8-0xdf */ + 7968, 7970, 7972, 7974, 7976, 7978, 7980, 7982, /* 0xe0-0xe7 */ + 7984, 7986, 7988, 7990, 7992, 7994, 7996, 7998, /* 0xe8-0xef */ + 8000, 8002, 8004, 8006, 8008, 8010, 8012, 8014, /* 0xf0-0xf7 */ + 8016, 8018, 8020, 8022, 8024, 8026, 8028, 8030, /* 0xf8-0xff */ +}; +static const short translit_page2f8[544] = { + 8032, 8034, 8036, 8038, 8040, 8042, 8044, 8046, /* 0x00-0x07 */ + 8048, 8050, 8052, 8054, 8056, 8058, 8060, 8062, /* 0x08-0x0f */ + 8064, 8066, 8068, 8070, 8072, 8074, 8076, 8078, /* 0x10-0x17 */ + 8080, 8082, 8084, 8086, 8088, 8090, 8092, 8094, /* 0x18-0x1f */ + 8096, 8098, 8100, 8102, 8104, 8106, 8108, 8110, /* 0x20-0x27 */ + 8112, 8114, 8116, 8118, 8120, 8122, 8124, 8126, /* 0x28-0x2f */ + 8128, 8130, 8132, 8134, 8136, 8138, 8140, 8142, /* 0x30-0x37 */ + 8144, 8146, 8148, 8150, 8152, 8154, 8156, 8158, /* 0x38-0x3f */ + 8160, 8162, 8164, 8166, 8168, 8170, 8172, 8174, /* 0x40-0x47 */ + 8176, 8178, 8180, 8182, 8184, 8186, 8188, 8190, /* 0x48-0x4f */ + 8192, 8194, 8196, 8198, 8200, 8202, 8204, 8206, /* 0x50-0x57 */ + 8208, 8210, 8212, 8214, 8216, 8218, 8220, 8222, /* 0x58-0x5f */ + 8224, 8226, 8228, 8230, 8232, 8234, 8236, 8238, /* 0x60-0x67 */ + 8240, 8242, 8244, 8246, 8248, 8250, 8252, 8254, /* 0x68-0x6f */ + 8256, 8258, 8260, 8262, 8264, 8266, 8268, 8270, /* 0x70-0x77 */ + 8272, 8274, 8276, 8278, 8280, 8282, 8284, 8286, /* 0x78-0x7f */ + 8288, 8290, 8292, 8294, 8296, 8298, 8300, 8302, /* 0x80-0x87 */ + 8304, 8306, 8308, 8310, 8312, 8314, 8316, 8318, /* 0x88-0x8f */ + 8320, 8322, 8324, 8326, 8328, 8330, 8332, 8334, /* 0x90-0x97 */ + 8336, 8338, 8340, 8342, 8344, 8346, 8348, 8350, /* 0x98-0x9f */ + 8352, 8354, 8356, 8358, 8360, 8362, 8364, 8366, /* 0xa0-0xa7 */ + 8368, 8370, 8372, 8374, 8376, 8378, 8380, 8382, /* 0xa8-0xaf */ + 8384, 8386, 8388, 8390, 8392, 8394, 8396, 8398, /* 0xb0-0xb7 */ + 8400, 8402, 8404, 8406, 8408, 8410, 8412, 8414, /* 0xb8-0xbf */ + 8416, 8418, 8420, 8422, 8424, 8426, 8428, 8430, /* 0xc0-0xc7 */ + 8432, 8434, 8436, 8438, 8440, 8442, 8444, 8446, /* 0xc8-0xcf */ + 8448, 8450, 8452, 8454, 8456, 8458, 8460, 8462, /* 0xd0-0xd7 */ + 8464, 8466, 8468, 8470, 8472, 8474, 8476, 8478, /* 0xd8-0xdf */ + 8480, 8482, 8484, 8486, 8488, 8490, 8492, 8494, /* 0xe0-0xe7 */ + 8496, 8498, 8500, 8502, 8504, 8506, 8508, 8510, /* 0xe8-0xef */ + 8512, 8514, 8516, 8518, 8520, 8522, 8524, 8526, /* 0xf0-0xf7 */ + 8528, 8530, 8532, 8534, 8536, 8538, 8540, 8542, /* 0xf8-0xff */ + /* 0x2f900 */ + 8544, 8546, 8548, 8550, 8552, 8554, 8556, 8558, /* 0x00-0x07 */ + 8560, 8562, 8564, 8566, 8568, 8570, 8572, 8574, /* 0x08-0x0f */ + 8576, 8578, 8580, 8582, 8584, 8586, 8588, 8590, /* 0x10-0x17 */ + 8592, 8594, 8596, 8598, 8600, 8602, 8604, 8606, /* 0x18-0x1f */ + 8608, 8610, 8612, 8614, 8616, 8618, 8620, 8622, /* 0x20-0x27 */ + 8624, 8626, 8628, 8630, 8632, 8634, 8636, 8638, /* 0x28-0x2f */ + 8640, 8642, 8644, 8646, 8648, 8650, 8652, 8654, /* 0x30-0x37 */ + 8656, 8658, 8660, 8662, 8664, 8666, 8668, 8670, /* 0x38-0x3f */ + 8672, 8674, 8676, 8678, 8680, 8682, 8684, 8686, /* 0x40-0x47 */ + 8688, 8690, 8692, 8694, 8696, 8698, 8700, 8702, /* 0x48-0x4f */ + 8704, 8706, 8708, 8710, 8712, 8714, 8716, 8718, /* 0x50-0x57 */ + 8720, 8722, 8724, 8726, 8728, 8730, 8732, 8734, /* 0x58-0x5f */ + 8736, 8738, 8740, 8742, 8744, 8746, 8748, 8750, /* 0x60-0x67 */ + 8752, 8754, 8756, 8758, 8760, 8762, 8764, 8766, /* 0x68-0x6f */ + 8768, 8770, 8772, 8774, 8776, 8778, 8780, 8782, /* 0x70-0x77 */ + 8784, 8786, 8788, 8790, 8792, 8794, 8796, 8798, /* 0x78-0x7f */ + 8800, 8802, 8804, 8806, 8808, 8810, 8812, 8814, /* 0x80-0x87 */ + 8816, 8818, 8820, 8822, 8824, 8826, 8828, 8830, /* 0x88-0x8f */ + 8832, 8834, 8836, 8838, 8840, 8842, 8844, 8846, /* 0x90-0x97 */ + 8848, 8850, 8852, 8854, 8856, 8858, 8860, 8862, /* 0x98-0x9f */ + 8864, 8866, 8868, 8870, 8872, 8874, 8876, 8878, /* 0xa0-0xa7 */ + 8880, 8882, 8884, 8886, 8888, 8890, 8892, 8894, /* 0xa8-0xaf */ + 8896, 8898, 8900, 8902, 8904, 8906, 8908, 8910, /* 0xb0-0xb7 */ + 8912, 8914, 8916, 8918, 8920, 8922, 8924, 8926, /* 0xb8-0xbf */ + 8928, 8930, 8932, 8934, 8936, 8938, 8940, 8942, /* 0xc0-0xc7 */ + 8944, 8946, 8948, 8950, 8952, 8954, 8956, 8958, /* 0xc8-0xcf */ + 8960, 8962, 8964, 8966, 8968, 8970, 8972, 8974, /* 0xd0-0xd7 */ + 8976, 8978, 8980, 8982, 8984, 8986, 8988, 8990, /* 0xd8-0xdf */ + 8992, 8994, 8996, 8998, 9000, 9002, 9004, 9006, /* 0xe0-0xe7 */ + 9008, 9010, 9012, 9014, 9016, 9018, 9020, 9022, /* 0xe8-0xef */ + 9024, 9026, 9028, 9030, 9032, 9034, 9036, 9038, /* 0xf0-0xf7 */ + 9040, 9042, 9044, 9046, 9048, 9050, 9052, 9054, /* 0xf8-0xff */ + /* 0x2fa00 */ + 9056, 9058, 9060, 9062, 9064, 9066, 9068, 9070, /* 0x00-0x07 */ + 9072, 9074, 9076, 9078, 9080, 9082, 9084, 9086, /* 0x08-0x0f */ + 9088, 9090, 9092, 9094, 9096, 9098, 9100, 9102, /* 0x10-0x17 */ + 9104, 9106, 9108, 9110, 9112, 9114, -1, -1, /* 0x18-0x1f */ +}; + +#define translit_index(wc) \ + (wc >= 0x00a0 && wc < 0x01f8 ? translit_page00[wc-0x00a0] : \ + wc >= 0x0218 && wc < 0x0220 ? translit_page02[wc-0x0218] : \ + wc >= 0x02b8 && wc < 0x02e0 ? translit_page02_1[wc-0x02b8] : \ + wc >= 0x03d0 && wc < 0x0400 ? translit_page03[wc-0x03d0] : \ + wc == 0x0587 ? 654 : \ + wc >= 0x05f0 && wc < 0x05f8 ? translit_page05[wc-0x05f0] : \ + wc >= 0x0670 && wc < 0x0680 ? translit_page06[wc-0x0670] : \ + wc == 0x0e33 ? 678 : \ + wc >= 0x0eb0 && wc < 0x0ee0 ? translit_page0e[wc-0x0eb0] : \ + wc >= 0x0f70 && wc < 0x0f80 ? translit_page0f[wc-0x0f70] : \ + wc >= 0x1e00 && wc < 0x1ea0 ? translit_page1e[wc-0x1e00] : \ + wc >= 0x1ef0 && wc < 0x1ef8 ? translit_page1e_2[wc-0x1ef0] : \ + wc >= 0x2000 && wc < 0x2058 ? translit_page20[wc-0x2000] : \ + wc >= 0x20a8 && wc < 0x20b0 ? translit_page20_3[wc-0x20a8] : \ + wc >= 0x2100 && wc < 0x21d8 ? translit_page21[wc-0x2100] : \ + wc >= 0x2210 && wc < 0x2270 ? translit_page22[wc-0x2210] : \ + wc >= 0x22c0 && wc < 0x22f0 ? translit_page22_4[wc-0x22c0] : \ + wc >= 0x2400 && wc < 0x24f0 ? translit_page24[wc-0x2400] : \ + wc >= 0x2500 && wc < 0x2540 ? translit_page25[wc-0x2500] : \ + wc == 0x25e6 ? 2025 : \ + wc == 0x2a0c ? 2027 : \ + wc >= 0x2a70 && wc < 0x2a78 ? translit_page2a[wc-0x2a70] : \ + wc == 0x2e9f ? 2043 : \ + wc == 0x2ef3 ? 2045 : \ + wc >= 0x2f00 && wc < 0x2fd8 ? translit_page2f[wc-0x2f00] : \ + wc >= 0x3000 && wc < 0x30f8 ? translit_page30[wc-0x3000] : \ + wc >= 0x3130 && wc < 0x3190 ? translit_page31[wc-0x3130] : \ + wc >= 0x31f0 && wc < 0x3400 ? translit_page31_5[wc-0x31f0] : \ + wc >= 0xf900 && wc < 0xfa70 ? translit_pagef9[wc-0xf900] : \ + wc >= 0xfb00 && wc < 0xfb50 ? translit_pagefb[wc-0xfb00] : \ + wc >= 0xfe48 && wc < 0xfe70 ? translit_pagefe[wc-0xfe48] : \ + wc >= 0xff00 && wc < 0xfff0 ? translit_pageff[wc-0xff00] : \ + wc >= 0x1d400 && wc < 0x1d800 ? translit_page1d4[wc-0x1d400] : \ + wc >= 0x2f800 && wc < 0x2fa20 ? translit_page2f8[wc-0x2f800] : \ + -1) diff --git a/graf2d/win32gdk/gdk/src/iconv/ucs2.h b/graf2d/win32gdk/gdk/src/iconv/ucs2.h new file mode 100644 index 0000000000000..206b8ccaeae76 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ucs2.h @@ -0,0 +1,68 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UCS-2 + */ + +/* Here we accept FFFE/FEFF marks as endianness indicators everywhere + in the stream, not just at the beginning. The default is big-endian. */ +/* The state is 0 if big-endian, 1 if little-endian. */ +static int +ucs2_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + state_t state = conv->istate; + int count = 0; + for (; n >= 2;) { + ucs4_t wc = (state ? s[0] + (s[1] << 8) : (s[0] << 8) + s[1]); + s += 2; n -= 2; count += 2; + if (wc == 0xfeff) { + } else if (wc == 0xfffe) { + state ^= 1; + } else if (wc >= 0xd800 && wc < 0xe000) { + conv->istate = state; + return RET_SHIFT_ILSEQ(count); + } else { + *pwc = wc; + conv->istate = state; + return count; + } + } + conv->istate = state; + return RET_TOOFEW(count); +} + +/* But we output UCS-2 in big-endian order, without byte-order mark. */ +/* RFC 2152 says: + "ISO/IEC 10646-1:1993(E) specifies that when characters the UCS-2 form are + serialized as octets, that the most significant octet appear first." */ +static int +ucs2_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x10000 && wc != 0xfffe && !(wc >= 0xd800 && wc < 0xe000)) { + if (n >= 2) { + r[0] = (unsigned char) (wc >> 8); + r[1] = (unsigned char) wc; + return 2; + } else + return RET_TOOSMALL; + } else + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/ucs2be.h b/graf2d/win32gdk/gdk/src/iconv/ucs2be.h new file mode 100644 index 0000000000000..150c0a36ba41e --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ucs2be.h @@ -0,0 +1,51 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UCS-2BE = UCS-2 big endian + */ + +static int +ucs2be_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + if (n >= 2) { + if (s[0] >= 0xd8 && s[0] < 0xe0) { + return RET_ILSEQ; + } else { + *pwc = (s[0] << 8) + s[1]; + return 2; + } + } + return RET_TOOFEW(0); +} + +static int +ucs2be_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x10000 && !(wc >= 0xd800 && wc < 0xe000)) { + if (n >= 2) { + r[0] = (unsigned char) (wc >> 8); + r[1] = (unsigned char) wc; + return 2; + } else + return RET_TOOSMALL; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/ucs2internal.h b/graf2d/win32gdk/gdk/src/iconv/ucs2internal.h new file mode 100644 index 0000000000000..d482aeac40b37 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ucs2internal.h @@ -0,0 +1,51 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UCS-2-INTERNAL = UCS-2 with machine dependent endianness and alignment + */ + +static int +ucs2internal_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + if (n >= 2) { + unsigned short x = *(const unsigned short *)s; + if (x >= 0xd800 && x < 0xe000) { + return RET_ILSEQ; + } else { + *pwc = x; + return 2; + } + } + return RET_TOOFEW(0); +} + +static int +ucs2internal_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x10000 && !(wc >= 0xd800 && wc < 0xe000)) { + if (n >= 2) { + *(unsigned short *)r = wc; + return 2; + } else + return RET_TOOSMALL; + } else + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/ucs2le.h b/graf2d/win32gdk/gdk/src/iconv/ucs2le.h new file mode 100644 index 0000000000000..49018612b5df5 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ucs2le.h @@ -0,0 +1,51 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UCS-2LE = UCS-2 little endian + */ + +static int +ucs2le_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + if (n >= 2) { + if (s[1] >= 0xd8 && s[1] < 0xe0) { + return RET_ILSEQ; + } else { + *pwc = s[0] + (s[1] << 8); + return 2; + } + } + return RET_TOOFEW(0); +} + +static int +ucs2le_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x10000 && !(wc >= 0xd800 && wc < 0xe000)) { + if (n >= 2) { + r[0] = (unsigned char) wc; + r[1] = (unsigned char) (wc >> 8); + return 2; + } else + return RET_TOOSMALL; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/ucs2swapped.h b/graf2d/win32gdk/gdk/src/iconv/ucs2swapped.h new file mode 100644 index 0000000000000..f426f406f1205 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ucs2swapped.h @@ -0,0 +1,60 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UCS-2-SWAPPED = UCS-2-INTERNAL with inverted endianness + */ + +static int +ucs2swapped_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + /* This function assumes that 'unsigned short' has exactly 16 bits. */ + if (sizeof(unsigned short) != 2) abort(); + + if (n >= 2) { + unsigned short x = *(const unsigned short *)s; + x = (x >> 8) | (x << 8); + if (x >= 0xd800 && x < 0xe000) { + return RET_ILSEQ; + } else { + *pwc = x; + return 2; + } + } + return RET_TOOFEW(0); +} + +static int +ucs2swapped_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + /* This function assumes that 'unsigned short' has exactly 16 bits. */ + if (sizeof(unsigned short) != 2) abort(); + + if (wc < 0x10000 && !(wc >= 0xd800 && wc < 0xe000)) { + if (n >= 2) { + unsigned short x = wc; + x = (x >> 8) | (x << 8); + *(unsigned short *)r = x; + return 2; + } else + return RET_TOOSMALL; + } else + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/ucs4.h b/graf2d/win32gdk/gdk/src/iconv/ucs4.h new file mode 100644 index 0000000000000..00d08d2517a6f --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ucs4.h @@ -0,0 +1,69 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UCS-4 + */ + +/* Here we accept FFFE0000/0000FEFF marks as endianness indicators everywhere + in the stream, not just at the beginning. The default is big-endian. */ +/* The state is 0 if big-endian, 1 if little-endian. */ +static int +ucs4_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + state_t state = conv->istate; + int count = 0; + for (; n >= 4;) { + ucs4_t wc = (state + ? s[0] + (s[1] << 8) + (s[2] << 16) + (s[3] << 24) + : (s[0] << 24) + (s[1] << 16) + (s[2] << 8) + s[3]); + s += 4; n -= 4; count += 4; + if (wc == 0x0000feff) { + } else if (wc == 0xfffe0000u) { + state ^= 1; + } else if (wc <= 0x7fffffff) { + *pwc = wc; + conv->istate = state; + return count; + } else { + conv->istate = state; + return RET_SHIFT_ILSEQ(count); + } + } + conv->istate = state; + return RET_TOOFEW(count); +} + +/* But we output UCS-4 in big-endian order, without byte-order mark. */ +static int +ucs4_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc <= 0x7fffffff) { + if (n >= 4) { + r[0] = (unsigned char) (wc >> 24); + r[1] = (unsigned char) (wc >> 16); + r[2] = (unsigned char) (wc >> 8); + r[3] = (unsigned char) wc; + return 4; + } else + return RET_TOOSMALL; + } else + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/ucs4be.h b/graf2d/win32gdk/gdk/src/iconv/ucs4be.h new file mode 100644 index 0000000000000..241bc158dcf20 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ucs4be.h @@ -0,0 +1,46 @@ +/* + * Copyright (C) 1999-2000 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UCS-4BE = UCS-4 big endian + */ + +static int +ucs4be_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + if (n >= 4) { + *pwc = (s[0] << 24) + (s[1] << 16) + (s[2] << 8) + s[3]; + return 4; + } + return RET_TOOFEW(0); +} + +static int +ucs4be_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 4) { + r[0] = (unsigned char) (wc >> 24); + r[1] = (unsigned char) (wc >> 16); + r[2] = (unsigned char) (wc >> 8); + r[3] = (unsigned char) wc; + return 4; + } else + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/ucs4internal.h b/graf2d/win32gdk/gdk/src/iconv/ucs4internal.h new file mode 100644 index 0000000000000..bd793a3f0af56 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ucs4internal.h @@ -0,0 +1,43 @@ +/* + * Copyright (C) 1999-2000 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UCS-4-INTERNAL = UCS-4 with machine dependent endianness and alignment + */ + +static int +ucs4internal_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + if (n >= 4) { + *pwc = *(const unsigned int *)s; + return 4; + } + return RET_TOOFEW(0); +} + +static int +ucs4internal_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 4) { + *(unsigned int *)r = wc; + return 4; + } else + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/ucs4le.h b/graf2d/win32gdk/gdk/src/iconv/ucs4le.h new file mode 100644 index 0000000000000..0c762fec59e6e --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ucs4le.h @@ -0,0 +1,46 @@ +/* + * Copyright (C) 1999-2000 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UCS-4LE = UCS-4 little endian + */ + +static int +ucs4le_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + if (n >= 4) { + *pwc = s[0] + (s[1] << 8) + (s[2] << 16) + (s[3] << 24); + return 4; + } + return RET_TOOFEW(0); +} + +static int +ucs4le_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 4) { + r[0] = (unsigned char) wc; + r[1] = (unsigned char) (wc >> 8); + r[2] = (unsigned char) (wc >> 16); + r[3] = (unsigned char) (wc >> 24); + return 4; + } else + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/ucs4swapped.h b/graf2d/win32gdk/gdk/src/iconv/ucs4swapped.h new file mode 100644 index 0000000000000..6a292ecda6919 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/ucs4swapped.h @@ -0,0 +1,53 @@ +/* + * Copyright (C) 1999-2000 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UCS-4-SWAPPED = UCS-4-INTERNAL with inverted endianness + */ + +static int +ucs4swapped_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + /* This function assumes that 'unsigned int' has exactly 32 bits. */ + if (sizeof(unsigned int) != 4) abort(); + + if (n >= 4) { + unsigned int x = *(const unsigned int *)s; + x = (x >> 24) | ((x >> 8) & 0xff00) | ((x & 0xff00) << 8) | (x << 24); + *pwc = x; + return 4; + } + return RET_TOOFEW(0); +} + +static int +ucs4swapped_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + /* This function assumes that 'unsigned int' has exactly 32 bits. */ + if (sizeof(unsigned int) != 4) abort(); + + if (n >= 4) { + unsigned int x = wc; + x = (x >> 24) | ((x >> 8) & 0xff00) | ((x & 0xff00) << 8) | (x << 24); + *(unsigned int *)r = x; + return 4; + } else + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/uhc_1.h b/graf2d/win32gdk/gdk/src/iconv/uhc_1.h new file mode 100644 index 0000000000000..7b0c725819fa2 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/uhc_1.h @@ -0,0 +1,1725 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * Unified Hangul Code part 1 + */ + +static const unsigned short uhc_1_2uni_main_page81[64] = { + 0xac02, 0xac8d, 0xad14, 0xad91, 0xadfa, 0xae7a, 0xaee6, 0xaf57, + 0xafbf, 0xb030, 0xb0a5, 0xb122, 0xb19e, 0xb207, 0xb26f, 0xb2f0, + 0xb366, 0xb3e1, 0xb445, 0xb4ad, 0xb51e, 0xb590, 0xb600, 0xb661, + 0xb6c3, 0xb723, 0xb79f, 0xb811, 0xb885, 0xb8f1, 0xb95a, 0xb9d4, + 0xba47, 0xbac2, 0xbb28, 0xbb9a, 0xbc03, 0xbc80, 0xbcfe, 0xbd67, + 0xbdd2, 0xbe3d, 0xbeb8, 0xbf23, 0xbf83, 0xbfe6, 0xc040, 0xc0a7, + 0xc132, 0xc1b1, 0xc224, 0xc297, 0xc310, 0xc37a, 0xc3db, 0xc446, + 0xc4aa, 0xc50f, 0xc596, 0xc626, 0xc6a8, 0xc726, 0xc7b8, 0xc832, +}; +static const unsigned char uhc_1_2uni_page81[5696] = { + /* 0x81 */ + 0x00, 0x01, 0x03, 0x04, 0x09, 0x0a, 0x0b, 0x0c, + 0x0d, 0x16, 0x1c, 0x1d, 0x1f, 0x20, 0x21, 0x23, + 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2c, 0x30, + 0x31, 0x32, 0x33, 0x34, 0x35, 0x38, 0x39, 0x3b, + 0x3c, 0x3d, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, + 0x45, 0x46, 0x47, 0x48, 0x4a, 0x4c, 0x4d, 0x4e, + 0x4f, 0x50, 0x51, 0x53, 0x54, 0x55, 0x57, 0x58, + 0x59, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, + 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, + 0x6a, 0x6b, 0x6c, 0x6d, 0x70, 0x71, 0x73, 0x74, + 0x77, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, 0x80, 0x85, + 0x86, 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, 0x08, + 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x11, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1e, 0x20, 0x21, + 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2d, + 0x31, 0x32, 0x33, 0x35, 0x36, 0x38, 0x39, 0x3a, + 0x3c, 0x3d, 0x3e, 0x40, 0x41, 0x42, 0x43, 0x44, + 0x45, 0x46, 0x47, 0x49, 0x4b, 0x4c, 0x4d, 0x4e, + 0x4f, 0x50, 0x51, 0x52, 0x55, 0x56, 0x58, 0x59, + 0x5c, 0x5e, 0x60, 0x61, 0x65, 0x67, 0x6a, 0x6b, + 0x6c, 0x6d, 0x6e, 0x71, 0x72, 0x74, 0x75, 0x76, + 0x78, 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x81, 0x83, + 0x85, 0x86, + /* 0x82 */ + 0x00, 0x01, 0x02, 0x03, 0x05, 0x06, 0x07, 0x09, + 0x0a, 0x0b, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, + 0x13, 0x14, 0x16, 0x17, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x22, 0x23, 0x25, 0x26, 0x27, 0x29, + 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x32, 0x34, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3d, 0x3e, + 0x3f, 0x41, 0x42, 0x43, 0x45, 0x46, 0x47, 0x48, + 0x49, 0x4a, 0x4b, 0x4c, 0x4e, 0x50, 0x51, 0x52, + 0x53, 0x54, 0x55, 0x56, 0x57, 0x5a, 0x5b, 0x5d, + 0x5e, 0x63, 0x64, 0x65, 0x66, 0x6a, 0x6c, 0x6f, + 0x70, 0x71, 0x72, 0x73, 0x76, 0x77, 0x79, 0x7a, + 0x7b, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0a, 0x0d, 0x0e, 0x0f, 0x10, + 0x11, 0x12, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, + 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, + 0x22, 0x23, 0x24, 0x25, 0x27, 0x28, 0x29, 0x2a, + 0x2b, 0x2c, 0x2d, 0x2e, 0x31, 0x32, 0x34, 0x35, + 0x36, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, + 0x41, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, + 0x4a, 0x4c, 0x4d, 0x4e, 0x50, 0x51, 0x52, 0x54, + 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, + 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, 0x64, + 0x65, 0x66, + /* 0x83 */ + 0x00, 0x01, 0x03, 0x04, 0x08, 0x09, 0x0a, 0x0b, + 0x0c, 0x0d, 0x10, 0x12, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, + 0x31, 0x32, 0x33, 0x34, 0x35, 0x38, 0x39, 0x3b, + 0x3c, 0x3f, 0x41, 0x42, 0x43, 0x44, 0x45, 0x48, + 0x4a, 0x4d, 0x4e, 0x4f, 0x51, 0x55, 0x57, 0x58, + 0x59, 0x5b, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x64, + 0x68, 0x69, 0x6a, 0x6c, 0x6d, 0x70, 0x71, 0x73, + 0x74, 0x75, 0x77, 0x78, 0x79, 0x7a, 0x7b, 0x7c, + 0x7d, 0x00, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, + 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x13, 0x14, + 0x15, 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, + 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, + 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, + 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, + 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, + 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x45, 0x47, 0x48, + 0x49, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, + 0x54, 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x60, + 0x61, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, + 0x6a, 0x6b, + /* 0x84 */ + 0x00, 0x01, 0x03, 0x04, 0x06, 0x08, 0x09, 0x0a, + 0x0b, 0x0c, 0x0d, 0x0f, 0x10, 0x11, 0x13, 0x14, + 0x15, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x23, 0x24, 0x25, 0x26, 0x28, + 0x29, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, + 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, + 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, + 0x42, 0x43, 0x44, 0x45, 0x48, 0x49, 0x4b, 0x4d, + 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x58, + 0x5a, 0x5e, 0x5f, 0x60, 0x61, 0x64, 0x65, 0x66, + 0x67, 0x68, 0x69, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, + 0x70, 0x00, 0x01, 0x02, 0x03, 0x04, 0x07, 0x08, + 0x09, 0x0a, 0x0b, 0x0c, 0x0f, 0x10, 0x11, 0x12, + 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, 0x1a, + 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x23, + 0x24, 0x25, 0x26, 0x27, 0x28, 0x2a, 0x2b, 0x2c, + 0x2e, 0x2f, 0x30, 0x32, 0x33, 0x34, 0x35, 0x36, + 0x37, 0x38, 0x3b, 0x3c, 0x3d, 0x3f, 0x40, 0x41, + 0x42, 0x43, 0x44, 0x46, 0x47, 0x48, 0x49, 0x4a, + 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, + 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, + 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x63, 0x64, + 0x66, 0x67, + /* 0x85 */ + 0x00, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x0b, + 0x0d, 0x10, 0x11, 0x12, 0x13, 0x14, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x33, 0x34, + 0x36, 0x37, 0x38, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, + 0x3f, 0x40, 0x43, 0x44, 0x46, 0x47, 0x48, 0x49, + 0x4a, 0x4b, 0x4c, 0x4e, 0x4f, 0x50, 0x52, 0x53, + 0x54, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, + 0x5f, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, + 0x67, 0x68, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, + 0x70, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, + 0x0f, 0x10, 0x11, 0x12, 0x13, 0x16, 0x17, 0x19, + 0x1b, 0x1d, 0x1f, 0x20, 0x21, 0x22, 0x26, 0x28, + 0x2a, 0x2b, 0x2c, 0x2e, 0x2f, 0x30, 0x31, 0x32, + 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, + 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, + 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, + 0x4b, 0x4e, 0x4f, 0x51, 0x52, 0x53, 0x55, 0x56, + 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5e, 0x60, 0x62, + 0x63, 0x64, 0x65, 0x66, 0x67, 0x6b, 0x6d, 0x6e, + 0x73, 0x74, + /* 0x86 */ + 0x00, 0x01, 0x02, 0x05, 0x0b, 0x0d, 0x11, 0x12, + 0x14, 0x15, 0x16, 0x18, 0x19, 0x1a, 0x1b, 0x1c, + 0x1d, 0x1e, 0x21, 0x25, 0x26, 0x27, 0x28, 0x29, + 0x2a, 0x2d, 0x2e, 0x30, 0x31, 0x32, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3c, 0x3d, 0x3e, + 0x3f, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, 0x62, 0x65, 0x68, 0x69, 0x6a, 0x6c, + 0x6f, 0x70, 0x71, 0x72, 0x75, 0x79, 0x7a, 0x7b, + 0x7c, 0x00, 0x04, 0x05, 0x07, 0x08, 0x09, 0x0b, + 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x14, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x20, 0x21, 0x23, + 0x24, 0x25, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, + 0x2d, 0x30, 0x31, 0x34, 0x35, 0x37, 0x38, 0x39, + 0x3b, 0x3c, 0x3d, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, + 0x54, 0x55, 0x58, 0x59, 0x5b, 0x5c, 0x5d, 0x5f, + 0x61, 0x62, 0x63, 0x64, 0x65, 0x68, 0x6a, 0x6c, + 0x6d, 0x6e, 0x6f, 0x73, 0x74, 0x75, 0x77, 0x78, + 0x79, 0x7b, + /* 0x87 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2f, 0x30, 0x31, + 0x33, 0x34, 0x35, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x40, 0x42, 0x43, 0x44, 0x45, 0x46, + 0x47, 0x48, 0x49, 0x4c, 0x4d, 0x4f, 0x50, 0x51, + 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, + 0x5c, 0x5e, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, + 0x68, 0x00, 0x02, 0x03, 0x06, 0x07, 0x08, 0x09, + 0x0a, 0x0b, 0x0c, 0x0f, 0x11, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, + 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, + 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x36, 0x37, 0x38, + 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, + 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, + 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, + 0x52, 0x53, 0x54, 0x56, 0x57, 0x58, 0x5a, 0x5b, + 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x63, 0x64, 0x65, + 0x66, 0x67, + /* 0x88 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x07, 0x08, 0x09, + 0x0a, 0x0b, 0x0c, 0x0e, 0x0f, 0x10, 0x11, 0x12, + 0x13, 0x14, 0x17, 0x18, 0x19, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x23, 0x24, 0x26, 0x27, 0x28, + 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x33, 0x35, 0x38, + 0x39, 0x3a, 0x3c, 0x3e, 0x3f, 0x40, 0x42, 0x43, + 0x44, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, + 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, + 0x55, 0x56, 0x57, 0x58, 0x5b, 0x5c, 0x5e, 0x5f, + 0x60, 0x62, 0x64, 0x65, 0x66, 0x67, 0x68, 0x6b, + 0x6d, 0x6f, 0x70, 0x71, 0x72, 0x74, 0x78, 0x7a, + 0x7b, 0x00, 0x01, 0x02, 0x06, 0x0c, 0x0d, 0x0e, + 0x12, 0x13, 0x15, 0x16, 0x17, 0x19, 0x1a, 0x1b, + 0x1c, 0x1d, 0x1e, 0x1f, 0x22, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2d, 0x2e, 0x2f, 0x30, 0x31, + 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, + 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, + 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, + 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, + 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, + 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, + 0x62, 0x63, 0x67, 0x69, 0x6a, 0x6d, 0x70, 0x71, + 0x72, 0x73, + /* 0x89 */ + 0x00, 0x02, 0x04, 0x06, 0x07, 0x09, 0x0c, 0x0d, + 0x0f, 0x10, 0x11, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1c, 0x20, 0x21, 0x22, 0x23, 0x24, + 0x25, 0x27, 0x28, 0x29, 0x2b, 0x2c, 0x2d, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, + 0x43, 0x44, 0x45, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, + 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, + 0x5c, 0x5d, 0x60, 0x61, 0x63, 0x64, 0x67, 0x69, + 0x6b, 0x6c, 0x6d, 0x70, 0x72, 0x74, 0x76, 0x78, + 0x79, 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, 0x08, + 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, + 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, + 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x30, 0x31, 0x32, + 0x33, 0x34, 0x35, 0x36, 0x38, 0x39, 0x3a, 0x3c, + 0x3d, 0x3e, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, + 0x46, 0x49, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, + 0x51, 0x52, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, + 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, + 0x62, 0x63, + /* 0x8a */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0d, 0x0e, 0x10, 0x11, 0x12, + 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1d, + 0x1f, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, + 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, + 0x39, 0x3a, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, + 0x42, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, + 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, + 0x53, 0x54, 0x55, 0x56, 0x57, 0x59, 0x5a, 0x5b, + 0x5c, 0x5d, 0x5e, 0x60, 0x61, 0x62, 0x64, 0x65, + 0x66, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x09, 0x0b, 0x0d, 0x0e, 0x0f, 0x10, 0x11, + 0x12, 0x14, 0x15, 0x16, 0x18, 0x19, 0x1a, 0x1c, + 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x24, 0x25, + 0x26, 0x27, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, + 0x31, 0x32, 0x34, 0x35, 0x38, 0x3a, 0x3b, 0x3c, + 0x3d, 0x3e, 0x41, 0x43, 0x45, 0x46, 0x47, 0x48, + 0x49, 0x4a, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, + 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, + 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, + 0x62, 0x63, 0x64, 0x65, 0x66, 0x69, 0x6a, 0x6c, + 0x6d, 0x70, + /* 0x8b */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x08, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x14, 0x15, 0x17, 0x18, + 0x19, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, + 0x24, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x30, 0x31, + 0x33, 0x34, 0x35, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x40, 0x44, 0x45, 0x46, 0x47, 0x48, + 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, + 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, + 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, + 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, + 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, + 0x71, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, + 0x0f, 0x12, 0x13, 0x15, 0x16, 0x17, 0x19, 0x1c, + 0x1d, 0x1e, 0x1f, 0x22, 0x26, 0x27, 0x28, 0x29, + 0x2a, 0x2e, 0x2f, 0x31, 0x32, 0x33, 0x35, 0x36, + 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3e, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x49, 0x4a, 0x4b, 0x4c, + 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, + 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5d, + 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, + 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, + 0x6e, 0x6f, + /* 0x8c */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x12, 0x13, 0x15, 0x16, 0x17, 0x19, 0x1a, 0x1b, + 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, + 0x24, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x35, 0x36, + 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, + 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, + 0x47, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, 0x08, + 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, + 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, + 0x39, 0x3a, 0x3d, 0x3e, 0x40, 0x41, 0x42, 0x44, + 0x45, 0x46, 0x47, 0x48, 0x49, 0x4c, 0x4d, 0x4e, + 0x4f, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, + /* 0x8d */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, 0x2e, 0x2f, 0x30, 0x32, + 0x33, 0x34, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3f, 0x40, 0x41, 0x43, 0x44, 0x45, 0x46, + 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, + 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, + 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, + 0x5f, 0x00, 0x01, 0x02, 0x03, 0x04, 0x07, 0x08, + 0x0a, 0x0b, 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, + 0x14, 0x17, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, + 0x1f, 0x20, 0x22, 0x23, 0x24, 0x26, 0x27, 0x28, + 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x33, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3e, 0x3f, 0x40, 0x42, 0x43, 0x44, 0x46, + 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4f, 0x51, + 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x5b, 0x5c, + 0x5e, 0x5f, 0x60, 0x62, 0x63, 0x64, 0x65, 0x66, + 0x67, 0x68, 0x6b, 0x70, 0x71, 0x72, 0x77, 0x78, + 0x7a, 0x7b, + /* 0x8e */ + 0x00, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, + 0x0b, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x17, + 0x18, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x29, + 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, + 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, + 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, + 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, + 0x4b, 0x4c, 0x4f, 0x50, 0x52, 0x53, 0x54, 0x56, + 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5f, 0x63, + 0x64, 0x65, 0x66, 0x67, 0x6b, 0x6c, 0x6e, 0x6f, + 0x70, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x09, 0x0b, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, + 0x15, 0x16, 0x18, 0x19, 0x1a, 0x1c, 0x1d, 0x1e, + 0x1f, 0x20, 0x21, 0x22, 0x25, 0x29, 0x2a, 0x2b, + 0x2c, 0x2d, 0x2e, 0x30, 0x31, 0x32, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, + 0x3e, 0x3f, 0x41, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4d, 0x4e, 0x50, 0x51, 0x52, + 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5d, + 0x5f, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x68, + 0x69, 0x6a, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, + 0x72, 0x73, + /* 0x8f */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, + 0x2a, 0x2c, 0x2d, 0x2e, 0x30, 0x31, 0x32, 0x34, + 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3d, 0x3f, + 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x48, 0x49, + 0x4a, 0x4c, 0x4d, 0x4e, 0x50, 0x51, 0x52, 0x53, + 0x54, 0x55, 0x56, 0x57, 0x59, 0x5b, 0x5d, 0x5e, + 0x5f, 0x60, 0x61, 0x62, 0x65, 0x66, 0x68, 0x69, + 0x6a, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x09, 0x0b, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, + 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, + 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, + 0x24, 0x25, 0x26, 0x28, 0x29, 0x2a, 0x2b, 0x2c, + 0x2d, 0x2e, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, + 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, + 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4d, 0x4e, 0x50, + 0x51, 0x52, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, + 0x5a, 0x5c, 0x5d, 0x5f, 0x61, 0x62, 0x63, 0x64, + 0x65, 0x66, + /* 0x90 */ + 0x00, 0x01, 0x03, 0x04, 0x05, 0x07, 0x08, 0x09, + 0x0a, 0x0b, 0x0c, 0x0d, 0x10, 0x12, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1c, 0x1d, 0x1f, 0x20, + 0x21, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, + 0x2c, 0x2e, 0x31, 0x32, 0x35, 0x36, 0x37, 0x38, + 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, + 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, + 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, + 0x51, 0x54, 0x55, 0x57, 0x58, 0x59, 0x5b, 0x5c, + 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x64, 0x66, 0x68, + 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x70, 0x71, 0x73, + 0x79, 0x00, 0x01, 0x02, 0x03, 0x06, 0x08, 0x0b, + 0x0c, 0x0e, 0x12, 0x13, 0x15, 0x16, 0x17, 0x19, + 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x22, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2e, 0x2f, 0x30, 0x31, + 0x32, 0x33, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, + 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, + 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, + 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, + 0x66, 0x67, 0x69, 0x6a, 0x6b, 0x6d, 0x6f, 0x70, + 0x71, 0x72, + /* 0x91 */ + 0x00, 0x03, 0x05, 0x08, 0x09, 0x0a, 0x0b, 0x0f, + 0x10, 0x12, 0x13, 0x14, 0x16, 0x17, 0x18, 0x19, + 0x1a, 0x1b, 0x1c, 0x1f, 0x23, 0x24, 0x25, 0x26, + 0x27, 0x28, 0x2b, 0x2c, 0x2e, 0x2f, 0x30, 0x32, + 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, + 0x3b, 0x3f, 0x41, 0x42, 0x43, 0x44, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x63, 0x66, 0x67, 0x68, 0x6a, 0x6c, 0x6d, + 0x6e, 0x6f, 0x70, 0x73, 0x75, 0x77, 0x78, 0x79, + 0x7a, 0x00, 0x01, 0x03, 0x04, 0x05, 0x07, 0x08, + 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x18, 0x19, 0x1a, + 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, + 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, + 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, + 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3b, + 0x3c, 0x3d, 0x3f, 0x40, 0x41, 0x43, 0x44, 0x45, + 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4c, 0x4e, 0x50, + 0x51, 0x52, 0x53, 0x54, 0x55, 0x57, 0x58, 0x59, + 0x5b, 0x5c, 0x5d, 0x5f, 0x60, 0x61, 0x62, 0x63, + 0x64, 0x65, + /* 0x92 */ + 0x00, 0x02, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, + 0x0a, 0x0b, 0x0f, 0x11, 0x12, 0x17, 0x18, 0x19, + 0x1a, 0x1b, 0x1e, 0x20, 0x22, 0x23, 0x24, 0x26, + 0x29, 0x2a, 0x2b, 0x2d, 0x2e, 0x2f, 0x31, 0x32, + 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x3a, 0x3c, + 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x45, + 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, + 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, + 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, + 0x5e, 0x5f, 0x61, 0x62, 0x63, 0x65, 0x66, 0x67, + 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, + 0x71, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0b, 0x0c, 0x0d, 0x0f, 0x10, + 0x11, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, + 0x1b, 0x1c, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, + 0x24, 0x25, 0x27, 0x28, 0x29, 0x2b, 0x2c, 0x2d, + 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x37, + 0x38, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, + 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, + 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, + 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, + 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x60, 0x61, 0x63, + 0x64, 0x67, + /* 0x93 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x07, 0x0b, 0x0d, + 0x0f, 0x10, 0x16, 0x17, 0x1d, 0x1e, 0x1f, 0x20, + 0x23, 0x25, 0x27, 0x28, 0x29, 0x2b, 0x2c, 0x2f, + 0x30, 0x32, 0x33, 0x34, 0x36, 0x37, 0x38, 0x39, + 0x3a, 0x3b, 0x3c, 0x3f, 0x43, 0x44, 0x45, 0x47, + 0x48, 0x4b, 0x4c, 0x4e, 0x4f, 0x50, 0x51, 0x52, + 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5b, + 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, + 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, + 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, + 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, + 0x7c, 0x00, 0x01, 0x02, 0x03, 0x06, 0x07, 0x09, + 0x0a, 0x0d, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x16, + 0x18, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x22, 0x23, + 0x25, 0x26, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, + 0x2f, 0x32, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3e, 0x3f, 0x41, 0x42, 0x43, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4e, 0x52, 0x53, + 0x54, 0x56, 0x57, 0x59, 0x5a, 0x5b, 0x5d, 0x5e, + 0x5f, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, + 0x67, 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, + 0x6f, 0x70, 0x71, 0x72, 0x73, 0x77, 0x79, 0x7a, + 0x7b, 0x7d, + /* 0x94 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x08, 0x0a, + 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x13, 0x14, + 0x15, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, + 0x49, 0x4c, 0x4d, 0x4f, 0x50, 0x51, 0x53, 0x54, + 0x55, 0x56, 0x57, 0x58, 0x59, 0x5c, 0x5d, 0x5e, + 0x5f, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x67, + 0x68, 0x00, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x1b, 0x1c, 0x1e, 0x1f, 0x24, 0x25, 0x26, + 0x27, 0x28, 0x2b, 0x2d, 0x2f, 0x30, 0x31, 0x34, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3e, + 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, + 0x47, 0x48, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, + 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, + 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, + 0x69, 0x6a, + /* 0x95 */ + 0x00, 0x01, 0x04, 0x05, 0x07, 0x08, 0x09, 0x0b, + 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, + 0x14, 0x15, 0x16, 0x18, 0x19, 0x1a, 0x1b, 0x1c, + 0x1d, 0x1f, 0x20, 0x21, 0x23, 0x24, 0x25, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2f, 0x30, + 0x32, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3c, + 0x3d, 0x3f, 0x40, 0x41, 0x43, 0x44, 0x45, 0x46, + 0x47, 0x48, 0x49, 0x4c, 0x4e, 0x4f, 0x50, 0x51, + 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, + 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, + 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, + 0x6a, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x09, 0x0a, 0x0c, 0x0d, 0x0e, 0x10, 0x12, 0x13, + 0x14, 0x15, 0x16, 0x19, 0x1b, 0x1f, 0x20, 0x21, + 0x22, 0x25, 0x26, 0x28, 0x29, 0x2a, 0x2c, 0x2e, + 0x2f, 0x30, 0x31, 0x32, 0x35, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x41, 0x42, 0x44, 0x45, 0x46, 0x48, + 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x51, 0x55, + 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, + 0x68, 0x69, 0x6a, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, + 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, + 0x79, 0x7a, + /* 0x96 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x1a, 0x1b, 0x1d, 0x1e, 0x21, 0x22, 0x23, 0x24, + 0x25, 0x26, 0x27, 0x29, 0x2a, 0x2e, 0x2f, 0x30, + 0x31, 0x32, 0x33, 0x35, 0x36, 0x37, 0x38, 0x39, + 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, + 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x4a, + 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x52, 0x53, 0x54, + 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, + 0x5d, 0x5e, 0x5f, 0x62, 0x66, 0x67, 0x68, 0x69, + 0x6a, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, + 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, + 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1f, 0x20, + 0x22, 0x23, 0x24, 0x26, 0x27, 0x28, 0x29, 0x2a, + 0x2b, 0x2c, 0x2f, 0x30, 0x31, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, + 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, + 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, + 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, + 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, + 0x5e, 0x5f, + /* 0x97 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, 0x2e, 0x2f, 0x30, 0x31, + 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, + 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, + 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x4b, 0x4c, + 0x4e, 0x4f, 0x50, 0x52, 0x53, 0x54, 0x55, 0x56, + 0x57, 0x58, 0x5a, 0x5b, 0x5d, 0x5f, 0x60, 0x61, + 0x62, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, + 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, + 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, + 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, + 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, + 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, + 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, + 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, + 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, + 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x57, + 0x58, 0x59, + /* 0x98 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x19, + 0x1a, 0x1b, 0x1d, 0x1e, 0x1f, 0x21, 0x22, 0x23, + 0x24, 0x25, 0x26, 0x27, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, + 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, + 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, + 0x4e, 0x4f, 0x52, 0x53, 0x55, 0x56, 0x57, 0x59, + 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x62, 0x64, + 0x66, 0x00, 0x01, 0x02, 0x03, 0x04, 0x07, 0x0a, + 0x0b, 0x10, 0x11, 0x12, 0x13, 0x14, 0x17, 0x1b, + 0x1c, 0x1d, 0x1f, 0x20, 0x23, 0x24, 0x26, 0x27, + 0x28, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, + 0x33, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3f, + 0x40, 0x42, 0x43, 0x44, 0x46, 0x47, 0x48, 0x49, + 0x4a, 0x4b, 0x4c, 0x4f, 0x51, 0x53, 0x54, 0x55, + 0x56, 0x57, 0x58, 0x5a, 0x5b, 0x5c, 0x5e, 0x5f, + 0x60, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, + 0x6a, 0x6b, 0x6c, 0x6d, 0x6f, 0x70, 0x71, 0x72, + 0x73, 0x74, 0x7a, 0x7b, 0x7e, 0x81, 0x82, 0x83, + 0x84, 0x87, + /* 0x99 */ + 0x00, 0x01, 0x02, 0x03, 0x05, 0x08, 0x09, 0x0b, + 0x0c, 0x0d, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, + 0x15, 0x18, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, + 0x24, 0x25, 0x27, 0x28, 0x29, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x34, 0x38, 0x39, 0x3a, + 0x3b, 0x3c, 0x3d, 0x3f, 0x40, 0x41, 0x43, 0x44, + 0x45, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, + 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x54, 0x55, 0x56, + 0x57, 0x58, 0x59, 0x5d, 0x5f, 0x60, 0x61, 0x63, + 0x65, 0x66, 0x67, 0x68, 0x69, 0x6c, 0x6e, 0x70, + 0x71, 0x72, 0x74, 0x75, 0x78, 0x79, 0x7b, 0x7c, + 0x7d, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x14, 0x15, 0x16, 0x18, 0x19, + 0x1a, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, + 0x24, 0x25, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x30, 0x31, 0x32, 0x34, 0x35, 0x36, 0x38, + 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x41, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4d, + 0x4e, 0x50, 0x51, 0x52, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5d, 0x5f, 0x61, 0x62, 0x63, + 0x64, 0x65, 0x66, 0x69, 0x6a, 0x6c, 0x6d, 0x70, + 0x71, 0x72, + /* 0x9a */ + 0x00, 0x01, 0x02, 0x03, 0x06, 0x08, 0x0a, 0x0c, + 0x0f, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2e, 0x2f, 0x31, 0x32, 0x33, + 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3d, + 0x3e, 0x3f, 0x40, 0x42, 0x43, 0x44, 0x45, 0x46, + 0x47, 0x4a, 0x4b, 0x4d, 0x4e, 0x4f, 0x51, 0x52, + 0x53, 0x54, 0x55, 0x56, 0x57, 0x5a, 0x5c, 0x5e, + 0x5f, 0x60, 0x61, 0x62, 0x63, 0x66, 0x67, 0x68, + 0x69, 0x6a, 0x6b, 0x6d, 0x6e, 0x6f, 0x70, 0x71, + 0x72, 0x00, 0x02, 0x03, 0x05, 0x07, 0x08, 0x09, + 0x0a, 0x0b, 0x0c, 0x0f, 0x10, 0x12, 0x13, 0x14, + 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1f, 0x21, + 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, + 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, + 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, + 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, + 0x43, 0x44, 0x47, 0x48, 0x4a, 0x4b, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x57, 0x59, 0x5b, 0x5c, + 0x5d, 0x5e, 0x60, 0x63, 0x66, 0x67, 0x68, 0x6a, + 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x73, 0x74, + 0x77, 0x78, + /* 0x9b */ + 0x00, 0x01, 0x02, 0x06, 0x07, 0x09, 0x0a, 0x0b, + 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x16, + 0x17, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, + 0x31, 0x32, 0x33, 0x34, 0x36, 0x37, 0x38, 0x39, + 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, + 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, + 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, + 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x5a, 0x5b, + 0x5d, 0x5e, 0x5f, 0x61, 0x63, 0x64, 0x65, 0x66, + 0x67, 0x00, 0x01, 0x04, 0x05, 0x06, 0x07, 0x08, + 0x09, 0x0b, 0x0c, 0x0d, 0x0f, 0x10, 0x11, 0x13, + 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, + 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, + 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, + 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, + 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, + 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, + 0x5d, 0x60, + /* 0x9c */ + 0x00, 0x02, 0x03, 0x06, 0x08, 0x09, 0x0a, 0x0b, + 0x0c, 0x0f, 0x10, 0x11, 0x13, 0x14, 0x15, 0x16, + 0x17, 0x18, 0x1b, 0x1c, 0x1e, 0x1f, 0x20, 0x21, + 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, + 0x2a, 0x2b, 0x2c, 0x2e, 0x2f, 0x30, 0x31, 0x32, + 0x33, 0x34, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x4a, 0x4b, 0x4c, + 0x4d, 0x4e, 0x4f, 0x50, 0x52, 0x53, 0x54, 0x56, + 0x57, 0x58, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, + 0x6a, 0x00, 0x01, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x20, 0x21, + 0x23, 0x24, 0x25, 0x27, 0x28, 0x29, 0x2a, 0x2b, + 0x2c, 0x2d, 0x30, 0x31, 0x32, 0x34, 0x35, 0x36, + 0x37, 0x38, 0x39, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4f, 0x50, + 0x51, 0x52, 0x53, 0x54, 0x55, 0x57, 0x58, 0x59, + 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, + 0x62, 0x63, + /* 0x9d */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0f, 0x10, + 0x11, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, + 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, + 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, + 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, + 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, + 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x40, 0x41, 0x42, + 0x43, 0x44, 0x45, 0x48, 0x49, 0x4b, 0x4c, 0x4d, + 0x4f, 0x51, 0x52, 0x53, 0x54, 0x58, 0x59, 0x5a, + 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x63, + 0x64, 0x00, 0x02, 0x03, 0x04, 0x06, 0x07, 0x08, + 0x09, 0x0a, 0x0b, 0x0c, 0x0e, 0x0f, 0x10, 0x11, + 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x1b, + 0x1c, 0x1e, 0x1f, 0x20, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x2b, 0x2d, 0x2f, 0x30, 0x31, + 0x32, 0x33, 0x34, 0x37, 0x38, 0x3c, 0x40, 0x41, + 0x42, 0x43, 0x47, 0x4b, 0x4c, 0x4d, 0x50, 0x53, + 0x54, 0x56, 0x57, 0x58, 0x5a, 0x5b, 0x5c, 0x5d, + 0x5e, 0x5f, 0x60, 0x63, 0x67, 0x68, 0x69, 0x6a, + 0x6b, 0x6c, 0x6f, 0x70, 0x72, 0x73, 0x74, 0x76, + 0x77, 0x79, 0x7a, 0x7b, 0x7c, 0x7f, 0x81, 0x83, + 0x84, 0x85, + /* 0x9e */ + 0x00, 0x03, 0x04, 0x05, 0x07, 0x08, 0x09, 0x0b, + 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x14, + 0x15, 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, + 0x1d, 0x20, 0x21, 0x24, 0x29, 0x2a, 0x2b, 0x2c, + 0x2d, 0x35, 0x37, 0x39, 0x3c, 0x3d, 0x3f, 0x40, + 0x41, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, + 0x4c, 0x4e, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, + 0x59, 0x5b, 0x5c, 0x5d, 0x5f, 0x62, 0x63, 0x64, + 0x65, 0x6c, 0x6d, 0x6e, 0x73, 0x74, 0x75, 0x77, + 0x78, 0x79, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, 0x80, + 0x81, 0x84, 0x87, 0x88, 0x89, 0x8a, 0x8b, 0x8c, + 0x8d, 0x00, 0x01, 0x03, 0x04, 0x05, 0x09, 0x0b, + 0x0c, 0x10, 0x12, 0x14, 0x16, 0x17, 0x18, 0x19, + 0x1c, 0x1d, 0x1f, 0x20, 0x21, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2c, 0x30, 0x31, 0x32, + 0x33, 0x34, 0x35, 0x38, 0x39, 0x3b, 0x3c, 0x3d, + 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, + 0x47, 0x48, 0x4a, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, + 0x51, 0x54, 0x55, 0x57, 0x58, 0x59, 0x5b, 0x5c, + 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x64, 0x66, 0x68, + 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x70, 0x71, 0x73, + 0x74, 0x75, 0x77, 0x78, 0x79, 0x7a, 0x7b, 0x7c, + 0x7d, 0x80, + /* 0x9f */ + 0x00, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x0a, + 0x0b, 0x0d, 0x0e, 0x0f, 0x13, 0x14, 0x15, 0x16, + 0x17, 0x1a, 0x1c, 0x1e, 0x1f, 0x20, 0x21, 0x22, + 0x23, 0x26, 0x27, 0x29, 0x2a, 0x2b, 0x2d, 0x2e, + 0x2f, 0x30, 0x31, 0x32, 0x33, 0x36, 0x37, 0x3a, + 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x42, 0x43, 0x45, + 0x46, 0x47, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, + 0x4f, 0x52, 0x53, 0x54, 0x56, 0x57, 0x58, 0x59, + 0x5a, 0x5b, 0x5e, 0x5f, 0x61, 0x62, 0x63, 0x65, + 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, 0x6e, 0x70, + 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, 0x7a, 0x7b, + 0x7d, 0x00, 0x01, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0c, 0x0e, 0x10, 0x12, 0x13, 0x14, + 0x15, 0x18, 0x19, 0x1b, 0x1c, 0x1d, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x25, 0x28, 0x2a, 0x33, 0x34, + 0x35, 0x37, 0x38, 0x39, 0x3b, 0x3c, 0x3d, 0x3e, + 0x3f, 0x40, 0x41, 0x43, 0x44, 0x46, 0x47, 0x48, + 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x50, 0x51, 0x53, + 0x54, 0x55, 0x59, 0x5a, 0x5b, 0x5c, 0x60, 0x65, + 0x66, 0x67, 0x69, 0x6c, 0x6d, 0x6f, 0x73, 0x75, + 0x76, 0x77, 0x78, 0x79, 0x7c, 0x81, 0x82, 0x83, + 0x84, 0x85, 0x88, 0x89, 0x8b, 0x8c, 0x8d, 0x8f, + 0x90, 0x91, + /* 0xa0 */ + 0x00, 0x01, 0x02, 0x03, 0x06, 0x0a, 0x0b, 0x0c, + 0x0d, 0x0e, 0x0f, 0x12, 0x13, 0x15, 0x17, 0x19, + 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x21, 0x22, + 0x23, 0x24, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, + 0x2d, 0x2e, 0x2f, 0x31, 0x32, 0x33, 0x35, 0x36, + 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, + 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, + 0x47, 0x4a, 0x4b, 0x4d, 0x4e, 0x4f, 0x51, 0x53, + 0x54, 0x55, 0x56, 0x57, 0x5a, 0x5c, 0x5f, 0x60, + 0x61, 0x62, 0x63, 0x66, 0x67, 0x69, 0x6a, 0x6b, + 0x6d, 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, 0x76, + 0x78, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x07, + 0x08, 0x09, 0x0b, 0x0c, 0x0d, 0x0f, 0x10, 0x11, + 0x12, 0x13, 0x14, 0x15, 0x18, 0x19, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x23, 0x24, 0x25, 0x26, + 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, + 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, + 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x40, + 0x41, 0x43, 0x44, 0x45, 0x47, 0x49, 0x4a, 0x4b, + 0x4c, 0x4d, 0x50, 0x52, 0x56, 0x57, 0x58, 0x5c, + 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x63, 0x64, 0x65, + 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6c, 0x6e, 0x70, + 0x71, 0x72, +}; + +static int +uhc_1_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0x81 && c1 <= 0xa0)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x41 && c2 < 0x5b) || (c2 >= 0x61 && c2 < 0x7b) || (c2 >= 0x81 && c2 < 0xff)) { + unsigned int row = c1 - 0x81; + unsigned int col = c2 - (c2 >= 0x81 ? 0x4d : c2 >= 0x61 ? 0x47 : 0x41); + unsigned int i = 178 * row + col; + if (i < 5696) { + *pwc = (ucs4_t) (uhc_1_2uni_main_page81[2*row+(col>=89?1:0)] + uhc_1_2uni_page81[i]); + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short uhc_1_2charset_main[45] = { + 0x8141, 0x81cd, 0x829b, 0x8363, 0x83e9, 0x84b7, 0x8585, 0x8647, + 0x86d3, 0x87a1, 0x8869, 0x88ef, 0x89bd, 0x8a8b, 0x8b4d, 0x8bd9, + 0x8ca7, 0x8d6f, 0x8df5, 0x8ec3, 0x8f91, 0x9053, 0x90df, 0x91ad, + 0x9275, 0x92fb, 0x93c9, 0x9497, 0x9559, 0x95e5, 0x96b3, 0x9781, + 0x9843, 0x98cf, 0x999d, 0x9a65, 0x9aeb, 0x9bb9, 0x9c87, 0x9d49, + 0x9dd5, 0x9ea3, 0x9f6b, 0x9ff1, 0xa0bf, +}; +static const unsigned char uhc_1_2charset[5696] = { + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, + 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, + 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, + 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, + 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, + 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, + 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, + 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, 0x8a, 0x8b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, + 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, + 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, + 0x8a, 0x8b, 0x8c, 0x8d, 0x94, 0x95, 0x96, 0x97, + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, + 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, 0x62, 0x63, 0xa6, 0xa7, 0xa8, 0xa9, + 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, 0xb0, 0xb1, + 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, 0xb8, 0xb9, + 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, 0xc6, 0xc7, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, + 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, + 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, + 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, + 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, + 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, + 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, + 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, + 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, + 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x58, 0x59, + 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, + 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, + 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, + 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, + 0x90, 0x91, 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, + 0x9e, 0x9f, 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, + 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, + 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, 0x90, 0x91, + 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, 0x98, 0x99, + 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, 0xa0, 0xa1, + 0xa2, 0xa3, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, + 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, + 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, + 0x78, 0x79, 0xbc, 0xbd, 0xbe, 0xbf, 0xc0, 0xc1, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, + 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, + 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, + 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, + 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, + 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, + 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, + 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, 0x8a, 0x8b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x6e, 0x6f, 0x70, 0x71, + 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, + 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, + 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, 0x8e, 0x8f, + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, + 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, + 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0xa0, 0xa1, + 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, 0xa8, 0xa9, + 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, 0xb0, 0xb1, + 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, 0xb8, 0xb9, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, + 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, + 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, + 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, + 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, + 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, + 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, + 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, + 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, + 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, + 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, + 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, + 0x6a, 0x6b, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, + 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, + 0x88, 0x89, 0x8a, 0x8b, 0x92, 0x93, 0x94, 0x95, + 0x96, 0x97, 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, + 0x9e, 0x9f, 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, + 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, + 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, + 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, 0x90, 0x91, + 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, 0x98, 0x99, + 0x9a, 0x9b, 0x9c, 0x9d, 0xa4, 0xa5, 0xa6, 0xa7, + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, + 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, + 0x70, 0x71, 0x72, 0x73, 0xb6, 0xb7, 0xb8, 0xb9, + 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, 0xc0, 0xc1, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, + 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, + 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, + 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, + 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, + 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, + 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, + 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, 0x8a, 0x8b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x68, 0x69, + 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, + 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, + 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, + 0xa0, 0xa1, 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, + 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, 0xa0, 0xa1, + 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, 0xa8, 0xa9, + 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, 0xb0, 0xb1, + 0xb2, 0xb3, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, + 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, + 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, + 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, + 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, + 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, + 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, + 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, + 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, + 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, + 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, + 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, + 0x62, 0x63, 0x64, 0x65, 0x6c, 0x6d, 0x6e, 0x6f, + 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, + 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x8c, 0x8d, + 0x8e, 0x8f, 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, + 0x96, 0x97, 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, + 0x9e, 0x9f, 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, + 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, + 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x7e, 0x7f, 0x80, 0x81, + 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, + 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, 0x90, 0x91, + 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, 0x9e, 0x9f, + 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, + 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0xb0, 0xb1, + 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, 0xb8, 0xb9, + 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, 0xc0, 0xc1, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, + 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, + 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, + 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, + 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, + 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, + 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, + 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, 0x8a, 0x8b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, + 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, + 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, + 0x7a, 0x7b, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, + 0x98, 0x99, 0x9a, 0x9b, 0xa2, 0xa3, 0xa4, 0xa5, + 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, + 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x94, 0x95, 0x96, 0x97, 0x98, 0x99, + 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, 0xa0, 0xa1, + 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, 0xa8, 0xa9, + 0xaa, 0xab, 0xac, 0xad, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, + 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, + 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, + 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, + 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, + 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, + 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, + 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, + 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, + 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, + 0x00, 0x01, 0x02, 0x03, 0x46, 0x47, 0x48, 0x49, + 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, + 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, + 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x66, 0x67, + 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, + 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, + 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, + 0x86, 0x87, 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, + 0x8e, 0x8f, 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, + 0x96, 0x97, 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, + 0x9e, 0x9f, 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, + 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, + 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x78, 0x79, + 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, + 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, + 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, 0x90, 0x91, + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, + 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, + 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, 0xb0, 0xb1, + 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, 0xb8, 0xb9, + 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, 0xc0, 0xc1, + 0x00, 0x01, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x28, 0x29, 0x2a, 0x2b, + 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, + 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, + 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, + 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, + 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, + 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, + 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, + 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, 0x8a, 0x8b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, + 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, + 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, + 0x72, 0x73, 0x74, 0x75, 0x7c, 0x7d, 0x7e, 0x7f, + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x9c, 0x9d, + 0x9e, 0x9f, 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, + 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, + 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x8e, 0x8f, 0x90, 0x91, + 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, 0x98, 0x99, + 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, 0xa0, 0xa1, + 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, + 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, + 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, + 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, 0xc0, 0xc1, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, + 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, + 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, + 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, + 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, + 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, + 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, + 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, 0x8a, 0x8b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, + 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, + 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, + 0x8a, 0x8b, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, + 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, + 0xa8, 0xa9, 0xaa, 0xab, 0xb2, 0xb3, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, 0xa4, 0xa5, 0xa6, 0xa7, 0xa8, 0xa9, + 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, 0xb0, 0xb1, + 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, 0xb8, 0xb9, + 0xba, 0xbb, 0xbc, 0xbd, 0xc4, 0xc5, 0xc6, 0xc7, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, + 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, + 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, + 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, + 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, + 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, + 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, + 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, + 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, + 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x56, 0x57, 0x58, 0x59, + 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, + 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, + 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, 0x76, 0x77, + 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, + 0x96, 0x97, 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, + 0x9e, 0x9f, 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, + 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, + 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x88, 0x89, + 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, 0x90, 0x91, + 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, 0x98, 0x99, + 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, 0xa0, 0xa1, + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, + 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, + 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, + 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, 0xc0, 0xc1, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, + 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, + 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, + 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, + 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, + 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, + 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, + 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, 0x8a, 0x8b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, + 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, + 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, 0x80, 0x81, + 0x82, 0x83, 0x84, 0x85, 0x8c, 0x8d, 0x8e, 0x8f, + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, + 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xac, 0xad, + 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, + 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, + 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, + 0x58, 0x59, 0x5a, 0x5b, 0x9e, 0x9f, 0xa0, 0xa1, + 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, 0xa8, 0xa9, + 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, 0xb0, 0xb1, + 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, + 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, + 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, + 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, + 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, 0x5c, 0x5d, + 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, + 0x66, 0x67, 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, + 0x6e, 0x6f, 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, + 0x76, 0x77, 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, + 0x7e, 0x7f, 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x50, 0x51, + 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, + 0x5a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, + 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, + 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, + 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, + 0x88, 0x89, 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, + 0x96, 0x97, 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, + 0x9e, 0x9f, 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, + 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, + 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, + 0xb6, 0xb7, 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, + 0xbe, 0xbf, 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, +}; + +static const Summary16 uhc_1_uni2indx_pageac[459] = { + /* 0xac00 */ + { 0, 0xf86c }, { 9, 0xc100 }, { 12, 0x4fee }, { 23, 0xecfc }, + { 34, 0xd7fe }, { 47, 0xeeef }, { 60, 0xffff }, { 76, 0xfa6c }, + { 86, 0xe184 }, { 92, 0x4fee }, { 103, 0x68fc }, { 112, 0xc4fe }, + { 122, 0xeeed }, { 134, 0xff5f }, { 148, 0x6a6c }, { 156, 0xcf94 }, + /* 0xad00 */ + { 165, 0x4fae }, { 175, 0xeefd }, { 188, 0xcdfe }, { 200, 0xeecf }, + { 212, 0xfd4f }, { 224, 0xfeee }, { 237, 0xcff5 }, { 249, 0x4786 }, + { 256, 0xecf9 }, { 267, 0xcffe }, { 280, 0xffef }, { 295, 0xff7f }, + { 310, 0xfeec }, { 322, 0xeff4 }, { 334, 0xffee }, { 348, 0x6cff }, + /* 0xae00 */ + { 360, 0xd4fc }, { 370, 0xffef }, { 385, 0xffff }, { 401, 0xfa6c }, + { 411, 0x8b94 }, { 418, 0x4fae }, { 428, 0xecdc }, { 438, 0xc4fe }, + { 448, 0xefcf }, { 461, 0xffff }, { 477, 0xffff }, { 493, 0x8fff }, + { 506, 0x4fee }, { 517, 0xecfc }, { 528, 0xd6ff }, { 541, 0xeeef }, + /* 0xaf00 */ + { 554, 0xde7f }, { 567, 0xfffe }, { 582, 0xcfff }, { 596, 0x4fea }, + { 606, 0xfcf1 }, { 617, 0xcffe }, { 630, 0xffcf }, { 644, 0xfdff }, + { 659, 0xfeee }, { 672, 0xefdc }, { 684, 0xffff }, { 700, 0xecff }, + { 713, 0x947e }, { 722, 0xefef }, { 736, 0xfcff }, { 750, 0xfeec }, + /* 0xb000 */ + { 762, 0xefec }, { 774, 0xcfee }, { 786, 0xfeff }, { 801, 0xffff }, + { 817, 0xaacf }, { 827, 0xdd47 }, { 837, 0xffff }, { 853, 0xcfff }, + { 867, 0x4fee }, { 878, 0x68fd }, { 888, 0x04f8 }, { 894, 0xeec5 }, + { 904, 0xfc4f }, { 915, 0xfeec }, { 927, 0xffde }, { 941, 0xffff }, + /* 0xb100 */ + { 957, 0xe4ff }, { 969, 0xc4f2 }, { 977, 0xeec7 }, { 988, 0xfc4f }, + { 999, 0xfeec }, { 1011, 0xeecc }, { 1021, 0xfffe }, { 1036, 0xecff }, + { 1049, 0xd4fa }, { 1059, 0xeee3 }, { 1070, 0xfeff }, { 1085, 0xffff }, + { 1101, 0xefff }, { 1116, 0x4fee }, { 1127, 0xecff }, { 1140, 0xd5fe }, + /* 0xb200 */ + { 1152, 0xe6cf }, { 1163, 0xfd4f }, { 1175, 0xfffe }, { 1190, 0xefef }, + { 1204, 0xffff }, { 1220, 0xeeff }, { 1234, 0xfcfe }, { 1247, 0xefcf }, + { 1260, 0xfdcf }, { 1273, 0xf8ec }, { 1283, 0xeb94 }, { 1292, 0xffee }, + { 1306, 0xecff }, { 1319, 0xd4fa }, { 1329, 0x068b }, { 1335, 0x7047 }, + /* 0xb300 */ + { 1342, 0xfeec }, { 1354, 0xefc4 }, { 1364, 0xffff }, { 1380, 0xffff }, + { 1396, 0xffff }, { 1412, 0x268f }, { 1420, 0xb54f }, { 1430, 0xfeec }, + { 1442, 0xefc4 }, { 1452, 0xffee }, { 1466, 0xeefc }, { 1478, 0xffff }, + { 1494, 0xa6cf }, { 1504, 0xd54e }, { 1513, 0xfeee }, { 1526, 0xefff }, + /* 0xb400 */ + { 1541, 0xffff }, { 1557, 0xeefe }, { 1570, 0xf4fe }, { 1582, 0xffef }, + { 1597, 0xffff }, { 1613, 0xfeec }, { 1625, 0xefd4 }, { 1636, 0xffff }, + { 1652, 0xfefe }, { 1666, 0xdfff }, { 1681, 0xeeef }, { 1694, 0xfd5f }, + { 1707, 0xfeee }, { 1720, 0xcfde }, { 1732, 0x4fa6 }, { 1741, 0xfefd }, + /* 0xb500 */ + { 1755, 0xffff }, { 1771, 0xe6cf }, { 1782, 0xf84f }, { 1792, 0xfeec }, + { 1804, 0xc7c4 }, { 1812, 0x4fee }, { 1823, 0xfffc }, { 1837, 0xffff }, + { 1853, 0xffff }, { 1869, 0xffff }, { 1885, 0xf2ec }, { 1895, 0xc7c4 }, + { 1903, 0x4fee }, { 1914, 0xfefc }, { 1927, 0xefff }, { 1942, 0xffff }, + /* 0xb600 */ + { 1958, 0xffff }, { 1974, 0xfeec }, { 1986, 0xefdf }, { 2000, 0xffef }, + { 2015, 0xfeff }, { 2030, 0xffff }, { 2046, 0xfeef }, { 2060, 0xffff }, + { 2076, 0xffff }, { 2092, 0xcfff }, { 2106, 0xe7ee }, { 2118, 0xfffd }, + { 2133, 0xffff }, { 2149, 0xffef }, { 2164, 0xffff }, { 2180, 0xfeee }, + /* 0xb700 */ + { 2193, 0xffdc }, { 2206, 0xffff }, { 2222, 0x6cff }, { 2234, 0xf4fe }, + { 2246, 0xeeef }, { 2259, 0xffcf }, { 2273, 0xfeee }, { 2286, 0xcfd4 }, + { 2296, 0x4fee }, { 2307, 0xec38 }, { 2315, 0xc4fe }, { 2325, 0xfecf }, + { 2338, 0xfd7f }, { 2352, 0xffff }, { 2368, 0xcfff }, { 2382, 0x4fee }, + /* 0xb800 */ + { 2393, 0xec7c }, { 2403, 0xd4fe }, { 2414, 0xeecf }, { 2426, 0xfc4f }, + { 2437, 0xffee }, { 2451, 0xcff5 }, { 2463, 0x4fee }, { 2474, 0xeefd }, + { 2487, 0xdfff }, { 2502, 0xffff }, { 2518, 0xfeff }, { 2533, 0xfeee }, + { 2546, 0xefd4 }, { 2557, 0x5fee }, { 2569, 0xecfd }, { 2581, 0xd4fe }, + /* 0xb900 */ + { 2592, 0xffef }, { 2607, 0xfeff }, { 2622, 0xfffe }, { 2637, 0xcfff }, + { 2651, 0x6fee }, { 2663, 0xecfd }, { 2675, 0xd4fe }, { 2686, 0xeecf }, + { 2698, 0x994f }, { 2707, 0xffff }, { 2723, 0xcfff }, { 2737, 0x4fee }, + { 2748, 0x2cfd }, { 2758, 0x94f8 }, { 2766, 0xeec5 }, { 2776, 0xf84f }, + /* 0xba00 */ + { 2786, 0xfefc }, { 2799, 0xffdf }, { 2814, 0xffff }, { 2830, 0xecff }, + { 2843, 0x94fa }, { 2852, 0xeec7 }, { 2863, 0xfc4f }, { 2874, 0xfeec }, + { 2886, 0xef47 }, { 2897, 0xffff }, { 2913, 0xe4ff }, { 2925, 0xd4fa }, + { 2935, 0xfeef }, { 2949, 0xfcff }, { 2963, 0xffff }, { 2979, 0xefff }, + /* 0xbb00 */ + { 2994, 0x5fee }, { 3006, 0xeefd }, { 3019, 0xf5fe }, { 3032, 0x868f }, + { 3040, 0x5d4f }, { 3050, 0xfeee }, { 3063, 0xeff5 }, { 3076, 0xffff }, + { 3092, 0xeeff }, { 3106, 0xfffe }, { 3121, 0xeeef }, { 3134, 0xff6f }, + { 3148, 0xfeee }, { 3161, 0xfff6 }, { 3175, 0xffff }, { 3191, 0x6cff }, + /* 0xbc00 */ + { 3203, 0x44fa }, { 3211, 0x060d }, { 3216, 0xdd4f }, { 3227, 0xfeec }, + { 3239, 0xcdc4 }, { 3247, 0xdffe }, { 3261, 0xffff }, { 3277, 0xffff }, + { 3293, 0xa6cf }, { 3303, 0xf94f }, { 3314, 0xfe6c }, { 3325, 0xcfc4 }, + { 3334, 0x5fee }, { 3346, 0xeedc }, { 3357, 0xffff }, { 3373, 0xee8f }, + /* 0xbd00 */ + { 3384, 0xfd4f }, { 3396, 0xffee }, { 3410, 0xefef }, { 3424, 0xffff }, + { 3440, 0xecfe }, { 3452, 0xfcfe }, { 3465, 0xfeef }, { 3479, 0xffff }, + { 3495, 0xf86c }, { 3504, 0xe9d4 }, { 3513, 0xffef }, { 3528, 0xfefe }, + { 3542, 0xffff }, { 3558, 0xeecf }, { 3570, 0xfdff }, { 3585, 0xfeee }, + /* 0xbe00 */ + { 3598, 0xcfd6 }, { 3609, 0x4fee }, { 3620, 0xffff }, { 3636, 0xffff }, + { 3652, 0xaecf }, { 3663, 0xf14f }, { 3673, 0xfaec }, { 3684, 0xc7c4 }, + { 3692, 0x4fee }, { 3703, 0xfcfc }, { 3715, 0xfeff }, { 3730, 0xffff }, + { 3746, 0xffff }, { 3762, 0xfe6c }, { 3773, 0xefc6 }, { 3784, 0xffff }, + /* 0xbf00 */ + { 3800, 0xfcfd }, { 3813, 0xc4ff }, { 3824, 0xffff }, { 3840, 0xffff }, + { 3856, 0xfeec }, { 3868, 0xffdc }, { 3881, 0xffff }, { 3897, 0xffff }, + { 3913, 0xffff }, { 3929, 0xffef }, { 3944, 0xffff }, { 3960, 0xfffe }, + { 3975, 0xcfdf }, { 3988, 0x6fee }, { 4000, 0xfffd }, { 4015, 0xffff }, + /* 0xc000 */ + { 4031, 0xffff }, { 4047, 0xffff }, { 4063, 0xffff }, { 4079, 0xefff }, + { 4094, 0xffff }, { 4110, 0xeefd }, { 4123, 0xfcfe }, { 4136, 0xffff }, + { 4152, 0xffff }, { 4168, 0xfeec }, { 4180, 0x4fd4 }, { 4189, 0x4f86 }, + { 4197, 0xecdc }, { 4207, 0xc4fe }, { 4217, 0xeecf }, { 4229, 0xfd4f }, + /* 0xc100 */ + { 4241, 0xfeee }, { 4254, 0x0fde }, { 4264, 0x4f26 }, { 4272, 0xecbc }, + { 4282, 0xc4fe }, { 4292, 0xeecf }, { 4304, 0xfc4f }, { 4315, 0xfeee }, + { 4328, 0x8fdf }, { 4340, 0x4fae }, { 4350, 0xecdd }, { 4361, 0xdffe }, + { 4375, 0xeeef }, { 4388, 0xfe6f }, { 4401, 0xfeee }, { 4414, 0xcff4 }, + /* 0xc200 */ + { 4425, 0x4fee }, { 4436, 0x6cfd }, { 4447, 0x54fe }, { 4457, 0xffe9 }, + { 4470, 0xfeff }, { 4485, 0xfeec }, { 4497, 0xcfde }, { 4509, 0x4fee }, + { 4520, 0xfcfd }, { 4533, 0xd6fe }, { 4545, 0xcecf }, { 4556, 0xfd4f }, + { 4568, 0xffff }, { 4584, 0xcfff }, { 4598, 0x47e6 }, { 4607, 0xe4bd }, + /* 0xc300 */ + { 4617, 0xccfe }, { 4628, 0xeec7 }, { 4639, 0xfccf }, { 4651, 0xffff }, + { 4667, 0xffdf }, { 4682, 0xffff }, { 4698, 0xecff }, { 4711, 0xccfa }, + { 4721, 0xeeef }, { 4734, 0xffff }, { 4750, 0xffff }, { 4766, 0xffff }, + { 4782, 0xfffe }, { 4797, 0x6cff }, { 4809, 0xdcfa }, { 4820, 0xfecf }, + /* 0xc400 */ + { 4833, 0xfeff }, { 4848, 0xfffe }, { 4863, 0xefef }, { 4877, 0xcfee }, + { 4889, 0xfeff }, { 4904, 0xffff }, { 4920, 0xeecf }, { 4932, 0xfdcf }, + { 4945, 0xfffe }, { 4960, 0xefef }, { 4974, 0xffff }, { 4990, 0xeeff }, + { 5004, 0xffff }, { 5020, 0xffff }, { 5036, 0xfdff }, { 5051, 0x7aec }, + /* 0xc500 */ + { 5061, 0xeffc }, { 5074, 0xefee }, { 5087, 0xecff }, { 5100, 0xd4fe }, + { 5111, 0x88cf }, { 5119, 0x9c47 }, { 5127, 0xfeec }, { 5139, 0xcfc4 }, + { 5148, 0x4f6e }, { 5158, 0xee5d }, { 5169, 0xfdfe }, { 5183, 0x84cf }, + { 5191, 0xa80f }, { 5198, 0xfeec }, { 5210, 0x8fd4 }, { 5219, 0x0f2e }, + /* 0xc600 */ + { 5227, 0xee1c }, { 5236, 0xe4fe }, { 5247, 0x8ecf }, { 5257, 0xf546 }, + { 5266, 0xfeec }, { 5278, 0xcfc4 }, { 5287, 0x6ffe }, { 5300, 0xecfd }, + { 5312, 0xd4fe }, { 5323, 0xeecf }, { 5335, 0xfd4f }, { 5347, 0xf8ec }, + { 5357, 0xcfd4 }, { 5367, 0xcfee }, { 5379, 0xecfc }, { 5390, 0xdcfe }, + /* 0xc700 */ + { 5402, 0xeecf }, { 5414, 0xfd4f }, { 5426, 0xfeec }, { 5438, 0xcf54 }, + { 5447, 0x4bee }, { 5457, 0xee01 }, { 5464, 0xf6fe }, { 5477, 0x8ecf }, + { 5487, 0xb847 }, { 5495, 0xfa2c }, { 5504, 0xcf84 }, { 5512, 0x4fee }, + { 5523, 0xacfc }, { 5533, 0xdefe }, { 5546, 0xeeef }, { 5559, 0xffff }, + /* 0xc800 */ + { 5575, 0xfaec }, { 5586, 0xcf94 }, { 5595, 0x4fee }, { 5606, 0xeefd }, + { 5619, 0xccfe }, { 5630, 0xffef }, { 5645, 0xffff }, { 5661, 0xfaec }, + { 5672, 0xc714 }, { 5679, 0x5fef }, { 5692, 0x001d }, +}; + +static int +uhc_1_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + if (wc >= 0xac00 && wc < 0xc8b0) { + const Summary16 *summary = &uhc_1_uni2indx_pageac[(wc>>4)-0xac0]; + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + used += summary->indx; + c = uhc_1_2charset_main[used>>7] + uhc_1_2charset[used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/uhc_2.h b/graf2d/win32gdk/gdk/src/iconv/uhc_2.h new file mode 100644 index 0000000000000..4aa290a943b32 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/uhc_2.h @@ -0,0 +1,1022 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * Unified Hangul Code part 2 + */ + +static const unsigned short uhc_2_2uni_main_pagea1[76] = { + 0xc8a5, 0xc8d8, 0xc910, 0xc93e, 0xc971, 0xc9a5, 0xc9de, 0xca1c, + 0xca47, 0xca7b, 0xcaa8, 0xcadd, 0xcb0b, 0xcb3a, 0xcb6d, 0xcb99, + 0xcbc5, 0xcbf3, 0xcc25, 0xcc67, 0xcc94, 0xcccf, 0xccfe, 0xcd34, + 0xcd61, 0xcd92, 0xcdc6, 0xcdf5, 0xce2c, 0xce5d, 0xce9a, 0xcecc, + 0xcf02, 0xcf3b, 0xcf6d, 0xcf9e, 0xcfcc, 0xcfff, 0xd02e, 0xd064, + 0xd095, 0xd0cc, 0xd105, 0xd132, 0xd16e, 0xd19b, 0xd1d0, 0xd1fd, + 0xd22a, 0xd25e, 0xd28d, 0xd2c5, 0xd2fb, 0xd33e, 0xd36a, 0xd3a1, + 0xd3d7, 0xd40d, 0xd438, 0xd467, 0xd49e, 0xd4c9, 0xd4fe, 0xd52e, + 0xd564, 0xd59d, 0xd5ca, 0xd606, 0xd63d, 0xd677, 0xd6ab, 0xd6e2, + 0xd715, 0xd74e, 0xd78d, 0xfffd, +}; +static const unsigned char uhc_2_2uni_pagea1[3126] = { + /* 0xa1 */ + 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, 0x07, 0x08, + 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x19, 0x1a, + 0x1b, 0x1c, 0x1d, 0x1e, 0x20, 0x21, 0x22, 0x24, + 0x25, 0x26, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x31, 0x00, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x0a, 0x0b, 0x0d, 0x0e, 0x0f, 0x10, 0x11, + 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, + 0x1a, 0x1b, 0x1c, 0x1e, 0x1f, 0x20, 0x21, 0x22, + 0x23, 0x26, 0x27, 0x29, 0x2a, 0x2b, 0x2f, 0x30, + 0x31, 0x32, 0x33, 0x36, + /* 0xa2 */ + 0x00, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x09, + 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, + 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, + 0x1a, 0x1b, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, + 0x23, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, + 0x2c, 0x2d, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x14, 0x15, 0x17, 0x18, + 0x19, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, + 0x24, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, + 0x2d, 0x2f, 0x30, 0x31, + /* 0xa3 */ + 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, 0x07, 0x08, + 0x09, 0x0a, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, + 0x12, 0x13, 0x14, 0x15, 0x16, 0x19, 0x1a, 0x1c, + 0x1d, 0x1e, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x29, 0x2b, 0x2d, 0x2e, 0x2f, 0x30, 0x31, + 0x32, 0x33, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1d, 0x1e, 0x20, + 0x21, 0x24, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2d, + 0x2f, 0x32, 0x33, 0x36, + /* 0xa4 */ + 0x00, 0x01, 0x03, 0x05, 0x07, 0x08, 0x0a, 0x0b, + 0x0c, 0x0d, 0x10, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1c, 0x1d, 0x1f, 0x20, 0x21, 0x23, 0x24, + 0x25, 0x26, 0x27, 0x28, 0x29, 0x2c, 0x30, 0x31, + 0x32, 0x33, 0x34, 0x35, 0x37, 0x38, 0x39, 0x3b, + 0x3c, 0x3d, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0e, + 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, + 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, + 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, + 0x27, 0x28, 0x29, 0x2a, + /* 0xa5 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x07, 0x08, 0x0a, + 0x0b, 0x0c, 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, + 0x14, 0x17, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, + 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, + 0x32, 0x33, 0x00, 0x01, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, + /* 0xa6 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x16, 0x17, 0x19, 0x1a, + 0x1b, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, + 0x26, 0x28, 0x2a, 0x2c, 0x2d, 0x2e, 0x2f, 0x32, + 0x33, 0x34, 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2c, 0x2d, + /* 0xa7 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x06, 0x07, 0x08, + 0x0a, 0x0b, 0x0c, 0x0e, 0x0f, 0x10, 0x11, 0x12, + 0x13, 0x14, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, + 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, + 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, + 0x2d, 0x2e, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x10, + 0x11, 0x13, 0x14, 0x15, 0x17, 0x18, 0x19, 0x1a, + 0x1b, 0x1c, 0x1d, 0x20, 0x21, 0x22, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2b, 0x2c, 0x2d, 0x2e, + 0x2f, 0x30, 0x31, 0x32, + /* 0xa8 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0d, 0x0e, 0x0f, 0x10, 0x11, + 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, + 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, + 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, + 0x2a, 0x2b, 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, + 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, + 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, + /* 0xa9 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x20, 0x21, + 0x23, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, + 0x2c, 0x2d, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x1b, 0x1c, 0x1e, 0x1f, 0x20, + 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x2b, + 0x2c, 0x2d, 0x30, 0x31, + /* 0xaa */ + 0x00, 0x01, 0x05, 0x06, 0x08, 0x0a, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x15, 0x1a, 0x1b, + 0x1c, 0x1d, 0x1e, 0x21, 0x22, 0x24, 0x25, 0x26, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x31, + 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3c, 0x3d, + 0x3e, 0x40, 0x00, 0x02, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x0a, 0x0b, 0x0c, 0x0d, 0x0f, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, + /* 0xab */ + 0x00, 0x01, 0x02, 0x03, 0x06, 0x07, 0x09, 0x0a, + 0x0b, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, + 0x16, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x22, + 0x23, 0x25, 0x26, 0x27, 0x29, 0x2a, 0x2b, 0x2c, + 0x2d, 0x2e, 0x2f, 0x32, 0x34, 0x36, 0x37, 0x38, + 0x39, 0x3a, 0x00, 0x02, 0x03, 0x04, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1e, 0x1f, 0x20, 0x22, + 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, + 0x2b, 0x2c, 0x2d, 0x2e, + /* 0xac */ + 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, 0x07, 0x08, + 0x09, 0x0c, 0x0d, 0x0f, 0x10, 0x11, 0x13, 0x14, + 0x15, 0x16, 0x17, 0x18, 0x19, 0x1c, 0x1e, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x27, 0x28, 0x29, + 0x2b, 0x2c, 0x2d, 0x2f, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x35, 0x00, 0x01, 0x02, 0x03, 0x04, 0x06, + 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, + 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, + 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, + 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, + 0x27, 0x29, 0x2a, 0x2b, + /* 0xad */ + 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, 0x07, 0x08, + 0x09, 0x0a, 0x0d, 0x0f, 0x11, 0x12, 0x13, 0x14, + 0x15, 0x16, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, + 0x2f, 0x30, 0x00, 0x01, 0x04, 0x05, 0x07, 0x08, + 0x09, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, + 0x14, 0x16, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, + 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, + 0x2f, 0x30, 0x31, 0x33, + /* 0xae */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x07, 0x08, + 0x09, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, + 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, + 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, + 0x23, 0x24, 0x25, 0x27, 0x28, 0x29, 0x2b, 0x2c, + 0x2d, 0x2e, 0x00, 0x01, 0x02, 0x05, 0x07, 0x09, + 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x10, 0x11, 0x12, + 0x14, 0x15, 0x16, 0x18, 0x19, 0x1a, 0x1b, 0x1c, + 0x1d, 0x1e, 0x20, 0x21, 0x22, 0x23, 0x25, 0x26, + 0x27, 0x28, 0x29, 0x2a, 0x2d, 0x2e, 0x30, 0x31, + 0x32, 0x34, 0x35, 0x36, + /* 0xaf */ + 0x00, 0x01, 0x02, 0x03, 0x06, 0x08, 0x0a, 0x0b, + 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, + 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, + 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, + 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, + 0x2e, 0x2f, 0x00, 0x01, 0x05, 0x06, 0x07, 0x08, + 0x09, 0x0a, 0x0d, 0x0f, 0x11, 0x12, 0x13, 0x14, + 0x15, 0x16, 0x19, 0x1a, 0x1c, 0x1d, 0x1e, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x29, 0x2b, + 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x35, 0x36, + 0x38, 0x39, 0x3a, 0x3c, + /* 0xb0 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x08, 0x0c, + 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x14, 0x15, 0x16, + 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, + 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x1a, 0x1b, 0x1d, 0x1e, 0x21, 0x22, + 0x23, 0x24, 0x25, 0x26, 0x27, 0x2a, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, + /* 0xb1 */ + 0x00, 0x01, 0x03, 0x04, 0x05, 0x07, 0x08, 0x09, + 0x0a, 0x0b, 0x0c, 0x0d, 0x10, 0x12, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1b, 0x1c, 0x1d, 0x1f, + 0x20, 0x21, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2c, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x37, 0x38, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x1b, 0x1c, 0x1e, 0x1f, 0x20, + 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x2b, + 0x2d, 0x2f, 0x30, 0x31, + /* 0xb2 */ + 0x00, 0x01, 0x02, 0x05, 0x06, 0x08, 0x09, 0x0a, + 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x14, + 0x15, 0x16, 0x17, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, + 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, + 0x2f, 0x30, 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x27, 0x28, 0x29, + 0x2a, 0x2b, 0x2c, 0x2d, + /* 0xb3 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x16, 0x17, 0x19, 0x1a, + 0x1b, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, + 0x26, 0x28, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x31, 0x32, 0x00, 0x02, 0x03, 0x04, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, + 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, + 0x2a, 0x2b, 0x2c, 0x2d, + /* 0xb4 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x08, 0x09, + 0x0b, 0x0c, 0x0d, 0x0f, 0x10, 0x11, 0x12, 0x13, + 0x14, 0x15, 0x18, 0x1a, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x23, 0x24, 0x25, 0x27, 0x28, 0x29, + 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x33, + 0x34, 0x35, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x07, 0x0a, 0x0b, 0x0d, 0x0e, 0x0f, 0x11, + 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x1a, 0x1b, + 0x1c, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, + 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, + 0x2d, 0x2e, 0x2f, 0x30, + /* 0xb5 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x11, + 0x12, 0x14, 0x15, 0x16, 0x18, 0x19, 0x1a, 0x1b, + 0x1c, 0x1d, 0x1e, 0x21, 0x23, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2d, 0x2e, 0x30, 0x31, 0x32, + 0x35, 0x36, 0x00, 0x01, 0x02, 0x03, 0x06, 0x0a, + 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x12, 0x13, 0x15, + 0x16, 0x17, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, + 0x1f, 0x22, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, + 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, + 0x35, 0x36, 0x37, 0x38, + /* 0xb6 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x00, 0x01, 0x03, 0x04, 0x05, 0x07, + 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x10, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1c, 0x1d, 0x1f, 0x20, + 0x21, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, + 0x2c, 0x2e, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x37, 0x38, 0x39, 0x3b, + /* 0xb7 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0f, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x17, 0x18, 0x19, + 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, + 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, + 0x2b, 0x2c, 0x00, 0x01, 0x02, 0x03, 0x04, 0x07, + 0x08, 0x0a, 0x0b, 0x0c, 0x0e, 0x0f, 0x10, 0x11, + 0x12, 0x13, 0x14, 0x17, 0x19, 0x1b, 0x1c, 0x1d, + 0x1e, 0x20, 0x22, 0x23, 0x24, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, + 0x31, 0x32, 0x33, 0x34, + /* 0xb8 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x25, 0x26, 0x27, 0x29, 0x2a, + 0x2b, 0x2c, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x07, 0x08, 0x09, 0x0b, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, + /* 0xb9 */ + 0x00, 0x01, 0x04, 0x05, 0x07, 0x08, 0x09, 0x0b, + 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x14, 0x16, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, + 0x31, 0x33, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, + 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, + 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, + 0x1f, 0x20, 0x21, 0x24, 0x25, 0x27, 0x28, 0x29, + 0x2b, 0x2c, 0x2d, 0x2e, + /* 0xba */ + 0x00, 0x01, 0x02, 0x05, 0x06, 0x07, 0x09, 0x0a, + 0x0b, 0x0c, 0x0d, 0x0e, 0x10, 0x11, 0x12, 0x14, + 0x15, 0x16, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x20, 0x21, 0x22, 0x23, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2d, 0x2e, 0x30, 0x31, 0x34, + 0x36, 0x37, 0x00, 0x01, 0x02, 0x05, 0x07, 0x08, + 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x10, 0x11, + 0x12, 0x14, 0x15, 0x16, 0x18, 0x19, 0x1a, 0x1b, + 0x1c, 0x1d, 0x1e, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2d, 0x2e, 0x30, + 0x31, 0x32, 0x34, 0x35, + /* 0xbb */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x07, 0x09, 0x0b, + 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x14, 0x16, 0x17, + 0x18, 0x1a, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x23, + 0x27, 0x28, 0x29, 0x2b, 0x2c, 0x2f, 0x30, 0x32, + 0x33, 0x34, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3f, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, + /* 0xbc */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x14, 0x15, 0x17, 0x18, 0x19, 0x1b, + 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x24, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x30, 0x31, 0x33, + 0x34, 0x35, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x09, 0x0b, 0x0d, 0x0e, 0x0f, 0x10, 0x11, + 0x12, 0x14, 0x15, 0x16, 0x18, 0x19, 0x1a, 0x1c, + 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x25, 0x26, + 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x30, 0x31, + 0x32, 0x33, 0x34, 0x35, + /* 0xbd */ + 0x00, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, + 0x09, 0x0b, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, + 0x13, 0x14, 0x17, 0x18, 0x1a, 0x1b, 0x1c, 0x1e, + 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x27, 0x29, + 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x32, 0x33, + 0x34, 0x35, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, + 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, + 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, + 0x27, 0x28, 0x29, 0x2a, + /* 0xbe */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x09, 0x0a, 0x0b, 0x0d, 0x0e, 0x0f, 0x10, 0x11, + 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, + 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, + 0x22, 0x23, 0x25, 0x26, 0x27, 0x29, 0x2a, 0x2b, + 0x2d, 0x2e, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x07, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x13, 0x14, 0x16, 0x17, 0x1a, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x23, 0x25, 0x27, 0x28, 0x29, + 0x2a, 0x2b, 0x2c, 0x2e, 0x2f, 0x30, 0x31, 0x32, + 0x33, 0x34, 0x35, 0x36, + /* 0xbf */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, + 0x08, 0x09, 0x0a, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, + 0x11, 0x12, 0x14, 0x15, 0x17, 0x18, 0x19, 0x1a, + 0x1b, 0x1c, 0x1d, 0x1e, 0x20, 0x21, 0x22, 0x24, + 0x25, 0x26, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x30, 0x31, 0x33, + /* 0xc0 */ + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x07, 0x08, + 0x09, 0x0b, 0x0c, 0x0d, 0x0f, 0x10, 0x11, 0x12, + 0x13, 0x14, 0x15, 0x18, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, + 0x10, 0x11, 0x13, 0x14, 0x15, 0x17, 0x18, 0x19, + 0x1a, 0x1b, 0x1c, 0x1d, 0x20, 0x22, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2c, 0x2d, 0x2f, 0x30, + 0x31, 0x33, 0x34, 0x35, + /* 0xc1 */ + 0x00, 0x02, 0x03, 0x06, 0x08, 0x0a, 0x0b, 0x0c, + 0x0d, 0x0e, 0x0f, 0x12, 0x13, 0x15, 0x16, 0x17, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x22, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2d, 0x2e, + 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, + 0x37, 0x38, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x07, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, + 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, + 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, + 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, + 0x27, 0x28, 0x29, 0x2a, + /* 0xc2 */ + 0x00, 0x01, 0x03, 0x04, 0x05, 0x07, 0x09, 0x0a, + 0x0b, 0x0c, 0x0d, 0x10, 0x12, 0x14, 0x15, 0x16, + 0x17, 0x18, 0x19, 0x1c, 0x1d, 0x1f, 0x20, 0x21, + 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2c, + 0x2e, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x38, + 0x39, 0x3b, 0x00, 0x01, 0x03, 0x04, 0x05, 0x06, + 0x07, 0x08, 0x09, 0x0c, 0x10, 0x11, 0x12, 0x13, + 0x14, 0x15, 0x17, 0x18, 0x19, 0x1b, 0x1c, 0x1d, + 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x34, 0x35, + /* 0xc3 */ + 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, 0x07, 0x09, + 0x0a, 0x0d, 0x0f, 0x11, 0x12, 0x13, 0x15, 0x16, + 0x19, 0x1a, 0x1c, 0x1d, 0x1e, 0x20, 0x21, 0x22, + 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2b, + 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x35, 0x36, + 0x38, 0x39, 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, + 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0d, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x17, 0x18, 0x1a, + 0x1b, 0x1c, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, + 0x24, 0x25, 0x27, 0x29, 0x2b, 0x2c, 0x2d, 0x2e, + 0x2f, 0x30, 0x32, 0x33, + /* 0xc4 */ + 0x00, 0x02, 0x03, 0x04, 0x06, 0x07, 0x08, 0x09, + 0x0a, 0x0b, 0x0c, 0x0d, 0x0f, 0x11, 0x12, 0x13, + 0x14, 0x15, 0x16, 0x17, 0x18, 0x1b, 0x1c, 0x1e, + 0x1f, 0x20, 0x22, 0x23, 0x24, 0x25, 0x27, 0x28, + 0x2a, 0x2b, 0x2d, 0x2f, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x36, 0x00, 0x01, 0x03, 0x04, 0x05, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0f, 0x10, + 0x11, 0x12, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, + 0x1c, 0x1d, 0x1f, 0x20, 0x21, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x30, 0x31, 0x32, + /* 0xc5 */ + 0x00, 0x01, 0x02, 0x05, 0x06, 0x08, 0x09, 0x0a, + 0x0c, 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x15, + 0x17, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x21, + 0x22, 0x24, 0x25, 0x26, 0x28, 0x29, 0x2a, 0x2b, + 0x2c, 0x2d, 0x2e, 0x30, 0x31, 0x33, 0x35, 0x36, + 0x37, 0x38, 0x00, 0x01, 0x04, 0x05, 0x07, 0x0c, + 0x0d, 0x0e, 0x0f, 0x10, 0x11, 0x14, 0x16, 0x18, + 0x19, 0x1a, 0x1c, 0x1d, 0x1f, 0x20, 0x21, 0x23, + 0x24, 0x25, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, + 0x2d, 0x30, 0x31, 0x32, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3c, 0x3d, + /* 0xc6 */ + 0x00, 0x01, 0x02, 0x04, 0x05, 0x06, 0x07, 0x08, + 0x09, 0x0a, 0x0d, 0x0f, 0x11, 0x12, 0x13, 0x14, + 0x15, 0x16, +}; + +static int +uhc_2_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c1 = s[0]; + if ((c1 >= 0xa1 && c1 <= 0xc6)) { + if (n >= 2) { + unsigned char c2 = s[1]; + if ((c2 >= 0x41 && c2 < 0x5b) || (c2 >= 0x61 && c2 < 0x7b) || (c2 >= 0x81 && c2 < 0xa1)) { + unsigned int row = c1 - 0xa1; + unsigned int col = c2 - (c2 >= 0x81 ? 0x4d : c2 >= 0x61 ? 0x47 : 0x41); + unsigned int i = 84 * row + col; + if (i < 3126) { + *pwc = (ucs4_t) (uhc_2_2uni_main_pagea1[2*row+(col>=42?1:0)] + uhc_2_2uni_pagea1[i]); + return 2; + } + } + return RET_ILSEQ; + } + return RET_TOOFEW(0); + } + return RET_ILSEQ; +} + +static const unsigned short uhc_2_2charset_main[49] = { + 0xa141, 0xa18d, 0xa273, 0xa359, 0xa445, 0xa491, 0xa577, 0xa663, + 0xa749, 0xa795, 0xa881, 0xa967, 0xaa4d, 0xaa99, 0xab85, 0xac6b, + 0xad51, 0xad9d, 0xae89, 0xaf6f, 0xb055, 0xb141, 0xb18d, 0xb273, + 0xb359, 0xb445, 0xb491, 0xb577, 0xb663, 0xb749, 0xb795, 0xb881, + 0xb967, 0xba4d, 0xba99, 0xbb85, 0xbc6b, 0xbd51, 0xbd9d, 0xbe89, + 0xbf6f, 0xc055, 0xc141, 0xc18d, 0xc273, 0xc359, 0xc445, 0xc491, + 0xc577, +}; +static const unsigned char uhc_2_2charset[3126] = { + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x28, 0x29, 0x2a, 0x2b, + 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0xe8, 0xe9, 0xea, 0xeb, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0xca, 0xcb, 0xcc, 0xcd, + 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xea, 0xeb, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xcc, 0xcd, + 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, + 0xd8, 0xd9, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe8, 0xe9, 0xea, 0xeb, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0xa4, 0xa5, 0xa6, 0xa7, + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xe4, 0xe5, 0xe6, 0xe7, 0xe8, 0xe9, 0xea, 0xeb, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, + 0xd0, 0xd1, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x28, 0x29, 0x2a, 0x2b, + 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0xe8, 0xe9, 0xea, 0xeb, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0xca, 0xcb, 0xcc, 0xcd, + 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xea, 0xeb, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xcc, 0xcd, + 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, + 0xd8, 0xd9, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe8, 0xe9, 0xea, 0xeb, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0xa4, 0xa5, 0xa6, 0xa7, + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xc4, 0xc5, + 0xc6, 0xc7, 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, + 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xe4, 0xe5, 0xe6, 0xe7, 0xe8, 0xe9, 0xea, 0xeb, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, + 0xd0, 0xd1, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x36, 0x37, 0x38, 0x39, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x28, 0x29, 0x2a, 0x2b, + 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0xe8, 0xe9, 0xea, 0xeb, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, + 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, + 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a, 0x4b, + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, + 0xde, 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, + 0x00, 0x01, 0x02, 0x03, 0x0a, 0x0b, 0x0c, 0x0d, + 0x0e, 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, + 0x16, 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, + 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0xca, 0xcb, 0xcc, 0xcd, + 0xce, 0xcf, 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, + 0xd6, 0xd7, 0xd8, 0xd9, 0xda, 0xdb, +}; + +static const Summary16 uhc_2_uni2indx_pagec8[251] = { + /* 0xc800 */ + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0x0000 }, + { 0, 0x0000 }, { 0, 0x0000 }, { 0, 0xfee0 }, { 10, 0xcfff }, + { 24, 0xeeef }, { 37, 0xfd4f }, { 49, 0xffec }, { 62, 0xcfdf }, + /* 0xc900 */ + { 75, 0x4f8e }, { 84, 0xfefd }, { 98, 0xefff }, { 113, 0xffef }, + { 128, 0xffff }, { 144, 0xfeec }, { 156, 0xeff4 }, { 168, 0xefee }, + { 181, 0xecff }, { 194, 0xd4fe }, { 205, 0xffff }, { 221, 0xffff }, + { 237, 0xfa6c }, { 247, 0xc994 }, { 254, 0x4f6a }, { 263, 0xecfc }, + /* 0xca00 */ + { 274, 0xc4fe }, { 284, 0xfeef }, { 298, 0xfdff }, { 313, 0xffff }, + { 329, 0xcfff }, { 343, 0x4fee }, { 354, 0xfefc }, { 367, 0xdfff }, + { 382, 0xffef }, { 397, 0xfeff }, { 412, 0xffff }, { 428, 0xcfff }, + { 442, 0x4fee }, { 453, 0xfcf5 }, { 465, 0xeffe }, { 479, 0xffef }, + /* 0xcb00 */ + { 494, 0xfeff }, { 509, 0xfeee }, { 522, 0xfffc }, { 536, 0xffff }, + { 552, 0xecfd }, { 564, 0xdcfe }, { 576, 0xffef }, { 591, 0xfcff }, + { 605, 0xffff }, { 621, 0xefff }, { 636, 0xffff }, { 652, 0xfeff }, + { 667, 0xffff }, { 683, 0xffef }, { 698, 0xfd6f }, { 711, 0xffff }, + /* 0xcc00 */ + { 727, 0xcfff }, { 741, 0xcfee }, { 753, 0xac79 }, { 762, 0x84fe }, + { 771, 0xeecf }, { 783, 0xfc4f }, { 794, 0xfeae }, { 806, 0xffde }, + { 820, 0xffff }, { 836, 0xecff }, { 849, 0xc4fe }, { 859, 0xeecf }, + { 871, 0xfd4f }, { 883, 0xffee }, { 897, 0xefef }, { 911, 0xfffe }, + /* 0xcd00 */ + { 926, 0xecfd }, { 938, 0xd4fe }, { 949, 0xeeef }, { 962, 0xfdff }, + { 977, 0xffff }, { 993, 0xefff }, { 1008, 0x4fee }, { 1019, 0xfefd }, + { 1033, 0xfeff }, { 1048, 0xeecf }, { 1060, 0xfd4f }, { 1072, 0xfffe }, + { 1087, 0xefef }, { 1101, 0xfffe }, { 1116, 0xeeff }, { 1130, 0xd4fe }, + /* 0xce00 */ + { 1141, 0xeeef }, { 1154, 0xfdef }, { 1168, 0xfeec }, { 1180, 0xffd4 }, + { 1192, 0xffff }, { 1208, 0x6cff }, { 1220, 0xd4fc }, { 1230, 0xeecf }, + { 1242, 0xfd4f }, { 1254, 0xfeec }, { 1266, 0xcfc4 }, { 1275, 0xffff }, + { 1291, 0xfffd }, { 1306, 0xffff }, { 1322, 0xe6cf }, { 1333, 0xfc4f }, + /* 0xcf00 */ + { 1344, 0xfeec }, { 1356, 0xefd4 }, { 1367, 0x4fee }, { 1378, 0xfefc }, + { 1391, 0xffff }, { 1407, 0xeecf }, { 1419, 0xfd4f }, { 1431, 0xfeec }, + { 1443, 0xefde }, { 1456, 0xffff }, { 1472, 0xfefd }, { 1486, 0xfffe }, + { 1501, 0xffef }, { 1516, 0xffff }, { 1532, 0xfeec }, { 1544, 0xefd4 }, + /* 0xd000 */ + { 1555, 0xffee }, { 1569, 0xfefd }, { 1583, 0xdfff }, { 1598, 0xeecf }, + { 1610, 0xfd4f }, { 1622, 0xfeee }, { 1635, 0xcffe }, { 1648, 0xcfee }, + { 1660, 0xfffd }, { 1675, 0xffff }, { 1691, 0xeecf }, { 1703, 0xfd4f }, + { 1715, 0xfcec }, { 1726, 0xcfc4 }, { 1735, 0x4fee }, { 1746, 0xfefc }, + /* 0xd100 */ + { 1759, 0xdfff }, { 1774, 0xffff }, { 1790, 0xffff }, { 1806, 0xfaec }, + { 1817, 0xcfc4 }, { 1826, 0x4fee }, { 1837, 0xeefd }, { 1850, 0xefff }, + { 1865, 0xfeef }, { 1879, 0xffff }, { 1895, 0xfeec }, { 1907, 0xebd4 }, + { 1917, 0xfffe }, { 1932, 0xfeff }, { 1947, 0xffff }, { 1963, 0xfeef }, + /* 0xd200 */ + { 1977, 0xfd7f }, { 1991, 0xfffe }, { 2006, 0xcfff }, { 2020, 0x4fee }, + { 2031, 0xfefd }, { 2045, 0xefff }, { 2060, 0xffef }, { 2075, 0xffff }, + { 2091, 0xfeec }, { 2103, 0xefdc }, { 2115, 0xefee }, { 2128, 0x6cfd }, + { 2139, 0xf4fa }, { 2150, 0xeeef }, { 2163, 0xffcf }, { 2177, 0xfeec }, + /* 0xd300 */ + { 2189, 0x8fd4 }, { 2198, 0x4fae }, { 2208, 0xecdc }, { 2218, 0xc4fe }, + { 2228, 0xffcf }, { 2242, 0xffff }, { 2258, 0xffff }, { 2274, 0xcfff }, + { 2288, 0x4fee }, { 2299, 0xecfc }, { 2310, 0xd4fe }, { 2321, 0xeeef }, + { 2334, 0xfccf }, { 2346, 0xfefe }, { 2360, 0xcff5 }, { 2372, 0x4fee }, + /* 0xd400 */ + { 2383, 0xfefd }, { 2397, 0xdfff }, { 2412, 0xffff }, { 2428, 0xffff }, + { 2444, 0xffee }, { 2458, 0xefff }, { 2473, 0x5fee }, { 2485, 0x6cff }, + { 2497, 0xd4fa }, { 2507, 0xffef }, { 2522, 0xfdff }, { 2537, 0xffff }, + { 2553, 0xefff }, { 2568, 0x6fee }, { 2580, 0xeeff }, { 2594, 0xd6fe }, + /* 0xd500 */ + { 2606, 0xeeef }, { 2619, 0xff4f }, { 2632, 0xffff }, { 2648, 0xcfff }, + { 2662, 0x4fee }, { 2673, 0xecfd }, { 2685, 0xd4de }, { 2695, 0xeecf }, + { 2707, 0xfc4f }, { 2718, 0xfffe }, { 2733, 0xffdf }, { 2748, 0xffff }, + { 2764, 0xecff }, { 2777, 0xd4fa }, { 2787, 0xeecf }, { 2799, 0xfd4f }, + /* 0xd600 */ + { 2811, 0xfeec }, { 2823, 0xefc4 }, { 2833, 0xdfee }, { 2846, 0xecff }, + { 2859, 0xd4de }, { 2869, 0xeecd }, { 2880, 0xfd7f }, { 2894, 0xffec }, + { 2907, 0xcfd7 }, { 2919, 0x5fee }, { 2931, 0xeefd }, { 2944, 0xf5fe }, + { 2957, 0xeecf }, { 2969, 0xfd6d }, { 2981, 0xfeee }, { 2994, 0xcfde }, + /* 0xd700 */ + { 3006, 0xffee }, { 3020, 0xecfd }, { 3032, 0xd4fe }, { 3043, 0xeecf }, + { 3055, 0xfd6f }, { 3068, 0xfc2c }, { 3077, 0xedd4 }, { 3087, 0xcfee }, + { 3099, 0xecfd }, { 3111, 0xd4fe }, { 3122, 0x000f }, +}; + +static int +uhc_2_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (n >= 2) { + if (wc >= 0xc800 && wc < 0xd7b0) { + const Summary16 *summary = &uhc_2_uni2indx_pagec8[(wc>>4)-0xc80]; + unsigned short used = summary->used; + unsigned int i = wc & 0x0f; + if (used & ((unsigned short) 1 << i)) { + unsigned short c; + /* Keep in `used' only the bits 0..i-1. */ + used &= ((unsigned short) 1 << i) - 1; + /* Add `summary->indx' and the number of bits set in `used'. */ + used = (used & 0x5555) + ((used & 0xaaaa) >> 1); + used = (used & 0x3333) + ((used & 0xcccc) >> 2); + used = (used & 0x0f0f) + ((used & 0xf0f0) >> 4); + used = (used & 0x00ff) + (used >> 8); + used += summary->indx; + c = uhc_2_2charset_main[used>>6] + uhc_2_2charset[used]; + r[0] = (c >> 8); r[1] = (c & 0xff); + return 2; + } + } + return RET_ILUNI; + } + return RET_TOOSMALL; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/utf16.h b/graf2d/win32gdk/gdk/src/iconv/utf16.h new file mode 100644 index 0000000000000..99b5e2c2d8596 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/utf16.h @@ -0,0 +1,113 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UTF-16 + */ + +/* Specification: RFC 2781 */ + +/* Here we accept FFFE/FEFF marks as endianness indicators everywhere + in the stream, not just at the beginning. (This is contrary to what + RFC 2781 section 3.2 specifies, but it allows concatenation of byte + sequences to work flawlessly, while disagreeing with the RFC behaviour + only for strings containing U+FEFF characters, which is quite rare.) + The default is big-endian. */ +/* The state is 0 if big-endian, 1 if little-endian. */ +static int +utf16_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + state_t state = conv->istate; + int count = 0; + for (; n >= 2;) { + ucs4_t wc = (state ? s[0] + (s[1] << 8) : (s[0] << 8) + s[1]); + if (wc == 0xfeff) { + } else if (wc == 0xfffe) { + state ^= 1; + } else if (wc >= 0xd800 && wc < 0xdc00) { + if (n >= 4) { + ucs4_t wc2 = (state ? s[2] + (s[3] << 8) : (s[2] << 8) + s[3]); + if (!(wc2 >= 0xdc00 && wc2 < 0xe000)) + goto ilseq; + *pwc = 0x10000 + ((wc - 0xd800) << 10) + (wc2 - 0xdc00); + conv->istate = state; + return count+4; + } else + break; + } else if (wc >= 0xdc00 && wc < 0xe000) { + goto ilseq; + } else { + *pwc = wc; + conv->istate = state; + return count+2; + } + s += 2; n -= 2; count += 2; + } + conv->istate = state; + return RET_TOOFEW(count); + +ilseq: + conv->istate = state; + return RET_SHIFT_ILSEQ(count); +} + +/* We output UTF-16 in big-endian order, with byte-order mark. + See RFC 2781 section 3.3 for a rationale: Some document formats + mandate a BOM; the file concatenation issue is not so severe as + long as the above utf16_mbtowc function is used. */ +/* The state is 0 at the beginning, 1 after the BOM has been written. */ +static int +utf16_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc != 0xfffe && !(wc >= 0xd800 && wc < 0xe000)) { + int count = 0; + if (!conv->ostate) { + if (n >= 2) { + r[0] = 0xFE; + r[1] = 0xFF; + r += 2; n -= 2; count += 2; + } else + return RET_TOOSMALL; + } + if (wc < 0x10000) { + if (n >= 2) { + r[0] = (unsigned char) (wc >> 8); + r[1] = (unsigned char) wc; + conv->ostate = 1; + return count+2; + } else + return RET_TOOSMALL; + } + else if (wc < 0x110000) { + if (n >= 4) { + ucs4_t wc1 = 0xd800 + ((wc - 0x10000) >> 10); + ucs4_t wc2 = 0xdc00 + ((wc - 0x10000) & 0x3ff); + r[0] = (unsigned char) (wc1 >> 8); + r[1] = (unsigned char) wc1; + r[2] = (unsigned char) (wc2 >> 8); + r[3] = (unsigned char) wc2; + conv->ostate = 1; + return count+4; + } else + return RET_TOOSMALL; + } + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/utf16be.h b/graf2d/win32gdk/gdk/src/iconv/utf16be.h new file mode 100644 index 0000000000000..a6d90ffb91660 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/utf16be.h @@ -0,0 +1,80 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UTF-16BE + */ + +/* Specification: RFC 2781 */ + +static int +utf16be_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + int count = 0; + if (n >= 2) { + ucs4_t wc = (s[0] << 8) + s[1]; + if (wc >= 0xd800 && wc < 0xdc00) { + if (n >= 4) { + ucs4_t wc2 = (s[2] << 8) + s[3]; + if (!(wc2 >= 0xdc00 && wc2 < 0xe000)) + goto ilseq; + *pwc = 0x10000 + ((wc - 0xd800) << 10) + (wc2 - 0xdc00); + return count+4; + } + } else if (wc >= 0xdc00 && wc < 0xe000) { + goto ilseq; + } else { + *pwc = wc; + return count+2; + } + } + return RET_TOOFEW(count); + +ilseq: + return RET_SHIFT_ILSEQ(count); +} + +static int +utf16be_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (!(wc >= 0xd800 && wc < 0xe000)) { + if (wc < 0x10000) { + if (n >= 2) { + r[0] = (unsigned char) (wc >> 8); + r[1] = (unsigned char) wc; + return 2; + } else + return RET_TOOSMALL; + } + else if (wc < 0x110000) { + if (n >= 4) { + ucs4_t wc1 = 0xd800 + ((wc - 0x10000) >> 10); + ucs4_t wc2 = 0xdc00 + ((wc - 0x10000) & 0x3ff); + r[0] = (unsigned char) (wc1 >> 8); + r[1] = (unsigned char) wc1; + r[2] = (unsigned char) (wc2 >> 8); + r[3] = (unsigned char) wc2; + return 4; + } else + return RET_TOOSMALL; + } + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/utf16le.h b/graf2d/win32gdk/gdk/src/iconv/utf16le.h new file mode 100644 index 0000000000000..5bb2b02696669 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/utf16le.h @@ -0,0 +1,80 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UTF-16LE + */ + +/* Specification: RFC 2781 */ + +static int +utf16le_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + int count = 0; + if (n >= 2) { + ucs4_t wc = s[0] + (s[1] << 8); + if (wc >= 0xd800 && wc < 0xdc00) { + if (n >= 4) { + ucs4_t wc2 = s[2] + (s[3] << 8); + if (!(wc2 >= 0xdc00 && wc2 < 0xe000)) + goto ilseq; + *pwc = 0x10000 + ((wc - 0xd800) << 10) + (wc2 - 0xdc00); + return count+4; + } + } else if (wc >= 0xdc00 && wc < 0xe000) { + goto ilseq; + } else { + *pwc = wc; + return count+2; + } + } + return RET_TOOFEW(count); + +ilseq: + return RET_SHIFT_ILSEQ(count); +} + +static int +utf16le_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (!(wc >= 0xd800 && wc < 0xe000)) { + if (wc < 0x10000) { + if (n >= 2) { + r[0] = (unsigned char) wc; + r[1] = (unsigned char) (wc >> 8); + return 2; + } else + return RET_TOOSMALL; + } + else if (wc < 0x110000) { + if (n >= 4) { + ucs4_t wc1 = 0xd800 + ((wc - 0x10000) >> 10); + ucs4_t wc2 = 0xdc00 + ((wc - 0x10000) & 0x3ff); + r[0] = (unsigned char) wc1; + r[1] = (unsigned char) (wc1 >> 8); + r[2] = (unsigned char) wc2; + r[3] = (unsigned char) (wc2 >> 8); + return 4; + } else + return RET_TOOSMALL; + } + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/utf32.h b/graf2d/win32gdk/gdk/src/iconv/utf32.h new file mode 100644 index 0000000000000..bc579ae0b8baf --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/utf32.h @@ -0,0 +1,93 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UTF-32 + */ + +/* Specification: Unicode 3.1 Standard Annex #19 */ + +/* Here we accept FFFE0000/0000FEFF marks as endianness indicators + everywhere in the stream, not just at the beginning. (This is contrary + to what #19 D36c specifies, but it allows concatenation of byte + sequences to work flawlessly, while disagreeing with #19 behaviour + only for strings containing U+FEFF characters, which is quite rare.) + The default is big-endian. */ +/* The state is 0 if big-endian, 1 if little-endian. */ +static int +utf32_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + state_t state = conv->istate; + int count = 0; + for (; n >= 4;) { + ucs4_t wc = (state + ? s[0] + (s[1] << 8) + (s[2] << 16) + (s[3] << 24) + : (s[0] << 24) + (s[1] << 16) + (s[2] << 8) + s[3]); + count += 4; + if (wc == 0x0000feff) { + } else if (wc == 0xfffe0000u) { + state ^= 1; + } else { + if (wc < 0x110000 && !(wc >= 0xd800 && wc < 0xe000)) { + *pwc = wc; + conv->istate = state; + return count; + } else { + conv->istate = state; + return RET_SHIFT_ILSEQ(count); + } + } + s += 4; n -= 4; + } + conv->istate = state; + return RET_TOOFEW(count); +} + +/* We output UTF-32 in big-endian order, with byte-order mark. */ +/* The state is 0 at the beginning, 1 after the BOM has been written. */ +static int +utf32_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x110000 && !(wc >= 0xd800 && wc < 0xe000)) { + int count = 0; + if (!conv->ostate) { + if (n >= 4) { + r[0] = 0x00; + r[1] = 0x00; + r[2] = 0xFE; + r[3] = 0xFF; + r += 4; n -= 4; count += 4; + } else + return RET_TOOSMALL; + } + if (wc < 0x110000) { + if (n >= 4) { + r[0] = 0; + r[1] = (unsigned char) (wc >> 16); + r[2] = (unsigned char) (wc >> 8); + r[3] = (unsigned char) wc; + conv->ostate = 1; + return count+4; + } else + return RET_TOOSMALL; + } + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/utf32be.h b/graf2d/win32gdk/gdk/src/iconv/utf32be.h new file mode 100644 index 0000000000000..50811298d63f3 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/utf32be.h @@ -0,0 +1,55 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UTF-32BE + */ + +/* Specification: Unicode 3.1 Standard Annex #19 */ + +static int +utf32be_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + if (n >= 4) { + ucs4_t wc = (s[0] << 24) + (s[1] << 16) + (s[2] << 8) + s[3]; + if (wc < 0x110000 && !(wc >= 0xd800 && wc < 0xe000)) { + *pwc = wc; + return 4; + } else + return RET_ILSEQ; + } + return RET_TOOFEW(0); +} + +static int +utf32be_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x110000 && !(wc >= 0xd800 && wc < 0xe000)) { + if (n >= 4) { + r[0] = 0; + r[1] = (unsigned char) (wc >> 16); + r[2] = (unsigned char) (wc >> 8); + r[3] = (unsigned char) wc; + return 4; + } else + return RET_TOOSMALL; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/utf32le.h b/graf2d/win32gdk/gdk/src/iconv/utf32le.h new file mode 100644 index 0000000000000..9d3699bc98d0e --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/utf32le.h @@ -0,0 +1,55 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UTF-32LE + */ + +/* Specification: Unicode 3.1 Standard Annex #19 */ + +static int +utf32le_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + if (n >= 4) { + ucs4_t wc = s[0] + (s[1] << 8) + (s[2] << 16) + (s[3] << 24); + if (wc < 0x110000 && !(wc >= 0xd800 && wc < 0xe000)) { + *pwc = wc; + return 4; + } else + return RET_ILSEQ; + } + return RET_TOOFEW(0); +} + +static int +utf32le_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + if (wc < 0x110000 && !(wc >= 0xd800 && wc < 0xe000)) { + if (n >= 4) { + r[0] = (unsigned char) wc; + r[1] = (unsigned char) (wc >> 8); + r[2] = (unsigned char) (wc >> 16); + r[3] = 0; + return 4; + } else + return RET_TOOSMALL; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/utf7.h b/graf2d/win32gdk/gdk/src/iconv/utf7.h new file mode 100644 index 0000000000000..888bfb4d65048 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/utf7.h @@ -0,0 +1,355 @@ +/* + * Copyright (C) 1999-2001, 2008 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UTF-7 + */ + +/* Specification: RFC 2152 (and old RFC 1641, RFC 1642) */ +/* The original Base64 encoding is defined in RFC 2045. */ + +/* Set of direct characters: + * A-Z a-z 0-9 ' ( ) , - . / : ? space tab lf cr + */ +static const unsigned char direct_tab[128/8] = { + 0x00, 0x26, 0x00, 0x00, 0x81, 0xf3, 0xff, 0x87, + 0xfe, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0x07, +}; +#define isdirect(ch) ((ch) < 128 && ((direct_tab[(ch)>>3] >> (ch & 7)) & 1)) + +/* Set of direct and optional direct characters: + * A-Z a-z 0-9 ' ( ) , - . / : ? space tab lf cr + * ! " # $ % & * ; < = > @ [ ] ^ _ ` { | } + */ +static const unsigned char xdirect_tab[128/8] = { + 0x00, 0x26, 0x00, 0x00, 0xff, 0xf7, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xef, 0xff, 0xff, 0xff, 0x3f, +}; +#define isxdirect(ch) ((ch) < 128 && ((xdirect_tab[(ch)>>3] >> (ch & 7)) & 1)) + +/* Set of base64 characters, extended: + * A-Z a-z 0-9 + / - + */ +static const unsigned char xbase64_tab[128/8] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0xa8, 0xff, 0x03, + 0xfe, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0x07, +}; +#define isxbase64(ch) ((ch) < 128 && ((xbase64_tab[(ch)>>3] >> (ch & 7)) & 1)) + +/* + * The state is structured as follows: + * bit 1..0: shift + * bit 7..2: data + * Precise meaning: + * shift data + * 0 0 not inside base64 encoding + * 1 0 inside base64, no pending bits + * 2 XXXX00 inside base64, 4 bits remain from 2nd byte + * 3 XX0000 inside base64, 2 bits remain from 3rd byte + */ + +static int +utf7_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + state_t state = conv->istate; + int count = 0; /* number of input bytes already read */ + if (state & 3) + goto active; + else + goto inactive; + +inactive: + { + /* Here (state & 3) == 0 */ + if (n < count+1) + goto none; + { + unsigned char c = *s; + if (isxdirect(c)) { + *pwc = (ucs4_t) c; + conv->istate = state; + return count+1; + } + if (c == '+') { + if (n < count+2) + goto none; + if (s[1] == '-') { + *pwc = (ucs4_t) '+'; + conv->istate = state; + return count+2; + } + s++; count++; + state = 1; + goto active; + } + goto ilseq; + } + } + +active: + { + /* base64 encoding active */ + unsigned int wc = 0; + state_t base64state = state; + unsigned int kmax = 2; /* number of payload bytes to read */ + unsigned int k = 0; /* number of payload bytes already read */ + unsigned int base64count = 0; /* number of base64 bytes already read */ + for (;;) { + unsigned char c = *s; + unsigned int i; + if (c >= 'A' && c <= 'Z') + i = c-'A'; + else if (c >= 'a' && c <= 'z') + i = c-'a'+26; + else if (c >= '0' && c <= '9') + i = c-'0'+52; + else if (c == '+') + i = 62; + else if (c == '/') + i = 63; + else { + /* c terminates base64 encoding */ + if (base64state & -4) + goto ilseq; /* data must be 0, otherwise illegal */ + if (base64count) + goto ilseq; /* partial UTF-16 characters are invalid */ + if (c == '-') { + s++; count++; + } + state = 0; + goto inactive; + } + s++; base64count++; + /* read 6 bits: 0 <= i < 64 */ + switch (base64state & 3) { + case 1: /* inside base64, no pending bits */ + base64state = (i << 2) | 0; break; + case 0: /* inside base64, 6 bits remain from 1st byte */ + wc = (wc << 8) | (base64state & -4) | (i >> 4); k++; + base64state = ((i & 15) << 4) | 2; break; + case 2: /* inside base64, 4 bits remain from 2nd byte */ + wc = (wc << 8) | (base64state & -4) | (i >> 2); k++; + base64state = ((i & 3) << 6) | 3; break; + case 3: /* inside base64, 2 bits remain from 3rd byte */ + wc = (wc << 8) | (base64state & -4) | i; k++; + base64state = 1; break; + } + if (k == kmax) { + /* UTF-16: When we see a High Surrogate, we must also decode + the following Low Surrogate. */ + if (kmax == 2 && (wc >= 0xd800 && wc < 0xdc00)) + kmax = 4; + else + break; + } + if (n < count+base64count+1) + goto none; + } + /* Here k = kmax > 0, hence base64count > 0. */ + if ((base64state & 3) == 0) abort(); + if (kmax == 4) { + ucs4_t wc1 = wc >> 16; + ucs4_t wc2 = wc & 0xffff; + if (!(wc1 >= 0xd800 && wc1 < 0xdc00)) abort(); + if (!(wc2 >= 0xdc00 && wc2 < 0xe000)) goto ilseq; + *pwc = 0x10000 + ((wc1 - 0xd800) << 10) + (wc2 - 0xdc00); + } else { + *pwc = wc; + } + conv->istate = base64state; + return count+base64count; + } + +none: + conv->istate = state; + return RET_TOOFEW(count); + +ilseq: + conv->istate = state; + return RET_SHIFT_ILSEQ(count); +} + +/* + * The state is structured as follows: + * bit 1..0: shift + * bit 7..2: data + * Precise meaning: + * shift data + * 0 0 not inside base64 encoding + * 1 0 inside base64, no pending bits + * 2 XX00 inside base64, 2 bits known for 2nd byte + * 3 XXXX inside base64, 4 bits known for 3rd byte + */ + +/* Define this to 1 if you want the so-called "optional direct" characters + ! " # $ % & * ; < = > @ [ ] ^ _ ` { | } + to be encoded. Define to 0 if you want them to be passed straight through, + like the so-called "direct" characters. + We set this to 1 because it's safer. + */ +#define UTF7_ENCODE_OPTIONAL_CHARS 1 + +static int +utf7_wctomb (conv_t conv, unsigned char *r, ucs4_t iwc, int n) +{ + state_t state = conv->ostate; + unsigned int wc = iwc; + int count = 0; + if (state & 3) + goto active; + +/*inactive:*/ + { + if (UTF7_ENCODE_OPTIONAL_CHARS ? isdirect(wc) : isxdirect(wc)) { + r[0] = (unsigned char) wc; + /*conv->ostate = state;*/ + return 1; + } else { + *r++ = '+'; + if (wc == '+') { + if (n < 2) + return RET_TOOSMALL; + *r = '-'; + /*conv->ostate = state;*/ + return 2; + } + count = 1; + state = 1; + goto active; + } + } + +active: + { + /* base64 encoding active */ + if (UTF7_ENCODE_OPTIONAL_CHARS ? isdirect(wc) : isxdirect(wc)) { + /* deactivate base64 encoding */ + count += ((state & 3) >= 2 ? 1 : 0) + (isxbase64(wc) ? 1 : 0) + 1; + if (n < count) + return RET_TOOSMALL; + if ((state & 3) >= 2) { + unsigned int i = state & -4; + unsigned char c; + if (i < 26) + c = i+'A'; + else if (i < 52) + c = i-26+'a'; + else if (i < 62) + c = i-52+'0'; + else if (i == 62) + c = '+'; + else if (i == 63) + c = '/'; + else + abort(); + *r++ = c; + } + if (isxbase64(wc)) + *r++ = '-'; + state = 0; + *r++ = (unsigned char) wc; + conv->ostate = state; + return count; + } else { + unsigned int k; /* number of payload bytes to write */ + if (wc < 0x10000) { + k = 2; + count += ((state & 3) >= 2 ? 3 : 2); + } else if (wc < 0x110000) { + unsigned int wc1 = 0xd800 + ((wc - 0x10000) >> 10); + unsigned int wc2 = 0xdc00 + ((wc - 0x10000) & 0x3ff); + wc = (wc1 << 16) | wc2; + k = 4; + count += ((state & 3) >= 3 ? 6 : 5); + } else + return RET_ILUNI; + if (n < count) + return RET_TOOSMALL; + for (;;) { + unsigned int i; + unsigned char c; + switch (state & 3) { + case 0: /* inside base64, 6 bits known for 4th byte */ + c = (state & -4) >> 2; state = 1; break; + case 1: /* inside base64, no pending bits */ + i = (wc >> (8 * --k)) & 0xff; + c = i >> 2; state = ((i & 3) << 4) | 2; break; + case 2: /* inside base64, 2 bits known for 2nd byte */ + i = (wc >> (8 * --k)) & 0xff; + c = (state & -4) | (i >> 4); state = ((i & 15) << 2) | 3; break; + case 3: /* inside base64, 4 bits known for 3rd byte */ + i = (wc >> (8 * --k)) & 0xff; + c = (state & -4) | (i >> 6); state = ((i & 63) << 2) | 0; break; + default: abort(); /* stupid gcc */ + } + if (c < 26) + c = c+'A'; + else if (c < 52) + c = c-26+'a'; + else if (c < 62) + c = c-52+'0'; + else if (c == 62) + c = '+'; + else if (c == 63) + c = '/'; + else + abort(); + *r++ = c; + if ((state & 3) && (k == 0)) + break; + } + conv->ostate = state; + return count; + } + } +} + +static int +utf7_reset (conv_t conv, unsigned char *r, int n) +{ + state_t state = conv->ostate; + if (state & 3) { + /* deactivate base64 encoding */ + unsigned int count = ((state & 3) >= 2 ? 1 : 0) + 1; + if (n < count) + return RET_TOOSMALL; + if ((state & 3) >= 2) { + unsigned int i = state & -4; + unsigned char c; + if (i < 26) + c = i+'A'; + else if (i < 52) + c = i-26+'a'; + else if (i < 62) + c = i-52+'0'; + else if (i == 62) + c = '+'; + else if (i == 63) + c = '/'; + else + abort(); + *r++ = c; + } + *r++ = '-'; + /* conv->ostate = 0; will be done by the caller */ + return count; + } else + return 0; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/utf8.h b/graf2d/win32gdk/gdk/src/iconv/utf8.h new file mode 100644 index 0000000000000..9d07219c8ad94 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/utf8.h @@ -0,0 +1,128 @@ +/* + * Copyright (C) 1999-2001, 2004 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * UTF-8 + */ + +/* Specification: RFC 3629 */ + +static int +utf8_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = s[0]; + + if (c < 0x80) { + *pwc = c; + return 1; + } else if (c < 0xc2) { + return RET_ILSEQ; + } else if (c < 0xe0) { + if (n < 2) + return RET_TOOFEW(0); + if (!((s[1] ^ 0x80) < 0x40)) + return RET_ILSEQ; + *pwc = ((ucs4_t) (c & 0x1f) << 6) + | (ucs4_t) (s[1] ^ 0x80); + return 2; + } else if (c < 0xf0) { + if (n < 3) + return RET_TOOFEW(0); + if (!((s[1] ^ 0x80) < 0x40 && (s[2] ^ 0x80) < 0x40 + && (c >= 0xe1 || s[1] >= 0xa0))) + return RET_ILSEQ; + *pwc = ((ucs4_t) (c & 0x0f) << 12) + | ((ucs4_t) (s[1] ^ 0x80) << 6) + | (ucs4_t) (s[2] ^ 0x80); + return 3; + } else if (c < 0xf8 && sizeof(ucs4_t)*8 >= 32) { + if (n < 4) + return RET_TOOFEW(0); + if (!((s[1] ^ 0x80) < 0x40 && (s[2] ^ 0x80) < 0x40 + && (s[3] ^ 0x80) < 0x40 + && (c >= 0xf1 || s[1] >= 0x90))) + return RET_ILSEQ; + *pwc = ((ucs4_t) (c & 0x07) << 18) + | ((ucs4_t) (s[1] ^ 0x80) << 12) + | ((ucs4_t) (s[2] ^ 0x80) << 6) + | (ucs4_t) (s[3] ^ 0x80); + return 4; + } else if (c < 0xfc && sizeof(ucs4_t)*8 >= 32) { + if (n < 5) + return RET_TOOFEW(0); + if (!((s[1] ^ 0x80) < 0x40 && (s[2] ^ 0x80) < 0x40 + && (s[3] ^ 0x80) < 0x40 && (s[4] ^ 0x80) < 0x40 + && (c >= 0xf9 || s[1] >= 0x88))) + return RET_ILSEQ; + *pwc = ((ucs4_t) (c & 0x03) << 24) + | ((ucs4_t) (s[1] ^ 0x80) << 18) + | ((ucs4_t) (s[2] ^ 0x80) << 12) + | ((ucs4_t) (s[3] ^ 0x80) << 6) + | (ucs4_t) (s[4] ^ 0x80); + return 5; + } else if (c < 0xfe && sizeof(ucs4_t)*8 >= 32) { + if (n < 6) + return RET_TOOFEW(0); + if (!((s[1] ^ 0x80) < 0x40 && (s[2] ^ 0x80) < 0x40 + && (s[3] ^ 0x80) < 0x40 && (s[4] ^ 0x80) < 0x40 + && (s[5] ^ 0x80) < 0x40 + && (c >= 0xfd || s[1] >= 0x84))) + return RET_ILSEQ; + *pwc = ((ucs4_t) (c & 0x01) << 30) + | ((ucs4_t) (s[1] ^ 0x80) << 24) + | ((ucs4_t) (s[2] ^ 0x80) << 18) + | ((ucs4_t) (s[3] ^ 0x80) << 12) + | ((ucs4_t) (s[4] ^ 0x80) << 6) + | (ucs4_t) (s[5] ^ 0x80); + return 6; + } else + return RET_ILSEQ; +} + +static int +utf8_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) /* n == 0 is acceptable */ +{ + int count; + if (wc < 0x80) + count = 1; + else if (wc < 0x800) + count = 2; + else if (wc < 0x10000) + count = 3; + else if (wc < 0x200000) + count = 4; + else if (wc < 0x4000000) + count = 5; + else if (wc <= 0x7fffffff) + count = 6; + else + return RET_ILUNI; + if (n < count) + return RET_TOOSMALL; + switch (count) { /* note: code falls through cases! */ + case 6: r[5] = 0x80 | (wc & 0x3f); wc = wc >> 6; wc |= 0x4000000; + case 5: r[4] = 0x80 | (wc & 0x3f); wc = wc >> 6; wc |= 0x200000; + case 4: r[3] = 0x80 | (wc & 0x3f); wc = wc >> 6; wc |= 0x10000; + case 3: r[2] = 0x80 | (wc & 0x3f); wc = wc >> 6; wc |= 0x800; + case 2: r[1] = 0x80 | (wc & 0x3f); wc = wc >> 6; wc |= 0xc0; + case 1: r[0] = wc; + } + return count; +} diff --git a/graf2d/win32gdk/gdk/src/iconv/vietcomb.h b/graf2d/win32gdk/gdk/src/iconv/vietcomb.h new file mode 100644 index 0000000000000..34892cd440b73 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/vietcomb.h @@ -0,0 +1,467 @@ +/* + * Copyright (C) 2001, 2004 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* Combining characters used in Vietnamese encodings CP1258, TCVN. */ + +#ifndef _VIETCOMB_H +#define _VIETCOMB_H + +/* Relevant combining characters: + 0x0300, 0x0301, 0x0303, 0x0309, 0x0323. */ + +/* Composition tables for each of the relevant combining characters. */ +static const struct { unsigned short base; unsigned short composed; } viet_comp_table_data[] = { +#define viet_comp_table0300_idx 0 +#define viet_comp_table0300_len 31 + { 0x0041, 0x00C0 }, + { 0x0045, 0x00C8 }, + { 0x0049, 0x00CC }, + { 0x004E, 0x01F8 }, + { 0x004F, 0x00D2 }, + { 0x0055, 0x00D9 }, + { 0x0057, 0x1E80 }, + { 0x0059, 0x1EF2 }, + { 0x0061, 0x00E0 }, + { 0x0065, 0x00E8 }, + { 0x0069, 0x00EC }, + { 0x006E, 0x01F9 }, + { 0x006F, 0x00F2 }, + { 0x0075, 0x00F9 }, + { 0x0077, 0x1E81 }, + { 0x0079, 0x1EF3 }, + { 0x00A8, 0x1FED }, + { 0x00C2, 0x1EA6 }, + { 0x00CA, 0x1EC0 }, + { 0x00D4, 0x1ED2 }, + { 0x00DC, 0x01DB }, + { 0x00E2, 0x1EA7 }, + { 0x00EA, 0x1EC1 }, + { 0x00F4, 0x1ED3 }, + { 0x00FC, 0x01DC }, + { 0x0102, 0x1EB0 }, + { 0x0103, 0x1EB1 }, +/*{ 0x0112, 0x1E14 },*/ +/*{ 0x0113, 0x1E15 },*/ +/*{ 0x014C, 0x1E50 },*/ +/*{ 0x014D, 0x1E51 },*/ + { 0x01A0, 0x1EDC }, + { 0x01A1, 0x1EDD }, + { 0x01AF, 0x1EEA }, + { 0x01B0, 0x1EEB }, +#define viet_comp_table0301_idx (viet_comp_table0300_idx+viet_comp_table0300_len) +#define viet_comp_table0301_len 64 + { 0x0041, 0x00C1 }, + { 0x0043, 0x0106 }, + { 0x0045, 0x00C9 }, + { 0x0047, 0x01F4 }, + { 0x0049, 0x00CD }, + { 0x004B, 0x1E30 }, + { 0x004C, 0x0139 }, + { 0x004D, 0x1E3E }, + { 0x004E, 0x0143 }, + { 0x004F, 0x00D3 }, + { 0x0050, 0x1E54 }, + { 0x0052, 0x0154 }, + { 0x0053, 0x015A }, + { 0x0055, 0x00DA }, + { 0x0057, 0x1E82 }, + { 0x0059, 0x00DD }, + { 0x005A, 0x0179 }, + { 0x0061, 0x00E1 }, + { 0x0063, 0x0107 }, + { 0x0065, 0x00E9 }, + { 0x0067, 0x01F5 }, + { 0x0069, 0x00ED }, + { 0x006B, 0x1E31 }, + { 0x006C, 0x013A }, + { 0x006D, 0x1E3F }, + { 0x006E, 0x0144 }, + { 0x006F, 0x00F3 }, + { 0x0070, 0x1E55 }, + { 0x0072, 0x0155 }, + { 0x0073, 0x015B }, + { 0x0075, 0x00FA }, + { 0x0077, 0x1E83 }, + { 0x0079, 0x00FD }, + { 0x007A, 0x017A }, + { 0x00A5, 0x0385 }, + { 0x00A8, 0x1FEE }, + { 0x00C2, 0x1EA4 }, + { 0x00C5, 0x01FA }, + { 0x00C6, 0x01FC }, + { 0x00C7, 0x1E08 }, + { 0x00CA, 0x1EBE }, + { 0x00CF, 0x1E2E }, + { 0x00D4, 0x1ED0 }, + { 0x00D5, 0x1E4C }, + { 0x00D8, 0x01FE }, + { 0x00DC, 0x01D7 }, + { 0x00E2, 0x1EA5 }, + { 0x00E5, 0x01FB }, + { 0x00E6, 0x01FD }, + { 0x00E7, 0x1E09 }, + { 0x00EA, 0x1EBF }, + { 0x00EF, 0x1E2F }, + { 0x00F4, 0x1ED1 }, + { 0x00F5, 0x1E4D }, + { 0x00F8, 0x01FF }, + { 0x00FC, 0x01D8 }, + { 0x0102, 0x1EAE }, + { 0x0103, 0x1EAF }, +/*{ 0x0112, 0x1E16 },*/ +/*{ 0x0113, 0x1E17 },*/ +/*{ 0x014C, 0x1E52 },*/ +/*{ 0x014D, 0x1E53 },*/ + { 0x0168, 0x1E78 }, + { 0x0169, 0x1E79 }, + { 0x01A0, 0x1EDA }, + { 0x01A1, 0x1EDB }, + { 0x01AF, 0x1EE8 }, + { 0x01B0, 0x1EE9 }, +#define viet_comp_table0303_idx (viet_comp_table0301_idx+viet_comp_table0301_len) +#define viet_comp_table0303_len 34 + { 0x0041, 0x00C3 }, + { 0x0045, 0x1EBC }, + { 0x0049, 0x0128 }, + { 0x004E, 0x00D1 }, + { 0x004F, 0x00D5 }, + { 0x0055, 0x0168 }, + { 0x0056, 0x1E7C }, + { 0x0059, 0x1EF8 }, + { 0x0061, 0x00E3 }, + { 0x0065, 0x1EBD }, + { 0x0069, 0x0129 }, + { 0x006E, 0x00F1 }, + { 0x006F, 0x00F5 }, + { 0x0075, 0x0169 }, + { 0x0076, 0x1E7D }, + { 0x0079, 0x1EF9 }, + { 0x00C2, 0x1EAA }, + { 0x00CA, 0x1EC4 }, + { 0x00D3, 0x1E4C }, + { 0x00D4, 0x1ED6 }, + { 0x00D6, 0x1E4E }, + { 0x00DA, 0x1E78 }, + { 0x00E2, 0x1EAB }, + { 0x00EA, 0x1EC5 }, + { 0x00F3, 0x1E4D }, + { 0x00F4, 0x1ED7 }, + { 0x00F6, 0x1E4F }, + { 0x00FA, 0x1E79 }, + { 0x0102, 0x1EB4 }, + { 0x0103, 0x1EB5 }, + { 0x01A0, 0x1EE0 }, + { 0x01A1, 0x1EE1 }, + { 0x01AF, 0x1EEE }, + { 0x01B0, 0x1EEF }, +#define viet_comp_table0309_idx (viet_comp_table0303_idx+viet_comp_table0303_len) +#define viet_comp_table0309_len 24 + { 0x0041, 0x1EA2 }, + { 0x0045, 0x1EBA }, + { 0x0049, 0x1EC8 }, + { 0x004F, 0x1ECE }, + { 0x0055, 0x1EE6 }, + { 0x0059, 0x1EF6 }, + { 0x0061, 0x1EA3 }, + { 0x0065, 0x1EBB }, + { 0x0069, 0x1EC9 }, + { 0x006F, 0x1ECF }, + { 0x0075, 0x1EE7 }, + { 0x0079, 0x1EF7 }, + { 0x00C2, 0x1EA8 }, + { 0x00CA, 0x1EC2 }, + { 0x00D4, 0x1ED4 }, + { 0x00E2, 0x1EA9 }, + { 0x00EA, 0x1EC3 }, + { 0x00F4, 0x1ED5 }, + { 0x0102, 0x1EB2 }, + { 0x0103, 0x1EB3 }, + { 0x01A0, 0x1EDE }, + { 0x01A1, 0x1EDF }, + { 0x01AF, 0x1EEC }, + { 0x01B0, 0x1EED }, +#define viet_comp_table0323_idx (viet_comp_table0309_idx+viet_comp_table0309_len) +#define viet_comp_table0323_len 50 + { 0x0041, 0x1EA0 }, + { 0x0042, 0x1E04 }, + { 0x0044, 0x1E0C }, + { 0x0045, 0x1EB8 }, + { 0x0048, 0x1E24 }, + { 0x0049, 0x1ECA }, + { 0x004B, 0x1E32 }, + { 0x004C, 0x1E36 }, + { 0x004D, 0x1E42 }, + { 0x004E, 0x1E46 }, + { 0x004F, 0x1ECC }, + { 0x0052, 0x1E5A }, + { 0x0053, 0x1E62 }, + { 0x0054, 0x1E6C }, + { 0x0055, 0x1EE4 }, + { 0x0056, 0x1E7E }, + { 0x0057, 0x1E88 }, + { 0x0059, 0x1EF4 }, + { 0x005A, 0x1E92 }, + { 0x0061, 0x1EA1 }, + { 0x0062, 0x1E05 }, + { 0x0064, 0x1E0D }, + { 0x0065, 0x1EB9 }, + { 0x0068, 0x1E25 }, + { 0x0069, 0x1ECB }, + { 0x006B, 0x1E33 }, + { 0x006C, 0x1E37 }, + { 0x006D, 0x1E43 }, + { 0x006E, 0x1E47 }, + { 0x006F, 0x1ECD }, + { 0x0072, 0x1E5B }, + { 0x0073, 0x1E63 }, + { 0x0074, 0x1E6D }, + { 0x0075, 0x1EE5 }, + { 0x0076, 0x1E7F }, + { 0x0077, 0x1E89 }, + { 0x0079, 0x1EF5 }, + { 0x007A, 0x1E93 }, + { 0x00C2, 0x1EAC }, + { 0x00CA, 0x1EC6 }, + { 0x00D4, 0x1ED8 }, + { 0x00E2, 0x1EAD }, + { 0x00EA, 0x1EC7 }, + { 0x00F4, 0x1ED9 }, + { 0x0102, 0x1EB6 }, + { 0x0103, 0x1EB7 }, + { 0x01A0, 0x1EE2 }, + { 0x01A1, 0x1EE3 }, + { 0x01AF, 0x1EF0 }, + { 0x01B0, 0x1EF1 }, +}; +static const struct { unsigned int len; unsigned int idx; } viet_comp_table[] = { + { viet_comp_table0300_len, viet_comp_table0300_idx }, + { viet_comp_table0301_len, viet_comp_table0301_idx }, + { viet_comp_table0303_len, viet_comp_table0303_idx }, + { viet_comp_table0309_len, viet_comp_table0309_idx }, + { viet_comp_table0323_len, viet_comp_table0323_idx }, +}; + +/* Decomposition table for the relevant Unicode characters. */ +struct viet_decomp { unsigned short composed; unsigned int base : 12; int comb1 : 4; }; +static const struct viet_decomp viet_decomp_table[] = { + { 0x00B4, 0x0020, 1 }, /* compatibility decomposition - for TCVN only */ + { 0x00C0, 0x0041, 0 }, + { 0x00C1, 0x0041, 1 }, + { 0x00C3, 0x0041, 2 }, + { 0x00C8, 0x0045, 0 }, + { 0x00C9, 0x0045, 1 }, + { 0x00CC, 0x0049, 0 }, + { 0x00CD, 0x0049, 1 }, + { 0x00D1, 0x004E, 2 }, + { 0x00D2, 0x004F, 0 }, + { 0x00D3, 0x004F, 1 }, + { 0x00D5, 0x004F, 2 }, + { 0x00D9, 0x0055, 0 }, + { 0x00DA, 0x0055, 1 }, + { 0x00DD, 0x0059, 1 }, + { 0x00E0, 0x0061, 0 }, + { 0x00E1, 0x0061, 1 }, + { 0x00E3, 0x0061, 2 }, + { 0x00E8, 0x0065, 0 }, + { 0x00E9, 0x0065, 1 }, + { 0x00EC, 0x0069, 0 }, + { 0x00ED, 0x0069, 1 }, + { 0x00F1, 0x006E, 2 }, + { 0x00F2, 0x006F, 0 }, + { 0x00F3, 0x006F, 1 }, + { 0x00F5, 0x006F, 2 }, + { 0x00F9, 0x0075, 0 }, + { 0x00FA, 0x0075, 1 }, + { 0x00FD, 0x0079, 1 }, + { 0x0106, 0x0043, 1 }, + { 0x0107, 0x0063, 1 }, + { 0x0128, 0x0049, 2 }, + { 0x0129, 0x0069, 2 }, + { 0x0139, 0x004C, 1 }, + { 0x013A, 0x006C, 1 }, + { 0x0143, 0x004E, 1 }, + { 0x0144, 0x006E, 1 }, + { 0x0154, 0x0052, 1 }, + { 0x0155, 0x0072, 1 }, + { 0x015A, 0x0053, 1 }, + { 0x015B, 0x0073, 1 }, + { 0x0168, 0x0055, 2 }, + { 0x0169, 0x0075, 2 }, + { 0x0179, 0x005A, 1 }, + { 0x017A, 0x007A, 1 }, + { 0x01D7, 0x00DC, 1 }, + { 0x01D8, 0x00FC, 1 }, + { 0x01DB, 0x00DC, 0 }, + { 0x01DC, 0x00FC, 0 }, + { 0x01F4, 0x0047, 1 }, + { 0x01F5, 0x0067, 1 }, + { 0x01F8, 0x004E, 0 }, + { 0x01F9, 0x006E, 0 }, + { 0x01FA, 0x00C5, 1 }, + { 0x01FB, 0x00E5, 1 }, + { 0x01FC, 0x00C6, 1 }, + { 0x01FD, 0x00E6, 1 }, + { 0x01FE, 0x00D8, 1 }, + { 0x01FF, 0x00F8, 1 }, + { 0x02DC, 0x0020, 2 }, /* compatibility decomposition - for TCVN only */ + { 0x0385, 0x00A5, 1 }, + { 0x1E04, 0x0042, 4 }, + { 0x1E05, 0x0062, 4 }, + { 0x1E08, 0x00C7, 1 }, + { 0x1E09, 0x00E7, 1 }, + { 0x1E0C, 0x0044, 4 }, + { 0x1E0D, 0x0064, 4 }, + { 0x1E24, 0x0048, 4 }, + { 0x1E25, 0x0068, 4 }, + { 0x1E2E, 0x00CF, 1 }, + { 0x1E2F, 0x00EF, 1 }, + { 0x1E30, 0x004B, 1 }, + { 0x1E31, 0x006B, 1 }, + { 0x1E32, 0x004B, 4 }, + { 0x1E33, 0x006B, 4 }, + { 0x1E36, 0x004C, 4 }, + { 0x1E37, 0x006C, 4 }, + { 0x1E3E, 0x004D, 1 }, + { 0x1E3F, 0x006D, 1 }, + { 0x1E42, 0x004D, 4 }, + { 0x1E43, 0x006D, 4 }, + { 0x1E46, 0x004E, 4 }, + { 0x1E47, 0x006E, 4 }, + { 0x1E4C, 0x00D3, 2 }, /*{ 0x1E4C, 0x00D5, 1 },*/ /*{ 0x1E4C, 0x004F, 1, 2 },*/ + { 0x1E4D, 0x00F3, 2 }, /*{ 0x1E4D, 0x00F5, 1 },*/ /*{ 0x1E4D, 0x006F, 1, 2 },*/ + { 0x1E4E, 0x00D6, 2 }, + { 0x1E4F, 0x00F6, 2 }, + { 0x1E54, 0x0050, 1 }, + { 0x1E55, 0x0070, 1 }, + { 0x1E5A, 0x0052, 4 }, + { 0x1E5B, 0x0072, 4 }, + { 0x1E62, 0x0053, 4 }, + { 0x1E63, 0x0073, 4 }, + { 0x1E6C, 0x0054, 4 }, + { 0x1E6D, 0x0074, 4 }, + { 0x1E78, 0x00DA, 2 }, /*{ 0x1E78, 0x0168, 1 },*/ /*{ 0x1E78, 0x0055, 1, 2 },*/ + { 0x1E79, 0x00FA, 2 }, /*{ 0x1E79, 0x0169, 1 },*/ /*{ 0x1E79, 0x0075, 1, 2 },*/ + { 0x1E7C, 0x0056, 2 }, + { 0x1E7D, 0x0076, 2 }, + { 0x1E7E, 0x0056, 4 }, + { 0x1E7F, 0x0076, 4 }, + { 0x1E80, 0x0057, 0 }, + { 0x1E81, 0x0077, 0 }, + { 0x1E82, 0x0057, 1 }, + { 0x1E83, 0x0077, 1 }, + { 0x1E88, 0x0057, 4 }, + { 0x1E89, 0x0077, 4 }, + { 0x1E92, 0x005A, 4 }, + { 0x1E93, 0x007A, 4 }, + { 0x1EA0, 0x0041, 4 }, + { 0x1EA1, 0x0061, 4 }, + { 0x1EA2, 0x0041, 3 }, + { 0x1EA3, 0x0061, 3 }, + { 0x1EA4, 0x00C2, 1 }, + { 0x1EA5, 0x00E2, 1 }, + { 0x1EA6, 0x00C2, 0 }, + { 0x1EA7, 0x00E2, 0 }, + { 0x1EA8, 0x00C2, 3 }, + { 0x1EA9, 0x00E2, 3 }, + { 0x1EAA, 0x00C2, 2 }, + { 0x1EAB, 0x00E2, 2 }, + { 0x1EAC, 0x00C2, 4 }, + { 0x1EAD, 0x00E2, 4 }, + { 0x1EAE, 0x0102, 1 }, + { 0x1EAF, 0x0103, 1 }, + { 0x1EB0, 0x0102, 0 }, + { 0x1EB1, 0x0103, 0 }, + { 0x1EB2, 0x0102, 3 }, + { 0x1EB3, 0x0103, 3 }, + { 0x1EB4, 0x0102, 2 }, + { 0x1EB5, 0x0103, 2 }, + { 0x1EB6, 0x0102, 4 }, + { 0x1EB7, 0x0103, 4 }, + { 0x1EB8, 0x0045, 4 }, + { 0x1EB9, 0x0065, 4 }, + { 0x1EBA, 0x0045, 3 }, + { 0x1EBB, 0x0065, 3 }, + { 0x1EBC, 0x0045, 2 }, + { 0x1EBD, 0x0065, 2 }, + { 0x1EBE, 0x00CA, 1 }, + { 0x1EBF, 0x00EA, 1 }, + { 0x1EC0, 0x00CA, 0 }, + { 0x1EC1, 0x00EA, 0 }, + { 0x1EC2, 0x00CA, 3 }, + { 0x1EC3, 0x00EA, 3 }, + { 0x1EC4, 0x00CA, 2 }, + { 0x1EC5, 0x00EA, 2 }, + { 0x1EC6, 0x00CA, 4 }, + { 0x1EC7, 0x00EA, 4 }, + { 0x1EC8, 0x0049, 3 }, + { 0x1EC9, 0x0069, 3 }, + { 0x1ECA, 0x0049, 4 }, + { 0x1ECB, 0x0069, 4 }, + { 0x1ECC, 0x004F, 4 }, + { 0x1ECD, 0x006F, 4 }, + { 0x1ECE, 0x004F, 3 }, + { 0x1ECF, 0x006F, 3 }, + { 0x1ED0, 0x00D4, 1 }, + { 0x1ED1, 0x00F4, 1 }, + { 0x1ED2, 0x00D4, 0 }, + { 0x1ED3, 0x00F4, 0 }, + { 0x1ED4, 0x00D4, 3 }, + { 0x1ED5, 0x00F4, 3 }, + { 0x1ED6, 0x00D4, 2 }, + { 0x1ED7, 0x00F4, 2 }, + { 0x1ED8, 0x00D4, 4 }, + { 0x1ED9, 0x00F4, 4 }, + { 0x1EDA, 0x01A0, 1 }, + { 0x1EDB, 0x01A1, 1 }, + { 0x1EDC, 0x01A0, 0 }, + { 0x1EDD, 0x01A1, 0 }, + { 0x1EDE, 0x01A0, 3 }, + { 0x1EDF, 0x01A1, 3 }, + { 0x1EE0, 0x01A0, 2 }, + { 0x1EE1, 0x01A1, 2 }, + { 0x1EE2, 0x01A0, 4 }, + { 0x1EE3, 0x01A1, 4 }, + { 0x1EE4, 0x0055, 4 }, + { 0x1EE5, 0x0075, 4 }, + { 0x1EE6, 0x0055, 3 }, + { 0x1EE7, 0x0075, 3 }, + { 0x1EE8, 0x01AF, 1 }, + { 0x1EE9, 0x01B0, 1 }, + { 0x1EEA, 0x01AF, 0 }, + { 0x1EEB, 0x01B0, 0 }, + { 0x1EEC, 0x01AF, 3 }, + { 0x1EED, 0x01B0, 3 }, + { 0x1EEE, 0x01AF, 2 }, + { 0x1EEF, 0x01B0, 2 }, + { 0x1EF0, 0x01AF, 4 }, + { 0x1EF1, 0x01B0, 4 }, + { 0x1EF2, 0x0059, 0 }, + { 0x1EF3, 0x0079, 0 }, + { 0x1EF4, 0x0059, 4 }, + { 0x1EF5, 0x0079, 4 }, + { 0x1EF6, 0x0059, 3 }, + { 0x1EF7, 0x0079, 3 }, + { 0x1EF8, 0x0059, 2 }, + { 0x1EF9, 0x0079, 2 }, + { 0x1FED, 0x00A8, 0 }, + { 0x1FEE, 0x00A8, 1 }, +}; + +#endif /* _VIETCOMB_H */ diff --git a/graf2d/win32gdk/gdk/src/iconv/viscii.h b/graf2d/win32gdk/gdk/src/iconv/viscii.h new file mode 100644 index 0000000000000..04e68fa815366 --- /dev/null +++ b/graf2d/win32gdk/gdk/src/iconv/viscii.h @@ -0,0 +1,141 @@ +/* + * Copyright (C) 1999-2001 Free Software Foundation, Inc. + * This file is part of the GNU LIBICONV Library. + * + * The GNU LIBICONV Library is free software; you can redistribute it + * and/or modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * The GNU LIBICONV Library is distributed in the hope that it will be + * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with the GNU LIBICONV Library; see the file COPYING.LIB. + * If not, write to the Free Software Foundation, Inc., 51 Franklin Street, + * Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/* + * VISCII1.1-1 + */ + +/* Specification: RFC 1456 */ + +static const unsigned short viscii_2uni_1[32] = { + /* 0x00 */ + 0x0000, 0x0001, 0x1eb2, 0x0003, 0x0004, 0x1eb4, 0x1eaa, 0x0007, + 0x0008, 0x0009, 0x000a, 0x000b, 0x000c, 0x000d, 0x000e, 0x000f, + /* 0x10 */ + 0x0010, 0x0011, 0x0012, 0x0013, 0x1ef6, 0x0015, 0x0016, 0x0017, + 0x0018, 0x1ef8, 0x001a, 0x001b, 0x001c, 0x001d, 0x1ef4, 0x001f, +}; +static const unsigned short viscii_2uni_2[128] = { + /* 0x80 */ + 0x1ea0, 0x1eae, 0x1eb0, 0x1eb6, 0x1ea4, 0x1ea6, 0x1ea8, 0x1eac, + 0x1ebc, 0x1eb8, 0x1ebe, 0x1ec0, 0x1ec2, 0x1ec4, 0x1ec6, 0x1ed0, + /* 0x90 */ + 0x1ed2, 0x1ed4, 0x1ed6, 0x1ed8, 0x1ee2, 0x1eda, 0x1edc, 0x1ede, + 0x1eca, 0x1ece, 0x1ecc, 0x1ec8, 0x1ee6, 0x0168, 0x1ee4, 0x1ef2, + /* 0xa0 */ + 0x00d5, 0x1eaf, 0x1eb1, 0x1eb7, 0x1ea5, 0x1ea7, 0x1ea9, 0x1ead, + 0x1ebd, 0x1eb9, 0x1ebf, 0x1ec1, 0x1ec3, 0x1ec5, 0x1ec7, 0x1ed1, + /* 0xb0 */ + 0x1ed3, 0x1ed5, 0x1ed7, 0x1ee0, 0x01a0, 0x1ed9, 0x1edd, 0x1edf, + 0x1ecb, 0x1ef0, 0x1ee8, 0x1eea, 0x1eec, 0x01a1, 0x1edb, 0x01af, + /* 0xc0 */ + 0x00c0, 0x00c1, 0x00c2, 0x00c3, 0x1ea2, 0x0102, 0x1eb3, 0x1eb5, + 0x00c8, 0x00c9, 0x00ca, 0x1eba, 0x00cc, 0x00cd, 0x0128, 0x1ef3, + /* 0xd0 */ + 0x0110, 0x1ee9, 0x00d2, 0x00d3, 0x00d4, 0x1ea1, 0x1ef7, 0x1eeb, + 0x1eed, 0x00d9, 0x00da, 0x1ef9, 0x1ef5, 0x00dd, 0x1ee1, 0x01b0, + /* 0xe0 */ + 0x00e0, 0x00e1, 0x00e2, 0x00e3, 0x1ea3, 0x0103, 0x1eef, 0x1eab, + 0x00e8, 0x00e9, 0x00ea, 0x1ebb, 0x00ec, 0x00ed, 0x0129, 0x1ec9, + /* 0xf0 */ + 0x0111, 0x1ef1, 0x00f2, 0x00f3, 0x00f4, 0x00f5, 0x1ecf, 0x1ecd, + 0x1ee5, 0x00f9, 0x00fa, 0x0169, 0x1ee7, 0x00fd, 0x1ee3, 0x1eee, +}; + +static int +viscii_mbtowc (conv_t conv, ucs4_t *pwc, const unsigned char *s, int n) +{ + unsigned char c = *s; + if (c < 0x20) + *pwc = (ucs4_t) viscii_2uni_1[c]; + else if (c < 0x80) + *pwc = (ucs4_t) c; + else + *pwc = (ucs4_t) viscii_2uni_2[c-0x80]; + return 1; +} + +static const unsigned char viscii_page00[64+184] = { + 0xc0, 0xc1, 0xc2, 0xc3, 0x00, 0x00, 0x00, 0x00, /* 0xc0-0xc7 */ + 0xc8, 0xc9, 0xca, 0x00, 0xcc, 0xcd, 0x00, 0x00, /* 0xc8-0xcf */ + 0x00, 0x00, 0xd2, 0xd3, 0xd4, 0xa0, 0x00, 0x00, /* 0xd0-0xd7 */ + 0x00, 0xd9, 0xda, 0x00, 0x00, 0xdd, 0x00, 0x00, /* 0xd8-0xdf */ + 0xe0, 0xe1, 0xe2, 0xe3, 0x00, 0x00, 0x00, 0x00, /* 0xe0-0xe7 */ + 0xe8, 0xe9, 0xea, 0x00, 0xec, 0xed, 0x00, 0x00, /* 0xe8-0xef */ + 0x00, 0x00, 0xf2, 0xf3, 0xf4, 0xf5, 0x00, 0x00, /* 0xf0-0xf7 */ + 0x00, 0xf9, 0xfa, 0x00, 0x00, 0xfd, 0x00, 0x00, /* 0xf8-0xff */ + /* 0x0100 */ + 0x00, 0x00, 0xc5, 0xe5, 0x00, 0x00, 0x00, 0x00, /* 0x00-0x07 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x08-0x0f */ + 0xd0, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x10-0x17 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x18-0x1f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x20-0x27 */ + 0xce, 0xee, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x28-0x2f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x30-0x37 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x38-0x3f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x40-0x47 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x48-0x4f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x50-0x57 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x58-0x5f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x60-0x67 */ + 0x9d, 0xfb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x68-0x6f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x70-0x77 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x78-0x7f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x80-0x87 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x88-0x8f */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x90-0x97 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0x98-0x9f */ + 0xb4, 0xbd, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xa0-0xa7 */ + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xbf, /* 0xa8-0xaf */ + 0xdf, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xb0-0xb7 */ +}; +static const unsigned char viscii_page1e[96] = { + 0x80, 0xd5, 0xc4, 0xe4, 0x84, 0xa4, 0x85, 0xa5, /* 0xa0-0xa7 */ + 0x86, 0xa6, 0x06, 0xe7, 0x87, 0xa7, 0x81, 0xa1, /* 0xa8-0xaf */ + 0x82, 0xa2, 0x02, 0xc6, 0x05, 0xc7, 0x83, 0xa3, /* 0xb0-0xb7 */ + 0x89, 0xa9, 0xcb, 0xeb, 0x88, 0xa8, 0x8a, 0xaa, /* 0xb8-0xbf */ + 0x8b, 0xab, 0x8c, 0xac, 0x8d, 0xad, 0x8e, 0xae, /* 0xc0-0xc7 */ + 0x9b, 0xef, 0x98, 0xb8, 0x9a, 0xf7, 0x99, 0xf6, /* 0xc8-0xcf */ + 0x8f, 0xaf, 0x90, 0xb0, 0x91, 0xb1, 0x92, 0xb2, /* 0xd0-0xd7 */ + 0x93, 0xb5, 0x95, 0xbe, 0x96, 0xb6, 0x97, 0xb7, /* 0xd8-0xdf */ + 0xb3, 0xde, 0x94, 0xfe, 0x9e, 0xf8, 0x9c, 0xfc, /* 0xe0-0xe7 */ + 0xba, 0xd1, 0xbb, 0xd7, 0xbc, 0xd8, 0xff, 0xe6, /* 0xe8-0xef */ + 0xb9, 0xf1, 0x9f, 0xcf, 0x1e, 0xdc, 0x14, 0xd6, /* 0xf0-0xf7 */ + 0x19, 0xdb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0xf8-0xff */ +}; + +static int +viscii_wctomb (conv_t conv, unsigned char *r, ucs4_t wc, int n) +{ + unsigned char c = 0; + if (wc < 0x0080 && (wc >= 0x0020 || (0x42100064 & (1 << wc)) == 0)) { + *r = wc; + return 1; + } + else if (wc >= 0x00c0 && wc < 0x01b8) + c = viscii_page00[wc-0x00c0]; + else if (wc >= 0x1ea0 && wc < 0x1f00) + c = viscii_page1e[wc-0x1ea0]; + if (c != 0) { + *r = c; + return 1; + } + return RET_ILUNI; +} diff --git a/graf2d/win32gdk/inc/TGWin32.h b/graf2d/win32gdk/inc/TGWin32.h index 44815569ef5fb..af82a8f858ccf 100644 --- a/graf2d/win32gdk/inc/TGWin32.h +++ b/graf2d/win32gdk/inc/TGWin32.h @@ -169,6 +169,8 @@ class TGWin32 : public TVirtualX { void DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, const char *text, ETextMode mode); + void DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, + const wchar_t *text, ETextMode mode); void SetTextFont(Font_t fontnumber); Int_t SetTextFont(char *fontname, ETextSetMode mode); void SetTextSize(Float_t textsize); @@ -193,6 +195,7 @@ class TGWin32 : public TVirtualX { void GetPlanes(Int_t &nplanes); void GetRGB(Int_t index, Float_t &r, Float_t &g, Float_t &b); virtual void GetTextExtent(UInt_t &w, UInt_t &h, char *mess); + virtual void GetTextExtent(UInt_t &, UInt_t &, wchar_t *){} Float_t GetTextMagnitude() {return fTextMagnitude;} Window_t GetWindowID(Int_t wid); Bool_t HasTTFonts() const { return fHasTTFonts; } diff --git a/graf2d/win32gdk/inc/TGWin32InterpreterProxy.h b/graf2d/win32gdk/inc/TGWin32InterpreterProxy.h index aa2200da084eb..6992a7836db92 100644 --- a/graf2d/win32gdk/inc/TGWin32InterpreterProxy.h +++ b/graf2d/win32gdk/inc/TGWin32InterpreterProxy.h @@ -59,6 +59,7 @@ class TGWin32InterpreterProxy : public TInterpreter , public TGWin32ProxyBase { Long_t ProcessLine(const char *line, EErrorCode *error = 0); Long_t ProcessLineSynch(const char *line, EErrorCode *error = 0); void PrintIntro(); + Int_t SetClassSharedLibs(const char *cls, const char *libs); void SetGetline(const char*(*getlineFunc)(const char* prompt), void (*histaddFunc)(const char* line)); void Reset(); @@ -67,6 +68,7 @@ class TGWin32InterpreterProxy : public TInterpreter , public TGWin32ProxyBase { void ResetGlobalVar(void *obj); void RewindDictionary(); Int_t DeleteGlobal(void *obj); + Int_t DeleteVariable(const char* name) ; void SaveContext(); void SaveGlobalsContext(); void UpdateListOfGlobals(); diff --git a/graf2d/win32gdk/inc/TGWin32VirtualXProxy.h b/graf2d/win32gdk/inc/TGWin32VirtualXProxy.h index b7de1388f045d..6909be6cf4845 100644 --- a/graf2d/win32gdk/inc/TGWin32VirtualXProxy.h +++ b/graf2d/win32gdk/inc/TGWin32VirtualXProxy.h @@ -55,6 +55,7 @@ friend class TGWin32; void DrawPolyLine(Int_t n, TPoint *xy); void DrawPolyMarker(Int_t n, TPoint *xy); void DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, const char *text, ETextMode mode); + void DrawText(Int_t, Int_t, Float_t, Float_t, const wchar_t *, ETextMode){} void GetCharacterUp(Float_t &chupx, Float_t &chupy); EDrawMode GetDrawMode(); Int_t GetDoubleBuffer(Int_t wid); @@ -65,6 +66,7 @@ friend class TGWin32; void GetPlanes(Int_t &nplanes); void GetRGB(Int_t index, Float_t &r, Float_t &g, Float_t &b); void GetTextExtent(UInt_t &w, UInt_t &h, char *mess); + void GetTextExtent(UInt_t &, UInt_t &, wchar_t *){} Float_t GetTextMagnitude(); Window_t GetWindowID(Int_t wid); Bool_t HasTTFonts() const; diff --git a/graf2d/win32gdk/src/TGWin32.cxx b/graf2d/win32gdk/src/TGWin32.cxx index 2b5e1f0bcd6e7..9279a2f2ee72f 100644 --- a/graf2d/win32gdk/src/TGWin32.cxx +++ b/graf2d/win32gdk/src/TGWin32.cxx @@ -438,7 +438,6 @@ static void W32ChangeProperty(HWND w, Atom_t property, Atom_t type, char *atomName; char buffer[256]; - char *p, *s; int len; char propName[32]; @@ -466,11 +465,9 @@ static int _GetWindowProperty(GdkWindow * id, Atom_t property, Long_t long_offse if (!id) return 0; - char *atomName; char *data, *destPtr; char propName[32]; HGLOBAL handle; - HGLOBAL hMem; HWND w; w = (HWND) GDK_DRAWABLE_XID(id); @@ -1354,6 +1351,21 @@ void TGWin32::DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, RenderString(x, y, mode); } +//______________________________________________________________________________ +void TGWin32::DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, + const wchar_t *text, ETextMode mode) +{ + // Draw text using TrueType fonts. If TrueType fonts are not available the + // text is drawn with TGWin32::DrawText. + + if (!TTF::IsInitialized()) TTF::Init(); + TTF::SetRotationMatrix(angle); + TTF::PrepareString(text); + TTF::LayoutGlyphs(); + Align(); + RenderString(x, y, mode); +} + //______________________________________________________________________________ GdkImage *TGWin32::GetBackground(Int_t x, Int_t y, UInt_t w, UInt_t h) { @@ -2076,12 +2088,10 @@ Int_t TGWin32::OpenPixmap(unsigned int w, unsigned int h) // Open a new pixmap. // w,h : Width and height of the pixmap. - GdkWindow root; - int wval, hval; - int xx, yy, i, wid; - int ww, hh, border, depth; - wval = w; - hval = h; + int i, wid; + int ww, hh, depth; + int wval = w; + int hval = h; // Select next free window number again: @@ -2138,10 +2148,8 @@ Int_t TGWin32::InitWindow(ULong_t win) GdkWindowAttr attributes; unsigned long attr_mask = 0; - int wid; - int xval, yval; - int wval, hval, border, depth; - GdkWindow root; + int wid, xval, yval; + int wval, hval, depth; GdkWindow *wind = (GdkWindow *) win; @@ -2290,7 +2298,6 @@ Int_t TGWin32::RequestLocator(Int_t mode, Int_t ctyp, Int_t & x, Int_t & y) Int_t xtmp, ytmp; GdkEvent *event; - GdkEvent *next_event; int button_press; int radius; @@ -2442,14 +2449,12 @@ Int_t TGWin32::RequestString(int x, int y, char *text) static int percent = 0; // bell volume static GdkWindow *CurWnd; HWND focuswindow; - int focusrevert; GdkEvent *event; KeySym keysym; int key = -1; int len_text = strlen(text); int nt; // defined length of text int pt; // cursor position in text - MSG msg; CurWnd = (GdkWindow *)gCws->window; // change the cursor shape @@ -2717,12 +2722,9 @@ int TGWin32::ResizePixmap(int wid, unsigned int w, unsigned int h) // wid : pixmap to be resized // w,h : Width and height of the pixmap - GdkWindow root; - int wval, hval; - int xx, yy, i; - int ww, hh, border, depth; - wval = w; - hval = h; + int i, ww, hh, depth; + int wval = w; + int hval = h; if (!fWindows) return 0; @@ -3052,8 +3054,6 @@ void TGWin32::SetDoubleBufferON() { // Turn double buffer mode on. - Int_t depth; - if (!fWindows || gTws->double_buffer || gTws->ispixmap) return; if (!gTws->buffer) { @@ -3157,7 +3157,6 @@ void TGWin32::UpdateFillStyle() { // Set fill area style index. - char* pchar; static int current_fasi = 0; Int_t style = fFillStyle / 1000; @@ -3246,7 +3245,7 @@ void TGWin32::SetLineType(int n, int *dash) (GdkCapStyle) gCapStyle, (GdkJoinStyle) gJoinStyle); } else { - int i, j; + int i; gDashSize = TMath::Min((int)sizeof(gDashList),n); gDashLength = 0; for (i = 0; i < gDashSize; i++) { @@ -4348,8 +4347,6 @@ void TGWin32::MapSubwindows(Window_t id) // if (!id) return; - - HWND wp; EnumChildWindows((HWND)GDK_DRAWABLE_XID((GdkWindow *)id), EnumChildProc, (LPARAM) NULL); } @@ -4533,12 +4530,10 @@ Window_t TGWin32::CreateWindow(Window_t parent, Int_t x, Int_t y, { // Return handle to newly created gdk window. - GdkWMDecoration deco; GdkWindowAttr xattr; GdkWindow *newWin; GdkColor background_color; ULong_t xmask = 0; - UInt_t xevmask; if (attr) { MapSetWindowAttributes(attr, xmask, xattr); @@ -5019,7 +5014,6 @@ void TGWin32::GetWindowAttributes(Window_t id, WindowAttributes_t & attr) if (!id) return; - GdkWindowAttr xattr; RECT rcClient, rcWind; ::GetClientRect((HWND)GDK_DRAWABLE_XID((GdkWindow *) id), &rcClient); ::GetWindowRect((HWND)GDK_DRAWABLE_XID((GdkWindow *) id), &rcWind); @@ -6060,12 +6054,9 @@ void TGWin32::ChangeWindowAttributes(Window_t id, SetWindowAttributes_t * attr) if (!id) return; - GdkWMDecoration deco; GdkColor color; - GdkEventMask xevent_mask; UInt_t xevmask; Mask_t evmask; - HWND w, flag; if (attr && (attr->fMask & kWAEventMask)) { evmask = (Mask_t) attr->fEventMask; @@ -6270,7 +6261,7 @@ void TGWin32::SetClassHints(Window_t id, char *className, char *resourceName) char *class_string; char *s; int len_nm, len_cl; - GdkAtom type, prop; + GdkAtom prop; prop = gdk_atom_intern("WM_CLASS", kFALSE); @@ -6407,7 +6398,7 @@ void TGWin32::DrawString(Drawable_t id, GContext_t gc, Int_t x, Int_t y, //______________________________________________________________________________ Int_t TGWin32::TextWidth(FontStruct_t font, const char *s, Int_t len) { - // Return lenght of string in pixels. Size depends on font. + // Return length of string in pixels. Size depends on font. return gdk_text_width((GdkFont *)font, s, len); } @@ -6592,7 +6583,6 @@ void TGWin32::LookupString(Event_t * event, char *buf, Int_t buflen, // keyboard mapping). In buf a null terminated ASCII string is returned // representing the string that is currently mapped to the key code. - KeySym xkeysym; _lookup_string(event, buf, buflen); UInt_t ks, xks = (UInt_t) event->fCode; MapKeySym(ks, xks, kFALSE); @@ -6754,7 +6744,7 @@ void TGWin32::QueryPointer(Window_t id, Window_t &rootw, if (!id) return; - POINT mousePt, sPt, currPt; + POINT currPt; HWND chw, window; UInt_t umask = 0; BYTE kbd[256]; @@ -7431,7 +7421,7 @@ void TGWin32::ChangeProperties(Window_t id, Atom_t property, Atom_t type, // Put data into Clipboard. HGLOBAL hdata; - Int_t i, length; + Int_t i; UChar_t *ptr; if (data == 0 || len == 0) @@ -7467,11 +7457,9 @@ Window_t TGWin32::FindRWindow(Window_t root, Window_t dragwin, Window_t input, // location x, y and is DND aware, with a maximum depth of maxd. // Possibility to exclude dragwin and input. - POINT screen_point, point; - POINT cpt; + POINT cpt, point; RECT rect; - HWND hwnd, hwndc; - HWND hwndt; + HWND hwnd, hwndc, hwndt; Window_t win, retwin = kNone; Atom_t version = 0; Atom_t dndaware = InternAtom("XdndAware", kFALSE); diff --git a/graf2d/win32gdk/src/TGWin32InterpreterProxy.cxx b/graf2d/win32gdk/src/TGWin32InterpreterProxy.cxx index e2fb476d01dfc..755db3a342778 100644 --- a/graf2d/win32gdk/src/TGWin32InterpreterProxy.cxx +++ b/graf2d/win32gdk/src/TGWin32InterpreterProxy.cxx @@ -60,6 +60,7 @@ RETURN_METHOD_ARG2(Interpreter,Long_t,ProcessLineSynch,const char*,line,TInterpr VOID_METHOD_ARG0(Interpreter,PrintIntro,1) typedef const char* (*GetlineFunc_t)(const char* prompt); typedef void (*HistaddFunc_t)(const char* line); +RETURN_METHOD_ARG2(Interpreter,Int_t,SetClassSharedLibs,const char*,cls,const char*,libs); VOID_METHOD_ARG2(Interpreter,SetGetline,GetlineFunc_t, getlineFunc,\ HistaddFunc_t, histaddFunc, 1) VOID_METHOD_ARG0(Interpreter,Reset,1) @@ -68,6 +69,7 @@ VOID_METHOD_ARG0(Interpreter,ResetGlobals,1) VOID_METHOD_ARG1(Interpreter,ResetGlobalVar,void*,obj,1) VOID_METHOD_ARG0(Interpreter,RewindDictionary,1) RETURN_METHOD_ARG1(Interpreter,Int_t,DeleteGlobal,void*,obj) +RETURN_METHOD_ARG1(Interpreter,Int_t,DeleteVariable,const char*,name) VOID_METHOD_ARG0(Interpreter,SaveContext,1) VOID_METHOD_ARG0(Interpreter,SaveGlobalsContext,1) VOID_METHOD_ARG0_LOCK(Interpreter,UpdateListOfGlobals) diff --git a/graf2d/win32gdk/src/gifquantize.c b/graf2d/win32gdk/src/gifquantize.c index 754e519b83d36..c1c8b175ed48b 100644 --- a/graf2d/win32gdk/src/gifquantize.c +++ b/graf2d/win32gdk/src/gifquantize.c @@ -58,7 +58,7 @@ static int SortCmpRtn(const void *Entry1, const void *Entry2); * ColorMapSize specifies size of color map up to 256 and will be updated to * * real size before returning. * * Also non of the parameter are allocated by this routine. * -* This function returns GIF_OK if succesfull, GIF_ERROR otherwise. * +* This function returns GIF_OK if successful, GIF_ERROR otherwise. * ******************************************************************************/ int GIFquantize(unsigned int Width, unsigned int Height, int *ColorMapSize, byte *RedInput, byte *GreenInput, byte *BlueInput, diff --git a/graf2d/x11/CMakeLists.txt b/graf2d/x11/CMakeLists.txt index 92aee4acab413..da4dbac330c8a 100644 --- a/graf2d/x11/CMakeLists.txt +++ b/graf2d/x11/CMakeLists.txt @@ -5,6 +5,7 @@ set(libname GX11) ROOT_USE_PACKAGE(core) +include_directories(${X11_INCLUDE_DIR}) ROOT_GENERATE_DICTIONARY(G__${libname} T*.h LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(${libname} LINKDEF LinkDef.h) diff --git a/graf2d/x11/inc/TGX11.h b/graf2d/x11/inc/TGX11.h index 699fbd0dc8f13..1f383e86b2e32 100644 --- a/graf2d/x11/inc/TGX11.h +++ b/graf2d/x11/inc/TGX11.h @@ -192,6 +192,7 @@ class TGX11 : public TVirtualX { void DrawPolyLine(Int_t n, TPoint *xy); void DrawPolyMarker(Int_t n, TPoint *xy); virtual void DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, const char *text, ETextMode mode); + virtual void DrawText(Int_t, Int_t, Float_t, Float_t, const wchar_t *, ETextMode) {} void GetCharacterUp(Float_t &chupx, Float_t &chupy); Int_t GetDoubleBuffer(Int_t wid); void GetGeometry(Int_t wid, Int_t &x, Int_t &y, UInt_t &w, UInt_t &h); @@ -201,6 +202,7 @@ class TGX11 : public TVirtualX { void GetPlanes(Int_t &nplanes); void GetRGB(Int_t index, Float_t &r, Float_t &g, Float_t &b); virtual void GetTextExtent(UInt_t &w, UInt_t &h, char *mess); + virtual void GetTextExtent(UInt_t &, UInt_t &, wchar_t *){} Float_t GetTextMagnitude() { return fTextMagnitude; } Window_t GetWindowID(Int_t wid); Bool_t HasTTFonts() const { return fHasTTFonts; } diff --git a/graf2d/x11/src/GX11Gui.cxx b/graf2d/x11/src/GX11Gui.cxx index 9d99243145767..cc33b5cc02b49 100644 --- a/graf2d/x11/src/GX11Gui.cxx +++ b/graf2d/x11/src/GX11Gui.cxx @@ -2058,7 +2058,7 @@ void TGX11::DrawString(Drawable_t id, GContext_t gc, Int_t x, Int_t y, //______________________________________________________________________________ Int_t TGX11::TextWidth(FontStruct_t font, const char *s, Int_t len) { - // Return lenght of string in pixels. Size depends on font. + // Return length of string in pixels. Size depends on font. return XTextWidth((XFontStruct*) font, (char*) s, len); } diff --git a/graf2d/x11/src/gifquantize.c b/graf2d/x11/src/gifquantize.c index ac15634706bce..b060751ae03a9 100644 --- a/graf2d/x11/src/gifquantize.c +++ b/graf2d/x11/src/gifquantize.c @@ -58,7 +58,7 @@ static int SortCmpRtn(const void *Entry1, const void *Entry2); * ColorMapSize specifies size of color map up to 256 and will be updated to * * real size before returning. * * Also non of the parameter are allocated by this routine. * -* This function returns GIF_OK if succesfull, GIF_ERROR otherwise. * +* This function returns GIF_OK if successful, GIF_ERROR otherwise. * ******************************************************************************/ int GIFquantize(unsigned int Width, unsigned int Height, int *ColorMapSize, byte *RedInput, byte *GreenInput, byte *BlueInput, diff --git a/graf2d/x11ttf/CMakeLists.txt b/graf2d/x11ttf/CMakeLists.txt index 62e153d90b1b4..20a9ab7c20393 100644 --- a/graf2d/x11ttf/CMakeLists.txt +++ b/graf2d/x11ttf/CMakeLists.txt @@ -12,7 +12,7 @@ ROOT_GENERATE_DICTIONARY(G__${libname} *.h LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(${libname} LINKDEF LinkDef.h DEPENDENCIES GX11 Graf) ROOT_LINKER_LIBRARY(${libname} *.cxx G__${libname}.cxx - LIBRARIES ${X11_LIBRARIES} ${X11_Xpm_LIB} ${X11_Xft_LIB} ${FREETYPE_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} + LIBRARIES ${X11_LIBRARIES} ${X11_Xpm_LIB} ${X11_Xft_LIB} ${FREETYPE_LIBRARIES} ${ZLIB_LIBRARY} ${CMAKE_THREAD_LIBS_INIT} DEPENDENCIES GX11 Graf) ROOT_INSTALL_HEADERS() diff --git a/graf2d/x11ttf/inc/TGX11TTF.h b/graf2d/x11ttf/inc/TGX11TTF.h index 8831f401adec5..92142e4a73781 100644 --- a/graf2d/x11ttf/inc/TGX11TTF.h +++ b/graf2d/x11ttf/inc/TGX11TTF.h @@ -68,6 +68,8 @@ class TGX11TTF : public TGX11 { Bool_t Init(void *display); void DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, const char *text, ETextMode mode); + void DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, + const wchar_t *text, ETextMode mode); void SetTextFont(Font_t fontnumber); Int_t SetTextFont(char *fontname, ETextSetMode mode); void SetTextSize(Float_t textsize); diff --git a/graf2d/x11ttf/src/TGX11TTF.cxx b/graf2d/x11ttf/src/TGX11TTF.cxx index cb48debcd41b2..aaf495f04a281 100644 --- a/graf2d/x11ttf/src/TGX11TTF.cxx +++ b/graf2d/x11ttf/src/TGX11TTF.cxx @@ -350,6 +350,25 @@ void TGX11TTF::DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, } } +//______________________________________________________________________________ +void TGX11TTF::DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn, + const wchar_t *text, ETextMode mode) +{ + // Draw text using TrueType fonts. If TrueType fonts are not available the + // text is drawn with TGX11::DrawText. + + if (!fHasTTFonts) { + TGX11::DrawText(x, y, angle, mgn, text, mode); + } else { + if (!TTF::fgInit) TTF::Init(); + TTF::SetRotationMatrix(angle); + TTF::PrepareString(text); + TTF::LayoutGlyphs(); + Align(); + RenderString(x, y, mode); + } +} + //______________________________________________________________________________ XImage *TGX11TTF::GetBackground(Int_t x, Int_t y, UInt_t w, UInt_t h) { @@ -591,7 +610,7 @@ void TGX11TTF::DeleteFont(FontStruct_t fs) //______________________________________________________________________________ Int_t TGX11TTF::TextWidth(FontStruct_t font, const char *s, Int_t len) { - // Return lenght of string in pixels. Size depends on font + // Return length of string in pixels. Size depends on font if (!fXftFontHash) { return TGX11::TextWidth(font, s, len); diff --git a/graf3d/CMakeLists.txt b/graf3d/CMakeLists.txt index fde5b9d95fb44..d9f67c32e66cd 100644 --- a/graf3d/CMakeLists.txt +++ b/graf3d/CMakeLists.txt @@ -1,5 +1,5 @@ add_subdirectory(g3d) # special CMakeLists.txt -if(NOT WIN32) +if(NOT WIN32 AND x11) add_subdirectory(x3d) # special CMakeLists.txt endif() if (opengl) diff --git a/graf3d/eve/Module.mk b/graf3d/eve/Module.mk index c417049c383b6..3a4cb8ece8f1d 100644 --- a/graf3d/eve/Module.mk +++ b/graf3d/eve/Module.mk @@ -106,6 +106,9 @@ else $(EVEO) $(EVEDO): CXXFLAGS += $(OPENGLINCDIR:%=-I%) $(FTGLINCDIR:%=-I%) $(FTGLCPPFLAGS) $(EVEO): CXXFLAGS += $(GLEWINCDIR:%=-I%) $(GLEWCPPFLAGS) endif +ifeq ($(MACOSX_GLU_DEPRECATED),yes) +$(EVEO) $(EVEDO): CXXFLAGS += -Wno-deprecated-declarations +endif $(MODNAME)-echo-h1: @echo $(EVEH1) diff --git a/graf3d/eve/doc/index.txt b/graf3d/eve/doc/index.txt index 6ae3018f3b054..6924fd4268880 100644 --- a/graf3d/eve/doc/index.txt +++ b/graf3d/eve/doc/index.txt @@ -2,7 +2,7 @@ BEGIN_HTML <center><h1>The Event Display classes</h1></center> <p><hr><p> - Eve is a ROOT module based on experiment-independant part of the + Eve is a ROOT module based on experiment-independent part of the ALICE event display developed in cooperation between ALICE offline project and ROOT during the last two years. It has been used in ALICE for more than a year to perform high-level event diff --git a/graf3d/eve/inc/LinkDef1.h b/graf3d/eve/inc/LinkDef1.h index 85878241127ee..5b1e02b0f5e3f 100644 --- a/graf3d/eve/inc/LinkDef1.h +++ b/graf3d/eve/inc/LinkDef1.h @@ -164,6 +164,7 @@ #pragma link C++ class TEveListTreeItem+; #pragma link C++ class TEveGListTreeEditorFrame+; #pragma link C++ class TEveBrowser+; +#pragma link C++ class TEveContextMenu+; #pragma link C++ class TEveCompositeFrame+; #pragma link C++ class TEveCompositeFrameInMainFrame+; #pragma link C++ class TEveCompositeFrameInPack+; diff --git a/graf3d/eve/inc/TEveBrowser.h b/graf3d/eve/inc/TEveBrowser.h index 18acd541432ef..723398c64cda8 100644 --- a/graf3d/eve/inc/TEveBrowser.h +++ b/graf3d/eve/inc/TEveBrowser.h @@ -143,12 +143,15 @@ class TEveBrowser : public TRootBrowser TEveBrowser(UInt_t w, UInt_t h); virtual ~TEveBrowser() {} - void ReallyDelete(); + virtual void ReallyDelete(); + virtual void CloseTab(Int_t id); + virtual void CloseWindow(); void InitPlugins(Option_t *opt="FI"); - TGFileBrowser* MakeFileBrowser(); - TGFileBrowser* GetFileBrowser() const { return fFileBrowser; } + TGFileBrowser* MakeFileBrowser(Bool_t make_default=kFALSE); + TGFileBrowser* GetFileBrowser() const; + void SetFileBrowser(TGFileBrowser* b); void EveMenu(Int_t id); @@ -158,6 +161,8 @@ class TEveBrowser : public TRootBrowser void HideBottomTab(); + void SanitizeTabCounts(); + ClassDef(TEveBrowser, 0); // Specialization of TRootBrowser for Eve. }; diff --git a/graf3d/eve/inc/TEveCalo.h b/graf3d/eve/inc/TEveCalo.h index 9458e2a46e584..4ff2e7b63efef 100644 --- a/graf3d/eve/inc/TEveCalo.h +++ b/graf3d/eve/inc/TEveCalo.h @@ -48,7 +48,8 @@ class TEveCaloViz : public TEveElement, Bool_t fAutoRange; // set eta phi limits on DataChanged() Float_t fBarrelRadius; // barrel raidus in cm - Float_t fEndCapPos; // end cap z coordinate in cm + Float_t fEndCapPosF; // forward end cap z coordinate in cm + Float_t fEndCapPosB; // backward end cap z coordinate in cm (should be < 0) Float_t fPlotEt; // plot E or Et. @@ -79,7 +80,7 @@ class TEveCaloViz : public TEveElement, virtual TClass* ProjectedClass(const TEveProjection* p) const; virtual Float_t GetValToHeight() const; virtual void CellSelectionChanged() {} - + virtual void SetScaleAbs(Bool_t x) { fScaleAbs = x; } TEveCaloData* GetData() const { return fData; } @@ -97,8 +98,12 @@ class TEveCaloViz : public TEveElement, Float_t GetBarrelRadius() const { return fBarrelRadius; } void SetBarrelRadius(Float_t r) { fBarrelRadius = r; ResetBBox(); } - Float_t GetEndCapPos () const { return fEndCapPos; } - void SetEndCapPos (Float_t z) { fEndCapPos = z; ResetBBox(); } + Float_t GetEndCapPos () const { return fEndCapPosF; } // get end cap position, assuming fEndCapPosF = -fEndCapPosB + Float_t GetForwardEndCapPos () const { return fEndCapPosF; } + Float_t GetBackwardEndCapPos () const { return fEndCapPosB; } + void SetEndCapPos (Float_t z) { fEndCapPosF = z; fEndCapPosB = -z; ResetBBox(); } + void SetForwardEndCapPos (Float_t z) { fEndCapPosF = z; ResetBBox(); } + void SetBackwardEndCapPos(Float_t z) { fEndCapPosB = z; ResetBBox(); } Bool_t GetPlotEt() const { return fPlotEt; } void SetPlotEt(Bool_t x); @@ -110,7 +115,11 @@ class TEveCaloViz : public TEveElement, Float_t GetMaxValAbs() const { return fMaxValAbs; } Float_t GetTransitionEta() const; + Float_t GetTransitionEtaForward() const; + Float_t GetTransitionEtaBackward() const; Float_t GetTransitionTheta() const; + Float_t GetTransitionThetaForward() const; + Float_t GetTransitionThetaBackward() const; TEveRGBAPalette* GetPalette() const { return fPalette; } void SetPalette(TEveRGBAPalette* p); diff --git a/graf3d/eve/inc/TEveGeoShape.h b/graf3d/eve/inc/TEveGeoShape.h index e6dd37370c209..050582998b5f3 100644 --- a/graf3d/eve/inc/TEveGeoShape.h +++ b/graf3d/eve/inc/TEveGeoShape.h @@ -15,6 +15,7 @@ #include "TEveShape.h" class TGeoShape; +class TGeoHMatrix; class TGeoCompositeShape; class TEveGeoShapeExtract; class TBuffer3D; @@ -63,6 +64,7 @@ class TEveGeoShape : public TEveShape virtual TClass* ProjectedClass(const TEveProjection* p) const; static TGeoManager* GetGeoMangeur(); + static TGeoHMatrix* GetGeoHMatrixIdentity(); ClassDef(TEveGeoShape, 2); // Wrapper for TGeoShape with absolute positioning and color attributes allowing display of extracted TGeoShape's (without an active TGeoManager) and simplified geometries (needed for NLT projections). }; diff --git a/graf3d/eve/inc/TEveLine.h b/graf3d/eve/inc/TEveLine.h index 177a8b79a003f..974dedcd7187c 100644 --- a/graf3d/eve/inc/TEveLine.h +++ b/graf3d/eve/inc/TEveLine.h @@ -56,7 +56,8 @@ class TEveLine : public TEvePointSet, void SetRnrPoints(Bool_t r); void SetSmooth(Bool_t r); - void ReduceSegmentLengths(Float_t max); + void ReduceSegmentLengths(Float_t max); + Float_t CalculateLineLength() const; TEveVector GetLineStart() const; TEveVector GetLineEnd() const; diff --git a/graf3d/eve/inc/TEvePathMark.h b/graf3d/eve/inc/TEvePathMark.h index 72475e306338f..e47ba6641137d 100644 --- a/graf3d/eve/inc/TEvePathMark.h +++ b/graf3d/eve/inc/TEvePathMark.h @@ -22,7 +22,7 @@ template <typename TT> class TEvePathMarkT { public: - enum EType_e { kReference, kDaughter, kDecay, kCluster2D }; + enum EType_e { kReference, kDaughter, kDecay, kCluster2D, kLineSegment }; EType_e fType; // Mark-type. TEveVectorT<TT> fV; // Vertex. diff --git a/graf3d/eve/inc/TEveTrack.h b/graf3d/eve/inc/TEveTrack.h index 10cb4770b01cf..da3cc5f073c45 100644 --- a/graf3d/eve/inc/TEveTrack.h +++ b/graf3d/eve/inc/TEveTrack.h @@ -51,6 +51,7 @@ class TEveTrack : public TEveLine TEveVectorD fP; // Starting momentum TEveVectorD fPEnd; // Momentum at the last point of extrapolation Double_t fBeta; // Relativistic beta factor + Double_t fDpDs; // Momentum loss over distance Int_t fPdg; // PDG code Int_t fCharge; // Charge in units of e0 Int_t fLabel; // Simulation label @@ -89,6 +90,9 @@ class TEveTrack : public TEveLine const TEveVectorD& GetMomentum() const { return fP; } const TEveVectorD& GetEndMomentum() const { return fPEnd; } + Double_t GetDpDs() const { return fDpDs; } + void SetDpDs(Double_t dpds) { fDpDs = dpds; } + Int_t GetPdg() const { return fPdg; } void SetPdg(Int_t pdg) { fPdg = pdg; } Int_t GetCharge() const { return fCharge; } diff --git a/graf3d/eve/inc/TEveTrackPropagator.h b/graf3d/eve/inc/TEveTrackPropagator.h index 274dc7fa5d3b6..f8709cd126a84 100644 --- a/graf3d/eve/inc/TEveTrackPropagator.h +++ b/graf3d/eve/inc/TEveTrackPropagator.h @@ -176,6 +176,8 @@ class TEveTrackPropagator : public TEveElementList, TEveTrackPropagator(const TEveTrackPropagator&); // Not implemented TEveTrackPropagator& operator=(const TEveTrackPropagator&); // Not implemented + void DistributeOffset(const TEveVectorD& off, Int_t first_point, Int_t np, TEveVectorD& p); + protected: EStepper_e fStepper; @@ -195,6 +197,7 @@ class TEveTrackPropagator : public TEveElementList, Bool_t fFitReferences; // Pass through given track-references when extrapolating a track. Bool_t fFitDecay; // Pass through decay point when extrapolating a track. Bool_t fFitCluster2Ds; // Pass through 2D-clusters when extrapolating a track. + Bool_t fFitLineSegments; // Pass through line when extrapolating a track. Bool_t fRnrDaughters; // Render daughter path-marks. Bool_t fRnrReferences; // Render track-reference path-marks. Bool_t fRnrDecay; // Render decay path-marks. @@ -220,6 +223,7 @@ class TEveTrackPropagator : public TEveElementList, void Step(const TEveVector4D &v, const TEveVectorD &p, TEveVector4D &vOut, TEveVectorD &pOut); Bool_t LoopToVertex(TEveVectorD& v, TEveVectorD& p); + Bool_t LoopToLineSegment(const TEveVectorD& s, const TEveVectorD& r, TEveVectorD& p); void LoopToBounds(TEveVectorD& p); Bool_t LineToVertex (TEveVectorD& v); @@ -231,8 +235,10 @@ class TEveTrackPropagator : public TEveElementList, TEveVectorD&itsect); Bool_t LineIntersectPlane(const TEveVectorD& p, const TEveVectorD& point, const TEveVectorD& normal, TEveVectorD& itsect); + Bool_t PointOverVertex(const TEveVector4D& v0, const TEveVector4D& v, Double_t* p=0); - Bool_t PointOverVertex(const TEveVector4D& v0, const TEveVector4D& v, Double_t* p=0); + void ClosestPointFromVertexToLineSegment(const TEveVectorD& v, const TEveVectorD& s, const TEveVectorD& r, Double_t rMagInv, TEveVectorD& c); + Bool_t ClosestPointBetweenLines(const TEveVectorD&, const TEveVectorD&, const TEveVectorD&, const TEveVectorD&, TEveVectorD& out); public: TEveTrackPropagator(const char* n="TEveTrackPropagator", const char* t="", @@ -248,13 +254,19 @@ class TEveTrackPropagator : public TEveElementList, // propagation void InitTrack(const TEveVectorD& v, Int_t charge); void ResetTrack(); - void GoToBounds(TEveVectorD& p); - Bool_t GoToVertex(TEveVectorD& v, TEveVectorD& p); + + Int_t GetCurrentPoint() const; + Double_t GetTrackLength(Int_t start_point=0, Int_t end_point=-1) const; + + virtual void GoToBounds(TEveVectorD& p); + virtual Bool_t GoToVertex(TEveVectorD& v, TEveVectorD& p); + virtual Bool_t GoToLineSegment(const TEveVectorD& s, const TEveVectorD& r, TEveVectorD& p); // TEveVectorF wrappers void InitTrack(const TEveVectorF& v, Int_t charge); void GoToBounds(TEveVectorF& p); Bool_t GoToVertex(TEveVectorF& v, TEveVectorF&p); + Bool_t GoToLineSegment(const TEveVectorF& s, const TEveVectorF& r, TEveVectorF& p); Bool_t IntersectPlane(const TEveVectorD& p, const TEveVectorD& point, const TEveVectorD& normal, TEveVectorD& itsect); @@ -284,6 +296,7 @@ class TEveTrackPropagator : public TEveElementList, void SetFitReferences(Bool_t x); void SetFitDecay(Bool_t x); void SetFitCluster2Ds(Bool_t x); + void SetFitLineSegments(Bool_t x); void SetRnrFV(Bool_t x); void SetProjTrackBreaking(UChar_t x); void SetRnrPTBMarkers(Bool_t x); @@ -310,6 +323,7 @@ class TEveTrackPropagator : public TEveElementList, Bool_t GetFitReferences() const { return fFitReferences; } Bool_t GetFitDecay() const { return fFitDecay; } Bool_t GetFitCluster2Ds() const { return fFitCluster2Ds; } + Bool_t GetFitLineSegments() const { return fFitLineSegments; } Bool_t GetRnrFV() const { return fRnrFV; } UChar_t GetProjTrackBreaking() const { return fProjTrackBreaking; } Bool_t GetRnrPTBMarkers() const { return fRnrPTBMarkers; } @@ -317,7 +331,6 @@ class TEveTrackPropagator : public TEveElementList, TMarker& RefPMAtt() { return fPMAtt; } TMarker& RefFVAtt() { return fFVAtt; } TMarker& RefPTBAtt() { return fPTBAtt; } - static Bool_t IsOutsideBounds(const TEveVectorD& point, Double_t maxRsqr, Double_t maxZ); diff --git a/graf3d/eve/inc/TEveTrackPropagatorEditor.h b/graf3d/eve/inc/TEveTrackPropagatorEditor.h index 3472b726366b0..c29397d86e53b 100644 --- a/graf3d/eve/inc/TEveTrackPropagatorEditor.h +++ b/graf3d/eve/inc/TEveTrackPropagatorEditor.h @@ -55,6 +55,7 @@ class TEveTrackPropagatorSubEditor : public TGVerticalFrame TGButton *fFitReferences; TGButton *fFitDecay; TGButton *fFitCluster2Ds; + TGButton *fFitLineSegments; TGButton *fRnrDaughters; TGButton *fRnrReferences; TGButton *fRnrDecay; diff --git a/graf3d/eve/inc/TEveVSD.h b/graf3d/eve/inc/TEveVSD.h index eff26a91cc6c6..ddf941b8e5b90 100644 --- a/graf3d/eve/inc/TEveVSD.h +++ b/graf3d/eve/inc/TEveVSD.h @@ -64,7 +64,7 @@ class TEveVSD : public TObject static void DisableTObjectStreamersForVSDStruct(); - ClassDef(TEveVSD, 1); // Visualization Summary Data - a collection of trees holding standard event data in experiment independant format. + ClassDef(TEveVSD, 1); // Visualization Summary Data - a collection of trees holding standard event data in experiment independent format. }; #endif diff --git a/graf3d/eve/inc/TEveVSDStructs.h b/graf3d/eve/inc/TEveVSDStructs.h index 67004a3ec1fa1..f7ca152e6d7e3 100644 --- a/graf3d/eve/inc/TEveVSDStructs.h +++ b/graf3d/eve/inc/TEveVSDStructs.h @@ -136,15 +136,19 @@ class TEveRecTrackT : public TObject TEveVectorT<TT> fV; // Start vertex from reconstruction. TEveVectorT<TT> fP; // Reconstructed momentum at start vertex. TT fBeta; // Relativistic beta factor. - + Double32_t fDcaXY; // dca xy to the primary vertex + Double32_t fDcaZ; // dca z to the primary vertex + Double32_t fPVX; // + Double32_t fPVY; // + Double32_t fPVZ; // // PID data missing - TEveRecTrackT() : fLabel(-1), fIndex(-1), fStatus(0), fSign(0), fV(), fP(), fBeta(0) {} + TEveRecTrackT() : fLabel(-1), fIndex(-1), fStatus(0), fSign(0), fV(), fP(), fBeta(0), fDcaXY(0), fDcaZ(0), fPVX(0), fPVY(0), fPVZ(0) {} virtual ~TEveRecTrackT() {} Float_t Pt() { return fP.Perp(); } - ClassDef(TEveRecTrackT, 1); // Template for reconstructed track (also used in VSD). + ClassDef(TEveRecTrackT, 2); // Template for reconstructed track (also used in VSD). }; typedef TEveRecTrackT<Float_t> TEveRecTrack; diff --git a/graf3d/eve/inc/TEveWindow.h b/graf3d/eve/inc/TEveWindow.h index 8c57b9bcdf8a3..b3eb4b8b88cf5 100644 --- a/graf3d/eve/inc/TEveWindow.h +++ b/graf3d/eve/inc/TEveWindow.h @@ -15,6 +15,7 @@ #include "TEveElement.h" #include "TGFrame.h" +#include "TContextMenu.h" class TEveWindow; class TEveWindowSlot; @@ -22,8 +23,7 @@ class TEveWindowFrame; class TEveWindowMainFrame; class TEveWindowPack; class TEveWindowTab; - -class TContextMenu; +class TEveContextMenu; class TGButton; class TGSplitButton; @@ -67,10 +67,10 @@ class TEveCompositeFrame : public TGCompositeFrame Bool_t fShowInSync; - static TContextMenu *fgCtxMenu; - static const TString fgkEmptyFrameName; + static TEveContextMenu *fgCtxMenu; + static const TString fgkEmptyFrameName; - static TList *fgFrameList; + static TList *fgFrameList; public: TEveCompositeFrame(TGCompositeFrame* gui_parent, TEveWindow* eve_parent); @@ -415,4 +415,26 @@ class TEveWindowTab : public TEveWindow ClassDef(TEveWindowTab, 0); // Eve-window containing a TGTab. }; + +//============================================================================== +//============================================================================== +// Helper classes +//============================================================================== +//============================================================================== + + +//============================================================================== +// TEveContextMenu +//============================================================================== + +class TEveContextMenu : public TContextMenu +{ +public: + TEveContextMenu(const char *name, const char *title = "Eve context menu"); + + void SetupAndPopup(TGWindow* button, TObject* obj); + + ClassDef(TEveContextMenu, 0) // Specialization of TContextMenu for Eve. +}; + #endif diff --git a/graf3d/eve/src/TEveBrowser.cxx b/graf3d/eve/src/TEveBrowser.cxx index 5d9e52ec91680..6ba57a83110b7 100644 --- a/graf3d/eve/src/TEveBrowser.cxx +++ b/graf3d/eve/src/TEveBrowser.cxx @@ -531,7 +531,7 @@ namespace { enum EEveMenu_e { kNewMainFrameSlot, kNewTabSlot, - kNewViewer, kNewScene, kNewProjector, + kNewViewer, kNewScene, kNewBrowser, kNewCanvas, kNewCanvasExt, kNewTextEditor, kNewHtmlBrowser, kSel_PS_Ignore, kSel_PS_Element, kSel_PS_Projectable, kSel_PS_Compound, kSel_PS_PableCompound, kSel_PS_Master, kSel_PS_END, @@ -561,7 +561,6 @@ TEveBrowser::TEveBrowser(UInt_t w, UInt_t h) : fEvePopup->AddSeparator(); fEvePopup->AddEntry("New &Viewer", kNewViewer); fEvePopup->AddEntry("New &Scene", kNewScene); - fEvePopup->AddEntry("New &Projector", kNewProjector); fEvePopup->AddSeparator(); fEvePopup->AddEntry("New &Browser", kNewBrowser); fEvePopup->AddEntry("New &Canvas", kNewCanvas); @@ -617,6 +616,9 @@ TEveBrowser::TEveBrowser(UInt_t w, UInt_t h) : fPreMenuFrame->ChangeOptions(fPreMenuFrame->GetOptions() | kRaisedFrame); fTopMenuFrame->Layout(); fTopMenuFrame->MapSubwindows(); + + // Rename "Close Window" to "Close Eve" + fMenuFile->GetEntry(kCloseWindow)->GetLabel()->SetString("Close Eve"); } /******************************************************************************/ @@ -646,12 +648,6 @@ void TEveBrowser::EveMenu(Int_t id) gEve->SpawnNewScene("Scena Mica"); break; } - case kNewProjector: { - TEveElement* pr = (TEveElement*) (gROOT->GetClass("TEveProjectionManager")->New()); - pr->SetElementNameTitle("Projector", "User-created projector."); - gEve->AddToListTree(pr, kTRUE); - break; - } case kNewBrowser: { gROOT->ProcessLineFast("new TBrowser"); break; @@ -766,10 +762,12 @@ void TEveBrowser::InitPlugins(Option_t *opt) } //______________________________________________________________________________ -TGFileBrowser* TEveBrowser::MakeFileBrowser() +TGFileBrowser* TEveBrowser::MakeFileBrowser(Bool_t make_default) { - // Create a file-browser. Caller should provide - // Start/StopEmbedding() calls and populate the new browser. + // Create a file-browser. Caller should provide Start/StopEmbedding() calls + // and populate the new browser. + // If flag make_default is kTRUE, the default file-browser is set to the + // newly created browser. TBrowserImp imp; TBrowser *tb = new TBrowser("Pipi", "Strel", &imp); @@ -778,19 +776,87 @@ TGFileBrowser* TEveBrowser::MakeFileBrowser() fb->SetBrowser(tb); fb->SetNewBrowser(this); gROOT->GetListOfBrowsers()->Remove(tb); + // This guy is never used and stays in list-of-cleanups after destruction. + // So let's just delete it now. + delete tb->GetContextMenu(); + + if (make_default) + fFileBrowser = fb; + return fb; } +//______________________________________________________________________________ +TGFileBrowser* TEveBrowser::GetFileBrowser() const +{ + // Returns the default file-browser. + + return fFileBrowser; +} + +//______________________________________________________________________________ +void TEveBrowser::SetFileBrowser(TGFileBrowser* b) +{ + // Set the default file browser. + + fFileBrowser = b; +} + //______________________________________________________________________________ void TEveBrowser::ReallyDelete() { - // Really delete the browser and the this GUI. + // Override from TRootBrowser. We need to be more brutal as fBrowser is + // not set in Eve case. + + delete this; +} + +//______________________________________________________________________________ +void TEveBrowser::CloseTab(Int_t id) +{ + // Virtual from TRootBrowser. Need to intercept closing of Eve tabs. + + // Check if this is an Eve window and destroy accordingly. + TGCompositeFrame *pcf = fTabRight->GetTabContainer(id); + TGFrameElement *fe = (TGFrameElement *) pcf->GetList()->First(); + if (fe) + { + TEveCompositeFrame *ecf = dynamic_cast<TEveCompositeFrame*>(fe->fFrame); + if (ecf) + { + ecf->GetEveWindow()->DestroyWindowAndSlot(); + return; + } + } - delete this; // will in turn delete this object + // Fallback to standard tab destruction + TRootBrowser::CloseTab(id); } +//______________________________________________________________________________ +void TEveBrowser::CloseWindow() +{ + // Virtual from TGMainFrame. Calls TEveManager::Terminate(). + + TEveManager::Terminate(); +} + +//______________________________________________________________________________ void TEveBrowser::HideBottomTab() { + // Hide the bottom tab (usually holding command-line widget). + fV2->HideFrame(fHSplitter); fV2->HideFrame(fH2); } + +//______________________________________________________________________________ +void TEveBrowser::SanitizeTabCounts() +{ + // TRootBrowser keeps (somewhat unnecessarily) counters for number ob tabs + // on each position. Eve bastardizes the right tab so we have to fix the counters + // when a new window is added ... it doesn't seem to be needed when it is removed. + + fNbTab[TRootBrowser::kRight] = fTabRight->GetNumberOfTabs(); + fCrTab[TRootBrowser::kRight] = fTabRight->GetNumberOfTabs() - 1; +} diff --git a/graf3d/eve/src/TEveCalo.cxx b/graf3d/eve/src/TEveCalo.cxx index 10e0f317d22a9..2a6de46646b33 100644 --- a/graf3d/eve/src/TEveCalo.cxx +++ b/graf3d/eve/src/TEveCalo.cxx @@ -55,7 +55,8 @@ TEveCaloViz::TEveCaloViz(TEveCaloData* data, const char* n, const char* t) : fAutoRange(kTRUE), fBarrelRadius(-1.f), - fEndCapPos(-1.f), + fEndCapPosF(-1.f), + fEndCapPosB(-1.f), fPlotEt(kTRUE), @@ -181,21 +182,59 @@ void TEveCaloViz::SetPhiWithRng(Float_t phi, Float_t rng) //______________________________________________________________________________ Float_t TEveCaloViz::GetTransitionTheta() const { - // Get transition angle between barrel and end-cap cells. + // Get transition angle between barrel and end-cap cells, assuming fEndCapPosF = -fEndCapPosB. - return TMath::ATan(fBarrelRadius/fEndCapPos); + return TMath::ATan(fBarrelRadius/fEndCapPosF); } //______________________________________________________________________________ Float_t TEveCaloViz::GetTransitionEta() const { - // Get transition eta between barrel and end-cap cells. + // Get transition eta between barrel and end-cap cells, assuming fEndCapPosF = -fEndCapPosB. using namespace TMath; Float_t t = GetTransitionTheta()*0.5f; return -Log(Tan(t)); } +//______________________________________________________________________________ +Float_t TEveCaloViz::GetTransitionThetaForward() const +{ + // Get transition angle between barrel and forward end-cap cells. + + return TMath::ATan(fBarrelRadius/fEndCapPosF); +} + +//______________________________________________________________________________ +Float_t TEveCaloViz::GetTransitionEtaForward() const +{ + // Get transition eta between barrel and forward end-cap cells. + + using namespace TMath; + Float_t t = GetTransitionThetaForward()*0.5f; + return -Log(Tan(t)); +} + +//______________________________________________________________________________ +Float_t TEveCaloViz::GetTransitionThetaBackward() const +{ + // Get transition angle between barrel and backward end-cap cells. + + return TMath::ATan(fBarrelRadius/fEndCapPosB); +} + +//______________________________________________________________________________ +Float_t TEveCaloViz::GetTransitionEtaBackward() const +{ + // Get transition eta between barrel and backward end-cap cells. + + using namespace TMath; + Float_t t = GetTransitionThetaBackward()*0.5f; + //negative theta means negative eta + return Log(-Tan(t)); +} + + //______________________________________________________________________________ void TEveCaloViz::SetData(TEveCaloData* data) { @@ -292,7 +331,8 @@ void TEveCaloViz::AssignCaloVizParameters(TEveCaloViz* m) fPhiOffset = m->fPhiOffset; fBarrelRadius = m->fBarrelRadius; - fEndCapPos = m->fEndCapPos; + fEndCapPosF = m->fEndCapPosF; + fEndCapPosB = m->fEndCapPosB; if (m->fPalette) { @@ -445,8 +485,8 @@ void TEveCalo3D::ComputeBBox() fBBox[1] = fBarrelRadius + th; fBBox[2] = fBBox[0]; fBBox[3] = fBBox[1]; - fBBox[4] = -fEndCapPos - th; - fBBox[5] = fEndCapPos + th; + fBBox[4] = fEndCapPosB - th; + fBBox[5] = fEndCapPosF + th; } @@ -714,7 +754,6 @@ void TEveCalo2D::ComputeBBox() Float_t x, y, z; Float_t th = fMaxTowerH ; Float_t r = fBarrelRadius + th; - Float_t ze = fEndCapPos + th; x = r, y = 0, z = 0; fManager->GetProjection()->ProjectPoint(x, y, z, fDepth); @@ -723,10 +762,10 @@ void TEveCalo2D::ComputeBBox() fManager->GetProjection()->ProjectPoint(x, y, z, fDepth); BBoxCheckPoint(x, y, z); - x = 0, y = 0, z = ze; + x = 0, y = 0, z = fEndCapPosF + th; fManager->GetProjection()->ProjectPoint(x, y, z, fDepth); BBoxCheckPoint(x, y, z); - x = 0, y = 0, z = -ze; + x = 0, y = 0, z = fEndCapPosB - th; fManager->GetProjection()->ProjectPoint(x, y, z, fDepth); BBoxCheckPoint(x, y, z); diff --git a/graf3d/eve/src/TEveCalo2DGL.cxx b/graf3d/eve/src/TEveCalo2DGL.cxx index 708c80ef7ef10..9dddd574f9787 100644 --- a/graf3d/eve/src/TEveCalo2DGL.cxx +++ b/graf3d/eve/src/TEveCalo2DGL.cxx @@ -234,7 +234,12 @@ void TEveCalo2DGL::MakeRhoZCell(Float_t thetaMin, Float_t thetaMax, else { // endcap - Float_t r1 = fM->GetEndCapPos()/Abs(Cos(0.5f*(thetaMin+thetaMax))) + offset; + Float_t zE = fM->GetForwardEndCapPos(); + // uses a different theta definition than GetTransitionThetaBackward(), so we need a conversion + Float_t transThetaB = TEveCaloData::EtaToTheta(fM->GetTransitionEtaBackward()); + if (thetaMax >= transThetaB) + zE = Abs(fM->GetBackwardEndCapPos()); + Float_t r1 = zE/Abs(Cos(0.5f*(thetaMin+thetaMax))) + offset; Float_t r2 = r1 + towerH; pnts[0] = r1*sin1; pnts[1] = r1*cos1; @@ -269,7 +274,8 @@ void TEveCalo2DGL::DrawRhoZ(TGLRnrCtx & rnrCtx, TEveCalo2D::vBinCells_t& cellLis Float_t *sliceValsLow = new Float_t[nSlices]; Bool_t isBarrel; Float_t towerH; - Float_t transEta = fM->GetTransitionEta(); + Float_t transEtaF = fM->GetTransitionEtaForward(); + Float_t transEtaB = fM->GetTransitionEtaBackward(); TAxis* axis = data->GetEtaBins(); UInt_t nEta = axis->GetNbins(); @@ -301,12 +307,7 @@ void TEveCalo2DGL::DrawRhoZ(TGLRnrCtx & rnrCtx, TEveCalo2D::vBinCells_t& cellLis sliceValsLow[it->fSlice] += cellData.Value(fM->fPlotEt)*(*it).fFraction; } - isBarrel = true; - if ((etaMax > 0 && etaMax > transEta) || - (etaMin < 0 && etaMin < -transEta)) - { - isBarrel = false; - } + isBarrel = !(etaMax > 0 && etaMax > transEtaF) && !(etaMin < 0 && etaMin < transEtaB); // draw if (rnrCtx.SecSelection()) glLoadName(etaBin); // name-stack eta bin @@ -354,6 +355,8 @@ void TEveCalo2DGL::DrawRhoZHighlighted(std::vector<TEveCaloData::vCellId_t*>& ce TAxis* axis = data->GetEtaBins(); UInt_t nEtaBins = axis->GetNbins(); Int_t nSlices = data->GetNSlices(); + Float_t transEtaF = fM->GetTransitionEtaForward(); + Float_t transEtaB = fM->GetTransitionEtaBackward(); Float_t *sliceValsUp = new Float_t[nSlices]; Float_t *sliceValsLow = new Float_t[nSlices]; @@ -400,7 +403,9 @@ void TEveCalo2DGL::DrawRhoZHighlighted(std::vector<TEveCaloData::vCellId_t*>& ce sliceValsLowRef[i->fSlice] += cellData.Value(fM->fPlotEt)*(*i).fFraction; } - isBarrel = TMath::Abs(axis->GetBinCenter(etaBin)) < fM->GetTransitionEta(); + Float_t bincenterEta = axis->GetBinCenter(etaBin); + isBarrel = !(bincenterEta > 0 && bincenterEta > transEtaF) && !(bincenterEta < 0 && bincenterEta < transEtaB); + for (Int_t s = 0; s < nSlices; ++s) { Float_t thetaMin = TEveCaloData::EtaToTheta(axis->GetBinUpEdge(etaBin)); diff --git a/graf3d/eve/src/TEveCalo3DGL.cxx b/graf3d/eve/src/TEveCalo3DGL.cxx index 3af31b85dda5f..f0d8fa90d4125 100644 --- a/graf3d/eve/src/TEveCalo3DGL.cxx +++ b/graf3d/eve/src/TEveCalo3DGL.cxx @@ -89,11 +89,13 @@ void TEveCalo3DGL::RenderGridEndCap() const using namespace TMath; Float_t rB = fM->GetBarrelRadius(); - Double_t zE = fM->GetEndCapPos(); + Double_t zEF = fM->GetForwardEndCapPos(); + Double_t zEB = fM->GetBackwardEndCapPos(); Float_t etaMin = fM->GetEtaMin(); Float_t etaMax = fM->GetEtaMax(); - Float_t trans = fM->GetTransitionEta(); + Float_t transF = fM->GetTransitionEtaForward(); + Float_t transB = fM->GetTransitionEtaBackward(); Float_t phiMin = fM->GetPhiMin(); Float_t phiMax = fM->GetPhiMax(); @@ -109,11 +111,25 @@ void TEveCalo3DGL::RenderGridEndCap() const for (Int_t i=0; i<=nx; ++i) { eta = ax->GetBinUpEdge(i); - if (Abs(eta) >= trans && (eta > etaMin && eta < etaMax)) + if (eta >= transF && (eta > etaMin && eta < etaMax)) { theta = TEveCaloData::EtaToTheta(eta); - r = Abs(zE*Tan(theta)); - z = Sign(zE, ax->GetBinLowEdge(i)); + r = Abs(zEF*Tan(theta)); + z = Sign(zEF, ax->GetBinLowEdge(i)); + for (Int_t j=1; j<=ny; ++j) + { + phiL = ay->GetBinLowEdge(j); + phiU = ay->GetBinUpEdge(j); + if (TEveUtil::IsU1IntervalContainedByMinMax(phiMin, phiMax, phiL, phiU)) + { + glVertex3f(r*Cos(phiL), r*Sin(phiL), z); + glVertex3f(r*Cos(phiU), r*Sin(phiU), z); + } + } + } else if (eta <= transB && (eta > etaMin && eta < etaMax)) { + theta = TEveCaloData::EtaToTheta(eta); + r = Abs(zEB*Tan(theta)); + z = Sign(zEB, ax->GetBinLowEdge(i)); for (Int_t j=1; j<=ny; ++j) { phiL = ay->GetBinLowEdge(j); @@ -129,13 +145,13 @@ void TEveCalo3DGL::RenderGridEndCap() const Float_t r1, r2; // phi slices front - if (etaMax > trans) + if (etaMax > transF) { - r1 = zE*Tan(TEveCaloData::EtaToTheta(etaMax)); - if (etaMin < trans) + r1 = zEF*Tan(TEveCaloData::EtaToTheta(etaMax)); + if (etaMin < transF) r2 = rB; else - r2 = zE*Tan(TEveCaloData::EtaToTheta(etaMin)); + r2 = zEF*Tan(TEveCaloData::EtaToTheta(etaMin)); for (Int_t j=1; j<=ny; ++j) { @@ -143,22 +159,22 @@ void TEveCalo3DGL::RenderGridEndCap() const phiU = ay->GetBinUpEdge(j); if (TEveUtil::IsU1IntervalContainedByMinMax(phiMin, phiMax, phiL, phiU)) { - glVertex3f( r1*Cos(phiU), r1*Sin(phiU), zE); - glVertex3f( r2*Cos(phiU), r2*Sin(phiU), zE); - glVertex3f( r1*Cos(phiL), r1*Sin(phiL), zE); - glVertex3f( r2*Cos(phiL), r2*Sin(phiL), zE); + glVertex3f( r1*Cos(phiU), r1*Sin(phiU), zEF); + glVertex3f( r2*Cos(phiU), r2*Sin(phiU), zEF); + glVertex3f( r1*Cos(phiL), r1*Sin(phiL), zEF); + glVertex3f( r2*Cos(phiL), r2*Sin(phiL), zEF); } } } // phi slices back - if (etaMin < -trans) + if (etaMin < transB) { - r1 = zE*Tan(TEveCaloData::EtaToTheta(etaMin)); - if (etaMax > -trans) + r1 = zEB*Tan(TEveCaloData::EtaToTheta(etaMin)); + if (etaMax > transB) r2 = rB; else - r2 = zE*Tan(TEveCaloData::EtaToTheta(etaMax)); + r2 = zEB*Tan(TEveCaloData::EtaToTheta(etaMax)); r1 = Abs(r1); r2 = Abs(r2); @@ -168,10 +184,10 @@ void TEveCalo3DGL::RenderGridEndCap() const phiU = ay->GetBinUpEdge(j); if (TEveUtil::IsU1IntervalContainedByMinMax(phiMin, phiMax, phiL, phiU)) { - glVertex3f(r1*Cos(phiU), r1*Sin(phiU), -zE); - glVertex3f(r2*Cos(phiU), r2*Sin(phiU), -zE); - glVertex3f(r1*Cos(phiL), r1*Sin(phiL), -zE); - glVertex3f(r2*Cos(phiL), r2*Sin(phiL), -zE); + glVertex3f(r1*Cos(phiU), r1*Sin(phiU), zEB); + glVertex3f(r2*Cos(phiU), r2*Sin(phiU), zEB); + glVertex3f(r1*Cos(phiL), r1*Sin(phiL), zEB); + glVertex3f(r2*Cos(phiL), r2*Sin(phiL), zEB); } } } @@ -186,7 +202,8 @@ void TEveCalo3DGL::RenderGridBarrel() const Float_t etaMin = fM->GetEtaMin(); Float_t etaMax = fM->GetEtaMax(); - Float_t trans = fM->GetTransitionEta(); + Float_t transF = fM->GetTransitionEtaForward(); + Float_t transB = fM->GetTransitionEtaBackward(); Float_t phiMin = fM->GetPhiMin(); Float_t phiMax = fM->GetPhiMax(); @@ -202,7 +219,7 @@ void TEveCalo3DGL::RenderGridBarrel() const for(Int_t i=0; i<=nx; i++) { eta = ax->GetBinUpEdge(i); - if ((Abs(eta)<=trans) && (etaMin < eta && eta < etaMax)) + if (eta<=transF && eta>=transB && (etaMin < eta && eta < etaMax)) { theta = TEveCaloData::EtaToTheta(eta); z = rB/Tan(theta); @@ -222,16 +239,16 @@ void TEveCalo3DGL::RenderGridBarrel() const // phi slices Float_t zF, zB; - if (etaMin > -trans) + if (etaMin > transB) zB = rB/Tan(TEveCaloData::EtaToTheta(etaMin)); else - zB = -fM->GetEndCapPos(); + zB = fM->GetBackwardEndCapPos(); - if (etaMax < trans) + if (etaMax < transF) zF = rB/Tan(TEveCaloData::EtaToTheta(etaMax)); else - zF = fM->GetEndCapPos(); + zF = fM->GetForwardEndCapPos(); for (Int_t j=1; j<=ny; j++) { @@ -279,13 +296,14 @@ void TEveCalo3DGL::RenderGrid(TGLRnrCtx & rnrCtx) const Float_t etaMin = fM->GetEtaMin(); Float_t etaMax = fM->GetEtaMax(); - Float_t trans = fM->GetTransitionEta(); - if (fM->GetRnrBarrelFrame() && (etaMin < trans && etaMax > -trans)) + Float_t transF = fM->GetTransitionEtaForward(); + Float_t transB = fM->GetTransitionEtaBackward(); + if (fM->GetRnrBarrelFrame() && (etaMin < transF && etaMax > transB)) { RenderGridBarrel(); } - if (fM->GetRnrEndCapFrame() && (etaMax > trans || etaMin < -trans)) + if (fM->GetRnrEndCapFrame() && (etaMax > transF || etaMin < transB)) { RenderGridEndCap(); } @@ -452,7 +470,7 @@ void TEveCalo3DGL::RenderEndCapCell(const TEveCaloData::CellGeom_t &cellData, Fl using namespace TMath; Float_t z1, r1In, r1Out, z2, r2In, r2Out; - z1 = TMath::Sign(fM->fEndCapPos + offset, cellData.EtaMin()); + z1 = (cellData.EtaMin()<0) ? fM->fEndCapPosB : fM->fEndCapPosF; z2 = z1 + TMath::Sign(towerH, cellData.EtaMin()); r1In = z1*Tan(cellData.ThetaMin()); @@ -559,8 +577,8 @@ void TEveCalo3DGL::DirectDraw(TGLRnrCtx &rnrCtx) const if (rnrCtx.SecSelection()) glLoadName(cellID); - if ((cellData.Eta() > 0 && cellData.Eta() < fM->GetTransitionEta()) || - (cellData.Eta() < 0 && cellData.Eta() > -fM->GetTransitionEta())) + if ((cellData.Eta() > 0 && cellData.Eta() < fM->GetTransitionEtaForward()) || + (cellData.Eta() < 0 && cellData.Eta() > fM->GetTransitionEtaBackward())) { RenderBarrelCell(cellData, towerH, offset); } @@ -596,7 +614,7 @@ void TEveCalo3DGL::DrawHighlight(TGLRnrCtx & rnrCtx, const TGLPhysicalShape* /*p TGLUtil::LineWidth(2); TGLUtil::LockColor(); - if (!fM->fData->GetCellsHighlighted().empty()) + if (!fM->fData->GetCellsHighlighted().empty()) { glColor4ubv(rnrCtx.ColorSet().Selection(3).CArr()); DrawSelectedCells(fM->fData->GetCellsHighlighted()); @@ -637,13 +655,13 @@ void TEveCalo3DGL::DrawSelectedCells(TEveCaloData::vCellId_t cells) const } } - if (fM->CellInEtaPhiRng(cellData)) + if (fM->CellInEtaPhiRng(cellData)) { - if (TMath::Abs(cellData.Eta()) < fM->GetTransitionEta()) + if (cellData.Eta() < fM->GetTransitionEtaForward() && cellData.Eta() > fM->GetTransitionEtaBackward()) RenderBarrelCell(cellData, towerH, offset); else RenderEndCapCell(cellData, towerH, offset); - } + } } } diff --git a/graf3d/eve/src/TEveCaloLegoGL.cxx b/graf3d/eve/src/TEveCaloLegoGL.cxx index db368e28e0b09..bcb1880b3e830 100644 --- a/graf3d/eve/src/TEveCaloLegoGL.cxx +++ b/graf3d/eve/src/TEveCaloLegoGL.cxx @@ -703,11 +703,12 @@ Int_t TEveCaloLegoGL::GetGridStep(TGLRnrCtx &rnrCtx) const Int_t ngroup = 1; if (fM->fAutoRebin && fM->fPixelsPerBin > ppb) { - ngroup = TMath::Nint(fM->fPixelsPerBin*0.5/ppb); // symetrical rebin factor 2 // limit rebin realtive to number of axis bins - Int_t minN = TMath::Min(fM->fData->GetEtaBins()->GetNbins(), fM->fData->GetPhiBins()->GetNbins()); - if (ngroup * 4 > minN) - ngroup = minN/4; + Int_t maxGroup = TMath::Min(fM->fData->GetEtaBins()->GetNbins(), fM->fData->GetPhiBins()->GetNbins())/4; + if (maxGroup > 1) { + ngroup = TMath::Nint(fM->fPixelsPerBin*0.5/ppb); // symetrical rebin factor 2 + if (ngroup > maxGroup) ngroup = maxGroup; + } } fCurrentPixelsPerBin = TMath::Nint(ppb); diff --git a/graf3d/eve/src/TEveGeoNode.cxx b/graf3d/eve/src/TEveGeoNode.cxx index c708cc77bd700..5262223f83de9 100644 --- a/graf3d/eve/src/TEveGeoNode.cxx +++ b/graf3d/eve/src/TEveGeoNode.cxx @@ -362,19 +362,14 @@ TEveGeoShapeExtract* TEveGeoNode::DumpShapeTree(TEveGeoNode* geon, TEveGeoManagerHolder gmgr(tvolume->GetGeoManager(), fgCSGExportNSeg); gGeoManager->SetPaintVolume(tvolume); - Bool_t had_null_transform = kFALSE; - if (tshape->GetTransform() == 0) { - had_null_transform = kTRUE; - tshape->SetTransform(gGeoIdentity); - } + TGeoMatrix *gst = TGeoShape::GetTransform(); + TGeoShape::SetTransform(TEveGeoShape::GetGeoHMatrixIdentity()); scene_pad.BeginScene(); dynamic_cast<TGeoCompositeShape*>(tshape)->PaintComposite(); scene_pad.EndScene(); - if (had_null_transform) { - tshape->SetTransform(0); - } + TGeoShape::SetTransform(gst); } pad.SetViewer3D(0); diff --git a/graf3d/eve/src/TEveGeoPolyShape.cxx b/graf3d/eve/src/TEveGeoPolyShape.cxx index a9ba2b97f3bc5..1f3d0337f9fb9 100644 --- a/graf3d/eve/src/TEveGeoPolyShape.cxx +++ b/graf3d/eve/src/TEveGeoPolyShape.cxx @@ -72,9 +72,8 @@ TEveGeoPolyShape* TEveGeoPolyShape::Construct(TGeoCompositeShape *cshape, Int_t TBuffer3D::IncCSLevel(); // Paint the boolean node - will add more buffers to viewer - TGeoHMatrix xxx; TGeoMatrix *gst = TGeoShape::GetTransform(); - TGeoShape::SetTransform(&xxx); + TGeoShape::SetTransform(TEveGeoShape::GetGeoHMatrixIdentity()); if (paintComponents) cshape->GetBoolNode()->Paint(""); TGeoShape::SetTransform(gst); // Close the composite shape diff --git a/graf3d/eve/src/TEveGeoShape.cxx b/graf3d/eve/src/TEveGeoShape.cxx index f9a01515a503a..a1250eca77433 100644 --- a/graf3d/eve/src/TEveGeoShape.cxx +++ b/graf3d/eve/src/TEveGeoShape.cxx @@ -55,6 +55,8 @@ namespace gGeoIdentity = old_id; return mgr; } + + TGeoHMatrix localGeoHMatrixIdentity; } //============================================================================== @@ -92,6 +94,17 @@ TGeoManager* TEveGeoShape::GetGeoMangeur() return fgGeoMangeur; } +//______________________________________________________________________________ +TGeoHMatrix* TEveGeoShape::GetGeoHMatrixIdentity() +{ + // Return static identity matrix in homogeneous representation. + // This is needed because TGeoCompositeShape::PaintComposite() + // assumes TGeoShape::fgTransform is a TGeoHMatrix and we need to pass in + // an identity matrix when painting a composite shape. + + return &localGeoHMatrixIdentity; +} + //______________________________________________________________________________ TEveGeoShape::TEveGeoShape(const char* name, const char* title) : TEveShape (name, title), @@ -227,9 +240,8 @@ void TEveGeoShape::Paint(Option_t* /*option*/) TBuffer3D::IncCSLevel(); // Paint the boolean node - will add more buffers to viewer - TGeoHMatrix xxx; TGeoMatrix *gst = TGeoShape::GetTransform(); - TGeoShape::SetTransform(&xxx); + TGeoShape::SetTransform(TEveGeoShape::GetGeoHMatrixIdentity()); if (paintComponents) fCompositeShape->GetBoolNode()->Paint(""); TGeoShape::SetTransform(gst); // Close the composite shape diff --git a/graf3d/eve/src/TEveGeoShapeExtract.cxx b/graf3d/eve/src/TEveGeoShapeExtract.cxx index c12fb822d3658..c550d52170be9 100644 --- a/graf3d/eve/src/TEveGeoShapeExtract.cxx +++ b/graf3d/eve/src/TEveGeoShapeExtract.cxx @@ -47,7 +47,6 @@ TEveGeoShapeExtract::TEveGeoShapeExtract(const char* n, const char* t) : fTrans[0] = fTrans[5] = fTrans[10] = fTrans[15] = 1; fRGBA [0] = fRGBA [1] = fRGBA [2] = fRGBA [3] = 1; fRGBALine[0] = fRGBALine[1] = fRGBALine[2] = 0; fRGBALine[3] = 1; - gGeoManager = TEveGeoShape::GetGeoMangeur(); // To inforce phony geo-manager on load time. } //______________________________________________________________________________ diff --git a/graf3d/eve/src/TEveLine.cxx b/graf3d/eve/src/TEveLine.cxx index 86d647a74b9f2..51c8aed9b86ef 100644 --- a/graf3d/eve/src/TEveLine.cxx +++ b/graf3d/eve/src/TEveLine.cxx @@ -12,6 +12,11 @@ #include "TEveLine.h" #include "TEveProjectionManager.h" +namespace +{ + inline Float_t sqr(Float_t x) { return x*x; } +} + //============================================================================== //============================================================================== // TEveLine @@ -217,6 +222,22 @@ void TEveLine::ReduceSegmentLengths(Float_t max) SetNextPoint(i->fX, i->fY, i->fZ); } +//______________________________________________________________________________ +Float_t TEveLine::CalculateLineLength() const +{ + // Sum-up lengths of individual segments. + + Float_t sum = 0; + + Int_t s = Size(); + Float_t *p = GetP(); + for (Int_t i = 1; i < s; ++i, p += 3) + { + sum += TMath::Sqrt(sqr(p[3] - p[0]) + sqr(p[4] - p[1]) + sqr(p[5] - p[2])); + } + return sum; +} + //______________________________________________________________________________ TEveVector TEveLine::GetLineStart() const { diff --git a/graf3d/eve/src/TEveManager.cxx b/graf3d/eve/src/TEveManager.cxx index 0b435eac5d0c5..095bc4329f832 100644 --- a/graf3d/eve/src/TEveManager.cxx +++ b/graf3d/eve/src/TEveManager.cxx @@ -133,7 +133,6 @@ TEveManager::TEveManager(UInt_t w, UInt_t h, Bool_t map_window, Option_t* opt) : // Build GUI fBrowser = new TEveBrowser(w, h); - fBrowser->Connect("CloseWindow()", "TEveManager", this, "CloseEveWindow()"); // ListTreeEditor fBrowser->StartEmbedding(0); @@ -223,6 +222,7 @@ TEveManager::~TEveManager() fHighlight->DecDenyDestroy(); fSelection->DecDenyDestroy(); + gROOT->GetListOfBrowsables()->Remove(fMacroFolder); delete fMacroFolder; delete fGeometryAliases; @@ -233,9 +233,8 @@ TEveManager::~TEveManager() fLTEFrame->DeleteWindow(); - fBrowser->Disconnect("CloseWindow()", this, "CloseEveWindow()"); - fBrowser->GetMainFrame()->DontCallClose(); - fBrowser->GetMainFrame()->CloseWindow(); + fBrowser->DontCallClose(); + fBrowser->TRootBrowser::CloseWindow(); } //______________________________________________________________________________ @@ -322,6 +321,7 @@ TEveViewer* TEveManager::SpawnNewViewer(const char* name, const char* title, // in TEveWindowManager. // Also to store closed windows. slot = TEveWindow::CreateWindowInTab(fBrowser->GetTabRight()); + fBrowser->SanitizeTabCounts(); } } else @@ -917,7 +917,7 @@ void TEveManager::ClearROOTClassSaved() //______________________________________________________________________________ void TEveManager::CloseEveWindow() { - // Close button haas been clicked on EVE main window (browser). + // Close button has been clicked on EVE main window (browser). // Cleanup and terminate application. TGMainFrame *mf = (TGMainFrame*) gTQSender; diff --git a/graf3d/eve/src/TEvePathMark.cxx b/graf3d/eve/src/TEvePathMark.cxx index addaedbd152ba..88db0b3bcc725 100644 --- a/graf3d/eve/src/TEvePathMark.cxx +++ b/graf3d/eve/src/TEvePathMark.cxx @@ -26,6 +26,11 @@ // fP - normal to detector plane, // fE - large error direction, must be normalized. // Track is propagated to plane and correction in fE direction is discarded. +// kLineSegment - line segment with vertex fV and vector fE +// fV - first point of line segment +// fP - normal to detector plane, +// fE - vector from fV to the second vertex of line segment + ClassImp(TEvePathMarkT<Float_t>); ClassImp(TEvePathMarkT<Double_t>); @@ -37,11 +42,12 @@ template<typename TT> const char* TEvePathMarkT<TT>::TypeName() switch (fType) { - case kDaughter: return "Daughter"; - case kReference: return "Reference"; - case kDecay: return "Decay"; - case kCluster2D: return "Cluster2D"; - default: return "Unknown"; + case kDaughter: return "Daughter"; + case kReference: return "Reference"; + case kDecay: return "Decay"; + case kCluster2D: return "Cluster2D"; + case kLineSegment: return "LineSegment"; + default: return "Unknown"; } } diff --git a/graf3d/eve/src/TEvePointSet.cxx b/graf3d/eve/src/TEvePointSet.cxx index e9c2c9ae97176..5dd2e4834bfab 100644 --- a/graf3d/eve/src/TEvePointSet.cxx +++ b/graf3d/eve/src/TEvePointSet.cxx @@ -227,7 +227,7 @@ Int_t TEvePointSet::GetPointIntId(Int_t p, Int_t i) const //______________________________________________________________________________ void TEvePointSet::SetPointIntIds(Int_t* ids) { - // Set integer ids for the last point that was registerd (most + // Set integer ids for the last point that was registered (most // probably via TPolyMarker3D::SetNextPoint(x,y,z)). SetPointIntIds(fLastPoint, ids); diff --git a/graf3d/eve/src/TEveRGBAPalette.cxx b/graf3d/eve/src/TEveRGBAPalette.cxx index 4bcda42cb3877..e6e9b786b09af 100644 --- a/graf3d/eve/src/TEveRGBAPalette.cxx +++ b/graf3d/eve/src/TEveRGBAPalette.cxx @@ -118,7 +118,7 @@ void TEveRGBAPalette::SetupColor(Int_t val, UChar_t* pixel) const if (fInterpolate) { Int_t bin = (Int_t) f; - Float_t f1 = f - bin, f2 = 1.0f - f1; + Float_t f2 = f - bin, f1 = 1.0f - f2; TEveUtil::ColorFromIdx(f1, gStyle->GetColorPalette(bin), f2, gStyle->GetColorPalette(Min(bin + 1, nCol - 1)), pixel); diff --git a/graf3d/eve/src/TEveStraightLineSet.cxx b/graf3d/eve/src/TEveStraightLineSet.cxx index 672db5b6ebbf6..63a48649adee9 100644 --- a/graf3d/eve/src/TEveStraightLineSet.cxx +++ b/graf3d/eve/src/TEveStraightLineSet.cxx @@ -183,7 +183,7 @@ void TEveStraightLineSet::ComputeBBox() // Compute bounding-box. // Virtual from TAttBBox. - if(fLinePlex.Size() == 0) { + if (fLinePlex.Size() == 0 && fMarkerPlex.Size() == 0) { BBoxZero(); return; } diff --git a/graf3d/eve/src/TEveTrack.cxx b/graf3d/eve/src/TEveTrack.cxx index 1a744cdb46ec2..8cda9d459d099 100644 --- a/graf3d/eve/src/TEveTrack.cxx +++ b/graf3d/eve/src/TEveTrack.cxx @@ -39,6 +39,9 @@ // // Visual representation of a track. // +// If member fDpDs is set, the momentum is reduced on all path-marks that do +// not fix the momentum according to the distance travelled from the previous +// pathmark. ClassImp(TEveTrack); @@ -50,6 +53,7 @@ TEveTrack::TEveTrack() : fP(), fPEnd(), fBeta(0), + fDpDs(0), fPdg(0), fCharge(0), fLabel(kMinInt), @@ -71,6 +75,7 @@ TEveTrack::TEveTrack(TParticle* t, Int_t label, TEveTrackPropagator* prop): fP(t->Px(), t->Py(), t->Pz()), fPEnd(), fBeta(t->P()/t->Energy()), + fDpDs(0), fPdg(0), fCharge(0), fLabel(label), @@ -103,6 +108,7 @@ TEveTrack::TEveTrack(TEveMCTrack* t, TEveTrackPropagator* prop): fP(t->Px(), t->Py(), t->Pz()), fPEnd(), fBeta(t->P()/t->Energy()), + fDpDs(0), fPdg(0), fCharge(0), fLabel(t->fLabel), @@ -119,10 +125,9 @@ TEveTrack::TEveTrack(TEveMCTrack* t, TEveTrackPropagator* prop): fMainColorPtr = &fLineColor; TParticlePDG* pdgp = t->GetPDG(); - if (pdgp == 0) { - t->ResetPdgCode(); pdgp = t->GetPDG(); + if (pdgp) { + fCharge = (Int_t) TMath::Nint(pdgp->Charge()/3); } - fCharge = (Int_t) TMath::Nint(pdgp->Charge()/3); SetName(t->GetName()); } @@ -135,6 +140,7 @@ TEveTrack::TEveTrack(TEveRecTrackD* t, TEveTrackPropagator* prop) : fP(t->fP), fPEnd(), fBeta(t->fBeta), + fDpDs(0), fPdg(0), fCharge(t->fSign), fLabel(t->fLabel), @@ -161,6 +167,7 @@ TEveTrack::TEveTrack(TEveRecTrack* t, TEveTrackPropagator* prop) : fP(t->fP), fPEnd(), fBeta(t->fBeta), + fDpDs(0), fPdg(0), fCharge(t->fSign), fLabel(t->fLabel), @@ -188,6 +195,7 @@ TEveTrack::TEveTrack(const TEveTrack& t) : fP(t.fP), fPEnd(), fBeta(t.fBeta), + fDpDs(t.fDpDs), fPdg(t.fPdg), fCharge(t.fCharge), fLabel(t.fLabel), @@ -353,15 +361,17 @@ void TEveTrack::MakeTrack(Bool_t recurse) { TEveVectorD currP = fP; Bool_t decay = kFALSE; - fPropagator->InitTrack(fV, fCharge); + rTP.InitTrack(fV, fCharge); for (vPathMark_i pm = fPathMarks.begin(); pm != fPathMarks.end(); ++pm, ++fLastPMIdx) { + Int_t start_point = rTP.GetCurrentPoint(); + if (rTP.GetFitReferences() && pm->fType == TEvePathMarkD::kReference) { if (TEveTrackPropagator::IsOutsideBounds(pm->fV, maxRsq, maxZ)) break; - // printf("%s fit reference \n", fName.Data()); - if (fPropagator->GoToVertex(pm->fV, currP)) { + if (rTP.GoToVertex(pm->fV, currP)) + { currP.fX = pm->fP.fX; currP.fY = pm->fP.fY; currP.fZ = pm->fP.fZ; } else @@ -373,9 +383,15 @@ void TEveTrack::MakeTrack(Bool_t recurse) { if (TEveTrackPropagator::IsOutsideBounds(pm->fV, maxRsq, maxZ)) break; - // printf("%s fit daughter \n", fName.Data()); - if (fPropagator->GoToVertex(pm->fV, currP)) { + if (rTP.GoToVertex(pm->fV, currP)) + { currP.fX -= pm->fP.fX; currP.fY -= pm->fP.fY; currP.fZ -= pm->fP.fZ; + if (fDpDs != 0) + { + Double_t dp = fDpDs * rTP.GetTrackLength(start_point); + Double_t p = currP.Mag(); + if (p > dp) currP *= 1.0 - dp / p; + } } else { @@ -386,8 +402,7 @@ void TEveTrack::MakeTrack(Bool_t recurse) { if (TEveTrackPropagator::IsOutsideBounds(pm->fV, maxRsq, maxZ)) break; - // printf("%s fit decay \n", fName.Data()); - fPropagator->GoToVertex(pm->fV, currP); + rTP.GoToVertex(pm->fV, currP); decay = kTRUE; ++fLastPMIdx; break; @@ -395,36 +410,62 @@ void TEveTrack::MakeTrack(Bool_t recurse) else if (rTP.GetFitCluster2Ds() && pm->fType == TEvePathMarkD::kCluster2D) { TEveVectorD itsect; - if (fPropagator->IntersectPlane(currP, pm->fV, pm->fP, itsect)) + if (rTP.IntersectPlane(currP, pm->fV, pm->fP, itsect)) { TEveVectorD delta = itsect - pm->fV; TEveVectorD vtopass = pm->fV + pm->fE*(pm->fE.Dot(delta)); if (TEveTrackPropagator::IsOutsideBounds(vtopass, maxRsq, maxZ)) break; - if ( ! fPropagator->GoToVertex(vtopass, currP)) + if ( ! rTP.GoToVertex(vtopass, currP)) break; + + if (fDpDs != 0) + { + Double_t dp = fDpDs * rTP.GetTrackLength(start_point); + Double_t p = currP.Mag(); + if (p > dp) currP *= 1.0 - dp / p; + } } else { Warning("TEveTrack::MakeTrack", "Failed to intersect plane for Cluster2D. Ignoring path-mark."); } } + else if (rTP.GetFitLineSegments() && pm->fType == TEvePathMarkD::kLineSegment) + { + if (TEveTrackPropagator::IsOutsideBounds(pm->fV, maxRsq, maxZ)) + break; + + if (rTP.GoToLineSegment(pm->fV, pm->fE, currP)) + { + if (fDpDs != 0) + { + Double_t dp = fDpDs * rTP.GetTrackLength(start_point); + Double_t p = currP.Mag(); + if (p > dp) currP *= 1.0 - dp / p; + } + } + else + { + break; + } + } else { if (TEveTrackPropagator::IsOutsideBounds(pm->fV, maxRsq, maxZ)) break; - } + } } // loop path-marks if (!decay) { // printf("%s loop to bounds \n",fName.Data() ); - fPropagator->GoToBounds(currP); + rTP.GoToBounds(currP); } fPEnd = currP; // make_polyline: - fPropagator->FillPointSet(this); - fPropagator->ResetTrack(); + rTP.FillPointSet(this); + rTP.ResetTrack(); } } @@ -486,7 +527,7 @@ namespace //______________________________________________________________________________ void TEveTrack::SortPathMarksByTime() { - // Sort registerd pat-marks by time. + // Sort registered pat-marks by time. std::sort(fPathMarks.begin(), fPathMarks.end(), Cmp_pathmark_t()); } @@ -503,10 +544,11 @@ void TEveTrack::PrintPathMarks() for (vPathMark_i pm = fPathMarks.begin(); pm != fPathMarks.end(); ++pm) { - printf(" %-9s p: %8f %8f %8f Vertex: %8e %8e %8e %g \n", + printf(" %-9s p: %8f %8f %8f Vertex: %8e %8e %8e %g Extra:%8f %8f %8f\n", pm->TypeName(), pm->fP.fX, pm->fP.fY, pm->fP.fZ, pm->fV.fX, pm->fV.fY, pm->fV.fZ, + pm->fE.fX, pm->fE.fY, pm->fE.fZ, pm->fTime); } } @@ -529,15 +571,16 @@ Bool_t TEveTrack::ShouldBreakTrack() const { // Should this track be broken in projections. - Error("ShouldBreakTrack", "Deprected -- use TEveTrackPropagator functions."); - return fPropagator->GetProjTrackBreaking() == TEveTrackPropagator::kPTB_Break; + Error("ShouldBreakTrack", "Deprecated -- use TEveTrackPropagator functions."); + TEveTrackPropagator& rTP((fPropagator != 0) ? *fPropagator : TEveTrackPropagator::fgDefault); + return rTP.GetProjTrackBreaking() == TEveTrackPropagator::kPTB_Break; } //______________________________________________________________________________ UChar_t TEveTrack::GetBreakProjectedTracks() const { // Deprected -- use TEveTrackPropagator functions. - Error("GetBreakProjectedTracks", "Deprected -- use TEveTrackPropagator functions."); + Error("GetBreakProjectedTracks", "Deprecated -- use TEveTrackPropagator functions."); return 0; } @@ -546,7 +589,7 @@ void TEveTrack::SetBreakProjectedTracks(UChar_t) { // Deprected -- use TEveTrackPropagator functions. - Error("SetBreakProjectedTracks", "Deprected -- use TEveTrackPropagator functions."); + Error("SetBreakProjectedTracks", "Deprecated -- use TEveTrackPropagator functions."); } //______________________________________________________________________________ @@ -652,7 +695,7 @@ void TEveTrackList::SetPropagator(TEveTrackPropagator* prop) if (fPropagator == prop) return; if (fPropagator) fPropagator->DecRefCount(); fPropagator = prop; - if (fPropagator) prop->IncRefCount(); + if (fPropagator) fPropagator->IncRefCount(); } //============================================================================== diff --git a/graf3d/eve/src/TEveTrackPropagator.cxx b/graf3d/eve/src/TEveTrackPropagator.cxx index 5893e467d7d23..bf31399f872a4 100644 --- a/graf3d/eve/src/TEveTrackPropagator.cxx +++ b/graf3d/eve/src/TEveTrackPropagator.cxx @@ -237,7 +237,8 @@ TEveTrackPropagator::TEveTrackPropagator(const char* n, const char* t, fEditPathMarks (kTRUE), fFitDaughters (kTRUE), fFitReferences (kTRUE), - fFitDecay (kTRUE), fFitCluster2Ds (kTRUE), + fFitDecay (kTRUE), + fFitCluster2Ds (kTRUE), fFitLineSegments (kTRUE), fRnrDaughters (kFALSE), fRnrReferences (kFALSE), fRnrDecay (kFALSE), fRnrCluster2Ds (kFALSE), fRnrFV (kFALSE), @@ -351,6 +352,30 @@ void TEveTrackPropagator::ResetTrack() fH.fPhi = 0; } +//______________________________________________________________________________ +Int_t TEveTrackPropagator::GetCurrentPoint() const +{ + // Get index of current point on track. + + return fPoints.size() - 1; +} + +//______________________________________________________________________________ +Double_t TEveTrackPropagator::GetTrackLength(Int_t start_point, Int_t end_point) const +{ + // Calculate track length from start_point to end_point. + // If end_point is less than 0, distance to the end is returned. + + if (end_point < 0) end_point = fPoints.size() - 1; + + Double_t sum = 0; + for (Int_t i = start_point; i < end_point; ++i) + { + sum += (fPoints[i+1] - fPoints[i]).Mag(); + } + return sum; +} + //______________________________________________________________________________ Bool_t TEveTrackPropagator::GoToVertex(TEveVectorD& v, TEveVectorD& p) { @@ -367,6 +392,26 @@ Bool_t TEveTrackPropagator::GoToVertex(TEveVectorD& v, TEveVectorD& p) return fH.fValid ? LoopToVertex(v, p) : LineToVertex(v); } +//______________________________________________________________________________ +Bool_t TEveTrackPropagator::GoToLineSegment(const TEveVectorD& s, const TEveVectorD& r, TEveVectorD& p) +{ + // Propagate particle with momentum p to line with start point s and vector r to the second point. + + Update(fV, p, kTRUE); + + if (!fH.fValid) + { + TEveVectorD v; + ClosestPointBetweenLines(s, r, fV, p, v); + LineToVertex(v); + return kTRUE; + } + else + { + return LoopToLineSegment(s, r, p); + } +} + //______________________________________________________________________________ Bool_t TEveTrackPropagator::GoToVertex(TEveVectorF& v, TEveVectorF& p) { @@ -378,6 +423,17 @@ Bool_t TEveTrackPropagator::GoToVertex(TEveVectorF& v, TEveVectorF& p) return result; } +//______________________________________________________________________________ +Bool_t TEveTrackPropagator::GoToLineSegment(const TEveVectorF& s, const TEveVectorF& r, TEveVectorF& p) +{ + // TEveVectorF wrapper. + + TEveVectorD sd(s), rd(r), pd(p); + Bool_t result = GoToLineSegment(sd, rd, pd); + p = pd; + return result; +} + //______________________________________________________________________________ void TEveTrackPropagator::GoToBounds(TEveVectorD& p) { @@ -441,7 +497,7 @@ void TEveTrackPropagator::Update(const TEveVector4D& v, const TEveVectorD& p, } else { - fH.fRKStep = fH.fMaxStep; + fH.fRKStep = fH.fMaxStep; } } } @@ -611,32 +667,97 @@ Bool_t TEveTrackPropagator::LoopToVertex(TEveVectorD& v, TEveVectorD& p) TEveVectorD off(v - currV); off *= 1.0f / currV.fT; + DistributeOffset(off, first_point, np, p); + fV = v; + return kTRUE; + } + } - // Calculate the required momentum rotation. - // lpd - last-points-delta - TEveVectorD lpd0(fPoints[np-1]); - lpd0 -= fPoints[np-2]; - lpd0.Normalize(); + fPoints.push_back(v); + fV = v; + return kTRUE; +} - for (Int_t i = first_point; i < np; ++i) - { - fPoints[i] += off * fPoints[i].fT; - } +//______________________________________________________________________________ +Bool_t TEveTrackPropagator::LoopToLineSegment(const TEveVectorD& s, const TEveVectorD& r, TEveVectorD& p) +{ + // Propagate charged particle with momentum p to line segment with point s and vector r to the second point. + // It is expected that Update() with full-update was called before. Returns kFALSE if hits bounds. - TEveVectorD lpd1(fPoints[np-1]); - lpd1 -= fPoints[np-2]; - lpd1.Normalize(); + const Double_t maxRsq = fMaxR * fMaxR; + const Double_t rMagInv = 1./r.Mag(); - TEveTrans tt; - tt.SetupFromToVec(lpd0, lpd1); + TEveVector4D currV(fV); + TEveVector4D forwV(fV); + TEveVectorD forwP(p); - // TEveVectorD pb4(p); - // printf("Rotating momentum: p0 = "); p.Dump(); - tt.RotateIP(p); - // printf(" p1 = "); p.Dump(); - // printf(" n1=%f, n2=%f, dp = %f deg\n", pb4.Mag(), p.Mag(), - // TMath::RadToDeg()*TMath::ACos(p.Dot(pb4)/(pb4.Mag()*p.Mag()))); + Int_t first_point = fPoints.size(); + Int_t np = first_point; + + TEveVectorD forwC; + TEveVectorD currC; + do + { + Step(currV, p, forwV, forwP); + Update(forwV, forwP); + + ClosestPointFromVertexToLineSegment(forwV, s, r, rMagInv, forwC); + + // check forwV is over segment with orthogonal component of + // momentum to vector r + TEveVectorD b = r; b.Normalize(); + Double_t x = forwP.Dot(b); + TEveVectorD pTPM = forwP - x*b; + if (pTPM.Dot(forwC - forwV) < 0) + { + break; + } + if (IsOutsideBounds(forwV, maxRsq, fMaxZ)) + { + fV = currV; + return kFALSE; + } + + fPoints.push_back(forwV); + currV = forwV; + p = forwP; + currC = forwC; + ++np; + } while (np < fNMax); + + // Get closest point on segment relative to line with forw and currV points. + TEveVectorD v; + ClosestPointBetweenLines(s, r, currV, forwV - currV, v); + + // make the remaining fractional step + if (np > first_point) + { + if ((v - currV).Mag() > kStepEps) + { + TEveVector last_step = forwV - currV; + TEveVector delta = v - currV; + Double_t step_frac = last_step.Dot(delta) / last_step.Mag2(); + if (step_frac > 0) + { + // Step for fraction of previous step size. + // We pass 'enforce_max_step' flag to Update(). + Float_t orig_max_step = fH.fMaxStep; + fH.fMaxStep = step_frac * (forwV - currV).Mag(); + Update(currV, p, kTRUE, kTRUE); + Step(currV, p, forwV, forwP); + p = forwP; + currV = forwV; + fPoints.push_back(currV); + ++np; + fH.fMaxStep = orig_max_step; + } + + // Distribute offset to desired crossing point over all segment. + + TEveVectorD off(v - currV); + off *= 1.0f / currV.fT; + DistributeOffset(off, first_point, np, p); fV = v; return kTRUE; } @@ -647,6 +768,38 @@ Bool_t TEveTrackPropagator::LoopToVertex(TEveVectorD& v, TEveVectorD& p) return kTRUE; } +//______________________________________________________________________________ +void TEveTrackPropagator::DistributeOffset(const TEveVectorD& off, Int_t first_point, Int_t np, TEveVectorD& p) +{ + // Distribute offset between first and last point index and rotate + // momentum. + + // Calculate the required momentum rotation. + // lpd - last-points-delta + TEveVectorD lpd0(fPoints[np-1]); + lpd0 -= fPoints[np-2]; + lpd0.Normalize(); + + for (Int_t i = first_point; i < np; ++i) + { + fPoints[i] += off * fPoints[i].fT; + } + + TEveVectorD lpd1(fPoints[np-1]); + lpd1 -= fPoints[np-2]; + lpd1.Normalize(); + + TEveTrans tt; + tt.SetupFromToVec(lpd0, lpd1); + + // TEveVectorD pb4(p); + // printf("Rotating momentum: p0 = "); p.Dump(); + tt.RotateIP(p); + // printf(" p1 = "); p.Dump(); + // printf(" n1=%f, n2=%f, dp = %f deg\n", pb4.Mag(), p.Mag(), + // TMath::RadToDeg()*TMath::ACos(p.Dot(pb4)/(pb4.Mag()*p.Mag()))); +} + //______________________________________________________________________________ Bool_t TEveTrackPropagator::LineToVertex(TEveVectorD& v) { @@ -752,15 +905,14 @@ Bool_t TEveTrackPropagator::LineIntersectPlane(const TEveVectorD& p, // the line. TEveVectorD pos(fV.fX, fV.fY, fV.fZ); - TEveVectorD delta = pos - point; + TEveVectorD delta = point - pos; - Double_t d = delta.Dot(normal); - if (d == 0) { - itsect = pos; - return kTRUE; + Double_t pn = p.Dot(normal); + if (pn == 0) + { + return kFALSE; } - - Double_t t = (p.Dot(normal)) / d; + Double_t t = delta.Dot(normal) / pn; if (t < 0) { return kFALSE; } else { @@ -792,6 +944,56 @@ Bool_t TEveTrackPropagator::IntersectPlane(const TEveVectorD& p, return LineIntersectPlane(p, point, normal, itsect); } +//______________________________________________________________________________ +void TEveTrackPropagator::ClosestPointFromVertexToLineSegment(const TEveVectorD& v, + const TEveVectorD& s, + const TEveVectorD& r, + Double_t rMagInv, + TEveVectorD& c) +{ + // Get closest point from given vertex v to line segment defined with s and r. + // Argument rMagInv is cached. rMagInv= 1./rMag() + + TEveVectorD dir = v - s; + TEveVectorD b1 = r * rMagInv; + + // paralell distance + Double_t dot = dir.Dot(b1); + TEveVectorD dirI = dot * b1; + + Double_t facX = dot * rMagInv; + + if (facX <= 0) + c = s; + else if (facX >= 1) + c = s + r; + else + c = s + dirI; +} + +//______________________________________________________________________________ +Bool_t TEveTrackPropagator::ClosestPointBetweenLines(const TEveVectorD& p0, + const TEveVectorD& u, + const TEveVectorD& q0, + const TEveVectorD& v, + TEveVectorD& out) +{ + // Get closest point on line defined with vector p0 and u. + // Return false if the point is forced on the line segment. + + TEveVectorD w0 = p0 -q0; + Double_t a = u.Mag2(); + Double_t b = u.Dot(v); + Double_t c = v.Mag2(); + Double_t d = u.Dot(w0); + Double_t e = v.Dot(w0); + + Double_t x = (b*e - c*d)/(a*c -b*b); + Bool_t force = (x < 0 || x > 1); + out = p0 + TMath::Range(0., 1., x) * u; + return force; +} + //______________________________________________________________________________ void TEveTrackPropagator::FillPointSet(TEvePointSet* ps) const { @@ -951,6 +1153,15 @@ void TEveTrackPropagator::SetFitDecay(Bool_t x) RebuildTracks(); } +//______________________________________________________________________________ +void TEveTrackPropagator::SetFitLineSegments(Bool_t x) +{ + // Set line segment fitting and rebuild tracks. + + fFitLineSegments = x; + RebuildTracks(); +} + //______________________________________________________________________________ void TEveTrackPropagator::SetFitCluster2Ds(Bool_t x) { diff --git a/graf3d/eve/src/TEveTrackPropagatorEditor.cxx b/graf3d/eve/src/TEveTrackPropagatorEditor.cxx index 6ae48120c0da8..e21951eaf01f9 100644 --- a/graf3d/eve/src/TEveTrackPropagatorEditor.cxx +++ b/graf3d/eve/src/TEveTrackPropagatorEditor.cxx @@ -45,7 +45,8 @@ TEveTrackPropagatorSubEditor::TEveTrackPropagatorSubEditor(const TGWindow *p): fRefsCont(0), fPMFrame(0), fFitDaughters(0), fFitReferences(0), - fFitDecay(0), fFitCluster2Ds(0), + fFitDecay(0), + fFitCluster2Ds(0), fFitLineSegments(0), fRnrDaughters(0), fRnrReferences(0), fRnrDecay(0), fRnrCluster2Ds(0), fRnrFV(0), @@ -124,16 +125,19 @@ void TEveTrackPropagatorSubEditor::CreateRefsContainer(TGVerticalFrame* p) fFitReferences = new TGCheckButton(fitPM, "Fit Refs", TEvePathMark::kReference); fFitDecay = new TGCheckButton(fitPM, "Fit Decay", TEvePathMark::kDecay); fFitCluster2Ds = new TGCheckButton(fitPM, "Fit 2D Clusters", TEvePathMark::kCluster2D); + fFitLineSegments = new TGCheckButton(fitPM, "Fit Line Segments", TEvePathMark::kLineSegment); fitPM->AddFrame(fFitDaughters); fitPM->AddFrame(fFitReferences); fitPM->AddFrame(fFitDecay); fitPM->AddFrame(fFitCluster2Ds); + fitPM->AddFrame(fFitLineSegments); - fFitDecay ->Connect("Clicked()","TEveTrackPropagatorSubEditor", this, "DoFitPM()"); - fFitReferences->Connect("Clicked()","TEveTrackPropagatorSubEditor", this, "DoFitPM()"); - fFitDaughters ->Connect("Clicked()","TEveTrackPropagatorSubEditor", this, "DoFitPM()"); - fFitCluster2Ds->Connect("Clicked()","TEveTrackPropagatorSubEditor", this, "DoFitPM()"); + fFitDecay ->Connect("Clicked()","TEveTrackPropagatorSubEditor", this, "DoFitPM()"); + fFitReferences ->Connect("Clicked()","TEveTrackPropagatorSubEditor", this, "DoFitPM()"); + fFitDaughters ->Connect("Clicked()","TEveTrackPropagatorSubEditor", this, "DoFitPM()"); + fFitCluster2Ds ->Connect("Clicked()","TEveTrackPropagatorSubEditor", this, "DoFitPM()"); + fFitLineSegments->Connect("Clicked()","TEveTrackPropagatorSubEditor", this, "DoFitPM()"); } // Kinematics fitting. { @@ -260,6 +264,7 @@ void TEveTrackPropagatorSubEditor::SetModel(TEveTrackPropagator* m) fFitReferences->SetState(fM->fFitReferences ? kButtonDown : kButtonUp); fFitDecay->SetState(fM->fFitDecay ? kButtonDown : kButtonUp); fFitCluster2Ds->SetState(fM->fFitCluster2Ds ? kButtonDown : kButtonUp); + fFitLineSegments->SetState(fM->fFitLineSegments ? kButtonDown : kButtonUp); fPMAtt->SetModel(&fM->fPMAtt); } @@ -358,6 +363,9 @@ void TEveTrackPropagatorSubEditor::DoFitPM() case TEvePathMark::kCluster2D: fM->SetFitCluster2Ds(on); break; + case TEvePathMark::kLineSegment: + fM->SetFitLineSegments(on); + break; default: break; diff --git a/graf3d/eve/src/TEveVSD.cxx b/graf3d/eve/src/TEveVSD.cxx index ce79fa1494e5b..00e83fcf1b741 100644 --- a/graf3d/eve/src/TEveVSD.cxx +++ b/graf3d/eve/src/TEveVSD.cxx @@ -19,7 +19,7 @@ //______________________________________________________________________________ // // Visualization Summary Data - a collection of trees holding standard -// event data in experiment independant format. +// event data in experiment independent format. ClassImp(TEveVSD); diff --git a/graf3d/eve/src/TEveWindow.cxx b/graf3d/eve/src/TEveWindow.cxx index fb2374eb92185..fdc53e1616845 100644 --- a/graf3d/eve/src/TEveWindow.cxx +++ b/graf3d/eve/src/TEveWindow.cxx @@ -15,13 +15,12 @@ #include "TEveSelection.h" #include "THashList.h" -#include "TContextMenu.h" #include "TGButton.h" -#include "TContextMenu.h" #include "TGMenu.h" #include "TGPack.h" #include "TGTab.h" +#include "TRootContextMenu.h" #include <cassert> @@ -65,7 +64,7 @@ ClassImp(TEveCompositeFrame); -TContextMenu* TEveCompositeFrame::fgCtxMenu = 0; +TEveContextMenu* TEveCompositeFrame::fgCtxMenu = 0; const TString TEveCompositeFrame::fgkEmptyFrameName("<relinquished>"); TList* TEveCompositeFrame::fgFrameList = new THashList; @@ -337,18 +336,10 @@ void TEveCompositeFrame::ActionPressed() // This opens context menu of the eve-window. if (fgCtxMenu == 0) { - fgCtxMenu = new TContextMenu("", ""); + fgCtxMenu = new TEveContextMenu("", ""); } - Int_t x, y; - UInt_t w, h; - Window_t childdum; - gVirtualX->GetWindowSize(fIconBar->GetId(), x, y, w, h); - gVirtualX->TranslateCoordinates(fIconBar->GetId(), - gClient->GetDefaultRoot()->GetId(), - 0, 0, x, y, childdum); - - fgCtxMenu->Popup(x - 2, y + h - 2, fEveWindow); + fgCtxMenu->SetupAndPopup(fIconBar, fEveWindow); } //______________________________________________________________________________ @@ -1528,3 +1519,51 @@ TEveWindowSlot* TEveWindowTab::NewSlot() return TEveWindow::CreateWindowInTab(fTab, this); } + + +//============================================================================== +//============================================================================== +// Helper classes +//============================================================================== +//============================================================================== + + +//============================================================================== +// TEveContextMenu +//============================================================================== + +//______________________________________________________________________________ +// +// Specialization of TContext menu. +// Provide a window manager hint that ensures proper placement of popup on Cocoa. + +ClassImp(TEveContextMenu); + +//______________________________________________________________________________ +TEveContextMenu::TEveContextMenu(const char *name, const char *title) : + TContextMenu(name, title) +{ + // Constructor. +} + +//______________________________________________________________________________ +void TEveContextMenu::SetupAndPopup(TGWindow* button, TObject* obj) +{ + // Position the popup below given button and show context menu for object obj. + + Int_t x, y; + UInt_t w, h; + Window_t childdum; + gVirtualX->GetWindowSize(button->GetId(), x, y, w, h); + gVirtualX->TranslateCoordinates(button->GetId(), + gClient->GetDefaultRoot()->GetId(), + 0, 0, x, y, childdum); + + TRootContextMenu *rcm = dynamic_cast<TRootContextMenu*>(fContextMenuImp); + if (rcm != 0) + { + gVirtualX->SetWMTransientHint (rcm->GetId(), button->GetId()); + } + + Popup(x - 2, y + h - 2, obj); +} diff --git a/graf3d/ftgl/CMakeLists.txt b/graf3d/ftgl/CMakeLists.txt index e7f081c364888..fea9270b05cd4 100644 --- a/graf3d/ftgl/CMakeLists.txt +++ b/graf3d/ftgl/CMakeLists.txt @@ -4,7 +4,7 @@ include_directories(${OPENGL_INCLUDE_DIR} ${FREETYPE_INCLUDE_DIRS}) -ROOT_LINKER_LIBRARY(FTGL *.cxx LIBRARIES ${OPENGL_LIBRARIES} ${FREETYPE_LIBRARIES}) +ROOT_LINKER_LIBRARY(FTGL *.cxx LIBRARIES ${OPENGL_LIBRARIES} ${FREETYPE_LIBRARIES} ${ZLIB_LIBRARY}) if(builtin_freetype) add_dependencies(FTGL FREETYPE) endif() diff --git a/graf3d/ftgl/Module.mk b/graf3d/ftgl/Module.mk index b1d8c924f6fc4..165e8d803a590 100644 --- a/graf3d/ftgl/Module.mk +++ b/graf3d/ftgl/Module.mk @@ -28,9 +28,6 @@ ALLLIBS += $(FTGLLIB) # include all dependency files INCLUDEFILES += $(FTGLDEP) -ifeq ($(ARCH),win32) -GLLIBS := opengl32.lib glu32.lib -endif ifeq ($(MACOSX_MINOR),3) FTGLLIBEXTRA += -lz endif @@ -46,7 +43,7 @@ $(FTGLLIB): $(FTGLO) $(FREETYPEDEP) $(ORDER_) $(MAINLIBS) $(FTGLLIBDEP) "$(SOFLAGS)" libFTGL.$(SOEXT) $@ \ "$(FTGLO)" \ "$(FREETYPELDFLAGS) $(FREETYPELIB) \ - $(FTGLLIBEXTRA) $(XLIBS) $(GLLIBS)" + $(FTGLLIBEXTRA) $(GLLIBS)" all-$(MODNAME): $(FTGLLIB) @@ -63,3 +60,6 @@ distclean:: distclean-$(MODNAME) ##### extra rules ###### $(FTGLO): $(FREETYPEDEP) $(FTGLO): CXXFLAGS += $(FREETYPEINC) $(OPENGLINCDIR:%=-I%) +ifeq ($(MACOSX_GLU_DEPRECATED),yes) +$(FTGLO): CXXFLAGS += -Wno-deprecated-declarations +endif diff --git a/graf3d/ftgl/inc/FTFace.h b/graf3d/ftgl/inc/FTFace.h index 356abd5392684..44472c0fca5f6 100755 --- a/graf3d/ftgl/inc/FTFace.h +++ b/graf3d/ftgl/inc/FTFace.h @@ -41,16 +41,16 @@ class FTGL_EXPORT FTFace virtual ~FTFace(); /** - * Attach auxilliary file to font (e.g., font metrics). + * Attach auxiliary file to font (e.g., font metrics). * - * @param fontFilePath auxilliary font file path. + * @param fontFilePath auxiliary font file path. * @return <code>true</code> if file has opened * successfully. */ bool Attach( const char* fontFilePath); /** - * Attach auxilliary data to font (e.g., font metrics) from memory + * Attach auxiliary data to font (e.g., font metrics) from memory * * @param pBufferBytes the in-memory buffer * @param bufferSizeInBytes the length of the buffer in bytes diff --git a/graf3d/ftgl/inc/FTFont.h b/graf3d/ftgl/inc/FTFont.h index 550da7a3f8385..480dc7e1a245f 100755 --- a/graf3d/ftgl/inc/FTFont.h +++ b/graf3d/ftgl/inc/FTFont.h @@ -55,18 +55,18 @@ class FTGL_EXPORT FTFont virtual ~FTFont(); /** - * Attach auxilliary file to font e.g font metrics. + * Attach auxiliary file to font e.g font metrics. * * Note: not all font formats implement this function. * - * @param fontFilePath auxilliary font file path. + * @param fontFilePath auxiliary font file path. * @return <code>true</code> if file has been attached * successfully. */ bool Attach( const char* fontFilePath); /** - * Attach auxilliary data to font e.g font metrics, from memory + * Attach auxiliary data to font e.g font metrics, from memory * * Note: not all font formats implement this function. * diff --git a/graf3d/gl/CMakeLists.txt b/graf3d/gl/CMakeLists.txt index a6216dc6bae0b..4dcbf61b023ea 100644 --- a/graf3d/gl/CMakeLists.txt +++ b/graf3d/gl/CMakeLists.txt @@ -5,10 +5,8 @@ ROOT_USE_PACKAGE(gui/ged) if(builtin_glew) ROOT_USE_PACKAGE(graf3d/glew) endif() -if(builtin_ftgl) - ROOT_USE_PACKAGE(graf3d/ftgl) -endif() -include_directories(${OPENGL_INCLUDE_DIR}) + +include_directories(${OPENGL_INCLUDE_DIR} ${FTGL_INCLUDE_DIR}) ROOT_GLOB_HEADERS(headers RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}/inc ${CMAKE_CURRENT_SOURCE_DIR}/inc/*.h) list(REMOVE_ITEM headers gl2ps.h CsgOps.h TGLIncludes.h TGLWSIncludes.h TGLContextPrivate.h @@ -20,11 +18,11 @@ if(WIN32) list(REMOVE_ITEM sources TX11GL.cxx) endif() -set_source_files_properties(src/TGLFontManager.cxx PROPERTIES COMPILE_FLAGS "-I${FREETYPE_INCLUDE_DIR} -DBUILTIN_FTGL") -set_source_files_properties(src/TGLText.cxx PROPERTIES COMPILE_FLAGS "-I${FREETYPE_INCLUDE_DIR} -DBUILTIN_FTGL") +set_source_files_properties(src/TGLFontManager.cxx PROPERTIES COMPILE_FLAGS "-I${FREETYPE_INCLUDE_DIR} ${FTGL_CFLAGS}") +set_source_files_properties(src/TGLText.cxx PROPERTIES COMPILE_FLAGS "-I${FREETYPE_INCLUDE_DIR} ${FTGL_CFLAGS}") ROOT_GENERATE_DICTIONARY(G__GL ${headers} LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(RGL LINKDEF LinkDef.h DEPENDENCIES Graf3d Gui Graf Hist Ged MathCore Tree TreePlayer) -ROOT_LINKER_LIBRARY(RGL ${sources} G__GL.cxx LIBRARIES ${OPENGL_LIBRARIES} GLEW FTGL DEPENDENCIES Hist Gui Ged) +ROOT_LINKER_LIBRARY(RGL ${sources} G__GL.cxx LIBRARIES ${OPENGL_LIBRARIES} GLEW ${FTGL_LIBRARIES} DEPENDENCIES Hist Gui Ged) ROOT_INSTALL_HEADERS() diff --git a/graf3d/gl/Module.mk b/graf3d/gl/Module.mk index 845af694dd9f9..461ee84a05fe9 100644 --- a/graf3d/gl/Module.mk +++ b/graf3d/gl/Module.mk @@ -26,6 +26,11 @@ ifeq ($(ARCH),win32) GLS := $(filter-out $(MODDIRS)/TX11GL.cxx, $(GLS)) GLH := $(filter-out $(MODDIRI)/TX11GL.h, $(GLH)) endif +# Excluded from OSX Cocoa builds +ifeq ($(BUILDCOCOA),yes) +GLS := $(filter-out $(MODDIRS)/TX11GL.cxx, $(GLS)) +GLH := $(filter-out $(MODDIRI)/TX11GL.h, $(GLH)) +endif # Excluded from rootcint GLH1 := $(MODDIRI)/gl2ps.h $(MODDIRI)/CsgOps.h \ @@ -39,11 +44,14 @@ GLH2 := $(filter-out $(GLH1), $(GLH)) ifneq ($(OPENGLLIB),) GLLIBS := $(OPENGLLIBDIR) $(OPENGLULIB) $(OPENGLLIB) \ - $(X11LIBDIR) -lX11 -lm + $(XLIBS) -lm endif ifeq ($(ARCH),win32) GLLIBS := opengl32.lib glu32.lib endif +ifeq ($(BUILDCOCOA),yes) +GLLIBS := -framework OpenGL +endif GLO := $(call stripsrc,$(GLS:.cxx=.o)) GLDEP := $(GLO:.o=.d) $(GLDO:.o=.d) $(GLO1:.o=.d) @@ -113,3 +121,7 @@ $(GLO): CXXFLAGS += $(GLEWINCDIR:%=-I%) $(GLEWCPPFLAGS) # Optimize dictionary with stl containers. $(GLDO): NOOPT = $(OPT) + +ifeq ($(MACOSX_GLU_DEPRECATED),yes) +$(GLO) $(GLDO): CXXFLAGS += -Wno-deprecated-declarations +endif diff --git a/graf3d/gl/inc/LinkDef.h b/graf3d/gl/inc/LinkDef.h index c4220f4db0a14..e00840bf5e208 100644 --- a/graf3d/gl/inc/LinkDef.h +++ b/graf3d/gl/inc/LinkDef.h @@ -8,6 +8,8 @@ * For the list of contributors see $ROOTSYS/README/CREDITS. * *************************************************************************/ +#include "RConfigure.h" + #ifdef __CINT__ #pragma link off all globals; @@ -136,7 +138,7 @@ #pragma link C++ class TGLTH3Composition; #pragma link C++ class TGLTH3CompositionPainter; -#ifndef _WIN32 +#if !defined(_WIN32) && !defined(R__HAS_COCOA) #pragma link C++ class TX11GLManager; #endif diff --git a/graf3d/gl/inc/TGLBoundingBox.h b/graf3d/gl/inc/TGLBoundingBox.h index 2ccec17037eb9..105fb65cf1fd0 100644 --- a/graf3d/gl/inc/TGLBoundingBox.h +++ b/graf3d/gl/inc/TGLBoundingBox.h @@ -124,8 +124,8 @@ class TGLBoundingBox TGLPlane GetNearPlane() const; // Overlap testing - EOverlap Overlap(const TGLPlane & plane) const; - EOverlap Overlap(const TGLBoundingBox & box) const; + Rgl::EOverlap Overlap(const TGLPlane & plane) const; + Rgl::EOverlap Overlap(const TGLBoundingBox & box) const; void Draw(Bool_t solid = kFALSE) const; void Dump() const; diff --git a/graf3d/gl/inc/TGLCamera.h b/graf3d/gl/inc/TGLCamera.h index 175bef6d586d4..6171e2f699e2b 100644 --- a/graf3d/gl/inc/TGLCamera.h +++ b/graf3d/gl/inc/TGLCamera.h @@ -15,6 +15,7 @@ #include "TGLUtil.h" #include "TGLBoundingBox.h" #include "TPoint.h" +#include "TObject.h" #include <cassert> #include <cmath> @@ -39,7 +40,7 @@ // concrete ortho and prespective classes must implement. // ////////////////////////////////////////////////////////////////////////// -class TGLCamera +class TGLCamera : public TObject { public: enum EFrustumPlane @@ -71,23 +72,24 @@ class TGLCamera TGLCamera & operator=(const TGLCamera &); protected: - // Fields - TGLMatrix fCamBase; //! tranformation to center and rotation from up to x vector - TGLMatrix fCamTrans; //! transformation relative to fCamTrans - Bool_t fExternalCenter; //! use external center insead of scene center - Bool_t fFixDefCenter; //! use fixed default center - TGLVector3 fExtCenter; //! external camera center - TGLVector3 fDefCenter; //! deafult camera center - TGLVector3 fFDCenter; //! fixed deafult camera center - TGLVector3 *fCenter; //! current camera center - - mutable Double_t fNearClip; //! last applied near-clip - mutable Double_t fFarClip; //! last applied far-clip - - // Set in Setup() - Double_t fDollyDefault; //! default distnce from viewing centre - Double_t fDollyDistance; //! unit distance for camera movement in fwd/bck direction - Float_t fVAxisMinAngle; //! minimal allowed angle between up and fCamTrans Z vector + // Fields + TGLMatrix fCamBase; // tranformation to center and rotation from up to x vector + TGLMatrix fCamTrans; // transformation relative to fCamTrans + Bool_t fExternalCenter; // use external center insead of scene center + Bool_t fFixDefCenter; // use fixed default center + Bool_t fWasArcBalled; // set when arc-ball rotation is used + TGLVector3 fExtCenter; // external camera center + TGLVector3 fDefCenter; // default camera center + TGLVector3 fFDCenter; // fixed default camera center + TGLVector3 *fCenter; //! current camera center + + mutable Double_t fNearClip; //! last applied near-clip + mutable Double_t fFarClip; //! last applied far-clip + + // Set in Setup() + Double_t fDollyDefault; // default distnce from viewing centre + Double_t fDollyDistance; // unit distance for camera movement in fwd/bck direction + Float_t fVAxisMinAngle; // minimal allowed angle between up and fCamTrans Z vector // Internal cached matrices and frustum planes mutable Bool_t fCacheDirty; //! cached items dirty? @@ -136,6 +138,8 @@ class TGLCamera virtual Bool_t Truck(Int_t xDelta, Int_t yDelta, Bool_t mod1, Bool_t mod2) = 0; virtual Bool_t Rotate(Int_t xDelta, Int_t yDelta, Bool_t mod1, Bool_t mod2); virtual Bool_t RotateRad(Double_t hRotate, Double_t vRotate); + virtual Bool_t RotateArcBall(Int_t xDelta, Int_t yDelta, Bool_t mod1, Bool_t mod2); + virtual Bool_t RotateArcBallRad(Double_t hRotate, Double_t vRotate); virtual void Apply(const TGLBoundingBox & sceneBox, const TGLRect * pickRect = 0) const = 0; @@ -177,8 +181,8 @@ class TGLCamera // Overlap / projection / intersection tests // Viewport is GL coorinate system - origin bottom/left - EOverlap FrustumOverlap (const TGLBoundingBox & box) const; // box/frustum overlap test - EOverlap ViewportOverlap(const TGLBoundingBox & box) const; // box/viewport overlap test + Rgl::EOverlap FrustumOverlap (const TGLBoundingBox & box) const; // box/frustum overlap test + Rgl::EOverlap ViewportOverlap(const TGLBoundingBox & box) const; // box/viewport overlap test TGLRect ViewportRect (const TGLBoundingBox & box, TGLBoundingBox::EFace face) const; TGLRect ViewportRect (const TGLBoundingBox & box, const TGLBoundingBox::EFace * face = 0) const; TGLVertex3 WorldToViewport(const TGLVertex3 & worldVertex, TGLMatrix* modviewMat=0) const; @@ -209,7 +213,7 @@ class TGLCamera // Debuging - draw frustum and interest boxes void DrawDebugAids() const; - ClassDef(TGLCamera,0); // Camera abstract base class. + ClassDef(TGLCamera,1); // Camera abstract base class. }; inline const TGLPlane & TGLCamera::FrustumPlane(EFrustumPlane plane) const diff --git a/graf3d/gl/inc/TGLClip.h b/graf3d/gl/inc/TGLClip.h index 5fa21c30a3412..afd61ba52eb68 100644 --- a/graf3d/gl/inc/TGLClip.h +++ b/graf3d/gl/inc/TGLClip.h @@ -31,8 +31,16 @@ class TGLManipSet; class TGLClip : public TGLPhysicalShape { public: - enum EMode { kOutside, // Clip away what's outside - kInside // Clip away what's inside + enum EMode + { + kOutside, // Clip away what's outside + kInside // Clip away what's inside + }; + enum EType + { + kClipNone = 0, + kClipPlane, + kClipBox }; protected: @@ -170,11 +178,11 @@ class TGLClipSet : public TGLOverlayElement void InvalidateClips(); void InvalidateCurrentClip(); - void GetClipState(EClipType type, Double_t data[6]) const; - void SetClipState(EClipType type, const Double_t data[6]); + void GetClipState(TGLClip::EType type, Double_t data[6]) const; + void SetClipState(TGLClip::EType type, const Double_t data[6]); - EClipType GetClipType() const; - void SetClipType(EClipType type); + TGLClip::EType GetClipType() const; + void SetClipType(TGLClip::EType type); // Clip control flags Bool_t GetAutoUpdate() const { return fAutoUpdate; } diff --git a/graf3d/gl/inc/TGLClipSetEditor.h b/graf3d/gl/inc/TGLClipSetEditor.h index 68af06af1f90b..041d46871d3a7 100644 --- a/graf3d/gl/inc/TGLClipSetEditor.h +++ b/graf3d/gl/inc/TGLClipSetEditor.h @@ -19,15 +19,16 @@ #include "TGLUtil.h" #endif +#include "TGLClip.h" + class TGButton; class TGCheckButton; class TGNumberEntry; class TGButtonGroup; -class TGLClipSet; - -class TGLClipSetSubEditor : public TGVerticalFrame { +class TGLClipSetSubEditor : public TGVerticalFrame +{ private: TGLClipSetSubEditor(const TGLClipSetSubEditor&); // Not implemented TGLClipSetSubEditor& operator=(const TGLClipSetSubEditor&); // Not implemented @@ -35,7 +36,7 @@ class TGLClipSetSubEditor : public TGVerticalFrame { protected: TGLClipSet *fM; - EClipType fCurrentClip; + TGLClip::EType fCurrentClip; TGButtonGroup *fTypeButtons; TGCompositeFrame *fPlanePropFrame; diff --git a/graf3d/gl/inc/TGLContextPrivate.h b/graf3d/gl/inc/TGLContextPrivate.h index ce40fb2f76881..eaf0e45fb2749 100644 --- a/graf3d/gl/inc/TGLContextPrivate.h +++ b/graf3d/gl/inc/TGLContextPrivate.h @@ -9,6 +9,8 @@ #include "TGLIncludes.h" #include "TGLWSIncludes.h" #include "TGLContext.h" +#include "RConfigure.h" +#include "GuiTypes.h" #ifdef WIN32 @@ -36,6 +38,29 @@ class TGLContextPrivate { static std::map<HGLRC, TGLContext *> fgContexts; }; +#elif defined(R__HAS_COCOA) + +class TGLContextPrivate { +public: + Handle_t fWindowID; + Handle_t fGLContext; + + + TGLContextPrivate() + : fGLContext(0) + { + } + + static void RegisterContext(TGLContext *ctx); + static void RemoveContext(TGLContext *ctx); + static TGLContext *GetCurrentContext(); + +private: + TGLContextPrivate(const TGLContextPrivate &); + TGLContextPrivate &operator = (const TGLContextPrivate &); + + static std::map<Handle_t, TGLContext *> fgContexts; +}; #else @@ -67,5 +92,4 @@ class TGLContextPrivate { }; #endif - #endif diff --git a/graf3d/gl/inc/TGLEventHandler.h b/graf3d/gl/inc/TGLEventHandler.h index 9b9e86345f179..ecae52ed6f8e2 100644 --- a/graf3d/gl/inc/TGLEventHandler.h +++ b/graf3d/gl/inc/TGLEventHandler.h @@ -48,6 +48,7 @@ class TGLEventHandler : public TGEventHandler Bool_t fInPointerGrab; Bool_t fMouseTimerRunning; Bool_t fTooltipShown; + Bool_t fArcBall; Int_t fTooltipPixelTolerance; Int_t fSecSelType; // secondary selection type Bool_t fDoInternalSelection; @@ -103,6 +104,9 @@ class TGLEventHandler : public TGEventHandler Bool_t GetDoInternalSelection() const { return fDoInternalSelection; } void SetDoInternalSelection(Bool_t x) { fDoInternalSelection = x; } + Bool_t GetArcBall() const { return fArcBall; } + void SetArcBall(Bool_t a) { fArcBall = a; } + ClassDef(TGLEventHandler, 0); // Base-class and default implementation of event-handler for TGLViewer. }; diff --git a/graf3d/gl/inc/TGLFormat.h b/graf3d/gl/inc/TGLFormat.h index e96522ed5a9c9..99e23d64dd0db 100644 --- a/graf3d/gl/inc/TGLFormat.h +++ b/graf3d/gl/inc/TGLFormat.h @@ -12,6 +12,7 @@ #ifndef ROOT_TGLFormat #define ROOT_TGLFormat +#include "TVirtualGL.h" #include "Rtypes.h" #include <vector> @@ -33,18 +34,6 @@ class TGLFormat { -public: - enum EFormatOptions - { - kNone = 0, - kDoubleBuffer = 1, - kDepth = 2, - kAccum = 4, - kStencil = 8, - kStereo = 16, - kMultiSample = 32 - }; - private: Bool_t fDoubleBuffered; Bool_t fStereo; @@ -60,7 +49,7 @@ class TGLFormat public: TGLFormat(); - TGLFormat(EFormatOptions options); + TGLFormat(Rgl::EFormatOptions options); //Virtual dtor only to supress warnings from g++ - //ClassDef adds virtual functions, so g++ wants virtual dtor. diff --git a/graf3d/gl/inc/TGLLogicalShape.h b/graf3d/gl/inc/TGLLogicalShape.h index fdea8fc389a34..d9383dd21d75f 100644 --- a/graf3d/gl/inc/TGLLogicalShape.h +++ b/graf3d/gl/inc/TGLLogicalShape.h @@ -60,6 +60,8 @@ class TGLLogicalShape void PurgeDLRange(UInt_t base, Int_t size) const; + static Bool_t fgIgnoreSizeForCameraInterest; + public: TGLLogicalShape(); TGLLogicalShape(TObject* obj); @@ -99,7 +101,7 @@ class TGLLogicalShape virtual void DrawHighlight(TGLRnrCtx& rnrCtx, const TGLPhysicalShape* pshp, Int_t lvl=-1) const; - virtual Bool_t IgnoreSizeForOfInterest() const { return kFALSE; } + virtual Bool_t IgnoreSizeForOfInterest() const; // Override in sub-classes that do direct object rendering (e.g. TGLObject). virtual Bool_t KeepDuringSmartRefresh() const { return kFALSE; } @@ -110,6 +112,9 @@ class TGLLogicalShape void InvokeContextMenu(TContextMenu & menu, UInt_t x, UInt_t y) const; + static Bool_t GetIgnoreSizeForCameraInterest(); + static void SetIgnoreSizeForCameraInterest(Bool_t isfci); + ClassDef(TGLLogicalShape,0) // a logical (non-placed, local frame) drawable object }; diff --git a/graf3d/gl/inc/TGLOrthoCamera.h b/graf3d/gl/inc/TGLOrthoCamera.h index e0761503e1fe3..c99ed8a25cd0e 100644 --- a/graf3d/gl/inc/TGLOrthoCamera.h +++ b/graf3d/gl/inc/TGLOrthoCamera.h @@ -36,26 +36,27 @@ class TGLOrthoCamera : public TGLCamera { public: enum EType { kZOY, kXOZ, kXOY, // Pair of world axes aligned to h/v screen. - kZnOY, kXnOZ, kXnOY }; // 'n' means preceeding axis is negated. + kZnOY, kXnOZ, kXnOY }; // 'n' means preceding axis is negated. private: // Fields - EType fType; //! camera type - Bool_t fEnableRotate; //! enable rotation - Bool_t fDollyToZoom; //! zoom when dolly is requested + EType fType; // camera type + Bool_t fEnableRotate; // enable rotation + Bool_t fDollyToZoom; // zoom when dolly is requested // Limits - set in Setup() - Double_t fZoomMin; //! minimum zoom factor - Double_t fZoomDefault; //! default zoom factor - Double_t fZoomMax; //! maximum zoom factor + Double_t fZoomMin; // minimum zoom factor + Double_t fZoomDefault; // default zoom factor + Double_t fZoomMax; // maximum zoom factor TGLBoundingBox fVolume; //! scene volume // Current interaction Double_t fDefXSize, fDefYSize; //! x, y size of scene from camera view - Double_t fZoom; //! current zoom + Double_t fZoom; // current zoom static UInt_t fgZoomDeltaSens; public: + TGLOrthoCamera(); TGLOrthoCamera(EType type, const TGLVector3 & hAxis, const TGLVector3 & vAxis); virtual ~TGLOrthoCamera(); @@ -88,7 +89,10 @@ class TGLOrthoCamera : public TGLCamera void SetDollyToZoom(Bool_t x) { fDollyToZoom = x; } Bool_t GetDollyToZoom() const { return fDollyToZoom; } - ClassDef(TGLOrthoCamera,0) // Camera for orthographic view. + void SetZoom(Double_t x) { fZoom = x; } + Double_t GetZoom() const { return fZoom; } + + ClassDef(TGLOrthoCamera,1) // Camera for orthographic view. }; #endif // ROOT_TGLOrthoCamera diff --git a/graf3d/gl/inc/TGLPadPainter.h b/graf3d/gl/inc/TGLPadPainter.h index 4b44c347f6bee..2386cbc63bed4 100644 --- a/graf3d/gl/inc/TGLPadPainter.h +++ b/graf3d/gl/inc/TGLPadPainter.h @@ -114,8 +114,10 @@ class TGLPadPainter : public TVirtualPadPainter { void DrawPolyMarker(Int_t n, const Float_t *x, const Float_t *y); void DrawText(Double_t x, Double_t y, const char *text, ETextMode mode); + void DrawText(Double_t, Double_t, const wchar_t *, ETextMode){} void DrawTextNDC(Double_t x, Double_t y, const char *text, ETextMode mode); - + void DrawTextNDC(Double_t, Double_t, const wchar_t *, ETextMode){} + //jpg, png, gif and bmp output. void SaveImage(TVirtualPad *pad, const char *fileName, Int_t type) const; diff --git a/graf3d/gl/inc/TGLPadUtils.h b/graf3d/gl/inc/TGLPadUtils.h index 0c2daa8542289..0a7e7da9390a4 100644 --- a/graf3d/gl/inc/TGLPadUtils.h +++ b/graf3d/gl/inc/TGLPadUtils.h @@ -46,16 +46,16 @@ class PolygonStippleSet { friend class FillAttribSet; private: std::vector<unsigned char> fStipples; - + static const UInt_t fgBitSwap[]; static UInt_t SwapBits(UInt_t bits); - + enum EGeometry { kRowSize = 4,//For gl, stipple is a 32x32 pixel pattern. So, 4 GLubyte objects form a single line of a stipple. kNRows = 32, - kStippleSize = kNRows * kRowSize//4 * 32 == 32 lines. + kStippleSize = kNRows * kRowSize//4 * 32 == 32 lines. }; - + enum EBitMasks { kLow4 = 0xf, kUp4 = 0xf0, @@ -70,6 +70,7 @@ RAII class to enable/disable selected stipple. */ class FillAttribSet { UInt_t fStipple; + Float_t fAlpha; public: FillAttribSet(const PolygonStippleSet & set, Bool_t ignoreStipple); ~FillAttribSet(); @@ -90,6 +91,7 @@ class LineAttribSet { Bool_t fSmooth; UInt_t fStipple; Bool_t fSetWidth; + Float_t fAlpha; public: LineAttribSet(Bool_t smooth, UInt_t stipple, Double_t maxWidth, Bool_t setWidth); ~LineAttribSet(); @@ -110,14 +112,14 @@ class MarkerPainter { //Different TArrMarker styles. mutable TPoint fStar[8]; mutable TPoint fCross[4]; - + mutable std::vector<TPoint> fCircle; - + enum { kSmallCirclePts = 80, kLargeCirclePts = 150 }; - + public: //Each function draw n markers. void DrawDot(UInt_t n, const TPoint *xy)const; @@ -126,10 +128,10 @@ class MarkerPainter { void DrawX(UInt_t n, const TPoint *xy)const; void DrawFullDotSmall(UInt_t n, const TPoint *xy)const; void DrawFullDotMedium(UInt_t n, const TPoint *xy)const; - + void DrawCircle(UInt_t n, const TPoint *xy)const; void DrawFullDotLarge(UInt_t n, const TPoint *xy)const; - + void DrawFullSquare(UInt_t n, const TPoint *xy)const; void DrawFullTrianlgeUp(UInt_t n, const TPoint *xy)const; void DrawFullTrianlgeDown(UInt_t n, const TPoint *xy)const; @@ -163,7 +165,7 @@ class Tesselator { Tesselator(Bool_t dump = kFALSE); ~Tesselator(); - + void *GetTess()const { return fTess; @@ -194,7 +196,7 @@ class OffScreenDevice { friend class ::TGLPadPainter; public: OffScreenDevice(UInt_t w, UInt_t h, UInt_t x, UInt_t y, Bool_t top); - + private: UInt_t fW; UInt_t fH; diff --git a/graf3d/gl/inc/TGLPerspectiveCamera.h b/graf3d/gl/inc/TGLPerspectiveCamera.h index b7c5f3a1c6c36..aa0578725ac46 100644 --- a/graf3d/gl/inc/TGLPerspectiveCamera.h +++ b/graf3d/gl/inc/TGLPerspectiveCamera.h @@ -20,23 +20,19 @@ // // // Perspective projection camera - with characteristic foreshortening. // // // -// TODO: Currently constrains YOZ plane to be floor - this is never // -// 'tipped'. While useful we really need to extend so can: // -// i) Pick any one of the three natural planes of the world to be floor.// -// ii) Can use a free arcball style camera with no contraint - integrate// -// TArcBall. // ////////////////////////////////////////////////////////////////////////// class TGLPerspectiveCamera : public TGLCamera { private: // Fields - Double_t fFOV; //! + Double_t fFOV; static Double_t fgFOVMin, fgFOVDefault, fgFOVMax; static UInt_t fgFOVDeltaSens; public: + TGLPerspectiveCamera(); TGLPerspectiveCamera(const TGLVector3 & hAxis, const TGLVector3 & vAxis); virtual ~TGLPerspectiveCamera(); @@ -55,7 +51,7 @@ class TGLPerspectiveCamera : public TGLCamera virtual void Configure(Double_t fov, Double_t dolly, Double_t center[3], Double_t hRotate, Double_t vRotate); - ClassDef(TGLPerspectiveCamera,0) // Camera for perspective view. + ClassDef(TGLPerspectiveCamera,1) // Camera for perspective view. }; #endif // ROOT_TGLPerspectiveCamera diff --git a/graf3d/gl/inc/TGLPhysicalShape.h b/graf3d/gl/inc/TGLPhysicalShape.h index 856f9b2487406..b69ec12782282 100644 --- a/graf3d/gl/inc/TGLPhysicalShape.h +++ b/graf3d/gl/inc/TGLPhysicalShape.h @@ -64,10 +64,11 @@ class TGLPhysicalShape TGLMatrix fTransform; //! transform (placement) of physical instance TGLBoundingBox fBoundingBox; //! bounding box of the physical (transformed) Float_t fColor[17]; //! GL color array + EManip fManip; //! permitted manipulation bitflags - see EManip UChar_t fSelected; //! selected state Bool_t fInvertedWind; //! face winding TODO: can get directly from fTransform? Bool_t fModified; //! has been modified - retain across scene rebuilds - EManip fManip; //! permitted manipulation bitflags - see EManip + Bool_t fIsScaleForRnr;//! cache // Methods void UpdateBoundingBox(); diff --git a/graf3d/gl/inc/TGLRnrCtx.h b/graf3d/gl/inc/TGLRnrCtx.h index 344200d6d9822..3dca5f8d07515 100644 --- a/graf3d/gl/inc/TGLRnrCtx.h +++ b/graf3d/gl/inc/TGLRnrCtx.h @@ -14,6 +14,7 @@ #include "Rtypes.h" #include "TGLStopwatch.h" +#include <list> class TGLViewerBase; class TGLCamera; @@ -31,11 +32,6 @@ class TGLRect; class GLUquadric; -namespace std -{ - template<typename _Tp> class allocator; - template<typename _Tp, typename _Alc> class list; -} /**************************************************************************/ // TGLRnrCtx @@ -92,7 +88,7 @@ class TGLRnrCtx TGLRnrCtx(const TGLRnrCtx&); // Not implemented TGLRnrCtx& operator=(const TGLRnrCtx&); // Not implemented - typedef std::list<TGLColorSet*, std::allocator<TGLColorSet*> > lpTGLColorSet_t; + typedef std::list<TGLColorSet*> lpTGLColorSet_t; protected: TGLViewerBase *fViewer; @@ -264,7 +260,7 @@ class TGLRnrCtx void RegisterFontNoScale(Int_t size, const char* name, Int_t mode, TGLFont& out); void ReleaseFont(TGLFont& font); - GLUquadric* GetGluQuadric() { return fQuadric; } + GLUquadric* GetGluQuadric(); // Picture grabbing void SetGrabImage(Bool_t gi) { fGrabImage = gi; } diff --git a/graf3d/gl/inc/TGLUtil.h b/graf3d/gl/inc/TGLUtil.h index f8a925aebb2ba..5b2000e1033fd 100644 --- a/graf3d/gl/inc/TGLUtil.h +++ b/graf3d/gl/inc/TGLUtil.h @@ -19,6 +19,10 @@ #include "TError.h" #endif +#include <vector> +#include <cmath> +#include <cassert> + class TString; class TGLBoundingBox; class TGLCamera; @@ -28,48 +32,26 @@ class TAttLine; class GLUtesselator; -#include <vector> -#include <cmath> -#include <cassert> - -// TODO:Find a better place for these enums - TGLEnum.h? -// Whole GL viewer should be moved into own namespace -// probably -enum EPosition -{ - kInFront = 0, - kBehind -}; - -enum EOverlap +namespace Rgl { - kInside = 0, - kPartial, - kOutside -}; - -enum EClipType -{ - kClipNone = 0, - kClipPlane, - kClipBox -}; + enum EOverlap + { + kInside = 0, + kPartial, + kOutside + }; +} -enum EManipType +enum EGLCoordType { - kManipTrans = 0, - kManipScale, - kManipRotate -}; - -enum EGLCoordType { kGLCartesian, kGLPolar, kGLCylindrical, kGLSpherical }; -enum EGLPlotType { +enum EGLPlotType +{ kGLLegoPlot, kGLSurfacePlot, kGLBoxPlot, @@ -149,7 +131,7 @@ class TGLVertex3 void Dump() const; - ClassDef(TGLVertex3,0); // GL 3 component vertex helper/wrapper class + ClassDef(TGLVertex3,1); // GL 3 component vertex helper/wrapper class }; //______________________________________________________________________________ @@ -283,7 +265,7 @@ class TGLVector3 : public TGLVertex3 Double_t Mag() const; void Normalise(); - ClassDef(TGLVector3,0); // GL 3 component vector helper/wrapper class + ClassDef(TGLVector3,1); // GL 3 component vector helper/wrapper class }; // Inline for TGLVertex3 requiring full TGLVector definition @@ -485,7 +467,7 @@ class TGLRect Int_t Longest() const; Double_t Aspect() const; - EOverlap Overlap(const TGLRect & other) const; + Rgl::EOverlap Overlap(const TGLRect & other) const; ClassDef(TGLRect,0); // GL rect helper/wrapper class }; @@ -666,6 +648,7 @@ class TGLMatrix // Accesors TGLVector3 GetTranslation() const; TGLVector3 GetScale() const; + Bool_t IsScalingForRender() const; void SetBaseVec(Int_t b, Double_t x, Double_t y, Double_t z); void SetBaseVec(Int_t b, const TGLVector3& v); @@ -686,7 +669,7 @@ class TGLMatrix void Dump() const; - ClassDef(TGLMatrix,0); // GL matrix helper/wrapper class + ClassDef(TGLMatrix,1); // GL matrix helper/wrapper class }; //______________________________________________________________________________ @@ -943,11 +926,16 @@ class TGLUtil static Float_t fgPointSizeScale; static Float_t fgLineWidthScale; + static Float_t fgScreenScalingFactor; + static Float_t fgPointLineScalingFactor; + static Int_t fgPickingRadius; + TGLUtil(const TGLUtil&); // Not implemented. TGLUtil& operator=(const TGLUtil&); // Not implemented. public: virtual ~TGLUtil() {} + static void InitializeIfNeeded(); // Error checking static Int_t CheckError(const char * loc); @@ -986,6 +974,13 @@ class TGLUtil static void Color3fv(const Float_t* rgb); static void Color4fv(const Float_t* rgba); + // Coordinate conversion and extra scaling (needed for osx retina) + static void PointToViewport(Int_t& x, Int_t& y); + static void PointToViewport(Int_t& x, Int_t& y, Int_t& w, Int_t& h); + static Float_t GetScreenScalingFactor(); + static Float_t GetPointLineScalingFactor(); + static Int_t GetPickingRadius(); + static Float_t GetPointSizeScale(); static void SetPointSizeScale(Float_t scale); static Float_t GetLineWidthScale(); diff --git a/graf3d/gl/inc/TGLViewer.h b/graf3d/gl/inc/TGLViewer.h index ffcff754ef4d4..0e1271c639201 100644 --- a/graf3d/gl/inc/TGLViewer.h +++ b/graf3d/gl/inc/TGLViewer.h @@ -268,6 +268,7 @@ class TGLViewer : public TVirtualViewer3D, Double_t center[3], Double_t hRotate, Double_t vRotate); void SetPerspectiveCamera(ECameraType camera, Double_t fov, Double_t dolly, Double_t center[3], Double_t hRotate, Double_t vRotate); + void ReinitializeCurrentCamera(const TGLVector3& hAxis, const TGLVector3& vAxis, Bool_t redraw=kTRUE); void GetGuideState(Int_t & axesType, Bool_t & axesDepthTest, Bool_t & referenceOn, Double_t* referencePos) const; void SetGuideState(Int_t axesType, Bool_t axesDepthTest, Bool_t referenceOn, const Double_t* referencePos); void SetDrawCameraCenter(Bool_t x); diff --git a/graf3d/gl/inc/TGLWSIncludes.h b/graf3d/gl/inc/TGLWSIncludes.h index 23ee50a432420..5691cc9c03297 100644 --- a/graf3d/gl/inc/TGLWSIncludes.h +++ b/graf3d/gl/inc/TGLWSIncludes.h @@ -14,15 +14,19 @@ #ifndef ROOT_TGLWSIncludes +#include "RConfigure.h" #include "TGLIncludes.h" #if defined(WIN32) # include <GL/wglew.h> #else -# if defined(__APPLE__) +# if defined(__APPLE__) && !defined(R__HAS_COCOA) # define GLEW_APPLE_GLX # endif -# include <GL/glxew.h> +# if !defined(R__HAS_COCOA) +# include <GL/glxew.h> +# endif #endif #endif + diff --git a/graf3d/gl/src/CsgOps.cxx b/graf3d/gl/src/CsgOps.cxx index f1454f8a83144..a7a1c86b4f79d 100644 --- a/graf3d/gl/src/CsgOps.cxx +++ b/graf3d/gl/src/CsgOps.cxx @@ -1892,7 +1892,7 @@ namespace RootCsg { PLIST& polyList = Polys(); UInt_t i; for (i=0;i < polyList.size(); i++) { - TGBinder binder(fMesh,i); + TGBinder binder(*this, i); polyList[i].SetPlane(compute_plane(binder)); } } diff --git a/graf3d/gl/src/TGL5DPainter.cxx b/graf3d/gl/src/TGL5DPainter.cxx index 16ed3873ccbcc..40ce4ab1f94d8 100644 --- a/graf3d/gl/src/TGL5DPainter.cxx +++ b/graf3d/gl/src/TGL5DPainter.cxx @@ -473,7 +473,7 @@ void TGL5DPainter::DrawSubCloud(Double_t v4, Double_t range, Color_t ci)const //Draw cloud for selected iso-surface. const TGLDisableGuard light(GL_LIGHTING); - Float_t rgb[3] = {}; + Float_t rgb[4] = {}; Rgl::Pad::ExtractRGB(ci, rgb); glColor3fv(rgb); diff --git a/graf3d/gl/src/TGLAxisPainter.cxx b/graf3d/gl/src/TGLAxisPainter.cxx index b524885fdc3c7..b4857b127f908 100644 --- a/graf3d/gl/src/TGLAxisPainter.cxx +++ b/graf3d/gl/src/TGLAxisPainter.cxx @@ -568,7 +568,7 @@ void TGLAxisPainterBox::DrawAxis3D(TGLRnrCtx &rnrCtx) glGetDoublev(GL_PROJECTION_MATRIX, pm); glGetIntegerv(GL_VIEWPORT, vp); - // determine bitmap font size from lenght of projected vertical + // determine bitmap font size from length of projected vertical GLdouble dn[3]; GLdouble up[3]; gluProject(fAxisTitlePos[2].X(), fAxisTitlePos[2].Y(), fAxis[2]->GetXmin(), mm.Arr(), pm, vp, &dn[0], &dn[1], &dn[2]); diff --git a/graf3d/gl/src/TGLBoundingBox.cxx b/graf3d/gl/src/TGLBoundingBox.cxx index 301090604d1ee..73436b09a9e3f 100644 --- a/graf3d/gl/src/TGLBoundingBox.cxx +++ b/graf3d/gl/src/TGLBoundingBox.cxx @@ -428,10 +428,12 @@ TGLPlane TGLBoundingBox::GetNearPlane() const } //______________________________________________________________________________ -EOverlap TGLBoundingBox::Overlap(const TGLPlane & plane) const +Rgl::EOverlap TGLBoundingBox::Overlap(const TGLPlane & plane) const { // Find overlap (Inside, Outside, Partial) of plane c.f. bounding box. + using namespace Rgl; + // First : cheap square approxiamtion test. If distance of our // center to plane > our half extent length we are outside plane if (plane.DistanceTo(Center()) + (Extents().Mag()/2.0) < 0.0) { @@ -456,10 +458,12 @@ EOverlap TGLBoundingBox::Overlap(const TGLPlane & plane) const } //______________________________________________________________________________ -EOverlap TGLBoundingBox::Overlap(const TGLBoundingBox & other) const +Rgl::EOverlap TGLBoundingBox::Overlap(const TGLBoundingBox & other) const { // Find overlap (Inside, Outside, Partial) of other bounding box c.f. us. + using namespace Rgl; + // Simplify code with refs const TGLBoundingBox & a = *this; const TGLBoundingBox & b = other; diff --git a/graf3d/gl/src/TGLCamera.cxx b/graf3d/gl/src/TGLCamera.cxx index cc6cfcea510ee..ca059bbd290e7 100644 --- a/graf3d/gl/src/TGLCamera.cxx +++ b/graf3d/gl/src/TGLCamera.cxx @@ -44,6 +44,7 @@ UInt_t TGLCamera::fgDollyDeltaSens = 500; TGLCamera::TGLCamera() : fExternalCenter(kFALSE), fFixDefCenter(kFALSE), + fWasArcBalled(kFALSE), fCenter(&fDefCenter), fNearClip(0), fFarClip(0), fDollyDefault(1.0), fDollyDistance(1.0), @@ -66,6 +67,7 @@ TGLCamera::TGLCamera() : TGLCamera::TGLCamera(const TGLVector3 & hAxis, const TGLVector3 & vAxis) : fExternalCenter(kFALSE), fFixDefCenter(kFALSE), + fWasArcBalled(kFALSE), fCenter(&fDefCenter), fNearClip(0), fFarClip(0), fDollyDefault(1.0), fDollyDistance(1.0), @@ -261,11 +263,12 @@ TGLVertex3 TGLCamera::FrustumCenter() const } //______________________________________________________________________________ -EOverlap TGLCamera::FrustumOverlap(const TGLBoundingBox & box) const +Rgl::EOverlap TGLCamera::FrustumOverlap(const TGLBoundingBox & box) const { // Calcaulte overlap (kInside, kOutside, kPartial) of box with camera // frustum // Camera must have valid frustum cache - call Apply() after last modifcation, before using + if (fCacheDirty) { Error("TGLCamera::FrustumOverlap()", "cache dirty - must call Apply()"); } @@ -277,8 +280,9 @@ EOverlap TGLCamera::FrustumOverlap(const TGLBoundingBox & box) const // TODO: Improve this - have a reliable test (seperating axes). Int_t planesInside = 0; // Assume outside to start - for (Int_t planeIndex = 0; planeIndex < kPlanesPerFrustum; ++planeIndex) { - EOverlap planeOverlap = box.Overlap(fFrustumPlanes[planeIndex]); + for (Int_t planeIndex = 0; planeIndex < kPlanesPerFrustum; ++planeIndex) + { + Rgl::EOverlap planeOverlap = box.Overlap(fFrustumPlanes[planeIndex]); // Special case - any object which comes through the near clipping // plane is completely removed - disabled at present @@ -288,22 +292,22 @@ EOverlap TGLCamera::FrustumOverlap(const TGLBoundingBox & box) const return kOutside; }*/ // Once we find a single plane which shape is outside, we are outside the frustum - if ( planeOverlap == kOutside ) { - return kOutside; - } else if ( planeOverlap == kInside ) { + if (planeOverlap == Rgl::kOutside) { + return Rgl::kOutside; + } else if (planeOverlap == Rgl::kInside) { planesInside++; } } // Completely inside frustum - if ( planesInside == kPlanesPerFrustum ) { - return kInside; + if (planesInside == kPlanesPerFrustum) { + return Rgl::kInside; } else { - return kPartial; + return Rgl::kPartial; } } //______________________________________________________________________________ -EOverlap TGLCamera::ViewportOverlap(const TGLBoundingBox & box) const +Rgl::EOverlap TGLCamera::ViewportOverlap(const TGLBoundingBox & box) const { // Calculate overlap (kInside, kOutside, kPartial) of box projection onto viewport // (as rect) against the viewport rect. @@ -580,23 +584,30 @@ Bool_t TGLCamera::OfInterest(const TGLBoundingBox & box, Bool_t ignoreSize) cons // thus fires an internal rebuild to fill scene properly and // finally setup camera properly. - if (fInterestBox.IsEmpty()) { - if (box.Diagonal() >= fLargestSeen * 0.001) { + if (fInterestBox.IsEmpty()) + { + if (box.Diagonal() >= fLargestSeen * 0.001) + { if (box.Diagonal() > fLargestSeen) { fLargestSeen = box.Diagonal(); } interest = kTRUE; } - } else { + } + else + { // Objects are of interest if the have length ratio c.f. the // current interest box, and they at least partially overlap it. // Some objects have zero volume BBs - e.g. single points - skip // the test for these as there is no way to threshold on 0. - if (box.IsEmpty()) { + if (box.IsEmpty()) + { interest = kTRUE; - } else { + } + else + { if (ignoreSize || box.Diagonal() / fInterestBox.Diagonal() > 0.0001) - interest = fInterestBox.Overlap(box) != kOutside; + interest = fInterestBox.Overlap(box) != Rgl::kOutside; } } @@ -618,7 +629,7 @@ Bool_t TGLCamera::UpdateInterest(Bool_t force) // sizable amount). // // If the interest box is updated we return kTRUE - kFALSE otherwise. - // + Bool_t exposedUpdate = kFALSE; // Construct a new interest box using the current frustum box as a basis @@ -646,12 +657,13 @@ Bool_t TGLCamera::UpdateInterest(Bool_t force) // ii) The current frustum is not inside existing interest // iii) Force case (debugging) if (volRatio > 8.0 || volRatio < 0.125 || fInterestBox.IsEmpty() || - fInterestBox.Overlap(frustumBox) != kInside || force) { + fInterestBox.Overlap(frustumBox) != Rgl::kInside || force) + { fPreviousInterestBox = fInterestBox; fInterestBox = newInterestBox; // Frustum should be fully contained now - if (fInterestBox.Overlap(frustumBox) != kInside) { + if (fInterestBox.Overlap(frustumBox) != Rgl::kInside) { Error("TGLCamera::UpdateInterest", "update interest box does not contain frustum"); } @@ -901,24 +913,41 @@ Bool_t TGLCamera::RotateRad(Double_t hRotate, Double_t vRotate) // Rotate camera around center. using namespace TMath; - if (hRotate != 0.0) + + if (fWasArcBalled) + { + Double_t *M = fCamTrans.Arr(); + Double_t d = M[2]; + if (d > 1) d = 1; + else if (d < -1) d = -1; // Fix numerical errors + + Double_t theta = ASin(d); + Double_t phi = Abs(Cos(theta)) > 8.7e-6 ? ATan2(M[1], M[0]) : ATan2(-M[4], M[5]); + + M[0] = M[5] = M[10] = 1; + M[1] = M[2] = M[4] = M[6] = M[8] = M[9] = 0; + fCamTrans.RotateLF(1, 2, phi); + fCamTrans.RotateLF(1, 3, theta); + } + + if (hRotate != 0.0 || fWasArcBalled) { TGLVector3 fwd = fCamTrans.GetBaseVec(1); TGLVector3 lft = fCamTrans.GetBaseVec(2); TGLVector3 up = fCamTrans.GetBaseVec(3); TGLVector3 pos = fCamTrans.GetTranslation(); - TGLVector3 deltaT = pos - (pos*lft)*lft; - Double_t deltaF = deltaT * fwd; - Double_t deltaU = deltaT * up; + Double_t deltaF = pos * fwd; + Double_t deltaU = pos * up; // up vector lock TGLVector3 zdir = fCamBase.GetBaseVec(3); + fCamBase.RotateIP(fwd); Double_t theta = ACos(fwd*zdir); - if(theta+hRotate < fVAxisMinAngle) + if (theta + hRotate < fVAxisMinAngle) hRotate = fVAxisMinAngle - theta; - else if(theta+hRotate > Pi() - fVAxisMinAngle) + else if (theta + hRotate > Pi() - fVAxisMinAngle) hRotate = Pi() - fVAxisMinAngle - theta; fCamTrans.MoveLF(1, -deltaF); @@ -926,6 +955,8 @@ Bool_t TGLCamera::RotateRad(Double_t hRotate, Double_t vRotate) fCamTrans.RotateLF(3, 1, hRotate); fCamTrans.MoveLF(3, deltaU); fCamTrans.MoveLF(1, deltaF); + + fWasArcBalled = kFALSE; } if (vRotate != 0.0) { @@ -936,6 +967,59 @@ Bool_t TGLCamera::RotateRad(Double_t hRotate, Double_t vRotate) return kTRUE; } +//______________________________________________________________________________ +Bool_t TGLCamera::RotateArcBall(Int_t xDelta, Int_t yDelta, Bool_t mod1, Bool_t mod2) +{ + // Rotate the camera round view volume center established in Setup(). + // Arguments are: + // xDelta - horizontal delta (pixels) + // YDelta - vertical delta (pixels) + + Double_t vRotate = AdjustDelta(xDelta, TMath::TwoPi() / fViewport.Width(), mod1, mod2); + Double_t hRotate = AdjustDelta(yDelta, TMath::Pi() / fViewport.Height(), mod1, mod2); + + return RotateArcBallRad(hRotate, vRotate); +} + +//______________________________________________________________________________ +Bool_t TGLCamera::RotateArcBallRad(Double_t hRotate, Double_t vRotate) +{ + // Rotate camera around center. + + using namespace TMath; + + TGLVector3 fwd = fCamTrans.GetBaseVec(1); + TGLVector3 lft = fCamTrans.GetBaseVec(2); + TGLVector3 up = fCamTrans.GetBaseVec(3); + TGLVector3 pos = fCamTrans.GetTranslation(); + + Double_t deltaF = pos * fwd; + Double_t deltaL = pos * lft; + Double_t deltaU = pos * up; + + fCamTrans.MoveLF(1, -deltaF); + fCamTrans.MoveLF(2, -deltaL); + fCamTrans.MoveLF(3, -deltaU); + + if (hRotate != 0.0) + { + fCamTrans.RotateLF(3, 1, hRotate); + } + if (vRotate != 0.0) + { + fCamTrans.RotateLF(1, 2, -vRotate); + } + + fCamTrans.MoveLF(3, deltaU); + fCamTrans.MoveLF(2, deltaL); + fCamTrans.MoveLF(1, deltaF); + + fWasArcBalled = kTRUE; + + IncTimeStamp(); + return kTRUE; +} + //______________________________________________________________________________ Bool_t TGLCamera::Dolly(Int_t delta, Bool_t mod1, Bool_t mod2) { diff --git a/graf3d/gl/src/TGLClip.cxx b/graf3d/gl/src/TGLClip.cxx index 76002d24c35f2..a508447d945d1 100644 --- a/graf3d/gl/src/TGLClip.cxx +++ b/graf3d/gl/src/TGLClip.cxx @@ -471,7 +471,7 @@ void TGLClipSet::InvalidateCurrentClip() } //______________________________________________________________________________ -void TGLClipSet::GetClipState(EClipType type, Double_t data[6]) const +void TGLClipSet::GetClipState(TGLClip::EType type, Double_t data[6]) const { // Get state of clip object 'type' into data vector: // @@ -481,10 +481,10 @@ void TGLClipSet::GetClipState(EClipType type, Double_t data[6]) const switch (type) { - case kClipNone: + case TGLClip::kClipNone: break; - case kClipPlane: + case TGLClip::kClipPlane: { if (!fClipPlane->IsValid()) fClipPlane->Setup(fLastBBox); @@ -496,7 +496,7 @@ void TGLClipSet::GetClipState(EClipType type, Double_t data[6]) const data[3] = planes[0].D(); break; } - case kClipBox: + case TGLClip::kClipBox: { if (!fClipBox->IsValid()) fClipBox->Setup(fLastBBox); @@ -517,7 +517,7 @@ void TGLClipSet::GetClipState(EClipType type, Double_t data[6]) const } //______________________________________________________________________________ -void TGLClipSet::SetClipState(EClipType type, const Double_t data[6]) +void TGLClipSet::SetClipState(TGLClip::EType type, const Double_t data[6]) { // Set state of clip object 'type' into data vector: // @@ -527,15 +527,15 @@ void TGLClipSet::SetClipState(EClipType type, const Double_t data[6]) // kBoxPlane 6 components - Box Center X/Y/Z - Box Extents X/Y/Z switch (type) { - case kClipNone: { + case TGLClip::kClipNone: { break; } - case kClipPlane: { + case TGLClip::kClipPlane: { TGLPlane newPlane(-data[0], -data[1], -data[2], -data[3]); fClipPlane->Set(newPlane); break; } - case kClipBox: { + case TGLClip::kClipBox: { //TODO: Pull these inside TGLPhysicalShape // Update clip box center const TGLBoundingBox & currentBox = fClipBox->BoundingBox(); @@ -557,41 +557,41 @@ void TGLClipSet::SetClipState(EClipType type, const Double_t data[6]) } //______________________________________________________________________________ -EClipType TGLClipSet::GetClipType() const +TGLClip::EType TGLClipSet::GetClipType() const { // Get current type active in viewer - returns one of kClipNone // kClipPlane or kClipBox. - EClipType type; + TGLClip::EType type; if (fCurrentClip == 0) { - type = kClipNone; + type = TGLClip::kClipNone; } else if (fCurrentClip == fClipPlane) { - type = kClipPlane; + type = TGLClip::kClipPlane; } else if (fCurrentClip == fClipBox) { - type = kClipBox; + type = TGLClip::kClipBox; } else { Error("TGLClipSet::GetClipType" , "Unknown clip type"); - type = kClipNone; + type = TGLClip::kClipNone; } return type; } //______________________________________________________________________________ -void TGLClipSet::SetClipType(EClipType type) +void TGLClipSet::SetClipType(TGLClip::EType type) { // Set current clip active in viewer - 'type' is one of kClipNone // kClipPlane or kClipBox. switch (type) { - case kClipNone: { + case TGLClip::kClipNone: { fCurrentClip = 0; break; } - case kClipPlane: { + case TGLClip::kClipPlane: { fCurrentClip = fClipPlane; break; } - case kClipBox: { + case TGLClip::kClipBox: { fCurrentClip = fClipBox; break; } diff --git a/graf3d/gl/src/TGLClipSetEditor.cxx b/graf3d/gl/src/TGLClipSetEditor.cxx index e3a2fd68e1c0f..4eebdfbb0eec6 100644 --- a/graf3d/gl/src/TGLClipSetEditor.cxx +++ b/graf3d/gl/src/TGLClipSetEditor.cxx @@ -31,7 +31,7 @@ ClassImp(TGLClipSetSubEditor); TGLClipSetSubEditor::TGLClipSetSubEditor(const TGWindow *p) : TGVerticalFrame(p), fM(0), - fCurrentClip(kClipNone), + fCurrentClip(TGLClip::kClipNone), fTypeButtons(0), fPlanePropFrame(0), fPlaneProp(), @@ -124,7 +124,7 @@ void TGLClipSetSubEditor::SetModel(TGLClipSet* m) btn->SetDown(); fTypeButtons->SetButton(fCurrentClip+1); } - Bool_t active = (fCurrentClip != kClipNone); + Bool_t active = (fCurrentClip != TGLClip::kClipNone); fClipInside->SetEnabled(active); fAutoUpdate->SetEnabled(active); fClipEdit ->SetEnabled(active); @@ -135,12 +135,12 @@ void TGLClipSetSubEditor::SetModel(TGLClipSet* m) fClipInside->SetDown(fM->GetCurrentClip()->GetMode() == TGLClip::kInside); fAutoUpdate->SetDown(fM->GetAutoUpdate()); - if (fCurrentClip == kClipPlane) { + if (fCurrentClip == TGLClip::kClipPlane) { HideFrame(fBoxPropFrame); ShowFrame(fPlanePropFrame); for (Int_t i = 0; i < 4; ++i) fPlaneProp[i]->SetNumber(clip[i]); - } else if (fCurrentClip == kClipBox) { + } else if (fCurrentClip == TGLClip::kClipBox) { HideFrame(fPlanePropFrame); ShowFrame(fBoxPropFrame); for (Int_t i = 0; i < 6; ++i) @@ -182,9 +182,9 @@ void TGLClipSetSubEditor::ClipTypeChanged(Int_t id) switch (id) { - case 2: fCurrentClip = kClipPlane; break; - case 3: fCurrentClip = kClipBox; break; - default: fCurrentClip = kClipNone; break; + case 2: fCurrentClip = TGLClip::kClipPlane; break; + case 3: fCurrentClip = TGLClip::kClipBox; break; + default: fCurrentClip = TGLClip::kClipNone; break; } fM->SetClipType(fCurrentClip); SetModel(fM); @@ -200,10 +200,10 @@ void TGLClipSetSubEditor::UpdateViewerClip() Double_t data[6] = {0.}; // Fetch GUI state for clip if 'type' into 'data' vector - if (fCurrentClip == kClipPlane) + if (fCurrentClip == TGLClip::kClipPlane) for (Int_t i = 0; i < 4; ++i) data[i] = fPlaneProp[i]->GetNumber(); - else if (fCurrentClip == kClipBox) + else if (fCurrentClip == TGLClip::kClipBox) for (Int_t i = 0; i < 6; ++i) data[i] = fBoxProp[i]->GetNumber(); @@ -212,7 +212,7 @@ void TGLClipSetSubEditor::UpdateViewerClip() fM->SetClipState(fCurrentClip, data); fM->SetShowManip(fClipEdit->IsDown()); fM->SetShowClip (fClipShow->IsDown()); - if (fCurrentClip != kClipNone) + if (fCurrentClip != TGLClip::kClipNone) fM->GetCurrentClip()->SetMode(fClipInside->IsDown() ? TGLClip::kInside : TGLClip::kOutside); fM->SetAutoUpdate(fAutoUpdate->IsDown()); @@ -224,11 +224,11 @@ void TGLClipSetSubEditor::ResetViewerClip() { // Reset transformation of the current clip. - if (fCurrentClip != kClipNone) { - if (fM->GetClipType() == kClipPlane) { + if (fCurrentClip != TGLClip::kClipNone) { + if (fM->GetClipType() == TGLClip::kClipPlane) { TGLPlane plane(0.0, -1.0, 0.0, 0.0); dynamic_cast<TGLClipPlane*>(fM->GetCurrentClip())->Set(plane); - } else if (fM->GetClipType() == kClipBox) { + } else if (fM->GetClipType() == TGLClip::kClipBox) { fM->GetCurrentClip()->SetTransform(TGLMatrix()); } Changed(); diff --git a/graf3d/gl/src/TGLContext.cxx b/graf3d/gl/src/TGLContext.cxx index 829b4ea6bdd39..ed8ed0906f516 100644 --- a/graf3d/gl/src/TGLContext.cxx +++ b/graf3d/gl/src/TGLContext.cxx @@ -21,6 +21,7 @@ #include "TROOT.h" #include "TGLContextPrivate.h" +#include "RConfigure.h" #include "TGLIncludes.h" #include "TGLContext.h" #include "TGLWidget.h" @@ -224,8 +225,83 @@ void TGLContext::Release() fValid = kFALSE; } +#elif defined(R__HAS_COCOA) + +//______________________________________________________________________________ +void TGLContext::SetContext(TGLWidget *widget, const TGLContext *shareList) +{ + //This function is public only for calls via gROOT and called from ctor. + if (!fFromCtor) { + Error("TGLContext::SetContext", "SetContext must be called only from ctor"); + return; + } + + std::auto_ptr<TGLContextPrivate> safe_ptr(fPimpl = new TGLContextPrivate); + + fPimpl->fGLContext = gVirtualX->CreateOpenGLContext(widget->GetId(), shareList ? shareList->fPimpl->fGLContext : 0); + fPimpl->fWindowID = widget->GetId(); + + fValid = kTRUE; + fDevice->AddContext(this); + TGLContextPrivate::RegisterContext(this); + + safe_ptr.release(); +} + +//______________________________________________________________________________ +Bool_t TGLContext::MakeCurrent() +{ + //If context is valid (TGLPaintDevice, for which context was created still exists), + //make it current. + + if (!fValid) { + Error("TGLContext::MakeCurrent", "This context is invalid."); + return kFALSE; + } + + const Bool_t rez = gVirtualX->MakeOpenGLContextCurrent(fPimpl->fGLContext, fPimpl->fWindowID); + if (rez) { + if (!fgGlewInitDone) + GlewInit(); + fIdentity->DeleteGLResources(); + + } + + return rez; +} + +//______________________________________________________________________________ +Bool_t TGLContext::ClearCurrent() +{ + //Reset current context. + return kFALSE; +} + +//______________________________________________________________________________ +void TGLContext::SwapBuffers() +{ + //If context is valid (TGLPaintDevice, for which context was created still exists), + //swap buffers (in case of P-buffer call glFinish()). + if (!fValid) { + Error("TGLContext::SwapBuffers", "This context is invalid."); + return; + } + + gVirtualX->FlushOpenGLBuffer(fPimpl->fGLContext); +} + +//______________________________________________________________________________ +void TGLContext::Release() +{ + //Make the context invalid and free resources. + + TGLContextPrivate::RemoveContext(this); + gVirtualX->DeleteOpenGLContext(fPimpl->fGLContext); + fValid = kFALSE; +} + //============================================================================== -#else // Non WIN32 +#else // X11 //============================================================================== //______________________________________________________________________________ diff --git a/graf3d/gl/src/TGLContextPrivate.cxx b/graf3d/gl/src/TGLContextPrivate.cxx index 206bacb9b59e1..ea831eb12d951 100644 --- a/graf3d/gl/src/TGLContextPrivate.cxx +++ b/graf3d/gl/src/TGLContextPrivate.cxx @@ -3,6 +3,13 @@ #include "TGLContextPrivate.h" +#ifdef R__HAS_COCOA +#include <cassert> + +#include "TVirtualX.h" +#include "TError.h" +#endif + //______________________________________________________________________________ void TGLContextPrivate::RegisterContext(TGLContext *ctx) { @@ -36,6 +43,23 @@ TGLContext *TGLContextPrivate::GetCurrentContext() return 0; } +#elif defined(R__HAS_COCOA) + +std::map<Handle_t, TGLContext *> TGLContextPrivate::fgContexts; + +//______________________________________________________________________________ +TGLContext *TGLContextPrivate::GetCurrentContext() +{ + const Handle_t ctxID = gVirtualX->GetCurrentOpenGLContext(); + if (ctxID) { + assert(fgContexts.find(ctxID) != fgContexts.end() && "GetCurrentContext, context id is unknown"); + return fgContexts[ctxID]; + } + + //Else part - error message was issued already by TGCocoa. + return 0; +} + #else std::map<GLXContext, TGLContext *> TGLContextPrivate::fgContexts; diff --git a/graf3d/gl/src/TGLEventHandler.cxx b/graf3d/gl/src/TGLEventHandler.cxx index 833b62d502231..0ba41d20743d6 100644 --- a/graf3d/gl/src/TGLEventHandler.cxx +++ b/graf3d/gl/src/TGLEventHandler.cxx @@ -35,6 +35,7 @@ #include "TGLAnnotation.h" #include "TEnv.h" #include "TMath.h" +#include "RConfigure.h" //______________________________________________________________________________ // @@ -71,6 +72,7 @@ TGLEventHandler::TGLEventHandler(TGWindow *w, TObject *obj) : fInPointerGrab (kFALSE), fMouseTimerRunning (kFALSE), fTooltipShown (kFALSE), + fArcBall (kFALSE), fTooltipPixelTolerance (3), fSecSelType(TGLViewer::kOnRequest), fDoInternalSelection(kTRUE), @@ -488,6 +490,13 @@ Bool_t TGLEventHandler::HandleButton(Event_t * event) fActiveButtonID = event->fCode; } +#if defined(R__HAS_COCOA) + // On osx/cocoa use cmd modifier for mouse-2 and cmd-alt for mouse-3. + if (event->fCode == kButton1 && event->fState & kKeyMod2Mask) + { + event->fCode = event->fState & kKeyMod1Mask ? kButton3 : kButton2; + } +#endif // Button DOWN if (event->fType == kButtonPress) @@ -517,9 +526,11 @@ Bool_t TGLEventHandler::HandleButton(Event_t * event) TGLSelectRecord& rec = fGLViewer->GetSelRec(); TObject* obj = rec.GetObject(); TGLRect& vp = fGLViewer->CurrentCamera().RefViewport(); + Int_t x = event->fX, y = event->fY; + TGLUtil::PointToViewport(x, y); new TGLAnnotation(fGLViewer, obj->GetTitle(), - event->fX * 1.0f/vp.Width(), - 1 - event->fY * 1.0f/vp.Height(), v); + x * 1.0f/vp.Width(), + 1 - y * 1.0f/vp.Height(), v); } fGLViewer->RequestDraw(); @@ -531,7 +542,9 @@ Bool_t TGLEventHandler::HandleButton(Event_t * event) if (fGLViewer->fDragAction == TGLViewer::kDragNone && fGLViewer->fCurrentOvlElm) { - if (fGLViewer->fCurrentOvlElm->Handle(*fGLViewer->fRnrCtx, fGLViewer->fOvlSelRec, event)) + Event_t e = *event; + TGLUtil::PointToViewport(e.fX, e.fY); + if (fGLViewer->fCurrentOvlElm->Handle(*fGLViewer->fRnrCtx, fGLViewer->fOvlSelRec, &e)) { handled = kTRUE; fGLViewer->fDragAction = TGLViewer::kDragOverlay; @@ -541,7 +554,7 @@ Bool_t TGLEventHandler::HandleButton(Event_t * event) if ( ! handled) { - switch(event->fCode) + switch (event->fCode) { // LEFT mouse button case kButton1: @@ -598,7 +611,9 @@ Bool_t TGLEventHandler::HandleButton(Event_t * event) } else if (fGLViewer->fDragAction == TGLViewer::kDragOverlay && fGLViewer->fCurrentOvlElm) { - fGLViewer->fCurrentOvlElm->Handle(*fGLViewer->fRnrCtx, fGLViewer->fOvlSelRec, event); + Event_t e = *event; + TGLUtil::PointToViewport(e.fX, e.fY); + fGLViewer->fCurrentOvlElm->Handle(*fGLViewer->fRnrCtx, fGLViewer->fOvlSelRec, &e); fGLViewer->OverlayDragFinished(); if (fGLViewer->RequestOverlaySelect(event->fX, event->fY)) fGLViewer->RequestDraw(); @@ -701,7 +716,9 @@ Bool_t TGLEventHandler::HandleConfigureNotify(Event_t *event) } if (event) { - fGLViewer->SetViewport(event->fX, event->fY, event->fWidth, event->fHeight); + Int_t x = event->fX, y = event->fY, w = event->fWidth, h = event->fHeight; + TGLUtil::PointToViewport(x, y, w, h); + fGLViewer->SetViewport(x, y, w, h); fGLViewer->fRedrawTimer->RequestDraw(10, TGLRnrCtx::kLODMed); } return kTRUE; @@ -758,13 +775,21 @@ Bool_t TGLEventHandler::HandleKey(Event_t *event) keysym = event->fCode; fGLViewer->fRnrCtx->SetEventKeySym(keysym); - Bool_t redraw = kFALSE; - if (fGLViewer->fCurrentOvlElm && - fGLViewer->fCurrentOvlElm->Handle(*fGLViewer->fRnrCtx, fGLViewer->fOvlSelRec, event)) + Bool_t handled = kFALSE; + Bool_t redraw = kFALSE; + + if (fGLViewer->fCurrentOvlElm) { - redraw = kTRUE; + Event_t e = *event; + TGLUtil::PointToViewport(e.fX, e.fY); + if (fGLViewer->fCurrentOvlElm->Handle(*fGLViewer->fRnrCtx, fGLViewer->fOvlSelRec, &e)) + { + handled = kTRUE; + redraw = kTRUE; + } } - else + + if ( ! handled) { const Bool_t mod1 = event->fState & kKeyControlMask; const Bool_t mod2 = event->fState & kKeyShiftMask; @@ -800,6 +825,10 @@ Bool_t TGLEventHandler::HandleKey(Event_t *event) break; // Camera + case kKey_A: + case kKey_a: + fArcBall = ! fArcBall; + break; case kKey_Plus: case kKey_J: case kKey_j: @@ -880,6 +909,7 @@ Bool_t TGLEventHandler::HandleMotion(Event_t * event) Int_t yDelta = TMath::Nint(fMouseDragFactor * ControlValue(event->fY - fLastPos.fY)); Bool_t mod1 = event->fState & kKeyControlMask; Bool_t mod2 = event->fState & kKeyShiftMask; + TGLUtil::PointToViewport(xDelta, yDelta); if (fMouseTimerRunning) StopMouseTimer(); @@ -899,7 +929,11 @@ Bool_t TGLEventHandler::HandleMotion(Event_t * event) } changed = fGLViewer->RequestOverlaySelect(event->fX, event->fY); if (fGLViewer->fCurrentOvlElm) - processed = fGLViewer->fCurrentOvlElm->Handle(*fGLViewer->fRnrCtx, fGLViewer->fOvlSelRec, event); + { + Event_t e = *event; + TGLUtil::PointToViewport(e.fX, e.fY); + processed = fGLViewer->fCurrentOvlElm->Handle(*fGLViewer->fRnrCtx, fGLViewer->fOvlSelRec, &e); + } lod = TGLRnrCtx::kLODHigh; if ( ! processed && ! fMouseTimerRunning) StartMouseTimer(); @@ -918,8 +952,11 @@ Bool_t TGLEventHandler::HandleMotion(Event_t * event) } else if (fGLViewer->fDragAction == TGLViewer::kDragOverlay) { - if (fGLViewer->fCurrentOvlElm) - processed = fGLViewer->fCurrentOvlElm->Handle(*fGLViewer->fRnrCtx, fGLViewer->fOvlSelRec, event); + if (fGLViewer->fCurrentOvlElm) { + Event_t e = *event; + TGLUtil::PointToViewport(e.fX, e.fY); + processed = fGLViewer->fCurrentOvlElm->Handle(*fGLViewer->fRnrCtx, fGLViewer->fOvlSelRec, &e); + } } fLastPos.fX = event->fX; @@ -945,7 +982,9 @@ Bool_t TGLEventHandler::Rotate(Int_t xDelta, Int_t yDelta, Bool_t mod1, Bool_t m { // Method to handle action TGLViewer::kDragCameraRotate. - return fGLViewer->CurrentCamera().Rotate(xDelta, -yDelta, mod1, mod2); + TGLCamera &cam = fGLViewer->CurrentCamera(); + if (fArcBall) return cam.RotateArcBall(xDelta, -yDelta, mod1, mod2); + else return cam.Rotate (xDelta, -yDelta, mod1, mod2); } //______________________________________________________________________________ diff --git a/graf3d/gl/src/TGLFormat.cxx b/graf3d/gl/src/TGLFormat.cxx index c79d0d80f4731..4b3139375ef65 100644 --- a/graf3d/gl/src/TGLFormat.cxx +++ b/graf3d/gl/src/TGLFormat.cxx @@ -20,6 +20,7 @@ #include "TEnv.h" #include "TError.h" #include "TVirtualX.h" +#include "RConfigure.h" //______________________________________________________________________________ // @@ -55,17 +56,17 @@ TGLFormat::TGLFormat() : } //______________________________________________________________________________ -TGLFormat::TGLFormat(EFormatOptions opt) : - fDoubleBuffered(opt & kDoubleBuffer), +TGLFormat::TGLFormat(Rgl::EFormatOptions opt) : + fDoubleBuffered(opt & Rgl::kDoubleBuffer), fStereo(kFALSE), #ifdef WIN32 - fDepthSize(opt & kDepth ? 32 : 0), + fDepthSize(opt & Rgl::kDepth ? 32 : 0), #else - fDepthSize(opt & kDepth ? 16 : 0),//FIXFIX + fDepthSize(opt & Rgl::kDepth ? 16 : 0),//FIXFIX #endif - fAccumSize(opt & kAccum ? 8 : 0), //I've never tested accumulation buffer size. - fStencilSize(opt & kStencil ? 8 : 0), //I've never tested stencil buffer size. - fSamples(opt & kMultiSample ? GetDefaultSamples() : 0) + fAccumSize(opt & Rgl::kAccum ? 8 : 0), //I've never tested accumulation buffer size. + fStencilSize(opt & Rgl::kStencil ? 8 : 0), //I've never tested stencil buffer size. + fSamples(opt & Rgl::kMultiSample ? GetDefaultSamples() : 0) { //Define surface using options. } @@ -241,14 +242,16 @@ void TGLFormat::InitAvailableSamples() std::set<Int_t> ns_set; ns_set.insert(0); - TGLWidget *widget = TGLWidget::CreateDummy(); - widget->MakeCurrent(); - #ifdef WIN32 // Missing implementation. - +#elif defined(R__HAS_COCOA) + ns_set.insert(8); + ns_set.insert(16); #else + TGLWidget *widget = TGLWidget::CreateDummy(); + widget->MakeCurrent(); + if (GLXEW_ARB_multisample) { Display *dpy = (Display*) gVirtualX->GetDisplay(); @@ -267,9 +270,8 @@ void TGLFormat::InitAvailableSamples() XFree(vis); } -#endif - delete widget; +#endif fgAvailableSamples.reserve(ns_set.size()); for (std::set<Int_t>::iterator i = ns_set.begin(); i != ns_set.end(); ++i) diff --git a/graf3d/gl/src/TGLLogicalShape.cxx b/graf3d/gl/src/TGLLogicalShape.cxx index 7fd30198275ff..aabfa764bbb43 100644 --- a/graf3d/gl/src/TGLLogicalShape.cxx +++ b/graf3d/gl/src/TGLLogicalShape.cxx @@ -65,6 +65,8 @@ ClassImp(TGLLogicalShape); +Bool_t TGLLogicalShape::fgIgnoreSizeForCameraInterest = kFALSE; + //______________________________________________________________________________ TGLLogicalShape::TGLLogicalShape() : fRef (0), @@ -455,3 +457,32 @@ void TGLLogicalShape::InvokeContextMenu(TContextMenu& menu, UInt_t x, UInt_t y) menu.Popup(x, y, fExternalObj); } } + +//______________________________________________________________________________ +Bool_t TGLLogicalShape::IgnoreSizeForOfInterest() const +{ + // Return true if size of this shape should be ignored when determining if + // the object should be drawn. In this base-class we simply return state of + // static flag fgIgnoreSizeForCameraInterest. + // + // Several sub-classes override this virtual function. + + return fgIgnoreSizeForCameraInterest; +} + +//______________________________________________________________________________ +Bool_t TGLLogicalShape::GetIgnoreSizeForCameraInterest() +{ + // Get state of static fgIgnoreSizeForCameraInterest flag. + // When this is true all objects, also very small, will be drawn by GL. + + return fgIgnoreSizeForCameraInterest; +} + +//______________________________________________________________________________ +void TGLLogicalShape::SetIgnoreSizeForCameraInterest(Bool_t isfci) +{ + // Set state of static fgIgnoreSizeForCameraInterest flag. + + fgIgnoreSizeForCameraInterest = isfci; +} diff --git a/graf3d/gl/src/TGLOrthoCamera.cxx b/graf3d/gl/src/TGLOrthoCamera.cxx index 58fd4fa75feb2..b85b39bad2c92 100644 --- a/graf3d/gl/src/TGLOrthoCamera.cxx +++ b/graf3d/gl/src/TGLOrthoCamera.cxx @@ -35,6 +35,20 @@ ClassImp(TGLOrthoCamera) UInt_t TGLOrthoCamera::fgZoomDeltaSens = 500; +//______________________________________________________________________________ +TGLOrthoCamera::TGLOrthoCamera() : + TGLCamera(TGLVector3( 0.0, 0.0, 1.0), TGLVector3(0.0, 1.0, 0.0)), + fType(kXOY), + fEnableRotate(kFALSE), fDollyToZoom(kTRUE), + fZoomMin(0.001), fZoomDefault(0.78), fZoomMax(1000.0), + fVolume(TGLVertex3(-100.0, -100.0, -100.0), TGLVertex3(100.0, 100.0, 100.0)), + fZoom(1.0) +{ + // Construct kXOY orthographic camera. + + Setup(TGLBoundingBox(TGLVertex3(-100,-100,-100), TGLVertex3(100,100,100))); +} + //______________________________________________________________________________ TGLOrthoCamera::TGLOrthoCamera(EType type, const TGLVector3 & hAxis, const TGLVector3 & vAxis) : TGLCamera(hAxis, vAxis), @@ -277,7 +291,7 @@ void TGLOrthoCamera::Apply(const TGLBoundingBox & /*box*/, TGLVector3 pos = mx.GetTranslation(); TGLVector3 fwd = mx.GetBaseVec(1); TGLVector3 center = pos - fwd; - TGLVector3 up = fCamBase.GetBaseVec(3); + TGLVector3 up = mx.GetBaseVec(3); gluLookAt(pos[0], pos[1], pos[2], center[0], center[1], center[2], diff --git a/graf3d/gl/src/TGLPadPainter.cxx b/graf3d/gl/src/TGLPadPainter.cxx index 7033c8cb9abc6..5540f30b5621b 100644 --- a/graf3d/gl/src/TGLPadPainter.cxx +++ b/graf3d/gl/src/TGLPadPainter.cxx @@ -614,7 +614,7 @@ void TGLPadPainter::DrawPolyMarker() // glMatrixMode(GL_MODELVIEW); // - Float_t rgba[3] = {}; + Float_t rgba[4] = {}; Rgl::Pad::ExtractRGB(gVirtualX->GetMarkerColor(), rgba); glColor3fv(rgba); @@ -701,7 +701,7 @@ void TGLPadPainter::DrawText(Double_t x, Double_t y, const char *text, ETextMode // glMatrixMode(GL_MODELVIEW); - Float_t rgba[3] = {}; + Float_t rgba[4] = {}; Rgl::Pad::ExtractRGB(gVirtualX->GetTextColor(), rgba); glColor3fv(rgba); diff --git a/graf3d/gl/src/TGLPadUtils.cxx b/graf3d/gl/src/TGLPadUtils.cxx index 64fe1d1780529..83634dd0e7792 100644 --- a/graf3d/gl/src/TGLPadUtils.cxx +++ b/graf3d/gl/src/TGLPadUtils.cxx @@ -50,46 +50,46 @@ PolygonStippleSet::PolygonStippleSet() I have to assume, that gStipple has two chars in a line. There in no way to calculate line length and there are no corresponding constants in RStipple.h. So, these numbers are hardcode here. - Ordering in RStipples completely different from OpenGL. + Ordering in RStipples completely different from OpenGL. In OpenGL, if I have, say, 16x2 pattern, GLbytes will be: - + [3][4] [1][2] - + and bits inside them - + [7 6 5 4 3 2 1 0][7 6 5 4 3 2 1 0] [7 6 5 4 3 2 1 0][7 6 5 4 3 2 1 0]. - + But for X11 this will be: - + [2][1] [4][3] - + [0 1 2 3 4 5 6 7][0 1 2 3 4 5 6 7] [0 1 2 3 4 5 6 7][0 1 2 3 4 5 6 7] - - So, line 0x7, 0xE from X11 must be + + So, line 0x7, 0xE from X11 must be converted into 0x70, 0xE0 for OpenGL. - + As OpenGL expects 32x32 pattern, I have to twice each line. */ - - /*If somebody will seriously change gStipples declaration, + + /*If somebody will seriously change gStipples declaration, so, that sizeof gStipples becomes "wrong", change this!*/ const UInt_t numOfStipples = sizeof gStipples / sizeof gStipples[0]; fStipples.resize(kStippleSize * numOfStipples); for (UInt_t i = 0; i < numOfStipples; ++i) { const UInt_t baseInd = i * kStippleSize; - + for (Int_t j = 15, j1 = 0; j >= 0; --j, ++j1) {//ROOT uses 16x16 stipples. const UInt_t rowShift = j1 * kRowSize; - + for (Int_t k = 1, k1 = 0; k >= 0; --k, ++k1) {//Two chars form a line. const UChar_t pixel = SwapBits(gStipples[i][j * 2 + k]); const UInt_t ind = baseInd + rowShift + k1; - + fStipples[ind] = pixel; fStipples[ind + 2] = pixel; fStipples[ind + 64] = pixel; @@ -103,10 +103,10 @@ PolygonStippleSet::PolygonStippleSet() UInt_t PolygonStippleSet::SwapBits(UInt_t b) { b &= k16Bits; - + const UInt_t low = fgBitSwap[b & kLow4] << 4; const UInt_t up = fgBitSwap[(b & kUp4) >> 4]; - + return low | up; } @@ -115,11 +115,11 @@ Class to manipulate fill parameters. */ //______________________________________________________________________________ FillAttribSet::FillAttribSet(const PolygonStippleSet &set, Bool_t ignoreStipple) - : fStipple(0) + : fStipple(0), fAlpha(1.) { //Polygon stipple, if required. const UInt_t style = gVirtualX->GetFillStyle() / 1000; - + if (!ignoreStipple) { if (style == 3) { const UInt_t fasi = gVirtualX->GetFillStyle() % 1000; @@ -128,10 +128,15 @@ FillAttribSet::FillAttribSet(const PolygonStippleSet &set, Bool_t ignoreStipple) glEnable(GL_POLYGON_STIPPLE); } } - - //Color. + + // Color and transparency Float_t rgba[] = {0.f, 0.f, 0.f, 1.f}; ExtractRGB(gVirtualX->GetFillColor(), rgba); + fAlpha = rgba[3]; + if (fAlpha<1.) { + glEnable(GL_BLEND); + glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); + } glColor4fv(rgba); } @@ -140,14 +145,17 @@ FillAttribSet::~FillAttribSet() { if (fStipple) glDisable(GL_POLYGON_STIPPLE); + + if (fAlpha<1.) + glDisable(GL_BLEND); } /* "ROOT like" line stipples. */ -const UShort_t gLineStipples[] = {0xffff, 0xffff, 0x3333, 0x5555, - 0xf040, 0xf4f4, 0xf111, 0xf0f0, +const UShort_t gLineStipples[] = {0xffff, 0xffff, 0x3333, 0x5555, + 0xf040, 0xf4f4, 0xf111, 0xf0f0, 0xff11, 0x3fff, 0x08ff}; const UInt_t gMaxStipple = sizeof gLineStipples / sizeof gLineStipples[0]; @@ -157,7 +165,7 @@ Set/unset line attributes. */ //______________________________________________________________________________ LineAttribSet::LineAttribSet(Bool_t smooth, UInt_t stipple, Double_t maxWidth, Bool_t setWidth) - : fSmooth(smooth), fStipple(stipple), fSetWidth(setWidth) + : fSmooth(smooth), fStipple(stipple), fSetWidth(setWidth), fAlpha(0.8) { //Set up line parameters. //Smooth. @@ -167,7 +175,7 @@ LineAttribSet::LineAttribSet(Bool_t smooth, UInt_t stipple, Double_t maxWidth, B glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); glHint(GL_LINE_SMOOTH_HINT, GL_NICEST); } - + //Stipple. if (fStipple > 1) { if (fStipple >= gMaxStipple) @@ -177,11 +185,17 @@ LineAttribSet::LineAttribSet(Bool_t smooth, UInt_t stipple, Double_t maxWidth, B glLineStipple(fStipple == 10 ? 2 : 1, gLineStipples[fStipple]); } } - - //Color. + + //Color and transparency Float_t rgba[] = {0.f, 0.f, 0.f, 0.8f}; ExtractRGB(gVirtualX->GetLineColor(), rgba); + fAlpha = rgba[3]; + if (fAlpha<0.8) { + glEnable(GL_BLEND); + glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); + } glColor4fv(rgba); + //Width. if (fSetWidth) { const Width_t w = gVirtualX->GetLineWidth(); @@ -192,14 +206,14 @@ LineAttribSet::LineAttribSet(Bool_t smooth, UInt_t stipple, Double_t maxWidth, B //______________________________________________________________________________ LineAttribSet::~LineAttribSet() { - if (fSmooth) { + if (fSmooth || fAlpha<0.8) { glDisable(GL_LINE_SMOOTH); glDisable(GL_BLEND); } - + if (fStipple > 1) glDisable(GL_LINE_STIPPLE); - + if (fSetWidth) glLineWidth(1.f); } @@ -212,7 +226,7 @@ void MarkerPainter::DrawDot(UInt_t n, const TPoint *xy)const { //Simple 1-pixel dots. glBegin(GL_POINTS); - + for (UInt_t i = 0; i < n; ++i) glVertex2d(xy[i].fX, xy[i].fY); @@ -225,7 +239,7 @@ void MarkerPainter::DrawPlus(UInt_t n, const TPoint *xy)const //+ sign. 1 pixel width lines. const Double_t im = 4 * gVirtualX->GetMarkerSize() + 0.5; glBegin(GL_LINES); - + for (UInt_t i = 0; i < n; ++i) { const Double_t x = xy[i].fX; const Double_t y = xy[i].fY; @@ -234,7 +248,7 @@ void MarkerPainter::DrawPlus(UInt_t n, const TPoint *xy)const glVertex2d(x, -im + y); glVertex2d(x, im + y); } - + glEnd(); } @@ -252,13 +266,13 @@ void MarkerPainter::DrawStar(UInt_t n, const TPoint *xy)const fStar[5].fX = im; fStar[5].fY = im; fStar[6].fX = -im; fStar[6].fY = im; fStar[7].fX = im; fStar[7].fY = -im; - + glBegin(GL_LINES); - + for (UInt_t i = 0; i < n; ++i) { const Double_t x = xy[i].fX; const Double_t y = xy[i].fY; - + glVertex2d(fStar[0].fX + x, fStar[0].fY + y); glVertex2d(fStar[1].fX + x, fStar[1].fY + y); glVertex2d(fStar[2].fX + x, fStar[2].fY + y); @@ -268,7 +282,7 @@ void MarkerPainter::DrawStar(UInt_t n, const TPoint *xy)const glVertex2d(fStar[6].fX + x, fStar[6].fY + y); glVertex2d(fStar[7].fX + x, fStar[7].fY + y); } - + glEnd(); } @@ -278,17 +292,17 @@ void MarkerPainter::DrawX(UInt_t n, const TPoint *xy)const const Double_t im = 0.707 * (4 * gVirtualX->GetMarkerSize() + 0.5) + 0.5; glBegin(GL_LINES); - + for (UInt_t i = 0; i < n; ++i) { const Double_t x = xy[i].fX; const Double_t y = xy[i].fY; - + glVertex2d(-im + x, -im + y); glVertex2d(im + x, im + y); glVertex2d(-im + x, im + y); glVertex2d(im + x, -im + y); } - + glEnd(); } @@ -296,17 +310,17 @@ void MarkerPainter::DrawX(UInt_t n, const TPoint *xy)const void MarkerPainter::DrawFullDotSmall(UInt_t n, const TPoint *xy)const { glBegin(GL_LINES); - + for (UInt_t i = 0; i < n; ++i) { const Double_t x = xy[i].fX; const Double_t y = xy[i].fY; - + glVertex2d(-1. + x, y); glVertex2d(x + 1., y); glVertex2d(x, -1. + y); glVertex2d(x, 1. + y); } - + glEnd(); } @@ -328,14 +342,14 @@ void MarkerPainter::DrawCircle(UInt_t n, const TPoint *xy)const Double_t r = 4 * gVirtualX->GetMarkerSize() + 0.5; if (r > 100.) r = 100.;//as in TGX11. - + fCircle.clear(); CalculateCircle(fCircle, r, r < 100. ? kSmallCirclePts : kLargeCirclePts); - + for (UInt_t i = 0; i < n; ++i) { const Double_t x = xy[i].fX; const Double_t y = xy[i].fY; - + glBegin(GL_LINE_LOOP); for (UInt_t j = 0, e = fCircle.size(); j < e; ++j) glVertex2d(fCircle[j].fX + x, fCircle[j].fY + y); @@ -348,17 +362,17 @@ void MarkerPainter::DrawFullDotLarge(UInt_t n, const TPoint *xy)const { fCircle.clear(); fCircle.push_back(TPoint(0, 0)); - + Double_t r = 4 * gVirtualX->GetMarkerSize() + 0.5; if (r > 100.) r = 100;//as in TGX11. - + CalculateCircle(fCircle, r, r < 100 ? kSmallCirclePts : kLargeCirclePts); - + for (UInt_t i = 0; i < n; ++i) { const Double_t x = xy[i].fX; const Double_t y = xy[i].fY; - + glBegin(GL_TRIANGLE_FAN); for (UInt_t j = 0, e = fCircle.size(); j < e; ++j) glVertex2d(fCircle[j].fX + x, fCircle[j].fY + y); @@ -393,7 +407,7 @@ void MarkerPainter::DrawFullTrianlgeUp(UInt_t n, const TPoint *xy)const void MarkerPainter::DrawFullTrianlgeDown(UInt_t n, const TPoint *xy)const { const Int_t im = Int_t(4 * gVirtualX->GetMarkerSize() + 0.5); - + for (UInt_t i = 0; i < n; ++i) { const Double_t x = xy[i].fX; const Double_t y = xy[i].fY; @@ -410,11 +424,11 @@ void MarkerPainter::DrawDiamond(UInt_t n, const TPoint *xy)const { const Int_t im = Int_t(4 * gVirtualX->GetMarkerSize() + 0.5); const Int_t imx = Int_t(2.66 * gVirtualX->GetMarkerSize() + 0.5); - + for (UInt_t i = 0; i < n; ++i) { const Double_t x = xy[i].fX; const Double_t y = xy[i].fY; - + glBegin(GL_LINE_LOOP); glVertex2d(x - imx, y); glVertex2d(x, y - im); @@ -433,7 +447,7 @@ void MarkerPainter::DrawCross(UInt_t n, const TPoint *xy)const for (UInt_t i = 0; i < n; ++i) { const Double_t x = xy[i].fX; const Double_t y = xy[i].fY; - + glBegin(GL_LINE_LOOP); glVertex2d(x - im, y - imx); glVertex2d(x - imx, y - imx); @@ -460,7 +474,7 @@ void MarkerPainter::DrawFullStar(UInt_t n, const TPoint *xy)const const Int_t im2 = Int_t(2.00 * gVirtualX->GetMarkerSize() + 0.5); const Int_t im3 = Int_t(2.66 * gVirtualX->GetMarkerSize() + 0.5); const Int_t im4 = Int_t(1.33 * gVirtualX->GetMarkerSize() + 0.5); - + for (UInt_t i = 0; i < n; ++i) { const Double_t x = xy[i].fX; const Double_t y = xy[i].fY; @@ -469,35 +483,35 @@ void MarkerPainter::DrawFullStar(UInt_t n, const TPoint *xy)const glVertex2d(x - im, y - im4);//0 glVertex2d(x - im2, y + im1);//1 glVertex2d(x - im4, y - im4);//9 - + glVertex2d(x - im2, y + im1);//1 glVertex2d(x - im3, y + im);//2 glVertex2d(x, y + im2);//3 - + glVertex2d(x, y + im2);//3 glVertex2d(x + im3, y + im);//4 glVertex2d(x + im2, y + im1);//5 - + glVertex2d(x + im2, y + im1);//5 glVertex2d(x + im, y - im4);//6 glVertex2d(x + im4, y - im4);//7 - + glVertex2d(x + im4, y - im4);//7 glVertex2d(x, y - im);//8 glVertex2d(x - im4, y - im4);//9 - + glVertex2d(x - im4, y - im4);//9 glVertex2d(x - im2, y + im1);//1 glVertex2d(x, y + im2);//3 - + glVertex2d(x - im4, y - im4);//9 glVertex2d(x, y + im2);//3 glVertex2d(x + im2, y + im1);//5 - + glVertex2d(x - im4, y - im4);//9 glVertex2d(x + im2, y + im1);//5 glVertex2d(x + im4, y - im4);//7 - + glEnd(); } @@ -512,7 +526,7 @@ void MarkerPainter::DrawOpenStar(UInt_t n, const TPoint *xy)const const Int_t im2 = Int_t(2.00 * gVirtualX->GetMarkerSize() + 0.5); const Int_t im3 = Int_t(2.66 * gVirtualX->GetMarkerSize() + 0.5); const Int_t im4 = Int_t(1.33 * gVirtualX->GetMarkerSize() + 0.5); - + for (UInt_t i = 0; i < n; ++i) { const Double_t x = xy[i].fX; const Double_t y = xy[i].fY; @@ -634,7 +648,7 @@ Double_t GLLimits::GetMaxLineWidth()const glGetDoublev(lineWidthPNAME, lp);//lineWidthPNAME is defined at the top of this file. fMaxLineWidth = lp[1]; } - + return fMaxLineWidth; } @@ -646,7 +660,7 @@ Double_t GLLimits::GetMaxPointSize()const glGetDoublev(pointSizePNAME, lp);//pointSizePNAME is defined at the top of this file. fMaxPointSize = lp[1]; } - + return fMaxLineWidth; } @@ -655,8 +669,10 @@ Double_t GLLimits::GetMaxPointSize()const void ExtractRGB(Color_t colorIndex, Float_t *rgb) { const TColor *color = gROOT->GetColor(colorIndex); - if (color) + if (color) { color->GetRGB(rgb[0], rgb[1], rgb[2]); + rgb[3] = color->GetAlpha(); + } } namespace { @@ -668,12 +684,12 @@ void CalculateCircle(std::vector<TPoint> &circle, Double_t r, UInt_t pts) const UInt_t first = circle.size(); Double_t angle = 0.; circle.resize(circle.size() + pts + 1); - + for (UInt_t i = 0; i < pts; ++i, angle += delta) { circle[first + i].fX = SCoord_t(r * TMath::Cos(angle)); circle[first + i].fY = SCoord_t(r * TMath::Sin(angle)); } - + circle.back().fX = circle[first].fX; circle.back().fY = circle[first].fY; } diff --git a/graf3d/gl/src/TGLPerspectiveCamera.cxx b/graf3d/gl/src/TGLPerspectiveCamera.cxx index fbcf7329ab7e9..15cf73d4722d0 100644 --- a/graf3d/gl/src/TGLPerspectiveCamera.cxx +++ b/graf3d/gl/src/TGLPerspectiveCamera.cxx @@ -22,11 +22,6 @@ // // // Perspective projection camera - with characteristic foreshortening. // // // -// TODO: Currently constrains YOZ plane to be floor - this is never // -// 'tipped'. While useful we really need to extend so can: // -// i) Pick any one of the three natural planes of the world to be floor.// -// ii) Can use a free arcball style camera with no contraint - integrate// -// TArcBall. // ////////////////////////////////////////////////////////////////////////// ClassImp(TGLPerspectiveCamera) @@ -36,6 +31,16 @@ Double_t TGLPerspectiveCamera::fgFOVDefault = 30; Double_t TGLPerspectiveCamera::fgFOVMax = 120.0; UInt_t TGLPerspectiveCamera::fgFOVDeltaSens = 500; +//______________________________________________________________________________ +TGLPerspectiveCamera::TGLPerspectiveCamera() : + TGLCamera(TGLVector3(-1.0, 0.0, 0.0), TGLVector3(0.0, 1.0, 0.0)), + fFOV(fgFOVDefault) +{ + // Construct default XOZ perspective camera + Setup(TGLBoundingBox(TGLVertex3(-100,-100,-100), TGLVertex3(100,100,100))); + fCamTrans.MoveLF(1, fDollyDefault); +} + //______________________________________________________________________________ TGLPerspectiveCamera::TGLPerspectiveCamera(const TGLVector3 & hAxes, const TGLVector3 & vAxes) : TGLCamera(hAxes, vAxes), @@ -191,7 +196,7 @@ void TGLPerspectiveCamera::Apply(const TGLBoundingBox & sceneBox, TGLVector3 pos = mx.GetTranslation(); TGLVector3 fwd = mx.GetBaseVec(1); TGLVector3 center = pos - fwd; - TGLVector3 up = fCamBase.GetBaseVec(3); + TGLVector3 up = mx.GetBaseVec(3); gluLookAt(pos[0], pos[1], pos[2], center[0], center[1], center[2], diff --git a/graf3d/gl/src/TGLPhysicalShape.cxx b/graf3d/gl/src/TGLPhysicalShape.cxx index 214084550cb78..e2c4f8e0218b6 100644 --- a/graf3d/gl/src/TGLPhysicalShape.cxx +++ b/graf3d/gl/src/TGLPhysicalShape.cxx @@ -68,10 +68,11 @@ TGLPhysicalShape::TGLPhysicalShape(UInt_t id, const TGLLogicalShape & logicalSha fFirstPSRef (0), fID (id), fTransform (transform), + fManip (kManipAll), fSelected (0), fInvertedWind (invertedWind), fModified (kFALSE), - fManip (kManipAll) + fIsScaleForRnr(kFALSE) { // Construct a physical shape using arguments: // ID - unique drawable id. @@ -96,10 +97,11 @@ TGLPhysicalShape::TGLPhysicalShape(UInt_t id, const TGLLogicalShape & logicalSha fFirstPSRef (0), fID (id), fTransform (transform), + fManip (kManipAll), fSelected (0), fInvertedWind (invertedWind), fModified (kFALSE), - fManip (kManipAll) + fIsScaleForRnr(kFALSE) { // Construct a physical shape using arguments: // id - unique drawable id. @@ -197,6 +199,8 @@ void TGLPhysicalShape::UpdateBoundingBox() fBoundingBox.Set(fLogicalShape->BoundingBox()); fBoundingBox.Transform(fTransform); + fIsScaleForRnr = fTransform.IsScalingForRender(); + if (fLogicalShape->GetScene()) fLogicalShape->GetScene()->InvalidateBoundingBox(); } @@ -364,7 +368,8 @@ void TGLPhysicalShape::Draw(TGLRnrCtx & rnrCtx) const glPushMatrix(); glMultMatrixd(fTransform.CArr()); - if (fInvertedWind) glFrontFace(GL_CW); + if (fIsScaleForRnr) glEnable(GL_NORMALIZE); + if (fInvertedWind) glFrontFace(GL_CW); if (rnrCtx.Highlight()) { glPushAttrib(GL_LIGHTING_BIT | GL_DEPTH_BUFFER_BIT); @@ -374,13 +379,18 @@ void TGLPhysicalShape::Draw(TGLRnrCtx & rnrCtx) const if (rnrCtx.HighlightOutline()) { - const Int_t offsets[12][2] = { {-1,-1}, { 1,-1}, { 1, 1}, {-1, 1}, - { 1, 0}, { 0, 1}, {-1, 0}, { 0,-1}, - { 0,-2}, { 2, 0}, { 0, 2}, {-2, 0} }; + static const Int_t offsets[20][2] = + { {-1,-1}, { 1,-1}, { 1, 1}, {-1, 1}, + { 1, 0}, { 0, 1}, {-1, 0}, { 0,-1}, + { 0,-2}, { 2, 0}, { 0, 2}, {-2, 0}, + {-2,-2}, { 2,-2}, { 2, 2}, {-2, 2}, + { 0,-3}, { 3, 0}, { 0, 3}, {-3, 0} }; + static const Int_t max_off = + TGLUtil::GetScreenScalingFactor() > 1.5 ? 20 : 12; const TGLRect& vp = rnrCtx.RefCamera().RefViewport(); - for (int i = 0; i < 12; ++i) + for (int i = 0; i < max_off; ++i) { glViewport(vp.X() + offsets[i][0], vp.Y() + offsets[i][1], vp.Width(), vp.Height()); fLogicalShape->DrawHighlight(rnrCtx, this); @@ -404,7 +414,8 @@ void TGLPhysicalShape::Draw(TGLRnrCtx & rnrCtx) const if (rnrCtx.IsDrawPassOutlineLine()) TGLUtil::UnlockColor(); } - if (fInvertedWind) glFrontFace(GL_CCW); + if (fInvertedWind) glFrontFace(GL_CCW); + if (fIsScaleForRnr) glDisable(GL_NORMALIZE); glPopMatrix(); } diff --git a/graf3d/gl/src/TGLRnrCtx.cxx b/graf3d/gl/src/TGLRnrCtx.cxx index 45e66ab8d0402..d88c471b94e1f 100644 --- a/graf3d/gl/src/TGLRnrCtx.cxx +++ b/graf3d/gl/src/TGLRnrCtx.cxx @@ -108,10 +108,6 @@ TGLRnrCtx::TGLRnrCtx(TGLViewerBase* viewer) : fColorSetStack->push_back(0); fSelectBuffer = new TGLSelectBuffer; - fQuadric = gluNewQuadric(); - gluQuadricOrientation(fQuadric, (GLenum)GLU_OUTSIDE); - gluQuadricNormals (fQuadric, (GLenum)GLU_SMOOTH); - if (fViewer == 0) { // Assume external usage, initialize for highest quality. @@ -353,7 +349,6 @@ void TGLRnrCtx::CloseDLCapture() fDLCaptureOpen = kFALSE; } - /******************************************************************************/ // TGLFont interface /******************************************************************************/ @@ -399,6 +394,26 @@ void TGLRnrCtx::RegisterFont(Int_t size, const char* name, Int_t mode, TGLFont& RegisterFontNoScale(TMath::Nint(size*fRenderScale), name, mode, out); } +/******************************************************************************/ +// fQuadric's initialization. +/******************************************************************************/ + +//______________________________________________________________________ +GLUquadric *TGLRnrCtx::GetGluQuadric() +{ + // Initialize fQuadric. + + if (!fQuadric) { + if ((fQuadric = gluNewQuadric())) { + gluQuadricOrientation(fQuadric, (GLenum)GLU_OUTSIDE); + gluQuadricNormals(fQuadric, (GLenum)GLU_SMOOTH); + } else + Error("TGLRnrCtx::GetGluQuadric", "gluNewQuadric failed"); + } + + return fQuadric; +} + /******************************************************************************/ // Matrix manipulation helpers diff --git a/graf3d/gl/src/TGLSAViewer.cxx b/graf3d/gl/src/TGLSAViewer.cxx index 443f2967740b7..df11587087cef 100644 --- a/graf3d/gl/src/TGLSAViewer.cxx +++ b/graf3d/gl/src/TGLSAViewer.cxx @@ -63,6 +63,7 @@ DIRECT SCENE INTERACTIONS\n\n\ \tt --- outline mode\n\ \tj --- ZOOM in\n\ \tk --- ZOOM out\n\ + \ta --- switch on/off arc-ball camera rotation control\n\ \tArrow Keys --- PAN (TRUCK) across scene\n\ \tHome --- reset current camera\n\ \tCtrl-Home --- switch external/automatic camera center\n\ diff --git a/graf3d/gl/src/TGLScene.cxx b/graf3d/gl/src/TGLScene.cxx index 80e7dd5bb5ecc..aec68cbfd20a7 100644 --- a/graf3d/gl/src/TGLScene.cxx +++ b/graf3d/gl/src/TGLScene.cxx @@ -463,7 +463,7 @@ void TGLScene::UpdateSceneInfo(TGLRnrCtx& rnrCtx) std::vector<TGLPlane>::iterator pi = sinfo->ClipPlanes().begin(); while (pi != sinfo->ClipPlanes().end()) { - if (drawShape->BoundingBox().Overlap(*pi) == kOutside) + if (drawShape->BoundingBox().Overlap(*pi) == Rgl::kOutside) { drawNeeded = kFALSE; break; @@ -478,10 +478,10 @@ void TGLScene::UpdateSceneInfo(TGLRnrCtx& rnrCtx) size_t cnt = 0; while (pi != sinfo->ClipPlanes().end()) { - EOverlap ovlp = drawShape->BoundingBox().Overlap(*pi); - if (ovlp == kOutside) + Rgl::EOverlap ovlp = drawShape->BoundingBox().Overlap(*pi); + if (ovlp == Rgl::kOutside) break; - else if (ovlp == kInside) + else if (ovlp == Rgl::kInside) ++cnt; ++pi; } @@ -496,7 +496,7 @@ void TGLScene::UpdateSceneInfo(TGLRnrCtx& rnrCtx) std::vector<TGLPlane>::iterator pi = sinfo->FrustumPlanes().begin(); while (pi != sinfo->FrustumPlanes().end()) { - if (drawShape->BoundingBox().Overlap(*pi) == kOutside) + if (drawShape->BoundingBox().Overlap(*pi) == Rgl::kOutside) { drawNeeded = kFALSE; break; @@ -1537,7 +1537,7 @@ Bool_t TGLScene::IsOutside(const TGLBoundingBox & box, // Check if box is outside of all planes. for (TGLPlaneSet_ci p=planes.begin(); p!=planes.end(); ++p) - if (box.Overlap(*p) == kOutside) + if (box.Overlap(*p) == Rgl::kOutside) return kTRUE; return kFALSE; } diff --git a/graf3d/gl/src/TGLSceneBase.cxx b/graf3d/gl/src/TGLSceneBase.cxx index a0f345e4baef4..1417ad8af3440 100644 --- a/graf3d/gl/src/TGLSceneBase.cxx +++ b/graf3d/gl/src/TGLSceneBase.cxx @@ -222,12 +222,12 @@ void TGLSceneBase::UpdateSceneInfo(TGLRnrCtx& ctx) // !!! transform plane switch (BoundingBox().Overlap(p)) { - case kInside: // Whole scene passes ... no need to store it. + case Rgl::kInside: // Whole scene passes ... no need to store it. break; - case kPartial: + case Rgl::kPartial: sinfo->FrustumPlanes().push_back(p); break; - case kOutside: + case Rgl::kOutside: sinfo->InFrustum(kFALSE); break; } @@ -251,12 +251,12 @@ void TGLSceneBase::UpdateSceneInfo(TGLRnrCtx& ctx) // !!! transform plane switch (BoundingBox().Overlap(*it)) { - case kInside: // Whole scene passes ... no need to store it. + case Rgl::kInside: // Whole scene passes ... no need to store it. break; - case kPartial: + case Rgl::kPartial: sinfo->ClipPlanes().push_back(*it); break; - case kOutside: // Depends on mode + case Rgl::kOutside: // Depends on mode if (sinfo->ClipMode() == TGLSceneInfo::kClipOutside) { // Scene is outside of whole clip object - nothing visible. diff --git a/graf3d/gl/src/TGLUtil.cxx b/graf3d/gl/src/TGLUtil.cxx index e885a5f927ef0..392460ba73e0e 100644 --- a/graf3d/gl/src/TGLUtil.cxx +++ b/graf3d/gl/src/TGLUtil.cxx @@ -25,6 +25,7 @@ #include "TMath.h" #include "TROOT.h" #include "TClass.h" +#include "TEnv.h" #include "TGLBoundingBox.h" #include "TGLCamera.h" @@ -304,20 +305,27 @@ Int_t TGLRect::Diagonal() const } //______________________________________________________________________________ -EOverlap TGLRect::Overlap(const TGLRect & other) const +Rgl::EOverlap TGLRect::Overlap(const TGLRect & other) const { // Return overlap result (kInside, kOutside, kPartial) of this // rect with 'other' - if ((fX <= other.fX) && (fX + fWidth >= other.fX + other.fWidth) && - (fY <= other.fY) && (fY +fHeight >= other.fY + other.fHeight)) { + + using namespace Rgl; + + if ((fX <= other.fX) && (fX + fWidth >= other.fX + other.fWidth) && + (fY <= other.fY) && (fY + fHeight >= other.fY + other.fHeight)) + { return kInside; } - else if ((fX >= other.fX + static_cast<Int_t>(other.fWidth)) || - (fX + static_cast<Int_t>(fWidth) <= other.fX) || + else if ((fX >= other.fX + static_cast<Int_t>(other.fWidth)) || + (fX + static_cast<Int_t>(fWidth) <= other.fX) || (fY >= other.fY + static_cast<Int_t>(other.fHeight)) || - (fY + static_cast<Int_t>(fHeight) <= other.fY)) { + (fY + static_cast<Int_t>(fHeight) <= other.fY)) + { return kOutside; - } else { + } + else + { return kPartial; } } @@ -1085,6 +1093,21 @@ TGLVector3 TGLMatrix::GetScale() const return TGLVector3(x.Mag(), y.Mag(), z.Mag()); } +//______________________________________________________________________________ +Bool_t TGLMatrix::IsScalingForRender() const +{ + // Return true if matrix is to be considered a scaling matrix + // for rendering. + Double_t ss; + ss = fVals[0]*fVals[0] + fVals[1]*fVals[1] + fVals[2]*fVals[2]; + if (ss < 0.8 || ss > 1.2) return kTRUE; + ss = fVals[4]*fVals[4] + fVals[5]*fVals[5] + fVals[6]*fVals[6]; + if (ss < 0.8 || ss > 1.2) return kTRUE; + ss = fVals[8]*fVals[8] + fVals[9]*fVals[9] + fVals[10]*fVals[10]; + if (ss < 0.8 || ss > 1.2) return kTRUE; + return kFALSE; +} + //______________________________________________________________________________ void TGLMatrix::Dump() const { @@ -1381,6 +1404,10 @@ Float_t TGLUtil::fgLineWidth = 1.0f; Float_t TGLUtil::fgPointSizeScale = 1.0f; Float_t TGLUtil::fgLineWidthScale = 1.0f; +Float_t TGLUtil::fgScreenScalingFactor = 1.0f; +Float_t TGLUtil::fgPointLineScalingFactor = 1.0f; +Int_t TGLUtil::fgPickingRadius = 1; + const UChar_t TGLUtil::fgRed[4] = { 230, 0, 0, 255 }; const UChar_t TGLUtil::fgGreen[4] = { 0, 230, 0, 255 }; const UChar_t TGLUtil::fgBlue[4] = { 0, 0, 230, 255 }; @@ -1479,6 +1506,30 @@ GLUtesselator* TGLUtil::GetDrawTesselator4dv() return singleton.fTess; } +//______________________________________________________________________________ +void TGLUtil::InitializeIfNeeded() +{ + // Initialize globals that require other libraries to be initialized. + // This is called from TGLWidget creation function. + + static Bool_t init_done = kFALSE; + if (init_done) return; + init_done = kTRUE; + + fgScreenScalingFactor = gVirtualX->GetOpenGLScalingFactor(); + + if (strcmp(gEnv->GetValue("OpenGL.PointLineScalingFactor", "native"), "native") == 0) + { + fgPointLineScalingFactor = fgScreenScalingFactor; + } + else + { + fgPointLineScalingFactor = gEnv->GetValue("OpenGL.PointLineScalingFactor", 1.0); + } + + fgPickingRadius = TMath::Nint(gEnv->GetValue("OpenGL.PickingRadius", 3.0) * TMath::Sqrt(fgScreenScalingFactor)); +} + //______________________________________________________________________________ UInt_t TGLUtil::GetDrawQuality() { @@ -1679,6 +1730,66 @@ void TGLUtil::Color4fv(const Float_t* rgba) if (fgColorLockCount == 0) glColor4fv(rgba); } +/******************************************************************************/ +// Coordinate conversion and extra scaling (needed for osx retina) +/******************************************************************************/ + +//______________________________________________________________________________ +void TGLUtil::PointToViewport(Int_t& x, Int_t& y) +{ + // Convert from point/screen coordinates to GL viewport coordinates. + + if (fgScreenScalingFactor != 1.0) + { + x = TMath::Nint(x * fgScreenScalingFactor); + y = TMath::Nint(y * fgScreenScalingFactor); + } +} + +//______________________________________________________________________________ +void TGLUtil::PointToViewport(Int_t& x, Int_t& y, Int_t& w, Int_t& h) +{ + // Convert from point/screen coordinates to GL viewport coordinates. + + if (fgScreenScalingFactor != 1.0) + { + x = TMath::Nint(x * fgScreenScalingFactor); + y = TMath::Nint(y * fgScreenScalingFactor); + w = TMath::Nint(w * fgScreenScalingFactor); + h = TMath::Nint(h * fgScreenScalingFactor); + } +} + +//______________________________________________________________________________ +Float_t TGLUtil::GetScreenScalingFactor() +{ + // Returns scaling factor between screen points and GL viewport pixels. + // This is what is returned by gVirtualX->GetOpenGLScalingFactor() but is + // cached here to avoid a virtual function call as it is used quite often in + // TGLPhysical shape when drawing the selection highlight. + + return fgScreenScalingFactor; +} + +//______________________________________________________________________________ +Float_t TGLUtil::GetPointLineScalingFactor() +{ + // Return extra scaling factor for points and lines. + // By default this is set to the same value as ScreenScalingFactor to keep + // the same appearance. To override use rootrc entry, e.g.: + // OpenGL.PointLineScalingFactor: 1.0 + + return fgPointLineScalingFactor; +} + +//______________________________________________________________________________ +Int_t TGLUtil::GetPickingRadius() +{ + // Returns picking radius. + + return fgPickingRadius; +} + /******************************************************************************/ // Control for scaling of point-size and line-width. /******************************************************************************/ @@ -1721,7 +1832,7 @@ void TGLUtil::PointSize(Float_t point_size) // Set the point-size, taking the global scaling into account. // Wrapper for glPointSize. - fgPointSize = point_size * fgPointSizeScale; + fgPointSize = point_size * fgPointSizeScale * fgPointLineScalingFactor; glPointSize(fgPointSize); } @@ -1731,7 +1842,7 @@ void TGLUtil::LineWidth(Float_t line_width) // Set the line-width, taking the global scaling into account. // Wrapper for glLineWidth. - fgLineWidth = line_width * fgLineWidthScale; + fgLineWidth = line_width * fgLineWidthScale * fgPointLineScalingFactor; glLineWidth(fgLineWidth); } diff --git a/graf3d/gl/src/TGLViewer.cxx b/graf3d/gl/src/TGLViewer.cxx index dab522ced9012..9189ede41e3ff 100644 --- a/graf3d/gl/src/TGLViewer.cxx +++ b/graf3d/gl/src/TGLViewer.cxx @@ -883,7 +883,14 @@ Bool_t TGLViewer::SavePictureUsingFBO(const TString &fileName, Int_t w, Int_t h, catch (std::runtime_error& exc) { Error(eh, "%s",exc.what()); - return kFALSE; + if (gEnv->GetValue("OpenGL.SavePictureFallbackToBB", 1)) { + Info(eh, "Falling back to saving image via back-buffer. Window must be fully visible."); + if (w != fViewport.Width() || h != fViewport.Height()) + Warning(eh, "Back-buffer does not support image scaling, window size will be used."); + return SavePictureUsingBB(fileName); + } else { + return kFALSE; + } } TGLRect old_vp(fViewport); @@ -1157,11 +1164,13 @@ Bool_t TGLViewer::DoSelect(Int_t x, Int_t y) return kFALSE; } + TGLUtil::PointToViewport(x, y); + TUnlocker ulck(this); MakeCurrent(); - fRnrCtx->BeginSelection(x, y, 3); + fRnrCtx->BeginSelection(x, y, TGLUtil::GetPickingRadius()); glRenderMode(GL_SELECT); PreRender(); @@ -1222,6 +1231,8 @@ Bool_t TGLViewer::DoSecondarySelect(Int_t x, Int_t y) return kFALSE; } + TGLUtil::PointToViewport(x, y); + TUnlocker ulck(this); if (! fSelRec.GetSceneInfo() || ! fSelRec.GetPhysShape() || @@ -1244,7 +1255,7 @@ Bool_t TGLViewer::DoSecondarySelect(Int_t x, Int_t y) SceneInfoList_t foo; foo.push_back(sinfo); fScenes.swap(foo); - fRnrCtx->BeginSelection(x, y, 3); + fRnrCtx->BeginSelection(x, y, TGLUtil::GetPickingRadius()); fRnrCtx->SetSecSelection(kTRUE); glRenderMode(GL_SELECT); @@ -1329,11 +1340,13 @@ Bool_t TGLViewer::DoOverlaySelect(Int_t x, Int_t y) return kFALSE; } + TGLUtil::PointToViewport(x, y); + TUnlocker ulck(this); MakeCurrent(); - fRnrCtx->BeginSelection(x, y, 3); + fRnrCtx->BeginSelection(x, y, TGLUtil::GetPickingRadius()); glRenderMode(GL_SELECT); PreRenderOverlaySelection(); @@ -1771,6 +1784,20 @@ void TGLViewer::SetPerspectiveCamera(ECameraType camera, } } +//______________________________________________________________________________ +void TGLViewer::ReinitializeCurrentCamera(const TGLVector3& hAxis, const TGLVector3& vAxis, Bool_t redraw) +{ + // Change base-vectors defining the camera-base transformation of current + // camera. hAxis and vAxis are the default directions for forward + // (inverted) and upwards. + + TGLMatrix& cb = fCurrentCamera->RefCamBase(); + cb.Set(cb.GetTranslation(), vAxis, hAxis); + fCurrentCamera->Setup(fOverallBoundingBox, kTRUE); + if (redraw) + RequestDraw(); +} + //______________________________________________________________________________ TGLAutoRotator* TGLViewer::GetAutoRotator() { diff --git a/graf3d/gl/src/TGLViewerBase.cxx b/graf3d/gl/src/TGLViewerBase.cxx index 98304f1620e93..8368599301c49 100644 --- a/graf3d/gl/src/TGLViewerBase.cxx +++ b/graf3d/gl/src/TGLViewerBase.cxx @@ -26,6 +26,8 @@ #include "TGLContext.h" #include "TGLIncludes.h" +#include "TEnv.h" + #include <algorithm> #include <stdexcept> @@ -62,6 +64,9 @@ TGLViewerBase::TGLViewerBase() : // Constructor. fRnrCtx = new TGLRnrCtx(this); + + fWFLineW = gEnv->GetValue("OpenGL.WireframeLineScalingFactor", 1.0); + fOLLineW = gEnv->GetValue("OpenGL.OutlineLineScalingFactor", 1.0); } //______________________________________________________________________ @@ -368,7 +373,7 @@ void TGLViewerBase::PreRender() { TGLSceneInfo * sinfo = *i; const TGLBoundingBox & bbox = sinfo->GetTransformedBBox(); - Bool_t visp = (!bbox.IsEmpty() && fCamera->FrustumOverlap(bbox) != kOutside); + Bool_t visp = (!bbox.IsEmpty() && fCamera->FrustumOverlap(bbox) != Rgl::kOutside); sinfo->ViewCheck(visp); if (visp) { fRnrCtx->SetSceneInfo(sinfo); diff --git a/graf3d/gl/src/TGLWidget.cxx b/graf3d/gl/src/TGLWidget.cxx index 29030e037aa20..d8b6af0b21e72 100644 --- a/graf3d/gl/src/TGLWidget.cxx +++ b/graf3d/gl/src/TGLWidget.cxx @@ -12,6 +12,7 @@ #include <stdexcept> #include <vector> + #include "TVirtualX.h" #include "TGClient.h" #include "TError.h" @@ -21,8 +22,8 @@ #include "TGLIncludes.h" #include "TGLWSIncludes.h" #include "TGLUtil.h" - #include "TGLEventHandler.h" +#include "RConfigure.h" /******************************************************************************/ // TGLWidget @@ -74,7 +75,7 @@ TGLWidget* TGLWidget::CreateDummy() { // Static constructor for creating widget with default pixel format. - TGLFormat format(TGLFormat::kNone); + TGLFormat format(Rgl::kNone); return Create(format, gClient->GetDefaultRoot(), kFALSE, kFALSE, 0, 1, 1); } @@ -100,6 +101,9 @@ TGLWidget* TGLWidget::Create(const TGLFormat &format, { // Static constructor for creating widget with given pixel format. + // Make sure window-system dependent part of GL-util is initialized. + TGLUtil::InitializeIfNeeded(); + std::pair<void *, void *> innerData; Window_t wid = CreateWindow(parent, format, width, height, innerData); @@ -108,6 +112,8 @@ TGLWidget* TGLWidget::Create(const TGLFormat &format, #ifdef WIN32 glw->fWindowIndex = (Int_t) innerData.second; +#elif defined(R__HAS_COCOA) + glw->fWindowIndex = wid; #else glw->fWindowIndex = gVirtualX->AddWindow(wid, width, height); glw->fInnerData = innerData; @@ -136,7 +142,7 @@ TGLWidget::TGLWidget(Window_t glw, const TGWindow* p, Bool_t selectInput) : TGFrame(gClient, glw, p), fGLContext(0), fWindowIndex(-1), - fGLFormat(TGLFormat::kNone), + fGLFormat(Rgl::kNone), fFromInit(kTRUE), fEventHandler(0) { @@ -159,7 +165,9 @@ TGLWidget::~TGLWidget() //Destructor. Deletes window ???? and XVisualInfo #ifndef WIN32 +#ifndef R__HAS_COCOA XFree(fInnerData.second);//free XVisualInfo +#endif #endif if (fValidContexts.size() > 1u) { Warning("~TGLWidget", "There are some gl-contexts connected to this gl device" @@ -250,6 +258,7 @@ void TGLWidget::RemoveContext(TGLContext *ctx) void TGLWidget::ExtractViewport(Int_t *vp)const { //For camera. + vp[0] = 0; vp[1] = 0; vp[2] = GetWidth(); @@ -377,9 +386,47 @@ void TGLWidget::SetFormat() throw std::runtime_error("ChoosePixelFormat failed"); } } +//============================================================================== +#elif defined(R__HAS_COCOA) //MacOSX with Cocoa enabled. +//============================================================================== + +//______________________________________________________________________________ +Window_t TGLWidget::CreateWindow(const TGWindow* parent, const TGLFormat &format, + UInt_t width, UInt_t height, + std::pair<void *, void *>& /*internalData*/) +{ + // CreateWidget - MacOSX/Cocoa version. + // Static function called prior to construction. + + typedef std::pair<UInt_t, Int_t> component_type; + + std::vector<component_type>formatComponents; + + if (format.HasDepth()) + formatComponents.push_back(component_type(Rgl::kDepth, format.GetDepthSize())); + if (format.HasStencil()) + formatComponents.push_back(component_type(Rgl::kStencil, format.GetStencilSize())); + if (format.HasAccumBuffer()) + formatComponents.push_back(component_type(Rgl::kAccum, format.GetAccumSize())); + if (format.IsDoubleBuffered()) + formatComponents.push_back(component_type(Rgl::kDoubleBuffer, 0)); + if (format.IsStereo()) + formatComponents.push_back(component_type(Rgl::kStereo, 0)); + if (format.HasMultiSampling()) + formatComponents.push_back(component_type(Rgl::kMultiSample, format.GetSamples())); + + return gVirtualX->CreateOpenGLWindow(parent->GetId(), width, height, formatComponents); +} + +//______________________________________________________________________________ +void TGLWidget::SetFormat() +{ + // Set pixel format. + // Empty version for X11. +} //============================================================================== -#else // Non WIN32 +#else // X11 //============================================================================== namespace diff --git a/graf3d/glew/Module.mk b/graf3d/glew/Module.mk index 8d5270cc070b7..fe509b10382bc 100644 --- a/graf3d/glew/Module.mk +++ b/graf3d/glew/Module.mk @@ -28,9 +28,6 @@ ALLLIBS += $(GLEWLIB) # include all dependency files INCLUDEFILES += $(GLEWDEP) -ifeq ($(ARCH),win32) -GLLIBS := opengl32.lib glu32.lib -endif ifeq ($(MACOSX_MINOR),3) GLEWLIBEXTRA += -lz endif @@ -49,7 +46,7 @@ $(GLEWLIB): $(GLEWO) $(FREETYPEDEP) $(ORDER_) $(MAINLIBS) $(GLEWLIBDEP) "$(SOFLAGS)" libGLEW.$(SOEXT) $@ \ "$(GLEWO)" \ "$(FREETYPELDFLAGS) $(FREETYPELIB) \ - $(GLEWLIBEXTRA) $(XLIBS) $(GLLIBS)" + $(GLEWLIBEXTRA) $(GLLIBS)" all-$(MODNAME): $(GLEWLIB) diff --git a/graf3d/glew/src/glew.c b/graf3d/glew/src/glew.c index 627da290cdff0..28aca830a88ae 100644 --- a/graf3d/glew/src/glew.c +++ b/graf3d/glew/src/glew.c @@ -30,10 +30,11 @@ */ /* ROOT additions begin */ +#include "RConfigure.h" #define GLEW_BUILD -#if defined(__APPLE__) +#if defined(__APPLE__) && !defined(R__HAS_COCOA) # define GLEW_APPLE_GLX #endif diff --git a/graf3d/x3d/CMakeLists.txt b/graf3d/x3d/CMakeLists.txt index 432454f90bcfe..cb53e2ccd41f1 100644 --- a/graf3d/x3d/CMakeLists.txt +++ b/graf3d/x3d/CMakeLists.txt @@ -6,6 +6,7 @@ set(libname X3d) ROOT_USE_PACKAGE(graf3d/g3d) ROOT_USE_PACKAGE(gui/gui) +include_directories(${X11_INCLUDE_DIR}) ROOT_GENERATE_DICTIONARY(G__X3D TViewerX3D.h TX3DFrame.h LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(${libname} LINKDEF LinkDef.h DEPENDENCIES Graf3d Gui) diff --git a/gui/fitpanel/inc/TFitEditor.h b/gui/fitpanel/inc/TFitEditor.h index 9dca4f6957e7b..48738a4a65646 100644 --- a/gui/fitpanel/inc/TFitEditor.h +++ b/gui/fitpanel/inc/TFitEditor.h @@ -133,7 +133,7 @@ class TFitEditor : public TGMainFrame { }; std::vector<FuncParamData_t> fFuncPars; // function parameters (value + limits) - std::multimap<TObject*, TF1*> fPrevFit; // Previous succesful fits. + std::multimap<TObject*, TF1*> fPrevFit; // Previous successful fits. std::vector<TF1*> fSystemFuncs; // functions managed by the fitpanel TGRadioButton *fLibMinuit; // set default minimization library (Minuit) diff --git a/gui/fitpanel/src/TFitEditor.cxx b/gui/fitpanel/src/TFitEditor.cxx index b6c3c24de9a66..9fe39065b039f 100644 --- a/gui/fitpanel/src/TFitEditor.cxx +++ b/gui/fitpanel/src/TFitEditor.cxx @@ -439,7 +439,7 @@ TFitEditor::TFitEditor(TVirtualPad* pad, TObject *obj) : TGDimension size = GetDefaultSize(); SetWindowName("Fit Panel"); SetIconName("Fit Panel"); - SetClassHints("Fit Panel", "Fit Panel"); + SetClassHints("ROOT", "Fit Panel"); SetMWMHints(kMWMDecorAll | kMWMDecorResizeH | kMWMDecorMaximize | kMWMDecorMinimize | kMWMDecorMenu, diff --git a/gui/fitpanel/test/UnitTesting.cxx b/gui/fitpanel/test/UnitTesting.cxx index 752e75b0c27f9..10b9a50d83dbe 100644 --- a/gui/fitpanel/test/UnitTesting.cxx +++ b/gui/fitpanel/test/UnitTesting.cxx @@ -170,7 +170,7 @@ class FitEditorUnitTesting // This function compares the parameters stored in the TFitEditor // with the ones passed by the test functions. Normally, if the // function return 0, it means all the parameters are equal up to a - // certain limit, thus the test was succesful. + // certain limit, thus the test was successful. int CompareFuncPars(std::vector<TFitEditor::FuncParamData_t>& pars) { int status = 0; diff --git a/gui/ged/inc/LinkDef.h b/gui/ged/inc/LinkDef.h index bbdf2dd32dd55..b66387df5e680 100644 --- a/gui/ged/inc/LinkDef.h +++ b/gui/ged/inc/LinkDef.h @@ -25,6 +25,7 @@ #pragma link C++ class TAxisEditor; #pragma link C++ class TFrameEditor; #pragma link C++ class TGraphEditor; +#pragma link C++ class TTextEditor; #pragma link C++ class TPieEditor; #pragma link C++ class TPieSliceEditor; #pragma link C++ class TH1Editor; diff --git a/gui/ged/inc/TTextEditor.h b/gui/ged/inc/TTextEditor.h new file mode 100644 index 0000000000000..16e6a869f5c02 --- /dev/null +++ b/gui/ged/inc/TTextEditor.h @@ -0,0 +1,63 @@ +// Author: Olivier Couet 22/12/2013 + +/************************************************************************* + * Copyright (C) 1995-2002, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + + +////////////////////////////////////////////////////////////////////////// +// // +// TTextEditor // +// // +// Editor for changing TText's and TLatex's attributes. // +// // +////////////////////////////////////////////////////////////////////////// + +#ifndef ROOT_TTextEditor +#define ROOT_TTextEditor +#ifndef ROOT_TGedFrame +#include "TGedFrame.h" +#endif + +class TText; +class TGTextEntry; +class TGNumberEntry; + +class TTextEditor : public TGedFrame { + +private: + TText *fEditedText; + +protected: + TGTextEntry *fText; // Text + TGNumberEntry *fAngle; // Text's angle + TGNumberEntry *fSize; // Text's angle + TGNumberEntry *fXpos; // Text's X position + TGNumberEntry *fYpos; // Text's Y position + + void ConnectSignals2Slots(); + +public: + TTextEditor(const TGWindow *p = 0, + Int_t width = 140, Int_t height = 30, + UInt_t options = kChildFrame, + Pixel_t back = GetDefaultFrameBackground()); + ~TTextEditor(); + + void SetModel(TObject *); + + void DoAngle(); + void DoSize(); + void DoText(const char*); + void DoXpos(); + void DoYpos(); + + ClassDef(TTextEditor,0) // text editor +}; + +#endif // ROOT_TTextEditor + diff --git a/gui/ged/src/HelpSMText.cxx b/gui/ged/src/HelpSMText.cxx index ec937e56d61be..f23d86902a7ab 100644 --- a/gui/ged/src/HelpSMText.cxx +++ b/gui/ged/src/HelpSMText.cxx @@ -13,7 +13,7 @@ const char gHelpSMTopLevel[] = "The Style Manager handles a list of styles in the ROOT session. It loads\n" -"by default the five styles provided by ROOT: Deafult, Plain, Bold, Video,\n" +"by default the five styles provided by ROOT: Default, Plain, Bold, Video,\n" "and Pub. If this list does not contain a style with the characteristics\n" "you want, you can create a new one and than apply it.\n" "\n" @@ -254,7 +254,7 @@ const char gHelpSMAxis[] = ; const char gHelpSMTitle[] = -"In this tad, the informations related with titles are edited. You can choose\n" +"In this tad, the information related with titles are edited. You can choose\n" "to show or hide the title in your canvases via the check button 'Show title'.\n" "\n" "'Fill' group: \n" @@ -279,7 +279,7 @@ const char gHelpSMTitle[] = ; const char gHelpSMStats[] = -"In this tad, the informations related with stats are edited.\n" +"In this tad, the information related with stats are edited.\n" "\n" "'Fill' group: \n" " You can modify here the color and the pattern which is used to fill\n" @@ -302,18 +302,18 @@ const char gHelpSMStats[] = " the width (W) and the height (H).\n" "\n" "'Stat Options' group:\n" -" You can select the informations you want to see in the stats pave.\n" +" You can select the information you want to see in the stats pave.\n" " The paint format is used as an argument in a C++ printf() method: it\n" " describes how the value will be shown.\n" "\n" "'Fit Options' group:\n" -" You can select the way you want to show informations in the pave.\n" +" You can select the way you want to show information in the pave.\n" " The paint format is used as an argument in a C++ printf() method: it\n" " describes how the value will be shown.\n" ; const char gHelpSMPSPDF[] = -"In this tad, the informations related with PS and PDF are edited. These\n" +"In this tad, the information related with PS and PDF are edited. These\n" "settings can't be previewed, but as in the other tabs, any modification in\n" "this one will take effect.\n" "\n" diff --git a/gui/ged/src/TGedPatternSelect.cxx b/gui/ged/src/TGedPatternSelect.cxx index 9814039cad4bd..49532409b0f14 100644 --- a/gui/ged/src/TGedPatternSelect.cxx +++ b/gui/ged/src/TGedPatternSelect.cxx @@ -40,6 +40,7 @@ #include "TGResourcePool.h" #include "TGedPatternSelect.h" +#include "RConfigure.h" #include "TGToolTip.h" #include "TGButton.h" #include "Riostream.h" @@ -464,6 +465,9 @@ Bool_t TGedSelect::HandleButton(Event_t *event) if (fPopup) { gVirtualX->TranslateCoordinates(fId, gClient->GetDefaultRoot()->GetId(), 0, fHeight, ax, ay, wdummy); +#ifdef R__HAS_COCOA + gVirtualX->SetWMTransientHint(fPopup->GetId(), GetId()); +#endif fPopup->PlacePopup(ax, ay, fPopup->GetDefaultWidth(), fPopup->GetDefaultHeight()); } @@ -520,7 +524,7 @@ void TGedSelect::DoRedraw() if (fState == kButtonDown) { ++x; ++y; } - DrawTriangle(GetShadowGC()(), x, y); + DrawTriangle(GetBlackGC()(), x, y); } else { @@ -549,13 +553,22 @@ void TGedSelect::DrawTriangle(GContext_t gc, Int_t x, Int_t y) // Draw small triangle. Point_t points[3]; - + +#ifdef R__HAS_COCOA + points[0].fX = x; + points[0].fY = y; + points[1].fX = x + 6; + points[1].fY = y; + points[2].fX = x + 3; + points[2].fY = y + 3; +#else points[0].fX = x; points[0].fY = y; points[1].fX = x + 5; points[1].fY = y; points[2].fX = x + 2; points[2].fY = y + 3; +#endif gVirtualX->FillPolygon(fId, gc, points, 3); } @@ -605,6 +618,22 @@ void TGedPatternSelect::DoRedraw() w = h * 2; if (fState == kButtonDown) { ++x; ++y; } +#ifdef R__HAS_COCOA + TGedPatternFrame::SetFillStyle(fDrawGC, 1001); + + Pixel_t white; + gClient->GetColorByName("white", white); // white background + fDrawGC->SetForeground(white); + gVirtualX->FillRectangle(fId, fDrawGC->GetGC(), x + 1, y + 1, w - 1, h - 1); + + if (fPattern != 0) { + fDrawGC->SetForeground(0); + TGedPatternFrame::SetFillStyle(fDrawGC, fPattern); + gVirtualX->FillRectangle(fId, fDrawGC->GetGC(), x + 1, y + 1, w - 1, h - 1); + } + + gVirtualX->DrawRectangle(fId, GetShadowGC()(), x + 1, y + 1, w - 1, h - 1); +#else gVirtualX->DrawRectangle(fId, GetShadowGC()(), x, y, w - 1, h - 1); TGedPatternFrame::SetFillStyle(fDrawGC, 1001); @@ -619,6 +648,7 @@ void TGedPatternSelect::DoRedraw() TGedPatternFrame::SetFillStyle(fDrawGC, fPattern); gVirtualX->FillRectangle(fId, fDrawGC->GetGC(), x + 1, y + 1, w - 2, h - 2); } +#endif } else { // sunken rectangle x = fBorderWidth + 2; @@ -641,11 +671,11 @@ void TGedPatternSelect::SetPattern(Style_t pattern, Bool_t emit) } //______________________________________________________________________________ -void TGedPatternSelect::SavePrimitive(ostream &out, Option_t * /*= ""*/) +void TGedPatternSelect::SavePrimitive(std::ostream &out, Option_t * /*= ""*/) { // Save the pattern select widget as a C++ statement(s) on output stream out out <<" TGedPatternSelect *"; out << GetName() << " = new TGedPatternSelect(" << fParent->GetName() - << "," << fPattern << "," << WidgetId() << ");" << endl; + << "," << fPattern << "," << WidgetId() << ");" << std::endl; } diff --git a/gui/ged/src/TH1Editor.cxx b/gui/ged/src/TH1Editor.cxx index 76b3652b11d56..46a6590ea9809 100644 --- a/gui/ged/src/TH1Editor.cxx +++ b/gui/ged/src/TH1Editor.cxx @@ -663,6 +663,7 @@ void TH1Editor::SetModel(TObject* obj) fAddCombo->Select(kADD_NONE); fAddMarker->SetState(kButtonUp); fAddB->SetState(kButtonUp); + fAddBar->SetState(kButtonUp); fAddSimple->SetState(kButtonDisabled); ChangeErrorCombo(1); // in case of a 2D plot: diff --git a/gui/ged/src/TStyleManager.cxx b/gui/ged/src/TStyleManager.cxx index 53b329c8734d0..521a8fb2acb8b 100644 --- a/gui/ged/src/TStyleManager.cxx +++ b/gui/ged/src/TStyleManager.cxx @@ -4617,7 +4617,7 @@ void TStyleManager::DoSelectCanvas(TVirtualPad *pad, TObject *obj, Int_t mouseBu if ((!samePad) && preview) DoPreview(kFALSE); - // Update the informations' label about the selected objects. + // Update the information' label about the selected objects. TString sPad; if (fCurPad->GetName() && strlen(fCurPad->GetName())) sPad.Append(fCurPad->GetName()); diff --git a/gui/ged/src/TTextEditor.cxx b/gui/ged/src/TTextEditor.cxx new file mode 100644 index 0000000000000..d8137af5ada1a --- /dev/null +++ b/gui/ged/src/TTextEditor.cxx @@ -0,0 +1,163 @@ +#include "TTextEditor.h" +#include "TText.h" +#include "TGTextEntry.h" +#include "TGNumberEntry.h" +#include "TGLabel.h" + +ClassImp(TTextEditor) + + +enum ELatexID{ + kText_Text = 0, kText_Xpos, kText_Ypos, kText_Angle, kText_Size +}; + + +//______________________________________________________________________________ +TTextEditor::TTextEditor(const TGWindow *p, + Int_t width, Int_t height, + UInt_t options, Pixel_t back) + : TGedFrame(p, width, height, options | kVerticalFrame, back) +{ + // TTextEditor constructor. + + fText = 0; + + // start initializing the window components + MakeTitle("Text String"); + + fText = new TGTextEntry(this, new TGTextBuffer(50), kText_Text); + fText->Resize(135, fText->GetDefaultHeight()); + fText->SetToolTipText("Enter the text string"); + AddFrame(fText, new TGLayoutHints(kLHintsLeft, 3, 1, 2, 5)); + + TGCompositeFrame *f1 = new TGCompositeFrame(this, 120, 20, kHorizontalFrame); + TGLabel *lbl1 = new TGLabel(f1,"X Position"); + fXpos = new TGNumberEntry(f1, 4, 2, kText_Xpos, TGNumberEntry::kNESRealTwo, + TGNumberEntry::kNEANonNegative); + fXpos->Resize(50, 20); + f1->AddFrame(lbl1, new TGLayoutHints(kLHintsLeft,1, 1, 1, 1)); + f1->AddFrame(fXpos, new TGLayoutHints(kLHintsLeft, 7, 1, 1, 1)); + AddFrame(f1, new TGLayoutHints(kLHintsLeft, 1, 1, 1, 1)); + + TGCompositeFrame *f2 = new TGCompositeFrame(this, 120, 20, kHorizontalFrame); + TGLabel *lbl2 = new TGLabel(f2,"Y Position"); + fYpos = new TGNumberEntry(f2, 4, 2, kText_Ypos, TGNumberEntry::kNESRealTwo, + TGNumberEntry::kNEANonNegative); + fYpos->Resize(50, 20); + f2->AddFrame(lbl2, new TGLayoutHints(kLHintsLeft,1, 1, 1, 1)); + f2->AddFrame(fYpos, new TGLayoutHints(kLHintsLeft, 7, 1, 1, 1)); + AddFrame(f2, new TGLayoutHints(kLHintsLeft, 1, 1, 1, 1)); + + TGCompositeFrame *f3 = new TGCompositeFrame(this, 120, 20, kHorizontalFrame); + TGLabel *lbl3 = new TGLabel(f3,"Text Angle"); + fAngle = new TGNumberEntry(f3, 4, 2, kText_Angle, TGNumberEntry::kNESInteger, + TGNumberEntry::kNEANonNegative); + fAngle->Resize(50, 20); + f3->AddFrame(lbl3, new TGLayoutHints(kLHintsLeft,1, 1, 1, 1)); + f3->AddFrame(fAngle, new TGLayoutHints(kLHintsLeft, 7, 1, 1, 1)); + AddFrame(f3, new TGLayoutHints(kLHintsLeft, 1, 1, 1, 1)); + + TGCompositeFrame *f4 = new TGCompositeFrame(this, 120, 20, kHorizontalFrame); + TGLabel *lbl4 = new TGLabel(f4,"Text Size"); + fSize = new TGNumberEntry(f4, 4, 2, kText_Size, TGNumberEntry::kNESRealTwo, + TGNumberEntry::kNEANonNegative); + fSize->Resize(50, 20); + f4->AddFrame(lbl4, new TGLayoutHints(kLHintsLeft,1, 1, 1, 1)); + f4->AddFrame(fSize, new TGLayoutHints(kLHintsLeft, 7, 1, 1, 1)); + AddFrame(f4, new TGLayoutHints(kLHintsLeft, 1, 1, 1, 1)); +} + + +//______________________________________________________________________________ +TTextEditor::~TTextEditor() +{ + // TTextEditor destructor. +} + + +//______________________________________________________________________________ +void TTextEditor::SetModel(TObject *obj) +{ + // Set model. + + fEditedText = (TText*) (obj); + + fAvoidSignal = kTRUE; + fText->SetText(fEditedText->GetTitle()); + fXpos->SetNumber(fEditedText->GetX()); + fYpos->SetNumber(fEditedText->GetY()); + fAngle->SetNumber(fEditedText->GetTextAngle()); + fSize->SetNumber(fEditedText->GetTextSize()); + + if (fInit) ConnectSignals2Slots(); + fAvoidSignal = kFALSE; +} + + +//_____________________________________________________________________________ +void TTextEditor::ConnectSignals2Slots() +{ + // Connect signals to slots. + + fText->Connect("TextChanged(const char *)","TTextEditor",this,"DoText(const char *)"); + fXpos->Connect("ValueSet(Long_t)", "TTextEditor", this, "DoXpos()"); + fYpos->Connect("ValueSet(Long_t)", "TTextEditor", this, "DoYpos()"); + fAngle->Connect("ValueSet(Long_t)", "TTextEditor", this, "DoAngle()"); + fSize->Connect("ValueSet(Long_t)", "TTextEditor", this, "DoSize()"); + + fInit = kFALSE; // connect the slots to the signals only once +} + +//______________________________________________________________________________ +void TTextEditor::DoAngle() +{ + // Slot for setting the text Angle. + + if (fAvoidSignal) return; + fEditedText->SetTextAngle(fAngle->GetNumber()); + Update(); +} + + +//______________________________________________________________________________ +void TTextEditor::DoSize() +{ + // Slot for setting the text Size. + + if (fAvoidSignal) return; + fEditedText->SetTextSize(fSize->GetNumber()); + Update(); +} + + +//______________________________________________________________________________ +void TTextEditor::DoText(const char *text) +{ + // Slot for setting the text string. + + if (fAvoidSignal) return; + fEditedText->SetTitle(text); + Update(); +} + + +//______________________________________________________________________________ +void TTextEditor::DoXpos() +{ + // Slot for setting the text X position. + + if (fAvoidSignal) return; + fEditedText->SetX(fXpos->GetNumber()); + Update(); +} + + +//______________________________________________________________________________ +void TTextEditor::DoYpos() +{ + // Slot for setting the text Y position. + + if (fAvoidSignal) return; + fEditedText->SetY(fYpos->GetNumber()); + Update(); +} \ No newline at end of file diff --git a/gui/gui/inc/TGFileBrowser.h b/gui/gui/inc/TGFileBrowser.h index c97a0141cf5c4..8150bb605ab0e 100644 --- a/gui/gui/inc/TGFileBrowser.h +++ b/gui/gui/inc/TGFileBrowser.h @@ -34,6 +34,7 @@ class TString; class TRootBrowser; class TSystemDirectory; class TSystemFile; +class TGPictureButton; class TGFileBrowser : public TGMainFrame, public TBrowserImp { diff --git a/gui/gui/inc/TGListBox.h b/gui/gui/inc/TGListBox.h index fb7245c867635..723614b92af01 100644 --- a/gui/gui/inc/TGListBox.h +++ b/gui/gui/inc/TGListBox.h @@ -156,7 +156,7 @@ class TGLineLBEntry : public TGTextLBEntry { protected: UInt_t fLineWidth; // line width Style_t fLineStyle; // line style - UInt_t fLineLength; // line lenght + UInt_t fLineLength; // line length TGGC *fLineGC; // line graphics context virtual void DoRedraw(); diff --git a/gui/gui/inc/TGMdiMainFrame.h b/gui/gui/inc/TGMdiMainFrame.h index 7ad9eabbbd177..cb7d80c0ea452 100644 --- a/gui/gui/inc/TGMdiMainFrame.h +++ b/gui/gui/inc/TGMdiMainFrame.h @@ -152,10 +152,10 @@ friend class TGMdiFrame; }; Int_t fCurrentX, fCurrentY, fResizeMode; // current MDI child XY position and resize mode - Int_t fArrangementMode; // MDI childs arrangement mode - TGFont *fFontCurrent, *fFontNotCurrent; // fonts for active and inactive MDI childs - Pixel_t fBackCurrent, fForeCurrent; // back and fore colors for active MDI childs - Pixel_t fBackNotCurrent, fForeNotCurrent; // back and fore colors for inactive MDI childs + Int_t fArrangementMode; // MDI children arrangement mode + TGFont *fFontCurrent, *fFontNotCurrent; // fonts for active and inactive MDI children + Pixel_t fBackCurrent, fForeCurrent; // back and fore colors for active MDI children + Pixel_t fBackNotCurrent, fForeNotCurrent; // back and fore colors for inactive MDI children TGGC *fBoxGC; // GC used to draw resizing box (rectangle) diff --git a/gui/gui/inc/TGPack.h b/gui/gui/inc/TGPack.h index 76779c9336f88..326e18f2b66b3 100644 --- a/gui/gui/inc/TGPack.h +++ b/gui/gui/inc/TGPack.h @@ -103,7 +103,7 @@ class TGPack : public TGCompositeFrame Bool_t GetVertical() const { return fVertical; } void SetVertical(Bool_t x); - // For now assume this is always true. Lenght of splitter = 4 pixels. + // For now assume this is always true. Length of splitter = 4 pixels. Bool_t GetUseSplitters() const { return fUseSplitters; } void SetUseSplitters(Bool_t x) { fUseSplitters = x; } diff --git a/gui/gui/inc/TGText.h b/gui/gui/inc/TGText.h index b7f50e9b7dd6c..40405cc0b9c0f 100644 --- a/gui/gui/inc/TGText.h +++ b/gui/gui/inc/TGText.h @@ -38,7 +38,7 @@ friend class TGText; protected: char *fString; // line of text - ULong_t fLength; // lenght of line + ULong_t fLength; // length of line TGTextLine *fPrev; // previous line TGTextLine *fNext; // next line diff --git a/gui/gui/inc/TRootBrowser.h b/gui/gui/inc/TRootBrowser.h index eb9f953879c23..025e2e3f58242 100644 --- a/gui/gui/inc/TRootBrowser.h +++ b/gui/gui/inc/TRootBrowser.h @@ -1,4 +1,4 @@ -// @(#)root/gui:$Id$ +// @(#)root/gui:$Id: 7cf312b9bc9940a03d7c0cee95eea0085dc9898c $ // Author: Bertrand Bellenot 26/09/2007 /************************************************************************* @@ -96,8 +96,31 @@ class TRootBrowser : public TGMainFrame, public TBrowserImp { Int_t fCrTab[3]; // Actual (active) tab elements (for each Tab) Int_t fPid; // Current process id Bool_t fShowCloseTab; // kTRUE to show close icon on tab elements + const TGPicture *fIconPic; // icon picture public: + enum ENewBrowserMessages { + kBrowse = 11011, + kOpenFile, + kClone, + kHelpAbout, + kHelpOnBrowser, + kHelpOnCanvas, + kHelpOnMenus, + kHelpOnGraphicsEd, + kHelpOnObjects, + kHelpOnPS, + kHelpOnRemote, + kNewEditor, + kNewCanvas, + kNewHtml, + kExecPluginMacro, + kExecPluginCmd, + kCloseTab, + kCloseWindow, + kQuitRoot + }; + enum EInsertPosition { kLeft, kRight, kBottom }; @@ -110,8 +133,8 @@ class TRootBrowser : public TGMainFrame, public TBrowserImp { void CreateBrowser(const char *name); void CloneBrowser(); - void CloseWindow(); - void CloseTab(Int_t id); + virtual void CloseWindow(); + virtual void CloseTab(Int_t id); virtual void CloseTabs(); void DoTab(Int_t id); TGFrame *GetActFrame() const { return (TGFrame *)fEditFrame; } diff --git a/gui/gui/src/HelpText.cxx b/gui/gui/src/HelpText.cxx index 5ca18b9f369a8..54852542d2d38 100644 --- a/gui/gui/src/HelpText.cxx +++ b/gui/gui/src/HelpText.cxx @@ -254,6 +254,7 @@ Each canvas has a menu bar with the following items:\n\ <name.eps > makes a Postscript encapsulated file\n\ <name.pdf > makes a PDF file\n\ <name.svg > makes a SVG file\n\ + <name.tex > makes a TeX file\n\ <name.gif > makes a GIF file\n\ <name.C > generates a C++ macro to reproduce the canvas\n\ <name.root> saves canvas objects in a Root file\n\ @@ -452,7 +453,7 @@ The username can be specified in two ways, \"-l\" having the priority\n\ (as in ssh). A \"dbg\" value > 0 gives increasing verbosity.\n\ The last argument \"script\" allows to specify an alternative script to\n\ be executed remotely to startup the session, \"roots\" being\n\ -the default. If the script is preceeded by a \"<\" the script will be\n\ +the default. If the script is preceded by a \"<\" the script will be\n\ sourced, after which \"roots\" is executed. The sourced script can be \n\ used to change the PATH and other variables, allowing an alternative\n\ \"roots\" script to be found.\n\ diff --git a/gui/gui/src/TGCanvas.cxx b/gui/gui/src/TGCanvas.cxx index c8fb0d26763d0..b27f280843912 100644 --- a/gui/gui/src/TGCanvas.cxx +++ b/gui/gui/src/TGCanvas.cxx @@ -792,13 +792,16 @@ void TGContainer::SetPageDimension(UInt_t w, UInt_t h) void TGContainer::DoRedraw() { // Redraw content of container in the viewport region. - +#ifdef R__HAS_COCOA + DrawRegion(0, 0, GetWidth(), GetHeight()); +#else if (!fExposedRegion.IsEmpty()) { DrawRegion(fExposedRegion.fX, fExposedRegion.fY, fExposedRegion.fW, fExposedRegion.fH); fExposedRegion.Empty(); } +#endif } //______________________________________________________________________________ diff --git a/gui/gui/src/TGColorDialog.cxx b/gui/gui/src/TGColorDialog.cxx index c1ecfb3a4b914..bb6b731c5d3fa 100644 --- a/gui/gui/src/TGColorDialog.cxx +++ b/gui/gui/src/TGColorDialog.cxx @@ -1,4 +1,4 @@ -// @(#)root/gui:$Id$ +// @(#)root/gui:$Id: c1ecfb3a4b91442ae3b6fe3059ae838e463f2f56 $ // Author: Bertrand Bellenot + Fons Rademakers 22/08/02 // Author: Ilka Antcheva (color wheel support) 16/03/07 @@ -1267,7 +1267,7 @@ TGColorDialog::TGColorDialog(const TGWindow *p, const TGWindow *m, SetWindowName("Color Selector"); SetIconName("Color Selector"); - SetClassHints("ColorSelector", "ColorSelector"); + SetClassHints("ROOT", "ColorSelector"); SetMWMHints(kMWMDecorAll | kMWMDecorResizeH | kMWMDecorMaximize | kMWMDecorMinimize | kMWMDecorMenu, diff --git a/gui/gui/src/TGColorSelect.cxx b/gui/gui/src/TGColorSelect.cxx index 19ba7f8460425..55ad4bf1c208b 100644 --- a/gui/gui/src/TGColorSelect.cxx +++ b/gui/gui/src/TGColorSelect.cxx @@ -50,6 +50,7 @@ #include "TGColorSelect.h" #include "TGColorDialog.h" #include "TGResourcePool.h" +#include "RConfigure.h" #include "TG3DLine.h" #include "TColor.h" #include "Riostream.h" @@ -453,6 +454,9 @@ Bool_t TGColorSelect::HandleButton(Event_t *event) gVirtualX->TranslateCoordinates(fId, gClient->GetDefaultRoot()->GetId(), 0, fHeight, ax, ay, wdummy); +#ifdef R__HAS_COCOA + gVirtualX->SetWMTransientHint(fColorPopup->GetId(), GetId()); +#endif fColorPopup->PlacePopup(ax, ay, fColorPopup->GetDefaultWidth(), fColorPopup->GetDefaultHeight()); fColorPopup = 0; @@ -504,8 +508,17 @@ void TGColorSelect::DoRedraw() if (fState == kButtonDown) { ++x; ++y; } +#ifdef R__HAS_COCOA + //Adjustment for Quartz 2D is required: + //first, I DO not try to fit filled rectangle into outline - this + //simply DOES NOT work (with retina/non-retina display, for example. + //First - fill rectable, then draw outline. + gVirtualX->FillRectangle(fId, fDrawGC(), x + 1, y + 1, w - 1, h - 1); + gVirtualX->DrawRectangle(fId, GetShadowGC()(), x + 1, y + 1, w - 1, h - 1); +#else gVirtualX->DrawRectangle(fId, GetShadowGC()(), x, y, w - 1, h - 1); gVirtualX->FillRectangle(fId, fDrawGC(), x + 1, y + 1, w - 2, h - 2); +#endif // separator @@ -526,7 +539,7 @@ void TGColorSelect::DoRedraw() if (fState == kButtonDown) { ++x; ++y; } - DrawTriangle(GetShadowGC()(), x, y); + DrawTriangle(GetBlackGC()(), x, y); } else { @@ -566,12 +579,24 @@ void TGColorSelect::DrawTriangle(GContext_t gc, Int_t x, Int_t y) Point_t points[3]; +#ifdef R__HAS_COCOA + //When it comes to tiny pixel-precise objects like this, + //Quartz is not really good: triangle is ugly and wrong. + //I have to adjust pixels manually. + points[0].fX = x; + points[0].fY = y; + points[1].fX = x + 6; + points[1].fY = y; + points[2].fX = x + 3; + points[2].fY = y + 3; +#else points[0].fX = x; points[0].fY = y; points[1].fX = x + 5; points[1].fY = y; points[2].fX = x + 2; points[2].fY = y + 3; +#endif gVirtualX->FillPolygon(fId, gc, points, 3); } @@ -589,7 +614,7 @@ void TGColorSelect::SetColor(ULong_t color, Bool_t emit) } //______________________________________________________________________________ -void TGColorSelect::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGColorSelect::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a color select widget as a C++ statement(s) on output stream out @@ -601,22 +626,22 @@ void TGColorSelect::SavePrimitive(ostream &out, Option_t *option /*= ""*/) const char *colorname = TColor::PixelAsHexString(color); gClient->GetColorByName(colorname, color); - out << endl << " // color select widget" << endl; - out << " ULong_t " << cvar.Data() << ";" << endl; + out << std::endl << " // color select widget" << std::endl; + out << " ULong_t " << cvar.Data() << ";" << std::endl; out << " gClient->GetColorByName(" << quote << colorname << quote - << ", " << cvar.Data() << ");" << endl; + << ", " << cvar.Data() << ");" << std::endl; out <<" TGColorSelect *"; out << GetName() << " = new TGColorSelect(" << fParent->GetName() - << ", " << cvar.Data() << ", " << WidgetId() << ");" << endl; + << ", " << cvar.Data() << ", " << WidgetId() << ");" << std::endl; nn++; if (option && strstr(option, "keep_names")) - out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << endl; + out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << std::endl; if (!IsEnabled()) { - out << " " << GetName() << "->Disable();" << endl; + out << " " << GetName() << "->Disable();" << std::endl; } - out << endl; + out << std::endl; } diff --git a/gui/gui/src/TGComboBox.cxx b/gui/gui/src/TGComboBox.cxx index 27c33cbd98e75..58b16f5f12b21 100644 --- a/gui/gui/src/TGComboBox.cxx +++ b/gui/gui/src/TGComboBox.cxx @@ -47,6 +47,7 @@ #include "Riostream.h" #include "TGTextEntry.h" #include "KeySymbols.h" +#include "RConfigure.h" ClassImp(TGComboBoxPopup) @@ -479,8 +480,18 @@ Bool_t TGComboBox::HandleButton(Event_t *event) 0, fHeight, ax, ay, wdummy); // Drop down listbox of combo box should react to pointer motion... fListBox->GetContainer()->AddInput(kPointerMotionMask); +#ifdef R__HAS_COCOA + gVirtualX->SetWMTransientHint(fComboFrame->GetId(), GetId()); +#endif fComboFrame->PlacePopup(ax, ay, fWidth-2, fComboFrame->GetDefaultHeight()); fDDButton->SetState(kButtonUp); +#ifdef R__HAS_COCOA + //tp: I need this modification - "button" is not repainted correctly + //with Cocoa, when combobox is closed (reason is quite complex), happens + //when item is wider than combobox. + //TODO: find another way :) + fClient->NeedRedraw(fDDButton); +#endif } else if (fTextEntry) { return fTextEntry->HandleButton(event); } @@ -672,13 +683,13 @@ void TGComboBox::RemoveAll() } //______________________________________________________________________________ -void TGComboBox::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGComboBox::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a combo box widget as a C++ statement(s) on output stream out. if (fBackground != GetDefaultFrameBackground()) SaveUserColor(out, option); - out << endl << " // combo box" << endl; + out << std::endl << " // combo box" << std::endl; out << " TGComboBox *"; if (!fTextEntry) { @@ -690,15 +701,15 @@ void TGComboBox::SavePrimitive(ostream &out, Option_t *option /*= ""*/) if (fBackground == GetWhitePixel()) { if (GetOptions() == (kHorizontalFrame | kSunkenFrame | kDoubleBorder)) { - out <<");" << endl; + out <<");" << std::endl; } else { - out << "," << GetOptionString() << ");" << endl; + out << "," << GetOptionString() << ");" << std::endl; } } else { - out << "," << GetOptionString() << ",ucolor);" << endl; + out << "," << GetOptionString() << ",ucolor);" << std::endl; } if (option && strstr(option, "keep_names")) - out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << endl; + out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << std::endl; TGTextLBEntry *b; TGFrameElement *el; @@ -710,12 +721,12 @@ void TGComboBox::SavePrimitive(ostream &out, Option_t *option /*= ""*/) b = (TGTextLBEntry *) el->fFrame; out << " " << GetName() << "->AddEntry("; b->SavePrimitive(out, option); - out << ");" << endl; + out << ");" << std::endl; } out << " " << GetName() << "->Resize(" << GetWidth() << "," - << GetHeight() << ");" << endl; - out << " " << GetName() << "->Select(" << GetSelected() << ");" << endl; + << GetHeight() << ");" << std::endl; + out << " " << GetName() << "->Select(" << GetSelected() << ");" << std::endl; } //______________________________________________________________________________ @@ -740,20 +751,20 @@ TGLineStyleComboBox::TGLineStyleComboBox(const TGWindow *p, Int_t id, } //______________________________________________________________________________ -void TGLineStyleComboBox::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGLineStyleComboBox::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a line style combo box widget as a C++ statement(s). - out << endl << " // line style combo box" << endl; + out << std::endl << " // line style combo box" << std::endl; out << " TGLineStyleComboBox *"; out << GetName() << " = new TGLineStyleComboBox(" << fParent->GetName() - << "," << fWidgetId << ");" << endl; + << "," << fWidgetId << ");" << std::endl; if (option && strstr(option, "keep_names")) - out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << endl; + out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << std::endl; out << " " << GetName() << "->Resize(" << GetWidth() << "," - << GetHeight() << ");" << endl; - out << " " << GetName() << "->Select(" << GetSelected() << ");" << endl; + << GetHeight() << ");" << std::endl; + out << " " << GetName() << "->Select(" << GetSelected() << ");" << std::endl; } //______________________________________________________________________________ @@ -782,20 +793,20 @@ TGLineWidthComboBox::TGLineWidthComboBox(const TGWindow *p, Int_t id, } //______________________________________________________________________________ -void TGLineWidthComboBox::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGLineWidthComboBox::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a line width combo box widget as a C++ statement(s). - out << endl << " // line width combo box" << endl; + out << std::endl << " // line width combo box" << std::endl; out << " TGLineWidthComboBox *"; out << GetName() << " = new TGLineWidthComboBox(" << fParent->GetName() - << "," << fWidgetId << ");" << endl; + << "," << fWidgetId << ");" << std::endl; if (option && strstr(option, "keep_names")) - out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << endl; + out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << std::endl; out << " " << GetName() << "->Resize(" << GetWidth() << "," - << GetHeight() << ");" << endl; - out << " " << GetName() << "->Select(" << GetSelected() << ");" << endl; + << GetHeight() << ");" << std::endl; + out << " " << GetName() << "->Select(" << GetSelected() << ");" << std::endl; } static const char *gFonts[][2] = { // unix name, name diff --git a/gui/gui/src/TGFileBrowser.cxx b/gui/gui/src/TGFileBrowser.cxx index f96f197fc1b35..1eb9e230522c2 100644 --- a/gui/gui/src/TGFileBrowser.cxx +++ b/gui/gui/src/TGFileBrowser.cxx @@ -1,4 +1,4 @@ -// @(#)root/gui:$Id$ +// @(#)root/gui:$Id: f96f197fc1b35e846c5be5b3f6b655200f0b4efc $ // Author: Bertrand Bellenot 26/09/2007 /************************************************************************* @@ -1292,12 +1292,33 @@ void TGFileBrowser::DoubleClicked(TGListTreeItem *item, Int_t /*btn*/) } if (!obj->InheritsFrom("TObjString") || gSystem->AccessPathName(fullpath.Data())) { + fBrowser->SetDrawOption(GetDrawOption()); fDblClick = kTRUE; - obj->Browse(fBrowser); + if (gClient->GetMimeTypeList()->GetAction(obj->IsA()->GetName(), action)) { + act = action; + if (act.Contains("%s")) act.ReplaceAll("%s", obj->GetName()); + else if (act.Contains("->Browse()")) obj->Browse(fBrowser); + else if (act.Contains("->Draw()")) obj->Draw(GetDrawOption()); + else { + act.Prepend(obj->GetName()); + gInterpreter->SaveGlobalsContext(); + if (act[0] == '!') { + act.Remove(0, 1); + gSystem->Exec(act.Data()); + } else { + // special case for remote object: remote process + if (obj->InheritsFrom("TRemoteObject")) + gApplication->SetBit(TApplication::kProcessRemotely); + gApplication->ProcessLine(act.Data()); + } + } + } + else obj->Browse(fBrowser); fDblClick = kFALSE; fNKeys = 0; fCnt = 0; fListTree->ClearViewPort(); + if (gPad) gPad->Update(); return; } } diff --git a/gui/gui/src/TGFileDialog.cxx b/gui/gui/src/TGFileDialog.cxx index fedcde4f35930..a192368663b46 100644 --- a/gui/gui/src/TGFileDialog.cxx +++ b/gui/gui/src/TGFileDialog.cxx @@ -321,7 +321,7 @@ TGFileDialog::TGFileDialog(const TGWindow *p, const TGWindow *main, const char *wname = (dlg_type == kFDSave) ? "Save As..." : "Open"; SetWindowName(wname); SetIconName(wname); - SetClassHints("FileDialog", "FileDialog"); + SetClassHints("ROOT", "FileDialog"); SetMWMHints(kMWMDecorAll | kMWMDecorResizeH | kMWMDecorMaximize | kMWMDecorMinimize | kMWMDecorMenu, diff --git a/gui/gui/src/TGFontDialog.cxx b/gui/gui/src/TGFontDialog.cxx index 582991cfe74e2..df21f9dbb72e3 100644 --- a/gui/gui/src/TGFontDialog.cxx +++ b/gui/gui/src/TGFontDialog.cxx @@ -1,4 +1,4 @@ -// @(#)root/gui:$Id$ +// @(#)root/gui:$Id: bcc7b53cab203466d39a6f17445d822d6fc19610 $ // Author: Bertrand Bellenot + Fons Rademakers + Valeriy Onuchin 23/04/03 /************************************************************************* @@ -180,9 +180,10 @@ TGFontDialog::TGFontDialog(const TGWindow *p, const TGWindow *t, fFontNames = new TGListBox(vf, kFDLG_FONTNAMES); fFontNames->Resize(120, fFontNames->GetDefaultHeight()); - if (gVirtualX->InheritsFrom("TGX11")) { + if (gVirtualX->InheritsFrom("TGX11") || gVirtualX->InheritsFrom("TGCocoa")) { fFontNames->Connect("Selected(char*)", "TGFontDialog", this, "UpdateStyleSize(char*)"); } + fFontNames->Associate(this); vf->AddFrame(fFontNames, new TGLayoutHints(kLHintsExpandX | kLHintsExpandY)); @@ -365,7 +366,7 @@ TGFontDialog::TGFontDialog(const TGWindow *p, const TGWindow *t, SetWindowName("Font Selection"); SetIconName("Font Selection"); - SetClassHints("FontDialog", "FontDialog"); + SetClassHints("ROOT", "FontDialog"); SetMWMHints(kMWMDecorAll | kMWMDecorResizeH | kMWMDecorMaximize | kMWMDecorMinimize | kMWMDecorMenu, @@ -580,6 +581,13 @@ void TGFontDialog::UpdateStyleSize(const char *family) Bool_t x11 = gVirtualX->InheritsFrom("TGX11"); Bool_t all_sizes = !x11; Bool_t all_styles = !x11; + + // + if (gVirtualX->InheritsFrom("TGCocoa")) { + all_sizes = kTRUE; + all_styles = kFALSE; + } + int szn = 0; fFontSizes->AddEntry("12", szn++); @@ -798,15 +806,11 @@ void TGFontDialog::GetFontName() if (!fLabelFont) { // should not happen fLName = oldFont; - goto out; } - - if (fSample) { + else if (fSample) { fSample->SetTextFont(fLabelFont); } } - -out: Int_t oldAlign = fTextAlign; Int_t idx = fTextAligns->GetSelected(); diff --git a/gui/gui/src/TGFrame.cxx b/gui/gui/src/TGFrame.cxx index 0f9e5cc28e1d9..affb0da3c222d 100644 --- a/gui/gui/src/TGFrame.cxx +++ b/gui/gui/src/TGFrame.cxx @@ -566,7 +566,7 @@ void TGFrame::Move(Int_t x, Int_t y) void TGFrame::Resize(UInt_t w, UInt_t h) { // Resize the frame. - // If w=0 && h=0 - Resize to deafult size + // If w=0 && h=0 - Resize to default size if (w != fWidth || h != fHeight) { TGDimension siz(0,0); @@ -590,7 +590,7 @@ void TGFrame::Resize(TGDimension size) void TGFrame::MoveResize(Int_t x, Int_t y, UInt_t w, UInt_t h) { // Move and/or resize the frame. - // If w=0 && h=0 - Resize to deafult size + // If w=0 && h=0 - Resize to default size // we do it anyway as we don't know if it's only a move or only a resize TGDimension siz(0,0); @@ -2311,7 +2311,7 @@ TGHeaderFrame::TGHeaderFrame(const TGWindow *p, UInt_t w, UInt_t h, void TGHeaderFrame::SetColumnsInfo(Int_t nColumns, TGTextButton **colHeader, TGVFileSplitter **splitHeader) { - // Set columns informations in the header frame. + // Set columns information in the header frame. fNColumns = nColumns; fColHeader = colHeader; diff --git a/gui/gui/src/TGImageMap.cxx b/gui/gui/src/TGImageMap.cxx index ce5e391fb1d80..3927fa23b4edc 100644 --- a/gui/gui/src/TGImageMap.cxx +++ b/gui/gui/src/TGImageMap.cxx @@ -384,7 +384,7 @@ void TGRegionWithId::DisplayPopup() { // Display popup menu associated with this region. - if (fPopup) fPopup->PlaceMenu(gPointerX, gPointerY, kFALSE, kTRUE); + if (fPopup) fPopup->PlaceMenu(gPointerX, gPointerY, kTRUE, kTRUE); } //______________________________________________________________________________ @@ -593,7 +593,7 @@ Bool_t TGImageMap::HandleButton(Event_t *event) RegionClicked(region->GetId()); else if (event->fCode == kButton3 ) { pop = region->GetPopup(); - if (pop) pop->PlaceMenu(gPointerX, gPointerY, kFALSE, kTRUE); + if (pop) pop->PlaceMenu(gPointerX, gPointerY, kTRUE, kTRUE); } } return kTRUE; diff --git a/gui/gui/src/TGLabel.cxx b/gui/gui/src/TGLabel.cxx index b7752230ac935..09a724792dc7b 100644 --- a/gui/gui/src/TGLabel.cxx +++ b/gui/gui/src/TGLabel.cxx @@ -61,7 +61,7 @@ TGLabel::TGLabel(const TGWindow *p, TGString *text, GContext_t norm, fMLeft = fMRight = fMTop = fMBottom = 0; if (!norm) { - norm = fgDefaultGC->GetGC(); + norm = GetDefaultGC().GetGC(); } fNormGC = norm; @@ -102,7 +102,7 @@ TGLabel::TGLabel(const TGWindow *p, const char *text, GContext_t norm, fMLeft = fMRight = fMTop = fMBottom = 0; if (!norm) { - norm = fgDefaultGC->GetGC(); + norm = GetDefaultGC().GetGC(); } fNormGC = norm; @@ -224,7 +224,7 @@ void TGLabel::DoRedraw() TGGC *gc = pool->FindGC(fNormGC); if (!gc) { - fNormGC = fgDefaultGC->GetGC(); + fNormGC = GetDefaultGC().GetGC(); gc = pool->FindGC(fNormGC); } if (!gc) return; @@ -336,7 +336,7 @@ void TGLabel::SetTextFont(TGFont *font, Bool_t global) TGGC *gc = pool->FindGC(fNormGC); if (!global) { - if (gc == fgDefaultGC) { // create new GC + if (gc == &GetDefaultGC() ) { // create new GC gc = pool->GetGC((GCValues_t*)gc->GetAttributes(), kTRUE); // copy ctor. } fHasOwnFont = kTRUE; @@ -362,7 +362,7 @@ void TGLabel::SetTextColor(Pixel_t color, Bool_t global) TGGC *gc = pool->FindGC(fNormGC); if (!global) { - if (gc == fgDefaultGC) { + if (gc == &GetDefaultGC() ) { gc = pool->GetGC((GCValues_t*)gc->GetAttributes(), kTRUE); // copy } fHasOwnFont = kTRUE; diff --git a/gui/gui/src/TGListBox.cxx b/gui/gui/src/TGListBox.cxx index 33d730c9ec878..994291022ce61 100644 --- a/gui/gui/src/TGListBox.cxx +++ b/gui/gui/src/TGListBox.cxx @@ -930,8 +930,9 @@ Bool_t TGLBContainer::HandleDoubleClick(Event_t *ev) DoubleClicked(f, ev->fCode); DoubleClicked(f, ev->fCode, ev->fXRoot, ev->fYRoot); } + return kTRUE; } - return kTRUE; + return TGContainer::HandleDoubleClick(ev); } //______________________________________________________________________________ @@ -1583,7 +1584,7 @@ Bool_t TGListBox::ProcessMessage(Long_t msg, Long_t parm1, Long_t) } break; case kCT_ITEMDBLCLICK: - { + if (!GetMultipleSelections()) { TGLBEntry *entry = GetSelectedEntry(); if (entry) { if (entry->InheritsFrom(TGTextLBEntry::Class())) { diff --git a/gui/gui/src/TGListTree.cxx b/gui/gui/src/TGListTree.cxx index 8f0f1faf5f04c..5d34d31eb0210 100644 --- a/gui/gui/src/TGListTree.cxx +++ b/gui/gui/src/TGListTree.cxx @@ -57,6 +57,7 @@ #include "TGDNDManager.h" #include "TBufferFile.h" #include "Riostream.h" +#include "RConfigure.h" Pixel_t TGListTree::fgGrayPixel = 0; const TGFont *TGListTree::fgDefaultFont = 0; @@ -1479,6 +1480,7 @@ void TGListTree::DrawItem(Handle_t id, TGListTreeItem *item, Int_t x, Int_t y, // Compute the height of this line height = FontHeight(); + xline = 0; xpic1 = x; xtext = x + fHspacing + (Int_t)item->GetPicWidth(); @@ -1502,6 +1504,9 @@ void TGListTree::DrawItem(Handle_t id, TGListTreeItem *item, Int_t x, Int_t y, height = pic1->GetHeight(); ypic1 = y; } else { +#ifdef R__HAS_COCOA + if (!pic2)//DO NOT MODIFY ytext, it WAS ADJUSTED already! +#endif ytext = y; ypic1 = y + (Int_t)((height - pic1->GetHeight()) >> 1); } @@ -1587,8 +1592,13 @@ void TGListTree::DrawOutline(Handle_t id, TGListTreeItem *item, Pixel_t col, } else gVirtualX->SetForeground(fDrawGC, col); + +#ifdef R__HAS_COCOA + gVirtualX->DrawRectangle(id, fDrawGC, 1, item->fY - pos.fY, dim.fWidth-2, item->fHeight + 1); +#else gVirtualX->DrawRectangle(id, fDrawGC, 1, item->fYtext-pos.fY-2, dim.fWidth-3, FontHeight()+4); +#endif gVirtualX->SetForeground(fDrawGC, fgBlackPixel); } @@ -1603,8 +1613,13 @@ void TGListTree::DrawActive(Handle_t id, TGListTreeItem *item) width = dim.fWidth-2; gVirtualX->SetForeground(fDrawGC, item->GetActiveColor()); + +#ifdef R__HAS_COCOA + gVirtualX->FillRectangle(id, fDrawGC, 1, item->fY - pos.fY, width, item->fHeight + 1); +#else gVirtualX->FillRectangle(id, fDrawGC, 1, item->fYtext-pos.fY-1, width, FontHeight()+3); +#endif gVirtualX->SetForeground(fDrawGC, fgBlackPixel); gVirtualX->DrawString(id, fActiveGC, item->fXtext, item->fYtext - pos.fY + FontAscent(), @@ -1623,7 +1638,7 @@ void TGListTree::DrawItemName(Handle_t id, TGListTreeItem *item) DrawActive(id, item); } else { // if (!item->IsActive() && (item != fSelected)) { - gVirtualX->FillRectangle(id, fHighlightGC, item->fXtext, + gVirtualX->FillRectangle(id, fHighlightGC, item->fXtext, item->fYtext-pos.fY, dim.fWidth-item->fXtext-2, FontHeight()+1); gVirtualX->DrawString(id, fDrawGC, @@ -2323,7 +2338,6 @@ TGListTreeItem *TGListTree::FindItemByPathname(const char *path) TGListTreeItem *diritem = 0; TString fulldir; -start: while (1) { while (*p && *p == '/') p++; if (!*p) break; @@ -2346,7 +2360,7 @@ TGListTreeItem *TGListTree::FindItemByPathname(const char *path) if (!s || !strlen(s)) return diritem; p = ++s; item = diritem; - goto start; + continue; } } @@ -2578,13 +2592,13 @@ const TGPicture *TGListTree::GetUncheckedPic() } //______________________________________________________________________________ -void TGListTree::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGListTree::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a list tree widget as a C++ statements on output stream out. if (fBackground != GetWhitePixel()) SaveUserColor(out, option); - out << endl << " // list tree" << endl; + out << std::endl << " // list tree" << std::endl; out << " TGListTree *"; if ((fParent->GetParent())->InheritsFrom(TGCanvas::Class())) { @@ -2596,37 +2610,37 @@ void TGListTree::SavePrimitive(ostream &out, Option_t *option /*= ""*/) if (fBackground == GetWhitePixel()) { if (GetOptions() == kSunkenFrame) { - out <<");" << endl; + out <<");" << std::endl; } else { - out << "," << GetOptionString() <<");" << endl; + out << "," << GetOptionString() <<");" << std::endl; } } else { - out << "," << GetOptionString() << ",ucolor);" << endl; + out << "," << GetOptionString() << ",ucolor);" << std::endl; } if (option && strstr(option, "keep_names")) - out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << endl; + out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << std::endl; - out << endl; + out << std::endl; static Int_t n = 0; TGListTreeItem *current; current = GetFirstItem(); - out << " const TGPicture *popen; //used for list tree items" << endl; - out << " const TGPicture *pclose; //used for list tree items" << endl; - out << endl; + out << " const TGPicture *popen; //used for list tree items" << std::endl; + out << " const TGPicture *pclose; //used for list tree items" << std::endl; + out << std::endl; while (current) { out << " TGListTreeItem *item" << n << " = " << GetName() << "->AddItem("; current->SavePrimitive(out, TString::Format("%d",n), n); if (current->IsOpen()) - out << " " << GetName() << "->OpenItem(item" << n << ");" << endl; + out << " " << GetName() << "->OpenItem(item" << n << ");" << std::endl; else - out << " " << GetName() << "->CloseItem(item" << n << ");" << endl; + out << " " << GetName() << "->CloseItem(item" << n << ");" << std::endl; if (current == fSelected) - out << " " << GetName() << "->SetSelected(item" << n << ");" << endl; + out << " " << GetName() << "->SetSelected(item" << n << ");" << std::endl; n++; if (current->fFirstchild) { @@ -2635,11 +2649,11 @@ void TGListTree::SavePrimitive(ostream &out, Option_t *option /*= ""*/) current = current->fNextsibling; } - out << endl; + out << std::endl; } //______________________________________________________________________________ -void TGListTree::SaveChildren(ostream &out, TGListTreeItem *item, Int_t &n) +void TGListTree::SaveChildren(std::ostream &out, TGListTreeItem *item, Int_t &n) { // Save child items as a C++ statements on output stream out. @@ -2656,7 +2670,7 @@ void TGListTree::SaveChildren(ostream &out, TGListTreeItem *item, Int_t &n) } //______________________________________________________________________________ -void TGListTreeItemStd::SavePrimitive(ostream &out, Option_t *option, Int_t n) +void TGListTreeItemStd::SavePrimitive(std::ostream &out, Option_t *option, Int_t n) { // Save a list tree item attributes as a C++ statements on output stream. @@ -2679,50 +2693,50 @@ void TGListTreeItemStd::SavePrimitive(ostream &out, Option_t *option, Int_t n) text.ReplaceAll('\\', "\\\\"); text.ReplaceAll("\"", "\\\""); out << quote << text << quote; - out << ");" << endl; + out << ");" << std::endl; if (oldopen != fOpenPic) { oldopen = fOpenPic; out << " popen = gClient->GetPicture(" << quote << gSystem->ExpandPathName(gSystem->UnixPathName(fOpenPic->GetName())) - << quote << ");" << endl; + << quote << ");" << std::endl; } if (oldclose != fClosedPic) { oldclose = fClosedPic; out << " pclose = gClient->GetPicture(" << quote << gSystem->ExpandPathName(gSystem->UnixPathName(fClosedPic->GetName())) - << quote << ");" << endl; + << quote << ");" << std::endl; } - out << " item" << s.Data() << "->SetPictures(popen, pclose);" << endl; + out << " item" << s.Data() << "->SetPictures(popen, pclose);" << std::endl; if (HasCheckBox()) { if (fCheckedPic && makecheck) { - out << " const TGPicture *pcheck; //used for checked items" << endl; + out << " const TGPicture *pcheck; //used for checked items" << std::endl; makecheck = kFALSE; } if (fUncheckedPic && makeuncheck) { - out << " const TGPicture *puncheck; //used for unchecked items" << endl; + out << " const TGPicture *puncheck; //used for unchecked items" << std::endl; makeuncheck = kFALSE; } - out << " item" << s.Data() << "->CheckItem();" << endl; + out << " item" << s.Data() << "->CheckItem();" << std::endl; if (fCheckedPic && oldcheck != fCheckedPic) { oldcheck = fCheckedPic; out << " pcheck = gClient->GetPicture(" << quote << gSystem->ExpandPathName(gSystem->UnixPathName(fCheckedPic->GetName())) - << quote << ");" << endl; + << quote << ");" << std::endl; } if (fUncheckedPic && olduncheck != fUncheckedPic) { olduncheck = fUncheckedPic; out << " puncheck = gClient->GetPicture(" << quote << gSystem->ExpandPathName(gSystem->UnixPathName(fUncheckedPic->GetName())) - << quote << ");" << endl; + << quote << ");" << std::endl; } - out << " item" << s.Data() << "->SetCheckBoxPictures(pcheck, puncheck);" << endl; - out << " item" << s.Data() << "->SetCheckBox(kTRUE);" << endl; + out << " item" << s.Data() << "->SetCheckBoxPictures(pcheck, puncheck);" << std::endl; + out << " item" << s.Data() << "->SetCheckBox(kTRUE);" << std::endl; } if (fHasColor) { if (oldcolor != fColor) { oldcolor = fColor; - out << " item" << s.Data() << "->SetColor(" << fColor << ");" << endl; + out << " item" << s.Data() << "->SetColor(" << fColor << ");" << std::endl; } } if (fTipText.Length() > 0) { @@ -2731,7 +2745,7 @@ void TGListTreeItemStd::SavePrimitive(ostream &out, Option_t *option, Int_t n) tiptext.ReplaceAll("\n", "\\n"); tiptext.ReplaceAll("\"", "\\\""); out << " item" << s.Data() << "->SetTipText(" << quote - << tiptext << quote << ");" << endl; + << tiptext << quote << ");" << std::endl; } } diff --git a/gui/gui/src/TGMenu.cxx b/gui/gui/src/TGMenu.cxx index 586413c2197eb..9704a2727ecc1 100644 --- a/gui/gui/src/TGMenu.cxx +++ b/gui/gui/src/TGMenu.cxx @@ -71,6 +71,7 @@ #include "TGButton.h" #include "TQConnection.h" #include "TParameter.h" +#include "RConfigure.h" #include "TEnv.h" const TGGC *TGPopupMenu::fgDefaultGC = 0; @@ -757,6 +758,9 @@ Bool_t TGMenuBar::HandleKey(Event_t *event) (ce->fPopup->GetParent())->GetId(), ce->fEx+currentMenu->fMenuWidth, ce->fEy, ax, ay, wdummy); +#ifdef R__HAS_COCOA + gVirtualX->SetWMTransientHint(ce->fPopup->GetId(), GetId()); +#endif ce->fPopup->PlaceMenu(ax-5, ay-1, kFALSE, kFALSE); } } @@ -793,7 +797,9 @@ Bool_t TGMenuBar::HandleKey(Event_t *event) (submenu->GetParent())->GetId(), ce->fEx+menu->fMenuWidth, ce->fEy, ax, ay, wdummy); - +#ifdef R__HAS_COCOA + gVirtualX->SetWMTransientHint(submenu->GetId(), GetId()); +#endif submenu->PlaceMenu(ax-5, ay-1, kFALSE, kFALSE); } break; @@ -1273,7 +1279,7 @@ Int_t TGPopupMenu::EndMenu(void *&userData) if (fDelay) fDelay->Remove(); - // destroy any cascaded childs and get any ID + // destroy any cascaded children and get any ID if (fCurrent != 0) { @@ -1456,7 +1462,9 @@ Bool_t TGPopupMenu::HandleTimer(TTimer *) (fCurrent->fPopup->GetParent())->GetId(), fCurrent->fEx+fMenuWidth, fCurrent->fEy, ax, ay, wdummy); - +#ifdef R__HAS_COCOA + gVirtualX->SetWMTransientHint(fCurrent->fPopup->GetId(), GetId()); +#endif fCurrent->fPopup->PlaceMenu(ax-5, ay-1, kFALSE, kFALSE); } } @@ -2040,6 +2048,9 @@ void TGMenuTitle::SetState(Bool_t state) 0, 0, ax, ay, wdummy); // place the menu just under the window: +#ifdef R__HAS_COCOA + gVirtualX->SetWMTransientHint(fMenu->GetId(), GetId()); +#endif fMenu->PlaceMenu(ax-1, ay+fHeight, kTRUE, kFALSE); //kTRUE); } } else { @@ -2126,7 +2137,7 @@ const TGGC &TGMenuTitle::GetDefaultSelectedGC() } //______________________________________________________________________________ -void TGPopupMenu::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGPopupMenu::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a popup menu widget as a C++ statement(s) on output stream out. @@ -2134,7 +2145,7 @@ void TGPopupMenu::SavePrimitive(ostream &out, Option_t *option /*= ""*/) out << " TGPopupMenu *"; out << GetName() << " = new TGPopupMenu(gClient->GetDefaultRoot()" - << "," << GetWidth() << "," << GetHeight() << "," << GetOptionString() << ");" << endl; + << "," << GetWidth() << "," << GetHeight() << "," << GetOptionString() << ");" << std::endl; Bool_t hasradio = kFALSE; Int_t r_first, r_last, r_active; @@ -2184,12 +2195,12 @@ void TGPopupMenu::SavePrimitive(ostream &out, Option_t *option /*= ""*/) << gSystem->ExpandPathName(gSystem->UnixPathName(mentry->fPic->GetName())) << quote << ")"; } - out << ");" << endl; + out << ");" << std::endl; delete [] outext; break; case kMenuPopup: - out << endl; - out << " // cascaded menu " << quote << mentry->GetName() << quote <<endl; + out << std::endl; + out << " // cascaded menu " << quote << mentry->GetName() << quote <<std::endl; mentry->fPopup->SavePrimitive(out, option); text = mentry->GetName(); lentext = mentry->fLabel->GetLength(); @@ -2208,7 +2219,7 @@ void TGPopupMenu::SavePrimitive(ostream &out, Option_t *option /*= ""*/) out << " " << GetName() << "->AddPopup(" << quote << outext << quote << "," << mentry->fPopup->GetName() - << ");" << endl; + << ");" << std::endl; delete [] outext; break; case kMenuLabel: @@ -2219,28 +2230,28 @@ void TGPopupMenu::SavePrimitive(ostream &out, Option_t *option /*= ""*/) << mentry->fPic->GetName() << quote << ")"; } - out << ");" << endl; + out << ");" << std::endl; break; case kMenuSeparator: - out << " " << GetName() << "->AddSeparator();" << endl; + out << " " << GetName() << "->AddSeparator();" << std::endl; break; } if (!(mentry->GetStatus() & kMenuEnableMask)) { out<< " " << GetName() << "->DisableEntry(" << mentry->GetEntryId() - << ");" << endl; + << ");" << std::endl; } if (mentry->GetStatus() & kMenuHideMask) { out<< " " << GetName() << "->HideEntry(" << mentry->GetEntryId() - << ");" << endl; + << ");" << std::endl; } if (mentry->GetStatus() & kMenuCheckedMask) { out<< " " << GetName() << "->CheckEntry(" << mentry->GetEntryId() - << ");" << endl; + << ");" << std::endl; } if (mentry->GetStatus() & kMenuDefaultMask) { out<< " "<< GetName() << "->DefaultEntry(" << mentry->GetEntryId() - << ");" << endl; + << ");" << std::endl; } if (mentry->GetStatus() & kMenuRadioEntryMask) { if (hasradio) { @@ -2254,7 +2265,7 @@ void TGPopupMenu::SavePrimitive(ostream &out, Option_t *option /*= ""*/) } } else if (hasradio) { out << " " << GetName() << "->RCheckEntry(" << r_active << "," << r_first - << "," << r_last << ");" << endl; + << "," << r_last << ");" << std::endl; hasradio = kFALSE; r_active = r_first = r_last = -1; } @@ -2262,14 +2273,14 @@ void TGPopupMenu::SavePrimitive(ostream &out, Option_t *option /*= ""*/) } //______________________________________________________________________________ -void TGMenuTitle::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGMenuTitle::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a title menu widget as a C++ statement(s) on output stream out. char quote = '"'; - out << endl; - out << " // " << quote << fLabel->GetString() << quote <<" menu" << endl; + out << std::endl; + out << " // " << quote << fLabel->GetString() << quote <<" menu" << std::endl; fMenu->SavePrimitive(out, option); @@ -2294,18 +2305,18 @@ void TGMenuTitle::SavePrimitive(ostream &out, Option_t *option /*= ""*/) } //______________________________________________________________________________ -void TGMenuBar::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGMenuBar::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a menu bar widget as a C++ statement(s) on output stream out. - out << endl; - out << " // menu bar" << endl; + out << std::endl; + out << " // menu bar" << std::endl; out << " TGMenuBar *"; out << GetName() << " = new TGMenuBar(" << fParent->GetName() - << "," << GetWidth() << "," << GetHeight() << "," << GetOptionString() << ");" << endl; + << "," << GetWidth() << "," << GetHeight() << "," << GetOptionString() << ");" << std::endl; if (option && strstr(option, "keep_names")) - out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << endl; + out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << std::endl; if (!fList) return; @@ -2315,6 +2326,6 @@ void TGMenuBar::SavePrimitive(ostream &out, Option_t *option /*= ""*/) while ((el = (TGFrameElement *)next())) { el->fFrame->SavePrimitive(out, option); el->fLayout->SavePrimitive(out, option); - out << ");" << endl; + out << ");" << std::endl; } } diff --git a/gui/gui/src/TGMsgBox.cxx b/gui/gui/src/TGMsgBox.cxx index d25b6f3b0b254..e98c697d4f65a 100644 --- a/gui/gui/src/TGMsgBox.cxx +++ b/gui/gui/src/TGMsgBox.cxx @@ -1,4 +1,4 @@ -// @(#)root/gui:$Id$ +// @(#)root/gui:$Id: d25b6f3b0b2546fe028288bd22c21588bdd1b8c1 $ // Author: Fons Rademakers 09/01/98 /************************************************************************* @@ -301,7 +301,7 @@ void TGMsgBox::PMsgBox(const char *title, const char *msg, SetWindowName(title); SetIconName(title); - SetClassHints("MsgBox", "MsgBox"); + SetClassHints("ROOT", "MsgBox"); SetMWMHints(kMWMDecorAll | kMWMDecorResizeH | kMWMDecorMaximize | kMWMDecorMinimize | kMWMDecorMenu, diff --git a/gui/gui/src/TGSplitFrame.cxx b/gui/gui/src/TGSplitFrame.cxx index ec8f7e2f59ce6..fe0926913fd87 100644 --- a/gui/gui/src/TGSplitFrame.cxx +++ b/gui/gui/src/TGSplitFrame.cxx @@ -407,7 +407,7 @@ void TGSplitFrame::HSplit(UInt_t h) { // Horizontally split the frame. - // return if already splitted + // return if already split if ((fSplitter != 0) || (fFirst != 0) || (fSecond != 0) || (fFrame != 0)) return; UInt_t height = (h > 0) ? h : fHeight/2; @@ -436,7 +436,7 @@ void TGSplitFrame::VSplit(UInt_t w) { // Vertically split the frame. - // return if already splitted + // return if already split if ((fSplitter != 0) || (fFirst != 0) || (fSecond != 0) || (fFrame != 0)) return; UInt_t width = (w > 0) ? w : fWidth/2; diff --git a/gui/gui/src/TGTextEdit.cxx b/gui/gui/src/TGTextEdit.cxx index ed92f4958d9b9..c56c6d082e5c6 100644 --- a/gui/gui/src/TGTextEdit.cxx +++ b/gui/gui/src/TGTextEdit.cxx @@ -42,6 +42,7 @@ #include "TGScrollBar.h" #include "KeySymbols.h" #include "Riostream.h" +#include "RConfigure.h" static const char *gFiletypes[] = { "All files", "*", @@ -1766,6 +1767,23 @@ void TGTextEdit::InsChar(char character) Int_t(ToScrYCoord(fCurrent.fY+1) - fMaxDescent), charstring, strlen(charstring)); } else { +#ifdef R__HAS_COCOA + //I would use const, but some members of TGTextLine are non-const. + if (TGTextLine *currentLine = fText->GetCurrentLine()) { + const ULong_t lineStart = ToObjXCoord(fVisible.fX, fCurrent.fY); + if (lineStart < currentLine->GetLineLength()) { + const char *textToRender = currentLine->GetText(lineStart, currentLine->GetLineLength() - lineStart); + //The next two lines can throw and textToRender will leak, but ROOT does not care about such things. :( + gVirtualX->ClearArea(fCanvas->GetId(), Int_t(ToScrXCoord(0, fCurrent.fY)), + Int_t(ToScrYCoord(fCurrent.fY)), UInt_t(ToScrXCoord(currentLine->GetLineLength(), fCurrent.fY)), + UInt_t(ToScrYCoord(fCurrent.fY+1)-ToScrYCoord(fCurrent.fY))); + gVirtualX->DrawString(fCanvas->GetId(), fNormGC(), Int_t(ToScrXCoord(0, fCurrent.fY)), + Int_t(ToScrYCoord(fCurrent.fY + 1) - fMaxDescent), + textToRender, -1); + delete [] textToRender; + } + } +#else gVirtualX->CopyArea(fCanvas->GetId(), fCanvas->GetId(), fNormGC(), (Int_t)ToScrXCoord(fCurrent.fX, fCurrent.fY), (Int_t)ToScrYCoord(fCurrent.fY), fCanvas->GetWidth(), @@ -1783,6 +1801,7 @@ void TGTextEdit::InsChar(char character) Int_t(ToScrYCoord(fCurrent.fY+1) - fMaxDescent), charstring, strlen(charstring)); fCursorState = 2; // the ClearArea effectively turned off the cursor +#endif } delete [] charstring; SetCurrent(pos); @@ -1811,7 +1830,6 @@ void TGTextEdit::DelChar() if (!y) h = h << 1; pos.fX--; - if (fText->GetChar(pos) == 16) { do { pos.fX++; @@ -1857,18 +1875,22 @@ void TGTextEdit::DelChar() SetHsbPosition((ToScrXCoord(pos.fX, pos.fY)+fVisible.fX-fCanvas->GetWidth()/2)/fScrollVal.fX); } +#ifdef R__HAS_COCOA + UpdateRegion(0, 0, fCanvas->GetWidth(), fCanvas->GetHeight()); +#else h = UInt_t(fCanvas->GetHeight() - ToScrYCoord(fCurrent.fY)); - gVirtualX->CopyArea(fCanvas->GetId(), fCanvas->GetId(), fNormGC(), 0, Int_t(pos2.fY), fWidth, h, 0, (Int_t)ToScrYCoord(fCurrent.fY)); if (ToScrYCoord(pos.fY) < 0) { SetVsbPosition(fVisible.fY/fScrollVal.fY-1); } UpdateRegion(0, (Int_t)ToScrYCoord(pos.fY), fCanvas->GetWidth(), h); +#endif SetSBRange(kVertical); SetSBRange(kHorizontal); } } + SetCurrent(pos); } @@ -1882,6 +1904,9 @@ void TGTextEdit::BreakLine() TGLongPosition pos; fText->BreakLine(fCurrent); if (ToScrYCoord(fCurrent.fY+2) <= (Int_t)fCanvas->GetHeight()) { +#ifdef R__HAS_COCOA + UpdateRegion(0, (Int_t)ToScrYCoord(fCurrent.fY + 1), fCanvas->GetWidth(), fCanvas->GetHeight()); +#else gVirtualX->CopyArea(fCanvas->GetId(), fCanvas->GetId(), fNormGC(), 0, (Int_t)ToScrYCoord(fCurrent.fY+1), fCanvas->GetWidth(), UInt_t(fCanvas->GetHeight()-(ToScrYCoord(fCurrent.fY+2)- @@ -1889,7 +1914,7 @@ void TGTextEdit::BreakLine() 0, (Int_t)ToScrYCoord(fCurrent.fY+2)); UpdateRegion(0, (Int_t)ToScrYCoord(fCurrent.fY), fCanvas->GetWidth(), UInt_t(ToScrYCoord(fCurrent.fY+2) - ToScrYCoord(fCurrent.fY))); - +#endif if (fVisible.fX != 0) { SetHsbPosition(0); } @@ -2171,7 +2196,7 @@ const TGGC &TGTextEdit::GetCursor1GC() } //______________________________________________________________________________ -void TGTextEdit::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGTextEdit::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Save a text edit widget as a C++ statement(s) on output stream out @@ -2179,20 +2204,20 @@ void TGTextEdit::SavePrimitive(ostream &out, Option_t *option /*= ""*/) out << " TGTextEdit *"; out << GetName() << " = new TGTextEdit(" << fParent->GetName() << "," << GetWidth() << "," << GetHeight() - << ");"<< endl; + << ");"<< std::endl; if (option && strstr(option, "keep_names")) - out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << endl; + out << " " << GetName() << "->SetName(\"" << GetName() << "\");" << std::endl; if (IsReadOnly()) { - out << " " << GetName() << "->SetReadOnly(kTRUE);" << endl; + out << " " << GetName() << "->SetReadOnly(kTRUE);" << std::endl; } if (!IsMenuEnabled()) { - out << " " << GetName() << "->EnableMenu(kFALSE);" << endl; + out << " " << GetName() << "->EnableMenu(kFALSE);" << std::endl; } if (fCanvas->GetBackground() != TGFrame::fgWhitePixel) { - out << " " << GetName() << "->ChangeBackground(" << fCanvas->GetBackground() << ");" << endl; + out << " " << GetName() << "->ChangeBackground(" << fCanvas->GetBackground() << ");" << std::endl; } TGText *txt = GetText(); @@ -2206,5 +2231,5 @@ void TGTextEdit::SavePrimitive(ostream &out, Option_t *option /*= ""*/) fn = TString::Format("Txt%s", GetName()+5); txt->Save(fn.Data()); } - out << " " << GetName() << "->LoadFile(" << quote << fn.Data() << quote << ");" << endl; + out << " " << GetName() << "->LoadFile(" << quote << fn.Data() << quote << ");" << std::endl; } diff --git a/gui/gui/src/TGTextEditDialogs.cxx b/gui/gui/src/TGTextEditDialogs.cxx index a34e60e2ae536..2e846657b5aad 100644 --- a/gui/gui/src/TGTextEditDialogs.cxx +++ b/gui/gui/src/TGTextEditDialogs.cxx @@ -439,7 +439,7 @@ void TGPrintDialog::GetPrinters() TObject *obj; Int_t idx = 1, dflt =1; - if (gVirtualX->InheritsFrom("TGX11")) { + if (gVirtualX->InheritsFrom("TGX11") || gVirtualX->InheritsFrom("TGCocoa")) { char *lpstat = gSystem->Which(gSystem->Getenv("PATH"), "lpstat", kExecutePermission); if (lpstat == 0) return; diff --git a/gui/gui/src/TGTextEditor.cxx b/gui/gui/src/TGTextEditor.cxx index a742a45cfc8ae..71e6cb0ec590a 100644 --- a/gui/gui/src/TGTextEditor.cxx +++ b/gui/gui/src/TGTextEditor.cxx @@ -439,7 +439,7 @@ void TGTextEditor::Build() fStatusBar->SetParts(parts, 2); AddFrame(fStatusBar, new TGLayoutHints(kLHintsBottom | kLHintsExpandX, 0, 0, 3, 0)); - SetClassHints("TGTextEditor", "TGTextEditor"); + SetClassHints("ROOT", "TGTextEditor"); SetWindowName("Untitled - TGTextEditor"); fMacro = 0; @@ -476,7 +476,7 @@ void TGTextEditor::Build() //______________________________________________________________________________ void TGTextEditor::DataDropped(char *fname) { - // Update file informations when receiving the signal + // Update file information when receiving the signal // DataDropped from TGTextEdit widget. TString tmp; diff --git a/gui/gui/src/TGTextEntry.cxx b/gui/gui/src/TGTextEntry.cxx index c652cddd26e0c..2441d1627b972 100644 --- a/gui/gui/src/TGTextEntry.cxx +++ b/gui/gui/src/TGTextEntry.cxx @@ -328,7 +328,7 @@ void TGTextEntry::Init() fSelbackGC = GetDefaultSelectedBackgroundGC()(); fOffset = 0; - // Set default maximum lenght to 4096. Can be changed with SetMaxLength() + // Set default maximum length to 4096. Can be changed with SetMaxLength() fMaxLen = 4096; fFrameDrawn = kTRUE; fEdited = kFALSE; diff --git a/gui/gui/src/TGView.cxx b/gui/gui/src/TGView.cxx index 4b20dd88ab058..a7e63537f2384 100644 --- a/gui/gui/src/TGView.cxx +++ b/gui/gui/src/TGView.cxx @@ -270,19 +270,11 @@ void TGView::DoRedraw() DrawBorder(); -#ifdef R__HAS_COCOA - //It can happen, that TGView::DoRedraw is called outside - //of QuartzView's drawRect (drawRect also sets fExposedRegion). - //In this case, TGView's content will be lost. - //TODO: This is non-optimal solution. - DrawRegion(0, 0, GetWidth(), GetHeight()); -#else if (!fExposedRegion.IsEmpty()) { DrawRegion(fExposedRegion.fX, fExposedRegion.fY, fExposedRegion.fW, fExposedRegion.fH); fExposedRegion.Empty(); } -#endif } //______________________________________________________________________________ diff --git a/gui/gui/src/TGuiBuilder.cxx b/gui/gui/src/TGuiBuilder.cxx index c461ac60c5b4f..fd7aebacc4ad1 100644 --- a/gui/gui/src/TGuiBuilder.cxx +++ b/gui/gui/src/TGuiBuilder.cxx @@ -48,7 +48,7 @@ // // o Click left mouse button or Ctrl-Click to select an object to edit. // o Press right mouse button to activate context menu -// o Mutiple selection (grabbing): +// o Multiple selection (grabbing): // - draw lasso and press Return key // - press Shift key and draw lasso // o Dropping: diff --git a/gui/gui/src/TRootBrowser.cxx b/gui/gui/src/TRootBrowser.cxx index 3dc8c2a2d402d..afe606c67d4d1 100644 --- a/gui/gui/src/TRootBrowser.cxx +++ b/gui/gui/src/TRootBrowser.cxx @@ -1,4 +1,4 @@ -// @(#)root/gui:$Id$ +// @(#)root/gui:$Id: 4ed8aea02c288ef2cae232094ae0b155c9a799df $ // Author: Bertrand Bellenot 26/09/2007 /************************************************************************* @@ -70,12 +70,13 @@ #include "TEnv.h" #include <KeySymbols.h> +#include "RConfigure.h" + #include "TRootBrowser.h" #include "TGFileBrowser.h" #include "TGInputDialog.h" #include "TRootHelpDialog.h" #include "HelpText.h" - #include "Getline.h" #ifdef WIN32 @@ -94,28 +95,6 @@ static const char *gPluginFileTypes[] = { 0, 0 }; -enum ENewBrowserMessages { - kBrowse = 11011, - kOpenFile, - kClone, - kHelpAbout, - kHelpOnBrowser, - kHelpOnCanvas, - kHelpOnMenus, - kHelpOnGraphicsEd, - kHelpOnObjects, - kHelpOnPS, - kHelpOnRemote, - kNewEditor, - kNewCanvas, - kNewHtml, - kExecPluginMacro, - kExecPluginCmd, - kCloseTab, - kCloseWindow, - kQuitRoot -}; - //_____________________________________________________________________________ // // TRootBrowser @@ -134,6 +113,7 @@ TRootBrowser::TRootBrowser(TBrowser *b, const char *name, UInt_t width, fShowCloseTab = kTRUE; fActBrowser = 0; + fIconPic = 0; CreateBrowser(name); Resize(width, height); if (initshow) { @@ -153,6 +133,7 @@ TRootBrowser::TRootBrowser(TBrowser *b, const char *name, Int_t x, Int_t y, fShowCloseTab = kTRUE; fActBrowser = 0; + fIconPic = 0; CreateBrowser(name); MoveResize(x, y, width, height); SetWMPosition(x, y); @@ -238,7 +219,11 @@ void TRootBrowser::CreateBrowser(const char *name) fHf = new TGHorizontalFrame(fVf, 100, 100); // Tabs & co... +#if defined(R__HAS_COCOA) + fV1 = new TGVerticalFrame(fHf, 252, 100, kFixedWidth); +#else fV1 = new TGVerticalFrame(fHf, 250, 100, kFixedWidth); +#endif fV2 = new TGVerticalFrame(fHf, 600, 100); fH1 = new TGHorizontalFrame(fV2, 100, 100); fH2 = new TGHorizontalFrame(fV2, 100, 100, kFixedHeight); @@ -296,7 +281,8 @@ void TRootBrowser::CreateBrowser(const char *name) // Set a name to the main frame SetWindowName(name); SetIconName(name); - SetClassHints("Browser", "Browser"); + fIconPic = SetIconPixmap("rootdb_s.xpm"); + SetClassHints("ROOT", "Browser"); if (!strcmp(gROOT->GetDefCanvasName(), "c1")) gROOT->SetDefCanvasName("Canvas_1"); @@ -314,6 +300,7 @@ TRootBrowser::~TRootBrowser() { // Clean up all widgets, frames and layouthints that were used + if (fIconPic) gClient->FreePicture(fIconPic); delete fLH0; delete fLH1; delete fLH2; @@ -780,7 +767,7 @@ void TRootBrowser::HandleMenu(Int_t id) } break; case kCloseTab: - RemoveTab(kRight, fTabRight->GetCurrent()); + CloseTab(fTabRight->GetCurrent()); break; case kCloseWindow: CloseWindow(); diff --git a/gui/gui/src/TRootBrowserLite.cxx b/gui/gui/src/TRootBrowserLite.cxx index b9c0b7354930d..b4febfa393755 100644 --- a/gui/gui/src/TRootBrowserLite.cxx +++ b/gui/gui/src/TRootBrowserLite.cxx @@ -1,4 +1,4 @@ -// @(#)root/gui:$Id$ +// @(#)root/gui:$Id: b9c0b7354930d42a39f3e13f72c5f3f75313a2c6 $ // Author: Fons Rademakers 27/02/98 /************************************************************************* @@ -661,7 +661,6 @@ void TRootIconBox::AddObjItem(const char *name, TObject *obj, TClass *cl) fi->SetUserData(obj); AddItem(fi); - fTotal++; return; } @@ -1214,7 +1213,7 @@ void TRootBrowserLite::CreateBrowser(const char *name) SetWindowName(bname.Data()); SetIconName(bname.Data()); fIconPic = SetIconPixmap("rootdb_s.xpm"); - SetClassHints("Browser", "Browser"); + SetClassHints("ROOT", "Browser"); SetWMSizeHints(600, 350, 10000, 10000, 2, 2); diff --git a/gui/gui/src/TRootCanvas.cxx b/gui/gui/src/TRootCanvas.cxx index e2b9d691da5c0..d32c7ad69032e 100644 --- a/gui/gui/src/TRootCanvas.cxx +++ b/gui/gui/src/TRootCanvas.cxx @@ -163,6 +163,7 @@ static const char *gSaveAsTypes[] = { "PostScript", "*.ps", "Encapsulated PostScript", "*.eps", "PDF", "*.pdf", "SVG", "*.svg", + "TeX", "*.tex", "GIF", "*.gif", "ROOT macros", "*.C", "ROOT files", "*.root", @@ -578,7 +579,7 @@ void TRootCanvas::CreateCanvas(const char *name) SetWindowName(name); SetIconName(name); fIconPic = SetIconPixmap("macro_s.xpm"); - SetClassHints("Canvas", "Canvas"); + SetClassHints("ROOT", "Canvas"); SetEditDisabled(kEditDisable); MapSubwindows(); @@ -841,6 +842,7 @@ Bool_t TRootCanvas::ProcessMessage(Long_t msg, Long_t parm1, Long_t) fn.EndsWith(".eps") || fn.EndsWith(".pdf") || fn.EndsWith(".svg") || + fn.EndsWith(".tex") || fn.EndsWith(".gif") || fn.EndsWith(".xml") || fn.EndsWith(".xpm") || diff --git a/gui/gui/src/TRootContextMenu.cxx b/gui/gui/src/TRootContextMenu.cxx index 229ea59028a0b..39f86d14de047 100644 --- a/gui/gui/src/TRootContextMenu.cxx +++ b/gui/gui/src/TRootContextMenu.cxx @@ -48,6 +48,7 @@ #include "TClassMenuItem.h" #include "TObjectSpy.h" #include "KeySymbols.h" +#include "RConfigure.h" enum EContextMenu { kToggleStart = 1000, // first id of toggle menu items @@ -116,6 +117,23 @@ void TRootContextMenu::DisplayPopup(Int_t x, Int_t y) xx = topx + x + 1; yy = topy + y + 1; + +#ifdef R__HAS_COCOA + //Context menu must be transient for a canvas, otherwise it's possible + //to break the z-order (for example, using alt-tab to switch between + //different aplications). This hint works ONLY for canvas though + //(otherwise selected canvas is null). + TGWindow *parent = 0; + if (TVirtualPad *pad = fContextMenu->GetSelectedCanvas()) + parent = dynamic_cast<TGWindow *>(pad->GetCanvasImp()); + else if ((pad = fContextMenu->GetSelectedPad()) && pad->GetCanvasImp()) + parent = dynamic_cast<TGWindow *>(pad->GetCanvasImp()); + else if (TBrowser * const browser = fContextMenu->GetBrowser()) + parent = dynamic_cast<TGWindow *>(browser->GetBrowserImp()); + + if (parent) + gVirtualX->SetWMTransientHint(GetId(), parent->GetId()); +#endif PlaceMenu(xx, yy, kTRUE, kTRUE); // add some space for the right-side '?' (help) @@ -350,6 +368,7 @@ void TRootContextMenu::CreateMenu(TObject *object) break; case TClassMenuItem::kPopupUserFunction: { + const char* menuItemTitle = menuItem->GetTitle(); if (menuItem->IsToggle()) { TMethod* method = object->IsA()->GetMethodWithPrototype(menuItem->GetFunctionName(),menuItem->GetArgs()); @@ -359,11 +378,11 @@ void TRootContextMenu::CreateMenu(TObject *object) t->SetOnValue(1); fTrash->Add(t); - AddEntry(method->GetName(), toggle++, t); + if (strlen(menuItemTitle)==0) menuItemTitle = method->GetName(); + AddEntry(menuItemTitle, toggle++, t); if (t->GetState()) CheckEntry(toggle-1); } } else { - const char* menuItemTitle = menuItem->GetTitle(); if (strlen(menuItemTitle)==0) menuItemTitle = menuItem->GetFunctionName(); AddEntry(menuItemTitle,userfunction++,menuItem); } diff --git a/gui/gui/src/TRootDialog.cxx b/gui/gui/src/TRootDialog.cxx index a006af7ecb85c..8ab31c692d0be 100644 --- a/gui/gui/src/TRootDialog.cxx +++ b/gui/gui/src/TRootDialog.cxx @@ -77,7 +77,10 @@ void TRootDialog::Add(const char *argname, const char *value, const char *type) // Add a label and text input field. TGLabel *l = new TGLabel(this, argname); - TGTextBuffer *b = new TGTextBuffer(20); b->AddText(0, value); + TString svalue(value); + // keep double backslashes (e.g. in case of LateX formatting, like \\gamma) + svalue.ReplaceAll("\\", "\\\\"); + TGTextBuffer *b = new TGTextBuffer(20); b->AddText(0, svalue.Data()); TGTextEntry *t = new TGTextEntry(this, b); t->Connect("TabPressed()", "TRootDialog", this, "TabPressed()"); diff --git a/gui/guibuilder/src/TGuiBldDragManager.cxx b/gui/guibuilder/src/TGuiBldDragManager.cxx index e93b785f91418..3e214f8dad9b8 100644 --- a/gui/guibuilder/src/TGuiBldDragManager.cxx +++ b/gui/guibuilder/src/TGuiBldDragManager.cxx @@ -315,11 +315,12 @@ void TGuiBldMenuDialog::Build() while ((argument = (TMethodArg *) next())) { // Do not input argument for self object if (selfobjpos != argpos) { - const char *argname = CreateArgumentTitle(argument).Data(); - const char *type = argument->GetTypeName(); - TDataType *datatype = gROOT->GetType(type); - const char *charstar = "char*"; - char basictype[32]; + TString arg_name = CreateArgumentTitle(argument); + const char *argname = arg_name.Data(); + const char *type = argument->GetTypeName(); + TDataType *datatype = gROOT->GetType(type); + const char *charstar = "char*"; + char basictype[32]; if (datatype) { strlcpy(basictype, datatype->GetTypeName(), sizeof(basictype)); @@ -5472,7 +5473,7 @@ void TGuiBldDragManager::AddClassMenuMethods(TGPopupMenu *menu, TObject *object) //______________________________________________________________________________ void TGuiBldDragManager::DoClassMenu(Int_t id) { - // Process a method choosen via frame context menu + // Process a method chosen via frame context menu if (!fFrameMenu || ((id != kMethodMenuAct) && (id != kToggleMenuAct))) { return; @@ -5734,7 +5735,7 @@ void TGuiBldDragManager::Menu4Frame(TGFrame *frame, Int_t x, Int_t y) fPimpl->fLastPopupAction = kNoneAct; fPimpl->fPlacePopup = kTRUE; - fFrameMenu->PlaceMenu(x, y, kFALSE, kTRUE); + fFrameMenu->PlaceMenu(x, y, kTRUE, kTRUE); } //______________________________________________________________________________ @@ -5773,7 +5774,7 @@ void TGuiBldDragManager::Menu4Lasso(Int_t x, Int_t y) fPimpl->fLastPopupAction = kNoneAct; fPimpl->fPlacePopup = kTRUE; - fLassoMenu->PlaceMenu(x, y, kFALSE, kTRUE); + fLassoMenu->PlaceMenu(x, y, kTRUE, kTRUE); } //______________________________________________________________________________ diff --git a/gui/guibuilder/src/TRootGuiBuilder.cxx b/gui/guibuilder/src/TRootGuiBuilder.cxx index f08996110a430..5b76c12186270 100644 --- a/gui/guibuilder/src/TRootGuiBuilder.cxx +++ b/gui/guibuilder/src/TRootGuiBuilder.cxx @@ -1,4 +1,4 @@ -// @(#)root/guibuilder:$Id$ +// @(#)root/guibuilder:$Id: d2f0a1966f9911570cafe9d356f2158a2773edd1 $ // Author: Valeriy Onuchin 12/09/04 /************************************************************************* @@ -83,7 +83,7 @@ // // o Click left mouse button or Ctrl-Click to select an object to edit. // o Press right mouse button to activate context menu -// o Mutiple selection (grabbing): +// o Multiple selection (grabbing): // - draw lasso and press Return key // - press Shift key and draw lasso // o Dropping: @@ -133,7 +133,7 @@ const char gHelpBuilder[] = "\ \n\ o Press left mouse button Click or Ctrl-Click to select an object.\n\ o Press right mouse button to activate context menu\n\ - o Mutiple selection can be done in two ways (grabbing):\n\ + o Multiple selection can be done in two ways (grabbing):\n\ - draw lasso and press Return key\n\ - press Shift key and draw lasso\n\ o Dropping:\n\ @@ -166,7 +166,7 @@ const char gHelpBuilder[] = "\ o Ctrl-Z - undo last action (not implemented)\n\ o Shift-Ctrl-Z - redo (not implemented)\n\ \n\ - More informations\n\ + More information\n\ ************************************************\n\ \n\ For more information, please see the GuiBuilder Howto page at:\n\ @@ -906,7 +906,7 @@ TRootGuiBuilder::TRootGuiBuilder(const TGWindow *p) : TGuiBuilder(), SetWindowName("ROOT GuiBuilder"); SetIconName("ROOT GuiBuilder"); fIconPic = SetIconPixmap("bld_rgb.xpm"); - SetClassHints("GuiBuilder", "GuiBuilder"); + SetClassHints("ROOT", "GuiBuilder"); fSelected = 0; Update(); diff --git a/gui/guihtml/inc/TGHtml.h b/gui/guihtml/inc/TGHtml.h index d7af1353a1e9a..e0e4cd81f6abd 100755 --- a/gui/guihtml/inc/TGHtml.h +++ b/gui/guihtml/inc/TGHtml.h @@ -150,7 +150,7 @@ struct SHtmlStyle_t { signed int fSubscript : 4; // Positive for <sup>, negative for <sub> unsigned int fAlign : 2; // Horizontal alignment unsigned int fBgcolor : 6; // Background color - unsigned int fExpbg : 1; // Set to 1 if bgcolor explicitely set + unsigned int fExpbg : 1; // Set to 1 if bgcolor explicitly set unsigned int fFlags : 7; // the STY_ flags below }; diff --git a/gui/qtgsi/inc/TQApplication.h b/gui/qtgsi/inc/TQApplication.h index 0a5e5807710b5..70262f52cef6c 100644 --- a/gui/qtgsi/inc/TQApplication.h +++ b/gui/qtgsi/inc/TQApplication.h @@ -16,7 +16,7 @@ // // TQApplication // -// This class creates ROOT environement that will +// This class creates ROOT environment that will // interface with the Qt windowing system eventloop and eventhandlers. // This class will be instantiated once (singleton) in a main() // program. @@ -39,7 +39,7 @@ class TQApplication : public TApplication { virtual void LoadGraphicsLibs(); void SetCustomized(); - ClassDef(TQApplication,0) //creates ROOT environement with the Qt windowing system + ClassDef(TQApplication,0) //creates ROOT environment with the Qt windowing system }; #endif diff --git a/gui/qtgsi/inc/TQRootApplication.h b/gui/qtgsi/inc/TQRootApplication.h index c8436dd90b05f..8d6d2036df61f 100644 --- a/gui/qtgsi/inc/TQRootApplication.h +++ b/gui/qtgsi/inc/TQRootApplication.h @@ -16,7 +16,7 @@ // // TQRootApplication // -// This class creates Qt environement that will +// This class creates Qt environment that will // interface with the ROOT windowing system eventloop and eventhandlers, // via a polling mechanism. // @@ -58,7 +58,7 @@ public slots: void Quit(); public: - ClassDef(TQRootApplication,1) //creates Qt environement interface with the ROOT windowing system + ClassDef(TQRootApplication,1) //creates Qt environment interface with the ROOT windowing system }; #endif diff --git a/gui/qtgsi/src/TQCanvasMenu.cxx b/gui/qtgsi/src/TQCanvasMenu.cxx index 143ba7793ebec..1433571eeb56b 100644 --- a/gui/qtgsi/src/TQCanvasMenu.cxx +++ b/gui/qtgsi/src/TQCanvasMenu.cxx @@ -153,6 +153,7 @@ void TQCanvasMenu::Execute(int id) // Slot defined to execute a method from a selected TObject // using TObject::Execute() function. + if (id < 0) return; QString text=""; TVirtualPad *psave = gROOT->GetSelectedPad(); diff --git a/gui/qtgsi/src/TQRootDialog.cxx b/gui/qtgsi/src/TQRootDialog.cxx index 5fe3558f22895..ad7d3727eee05 100644 --- a/gui/qtgsi/src/TQRootDialog.cxx +++ b/gui/qtgsi/src/TQRootDialog.cxx @@ -142,9 +142,11 @@ void TQRootDialog::Add(const char* argname, const char* value, const char* /*typ s = value; new QLabel(argname,fArgBox); QLineEdit* lineEdit = new QLineEdit(fArgBox); - fLineEdit->setGeometry(10,10, 130, 30); - fLineEdit->setFocus(); - fLineEdit->setText(s); + if (fLineEdit) { + fLineEdit->setGeometry(10,10, 130, 30); + fLineEdit->setFocus(); + fLineEdit->setText(s); + } fList.append( lineEdit ); } diff --git a/gui/qtgsi/test/example1/README b/gui/qtgsi/test/example1/README index bce0c3a6aa88e..d012ed8045618 100644 --- a/gui/qtgsi/test/example1/README +++ b/gui/qtgsi/test/example1/README @@ -1,7 +1,7 @@ QtROOT main application example - (Initialising both Root/Qt environement) + (Initialising both Root/Qt environment) 1. Build the example typing `make' on this directory. diff --git a/gui/qtgsi/test/example1/main.cpp b/gui/qtgsi/test/example1/main.cpp index c3ef981e00bce..ac6878de1bbe0 100644 --- a/gui/qtgsi/test/example1/main.cpp +++ b/gui/qtgsi/test/example1/main.cpp @@ -1,7 +1,7 @@ /** * Main program * -* Initialising both Root/Qt environement +* Initialising both Root/Qt environment * * Updated 10/10/01 * @authors Denis Bertini <d.bertini@gsi.de> diff --git a/gui/sessionviewer/inc/TProofProgressLog.h b/gui/sessionviewer/inc/TProofProgressLog.h index c52dc6cb225c2..235104c0586d7 100644 --- a/gui/sessionviewer/inc/TProofProgressLog.h +++ b/gui/sessionviewer/inc/TProofProgressLog.h @@ -1,4 +1,4 @@ -// @(#)root/sessionviewer:$Id$ +// @(#)root/sessionviewer:$Id: c52dc6cb225c25e34d388329d41570a484d98ce0 $ // Author: G Ganis, Aug 2005 /************************************************************************* @@ -39,7 +39,7 @@ class TGListBox; class TGSplitButton; class TGVerticalFrame; class TGCheckButton; - +class TGLabel; class TProofProgressLog : public TGTransientFrame { @@ -68,6 +68,9 @@ class TProofProgressLog : public TGTransientFrame { TGCheckButton *fRawLines; // display raw lines button TGSplitButton *fAllWorkers; // display all workers button TGVerticalFrame *fVworkers; // Vertical frame + TGLabel *fGrepLabel; // label indicating if grepping or piping + TGCheckButton *fGrepCheckCmd; // checkbox active if piping + TGCheckButton *fGrepCheckInv; // checkbox active if inverting Bool_t fFullText; // 0 - when grep was called Int_t fTextType; // Type of retrieval @@ -93,6 +96,7 @@ class TProofProgressLog : public TGTransientFrame { void Popup(); void SaveToFile(); void NoLineEntry(); + void SetGrepView(); void Select(Int_t id, Bool_t all = kTRUE); void SetUrl(const char *url) { fSessionUrl = url; } diff --git a/gui/sessionviewer/src/TProofProgressLog.cxx b/gui/sessionviewer/src/TProofProgressLog.cxx index c4b9140e298ca..fbac457e45d20 100644 --- a/gui/sessionviewer/src/TProofProgressLog.cxx +++ b/gui/sessionviewer/src/TProofProgressLog.cxx @@ -10,6 +10,7 @@ *************************************************************************/ #include "TError.h" +#include "TPRegexp.h" #include "TGFrame.h" #include "TGTextView.h" #include "TGScrollBar.h" @@ -154,7 +155,7 @@ void TProofProgressLog::Init(Int_t w, Int_t h) hflogbox->AddFrame(fSave, new TGLayoutHints(kLHintsCenterY | kLHintsRight, 4, 0, 0, 0)); fFileName = new TGTextEntry(hflogbox); fFileName->SetText("<session-tag>.log"); - hflogbox->AddFrame(fFileName, new TGLayoutHints(kLHintsCenterY | kLHintsRight)); + hflogbox->AddFrame(fFileName, new TGLayoutHints(kLHintsCenterY | kLHintsRight | kLHintsExpandX)); TGLabel *label10 = new TGLabel(hflogbox, "Save to a file:"); hflogbox->AddFrame(label10, new TGLayoutHints(kLHintsCenterY | kLHintsRight, 50, 2, 2, 2)); @@ -193,20 +194,48 @@ void TProofProgressLog::Init(Int_t w, Int_t h) vlines->AddFrame(vlines_buttons, new TGLayoutHints(kLHintsCenterY)); hflogbox->AddFrame(vlines, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2)); - //Grep controls - TGLabel *label4 = new TGLabel(hflogbox, "Grep for:"); - hflogbox->AddFrame(label4, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 5, 2, 2, 2)); - fGrepText = new TGTextEntry(hflogbox); - hflogbox->AddFrame(fGrepText, new TGLayoutHints(kLHintsCenterY | kLHintsLeft)); + // + // Lowest line, with filter (grep or cmd pipe) controls + // - fGrepButton = new TGTextButton(hflogbox, "Grep"); + TGHorizontalFrame *hfgrepbox = new TGHorizontalFrame(vtextbox, 550, 20); + + // Grep/pipe label, textbox and button + fGrepLabel = new TGLabel(hfgrepbox, ""); + hfgrepbox->AddFrame(fGrepLabel, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2)); + fGrepText = new TGTextEntry(hfgrepbox); + { + TGDimension dim = fGrepText->GetDefaultSize(); + fGrepText->SetDefaultSize(400, dim.fHeight); + } + hfgrepbox->AddFrame(fGrepText, new TGLayoutHints( kLHintsCenterY | kLHintsLeft | kLHintsExpandX)); + fGrepButton = new TGTextButton(hfgrepbox, "Filter"); fGrepButton->Connect("Clicked()", "TProofProgressLog", this, "DoLog(=kTRUE)"); - hflogbox->AddFrame(fGrepButton, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 4, 0, 0, 0)); + hfgrepbox->AddFrame(fGrepButton, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 4, 10, 0, 0)); // l r t b + + // Checkbox for inverting selection or giving a pipe command + fGrepCheckInv = new TGCheckButton(hfgrepbox, "invert match"); + fGrepCheckInv->Connect("Clicked()", "TProofProgressLog", this, "SetGrepView()"); + hfgrepbox->AddFrame(fGrepCheckInv, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2)); + + fGrepCheckCmd = new TGCheckButton(hfgrepbox, "is a pipe command"); + fGrepCheckCmd->Connect("Clicked()", "TProofProgressLog", this, "SetGrepView()"); + hfgrepbox->AddFrame(fGrepCheckCmd, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2)); - vtextbox->AddFrame(hflogbox, new TGLayoutHints(kLHintsBottom | kLHintsLeft | kLHintsExpandX, 2, 2, 2, 2)); + // fRawLines->SetToolTipText("Retrieve all type of lines, service messages included"); + // fRawLines->SetState(kButtonUp); + // vlines_buttons->AddFrame(fRawLines, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2)); + + // + // Add frames to the global picture + // + + vtextbox->AddFrame(hflogbox, new TGLayoutHints(kLHintsTop | kLHintsLeft | kLHintsExpandX, 2, 2, 2, 2)); + vtextbox->AddFrame(hfgrepbox, new TGLayoutHints(kLHintsBottom | kLHintsLeft | kLHintsExpandX, 2, 2, 2, 2)); htotal->AddFrame(vtextbox, new TGLayoutHints(kLHintsExpandX | kLHintsExpandY | kLHintsRight, 3, 3, 3, 3)); AddFrame(htotal, new TGLayoutHints(kLHintsExpandX | kLHintsExpandY, 3, 3, 3, 3)); + SetGrepView(); MapSubwindows(); Resize(); CenterOnParent(); @@ -356,7 +385,8 @@ void TProofProgressLog::BuildLogList(Bool_t create) //______________________________________________________________________________ void TProofProgressLog::DoLog(Bool_t grep) { - // Display the logs + // Display logs. 'grep' is set to kTRUE if it is invoked by pressing the + // 'Filter' button. Clear(); @@ -366,6 +396,16 @@ void TProofProgressLog::DoLog(Bool_t grep) } TString greptext = fGrepText->GetText(); + greptext.Remove(TString::kBoth, ' '); + if (greptext.IsNull()) { + grep = kFALSE; + } + else if (!fGrepCheckCmd->IsOn()) { + // Not a command: sanitize string + TPMERegexp san("(^|[^\\\\])([^a-zA-Z0-9_=\\\\/.-])"); + while (san.Substitute(greptext, "$1\\$2") > 0) { } + } + Int_t from, to; if (fAllLines->IsOn()){ from = 0; @@ -389,9 +429,18 @@ void TProofProgressLog::DoLog(Bool_t grep) } } + // Pipe command for filtering + TString pipeCommand; + + // Filter out SvcMsg + if (!fRawLines->IsOn()) { + pipeCommand = "grep -v \"| SvcMsg\""; + } + // Default is not retrieving Bool_t retrieve = kFALSE; if (!grep) { + // Not invoked via 'Filter' button if (!fFullText || ((fTextType != kRaw && fRawLines->IsOn()) || (fTextType != kStd && !fRawLines->IsOn())) || @@ -408,6 +457,21 @@ void TProofProgressLog::DoLog(Bool_t grep) } else { retrieve = kTRUE; fTextType = kGrep; + + if (!pipeCommand.IsNull()) + pipeCommand.Append('|'); + + if (fGrepCheckCmd->IsOn()) { + pipeCommand.Append(greptext); + } + else { + pipeCommand.Append("grep "); + if (fGrepCheckInv->IsOn()) + pipeCommand.Append("-v "); + pipeCommand.Append("-- "); + pipeCommand.Append(greptext); // sanitized + } + if (fDialog && fDialog->fStatus != TProofProgressDialog::kRunning) fFullText = kTRUE; } @@ -428,12 +492,17 @@ void TProofProgressLog::DoLog(Bool_t grep) Int_t is = ord.Index(" "); if (is != kNPOS) ord.Remove(is); if (retrieve || !selentry->TestBit(kLogElemFilled)) { - if (fTextType == kGrep) { - fProofLog->Retrieve(ord.Data(), TProofLog::kGrep, 0, greptext.Data()); - } else if (fTextType == kRaw) { - fProofLog->Retrieve(ord.Data(), TProofLog::kTrailing, 0, 0); - } else { - fProofLog->Retrieve(ord.Data(), TProofLog::kGrep, 0, "-v \"| SvcMsg\""); + pipeCommand.Prepend('|'); + if (fTextType == kRaw) { + if (gDebug >= 2) + Info("DoLog", "Retrieving unfiltered log for %s", ord.Data()); + fProofLog->Retrieve(ord.Data(), TProofLog::kTrailing, 0, 0); + } + else { + if (gDebug >= 2) + Info("DoLog", "Retrieving log for %s filtered with %s", + ord.Data(), pipeCommand.Data()); + fProofLog->Retrieve(ord.Data(), TProofLog::kGrep, 0, pipeCommand.Data()); } selentry->SetBit(kLogElemFilled); } @@ -496,6 +565,35 @@ void TProofProgressLog::SaveToFile() return; } +//______________________________________________________________________________ +void TProofProgressLog::SetGrepView() +{ + // Sets the view of grep filters according to the value of checkboxes + + if (fGrepCheckCmd->IsOn()) { + fGrepLabel->SetText("Pipe log through command:"); + fGrepCheckInv->SetDisabledAndSelected(kFALSE); + } + else { + fGrepLabel->SetText("Grep:"); + Bool_t u = fGrepCheckInv->IsOn(); + fGrepCheckInv->SetEnabled(kTRUE); + if (u) { + fGrepLabel->SetText("Show lines not matching:"); + fGrepCheckInv->SetState(kButtonDown); + } + else { + fGrepLabel->SetText("Show lines matching:"); + fGrepCheckInv->SetState(kButtonUp); + } + } + + // Ugly but necessary const_cast + TGFrame *frame = dynamic_cast<TGFrame *>( const_cast<TGWindow *>(fGrepLabel->GetParent()) ); + if (frame) frame->Layout(); + +} + //______________________________________________________________________________ void TProofProgressLog::NoLineEntry() { diff --git a/gui/sessionviewer/src/TSessionDialogs.cxx b/gui/sessionviewer/src/TSessionDialogs.cxx index 57081ebf1bb35..ea3beb9abe94a 100644 --- a/gui/sessionviewer/src/TSessionDialogs.cxx +++ b/gui/sessionviewer/src/TSessionDialogs.cxx @@ -1313,7 +1313,7 @@ void TUploadDataSetDlg::UploadDataSet() } else { new TGMsgBox(fClient->GetRoot(), this, "Upload DataSet", - "Files have been succesfully uploaded to the cluster", + "Files have been successfully uploaded to the cluster", kMBIconAsterisk, kMBOk, &retval); } fUploading = kFALSE; @@ -1338,7 +1338,7 @@ void TUploadDataSetDlg::UploadDataSet() } else { new TGMsgBox(fClient->GetRoot(), this, "Upload DataSet", - "Files have been succesfully uploaded to the cluster", + "Files have been successfully uploaded to the cluster", kMBIconAsterisk, kMBOk, &retval); } } @@ -1347,7 +1347,7 @@ void TUploadDataSetDlg::UploadDataSet() } else { new TGMsgBox(fClient->GetRoot(), this, "Upload DataSet", - "Files have been succesfully uploaded to the cluster", + "Files have been successfully uploaded to the cluster", kMBIconAsterisk, kMBOk, &retval); } // finally, update list of datasets in session viewer diff --git a/gui/sessionviewer/src/TSessionViewer.cxx b/gui/sessionviewer/src/TSessionViewer.cxx index 49fac9e7d1223..94d3349a9d140 100644 --- a/gui/sessionviewer/src/TSessionViewer.cxx +++ b/gui/sessionviewer/src/TSessionViewer.cxx @@ -932,7 +932,7 @@ void TSessionFrame::Build(TSessionViewer *gui) tf->AddFrame(fFC, new TGLayoutHints(kLHintsTop | kLHintsLeft | kLHintsExpandX | kLHintsExpandY)); - // add comand line label and text entry + // add command line label and text entry TGCompositeFrame* frmCmd = new TGHorizontalFrame(fFC, 350, 100); frmCmd->SetCleanup(kDeepCleanup); frmCmd->AddFrame(new TGLabel(frmCmd, "Command Line :"), @@ -1195,7 +1195,7 @@ void TSessionFrame::Build(TSessionViewer *gui) //______________________________________________________________________________ void TSessionFrame::ProofInfos() { - // Display informations on current session. + // Display information on current session. TString buf; @@ -2383,7 +2383,7 @@ TSessionQueryFrame::~TSessionQueryFrame() //______________________________________________________________________________ void TSessionQueryFrame::Build(TSessionViewer *gui) { - // Build query informations frame. + // Build query information frame. SetLayoutManager(new TGVerticalLayout(this)); SetCleanup(kDeepCleanup); @@ -2636,7 +2636,7 @@ void TSessionQueryFrame::Progress(Long64_t total, Long64_t processed) return; TString buf; - // Update informations at first call + // Update information at first call if (fEntries != total) { buf.Form("PROOF cluster : \"%s\" - %d worker nodes", fViewer->GetActDesc()->fProof->GetMaster(), @@ -2785,7 +2785,7 @@ void TSessionQueryFrame::ProgressLocal(Long64_t total, Long64_t processed) // if no change since last call, just return TString buf; - // Update informations at first call + // Update information at first call if (fEntries != total) { fLabInfos->SetText("Local Session"); @@ -3045,7 +3045,7 @@ void TSessionQueryFrame::OnBtnRetrieve() } } } - // update list tree, query frame informations, and buttons state + // update list tree, query frame information, and buttons state fViewer->GetSessionHierarchy()->ClearViewPort(); fClient->NeedRedraw(fViewer->GetSessionHierarchy()); UpdateInfos(); @@ -3087,7 +3087,7 @@ void TSessionQueryFrame::OnBtnSubmit() if (!obj || obj->IsA() != TQueryDescription::Class()) return; TQueryDescription *newquery = (TQueryDescription *)obj; - // reset progress informations + // reset progress information ResetProgressDialog(newquery->fSelectorString, newquery->fNbFiles, newquery->fFirstEntry, newquery->fNoEntries); // set query start time @@ -3581,7 +3581,7 @@ TSessionInputFrame::~TSessionInputFrame() //______________________________________________________________________________ void TSessionInputFrame::Build(TSessionViewer *gui) { - // Build query input informations frame. + // Build query input information frame. fViewer = gui; SetLayoutManager(new TGVerticalLayout(this)); @@ -3991,7 +3991,7 @@ void TSessionViewer::UpdateListOfProofs() } if (found) continue; newdesc = new TSessionDescription(); - // and fill informations from Proof session + // and fill information from Proof session newdesc->fTag = d->GetName(); newdesc->fName = d->GetTitle(); newdesc->fAddress = d->GetTitle(); @@ -4076,7 +4076,7 @@ void TSessionViewer::UpdateListOfProofs() if (found) continue; // create new session description newdesc = new TSessionDescription(); - // and fill informations from Proof session + // and fill information from Proof session newdesc->fName = proof->GetMaster(); newdesc->fConfigFile = proof->GetConfFile(); newdesc->fUserName = proof->GetUser(); @@ -4139,7 +4139,7 @@ void TSessionViewer::UpdateListOfSessions() if (found) continue; // create new session description newdesc = new TSessionDescription(); - // and fill informations from Proof session + // and fill information from Proof session newdesc->fTag = pdesc->GetName(); newdesc->fName = pdesc->GetTitle(); proof = pdesc->GetProof(); @@ -4650,7 +4650,7 @@ void TSessionViewer::OnListTreeClicked(TGListTreeItem *entry, Int_t btn, obj = (TObject *)entry->GetUserData(); if (!obj || obj->IsA() != TSessionDescription::Class()) return; - // update server frame informations + // update server frame information fServerFrame->Update((TSessionDescription *)obj); fActDesc = (TSessionDescription*)obj; // if Proof valid, update connection infos @@ -4729,7 +4729,7 @@ void TSessionViewer::OnListTreeClicked(TGListTreeItem *entry, Int_t btn, if (obj && obj->IsA() == TQueryDescription::Class()) { fActDesc->fActQuery = (TQueryDescription *)obj; } - // update query informations and buttons state + // update query information and buttons state fQueryFrame->UpdateInfos(); fQueryFrame->UpdateButtons(fActDesc->fActQuery); if (fActFrame != fQueryFrame) { @@ -5096,7 +5096,7 @@ void TSessionViewer::QueryResultReady(char *query) if (!fSessionHierarchy->FindChildByName(item2, "OutputList")) fSessionHierarchy->AddItem(item2, "OutputList"); } - // update list tree, query frame informations, and buttons state + // update list tree, query frame information, and buttons state fSessionHierarchy->ClearViewPort(); fClient->NeedRedraw(fSessionHierarchy); fQueryFrame->UpdateInfos(); diff --git a/hist/hbook/src/THbookFile.cxx b/hist/hbook/src/THbookFile.cxx index ef9fd1f83e2ff..bafecd94aa2ce 100644 --- a/hist/hbook/src/THbookFile.cxx +++ b/hist/hbook/src/THbookFile.cxx @@ -284,7 +284,7 @@ THbookFile::THbookFile(const char *fname, Int_t lrecl) char topdir[20]; snprintf(topdir,19,"lun%d",fLun); - Int_t ier; + Int_t ier = 0; #ifndef WIN32 hropen(fLun,PASSCHAR(topdir),PASSCHAR(fname),PASSCHAR("p"),lrecl,ier,strlen(topdir),strlen(fname),1); #else @@ -883,7 +883,7 @@ TObject *THbookFile::ConvertProfile(Int_t id) const Int_t kCON1 = 9; Int_t i; - Float_t x; + Float_t x = 0.; Float_t y = 0.5*(ymin+ymax); for (i=1;i<=ncx;i++) { Int_t n = Int_t(q[ln+i]); @@ -972,7 +972,7 @@ TObject *THbookFile::Convert2D(Int_t id) Int_t lw = lq[lcont]; if (lw) h2->Sumw2(); - Float_t x,y; + Float_t x = 0.,y = 0.; for (Int_t j=0;j<=ncy+1;j++) { for (Int_t i=0;i<=ncx+1;i++) { hijxy(id,i,j,x,y); diff --git a/hist/hist/inc/HFitInterface.h b/hist/hist/inc/HFitInterface.h index de941065ea15e..27ce9440a01dd 100644 --- a/hist/hist/inc/HFitInterface.h +++ b/hist/hist/inc/HFitInterface.h @@ -157,6 +157,16 @@ namespace ROOT { */ bool GetConfidenceIntervals(const TH1 * h1, const ROOT::Fit::FitResult & r, TGraphErrors * gr, double cl = 0.95); + /** + compute the chi2 value for an histogram given a function (see TH1::Chisquare for the documentation) + */ + double Chisquare(const TH1 & h1, TF1 & f1, bool useRange); + + /** + compute the chi2 value for a graph given a function (see TGraph::Chisquare) + */ + double Chisquare(const TGraph & h1, TF1 & f1, bool useRange); + } // end namespace Fit diff --git a/hist/hist/inc/TAxis.h b/hist/hist/inc/TAxis.h index b90cd8a5fc4fe..9cad5ed8e7791 100644 --- a/hist/hist/inc/TAxis.h +++ b/hist/hist/inc/TAxis.h @@ -118,7 +118,7 @@ class TAxis : public TNamed, public TAttAxis { } virtual void LabelsOption(Option_t *option="h"); // *MENU* virtual void RotateTitle(Bool_t rotate=kTRUE); // *TOGGLE* *GETTER=GetRotateTitle - virtual void SaveAttributes(ostream &out, const char *name, const char *subname); + virtual void SaveAttributes(std::ostream &out, const char *name, const char *subname); virtual void Set(Int_t nbins, Double_t xmin, Double_t xmax); virtual void Set(Int_t nbins, const Float_t *xbins); virtual void Set(Int_t nbins, const Double_t *xbins); diff --git a/hist/hist/inc/TEfficiency.h b/hist/hist/inc/TEfficiency.h index 599d615a625d9..1df138fa9b918 100644 --- a/hist/hist/inc/TEfficiency.h +++ b/hist/hist/inc/TEfficiency.h @@ -176,7 +176,7 @@ class TEfficiency: public TNamed, public TAttLine, public TAttFill, public TAttM static Double_t BetaMean(Double_t alpha,Double_t beta); static Double_t BetaMode(Double_t alpha,Double_t beta); - ClassDef(TEfficiency,1) //calculating efficiencies + ClassDef(TEfficiency,2) //calculating efficiencies }; const TEfficiency operator+(const TEfficiency& lhs,const TEfficiency& rhs); diff --git a/hist/hist/inc/TFitResult.h b/hist/hist/inc/TFitResult.h index ddc07d5377a07..8a766c2db0c8c 100644 --- a/hist/hist/inc/TFitResult.h +++ b/hist/hist/inc/TFitResult.h @@ -56,6 +56,14 @@ class TFitResult:public TNamed, public ROOT::Fit::FitResult { TMatrixDSym GetCorrelationMatrix() const; + + using TObject::Error; + + // need to re-implement to solve conflict with TObject::Error + double Error(unsigned int i) const { + return ParError(i); + } + private: ClassDef(TFitResult,1) // Class holding the result of the fit }; diff --git a/hist/hist/inc/TFractionFitter.h b/hist/hist/inc/TFractionFitter.h index 17ad75b28c5d7..a25534d8a373b 100644 --- a/hist/hist/inc/TFractionFitter.h +++ b/hist/hist/inc/TFractionFitter.h @@ -62,7 +62,7 @@ class TFractionFitter: public TObject { private: void CheckParNo(Int_t parm) const; void CheckConsistency(); - void FindPrediction(int bin, double* fractions, double& Ti, int& k0, double& Aki) const; + void FindPrediction(int bin, double& t_i, int& k_0, double& A_ki) const; void ComputeFCN(Int_t& npar, Double_t* gin, Double_t& f, Double_t* par, Int_t flag); void GetRanges(Int_t& minX, Int_t& maxX, Int_t& minY, Int_t& maxY, Int_t& minZ, Int_t& maxZ) const; diff --git a/hist/hist/inc/TGraph.h b/hist/hist/inc/TGraph.h index fa2840909c073..b0a2d14bb49b0 100644 --- a/hist/hist/inc/TGraph.h +++ b/hist/hist/inc/TGraph.h @@ -98,7 +98,7 @@ class TGraph : public TNamed, public TAttLine, public TAttFill, public TAttMarke virtual void Apply(TF1 *f); virtual void Browse(TBrowser *b); - virtual Double_t Chisquare(const TF1 *f1) const; + virtual Double_t Chisquare(const TF1 *f1, Option_t *option="") const; static Bool_t CompareArg(const TGraph* gr, Int_t left, Int_t right); static Bool_t CompareX(const TGraph* gr, Int_t left, Int_t right); static Bool_t CompareY(const TGraph* gr, Int_t left, Int_t right); diff --git a/hist/hist/inc/TGraph2D.h b/hist/hist/inc/TGraph2D.h index 86900d655b8f4..3234ec55e8cc0 100644 --- a/hist/hist/inc/TGraph2D.h +++ b/hist/hist/inc/TGraph2D.h @@ -92,6 +92,7 @@ class TGraph2D : public TNamed, public TAttLine, public TAttFill, public TAttMar TGraph2D& operator=(const TGraph2D &); + virtual void Browse(TBrowser *); virtual void Clear(Option_t *option=""); virtual void DirectoryAutoAdd(TDirectory *); Int_t DistancetoPrimitive(Int_t px, Int_t py); @@ -112,6 +113,8 @@ class TGraph2D : public TNamed, public TAttLine, public TAttFill, public TAttMar virtual Double_t GetErrorY(Int_t bin) const; virtual Double_t GetErrorZ(Int_t bin) const; Double_t GetMargin() const {return fMargin;} + Double_t GetMaximum() const {return fMaximum;}; + Double_t GetMinimum() const {return fMinimum;}; TAxis *GetXaxis() const ; TAxis *GetYaxis() const ; TAxis *GetZaxis() const ; diff --git a/hist/hist/inc/TH1.h b/hist/hist/inc/TH1.h index f72d2751fbae8..ec7603ab3d3ba 100644 --- a/hist/hist/inc/TH1.h +++ b/hist/hist/inc/TH1.h @@ -185,7 +185,8 @@ class TH1 : public TNamed, public TAttLine, public TAttFill, public TAttMarker { virtual void Browse(TBrowser *b); virtual Double_t Chi2Test(const TH1* h2, Option_t *option = "UU", Double_t *res = 0) const; virtual Double_t Chi2TestX(const TH1* h2, Double_t &chi2, Int_t &ndf, Int_t &igood,Option_t *option = "UU", Double_t *res = 0) const; - + + virtual Double_t Chisquare(TF1 * f1, Option_t *option = "") const; virtual Double_t ComputeIntegral(); virtual void DirectoryAutoAdd(TDirectory *); virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); @@ -289,6 +290,8 @@ class TH1 : public TNamed, public TAttLine, public TAttFill, public TAttMarker { virtual Int_t GetQuantiles(Int_t nprobSum, Double_t *q, const Double_t *probSum=0); virtual Double_t GetRandom() const; virtual void GetStats(Double_t *stats) const; + Double_t GetStdDev(Int_t axis=1) const { return GetRMS(axis); } + Double_t GetStdDevError(Int_t axis=1) const { return GetRMSError(axis); } virtual Double_t GetSumOfWeights() const; virtual TArrayD *GetSumw2() {return &fSumw2;} virtual const TArrayD *GetSumw2() const {return &fSumw2;} @@ -384,7 +387,7 @@ class TH1 : public TNamed, public TAttLine, public TAttFill, public TAttMarker { virtual void Smooth(Int_t ntimes=1, Option_t *option=""); // *MENU* static void SmoothArray(Int_t NN, Double_t *XX, Int_t ntimes=1); static void StatOverflows(Bool_t flag=kTRUE); - virtual void Sumw2(); + virtual void Sumw2(Bool_t flag = kTRUE); void UseCurrentStyle(); static TH1 *TransformHisto(TVirtualFFT *fft, TH1* h_output, Option_t *option); diff --git a/hist/hist/inc/TH2.h b/hist/hist/inc/TH2.h index e2766ba333d5d..9d34aa5c03e7d 100644 --- a/hist/hist/inc/TH2.h +++ b/hist/hist/inc/TH2.h @@ -53,19 +53,20 @@ class TH2 : public TH1 { TH2(const char *name,const char *title,Int_t nbinsx,const Float_t *xbins ,Int_t nbinsy,const Float_t *ybins); - virtual Int_t BufferFill(Double_t, Double_t) {return -2;} //may not use virtual Int_t BufferFill(Double_t x, Double_t y, Double_t w); virtual TH1D *DoProjection(bool onX, const char *name, Int_t firstbin, Int_t lastbin, Option_t *option) const; virtual TProfile *DoProfile(bool onX, const char *name, Int_t firstbin, Int_t lastbin, Option_t *option) const; virtual void DoFitSlices(bool onX, TF1 *f1, Int_t firstbin, Int_t lastbin, Int_t cut, Option_t *option, TObjArray* arr); + Int_t BufferFill(Double_t, Double_t) {return -2;} //may not use + Int_t Fill(Double_t); //MayNotUse + Int_t Fill(const char*, Double_t) { return Fill(0);} //MayNotUse + public: TH2(const TH2&); virtual ~TH2(); virtual Int_t BufferEmpty(Int_t action=0); virtual void Copy(TObject &hnew) const; - Int_t Fill(Double_t) {return -1;} //MayNotUse - Int_t Fill(const char*, Double_t) {return -1;} //MayNotUse virtual Int_t Fill(Double_t x, Double_t y); virtual Int_t Fill(Double_t x, Double_t y, Double_t w); virtual Int_t Fill(Double_t x, const char *namey, Double_t w); diff --git a/hist/hist/inc/TH2Poly.h b/hist/hist/inc/TH2Poly.h index 7f19b2ee30d91..4f948c24d83aa 100644 --- a/hist/hist/inc/TH2Poly.h +++ b/hist/hist/inc/TH2Poly.h @@ -116,6 +116,7 @@ class TH2Poly : public TH2 { Double_t Integral(Int_t, Int_t, const Option_t*) const{return 0;} //MayNotUse Double_t Integral(Int_t, Int_t, Int_t, Int_t, const Option_t*) const{return 0;} //MayNotUse Double_t Integral(Int_t, Int_t, Int_t, Int_t, Int_t, Int_t, const Option_t*) const{return 0;} //MayNotUse + Long64_t Merge(TCollection *); void Reset(Option_t *option); void SavePrimitive(ostream& out, Option_t* option = ""); void SetBinContent(Int_t bin, Double_t content); diff --git a/hist/hist/inc/TH3.h b/hist/hist/inc/TH3.h index f873c4fe08554..3a8a43c488f21 100644 --- a/hist/hist/inc/TH3.h +++ b/hist/hist/inc/TH3.h @@ -53,23 +53,24 @@ class TH3 : public TH1, public TAtt3D { TH3(const char *name,const char *title,Int_t nbinsx,const Double_t *xbins ,Int_t nbinsy,const Double_t *ybins ,Int_t nbinsz,const Double_t *zbins); - virtual Int_t BufferFill(Double_t, Double_t) {return -2;} //may not use - virtual Int_t BufferFill(Double_t, Double_t, Double_t) {return -2;} //may not use virtual Int_t BufferFill(Double_t x, Double_t y, Double_t z, Double_t w); void DoFillProfileProjection(TProfile2D * p2, const TAxis & a1, const TAxis & a2, const TAxis & a3, Int_t bin1, Int_t bin2, Int_t bin3, Int_t inBin, Bool_t useWeights) const; + virtual Int_t BufferFill(Double_t, Double_t) {return -2;} //may not use + virtual Int_t BufferFill(Double_t, Double_t, Double_t) {return -2;} //may not use + Int_t Fill(Double_t); //MayNotUse + Int_t Fill(Double_t,Double_t) {return Fill(0.);} //MayNotUse + Int_t Fill(const char*, Double_t) {return Fill(0);} //MayNotUse + Int_t Fill(Double_t,const char*,Double_t) {return Fill(0);} //MayNotUse + Int_t Fill(const char*,Double_t,Double_t) {return Fill(0);} //MayNotUse + Int_t Fill(const char*,const char*,Double_t) {return Fill(0);} //MayNotUse + public: TH3(const TH3&); virtual ~TH3(); virtual Int_t BufferEmpty(Int_t action=0); virtual void Copy(TObject &hnew) const; - Int_t Fill(Double_t) {return -1;} //MayNotUse - Int_t Fill(Double_t,Double_t) {return -1;} //MayNotUse - Int_t Fill(const char*, Double_t) {return -1;} //MayNotUse - Int_t Fill(Double_t,const char*,Double_t) {return -1;} //MayNotUse - Int_t Fill(const char*,Double_t,Double_t) {return -1;} //MayNotUse - Int_t Fill(const char*,const char*,Double_t) {return -1;} //MayNotUse virtual Int_t Fill(Double_t x, Double_t y, Double_t z); virtual Int_t Fill(Double_t x, Double_t y, Double_t z, Double_t w); diff --git a/hist/hist/inc/TMultiGraph.h b/hist/hist/inc/TMultiGraph.h index 8fd26283083bf..b0fe9547308a1 100644 --- a/hist/hist/inc/TMultiGraph.h +++ b/hist/hist/inc/TMultiGraph.h @@ -56,8 +56,8 @@ class TMultiGraph : public TNamed { virtual void Browse(TBrowser *b); virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); virtual void Draw(Option_t *chopt=""); - virtual TFitResultPtr Fit(const char *formula ,Option_t *option="" ,Option_t *goption="", Axis_t xmin=0, Axis_t xmax=0); - virtual TFitResultPtr Fit(TF1 *f1 ,Option_t *option="" ,Option_t *goption="", Axis_t rxmin=0, Axis_t rxmax=0); + virtual TFitResultPtr Fit(const char *formula ,Option_t *option="" ,Option_t *goption="", Axis_t xmin=0, Axis_t xmax=0); + virtual TFitResultPtr Fit(TF1 *f1 ,Option_t *option="" ,Option_t *goption="", Axis_t rxmin=0, Axis_t rxmax=0); virtual void FitPanel(); // *MENU* virtual Option_t *GetGraphDrawOption(const TGraph *gr) const; virtual void LeastSquareLinearFit(Int_t ndata, Double_t &a0, Double_t &a1, Int_t &ifail, Double_t xmin, Double_t xmax); @@ -70,7 +70,7 @@ class TMultiGraph : public TNamed { TF1 *GetFunction(const char *name) const; TList *GetListOfGraphs() const { return fGraphs; } TList *GetListOfFunctions(); // non const method (create list if empty) - const TList *GetListOfFunctions() const { return fFunctions; } + const TList *GetListOfFunctions() const { return fFunctions; } TAxis *GetXaxis() const; TAxis *GetYaxis() const; virtual void Paint(Option_t *chopt=""); @@ -80,7 +80,7 @@ class TMultiGraph : public TNamed { virtual void SavePrimitive(ostream &out, Option_t *option = ""); virtual void SetMaximum(Double_t maximum=-1111); virtual void SetMinimum(Double_t minimum=-1111); - + ClassDef(TMultiGraph,2) //A collection of TGraph objects }; diff --git a/hist/hist/inc/TProfile.h b/hist/hist/inc/TProfile.h index 5326734b88fb5..7bae33ff7684c 100644 --- a/hist/hist/inc/TProfile.h +++ b/hist/hist/inc/TProfile.h @@ -128,9 +128,10 @@ static Bool_t fgApproximate; //bin error approximation option virtual void SetBinEntries(Int_t bin, Double_t w); virtual void SetBins(Int_t nbins, Double_t xmin, Double_t xmax); virtual void SetBins(Int_t nx, const Double_t *xbins); + virtual void SetBinsLength(Int_t n=-1); virtual void SetBuffer(Int_t buffersize, Option_t *option=""); virtual void SetErrorOption(Option_t *option=""); // *MENU* - virtual void Sumw2(); + virtual void Sumw2(Bool_t flag = kTRUE); ClassDef(TProfile,6) //Profile histogram class }; diff --git a/hist/hist/inc/TProfile2D.h b/hist/hist/inc/TProfile2D.h index a881f2176be45..aa2e8c7826a7e 100644 --- a/hist/hist/inc/TProfile2D.h +++ b/hist/hist/inc/TProfile2D.h @@ -53,6 +53,10 @@ class TProfile2D : public TH2D { nbins[1], range[2], range[3]); }; Int_t Fill(const Double_t* v) { return Fill(v[0], v[1], v[2], v[3]); }; + using TH2::Fill; + Int_t Fill(Double_t, Double_t) {return TH2::Fill(0); } //MayNotUse + + private: Double_t *GetB() {return &fBinEntries.fArray[0];} Double_t *GetB2() {return (fBinSumw2.fN ? &fBinSumw2.fArray[0] : 0 ); } @@ -93,9 +97,6 @@ class TProfile2D : public TH2D { virtual Bool_t Divide(const TH1 *h1); virtual Bool_t Divide(const TH1 *h1, const TH1 *h2, Double_t c1=1, Double_t c2=1, Option_t *option=""); // *MENU* virtual TH1 *DrawCopy(Option_t *option="") const; - Int_t Fill(Double_t) {return -1;} //MayNotUse - Int_t Fill(const char*, Double_t) {return -1;} //MayNotUse - Int_t Fill(Double_t, Double_t) {return -1; } //MayNotUse Int_t Fill(Double_t x, Double_t y, Double_t z); virtual Int_t Fill(Double_t x, const char *namey, Double_t z); virtual Int_t Fill(const char *namex, Double_t y, Double_t z); @@ -134,9 +135,10 @@ class TProfile2D : public TH2D { virtual void SetBinEntries(Int_t bin, Double_t w); virtual void SetBins(Int_t nbinsx, Double_t xmin, Double_t xmax, Int_t nbinsy, Double_t ymin, Double_t ymax); virtual void SetBins(Int_t nx, const Double_t *xBins, Int_t ny, const Double_t *yBins); + virtual void SetBinsLength(Int_t n=-1); virtual void SetBuffer(Int_t buffersize, Option_t *option=""); virtual void SetErrorOption(Option_t *option=""); // *MENU* - virtual void Sumw2(); + virtual void Sumw2(Bool_t flag = kTRUE); ClassDef(TProfile2D,7) //Profile2D histogram class }; diff --git a/hist/hist/inc/TProfile3D.h b/hist/hist/inc/TProfile3D.h index 2e652a1373b85..f01ffe8047a8d 100644 --- a/hist/hist/inc/TProfile3D.h +++ b/hist/hist/inc/TProfile3D.h @@ -54,6 +54,17 @@ class TProfile3D : public TH3D { nbins[1], range[2], range[3], nbins[2], range[4], range[5]); }; Int_t Fill(const Double_t* v) { return Fill(v[0], v[1], v[2], v[3], v[4]); }; + + + using TH3::Fill; + Int_t Fill(Double_t, Double_t,Double_t) {return TH3::Fill(0); } //MayNotUse + Int_t Fill(const char *, const char *, const char *, Double_t) {return TH3::Fill(0); } //MayNotUse + Int_t Fill(const char *, Double_t , const char *, Double_t) {return TH3::Fill(0); } //MayNotUse + Int_t Fill(const char *, const char *, Double_t, Double_t) {return TH3::Fill(0); } //MayNotUse + Int_t Fill(Double_t, const char *, const char *, Double_t) {return TH3::Fill(0); } //MayNotUse + Int_t Fill(Double_t, const char *, Double_t, Double_t) {return TH3::Fill(0); } //MayNotUse + Int_t Fill(Double_t, Double_t, const char *, Double_t) {return TH3::Fill(0); } //MayNotUse + private: Double_t *GetB() {return &fBinEntries.fArray[0];} @@ -90,16 +101,6 @@ class TProfile3D : public TH3D { virtual Bool_t Divide(const TH1 *h1); virtual Bool_t Divide(const TH1 *h1, const TH1 *h2, Double_t c1=1, Double_t c2=1, Option_t *option=""); // *MENU* virtual TH1 *DrawCopy(Option_t *option="") const; - Int_t Fill(Double_t) {return -1;} //MayNotUse - Int_t Fill(const char*, Double_t) {return -1;} //MayNotUse - Int_t Fill(Double_t, Double_t) {return -1; } //MayNotUse - Int_t Fill(Double_t, Double_t,Double_t) {return -1; } //MayNotUse - Int_t Fill(const char *, const char *, const char *, Double_t) {return -1; } //MayNotUse - Int_t Fill(const char *, Double_t , const char *, Double_t) {return -1; } //MayNotUse - Int_t Fill(const char *, const char *, Double_t, Double_t) {return -1; } //MayNotUse - Int_t Fill(Double_t, const char *, const char *, Double_t) {return -1; } //MayNotUse - Int_t Fill(Double_t, const char *, Double_t, Double_t) {return -1; } //MayNotUse - Int_t Fill(Double_t, Double_t, const char *, Double_t) {return -1; } //MayNotUse virtual Int_t Fill(Double_t x, Double_t y, Double_t z, Double_t t); virtual Int_t Fill(Double_t x, Double_t y, Double_t z, Double_t t, Double_t w); virtual Double_t GetBinContent(Int_t bin) const; @@ -134,9 +135,10 @@ class TProfile3D : public TH3D { Int_t nbinsz, Double_t zmin, Double_t zmax); virtual void SetBins(Int_t nx, const Double_t *xBins, Int_t ny, const Double_t * yBins, Int_t nz, const Double_t *zBins); + virtual void SetBinsLength(Int_t n=-1); virtual void SetBuffer(Int_t buffersize, Option_t *opt=""); virtual void SetErrorOption(Option_t *option=""); // *MENU* - virtual void Sumw2(); + virtual void Sumw2(Bool_t flag = kTRUE); ClassDef(TProfile3D,7) //Profile3D histogram class }; diff --git a/hist/hist/src/HFitImpl.cxx b/hist/hist/src/HFitImpl.cxx index e20273acf5c56..7e823bb7b344a 100644 --- a/hist/hist/src/HFitImpl.cxx +++ b/hist/hist/src/HFitImpl.cxx @@ -16,6 +16,7 @@ #include "Fit/Fitter.h" #include "Fit/BinData.h" #include "Fit/UnBinData.h" +#include "Fit/Chi2FCN.h" #include "HFitInterface.h" #include "Math/MinimizerOptions.h" #include "Math/Minimizer.h" @@ -52,6 +53,8 @@ namespace HFit { int CheckFitFunction(const TF1 * f1, int hdim); + void GetFunctionRange(const TF1 & f1, ROOT::Fit::DataRange & range); + void FitOptionsMake(const char *option, Foption_t &fitOption); void CheckGraphFitOptions(Foption_t &fitOption); @@ -68,7 +71,11 @@ namespace HFit { TFitResultPtr Fit(FitObject * h1, TF1 *f1 , Foption_t & option , const ROOT::Math::MinimizerOptions & moption, const char *goption, ROOT::Fit::DataRange & range); template <class FitObject> - void StoreAndDrawFitFunction(FitObject * h1, const TF1 * f1, const ROOT::Fit::DataRange & range, bool, bool, const char *goption); + void StoreAndDrawFitFunction(FitObject * h1, TF1 * f1, const ROOT::Fit::DataRange & range, bool, bool, const char *goption); + + template <class FitObject> + double ComputeChi2(const FitObject & h1, TF1 &f1, bool useRange ); + } @@ -105,6 +112,19 @@ int HFit::CheckFitFunction(const TF1 * f1, int dim) { } + +void HFit::GetFunctionRange(const TF1 & f1, ROOT::Fit::DataRange & range) { + // get the range form the function and fill and return the DataRange object + Double_t fxmin, fymin, fzmin, fxmax, fymax, fzmax; + f1.GetRange(fxmin, fymin, fzmin, fxmax, fymax, fzmax); + // support only one range - so add only if was not set before + if (range.Size(0) == 0) range.AddRange(0,fxmin,fxmax); + if (range.Size(1) == 0) range.AddRange(1,fymin,fymax); + if (range.Size(2) == 0) range.AddRange(2,fzmin,fzmax); + return; +} + + template<class FitObject> TFitResultPtr HFit::Fit(FitObject * h1, TF1 *f1 , Foption_t & fitOption , const ROOT::Math::MinimizerOptions & minOption, const char *goption, ROOT::Fit::DataRange & range) { @@ -159,13 +179,7 @@ TFitResultPtr HFit::Fit(FitObject * h1, TF1 *f1 , Foption_t & fitOption , const #ifdef DEBUG printf("use range \n" ); #endif - // check if function has range - Double_t fxmin, fymin, fzmin, fxmax, fymax, fzmax; - f1->GetRange(fxmin, fymin, fzmin, fxmax, fymax, fzmax); - // support only one range - so add only if was not set before - if (range.Size(0) == 0) range.AddRange(0,fxmin,fxmax); - if (range.Size(1) == 0) range.AddRange(1,fymin,fymax); - if (range.Size(2) == 0) range.AddRange(2,fzmin,fzmax); + HFit::GetFunctionRange(*f1,range); } #ifdef DEBUG printf("range size %d\n", range.Size(0) ); @@ -190,8 +204,10 @@ TFitResultPtr HFit::Fit(FitObject * h1, TF1 *f1 , Foption_t & fitOption , const } #endif - // switch off linear fitting in case data has coordinate errors - if (fitdata->GetErrorType() == ROOT::Fit::BinData::kCoordError ) linear = false; + // switch off linear fitting in case data has coordinate errors and the option is set + if (fitdata->GetErrorType() == ROOT::Fit::BinData::kCoordError && fitdata->Opt().fCoordErrors ) linear = false; + // linear fit cannot be done also in case of asymmetric errors + if (fitdata->GetErrorType() == ROOT::Fit::BinData::kAsymError && fitdata->Opt().fAsymErrors ) linear = false; // this functions use the TVirtualFitter if (special != 0 && !fitOption.Bound && !linear) { @@ -516,7 +532,7 @@ void HFit::GetDrawingRange(THnBase * s1, ROOT::Fit::DataRange & range) { } template<class FitObject> -void HFit::StoreAndDrawFitFunction(FitObject * h1, const TF1 * f1, const ROOT::Fit::DataRange & range, bool delOldFunction, bool drawFunction, const char *goption) { +void HFit::StoreAndDrawFitFunction(FitObject * h1, TF1 * f1, const ROOT::Fit::DataRange & range, bool delOldFunction, bool drawFunction, const char *goption) { // - Store fitted function in histogram functions list and draw // should have separate functions for 1,2,3d ? t.b.d in case @@ -524,9 +540,6 @@ void HFit::StoreAndDrawFitFunction(FitObject * h1, const TF1 * f1, const ROOT::F std::cout <<"draw and store fit function " << f1->GetName() << std::endl; #endif - TF1 *fnew1; - TF2 *fnew2; - TF3 *fnew3; Int_t ndim = GetDimension(h1); double xmin = 0, xmax = 0, ymin = 0, ymax = 0, zmin = 0, zmax = 0; @@ -546,41 +559,74 @@ void HFit::StoreAndDrawFitFunction(FitObject * h1, const TF1 * f1, const ROOT::F return; } + // delete the function in the list only if + // the funciton we are fitting is not in that list + // If this is the case we re-use that function object and + // we do not create a new one (if delOldFunction is true) + bool reuseOldFunction = false; if (delOldFunction) { TIter next(funcList, kIterBackward); TObject *obj; while ((obj = next())) { if (obj->InheritsFrom(TF1::Class())) { - funcList->Remove(obj); - delete obj; + if (obj != f1) { + funcList->Remove(obj); + delete obj; + } + else { + reuseOldFunction = true; + } } } } + TF1 *fnew1 = 0; + TF2 *fnew2 = 0; + TF3 *fnew3 = 0; + // copy TF1 using TClass to avoid slicing in case of derived classes if (ndim < 2) { - fnew1 = (TF1*)f1->IsA()->New(); - f1->Copy(*fnew1); - funcList->Add(fnew1); + if (!reuseOldFunction) { + fnew1 = (TF1*)f1->IsA()->New(); + R__ASSERT(fnew1); + f1->Copy(*fnew1); + funcList->Add(fnew1); + } + else { + fnew1 = f1; + } fnew1->SetParent( h1 ); fnew1->SetRange(xmin,xmax); fnew1->Save(xmin,xmax,0,0,0,0); if (!drawFunction) fnew1->SetBit(TF1::kNotDraw); fnew1->SetBit(TFormula::kNotGlobal); } else if (ndim < 3) { - fnew2 = (TF2*)f1->IsA()->New(); - f1->Copy(*fnew2); - funcList->Add(fnew2); + if (!reuseOldFunction) { + fnew2 = (TF2*)f1->IsA()->New(); + R__ASSERT(fnew2); + f1->Copy(*fnew2); + funcList->Add(fnew2); + } + else { + fnew2 = dynamic_cast<TF2*>(f1); + R__ASSERT(fnew2); + } fnew2->SetRange(xmin,ymin,xmax,ymax); fnew2->SetParent( h1 ); fnew2->Save(xmin,xmax,ymin,ymax,0,0); if (!drawFunction) fnew2->SetBit(TF1::kNotDraw); fnew2->SetBit(TFormula::kNotGlobal); - } else { - // 3D- why f3d is not saved ??? - fnew3 = (TF3*)f1->IsA()->New(); - f1->Copy(*fnew3); - funcList->Add(fnew3); + } else { + if (!reuseOldFunction) { + fnew3 = (TF3*)f1->IsA()->New(); + R__ASSERT(fnew3); + f1->Copy(*fnew3); + funcList->Add(fnew3); + } + else { + fnew2 = dynamic_cast<TF3*>(f1); + R__ASSERT(fnew3); + } fnew3->SetRange(xmin,ymin,zmin,xmax,ymax,zmax); fnew3->SetParent( h1 ); fnew3->Save(xmin,xmax,ymin,ymax,zmin,zmax); @@ -619,11 +665,12 @@ void ROOT::Fit::FitOptionsMake(const char *option, Foption_t &fitOption) { } if (opt.Contains("U")) fitOption.User = 1; + if (opt.Contains("W")) fitOption.W1 = 1; // all non-empty bins have weight =1 if (opt.Contains("Q")) fitOption.Quiet = 1; if (opt.Contains("V")){fitOption.Verbose = 1; fitOption.Quiet = 0;} if (opt.Contains("L")) fitOption.Like = 1; if (opt.Contains("X")) fitOption.Chi2 = 1; - if (opt.Contains("I")) fitOption.Integral= 1; + // likelihood fit options if (opt.Contains("L")) { fitOption.Like = 1; @@ -857,3 +904,34 @@ TFitResultPtr ROOT::Fit::FitObject(THnBase * s1, TF1 *f1 , Foption_t & foption , // return ROOT::Fit::FitObject(this, f2 , fitOption , minOption, goption, range); // } + +// function to compute the simple chi2 for graphs and histograms + +double ROOT::Fit::Chisquare(const TH1 & h1, TF1 & f1, bool useRange) { + return HFit::ComputeChi2(h1,f1,useRange); +} + +double ROOT::Fit::Chisquare(const TGraph & g, TF1 & f1, bool useRange) { + return HFit::ComputeChi2(g,f1, useRange); +} + +template<class FitObject> +double HFit::ComputeChi2(const FitObject & obj, TF1 & f1, bool useRange ) { + + // implement using the fitting classes + ROOT::Fit::DataOptions opt; + ROOT::Fit::DataRange range; + // get range of function + if (useRange) HFit::GetFunctionRange(f1,range); + // fill the data set + ROOT::Fit::BinData data(opt,range); + ROOT::Fit::FillData(data, &obj, &f1); + if (data.Size() == 0 ) { + Warning("Chisquare","data set is empty - return -1"); + return -1; + } + ROOT::Math::WrappedMultiTF1 wf1(f1); + ROOT::Fit::Chi2Function chi2(data, wf1); + return chi2(f1.GetParameters() ); + +} diff --git a/hist/hist/src/HFitInterface.cxx b/hist/hist/src/HFitInterface.cxx index 5ec548d0be33f..f5cbad6ed6b3a 100644 --- a/hist/hist/src/HFitInterface.cxx +++ b/hist/hist/src/HFitInterface.cxx @@ -217,9 +217,9 @@ void FillData(BinData & dv, const TH1 * hfit, TF1 * func) // need to evaluate function to know about rejected points // hugly but no other solutions if (func != 0) { - func->RejectPoint(false); + TF1::RejectPoint(false); (*func)( &x[0] ); // evaluate using stored function parameters - if (func->RejectedPoint() ) continue; + if (TF1::RejectedPoint() ) continue; } @@ -471,7 +471,7 @@ void Init2DGaus(const ROOT::Fit::BinData & data, TF1 * f1) // filling fit data from TGraph objects -BinData::ErrorType GetDataType(const TGraph * gr, const DataOptions & fitOpt) { +BinData::ErrorType GetDataType(const TGraph * gr, DataOptions & fitOpt) { // get type of data for TGraph objects double *ex = gr->GetEX(); double *ey = gr->GetEY(); @@ -486,6 +486,7 @@ BinData::ErrorType GetDataType(const TGraph * gr, const DataOptions & fitOpt) { type = BinData::kNoError; } // need to treat case when all errors are zero + // note that by default fitOpt.fCoordError is true else if ( ex != 0 && fitOpt.fCoordErrors) { // check that all errors are not zero int i = 0; @@ -494,20 +495,30 @@ BinData::ErrorType GetDataType(const TGraph * gr, const DataOptions & fitOpt) { ++i; } } + // case of asymmetric errors (by default fAsymErrors is true) else if ( ( eyl != 0 && eyh != 0) && fitOpt.fAsymErrors) { // check also if that all errors are non zero's int i = 0; - bool zeroError = true; - while (i < gr->GetN() && zeroError) { + bool zeroErrorX = true; + bool zeroErrorY = true; + while (i < gr->GetN() && (zeroErrorX || zeroErrorY)) { double e2X = ( gr->GetErrorXlow(i) + gr->GetErrorXhigh(i) ); double e2Y = eyl[i] + eyh[i]; - if ( e2X > 0 || e2Y > 0) zeroError = false; + zeroErrorX &= (e2X <= 0); + zeroErrorY &= (e2Y <= 0); ++i; } - if (zeroError) + if (zeroErrorX && zeroErrorY) type = BinData::kNoError; - else + else if (!zeroErrorX && zeroErrorY) + type = BinData::kCoordError; + else if (zeroErrorX && !zeroErrorY) { type = BinData::kAsymError; + fitOpt.fCoordErrors = false; + } + else { + type = BinData::kAsymError; + } } // need to look also a case when all errors in y are zero @@ -597,9 +608,9 @@ void DoFillData ( BinData & dv, const TGraph * gr, BinData::ErrorType type, T // need to evaluate function to know about rejected points // hugly but no other solutions if (func) { - func->RejectPoint(false); + TF1::RejectPoint(false); (*func)( x ); // evaluate using stored function parameters - if (func->RejectedPoint() ) continue; + if (TF1::RejectedPoint() ) continue; } @@ -632,10 +643,12 @@ void DoFillData ( BinData & dv, const TGraph * gr, BinData::ErrorType type, T // adjust error in y according to option double errorY = std::max(gr->GetErrorY(i), 0.); + // we do not check the return value since we check later if error in X and Y is zero for skipping the point HFitInterface::AdjustError(fitOpt, errorY); - // skip points with totla error = 0 + // skip points with total error = 0 if ( errorX <=0 && errorY <= 0 ) continue; + if (type == BinData::kAsymError) { // asymmetric errors @@ -787,11 +800,13 @@ void FillData ( BinData & dv, const TGraph * gr, TF1 * func ) { fitOpt.fErrors1 = (type == BinData::kNoError); // set this if we want to have error=1 for points with zero errors (by default they are skipped) // fitOpt.fUseEmpty = true; - fitOpt.fCoordErrors = (type == BinData::kCoordError); - fitOpt.fAsymErrors = (type == BinData::kAsymError); + + // use coordinate or asym errors in case option is set and type is consistent + fitOpt.fCoordErrors &= (type == BinData::kCoordError) || (type == BinData::kAsymError) ; + fitOpt.fAsymErrors &= (type == BinData::kAsymError); - // if sata are filled already check if there are consistent - otherwise do nothing + // if data are filled already check if there are consistent - otherwise do nothing if (dv.Size() > 0 && dv.NDim() == 1 ) { // check if size is correct otherwise flag an errors if (dv.PointSize() == 2 && type != BinData::kNoError ) { @@ -806,6 +821,10 @@ void FillData ( BinData & dv, const TGraph * gr, TF1 * func ) { Error("FillData","Inconsistent TGraph with previous data set- skip all graph data"); return; } + if (dv.PointSize() == 5 && type != BinData::kAsymError ) { + Error("FillData","Inconsistent TGraph with previous data set- skip all graph data"); + return; + } } DoFillData(dv, gr, type, func); @@ -914,9 +933,9 @@ void FillData ( BinData & dv, const TGraph2D * gr, TF1 * func ) { // need to evaluate function to know about rejected points // hugly but no other solutions if (func) { - func->RejectPoint(false); + TF1::RejectPoint(false); (*func)( x ); // evaluate using stored function parameters - if (func->RejectedPoint() ) continue; + if (TF1::RejectedPoint() ) continue; } diff --git a/hist/hist/src/TAxis.cxx b/hist/hist/src/TAxis.cxx index 01ccd8124c8b1..c4801046df959 100644 --- a/hist/hist/src/TAxis.cxx +++ b/hist/hist/src/TAxis.cxx @@ -87,7 +87,7 @@ TAxis::~TAxis() } //______________________________________________________________________________ -TAxis::TAxis(const TAxis &axis) : TNamed(axis), TAttAxis(axis) +TAxis::TAxis(const TAxis &axis) : TNamed(axis), TAttAxis(axis), fLabels(0) { // Copy constructor. @@ -480,14 +480,11 @@ Double_t TAxis::GetBinUpEdge(Int_t bin) const { // Return up edge of bin - Double_t binwidth; - if (!fXbins.fN || bin<1 || bin>fNbins) { - binwidth = (fXmax - fXmin) / Double_t(fNbins); + if (!fXbins.fN || bin < 1 || bin>fNbins) { + Double_t binwidth = (fXmax - fXmin) / Double_t(fNbins); return fXmin + bin*binwidth; - } else { - binwidth = fXbins.fArray[bin] - fXbins.fArray[bin-1]; - return fXbins.fArray[bin-1] + binwidth; - } + } + return fXbins.fArray[bin]; } //______________________________________________________________________________ @@ -620,60 +617,62 @@ void TAxis::RotateTitle(Bool_t rotate) } //______________________________________________________________________________ -void TAxis::SaveAttributes(ostream &out, const char *name, const char *subname) +void TAxis::SaveAttributes(std::ostream &out, const char *name, const char *subname) { // Save axis attributes as C++ statement(s) on output stream out char quote = '"'; if (strlen(GetTitle())) { - out<<" "<<name<<subname<<"->SetTitle("<<quote<<GetTitle()<<quote<<");"<<endl; + TString t(GetTitle()); + t.ReplaceAll("\\","\\\\"); + out<<" "<<name<<subname<<"->SetTitle("<<quote<<t.Data()<<quote<<");"<<std::endl; } if (fTimeDisplay) { - out<<" "<<name<<subname<<"->SetTimeDisplay(1);"<<endl; - out<<" "<<name<<subname<<"->SetTimeFormat("<<quote<<GetTimeFormat()<<quote<<");"<<endl; + out<<" "<<name<<subname<<"->SetTimeDisplay(1);"<<std::endl; + out<<" "<<name<<subname<<"->SetTimeFormat("<<quote<<GetTimeFormat()<<quote<<");"<<std::endl; } if (fLabels) { TIter next(fLabels); TObjString *obj; while ((obj=(TObjString*)next())) { - out<<" "<<name<<subname<<"->SetBinLabel("<<obj->GetUniqueID()<<","<<quote<<obj->GetName()<<quote<<");"<<endl; + out<<" "<<name<<subname<<"->SetBinLabel("<<obj->GetUniqueID()<<","<<quote<<obj->GetName()<<quote<<");"<<std::endl; } } if (fFirst || fLast) { - out<<" "<<name<<subname<<"->SetRange("<<fFirst<<","<<fLast<<");"<<endl; + out<<" "<<name<<subname<<"->SetRange("<<fFirst<<","<<fLast<<");"<<std::endl; } if (TestBit(kLabelsHori)) { - out<<" "<<name<<subname<<"->SetBit(TAxis::kLabelsHori);"<<endl; + out<<" "<<name<<subname<<"->SetBit(TAxis::kLabelsHori);"<<std::endl; } if (TestBit(kLabelsVert)) { - out<<" "<<name<<subname<<"->SetBit(TAxis::kLabelsVert);"<<endl; + out<<" "<<name<<subname<<"->SetBit(TAxis::kLabelsVert);"<<std::endl; } if (TestBit(kLabelsDown)) { - out<<" "<<name<<subname<<"->SetBit(TAxis::kLabelsDown);"<<endl; + out<<" "<<name<<subname<<"->SetBit(TAxis::kLabelsDown);"<<std::endl; } if (TestBit(kLabelsUp)) { - out<<" "<<name<<subname<<"->SetBit(TAxis::kLabelsUp);"<<endl; + out<<" "<<name<<subname<<"->SetBit(TAxis::kLabelsUp);"<<std::endl; } if (TestBit(kCenterTitle)) { - out<<" "<<name<<subname<<"->CenterTitle(true);"<<endl; + out<<" "<<name<<subname<<"->CenterTitle(true);"<<std::endl; } if (TestBit(kRotateTitle)) { - out<<" "<<name<<subname<<"->RotateTitle(true);"<<endl; + out<<" "<<name<<subname<<"->RotateTitle(true);"<<std::endl; } if (TestBit(kMoreLogLabels)) { - out<<" "<<name<<subname<<"->SetMoreLogLabels();"<<endl; + out<<" "<<name<<subname<<"->SetMoreLogLabels();"<<std::endl; } if (TestBit(kNoExponent)) { - out<<" "<<name<<subname<<"->SetNoExponent();"<<endl; + out<<" "<<name<<subname<<"->SetNoExponent();"<<std::endl; } TAttAxis::SaveAttributes(out,name,subname); @@ -791,6 +790,8 @@ void TAxis::SetBinLabel(Int_t bin, const char *label) if ( obj->GetUniqueID()==(UInt_t)bin ) { // It does. Overwrite it. obj->SetString(label); + // LM need to rehash the labels list (see ROOT-5025) + fLabels->Rehash(fLabels->GetSize() ); return; } } @@ -856,25 +857,36 @@ void TAxis::SetRange(Int_t first, Int_t last) { // Set the viewing range for the axis from bin first to last // To set a range using the axis coordinates, use TAxis::SetRangeUser. - // if first<=1 and last>=Nbins or if last < first the range is reset by removing the - // bit TAxis::kAxisRange. In this case the functions TAxis::GetFirst() and TAxis::GetLast() - // will return 1 and Nbins. - // NOTE: If the bit has been set manually by the user in case of no range defined - // GetFirst() and GetLast() will return 0. - - if (last <= 0) last = fNbins; - if (last > fNbins) last = fNbins; - if (last < first) { first = 1; last = fNbins; } - if (first < 1) first = 1; - if (first == 1 && last == fNbins) { - SetBit(kAxisRange,0); - fFirst = 0; - fLast = 0; + + // If first == last == 0 or if last < first or if the range specified does + // not intersect at all with the maximum available range [0, fNbins + 1], + // then the range is reset by removing the bit TAxis::kAxisRange. In this + // case the functions TAxis::GetFirst() and TAxis::GetLast() will return 1 + // and fNbins. + + // If the range specified partially intersects [0, fNbins + 1], then the + // intersection range is set. For instance, if first == -2 and last == fNbins, + // then the set range is [0, fNbins] (fFirst = 0 and fLast = fNbins). + // + // NOTE: for historical reasons, SetRange(0,0) resets the range even though Bin 0 is + // technically reserved for the underflow; in order to set the range of the axis + // so that it only includes the underflow, use SetRange(a,0), where a < 0 + + Int_t nCells = fNbins + 1; // bins + overflow + + // special reset range cases + if (last < first || (first < 0 && last < 0) || + (first > nCells && last > nCells) || (first == 0 && last == 0) + ) { + fFirst = 1; + fLast = fNbins; + SetBit(kAxisRange, 0); } else { - SetBit(kAxisRange,1); - fFirst = first; - fLast = last; + fFirst = std::max(first, 0); + fLast = std::min(last, nCells); + SetBit(kAxisRange, 1); } + } @@ -894,7 +906,12 @@ void TAxis::SetRangeUser(Double_t ufirst, Double_t ulast) return; } } - SetRange(FindFixBin(ufirst),FindFixBin(ulast)); + Int_t ifirst = FindFixBin(ufirst); + Int_t ilast = FindFixBin(ulast); + // fixes for numerical error and for https://savannah.cern.ch/bugs/index.php?99777 + if (GetBinUpEdge(ifirst) <= ufirst ) ifirst += 1; + if (GetBinLowEdge(ilast) >= ulast ) ilast -= 1; + SetRange(ifirst, ilast); } //______________________________________________________________________________ @@ -953,13 +970,6 @@ void TAxis::SetTimeFormat(const char *tformat) TString timeformat = tformat; - Int_t lnF = timeformat.Length(); - Int_t idG = timeformat.Index("GMT"); - - if (idG) { - if (idG+3==lnF) timeformat.Append(Form("%d",TTimeStamp::GetZoneOffset())); - } - if (timeformat.Index("%F")>=0 || timeformat.IsNull()) { fTimeFormat = timeformat; return; @@ -967,7 +977,7 @@ void TAxis::SetTimeFormat(const char *tformat) Int_t idF = fTimeFormat.Index("%F"); if (idF>=0) { - lnF = fTimeFormat.Length(); + Int_t lnF = fTimeFormat.Length(); TString stringtimeoffset = fTimeFormat(idF,lnF); fTimeFormat = tformat; fTimeFormat.Append(stringtimeoffset); @@ -982,14 +992,11 @@ void TAxis::SetTimeFormat(const char *tformat) void TAxis::SetTimeOffset(Double_t toffset, Option_t *option) { // Change the time offset - // If option = "gmt" the time offset is treated as a GMT time. + // If option = "gmt", set display mode to GMT. TString opt = option; opt.ToLower(); - Bool_t gmt = kFALSE; - if (opt.Contains("gmt")) gmt = kTRUE; - char tmp[20]; time_t timeoff; struct tm* utctis; @@ -998,20 +1005,20 @@ void TAxis::SetTimeOffset(Double_t toffset, Option_t *option) fTimeFormat.Append("%F"); timeoff = (time_t)((Long_t)(toffset)); + // offset is always saved in GMT to allow file transport + // to different time zones utctis = gmtime(&timeoff); - + strftime(tmp,20,"%Y-%m-%d %H:%M:%S",utctis); fTimeFormat.Append(tmp); // append the decimal part of the time offset Double_t ds = toffset-(Int_t)toffset; - if(ds!= 0) { - snprintf(tmp,20,"s%g",ds); - fTimeFormat.Append(tmp); - } + snprintf(tmp,20,"s%g",ds); + fTimeFormat.Append(tmp); - // If the time is GMT, stamp fTimeFormat - if (gmt) fTimeFormat.Append(Form(" GMT%d",TTimeStamp::GetZoneOffset())); + // add GMT/local option + if (opt.Contains("gmt")) fTimeFormat.Append(" GMT"); } @@ -1073,7 +1080,7 @@ void TAxis::UnZoom() { // Reset first & last bin to the full range - + if (!gPad) return; gPad->SetView(); //unzoom object owning this axis @@ -1093,8 +1100,13 @@ void TAxis::UnZoom() hobj1->SetMinimum(fXmin); hobj1->SetMaximum(fXmax); } else { - hobj1->SetMinimum(); - hobj1->SetMaximum(); + if (fXmin==hobj1->GetMinimum() && fXmax==hobj1->GetMaximum()) { + hobj1->SetMinimum(fXmin); + hobj1->SetMaximum(fXmax); + } else { + hobj1->SetMinimum(); + hobj1->SetMaximum(); + } hobj1->ResetBit(TH1::kIsZoomed); } } diff --git a/hist/hist/src/TEfficiency.cxx b/hist/hist/src/TEfficiency.cxx index c663c2810b1df..124aa1a95594d 100644 --- a/hist/hist/src/TEfficiency.cxx +++ b/hist/hist/src/TEfficiency.cxx @@ -1040,6 +1040,9 @@ TEfficiency::TEfficiency(const TEfficiency& rEff): // by calling SetDirectory(TDirectory*) or write it explicitly to disk // by calling Write(). + // copy TObject bits + ((TObject&)rEff).Copy(*this); + Bool_t bStatus = TH1::AddDirectoryStatus(); TH1::AddDirectory(kFALSE); fTotalHistogram = (TH1*)((rEff.fTotalHistogram)->Clone()); @@ -1056,10 +1059,6 @@ TEfficiency::TEfficiency(const TEfficiency& rEff): SetStatisticOption(rEff.GetStatisticOption()); SetDirectory(0); - - SetBit(kPosteriorMode,TestBit(rEff.kPosteriorMode)); - SetBit(kShortestInterval,TestBit(rEff.kShortestInterval)); - SetBit(kUseWeights,TestBit(rEff.kUseWeights)); //copy style rEff.TAttLine::Copy(*this); @@ -1906,12 +1905,8 @@ TGraphAsymmErrors* TEfficiency::Combine(TCollection* pList,Option_t* option, Int_t nbins_max = vTotal.at(0)->GetNbinsX(); //check binning of all histograms for(UInt_t i=0; i<vTotal.size(); ++i) { - try { - TEfficiency::CheckBinning(*vTotal.at(0),*vTotal.at(i)); - } - catch(std::exception&) { + if (!TEfficiency::CheckBinning(*vTotal.at(0),*vTotal.at(i)) ) gROOT->Warning("TEfficiency::Combine","histograms have not the same binning -> results may be useless"); - } if(vTotal.at(i)->GetNbinsX() < nbins_max) nbins_max = vTotal.at(i)->GetNbinsX(); } @@ -2287,8 +2282,10 @@ Double_t TEfficiency::GetEfficiency(Int_t bin) const Double_t tw2 = fTotalHistogram->GetSumw2()->At(bin); Double_t pw = fPassedHistogram->GetBinContent(bin); + if (tw2 <= 0 ) return pw/tw; + // tw/tw2 renormalize the weights - double norm = (tw2 > 0) ? tw/tw2 : 0.; + double norm = tw/tw2; aa = pw * norm + alpha; bb = (tw - pw) * norm + beta; } @@ -2338,8 +2335,10 @@ Double_t TEfficiency::GetEfficiencyErrorLow(Int_t bin) const Double_t alpha = TestBit(kUseBinPrior) ? GetBetaAlpha(bin) : GetBetaAlpha(); Double_t beta = TestBit(kUseBinPrior) ? GetBetaBeta(bin) : GetBetaBeta(); + if (tw2 <= 0) return 0; + // tw/tw2 renormalize the weights - Double_t norm = (tw2 > 0) ? tw/tw2 : 0.; + Double_t norm = tw/tw2; Double_t aa = pw * norm + alpha; Double_t bb = (tw - pw) * norm + beta; Double_t low = 0; @@ -2415,8 +2414,10 @@ Double_t TEfficiency::GetEfficiencyErrorUp(Int_t bin) const Double_t alpha = TestBit(kUseBinPrior) ? GetBetaAlpha(bin) : GetBetaAlpha(); Double_t beta = TestBit(kUseBinPrior) ? GetBetaBeta(bin) : GetBetaBeta(); + if (tw2 <= 0) return 0; + // tw/tw2 renormalize the weights - Double_t norm = (tw2 > 0) ? tw/tw2 : 0.; + Double_t norm = tw/tw2; Double_t aa = pw * norm + alpha; Double_t bb = (tw - pw) * norm + beta; Double_t low = 0; @@ -2720,8 +2721,15 @@ void TEfficiency::Paint(const Option_t* opt) //refresh title before painting if changed TString oldTitle = fPaintGraph->GetTitle(); TString newTitle = GetTitle(); - if (oldTitle != newTitle ) + if (oldTitle != newTitle ) { fPaintGraph->SetTitle(newTitle); + } + + // set the axis labels + TString xlabel = fTotalHistogram->GetXaxis()->GetTitle(); + TString ylabel = fTotalHistogram->GetYaxis()->GetTitle(); + if (xlabel) fPaintGraph->GetXaxis()->SetTitle(xlabel); + if (ylabel) fPaintGraph->GetYaxis()->SetTitle(ylabel); //copying style information TAttLine::Copy(*fPaintGraph); @@ -2780,6 +2788,12 @@ void TEfficiency::Paint(const Option_t* opt) //refresh title before each painting fPaintHisto->SetTitle(GetTitle()); + // set the axis labels + TString xlabel = fTotalHistogram->GetXaxis()->GetTitle(); + TString ylabel = fTotalHistogram->GetYaxis()->GetTitle(); + if (xlabel) fPaintHisto->GetXaxis()->SetTitle(xlabel); + if (ylabel) fPaintHisto->GetYaxis()->SetTitle(ylabel); + Int_t bin; for(Int_t i = 0; i < nbinsx + 2; ++i) { for(Int_t j = 0; j < nbinsy + 2; ++j) { diff --git a/hist/hist/src/TF1.cxx b/hist/hist/src/TF1.cxx index 9e4589285a076..cffecc794dd0d 100644 --- a/hist/hist/src/TF1.cxx +++ b/hist/hist/src/TF1.cxx @@ -36,6 +36,7 @@ #include "Math/AdaptiveIntegratorMultiDim.h" #include "Math/RichardsonDerivator.h" #include "Math/Functor.h" +#include "Math/ChebyshevPol.h" #include "Fit/FitResult.h" //#include <iostream> @@ -1082,6 +1083,8 @@ void TF1::Browse(TBrowser *b) void TF1::Copy(TObject &obj) const { // Copy this F1 to a new F1. + // Note that the cached integral with its related arrays are not copied + // (they are also set as transient data members) if (((TF1&)obj).fParMin) delete [] ((TF1&)obj).fParMin; if (((TF1&)obj).fParMax) delete [] ((TF1&)obj).fParMax; @@ -2414,7 +2417,14 @@ void TF1::InitStandardFunctions() for (Int_t i=0;i<10;i++) { f1 = new TF1(Form("pol%d",i),Form("pol%d",i),-1,1); f1->SetParameters(1,1,1,1,1,1,1,1,1,1); + // create also chebyshev polynomial + // (note polynomial object will not be deleted) + // note that these functions cannot be stored + ROOT::Math::ChebyshevPol * pol = new ROOT::Math::ChebyshevPol(i); + f1 = new TF1(TString::Format("cheb%d",i),pol,-1,1,i+1); + f1->SetParameters(1,1,1,1,1,1,1,1,1,1); } + } } @@ -3058,8 +3068,8 @@ void TF1::SavePrimitive(ostream &out, Option_t *option /*= ""*/) out<<" "<<GetName()<<"->SetNDF("<<GetNDF()<<");"<<endl; } - GetXaxis()->SaveAttributes(out,GetName(),"->GetXaxis()"); - GetYaxis()->SaveAttributes(out,GetName(),"->GetYaxis()"); + if (GetXaxis()) GetXaxis()->SaveAttributes(out,GetName(),"->GetXaxis()"); + if (GetYaxis()) GetYaxis()->SaveAttributes(out,GetName(),"->GetYaxis()"); Double_t parmin, parmax; for (i=0;i<fNpar;i++) { diff --git a/hist/hist/src/TF2.cxx b/hist/hist/src/TF2.cxx index 4bbf027d91961..c98f404949d87 100644 --- a/hist/hist/src/TF2.cxx +++ b/hist/hist/src/TF2.cxx @@ -440,6 +440,10 @@ void TF2::GetMinimumXY(Double_t &x, Double_t &y) } TVirtualFitter *minuit = TVirtualFitter::Fitter(this, 2); + if (!minuit) { + Error("GetMinimumXY", "Cannot create fitter"); + return; + } minuit->Clear(); minuit->SetFitMethod("F2Minimizer"); Double_t arglist[10]; diff --git a/hist/hist/src/TF3.cxx b/hist/hist/src/TF3.cxx index cd07f56228dcc..b480bb8a0e203 100644 --- a/hist/hist/src/TF3.cxx +++ b/hist/hist/src/TF3.cxx @@ -329,6 +329,10 @@ void TF3::GetMinimumXYZ(Double_t &x, Double_t &y, Double_t &z) } TVirtualFitter *minuit = TVirtualFitter::Fitter(this, 3); + if (!minuit) { + Error("GetMinimumXYZ", "Cannot create fitter"); + return; + } minuit->Clear(); minuit->SetFitMethod("F3Minimizer"); Double_t arglist[10]; diff --git a/hist/hist/src/TFormula.cxx b/hist/hist/src/TFormula.cxx index b592fc557a070..57dd944912a2f 100644 --- a/hist/hist/src/TFormula.cxx +++ b/hist/hist/src/TFormula.cxx @@ -2909,24 +2909,16 @@ Double_t TFormula::EvalParOld(const Double_t *x, const Double_t *uparams) TMethodCall *method = (TMethodCall*)fFunctions.At(fno); // Set the arguments - TString args; + method->ResetParam(); if (nargs) { UInt_t argloc = pos-nargs; for(j=0;j<nargs;j++,argloc++,pos--) { - if (TMath::IsNaN(tab[argloc])) { - // TString would add 'nan' this is not what we want - // so let's do somethign else - args += "(double)(0x8000000000000)"; - } else { - args += tab[argloc]; - } - args += ','; + method->SetParam(tab[argloc]); } - args.Remove(args.Length()-1); } pos++; Double_t ret; - method->Execute(args,ret); + method->Execute(ret); tab[pos-1] = ret; // check for the correct conversion! continue; @@ -3426,7 +3418,10 @@ void TFormula::Streamer(TBuffer &b) Int_t npar = fNpar; fParams = 0; fNames = 0; - Compile(); + if (Compile()) { + Error("Streamer","error compiling formula"); + return; + } for (Int_t i = 0; i<npar && i<fNpar; ++i) fParams[i] = param[i]; delete [] param; delete [] fNames; @@ -3718,7 +3713,7 @@ void TFormula::Optimize() // // pdata[operand={Var,Par,Const}][offset] // pdata[fOperOffsets0[i]][fOperOffset1[i+1]] - // 2.) The fastest evaluation function is choosen at the end + // 2.) The fastest evaluation function is chosen at the end // a.) fOptimal := pointer to the fastest function for given evaluation string // switch(GetActionOptimized(0)){ // case kData : {fOptimal= (TFormulaPrimitive::TFuncG)&TFormula::EvalPrimitive0; break;} @@ -4370,24 +4365,16 @@ Double_t TFormula::EvalParFast(const Double_t *x, const Double_t *uparams) TMethodCall *method = (TMethodCall*)fFunctions.At(fno); // Set the arguments - TString args; + method->ResetParam(); if (nargs) { UInt_t argloc = pos-nargs; for(j=0;j<nargs;j++,argloc++,pos--) { - if (TMath::IsNaN(tab[argloc])) { - // TString would add 'nan' this is not what we want - // so let's do somethign else - args += "(double)(0x8000000000000)"; - } else { - args += tab[argloc]; - } - args += ','; + method->SetParam(tab[argloc]); } - args.Remove(args.Length()-1); } pos++; Double_t ret; - method->Execute(args,ret); + method->Execute(ret); tab[pos-1] = ret; // check for the correct conversion! continue; diff --git a/hist/hist/src/TFormulaPrimitive.cxx b/hist/hist/src/TFormulaPrimitive.cxx index 0ac706ac1a499..fc0554ea6ffb6 100644 --- a/hist/hist/src/TFormulaPrimitive.cxx +++ b/hist/hist/src/TFormulaPrimitive.cxx @@ -254,7 +254,7 @@ Double_t TFormulaPrimitive::Eval(Double_t *x, Double_t *param) namespace TFastFun { // // Namespace with basic primitive functions registered by TFormulaPrimitive - // all function registerd by TFormulaPrimitive can be used in TFormula + // all function registered by TFormulaPrimitive can be used in TFormula // Double_t Pow2(Double_t x){return x*x;} Double_t Pow3(Double_t x){return x*x*x;} diff --git a/hist/hist/src/TFractionFitter.cxx b/hist/hist/src/TFractionFitter.cxx index 57ff5c0414242..f2211a66573b6 100644 --- a/hist/hist/src/TFractionFitter.cxx +++ b/hist/hist/src/TFractionFitter.cxx @@ -524,8 +524,14 @@ void TFractionFitter::CheckConsistency() { for (z = minZ; z <= maxZ; ++z) { for (y = minY; y <= maxY; ++y) { for (x = minX; x <= maxX; ++x) { - if (IsExcluded(fData->GetBin(x, y, z))) continue; - fIntegralMCs[par] += h->GetBinContent(x, y, z); + Int_t bin = fData->GetBin(x, y, z); + if (IsExcluded(bin)) continue; + Double_t MCEvents = h->GetBinContent(bin); + if (MCEvents < 0) { + Error("CheckConsistency", "Number of MC events (bin = %d, par = %d) cannot be negative: " + " their distribution is binomial (see paper)", bin, par); + } + fIntegralMCs[par] += MCEvents; } } } @@ -696,7 +702,7 @@ void TFractionFitter::ComputeFCN(Int_t& /*npar*/, Double_t* /*gin*/, // Solve for the "predictions" int k0; Double_t ti; Double_t aki; - FindPrediction(bin, fFractions, ti, k0, aki); + FindPrediction(bin, ti, k0, aki); Double_t prediction = 0; for (mc = 0; mc < fNpar; ++mc) { @@ -737,102 +743,99 @@ void TFractionFitter::ComputeFCN(Int_t& /*npar*/, Double_t* /*gin*/, } //______________________________________________________________________________ -void TFractionFitter::FindPrediction(int bin, Double_t *fractions, Double_t &ti, int& k0, Double_t &aki) const { +void TFractionFitter::FindPrediction(int bin, Double_t &t_i, int& k_0, Double_t &A_ki) const { // Function used internally to obtain the template prediction in the individual bins - - // Sanity check: none of the fractions should be =0 - Int_t par; - TH1 *hw; - for (par = 0; par < fNpar; ++par) { - hw = (TH1*)fWeights.At(par); - Double_t weightedFraction = hw ? - hw->GetBinContent(bin) * fractions[par] : fractions[par]; - if (weightedFraction == 0) { - Error("FindPrediction","Fraction[%d] = 0!",par); + // 'bin' <=> 'i' (paper) + // 'par' <=> 'j' (paper) + + std::vector<Double_t> wgtFrac(fNpar); // weighted fractions (strengths of the sources) + std::vector<Double_t> a_ji(fNpar); // number of observed MC events for bin 'i' and par (source) 'j' + Double_t d_i = fData->GetBinContent(bin); // number of events in the real data for bin 'i' + + // Cache the weighted fractions and the number of observed MC events + // Sanity check: none of the fractions should be == 0 + for (Int_t par = 0; par < fNpar; ++par) { + a_ji[par] = ((TH1*)fMCs.At(par))->GetBinContent(bin); + TH1* hw = (TH1*)fWeights.At(par); + wgtFrac[par] = hw ? hw->GetBinContent(bin) * fFractions[par] : fFractions[par]; + if (wgtFrac[par] == 0) { + Error("FindPrediction", "Fraction[%d] = 0!", par); return; } } // Case data = 0 - if (TMath::Nint(fData->GetBinContent(bin)) == 0) { - ti = 1; - k0 = -1; - aki=0; + if (TMath::Nint(d_i) == 0) { + t_i = 1; + k_0 = -1; + A_ki = 0; return; } - // Case one or more of the MC bin contents = 0: find largest fraction - k0 = 0; - TH1 *hw0 = (TH1*)fWeights.At(0); - Double_t refWeightedFraction = hw0 ? - hw0->GetBinContent(bin) * fractions[0] : fractions[0]; - for (par = 1; par < fNpar; ++par) { - hw = (TH1*)fWeights.At(par); - Double_t weightedFraction = hw ? - hw->GetBinContent(bin) * fractions[par] : fractions[par]; - if (weightedFraction > refWeightedFraction) { - k0 = par; - refWeightedFraction = weightedFraction; + // Case one or more of the MC bin contents == 0 -> find largest fraction + // k_0 stores the source index of the largest fraction + k_0 = 0; + Double_t maxWgtFrac = wgtFrac[0]; + for (Int_t par = 1; par < fNpar; ++par) { + if (wgtFrac[par] > maxWgtFrac) { + k_0 = par; + maxWgtFrac = wgtFrac[par]; } - } - int nMax = 1; - Double_t contentsMax = ((TH1*)fMCs.At(k0))->GetBinContent(bin); - for (par = 0; par < fNpar; ++par) { - if (par == k0) continue; - hw = (TH1*)fWeights.At(par); - Double_t weightedFraction = hw ? - hw->GetBinContent(bin) * fractions[par] : fractions[par]; - if (weightedFraction == refWeightedFraction) { + } + Double_t t_min = -1 / maxWgtFrac; // t_i cannot be smaller than this value (see paper, par 5) + + // Determine if there are more sources which have the same maximum contribution (fraction) + Int_t nMax = 1; Double_t contentsMax = a_ji[k_0]; + for (Int_t par = 0; par < fNpar; ++par) { + if (par == k_0) continue; + if (wgtFrac[par] == maxWgtFrac) { nMax++; - contentsMax += ((TH1*)fMCs.At(par))->GetBinContent(bin); + contentsMax += a_ji[par]; } } - Double_t tmin = -1/refWeightedFraction; + // special action if there is a zero in the number of entries for the MC source with + // the largest strength (fraction) -> See Paper, Paragraph 5 if (contentsMax == 0) { - aki = fData->GetBinContent(bin)/(1+refWeightedFraction); - for (par = 0; par < fNpar; ++par) { - hw = (TH1*)fWeights.At(par); - if (par != k0) { - Double_t weightedFraction = hw ? - hw->GetBinContent(bin) * fractions[par] : fractions[par]; - if (weightedFraction != refWeightedFraction) - aki -= ((TH1*)fMCs.At(par))->GetBinContent(bin)*weightedFraction/ (refWeightedFraction - weightedFraction); - } + A_ki = d_i / (1.0 + maxWgtFrac); + for (Int_t par = 0; par < fNpar; ++par) { + if (par == k_0 || wgtFrac[par] == maxWgtFrac) continue; + A_ki -= a_ji[par] * wgtFrac[par] / (maxWgtFrac - wgtFrac[par]); } - if (aki > 0) { - if (nMax) aki /= nMax; - ti = tmin; + if (A_ki > 0) { + A_ki /= nMax; + t_i = t_min; return; } } - k0 = -1; + k_0 = -1; - // Case of nonzero histogram contents: solve for Ti using Newton's method - ti = 0; - for (Double_t step = 0.2;;) { - if (ti >= 1 || ti < tmin) { + // Case of nonzero histogram contents: solve for t_i using Newton's method + // The equation that needs to be solved: + // func(t_i) = \sum\limits_j{\frac{ p_j a_{ji} }{1 + p_j t_i}} - \frac{d_i}{1 - t_i} = 0 + t_i = 0; Double_t step = 0.2; + Int_t maxIter = 100000; // maximum number of iterations + for(Int_t i = 0; i < maxIter; ++i) { + if (t_i >= 1 || t_i < t_min) { step /= 10; - ti = 0; + t_i = 0; } - Double_t aFunction = - fData->GetBinContent(bin)/(1-ti); - Double_t aDerivative = aFunction / (1-ti); - for (par = 0; par < fNpar; ++par) { - TH1 *h = (TH1*)fMCs.At(par); - hw = (TH1*)fWeights.At(par); - Double_t weightedFraction = hw ? - hw->GetBinContent(bin) * fractions[par] : fractions[par]; - Double_t d = 1/(ti+1/weightedFraction); - aFunction += h->GetBinContent(bin)*d; - aDerivative -= h->GetBinContent(bin)*d*d; + Double_t func = - d_i / (1.0 - t_i); + Double_t deriv = func / (1.0 - t_i); + for (Int_t par = 0; par < fNpar; ++par) { + Double_t r = 1.0 / (t_i + 1.0 / wgtFrac[par]); + func += a_ji[par] * r; + deriv -= a_ji[par] * r * r; } - if (TMath::Abs(aFunction) < 1e-12) break; - Double_t delta = -aFunction/aDerivative; + if (TMath::Abs(func) < 1e-12) return; // solution found + Double_t delta = - func / deriv; // update delta if (TMath::Abs(delta) > step) - delta = (delta > 0) ? step : -step; - ti += delta; - if (TMath::Abs(delta) < 1e-13) break; - } + delta = (delta > 0) ? step : -step; // correct delta if it becomes too large + t_i += delta; + if (TMath::Abs(delta) < 1e-13) return; // solution found + } // the loop breaks when the solution is found, or when the maximum number of iterations is exhausted + + Warning("FindPrediction", "Did not find solution for t_i in %d iterations", maxIter); return; } diff --git a/hist/hist/src/TGraph.cxx b/hist/hist/src/TGraph.cxx index cd88e559977c7..be134457df8e9 100644 --- a/hist/hist/src/TGraph.cxx +++ b/hist/hist/src/TGraph.cxx @@ -197,12 +197,34 @@ TGraph& TGraph::operator=(const TGraph &gr) fNpoints = gr.fNpoints; fMaxSize = gr.fMaxSize; + + // delete list of functions and their contents before copying it + if (fFunctions) { + // delete previous lists of functions + if (!fFunctions->IsEmpty()) { + fFunctions->SetBit(kInvalidObject); + // use TList::Remove to take into account the case the same object is + // added multiple times in the list + TObject *obj; + while ((obj = fFunctions->First())) { + while (fFunctions->Remove(obj)) { } + delete obj; + } + } + delete fFunctions; + } + if (gr.fFunctions) fFunctions = (TList*)gr.fFunctions->Clone(); else fFunctions = new TList; + + if (fHistogram) delete fHistogram; if (gr.fHistogram) fHistogram = new TH1F(*(gr.fHistogram)); else fHistogram = 0; + fMinimum = gr.fMinimum; fMaximum = gr.fMaximum; + if (fX) delete [] fX; + if (fY) delete [] fY; if (!fMaxSize) { fX = fY = 0; return *this; @@ -567,7 +589,7 @@ void TGraph::Browse(TBrowser *b) //______________________________________________________________________________ -Double_t TGraph::Chisquare(const TF1 *f1) const +Double_t TGraph::Chisquare(const TF1 *f1, Option_t * option) const { // Return the chisquare of this graph with respect to f1. // The chisquare is computed as the sum of the quantity below at each point: @@ -580,43 +602,58 @@ Double_t TGraph::Chisquare(const TF1 *f1) const // In case of a pure TGraph, the denominator is 1. // In case of a TGraphErrors or TGraphAsymmErrors the errors are taken // into account. - - if (!f1) return 0; - Double_t cu, eu, exh, exl, ey, eux, fu, fsum; - Double_t x[1]; - Double_t chi2 = 0; - TF1 *func = (TF1*)f1; //EvalPar is not const ! - for (Int_t i = 0; i < fNpoints; i++) { - func->InitArgs(x, 0); //must be inside the loop because of TF1::Derivative calling InitArgs - x[0] = fX[i]; - if (!func->IsInside(x)) continue; - cu = fY[i]; - TF1::RejectPoint(kFALSE); - fu = func->EvalPar(x); - if (TF1::RejectedPoint()) continue; - fsum = (cu - fu); - //npfits++; - exh = GetErrorXhigh(i); - exl = GetErrorXlow(i); - if (fsum < 0) - ey = GetErrorYhigh(i); - else - ey = GetErrorYlow(i); - if (exl < 0) exl = 0; - if (exh < 0) exh = 0; - if (ey < 0) ey = 0; - if (exh > 0 || exl > 0) { - //"Effective Variance" method introduced by Anna Kreshuk - //a copy of the algorithm in GraphFitChisquare from TFitter - eux = 0.5 * (exl + exh) * func->Derivative(x[0]); - } else - eux = 0.; - eu = ey * ey + eux * eux; - if (eu <= 0) eu = 1; - chi2 += fsum * fsum / eu; - } - return chi2; -} + // By default the range of the graph is used whatever function range. + // Use option "R" to use the function range + + // need to cast away the const - since it requires evaluating the function which is not const + TF1 * func = const_cast<TF1*>(f1); + if (!func) { + Error("Chisquare","Function pointer is Null - return -1"); + return -1; + } + + TString opt(option); opt.ToUpper(); + bool useRange = opt.Contains("R"); + + return ROOT::Fit::Chisquare(*this, *func,useRange); +} + + +// Double_t cu, eu, exh, exl, ey, eux, fu, fsum; +// Double_t x[1]; +// Double_t chi2 = 0; +// TF1 *func = (TF1*)f1; //EvalPar is not const ! +// for (Int_t i = 0; i < fNpoints; i++) { +// func->InitArgs(x, 0); //must be inside the loop because of TF1::Derivative calling InitArgs +// x[0] = fX[i]; +// if (!func->IsInside(x)) continue; +// cu = fY[i]; +// TF1::RejectPoint(kFALSE); +// fu = func->EvalPar(x); +// if (TF1::RejectedPoint()) continue; +// fsum = (cu - fu); +// //npfits++; +// exh = GetErrorXhigh(i); +// exl = GetErrorXlow(i); +// if (fsum < 0) +// ey = GetErrorYhigh(i); +// else +// ey = GetErrorYlow(i); +// if (exl < 0) exl = 0; +// if (exh < 0) exh = 0; +// if (ey < 0) ey = 0; +// if (exh > 0 || exl > 0) { +// //"Effective Variance" method introduced by Anna Kreshuk +// //a copy of the algorithm in GraphFitChisquare from TFitter +// eux = 0.5 * (exl + exh) * func->Derivative(x[0]); +// } else +// eux = 0.; +// eu = ey * ey + eux * eux; +// if (eu <= 0) eu = 1; +// chi2 += fsum * fsum / eu; +// } +// return chi2; +// } //______________________________________________________________________________ @@ -730,6 +767,8 @@ Bool_t TGraph::CtorAllocate() { // In constructors set fNpoints than call this method. // Return kFALSE if the graph will contain no points. + //Note: This function should be called only from the constructor + // since it does not delete previously existing arrays fHistogram = 0; fMaximum = -1111; @@ -780,6 +819,15 @@ void TGraph::Draw(Option_t *option) if (!gPad->IsEditable()) gROOT->MakeDefCanvas(); if (opt.Contains("a")) gPad->Clear(); } + // If no option is specified, it is defined as "alp" in case there + // no current pad or if the current pad as no axis defined. + if (!strlen(option)) { + if (gPad) { + if (!gPad->GetListOfPrimitives()->FindObject("TFrame")) opt = "alp"; + } else { + opt = "alp"; + } + } AppendPad(opt); } @@ -1094,7 +1142,7 @@ TFitResultPtr TGraph::Fit(TF1 *f1, Option_t *option, Option_t *goption, Axis_t r // = "C" In case of linear fitting, do not calculate the chisquare // (saves time) // = "F" If fitting a polN, use the minuit fitter - // = "EX0" When fitting a TGraphErrors do not consider errors in the coordinate + // = "EX0" When fitting a TGraphErrors or TGraphAsymErrors do not consider errors in the coordinate // = "ROB" In case of linear fitting, compute the LTS regression // coefficients (robust (resistant) regression), using // the default fraction of good points @@ -1235,7 +1283,7 @@ TFitResultPtr TGraph::Fit(TF1 *f1, Option_t *option, Option_t *goption, Axis_t r // TMatrixDSym cov = r->GetCovarianceMatrix(); // to access the covariance matrix // Double_t chi2 = r->Chi2(); // to retrieve the fit chi2 // Double_t par0 = r->Value(0); // retrieve the value for the parameter 0 - // Double_t err0 = r->Error(0); // retrieve the error for the parameter 0 + // Double_t err0 = r->ParError(0); // retrieve the error for the parameter 0 // r->Print("V"); // print full information of fit including covariance matrix // r->Write(); // store the result in a file // @@ -1254,7 +1302,7 @@ TFitResultPtr TGraph::Fit(TF1 *f1, Option_t *option, Option_t *goption, Axis_t r // ===================== // The status of the fit can be obtained converting the TFitResultPtr to an integer // indipendently if the fit option "S" is used or not: - // TFitResultPtr r = h=>Fit(myFunc,opt); + // TFitResultPtr r = h->Fit(myFunc,opt); // Int_t fitStatus = r; // // The fitStatus is 0 if the fit is OK (i.e. no error occurred). diff --git a/hist/hist/src/TGraph2D.cxx b/hist/hist/src/TGraph2D.cxx index ae24227307692..84f8a35cac8bb 100644 --- a/hist/hist/src/TGraph2D.cxx +++ b/hist/hist/src/TGraph2D.cxx @@ -190,7 +190,7 @@ Begin_Macro(source) z = sin(sqrt(x*x+y*y))+1; dt->SetPoint(k,x,y,z); k++; - y = y+dx; + y = y+dy; } x = x+dx; y = -P; @@ -309,6 +309,7 @@ TGraph2D::TGraph2D(TH2 *h2) // Graph2D constructor with a TH2 (h2) as input. // Only the h2's bins within the X and Y axis ranges are used. // Empty bins, recognized when both content and errors are zero, are excluded. + Build(h2->GetNbinsX()*h2->GetNbinsY()); TString gname = "Graph2D_from_" + TString(h2->GetName()); @@ -394,15 +395,15 @@ TGraph2D::TGraph2D(const char *filename, const char *format, Option_t *option) // filename is assumed to contain at least three columns of numbers. // For files separated by a specific delimiter different from ' ' and '\t' (e.g. ';' in csv files) // you can avoid using %*s to bypass this delimiter by explicitly specify the "option" argument, - // e.g. option=" \t,;" for columns of figures separated by any of these characters (' ', '\t', ',', ';') - // used once (e.g. "1;1") or in a combined way (" 1;,;; 1"). + // e.g. option=" \t,;" for columns of figures separated by any of these characters (' ', '\t', ',', ';') + // used once (e.g. "1;1") or in a combined way (" 1;,;; 1"). // Note in that case, the instanciation is about 2 times slower. Double_t x, y, z; TString fname = filename; gSystem->ExpandPathName(fname); - ifstream infile(fname.Data()); + std::ifstream infile(fname.Data()); if (!infile.good()) { MakeZombie(); Error("TGraph2D", "Cannot open file: %s, TGraph2D is Zombie", filename); @@ -466,7 +467,7 @@ TGraph2D::TGraph2D(const char *filename, const char *format, Option_t *option) // Looping while (std::getline(infile, line, '\n')) { - if (line[line.size() - 1] == char(13)) { // removing DOS CR character + if (line[line.size() - 1] == char(13)) { // removing DOS CR character line.erase(line.end() - 1, line.end()) ; } if (line != "") { @@ -591,6 +592,16 @@ void TGraph2D::Build(Int_t n) } +//______________________________________________________________________________ +void TGraph2D::Browse(TBrowser *) +{ + // Browse + + Draw("p0"); + gPad->Update(); +} + + //______________________________________________________________________________ void TGraph2D::Clear(Option_t * /*option = "" */) { @@ -602,7 +613,8 @@ void TGraph2D::Clear(Option_t * /*option = "" */) fY = 0; delete [] fZ; fZ = 0; - if (fFunctions) { + fSize = fNpoints = 0; + if (fHistogram && !fUserHisto) { delete fHistogram; fHistogram = 0; } @@ -891,6 +903,7 @@ void TGraph2D::FitPanel() // Display a GUI panel with all graph fit options. // // See class TFitEditor for example + if (!gPad) gROOT->MakeDefCanvas(); @@ -915,8 +928,7 @@ TAxis *TGraph2D::GetXaxis() const { // Get x axis of the graph. - //if (!gPad) return 0; - TH1 *h = ((TGraph2D*)this)->GetHistogram(); + TH1 *h = ((TGraph2D*)this)->GetHistogram("empty"); if (!h) return 0; return h->GetXaxis(); } @@ -927,8 +939,7 @@ TAxis *TGraph2D::GetYaxis() const { // Get y axis of the graph. - //if (!gPad) return 0; - TH1 *h = ((TGraph2D*)this)->GetHistogram(); + TH1 *h = ((TGraph2D*)this)->GetHistogram("empty"); if (!h) return 0; return h->GetYaxis(); } @@ -939,8 +950,7 @@ TAxis *TGraph2D::GetZaxis() const { // Get z axis of the graph. - //if (!gPad) return 0; - TH1 *h = ((TGraph2D*)this)->GetHistogram(); + TH1 *h = ((TGraph2D*)this)->GetHistogram("empty"); if (!h) return 0; return h->GetZaxis(); } @@ -1042,6 +1052,24 @@ TH2D *TGraph2D::GetHistogram(Option_t *option) hymin = ymin - fMargin * (ymax - ymin); hxmax = xmax + fMargin * (xmax - xmin); hymax = ymax + fMargin * (ymax - ymin); + if (hxmin==hxmax) { + if (hxmin==0) { + hxmin = -0.01; + hxmax = 0.01; + } else { + hxmin = hxmin-hxmin*0.01; + hxmax = hxmax+hxmax*0.01; + } + } + if (hymin==hymax) { + if (hxmin==0) { + hymin = -0.01; + hymax = 0.01; + } else { + hymin = hymin-hymin*0.01; + hymax = hymax+hymax*0.01; + } + } fHistogram = new TH2D(GetName(), GetTitle(), fNpx , hxmin, hxmax, fNpy, hymin, hymax); @@ -1362,24 +1390,24 @@ Int_t TGraph2D::RemovePoint(Int_t ipoint) //______________________________________________________________________________ -void TGraph2D::SavePrimitive(ostream &out, Option_t *option /*= ""*/) +void TGraph2D::SavePrimitive(std::ostream &out, Option_t *option /*= ""*/) { // Saves primitive as a C++ statement(s) on output stream out char quote = '"'; - out << " " << endl; + out << " " << std::endl; if (gROOT->ClassSaved(TGraph2D::Class())) { out << " "; } else { out << " TGraph2D *"; } - out << "graph2d = new TGraph2D(" << fNpoints << ");" << endl; - out << " graph2d->SetName(" << quote << GetName() << quote << ");" << endl; - out << " graph2d->SetTitle(" << quote << GetTitle() << quote << ");" << endl; + out << "graph2d = new TGraph2D(" << fNpoints << ");" << std::endl; + out << " graph2d->SetName(" << quote << GetName() << quote << ");" << std::endl; + out << " graph2d->SetTitle(" << quote << GetTitle() << quote << ");" << std::endl; if (fDirectory == 0) { - out << " " << GetName() << "->SetDirectory(0);" << endl; + out << " " << GetName() << "->SetDirectory(0);" << std::endl; } SaveFillAttributes(out, "graph2d", 0, 1001); @@ -1387,7 +1415,7 @@ void TGraph2D::SavePrimitive(ostream &out, Option_t *option /*= ""*/) SaveMarkerAttributes(out, "graph2d", 1, 1, 1); for (Int_t i = 0; i < fNpoints; i++) { - out << " graph2d->SetPoint(" << i << "," << fX[i] << "," << fY[i] << "," << fZ[i] << ");" << endl; + out << " graph2d->SetPoint(" << i << "," << fX[i] << "," << fY[i] << "," << fZ[i] << ");" << std::endl; } // save list of functions @@ -1395,13 +1423,13 @@ void TGraph2D::SavePrimitive(ostream &out, Option_t *option /*= ""*/) TObject *obj; while ((obj = next())) { obj->SavePrimitive(out, "nodraw"); - out << " graph2d->GetListOfFunctions()->Add(" << obj->GetName() << ");" << endl; + out << " graph2d->GetListOfFunctions()->Add(" << obj->GetName() << ");" << std::endl; if (obj->InheritsFrom("TPaveStats")) { - out << " ptstats->SetParent(graph2d->GetListOfFunctions());" << endl; + out << " ptstats->SetParent(graph2d->GetListOfFunctions());" << std::endl; } } - out << " graph2d->Draw(" << quote << option << quote << ");" << endl; + out << " graph2d->Draw(" << quote << option << quote << ");" << std::endl; } @@ -1441,13 +1469,13 @@ void TGraph2D::SetHistogram(TH2 *h) // Sets the histogram to be filled. // If the 2D graph needs to be save in a TFile the folllowing set should be // followed to read it back: - // 1) Create TGraph2D - // 2) Call g->SetHistogram(h), and do whatever you need to do - // 3) Save g and h to the TFile, exit - // 4) Open the TFile, retrieve g and h - // 5) Call h->SetDirectory(0) - // 6) Call g->SetHistogram(h) again - // 7) Carry on as normal + // 1) Create TGraph2D + // 2) Call g->SetHistogram(h), and do whatever you need to do + // 3) Save g and h to the TFile, exit + // 4) Open the TFile, retrieve g and h + // 5) Call h->SetDirectory(0) + // 6) Call g->SetHistogram(h) again + // 7) Carry on as normal fUserHisto = kTRUE; fHistogram = (TH2D*)h; @@ -1494,7 +1522,8 @@ void TGraph2D::SetMaximum(Double_t maximum) // Set maximum. fMaximum = maximum; - GetHistogram()->SetMaximum(maximum); + TH1 * h = GetHistogram(); + if (h) h->SetMaximum(maximum); } @@ -1504,7 +1533,8 @@ void TGraph2D::SetMinimum(Double_t minimum) // Set minimum. fMinimum = minimum; - GetHistogram()->SetMinimum(minimum); + TH1 * h = GetHistogram(); + if (h) h->SetMinimum(minimum); } diff --git a/hist/hist/src/TGraphAsymmErrors.cxx b/hist/hist/src/TGraphAsymmErrors.cxx index 7bed730fb85a5..c1dabed3db4b8 100644 --- a/hist/hist/src/TGraphAsymmErrors.cxx +++ b/hist/hist/src/TGraphAsymmErrors.cxx @@ -99,6 +99,12 @@ TGraphAsymmErrors& TGraphAsymmErrors::operator=(const TGraphAsymmErrors &gr) if(this!=&gr) { TGraph::operator=(gr); + // delete arrays + if (fEXlow) delete [] fEXlow; + if (fEYlow) delete [] fEYlow; + if (fEXhigh) delete [] fEXhigh; + if (fEYhigh) delete [] fEYhigh; + if (!CtorAllocate()) return *this; Int_t n = fNpoints*sizeof(Double_t); memcpy(fEXlow, gr.fEXlow, n); @@ -630,29 +636,38 @@ void TGraphAsymmErrors::Divide(const TH1* pass, const TH1* total, Option_t *opt) //using bayesian statistics - if(bIsBayesian) { + if(bIsBayesian) { double aa,bb; - if (bEffective) { - // tw/tw2 renormalize the weights - double norm = (tw2 > 0) ? tw/tw2 : 0.; - aa = pw * norm + alpha; - bb = (tw - pw) * norm + beta; - } - else { - aa = double(p) + alpha; - bb = double(t-p) + beta; - } - if (usePosteriorMode) - eff = TEfficiency::BetaMode(aa,bb); - else - eff = TEfficiency::BetaMean(aa,bb); - if (useShortestInterval) { - TEfficiency::BetaShortestInterval(conf,aa,bb,low,upper); + if (bEffective && tw2 <= 0) { + // case of bins with zero errors + eff = pw/tw; + low = eff; upper = eff; } - else { - low = TEfficiency::BetaCentralInterval(conf,aa,bb,false); - upper = TEfficiency::BetaCentralInterval(conf,aa,bb,true); + else { + + if (bEffective) { + // tw/tw2 renormalize the weights + double norm = tw/tw2; // case of tw2 = 0 is treated above + aa = pw * norm + alpha; + bb = (tw - pw) * norm + beta; + } + else { + aa = double(p) + alpha; + bb = double(t-p) + beta; + } + if (usePosteriorMode) + eff = TEfficiency::BetaMode(aa,bb); + else + eff = TEfficiency::BetaMean(aa,bb); + + if (useShortestInterval) { + TEfficiency::BetaShortestInterval(conf,aa,bb,low,upper); + } + else { + low = TEfficiency::BetaCentralInterval(conf,aa,bb,false); + upper = TEfficiency::BetaCentralInterval(conf,aa,bb,true); + } } } // case of non-bayesian statistics @@ -802,6 +817,8 @@ Bool_t TGraphAsymmErrors::CopyPoints(Double_t **arrays, Bool_t TGraphAsymmErrors::CtorAllocate(void) { // Should be called from ctors after fNpoints has been set + // Note: This function should be called only from the constructor + // since it does not delete previously existing arrays if (!fNpoints) { fEXlow = fEYlow = fEXhigh = fEYhigh = 0; diff --git a/hist/hist/src/TGraphDelaunay.cxx b/hist/hist/src/TGraphDelaunay.cxx index 8c867c9541502..3cc2a5c4f8a60 100644 --- a/hist/hist/src/TGraphDelaunay.cxx +++ b/hist/hist/src/TGraphDelaunay.cxx @@ -252,7 +252,7 @@ void TGraphDelaunay::FileIt(Int_t p, Int_t n, Int_t m) if (swap) goto L1; // expand the triangles storage if needed - if (fNdt> fTriedSize) { + if (fNdt>=fTriedSize) { Int_t newN = 2*fTriedSize; Int_t *savep = new Int_t [newN]; Int_t *saven = new Int_t [newN]; diff --git a/hist/hist/src/TGraphErrors.cxx b/hist/hist/src/TGraphErrors.cxx index 0dd7ceefe5775..b24af57501964 100644 --- a/hist/hist/src/TGraphErrors.cxx +++ b/hist/hist/src/TGraphErrors.cxx @@ -197,6 +197,9 @@ TGraphErrors& TGraphErrors::operator=(const TGraphErrors &gr) if (this != &gr) { TGraph::operator=(gr); + // N.B CtorAllocate does not delete arrays + if (fEX) delete [] fEX; + if (fEY) delete [] fEY; if (!CtorAllocate()) return *this; Int_t n = sizeof(Double_t) * fNpoints; @@ -518,6 +521,9 @@ Bool_t TGraphErrors::CopyPoints(Double_t **arrays, Int_t ibegin, Int_t iend, Bool_t TGraphErrors::CtorAllocate() { // Constructor allocate. + //Note: This function should be called only from the constructor + // since it does not delete previously existing arrays + if (!fNpoints) { fEX = fEY = 0; diff --git a/hist/hist/src/TH1.cxx b/hist/hist/src/TH1.cxx index 00430e92cf393..fb0ad87481f34 100644 --- a/hist/hist/src/TH1.cxx +++ b/hist/hist/src/TH1.cxx @@ -802,7 +802,6 @@ Bool_t TH1::Add(TF1 *f1, Double_t c1, Option_t *option) SetMinimum(); SetMaximum(); - // - Loop on bins (including underflows/overflows) Int_t bin, binx, biny, binz; Double_t cu=0; @@ -845,8 +844,8 @@ Bool_t TH1::Add(const TH1 *h1, Double_t c1) // if errors are defined (see TH1::Sumw2), errors are also recalculated. // Note that if h1 has Sumw2 set, Sumw2 is automatically called for this // if not already set. -// Note also that adding histogram with labels is not supported, histogram will be -// added merging them by bin number independently of the labels. +// Note also that adding histogram with labels is not supported, histogram will be +// added merging them by bin number independently of the labels. // For adding histogram with labels one should use TH1::Merge // // SPECIAL CASE (Average/Efficiency histograms) @@ -890,7 +889,7 @@ Bool_t TH1::Add(const TH1 *h1, Double_t c1) } catch(DifferentLabels&) { Warning("Add","Attempt to add histograms with different labels"); } - + if (fDimension < 2) nbinsy = -1; if (fDimension < 3) nbinsz = -1; @@ -906,7 +905,7 @@ Bool_t TH1::Add(const TH1 *h1, Double_t c1) Double_t s1[kNstat] = {0}; Double_t s2[kNstat] = {0}; if (!resetStats) { - // need to initialize to zero s1 and s2 since + // need to initialize to zero s1 and s2 since // GetStats fills only used elements depending on dimension and type GetStats(s1); h1->GetStats(s2); @@ -933,34 +932,34 @@ Bool_t TH1::Add(const TH1 *h1, Double_t c1) Double_t w1 = 1., w2 = 1.; // consider all special cases when bin errors are zero // see http://root.cern.ch/phpBB3//viewtopic.php?f=3&t=13299 - if (e1 > 0 ) + if (e1 > 0 ) w1 = 1./(e1*e1); - else if (h1->fSumw2.fN) { + else if (h1->fSumw2.fN) { w1 = 1.E200; // use an arbitrary huge value - if (y1 == 0) { + if (y1 == 0) { // use an estimated error from the global histogram scale - double sf = (s2[0] != 0) ? s2[1]/s2[0] : 1; - w1 = 1./(sf*sf); + double sf = (s2[0] != 0) ? s2[1]/s2[0] : 1; + w1 = 1./(sf*sf); } } - if (e2 > 0) + if (e2 > 0) w2 = 1./(e2*e2); - else if (fSumw2.fN) { + else if (fSumw2.fN) { w2 = 1.E200; // use an arbitrary huge value - if (y2 == 0) { + if (y2 == 0) { // use an estimated error from the global histogram scale - double sf = (s1[0] != 0) ? s1[1]/s1[0] : 1; - w2 = 1./(sf*sf); + double sf = (s1[0] != 0) ? s1[1]/s1[0] : 1; + w2 = 1./(sf*sf); } - } + } double y = (w1*y1 + w2*y2)/(w1 + w2); SetBinContent(bin, y); - if (fSumw2.fN) { + if (fSumw2.fN) { double err2 = 1./(w1 + w2); if (err2 < 1.E-200) err2 = 0; // to remove arbitrary value when e1=0 AND e2=0 fSumw2.fArray[bin] = err2; - } - } + } + } //normal case of addition between histograms else { cu = c1*factor*h1->GetBinContent(bin); @@ -1000,8 +999,8 @@ Bool_t TH1::Add(const TH1 *h1, const TH1 *h2, Double_t c1, Double_t c2) // if errors are defined (see TH1::Sumw2), errors are also recalculated // Note that if h1 or h2 have Sumw2 set, Sumw2 is automatically called for this // if not already set. -// Note also that adding histogram with labels is not supported, histogram will be -// added merging them by bin number independently of the labels. +// Note also that adding histogram with labels is not supported, histogram will be +// added merging them by bin number independently of the labels. // For adding histogram ith labels one should use TH1::Merge // // SPECIAL CASE (Average/Efficiency histograms) @@ -1015,7 +1014,7 @@ Bool_t TH1::Add(const TH1 *h1, const TH1 *h2, Double_t c1, Double_t c2) // you should call Sumw2 before making this operation. // This is particularly important if you fit the histogram after TH1::Add // -//ANOTHER SPECIAL CASE : h1 = h2 and c2 < 0 +//ANOTHER SPECIAL CASE : h1 = h2 and c2 < 0 // do a scaling this = c1 * h1 / (bin Volume) // // The function returns kFALSE if the Add operation failed @@ -1032,10 +1031,10 @@ Bool_t TH1::Add(const TH1 *h1, const TH1 *h2, Double_t c1, Double_t c2) Bool_t normWidth = kFALSE; if (h1 == h2 && c2 < 0) {c2 = 0; normWidth = kTRUE;} Int_t nbinsx = GetNbinsX(); - Int_t nbinsy = GetNbinsY(); + Int_t nbinsy = GetNbinsY(); Int_t nbinsz = GetNbinsZ(); - if (h1 != h2) { + if (h1 != h2) { try { CheckConsistency(h1,h2); CheckConsistency(this,h1); @@ -1053,7 +1052,6 @@ Bool_t TH1::Add(const TH1 *h1, const TH1 *h2, Double_t c1, Double_t c2) if (fDimension < 2) nbinsy = -1; if (fDimension < 3) nbinsz = -1; - if (fDimension < 3) nbinsz = -1; // Create Sumw2 if h1 or h2 have Sumw2 set if (fSumw2.fN == 0 && (h1->GetSumw2N() != 0 || h2->GetSumw2N() != 0)) Sumw2(); @@ -1069,7 +1067,7 @@ Bool_t TH1::Add(const TH1 *h1, const TH1 *h2, Double_t c1, Double_t c2) Double_t s3[kNstat]; Bool_t resetStats = (c1*c2 < 0) || normWidth; if (!resetStats) { - // need to initialize to zero s1 and s2 since + // need to initialize to zero s1 and s2 since // GetStats fills only used elements depending on dimension and type h1->GetStats(s1); h2->GetStats(s2); @@ -1091,10 +1089,6 @@ Bool_t TH1::Add(const TH1 *h1, const TH1 *h2, Double_t c1, Double_t c2) Bool_t timeDisplayX = fXaxis.GetTimeDisplay(); if (timeDisplayX) fXaxis.SetTimeDisplay(0); - - - - // - Loop on bins (including underflows/overflows) Int_t bin, binx, biny, binz; @@ -1115,36 +1109,36 @@ Bool_t TH1::Add(const TH1 *h1, const TH1 *h2, Double_t c1, Double_t c2) Double_t w1 = 1., w2 = 1.; // consider all special cases when bin errors are zero // see http://root.cern.ch/phpBB3//viewtopic.php?f=3&t=13299 - if (e1 > 0 ) + if (e1 > 0 ) w1 = 1./(e1*e1); - else if (h1->fSumw2.fN) { + else if (h1->fSumw2.fN) { w1 = 1.E200; // use an arbitrary huge value - if (y1 == 0 ) { + if (y1 == 0 ) { // use an estimated error from the global histogram scale - double sf = (s1[0] != 0) ? s1[1]/s1[0] : 1; - w1 = 1./(sf*sf); + double sf = (s1[0] != 0) ? s1[1]/s1[0] : 1; + w1 = 1./(sf*sf); } } - if (e2 > 0) + if (e2 > 0) w2 = 1./(e2*e2); - else if (h2->fSumw2.fN) { + else if (h2->fSumw2.fN) { w2 = 1.E200; // use an arbitrary huge value - if (y2 == 0) { + if (y2 == 0) { // use an estimated error from the global histogram scale - double sf = (s2[0] != 0) ? s2[1]/s2[0] : 1; - w2 = 1./(sf*sf); + double sf = (s2[0] != 0) ? s2[1]/s2[0] : 1; + w2 = 1./(sf*sf); } - } + } double y = (w1*y1 + w2*y2)/(w1 + w2); SetBinContent(bin, y); - if (fSumw2.fN) { + if (fSumw2.fN) { double err2 = 1./(w1 + w2); if (err2 < 1.E-200) err2 = 0; // to remove arbitrary value when e1=0 AND e2=0 fSumw2.fArray[bin] = err2; - } - } + } + } - // case of histogram Addition + // case of histogram Addition else { if (normWidth) { Double_t w = wx*wy*wz; @@ -1223,25 +1217,25 @@ Int_t TH1::BufferEmpty(Int_t action) { // Fill histogram with all entries in the buffer. // action = -1 histogram is reset and refilled from the buffer (called by THistPainter::Paint) -// action = 0 histogram is reset and filled from the buffer. When the histogram is filled from the +// action = 0 histogram is reset and filled from the buffer. When the histogram is filled from the // buffer the value fBuffer[0] is set to a negative number (= - number of entries) -// When calling with action == 0 the histogram is NOT refilled when fBuffer[0] is < 0 +// When calling with action == 0 the histogram is NOT refilled when fBuffer[0] is < 0 // While when calling with action = -1 the histogram is reset and ALWAYS refilled independently if -// the histogram was filled before. This is needed when drawing the histogram -// +// the histogram was filled before. This is needed when drawing the histogram +// // action = 1 histogram is filled and buffer is deleted -// The buffer is automatically deleted when filling the histogram and the entries is -// larger than the buffer size +// The buffer is automatically deleted when filling the histogram and the entries is +// larger than the buffer size // // do we need to compute the bin size? if (!fBuffer) return 0; Int_t nbentries = (Int_t)fBuffer[0]; - // nbentries correspond to the number of entries of histogram - + // nbentries correspond to the number of entries of histogram + if (nbentries == 0) return 0; - if (nbentries < 0 && action == 0) return 0; // case histogram has been already filled from the buffer + if (nbentries < 0 && action == 0) return 0; // case histogram has been already filled from the buffer Double_t *buffer = fBuffer; if (nbentries < 0) { @@ -1249,8 +1243,8 @@ Int_t TH1::BufferEmpty(Int_t action) // a reset might call BufferEmpty() giving an infinite loop // Protect it by setting fBuffer = 0 fBuffer=0; - //do not reset the list of functions - Reset("ICES"); + //do not reset the list of functions + Reset("ICES"); fBuffer = buffer; } if (TestBit(kCanRebin) || (fXaxis.GetXmax() <= fXaxis.GetXmin())) { @@ -1277,16 +1271,16 @@ Int_t TH1::BufferEmpty(Int_t action) FillN(nbentries,&fBuffer[2],&fBuffer[1],2); // if action == 1 - delete the buffer - if (action > 0) { - delete [] fBuffer; - fBuffer = 0; + if (action > 0) { + delete [] fBuffer; + fBuffer = 0; fBufferSize = 0;} else { - // if number of entries is consistent with buffer - set it negative to avoid - // refilling the histogram every time BufferEmpty(0) is called - // In case it is not consistent, by setting fBuffer[0]=0 is like resetting the buffer + // if number of entries is consistent with buffer - set it negative to avoid + // refilling the histogram every time BufferEmpty(0) is called + // In case it is not consistent, by setting fBuffer[0]=0 is like resetting the buffer // (it will not be used anymore the next time BufferEmpty is called) - if (nbentries == (Int_t)fEntries) + if (nbentries == (Int_t)fEntries) fBuffer[0] = -nbentries; else fBuffer[0] = 0; @@ -1308,13 +1302,13 @@ Int_t TH1::BufferFill(Double_t x, Double_t w) if (nbentries < 0) { // reset nbentries to a positive value so next time BufferEmpty() is called - // the histogram will be refilled + // the histogram will be refilled nbentries = -nbentries; fBuffer[0] = nbentries; if (fEntries > 0) { // set fBuffer to zero to avoid calling BufferEmpty in Reset Double_t *buffer = fBuffer; fBuffer=0; - Reset("ICES"); // do not reset list of functions + Reset("ICES"); // do not reset list of functions fBuffer = buffer; } } @@ -1331,8 +1325,8 @@ Int_t TH1::BufferFill(Double_t x, Double_t w) bool TH1::CheckBinLimits(const TAxis* a1, const TAxis * a2) { - const TArrayD * h1Array = a1->GetXbins(); - const TArrayD * h2Array = a2->GetXbins(); + const TArrayD * h1Array = a1->GetXbins(); + const TArrayD * h2Array = a2->GetXbins(); Int_t fN = h1Array->fN; if ( fN != 0 ) { if ( h2Array->fN != fN ) { @@ -1354,16 +1348,16 @@ bool TH1::CheckBinLimits(const TAxis* a1, const TAxis * a2) bool TH1::CheckBinLabels(const TAxis* a1, const TAxis * a2) { - // check that axis have same labels + // check that axis have same labels THashList *l1 = (const_cast<TAxis*>(a1))->GetLabels(); THashList *l2 = (const_cast<TAxis*>(a2))->GetLabels(); if (!l1 && !l2 ) - return true; + return true; if (!l1 || !l2 ) { throw DifferentLabels(); return false; - } + } // check now labels sizes are the same if (l1->GetSize() != l2->GetSize() ) { throw DifferentLabels(); @@ -1374,7 +1368,7 @@ bool TH1::CheckBinLabels(const TAxis* a1, const TAxis * a2) TString label2 = a2->GetBinLabel(i); if (label1 != label2) { throw DifferentLabels(); - return false; + return false; } } @@ -1397,31 +1391,31 @@ bool TH1::CheckAxisLimits(const TAxis *a1, const TAxis *a2 ) bool TH1::CheckEqualAxes(const TAxis *a1, const TAxis *a2 ) { - // Check that the axis are the same - if (a1->GetNbins() != a2->GetNbins() ) { + // Check that the axis are the same + if (a1->GetNbins() != a2->GetNbins() ) { //throw DifferentNumberOfBins(); ::Info("CheckEqualAxes","Axes have different number of bins : nbin1 = %d nbin2 = %d",a1->GetNbins(),a2->GetNbins() ); return false; } - try { + try { CheckAxisLimits(a1,a2); - } catch (DifferentAxisLimits&) { + } catch (DifferentAxisLimits&) { ::Info("CheckEqualAxes","Axes have different limits"); - return false; + return false; } - try { + try { CheckBinLimits(a1,a2); - } catch (DifferentBinLimits&) { + } catch (DifferentBinLimits&) { ::Info("CheckEqualAxes","Axes have different bin limits"); - return false; + return false; } // check labels - try { + try { CheckBinLabels(a1,a2); - } catch (DifferentLabels&) { + } catch (DifferentLabels&) { ::Info("CheckEqualAxes","Axes have different labels"); - return false; + return false; } return true; @@ -1429,7 +1423,7 @@ bool TH1::CheckEqualAxes(const TAxis *a1, const TAxis *a2 ) bool TH1::CheckConsistentSubAxes(const TAxis *a1, Int_t firstBin1, Int_t lastBin1, const TAxis * a2, Int_t firstBin2, Int_t lastBin2 ) { - // Check that two sub axis are the same + // Check that two sub axis are the same // the limits are defined by first bin and last bin // N.B. no check is done in this case for variable bins @@ -1438,18 +1432,18 @@ bool TH1::CheckConsistentSubAxes(const TAxis *a1, Int_t firstBin1, Int_t lastBin Double_t xmin1 = a1->GetBinLowEdge(firstBin1); Double_t xmax1 = a1->GetBinUpEdge(lastBin1); - Int_t nbins2 = a2->GetNbins(); - Double_t xmin2 = a2->GetXmin(); + Int_t nbins2 = a2->GetNbins(); + Double_t xmin2 = a2->GetXmin(); Double_t xmax2 = a2->GetXmax(); - if (firstBin2 < lastBin2) { + if (firstBin2 < lastBin2) { // in this case assume no bins are given for the second axis nbins2 = lastBin1-firstBin1 + 1; xmin2 = a1->GetBinLowEdge(firstBin1); xmax2 = a1->GetBinUpEdge(lastBin1); } - if (nbins1 != nbins2 ) { + if (nbins1 != nbins2 ) { ::Info("CheckConsistentSubAxes","Axes have different number of bins"); return false; } @@ -1467,7 +1461,7 @@ bool TH1::CheckConsistentSubAxes(const TAxis *a1, Int_t firstBin1, Int_t lastBin bool TH1::CheckConsistency(const TH1* h1, const TH1* h2) { // Check histogram compatibility - if (h1 == h2) return true; + if (h1 == h2) return true; // returns kTRUE if number of bins and bin limits are identical Int_t nbinsx = h1->GetNbinsX(); @@ -1480,7 +1474,7 @@ bool TH1::CheckConsistency(const TH1* h1, const TH1* h2) return false; } - bool ret = true; + bool ret = true; // check axis limits ret &= CheckAxisLimits(h1->GetXaxis(), h2->GetXaxis()); @@ -1492,10 +1486,13 @@ bool TH1::CheckConsistency(const TH1* h1, const TH1* h2) ret &= CheckBinLimits(h1->GetYaxis(), h2->GetYaxis()); ret &= CheckBinLimits(h1->GetZaxis(), h2->GetZaxis()); - // check labels - ret &= CheckBinLabels(h1->GetXaxis(), h2->GetXaxis()); - ret &= CheckBinLabels(h1->GetYaxis(), h2->GetYaxis()); - ret &= CheckBinLabels(h1->GetZaxis(), h2->GetZaxis()); + // check labels if histograms are both not empty + if ( (h1->fTsumw != 0 || h1->GetEntries() != 0) && + (h2->fTsumw != 0 || h2->GetEntries() != 0) ) { + ret &= CheckBinLabels(h1->GetXaxis(), h2->GetXaxis()); + ret &= CheckBinLabels(h1->GetYaxis(), h2->GetYaxis()); + ret &= CheckBinLabels(h1->GetZaxis(), h2->GetZaxis()); + } return ret; } @@ -2066,7 +2063,7 @@ Double_t TH1::Chi2TestX(const TH1* h2, Double_t &chi2, Int_t &ndf, Int_t &igood } else bin1 = 0; - + err2 = h2->GetBinError(i,j,k); if (err2 > 0) { bin2 *= bin2/(err2*err2); @@ -2075,7 +2072,7 @@ Double_t TH1::Chi2TestX(const TH1* h2, Double_t &chi2, Int_t &ndf, Int_t &igood } else bin2 = 0; - + } if ( (int(bin1) == 0) && (int(bin2) == 0) ) { @@ -2264,7 +2261,7 @@ Double_t TH1::Chi2TestX(const TH1* h2, Double_t &chi2, Int_t &ndf, Int_t &igood } if ( (err1 == 0) && (err2 == 0) ) { - // cannot treat case of booth histogram have zero zero errors + // cannot treat case of booth histogram have zero zero errors Error("Chi2TestX","h1 and h2 both have bin %d,%d,%d with all zero errors\n", i,j,k); chi2 = 0; return 0; } @@ -2311,7 +2308,25 @@ Double_t TH1::Chi2TestX(const TH1* h2, Double_t &chi2, Int_t &ndf, Int_t &igood } return 0; } +//______________________________________________________________________________ +Double_t TH1::Chisquare(TF1 * func, Option_t *option) const +{ + // Compute and return the chisquare of this histogram with respect to a function + // The chisquare is computed by weighting each histogram point by the bin error + // By default the full range of the histogram is used. + // Use option "R" for restricting the chisquare calculation to the given range of the function + + if (!func) { + Error("Chisquare","Function pointer is Null - return -1"); + return -1; + } + TString opt(option); opt.ToUpper(); + bool useRange = opt.Contains("R"); + + return ROOT::Fit::Chisquare(*this, *func, useRange); + +} //______________________________________________________________________________ Double_t TH1::ComputeIntegral() { @@ -2363,8 +2378,8 @@ Double_t *TH1::GetIntegral() // if the pointer fIntegral is null, TH1::ComputeIntegral is called // The array dimension is the number of bins in the histograms // including underflow and overflow (fNCells) - // the last value integral[fNCells] is set to the number of entries of - // the histogram + // the last value integral[fNCells] is set to the number of entries of + // the histogram if (!fIntegral) ComputeIntegral(); return fIntegral; @@ -2393,25 +2408,39 @@ void TH1::Copy(TObject &obj) const ((TH1&)obj).fBarOffset = fBarOffset; ((TH1&)obj).fBarWidth = fBarWidth; ((TH1&)obj).fOption = fOption; - ((TH1&)obj).fBuffer = 0; ((TH1&)obj).fBufferSize= fBufferSize; + // copy the Buffer + // delete first a previously existing buffer + if (((TH1&)obj).fBuffer != 0) { + delete [] ((TH1&)obj).fBuffer; + ((TH1&)obj).fBuffer = 0; + } + if (fBuffer) { + Double_t *buf = new Double_t[fBufferSize]; + for (Int_t i=0;i<fBufferSize;i++) buf[i] = fBuffer[i]; + // obj.fBuffer has been deleted before + ((TH1&)obj).fBuffer = buf; + } + TArray* a = dynamic_cast<TArray*>(&obj); if (a) a->Set(fNcells); Int_t canRebin = ((TH1&)obj).TestBit(kCanRebin); ((TH1&)obj).ResetBit(kCanRebin); //we want to avoid the call to LabelsInflate + // we need to set fBuffer to zero to avoid calling BufferEmpty in GetBinContent + Double_t * buffer = 0; + if (fBuffer) { + buffer = fBuffer; + ((TH1*)this)->fBuffer = 0; + } for (Int_t i=0;i<fNcells;i++) ((TH1&)obj).SetBinContent(i,this->GetBinContent(i)); + // restore rebin bit and buffer pointer if (canRebin) ((TH1&)obj).SetBit(kCanRebin); + if (buffer) ((TH1*)this)->fBuffer = buffer; ((TH1&)obj).fEntries = fEntries; - // copy the Buffer (needs to do after calling Get/SetBinContent - // which will call BufferEmpty. Maybe one should call + // which will call BufferEmpty(0) and set fBuffer[0] to a Maybe one should call // assignment operator on the TArrayD - if (fBuffer) { - Double_t *buf = new Double_t[fBufferSize]; - for (Int_t i=0;i<fBufferSize;i++) buf[i] = fBuffer[i]; - ((TH1&)obj).fBuffer = buf; - } ((TH1&)obj).fTsumw = fTsumw; ((TH1&)obj).fTsumw2 = fTsumw2; @@ -2504,7 +2533,6 @@ Bool_t TH1::Divide(TF1 *f1, Double_t c1) if (fDimension < 2) nbinsy = -1; if (fDimension < 3) nbinsz = -1; - SetMinimum(); SetMaximum(); @@ -2512,7 +2540,6 @@ Bool_t TH1::Divide(TF1 *f1, Double_t c1) // would resize the axis limits! ResetBit(kCanRebin); - // - Loop on bins (including underflows/overflows) Int_t bin, binx, biny, binz; Double_t cu,w; @@ -2587,8 +2614,11 @@ Bool_t TH1::Divide(const TH1 *h1) Warning("Divide","Attempt to divide histograms with different axis limits"); } catch(DifferentBinLimits&) { Warning("Divide","Attempt to divide histograms with different bin limits"); + } catch(DifferentLabels&) { + Warning("Divide","Attempt to divide histograms with different labels"); } + if (fDimension < 2) nbinsy = -1; if (fDimension < 3) nbinsz = -1; @@ -2681,8 +2711,11 @@ Bool_t TH1::Divide(const TH1 *h1, const TH1 *h2, Double_t c1, Double_t c2, Optio Warning("Divide","Attempt to divide histograms with different axis limits"); } catch(DifferentBinLimits&) { Warning("Divide","Attempt to divide histograms with different bin limits"); + } catch(DifferentLabels&) { + Warning("Divide","Attempt to divide histograms with different labels"); } + if (!c2) { Error("Divide","Coefficient of dividing histogram cannot be zero"); return kFALSE; @@ -2751,47 +2784,55 @@ Bool_t TH1::Divide(const TH1 *h1, const TH1 *h2, Double_t c1, Double_t c2, Optio //______________________________________________________________________________ void TH1::Draw(Option_t *option) { -// -*-*-*-*-*-*-*-*-*Draw this histogram with options*-*-*-*-*-*-*-*-*-*-*-* -// ================================ -// -// Histograms are drawn via the THistPainter class. Each histogram has -// a pointer to its own painter (to be usable in a multithreaded program). -// The same histogram can be drawn with different options in different pads. -// When an histogram drawn in a pad is deleted, the histogram is -// automatically removed from the pad or pads where it was drawn. -// If an histogram is drawn in a pad, then filled again, the new status -// of the histogram will be automatically shown in the pad next time -// the pad is updated. One does not need to redraw the histogram. -// To draw the current version of an histogram in a pad, one can use -// h->DrawCopy(); -// This makes a clone of the histogram. Once the clone is drawn, the original -// histogram may be modified or deleted without affecting the aspect of the -// clone. -// By default, TH1::Draw clears the current pad. -// -// One can use TH1::SetMaximum and TH1::SetMinimum to force a particular -// value for the maximum or the minimum scale on the plot. -// -// TH1::UseCurrentStyle can be used to change all histogram graphics -// attributes to correspond to the current selected style. -// This function must be called for each histogram. -// In case one reads and draws many histograms from a file, one can force -// the histograms to inherit automatically the current graphics style -// by calling before gROOT->ForceStyle(); -// -// See THistPainter::Paint for a description of all the drawing options -// ======================= -// -// -*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-* + // Draw this histogram with options. + // + // Histograms are drawn via the THistPainter class. Each histogram has + // a pointer to its own painter (to be usable in a multithreaded program). + // The same histogram can be drawn with different options in different pads. + // When an histogram drawn in a pad is deleted, the histogram is + // automatically removed from the pad or pads where it was drawn. + // If an histogram is drawn in a pad, then filled again, the new status + // of the histogram will be automatically shown in the pad next time + // the pad is updated. One does not need to redraw the histogram. + // To draw the current version of an histogram in a pad, one can use + // h->DrawCopy(); + // This makes a clone of the histogram. Once the clone is drawn, the original + // histogram may be modified or deleted without affecting the aspect of the + // clone. + // By default, TH1::Draw clears the current pad. + // + // One can use TH1::SetMaximum and TH1::SetMinimum to force a particular + // value for the maximum or the minimum scale on the plot. + // + // TH1::UseCurrentStyle can be used to change all histogram graphics + // attributes to correspond to the current selected style. + // This function must be called for each histogram. + // In case one reads and draws many histograms from a file, one can force + // the histograms to inherit automatically the current graphics style + // by calling before gROOT->ForceStyle(); + // + // See the THistPainter class for a description of all the drawing options. + + TString opt1 = option; opt1.ToLower(); + TString opt2 = option; + Int_t index = opt1.Index("same"); + + // Check if the string "same" is part of a TCutg name. + if (index>=0) { + Int_t indb = opt1.Index("["); + if (indb>=0) { + Int_t indk = opt1.Index("]"); + if (index>indb && index<indk) index = -1; + } + } - TString opt = option; - opt.ToLower(); + // If there is no pad or an empty pad the the "same" is ignored. if (gPad) { if (!gPad->IsEditable()) gROOT->MakeDefCanvas(); - if (opt.Contains("same")) { + if (index>=0) { if (gPad->GetX1() == 0 && gPad->GetX2() == 1 && gPad->GetY1() == 0 && gPad->GetY2() == 1 && - gPad->GetListOfPrimitives()->GetSize()==0) opt.ReplaceAll("same",""); + gPad->GetListOfPrimitives()->GetSize()==0) opt2.Remove(index,4); } else { //the following statement is necessary in case one attempts to draw //a temporary histogram already in the current pad @@ -2799,9 +2840,10 @@ void TH1::Draw(Option_t *option) gPad->Clear(); } } else { - if (opt.Contains("same")) opt.ReplaceAll("same",""); + if (index>=0) opt2.Remove(index,4); } - AppendPad(option); + + AppendPad(opt2.Data()); } //______________________________________________________________________________ @@ -3270,49 +3312,54 @@ void TH1::FillRandom(TH1 *h, Int_t ntimes) Int_t first = fXaxis.GetFirst(); Int_t last = fXaxis.GetLast(); Int_t nbins = last-first+1; - if (CheckConsistency(this,h) && ntimes > 10*nbins) { - Double_t sumw = h->Integral(first,last); - if (sumw == 0) return; - Double_t sumgen = 0; - for (Int_t bin=first;bin<=last;bin++) { - Double_t mean = h->GetBinContent(bin)*ntimes/sumw; - Double_t cont = (Double_t)gRandom->Poisson(mean); - sumgen += cont; - AddBinContent(bin,cont); - if (fSumw2.fN) fSumw2.fArray[bin] += cont; - } - - // fix for the fluctations in the total number n - // since we use Poisson instead of multinomial - // add a correction to have ntimes as generated entries - Int_t i; - if (sumgen < ntimes) { - // add missing entries - for (i = Int_t(sumgen+0.5); i < ntimes; ++i) - { - Double_t x = h->GetRandom(); - Fill(x); + if (ntimes > 10*nbins) { + try { + CheckConsistency(this,h); + Double_t sumw = h->Integral(first,last); + if (sumw == 0) return; + Double_t sumgen = 0; + for (Int_t bin=first;bin<=last;bin++) { + Double_t mean = h->GetBinContent(bin)*ntimes/sumw; + Double_t cont = (Double_t)gRandom->Poisson(mean); + sumgen += cont; + AddBinContent(bin,cont); + if (fSumw2.fN) fSumw2.fArray[bin] += cont; } - } - else if (sumgen > ntimes) { - // remove extra entries - i = Int_t(sumgen+0.5); - while( i > ntimes) { - Double_t x = h->GetRandom(); - Int_t ibin = fXaxis.FindBin(x); - Double_t y = GetBinContent(ibin); - // skip in case bin is empty - if (y > 0) { - SetBinContent(ibin, y-1.); - i--; + + // fix for the fluctations in the total number n + // since we use Poisson instead of multinomial + // add a correction to have ntimes as generated entries + Int_t i; + if (sumgen < ntimes) { + // add missing entries + for (i = Int_t(sumgen+0.5); i < ntimes; ++i) + { + Double_t x = h->GetRandom(); + Fill(x); + } + } + else if (sumgen > ntimes) { + // remove extra entries + i = Int_t(sumgen+0.5); + while( i > ntimes) { + Double_t x = h->GetRandom(); + Int_t ibin = fXaxis.FindBin(x); + Double_t y = GetBinContent(ibin); + // skip in case bin is empty + if (y > 0) { + SetBinContent(ibin, y-1.); + i--; + } } } - } - ResetStats(); - return; + ResetStats(); + return; + } + catch(std::exception&) {} // do nothing } - + // case of different axis and not too large ntimes + if (h->ComputeIntegral() ==0) return; Int_t loop; Double_t x; @@ -3500,7 +3547,7 @@ TFitResultPtr TH1::Fit(TF1 *f1 ,Option_t *option ,Option_t *goption, Double_t xx // = "I" Use integral of function in bin, normalized by the bin volume, // instead of value at bin center // = "L" Use Loglikelihood method (default is chisquare method) -// = "WL" Use Loglikelihood method and bin contents are not integer, +// = "WL" Use Loglikelihood method and bin contents are not integer, // i.e. histogram is weighted (must have Sumw2() set) // = "U" Use a User specified fitting algorithm (via SetFCN) // = "Q" Quiet mode (minimum printing) @@ -3634,7 +3681,7 @@ TFitResultPtr TH1::Fit(TF1 *f1 ,Option_t *option ,Option_t *goption, Double_t xx // ===================== // The status of the fit can be obtained converting the TFitResultPtr to an integer // independently if the fit option "S" is used or not: -// TFitResultPtr r = h=>Fit(myFunc,opt); +// TFitResultPtr r = h->Fit(myFunc,opt); // Int_t fitStatus = r; // // The fitStatus is 0 if the fit is OK (i.e no error occurred). @@ -3717,7 +3764,7 @@ TFitResultPtr TH1::Fit(TF1 *f1 ,Option_t *option ,Option_t *goption, Double_t xx ROOT::Fit::DataRange range(xxmin,xxmax); ROOT::Math::MinimizerOptions minOption; - // need to empty the buffer before + // need to empty the buffer before // (t.b.d. do a ML unbinned fit with buffer data) if (fBuffer) BufferEmpty(); @@ -3858,9 +3905,9 @@ Double_t TH1::GetEntries() const { // return the current number of entries - if (fBuffer) { + if (fBuffer) { Int_t nentries = (Int_t) fBuffer[0]; - if (nentries > 0) return nentries; + if (nentries > 0) return nentries; } return fEntries; @@ -3870,9 +3917,14 @@ Double_t TH1::GetEntries() const Double_t TH1::GetEffectiveEntries() const { // number of effective entries of the histogram, - // i.e. the number of unweighted entries a histogram would need to - // have the same statistical power as this histogram with possibly - // weighted entries (i.e. <= TH1::GetEntries()) + // neff = (Sum of weights )^2 / (Sum of weight^2 ) + // In case of an unweighted histogram this number is equivalent to the + // number of entries of the histogram. + // For a weighted histogram, this number corresponds to the hypotetical number of unweighted entries + // a histogram would need to have the same statistical power as this weighted histogram. + // Note: The underflow/overflow are included if one has set the TH1::StatOverFlows flag + // and if the statistics has been computed at filling time. + // If a range is set in the histogram the number is computed from the given range. Stat_t s[kNstat]; this->GetStats(s);// s[1] sum of squares of weights, s[0] sum of weights @@ -4031,12 +4083,12 @@ Int_t TH1::FitOptionsMake(Option_t *choptin, Foption_t &fitOption) if (opt.Contains("W")) fitOption.W1 = 1; if (opt.Contains("WW")) fitOption.W1 = 2; //all bins have weight=1, even empty bins // likelihood fit options - if (opt.Contains("L")) { + if (opt.Contains("L")) { fitOption.Like = 1; //if (opt.Contains("LL")) fitOption.Like = 2; if (opt.Contains("W")){ fitOption.Like = 2; fitOption.W1=0;}// (weighted likelihood) - if (opt.Contains("MULTI")) { - if (fitOption.Like == 2) fitOption.Like = 6; // weighted multinomial + if (opt.Contains("MULTI")) { + if (fitOption.Like == 2) fitOption.Like = 6; // weighted multinomial else fitOption.Like = 4; // multinomial likelihood fit instead of Poisson opt.ReplaceAll("MULTI",""); } @@ -4443,7 +4495,7 @@ Double_t TH1::GetRandom() const Int_t nbinsx = GetNbinsX(); Double_t integral = 0; if (fIntegral) { - if (fIntegral[nbinsx+1] != fEntries) integral = ((TH1*)this)->ComputeIntegral(); + if (fIntegral[nbinsx+1] != fEntries) integral = ((TH1*)this)->ComputeIntegral(); else integral = fIntegral[nbinsx]; } else { integral = ((TH1*)this)->ComputeIntegral(); @@ -4657,31 +4709,32 @@ void TH1::LabelsDeflate(Option_t *ax) { // Reduce the number of bins for the axis passed in the option to the number of bins having a label. // The method will remove only the extra bins existing after the last "labeled" bin. - // Note that if there are "un-labeled" bins present between "labeled" bins they will not be removed + // Note that if there are "un-labeled" bins present between "labeled" bins they will not be removed Int_t iaxis = AxisChoice(ax); TAxis *axis = 0; if (iaxis == 1) axis = GetXaxis(); if (iaxis == 2) axis = GetYaxis(); if (iaxis == 3) axis = GetZaxis(); - if (!axis) { + if (!axis) { Error("LabelsDeflate","Invalid axis option %s",ax); return; } if (!axis->GetLabels()) return; - - // find bin with last labels - // bin number is object ID in list of labels + + // find bin with last labels + // bin number is object ID in list of labels // therefore max bin number is number of bins of the deflated histograms TIter next(axis->GetLabels()); TObject *obj; Int_t nbins = 0; while ((obj = next())) { Int_t ibin = obj->GetUniqueID(); - if (ibin > nbins) nbins = ibin; + if (ibin > nbins) nbins = ibin; } if (nbins < 1) nbins = 1; - TH1 *hold = (TH1*)IsA()->New();; + TH1 *hold = (TH1*)IsA()->New(); + R__ASSERT(hold); hold->SetDirectory(0); Copy(*hold); @@ -4700,16 +4753,16 @@ void TH1::LabelsDeflate(Option_t *ax) //now loop on all bins and refill // NOTE that if the bins without labels have content - // it will be put in the underflow/overflow. + // it will be put in the underflow/overflow. // For this reason we use AddBinContent method Double_t oldEntries = fEntries; Int_t bin,binx,biny,binz; - for (bin=0; bin < hold->fNcells; ++bin) { + for (bin=0; bin < hold->fNcells; ++bin) { hold->GetBinXYZ(bin,binx,biny,binz); Int_t ibin = GetBin(binx,biny,binz); Double_t cu = hold->GetBinContent(bin); AddBinContent(ibin,cu); - if (errors) { + if (errors) { fSumw2.fArray[ibin] += hold->fSumw2.fArray[bin]; } } @@ -4744,7 +4797,7 @@ void TH1::LabelsInflate(Option_t *ax) Double_t xmax = axis->GetXmax(); xmax = xmin + 2*(xmax-xmin); axis->SetRange(0,0); - // double the bins and recompute ncells + // double the bins and recompute ncells axis->Set(2*nbins,xmin,xmax); SetBinsLength(-1); Int_t errors = fSumw2.fN; @@ -4756,12 +4809,12 @@ void TH1::LabelsInflate(Option_t *ax) //now loop on all bins and refill Double_t oldEntries = fEntries; Int_t bin,ibin,binx,biny,binz; - for (ibin =0; ibin < fNcells; ibin++) { + for (ibin =0; ibin < fNcells; ibin++) { GetBinXYZ(ibin,binx,biny,binz); bin = hold->GetBin(binx,biny,binz); // NOTE that overflow in hold will be not considered if (binx > nbxold || biny > nbyold || binz > nbzold) bin = -1; - if (bin > 0) { + if (bin > 0) { Double_t cu = hold->GetBinContent(bin); AddBinContent(ibin,cu); if (errors) fSumw2.fArray[ibin] += hold->fSumw2.fArray[bin]; @@ -4896,7 +4949,7 @@ void TH1::LabelsOption(Option_t *option, Option_t *ax) } } } - else { + else { // using y axis for (i=1;i<=nx;i++) { for (j=1;j<=n;j++) { @@ -4906,7 +4959,7 @@ void TH1::LabelsOption(Option_t *option, Option_t *ax) } } } else { - //to be implemented for 3d + //to be implemented for 3d } } else { //---alphabetic sort @@ -4999,7 +5052,7 @@ void TH1::LabelsOption(Option_t *option, Option_t *ax) } } } - } + } else if (axis == GetYaxis()) { // labels on y axis for (i=0;i<nx;i++) { @@ -5151,14 +5204,14 @@ Long64_t TH1::Merge(TCollection *li) // list->Add(h3); // TH1F *h = (TH1F*)h1->Clone("h"); // h->Reset(); - // h.Merge(list); + // h->Merge(list); // h->Draw(); // } if (!li) return 0; if (li->IsEmpty()) return (Long64_t) GetEntries(); - // is this really needed ? + // is this really needed ? TList inlist; inlist.AddAll(li); @@ -5170,20 +5223,34 @@ Long64_t TH1::Merge(TCollection *li) Bool_t allHaveLimits = kTRUE; Bool_t allSameLimits = kTRUE; Bool_t foundLabelHist = kFALSE; + Bool_t firstNonEmptyHist = kTRUE; TIter next(&inlist); - // start looping with this histogram - TH1 * h = this; + // start looping with this histogram + TH1 * h = this; + do { // skip empty histograms if (h->fTsumw == 0 && h->GetEntries() == 0) continue; + Bool_t hasLimits = h->GetXaxis()->GetXmin() < h->GetXaxis()->GetXmax(); allHaveLimits = allHaveLimits && hasLimits; if (hasLimits) { h->BufferEmpty(); + + // this is done in case the first histograms are empty and + // the histogram have different limits + if (firstNonEmptyHist ) { + // set axis limits in the case the first histogram was empty + if (h != this && !SameLimitsAndNBins( fXaxis, *h->GetXaxis()) ) { + fXaxis.Set(h->GetXaxis()->GetNbins(), h->GetXaxis()->GetXmin(),h->GetXaxis()->GetXmax()); + } + firstNonEmptyHist = kFALSE; + } + // this is executed the first time an histogram with limits is found // to set some initial values on the new axis if (!initialLimitsFound) { @@ -5192,11 +5259,11 @@ Long64_t TH1::Merge(TCollection *li) h->GetXaxis()->GetXmax()); } else { - // check first if histograms have same bins - if (!SameLimitsAndNBins(newXAxis, *(h->GetXaxis())) ) { + // check first if histograms have same bins + if (!SameLimitsAndNBins(newXAxis, *(h->GetXaxis())) ) { allSameLimits = kFALSE; // recompute the limits in this case the optimal limits - // The condition to works is that the histogram have same bin with + // The condition to works is that the histogram have same bin with // and one common bin edge if (!RecomputeAxisLimits(newXAxis, *(h->GetXaxis()))) { Error("Merge", "Cannot merge histograms - limits are inconsistent:\n " @@ -5212,35 +5279,35 @@ Long64_t TH1::Merge(TCollection *li) if (allHaveLabels) { THashList* hlabels=h->GetXaxis()->GetLabels(); Bool_t haveOneLabel = (hlabels != 0); - // do here to print message only one time + // do here to print message only one time if (foundLabelHist && allHaveLabels && !haveOneLabel) { Warning("Merge","Not all histograms have labels. I will ignore labels," " falling back to bin numbering mode."); - } + } allHaveLabels &= (haveOneLabel); // for the error message if (haveOneLabel) foundLabelHist = kTRUE; - // I could add a check if histogram contains bins without a label + // I could add a check if histogram contains bins without a label // and with non-zero bin content // Do we want to support this ??? // only in case the kCanRebin bit is not set - if (allHaveLabels && !h->TestBit(TH1::kCanRebin) ) { + if (allHaveLabels && !h->TestBit(TH1::kCanRebin) ) { // count number of bins with non-null content - Int_t non_zero_bins = 0; - Int_t nbins = h->GetXaxis()->GetNbins(); - if (nbins > hlabels->GetEntries() ) { + Int_t non_zero_bins = 0; + Int_t nbins = h->GetXaxis()->GetNbins(); + if (nbins > hlabels->GetEntries() ) { for (Int_t i = 1; i <= nbins; i++) { - if (h->GetBinContent(i) != 0 || (fSumw2.fN && h->GetBinError(i) != 0) ) { + if (h->GetBinContent(i) != 0 || (fSumw2.fN && h->GetBinError(i) != 0) ) { non_zero_bins++; - } + } } - if (non_zero_bins > hlabels->GetEntries() ) { + if (non_zero_bins > hlabels->GetEntries() ) { Warning("Merge","Histogram %s contains non-empty bins without labels - falling back to bin numbering mode",h->GetName() ); allHaveLabels = kFALSE; - } + } } - } + } } } while ( ( h = dynamic_cast<TH1*> ( next() ) ) != NULL ); @@ -5257,7 +5324,7 @@ Long64_t TH1::Merge(TCollection *li) // but one needs first to clone this histogram to perform the merge // The clone is not needed when all histograms have the same limits TH1 * hclone = 0; - if (!allSameLimits) { + if (!allSameLimits) { // We don't want to add the clone to gDirectory, // so remove our kMustCleanup bit temporarily Bool_t mustCleanup = TestBit(kMustCleanup); @@ -5279,26 +5346,26 @@ Long64_t TH1::Merge(TCollection *li) // fill this histogram with all the data from buffers of histograms without limits while (TH1* hist = (TH1*)next()) { // support also case where some histogram have limits and some have the buffer - if ( (hist->GetXaxis()->GetXmin() >= hist->GetXaxis()->GetXmax() ) && hist->fBuffer ) { + if ( (hist->GetXaxis()->GetXmin() >= hist->GetXaxis()->GetXmax() ) && hist->fBuffer ) { // no limits Int_t nbentries = (Int_t)hist->fBuffer[0]; for (Int_t i = 0; i < nbentries; i++) Fill(hist->fBuffer[2*i + 2], hist->fBuffer[2*i + 1]); // Entries from buffers have to be filled one by one - // because FillN doesn't resize histograms. + // because FillN doesn't resize histograms. } } // all histograms have been processed - if (!initialLimitsFound ) { + if (!initialLimitsFound ) { // here the case where all histograms don't have limits - // In principle I should not have copied in hclone since + // In principle I should not have copied in hclone since // when initialLimitsFound = false then allSameLimits should be true - if (hclone) { + if (hclone) { inlist.Remove(hclone); - delete hclone; + delete hclone; } - return (Long64_t) GetEntries(); + return (Long64_t) GetEntries(); } next.Reset(); } @@ -5312,10 +5379,10 @@ Long64_t TH1::Merge(TCollection *li) Double_t nentries = GetEntries(); Bool_t canRebin=TestBit(kCanRebin); // reset, otherwise setting the under/overflow will rebin and make a mess - if (!allHaveLabels) ResetBit(kCanRebin); + if (!allHaveLabels) ResetBit(kCanRebin); while (TH1* hist=(TH1*)next()) { // process only if the histogram has limits; otherwise it was processed before - // in the case of an existing buffer (see if statement just before) + // in the case of an existing buffer (see if statement just before) if (allHaveLabels || (hist->GetXaxis()->GetXmin() < hist->GetXaxis()->GetXmax()) ) { // import statistics hist->GetStats(stats); @@ -5323,75 +5390,75 @@ Long64_t TH1::Merge(TCollection *li) totstats[i] += stats[i]; nentries += hist->GetEntries(); - + Int_t nx = hist->GetXaxis()->GetNbins(); - // loop on bins of the histogram and do the merge + // loop on bins of the histogram and do the merge for (Int_t binx = 0; binx <= nx + 1; binx++) { Double_t cu = hist->GetBinContent(binx); - Double_t error1 = 0; - Int_t ix = -1; + Double_t error1 = 0; + Int_t ix = -1; if (fSumw2.fN) error1= hist->GetBinError(binx); // do only for bins with non null bin content or non-null errors (if Sumw2) - if (TMath::Abs(cu) > 0 || (fSumw2.fN && error1 > 0 ) ) { - // case of overflow bins + if (TMath::Abs(cu) > 0 || (fSumw2.fN && error1 > 0 ) ) { + // case of overflow bins // they do not make sense also in the case of labels - if (!allHaveLabels) { - // case of bins without labels - if (!allSameLimits) { + if (!allHaveLabels) { + // case of bins without labels + if (!allSameLimits) { if ( binx==0 || binx== nx+1) { Error("Merge", "Cannot merge histograms - the histograms have" " different limits and undeflows/overflows are present." " The initial histogram is now broken!"); return -1; } - // NOTE: in the case of one of the histogram as labels - it is treated as - // an error and it has been flagged before + // NOTE: in the case of one of the histogram as labels - it is treated as + // an error and it has been flagged before // since calling FindBin(x) for histo with labels does not make sense - // and the result is unpredictable + // and the result is unpredictable ix = fXaxis.FindBin(hist->GetXaxis()->GetBinCenter(binx)); } else { // histogram have same limits - no need to call FindBin - ix = binx; + ix = binx; } } else { - // here only in the case of bins with labels + // here only in the case of bins with labels const char* label=hist->GetXaxis()->GetBinLabel(binx); // do we need to support case when there are bins with labels and bins without them ?? // NO -then return an error - if (label == 0 ) { + if (label == 0 ) { Fatal("Merge","Histogram %s with labels has NULL label pointer for bin %d", hist->GetName(),binx ); return -1; } - if (label[0] == 0 ) { // case label is "" , i.e. is not set + if (label[0] == 0 ) { // case label is "" , i.e. is not set // exclude underflow which could contain the non-existing labels // thsi we could merge in all underflow - if ( binx > 0 && binx <= nx) { + if ( binx > 0 && binx <= nx) { Error("Merge","Cannot merge ! Label histogram %s contains a bin %d which has not a label and has non-zero content ",hist->GetName(),binx ); return -1; } else // case of underflow/overflow - ix = binx; + ix = binx; } - else { - // if bin does not exists FindBin will add it automatically + else { + // if bin does not exists FindBin will add it automatically // by calling LabelsInflate() if the bit is set // otherwise it will return zero and bin will be merged in underflow/overflow // Do we want to keep this case ?? ix = fXaxis.FindBin(label); } - // ix cannot be -1 . Can be 0 in case label is not found and bit is not set + // ix cannot be -1 . Can be 0 in case label is not found and bit is not set if (ix <0) { Fatal("Merge","Error return from TAxis::FindBin for label %s",label); return -1; } } - if (ix >= 0) { + if (ix >= 0) { // MERGE here the bin contents - AddBinContent(ix,cu); - if (fSumw2.fN) fSumw2.fArray[ix] += error1*error1; + AddBinContent(ix,cu); + if (fSumw2.fN) fSumw2.fArray[ix] += error1*error1; } } } @@ -5402,7 +5469,7 @@ Long64_t TH1::Merge(TCollection *li) //copy merged stats PutStats(totstats); SetEntries(nentries); - if (hclone) { + if (hclone) { inlist.Remove(hclone); delete hclone; } @@ -5513,8 +5580,11 @@ Bool_t TH1::Multiply(const TH1 *h1) Warning("Multiply","Attempt to multiply histograms with different axis limits"); } catch(DifferentBinLimits&) { Warning("Multiply","Attempt to multiply histograms with different bin limits"); + } catch(DifferentLabels&) { + Warning("Multiply","Attempt to multiply histograms with different labels"); } + if (fDimension < 2) nbinsy = -1; if (fDimension < 3) nbinsz = -1; @@ -5597,6 +5667,8 @@ Bool_t TH1::Multiply(const TH1 *h1, const TH1 *h2, Double_t c1, Double_t c2, Opt Warning("Multiply","Attempt to multiply histograms with different axis limits"); } catch(DifferentBinLimits&) { Warning("Multiply","Attempt to multiply histograms with different bin limits"); + } catch(DifferentLabels&) { + Warning("Multiply","Attempt to multiply histograms with different labels"); } if (fDimension < 2) nbinsy = -1; @@ -5635,7 +5707,7 @@ Bool_t TH1::Multiply(const TH1 *h1, const TH1 *h2, Double_t c1, Double_t c2, Opt } } ResetStats(); - return kTRUE; + return kTRUE; } //______________________________________________________________________________ @@ -5662,15 +5734,15 @@ TH1 *TH1::Rebin(Int_t ngroup, const char*newname, const Double_t *xbins) // // -case 1 xbins=0 // If newname is blank (default), the current histogram is modified and - // a pointer to it is returned. + // a pointer to it is returned. // // If newname is not blank, the current histogram is not modified, and a // new histogram is returned which is a Clone of the current histogram // with its name set to newname. - // + // // The parameter ngroup indicates how many bins of this have to be merged // into one bin of the result. - // + // // If the original histogram has errors stored (via Sumw2), the resulting // histograms has new errors correctly calculated. // @@ -5695,10 +5767,10 @@ TH1 *TH1::Rebin(Int_t ngroup, const char*newname, const Double_t *xbins) // histograms has new errors correctly calculated. // // NOTE: The bin edges specified in xbins should correspond to bin edges - // in the original histogram. If a bin edge in the new histogram is - // in the middle of a bin in the original histogram, all entries in + // in the original histogram. If a bin edge in the new histogram is + // in the middle of a bin in the original histogram, all entries in // the split bin in the original histogram will be transfered to the - // lower of the two possible bins in the new histogram. This is + // lower of the two possible bins in the new histogram. This is // probably not what you want. // // examples: if h1 is an existing TH1F histogram with 100 bins @@ -5730,7 +5802,7 @@ TH1 *TH1::Rebin(Int_t ngroup, const char*newname, const Double_t *xbins) } } else { - // in the case that xbins is given (rebinning in variable bins), ngroup is + // in the case that xbins is given (rebinning in variable bins), ngroup is // the new number of bins and number of grouped bins is not constant. // when looping for setting the contents for the new histogram we // need to loop on all bins of original histogram. Then set ngroup=nbins @@ -6111,6 +6183,11 @@ void TH1::SmoothArray(Int_t nn, Double_t *xx, Int_t ntimes) // based on algorithm 353QH twice presented by J. Friedman // in Proc.of the 1974 CERN School of Computing, Norway, 11-24 August, 1974. + if (nn < 3 ) { + if (gROOT) gROOT->Error("SmoothArray","Need at least 3 points for smoothing: n = %d",nn); + return; + } + Int_t ii, jj, ik, jk, kk, nn2; Double_t hh[6] = {0,0,0,0,0,0}; Double_t *yy = new Double_t[nn]; @@ -6281,10 +6358,15 @@ void TH1::Smooth(Int_t ntimes, Option_t *option) Error("Smooth","Smooth only supported for 1-d histograms"); return; } + Int_t nbins = fXaxis.GetNbins(); + if (nbins < 3) { + Error("Smooth","Smooth only supported for histograms with >= 3 bins. Nbins = %d",nbins); + return; + } + // delete buffer if it is there since it will become invalid if (fBuffer) BufferEmpty(1); - Int_t nbins = fXaxis.GetNbins(); Int_t firstbin = 1, lastbin = nbins; TString opt = option; opt.ToLower(); @@ -6494,11 +6576,11 @@ void TH1::Reset(Option_t *option) // =========================================== // // if option "ICE" is specified, resets only Integral, Contents and Errors. - // if option "ICES" is specified, resets only Integral, Contents , Errors and Statistics - // This option is used + // if option "ICES" is specified, resets only Integral, Contents , Errors and Statistics + // This option is used // if option "M" is specified, resets also Minimum and Maximum - // The option "ICE" is used when rebinning the histogram (in RebinAxis, LabelInflate, etc..) + // The option "ICE" is used when rebinning the histogram (in RebinAxis, LabelInflate, etc..) // The option "ICES is used in combination with the buffer (see BufferEmpty and BufferFill) TString opt = option; @@ -6513,11 +6595,11 @@ void TH1::Reset(Option_t *option) if (opt.Contains("ICE") && !opt.Contains("S")) return; - // Setting fBuffer[0] = 0 is like resetting the buffer but not deleting it - // But what is the sense of calling BufferEmpty() ? For making the axes ? - // BufferEmpty will update contents that later will be + // Setting fBuffer[0] = 0 is like resetting the buffer but not deleting it + // But what is the sense of calling BufferEmpty() ? For making the axes ? + // BufferEmpty will update contents that later will be // reset in calling TH1D::Reset. For this we need to reset the stats afterwards - // It may be needed for computing the axis limits.... + // It may be needed for computing the axis limits.... if (fBuffer) {BufferEmpty(); fBuffer[0] = 0;} // need to reset also the statistics @@ -6621,7 +6703,7 @@ void TH1::SavePrimitive(ostream &out, Option_t *option /*= ""*/) opt.ToLower(); static Int_t hcounter = 0; TString histName = GetName(); - if (!fDirectory && !histName.Contains("Graph") + if (!fDirectory && !histName.Contains("Graph") && !histName.Contains("_stack_") && !opt.Contains("colz")) { hcounter++; @@ -6630,9 +6712,10 @@ void TH1::SavePrimitive(ostream &out, Option_t *option /*= ""*/) } const char *hname = histName.Data(); - + TString t(GetTitle()); + t.ReplaceAll("\\","\\\\"); out << hname << " = new " << ClassName() << "(" << quote - << hname << quote << "," << quote<< GetTitle() << quote + << hname << quote << "," << quote<< t.Data() << quote << "," << GetXaxis()->GetNbins(); if (nonEqiX) out << ", "<<sxaxis; @@ -7089,12 +7172,12 @@ void TH1::GetStats(Double_t *stats) const Int_t bin, binx; Double_t w,err; Double_t x; - // case of labels with rebin of axis set - // statistics in x does not make any sense - set to zero - if ((const_cast<TAxis&>(fXaxis)).GetLabels() && TestBit(TH1::kCanRebin) ) { + // case of labels with rebin of axis set + // statistics in x does not make any sense - set to zero + if ((const_cast<TAxis&>(fXaxis)).GetLabels() && TestBit(TH1::kCanRebin) ) { stats[0] = fTsumw; stats[1] = fTsumw2; - stats[2] = 0; + stats[2] = 0; stats[3] = 0; } else if ((fTsumw == 0 && fEntries > 0) || fXaxis.TestBit(TAxis::kAxisRange)) { @@ -7118,9 +7201,9 @@ void TH1::GetStats(Double_t *stats) const stats[2] += w*x; stats[3] += w*x*x; } - // if (stats[0] < 0) { + // if (stats[0] < 0) { // // in case total is negative do something ?? - // stats[0] = 0; + // stats[0] = 0; // } } else { stats[0] = fTsumw; @@ -7574,7 +7657,7 @@ void TH1::SetBuffer(Int_t buffersize, Option_t * /*option*/) if (buffersize < 100) buffersize = 100; fBufferSize = 1 + buffersize*(fDimension+1); fBuffer = new Double_t[fBufferSize]; - memset(fBuffer,0,8*fBufferSize); + memset(fBuffer,0,sizeof(Double_t)*fBufferSize); } //______________________________________________________________________________ @@ -7709,7 +7792,7 @@ Int_t TH1::GetMaximumBin(Int_t &locmax, Int_t &locmay, Int_t &locmaz) const //______________________________________________________________________________ Double_t TH1::GetMinimum(Double_t minval) const { - // Return minimum value smaller than maxval of bins in the range, + // Return minimum value larger than minval of bins in the range, // unless the value has been overridden by TH1::SetMinimum, // in which case it returns that value. (This happens, for example, // when the histogram is drawn and the y or z axis limits are changed @@ -8063,7 +8146,7 @@ void TH1::SetStats(Bool_t stats) } //______________________________________________________________________________ -void TH1::Sumw2() +void TH1::Sumw2(Bool_t flag) { // Create structure to store sum of squares of weights*-*-*-*-*-*-*-* // @@ -8075,12 +8158,19 @@ void TH1::Sumw2() // // This function is automatically called when the histogram is created // if the static function TH1::SetDefaultSumw2 has been called before. + // If flag = false the structure is deleted + + if (!flag) { + // clear the array if existing - do nothing otherwise + if (fSumw2.fN > 0 ) fSumw2.Set(0); + return; + } - if (fSumw2.fN == fNcells) { - if (!fgDefaultSumw2 ) - Warning("Sumw2","Sum of squares of weights structure already created"); - return; - } + if (fSumw2.fN == fNcells) { + if (!fgDefaultSumw2 ) + Warning("Sumw2","Sum of squares of weights structure already created"); + return; + } fSumw2.Set(fNcells); @@ -8130,8 +8220,8 @@ Double_t TH1::GetBinErrorLow(Int_t bin) const { // -*-*-*-*-*Return lower error associated to bin number bin*-*-*-*-* // ================================================== - // - // The error will depend on the statistic option used will return + // + // The error will depend on the statistic option used will return // the binContent - lower interval value // // @@ -8143,18 +8233,18 @@ Double_t TH1::GetBinErrorLow(Int_t bin) const if (fBuffer) ((TH1*)this)->BufferEmpty(); Double_t alpha = 1.- 0.682689492; - if (fBinStatErrOpt == kPoisson2) alpha = 0.05; + if (fBinStatErrOpt == kPoisson2) alpha = 0.05; Double_t c = GetBinContent(bin); - Int_t n = int(c); - if (n < 0) { + Int_t n = int(c); + if (n < 0) { Warning("GetBinErrorLow","Histogram has negative bin content-force usage to normal errors"); ((TH1*)this)->fBinStatErrOpt = kNormal; return GetBinError(bin); } - if (n == 0) return 0; - return c - ROOT::Math::gamma_quantile( alpha/2, n, 1.); + if (n == 0) return 0; + return c - ROOT::Math::gamma_quantile( alpha/2, n, 1.); } //______________________________________________________________________________ @@ -8162,8 +8252,8 @@ Double_t TH1::GetBinErrorUp(Int_t bin) const { // -*-*-*-*-*Return lower error associated to bin number bin*-*-*-*-* // ================================================== - // - // The error will depend on the statistic option used will return + // + // The error will depend on the statistic option used will return // the binContent - lower interval value // // @@ -8175,11 +8265,11 @@ Double_t TH1::GetBinErrorUp(Int_t bin) const if (fBuffer) ((TH1*)this)->BufferEmpty(); Double_t alpha = 1.- 0.682689492; - if (fBinStatErrOpt == kPoisson2) alpha = 0.05; + if (fBinStatErrOpt == kPoisson2) alpha = 0.05; Double_t c = GetBinContent(bin); - Int_t n = int(c); - if (n < 0) { + Int_t n = int(c); + if (n < 0) { Warning("GetBinErrorLow","Histogram has negative bin content-force usage to normal errors"); ((TH1*)this)->fBinStatErrOpt = kNormal; return GetBinError(bin); @@ -8188,7 +8278,7 @@ Double_t TH1::GetBinErrorUp(Int_t bin) const // for N==0 return an upper limit at 0.68 or (1-alpha)/2 ? // decide to return always (1-alpha)/2 upper interval //if (n == 0) return ROOT::Math::gamma_quantile_c(alpha,n+1,1); - return ROOT::Math::gamma_quantile_c( alpha/2, n+1, 1) - c; + return ROOT::Math::gamma_quantile_c( alpha/2, n+1, 1) - c; } //______________________________________________________________________________ @@ -8386,8 +8476,13 @@ TH1* TH1::TransformHisto(TVirtualFFT *fft, TH1* h_output, Option_t *option) // "MAG" - magnitude of the output // "PH" - phase of the output + if (!fft || !fft->GetN() ) { + ::Error("TransformHisto","Invalid FFT transform class"); + return 0; + } + if (fft->GetNdim()>2){ - printf("Only 1d and 2d\n"); + ::Error("TransformHisto","Only 1d and 2D transform are supported"); return 0; } Int_t binx,biny; @@ -8395,7 +8490,7 @@ TH1* TH1::TransformHisto(TVirtualFFT *fft, TH1* h_output, Option_t *option) opt.ToUpper(); Int_t *n = fft->GetN(); TH1 *hout=0; - if (h_output) { + if (h_output) { hout = h_output; } else { @@ -8438,7 +8533,7 @@ TH1* TH1::TransformHisto(TVirtualFFT *fft, TH1* h_output, Option_t *option) } } } else { - printf("No complex numbers in the output"); + ::Error("TransformHisto","No complex numbers in the output"); return 0; } } diff --git a/hist/hist/src/TH2.cxx b/hist/hist/src/TH2.cxx index 74d571422997e..da6cf7a4bca79 100644 --- a/hist/hist/src/TH2.cxx +++ b/hist/hist/src/TH2.cxx @@ -253,6 +253,13 @@ void TH2::Copy(TObject &obj) const ((TH2&)obj).fTsumwxy = fTsumwxy; } +//______________________________________________________________________________ +Int_t TH2::Fill(Double_t ) +{ + // Invalid Fill method + Error("Fill", "Invalid signature - do nothing"); + return -1; +} //______________________________________________________________________________ Int_t TH2::Fill(Double_t x,Double_t y) { @@ -525,10 +532,12 @@ void TH2::FillRandom(const char *fname, Int_t ntimes) //*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-**-*-*-*-*-*-*-* Int_t bin, binx, biny, ibin, loop; - Double_t r1, x, y, xv[2]; + Double_t r1, x, y; //*-*- Search for fname in the list of ROOT defined functions - TF1 *f1 = (TF1*)gROOT->GetFunction(fname); - if (!f1) { Error("FillRandom", "Unknown function: %s",fname); return; } + TObject *fobj = gROOT->GetFunction(fname); + if (!fobj) { Error("FillRandom", "Unknown function: %s",fname); return; } + TF2 * f1 = dynamic_cast<TF2*>(fobj); + if (!f1) { Error("FillRandom", "Function: %s is not a TF2",fname); return; } //*-*- Allocate temporary space to store the integral and compute integral Int_t nbinsx = GetNbinsX(); @@ -539,11 +548,10 @@ void TH2::FillRandom(const char *fname, Int_t ntimes) ibin = 0; integral[ibin] = 0; for (biny=1;biny<=nbinsy;biny++) { - xv[1] = fYaxis.GetBinCenter(biny); for (binx=1;binx<=nbinsx;binx++) { - xv[0] = fXaxis.GetBinCenter(binx); ibin++; - integral[ibin] = integral[ibin-1] + f1->Eval(xv[0],xv[1]); + Double_t fint = f1->Integral(fXaxis.GetBinLowEdge(binx), fXaxis.GetBinUpEdge(binx), fYaxis.GetBinLowEdge(biny), fYaxis.GetBinUpEdge(biny)); + integral[ibin] = integral[ibin-1] + fint; } } @@ -1446,6 +1454,7 @@ Long64_t TH2::Merge(TCollection *list) Bool_t initialLimitsFound = kFALSE; Bool_t allSameLimits = kTRUE; Bool_t allHaveLimits = kTRUE; + Bool_t firstNonEmptyHist = kTRUE; TIter next(&inlist); TH2 * h = this; @@ -1458,6 +1467,20 @@ Long64_t TH2::Merge(TCollection *list) if (hasLimits) { h->BufferEmpty(); + + // this is done in case the first histograms are empty and + // the histogram have different limits + if (firstNonEmptyHist ) { + // set axis limits in the case the first histogram was empty + if (h != this ) { + if (!SameLimitsAndNBins(fXaxis, *(h->GetXaxis())) ) + fXaxis.Set(h->GetXaxis()->GetNbins(), h->GetXaxis()->GetXmin(),h->GetXaxis()->GetXmax()); + if (!SameLimitsAndNBins(fYaxis, *(h->GetYaxis())) ) + fYaxis.Set(h->GetYaxis()->GetNbins(), h->GetYaxis()->GetXmin(),h->GetYaxis()->GetXmax()); + } + firstNonEmptyHist = kFALSE; + } + if (!initialLimitsFound) { // this is executed the first time an histogram with limits is found // to set some initial values on the new axes @@ -1978,20 +2001,22 @@ TProfile *TH2::DoProfile(bool onX, const char *name, Int_t firstbin, Int_t lastb return 0; } h1 = (TProfile*)h1obj; - // check profile compatibility - bool useAllBins = ((lastOutBin - firstOutBin +1 ) == outAxis.GetNbins() ); - if (useAllBins && CheckEqualAxes(&outAxis, h1->GetXaxis() ) ) { - // enable originalRange option in case a range is set in the outer axis - originalRange = kTRUE; - h1->Reset(); - } - else if (!useAllBins && CheckConsistentSubAxes(&outAxis, firstOutBin, lastOutBin, h1->GetXaxis() ) ) { - // reset also in case a profile exists with compatible axis with the zoomed original axis - h1->Reset(); - } - else { - Error("DoProfile","Profile with name %s already exists and it is not compatible",pname); - return 0; + // reset the existing histogram and set always the new binning for the axis + // This avoid problems when the histogram already exists and the histograms is rebinned or its range has changed + // (see https://savannah.cern.ch/bugs/?94101 or https://savannah.cern.ch/bugs/?95808 ) + h1->Reset(); + const TArrayD *xbins = outAxis.GetXbins(); + if (xbins->fN == 0) { + if ( originalRange ) + h1->SetBins(outAxis.GetNbins(),outAxis.GetXmin(),outAxis.GetXmax()); + else + h1->SetBins(lastOutBin-firstOutBin+1,outAxis.GetBinLowEdge(firstOutBin),outAxis.GetBinUpEdge(lastOutBin)); + } else { + // case variable bins + if (originalRange ) + h1->SetBins(outAxis.GetNbins(),xbins->fArray); + else + h1->SetBins(lastOutBin-firstOutBin+1,&xbins->fArray[firstOutBin-1]); } } @@ -2087,7 +2112,7 @@ TProfile *TH2::DoProfile(bool onX, const char *name, Int_t firstbin, Int_t lastb TVirtualPad *pad = gROOT->GetSelectedPad(); if (pad) pad->cd(); opt.Remove(opt.First("d"),1); - if (!gPad->FindObject(h1)) { + if (!gPad || !gPad->FindObject(h1)) { h1->Draw(opt); } else { h1->Paint(opt); @@ -2127,7 +2152,7 @@ TProfile *TH2::ProfileX(const char *name, Int_t firstybin, Int_t lastybin, Optio // To invert the cut, it is enough to put a "-" in front of its name: // myhist->ProfileX(" ",firstybin,lastybin,"[-cutg]"); // It is possible to apply several cuts ("," means logical AND): - // myhist->ProfileX(" ",firstybin,lastybin,[cutg1,cutg2]"); + // myhist->ProfileX(" ",firstybin,lastybin,"[cutg1,cutg2]"); // // NOTE that if a TProfile named "name" exists in the current directory or pad with // a compatible axis the profile is reset and filled again with the projected contents of the TH2. @@ -2172,7 +2197,7 @@ TProfile *TH2::ProfileY(const char *name, Int_t firstxbin, Int_t lastxbin, Optio // To invert the cut, it is enough to put a "-" in front of its name: // myhist->ProfileY(" ",firstybin,lastybin,"[-cutg]"); // It is possible to apply several cuts: - // myhist->ProfileY(" ",firstybin,lastybin,[cutg1,cutg2]"); + // myhist->ProfileY(" ",firstybin,lastybin,"[cutg1,cutg2]"); // // NOTE that if a TProfile named "name" exists in the current directory or pad with // a compatible axis the profile is reset and filled again with the projected contents of the TH2. @@ -2260,20 +2285,22 @@ TH1D *TH2::DoProjection(bool onX, const char *name, Int_t firstbin, Int_t lastbi return 0; } h1 = (TH1D*)h1obj; - // check axis compatibility - distinguish case when using all bins or a part of the axis - bool useAllBins = ((lastOutBin - firstOutBin +1 ) == outAxis->GetNbins() ); - if (useAllBins && CheckEqualAxes(outAxis, h1->GetXaxis()) ) { - // enable originalRange option in case a range is set in the outer axis - originalRange = kTRUE; - h1->Reset(); - } - else if (!useAllBins && CheckConsistentSubAxes(outAxis, firstOutBin, lastOutBin, h1->GetXaxis() ) ) { - // reset also in case an histogram exists with compatible axis with the zoomed original axis - h1->Reset(); - } - else { - Error("DoProjection","Histogram with name %s already exists and it is not compatible",pname); - return 0; + // reset the existing histogram and set always the new binning for the axis + // This avoid problems when the histogram already exists and the histograms is rebinned or its range has changed + // (see https://savannah.cern.ch/bugs/?94101 or https://savannah.cern.ch/bugs/?95808 ) + h1->Reset(); + const TArrayD *xbins = outAxis->GetXbins(); + if (xbins->fN == 0) { + if ( originalRange ) + h1->SetBins(outAxis->GetNbins(),outAxis->GetXmin(),outAxis->GetXmax()); + else + h1->SetBins(lastOutBin-firstOutBin+1,outAxis->GetBinLowEdge(firstOutBin),outAxis->GetBinUpEdge(lastOutBin)); + } else { + // case variable bins + if (originalRange ) + h1->SetBins(outAxis->GetNbins(),xbins->fArray); + else + h1->SetBins(lastOutBin-firstOutBin+1,&xbins->fArray[firstOutBin-1]); } } @@ -2449,11 +2476,10 @@ TH1D *TH2::ProjectionX(const char *name, Int_t firstybin, Int_t lastybin, Option // To invert the cut, it is enough to put a "-" in front of its name: // myhist->ProjectionX(" ",firstybin,lastybin,"[-cutg]"); // It is possible to apply several cuts: - // myhist->ProjectionX(" ",firstybin,lastybin,[cutg1,cutg2]"); + // myhist->ProjectionX(" ",firstybin,lastybin,"[cutg1,cutg2]"); // - // NOTE that if a TH1D named "name" exists in the current directory or pad and having - // a compatible axis, the histogram is reset and filled again with the projected contents of the TH2. - // In the case of axis incompatibility, an error is reported and a NULL pointer is returned. + // NOTE that if a TH1D named "name" exists in the current directory or pad + // the histogram is reset and filled again with the projected contents of the TH2. // // NOTE that the X axis attributes of the TH2 are copied to the X axis of the projection. // @@ -2490,7 +2516,7 @@ TH1D *TH2::ProjectionY(const char *name, Int_t firstxbin, Int_t lastxbin, Option // To invert the cut, it is enough to put a "-" in front of its name: // myhist->ProjectionY(" ",firstxbin,lastxbin,"[-cutg]"); // It is possible to apply several cuts: - // myhist->ProjectionY(" ",firstxbin,lastxbin,[cutg1,cutg2]"); + // myhist->ProjectionY(" ",firstxbin,lastxbin,"[cutg1,cutg2]"); // // NOTE that if a TH1D named "name" exists in the current directory or pad and having // a compatible axis, the histogram is reset and filled again with the projected contents of the TH2. diff --git a/hist/hist/src/TH2Poly.cxx b/hist/hist/src/TH2Poly.cxx index b2fa854a8972b..aa3d1359edc6a 100644 --- a/hist/hist/src/TH2Poly.cxx +++ b/hist/hist/src/TH2Poly.cxx @@ -34,7 +34,7 @@ ClassImp(TH2Poly) <h3>Overview</h3> <tt>TH2Poly</tt> is a 2D Histogram class (TH2) allowing to define polygonal -bins of arbitary shape. +bins of arbitrary shape. <p> Each bin in the <tt>TH2Poly</tt> histogram is a <tt>TH2PolyBin</tt> object. <tt>TH2PolyBin</tt> is a very simple class containing the vertices (stored @@ -80,28 +80,27 @@ contains the input coordinates), especially if the histogram is to be filled many times. <p> The following very simple macro shows how to build and fill a <tt>TH2Poly</tt>: -<pre> { - TH2Poly *h2p = new TH2Poly(); - - Double_t x1[] = {0, 5, 5}; - Double_t y1[] = {0, 0, 5}; - Double_t x2[] = {0, -1, -1, 0}; - Double_t y2[] = {0, 0, -1, -1}; - Double_t x3[] = {4, 3, 0, 1, 2.4}; - Double_t y3[] = {4, 3.7, 1, 4.7, 3.5}; - - h2p->AddBin(3, x1, y1); - h2p->AddBin(3, x2, y2); - h2p->AddBin(3, x3, y3); - - h2p->Fill( 3, 1, 3); // fill bin 1 - h2p->Fill(-0.5, -0.5, 7); // fill bin 2 - h2p->Fill(-0.7, -0.5, 1); // fill bin 2 - h2p->Fill( 1, 3, 5); // fill bin 3 + TH2Poly *h2p = new TH2Poly(); + + Double_t x1[] = {0, 5, 6}; + Double_t y1[] = {0, 0, 5}; + Double_t x2[] = {0, -1, -1, 0}; + Double_t y2[] = {0, 0, -1, 3}; + Double_t x3[] = {4, 3, 0, 1, 2.4}; + Double_t y3[] = {4, 3.7, 1, 3.7, 2.5}; + + h2p->AddBin(3, x1, y1); + h2p->AddBin(4, x2, y2); + h2p->AddBin(5, x3, y3); + + h2p->Fill(0.1, 0.01, 3); + h2p->Fill(-0.5, -0.5, 7); + h2p->Fill(-0.7, -0.5, 1); + h2p->Fill(1, 3, 1.5); } </pre> - +<p> More examples can bin found in <tt>$ROOTSYS/tutorials/hist/th2poly*.C</tt> <h3>Partitioning Algorithm</h3> @@ -1133,6 +1132,14 @@ Bool_t TH2Poly::IsIntersectingPolygon(Int_t bn, Double_t *x, Double_t *y, } +//______________________________________________________________________________ +Long64_t TH2Poly::Merge(TCollection *) +{ + Error("Merge","Cannot merge TH2Poly"); + return 0; +} + + //______________________________________________________________________________ void TH2Poly::SavePrimitive(ostream &out, Option_t *option) { diff --git a/hist/hist/src/TH3.cxx b/hist/hist/src/TH3.cxx index 69c78f4b2109d..0c9f17a40267b 100644 --- a/hist/hist/src/TH3.cxx +++ b/hist/hist/src/TH3.cxx @@ -251,6 +251,13 @@ Int_t TH3::BufferFill(Double_t x, Double_t y, Double_t z, Double_t w) return -3; } +//______________________________________________________________________________ +Int_t TH3::Fill(Double_t ) +{ + // Invalid Fill method + Error("Fill", "Invalid signature - do nothing"); + return -1; +} //______________________________________________________________________________ Int_t TH3::Fill(Double_t x, Double_t y, Double_t z) { @@ -1480,6 +1487,7 @@ Long64_t TH3::Merge(TCollection *list) Bool_t initialLimitsFound = kFALSE; Bool_t allSameLimits = kTRUE; Bool_t allHaveLimits = kTRUE; + Bool_t firstNonEmptyHist = kTRUE; TIter next(&inlist); TH3* h = this; @@ -1492,6 +1500,22 @@ Long64_t TH3::Merge(TCollection *list) if (hasLimits) { h->BufferEmpty(); + + // this is done in case the first histograms are empty and + // the histogram have different limits + if (firstNonEmptyHist ) { + // set axis limits in the case the first histogram was empty + if (h != this ) { + if (!SameLimitsAndNBins(fXaxis, *(h->GetXaxis())) ) + fXaxis.Set(h->GetXaxis()->GetNbins(), h->GetXaxis()->GetXmin(),h->GetXaxis()->GetXmax()); + if (!SameLimitsAndNBins(fYaxis, *(h->GetYaxis())) ) + fYaxis.Set(h->GetYaxis()->GetNbins(), h->GetYaxis()->GetXmin(),h->GetYaxis()->GetXmax()); + if (!SameLimitsAndNBins(fZaxis, *(h->GetZaxis())) ) + fZaxis.Set(h->GetZaxis()->GetNbins(), h->GetZaxis()->GetXmin(),h->GetZaxis()->GetXmax()); + } + firstNonEmptyHist = kFALSE; + } + if (!initialLimitsFound) { // this is executed the first time an histogram with limits is found // to set some initial values on the new axes @@ -1692,9 +1716,8 @@ TH1D *TH3::ProjectionX(const char *name, Int_t iymin, Int_t iymax, Int_t izmin, // if option "o" original axis range of the target axes will be // kept, but only bins inside the selected range will be filled. // - // NOTE that if a TH1D named "name" exists in the current directory or pad and having - // a compatible axis, the histogram is reset and filled again with the projected contents of the TH3. - // In the case of axis incompatibility, an error is reported and a NULL pointer is returned. + // NOTE that if a TH1D named "name" exists in the current directory or pad + // the histogram is reset and filled again with the projected contents of the TH3. // // implemented using Project3D @@ -1702,23 +1725,14 @@ TH1D *TH3::ProjectionX(const char *name, Int_t iymin, Int_t iymax, Int_t izmin, TString opt = option; opt.ToLower(); - Int_t piymin = GetYaxis()->GetFirst(); - Int_t piymax = GetYaxis()->GetLast(); - Int_t pizmin = GetZaxis()->GetFirst(); - Int_t pizmax = GetZaxis()->GetLast(); + Int_t iyminOld = GetYaxis()->GetFirst(); + Int_t iymaxOld = GetYaxis()->GetLast(); + Int_t izminOld = GetZaxis()->GetFirst(); + Int_t izmaxOld = GetZaxis()->GetLast(); GetYaxis()->SetRange(iymin,iymax); GetZaxis()->SetRange(izmin,izmax); - // exclude underflow/overflow by forcing the axis range bit - // due to limitation of TAxis::SetRange cannot select only underflow or overflow cannot have underflow or overflow only - if (iymin == 1 && iymax == GetNbinsY() ) GetYaxis()->SetBit(TAxis::kAxisRange); - if (izmin == 1 && izmax == GetNbinsZ() ) GetZaxis()->SetBit(TAxis::kAxisRange); - // I can use the useUF or useOF flag for exclude/include the underflow/overflow separtly - // (-1 in the imax is considered as an overflow) - Bool_t useUF = (iymin == 0 || izmin == 0); - Bool_t useOF = ( (iymax < 0 ) || (iymax > GetNbinsY() ) || (izmax < 0) || (izmax > GetNbinsZ() ) ); - Bool_t computeErrors = GetSumw2N(); if (opt.Contains("e") ) { computeErrors = kTRUE; @@ -1730,11 +1744,11 @@ TH1D *TH3::ProjectionX(const char *name, Int_t iymin, Int_t iymax, Int_t izmin, opt.Remove(opt.First("o"),1); } - TH1D * h1 = DoProject1D(name, GetTitle(), this->GetXaxis(), computeErrors, originalRange, useUF, useOF); + TH1D * h1 = DoProject1D(name, GetTitle(), this->GetXaxis(), computeErrors, originalRange,true,true); // restore original range - GetYaxis()->SetRange(piymin,piymax); - GetZaxis()->SetRange(pizmin,pizmax); + if (GetYaxis()->TestBit(TAxis::kAxisRange)) GetYaxis()->SetRange(iyminOld,iymaxOld); + if (GetZaxis()->TestBit(TAxis::kAxisRange)) GetZaxis()->SetRange(izminOld,izmaxOld); // draw in current pad if (h1 && opt.Contains("d")) { @@ -1742,7 +1756,7 @@ TH1D *TH3::ProjectionX(const char *name, Int_t iymin, Int_t iymax, Int_t izmin, TVirtualPad *padsav = gPad; TVirtualPad *pad = gROOT->GetSelectedPad(); if (pad) pad->cd(); - if (!gPad->FindObject(h1)) { + if (!gPad || !gPad->FindObject(h1)) { h1->Draw(opt); } else { h1->Paint(opt); @@ -1770,9 +1784,8 @@ TH1D *TH3::ProjectionY(const char *name, Int_t ixmin, Int_t ixmax, Int_t izmin, // if option "o" original axis range of the target axes will be // kept, but only bins inside the selected range will be filled. // - // NOTE that if a TH1D named "name" exists in the current directory or pad and having - // a compatible axis, the histogram is reset and filled again with the projected contents of the TH3. - // In the case of axis incompatibility, an error is reported and a NULL pointer is returned. + // NOTE that if a TH1D named "name" exists in the current directory or pad, + // the histogram is reset and filled again with the projected contents of the TH3. // // implemented using Project3D @@ -1780,23 +1793,14 @@ TH1D *TH3::ProjectionY(const char *name, Int_t ixmin, Int_t ixmax, Int_t izmin, TString opt = option; opt.ToLower(); - Int_t pixmin = GetXaxis()->GetFirst(); - Int_t pixmax = GetXaxis()->GetLast(); - Int_t pizmin = GetZaxis()->GetFirst(); - Int_t pizmax = GetZaxis()->GetLast(); + Int_t ixminOld = GetXaxis()->GetFirst(); + Int_t ixmaxOld = GetXaxis()->GetLast(); + Int_t izminOld = GetZaxis()->GetFirst(); + Int_t izmaxOld = GetZaxis()->GetLast(); GetXaxis()->SetRange(ixmin,ixmax); GetZaxis()->SetRange(izmin,izmax); - // exclude underflow/overflow by forcing the axis range bit - // due to limitation of TAxis::SetRange cannot select only underflow or overflow cannot have underflow or overflow only - if (ixmin == 1 && ixmax == GetNbinsX() ) GetXaxis()->SetBit(TAxis::kAxisRange); - if (izmin == 1 && izmax == GetNbinsZ() ) GetZaxis()->SetBit(TAxis::kAxisRange); - // I can use the useUF or useOF flag for exclude/include the underflow/overflow separtly - // (-1 in the imax is considered as an overflow) - Bool_t useUF = (ixmin == 0 || izmin == 0); - Bool_t useOF = ( (ixmax < 0 ) || (ixmax > GetNbinsX() ) || (izmax < 0) || (izmax > GetNbinsZ() ) ); - Bool_t computeErrors = GetSumw2N(); if (opt.Contains("e") ) { computeErrors = kTRUE; @@ -1808,11 +1812,11 @@ TH1D *TH3::ProjectionY(const char *name, Int_t ixmin, Int_t ixmax, Int_t izmin, opt.Remove(opt.First("o"),1); } - TH1D * h1 = DoProject1D(name, GetTitle(), this->GetYaxis(), computeErrors, originalRange, useUF, useOF); + TH1D * h1 = DoProject1D(name, GetTitle(), this->GetYaxis(), computeErrors, originalRange, true, true); // restore axis range - GetXaxis()->SetRange(pixmin,pixmax); - GetZaxis()->SetRange(pizmin,pizmax); + if (GetXaxis()->TestBit(TAxis::kAxisRange)) GetXaxis()->SetRange(ixminOld,ixmaxOld); + if (GetZaxis()->TestBit(TAxis::kAxisRange)) GetZaxis()->SetRange(izminOld,izmaxOld); // draw in current pad if (h1 && opt.Contains("d")) { @@ -1820,7 +1824,7 @@ TH1D *TH3::ProjectionY(const char *name, Int_t ixmin, Int_t ixmax, Int_t izmin, TVirtualPad *padsav = gPad; TVirtualPad *pad = gROOT->GetSelectedPad(); if (pad) pad->cd(); - if (!gPad->FindObject(h1)) { + if (!gPad || !gPad->FindObject(h1)) { h1->Draw(opt); } else { h1->Paint(opt); @@ -1838,7 +1842,7 @@ TH1D *TH3::ProjectionZ(const char *name, Int_t ixmin, Int_t ixmax, Int_t iymin, //*-* ==================================================== // // The projection is always of the type TH1D. - // The projection is made from the cells along the X axis + // The projection is made from the cells along the Z axis // ranging from ixmin to ixmax and iymin to iymax included. // By default, bins 1 to nx and 1 to ny are included // By setting ixmin=1 and/or ixmax=NbinsX the underflow and/or overflow in X will be excluded @@ -1849,9 +1853,8 @@ TH1D *TH3::ProjectionZ(const char *name, Int_t ixmin, Int_t ixmax, Int_t iymin, // if option "o" original axis range of the target axes will be // kept, but only bins inside the selected range will be filled. // - // NOTE that if a TH1D named "name" exists in the current directory or pad and having - // a compatible axis, the histogram is reset and filled again with the projected contents of the TH3. - // In the case of axis incompatibility, an error is reported and a NULL pointer is returned. + // NOTE that if a TH1D named "name" exists in the current directory or pad, + // the histogram is reset and filled again with the projected contents of the TH3. // // implemented using Project3D @@ -1859,23 +1862,14 @@ TH1D *TH3::ProjectionZ(const char *name, Int_t ixmin, Int_t ixmax, Int_t iymin, TString opt = option; opt.ToLower(); - Int_t pixmin = GetXaxis()->GetFirst(); - Int_t pixmax = GetXaxis()->GetLast(); - Int_t piymin = GetYaxis()->GetFirst(); - Int_t piymax = GetYaxis()->GetLast(); + Int_t ixminOld = GetXaxis()->GetFirst(); + Int_t ixmaxOld = GetXaxis()->GetLast(); + Int_t iyminOld = GetYaxis()->GetFirst(); + Int_t iymaxOld = GetYaxis()->GetLast(); GetXaxis()->SetRange(ixmin,ixmax); GetYaxis()->SetRange(iymin,iymax); - // exclude underflow/overflow by forcing the axis range bit - // due to limitation of TAxis::SetRange cannot select only underflow or overflow cannot have underflow or overflow only - if (ixmin == 1 && ixmax == GetNbinsX() ) GetXaxis()->SetBit(TAxis::kAxisRange); - if (iymin == 1 && iymax == GetNbinsY() ) GetYaxis()->SetBit(TAxis::kAxisRange); - // I can use the useUF or useOF flag for exclude/include the underflow/overflow separtly - // (-1 in the imax is considered as an overflow) - Bool_t useUF = (ixmin == 0 || iymin == 0); - Bool_t useOF = ( (ixmax < 0 ) || (ixmax > GetNbinsX() ) || (iymax < 0) || (iymax > GetNbinsY() ) ); - Bool_t computeErrors = GetSumw2N(); if (opt.Contains("e") ) { computeErrors = kTRUE; @@ -1887,11 +1881,11 @@ TH1D *TH3::ProjectionZ(const char *name, Int_t ixmin, Int_t ixmax, Int_t iymin, opt.Remove(opt.First("o"),1); } - TH1D * h1 = DoProject1D(name, GetTitle(), this->GetZaxis(), computeErrors, originalRange, useUF, useOF); + TH1D * h1 = DoProject1D(name, GetTitle(), this->GetZaxis(), computeErrors, originalRange, true, true); // restore the range - GetXaxis()->SetRange(pixmin,pixmax); - GetYaxis()->SetRange(piymin,piymax); + if (GetXaxis()->TestBit(TAxis::kAxisRange)) GetXaxis()->SetRange(ixminOld,ixmaxOld); + if (GetYaxis()->TestBit(TAxis::kAxisRange)) GetYaxis()->SetRange(iyminOld,iymaxOld); // draw in current pad if (h1 && opt.Contains("d")) { @@ -1899,7 +1893,7 @@ TH1D *TH3::ProjectionZ(const char *name, Int_t ixmin, Int_t ixmax, Int_t iymin, TVirtualPad *padsav = gPad; TVirtualPad *pad = gROOT->GetSelectedPad(); if (pad) pad->cd(); - if (!gPad->FindObject(h1)) { + if (!gPad || !gPad->FindObject(h1)) { h1->Draw(opt); } else { h1->Paint(opt); @@ -1912,8 +1906,8 @@ TH1D *TH3::ProjectionZ(const char *name, Int_t ixmin, Int_t ixmax, Int_t iymin, //______________________________________________________________________________ TH1D *TH3::DoProject1D(const char* name, const char* title, TAxis* projX, - bool computeErrors, bool originalRange, - bool useUF, bool useOF) const + bool computeErrors, bool originalRange, + bool useUF, bool useOF) const { // internal methdod performing the projection to 1D histogram // called from TH3::Project3D @@ -1924,11 +1918,10 @@ TH1D *TH3::DoProject1D(const char* name, const char* title, TAxis* projX, // Get range to use as well as bin limits Int_t ixmin = projX->GetFirst(); Int_t ixmax = projX->GetLast(); - if (ixmin == 0 && ixmax == 0) { ixmin = 1; ixmax = projX->GetNbins(); } +// if (ixmin == 0 && ixmax == 0) { ixmin = 1; ixmax = projX->GetNbins(); } Int_t nx = ixmax-ixmin+1; // Create the histogram, either reseting a preexisting one - // in case they have a compatible axis TObject *h1obj = gROOT->FindObject(name); if (h1obj && h1obj->InheritsFrom(TH1::Class())) { if (h1obj->IsA() != TH1D::Class() ) { @@ -1936,21 +1929,22 @@ TH1D *TH3::DoProject1D(const char* name, const char* title, TAxis* projX, return 0; } h1 = (TH1D*)h1obj; - // check histogram compatibility - bool useAllBins = (nx == projX->GetNbins() ); - if (useAllBins && CheckEqualAxes( projX, h1->GetXaxis() ) ) { - // enable originalRange option in case a range is set in the outer axis - originalRange = kTRUE; - h1->Reset(); - } - else if ( !useAllBins && - CheckConsistentSubAxes(projX, ixmin, ixmax, h1->GetXaxis() ) ) { - // reset also in case an histogram exists with compatible axis with the zoomed original axis - h1->Reset(); - } - else { - Error("DoProject1D","Histogram with name %s already exists and it is not compatible",name); - return 0; + // reset histogram and re-set the axis in any case + h1->Reset(); + const TArrayD *bins = projX->GetXbins(); + if ( originalRange ) + { + if (bins->fN == 0) { + h1->SetBins(projX->GetNbins(),projX->GetXmin(),projX->GetXmax()); + } else { + h1->SetBins(projX->GetNbins(),bins->fArray); + } + } else { + if (bins->fN == 0) { + h1->SetBins(nx,projX->GetBinLowEdge(ixmin),projX->GetBinUpEdge(ixmax)); + } else { + h1->SetBins(nx,&bins->fArray[ixmin-1]); + } } } @@ -2020,13 +2014,13 @@ TH1D *TH3::DoProject1D(const char* name, const char* title, TAxis* projX, Int_t out1min = out1->GetFirst(); Int_t out1max = out1->GetLast(); // GetFirst(), GetLast() can return (0,0) when the range bit is set artifically (see TAxis::SetRange) - if (out1min == 0 && out1max == 0) { out1min = 1; out1max = out1->GetNbins(); } + //if (out1min == 0 && out1max == 0) { out1min = 1; out1max = out1->GetNbins(); } // correct for underflow/overflows if (useUF && !out1->TestBit(TAxis::kAxisRange) ) out1min -= 1; if (useOF && !out1->TestBit(TAxis::kAxisRange) ) out1max += 1; Int_t out2min = out2->GetFirst(); Int_t out2max = out2->GetLast(); - if (out2min == 0 && out2max == 0) { out2min = 1; out2max = out2->GetNbins(); } +// if (out2min == 0 && out2max == 0) { out2min = 1; out2max = out2->GetNbins(); } if (useUF && !out2->TestBit(TAxis::kAxisRange) ) out2min -= 1; if (useOF && !out2->TestBit(TAxis::kAxisRange) ) out2max += 1; @@ -2125,7 +2119,7 @@ TH2D *TH3::DoProject2D(const char* name, const char * title, TAxis* projX, TAxis Int_t ny = iymax-iymin+1; // Create the histogram, either reseting a preexisting one - // if compatible or creating one from scratch. + // or creating one from scratch. // Does an object with the same name exists? TObject *h2obj = gROOT->FindObject(name); if (h2obj && h2obj->InheritsFrom(TH1::Class())) { @@ -2134,24 +2128,25 @@ TH2D *TH3::DoProject2D(const char* name, const char * title, TAxis* projX, TAxis return 0; } h2 = (TH2D*)h2obj; - // check histogram axis compatibility - // note that the x axis of the projected histogram is labeld Y of the original - bool useAllBins = ((nx == projX->GetNbins() ) && (ny == projY->GetNbins() ) ); - if (useAllBins && CheckEqualAxes(projY, h2->GetXaxis() ) && - CheckEqualAxes(projX, h2->GetYaxis() ) ) { - // enable originalRange option in case a range is set in the outer axis - originalRange = kTRUE; - h2->Reset(); - } - else if ( !useAllBins && - CheckConsistentSubAxes(projY, iymin, iymax, h2->GetXaxis() ) && - CheckConsistentSubAxes(projX, ixmin, ixmax, h2->GetYaxis() ) ) { - // reset also in case an histogram exists with compatible axis with the zoomed original axis - h2->Reset(); - } - else { - Error("DoProject2D","Histogram with name %s already exists and it is not compatible",name); - return 0; + // reset histogram and its axes + h2->Reset(); + const TArrayD *xbins = projX->GetXbins(); + const TArrayD *ybins = projY->GetXbins(); + if ( originalRange ) { + h2->SetBins(projY->GetNbins(),projY->GetXmin(),projY->GetXmax() + ,projX->GetNbins(),projX->GetXmin(),projX->GetXmax()); + // set bins for mixed axis do not exists - need to set afterwards the variable bins + if (ybins->fN != 0) + h2->GetXaxis()->Set(projY->GetNbins(),&ybins->fArray[iymin-1]); + if (xbins->fN != 0) + h2->GetYaxis()->Set(projX->GetNbins(),&xbins->fArray[ixmin-1]); + } else { + h2->SetBins(ny,projY->GetBinLowEdge(iymin),projY->GetBinUpEdge(iymax) + ,nx,projX->GetBinLowEdge(ixmin),projX->GetBinUpEdge(ixmax)); + if (ybins->fN != 0) + h2->GetXaxis()->Set(ny,&ybins->fArray[iymin-1]); + if (xbins->fN != 0) + h2->GetYaxis()->Set(nx,&xbins->fArray[ixmin-1]); } } @@ -2334,7 +2329,7 @@ TH2D *TH3::DoProject2D(const char* name, const char * title, TAxis* projX, TAxis stats[5] = oldst[3]; stats[6] = oldst[9]; } - if ( projX == GetZaxis() ) { // case ZY + if ( projX == GetYaxis() ) { // case ZY stats[4] = oldst[4]; stats[5] = oldst[5]; stats[6] = oldst[10]; @@ -2401,9 +2396,8 @@ TH1 *TH3::Project3D(Option_t *option) const // A different name can be generated by attaching a string to the option // For example h->Project3D("name_xy") will generate an histogram with the name: h3dname_name_xy. // - // NOTE 2: If an histogram of the same type already exists with compatible axes, + // NOTE 2: If an histogram of the same type already exists, // the histogram is reset and filled again with the projected contents of the TH3. - // In the case of axes incompatibility, an error is reported and a NULL pointer is returned. // // NOTE 3: The number of entries in the projected histogram is estimated from the number of // effective entries for all the cells included in the projection. @@ -2411,9 +2405,7 @@ TH1 *TH3::Project3D(Option_t *option) const // NOTE 4: underflow/overflow are included by default in the projection // To exclude underflow and/or overflow (for both axis in case of a projection to a 1D histogram) use option "NUF" and/or "NOF" // With SetRange() you can have all bins except underflow/overflow only if you set the axis bit range as - // following after having called SetRange: - // axis->SetRange(1, axis->GetNbins()); - // axis->SetBit(TAxis::kAxisRange); + // following after having called SetRange: axis->SetRange(1, axis->GetNbins()); // TString opt = option; opt.ToLower(); @@ -2530,7 +2522,7 @@ TH1 *TH3::Project3D(Option_t *option) const TVirtualPad *padsav = gPad; TVirtualPad *pad = gROOT->GetSelectedPad(); if (pad) pad->cd(); - if (!gPad->FindObject(h)) { + if (!gPad || !gPad->FindObject(h)) { h->Draw(opt); } else { h->Paint(opt); @@ -2587,7 +2579,6 @@ TProfile2D *TH3::DoProjectProfile2D(const char* name, const char * title, TAxis* TProfile2D *p2 = 0; // Create the histogram, either reseting a preexisting one - // if compatible or creating one from scratch. // Does an object with the same name exists? TObject *p2obj = gROOT->FindObject(name); if (p2obj && p2obj->InheritsFrom(TH1::Class())) { @@ -2596,27 +2587,25 @@ TProfile2D *TH3::DoProjectProfile2D(const char* name, const char * title, TAxis* return 0; } p2 = (TProfile2D*)p2obj; - // check histogram compatibility (not perfect for variable bins histograms) - // note that the x axis of the projected histogram is labeld Y of the original - bool useAllBins = ((nx == projX->GetNbins() ) && (ny == projY->GetNbins() ) ); - if (useAllBins && CheckEqualAxes( projY, p2->GetXaxis() ) && - CheckEqualAxes( projX, p2->GetYaxis() ) ) { - // enable originalRange option in case a range is set in the outer axis - originalRange = kTRUE; - p2->Reset(); - } - else if ( !useAllBins && - CheckConsistentSubAxes(projY, iymin, iymax, p2->GetXaxis() ) && - CheckConsistentSubAxes(projX, ixmin, ixmax, p2->GetYaxis() ) ) { - // reset also in case an histogram exists with compatible axis with the zoomed original axis - p2->Reset(); - } - else { - p2->Dump(); - projY->Dump(); projX->Dump(); - std::cout << ny << " " << iymin << " , " << iymax << " nx " << nx << " " << ixmin << " , " << ixmax << std::endl; - Error("DoProjectProfile2D","Profile2D with name %s already exists and it is not compatible",name); - return 0; + // reset existing profile and re-set bins + p2->Reset(); + const TArrayD *xbins = projX->GetXbins(); + const TArrayD *ybins = projY->GetXbins(); + if ( originalRange ) { + p2->SetBins(projY->GetNbins(),projY->GetXmin(),projY->GetXmax() + ,projX->GetNbins(),projX->GetXmin(),projX->GetXmax()); + // set bins for mixed axis do not exists - need to set afterwards the variable bins + if (ybins->fN != 0) + p2->GetXaxis()->Set(projY->GetNbins(),&ybins->fArray[iymin-1]); + if (xbins->fN != 0) + p2->GetYaxis()->Set(projX->GetNbins(),&xbins->fArray[ixmin-1]); + } else { + p2->SetBins(ny,projY->GetBinLowEdge(iymin),projY->GetBinUpEdge(iymax) + ,nx,projX->GetBinLowEdge(ixmin),projX->GetBinUpEdge(ixmax)); + if (ybins->fN != 0) + p2->GetXaxis()->Set(ny,&ybins->fArray[iymin-1]); + if (xbins->fN != 0) + p2->GetYaxis()->Set(nx,&xbins->fArray[ixmin-1]); } } diff --git a/hist/hist/src/THStack.cxx b/hist/hist/src/THStack.cxx index 2e2fb95456e26..d2bc2f22fff3a 100644 --- a/hist/hist/src/THStack.cxx +++ b/hist/hist/src/THStack.cxx @@ -52,7 +52,7 @@ ClassImp(THStack) // c1.cd(1); // hs.Draw(); // c1.cd(2); -// hs->Draw("nostack"); +// hs.Draw("nostack"); // // See a more complex example in $ROOTSYS/tutorials/hist/hstack.C // @@ -567,7 +567,7 @@ Long64_t THStack::Merge(TCollection* li, TFileMergeInfo * /* info */) { // Merge the THStack in the TList into this stack. // Returns the total number of histograms in the result or -1 in case of an error. - + if (li==0 || li->GetEntries()==0) { return fHists->GetEntries(); } @@ -614,6 +614,12 @@ void THStack::Paint(Option_t *option) // a number of pads equal to the number of histograms and each histogram // is paint into a separate pad. // + // By default the background of the histograms is erased before drawing the + // histograms. The option "noclear" avoid this behaviour. This is useful + // when drawing a THStack on top of an other plot. If the patterns used to + // draw the histograms in the stack are transparents, then the plot behind + // will be visible. + // // See THistPainter::Paint for a list of valid options. if (!fHists) return; @@ -626,6 +632,11 @@ void THStack::Paint(Option_t *option) lsame = kTRUE; opt.ReplaceAll("same",""); } + Bool_t lclear = kTRUE; + if (opt.Contains("noclear")) { + lclear = kFALSE; + opt.ReplaceAll("noclear",""); + } if (opt.Contains("pads")) { Int_t npads = fHists->GetSize(); TVirtualPad *padsav = gPad; @@ -700,9 +711,9 @@ void THStack::Paint(Option_t *option) h = (TH1*)fHists->At(0); TAxis *xaxis = h->GetXaxis(); TAxis *yaxis = h->GetYaxis(); + const TArrayD *xbins = xaxis->GetXbins(); if (h->GetDimension() > 1) { if (strlen(option) == 0) strlcpy(loption,"lego1",32); - const TArrayD *xbins = xaxis->GetXbins(); const TArrayD *ybins = yaxis->GetXbins(); if (xbins->fN != 0 && ybins->fN != 0) { fHistogram = new TH2F(GetName(),GetTitle(), @@ -722,7 +733,12 @@ void THStack::Paint(Option_t *option) yaxis->GetNbins(), ymin, ymax); } } else { - fHistogram = new TH1F(GetName(),GetTitle(),xaxis->GetNbins(),xmin, xmax); + if (xbins->fN != 0) { + fHistogram = new TH1F(GetName(),GetTitle(), + xaxis->GetNbins(), xbins->GetArray()); + } else { + fHistogram = new TH1F(GetName(),GetTitle(),xaxis->GetNbins(),xmin, xmax); + } } fHistogram->SetStats(0); TH1::AddDirectory(add); @@ -792,7 +808,7 @@ void THStack::Paint(Option_t *option) snprintf(loption,31,"%ssame%s",noption,lnk->GetOption()); } h1 = (TH1*)fStack->At(nhists-i-1); - if (i>0) { + if (i>0 && lclear) { // Erase before drawing the histogram h1col = h1->GetFillColor(); h1fill = h1->GetFillStyle(); @@ -801,8 +817,10 @@ void THStack::Paint(Option_t *option) h1->Paint(loption); static TClassRef clTFrame = TClass::GetClass("TFrame",kFALSE); TAttFill *frameFill = (TAttFill*)clTFrame->DynamicCast(TAttFill::Class(),gPad->GetFrame()); - h1->SetFillColor(frameFill->GetFillColor()); - h1->SetFillStyle(frameFill->GetFillStyle()); + if (frameFill) { + h1->SetFillColor(frameFill->GetFillColor()); + h1->SetFillStyle(frameFill->GetFillStyle()); + } h1->Paint(loption); h1->SetFillColor(h1col); h1->SetFillStyle(h1fill); diff --git a/hist/hist/src/THn.cxx b/hist/hist/src/THn.cxx index 526093e6ef7d5..5bfdeba885087 100644 --- a/hist/hist/src/THn.cxx +++ b/hist/hist/src/THn.cxx @@ -210,15 +210,16 @@ void THn::AllocCoordBuf() const { // Create the coordinate buffer. Outlined to hide allocation // from inlined functions. - fCoordBuf = new Int_t[fNdimensions]; + fCoordBuf = new Int_t[fNdimensions](); } //______________________________________________________________________________ void THn::InitStorage(Int_t* nbins, Int_t /*chunkSize*/) { // Initialize the storage of a histogram created via Init() - fCoordBuf = new Int_t[fNdimensions]; + fCoordBuf = new Int_t[fNdimensions](); GetArray().Init(fNdimensions, nbins, true /*addOverflow*/); + fSumw2.Init(fNdimensions, nbins, true /*addOverflow*/); } //______________________________________________________________________________ diff --git a/hist/hist/src/THnBase.cxx b/hist/hist/src/THnBase.cxx index 27288a1c0bd55..f6f53ea82df48 100644 --- a/hist/hist/src/THnBase.cxx +++ b/hist/hist/src/THnBase.cxx @@ -43,8 +43,8 @@ ClassImp(THnBase); //______________________________________________________________________________ THnBase::THnBase(const char* name, const char* title, Int_t dim, const Int_t* nbins, const Double_t* xmin, const Double_t* xmax): - TNamed(name, title), fNdimensions(dim), fAxes(dim), fEntries(0), fTsumw(0), - fTsumw2(-1.), fTsumwx(dim), fTsumwx2(dim), + TNamed(name, title), fNdimensions(dim), fAxes(dim), fBrowsables(dim), + fEntries(0), fTsumw(0), fTsumw2(-1.), fTsumwx(dim), fTsumwx2(dim), fIntegral(0), fIntegralStatus(kNoInt) { // Construct a THnBase with "dim" dimensions, @@ -103,7 +103,13 @@ void THnBase::Init(const char* name, const char* title, TAxis* reqaxis = (TAxis*)axis->Clone(); if (!keepTargetAxis && axis->TestBit(TAxis::kAxisRange)) { Int_t binFirst = axis->GetFirst(); + // The lowest egde of the underflow is meaningless. + if (binFirst == 0) + binFirst = 1; Int_t binLast = axis->GetLast(); + // The overflow edge is implicit. + if (binLast > axis->GetNbins()) + binLast = axis->GetNbins(); Int_t nBins = binLast - binFirst + 1; if (axis->GetXbins()->GetSize()) { // non-uniform bins: @@ -417,13 +423,6 @@ void THnBase::GetRandom(Double_t *rand, Bool_t subBinRandom /* = kTRUE */) Bool_t THnBase::IsInRange(Int_t *coord) const { // Check whether bin coord is in range, as defined by TAxis::SetRange(). - // Currently, TAxis::SetRange() does not allow to select all but over- and - // underflow bins (it instead resets the axis to "no range selected"). - // Instead, simply call - // TAxis* axis12 = hsparse.GetAxis(12); - // axis12->SetRange(1, axis12->GetNbins()); - // axis12->SetBit(TAxis::kAxisRange); - // to deselect the under- and overflow bins in the 12th dimension. Int_t min = 0; Int_t max = 0; @@ -432,13 +431,6 @@ Bool_t THnBase::IsInRange(Int_t *coord) const if (!axis->TestBit(TAxis::kAxisRange)) continue; min = axis->GetFirst(); max = axis->GetLast(); - if (min == 0 && max == 0) { - // special case where TAxis::SetBit(kAxisRange) and - // over- and underflow bins are de-selected. - // first and last are == 0 due to axis12->SetRange(1, axis12->GetNbins()); - min = 1; - max = axis->GetNbins(); - } if (coord[i] < min || coord[i] > max) return kFALSE; } @@ -535,7 +527,10 @@ TObject* THnBase::ProjectionAny(Int_t ndim, const Int_t* dim, for (Int_t d = 0; d < ndim; ++d) { bins[d] = iter.GetCoord(dim[d]); if (!keepTargetAxis && GetAxis(dim[d])->TestBit(TAxis::kAxisRange)) { - bins[d] -= GetAxis(dim[d])->GetFirst() - 1; + Int_t binOffset = GetAxis(dim[d])->GetFirst(); + // Don't subtract even more if underflow is alreday included: + if (binOffset > 0) --binOffset; + bins[d] -= binOffset; } } @@ -1383,7 +1378,7 @@ void THnBase::Browse(TBrowser *b) // dimension. if (fBrowsables.IsEmpty()) { for (Int_t dim = 0; dim < fNdimensions; ++dim) { - fBrowsables[dim] = new ROOT::THnBaseBrowsable(this, dim); + fBrowsables.AddAtAndExpand(new ROOT::THnBaseBrowsable(this, dim), dim); } fBrowsables.SetOwner(); } diff --git a/hist/hist/src/THnSparse.cxx b/hist/hist/src/THnSparse.cxx index a71eafc518a8a..856f4dbded25b 100644 --- a/hist/hist/src/THnSparse.cxx +++ b/hist/hist/src/THnSparse.cxx @@ -547,8 +547,6 @@ void THnSparseArrayChunk::Sumw2() // a THnSparse. See the Projection() members. To only project parts of the // histogram, call // THnSparse::GetAxis(12)->SetRange(from_bin, to_bin); -// See the important remark in THnSparse::IsInRange() when excluding under- -// and overflow bins! // // * Internal Representation // An entry for a filled bin consists of its n-dimensional coordinates and diff --git a/hist/hist/src/TLimit.cxx b/hist/hist/src/TLimit.cxx index d3d60246dadb6..5769d94be3071 100644 --- a/hist/hist/src/TLimit.cxx +++ b/hist/hist/src/TLimit.cxx @@ -105,7 +105,7 @@ TConfidenceLevel *TLimit::ComputeLimit(TLimitDataSource * data, infile->Close(); </PRE></BLOCKQUOTE></p> <p></p> - <p>More informations can still be found on + <p>More information can still be found on <a HREF="http://cern.ch/aleph-proj-alphapp/doc/tlimit.html">this</a> page.</p> </FONT> */ diff --git a/hist/hist/src/TMultiDimFit.cxx b/hist/hist/src/TMultiDimFit.cxx index 26a146520f041..9999a208de977 100644 --- a/hist/hist/src/TMultiDimFit.cxx +++ b/hist/hist/src/TMultiDimFit.cxx @@ -2380,11 +2380,17 @@ void TMultiDimFit::Fit(Option_t *option) Warning("Fit", "test sample is very small"); if (!opt.Contains("m")) { + Error("Fit", "invalid option"); delete [] x; return; } fFitter = TVirtualFitter::Fitter(0,fNCoefficients); + if (!fFitter) { + Error("Fit", "Vannot create Fitter"); + delete [] x; + return; + } fFitter->SetFCN(mdfHelper); const Int_t maxArgs = 16; diff --git a/hist/hist/src/TMultiGraph.cxx b/hist/hist/src/TMultiGraph.cxx index ddcee067703dd..73aaac735c4bd 100644 --- a/hist/hist/src/TMultiGraph.cxx +++ b/hist/hist/src/TMultiGraph.cxx @@ -62,24 +62,24 @@ class. All details about the various painting options are given in mg->Add(gr2,"cp"); mg->Draw("a"); </pre> -A special option <tt>3D</tt> allows to draw the graphs in a 3D space. See the +A special option <tt>3D</tt> allows to draw the graphs in a 3D space. See the following example: End_Html Begin_Macro(source) { c0 = new TCanvas("c1","multigraph L3",200,10,700,500); c0->SetFrameFillColor(30); - + TMultiGraph *mg = new TMultiGraph(); - + TGraph *gr1 = new TGraph(); gr1->SetLineColor(kBlue); TGraph *gr2 = new TGraph(); gr2->SetLineColor(kRed); TGraph *gr3 = new TGraph(); gr3->SetLineColor(kGreen); TGraph *gr4 = new TGraph(); gr4->SetLineColor(kOrange); - + Double_t dx = 6.28/100; Double_t x = -3.14; - + for (int i=0; i<=100; i++) { x = x+dx; gr1->SetPoint(i,x,2.*TMath::Sin(x)); @@ -87,12 +87,12 @@ Begin_Macro(source) gr3->SetPoint(i,x,TMath::Cos(x*x)); gr4->SetPoint(i,x,TMath::Cos(x*x*x)); } - + mg->Add(gr4); gr4->SetTitle("Cos(x*x*x)"); gr4->SetLineWidth(3); mg->Add(gr3); gr3->SetTitle("Cos(x*x)") ; gr3->SetLineWidth(3); mg->Add(gr2); gr2->SetTitle("Cos(x)") ; gr2->SetLineWidth(3); mg->Add(gr1); gr1->SetTitle("2*Sin(x)") ; gr1->SetLineWidth(3); - + mg->Draw("a fb l3d"); return c0; } @@ -276,7 +276,7 @@ End_Html */ //______________________________________________________________________________ TMultiGraph::TMultiGraph(): TNamed() { - // TMultiGraph default constructor + // TMultiGraph default constructor. fGraphs = 0; fFunctions = 0; @@ -290,7 +290,7 @@ TMultiGraph::TMultiGraph(): TNamed() TMultiGraph::TMultiGraph(const char *name, const char *title) : TNamed(name,title) { - // Constructor with name and title + // Constructor with name and title. fGraphs = 0; fFunctions = 0; @@ -309,16 +309,16 @@ TMultiGraph::TMultiGraph(const TMultiGraph& mg) : fMaximum(mg.fMaximum), fMinimum(mg.fMinimum) { - // Copy constructor + // Copy constructor. } //______________________________________________________________________________ TMultiGraph& TMultiGraph::operator=(const TMultiGraph& mg) { - // Assignement operator - - if(this!=&mg) { + // Assignement operator. + + if (this!=&mg) { TNamed::operator=(mg); fGraphs=mg.fGraphs; fFunctions=mg.fFunctions; @@ -333,7 +333,7 @@ TMultiGraph& TMultiGraph::operator=(const TMultiGraph& mg) //______________________________________________________________________________ TMultiGraph::~TMultiGraph() { - // TMultiGraph destructor + // TMultiGraph destructor. if (!fGraphs) return; TGraph *g; @@ -354,7 +354,7 @@ TMultiGraph::~TMultiGraph() //drawing modes TObject *obj; while ((obj = fFunctions->First())) { - while(fFunctions->Remove(obj)) { } + while (fFunctions->Remove(obj)) { } delete obj; } delete fFunctions; @@ -380,18 +380,24 @@ void TMultiGraph::Add(TGraph *graph, Option_t *chopt) void TMultiGraph::Add(TMultiGraph *multigraph, Option_t *chopt) { // Add all the graphs in "multigraph" to the list of graphs. + // If "chopt" is defined all the graphs in "multigraph" will be added with + // the "chopt" option. + // If "chopt" is undefined each graph will be added with the option it had + // in "multigraph". TList *graphlist = multigraph->GetListOfGraphs(); if (!graphlist) return; if (!fGraphs) fGraphs = new TList(); - TGraph *gr; - gr = (TGraph*)graphlist->First(); - fGraphs->Add(gr,chopt); - for(Int_t i = 1; i < graphlist->GetSize(); i++){ - gr = (TGraph*)graphlist->After(gr); - fGraphs->Add(gr,chopt); + TObjOptLink *lnk = (TObjOptLink*)graphlist->FirstLink(); + TObject *obj = 0; + + while (lnk) { + obj = lnk->GetObject(); + if (!strlen(chopt)) fGraphs->Add(obj,lnk->GetOption()); + else fGraphs->Add(obj,chopt); + lnk = (TObjOptLink*)lnk->Next(); } } @@ -409,7 +415,7 @@ void TMultiGraph::Browse(TBrowser *) //______________________________________________________________________________ Int_t TMultiGraph::DistancetoPrimitive(Int_t px, Int_t py) { - // Compute distance from point px,py to each graph + // Compute distance from point px,py to each graph. // Are we on the axis? const Int_t kMaxDiff = 10; @@ -437,7 +443,7 @@ void TMultiGraph::Draw(Option_t *option) { // Draw this multigraph with its current attributes. // - // Options to draw a graph are described in TGraph::PaintGraph + // Options to draw a graph are described in TGraphPainter. // // The drawing option for each TGraph may be specified as an optional // second argument of the Add function. You can use GetGraphDrawOption @@ -447,6 +453,13 @@ void TMultiGraph::Draw(Option_t *option) // TMultiGraph::Draw. Use GetDrawOption to return the option specified // when drawing the TMultiGraph. + TString opt = option; + opt.ToLower(); + + if (gPad) { + if (!gPad->IsEditable()) gROOT->MakeDefCanvas(); + if (opt.Contains("a")) gPad->Clear(); + } AppendPad(option); } @@ -627,7 +640,7 @@ TFitResultPtr TMultiGraph::Fit(TF1 *f1, Option_t *option, Option_t *goption, Axi //______________________________________________________________________________ void TMultiGraph::FitPanel() { - // Display a panel with all histogram fit options + // Display a panel with all histogram fit options. // See class TFitPanel for example if (!gPad) @@ -651,7 +664,7 @@ void TMultiGraph::FitPanel() //______________________________________________________________________________ Option_t *TMultiGraph::GetGraphDrawOption(const TGraph *gr) const { - // Return the draw option for the TGraph gr in this TMultiGraph + // Return the draw option for the TGraph gr in this TMultiGraph. // The return option is the one specified when calling TMultiGraph::Add(gr,option). if (!fGraphs || !gr) return ""; @@ -684,7 +697,7 @@ void TMultiGraph::InitGaus(Double_t xmin, Double_t xmax) px=g->GetX(); py=g->GetY(); npp=g->GetN(); - for (bin=0; bin<npp; bin++){ + for (bin=0; bin<npp; bin++) { x=px[bin]; if (x<xmin || x>xmax) continue; np++; @@ -774,7 +787,7 @@ void TMultiGraph::LeastSquareFit(Int_t m, Double_t *a, Double_t xmin, Double_t x while ((g = (TGraph*) next())) { px=g->GetX(); npp=g->GetN(); - for (bin=0; bin<npp; bin++){ + for (bin=0; bin<npp; bin++) { xk=px[bin]; if (xk < xmin || xk > xmax) continue; n++; @@ -837,7 +850,8 @@ void TMultiGraph::LeastSquareFit(Int_t m, Double_t *a, Double_t xmin, Double_t x //______________________________________________________________________________ -void TMultiGraph::LeastSquareLinearFit(Int_t ndata, Double_t &a0, Double_t &a1, Int_t &ifail, Double_t xmin, Double_t xmax) +void TMultiGraph::LeastSquareLinearFit(Int_t ndata, Double_t &a0, Double_t &a1, + Int_t &ifail, Double_t xmin, Double_t xmax) { // Least square linear fit without weights. // @@ -916,7 +930,7 @@ Int_t TMultiGraph::IsInside(Double_t x, Double_t y) const //______________________________________________________________________________ TH1F *TMultiGraph::GetHistogram() const { - // Returns a pointer to the histogram used to draw the axis + // Returns a pointer to the histogram used to draw the axis. // Takes into account the two following cases. // 1- option 'A' was specified in TMultiGraph::Draw. Return fHistogram // 2- user had called TPad::DrawFrame. return pointer to hframe histogram @@ -946,8 +960,8 @@ TF1 *TMultiGraph::GetFunction(const char *name) const //______________________________________________________________________________ TList *TMultiGraph::GetListOfFunctions() { - // Return pointer to list of functions - // if pointer is null create the list + // Return pointer to list of functions. + // If pointer is null create the list if (!fFunctions) fFunctions = new TList(); return fFunctions; @@ -958,6 +972,7 @@ TList *TMultiGraph::GetListOfFunctions() TAxis *TMultiGraph::GetXaxis() const { // Get x axis of the graph. + // This method returns a valid axis only after the TMultigraph has been drawn. if (!gPad) return 0; TH1 *h = GetHistogram(); @@ -970,6 +985,7 @@ TAxis *TMultiGraph::GetXaxis() const TAxis *TMultiGraph::GetYaxis() const { // Get y axis of the graph. + // This method returns a valid axis only after the TMultigraph has been drawn. if (!gPad) return 0; TH1 *h = GetHistogram(); @@ -981,8 +997,8 @@ TAxis *TMultiGraph::GetYaxis() const //______________________________________________________________________________ void TMultiGraph::Paint(Option_t *option) { - // Paint all the graphs of this multigraph - + // Paint all the graphs of this multigraph. + const TPickerStackGuard pushGuard(this); if (!fGraphs) return; @@ -1092,11 +1108,11 @@ void TMultiGraph::Paint(Option_t *option) //else uxmax = 0; } if (minimum < 0 && rwymin >= 0) { - if(gPad->GetLogy()) minimum = 0.9*rwymin; + if (gPad->GetLogy()) minimum = 0.9*rwymin; //else minimum = 0; } if (maximum > 0 && rwymax <= 0) { - if(gPad->GetLogy()) maximum = 1.1*rwymax; + if (gPad->GetLogy()) maximum = 1.1*rwymax; //else maximum = 0; } if (minimum <= 0 && gPad->GetLogy()) minimum = 0.001*maximum; @@ -1138,11 +1154,11 @@ void TMultiGraph::Paint(Option_t *option) TObject *obj = 0; while (lnk) { - + obj = lnk->GetObject(); - + gPad->PushSelectableObject(obj); - + if (!gPad->PadInHighlightMode() || (gPad->PadInHighlightMode() && obj == gPad->GetSelected())) { if (strlen(lnk->GetOption())) obj->Paint(lnk->GetOption()); @@ -1177,7 +1193,7 @@ void TMultiGraph::Paint(Option_t *option) //______________________________________________________________________________ void TMultiGraph::PaintPolyLine3D(Option_t *option) { - // Paint all the graphs of this multigraph as 3D lines + // Paint all the graphs of this multigraph as 3D lines. Int_t i, npt=0; char *l; @@ -1202,7 +1218,7 @@ void TMultiGraph::PaintPolyLine3D(Option_t *option) } Int_t ndiv = fGraphs->GetSize(); - TH2F* frame = new TH2F("frame","", ndiv, 0., (Double_t)(ndiv), + TH2F* frame = new TH2F("frame","", ndiv, 0., (Double_t)(ndiv), 10, rwxmin, rwxmax); TAxis *Xaxis = frame->GetXaxis(); @@ -1216,15 +1232,15 @@ void TMultiGraph::PaintPolyLine3D(Option_t *option) frame->SetStats(kFALSE); frame->SetMinimum(rwymin); frame->SetMaximum(rwymax); - + l = (char*)strstr(option,"A"); if (l) frame->Paint("lego0,fb,bb"); l = (char*)strstr(option,"BB"); if (!l) frame->Paint("lego0,fb,a,same"); - + Double_t *x, *y; Double_t xyz1[3], xyz2[3]; - + next.Reset(); Int_t j = ndiv; while ((g = (TGraph*) next())) { @@ -1246,7 +1262,7 @@ void TMultiGraph::PaintPolyLine3D(Option_t *option) } j--; } - + l = (char*)strstr(option,"FB"); if (!l) frame->Paint("lego0,bb,a,same"); delete frame; @@ -1256,7 +1272,7 @@ void TMultiGraph::PaintPolyLine3D(Option_t *option) //______________________________________________________________________________ void TMultiGraph::Print(Option_t *option) const { - // Print the list of graphs + // Print the list of graphs. TGraph *g; if (fGraphs) { @@ -1272,7 +1288,7 @@ void TMultiGraph::Print(Option_t *option) const void TMultiGraph::RecursiveRemove(TObject *obj) { // Recursively remove this object from a list. Typically implemented - // by classes that can contain mulitple references to a same object. + // by classes that can contain multiple references to a same object. if (!fGraphs) return; TObject *objr = fGraphs->Remove(obj); @@ -1285,7 +1301,7 @@ void TMultiGraph::RecursiveRemove(TObject *obj) //______________________________________________________________________________ void TMultiGraph::SavePrimitive(ostream &out, Option_t *option /*= ""*/) { - // Save primitive as a C++ statement(s) on output stream out + // Save primitive as a C++ statement(s) on output stream out. char quote = '"'; out<<" "<<endl; @@ -1339,4 +1355,4 @@ void TMultiGraph::SetMinimum(Double_t minimum) fMinimum = minimum; if (fHistogram) fHistogram->SetMinimum(minimum); -} +} \ No newline at end of file diff --git a/hist/hist/src/TPolyMarker.cxx b/hist/hist/src/TPolyMarker.cxx index dc59826cbbe0a..5b1095f627b45 100644 --- a/hist/hist/src/TPolyMarker.cxx +++ b/hist/hist/src/TPolyMarker.cxx @@ -116,6 +116,9 @@ TPolyMarker& TPolyMarker::operator=(const TPolyMarker& pm) TAttMarker::operator=(pm); fN=pm.fN; fLastPoint=pm.fLastPoint; + // delete first previous existing fX and fY + if (fX) delete [] fX; + if (fY) delete [] fY; fX=pm.fX; fY=pm.fY; fOption=pm.fOption; @@ -155,6 +158,9 @@ void TPolyMarker::Copy(TObject &obj) const TObject::Copy(obj); TAttMarker::Copy(((TPolyMarker&)obj)); ((TPolyMarker&)obj).fN = fN; + // delete first previous existing fX and fY + if (((TPolyMarker&)obj).fX) delete [] (((TPolyMarker&)obj).fX); + if (((TPolyMarker&)obj).fY) delete [] (((TPolyMarker&)obj).fY); if (fN > 0) { ((TPolyMarker&)obj).fX = new Double_t [fN]; ((TPolyMarker&)obj).fY = new Double_t [fN]; diff --git a/hist/hist/src/TPrincipal.cxx b/hist/hist/src/TPrincipal.cxx index ea01e34bce3ab..72b400d674f3b 100644 --- a/hist/hist/src/TPrincipal.cxx +++ b/hist/hist/src/TPrincipal.cxx @@ -1260,6 +1260,7 @@ void TPrincipal::MakeHistograms(const char *name, Option_t *opt) // update the original data histogram x = (Double_t*)(GetRow(i)); + R__ASSERT(x); if (makeP||makeD||makeS) // calculate the corresponding principal component diff --git a/hist/hist/src/TProfile.cxx b/hist/hist/src/TProfile.cxx index 709a179ab2351..b3706660fc821 100644 --- a/hist/hist/src/TProfile.cxx +++ b/hist/hist/src/TProfile.cxx @@ -236,12 +236,8 @@ void TProfile::BuildOptions(Double_t ymin, Double_t ymax, Option_t *option) SetErrorOption(option); - fBinEntries.Set(fNcells); //*-* create number of entries per bin array - - // TH1::Sumw2 create sum of square of weights array times y (fSumw2) . This is always created for a TProfile - TH1::Sumw2(); //*-* create sum of squares of weights array times y - // TProfile::Sumw2 create sum of square of weight2 (fBinSumw2). This is needed only for profile filled with weights not 1 - if (fgDefaultSumw2) Sumw2(); // optionally create sum of squares of weights / bin + // create extra profile data structire (bin entries/ y^2 and sum of weight square) + TProfileHelper::BuildArray(this); fYmin = ymin; fYmax = ymax; @@ -424,20 +420,27 @@ void TProfile::Copy(TObject &obj) const //*-*-*-*-*-*-*-*Copy a Profile histogram to a new profile histogram*-*-*-*-* //*-* =================================================== - TH1D::Copy(((TProfile&)obj)); - fBinEntries.Copy(((TProfile&)obj).fBinEntries); - fBinSumw2.Copy(((TProfile&)obj).fBinSumw2); - for (int bin=0;bin<fNcells;bin++) { - ((TProfile&)obj).fArray[bin] = fArray[bin]; - ((TProfile&)obj).fSumw2.fArray[bin] = fSumw2.fArray[bin]; + try { + TProfile & pobj = dynamic_cast<TProfile&>(obj); + TH1D::Copy(pobj); + fBinEntries.Copy(pobj.fBinEntries); + fBinSumw2.Copy(pobj.fBinSumw2); + for (int bin=0;bin<fNcells;bin++) { + pobj.fArray[bin] = fArray[bin]; + pobj.fSumw2.fArray[bin] = fSumw2.fArray[bin]; + } + + pobj.fYmin = fYmin; + pobj.fYmax = fYmax; + pobj.fScaling = fScaling; + pobj.fErrorMode = fErrorMode; + pobj.fTsumwy = fTsumwy; + pobj.fTsumwy2 = fTsumwy2; + + } catch(...) { + Fatal("Copy","Cannot copy a TProfile in a %s",obj.IsA()->GetName()); } - - ((TProfile&)obj).fYmin = fYmin; - ((TProfile&)obj).fYmax = fYmax; - ((TProfile&)obj).fScaling = fScaling; - ((TProfile&)obj).fErrorMode = fErrorMode; - ((TProfile&)obj).fTsumwy = fTsumwy; - ((TProfile&)obj).fTsumwy2 = fTsumwy2; + } @@ -1667,9 +1670,6 @@ void TProfile::SetBins(Int_t nx, Double_t xmin, Double_t xmax) fXaxis.Set(nx,xmin,xmax); fNcells = nx+2; SetBinsLength(fNcells); - fBinEntries.Set(fNcells); - fSumw2.Set(fNcells); - if (fBinSumw2.fN) fBinSumw2.Set(fNcells); } //______________________________________________________________________________ @@ -1681,11 +1681,16 @@ void TProfile::SetBins(Int_t nx, const Double_t *xbins) fXaxis.Set(nx,xbins); fNcells = nx+2; SetBinsLength(fNcells); - fBinEntries.Set(fNcells); - fSumw2.Set(fNcells); - if (fBinSumw2.fN) fBinSumw2.Set(fNcells); } +//______________________________________________________________________________ +void TProfile::SetBinsLength(Int_t n) +{ + // Set total number of bins including under/overflow + // Reallocate bin contents array + TH1D::SetBinsLength(n); + TProfileHelper::BuildArray(this); +} //______________________________________________________________________________ void TProfile::SetBuffer(Int_t buffersize, Option_t *) @@ -1704,7 +1709,7 @@ void TProfile::SetBuffer(Int_t buffersize, Option_t *) if (buffersize < 100) buffersize = 100; fBufferSize = 1 + 3*buffersize; fBuffer = new Double_t[fBufferSize]; - memset(fBuffer,0,8*fBufferSize); + memset(fBuffer,0,sizeof(Double_t)*fBufferSize); } //______________________________________________________________________________ @@ -1772,15 +1777,16 @@ void TProfile::Streamer(TBuffer &R__b) } } //______________________________________________________________________________ -void TProfile::Sumw2() +void TProfile::Sumw2(Bool_t flag) { - // Create structure to store sum of squares of weights per bin *-*-*-*-*-*-*-* + // Create/delete structure to store sum of squares of weights per bin *-*-*-*-*-*-*-* // This is needed to compute the correct statistical quantities // of a profile filled with weights // // // This function is automatically called when the histogram is created // if the static function TH1::SetDefaultSumw2 has been called before. + // If flag is false the structure is deleted - TProfileHelper::Sumw2(this); + TProfileHelper::Sumw2(this, flag); } diff --git a/hist/hist/src/TProfile2D.cxx b/hist/hist/src/TProfile2D.cxx index a9067825b251c..01074500ebda6 100644 --- a/hist/hist/src/TProfile2D.cxx +++ b/hist/hist/src/TProfile2D.cxx @@ -179,10 +179,8 @@ void TProfile2D::BuildOptions(Double_t zmin, Double_t zmax, Option_t *option) SetErrorOption(option); - fBinEntries.Set(fNcells); //*-* create number of entries per cell array - - TH1::Sumw2(); //*-* create sum of squares of weights array times y - if (fgDefaultSumw2) Sumw2(); // optionally create sum of squares of weights + // create extra profile data structire (bin entries/ y^2 and sum of weight square) + TProfileHelper::BuildArray(this); fZmin = zmin; fZmax = zmax; @@ -370,19 +368,27 @@ void TProfile2D::Copy(TObject &obj) const //*-*-*-*-*-*-*-*Copy a Profile2D histogram to a new profile2D histogram*-*-*-* //*-* ======================================================= - TH2D::Copy(((TProfile2D&)obj)); - fBinEntries.Copy(((TProfile2D&)obj).fBinEntries); - fBinSumw2.Copy(((TProfile2D&)obj).fBinSumw2); - for (int bin=0;bin<fNcells;bin++) { - ((TProfile2D&)obj).fArray[bin] = fArray[bin]; - ((TProfile2D&)obj).fSumw2.fArray[bin] = fSumw2.fArray[bin]; + try { + TProfile2D & pobj = dynamic_cast<TProfile2D&>(obj); + + TH2D::Copy(pobj); + fBinEntries.Copy(pobj.fBinEntries); + fBinSumw2.Copy(pobj.fBinSumw2); + for (int bin=0;bin<fNcells;bin++) { + pobj.fArray[bin] = fArray[bin]; + pobj.fSumw2.fArray[bin] = fSumw2.fArray[bin]; + } + pobj.fZmin = fZmin; + pobj.fZmax = fZmax; + pobj.fScaling = fScaling; + pobj.fErrorMode = fErrorMode; + pobj.fTsumwz = fTsumwz; + pobj.fTsumwz2 = fTsumwz2; + + } catch(...) { + Fatal("Copy","Cannot copy a TProfile2D in a %s",obj.IsA()->GetName()); } - ((TProfile2D&)obj).fZmin = fZmin; - ((TProfile2D&)obj).fZmax = fZmax; - ((TProfile2D&)obj).fScaling = fScaling; - ((TProfile2D&)obj).fErrorMode = fErrorMode; - ((TProfile2D&)obj).fTsumwz = fTsumwz; - ((TProfile2D&)obj).fTsumwz2 = fTsumwz2; + } @@ -1748,6 +1754,14 @@ void TProfile2D::SetBins(Int_t nx, const Double_t *xbins, Int_t ny, const Doubl if (fBinSumw2.fN) fBinSumw2.Set(fNcells); } +//______________________________________________________________________________ +void TProfile2D::SetBinsLength(Int_t n) +{ + // Set total number of bins including under/overflow + // Reallocate bin contents array + TH2D::SetBinsLength(n); + TProfileHelper::BuildArray(this); +} //______________________________________________________________________________ void TProfile2D::SetBuffer(Int_t buffersize, Option_t *) @@ -1766,7 +1780,7 @@ void TProfile2D::SetBuffer(Int_t buffersize, Option_t *) if (buffersize < 100) buffersize = 100; fBufferSize = 1 + 4*buffersize; fBuffer = new Double_t[fBufferSize]; - memset(fBuffer,0,8*fBufferSize); + memset(fBuffer,0,sizeof(Double_t)*fBufferSize); } //______________________________________________________________________________ @@ -1834,15 +1848,16 @@ void TProfile2D::Streamer(TBuffer &R__b) } //______________________________________________________________________________ -void TProfile2D::Sumw2() +void TProfile2D::Sumw2(Bool_t flag) { - // Create structure to store sum of squares of weights per bin *-*-*-*-*-*-*-* + // Create/Delete structure to store sum of squares of weights per bin *-*-*-*-*-*-*-* // This is needed to compute the correct statistical quantities // of a profile filled with weights // // // This function is automatically called when the histogram is created // if the static function TH1::SetDefaultSumw2 has been called before. + // If flag is false the structure is deleted - TProfileHelper::Sumw2(this); + TProfileHelper::Sumw2(this, flag); } diff --git a/hist/hist/src/TProfile3D.cxx b/hist/hist/src/TProfile3D.cxx index c40ba2a6425b0..30729a568414a 100644 --- a/hist/hist/src/TProfile3D.cxx +++ b/hist/hist/src/TProfile3D.cxx @@ -143,10 +143,8 @@ void TProfile3D::BuildOptions(Double_t tmin, Double_t tmax, Option_t *option) SetErrorOption(option); - fBinEntries.Set(fNcells); //*-* create number of entries per cell array - - TH1::Sumw2(); //*-* create sum of squares of weights array times y - if (fgDefaultSumw2) Sumw2(); // optionally create sum of squares of weights + // create extra profile data structire (bin entries/ y^2 and sum of weight square) + TProfileHelper::BuildArray(this); fTmin = tmin; fTmax = tmax; @@ -343,22 +341,28 @@ void TProfile3D::Copy(TObject &obj) const //*-*-*-*-*-*-*-*Copy a Profile3D histogram to a new profile2D histogram*-*-*-* //*-* ======================================================= - TH3D::Copy(((TProfile3D&)obj)); - fBinEntries.Copy(((TProfile3D&)obj).fBinEntries); - fBinSumw2.Copy(((TProfile3D&)obj).fBinSumw2); - for (int bin=0;bin<fNcells;bin++) { - ((TProfile3D&)obj).fArray[bin] = fArray[bin]; - ((TProfile3D&)obj).fSumw2.fArray[bin] = fSumw2.fArray[bin]; + try { + TProfile3D & pobj = dynamic_cast<TProfile3D&>(obj); + + TH3D::Copy(pobj); + fBinEntries.Copy(pobj.fBinEntries); + fBinSumw2.Copy(pobj.fBinSumw2); + for (int bin=0;bin<fNcells;bin++) { + pobj.fArray[bin] = fArray[bin]; + pobj.fSumw2.fArray[bin] = fSumw2.fArray[bin]; + } + pobj.fTmin = fTmin; + pobj.fTmax = fTmax; + pobj.fScaling = fScaling; + pobj.fErrorMode = fErrorMode; + pobj.fTsumwt = fTsumwt; + pobj.fTsumwt2 = fTsumwt2; + + } catch(...) { + Fatal("Copy","Cannot copy a TProfile3D in a %s",obj.IsA()->GetName()); } - ((TProfile3D&)obj).fTmin = fTmin; - ((TProfile3D&)obj).fTmax = fTmax; - ((TProfile3D&)obj).fScaling = fScaling; - ((TProfile3D&)obj).fErrorMode = fErrorMode; - ((TProfile3D&)obj).fTsumwt = fTsumwt; - ((TProfile3D&)obj).fTsumwt2 = fTsumwt2; } - //______________________________________________________________________________ Bool_t TProfile3D::Divide(TF1 *, Double_t ) { @@ -1262,6 +1266,16 @@ void TProfile3D::SetBins(Int_t nx, const Double_t *xBins, Int_t ny, const Double fBinEntries.Set(fNcells); if (fBinSumw2.fN) fBinSumw2.Set(fNcells); } + +//______________________________________________________________________________ +void TProfile3D::SetBinsLength(Int_t n) +{ + // Set total number of bins including under/overflow + // Reallocate bin contents array + TH3D::SetBinsLength(n); + TProfileHelper::BuildArray(this); +} + //______________________________________________________________________________ void TProfile3D::SetBuffer(Int_t buffersize, Option_t *) { @@ -1279,7 +1293,7 @@ void TProfile3D::SetBuffer(Int_t buffersize, Option_t *) if (buffersize < 100) buffersize = 100; fBufferSize = 1 + 5*buffersize; fBuffer = new Double_t[fBufferSize]; - memset(fBuffer,0,8*fBufferSize); + memset(fBuffer,0,sizeof(Double_t)*fBufferSize); } //______________________________________________________________________________ @@ -1314,15 +1328,16 @@ void TProfile3D::SetErrorOption(Option_t *option) } //______________________________________________________________________________ -void TProfile3D::Sumw2() +void TProfile3D::Sumw2(Bool_t flag) { - // Create structure to store sum of squares of weights per bin *-*-*-*-*-*-*-* + // Create/Delete structure to store sum of squares of weights per bin *-*-*-*-*-*-*-* // This is needed to compute the correct statistical quantities // of a profile filled with weights // // // This function is automatically called when the histogram is created // if the static function TH1::SetDefaultSumw2 has been called before. + // If flag = false the structure is deleted - TProfileHelper::Sumw2(this); + TProfileHelper::Sumw2(this, flag); } diff --git a/hist/hist/src/TProfileHelper.h b/hist/hist/src/TProfileHelper.h index d391e8322f44b..9ab0af5653136 100644 --- a/hist/hist/src/TProfileHelper.h +++ b/hist/hist/src/TProfileHelper.h @@ -33,6 +33,9 @@ class TProfileHelper { template <typename T> static Bool_t Add(T* p, const TH1 *h1, const TH1 *h2, Double_t c1, Double_t c2=1); + template <typename T> + static void BuildArray(T* p); + template <typename T> static Double_t GetBinEffectiveEntries(T* p, Int_t bin); @@ -46,7 +49,7 @@ class TProfileHelper { static void Scale(T* p, Double_t c1, Option_t * option); template <typename T> - static void Sumw2(T* p); + static void Sumw2(T* p, Bool_t flag ); template <typename T> static void LabelsDeflate(T* p, Option_t *); @@ -120,6 +123,19 @@ Bool_t TProfileHelper::Add(T* p, const TH1 *h1, const TH1 *h2, Double_t c1, Dou return kTRUE; } +template <typename T> +void TProfileHelper::BuildArray(T* p) { + // Build the extra profile data structure in addition to the histograms + // this are: array of bin entries: fBinEntries + // array of sum of profiled observable value - squared + // stored in TH1::fSumw2 + // array of some of weight squared (optional) in TProfile::fBinSumw2 + p->fBinEntries.Set(p->fNcells); + p->fSumw2.Set(p->fNcells); + if (TH1::GetDefaultSumw2() || p->fBinSumw2.fN > 0 ) p->fBinSumw2.Set(p->fNcells); +} + + template <typename T> Double_t TProfileHelper::GetBinEffectiveEntries(T* p, Int_t bin) { @@ -171,6 +187,7 @@ Long64_t TProfileHelper::Merge(T* p, TCollection *li) { Bool_t initialLimitsFound = kFALSE; Bool_t allSameLimits = kTRUE; Bool_t allHaveLimits = kTRUE; + Bool_t firstNonEmptyHist = kTRUE; TIter next(&inlist); T* h = p; @@ -185,6 +202,24 @@ Long64_t TProfileHelper::Merge(T* p, TCollection *li) { if (hasLimits) { h->BufferEmpty(); + + // this is done in case the first histograms are empty and + // the histogram have different limits + if (firstNonEmptyHist ) { + // set axis limits in the case the first histogram was empty + if (h != p ) { + if (!p->SameLimitsAndNBins(p->fXaxis, *(h->GetXaxis())) ) + p->fXaxis.Set(h->GetXaxis()->GetNbins(), h->GetXaxis()->GetXmin(),h->GetXaxis()->GetXmax()); + if (!p->SameLimitsAndNBins(p->fYaxis, *(h->GetYaxis())) ) + p->fYaxis.Set(h->GetYaxis()->GetNbins(), h->GetYaxis()->GetXmin(),h->GetYaxis()->GetXmax()); + if (!p->SameLimitsAndNBins(p->fZaxis, *(h->GetZaxis())) ) + p->fZaxis.Set(h->GetZaxis()->GetNbins(), h->GetZaxis()->GetXmin(),h->GetZaxis()->GetXmax()); + } + firstNonEmptyHist = kFALSE; + } + + // this is executed the first time an histogram with limits is found + // to set some initial values on the new axis if (!initialLimitsFound) { initialLimitsFound = kTRUE; newXAxis.Set(h->GetXaxis()->GetNbins(), h->GetXaxis()->GetXmin(), @@ -454,15 +489,21 @@ void TProfileHelper::Scale(T* p, Double_t c1, Option_t *) } template <typename T> -void TProfileHelper::Sumw2(T* p) +void TProfileHelper::Sumw2(T* p, Bool_t flag) { - // Create structure to store sum of squares of weights per bin *-*-*-*-*-*-*-* + // Create/Delete structure to store sum of squares of weights per bin *-*-*-*-*-*-*-* // This is needed to compute the correct statistical quantities // of a profile filled with weights // // // This function is automatically called when the histogram is created // if the static function TH1::SetDefaultSumw2 has been called before. + + if (!flag) { + // clear array if existing or do nothing + if (p->fBinSumw2.fN > 0 ) p->fBinSumw2.Set(0); + return; + } if ( p->fBinSumw2.fN == p->fNcells) { if (!p->fgDefaultSumw2) diff --git a/hist/hist/src/TSVDUnfold.cxx b/hist/hist/src/TSVDUnfold.cxx index d9409807be24f..93838197f3081 100644 --- a/hist/hist/src/TSVDUnfold.cxx +++ b/hist/hist/src/TSVDUnfold.cxx @@ -39,7 +39,7 @@ Monte Carlo inputs: <li><tt>bini</tt>: reconstructed spectrum (TH1D, n bins) <li><tt>Adet</tt>: response matrix (TH2D, nxn bins) </ul> -Consider the unfolding of a measured spectrum <tt>bdat</tt> with covariance matrix <tt>Bcov</tt> (if not passed explicitely, a diagonal covariance will be built given the errors of <tt>bdat</tt>). The corresponding spectrum in the Monte Carlo is given by <tt>bini</tt>, with the true underlying spectrum given by <tt>xini</tt>. The detector response is described by <tt>Adet</tt>, with <tt>Adet</tt> filled with events (not probabilities) with the true observable on the y-axis and the reconstructed observable on the x-axis. +Consider the unfolding of a measured spectrum <tt>bdat</tt> with covariance matrix <tt>Bcov</tt> (if not passed explicitly, a diagonal covariance will be built given the errors of <tt>bdat</tt>). The corresponding spectrum in the Monte Carlo is given by <tt>bini</tt>, with the true underlying spectrum given by <tt>xini</tt>. The detector response is described by <tt>Adet</tt>, with <tt>Adet</tt> filled with events (not probabilities) with the true observable on the y-axis and the reconstructed observable on the x-axis. <p> The measured distribution can be unfolded for any combination of resolution, efficiency and acceptance effects, provided an appropriate definition of <tt>xini</tt> and <tt>Adet</tt>.<br><br> <p> diff --git a/hist/hist/src/TUnfoldSys.cxx b/hist/hist/src/TUnfoldSys.cxx index b1659bcdb98c3..be3a392d49d67 100644 --- a/hist/hist/src/TUnfoldSys.cxx +++ b/hist/hist/src/TUnfoldSys.cxx @@ -404,14 +404,15 @@ void TUnfoldSys::DoBackgroundSubtraction(void) { { TMapIter bgrErrCorrPtr(fBgrErrCorrIn); for(key=bgrErrCorrPtr.Next();key;key=bgrErrCorrPtr.Next()) { - const TMatrixD *bgrerrcorr=(const TMatrixD *) #if ROOT_VERSION_CODE >= ROOT_VERSION(5,20,00) - ((const TPair *)*bgrErrCorrPtr)->Value() + if (!*bgrErrCorrPtr) continue; + const TMatrixD *bgrerrcorr=(const TMatrixD *) + ((const TPair *)*bgrErrCorrPtr)->Value(); #else + const TMatrixD *bgrerrcorr=(const TMatrixD *) fBgrErrCorrIn->GetValue(((const TObjString *)key) - ->GetString()) + ->GetString()); #endif - ; for(Int_t yi=0;yi<ny;yi++) { if(!usedBin[yi]) continue; for(Int_t yj=0;yj<ny;yj++) { @@ -676,6 +677,7 @@ void TUnfoldSys::PrepareSysError(void) { for(key=(const TObjString *)sysErrIn.Next();key; key=(const TObjString *)sysErrIn.Next()) { #if ROOT_VERSION_CODE >= ROOT_VERSION(5,20,00) + if (!*sysErrIn) continue; const TMatrixDSparse *dsys= (const TMatrixDSparse *)((const TPair *)*sysErrIn)->Value(); #else @@ -1111,14 +1113,16 @@ Double_t TUnfoldSys::GetChi2Sys(void) { const TObject *key; // correlated su=ystematic errors for(key=sysErrPtr.Next();key;key=sysErrPtr.Next()) { - const TMatrixDSparse *delta=(TMatrixDSparse *) #if ROOT_VERSION_CODE >= ROOT_VERSION(5,20,00) - ((const TPair *)*sysErrPtr)->Value() + if (!*sysErrPtr) continue; + const TMatrixDSparse *delta=(TMatrixDSparse *) + ((const TPair *)*sysErrPtr)->Value(); #else + const TMatrixDSparse *delta=(TMatrixDSparse *) fDeltaCorrAx->GetValue(((const TObjString *)key) - ->GetString()) + ->GetString()); #endif - ; + TMatrixDSparse *emat=MultiplyMSparseMSparseTranspVector(delta,delta,0); AddMSparse(&emat_sum,1.0,emat); DeleteMatrix(&emat); diff --git a/hist/histpainter/inc/TPainter3dAlgorithms.h b/hist/histpainter/inc/TPainter3dAlgorithms.h index 0a1dce4a0cdbf..ae088a4949d9d 100644 --- a/hist/histpainter/inc/TPainter3dAlgorithms.h +++ b/hist/histpainter/inc/TPainter3dAlgorithms.h @@ -72,6 +72,10 @@ class TPainter3dAlgorithms : public TObject, public TAttLine, public TAttFill { Int_t *fColorDark; // Int_t fColorTop; // Int_t fColorBottom; // + Int_t *fEdgeColor; // + Int_t *fEdgeStyle; // + Int_t *fEdgeWidth; // + Int_t fEdgeIdx; // Int_t fMesh; //(=1 if mesh to draw, o otherwise) Int_t fNlines; // Int_t fLevelLine[200]; // @@ -168,6 +172,7 @@ class TPainter3dAlgorithms : public TObject, public TAttLine, public TAttFill { void SetSurfaceFunction(SurfaceFunc_t pointer); void SetColorDark(Color_t color, Int_t n=0); void SetColorMain(Color_t color, Int_t n=0); + void SetEdgeAtt(Color_t color=1, Style_t style=1, Width_t width=1, Int_t n=0); void SideVisibilityDecode(Double_t val, Int_t &iv1, Int_t &iv2, Int_t &iv3, Int_t &iv4, Int_t &iv5, Int_t &iv6, Int_t &ir); void SideVisibilityEncode(Int_t iopt, Double_t phi1, Double_t phi2, Double_t &val); void Spectrum(Int_t nl, Double_t fmin, Double_t fmax, Int_t ic, Int_t idc, Int_t &irep); diff --git a/hist/histpainter/inc/TPaletteAxis.h b/hist/histpainter/inc/TPaletteAxis.h index 257f46cef952e..e8121be3aa58d 100644 --- a/hist/histpainter/inc/TPaletteAxis.h +++ b/hist/histpainter/inc/TPaletteAxis.h @@ -46,6 +46,7 @@ class TPaletteAxis : public TPave { TPaletteAxis(const TPaletteAxis &palette); virtual ~TPaletteAxis(); void Copy(TObject &palette) const; + TPaletteAxis& operator=(const TPaletteAxis&); virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py); diff --git a/hist/histpainter/src/TGraph2DPainter.cxx b/hist/histpainter/src/TGraph2DPainter.cxx index 04bbd4c9eeaa9..e683acf711e56 100644 --- a/hist/histpainter/src/TGraph2DPainter.cxx +++ b/hist/histpainter/src/TGraph2DPainter.cxx @@ -589,8 +589,12 @@ void TGraph2DPainter::PaintLevels(Int_t *t,Double_t *x, Double_t *y, Double_t x0 = x[0] , x2 = x[0]; Double_t y0 = y[0] , y2 = y[0]; Double_t z0 = fZ[p0], z2 = fZ[p0]; - Double_t zmin = fZmin; - Double_t zmax = fZmax; + Double_t zmin = fGraph2D->GetMinimum(); + Double_t zmax = fGraph2D->GetMaximum(); + if (zmin==-1111 && zmax==-1111) { + zmin = fZmin; + zmax = fZmax; + } // Order along Z axis the points (xi,yi,zi) where "i" belongs to {0,1,2} // After this z0 < z1 < z2 @@ -773,7 +777,7 @@ void TGraph2DPainter::PaintPolyMarker(Option_t *option) Bool_t colors = opt.Contains("pcol"); Int_t ncolors = gStyle->GetNumberOfColors(); Int_t it, theColor; - + // Initialize the levels on the Z axis if (colors) { Int_t ndiv = gCurrentHist->GetContour(); @@ -783,7 +787,7 @@ void TGraph2DPainter::PaintPolyMarker(Option_t *option) } if (gCurrentHist->TestBit(TH1::kUserContour) == 0) gCurrentHist->SetContour(ndiv); } - + Double_t *xm = new Double_t[fNpoints]; Double_t *ym = new Double_t[fNpoints]; Double_t hzmin = gCurrentHist->GetMinimum(); diff --git a/hist/histpainter/src/TGraphPainter.cxx b/hist/histpainter/src/TGraphPainter.cxx index df0ac7c274c96..1e3dc7bb345d8 100644 --- a/hist/histpainter/src/TGraphPainter.cxx +++ b/hist/histpainter/src/TGraphPainter.cxx @@ -461,7 +461,7 @@ Begin_Html <a name="GP03c"></a><h4><u>TGraphBentErrors</u></h4> A <tt>TGraphBentErrors</tt> is like a <tt>TGraphAsymmErrors</tt>. -An extra parameter allows to bent the error bars to better see them +An extra parameter allows to bend the error bars to better see them when several graphs are drawn on the same plot. End_Html @@ -578,7 +578,7 @@ TGraphPainter::~TGraphPainter() void TGraphPainter::ComputeLogs(Int_t npoints, Int_t opt) { /* Begin_Html - Compute the lorarithm of global variables <tt>gxwork</tt> and <tt>gywork</tt> + Compute the logarithm of global variables <tt>gxwork</tt> and <tt>gywork</tt> according to the value of Options and put the results in the global variables <tt>gxworkl</tt> and <tt>gyworkl</tt>. <p> diff --git a/hist/histpainter/src/THistPainter.cxx b/hist/histpainter/src/THistPainter.cxx index 526a877292e72..53981608f850a 100644 --- a/hist/histpainter/src/THistPainter.cxx +++ b/hist/histpainter/src/THistPainter.cxx @@ -23,6 +23,7 @@ #include "TH2Poly.h" #include "TH3.h" #include "TProfile.h" +#include "TProfile2D.h" #include "THStack.h" #include "TF2.h" #include "TF3.h" @@ -258,6 +259,16 @@ Draw a lego plot using colors to show the cell contents When the option "0" is used with any LEGO option, the empty bins are not drawn. </td></tr> +<tr><th valign=top>"LEGO3"</th><td> +Draw a lego plot with hidden surface removal, like LEGO1 but the border lines +of each lego-bar are not drawn. +</td></tr> + +<tr><th valign=top>"LEGO4"</th><td> +Draw a lego plot with hidden surface removal, like LEGO1 but without the +shadow effect on each lego-bar. +</td></tr> + <tr><th valign=top>"TEXT"</th><td> Draw bin contents as text (format set via <tt>gStyle->SetPaintTextFormat</tt>). </td></tr> @@ -404,6 +415,10 @@ value. A sunken button is drawn for negative values a raised one for positive. A box is drawn for each cell with a color scale varying with contents. All the none empty bins are painted. Empty bins are not painted unless some bins have a negative content because in that case the null bins might be not empty. +<tt>TProfile2D</tt> histograms are handled differently because, for this type of 2D +histograms, it is possible to know if an empty bin has been filled or not. So even +if all the bins' contents are positive some empty bins might be painted. And vice versa, +if some bins have a negative content some empty bins might be not painted. </td></tr> <tr><th valign=top>"COLZ"</th><td> @@ -698,6 +713,7 @@ The "<tt>mode</tt>" has up to nine digits that can be set to on(1 or 2), off(0). s = 1; skewness printed s = 2; skewness and skewness error printed i = 1; integral of bins printed + i = 2; integral of bins with option "width" printed o = 1; number of overflows printed u = 1; number of underflows printed r = 1; rms printed @@ -744,13 +760,14 @@ To print only the name of the histogram do: of underflow/overflows and not just one single number. <p>The parameter mode can be any combination of the letters -<tt>kKsSiourRmMen</tt> +<tt>kKsSiIourRmMen</tt> <pre> k : kurtosis printed K : kurtosis and kurtosis error printed s : skewness printed S : skewness and skewness error printed i : integral of bins printed + I : integral of bins with option "width" printed o : number of overflows printed u : number of underflows printed r : rms printed @@ -823,6 +840,12 @@ and activate it again with: h->SetStats(1). </pre> +<p>Labels used in the statistics box ("Mean", "RMS", ...) can be changed from +<a href="http://root.cern.ch/download/doc/primer/ROOTPrimer.html#configure-root-at-start-up">$ROOTSYS/etc/system.rootrc</a> or +<a href="http://root.cern.ch/download/doc/primer/ROOTPrimer.html#configure-root-at-start-up">.rootrc</a> +(look for the string <tt>"Hist.Stats."</tt>). +</p> + <a name="HP08"></a><h3>Fit Statistics</h3> @@ -1162,10 +1185,10 @@ Begin_Macro(source) for (Int_t i=0;i<1000;i++) { double x,y; gRandom->Rannor(x,y); - if(x>0 && y>0) hb1->Fill(x,y,4); - if(x<0 && y<0) hb2->Fill(x,y,3); - if(x>0 && y<0) hb3->Fill(x,y,2); - if(x<0 && y>0) hb4->Fill(x,y,1); + if (x>0 && y>0) hb1->Fill(x,y,4); + if (x<0 && y<0) hb2->Fill(x,y,3); + if (x>0 && y<0) hb3->Fill(x,y,2); + if (x<0 && y>0) hb4->Fill(x,y,1); } hb1->SetFillColor(1); hb2->SetFillColor(2); @@ -1205,6 +1228,11 @@ is the color change between cells. some bins have a negative content because in that case the null bins might be not empty. +<p><tt>TProfile2D</tt> histograms are handled differently because, for this type of 2D +histograms, it is possible to know if an empty bin has been filled or not. So even +if all the bins' contents are positive some empty bins might be painted. And vice versa, +if some bins have a negative content some empty bins might be not painted. + <p>Combined with the option <tt>"COL"</tt>, the option <tt>"Z"</tt> allows to display the color palette defined by <tt>gStyle->SetPalette()</tt>. @@ -1573,6 +1601,16 @@ Draw a lego plot using the hidden surface removal technique. Draw a lego plot using colors to show the cell contents. </td></tr> +<tr><th valign=top>"LEGO3"</th><td> +Draw a lego plot with hidden surface removal, like LEGO1 but the border lines +of each lego-bar are not drawn. +</td></tr> + +<tr><th valign=top>"LEGO4"</th><td> +Draw a lego plot with hidden surface removal, like LEGO1 but without the +shadow effect on each lego-bar. +</td></tr> + <tr><th valign=top>"0"</th><td> When used with any LEGO option, the empty bins are not drawn. </td></tr> @@ -1580,6 +1618,8 @@ When used with any LEGO option, the empty bins are not drawn. </table> See the limitations with <a href="#HP060a">the option "SAME"</a>. +<p>Line attributes can be used in lego plots to change the edges' style. + <p>The following example shows a 2D histogram plotted with the option <tt>"LEGO"</tt>. The option <tt>"LEGO"</tt> draws a lego plot using the hidden lines removal technique. @@ -1617,7 +1657,6 @@ Begin_Macro(source) hlego1->Fill(px-1,5*py); hlego1->Fill(2+0.5*px,2*py-10.,0.1); } - gStyle->SetPalette(1); hlego1->SetFillColor(kYellow); hlego1->Draw("LEGO1 0"); return c2; @@ -1625,6 +1664,30 @@ Begin_Macro(source) End_Macro Begin_Html +<p>The following example shows a 2D histogram plotted with the option +<tt>"LEGO3"</tt>. Like the option <tt>"LEGO1"</tt>, the option <tt>"LEGO3"</tt> +draws a lego plot using the hidden surface removal technique but doesn't draw +the border lines of each individual lego-bar. This is very useful for histograms +having many bins. With such histograms the option <tt>"LEGO1"</tt> gives a black +image because of the border lines. This option also works with stacked legos. +End_Html +Begin_Macro(source) +{ + TCanvas *c2 = new TCanvas("c2","c2",600,400); + TH2F *hlego3 = new TH2F("hlego3","Option LEGO3 example",40,-4,4,40,-20,20); + Float_t px, py; + for (Int_t i = 0; i < 25000; i++) { + gRandom->Rannor(px,py); + hlego3->Fill(px-1,5*py); + hlego3->Fill(2+0.5*px,2*py-10.,0.1); + } + hlego3->SetFillColor(kRed); + hlego3->Draw("LEGO3"); + return c2; + } +End_Macro +Begin_Html + <p>The following example shows a 2D histogram plotted with the option <tt>"LEGO2"</tt>. The option <tt>"LEGO2"</tt> draws a lego plot using colors to show the cell contents. Combined with the option <tt>"LEGO2"</tt>, the option @@ -1929,12 +1992,12 @@ Begin_Macro(source) hlcc->Fill(2+0.5*px,2*py-10.,0.1); } hlcc->SetFillColor(kYellow); - c3->cd(1) ; hlcc->Draw("LEGO1 CYL"); - c3->cd(2) ; TH2F *hlpc = hlcc->DrawClone("LEGO1 POL"); + c3->cd(1); hlcc->Draw("LEGO1 CYL"); + c3->cd(2); TH2F *hlpc = hlcc->DrawClone("LEGO1 POL"); hlpc->SetTitle("Polar coordinates"); - c3->cd(3) ; TH2F *hlsc = hlcc->DrawClone("LEGO1 SPH"); + c3->cd(3); TH2F *hlsc = hlcc->DrawClone("LEGO1 SPH"); hlsc->SetTitle("Spherical coordinates"); - c3->cd(4) ; TH2F *hlprpc = hlcc->DrawClone("LEGO1 PSR"); + c3->cd(4); TH2F *hlprpc = hlcc->DrawClone("LEGO1 PSR"); hlprpc->SetTitle("PseudoRapidity/Phi coordinates"); return c3; } @@ -1957,12 +2020,12 @@ Begin_Macro(source) hscc->Fill(2+0.5*px,2*py-10.,0.1); } gStyle->SetPalette(1); - c4->cd(1) ; hscc->Draw("SURF1 CYL"); - c4->cd(2) ; TH2F *hspc = hscc->DrawClone("SURF1 POL"); + c4->cd(1); hscc->Draw("SURF1 CYL"); + c4->cd(2); TH2F *hspc = hscc->DrawClone("SURF1 POL"); hspc->SetTitle("Polar coordinates"); - c4->cd(3) ; TH2F *hssc = hscc->DrawClone("SURF1 SPH"); + c4->cd(3); TH2F *hssc = hscc->DrawClone("SURF1 SPH"); hssc->SetTitle("Spherical coordinates"); - c4->cd(4) ; TH2F *hsprpc = hscc->DrawClone("SURF1 PSR"); + c4->cd(4); TH2F *hsprpc = hscc->DrawClone("SURF1 PSR"); hsprpc->SetTitle("PseudoRapidity/Phi coordinates"); return c4; } @@ -2123,10 +2186,10 @@ Begin_Macro(source) Double_t x2[] = {0, -1, -1, 0}; Double_t y2[] = {0, 0, -1, 3}; Double_t x3[] = {4, 3, 0, 1, 2.4}; - Double_t y3[] = {4, 3.7, 1, 4.7, 3.5}; + Double_t y3[] = {4, 3.7, 1, 3.7, 2.5}; h2p->AddBin(3, x1, y1); h2p->AddBin(4, x2, y2); - h2p->AddBin(4, x3, y3); + h2p->AddBin(5, x3, y3); h2p->Fill(0.1, 0.01, 3); h2p->Fill(-0.5, -0.5, 7); h2p->Fill(-0.7, -0.5, 1); @@ -2746,6 +2809,7 @@ static TString gStringRMSZ; static TString gStringUnderflow; static TString gStringOverflow; static TString gStringIntegral; +static TString gStringIntegralBinWidth; static TString gStringSkewness; static TString gStringSkewnessX; static TString gStringSkewnessY; @@ -2784,26 +2848,27 @@ THistPainter::THistPainter() fCutsOpt[i] = 0; } - gStringEntries = gEnv->GetValue("Hist.Stats.Entries", "Entries"); - gStringMean = gEnv->GetValue("Hist.Stats.Mean", "Mean"); - gStringMeanX = gEnv->GetValue("Hist.Stats.MeanX", "Mean x"); - gStringMeanY = gEnv->GetValue("Hist.Stats.MeanY", "Mean y"); - gStringMeanZ = gEnv->GetValue("Hist.Stats.MeanZ", "Mean z"); - gStringRMS = gEnv->GetValue("Hist.Stats.RMS", "RMS"); - gStringRMSX = gEnv->GetValue("Hist.Stats.RMSX", "RMS x"); - gStringRMSY = gEnv->GetValue("Hist.Stats.RMSY", "RMS y"); - gStringRMSZ = gEnv->GetValue("Hist.Stats.RMSZ", "RMS z"); - gStringUnderflow = gEnv->GetValue("Hist.Stats.Underflow", "Underflow"); - gStringOverflow = gEnv->GetValue("Hist.Stats.Overflow", "Overflow"); - gStringIntegral = gEnv->GetValue("Hist.Stats.Integral", "Integral"); - gStringSkewness = gEnv->GetValue("Hist.Stats.Skewness", "Skewness"); - gStringSkewnessX = gEnv->GetValue("Hist.Stats.SkewnessX", "Skewness x"); - gStringSkewnessY = gEnv->GetValue("Hist.Stats.SkewnessY", "Skewness y"); - gStringSkewnessZ = gEnv->GetValue("Hist.Stats.SkewnessZ", "Skewness z"); - gStringKurtosis = gEnv->GetValue("Hist.Stats.Kurtosis", "Kurtosis"); - gStringKurtosisX = gEnv->GetValue("Hist.Stats.KurtosisX", "Kurtosis x"); - gStringKurtosisY = gEnv->GetValue("Hist.Stats.KurtosisY", "Kurtosis y"); - gStringKurtosisZ = gEnv->GetValue("Hist.Stats.KurtosisZ", "Kurtosis z"); + gStringEntries = gEnv->GetValue("Hist.Stats.Entries", "Entries"); + gStringMean = gEnv->GetValue("Hist.Stats.Mean", "Mean"); + gStringMeanX = gEnv->GetValue("Hist.Stats.MeanX", "Mean x"); + gStringMeanY = gEnv->GetValue("Hist.Stats.MeanY", "Mean y"); + gStringMeanZ = gEnv->GetValue("Hist.Stats.MeanZ", "Mean z"); + gStringRMS = gEnv->GetValue("Hist.Stats.RMS", "RMS"); + gStringRMSX = gEnv->GetValue("Hist.Stats.RMSX", "RMS x"); + gStringRMSY = gEnv->GetValue("Hist.Stats.RMSY", "RMS y"); + gStringRMSZ = gEnv->GetValue("Hist.Stats.RMSZ", "RMS z"); + gStringUnderflow = gEnv->GetValue("Hist.Stats.Underflow", "Underflow"); + gStringOverflow = gEnv->GetValue("Hist.Stats.Overflow", "Overflow"); + gStringIntegral = gEnv->GetValue("Hist.Stats.Integral", "Integral"); + gStringIntegralBinWidth = gEnv->GetValue("Hist.Stats.IntegralBinWidth", "Integral(w)"); + gStringSkewness = gEnv->GetValue("Hist.Stats.Skewness", "Skewness"); + gStringSkewnessX = gEnv->GetValue("Hist.Stats.SkewnessX", "Skewness x"); + gStringSkewnessY = gEnv->GetValue("Hist.Stats.SkewnessY", "Skewness y"); + gStringSkewnessZ = gEnv->GetValue("Hist.Stats.SkewnessZ", "Skewness z"); + gStringKurtosis = gEnv->GetValue("Hist.Stats.Kurtosis", "Kurtosis"); + gStringKurtosisX = gEnv->GetValue("Hist.Stats.KurtosisX", "Kurtosis x"); + gStringKurtosisY = gEnv->GetValue("Hist.Stats.KurtosisY", "Kurtosis y"); + gStringKurtosisZ = gEnv->GetValue("Hist.Stats.KurtosisZ", "Kurtosis z"); } @@ -3133,6 +3198,7 @@ void THistPainter::ExecuteEvent(Int_t event, Int_t px, Int_t py) } } + //______________________________________________________________________________ TList *THistPainter::GetContourList(Double_t contour) const { @@ -3164,7 +3230,7 @@ char *THistPainter::GetObjectInfo(Int_t px, Int_t py) const End_html */ if (!gPad) return (char*)""; - static char info[100]; + static char info[200]; Double_t x = gPad->PadtoX(gPad->AbsPixeltoX(px)); Double_t y = gPad->PadtoY(gPad->AbsPixeltoY(py)); Double_t x1 = gPad->PadtoX(gPad->AbsPixeltoX(px+1)); @@ -3224,18 +3290,42 @@ char *THistPainter::GetObjectInfo(Int_t px, Int_t py) const } } if (fH->GetDimension() == 1) { - Double_t integ = 0; - for (Int_t bin=binmin;bin<=binx;bin++) {integ += fH->GetBinContent(bin);} - snprintf(info,100,"(x=%g, y=%g, binx=%d, binc=%g, Sum=%g)",x,y,binx,fH->GetBinContent(binx),integ); - } else { + if (fH->InheritsFrom(TProfile::Class())) { + TProfile *tp = (TProfile*)fH; + snprintf(info,200,"(x=%g, y=%g, binx=%d, binc=%g, bine=%g, binn=%d)", + x, y, binx, fH->GetBinContent(binx), fH->GetBinError(binx), + (Int_t) tp->GetBinEntries(binx)); + } + else { + Double_t integ = 0; + for (Int_t bin=binmin;bin<=binx;bin++) {integ += fH->GetBinContent(bin);} + snprintf(info,200,"(x=%g, y=%g, binx=%d, binc=%g, Sum=%g)", + x,y,binx,fH->GetBinContent(binx),integ); + } + } else if (fH->GetDimension() == 2) { if (fH->InheritsFrom(TH2Poly::Class())) { TH2Poly *th2 = (TH2Poly*)fH; biny = th2->FindBin(x,y); - snprintf(info,100,"%s (x=%g, y=%g, bin=%d, binc=%g)",th2->GetBinTitle(biny),x,y,biny,th2->GetBinContent(biny)); + snprintf(info,200,"%s (x=%g, y=%g, bin=%d, binc=%g)", + th2->GetBinTitle(biny),x,y,biny,th2->GetBinContent(biny)); + } + else if (fH->InheritsFrom(TProfile2D::Class())) { + TProfile2D *tp = (TProfile2D*)fH; + biny = fYaxis->FindFixBin(y); + Int_t bin = fH->GetBin(binx,biny); + snprintf(info,200,"(x=%g, y=%g, binx=%d, biny=%d, binc=%g, bine=%g, binn=%d)", + x, y, binx, biny, fH->GetBinContent(bin), + fH->GetBinError(bin), (Int_t) tp->GetBinEntries(bin)); } else { biny = fYaxis->FindFixBin(y); - snprintf(info,100,"(x=%g, y=%g, binx=%d, biny=%d, binc=%g)",x,y,binx,biny,fH->GetCellContent(binx,biny)); + snprintf(info,200,"(x=%g, y=%g, binx=%d, biny=%d, binc=%g bine=%g)", + x,y,binx,biny,fH->GetBinContent(binx,biny), + fH->GetBinError(binx,biny)); } + } else { + // 3d case: retrieving the x,y,z bin is not yet implemented + // print just the x,y info + snprintf(info,200,"(x=%g, y=%g)",x,y); } return info; } @@ -3290,6 +3380,7 @@ Int_t THistPainter::MakeChopt(Option_t *choptin) char chopt[128]; Int_t nch = strlen(choptin); strlcpy(chopt,choptin,128); + Int_t hdim = fH->GetDimension(); Hoption.Axis = Hoption.Bar = Hoption.Curve = Hoption.Error = 0; Hoption.Hist = Hoption.Line = Hoption.Mark = Hoption.Fill = 0; @@ -3315,10 +3406,10 @@ Int_t THistPainter::MakeChopt(Option_t *choptin) MakeCuts(chopt); for (Int_t i=0;i<nch;i++) chopt[i] = toupper(chopt[i]); - if (fH->GetDimension() > 1) Hoption.Scat = 1; + if (hdim > 1) Hoption.Scat = 1; if (!nch) Hoption.Hist = 1; if (fFunctions->First()) Hoption.Func = 2; - if (fH->GetSumw2N() && fH->GetDimension() == 1) Hoption.Error = 2; + if (fH->GetSumw2N() && hdim == 1) Hoption.Error = 2; l = strstr(chopt,"SPEC"); if (l) { @@ -3354,8 +3445,8 @@ Int_t THistPainter::MakeChopt(Option_t *choptin) Hoption.AxisPos += 1; strncpy(l," ",2); } - if((Hoption.AxisPos == 10 || Hoption.AxisPos == 1) && (nch == 2)) Hoption.Hist = 1; - if(Hoption.AxisPos == 11 && nch == 4) Hoption.Hist = 1; + if ((Hoption.AxisPos == 10 || Hoption.AxisPos == 1) && (nch == 2)) Hoption.Hist = 1; + if (Hoption.AxisPos == 11 && nch == 4) Hoption.Hist = 1; l = strstr(chopt,"SAMES"); if (l) { @@ -3382,6 +3473,8 @@ Int_t THistPainter::MakeChopt(Option_t *choptin) Hoption.Lego = 1; strncpy(l," ",4); if (l[4] == '1') { Hoption.Lego = 11; l[4] = ' '; } if (l[4] == '2') { Hoption.Lego = 12; l[4] = ' '; } + if (l[4] == '3') { Hoption.Lego = 13; l[4] = ' '; } + if (l[4] == '4') { Hoption.Lego = 14; l[4] = ' '; } l = strstr(chopt,"FB"); if (l) { Hoption.FrontBox = 0; strncpy(l," ",2); } l = strstr(chopt,"BB"); if (l) { Hoption.BackBox = 0; strncpy(l," ",2); } l = strstr(chopt,"0"); if (l) { Hoption.Zero = 1; strncpy(l," ",1); } @@ -3418,13 +3511,18 @@ Int_t THistPainter::MakeChopt(Option_t *choptin) l = strstr(chopt,"CONT"); if (l) { - Hoption.Scat = 0; - Hoption.Contour = 1; strncpy(l," ",4); - if (l[4] == '1') { Hoption.Contour = 11; l[4] = ' '; } - if (l[4] == '2') { Hoption.Contour = 12; l[4] = ' '; } - if (l[4] == '3') { Hoption.Contour = 13; l[4] = ' '; } - if (l[4] == '4') { Hoption.Contour = 14; l[4] = ' '; } - if (l[4] == '5') { Hoption.Contour = 15; l[4] = ' '; } + strncpy(l," ",4); + if (hdim>1) { + Hoption.Scat = 0; + Hoption.Contour = 1; + if (l[4] == '1') { Hoption.Contour = 11; l[4] = ' '; } + if (l[4] == '2') { Hoption.Contour = 12; l[4] = ' '; } + if (l[4] == '3') { Hoption.Contour = 13; l[4] = ' '; } + if (l[4] == '4') { Hoption.Contour = 14; l[4] = ' '; } + if (l[4] == '5') { Hoption.Contour = 15; l[4] = ' '; } + } else { + Hoption.Hist = 1; + } } l = strstr(chopt,"HBAR"); if (l) { @@ -3445,15 +3543,48 @@ Int_t THistPainter::MakeChopt(Option_t *choptin) if (l[3] == '4') { Hoption.Bar = 14; l[3] = ' '; } } - l = strstr(chopt,"ARR" ); if (l) { Hoption.Arrow = 1; strncpy(l," ", 3); Hoption.Scat = 0; } + l = strstr(chopt,"ARR" ); + if (l) { + strncpy(l," ", 3); + if (hdim>1) { + Hoption.Arrow = 1; + Hoption.Scat = 0; + } else { + Hoption.Hist = 1; + } + } l = strstr(chopt,"BOX" ); if (l) { - Hoption.Scat = 0; - Hoption.Box = 1; strncpy(l," ", 3); - if (l[3] == '1') { Hoption.Box = 11; l[3] = ' '; } + strncpy(l," ", 3); + if (hdim>1) { + Hoption.Scat = 0; + Hoption.Box = 1; + if (l[3] == '1') { Hoption.Box = 11; l[3] = ' '; } + } else { + Hoption.Hist = 1; + } + } + l = strstr(chopt,"COLZ"); + if (l) { + strncpy(l," ",4); + if (hdim>1) { + Hoption.Color = 2; + Hoption.Scat = 0; + Hoption.Zscale = 1; + } else { + Hoption.Hist = 1; + } + } + l = strstr(chopt,"COL" ); + if (l) { + strncpy(l," ", 3); + if (hdim>1) { + Hoption.Color = 1; + Hoption.Scat = 0; + } else { + Hoption.Hist = 1; + } } - l = strstr(chopt,"COLZ"); if (l) { Hoption.Color = 2; strncpy(l," ",4); Hoption.Scat = 0; Hoption.Zscale = 1;} - l = strstr(chopt,"COL" ); if (l) { Hoption.Color = 1; strncpy(l," ", 3); Hoption.Scat = 0; } l = strstr(chopt,"CHAR"); if (l) { Hoption.Char = 1; strncpy(l," ",4); Hoption.Scat = 0; } l = strstr(chopt,"FUNC"); if (l) { Hoption.Func = 2; strncpy(l," ",4); Hoption.Hist = 0; } l = strstr(chopt,"HIST"); if (l) { Hoption.Hist = 2; strncpy(l," ",4); Hoption.Func = 0; Hoption.Error = 0;} @@ -3529,7 +3660,7 @@ Int_t THistPainter::MakeChopt(Option_t *choptin) } if (strstr(chopt,"E")) { - if (fH->GetDimension() == 1) { + if (hdim == 1) { Hoption.Error = 1; if (strstr(chopt,"E0")) Hoption.Error = 10; if (strstr(chopt,"E1")) Hoption.Error = 11; @@ -3596,7 +3727,7 @@ Int_t THistPainter::MakeCuts(char *choptin) *right = 0; char *comma, *minus; Int_t i; - while(1) { + while (1) { comma = strchr(cuts,','); if (comma) *comma = 0; minus = strchr(cuts,'-'); @@ -3847,18 +3978,18 @@ void THistPainter::PaintArrows(Option_t *) xstep = fXaxis->GetBinWidth(i); if (!IsInside(xk+0.5*xstep,yk+0.5*ystep)) continue; if (i == Hparam.xfirst) { - dx = fH->GetCellContent(i+1, j) - fH->GetCellContent(i, j); + dx = fH->GetBinContent(i+1, j) - fH->GetBinContent(i, j); } else if (i == Hparam.xlast) { - dx = fH->GetCellContent(i, j) - fH->GetCellContent(i-1, j); + dx = fH->GetBinContent(i, j) - fH->GetBinContent(i-1, j); } else { - dx = 0.5*(fH->GetCellContent(i+1, j) - fH->GetCellContent(i-1, j)); + dx = 0.5*(fH->GetBinContent(i+1, j) - fH->GetBinContent(i-1, j)); } if (j == Hparam.yfirst) { - dy = fH->GetCellContent(i, j+1) - fH->GetCellContent(i, j); + dy = fH->GetBinContent(i, j+1) - fH->GetBinContent(i, j); } else if (j == Hparam.ylast) { - dy = fH->GetCellContent(i, j) - fH->GetCellContent(i, j-1); + dy = fH->GetBinContent(i, j) - fH->GetBinContent(i, j-1); } else { - dy = 0.5*(fH->GetCellContent(i, j+1) - fH->GetCellContent(i, j-1)); + dy = 0.5*(fH->GetBinContent(i, j+1) - fH->GetBinContent(i, j-1)); } if (id == 1) { dn = TMath::Max(dn, TMath::Abs(dx)); @@ -4552,6 +4683,7 @@ void THistPainter::PaintColorLevels(Option_t *) Double_t scale = ndivz/dz; Int_t color; + TProfile2D* prof2d = dynamic_cast<TProfile2D*>(fH); for (Int_t j=Hparam.yfirst; j<=Hparam.ylast;j++) { yk = fYaxis->GetBinLowEdge(j); ystep = fYaxis->GetBinWidth(j); @@ -4562,7 +4694,17 @@ void THistPainter::PaintColorLevels(Option_t *) if (Hoption.System == kPOLAR && xk<0) xk= 2*TMath::Pi()+xk; if (!IsInside(xk+0.5*xstep,yk+0.5*ystep)) continue; z = fH->GetBinContent(bin); - if (z == 0 && (zmin >= 0 || Hoption.Logz)) continue; // don't draw the empty bins for histograms with positive content + // if fH is a profile histogram do not draw empty bins + if (prof2d) { + const Double_t binEntries = prof2d->GetBinEntries(bin); + if (binEntries == 0) + continue; + } else { + // don't draw the empty bins for non-profile histograms + // with positive content + if (z == 0 && (zmin >= 0 || Hoption.Logz)) continue; + } + if (Hoption.Logz) { if (z > 0) z = TMath::Log10(z); else z = zmin; @@ -5236,7 +5378,7 @@ void THistPainter::PaintErrors(Option_t *) if ((yi3 < yi1 - s2y) && (yi3 < ymax)) gPad->PaintLine(xi3,yi3,xi4,TMath::Min(yi1 - s2y,ymax)); if ((yi1 + s2y < yi4) && (yi4 > ymin)) gPad->PaintLine(xi3,TMath::Max(yi1 + s2y, ymin),xi4,yi4); // don't duplicate the horizontal line - if (Hoption.Hist != 2){ + if (Hoption.Hist != 2) { if (yi1<ymax && yi1>ymin) { if (xi1 < xi3 - s2x) gPad->PaintLine(xi1,yi1,xi3 - s2x,yi2); if (xi3 + s2x < xi2) gPad->PaintLine(xi3 + s2x,yi1,xi2,yi2); @@ -5247,7 +5389,7 @@ void THistPainter::PaintErrors(Option_t *) if ((yi3 < yi1) && (yi3 < ymax)) gPad->PaintLine(xi3,yi3,xi4,TMath::Min(yi1,ymax)); if ((yi1 < yi4) && (yi4 > ymin)) gPad->PaintLine(xi3,TMath::Max(yi1,ymin),xi4,yi4); // don't duplicate the horizontal line - if (Hoption.Hist != 2){ + if (Hoption.Hist != 2) { if (yi1<ymax && yi1>ymin) { if (xi1 < xi3) gPad->PaintLine(xi1,yi1,xi3,yi2); if (xi3 < xi2) gPad->PaintLine(xi3,yi1,xi2,yi2); @@ -5296,7 +5438,7 @@ void THistPainter::PaintErrors(Option_t *) // 2*npoints. In such cases the array xline and yline must be arranged // before being plotted. The next loop does that. if (if2 > npoints) { - for(i=1; i<if1 ;i++) { + for (i=1; i<if1; i++) { xline[if1-2+i] = xline[if2-1+i]; yline[if1-2+i] = yline[if2-1+i]; } @@ -5367,7 +5509,7 @@ void THistPainter::Paint2DErrors(Option_t *) Double_t temp1[3],temp2[3]; Double_t xyerror; if (Hoption.Error == 110) { - xyerror = 0 ; + xyerror = 0; } else { xyerror = gStyle->GetErrorX(); } @@ -5595,7 +5737,7 @@ void THistPainter::PaintHist(Option_t *) if (Hoption.Logy) yb = TMath::Log10(TMath::Max(c1,.1*logymin)); else yb = c1; } - if(!Hoption.Line){ + if (!Hoption.Line) { yb = TMath::Max(yb, ymin); yb = TMath::Min(yb, ymax); } @@ -5643,10 +5785,8 @@ void THistPainter::PaintHist(Option_t *) chopth[8] = 'N'; } - // coverity [Calling risky function] - if (Hoption.Fill == 2) strlcat(chopth,"2",17); - // coverity [Calling risky function] - if (Hoption.HighRes != 0) strlcat(chopth,"9",17); + if (Hoption.Fill == 2) chopth[13] = '2'; + if (Hoption.HighRes != 0) chopth[14] = '9'; // Option LOGX @@ -5712,6 +5852,9 @@ void THistPainter::PaintH3(Option_t *option) cmd = Form("TPolyMarker3D::PaintH3((TH1 *)0x%lx,\"%s\");",(Long_t)fH,option); } + if (strstr(opt,"fb")) Hoption.FrontBox = 0; + if (strstr(opt,"bb")) Hoption.BackBox = 0; + TView *view = gPad->GetView(); if (!view) return; Double_t thedeg = 90 - gPad->GetTheta(); @@ -5727,10 +5870,10 @@ void THistPainter::PaintH3(Option_t *option) // Draw axis view->SetOutlineToCube(); TSeqCollection *ol = view->GetOutline(); - if (ol) ol->Paint(option); + if (ol && Hoption.BackBox && Hoption.FrontBox) ol->Paint(option); Hoption.System = kCARTESIAN; TGaxis *axis = new TGaxis(); - PaintLegoAxis(axis,90); + if (!Hoption.Axis && !Hoption.Same) PaintLegoAxis(axis, 90); delete axis; // Draw palette. In case of 4D plot with TTree::Draw() the palette should @@ -5775,6 +5918,7 @@ Int_t THistPainter::PaintInit() if (fH->GetDimension() > 1 || Hoption.Lego || Hoption.Surf) return 1; + Int_t i; static const char *where = "PaintInit"; Double_t yMARGIN = gStyle->GetHistTopMargin(); Int_t maximum = 0; @@ -5795,18 +5939,28 @@ Int_t THistPainter::PaintInit() // if log scale in X, replace xmin,max by the log if (Hoption.Logx) { + if (Hparam.xmax<=0) { + Error(where, "cannot set X axis to log scale"); + return 0; + } if (Hparam.xlowedge <=0 ) { if (Hoption.Same) { Hparam.xlowedge = TMath::Power(10, gPad->GetUxmin()); } else { - Hparam.xlowedge = 0.1*Hparam.xbinsize; + for (i=first; i<=last; i++) { + Double_t binLow = fXaxis->GetBinLowEdge(i); + if (binLow>0) { + Hparam.xlowedge = binLow; + break; + } + } + if (Hparam.xlowedge<=0) { + Error(where, "cannot set X axis to log scale"); + return 0; + } } Hparam.xmin = Hparam.xlowedge; } - if (Hparam.xmin <=0 || Hparam.xmax <=0) { - Error(where, "cannot set X axis to log scale"); - return 0; - } Hparam.xfirst= fXaxis->FindFixBin(Hparam.xmin); Hparam.xlast = fXaxis->FindFixBin(Hparam.xmax); Hparam.xmin = TMath::Log10(Hparam.xmin); @@ -5822,7 +5976,6 @@ Int_t THistPainter::PaintInit() Double_t c1, e1; Double_t xv[1]; Double_t fval; - Int_t i; TObject *f; TF1 *f1; Double_t allchan = 0; @@ -5920,7 +6073,7 @@ Int_t THistPainter::PaintInit() } // In some cases, mainly because of precision issues, ymin and ymax could almost equal. - if(TMath::AreEqualRel(ymin,ymax,1E-15)) { + if (TMath::AreEqualRel(ymin,ymax,1E-15)) { ymin = ymin*(1-1E-14); ymax = ymax*(1+1E-14); } @@ -6189,9 +6342,9 @@ void THistPainter::PaintH3Iso() Double_t *y = new Double_t[ny]; Double_t *z = new Double_t[nz]; - for ( i=0 ; i<nx ; i++) x[i] = xaxis->GetBinCenter(i+1); - for ( i=0 ; i<ny ; i++) y[i] = yaxis->GetBinCenter(i+1); - for ( i=0 ; i<nz ; i++) z[i] = zaxis->GetBinCenter(i+1); + for (i=0; i<nx; i++) x[i] = xaxis->GetBinCenter(i+1); + for (i=0; i<ny; i++) y[i] = yaxis->GetBinCenter(i+1); + for (i=0; i<nz; i++) z[i] = zaxis->GetBinCenter(i+1); fXbuf[0] = xaxis->GetBinLowEdge(xaxis->GetFirst()); fYbuf[0] = xaxis->GetBinUpEdge(xaxis->GetLast()); @@ -6341,6 +6494,22 @@ void THistPainter::PaintLego(Option_t *) fLego = new TPainter3dAlgorithms(fXbuf, fYbuf, Hoption.System); + Int_t nids = -1; + TH1 * hid = NULL; + Color_t colormain = -1, colordark = -1; + Bool_t drawShadowsInLego1 = kTRUE; + + // LEGO3 is like LEGO1 except that the black lines around each lego are not drawn. + if (Hoption.Lego == 13) { + Hoption.Lego = 11; + fLego->SetMesh(0); + } + // LEGO4 is like LEGO1 except no shadows are drawn. + if (Hoption.Lego == 14) { + Hoption.Lego = 11; + drawShadowsInLego1 = kFALSE; + } + // Create axis object TGaxis *axis = new TGaxis(); @@ -6354,23 +6523,29 @@ void THistPainter::PaintLego(Option_t *) Int_t ndivz = TMath::Abs(ndiv); if (fH->TestBit(TH1::kUserContour) == 0) fH->SetContour(ndiv); - // Initialize colors for the lighting model (option Lego1 only) - if (Hoption.Lego == 1) { - Color_t colormain = fH->GetLineColor(); - fLego->SetColorMain(colormain,0); + // Initialize colors + if (!fStack) { + fLego->SetEdgeAtt(fH->GetLineColor(),fH->GetLineStyle(),fH->GetLineWidth(),0); + } else { + for (Int_t id=0;id<=fStack->GetSize();id++) { + hid = (TH1*)fStack->At((id==0)?id:id-1); + fLego->SetEdgeAtt(hid->GetLineColor(),hid->GetLineStyle(),hid->GetLineWidth(),id); + } } + if (Hoption.Lego == 11) { - Int_t nids = 1; + nids = 1; if (fStack) nids = fStack->GetSize(); - TH1 *hid = fH; + hid = fH; for (Int_t id=0;id<=nids;id++) { if (id > 0 && fStack) hid = (TH1*)fStack->At(id-1); - Color_t colormain = hid->GetFillColor(); + colormain = hid->GetFillColor(); if (colormain == 1) colormain = 17; //avoid drawing with black - Color_t colordark = TColor::GetColorDark(colormain); + if (drawShadowsInLego1) colordark = TColor::GetColorDark(colormain); + else colordark = colormain; fLego->SetColorMain(colormain,id); fLego->SetColorDark(colordark,id); - if (id == 0) fLego->SetColorMain(colormain,-1); // Set Bottom color + if (id <= 1) fLego->SetColorMain(colormain,-1); // Set Bottom color if (id == nids) fLego->SetColorMain(colormain,99); // Set Top color } } @@ -6389,7 +6564,7 @@ void THistPainter::PaintLego(Option_t *) Double_t psideg = view->GetPsi(); view->SetView(phideg, thedeg, psideg, irep); - fLego->SetLineColor(fH->GetLineColor()); + fLego->SetLineColor(kBlack); /// zgrid color for lego1 & lego2 fLego->SetFillStyle(fH->GetFillStyle()); // Set color/style for back box @@ -6448,7 +6623,6 @@ void THistPainter::PaintLego(Option_t *) } if (Hoption.Lego == 1 || Hoption.Lego == 11) { - fLego->SetLineColor(1); if (Hoption.System == kCARTESIAN && Hoption.BackBox) { fLego->SetDrawFace(&TPainter3dAlgorithms::DrawFaceMove1); fLego->BackBox(90); @@ -6502,10 +6676,10 @@ void THistPainter::PaintLegoAxis(TGaxis *axis, Double_t ang) r[2] = 0; view->WCtoNDC(r, x2); gPad->PaintLine(x1[0],x1[1],x2[0],x2[1]); - return ; + return; } - if (Hoption.System != kCARTESIAN) return ; + if (Hoption.System != kCARTESIAN) return; rad = TMath::ATan(1.) * 4. /180.; cosa = TMath::Cos(ang*rad); @@ -6655,7 +6829,7 @@ void THistPainter::PaintLegoAxis(TGaxis *axis, Double_t ang) axis->PaintAxis(z1[0], z1[1], z2[0], z2[1], bmin, bmax, ndivz, chopaz); } - fH->SetLineStyle(1); + //fH->SetLineStyle(1); /// otherwise fEdgeStyle[i] gets overwritten! } @@ -6692,7 +6866,7 @@ void THistPainter::PaintPalette() Double_t xmax = gPad->PadtoX(xup + xr); if (xmax > x2) xmax = gPad->PadtoX(gPad->GetX2()-0.01*xr); palette = new TPaletteAxis(xmin,ymin,xmax,ymax,fH); - fFunctions->Add(palette); + fFunctions->AddFirst(palette); palette->Paint(); } } @@ -6790,11 +6964,11 @@ void THistPainter::PaintScatterPlot(Option_t *option) } fXbuf[marker] = (random.Rndm(loop)*xstep) + xk; fYbuf[marker] = (random.Rndm(loop)*ystep) + yk; - if (Hoption.Logx){ + if (Hoption.Logx) { if (fXbuf[marker] > 0) fXbuf[marker] = TMath::Log10(fXbuf[marker]); else break; } - if (Hoption.Logy){ + if (Hoption.Logy) { if (fYbuf[marker] > 0) fYbuf[marker] = TMath::Log10(fYbuf[marker]); else break; } @@ -6986,7 +7160,7 @@ void THistPainter::PaintStat(Int_t dostat, TF1 *fit) snprintf(t,100,textstats,fH->GetRMS(1),fH->GetRMSError(1)); } stats->AddText(t); - if(fH->InheritsFrom(TProfile::Class())) { + if (fH->InheritsFrom(TProfile::Class())) { if (print_rms == 1) { snprintf(textstats,50,"%s = %s%s",gStringRMSY.Data(),"%",stats->GetStatFormat()); snprintf(t,100,textstats,fH->GetRMS(2)); @@ -7009,8 +7183,13 @@ void THistPainter::PaintStat(Int_t dostat, TF1 *fit) stats->AddText(t); } if (print_integral) { - snprintf(textstats,50,"%s = %s%s",gStringIntegral.Data(),"%",stats->GetStatFormat()); - snprintf(t,100,textstats,fH->Integral()); + if (print_integral == 1) { + snprintf(textstats,50,"%s = %s%s",gStringIntegral.Data(),"%",stats->GetStatFormat()); + snprintf(t,100,textstats,fH->Integral()); + } else { + snprintf(textstats,50,"%s = %s%s",gStringIntegralBinWidth.Data(),"%",stats->GetStatFormat()); + snprintf(t,100,textstats,fH->Integral("width")); + } stats->AddText(t); } if (print_skew) { @@ -7049,17 +7228,21 @@ void THistPainter::PaintStat(Int_t dostat, TF1 *fit) } if (print_fval || print_ferrors) { Double_t parmin,parmax; + Int_t a; for (Int_t ipar=0;ipar<fit->GetNpar();ipar++) { fit->GetParLimits(ipar,parmin,parmax); if (print_fval < 2 && parmin*parmax != 0 && parmin >= parmax) continue; + snprintf(t,100,"%-8s ",fit->GetParName(ipar)); + a = strlen(t); + if (a>50) a = 50; if (print_ferrors) { - snprintf(textstats,50,"%-8s = %s%s #pm %s ",fit->GetParName(ipar), "%",stats->GetFitFormat(), + snprintf(textstats,50,"= %s%s #pm %s ", "%",stats->GetFitFormat(), GetBestFormat(fit->GetParameter(ipar), fit->GetParError(ipar), stats->GetFitFormat())); - snprintf(t,100,textstats,(Float_t)fit->GetParameter(ipar) + snprintf(&t[a],100,textstats,(Float_t)fit->GetParameter(ipar) ,(Float_t)fit->GetParError(ipar)); } else { - snprintf(textstats,50,"%-8s = %s%s ",fit->GetParName(ipar),"%",stats->GetFitFormat()); - snprintf(t,100,textstats,(Float_t)fit->GetParameter(ipar)); + snprintf(textstats,50,"= %s%s ","%",stats->GetFitFormat()); + snprintf(&t[a],100,textstats,(Float_t)fit->GetParameter(ipar)); } t[63] = 0; stats->AddText(t); @@ -7245,15 +7428,22 @@ void THistPainter::PaintStat2(Int_t dostat, TF1 *fit) //get 3*3 under/overflows for 2d hist Double_t unov[9]; - unov[0] = h2->Integral(0,h2->GetXaxis()->GetFirst()-1,h2->GetYaxis()->GetLast()+1,h2->GetYaxis()->GetNbins()+1); - unov[1] = h2->Integral(h2->GetXaxis()->GetFirst(),h2->GetXaxis()->GetLast(),h2->GetYaxis()->GetLast()+1,h2->GetYaxis()->GetNbins()+1); - unov[2] = h2->Integral(h2->GetXaxis()->GetLast()+1,h2->GetXaxis()->GetNbins()+1,h2->GetYaxis()->GetLast()+1,h2->GetYaxis()->GetNbins()+1); - unov[3] = h2->Integral(0,h2->GetXaxis()->GetFirst()-1,h2->GetYaxis()->GetFirst(),h2->GetYaxis()->GetLast()); - unov[4] = h2->Integral(h2->GetXaxis()->GetFirst(),h2->GetXaxis()->GetLast(),h2->GetYaxis()->GetFirst(),h2->GetYaxis()->GetLast()); - unov[5] = h2->Integral(h2->GetXaxis()->GetLast()+1,h2->GetXaxis()->GetNbins()+1,h2->GetYaxis()->GetFirst(),h2->GetYaxis()->GetLast()); - unov[6] = h2->Integral(0,h2->GetXaxis()->GetFirst()-1,0,h2->GetYaxis()->GetFirst()-1); - unov[7] = h2->Integral(h2->GetXaxis()->GetFirst(),h2->GetXaxis()->GetLast(),0,h2->GetYaxis()->GetFirst()-1); - unov[8] = h2->Integral(h2->GetXaxis()->GetLast()+1,h2->GetXaxis()->GetNbins()+1,0,h2->GetYaxis()->GetFirst()-1); + Int_t cellsX = h2->GetXaxis()->GetNbins() + 1; + Int_t cellsY = h2->GetYaxis()->GetNbins() + 1; + Int_t firstX = std::max(1, h2->GetXaxis()->GetFirst()); + Int_t firstY = std::max(1, h2->GetYaxis()->GetFirst()); + Int_t lastX = std::min(h2->GetXaxis()->GetLast(), h2->GetXaxis()->GetNbins()); + Int_t lastY = std::min(h2->GetYaxis()->GetLast(), h2->GetYaxis()->GetNbins()); + + unov[0] = h2->Integral( 0, firstX-1, lastY+1, cellsY ); + unov[1] = h2->Integral(firstX , lastX , lastY+1, cellsY ); + unov[2] = h2->Integral(lastX+1, cellsX , lastY+1, cellsY ); + unov[3] = h2->Integral( 0, firstX-1, firstY , lastY ); + unov[4] = h2->Integral(firstX , lastX , firstY , lastY ); + unov[5] = h2->Integral(lastX+1, cellsX , firstY , lastY ); + unov[6] = h2->Integral( 0, firstX-1, 0, firstY-1); + unov[7] = h2->Integral(firstX, lastX, 0, firstY-1); + unov[8] = h2->Integral(lastX+1, cellsX , 0, firstY-1); snprintf(t, 100," %7d|%7d|%7d\n", (Int_t)unov[0], (Int_t)unov[1], (Int_t)unov[2]); stats->AddText(t); @@ -7275,7 +7465,7 @@ void THistPainter::PaintStat2(Int_t dostat, TF1 *fit) snprintf(t,100,"%-8s = %5.4g #pm %5.4g ",fit->GetParName(ipar) ,(Float_t)fit->GetParameter(ipar) ,(Float_t)fit->GetParError(ipar)); - t[32] = 0; + t[63] = 0; stats->AddText(t); } } @@ -7597,7 +7787,7 @@ void THistPainter::PaintSurface(Option_t *) } fLego = new TPainter3dAlgorithms(fXbuf, fYbuf, Hoption.System); - fLego->SetLineColor(fH->GetLineColor()); + fLego->SetEdgeAtt(fH->GetLineColor(),fH->GetLineStyle(),fH->GetLineWidth(),0); fLego->SetFillColor(fH->GetFillColor()); // Create axis object @@ -7674,7 +7864,6 @@ void THistPainter::PaintSurface(Option_t *) if (Hoption.Surf == 11 || Hoption.Surf == 12 || Hoption.Surf == 14 || Hoption.Surf == 17) { fLego->DefineGridLevels(fZaxis->GetNdivisions()%100); - fLego->SetLineColor(1); if (Hoption.System == kCARTESIAN && Hoption.BackBox) { fLego->SetDrawFace(&TPainter3dAlgorithms::DrawFaceMove1); fLego->BackBox(90); @@ -7759,7 +7948,6 @@ void THistPainter::PaintSurface(Option_t *) if ((!Hoption.Same) && (Hoption.Surf == 1 || Hoption.Surf == 13 || Hoption.Surf == 16)) { - fLego->SetLineColor(1); if (Hoption.System == kCARTESIAN && Hoption.BackBox) { fLego->SetDrawFace(&TPainter3dAlgorithms::DrawFaceMove1); fLego->BackBox(90); @@ -8870,10 +9058,10 @@ Int_t THistPainter::TableInit() Double_t allchan = 0; for (Int_t j=Hparam.yfirst; j<=Hparam.ylast;j++) { for (Int_t i=Hparam.xfirst; i<=Hparam.xlast;i++) { - c1 = fH->GetCellContent(i,j); + c1 = fH->GetBinContent(i,j); zmax = TMath::Max(zmax,c1); if (Hoption.Error) { - e1 = fH->GetCellError(i,j); + e1 = fH->GetBinError(i,j); zmax = TMath::Max(zmax,c1+e1); } zmin = TMath::Min(zmin,c1); @@ -9097,7 +9285,8 @@ void THistPainter::ShowProjectionX(Int_t /*px*/, Int_t py) c->SetLogx(padsav->GetLogx()); // Draw slice corresponding to mouse position - TH1D *hp = ((TH2*)fH)->ProjectionX("slice_px", biny1, biny2); + TString prjName = TString::Format("slice_px_of_%s",fH->GetName()); + TH1D *hp = ((TH2*)fH)->ProjectionX(prjName, biny1, biny2); if (hp) { hp->SetFillColor(38); if (biny1 == biny2) hp->SetTitle(Form("ProjectionX of biny=%d", biny1)); @@ -9145,7 +9334,7 @@ void THistPainter::ShowProjectionY(Int_t px, Int_t /*py*/) TVirtualPad *padsav = gPad; TVirtualPad *c = (TVirtualPad*)gROOT->GetListOfCanvases()->FindObject(Form("c_%lx_projection_%d", (ULong_t)fH, fShowProjection)); - if(c) { + if (c) { c->Clear(); } else { fShowProjection = 0; @@ -9158,7 +9347,8 @@ void THistPainter::ShowProjectionY(Int_t px, Int_t /*py*/) c->SetLogx(padsav->GetLogy()); // Draw slice corresponding to mouse position - TH1D *hp = ((TH2*)fH)->ProjectionY("slice_py", binx1, binx2); + TString prjName = TString::Format("slice_py_of_%s",fH->GetName()); + TH1D *hp = ((TH2*)fH)->ProjectionY(prjName, binx1, binx2); if (hp) { hp->SetFillColor(38); if (binx1 == binx2) hp->SetTitle(Form("ProjectionY of binx=%d", binx1)); @@ -9227,7 +9417,7 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) TVirtualPad *padsav = gPad; TVirtualPad *c = (TVirtualPad*)gROOT->GetListOfCanvases()->FindObject(Form("c_%lx_projection_%d", (ULong_t)fH, fShowProjection)); - if(!c) { + if (!c) { fShowProjection = 0; return; } @@ -9244,7 +9434,7 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) Int_t lastZ = zaxis->GetLast(); Int_t binz = firstZ + Int_t((lastZ-firstZ)*(py-pymin)/(pymax-pymin)); zaxis->SetRange(binz,binz+nbins-1); - if(line1[0].GetX()) gVirtualX->DrawPolyLine(2,line1); + if (line1[0].GetX()) gVirtualX->DrawPolyLine(2,line1); if (nbins>1 && line1[0].GetX()) { gVirtualX->DrawPolyLine(2,line2); gVirtualX->DrawPolyLine(2,line3); @@ -9351,7 +9541,7 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) Int_t lastZ = zaxis->GetLast(); Int_t binz = firstZ + Int_t((lastZ-firstZ)*(py-pymin)/(pymax-pymin)); zaxis->SetRange(binz,binz+nbins-1); - if(line1[0].GetX()) gVirtualX->DrawPolyLine(2,line1); + if (line1[0].GetX()) gVirtualX->DrawPolyLine(2,line1); if (nbins>1 && line1[0].GetX()) { gVirtualX->DrawPolyLine(2,line2); gVirtualX->DrawPolyLine(2,line3); @@ -9458,7 +9648,7 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) Int_t lastY = yaxis->GetLast(); Int_t biny = firstY + Int_t((lastY-firstY)*(py-pymin)/(pymax-pymin)); yaxis->SetRange(biny,biny+nbins-1); - if(line1[0].GetX()) gVirtualX->DrawPolyLine(2,line1); + if (line1[0].GetX()) gVirtualX->DrawPolyLine(2,line1); if (nbins>1 && line1[0].GetX()) { gVirtualX->DrawPolyLine(2,line2); gVirtualX->DrawPolyLine(2,line3); @@ -9561,8 +9751,8 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) Int_t last = zaxis->GetLast(); Int_t binz = first + Int_t((last-first)*(py-pymin)/(pymax-pymin)); zaxis->SetRange(binz,binz+nbins-1); - if(rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect1); - if(nbins>1 && rect2[0].GetX()) gVirtualX->DrawPolyLine(5,rect2); + if (rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect1); + if (nbins>1 && rect2[0].GetX()) gVirtualX->DrawPolyLine(5,rect2); xx[0] = xaxis->GetXmin(); xx[1] = yaxis->GetXmax(); xx[2] = zaxis->GetBinCenter(binz); @@ -9616,7 +9806,7 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) zaxis->SetRange(first,last); if (hp) { hp->SetFillColor(38); - if(nbins==1)hp->SetTitle(Form("ProjectionXY of binz=%d (%.1f)", binz,value1)); + if (nbins==1)hp->SetTitle(Form("ProjectionXY of binz=%d (%.1f)", binz,value1)); else hp->SetTitle(Form("ProjectionXY, binz range=%d-%d (%.1f-%.1f)", binz,binz+nbins-1,value1,value2)); hp->SetXTitle(fH->GetYaxis()->GetTitle()); hp->SetYTitle(fH->GetXaxis()->GetTitle()); @@ -9633,8 +9823,8 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) Int_t last = zaxis->GetLast(); Int_t binz = first + Int_t((last-first)*(py-pymin)/(pymax-pymin)); zaxis->SetRange(binz,binz+nbins-1); - if(rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect1); - if(nbins>1 && rect2[0].GetX()) gVirtualX->DrawPolyLine(5,rect2); + if (rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect1); + if (nbins>1 && rect2[0].GetX()) gVirtualX->DrawPolyLine(5,rect2); xx[0] = xaxis->GetXmin(); xx[1] = yaxis->GetXmax(); xx[2] = zaxis->GetBinCenter(binz); @@ -9687,7 +9877,7 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) zaxis->SetRange(first,last); if (hp) { hp->SetFillColor(38); - if(nbins==1)hp->SetTitle(Form("ProjectionYX of binz=%d (%.1f)", binz,value1)); + if (nbins==1)hp->SetTitle(Form("ProjectionYX of binz=%d (%.1f)", binz,value1)); else hp->SetTitle(Form("ProjectionXY, binz range=%d-%d (%.1f-%.1f)", binz,binz+nbins-1,value1,value2)); hp->SetXTitle(fH->GetXaxis()->GetTitle()); hp->SetYTitle(fH->GetYaxis()->GetTitle()); @@ -9704,8 +9894,8 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) Int_t last = yaxis->GetLast(); Int_t biny = first + Int_t((last-first)*(py-pymin)/(pymax-pymin)); yaxis->SetRange(biny,biny+nbins-1); - if(rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect1); - if(nbins>1 && rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect2); + if (rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect1); + if (nbins>1 && rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect2); xx[0] = xaxis->GetXmin(); xx[2] = zaxis->GetXmax(); xx[1] = yaxis->GetBinCenter(biny); @@ -9758,7 +9948,7 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) yaxis->SetRange(first,last); if (hp) { hp->SetFillColor(38); - if(nbins==1)hp->SetTitle(Form("ProjectionXZ of biny=%d (%.1f)", biny,value1)); + if (nbins==1)hp->SetTitle(Form("ProjectionXZ of biny=%d (%.1f)", biny,value1)); else hp->SetTitle(Form("ProjectionXZ, biny range=%d-%d (%.1f-%.1f)", biny,biny+nbins-1,value1,value2)); hp->SetXTitle(fH->GetZaxis()->GetTitle()); hp->SetYTitle(fH->GetXaxis()->GetTitle()); @@ -9775,8 +9965,8 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) Int_t last = yaxis->GetLast(); Int_t biny = first + Int_t((last-first)*(py-pymin)/(pymax-pymin)); yaxis->SetRange(biny,biny+nbins-1); - if(rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect1); - if(nbins>1 && rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect2); + if (rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect1); + if (nbins>1 && rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect2); xx[0] = xaxis->GetXmin(); xx[2] = zaxis->GetXmax(); xx[1] = yaxis->GetBinCenter(biny); @@ -9829,7 +10019,7 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) yaxis->SetRange(first,last); if (hp) { hp->SetFillColor(38); - if(nbins==1)hp->SetTitle(Form("ProjectionZX of biny=%d (%.1f)", biny,value1)); + if (nbins==1)hp->SetTitle(Form("ProjectionZX of biny=%d (%.1f)", biny,value1)); else hp->SetTitle(Form("ProjectionZX, binY range=%d-%d (%.1f-%.1f)", biny,biny+nbins-1,value1,value2)); hp->SetXTitle(fH->GetXaxis()->GetTitle()); hp->SetYTitle(fH->GetZaxis()->GetTitle()); @@ -9846,8 +10036,8 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) Int_t last = xaxis->GetLast(); Int_t binx = first + Int_t((last-first)*(px-pxmin)/(pxmax-pxmin)); xaxis->SetRange(binx,binx+nbins-1); - if(rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect1); - if(nbins>1 && rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect2); + if (rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect1); + if (nbins>1 && rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect2); xx[2] = zaxis->GetXmin(); xx[1] = yaxis->GetXmax(); xx[0] = xaxis->GetBinCenter(binx); @@ -9900,7 +10090,7 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) xaxis->SetRange(first,last); if (hp) { hp->SetFillColor(38); - if(nbins==1)hp->SetTitle(Form("ProjectionYZ of binx=%d (%.1f)", binx,value1)); + if (nbins==1)hp->SetTitle(Form("ProjectionYZ of binx=%d (%.1f)", binx,value1)); else hp->SetTitle(Form("ProjectionYZ, binx range=%d-%d (%.1f-%.1f)", binx,binx+nbins-1,value1,value2)); hp->SetXTitle(fH->GetZaxis()->GetTitle()); hp->SetYTitle(fH->GetYaxis()->GetTitle()); @@ -9917,8 +10107,8 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) Int_t last = xaxis->GetLast(); Int_t binx = first + Int_t((last-first)*(px-pxmin)/(pxmax-pxmin)); xaxis->SetRange(binx,binx+nbins-1); - if(rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect1); - if(nbins>1 && rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect2); + if (rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect1); + if (nbins>1 && rect1[0].GetX()) gVirtualX->DrawPolyLine(5,rect2); xx[2] = zaxis->GetXmin(); xx[1] = yaxis->GetXmax(); xx[0] = xaxis->GetBinCenter(binx); @@ -9971,7 +10161,7 @@ void THistPainter::ShowProjection3(Int_t px, Int_t py) xaxis->SetRange(first,last); if (hp) { hp->SetFillColor(38); - if(nbins==1)hp->SetTitle(Form("ProjectionZY of binx=%d (%.1f)", binx,value1)); + if (nbins==1)hp->SetTitle(Form("ProjectionZY of binx=%d (%.1f)", binx,value1)); else hp->SetTitle(Form("ProjectionZY, binx range=%d-%d (%.1f-%.1f)", binx,binx+nbins-1,value1,value2)); hp->SetXTitle(fH->GetYaxis()->GetTitle()); hp->SetYTitle(fH->GetZaxis()->GetTitle()); diff --git a/hist/histpainter/src/TPainter3dAlgorithms.cxx b/hist/histpainter/src/TPainter3dAlgorithms.cxx index a6764def1f385..038caee9afd83 100644 --- a/hist/histpainter/src/TPainter3dAlgorithms.cxx +++ b/hist/histpainter/src/TPainter3dAlgorithms.cxx @@ -40,17 +40,13 @@ End_Html */ #include "THLimitsFinder.h" #include "TColor.h" -#ifdef R__SUNCCBUG -const Double_t kRad = 1.74532925199432955e-02; -#else -const Double_t kRad = TMath::ATan(1)*Double_t(4)/Double_t(180); -#endif +const Double_t kRad = TMath::ATan(1)*Double_t(4)/Double_t(180); const Double_t kFdel = 0.; -const Double_t kDel = 0.0001; -const Int_t kNiso = 4; +const Double_t kDel = 0.0001; +const Int_t kNiso = 4; const Int_t kNmaxp = kNiso*13; const Int_t kNmaxt = kNiso*12; -const Int_t kLmax = 12; +const Int_t kLmax = 12; const Int_t kF3FillColor1 = 201; const Int_t kF3FillColor2 = 202; const Int_t kF3LineColor = 203; @@ -67,6 +63,9 @@ static Double_t gV[kVSizeMax]; static Double_t gTT[4*kVSizeMax]; static Int_t gColorMain[kVSizeMax+1]; static Int_t gColorDark[kVSizeMax+1]; +static Int_t gEdgeColor[kVSizeMax+1]; +static Int_t gEdgeStyle[kVSizeMax+1]; +static Int_t gEdgeWidth[kVSizeMax+1]; extern TH1 *gCurrentHist; //these 3 globals should be replaced by class members extern Hoption_t Hoption; @@ -86,13 +85,13 @@ TPainter3dAlgorithms::TPainter3dAlgorithms(): TObject(), TAttLine(1,1,1), TAttFi fRaster = 0; fColorTop = 1; fColorBottom = 1; + fEdgeIdx = -1; fNlevel = 0; fSystem = kCARTESIAN; fDrawFace = 0; fLegoFunction = 0; fSurfaceFunction = 0; - TList *stack = 0; if (gCurrentHist) stack = gCurrentHist->GetPainter()->GetStack(); fNStack = 0; @@ -100,13 +99,19 @@ TPainter3dAlgorithms::TPainter3dAlgorithms(): TObject(), TAttLine(1,1,1), TAttFi if (fNStack > kVSizeMax) { fColorMain = new Int_t[fNStack+1]; fColorDark = new Int_t[fNStack+1]; + fEdgeColor = new Int_t[fNStack+1]; + fEdgeStyle = new Int_t[fNStack+1]; + fEdgeWidth = new Int_t[fNStack+1]; } else { fColorMain = &gColorMain[0]; fColorDark = &gColorDark[0]; + fEdgeColor = &gEdgeColor[0]; + fEdgeStyle = &gEdgeStyle[0]; + fEdgeWidth = &gEdgeWidth[0]; } - for (i=0;i<fNStack;i++) { fColorMain[i] = 1; fColorDark[i] = 1; } - for (i=0;i<3;i++) { fRmin[i] = 0, fRmax[i] = 1; } + for (i=0;i<fNStack;i++) { fColorMain[i] = 1; fColorDark[i] = 1; fEdgeColor[i] = 1; fEdgeStyle[i] = 1; fEdgeWidth[i] = 1; } + for (i=0;i<3;i++) { fRmin[i] = 0; fRmax[i] = 1; } for (i=0;i<4;i++) { fYls[i] = 0; } for (i=0;i<30;i++) { fJmask[i] = 0; } @@ -163,6 +168,7 @@ TPainter3dAlgorithms::TPainter3dAlgorithms(Double_t *rmin, Double_t *rmax, Int_t fRaster = 0; fColorTop = 1; fColorBottom = 1; + fEdgeIdx = -1; fNlevel = 0; fSystem = system; if (system == kCARTESIAN || system == kPOLAR) psi = 0; @@ -177,13 +183,19 @@ TPainter3dAlgorithms::TPainter3dAlgorithms(Double_t *rmin, Double_t *rmax, Int_t if (fNStack > kVSizeMax) { fColorMain = new Int_t[fNStack+1]; fColorDark = new Int_t[fNStack+1]; + fEdgeColor = new Int_t[fNStack+1]; + fEdgeStyle = new Int_t[fNStack+1]; + fEdgeWidth = new Int_t[fNStack+1]; } else { fColorMain = &gColorMain[0]; fColorDark = &gColorDark[0]; + fEdgeColor = &gEdgeColor[0]; + fEdgeStyle = &gEdgeStyle[0]; + fEdgeWidth = &gEdgeWidth[0]; } - for (i=0;i<fNStack;i++) { fColorMain[i] = 1; fColorDark[i] = 1; } - for (i=0;i<3;i++) { fRmin[i] = rmin[i], fRmax[i] = rmax[i]; } + for (i=0;i<fNStack;i++) { fColorMain[i] = 1; fColorDark[i] = 1; fEdgeColor[i] = 1; fEdgeStyle[i] = 1; fEdgeWidth[i] = 1; } + for (i=0;i<3;i++) { fRmin[i] = rmin[i]; fRmax[i] = rmax[i]; } for (i=0;i<4;i++) { fYls[i] = 0; } for (i=0;i<30;i++) { fJmask[i] = 0; } @@ -240,6 +252,9 @@ TPainter3dAlgorithms::~TPainter3dAlgorithms() if (fNStack > kVSizeMax) { delete [] fColorMain; delete [] fColorDark; + delete [] fEdgeColor; + delete [] fEdgeStyle; + delete [] fEdgeWidth; } } @@ -525,10 +540,17 @@ void TPainter3dAlgorithms::DrawFaceMode2(Int_t *icodes, Double_t *xyz, Int_t np, // D R A W F A C E & B O R D E R FillPolygon(np, p3, &t[1]); if (fMesh == 1) { - SetFillColor(1); - SetFillStyle(0); - TAttFill::Modify(); - gPad->PaintFillArea(np, x, y); + if (Hoption.Lego!=0 && Hoption.Surf==0) { // i.e. PaintFillArea for lego, not for surf + SetFillColor(fEdgeColor[fEdgeIdx]); + SetFillStyle(0); + TAttFill::Modify(); + gPad->PaintFillArea(np, x, y); + } + SetLineColor(fEdgeColor[fEdgeIdx]); + SetLineStyle(fEdgeStyle[fEdgeIdx]); + SetLineWidth(fEdgeWidth[fEdgeIdx]); + TAttLine::Modify(); + gPad->PaintPolyLine(np, x, y); } } @@ -588,9 +610,14 @@ void TPainter3dAlgorithms::DrawFaceMode3(Int_t *icodes, Double_t *xyz, Int_t np, gPad->PaintFillArea(np, x, y); if (fMesh) { SetFillStyle(0); - SetFillColor(1); + SetFillColor(fEdgeColor[fEdgeIdx]); TAttFill::Modify(); gPad->PaintFillArea(np, x, y); + SetLineColor(fEdgeColor[fEdgeIdx]); + SetLineStyle(fEdgeStyle[fEdgeIdx]); + SetLineWidth(fEdgeWidth[fEdgeIdx]); + TAttLine::Modify(); + gPad->PaintPolyLine(np, x, y); } } @@ -644,6 +671,13 @@ void TPainter3dAlgorithms::DrawFaceMove1(Int_t *icodes, Double_t *xyz, Int_t np, // D R A W L E V E L L I N E S SetLineStyle(3); + if (icodes[3]==0) { // front & back boxes + SetLineColor(1); + SetLineWidth(1); + } else { + SetLineColor(fEdgeColor[fEdgeIdx]); + SetLineWidth(fEdgeWidth[fEdgeIdx]); + } TAttLine::Modify(); for (il = 1; il <= fNlines; ++il) { FindVisibleDraw(&fPlines[(2*il + 1)*3 - 9], &fPlines[(2*il + 2)*3 - 9]); @@ -661,7 +695,15 @@ void TPainter3dAlgorithms::DrawFaceMove1(Int_t *icodes, Double_t *xyz, Int_t np, } // D R A W F A C E - SetLineStyle(1); + if (icodes[3]==0) { // front & back boxes + SetLineColor(1); + SetLineStyle(1); + SetLineWidth(1); + } else { + SetLineColor(fEdgeColor[fEdgeIdx]); + SetLineStyle(fEdgeStyle[fEdgeIdx]); + SetLineWidth(fEdgeWidth[fEdgeIdx]); + } TAttLine::Modify(); for (i = 1; i <= np; ++i) { i1 = i; @@ -739,6 +781,15 @@ void TPainter3dAlgorithms::DrawFaceMove3(Int_t *icodes, Double_t *xyz, Int_t np, FindLevelLines(np, p3, &tt[1]); // Draw level lines + if (icodes[3]==0) { // front and back boxes + SetLineColor(1); + SetLineStyle(1); + SetLineWidth(1); + } else { + SetLineColor(fEdgeColor[fEdgeIdx]); + SetLineStyle(fEdgeStyle[fEdgeIdx]); + SetLineWidth(fEdgeWidth[fEdgeIdx]); + } TAttLine::Modify(); for (il = 1; il <= fNlines; ++il) { FindVisibleDraw(&fPlines[(2*il + 1)*3 - 9], &fPlines[(2*il + 2)*3 - 9]); @@ -787,7 +838,7 @@ void TPainter3dAlgorithms::DrawFaceMove2(Int_t *icodes, Double_t *xyz, Int_t np, // (not used in this routine) Double_t xdel, ydel; - Int_t i, k, icol, i1, i2, it; + Int_t i, k, i1, i2, it; Double_t x[2], y[2]; Double_t p1[3], p2[3], p3[36] /* was [3][12] */; TView *view = 0; @@ -810,9 +861,15 @@ void TPainter3dAlgorithms::DrawFaceMove2(Int_t *icodes, Double_t *xyz, Int_t np, } // D R A W F A C E - icol = icodes[3]; - if (icol) SetLineColor(fColorMain[icol - 1]); - else SetLineColor(1); + if (icodes[3]==0) { // front & back boxes + SetLineColor(1); + SetLineStyle(1); + SetLineWidth(1); + } else { + SetLineColor(fEdgeColor[fEdgeIdx]); + SetLineStyle(fEdgeStyle[fEdgeIdx]); + SetLineWidth(fEdgeWidth[fEdgeIdx]); + } TAttLine::Modify(); for (i = 1; i <= np; ++i) { i1 = i; @@ -893,6 +950,13 @@ void TPainter3dAlgorithms::DrawFaceRaster1(Int_t *icodes, Double_t *xyz, Int_t n // D R A W L E V E L L I N E S SetLineStyle(3); + if (icodes[3]==0) { // front & back boxes + SetLineColor(1); + SetLineWidth(1); + } else { + SetLineColor(fEdgeColor[fEdgeIdx]); + SetLineWidth(fEdgeWidth[fEdgeIdx]); + } TAttLine::Modify(); for (il = 1; il <= fNlines; ++il) { view->WCtoNDC(&fPlines[(2*il + 1)*3 - 9], p1); @@ -910,7 +974,15 @@ void TPainter3dAlgorithms::DrawFaceRaster1(Int_t *icodes, Double_t *xyz, Int_t n } // D R A W F A C E - SetLineStyle(1); + if (icodes[3]==0) { // front & back boxes + SetLineColor(1); + SetLineStyle(1); + SetLineWidth(1); + } else { + SetLineColor(fEdgeColor[fEdgeIdx]); + SetLineStyle(fEdgeStyle[fEdgeIdx]); + SetLineWidth(fEdgeWidth[fEdgeIdx]); + } TAttLine::Modify(); for (i = 1; i <= np; ++i) { if (iface[i] < 0) continue; @@ -955,7 +1027,7 @@ void TPainter3dAlgorithms::DrawFaceRaster2(Int_t *icodes, Double_t *xyz, Int_t n // (not used in this routine) Double_t xdel, ydel; - Int_t i, k, icol, i1, i2, it; + Int_t i, k, i1, i2, it; Double_t p[3], x[2], y[2]; Double_t pp[24] /* was [2][12] */; TView *view = 0; @@ -979,9 +1051,9 @@ void TPainter3dAlgorithms::DrawFaceRaster2(Int_t *icodes, Double_t *xyz, Int_t n } // D R A W F A C E - icol = icodes[3]; - if (icol) SetLineColor(fColorMain[icol - 1]); - else SetLineColor(1); + SetLineColor(fEdgeColor[fEdgeIdx]); + SetLineStyle(fEdgeStyle[fEdgeIdx]); + SetLineWidth(fEdgeWidth[fEdgeIdx]); TAttLine::Modify(); for (i = 1; i <= np; ++i) { if (iface[i] < 0) continue; @@ -2228,7 +2300,7 @@ void TPainter3dAlgorithms::LegoFunction(Int_t ia, Int_t ib, Int_t &nv, Double_t // Get the content of the table, and loop on the // stack if necessary. vv[1] = Hparam.zmin; - vv[2] = Hparam.factor*gCurrentHist->GetCellContent(ixt, iyt); + vv[2] = Hparam.factor*gCurrentHist->GetBinContent(ixt, iyt); // In linear scale, 3D boxes all start from 0. if (Hparam.zmin<0 && !Hoption.Logz && gStyle->GetHistMinimumZero()) { @@ -2246,7 +2318,7 @@ void TPainter3dAlgorithms::LegoFunction(Int_t ia, Int_t ib, Int_t &nv, Double_t if (nids) { for (i = 2; i <= nids + 1; ++i) { TH1 *hid = (TH1*)stack->At(i-2); - vv[i + 1] = Hparam.factor*hid->GetCellContent(ixt, iyt) + vv[i]; + vv[i + 1] = Hparam.factor*hid->GetBinContent(ixt, iyt) + vv[i]; vv[i + 1] = TMath::Max(Hparam.zmin, vv[i + 1]); //vv[i + 1] = TMath::Min(Hparam.zmax, vv[i + 1]); } @@ -2341,6 +2413,7 @@ void TPainter3dAlgorithms::LegoCartesian(Double_t ang, Int_t nx, Int_t ny, const Double_t xyz[24]; // was [3][8] Double_t *tn = 0; TView *view = 0; + Int_t firstStackNumberDrawn=-1 ; // necessary to compute fColorBottom when the 0 option is set and when the stack is seen from below (bottomview, theta<0.) sina = TMath::Sin(ang*kRad); cosa = TMath::Cos(ang*kRad); @@ -2422,6 +2495,7 @@ void TPainter3dAlgorithms::LegoCartesian(Double_t ang, Int_t nx, Int_t ny, const xyz[(i + 4)*3 - 2] = xyz[i*3 - 2]; } // D R A W S T A C K + firstStackNumberDrawn = -1; for (iv = 1; iv < nv; ++iv) { for (i = 1; i <= 4; ++i) { xyz[i*3 - 1] = v[iv - 1]; @@ -2443,8 +2517,10 @@ void TPainter3dAlgorithms::LegoCartesian(Double_t ang, Int_t nx, Int_t ny, const tface[1] = tt[k2 + (iv << 2) - 5]; tface[2] = tt[k2 + ((iv + 1) << 2) - 5]; tface[3] = tt[k1 + ((iv + 1) << 2) - 5]; + fEdgeIdx = iv-1; (this->*fDrawFace)(icodes, xyz, 4, iface, tface); } + if ( firstStackNumberDrawn==-1 ) firstStackNumberDrawn = fEdgeIdx; } // D R A W B O T T O M F A C E view->FindNormal(0, 0, 1, zn); @@ -2456,6 +2532,11 @@ void TPainter3dAlgorithms::LegoCartesian(Double_t ang, Int_t nx, Int_t ny, const iface[i - 1] = 5 - i; tface[i - 1] = tt[5 - i - 1]; } + if (!Hoption.Zero) fEdgeIdx = 0; + else { + fEdgeIdx = firstStackNumberDrawn; + fColorBottom = fColorMain[fEdgeIdx]; + } (this->*fDrawFace)(icodes, xyz, 4, iface, tface); } // D R A W T O P F A C E @@ -2467,9 +2548,15 @@ void TPainter3dAlgorithms::LegoCartesian(Double_t ang, Int_t nx, Int_t ny, const tface[i - 1] = tt[i + (nv << 2) - 5]; } Int_t cs = fColorTop; - if ( nv > 2 && (v[nv-1] == v[nv-2])) { - for (iv = nv-1; iv>2; iv--) { - if (v[nv-1] == v[iv-1]) fColorTop = fColorMain[iv-2]; + if ( nv <= 3 ) fEdgeIdx = 0 ; // no stack or stack with only one histo + else { + if ( nv > 2 && (v[nv-1] == v[nv-2])) { + for (iv = nv-1; iv>2; iv--) { + if (v[nv-1] == v[iv-1]) { + fColorTop = fColorMain[iv-2]; + fEdgeIdx = iv-2; + } + } } } (this->*fDrawFace)(icodes, xyz, 4, iface, tface); @@ -2530,6 +2617,7 @@ void TPainter3dAlgorithms::LegoPolar(Int_t iordr, Int_t na, Int_t nb, const char Double_t xyz[24]; // was [3][8] ia = ib = 0; TView *view = 0; + Int_t firstStackNumberDrawn=-1 ; // necessary to compute fColorBottom when the 0 option is set and when the stack is seen from below (bottomview, theta<0.) if (gPad) view = gPad->GetView(); if (!view) { @@ -2626,6 +2714,7 @@ void TPainter3dAlgorithms::LegoPolar(Int_t iordr, Int_t na, Int_t nb, const char xyz[(j + 4)*3 - 2] = xyz[j*3 - 2]; } // D R A W S T A C K + firstStackNumberDrawn = -1; for (iv = 1; iv < nv; ++iv) { for (i = 1; i <= 4; ++i) { xyz[i*3 - 1] = v[iv - 1]; @@ -2649,8 +2738,10 @@ void TPainter3dAlgorithms::LegoPolar(Int_t iordr, Int_t na, Int_t nb, const char tface[2] = tt[k2 + ((iv + 1) << 2) - 5]; tface[3] = tt[k1 + ((iv + 1) << 2) - 5]; icodes[3] = i; + fEdgeIdx = iv-1; (this->*fDrawFace)(icodes, xyz, 4, iface, tface); } + if ( firstStackNumberDrawn==-1 ) firstStackNumberDrawn = fEdgeIdx; } // D R A W B O T T O M F A C E if (ivis[4] != 0) { @@ -2661,6 +2752,11 @@ void TPainter3dAlgorithms::LegoPolar(Int_t iordr, Int_t na, Int_t nb, const char iface[i - 1] = 5 - i; tface[i - 1] = tt[5 - i - 1]; } + if (!Hoption.Zero) fEdgeIdx = 0; + else { + fEdgeIdx = firstStackNumberDrawn; + fColorBottom = fColorMain[fEdgeIdx]; + } (this->*fDrawFace)(icodes, xyz, 4, iface, tface); } // D R A W T O P F A C E @@ -2672,9 +2768,15 @@ void TPainter3dAlgorithms::LegoPolar(Int_t iordr, Int_t na, Int_t nb, const char tface[i - 1] = tt[i + (nv << 2) - 5]; } Int_t cs = fColorTop; - if ( nv > 2 && (v[nv-1] == v[nv-2])) { - for (iv = nv-1; iv>2; iv--) { - if (v[nv-1] == v[iv-1]) fColorTop = fColorMain[iv-2]; + if ( nv <= 3 ) fEdgeIdx = 0 ; // no stack or stack with only one histo + else { + if ( nv > 2 && (v[nv-1] == v[nv-2])) { + for (iv = nv-1; iv>2; iv--) { + if (v[nv-1] == v[iv-1]) { + fColorTop = fColorMain[iv-2]; + fEdgeIdx = iv-2; + } + } } } (this->*fDrawFace)(icodes, xyz, 4, iface, tface); @@ -2752,6 +2854,7 @@ void TPainter3dAlgorithms::LegoCylindrical(Int_t iordr, Int_t na, Int_t nb, cons Double_t xyz[24]; // was [3][8] ia = ib = 0; TView *view = 0; + Int_t firstStackNumberDrawn=-1 ; // necessary to compute fColorBottom when the 0 option is set and when the stack is seen from below (bottomview, theta<0.) if (gPad) view = gPad->GetView(); if (!view) { @@ -2849,6 +2952,7 @@ void TPainter3dAlgorithms::LegoCylindrical(Int_t iordr, Int_t na, Int_t nb, cons xyz[(j + 4)*3 - 1] = ab[jz + 2*i - 3]; } // D R A W S T A C K + firstStackNumberDrawn = -1; for (iv = 1; iv < nv; ++iv) { for (i = 1; i <= 4; ++i) { xyz[i*3 - 3] = v[iv - 1]*cosphi[i - 1]; @@ -2872,8 +2976,10 @@ void TPainter3dAlgorithms::LegoCylindrical(Int_t iordr, Int_t na, Int_t nb, cons tface[2] = tt[k2 + ((iv + 1) << 2) - 5]; tface[3] = tt[k1 + ((iv + 1) << 2) - 5]; icodes[3] = i; + fEdgeIdx = iv-1; (this->*fDrawFace)(icodes, xyz, 4, iface, tface); } + if ( firstStackNumberDrawn==-1 ) firstStackNumberDrawn = fEdgeIdx; } // D R A W B O T T O M F A C E if (ivis[4] != 0 && v[0] > 0) { @@ -2885,6 +2991,11 @@ void TPainter3dAlgorithms::LegoCylindrical(Int_t iordr, Int_t na, Int_t nb, cons iface[i - 1] = i; tface[i - 1] = tt[i - 1]; } + if (!Hoption.Zero) fEdgeIdx = 0; + else { + fEdgeIdx = firstStackNumberDrawn; + fColorBottom = fColorMain[fEdgeIdx]; + } (this->*fDrawFace)(icodes, xyz, 4, iface, tface); } // D R A W T O P F A C E @@ -2896,9 +3007,15 @@ void TPainter3dAlgorithms::LegoCylindrical(Int_t iordr, Int_t na, Int_t nb, cons tface[i - 1] = tt[5 - i + (nv << 2) - 5]; } Int_t cs = fColorTop; - if ( nv > 2 && (v[nv-1] == v[nv-2])) { - for (iv = nv-1; iv>2; iv--) { - if (v[nv-1] == v[iv-1]) fColorTop = fColorMain[iv-2]; + if ( nv <= 3 ) fEdgeIdx = 0 ; // no stack or stack with only one histo + else { + if ( nv > 2 && (v[nv-1] == v[nv-2])) { + for (iv = nv-1; iv>2; iv--) { + if (v[nv-1] == v[iv-1]) { + fColorTop = fColorMain[iv-2]; + fEdgeIdx = iv-2; + } + } } } (this->*fDrawFace)(icodes, xyz, 4, iface, tface); @@ -2974,6 +3091,7 @@ void TPainter3dAlgorithms::LegoSpherical(Int_t ipsdr, Int_t iordr, Int_t na, Int Double_t phi1, phi2; ia = ib = 0; TView *view = 0; + Int_t firstStackNumberDrawn=-1 ; // necessary to compute fColorBottom when the 0 option is set and when the stack is seen from below (bottomview, theta<0.) if (gPad) view = gPad->GetView(); if (!view) { @@ -3102,6 +3220,7 @@ void TPainter3dAlgorithms::LegoSpherical(Int_t ipsdr, Int_t iordr, Int_t na, Int cosphi[j - 1] = TMath::Cos(kRad*ab[jphi + 2*i - 3]); sinphi[j - 1] = TMath::Sin(kRad*ab[jphi + 2*i - 3]); } + firstStackNumberDrawn = -1; for (iv = 1; iv < nv; ++iv) { if (ipsdr == 1) { for (i = 1; i <= 4; ++i) { @@ -3138,8 +3257,10 @@ void TPainter3dAlgorithms::LegoSpherical(Int_t ipsdr, Int_t iordr, Int_t na, Int tface[2] = tt[k2 + ((iv + 1) << 2) - 5]; tface[3] = tt[k1 + ((iv + 1) << 2) - 5]; icodes[3] = i; + fEdgeIdx = iv-1; (this->*fDrawFace)(icodes, xyz, 4, iface, tface); } + if ( firstStackNumberDrawn==-1 ) firstStackNumberDrawn = fEdgeIdx; } // D R A W B O T T O M F A C E if (ivis[4] != 0 && v[0] > 0) { @@ -3158,6 +3279,11 @@ void TPainter3dAlgorithms::LegoSpherical(Int_t ipsdr, Int_t iordr, Int_t na, Int iface[i - 1] = 5 - i; tface[i - 1] = tt[5 - i - 1]; } + if (!Hoption.Zero) fEdgeIdx = 0; + else { + fEdgeIdx = firstStackNumberDrawn; + fColorBottom = fColorMain[fEdgeIdx]; + } (this->*fDrawFace)(icodes, xyz, 4, iface, tface); } // D R A W T O P F A C E @@ -3169,9 +3295,15 @@ void TPainter3dAlgorithms::LegoSpherical(Int_t ipsdr, Int_t iordr, Int_t na, Int tface[i - 1] = tt[i + 4 + 2*nv - 5]; } Int_t cs = fColorTop; - if ( nv > 2 && (v[nv-1] == v[nv-2])) { - for (iv = nv-1; iv>2; iv--) { - if (v[nv-1] == v[iv-1]) fColorTop = fColorMain[iv-2]; + if ( nv <= 3 ) fEdgeIdx = 0 ; // no stack or stack with only one histo + else { + if ( nv > 2 && (v[nv-1] == v[nv-2])) { + for (iv = nv-1; iv>2; iv--) { + if (v[nv-1] == v[iv-1]) { + fColorTop = fColorMain[iv-2]; + fEdgeIdx = iv-2; + } + } } } (this->*fDrawFace)(icodes, xyz, 4, iface, tface); @@ -3499,6 +3631,18 @@ void TPainter3dAlgorithms::SetColorMain(Color_t color, Int_t n) } +//______________________________________________________________________________ +void TPainter3dAlgorithms::SetEdgeAtt(Color_t color, Style_t style, Width_t width, Int_t n) +{ + + // Store edge attributes + + fEdgeColor[n] = color; + fEdgeStyle[n] = style; + fEdgeWidth[n] = width; +} + + //______________________________________________________________________________ void TPainter3dAlgorithms::SideVisibilityDecode(Double_t val, Int_t &iv1, Int_t &iv2, Int_t &iv3, Int_t &iv4, Int_t &iv5, Int_t &iv6, Int_t &ir) { @@ -3666,7 +3810,7 @@ void TPainter3dAlgorithms::SurfaceCartesian(Double_t ang, Int_t nx, Int_t ny, co Double_t cosa, sina, f[12] /* was [3][4] */; Int_t i, incrx, incry, i1, ix, iy; Double_t tt[4]; - Int_t icodes[2], ix1, iy1, ix2, iy2; + Int_t icodes[3], ix1, iy1, ix2, iy2; // was icode[2]. One element more to differentiate front & back boxes from data Double_t xyz[12] /* was [3][4] */; Double_t *tn; @@ -3702,6 +3846,8 @@ void TPainter3dAlgorithms::SurfaceCartesian(Double_t ang, Int_t nx, Int_t ny, co iy2 = ny - iy1 + 1; // D R A W S U R F A C E + icodes[2] = -1; // -1 for data, 0 for front a back boxes + fEdgeIdx = 0; // constant since stacks are not (yet?) handled for surfaces THistPainter *painter = (THistPainter*)gCurrentHist->GetPainter(); for (iy = iy1; incry < 0 ? iy >= iy2 : iy <= iy2; iy += incry) { for (ix = ix1; incrx < 0 ? ix >= ix2 : ix <= ix2; ix += incrx) { @@ -3822,7 +3968,7 @@ void TPainter3dAlgorithms::SurfaceFunction(Int_t ia, Int_t ib, Double_t *f, Doub // first channel should be used. */ icx = ixt + ixa; if (icx > Hparam.xlast) icx = 1; - f[i*3+3] = Hparam.factor*gCurrentHist->GetCellContent(icx, iyt + iya); + f[i*3+3] = Hparam.factor*gCurrentHist->GetBinContent(icx, iyt + iya); if (Hoption.Logz) { if (f[i*3+3] > 0) f[i*3+3] = TMath::Log10(f[i*3+3]); else f[i*3+3] = Hparam.zmin; @@ -3834,7 +3980,7 @@ void TPainter3dAlgorithms::SurfaceFunction(Int_t ia, Int_t ib, Double_t *f, Doub } // The colors on the surface can represent the content or the errors. - // if (fSumw2.fN) t[i] = gCurrentHist->GetCellError(icx, iyt + iya); + // if (fSumw2.fN) t[i] = gCurrentHist->GetBinError(icx, iyt + iya); // else t[i] = f[i * 3 + 3]; t[i] = f[i * 3 + 3]; } @@ -3897,7 +4043,7 @@ void TPainter3dAlgorithms::SurfacePolar(Int_t iordr, Int_t na, Int_t nb, const c Double_t f[12] /* was [3][4] */; Int_t i, j, incrr, ir1, ir2; Double_t z; - Int_t ia, ib, ir, jr, nr, icodes[2]; + Int_t ia, ib, ir, jr, nr, icodes[3]; // was icode[2]. One element more to differentiate front & back boxes from data Double_t tt[4]; Double_t phi, ttt[4], xyz[12] /* was [3][4] */; ia = ib = 0; @@ -3936,6 +4082,8 @@ void TPainter3dAlgorithms::SurfacePolar(Int_t iordr, Int_t na, Int_t nb, const c view->FindPhiSectors(iopt, kphi, fAphi, iphi1, iphi2); // D R A W S U R F A C E + icodes[2] = -1; // -1 for data, 0 for front a back boxes + fEdgeIdx = 0; // constant since stacks are not (yet?) handled for surfaces incr = 1; iphi = iphi1; L100: @@ -4032,7 +4180,7 @@ void TPainter3dAlgorithms::SurfaceCylindrical(Int_t iordr, Int_t na, Int_t nb, c Int_t iphi, jphi, kphi, incr, nphi, iopt, iphi1, iphi2; Int_t i, j, incrz, nz, iz1, iz2; - Int_t ia, ib, iz, jz, icodes[2]; + Int_t ia, ib, iz, jz, icodes[3]; // was icode[2]. One element more to differentiate front & back boxes from data Double_t f[12] /* was [3][4] */; Double_t z; Double_t tt[4]; @@ -4090,6 +4238,8 @@ void TPainter3dAlgorithms::SurfaceCylindrical(Int_t iordr, Int_t na, Int_t nb, c iz2 = nz - iz1 + 1; // D R A W S U R F A C E + icodes[2] = -1; // -1 for data, 0 for front a back boxes + fEdgeIdx = 0; // constant since stacks are not (yet?) handled for surfaces incr = 1; iphi = iphi1; L100: @@ -4164,7 +4314,7 @@ void TPainter3dAlgorithms::SurfaceSpherical(Int_t ipsdr, Int_t iordr, Int_t na, Int_t iphi, jphi, kphi, incr, nphi, iopt, iphi1, iphi2; Int_t i, j, incrth, ith, jth, kth, nth, mth, ith1, ith2; - Int_t ia, ib, icodes[2]; + Int_t ia, ib, icodes[3]; // was icode[2]. One element more to differentiate front & back boxes from data Double_t f[12] /* was [3][4] */; Double_t tt[4]; Double_t phi; @@ -4231,6 +4381,8 @@ void TPainter3dAlgorithms::SurfaceSpherical(Int_t ipsdr, Int_t iordr, Int_t na, } // D R A W S U R F A C E + icodes[2] = -1; // -1 for data, 0 for front a back boxes + fEdgeIdx = 0; // constant since stacks are not (yet?) handled for surfaces kth = nth; incr = 1; iphi = iphi1; @@ -5073,7 +5225,6 @@ void TPainter3dAlgorithms::MarchingCubeCase07(Int_t &nnod, Int_t &ntria, MarchingCubeSurfacePenetration(fF8[3], fF8[2], fF8[6], fF8[7], fF8[0], fF8[1], fF8[5], fF8[4], irep); if (irep != 2) goto L400; -/// IHMCTT(NTRIA,IT8,ITRIA) ntria = 9; icase = 9; diff --git a/hist/histpainter/src/TPaletteAxis.cxx b/hist/histpainter/src/TPaletteAxis.cxx index bb45c8665b4bb..95dd15140370f 100644 --- a/hist/histpainter/src/TPaletteAxis.cxx +++ b/hist/histpainter/src/TPaletteAxis.cxx @@ -119,6 +119,16 @@ TPaletteAxis::TPaletteAxis(const TPaletteAxis &palette) : TPave(palette) } +//______________________________________________________________________________ +TPaletteAxis& TPaletteAxis::operator=(const TPaletteAxis &orig) +{ + // Assignment operator. + + orig.Copy( *this ); + return *this; +} + + //______________________________________________________________________________ void TPaletteAxis::Copy(TObject &obj) const { diff --git a/html/src/TClassDocOutput.cxx b/html/src/TClassDocOutput.cxx index fc668e136c454..eada52eccb70e 100644 --- a/html/src/TClassDocOutput.cxx +++ b/html/src/TClassDocOutput.cxx @@ -1046,7 +1046,7 @@ Bool_t TClassDocOutput::CreateDotClassChartLib(const char* filename) { } outdot << "}" << endl; // dependencies } else - outdot << "\"No rlibmap information avaliable.\"" << endl; + outdot << "\"No rlibmap information available.\"" << endl; outdot << "}" << endl; // digraph diff --git a/html/src/TDocOutput.cxx b/html/src/TDocOutput.cxx index 04e55228da26f..caa8e9f41e9d9 100644 --- a/html/src/TDocOutput.cxx +++ b/html/src/TDocOutput.cxx @@ -1009,7 +1009,7 @@ void TDocOutput::CreateModuleIndex() std::set<std::string>& deps = libinfo->GetDependencies(); for (std::set<std::string>::iterator iDep = deps.begin(); - iDep != deps.end(); ++iDep) { + iDep != deps.end(); ) { Bool_t already_indirect = kFALSE; for (std::set<std::string>::const_iterator iDep2 = deps.begin(); !already_indirect && iDep2 != deps.end(); ++iDep2) { @@ -1022,8 +1022,11 @@ void TDocOutput::CreateModuleIndex() } if (already_indirect) { std::set<std::string>::iterator iRemove = iDep; - --iDep; // otherwise we cannot do the for loop's ++iDep - deps.erase(*iRemove); + // Advance the iterator before erasing the element which invalidates the iterator. + ++iDep; + deps.erase(iRemove); + } else { + ++iDep; } } // for library dependencies of module in library } // for libaries @@ -1516,21 +1519,33 @@ Bool_t TDocOutput::IsModified(TClass * classPtr, EFileType type) switch (type) { case kSource: - if (classPtr->GetImplFileLine()) { - fHtml->GetImplFileName(classPtr, kTRUE, sourceFile); - } else { - fHtml->GetDeclFileName(classPtr, kTRUE, sourceFile); + { + TString declFile; + if (classPtr->GetImplFileLine()) { + fHtml->GetImplFileName(classPtr, kTRUE, sourceFile); + } + fHtml->GetDeclFileName(classPtr, kTRUE, declFile); + Long64_t size; + Long_t id, flags, iModtime, dModtime; + if (!(gSystem->GetPathInfo(sourceFile, &id, &size, &flags, &iModtime))) { + if (!(gSystem->GetPathInfo(declFile, &id, &size, &flags, &dModtime))) { + if (iModtime < dModtime) { + // decl is newer than impl + sourceFile = declFile; + } + } + } + dir = "src"; + gSystem->PrependPathName(fHtml->GetOutputDir(), dir); + filename = classname; + NameSpace2FileName(filename); + gSystem->PrependPathName(dir, filename); + if (classPtr->GetImplFileLine()) + filename += ".cxx.html"; + else + filename += ".h.html"; + break; } - dir = "src"; - gSystem->PrependPathName(fHtml->GetOutputDir(), dir); - filename = classname; - NameSpace2FileName(filename); - gSystem->PrependPathName(dir, filename); - if (classPtr->GetImplFileLine()) - filename += ".cxx.html"; - else - filename += ".h.html"; - break; case kInclude: fHtml->GetDeclFileName(classPtr, kFALSE, filename); @@ -1548,16 +1563,28 @@ Bool_t TDocOutput::IsModified(TClass * classPtr, EFileType type) break; case kDoc: - if (classPtr->GetImplFileLine()) { - fHtml->GetImplFileName(classPtr, kTRUE, sourceFile); - } else { - fHtml->GetDeclFileName(classPtr, kTRUE, sourceFile); + { + TString declFile; + if (classPtr->GetImplFileLine()) { + fHtml->GetImplFileName(classPtr, kTRUE, sourceFile); + } + fHtml->GetDeclFileName(classPtr, kTRUE, declFile); + Long64_t size; + Long_t id, flags, iModtime, dModtime; + if (!(gSystem->GetPathInfo(sourceFile, &id, &size, &flags, &iModtime))) { + if (!(gSystem->GetPathInfo(declFile, &id, &size, &flags, &dModtime))) { + if (iModtime < dModtime) { + // decl is newer than impl + sourceFile = declFile; + } + } + } + filename = classname; + NameSpace2FileName(filename); + gSystem->PrependPathName(fHtml->GetOutputDir(), filename); + filename += ".html"; + break; } - filename = classname; - NameSpace2FileName(filename); - gSystem->PrependPathName(fHtml->GetOutputDir(), filename); - filename += ".html"; - break; default: Error("IsModified", "Unknown file type !"); @@ -1569,9 +1596,11 @@ Bool_t TDocOutput::IsModified(TClass * classPtr, EFileType type) Long64_t size; Long_t id, flags, sModtime, dModtime; - if (!(gSystem->GetPathInfo(sourceFile, &id, &size, &flags, &sModtime))) - if (!(gSystem->GetPathInfo(filename, &id, &size, &flags, &dModtime))) + if (!(gSystem->GetPathInfo(sourceFile, &id, &size, &flags, &sModtime))) { + if (!(gSystem->GetPathInfo(filename, &id, &size, &flags, &dModtime))) { return (sModtime > dModtime); + } + } return kTRUE; } diff --git a/html/src/THtml.cxx b/html/src/THtml.cxx index c7cccd10710d8..1dcf122d0103e 100644 --- a/html/src/THtml.cxx +++ b/html/src/THtml.cxx @@ -310,11 +310,13 @@ TString THtml::TFileDefinition::MatchFileSysName(TString& filename, TFileSysEntr if (!filename.EndsWith(fsentry->GetName())) continue; fsentry->GetFullName(filesysname, kTRUE); // get the short version + filename = filesysname; if (!filename.EndsWith(filesysname)) { - filesysname = ""; + // It's something - let's see whether we find something better + // else leave it as plan B. This helps finding Reflex sources. + //filesysname = ""; continue; } - filename = filesysname; fsentry->GetFullName(filesysname, kFALSE); // get the long version if (fse) *fse = fsentry; break; @@ -785,7 +787,7 @@ These are typical things people do with THtml: or to run on just a few classes: <pre> root[] <a href="http://root.cern.ch/root/html/THtml.html">THtml</a> html; // create a <a href="http://root.cern.ch/root/html/THtml.html">THtml</a> object - root[] html.MakeIndex(); // create auxilliary files (style sheet etc) and indices + root[] html.MakeIndex(); // create auxiliary files (style sheet etc) and indices root[] html.MakeClass("TMyClass"); // create documentation for TMyClass only </pre> To "beautify" (i.e. create links to documentation for class names etc) some text @@ -2396,7 +2398,7 @@ void THtml::MakeTree(const char *className, Bool_t force) //______________________________________________________________________________ void THtml::SetFoundDot(Bool_t found) { - // Set whether "dot" (a GraphViz utility) is avaliable + // Set whether "dot" (a GraphViz utility) is available if (found) fPathInfo.fFoundDot = PathInfo_t::kDotFound; else fPathInfo.fFoundDot = PathInfo_t::kDotNotFound; } diff --git a/icons/arc.xpm b/icons/arc.xpm index 8cf5e5e7cc125..9e54a7923e09b 100644 --- a/icons/arc.xpm +++ b/icons/arc.xpm @@ -1,21 +1,21 @@ -/* XPM */ -static char *arc[]={ -"16 16 2 1", -". c None", -"# c #303030", -"................", -"................", -"................", -"................", -"................", -"................", -"....#######.....", -"..##......##....", -".##.............", -".#..............", -".#..............", -".##.............", -"..###...........", -"....##..........", -"................", -"................"}; +/* XPM */ +static char *arc[]={ +"16 16 2 1", +". c None", +"# c #303030", +"................", +"................", +"................", +"................", +"................", +"................", +"....#######.....", +"..##......##....", +".##.............", +".#..............", +".#..............", +".##.............", +"..###...........", +"....##..........", +"................", +"................"}; diff --git a/icons/checkmark_t.xpm b/icons/checkmark_t.xpm index a7be89b0b419c..f1bd72dcf37e3 100644 --- a/icons/checkmark_t.xpm +++ b/icons/checkmark_t.xpm @@ -1,23 +1,23 @@ -/* XPM */ -static char * checkmark_t_xpm[] = { -"16 16 4 1", -" c None", -". c #808080", -"+ c #ffffff", -"X c Black", -" ", -" ", -" ", -" ", -" + ", -" +X+ ", -" + +XX+ ", -" +X+ +XXX+ ", -" +XX+XXX+ ", -" +XXXXX+ ", -" +XXX+ ", -" +X+ ", -" + ", -" ", -" ", -" "}; +/* XPM */ +static char * checkmark_t_xpm[] = { +"16 16 4 1", +" c None", +". c #808080", +"+ c #ffffff", +"X c Black", +" ", +" ", +" ", +" ", +" + ", +" +X+ ", +" + +XX+ ", +" +X+ +XXX+ ", +" +XX+XXX+ ", +" +XXXXX+ ", +" +XXX+ ", +" +X+ ", +" + ", +" ", +" ", +" "}; diff --git a/icons/cut.xpm b/icons/cut.xpm index 9f2768330cbf8..63fcb5ea80ce7 100644 --- a/icons/cut.xpm +++ b/icons/cut.xpm @@ -1,21 +1,21 @@ -/* XPM */ -static char *cut[]={ -"16 16 2 1", -". c None", -"# c #000000", -".#####..........", -".#...##.....###.", -".#....#...######", -".###.##..#####..", -"..#####.####....", -"....#######.....", -"#######.########", -"....######......", -"..#####.#..#....", -".###.##...####..", -".#....#...######", -".#...##.....###.", -".#####..........", -"................", -"................", -"................"}; +/* XPM */ +static char *cut[]={ +"16 16 2 1", +". c None", +"# c #000000", +".#####..........", +".#...##.....###.", +".#....#...######", +".###.##..#####..", +"..#####.####....", +"....#######.....", +"#######.########", +"....######......", +"..#####.#..#....", +".###.##...####..", +".#....#...######", +".#...##.....###.", +".#####..........", +"................", +"................", +"................"}; diff --git a/icons/eve_rnr01_t.xpm b/icons/eve_rnr01_t.xpm index 61e35038bbc3d..fcef7af011b8f 100644 --- a/icons/eve_rnr01_t.xpm +++ b/icons/eve_rnr01_t.xpm @@ -1,23 +1,23 @@ -/* XPM */ -static char * checked_dis_xpm[] = { -"16 16 4 1", -" c None", -". c #808080", -"X c Black", -"o c #c0c0c0", -" ", -" ", -" ............ ", -" .XXXXXXXXXXo ", -" .Xoooooooooo ", -" .Xooooooo.oo ", -" .Xoooooo..oo ", -" .Xo.ooo...oo ", -" .Xo..o...ooo ", -" .Xo.....oooo ", -" .Xoo...ooooo ", -" .Xooo.oooooo ", -" .Xoooooooooo ", -" .ooooooooooo ", -" ", -" "}; +/* XPM */ +static char * checked_dis_xpm[] = { +"16 16 4 1", +" c None", +". c #808080", +"X c Black", +"o c #c0c0c0", +" ", +" ", +" ............ ", +" .XXXXXXXXXXo ", +" .Xoooooooooo ", +" .Xooooooo.oo ", +" .Xoooooo..oo ", +" .Xo.ooo...oo ", +" .Xo..o...ooo ", +" .Xo.....oooo ", +" .Xoo...ooooo ", +" .Xooo.oooooo ", +" .Xoooooooooo ", +" .ooooooooooo ", +" ", +" "}; diff --git a/icons/leaf_method_s.xpm b/icons/leaf_method_s.xpm index 3c73f8da55646..6aba96e59d217 100644 --- a/icons/leaf_method_s.xpm +++ b/icons/leaf_method_s.xpm @@ -1,52 +1,52 @@ -/* XPM */ -static char * leaf_method_s_xpm[] = { -"32 32 17 1", -" c None", -". c #808000", -"+ c #008000", -"@ c #008080", -"# c #000000", -"$ c #F31313", -"% c #808080", -"& c #EE1717", -"* c #E81712", -"= c #DC1D1D", -"- c #DB1D1D", -"; c #E12310", -"> c #E02424", -", c #C0290F", -"' c #DA2A2A", -") c #B2300D", -"! c #D43030", -" ", -" ", -" .+ ", -" +++ ", -" ++@.### $$$ ", -" @@+@+@#+@$$$ ", -" @+@+@+@$$$ ", -" @@%@.@+$$$ @ ", -" +.+.@+@+@$$$+@# ", -" ++++%@+@@$$$@.@# ", -" ++@%@.@$$$@++# ", -" @@+@%@+$$$+++#@ @ ", -" ++.+++.@%%$$$@++.+@# ", -" @@++@+..%$$$.@++@.@ ", -" ..++.++.@&$*@+@+..# @.@ ", -" ..+..@.=$-.@.@+## +@+# ", -" ++++...++;$>@+@++@ @@@@# ", -" @@+.@.+.@,$'%@+@.@@.@+@# ", -" ++.+.+.)$!%%@+@@+@@@+# ", -" @+...+...%%+@+@@.@.@ ", -" +++++++...+...++%@+@@@@+@@. ", -" ++@@++@.+.@.+...%@+@@@@.+.# ", -" +++++.+.+.$$$.+.%@+@+@.+## ", -" ..+.@.+$$$++.@%@.@...# ", -" @.++.+.$$$..@+@%@.+### ", -" .+.+..$$$@@++.@%@.# ", -" ++.+.+.++..+.### ", -" ......+@..++....%.+ ", -" ..+@+++@+++..##.%.+ ", -" .....+.+....# %.+. ", -" .@.@@@..# .+## ", -" ####### ## "}; +/* XPM */ +static char * leaf_method_s_xpm[] = { +"32 32 17 1", +" c None", +". c #808000", +"+ c #008000", +"@ c #008080", +"# c #000000", +"$ c #F31313", +"% c #808080", +"& c #EE1717", +"* c #E81712", +"= c #DC1D1D", +"- c #DB1D1D", +"; c #E12310", +"> c #E02424", +", c #C0290F", +"' c #DA2A2A", +") c #B2300D", +"! c #D43030", +" ", +" ", +" .+ ", +" +++ ", +" ++@.### $$$ ", +" @@+@+@#+@$$$ ", +" @+@+@+@$$$ ", +" @@%@.@+$$$ @ ", +" +.+.@+@+@$$$+@# ", +" ++++%@+@@$$$@.@# ", +" ++@%@.@$$$@++# ", +" @@+@%@+$$$+++#@ @ ", +" ++.+++.@%%$$$@++.+@# ", +" @@++@+..%$$$.@++@.@ ", +" ..++.++.@&$*@+@+..# @.@ ", +" ..+..@.=$-.@.@+## +@+# ", +" ++++...++;$>@+@++@ @@@@# ", +" @@+.@.+.@,$'%@+@.@@.@+@# ", +" ++.+.+.)$!%%@+@@+@@@+# ", +" @+...+...%%+@+@@.@.@ ", +" +++++++...+...++%@+@@@@+@@. ", +" ++@@++@.+.@.+...%@+@@@@.+.# ", +" +++++.+.+.$$$.+.%@+@+@.+## ", +" ..+.@.+$$$++.@%@.@...# ", +" @.++.+.$$$..@+@%@.+### ", +" .+.+..$$$@@++.@%@.# ", +" ++.+.+.++..+.### ", +" ......+@..++....%.+ ", +" ..+@+++@+++..##.%.+ ", +" .....+.+....# %.+. ", +" .@.@@@..# .+## ", +" ####### ## "}; diff --git a/icons/leaf_method_t.xpm b/icons/leaf_method_t.xpm index d7d70e3fcd790..aaa8bc8b918fe 100644 --- a/icons/leaf_method_t.xpm +++ b/icons/leaf_method_t.xpm @@ -1,32 +1,32 @@ -/* XPM */ -static char * leaf_method_t_xpm[] = { -"16 16 13 1", -" c None", -". c #008000", -"+ c #F31313", -"@ c #008080", -"# c #000000", -"$ c #C0C0C0", -"% c #808000", -"& c #F11919", -"* c #EE1712", -"= c #E71E11", -"- c #EE2323", -"; c #CA250F", -"> c #EB2E2E", -" ", -" .. ++ ", -" @..#@++ ", -" @$..++@ ", -" ..$.@++@ ", -" @.$.++.@@ ", -" @@@%$++.@@ ", -" %...&*..#.. ", -" @.@.@=-.%@@@ ", -" .%.;>..@@@ ", -" .@.@.@.%$@@@.# ", -" %.@.%.@$%%@ ", -" ..%++.%$@ ", -" ..%.++.%$. ", -" %%..%% .. ", -" ### .# "}; +/* XPM */ +static char * leaf_method_t_xpm[] = { +"16 16 13 1", +" c None", +". c #008000", +"+ c #F31313", +"@ c #008080", +"# c #000000", +"$ c #C0C0C0", +"% c #808000", +"& c #F11919", +"* c #EE1712", +"= c #E71E11", +"- c #EE2323", +"; c #CA250F", +"> c #EB2E2E", +" ", +" .. ++ ", +" @..#@++ ", +" @$..++@ ", +" ..$.@++@ ", +" @.$.++.@@ ", +" @@@%$++.@@ ", +" %...&*..#.. ", +" @.@.@=-.%@@@ ", +" .%.;>..@@@ ", +" .@.@.@.%$@@@.# ", +" %.@.%.@$%%@ ", +" ..%++.%$@ ", +" ..%.++.%$. ", +" %%..%% .. ", +" ### .# "}; diff --git a/icons/mdi_close.xpm b/icons/mdi_close.xpm index 3ce8285a7554b..f4eb979f056db 100644 --- a/icons/mdi_close.xpm +++ b/icons/mdi_close.xpm @@ -1,15 +1,15 @@ -/* XPM */ -static char * closeButtonIconData[] = { -"9 9 2 1", -" c None s None", -". c #000000", -" ", -" .. ..", -" .. .. ", -" .... ", -" .. ", -" .... ", -" .. .. ", -" .. ..", -" "}; - +/* XPM */ +static char * closeButtonIconData[] = { +"9 9 2 1", +" c None s None", +". c #000000", +" ", +" .. ..", +" .. .. ", +" .... ", +" .. ", +" .... ", +" .. .. ", +" .. ..", +" "}; + diff --git a/icons/mdi_default.xpm b/icons/mdi_default.xpm index 3ec01667b1d7d..8556c89b5dfee 100644 --- a/icons/mdi_default.xpm +++ b/icons/mdi_default.xpm @@ -1,25 +1,25 @@ -/* XPM */ -static char * defaultMdiIconData[] = { -"16 16 5 1", -" s None c None", -". c #808080", -"X c white", -"o c #c0c0c0", -"O c black", -" .......... ", -" .XXXXXXXXo. ", -" .XXXXXXXXoX. ", -" .XXXXXXXXOOOO ", -" .XXXXXXXXXXoO ", -" .XXXXXXXXXXoO ", -" .XXXXXXXXXXoO ", -" .XXXXXXXXXXoO ", -" .XXXXXXXXXXoO ", -" .XXXXXXXXXXoO ", -" .XXXXXXXXXXoO ", -" .XXXXXXXXXXoO ", -" .XXXXXXXXXXoO ", -" .XXXXXXXXXXoO ", -" .oooooooooooO ", -" OOOOOOOOOOOOO "}; - +/* XPM */ +static char * defaultMdiIconData[] = { +"16 16 5 1", +" s None c None", +". c #808080", +"X c white", +"o c #c0c0c0", +"O c black", +" .......... ", +" .XXXXXXXXo. ", +" .XXXXXXXXoX. ", +" .XXXXXXXXOOOO ", +" .XXXXXXXXXXoO ", +" .XXXXXXXXXXoO ", +" .XXXXXXXXXXoO ", +" .XXXXXXXXXXoO ", +" .XXXXXXXXXXoO ", +" .XXXXXXXXXXoO ", +" .XXXXXXXXXXoO ", +" .XXXXXXXXXXoO ", +" .XXXXXXXXXXoO ", +" .XXXXXXXXXXoO ", +" .oooooooooooO ", +" OOOOOOOOOOOOO "}; + diff --git a/icons/mdi_help.xpm b/icons/mdi_help.xpm index bc0df059e0f07..5605917da4f89 100644 --- a/icons/mdi_help.xpm +++ b/icons/mdi_help.xpm @@ -1,15 +1,15 @@ -/* XPM */ -static char * helpButtonIconData[] = { -"9 9 2 1", -" c None s None", -". c #000000", -" ..... ", -" ... ... ", -" .. .. ", -" .. ", -" .. ", -" .. ", -" ", -" .. ", -" .. "}; - +/* XPM */ +static char * helpButtonIconData[] = { +"9 9 2 1", +" c None s None", +". c #000000", +" ..... ", +" ... ... ", +" .. .. ", +" .. ", +" .. ", +" .. ", +" ", +" .. ", +" .. "}; + diff --git a/icons/mdi_maximize.xpm b/icons/mdi_maximize.xpm index ac51ed8e79527..1b10f701c02ff 100644 --- a/icons/mdi_maximize.xpm +++ b/icons/mdi_maximize.xpm @@ -1,15 +1,15 @@ -/* XPM */ -static char * maximizeButtonIconData[] = { -"9 9 2 1", -" c None s None", -". c #000000", -"......... ", -"......... ", -". . ", -". . ", -". . ", -". . ", -". . ", -". . ", -"......... "}; - +/* XPM */ +static char * maximizeButtonIconData[] = { +"9 9 2 1", +" c None s None", +". c #000000", +"......... ", +"......... ", +". . ", +". . ", +". . ", +". . ", +". . ", +". . ", +"......... "}; + diff --git a/icons/mdi_minimize.xpm b/icons/mdi_minimize.xpm index 5bcbdfb756180..c922a7a9f956b 100644 --- a/icons/mdi_minimize.xpm +++ b/icons/mdi_minimize.xpm @@ -1,15 +1,15 @@ -/* XPM */ -static char * minimizeButtonIconData[] = { -"9 9 2 1", -" c None s None", -". c #000000", -" ", -" ", -" ", -" ", -" ", -" ", -" ", -" ...... ", -" ...... "}; - +/* XPM */ +static char * minimizeButtonIconData[] = { +"9 9 2 1", +" c None s None", +". c #000000", +" ", +" ", +" ", +" ", +" ", +" ", +" ", +" ...... ", +" ...... "}; + diff --git a/icons/mdi_restore.xpm b/icons/mdi_restore.xpm index 3d679a321192e..af215d06eca54 100644 --- a/icons/mdi_restore.xpm +++ b/icons/mdi_restore.xpm @@ -1,15 +1,15 @@ -/* XPM */ -static char * restoreButtonIconData[] = { -"9 9 2 1", -" c None s None", -". c #000000", -" ...... ", -" ...... ", -" . . ", -" ...... . ", -" ...... . ", -" . ... ", -" . . ", -" . . ", -" ...... "}; - +/* XPM */ +static char * restoreButtonIconData[] = { +"9 9 2 1", +" c None s None", +". c #000000", +" ...... ", +" ...... ", +" . . ", +" ...... . ", +" ...... . ", +" . ... ", +" . . ", +" . . ", +" ...... "}; + diff --git a/icons/pdf.xpm b/icons/pdf.xpm index 66055ae20b672..d5745e87d48e3 100644 --- a/icons/pdf.xpm +++ b/icons/pdf.xpm @@ -1,41 +1,41 @@ -/* XPM */ -static char * pdf_xpm[] = { -"32 32 6 1", -" s None c None", -". c #808080", -"X c white", -"o c black", -"O c #c0c0c0", -"+ c #ff0000", -" ................... ", -" .XXXXXXXXXXXXXXXXX.o ", -" .XXXXXXXXXXXXXXXXX..o ", -" .XXXXXXXXXXXXXXXXX.O.o ", -" .XXXXXXXXXXXXXXXXX.XO.o ", -" .XXXXXXXXXXXXXXXXX.XXO.o ", -" .XXXXXXXXX+XXXXXXX.oooooo ", -" .XXXXXXXX+X+XXXXXXXXXXXOo ", -" .XXXXXXXX+X+.XXXXXXXXXXOo ", -" .XXXXXX.X+X+XXX.XXXXXXXOo ", -" .XXXXXXXX+++XXXXXXXXXXXOo ", -" .XXXX.XXXX++XXXXX.XXXXXOo ", -" .XXXXXXXXX++XXXXXXXXXXXOo ", -" .XXXXXXXXX+++XXXXXXXXXXOo ", -" .XXX.XXXXO+X++XXXX.XXXXOo ", -" .XXXXXXXX++XX++OXXXXXXXOo ", -" .XXXXXXXX+OXXXX++++++XXOo ", -" .XXX.XXXO+XXX+++++XXX+XOo ", -" .XXXXXXX++X+++XXXX+++XXOo ", -" .XXXXXXX++++XXXXXXXXXXXOo ", -" .XXXX.X++OXXXXXXX.XXXXXOo ", -" .XXXXX++XXXXXXXXXXXXXXXOo ", -" .XXX++++XXXXXXX.XXXXXXXOo ", -" .XX++X+XX.XX.XXXXXXXXXXOo ", -" .XX+XX+XXXXXXXXXXXXXXXXOo ", -" .XXX++XXXXXXXXXXXXXXXXXOo ", -" .XXXXXXXXXXXXXXXXXXXXXXOo ", -" .XXXXXXXXXXXXXXXXXXXXXXOo ", -" .XXXXXXXXXXXXXXXXXXXXXXOo ", -" .XXXXXXXXXXXXXXXXXXXXXXOo ", -" .OOOOOOOOOOOOOOOOOOOOOOOo ", -" ooooooooooooooooooooooooo "}; +/* XPM */ +static char * pdf_xpm[] = { +"32 32 6 1", +" s None c None", +". c #808080", +"X c white", +"o c black", +"O c #c0c0c0", +"+ c #ff0000", +" ................... ", +" .XXXXXXXXXXXXXXXXX.o ", +" .XXXXXXXXXXXXXXXXX..o ", +" .XXXXXXXXXXXXXXXXX.O.o ", +" .XXXXXXXXXXXXXXXXX.XO.o ", +" .XXXXXXXXXXXXXXXXX.XXO.o ", +" .XXXXXXXXX+XXXXXXX.oooooo ", +" .XXXXXXXX+X+XXXXXXXXXXXOo ", +" .XXXXXXXX+X+.XXXXXXXXXXOo ", +" .XXXXXX.X+X+XXX.XXXXXXXOo ", +" .XXXXXXXX+++XXXXXXXXXXXOo ", +" .XXXX.XXXX++XXXXX.XXXXXOo ", +" .XXXXXXXXX++XXXXXXXXXXXOo ", +" .XXXXXXXXX+++XXXXXXXXXXOo ", +" .XXX.XXXXO+X++XXXX.XXXXOo ", +" .XXXXXXXX++XX++OXXXXXXXOo ", +" .XXXXXXXX+OXXXX++++++XXOo ", +" .XXX.XXXO+XXX+++++XXX+XOo ", +" .XXXXXXX++X+++XXXX+++XXOo ", +" .XXXXXXX++++XXXXXXXXXXXOo ", +" .XXXX.X++OXXXXXXX.XXXXXOo ", +" .XXXXX++XXXXXXXXXXXXXXXOo ", +" .XXX++++XXXXXXX.XXXXXXXOo ", +" .XX++X+XX.XX.XXXXXXXXXXOo ", +" .XX+XX+XXXXXXXXXXXXXXXXOo ", +" .XXX++XXXXXXXXXXXXXXXXXOo ", +" .XXXXXXXXXXXXXXXXXXXXXXOo ", +" .XXXXXXXXXXXXXXXXXXXXXXOo ", +" .XXXXXXXXXXXXXXXXXXXXXXOo ", +" .XXXXXXXXXXXXXXXXXXXXXXOo ", +" .OOOOOOOOOOOOOOOOOOOOOOOo ", +" ooooooooooooooooooooooooo "}; diff --git a/icons/return_object_s.xpm b/icons/return_object_s.xpm index 63f78ac4f9cd8..daf5f787c554e 100644 --- a/icons/return_object_s.xpm +++ b/icons/return_object_s.xpm @@ -1,52 +1,52 @@ -/* XPM */ -static char * return_object_s_xpm[] = { -"32 32 17 1", -" c None", -". c #808080", -"+ c #FFFFFF", -"@ c #F31313", -"# c #FFFF00", -"$ c #C0C0C0", -"% c #000000", -"& c #808000", -"* c #F11919", -"= c #F01A1A", -"- c #F42911", -"; c #F42A11", -"> c #EB2D2D", -", c #EB2E2E", -"' c #F5440F", -") c #F5440E", -"! c #E54141", -" ", -" ", -" ", -" ......... ", -" .+++++++++.@@@ ", -" .+#$#$#$#$#$@@@ ", -" .+#$#$#$#$#$#@@@ ", -".$$$$$$$$$$$$$@@@.............% ", -".+++++++++++++@@@+++++++++++++%%", -".+#$#$#$#$#$#$@@@$#$#$#$#$#$#$&%", -".+$#$#$#$#$#$#@@@#$#$#$#$#$#$#&%", -".+#$#$#$#$#$#$@@@$#$#$#$#$#$#$&%", -".+$#$#$#$#$#$#@@@#$#$#$#$#$#$#&%", -".+#$#$#$#$#$#$@@@$#$#$#$#$#$#$&%", -".+$#$#$#$#$#$#*@=#$#$#$#$#$#$#&%", -".+#$#$#$#$#$#$-@;$#$#$#$#$#$#$&%", -".+$#$#$#$#$#$#>@,#$#$#$#$#$#$#&%", -".+#$#$#$#$#$#$'@)$#$#$#$#$#$#$&%", -".+$#$#$#$#$#$#!@!#$#$#$#$#$#$#&%", -".+#$#$#$#$#$#$#$#$#$#$#$#$#$#$&%", -".+$#$#$#$#$#$#$#$#$#$#$#$#$#$#&%", -".+#$#$#$#$#$#$#$#$#$#$#$#$#$#$&%", -".+$#$#$#$#$#$#@@@#$#$#$#$#$#$#&%", -".+#$#$#$#$#$#$@@@$#$#$#$#$#$#$&%", -".+$#$#$#$#$#$#@@@#$#$#$#$#$#$#&%", -".+#$#$#$#$#$#$@@@$#$#$#$#$#$#$&%", -".+$#$#$#$#$#$#$#$#$#$#$#$#$#$#&%", -".+#$#$#$#$#$#$#$#$#$#$#$#$#$#$&%", -".&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&%", -" %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ", -" ", -" "}; +/* XPM */ +static char * return_object_s_xpm[] = { +"32 32 17 1", +" c None", +". c #808080", +"+ c #FFFFFF", +"@ c #F31313", +"# c #FFFF00", +"$ c #C0C0C0", +"% c #000000", +"& c #808000", +"* c #F11919", +"= c #F01A1A", +"- c #F42911", +"; c #F42A11", +"> c #EB2D2D", +", c #EB2E2E", +"' c #F5440F", +") c #F5440E", +"! c #E54141", +" ", +" ", +" ", +" ......... ", +" .+++++++++.@@@ ", +" .+#$#$#$#$#$@@@ ", +" .+#$#$#$#$#$#@@@ ", +".$$$$$$$$$$$$$@@@.............% ", +".+++++++++++++@@@+++++++++++++%%", +".+#$#$#$#$#$#$@@@$#$#$#$#$#$#$&%", +".+$#$#$#$#$#$#@@@#$#$#$#$#$#$#&%", +".+#$#$#$#$#$#$@@@$#$#$#$#$#$#$&%", +".+$#$#$#$#$#$#@@@#$#$#$#$#$#$#&%", +".+#$#$#$#$#$#$@@@$#$#$#$#$#$#$&%", +".+$#$#$#$#$#$#*@=#$#$#$#$#$#$#&%", +".+#$#$#$#$#$#$-@;$#$#$#$#$#$#$&%", +".+$#$#$#$#$#$#>@,#$#$#$#$#$#$#&%", +".+#$#$#$#$#$#$'@)$#$#$#$#$#$#$&%", +".+$#$#$#$#$#$#!@!#$#$#$#$#$#$#&%", +".+#$#$#$#$#$#$#$#$#$#$#$#$#$#$&%", +".+$#$#$#$#$#$#$#$#$#$#$#$#$#$#&%", +".+#$#$#$#$#$#$#$#$#$#$#$#$#$#$&%", +".+$#$#$#$#$#$#@@@#$#$#$#$#$#$#&%", +".+#$#$#$#$#$#$@@@$#$#$#$#$#$#$&%", +".+$#$#$#$#$#$#@@@#$#$#$#$#$#$#&%", +".+#$#$#$#$#$#$@@@$#$#$#$#$#$#$&%", +".+$#$#$#$#$#$#$#$#$#$#$#$#$#$#&%", +".+#$#$#$#$#$#$#$#$#$#$#$#$#$#$&%", +".&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&%", +" %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ", +" ", +" "}; diff --git a/icons/return_object_t.xpm b/icons/return_object_t.xpm index 4ca73d7659089..6cf52f378004b 100644 --- a/icons/return_object_t.xpm +++ b/icons/return_object_t.xpm @@ -1,32 +1,32 @@ -/* XPM */ -static char * return_object_t_xpm[] = { -"16 16 13 1", -" c None", -". c #808080", -"+ c #F31313", -"@ c #C0C0C0", -"# c #FFFF00", -"$ c #FFFFFF", -"% c #000000", -"& c #F31C12", -"* c #F11919", -"= c #ED2424", -"- c #F42A11", -"; c #F53A0F", -"> c #EB2E2E", -" ", -" ....++ ", -" .@#@#++ ", -" .@#@#@++...... ", -" .$$$$$++$$$$$.%", -" .$#@#@++#@#@#.%", -" .$@#@#++@#@#@.%", -" .$#@#@&*#@#@#.%", -" .$@#@#=-@#@#@.%", -" .$#@#@;>#@#@#.%", -" .$@#@#@#@#@#@.%", -" .$#@#@#@#@#@#.%", -" ......++......%", -" %%%%%++%%%%%%%", -" ", -" "}; +/* XPM */ +static char * return_object_t_xpm[] = { +"16 16 13 1", +" c None", +". c #808080", +"+ c #F31313", +"@ c #C0C0C0", +"# c #FFFF00", +"$ c #FFFFFF", +"% c #000000", +"& c #F31C12", +"* c #F11919", +"= c #ED2424", +"- c #F42A11", +"; c #F53A0F", +"> c #EB2E2E", +" ", +" ....++ ", +" .@#@#++ ", +" .@#@#@++...... ", +" .$$$$$++$$$$$.%", +" .$#@#@++#@#@#.%", +" .$@#@#++@#@#@.%", +" .$#@#@&*#@#@#.%", +" .$@#@#=-@#@#@.%", +" .$#@#@;>#@#@#.%", +" .$@#@#@#@#@#@.%", +" .$#@#@#@#@#@#.%", +" ......++......%", +" %%%%%++%%%%%%%", +" ", +" "}; diff --git a/icons/rotate.png b/icons/rotate.png new file mode 100644 index 0000000000000..db479714fa9bc Binary files /dev/null and b/icons/rotate.png differ diff --git a/icons/slider1h.xpm b/icons/slider1h.xpm index 7f3c7627ae862..79f02b886392e 100644 --- a/icons/slider1h.xpm +++ b/icons/slider1h.xpm @@ -1,23 +1,23 @@ -/* XPM */ -static char *cursorv_xpm[] = { -/* width height num_colors chars_per_pixel */ -" 14 11 5 2", -/* colors */ -"`` c None s None", -"`. c #000000", -"`# c #ffffff", -"`a c #c0c0c0", -"`b c #808080", -/* pixels */ -"`#`#`#`#`#`#`#`#`#``````````", -"`#`a`a`a`a`a`a`a`a`#````````", -"`#`#`a`a`a`#`a`a`a`a`#``````", -"`#`a`.`a`a`a`.`a`a`a`a`#````", -"`#`a`a`#`a`a`a`a`a`a`a`a`#``", -"`#`a`a`a`.`a`a`a`a`a`a`a`a`.", -"`#`#`a`a`a`#`a`a`a`a`a`b`.``", -"`#`a`.`a`a`a`.`a`a`a`b`.````", -"`#`a`a`a`a`a`a`a`a`b`.``````", -"`#`b`b`b`b`b`b`b`b`.````````", -"`.`.`.`.`.`.`.`.`.``````````" -}; +/* XPM */ +static char *cursorv_xpm[] = { +/* width height num_colors chars_per_pixel */ +" 14 11 5 2", +/* colors */ +"`` c None s None", +"`. c #000000", +"`# c #ffffff", +"`a c #c0c0c0", +"`b c #808080", +/* pixels */ +"`#`#`#`#`#`#`#`#`#``````````", +"`#`a`a`a`a`a`a`a`a`#````````", +"`#`#`a`a`a`#`a`a`a`a`#``````", +"`#`a`.`a`a`a`.`a`a`a`a`#````", +"`#`a`a`#`a`a`a`a`a`a`a`a`#``", +"`#`a`a`a`.`a`a`a`a`a`a`a`a`.", +"`#`#`a`a`a`#`a`a`a`a`a`b`.``", +"`#`a`.`a`a`a`.`a`a`a`b`.````", +"`#`a`a`a`a`a`a`a`a`b`.``````", +"`#`b`b`b`b`b`b`b`b`.````````", +"`.`.`.`.`.`.`.`.`.``````````" +}; diff --git a/icons/slider1v.xpm b/icons/slider1v.xpm index 65b90c6b6cac9..2b1ceb8e8588d 100644 --- a/icons/slider1v.xpm +++ b/icons/slider1v.xpm @@ -1,26 +1,26 @@ -/* XPM */ -static char *cursorh_xpm[] = { -/* width height num_colors chars_per_pixel */ -" 11 14 5 2", -/* colors */ -"`` c None s None", -"`. c #000000", -"`# c #ffffff", -"`a c #c0c0c0", -"`b c #808080", -/* pixels */ -"`#`#`#`#`#`#`#`#`#`#`.", -"`#`a`#`a`a`a`#`a`a`b`.", -"`#`a`a`.`a`a`a`.`a`b`.", -"`#`a`a`a`#`a`a`a`a`b`.", -"`#`a`a`a`a`.`a`a`a`b`.", -"`#`a`#`a`a`a`#`a`a`b`.", -"`#`a`a`.`a`a`a`.`a`b`.", -"`#`a`a`a`a`a`a`a`a`b`.", -"`#`a`a`a`a`a`a`a`a`b`.", -"```#`a`a`a`a`a`a`b`.``", -"`````#`a`a`a`a`b`.````", -"```````#`a`a`b`.``````", -"`````````#`a`.````````", -"```````````.``````````" -}; +/* XPM */ +static char *cursorh_xpm[] = { +/* width height num_colors chars_per_pixel */ +" 11 14 5 2", +/* colors */ +"`` c None s None", +"`. c #000000", +"`# c #ffffff", +"`a c #c0c0c0", +"`b c #808080", +/* pixels */ +"`#`#`#`#`#`#`#`#`#`#`.", +"`#`a`#`a`a`a`#`a`a`b`.", +"`#`a`a`.`a`a`a`.`a`b`.", +"`#`a`a`a`#`a`a`a`a`b`.", +"`#`a`a`a`a`.`a`a`a`b`.", +"`#`a`#`a`a`a`#`a`a`b`.", +"`#`a`a`.`a`a`a`.`a`b`.", +"`#`a`a`a`a`a`a`a`a`b`.", +"`#`a`a`a`a`a`a`a`a`b`.", +"```#`a`a`a`a`a`a`b`.``", +"`````#`a`a`a`a`b`.````", +"```````#`a`a`b`.``````", +"`````````#`a`.````````", +"```````````.``````````" +}; diff --git a/icons/tb_find.xpm b/icons/tb_find.xpm index 2a2b60e56a7ba..465005f323d49 100644 --- a/icons/tb_find.xpm +++ b/icons/tb_find.xpm @@ -1,65 +1,65 @@ -/* XPM */ -static char *asxpm[] = { -/* columns rows colors chars-per-pixel */ -"16 16 44 1", -" c #010101", -". c #002020", -"X c #232323", -"o c #303031", -"O c #21205F", -"+ c #003F7F", -"@ c #303070", -"# c #004040", -"$ c #204040", -"% c #236161", -"& c #434343", -"* c #505050", -"= c #666666", -"- c #000386", -"; c #0007C2", -": c #003FDF", -"> c #50508F", -", c #407F80", -"< c #7F7F80", -"1 c #0342E6", -"2 c #018080", -"3 c #7F8280", -"4 c #41A0A0", -"5 c #70AFAF", -"6 c #7FBFBF", -"7 c #508FD6", -"8 c #01C0FF", -"9 c #61E2E2", -"0 c #72F2F2", -"q c #9F9F9F", -"w c #A6A6A6", -"e c #BFBFBF", -"r c #83C2C2", -"t c #9FE6E6", -"y c #86FFFF", -"u c #A6E6E6", -"i c #C6C6C6", -"p c #C6C6E6", -"a c #C6C6FF", -"s c #E2DFE6", -"d c #E0E0DF", -"f c #E2E6E6", -"g c #F6F6F6", -"h c None", -"hhhhhhhhhhhhhhhh", -"hhhhhhhhhhhhhhhh", -"hhhhhqiiiei&hhhh", -"hhhh&qgggggwXhhh", -"hhh6u02eggg== hh", -"hh<yf99$ifggg=hh", -"hh6yf99#wfffg=hh", -"hh,0ur4.wfffg=hh", -"hhh5tr%O<ffdg=hh", -"hhhh &>7;3dsg=hh", -"hhhhhea18;<gg=hh", -"hhhhhegp18;<g=hh", -"hhhhh*==@:8-=ohh", -"hhhhhhhhhh+ohhhh", -"hhhhhhhhhhhhhhhh", -"hhhhhhhhhhhhhhhh" -}; +/* XPM */ +static char *asxpm[] = { +/* columns rows colors chars-per-pixel */ +"16 16 44 1", +" c #010101", +". c #002020", +"X c #232323", +"o c #303031", +"O c #21205F", +"+ c #003F7F", +"@ c #303070", +"# c #004040", +"$ c #204040", +"% c #236161", +"& c #434343", +"* c #505050", +"= c #666666", +"- c #000386", +"; c #0007C2", +": c #003FDF", +"> c #50508F", +", c #407F80", +"< c #7F7F80", +"1 c #0342E6", +"2 c #018080", +"3 c #7F8280", +"4 c #41A0A0", +"5 c #70AFAF", +"6 c #7FBFBF", +"7 c #508FD6", +"8 c #01C0FF", +"9 c #61E2E2", +"0 c #72F2F2", +"q c #9F9F9F", +"w c #A6A6A6", +"e c #BFBFBF", +"r c #83C2C2", +"t c #9FE6E6", +"y c #86FFFF", +"u c #A6E6E6", +"i c #C6C6C6", +"p c #C6C6E6", +"a c #C6C6FF", +"s c #E2DFE6", +"d c #E0E0DF", +"f c #E2E6E6", +"g c #F6F6F6", +"h c None", +"hhhhhhhhhhhhhhhh", +"hhhhhhhhhhhhhhhh", +"hhhhhqiiiei&hhhh", +"hhhh&qgggggwXhhh", +"hhh6u02eggg== hh", +"hh<yf99$ifggg=hh", +"hh6yf99#wfffg=hh", +"hh,0ur4.wfffg=hh", +"hhh5tr%O<ffdg=hh", +"hhhh &>7;3dsg=hh", +"hhhhhea18;<gg=hh", +"hhhhhegp18;<g=hh", +"hhhhh*==@:8-=ohh", +"hhhhhhhhhh+ohhhh", +"hhhhhhhhhhhhhhhh", +"hhhhhhhhhhhhhhhh" +}; diff --git a/io/CMakeLists.txt b/io/CMakeLists.txt index 9b516a93ee187..309d2a1b05610 100644 --- a/io/CMakeLists.txt +++ b/io/CMakeLists.txt @@ -10,4 +10,9 @@ endif() if(rfio) add_subdirectory(rfio) endif() - +if(gfal) + add_subdirectory(gfal) +endif() +if(dcache) + add_subdirectory(dcache) +endif() diff --git a/io/castor/src/TCastorFile.cxx b/io/castor/src/TCastorFile.cxx index 6191aa5eece16..ded159350e277 100644 --- a/io/castor/src/TCastorFile.cxx +++ b/io/castor/src/TCastorFile.cxx @@ -73,7 +73,7 @@ #define RFIO_HSM_CNS RFIO_HSM_BASETYPE+1 extern "C" { int rfio_HsmIf_reqtoput (char *); } -extern "C" { int DLL_DECL rfio_parse(char *, char **, char **); } +extern "C" { int rfio_parse(char *, char **, char **); } extern "C" { int rfio_HsmIf_IsHsmFile (const char *); } extern "C" { char *getconfent(char *, char *, int); } @@ -82,7 +82,7 @@ extern int tStageHostKey; extern int tStagePortKey; extern int tSvcClassKey; extern int tCastorVersionKey; -extern "C" { int DLL_DECL use_castor2_api(); } +extern "C" { int use_castor2_api(); } //______________________________________________________________________________ static int UseCastor2API() diff --git a/io/dcache/CMakeLists.txt b/io/dcache/CMakeLists.txt new file mode 100644 index 0000000000000..86288688cf2bd --- /dev/null +++ b/io/dcache/CMakeLists.txt @@ -0,0 +1,13 @@ +############################################################################ +# CMakeLists.txt file for building ROOT io/dcache package +############################################################################ + +ROOT_USE_PACKAGE(io/io) +ROOT_USE_PACKAGE(net/net) +include_directories(${DCAP_INCLUDE_DIRS}) +add_definitions(-pthread) + +ROOT_GENERATE_DICTIONARY(G__DCache *.h LINKDEF LinkDef.h) +ROOT_GENERATE_ROOTMAP(DCache LINKDEF LinkDef.h DEPENDENCIES Net RIO) +ROOT_LINKER_LIBRARY(DCache *.cxx G__DCache.cxx LIBRARIES Core ${DCAP_LIBRARIES} DEPENDENCIES Net RIO) +ROOT_INSTALL_HEADERS() diff --git a/io/doc/TFile/TDirectory.txt b/io/doc/TFile/TDirectory.txt index c0f2d1aa70fdf..8dcab828d8d6d 100644 --- a/io/doc/TFile/TDirectory.txt +++ b/io/doc/TFile/TDirectory.txt @@ -17,7 +17,7 @@ // 1->.. Title = lTitle bytes with the title of the object <direcory title> TNamed::fTitle // --------DATA---------------- // 0->0 Modified = True if directory has been modified TDirectory::fModified -// 1->1 Writeable = True if directory is writeable TDirectory::fWriteable +// 1->1 Writable = True if directory is writable TDirectory::fWriteable // 2->5 DatimeC = Date and time when directory was created TDirectory::fDatimeC // | (year-1995)<<26|month<<22|day<<17|hour<<12|minute<<6|second // 6->9 DatimeM = Date and time when directory was last modified TDirectory::fDatimeM diff --git a/io/doc/TFile/TFile.txt b/io/doc/TFile/TFile.txt index b4ed22393c08e..c6b814789641b 100644 --- a/io/doc/TFile/TFile.txt +++ b/io/doc/TFile/TFile.txt @@ -24,7 +24,7 @@ // 0->0 lTitle = Number of bytes in the TFile title TNamed::fTitle // 1->.. Title = lTitle bytes with the title of the TFile <file title> TNamed::fTitle // 0->0 Modified = True if directory has been modified TDirectory::fModified -// 1->1 Writeable = True if directory is writeable TDirectory::fWriteable +// 1->1 Writable = True if directory is writable TDirectory::fWriteable // 2->5 DatimeC = Date and time when directory was created TDirectory::fDatimeC // | (year-1995)<<26|month<<22|day<<17|hour<<12|minute<<6|second // 6->9 DatimeM = Date and time when directory was last modified TDirectory::fDatimeM diff --git a/io/doc/v524/index.html b/io/doc/v524/index.html index d68e15c853250..752ea1c445934 100644 --- a/io/doc/v524/index.html +++ b/io/doc/v524/index.html @@ -1,45 +1,45 @@ -<br> -<hr> -<a name="io"></a> -<h3>I/O</h3> -<ul> -<li>Implement proxy support in TWebFile. The proxy URL can be sprcified either -via TWebFile::SetProxy() or via the shell variable http_proxy, as is being -used by wget, e.g.: -<pre> export http_proxy=http://pcsalo.cern.ch:3128</pre> -To bypass the proxy, the TWebFile ctor (or via TFile::Open()) supports the -option "NOPROXY".</li> -<li>Add support for streaming std::bitset STL containers</li> -<li>Extend the checks done in case of a StreamerInfo checksum mismatch to -avoid spurrious failures (for example because of the various possible -type names for STL containers) and to report details on the nature of -the mismatch: explicit list missing base classese, missing data members -or the actual differences in type or comments. -For example: - -<pre>Warning in <TStreamerInfo::CompareContent>: The following data member of the on-file layout version 2 of class 'Tdata' differs from the in-memory layout version 2: - double mydouble; // -vs - double mydouble_two; // -Warning in <TStreamerInfo::CompareContent>: The following data member of the in-memory layout version 2 of class 'Tdata' is missing from the on-file layout version 2: - int more; // -Warning in <TStreamerInfo::CompareContent>: The following data member of the in-memory layout version 2 of class 'Tdata' is missing from the on-file layout version 2: - int three; // -</pre> -</li> -<li>Upgrade MakeProject to be able to handle ROOT files created by for ATLAS.</li> -<li>Allow user to provide a custom reallocator when the TBuffer is being passed -memory. If the TBuffer does not own the memory __and__ no custom memory -reallocator has been set, a Fatal error will be issued: -<pre>Fatal in <TBufferFile::Expand>: Failed to expand the data buffer because TBuffer does not own it and no custom memory reallocator was provided.</pre></li> -<li>Re-allow reading empty vector< long double >, however long double is <b>still</b> not supported.</li> -<li>Upgrade TSQLFile to properly work with MySQL on MacOS.</li> -<li>Update to the CollectionProxyInfo interface to insure the proper creation of iterator over std containers on all platforms.</li> -<li>In XML and SQL output, use %e format to write float and double: - <ul> - <li>Conversion from float/double to string per default performed with "%e" (exponential) format.</li> - <li>Format can be configured with SetFloatFormat methods that one can specify precision, width arguments of printf call.</li> - <li>sscanf works as before - "%f" accpet both exponential and decimal format.</li> - </ul> -</li> -</ul> +<br> +<hr> +<a name="io"></a> +<h3>I/O</h3> +<ul> +<li>Implement proxy support in TWebFile. The proxy URL can be sprcified either +via TWebFile::SetProxy() or via the shell variable http_proxy, as is being +used by wget, e.g.: +<pre> export http_proxy=http://pcsalo.cern.ch:3128</pre> +To bypass the proxy, the TWebFile ctor (or via TFile::Open()) supports the +option "NOPROXY".</li> +<li>Add support for streaming std::bitset STL containers</li> +<li>Extend the checks done in case of a StreamerInfo checksum mismatch to +avoid spurrious failures (for example because of the various possible +type names for STL containers) and to report details on the nature of +the mismatch: explicit list missing base classese, missing data members +or the actual differences in type or comments. +For example: + +<pre>Warning in <TStreamerInfo::CompareContent>: The following data member of the on-file layout version 2 of class 'Tdata' differs from the in-memory layout version 2: + double mydouble; // +vs + double mydouble_two; // +Warning in <TStreamerInfo::CompareContent>: The following data member of the in-memory layout version 2 of class 'Tdata' is missing from the on-file layout version 2: + int more; // +Warning in <TStreamerInfo::CompareContent>: The following data member of the in-memory layout version 2 of class 'Tdata' is missing from the on-file layout version 2: + int three; // +</pre> +</li> +<li>Upgrade MakeProject to be able to handle ROOT files created by for ATLAS.</li> +<li>Allow user to provide a custom reallocator when the TBuffer is being passed +memory. If the TBuffer does not own the memory __and__ no custom memory +reallocator has been set, a Fatal error will be issued: +<pre>Fatal in <TBufferFile::Expand>: Failed to expand the data buffer because TBuffer does not own it and no custom memory reallocator was provided.</pre></li> +<li>Re-allow reading empty vector< long double >, however long double is <b>still</b> not supported.</li> +<li>Upgrade TSQLFile to properly work with MySQL on MacOS.</li> +<li>Update to the CollectionProxyInfo interface to insure the proper creation of iterator over std containers on all platforms.</li> +<li>In XML and SQL output, use %e format to write float and double: + <ul> + <li>Conversion from float/double to string per default performed with "%e" (exponential) format.</li> + <li>Format can be configured with SetFloatFormat methods that one can specify precision, width arguments of printf call.</li> + <li>sscanf works as before - "%f" accpet both exponential and decimal format.</li> + </ul> +</li> +</ul> diff --git a/io/doc/v534/index.html b/io/doc/v534/index.html index 71568129efa40..052ecc768c2f0 100644 --- a/io/doc/v534/index.html +++ b/io/doc/v534/index.html @@ -8,7 +8,18 @@ <h4>TFileCacheRead</h4> <li>Support for multiple <tt>TFileCacheRead</tt> per <tt>TFile</tt>.<p/> Multiple <tt>TFileCacheRead</tt> per <tt>TFile</tt> are supported by augmenting the existing <tt>TFile::SetCacheRead()</tt> function with an optional <tt>TObject*</tt> argument specifying the owner (i.e. tree) of the cache. This function will assign a <tt>TFileCacheRead</tt> to a <tt>TFile</tt> for the given <tt>TTree</tt>. A cache can be removed by setting the pointer <tt>TFileCacheRead</tt> to 0.<p/> Similarly, in <tt>TFile::GetCacheRead()</tt> an optional <tt>TObject*</tt> argument was added to obtain the <tt>TFileCacheRead</tt> from a <tt>TFile</tt>.<p/> -In addition to the unassigned <tt>TFileCacheRead</tt> pointer, <tt>TFile</tt> will maintain a map of tree specific cache pointer.<p/> -Backward compatibility in both functions is handled by making the <tt>TObject*</tt> argument optional. If it is not specified in the <tt>TFile::SetCacheRead()</tt> call, only the unassigned <tt>TFileCacheRead</tt> pointer is updated, otherwise the map and the unassigned cache are updated. In <tt>TFile::GetCacheRead()</tt>, if an owner is not specified or doesn't exist in the files' cache map, the unassigned cache is returned, unless it is 0 and there is exactly one entry in the cache map.<p/> +In addition to the unassigned <tt>TFileCacheRead</tt> pointer, <tt>TFile</tt> will maintain a map of tree specific cache pointers.<p/> +Backward compatibility in both functions is handled by making the <tt>TObject*</tt> argument optional. If it is not specified in the <tt>TFile::SetCacheRead()</tt> call, only the unassigned <tt>TFileCacheRead</tt> pointer is updated, otherwise the map and the unassigned cache are updated. In <tt>TFile::GetCacheRead()</tt>, if an owner is not specified or doesn't exist in the file's cache map, the unassigned cache is returned, unless it is 0 and there is exactly one entry in the cache map.<p/> +Distinguish counter for bytes read and read calls for learning phase. </li> -</ul> \ No newline at end of file +</ul> + +<h4>TFileMerger</h4> + +<ul> +<li>Improve efficiency of <tt>TFileMerger</tt> when merging a single file by doing a <tt>TFile::Cp</tt> rather than a load/write of the objects.</li> +<li>In <tt>TFileMerger</tt> and hadd when objects can not be merged do <em>not</em> overwrite the last object in the set with the first!</li> +<li>Renable warning about not being able to merge objects in <tt>TFileMerger</tt> and hadd.</li> +<li>Fix <tt>hadd</tt> problem where the incremental merging fails if the <tt>TTree</tt> are stored in sub-directories.</li> +<li>Improve the code used for forward compatibility (record the type as <tt>TDirectory</tt> even-though the class is now <tt>TDirectoryFile</tt>) by delaying the switching of the class name until it is written (to the buffer). This avoids problem where a <tt>TKey</tt> is created (by <tt>TFile::mkdir</tt>) and then immediately used for reading (this happens in the incremental file merger).</li> +</ul> diff --git a/io/gfal/CMakeLists.txt b/io/gfal/CMakeLists.txt new file mode 100644 index 0000000000000..7befab0722047 --- /dev/null +++ b/io/gfal/CMakeLists.txt @@ -0,0 +1,14 @@ +############################################################################ +# CMakeLists.txt file for building ROOT io/gfal package +############################################################################ + +ROOT_USE_PACKAGE(io/io) +ROOT_USE_PACKAGE(net/net) +include_directories(${GFAL_INCLUDE_DIRS}) + +add_definitions(-D_FILE_OFFSET_BITS=64) + +ROOT_GENERATE_DICTIONARY(G__GFAL *.h LINKDEF LinkDef.h) +ROOT_GENERATE_ROOTMAP(GFAL LINKDEF LinkDef.h DEPENDENCIES Net RIO) +ROOT_LINKER_LIBRARY(GFAL *.cxx G__GFAL.cxx LIBRARIES Core ${GFAL_LIBRARIES} DEPENDENCIES Net RIO) +ROOT_INSTALL_HEADERS() diff --git a/io/gfal/Module.mk b/io/gfal/Module.mk index 66d6ea70f9f66..dcf8a702c0e34 100644 --- a/io/gfal/Module.mk +++ b/io/gfal/Module.mk @@ -70,3 +70,6 @@ distclean:: distclean-$(MODNAME) ##### extra rules ###### $(GFALO) $(GFALDO): CXXFLAGS := $(filter-out -Wshadow,$(CXXFLAGS)) $(GFALO): CXXFLAGS += $(GFALINCDIR:%=-I%) +$(GFALO): CXXFLAGS += $(SRMIFCEINCDIR:%=-I%) +$(GFALO): CXXFLAGS += $(GLIB2INCDIR:%=-I%) +$(GFALO): CXXFLAGS += -D_FILE_OFFSET_BITS=64 diff --git a/io/hdfs/src/THDFSFile.cxx b/io/hdfs/src/THDFSFile.cxx index 82ad87ffe60ff..57226c118931f 100644 --- a/io/hdfs/src/THDFSFile.cxx +++ b/io/hdfs/src/THDFSFile.cxx @@ -490,7 +490,7 @@ Bool_t THDFSSystem::AccessPathName(const char *path, EAccessMode mode) //______________________________________________________________________________ Int_t THDFSSystem::Unlink(const char * path) { - // Unlink, i.e. remove, a file or directory. Returns 0 when succesfull, + // Unlink, i.e. remove, a file or directory. Returns 0 when successful, // -1 in case of failure. if (fFH == 0) { diff --git a/io/io/CMakeLists.txt b/io/io/CMakeLists.txt index 3b5bdc5921685..06dacedd27c0a 100644 --- a/io/io/CMakeLists.txt +++ b/io/io/CMakeLists.txt @@ -13,7 +13,8 @@ ROOT_USE_PACKAGE(math/mathcore) ROOT_GENERATE_DICTIONARY(G__IO *.h LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(${libname} LINKDEF LinkDef.h ) -ROOT_LINKER_LIBRARY(${libname} *.cxx G__IO.cxx DEPENDENCIES Core Thread) +ROOT_LINKER_LIBRARY(${libname} *.cxx G__IO.cxx LIBRARIES ${CMAKE_DL_LIBS} + DEPENDENCIES Core Thread) ROOT_INSTALL_HEADERS() #--- Extra rules ---------------------------------------------------------- diff --git a/io/io/inc/TBufferFile.h b/io/io/inc/TBufferFile.h index 8c69bae0bbbaa..ee6734a1d968f 100644 --- a/io/io/inc/TBufferFile.h +++ b/io/io/inc/TBufferFile.h @@ -1,4 +1,4 @@ -// @(#)root/io:$Id$ +// @(#)root/io:$Id: 697641b2b52ed3d97bb5bde0fb5d2ff4a2f6c24f $ // Author: Rene Brun 17/01/2007 /************************************************************************* @@ -111,6 +111,7 @@ class TBufferFile : public TBuffer { virtual void SkipVersion(const TClass *cl = 0); virtual Version_t ReadVersion(UInt_t *start = 0, UInt_t *bcnt = 0, const TClass *cl = 0); + virtual Version_t ReadVersionNoCheckSum(UInt_t *start = 0, UInt_t *bcnt = 0); virtual Version_t ReadVersionForMemberWise(const TClass *cl = 0); virtual UInt_t WriteVersion(const TClass *cl, Bool_t useBcnt = kFALSE); virtual UInt_t WriteVersionMemberWise(const TClass *cl, Bool_t useBcnt = kFALSE); @@ -209,6 +210,10 @@ class TBufferFile : public TBuffer { virtual void ReadFastArray(Double_t *d, Int_t n); virtual void ReadFastArrayFloat16(Float_t *f, Int_t n, TStreamerElement *ele=0); virtual void ReadFastArrayDouble32(Double_t *d, Int_t n, TStreamerElement *ele=0); + virtual void ReadFastArrayWithFactor(Float_t *ptr, Int_t n, Double_t factor, Double_t minvalue) ; + virtual void ReadFastArrayWithNbits(Float_t *ptr, Int_t n, Int_t nbits); + virtual void ReadFastArrayWithFactor(Double_t *ptr, Int_t n, Double_t factor, Double_t minvalue); + virtual void ReadFastArrayWithNbits(Double_t *ptr, Int_t n, Int_t nbits) ; virtual void ReadFastArray(void *start , const TClass *cl, Int_t n=1, TMemberStreamer *s=0, const TClass* onFileClass=0 ); virtual void ReadFastArray(void **startp, const TClass *cl, Int_t n=1, Bool_t isPreAlloc=kFALSE, TMemberStreamer *s=0, const TClass* onFileClass=0); diff --git a/io/io/inc/TEmulatedCollectionProxy.h b/io/io/inc/TEmulatedCollectionProxy.h index b2aef44fa1b6a..d132e1e013ac4 100644 --- a/io/io/inc/TEmulatedCollectionProxy.h +++ b/io/io/inc/TEmulatedCollectionProxy.h @@ -84,10 +84,10 @@ class TEmulatedCollectionProxy : public TGenCollectionProxy { virtual void* NewArray(Int_t nElements, void* memory) const { return new(memory) Cont_t[nElements]; } // Virtual destructor - virtual void Destructor(void* p, Bool_t dtorOnly = kFALSE); + virtual void Destructor(void* p, Bool_t dtorOnly = kFALSE) const; // Virtual array destructor - virtual void DeleteArray(void* p, Bool_t dtorOnly = kFALSE); + virtual void DeleteArray(void* p, Bool_t dtorOnly = kFALSE) const; // TVirtualCollectionProxy overload: Return the sizeof the collection object. virtual UInt_t Sizeof() const { return sizeof(Cont_t); } diff --git a/io/io/inc/TEmulatedMapProxy.h b/io/io/inc/TEmulatedMapProxy.h index 3588f57824dba..141c82413cebb 100644 --- a/io/io/inc/TEmulatedMapProxy.h +++ b/io/io/inc/TEmulatedMapProxy.h @@ -26,10 +26,10 @@ class TEmulatedMapProxy : public TEmulatedCollectionProxy { protected: // Map input streamer - void ReadMap(int nElements, TBuffer &b); + void ReadMap(UInt_t nElements, TBuffer &b); // Map output streamer - void WriteMap(int nElements, TBuffer &b); + void WriteMap(UInt_t nElements, TBuffer &b); private: TEmulatedMapProxy &operator=(const TEmulatedMapProxy &rhs); // Not implemented. diff --git a/io/io/inc/TFPBlock.h b/io/io/inc/TFPBlock.h index 85030f7d8b72a..90678ce04d381 100644 --- a/io/io/inc/TFPBlock.h +++ b/io/io/inc/TFPBlock.h @@ -33,14 +33,17 @@ class TFPBlock : public TObject{ private: char *fBuffer; // content of the block Int_t fNblock; // number of segment in the block - Int_t fFullSize; // total size of segments that make up the block + Long64_t fDataSize; // total size of useful data in the block + Long64_t fCapacity; // capacity of the buffer Int_t *fLen; // array of lengths of each segment Long64_t *fPos; // array of positions of each segment + Long64_t *fRelOffset; // relative offset of piece in the buffer TFPBlock(const TFPBlock&); // Not implemented. TFPBlock &operator=(const TFPBlock&); // Not implemented. public: + TFPBlock(Long64_t*, Int_t*, Int_t); virtual ~TFPBlock(); @@ -49,9 +52,11 @@ class TFPBlock : public TObject{ Long64_t *GetPos() const; Int_t *GetLen() const; - Int_t GetFullSize() const; + Long64_t GetDataSize() const; + Long64_t GetCapacity() const; Int_t GetNoElem() const; char *GetBuffer() const; + char *GetPtrToPiece(Int_t index) const; void SetBuffer(char*); void SetPos(Int_t, Long64_t); @@ -60,4 +65,76 @@ class TFPBlock : public TObject{ ClassDef(TFPBlock, 0); // File prefetch block }; +//__________________________________________________________________ +inline Long64_t* TFPBlock::GetPos() const +{ + // Get pointer to the array of postions. + + return fPos; +} + +//__________________________________________________________________ +inline Int_t* TFPBlock::GetLen() const +{ + // Get pointer to the array of lengths. + + return fLen; +} + +//__________________________________________________________________ +inline Long64_t TFPBlock::GetDataSize() const +{ + // Return size of the data in the block. + + return fDataSize; +} + +//__________________________________________________________________ +inline Long64_t TFPBlock::GetCapacity() const +{ + // Return capacity of the block. + + return fCapacity; +} + +//__________________________________________________________________ +inline Int_t TFPBlock::GetNoElem() const +{ + // Return number of elements in the block. + + return fNblock; +} + +//__________________________________________________________________ +inline Long64_t TFPBlock::GetPos(Int_t i) const +{ + // Get position of the element at index i. + + return fPos[i]; +} + +//__________________________________________________________________ +inline Int_t TFPBlock::GetLen(Int_t i) const +{ + // Get length of the element at index i. + + return fLen[i]; +} + +//__________________________________________________________________ +inline char* TFPBlock::GetBuffer() const +{ + // Get block buffer. + + return fBuffer; +} + +//__________________________________________________________________ +inline char* TFPBlock::GetPtrToPiece(Int_t index) const +{ + // Get block buffer. + + return (fBuffer + fRelOffset[index]); +} + #endif diff --git a/io/io/inc/TFile.h b/io/io/inc/TFile.h index c4d2c6b75274a..9018215336d0e 100644 --- a/io/io/inc/TFile.h +++ b/io/io/inc/TFile.h @@ -52,6 +52,9 @@ class TFile : public TDirectoryFile { // Open timeout constants enum EOpenTimeOut { kInstantTimeout = 0, kEternalTimeout = 999999999 }; + // TTreeCache flushing semantics + enum ECacheAction { kDisconnect = 0, kDoNotDisconnect = 1 }; + protected: Double_t fSumBuffer; //Sum of buffer sizes of objects written so far Double_t fSum2Buffer; //Sum of squares of buffer sizes of objects written so far @@ -232,7 +235,7 @@ class TFile : public TDirectoryFile { virtual Int_t Recover(); virtual Int_t ReOpen(Option_t *mode); virtual void Seek(Long64_t offset, ERelativeTo pos = kBeg); - virtual void SetCacheRead(TFileCacheRead *cache, TObject* tree = 0); + virtual void SetCacheRead(TFileCacheRead *cache, TObject* tree = 0, ECacheAction action = kDisconnect); virtual void SetCacheWrite(TFileCacheWrite *cache); virtual void SetCompressionAlgorithm(Int_t algorithm=0); virtual void SetCompressionLevel(Int_t level=1); diff --git a/io/io/inc/TFileCacheRead.h b/io/io/inc/TFileCacheRead.h index 4bbe6de6e0219..6f41752fd2267 100644 --- a/io/io/inc/TFileCacheRead.h +++ b/io/io/inc/TFileCacheRead.h @@ -25,7 +25,10 @@ #include "TObject.h" #endif -class TFile; +#ifndef ROOT_TFile +#include "TFile.h" +#endif + class TBranch; class TFilePrefetch; @@ -80,6 +83,8 @@ class TFileCacheRead : public TObject { Bool_t fBIsSorted; Bool_t fBIsTransferred; + void SetEnablePrefetchingImpl(Bool_t setPrefetching = kFALSE); // Can not be virtual as it is called from the constructor. + private: TFileCacheRead(const TFileCacheRead &); //cannot be copied TFileCacheRead& operator=(const TFileCacheRead &); @@ -92,6 +97,7 @@ class TFileCacheRead : public TObject { virtual void AddBranch(const char * /*branch*/, Bool_t /*subbranches*/ = kFALSE) {} virtual void AddNoCacheBytesRead(Long64_t len) { fNoCacheBytesRead += len; } virtual void AddNoCacheReadCalls(Int_t reads) { fNoCacheReadCalls += reads; } + virtual void Close(Option_t *option=""); virtual Int_t GetBufferSize() const { return fBufferSize; }; virtual Long64_t GetBytesRead() const { return fBytesRead; } virtual Long64_t GetNoCacheBytesRead() const { return fNoCacheBytesRead; } @@ -104,7 +110,7 @@ class TFileCacheRead : public TObject { virtual Int_t GetUnzipBuffer(char ** /*buf*/, Long64_t /*pos*/, Int_t /*len*/, Bool_t * /*free*/) { return -1; } Long64_t GetPrefetchedBlocks() const { return fPrefetchedBlocks; } virtual Bool_t IsAsyncReading() const { return fAsyncReading; }; - virtual void SetEnablePrefetching(Bool_t setPrefetching = kFALSE) { fEnablePrefetching = setPrefetching; } + virtual void SetEnablePrefetching(Bool_t setPrefetching = kFALSE); virtual Bool_t IsEnablePrefetching() const { return fEnablePrefetching; }; virtual Bool_t IsLearning() const {return kFALSE;} virtual void Prefetch(Long64_t pos, Int_t len); @@ -113,12 +119,13 @@ class TFileCacheRead : public TObject { virtual Int_t ReadBufferExtNormal(char *buf, Long64_t pos, Int_t len, Int_t &loc); virtual Int_t ReadBufferExtPrefetch(char *buf, Long64_t pos, Int_t len, Int_t &loc); virtual Int_t ReadBuffer(char *buf, Long64_t pos, Int_t len); - virtual void SetFile(TFile *file); + virtual void SetFile(TFile *file, TFile::ECacheAction action = TFile::kDisconnect); virtual void SetSkipZip(Bool_t /*skip*/ = kTRUE) {} // This function is only used by TTreeCacheUnzip (ignore it) virtual void Sort(); virtual void SecondSort(); //Method used to sort and merge the chunks in the second block virtual void SecondPrefetch(Long64_t, Int_t); //Used to add chunks to the second block virtual TFilePrefetch* GetPrefetchObj(); + virtual void WaitFinishPrefetch(); //Gracefully join the prefetching thread ClassDef(TFileCacheRead,2) //TFile cache when reading }; diff --git a/io/io/inc/TFileMerger.h b/io/io/inc/TFileMerger.h index 022c8ad251fad..08b8c0610c479 100644 --- a/io/io/inc/TFileMerger.h +++ b/io/io/inc/TFileMerger.h @@ -62,6 +62,7 @@ class TFileMerger : public TObject { Int_t fMaxOpenedFiles; // Maximum number of files opened at the same time by the TFileMerger. Bool_t fLocal; // Makes local copies of merging files if True (default is kTRUE) Bool_t fHistoOneGo; // Merger histos in one go (default is kTRUE) + TString fObjectNames; // List of object names to be either merged exclusively or skipped TList *fMergeList; // list of TObjString containing the name of the files need to be merged TList *fExcessFiles; //! List of TObjString containing the name of the files not yet added to fFileList due to user or system limitiation on the max number of files opened. @@ -76,8 +77,11 @@ class TFileMerger : public TObject { kResetable = BIT(2), // Only the objects with a MergeAfterReset member function. kNonResetable = BIT(3), // Only the objects without a MergeAfterReset member function. - kAll = BIT(2)|BIT(3), // Merge all type of objects (default) - kAllIncremental = kIncremental | kAll // Merge incrementally all type of objects. + kAll = BIT(2)|BIT(3), // Merge all type of objects (default) + kAllIncremental = kIncremental | kAll, // Merge incrementally all type of objects. + + kOnlyListed = BIT(4), // Merge only the objects specified in fObjectNames list + kSkipListed = BIT(5) // Skip objects specified in fObjectNames list }; TFileMerger(Bool_t isLocal = kTRUE, Bool_t histoOneGo = kTRUE); virtual ~TFileMerger(); @@ -92,6 +96,9 @@ class TFileMerger : public TObject { void SetMaxOpenedFiles(Int_t newmax); const char *GetMsgPrefix() const { return fMsgPrefix; } void SetMsgPrefix(const char *prefix); + void AddObjectNames(const char *name) {fObjectNames += name; fObjectNames += " ";} + const char *GetObjectNames() const {return fObjectNames.Data();} + void ClearObjectNames() {fObjectNames.Clear();} //--- file management interface virtual Bool_t SetCWD(const char * /*path*/) { MayNotUse("SetCWD"); return kFALSE; } @@ -113,7 +120,7 @@ class TFileMerger : public TObject { virtual void SetNotrees(Bool_t notrees=kFALSE) {fNoTrees = notrees;} virtual void RecursiveRemove(TObject *obj); - ClassDef(TFileMerger,4) // File copying and merging services + ClassDef(TFileMerger,5) // File copying and merging services }; #endif diff --git a/io/io/inc/TFilePrefetch.h b/io/io/inc/TFilePrefetch.h index f0da277055371..af152719a6a23 100644 --- a/io/io/inc/TFilePrefetch.h +++ b/io/io/inc/TFilePrefetch.h @@ -1,4 +1,4 @@ -// @(#)root/io:$Id$ +// @(#)root/io: // Author: Elvin Sindrilaru 19/05/2011 /************************************************************************* @@ -70,17 +70,19 @@ class TFilePrefetch : public TObject { private: TFile *fFile; // reference to the file - TList *fPendingBlocks; // list of pending block to be read - TList *fReadBlocks; // list of block read + TList *fPendingBlocks; // list of pending blocks to be read + TList *fReadBlocks; // list of blocks read TThread *fConsumer; // consumer thread TMutex *fMutexPendingList; // mutex for the pending list TMutex *fMutexReadList; // mutex for the list of read blocks - TMutex *fMutexSynch; // mutex for synchronisation between working and main thread - TCondition *fNewBlockAdded; // condition used to signal the addition of a new pending block - TCondition *fReadBlockAdded; // condition usd to signal the addition of a new red block - TSemaphore *fSem; // semaphore used to kill the consumer thread + TCondition *fNewBlockAdded; // signal the addition of a new pending block + TCondition *fReadBlockAdded; // signal the addition of a new red block + TSemaphore *fSemMasterWorker; // semaphore used to kill the consumer thread + TSemaphore *fSemWorkerMaster; // semaphore used to notify the master that worker is killed + TSemaphore *fSemChangeFile; // semaphore used when changin a file in TChain TString fPathCache; // path to the cache directory TStopwatch fWaitTime; // time wating to prefetch a buffer (in usec) + Bool_t fThreadJoined; // mark if async thread was joined static TThread::VoidRtnFunc_t ThreadProc(void*); //create a joinable worker thread @@ -113,7 +115,8 @@ class TFilePrefetch : public TObject { Long64_t GetWaitTime(); void SetFile(TFile*); - TMutex* GetMutexSynch() const { return fMutexSynch; }; + TCondition* GetCondNewBlock() const { return fNewBlockAdded; }; + void WaitFinishPrefetch(); ClassDef(TFilePrefetch, 0); // File block prefetcher }; diff --git a/io/io/inc/TGenCollectionProxy.h b/io/io/inc/TGenCollectionProxy.h index 5ad0e2cdd7a71..62a71032cbf25 100644 --- a/io/io/inc/TGenCollectionProxy.h +++ b/io/io/inc/TGenCollectionProxy.h @@ -310,6 +310,7 @@ class TGenCollectionProxy mutable TStreamerInfoActions::TActionSequence *fWriteMemberWise; typedef void (*Sizing_t)(void *obj, size_t size); typedef void* (*Feedfunc_t)(void *from, void *to, size_t size); + typedef void* (*Collectfunc_t)(void *from, void *to); typedef void* (*ArrIterfunc_t)(void *from, size_t size); std::string fName; // Name of the class being proxied. @@ -322,7 +323,7 @@ class TGenCollectionProxy ArrIterfunc_t fConstruct; // Container accessors: block construct Sizing_t fDestruct; // Container accessors: block destruct Feedfunc_t fFeed; // Container accessors: block feed - Method fCollect; // Method to collect objects from container + Collectfunc_t fCollect; // Method to collect objects from container Method0 fCreateEnv; // Method to allocate an Environment holder. Value* fValue; // Descriptor of the container value type Value* fVal; // Descriptor of the Value_type @@ -338,6 +339,9 @@ class TGenCollectionProxy TClass* fOnFileClass; // On file class CreateIterators_t fFunctionCreateIterators; + CopyIterator_t fFunctionCopyIterator; + Next_t fFunctionNextIterator; + DeleteIterator_t fFunctionDeleteIterator; DeleteTwoIterators_t fFunctionDeleteTwoIterators; // Late initialization of collection proxy @@ -372,13 +376,13 @@ class TGenCollectionProxy virtual ~TGenCollectionProxy(); // Return a pointer to the TClass representing the container. - virtual TClass *GetCollectionClass(); + virtual TClass *GetCollectionClass() const; // Return the type of collection see TClassEdit::ESTLType - virtual Int_t GetCollectionType(); + virtual Int_t GetCollectionType() const; // Return the offset between two consecutive value_types (memory layout). - virtual ULong_t GetIncrement(); + virtual ULong_t GetIncrement() const; // Return the sizeof the collection object. virtual UInt_t Sizeof() const; @@ -393,13 +397,13 @@ class TGenCollectionProxy virtual Bool_t HasPointers() const; // Return a pointer to the TClass representing the content. - virtual TClass *GetValueClass(); + virtual TClass *GetValueClass() const; // Set pointer to the TClass representing the content. virtual void SetValueClass(TClass *newcl); // If the content is a simple numerical value, return its type (see TDataType). - virtual EDataType GetType(); + virtual EDataType GetType() const; // Return the address of the value at index 'idx'. virtual void *At(UInt_t idx); @@ -449,10 +453,11 @@ class TGenCollectionProxy // Otherwise the iterators will be allocated via a regular new and their address returned by modifying the value of begin_arena and end_arena. virtual CopyIterator_t GetFunctionCopyIterator(Bool_t read = kTRUE); - // typedef void* (*CopyIterator_t)(void *dest, const void *source); + // typedef void* (*CopyIterator_t)(void **dest, const void *source); // Copy the iterator source, into dest. dest should contain the location of a memory arena of size fgIteratorSize. // If the collection iterator is of that size or less, the iterator will be constructed in place in this location (new with placement) - // Otherwise the iterator will be allocated via a regular new and its address returned by modifying the value of dest. + // Otherwise the iterator will be allocated via a regular new. + // The actual address of the iterator is returned in both case. virtual Next_t GetFunctionNext(Bool_t read = kTRUE); // typedef void* (*Next_t)(void *iter, const void *end); diff --git a/io/io/inc/TGenCollectionStreamer.h b/io/io/inc/TGenCollectionStreamer.h index 558a20709f4a2..f1f3cedb369de 100644 --- a/io/io/inc/TGenCollectionStreamer.h +++ b/io/io/inc/TGenCollectionStreamer.h @@ -27,25 +27,29 @@ class TGenCollectionStreamer : public TGenCollectionProxy { protected: void ReadMapHelper(StreamHelper *i, Value *v, Bool_t vsn3, TBuffer &b); - void ReadMap(int nElements, TBuffer &b); + void ReadMap(int nElements, TBuffer &b, const TClass *onfileClass); void ReadPairFromMap(int nElements, TBuffer &b); - void ReadObjects(int nElements, TBuffer &b); - void ReadPrimitives(int nElements, TBuffer &b); + void ReadObjects(int nElements, TBuffer &b, const TClass *onfileClass); + void ReadPrimitives(int nElements, TBuffer &b, const TClass *onfileClass); void WriteMap(int nElements, TBuffer &b); void WriteObjects(int nElements, TBuffer &b); void WritePrimitives(int nElements, TBuffer &b); -// typedef void (TGenCollectionStreamer::*ReadBufferConv_t)(TBuffer &b, void *obj, const TClass *onfileClass); +// typedef void (TGenCollectionStreamer::*ReadBufferConv_t)(TBuffer &b, void *obj, const TClass *onFileClass); // ReadBufferConv_t fReadBufferConvFunc; - typedef void (TGenCollectionStreamer::*ReadBuffer_t)(TBuffer &b, void *obj); + typedef void (TGenCollectionStreamer::*ReadBuffer_t)(TBuffer &b, void *obj, const TClass *onFileClass); ReadBuffer_t fReadBufferFunc; - template <typename basictype> void ReadBufferVectorPrimitives(TBuffer &b, void *obj); - void ReadBufferVectorPrimitivesFloat16(TBuffer &b, void *obj); - void ReadBufferVectorPrimitivesDouble32(TBuffer &b, void *obj); - void ReadBufferDefault(TBuffer &b, void *obj); - void ReadBufferGeneric(TBuffer &b, void *obj); + template <typename From, typename To> void ConvertBufferVectorPrimitives(TBuffer &b, void *obj, Int_t nElements); + template <typename To> void ConvertBufferVectorPrimitivesFloat16(TBuffer &b, void *obj, Int_t nElements); + template <typename To> void ConvertBufferVectorPrimitivesDouble32(TBuffer &b, void *obj, Int_t nElements); + template <typename To> void DispatchConvertBufferVectorPrimitives(TBuffer &b, void *obj, Int_t nElements, const TVirtualCollectionProxy *onfileProxy); + template <typename basictype> void ReadBufferVectorPrimitives(TBuffer &b, void *obj, const TClass *onFileClass); + void ReadBufferVectorPrimitivesFloat16(TBuffer &b, void *obj, const TClass *onFileClass); + void ReadBufferVectorPrimitivesDouble32(TBuffer &b, void *obj, const TClass *onFileClass); + void ReadBufferDefault(TBuffer &b, void *obj, const TClass *onFileClass); + void ReadBufferGeneric(TBuffer &b, void *obj, const TClass *onFileClass); private: TGenCollectionStreamer &operator=(const TGenCollectionStreamer&); // Not implemented. @@ -93,7 +97,7 @@ struct AnyCollectionStreamer : public TGenCollectionStreamer { fNext.call = T::next; fClear.call = T::clear; fResize = T::resize; - fCollect.call = T::collect; + fCollect = T::collect; fConstruct = T::construct; fDestruct = T::destruct; fFeed = T::feed; diff --git a/io/io/inc/TStreamerInfo.h b/io/io/inc/TStreamerInfo.h index d0955971cee65..044538ba77ffc 100644 --- a/io/io/inc/TStreamerInfo.h +++ b/io/io/inc/TStreamerInfo.h @@ -113,7 +113,7 @@ class TStreamerInfo : public TVirtualStreamerInfo { static Int_t fgCount; //Number of TStreamerInfo instances static TStreamerElement *fgElement; //Pointer to current TStreamerElement - static Double_t GetValueAux(Int_t type, void *ladd, int k, Int_t len); + template <typename T> static T GetTypedValueAux(Int_t type, void *ladd, int k, Int_t len); static void PrintValueAux(char *ladd, Int_t atype, TStreamerElement * aElement, Int_t aleng, Int_t *count); UInt_t GenerateIncludes(FILE *fp, char *inclist, const TList *extrainfos); @@ -220,10 +220,14 @@ class TStreamerInfo : public TVirtualStreamerInfo { TStreamerElement *GetStreamerElement(const char*datamember, Int_t& offset) const; TStreamerElement *GetStreamerElementReal(Int_t i, Int_t j) const; Int_t *GetTypes() const {return fType;} - Double_t GetValue(char *pointer, Int_t i, Int_t j, Int_t len) const; - Double_t GetValueClones(TClonesArray *clones, Int_t i, Int_t j, Int_t k, Int_t eoffset) const; - Double_t GetValueSTL(TVirtualCollectionProxy *cont, Int_t i, Int_t j, Int_t k, Int_t eoffset) const; - Double_t GetValueSTLP(TVirtualCollectionProxy *cont, Int_t i, Int_t j, Int_t k, Int_t eoffset) const; + template <typename T> T GetTypedValue(char *pointer, Int_t i, Int_t j, Int_t len) const; + template <typename T> T GetTypedValueClones(TClonesArray *clones, Int_t i, Int_t j, Int_t k, Int_t eoffset) const; + template <typename T> T GetTypedValueSTL(TVirtualCollectionProxy *cont, Int_t i, Int_t j, Int_t k, Int_t eoffset) const; + template <typename T> T GetTypedValueSTLP(TVirtualCollectionProxy *cont, Int_t i, Int_t j, Int_t k, Int_t eoffset) const; + Double_t GetValue(char *pointer, Int_t i, Int_t j, Int_t len) const { return GetTypedValue<Double_t>(pointer, i, j, len); } + Double_t GetValueClones(TClonesArray *clones, Int_t i, Int_t j, Int_t k, Int_t eoffset) const { return GetTypedValueClones<Double_t>(clones, i, j, k, eoffset); } + Double_t GetValueSTL(TVirtualCollectionProxy *cont, Int_t i, Int_t j, Int_t k, Int_t eoffset) const { return GetTypedValueSTL<Double_t>(cont, i, j, k, eoffset); } + Double_t GetValueSTLP(TVirtualCollectionProxy *cont, Int_t i, Int_t j, Int_t k, Int_t eoffset) const { return GetTypedValueSTLP<Double_t>(cont, i, j, k, eoffset); } void ls(Option_t *option="") const; TVirtualStreamerInfo *NewInfo(TClass *cl) {return new TStreamerInfo(cl);} void *New(void *obj = 0); diff --git a/io/io/inc/TVirtualCollectionIterators.h b/io/io/inc/TVirtualCollectionIterators.h index e00edea30f172..8f5fc7f165689 100644 --- a/io/io/inc/TVirtualCollectionIterators.h +++ b/io/io/inc/TVirtualCollectionIterators.h @@ -1,4 +1,4 @@ -// @(#)root/cont:$Id$ +// @(#)root/cont:$Id: e00edea30f17233d3f97a85eba14e20c201eb980 $ // Author: Philippe Canal 20/08/2010 /************************************************************************* @@ -63,11 +63,11 @@ class TVirtualCollectionIterators { } - inline void CreateIterators(void *collection) + inline void CreateIterators(void *collection, TVirtualCollectionProxy *proxy) { // Initialize the fBegin and fEnd iterators. - fCreateIterators(collection, &fBegin, &fEnd); + fCreateIterators(collection, &fBegin, &fEnd, proxy); } inline ~TVirtualCollectionIterators() @@ -143,13 +143,13 @@ class TVirtualCollectionPtrIterators } } - inline void CreateIterators(void *collection) + inline void CreateIterators(void *collection, TVirtualCollectionProxy *proxy) { // Initialize the fBegin and fEnd iterators. fBegin = &(fRawBeginBuffer[0]); fEnd = &(fRawEndBuffer[0]); - fCreateIterators(collection, &fBegin, &fEnd); + fCreateIterators(collection, &fBegin, &fEnd, proxy); if (fBegin != &(fRawBeginBuffer[0])) { // The iterator where too large to buffer in the buffer fAllocated = kTRUE; diff --git a/io/io/src/TBufferFile.cxx b/io/io/src/TBufferFile.cxx index 809b6375cc0b6..2dded853d0d91 100644 --- a/io/io/src/TBufferFile.cxx +++ b/io/io/src/TBufferFile.cxx @@ -401,7 +401,7 @@ void TBufferFile::ReadDouble32(Double_t *d, TStreamerElement *ele) //______________________________________________________________________________ void TBufferFile::ReadWithFactor(Float_t *ptr, Double_t factor, Double_t minvalue) { - // Read a Double32_t from the buffer when the factor and minimun value have been specified + // Read a Float16_t from the buffer when the factor and minimun value have been specified // see comments about Double32_t encoding at TBufferFile::WriteDouble32(). //a range was specified. We read an integer and convert it back to a double. @@ -1414,6 +1414,48 @@ void TBufferFile::ReadFastArrayFloat16(Float_t *f, Int_t n, TStreamerElement *el } } +//______________________________________________________________________________ +void TBufferFile::ReadFastArrayWithFactor(Float_t *ptr, Int_t n, Double_t factor, Double_t minvalue) +{ + // Read array of n floats (written as truncated float) from the I/O buffer. + // see comments about Float16_t encoding at TBufferFile::WriteFloat16 + + if (n <= 0 || 3*n > fBufSize) return; + + //a range was specified. We read an integer and convert it back to a float + for (int j=0;j < n; j++) { + UInt_t aint; *this >> aint; ptr[j] = (Float_t)(aint/factor + minvalue); + } +} + +//______________________________________________________________________________ +void TBufferFile::ReadFastArrayWithNbits(Float_t *ptr, Int_t n, Int_t nbits) +{ + // Read array of n floats (written as truncated float) from the I/O buffer. + // see comments about Float16_t encoding at TBufferFile::WriteFloat16 + + if (n <= 0 || 3*n > fBufSize) return; + + if (!nbits) nbits = 12; + //we read the exponent and the truncated mantissa of the float + //and rebuild the new float. + union { + Float_t fFloatValue; + Int_t fIntValue; + }; + UChar_t theExp; + UShort_t theMan; + for (Int_t i = 0; i < n; i++) { + *this >> theExp; + *this >> theMan; + fIntValue = theExp; + fIntValue <<= 23; + fIntValue |= (theMan & ((1<<(nbits+1))-1)) <<(23-nbits); + if(1<<(nbits+1) & theMan) fFloatValue = -fFloatValue; + ptr[i] = fFloatValue; + } +} + //______________________________________________________________________________ void TBufferFile::ReadFastArrayDouble32(Double_t *d, Int_t n, TStreamerElement *ele) { @@ -1462,6 +1504,56 @@ void TBufferFile::ReadFastArrayDouble32(Double_t *d, Int_t n, TStreamerElement * } } +//______________________________________________________________________________ +void TBufferFile::ReadFastArrayWithFactor(Double_t *d, Int_t n, Double_t factor, Double_t minvalue) +{ + // Read array of n doubles (written as float) from the I/O buffer. + // see comments about Double32_t encoding at TBufferFile::WriteDouble32 + + if (n <= 0 || 3*n > fBufSize) return; + + //a range was specified. We read an integer and convert it back to a double. + for (int j=0;j < n; j++) { + UInt_t aint; *this >> aint; d[j] = (Double_t)(aint/factor + minvalue); + } +} + +//______________________________________________________________________________ +void TBufferFile::ReadFastArrayWithNbits(Double_t *d, Int_t n, Int_t nbits) +{ + // Read array of n doubles (written as float) from the I/O buffer. + // see comments about Double32_t encoding at TBufferFile::WriteDouble32 + + if (n <= 0 || 3*n > fBufSize) return; + + if (!nbits) { + //we read a float and convert it to double + Float_t afloat; + for (Int_t i = 0; i < n; i++) { + *this >> afloat; + d[i] = (Double_t)afloat; + } + } else { + //we read the exponent and the truncated mantissa of the float + //and rebuild the double. + union { + Float_t fFloatValue; + Int_t fIntValue; + }; + UChar_t theExp; + UShort_t theMan; + for (Int_t i = 0; i < n; i++) { + *this >> theExp; + *this >> theMan; + fIntValue = theExp; + fIntValue <<= 23; + fIntValue |= (theMan & ((1<<(nbits+1))-1)) <<(23-nbits); + if (1<<(nbits+1) & theMan) fFloatValue = -fFloatValue; + d[i] = (Double_t)fFloatValue; + } + } +} + //______________________________________________________________________________ void TBufferFile::ReadFastArray(void *start, const TClass *cl, Int_t n, TMemberStreamer *streamer, const TClass* onFileClass ) @@ -2157,9 +2249,13 @@ Int_t TBufferFile::WriteFastArray(void **start, const TClass *cl, Int_t n, for (Int_t j=0;j<n;j++) { //must write StreamerInfo if pointer is null - if (!strInfo && !start[j] ) { - TStreamerInfo *info = (TStreamerInfo*)((TClass*)cl)->GetStreamerInfo(); - ForceWriteInfo(info,kFALSE); + if (!strInfo && !start[j]) { + if (cl->Property() & kIsAbstract) { + // Do not try to generate the StreamerInfo for an abstract class + } else { + TStreamerInfo *info = (TStreamerInfo*)((TClass*)cl)->GetStreamerInfo(); + ForceWriteInfo(info,kFALSE); + } } strInfo = 2003; res |= WriteObjectAny(start[j],cl); @@ -2680,49 +2776,42 @@ Version_t TBufferFile::ReadVersion(UInt_t *startpos, UInt_t *bcnt, const TClass Version_t version; - if (startpos && bcnt) { + if (startpos) { // before reading object save start position *startpos = UInt_t(fBufCur-fBuffer); + } - // read byte count (older files don't have byte count) - // byte count is packed in two individual shorts, this to be - // backward compatible with old files that have at this location - // only a single short (i.e. the version) - union { - UInt_t cnt; - Version_t vers[2]; - } v; + // read byte count (older files don't have byte count) + // byte count is packed in two individual shorts, this to be + // backward compatible with old files that have at this location + // only a single short (i.e. the version) + union { + UInt_t cnt; + Version_t vers[2]; + } v; #ifdef R__BYTESWAP - frombuf(this->fBufCur,&v.vers[1]); - frombuf(this->fBufCur,&v.vers[0]); + frombuf(this->fBufCur,&v.vers[1]); + frombuf(this->fBufCur,&v.vers[0]); #else - frombuf(this->fBufCur,&v.vers[0]); - frombuf(this->fBufCur,&v.vers[1]); + frombuf(this->fBufCur,&v.vers[0]); + frombuf(this->fBufCur,&v.vers[1]); #endif - // no bytecount, backup and read version - if (!(v.cnt & kByteCountMask)) { - fBufCur -= sizeof(UInt_t); - v.cnt = 0; - } - *bcnt = (v.cnt & ~kByteCountMask); - frombuf(this->fBufCur,&version); - - } else { - - // not interested in byte count - frombuf(this->fBufCur,&version); - - // if this is a byte count, then skip next short and read version - if (version & kByteCountVMask) { - frombuf(this->fBufCur,&version); - frombuf(this->fBufCur,&version); - } + // no bytecount, backup and read version + if (!(v.cnt & kByteCountMask)) { + fBufCur -= sizeof(UInt_t); + v.cnt = 0; } + if (bcnt) *bcnt = (v.cnt & ~kByteCountMask); + frombuf(this->fBufCur,&version); + if (version<=1) { if (version <= 0) { if (cl) { - if (cl->GetClassVersion() != 0) { + if (cl->GetClassVersion() != 0 + // If v.cnt < 6 then we have a class with a version that used to be zero and so there is no checksum. + && (v.cnt && v.cnt >= 6) + ) { UInt_t checksum = 0; //*this >> checksum; frombuf(this->fBufCur,&checksum); @@ -2751,7 +2840,9 @@ Version_t TBufferFile::ReadVersion(UInt_t *startpos, UInt_t *bcnt, const TClass } else { // of if (cl) { UInt_t checksum = 0; //*this >> checksum; - frombuf(this->fBufCur,&checksum); + // If *bcnt < 6 then we have a class with 'just' version zero and no checksum + if (v.cnt && v.cnt >= 6) + frombuf(this->fBufCur,&checksum); } } else if (version == 1 && fParent && ((TFile*)fParent)->GetVersion()<40000 && cl && cl->GetClassVersion() != 0) { // We could have a file created using a Foreign class before @@ -2783,6 +2874,46 @@ Version_t TBufferFile::ReadVersion(UInt_t *startpos, UInt_t *bcnt, const TClass return version; } +//______________________________________________________________________________ +Version_t TBufferFile::ReadVersionNoCheckSum(UInt_t *startpos, UInt_t *bcnt) +{ + // Read class version from I/O buffer, when the caller knows for sure that + // there is no checksum written/involved. + + Version_t version; + + if (startpos) { + // before reading object save start position + *startpos = UInt_t(fBufCur-fBuffer); + } + + // read byte count (older files don't have byte count) + // byte count is packed in two individual shorts, this to be + // backward compatible with old files that have at this location + // only a single short (i.e. the version) + union { + UInt_t cnt; + Version_t vers[2]; + } v; +#ifdef R__BYTESWAP + frombuf(this->fBufCur,&v.vers[1]); + frombuf(this->fBufCur,&v.vers[0]); +#else + frombuf(this->fBufCur,&v.vers[0]); + frombuf(this->fBufCur,&v.vers[1]); +#endif + + // no bytecount, backup and read version + if (!(v.cnt & kByteCountMask)) { + fBufCur -= sizeof(UInt_t); + v.cnt = 0; + } + if (bcnt) *bcnt = (v.cnt & ~kByteCountMask); + frombuf(this->fBufCur,&version); + + return version; +} + //______________________________________________________________________________ Version_t TBufferFile::ReadVersionForMemberWise(const TClass *cl) { @@ -2981,7 +3112,7 @@ UInt_t TBufferFile::CheckObject(UInt_t offset, const TClass *cl, Bool_t readClas if (readClass) { if ((cli = fMap->GetValue(offset)) == 0) { // No class found at this location in map. It might have been skipped - // as part of a skipped object. Try to explicitely read the class. + // as part of a skipped object. Try to explicitly read the class. // save fBufCur and set to place specified by offset (-kMapOffset-sizeof(bytecount)) char *bufsav = fBufCur; @@ -3013,7 +3144,7 @@ UInt_t TBufferFile::CheckObject(UInt_t offset, const TClass *cl, Bool_t readClas if ((cli = fMap->GetValue(offset)) == 0) { // No object found at this location in map. It might have been skipped - // as part of a skipped object. Try to explicitely read the object. + // as part of a skipped object. Try to explicitly read the object. // save fBufCur and set to place specified by offset (-kMapOffset) char *bufsav = fBufCur; @@ -3518,6 +3649,12 @@ Int_t TBufferFile::ReadClassBuffer(const TClass *cl, void *pointer, Int_t versio infos->AddAtAndExpand(sinfo, version); if (gDebug > 0) printf("Creating StreamerInfo for class: %s, version: %d\n", cl->GetName(), version); sinfo->Build(); + } else if (version==0) { + // When the object was written the class was version zero, so + // there is no StreamerInfo to be found. + // Check that the buffer position corresponds to the byte count. + CheckByteCount(start, count, cl); + return 0; } else { Error("ReadClassBuffer", "Could not find the StreamerInfo for version %d of the class %s, object skipped at offset %d", version, cl->GetName(), Length() ); @@ -3612,6 +3749,12 @@ Int_t TBufferFile::ReadClassBuffer(const TClass *cl, void *pointer, const TClass sinfo->Build(); if (v2file) sinfo->BuildEmulated(file); + } else if (version==0) { + // When the object was written the class was version zero, so + // there is no StreamerInfo to be found. + // Check that the buffer position corresponds to the byte count. + CheckByteCount(R__s, R__c, cl); + return 0; } else { Error( "ReadClassBuffer", "Could not find the StreamerInfo for version %d of the class %s, object skipped at offset %d", version, cl->GetName(), Length() ); diff --git a/io/io/src/TContainerConverters.cxx b/io/io/src/TContainerConverters.cxx index 5c5a874d0bc2b..56ae10c519627 100644 --- a/io/io/src/TContainerConverters.cxx +++ b/io/io/src/TContainerConverters.cxx @@ -119,7 +119,7 @@ void TConvertClonesArrayToProxy::operator()(TBuffer &b, void *pmember, Int_t siz if (b.GetBufferVersion()==0) continue; // No object found at this location in map. It might have been skipped - // as part of a skipped object. Try to explicitely read the object. + // as part of a skipped object. Try to explicitly read the object. b.MapObject(*(void**)addr, fProxy->GetCollectionClass(), 0); Int_t currentpos = b.Length(); b.SetBufferOffset( tag - kMapOffset ); diff --git a/io/io/src/TDirectoryFile.cxx b/io/io/src/TDirectoryFile.cxx index efafe4df3981c..300c6a1c284d8 100644 --- a/io/io/src/TDirectoryFile.cxx +++ b/io/io/src/TDirectoryFile.cxx @@ -184,6 +184,18 @@ TDirectoryFile::~TDirectoryFile() CleanTargets(); + // Delete our content before we become somewhat invalid + // since some those objects (TTree for example) needs information + // from this object. Note that on some platform after the end + // of the body (i.e. thus during ~TDirectory which is also + // contains this code) the exeuction of 'this->GetFile()' fails + // to return the 'proper' value (because it uses the wrong + // virtual function). + if (fList) { + fList->Delete("slow"); + SafeDelete(fList); + } + if (gDebug) { Info("~TDirectoryFile", "dtor called for %s", GetName()); } @@ -474,25 +486,20 @@ TDirectory *TDirectoryFile::GetDirectory(const char *apath, delete [] path; return result; } - TObject *obj; + TDirectoryFile *obj; char *slash = (char*)strchr(path,'/'); if (!slash) { // we are at the lowest level if (!strcmp(path, "..")) { result = GetMotherDir(); delete [] path; return result; } - obj = Get(path); + GetObject(path,obj); if (!obj) { if (printError) Error(funcname,"Unknown directory %s", path); delete [] path; return 0; } - //Check return object is a directory - if (!obj->InheritsFrom(TDirectoryFile::Class())) { - if (printError) Error(funcname,"Object %s is not a directory", path); - delete [] path; return 0; - } - delete [] path; return (TDirectory*)obj; + delete [] path; return obj; } TString subdir(path); @@ -505,17 +512,12 @@ TDirectory *TDirectoryFile::GetDirectory(const char *apath, result = mom->GetDirectory(slash+1,printError,funcname); delete [] path; return result; } - obj = Get(subdir); + GetObject(subdir,obj); if (!obj) { if (printError) Error(funcname,"Unknown directory %s", subdir.Data()); delete [] path; return 0; } - //Check return object is a directory - if (!obj->InheritsFrom(TDirectoryFile::Class())) { - if (printError) Error(funcname,"Object %s is not a directory", subdir.Data()); - delete [] path; return 0; - } result = ((TDirectory*)obj)->GetDirectory(slash+1,printError,funcname); delete [] path; return result; } @@ -591,7 +593,7 @@ void TDirectoryFile::Delete(const char *namecycle) TDirectory::TContext ctxt(gDirectory, this); Short_t cycle; char name[kMaxLen]; - DecodeNameCycle(namecycle, name, cycle); + DecodeNameCycle(namecycle, name, cycle, kMaxLen); Int_t deleteall = 0; Int_t deletetree = 0; @@ -716,7 +718,7 @@ TKey *TDirectoryFile::FindKey(const char *keyname) const Short_t cycle; char name[kMaxLen]; - DecodeNameCycle(keyname, name, cycle); + DecodeNameCycle(keyname, name, cycle, kMaxLen); return GetKey(name,cycle); } @@ -732,7 +734,7 @@ TKey *TDirectoryFile::FindKeyAny(const char *keyname) const Short_t cycle; char name[kMaxLen]; - DecodeNameCycle(keyname, name, cycle); + DecodeNameCycle(keyname, name, cycle, kMaxLen); TIter next(GetListOfKeys()); TKey *key; @@ -775,7 +777,7 @@ TObject *TDirectoryFile::FindObjectAny(const char *aname) const Short_t cycle; char name[kMaxLen]; - DecodeNameCycle(aname, name, cycle); + DecodeNameCycle(aname, name, cycle, kMaxLen); TIter next(GetListOfKeys()); TKey *key; @@ -847,18 +849,18 @@ TObject *TDirectoryFile::Get(const char *namecycle) Short_t cycle; char name[kMaxLen]; - DecodeNameCycle(namecycle, name, cycle); - char *namobj = name; + DecodeNameCycle(namecycle, name, cycle, kMaxLen); Int_t nch = strlen(name); for (Int_t i = nch-1; i > 0; i--) { if (name[i] == '/') { name[i] = 0; TDirectory* dirToSearch=GetDirectory(name); - namobj = name + i + 1; + const char *subnamecycle = namecycle + i + 1; name[i] = '/'; - return dirToSearch?dirToSearch->Get(namobj):0; + return dirToSearch?dirToSearch->Get(subnamecycle):0; } } + const char *namobj = name; //*-*---------------------Case of Object in memory--------------------- // ======================== @@ -947,22 +949,22 @@ void *TDirectoryFile::GetObjectChecked(const char *namecycle, const TClass* expe Short_t cycle; char name[kMaxLen]; - DecodeNameCycle(namecycle, name, cycle); - char *namobj = name; + DecodeNameCycle(namecycle, name, cycle, kMaxLen); Int_t nch = strlen(name); for (Int_t i = nch-1; i > 0; i--) { if (name[i] == '/') { name[i] = 0; TDirectory* dirToSearch=GetDirectory(name); - namobj = name + i + 1; + const char *subnamecycle = namecycle + i + 1; name[i] = '/'; if (dirToSearch) { - return dirToSearch->GetObjectChecked(namobj, expectedClass); + return dirToSearch->GetObjectChecked(subnamecycle, expectedClass); } else { return 0; } } } + const char *namobj = name; //*-*---------------------Case of Object in memory--------------------- // ======================== @@ -1024,13 +1026,18 @@ TKey *TDirectoryFile::GetKey(const char *name, Short_t cycle) const //*-* ===================================== // if cycle = 9999 returns highest cycle // + + // TIter::TIter() already checks for null pointers + TIter next( ((THashList *)(GetListOfKeys()))->GetListForObject(name) ); + TKey *key; - TIter next(GetListOfKeys()); - while ((key = (TKey *) next())) + while (( key = (TKey *)next() )) { if (!strcmp(name, key->GetName())) { - if (cycle == 9999) return key; - if (cycle >= key->GetCycle()) return key; + if ((cycle == 9999) || (cycle >= key->GetCycle())) + return key; } + } + return 0; } @@ -1124,8 +1131,12 @@ TDirectory *TDirectoryFile::mkdir(const char *name, const char *title) char *workname = new char[size+1]; strncpy(workname, name, size); workname[size] = 0; - TDirectoryFile *tmpdir = (TDirectoryFile*)mkdir(workname,title); - if (!tmpdir) return 0; + TDirectoryFile *tmpdir; + GetObject(workname,tmpdir); + if (!tmpdir) { + tmpdir = (TDirectoryFile*)mkdir(workname,title); + if (!tmpdir) return 0; + } if (!newdir) newdir = tmpdir; tmpdir->mkdir(slash+1); delete[] workname; @@ -1782,7 +1793,7 @@ Int_t TDirectoryFile::WriteTObject(const TObject *obj, const char *name, Option_ // Remove trailing blanks in object name Int_t nch = strlen(oname); char *newName = 0; - if (oname[nch-1] == ' ') { + if (nch && oname[nch-1] == ' ') { newName = new char[nch+1]; strlcpy(newName,oname,nch+1); for (Int_t i=0;i<nch;i++) { @@ -1906,7 +1917,7 @@ Int_t TDirectoryFile::WriteObjectAny(const void *obj, const TClass *cl, const ch // Remove trailing blanks in object name Int_t nch = strlen(oname); char *newName = 0; - if (oname[nch-1] == ' ') { + if (nch && oname[nch-1] == ' ') { newName = new char[nch+1]; strlcpy(newName,oname,nch+1); for (Int_t i=0;i<nch;i++) { diff --git a/io/io/src/TEmulatedCollectionProxy.cxx b/io/io/src/TEmulatedCollectionProxy.cxx index 430adccf534ae..d6e3acfb6086d 100644 --- a/io/io/src/TEmulatedCollectionProxy.cxx +++ b/io/io/src/TEmulatedCollectionProxy.cxx @@ -32,6 +32,7 @@ #include "Riostream.h" #include "TVirtualMutex.h" // For R__LOCKGUARD +#include "TInterpreter.h" // For gCINTMutex // // Utility function to allow the creation of a TClass for a std::pair without @@ -76,16 +77,17 @@ TVirtualCollectionProxy* TEmulatedCollectionProxy::Generate() const return new TEmulatedCollectionProxy(*this); } -void TEmulatedCollectionProxy::Destructor(void* p, Bool_t dtorOnly) +void TEmulatedCollectionProxy::Destructor(void* p, Bool_t dtorOnly) const { // Virtual destructor if (!p) return; if (!fEnv || fEnv->fObject != p) { // Envoid the cost of TPushPop if we don't need it - TVirtualCollectionProxy::TPushPop env(this, p); - Clear("force"); + // FIXME: This is not thread safe. + TVirtualCollectionProxy::TPushPop env(const_cast<TEmulatedCollectionProxy*>(this), p); + const_cast<TEmulatedCollectionProxy*>(this)->Clear("force"); } else { - Clear("force"); + const_cast<TEmulatedCollectionProxy*>(this)->Clear("force"); } if (dtorOnly) { ((Cont_t*)p)->~Cont_t(); @@ -94,7 +96,7 @@ void TEmulatedCollectionProxy::Destructor(void* p, Bool_t dtorOnly) } } -void TEmulatedCollectionProxy::DeleteArray(void* p, Bool_t dtorOnly) +void TEmulatedCollectionProxy::DeleteArray(void* p, Bool_t dtorOnly) const { // Virtual array destructor @@ -109,7 +111,7 @@ void TEmulatedCollectionProxy::DeleteArray(void* p, Bool_t dtorOnly) TGenCollectionProxy *TEmulatedCollectionProxy::InitializeEx(Bool_t silent) { // Proxy initializer - R__LOCKGUARD2(gCollectionMutex); + R__LOCKGUARD2(gCINTMutex); if (fClass) return this; diff --git a/io/io/src/TEmulatedMapProxy.cxx b/io/io/src/TEmulatedMapProxy.cxx index ef734a3db53d7..6d39dc176e062 100644 --- a/io/io/src/TEmulatedMapProxy.cxx +++ b/io/io/src/TEmulatedMapProxy.cxx @@ -80,11 +80,12 @@ UInt_t TEmulatedMapProxy::Size() const return 0; } -void TEmulatedMapProxy::ReadMap(int nElements, TBuffer &b) +void TEmulatedMapProxy::ReadMap(UInt_t nElements, TBuffer &b) { // Map input streamer. Bool_t vsn3 = b.GetInfo() && b.GetInfo()->GetOldVersion()<=3; - int idx, loop, off[2] = {0, fValOffset }; + UInt_t idx, loop; + Int_t off[2] = {0, fValOffset }; Value *v, *val[2] = { fKey, fVal }; StreamHelper* helper; float f; @@ -144,7 +145,7 @@ void TEmulatedMapProxy::ReadMap(int nElements, TBuffer &b) } } -void TEmulatedMapProxy::WriteMap(int nElements, TBuffer &b) +void TEmulatedMapProxy::WriteMap(UInt_t nElements, TBuffer &b) { // Map output streamer. Value *v, *val[2] = { fKey, fVal }; @@ -152,7 +153,7 @@ void TEmulatedMapProxy::WriteMap(int nElements, TBuffer &b) StreamHelper* i; char* addr = 0; char* temp = (char*)At(0); - for (int loop, idx = 0; idx < nElements; ++idx ) { + for (UInt_t loop, idx = 0; idx < nElements; ++idx ) { addr = temp + idx*fValDiff; for ( loop = 0; loop<2; ++loop ) { addr += off[loop]; @@ -231,7 +232,7 @@ void TEmulatedMapProxy::Streamer(TBuffer &b) { // TClassStreamer IO overload. if ( b.IsReading() ) { //Read mode - int nElements = 0; + UInt_t nElements = 0; b >> nElements; if ( fEnv->fObject ) { Resize(nElements,true); @@ -241,7 +242,7 @@ void TEmulatedMapProxy::Streamer(TBuffer &b) } } else { // Write case - int nElements = fEnv->fObject ? Size() : 0; + UInt_t nElements = fEnv->fObject ? Size() : 0; b << nElements; if ( nElements > 0 ) { WriteMap(nElements, b); diff --git a/io/io/src/TFPBlock.cxx b/io/io/src/TFPBlock.cxx index e8672bf4deccd..122527f82a7fd 100644 --- a/io/io/src/TFPBlock.cxx +++ b/io/io/src/TFPBlock.cxx @@ -25,6 +25,9 @@ #include "TStorage.h" #include <cstdlib> +using std::calloc; +using std::free; +using std::realloc; ClassImp(TFPBlock) @@ -33,19 +36,23 @@ TFPBlock::TFPBlock(Long64_t* offset, Int_t* length, Int_t nb) { // Constructor. - Int_t aux = 0; + Long64_t aux = 0; fNblock = nb; fPos = new Long64_t[nb]; + fRelOffset = new Long64_t[nb]; fLen = new Int_t[nb]; for (Int_t i=0; i < nb; i++){ fPos[i] = offset[i]; fLen[i] = length[i]; + fRelOffset[i] = aux; aux += length[i]; } - fFullSize = aux; - fBuffer = new char[fFullSize]; + + fCapacity = aux; + fDataSize = aux; + fBuffer = (char*) calloc(fCapacity, sizeof(char)); } //__________________________________________________________________ @@ -55,63 +62,8 @@ TFPBlock::~TFPBlock() delete[] fPos; delete[] fLen; - delete[] fBuffer; -} - -//__________________________________________________________________ -Long64_t* TFPBlock::GetPos() const -{ - // Get pointer to the array of postions. - - return fPos; -} - -//__________________________________________________________________ -Int_t* TFPBlock::GetLen() const -{ - // Get pointer to the array of lengths. - - return fLen; -} - -//__________________________________________________________________ -Int_t TFPBlock::GetFullSize() const -{ - // Return size of the block. - - return fFullSize; -} - -//__________________________________________________________________ -Int_t TFPBlock::GetNoElem() const -{ - // Return number of elements in the block. - - return fNblock; -} - -//__________________________________________________________________ -Long64_t TFPBlock::GetPos(Int_t i) const -{ - // Get position of the element at index i. - - return fPos[i]; -} - -//__________________________________________________________________ -Int_t TFPBlock::GetLen(Int_t i) const -{ - // Get length of the element at index i. - - return fLen[i]; -} - -//__________________________________________________________________ -char* TFPBlock::GetBuffer() const -{ - // Get block buffer. - - return fBuffer; + delete[] fRelOffset; + free(fBuffer); } @@ -128,8 +80,11 @@ void TFPBlock::SetPos(Int_t idx, Long64_t value) void TFPBlock::SetBuffer(char* buf) { // Set block buffer. - + if ( fBuffer ) { + free(fBuffer); + } fBuffer = buf; + } //__________________________________________________________________ @@ -138,19 +93,24 @@ void TFPBlock::ReallocBlock(Long64_t* offset, Int_t* length, Int_t nb) // Reallocate the block's buffer based on the length // of the elements it will contain. - Int_t aux = 0; + Long64_t newSize = 0; fPos = (Long64_t*) TStorage::ReAlloc(fPos, nb * sizeof(Long64_t), fNblock * sizeof(Long64_t)); + fRelOffset = (Long64_t*) TStorage::ReAlloc(fRelOffset, nb * sizeof(Long64_t), fNblock * sizeof(Long64_t)); fLen = TStorage::ReAllocInt(fLen, nb, fNblock); fNblock = nb; for(Int_t i=0; i < nb; i++){ - fPos[i] = offset[i]; fLen[i] = length[i]; - aux += fLen[i]; + fRelOffset[i] = newSize; + newSize += fLen[i]; + } + + if (newSize > fCapacity) { + fCapacity = newSize; + fBuffer = (char*) realloc(fBuffer, fCapacity); } - fBuffer = TStorage::ReAllocChar(fBuffer, aux, fFullSize); - fFullSize = aux; + fDataSize = newSize; } diff --git a/io/io/src/TFile.cxx b/io/io/src/TFile.cxx index e636de7093037..17b856fc61bf9 100644 --- a/io/io/src/TFile.cxx +++ b/io/io/src/TFile.cxx @@ -1,4 +1,3 @@ - // @(#)root/io:$Id$ // Author: Rene Brun 28/11/94 @@ -98,6 +97,7 @@ #include "TPluginManager.h" #include "TProcessUUID.h" #include "TRegexp.h" +#include "TPRegexp.h" #include "TROOT.h" #include "TStreamerInfo.h" #include "TStreamerElement.h" @@ -501,21 +501,24 @@ TFile::TFile(const TFile &) : TDirectoryFile(), fInfoCache(0) TFile::~TFile() { // File destructor. + Close(); + SafeDelete(fAsyncHandle); + SafeDelete(fCacheRead); + SafeDelete(fCacheReadMap); + SafeDelete(fCacheWrite); SafeDelete(fProcessIDs); SafeDelete(fFree); SafeDelete(fArchive); SafeDelete(fInfoCache); SafeDelete(fOpenPhases); - SafeDelete(fAsyncHandle); - SafeDelete(fCacheRead); - SafeDelete(fCacheReadMap); - SafeDelete(fCacheWrite); - R__LOCKGUARD2(gROOTMutex); - gROOT->GetListOfClosedObjects()->Remove(this); - gROOT->GetUUIDs()->RemoveUUID(GetUniqueID()); + { + R__LOCKGUARD2(gROOTMutex); + gROOT->GetListOfClosedObjects()->Remove(this); + gROOT->GetUUIDs()->RemoveUUID(GetUniqueID()); + } if (IsOnHeap()) { // Delete object from CINT symbol table so it can not be used anymore. @@ -649,6 +652,12 @@ void TFile::Init(Bool_t create) frombuf(buffer, &fSeekInfo); frombuf(buffer, &fNbytesInfo); } + if (fBEGIN < 0 || fBEGIN > fEND) { + // humm fBEGIN is wrong .... + Error("Init","file %s has an incorrect header length (%lld) or incorrect end of file length (%lld)", + GetName(),fBEGIN,fEND); + goto zombie; + } fSeekDir = fBEGIN; //*-*-------------Read Free segments structure if file is writable if (fWritable) { @@ -664,6 +673,12 @@ void TFile::Init(Bool_t create) char *buffer_keyloc = 0; Int_t nbytes = fNbytesName + TDirectoryFile::Sizeof(); + if ( (nbytes + fBEGIN) > fEND) { + // humm fBEGIN is wrong .... + Error("Init","file %s has an incorrect header length (%lld) or incorrect end of file length (%lld)", + GetName(),fBEGIN+nbytes,fEND); + goto zombie; + } if (nbytes+fBEGIN > kBEGIN+200) { delete [] header; header = new char[nbytes]; @@ -859,9 +874,17 @@ void TFile::Close(Option_t *option) WriteStreamerInfo(); } - delete fClassIndex; - fClassIndex = 0; - + // Finish any concurrent I/O operations before we close the file handles. + if (fCacheRead) fCacheRead->Close(); + { + TIter iter(fCacheReadMap); + TObject *key = 0; + while ((key = iter()) != 0) { + TFileCacheRead *cache = dynamic_cast<TFileCacheRead *>(fCacheReadMap->GetValue(key)); + cache->Close(); + } + } + // Delete all supported directories structures from memory // If gDirectory points to this object or any of the nested // TDirectoryFile, TDirectoryFile::Close will induce the proper cd. @@ -880,6 +903,9 @@ void TFile::Close(Option_t *option) if (gMonitoringWriter) gMonitoringWriter->SendFileCloseEvent(this); + delete fClassIndex; + fClassIndex = 0; + // Delete free segments from free list (but don't delete list header) if (fFree) { fFree->Delete(); @@ -1241,7 +1267,7 @@ TList *TFile::GetStreamerInfoList() return 0; } key->ReadKeyBuffer(buf); - list = (TList*)key->ReadObjWithBuffer(buffer); + list = dynamic_cast<TList*>(key->ReadObjWithBuffer(buffer)); if (list) list->SetOwner(); delete [] buffer; delete key; @@ -2048,13 +2074,26 @@ void TFile::SetCompressionSettings(Int_t settings) } //______________________________________________________________________________ -void TFile::SetCacheRead(TFileCacheRead *cache, TObject* tree) +void TFile::SetCacheRead(TFileCacheRead *cache, TObject* tree, ECacheAction action) { // Set a pointer to the read cache. // NOTE: This relinquish ownership of the previous cache, so if you do not // already have a pointer to the previous cache (and there was a previous // cache), you ought to retrieve (and delete it if needed) using: // TFileCacheRead *older = myfile->GetCacheRead(); + // + // NOTE: the action specifies how to behave when detaching a cache from the + // the TFile. If set to (default) kDisconnect, the contents of the cache + // will be flushed when it is removed from the file, and it will disconnect + // the cache object from the file. In almost all cases, this is what you want. + // If you want to disconnect the cache temporarily from this tree and re-attach + // later to the same fil, you can set action to kDoNotDisconnect. This will allow + // things like prefetching to continue in the background while it is no longer the + // default cache for the TTree. Except for a few expert use cases, kDisconnect is + // likely the correct setting. + // + // WARNING: if action=kDoNotDisconnect, you MUST delete the cache before TFile. + // if (tree) { if (cache) fCacheReadMap->Add(tree, cache); @@ -2062,12 +2101,12 @@ void TFile::SetCacheRead(TFileCacheRead *cache, TObject* tree) // The only addition to fCacheReadMap is via an interface that takes // a TFileCacheRead* so the C-cast is safe. TFileCacheRead* tpf = (TFileCacheRead *)fCacheReadMap->GetValue(tree); - if (tpf && tpf->GetFile() == this) tpf->SetFile(0); fCacheReadMap->RemoveEntry(tree); + if (tpf && (tpf->GetFile() == this) && (action != kDoNotDisconnect)) tpf->SetFile(0, action); } } - if (cache) cache->SetFile(this); - else if (!tree && fCacheRead) fCacheRead->SetFile(0); + if (cache) cache->SetFile(this, action); + else if (!tree && fCacheRead && (action != kDoNotDisconnect)) fCacheRead->SetFile(0, action); // For backward compatibility the last Cache set is the default cache. fCacheRead = cache; } @@ -3659,7 +3698,7 @@ TFile *TFile::OpenFromCache(const char *name, Option_t *, const char *ftitle, tagfile += ".ROOT.cachefile"; tagurl.SetFile(tagfile); // we symlink this file as a ROOT cached file - gSystem->Symlink(cachefilepath, tagfile); + gSystem->Symlink(gSystem->BaseName(cachefilepath), tagfile); return TFile::Open(fileurl.GetUrl(), "READ", ftitle, compress, netopt); } } @@ -3984,7 +4023,8 @@ TFileOpenHandle *TFile::AsyncOpen(const char *url, Option_t *option, if (type == kNet) { // Network files if ((h = gROOT->GetPluginManager()->FindHandler("TFile", name)) && - !strcmp(h->GetClass(),"TXNetFile") && h->LoadPlugin() == 0) { + (!strcmp(h->GetClass(),"TXNetFile") || !strcmp(h->GetClass(),"TNetXNGFile")) + && h->LoadPlugin() == 0) { f = (TFile*) h->ExecPlugin(6, name.Data(), option, ftitle, compress, netopt, kTRUE); notfound = kFALSE; } @@ -4406,9 +4446,8 @@ TFile::EFileType TFile::GetType(const char *name, Option_t *option, TString *pre EFileType type = kDefault; - TRegexp re("^root.*:"); - TString sname = name; - if (sname.Index(re) != kNPOS) { + TPMERegexp re("^(root|xroot).*", "i"); + if (re.Match(name)) { // // Should be a network file ... type = kNet; @@ -4466,9 +4505,7 @@ TFile::EFileType TFile::GetType(const char *name, Option_t *option, TString *pre // // Adjust the type according to findings type = (localFile) ? kLocal : type; - } else if (!strncmp(name, "http:", 5) || - !strncmp(name, "as3:", 4) || - !strncmp(name, "gs:", 3)) { + } else if (TPMERegexp("^(http[s]?|s3http[s]?|[a]?s3|gs|gshttp[s]?){1}:", "i").Match(name)) { // // Web file type = kWeb; @@ -4579,7 +4616,7 @@ void TFile::CpProgress(Long64_t bytesread, Long64_t size, TStopwatch &watch) watch.Stop(); Double_t lCopy_time = watch.RealTime(); fprintf(stderr, "| %.02f %% [%.01f MB/s]\r", - 100.0*(size?(bytesread/size):1), bytesread/lCopy_time/1048576.); + 100.0*(size?(bytesread/((float)size)):1), bytesread/lCopy_time/1048576.); watch.Continue(); } diff --git a/io/io/src/TFileCacheRead.cxx b/io/io/src/TFileCacheRead.cxx index 8f2ef48e57e7b..3c51a2ac35a9d 100644 --- a/io/io/src/TFileCacheRead.cxx +++ b/io/io/src/TFileCacheRead.cxx @@ -137,41 +137,17 @@ TFileCacheRead::TFileCacheRead(TFile *file, Int_t buffersize, TObject *tree) //initialise the prefetch object and set the cache directory // start the thread only if the file is not local fEnablePrefetching = gEnv->GetValue("TFile.AsyncPrefetching", 0); + if (fEnablePrefetching && strcmp(file->GetEndpointUrl()->GetProtocol(), "file")){ - fPrefetch = new TFilePrefetch(file); - const char* cacheDir = gEnv->GetValue("Cache.Directory", ""); - if (strcmp(cacheDir, "")) - if (!fPrefetch->SetCache((char*) cacheDir)) - fprintf(stderr, "Error while trying to set the cache directory.\n"); - if (fPrefetch->ThreadStart()){ - fprintf(stderr,"Error stating prefetching thread. Disabling prefetching.\n"); - fEnablePrefetching = 0; - } + SetEnablePrefetchingImpl(true); } - else //disable the async pref for local files - fEnablePrefetching = 0; - - //environment variable used to switch to the new method of reading asynchronously - if (fEnablePrefetching){ - fAsyncReading = kFALSE; + else {//disable the async pref for local files + SetEnablePrefetchingImpl(false); } - else { - fAsyncReading = gEnv->GetValue("TFile.AsyncReading", 0); - if (fAsyncReading) { - // Check if asynchronous reading is supported by this TFile specialization - fAsyncReading = kFALSE; - if (file && !(file->ReadBufferAsync(0, 0))) - fAsyncReading = kTRUE; - } - if (!fAsyncReading) { - // we use sync primitives, hence we need the local buffer - fBuffer = new char[fBufferSize]; - } - } - fIsSorted = kFALSE; - fIsTransferred = kFALSE; - fBIsSorted = kFALSE; + fIsSorted = kFALSE; + fIsTransferred = kFALSE; + fBIsSorted = kFALSE; fBIsTransferred = kFALSE; if (file) file->SetCacheRead(this, tree); @@ -191,7 +167,8 @@ TFileCacheRead::~TFileCacheRead() delete [] fSeekSortLen; delete [] fSeekPos; delete [] fLen; - delete [] fBuffer; + if (fBuffer) + delete [] fBuffer; delete [] fBSeek; delete [] fBSeekIndex; delete [] fBSeekSort; @@ -202,6 +179,21 @@ TFileCacheRead::~TFileCacheRead() delete [] fBLen; } +//_____________________________________________________________________________ +void TFileCacheRead::Close(Option_t * /* opt = "" */) +{ + // Close out any threads or asynchronous fetches used by the underlying + // implementation. + // This is called by TFile::Close to prevent usage of the file handles + // after the closing of the file. + + if (fPrefetch) { + delete fPrefetch; + fPrefetch = 0; + } + +} + //_____________________________________________________________________________ void TFileCacheRead::Prefetch(Long64_t pos, Int_t len) { @@ -391,7 +383,7 @@ Int_t TFileCacheRead::ReadBufferExt(char *buf, Long64_t pos, Int_t len, Int_t &l //_____________________________________________________________________________ Int_t TFileCacheRead::ReadBufferExtPrefetch(char *buf, Long64_t pos, Int_t len, Int_t &loc) { - //prefetch the first block + //prefetch the first block if (fNseek > 0 && !fIsSorted) { Sort(); loc = -1; @@ -425,8 +417,8 @@ Int_t TFileCacheRead::ReadBufferExtPrefetch(char *buf, Long64_t pos, Int_t len, if (buf && fPrefetch){ //prefetch with the new method fPrefetch->ReadBuffer(buf, pos, len); + return 1; } - return 1; } else if (buf && fPrefetch){ //try to preferch from the second block @@ -534,7 +526,7 @@ Int_t TFileCacheRead::ReadBufferExtNormal(char *buf, Long64_t pos, Int_t len, In } //_____________________________________________________________________________ -void TFileCacheRead::SetFile(TFile *file) +void TFileCacheRead::SetFile(TFile *file, TFile::ECacheAction action) { // Set the file using this cache and reset the current blocks (if any). @@ -549,10 +541,12 @@ void TFileCacheRead::SetFile(TFile *file) } } - Prefetch(0,0); + if (action == TFile::kDisconnect) + Prefetch(0,0); if (fPrefetch) { - SecondPrefetch(0, 0); + if (action == TFile::kDisconnect) + SecondPrefetch(0, 0); fPrefetch->SetFile(file); } } @@ -677,3 +671,71 @@ TFilePrefetch* TFileCacheRead::GetPrefetchObj(){ return this->fPrefetch; } + + +//_____________________________________________________________________________ +void TFileCacheRead::WaitFinishPrefetch() +{ + if ( fEnablePrefetching && fPrefetch ) { + fPrefetch->WaitFinishPrefetch(); + } +} + + +//______________________________________________________________________________ +void TFileCacheRead::SetEnablePrefetching(Bool_t setPrefetching) +{ + // Set the prefetching mode of this file. + // if 'setPrefetching', enable the asynchronous prefetching + // (using TFilePrefetch) and if the gEnv and rootrc + // variable Cache.Directory is set, also enable the local + // caching of the prefetched blocks. + // if 'setPrefetching', the old prefetcher is enabled is + // the gEnv and rootrc variable is TFile.AsyncReading + + SetEnablePrefetchingImpl(setPrefetching); +} + +//______________________________________________________________________________ +void TFileCacheRead::SetEnablePrefetchingImpl(Bool_t setPrefetching) +{ + // TFileCacheRead implementation of SetEnablePrefetching. + // + // This function is called from the constructor and should not be virtual. + + fEnablePrefetching = setPrefetching; + + if (!fPrefetch && fEnablePrefetching) { + fPrefetch = new TFilePrefetch(fFile); + const char* cacheDir = gEnv->GetValue("Cache.Directory", ""); + if (strcmp(cacheDir, "")) + if (!fPrefetch->SetCache((char*) cacheDir)) + fprintf(stderr, "Error while trying to set the cache directory: %s.\n", cacheDir); + if (fPrefetch->ThreadStart()){ + fprintf(stderr,"Error stating prefetching thread. Disabling prefetching.\n"); + fEnablePrefetching = 0; + } + } else if (fPrefetch && !fEnablePrefetching) { + SafeDelete(fPrefetch); + fPrefetch = NULL; + } + + //environment variable used to switch to the new method of reading asynchronously + if (fEnablePrefetching) { + fAsyncReading = kFALSE; + } + else { + fAsyncReading = gEnv->GetValue("TFile.AsyncReading", 0); + if (fAsyncReading) { + // Check if asynchronous reading is supported by this TFile specialization + fAsyncReading = kFALSE; + if (fFile && !(fFile->ReadBufferAsync(0, 0))) + fAsyncReading = kTRUE; + } + if (!fAsyncReading && fBuffer == 0) { + // we use sync primitives, hence we need the local buffer + fBuffer = new char[fBufferSize]; + } + } +} + diff --git a/io/io/src/TFileMerger.cxx b/io/io/src/TFileMerger.cxx index d74fc3fb4e53f..e05c58fc71f5a 100644 --- a/io/io/src/TFileMerger.cxx +++ b/io/io/src/TFileMerger.cxx @@ -87,7 +87,7 @@ static Int_t R__GetSystemMaxOpenedFiles() TFileMerger::TFileMerger(Bool_t isLocal, Bool_t histoOneGo) : fOutputFile(0), fFastMethod(kTRUE), fNoTrees(kFALSE), fExplicitCompLevel(kFALSE), fCompressionChange(kFALSE), fPrintLevel(0), fMsgPrefix("TFileMerger"), fMaxOpenedFiles( R__GetSystemMaxOpenedFiles() ), - fLocal(isLocal), fHistoOneGo(histoOneGo) + fLocal(isLocal), fHistoOneGo(histoOneGo), fObjectNames() { // Create file merger object. @@ -122,6 +122,7 @@ void TFileMerger::Reset() fFileList->Clear(); fMergeList->Clear(); fExcessFiles->Clear(); + fObjectNames.Clear(); } //______________________________________________________________________________ @@ -148,21 +149,19 @@ Bool_t TFileMerger::AddFile(const char *url, Bool_t cpProgress) } // We want gDirectory untouched by anything going on here - TDirectory *dirsave = gDirectory; + TDirectory::TContext ctx(0); if (fLocal) { TUUID uuid; localcopy.Form("file:%s/ROOTMERGE-%s.root", gSystem->TempDirectory(), uuid.AsString()); if (!TFile::Cp(url, localcopy, cpProgress)) { Error("AddFile", "cannot get a local copy of file %s", url); - gDirectory = dirsave; return kFALSE; } newfile = TFile::Open(localcopy, "READ"); } else { newfile = TFile::Open(url, "READ"); } - gDirectory = dirsave; if (!newfile) { if (fLocal) @@ -226,20 +225,18 @@ Bool_t TFileMerger::AddFile(TFile *source, Bool_t own, Bool_t cpProgress) TString localcopy; // We want gDirectory untouched by anything going on here - TDirectory *dirsave = gDirectory; + TDirectory::TContext ctx(0); if (fLocal && !source->InheritsFrom(TMemFile::Class())) { TUUID uuid; localcopy.Form("file:%s/ROOTMERGE-%s.root", gSystem->TempDirectory(), uuid.AsString()); if (!source->Cp(localcopy, cpProgress)) { Error("AddFile", "cannot get a local copy of file %s", source->GetName()); - gDirectory = dirsave; return kFALSE; } newfile = TFile::Open(localcopy, "READ"); } else { newfile = source; } - gDirectory = dirsave; if (!newfile) { if (fLocal) @@ -305,13 +302,11 @@ Bool_t TFileMerger::OutputFile(const char *outputfile, const char *mode, Int_t c fOutputFilename = outputfile; // We want gDirectory untouched by anything going on here - TDirectory *dirsave = gDirectory; + TDirectory::TContext ctx(0); if (!(fOutputFile = TFile::Open(outputfile, mode, "", compressionLevel)) || fOutputFile->IsZombie()) { Error("OutputFile", "cannot open the MERGER output file %s", fOutputFilename.Data()); - gDirectory = dirsave; return kFALSE; } - gDirectory = dirsave; return kTRUE; } @@ -356,8 +351,11 @@ Bool_t TFileMerger::MergeRecursive(TDirectory *target, TList *sourcelist, Int_t // kAll : merge all type of objects (default) // kResetable : merge only the objects with a MergeAfterReset member function. // kNonResetable : merge only the objects without a MergeAfterReset member function. + // kOnlyListed : merge only objects listed in fObjectNames + // kSkipListed : skip merging of objects listed in fObjectNames Bool_t status = kTRUE; + Bool_t onlyListed = kFALSE; if (fPrintLevel > 0) { Printf("%s Target path: %s",fMsgPrefix.Data(),target->GetPath()); } @@ -370,6 +368,14 @@ Bool_t TFileMerger::MergeRecursive(TDirectory *target, TList *sourcelist, Int_t Int_t nguess = sourcelist->GetSize()+1000; THashList allNames(nguess); allNames.SetOwner(kTRUE); + // If the mode is set to skipping list objects, add names to the allNames list + if (type & kSkipListed) { + TObjArray *arr = fObjectNames.Tokenize(" "); + arr->SetOwner(kFALSE); + for (Int_t iname=0; iname<arr->GetEntriesFast(); iname++) + allNames.Add(arr->At(iname)); + delete arr; + } ((THashList*)target->GetList())->Rehash(nguess); ((THashList*)target->GetListOfKeys())->Rehash(nguess); @@ -399,13 +405,15 @@ Bool_t TFileMerger::MergeRecursive(TDirectory *target, TList *sourcelist, Int_t TString oldkeyname; while ( (key = (TKey*)nextkey())) { - - // Keep only the highest cycle number for each key. They are stored in the (hash) list - // consecutively and in decreasing order of cycles, so we can continue until the name - // changes. - if (oldkeyname == key->GetName()) continue; + + // Keep only the highest cycle number for each key for mergeable objects. They are stored + // in the (hash) list onsecutively and in decreasing order of cycles, so we can continue + // until the name changes. We flag the case here and we act consequently later. + Bool_t alreadyseen = (oldkeyname == key->GetName()) ? kTRUE : kFALSE; + // Read in but do not copy directly the processIds. if (strcmp(key->GetClassName(),"TProcessID") == 0) { key->ReadObj(); continue;} + // If we have already seen this object [name], we already processed // the whole list of files for this objects and we can just skip it // and any related cycles. @@ -413,14 +421,29 @@ Bool_t TFileMerger::MergeRecursive(TDirectory *target, TList *sourcelist, Int_t oldkeyname = key->GetName(); continue; } - + TClass *cl = TClass::GetClass(key->GetClassName()); if (!cl || !cl->InheritsFrom(TObject::Class())) { Info("MergeRecursive", "cannot merge object type, name: %s title: %s", key->GetName(), key->GetTitle()); continue; } - allNames.Add(new TObjString(key->GetName())); + // Check if only the listed objects are to be merged + if (type & kOnlyListed) { + onlyListed = kFALSE; + oldkeyname = key->GetName(); + oldkeyname += " "; + onlyListed = fObjectNames.Contains(oldkeyname); + oldkeyname = key->GetName(); + if ((!onlyListed) && (!cl->InheritsFrom(TDirectory::Class()))) continue; + } + // For mergeable objects we add the names in a local hashlist handling them + // again (see above) + if (cl->GetMerge() || cl->InheritsFrom(TDirectory::Class()) || + (cl->InheritsFrom(TObject::Class()) && + (cl->GetMethodWithPrototype("Merge", "TCollection*,TFileMergeInfo*") || + cl->GetMethodWithPrototype("Merge", "TCollection*")))) + allNames.Add(new TObjString(key->GetName())); if (fNoTrees && cl->InheritsFrom(R__TTree_Class)) { // Skip the TTree objects and any related cycles. @@ -468,7 +491,9 @@ Bool_t TFileMerger::MergeRecursive(TDirectory *target, TList *sourcelist, Int_t target->cd(); TDirectory *newdir; - if (type & kIncremental) { + + // For incremental or already seen we may have already a directory created + if (type & kIncremental || alreadyseen) { newdir = target->GetDirectory(obj->GetName()); if (!newdir) { newdir = target->mkdir( obj->GetName(), obj->GetTitle() ); @@ -476,14 +501,22 @@ Bool_t TFileMerger::MergeRecursive(TDirectory *target, TList *sourcelist, Int_t } else { newdir = target->mkdir( obj->GetName(), obj->GetTitle() ); } - + // newdir is now the starting point of another round of merging // newdir still knows its depth within the target file via // GetPath(), so we can still figure out where we are in the recursion + + + // If this folder is a onlyListed object, merge everything inside. + if (onlyListed) type &= ~kOnlyListed; status = MergeRecursive(newdir, sourcelist, type); + if (onlyListed) type |= kOnlyListed; if (!status) return status; } else if (obj->IsA()->GetMerge()) { + // Check if already treated + if (alreadyseen) continue; + TList inputs; Bool_t oneGo = fHistoOneGo && obj->IsA()->InheritsFrom(R__TH1_Class); @@ -541,6 +574,9 @@ Bool_t TFileMerger::MergeRecursive(TDirectory *target, TList *sourcelist, Int_t obj->IsA()->GetMethodWithPrototype("Merge", "TCollection*,TFileMergeInfo*") ) { // Object implements Merge(TCollection*,TFileMergeInfo*) and has a reflex dictionary ... + // Check if already treated + if (alreadyseen) continue; + TList listH; TString listHargs; listHargs.Form("(TCollection*)0x%lx,(TFileMergeInfo*)0x%lx", (ULong_t)&listH,(ULong_t)&info); @@ -601,6 +637,9 @@ Bool_t TFileMerger::MergeRecursive(TDirectory *target, TList *sourcelist, Int_t obj->IsA()->GetMethodWithPrototype("Merge", "TCollection*") ) { // Object implements Merge(TCollection*) and has a reflex dictionary ... + // Check if already treated + if (alreadyseen) continue; + TList listH; TString listHargs; listHargs.Form("((TCollection*)0x%lx)", (ULong_t)&listH); @@ -658,42 +697,7 @@ Bool_t TFileMerger::MergeRecursive(TDirectory *target, TList *sourcelist, Int_t } } else { // Object is of no type that we can merge - Bool_t warned = kFALSE; canBeMerged = kFALSE; - - // Loop over all source files and write similar objects directly to the output file - TFile *nextsource = current_file ? (TFile*)sourcelist->After( current_file ) : (TFile*)sourcelist->First(); - while (nextsource) { - // make sure we are at the correct directory level by cd'ing to path - TDirectory *ndir = nextsource->GetDirectory(path); - if (ndir) { - ndir->cd(); - TKey *key2 = (TKey*)ndir->GetListOfKeys()->FindObject(key->GetName()); - if (key2) { - if (!warned) { - Warning("MergeRecursive", "cannot merge object type (n:'%s', t:'%s') - " - "Merge(TCollection *) not implemented", - obj->GetName(), obj->GetTitle()); - warned = kTRUE; - } - TObject *nobj = key2->ReadObj(); - if (!nobj) { - Info("MergeRecursive", "could not read object for key {%s, %s}; skipping file %s", - key->GetName(), key->GetTitle(), nextsource->GetName()); - nextsource = (TFile*)sourcelist->After(nextsource); - continue; - } - nobj->ResetBit(kMustCleanup); - if (target->WriteTObject(nobj, key2->GetName(), "SingleKey") <= 0) { - Warning("MergeRecursive", "problems copying object (n:'%s', t:'%s') to output file ", - obj->GetName(), obj->GetTitle()); - status = kFALSE; - } - delete nobj; - } - } - nextsource = (TFile*)sourcelist->After( nextsource ); - } } // now write the merged histogram (which is "in" obj) to the target file @@ -722,10 +726,11 @@ Bool_t TFileMerger::MergeRecursive(TDirectory *target, TList *sourcelist, Int_t delete obj; } else { // Don't overwrite, if the object were not merged. + // NOTE: this is probably wrong for emulated objects. if ( obj->Write( oldkeyname, canBeMerged ? TObject::kOverwrite : 0) <= 0) { status = kFALSE; } - delete obj; + cl->Destructor(obj); // just in case the class is not loaded. } info.Reset(); } // while ( ( TKey *key = (TKey*)nextkey() ) ) @@ -766,7 +771,7 @@ Bool_t TFileMerger::PartialMerge(Int_t in_type) TString outf(fOutputFilename); if (outf.IsNull()) { outf.Form("file:%s/FileMerger.root", gSystem->TempDirectory()); - Info("Merge", "will merge the results to the file %s\n" + Info("PartialMerge", "will merge the results to the file %s\n" "since you didn't specify a merge filename", TUrl(outf).GetFile()); } @@ -774,7 +779,36 @@ Bool_t TFileMerger::PartialMerge(Int_t in_type) return kFALSE; } } - + + // Special treament for the single file case ... + if ((fFileList->GetEntries() == 1) && !fExcessFiles->GetEntries() && + !(in_type & kIncremental) && !fCompressionChange && !fExplicitCompLevel) { + fOutputFile->Close(); + SafeDelete(fOutputFile); + + TFile *file = (TFile *) fFileList->First(); + if (!file || (file && file->IsZombie())) { + Error("PartialMerge", "one-file case: problem attaching to file"); + return kFALSE; + } + Bool_t result = kTRUE; + if (!(result = file->Cp(fOutputFilename))) { + Error("PartialMerge", "one-file case: could not copy '%s' to '%s'", + file->GetPath(), fOutputFilename.Data()); + return kFALSE; + } + if (file->TestBit(kCanDelete)) file->Close(); + + // Remove the temporary file + if (fLocal) { + TUrl u(file->GetPath(), kTRUE); + if (gSystem->Unlink(u.GetFile()) != 0) + Warning("PartialMerge", "problems removing temporary local file '%s'", u.GetFile()); + } + fFileList->Clear(); + return result; + } + fOutputFile->SetBit(kMustCleanup); TDirectory::TContext ctxt(0); @@ -842,7 +876,7 @@ Bool_t TFileMerger::OpenExcessFiles() TObjString *url = 0; TString localcopy; // We want gDirectory untouched by anything going on here - TDirectory *dirsave = gDirectory; + TDirectory::TContext ctx(0); while( nfiles < (fMaxOpenedFiles-1) && ( url = (TObjString*)next() ) ) { TFile *newfile = 0; if (fLocal) { @@ -850,7 +884,6 @@ Bool_t TFileMerger::OpenExcessFiles() localcopy.Form("file:%s/ROOTMERGE-%s.root", gSystem->TempDirectory(), uuid.AsString()); if (!TFile::Cp(url->GetName(), localcopy, url->TestBit(kCpProgress))) { Error("OpenExcessFiles", "cannot get a local copy of file %s", url->GetName()); - gDirectory = dirsave; return kFALSE; } newfile = TFile::Open(localcopy, "READ"); @@ -864,7 +897,6 @@ Bool_t TFileMerger::OpenExcessFiles() localcopy.Data(), url->GetName()); else Error("OpenExcessFiles", "cannot open file %s", url->GetName()); - gDirectory = dirsave; return kFALSE; } else { if (fOutputFile && fOutputFile->GetCompressionLevel() != newfile->GetCompressionLevel()) fCompressionChange = kTRUE; @@ -875,7 +907,6 @@ Bool_t TFileMerger::OpenExcessFiles() fExcessFiles->Remove(url); } } - gDirectory = dirsave; return kTRUE; } @@ -885,7 +916,7 @@ void TFileMerger::RecursiveRemove(TObject *obj) // Intercept the case where the output TFile is deleted! if (obj == fOutputFile) { - Fatal("RecursiveRemove","Output file of the TFile Merger (targetting %s) has been deleted (likely due to a TTree larger than 100Gb)", fOutputFilename.Data()); + Fatal("RecursiveRemove","Output file of the TFile Merger (targeting %s) has been deleted (likely due to a TTree larger than 100Gb)", fOutputFilename.Data()); } } diff --git a/io/io/src/TFilePrefetch.cxx b/io/io/src/TFilePrefetch.cxx index 729025ca4a0f4..44d7fac02566d 100644 --- a/io/io/src/TFilePrefetch.cxx +++ b/io/io/src/TFilePrefetch.cxx @@ -30,45 +30,69 @@ using namespace std; ClassImp(TFilePrefetch) //____________________________________________________________________________________________ -TFilePrefetch::TFilePrefetch(TFile* file) +TFilePrefetch::TFilePrefetch(TFile* file) : + fFile(file), + fConsumer(0), + fThreadJoined(kTRUE) { // Constructor. - fConsumer = 0; - fFile = file; fPendingBlocks = new TList(); fReadBlocks = new TList(); + + fPendingBlocks->SetOwner(); + fReadBlocks->SetOwner(); + fMutexReadList = new TMutex(); fMutexPendingList = new TMutex(); - fMutexSynch = new TMutex(); fNewBlockAdded = new TCondition(0); fReadBlockAdded = new TCondition(0); - fSem = new TSemaphore(0); + fSemMasterWorker = new TSemaphore(0); + fSemWorkerMaster = new TSemaphore(0); + fSemChangeFile = new TSemaphore(0); } //____________________________________________________________________________________________ TFilePrefetch::~TFilePrefetch() { - // Destructor. + // Destructor + + if (!fThreadJoined) { + WaitFinishPrefetch(); + } - //killing consumer thread - fMutexSynch->Lock(); //wait fo thread to finish work - fMutexSynch->UnLock(); - fSem->Post(); //send terminate signal - fNewBlockAdded->Signal(); - fConsumer->Join(); - SafeDelete(fConsumer); SafeDelete(fPendingBlocks); SafeDelete(fReadBlocks); SafeDelete(fMutexReadList); SafeDelete(fMutexPendingList); - SafeDelete(fMutexSynch); SafeDelete(fNewBlockAdded); SafeDelete(fReadBlockAdded); - SafeDelete(fSem); + SafeDelete(fSemMasterWorker); + SafeDelete(fSemWorkerMaster); + SafeDelete(fSemChangeFile); } + +//____________________________________________________________________________________________ +void TFilePrefetch::WaitFinishPrefetch() +{ + // Killing the async prefetching thread + + fSemMasterWorker->Post(); + + TMutex *mutexCond = fNewBlockAdded->GetMutex(); + while ( fSemWorkerMaster->Wait(10) != 0 ) { + mutexCond->Lock(); + fNewBlockAdded->Signal(); + mutexCond->UnLock(); + } + + fConsumer->Join(); + fThreadJoined=kTRUE; +} + + //____________________________________________________________________________________________ void TFilePrefetch::ReadAsync(TFPBlock* block, Bool_t &inCache) { @@ -77,7 +101,7 @@ void TFilePrefetch::ReadAsync(TFPBlock* block, Bool_t &inCache) char* path = 0; if (CheckBlockInCache(path, block)){ - block->SetBuffer(GetBlockFromCache(path, block->GetFullSize())); + block->SetBuffer(GetBlockFromCache(path, block->GetDataSize())); inCache = kTRUE; } else{ @@ -173,21 +197,9 @@ Bool_t TFilePrefetch::ReadBuffer(char* buf, Long64_t offset, Int_t len) } if (found){ - Int_t auxInt = 0; - char* ptrInt = 0; - - for(Int_t i=0; i < blockObj->GetNoElem(); i++){ - - ptrInt = blockObj->GetBuffer(); - ptrInt += auxInt; - - if (index == i){ - ptrInt+= (offset - blockObj->GetPos(i)); - memcpy(buf, ptrInt, len); - break; - } - auxInt += blockObj->GetLen(i); - } + char *pBuff = blockObj->GetPtrToPiece(index); + pBuff += (offset - blockObj->GetPos(index)); + memcpy(buf, pBuff, len); } mutexBlocks->UnLock(); return found; @@ -208,11 +220,15 @@ void TFilePrefetch::AddPendingBlock(TFPBlock* block) // Safe method to add a block to the pendingList. TMutex *mutexBlocks = fMutexPendingList; + TMutex *mutexCond = fNewBlockAdded->GetMutex(); mutexBlocks->Lock(); fPendingBlocks->Add(block); mutexBlocks->UnLock(); + + mutexCond->Lock(); fNewBlockAdded->Signal(); + mutexCond->UnLock(); } //____________________________________________________________________________________________ @@ -221,14 +237,14 @@ TFPBlock* TFilePrefetch::GetPendingBlock() // Safe method to remove a block from the pendingList. TFPBlock* block = 0; - TMutex *mutexBlocks = fMutexPendingList; - mutexBlocks->Lock(); + TMutex *mutex = fMutexPendingList; + mutex->Lock(); if (fPendingBlocks->GetSize()){ block = (TFPBlock*)fPendingBlocks->First(); block = (TFPBlock*)fPendingBlocks->Remove(block); } - mutexBlocks->UnLock(); + mutex->UnLock(); return block; } @@ -237,8 +253,9 @@ void TFilePrefetch::AddReadBlock(TFPBlock* block) { // Safe method to add a block to the readList. - TMutex *mutexBlocks = fMutexReadList; - mutexBlocks->Lock(); + TMutex *mutexCond = fReadBlockAdded->GetMutex(); + TMutex *mutex = fMutexReadList; + mutex->Lock(); if (fReadBlocks->GetSize() >= kMAX_READ_SIZE){ TFPBlock* movedBlock = (TFPBlock*) fReadBlocks->First(); @@ -248,8 +265,12 @@ void TFilePrefetch::AddReadBlock(TFPBlock* block) } fReadBlocks->Add(block); - mutexBlocks->UnLock(); + mutex->UnLock(); + + //signal the addition of a new block + mutexCond->Lock(); fReadBlockAdded->Signal(); + mutexCond->UnLock(); } @@ -259,18 +280,18 @@ TFPBlock* TFilePrefetch::CreateBlockObj(Long64_t* offset, Int_t* len, Int_t nobl // Create a new block or recycle an old one. TFPBlock* blockObj = 0; - TMutex *mutexRead = fMutexReadList; + TMutex *mutex = fMutexReadList; - mutexRead->Lock(); + mutex->Lock(); if (fReadBlocks->GetSize() >= kMAX_READ_SIZE){ blockObj = static_cast<TFPBlock*>(fReadBlocks->First()); fReadBlocks->Remove(blockObj); + mutex->UnLock(); blockObj->ReallocBlock(offset, len, noblock); - mutexRead->UnLock(); } else{ - mutexRead->UnLock(); + mutex->UnLock(); blockObj = new TFPBlock(offset, len, noblock); } return blockObj; @@ -289,8 +310,26 @@ TThread* TFilePrefetch::GetThread() const void TFilePrefetch::SetFile(TFile *file) { // Change the file + // When prefetching is enabled we also need to: + // - make sure the async thread is not doing any work + // - clear all blocks from prefetching and read list + // - reset the file pointer + fSemChangeFile->Wait(); + + if (fFile) { + // Remove all pending and read blocks + fMutexPendingList->Lock(); + fPendingBlocks->Clear(); + fMutexPendingList->UnLock(); + + fMutexReadList->Lock(); + fReadBlocks->Clear(); + fMutexReadList->UnLock(); + } + fFile = file; + fSemChangeFile->Post(); } @@ -299,9 +338,12 @@ Int_t TFilePrefetch::ThreadStart() { // Used to start the consumer thread. int rc; - fConsumer= new TThread((TThread::VoidRtnFunc_t) ThreadProc, - (void*) this); + + fConsumer = new TThread((TThread::VoidRtnFunc_t) ThreadProc, (void*) this); rc = fConsumer->Run(); + if ( !rc ) { + fThreadJoined = kFALSE; + } return rc; } @@ -310,23 +352,27 @@ TThread::VoidRtnFunc_t TFilePrefetch::ThreadProc(void* arg) { // Execution loop of the consumer thread. - TFilePrefetch* tmp = (TFilePrefetch*) arg; - tmp->fMutexSynch->Lock(); - - while(tmp->fSem->TryWait() !=0){ - tmp->ReadListOfBlocks(); - if (tmp->fSem->TryWait() == 0) break; - tmp->fMutexSynch->UnLock(); - tmp->fNewBlockAdded->Wait(); - tmp->fMutexSynch->Lock(); - } + TFilePrefetch* pClass = (TFilePrefetch*) arg; + TSemaphore* semChangeFile = pClass->fSemChangeFile; + semChangeFile->Post(); + pClass->fNewBlockAdded->Wait(); + semChangeFile->Wait(); - tmp->fMutexSynch->UnLock(); + while( pClass->fSemMasterWorker->TryWait() != 0 ) { + pClass->ReadListOfBlocks(); + + // Use the semaphore to deal with the case when the file pointer + // is changed on the fly by TChain + semChangeFile->Post(); + pClass->fNewBlockAdded->Wait(); + semChangeFile->Wait(); + } + pClass->fSemWorkerMaster->Post(); return (TThread::VoidRtnFunc_t) 1; } -//########################################### CACHING PART ############################################################### +//########################################### CACHING PART #################################### //____________________________________________________________________________________________ Int_t TFilePrefetch::SumHex(const char *hex) @@ -355,7 +401,7 @@ Bool_t TFilePrefetch::CheckBlockInCache(char*& path, TFPBlock* block) Int_t value = 0; - if (gSystem->OpenDirectory(fullPath) == 0) + if (!gSystem->OpenDirectory(fullPath)) gSystem->mkdir(fullPath); //dir is SHA1 value modulo 16; filename is the value of the SHA1(offset+len) @@ -402,7 +448,7 @@ char* TFilePrefetch::GetBlockFromCache(const char* path, Int_t length) Double_t start = 0; if (gPerfStats != 0) start = TTimeStamp(); - buffer = (char*) calloc(length+1, sizeof(char)); + buffer = (char*) calloc(length, sizeof(char)); file->ReadBuffer(buffer, 0, length); fFile->fBytesRead += length; @@ -416,6 +462,7 @@ char* TFilePrefetch::GetBlockFromCache(const char* path, Int_t length) gPerfStats->FileReadEvent(fFile, length, start); } + file->Close(); delete file; return buffer; } @@ -447,7 +494,7 @@ void TFilePrefetch::SaveBlockInCache(TFPBlock* block) dirName.Form("%i", value); fullPath += ("/" + dirName); - if (gSystem->OpenDirectory(fullPath) == false) + if (!gSystem->OpenDirectory(fullPath)) gSystem->mkdir(fullPath); TFile* file = 0; @@ -462,7 +509,9 @@ void TFilePrefetch::SaveBlockInCache(TFPBlock* block) } if (file) { - file->WriteBuffer(block->GetBuffer(), block->GetFullSize()); + // coverity[unchecked_value] We do not print error message, have no error + // return code and close the file anyway, no need to check the return value. + file->WriteBuffer(block->GetBuffer(), block->GetDataSize()); file->Close(); delete file; } @@ -485,7 +534,8 @@ Bool_t TFilePrefetch::CheckCachePath(const char* locationCache) TString directory(dir); for(Int_t i=0; i < directory.Sizeof()-1; i++) - if (!isdigit(directory[i]) && !isalpha(directory[i]) && directory[i] !='/' && directory[i] != ':'){ + if (!isdigit(directory[i]) && !isalpha(directory[i]) && directory[i] !='/' + && directory[i] != ':' && directory[i] != '_'){ found = false; break; } @@ -504,7 +554,7 @@ Bool_t TFilePrefetch::SetCache(const char* path) fPathCache = path; if (!gSystem->OpenDirectory(path)){ - gSystem->mkdir(path); + gSystem->mkdir(path); } } else return false; diff --git a/io/io/src/TFree.cxx b/io/io/src/TFree.cxx index c5b1c0efc3e49..0748005b9f70b 100644 --- a/io/io/src/TFree.cxx +++ b/io/io/src/TFree.cxx @@ -55,11 +55,11 @@ TFree *TFree::AddFree(TList *lfree, Long64_t first, Long64_t last) { // Add a new free segment to the list of free segments. // -// If last just preceedes an existing free segment, then first becomes +// If last just precedes an existing free segment, then first becomes // the new starting location of the free segment. // if first just follows an existing free segment, then last becomes // the new ending location of the free segment. -// if first just follows an existing free segment AND last just preceedes +// if first just follows an existing free segment AND last just precedes // an existing free segment, these two segments are merged into // one single segment. // diff --git a/io/io/src/TGenCollectionProxy.cxx b/io/io/src/TGenCollectionProxy.cxx index 3a4e303013540..451bc08fde7b3 100644 --- a/io/io/src/TGenCollectionProxy.cxx +++ b/io/io/src/TGenCollectionProxy.cxx @@ -36,9 +36,9 @@ #include "TStreamerInfoActions.h" #include <stdlib.h> -#define MESSAGE(which,text) +#include "TInterpreter.h" // For gCINTMutex -std::vector<TVirtualCollectionProxy*> gSlowIterator__Proxy; +#define MESSAGE(which,text) ////////////////////////////////////////////////////////////////////////// // // @@ -524,7 +524,7 @@ TGenCollectionProxy::TGenCollectionProxy(const TGenCollectionProxy& copy) fDestruct = copy.fDestruct; fConstruct = copy.fConstruct; fFeed = copy.fFeed; - fCollect.call = copy.fCollect.call; + fCollect = copy.fCollect; fCreateEnv.call = copy.fCreateEnv.call; fValOffset = copy.fValOffset; fValDiff = copy.fValDiff; @@ -537,6 +537,9 @@ TGenCollectionProxy::TGenCollectionProxy(const TGenCollectionProxy& copy) fWriteMemberWise = 0; fProperties = copy.fProperties; fFunctionCreateIterators = copy.fFunctionCreateIterators; + fFunctionCopyIterator = copy.fFunctionCopyIterator; + fFunctionNextIterator = copy.fFunctionNextIterator; + fFunctionDeleteIterator = copy.fFunctionDeleteIterator; fFunctionDeleteTwoIterators = copy.fFunctionDeleteTwoIterators; } @@ -554,7 +557,7 @@ TGenCollectionProxy::TGenCollectionProxy(Info_t info, size_t iter_size) fResize = 0; fDestruct = 0; fConstruct = 0; - fCollect.call = 0; + fCollect = 0; fCreateEnv.call = 0; fFeed = 0; fValue = 0; @@ -578,6 +581,9 @@ TGenCollectionProxy::TGenCollectionProxy(Info_t info, size_t iter_size) fConversionReadMemberWise = 0; fWriteMemberWise = 0; fFunctionCreateIterators = 0; + fFunctionCopyIterator = 0; + fFunctionNextIterator = 0; + fFunctionDeleteIterator = 0; fFunctionDeleteTwoIterators = 0; } @@ -598,7 +604,7 @@ TGenCollectionProxy::TGenCollectionProxy(const ROOT::TCollectionProxyInfo &info, fConstruct = info.fConstructFunc; fDestruct = info.fDestructFunc; fFeed = info.fFeedFunc; - fCollect.call = info.fCollectFunc; + fCollect = info.fCollectFunc; fCreateEnv.call = info.fCreateEnv; if (cl) { @@ -624,8 +630,11 @@ TGenCollectionProxy::TGenCollectionProxy(const ROOT::TCollectionProxyInfo &info, fReadMemberWise = new TObjArray(TCollection::kInitCapacity,-1); fConversionReadMemberWise = 0; fWriteMemberWise = 0; - fFunctionCreateIterators = 0; - fFunctionDeleteTwoIterators = 0; + fFunctionCreateIterators = info.fCreateIterators; + fFunctionCopyIterator = info.fCopyIterator; + fFunctionNextIterator = info.fNext; + fFunctionDeleteIterator = info.fDeleteSingleIterator; + fFunctionDeleteTwoIterators = info.fDeleteTwoIterators; } namespace { @@ -739,7 +748,7 @@ void TGenCollectionProxy::CheckFunctions() const if ( 0 == fFeed ) { Fatal("TGenCollectionProxy","No 'data feed' function for class %s present.",fName.c_str()); } - if ( 0 == fCollect.call ) { + if ( 0 == fCollect ) { Fatal("TGenCollectionProxy","No 'data collect' function for class %s present.",fName.c_str()); } if (0 == fCreateEnv.call ) { @@ -762,7 +771,7 @@ static TGenCollectionProxy::Value *R__CreateValue(const std::string &name, Bool_ TGenCollectionProxy *TGenCollectionProxy::InitializeEx(Bool_t silent) { // Proxy initializer - R__LOCKGUARD2(gCollectionMutex); + R__LOCKGUARD2(gCINTMutex); if (fValue) return this; TClass *cl = fClass ? fClass.GetClass() : TClass::GetClass(fTypeinfo,kTRUE,silent); @@ -785,6 +794,7 @@ TGenCollectionProxy *TGenCollectionProxy::InitializeEx(Bool_t silent) case TClassEdit::kMultiMap: case TClassEdit::kSet: case TClassEdit::kMultiSet: + case TClassEdit::kBitSet: // not really an associate container but it has no real iterator. fProperties |= kIsAssociative; break; }; @@ -841,25 +851,25 @@ TGenCollectionProxy *TGenCollectionProxy::InitializeEx(Bool_t silent) } //______________________________________________________________________________ -TClass *TGenCollectionProxy::GetCollectionClass() +TClass *TGenCollectionProxy::GetCollectionClass() const { // Return a pointer to the TClass representing the container return fClass ? fClass : Initialize(kFALSE)->fClass; } //______________________________________________________________________________ -Int_t TGenCollectionProxy::GetCollectionType() +Int_t TGenCollectionProxy::GetCollectionType() const { // Return the type of collection see TClassEdit::ESTLType - if (!fClass) { + if (!fValue) { Initialize(kFALSE); } return fSTL_type; } //______________________________________________________________________________ -ULong_t TGenCollectionProxy::GetIncrement() { +ULong_t TGenCollectionProxy::GetIncrement() const { // Return the offset between two consecutive value_types (memory layout). if (!fValue) { @@ -891,7 +901,7 @@ Bool_t TGenCollectionProxy::HasPointers() const } //______________________________________________________________________________ -TClass *TGenCollectionProxy::GetValueClass() +TClass *TGenCollectionProxy::GetValueClass() const { // Return a pointer to the TClass representing the content. @@ -909,7 +919,7 @@ void TGenCollectionProxy::SetValueClass(TClass *new_Value_type) } //______________________________________________________________________________ -EDataType TGenCollectionProxy::GetType() +EDataType TGenCollectionProxy::GetType() const { // If the content is a simple numerical value, return its type (see TDataType) @@ -1022,7 +1032,7 @@ void* TGenCollectionProxy::Allocate(UInt_t n, Bool_t /* forceDelete */ ) case TClassEdit::kSet: case TClassEdit::kMultiSet: case TClassEdit::kMap: - case TClassEdit::kMultiMap: + case TClassEdit::kMultiMap: { if ( (fProperties & kNeedDelete) ) Clear("force"); else @@ -1049,6 +1059,7 @@ void* TGenCollectionProxy::Allocate(UInt_t n, Bool_t /* forceDelete */ ) fEnv->fStart = fEnv->fTemp; return s; + } case TClassEdit::kVector: case TClassEdit::kList: case TClassEdit::kDeque: @@ -1059,9 +1070,23 @@ void* TGenCollectionProxy::Allocate(UInt_t n, Bool_t /* forceDelete */ ) fResize(fEnv->fObject,n); return fEnv->fObject; - case TClassEdit::kBitSet: - // Nothing to do. - return fEnv->fObject; + case TClassEdit::kBitSet: { + TStaging *s; + if (fStaged.empty()) { + s = new TStaging(n,fValDiff); + } else { + s = fStaged.back(); + fStaged.pop_back(); + s->Resize(n); + } + s->SetTarget(fEnv->fObject); + + fEnv->fTemp = s->GetContent(); + fEnv->fUseTemp = kTRUE; + fEnv->fStart = fEnv->fTemp; + + return s; + } } } return 0; @@ -1094,8 +1119,6 @@ void TGenCollectionProxy::PushProxy(void *objstart) { // Add an object. - gSlowIterator__Proxy.push_back(this); - if ( !fValue ) Initialize(kFALSE); if ( !fProxyList.empty() ) { EnvironBase_t* back = fProxyList.back(); @@ -1131,8 +1154,6 @@ void TGenCollectionProxy::PopProxy() { // Remove the last object. - gSlowIterator__Proxy.pop_back(); - if ( !fProxyList.empty() ) { EnvironBase_t* e = fProxyList.back(); if ( --e->fRefCount <= 0 ) { @@ -1250,10 +1271,10 @@ struct TGenCollectionProxy__SlowIterator { }; //______________________________________________________________________________ -void TGenCollectionProxy__SlowCreateIterators(void * /* collection */, void **begin_arena, void **end_arena) +void TGenCollectionProxy__SlowCreateIterators(void * /* collection */, void **begin_arena, void **end_arena, TVirtualCollectionProxy *proxy) { - new (*begin_arena) TGenCollectionProxy__SlowIterator(gSlowIterator__Proxy.back()); - *(UInt_t*)*end_arena = gSlowIterator__Proxy.back()->Size(); + new (*begin_arena) TGenCollectionProxy__SlowIterator(proxy); + *(UInt_t*)*end_arena = proxy->Size(); } //______________________________________________________________________________ @@ -1290,7 +1311,7 @@ void TGenCollectionProxy__SlowDeleteTwoIterators(void *, void *) //______________________________________________________________________________ -void TGenCollectionProxy__VectorCreateIterators(void *obj, void **begin_arena, void **end_arena) +void TGenCollectionProxy__VectorCreateIterators(void *obj, void **begin_arena, void **end_arena, TVirtualCollectionProxy*) { // We can safely assume that the std::vector layout does not really depend on // the content! @@ -1308,10 +1329,6 @@ void TGenCollectionProxy__VectorCreateIterators(void *obj, void **begin_arena, v *end_arena = &(*vec->end()); #endif - // The following is a safer way but require the caller to have called TPushPop - // TVirtualCollectionProxy *proxy = gSlowIterator__Proxy.back(); - // void *good_begin_arena = proxy->At(0); - // void *good_end_arena = ((char*)proxy->At(0)) + proxy->Size() * proxy->GetIncrement(); } //______________________________________________________________________________ @@ -1344,7 +1361,7 @@ void TGenCollectionProxy__VectorDeleteTwoIterators(void *, void *) //______________________________________________________________________________ -void TGenCollectionProxy__StagingCreateIterators(void *obj, void **begin_arena, void **end_arena) +void TGenCollectionProxy__StagingCreateIterators(void *obj, void **begin_arena, void **end_arena, TVirtualCollectionProxy *) { TGenCollectionProxy::TStaging * s = (TGenCollectionProxy::TStaging*)obj; *begin_arena = s->GetContent(); @@ -1387,6 +1404,12 @@ TVirtualCollectionProxy::CreateIterators_t TGenCollectionProxy::GetFunctionCreat // If the collection iterator are of that size or less, the iterators will be constructed in place in those location (new with placement) // Otherwise the iterators will be allocated via a regular new and their address returned by modifying the value of begin_arena and end_arena. + if (read) { + if ( !fValue ) InitializeEx(kFALSE); + if ( (fProperties & kIsAssociative) && read) + return TGenCollectionProxy__StagingCreateIterators; + } + if ( fFunctionCreateIterators ) return fFunctionCreateIterators; if ( !fValue ) InitializeEx(kFALSE); @@ -1400,12 +1423,11 @@ TVirtualCollectionProxy::CreateIterators_t TGenCollectionProxy::GetFunctionCreat // fprintf(stderr,"a generic iterator\n"); if (fSTL_type==TClassEdit::kVector || (fProperties & kIsEmulated)) - fFunctionCreateIterators = TGenCollectionProxy__VectorCreateIterators; + return fFunctionCreateIterators = TGenCollectionProxy__VectorCreateIterators; else if ( (fProperties & kIsAssociative) && read) - fFunctionCreateIterators = TGenCollectionProxy__StagingCreateIterators; + return TGenCollectionProxy__StagingCreateIterators; else - fFunctionCreateIterators = TGenCollectionProxy__SlowCreateIterators; - return fFunctionCreateIterators; + return fFunctionCreateIterators = TGenCollectionProxy__SlowCreateIterators; } //______________________________________________________________________________ @@ -1416,14 +1438,22 @@ TVirtualCollectionProxy::CopyIterator_t TGenCollectionProxy::GetFunctionCopyIter // If the collection iterator are of that size or less, the iterator will be constructed in place in this location (new with placement) // Otherwise the iterator will be allocated via a regular new and its address returned by modifying the value of dest. + if (read) { + if ( !fValue ) InitializeEx(kFALSE); + if ( (fProperties & kIsAssociative) && read) + return TGenCollectionProxy__StagingCopyIterator; + } + + if ( fFunctionCopyIterator ) return fFunctionCopyIterator; + if ( !fValue ) InitializeEx(kFALSE); if (fSTL_type==TClassEdit::kVector || (fProperties & kIsEmulated)) - return TGenCollectionProxy__VectorCopyIterator; + return fFunctionCopyIterator = TGenCollectionProxy__VectorCopyIterator; else if ( (fProperties & kIsAssociative) && read) return TGenCollectionProxy__StagingCopyIterator; else - return TGenCollectionProxy__SlowCopyIterator; + return fFunctionCopyIterator = TGenCollectionProxy__SlowCopyIterator; } //______________________________________________________________________________ @@ -1435,14 +1465,22 @@ TVirtualCollectionProxy::Next_t TGenCollectionProxy::GetFunctionNext(Bool_t read // If the end is not reached, 'Next' will return the address of the content unless the collection contains pointers in // which case 'Next' will return the value of the pointer. + if (read) { + if ( !fValue ) InitializeEx(kFALSE); + if ( (fProperties & kIsAssociative) && read) + return TGenCollectionProxy__StagingNext; + } + + if ( fFunctionNextIterator ) return fFunctionNextIterator; + if ( !fValue ) InitializeEx(kFALSE); if (fSTL_type==TClassEdit::kVector || (fProperties & kIsEmulated)) - return TGenCollectionProxy__VectorNext; + return fFunctionNextIterator = TGenCollectionProxy__VectorNext; else if ( (fProperties & kIsAssociative) && read) return TGenCollectionProxy__StagingNext; else - return TGenCollectionProxy__SlowNext; + return fFunctionNextIterator = TGenCollectionProxy__SlowNext; } //______________________________________________________________________________ @@ -1452,14 +1490,22 @@ TVirtualCollectionProxy::DeleteIterator_t TGenCollectionProxy::GetFunctionDelete // If the sizeof iterator is greater than fgIteratorArenaSize, call delete on the addresses, // Otherwise just call the iterator's destructor. + if (read) { + if ( !fValue ) InitializeEx(kFALSE); + if ( (fProperties & kIsAssociative) && read) + return TGenCollectionProxy__StagingDeleteSingleIterators; + } + + if ( fFunctionDeleteIterator ) return fFunctionDeleteIterator; + if ( !fValue ) InitializeEx(kFALSE); if (fSTL_type==TClassEdit::kVector || (fProperties & kIsEmulated)) - return TGenCollectionProxy__VectorDeleteSingleIterators; + return fFunctionDeleteIterator = TGenCollectionProxy__VectorDeleteSingleIterators; else if ( (fProperties & kIsAssociative) && read) return TGenCollectionProxy__StagingDeleteSingleIterators; else - return TGenCollectionProxy__SlowDeleteSingleIterators; + return fFunctionDeleteIterator = TGenCollectionProxy__SlowDeleteSingleIterators; } //______________________________________________________________________________ @@ -1469,17 +1515,22 @@ TVirtualCollectionProxy::DeleteTwoIterators_t TGenCollectionProxy::GetFunctionDe // If the sizeof iterator is greater than fgIteratorArenaSize, call delete on the addresses, // Otherwise just call the iterator's destructor. + if (read) { + if ( !fValue ) InitializeEx(kFALSE); + if ( (fProperties & kIsAssociative) && read) + return TGenCollectionProxy__StagingDeleteTwoIterators; + } + if ( fFunctionDeleteTwoIterators ) return fFunctionDeleteTwoIterators; if ( !fValue ) InitializeEx(kFALSE); if (fSTL_type==TClassEdit::kVector || (fProperties & kIsEmulated)) - fFunctionDeleteTwoIterators = TGenCollectionProxy__VectorDeleteTwoIterators; + return fFunctionDeleteTwoIterators = TGenCollectionProxy__VectorDeleteTwoIterators; else if ( (fProperties & kIsAssociative) && read) - fFunctionDeleteTwoIterators = TGenCollectionProxy__StagingDeleteTwoIterators; + return TGenCollectionProxy__StagingDeleteTwoIterators; else - fFunctionDeleteTwoIterators = TGenCollectionProxy__SlowDeleteTwoIterators; - return fFunctionDeleteTwoIterators; + return fFunctionDeleteTwoIterators = TGenCollectionProxy__SlowDeleteTwoIterators; } //______________________________________________________________________________ diff --git a/io/io/src/TGenCollectionStreamer.cxx b/io/io/src/TGenCollectionStreamer.cxx index 7a0d887f1781e..5bdc351da4697 100644 --- a/io/io/src/TGenCollectionStreamer.cxx +++ b/io/io/src/TGenCollectionStreamer.cxx @@ -62,15 +62,166 @@ TVirtualCollectionProxy* TGenCollectionStreamer::Generate() const return new TGenCollectionStreamer(*this); } +template <typename T> +static T* getaddress(TGenCollectionProxy::StreamHelper &itm); -void TGenCollectionStreamer::ReadPrimitives(int nElements, TBuffer &b) +template <> +bool* getaddress<bool>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.boolean; +} + +template <> +Char_t* getaddress<Char_t>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.s_char; +} + +template <> +Short_t* getaddress<Short_t>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.s_short; +} + +template <> +Int_t* getaddress<Int_t>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.s_int; +} + +template <> +Long_t* getaddress<Long_t>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.s_long; +} + +template <> +Long64_t* getaddress<Long64_t>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.s_longlong; +} + +template <> +Float_t* getaddress<Float_t>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.flt; +} + +template <> +Double_t* getaddress<Double_t>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.dbl; +} + +template <> +UChar_t* getaddress<UChar_t>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.u_char; +} + +template <> +UShort_t* getaddress<UShort_t>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.u_short; +} + +template <> +UInt_t* getaddress<UInt_t>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.u_int; +} + +template <> +ULong_t* getaddress<ULong_t>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.u_long; +} + +template <> +ULong64_t* getaddress<ULong64_t>(TGenCollectionProxy::StreamHelper &itm) +{ + return &itm.u_longlong; +} + +template <typename From, typename To> +void ConvertArray(TGenCollectionProxy::StreamHelper *read, TGenCollectionProxy::StreamHelper *write, int nElements) +{ + From *r = getaddress<From>( *read ); + To *w = getaddress<To>( *write ); + for(int i = 0; i < nElements; ++i) { + // getvalue<To>( write[i] ) = (To) getvalue<From>( read[i] ); + w[i] = (To)r[i]; + } +} + +template <typename From> +void DispatchConvertArray(int writeType, TGenCollectionProxy::StreamHelper *read, TGenCollectionProxy::StreamHelper *write, int nElements) +{ + switch(writeType) { + case kBool_t: + ConvertArray<From,bool>(read,write,nElements); + break; + case kChar_t: + ConvertArray<From,Char_t>(read,write,nElements); + break; + case kShort_t: + ConvertArray<From,Short_t>(read,write,nElements); + break; + case kInt_t: + ConvertArray<From,Int_t>(read,write,nElements); + break; + case kLong_t: + ConvertArray<From,Long64_t>(read,write,nElements); + break; + case kLong64_t: + ConvertArray<From,Long64_t>(read,write,nElements); + break; + case kFloat_t: + ConvertArray<From,Float_t>(read,write,nElements); + break; + case kFloat16_t: + ConvertArray<From,Float16_t>(read,write,nElements); + break; + case kDouble_t: + ConvertArray<From,Double_t>(read,write,nElements); + break; + case TGenCollectionProxy::kBOOL_t: + ConvertArray<From,bool>(read,write,nElements); + break; + case kUChar_t: + ConvertArray<From,UChar_t>(read,write,nElements); + break; + case kUShort_t: + ConvertArray<From,UShort_t>(read,write,nElements); + break; + case kUInt_t: + ConvertArray<From,UInt_t>(read,write,nElements); + break; + case kULong_t: + ConvertArray<From,ULong_t>(read,write,nElements); + break; + case kULong64_t: + ConvertArray<From,ULong64_t>(read,write,nElements); + break; + case kDouble32_t: + ConvertArray<From,Double32_t>(read,write,nElements); + break; + case kchar: + case kNoType_t: + case kOther_t: + Error("TGenCollectionStreamer", "fType %d is not supported yet!\n", writeType); + } +} + +void TGenCollectionStreamer::ReadPrimitives(int nElements, TBuffer &b, const TClass *onFileClass) { // Primitive input streamer. size_t len = fValDiff * nElements; char buffer[8096]; Bool_t feed = false; void* memory = 0; - StreamHelper* itm = 0; + StreamHelper* itmstore = 0; + StreamHelper* itmconv = 0; fEnv->fSize = nElements; switch (fSTL_type) { case TClassEdit::kVector: @@ -80,79 +231,147 @@ void TGenCollectionStreamer::ReadPrimitives(int nElements, TBuffer &b) TVirtualVectorIterators iterators(fFunctionCreateIterators); iterators.CreateIterators(fEnv->fObject); - itm = (StreamHelper*)iterators.fBegin; - fEnv->fStart = itm; + itmstore = (StreamHelper*)iterators.fBegin; + fEnv->fStart = itmstore; break; } default: feed = true; - itm = (StreamHelper*)(len < sizeof(buffer) ? buffer : memory =::operator new(len)); + itmstore = (StreamHelper*)(len < sizeof(buffer) ? buffer : memory =::operator new(len)); break; } - fEnv->fStart = itm; - switch (int(fVal->fKind)) { + fEnv->fStart = itmstore; + + StreamHelper *itmread; + int readkind; + if (onFileClass) { + readkind = onFileClass->GetCollectionProxy()->GetType(); + itmconv = (StreamHelper*) ::operator new( nElements * onFileClass->GetCollectionProxy()->GetIncrement() ); + itmread = itmconv; + } else { + itmread = itmstore; + readkind = fVal->fKind; + } + switch (readkind) { case kBool_t: - b.ReadFastArray(&itm->boolean , nElements); + b.ReadFastArray(&itmread->boolean , nElements); break; case kChar_t: - b.ReadFastArray(&itm->s_char , nElements); + b.ReadFastArray(&itmread->s_char , nElements); break; case kShort_t: - b.ReadFastArray(&itm->s_short , nElements); + b.ReadFastArray(&itmread->s_short , nElements); break; case kInt_t: - b.ReadFastArray(&itm->s_int , nElements); + b.ReadFastArray(&itmread->s_int , nElements); break; case kLong_t: - b.ReadFastArray(&itm->s_long , nElements); + b.ReadFastArray(&itmread->s_long , nElements); break; case kLong64_t: - b.ReadFastArray(&itm->s_longlong, nElements); + b.ReadFastArray(&itmread->s_longlong, nElements); break; case kFloat_t: - b.ReadFastArray(&itm->flt , nElements); + b.ReadFastArray(&itmread->flt , nElements); break; case kFloat16_t: - b.ReadFastArrayFloat16(&itm->flt, nElements); + b.ReadFastArrayFloat16(&itmread->flt, nElements); break; case kDouble_t: - b.ReadFastArray(&itm->dbl , nElements); + b.ReadFastArray(&itmread->dbl , nElements); break; case kBOOL_t: - b.ReadFastArray(&itm->boolean , nElements); + b.ReadFastArray(&itmread->boolean , nElements); break; case kUChar_t: - b.ReadFastArray(&itm->u_char , nElements); + b.ReadFastArray(&itmread->u_char , nElements); break; case kUShort_t: - b.ReadFastArray(&itm->u_short , nElements); + b.ReadFastArray(&itmread->u_short , nElements); break; case kUInt_t: - b.ReadFastArray(&itm->u_int , nElements); + b.ReadFastArray(&itmread->u_int , nElements); break; case kULong_t: - b.ReadFastArray(&itm->u_long , nElements); + b.ReadFastArray(&itmread->u_long , nElements); break; case kULong64_t: - b.ReadFastArray(&itm->u_longlong, nElements); + b.ReadFastArray(&itmread->u_longlong, nElements); break; case kDouble32_t: - b.ReadFastArrayDouble32(&itm->dbl, nElements); + b.ReadFastArrayDouble32(&itmread->dbl, nElements); break; case kchar: case kNoType_t: case kOther_t: - Error("TGenCollectionStreamer", "fType %d is not supported yet!\n", fVal->fKind); + Error("TGenCollectionStreamer", "fType %d is not supported yet!\n", readkind); + } + if (onFileClass) { + switch (readkind) { + case kBool_t: + DispatchConvertArray<bool>(fVal->fKind, itmread, itmstore, nElements); + break; + case kChar_t: + DispatchConvertArray<Char_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kShort_t: + DispatchConvertArray<Short_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kInt_t: + DispatchConvertArray<Int_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kLong_t: + DispatchConvertArray<Long_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kLong64_t: + DispatchConvertArray<Long64_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kFloat_t: + DispatchConvertArray<Float_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kFloat16_t: + DispatchConvertArray<Float16_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kDouble_t: + DispatchConvertArray<Double_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kBOOL_t: + DispatchConvertArray<bool>(fVal->fKind, itmread, itmstore, nElements); + break; + case kUChar_t: + DispatchConvertArray<UChar_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kUShort_t: + DispatchConvertArray<UShort_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kUInt_t: + DispatchConvertArray<UInt_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kULong_t: + DispatchConvertArray<ULong_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kULong64_t: + DispatchConvertArray<ULong64_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kDouble32_t: + DispatchConvertArray<Double_t>(fVal->fKind, itmread, itmstore, nElements); + break; + case kchar: + case kNoType_t: + case kOther_t: + Error("TGenCollectionStreamer", "fType %d is not supported yet!\n", readkind); + } + ::operator delete((void*)itmconv); } if (feed) { // need to feed in data... - fEnv->fStart = fFeed(fEnv->fStart,fEnv->fObject,fEnv->fSize); + fEnv->fStart = fFeed(itmstore,fEnv->fObject,fEnv->fSize); if (memory) { ::operator delete(memory); } } } -void TGenCollectionStreamer::ReadObjects(int nElements, TBuffer &b) +void TGenCollectionStreamer::ReadObjects(int nElements, TBuffer &b, const TClass *onFileClass) { // Object input streamer. Bool_t vsn3 = b.GetInfo() && b.GetInfo()->GetOldVersion() <= 3; @@ -161,7 +380,7 @@ void TGenCollectionStreamer::ReadObjects(int nElements, TBuffer &b) char buffer[8096]; void* memory = 0; - TClass* onFileValClass = (fOnFileClass ? fOnFileClass->GetCollectionProxy()->GetValueClass() : 0); + TClass* onFileValClass = (onFileClass ? onFileClass->GetCollectionProxy()->GetValueClass() : 0); fEnv->fSize = nElements; switch (fSTL_type) { @@ -435,7 +654,88 @@ void TGenCollectionStreamer::ReadMapHelper(StreamHelper *i, Value *v, Bool_t vsn } } -void TGenCollectionStreamer::ReadMap(int nElements, TBuffer &b) +template <typename To> +To readOneValue(TBuffer &b, int readtype) { + TGenCollectionProxy::StreamHelper itm; + TGenCollectionProxy::StreamHelper *i = &itm; + switch (readtype) { + case kBool_t: + b >> i->boolean; + return (To)i->boolean; + break; + case kChar_t: + b >> i->s_char; + return (To)i->s_char; + break; + case kShort_t: + b >> i->s_short; + return (To)i->s_short; + break; + case kInt_t: + b >> i->s_int; + return (To)i->s_int; + break; + case kLong_t: + b >> i->s_long; + return (To)i->s_long; + break; + case kLong64_t: + b >> i->s_longlong; + return (To)i->s_longlong; + break; + case kFloat_t: + b >> i->flt; + return (To)i->flt; + break; + case kFloat16_t: + b >> i->flt; + return (To)i->flt; + break; + case kDouble_t: + b >> i->dbl; + return (To)i->dbl; + break; + case TGenCollectionProxy::kBOOL_t: + b >> i->boolean; + return (To)i->boolean; + break; + case kUChar_t: + b >> i->u_char; + return (To)i->u_char; + break; + case kUShort_t: + b >> i->u_short; + return (To)i->u_short; + break; + case kUInt_t: + b >> i->u_int; + return (To)i->u_int; + break; + case kULong_t: + b >> i->u_long; + return (To)i->u_long; + break; + case kULong64_t: + b >> i->u_longlong; + return (To)i->u_longlong; + break; + case kDouble32_t: { + float f; + b >> f; + i->dbl = double(f); + return (To)i->dbl; + break; + } + case kchar: + case kNoType_t: + case kOther_t: + Error("TGenCollectionStreamer", "fType %d is not supported yet!\n", readtype); + } + return 0; +} + + +void TGenCollectionStreamer::ReadMap(int nElements, TBuffer &b, const TClass *onFileClass) { // Map input streamer. Bool_t vsn3 = b.GetInfo() && b.GetInfo()->GetOldVersion() <= 3; @@ -449,6 +749,14 @@ void TGenCollectionStreamer::ReadMap(int nElements, TBuffer &b) fEnv->fStart = (len < sizeof(buffer) ? buffer : memory =::operator new(len)); addr = temp = (char*)fEnv->fStart; fConstruct(addr,nElements); + + int onFileValueKind[2]; + if (onFileClass) { + TClass *onFileValueClass = onFileClass->GetCollectionProxy()->GetValueClass(); + TVirtualStreamerInfo *sourceInfo = onFileValueClass->GetStreamerInfo(); + onFileValueKind[0] = ((TStreamerElement*)sourceInfo->GetElements()->At(0))->GetType(); + onFileValueKind[1] = ((TStreamerElement*)sourceInfo->GetElements()->At(1))->GetType(); + } for (int loop, idx = 0; idx < nElements; ++idx) { addr = temp + fValDiff * idx; v = fKey; @@ -457,7 +765,64 @@ void TGenCollectionStreamer::ReadMap(int nElements, TBuffer &b) switch (v->fCase) { case G__BIT_ISFUNDAMENTAL: // Only handle primitives this way case G__BIT_ISENUM: - switch (int(v->fKind)) { + if (onFileClass) { + int readtype = (int)(onFileValueKind[loop]); + switch (int(v->fKind)) { + case kBool_t: + i->boolean = readOneValue<bool>(b,readtype); + break; + case kChar_t: + i->s_char = readOneValue<Char_t>(b,readtype); + break; + case kShort_t: + i->s_short = readOneValue<Short_t>(b,readtype); + break; + case kInt_t: + i->s_int = readOneValue<Int_t>(b,readtype); + break; + case kLong_t: + i->s_long = readOneValue<Long_t>(b,readtype); + break; + case kLong64_t: + i->s_longlong = readOneValue<Long64_t>(b,readtype); + break; + case kFloat_t: + i->flt = readOneValue<Float_t>(b,readtype); + break; + case kFloat16_t: + i->flt = readOneValue<Float16_t>(b,readtype); + break; + case kDouble_t: + i->dbl = readOneValue<Double_t>(b,readtype); + break; + case kBOOL_t: + i->boolean = readOneValue<bool>(b,readtype); + break; + case kUChar_t: + i->u_char = readOneValue<UChar_t>(b,readtype); + break; + case kUShort_t: + i->u_short = readOneValue<UShort_t>(b,readtype); + break; + case kUInt_t: + i->u_int = readOneValue<UInt_t>(b,readtype); + break; + case kULong_t: + i->u_long = readOneValue<ULong_t>(b,readtype); + break; + case kULong64_t: + i->u_longlong = readOneValue<ULong64_t>(b,readtype); + break; + case kDouble32_t: + i->dbl = readOneValue<Double32_t>(b,readtype); + break; + case kchar: + case kNoType_t: + case kOther_t: + Error("TGenCollectionStreamer", "fType %d is not supported yet!\n", v->fKind); + } + } else { + switch (int(v->fKind)) { case kBool_t: b >> i->boolean; break; @@ -512,6 +877,7 @@ void TGenCollectionStreamer::ReadMap(int nElements, TBuffer &b) case kNoType_t: case kOther_t: Error("TGenCollectionStreamer", "fType %d is not supported yet!\n", v->fKind); + } } break; case G__BIT_ISCLASS: @@ -556,7 +922,7 @@ void TGenCollectionStreamer::WritePrimitives(int nElements, TBuffer &b) } default: fEnv->fStart = itm = (StreamHelper*)(len < sizeof(buffer) ? buffer : memory =::operator new(len)); - fCollect.invoke(fEnv); + fCollect(fEnv->fObject,itm); break; } switch (int(fVal->fKind)) { @@ -764,38 +1130,109 @@ void TGenCollectionStreamer::WriteMap(int nElements, TBuffer &b) } } +template <typename From, typename To> +void TGenCollectionStreamer::ConvertBufferVectorPrimitives(TBuffer &b, void *obj, Int_t nElements) +{ + From *temp = new From[nElements]; + b.ReadFastArray(temp, nElements); + std::vector<To> *const vec = (std::vector<To>*)(obj); + for(Int_t ind = 0; ind < nElements; ++ind) { + (*vec)[ind] = (To)temp[ind]; + } + delete [] temp; +} + +template <typename To> +void TGenCollectionStreamer::ConvertBufferVectorPrimitivesFloat16(TBuffer &b, void *obj, Int_t nElements) +{ + Float16_t *temp = new Float16_t[nElements]; + b.ReadFastArrayFloat16(temp, nElements); + std::vector<To> *const vec = (std::vector<To>*)(obj); + for(Int_t ind = 0; ind < nElements; ++ind) { + (*vec)[ind] = (To)temp[ind]; + } + delete [] temp; +} + +template <typename To> +void TGenCollectionStreamer::ConvertBufferVectorPrimitivesDouble32(TBuffer &b, void *obj, Int_t nElements) +{ + Double32_t *temp = new Double32_t[nElements]; + b.ReadFastArrayDouble32(temp, nElements); + std::vector<To> *const vec = (std::vector<To>*)(obj); + for(Int_t ind = 0; ind < nElements; ++ind) { + (*vec)[ind] = (To)temp[ind]; + } + delete [] temp; +} + +template <typename To> +void TGenCollectionStreamer::DispatchConvertBufferVectorPrimitives(TBuffer &b, void *obj, Int_t nElements, const TVirtualCollectionProxy *onFileProxy) +{ + switch (onFileProxy->GetType()) { + case TStreamerInfo::kBool: ConvertBufferVectorPrimitives<Bool_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kChar: ConvertBufferVectorPrimitives<Char_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kShort: ConvertBufferVectorPrimitives<Short_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kInt: ConvertBufferVectorPrimitives<Int_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kLong: ConvertBufferVectorPrimitives<Long_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kLong64: ConvertBufferVectorPrimitives<Long64_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kFloat: ConvertBufferVectorPrimitives<Float_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kFloat16: ConvertBufferVectorPrimitives<Float16_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kDouble: ConvertBufferVectorPrimitives<Double_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kDouble32: ConvertBufferVectorPrimitives<Double32_t,To>(b,obj,nElements); break; + case TStreamerInfo::kUChar: ConvertBufferVectorPrimitives<UChar_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kUShort: ConvertBufferVectorPrimitives<UShort_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kUInt: ConvertBufferVectorPrimitives<UInt_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kULong: ConvertBufferVectorPrimitives<ULong_t ,To>(b,obj,nElements); break; + case TStreamerInfo::kULong64: ConvertBufferVectorPrimitives<ULong64_t ,To>(b,obj,nElements); break; + default: break; + } +} + template <typename basictype> -void TGenCollectionStreamer::ReadBufferVectorPrimitives(TBuffer &b, void *obj) +void TGenCollectionStreamer::ReadBufferVectorPrimitives(TBuffer &b, void *obj, const TClass *onFileClass) { int nElements = 0; b >> nElements; fResize(obj,nElements); - TVirtualVectorIterators iterators(fFunctionCreateIterators); - iterators.CreateIterators(obj); - b.ReadFastArray((basictype*)iterators.fBegin, nElements); + if (onFileClass) { + DispatchConvertBufferVectorPrimitives<basictype>(b,obj,nElements,onFileClass->GetCollectionProxy()); + } else { + TVirtualVectorIterators iterators(fFunctionCreateIterators); + iterators.CreateIterators(obj); + b.ReadFastArray((basictype*)iterators.fBegin, nElements); + } } -void TGenCollectionStreamer::ReadBufferVectorPrimitivesFloat16(TBuffer &b, void *obj) +void TGenCollectionStreamer::ReadBufferVectorPrimitivesFloat16(TBuffer &b, void *obj, const TClass *onFileClass) { int nElements = 0; b >> nElements; fResize(obj,nElements); - TVirtualVectorIterators iterators(fFunctionCreateIterators); - iterators.CreateIterators(obj); - b.ReadFastArrayFloat16((Float16_t*)iterators.fBegin, nElements); + if (onFileClass) { + DispatchConvertBufferVectorPrimitives<Float16_t>(b,obj,nElements,onFileClass->GetCollectionProxy()); + } else { + TVirtualVectorIterators iterators(fFunctionCreateIterators); + iterators.CreateIterators(obj); + b.ReadFastArrayFloat16((Float16_t*)iterators.fBegin, nElements); + } } -void TGenCollectionStreamer::ReadBufferVectorPrimitivesDouble32(TBuffer &b, void *obj) +void TGenCollectionStreamer::ReadBufferVectorPrimitivesDouble32(TBuffer &b, void *obj, const TClass *onFileClass) { int nElements = 0; b >> nElements; fResize(obj,nElements); - TVirtualVectorIterators iterators(fFunctionCreateIterators); - iterators.CreateIterators(obj); - b.ReadFastArrayDouble32((Double32_t*)iterators.fBegin, nElements); + if (onFileClass) { + DispatchConvertBufferVectorPrimitives<Double32_t>(b,obj,nElements,onFileClass->GetCollectionProxy()); + } else { + TVirtualVectorIterators iterators(fFunctionCreateIterators); + iterators.CreateIterators(obj); + b.ReadFastArrayDouble32((Double32_t*)iterators.fBegin, nElements); + } } @@ -805,8 +1242,7 @@ void TGenCollectionStreamer::ReadBuffer(TBuffer &b, void *obj, const TClass *onF // Call the specialized function. The first time this call ReadBufferDefault which // actually set to fReadBufferFunc to the 'right' specialized version. - SetOnFileClass((TClass*)onFileClass); - (this->*fReadBufferFunc)(b,obj); + (this->*fReadBufferFunc)(b,obj,onFileClass); } void TGenCollectionStreamer::ReadBuffer(TBuffer &b, void *obj) @@ -814,14 +1250,16 @@ void TGenCollectionStreamer::ReadBuffer(TBuffer &b, void *obj) // Call the specialized function. The first time this call ReadBufferDefault which // actually set to fReadBufferFunc to the 'right' specialized version. - (this->*fReadBufferFunc)(b,obj); + (this->*fReadBufferFunc)(b,obj,0); } -void TGenCollectionStreamer::ReadBufferDefault(TBuffer &b, void *obj) +void TGenCollectionStreamer::ReadBufferDefault(TBuffer &b, void *obj, const TClass *onFileClass) { fReadBufferFunc = &TGenCollectionStreamer::ReadBufferGeneric; + // We will need this later, so let's make sure it is initialized. + if ( !fValue ) InitializeEx(kFALSE); if (!GetFunctionCreateIterators()) { Fatal("TGenCollectionStreamer::ReadBufferDefault","No CreateIterators function for %s",fName.c_str()); } @@ -884,10 +1322,10 @@ void TGenCollectionStreamer::ReadBufferDefault(TBuffer &b, void *obj) break; } } - (this->*fReadBufferFunc)(b,obj); + (this->*fReadBufferFunc)(b,obj,onFileClass); } -void TGenCollectionStreamer::ReadBufferGeneric(TBuffer &b, void *obj) +void TGenCollectionStreamer::ReadBufferGeneric(TBuffer &b, void *obj, const TClass *onFileClass) { TVirtualCollectionProxy::TPushPop env(this, obj); @@ -908,7 +1346,7 @@ void TGenCollectionStreamer::ReadBufferGeneric(TBuffer &b, void *obj) fClear.invoke(fEnv); } } - ReadPrimitives(nElements, b); + ReadPrimitives(nElements, b, onFileClass); return; case TClassEdit::kVector: if (obj) { @@ -922,10 +1360,10 @@ void TGenCollectionStreamer::ReadBufferGeneric(TBuffer &b, void *obj) switch (fVal->fCase) { case G__BIT_ISFUNDAMENTAL: // Only handle primitives this way case G__BIT_ISENUM: - ReadPrimitives(nElements, b); + ReadPrimitives(nElements, b, onFileClass); return; default: - ReadObjects(nElements, b); + ReadObjects(nElements, b, onFileClass); return; } break; @@ -943,10 +1381,10 @@ void TGenCollectionStreamer::ReadBufferGeneric(TBuffer &b, void *obj) switch (fVal->fCase) { case G__BIT_ISFUNDAMENTAL: // Only handle primitives this way case G__BIT_ISENUM: - ReadPrimitives(nElements, b); + ReadPrimitives(nElements, b, onFileClass); return; default: - ReadObjects(nElements, b); + ReadObjects(nElements, b, onFileClass); return; } break; @@ -959,7 +1397,7 @@ void TGenCollectionStreamer::ReadBufferGeneric(TBuffer &b, void *obj) fClear.invoke(fEnv); } } - ReadMap(nElements, b); + ReadMap(nElements, b, onFileClass); break; } } @@ -977,7 +1415,7 @@ void TGenCollectionStreamer::Streamer(TBuffer &b) if (nElements > 0) { switch (fSTL_type) { case TClassEdit::kBitSet: - ReadPrimitives(nElements, b); + ReadPrimitives(nElements, b, fOnFileClass); return; case TClassEdit::kVector: case TClassEdit::kList: @@ -987,16 +1425,16 @@ void TGenCollectionStreamer::Streamer(TBuffer &b) switch (fVal->fCase) { case G__BIT_ISFUNDAMENTAL: // Only handle primitives this way case G__BIT_ISENUM: - ReadPrimitives(nElements, b); + ReadPrimitives(nElements, b, fOnFileClass); return; default: - ReadObjects(nElements, b); + ReadObjects(nElements, b, fOnFileClass); return; } break; case TClassEdit::kMap: case TClassEdit::kMultiMap: - ReadMap(nElements, b); + ReadMap(nElements, b, fOnFileClass); break; } } @@ -1045,7 +1483,7 @@ void TGenCollectionStreamer::StreamerAsMap(TBuffer &b) switch (fSTL_type) { case TClassEdit::kMap: case TClassEdit::kMultiMap: - ReadMap(nElements, b); + ReadMap(nElements, b, fOnFileClass); break; case TClassEdit::kVector: case TClassEdit::kList: diff --git a/io/io/src/TKey.cxx b/io/io/src/TKey.cxx index e9ba3263cdc90..0a86907212d5a 100644 --- a/io/io/src/TKey.cxx +++ b/io/io/src/TKey.cxx @@ -784,7 +784,7 @@ TObject *TKey::ReadObj() if (fObjlen > fNbytes-fKeylen) { char *objbuf = fBufferRef->Buffer() + fKeylen; UChar_t *bufcur = (UChar_t *)&fBuffer[fKeylen]; - Int_t nin, nout, nbuf; + Int_t nin, nout = 0, nbuf; Int_t noutot = 0; while (1) { Int_t hc = R__unzip_header(&nin, bufcur, &nbuf); @@ -911,7 +911,7 @@ TObject *TKey::ReadObjWithBuffer(char *bufferRead) if (fObjlen > fNbytes-fKeylen) { char *objbuf = fBufferRef->Buffer() + fKeylen; UChar_t *bufcur = (UChar_t *)&fBuffer[fKeylen]; - Int_t nin, nout, nbuf; + Int_t nin, nout = 0, nbuf; Int_t noutot = 0; while (1) { Int_t hc = R__unzip_header(&nin, bufcur, &nbuf); @@ -1056,7 +1056,7 @@ void *TKey::ReadObjectAny(const TClass* expectedClass) if (fObjlen > fNbytes-fKeylen) { char *objbuf = fBufferRef->Buffer() + fKeylen; UChar_t *bufcur = (UChar_t *)&fBuffer[fKeylen]; - Int_t nin, nout, nbuf; + Int_t nin, nout = 0, nbuf; Int_t noutot = 0; while (1) { Int_t hc = R__unzip_header(&nin, bufcur, &nbuf); @@ -1146,7 +1146,7 @@ Int_t TKey::Read(TObject *obj) if (fObjlen > fNbytes-fKeylen) { char *objbuf = fBufferRef->Buffer() + fKeylen; UChar_t *bufcur = (UChar_t *)&fBuffer[fKeylen]; - Int_t nin, nout, nbuf; + Int_t nin, nout = 0, nbuf; Int_t noutot = 0; while (1) { Int_t hc = R__unzip_header(&nin, bufcur, &nbuf); diff --git a/io/io/src/TMemFile.cxx b/io/io/src/TMemFile.cxx index 27357c761ab17..06a6ff635f4df 100644 --- a/io/io/src/TMemFile.cxx +++ b/io/io/src/TMemFile.cxx @@ -317,8 +317,6 @@ void TMemFile::ResetAfterMerge(TFileMergeInfo *info) fNProcessIDs = 0; fOffset = 0; fCacheRead = 0; - delete fCacheReadMap; - fCacheReadMap = 0; fCacheWrite = 0; fReadCalls = 0; if (fFree) { diff --git a/io/io/src/TStreamerInfo.cxx b/io/io/src/TStreamerInfo.cxx index 004eb8c22bd7d..fe97b65839c6d 100644 --- a/io/io/src/TStreamerInfo.cxx +++ b/io/io/src/TStreamerInfo.cxx @@ -90,7 +90,6 @@ static void R__TObjArray_InsertAt(TObjArray *arr, TObject *obj, Int_t at) arr->AddAt( obj, at); } -#if 0 static void R__TObjArray_InsertAfter(TObjArray *arr, TObject *newobj, TObject *oldobj) { // Slide by one. @@ -99,12 +98,9 @@ static void R__TObjArray_InsertAfter(TObjArray *arr, TObject *newobj, TObject *o while (at<last && arr->At(at) != oldobj) { ++at; } - if (at!=0) { - ++at; // we found the object, insert after it - } + ++at; // we found the object, insert after it R__TObjArray_InsertAt(arr, newobj, at); } -#endif static void R__TObjArray_InsertBefore(TObjArray *arr, TObject *newobj, TObject *oldobj) { @@ -218,8 +214,14 @@ void TStreamerInfo::Build() fIsBuilt = kTRUE; if (fClass->GetCollectionProxy()) { - //FIXME: What about arrays of STL containers? - TStreamerElement* element = new TStreamerSTL("This", "Used to call the proper TStreamerInfo case", 0, fClass->GetName(), fClass->GetName(), 0); + TVirtualCollectionProxy *proxy = fClass->GetCollectionProxy(); + TString title; + if (proxy->GetValueClass()) { + title.Form("<%s%s> Used to call the proper TStreamerInfo case",proxy->GetValueClass()->GetName(),proxy->HasPointers() ? "*" : ""); + } else { + title .Form("<%s%s> Used to call the proper TStreamerInfo case",TDataType::GetTypeName(proxy->GetType()),proxy->HasPointers() ? "*" : ""); + } + TStreamerElement* element = new TStreamerSTL("This", title.Data(), 0, fClass->GetName(), *proxy, 0); fElements->Add(element); Compile(); return; @@ -256,7 +258,16 @@ void TStreamerInfo::Build() if (!strcmp(bname, "string")) { element = new TStreamerSTLstring(bname, btitle, offset, bname, kFALSE); } else if (base->IsSTLContainer()) { - element = new TStreamerSTL(bname, btitle, offset, bname, 0, kFALSE); + TVirtualCollectionProxy *proxy = base->GetClassPointer()->GetCollectionProxy(); + if (proxy) element = new TStreamerSTL(bname, btitle, offset, bname, *proxy, kFALSE); + else element = new TStreamerSTL(bname, btitle, offset, bname, 0, kFALSE); + if (fClass->IsLoaded() && ((TStreamerSTL*)element)->GetSTLtype() != TClassEdit::kVector) { + if (!element->GetClassPointer()->IsLoaded()) { + Error("Build","The class \"%s\" is compiled and its base class \"%s\" is a collection and we do not have a dictionary for it, we will not be able to read or write this base class.",GetName(),bname); + delete element; + continue; + } + } } else { element = new TStreamerBase(bname, btitle, offset); TClass* clm = element->GetClassPointer(); @@ -382,7 +393,16 @@ void TStreamerInfo::Build() if (!strcmp(dmType, "string") || !strcmp(dmType, full_string_name)) { element = new TStreamerSTLstring(dmName, dmTitle, offset, dmFull, dmIsPtr); } else if (dm->IsSTLContainer()) { - element = new TStreamerSTL(dmName, dmTitle, offset, dmFull, dm->GetTrueTypeName(), dmIsPtr); + TVirtualCollectionProxy *proxy = TClass::GetClass(dm->GetTypeName() /* the underlying type */)->GetCollectionProxy(); + if (proxy) element = new TStreamerSTL(dmName, dmTitle, offset, dmFull, *proxy, dmIsPtr); + else element = new TStreamerSTL(dmName, dmTitle, offset, dmFull, dm->GetTrueTypeName(), dmIsPtr); + if (fClass->IsLoaded() && ((TStreamerSTL*)element)->GetSTLtype() != TClassEdit::kVector) { + if (!element->GetClassPointer()->IsLoaded()) { + Error("Build","The class \"%s\" is compiled and for its the data member \"%s\", we do not have a dictionary for the collection \"%s\", we will not be able to read or write this data member.",GetName(),dmName,element->GetClassPointer()->GetName()); + delete element; + continue; + } + } } else { TClass* clm = TClass::GetClass(dmType); if (!clm) { @@ -459,6 +479,15 @@ void TStreamerInfo::Build() cached = copy; // Warning("BuildOld","%s::%s is not set from the version %d of %s (You must add a rule for it)\n",GetName(), element->GetName(), GetClassVersion(), GetName() ); + } else { + // If the element is just cached and not repeat, we need to inject an element + // to insure the writing. + TStreamerElement *writecopy = (TStreamerElement*)element->Clone(); + fElements->Add(element); + writecopy->SetBit(TStreamerElement::kWrite); + writecopy->SetNewType( writecopy->GetType() ); + // Put the write element after the read element (that does caching). + element = writecopy; } cached->SetBit(TStreamerElement::kCache); cached->SetNewType( cached->GetType() ); @@ -530,7 +559,45 @@ void TStreamerInfo::BuildCheck() fClass = new TClass(GetName(), fClassVersion, 0, 0, -1, -1); fClass->SetBit(TClass::kIsEmulation); array = fClass->GetStreamerInfos(); - } else { + + // Case of a custom collection (the user provided a CollectionProxy + // for a class that is not an STL collection). + if (GetElements()->GetEntries() == 1) { + TObject *element = GetElements()->UncheckedAt(0); + Bool_t isstl = element && strcmp("This",element->GetName())==0; + if (isstl) { + if (element->GetTitle()[0] == '<') { + // We know the content. + TString content = element->GetTitle(); + Int_t level = 1; + for(Int_t c = 1; c < content.Length(); ++c) { + if (content[c] == '<') ++level; + else if (content[c] == '>') --level; + if (level == 0) { + content.Remove(c+1); + break; + } + } + content.Prepend("vector"); + TClass *clequiv = TClass::GetClass(content); + TVirtualCollectionProxy *proxy = clequiv->GetCollectionProxy(); + if (gDebug > 1) + Info("BuildCheck", + "Update the collection proxy of the class \"%s\" \n" + "\tto be similar to \"%s\".", + GetName(),content.Data()); + fClass->CopyCollectionProxy( *proxy ); + } else { + Warning("BuildCheck", "\n\ + The class %s had a collection proxy when written but it is not an STL\n \ + collection and we did not record the type of the content of the collection.\n \ + We will claim the content is a bool (i.e. no data will be read).", + GetName()); + } + } + } + + } else { if (TClassEdit::IsSTLCont(fClass->GetName())) { SetBit(kCanDelete); return; @@ -547,6 +614,45 @@ void TStreamerInfo::BuildCheck() ::Warning("TClass::TClass", "no dictionary for class %s is available", GetName()); } + // Case of a custom collection (the user provided a CollectionProxy + // for a class that is not an STL collection). + if (GetElements()->GetEntries() == 1) { + TObject *element = GetElements()->UncheckedAt(0); + Bool_t isstl = element && strcmp("This",element->GetName())==0; + if (isstl && !fClass->GetCollectionProxy()) { + if (element->GetTitle()[0] == '<') { + // We know the content. + TString content = element->GetTitle(); + Int_t level = 1; + for(Int_t c = 1; c < content.Length(); ++c) { + if (content[c] == '<') ++level; + else if (content[c] == '>') --level; + if (level == 0) { + content.Remove(c+1); + break; + } + } + content.Prepend("vector"); + TClass *clequiv = TClass::GetClass(content); + TVirtualCollectionProxy *proxy = clequiv->GetCollectionProxy(); + if (gDebug > 1) + Info("BuildCheck", + "Update the collection proxy of the class \"%s\" \n" + "\tto be similar to \"%s\".", + GetName(),content.Data()); + fClass->CopyCollectionProxy( *proxy ); + } else { + Warning("BuildCheck", "\n\ + The class %s had a collection proxy when written but it is not an STL\n \ + collection and we did not record the type of the content of the collection.\n \ + We will claim the content is a bool (i.e. no data will be read).", + GetName()); + } + SetBit(kCanDelete); + return; + } + } + // If the user has not specified a class version (this _used to_ // always be the case when the class is Foreign) or if the user // has specified a version to be explicitly 1. [We can not @@ -1069,7 +1175,9 @@ namespace { } else if (newContent) { TString oldFlatContent( TMakeProject::UpdateAssociativeToVector(oldContent->GetName()) ); TString newFlatContent( TMakeProject::UpdateAssociativeToVector(newContent->GetName()) ); - contentMatch = kTRUE; + if (oldFlatContent == newFlatContent) { + contentMatch = kTRUE; + } } else { contentMatch = kFALSE; } @@ -1211,10 +1319,20 @@ void TStreamerInfo::BuildOld() int nBaze = 0; - if (fClass->GetCollectionProxy() && (fElements->GetEntries() == 1) && !strcmp(fElements->At(0)->GetName(), "This")) { - element = (TStreamerElement*)next(); - element->SetNewType( element->GetType() ); - element->SetNewClass( fClass ); + if ((fElements->GetEntries() == 1) && !strcmp(fElements->At(0)->GetName(), "This")) { + if (fClass->GetCollectionProxy()) { + element = (TStreamerElement*)next(); + element->SetNewType( element->GetType() ); + element->SetNewClass( fClass ); + } else if (((TStreamerElement*)fElements->At(0))->GetType() == TStreamerInfo::kSTL && + !strcmp( ((TStreamerElement*)fElements->At(0))->GetTypeName(),GetName()) == 0) { + // We have a collection that was proxied but does not have a collection proxy, + // let's put one in place just for fun ... humm however we have no clue what is the value + // type .... + + // For now wild guess .... + + } } TClass *allocClass = 0; @@ -1368,6 +1486,14 @@ void TStreamerInfo::BuildOld() if (!bc) { Error("BuildOld", "Could not find STL base class: %s for %s\n", element->GetName(), GetName()); continue; + } else if (bc->GetClassPointer()->GetCollectionProxy() + && !bc->GetClassPointer()->IsLoaded() + && bc->GetClassPointer()->GetCollectionProxy()->GetCollectionType() != TClassEdit::kVector) { + Error("BuildOld","The class \"%s\" is compiled and its base class \"%s\" is a collection and we do not have a dictionary for it, we will not be able to read or write this base class.",GetName(),bc->GetName()); + offset = kMissing; + element->SetOffset(kMissing); + element->SetNewType(-1); + continue; } baseOffset = bc->GetDelta(); asize = bc->GetClassPointer()->Size(); @@ -1451,6 +1577,20 @@ void TStreamerInfo::BuildOld() offset = GetDataMemberOffset(dm, streamer); element->SetOffset(offset); element->Init(this); + // We have a loaded class, let's make sure that if we have a collection + // it is also loaded. + TString dmClassName = TClassEdit::ShortType(dm->GetTypeName(),TClassEdit::kDropStlDefault).c_str(); + dmClassName = dmClassName.Strip(TString::kTrailing, '*'); + if (dmClassName.Index("const ")==0) dmClassName.Remove(0,6); + TClass *elemDm = TClass::GetClass(dmClassName.Data()); + if (elemDm && elemDm->GetCollectionProxy() + && !elemDm->IsLoaded() + && elemDm->GetCollectionProxy()->GetCollectionType() != TClassEdit::kVector) { + Error("BuildOld","The class \"%s\" is compiled and for its data member \"%s\", we do not have a dictionary for the collection \"%s\", we will not be able to read or write this data member.",GetName(),dm->GetName(),elemDm->GetName()); + offset = kMissing; + element->SetOffset(kMissing); + element->SetNewType(-1); + } element->SetStreamer(streamer); int narr = element->GetArrayLength(); if (!narr) { @@ -1631,6 +1771,11 @@ void TStreamerInfo::BuildOld() } else if (CollectionMatchULong64(oldClass,newClass)) { // Not much to do since both are the same collection of 8 bits unsigned entities on file element->Update(oldClass, newClass.GetClass()); + } else if (newClass->GetSchemaRules()->HasRuleWithSourceClass( oldClass->GetName() )) { + //------------------------------------------------------------------------ + // We can convert one type to another (at least for some of the versions). + //------------------------------------------------------------------------ + element->SetNewClass( newClass ); } else { element->SetNewType(-2); } @@ -1639,9 +1784,9 @@ void TStreamerInfo::BuildOld() newClass.GetClass() && newClass->GetSchemaRules() && newClass->GetSchemaRules()->HasRuleWithSourceClass( oldClass->GetName() ) ) { - //----------------------------------------------------------------------- - // We can convert one type to another (at least for some of the versions. - //----------------------------------------------------------------------- + //------------------------------------------------------------------------ + // We can convert one type to another (at least for some of the versions). + //------------------------------------------------------------------------ element->SetNewClass( newClass ); } else { element->SetNewType(-2); @@ -1764,10 +1909,23 @@ void TStreamerInfo::BuildOld() } if (offset != kMissing && fClass->GetDeclFileLine() < 0) { - // Note the initilization in this case are + // Note the initialization in this case are // delayed until __after__ the schema evolution // section, just in case the info has changed. - Int_t asize = element->GetSize(); + + Int_t asize; + if (element->GetType() == TStreamerInfo::kSTL && + strcmp(element->GetName(),"This") == 0 && + strcmp(element->GetTypeName(),GetName()) == 0 && + !fClass->GetCollectionProxy()) { + // Humm .. we are missing the collection Proxy + // for a proxied (custom) collection ... avoid + // an infinite recursion and take a wild guess + asize = sizeof(std::vector<int>); + } else { + // Regular case + asize = element->GetSize(); + } // align the non-basic data types (required on alpha and IRIX!!) if ((offset % sp) != 0) { offset = offset - (offset % sp) + sp; @@ -1776,34 +1934,68 @@ void TStreamerInfo::BuildOld() offset += asize; } - if ( !wasCompiled && rules && rules->HasRuleWithSource( element->GetName(), kTRUE ) ) { + if (!wasCompiled && rules) { + if (rules->HasRuleWithSource( element->GetName(), kTRUE ) ) { + + if (allocClass == 0) { + infoalloc = (TStreamerInfo *)Clone(TString::Format("%s@@%d",GetName(),GetOnFileClassVersion())); + if (!infoalloc) { + Error("BuildOld","Unable to create the StreamerInfo for %s.",TString::Format("%s@@%d",GetName(),GetOnFileClassVersion()).Data()); + } else { + infoalloc->BuildCheck(); + infoalloc->BuildOld(); + allocClass = infoalloc->GetClass(); + } + } - if (allocClass == 0) { - infoalloc = (TStreamerInfo *)Clone(TString::Format("%s@@%d",GetName(),GetOnFileClassVersion())); - if (!infoalloc) { - Error("BuildOld","Unable to create the StreamerInfo for %s.",TString::Format("%s@@%d",GetName(),GetOnFileClassVersion()).Data()); + // Now that we are caching the unconverted element, we do not assign it to the real type even if we could have! + if (element->GetNewType()>0 /* intentionally not including base class for now */ + && !rules->HasRuleWithTarget( element->GetName(), kTRUE ) ) { + + TStreamerElement *copy = (TStreamerElement*)element->Clone(); + R__TObjArray_InsertBefore( fElements, copy, element ); + next(); // move the cursor passed the insert object. + copy->SetBit(TStreamerElement::kRepeat); + element = copy; + + // Warning("BuildOld","%s::%s is not set from the version %d of %s (You must add a rule for it)\n",GetName(), element->GetName(), GetClassVersion(), GetName() ); + } else { + // If the element is just cached and not repeat, we need to inject an element + // to insure the writing. + TStreamerElement *writecopy = (TStreamerElement*)element->Clone(); + R__TObjArray_InsertAfter( fElements, writecopy, element ); + next(); // move the cursor passed the insert object. + writecopy->SetBit(TStreamerElement::kWrite); + writecopy->SetNewType( writecopy->GetType() ); + writecopy->SetBit(TStreamerElement::kCache); + writecopy->SetOffset(infoalloc ? infoalloc->GetOffset(element->GetName()) : 0); + } + element->SetBit(TStreamerElement::kCache); + element->SetNewType( element->GetType() ); + element->SetOffset(infoalloc ? infoalloc->GetOffset(element->GetName()) : 0); + } else if (rules->HasRuleWithTarget( element->GetName(), kTRUE ) ) { + // The data member exist in the onfile StreamerInfo and there is a rule + // that has the same member 'only' has a target ... so this means we are + // asked to ignore the input data ... + if (element->GetType() == kCounter) { + // If the element is a counter, we will need its value to read + // other data member, so let's do so (by not disabling it) even + // if the value will be over-written by a rule. } else { - infoalloc->BuildCheck(); - infoalloc->BuildOld(); - allocClass = infoalloc->GetClass(); + element->SetOffset(kMissing); } } - - // Now that we are caching the unconverted element, we do not assign it to the real type even if we could have! - if (element->GetNewType()>0 /* intentionally not including base class for now */ - && !rules->HasRuleWithTarget( element->GetName(), kTRUE ) ) - { - TStreamerElement *copy = (TStreamerElement*)element->Clone(); - R__TObjArray_InsertBefore( fElements, copy, element ); - next(); // move the cursor passed the insert object. - copy->SetBit(TStreamerElement::kRepeat); - element = copy; - - // Warning("BuildOld","%s::%s is not set from the version %d of %s (You must add a rule for it)\n",GetName(), element->GetName(), GetClassVersion(), GetName() ); + } else if (rules && rules->HasRuleWithTarget( element->GetName(), kTRUE ) ) { + // The data member exist in the onfile StreamerInfo and there is a rule + // that has the same member 'only' has a target ... so this means we are + // asked to ignore the input data ... + if (element->GetType() == kCounter) { + // If the element is a counter, we will need its value to read + // other data member, so let's do so (by not disabling it) even + // if the value will be over-written by a rule. + } else { + element->SetOffset(kMissing); } - element->SetBit(TStreamerElement::kCache); - element->SetNewType( element->GetType() ); - element->SetOffset(infoalloc ? infoalloc->GetOffset(element->GetName()) : 0); } if (element->GetNewType() == -2) { @@ -1895,6 +2087,12 @@ namespace { TString fName; TString fClassName; TString fComment; + Int_t fDataType; + + void SetDataType(Int_t datatype) { + fDataType = datatype; + } + void SetName(const char *name) { fName = name; } @@ -1926,13 +2124,38 @@ namespace { */ Bool_t operator!=(const TMemberInfo &other) { if (fName != other.fName) return kTRUE; - if (fClassName != other.fClassName) { + if (fDataType < TStreamerInfo::kObject) { + // For simple type, let compare the data type + if (fDataType != other.fDataType) { + if ( (fDataType == 4 && other.fDataType == 16) + || (fDataType == 16 && other.fDataType == 4) ) { + // long and 'long long' have the same file format + } else if ( (fDataType == 14 && other.fDataType == 17) + || (fDataType == 17 && other.fDataType == 14) ) { + // unsigned long and 'unsigned long long' have the same file format + } else if ( (fDataType == 3 && other.fDataType == 6) + ||(fDataType == 6 && other.fDataType == 3) ){ + // Int_t and kCounter. As the switch from Int_t (3) to + // kCounter (6) might be triggered by a derived class using + // the field as an array size, the class itself has no + // control on what the field type really use. + } else { + return kTRUE; + } + } + } else if (fClassName != other.fClassName) { if ( (fClassName == "long" && (other.fClassName == "long long" || other.fClassName == "Long64_t")) || ( (fClassName == "long long" || fClassName == "Long64_t") && other.fClassName == "long") ) { // This is okay both have the same on file format. } else if ( (fClassName == "unsigned long" && (other.fClassName == "unsigned long long" || other.fClassName == "ULong64_t")) || ( (fClassName == "unsigned long long" || fClassName == "ULong64_t") && other.fClassName == "unsigned long") ) { // This is okay both have the same on file format. + } else if (TClassEdit::IsSTLCont(fName)) { + TString name = TClassEdit::ShortType( fName, TClassEdit::kDropStlDefault ); + TString othername = TClassEdit::ShortType( other.fName, TClassEdit::kDropStlDefault ); + if (name != othername) { + return kTRUE; + } } else { return kTRUE; } @@ -2101,6 +2324,10 @@ Bool_t TStreamerInfo::CompareContent(TClass *cl, TVirtualStreamerInfo *info, Boo done = kTRUE; break; } + } + if (TClassEdit::IsSTLCont(localClass)) { + localClass = TClassEdit::ShortType( localClass, TClassEdit::kDropStlDefault ); + otherClass = TClassEdit::ShortType( otherClass, TClassEdit::kDropStlDefault ); } // Need to normalized the name if (localClass != otherClass) { @@ -2146,6 +2373,7 @@ Bool_t TStreamerInfo::CompareContent(TClass *cl, TVirtualStreamerInfo *info, Boo local.SetName( el->GetName() ); local.SetClassName( el->GetTypeName() ); local.SetComment( el->GetTitle() ); + local.SetDataType( el->GetType() ); } if (cl) { TDataMember *tdm = (TDataMember*)membernext(); @@ -2154,8 +2382,20 @@ Bool_t TStreamerInfo::CompareContent(TClass *cl, TVirtualStreamerInfo *info, Boo } if (tdm) { other.SetName( tdm->GetName() ); - other.SetClassName( tdm->GetFullTypeName() ); + other.SetClassName( tdm->GetTrueTypeName() ); other.SetComment( tdm->GetTitle() ); + if (tdm->GetDataType()) { + // Need to update the type for arrays. + if (tdm->IsaPointer()) { + other.SetDataType( tdm->GetDataType()->GetType() + TVirtualStreamerInfo::kOffsetP); + } else { + if (tdm->GetArrayDim()) { + other.SetDataType( tdm->GetDataType()->GetType() + TVirtualStreamerInfo::kOffsetL); + } else { + other.SetDataType( tdm->GetDataType()->GetType() ); + } + } + } } else if (el==0) { done = kTRUE; break; @@ -2169,6 +2409,7 @@ Bool_t TStreamerInfo::CompareContent(TClass *cl, TVirtualStreamerInfo *info, Boo other.SetName( infoel->GetName() ); other.SetClassName( infoel->GetTypeName() ); other.SetComment( infoel->GetTitle() ); + other.SetDataType( infoel->GetType() ); } else if (el==0) { done = kTRUE; break; @@ -3244,7 +3485,8 @@ TStreamerElement* TStreamerInfo::GetStreamerElementReal(Int_t i, Int_t j) const } //______________________________________________________________________________ -Double_t TStreamerInfo::GetValueAux(Int_t type, void *ladd, Int_t k, Int_t len) +template <typename T> +T TStreamerInfo::GetTypedValueAux(Int_t type, void *ladd, Int_t k, Int_t len) { // Get the value from inside a collection. @@ -3253,46 +3495,46 @@ Double_t TStreamerInfo::GetValueAux(Int_t type, void *ladd, Int_t k, Int_t len) } switch (type) { // basic types - case kBool: {Bool_t *val = (Bool_t*)ladd; return Double_t(*val);} - case kChar: {Char_t *val = (Char_t*)ladd; return Double_t(*val);} - case kShort: {Short_t *val = (Short_t*)ladd; return Double_t(*val);} - case kInt: {Int_t *val = (Int_t*)ladd; return Double_t(*val);} - case kLong: {Long_t *val = (Long_t*)ladd; return Double_t(*val);} - case kLong64: {Long64_t *val = (Long64_t*)ladd; return Double_t(*val);} - case kFloat: {Float_t *val = (Float_t*)ladd; return Double_t(*val);} - case kFloat16: {Float_t *val = (Float_t*)ladd; return Double_t(*val);} - case kDouble: {Double_t *val = (Double_t*)ladd; return Double_t(*val);} - case kDouble32: {Double_t *val = (Double_t*)ladd; return Double_t(*val);} - case kUChar: {UChar_t *val = (UChar_t*)ladd; return Double_t(*val);} - case kUShort: {UShort_t *val = (UShort_t*)ladd; return Double_t(*val);} - case kUInt: {UInt_t *val = (UInt_t*)ladd; return Double_t(*val);} - case kULong: {ULong_t *val = (ULong_t*)ladd; return Double_t(*val);} + case kBool: {Bool_t *val = (Bool_t*)ladd; return T(*val);} + case kChar: {Char_t *val = (Char_t*)ladd; return T(*val);} + case kShort: {Short_t *val = (Short_t*)ladd; return T(*val);} + case kInt: {Int_t *val = (Int_t*)ladd; return T(*val);} + case kLong: {Long_t *val = (Long_t*)ladd; return T(*val);} + case kLong64: {Long64_t *val = (Long64_t*)ladd; return T(*val);} + case kFloat: {Float_t *val = (Float_t*)ladd; return T(*val);} + case kFloat16: {Float_t *val = (Float_t*)ladd; return T(*val);} + case kDouble: {Double_t *val = (Double_t*)ladd; return T(*val);} + case kDouble32: {Double_t *val = (Double_t*)ladd; return T(*val);} + case kUChar: {UChar_t *val = (UChar_t*)ladd; return T(*val);} + case kUShort: {UShort_t *val = (UShort_t*)ladd; return T(*val);} + case kUInt: {UInt_t *val = (UInt_t*)ladd; return T(*val);} + case kULong: {ULong_t *val = (ULong_t*)ladd; return T(*val);} #if defined(_MSC_VER) && (_MSC_VER <= 1200) - case kULong64: {Long64_t *val = (Long64_t*)ladd; return Double_t(*val);} + case kULong64: {Long64_t *val = (Long64_t*)ladd; return T(*val);} #else - case kULong64: {ULong64_t *val= (ULong64_t*)ladd; return Double_t(*val);} + case kULong64: {ULong64_t *val= (ULong64_t*)ladd; return T(*val);} #endif - case kBits: {UInt_t *val = (UInt_t*)ladd; return Double_t(*val);} + case kBits: {UInt_t *val = (UInt_t*)ladd; return T(*val);} // array of basic types array[8] - case kOffsetL + kBool: {Bool_t *val = (Bool_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kChar: {Char_t *val = (Char_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kShort: {Short_t *val = (Short_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kInt: {Int_t *val = (Int_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kLong: {Long_t *val = (Long_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kLong64: {Long64_t *val = (Long64_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kFloat: {Float_t *val = (Float_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kFloat16: {Float_t *val = (Float_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kDouble: {Double_t *val = (Double_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kDouble32:{Double_t *val = (Double_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kUChar: {UChar_t *val = (UChar_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kUShort: {UShort_t *val = (UShort_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kUInt: {UInt_t *val = (UInt_t*)ladd; return Double_t(val[k]);} - case kOffsetL + kULong: {ULong_t *val = (ULong_t*)ladd; return Double_t(val[k]);} + case kOffsetL + kBool: {Bool_t *val = (Bool_t*)ladd; return T(val[k]);} + case kOffsetL + kChar: {Char_t *val = (Char_t*)ladd; return T(val[k]);} + case kOffsetL + kShort: {Short_t *val = (Short_t*)ladd; return T(val[k]);} + case kOffsetL + kInt: {Int_t *val = (Int_t*)ladd; return T(val[k]);} + case kOffsetL + kLong: {Long_t *val = (Long_t*)ladd; return T(val[k]);} + case kOffsetL + kLong64: {Long64_t *val = (Long64_t*)ladd; return T(val[k]);} + case kOffsetL + kFloat: {Float_t *val = (Float_t*)ladd; return T(val[k]);} + case kOffsetL + kFloat16: {Float_t *val = (Float_t*)ladd; return T(val[k]);} + case kOffsetL + kDouble: {Double_t *val = (Double_t*)ladd; return T(val[k]);} + case kOffsetL + kDouble32:{Double_t *val = (Double_t*)ladd; return T(val[k]);} + case kOffsetL + kUChar: {UChar_t *val = (UChar_t*)ladd; return T(val[k]);} + case kOffsetL + kUShort: {UShort_t *val = (UShort_t*)ladd; return T(val[k]);} + case kOffsetL + kUInt: {UInt_t *val = (UInt_t*)ladd; return T(val[k]);} + case kOffsetL + kULong: {ULong_t *val = (ULong_t*)ladd; return T(val[k]);} #if defined(_MSC_VER) && (_MSC_VER <= 1200) - case kOffsetL + kULong64: {Long64_t *val = (Long64_t*)ladd; return Double_t(val[k]);} + case kOffsetL + kULong64: {Long64_t *val = (Long64_t*)ladd; return T(val[k]);} #else - case kOffsetL + kULong64:{ULong64_t *val= (ULong64_t*)ladd; return Double_t(val[k]);} + case kOffsetL + kULong64:{ULong64_t *val= (ULong64_t*)ladd; return T(val[k]);} #endif #define READ_ARRAY(TYPE_t) \ @@ -3307,7 +3549,7 @@ Double_t TStreamerInfo::GetValueAux(Int_t type, void *ladd, Int_t k, Int_t len) sub_instance = 0; \ } \ TYPE_t **val =(TYPE_t**)(ladd); \ - return Double_t((val[sub_instance])[index]); \ + return T((val[sub_instance])[index]); \ } // pointer to an array of basic types array[n] @@ -3332,13 +3574,18 @@ Double_t TStreamerInfo::GetValueAux(Int_t type, void *ladd, Int_t k, Int_t len) #endif // array counter //[n] - case kCounter: {Int_t *val = (Int_t*)ladd; return Double_t(*val);} + case kCounter: {Int_t *val = (Int_t*)ladd; return T(*val);} } return 0; } //______________________________________________________________________________ -Double_t TStreamerInfo::GetValue(char *pointer, Int_t i, Int_t j, Int_t len) const +template Double_t TStreamerInfo::GetTypedValue(char *pointer, Int_t i, Int_t j, Int_t len) const; +template Long64_t TStreamerInfo::GetTypedValue(char *pointer, Int_t i, Int_t j, Int_t len) const; +template LongDouble_t TStreamerInfo::GetTypedValue(char *pointer, Int_t i, Int_t j, Int_t len) const; + +template <typename T> +T TStreamerInfo::GetTypedValue(char *pointer, Int_t i, Int_t j, Int_t len) const { // return value of element i in object at pointer. // The function may be called in two ways: @@ -3374,15 +3621,20 @@ Double_t TStreamerInfo::GetValue(char *pointer, Int_t i, Int_t j, Int_t len) con Int_t nc = proxy->Size(); if (j >= nc) return 0; char *element_ptr = (char*)proxy->At(j); - return GetValueAux(atype,element_ptr,0,1); + return GetTypedValueAux<T>(atype,element_ptr,0,1); } } } - return GetValueAux(atype,ladd,j,len); + return GetTypedValueAux<T>(atype,ladd,j,len); } //______________________________________________________________________________ -Double_t TStreamerInfo::GetValueClones(TClonesArray *clones, Int_t i, Int_t j, int k, Int_t eoffset) const +template Double_t TStreamerInfo::GetTypedValueClones<Double_t>(TClonesArray *clones, Int_t i, Int_t j, int k, Int_t eoffset) const; +template Long64_t TStreamerInfo::GetTypedValueClones(TClonesArray *clones, Int_t i, Int_t j, int k, Int_t eoffset) const; +template LongDouble_t TStreamerInfo::GetTypedValueClones(TClonesArray *clones, Int_t i, Int_t j, int k, Int_t eoffset) const; + +template <typename T> +T TStreamerInfo::GetTypedValueClones(TClonesArray *clones, Int_t i, Int_t j, int k, Int_t eoffset) const { // return value of element i in object number j in a TClonesArray and eventually // element k in a sub-array. @@ -3392,11 +3644,16 @@ Double_t TStreamerInfo::GetValueClones(TClonesArray *clones, Int_t i, Int_t j, i char *pointer = (char*)clones->UncheckedAt(j); char *ladd = pointer + eoffset + fOffset[i]; - return GetValueAux(fType[i],ladd,k,((TStreamerElement*)fElem[i])->GetArrayLength()); + return GetTypedValueAux<T>(fType[i],ladd,k,((TStreamerElement*)fElem[i])->GetArrayLength()); } //______________________________________________________________________________ -Double_t TStreamerInfo::GetValueSTL(TVirtualCollectionProxy *cont, Int_t i, Int_t j, int k, Int_t eoffset) const +template Double_t TStreamerInfo::GetTypedValueSTL(TVirtualCollectionProxy *cont, Int_t i, Int_t j, int k, Int_t eoffset) const; +template Long64_t TStreamerInfo::GetTypedValueSTL(TVirtualCollectionProxy *cont, Int_t i, Int_t j, int k, Int_t eoffset) const; +template LongDouble_t TStreamerInfo::GetTypedValueSTL(TVirtualCollectionProxy *cont, Int_t i, Int_t j, int k, Int_t eoffset) const; + +template <typename T> +T TStreamerInfo::GetTypedValueSTL(TVirtualCollectionProxy *cont, Int_t i, Int_t j, int k, Int_t eoffset) const { // return value of element i in object number j in a TClonesArray and eventually // element k in a sub-array. @@ -3406,11 +3663,16 @@ Double_t TStreamerInfo::GetValueSTL(TVirtualCollectionProxy *cont, Int_t i, Int_ char *pointer = (char*)cont->At(j); char *ladd = pointer + eoffset + fOffset[i]; - return GetValueAux(fType[i],ladd,k,((TStreamerElement*)fElem[i])->GetArrayLength()); + return GetTypedValueAux<T>(fType[i],ladd,k,((TStreamerElement*)fElem[i])->GetArrayLength()); } //______________________________________________________________________________ -Double_t TStreamerInfo::GetValueSTLP(TVirtualCollectionProxy *cont, Int_t i, Int_t j, int k, Int_t eoffset) const +template Double_t TStreamerInfo::GetTypedValueSTLP(TVirtualCollectionProxy *cont, Int_t i, Int_t j, int k, Int_t eoffset) const; +template Long64_t TStreamerInfo::GetTypedValueSTLP(TVirtualCollectionProxy *cont, Int_t i, Int_t j, int k, Int_t eoffset) const; +template LongDouble_t TStreamerInfo::GetTypedValueSTLP(TVirtualCollectionProxy *cont, Int_t i, Int_t j, int k, Int_t eoffset) const; + +template <typename T> +T TStreamerInfo::GetTypedValueSTLP(TVirtualCollectionProxy *cont, Int_t i, Int_t j, int k, Int_t eoffset) const { // return value of element i in object number j in a TClonesArray and eventually // element k in a sub-array. @@ -3422,7 +3684,7 @@ Double_t TStreamerInfo::GetValueSTLP(TVirtualCollectionProxy *cont, Int_t i, Int char *pointer = *ptr; char *ladd = pointer + eoffset + fOffset[i]; - return GetValueAux(fType[i],ladd,k,((TStreamerElement*)fElem[i])->GetArrayLength()); + return GetTypedValueAux<T>(fType[i],ladd,k,((TStreamerElement*)fElem[i])->GetArrayLength()); } //______________________________________________________________________________ @@ -3440,13 +3702,9 @@ void TStreamerInfo::InsertArtificialElements(const TObjArray *rules) if( rule->IsRenameRule() || rule->IsAliasRule() ) continue; next.Reset(); - Bool_t match = kFALSE; TStreamerElement *element; while ((element = (TStreamerElement*) next())) { if ( rule->HasTarget( element->GetName() ) ) { - // If the rule targets an existing member but it is also a source, - // we still need to insert the rule. - match = ! ((ROOT::TSchemaMatch*)rules)->HasRuleWithSource( element->GetName(), kTRUE ); // Check whether this is an 'attribute' rule. if ( rule->GetAttributes()[0] != 0 ) { @@ -3464,61 +3722,69 @@ void TStreamerInfo::InsertArtificialElements(const TObjArray *rules) break; } } - if (!match) { - TStreamerArtificial *newel; - if (rule->GetTarget()==0) { - TString newName; - newName.Form("%s_rule%d",fClass->GetName(),count); - newel = new TStreamerArtificial(newName,"", - fClass->GetDataMemberOffset(newName), - TStreamerInfo::kArtificial, - "void"); - newel->SetReadFunc( rule->GetReadFunctionPointer() ); - newel->SetReadRawFunc( rule->GetReadRawFunctionPointer() ); - fElements->Add(newel); - } else { - TObjString * objstr = (TObjString*)(rule->GetTarget()->At(0)); - if (objstr) { - TString newName = objstr->String(); - if ( fClass->GetDataMember( newName ) ) { - newel = new TStreamerArtificial(newName,"", - fClass->GetDataMemberOffset(newName), - TStreamerInfo::kArtificial, - fClass->GetDataMember( newName )->GetTypeName()); - newel->SetReadFunc( rule->GetReadFunctionPointer() ); - newel->SetReadRawFunc( rule->GetReadRawFunctionPointer() ); - fElements->Add(newel); - } else { - // This would be a completely new member (so it would need to be cached) - // TOBEDONE - } - for(Int_t other = 1; other < rule->GetTarget()->GetEntries(); ++other) { - objstr = (TObjString*)(rule->GetTarget()->At(other)); - if (objstr) { - newName = objstr->String(); - if ( fClass->GetDataMember( newName ) ) { - newel = new TStreamerArtificial(newName,"", - fClass->GetDataMemberOffset(newName), - TStreamerInfo::kArtificial, - fClass->GetDataMember( newName )->GetTypeName()); - fElements->Add(newel); - } + TStreamerArtificial *newel; + if (rule->GetTarget()==0) { + TString newName; + newName.Form("%s_rule%d",fClass->GetName(),count); + newel = new TStreamerArtificial(newName,"", + fClass->GetDataMemberOffset(newName), + TStreamerInfo::kArtificial, + "void"); + newel->SetBit(TStreamerElement::kWholeObject); + newel->SetReadFunc( rule->GetReadFunctionPointer() ); + newel->SetReadRawFunc( rule->GetReadRawFunctionPointer() ); + fElements->Add(newel); + } else { + TObjString * objstr = (TObjString*)(rule->GetTarget()->At(0)); + if (objstr) { + TString newName = objstr->String(); + if ( fClass->GetDataMember( newName ) ) { + newel = new TStreamerArtificial(newName,"", + fClass->GetDataMemberOffset(newName), + TStreamerInfo::kArtificial, + fClass->GetDataMember( newName )->GetTypeName()); + newel->SetReadFunc( rule->GetReadFunctionPointer() ); + newel->SetReadRawFunc( rule->GetReadRawFunctionPointer() ); + fElements->Add(newel); + } else { + // This would be a completely new member (so it would need to be cached) + // TOBEDONE + } + for(Int_t other = 1; other < rule->GetTarget()->GetEntries(); ++other) { + objstr = (TObjString*)(rule->GetTarget()->At(other)); + if (objstr) { + newName = objstr->String(); + if ( fClass->GetDataMember( newName ) ) { + newel = new TStreamerArtificial(newName,"", + fClass->GetDataMemberOffset(newName), + TStreamerInfo::kArtificial, + fClass->GetDataMember( newName )->GetTypeName()); + fElements->Add(newel); } } - } // For each target of the rule - } - } // None of the target of the rule are on file. - } + } + } // For each target of the rule + } + } // None of the target of the rule are on file. } //______________________________________________________________________________ void TStreamerInfo::ls(Option_t *option) const { // List the TStreamerElement list and also the precomputed tables - if (fClass && fClass->IsForeign() && fClass->GetClassVersion()<2) { - Printf("\nStreamerInfo for class: %s, checksum=0x%x",GetName(),GetCheckSum()); + if (fClass && (fName != fClass->GetName())) { + if (fClass->IsForeign() && fClass->GetClassVersion()<2) { + Printf("\nStreamerInfo for conversion to %s from: %s, checksum=0x%x",fClass->GetName(),GetName(),GetCheckSum()); + } else { + Printf("\nStreamerInfo for conversion to %s from: %s, version=%d, checksum=0x%x",fClass->GetName(),GetName(),fClassVersion,GetCheckSum()); + } + } else { - Printf("\nStreamerInfo for class: %s, version=%d, checksum=0x%x",GetName(),fClassVersion,GetCheckSum()); + if (fClass && fClass->IsForeign() && fClass->GetClassVersion()<2) { + Printf("\nStreamerInfo for class: %s, checksum=0x%x",GetName(),GetCheckSum()); + } else { + Printf("\nStreamerInfo for class: %s, version=%d, checksum=0x%x",GetName(),fClassVersion,GetCheckSum()); + } } if (fElements) { @@ -3529,26 +3795,15 @@ void TStreamerInfo::ls(Option_t *option) const } for (Int_t i=0;i < fNdata;i++) { TStreamerElement *element = (TStreamerElement*)fElem[i]; - TString sequenceType = " ["; - Bool_t first = kTRUE; - if (element->TestBit(TStreamerElement::kCache)) { - first = kFALSE; - sequenceType += "cached"; - } - if (element->TestBit(TStreamerElement::kRepeat)) { - if (!first) sequenceType += ","; - first = kFALSE; - sequenceType += "repeat"; - } - if (element->TestBit(TStreamerElement::kDoNotDelete)) { - if (!first) sequenceType += ","; - first = kFALSE; - sequenceType += "nodelete"; - } - if (first) sequenceType.Clear(); - else sequenceType += "]"; - - Printf(" i=%2d, %-15s type=%3d, offset=%3d, len=%d, method=%ld%s",i,element->GetName(),fType[i],fOffset[i],fLength[i],fMethod[i],sequenceType.Data()); + TString sequenceType; + element->GetSequenceType(sequenceType); + if (sequenceType.Length()) { + sequenceType.Prepend(" ["); + sequenceType += "]"; + } + Printf(" i=%2d, %-15s type=%3d, offset=%3d, len=%d, method=%ld%s", + i,element->GetName(),fType[i],fOffset[i],fLength[i],fMethod[i], + sequenceType.Data()); } } @@ -3656,12 +3911,23 @@ void* TStreamerInfo::New(void *obj) case kTObject: case kTString: case kTNamed: - case kSTL: { cle->New(eaddr); } break; + case kSTL: + { + if (strcmp(element->GetName(),"This")==0 && + !cle->GetCollectionProxy()) { + // missing information, avoid infinite loop + // by doing nothing .... + } else { + cle->New(eaddr); + } + } + break; + case kObject + kOffsetL: case kAny + kOffsetL: case kTObject + kOffsetL: @@ -3830,7 +4096,12 @@ void TStreamerInfo::DestructorImpl(void* obj, Bool_t dtorOnly) // A data member is destroyed, but not deleted. TVirtualCollectionProxy *pr = cle->GetCollectionProxy(); if (!pr) { - cle->Destructor(eaddr, kTRUE); + if (strcmp(ele->GetName(),"This")==0) { + // missing information, avoid infinite loop + // by doing nothing .... + } else { + cle->Destructor(eaddr, kTRUE); + } } else { if (ele->TestBit(TStreamerElement::kDoNotDelete)) { TVirtualCollectionProxy::TPushPop env(cle->GetCollectionProxy(), eaddr); // used for both this 'clear' and the 'clear' inside destructor. @@ -4082,6 +4353,8 @@ void TStreamerInfo::Streamer(TBuffer &R__b) el = (TStreamerElement*)fElements->UncheckedAt(i); if( el != 0 && (el->IsA() == TStreamerArtificial::Class() || el->TestBit(TStreamerElement::kRepeat))) { fElements->RemoveAt( i ); + } else if( el !=0 && (el->TestBit(TStreamerElement::kCache) && !el->TestBit(TStreamerElement::kWrite)) ) { + fElements->RemoveAt( i ); } } fElements->Compress(); diff --git a/io/io/src/TStreamerInfoActions.cxx b/io/io/src/TStreamerInfoActions.cxx index 17cd6d02871c6..340f33a1e0fa0 100644 --- a/io/io/src/TStreamerInfoActions.cxx +++ b/io/io/src/TStreamerInfoActions.cxx @@ -22,6 +22,7 @@ #include "TError.h" #include "TClassEdit.h" #include "TVirtualCollectionIterators.h" +#include "TProcessID.h" static const Int_t kRegrouped = TStreamerInfo::kOffsetL; @@ -42,6 +43,20 @@ using namespace TStreamerInfoActions; namespace TStreamerInfoActions { + template <typename From> + struct WithFactorMarker { + typedef From Value_t; + }; + + template <typename From> + struct NoFactorMarker { + typedef From Value_t; + }; + + struct BitsMarker { + typedef UInt_t Value_t; + }; + void TConfiguration::AddToOffset(Int_t delta) { // Add the (potentially negative) delta to all the configuration's offset. This is used by @@ -62,14 +77,15 @@ namespace TStreamerInfoActions { // Inform the user what we are about to stream. - // Idea: We should print the name of the action function. TStreamerInfo *info = (TStreamerInfo*)fInfo; TStreamerElement *aElement = (TStreamerElement*)info->GetElems()[fElemId]; + TString sequenceType; + aElement->GetSequenceType(sequenceType); printf("StreamerInfoAction, class:%s, name=%s, fType[%d]=%d," - " %s, offset=%d\n", + " %s, offset=%d (%s)\n", info->GetClass()->GetName(), aElement->GetName(), fElemId, info->GetTypes()[fElemId], - aElement->ClassName(), fOffset); + aElement->ClassName(), fOffset, sequenceType.Data()); } void TConfiguration::PrintDebug(TBuffer &buf, void *addr) const @@ -80,11 +96,13 @@ namespace TStreamerInfoActions // Idea: We should print the name of the action function. TStreamerInfo *info = (TStreamerInfo*)fInfo; TStreamerElement *aElement = (TStreamerElement*)info->GetElems()[fElemId]; - + TString sequenceType; + aElement->GetSequenceType(sequenceType); + printf("StreamerInfoAction, class:%s, name=%s, fType[%d]=%d," - " %s, bufpos=%d, arr=%p, offset=%d\n", + " %s, bufpos=%d, arr=%p, offset=%d (%s)\n", info->GetClass()->GetName(), aElement->GetName(), fElemId, info->GetTypes()[fElemId], - aElement->ClassName(), buf.Length(), addr, fOffset); + aElement->ClassName(), buf.Length(), addr, fOffset, sequenceType.Data()); } } @@ -104,8 +122,43 @@ namespace TStreamerInfoActions void PrintDebug(TBuffer &, void *) const { // Since we call the old code, it will print the debug statement. } - }; + + virtual TConfiguration *Copy() { return new TGenericConfiguration(*this); } + }; + + struct TBitsConfiguration : TConfiguration { + // Configuration of action handling kBits. + // In this case we need to know both the location + // of the member (fBits) and the start of the object + // (its TObject part to be exact). + + Int_t fObjectOffset; // Offset of the TObject part within the object + + TBitsConfiguration(TVirtualStreamerInfo *info, UInt_t id, Int_t offset = 0) : TConfiguration(info,id,offset),fObjectOffset(0) {}; + void PrintDebug(TBuffer &, void *) const { + TStreamerInfo *info = (TStreamerInfo*)fInfo; + TStreamerElement *aElement = (TStreamerElement*)info->GetElems()[fElemId]; + TString sequenceType; + aElement->GetSequenceType(sequenceType); + + printf("StreamerInfoAction, class:%s, name=%s, fType[%d]=%d," + " %s, offset=%d (%s)\n", + info->GetClass()->GetName(), aElement->GetName(), fElemId, info->GetTypes()[fElemId], + aElement->ClassName(), fOffset, sequenceType.Data()); + } + + void AddToOffset(Int_t delta) + { + // Add the (potentially negative) delta to all the configuration's offset. This is used by + // TBranchElement in the case of split sub-object. + + fOffset += delta; + fObjectOffset = 0; + } + virtual TConfiguration *Copy() { return new TBitsConfiguration(*this); } + + }; Int_t GenericReadAction(TBuffer &buf, void *addr, const TConfiguration *config) { @@ -130,6 +183,40 @@ namespace TStreamerInfoActions return 0; } + void HandleReferencedTObject(TBuffer &buf, void *addr, const TConfiguration *config) { + TBitsConfiguration *conf = (TBitsConfiguration*)config; + UShort_t pidf; + buf >> pidf; + pidf += buf.GetPidOffset(); + TProcessID *pid = buf.ReadProcessID(pidf); + if (pid!=0) { + TObject *obj = (TObject*)( ((char*)addr) + conf->fObjectOffset); + UInt_t gpid = pid->GetUniqueID(); + UInt_t uid; + if (gpid>=0xff) { + uid = obj->GetUniqueID() | 0xff000000; + } else { + uid = ( obj->GetUniqueID() & 0xffffff) + (gpid<<24); + } + obj->SetUniqueID(uid); + pid->PutObjectWithID(obj); + } + } + + template <> + INLINE_TEMPLATE_ARGS Int_t ReadBasicType<BitsMarker>(TBuffer &buf, void *addr, const TConfiguration *config) + { + UInt_t *x = (UInt_t*)( ((char*)addr) + config->fOffset ); + // Idea: Implement buf.ReadBasic/Primitive to avoid the return value + // Idea: This code really belongs inside TBuffer[File] + buf >> *x; + + if ((*x & kIsReferenced) != 0) { + HandleReferencedTObject(buf,addr,config); + } + return 0; + } + template <typename T> INLINE_TEMPLATE_ARGS Int_t WriteBasicType(TBuffer &buf, void *addr, const TConfiguration *config) { @@ -255,6 +342,23 @@ namespace TStreamerInfoActions virtual TConfiguration *Copy() { return new TConfigSTL(*this); } }; + class TConfSTLWithFactor : public TConfigSTL { + // Configuration object for the Float16/Double32 where a factor has been specified. + public: + Double_t fFactor; + Double_t fXmin; + TConfSTLWithFactor(TConfigSTL *orig, Double_t factor, Double_t xmin) : TConfigSTL(*orig),fFactor(factor),fXmin(xmin) {}; + virtual TConfiguration *Copy() { return new TConfSTLWithFactor(*this); } + }; + + class TConfSTLNoFactor : public TConfigSTL { + // Configuration object for the Float16/Double32 where a factor has been specified. + public: + Int_t fNbits; + TConfSTLNoFactor(TConfigSTL *orig, Int_t nbits) : TConfigSTL(*orig),fNbits(nbits) {}; + virtual TConfiguration *Copy() { return new TConfSTLNoFactor(*this); } + }; + class TVectorLoopConfig : public TLoopConfiguration { // Base class of the Configurations used in member wise streaming. protected: @@ -367,10 +471,14 @@ namespace TStreamerInfoActions TClass *oldClass = config->fOldClass; - TClass *valueClass = oldClass->GetCollectionProxy()->GetValueClass(); + TVirtualCollectionProxy *oldProxy = oldClass->GetCollectionProxy(); + if (!oldProxy) { + // Missing information, broken file ... give up + return; + } + TClass *valueClass = oldProxy->GetValueClass(); Version_t vClVersion = buf.ReadVersionForMemberWise( valueClass ); - TVirtualCollectionProxy *oldProxy = oldClass->GetCollectionProxy(); TVirtualCollectionProxy::TPushPop helper( oldProxy, (char*)addr ); Int_t nobjects; buf.ReadInt(nobjects); @@ -382,7 +490,7 @@ namespace TStreamerInfoActions char endbuf[TVirtualCollectionProxy::fgIteratorArenaSize]; void *begin = &(startbuf[0]); void *end = &(endbuf[0]); - config->fCreateIterators(alternative, &begin, &end ); + config->fCreateIterators(alternative, &begin, &end, oldProxy); // We can not get here with a split vector of pointer, so we can indeed assume // that actions->fConfiguration != null. buf.ApplySequence(*actions, begin, end); @@ -398,6 +506,10 @@ namespace TStreamerInfoActions TClass *oldClass = config->fOldClass; TVirtualCollectionProxy *oldProxy = oldClass->GetCollectionProxy(); + if (!oldProxy) { + // Missing information, broken file ... give up + return; + } TVirtualCollectionProxy::TPushPop helper( oldProxy, (char*)addr ); Int_t nobjects; @@ -429,10 +541,14 @@ namespace TStreamerInfoActions TClass *oldClass = config->fOldClass; - TClass *valueClass = oldClass->GetCollectionProxy()->GetValueClass(); + TVirtualCollectionProxy *oldProxy = oldClass->GetCollectionProxy(); + if (!oldProxy) { + // Missing information, broken file ... give up + return; + } + TClass *valueClass = oldProxy->GetValueClass(); Version_t vClVersion = buf.ReadVersionForMemberWise( valueClass ); - TVirtualCollectionProxy *oldProxy = oldClass->GetCollectionProxy(); TActionSequence *actions = oldProxy->GetReadMemberWiseActions( vClVersion ); int objectSize = oldClass->Size(); @@ -449,7 +565,7 @@ namespace TStreamerInfoActions char endbuf[TVirtualCollectionProxy::fgIteratorArenaSize]; void *begin = &(startbuf[0]); void *end = &(endbuf[0]); - config->fCreateIterators(alternative, &begin, &end ); + config->fCreateIterators(alternative, &begin, &end, oldProxy); // We can not get here with a split vector of pointer, so we can indeed assume // that actions->fConfiguration != null. buf.ApplySequence(*actions, begin, end); @@ -464,8 +580,12 @@ namespace TStreamerInfoActions } else { TClass *oldClass = config->fOldClass; - + TVirtualCollectionProxy *oldProxy = oldClass->GetCollectionProxy(); + if (!oldProxy) { + // Missing information, broken file ... give up + return; + } int objectSize = oldClass->Size(); char *obj = (char*)addr; @@ -523,7 +643,7 @@ namespace TStreamerInfoActions char endbuf[TVirtualCollectionProxy::fgIteratorArenaSize]; void *begin = &(startbuf[0]); void *end = &(endbuf[0]); - config->fCreateIterators( alternative, &begin, &end ); + config->fCreateIterators( alternative, &begin, &end, newProxy); // We can not get here with a split vector of pointer, so we can indeed assume // that actions->fConfiguration != null. buf.ApplySequence(*actions, begin, end); @@ -572,7 +692,7 @@ namespace TStreamerInfoActions char endbuf[TVirtualCollectionProxy::fgIteratorArenaSize]; void *begin = &(startbuf[0]); void *end = &(endbuf[0]); - config->fCreateIterators( alternative, &begin, &end ); + config->fCreateIterators( alternative, &begin, &end, newProxy); // We can not get here with a split vector of pointer, so we can indeed assume // that actions->fConfiguration != null. buf.ApplySequence(*actions, begin, end); @@ -641,14 +761,59 @@ namespace TStreamerInfoActions } template <typename From, typename To> - INLINE_TEMPLATE_ARGS Int_t ConvertBasicType(TBuffer &buf, void *addr, const TConfiguration *config) - { - // Simple conversion from a 'From' on disk to a 'To' in memory. - From temp; - buf >> temp; - *(To*)( ((char*)addr) + config->fOffset ) = (To)temp; - return 0; - } + struct ConvertBasicType { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *addr, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + From temp; + buf >> temp; + *(To*)( ((char*)addr) + config->fOffset ) = (To)temp; + return 0; + } + }; + + template <typename To> + struct ConvertBasicType<BitsMarker,To> { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *addr, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory + UInt_t temp; + buf >> temp; + + if ((temp & kIsReferenced) != 0) { + HandleReferencedTObject(buf,addr,config); + } + + *(To*)( ((char*)addr) + config->fOffset ) = (To)temp; + return 0; + } + }; + + template <typename From, typename To> + struct ConvertBasicType<WithFactorMarker<From>,To> { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *addr, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + TConfWithFactor *conf = (TConfWithFactor *)config; + From temp; + buf.ReadWithFactor(&temp, conf->fFactor, conf->fXmin); + *(To*)( ((char*)addr) + config->fOffset ) = (To)temp; + return 0; + } + }; + + template <typename From, typename To> + struct ConvertBasicType<NoFactorMarker<From>,To> { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *addr, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + TConfNoFactor *conf = (TConfNoFactor *)config; + From temp; + buf.ReadWithNbits(&temp, conf->fNbits); + *(To*)( ((char*)addr) + config->fOffset ) = (To)temp; + return 0; + } + }; class TConfigurationUseCache : public TConfiguration { // Configuration object for the UseCache case. @@ -795,337 +960,1294 @@ namespace TStreamerInfoActions return 0; } - Int_t GenericVectorPtrReadAction(TBuffer &buf, void *iter, const void *end, const TConfiguration *config) - { - Int_t n = ( ((void**)end) - ((void**)iter) ); - char **arr = (char**)iter; - return ((TStreamerInfo*)config->fInfo)->ReadBuffer(buf, arr, config->fElemId, n, config->fOffset, 1|2 ); - } + enum ESelectLooper { kVectorLooper, kVectorPtrLooper, kAssociativeLooper, kGenericLooper }; - Int_t GenericVectorPtrWriteAction(TBuffer &buf, void *iter, const void *end, const TConfiguration *config) + ESelectLooper SelectLooper(TVirtualCollectionProxy &proxy) { - Int_t n = ( ((void**)end) - ((void**)iter) ); - char **arr = (char**)iter; - return ((TStreamerInfo*)config->fInfo)->WriteBufferAux(buf, arr, config->fElemId, n, config->fOffset, 1|2 ); + if ( (proxy.GetCollectionType() == TClassEdit::kVector) || (proxy.GetProperties() & TVirtualCollectionProxy::kIsEmulated) ) { + return kVectorLooper; + } else if (proxy.GetCollectionType() == TClassEdit::kSet || proxy.GetCollectionType() == TClassEdit::kMultiSet + || proxy.GetCollectionType() == TClassEdit::kMap || proxy.GetCollectionType() == TClassEdit::kMultiMap + || proxy.GetCollectionType() == TClassEdit::kBitSet) { + return kAssociativeLooper; + } else { + return kGenericLooper; + } } - Int_t ReadVectorBase(TBuffer &buf, void *start, const void *end, const TLoopConfiguration * loopconfig, const TConfiguration *config) - { - // Well the implementation is non trivial since we do not have a proxy for the container of _only_ the base class. For now - // punt. - - UInt_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; - UInt_t n = (((char*)end)-((char*)start))/incr; - char **arrptr = new char*[n]; - UInt_t i = 0; - for(void *iter = start; iter != end; iter = (char*)iter + incr, ++i ) { - arrptr[i] = (char*)iter; - } - ((TStreamerInfo*)config->fInfo)->ReadBuffer(buf, arrptr, config->fElemId, n, config->fOffset, 1|2 ); - delete [] arrptr; - -// // Idea: need to cache this result! -// TStreamerInfo *info = (TStreamerInfo*)config->fInfo; -// TStreamerElement *aElement = (TStreamerElement*)info->GetElems()[config->fElemId]; -// Int_t clversion = ((TStreamerBase*)aElement)->GetBaseVersion(); -// TClass *cle = aElement->GetNewBaseClass(); -// TSequence *actions = CreateReadMemberWiseActions( cle->GetStreamerInfo(clversion), ???? ); -// actions->ReadBuffer(b,start,end); -// delete actions; - -// const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; -// for(void *iter = start; iter != end; iter = (char*)iter + incr ) -// { -// Int_t clversion = ((TStreamerBase*)aElement)->GetBaseVersion(); -// ((TStreamerInfo*)cle->GetStreamerInfo(clversion))->ReadBuffer(b,arr,-1,narr,ioffset,arrayMode); -// -// ((TStreamerInfo*)config->fInfo)->ReadBuffer(buf, (char**)&iter, config->fElemId, 1, config->fOffset, 1|2 ); -// } - return 0; - } + struct VectorLooper { - Int_t ReadVectorWrapping(TBuffer &buf, void *start, const void *end, const TLoopConfiguration * loopconfig, const TConfiguration *config) - { - // Well the implementation is non trivial. For now punt. + template <typename T> + static INLINE_TEMPLATE_ARGS Int_t ReadBasicType(TBuffer &buf, void *iter, const void *end, const TLoopConfiguration *loopconfig, const TConfiguration *config) + { + const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; + iter = (char*)iter + config->fOffset; + end = (char*)end + config->fOffset; + for(; iter != end; iter = (char*)iter + incr ) { + T *x = (T*) ((char*) iter); + buf >> *x; + } + return 0; + } - UInt_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; - UInt_t n = (((char*)end)-((char*)start))/incr; - char **arrptr = new char*[n]; - UInt_t i = 0; - for(void *iter = start; iter != end; iter = (char*)iter + incr, ++i ) { - arrptr[i] = (char*)iter; + template <typename From, typename To> + struct ConvertBasicType { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *iter, const void *end, const TLoopConfiguration *loopconfig, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + From temp; + const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; + iter = (char*)iter + config->fOffset; + end = (char*)end + config->fOffset; + for(; iter != end; iter = (char*)iter + incr ) { + buf >> temp; + *(To*)( ((char*)iter) ) = (To)temp; + } + return 0; + } + }; + + template <typename To> + struct ConvertBasicType<BitsMarker,To> { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *iter, const void *end, const TLoopConfiguration *loopconfig, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + UInt_t temp; + const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; + iter = (char*)iter + config->fOffset; + end = (char*)end + config->fOffset; + for(; iter != end; iter = (char*)iter + incr ) { + buf >> temp; + + if ((temp & kIsReferenced) != 0) { + HandleReferencedTObject(buf, (char*)iter - config->fOffset, config); + } + + *(To*)( ((char*)iter) ) = (To)temp; + } + return 0; + } + }; + + template <typename From, typename To> + struct ConvertBasicType<WithFactorMarker<From>,To> { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *iter, const void *end, const TLoopConfiguration *loopconfig, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + TConfWithFactor *conf = (TConfWithFactor *)config; + From temp; + const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; + iter = (char*)iter + config->fOffset; + end = (char*)end + config->fOffset; + for(; iter != end; iter = (char*)iter + incr ) { + buf.ReadWithFactor(&temp, conf->fFactor, conf->fXmin); + *(To*)( ((char*)iter) ) = (To)temp; + } + return 0; + } + }; + + template <typename From, typename To> + struct ConvertBasicType<NoFactorMarker<From>,To> { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *iter, const void *end, const TLoopConfiguration *loopconfig, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + TConfNoFactor *conf = (TConfNoFactor *)config; + From temp; + const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; + iter = (char*)iter + config->fOffset; + end = (char*)end + config->fOffset; + for(; iter != end; iter = (char*)iter + incr ) { + buf.ReadWithNbits(&temp, conf->fNbits); + *(To*)( ((char*)iter) ) = (To)temp; + } + return 0; + } + }; + + template <typename T> + static INLINE_TEMPLATE_ARGS Int_t WriteBasicType(TBuffer &buf, void *iter, const void *end, const TLoopConfiguration *loopconfig, const TConfiguration *config) + { + const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; + iter = (char*)iter + config->fOffset; + end = (char*)end + config->fOffset; + for(; iter != end; iter = (char*)iter + incr ) { + T *x = (T*) ((char*) iter); + buf << *x; + } + return 0; } - ((TStreamerInfo*)config->fInfo)->ReadBuffer(buf, arrptr, config->fElemId, n, config->fOffset, 1|2 ); - delete [] arrptr; - return 0; - } - Int_t WriteVectorWrapping(TBuffer &buf, void *start, const void *end, const TLoopConfiguration * loopconfig, const TConfiguration *config) - { - // Well the implementation is non trivial. For now punt. + template <Int_t (*iter_action)(TBuffer&,void *,const TConfiguration*)> + static INLINE_TEMPLATE_ARGS Int_t ReadAction(TBuffer &buf, void *start, const void *end, const TLoopConfiguration *loopconfig, const TConfiguration *config) + { + const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; + //Idea: can we factor out the addition of fOffset + // iter = (char*)iter + config->fOffset; + for(void *iter = start; iter != end; iter = (char*)iter + incr ) { + iter_action(buf, iter, config); + } + return 0; + } - UInt_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; - UInt_t n = (((char*)end)-((char*)start))/incr; - char **arrptr = new char*[n]; - UInt_t i = 0; - for(void *iter = start; iter != end; iter = (char*)iter + incr, ++i ) { - arrptr[i] = (char*)iter; + static INLINE_TEMPLATE_ARGS Int_t ReadBase(TBuffer &buf, void *start, const void *end, const TLoopConfiguration * loopconfig, const TConfiguration *config) + { + // Well the implementation is non trivial since we do not have a proxy for the container of _only_ the base class. For now + // punt. + + UInt_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; + UInt_t n = (((char*)end)-((char*)start))/incr; + char **arrptr = new char*[n]; + UInt_t i = 0; + for(void *iter = start; iter != end; iter = (char*)iter + incr, ++i ) { + arrptr[i] = (char*)iter; + } + ((TStreamerInfo*)config->fInfo)->ReadBuffer(buf, arrptr, config->fElemId, n, config->fOffset, 1|2 ); + delete [] arrptr; + + // // Idea: need to cache this result! + // TStreamerInfo *info = (TStreamerInfo*)config->fInfo; + // TStreamerElement *aElement = (TStreamerElement*)info->GetElems()[config->fElemId]; + // Int_t clversion = ((TStreamerBase*)aElement)->GetBaseVersion(); + // TClass *cle = aElement->GetNewBaseClass(); + // TSequence *actions = CreateReadMemberWiseActions( cle->GetStreamerInfo(clversion), ???? ); + // actions->ReadBuffer(b,start,end); + // delete actions; + + // const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; + // for(void *iter = start; iter != end; iter = (char*)iter + incr ) + // { + // Int_t clversion = ((TStreamerBase*)aElement)->GetBaseVersion(); + // ((TStreamerInfo*)cle->GetStreamerInfo(clversion))->ReadBuffer(b,arr,-1,narr,ioffset,arrayMode); + // + // ((TStreamerInfo*)config->fInfo)->ReadBuffer(buf, (char**)&iter, config->fElemId, 1, config->fOffset, 1|2 ); + // } + return 0; + } + + static INLINE_TEMPLATE_ARGS Int_t GenericRead(TBuffer &buf, void *start, const void *end, const TLoopConfiguration * loopconfig, const TConfiguration *config) + { + // Well the implementation is non trivial. For now punt. + + UInt_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; + UInt_t n = (((char*)end)-((char*)start))/incr; + char **arrptr = new char*[n]; + UInt_t i = 0; + for(void *iter = start; iter != end; iter = (char*)iter + incr, ++i ) { + arrptr[i] = (char*)iter; + } + ((TStreamerInfo*)config->fInfo)->ReadBuffer(buf, arrptr, config->fElemId, n, config->fOffset, 1|2 ); + delete [] arrptr; + return 0; } - ((TStreamerInfo*)config->fInfo)->WriteBufferAux(buf, arrptr, config->fElemId, n, config->fOffset, 1|2 ); - delete [] arrptr; - return 0; - } - Int_t GenericVectorReadAction(TBuffer &buf, void *start, const void *end, const TLoopConfiguration * loopconfig, const TConfiguration *config) - { - const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; - for(void *iter = start; iter != end; iter = (char*)iter + incr ) { - void **iter_ptr = &iter; - ((TStreamerInfo*)config->fInfo)->ReadBuffer(buf, (char**)iter_ptr, config->fElemId, 1, config->fOffset, 1|2 ); + static INLINE_TEMPLATE_ARGS Int_t GenericWrite(TBuffer &buf, void *start, const void *end, const TLoopConfiguration * loopconfig, const TConfiguration *config) + { + // Well the implementation is non trivial. For now punt. + + UInt_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; + UInt_t n = (((char*)end)-((char*)start))/incr; + char **arrptr = new char*[n]; + UInt_t i = 0; + for(void *iter = start; iter != end; iter = (char*)iter + incr, ++i ) { + arrptr[i] = (char*)iter; + } + ((TStreamerInfo*)config->fInfo)->WriteBufferAux(buf, arrptr, config->fElemId, n, config->fOffset, 1|2 ); + delete [] arrptr; + return 0; } - return 0; - } - Int_t GenericCollectionReadAction(TBuffer &buf, void *, const void *, const TLoopConfiguration * loopconf, const TConfiguration *config) - { - TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; - TVirtualCollectionProxy *proxy = loopconfig->fProxy; - return ((TStreamerInfo*)config->fInfo)->ReadBuffer(buf, *proxy, config->fElemId, proxy->Size(), config->fOffset, 1|2 ); - } + template <typename T> + static INLINE_TEMPLATE_ARGS Int_t ReadCollectionBasicType(TBuffer &buf, void *addr, const TConfiguration *conf) + { + // Collection of numbers. Memberwise or not, it is all the same. + + TConfigSTL *config = (TConfigSTL*)conf; + UInt_t start, count; + /* Version_t vers = */ buf.ReadVersion(&start, &count, config->fOldClass); + + std::vector<T> *const vec = (std::vector<T>*)(((char*)addr)+config->fOffset); + Int_t nvalues; + buf.ReadInt(nvalues); + vec->resize(nvalues); + +#ifdef R__VISUAL_CPLUSPLUS + if (nvalues <= 0) { + buf.CheckByteCount(start,count,config->fTypeName); + return 0; + } +#endif + T *begin = &(*vec->begin()); + buf.ReadFastArray(begin, nvalues); - Int_t GenericCollectionWriteAction(TBuffer &buf, void *, const void *, const TLoopConfiguration * loopconf, const TConfiguration *config) - { - TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; - TVirtualCollectionProxy *proxy = loopconfig->fProxy; - return ((TStreamerInfo*)config->fInfo)->WriteBufferAux(buf, *proxy, config->fElemId, proxy->Size(), config->fOffset, 1|2 ); - } + buf.CheckByteCount(start,count,config->fTypeName); + return 0; + } - Int_t GenericAssocCollectionReadAction(TBuffer &buf, void *, const void *, const TLoopConfiguration *loopconf, const TConfiguration *config) - { - TAssocLoopConfig *loopconfig = (TAssocLoopConfig*)loopconf; - TVirtualCollectionProxy *proxy = loopconfig->fProxy; - return ((TStreamerInfo*)config->fInfo)->ReadBuffer(buf, *proxy, config->fElemId, proxy->Size(), config->fOffset, 1|2 ); - } + static INLINE_TEMPLATE_ARGS Int_t ReadCollectionBool(TBuffer &buf, void *addr, const TConfiguration *conf) + { + // Collection of numbers. Memberwise or not, it is all the same. + + TConfigSTL *config = (TConfigSTL*)conf; + UInt_t start, count; + /* Version_t vers = */ buf.ReadVersion(&start, &count, config->fOldClass); + + std::vector<bool> *const vec = (std::vector<bool>*)(((char*)addr)+config->fOffset); + Int_t nvalues; + buf.ReadInt(nvalues); + vec->resize(nvalues); + + bool *items = new bool[nvalues]; + buf.ReadFastArray(items, nvalues); + for(Int_t i = 0 ; i < nvalues; ++i) { + (*vec)[i] = items[i]; + } + delete [] items; + + // We could avoid the call to ReadFastArray, and we could + // the following, however this breaks TBufferXML ... + // for(Int_t i = 0 ; i < nvalues; ++i) { + // bool tmp; buf >> tmp; + // (*vec)[i] = tmp; + // } + + buf.CheckByteCount(start,count,config->fTypeName); + return 0; + } - template <typename T> - Int_t ReadBasicTypeVectorLoop(TBuffer &buf, void *iter, const void *end, const TLoopConfiguration *loopconfig, const TConfiguration *config) - { - const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; - iter = (char*)iter + config->fOffset; - end = (char*)end + config->fOffset; - for(; iter != end; iter = (char*)iter + incr ) { - T *x = (T*) ((char*) iter); - buf >> *x; + static INLINE_TEMPLATE_ARGS Int_t ReadCollectionFloat16(TBuffer &buf, void *addr, const TConfiguration *conf) + { + // Collection of numbers. Memberwise or not, it is all the same. + + TConfigSTL *config = (TConfigSTL*)conf; + UInt_t start, count; + /* Version_t vers = */ buf.ReadVersion(&start, &count, config->fOldClass); + + std::vector<float> *const vec = (std::vector<float>*)(((char*)addr)+config->fOffset); + Int_t nvalues; + buf.ReadInt(nvalues); + vec->resize(nvalues); + +#ifdef R__VISUAL_CPLUSPLUS + if (nvalues <= 0) { + buf.CheckByteCount(start,count,config->fTypeName); + return 0; + } +#endif + float *begin = &(*vec->begin()); + buf.ReadFastArrayFloat16(begin, nvalues); + + buf.CheckByteCount(start,count,config->fTypeName); + return 0; } - return 0; - } - template <typename T> - Int_t WriteBasicTypeVectorLoop(TBuffer &buf, void *iter, const void *end, const TLoopConfiguration *loopconfig, const TConfiguration *config) - { - const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; - iter = (char*)iter + config->fOffset; - end = (char*)end + config->fOffset; - for(; iter != end; iter = (char*)iter + incr ) { - T *x = (T*) ((char*) iter); - buf << *x; + static INLINE_TEMPLATE_ARGS Int_t ReadCollectionDouble32(TBuffer &buf, void *addr, const TConfiguration *conf) + { + // Collection of numbers. Memberwise or not, it is all the same. + + TConfigSTL *config = (TConfigSTL*)conf; + UInt_t start, count; + /* Version_t vers = */ buf.ReadVersion(&start, &count, config->fOldClass); + + std::vector<double> *const vec = (std::vector<double>*)(((char*)addr)+config->fOffset); + Int_t nvalues; + buf.ReadInt(nvalues); + vec->resize(nvalues); + +#ifdef R__VISUAL_CPLUSPLUS + if (nvalues <= 0) { + buf.CheckByteCount(start,count,config->fTypeName); + return 0; + } +#endif + double *begin = &(*vec->begin()); + buf.ReadFastArrayDouble32(begin, nvalues); + + buf.CheckByteCount(start,count,config->fTypeName); + return 0; } - return 0; - } - template <typename T> - Int_t ReadBasicTypeGenericLoop(TBuffer &buf, void *start, const void *end, const TLoopConfiguration *loopconf, const TConfiguration *config) - { - TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + template <typename From, typename To> + struct ConvertCollectionBasicType { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *addr, const TConfiguration *conf) + { + // Collection of numbers. Memberwise or not, it is all the same. + + TConfigSTL *config = (TConfigSTL*)conf; + UInt_t start, count; + /* Version_t vers = */ buf.ReadVersion(&start, &count, config->fOldClass); + + std::vector<To> *const vec = (std::vector<To>*)(((char*)addr)+config->fOffset); + Int_t nvalues; + buf.ReadInt(nvalues); + vec->resize(nvalues); + + From *temp = new From[nvalues]; + buf.ReadFastArray(temp, nvalues); + for(Int_t ind = 0; ind < nvalues; ++ind) { + (*vec)[ind] = (To)temp[ind]; + } + delete [] temp; + + buf.CheckByteCount(start,count,config->fTypeName); + return 0; + } + }; + + template <typename From, typename To> + struct ConvertCollectionBasicType<NoFactorMarker<From>,To> { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *addr, const TConfiguration *conf) + { + // Collection of numbers. Memberwise or not, it is all the same. + + TConfigSTL *config = (TConfigSTL*)conf; + UInt_t start, count; + /* Version_t vers = */ buf.ReadVersion(&start, &count, config->fOldClass); + + std::vector<To> *const vec = (std::vector<To>*)(((char*)addr)+config->fOffset); + Int_t nvalues; + buf.ReadInt(nvalues); + vec->resize(nvalues); + + From *temp = new From[nvalues]; + buf.ReadFastArrayWithNbits(temp, nvalues, 0); + for(Int_t ind = 0; ind < nvalues; ++ind) { + (*vec)[ind] = (To)temp[ind]; + } + delete [] temp; + + buf.CheckByteCount(start,count,config->fTypeName); + return 0; + } + }; + + template <typename To> + static INLINE_TEMPLATE_ARGS Int_t ConvertCollectionDouble32(TBuffer &buf, void *addr, const TConfiguration *conf) + { + // Collection of numbers. Memberwise or not, it is all the same. + + TConfigSTL *config = (TConfigSTL*)conf; + UInt_t start, count; + /* Version_t vers = */ buf.ReadVersion(&start, &count, config->fOldClass); + + std::vector<To> *const vec = (std::vector<To>*)(((char*)addr)+config->fOffset); + Int_t nvalues; + buf.ReadInt(nvalues); + vec->resize(nvalues); + + Double32_t *temp = new Double32_t[nvalues]; + buf.ReadFastArrayDouble32(temp, nvalues); + for(Int_t ind = 0; ind < nvalues; ++ind) { + (*vec)[ind] = (To)temp[ind]; + } + delete [] temp; + + buf.CheckByteCount(start,count,config->fTypeName); + return 0; + } + + }; + + struct VectorPtrLooper { + + template <typename T> + static INLINE_TEMPLATE_ARGS Int_t ReadBasicType(TBuffer &buf, void *iter, const void *end, const TConfiguration *config) + { + const Int_t offset = config->fOffset; + + for(; iter != end; iter = (char*)iter + sizeof(void*) ) { + T *x = (T*)( ((char*) (*(void**)iter) ) + offset ); + buf >> *x; + } + return 0; + } + + template <typename From, typename To> + struct ConvertBasicType { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *iter, const void *end, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + From temp; + const Int_t offset = config->fOffset; + for(; iter != end; iter = (char*)iter + sizeof(void*) ) { + buf >> temp; + To *x = (To*)( ((char*) (*(void**)iter) ) + offset ); + *x = (To)temp; + } + return 0; + } + }; + + template <typename To> + struct ConvertBasicType<BitsMarker,To> { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *iter, const void *end, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + UInt_t temp; + const Int_t offset = config->fOffset; + for(; iter != end; iter = (char*)iter + sizeof(void*) ) { + buf >> temp; + + if ((temp & kIsReferenced) != 0) { + HandleReferencedTObject(buf,*(void**)iter,config); + } + + To *x = (To*)( ((char*) (*(void**)iter) ) + offset ); + *x = (To)temp; + } + return 0; + } + }; + + template <typename From, typename To> + struct ConvertBasicType<WithFactorMarker<From>,To> { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *iter, const void *end, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + TConfWithFactor *conf = (TConfWithFactor *)config; + From temp; + const Int_t offset = config->fOffset; + for(; iter != end; iter = (char*)iter + sizeof(void*) ) { + buf.ReadWithFactor(&temp, conf->fFactor, conf->fXmin); + To *x = (To*)( ((char*) (*(void**)iter) ) + offset ); + *x = (To)temp; + } + return 0; + } + }; + + template <typename From, typename To> + struct ConvertBasicType<NoFactorMarker<From>,To> { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *iter, const void *end, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + TConfNoFactor *conf = (TConfNoFactor *)config; + From temp; + const Int_t offset = config->fOffset; + for(; iter != end; iter = (char*)iter + sizeof(void*) ) { + buf.ReadWithNbits(&temp, conf->fNbits); + To *x = (To*)( ((char*) (*(void**)iter) ) + offset ); + *x = (To)temp; + } + return 0; + } + }; + + template <typename T> + static INLINE_TEMPLATE_ARGS Int_t WriteBasicType(TBuffer &buf, void *iter, const void *end, const TConfiguration *config) + { + const Int_t offset = config->fOffset; + + for(; iter != end; iter = (char*)iter + sizeof(void*) ) { + T *x = (T*)( ((char*) (*(void**)iter) ) + offset ); + buf << *x; + } + return 0; + } + + template <Int_t (*action)(TBuffer&,void *,const TConfiguration*)> + static INLINE_TEMPLATE_ARGS Int_t ReadAction(TBuffer &buf, void *start, const void *end, const TConfiguration *config) + { + for(void *iter = start; iter != end; iter = (char*)iter + sizeof(void*) ) { + action(buf, *(void**)iter, config); + } + return 0; + } + + static INLINE_TEMPLATE_ARGS Int_t ReadBase(TBuffer &buf, void *start, const void *end, const TConfiguration *config) + { + // Well the implementation is non trivial since we do not have a proxy for the container of _only_ the base class. For now + // punt. + + return GenericRead(buf,start,end,config); + } + + static INLINE_TEMPLATE_ARGS Int_t GenericRead(TBuffer &buf, void *iter, const void *end, const TConfiguration *config) + { + Int_t n = ( ((void**)end) - ((void**)iter) ); + char **arr = (char**)iter; + return ((TStreamerInfo*)config->fInfo)->ReadBuffer(buf, arr, config->fElemId, n, config->fOffset, 1|2 ); + } + + static INLINE_TEMPLATE_ARGS Int_t GenericWrite(TBuffer &buf, void *iter, const void *end, const TConfiguration *config) + { + Int_t n = ( ((void**)end) - ((void**)iter) ); + char **arr = (char**)iter; + return ((TStreamerInfo*)config->fInfo)->WriteBufferAux(buf, arr, config->fElemId, n, config->fOffset, 1|2 ); + } + + }; + + struct AssociativeLooper { + + template <typename T> + static INLINE_TEMPLATE_ARGS void SimpleRead(TBuffer &buf, void *addr, Int_t nvalues) + { + buf.ReadFastArray((T*)addr, nvalues); + } + + static INLINE_TEMPLATE_ARGS void SimpleReadFloat16(TBuffer &buf, void *addr, Int_t nvalues) + { + buf.ReadFastArrayFloat16((float*)addr, nvalues); + } + + static INLINE_TEMPLATE_ARGS void SimpleReadDouble32(TBuffer &buf, void *addr, Int_t nvalues) + { + buf.ReadFastArrayDouble32((double*)addr, nvalues); + } + + template <typename T,void (*action)(TBuffer&,void *,Int_t)> + static INLINE_TEMPLATE_ARGS Int_t ReadNumericalCollection(TBuffer &buf, void *addr, const TConfiguration *conf) + { + // Collection of numbers. Memberwise or not, it is all the same. + + TConfigSTL *config = (TConfigSTL*)conf; + UInt_t start, count; + /* Version_t vers = */ buf.ReadVersion(&start, &count, config->fOldClass); + + TClass *newClass = config->fNewClass; + TVirtualCollectionProxy *newProxy = newClass->GetCollectionProxy(); + TVirtualCollectionProxy::TPushPop helper( newProxy, ((char*)addr)+config->fOffset ); + + Int_t nvalues; + buf.ReadInt(nvalues); + void* alternative = newProxy->Allocate(nvalues,true); + if (nvalues) { + char startbuf[TVirtualCollectionProxy::fgIteratorArenaSize]; + char endbuf[TVirtualCollectionProxy::fgIteratorArenaSize]; + void *begin = &(startbuf[0]); + void *end = &(endbuf[0]); + config->fCreateIterators(alternative, &begin, &end, newProxy); + // We can not get here with a split vector of pointer, so we can indeed assume + // that actions->fConfiguration != null. + + action(buf,begin,nvalues); + + if (begin != &(startbuf[0])) { + // assert(end != endbuf); + config->fDeleteTwoIterators(begin,end); + } + } + newProxy->Commit(alternative); + + buf.CheckByteCount(start,count,config->fTypeName); + return 0; + } + + static INLINE_TEMPLATE_ARGS Int_t ReadCollectionBool(TBuffer &buf, void *addr, const TConfiguration *conf) + { + return ReadNumericalCollection<bool,SimpleRead<bool> >(buf,addr,conf); + } + + static INLINE_TEMPLATE_ARGS Int_t ReadCollectionFloat16(TBuffer &buf, void *addr, const TConfiguration *conf) + { + return ReadNumericalCollection<Float_t,SimpleReadFloat16 >(buf,addr,conf); + } + + static INLINE_TEMPLATE_ARGS Int_t ReadCollectionDouble32(TBuffer &buf, void *addr, const TConfiguration *conf) + { + return ReadNumericalCollection<Double_t,SimpleReadDouble32 >(buf,addr,conf); + } + + template <typename T> + static INLINE_TEMPLATE_ARGS Int_t ReadCollectionBasicType(TBuffer &buf, void *addr, const TConfiguration *conf) + { + return ReadNumericalCollection<T,SimpleRead<T> >(buf,addr,conf); + } + + template <typename From, typename To> + struct ConvertRead { + static INLINE_TEMPLATE_ARGS void Action(TBuffer &buf, void *addr, Int_t nvalues) + { + From *temp = new From[nvalues]; + buf.ReadFastArray(temp, nvalues); + To *vec = (To*)addr; + for(Int_t ind = 0; ind < nvalues; ++ind) { + vec[ind] = (To)temp[ind]; + } + delete [] temp; + } + }; + + template <typename From, typename To> + struct ConvertRead<NoFactorMarker<From>,To> { + static INLINE_TEMPLATE_ARGS void Action(TBuffer &buf, void *addr, Int_t nvalues) + { + From *temp = new From[nvalues]; + buf.ReadFastArrayWithNbits(temp, nvalues,0); + To *vec = (To*)addr; + for(Int_t ind = 0; ind < nvalues; ++ind) { + vec[ind] = (To)temp[ind]; + } + delete [] temp; + } + }; + + template <typename From, typename To> + struct ConvertRead<WithFactorMarker<From>,To> { + static INLINE_TEMPLATE_ARGS void Action(TBuffer &buf, void *addr, Int_t nvalues) + { + From *temp = new From[nvalues]; + double factor,min; // needs to be initialized. + buf.ReadFastArrayWithFactor(temp, nvalues, factor, min); + To *vec = (To*)addr; + for(Int_t ind = 0; ind < nvalues; ++ind) { + vec[ind] = (To)temp[ind]; + } + delete [] temp; + } + }; + + template <typename From, typename To> + struct ConvertCollectionBasicType { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *addr, const TConfiguration *conf) + { + return ReadNumericalCollection<To,ConvertRead<From,To>::Action >(buf,addr,conf); + } + }; + + }; + + struct GenericLooper { + + template <typename T> + static INLINE_TEMPLATE_ARGS Int_t ReadBasicType(TBuffer &buf, void *start, const void *end, const TLoopConfiguration *loopconf, const TConfiguration *config) + { + TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + + Next_t next = loopconfig->fNext; + const Int_t offset = config->fOffset; + + char iterator[TVirtualCollectionProxy::fgIteratorArenaSize]; + void *iter = loopconfig->fCopyIterator(iterator,start); + void *addr; + while( (addr = next(iter,end)) ) { + T *x = (T*)( ((char*)addr) + offset ); + buf >> *x; + } + if (iter != &iterator[0]) { + loopconfig->fDeleteIterator(iter); + } + return 0; + } + + template <typename T> + static INLINE_TEMPLATE_ARGS Int_t WriteBasicType(TBuffer &buf, void *start, const void *end, const TLoopConfiguration *loopconf, const TConfiguration *config) + { + TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + + Next_t next = loopconfig->fNext; + const Int_t offset = config->fOffset; + + char iterator[TVirtualCollectionProxy::fgIteratorArenaSize]; + void *iter = loopconfig->fCopyIterator(iterator,start); + void *addr; + while( (addr = next(iter,end)) ) { + T *x = (T*)( ((char*)addr) + offset ); + buf << *x; + } + if (iter != &iterator[0]) { + loopconfig->fDeleteIterator(iter); + } + return 0; + } + + template <Int_t (*iter_action)(TBuffer&,void *,const TConfiguration*)> + static INLINE_TEMPLATE_ARGS Int_t ReadAction(TBuffer &buf, void *start, const void *end, const TLoopConfiguration *loopconf, const TConfiguration *config) + { + TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + + // const Int_t offset = config->fOffset; + Next_t next = loopconfig->fNext; + + char iterator[TVirtualCollectionProxy::fgIteratorArenaSize]; + void *iter = loopconfig->fCopyIterator(&iterator,start); + void *addr; + while( (addr = next(iter,end)) ) { + iter_action(buf, addr, config); + } + if (iter != &iterator[0]) { + loopconfig->fDeleteIterator(iter); + } + return 0; + } + + template <typename From, typename To> + struct Generic { + static void ConvertAction(From *items, void *start, const void *end, const TLoopConfiguration *loopconf, const TConfiguration *config) + { + TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + + const Int_t offset = config->fOffset; + Next_t next = loopconfig->fNext; + + char iterator[TVirtualCollectionProxy::fgIteratorArenaSize]; + void *iter = loopconfig->fCopyIterator(&iterator,start); + void *addr; + while( (addr = next(iter,end)) ) { + To *x = (To*)( ((char*)addr) + offset ); + *x = (To)(*items); + ++items; + } + if (iter != &iterator[0]) { + loopconfig->fDeleteIterator(iter); + } + } + }; + + template <typename From, typename To> + struct Numeric { + static void ConvertAction(From *items, void *start, const void *end, const TLoopConfiguration *loopconf, const TConfiguration * /* config */) + { + // The difference with ConvertAction is that we can modify the start + // iterator and skip the copy. We also never have an offset. + + TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + Next_t next = loopconfig->fNext; + + void *iter = start; + void *addr; + while( (addr = next(iter,end)) ) { + To *x = (To*)(addr); + *x = (To)(*items); + ++items; + } + } + }; + + template <typename From, typename To, template <typename F, typename T> class Converter = Generic > + struct ConvertBasicType { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *start, const void *end, const TLoopConfiguration *loopconf, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + + TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + TVirtualCollectionProxy *proxy = loopconfig->fProxy; + Int_t nvalues = proxy->Size(); + + From *items = new From[nvalues]; + buf.ReadFastArray(items, nvalues); + Converter<From,To>::ConvertAction(items,start,end,loopconfig,config); + delete [] items; + return 0; + } + }; + + template <typename To> + struct ConvertBasicType<BitsMarker, To, Generic> { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *start, const void *end, const TLoopConfiguration *loopconf, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + + TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + TVirtualCollectionProxy *proxy = loopconfig->fProxy; + Int_t nvalues = proxy->Size(); + + UInt_t *items_storage = new UInt_t[nvalues]; + UInt_t *items = items_storage; + + const Int_t offset = config->fOffset; + Next_t next = loopconfig->fNext; + + char iterator[TVirtualCollectionProxy::fgIteratorArenaSize]; + void *iter = loopconfig->fCopyIterator(&iterator,start); + void *addr; + while( (addr = next(iter,end)) ) { + buf >> (*items); + if (((*items) & kIsReferenced) != 0) { + HandleReferencedTObject(buf, addr, config); + } + To *x = (To*)( ((char*)addr) + offset ); + *x = (To)(*items); + ++items; + } + if (iter != &iterator[0]) { + loopconfig->fDeleteIterator(iter); + } + + delete [] items_storage; + return 0; + } + }; + + template <typename From, typename To, template <typename F, typename T> class Converter > + struct ConvertBasicType<WithFactorMarker<From>,To,Converter > { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *start, const void *end, const TLoopConfiguration *loopconf, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + + TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + TVirtualCollectionProxy *proxy = loopconfig->fProxy; + Int_t nvalues = proxy->Size(); + + TConfSTLWithFactor *conf = (TConfSTLWithFactor *)config; + + From *items = new From[nvalues]; + buf.ReadFastArrayWithFactor(items, nvalues, conf->fFactor, conf->fXmin); + Converter<From,To>::ConvertAction(items,start,end,loopconfig,config); + delete [] items; + return 0; + } + }; + + template <typename From, typename To, template <typename F, typename T> class Converter > + struct ConvertBasicType<NoFactorMarker<From>,To,Converter > { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *start, const void *end, const TLoopConfiguration *loopconf, const TConfiguration *config) + { + // Simple conversion from a 'From' on disk to a 'To' in memory. + + TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + TVirtualCollectionProxy *proxy = loopconfig->fProxy; + Int_t nvalues = proxy->Size(); + + TConfSTLNoFactor *conf = (TConfSTLNoFactor *)config; + + From *items = new From[nvalues]; + buf.ReadFastArrayWithNbits(items, nvalues, conf->fNbits); + Converter<From,To>::ConvertAction(items,start,end,loopconfig,config); + delete [] items; + return 0; + } + }; + + static INLINE_TEMPLATE_ARGS Int_t ReadBase(TBuffer &buf, void *start, const void *end, const TLoopConfiguration * loopconfig, const TConfiguration *config) + { + // Well the implementation is non trivial since we do not have a proxy for the container of _only_ the base class. For now + // punt. + + return GenericRead(buf,start,end,loopconfig, config); + } + + static INLINE_TEMPLATE_ARGS Int_t GenericRead(TBuffer &buf, void *, const void *, const TLoopConfiguration * loopconf, const TConfiguration *config) + { + TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + TVirtualCollectionProxy *proxy = loopconfig->fProxy; + return ((TStreamerInfo*)config->fInfo)->ReadBuffer(buf, *proxy, config->fElemId, proxy->Size(), config->fOffset, 1|2 ); + } + + static INLINE_TEMPLATE_ARGS Int_t GenericWrite(TBuffer &buf, void *, const void *, const TLoopConfiguration * loopconf, const TConfiguration *config) + { + TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + TVirtualCollectionProxy *proxy = loopconfig->fProxy; + return ((TStreamerInfo*)config->fInfo)->WriteBufferAux(buf, *proxy, config->fElemId, proxy->Size(), config->fOffset, 1|2 ); + } + + template <typename T> + static INLINE_TEMPLATE_ARGS void SimpleRead(TBuffer &buf, void *addr) + { + buf >> *(T*)addr; + } + + static INLINE_TEMPLATE_ARGS void SimpleReadFloat16(TBuffer &buf, void *addr) + { + buf.ReadWithNbits((float*)addr,12); + } + + static INLINE_TEMPLATE_ARGS void SimpleReadDouble32(TBuffer &buf, void *addr) + { + //we read a float and convert it to double + Float_t afloat; + buf >> afloat; + *(double*)addr = (Double_t)afloat; + } + + template <typename ActionHolder> + static INLINE_TEMPLATE_ARGS Int_t ReadNumericalCollection(TBuffer &buf, void *addr, const TConfiguration *conf) + { + // Collection of numbers. Memberwise or not, it is all the same. - // const Int_t offset = config->fOffset; - Next_t next = loopconfig->fNext; - const Int_t offset = config->fOffset; + TConfigSTL *config = (TConfigSTL*)conf; + UInt_t start, count; + /* Version_t vers = */ buf.ReadVersion(&start, &count, config->fOldClass); - char iterator[TVirtualCollectionProxy::fgIteratorArenaSize]; - void *iter = loopconfig->fCopyIterator(iterator,start); - void *addr; - while( (addr = next(iter,end)) ) { - T *x = (T*)( ((char*)addr) + offset ); - buf >> *x; - } - if (iter != &iterator[0]) { - loopconfig->fDeleteIterator(iter); - } - return 0; - } + TClass *newClass = config->fNewClass; + TVirtualCollectionProxy *newProxy = newClass->GetCollectionProxy(); + TVirtualCollectionProxy::TPushPop helper( newProxy, ((char*)addr)+config->fOffset ); - template <typename T> - Int_t WriteBasicTypeGenericLoop(TBuffer &buf, void *start, const void *end, const TLoopConfiguration *loopconf, const TConfiguration *config) - { - TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; + Int_t nvalues; + buf.ReadInt(nvalues); + void* alternative = newProxy->Allocate(nvalues,true); + if (nvalues) { + char startbuf[TVirtualCollectionProxy::fgIteratorArenaSize]; + char endbuf[TVirtualCollectionProxy::fgIteratorArenaSize]; + void *begin = &(startbuf[0]); + void *end = &(endbuf[0]); + config->fCreateIterators(alternative, &begin, &end, newProxy); + // We can not get here with a split vector of pointer, so we can indeed assume + // that actions->fConfiguration != null. + + TGenericLoopConfig loopconf(newProxy); + ActionHolder::Action(buf,begin,end,&loopconf,config); + + if (begin != &(startbuf[0])) { + // assert(end != endbuf); + config->fDeleteTwoIterators(begin,end); + } + } + newProxy->Commit(alternative); - // const Int_t offset = config->fOffset; - Next_t next = loopconfig->fNext; - const Int_t offset = config->fOffset; + buf.CheckByteCount(start,count,config->fTypeName); + return 0; + } - char iterator[TVirtualCollectionProxy::fgIteratorArenaSize]; - void *iter = loopconfig->fCopyIterator(iterator,start); - void *addr; - while( (addr = next(iter,end)) ) { - T *x = (T*)( ((char*)addr) + offset ); - buf << *x; + static INLINE_TEMPLATE_ARGS Int_t ReadCollectionBool(TBuffer &buf, void *addr, const TConfiguration *conf) + { + return ReadNumericalCollection<ConvertBasicType<bool,bool,Numeric > >(buf,addr,conf); } - if (iter != &iterator[0]) { - loopconfig->fDeleteIterator(iter); + + static INLINE_TEMPLATE_ARGS Int_t ReadCollectionFloat16(TBuffer &buf, void *addr, const TConfiguration *conf) + { + return ReadNumericalCollection<ConvertBasicType<NoFactorMarker<float>,float,Numeric > >(buf,addr,conf); + } + + static INLINE_TEMPLATE_ARGS Int_t ReadCollectionDouble32(TBuffer &buf, void *addr, const TConfiguration *conf) + { + return ReadNumericalCollection<ConvertBasicType<float,double,Numeric > >(buf,addr,conf); + // Could also use: + // return ReadNumericalCollection<ConvertBasicType<NoFactorMarker<double>,double,Numeric > >(buf,addr,conf); + } + + template <typename T> + static INLINE_TEMPLATE_ARGS Int_t ReadCollectionBasicType(TBuffer &buf, void *addr, const TConfiguration *conf) + { + return ReadNumericalCollection<ConvertBasicType<T,T,Numeric > >(buf,addr,conf); } - return 0; - } - template <typename T> - Int_t ReadBasicTypeVectorPtrLoop(TBuffer &buf, void *iter, const void *end, const TConfiguration *config) - { - const Int_t offset = config->fOffset; + template <typename From, typename To> + struct ConvertCollectionBasicType { + static INLINE_TEMPLATE_ARGS Int_t Action(TBuffer &buf, void *addr, const TConfiguration *conf) + { + // return ReadNumericalCollection<To,ConvertRead<From,To>::Action >(buf,addr,conf); + return ReadNumericalCollection<ConvertBasicType<From,To,Numeric > >(buf,addr,conf); + } + }; + + }; +} - for(; iter != end; iter = (char*)iter + sizeof(void*) ) { - T *x = (T*)( ((char*) (*(void**)iter) ) + offset ); - buf >> *x; - } - return 0; +template <typename Looper, typename From> +static TConfiguredAction GetCollectionReadConvertAction(Int_t newtype, TConfiguration *conf) +{ + switch (newtype) { + case TStreamerInfo::kBool: return TConfiguredAction( Looper::template ConvertBasicType<From,bool>::Action, conf ); break; + case TStreamerInfo::kChar: return TConfiguredAction( Looper::template ConvertBasicType<From,char>::Action, conf ); break; + case TStreamerInfo::kShort: return TConfiguredAction( Looper::template ConvertBasicType<From,short>::Action, conf ); break; + case TStreamerInfo::kInt: return TConfiguredAction( Looper::template ConvertBasicType<From,Int_t>::Action, conf ); break; + case TStreamerInfo::kLong: return TConfiguredAction( Looper::template ConvertBasicType<From,Long_t>::Action, conf ); break; + case TStreamerInfo::kLong64: return TConfiguredAction( Looper::template ConvertBasicType<From,Long64_t>::Action, conf ); break; + case TStreamerInfo::kFloat: return TConfiguredAction( Looper::template ConvertBasicType<From,float>::Action, conf ); break; + case TStreamerInfo::kFloat16: return TConfiguredAction( Looper::template ConvertBasicType<From,float>::Action, conf ); break; + case TStreamerInfo::kDouble: return TConfiguredAction( Looper::template ConvertBasicType<From,double>::Action, conf ); break; + case TStreamerInfo::kDouble32:return TConfiguredAction( Looper::template ConvertBasicType<From,double>::Action, conf ); break; + case TStreamerInfo::kUChar: return TConfiguredAction( Looper::template ConvertBasicType<From,UChar_t>::Action, conf ); break; + case TStreamerInfo::kUShort: return TConfiguredAction( Looper::template ConvertBasicType<From,UShort_t>::Action, conf ); break; + case TStreamerInfo::kUInt: return TConfiguredAction( Looper::template ConvertBasicType<From,UInt_t>::Action, conf ); break; + case TStreamerInfo::kULong: return TConfiguredAction( Looper::template ConvertBasicType<From,ULong_t>::Action, conf ); break; + case TStreamerInfo::kULong64: return TConfiguredAction( Looper::template ConvertBasicType<From,ULong64_t>::Action, conf ); break; + case TStreamerInfo::kBits: return TConfiguredAction( Looper::template ConvertBasicType<From,UInt_t>::Action, conf ); break; + default: + return TConfiguredAction( Looper::GenericRead, conf ); + break; } + R__ASSERT(0); // We should never be here + return TConfiguredAction(); +} - template <typename T> - Int_t WriteBasicTypeVectorPtrLoop(TBuffer &buf, void *iter, const void *end, const TConfiguration *config) - { - const Int_t offset = config->fOffset; +template <class Looper> +static TConfiguredAction GetNumericCollectionReadAction(Int_t type, TConfigSTL *conf) +{ + // If we ever support std::vector<Double32_t> fValues; //[...] we would get the info from the StreamerElement for fValues. - for(; iter != end; iter = (char*)iter + sizeof(void*) ) { - T *x = (T*)( ((char*) (*(void**)iter) ) + offset ); - buf << *x; + switch (type) { + // Read basic types. + case /* kBOOL_t = */ 21: + case TStreamerInfo::kBool: return TConfiguredAction( Looper::ReadCollectionBool, conf ); break; + case TStreamerInfo::kChar: return TConfiguredAction( Looper::template ReadCollectionBasicType<Char_t>, conf ); break; + case TStreamerInfo::kShort: return TConfiguredAction( Looper::template ReadCollectionBasicType<Short_t>,conf ); break; + case TStreamerInfo::kInt: return TConfiguredAction( Looper::template ReadCollectionBasicType<Int_t>, conf ); break; + case TStreamerInfo::kLong: return TConfiguredAction( Looper::template ReadCollectionBasicType<Long_t>, conf ); break; + case TStreamerInfo::kLong64: return TConfiguredAction( Looper::template ReadCollectionBasicType<Long64_t>, conf ); break; + case TStreamerInfo::kFloat: return TConfiguredAction( Looper::template ReadCollectionBasicType<Float_t>, conf ); break; + case TStreamerInfo::kDouble: return TConfiguredAction( Looper::template ReadCollectionBasicType<Double_t>, conf ); break; + case TStreamerInfo::kUChar: return TConfiguredAction( Looper::template ReadCollectionBasicType<UChar_t>, conf ); break; + case TStreamerInfo::kUShort: return TConfiguredAction( Looper::template ReadCollectionBasicType<UShort_t>, conf ); break; + case TStreamerInfo::kUInt: return TConfiguredAction( Looper::template ReadCollectionBasicType<UInt_t>, conf ); break; + case TStreamerInfo::kULong: return TConfiguredAction( Looper::template ReadCollectionBasicType<ULong_t>, conf ); break; + case TStreamerInfo::kULong64: return TConfiguredAction( Looper::template ReadCollectionBasicType<ULong64_t>, conf ); break; + case TStreamerInfo::kBits: Error("GetNumericCollectionReadAction","There is no support for kBits outside of a TObject."); break; + case TStreamerInfo::kFloat16: { + TConfigSTL *alternate = new TConfSTLNoFactor(conf,12); + delete conf; + return TConfiguredAction( Looper::ReadCollectionFloat16, alternate ); + // if (element->GetFactor() != 0) { + // return TConfiguredAction( Looper::template ReadAction<ReadBasicType_WithFactor<float> >, new TConfWithFactor(info,i,offset,element->GetFactor(),element->GetXmin()) ); + // } else { + // Int_t nbits = (Int_t)element->GetXmin(); + // if (!nbits) nbits = 12; + // return TConfiguredAction( Looper::template ReadAction<ReadBasicType_NoFactor<float> >, new TConfNoFactor(info,i,offset,nbits) ); + // } + break; } - return 0; - } - - template <Int_t (*action)(TBuffer&,void *,const TConfiguration*)> - Int_t VectorPtrLooper(TBuffer &buf, void *start, const void *end, const TConfiguration *config) - { - for(void *iter = start; iter != end; iter = (char*)iter + sizeof(void*) ) { - action(buf, *(void**)iter, config); + case TStreamerInfo::kDouble32: { + TConfigSTL *alternate = new TConfSTLNoFactor(conf,0); + delete conf; + return TConfiguredAction( Looper::ReadCollectionDouble32, alternate ); + // if (element->GetFactor() != 0) { + // return TConfiguredAction( Looper::template ReadAction<ReadBasicType_WithFactor<double> >, new TConfWithFactor(info,i,offset,element->GetFactor(),element->GetXmin()) ); + // } else { + // Int_t nbits = (Int_t)element->GetXmin(); + // if (!nbits) { + // return TConfiguredAction( Looper::template ReadAction<ConvertBasicType<float,double> >, new TConfiguration(info,i,offset) ); + // } else { + // return TConfiguredAction( Looper::template ReadAction<ReadBasicType_NoFactor<double> >, new TConfNoFactor(info,i,offset,nbits) ); + // } + // } + break; } - return 0; } + R__ASSERT(0); // We should never be here + return TConfiguredAction(); +} - template <Int_t (*action)(TBuffer&,void *,const TConfiguration*)> - Int_t VectorLooper(TBuffer &buf, void *start, const void *end, const TLoopConfiguration *loopconfig, const TConfiguration *config) - { - const Int_t incr = ((TVectorLoopConfig*)loopconfig)->fIncrement; - //Idea: can we factor out the addition of fOffset - // iter = (char*)iter + config->fOffset; - for(void *iter = start; iter != end; iter = (char*)iter + incr ) { - action(buf, iter, config); - } - return 0; +template <typename Looper, typename From> +static TConfiguredAction GetConvertCollectionReadActionFrom(Int_t newtype, TConfiguration *conf) +{ + switch (newtype) { + case TStreamerInfo::kBool: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,bool>::Action, conf ); break; + case TStreamerInfo::kChar: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,char>::Action, conf ); break; + case TStreamerInfo::kShort: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,short>::Action, conf ); break; + case TStreamerInfo::kInt: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,Int_t>::Action, conf ); break; + case TStreamerInfo::kLong: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,Long_t>::Action, conf ); break; + case TStreamerInfo::kLong64: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,Long64_t>::Action, conf ); break; + case TStreamerInfo::kFloat: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,float>::Action, conf ); break; + case TStreamerInfo::kFloat16: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,float>::Action, conf ); break; + case TStreamerInfo::kDouble: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,double>::Action, conf ); break; + case TStreamerInfo::kDouble32:return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,double>::Action, conf ); break; + case TStreamerInfo::kUChar: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,UChar_t>::Action, conf ); break; + case TStreamerInfo::kUShort: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,UShort_t>::Action, conf ); break; + case TStreamerInfo::kUInt: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,UInt_t>::Action, conf ); break; + case TStreamerInfo::kULong: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,ULong_t>::Action, conf ); break; + case TStreamerInfo::kULong64: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,ULong64_t>::Action, conf ); break; + case TStreamerInfo::kBits: return TConfiguredAction( Looper::template ConvertCollectionBasicType<From,UInt_t>::Action, conf ); break; + default: + break; } + R__ASSERT(0); // We should never be here + return TConfiguredAction(); +} - template <Int_t (*action)(TBuffer&,void *,const TConfiguration*)> - Int_t GenericLooper(TBuffer &buf, void *start, const void *end, const TLoopConfiguration *loopconf, const TConfiguration *config) - { - TGenericLoopConfig *loopconfig = (TGenericLoopConfig*)loopconf; - - // const Int_t offset = config->fOffset; - Next_t next = loopconfig->fNext; - - char iterator[TVirtualCollectionProxy::fgIteratorArenaSize]; - void *iter = loopconfig->fCopyIterator(&iterator,start); - void *addr; - while( (addr = next(iter,end)) ) { - action(buf, addr, config); - } - if (iter != &iterator[0]) { - loopconfig->fDeleteIterator(iter); - } - return 0; +template <typename Looper> +static TConfiguredAction GetConvertCollectionReadAction(Int_t oldtype, Int_t newtype, TConfiguration *conf) +{ + switch (oldtype) { + case TStreamerInfo::kBool: + return GetConvertCollectionReadActionFrom<Looper,Bool_t>(newtype, conf ); + break; + case TStreamerInfo::kChar: + return GetConvertCollectionReadActionFrom<Looper,Char_t>(newtype, conf ); + break; + case TStreamerInfo::kShort: + return GetConvertCollectionReadActionFrom<Looper,Short_t>(newtype, conf ); + break; + case TStreamerInfo::kInt: + return GetConvertCollectionReadActionFrom<Looper,Int_t>(newtype, conf ); + break; + case TStreamerInfo::kLong: + return GetConvertCollectionReadActionFrom<Looper,Long_t>(newtype, conf ); + break; + case TStreamerInfo::kLong64: + return GetConvertCollectionReadActionFrom<Looper,Long64_t>(newtype, conf ); + break; + case TStreamerInfo::kFloat: + return GetConvertCollectionReadActionFrom<Looper,Float_t>( newtype, conf ); + break; + case TStreamerInfo::kDouble: + return GetConvertCollectionReadActionFrom<Looper,Double_t>(newtype, conf ); + break; + case TStreamerInfo::kUChar: + return GetConvertCollectionReadActionFrom<Looper,UChar_t>(newtype, conf ); + break; + case TStreamerInfo::kUShort: + return GetConvertCollectionReadActionFrom<Looper,UShort_t>(newtype, conf ); + break; + case TStreamerInfo::kUInt: + return GetConvertCollectionReadActionFrom<Looper,UInt_t>(newtype, conf ); + break; + case TStreamerInfo::kULong: + return GetConvertCollectionReadActionFrom<Looper,ULong_t>(newtype, conf ); + break; + case TStreamerInfo::kULong64: + return GetConvertCollectionReadActionFrom<Looper,ULong64_t>(newtype, conf ); + break; + case TStreamerInfo::kFloat16: + return GetConvertCollectionReadActionFrom<Looper,NoFactorMarker<Float16_t> >( newtype, conf ); + break; + case TStreamerInfo::kDouble32: + return GetConvertCollectionReadActionFrom<Looper,NoFactorMarker<Double32_t> >( newtype, conf ); + break; + case TStreamerInfo::kBits: + Error("GetConvertCollectionReadAction","There is no support for kBits outside of a TObject."); + break; + default: + break; } - + R__ASSERT(0); // We should never be here + return TConfiguredAction(); } -static TConfiguredAction GetVectorReadAction(TVirtualStreamerInfo *info, TStreamerElement *element, Int_t type, UInt_t i, Int_t offset) +template <class Looper> +static TConfiguredAction GetCollectionReadAction(TVirtualStreamerInfo *info, TStreamerElement *element, Int_t type, UInt_t i, Int_t offset) { switch (type) { - // read basic types - case TStreamerInfo::kBool: return TConfiguredAction( ReadBasicTypeVectorLoop<Bool_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kChar: return TConfiguredAction( ReadBasicTypeVectorLoop<Char_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kShort: return TConfiguredAction( ReadBasicTypeVectorLoop<Short_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kInt: return TConfiguredAction( ReadBasicTypeVectorLoop<Int_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kLong: return TConfiguredAction( ReadBasicTypeVectorLoop<Long_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kLong64: return TConfiguredAction( ReadBasicTypeVectorLoop<Long64_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kFloat: return TConfiguredAction( ReadBasicTypeVectorLoop<Float_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kDouble: return TConfiguredAction( ReadBasicTypeVectorLoop<Double_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kUChar: return TConfiguredAction( ReadBasicTypeVectorLoop<UChar_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kUShort: return TConfiguredAction( ReadBasicTypeVectorLoop<UShort_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kUInt: return TConfiguredAction( ReadBasicTypeVectorLoop<UInt_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kULong: return TConfiguredAction( ReadBasicTypeVectorLoop<ULong_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kULong64: return TConfiguredAction( ReadBasicTypeVectorLoop<ULong64_t>, new TConfiguration(info,i,offset) ); break; + // Read basic types. + case TStreamerInfo::kBool: return TConfiguredAction( Looper::template ReadBasicType<Bool_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kChar: return TConfiguredAction( Looper::template ReadBasicType<Char_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kShort: return TConfiguredAction( Looper::template ReadBasicType<Short_t>,new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kInt: return TConfiguredAction( Looper::template ReadBasicType<Int_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kLong: return TConfiguredAction( Looper::template ReadBasicType<Long_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kLong64: return TConfiguredAction( Looper::template ReadBasicType<Long64_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kFloat: return TConfiguredAction( Looper::template ReadBasicType<Float_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kDouble: return TConfiguredAction( Looper::template ReadBasicType<Double_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kUChar: return TConfiguredAction( Looper::template ReadBasicType<UChar_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kUShort: return TConfiguredAction( Looper::template ReadBasicType<UShort_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kUInt: return TConfiguredAction( Looper::template ReadBasicType<UInt_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kULong: return TConfiguredAction( Looper::template ReadBasicType<ULong_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kULong64: return TConfiguredAction( Looper::template ReadBasicType<ULong64_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kBits: return TConfiguredAction( Looper::template ReadAction<TStreamerInfoActions::ReadBasicType<BitsMarker> > , new TBitsConfiguration(info,i,offset) ); break; case TStreamerInfo::kFloat16: { if (element->GetFactor() != 0) { - return TConfiguredAction( VectorLooper<ReadBasicType_WithFactor<float> >, new TConfWithFactor(info,i,offset,element->GetFactor(),element->GetXmin()) ); + return TConfiguredAction( Looper::template ReadAction<ReadBasicType_WithFactor<float> >, new TConfWithFactor(info,i,offset,element->GetFactor(),element->GetXmin()) ); } else { Int_t nbits = (Int_t)element->GetXmin(); if (!nbits) nbits = 12; - return TConfiguredAction( VectorLooper<ReadBasicType_NoFactor<float> >, new TConfNoFactor(info,i,offset,nbits) ); + return TConfiguredAction( Looper::template ReadAction<ReadBasicType_NoFactor<float> >, new TConfNoFactor(info,i,offset,nbits) ); } break; } case TStreamerInfo::kDouble32: { if (element->GetFactor() != 0) { - return TConfiguredAction( VectorLooper<ReadBasicType_WithFactor<double> >, new TConfWithFactor(info,i,offset,element->GetFactor(),element->GetXmin()) ); + return TConfiguredAction( Looper::template ReadAction<ReadBasicType_WithFactor<double> >, new TConfWithFactor(info,i,offset,element->GetFactor(),element->GetXmin()) ); } else { Int_t nbits = (Int_t)element->GetXmin(); if (!nbits) { - return TConfiguredAction( VectorLooper<ConvertBasicType<float,double> >, new TConfiguration(info,i,offset) ); + return TConfiguredAction( Looper::template ReadAction<ConvertBasicType<float,double>::Action >, new TConfiguration(info,i,offset) ); } else { - return TConfiguredAction( VectorLooper<ReadBasicType_NoFactor<double> >, new TConfNoFactor(info,i,offset,nbits) ); + return TConfiguredAction( Looper::template ReadAction<ReadBasicType_NoFactor<double> >, new TConfNoFactor(info,i,offset,nbits) ); } } break; } - case TStreamerInfo::kTNamed: return TConfiguredAction( VectorLooper<ReadTNamed >, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kTNamed: return TConfiguredAction( Looper::template ReadAction<ReadTNamed >, new TConfiguration(info,i,offset) ); break; // Idea: We should calculate the CanIgnoreTObjectStreamer here and avoid calling the // Streamer alltogether. - case TStreamerInfo::kTObject: return TConfiguredAction( VectorLooper<ReadTObject >, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kTString: return TConfiguredAction( VectorLooper<ReadTString >, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kTObject: return TConfiguredAction( Looper::template ReadAction<ReadTObject >, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kTString: return TConfiguredAction( Looper::template ReadAction<ReadTString >, new TConfiguration(info,i,offset) ); break; case TStreamerInfo::kArtificial: case TStreamerInfo::kCacheNew: case TStreamerInfo::kCacheDelete: - case TStreamerInfo::kSTL: return TConfiguredAction( ReadVectorWrapping, new TConfiguration(info,i,0 /* 0 because we call the legacy code */) ); break; - case TStreamerInfo::kBase: return TConfiguredAction( ReadVectorBase, new TConfiguration(info,i,0 /* 0 because we call the legacy code */) ); break; + case TStreamerInfo::kSTL: return TConfiguredAction( Looper::GenericRead, new TGenericConfiguration(info,i) ); break; + case TStreamerInfo::kBase: return TConfiguredAction( Looper::ReadBase, new TGenericConfiguration(info,i) ); break; + + // Conversions. + case TStreamerInfo::kConv + TStreamerInfo::kBool: + return GetCollectionReadConvertAction<Looper,Bool_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kChar: + return GetCollectionReadConvertAction<Looper,Char_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kShort: + return GetCollectionReadConvertAction<Looper,Short_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kInt: + return GetCollectionReadConvertAction<Looper,Int_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kLong: + return GetCollectionReadConvertAction<Looper,Long_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kLong64: + return GetCollectionReadConvertAction<Looper,Long64_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kFloat: + return GetCollectionReadConvertAction<Looper,Float_t>( element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kDouble: + return GetCollectionReadConvertAction<Looper,Double_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kUChar: + return GetCollectionReadConvertAction<Looper,UChar_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kUShort: + return GetCollectionReadConvertAction<Looper,UShort_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kUInt: + return GetCollectionReadConvertAction<Looper,UInt_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kULong: + return GetCollectionReadConvertAction<Looper,ULong_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kULong64: + return GetCollectionReadConvertAction<Looper,ULong64_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kBits: + return GetCollectionReadConvertAction<Looper,BitsMarker>(element->GetNewType(), new TBitsConfiguration(info,i,offset) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kFloat16: { + if (element->GetFactor() != 0) { + return GetCollectionReadConvertAction<Looper,WithFactorMarker<float> >(element->GetNewType(), new TConfWithFactor(info,i,offset,element->GetFactor(),element->GetXmin()) ); + } else { + Int_t nbits = (Int_t)element->GetXmin(); + if (!nbits) nbits = 12; + return GetCollectionReadConvertAction<Looper,NoFactorMarker<float> >(element->GetNewType(), new TConfNoFactor(info,i,offset,nbits) ); + } + break; + } + case TStreamerInfo::kConv + TStreamerInfo::kDouble32: { + if (element->GetFactor() != 0) { + return GetCollectionReadConvertAction<Looper,WithFactorMarker<double> >(element->GetNewType(), new TConfWithFactor(info,i,offset,element->GetFactor(),element->GetXmin()) ); + } else { + Int_t nbits = (Int_t)element->GetXmin(); + if (!nbits) { + return GetCollectionReadConvertAction<Looper,Float_t>(element->GetNewType(), new TConfiguration(info,i,offset) ); + } else { + return GetCollectionReadConvertAction<Looper,NoFactorMarker<double> >(element->GetNewType(), new TConfNoFactor(info,i,offset,nbits) ); + } + } + break; + } default: - return TConfiguredAction( ReadVectorWrapping, new TConfiguration(info,i,0 /* 0 because we call the legacy code */) ); - // return TConfiguredAction( GenericVectorAction, new TConfigSTL(info,i,0 /* the offset will be used from TStreamerInfo */,0,proxy->GetCollectionClass(),0,0) ); + return TConfiguredAction( Looper::GenericRead, new TGenericConfiguration(info,i) ); break; } R__ASSERT(0); // We should never be here return TConfiguredAction(); } -static TConfiguredAction GetVectorWriteAction(TVirtualStreamerInfo *info, TStreamerElement * /*element*/, Int_t type, UInt_t i, Int_t offset) { - switch (type) { - // read basic types - case TStreamerInfo::kBool: return TConfiguredAction( WriteBasicTypeVectorLoop<Bool_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kChar: return TConfiguredAction( WriteBasicTypeVectorLoop<Char_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kShort: return TConfiguredAction( WriteBasicTypeVectorLoop<Short_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kInt: return TConfiguredAction( WriteBasicTypeVectorLoop<Int_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kLong: return TConfiguredAction( WriteBasicTypeVectorLoop<Long_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kLong64: return TConfiguredAction( WriteBasicTypeVectorLoop<Long64_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kFloat: return TConfiguredAction( WriteBasicTypeVectorLoop<Float_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kDouble: return TConfiguredAction( WriteBasicTypeVectorLoop<Double_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kUChar: return TConfiguredAction( WriteBasicTypeVectorLoop<UChar_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kUShort: return TConfiguredAction( WriteBasicTypeVectorLoop<UShort_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kUInt: return TConfiguredAction( WriteBasicTypeVectorLoop<UInt_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kULong: return TConfiguredAction( WriteBasicTypeVectorLoop<ULong_t>, new TConfiguration(info,i,offset) ); break; - case TStreamerInfo::kULong64: return TConfiguredAction( WriteBasicTypeVectorLoop<ULong64_t>, new TConfiguration(info,i,offset) ); break; - default: - return TConfiguredAction( WriteVectorWrapping, new TConfiguration(info,i,0 /* 0 because we call the legacy code */) ); - } - R__ASSERT(0); // We should never be here - return TConfiguredAction(); +template <class Looper> +static TConfiguredAction GetCollectionWriteAction(TVirtualStreamerInfo *info, TStreamerElement * /*element*/, Int_t type, UInt_t i, Int_t offset) { + switch (type) { + // read basic types + case TStreamerInfo::kBool: return TConfiguredAction( Looper::template WriteBasicType<Bool_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kChar: return TConfiguredAction( Looper::template WriteBasicType<Char_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kShort: return TConfiguredAction( Looper::template WriteBasicType<Short_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kInt: return TConfiguredAction( Looper::template WriteBasicType<Int_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kLong: return TConfiguredAction( Looper::template WriteBasicType<Long_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kLong64: return TConfiguredAction( Looper::template WriteBasicType<Long64_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kFloat: return TConfiguredAction( Looper::template WriteBasicType<Float_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kDouble: return TConfiguredAction( Looper::template WriteBasicType<Double_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kUChar: return TConfiguredAction( Looper::template WriteBasicType<UChar_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kUShort: return TConfiguredAction( Looper::template WriteBasicType<UShort_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kUInt: return TConfiguredAction( Looper::template WriteBasicType<UInt_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kULong: return TConfiguredAction( Looper::template WriteBasicType<ULong_t>, new TConfiguration(info,i,offset) ); break; + case TStreamerInfo::kULong64: return TConfiguredAction( Looper::template WriteBasicType<ULong64_t>,new TConfiguration(info,i,offset) ); break; + // the simple type missing are kBits and kCounter. + default: + return TConfiguredAction( Looper::GenericWrite, new TConfiguration(info,i,0 /* 0 because we call the legacy code */) ); + } + R__ASSERT(0); // We should never be here + return TConfiguredAction(); } + //______________________________________________________________________________ void TStreamerInfo::Compile() { @@ -1230,7 +2352,10 @@ void TStreamerInfo::Compile() // Make sure the StreamerInfo for the base class is also // not optimized. TClass *bclass = element->GetClassPointer(); - Int_t clversion = ((TStreamerBase*)element)->GetBaseVersion(); + Int_t clversion = 0; + if (element->IsA() == TStreamerBase::Class()) { + clversion = ((TStreamerBase*)element)->GetBaseVersion(); + } TStreamerInfo *binfo = ((TStreamerInfo*)bclass->GetStreamerInfo(clversion)); if (binfo) { // binfo might be null in cases where: @@ -1348,11 +2473,36 @@ void TStreamerInfo::Compile() } } +template <typename From> +static void AddReadConvertAction(TStreamerInfoActions::TActionSequence *sequence, Int_t newtype, TConfiguration *conf) +{ + switch (newtype) { + case TStreamerInfo::kBool: sequence->AddAction( ConvertBasicType<From,bool>::Action, conf ); break; + case TStreamerInfo::kChar: sequence->AddAction( ConvertBasicType<From,char>::Action, conf ); break; + case TStreamerInfo::kShort: sequence->AddAction( ConvertBasicType<From,short>::Action, conf ); break; + case TStreamerInfo::kInt: sequence->AddAction( ConvertBasicType<From,Int_t>::Action, conf ); break; + case TStreamerInfo::kLong: sequence->AddAction( ConvertBasicType<From,Long_t>::Action,conf ); break; + case TStreamerInfo::kLong64: sequence->AddAction( ConvertBasicType<From,Long64_t>::Action, conf ); break; + case TStreamerInfo::kFloat: sequence->AddAction( ConvertBasicType<From,float>::Action, conf ); break; + case TStreamerInfo::kFloat16: sequence->AddAction( ConvertBasicType<From,float>::Action, conf ); break; + case TStreamerInfo::kDouble: sequence->AddAction( ConvertBasicType<From,double>::Action, conf ); break; + case TStreamerInfo::kDouble32:sequence->AddAction( ConvertBasicType<From,double>::Action, conf ); break; + case TStreamerInfo::kUChar: sequence->AddAction( ConvertBasicType<From,UChar_t>::Action, conf ); break; + case TStreamerInfo::kUShort: sequence->AddAction( ConvertBasicType<From,UShort_t>::Action, conf ); break; + case TStreamerInfo::kUInt: sequence->AddAction( ConvertBasicType<From,UInt_t>::Action, conf ); break; + case TStreamerInfo::kULong: sequence->AddAction( ConvertBasicType<From,ULong_t>::Action, conf ); break; + case TStreamerInfo::kULong64: sequence->AddAction( ConvertBasicType<From,ULong64_t>::Action,conf ); break; + case TStreamerInfo::kBits: sequence->AddAction( ConvertBasicType<From,UInt_t>::Action, conf ); break; + } +} + //______________________________________________________________________________ void TStreamerInfo::AddReadAction(Int_t i, TStreamerElement* element) { // Add a read action for the given element. + if (element->TestBit(TStreamerElement::kWrite)) return; + switch (fType[i]) { // read basic types case TStreamerInfo::kBool: fReadObjectWise->AddAction( ReadBasicType<Bool_t>, new TConfiguration(this,i,fOffset[i]) ); break; @@ -1368,6 +2518,7 @@ void TStreamerInfo::AddReadAction(Int_t i, TStreamerElement* element) case TStreamerInfo::kUInt: fReadObjectWise->AddAction( ReadBasicType<UInt_t>, new TConfiguration(this,i,fOffset[i]) ); break; case TStreamerInfo::kULong: fReadObjectWise->AddAction( ReadBasicType<ULong_t>, new TConfiguration(this,i,fOffset[i]) ); break; case TStreamerInfo::kULong64: fReadObjectWise->AddAction( ReadBasicType<ULong64_t>, new TConfiguration(this,i,fOffset[i]) ); break; + case TStreamerInfo::kBits: fReadObjectWise->AddAction( ReadBasicType<BitsMarker>, new TBitsConfiguration(this,i,fOffset[i]) ); break; case TStreamerInfo::kFloat16: { if (element->GetFactor() != 0) { fReadObjectWise->AddAction( ReadBasicType_WithFactor<float>, new TConfWithFactor(this,i,fOffset[i],element->GetFactor(),element->GetXmin()) ); @@ -1384,7 +2535,7 @@ void TStreamerInfo::AddReadAction(Int_t i, TStreamerElement* element) } else { Int_t nbits = (Int_t)element->GetXmin(); if (!nbits) { - fReadObjectWise->AddAction( ConvertBasicType<float,double>, new TConfiguration(this,i,fOffset[i]) ); + fReadObjectWise->AddAction( ConvertBasicType<float,double>::Action, new TConfiguration(this,i,fOffset[i]) ); } else { fReadObjectWise->AddAction( ReadBasicType_NoFactor<double>, new TConfNoFactor(this,i,fOffset[i],nbits) ); } @@ -1421,15 +2572,49 @@ void TStreamerInfo::AddReadAction(Int_t i, TStreamerElement* element) if (element->GetStreamer()) { fReadObjectWise->AddAction(ReadSTL<ReadSTLMemberWiseChangedClass,ReadSTLObjectWiseStreamer>, new TConfigSTL(this,i,fOffset[i],1,oldClass,newClass,element->GetStreamer(),element->GetTypeName(),isSTLbase)); } else { - fReadObjectWise->AddAction(ReadSTL<ReadSTLMemberWiseChangedClass,ReadSTLObjectWiseFastArray>, new TConfigSTL(this,i,fOffset[i],1,oldClass,newClass,element->GetTypeName(),isSTLbase)); + if (oldClass->GetCollectionProxy() == 0 || oldClass->GetCollectionProxy()->GetValueClass() || oldClass->GetCollectionProxy()->HasPointers() ) { + fReadObjectWise->AddAction(ReadSTL<ReadSTLMemberWiseChangedClass,ReadSTLObjectWiseFastArray>, new TConfigSTL(this,i,fOffset[i],1,oldClass,newClass,element->GetTypeName(),isSTLbase)); + } else { + switch (SelectLooper(*newClass->GetCollectionProxy())) { + case kVectorLooper: + fReadObjectWise->AddAction(GetConvertCollectionReadAction<VectorLooper>(oldClass->GetCollectionProxy()->GetType(), newClass->GetCollectionProxy()->GetType(), new TConfigSTL(this,i,fOffset[i],1,oldClass,newClass,element->GetTypeName(),isSTLbase))); + break; + case kAssociativeLooper: + fReadObjectWise->AddAction(GetConvertCollectionReadAction<AssociativeLooper>(oldClass->GetCollectionProxy()->GetType(), newClass->GetCollectionProxy()->GetType(), new TConfigSTL(this,i,fOffset[i],1,oldClass,newClass,element->GetTypeName(),isSTLbase))); + break; + case kVectorPtrLooper: + case kGenericLooper: + default: + // For now TBufferXML would force use to allocate the data buffer each time and copy into the real thing. + fReadObjectWise->AddAction(GetConvertCollectionReadAction<GenericLooper>(oldClass->GetCollectionProxy()->GetType(), newClass->GetCollectionProxy()->GetType(), new TConfigSTL(this,i,fOffset[i],1,oldClass,newClass,element->GetTypeName(),isSTLbase))); + break; + } + } } } else { if (element->GetStreamer()) { fReadObjectWise->AddAction(ReadSTL<ReadSTLMemberWiseSameClass,ReadSTLObjectWiseStreamer>, new TConfigSTL(this,i,fOffset[i],1,oldClass,element->GetStreamer(),element->GetTypeName(),isSTLbase)); } else { - fReadObjectWise->AddAction(ReadSTL<ReadSTLMemberWiseSameClass,ReadSTLObjectWiseFastArray>, new TConfigSTL(this,i,fOffset[i],1,oldClass,element->GetTypeName(),isSTLbase)); + if (oldClass->GetCollectionProxy() == 0 || oldClass->GetCollectionProxy()->GetValueClass() || oldClass->GetCollectionProxy()->HasPointers() ) { + fReadObjectWise->AddAction(ReadSTL<ReadSTLMemberWiseSameClass,ReadSTLObjectWiseFastArray>, new TConfigSTL(this,i,fOffset[i],1,oldClass,element->GetTypeName(),isSTLbase)); + } else { + switch (SelectLooper(*oldClass->GetCollectionProxy())) { + case kVectorLooper: + fReadObjectWise->AddAction(GetNumericCollectionReadAction<VectorLooper>(oldClass->GetCollectionProxy()->GetType(), new TConfigSTL(this,i,fOffset[i],1,oldClass,element->GetTypeName(),isSTLbase))); + break; + case kAssociativeLooper: + fReadObjectWise->AddAction(GetNumericCollectionReadAction<AssociativeLooper>(oldClass->GetCollectionProxy()->GetType(), new TConfigSTL(this,i,fOffset[i],1,oldClass,element->GetTypeName(),isSTLbase))); + break; + case kVectorPtrLooper: + case kGenericLooper: + default: + // For now TBufferXML would force use to allocate the data buffer each time and copy into the real thing. + fReadObjectWise->AddAction(GetNumericCollectionReadAction<GenericLooper>(oldClass->GetCollectionProxy()->GetType(), new TConfigSTL(this,i,fOffset[i],1,oldClass,element->GetTypeName(),isSTLbase))); + break; + } + } } - } + } } } else { if (fOldVersion<3){ // case of old TStreamerInfo @@ -1464,6 +2649,72 @@ void TStreamerInfo::AddReadAction(Int_t i, TStreamerElement* element) } break; } + + case TStreamerInfo::kConv + TStreamerInfo::kBool: + AddReadConvertAction<Bool_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kChar: + AddReadConvertAction<Char_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kShort: + AddReadConvertAction<Short_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kInt: + AddReadConvertAction<Int_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kLong: + AddReadConvertAction<Long_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kLong64: + AddReadConvertAction<Long64_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kFloat: + AddReadConvertAction<Float_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kDouble: + AddReadConvertAction<Double_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kUChar: + AddReadConvertAction<UChar_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kUShort: + AddReadConvertAction<UShort_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kUInt: + AddReadConvertAction<UInt_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kULong: + AddReadConvertAction<ULong_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kULong64: + AddReadConvertAction<ULong64_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kBits: + AddReadConvertAction<BitsMarker>(fReadObjectWise, fNewType[i], new TBitsConfiguration(this,i,fOffset[i]) ); + break; + case TStreamerInfo::kConv + TStreamerInfo::kFloat16: { + if (element->GetFactor() != 0) { + AddReadConvertAction<WithFactorMarker<float> >(fReadObjectWise, fNewType[i], new TConfWithFactor(this,i,fOffset[i],element->GetFactor(),element->GetXmin()) ); + } else { + Int_t nbits = (Int_t)element->GetXmin(); + if (!nbits) nbits = 12; + AddReadConvertAction<NoFactorMarker<float> >(fReadObjectWise, fNewType[i], new TConfNoFactor(this,i,fOffset[i],nbits) ); + } + break; + } + case TStreamerInfo::kConv + TStreamerInfo::kDouble32: { + if (element->GetFactor() != 0) { + AddReadConvertAction<WithFactorMarker<double> >(fReadObjectWise, fNewType[i], new TConfWithFactor(this,i,fOffset[i],element->GetFactor(),element->GetXmin()) ); + } else { + Int_t nbits = (Int_t)element->GetXmin(); + if (!nbits) { + AddReadConvertAction<Float_t>(fReadObjectWise, fNewType[i], new TConfiguration(this,i,fOffset[i]) ); + } else { + AddReadConvertAction<NoFactorMarker<double> >(fReadObjectWise, fNewType[i], new TConfNoFactor(this,i,fOffset[i],nbits) ); + } + } + break; + } default: fReadObjectWise->AddAction( GenericReadAction, new TGenericConfiguration(this,i) ); break; @@ -1475,65 +2726,27 @@ void TStreamerInfo::AddReadAction(Int_t i, TStreamerElement* element) } if (fReadMemberWise) { // This is for streaming via a TClonesArray (or a vector of pointers of this type). - + if (element->TestBit(TStreamerElement::kCache)) { - TConfiguredAction action( GetVectorReadAction(this,element,fType[i],i,fOffset[i]) ); + TConfiguredAction action( GetCollectionReadAction<VectorLooper>(this,element,fType[i],i,fOffset[i]) ); fReadMemberWise->AddAction( UseCacheVectorPtrLoop, new TConfigurationUseCache(this,action,element->TestBit(TStreamerElement::kRepeat)) ); } else { - switch (fType[i]) { - // read basic types - case TStreamerInfo::kBool: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<Bool_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kChar: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<Char_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kShort: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<Short_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kInt: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<Int_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kLong: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<Long_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kLong64: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<Long64_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kFloat: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<Float_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kDouble: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<Double_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kUChar: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<UChar_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kUShort: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<UShort_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kUInt: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<UInt_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kULong: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<ULong_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kULong64: fReadMemberWise->AddAction( ReadBasicTypeVectorPtrLoop<ULong64_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kFloat16: { - if (element->GetFactor() != 0) { - fReadMemberWise->AddAction( VectorPtrLooper<ReadBasicType_WithFactor<float> >, new TConfWithFactor(this,i,fOffset[i],element->GetFactor(),element->GetXmin()) ); - } else { - Int_t nbits = (Int_t)element->GetXmin(); - if (!nbits) nbits = 12; - fReadMemberWise->AddAction( VectorPtrLooper<ReadBasicType_NoFactor<float> >, new TConfNoFactor(this,i,fOffset[i],nbits) ); - } - break; - } - case TStreamerInfo::kDouble32: { - if (element->GetFactor() != 0) { - fReadMemberWise->AddAction( VectorPtrLooper<ReadBasicType_WithFactor<double> >, new TConfWithFactor(this,i,fOffset[i],element->GetFactor(),element->GetXmin()) ); - } else { - Int_t nbits = (Int_t)element->GetXmin(); - if (!nbits) { - fReadMemberWise->AddAction( VectorPtrLooper<ConvertBasicType<float,double> >, new TConfiguration(this,i,fOffset[i]) ); - } else { - fReadMemberWise->AddAction( VectorPtrLooper<ReadBasicType_NoFactor<double> >, new TConfNoFactor(this,i,fOffset[i],nbits) ); - } - } - break; - } - case TStreamerInfo::kTNamed: fReadMemberWise->AddAction( VectorPtrLooper<ReadTNamed >, new TConfiguration(this,i,fOffset[i]) ); break; - // Idea: We should calculate the CanIgnoreTObjectStreamer here and avoid calling the - // Streamer alltogether. - case TStreamerInfo::kTObject: fReadMemberWise->AddAction( VectorPtrLooper<ReadTObject >, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kTString: fReadMemberWise->AddAction( VectorPtrLooper<ReadTString >, new TConfiguration(this,i,fOffset[i]) ); break; - default: - fReadMemberWise->AddAction( GenericVectorPtrReadAction, new TGenericConfiguration(this,i) ); - break; - } + fReadMemberWise->AddAction( GetCollectionReadAction<VectorPtrLooper>(this,element,fType[i],i,fOffset[i]) ); } } } //______________________________________________________________________________ -void TStreamerInfo::AddWriteAction(Int_t i, TStreamerElement* /*element*/ ) +void TStreamerInfo::AddWriteAction(Int_t i, TStreamerElement *element ) { + if (element->TestBit(TStreamerElement::kCache) && !element->TestBit(TStreamerElement::kWrite)) { + // Skip element cached for reading purposes. + return; + } + if (element->GetType() >= kArtificial && !element->TestBit(TStreamerElement::kWrite)) { + // Skip artificial element used for reading purposes. + return; + } switch (fType[i]) { // write basic types case TStreamerInfo::kBool: fWriteObjectWise->AddAction( WriteBasicType<Bool_t>, new TConfiguration(this,i,fOffset[i]) ); break; @@ -1549,7 +2762,8 @@ void TStreamerInfo::AddWriteAction(Int_t i, TStreamerElement* /*element*/ ) case TStreamerInfo::kUInt: fWriteObjectWise->AddAction( WriteBasicType<UInt_t>, new TConfiguration(this,i,fOffset[i]) ); break; case TStreamerInfo::kULong: fWriteObjectWise->AddAction( WriteBasicType<ULong_t>, new TConfiguration(this,i,fOffset[i]) ); break; case TStreamerInfo::kULong64: fWriteObjectWise->AddAction( WriteBasicType<ULong64_t>, new TConfiguration(this,i,fOffset[i]) ); break; - /*case TStreamerInfo::kFloat16: { + // case TStreamerInfo::kBits: fWriteObjectWise->AddAction( WriteBasicType<BitsMarker>, new TConfiguration(this,i,fOffset[i]) ); break; + /*case TStreamerInfo::kFloat16: { if (element->GetFactor() != 0) { fWriteObjectWise->AddAction( WriteBasicType_WithFactor<float>, new TConfWithFactor(this,i,fOffset[i],element->GetFactor(),element->GetXmin()) ); } else { @@ -1629,59 +2843,13 @@ void TStreamerInfo::AddWriteAction(Int_t i, TStreamerElement* /*element*/ ) #if defined(CDJ_NO_COMPILE) if (element->TestBit(TStreamerElement::kCache)) { - TConfiguredAction action( GetVectorWriteAction(this,element,fType[i],i,fOffset[i]) ); + TConfiguredAction action( GetCollectionWriteAction<VectorLooper>(this,element,fType[i],i,fOffset[i]) ); fWriteMemberWise->AddAction( UseCacheVectorPtrLoop, new TConfigurationUseCache(this,action,element->TestBit(TStreamerElement::kRepeat)) ); } else { - switch (fType[i]) { - // read basic types - case TStreamerInfo::kBool: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<Bool_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kChar: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<Char_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kShort: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<Short_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kInt: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<Int_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kLong: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<Long_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kLong64: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<Long64_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kFloat: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<Float_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kDouble: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<Double_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kUChar: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<UChar_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kUShort: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<UShort_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kUInt: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<UInt_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kULong: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<ULong_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kULong64: fWriteMemberWise->AddAction( WriteBasicTypeVectorPtrLoop<ULong64_t>, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kFloat16: { - if (element->GetFactor() != 0) { - fWriteMemberWise->AddAction( VectorPtrLooper<WriteBasicType_WithFactor<float> >, new TConfWithFactor(this,i,fOffset[i],element->GetFactor(),element->GetXmin()) ); - } else { - Int_t nbits = (Int_t)element->GetXmin(); - if (!nbits) nbits = 12; - fWriteMemberWise->AddAction( VectorPtrLooper<WriteBasicType_NoFactor<float> >, new TConfNoFactor(this,i,fOffset[i],nbits) ); - } - break; - } - case TStreamerInfo::kDouble32: { - if (element->GetFactor() != 0) { - fWriteMemberWise->AddAction( VectorPtrLooper<WriteBasicType_WithFactor<double> >, new TConfWithFactor(this,i,fOffset[i],element->GetFactor(),element->GetXmin()) ); - } else { - Int_t nbits = (Int_t)element->GetXmin(); - if (!nbits) { - fWriteMemberWise->AddAction( VectorPtrLooper<ConvertBasicType<float,double> >, new TConfiguration(this,i,fOffset[i]) ); - } else { - fWriteMemberWise->AddAction( VectorPtrLooper<WriteBasicType_NoFactor<double> >, new TConfNoFactor(this,i,fOffset[i],nbits) ); - } - } - break; - } - case TStreamerInfo::kTNamed: fWriteMemberWise->AddAction( VectorPtrLooper<WriteTNamed >, new TConfiguration(this,i,fOffset[i]) ); break; - // Idea: We should calculate the CanIgnoreTObjectStreamer here and avoid calling the - // Streamer alltogether. - case TStreamerInfo::kTObject: fWriteMemberWise->AddAction( VectorPtrLooper<WriteTObject >, new TConfiguration(this,i,fOffset[i]) ); break; - case TStreamerInfo::kTString: fWriteMemberWise->AddAction( VectorPtrLooper<WriteTString >, new TConfiguration(this,i,fOffset[i]) ); break; - default: - fWriteMemberWise->AddAction( GenericVectorPtrWriteAction, new TGenericConfiguration(this,i) ); - break; - } + fWriteMemberWise->Addaction( GetCollectionWriteAction<VectorPtrLooper>(this,element,fType[i],i,fOffset[i]) ); } #else - fWriteMemberWise->AddAction( GenericVectorPtrWriteAction, new TGenericConfiguration(this,i) ); + fWriteMemberWise->AddAction( VectorPtrLooper::GenericWrite, new TGenericConfiguration(this,i) ); #endif } } @@ -1738,6 +2906,10 @@ TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::Cr // when it is making branches for a split object. continue; } + if (element->TestBit(TStreamerElement::kWrite)) { + // Skip element that only for writing. + continue; + } Int_t asize = element->GetSize(); if (element->GetArrayLength()) { asize /= element->GetArrayLength(); @@ -1755,76 +2927,31 @@ TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::Cr oldType += TVirtualStreamerInfo::kSkip; } } - if ( (proxy.GetCollectionType() == TClassEdit::kVector) || (proxy.GetProperties() & TVirtualCollectionProxy::kIsEmulated) - || (proxy.GetCollectionType() == TClassEdit::kSet || proxy.GetCollectionType() == TClassEdit::kMultiSet - || proxy.GetCollectionType() == TClassEdit::kMap || proxy.GetCollectionType() == TClassEdit::kMultiMap) ) - { - + switch (SelectLooper(proxy)) { + case kAssociativeLooper: +// } else if (proxy.GetCollectionType() == TClassEdit::kSet || proxy.GetCollectionType() == TClassEdit::kMultiSet +// || proxy.GetCollectionType() == TClassEdit::kMap || proxy.GetCollectionType() == TClassEdit::kMultiMap) { +// sequence->AddAction( GenericAssocCollectionAction, new TConfigSTL(info,i,offset,0,proxy.GetCollectionClass(),0,0) ); + case kVectorLooper: + case kVectorPtrLooper: // We can speed up the iteration in case of vector. We also know that all emulated collection are stored internally as a vector. if (element->TestBit(TStreamerElement::kCache)) { - TConfiguredAction action( GetVectorReadAction(info,element,oldType,i,offset) ); + TConfiguredAction action( GetCollectionReadAction<VectorLooper>(info,element,oldType,i,offset) ); sequence->AddAction( UseCacheVectorLoop, new TConfigurationUseCache(info,action,element->TestBit(TStreamerElement::kRepeat)) ); - } else { - sequence->AddAction(GetVectorReadAction(info,element,oldType,i,offset)); + } else { + sequence->AddAction( GetCollectionReadAction<VectorLooper>(info,element,oldType,i,offset)); } - -// } else if (proxy.GetCollectionType() == TClassEdit::kSet || proxy.GetCollectionType() == TClassEdit::kMultiSet -// || proxy.GetCollectionType() == TClassEdit::kMap || proxy.GetCollectionType() == TClassEdit::kMultiMap) { -// sequence->AddAction( GenericAssocCollectionAction, new TConfigSTL(info,i,offset,0,proxy.GetCollectionClass(),0,0) ); - } else { + break; + case kGenericLooper: + default: // The usual collection case. if (element->TestBit(TStreamerElement::kCache)) { - TConfiguredAction action( GetVectorReadAction(info,element,oldType,i,offset) ); + TConfiguredAction action( GetCollectionReadAction<VectorLooper>(info,element,oldType,i,offset) ); sequence->AddAction( UseCacheGenericCollection, new TConfigurationUseCache(info,action,element->TestBit(TStreamerElement::kRepeat)) ); } else { - switch (oldType) { - // read basic types - case TVirtualStreamerInfo::kBool: sequence->AddAction( ReadBasicTypeGenericLoop<Bool_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kChar: sequence->AddAction( ReadBasicTypeGenericLoop<Char_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kShort: sequence->AddAction( ReadBasicTypeGenericLoop<Short_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kInt: sequence->AddAction( ReadBasicTypeGenericLoop<Int_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kLong: sequence->AddAction( ReadBasicTypeGenericLoop<Long_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kLong64: sequence->AddAction( ReadBasicTypeGenericLoop<Long64_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kFloat: sequence->AddAction( ReadBasicTypeGenericLoop<Float_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kDouble: sequence->AddAction( ReadBasicTypeGenericLoop<Double_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kUChar: sequence->AddAction( ReadBasicTypeGenericLoop<UChar_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kUShort: sequence->AddAction( ReadBasicTypeGenericLoop<UShort_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kUInt: sequence->AddAction( ReadBasicTypeGenericLoop<UInt_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kULong: sequence->AddAction( ReadBasicTypeGenericLoop<ULong_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kULong64: sequence->AddAction( ReadBasicTypeGenericLoop<ULong64_t>, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kFloat16: { - if (element->GetFactor() != 0) { - sequence->AddAction( GenericLooper<ReadBasicType_WithFactor<float> >, new TConfWithFactor(info,i,offset,element->GetFactor(),element->GetXmin()) ); - } else { - Int_t nbits = (Int_t)element->GetXmin(); - if (!nbits) nbits = 12; - sequence->AddAction( GenericLooper<ReadBasicType_NoFactor<float> >, new TConfNoFactor(info,i,offset,nbits) ); - } - break; - } - case TVirtualStreamerInfo::kDouble32: { - if (element->GetFactor() != 0) { - sequence->AddAction( GenericLooper<ReadBasicType_WithFactor<double> >, new TConfWithFactor(info,i,offset,element->GetFactor(),element->GetXmin()) ); - } else { - Int_t nbits = (Int_t)element->GetXmin(); - if (!nbits) { - sequence->AddAction( GenericLooper<ConvertBasicType<float,double> >, new TConfiguration(info,i,offset) ); - } else { - sequence->AddAction( GenericLooper<ReadBasicType_NoFactor<double> >, new TConfNoFactor(info,i,offset,nbits) ); - } - } - break; - } - case TVirtualStreamerInfo::kTNamed: sequence->AddAction( GenericLooper<ReadTNamed >, new TConfiguration(info,i,offset) ); break; - // Idea: We should calculate the CanIgnoreTObjectStreamer here and avoid calling the - // Streamer alltogether. - case TVirtualStreamerInfo::kTObject: sequence->AddAction( GenericLooper<ReadTObject >, new TConfiguration(info,i,offset) ); break; - case TVirtualStreamerInfo::kTString: sequence->AddAction( GenericLooper<ReadTString >, new TConfiguration(info,i,offset) ); break; - default: - sequence->AddAction( GenericCollectionReadAction, new TConfigSTL(info,i,0 /* the offset will be used from TStreamerInfo */,0,proxy.GetCollectionClass(),0,0) ); - break; - } + sequence->AddAction( GetCollectionReadAction<GenericLooper>(info,element,oldType,i,offset) ); } + break; } } return sequence; @@ -1882,6 +3009,14 @@ TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::Cr // when it is making branches for a split object. continue; } + if (element->TestBit(TStreamerElement::kCache) && !element->TestBit(TStreamerElement::kWrite)) { + // Skip element cached for reading purposes. + continue; + } + if (element->GetType() >= TVirtualStreamerInfo::kArtificial && !element->TestBit(TStreamerElement::kWrite)) { + // Skip artificial element used for reading purposes. + continue; + } Int_t asize = element->GetSize(); if (element->GetArrayLength()) { asize /= element->GetArrayLength(); @@ -1907,10 +3042,10 @@ TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::Cr // We can speed up the iteration in case of vector. We also know that all emulated collection are stored internally as a vector. if (element->TestBit(TStreamerElement::kCache)) { - TConfiguredAction action( GetVectorWriteAction(info,element,oldType,i,offset) ); + TConfiguredAction action( GetCollectionWriteAction<VectorLooper>(info,element,oldType,i,offset) ); sequence->AddAction( UseCacheVectorLoop, new TConfigurationUseCache(info,action,element->TestBit(TStreamerElement::kRepeat)) ); } else { - sequence->AddAction(GetVectorWriteAction(info,element,oldType,i,offset)); + sequence->AddAction(GetCollectionWriteAction<VectorLooper>(info,element,oldType,i,offset)); } // } else if (proxy.GetCollectionType() == TClassEdit::kSet || proxy.GetCollectionType() == TClassEdit::kMultiSet @@ -1919,7 +3054,7 @@ TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::Cr } else { // The usual collection case. if (element->TestBit(TStreamerElement::kCache)) { - TConfiguredAction action( GetVectorWriteAction(info,element,oldType,i,offset) ); + TConfiguredAction action( GetWriteAction<VectorLooper>(info,element,oldType,i,offset) ); sequence->AddAction( UseCacheGenericCollection, new TConfigurationUseCache(info,action,element->TestBit(TStreamerElement::kRepeat)) ); } else { switch (oldType) { @@ -1937,6 +3072,7 @@ TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::Cr case TVirtualStreamerInfo::kUInt: sequence->AddAction( WriteBasicTypeGenericLoop<UInt_t>, new TConfiguration(info,i,offset) ); break; case TVirtualStreamerInfo::kULong: sequence->AddAction( WriteBasicTypeGenericLoop<ULong_t>, new TConfiguration(info,i,offset) ); break; case TVirtualStreamerInfo::kULong64: sequence->AddAction( WriteBasicTypeGenericLoop<ULong64_t>, new TConfiguration(info,i,offset) ); break; + // case TVirtualStreamerInfo::kBits: sequence->AddAction( WriteBasicTypeGenericLoop<BitsMarker>, new TConfiguration(info,i,offset) ); break; case TVirtualStreamerInfo::kFloat16: { if (element->GetFactor() != 0) { sequence->AddAction( GenericLooper<WriteBasicType_WithFactor<float> >, new TConfWithFactor(info,i,offset,element->GetFactor(),element->GetXmin()) ); @@ -1976,9 +3112,13 @@ TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::Cr /*|| (proxy.GetCollectionType() == TClassEdit::kSet || proxy.GetCollectionType() == TClassEdit::kMultiSet || proxy.GetCollectionType() == TClassEdit::kMap || proxy.GetCollectionType() == TClassEdit::kMultiMap)*/ ) { - sequence->AddAction(GetVectorWriteAction(info,element,oldType,i,offset)); + sequence->AddAction( GetCollectionWriteAction<VectorLooper>(info,element,oldType,i,offset) ); } else { - sequence->AddAction( GenericCollectionWriteAction, new TConfigSTL(info,i,0 /* the offset will be used from TStreamerInfo */,0,proxy.GetCollectionClass(),0,0) ); + // NOTE: TBranch::FillLeavesCollection[Member] is not yet ready to handle the sequence + // as it does not create/use a TStaging as expected ... but then again it might + // not be the right things to expect ... + // sequence->AddAction( GetCollectionWriteAction<GenericLooper>(info,element,oldType,i,offset) ); + sequence->AddAction( GenericLooper::GenericWrite, new TConfigSTL(info,i,0 /* the offset will be used from TStreamerInfo */,0,proxy.GetCollectionClass(),0,0) ); } #endif } @@ -1987,14 +3127,15 @@ TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::Cr void TStreamerInfoActions::TActionSequence::AddToOffset(Int_t delta) { // Add the (potentially negative) delta to all the configuration's offset. This is used by - // TTBranchElement in the case of split sub-object. + // TBranchElement in the case of split sub-object. TStreamerInfoActions::ActionContainer_t::iterator end = fActions.end(); for(TStreamerInfoActions::ActionContainer_t::iterator iter = fActions.begin(); iter != end; ++iter) { - iter->fConfiguration->AddToOffset(delta); + if (!iter->fConfiguration->fInfo->GetElements()->At(iter->fConfiguration->fElemId)->TestBit(TStreamerElement::kCache)) + iter->fConfiguration->AddToOffset(delta); } } @@ -2020,7 +3161,7 @@ TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::Cr TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::CreateSubSequence(const std::vector<Int_t> &element_ids, size_t offset) { // Create a sequence containing the subset of the action corresponding to the SteamerElement whose ids is contained in the vector. - // 'offset' is the location of this 'class' within the object (address) that will be pass to ReadBuffer when using this sequence. + // 'offset' is the location of this 'class' within the object (address) that will be passed to ReadBuffer when using this sequence. TStreamerInfoActions::TActionSequence *sequence = new TStreamerInfoActions::TActionSequence(fStreamerInfo,element_ids.size()); @@ -2034,7 +3175,8 @@ TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::Cr ++iter) { TConfiguration *conf = iter->fConfiguration->Copy(); - conf->AddToOffset(offset); + if (!iter->fConfiguration->fInfo->GetElements()->At(iter->fConfiguration->fElemId)->TestBit(TStreamerElement::kCache)) + conf->AddToOffset(offset); sequence->AddAction( iter->fAction, conf ); } } else { @@ -2044,7 +3186,8 @@ TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::Cr ++iter) { if ( iter->fConfiguration->fElemId == (UInt_t)element_ids[id] ) { TConfiguration *conf = iter->fConfiguration->Copy(); - conf->AddToOffset(offset); + if (!iter->fConfiguration->fInfo->GetElements()->At(iter->fConfiguration->fElemId)->TestBit(TStreamerElement::kCache)) + conf->AddToOffset(offset); sequence->AddAction( iter->fAction, conf ); } } @@ -2052,11 +3195,51 @@ TStreamerInfoActions::TActionSequence *TStreamerInfoActions::TActionSequence::Cr } return sequence; } + +#if !defined(R__WIN32) && !defined(_AIX) + +#include <dlfcn.h> + +#endif + +typedef void (*voidfunc)(); +static const char *R__GetSymbolName(voidfunc func) +{ +#if defined(R__WIN32) || defined(__CYGWIN__) || defined(_AIX) + return "not available on this platform"; +#if 0 + MEMORY_BASIC_INFORMATION mbi; + if (!VirtualQuery (func, &mbi, sizeof (mbi))) + { + return 0; + } + + HMODULE hMod = (HMODULE) mbi.AllocationBase; + static char moduleName[MAX_PATH]; + + if (!GetModuleFileNameA (hMod, moduleName, sizeof (moduleName))) + { + return 0; + } + return moduleName; +#endif +#else + Dl_info info; + if (dladdr((void*)func,&info)==0) { + // Not in a known share library, let's give up + return "name not found"; + } else { + //fprintf(stdout,"Found address in %s\n",info.dli_fname); + return info.dli_sname; + } +#endif +} -void TStreamerInfoActions::TActionSequence::Print(Option_t *) const +void TStreamerInfoActions::TActionSequence::Print(Option_t *opt) const { // Add the (potentially negative) delta to all the configuration's offset. This is used by // TTBranchElement in the case of split sub-object. + // If opt contains 'func', also print the (mangled) name of the function that will be executed. if (fLoopConfig) { fLoopConfig->Print(); @@ -2067,6 +3250,9 @@ void TStreamerInfoActions::TActionSequence::Print(Option_t *) const ++iter) { iter->fConfiguration->Print(); + if (strstr(opt,"func")) { + printf("StreamerInfoAction func: %s\n",R__GetSymbolName((voidfunc)iter->fAction)); + } } } diff --git a/io/io/src/TStreamerInfoReadBuffer.cxx b/io/io/src/TStreamerInfoReadBuffer.cxx index 7cd1e100b6193..bf9aa7424ad1c 100644 --- a/io/io/src/TStreamerInfoReadBuffer.cxx +++ b/io/io/src/TStreamerInfoReadBuffer.cxx @@ -398,7 +398,7 @@ Int_t TStreamerInfo::ReadBufferSkip(TBuffer &b, const T &arr, Int_t i, Int_t kas break; \ } -#define ConvCBasicArray(name,ReadArrayFunc) \ +#define ConvCBasicArray(name,ReadArrayFunc) \ { \ int j, len = fLength[i]; \ name* readbuf = new name[len]; \ @@ -816,6 +816,8 @@ Int_t TStreamerInfo::ReadBuffer(TBuffer &b, const T &arr, Int_t first, TStreamerElement * aElement = (TStreamerElement*)fElem[i]; fgElement = aElement; + if (aElement->TestBit(TStreamerElement::kWrite)) continue; + if (R__TestUseCache<T>(aElement)) { Int_t bufpos = b.Length(); if (((TBufferFile&)b).PeekDataCache()==0) { diff --git a/io/rfio/src/TRFIOFile.cxx b/io/rfio/src/TRFIOFile.cxx index c606ca1193f5e..aedbd650e3a0c 100644 --- a/io/rfio/src/TRFIOFile.cxx +++ b/io/rfio/src/TRFIOFile.cxx @@ -282,6 +282,7 @@ Bool_t TRFIOFile::ReadBuffers(char *buf, Long64_t *pos, Int_t *len, Int_t nbuf) } fBytesRead += k; + fReadCalls++; #ifdef WIN32 SetFileBytesRead(GetFileBytesRead() + k); SetFileReadCalls(GetFileReadCalls() + 1); @@ -543,7 +544,7 @@ Bool_t TRFIOSystem::AccessPathName(const char *path, EAccessMode mode) //______________________________________________________________________________ Int_t TRFIOSystem::Unlink(const char *path) { - // Unlink, i.e. remove, a file or directory. Returns 0 when succesfull, + // Unlink, i.e. remove, a file or directory. Returns 0 when successful, // -1 in case of failure. TUrl url(path); diff --git a/io/sql/inc/TBufferSQL2.h b/io/sql/inc/TBufferSQL2.h index 5a1507f54899a..e65a99b4d74ed 100644 --- a/io/sql/inc/TBufferSQL2.h +++ b/io/sql/inc/TBufferSQL2.h @@ -225,6 +225,10 @@ friend class TSQLStructure; virtual void ReadFastArray(Double_t *d, Int_t n); virtual void ReadFastArrayFloat16(Float_t *f, Int_t n, TStreamerElement *ele=0); virtual void ReadFastArrayDouble32(Double_t *d, Int_t n, TStreamerElement *ele=0); + virtual void ReadFastArrayWithFactor(Float_t *ptr, Int_t n, Double_t factor, Double_t minvalue) ; + virtual void ReadFastArrayWithNbits(Float_t *ptr, Int_t n, Int_t nbits); + virtual void ReadFastArrayWithFactor(Double_t *ptr, Int_t n, Double_t factor, Double_t minvalue); + virtual void ReadFastArrayWithNbits(Double_t *ptr, Int_t n, Int_t nbits) ; virtual void WriteArray(const Bool_t *b, Int_t n); virtual void WriteArray(const Char_t *c, Int_t n); diff --git a/io/sql/src/TBufferSQL2.cxx b/io/sql/src/TBufferSQL2.cxx index b4b79a724265b..9c5bfa6d93f38 100644 --- a/io/sql/src/TBufferSQL2.cxx +++ b/io/sql/src/TBufferSQL2.cxx @@ -1543,6 +1543,22 @@ void TBufferSQL2::ReadFastArrayFloat16(Float_t *f, Int_t n, TStreamerElement * TBufferSQL2_ReadFastArray(f); } +//______________________________________________________________________________ +void TBufferSQL2::ReadFastArrayWithFactor(Float_t *f, Int_t n, Double_t /* factor */, Double_t /* minvalue */) +{ + // read array of Float16_t from buffer + + TBufferSQL2_ReadFastArray(f); +} + +//______________________________________________________________________________ +void TBufferSQL2::ReadFastArrayWithNbits(Float_t *f, Int_t n, Int_t /*nbits*/) +{ + // read array of Float16_t from buffer + + TBufferSQL2_ReadFastArray(f); +} + //______________________________________________________________________________ void TBufferSQL2::ReadFastArrayDouble32(Double_t *d, Int_t n, TStreamerElement * /*ele*/) { @@ -1551,6 +1567,21 @@ void TBufferSQL2::ReadFastArrayDouble32(Double_t *d, Int_t n, TStreamerElement TBufferSQL2_ReadFastArray(d); } +//______________________________________________________________________________ +void TBufferSQL2::ReadFastArrayWithFactor(Double_t *d, Int_t n, Double_t /* factor */, Double_t /* minvalue */) +{ + // read array of Double32_t from buffer + + TBufferSQL2_ReadFastArray(d); +} +//______________________________________________________________________________ +void TBufferSQL2::ReadFastArrayWithNbits(Double_t *d, Int_t n, Int_t /*nbits*/) +{ + // read array of Double32_t from buffer + + TBufferSQL2_ReadFastArray(d); +} + //______________________________________________________________________________ void TBufferSQL2::ReadFastArray(void *start, const TClass *cl, Int_t n, TMemberStreamer *streamer, const TClass* onFileClass ) { diff --git a/io/sql/src/TSQLFile.cxx b/io/sql/src/TSQLFile.cxx index 19ab66bba54a3..8a02e7e0c052e 100644 --- a/io/sql/src/TSQLFile.cxx +++ b/io/sql/src/TSQLFile.cxx @@ -589,7 +589,7 @@ Bool_t TSQLFile::StartTransaction() { // Start user transaction. // This can be usesfull, when big number of objects should be stored in - // data base and commitment required only if all operations were succesfull. + // data base and commitment required only if all operations were successful. // In that case in the end of all operations method Commit() should be // called. If operation on user-level is looks like not successfull, // method Rollback() will return database data and TSQLFile instance to @@ -935,7 +935,7 @@ Int_t TSQLFile::StreamKeysForDirectory(TDirectory* dir, Bool_t doupdate, Long64_ { // read keys for specified directory (when update == kFALSE) // or update value for modified keys when update == kTRUE - // Returns number of succesfully read keys or -1 if error + // Returns number of successfully read keys or -1 if error if (dir==0) return -1; diff --git a/io/sql/src/TSQLStructure.cxx b/io/sql/src/TSQLStructure.cxx index 239d4c51f55c3..962f594538aa1 100644 --- a/io/sql/src/TSQLStructure.cxx +++ b/io/sql/src/TSQLStructure.cxx @@ -1730,7 +1730,7 @@ Bool_t TSQLStructure::StoreElementInNormalForm(TSqlRegistry* reg, TSQLTableData* } if (columntyp==kColSimpleArray) { - // number of items should be exactly equal to number of childs + // number of items should be exactly equal to number of children if (NumChilds()!=1) { Error("StoreElementInNormalForm","In fixed array %s only array node should be", elem->GetName()); diff --git a/io/xml/inc/TBufferXML.h b/io/xml/inc/TBufferXML.h index 917474ee74376..25ef96850fb5b 100644 --- a/io/xml/inc/TBufferXML.h +++ b/io/xml/inc/TBufferXML.h @@ -1,4 +1,4 @@ -// @(#)root/xml:$Id$ +// @(#)root/xml:$Id: d90d66e8fd2aa9daa4b05bcba9166aee1e2b2e7f $ // Author: Sergey Linev 10.05.2004 /************************************************************************* @@ -49,8 +49,8 @@ friend class TKeyXML; TBufferXML(TBuffer::EMode mode, TXMLFile* file); virtual ~TBufferXML(); - static TString ConvertToXML(TObject* obj, Bool_t GenericLayout = kFALSE, Bool_t UseNamespaces = kFALSE); - static TString ConvertToXML(void* obj, TClass* cl, Bool_t GenericLayout = kFALSE, Bool_t UseNamespaces = kFALSE); + static TString ConvertToXML(const TObject* obj, Bool_t GenericLayout = kFALSE, Bool_t UseNamespaces = kFALSE); + static TString ConvertToXML(const void* obj, const TClass* cl, Bool_t GenericLayout = kFALSE, Bool_t UseNamespaces = kFALSE); static TObject* ConvertFromXML(const char* str, Bool_t GenericLayout = kFALSE, Bool_t UseNamespaces = kFALSE); static void* ConvertFromXMLAny(const char* str, TClass** cl = 0, Bool_t GenericLayout = kFALSE, Bool_t UseNamespaces = kFALSE); @@ -139,6 +139,10 @@ friend class TKeyXML; virtual void ReadFastArray(Double_t *d, Int_t n); virtual void ReadFastArrayFloat16(Float_t *f, Int_t n, TStreamerElement *ele=0); virtual void ReadFastArrayDouble32(Double_t *d, Int_t n, TStreamerElement *ele=0); + virtual void ReadFastArrayWithFactor(Float_t *ptr, Int_t n, Double_t factor, Double_t minvalue) ; + virtual void ReadFastArrayWithNbits(Float_t *ptr, Int_t n, Int_t nbits); + virtual void ReadFastArrayWithFactor(Double_t *ptr, Int_t n, Double_t factor, Double_t minvalue); + virtual void ReadFastArrayWithNbits(Double_t *ptr, Int_t n, Int_t nbits) ; virtual void WriteArray(const Bool_t *b, Int_t n); virtual void WriteArray(const Char_t *c, Int_t n); diff --git a/io/xml/src/TBufferXML.cxx b/io/xml/src/TBufferXML.cxx index 8e6c677802285..cff24f2e22802 100644 --- a/io/xml/src/TBufferXML.cxx +++ b/io/xml/src/TBufferXML.cxx @@ -1,4 +1,4 @@ -// @(#)root/:$Id$ +// @(#)root/:$Id: 5400e36954e1dc109fcfc306242c30234beb7312 $ // Author: Sergey Linev, Rene Brun 10.05.2004 /************************************************************************* @@ -156,7 +156,7 @@ TXMLFile* TBufferXML::XmlFile() } //______________________________________________________________________________ -TString TBufferXML::ConvertToXML(TObject* obj, Bool_t GenericLayout, Bool_t UseNamespaces) +TString TBufferXML::ConvertToXML(const TObject* obj, Bool_t GenericLayout, Bool_t UseNamespaces) { // converts object, inherited from TObject class, to XML string // fmt contains configuration of XML layout. See TXMLSetup class for detatils @@ -165,7 +165,7 @@ TString TBufferXML::ConvertToXML(TObject* obj, Bool_t GenericLayout, Bool_t UseN } //______________________________________________________________________________ -TString TBufferXML::ConvertToXML(void* obj, TClass* cl, Bool_t GenericLayout, Bool_t UseNamespaces) +TString TBufferXML::ConvertToXML(const void* obj, const TClass* cl, Bool_t GenericLayout, Bool_t UseNamespaces) { // converts any type of object to XML string // fmt contains configuration of XML layout. See TXMLSetup class for detatils @@ -2064,6 +2064,22 @@ void TBufferXML::ReadFastArrayFloat16(Float_t *f, Int_t n, TStreamerElement * / TBufferXML_ReadFastArray(f); } +//______________________________________________________________________________ +void TBufferXML::ReadFastArrayWithFactor(Float_t *f, Int_t n, Double_t /* factor */, Double_t /* minvalue */) +{ + // read array of Float16_t from buffer + + TBufferXML_ReadFastArray(f); +} + +//______________________________________________________________________________ +void TBufferXML::ReadFastArrayWithNbits(Float_t *f, Int_t n, Int_t /*nbits*/) +{ + // read array of Float16_t from buffer + + TBufferXML_ReadFastArray(f); +} + //______________________________________________________________________________ void TBufferXML::ReadFastArrayDouble32(Double_t *d, Int_t n, TStreamerElement * /*ele*/) { @@ -2072,6 +2088,22 @@ void TBufferXML::ReadFastArrayDouble32(Double_t *d, Int_t n, TStreamerElement * TBufferXML_ReadFastArray(d); } +//______________________________________________________________________________ +void TBufferXML::ReadFastArrayWithFactor(Double_t *d, Int_t n, Double_t /* factor */, Double_t /* minvalue */) +{ + // read array of Double32_t from buffer + + TBufferXML_ReadFastArray(d); +} + +//______________________________________________________________________________ +void TBufferXML::ReadFastArrayWithNbits(Double_t *d, Int_t n, Int_t /*nbits*/) +{ + // read array of Double32_t from buffer + + TBufferXML_ReadFastArray(d); +} + //______________________________________________________________________________ void TBufferXML::ReadFastArray(void *start, const TClass *cl, Int_t n, TMemberStreamer *s, const TClass *onFileClass) { diff --git a/io/xml/src/TXMLEngine.cxx b/io/xml/src/TXMLEngine.cxx index 577eb6ecaf5e0..d878f0aaf0524 100644 --- a/io/xml/src/TXMLEngine.cxx +++ b/io/xml/src/TXMLEngine.cxx @@ -1,4 +1,4 @@ -// @(#)root/xml:$Id$ +// @(#)root/xml:$Id: 1bd040ac1c03c58bcad15b5206d602680a831c0a $ // Author: Sergey Linev 10.05.2004 /************************************************************************* @@ -36,7 +36,7 @@ struct SXmlAttr_t { }; enum EXmlNodeType { - kXML_NODE = 1, // normal node with childs + kXML_NODE = 1, // normal node with children kXML_COMMENT = 2, // comment (stored as value of node fName) kXML_PI_NODE = 3, // processing instructions node (like <?name attr="" ?> kXML_RAWLINE = 4 // just one line of xml code @@ -98,6 +98,7 @@ class TXMLOutputStream { { if (fCurrent!=fBuf) OutputCurrent(); delete fOut; + free(fBuf); } void OutputCurrent() @@ -273,14 +274,14 @@ class TXMLInputStream { Bool_t SkipSpaces(Bool_t tillendl = kFALSE) { - do { + while (fCurrent<fMaxAddr) { char symb = *fCurrent; if ((symb>26) && (symb!=' ')) return kTRUE; if (!ShiftCurrent()) return kFALSE; if (tillendl && (symb==10)) return kTRUE; - } while (fCurrent<fMaxAddr); + } return kFALSE; } @@ -959,7 +960,7 @@ void TXMLEngine::SkipEmpty(XMLNodePointer_t &xmlnode) //______________________________________________________________________________ void TXMLEngine::CleanNode(XMLNodePointer_t xmlnode) { - // remove all childs node from xmlnode + // remove all children node from xmlnode if (xmlnode==0) return; SXmlNode_t* node = (SXmlNode_t*) xmlnode; @@ -1483,7 +1484,7 @@ XMLNodePointer_t TXMLEngine::ReadNode(XMLNodePointer_t xmlparent, TXMLInputStrea if (*inp->fCurrent!='<') { // here should be reading of element content - // only one entry for content is supported, only before any other childs + // only one entry for content is supported, only before any other children if ((parent==0) || (parent->fChild!=0)) { resvalue = -2; return 0; } int contlen = inp->LocateContent(); if (contlen<0) return 0; @@ -1529,14 +1530,14 @@ XMLNodePointer_t TXMLEngine::ReadNode(XMLNodePointer_t xmlparent, TXMLInputStrea } EXmlNodeType nodetype = kXML_NODE; - Bool_t canhaschilds = true; + Bool_t canhaschildren = true; char endsymbol = '/'; // this is case of processing instructions node if (*inp->fCurrent=='?') { if (!inp->ShiftCurrent()) return 0; nodetype = kXML_PI_NODE; - canhaschilds = false; + canhaschildren = false; endsymbol = '?'; } @@ -1578,8 +1579,8 @@ XMLNodePointer_t TXMLEngine::ReadNode(XMLNodePointer_t xmlparent, TXMLInputStrea return node; } else return 0; } else - if (nextsymb=='>') { // this is end of parent node, lets find all childs - if (!canhaschilds) { resvalue = -11; return 0; } + if (nextsymb=='>') { // this is end of parent node, lets find all children + if (!canhaschildren) { resvalue = -11; return 0; } if (!inp->ShiftCurrent()) return 0; diff --git a/io/xml/src/TXMLFile.cxx b/io/xml/src/TXMLFile.cxx index 7853bc0af545b..c6d85738bc844 100644 --- a/io/xml/src/TXMLFile.cxx +++ b/io/xml/src/TXMLFile.cxx @@ -928,7 +928,7 @@ void TXMLFile::SetStoreStreamerInfos(Bool_t iConvert) void TXMLFile::SetUsedDtd(Bool_t use) { // Specify usage of DTD for this file. - // Currently this option not avaliable (always false). + // Currently this option not available (always false). // Can be changed only for newly created file. if (IsWritable() && (GetListOfKeys()->GetSize()==0)) diff --git a/io/xml/src/TXMLPlayer.cxx b/io/xml/src/TXMLPlayer.cxx index be2d8cf431b3e..40baaec09eaa9 100644 --- a/io/xml/src/TXMLPlayer.cxx +++ b/io/xml/src/TXMLPlayer.cxx @@ -13,7 +13,7 @@ // // Class for xml code generation // It should be used for generation of xml steramers, which could be used outside root -// enviroment. This means, that with help of such streamers user can read and write +// environment. This means, that with help of such streamers user can read and write // objects from/to xml file, which later can be accepted by ROOT. // // At the moment supported only classes, which are not inherited from TObject diff --git a/io/xmlparser/src/TXMLParser.cxx b/io/xmlparser/src/TXMLParser.cxx index fa8da3611e484..dbc1043842271 100644 --- a/io/xmlparser/src/TXMLParser.cxx +++ b/io/xmlparser/src/TXMLParser.cxx @@ -164,7 +164,7 @@ void TXMLParser::StopParser() void TXMLParser::SetParseCode(Int_t errorcode) { // Set the parse code: - // 0: Parse succesfull + // 0: Parse successful // -1: Attempt to parse a second file while a parse is in progress // -2: Parse context is not created // -3: An error occured while parsing file diff --git a/main/CMakeLists.txt b/main/CMakeLists.txt index 3090b9ebb4bfa..88b7497f913db 100644 --- a/main/CMakeLists.txt +++ b/main/CMakeLists.txt @@ -18,6 +18,6 @@ ROOT_EXECUTABLE(hadd hadd.cxx LIBRARIES Core Cint RIO Net Hist Graf Graf3d Gpad if(CMAKE_Fortran_COMPILER) ROOT_EXECUTABLE(g2root g2root.f LIBRARIES minicern) - #ROOT_EXECUTABLE(h2root h2root.cxx LIBRARIES Core Cint RIO Net Hist Graf Graf3d Gpad Tree Matrix MathCore Thread minicern) + ROOT_EXECUTABLE(h2root h2root.cxx LIBRARIES Core Cint RIO Net Hist Graf Graf3d Gpad Tree Matrix MathCore Thread minicern) endif() diff --git a/main/Module.mk b/main/Module.mk index c6cbccecc57e0..1204433ec067b 100644 --- a/main/Module.mk +++ b/main/Module.mk @@ -45,6 +45,20 @@ PROOFSERVEXE := PROOFSERVSH := endif +##### xpdtest ##### +XPDTESTS := $(MODDIRS)/xpdtest.cxx +XPDTESTO := $(call stripsrc,$(XPDTESTS:.cxx=.o)) +XPDTESTDEP := $(XPDTESTO:.o=.d) +ifneq ($(PLATFORM),win32) +XPDTESTEXE := bin/xpdtest +endif +ifeq ($(PROOFLIB),) +XPDTESTEXE := +endif +XPDTESTLIBS := -lProof -lTree -lHist -lRIO -lNet -lThread -lMatrix -lMathCore +XPDTESTLIBSDEP = $(IOLIB) $(TREELIB) $(NETLIB) $(HISTLIB) $(PROOFLIB) \ + $(THREADLIB) $(MATRIXLIB) $(MATHCORELIB) + ##### roots.exe ##### ROOTSEXES := $(MODDIRS)/roots.cxx ROOTSEXEO := $(call stripsrc,$(ROOTSEXES:.cxx=.o)) @@ -98,14 +112,14 @@ endif # used in the main Makefile ALLEXECS += $(ROOTEXE) $(ROOTNEXE) $(PROOFSERVEXE) $(PROOFSERVSH) \ - $(HADD) $(SSH2RPD) $(ROOTSEXE) $(ROOTSSH) + $(XPDTESTEXE) $(HADD) $(SSH2RPD) $(ROOTSEXE) $(ROOTSSH) ifneq ($(F77),) ALLEXECS += $(H2ROOT) $(G2ROOT) endif # include all dependency files -INCLUDEFILES += $(ROOTEXEDEP) $(PROOFSERVDEP) $(HADDDEP) $(H2ROOTDEP) \ - $(SSH2RPDDEP) $(ROOTSEXEDEP) +INCLUDEFILES += $(ROOTEXEDEP) $(PROOFSERVDEP) $(XPDTESTDEP) $(HADDDEP) \ + $(H2ROOTDEP) $(SSH2RPDDEP) $(ROOTSEXEDEP) ##### local rules ##### .PHONY: all-$(MODNAME) clean-$(MODNAME) distclean-$(MODNAME) @@ -129,6 +143,10 @@ $(PROOFSERVSH): $(call stripsrc,$(MAINDIRS)/proofserv.sh) @cp $< $@ @chmod 0755 $@ +$(XPDTESTEXE): $(XPDTESTO) $(BOOTLIBSDEP) $(XPDTESTLIBSDEP) + $(LD) $(LDFLAGS) -o $@ $(XPDTESTO) \ + $(RPATH) $(BOOTLIBS) $(XPDTESTLIBS) $(SYSLIBS) + $(ROOTSEXE): $(ROOTSEXEO) $(BOOTLIBSDEP) $(LD) $(LDFLAGS) -o $@ $(ROOTSEXEO) \ $(RPATH) $(BOOTLIBS) $(SYSLIBS) @@ -158,23 +176,23 @@ $(G2ROOT): $(G2ROOTO) $(ORDER_) $(MINICERNLIB) ifneq ($(F77),) all-$(MODNAME): $(ROOTEXE) $(ROOTNEXE) $(PROOFSERVEXE) $(PROOFSERVSH) \ - $(HADD) $(SSH2RPD) $(H2ROOT) $(G2ROOT) \ + $(XPDTESTEXE) $(HADD) $(SSH2RPD) $(H2ROOT) $(G2ROOT) \ $(ROOTSEXE) $(ROOTSSH) else all-$(MODNAME): $(ROOTEXE) $(ROOTNEXE) $(PROOFSERVEXE) $(PROOFSERVSH) \ - $(HADD) $(SSH2RPD) $(ROOTSEXE) $(ROOTSSH) + $(XPDTESTEXE) $(HADD) $(SSH2RPD) $(ROOTSEXE) $(ROOTSSH) endif clean-$(MODNAME): - @rm -f $(ROOTEXEO) $(PROOFSERVO) $(HADDO) $(H2ROOTO) \ - $(G2ROOTO) $(SSH2RPDO) $(ROOTSEXEO) + @rm -f $(ROOTEXEO) $(PROOFSERVO) $(XPDTESTO) $(HADDO) \ + $(H2ROOTO) $(G2ROOTO) $(SSH2RPDO) $(ROOTSEXEO) clean:: clean-$(MODNAME) distclean-$(MODNAME): clean-$(MODNAME) @rm -f $(ROOTEXEDEP) $(ROOTEXE) $(ROOTNEXE) $(PROOFSERVDEP) \ - $(PROOFSERVEXE) $(PROOFSERVSH) $(HADDDEP) $(HADD) \ - $(H2ROOTDEP) $(H2ROOT) $(G2ROOT) \ + $(PROOFSERVEXE) $(PROOFSERVSH) $(XPDTESTDEP) $(XPDTESTEXE) \ + $(HADDDEP) $(HADD) $(H2ROOTDEP) $(H2ROOT) $(G2ROOT) \ $(SSH2RPDDEP) $(SSH2RPD) $(ROOTSEXEDEP) $(ROOTSEXE) \ $(ROOTSSH) diff --git a/main/src/h2root.cxx b/main/src/h2root.cxx index bf3c8f33af15a..c8a9b7b696d0a 100644 --- a/main/src/h2root.cxx +++ b/main/src/h2root.cxx @@ -521,7 +521,7 @@ void convert_2d(Int_t id) Int_t lw = lq[lcont]; if (lw) h2->Sumw2(); - Float_t x,y; + Float_t x = 0.0, y = 0.0; for (Int_t j=0;j<=ncy+1;j++) { for (Int_t i=0;i<=ncx+1;i++) { hijxy(id,i,j,x,y); diff --git a/main/src/hadd.cxx b/main/src/hadd.cxx index a6b8862372ccf..3eaaa296cd3bd 100644 --- a/main/src/hadd.cxx +++ b/main/src/hadd.cxx @@ -71,6 +71,8 @@ #include <stdlib.h> #include "TFileMerger.h" +#include "TROOT.h" +#include "TInterpreter.h" //___________________________________________________________________________ int main( int argc, char **argv ) @@ -169,7 +171,10 @@ int main( int argc, char **argv ) } gSystem->Load("libTreePlayer"); - + TClass::GetClass("ROOT::Cintex::Cintex"); // autoload Cintex if it exist. + if (gInterpreter->IsLoaded("libCintex")) { + gROOT->ProcessLine("ROOT::Cintex::Cintex::Enable();"); + } const char *targetname = 0; if (outputPlace) { targetname = argv[outputPlace]; @@ -203,8 +208,7 @@ int main( int argc, char **argv ) } while( indirect_file ){ std::string line; - std::getline(indirect_file, line); - if( !merger.AddFile(line.c_str()) ) { + if( std::getline(indirect_file, line) && line.length() && !merger.AddFile(line.c_str()) ) { return 1; } } diff --git a/main/src/xpdtest.cxx b/main/src/xpdtest.cxx new file mode 100644 index 0000000000000..779aa9b864b86 --- /dev/null +++ b/main/src/xpdtest.cxx @@ -0,0 +1,637 @@ +// @(#)root/main:$Id$ +// Author: G. Ganis 2012 + +/************************************************************************* + * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////// +// // +// xpdtest // +// // +// Program used to test existence and status of a proof daemon // +// // +////////////////////////////////////////////////////////////////////////// +#include <stdio.h> +#include <errno.h> + +#include <sys/time.h> +#include <sys/resource.h> +#include <stdlib.h> +#include <sys/types.h> +#include <sys/socket.h> +#include <netinet/in.h> +#include <arpa/inet.h> +#include <netdb.h> +#include <signal.h> + +#include "Riostream.h" +#include "TSystem.h" +#include "TProof.h" +#include "TString.h" + +//______________________________________________________________________________ +// Prototypes +int xpd_ping(const char *host, int port); +int getsocket(struct hostent *h, int); +void printhelp(); +int recvn(int sock, void *buffer, int length); +int sendn(int sock, const void *buffer, int length); +int proof_open(const char *master, long to = 10); +int parse_args(int argc, char **argv, + TString &url, TString &sboxdir, time_t &span, int &test, + TString &logfile, bool &keep, bool &verbose, long &to, + TString &pidfile); +void printhelp(); +int set_timer(bool on = 1, long to = 10); + +//______________________________________________________________________________ +// The client request structure +typedef struct { + int first; + int second; + int third; + int fourth; + int fifth; +} clnt_HS_t; + +//______________________________________________________________________________ +// The body received after the first handshake's header +typedef struct { + int msglen; + int protover; + int msgval; +} srv_HS_t; + +//______________________________________________________________________________ +int main(int argc, char **argv) +{ + // PROOF daemon test program. + // Syntax + // xpdtest <url> <sandbox_dir> <time_span> + // + // <url> URL to test; default 'localhost:1093' + // <sandbox_dir> directory with users sandboxes; used to find out + // users to check connection; default '/tmp/proofbox' + // <time_span> check only users whose latest activity was within + // 'time_span' minutes; use -1 to check all users; + // default -1. + // + // Exits 0 on success, 1 on error + + TString url, sboxdir, logfile, pidfile; + time_t span = -1; + int test = 0; + bool keep = 0, verbose = 0; + long timeout = -1; + int rc = parse_args(argc, argv, url, sboxdir, span, test, logfile, keep, + verbose, timeout, pidfile); + if (rc < 0) { + fprintf(stderr, "xpdtest: parse_args failure\n"); + gSystem->Exit(1); + } else if (rc > 0) { + gSystem->Exit(0); + } + gDebug = (verbose) ? 1 : 0; + + rc = 0; + + // Set up log file if required + RedirectHandle_t redirH; + if (!logfile.IsNull()) { + gSystem->RedirectOutput(logfile, "w", &redirH); + } + + // Extract process ID, if a file has been passed + if (!pidfile.IsNull()) { + std::fstream infile(pidfile.Data(), std::ios::in); + if (infile.is_open()) { + TString line; + line.ReadToDelim(infile); + line.Remove(TString::kTrailing, '\n'); + if (line.IsDigit()) { + pid_t pid = (pid_t) line.Atoi(); + if (kill(pid, 0) != 0) { + fprintf(stderr, "xpdtest: process '%d' does not exist\n", (int) pid); + rc = 1; + } + } else { + fprintf(stderr, "xpdtest: pId file does not contain pid in expected form (first line: %s)\n", line.Data()); + rc = 1; + } + } else { + fprintf(stderr, "xpdtest: pId file '%s' could not be opened\n", pidfile.Data()); + rc = 1; + } + } + + // Check sandbox dir + FileStat_t fst; + if (rc == 0 && test > 1) { + if (gSystem->GetPathInfo(sboxdir, fst) != 0) { + fprintf(stderr, "xpdtest: stat failure for '%s'\n", sboxdir.Data()); + rc = 1; + } + if (rc == 0 && !R_ISDIR(fst.fMode)) { + fprintf(stderr, "xpdtest: '%s' is not a directory\n", sboxdir.Data()); + rc = 1; + } + } + + // Setup URL + TUrl u; + TString defusr; + if (rc == 0) { + u.SetUrl(url.Data()); + defusr = u.GetUser(); + if (defusr.IsNull()) { + UserGroup_t *pw = gSystem->GetUserInfo(); + if (pw) { + defusr = pw->fUser; + delete pw; + } + } + if (!url.BeginsWith(u.GetProtocol())) { + if (u.GetPort() == 80 && !strcmp(u.GetProtocol(), "http")) u.SetPort(1093); + u.SetProtocol("proof"); + } + } + + // Do ping + if (rc == 0) { + set_timer(1, timeout); + if ((rc = xpd_ping(u.GetHost(), u.GetPort())) != 0) + fprintf(stderr, "xpdtest: failure pinging '%s'\n", url.Data()); + set_timer(0); + } + + if (test > 0) { + // Do TProof::Open in "masteronly" mode + if (rc == 0) { + if (!logfile.IsNull()) gSystem->RedirectOutput(0, 0, &redirH); + rc = proof_open(u.GetUrl(), timeout); + if (!logfile.IsNull()) gSystem->RedirectOutput(logfile, "a", &redirH); + if (rc != 0) + fprintf(stderr, "xpdtest: TProof::Open failure for default user '%s'\n", u.GetUrl()); + } + + if (test > 1) { + if (rc == 0) { + + // Scan sandbox dir + time_t now = time(0); + void *dirp = gSystem->OpenDirectory(sboxdir.Data()); + const char *ent = 0; + TString dent; + while ((ent = gSystem->GetDirEntry(dirp))) { + if (!strcmp(ent, "..") || !strcmp(ent, ".")) continue; + if (defusr == ent) continue; + FileStat_t st; + if (span > 0) { + dent.Form("%s/%s", sboxdir.Data(), ent); + if (gSystem->GetPathInfo(dent, st) != 0) { + fprintf(stderr, "xpdtest: stat failure for '%s'\n", dent.Data()); + rc = 1; + break; + } + } + if (span < 0 || st.fMtime > (now - span)) { + u.SetUser(ent); + fprintf(stderr, "proof_open: url: '%s'\n", u.GetUrl()); + if (!logfile.IsNull()) gSystem->RedirectOutput(0, 0, &redirH); + rc = proof_open(u.GetUrl(), timeout); + if (!logfile.IsNull()) gSystem->RedirectOutput(logfile, "a", &redirH); + if (rc != 0) { + fprintf(stderr, "xpdtest: failure scanning sandbox dir '%s'\n", sboxdir.Data()); + break; + } + } + } + gSystem->FreeDirectory(dirp); + } + } + } + if (!logfile.IsNull()) { + gSystem->RedirectOutput(0, 0, &redirH); + if (rc == 0 && !keep) gSystem->Unlink(logfile); + } + gSystem->Exit(rc); +} + +// Auxilliary functions + +//______________________________________________________________________________ +int parse_args(int argc, char **argv, + TString &url, TString &sboxdir, time_t &span, int &test, + TString &logfile, bool &keep, bool &verbose, long &to, TString &pidfile) +{ + // Extract control info from arguments + + url = "localhost:1093"; + sboxdir = "/tmp/proofbox"; + span = -1; + test = 0; + logfile= ""; + keep = 0; + + // Check environment settings first + if (getenv("XPDTEST_URL")) { + url = getenv("XPDTEST_URL"); + } + if (getenv("XPDTEST_SBOXDIR")) { + sboxdir = getenv("XPDTEST_SBOXDIR"); + } + if (getenv("XPDTEST_TIMESPAN")) { + errno = 0; + long xspan = strtol(getenv("XPDTEST_TIMESPAN"), 0, 10); + if (errno == 0) span = (time_t) xspan; + } + if (getenv("XPDTEST_TEST")) { + errno = 0; + long xtest = strtol(getenv("XPDTEST_TEST"), 0, 10); + if (errno == 0 && xtest >= 0 && xtest <= 2) sscanf(getenv("XPDTEST_TEST"), "%d", &test); + } + if (getenv("XPDTEST_LOGFILE")) { + logfile = getenv("XPDTEST_LOGFILE"); + } + if (getenv("XPDTEST_KEEP")) { + keep = 1; + } + if (getenv("XPDTEST_VERBOSE")) { + verbose = 1; + } + if (getenv("XPDTEST_TIMEOUT")) { + errno = 0; + long xto = strtol(getenv("XPDTEST_TIMEOUT"), 0, 10); + if (errno == 0 && xto > 0) sscanf(getenv("XPDTEST_TIMEOUT"), "%ld", &to); + } + if (getenv("XPDTEST_PIDFILE")) { + pidfile = getenv("XPDTEST_PIDFILE"); + } + + // -u url -d sboxdir -s span -t test + for (int i = 1; i < argc; i++) { + if (argv[i]) { + if (!strcmp(argv[i], "-h") || !strcmp(argv[i], "--help")) { + printhelp(); + return 1; + } else if (!strcmp(argv[i], "-u")) { + if (argv[++i]) { + url = argv[i]; + } else { + fprintf(stderr, "parse_args: '-u' requires the specification of the URL!\n"); + printhelp(); + return -1; + } + } else if (!strcmp(argv[i], "-d")) { + if (argv[++i]) { + sboxdir = argv[i]; + } else { + fprintf(stderr, "parse_args: '-d' requires the specification of the sandbox directory!\n"); + printhelp(); + return -1; + } + } else if (!strcmp(argv[i], "-l")) { + if (argv[++i]) { + logfile = argv[i]; + } else { + fprintf(stderr, "parse_args: '-l' requires the specification of the logfile!\n"); + printhelp(); + return -1; + } + } else if (!strcmp(argv[i], "-k")) { + keep = 1; + } else if (!strcmp(argv[i], "-s")) { + if (argv[++i]) { + errno = 0; + long xspan = strtol(argv[i], 0, 10); + if (errno == 0 && xspan > 0) { + span = (time_t) xspan; + } else { + fprintf(stderr, "parse_args: time span must be a positive integer! (argv: %s, xspan: %ld)\n", + argv[i], xspan); + printhelp(); + return -1; + } + } else { + fprintf(stderr, "parse_args: '-s' requires the specification of the time span!\n"); + printhelp(); + return -1; + } + } else if (!strcmp(argv[i], "-t")) { + if (argv[++i]) { + errno = 0; + long xtest = strtol(argv[i], 0, 10); + if (errno == 0 && xtest >= 0 && xtest <= 2) { + sscanf(argv[i], "%d", &test); + } else { + fprintf(stderr, "parse_args: test must be an integer in [0,2]! (argv: %s, xtest: %ld)\n", + argv[i], xtest); + printhelp(); + return -1; + } + } else { + fprintf(stderr, "parse_args: '-t' requires the specification of the test!\n"); + printhelp(); + return -1; + } + } else if (!strcmp(argv[i], "-T")) { + if (argv[++i]) { + errno = 0; + long xto = strtol(argv[i], 0, 10); + if (errno == 0 && xto > 0) { + to = (time_t) xto; + } else { + fprintf(stderr, "parse_args: timeout must be a positive integer! (argv: %s, xto: %ld)\n", + argv[i], xto); + printhelp(); + return -1; + } + } else { + fprintf(stderr, "parse_args: '-T' requires the specification of the timeout (in secs)!\n"); + printhelp(); + return -1; + } + } else if (!strcmp(argv[i], "-p")) { + if (argv[++i]) { + pidfile = argv[i]; + } else { + fprintf(stderr, "parse_args: '-p' requires the specification of the file with the process ID!\n"); + printhelp(); + return -1; + } + } else if (!strcmp(argv[i], "-v")) { + verbose = 1; + } + } + } + // Done + return 0; +} + +//______________________________________________________________________________ +void printhelp() +{ + // Help function + fprintf(stderr, "\n"); + fprintf(stderr, " xpdtest: test xproofd service on (remote) host\n"); + fprintf(stderr, "\n"); + fprintf(stderr, " Syntax:\n"); + fprintf(stderr, " xpdtest [-u url] [-t test] [-d sbdir] [-s span] [-T timeout] [-l logfile]\n"); + fprintf(stderr, " [-p pidfile] [-k] [-v] [-h|--help]\n"); + fprintf(stderr, "\n"); + fprintf(stderr, " url: URL where the xproofd under test responds [localhost:1093]\n"); + fprintf(stderr, " test: type of test [0]\n"); + fprintf(stderr, " 0 ping\n"); + fprintf(stderr, " 1 '0' + check connection for default user\n"); + fprintf(stderr, " 2 '1' + check connection for all recent users\n"); + fprintf(stderr, " sbdir: sandbox directory used to find out the users of the facility\n"); + fprintf(stderr, " when test is 2 ['/tmp/proofbox']\n"); + fprintf(stderr, " span: define the time interval to define 'recent' users when test\n"); + fprintf(stderr, " is 2: only users who connected within this interval are checked;\n"); + fprintf(stderr, " use -1 for infinite [-1]\n"); + fprintf(stderr, " timeout: max time waited for a successful session start in seconds [10 secs]\n"); + fprintf(stderr, " logfile: log file if not screen; deleted if the test fails unless '-k' is\n"); + fprintf(stderr, " specified (see below) [terminal]\n"); + fprintf(stderr, " pidfile: file with the daemon process id; if specified, an initial test of the\n"); + fprintf(stderr, " process existence is done (using kill(pid, 0))\n"); + fprintf(stderr, " -k: keep log file at path given via '-l' in all cases [do not keep]\n"); + fprintf(stderr, " -v: set gDebug = 1 for ROOT\n"); + fprintf(stderr, " -h, --help: print this screen\n"); + fprintf(stderr, "\n"); + fprintf(stderr, " Return: 0 the required test succeeded\n"); + fprintf(stderr, " 1 the test failed\n"); + fprintf(stderr, "\n"); +} + +//______________________________________________________________________________ +int proof_open(const char *master, long to) +{ + // Test proof open. + // Return 0 on success, 1 on failure + int rc = 0; + RedirectHandle_t rh; + TString popenfile = TString::Format("%s/xpdtest_popen_file", gSystem->TempDirectory()); + gSystem->RedirectOutput(popenfile, "w", &rh); + set_timer(1, to); + TProof *p = TProof::Open(master, "masteronly"); + set_timer(0); + gSystem->RedirectOutput(0, 0, &rh); + if (!p || (p && !p->IsValid())) { + TMacro m; + m.ReadFile(popenfile); + if (!m.GetLineWith("Server not allowed to be top master")) rc = 1; + } + if (p) delete p; + return rc; +} + +//______________________________________________________________________________ +static void handle_sigalarm(int) +{ + // If we are called it means that we failed + gSystem->Exit(1); +} + +//______________________________________________________________________________ +static void ignore_signal(int) +{ + // Do nothing +} + +//______________________________________________________________________________ +int set_timer(bool on, long to) +{ + // Start an asynchronous firing after 'to' seconds + // Return + // 0 on success + // 1 otherwise + + struct itimerval itv; + bool sett = (on && to > 0) ? 1 : 0; + itv.it_value.tv_sec = (sett) ? time_t(to) : time_t(0); + itv.it_value.tv_usec = 0; + itv.it_interval.tv_sec = 0; + itv.it_interval.tv_usec = 0; + // Enable/disable handling of the related signal + if (sett) { + signal(SIGALRM, handle_sigalarm); + } else { + signal(SIGALRM, ignore_signal); + } + errno = 0; + return setitimer(ITIMER_REAL, &itv, 0); +} + +//______________________________________________________________________________ +int xpd_ping(const char *host, int port) +{ + // Non-blocking check for a PROOF service at 'url' + // Return + // 0 if a XProofd daemon is listening at 'url' + // 1 otherwise + + // Check arguments + if (!host || (host && strlen(host) <= 0)) { + fprintf(stderr,"xpd_ping: host must be given!\n"); + return 1; + } + + struct hostent *h = gethostbyname(host); + if (!h) { + fprintf(stderr,"xpd_ping: unknown host '%s'\n", host); + return 1; + } + + // Get socket and listen to it + int sd = getsocket(h,port); + if (sd == -1) { + fprintf(stderr,"xpd_ping: problems creating socket ... exit\n"); + return 1; + } + + // Send the first bytes + clnt_HS_t initHS; + memset(&initHS, 0, sizeof(initHS)); + int len = sizeof(initHS); + initHS.third = (int)htonl((int)1); + if (sendn(sd, &initHS, len) != len) { + fprintf(stderr,"xpd_ping: problems sending first set of handshake bytes\n"); + return 1; + } + + // These 8 bytes are need by 'rootd/proofd' and discarded by XRD/XPD + int dum[2]; + dum[0] = (int)htonl((int)4); + dum[1] = (int)htonl((int)2012); + if (sendn(sd, &dum[0], sizeof(dum)) != sizeof(dum)) { + fprintf(stderr,"xpd_ping: problems sending second set of handshake bytes\n"); + return 1; + } + + // Read first server response + int type; + len = sizeof(type); + int nr = 0; + if ((nr = recvn(sd, &type, len)) != len) { // 4 bytes + fprintf(stderr, "xpd_ping: 1st: wrong number of bytes read: %d (expected: %d)\n", + nr, len); + return 1; + } + + // To host byte order + type = ntohl(type); + // Check if the server is the eXtended proofd + if (type == 0) { + srv_HS_t xbody; + len = sizeof(xbody); + if ((nr = recvn(sd, &xbody, len)) != len) { // 12(4+4+4) bytes + fprintf(stderr, "xpd_ping: 2nd: wrong number of bytes read: %d (expected: %d)\n", + nr, len); + return 1; + } + xbody.protover = ntohl(xbody.protover); + xbody.msgval = ntohl(xbody.msglen); + xbody.msglen = ntohl(xbody.msgval); + + } else if (type == 8) { + // Standard proofd + fprintf(stderr, "xpd_ping: server is PROOFD\n"); + return 1; + } else { + // We don't know the server type + fprintf(stderr, "xpd_ping: unknown server type: %d\n", type); + return 1; + } + // Cleanup + close(sd); + // Done + return 0; +} + +//______________________________________________________________________________ +int getsocket(struct hostent *h, int port) +{ + int sd, rc; + struct sockaddr_in localAddr, servAddr; + + servAddr.sin_family = h->h_addrtype; + memcpy((char *) &servAddr.sin_addr.s_addr, h->h_addr_list[0], h->h_length); + servAddr.sin_port = htons(port); + + /* create socket */ + sd = socket(AF_INET, SOCK_STREAM, 0); + if(sd < 0) { + perror("cannot open socket "); + return -1; + } + + /* bind any port number */ + localAddr.sin_family = AF_INET; + localAddr.sin_addr.s_addr = htonl(INADDR_ANY); + localAddr.sin_port = htons(0); + + rc = ::bind(sd, (struct sockaddr *) &localAddr, sizeof(localAddr)); + if(rc < 0) { + perror("error "); + return -1; + } + + /* connect to server */ + rc = connect(sd, (struct sockaddr *) &servAddr, sizeof(servAddr)); + if(rc < 0) { + perror("cannot connect "); + return -1; + } + + return sd; + +} + +//______________________________________________________________________________ +int sendn(int sock, const void *buffer, int length) +{ + // Send exactly length bytes from buffer. + + if (sock < 0) return -1; + + int n, nsent = 0; + const char *buf = (const char *)buffer; + + for (n = 0; n < length; n += nsent) { + if ((nsent = send(sock, buf+n, length-n, 0)) <= 0) { + perror("problems sending "); + return nsent; + } + } + + return n; +} + +//______________________________________________________________________________ +int recvn(int sock, void *buffer, int length) +{ + // Receive exactly length bytes into buffer. Returns number of bytes + // received. Returns -1 in case of error. + + if (sock < 0) return -1; + + int n, nrecv = 0; + char *buf = (char *)buffer; + + for (n = 0; n < length; n += nrecv) { + while ((nrecv = recv(sock, buf+n, length-n, 0)) == -1 && errno == EINTR) + errno = 0; // probably a SIGCLD that was caught + if (nrecv < 0) { + perror("problems receiving "); + return nrecv; + } else if (nrecv == 0) + break; // EOF + } + + return n; +} diff --git a/man/man1/g2root.1 b/man/man1/g2root.1 index ec1f6c2c5a063..45105fc48656a 100644 --- a/man/man1/g2root.1 +++ b/man/man1/g2root.1 @@ -110,7 +110,7 @@ and .RS .I The ROOT Users Guide .RE -avaliable from the main +available from the main .B ROOT website: .RS diff --git a/man/man1/g2rootold.1 b/man/man1/g2rootold.1 index a235a5d4af104..bf65eeee2fc36 100644 --- a/man/man1/g2rootold.1 +++ b/man/man1/g2rootold.1 @@ -111,7 +111,7 @@ and .RS .I The ROOT Users Guide .RE -avaliable from the main +available from the main .B ROOT website: .RS diff --git a/man/man1/h2root.1 b/man/man1/h2root.1 index 5f43b58d2f231..721d04f2e60bb 100644 --- a/man/man1/h2root.1 +++ b/man/man1/h2root.1 @@ -106,7 +106,7 @@ and .RS .I The ROOT Users Guide .RE -avaliable from the main +available from the main .B ROOT website: .RS diff --git a/man/man1/hadd.1 b/man/man1/hadd.1 index 27a9992544a7e..f996dfe3e3a7a 100644 --- a/man/man1/hadd.1 +++ b/man/man1/hadd.1 @@ -26,7 +26,7 @@ For extensive documentation on the \fBROOT\fR system, see \fIhttp://root.cern.ch\fR .UE .PP -A \fBUsers Guide\fR is avaliable from +A \fBUsers Guide\fR is available from .UR http://root.cern.ch/root/UsersGuide.html here. .UE diff --git a/man/man1/proofd.1 b/man/man1/proofd.1 index 331832619f567..27bf3a48c59bb 100644 --- a/man/man1/proofd.1 +++ b/man/man1/proofd.1 @@ -27,7 +27,7 @@ not linked with any graphics libraries (Motif, X11, etc.). .SH "SETTING UP PROOF" Since you need to handle sensitive system files, you need to have root (the user, not the program!) privileges. Also, it's recommended that -you read the appropiate \fIman\fR(1) pages first. These are +you read the appropriate \fIman\fR(1) pages first. These are \fIinetd\fR(8) (the internet daemon), \fIsysklogd\fR(8) and \fIsyslog\fR(3) (the system logger daemon), and \fIinit\fR(8) (the SYSV process control initializer). @@ -87,7 +87,7 @@ If you use \fBSYSV\fR \fIinit\fR(8) scripts, you can probaly just do /etc/init.d/inetd restart .fi -or whatever is appropiate for your system. +or whatever is appropriate for your system. .TP 5 @@ -145,7 +145,7 @@ If you use \fBSYSV\fR \fIinit\fR(8) scripts, you can probaly just do /etc/init.d/sysklogd restart .fi -or whatever is appropiate for your system. +or whatever is appropriate for your system. .TP 9 @@ -163,7 +163,7 @@ distribution. This script uses \fIsyslog-facility\fR(1), from the \fBLinux\fR \fIsyslog\fR(1) distribution, and may run on other platforms as well \- but no warrenties mind you! .PP -Step 9 is completly up to the user. +Step 9 is completely up to the user. .SH "EXAMPLE" That's it. To test PROOF try the following: .nf diff --git a/man/man1/rlibmap.1 b/man/man1/rlibmap.1 index 909e8bb68e918..1616ea8768e1d 100644 --- a/man/man1/rlibmap.1 +++ b/man/man1/rlibmap.1 @@ -15,7 +15,7 @@ classes. .SH OPTIONS .TP .B --help -Gives a short list of options avaliable, and exit +Gives a short list of options available, and exit .TP .BI -f What!? diff --git a/man/man1/root-config.1 b/man/man1/root-config.1 index 315c5a73b64be..0c9df6efa5c29 100644 --- a/man/man1/root-config.1 +++ b/man/man1/root-config.1 @@ -53,7 +53,7 @@ CLEANFILES = *Cint.cxx *Cint.h *~ core .fi .RE where you should substitute \fBFoo\fR with whatever, and list the -appropiate source files in the \fB_SOURCES\fR variable. In you +appropriate source files in the \fB_SOURCES\fR variable. In you \ficonfigure.in\fR file, put: .RS .nf @@ -146,7 +146,7 @@ Same as \fBROOTLIBDIR\fR .SH OPTIONS .TP .B \-\-help -Gives a short list of options avaliable, and exit +Gives a short list of options available, and exit .TP .B \-\-version Report the version number of installed \fBROOT\fR, and exit. diff --git a/man/man1/root.1 b/man/man1/root.1 index 131847c3b682f..ef15a145da10a 100644 --- a/man/man1/root.1 +++ b/man/man1/root.1 @@ -48,7 +48,7 @@ For extensive documentation on the \fBROOT\fR system, see \fIhttp://root.cern.ch\fR .UE .PP -A \fBUsers Guide\fR is avaliable +A \fBUsers Guide\fR is available .UR http://root.cern.ch/root/UsersGuide.html online. .UE diff --git a/man/man1/roota.1 b/man/man1/roota.1 index 1534aa7d46ddf..0154ba694b1a7 100644 --- a/man/man1/roota.1 +++ b/man/man1/roota.1 @@ -49,7 +49,7 @@ For extensive documentation on the \fBROOT\fR system, see \fIROOT web-site\fR .UE .IP * -A \fBUsers Guide\fR is avaliable from +A \fBUsers Guide\fR is available from .UR http://root.cern.ch/root/UsersGuide.html \fIthe ROOT website\fR .UE diff --git a/man/man1/rootn.exe.1 b/man/man1/rootn.exe.1 index 2962658fbecc0..394a31b3d19b5 100644 --- a/man/man1/rootn.exe.1 +++ b/man/man1/rootn.exe.1 @@ -5,7 +5,7 @@ rootn.exe \- ROOT interpretor memory managed backend .SH DESCRIPTION This executable is linked with \fBlibNew\fR, unlike \fIroot.exe\fR, -which makes it appropiate for if one wants to use memory mapped file, +which makes it appropriate for if one wants to use memory mapped file, \fBTMapFile\fR, and so on. In all other aspects, it's the same as the \fIroot\fR(1) executable. .SH "SEE ALSO" diff --git a/man/man1/ssh2rpd.1 b/man/man1/ssh2rpd.1 index ae2e93c9ed7eb..9c15872a57678 100644 --- a/man/man1/ssh2rpd.1 +++ b/man/man1/ssh2rpd.1 @@ -14,7 +14,7 @@ Do know what to write here. .SH OPTIONS .TP .B --help -Gives a short list of options avaliable, and exit +Gives a short list of options available, and exit .SH "SEE ALSO" \fIroot\fR(1), \fIrootd\fR(1) .PP diff --git a/man/man1/xpdtest.1 b/man/man1/xpdtest.1 new file mode 100644 index 0000000000000..c87be6a415d31 --- /dev/null +++ b/man/man1/xpdtest.1 @@ -0,0 +1,136 @@ +.\" +.\" $Id: root-config.1,v 1.4 2005/03/21 21:42:21 rdm Exp $ +.\" +.TH XPDTEST 1 "Version 5" "ROOT" +.\" NAME should be all caps, SECTION should be 1-8, maybe w/ subsection +.\" other parms are allowed: see man(7), man(1) +.SH NAME +xpdtest \- xproofd test utility +.SH SYNOPSIS +.B xpdtest +.I "[options]" +.SH "DESCRIPTION" +This manual page documents the +.BR xpdtest +program, an utility whose purpose is to test the status of an xproofd daemon running on the local machine. +The target is to run +.B xpdtest +inside a monitor infrastructure, for example +.B monit +(see +.UR http://mmonit.com/monit/ +\fIhttp://mmonit.com/monit/\fP +), capable to take some decisions and to do some actions following the result of +.B xpdtest. + + +.SH OPTIONS +.TP +.B \-\-help, \-h +Gives a short list of options avaliable, and exit +.TP +.B \-t\fP \fR<test>\fP +type of test to be run: + 0 ping the daemon (includes process existence check if pid specified; see below) + 1 ping the daemon and check connection for default user + 2 ping the daemon and check connection for the default user and all recent users + +The default user is the one specified in the URL (e.g. 'user' for user@localhost); if no explicit specification is found in the URL, the user under which +.B xpdtest +is run is used; it can be also passed via the environment variable +.B XPDTEST_TEST. +.TP +.B \-u\fP \fR<url>\fP +URL where the xproofd under test responds; it can be also passed via the environment variable +.B XPDTEST_URL +(default is 'localhost:1093'). +.TP +.B \-d\fP \fR<sbdir>\fP +sandbox directory used to find out the users of the facility when test is 2; it can be also passed via the environment variable +.B XPDTEST_SBOXDIR +(default is '/tmp/proofbox'). +.TP +.B \-s\fP \fR<span>\fP +define the time interval, in minutes, to define 'recent' users when test is 2: only users who connected within this interval are checked; use -1 for infinite; +it can be also passed via the environment variable +.B XPDTEST_TIMESPAN +(default is -1). +.TP +.B \-T\fP \fR<timeout>\fP +define the time, in seconds, waited for the session to start successfully; +it can be also passed via the environment variable +.B XPDTEST_TIMESOUT +(default is 10 seconds). +.TP +.B \-l\fP \fR<logfile>\fP +log file if not screen; deleted if the required test fails unless '-k' is specified (see below);it can be also passed via the environment variable +.B XPDTEST_LOGFILE. +.TP +.B \-p\fP \fR<pidfile>\fP +file with the process ID as a integer number in the first line; if this file is given a quick test on the process existence is done using kill(\fRpid\fP,0); +it can be also passed via the environment variable +.B XPDTEST_PIDFILE. +.TP +.B \-k +keep log file at path given via '-l' in all cases; it can be also passed via the environment variable +.B XPDTEST_KEEP +(default is 'no keep'). +.TP +.B \-v +set +.B +gDebug=1 +for the underline ROOT calls; it can be also passed via the environment variable +.B XPDTEST_VERBOSE +(default is 'no verbose'). +.SH RETURN +.B xpdtest +returns 0 on success and 1 in case of test failure. Errors are printed on the screen or saved into the specified log file. + +.SH FILES +The file +.B xpdtest_popen_file +in the temporary directory (typically /tmp) is used to parse the output of +.B TProof::Open(). +The file is overwritten by each new attempt; after a run of +.B xpdtest +it contains the result of the last session open attempt. + +.SH NOTES +The connection attempt is done in +.B 'masteronly' +mode. For daemons running in +.B 'worker' +mode the attempt will fail with a well defined error message ('Server not allowed to be top master'); +since this indicates that the daemon is anyhow responsive, a positive detection of such a pattern in the error message +is interpreted as the attempt having being successful. + +.SH "ORIGINAL AUTHORS" +The ROOT team: +.RS +\fBRene Brun\fR and \fBFons Rademakers\fR +.RE +More information can be found at the \fBROOT\fR website: +.UR http://root.cern.ch +\fIhttp://root.cern.ch\fB +.SH "COPYRIGHT" +This library is free software; you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as +published by the Free Software Foundation; either version 2.1 of the +License, or (at your option) any later version. +.P +This library is distributed in the hope that it will be useful, but +WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +Lesser General Public License for more details. +.P +You should have received a copy of the GNU Lesser General Public +License along with this library; if not, write to the Free Software +Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +.SH AUTHOR +This manual page was written by Gerardo Ganis +<gerardo.ganis@cern.ch>, for the GNU/Linux system (but may be used by +others). +.\" +.\" EOF +.\" diff --git a/man/man1/xproofd.1 b/man/man1/xproofd.1 index 04eb5963e718a..d2edb3cb50f50 100644 --- a/man/man1/xproofd.1 +++ b/man/man1/xproofd.1 @@ -34,7 +34,7 @@ not linked with any graphics libraries (Motif, X11, etc.). .SH "SETTING UP PROOF" Since you need to handle sensitive system files, you need to have root (the user, not the program!) privileges. Also, it's recommended that -you read the appropiate \fIman\fR(1) pages first. These are +you read the appropriate \fIman\fR(1) pages first. These are \fIinetd\fR(8) (the internet daemon), \fIsysklogd\fR(8) and \fIsyslog\fR(3) (the system logger daemon), and \fIinit\fR(8) (the SYSV process control initializer). @@ -94,7 +94,7 @@ If you use \fBSYSV\fR \fIinit\fR(8) scripts, you can probaly just do /etc/init.d/inetd restart .fi -or whatever is appropiate for your system. +or whatever is appropriate for your system. .TP 5 @@ -152,7 +152,7 @@ If you use \fBSYSV\fR \fIinit\fR(8) scripts, you can probaly just do /etc/init.d/sysklogd restart .fi -or whatever is appropiate for your system. +or whatever is appropriate for your system. .TP 9 @@ -170,7 +170,7 @@ distribution. This script uses \fIsyslog-facility\fR(1), from the \fBLinux\fR \fIsyslog\fR(1) distribution, and may run on other platforms as well \- but no warrenties mind you! .PP -Step 9 is completly up to the user. +Step 9 is completely up to the user. .SH "EXAMPLE" That's it. To test PROOF try the following: .nf diff --git a/math/fftw/src/TFFTComplexReal.cxx b/math/fftw/src/TFFTComplexReal.cxx index 7913011b3ec4a..e8506cd9346a4 100644 --- a/math/fftw/src/TFFTComplexReal.cxx +++ b/math/fftw/src/TFFTComplexReal.cxx @@ -346,8 +346,8 @@ void TFFTComplexReal::SetPointComplex(Int_t ipoint, TComplex &c) ((fftw_complex*)fIn)[ipoint][0] = c.Re(); ((fftw_complex*)fIn)[ipoint][1] = c.Im(); } else { - ((fftw_complex*)fOut)[2*(fN[0]/2)-ipoint][0] = c.Re(); - ((fftw_complex*)fOut)[2*(fN[0]/2)-ipoint][1] = -c.Im(); + ((fftw_complex*)fIn)[2*(fN[0]/2)-ipoint][0] = c.Re(); + ((fftw_complex*)fIn)[2*(fN[0]/2)-ipoint][1] = -c.Im(); } } diff --git a/math/foam/inc/TFoamSampler.h b/math/foam/inc/TFoamSampler.h index 409cc29e17ae8..7b30c327587e8 100644 --- a/math/foam/inc/TFoamSampler.h +++ b/math/foam/inc/TFoamSampler.h @@ -123,7 +123,7 @@ class TFoamSampler : public ROOT::Math::DistSampler { private: // private member - bool fOneDim; // flag to indicate if the function is 1 dimension +// bool fOneDim; // flag to indicate if the function is 1 dimension // bool fHasMode; // flag to indicate if a mode is set // bool fHasArea; // flag to indicate if a area is set // double fMode; // mode of dist diff --git a/math/foam/src/TFoamSampler.cxx b/math/foam/src/TFoamSampler.cxx index f7265897fe1f0..74404b952d67d 100644 --- a/math/foam/src/TFoamSampler.cxx +++ b/math/foam/src/TFoamSampler.cxx @@ -85,7 +85,7 @@ ClassImp(TFoamSampler) */ TFoamSampler::TFoamSampler() : ROOT::Math::DistSampler(), - fOneDim(false), +// fOneDim(false), // fDiscrete(false), // fHasMode(false), fHasArea(false), // fMode(0), fArea(0), diff --git a/math/genvector/inc/Math/GenVector/BitReproducible.h b/math/genvector/inc/Math/GenVector/BitReproducible.h index 8bf82a420678c..b12769d3d04ae 100644 --- a/math/genvector/inc/Math/GenVector/BitReproducible.h +++ b/math/genvector/inc/Math/GenVector/BitReproducible.h @@ -48,7 +48,7 @@ class BitReproducible { // dto2longs(d, i1, i2) returns (in i1 and i2) two unsigned ints // representation of its double input. This is byte-ordering - // independant, and depends for complete portability ONLY on adherance + // independent, and depends for complete portability ONLY on adherance // to the IEEE 754 standard for 64-bit floating point representation. // The first unsigned int contains the high-order bits in IEEE; thus // 1.0 will always be 0x3FF00000, 00000000 @@ -64,7 +64,7 @@ class BitReproducible { // dtox(d) returns a 16-character string containing the (zero-filled) hex // representation of its double input. This is byte-ordering - // independant, and depends for complete portability ONLY on adherance + // independent, and depends for complete portability ONLY on adherance // to the IEEE 754 standard for 64-bit floating point representation. static std::string D2x(double d); diff --git a/math/mathcore/CMakeLists.txt b/math/mathcore/CMakeLists.txt index 8d712c63cedfe..ef56b34c6cd95 100644 --- a/math/mathcore/CMakeLists.txt +++ b/math/mathcore/CMakeLists.txt @@ -6,7 +6,7 @@ ROOT_USE_PACKAGE(core) include_directories(${CMAKE_SOURCE_DIR}/hist/hist/inc) # Explicit to avoid circular dependencies mathcore <--> hist :-( set(MATHCORE_HEADERS TRandom.h - TRandom1.h TRandom2.h TRandom3.h TVirtualFitter.h TKDTree.h TKDTreeBinning.h TStatistic.h + TRandom1.h TRandom2.h TRandom3.h TVirtualFitter.h TKDTree.h TKDTreeBinning.h TStatistic.h Math/IParamFunction.h Math/IFunction.h Math/ParamFunctor.h Math/Functor.h Math/Minimizer.h Math/MinimizerOptions.h Math/IntegratorOptions.h Math/IOptions.h Math/Integrator.h Math/VirtualIntegrator.h Math/AllIntegrationTypes.h Math/AdaptiveIntegratorMultiDim.h @@ -14,11 +14,11 @@ set(MATHCORE_HEADERS TRandom.h Math/GaussLegendreIntegrator.h Math/RootFinder.h Math/IRootFinderMethod.h Math/RichardsonDerivator.h Math/BrentMethods.h Math/BrentMinimizer1D.h Math/BrentRootFinder.h Math/DistSampler.h Math/DistSamplerOptions.h Math/GoFTest.h Math/SpecFuncMathCore.h Math/DistFuncMathCore.h - Math/KDTree.h Math/TDataPoint.h Math/TDataPointN.h + Math/ChebyshevPol.h Math/KDTree.h Math/TDataPoint.h Math/TDataPointN.h ) -ROOT_GENERATE_DICTIONARY(G__Math TComplex.h TMath.h LINKDEF LinkDef1.h) +ROOT_GENERATE_DICTIONARY(G__Math TComplex.h TMath.h LINKDEF LinkDef1.h) ROOT_GENERATE_DICTIONARY(G__MathCore ${MATHCORE_HEADERS} LINKDEF LinkDef2.h) ROOT_GENERATE_DICTIONARY(G__MathFit Fit/*.h LINKDEF LinkDef3.h) diff --git a/math/mathcore/Module.mk b/math/mathcore/Module.mk index 740fb78438f7a..09a99abff060e 100644 --- a/math/mathcore/Module.mk +++ b/math/mathcore/Module.mk @@ -30,12 +30,12 @@ MATHCOREDO := $(MATHCOREDO1) $(MATHCOREDO2) $(MATHCOREDO3) MATHCOREDH := $(MATHCOREDS:.cxx=.h) MATHCOREDH1 := $(MODDIRI)/TComplex.h \ - $(MODDIRI)/TStatistic.h \ $(MODDIRI)/TMath.h MATHCOREDH2 := $(MODDIRI)/TRandom.h \ $(MODDIRI)/TRandom1.h \ $(MODDIRI)/TRandom2.h \ $(MODDIRI)/TRandom3.h \ + $(MODDIRI)/TStatistic.h \ $(MODDIRI)/TVirtualFitter.h \ $(MODDIRI)/TKDTree.h \ $(MODDIRI)/TKDTreeBinning.h \ @@ -68,6 +68,7 @@ MATHCOREDH2 := $(MODDIRI)/TRandom.h \ $(MODDIRI)/Math/DistSampler.h \ $(MODDIRI)/Math/DistSamplerOptions.h \ $(MODDIRI)/Math/GoFTest.h \ + $(MODDIRI)/Math/ChebyshevPol.h \ $(MODDIRI)/Math/SpecFuncMathCore.h \ $(MODDIRI)/Math/DistFuncMathCore.h MATHCOREDH3 := $(filter-out $(MODDIRI)/Fit/Chi2Grad%,$(wildcard $(MODDIRI)/Fit/*.h)) diff --git a/math/mathcore/inc/Fit/SparseData.h b/math/mathcore/inc/Fit/SparseData.h index ffe749491515e..129e0215e0be1 100644 --- a/math/mathcore/inc/Fit/SparseData.h +++ b/math/mathcore/inc/Fit/SparseData.h @@ -17,10 +17,11 @@ #ifndef ROOT_Fit_DataVector #include "Fit/DataVector.h" +#endif +#ifndef ROOT_Fit_BinData #include "Fit/BinData.h" #endif - namespace ROOT { namespace Fit { diff --git a/math/mathcore/inc/LinkDef1.h b/math/mathcore/inc/LinkDef1.h index 75ca096f9f001..fdd2f5b45ba15 100644 --- a/math/mathcore/inc/LinkDef1.h +++ b/math/mathcore/inc/LinkDef1.h @@ -22,7 +22,6 @@ #pragma link C++ global ROOT_TMath; #pragma link C++ class TComplex+; -#pragma link C++ class TStatistic+; #pragma link C++ function operator*(Double_t, const TComplex&); #pragma link C++ function operator+(Double_t, const TComplex&); @@ -46,6 +45,9 @@ //#pragma link C++ function TMath::Limits<Long64_t>::Max(); //#pragma link C++ function TMath::Limits<Long64_t>::Min(); +#pragma link C++ function TMath::Nint<Float_t>(Float_t); +#pragma link C++ function TMath::Nint<Double_t>(Double_t); + #pragma link C++ function TMath::MinElement(Long64_t, const Short_t*); #pragma link C++ function TMath::MinElement(Long64_t, const Int_t*); #pragma link C++ function TMath::MinElement(Long64_t, const Float_t*); diff --git a/math/mathcore/inc/LinkDef2.h b/math/mathcore/inc/LinkDef2.h index 6fa21a6bf96ca..fb9da621cb711 100644 --- a/math/mathcore/inc/LinkDef2.h +++ b/math/mathcore/inc/LinkDef2.h @@ -44,6 +44,8 @@ #pragma link C++ class TRandom2+; #pragma link C++ class TRandom3-; +#pragma link C++ class TStatistic+; + #pragma link C++ class TVirtualFitter+; #pragma link C++ class TKDTree<Int_t, Double_t>+; diff --git a/math/mathcore/inc/LinkDef_Func.h b/math/mathcore/inc/LinkDef_Func.h index b59819bbaae47..1f668d7333396 100644 --- a/math/mathcore/inc/LinkDef_Func.h +++ b/math/mathcore/inc/LinkDef_Func.h @@ -99,4 +99,15 @@ #pragma link C++ function ROOT::Math::uniform_quantile_c(double,double,double); #pragma link C++ function ROOT::Math::uniform_quantile(double,double,double); +//Chebyshev functions and polynomials +#pragma link C++ function ROOT::Math::Chebyshev0(double, double); +#pragma link C++ function ROOT::Math::Chebyshev1(double, double, double); +#pragma link C++ function ROOT::Math::Chebyshev2(double, double, double, double); +#pragma link C++ function ROOT::Math::Chebyshev3(double, double, double, double, double); +#pragma link C++ function ROOT::Math::Chebyshev4(double, double, double, double, double, double); +#pragma link C++ function ROOT::Math::Chebyshev5(double, double, double, double, double, double, double); +#pragma link C++ function ROOT::Math::ChebyshevN(unsigned int,double, const double*); +#pragma link C++ class ROOT::Math::ChebyshevPol+; + + #endif diff --git a/math/mathcore/inc/Math/ChebyshevPol.h b/math/mathcore/inc/Math/ChebyshevPol.h new file mode 100644 index 0000000000000..18bbb36d4d8e8 --- /dev/null +++ b/math/mathcore/inc/Math/ChebyshevPol.h @@ -0,0 +1,135 @@ +// @(#)root/mathcore:$Id$ +// Author: L. Moneta, 11/2012 + +/************************************************************************* + * Copyright (C) 1995-2012, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////// +// // +// Header file declaring functions for the evaluation of the Chebyshev // +// polynomials and the ChebyshevPol class which can be used for // +// creating a TF1. // +// // +////////////////////////////////////////////////////////////////////////// + +#ifndef ROOT_Math_ChebyshevPol +#define ROOT_Math_ChebyshevPol + +#if !defined(__CINT__) +#include <sys/types.h> +#endif +#include <cstring> + +namespace ROOT { + + namespace Math { + + /// template recursive functions for defining evaluation of Chebyshev polynomials + /// T_n(x) and the series S(x) = Sum_i c_i* T_i(x) + namespace Chebyshev { + + template<int N> double T(double x) { + return (2.0 * x * T<N-1>(x)) - T<N-2>(x); + } + + template<> double T<0> (double ); + template<> double T<1> (double x); + template<> double T<2> (double x); + template<> double T<3> (double x); + + template<int N> double Eval(double x, const double * c) { + return c[N]*T<N>(x) + Eval<N-1>(x,c); + } + + template<> double Eval<0> (double , const double *c); + template<> double Eval<1> (double x, const double *c); + template<> double Eval<2> (double x, const double *c); + template<> double Eval<3> (double x, const double *c); + + } // end namespace Chebyshev + + + // implementation of Chebyshev polynomials using all coefficients + // needed for creating TF1 functions + inline double Chebyshev0(double , double c0) { + return c0; + } + inline double Chebyshev1(double x, double c0, double c1) { + return c0 + c1*x; + } + inline double Chebyshev2(double x, double c0, double c1, double c2) { + return c0 + c1*x + c2*(2.0*x*x - 1.0); + } + inline double Chebyshev3(double x, double c0, double c1, double c2, double c3) { + return c3*Chebyshev::T<3>(x) + Chebyshev2(x,c0,c1,c2); + } + inline double Chebyshev4(double x, double c0, double c1, double c2, double c3, double c4) { + return c4*Chebyshev::T<4>(x) + Chebyshev3(x,c0,c1,c2,c3); + } + inline double Chebyshev5(double x, double c0, double c1, double c2, double c3, double c4, double c5) { + return c5*Chebyshev::T<5>(x) + Chebyshev4(x,c0,c1,c2,c3,c4); + } + + + // implementation of Chebyshev polynomial with run time parameter + inline double ChebyshevN(unsigned int n, double x, const double * c) { + + if (n == 0) return Chebyshev0(x,c[0]); + if (n == 1) return Chebyshev1(x,c[0],c[1]); + if (n == 2) return Chebyshev2(x,c[0],c[1],c[2]); + if (n == 3) return Chebyshev3(x,c[0],c[1],c[2],c[3]); + if (n == 4) return Chebyshev4(x,c[0],c[1],c[2],c[3],c[4]); + if (n == 5) return Chebyshev5(x,c[0],c[1],c[2],c[3],c[4],c[5]); + + /* do not use recursive formula + (2.0 * x * Tn(n - 1, x)) - Tn(n - 2, x) ; + which is too slow for large n + */ + + size_t i; + double d1 = 0.0; + double d2 = 0.0; + + // if not in range [-1,1] + //double y = (2.0 * x - a - b) / (b - a); + //double y = x; + double y2 = 2.0 * x; + + for (i = n; i >= 1; i--) + { + double temp = d1; + d1 = y2 * d1 - d2 + c[i]; + d2 = temp; + } + + return x * d1 - d2 + c[0]; + } + + + // implementation of Chebyshev Polynomial class + // which can be used for building TF1 classes + class ChebyshevPol { + public: + ChebyshevPol(unsigned int n) : fOrder(n) {} + + double operator() (const double *x, const double * coeff) { + return ChebyshevN(fOrder, x[0], coeff); + } + private: + unsigned int fOrder; + }; + + + + } // end namespace Math + +} // end namespace ROOT + + + +#endif // ROOT_Math_Chebyshev diff --git a/math/mathcore/inc/Math/Minimizer.h b/math/mathcore/inc/Math/Minimizer.h index 6f9e4467c5f08..6e8826a6f81cc 100644 --- a/math/mathcore/inc/Math/Minimizer.h +++ b/math/mathcore/inc/Math/Minimizer.h @@ -128,7 +128,7 @@ class Minimizer { } - /// add variables . Return number of variables succesfully added + /// add variables . Return number of variables successfully added template<class VariableIterator> int SetVariables(const VariableIterator & begin, const VariableIterator & end) { unsigned int ivar = 0; diff --git a/math/mathcore/inc/Math/OneDimFunctionAdapter.h b/math/mathcore/inc/Math/OneDimFunctionAdapter.h index d74b2124971cd..f060f7d7a1d11 100644 --- a/math/mathcore/inc/Math/OneDimFunctionAdapter.h +++ b/math/mathcore/inc/Math/OneDimFunctionAdapter.h @@ -102,8 +102,11 @@ class OneDimMultiFunctionAdapter : public ROOT::Math::IGenFunction { clone */ virtual OneDimMultiFunctionAdapter * Clone( ) const { - if (fOwn) - return new OneDimMultiFunctionAdapter( fFunc, fDim, fCoord, fParams); + if (fOwn) { + OneDimMultiFunctionAdapter * f = new OneDimMultiFunctionAdapter( fFunc, fDim, fCoord, fParams); + std::copy(fX, fX+fDim, f->fX); + return f; + } else return new OneDimMultiFunctionAdapter( fFunc, fX, fCoord, fParams); } diff --git a/math/mathcore/inc/Math/RootFinder.h b/math/mathcore/inc/Math/RootFinder.h index 95790b4516a9b..f695b2193d391 100644 --- a/math/mathcore/inc/Math/RootFinder.h +++ b/math/mathcore/inc/Math/RootFinder.h @@ -45,7 +45,7 @@ @defgroup RootFinders One-dimensional Root-Finding algorithms Various implementation esists in MathCore and MathMore The user interacts with a proxy class ROOT::Math::RootFinder which creates behing - the choosen algorithms which are implemented using the ROOT::Math::IRootFinderMethod interface + the chosen algorithms which are implemented using the ROOT::Math::IRootFinderMethod interface @ingroup NumAlgo */ diff --git a/math/mathcore/inc/TKDTreeBinning.h b/math/mathcore/inc/TKDTreeBinning.h index 65f25c5516c14..a64246826f827 100644 --- a/math/mathcore/inc/TKDTreeBinning.h +++ b/math/mathcore/inc/TKDTreeBinning.h @@ -82,11 +82,12 @@ class TKDTreeBinning : public TObject { Double_t GetDataMax(UInt_t dim) const; Double_t GetBinDensity(UInt_t bin) const; Double_t GetBinVolume(UInt_t bin) const; - const Double_t* GetOneDimBinEdges() const; const Double_t* GetBinCenter(UInt_t bin) const; const Double_t* GetBinWidth(UInt_t bin) const; UInt_t GetBinMaxDensity() const; UInt_t GetBinMinDensity() const; + const Double_t* GetOneDimBinEdges() const; + const Double_t* SortOneDimBinEdges(Bool_t sortAsc = kTRUE); void FillBinData(ROOT::Fit::BinData & data) const; ClassDef(TKDTreeBinning, 1) diff --git a/math/mathcore/inc/TMath.h b/math/mathcore/inc/TMath.h index af67f34a48aab..2b0303650c36f 100644 --- a/math/mathcore/inc/TMath.h +++ b/math/mathcore/inc/TMath.h @@ -151,11 +151,14 @@ namespace TMath { /* ************************ */ /* * Elementary Functions * */ /* ************************ */ - inline Double_t Sqrt(Double_t x); inline Double_t Ceil(Double_t x); inline Int_t CeilNint(Double_t x); inline Double_t Floor(Double_t x); inline Int_t FloorNint(Double_t x); + template<typename T> + inline Int_t Nint(T x); + + inline Double_t Sqrt(Double_t x); inline Double_t Exp(Double_t x); inline Double_t Ldexp(Double_t x, Int_t exp); Double_t Factorial(Int_t i); @@ -164,8 +167,6 @@ namespace TMath { inline Double_t Log(Double_t x); Double_t Log2(Double_t x); inline Double_t Log10(Double_t x); - Int_t Nint(Float_t x); - Int_t Nint(Double_t x); inline Int_t Finite(Double_t x); inline Int_t IsNaN(Double_t x); @@ -302,6 +303,9 @@ namespace TMath { template <typename T> Double_t RMS(Long64_t n, const T *a); template <typename Iterator> Double_t RMS(Iterator first, Iterator last); + template <typename T> Double_t StdDev(Long64_t n, const T *a) { return RMS<T>(n,a); } + template <typename Iterator> Double_t StdDev(Iterator first, Iterator last) { return RMS<Iterator>(first,last); } + template <typename T> Double_t Median(Long64_t n, const T *a, const Double_t *w=0, Long64_t *work=0); //k-th order statistic @@ -463,6 +467,22 @@ inline Double_t TMath::Floor(Double_t x) inline Int_t TMath::FloorNint(Double_t x) { return TMath::Nint(floor(x)); } +template<typename T> +inline Int_t TMath::Nint(T x) +{ + // Round to nearest integer. Rounds half integers to the nearest + // even integer. + int i; + if (x >= 0) { + i = int(x + 0.5); + if ( i & 1 && x + 0.5 == T(i) ) i--; + } else { + i = int(x - 0.5); + if ( i & 1 && x - 0.5 == T(i) ) i++; + } + return i; +} + inline Double_t TMath::Exp(Double_t x) { return exp(x); } @@ -489,7 +509,7 @@ inline Double_t TMath::Log10(Double_t x) inline Int_t TMath::Finite(Double_t x) #if defined(R__HPUX11) { return isfinite(x); } -#elif defined(R__MACOSX) && defined(__arm__) +#elif defined(R__MACOSX) #ifdef isfinite // from math.h { return isfinite(x); } @@ -502,7 +522,7 @@ inline Int_t TMath::Finite(Double_t x) #endif inline Int_t TMath::IsNaN(Double_t x) -#if (defined(R__ANSISTREAM) || (defined(R__MACOSX) && defined(__arm__))) && !defined(_AIX) +#if (defined(R__ANSISTREAM) || (defined(R__MACOSX) && defined(__arm__))) && !defined(_AIX) && !defined(__CUDACC__) #if defined(isnan) || defined(R__SOLARIS_CC50) || defined(__INTEL_COMPILER) // from math.h { return ::isnan(x); } diff --git a/math/mathcore/inc/TStatistic.h b/math/mathcore/inc/TStatistic.h index dd5d3456c5f7d..a3d6d14b68f10 100644 --- a/math/mathcore/inc/TStatistic.h +++ b/math/mathcore/inc/TStatistic.h @@ -1,4 +1,4 @@ -// @(#)root/base:$Id$ +// @(#)root/mathcore:$Id$ // Author: G. Ganis 2012 /************************************************************************* @@ -22,14 +22,6 @@ // // ////////////////////////////////////////////////////////////////////////// -#ifndef ROOT_Riostream -#include "Riostream.h" -#endif - -#ifndef ROOT_TClass -#include "TClass.h" -#endif - #ifndef ROOT_TObject #include "TObject.h" #endif diff --git a/math/mathcore/src/ChebyshevPol.cxx b/math/mathcore/src/ChebyshevPol.cxx new file mode 100644 index 0000000000000..3d44e3a32f60c --- /dev/null +++ b/math/mathcore/src/ChebyshevPol.cxx @@ -0,0 +1,35 @@ +// @(#)root/mathcore:$Id$ +// Author: Fons Rademakers, 12/2012 + +/************************************************************************* + * Copyright (C) 1995-2012, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////// +// // +// Functions for the evaluation of the Chebyshev polynomials and the // +// ChebyshevPol class which can be used for creating a TF1. // +// // +////////////////////////////////////////////////////////////////////////// + +#include "Math/ChebyshevPol.h" + +namespace ROOT { + namespace Math { + namespace Chebyshev { + template<> double T<0> (double ) { return 1;} + template<> double T<1> (double x) { return x;} + template<> double T<2> (double x) { return 2.0*x*x -1;} + template<> double T<3> (double x) { return 4.0*x*x*x -3.0*x;} + + template<> double Eval<0> (double , const double *c) { return c[0];} + template<> double Eval<1> (double x, const double *c) { return c[1]*x + c[0];} + template<> double Eval<2> (double x, const double *c) { return c[2]*Chebyshev::T<2>(x) + c[1]*x + c[0];} + template<> double Eval<3> (double x, const double *c) { return c[3]*Chebyshev::T<3>(x) + Eval<2>(x,c); } + } + } +} diff --git a/math/mathcore/src/Factory.cxx b/math/mathcore/src/Factory.cxx index c9216f0cc7d69..49d47646534e7 100644 --- a/math/mathcore/src/Factory.cxx +++ b/math/mathcore/src/Factory.cxx @@ -21,10 +21,17 @@ #include "Math/DistSampler.h" #include "Math/DistSamplerOptions.h" +// uncomment these if you dont want to use the plugin manager +// but you need to link also the needed minimization libraries (e.g Minuit and/or Minuit2) +// #define MATH_NO_PLUGIN_MANAGER +// #define HAS_MINUIT +// #define HAS_MINUIT2 + #ifndef MATH_NO_PLUGIN_MANAGER // use ROOT Plug-in manager #include "TPluginManager.h" #include "TROOT.h" +#include "TVirtualMutex.h" #else // all the minimizer implementation classes //#define HAS_MINUIT2 @@ -76,6 +83,8 @@ ROOT::Math::Minimizer * ROOT::Math::Factory::CreateMinimizer(const std::string & if (minimizerType.empty() ) minim = ROOT::Math::MinimizerOptions::DefaultMinimizerType().c_str(); + R__LOCKGUARD2(gROOTMutex); + // create Minimizer using the PM TPluginHandler *h; //gDebug = 3; @@ -128,7 +137,7 @@ ROOT::Math::Minimizer * ROOT::Math::Factory::CreateMinimizer(const std::string & #ifdef HAS_MINUIT // use TMinuit if (minimizerType == "Minuit" || minimizerType == "TMinuit") - min = new ROOT::Fit::TMinuitMinimizer(algoType.c_str()); + min = new TMinuitMinimizer(algoType.c_str()); #endif #ifdef R__HAS_MATHMORE @@ -164,6 +173,8 @@ ROOT::Math::DistSampler * ROOT::Math::Factory::CreateDistSampler(const std::stri const char * typeName = type.c_str(); if (type.empty() ) typeName = ROOT::Math::DistSamplerOptions::DefaultSampler().c_str(); + R__LOCKGUARD2(gROOTMutex); + TPluginManager *pm = gROOT->GetPluginManager(); assert(pm != 0); TPluginHandler *h = pm->FindHandler("ROOT::Math::DistSampler", typeName ); diff --git a/math/mathcore/src/Fitter.cxx b/math/mathcore/src/Fitter.cxx index 4c2ca13b141f6..7f85a64820165 100644 --- a/math/mathcore/src/Fitter.cxx +++ b/math/mathcore/src/Fitter.cxx @@ -37,6 +37,11 @@ namespace ROOT { namespace Fit { +// use a static variable to get default minimizer options for error def +// to see if user has changed it later on. If it has not been changed we set +// for the likelihood method an error def of 0.5 +// t.b.d : multiply likelihood by 2 so have same error def definition as chi2 + double gDefaultErrorDef = ROOT::Math::MinimizerOptions::DefaultErrorDef(); Fitter::Fitter() : @@ -358,10 +363,16 @@ bool Fitter::DoLikelihoodFit(const BinData & data, bool extended) { } // logl fit (error should be 0.5) set if different than default values (of 1) - if (fConfig.MinimizerOptions().ErrorDef() == ROOT::Math::MinimizerOptions::DefaultErrorDef() ) { + if (fConfig.MinimizerOptions().ErrorDef() == gDefaultErrorDef ) { fConfig.MinimizerOptions().SetErrorDef(0.5); } + if (useWeight && fConfig.MinosErrors() ) { + MATH_INFO_MSG("Fitter::DoLikelihoodFit","MINOS errors cannot be computed in weighted likelihood fits"); + fConfig.SetMinosErrors(false); + } + + fBinFit = true; fDataSize = data.Size(); @@ -416,6 +427,12 @@ bool Fitter::DoLikelihoodFit(const UnBinData & data, bool extended) { return false; } + if (useWeight && fConfig.MinosErrors() ) { + MATH_INFO_MSG("Fitter::DoLikelihoodFit","MINOS errors cannot be computed in weighted likelihood fits"); + fConfig.SetMinosErrors(false); + } + + fBinFit = false; fDataSize = data.Size(); @@ -425,7 +442,7 @@ bool Fitter::DoLikelihoodFit(const UnBinData & data, bool extended) { #endif // logl fit (error should be 0.5) set if different than default values (of 1) - if (fConfig.MinimizerOptions().ErrorDef() == ROOT::Math::MinimizerOptions::DefaultErrorDef() ) { + if (fConfig.MinimizerOptions().ErrorDef() == gDefaultErrorDef ) { fConfig.MinimizerOptions().SetErrorDef(0.5); } @@ -479,15 +496,39 @@ bool Fitter::DoLinearFit(const BinData & data ) { bool Fitter::CalculateHessErrors() { - // compute the Minos errors according to configuration + // compute the Hesse errors according to configuration // set in the parameters and append value in fit result if (fObjFunction.get() == 0) { - MATH_ERROR_MSG("Fitter::FitFCN","Objective function has not been set"); + MATH_ERROR_MSG("Fitter::CalculateHessErrors","Objective function has not been set"); return false; } // assume a fResult pointer always exists assert (fResult.get() ); + // need a special treatment in case of weighted likelihood fit + // (not yet implemented) + if (fFitType == 2 && fConfig.UseWeightCorrection() ) { + MATH_ERROR_MSG("Fitter::CalculateHessErrors","Re-computation of Hesse errors not implemented for weighted likelihood fits"); + MATH_INFO_MSG("Fitter::CalculateHessErrors","Do the Fit using configure option FitConfig::SetParabErrors()"); + return false; + } + // if (!fUseGradient ) { + // ROOT::Math::FitMethodFunction * fcn = dynamic_cast< ROOT::Math::FitMethodFunction *>(fObjFunction.get()); + // if (fcn && fcn->Type() == ROOT::Math::FitMethodFunction::kLogLikelihood) { + // if (!fBinFit) { + // ROOT::Math::LogLikelihoodFunction * nll = dynamic_cast< ROOT::Math::LogLikelihoodFunction *>(fcn); + // assert(nll); + // nll->UseSumOfWeightSquare(false); + // } + // else { + // ROOT::Math::PoissonLikelihoodFunction * nll = dynamic_cast< ROOT::Math::PoissonLikelihoodFunction *>(fcn); + // assert(nll); + // nll->UseSumOfWeightSquare(false); + // } + // // reset fcn in minimizer + // } + + // create minimizer if not done or if name has changed if ( !fMinimizer.get() || fResult->MinimizerType().find(fConfig.MinimizerType()) == std::string::npos ) { @@ -546,6 +587,12 @@ bool Fitter::CalculateMinosErrors() { return false; } + if (fFitType == 2 && fConfig.UseWeightCorrection() ) { + MATH_ERROR_MSG("Fitter::CalculateMinosErrors","Computation of MINOS errors not implemented for weighted likelihood fits"); + return false; + } + + const std::vector<unsigned int> & ipars = fConfig.MinosParams(); unsigned int n = (ipars.size() > 0) ? ipars.size() : fResult->Parameters().size(); bool ok = false; @@ -585,8 +632,8 @@ struct ObjFuncTrait<ROOT::Math::FitMethodGradFunction> { }; bool Fitter::DoInitMinimizer() { - //initialize minimizer - + //initialize minimizer by creating it + // and set there the objective function // obj function must have been copied before assert(fObjFunction.get() ); diff --git a/math/mathcore/src/RichardsonDerivator.cxx b/math/mathcore/src/RichardsonDerivator.cxx index 0c9afa3507f61..64d0df8e0bb49 100644 --- a/math/mathcore/src/RichardsonDerivator.cxx +++ b/math/mathcore/src/RichardsonDerivator.cxx @@ -49,7 +49,11 @@ RichardsonDerivator::~RichardsonDerivator() RichardsonDerivator::RichardsonDerivator(const RichardsonDerivator & rhs) { // copy constructor - *this = rhs; + // copy constructor (deep copy or not depending on fFunctionCopied) + fStepSize = rhs.fStepSize; + fLastError = rhs.fLastError; + fFunctionCopied = rhs.fFunctionCopied; + SetFunction(*rhs.fFunction); } RichardsonDerivator & RichardsonDerivator::operator= ( const RichardsonDerivator & rhs) diff --git a/math/mathcore/src/TKDTreeBinning.cxx b/math/mathcore/src/TKDTreeBinning.cxx index c658498614c3a..e8ef4b84a44c0 100644 --- a/math/mathcore/src/TKDTreeBinning.cxx +++ b/math/mathcore/src/TKDTreeBinning.cxx @@ -119,17 +119,9 @@ void TKDTreeBinning::SetNBins(UInt_t bins) { void TKDTreeBinning::SortBinsByDensity(Bool_t sortAsc) { // Sorts bins by their density - if (fDim == 1) { - fIsSortedAsc = kTRUE; - std::sort(fBinMinEdges.begin(), fBinMinEdges.end()); - std::sort(fBinMaxEdges.begin(), fBinMaxEdges.end()); - // Add also the upper edge to the min - fBinMinEdges.push_back(fBinMaxEdges.back()); - if (!sortAsc) { - std::reverse(fBinMinEdges.begin(), fBinMinEdges.end()); - std::reverse(fBinMaxEdges.begin(), fBinMaxEdges.end()); - fIsSortedAsc = kFALSE; - } + if (fDim == 1) { + // in one dim they are already sorted (no need to do anything) + return; } else { UInt_t* indices = new UInt_t[fNBins]; for (UInt_t i = 0; i < fNBins; ++i) @@ -141,31 +133,37 @@ void TKDTreeBinning::SortBinsByDensity(Bool_t sortAsc) { std::sort(indices, indices + fNBins, CompareDesc(this)); fIsSortedAsc = kFALSE; } - std::vector<Double_t> binMinEdges; binMinEdges.reserve(fNBins * fDim); - std::vector<Double_t> binMaxEdges; binMaxEdges.reserve(fNBins * fDim); + std::vector<Double_t> binMinEdges(fNBins * fDim); + std::vector<Double_t> binMaxEdges(fNBins * fDim); + std::vector<UInt_t> binContent(fNBins ); // reajust also content (not needed bbut better in general!) for (UInt_t i = 0; i < fNBins; ++i) { for (UInt_t j = 0; j < fDim; ++j) { binMinEdges[i * fDim + j] = fBinMinEdges[indices[i] * fDim + j]; binMaxEdges[i * fDim + j] = fBinMaxEdges[indices[i] * fDim + j]; } + binContent[i] = fBinsContent[indices[i]]; } fBinMinEdges.swap(binMinEdges); fBinMaxEdges.swap(binMaxEdges); + fBinsContent.swap(binContent); + + // not needed anymore if readjusting bin content all the time // re-adjust content of extra bins if exists // since it is different than the others - if ( fDataSize % fNBins != 0) { - UInt_t k = 0; - Bool_t found = kFALSE; - while (!found) { - if (indices[k] == fNBins - 1) { - found = kTRUE; - break; - } - ++k; - } - fBinsContent[fNBins - 1] = fDataBins->GetBucketSize(); - fBinsContent[k] = fDataSize % fNBins-1; - } + // if ( fDataSize % fNBins != 0) { + // UInt_t k = 0; + // Bool_t found = kFALSE; + // while (!found) { + // if (indices[k] == fNBins - 1) { + // found = kTRUE; + // break; + // } + // ++k; + // } + // fBinsContent[fNBins - 1] = fDataBins->GetBucketSize(); + // fBinsContent[k] = fDataSize % fNBins-1; + // } + delete [] indices; fIsSorted = kTRUE; } @@ -442,8 +440,9 @@ Double_t TKDTreeBinning::GetBinVolume(UInt_t bin) const { } const double * TKDTreeBinning::GetOneDimBinEdges() const { - // Returns the sorted minimum edges for one dimensional binning only. - // size of the vector is fNBins + 1 + // Returns the minimum edges for one dimensional binning only. + // size of the vector is fNBins + 1 is the vector has been sorted in increasing bin edges + // N.B : if one does not call SortOneDimBinEdges the bins are not ordered if (fDim == 1) { // no need to sort here because vector is already sorted in one dim return &fBinMinEdges.front(); @@ -453,6 +452,39 @@ const double * TKDTreeBinning::GetOneDimBinEdges() const { return 0; } +const Double_t * TKDTreeBinning::SortOneDimBinEdges(Bool_t sortAsc) { + if (fDim != 1) { + this->Warning("SortOneDimBinEdges", "Data is multidimensional. Cannot sorted bin edges. Returning null pointer."); + this->Info("SortOneDimBinEdges", "This method can only be invoked if the data is a one dimensional set"); + return 0; + } + // order bins by increasing (or decreasing ) x positions + std::vector<UInt_t> indices( fNBins ); + TMath::Sort( fNBins, &fBinMinEdges[0], &indices[0], !sortAsc ); + + std::vector<Double_t> binMinEdges(fNBins ); + std::vector<Double_t> binMaxEdges(fNBins ); + std::vector<UInt_t> binContent(fNBins ); // reajust also content (not needed but better in general!) + for (UInt_t i = 0; i < fNBins; ++i) { + binMinEdges[i ] = fBinMinEdges[indices[i] ]; + binMaxEdges[i ] = fBinMaxEdges[indices[i] ]; + binContent[i] = fBinsContent[indices[i] ]; + } + fBinMinEdges.swap(binMinEdges); + fBinMaxEdges.swap(binMaxEdges); + fBinsContent.swap(binContent); + + // Add also the upper(lower) edge to the min (max) list + if (sortAsc) { + fBinMinEdges.push_back(fBinMaxEdges.back()); + return &fBinMinEdges[0]; + } + fBinMaxEdges.push_back(fBinMinEdges.back()); + return &fBinMaxEdges[0]; + +} + + const Double_t* TKDTreeBinning::GetBinCenter(UInt_t bin) const { // Returns the geometric center of of the bin. 'bin' is between 0 and fNBins - 1 if(bin < fNBins) { @@ -515,6 +547,7 @@ UInt_t TKDTreeBinning::GetBinMinDensity() const { void TKDTreeBinning::FillBinData(ROOT::Fit::BinData & data) const { // Fill the bin data set with the result of the TKDTree binning + if (!fDataBins) return; data.Initialize(fNBins, fDim); for (unsigned int i = 0; i < fNBins; ++i) { data.Add( GetBinMinEdges(i), GetBinDensity(i), std::sqrt(double(GetBinContent(i) ))/ GetBinVolume(i) ); diff --git a/math/mathcore/src/TMath.cxx b/math/mathcore/src/TMath.cxx index 173d7e20a9806..cc3e3d4cf756f 100644 --- a/math/mathcore/src/TMath.cxx +++ b/math/mathcore/src/TMath.cxx @@ -100,42 +100,6 @@ Double_t TMath::Log2(Double_t x) return log(x)/log(2.0); } -//______________________________________________________________________________ -Int_t TMath::Nint(Float_t x) -{ - // Round to nearest integer. Rounds half integers to the nearest - // even integer. - - int i; - if (x >= 0) { - i = int(x + 0.5); - if (x + 0.5 == Float_t(i) && i & 1) i--; - } else { - i = int(x - 0.5); - if (x - 0.5 == Float_t(i) && i & 1) i++; - - } - return i; -} - -//______________________________________________________________________________ -Int_t TMath::Nint(Double_t x) -{ - // Round to nearest integer. Rounds half integers to the nearest - // even integer. - - int i; - if (x >= 0) { - i = int(x + 0.5); - if (x + 0.5 == Double_t(i) && i & 1) i--; - } else { - i = int(x - 0.5); - if (x - 0.5 == Double_t(i) && i & 1) i++; - - } - return i; -} - //______________________________________________________________________________ Double_t TMath::DiLog(Double_t x) { @@ -483,6 +447,8 @@ Double_t TMath::Gaus(Double_t x, Double_t mean, Double_t sigma, Bool_t norm) if (sigma == 0) return 1.e30; Double_t arg = (x-mean)/sigma; + // for |arg| > 39 result is zero in double precision + if (arg < -39.0 || arg > 39.0) return 0.0; Double_t res = TMath::Exp(-0.5*arg*arg); if (!norm) return res; return res/(2.50662827463100024*sigma); //sqrt(2*Pi)=2.50662827463100024 @@ -1231,14 +1197,16 @@ void TMath::Quantiles(Int_t n, Int_t nprob, Double_t *x, Double_t *quantiles, Do nppm = n*prob[i]; // use m = 0 j = TMath::FloorNint(nppm); + + // LM : fix for numerical problems if nppm is actually equal to j, but results different for numerical error // g in the paper is nppm -j - if (type == 1) - gamma = (nppm > j) ? 1 : 0; - else if (type == 2) - gamma = (nppm > j) ? 1 : 0.5; - else if (type == 3) - // gamma = 0 for g=0 and j even - gamma = (nppm == j && TMath::Even(j) ) ? 0 : 1; + if (type == 1) + gamma = ( (nppm -j) > j*TMath::Limits<Double_t>::Epsilon() ) ? 1 : 0; + else if (type == 2) + gamma = ( (nppm -j) > j*TMath::Limits<Double_t>::Epsilon() ) ? 1 : 0.5; + else if (type == 3) + // gamma = 0 for g=0 and j even + gamma = ( TMath::Abs(nppm -j) <= j*TMath::Limits<Double_t>::Epsilon() && TMath::Even(j) ) ? 0 : 1; } else { @@ -2092,8 +2060,8 @@ Double_t TMath::Binomial(Int_t n,Int_t k) { // Calculate the binomial coefficient n over k. + if (n<0 || k<0 || n<k) return TMath::SignalingNaN(); if (k==0 || n==k) return 1; - if (n<=0 || k<0 || n<k) return 0; Int_t k1=TMath::Min(k,n-k); Int_t k2=n-k1; diff --git a/math/mathcore/src/TRandom.cxx b/math/mathcore/src/TRandom.cxx index de3f4602f7b8a..9ba353af4ab7d 100644 --- a/math/mathcore/src/TRandom.cxx +++ b/math/mathcore/src/TRandom.cxx @@ -129,7 +129,7 @@ #include "TSystem.h" #include "TDirectory.h" #include "Math/QuantFuncMathCore.h" -#include <time.h> +#include "TUUID.h" ClassImp(TRandom) @@ -546,18 +546,17 @@ void TRandom::SetSeed(UInt_t seed) // Set the random generator seed. Note that default value is zero, which is // different than the default value used when constructing the class. // If the seed is zero the seed is set to a random value - // which in case of TRandom depends on the machine clock. - // Note that the machine clock is returned with a precision of 1 second. - // If one calls SetSeed(0) within a loop and the loop time is less than 1s, - // all generated numbers will be identical! + // which in case of TRandom depends on the lowest 4 bytes of TUUID + // The UUID will be identical if SetSeed(0) is called with time smaller than 100 ns // Instead if a different generator implementation is used (TRandom1, 2 or 3) // the seed is generated using a 128 bit UUID. This results in different seeds // and then random sequence for every SetSeed(0) call. if( seed==0 ) { - time_t curtime; // Set 'random' seed number if seed=0 - time(&curtime); // Get current time in fSeed. - fSeed = (UInt_t)curtime; + TUUID u; + UChar_t uuid[16]; + u.GetUUID(uuid); + fSeed = int(uuid[3])*16777216 + int(uuid[2])*65536 + int(uuid[1])*256 + int(uuid[0]); } else { fSeed = seed; } diff --git a/math/mathcore/src/TRandom1.cxx b/math/mathcore/src/TRandom1.cxx index 2e8a2056613ba..f7a9339659cb4 100644 --- a/math/mathcore/src/TRandom1.cxx +++ b/math/mathcore/src/TRandom1.cxx @@ -268,11 +268,13 @@ TRandom1::TRandom1(UInt_t seed, Int_t lux) fTheSeeds = &fSeed; fLuxury = lux; SetSeed2(seed, fLuxury); - - // setSeeds() wants a zero terminated array! - seedlist[0]=fSeed; - seedlist[1]=0; - SetSeeds(seedlist, fLuxury); + // in case seed = 0 SetSeed2 calls already SetSeeds + if (seed != 0) { + // setSeeds() wants a zero terminated array! + seedlist[0]=fSeed; + seedlist[1]=0; + SetSeeds(seedlist, fLuxury); + } } //______________________________________________________________________________ @@ -550,10 +552,15 @@ void TRandom1::SetSeed2(UInt_t seed, int lux) UInt_t int_seed_table[24]; // case of seed == 0 - // use a random seed based on TRandom3(0) which is base don the UUID + // use a random seed based on TRandom2(0) which is based on the UUID if (seed == 0) { - TRandom3 r3(0); - seed = static_cast<UInt_t> (4294967296.*r3.Rndm()); + UInt_t randSeeds[25]; + TRandom3 r2(0); + for (int j = 0; j < 24; ++j) + randSeeds[j] = static_cast<UInt_t> (4294967296.*r2.Rndm()); + randSeeds[24] = 0; + SetSeeds(randSeeds, lux); + return; } diff --git a/math/mathcore/src/TRandom2.cxx b/math/mathcore/src/TRandom2.cxx index 8fc76bcc61e13..d1f32c32a7aee 100644 --- a/math/mathcore/src/TRandom2.cxx +++ b/math/mathcore/src/TRandom2.cxx @@ -22,6 +22,7 @@ #include "TRandom2.h" #include "TRandom3.h" +#include "TUUID.h" ClassImp(TRandom2) @@ -125,11 +126,23 @@ void TRandom2::SetSeed(UInt_t seed) fSeed2 = LCG (fSeed1); if (fSeed2 < 16) fSeed2 += 16UL; } else { - // initialize using TRandom3 which uses a UUID - TRandom3 r3(0); - fSeed = static_cast<UInt_t> (4294967296.*r3.Rndm()); - fSeed1 = static_cast<UInt_t> (4294967296.*r3.Rndm()); - fSeed2 = static_cast<UInt_t> (4294967296.*r3.Rndm()); + // initialize using a TUUID + TUUID u; + UChar_t uuid[16]; + u.GetUUID(uuid); + fSeed = int(uuid[3])*16777216 + int(uuid[2])*65536 + int(uuid[1])*256 + int(uuid[0]); + fSeed1 = int(uuid[7])*16777216 + int(uuid[6])*65536 + int(uuid[5])*256 + int(uuid[4]); + fSeed2 = int(uuid[11])*16777216 + int(uuid[10])*65536 + int(uuid[9])*256 + int(uuid[8]); + // use also the other bytes + UInt_t seed3 = int(uuid[15])*16777216 + int(uuid[14])*65536 + int(uuid[13])*256 + int(uuid[12]); + fSeed2 += seed3; + + + + // TRandom r3(0); + // fSeed = static_cast<UInt_t> (4294967296.*r3.Rndm()); + // fSeed1 = static_cast<UInt_t> (4294967296.*r3.Rndm()); + // fSeed2 = static_cast<UInt_t> (4294967296.*r3.Rndm()); if (fSeed < 2) fSeed += 2UL; if (fSeed1 < 8) fSeed1 += 8UL; diff --git a/math/mathcore/src/TRandom3.cxx b/math/mathcore/src/TRandom3.cxx index 0c74e8b1157fd..8f3216e423047 100644 --- a/math/mathcore/src/TRandom3.cxx +++ b/math/mathcore/src/TRandom3.cxx @@ -44,6 +44,7 @@ ///////////////////////////////////////////////////////////////////// #include "TRandom3.h" +#include "TRandom2.h" #include "TClass.h" #include "TUUID.h" @@ -194,24 +195,28 @@ void TRandom3::SetSeed(UInt_t seed) TRandom::SetSeed(seed); fCount624 = 624; - Int_t i,j; if (seed > 0) { fMt[0] = fSeed; - j = 1; + + // use multipliers from Knuth's "Art of Computer Programming" Vol. 2, 3rd Ed. p.106 + for(Int_t i=1; i<624; i++) { + fMt[i] = (1812433253 * ( fMt[i-1] ^ ( fMt[i-1] >> 30)) + i ); + } + } else { - TUUID uid; - UChar_t uuid[16]; - uid.GetUUID(uuid); - for (i=0;i<8;i++) { - fMt[i] = uuid[2*i]*256 +uuid[2*i+1]; - if (i > 1) fMt[i] += fMt[0]; + + // use TRandom2 (which is based on TUUId to generate the seed + // TRandom2 works fairly well and has been tested against example + // layout in https://savannah.cern.ch/bugs/?99516 + TRandom2 r(0); + for (Int_t i = 0; i< 624; i++) { + fMt[i] = static_cast<UInt_t> (4294967296.*r.Rndm()); } - j = 8; - } - // use multipliers from Knuth's "Art of Computer Programming" Vol. 2, 3rd Ed. p.106 - for(i=j; i<624; i++) { - fMt[i] = (1812433253 * ( fMt[i-1] ^ ( fMt[i-1] >> 30)) + i); + // warm up the generator calling it 10 times + for (Int_t i = 0; i < 10; ++i) Rndm(); } + + } //______________________________________________________________________________ diff --git a/math/mathcore/src/TStatistic.cxx b/math/mathcore/src/TStatistic.cxx index 0bd061c2c9a67..fe73b90999776 100644 --- a/math/mathcore/src/TStatistic.cxx +++ b/math/mathcore/src/TStatistic.cxx @@ -39,4 +39,4 @@ TStatistic::TStatistic(const char *name, Int_t n, const Double_t *val, const Dou } } } -} \ No newline at end of file +} diff --git a/math/mathcore/test/fit/Makefile b/math/mathcore/test/fit/Makefile index efa4834395a4f..c4c31a4c4844e 100644 --- a/math/mathcore/test/fit/Makefile +++ b/math/mathcore/test/fit/Makefile @@ -6,9 +6,24 @@ # # Author: Fons Rademakers, 29/2/2000 -ROOTSYS = ../../../.. -include $(ROOTSYS)/config/Makefile.config + +RC := root-config +ifeq ($(shell which $(RC) 2>&1 | sed -ne "s@.*/$(RC)@$(RC)@p"),$(RC)) +MKARCH := $(wildcard $(shell $(RC) --etcdir)/Makefile.arch) +RCONFIG := $(wildcard $(shell $(RC) --incdir)/RConfigure.h) +endif +ifneq ($(MKARCH),) +include $(MKARCH) +else +ifeq ($(ROOTSYS),) +ROOTSYS = .. +endif include $(ROOTSYS)/etc/Makefile.arch +endif + +#ROOTSYS = ../../../.. +#include $(ROOTSYS)/config/Makefile.config +#include $(ROOTSYS)/etc/Makefile.arch #------------------------------------------------------------------------------ @@ -44,8 +59,8 @@ TESTMINIMOBJ = testMinim.$(ObjSuf) TESTMINIMSRC = testMinim.$(SrcSuf) TESTMINIM = testMinim$(ExeSuf) -ifeq ($(shell $(ROOTCONFIG) --has-mathmore),yes) -ifeq ($(shell $(ROOTCONFIG) --has-roofit),yes) +ifeq ($(shell $(RC) --has-mathmore),yes) +ifeq ($(shell $(RC) --has-roofit),yes) TESTPERFOBJ = testFitPerf.$(ObjSuf) TESTPERFSRC = testFitPerf.$(SrcSuf) diff --git a/math/mathcore/test/fit/SparseFit3.cxx b/math/mathcore/test/fit/SparseFit3.cxx index d5dfbb1b6627f..bb65e28db2a30 100644 --- a/math/mathcore/test/fit/SparseFit3.cxx +++ b/math/mathcore/test/fit/SparseFit3.cxx @@ -1,471 +1,471 @@ -#include "TH2.h" -#include "TH3.h" -#include "TF2.h" -#include "TF3.h" -#include "TCanvas.h" -#include "TApplication.h" -#include "TMath.h" - -#include "Fit/SparseData.h" -#include "HFitInterface.h" -#include "Fit/Fitter.h" -#include "Math/WrappedMultiTF1.h" - -#include "TRandom.h" - -#include <iostream> -#include <iterator> -#include <algorithm> - -#include <list> -#include <vector> - -#include <cmath> -#include <cassert> - -using namespace std; - -const bool __DRAW__ = 1; - -double gaus2D(double *x, double *p) -{ - return p[0]*TMath::Gaus(x[0],p[1],p[2]) * TMath::Gaus(x[1],p[3],p[4]); -} - -double gaus3D(double *x, double *p) -{ - return p[0] * TMath::Gaus(x[0],p[1],p[2]) - * TMath::Gaus(x[1],p[3],p[4]) - * TMath::Gaus(x[2],p[5],p[6]); -} - -double pol2D(double *x, double *p) -{ - return p[0]*x[0]+ p[1]*x[0]*x[0] + p[2]*x[1] + p[3]*x[1]*x[1] + p[4]; -} - -ostream& operator << (ostream& out, ROOT::Fit::BinData& bd) -{ - const unsigned int ndim( bd.NDim() ); - const unsigned int npoints( bd.NPoints() ); - for ( unsigned int i = 0; i < npoints; ++i ) - { - double value, error; - const double *x = bd.GetPoint(i, value, error); - for ( unsigned int j = 0; j < ndim; ++j ) - { - out << " x[" << j << "]: " << x[j]; - } - out << " value: " << value; - out << " error: " << error; - out << endl; - } - return out; -} - -int findBin(ROOT::Fit::BinData& bd, const double *x) -{ - const unsigned int ndim = bd.NDim(); - const unsigned int npoints = bd.NPoints(); - - for ( unsigned int i = 0; i < npoints; ++i ) - { - double value1, error1; - const double *x1 = bd.GetPoint(i, value1, error1); - bool thisIsIt = true; - for ( unsigned int j = 0; j < ndim; ++j ) - { - thisIsIt &= fabs(x1[j] - x[j]) < 1E-15; - } - if ( thisIsIt ) return i; - } - - cout << "NO ENCONTRADO!"; - copy(x, x+ndim, ostream_iterator<double>(cout, " " )); - cout << endl; - - return -1; -} - -bool operator ==(ROOT::Fit::BinData& bd1, ROOT::Fit::BinData& bd2) -{ - const unsigned int ndim = bd1.NDim(); - const unsigned int npoints = bd1.NPoints(); - - bool equals = true; - - cout << "Equals" << endl; - - for ( unsigned int i = 0; i < npoints && equals; ++i ) - { - double value1, error1; - const double *x1 = bd1.GetPoint(i, value1, error1); - - int bin = findBin(bd2, x1); - - double value2 = 0, error2; - const double *x2 = bd2.GetPoint(bin, value2, error2); - - equals &= ( value1 == value2 ); - cout << " v: " << equals; - equals &= ( error1 == error2 ); - cout << " e: " << equals; - for ( unsigned int j = 0; j < ndim; ++j ) - { - equals &= fabs(x1[j] - x2[j]) < 1E-15; - cout << " x[" << j << "]: " << equals; - } - - cout << " bd1: "; - std::copy(x1, &x1[ndim], ostream_iterator<double>(cout, " ")); - cout << " value:" << value1; - cout << " error:" << error1; - - cout << " bd2: "; - std::copy(x2, &x2[ndim], ostream_iterator<double>(cout, " ")); - cout << " value:" << value2; - cout << " error:" << error2; - - cout << " equals: " << equals; - - cout << endl; - } - - return equals; -} - -void fit3DHist() -{ - vector<double> min(3); min[0] = 0.; min[1] = 0.; min[2] = 0.; - vector<double> max(3); max[0] = 10.; max[1] = 10.; max[2] = 10.; - vector<int> nbins(3); nbins[0] = 10; nbins[1] = 10; nbins[2] = 10; - - TH3D* h1 = new TH3D("3D Original Hist Fit", "h1-title", - nbins[0], min[0], max[0], - nbins[1], min[1], max[1], - nbins[2], min[2], max[2]); - TH3D* h2 = new TH3D("3D Blanked Hist Fit", "h1-title", - nbins[0], min[0], max[0], - nbins[1], min[1], max[1], - nbins[2], min[2], max[2]); - - TF3* f1 = new TF3("func3D", gaus3D, - min[0],max[0], - min[1],max[1], - min[2],max[2], - 7); - double initialPars[] = {20,5,2,5,1,5,2}; -// TF1* f1 = new TF1("func3D", pol2D, -// min[0],max[0], min[1], max[1], 5); -// double initialPars[] = {1,0.,0.5,0.,0.}; - f1->SetParameters(initialPars); -// f1->FixParameter(1,0.); -// f1->FixParameter(3,0.); - - - for (int ix=1; ix <= h1->GetNbinsX(); ++ix) { - for (int iy=1; iy <= h1->GetNbinsY(); ++iy) { - for (int iz=1; iz <= h1->GetNbinsZ(); ++iz) { - double x = h1->GetXaxis()->GetBinCenter(ix); - double y = h1->GetYaxis()->GetBinCenter(iy); - double z = h1->GetZaxis()->GetBinCenter(iz); - - h1->SetBinContent( ix, iy, iz, gRandom->Poisson( f1->Eval(x,y,z) ) ); - } - } - } - -///////////////// CREATE THE SPARSE DATA - cout << "Retrieving the Sparse Data Structure" << endl; - ROOT::Fit::SparseData d(min,max); - ROOT::Fit::FillData(d, h1, 0); - ROOT::Fit::BinData bd; - d.GetBinData(bd); - - - cout << "Filling second histogram" << endl; - for ( unsigned int i = 0; i < bd.NPoints(); ++i ) - { - const double* x; - double value, error; - x = bd.GetPoint(i, value, error); - value = (value)?value:-10; - h2->Fill(x[0], x[1], x[2], value); - } - - - ///////////////// FITS - // Fit preparation - bool ret; - ROOT::Fit::Fitter fitter; - ROOT::Math::WrappedMultiTF1 wf1(*f1); - ROOT::Math::IParametricFunctionMultiDim & if1 = wf1; - fitter.Config().SetMinimizer("Minuit2"); - //fitter.Config().MinimizerOptions().SetPrintLevel(3); - - ///////////////////////////////////////////////////////////////////////// - cout << "\n ******* Chi2Fit with Original BinData *******" << endl; - ROOT::Fit::BinData bdOriginal; - ROOT::Fit::FillData(bdOriginal, h1, 0); - ret = fitter.LikelihoodFit(bdOriginal, if1); - fitter.Result().Print(std::cout); - if (!ret) - std::cout << "Fit Failed " << std::endl; - - ///////////////////////////////////////////////////////////////////////// - cout << "\n ******* Chi2Fit with Original BinData with Ceros*******" << endl; - ROOT::Fit::DataOptions opt; - opt.fUseEmpty = true; - opt.fIntegral = true; - ROOT::Fit::BinData bdOriginalWithCeros(opt); - ROOT::Fit::FillData(bdOriginalWithCeros, h1, 0); - ret = fitter.LikelihoodFit(bdOriginalWithCeros, if1); - fitter.Result().Print(std::cout); - if (!ret) - std::cout << "Fit Failed " << std::endl; - - ///////////////////////////////////////////////////////////////////////// - cout << "\n ******* Chi2Fit with BinData and NoCeros *******" << endl; - ROOT::Fit::BinData bdNoCeros; - d.GetBinDataNoZeros(bdNoCeros); - ret = fitter.LikelihoodFit(bdNoCeros, if1); - fitter.Result().Print(std::cout); - if (!ret) - std::cout << "Fit Failed " << std::endl; - -// cout << "bdOriginal:\n" << bdOriginal << endl; -// cout << "bdNoCeros:\n" << *bdNoCeros << endl; -// cout << "Equals: " << (bdOriginal == *bdNoCeros) << endl; - ///////////////////////////////////////////////////////////////////////// - cout << "\n ******* Chi2Fit with BinData with Ceros *******" << endl; - ROOT::Fit::BinData bdWithCeros(opt); - d.GetBinDataIntegral(bdWithCeros); - ret = fitter.LikelihoodFit(bdWithCeros, if1); - fitter.Result().Print(std::cout); - if (!ret) - std::cout << "Fit Failed " << std::endl; - -// cout << "bdOriginal:\n" << bdOriginal << endl; -// cout << "bdWithCeros:\n" << bdWithCeros << endl; -// cout << "Equals: " << (bdOriginal == bdWithCeros) << endl; - - ///////////////////////////////////////////////////////////////////////// - - - TCanvas* c = new TCanvas("Histogram 3D"); - c->Divide(1,2); - c->cd(1); - h1->Draw("lego"); - c->cd(2); - h2->Draw("lego"); -} - -void fit2DHist() -{ - vector<double> min(2); min[0] = 0.; min[1] = 0.; - vector<double> max(2); max[0] = 10.; max[1] = 10.; - vector<int> nbins(2); nbins[0] = 10; nbins[1] = 10; - - TH2D* h1 = new TH2D("2D Original Hist Fit", "h1-title", nbins[0], min[0], max[0], nbins[1], min[1], max[1]); - TH2D* h2 = new TH2D("2D Blanked Hist Fit", "h1-title", nbins[0], min[0], max[0], nbins[1], min[1], max[1]); - - TF2* f2 = new TF2("func2D", gaus2D, - min[0],max[0], min[1], max[1], 5); - double initialPars[] = {20,5,2,5,1}; -// TF2* f2 = new TF2("func2D", pol2D, -// min[0],max[0], min[1], max[1], 5); -// double initialPars[] = {1,0.,0.5,0.,0.}; - f2->SetParameters(initialPars); -// f2->FixParameter(1,0.); -// f2->FixParameter(3,0.); - - - for (int ix=1; ix <= h1->GetNbinsX(); ++ix) { - for (int iy=1; iy <= h1->GetNbinsY(); ++iy) { - double x= h1->GetXaxis()->GetBinCenter(ix); - double y= h1->GetYaxis()->GetBinCenter(iy); - - h1->SetBinContent( ix, iy, gRandom->Poisson( f2->Eval(x,y) ) ); - } - } - -///////////////// CREATE THE SPARSE DATA - cout << "Retrieving the Sparse Data Structure" << endl; - ROOT::Fit::SparseData d(min,max); - ROOT::Fit::FillData(d, h1, 0); - ROOT::Fit::BinData bd; - d.GetBinData(bd); - - - cout << "Filling second histogram" << endl; - for ( unsigned int i = 0; i < bd.NPoints(); ++i ) - { - const double* x; - double value, error; - x = bd.GetPoint(i, value, error); - value = (value)?value:-10; - h2->Fill(x[0], x[1], value); - } - - ///////////////// FITS - // Fit preparation - bool ret; - ROOT::Fit::Fitter fitter; - ROOT::Math::WrappedMultiTF1 wf2(*f2); - ROOT::Math::IParametricFunctionMultiDim & if2 = wf2; - fitter.Config().SetMinimizer("Minuit2"); - //fitter.Config().MinimizerOptions().SetPrintLevel(3); - - ///////////////////////////////////////////////////////////////////////// - cout << "\n ******* Chi2Fit with Original BinData *******" << endl; - ROOT::Fit::BinData bdOriginal; - ROOT::Fit::FillData(bdOriginal, h1, 0); - ret = fitter.LikelihoodFit(bdOriginal, if2); - fitter.Result().Print(std::cout); - if (!ret) - std::cout << "Fit Failed " << std::endl; - - ///////////////////////////////////////////////////////////////////////// - cout << "\n ******* Chi2Fit with Original BinData with Ceros*******" << endl; - ROOT::Fit::DataOptions opt; - opt.fUseEmpty = true; - opt.fIntegral = true; - ROOT::Fit::BinData bdOriginalWithCeros(opt); - ROOT::Fit::FillData(bdOriginalWithCeros, h1, 0); - ret = fitter.LikelihoodFit(bdOriginalWithCeros, if2); - fitter.Result().Print(std::cout); - if (!ret) - std::cout << "Fit Failed " << std::endl; - - ///////////////////////////////////////////////////////////////////////// - cout << "\n ******* Chi2Fit with BinData and NoCeros *******" << endl; - ROOT::Fit::BinData bdNoCeros; - d.GetBinDataNoZeros(bdNoCeros); - ret = fitter.LikelihoodFit(bdNoCeros, if2); - fitter.Result().Print(std::cout); - if (!ret) - std::cout << "Fit Failed " << std::endl; - -// cout << "bdOriginal:\n" << bdOriginal << endl; -// cout << "bdNoCeros:\n" << *bdNoCeros << endl; -// cout << "Equals: " << (bdOriginal == *bdNoCeros) << endl; - ///////////////////////////////////////////////////////////////////////// - cout << "\n ******* Chi2Fit with BinData with Ceros *******" << endl; - ROOT::Fit::BinData bdWithCeros(opt); - d.GetBinDataIntegral(bdWithCeros); - ret = fitter.LikelihoodFit(bdWithCeros, if2); - fitter.Result().Print(std::cout); - if (!ret) - std::cout << "Fit Failed " << std::endl; - -// cout << "bdOriginal:\n" << bdOriginal << endl; -// cout << "bdWithCeros:\n" << *bdWithCeros << endl; -// cout << "Equals: " << (bdOriginal == *bdWithCeros) << endl; - - ///////////////////////////////////////////////////////////////////////// - - - TCanvas* c = new TCanvas("Histogram 2D"); - c->Divide(2,2); - c->cd(1); - h1->Draw("colz"); - c->cd(2); - h1->Draw("text"); - c->cd(3); - h2->Draw("colz"); - c->cd(4); - h2->Draw("text"); -} - -// void fit1DHist() -// { -// vector<double> min(1); -// min[0] = 0.; - -// vector<double> max(1); -// max[0] = 10.; - -// vector<int> nbins(1); -// nbins[0] = 10; - -// TH1D* h1 = new TH1D("1D Original Hist Fit", "h1-Original", nbins[0], min[0], max[0]); -// TH1D* h2 = new TH1D("1D Blanked Hist Fit", "h1-Blanked", nbins[0], min[0], max[0]); - -// TF1* f1 = new TF1("MyGaus", "[0]*TMath::Gaus([1],[2])", min[0], max[0]); -// f1->SetParameters(10., 5., 2.); - -// h1->FillRandom("MyGaus",1000); - -// cout << "Retrieving the Sparse Data Structure" << endl; -// ROOT::Fit::SparseData d(h1); -// ROOT::Fit::FillData(d, h1, 0); -// ROOT::Fit::BinData* bd = d.GetBinData(); - -// cout << "Filling second histogram" << endl; -// for ( unsigned int i = 0; i < bd->NPoints(); ++i) -// { -// const double* x; -// double value, error; -// x = bd->GetPoint(i, value, error); -// value = (value)?value:-10; -// h2->Fill(x[0], value); -// } - -// TCanvas* c = new TCanvas("Histogram 2D"); -// c->Divide(1,2); -// c->cd(1); -// h1->Draw("lego2Z"); -// c->cd(2); -// h2->Draw("lego2Z"); - -// // Fit preparation -// bool ret; -// ROOT::Fit::Fitter fitter; -// ROOT::Math::WrappedMultiTF1 wf1(*f1); -// fitter.Config().SetMinimizer("TMinuit"); - -// cout << "\n ******* Chi2Fit with Original BinData *******" << endl; -// ROOT::Fit::BinData bdOriginal; -// ROOT::Fit::FillData(bdOriginal, h1, 0); -// ret = fitter.Fit(bdOriginal, wf1); -// fitter.Result().Print(std::cout); -// if (!ret) -// std::cout << "Fit Failed " << std::endl; - -// cout << "\n ******* Chi2Fit with BinData and NoCeros *******" << endl; -// ROOT::Fit::BinData* bdNoCeros = d.GetBinDataNoCeros(); - -// cout << "bdOriginal:\n" << bdOriginal << endl; -// cout << "bdNoCeros:\n" << *bdNoCeros << endl; - -// cout << "Equals: " << (bdOriginal == *bdNoCeros) << endl; - -// ret = fitter.Fit(*bdNoCeros, wf1); -// fitter.Result().Print(std::cout); -// if (!ret) -// std::cout << "Fit Failed " << std::endl; - - -// delete bd; -// } - - int main(int argc, char** argv) -{ - TApplication* theApp = 0; - - if ( __DRAW__ ) - theApp = new TApplication("App",&argc,argv); - - fit3DHist(); -// fit2DHist(); -// fit1DHist(); - - if ( __DRAW__ ) { - theApp->Run(); - delete theApp; - theApp = 0; - } - - return 0; -} - +#include "TH2.h" +#include "TH3.h" +#include "TF2.h" +#include "TF3.h" +#include "TCanvas.h" +#include "TApplication.h" +#include "TMath.h" + +#include "Fit/SparseData.h" +#include "HFitInterface.h" +#include "Fit/Fitter.h" +#include "Math/WrappedMultiTF1.h" + +#include "TRandom.h" + +#include <iostream> +#include <iterator> +#include <algorithm> + +#include <list> +#include <vector> + +#include <cmath> +#include <cassert> + +using namespace std; + +const bool __DRAW__ = 1; + +double gaus2D(double *x, double *p) +{ + return p[0]*TMath::Gaus(x[0],p[1],p[2]) * TMath::Gaus(x[1],p[3],p[4]); +} + +double gaus3D(double *x, double *p) +{ + return p[0] * TMath::Gaus(x[0],p[1],p[2]) + * TMath::Gaus(x[1],p[3],p[4]) + * TMath::Gaus(x[2],p[5],p[6]); +} + +double pol2D(double *x, double *p) +{ + return p[0]*x[0]+ p[1]*x[0]*x[0] + p[2]*x[1] + p[3]*x[1]*x[1] + p[4]; +} + +ostream& operator << (ostream& out, ROOT::Fit::BinData& bd) +{ + const unsigned int ndim( bd.NDim() ); + const unsigned int npoints( bd.NPoints() ); + for ( unsigned int i = 0; i < npoints; ++i ) + { + double value, error; + const double *x = bd.GetPoint(i, value, error); + for ( unsigned int j = 0; j < ndim; ++j ) + { + out << " x[" << j << "]: " << x[j]; + } + out << " value: " << value; + out << " error: " << error; + out << endl; + } + return out; +} + +int findBin(ROOT::Fit::BinData& bd, const double *x) +{ + const unsigned int ndim = bd.NDim(); + const unsigned int npoints = bd.NPoints(); + + for ( unsigned int i = 0; i < npoints; ++i ) + { + double value1, error1; + const double *x1 = bd.GetPoint(i, value1, error1); + bool thisIsIt = true; + for ( unsigned int j = 0; j < ndim; ++j ) + { + thisIsIt &= fabs(x1[j] - x[j]) < 1E-15; + } + if ( thisIsIt ) return i; + } + + cout << "NO ENCONTRADO!"; + copy(x, x+ndim, ostream_iterator<double>(cout, " " )); + cout << endl; + + return -1; +} + +bool operator ==(ROOT::Fit::BinData& bd1, ROOT::Fit::BinData& bd2) +{ + const unsigned int ndim = bd1.NDim(); + const unsigned int npoints = bd1.NPoints(); + + bool equals = true; + + cout << "Equals" << endl; + + for ( unsigned int i = 0; i < npoints && equals; ++i ) + { + double value1, error1; + const double *x1 = bd1.GetPoint(i, value1, error1); + + int bin = findBin(bd2, x1); + + double value2 = 0, error2; + const double *x2 = bd2.GetPoint(bin, value2, error2); + + equals &= ( value1 == value2 ); + cout << " v: " << equals; + equals &= ( error1 == error2 ); + cout << " e: " << equals; + for ( unsigned int j = 0; j < ndim; ++j ) + { + equals &= fabs(x1[j] - x2[j]) < 1E-15; + cout << " x[" << j << "]: " << equals; + } + + cout << " bd1: "; + std::copy(x1, &x1[ndim], ostream_iterator<double>(cout, " ")); + cout << " value:" << value1; + cout << " error:" << error1; + + cout << " bd2: "; + std::copy(x2, &x2[ndim], ostream_iterator<double>(cout, " ")); + cout << " value:" << value2; + cout << " error:" << error2; + + cout << " equals: " << equals; + + cout << endl; + } + + return equals; +} + +void fit3DHist() +{ + vector<double> min(3); min[0] = 0.; min[1] = 0.; min[2] = 0.; + vector<double> max(3); max[0] = 10.; max[1] = 10.; max[2] = 10.; + vector<int> nbins(3); nbins[0] = 10; nbins[1] = 10; nbins[2] = 10; + + TH3D* h1 = new TH3D("3D Original Hist Fit", "h1-title", + nbins[0], min[0], max[0], + nbins[1], min[1], max[1], + nbins[2], min[2], max[2]); + TH3D* h2 = new TH3D("3D Blanked Hist Fit", "h1-title", + nbins[0], min[0], max[0], + nbins[1], min[1], max[1], + nbins[2], min[2], max[2]); + + TF3* f1 = new TF3("func3D", gaus3D, + min[0],max[0], + min[1],max[1], + min[2],max[2], + 7); + double initialPars[] = {20,5,2,5,1,5,2}; +// TF1* f1 = new TF1("func3D", pol2D, +// min[0],max[0], min[1], max[1], 5); +// double initialPars[] = {1,0.,0.5,0.,0.}; + f1->SetParameters(initialPars); +// f1->FixParameter(1,0.); +// f1->FixParameter(3,0.); + + + for (int ix=1; ix <= h1->GetNbinsX(); ++ix) { + for (int iy=1; iy <= h1->GetNbinsY(); ++iy) { + for (int iz=1; iz <= h1->GetNbinsZ(); ++iz) { + double x = h1->GetXaxis()->GetBinCenter(ix); + double y = h1->GetYaxis()->GetBinCenter(iy); + double z = h1->GetZaxis()->GetBinCenter(iz); + + h1->SetBinContent( ix, iy, iz, gRandom->Poisson( f1->Eval(x,y,z) ) ); + } + } + } + +///////////////// CREATE THE SPARSE DATA + cout << "Retrieving the Sparse Data Structure" << endl; + ROOT::Fit::SparseData d(min,max); + ROOT::Fit::FillData(d, h1, 0); + ROOT::Fit::BinData bd; + d.GetBinData(bd); + + + cout << "Filling second histogram" << endl; + for ( unsigned int i = 0; i < bd.NPoints(); ++i ) + { + const double* x; + double value, error; + x = bd.GetPoint(i, value, error); + value = (value)?value:-10; + h2->Fill(x[0], x[1], x[2], value); + } + + + ///////////////// FITS + // Fit preparation + bool ret; + ROOT::Fit::Fitter fitter; + ROOT::Math::WrappedMultiTF1 wf1(*f1); + ROOT::Math::IParametricFunctionMultiDim & if1 = wf1; + fitter.Config().SetMinimizer("Minuit2"); + //fitter.Config().MinimizerOptions().SetPrintLevel(3); + + ///////////////////////////////////////////////////////////////////////// + cout << "\n ******* Chi2Fit with Original BinData *******" << endl; + ROOT::Fit::BinData bdOriginal; + ROOT::Fit::FillData(bdOriginal, h1, 0); + ret = fitter.LikelihoodFit(bdOriginal, if1); + fitter.Result().Print(std::cout); + if (!ret) + std::cout << "Fit Failed " << std::endl; + + ///////////////////////////////////////////////////////////////////////// + cout << "\n ******* Chi2Fit with Original BinData with Ceros*******" << endl; + ROOT::Fit::DataOptions opt; + opt.fUseEmpty = true; + opt.fIntegral = true; + ROOT::Fit::BinData bdOriginalWithCeros(opt); + ROOT::Fit::FillData(bdOriginalWithCeros, h1, 0); + ret = fitter.LikelihoodFit(bdOriginalWithCeros, if1); + fitter.Result().Print(std::cout); + if (!ret) + std::cout << "Fit Failed " << std::endl; + + ///////////////////////////////////////////////////////////////////////// + cout << "\n ******* Chi2Fit with BinData and NoCeros *******" << endl; + ROOT::Fit::BinData bdNoCeros; + d.GetBinDataNoZeros(bdNoCeros); + ret = fitter.LikelihoodFit(bdNoCeros, if1); + fitter.Result().Print(std::cout); + if (!ret) + std::cout << "Fit Failed " << std::endl; + +// cout << "bdOriginal:\n" << bdOriginal << endl; +// cout << "bdNoCeros:\n" << *bdNoCeros << endl; +// cout << "Equals: " << (bdOriginal == *bdNoCeros) << endl; + ///////////////////////////////////////////////////////////////////////// + cout << "\n ******* Chi2Fit with BinData with Ceros *******" << endl; + ROOT::Fit::BinData bdWithCeros(opt); + d.GetBinDataIntegral(bdWithCeros); + ret = fitter.LikelihoodFit(bdWithCeros, if1); + fitter.Result().Print(std::cout); + if (!ret) + std::cout << "Fit Failed " << std::endl; + +// cout << "bdOriginal:\n" << bdOriginal << endl; +// cout << "bdWithCeros:\n" << bdWithCeros << endl; +// cout << "Equals: " << (bdOriginal == bdWithCeros) << endl; + + ///////////////////////////////////////////////////////////////////////// + + + TCanvas* c = new TCanvas("Histogram 3D"); + c->Divide(1,2); + c->cd(1); + h1->Draw("lego"); + c->cd(2); + h2->Draw("lego"); +} + +void fit2DHist() +{ + vector<double> min(2); min[0] = 0.; min[1] = 0.; + vector<double> max(2); max[0] = 10.; max[1] = 10.; + vector<int> nbins(2); nbins[0] = 10; nbins[1] = 10; + + TH2D* h1 = new TH2D("2D Original Hist Fit", "h1-title", nbins[0], min[0], max[0], nbins[1], min[1], max[1]); + TH2D* h2 = new TH2D("2D Blanked Hist Fit", "h1-title", nbins[0], min[0], max[0], nbins[1], min[1], max[1]); + + TF2* f2 = new TF2("func2D", gaus2D, + min[0],max[0], min[1], max[1], 5); + double initialPars[] = {20,5,2,5,1}; +// TF2* f2 = new TF2("func2D", pol2D, +// min[0],max[0], min[1], max[1], 5); +// double initialPars[] = {1,0.,0.5,0.,0.}; + f2->SetParameters(initialPars); +// f2->FixParameter(1,0.); +// f2->FixParameter(3,0.); + + + for (int ix=1; ix <= h1->GetNbinsX(); ++ix) { + for (int iy=1; iy <= h1->GetNbinsY(); ++iy) { + double x= h1->GetXaxis()->GetBinCenter(ix); + double y= h1->GetYaxis()->GetBinCenter(iy); + + h1->SetBinContent( ix, iy, gRandom->Poisson( f2->Eval(x,y) ) ); + } + } + +///////////////// CREATE THE SPARSE DATA + cout << "Retrieving the Sparse Data Structure" << endl; + ROOT::Fit::SparseData d(min,max); + ROOT::Fit::FillData(d, h1, 0); + ROOT::Fit::BinData bd; + d.GetBinData(bd); + + + cout << "Filling second histogram" << endl; + for ( unsigned int i = 0; i < bd.NPoints(); ++i ) + { + const double* x; + double value, error; + x = bd.GetPoint(i, value, error); + value = (value)?value:-10; + h2->Fill(x[0], x[1], value); + } + + ///////////////// FITS + // Fit preparation + bool ret; + ROOT::Fit::Fitter fitter; + ROOT::Math::WrappedMultiTF1 wf2(*f2); + ROOT::Math::IParametricFunctionMultiDim & if2 = wf2; + fitter.Config().SetMinimizer("Minuit2"); + //fitter.Config().MinimizerOptions().SetPrintLevel(3); + + ///////////////////////////////////////////////////////////////////////// + cout << "\n ******* Chi2Fit with Original BinData *******" << endl; + ROOT::Fit::BinData bdOriginal; + ROOT::Fit::FillData(bdOriginal, h1, 0); + ret = fitter.LikelihoodFit(bdOriginal, if2); + fitter.Result().Print(std::cout); + if (!ret) + std::cout << "Fit Failed " << std::endl; + + ///////////////////////////////////////////////////////////////////////// + cout << "\n ******* Chi2Fit with Original BinData with Ceros*******" << endl; + ROOT::Fit::DataOptions opt; + opt.fUseEmpty = true; + opt.fIntegral = true; + ROOT::Fit::BinData bdOriginalWithCeros(opt); + ROOT::Fit::FillData(bdOriginalWithCeros, h1, 0); + ret = fitter.LikelihoodFit(bdOriginalWithCeros, if2); + fitter.Result().Print(std::cout); + if (!ret) + std::cout << "Fit Failed " << std::endl; + + ///////////////////////////////////////////////////////////////////////// + cout << "\n ******* Chi2Fit with BinData and NoCeros *******" << endl; + ROOT::Fit::BinData bdNoCeros; + d.GetBinDataNoZeros(bdNoCeros); + ret = fitter.LikelihoodFit(bdNoCeros, if2); + fitter.Result().Print(std::cout); + if (!ret) + std::cout << "Fit Failed " << std::endl; + +// cout << "bdOriginal:\n" << bdOriginal << endl; +// cout << "bdNoCeros:\n" << *bdNoCeros << endl; +// cout << "Equals: " << (bdOriginal == *bdNoCeros) << endl; + ///////////////////////////////////////////////////////////////////////// + cout << "\n ******* Chi2Fit with BinData with Ceros *******" << endl; + ROOT::Fit::BinData bdWithCeros(opt); + d.GetBinDataIntegral(bdWithCeros); + ret = fitter.LikelihoodFit(bdWithCeros, if2); + fitter.Result().Print(std::cout); + if (!ret) + std::cout << "Fit Failed " << std::endl; + +// cout << "bdOriginal:\n" << bdOriginal << endl; +// cout << "bdWithCeros:\n" << *bdWithCeros << endl; +// cout << "Equals: " << (bdOriginal == *bdWithCeros) << endl; + + ///////////////////////////////////////////////////////////////////////// + + + TCanvas* c = new TCanvas("Histogram 2D"); + c->Divide(2,2); + c->cd(1); + h1->Draw("colz"); + c->cd(2); + h1->Draw("text"); + c->cd(3); + h2->Draw("colz"); + c->cd(4); + h2->Draw("text"); +} + +// void fit1DHist() +// { +// vector<double> min(1); +// min[0] = 0.; + +// vector<double> max(1); +// max[0] = 10.; + +// vector<int> nbins(1); +// nbins[0] = 10; + +// TH1D* h1 = new TH1D("1D Original Hist Fit", "h1-Original", nbins[0], min[0], max[0]); +// TH1D* h2 = new TH1D("1D Blanked Hist Fit", "h1-Blanked", nbins[0], min[0], max[0]); + +// TF1* f1 = new TF1("MyGaus", "[0]*TMath::Gaus([1],[2])", min[0], max[0]); +// f1->SetParameters(10., 5., 2.); + +// h1->FillRandom("MyGaus",1000); + +// cout << "Retrieving the Sparse Data Structure" << endl; +// ROOT::Fit::SparseData d(h1); +// ROOT::Fit::FillData(d, h1, 0); +// ROOT::Fit::BinData* bd = d.GetBinData(); + +// cout << "Filling second histogram" << endl; +// for ( unsigned int i = 0; i < bd->NPoints(); ++i) +// { +// const double* x; +// double value, error; +// x = bd->GetPoint(i, value, error); +// value = (value)?value:-10; +// h2->Fill(x[0], value); +// } + +// TCanvas* c = new TCanvas("Histogram 2D"); +// c->Divide(1,2); +// c->cd(1); +// h1->Draw("lego2Z"); +// c->cd(2); +// h2->Draw("lego2Z"); + +// // Fit preparation +// bool ret; +// ROOT::Fit::Fitter fitter; +// ROOT::Math::WrappedMultiTF1 wf1(*f1); +// fitter.Config().SetMinimizer("TMinuit"); + +// cout << "\n ******* Chi2Fit with Original BinData *******" << endl; +// ROOT::Fit::BinData bdOriginal; +// ROOT::Fit::FillData(bdOriginal, h1, 0); +// ret = fitter.Fit(bdOriginal, wf1); +// fitter.Result().Print(std::cout); +// if (!ret) +// std::cout << "Fit Failed " << std::endl; + +// cout << "\n ******* Chi2Fit with BinData and NoCeros *******" << endl; +// ROOT::Fit::BinData* bdNoCeros = d.GetBinDataNoCeros(); + +// cout << "bdOriginal:\n" << bdOriginal << endl; +// cout << "bdNoCeros:\n" << *bdNoCeros << endl; + +// cout << "Equals: " << (bdOriginal == *bdNoCeros) << endl; + +// ret = fitter.Fit(*bdNoCeros, wf1); +// fitter.Result().Print(std::cout); +// if (!ret) +// std::cout << "Fit Failed " << std::endl; + + +// delete bd; +// } + + int main(int argc, char** argv) +{ + TApplication* theApp = 0; + + if ( __DRAW__ ) + theApp = new TApplication("App",&argc,argv); + + fit3DHist(); +// fit2DHist(); +// fit1DHist(); + + if ( __DRAW__ ) { + theApp->Run(); + delete theApp; + theApp = 0; + } + + return 0; +} + diff --git a/math/mathcore/test/fit/SparseFit4.cxx b/math/mathcore/test/fit/SparseFit4.cxx index b1d3a15c1db41..98f51664ce0ec 100644 --- a/math/mathcore/test/fit/SparseFit4.cxx +++ b/math/mathcore/test/fit/SparseFit4.cxx @@ -1,318 +1,318 @@ -#include "THnSparse.h" -#include "TH2.h" -#include "TF2.h" -#include "TF3.h" -#include "TCanvas.h" -#include "TApplication.h" -#include "TMath.h" - -#include "Fit/SparseData.h" -#include "HFitInterface.h" -#include "Fit/Fitter.h" -#include "Math/WrappedMultiTF1.h" - -#include "TRandom2.h" - -#include <iostream> -#include <iterator> -#include <algorithm> - -#include <list> -#include <vector> - -#include <cmath> -#include <cassert> - -using namespace std; - -const bool __DRAW__ = 1; - -TRandom2 r(17); -Int_t bsize[] = { 10, 10, 10 }; -Double_t xmin[] = { 0., 0., 0. }; -Double_t xmax[] = { 10., 10., 10. }; - -double gaus1D(double *x, double *p) -{ - return p[0]*TMath::Gaus(x[0],p[1],p[2]); -} - -double gaus2D(double *x, double *p) -{ - return p[0]*TMath::Gaus(x[0],p[1],p[2]) * TMath::Gaus(x[1],p[3],p[4]); -} - -double gaus3D(double *x, double *p) -{ - return p[0] * TMath::Gaus(x[0],p[1],p[2]) - * TMath::Gaus(x[1],p[3],p[4]) - * TMath::Gaus(x[2],p[5],p[6]); -} - -double pol2D(double *x, double *p) -{ - return p[0]*x[0]+ p[1]*x[0]*x[0] + p[2]*x[1] + p[3]*x[1]*x[1] + p[4]; -} - -ostream& operator << (ostream& out, ROOT::Fit::BinData& bd) -{ - const unsigned int ndim( bd.NDim() ); - const unsigned int npoints( bd.NPoints() ); - for ( unsigned int i = 0; i < npoints; ++i ) - { - double value, error; - const double *x = bd.GetPoint(i, value, error); - for ( unsigned int j = 0; j < ndim; ++j ) - { - out << " x[" << j << "]: " << x[j]; - } - out << " value: " << value; - out << " error: " << error; - out << endl; - } - return out; -} - -int findBin(ROOT::Fit::BinData& bd, const double *x) -{ - const unsigned int ndim = bd.NDim(); - const unsigned int npoints = bd.NPoints(); - - for ( unsigned int i = 0; i < npoints; ++i ) - { - double value1, error1; - const double *x1 = bd.GetPoint(i, value1, error1); - bool thisIsIt = true; - for ( unsigned int j = 0; j < ndim; ++j ) - { - thisIsIt &= fabs(x1[j] - x[j]) < 1E-15; - } - if ( thisIsIt ) return i; - } - - cout << "NO ENCONTRADO!"; - copy(x, x+ndim, ostream_iterator<double>(cout, " " )); - cout << endl; - - return -1; -} - -bool operator ==(ROOT::Fit::BinData& bd1, ROOT::Fit::BinData& bd2) -{ - const unsigned int ndim = bd1.NDim(); - const unsigned int npoints = bd1.NPoints(); - - bool equals = true; - - cout << "Equals" << endl; - - for ( unsigned int i = 0; i < npoints && equals; ++i ) - { - double value1, error1; - const double *x1 = bd1.GetPoint(i, value1, error1); - - int bin = findBin(bd2, x1); - - double value2 = 0, error2; - const double *x2 = bd2.GetPoint(bin, value2, error2); - - equals &= ( value1 == value2 ); - cout << " v: " << equals; - equals &= ( error1 == error2 ); - cout << " e: " << equals; - for ( unsigned int j = 0; j < ndim; ++j ) - { - equals &= fabs(x1[j] - x2[j]) < 1E-15; - cout << " x[" << j << "]: " << equals; - } - - cout << " bd1: "; - std::copy(x1, &x1[ndim], ostream_iterator<double>(cout, " ")); - cout << " value:" << value1; - cout << " error:" << error1; - - cout << " bd2: "; - std::copy(x2, &x2[ndim], ostream_iterator<double>(cout, " ")); - cout << " value:" << value2; - cout << " error:" << error2; - - cout << " equals: " << equals; - - cout << endl; - } - - return equals; -} - -void fillSparse(THnSparse* s, TF1* f, int nEvents = 5) -{ - const unsigned int ndim = s->GetNdimensions(); - - for ( Int_t e = 0; e < nEvents; ++e ) { - Double_t points[ndim]; - for ( UInt_t i = 0; i < ndim; ++ i ) - points[i] = r.Uniform( xmin[0] * .9 , xmax[0] * 1.1 ); - double value = gRandom->Poisson( f->EvalPar(points)); - s->Fill(points, value ); - cout << value << " " << s->GetNbins() << endl; - } -} - -void DoFit(THnSparse* s, TF1* f, ROOT::Fit::BinData& bd) -{ - ///////////////// CREATE THE SPARSE DATA - cout << "Retrieving the Sparse Data Structure" << endl; - //ROOT::Fit::SparseData d(s); - ROOT::Fit::SparseData d(s->GetNdimensions(), xmin, xmax); - ROOT::Fit::FillData(d, s, 0); - d.GetBinData(bd); - - ///////////////// FITS - // Fit preparation - bool ret; - ROOT::Fit::Fitter fitter; - ROOT::Math::WrappedMultiTF1 wf2(*f); - ROOT::Math::IParametricFunctionMultiDim & if2 = wf2; - fitter.Config().SetMinimizer("Minuit2"); - - ROOT::Fit::DataOptions opt; - opt.fUseEmpty = true; - opt.fIntegral = true; - - ///////////////////////////////////////////////////////////////////////// - cout << "\n ******* Likelihood with BinData and NoCeros *******" << endl; - ROOT::Fit::BinData bdNoCeros; - d.GetBinDataNoZeros(bdNoCeros); - ret = fitter.LikelihoodFit(bdNoCeros, if2); - fitter.Result().Print(std::cout); - if (!ret) - std::cout << "Fit Failed " << std::endl; - - ///////////////////////////////////////////////////////////////////////// - cout << "\n ******* Likelihood with BinData with Ceros *******" << endl; - ROOT::Fit::BinData bdWithCeros(opt); - d.GetBinDataIntegral(bdWithCeros); - ret = fitter.LikelihoodFit(bdWithCeros, if2); - fitter.Result().Print(std::cout); - if (!ret) - std::cout << "Fit Failed " << std::endl; - - ///////////////////////////////////////////////////////////////////////// -} - -void fitSparse1D() -{ - const unsigned int ndim = 1; - - THnSparseD* s1 = new THnSparseD("mfND-s1", "s1-Title", ndim, bsize, xmin, xmax); - - TF1* f = new TF1("func1D", gaus1D, xmin[0] - 2, xmax[0] + 2, 3); - f->SetParameters(10., 5., 2.); - - fillSparse(s1,f,5); - - cout << "Retrieving the Sparse Data Structure" << endl; - //ROOT::Fit::SparseData d(s1); - ROOT::Fit::SparseData d(ndim, xmin, xmax); - ROOT::Fit::FillData(d, s1, 0); -} - -void fitSparse2D() -{ - const unsigned int ndim = 2; - - THnSparseD* s1 = new THnSparseD("mfND-s1", "s1-Title", ndim, bsize, xmin, xmax); - - TF2* f = new TF2("func2D", gaus2D, xmin[0],xmax[0], xmin[1], xmax[1], 5); - f->SetParameters(40,5,2,5,1); - - for (int ix=1; ix <= bsize[0]; ++ix) { - for (int iy=1; iy <= bsize[1]; ++iy) { - double x = s1->GetAxis(0)->GetBinCenter(ix); - double y = s1->GetAxis(1)->GetBinCenter(iy); - - double value = gRandom->Poisson( f->Eval(x,y) ); - if ( value ) - { - double points[] = {x,y}; - s1->Fill( points, value ); - } - } - } - - ROOT::Fit::BinData bd; - DoFit(s1, f, bd); - - TH2D* h2 = new TH2D("2D Blanked Hist Fit", "h1-title", - bsize[0], xmin[0], xmax[0], - bsize[1], xmin[1], xmax[1]); - cout << "Filling second histogram" << endl; - for ( unsigned int i = 0; i < bd.NPoints(); ++i ) - { - const double* x; - double value, error; - x = bd.GetPoint(i, value, error); - value = (value)?value:-10; - h2->Fill(x[0], x[1], value); - } - - h2->Draw("colZ"); -} - -void fitSparse3D() -{ - const unsigned int ndim = 3; - - THnSparseD* s1 = new THnSparseD("mfND-s1", "s1-Title", ndim, bsize, xmin, xmax); - - TF3* f = new TF3("func3D", gaus3D, - xmin[0],xmax[0], - xmin[1],xmax[1], - xmin[2],xmax[2], - 7); - f->SetParameters(100,5,2,5,1,5,2); - - for (int ix=1; ix <= bsize[0]; ++ix) { - for (int iy=1; iy <= bsize[1]; ++iy) { - for (int iz=1; iz <= bsize[2]; ++iz) { - double x = s1->GetAxis(0)->GetBinCenter(ix); - double y = s1->GetAxis(1)->GetBinCenter(iy); - double z = s1->GetAxis(2)->GetBinCenter(iz); - double value = gRandom->Poisson( f->Eval(x,y,z) ); - - if ( value ) - { - double points[] = {x,y,z}; - s1->Fill( points, value ); - } - } - } - } - - ROOT::Fit::BinData bd; - DoFit(s1, f, bd); -} - - -int main(int argc, char** argv) -{ - TApplication* theApp = 0; - - if ( __DRAW__ ) - theApp = new TApplication("App",&argc,argv); - - fitSparse1D(); - fitSparse2D(); - fitSparse3D(); - - cout << "C'est fini!" << endl; - - if ( __DRAW__ ) { - theApp->Run(); - delete theApp; - theApp = 0; - } - - return 0; -} - +#include "THnSparse.h" +#include "TH2.h" +#include "TF2.h" +#include "TF3.h" +#include "TCanvas.h" +#include "TApplication.h" +#include "TMath.h" + +#include "Fit/SparseData.h" +#include "HFitInterface.h" +#include "Fit/Fitter.h" +#include "Math/WrappedMultiTF1.h" + +#include "TRandom2.h" + +#include <iostream> +#include <iterator> +#include <algorithm> + +#include <list> +#include <vector> + +#include <cmath> +#include <cassert> + +using namespace std; + +const bool __DRAW__ = 1; + +TRandom2 r(17); +Int_t bsize[] = { 10, 10, 10 }; +Double_t xmin[] = { 0., 0., 0. }; +Double_t xmax[] = { 10., 10., 10. }; + +double gaus1D(double *x, double *p) +{ + return p[0]*TMath::Gaus(x[0],p[1],p[2]); +} + +double gaus2D(double *x, double *p) +{ + return p[0]*TMath::Gaus(x[0],p[1],p[2]) * TMath::Gaus(x[1],p[3],p[4]); +} + +double gaus3D(double *x, double *p) +{ + return p[0] * TMath::Gaus(x[0],p[1],p[2]) + * TMath::Gaus(x[1],p[3],p[4]) + * TMath::Gaus(x[2],p[5],p[6]); +} + +double pol2D(double *x, double *p) +{ + return p[0]*x[0]+ p[1]*x[0]*x[0] + p[2]*x[1] + p[3]*x[1]*x[1] + p[4]; +} + +ostream& operator << (ostream& out, ROOT::Fit::BinData& bd) +{ + const unsigned int ndim( bd.NDim() ); + const unsigned int npoints( bd.NPoints() ); + for ( unsigned int i = 0; i < npoints; ++i ) + { + double value, error; + const double *x = bd.GetPoint(i, value, error); + for ( unsigned int j = 0; j < ndim; ++j ) + { + out << " x[" << j << "]: " << x[j]; + } + out << " value: " << value; + out << " error: " << error; + out << endl; + } + return out; +} + +int findBin(ROOT::Fit::BinData& bd, const double *x) +{ + const unsigned int ndim = bd.NDim(); + const unsigned int npoints = bd.NPoints(); + + for ( unsigned int i = 0; i < npoints; ++i ) + { + double value1, error1; + const double *x1 = bd.GetPoint(i, value1, error1); + bool thisIsIt = true; + for ( unsigned int j = 0; j < ndim; ++j ) + { + thisIsIt &= fabs(x1[j] - x[j]) < 1E-15; + } + if ( thisIsIt ) return i; + } + + cout << "NO ENCONTRADO!"; + copy(x, x+ndim, ostream_iterator<double>(cout, " " )); + cout << endl; + + return -1; +} + +bool operator ==(ROOT::Fit::BinData& bd1, ROOT::Fit::BinData& bd2) +{ + const unsigned int ndim = bd1.NDim(); + const unsigned int npoints = bd1.NPoints(); + + bool equals = true; + + cout << "Equals" << endl; + + for ( unsigned int i = 0; i < npoints && equals; ++i ) + { + double value1, error1; + const double *x1 = bd1.GetPoint(i, value1, error1); + + int bin = findBin(bd2, x1); + + double value2 = 0, error2; + const double *x2 = bd2.GetPoint(bin, value2, error2); + + equals &= ( value1 == value2 ); + cout << " v: " << equals; + equals &= ( error1 == error2 ); + cout << " e: " << equals; + for ( unsigned int j = 0; j < ndim; ++j ) + { + equals &= fabs(x1[j] - x2[j]) < 1E-15; + cout << " x[" << j << "]: " << equals; + } + + cout << " bd1: "; + std::copy(x1, &x1[ndim], ostream_iterator<double>(cout, " ")); + cout << " value:" << value1; + cout << " error:" << error1; + + cout << " bd2: "; + std::copy(x2, &x2[ndim], ostream_iterator<double>(cout, " ")); + cout << " value:" << value2; + cout << " error:" << error2; + + cout << " equals: " << equals; + + cout << endl; + } + + return equals; +} + +void fillSparse(THnSparse* s, TF1* f, int nEvents = 5) +{ + const unsigned int ndim = s->GetNdimensions(); + + for ( Int_t e = 0; e < nEvents; ++e ) { + Double_t points[ndim]; + for ( UInt_t i = 0; i < ndim; ++ i ) + points[i] = r.Uniform( xmin[0] * .9 , xmax[0] * 1.1 ); + double value = gRandom->Poisson( f->EvalPar(points)); + s->Fill(points, value ); + cout << value << " " << s->GetNbins() << endl; + } +} + +void DoFit(THnSparse* s, TF1* f, ROOT::Fit::BinData& bd) +{ + ///////////////// CREATE THE SPARSE DATA + cout << "Retrieving the Sparse Data Structure" << endl; + //ROOT::Fit::SparseData d(s); + ROOT::Fit::SparseData d(s->GetNdimensions(), xmin, xmax); + ROOT::Fit::FillData(d, s, 0); + d.GetBinData(bd); + + ///////////////// FITS + // Fit preparation + bool ret; + ROOT::Fit::Fitter fitter; + ROOT::Math::WrappedMultiTF1 wf2(*f); + ROOT::Math::IParametricFunctionMultiDim & if2 = wf2; + fitter.Config().SetMinimizer("Minuit2"); + + ROOT::Fit::DataOptions opt; + opt.fUseEmpty = true; + opt.fIntegral = true; + + ///////////////////////////////////////////////////////////////////////// + cout << "\n ******* Likelihood with BinData and NoCeros *******" << endl; + ROOT::Fit::BinData bdNoCeros; + d.GetBinDataNoZeros(bdNoCeros); + ret = fitter.LikelihoodFit(bdNoCeros, if2); + fitter.Result().Print(std::cout); + if (!ret) + std::cout << "Fit Failed " << std::endl; + + ///////////////////////////////////////////////////////////////////////// + cout << "\n ******* Likelihood with BinData with Ceros *******" << endl; + ROOT::Fit::BinData bdWithCeros(opt); + d.GetBinDataIntegral(bdWithCeros); + ret = fitter.LikelihoodFit(bdWithCeros, if2); + fitter.Result().Print(std::cout); + if (!ret) + std::cout << "Fit Failed " << std::endl; + + ///////////////////////////////////////////////////////////////////////// +} + +void fitSparse1D() +{ + const unsigned int ndim = 1; + + THnSparseD* s1 = new THnSparseD("mfND-s1", "s1-Title", ndim, bsize, xmin, xmax); + + TF1* f = new TF1("func1D", gaus1D, xmin[0] - 2, xmax[0] + 2, 3); + f->SetParameters(10., 5., 2.); + + fillSparse(s1,f,5); + + cout << "Retrieving the Sparse Data Structure" << endl; + //ROOT::Fit::SparseData d(s1); + ROOT::Fit::SparseData d(ndim, xmin, xmax); + ROOT::Fit::FillData(d, s1, 0); +} + +void fitSparse2D() +{ + const unsigned int ndim = 2; + + THnSparseD* s1 = new THnSparseD("mfND-s1", "s1-Title", ndim, bsize, xmin, xmax); + + TF2* f = new TF2("func2D", gaus2D, xmin[0],xmax[0], xmin[1], xmax[1], 5); + f->SetParameters(40,5,2,5,1); + + for (int ix=1; ix <= bsize[0]; ++ix) { + for (int iy=1; iy <= bsize[1]; ++iy) { + double x = s1->GetAxis(0)->GetBinCenter(ix); + double y = s1->GetAxis(1)->GetBinCenter(iy); + + double value = gRandom->Poisson( f->Eval(x,y) ); + if ( value ) + { + double points[] = {x,y}; + s1->Fill( points, value ); + } + } + } + + ROOT::Fit::BinData bd; + DoFit(s1, f, bd); + + TH2D* h2 = new TH2D("2D Blanked Hist Fit", "h1-title", + bsize[0], xmin[0], xmax[0], + bsize[1], xmin[1], xmax[1]); + cout << "Filling second histogram" << endl; + for ( unsigned int i = 0; i < bd.NPoints(); ++i ) + { + const double* x; + double value, error; + x = bd.GetPoint(i, value, error); + value = (value)?value:-10; + h2->Fill(x[0], x[1], value); + } + + h2->Draw("colZ"); +} + +void fitSparse3D() +{ + const unsigned int ndim = 3; + + THnSparseD* s1 = new THnSparseD("mfND-s1", "s1-Title", ndim, bsize, xmin, xmax); + + TF3* f = new TF3("func3D", gaus3D, + xmin[0],xmax[0], + xmin[1],xmax[1], + xmin[2],xmax[2], + 7); + f->SetParameters(100,5,2,5,1,5,2); + + for (int ix=1; ix <= bsize[0]; ++ix) { + for (int iy=1; iy <= bsize[1]; ++iy) { + for (int iz=1; iz <= bsize[2]; ++iz) { + double x = s1->GetAxis(0)->GetBinCenter(ix); + double y = s1->GetAxis(1)->GetBinCenter(iy); + double z = s1->GetAxis(2)->GetBinCenter(iz); + double value = gRandom->Poisson( f->Eval(x,y,z) ); + + if ( value ) + { + double points[] = {x,y,z}; + s1->Fill( points, value ); + } + } + } + } + + ROOT::Fit::BinData bd; + DoFit(s1, f, bd); +} + + +int main(int argc, char** argv) +{ + TApplication* theApp = 0; + + if ( __DRAW__ ) + theApp = new TApplication("App",&argc,argv); + + fitSparse1D(); + fitSparse2D(); + fitSparse3D(); + + cout << "C'est fini!" << endl; + + if ( __DRAW__ ) { + theApp->Run(); + delete theApp; + theApp = 0; + } + + return 0; +} + diff --git a/math/mathcore/test/fit/WrapperRooPdf.h b/math/mathcore/test/fit/WrapperRooPdf.h index 978b7c9f72dbb..2b8e07c5bf00b 100644 --- a/math/mathcore/test/fit/WrapperRooPdf.h +++ b/math/mathcore/test/fit/WrapperRooPdf.h @@ -36,8 +36,10 @@ class WrapperRooPdf : public ROOT::Math::IParamMultiFunction { fParams = fPdf->getParameters(obsList); assert(fX!=0); assert(fParams!=0); +#ifdef DEBUG fX->Print("v"); fParams->Print("v"); +#endif } @@ -58,9 +60,10 @@ class WrapperRooPdf : public ROOT::Math::IParamMultiFunction { fParams = fPdf->getParameters(obsList); assert(fX!=0); assert(fParams!=0); +#ifdef DEBUG fX->Print("v"); fParams->Print("v"); - +#endif // // iterate on fX // TIterator* itr = fX->createIterator() ; // RooAbsArg* arg = 0; diff --git a/math/mathcore/test/fit/testFitPerf.cxx b/math/mathcore/test/fit/testFitPerf.cxx index 16f581e62c80a..2ee6b0d38046f 100644 --- a/math/mathcore/test/fit/testFitPerf.cxx +++ b/math/mathcore/test/fit/testFitPerf.cxx @@ -34,7 +34,7 @@ #include "TStopwatch.h" #include "TVirtualFitter.h" -#include "TFitterMinuit.h" +//#include "TFitterMinuit.h" // #include "TFitterFumili.h" // #include "TFumili.h" @@ -655,6 +655,9 @@ int FitUsingRooFit2(TTree * tree) { else if (j > 1) { pdf[j] = new RooProdPdf(pname.c_str(),pname.c_str(),RooArgSet(*g[j],*pdf[j-1]) ); } +// else +// pdf[0] = g[0]; + } @@ -667,7 +670,7 @@ int FitUsingRooFit2(TTree * tree) { (pdf[N-1]->getVariables())->Print("v"); // print the parameters std::cout << "\n\nDo the fit now \n\n"; #else - int level = -1; + int level = -1; bool save = false; #endif @@ -685,7 +688,7 @@ int FitUsingRooFit2(TTree * tree) { #endif - iret |= (result == 0); + iret |= (result != 0); // free for (int j = 0; j < N; ++j) { @@ -693,7 +696,7 @@ int FitUsingRooFit2(TTree * tree) { delete m[j]; delete s[j]; delete g[j]; - delete pdf[j]; + if (j> 0) delete pdf[j]; } if (iret != 0) return iret; diff --git a/math/mathcore/test/fit/testMinim.cxx b/math/mathcore/test/fit/testMinim.cxx index 2bf88a9c193af..19117cd66e775 100644 --- a/math/mathcore/test/fit/testMinim.cxx +++ b/math/mathcore/test/fit/testMinim.cxx @@ -19,17 +19,19 @@ #include "TRandom3.h" #include "TMath.h" +#include "RVersion.h" + //#define DEBUG int gNCall = 0; int gNCall2 = 0; -int gNmin = 1000; -int gVerbose = 0; +int gNmin = 1; +int gVerbose = 1; bool minos = false; -double gAbsTolerance = 0.001; +double gAbsTolerance = 5.E-6; // otherwise gsl_conjugate_PR fails // Rosenbrok function to be minimize @@ -62,11 +64,15 @@ public : return new RosenBrockFunction(); } - const double * TrueMinimum() const { + const double * TrueXMinimum() const { fTrueMin[0] = 1; fTrueMin[1] = 1; return fTrueMin; } + + double TrueMinimum() const { + return 0; + } private: @@ -153,10 +159,11 @@ public : } - const double * TrueMinimum() const { + const double * TrueXMinimum() const { return x0.GetMatrixArray(); } + double TrueMinimum() const { return 0; } void Gradient (const double * x, double * g) const { gNCall2++; @@ -270,10 +277,12 @@ public : return new ChebyQuadFunction(*this); } - const double * TrueMinimum() const { + const double * TrueXMinimum() const { return &fTrueMin[0]; } + double TrueMinimum() const { return 0; } + // use equally spaced points void StartPoints(double * x, double * s) { for (unsigned int i = 0; i < fDim; ++i) { @@ -367,14 +376,24 @@ public : -const double * TrueMinimum(const ROOT::Math::IMultiGenFunction & func) { +const double * TrueXMinimum(const ROOT::Math::IMultiGenFunction & func) { + + const RosenBrockFunction * fRB = dynamic_cast< const RosenBrockFunction *> (&func); + if (fRB != 0) return fRB->TrueXMinimum(); + const TrigoFletcherFunction * fTF = dynamic_cast< const TrigoFletcherFunction *> (&func); + if (fTF != 0) return fTF->TrueXMinimum(); +// const ChebyQuadFunction * fCQ = dynamic_cast< const ChebyQuadFunction *> (&func); +// if (fCQ != 0) return fCQ->TrueXMinimum(); + return 0; +} +double TrueMinimum(const ROOT::Math::IMultiGenFunction & func) { const RosenBrockFunction * fRB = dynamic_cast< const RosenBrockFunction *> (&func); if (fRB != 0) return fRB->TrueMinimum(); const TrigoFletcherFunction * fTF = dynamic_cast< const TrigoFletcherFunction *> (&func); if (fTF != 0) return fTF->TrueMinimum(); // const ChebyQuadFunction * fCQ = dynamic_cast< const ChebyQuadFunction *> (&func); -// if (fCQ != 0) return fCQ->TrueMinimum(); +// if (fCQ != 0) return fCQ->TrueXMinimum(); return 0; } @@ -399,10 +418,11 @@ int DoNewMinimization( const ROOT::Math::IMultiGenFunction & func, const double if (func.NDim() >= 10) { min->SetMaxFunctionCalls(1000000); min->SetMaxIterations(100000); - min->SetTolerance(0.001); - if (func.NDim() >= 10) min->SetTolerance(0.01); - + min->SetTolerance(0.01); } + else + min->SetTolerance(0.001); + min->SetPrintLevel(gVerbose); // check if func provides gradient @@ -428,10 +448,11 @@ int DoNewMinimization( const ROOT::Math::IMultiGenFunction & func, const double const double * xmin = min->X(); bool ok = true; - const double * trueMin = TrueMinimum(func); + const double * trueMin = TrueXMinimum(func); if (trueMin != 0) { + ok &= (std::fabs(minval - TrueMinimum(func) ) < gAbsTolerance ); for (unsigned int i = 0; i < func.NDim(); ++i) - ok &= (std::fabs(xmin[i]-trueMin[i] ) < gAbsTolerance); + ok &= (std::fabs(xmin[i]-trueMin[i] ) < sqrt(gAbsTolerance)); } if (!ok) iret = -2; @@ -487,13 +508,15 @@ int DoOldMinimization( FCN func, TVirtualFitter * min, double &minval, double & min->GetParameter(0,parName,parx,we,al,bl); min->GetParameter(1,parName,pary,we,al,bl); - bool ok = ( TMath::Abs(parx-1.) < gAbsTolerance && - TMath::Abs(pary-1.) < gAbsTolerance ); - + bool ok = ( TMath::Abs(parx-1.) < sqrt(gAbsTolerance) && + TMath::Abs(pary-1.) < sqrt(gAbsTolerance) ); + + double errdef = 0; int nvpar, nparx; min->GetStats(minval,edm,errdef,nvpar,nparx); + if (!ok) iret = -2; min->Clear(); // for further use @@ -521,7 +544,6 @@ int testNewMinimizer( const ROOT::Math::IMultiGenFunction & func, const double * return -1; } - for (int i = 0; i < gNmin; ++i) { gNCall = 0; gNCall2 = 0; iret |= DoNewMinimization(func, x0, s0, min,minval,edm,&xmin[0]); @@ -599,10 +621,14 @@ int testRosenBrock() { // minimize using Rosenbrock Function #ifndef DEBUG - gNmin = 10000; + gNmin = 1; #endif + + +#if ROOT_VERSION_CODE < ROOT_VERSION(5,99,00) iret |= testOldMinimizer(RosenBrock,"Minuit",2); iret |= testOldMinimizer(RosenBrock,"Minuit2",2); +#endif RosenBrockFunction fRB; double xRB[2] = { -1.,1.2}; diff --git a/math/mathcore/test/fit/testRooFit.cxx b/math/mathcore/test/fit/testRooFit.cxx index 38a1cae57f75f..4a7d0f993ef28 100644 --- a/math/mathcore/test/fit/testRooFit.cxx +++ b/math/mathcore/test/fit/testRooFit.cxx @@ -37,11 +37,12 @@ #include "Math/WrappedParamFunction.h" #include <cmath> -const int N = 1; // n must be greater than 1 +const int N = 3; // n must be greater than 1 const int nfit = 1; const int nEvents = 10000; double iniPar[2*N]; +//#define DEBUG typedef ROOT::Math::IParamMultiFunction Func; @@ -93,10 +94,13 @@ void FillUnBinData(ROOT::Fit::UnBinData &d, TTree * tree ) { for (int j = 0; j < N; ++j) m[j] += vx[j]; } + +#ifdef DEBUG std::cout << "average values of means :\n"; for (int j = 0; j < N; ++j) std::cout << m[j]/n << " "; std::cout << "\n"; +#endif return; @@ -134,14 +138,14 @@ class MultiGaussRooPdf { g[j] = new RooGaussian(gname.c_str(),"gauss(x,mean,sigma)",*x[j],*m[j],*s[j]); std::string pname = "prod_" + ROOT::Math::Util::ToString(j); - if (j == 1) { + if (j == 0) + pdf[0] = g[0]; + else if (j == 1) { pdf[1] = new RooProdPdf(pname.c_str(),pname.c_str(),RooArgSet(*g[1],*g[0]) ); } else if (j > 1) { pdf[j] = new RooProdPdf(pname.c_str(),pname.c_str(),RooArgSet(*g[j],*pdf[j-1]) ); } - else if (j == 0) - pdf[0] = g[0]; } @@ -164,7 +168,7 @@ class MultiGaussRooPdf { delete m[j]; delete s[j]; delete g[j]; - delete pdf[j]; + if (j> 0) delete pdf[j]; // no pdf allocated for j = 0 } } @@ -199,13 +203,13 @@ int FitUsingRooFit(TTree & tree, RooAbsPdf & pdf, RooArgSet & xvars) { #ifdef DEBUG - int level = 3; + int level = 2; std::cout << "num entries = " << data.numEntries() << std::endl; bool save = true; - (pdf[N-1]->getVariables())->Print("v"); // print the parameters + pdf.getVariables()->Print("v"); // print the parameters std::cout << "\n\nDo the fit now \n\n"; #else - int level = 1; + int level = -1; bool save = false; #endif @@ -226,6 +230,7 @@ int FitUsingRooFit(TTree & tree, RooAbsPdf & pdf, RooArgSet & xvars) { w.Stop(); + std::cout << "RooFit result " << std::endl; RooArgSet * params = pdf.getParameters(xvars); params->Print("v"); delete params; @@ -248,7 +253,7 @@ int DoFit(TTree * tree, Func & func, bool debug = false, bool = false ) { //std::cout << "Fit parameter 2 " << f.Parameters()[2] << std::endl; ROOT::Fit::Fitter fitter; - fitter.Config().MinimizerOptions().SetPrintLevel(2); + fitter.Config().MinimizerOptions().SetPrintLevel(0); fitter.Config().SetMinimizer(MinType::name().c_str(),MinType::name2().c_str()); fitter.Config().MinimizerOptions().SetTolerance(1.); // to be consistent with RooFit @@ -267,8 +272,7 @@ int DoFit(TTree * tree, Func & func, bool debug = false, bool = false ) { std::cout << " Fit Failed " << std::endl; return -1; } - if (debug) - fitter.Result().Print(std::cout); + fitter.Result().Print(std::cout); return 0; } @@ -301,13 +305,29 @@ int FitUsingNewFitter(FitObj * fitobj, Func & func, bool useGrad=false) { return iret; } -double gausnorm(const double *x, const double *p) { - //return p[0]*TMath::Gaus(x[0],p[1],p[2]); - double invsig = 1./p[1]; - double tmp = (x[0]-p[0]) * invsig; - const double sqrt_2pi = 1./std::sqrt(2.* 3.14159 ); - return std::exp(-0.5 * tmp*tmp ) * sqrt_2pi * invsig; -} +template <int N> +struct GausNorm { + static double F(const double *x, const double *p) { + return ROOT::Math::normal_pdf(x[N-1], p[2*N-1], p[2*N-2] ) * GausNorm<N-1>::F(x,p); + } +}; +template <> +struct GausNorm<1> { + + static double F(const double *x, const double *p) { + return ROOT::Math::normal_pdf(x[0], p[1], p[0] ); + } +}; + + +// double gausnorm( +// return ROOT::Math::normal_pdf(x[0], p[1], p[0] ); +// // //return p[0]*TMath::Gaus(x[0],p[1],p[2]); +// // double invsig = 1./p[1]; +// // double tmp = (x[0]-p[0]) * invsig; +// // const double sqrt_2pi = 1./std::sqrt(2.* 3.14159 ); +// // return std::exp(-0.5 * tmp*tmp ) * sqrt_2pi * invsig; +// } @@ -346,10 +366,10 @@ int main() { // in case of N = 1 do also a simple gauss fit // using TF1 gausN - if (N == 1) { - ROOT::Math::WrappedParamFunction<> gausn(&gausnorm,2,iniPar,iniPar+1); - FitUsingNewFitter<TMINUIT>(&tree,gausn); - } +// if (N == 1) { + ROOT::Math::WrappedParamFunction<> gausn(&GausNorm<N>::F,2*N,iniPar,iniPar+2*N); + FitUsingNewFitter<TMINUIT>(&tree,gausn); + //} diff --git a/math/mathmore/CMakeLists.txt b/math/mathmore/CMakeLists.txt index 117c7ccf274dc..4e9cf603d7647 100644 --- a/math/mathmore/CMakeLists.txt +++ b/math/mathmore/CMakeLists.txt @@ -4,15 +4,15 @@ ROOT_USE_PACKAGE(math/mathcore) -include_directories(${GSL_INCLUDE_DIR}) +include_directories(${GSL_INCLUDE_DIR} ${CMAKE_SOURCE_DIR}) add_definitions(-DUSE_ROOT_ERROR ${GSL_CFLAGS}) set(headers Math/DistFuncMathMore.h Math/SpecFuncMathMore.h Math/PdfFuncMathMore.h Math/Polynomial.h Math/Derivator.h Math/Interpolator.h Math/InterpolationTypes.h Math/GSLRootFinder.h Math/GSLRootFinderDeriv.h Math/RootFinderAlgorithms.h Math/GSLIntegrator.h Math/GSLMCIntegrator.h - Math/MCParameters.h Math/GSLMinimizer1D.h Math/Chebyshev.h - Math/Random.h Math/GSLRndmEngines.h Math/KelvinFunctions.h + Math/MCParameters.h Math/GSLMinimizer1D.h Math/ChebyshevApprox.h + Math/Random.h Math/GSLRndmEngines.h Math/QuasiRandom.h Math/GSLQuasiRandom.h Math/KelvinFunctions.h Math/GSLMinimizer.h Math/GSLNLSMinimizer.h Math/GSLSimAnMinimizer.h Math/GSLMultiRootFinder.h Math/Vavilov.h Math/VavilovAccurate.h Math/VavilovAccuratePdf.h diff --git a/math/mathmore/Module.mk b/math/mathmore/Module.mk index 4fe8eb16aba94..db71a4c25ab67 100644 --- a/math/mathmore/Module.mk +++ b/math/mathmore/Module.mk @@ -39,9 +39,11 @@ MATHMOREDH1 := $(MODDIRI)/Math/DistFuncMathMore.h \ $(MODDIRI)/Math/GSLMCIntegrator.h \ $(MODDIRI)/Math/MCParameters.h \ $(MODDIRI)/Math/GSLMinimizer1D.h \ - $(MODDIRI)/Math/Chebyshev.h \ + $(MODDIRI)/Math/ChebyshevApprox.h \ $(MODDIRI)/Math/Random.h \ $(MODDIRI)/Math/GSLRndmEngines.h \ + $(MODDIRI)/Math/QuasiRandom.h \ + $(MODDIRI)/Math/GSLQuasiRandom.h \ $(MODDIRI)/Math/KelvinFunctions.h \ $(MODDIRI)/Math/GSLMinimizer.h \ $(MODDIRI)/Math/GSLNLSMinimizer.h \ diff --git a/math/mathmore/inc/Math/Chebyshev.h b/math/mathmore/inc/Math/ChebyshevApprox.h similarity index 88% rename from math/mathmore/inc/Math/Chebyshev.h rename to math/mathmore/inc/Math/ChebyshevApprox.h index 0707ddd050c52..462ff6d5f4354 100644 --- a/math/mathmore/inc/Math/Chebyshev.h +++ b/math/mathmore/inc/Math/ChebyshevApprox.h @@ -22,14 +22,14 @@ * * **********************************************************************/ -// Header file for class Chebyshev +// Header file for class ChebyshevApprox // // Created by: moneta at Thu Dec 2 14:51:15 2004 // // Last update: Thu Dec 2 14:51:15 2004 // -#ifndef ROOT_Math_Chebyshev -#define ROOT_Math_Chebyshev +#ifndef ROOT_Math_ChebyshevApprox +#define ROOT_Math_ChebyshevApprox /** @defgroup NumAlgo Numerical Algorithms @@ -39,7 +39,7 @@ /** - @defgroup FuncApprox Function Approximation (Chebyshev) + @defgroup FuncApprox Function Approximation (ChebyshevApprox) @ingroup NumAlgo */ @@ -74,7 +74,7 @@ class GSLFunctionWrapper; */ -class Chebyshev { +class ChebyshevApprox { public: @@ -84,16 +84,16 @@ class Chebyshev { constructor based on functions of type IGenFunction */ - Chebyshev(const ROOT::Math::IGenFunction & f, double a, double b, size_t n); + ChebyshevApprox(const ROOT::Math::IGenFunction & f, double a, double b, size_t n); /** Construct a Chebyshev series approximation to a Function f in range [a,b]; constructor based on free functions with gsl_function type signature */ - Chebyshev(GSLFuncPointer f, void *p, double a, double b, size_t n); + ChebyshevApprox(GSLFuncPointer f, void *p, double a, double b, size_t n); // destructor - virtual ~Chebyshev(); + virtual ~ChebyshevApprox(); private: @@ -102,11 +102,11 @@ class Chebyshev { construct a Chebyshev series or order n The series must be initialized from a function */ - Chebyshev(size_t n); + ChebyshevApprox(size_t n); // usually copying is non trivial, so we make this unaccessible - Chebyshev(const Chebyshev &); - Chebyshev & operator = (const Chebyshev &); + ChebyshevApprox(const ChebyshevApprox &); + ChebyshevApprox & operator = (const ChebyshevApprox &); public: @@ -140,7 +140,7 @@ class Chebyshev { derivatives coefficients. The returned pointer must be managed by the user. */ //TO DO: implement copying to return by value - Chebyshev * Deriv(); + ChebyshevApprox * Deriv(); /** Compute the integral of the series and return a pointer to a new Chebyshev series with the @@ -148,7 +148,7 @@ class Chebyshev { The returned pointer must be managed by the user */ //TO DO: implement copying to return by value - Chebyshev * Integral(); + ChebyshevApprox * Integral(); protected: @@ -169,4 +169,4 @@ class Chebyshev { } // namespace Math } // namespace ROOT -#endif /* ROOT_Math_Chebyshev */ +#endif /* ROOT_Math_ChebyshevApprox */ diff --git a/math/mathmore/inc/Math/GSLMinimizer1D.h b/math/mathmore/inc/Math/GSLMinimizer1D.h index 4b5f67a756b30..3aa57443541e9 100644 --- a/math/mathmore/inc/Math/GSLMinimizer1D.h +++ b/math/mathmore/inc/Math/GSLMinimizer1D.h @@ -70,7 +70,7 @@ Implemented using GSL, for detailed description see: <A HREF="http://www.gnu.org/software/gsl/manual/html_node/One-dimensional-Minimization.html">GSL online doc</A> The algorithms uspported are only bracketing algorithm which do not use derivatives information. -The algorithms which can be choosen at construction time are GOLDENSECTION, whic is the simplest method +The algorithms which can be chosen at construction time are GOLDENSECTION, whic is the simplest method but the slowest and BRENT (the default one) which combines the golden section with a parabolic interpolation. diff --git a/math/mathmore/inc/Math/GSLQuasiRandom.h b/math/mathmore/inc/Math/GSLQuasiRandom.h new file mode 100644 index 0000000000000..1adcf3726064f --- /dev/null +++ b/math/mathmore/inc/Math/GSLQuasiRandom.h @@ -0,0 +1,183 @@ +// @(#)root/mathmore:$Id$ +// Author: L. Moneta, A. Zsenei 08/2005 + + /********************************************************************** + * * + * Copyright (c) 2004 ROOT Foundation, CERN/PH-SFT * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of the GNU General Public License * + * as published by the Free Software Foundation; either version 2 * + * of the License, or (at your option) any later version. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * + * General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this library (see file COPYING); if not, write * + * to the Free Software Foundation, Inc., 59 Temple Place, Suite * + * 330, Boston, MA 02111-1307 USA, or contact the author. * + * * + **********************************************************************/ + +// Header file for class GSLQuasiRandom +// +// Created by: moneta at Sun Nov 21 16:26:03 2004 +// +// Last update: Sun Nov 21 16:26:03 2004 +// +#ifndef ROOT_Math_GSLQuasiRandom +#define ROOT_Math_GSLQuasiRandom + +#include <string> +#include <vector> + +namespace ROOT { +namespace Math { + + + class GSLQRngWrapper; + + //_________________________________________________________________ + /** + GSLQuasiRandomEngine + Base class for all GSL quasi random engines, + normally user instantiate the derived classes + which creates internally the generator and uses the class ROOT::Math::QuasiRandom + + + @ingroup Random + */ + class GSLQuasiRandomEngine { + + public: + + /** + default constructor. No creation of rng is done. + If then Initialize() is called an engine is created + based on default GSL type (MT) + */ + GSLQuasiRandomEngine(); + + /** + create from an existing rng. + User manage the rng pointer which is then deleted olny by calling Terminate() + */ + GSLQuasiRandomEngine( GSLQRngWrapper * rng); + + /** + Copy constructor : clone the contained GSL generator + */ + GSLQuasiRandomEngine(const GSLQuasiRandomEngine & eng); + + /** + Assignment operator : make a deep copy of the contained GSL generator + */ + GSLQuasiRandomEngine & operator=(const GSLQuasiRandomEngine & eng); + + /** + initialize the generator giving the dimension of the sequence + If no rng is present the default one based on Mersenne and Twister is created + */ + void Initialize(unsigned int dimension); + + /** + delete pointer to contained rng + */ + void Terminate(); + + /** + call Terminate() + */ + virtual ~GSLQuasiRandomEngine(); + + /** + Generate a random number between ]0,1[ + */ + double operator() () const; + + /** + Fill array x with random numbers between ]0,1[ + */ + bool operator() (double * x) const; + + /** + Skip the next n random numbers + */ + bool Skip(unsigned int n) const; + + /** + Generate an array of quasi random numbers + The iterators points to the random numbers + */ + bool GenerateArray(double * begin, double * end) const; + + /** + return name of generator + */ + std::string Name() const; + + /** + return the state size of generator + */ + unsigned int Size() const; + + /** + return the dimension of generator + */ + unsigned int NDim() const; + + + + protected: + + /// internal method used by the derived class to set the type of generators + void SetType(GSLQRngWrapper * r) { + fQRng = r; + } + + private: + + GSLQRngWrapper * fQRng; // pointer to GSL generator wrapper (managed by the class) + + + }; + + //_____________________________________________________________________________________ + /** + Sobol generator + gsl_qrng_sobol from + <A HREF="http://www.gnu.org/software/gsl/manual/html_node/Quasi_002drandom-number-generator-algorithms.html#Quasi_002drandom-number-generator-algorithms">here</A> + + + @ingroup Random + */ + class GSLQRngSobol : public GSLQuasiRandomEngine { + public: + GSLQRngSobol(); + }; + + //_____________________________________________________________________________________ + /** + Niederreiter generator + gsl_qrng_niederreiter_2 from + <A HREF="http://www.gnu.org/software/gsl/manual/html_node/Quasi_002drandom-number-generator-algorithms.html#Quasi_002drandom-number-generator-algorithms">here</A> + + @ingroup Random + */ + class GSLQRngNiederreiter2 : public GSLQuasiRandomEngine { + public: + GSLQRngNiederreiter2(); + }; + + + + +} // namespace Math +} // namespace ROOT + + +#endif /* ROOT_Math_GSLQuasiRandom */ + diff --git a/math/mathmore/inc/Math/GSLRndmEngines.h b/math/mathmore/inc/Math/GSLRndmEngines.h index 67fd5f217855e..f1abd53240156 100644 --- a/math/mathmore/inc/Math/GSLRndmEngines.h +++ b/math/mathmore/inc/Math/GSLRndmEngines.h @@ -77,6 +77,16 @@ namespace Math { */ GSLRandomEngine( GSLRngWrapper * rng); + /** + Copy constructor : clone the contained GSL generator + */ + GSLRandomEngine(const GSLRandomEngine & eng); + + /** + Assignment operator : make a deep copy of the contained GSL generator + */ + GSLRandomEngine & operator=(const GSLRandomEngine & eng); + /** initialize the generator If no rng is present the default one based on Mersenne and Twister is created diff --git a/math/mathmore/inc/Math/GSLRootFinder.h b/math/mathmore/inc/Math/GSLRootFinder.h index e3304220e35d0..d1e654481b5b5 100644 --- a/math/mathmore/inc/Math/GSLRootFinder.h +++ b/math/mathmore/inc/Math/GSLRootFinder.h @@ -104,7 +104,7 @@ namespace Math { using IRootFinderMethod::SetFunction; - // iterate to find ROOTS return GSL_CONTINUE if iteration was succesfull or another error + // iterate to find ROOTS return GSL_CONTINUE if iteration was successful or another error int Iterate(); double Root() const; diff --git a/math/mathmore/inc/Math/GSLRootFinderDeriv.h b/math/mathmore/inc/Math/GSLRootFinderDeriv.h index fb981b21ea254..2f5fcdb3cdbf8 100644 --- a/math/mathmore/inc/Math/GSLRootFinderDeriv.h +++ b/math/mathmore/inc/Math/GSLRootFinderDeriv.h @@ -113,7 +113,7 @@ class GSLRootFinderDeriv: public IRootFinderMethod { using IRootFinderMethod::SetFunction; - /// iterate (return GSL_SUCCESS in case of succesfull iteration) + /// iterate (return GSL_SUCCESS in case of successful iteration) int Iterate(); double Root() const; diff --git a/math/mathmore/inc/Math/GSLSimAnnealing.h b/math/mathmore/inc/Math/GSLSimAnnealing.h index bba1783ed5c2c..eb5705ee02de7 100644 --- a/math/mathmore/inc/Math/GSLSimAnnealing.h +++ b/math/mathmore/inc/Math/GSLSimAnnealing.h @@ -65,7 +65,7 @@ class GSLSimAnFunc { protected: /** - derived classes might need to re-define completly the class + derived classes might need to re-define completely the class */ GSLSimAnFunc() : fFunc(0) diff --git a/math/mathmore/inc/Math/Interpolator.h b/math/mathmore/inc/Math/Interpolator.h index dfd4e1133627a..b1d04e97ca7c1 100644 --- a/math/mathmore/inc/Math/Interpolator.h +++ b/math/mathmore/inc/Math/Interpolator.h @@ -74,7 +74,7 @@ class Interpolator { /** Constructs an interpolator class from vector of data points \f$ (x_i, y_i )\f$ and with Interpolation::Type type. - The method will compute a continous interpolating function \f$ y(x) \f$ such that \f$ y_i = y ( x_i )\f$. + The method will compute a continuous interpolating function \f$ y(x) \f$ such that \f$ y_i = y ( x_i )\f$. The defult interpolation type is Cubic spline */ Interpolator(const std::vector<double> & x, const std::vector<double> & y, Interpolation::Type type = Interpolation::kCSPLINE); diff --git a/math/mathmore/inc/Math/LinkDef.h b/math/mathmore/inc/Math/LinkDef.h index 6a05853db491f..fd4aab7be8e78 100644 --- a/math/mathmore/inc/Math/LinkDef.h +++ b/math/mathmore/inc/Math/LinkDef.h @@ -30,7 +30,7 @@ #pragma link C++ class ROOT::Math::Polynomial-; #endif -#pragma link C++ class ROOT::Math::Chebyshev+; +#pragma link C++ class ROOT::Math::ChebyshevApprox+; #pragma link C++ class ROOT::Math::Derivator+; #pragma link C++ class ROOT::Math::Vavilov+; @@ -82,6 +82,21 @@ #pragma link C++ class ROOT::Math::Random<ROOT::Math::GSLRngRanLuxD2>+; #pragma link C++ class ROOT::Math::Random<ROOT::Math::GSLRngGFSR4>+; +#pragma link C++ typedef ROOT::Math::RandomMT; +#pragma link C++ typedef ROOT::Math::RandomTaus; +#pragma link C++ typedef ROOT::Math::RandomRanLux; +#pragma link C++ typedef ROOT::Math::RandomGFSR4; + + +#pragma link C++ class ROOT::Math::GSLQRngSobol+; +#pragma link C++ class ROOT::Math::GSLQRngNiederreiter2+; +#pragma link C++ class ROOT::Math::QuasiRandom<ROOT::Math::GSLQRngSobol>+; +#pragma link C++ class ROOT::Math::QuasiRandom<ROOT::Math::GSLQRngNiederreiter2>+; +#pragma link C++ typedef ROOT::Math::QuasiRandomSobol; +#pragma link C++ typedef ROOT::Math::QuasiRandomNiederreiter; + + + #pragma link C++ class ROOT::Math::KelvinFunctions+; #pragma link C++ class ROOT::Math::GSLMinimizer+; diff --git a/math/mathmore/inc/Math/QuasiRandom.h b/math/mathmore/inc/Math/QuasiRandom.h new file mode 100644 index 0000000000000..b5c1cd5764da5 --- /dev/null +++ b/math/mathmore/inc/Math/QuasiRandom.h @@ -0,0 +1,187 @@ +// @(#)root/mathmore:$Id$ +// Author: L. Moneta, A. Zsenei 08/2005 + + /********************************************************************** + * * + * Copyright (c) 2004 ROOT Foundation, CERN/PH-SFT * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of the GNU General Public License * + * as published by the Free Software Foundation; either version 2 * + * of the License, or (at your option) any later version. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * + * General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this library (see file COPYING); if not, write * + * to the Free Software Foundation, Inc., 59 Temple Place, Suite * + * 330, Boston, MA 02111-1307 USA, or contact the author. * + * * + **********************************************************************/ + +// Header file for class GSLRandom +// +// Created by: moneta at Sun Nov 21 16:26:03 2004 +// +// Last update: Sun Nov 21 16:26:03 2004 +// +#ifndef ROOT_Math_QuasiRandom +#define ROOT_Math_QuasiRandom + +#include <string> + +/** + @defgroup QuasiRandom QuasiRandom number generators and distributions +*/ + + + +namespace ROOT { +namespace Math { + + +//_____________________________________________________________________________________ +/** + User class for MathMore random numbers template on the Engine type. + The API of this class followed that of the class ROOT::Math::Random + It must be implemented using as Engine one of the derived classes of + ROOT::Math::GSLQuasiRandomEngine, like ROOT::Math::GSLQrngSobol + + @ingroup Random + +*/ +template < class Engine> +class QuasiRandom { + +public: + + + /** + Create a QuasiRandom generator. Use default engine constructor. + Engine will be initialized via Initialize() function in order to + allocate resources + */ + QuasiRandom(unsigned int dimension = 1) { + fEngine.Initialize(dimension); + } + + + /** + Create a QuasiRandom generator based on a provided generic engine. + Engine will be initialized via Initialize() function in order to + allocate resources + */ + explicit QuasiRandom(const Engine & e, unsigned int dimension = 1) : fEngine(e) { + fEngine.Initialize(dimension); + } + + /** + Destructor: call Terminate() function of engine to free any + allocated resource + */ + ~QuasiRandom() { + fEngine.Terminate(); + } + + /** + Generate next quasi random numbers points + */ + bool Next(double * x) { + return fEngine(x); + } + + /** + Generate next quasi random numbers point (1 - dimension) + */ + double Next() { + return fEngine(); + } + + /** + Generate quasi random numbers between ]0,1[ + 0 and 1 are excluded + Function to be compatible with ROOT TRandom compatibility + */ + double Rndm() { + return fEngine(); + } + + /** + skip the next n number and jumb directly to the current state + n + */ + bool Skip(unsigned int n) { + return fEngine.Skip(n); + } + /** + Generate an array of random numbers between ]0,1[ + Function to preserve ROOT Trandom compatibility + The array will be filled as x1,y1,z1,....x2,y2,z2,... + */ + bool RndmArray(int n, double * array) { + return fEngine.GenerateArray(array, array+n*NDim()); + } + + /** + Return the type (name) of the used generator + */ + std::string Type() const { + return fEngine.Name(); + } + + /** + Return the size of the generator state + */ + unsigned int EngineSize() const { + return fEngine.Size(); + } + + /** + Return the dimension of the generator + */ + unsigned int NDim() const { + return fEngine.NDim(); + } + + /** + Return the name of the generator + */ + std::string Name() const { + return fEngine.Name(); + } + +private: + + Engine fEngine; + +}; + + + +} // namespace Math +} // namespace ROOT + +#ifndef ROOT_Math_GSLQuasiRandom +#include "Math/GSLQuasiRandom.h" +#endif + + + + +namespace ROOT { +namespace Math { + + +typedef QuasiRandom<ROOT::Math::GSLQRngSobol> QuasiRandomSobol; +typedef QuasiRandom<ROOT::Math::GSLQRngNiederreiter2> QuasiRandomNiederreiter; + +} // namespace Math +} // namespace ROOT + + +#endif /* ROOT_Math_QuasiRandom */ + + + diff --git a/math/mathmore/inc/Math/Random.h b/math/mathmore/inc/Math/Random.h index e3b11bbc85ac5..cd16d5169e77f 100644 --- a/math/mathmore/inc/Math/Random.h +++ b/math/mathmore/inc/Math/Random.h @@ -293,6 +293,22 @@ namespace Math { }; +} // namespace Math +} // namespace ROOT + +#ifndef ROOT_Math_GSLRndmEngines +#include "Math/GSLRndmEngines.h" +#endif + +namespace ROOT { +namespace Math { + + + typedef Random<ROOT::Math::GSLRngMT> RandomMT; + typedef Random<ROOT::Math::GSLRngTaus> RandomTaus; + typedef Random<ROOT::Math::GSLRngRanLux> RandomRanLux; + typedef Random<ROOT::Math::GSLRngGFSR4> RandomGFSR4; + } // namespace Math } // namespace ROOT diff --git a/math/mathmore/src/Chebyshev.cxx b/math/mathmore/src/ChebyshevApprox.cxx similarity index 80% rename from math/mathmore/src/Chebyshev.cxx rename to math/mathmore/src/ChebyshevApprox.cxx index 2463021ddbc6a..af561c395f3c5 100644 --- a/math/mathmore/src/Chebyshev.cxx +++ b/math/mathmore/src/ChebyshevApprox.cxx @@ -23,7 +23,7 @@ * * **********************************************************************/ -// Implementation file for class Chebyshev +// Implementation file for class ChebyshevApprox // // Created by: moneta at Thu Dec 2 14:51:15 2004 // @@ -33,7 +33,7 @@ #include "Math/IFunction.h" -#include "Math/Chebyshev.h" +#include "Math/ChebyshevApprox.h" #include "GSLFunctionWrapper.h" #include "GSLChebSeries.h" @@ -46,7 +46,7 @@ namespace ROOT { namespace Math { -Chebyshev::Chebyshev(const ROOT::Math::IGenFunction & f, double a, double b, size_t n) : +ChebyshevApprox::ChebyshevApprox(const ROOT::Math::IGenFunction & f, double a, double b, size_t n) : fOrder(n) , fSeries(0), fFunction(0) { // constructor from function (IGenFunction type) and interval [a,b] and series size n @@ -57,7 +57,7 @@ Chebyshev::Chebyshev(const ROOT::Math::IGenFunction & f, double a, double b, siz } // constructor with GSL function -Chebyshev::Chebyshev(GSLFuncPointer f, void * params, double a, double b, size_t n) : +ChebyshevApprox::ChebyshevApprox(GSLFuncPointer f, void * params, double a, double b, size_t n) : fOrder(n) , fSeries(0), fFunction(0) { // constructor from function (GSL type) and interval [a,b] and series size n @@ -65,26 +65,26 @@ fOrder(n) , fSeries(0), fFunction(0) Initialize( f, params, a, b ); } -Chebyshev::~Chebyshev() +ChebyshevApprox::~ChebyshevApprox() { // desctructor (clean up resources) if (fFunction) delete fFunction; if (fSeries) delete fSeries; } -Chebyshev::Chebyshev(size_t n) : +ChebyshevApprox::ChebyshevApprox(size_t n) : fOrder(n) , fSeries(0), fFunction(0) { // constructor passing only size (need to initialize setting the function afterwards) fSeries = new GSLChebSeries(n); } -Chebyshev::Chebyshev(const Chebyshev & /*cheb */ ) +ChebyshevApprox::ChebyshevApprox(const ChebyshevApprox & /*cheb */ ) { // cannot copy series because don't know original function } -Chebyshev & Chebyshev::operator = (const Chebyshev &rhs) +ChebyshevApprox & ChebyshevApprox::operator = (const ChebyshevApprox &rhs) { // dummy assignment if (this == &rhs) return *this; // time saving self-test @@ -92,7 +92,7 @@ Chebyshev & Chebyshev::operator = (const Chebyshev &rhs) return *this; } -void Chebyshev::Initialize( GSLFuncPointer f, void * params, double a, double b) { +void ChebyshevApprox::Initialize( GSLFuncPointer f, void * params, double a, double b) { // initialize by passing a function and interval [a,b] // delete previous existing function pointer assert(fSeries != 0); @@ -106,24 +106,24 @@ void Chebyshev::Initialize( GSLFuncPointer f, void * params, double a, double b) gsl_cheb_init( fSeries->get(), fFunction->GetFunc(), a, b); } -double Chebyshev::operator() ( double x ) const { +double ChebyshevApprox::operator() ( double x ) const { // evaluate the approximation return gsl_cheb_eval(fSeries->get(), x); } -std::pair<double, double> Chebyshev::EvalErr( double x) const { +std::pair<double, double> ChebyshevApprox::EvalErr( double x) const { // evaluate returning result and error double result, error; gsl_cheb_eval_err(fSeries->get(), x, &result, &error); return std::make_pair( result, error); } -double Chebyshev::operator() ( double x, size_t n) const { +double ChebyshevApprox::operator() ( double x, size_t n) const { // evaluate at most order n ( truncate the series) return gsl_cheb_eval_n(fSeries->get(), n, x); } -std::pair<double, double> Chebyshev::EvalErr( double x, size_t n) const { +std::pair<double, double> ChebyshevApprox::EvalErr( double x, size_t n) const { // evaluate at most order n ( truncate the series) returning resutl + error double result, error; gsl_cheb_eval_n_err(fSeries->get(), n, x, &result, &error); @@ -132,10 +132,10 @@ std::pair<double, double> Chebyshev::EvalErr( double x, size_t n) const { -Chebyshev * Chebyshev::Deriv() { +ChebyshevApprox * ChebyshevApprox::Deriv() { // calculate derivative. Returna pointer to a new series // used auto_ptr (supprseed since not good support on some compilers) - Chebyshev * deriv = new Chebyshev(fOrder); + ChebyshevApprox * deriv = new ChebyshevApprox(fOrder); // check for errors ? gsl_cheb_calc_deriv( (deriv->fSeries)->get(), fSeries->get() ); @@ -145,9 +145,9 @@ Chebyshev * Chebyshev::Deriv() { // return pDeriv; } -Chebyshev * Chebyshev::Integral() { +ChebyshevApprox * ChebyshevApprox::Integral() { // integral (return pointer) - Chebyshev * integ = new Chebyshev(fOrder); + ChebyshevApprox * integ = new ChebyshevApprox(fOrder); // check for errors ? gsl_cheb_calc_integ( (integ->fSeries)->get(), fSeries->get() ); diff --git a/math/mathmore/src/GSLIntegrator.cxx b/math/mathmore/src/GSLIntegrator.cxx index e6ee3907b53c2..5b0ba396e1201 100644 --- a/math/mathmore/src/GSLIntegrator.cxx +++ b/math/mathmore/src/GSLIntegrator.cxx @@ -273,7 +273,7 @@ double GSLIntegrator::Integral( const std::vector<double> & pts) { double GSLIntegrator::Integral( ) { // Eval for indefined integrals: use QAGI method - // if method was choosen NO_ADAPTIVE WS does not exist create it + // if method was chosen NO_ADAPTIVE WS does not exist create it if (!CheckFunction()) return 0; @@ -289,7 +289,7 @@ double GSLIntegrator::Integral( ) { double GSLIntegrator::IntegralUp( double a ) { // Integral between [a, + inf] - // if method was choosen NO_ADAPTIVE WS does not exist create it + // if method was chosen NO_ADAPTIVE WS does not exist create it if (!CheckFunction()) return 0; @@ -305,7 +305,7 @@ double GSLIntegrator::IntegralUp( double a ) { double GSLIntegrator::IntegralLow( double b ) { // Integral between [-inf, + b] - // if method was choosen NO_ADAPTIVE WS does not exist create it + // if method was chosen NO_ADAPTIVE WS does not exist create it if (!CheckFunction()) return 0; diff --git a/math/mathmore/src/GSLNLSMinimizer.cxx b/math/mathmore/src/GSLNLSMinimizer.cxx index c72dc8ba9cf66..eef00b72820af 100644 --- a/math/mathmore/src/GSLNLSMinimizer.cxx +++ b/math/mathmore/src/GSLNLSMinimizer.cxx @@ -236,6 +236,11 @@ void GSLNLSMinimizer::SetFunction(const ROOT::Math::IMultiGenFunction & func) { return; } fSize = chi2Func->NPoints(); + + if (fSize == 0) { + MATH_WARN_MSG("GSLNLSMinimizer::SetFunction","Objective function has zero elements"); + } + fDim = chi2Func->NDim(); fNFree = fDim; @@ -266,6 +271,12 @@ bool GSLNLSMinimizer::Minimize() { return false; } + if (fSize == 0) { + MATH_ERROR_MSG("GSLNLSMinimizer::Minimize","Number of data points is zero"); + return false; + } + + unsigned int npar = fValues.size(); if (npar == 0 || npar < fDim) { MATH_ERROR_MSGVAL("GSLNLSMinimizer::Minimize","Wrong number of parameters",npar); @@ -389,20 +400,24 @@ bool GSLNLSMinimizer::Minimize() { fErrors.resize(fDim); // get errors from cov matrix - if (fGSLMultiFit->CovarMatrix() ) fCovMatrix.resize(fDim*fDim); - - if (minFound) { + const double * cov = fGSLMultiFit->CovarMatrix(); + if (cov) { - if (trFunc.get() != 0) { + unsigned int ndim = fDim; + fCovMatrix.resize(ndim*ndim); + + if (trFunc.get() ) { trFunc->MatrixTransformation(x, fGSLMultiFit->CovarMatrix(), &fCovMatrix[0] ); } else { - const double * m = fGSLMultiFit->CovarMatrix(); - std::copy(m, m+ fDim*fDim, fCovMatrix.begin() ); + std::copy(cov, cov + ndim*ndim, fCovMatrix.begin() ); } - + for (unsigned int i = 0; i < fDim; ++i) fErrors[i] = std::sqrt(fCovMatrix[i*fDim + i]); + } + + if (minFound) { if (debugLevel >=1 ) { std::cout << "GSLNLSMinimizer: Minimum Found" << std::endl; diff --git a/math/mathmore/src/GSLQRngWrapper.h b/math/mathmore/src/GSLQRngWrapper.h new file mode 100644 index 0000000000000..63588a2bd6763 --- /dev/null +++ b/math/mathmore/src/GSLQRngWrapper.h @@ -0,0 +1,143 @@ +// @(#)root/mathmore:$Id$ +// Author: L. Moneta Fri Aug 24 17:20:45 2007 + +/********************************************************************** + * * + * Copyright (c) 2006 LCG ROOT Math Team, CERN/PH-SFT * + * * + * * + **********************************************************************/ + +// Header file for class GSLQRngWrapper + +#ifndef ROOT_Math_GSLQRngWrapper +#define ROOT_Math_GSLQRngWrapper + +#include "gsl/gsl_qrng.h" + +namespace ROOT { + + namespace Math { + + +/** + GSLQRngWrapper class to wrap gsl_qrng structure +*/ +class GSLQRngWrapper { + +public: + + + /** + Default constructor + */ + GSLQRngWrapper () : + fOwn(0), + fRng(0), + fRngType(0) + { + } + + /** + Constructor with type + */ + GSLQRngWrapper(const gsl_qrng_type * type) : + fOwn(1), + fRng(0), + fRngType(type) + { + } + + /** + construct from an existing gsl_qrng + it is managed externally - so will not be deleted at the end + */ + GSLQRngWrapper(const gsl_qrng * r ) : + fOwn(0), + fRngType(0) + { + fRng = const_cast<gsl_qrng *>(r); + } + + /** + Copy constructor - clone the GSL object and manage it + */ + GSLQRngWrapper(GSLQRngWrapper & r) : + fOwn(1), + fRngType(r.fRngType) + { + fRng = gsl_qrng_clone(r.fRng); + } + + /** + Assignment operator + */ + GSLQRngWrapper & operator = (const GSLQRngWrapper & rhs) { + if (this == &rhs) return *this; // time saving self-test + fRngType = rhs.fRngType; + int iret = 0; + if (fRngType == rhs.fRngType) { + iret = gsl_qrng_memcpy(fRng, rhs.fRng); + if (!iret) return *this; + } + // otherwise create a new copy + if (fOwn) Free(); + fRng = gsl_qrng_clone(rhs.fRng); + fOwn = true; + return *this; + } + + /** + Destructor (free the rng if not done before) + */ + ~GSLQRngWrapper() { + if (fOwn) Free(); + } + + void Allocate(unsigned int dimension) { + if (fRngType == 0) SetDefaultType(); + if (fRng != 0 && fOwn) Free(); + fRng = gsl_qrng_alloc( fRngType, dimension ); + //std::cout << " allocate " << fRng << std::endl; + } + + void Free() { + if (!fOwn) return; // no operation if pointer is not own + //std::cout << "free gslrng " << fRngType << " " << fRng << std::endl; + if (fRng != 0) gsl_qrng_free(fRng); + fRng = 0; + } + + + void SetType(const gsl_qrng_type * type) { + fRngType = type; + } + + void SetDefaultType() { + // construct default engine (Sobol) + fRngType = gsl_qrng_sobol; + } + + + unsigned int Dimension() const { return fRng->dimension; } + + inline gsl_qrng * Rng() { return fRng; } + + inline const gsl_qrng * Rng() const { return fRng; } + + + +private: + + bool fOwn; // ownership of contained pointer + gsl_qrng * fRng; + const gsl_qrng_type * fRngType; +}; + + + } // end namespace Math + +} // end namespace ROOT + + +#endif /* ROOT_Math_GSLQRngWrapper */ diff --git a/math/mathmore/src/GSLQuasiRandom.cxx b/math/mathmore/src/GSLQuasiRandom.cxx new file mode 100644 index 0000000000000..4c96e56f1de2b --- /dev/null +++ b/math/mathmore/src/GSLQuasiRandom.cxx @@ -0,0 +1,186 @@ +// @(#)root/mathmore:$Id$ +// Authors: L. Moneta, A. Zsenei 08/2005 + + /********************************************************************** + * * + * Copyright (c) 2004 ROOT Foundation, CERN/PH-SFT * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of the GNU General Public License * + * as published by the Free Software Foundation; either version 2 * + * of the License, or (at your option) any later version. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * + * General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this library (see file COPYING); if not, write * + * to the Free Software Foundation, Inc., 59 Temple Place, Suite * + * 330, Boston, MA 02111-1307 USA, or contact the author. * + * * + **********************************************************************/ +// +// +// Created by: moneta at Sun Nov 21 :26:03 2004 +// +// Last update: Sun Nov 21 16:26:03 2004 +// + +// need to be included later +#include <time.h> +#include <stdlib.h> +#include <cassert> + + +#include "Math/GSLQuasiRandom.h" +#include "GSLQRngWrapper.h" + +//#include <iostream> + +namespace ROOT { +namespace Math { + + + + + + // default constructor (need to call set type later) + GSLQuasiRandomEngine::GSLQuasiRandomEngine() : + fQRng(0 ) + { } + + // constructor from external rng + // internal generator will be managed or not depending on + // how the GSLQRngWrapper is created + GSLQuasiRandomEngine::GSLQuasiRandomEngine( GSLQRngWrapper * rng) : + fQRng(new GSLQRngWrapper(*rng) ) + {} + + // copy constructor + GSLQuasiRandomEngine::GSLQuasiRandomEngine(const GSLQuasiRandomEngine & eng) : + fQRng(new GSLQRngWrapper(*eng.fQRng) ) + {} + + GSLQuasiRandomEngine::~GSLQuasiRandomEngine() { + // destructor : call terminate if not yet called + if (fQRng) Terminate(); + } + + // assignment operator + GSLQuasiRandomEngine & GSLQuasiRandomEngine::operator=(const GSLQuasiRandomEngine & eng) { + if (this == &eng) return *this; + if (fQRng) + *fQRng = *eng.fQRng; + else + fQRng = new GSLQRngWrapper(*eng.fQRng); + return *this; + } + + + void GSLQuasiRandomEngine::Initialize(unsigned int dimension) { + // initialize the generator by allocating the GSL object + // if type was not passed create with default generator + if (!fQRng) fQRng = new GSLQRngWrapper(); + fQRng->Allocate(dimension); + } + + void GSLQuasiRandomEngine::Terminate() { + // terminate the generator by freeing the GSL object + if (!fQRng) return; + fQRng->Free(); + delete fQRng; + fQRng = 0; + } + + + double GSLQuasiRandomEngine::operator() () const { + // generate next point in the quasi random sequence. The generate number x is 0 < x < 1 + // with 0 and 1 excluded + // This method should be called only if dimension == 1 + assert(fQRng->Dimension() == 1); + double x; + gsl_qrng_get(fQRng->Rng(), &x ); + return x; + } + + bool GSLQuasiRandomEngine::operator() (double * x) const { + // generate next point in the quasi random sequence. The generate number x is 0 < x < 1 + // with 0 and 1 excluded + int status = gsl_qrng_get(fQRng->Rng(), x ); + return (status == 0); + } + + bool GSLQuasiRandomEngine::Skip(unsigned int n) const { + // throw away the next n random numbers + std::vector<double> xtmp(fQRng->Dimension() ); + int status = 0; + for (unsigned int i = 0; i < n; ++i ) { + status |= gsl_qrng_get(fQRng->Rng(), &xtmp[0] ); + } + return status == 0; + } + + bool GSLQuasiRandomEngine::GenerateArray(double * begin, double * end ) const { + // generate array of randoms betweeen 0 and 1. 0 is excluded + // specialization for double * (to be faster) + int status = 0; + for ( double * itr = begin; itr != end; itr+=fQRng->Dimension() ) { + status |= gsl_qrng_get(fQRng->Rng(), itr ); + } + return status == 0; + } + + + std::string GSLQuasiRandomEngine::Name() const { + //---------------------------------------------------- + assert (fQRng != 0); + assert(fQRng->Rng() != 0); + const char * name = gsl_qrng_name( fQRng->Rng() ); + if (!name) return std::string(); + return std::string( name); + } + + unsigned int GSLQuasiRandomEngine::Size() const { + //---------------------------------------------------- + assert (fQRng != 0); + return gsl_qrng_size( fQRng->Rng() ); + } + + unsigned int GSLQuasiRandomEngine::NDim() const { + //---------------------------------------------------- + assert (fQRng != 0); + return fQRng->Dimension(); + } + + + + + //---------------------------------------------------- + // generators + //---------------------------------------------------- + + //---------------------------------------------------- + // generator based on Sobol sequence + GSLQRngSobol::GSLQRngSobol() : GSLQuasiRandomEngine() + { + SetType(new GSLQRngWrapper(gsl_qrng_sobol)); + } + + + // generator based on Bratley-Fox,Niederreiter sequence + GSLQRngNiederreiter2::GSLQRngNiederreiter2() : GSLQuasiRandomEngine() + { + SetType(new GSLQRngWrapper(gsl_qrng_niederreiter_2) ); + } + + + + + +} // namespace Math +} // namespace ROOT + + + diff --git a/math/mathmore/src/GSLRndmEngines.cxx b/math/mathmore/src/GSLRndmEngines.cxx index 89c92e9978a64..6faac2b087145 100644 --- a/math/mathmore/src/GSLRndmEngines.cxx +++ b/math/mathmore/src/GSLRndmEngines.cxx @@ -68,17 +68,28 @@ namespace Math { fCurTime(0) {} -// // constructor from external rng -// GSLRandomEngine( GSLRngWrapper & rng) : -// fRng(new GSLRngWrapper(rng) ), -// fCurTime(0) -// {} + // copy constructor + GSLRandomEngine::GSLRandomEngine(const GSLRandomEngine & eng) : + fRng(new GSLRngWrapper(*eng.fRng) ), + fCurTime(0) + {} GSLRandomEngine::~GSLRandomEngine() { // destructor : call terminate if not yet called if (fRng) Terminate(); } + // assignment operator + GSLRandomEngine & GSLRandomEngine::operator=(const GSLRandomEngine & eng) { + if (this == &eng) return *this; + if (fRng) + *fRng = *eng.fRng; + else + fRng = new GSLRngWrapper(*eng.fRng); + fCurTime = eng.fCurTime; + return *this; + } + void GSLRandomEngine::Initialize() { // initialize the generator by allocating the GSL object diff --git a/math/mathmore/src/GSLRngWrapper.h b/math/mathmore/src/GSLRngWrapper.h index 55a34ea197a31..3cc65b1d61b94 100644 --- a/math/mathmore/src/GSLRngWrapper.h +++ b/math/mathmore/src/GSLRngWrapper.h @@ -59,18 +59,32 @@ class GSLRngWrapper { } /** - Copy constructor - pass ownership (need not to be const) - Just copy the pointer and do not manage it + Copy constructor - clone the GSL object and manage it */ GSLRngWrapper(GSLRngWrapper & r) : - fOwn(r.fOwn), - fRng(r.fRng), + fOwn(1), fRngType(r.fRngType) { - // in case an rng exists must release it - if (fRng && fOwn) r.fOwn = false; + fRng = gsl_rng_clone(r.fRng); } + /** + Assignment operator + */ + GSLRngWrapper & operator = (const GSLRngWrapper & rhs) { + if (this == &rhs) return *this; // time saving self-test + fRngType = rhs.fRngType; + int iret = 0; + if (fRngType == rhs.fRngType) { + iret = gsl_rng_memcpy(fRng, rhs.fRng); + if (!iret) return *this; + } + // otherwise create a new copy + if (fOwn) Free(); + fRng = gsl_rng_clone(rhs.fRng); + fOwn = true; + return *this; + } /** Destructor (free the rng if not done before) @@ -104,24 +118,14 @@ class GSLRngWrapper { fRngType = gsl_rng_default; } - + void PrintState() const { + gsl_rng_print_state(fRng); + } inline gsl_rng * Rng() { return fRng; } inline const gsl_rng * Rng() const { return fRng; } -private: - // usually copying is non trivial, so we make this unaccessible - - - /** - Assignment operator - Disable since if don't want to change an already created wrapper - */ - GSLRngWrapper & operator = (const GSLRngWrapper & rhs) { - if (this == &rhs) return *this; // time saving self-test - return *this; - } private: diff --git a/math/mathmore/src/cblas.cxx b/math/mathmore/src/cblas.cxx new file mode 100644 index 0000000000000..caf40e4829e5d --- /dev/null +++ b/math/mathmore/src/cblas.cxx @@ -0,0 +1,21 @@ +// import just a cblas symbol in mathmore +#include "gsl/gsl_cblas.h" + +namespace ROOT { + + namespace Math { + + namespace Blas { + + // multiplication C = A * B where (n,m) is the size of C, A is size (n,k) and B is size (k,m) + void AMultB(int n, int m, int k, const double * A, const double * B, double *C) { + cblas_dgemm(CblasRowMajor, CblasNoTrans, CblasNoTrans, n, m, k, 1.0, A, k, B, m, 0.0, C, m); + } + // multiplication C = AT * B where (n,m) is the size of C, A is size (k,n) and B is size (k,m) + void ATMultB(int n, int m, int k, const double * A, const double * B, double *C) { + cblas_dgemm(CblasRowMajor, CblasTrans, CblasNoTrans, n, m, k, 1.0, A, n, B, m, 0.0, C, m); + } + + } + } +} diff --git a/math/mathmore/test/Makefile b/math/mathmore/test/Makefile index 2c0c385256b47..5fe5d0edc9926 100644 --- a/math/mathmore/test/Makefile +++ b/math/mathmore/test/Makefile @@ -87,6 +87,10 @@ RANDOMDISTOBJ = testRandomDist.$(ObjSuf) RANDOMDISTSRC = testRandomDist.$(SrcSuf) RANDOMDIST = testRandomDist$(ExeSuf) +QUASIRANDOMOBJ = testQuasiRandom.$(ObjSuf) +QUASIRANDOMSRC = testQuasiRandom.$(SrcSuf) +QUASIRANDOM = testQuasiRandom$(ExeSuf) + SPECFUNCOBJ = testSpecFunc.$(ObjSuf) SPECFUNCSRC = testSpecFunc.$(SrcSuf) SPECFUNC = testSpecFunc$(ExeSuf) @@ -111,11 +115,11 @@ SIMANTSP = simanTSP$(ExeSuf) OBJS = $(CHEBYSHEVOBJ) $(DERIVATIONOBJ) $(INTEGRATIONOBJ) $(INTEGRATIONMDOBJ) $(ROOTFINDEROBJ) $(MULTIROOTFINDEROBJ)\ - $(MINIMIZATION1DOBJ) $(INTERPOLATIONOBJ) $(RANDOMOBJ) $(RANDOMDISTOBJ) \ + $(MINIMIZATION1DOBJ) $(INTERPOLATIONOBJ) $(RANDOMOBJ) $(RANDOMDISTOBJ) $(QUASIRANDOMOBJ) \ $(SPECFUNCOBJ) $(STATFUNCOBJ) $(TESTFUNCTOROBJ) $(TESTPERMUTEOBJ) $(TESTVAVILOVOBJ) $(SIMANTSPOBJ) PROGRAMS = $(CHEBYSHEV) $(DERIVATION) $(INTEGRATION) $(INTEGRATIONMD) $(ROOTFINDER) $(MULTIROOTFINDER) \ - $(MINIMIZATION1D) $(INTERPOLATION) $(RANDOM) $(RANDOMDIST) \ + $(MINIMIZATION1D) $(INTERPOLATION) $(RANDOM) $(RANDOMDIST) $(QUASIRANDOM) \ $(SPECFUNC) $(STATFUNC) $(TESTFUNCTOR) $(TESTPERMUTE) $(TESTVAVILOV) $(SIMANTSP) .SUFFIXES: .$(SrcSuf) .$(ObjSuf) $(ExeSuf) @@ -167,6 +171,10 @@ $(RANDOMDIST): $(RANDOMDISTOBJ) $(LD) $(LDFLAGS) $^ $(LIBS) $(EXTRALIBS) $(UNURANLIB) $(OutPutOpt)$@ @echo "$@ done" +$(QUASIRANDOM): $(QUASIRANDOMOBJ) + $(LD) $(LDFLAGS) $^ $(LIBS) $(EXTRALIBS) $(OutPutOpt)$@ + @echo "$@ done" + $(SPECFUNC): $(SPECFUNCOBJ) $(LD) $(LDFLAGS) $^ $(LIBS) $(EXTRALIBS) $(OutPutOpt)$@ @echo "$@ done" diff --git a/math/mathmore/test/testChebyshev.cxx b/math/mathmore/test/testChebyshev.cxx index a5d04dc19a56f..c142bc30d2105 100644 --- a/math/mathmore/test/testChebyshev.cxx +++ b/math/mathmore/test/testChebyshev.cxx @@ -1,5 +1,5 @@ -#include "Math/Chebyshev.h" +#include "Math/ChebyshevApprox.h" #include "Math/IFunction.h" #include "Math/Functor.h" #include "Math/SpecFunc.h" @@ -46,7 +46,7 @@ class GammaFunction : public ROOT::Math::IGenFunction { }; -int printCheb( const ROOT::Math::Chebyshev & c, double x0, double x1, FP func = 0 ) { +int printCheb( const ROOT::Math::ChebyshevApprox & c, double x0, double x1, FP func = 0 ) { double dx = (x1-x0)/10; for ( double x = x0; x < x1; x+= dx ) { @@ -72,20 +72,20 @@ int main() { // test with cos(x) + 1.0 std::cout << "Test Cheb approx to step function :" << std::endl; - ROOT::Math::Chebyshev c(myfunc, 0, 0., 1.0, 40); + ROOT::Math::ChebyshevApprox c(myfunc, 0, 0., 1.0, 40); printCheb(c, 0, 1, myfunc); std::cout << "Test integral of step function :" << std::endl; - ROOT::Math::Chebyshev * cInteg = c.Integral(); + ROOT::Math::ChebyshevApprox * cInteg = c.Integral(); printCheb(*cInteg, 0., 1); delete cInteg; std::cout << "Test Cheb approx to Gamma function :" << std::endl; GammaFunction gf; - ROOT::Math::Chebyshev c2(gf, 1.0, 2.0, 40); + ROOT::Math::ChebyshevApprox c2(gf, 1.0, 2.0, 40); printCheb(c2, 1.0, 2.0, gamma_func); std::cout << "Test derivative of gammma :" << std::endl; - ROOT::Math::Chebyshev * cDeriv = c2.Deriv(); + ROOT::Math::ChebyshevApprox * cDeriv = c2.Deriv(); printCheb(*cDeriv, 1.0, 2.0); delete cDeriv; diff --git a/math/mathmore/test/testQuasiRandom.cxx b/math/mathmore/test/testQuasiRandom.cxx new file mode 100644 index 0000000000000..89ab8c4acf976 --- /dev/null +++ b/math/mathmore/test/testQuasiRandom.cxx @@ -0,0 +1,115 @@ +// test program for quasi random numbers + +#include "Math/QuasiRandom.h" +#include "Math/Random.h" +#include "TH2.h" +#include "TCanvas.h" +#include "TApplication.h" +//#include "TSopwatch.h" + +#include <iostream> + +using namespace ROOT::Math; + +int testQuasiRandom() { + + const int n = 10000; + + TH2D * h0 = new TH2D("h0","Pseudo-random Sequence",200,0,1,200,0,1); + TH2D * h1 = new TH2D("h1","Sobol Sequence",200,0,1,200,0,1); + TH2D * h2 = new TH2D("h2","Niederrer Sequence",200,0,1,200,0,1); + + RandomMT r0; + QuasiRandomSobol r1(2); + QuasiRandomNiederreiter r2(2); + + + // generate n sequences + + double x[2]; + for (unsigned int i = 0; i < n; ++i) { + r0.RndmArray(2,x); + h0->Fill(x[0],x[1]); + } + + + for (unsigned int i = 0; i < n; ++i) { + r1.Next(x); + h1->Fill(x[0],x[1]); + } + + double vx[2*n]; + r2.RndmArray(n,vx); + for (unsigned int i = 0; i < n; ++i) { + h2->Fill(vx[2*i],vx[2*i+1]); + } + + + TCanvas * c1 = new TCanvas("c1","Random sequence",600,1200); + c1->Divide(1,3); + + c1->cd(1); + + h0->Draw("COLZ"); + + c1->cd(2); + + + // check uniformity + h1->Draw("COLZ"); + + c1->cd(3); + + h2->Draw("COLZ"); + + gPad->Update(); + + + // test number of empty bins + + int nzerobins0 = 0; + int nzerobins1 = 0; + int nzerobins2 = 0; + for (int i = 1; i <= h1->GetNbinsX(); ++i) { + for (int j = 1; j <= h1->GetNbinsY(); ++j) { + if (h0->GetBinContent(i,j) == 0 ) nzerobins0++; + if (h1->GetBinContent(i,j) == 0 ) nzerobins1++; + if (h2->GetBinContent(i,j) == 0 ) nzerobins2++; + } + } + + std::cout << "number of empty bins for pseudo-random = " << nzerobins0 << std::endl; + std::cout << "number of empty bins for Sobol = " << nzerobins1 << std::endl; + std::cout << "number of empty bins for Niederreiter = " << nzerobins2 << std::endl; + + int iret = 0; + if (nzerobins1 >= nzerobins0 ) iret += 1; + if (nzerobins2 >= nzerobins0 ) iret += 2; + return iret; +} + + +int main(int argc, char **argv) +{ + + std::cout << "***************************************************\n"; + std::cout << " TEST QUASI-RANDOM generators "<< std::endl; + std::cout << "***************************************************\n\n"; + + int iret = 0; + if (argc > 1) { + TApplication theApp("App",&argc,argv); + iret = testQuasiRandom(); + theApp.Run(); + } + else + iret = testQuasiRandom(); + + if (iret != 0) std::cerr << "TEST QUASI-RANDOM FAILED " << std::endl; + + return iret; + + + + +} diff --git a/math/matrix/inc/TMatrixTUtils.h b/math/matrix/inc/TMatrixTUtils.h index 1aae7cbd28a74..28288b6db7534 100644 --- a/math/matrix/inc/TMatrixTUtils.h +++ b/math/matrix/inc/TMatrixTUtils.h @@ -574,7 +574,7 @@ template<class Element> class TMatrixTSub : public TMatrixTSub_const<Element> { template<class Element> class TMatrixTSparseRow_const { protected: - const TMatrixTBase<Element> *fMatrix; // the matrix I am a row of + const TMatrixTSparse<Element> *fMatrix; // the matrix I am a row of Int_t fRowInd; // effective row index Int_t fNindex; // index range const Int_t *fColPtr; // column index pointer @@ -640,7 +640,7 @@ template<class Element> class TMatrixTSparseRow : public TMatrixTSparseRow_const template<class Element> class TMatrixTSparseDiag_const { protected: - const TMatrixTBase<Element> *fMatrix; // the matrix I am the diagonal of + const TMatrixTSparse<Element> *fMatrix; // the matrix I am the diagonal of Int_t fNdiag; // number of diag elems, min(nrows,ncols) const Element *fDataPtr; // data pointer diff --git a/math/matrix/src/TMatrixT.cxx b/math/matrix/src/TMatrixT.cxx index e3e549b78b965..21d8fa28210a6 100644 --- a/math/matrix/src/TMatrixT.cxx +++ b/math/matrix/src/TMatrixT.cxx @@ -1370,24 +1370,26 @@ void TMatrixT<Element>::Determinant(Double_t &d1,Double_t &d2) const lu.Det(d1,d2); } +//______________________________________________________________________________ +template <> +TMatrixT<Double_t> &TMatrixT<Double_t>::Invert(Double_t *det) +{ +// Invert the matrix and calculate its determinant + + R__ASSERT(this->IsValid()); + TDecompLU::InvertLU(*this, Double_t(fTol), det); + return *this; +} + //______________________________________________________________________________ template<class Element> TMatrixT<Element> &TMatrixT<Element>::Invert(Double_t *det) { // Invert the matrix and calculate its determinant - R__ASSERT(this->IsValid()); - if (typeid(Element) == typeid(Double_t)) - TDecompLU::InvertLU(*dynamic_cast<TMatrixD *>(this),Double_t(this->fTol),det); - else { - TMatrixD tmp(*this); - if (TDecompLU::InvertLU(tmp,Double_t(this->fTol),det)) { - const Double_t *p1 = tmp.GetMatrixArray(); - Element *p2 = this->GetMatrixArray(); - for (Int_t i = 0; i < this->GetNoElements(); i++) - p2[i] = p1[i]; - } - } + TMatrixD tmp(*this); + if (TDecompLU::InvertLU(tmp, Double_t(this->fTol),det)) + std::copy(tmp.GetMatrixArray(), tmp.GetMatrixArray() + this->GetNoElements(), this->GetMatrixArray()); return *this; } @@ -1445,23 +1447,11 @@ TMatrixT<Element> &TMatrixT<Element>::InvertFast(Double_t *det) TMatrixTCramerInv::Inv6x6<Element>(*this,det); return *this; } - default: { - if(typeid(Element) == typeid(Double_t)) - TDecompLU::InvertLU(*dynamic_cast<TMatrixD *>(this),Double_t(this->fTol),det); - else { - TMatrixD tmp(*this); - if (TDecompLU::InvertLU(tmp,Double_t(this->fTol),det)) { - const Double_t *p1 = tmp.GetMatrixArray(); - Element *p2 = this->GetMatrixArray(); - for (Int_t i = 0; i < this->GetNoElements(); i++) - p2[i] = p1[i]; - } - } - return *this; + return Invert(det); } - } + } } //______________________________________________________________________________ diff --git a/math/matrix/src/TMatrixTBase.cxx b/math/matrix/src/TMatrixTBase.cxx index b30a988110ae7..02b21df1aacbd 100644 --- a/math/matrix/src/TMatrixTBase.cxx +++ b/math/matrix/src/TMatrixTBase.cxx @@ -1,4 +1,4 @@ -// @(#)root/matrix:$Id$ +// @(#)root/matrix:$Id: 2d00df45ce4c38c7ea0930d6b520cbf4cfb9152e $ // Authors: Fons Rademakers, Eddy Offermann Nov 2003 /************************************************************************* @@ -434,9 +434,10 @@ void TMatrixTBase<Element>::GetMatrix2Array(Element *data,Option_t *option) cons for (Int_t irow = 0; irow < fNrows; irow++) { const Int_t off1 = irow*fNcols; Int_t off2 = 0; - for (Int_t icol = 0; icol < fNcols; icol++) + for (Int_t icol = 0; icol < fNcols; icol++) { data[off2+irow] = elem[off1+icol]; - off2 += fNrows; + off2 += fNrows; + } } } else diff --git a/math/matrix/src/TMatrixTSym.cxx b/math/matrix/src/TMatrixTSym.cxx index 2bf8f6cb24354..3024827f1858b 100644 --- a/math/matrix/src/TMatrixTSym.cxx +++ b/math/matrix/src/TMatrixTSym.cxx @@ -169,12 +169,14 @@ TMatrixTSym<Element>::TMatrixTSym(const TMatrixTSym<Element> &a,EMatrixCreatorsO switch(op) { case kPlus: { + Allocate(a.GetNcols(),a.GetNcols(),a.GetColLwb(),a.GetColLwb(),1); Plus(a,b); break; } case kMinus: { + Allocate(a.GetNcols(),a.GetNcols(),a.GetColLwb(),a.GetColLwb(),1); Minus(a,b); break; } diff --git a/math/matrix/src/TMatrixTUtils.cxx b/math/matrix/src/TMatrixTUtils.cxx index 672ff84daae16..e2a7dece37f98 100644 --- a/math/matrix/src/TMatrixTUtils.cxx +++ b/math/matrix/src/TMatrixTUtils.cxx @@ -1417,7 +1417,7 @@ Element &TMatrixTSparseRow<Element>::operator()(Int_t i) if (index >= 0 && this->fColPtr[index] == acoln) return (const_cast<Element*>(this->fDataPtr))[index]; else { - TMatrixTBase<Element> *mt = const_cast<TMatrixTBase<Element> *>(this->fMatrix); + TMatrixTSparse<Element> *mt = const_cast<TMatrixTSparse<Element> *>(this->fMatrix); const Int_t row = this->fRowInd+mt->GetRowLwb(); Element val = 0.; mt->InsertRow(row,i,&val,1); @@ -1495,7 +1495,7 @@ void TMatrixTSparseRow<Element>::operator=(const TMatrixTSparseRow_const<Element TVectorT<Element> v(ncols); mt->ExtractRow(row2,col,v.GetMatrixArray()); - const_cast<TMatrixTBase<Element> *>(this->fMatrix)->InsertRow(row1,col,v.GetMatrixArray()); + const_cast<TMatrixTSparse<Element> *>(this->fMatrix)->InsertRow(row1,col,v.GetMatrixArray()); const Int_t sIndex = this->fMatrix->GetRowIndexArray()[this->fRowInd]; const Int_t eIndex = this->fMatrix->GetRowIndexArray()[this->fRowInd+1]; @@ -1522,7 +1522,7 @@ void TMatrixTSparseRow<Element>::operator=(const TVectorT<Element> &vec) const Element *vp = vec.GetMatrixArray(); const Int_t row = this->fRowInd+this->fMatrix->GetRowLwb(); const Int_t col = this->fMatrix->GetColLwb(); - const_cast<TMatrixTBase<Element> *>(this->fMatrix)->InsertRow(row,col,vp,vec.GetNrows()); + const_cast<TMatrixTSparse<Element> *>(this->fMatrix)->InsertRow(row,col,vp,vec.GetNrows()); const Int_t sIndex = this->fMatrix->GetRowIndexArray()[this->fRowInd]; const Int_t eIndex = this->fMatrix->GetRowIndexArray()[this->fRowInd+1]; @@ -1556,7 +1556,7 @@ void TMatrixTSparseRow<Element>::operator+=(const TMatrixTSparseRow_const<Elemen this->fMatrix->ExtractRow(row1,col,v1.GetMatrixArray()); mt ->ExtractRow(row2,col,v2.GetMatrixArray()); v1 += v2; - const_cast<TMatrixTBase<Element> *>(this->fMatrix)->InsertRow(row1,col,v1.GetMatrixArray()); + const_cast<TMatrixTSparse<Element> *>(this->fMatrix)->InsertRow(row1,col,v1.GetMatrixArray()); const Int_t sIndex = this->fMatrix->GetRowIndexArray()[this->fRowInd]; const Int_t eIndex = this->fMatrix->GetRowIndexArray()[this->fRowInd+1]; @@ -1592,7 +1592,7 @@ void TMatrixTSparseRow<Element>::operator*=(const TMatrixTSparseRow_const<Elemen mt ->ExtractRow(row2,col,v2.GetMatrixArray()); ElementMult(v1,v2); - const_cast<TMatrixTBase<Element> *>(this->fMatrix)->InsertRow(row1,col,v1.GetMatrixArray()); + const_cast<TMatrixTSparse<Element> *>(this->fMatrix)->InsertRow(row1,col,v1.GetMatrixArray()); const Int_t sIndex = this->fMatrix->GetRowIndexArray()[this->fRowInd]; const Int_t eIndex = this->fMatrix->GetRowIndexArray()[this->fRowInd+1]; @@ -1687,7 +1687,7 @@ Element &TMatrixTSparseDiag<Element>::operator()(Int_t i) return (const_cast<Element*>(this->fDataPtr))[0]; } - TMatrixTBase<Element> *mt = const_cast<TMatrixTBase<Element> *>(this->fMatrix); + TMatrixTSparse<Element> *mt = const_cast<TMatrixTSparse<Element> *>(this->fMatrix); const Int_t *pR = mt->GetRowIndexArray(); const Int_t *pC = mt->GetColIndexArray(); Int_t sIndex = pR[i]; diff --git a/math/matrix/src/TVectorT.cxx b/math/matrix/src/TVectorT.cxx index 0f2ffe8dd818c..4f0581865ec03 100644 --- a/math/matrix/src/TVectorT.cxx +++ b/math/matrix/src/TVectorT.cxx @@ -289,7 +289,7 @@ TVectorT<Element> &TVectorT<Element>::ResizeTo(Int_t lwb,Int_t upb) { // Resize the vector to [lwb:upb] . // New dynamic elemenst are created, the overlapping part of the old ones are -// copied to the new structures, then the old elements are deleleted. +// copied to the new structures, then the old elements are deleted. R__ASSERT(IsValid()); if (!fIsOwner) { diff --git a/math/minuit/inc/TMinuitMinimizer.h b/math/minuit/inc/TMinuitMinimizer.h index 3e79503676450..b66f080cbbe1e 100644 --- a/math/minuit/inc/TMinuitMinimizer.h +++ b/math/minuit/inc/TMinuitMinimizer.h @@ -94,12 +94,11 @@ class TMinuitMinimizer : public ROOT::Math::Minimizer { /// set upper/lower limited variable (override if minimizer supports them ) virtual bool SetLimitedVariable(unsigned int ivar , const std::string & name , double val , double step , double /* lower */, double /* upper */); -#ifdef LATER /// set lower limit variable (override if minimizer supports them ) virtual bool SetLowerLimitedVariable(unsigned int ivar , const std::string & name , double val , double step , double lower ); + /// set upper limit variable (override if minimizer supports them ) virtual bool SetUpperLimitedVariable(unsigned int ivar , const std::string & name , double val , double step , double upper ); -#endif /// set fixed variable (override if minimizer supports them ) virtual bool SetFixedVariable(unsigned int /* ivar */, const std::string & /* name */, double /* val */); diff --git a/math/minuit/src/TMinuit.cxx b/math/minuit/src/TMinuit.cxx index 1b7cf559d84d4..92dbb32e83dde 100644 --- a/math/minuit/src/TMinuit.cxx +++ b/math/minuit/src/TMinuit.cxx @@ -1195,6 +1195,7 @@ void TMinuit::mncntr(Int_t ike1, Int_t ike2, Int_t &ierrf) bwidx = (xup - xlo) / Double_t(nx); bwidy = (yup - ylo) / Double_t(ny); ixmid = Int_t(((xsav - xlo)*Double_t(nx) / (xup - xlo)) + 1); + if (ixmid < 1) ixmid = 1; if (fAmin == fUndefi) mnamin(); for (i = 1; i <= 20; ++i) { contur[i-1] = fAmin + fUp*(i-1)*(i-1); } @@ -2873,6 +2874,7 @@ void TMinuit::mnexcm(const char *command, Double_t *plist, Int_t llist, Int_t &i //*-*- possible loop over new minima fEpsi = fUp*.1; L510: + fCfrom = cname[i-1]; // ensure that mncuve complains about MINOS not MIGRAD mncuve(); mnmnos(); if (! fLnewmn) return; @@ -3835,7 +3837,7 @@ void TMinuit::mnhelp(TString comd) Printf(" reading. Note that this command is implemented in standard"); Printf(" Fortran 77 and the results may depend on the system;"); Printf(" for example, if a filename is given under VM/CMS, it must"); - Printf(" be preceeded by a slash."); + Printf(" be preceded by a slash."); Printf(" "); Printf(" SET INTeractive"); @@ -5881,6 +5883,7 @@ void TMinuit::mnparm(Int_t k1, TString cnamj, Double_t uk, Double_t wk, Double_t } } if (ktofix > 0) { + ierr = 0; kinfix = fNiofex[ktofix-1]; if (kinfix > 0) mnfixp(kinfix-1, ierr); if (ierr > 0) goto L800; @@ -6263,11 +6266,11 @@ void TMinuit::mnplot(Double_t *xpt, Double_t *ypt, char *chpt, Int_t nxypt, Int_ for (ibk = 1; ibk <= 12; ++ibk) { xvalus[ibk-1] = xmin + Double_t(ibk-1)*10*bwidx; } - printf(" "); iten = (nx + 9) / 10; - for (ibk = 1; ibk <= iten; ++ibk) { - Printf(" %9.4g", xvalus[ibk-1]); + for (ibk = 1; ibk <= iten && ibk <= 12; ++ibk) { + snprintf(cline + (ibk-1)*10, 11-(ibk == 12), "%#9.3g ", xvalus[ibk-1]); } + Printf(" %s", cline); chmess = " "; if (overpr) chmess = " Overprint character is &"; Printf(" ONE COLUMN=%13.7g%s",bwidx,(const char*)chmess); diff --git a/math/minuit/src/TMinuitMinimizer.cxx b/math/minuit/src/TMinuitMinimizer.cxx index 738221d2e2e93..0bfbfff058f0b 100644 --- a/math/minuit/src/TMinuitMinimizer.cxx +++ b/math/minuit/src/TMinuitMinimizer.cxx @@ -297,30 +297,20 @@ bool TMinuitMinimizer::SetLimitedVariable(unsigned int ivar, const std::string & int iret = fMinuit->DefineParameter(ivar, name.c_str(), val, step, lower, upper ); return (iret == 0); } -#ifdef LATER -bool Minuit2Minimizer::SetLowerLimitedVariable(unsigned int ivar , const std::string & name , double val , double step , double lower ) { - // add a lower bounded variable as a double bound one, using a very large number for the upper limit - if (fMinuit == 0) { - Error("SetVariable","invalid TMinuit pointer. Need to call first SetFunction"); - return false; - } - - fUsed = fgUsed; - - // clear after minimization when setting params - if (fUsed) DoClear(); - - // check if parameter was defined and in case it was fixed, release it - DoReleaseFixParameter(ivar); - - double s = val-lower; - double upper = s*1.0E15; - if (s != 0) upper = 1.0E15; - return SetLimitedVariable(ivar, name, val, step, lower,upper); +bool TMinuitMinimizer::SetLowerLimitedVariable(unsigned int ivar , const std::string & name , double val , double step , double lower ) { + // set a lower limited variable + // since is not supported in TMinuit , just use a artificial large value + Warning("TMinuitMinimizer::SetLowerLimitedVariable","not implemented - use as upper limit 1.E7 instead of +inf"); + return SetLimitedVariable(ivar, name, val , step, lower, lower+ 1.E7); // use 1.E7 which will make TMinuit happy } -#endif +bool TMinuitMinimizer::SetUpperLimitedVariable(unsigned int ivar , const std::string & name , double val , double step , double upper ) { + // set a upper limited variable + // since is not supported in TMinuit , just use a artificial large negative value + Warning("TMinuitMinimizer::SetUpperLimitedVariable","not implemented - use as lower limit -1.E7 instead of -inf"); + return SetLimitedVariable(ivar, name, val , step, upper -1.E7, upper); +} bool TMinuitMinimizer::SetFixedVariable(unsigned int ivar, const std::string & name, double val) { // set a fixed variable. @@ -384,17 +374,29 @@ bool TMinuitMinimizer::Minimize() { if (fMinuit == 0) { - Error("Minimize","invalid TMinuit pointer. Need to call first SetFunction and SetVariable"); + Error("TMinuitMinimizer::Minimize","invalid TMinuit pointer. Need to call first SetFunction and SetVariable"); return false; } // total number of parameter defined in Minuit is fNu if (fMinuit->fNu < static_cast<int>(fDim) ) { - Error("Minimize","The total number of defined parameters is different than the function dimension, npar = %d, dim = %d",fMinuit->fNu, fDim); + Error("TMinuitMinimizer::Minimize","The total number of defined parameters is different than the function dimension, npar = %d, dim = %d",fMinuit->fNu, fDim); return false; } + int printlevel = PrintLevel(); + + // total number of free parameter is 0 + if (fMinuit->fNpar <= 0) { + // retrieve parameters values from TMinuit + RetrieveParams(); + fMinuit->fAmin = (*fgFunc)(&fParams.front()); + if (printlevel > 0) Info("TMinuitMinimizer::Minimize","There are no free parameter - just compute the function value"); + return true; + } + + double arglist[10]; int ierr = 0; @@ -403,7 +405,6 @@ bool TMinuitMinimizer::Minimize() { arglist[0] = ErrorDef(); fMinuit->mnexcm("SET Err",arglist,1,ierr); - int printlevel = PrintLevel(); arglist[0] = printlevel - 1; fMinuit->mnexcm("SET PRINT",arglist,1,ierr); @@ -465,13 +466,13 @@ bool TMinuitMinimizer::Minimize() { fStatus = ierr; int minErrStatus = ierr; - if (printlevel>2) Info("Minimize","Finished to run MIGRAD - status %d",ierr); + if (printlevel>2) Info("TMinuitMinimizer::Minimize","Finished to run MIGRAD - status %d",ierr); // run improved if needed if (ierr == 0 && fType == ROOT::Minuit::kMigradImproved) { fMinuit->mnexcm("IMPROVE",arglist,1,ierr); fStatus += 1000*ierr; - if (printlevel>2) Info("Minimize","Finished to run IMPROVE - status %d",ierr); + if (printlevel>2) Info("TMinuitMinimizer::Minimize","Finished to run IMPROVE - status %d",ierr); } @@ -481,7 +482,7 @@ bool TMinuitMinimizer::Minimize() { if (minErrStatus == 0 && (IsValidError() || ( strategy >=1 && CovMatrixStatus() < 3) ) ) { fMinuit->mnexcm("HESSE",arglist,1,ierr); fStatus += 100*ierr; - if (printlevel>2) Info("Minimize","Finished to run HESSE - status %d",ierr); + if (printlevel>2) Info("TMinuitMinimizer::Minimize","Finished to run HESSE - status %d",ierr); } // retrieve parameters and errors from TMinuit @@ -590,7 +591,7 @@ bool TMinuitMinimizer::GetCovMatrix(double * cov) const { // get covariance matrix int covStatus = CovMatrixStatus(); if ( fCovar.size() != fDim*fDim || covStatus < 2) { - Error("GetHessianMatrix","Hessian matrix has not been computed - status %d",covStatus); + Error("TMinuitMinimizer::GetHessianMatrix","Hessian matrix has not been computed - status %d",covStatus); return false; } std::copy(fCovar.begin(), fCovar.end(), cov); @@ -604,7 +605,7 @@ bool TMinuitMinimizer::GetHessianMatrix(double * hes) const { // but need to get the compact form to avoid the zero for the fixed parameters int covStatus = CovMatrixStatus(); if ( fCovar.size() != fDim*fDim || covStatus < 2) { - Error("GetHessianMatrix","Hessian matrix has not been computed - status %d",covStatus); + Error("TMinuitMinimizer::GetHessianMatrix","Hessian matrix has not been computed - status %d",covStatus); return false; } // case of fixed params need to take care @@ -666,33 +667,42 @@ bool TMinuitMinimizer::GetMinosError(unsigned int i, double & errLow, double & e // Perform Minos analysis for the given parameter i if (fMinuit == 0) { - Error("GetMinosError","invalid TMinuit pointer. Need to call first SetFunction and SetVariable"); + Error("TMinuitMinimizer::GetMinosError","invalid TMinuit pointer. Need to call first SetFunction and SetVariable"); return false; } + // check if parameter is fixed + if (fMinuit->fNiofex[i] == 0 ) { + if (PrintLevel() > 0) Info("TMinuitMinimizer::GetMinosError","Parameter %s is fixed. There are no Minos error to calculate. Ignored.",VariableName(i).c_str()); + errLow = 0; errUp = 0; + return true; + } + double arglist[2]; int ierr = 0; - // if Minos is not run run it - if (!fMinosRun) { - - // set error and print level + // set error and print level, precision and stratgey if needed + if (fMinuit->fUp != ErrorDef() ) { arglist[0] = ErrorDef(); fMinuit->mnexcm("SET Err",arglist,1,ierr); + } + if (fMinuit->fISW[4] != (PrintLevel()-1) ) { arglist[0] = PrintLevel()-1; fMinuit->mnexcm("SET PRINT",arglist,1,ierr); - // suppress warning in case Printlevel() == 0 if (PrintLevel() == 0) fMinuit->mnexcm("SET NOW",arglist,0,ierr); + } + if (fMinuit->fIstrat != Strategy() ) { + arglist[0] = Strategy(); + fMinuit->mnexcm("SET STR",arglist,1,ierr); + } - // set precision if needed - if (Precision() > 0) { - arglist[0] = Precision(); - fMinuit->mnexcm("SET EPS",arglist,1,ierr); - } - + if (Precision() > 0 && fMinuit->fEpsma2 != Precision() ) { + arglist[0] = Precision(); + fMinuit->mnexcm("SET EPS",arglist,1,ierr); } + // syntax of MINOS is MINOS [maxcalls] [parno] // if parno = 0 all parameters are done @@ -701,6 +711,18 @@ bool TMinuitMinimizer::GetMinosError(unsigned int i, double & errLow, double & e int nargs = 2; fMinuit->mnexcm("MINOS",arglist,nargs,ierr); + bool isValid = (ierr == 0); + // check also the status from fCstatu + if (isValid && fMinuit->fCstatu != "SUCCESSFUL") { + if (fMinuit->fCstatu == "FAILURE" ) { + // in this case MINOS failed on all prameter, so it is not valid ! + ierr = 5; + isValid = false; + } + if (fMinuit->fCstatu == "PROBLEMS") ierr = 6; + ierr = 7; // this should be the case UNCHANGED + } + fStatus += 10*ierr; fMinosRun = true; @@ -710,8 +732,8 @@ bool TMinuitMinimizer::GetMinosError(unsigned int i, double & errLow, double & e // what returns if parameter fixed or constant or at limit ? fMinuit->mnerrs(i,errUp,errLow, errParab, gcor); - if (fStatus%100 != 0 ) return false; - return true; + // do not flag errors case of PROBLEMS or UNCHANGED ( + return isValid; } @@ -801,21 +823,20 @@ bool TMinuitMinimizer::Contour(unsigned int ipar, unsigned int jpar, unsigned in if (npoints < 4) { - Error("Contour","Cannot make contour with so few points"); + Error("TMinuitMinimizer::Contour","Cannot make contour with so few points"); return false; } int npfound = 0; - npoints -= 1; // remove always one point in TMinuit // parameter numbers in mncont start from zero fMinuit->mncont( ipar,jpar,npoints, x, y,npfound); if (npfound<4) { // mncont did go wrong - Error("Contour","Cannot find more than 4 points"); + Error("TMinuitMinimizer::Contour","Cannot find more than 4 points"); return false; } if (npfound!=(int)npoints) { // mncont did go wrong - Warning("Contour","Returning only %d points ",npfound); + Warning("TMinuitMinimizer::Contour","Returning only %d points ",npfound); npoints = npfound; } return true; @@ -898,7 +919,7 @@ bool TMinuitMinimizer::Hesse() { // perform calculation of Hessian if (fMinuit == 0) { - Error("Hesse","invalid TMinuit pointer. Need to call first SetFunction and SetVariable"); + Error("TMinuitMinimizer::Hesse","invalid TMinuit pointer. Need to call first SetFunction and SetVariable"); return false; } diff --git a/math/minuit2/inc/Minuit2/FumiliStandardChi2FCN.h b/math/minuit2/inc/Minuit2/FumiliStandardChi2FCN.h index 1909ff4f0584c..3e69de92e424c 100644 --- a/math/minuit2/inc/Minuit2/FumiliStandardChi2FCN.h +++ b/math/minuit2/inc/Minuit2/FumiliStandardChi2FCN.h @@ -64,8 +64,8 @@ class FumiliStandardChi2FCN : public FumiliChi2FCN { FumiliStandardChi2FCN(const ParametricFunction& modelFCN, const std::vector<double>& meas, const std::vector<double>& pos, - const std::vector<double>& mvar) : - fErrorDef(1.) { //this->fModelFCN = &modelFunction; + const std::vector<double>& mvar) + { //this->fModelFCN = &modelFunction; this->SetModelFunction(modelFCN); assert(meas.size() == pos.size()); @@ -109,8 +109,8 @@ class FumiliStandardChi2FCN : public FumiliChi2FCN { FumiliStandardChi2FCN(const ParametricFunction& modelFCN, const std::vector<double>& meas, const std::vector<std::vector<double> >& pos, - const std::vector<double>& mvar) : - fErrorDef(1.) { //this->fModelFCN = &modelFunction; + const std::vector<double>& mvar) + { //this->fModelFCN = &modelFunction; this->SetModelFunction(modelFCN); assert(meas.size() == pos.size()); @@ -206,10 +206,6 @@ class FumiliStandardChi2FCN : public FumiliChi2FCN { // support multi dim coordinates std::vector<std::vector<double> > fPositions; std::vector<double> fInvErrors; - double fErrorDef; - - - }; } // namespace Minuit2 diff --git a/math/minuit2/inc/Minuit2/FumiliStandardMaximumLikelihoodFCN.h b/math/minuit2/inc/Minuit2/FumiliStandardMaximumLikelihoodFCN.h index ab6ea60604c9c..b06dfe58c8365 100644 --- a/math/minuit2/inc/Minuit2/FumiliStandardMaximumLikelihoodFCN.h +++ b/math/minuit2/inc/Minuit2/FumiliStandardMaximumLikelihoodFCN.h @@ -52,8 +52,7 @@ class FumiliStandardMaximumLikelihoodFCN : public FumiliMaximumLikelihoodFCN { */ FumiliStandardMaximumLikelihoodFCN(const ParametricFunction& modelFCN, - const std::vector<double>& pos) : - fErrorDef(0.5) + const std::vector<double>& pos) { this->SetModelFunction(modelFCN); unsigned int n = pos.size(); @@ -79,8 +78,8 @@ class FumiliStandardMaximumLikelihoodFCN : public FumiliMaximumLikelihoodFCN { */ FumiliStandardMaximumLikelihoodFCN(const ParametricFunction& modelFCN, - const std::vector<std::vector<double> >& pos) : - fErrorDef(0.5) { + const std::vector<std::vector<double> >& pos) + { this->SetModelFunction(modelFCN); fPositions = pos; @@ -151,10 +150,6 @@ class FumiliStandardMaximumLikelihoodFCN : public FumiliMaximumLikelihoodFCN { private: std::vector<std::vector<double> > fPositions; - double fErrorDef; - - - }; } // namespace Minuit2 diff --git a/math/minuit2/inc/Minuit2/StackAllocator.h b/math/minuit2/inc/Minuit2/StackAllocator.h index b37030185f043..f667143c4bf41 100644 --- a/math/minuit2/inc/Minuit2/StackAllocator.h +++ b/math/minuit2/inc/Minuit2/StackAllocator.h @@ -26,6 +26,7 @@ #include <cstdlib> +#include <new> namespace ROOT { @@ -94,6 +95,7 @@ class StackAllocator { #else void* result = malloc(nBytes); + if (!result) throw std::bad_alloc(); #endif return result; diff --git a/math/minuit2/src/FumiliBuilder.cxx b/math/minuit2/src/FumiliBuilder.cxx index 3cdc2853ba8fd..a18e6548c680c 100644 --- a/math/minuit2/src/FumiliBuilder.cxx +++ b/math/minuit2/src/FumiliBuilder.cxx @@ -46,7 +46,7 @@ double inner_product(const LAVector&, const LAVector&); FunctionMinimum FumiliBuilder::Minimum(const MnFcn& fcn, const GradientCalculator& gc, const MinimumSeed& seed, const MnStrategy& strategy, unsigned int maxfcn, double edmval) const { // top level function to find minimum from a given initial seed - // iterate on a minimum search in case of first attempt is not succesfull + // iterate on a minimum search in case of first attempt is not successful edmval *= 0.0001; //edmval *= 0.1; // use small factor for Fumili @@ -414,7 +414,7 @@ FunctionMinimum FumiliBuilder::Minimum(const MnFcn& fcn, const GradientCalculato // std::cout<<"result.back().Error().Dcovar()= "<<result.back().Error().Dcovar()<<std::endl; #ifdef DEBUG - std::cout << "Exiting succesfully FumiliBuilder \n" + std::cout << "Exiting successfully FumiliBuilder \n" << "NFCalls = " << fcn.NumOfCalls() << "\nFval = " << result.back().Fval() << "\nedm = " << edm << " requested = " << edmval << std::endl; diff --git a/math/minuit2/src/Minuit2Minimizer.cxx b/math/minuit2/src/Minuit2Minimizer.cxx index d4aedf3fd67bc..75c16fbd67163 100644 --- a/math/minuit2/src/Minuit2Minimizer.cxx +++ b/math/minuit2/src/Minuit2Minimizer.cxx @@ -13,6 +13,7 @@ #include "Minuit2/Minuit2Minimizer.h" #include "Math/IFunction.h" +#include "Math/IOptions.h" #include "Minuit2/FCNAdapter.h" #include "Minuit2/FumiliFCNAdapter.h" @@ -316,7 +317,7 @@ bool Minuit2Minimizer::Minimize() { int maxfcn = MaxFunctionCalls(); double tol = Tolerance(); - int strategy = Strategy(); + int strategyLevel = Strategy(); fMinuitFCN->SetErrorDef(ErrorDef() ); if (PrintLevel() >=1) { @@ -328,7 +329,7 @@ bool Minuit2Minimizer::Minimize() { } std::cout << "Minuit2Minimizer: Minimize with max-calls " << maxfcn_used << " convergence for edm < " << tol << " strategy " - << strategy << std::endl; + << strategyLevel << std::endl; } // internal minuit messages @@ -339,16 +340,55 @@ bool Minuit2Minimizer::Minimize() { // set the precision if needed if (Precision() > 0) fState.SetPrecision(Precision()); + + // set strategy and add extra options if needed + ROOT::Minuit2::MnStrategy strategy(strategyLevel); + ROOT::Math::IOptions * minuit2Opt = ROOT::Math::MinimizerOptions::FindDefault("Minuit2"); + if (minuit2Opt) { + // set extra strategy options + int nGradCycles = strategy.GradientNCycles(); + int nHessCycles = strategy.HessianNCycles(); + int nHessGradCycles = strategy.HessianGradientNCycles(); + + double gradTol = strategy.GradientTolerance(); + double gradStepTol = strategy.GradientStepTolerance(); + double hessStepTol = strategy.HessianStepTolerance(); + double hessG2Tol = strategy.HessianG2Tolerance(); + + minuit2Opt->GetValue("GradientNCycles",nGradCycles); + minuit2Opt->GetValue("HessianNCycles",nHessCycles); + minuit2Opt->GetValue("HessianGradientNCycles",nHessGradCycles); + + minuit2Opt->GetValue("GradientTolerance",gradTol); + minuit2Opt->GetValue("GradientStepTolerance",gradStepTol); + minuit2Opt->GetValue("HessianStepTolerance",hessStepTol); + minuit2Opt->GetValue("HessianG2Tolerance",hessG2Tol); + + strategy.SetGradientNCycles(nGradCycles); + strategy.SetHessianNCycles(nHessCycles); + strategy.SetHessianGradientNCycles(nHessGradCycles); + + strategy.SetGradientTolerance(gradTol); + strategy.SetGradientStepTolerance(gradStepTol); + strategy.SetHessianStepTolerance(hessStepTol); + strategy.SetHessianG2Tolerance(hessStepTol); + + if (PrintLevel() > 0) { + std::cout << "Minuit2Minimizer::Minuit - Changing default stratgey options" << std::endl; + minuit2Opt->Print(); + } + + } const ROOT::Minuit2::FCNGradientBase * gradFCN = dynamic_cast<const ROOT::Minuit2::FCNGradientBase *>( fMinuitFCN ); if ( gradFCN != 0) { // use gradient //SetPrintLevel(3); - ROOT::Minuit2::FunctionMinimum min = GetMinimizer()->Minimize(*gradFCN, fState, ROOT::Minuit2::MnStrategy(strategy), maxfcn, tol); + ROOT::Minuit2::FunctionMinimum min = GetMinimizer()->Minimize(*gradFCN, fState, strategy, maxfcn, tol); fMinimum = new ROOT::Minuit2::FunctionMinimum (min); } else { - ROOT::Minuit2::FunctionMinimum min = GetMinimizer()->Minimize(*GetFCN(), fState, ROOT::Minuit2::MnStrategy(strategy), maxfcn, tol); + ROOT::Minuit2::FunctionMinimum min = GetMinimizer()->Minimize(*GetFCN(), fState, strategy, maxfcn, tol); fMinimum = new ROOT::Minuit2::FunctionMinimum (min); } @@ -415,7 +455,7 @@ bool Minuit2Minimizer::ExamineMinimum(const ROOT::Minuit2::FunctionMinimum & mi bool validMinimum = min.IsValid(); if (validMinimum) { // print a warning message in case something is not ok - if (fStatus != 0) MN_INFO_MSG2("Minuit2Minimizer::Minimize",txt); + if (fStatus != 0 && debugLevel > 0) MN_INFO_MSG2("Minuit2Minimizer::Minimize",txt); } else { // minimum is not valid when state is not valid and edm is over max or has passed call limits @@ -708,24 +748,34 @@ bool Minuit2Minimizer::GetMinosError(unsigned int i, double & errLow, double & e } - bool isValid = true; - if (runLower && !me.LowerValid() ) isValid = false; - if (runUpper && !me.UpperValid() ) isValid = false; - if ( !isValid ) { + bool lowerInvalid = (runLower && !me.LowerValid() ); + bool upperInvalid = (runUpper && !me.UpperValid() ); + int mstatus = 0; + if (lowerInvalid || upperInvalid ) { + // set status accroding to bit + // bit 1: lower invalid Minos errors + // bit 2: uper invalid Minos error + // bit 3: invalid because max FCN + // bit 4 : invalid because a new minimum has been found + if (lowerInvalid) { + mstatus |= 1; + if (me.AtLowerMaxFcn() ) mstatus |= 4; + if (me.LowerNewMin() ) mstatus |= 8; + } + if(upperInvalid) { + mstatus |= 3; + if (me.AtUpperMaxFcn() ) mstatus |= 4; + if (me.UpperNewMin() ) mstatus |= 8; + } //std::cout << "Error running Minos for parameter " << i << std::endl; - int mstatus = 5; - if (me.AtLowerMaxFcn() ) mstatus = 1; - if (me.AtUpperMaxFcn() ) mstatus = 2; - if (me.LowerNewMin() ) mstatus = 3; - if (me.UpperNewMin() ) mstatus = 4; fStatus += 10*mstatus; - return false; } errLow = me.Lower(); errUp = me.Upper(); - - return true; + + bool isValid = (runLower && me.LowerValid() ) || (runUpper && me.UpperValid() ); + return isValid; } bool Minuit2Minimizer::Scan(unsigned int ipar, unsigned int & nstep, double * x, double * y, double xmin, double xmax) { @@ -777,7 +827,7 @@ bool Minuit2Minimizer::Scan(unsigned int ipar, unsigned int & nstep, double * x, // what to do if a new minimum has been found ? // use that as new minimum if (scan.Fval() < amin ) { - MN_INFO_MSG2("Minuit2Minimizer::Scan","A new minimum has been found"); + if (PrintLevel() > 0) MN_INFO_MSG2("Minuit2Minimizer::Scan","A new minimum has been found"); fState.SetValue(ipar, scan.Parameters().Value(ipar) ); } diff --git a/math/minuit2/src/MnContours.cxx b/math/minuit2/src/MnContours.cxx index 733f0265a09f9..95fe3d7772995 100644 --- a/math/minuit2/src/MnContours.cxx +++ b/math/minuit2/src/MnContours.cxx @@ -27,14 +27,7 @@ namespace ROOT { void PrintContourPoint(const std::pair<double,double> & point) { -#ifdef WARNINGMSG -#ifdef USE_ROOT_ERROR - std::string msg = "\tx = " + ROOT::Math::Util::ToString(point.first) + "\ty = " + ROOT::Math::Util::ToString(point.first); - MN_INFO_MSG2("MnContour",msg.c_str()); -#else - std::cout << " x = " << point.first << " y = " << point.second << std::endl; -#endif -#endif + std::cout << "\t x = " << point.first << " y = " << point.second << std::endl; } std::vector<std::pair<double,double> > MnContours::operator()(unsigned int px, unsigned int py, unsigned int npoints) const { @@ -127,18 +120,22 @@ ContoursError MnContours::Contour(unsigned int px, unsigned int py, unsigned int result.push_back(std::pair<double,double>(eyx_up.UserState().Value(px), valy + ey.second)); + MnUserParameterState upar = fMinimum.UserState(); // std::cout<<"MnContours: first 4 params finished."<<std::endl; -#ifdef WARNINGMSG - MN_INFO_MSG("Minuit2::MnContour : List of found points"); - MN_INFO_VAL2("Minuit2::MnContour : parameter number x",px); - MN_INFO_VAL2("Minuit2::MnContour : parameter number y",py); -#endif - - for (unsigned int i = 0; i < 4; ++i) - PrintContourPoint(result[i] ); + int printLevel = MnPrint::Level(); + + if (printLevel > 0 ) { + std::cout << "MnContour : List of found points " << std::endl; + std::cout << "\t Parameter x is " << upar.Name(px) << std::endl; + std::cout << "\t Parameter y is " << upar.Name(py) << std::endl; + } + + if (printLevel > 0) { + for (unsigned int i = 0; i < 4; ++i) + PrintContourPoint(result[i] ); + } - MnUserParameterState upar = fMinimum.UserState(); upar.Fix(px); upar.Fix(py); @@ -203,13 +200,16 @@ ContoursError MnContours::Contour(unsigned int px, unsigned int py, unsigned int double aopt = opt.Value(); if(idist2 == result.begin()) { result.push_back(std::pair<double,double>(xmidcr+(aopt)*xdircr, ymidcr + (aopt)*ydircr)); - PrintContourPoint( result.back() ); + if (printLevel > 0) PrintContourPoint( result.back() ); } else { result.insert(idist2, std::pair<double,double>(xmidcr+(aopt)*xdircr, ymidcr + (aopt)*ydircr)); - PrintContourPoint( *idist2 ); + if (printLevel > 0) PrintContourPoint( *idist2 ); } } + if (printLevel >0) + std::cout << "MnContour: Number of contour points = " << result.size() << std::endl; + return ContoursError(px, py, result, mex, mey, nfcn); } diff --git a/math/minuit2/src/MnMinos.cxx b/math/minuit2/src/MnMinos.cxx index 8e5abcbe3c036..42d5d7e35ee52 100644 --- a/math/minuit2/src/MnMinos.cxx +++ b/math/minuit2/src/MnMinos.cxx @@ -142,7 +142,7 @@ MnCross MnMinos::FindCrossValue(int direction, unsigned int par, unsigned int ma unsigned int ind = upar.IntOfExt(par); // get error matrix (methods return a copy) MnAlgebraicSymMatrix m = fMinimum.Error().Matrix(); - // get internal paramaters + // get internal parameters const MnAlgebraicVector & xt = fMinimum.Parameters().Vec(); //LM: change to use err**2 (m(i,i) instead of err as in F77 version double xunit = sqrt(up/m(ind,ind)); @@ -236,7 +236,7 @@ MnCross MnMinos::Loval(unsigned int par, unsigned int maxcalls, double toler) co // unsigned int ind = upar.IntOfExt(par); // MnAlgebraicSymMatrix m = fMinimum.Error().Matrix(); // double xunit = sqrt(up/m(ind,ind)); -// // get internal paramaters +// // get internal parameters // const MnAlgebraicVector & xt = fMinimum.Parameters().Vec(); // for(unsigned int i = 0; i < m.Nrow(); i++) { diff --git a/math/minuit2/src/VariableMetricBuilder.cxx b/math/minuit2/src/VariableMetricBuilder.cxx index f714fb0f490c2..c44d7b772e224 100644 --- a/math/minuit2/src/VariableMetricBuilder.cxx +++ b/math/minuit2/src/VariableMetricBuilder.cxx @@ -41,7 +41,7 @@ double inner_product(const LAVector&, const LAVector&); FunctionMinimum VariableMetricBuilder::Minimum(const MnFcn& fcn, const GradientCalculator& gc, const MinimumSeed& seed, const MnStrategy& strategy, unsigned int maxfcn, double edmval) const { // top level function to find minimum from a given initial seed - // iterate on a minimum search in case of first attempt is not succesfull + // iterate on a minimum search in case of first attempt is not successful // to be consistent with F77 Minuit // in Minuit2 edm is correct and is ~ a factor of 2 smaller than F77Minuit @@ -399,7 +399,7 @@ FunctionMinimum VariableMetricBuilder::Minimum(const MnFcn& fcn, const GradientC // std::cout<<"result.back().Error().Dcovar()= "<<result.back().Error().Dcovar()<<std::endl; #ifdef DEBUG - std::cout << "Exiting succesfully Variable Metric Builder \n" + std::cout << "Exiting successfully Variable Metric Builder \n" << "NFCalls = " << fcn.NumOfCalls() << "\nFval = " << result.back().Fval() << "\nedm = " << edm << " requested = " << edmval << std::endl; diff --git a/math/mlp/src/TMLPAnalyzer.cxx b/math/mlp/src/TMLPAnalyzer.cxx index 86fa1284e643e..87de90b8f999c 100644 --- a/math/mlp/src/TMLPAnalyzer.cxx +++ b/math/mlp/src/TMLPAnalyzer.cxx @@ -165,7 +165,7 @@ void TMLPAnalyzer::CheckNetwork() //______________________________________________________________________________ void TMLPAnalyzer::GatherInformations() { - // Collect informations about what is usefull in the network. + // Collect information about what is usefull in the network. // This method has to be called first when analyzing a network. // Fills the two analysis trees. diff --git a/math/mlp/src/TMultiLayerPerceptron.cxx b/math/mlp/src/TMultiLayerPerceptron.cxx index 321d85ac7f999..5354d684b500e 100644 --- a/math/mlp/src/TMultiLayerPerceptron.cxx +++ b/math/mlp/src/TMultiLayerPerceptron.cxx @@ -50,7 +50,7 @@ </UL> <P>Neural Networks are more and more used in various fields for data analysis and classification, both for research and commercial -institutions. Some randomly choosen examples are:</P> +institutions. Some randomly chosen examples are:</P> <UL> <LI><P>image analysis</P> <LI><P>financial movements predictions and analysis</P> @@ -64,7 +64,7 @@ implementation of multilayer perceptrons is inspired from the package</A> originaly written by Jerome Schwindling. MLPfit remains one of the fastest tool for neural networks studies, and this ROOT add-on will not try to compete on that. A clear and flexible Object -Oriented implementation has been choosen over a faster but more +Oriented implementation has been chosen over a faster but more difficult to maintain code. Nevertheless, the time penalty does not exceed a factor 2.</P> <UL> @@ -159,7 +159,7 @@ the direction is reset to the steepes descent.</P> </UL> <P><FONT SIZE=3>TMLP is build from 3 classes: TNeuron, TSynapse and TMultiLayerPerceptron. Only TMultiLayerPerceptron should be used -explicitely by the user.</FONT></P> +explicitly by the user.</FONT></P> <P><FONT SIZE=3>TMultiLayerPerceptron will take examples from a TTree given in the constructor. The network is described by a simple string: The input/output layers are defined by giving the expression for @@ -178,7 +178,7 @@ One defines the training and test datasets by TEventLists.</FONT></P> </SPAN>TMultiLayerPerceptron("x,y:10:5:f",inputTree);</SPAN></FONT></P> <P><FONT SIZE=3>Both the TTree and the TEventLists can be defined in the constructor, or later with the suited setter method. The lists -used for training and test can be defined either explicitely, or via +used for training and test can be defined either explicitly, or via a string containing the formula to be used to define them, exactly as for a TCut.</FONT></P> <P><FONT SIZE=3>The learning method is defined using the diff --git a/math/physics/src/TQuaternion.cxx b/math/physics/src/TQuaternion.cxx index a1bc38e244e75..8b6b2f1fe5b08 100644 --- a/math/physics/src/TQuaternion.cxx +++ b/math/physics/src/TQuaternion.cxx @@ -154,7 +154,7 @@ Double_t TQuaternion::GetQAngle() const { // Get angle of quaternion (rad) // N.B : this angle is half of the corresponding rotation angle - if (fRealPart == 0) return 0; + if (fRealPart == 0) return TMath::PiOver2(); Double_t denominator = fVectorPart.Mag(); return atan(denominator/fRealPart); } diff --git a/math/physics/src/TVector3.cxx b/math/physics/src/TVector3.cxx index ce0e2b2c67622..ee07615451897 100644 --- a/math/physics/src/TVector3.cxx +++ b/math/physics/src/TVector3.cxx @@ -284,9 +284,10 @@ Double_t TVector3::Theta() const TVector3 TVector3::Unit() const { // return unit vector parallel to this. - Double_t tot = Mag2(); - TVector3 p(fX,fY,fZ); - return tot > 0.0 ? p *= (1.0/TMath::Sqrt(tot)) : p; + Double_t tot2 = Mag2(); + Double_t tot = (tot2 > 0) ? 1.0/TMath::Sqrt(tot2) : 1.0; + TVector3 p(fX*tot,fY*tot,fZ*tot); + return p; } //______________________________________________________________________________ diff --git a/math/quadp/src/TQpDataSparse.cxx b/math/quadp/src/TQpDataSparse.cxx index 40c0e0c246813..e183679458c92 100644 --- a/math/quadp/src/TQpDataSparse.cxx +++ b/math/quadp/src/TQpDataSparse.cxx @@ -101,12 +101,12 @@ TQpDataSparse::TQpDataSparse(TVectorD &c_in, TMatrixDSparse &Q_in, fMz = fC.GetNrows(); } else fMz = 0; - fQ.Print(); - fA.Print(); - fC.Print(); - printf("fNx: %d\n",fNx); - printf("fMy: %d\n",fMy); - printf("fMz: %d\n",fMz); + // fQ.Print(); + // fA.Print(); + // fC.Print(); + // printf("fNx: %d\n",fNx); + // printf("fMy: %d\n",fMy); + // printf("fMz: %d\n",fMz); } @@ -202,11 +202,11 @@ Double_t TQpDataSparse::DataNorm() componentNorm = fBa.NormInf(); if (componentNorm > norm) norm = componentNorm; - TMatrixDSparse fA_abs(fQ); + TMatrixDSparse fA_abs(fA); componentNorm = (fA_abs.Abs()).Max(); if (componentNorm > norm) norm = componentNorm; - TMatrixDSparse fC_abs(fQ); + TMatrixDSparse fC_abs(fC); componentNorm = (fC_abs.Abs()).Max(); if (componentNorm > norm) norm = componentNorm; diff --git a/math/smatrix/inc/Math/CholeskyDecomp.h b/math/smatrix/inc/Math/CholeskyDecomp.h index 4a3cd7b0731f5..72afbda055ce2 100644 --- a/math/smatrix/inc/Math/CholeskyDecomp.h +++ b/math/smatrix/inc/Math/CholeskyDecomp.h @@ -16,6 +16,12 @@ * factored code to provide a nice Cholesky decomposition class, along * with separate methods for solving a single linear system and to * obtain the inverse matrix from the decomposition + * @date July 15th 2013 + * provide a version of that class which works if the dimension of the + * problem is only known at run time + * @date September 30th 2013 + * provide routines to access the result of the decomposition L and its + * inverse */ #include <cmath> @@ -28,9 +34,13 @@ namespace ROOT { /// helpers for CholeskyDecomp namespace CholeskyDecompHelpers { // forward decls + template<class F, class M> struct _decomposerGenDim; template<class F, unsigned N, class M> struct _decomposer; + template<class F, class M> struct _inverterGenDim; template<class F, unsigned N, class M> struct _inverter; + template<class F, class V> struct _solverGenDim; template<class F, unsigned N, class V> struct _solver; + template<typename G> class PackedArrayAdapter; } /// class to compute the Cholesky decomposition of a matrix @@ -72,21 +82,6 @@ template<class F, unsigned N> class CholeskyDecomp F fL[N * (N + 1) / 2]; /// flag indicating a successful decomposition bool fOk; - /// adapter for packed arrays (to SMatrix indexing conventions) - template<typename G> class PackedArrayAdapter - { - private: - G* fArr; ///< pointer to first array element - public: - /// constructor - PackedArrayAdapter(G* arr) : fArr(arr) {} - /// read access to elements (make sure that j <= i) - const G operator()(unsigned i, unsigned j) const - { return fArr[((i * (i + 1)) / 2) + j]; } - /// write access to elements (make sure that j <= i) - G& operator()(unsigned i, unsigned j) - { return fArr[((i * (i + 1)) / 2) + j]; } - }; public: /// perform a Cholesky decomposition /** perfrom a Cholesky decomposition of a symmetric positive @@ -118,6 +113,7 @@ template<class F, unsigned N> class CholeskyDecomp fL(), fOk(false) { using CholeskyDecompHelpers::_decomposer; + using CholeskyDecompHelpers::PackedArrayAdapter; fOk = _decomposer<F, N, PackedArrayAdapter<G> >()( fL, PackedArrayAdapter<G>(m)); } @@ -129,8 +125,7 @@ template<class F, unsigned N> class CholeskyDecomp /** @returns true if decomposition was successful */ operator bool() const { return fOk; } - /// solves a linear system for the given right hand side - /** solves a linear system for the given right hand side + /** @brief solves a linear system for the given right hand side * * Note that you can use both SVector classes and plain arrays for * rhs. (Make sure that the sizes match!). It will work with any vector @@ -144,8 +139,7 @@ template<class F, unsigned N> class CholeskyDecomp if (fOk) _solver<F,N,V>()(rhs, fL); return fOk; } - /// place the inverse into m - /** place the inverse into m + /** @brief place the inverse into m * * This is the method to use with an SMatrix. * @@ -157,8 +151,7 @@ template<class F, unsigned N> class CholeskyDecomp if (fOk) _inverter<F,N,M>()(m, fL); return fOk; } - /// place the inverse into m - /** place the inverse into m + /** @brief place the inverse into m * * This is the method to use with a plain array. * @@ -171,22 +164,376 @@ template<class F, unsigned N> class CholeskyDecomp template<typename G> bool Invert(G* m) const { using CholeskyDecompHelpers::_inverter; + using CholeskyDecompHelpers::PackedArrayAdapter; if (fOk) { PackedArrayAdapter<G> adapted(m); _inverter<F,N,PackedArrayAdapter<G> >()(adapted, fL); } return fOk; } + + /** @brief obtain the decomposed matrix L + * + * This is the method to use with a plain array. + * + * @returns if the decomposition was successful + */ + template<class M> bool getL(M& m) const + { + if (!fOk) return false; + for (unsigned i = 0; i < N; ++i) { + // zero upper half of matrix + for (unsigned j = i + 1; j < N; ++j) + m(i, j) = F(0); + // copy the rest + for (unsigned j = 0; j <= i; ++j) + m(i, j) = fL[i * (i + 1) / 2 + j]; + // adjust the diagonal - we save 1/L(i, i) in that position, so + // convert to what caller expects + m(i, i) = F(1) / m(i, i); + } + return true; + } + + /** @brief obtain the decomposed matrix L + * + * @returns if the decomposition was successful + * + * NOTE: the matrix is given in packed representation, matrix + * element m(i,j) (j <= i) is supposed to be in array element + * (i * (i + 1)) / 2 + j + */ + template<typename G> bool getL(G* m) const + { + if (!fOk) return false; + // copy L + for (unsigned i = 0; i < (N * (N + 1)) / 2; ++i) + m[i] = fL[i]; + // adjust diagonal - we save 1/L(i, i) in that position, so convert to + // what caller expects + for (unsigned i = 0; i < N; ++i) + m[(i * (i + 1)) / 2 + i] = F(1) / fL[(i * (i + 1)) / 2 + i]; + return true; + } + + /** @brief obtain the inverse of the decomposed matrix L + * + * This is the method to use with a plain array. + * + * @returns if the decomposition was successful + */ + template<class M> bool getLi(M& m) const + { + if (!fOk) return false; + for (unsigned i = 0; i < N; ++i) { + // zero lower half of matrix + for (unsigned j = i + 1; j < N; ++j) + m(j, i) = F(0); + // copy the rest + for (unsigned j = 0; j <= i; ++j) + m(j, i) = fL[i * (i + 1) / 2 + j]; + } + // invert the off-diagonal part of what we just copied + for (unsigned i = 1; i < N; ++i) { + for (unsigned j = 0; j < i; ++j) { + typename M::value_type tmp = F(0); + for (unsigned k = i; k-- > j;) + tmp -= m(k, i) * m(j, k); + m(j, i) = tmp * m(i, i); + } + } + return true; + } + + /** @brief obtain the inverse of the decomposed matrix L + * + * @returns if the decomposition was successful + * + * NOTE: the matrix is given in packed representation, matrix + * element m(j,i) (j <= i) is supposed to be in array element + * (i * (i + 1)) / 2 + j + */ + template<typename G> bool getLi(G* m) const + { + if (!fOk) return false; + // copy L + for (unsigned i = 0; i < (N * (N + 1)) / 2; ++i) + m[i] = fL[i]; + // invert the off-diagonal part of what we just copied + G* base1 = &m[1]; + for (unsigned i = 1; i < N; base1 += ++i) { + for (unsigned j = 0; j < i; ++j) { + G tmp = F(0); + const G *base2 = &m[(i * (i - 1)) / 2]; + for (unsigned k = i; k-- > j; base2 -= k) + tmp -= base1[k] * base2[j]; + base1[j] = tmp * base1[i]; + } + } + return true; + } }; +/// class to compute the Cholesky decomposition of a matrix +/** class to compute the Cholesky decomposition of a symmetric + * positive definite matrix when the dimensionality of the problem is not known + * at compile time + * + * provides routines to check if the decomposition succeeded (i.e. if + * matrix is positive definite and non-singular), to solve a linear + * system for the given matrix and to obtain its inverse + * + * the actual functionality is implemented in templated helper + * classes which have specializations for dimensions N = 1 to 6 + * to achieve a gain in speed for common matrix sizes + * + * usage example: + * @code + * // let m be a symmetric positive definite SMatrix (use type float + * // for internal computations, matrix size is 4x4) + * CholeskyDecompGenDim<float> decomp(4, m); + * // check if the decomposition succeeded + * if (!decomp) { + * std::cerr << "decomposition failed!" << std::endl; + * } else { + * // let rhs be a vector; we seek a vector x such that m * x = rhs + * decomp.Solve(rhs); + * // rhs now contains the solution we are looking for + * + * // obtain the inverse of m, put it into m itself + * decomp.Invert(m); + * } + * @endcode + */ +template<class F> class CholeskyDecompGenDim +{ +private: + /** @brief dimensionality + * dimensionality of the problem */ + unsigned fN; + /// lower triangular matrix L + /** lower triangular matrix L, packed storage, with diagonal + * elements pre-inverted */ + F *fL; + /// flag indicating a successful decomposition + bool fOk; +public: + /// perform a Cholesky decomposition + /** perfrom a Cholesky decomposition of a symmetric positive + * definite matrix m + * + * this is the constructor to uses with an SMatrix (and objects + * that behave like an SMatrix in terms of using + * operator()(int i, int j) for access to elements) + */ + template<class M> CholeskyDecompGenDim(unsigned N, const M& m) : + fN(N), fL(new F[(fN * (fN + 1)) / 2]), fOk(false) + { + using CholeskyDecompHelpers::_decomposerGenDim; + fOk = _decomposerGenDim<F, M>()(fL, m, fN); + } + + /// perform a Cholesky decomposition + /** perfrom a Cholesky decomposition of a symmetric positive + * definite matrix m + * + * this is the constructor to use in special applications where + * plain arrays are used + * + * NOTE: the matrix is given in packed representation, matrix + * element m(i,j) (j <= i) is supposed to be in array element + * (i * (i + 1)) / 2 + j + */ + template<typename G> CholeskyDecompGenDim(unsigned N, G* m) : + fN(N), fL(new F[(fN * (fN + 1)) / 2]), fOk(false) + { + using CholeskyDecompHelpers::_decomposerGenDim; + using CholeskyDecompHelpers::PackedArrayAdapter; + fOk = _decomposerGenDim<F, PackedArrayAdapter<G> >()( + fL, PackedArrayAdapter<G>(m), fN); + } + + /// destructor + ~CholeskyDecompGenDim() { delete[] fL; } + + /// returns true if decomposition was successful + /** @returns true if decomposition was successful */ + bool ok() const { return fOk; } + /// returns true if decomposition was successful + /** @returns true if decomposition was successful */ + operator bool() const { return fOk; } + + /** @brief solves a linear system for the given right hand side + * + * Note that you can use both SVector classes and plain arrays for + * rhs. (Make sure that the sizes match!). It will work with any vector + * implementing the operator [i] + * + * @returns if the decomposition was successful + */ + template<class V> bool Solve(V& rhs) const + { + using CholeskyDecompHelpers::_solverGenDim; + if (fOk) _solverGenDim<F,V>()(rhs, fL, fN); return fOk; + } + + /** @brief place the inverse into m + * + * This is the method to use with an SMatrix. + * + * @returns if the decomposition was successful + */ + template<class M> bool Invert(M& m) const + { + using CholeskyDecompHelpers::_inverterGenDim; + if (fOk) _inverterGenDim<F,M>()(m, fL, fN); return fOk; + } + + /** @brief place the inverse into m + * + * This is the method to use with a plain array. + * + * @returns if the decomposition was successful + * + * NOTE: the matrix is given in packed representation, matrix + * element m(i,j) (j <= i) is supposed to be in array element + * (i * (i + 1)) / 2 + j + */ + template<typename G> bool Invert(G* m) const + { + using CholeskyDecompHelpers::_inverterGenDim; + using CholeskyDecompHelpers::PackedArrayAdapter; + if (fOk) { + PackedArrayAdapter<G> adapted(m); + _inverterGenDim<F,PackedArrayAdapter<G> >()(adapted, fL, fN); + } + return fOk; + } + + /** @brief obtain the decomposed matrix L + * + * This is the method to use with a plain array. + * + * @returns if the decomposition was successful + */ + template<class M> bool getL(M& m) const + { + if (!fOk) return false; + for (unsigned i = 0; i < fN; ++i) { + // zero upper half of matrix + for (unsigned j = i + 1; j < fN; ++j) + m(i, j) = F(0); + // copy the rest + for (unsigned j = 0; j <= i; ++j) + m(i, j) = fL[i * (i + 1) / 2 + j]; + // adjust the diagonal - we save 1/L(i, i) in that position, so + // convert to what caller expects + m(i, i) = F(1) / m(i, i); + } + return true; + } + + /** @brief obtain the decomposed matrix L + * + * @returns if the decomposition was successful + * + * NOTE: the matrix is given in packed representation, matrix + * element m(i,j) (j <= i) is supposed to be in array element + * (i * (i + 1)) / 2 + j + */ + template<typename G> bool getL(G* m) const + { + if (!fOk) return false; + // copy L + for (unsigned i = 0; i < (fN * (fN + 1)) / 2; ++i) + m[i] = fL[i]; + // adjust diagonal - we save 1/L(i, i) in that position, so convert to + // what caller expects + for (unsigned i = 0; i < fN; ++i) + m[(i * (i + 1)) / 2 + i] = F(1) / fL[(i * (i + 1)) / 2 + i]; + return true; + } + + /** @brief obtain the inverse of the decomposed matrix L + * + * This is the method to use with a plain array. + * + * @returns if the decomposition was successful + */ + template<class M> bool getLi(M& m) const + { + if (!fOk) return false; + for (unsigned i = 0; i < fN; ++i) { + // zero lower half of matrix + for (unsigned j = i + 1; j < fN; ++j) + m(j, i) = F(0); + // copy the rest + for (unsigned j = 0; j <= i; ++j) + m(j, i) = fL[i * (i + 1) / 2 + j]; + } + // invert the off-diagonal part of what we just copied + for (unsigned i = 1; i < fN; ++i) { + for (unsigned j = 0; j < i; ++j) { + typename M::value_type tmp = F(0); + for (unsigned k = i; k-- > j;) + tmp -= m(k, i) * m(j, k); + m(j, i) = tmp * m(i, i); + } + } + return true; + } + + /** @brief obtain the inverse of the decomposed matrix L + * + * @returns if the decomposition was successful + * + * NOTE: the matrix is given in packed representation, matrix + * element m(j,i) (j <= i) is supposed to be in array element + * (i * (i + 1)) / 2 + j + */ + template<typename G> bool getLi(G* m) const + { + if (!fOk) return false; + // copy L + for (unsigned i = 0; i < (fN * (fN + 1)) / 2; ++i) + m[i] = fL[i]; + // invert the off-diagonal part of what we just copied + G* base1 = &m[1]; + for (unsigned i = 1; i < fN; base1 += ++i) { + for (unsigned j = 0; j < i; ++j) { + G tmp = F(0); + const G *base2 = &m[(i * (i - 1)) / 2]; + for (unsigned k = i; k-- > j; base2 -= k) + tmp -= base1[k] * base2[j]; + base1[j] = tmp * base1[i]; + } + } + return true; + } +}; namespace CholeskyDecompHelpers { - /// struct to do a Cholesky decomposition - template<class F, unsigned N, class M> struct _decomposer + /// adapter for packed arrays (to SMatrix indexing conventions) + template<typename G> class PackedArrayAdapter + { + private: + G* fArr; ///< pointer to first array element + public: + /// constructor + PackedArrayAdapter(G* arr) : fArr(arr) {} + /// read access to elements (make sure that j <= i) + const G operator()(unsigned i, unsigned j) const + { return fArr[((i * (i + 1)) / 2) + j]; } + /// write access to elements (make sure that j <= i) + G& operator()(unsigned i, unsigned j) + { return fArr[((i * (i + 1)) / 2) + j]; } + }; + /// struct to do a Cholesky decomposition (general dimensionality) + template<class F, class M> struct _decomposerGenDim { /// method to do the decomposition /** @returns if the decomposition was successful */ - bool operator()(F* dst, const M& src) const + bool operator()(F* dst, const M& src, unsigned N) const { // perform Cholesky decomposition of matrix: M = L L^T // only thing that can go wrong: trying to take square @@ -223,14 +570,23 @@ namespace CholeskyDecompHelpers { } }; - /// struct to obtain the inverse from a Cholesky decomposition - template<class F, unsigned N, class M> struct _inverter + /// struct to do a Cholesky decomposition + template<class F, unsigned N, class M> struct _decomposer + { + /// method to do the decomposition + /** @returns if the decomposition was successful */ + bool operator()(F* dst, const M& src) const + { return _decomposerGenDim<F, M>()(dst, src, N); } + }; + + /// struct to obtain the inverse from a Cholesky decomposition (general dimensionality) + template<class F, class M> struct _inverterGenDim { /// method to do the inversion - void operator()(M& dst, const F* src) const + void operator()(M& dst, const F* src, unsigned N) const { // make working copy - F l[N * (N + 1) / 2]; + F * l = new F[N * (N + 1) / 2]; std::copy(src, src + ((N * (N + 1)) / 2), l); // ok, next step: invert off-diagonal part of matrix F* base1 = &l[1]; @@ -254,14 +610,23 @@ namespace CholeskyDecompHelpers { dst(i, j) = tmp; } } + delete [] l; } }; - /// struct to solve a linear system using its Cholesky decomposition - template<class F, unsigned N, class V> struct _solver + /// struct to obtain the inverse from a Cholesky decomposition + template<class F, unsigned N, class M> struct _inverter + { + /// method to do the inversion + void operator()(M& dst, const F* src) const + { return _inverterGenDim<F, M>()(dst, src, N); } + }; + + /// struct to solve a linear system using its Cholesky decomposition (generalised dimensionality) + template<class F, class V> struct _solverGenDim { /// method to solve the linear system - void operator()(V& rhs, const F* l) const + void operator()(V& rhs, const F* l, unsigned N) const { // solve Ly = rhs for (unsigned k = 0; k < N; ++k) { @@ -283,6 +648,14 @@ namespace CholeskyDecompHelpers { } }; + /// struct to solve a linear system using its Cholesky decomposition + template<class F, unsigned N, class V> struct _solver + { + /// method to solve the linear system + void operator()(V& rhs, const F* l) const + { _solverGenDim<F, V>()(rhs, l, N); } + }; + /// struct to do a Cholesky decomposition (specialized, N = 6) template<class F, class M> struct _decomposer<F, 6, M> { diff --git a/math/smatrix/inc/Math/Functions.h b/math/smatrix/inc/Math/Functions.h index f3ab873178c1d..92dcfba28bb5a 100644 --- a/math/smatrix/inc/Math/Functions.h +++ b/math/smatrix/inc/Math/Functions.h @@ -371,7 +371,7 @@ inline SVector<T,3> Cross(const VecExpr<A,T,3>& lhs, const VecExpr<B,T,3>& rhs) /** Unit. - Return a vector of unit lenght: \f$ \vec{e}_v = \vec{v}/|\vec{v}| \f$. + Return a vector of unit length: \f$ \vec{e}_v = \vec{v}/|\vec{v}| \f$. @ingroup VectFunction @author T. Glebe diff --git a/math/smatrix/inc/Math/MConfig.h b/math/smatrix/inc/Math/MConfig.h index 508d8490cbe18..3072cbc5a0d66 100644 --- a/math/smatrix/inc/Math/MConfig.h +++ b/math/smatrix/inc/Math/MConfig.h @@ -1,7 +1,7 @@ // @(#)root/smatrix:$Id$ // Authors: T. Glebe, L. Moneta 2005 -#ifndef ROOT_Math_MConfig_ +#ifndef ROOT_Math_MConfig #define ROOT_Math_MConfig // for alpha streams diff --git a/math/smatrix/inc/Math/MatrixInversion.icc b/math/smatrix/inc/Math/MatrixInversion.icc index e073a893fe594..750c2af142082 100644 --- a/math/smatrix/inc/Math/MatrixInversion.icc +++ b/math/smatrix/inc/Math/MatrixInversion.icc @@ -47,8 +47,8 @@ void Inverter<idim,N>::InvertBunchKaufman(MatRepSym<T,idim> & rhs, int &ifail) { // by having a new without a delete that is only done once. - static SVector<T, MatRepSym<T,idim>::kRows> xvec; - static SVector<int, MatRepSym<T,idim>::kRows> pivv; + SVector<T, MatRepSym<T,idim>::kRows> xvec; + SVector<int, MatRepSym<T,idim>::kRows> pivv; typedef int* pivIter; typedef T* mIter; diff --git a/math/smatrix/inc/Math/SVector.h b/math/smatrix/inc/Math/SVector.h index 453db58f46fd7..7de0c830a9538 100644 --- a/math/smatrix/inc/Math/SVector.h +++ b/math/smatrix/inc/Math/SVector.h @@ -297,7 +297,7 @@ class SVector { #endif /** @name --- Expert functions --- */ - /// transform vector into a vector of lenght 1 + /// transform vector into a vector of length 1 SVector<T,D>& Unit(); /// place a sub-vector starting from the given position template <unsigned int D2> diff --git a/math/smatrix/test/testInversion.cxx b/math/smatrix/test/testInversion.cxx index 843905838b7a1..fc711b0b8b965 100644 --- a/math/smatrix/test/testInversion.cxx +++ b/math/smatrix/test/testInversion.cxx @@ -365,6 +365,7 @@ bool stressSymPosInversion(int n, bool selftest ) { } int testInversion(int n = 100000) { + std::cout << "Test Inversion for matrix with N = " << N << std::endl; bool ok = stressSymPosInversion(n, doSelfTest); std::cerr << "Test inversion of positive defined matrix ....... "; if (ok) std::cerr << "OK \n"; diff --git a/math/unuran/CMakeLists.txt b/math/unuran/CMakeLists.txt index 190eeda0ca393..64335dc12a2ef 100644 --- a/math/unuran/CMakeLists.txt +++ b/math/unuran/CMakeLists.txt @@ -21,26 +21,23 @@ if(WIN32) else() #---Define special compiler settings for unurun----------------------------------------------------- set(UNR_CC ${CMAKE_C_COMPILER}) - if(ROOT_ARCHITECTURE MATCHES sgicc64) - set(UNR_CC "gcc -mabi=64") - elseif(ROOT_ARCHITECTURE MATCHES hpuxia64acc) - set(UNR_CC "cc +DD64 -Ae") + if(ROOT_ARCHITECTURE MATCHES hpuxia64acc) + set(UNR_CC "${UNR_CC} +DD64 -Ae") elseif(ROOT_ARCHITECTURE MATCHES linuxppc64gcc) - set(UNR_CC "gcc -m64 -fPIC") + set(UNR_CC "${UNR_CC} -m64 -fPIC") elseif(ROOT_ARCHITECTURE MATCHES linuxx8664gcc) - set(UNR_CC "gcc") set(UNR_CFLAGS "-m64 -fPIC") elseif(ROOT_ARCHITECTURE MATCHES linuxicc) - set(UNR_CC "icc") set(UNR_CFLAGS "-m32") elseif(ROOT_ARCHITECTURE MATCHES linuxx8664icc) - set(UNR_CC "icc") set(UNR_CFLAGS "-m64") + elseif(ROOT_ARCHITECTURE MATCHES win32) + set(UNR_CFLAGS "-MD -G5 -GX") endif() #---configure unuran (required for creating the config.h used by unuran source files)---------------- add_custom_command(OUTPUT ${UNR_UNTARDIR}/config.h - COMMAND GNUMAKE=make ./configure CC=${UNR_CC} CFLAGS=${UNR_CFLAGS} + COMMAND GNUMAKE=make ./configure CC=${UNR_CC} CFLAGS=${UNR_CFLAGS} > /dev/null 2>& 1 WORKING_DIRECTORY ${UNR_UNTARDIR}) endif() diff --git a/math/unuran/Module.mk b/math/unuran/Module.mk index 3d301debd00d3..8dc2802ff2b96 100644 --- a/math/unuran/Module.mk +++ b/math/unuran/Module.mk @@ -20,6 +20,17 @@ UNRDIRS := $(call stripsrc,$(MODDIRS)/$(UNRVERS)) UNURANETAG := $(call stripsrc,$(UNURANDIRS)/headers.d) UNRCFG := $(call stripsrc,$(UNURANDIRS)/$(UNRVERS)/config.h) +ifneq ($(wildcard $(UNRDIRS)),) +UNRS := $(wildcard $(UNRDIRS)/src/utils/*.c) \ + $(wildcard $(UNRDIRS)/src/methods/*.c) \ + $(wildcard $(UNRDIRS)/src/specfunct/*.c) \ + $(wildcard $(UNRDIRS)/src/distr/*.c) \ + $(wildcard $(UNRDIRS)/src/distributions/*.c) \ + $(wildcard $(UNRDIRS)/src/parser/*.c) \ + $(wildcard $(UNRDIRS)/src/tests/*.c) \ + $(wildcard $(UNRDIRS)/src/uniform/*.c) \ + $(wildcard $(UNRDIRS)/src/urng/*.c) +else UNRTARCONTENT:=$(subst $(UNRVERS),$(UNRDIRS),$(shell mkdir -p $(UNRDIR); cd $(UNRDIR); gunzip -c $(UNRSRCS) | tar tf -)) UNRS := $(filter %.c, \ $(filter $(UNRDIRS)/src/utils/%,$(UNRTARCONTENT)) \ @@ -31,6 +42,7 @@ UNRS := $(filter %.c, \ $(filter $(UNRDIRS)/src/tests/%,$(UNRTARCONTENT)) \ $(filter $(UNRDIRS)/src/uniform/%,$(UNRTARCONTENT)) \ $(filter $(UNRDIRS)/src/urng/%,$(UNRTARCONTENT))) +endif UNRO := $(UNRS:.c=.o) ifeq ($(PLATFORM),win32) @@ -97,24 +109,21 @@ $(UNRCFG): $(UNURANETAG) ACC="icc"; \ fi; \ if [ "$(ARCH)" = "sgicc64" ]; then \ - ACC="gcc -mabi=64"; \ + ACC="$$ACC -mabi=64"; \ fi; \ if [ "$(ARCH)" = "hpuxia64acc" ]; then \ - ACC="cc +DD64 -Ae"; \ + ACC="$$ACC +DD64 -Ae"; \ fi; \ if [ "$(ARCH)" = "linuxppc64gcc" ]; then \ - ACC="gcc -m64 -fPIC"; \ + ACC="$$ACC -m64 -fPIC"; \ fi; \ if [ "$(ARCH)" = "linuxx8664gcc" ]; then \ - ACC="gcc"; \ ACFLAGS="-m64 -fPIC"; \ fi; \ if [ "$(ARCH)" = "linuxicc" ]; then \ - ACC="icc"; \ ACFLAGS="-m32"; \ fi; \ if [ "$(ARCH)" = "linuxx8664icc" ]; then \ - ACC="icc"; \ ACFLAGS="-m64"; \ fi; \ if [ "$(ARCH)" = "win32" ]; then \ diff --git a/math/unuran/config.h.win.in b/math/unuran/config.h.win.in index 771f09c0b781c..e4ef2a1c7eb08 100644 --- a/math/unuran/config.h.win.in +++ b/math/unuran/config.h.win.in @@ -191,11 +191,11 @@ NULL pointer */ /* #undef UNUR_ENABLE_CHECKNULL */ -/* Define to 1 if you want to use the info routine for printing informations +/* Define to 1 if you want to use the info routine for printing information about UNU.RAN objects */ #define UNUR_ENABLE_INFO 1 -/* Define to 1 if you want to use a logfile for logging informations about +/* Define to 1 if you want to use a logfile for logging information about UNU.RAN objects */ /* #undef UNUR_ENABLE_LOGGING */ diff --git a/math/unuran/inc/TUnuranContDist.h b/math/unuran/inc/TUnuranContDist.h index 4264ec81c439c..9c94dc407e2b2 100644 --- a/math/unuran/inc/TUnuranContDist.h +++ b/math/unuran/inc/TUnuranContDist.h @@ -28,7 +28,7 @@ class TF1; //______________________________________________________________ /** - TUnuranContDist class describing one dimensional continous distribution. + TUnuranContDist class describing one dimensional continuous distribution. It is used by TUnuran to generate random numbers according to this distribution via TUnuran::Sample() diff --git a/math/unuran/src/TUnuran.cxx b/math/unuran/src/TUnuran.cxx index bb6b7f7134747..ca35fe7af52d9 100644 --- a/math/unuran/src/TUnuran.cxx +++ b/math/unuran/src/TUnuran.cxx @@ -172,7 +172,7 @@ bool TUnuran::SetRandomGenerator() bool TUnuran::SetContDistribution(const TUnuranContDist & dist ) { - // internal method to set in unuran the function pointer for a continous univariate distribution + // internal method to set in unuran the function pointer for a continuous univariate distribution if (fUdistr != 0) unur_distr_free(fUdistr); fUdistr = unur_distr_cont_new(); if (fUdistr == 0) return false; diff --git a/math/unuran/src/TUnuranSampler.cxx b/math/unuran/src/TUnuranSampler.cxx index 82a8404743dc8..daa7f7e96de4b 100644 --- a/math/unuran/src/TUnuranSampler.cxx +++ b/math/unuran/src/TUnuranSampler.cxx @@ -71,12 +71,12 @@ bool TUnuranSampler::Init(const char * algo) { ret = DoInitDiscrete1D(method); } else { - if (fLevel>1) Info("TUnuranSampler::Init","Initialize one-dim continous distribution with method %s",method.Data()); + if (fLevel>1) Info("TUnuranSampler::Init","Initialize one-dim continuous distribution with method %s",method.Data()); ret = DoInit1D(method); } } else { - if (fLevel>1) Info("TUnuranSampler::Init","Initialize multi-dim continous distribution with method %s",method.Data()); + if (fLevel>1) Info("TUnuranSampler::Init","Initialize multi-dim continuous distribution with method %s",method.Data()); ret = DoInitND(method); } // set print level in UNURAN (must be done after having initialized) - diff --git a/math/unuran/src/UnuranDistrAdapter.h b/math/unuran/src/UnuranDistrAdapter.h index 323d1444978e7..092736ae9c4db 100644 --- a/math/unuran/src/UnuranDistrAdapter.h +++ b/math/unuran/src/UnuranDistrAdapter.h @@ -19,7 +19,7 @@ #include <cmath> /** - Free functions adapter needed by UNURAN for onedimensional continous distributions + Free functions adapter needed by UNURAN for onedimensional continuous distributions */ #include "TUnuranContDist.h" diff --git a/math/unuran/test/unuranDistr.cxx b/math/unuran/test/unuranDistr.cxx index d9d1ba463f417..270f1c15dbb6e 100644 --- a/math/unuran/test/unuranDistr.cxx +++ b/math/unuran/test/unuranDistr.cxx @@ -31,7 +31,7 @@ using std::cout; using std::endl; -int n = 5000000; +int nsamples = 5000000; bool useRandomSeed = false; // to use a random seed different every time @@ -61,7 +61,7 @@ class DistTest { // make ref histo (uniform histo between 0,1 fHref = new TH1D("Href","uniform ref histo",100,0,1); - for (int i = 0; i < n; ++i) + for (int i = 0; i < nsamples; ++i) fHref->Fill(gRandom->Rndm() ); } @@ -78,16 +78,16 @@ class DistTest { TStopwatch w; w.Start(); - for (int i = 0; i < n; ++i) + for (int i = 0; i < nsamples; ++i) unr.Sample(); w.Stop(); - double time = w.CpuTime()*1.E9/n; + double time = w.CpuTime()*1.E9/nsamples; TH1D htmp("htmp","gaussian generated cdf",100,0,1.); // test quality (use cdf to avoid zero bins) - int n2 = n/100; + int n2 = nsamples/100; double x; for (int i = 0; i<n2; ++i) { x = unr.Sample(); @@ -112,17 +112,17 @@ class DistTest { TStopwatch w; w.Start(); - for (int i = 0; i < n; ++i) { + for (int i = 0; i < nsamples; ++i) { f->GetRandom(); } w.Stop(); - double time = w.CpuTime()*1.E9/n; + double time = w.CpuTime()*1.E9/nsamples; TH1D htmp("htmp","gaussian generated cdf",100,0,1.); // test quality (use cdf to avoid zero bins) - int n2 = n/100; + int n2 = nsamples/100; for (int i = 0; i<n2; ++i) { double x = f->GetRandom(); htmp.Fill( fCdf->Eval(x) ); @@ -232,7 +232,7 @@ int unuranDistr() { // ninv (needs cdf, pdf is an option) ret = unr.Init(dist,"ninv"); - n/= 10; // method is too slow + nsamples /= 10; // method is too slow if (!ret) { std::cerr << "Error initializing unuran with method " << unr.MethodName() << endl; iret = -5; @@ -262,7 +262,7 @@ int unuranDistr() { else iret |= t.testUnuran(unr); - n*= 10; + nsamples *= 10; ret = unr.Init(dist,"utdr"); if (!ret) { std::cerr << "Error initializing unuran with method " << unr.MethodName() << endl; @@ -311,7 +311,7 @@ int unuranDistr() { std::cerr << "Error initializing unuran with method " << unr.MethodName() << endl; iret = -20; } - int n2 = n/10; + int n2 = nsamples/10; for (int i = 0; i < n2; ++i) { double x1 = unr.Sample(); h1->Fill( x1 ); diff --git a/misc/minicern/src/zebra.f b/misc/minicern/src/zebra.f index 26c6ca42592a2..80477ee9bfa50 100644 --- a/misc/minicern/src/zebra.f +++ b/misc/minicern/src/zebra.f @@ -672,7 +672,7 @@ SUBROUTINE RZOPEN(LUNIN,CHDIR,CFNAME,CHOPTT,LRECL,ISTAT) ENDIF IF (IPASS.NE.0 .AND. LRECL2.NE.0) THEN WRITE(IQPRNT,10600) LRECL2,LRECL -10600 FORMAT(' RZOPEN: LRECL inconsistant - ', +10600 FORMAT(' RZOPEN: LRECL inconsistent - ', + ' file was opened with LRECL = ',I6, + ' should be LRECL = ',I6) ENDIF diff --git a/misc/table/doc/index.txt b/misc/table/doc/index.txt index acf276445b8de..ce0b47409abff 100644 --- a/misc/table/doc/index.txt +++ b/misc/table/doc/index.txt @@ -12,7 +12,7 @@ The base class class of this library is TDataSet: That defines the hierarchical nature the class and all its subclasses. <br> The most advanced subclasses of TDataSet are TTable and TGenericTable -to create the TDataSet implementations bearing the self-described variable lenght arrays +to create the TDataSet implementations bearing the self-described variable length arrays of the C-structures. <P> See STAR publications: diff --git a/misc/table/src/TTable.cxx b/misc/table/src/TTable.cxx index e6300781d6653..caf9eeb0e0a46 100644 --- a/misc/table/src/TTable.cxx +++ b/misc/table/src/TTable.cxx @@ -53,7 +53,7 @@ // float x_last[3]; /* coord. of last measured point (cm) */ // float length; /* from first to last point (cm) */ // float impact; /* primary vertex (cm) */ -// unsigned long map[2]; /* extrap. info. (see preceeding comments)*/ +// unsigned long map[2]; /* extrap. info. (see preceding comments)*/ // int id; /* Primary key (see comments) */ // int iflag; /* bitmask quality info. (see comments) */ // int det_id; /* Detector id information */ @@ -2158,31 +2158,41 @@ Int_t TTable::SetfN(Long_t len) #undef StreamElelement #endif -#define StreamElementIn(type) case TTableDescriptor::_NAME2_(k,type): \ - if (evolutionOn) { \ - if (nextCol->fDimensions) { \ - if (nextCol->fOffset != UInt_t(-1)) { \ - R__b.ReadFastArray((_NAME2_(type,_t) *)(row+nextCol->fOffset),nextCol->fSize/sizeof(_NAME2_(type,_t))); \ - } else { \ - _NAME2_(type,_t) *readPtrV = new _NAME2_(type,_t)[nextCol->fSize/sizeof(_NAME2_(type,_t))]; \ - R__b.ReadFastArray((_NAME2_(type,_t) *)(row+nextCol->fOffset),nextCol->fSize/sizeof(_NAME2_(type,_t))); \ - delete [] readPtrV; \ - readPtrV = 0; \ - } \ - } \ - else { \ - _NAME2_(type,_t) skipBuffer; \ - _NAME2_(type,_t) *readPtr = (_NAME2_(type,_t) *)(row+nextCol->fOffset); \ - if (nextCol->fOffset == UInt_t(-1)) readPtr = &skipBuffer; \ - R__b >> *readPtr; \ - } \ - } else { \ - if (nextCol->fDimensions) { \ - R__b.ReadFastArray ((_NAME2_(type,_t) *)(row+nextCol->fOffset),nextCol->fSize/sizeof(_NAME2_(type,_t))); \ - } else \ - R__b >> *(_NAME2_(type,_t) *)(row+nextCol->fOffset); \ - } \ - break +#define StreamElementIn(type) case TTableDescriptor::_NAME2_(k,type): \ + if (evolutionOn) { \ + if (nextCol->fDimensions) { \ + _NAME2_(type,_t) *readPtrV = new _NAME2_(type,_t)[nextCol->fSize/sizeof(_NAME2_(type,_t))]; \ + R__b.ReadFastArray(readPtrV,nextCol->fSize/sizeof(_NAME2_(type,_t))); \ + if (nextCol->fOffset != UInt_t(-1)) { \ + UInt_t x[3]; \ + _NAME2_(type,_t) *writePtrV = (_NAME2_(type,_t) *)(row+currentDescriptor->Offset(colCounter)); \ + memset(writePtrV, 0, currentDescriptor->ColumnSize(colCounter)); \ + for (UInt_t i = 0; i < nextCol->fSize/sizeof(_NAME2_(type,_t)); i++) { \ + UInt_t ii = i; \ + for (Int_t d = nextCol->fDimensions-1; d >=0; d--) { \ + x[d] = ii% nextCol->fIndexArray[d]; ii /= nextCol->fIndexArray[d]; \ + } \ + Int_t j = -1; \ + for (UInt_t d = 0; d < currentDescriptor->Dimensions(colCounter); d++) { \ + if (x[d] >= currentDescriptor->IndexArray(colCounter)[d]) {j = -1; break;} \ + if (d == 0) j = x[d]; \ + else j = currentDescriptor->IndexArray(colCounter)[d]*j + x[d]; \ + } \ + if (j >= 0) writePtrV[j] = readPtrV[i]; \ + } \ + } \ + delete [] readPtrV; \ + readPtrV = 0; \ + } else { \ + _NAME2_(type,_t) skipBuffer; \ + _NAME2_(type,_t) *readPtr = (_NAME2_(type,_t) *)(row+nextCol->fOffset); \ + if (nextCol->fOffset == UInt_t(-1)) readPtr = &skipBuffer; R__b >> *readPtr; \ + } \ + } else { if (nextCol->fDimensions) { \ + R__b.ReadFastArray ((_NAME2_(type,_t) *)(row+nextCol->fOffset),nextCol->fSize/sizeof(_NAME2_(type,_t))); \ + } else R__b >> *(_NAME2_(type,_t) *)(row+nextCol->fOffset); \ + } \ + break; #define StreamElementOut(type) case TTableDescriptor::_NAME2_(k,type): \ if (nextCol->fDimensions) \ diff --git a/misc/table/src/TTableDescriptor.cxx b/misc/table/src/TTableDescriptor.cxx index d2df49121f815..59de7ec637009 100644 --- a/misc/table/src/TTableDescriptor.cxx +++ b/misc/table/src/TTableDescriptor.cxx @@ -349,15 +349,25 @@ Int_t TTableDescriptor::UpdateOffsets(const TTableDescriptor *newDescriptor) if (newType == kInt) newType = kLong; else if (newType == kUInt) newType = kULong; #endif - if ( colNewIndx >=0 - && Dimensions(colCounter) == newDescriptor->Dimensions(colNewIndx) - && ColumnType(colCounter) == newType) { + if ( colNewIndx >=0 + && Dimensions(colCounter) == newDescriptor->Dimensions(colNewIndx) + && ColumnType(colCounter) == newType) { + Bool_t same = kFALSE; + if ( Dimensions(colCounter)) { + for (UInt_t d = 0; d < Dimensions(colCounter); ++d) { + if (IndexArray(colCounter)[d] != newDescriptor->IndexArray(colNewIndx)[d]){ same = kTRUE; break; } + } + } SetOffset(newDescriptor->Offset(colNewIndx),colCounter); if (colNewIndx != colCounter) { Printf("Schema evolution: \t%d column of the \"%s\" table has been moved to %d-th column\n", colCounter,ColumnName(colCounter),colNewIndx); mismathes++; - } + } else if (same) { + Printf("Schema evolution: \t%d column \"%s\" size has been changed\n", + colNewIndx, ColumnName(colCounter)); + mismathes++; + } } else { Printf("Schema evolution: \t%d column \"%s\" of %d type has been lost\n", colCounter,ColumnName(colCounter),ColumnType(colCounter)); diff --git a/montecarlo/eg/inc/TDatabasePDG.h b/montecarlo/eg/inc/TDatabasePDG.h index 3224781168eac..12c4f22b167c6 100644 --- a/montecarlo/eg/inc/TDatabasePDG.h +++ b/montecarlo/eg/inc/TDatabasePDG.h @@ -30,13 +30,15 @@ class TDatabasePDG: public TNamed { TObjArray *fListOfClasses; // list of classes (leptons etc.) mutable TExMap *fPdgMap; //!hash-map from pdg-code to particle + // make copy-constructor and assigment protected since class cannot be copied TDatabasePDG(const TDatabasePDG& db) : TNamed(db), fParticleList(db.fParticleList), fListOfClasses(db.fListOfClasses), fPdgMap(0) { } TDatabasePDG& operator=(const TDatabasePDG& db) - {if(this!=&db) {TNamed::operator=(db); fParticleList=db.fParticleList; - fListOfClasses=db.fListOfClasses;} return *this;} + {if(this!=&db) {TNamed::operator=(db); fParticleList=db.fParticleList; + fListOfClasses=db.fListOfClasses; fPdgMap=db.fPdgMap;} + return *this;} void BuildPdgMap() const; diff --git a/montecarlo/eg/src/TDatabasePDG.cxx b/montecarlo/eg/src/TDatabasePDG.cxx index 7731ab31ee70a..87d7f84badba8 100644 --- a/montecarlo/eg/src/TDatabasePDG.cxx +++ b/montecarlo/eg/src/TDatabasePDG.cxx @@ -75,11 +75,14 @@ TDatabasePDG::~TDatabasePDG() if (fParticleList) { fParticleList->Delete(); - delete fParticleList; - delete fPdgMap; + delete fParticleList; // this deletes all objects in the list + if (fPdgMap) delete fPdgMap; } // classes do not own particles... - if (fListOfClasses) delete fListOfClasses; + if (fListOfClasses) { + fListOfClasses->Delete(); + delete fListOfClasses; + } gROOT->GetListOfSpecials()->Remove(this); fgInstance = 0; } diff --git a/montecarlo/pythia6/CMakeLists.txt b/montecarlo/pythia6/CMakeLists.txt index 3ed2f82ff71fd..1f6ba98060a9e 100644 --- a/montecarlo/pythia6/CMakeLists.txt +++ b/montecarlo/pythia6/CMakeLists.txt @@ -9,5 +9,11 @@ ROOT_USE_PACKAGE(math/physics) ROOT_GENERATE_DICTIONARY(G__Pythia6 *.h LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(EGPythia6 LINKDEF LinkDef.h DEPENDENCIES EG Graf VMC Physics ) -ROOT_LINKER_LIBRARY(EGPythia6 *.cxx G__Pythia6.cxx LIBRARIES Core ${PYTHIA6_LIBRARIES} DEPENDENCIES EG Graf VMC Physics) +if(pythia6_nolink) + string(REGEX REPLACE "-Wl,--no-undefined" "" CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS}") + ROOT_LINKER_LIBRARY(EGPythia6 *.cxx G__Pythia6.cxx LIBRARIES Core DEPENDENCIES EG Graf VMC Physics) +else() + ROOT_LINKER_LIBRARY(EGPythia6 *.cxx G__Pythia6.cxx LIBRARIES Core ${PYTHIA6_LIBRARIES} DEPENDENCIES EG Graf VMC Physics) +endif() + ROOT_INSTALL_HEADERS() diff --git a/montecarlo/pythia6/src/TPythia6.cxx b/montecarlo/pythia6/src/TPythia6.cxx index 9230f8e8b9de2..509a552e08f4d 100644 --- a/montecarlo/pythia6/src/TPythia6.cxx +++ b/montecarlo/pythia6/src/TPythia6.cxx @@ -431,14 +431,20 @@ void TPythia6::Initialize(const char *frame, const char *beam, const char *targe char ctarget[8]; strlcpy(ctarget,target,8); + // For frames "3MOM", "4MOM" and "5MOM" see p. 181-182 of the version 6 manual, + // http://home.thep.lu.se/~torbjorn/pythia/lutp0613man2.pdf + // their usage may depend on the version of Pythia6 used if ( (!strncmp(frame, "CMS" ,3)) && (!strncmp(frame, "FIXT" ,4)) && (!strncmp(frame, "USER" ,4)) && (!strncmp(frame, "FOUR" ,4)) && (!strncmp(frame, "FIVE" ,4)) && + (!strncmp(frame, "3MOM" ,4)) && + (!strncmp(frame, "4MOM" ,4)) && + (!strncmp(frame, "5MOM" ,4)) && (!strncmp(frame, "NONE" ,4)) ) { printf("WARNING! In TPythia6:Initialize():\n"); - printf(" specified frame=%s is neither of CMS,FIXT,USER,FOUR,FIVE,NONE\n",frame); + printf(" specified frame=%s is neither of CMS,FIXT,USER,FOUR,FIVE,NONE,3MOM,4MOM,5MOM\n",frame); printf(" resetting to \"CMS\" ."); snprintf(cframe,4,"CMS"); } @@ -487,14 +493,11 @@ void TPythia6::Initialize(const char *frame, const char *beam, const char *targe snprintf(ctarget,8,"p+"); } - - Pyinit(cframe, cbeam ,ctarget, win); char atitle[32]; snprintf(atitle,32," %s-%s at %g GeV",cbeam,ctarget,win); SetTitle(atitle); - } diff --git a/montecarlo/pythia8/Module.mk b/montecarlo/pythia8/Module.mk index b3d0ee426d3db..e0184cd98b493 100644 --- a/montecarlo/pythia8/Module.mk +++ b/montecarlo/pythia8/Module.mk @@ -50,7 +50,7 @@ $(PYTHIA8LIB): $(PYTHIA8O) $(PYTHIA8DO) $(ORDER_) $(MAINLIBS) $(PYTHIA8LIBDEP) $(PYTHIA8DS): $(PYTHIA8H) $(PYTHIA8L) $(ROOTCINTTMPDEP) $(MAKEDIR) @echo "Generating dictionary $@..." - $(ROOTCINTTMP) -f $@ -c -I$(FPYTHIA8INCDIR) $(PYTHIA8H) $(PYTHIA8L) + $(ROOTCINTTMP) -f $@ -c $(FPYTHIA8INCDIR:%=-I%) $(PYTHIA8H) $(PYTHIA8L) $(PYTHIA8MAP): $(RLIBMAP) $(MAKEFILEDEP) $(PYTHIA8L) $(RLIBMAP) -o $@ -l $(PYTHIA8LIB) \ diff --git a/montecarlo/pythia8/inc/TPythia8.h b/montecarlo/pythia8/inc/TPythia8.h index c36f187e80fc4..0f70c2788df4a 100644 --- a/montecarlo/pythia8/inc/TPythia8.h +++ b/montecarlo/pythia8/inc/TPythia8.h @@ -66,7 +66,7 @@ */ #include "TGenerator.h" -#include "Pythia.h" +#include "Pythia8/Pythia.h" class Pythia; diff --git a/montecarlo/pythia8/inc/TPythia8Decayer.h b/montecarlo/pythia8/inc/TPythia8Decayer.h index 0f17cbbf6ac12..e80e74f7d6c22 100644 --- a/montecarlo/pythia8/inc/TPythia8Decayer.h +++ b/montecarlo/pythia8/inc/TPythia8Decayer.h @@ -7,7 +7,7 @@ #ifndef TPYTHIA8DECAYER_H #define TPYTHIA8DECAYER_H -#include <TVirtualMCDecayer.h> +#include "TVirtualMCDecayer.h" class TClonesArrray; class TLorentzVector; diff --git a/montecarlo/pythia8/src/TPythia8.cxx b/montecarlo/pythia8/src/TPythia8.cxx index 11fed847031b9..8b9767381fd91 100644 --- a/montecarlo/pythia8/src/TPythia8.cxx +++ b/montecarlo/pythia8/src/TPythia8.cxx @@ -90,11 +90,11 @@ TPythia8::TPythia8(): fNumberOfParticles(0) { // Constructor - if (fgInstance) + if (fgInstance) Fatal("TPythia8", "There's already an instance of TPythia8"); - + delete fParticles; // was allocated as TObjArray in TGenerator - + fParticles = new TClonesArray("TParticle",50); fPythia = new Pythia8::Pythia(); } @@ -106,11 +106,11 @@ TPythia8::TPythia8(const char *xmlDir): fNumberOfParticles(0) { // Constructor with an xmlDir (eg "../xmldoc" - if (fgInstance) + if (fgInstance) Fatal("TPythia8", "There's already an instance of TPythia8"); - + delete fParticles; // was allocated as TObjArray in TGenerator - + fParticles = new TClonesArray("TParticle",50); fPythia = new Pythia8::Pythia(xmlDir); } @@ -150,7 +150,6 @@ void TPythia8::GenerateEvent() fNumberOfParticles = fPythia->event.size() - 1; ImportParticles(); } - //___________________________________________________________________________ Int_t TPythia8::ImportParticles(TClonesArray *particles, Option_t *option) { @@ -160,19 +159,23 @@ Int_t TPythia8::ImportParticles(TClonesArray *particles, Option_t *option) clonesParticles.Clear(); Int_t nparts=0; Int_t i; - fNumberOfParticles = fPythia->event.size() - 1; + Int_t ioff = 0; + fNumberOfParticles = fPythia->event.size(); + if (fPythia->event[0].id() == 90) { + ioff = -1; + } if (!strcmp(option,"") || !strcmp(option,"Final")) { - for (i = 0; i <= fNumberOfParticles; i++) { + for (i = 0; i < fNumberOfParticles; i++) { if (fPythia->event[i].id() == 90) continue; if (fPythia->event[i].isFinal()) { new(clonesParticles[nparts]) TParticle( fPythia->event[i].id(), - fPythia->event[i].status(), - fPythia->event[i].mother1() - 1, - fPythia->event[i].mother2() - 1, - fPythia->event[i].daughter1() - 1, - fPythia->event[i].daughter2() - 1, + fPythia->event[i].isFinal(), + fPythia->event[i].mother1() + ioff, + fPythia->event[i].mother2() + ioff, + fPythia->event[i].daughter1() + ioff, + fPythia->event[i].daughter2() + ioff, fPythia->event[i].px(), // [GeV/c] fPythia->event[i].py(), // [GeV/c] fPythia->event[i].pz(), // [GeV/c] @@ -180,20 +183,20 @@ Int_t TPythia8::ImportParticles(TClonesArray *particles, Option_t *option) fPythia->event[i].xProd(), // [mm] fPythia->event[i].yProd(), // [mm] fPythia->event[i].zProd(), // [mm] - fPythia->event[i].tProd()); // [mm/c] + fPythia->event[i].tProd()); // [mm/c] nparts++; } // final state partice } // particle loop } else if (!strcmp(option,"All")) { - for (i = 0; i <= fNumberOfParticles; i++) { + for (i = 0; i < fNumberOfParticles; i++) { if (fPythia->event[i].id() == 90) continue; new(clonesParticles[nparts]) TParticle( fPythia->event[i].id(), - fPythia->event[i].status(), - fPythia->event[i].mother1() - 1, - fPythia->event[i].mother2() - 1, - fPythia->event[i].daughter1() - 1, - fPythia->event[i].daughter2() - 1, + fPythia->event[i].isFinal(), + fPythia->event[i].mother1() + ioff, + fPythia->event[i].mother2() + ioff, + fPythia->event[i].daughter1() + ioff, + fPythia->event[i].daughter2() + ioff, fPythia->event[i].px(), // [GeV/c] fPythia->event[i].py(), // [GeV/c] fPythia->event[i].pz(), // [GeV/c] @@ -202,9 +205,10 @@ Int_t TPythia8::ImportParticles(TClonesArray *particles, Option_t *option) fPythia->event[i].yProd(), // [mm] fPythia->event[i].zProd(), // [mm] fPythia->event[i].tProd()); // [mm/c] - nparts++; - } // particle loop + nparts++; + } // particle loop } + if(ioff==-1) fNumberOfParticles--; return nparts; } @@ -213,16 +217,23 @@ TObjArray* TPythia8::ImportParticles(Option_t* /* option */) { // Import particles from Pythia stack fParticles->Clear(); - Int_t numpart = fPythia->event.size() - 1; + Int_t ioff = 0; + Int_t numpart = fPythia->event.size(); + if (fPythia->event[0].id() == 90) { + numpart--; + ioff = -1; + } + + TClonesArray &a = *((TClonesArray*)fParticles); for (Int_t i = 1; i <= numpart; i++) { new(a[i]) TParticle( fPythia->event[i].id(), - fPythia->event[i].status(), - fPythia->event[i].mother1() - 1, - fPythia->event[i].mother2() - 1, - fPythia->event[i].daughter1() - 1, - fPythia->event[i].daughter2() - 1, + fPythia->event[i].isFinal(), + fPythia->event[i].mother1() + ioff, + fPythia->event[i].mother2() + ioff, + fPythia->event[i].daughter1() + ioff, + fPythia->event[i].daughter2() + ioff, fPythia->event[i].px(), // [GeV/c] fPythia->event[i].py(), // [GeV/c] fPythia->event[i].pz(), // [GeV/c] @@ -273,7 +284,7 @@ void TPythia8::EventListing() const //___________________________________________________________________________ void TPythia8::AddParticlesToPdgDataBase() { - // Add some pythia specific particle code to the data base + // Add some pythia specific particle code to the data base TDatabasePDG *pdgDB = TDatabasePDG::Instance(); pdgDB->AddParticle("string","string", 0, kTRUE, diff --git a/montecarlo/pythia8/src/TPythia8Decayer.cxx b/montecarlo/pythia8/src/TPythia8Decayer.cxx index 68e1598759687..e7d916401b786 100644 --- a/montecarlo/pythia8/src/TPythia8Decayer.cxx +++ b/montecarlo/pythia8/src/TPythia8Decayer.cxx @@ -16,8 +16,8 @@ * provided "as is" without express or implied warranty. * **************************************************************************/ -#include <TLorentzVector.h> -#include <TPythia8.h> +#include "TLorentzVector.h" +#include "TPythia8.h" #include "TPythia8Decayer.h" ClassImp(TPythia8Decayer) diff --git a/net/CMakeLists.txt b/net/CMakeLists.txt index c60734a3edd80..6aab949b9a299 100644 --- a/net/CMakeLists.txt +++ b/net/CMakeLists.txt @@ -1,3 +1,4 @@ + add_subdirectory(net) add_subdirectory(auth) # special CMakeListst.txt @@ -23,5 +24,14 @@ if(monalisa) add_subdirectory(monalisa) endif() +if(ldap) + add_subdirectory(ldap) +endif() +if(globus) + add_subdirectory(globusauth) +endif() +if(davix) + add_subdirectory(davix) +endif() diff --git a/net/alien/inc/TAlienCollection.h b/net/alien/inc/TAlienCollection.h index 19d5856d025d6..ec57866154424 100644 --- a/net/alien/inc/TAlienCollection.h +++ b/net/alien/inc/TAlienCollection.h @@ -114,6 +114,7 @@ class TAlienCollection : public TGridCollection { Bool_t OverlapCollection(TGridCollection *comparator); void Add(TGridCollection *addcollection); + void AddFast(TGridCollection *addcollection); Bool_t Stage(Bool_t bulk = kFALSE, Option_t* option = ""); Bool_t Prepare(Bool_t bulk = kFALSE) { return Stage(bulk,"option=0"); } diff --git a/net/alien/inc/TAlienFile.h b/net/alien/inc/TAlienFile.h index 8c62934bd2618..42bf9f2545a7c 100644 --- a/net/alien/inc/TAlienFile.h +++ b/net/alien/inc/TAlienFile.h @@ -43,9 +43,16 @@ class TAlienFile : public TXNetFile { private: TString fLfn; // logical file name TString fAuthz; // authorization envelope - + TString fGUID; // GUID + TString fUrl; // url for the opened copy + TString fPfn; // physical file name + TString fSE; // Storage element + Int_t fImage; // Image number + Int_t fNreplicas; // Number of replicas + Long64_t fOpenedAt; // Absolute value for time when opened + Double_t fElapsed; // Time elapsed to opem file public: - TAlienFile() : TXNetFile(), fLfn(), fAuthz() { } + TAlienFile() : TXNetFile(), fLfn(), fAuthz(), fGUID(), fUrl(), fPfn(), fSE(), fImage(0), fNreplicas(0), fOpenedAt(0), fElapsed(0) { } TAlienFile(const char *purl, Option_t *option = "", const char *ftitle = "", Int_t compress = 1, Bool_t parallelopen = kFALSE, const char *lurl = 0, @@ -54,12 +61,32 @@ class TAlienFile : public TXNetFile { virtual void Close(const Option_t *opt = ""); + const char *GetGUID() const {return fGUID;} + Double_t GetElapsed() const {return fElapsed;} + Int_t GetImage() const {return fImage;} + const char *GetLfn() const {return fLfn;} + Int_t GetNreplicas() const {return fNreplicas;} + Long64_t GetOpenTime() const {return fOpenedAt;} + const char *GetPfn() const {return fPfn;} + const char *GetSE() const {return fSE;} + const char *GetUrl() const {return fUrl;} + +protected: + void SetGUID(const char *guid) {fGUID = guid;} + void SetElapsed(Double_t real) {fElapsed = real;} + void SetImage(Int_t image) {fImage = image;} + void SetNreplicas(Int_t nrep) {fNreplicas = nrep;} + void SetPfn(const char *pfn) {fPfn = pfn;} + void SetSE(const char *se) {fSE = se;} + void SetUrl(const char *url) {fUrl = url;} + +public: static TAlienFile *Open(const char *lfn, const Option_t *option = "", const char *title = "", Int_t compress = 1, Bool_t parallelopen = kFALSE); static TString SUrl(const char *lfn); - ClassDef(TAlienFile, 3) //A ROOT file that reads/writes via AliEn services and TXNetFile protocol + ClassDef(TAlienFile, 4) //A ROOT file that reads/writes via AliEn services and TXNetFile protocol }; #endif diff --git a/net/alien/src/TAlienCollection.cxx b/net/alien/src/TAlienCollection.cxx index 50cd608c502c2..28470753e65a3 100644 --- a/net/alien/src/TAlienCollection.cxx +++ b/net/alien/src/TAlienCollection.cxx @@ -956,6 +956,22 @@ void TAlienCollection::Add(TGridCollection * addcollection) } } +//______________________________________________________________________________ +void TAlienCollection::AddFast(TGridCollection * addcollection) +{ + // adds <addcollection> to this collection - NO check for identical elements + + if ((!addcollection)) { + return; + } + addcollection->Reset(); + TMap *addmap, *clonemap; + while ((addmap = addcollection->Next())) { + clonemap = (TMap *) addmap->Clone(); + fFileGroupList->Add(clonemap); + } +} + //______________________________________________________________________________ Bool_t TAlienCollection::LookupSUrls(Bool_t verbose) { diff --git a/net/alien/src/TAlienFile.cxx b/net/alien/src/TAlienFile.cxx index 103fd79619444..ffc201140f3cc 100644 --- a/net/alien/src/TAlienFile.cxx +++ b/net/alien/src/TAlienFile.cxx @@ -38,6 +38,7 @@ #include "TString.h" #include "Rtypes.h" #include "TSystem.h" +#include "TStopwatch.h" #include "TVirtualMonitoring.h" #include "TVirtualMutex.h" #include "TProcessUUID.h" @@ -64,7 +65,7 @@ TAlienFile::TAlienFile(const char *purl, Option_t *option, // "alien:///alice/test.root" // If you want to write a file on specific storage element use the syntax // "alien:///alice/test.root?&se=Alice::CERN::Storage" - // The default SE is specified by the enviroment variable alien_CLOSE_SE + // The default SE is specified by the environment variable alien_CLOSE_SE // // If you read a file, the closest file image to alien_CLOSE_SE is taken. // If the file cannot opened from the closest image, the next image is tried, @@ -87,6 +88,13 @@ TAlienFile::TAlienFile(const char *purl, Option_t *option, TUrl logicalurl(lurl); fLfn = logicalurl.GetFile(); fAuthz = authz; + fGUID = ""; + fUrl = ""; + fPfn = ""; + fSE = ""; + fImage = 0; + fNreplicas = 0; + fOpenedAt = time(0); } //______________________________________________________________________________ @@ -111,6 +119,8 @@ TAlienFile *TAlienFile::Open(const char *url, Option_t *option, TString fAName = name; TString fAOption = option; TUrl fAUrl; + TString sguid, pfnStr; + Int_t nreplicas = 0; Bool_t fAWritable; fAWritable = kFALSE; TString authz; @@ -158,8 +168,10 @@ TAlienFile *TAlienFile::Open(const char *url, Option_t *option, fAOption.ToUpper(); TObjString *urlStr = 0; + TString urlStrs; TObjString *authzStr = 0; TObjString *seStr = 0; + TString seStrs, snreplicas; TString command; TString repcommand; @@ -309,13 +321,27 @@ TAlienFile *TAlienFile::Open(const char *url, Option_t *option, TObject *urlObject = map->GetValue("url"); urlStr = dynamic_cast < TObjString * >(urlObject); + if (urlStr) urlStrs = urlStr->GetName(); TObject *authzObject = map->GetValue("envelope"); authzStr = dynamic_cast < TObjString * >(authzObject); TObject *seObject = map->GetValue("se"); seStr = dynamic_cast < TObjString * >(seObject); - + if (seStr) seStrs = seStr->GetName(); + + TObject *nreplicasObject = map->GetValue("nSEs"); + if (nreplicasObject) { + snreplicas = nreplicasObject->GetName(); + nreplicas = snreplicas.Atoi(); + } + + TObject *guidObject = map->GetValue("guid"); + if (guidObject) sguid = guidObject->GetName(); + + TObject *pfnObject = map->GetValue("pfn"); + if (pfnObject) pfnStr = pfnObject->GetName(); + if (map->GetValue("eof")) { imageeof = kTRUE; // there is only one result line .... in case it is at all .... @@ -463,9 +489,12 @@ TAlienFile *TAlienFile::Open(const char *url, Option_t *option, delete result; if (gDebug > 1) ::Info("TAlienFile","Opening AUrl <%s> lUrl <%s>",fAUrl.GetUrl(),lUrl.GetUrl()); + TStopwatch timer; + timer.Start(); TAlienFile *alienfile = new TAlienFile(fAUrl.GetUrl(), fAOption, ftitle, compress, parallelopen, lUrl.GetUrl(), authz); + timer.Stop(); if (alienfile->IsZombie()) { delete alienfile; if (fAWritable) { @@ -474,6 +503,13 @@ TAlienFile *TAlienFile::Open(const char *url, Option_t *option, } continue; } else { + alienfile->SetSE(seStrs); + alienfile->SetPfn(pfnStr); + alienfile->SetImage(imagenr); + alienfile->SetNreplicas(nreplicas); + alienfile->SetGUID(sguid); + alienfile->SetUrl(urlStrs); + alienfile->SetElapsed(timer.RealTime()); return alienfile; } } while (imagenr < MAX_FILE_IMAGES); diff --git a/net/auth/Module.mk b/net/auth/Module.mk index 30eed2de31bd8..534dc9293ae1a 100644 --- a/net/auth/Module.mk +++ b/net/auth/Module.mk @@ -71,6 +71,16 @@ EXTRA_RAUTHFLAGS += $(SSLINCDIR:%=-I%) EXTRA_RAUTHLIBS += $(SSLLIBDIR) $(SSLLIB) endif +ifeq ($(PLATFORM),win32) +EXTRA_RAUTHFLAGS += -DOPENSSL_NO_TLSEXT +# extra libs needed when using some OpenSSL distributions +EXTRA_RAUTHLIBS += WSock32.lib Ws2_32.lib +endif + +ifeq ($(ARCH),win32gcc) +EXTRA_RAUTHLIBS += -lz +endif + # used in the main Makefile ALLHDRS += $(patsubst $(MODDIRI)/%.h,include/%.h,$(RAUTHH)) \ include/DaemonUtils.h diff --git a/net/auth/src/TAuthenticate.cxx b/net/auth/src/TAuthenticate.cxx index 4b9913adfd03c..1ff818be4bf14 100644 --- a/net/auth/src/TAuthenticate.cxx +++ b/net/auth/src/TAuthenticate.cxx @@ -502,8 +502,11 @@ Bool_t TAuthenticate::Authenticate() if (user != "") CheckNetrc(user, passwd, pwhash, kTRUE); if (passwd == "") { - if (fgPromptUser) - user = PromptUser(fRemote); + if (fgPromptUser) { + char *p = PromptUser(fRemote); + user = p; + delete [] p; + } rc = GetUserPasswd(user, passwd, pwhash, kTRUE); } fUser = user; diff --git a/net/auth/src/THostAuth.cxx b/net/auth/src/THostAuth.cxx index efa548b51da79..8f8d69d269b73 100644 --- a/net/auth/src/THostAuth.cxx +++ b/net/auth/src/THostAuth.cxx @@ -34,7 +34,7 @@ ClassImp(THostAuth) //______________________________________________________________________________ THostAuth::THostAuth() : TObject() { - // Deafult constructor. + // Default constructor. Create(0, 0); } diff --git a/net/bonjour/CMakeLists.txt b/net/bonjour/CMakeLists.txt index 4c15d93b05d53..cb1458341a2a2 100644 --- a/net/bonjour/CMakeLists.txt +++ b/net/bonjour/CMakeLists.txt @@ -9,7 +9,7 @@ include_directories(${BONJOUR_INCLUDE_DIR}) ROOT_GENERATE_DICTIONARY(G__BONJ *.h LINKDEF LinkDef.h) ROOT_GENERATE_ROOTMAP(Bonjour LINKDEF LinkDef.h DEPENDENCIES ) -ROOT_LINKER_LIBRARY(Bonjour *.cxx G__BONJ.cxx LIBRARIES ${BONJOUR_LIBRARIES}) +ROOT_LINKER_LIBRARY(Bonjour *.cxx G__BONJ.cxx LIBRARIES ${BONJOUR_LIBRARIES} Net) ROOT_INSTALL_HEADERS() diff --git a/net/davix/CMakeLists.txt b/net/davix/CMakeLists.txt new file mode 100644 index 0000000000000..3f09ccb01458a --- /dev/null +++ b/net/davix/CMakeLists.txt @@ -0,0 +1,18 @@ +############################################################################ +# CMakeLists.txt file for building ROOT net/davix package +# @author Pere Mato, CERN +############################################################################ + +ROOT_USE_PACKAGE(core) +ROOT_USE_PACKAGE(io/io) +ROOT_USE_PACKAGE(net/net) + +include_directories(${DAVIX_INCLUDE_DIRS}) + +ROOT_GENERATE_DICTIONARY(G__DAVIX *.h LINKDEF LinkDef.h) +ROOT_GENERATE_ROOTMAP(RDAVIX LINKDEF LinkDef.h DEPENDENCIES RIO Net) +ROOT_LINKER_LIBRARY(RDAVIX *.cxx G__DAVIX.cxx LIBRARIES ${DAVIX_LIBRARIES} DEPENDENCIES RIO Net) +add_dependencies(RDAVIX DAVIX) + +ROOT_INSTALL_HEADERS() + diff --git a/net/davix/Module.mk b/net/davix/Module.mk new file mode 100644 index 0000000000000..3480879655d91 --- /dev/null +++ b/net/davix/Module.mk @@ -0,0 +1,70 @@ +# Module.mk for DAVIX module +# +# Author: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de> + +MODNAME := davix +MODDIR := $(ROOT_SRCDIR)/net/$(MODNAME) +MODDIRS := $(MODDIR)/src +MODDIRI := $(MODDIR)/inc + +DAVIXDIR := $(MODDIR) +DAVIXDIRS := $(DAVIXDIR)/src +DAVIXDIRI := $(DAVIXDIR)/inc + +##### libRDAVIX ##### +DAVIXL := $(MODDIRI)/LinkDef.h +DAVIXDS := $(call stripsrc,$(MODDIRS)/G__DAVIX.cxx) +DAVIXDO := $(DAVIXDS:.cxx=.o) +DAVIXDH := $(DAVIXDS:.cxx=.h) + +DAVIXH := $(filter-out $(MODDIRI)/LinkDef%,$(wildcard $(MODDIRI)/*.h)) +DAVIXS := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx)) +DAVIXO := $(call stripsrc,$(DAVIXS:.cxx=.o)) + +DAVIXDEP := $(DAVIXO:.o=.d) $(DAVIXDO:.o=.d) + +DAVIXLIB := $(LPATH)/libRDAVIX.$(SOEXT) +DAVIXMAP := $(DAVIXLIB:.$(SOEXT)=.rootmap) + +# used in the main Makefile +ALLHDRS += $(patsubst $(MODDIRI)/%.h,include/%.h,$(DAVIXH)) +ALLLIBS += $(DAVIXLIB) +ALLMAPS += $(DAVIXMAP) + +# include all dependency files +INCLUDEFILES += $(DAVIXDEP) + +##### local rules ##### +.PHONY: all-$(MODNAME) clean-$(MODNAME) distclean-$(MODNAME) + +include/%.h: $(DAVIXDIRI)/%.h + cp $< $@ + +$(DAVIXLIB): $(DAVIXO) $(DAVIXDO) $(ORDER_) $(MAINLIBS) $(DAVIXLIBDEP) + @$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \ + "$(SOFLAGS)" libRDAVIX.$(SOEXT) $@ "$(DAVIXO) $(DAVIXDO)" \ + "$(DAVIXLIBEXTRA) $(DAVIXLIBDIR) $(DAVIXCLILIB)" + +$(DAVIXDS): $(DAVIXH) $(DAVIXL) $(ROOTCINTTMPDEP) + $(MAKEDIR) + @echo "Generating dictionary $@..." + $(ROOTCINTTMP) -f $@ -c $(DAVIXH) $(DAVIXL) + +$(DAVIXMAP): $(RLIBMAP) $(MAKEFILEDEP) $(DAVIXL) + $(RLIBMAP) -o $@ -l $(DAVIXLIB) \ + -d $(DAVIXLIBDEPM) -c $(DAVIXL) + +all-$(MODNAME): $(DAVIXLIB) $(DAVIXMAP) + +clean-$(MODNAME): + @rm -f $(DAVIXO) $(DAVIXDO) + +clean:: clean-$(MODNAME) + +distclean-$(MODNAME): clean-$(MODNAME) + @rm -f $(DAVIXDEP) $(DAVIXDS) $(DAVIXDH) $(DAVIXLIB) $(DAVIXMAP) + +distclean:: distclean-$(MODNAME) + +##### extra rules ###### +$(DAVIXO) $(DAVIXDO): CXXFLAGS += $(DAVIXINCDIR:%=-I%) diff --git a/net/davix/inc/LinkDef.h b/net/davix/inc/LinkDef.h new file mode 100644 index 0000000000000..0aab1b4e841d9 --- /dev/null +++ b/net/davix/inc/LinkDef.h @@ -0,0 +1,10 @@ +#ifdef __CINT__ + +#pragma link off all globals; +#pragma link off all classes; +#pragma link off all functions; + +#pragma link C++ class TDavixFile+; +#pragma link C++ class TDavixSystem+; + +#endif diff --git a/net/davix/inc/TDavixFile.h b/net/davix/inc/TDavixFile.h new file mode 100644 index 0000000000000..4798d1c110465 --- /dev/null +++ b/net/davix/inc/TDavixFile.h @@ -0,0 +1,113 @@ +// @(#)root/net:$Id$ +// Author: Adrien Devresse and Tigran Mkrtchyan + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TDavixFile +#define ROOT_TDavixFile + +////////////////////////////////////////////////////////////////////////// +// // +// TDavixFile // +// // +// A TDavixFile is like a normal TFile except that it uses // +// libdavix to read/write remote files. // +// It supports HTTP and HTTPS in a number of dialects and options // +// e.g. S3 is one of them // +// Other caracteristics come from the full support of Davix, // +// e.g. full redirection support in any circumstance // +// // +// Authors: Adrien Devresse (CERN IT/SDC) // +// Tigran Mkrtchyan (DESY) // +// // +// Checks, refactoring and ROOT5 porting: // +// Fabrizio Furano (CERN IT/SDC) // +// // +// September 2013 // +// // +////////////////////////////////////////////////////////////////////////// + +// +// Parameters that influence the behavior of TDavixFile/TDavixSystem. The names should be self-explanatory +// +//Davix.Debug +//Davix.GSI.UserProxy +//Davix.GSI.UserCert +//Davix.GSI.UserKey + +//Davix.GSI.CAdir +//Davix.GSI.CACheck +//Davix.GSI.GridMode +// +// Environment variables: +// X509_USER_CERT, X509_USER_KEY, X509_USER_PROXY ... usual meaning for the X509 Grid things. gEnv vars have higher priority. + +#include "TFile.h" +#include "TUrl.h" +#include "TSystem.h" +#include "TMutex.h" + +class TDavixFileInternal; +struct Davix_fd; + + +class TDavixFile : public TFile { +private: + TDavixFileInternal* d_ptr; + + void Init(Bool_t init); + Long64_t DavixReadBuffer(Davix_fd *fd, char *buf, Int_t len); + Long64_t DavixPReadBuffer(Davix_fd *fd, char *buf, Long64_t pos, Int_t len); + Long64_t DavixReadBuffers(Davix_fd *fd, char *buf, Long64_t *pos, Int_t *len, Int_t nbuf); + Long64_t DavixWriteBuffer(Davix_fd *fd, const char *buf, Int_t len); + Int_t DavixStat(struct stat *st) const; + + // perfStats + Double_t eventStart(); + void eventStop(Double_t t, Long64_t len); + +public: + /// + /// Open function for TDavixFile + /// + /// TDavixFile supports several options : + /// + /// - GRID_MODE=yes : enable the grid authentication and CA support + /// - CA_CHECK=no : remove all the certificate authority check, this option can create a security vulnerability + /// - S3_SECKEY=string : Amazon S3 secret token + /// - S3_ACCKEY=string : Amazon S3 access token + /// + /// Several parameters can be used if separated with whitespace + + TDavixFile(const char* url, Option_t *option="", const char *ftitle="", Int_t compress=1); + + ~TDavixFile(); + + // TFile interface. + virtual Long64_t GetSize() const; + virtual void Seek(Long64_t offset, ERelativeTo pos = kBeg); + virtual Bool_t ReadBuffer(char *buf, Int_t len); + virtual Bool_t ReadBuffer(char *buf, Long64_t pos, Int_t len); + virtual Bool_t ReadBuffers(char *buf, Long64_t *pos, Int_t *len, Int_t nbuf); + virtual Bool_t ReadBufferAsync(Long64_t offs, Int_t len); + virtual Bool_t WriteBuffer(const char *buffer, Int_t bufferLength); + + // TDavixFile options + /// Enable or disable certificate authority check + void setCACheck(Bool_t check); + + /// Enable the grid mode + /// The grid Mode configure automatically all grid-CA path, VOMS authentication + /// and grid related extension for a grid analysis usage + void enableGridMode(); + + ClassDef(TDavixFile, 0) +}; + +#endif diff --git a/net/davix/inc/TDavixFileInternal.h b/net/davix/inc/TDavixFileInternal.h new file mode 100644 index 0000000000000..fc1241d35f584 --- /dev/null +++ b/net/davix/inc/TDavixFileInternal.h @@ -0,0 +1,134 @@ +// @(#)root/net:$Id$ +// Author: Adrien Devresse and Tigran Mkrtchyan + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TDavixFileInternal +#define ROOT_TDavixFileInternal + +#include "TUrl.h" +#include "TMutex.h" + +#include <vector> +#include <iterator> +#include <algorithm> +#include <errno.h> +#include <stdlib.h> +#include <unistd.h> +#include <fcntl.h> +#include <sys/stat.h> +#include <sstream> +#include <string> +#include <cstring> + +////////////////////////////////////////////////////////////////////////// +// // +// TDavixFileInternal // +// // +// // +// Support class, common to TDavixFile and TDavixSystem // +// // +// Authors: Adrien Devresse (CERN IT/SDC) // +// Fabrizio Furano (CERN IT/SDC) // +// // +// September 2013 // +// // +////////////////////////////////////////////////////////////////////////// + +namespace Davix { + class Context; + class RequestParams; + class DavPosix; +} +struct Davix_fd; + + +class TDavixFileInternal { + friend class TDavixFile; + friend class TDavixSystem; + +private: + TDavixFileInternal(const TUrl & mUrl, Option_t* mopt) : + positionLock(), + openLock(), + davixContext(getDavixInstance()), + davixParam(NULL), + davixPosix(NULL), + davixFd(NULL), + fUrl(mUrl), + opt(mopt), + oflags(0), + dirdVec() { } + + TDavixFileInternal(const char* url, Option_t* mopt) : + positionLock(), + openLock(), + davixContext(getDavixInstance()), + davixParam(NULL), + davixPosix(NULL), + davixFd(NULL), + fUrl(url), + opt(mopt), + oflags(0), + dirdVec() { } + + ~TDavixFileInternal(); + + Davix_fd * getDavixFileInstance() + { + // singleton init + if (davixFd == NULL) { + TLockGuard l(&(openLock)); + if (davixFd == NULL) { + davixFd = this->Open(); + } + } + return davixFd; + } + + Davix_fd * Open(); + + void Close(); + + void enableGridMode(); + + void setS3Auth(const std::string & key, const std::string & token); + + void parseConfig(); + + void parseParams(Option_t* option); + + void init(); + + bool isMyDird(void* fd); + + void addDird(void* fd); + + void removeDird(void* fd); + + TMutex positionLock; + TMutex openLock; + + // DAVIX + Davix::Context *davixContext; + Davix::RequestParams *davixParam; + Davix::DavPosix *davixPosix; + Davix_fd *davixFd; + TUrl fUrl; + Option_t* opt; + int oflags; + std::vector<void*> dirdVec; + +public: + Int_t DavixStat(const char *url, struct stat *st); + + static Davix::Context* getDavixInstance(); +}; + +#endif diff --git a/net/davix/inc/TDavixSystem.h b/net/davix/inc/TDavixSystem.h new file mode 100644 index 0000000000000..97f4cc46ce1b0 --- /dev/null +++ b/net/davix/inc/TDavixSystem.h @@ -0,0 +1,65 @@ +// @(#)root/net:$Id$ +// Author: Adrien Devresse and Fabrizio Furano + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TDavixSystem +#define ROOT_TDavixSystem + +////////////////////////////////////////////////////////////////////////// +// // +// TDavixSystem // +// // +// A TSystem specialization for HTTP and WebDAV // +// It supports HTTP and HTTPS in a number of dialects and options // +// e.g. S3 is one of them // +// Other caracteristics come from the full support of Davix, // +// e.g. full redirection support in any circumstance // +// // +// Authors: Adrien Devresse (CERN IT/SDC) // +// Fabrizio Furano (CERN IT/SDC) // +// // +// September 2013 // +// // +////////////////////////////////////////////////////////////////////////// + +#include "TUrl.h" +#include "TSystem.h" +#include "TMutex.h" + + +class TDavixFileInternal; +struct Davix_fd; + + +class TDavixSystem : public TSystem { +private: + TDavixFileInternal* d_ptr; + +public: + TDavixSystem(); + TDavixSystem(const char *url); + + virtual ~TDavixSystem(); + + virtual void FreeDirectory(void *dirp); + virtual const char *GetDirEntry(void *dirp); + virtual Bool_t ConsistentWith(const char *path, void *dirptr); + + virtual Int_t GetPathInfo(const char* path, FileStat_t &buf); + virtual Bool_t IsPathLocal(const char *path); + virtual Int_t Locate(const char* path, TString &endurl); + virtual Int_t MakeDirectory(const char* dir); + virtual void *OpenDirectory(const char* dir); + virtual int Unlink(const char *path); + + ClassDef(TDavixSystem, 0); +}; + +#endif diff --git a/net/davix/src/TDavixFile.cxx b/net/davix/src/TDavixFile.cxx new file mode 100644 index 0000000000000..ca56c297e651c --- /dev/null +++ b/net/davix/src/TDavixFile.cxx @@ -0,0 +1,687 @@ +// @(#)root/net:$Id$ +// Author: Adrien Devresse and Tigran Mkrtchyan + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////// +// // +// TDavixFile // +// // +// A TDavixFile is like a normal TFile except that it uses // +// libdavix to read/write remote files. // +// It supports HTTP and HTTPS in a number of dialects and options // +// e.g. S3 is one of them // +// Other caracteristics come from the full support of Davix, // +// e.g. full redirection support in any circumstance // +// // +// Authors: Adrien Devresse (CERN IT/SDC) // +// Tigran Mkrtchyan (DESY) // +// // +// Checks and ROOT5 porting: // +// Fabrizio Furano (CERN IT/SDC) // +// // +// September 2013 // +// // +////////////////////////////////////////////////////////////////////////// + + +#include "TDavixFile.h" +#include "TROOT.h" +#include "TSocket.h" +#include "Bytes.h" +#include "TError.h" +#include "TSystem.h" +#include "TEnv.h" +#include "TBase64.h" +#include "TVirtualPerfStats.h" +#include "TDavixFileInternal.h" +#include "TSocket.h" + +#include <errno.h> +#include <stdlib.h> +#include <unistd.h> +#include <fcntl.h> +#include <davix.hpp> +#include <sstream> +#include <string> +#include <cstring> + + +static const std::string VERSION = "0.0.1"; + +static const std::string gUserAgent = "ROOT/" + std::string(gROOT->GetVersion()) + +" TDavixFile/" + VERSION + " davix/" + Davix::version(); + +// The prefix that is used to find the variables in the gEnv +#define ENVPFX "Davix." + +ClassImp(TDavixFile) + +using namespace Davix; + +const char* grid_mode_opt = "grid_mode=yes"; +const char* ca_check_opt = "ca_check=no"; +const char* s3_seckey_opt = "s3seckey="; +const char* s3_acckey_opt = "s3acckey="; +const char* open_mode_read = "READ"; +const char* open_mode_create = "CREATE"; +const char* open_mode_new = "NEW"; +const char* open_mode_update = "UPDATE"; + +static TMutex createLock; +static Context* davix_context_s = NULL; + + +//____________________________________________________________________________ +bool isno(const char *str) +{ + if (!str) return false; + + if (!strcmp(str, "n") || !strcmp(str, "no") || !strcmp(str, "0") || !strcmp(str, "false")) return true; + + return false; +} + +//____________________________________________________________________________ +int configure_open_flag(const std::string &str, int old_flag) +{ + if (strcasecmp(str.c_str(), open_mode_read) == 0) + old_flag |= O_RDONLY; + if ((strcasecmp(str.c_str(), open_mode_create) == 0) + || (strcasecmp(str.c_str(), open_mode_new) == 0)) { + old_flag |= (O_CREAT | O_WRONLY | O_TRUNC); + } + if ((strcasecmp(str.c_str(), open_mode_update) == 0)) { + old_flag |= (O_RDWR); + } + return old_flag; +} + +//____________________________________________________________________________ +static void ConfigureDavixLogLevel() +{ + Int_t log_level = (gEnv) ? gEnv->GetValue("Davix.Debug", 0) : 0; + + switch (log_level) { + case 0: + davix_set_log_level(0); + break; + case 1: + davix_set_log_level(DAVIX_LOG_WARNING); + break; + case 2: + davix_set_log_level(DAVIX_LOG_VERBOSE); + break; + case 3: + davix_set_log_level(DAVIX_LOG_DEBUG); + break; + default: + davix_set_log_level(DAVIX_LOG_ALL); + break; + } +} + + +/////////////////////////////////////////////////////////////////// +// Authn implementation, Locate and get VOMS cred if exist + +//____________________________________________________________________________ +static void TDavixFile_http_get_ucert(std::string &ucert, std::string &ukey) +{ + char default_proxy[64]; + const char *genvvar = 0, *genvvar1 = 0; + // The gEnv has higher priority, let's look for a proxy cert + genvvar = gEnv->GetValue("Davix.GSI.UserProxy", (const char *) NULL); + if (genvvar) { + ucert = ukey = genvvar; + if (gDebug > 0) + Info("TDavixFile_http_get_ucert", "Found proxy in gEnv"); + return; + } + + // Try explicit environment for proxy + if (getenv("X509_USER_PROXY")) { + if (gDebug > 0) + Info("TDavixFile_http_get_ucert", "Found proxy in X509_USER_PROXY"); + ucert = ukey = getenv("X509_USER_PROXY"); + return; + } + + // Try with default location + snprintf(default_proxy, sizeof(default_proxy), "/tmp/x509up_u%d", + geteuid()); + + if (access(default_proxy, R_OK) == 0) { + if (gDebug > 0) + Info("TDavixFile_http_get_ucert", "Found proxy in /tmp"); + ucert = ukey = default_proxy; + return; + } + + // It seems we got no proxy, let's try to gather the keys + genvvar = gEnv->GetValue("Davix.GSI.UserCert", (const char *) NULL); + genvvar1 = gEnv->GetValue("Davix.GSI.UserKey", (const char *) NULL); + if (genvvar || genvvar1) { + if (gDebug > 0) + Info("TDavixFile_http_get_ucert", "Found cert and key in gEnv"); + + ucert = genvvar; + ukey = genvvar1; + return; + } + + // try with X509_* environment + if (getenv("X509_USER_CERT")) + ucert = getenv("X509_USER_CERT"); + if (getenv("X509_USER_KEY")) + ukey = getenv("X509_USER_KEY"); + + if ((ucert.size() > 0) || (ukey.size() > 0)) { + if (gDebug > 0) + Info("TDavixFile_http_get_ucert", "Found cert and key in gEnv"); + } + return; +} + +//____________________________________________________________________________ +static int TDavixFile_http_authn_cert_X509(void *userdata, const Davix::SessionInfo &info, + Davix::X509Credential *cert, Davix::DavixError **err) +{ + (void) userdata; // keep quiete compilation warnings + (void) info; + std::string ucert, ukey; + TDavixFile_http_get_ucert(ucert, ukey); + + if (ucert.empty() || ukey.empty()) { + Davix::DavixError::setupError(err, "TDavixFile", + Davix::StatusCode::AuthentificationError, + "Could not set the user's proxy or certificate"); + return -1; + } + return cert->loadFromFilePEM(ukey, ucert, "", err); +} + +///////////////////////////////////////////////////////////////////////////////////////////// + + +//____________________________________________________________________________ +TDavixFileInternal::~TDavixFileInternal() +{ + delete davixPosix; + delete davixParam; +} + +//____________________________________________________________________________ +Context *TDavixFileInternal::getDavixInstance() +{ + if (davix_context_s == NULL) { + TLockGuard guard(&createLock); + if (davix_context_s == NULL) { + davix_context_s = new Context(); + } + } + return davix_context_s; +} + +//____________________________________________________________________________ +Davix_fd *TDavixFileInternal::Open() +{ + DavixError *davixErr = NULL; + Davix_fd *fd = davixPosix->open(davixParam, fUrl.GetUrl(), oflags, &davixErr); + if (fd == NULL) { + Error("DavixOpen", "failed to open file with davix: %s (%d)", + davixErr->getErrMsg().c_str(), davixErr->getStatus()); + DavixError::clearError(&davixErr); + } else { + // setup ROOT style read + davixPosix->fadvise(fd, 0, 300, Davix::AdviseRandom); + } + + return fd; +} + +//____________________________________________________________________________ +void TDavixFileInternal::Close() +{ + DavixError *davixErr = NULL; + if (davixFd != NULL && davixPosix->close(davixFd, &davixErr)) { + Error("DavixClose", "failed to close file with davix: %s (%d)", + davixErr->getErrMsg().c_str(), davixErr->getStatus()); + DavixError::clearError(&davixErr); + } +} + +//____________________________________________________________________________ +void TDavixFileInternal::enableGridMode() +{ + const char *env_var = NULL; + + if (gDebug > 1) + Info("enableGridMode", " grid mode enabled !"); + + env_var = gEnv->GetValue("Davix.GSI.CAdir", (const char *) NULL); + if (!env_var) { + env_var = (((char *) getenv("X509_CERT_DIR")) ? env_var : "/etc/grid-security/certificates/"); + davixParam->addCertificateAuthorityPath(env_var); + if (gDebug > 0) + Info("enableGridMode", "Setting CAdir to %s", env_var); + } + +} + +//____________________________________________________________________________ +void TDavixFileInternal::setS3Auth(const std::string &key, const std::string &token) +{ + if (gDebug > 1) + Info("setS3Auth", " Aws S3 tokens configured"); + davixParam->setAwsAuthorizationKeys(key, token); + davixParam->setProtocol(RequestProtocol::AwsS3); +} + +//____________________________________________________________________________ +void TDavixFileInternal::parseConfig() +{ + const char *env_var = NULL, *env_var2 = NULL; + // default opts + davixParam->setTransparentRedirectionSupport(true); + davixParam->setClientCertCallbackX509(&TDavixFile_http_authn_cert_X509, NULL); + + // setup CADIR + env_var = gEnv->GetValue("Davix.GSI.CAdir", (const char *) NULL); + if (env_var) { + davixParam->addCertificateAuthorityPath(env_var); + if (gDebug > 0) + Info("parseConfig", "Add Setting CA dir: %s", env_var); + } + // CA Check + bool ca_check_local = !isno(gEnv->GetValue("Davix.GSI.CACheck", (const char *)"y")); + davixParam->setSSLCAcheck(ca_check_local); + if (gDebug > 0) + Info("parseConfig", "Setting CAcheck to %s", ((ca_check_local) ? ("true") : ("false"))); + + // S3 Auth + if (((env_var = gEnv->GetValue("Davix.S3.SecretKey", getenv("S3_SECRET_KEY"))) != NULL) + && ((env_var2 = gEnv->GetValue("Davix.S3.AccessKey", getenv("S3_ACCESS_KEY"))) != NULL)) { + Info("parseConfig", "Setting S3 SecretKey and AccessKey. Access Key : %s ", env_var2); + davixParam->setAwsAuthorizationKeys(env_var, env_var2); + } + + env_var = gEnv->GetValue("Davix.GSI.GridMode", (const char *) NULL); + if (env_var && !isno(env_var)) + enableGridMode(); +} + +//____________________________________________________________________________ +void TDavixFileInternal::parseParams(Option_t *option) +{ + // intput params + std::stringstream ss(option); + std::string item; + std::vector<std::string> parsed_options; + // parameters + std::string s3seckey, s3acckey; + + while (std::getline(ss, item, ' ')) { + parsed_options.push_back(item); + } + + for (std::vector<std::string>::iterator it = parsed_options.begin(); it < parsed_options.end(); ++it) { + // grid mode option + if ((strcasecmp(it->c_str(), grid_mode_opt)) == 0) { + enableGridMode(); + } + // ca check option + if ((strcasecmp(it->c_str(), ca_check_opt)) == 0) { + davixParam->setSSLCAcheck(false); + } + // s3 sec key + if (strncasecmp(it->c_str(), s3_seckey_opt, strlen(s3_seckey_opt)) == 0) { + s3seckey = std::string(it->c_str() + strlen(s3_seckey_opt)); + } + // s3 access key + if (strncasecmp(it->c_str(), s3_acckey_opt, strlen(s3_acckey_opt)) == 0) { + s3acckey = std::string(it->c_str() + strlen(s3_acckey_opt)); + } + // open mods + oflags = configure_open_flag(*it, oflags); + } + + if (s3seckey.size() > 0) { + setS3Auth(s3seckey, s3acckey); + } + + if (oflags == 0) // default open mode + oflags = O_RDONLY; +} + +//____________________________________________________________________________ +void TDavixFileInternal::init() +{ + davixPosix = new DavPosix(davixContext); + davixParam = new RequestParams(); + davixParam->setUserAgent(gUserAgent); + ConfigureDavixLogLevel(); + parseConfig(); + parseParams(opt); +} + +//____________________________________________________________________________ +Int_t TDavixFileInternal::DavixStat(const char *url, struct stat *st) +{ + DavixError *davixErr = NULL; + + if (davixPosix->stat(davixParam, url, st, &davixErr) < 0) { + + Error("DavixStat", "failed to stat the file with davix: %s (%d)", + davixErr->getErrMsg().c_str(), davixErr->getStatus()); + DavixError::clearError(&davixErr); + return 0; + } + return 1; +} + +///////////////////////////////////////////////////////////////////////////////////////////// + +//______________________________________________________________________________ +TDavixFile::TDavixFile(const char *url, Option_t *opt, const char *ftitle, Int_t compress) : TFile(url, "WEB"), + d_ptr(new TDavixFileInternal(fUrl, opt)) +{ + (void) ftitle; + (void) compress; + Init(kFALSE); +} + +//______________________________________________________________________________ +TDavixFile::~TDavixFile() +{ + d_ptr->Close(); + delete d_ptr; +} + +//______________________________________________________________________________ +void TDavixFile::Init(Bool_t init) +{ + (void) init; + d_ptr->init(); + TFile::Init(kFALSE); + fOffset = 0; + fD = -2; // so TFile::IsOpen() will return true when in TFile::~TFi */ +} + +//______________________________________________________________________________ +void TDavixFile::Seek(Long64_t offset, ERelativeTo pos) +{ + // Set position from where to start reading. + + TLockGuard guard(&(d_ptr->positionLock)); + switch (pos) { + case kBeg: + fOffset = offset + fArchiveOffset; + break; + case kCur: + fOffset += offset; + break; + case kEnd: + // this option is not used currently in the ROOT code + if (fArchiveOffset) + Error("Seek", "seeking from end in archive is not (yet) supported"); + fOffset = fEND - offset; // is fEND really EOF or logical EOF? + break; + } + + if (gDebug > 1) + Info("Seek", " move cursor to %lld" + , fOffset); +} + +//______________________________________________________________________________ +Bool_t TDavixFile::ReadBuffer(char *buf, Int_t len) +{ + // Read specified byte range from remote file via HTTP. + // Returns kTRUE in case of error. + TLockGuard guard(&(d_ptr->positionLock)); + Davix_fd *fd; + if ((fd = d_ptr->getDavixFileInstance()) == NULL) + return kTRUE; + Long64_t ret = DavixReadBuffer(fd, buf, len); + if (ret < 0) + return kTRUE; + + if (gDebug > 1) + Info("ReadBuffer", "%lld bytes of data read sequentially" + " (%d requested)", ret, len); + + return kFALSE; +} + +//______________________________________________________________________________ +Bool_t TDavixFile::ReadBuffer(char *buf, Long64_t pos, Int_t len) +{ + + Davix_fd *fd; + if ((fd = d_ptr->getDavixFileInstance()) == NULL) + return kTRUE; + + Long64_t ret = DavixPReadBuffer(fd, buf, pos, len); + if (ret < 0) + return kTRUE; + + + if (gDebug > 1) + Info("ReadBuffer", "%lld bytes of data read from offset" + " %lld (%d requested)", ret, pos, len); + return kFALSE; +} + +//____________________________________________________________________________ +Bool_t TDavixFile::ReadBufferAsync(Long64_t offs, Int_t len) +{ + + Davix_fd *fd; + if ((fd = d_ptr->getDavixFileInstance()) == NULL) + return kFALSE; + + d_ptr->davixPosix->fadvise(fd, static_cast<dav_off_t>(offs), static_cast<dav_size_t>(len), Davix::AdviseRandom); + + if (gDebug > 1) + Info("ReadBufferAsync", "%d bytes of data prefected from offset" + " %lld ", len, offs); + return kFALSE; +} + +//______________________________________________________________________________ +Bool_t TDavixFile::ReadBuffers(char *buf, Long64_t *pos, Int_t *len, Int_t nbuf) +{ + Davix_fd *fd; + if ((fd = d_ptr->getDavixFileInstance()) == NULL) + return kTRUE; + + Long64_t ret = DavixReadBuffers(fd, buf, pos, len, nbuf); + if (ret < 0) + return kTRUE; + + if (gDebug > 1) + Info("ReadBuffers", "%lld bytes of data read from a list of %d buffers", + ret, nbuf); + + return kFALSE; +} + +//_____________________________________________________________________________ +Bool_t TDavixFile::WriteBuffer(const char *buf, Int_t len) +{ + + Davix_fd *fd; + if ((fd = d_ptr->getDavixFileInstance()) == NULL) + return kTRUE; + + Long64_t ret = DavixWriteBuffer(fd, buf, len); + if (ret < 0) + return kTRUE; + + if (gDebug > 1) + Info("WriteBuffer", "%lld bytes of data write" + " %d requested", ret, len); + return kFALSE; +} + +//____________________________________________________________________________ +void TDavixFile::setCACheck(Bool_t check) +{ + d_ptr->davixParam->setSSLCAcheck((bool)check); +} + +//____________________________________________________________________________ +void TDavixFile::enableGridMode() +{ + d_ptr->enableGridMode(); +} + +//____________________________________________________________________________ +bool TDavixFileInternal::isMyDird(void *fd) +{ + TLockGuard l(&(openLock)); + std::vector<void *>::iterator f = std::find(dirdVec.begin(), dirdVec.end(), fd); + return (f != dirdVec.end()); +} + +//____________________________________________________________________________ +void TDavixFileInternal::addDird(void *fd) +{ + TLockGuard l(&(openLock)); + dirdVec.push_back(fd); +} + +//____________________________________________________________________________ +void TDavixFileInternal::removeDird(void *fd) +{ + TLockGuard l(&(openLock)); + std::vector<void *>::iterator f = std::find(dirdVec.begin(), dirdVec.end(), fd); + if (f != dirdVec.end()) + dirdVec.erase(f); +} + + +//______________________________________________________________________________ +Long64_t TDavixFile::GetSize() const +{ + struct stat st; + Int_t ret = d_ptr->DavixStat(fUrl.GetUrl(), &st); + if (ret) { + if (gDebug > 1) + Info("GetSize", "file size requested: %ld", + st.st_size); + return st.st_size; + } + return -1; +} + +//______________________________________________________________________________ +Double_t TDavixFile::eventStart() +{ + if (gPerfStats) + return TTimeStamp(); + return 0; +} + +//______________________________________________________________________________ +void TDavixFile::eventStop(Double_t t_start, Long64_t len) +{ + // set TFile state info + fBytesRead += len; + fReadCalls += 1; + + if (gPerfStats) + gPerfStats->FileReadEvent(this, (Int_t) len, t_start); +} + +//____________________________________________________________________________ +Long64_t TDavixFile::DavixReadBuffer(Davix_fd *fd, char *buf, Int_t len) +{ + DavixError *davixErr = NULL; + Double_t start_time = eventStart(); + + Long64_t ret = d_ptr->davixPosix->pread(fd, buf, len, fOffset, &davixErr); + if (ret < 0) { + Error("DavixReadBuffer", "failed to read data with davix: %s (%d)", + davixErr->getErrMsg().c_str(), davixErr->getStatus()); + DavixError::clearError(&davixErr); + } else { + fOffset += ret; + eventStop(start_time, ret); + } + + return ret; +} + +//____________________________________________________________________________ +Long64_t TDavixFile::DavixWriteBuffer(Davix_fd *fd, const char *buf, Int_t len) +{ + DavixError *davixErr = NULL; + Double_t start_time = eventStart(); + + Long64_t ret = d_ptr->davixPosix->pwrite(fd, buf, len, fOffset, &davixErr); + if (ret < 0) { + Error("DavixWriteBuffer", "failed to write data with davix: %s (%d)", + davixErr->getErrMsg().c_str(), davixErr->getStatus()); + DavixError::clearError(&davixErr); + } else { + fOffset += ret; + eventStop(start_time, ret); + } + + return ret; +} + +//____________________________________________________________________________ +Long64_t TDavixFile::DavixPReadBuffer(Davix_fd *fd, char *buf, Long64_t pos, Int_t len) +{ + DavixError *davixErr = NULL; + Double_t start_time = eventStart(); + + Long64_t ret = d_ptr->davixPosix->pread(fd, buf, len, pos, &davixErr); + if (ret < 0) { + Error("DavixPReadBuffer", "failed to read data with davix: %s (%d)", + davixErr->getErrMsg().c_str(), davixErr->getStatus()); + DavixError::clearError(&davixErr); + } else { + eventStop(start_time, ret); + } + + return ret; +} + +//____________________________________________________________________________ +Long64_t TDavixFile::DavixReadBuffers(Davix_fd *fd, char *buf, Long64_t *pos, Int_t *len, Int_t nbuf) +{ + DavixError *davixErr = NULL; + Double_t start_time = eventStart(); + DavIOVecInput in[nbuf]; + DavIOVecOuput out[nbuf]; + + int lastPos = 0; + for (Int_t i = 0; i < nbuf; ++i) { + in[i].diov_buffer = &buf[lastPos]; + in[i].diov_offset = pos[i]; + in[i].diov_size = len[i]; + lastPos += len[i]; + } + + Long64_t ret = d_ptr->davixPosix->preadVec(fd, in, out, nbuf, &davixErr); + if (ret < 0) { + Error("DavixReadBuffers", "failed to read data with davix: %s (%d)", + davixErr->getErrMsg().c_str(), davixErr->getStatus()); + DavixError::clearError(&davixErr); + } else { + eventStop(start_time, ret); + } + + return ret; +} + diff --git a/net/davix/src/TDavixSystem.cxx b/net/davix/src/TDavixSystem.cxx new file mode 100644 index 0000000000000..8b38370faabef --- /dev/null +++ b/net/davix/src/TDavixSystem.cxx @@ -0,0 +1,209 @@ +// @(#)root/net:$Id$ +// Author: Adrien Devresse and Fabrizio Furano + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////// +// // +// TDavixSystem // +// // +// A TSystem specialization for HTTP and WebDAV // +// It supports HTTP and HTTPS in a number of dialects and options // +// e.g. S3 is one of them // +// Other caracteristics come from the full support of Davix, // +// e.g. full redirection support in any circumstance // +// // +// Authors: Adrien Devresse (CERN IT/SDC) // +// Fabrizio Furano (CERN IT/SDC) // +// // +// September 2013 // +// // +////////////////////////////////////////////////////////////////////////// + +#include "TDavixSystem.h" +#include "TROOT.h" +#include "TSocket.h" +#include "Bytes.h" +#include "TError.h" +#include "TSystem.h" +#include "TEnv.h" +#include "TBase64.h" +#include "TVirtualPerfStats.h" +#include "TDavixFileInternal.h" +#include "TSocket.h" + +#include <errno.h> +#include <stdlib.h> +#include <unistd.h> +#include <fcntl.h> +#include <davix.hpp> +#include <sstream> +#include <string> +#include <cstring> + + +extern const std::string VERSION; +extern const std::string gUserAgent; + +// The prefix that is used to find the variables in the gEnv +#define ENVPFX "Davix." + +ClassImp(TDavixSystem) + +using namespace Davix; + +extern const char* grid_mode_opt; +extern const char* ca_check_opt; +extern const char* s3_seckey_opt; +extern const char* s3_acckey_opt; + +//____________________________________________________________________________ +TDavixSystem::TDavixSystem(const char *url) : + TSystem(url), + d_ptr(new TDavixFileInternal(url, "WEB")) +{ + d_ptr->init(); + SetTitle("WebDAV system administration"); +} + +//____________________________________________________________________________ +TDavixSystem::TDavixSystem() : + TSystem(), + d_ptr(new TDavixFileInternal("", "WEB")) +{ + d_ptr->init(); + SetTitle("WebDAV system administration"); +} + +//____________________________________________________________________________ +TDavixSystem::~TDavixSystem() +{ + SafeDelete(d_ptr); +} + +//____________________________________________________________________________ +void TDavixSystem::FreeDirectory(void *dirp) +{ + d_ptr->davixPosix->closedir(static_cast<DAVIX_DIR *>(dirp), NULL); + d_ptr->removeDird(dirp); +} + +//____________________________________________________________________________ +const char *TDavixSystem::GetDirEntry(void *dirp) +{ + struct dirent *dir; + DavixError *davixErr = NULL; + if (((dir = d_ptr->davixPosix->readdir(static_cast<DAVIX_DIR *>(dirp), &davixErr)) == NULL) + && (davixErr != NULL)) { + Error("DavixReaddir", "failed to readdir the directory: %s (%d)", + davixErr->getErrMsg().c_str(), davixErr->getStatus()); + DavixError::clearError(&davixErr); + } + return (dir) ? (dir->d_name) : NULL; +} + +//____________________________________________________________________________ +void *TDavixSystem::OpenDirectory(const char *dir) +{ + DavixError *davixErr = NULL; + DAVIX_DIR *d; + if ((d = d_ptr->davixPosix->opendir(d_ptr->davixParam, dir, &davixErr)) == NULL) { + Error("DavixOpendir", "failed to opendir the directory: %s (%d)", + davixErr->getErrMsg().c_str(), davixErr->getStatus()); + DavixError::clearError(&davixErr); + } else { + d_ptr->addDird(d); + } + return d; +} + +//____________________________________________________________________________ +Bool_t TDavixSystem::ConsistentWith(const char * /*path*/, void *dirptr) +{ + return (Bool_t) d_ptr->isMyDird(dirptr); +} + +//____________________________________________________________________________ +Int_t TDavixSystem::GetPathInfo(const char *path, FileStat_t &buf) +{ + struct stat st; + + if (!d_ptr->DavixStat(path, &st)) return 1; + buf.fDev = 0; + buf.fIno = 0; + buf.fMode = st.st_mode; // protection (combination of EFileModeMask bits) + + buf.fUid = st.st_uid; // user id of owner + buf.fGid = st.st_gid; // group id of owner + buf.fSize = st.st_size; // total size in bytes + buf.fMtime = st.st_mtime; // modification date + buf.fIsLink = kFALSE; // symbolic link + buf.fUrl = path; // end point url of file + + return 0; +} + +//____________________________________________________________________________ +Bool_t TDavixSystem::IsPathLocal(const char *path) +{ + (void) path; + return kFALSE; +} + +//____________________________________________________________________________ +Int_t TDavixSystem::Locate(const char *path, TString &endurl) +{ + DavixError *davixErr = NULL; + ssize_t ret; + ReplicaVec vecRep; + DavFile f(*d_ptr->davixContext, Uri(path)); + if ((ret = f.getAllReplicas(d_ptr->davixParam, + vecRep, + &davixErr)) < 0) { + Error("DavixLocate", "failed to Locate file: %s (%d)", + davixErr->getErrMsg().c_str(), davixErr->getStatus()); + DavixError::clearError(&davixErr); + return 1; + } + if (vecRep.size() > 0) { + endurl = vecRep[0].getString().c_str(); + } else { + endurl = path; + } + if (gDebug > 0) + Info("DavixLocate", "Davix Locate %s to %s", path, endurl.Data()); + + return 0; +} + +//____________________________________________________________________________ +Int_t TDavixSystem::MakeDirectory(const char *dir) +{ + DavixError *davixErr = NULL; + int ret; + if ((ret = d_ptr->davixPosix->mkdir(d_ptr->davixParam, dir, 0755, &davixErr)) < 0) { + Error("DavixMkdir", "failed to create the directory: %s (%d)", + davixErr->getErrMsg().c_str(), davixErr->getStatus()); + DavixError::clearError(&davixErr); + } + return ret; +} + +//____________________________________________________________________________ +int TDavixSystem::Unlink(const char *path) +{ + DavixError *davixErr = NULL; + int ret; + if ((ret = d_ptr->davixPosix->unlink(d_ptr->davixParam, path, &davixErr)) < 0) { + Error("DavixUnlink", "failed to unlink the file: %s (%d)", + davixErr->getErrMsg().c_str(), davixErr->getStatus()); + DavixError::clearError(&davixErr); + } + return ret; +} diff --git a/net/doc/v534/index.html b/net/doc/v534/index.html index 467aa2de33ad3..dc042cf4ff9b2 100644 --- a/net/doc/v534/index.html +++ b/net/doc/v534/index.html @@ -2,3 +2,70 @@ <hr/> <a name="net"></a> <h3>Networking Libraries</h3> +<p> +A new class TS3WebFile has been introduced. The new class TS3WebFile is an +extension of TWebFile and belongs to the net module. +The name TS3WebFile reflects better the fact that this solution +is intended to be generic to several S3 servers and not limited to Amazon's, +in addition to the fact that it actually extends the capabilities of TWebFile. +</p> +<p> +Compared to the current support of S3 in ROOT (basically the class TAS3File), +the modifications include the improvements below: +</p> +<ul> +<li> + add support for using HTTPS : you can use different schemas for specifying + the underlying transport protocol to use "s3:", "s3http:", "s3https:" + ["s3" uses HTTPS]. The current schema, namely "as3:", is supported for + backwards compatibility. +</li> +<li> + extend support for other S3 service providers that do not offer the + virtual hosting functionality (currently only Amazon offers this). +</li> +<li> + support the possibility of specifying user credentials on a per-file + basis or for all S3 files via environment variables. +</li> +<li> + honor the "NOPROXY" option when specified in the constructor. +</li> +<li> + exploit the capability of the S3 file server to provide partial + content responses to multi-range HTTP requests. +</li> +</ul> +<p> +Here are some examples of usages from the end user perspective: +</p> +<pre> + TFile* f = TFile::Open("s3://s3.amazonaws.com/mybucket/path/to/my/file", "AUTH=<accessKey>:<secretKey> NOPROXY") + TFile* f = TFile::Open("s3://s3.amazonaws.com/mybucket/path/to/my/file") // Uses environmental variables for retrieving credentials +</pre> +<p> +Limitations: +</p> +<ul> +<li> + we cannot efficiently detect that a S3 server is able to respond to + multi-range HTTP GET requests. Some servers, such as Amazon's, respond + to such kind of requests with the whole file contents. Other servers, + such as Huawei's, respond with the exact partial content requested. + Therefore, I added the possibility of configuring the behavior via the + ROOT configuration file: the identity of the servers known to correctly + support multi-range requests is configurable. If the server is known to + support this feature, ROOT will send multi-range requests, otherwise it + will issue multiple single-range GET requests, which is also the default + behavior. +</li> +<li> + currently the virtual host syntax: + "s3://mybucket.s3.amazonaws.com/path/to/my/file" + is not supported but can be added if this is considered useful. +</li> +</ul> +<p> +The TAS3File class will be removed and should not have been used directly by +users anyway as it was only accessed via the plugin manager in TFile::Open(). +</p> diff --git a/net/globusauth/CMakeLists.txt b/net/globusauth/CMakeLists.txt new file mode 100644 index 0000000000000..9999378c09ccf --- /dev/null +++ b/net/globusauth/CMakeLists.txt @@ -0,0 +1,11 @@ +############################################################################ +# CMakeLists.txt file for building ROOT net/globusauth package +############################################################################ + +ROOT_USE_PACKAGE(net/net) +ROOT_USE_PACKAGE(net/auth) + +include_directories(${GLOBUS_INCLUDE_DIRS}) + +ROOT_LINKER_LIBRARY(GlobusAuth *.cxx LIBRARIES Core ${GLOBUS_LIBRARIES} ${OPENSSL_LIBRARIES} DEPENDENCIES RootAuth Net) +ROOT_INSTALL_HEADERS() diff --git a/net/krb5auth/CMakeLists.txt b/net/krb5auth/CMakeLists.txt index 4022b3a24b946..cae32dea50a48 100644 --- a/net/krb5auth/CMakeLists.txt +++ b/net/krb5auth/CMakeLists.txt @@ -7,7 +7,7 @@ ROOT_USE_PACKAGE(core) ROOT_USE_PACKAGE(net/net) ROOT_USE_PACKAGE(net/auth) -include_directories(${KRB5_INCLUDE_DIR}) +include_directories(${KRB5_INCLUDE_DIRS}) set_directory_properties(PROPERTIES COMPILE_DEFINITIONS R__KRB5INIT="${KRB5_INIT}") diff --git a/net/krb5auth/Module.mk b/net/krb5auth/Module.mk index 6f60b7f78327b..53b3e19b837b5 100644 --- a/net/krb5auth/Module.mk +++ b/net/krb5auth/Module.mk @@ -77,3 +77,6 @@ distclean:: distclean-$(MODNAME) $(KRB5AUTHDO): CXXFLAGS += $(KRB5INCDIR:%=-I%) $(KRB5AUTHO): CXXFLAGS += $(EXTRA_AUTHFLAGS) -DR__KRB5INIT="\"$(KRB5INIT)\"" $(KRB5INCDIR:%=-I%) $(SSLINCDIR:%=-I%) +ifeq ($(MACOSX_KRB5_DEPRECATED),yes) +$(KRB5AUTHO) $(KRB5AUTHDO): CXXFLAGS += -Wno-deprecated-declarations +endif diff --git a/net/krb5auth/src/Krb5Auth.cxx b/net/krb5auth/src/Krb5Auth.cxx index 17e8496b9024b..b641aed8aba68 100644 --- a/net/krb5auth/src/Krb5Auth.cxx +++ b/net/krb5auth/src/Krb5Auth.cxx @@ -485,7 +485,7 @@ Int_t Krb5Authenticate(TAuthenticate *auth, TString &user, TString &det, if (gDebug > 1) Info("Krb5Authenticate", - "Sending kerberos authentification to %s", + "Sending kerberos authentication to %s", serv_host.Data()); retval = krb5_sendauth(context, &auth_context, (krb5_pointer)&sockd, diff --git a/net/krb5auth/src/TKSocket.cxx b/net/krb5auth/src/TKSocket.cxx index 07504f98681e8..2a2f081c242da 100644 --- a/net/krb5auth/src/TKSocket.cxx +++ b/net/krb5auth/src/TKSocket.cxx @@ -5,6 +5,9 @@ #include <errno.h> #include <sys/types.h> #include <netinet/in.h> +#ifndef WIN32 +# include <unistd.h> +#endif #include "TKSocket.h" #include "TSocket.h" diff --git a/net/ldap/CMakeLists.txt b/net/ldap/CMakeLists.txt new file mode 100644 index 0000000000000..bc33032e0b80a --- /dev/null +++ b/net/ldap/CMakeLists.txt @@ -0,0 +1,12 @@ +############################################################################ +# CMakeLists.txt file for building ROOT net/ldap package +############################################################################ + +ROOT_USE_PACKAGE(net/net) +include_directories(${LDAP_INCLUDE_DIRS}) +add_definitions(-DLDAP_DEPRECATED) + +ROOT_GENERATE_DICTIONARY(G__LDAP *.h LINKDEF LinkDef.h) +ROOT_GENERATE_ROOTMAP(RLDAP LINKDEF LinkDef.h DEPENDENCIES Net RIO) +ROOT_LINKER_LIBRARY(RLDAP *.cxx G__LDAP.cxx LIBRARIES Core ${LDAP_LIBRARIES} DEPENDENCIES Net) +ROOT_INSTALL_HEADERS() diff --git a/net/monalisa/src/TMonaLisaWriter.cxx b/net/monalisa/src/TMonaLisaWriter.cxx index 944a0056c5dfc..ff0c3809fff26 100644 --- a/net/monalisa/src/TMonaLisaWriter.cxx +++ b/net/monalisa/src/TMonaLisaWriter.cxx @@ -204,7 +204,7 @@ void TMonaLisaWriter::Init(const char *monserver, const char *montag, const char // case of process monitoring it can be just an identifier to classify // the type of jobs e.g. "PROOF_PROCESSING". // If monid is not specified, TMonaLisaWriter tries to set it in this order - // from environement variables: + // from environment variables: // - PROOF_JOB_ID // - GRID_JOB_ID // - LCG_JOB_ID diff --git a/net/net/CMakeLists.txt b/net/net/CMakeLists.txt index 37a863f65554d..4ffa1cc4a0da1 100644 --- a/net/net/CMakeLists.txt +++ b/net/net/CMakeLists.txt @@ -18,13 +18,11 @@ else() add_definitions(-DR__SSL) endif() -if(NOT ssl AND NOT CRYPTLIBS) - list(REMOVE_ITEM headers TAS3File.h) - list(REMOVE_ITEM headers TGSFile.h) - list(REMOVE_ITEM headers THTTPMessage.h) - list(REMOVE_ITEM sources TAS3File.cxx) - list(REMOVE_ITEM sources TGSFile.cxx) - list(REMOVE_ITEM sources THTTPMessage.cxx) +if(NOT ssl OR NOT CRYPTLIBS) + list(REMOVE_ITEM headers TS3HTTPRequest.h) + list(REMOVE_ITEM headers TS3WebFile.h) + list(REMOVE_ITEM sources TS3HTTPRequest.cxx) + list(REMOVE_ITEM sources TS3WebFile.cxx) add_definitions(-DR__NO_CRYPTO) endif() diff --git a/net/net/Module.mk b/net/net/Module.mk index 000e650b5bffd..960066dbddba4 100644 --- a/net/net/Module.mk +++ b/net/net/Module.mk @@ -22,14 +22,15 @@ NETH := $(filter-out $(MODDIRI)/LinkDef%,$(wildcard $(MODDIRI)/*.h)) NETS := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx)) ifeq ($(CRYPTOLIB),) NETNOCRYPTO := -DR__NO_CRYPTO -NETH := $(filter-out $(MODDIRI)/TAS3File.h,$(NETH)) -NETH := $(filter-out $(MODDIRI)/TGSFile.h,$(NETH)) -NETH := $(filter-out $(MODDIRI)/THTTPMessage.h,$(NETH)) -NETS := $(filter-out $(MODDIRS)/TAS3File.cxx,$(NETS)) -NETS := $(filter-out $(MODDIRS)/TGSFile.cxx,$(NETS)) -NETS := $(filter-out $(MODDIRS)/THTTPMessage.cxx,$(NETS)) +NETH := $(filter-out $(MODDIRI)/TS3WebFile.h,$(NETH)) +NETH := $(filter-out $(MODDIRI)/TS3HTTPRequest.h,$(NETH)) +NETS := $(filter-out $(MODDIRS)/TS3WebFile.cxx,$(NETS)) +NETS := $(filter-out $(MODDIRS)/TS3HTTPRequest.cxx,$(NETS)) else NETNOCRYPTO := +ifeq ($(ARCH),win32gcc) +CRYPTOLIB += -lz +endif endif ifeq ($(SSLLIB),) @@ -92,5 +93,5 @@ ifeq ($(MACOSX_SSL_DEPRECATED),yes) $(call stripsrc,$(NETDIRS)/TSSLSocket.o): CXXFLAGS += -Wno-deprecated-declarations endif $(call stripsrc,$(NETDIRS)/TSSLSocket.o): CXXFLAGS += $(SSLINCDIR:%=-I%) -$(call stripsrc,$(NETDIRS)/THTTPMessage.o): CXXFLAGS += $(SSLINCDIR:%=-I%) +$(call stripsrc,$(NETDIRS)/TS3HTTPRequest.o): CXXFLAGS += $(SSLINCDIR:%=-I%) $(call stripsrc,$(NETDIRS)/TWebFile.o): CXXFLAGS += $(NETSSL) diff --git a/net/net/inc/LinkDef.h b/net/net/inc/LinkDef.h index 1f70b90bdfd78..9e10fe1e53c44 100644 --- a/net/net/inc/LinkDef.h +++ b/net/net/inc/LinkDef.h @@ -53,9 +53,8 @@ #pragma link C++ class TApplicationServer; #pragma link C++ class TUDPSocket; #ifndef R__NO_CRYPTO -#pragma link C++ class THTTPMessage+; -#pragma link C++ class TAS3File+; -#pragma link C++ class TGSFile+; +#pragma link C++ class TS3HTTPRequest+; +#pragma link C++ class TS3WebFile+; #endif #ifdef R__SSL #pragma link C++ class TSSLSocket; diff --git a/net/net/inc/TAS3File.h b/net/net/inc/TAS3File.h deleted file mode 100644 index 2b1ae33febbdf..0000000000000 --- a/net/net/inc/TAS3File.h +++ /dev/null @@ -1,73 +0,0 @@ -// @(#)root/net:$Id$ -// Author: Marcelo Sousa 23/08/2011 - -/************************************************************************* - * Copyright (C) 1995-2011, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_TAS3File -#define ROOT_TAS3File - -////////////////////////////////////////////////////////////////////////// -// // -// TAS3File // -// // -// A TAS3File is a normal TWebFile but it reads data from the // -// Amazon S3 server. As a derived TWebFile class TAS3File it is a // -// read only file. The HTTP requests are generated by THTTPMessage // -// objects with the auth_prefix set as AWS. The user id and secret pass // -// required to sign the requests are passed through the environment // -// variables S3_ACCESS_ID and S3_ACCESS_KEY. // -// For more information check: // -// http://aws.amazon.com/documentation/s3/ // -// http://awsdocs.s3.amazonaws.com/S3/latest/s3-qrc.pdf // -// // -////////////////////////////////////////////////////////////////////////// - -#ifndef ROOT_TWebFile -#include "TWebFile.h" -#endif - -#ifndef ROOT_TUrl -#include "TUrl.h" -#endif - -#ifndef ROOT_TString -#include "TString.h" -#endif - -class TAS3File: public TWebFile { - -private: - TAS3File(); - -protected: - TString fAuthPrefix; //Authentication prefix for Amazon S3 - TString fAccessId; //User id - TString fAccessKey; //Secret key - TUrl fServer; //Server url - TString fBucket; //Bucket name - - Int_t GetHead(); - Bool_t ReadBuffer10(char *buf, Int_t len); - -public: - TAS3File(const char *url, Option_t *opt=""); - virtual ~TAS3File() { } - - Bool_t ReadBuffer(char *buf, Int_t len); - Bool_t ReadBuffer(char *buf, Long64_t pos, Int_t len) { return TWebFile::ReadBuffer(buf, pos, len); } - TString GetAuthPrefix() const { return fAuthPrefix; } - TString GetAccessId() const { return fAccessId; } - TString GetAccessKey() const { return fAccessKey; } - TUrl GetUrl() const { return fServer; } - TString GetBucket() const { return fBucket; } - - ClassDef(TAS3File, 0) // Read a ROOT file from the Amazon S3 cloud -}; - -#endif diff --git a/net/net/inc/TFileStager.h b/net/net/inc/TFileStager.h index 3dc857d7a948c..1118ed0232201 100644 --- a/net/net/inc/TFileStager.h +++ b/net/net/inc/TFileStager.h @@ -35,6 +35,7 @@ #endif class TCollection; +class TFileCollection; class TFileStager : public TNamed { @@ -45,6 +46,7 @@ class TFileStager : public TNamed { virtual TList *GetStaged(TCollection *pathlist); virtual Bool_t IsStaged(const char *); virtual Int_t Locate(const char *u, TString &f); + virtual Int_t LocateCollection(TFileCollection *fc, Bool_t addDummyUrl = kFALSE); virtual Bool_t Matches(const char *s) { return ((s && (fName == s)) ? kTRUE : kFALSE); } virtual Bool_t Stage(const char *, Option_t * = 0) { return kTRUE; } virtual Bool_t Stage(TCollection *pathlist, Option_t *opt = 0); diff --git a/net/net/inc/TGSFile.h b/net/net/inc/TGSFile.h deleted file mode 100644 index 9064438b2a88a..0000000000000 --- a/net/net/inc/TGSFile.h +++ /dev/null @@ -1,73 +0,0 @@ -// @(#)root/net:$Id$ -// Author: Marcelo Sousa 23/08/2011 - -/************************************************************************* - * Copyright (C) 1995-2011, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_TGSFile -#define ROOT_TGSFile - -////////////////////////////////////////////////////////////////////////// -// // -// TGSFile // -// // -// A TGSFile is a normal TWebFile but it reads data from the // -// Google Storage server. As a derived TWebFile class TGSFile it is // -// a read only file. The HTTP requests are generated by THTTPMessage // -// objects with the auth_prefix set as GOOG1. The user id and secret // -// pass required to sign the requests are passed through the // -// environment variables GT_ACCESS_ID and GT_ACCESS_KEY. // -// For more information check: // -// http://code.google.com/apis/storage/docs/getting-started.html // -// // -////////////////////////////////////////////////////////////////////////// - -#ifndef ROOT_TWebFile -#include "TWebFile.h" -#endif - -#ifndef ROOT_TUrl -#include "TUrl.h" -#endif - -#ifndef ROOT_TString -#include "TString.h" -#endif - -class TGSFile: public TWebFile { - -private: - TGSFile(); - -protected: - TString fAuthPrefix; //Authentication prefix for Google Storage - TString fAccessId; //User id - TString fAccessKey; //Secret key - TUrl fServer; //Server url - TString fBucket; //Bucket name - - Int_t GetHead(); - Bool_t ReadBuffer10(char *buf, Int_t len); - //Bool_t ReadBuffers10(char *buf, Long64_t *pos, Int_t *len, Int_t nbuf); - -public: - TGSFile(const char *url, Option_t *opt=""); - virtual ~TGSFile() { } - - Bool_t ReadBuffer(char *buf, Int_t len); - Bool_t ReadBuffer(char *buf, Long64_t pos, Int_t len) { return TWebFile::ReadBuffer(buf, pos, len); } - TString GetAuthPrefix() const { return fAuthPrefix; } - TString GetAccessId() const { return fAccessId; } - TString GetAccessKey() const { return fAccessKey; } - TUrl GetUrl() const { return fServer; } - TString GetBucket() const { return fBucket; } - - ClassDef(TGSFile, 0) // Read a ROOT file from the Google Storage cloud -}; - -#endif diff --git a/net/net/inc/THTTPMessage.h b/net/net/inc/THTTPMessage.h deleted file mode 100644 index 3d39309f15728..0000000000000 --- a/net/net/inc/THTTPMessage.h +++ /dev/null @@ -1,114 +0,0 @@ -// @(#)root/net:$Id$ -// Author: Marcelo Sousa 23/08/2011 - -/************************************************************************* - * Copyright (C) 1995-2011, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_THTTPMessage -#define ROOT_THTTPMessage - -////////////////////////////////////////////////////////////////////////// -// // -// THTTPMessage // -// // -// A THTTPMessage object represents a generic HTTP request for the // -// Amazon S3 and the Google Storage services. It can easily be extended // -// to other API's. It assumes that each request is signed with the // -// client id and an encripted key, Base64(HMAC + SHA1 (HTTP Request)) // -// which is based on a secret key provided in the constructor. // -// For more information about the authentication : // -// Google Storage: // -// http://code.google.com/apis/storage/docs/reference/v1/developer-guidev1.html#authentication // -// Amazon S3: // -// http://awsdocs.s3.amazonaws.com/S3/latest/s3-qrc.pdf // -// At the moment THTTPMessage is used for derived classes of TWebFile // -// (read only) files supporting HEAD and GET requests. // -// // -////////////////////////////////////////////////////////////////////////// - -#ifndef ROOT_TObject -#include "TObject.h" -#endif - -#ifndef ROOT_TString -#include "TString.h" -#endif - -enum EHTTP_Verb { - kGET, - kPOST, - kPUT, - kDELETE, - kHEAD, - kCOPY -}; - -class THTTPMessage : public TObject{ - -private: - enum EHTTP_Verb fVerb; //HTTP Verb - TString fPath; //Given path to be parsed - TString fBucket; //Bucket associated with the file - TString fHost; //Server name - TString fDate; //Date - TString fAuthPrefix; //Authentication prefix to distinguish between GT and AWS3 - TString fAccessId; //User id - TString fAccessIdKey; //Secret key - Bool_t fHasRange; //GET request with range - Long64_t fOffset; //Offset - Long64_t *fInitByte; //Init positions for the range - Int_t *fLen; //Range length - Int_t fNumBuf; //Number of buffers - Int_t fCurrentBuf; //For requests > 8000 we need to generate several requests - Int_t fLength; //Request length - TString fSignature; //Message signature - -protected: - TString Sign(); - -public: - THTTPMessage(EHTTP_Verb mverb, TString mpath, TString mbucket, TString mhost, - TString maprefix, TString maid, TString maidkey); - THTTPMessage(EHTTP_Verb mverb, TString mpath, TString mbucket, TString mhost, - TString maprefix, TString maid, TString maidkey, Long64_t offset, Long64_t *pos, Int_t *len, Int_t nbuf); - THTTPMessage() : fInitByte(0), fLen(0) { } - virtual ~THTTPMessage() { } - THTTPMessage &operator=(const THTTPMessage& rhs); - - EHTTP_Verb GetHTTPVerb() const { return fVerb; } - TString GetPath() const { return fPath; } - TString GetBucket() const { return fBucket; } - TString GetHost() const { return fHost; } - TString GetDatime() const { return fDate; } - TString GetAuthPrefix() const { return fAuthPrefix; } - TString GetAccessId() const { return fAccessId; } - TString GetAccessIdKey() const { return fAccessIdKey; } - Long64_t GetOffset() const { return fOffset; } - Long64_t* GetInitByte() const { return fInitByte; } - Int_t* GetRangeLength() const { return fLen; } - Int_t GetCurrentBuffer() const { return fCurrentBuf; } - Int_t GetNumBuffers() const { return fNumBuf; } - Int_t GetLength() const { return fLength; } - TString GetSignature() const { return fSignature; } - - Bool_t HasRange() const { return fHasRange; } - - TString DatimeToTString() const; - TString HTTPVerbToTString() const; - - TString CreateHead() const; - TString CreateHost() const; - TString CreateDate() const; - TString CreateAuth() const; - - TString GetRequest(); - - ClassDef(THTTPMessage, 0) // Create generic HTTP request for Amazon S3 and Google Storage services -}; - -#endif diff --git a/net/net/inc/TMessage.h b/net/net/inc/TMessage.h index 0780b029752a2..04f559ad2ed2e 100644 --- a/net/net/inc/TMessage.h +++ b/net/net/inc/TMessage.h @@ -44,7 +44,7 @@ friend class TPSocket; friend class TXSocket; private: - TList *fInfos; //Array of TStreamerInfo used in WriteObject + TList *fInfos; //List of TStreamerInfo used in WriteObject TBits fBitsPIDs; //Array of bits to mark the TProcessIDs uids written to the message UInt_t fWhat; //Message type TClass *fClass; //If message is kMESS_OBJECT pointer to object's class @@ -82,6 +82,7 @@ friend class TXSocket; void EnableSchemaEvolution(Bool_t enable = kTRUE) { fEvolution = enable; } Bool_t UsesSchemaEvolution() const { return fEvolution; } + TList *GetStreamerInfos() const { return fInfos; } Int_t GetCompressionAlgorithm() const; Int_t GetCompressionLevel() const; Int_t GetCompressionSettings() const; diff --git a/net/net/inc/TS3HTTPRequest.h b/net/net/inc/TS3HTTPRequest.h new file mode 100644 index 0000000000000..d2a0f95efdf72 --- /dev/null +++ b/net/net/inc/TS3HTTPRequest.h @@ -0,0 +1,158 @@ +// @(#)root/net:$Id$ +// Author: Fabio Hernandez 30/01/2013 +// based on an initial version by Marcelo Sousa (class THTTPMessage) + +/************************************************************************* + * Copyright (C) 1995-2011, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TS3HTTPRequest +#define ROOT_TS3HTTPRequest + +////////////////////////////////////////////////////////////////////////// +// // +// TS3HTTPRequest // +// // +// An object of this class represents an HTTP request extended to be // +// compatible with Amazon's S3 protocol. // +// Specifically, such a request contains an 'Authorization' header with // +// information used by the S3 server for authenticating this request. // +// The authentication information is computed based on a pair of access // +// key and secret key which are both provided to the user by the S3 // +// service provider (e.g. Amazon, Google, etc.). // +// The secret key is used to compute a signature of selected fields in // +// the request. The algorithm for computing the signature is documented // +// in: // +// // +// Google storage: // +// http://code.google.com/apis/storage/docs/reference/v1/developer-guidev1.html#authentication +// // +// Amazon: // +// http://docs.aws.amazon.com/AmazonS3/latest/dev/S3_Authentication2.html +// // +////////////////////////////////////////////////////////////////////////// + +#ifndef ROOT_TObject +#include "TObject.h" +#endif + +#ifndef ROOT_TString +#include "TString.h" +#endif + + + +class TS3HTTPRequest : public TObject { + +public: + + enum EHTTPVerb { kGET, kPOST, kPUT, kDELETE, kHEAD, kCOPY }; + enum EAuthType { kNoAuth, kAmazon, kGoogle }; + +private: + EHTTPVerb fVerb; // HTTP Verb + EAuthType fAuthType; // Authentication type + TString fHost; // Host name + TString fBucket; // Bucket name + TString fObjectKey; // Object key + TString fTimeStamp; // Request time stamp + TString fAccessKey; // Access key (for authentication) + TString fSecretKey; // Secret key (for authentication) + + +protected: + TString HTTPVerbToTString(EHTTPVerb httpVerb) const; + TString MakeRequestLine(TS3HTTPRequest::EHTTPVerb httpVerb) const; + TString MakeAuthHeader(TS3HTTPRequest::EHTTPVerb httpVerb) const; + TString ComputeSignature(TS3HTTPRequest::EHTTPVerb httpVerb) const; + TString MakeAuthPrefix() const; + TString MakeHostHeader() const; + TString MakeDateHeader() const; + TS3HTTPRequest& SetTimeStamp(); + +public: + + TS3HTTPRequest(); + TS3HTTPRequest(EHTTPVerb httpVerb, const TString& host, + const TString& bucket, const TString& objectKey, + EAuthType authType, const TString& accessKey, + const TString& secretKey); + TS3HTTPRequest(const TS3HTTPRequest& m); + virtual ~TS3HTTPRequest() { } + + EHTTPVerb GetHTTPVerb() const { return fVerb; } + const TString& GetHost() const { return fHost; } + const TString& GetBucket() const { return fBucket; } + const TString& GetObjectKey() const { return fObjectKey; } + const TString& GetTimeStamp() const { return fTimeStamp; } + const TString& GetAccessKey() const { return fAccessKey; } + const TString& GetSecretKey() const { return fSecretKey; } + TString GetAuthType() const { return fAuthType; } + TString GetRequest(TS3HTTPRequest::EHTTPVerb httpVerb, Bool_t appendCRLF=kTRUE); + + TS3HTTPRequest& SetHost(const TString& host); + TS3HTTPRequest& SetBucket(const TString& bucket); + TS3HTTPRequest& SetObjectKey(const TString& objectKey); + TS3HTTPRequest& SetAccessKey(const TString& accessKey); + TS3HTTPRequest& SetSecretKey(const TString& secretKey); + TS3HTTPRequest& SetAuthKeys(const TString& accessKey, const TString& secretKey); + TS3HTTPRequest& SetAuthType(TS3HTTPRequest::EAuthType authType); + + ClassDef(TS3HTTPRequest, 0) // Create generic HTTP request for Amazon S3 and Google Storage services +}; + + +////////////////////////////////////////////////////////////////////////// +// // +// Inlines // +// // +////////////////////////////////////////////////////////////////////////// + +inline TS3HTTPRequest& TS3HTTPRequest::SetHost(const TString& host) +{ + fHost = host; + return *this; +} + +inline TS3HTTPRequest& TS3HTTPRequest::SetBucket(const TString& bucket) +{ + fBucket = bucket; + return *this; +} + +inline TS3HTTPRequest& TS3HTTPRequest::SetObjectKey(const TString& objectKey) +{ + fObjectKey = objectKey; + return *this; +} + +inline TS3HTTPRequest& TS3HTTPRequest::SetAuthKeys(const TString& accessKey, const TString& secretKey) +{ + fAccessKey = accessKey; + fSecretKey = secretKey; + return *this; +} + +inline TS3HTTPRequest& TS3HTTPRequest::SetAuthType(TS3HTTPRequest::EAuthType authType) +{ + fAuthType = authType; + return *this; +} + +inline TS3HTTPRequest& TS3HTTPRequest::SetAccessKey(const TString& accessKey) +{ + fAccessKey = accessKey; + return *this; +} + +inline TS3HTTPRequest& TS3HTTPRequest::SetSecretKey(const TString& secretKey) +{ + fSecretKey = secretKey; + return *this; +} + +#endif diff --git a/net/net/inc/TS3WebFile.h b/net/net/inc/TS3WebFile.h new file mode 100644 index 0000000000000..95947ed53aac1 --- /dev/null +++ b/net/net/inc/TS3WebFile.h @@ -0,0 +1,116 @@ +// @(#)root/net:$Id: TS3WebFile.h$ +// Author: Fabio Hernandez 22/01/2013 +// extending an initial version by Marcelo Sousa (class TAS3File) + +/************************************************************************* + * Copyright (C) 1995-2011, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TS3WebFile +#define ROOT_TS3WebFile + +////////////////////////////////////////////////////////////////////////// +// // +// TS3WebFile // +// // +// A TS3WebFile is a TWebFile which retrieves the file contents from a // +// web server implementing the REST API of the Amazon S3 protocol. This // +// class is meant to be as generic as possible to be used with files // +// hosted not only by Amazon S3 servers but also by other providers // +// implementing the core of the S3 protocol. // +// // +// The S3 protocol works on top of HTTPS (and HTTP) and imposes that // +// each HTTP request be signed using a specific convention: the request // +// must include an 'Authorization' header which contains the signature // +// of a concatenation of selected request fields. For signing the // +// request, an 'Access Key Id' and a 'Secret Access Key' need to be // +// known. These keys are used by the S3 servers to identify the client // +// and to authenticate the request as genuine. // +// // +// As an end user, you must know the Access Key and Secret Access Key // +// in order to access each S3 file. They are provided to you by your S3 // +// service provider. Those two keys can be provided to ROOT when // +// initializing an object of this class by two means: // +// a) by using the environmental variables S3_ACCESS_KEY and // +// S3_SECRET_KEY, or // +// b) by specifying them as an argument when opening each file. // +// // +// The first method is convenient if all the S3 files you want to // +// access are hosted by a single provider. The second one is more // +// flexible as it allows you to specify which credentials to use // +// on a per-file basis. See the documentation of the constructor of // +// this class for details on the syntax. // +// // +// For generating and signing the HTTP request, this class uses // +// TS3HTTPRequest. // +// // +// For more information on the details of S3 protocol please refer to: // +// "Amazon Simple Storage Service Developer Guide": // +// http://docs.amazonwebservices.com/AmazonS3/latest/dev/Welcome.html // +// // +// "Amazon Simple Storage Service REST API Reference" // +// http://docs.amazonwebservices.com/AmazonS3/latest/API/APIRest.html // +////////////////////////////////////////////////////////////////////////// + +#ifndef ROOT_TWebFile +#include "TWebFile.h" +#endif + +#ifndef ROOT_TUrl +#include "TUrl.h" +#endif + +#ifndef ROOT_TString +#include "TString.h" +#endif + +#ifndef ROOT_TS3HTTPRequest +#include "TS3HTTPRequest.h" +#endif + + +class TS3WebFile: public TWebFile { + +private: + TS3WebFile(); + Bool_t ParseOptions(Option_t* options, TString& accessKey, TString& secretKey); + Bool_t GetCredentialsFromEnv(const char* accessKeyEnv, const char* secretKeyEnv, + TString& outAccessKey, TString& outSecretKey); + +protected: + // Super-class methods extended by this class + virtual Int_t GetHead(); + virtual void SetMsgReadBuffer10(const char* redirectLocation = 0, Bool_t tempRedirect = kFALSE); + virtual void ProcessHttpHeader(const TString& headerLine); + + // Modifiers of data members (to be used mainly by subclasses) + void SetAccessKey(const TString& accessKey) { fS3Request.SetAccessKey(accessKey); } + void SetSecretKey(const TString& secretKey) { fS3Request.SetSecretKey(secretKey); } + + // Data members + TS3HTTPRequest fS3Request; // S3 HTTP request + Bool_t fUseMultiRange; // Is the S3 server capable of serving multirange requests? + +public: + // Constructors & Destructor + TS3WebFile(const char* url, Option_t* options=""); + virtual ~TS3WebFile() {} + + // Selectors + const TString& GetAccessKey() const { return fS3Request.GetAccessKey(); } + const TString& GetSecretKey() const { return fS3Request.GetSecretKey(); } + const TString& GetBucket() const { return fS3Request.GetBucket(); } + const TString& GetObjectKey() const { return fS3Request.GetObjectKey(); } + const TUrl& GetUrl() const { return fUrl; } + + // Modifiers + virtual Bool_t ReadBuffers(char* buf, Long64_t* pos, Int_t* len, Int_t nbuf); + + ClassDef(TS3WebFile, 0) // Read a ROOT file from a S3 server +}; + +#endif // ROOT_TS3WebFile diff --git a/net/net/inc/TSQLStatement.h b/net/net/inc/TSQLStatement.h index 410d2279f5f6e..67c9e3669c3d8 100644 --- a/net/net/inc/TSQLStatement.h +++ b/net/net/inc/TSQLStatement.h @@ -62,6 +62,7 @@ class TSQLStatement : public TObject { Bool_t SetTimestamp(Int_t, const TDatime&); virtual void SetTimeFormating(const char*) {} virtual Bool_t SetBinary(Int_t, void*, Long_t, Long_t = 0x1000) { return kFALSE; } + virtual Bool_t SetLargeObject(Int_t col, void* mem, Long_t size, Long_t maxsize = 0x1000) { return SetBinary(col, mem, size, maxsize); } #ifndef __MAKECINT__ virtual Bool_t SetVInt(Int_t, const std::vector<Int_t>, const char*, const char*) { return kFALSE; } virtual Bool_t SetVUInt(Int_t, const std::vector<UInt_t>, const char*, const char*) { return kFALSE; } @@ -89,6 +90,7 @@ class TSQLStatement : public TObject { virtual Double_t GetDouble(Int_t) { return 0.; } virtual const char *GetString(Int_t) { return 0; } virtual Bool_t GetBinary(Int_t, void* &, Long_t&) { return kFALSE; } + virtual Bool_t GetLargeObject(Int_t col, void* &mem, Long_t& size) { return GetBinary(col, mem, size); } virtual Bool_t GetDate(Int_t, Int_t&, Int_t&, Int_t&) { return kFALSE; } virtual Bool_t GetTime(Int_t, Int_t&, Int_t&, Int_t&) { return kFALSE; } diff --git a/net/net/inc/TWebFile.h b/net/net/inc/TWebFile.h index e12b1b4d58393..e20fe5dee3d8d 100644 --- a/net/net/inc/TWebFile.h +++ b/net/net/inc/TWebFile.h @@ -72,6 +72,7 @@ friend class TWebSystem; virtual Bool_t ReadBuffer10(char *buf, Int_t len); virtual Bool_t ReadBuffers10(char *buf, Long64_t *pos, Int_t *len, Int_t nbuf); virtual void SetMsgReadBuffer10(const char *redirectLocation = 0, Bool_t tempRedirect = kFALSE); + virtual void ProcessHttpHeader(const TString& headerLine); public: TWebFile(const char *url, Option_t *opt=""); diff --git a/net/net/src/TAS3File.cxx b/net/net/src/TAS3File.cxx deleted file mode 100644 index 7de0ce9eaa80e..0000000000000 --- a/net/net/src/TAS3File.cxx +++ /dev/null @@ -1,265 +0,0 @@ -// @(#)root/net:$Id$ -// Author: Marcelo Sousa 23/08/2011 - -/************************************************************************* - * Copyright (C) 1995-2011, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TAS3File // -// // -// A TAS3File is a normal TWebFile but it reads data from the // -// Amazon S3 server. As a derived TWebFile class TAS3File it is a // -// read only file. The HTTP requests are generated by THTTPMessage // -// objects with the auth_prefix set as AWS. The user id and secret pass // -// required to sign the requests are passed through the environment // -// variables S3_ACCESS_ID and S3_ACCESS_KEY. // -// For more information check: // -// http://aws.amazon.com/documentation/s3/ // -// http://awsdocs.s3.amazonaws.com/S3/latest/s3-qrc.pdf // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TAS3File.h" -#include "THTTPMessage.h" -#include "TSocket.h" -#include "TROOT.h" - -#include <errno.h> -#include <stdlib.h> - -ClassImp(TAS3File) - -//______________________________________________________________________________ -TAS3File::TAS3File(const char *path, Option_t *) : TWebFile(path, "IO") -{ - // For TAS3File to properly work you need to set up - // environment variables S3_ACCESS_ID and S3_ACCESS_KEY - // The format of the path is: server/bucket/file - // Example: f = new TAS3File("as3://s3-eu-west-1.amazonaws.com/roots3/hsimple.root") - - TString tpath = path; - - Int_t begPath = 6, slash = 0, i = 0; - - if (tpath.BeginsWith("as3://") == kFALSE) { - Error("TAS3File", "invalid path %s", path); - goto zombie; - } - - while (i < 2 && begPath < tpath.Length()) { - slash = tpath.Index('/', begPath); - - if (slash == kNPOS) { - Error("TAS3File","invalid path %s", path); - goto zombie; - } - - switch(i){ - case 0: - fServer = TUrl(TString(tpath(begPath,slash))); - break; - case 1: - fBucket = tpath(begPath,slash-begPath); - fRealName = "/" + tpath(slash+1, tpath.Length()-(slash+1)); - } - i++; - begPath = slash+1; - } - - fAuthPrefix = "AWS"; - fAccessId = gSystem->Getenv("S3_ACCESS_ID"); - fAccessKey = gSystem->Getenv("S3_ACCESS_KEY"); - if (fAccessId == "" || fAccessKey == "") { - if (fAccessId == "") Error("TAS3File", "shell variable S3_ACCESS_ID not set"); - if (fAccessKey == "") Error("TAS3File", "shell variable S3_ACCESS_KEY not set"); - goto zombie; - } - - Init(kFALSE); - return; - -zombie: - MakeZombie(); - gDirectory = gROOT; -} - -//______________________________________________________________________________ -Int_t TAS3File::GetHead() -{ - // Clone of TWebFile::GetHead except it uses THTTPMessage to generate - // the HTTP request. - - THTTPMessage s3head = THTTPMessage(kHEAD, fRealName, GetBucket(), - GetUrl().GetHost(), GetAuthPrefix(), - GetAccessId(), GetAccessKey()); - - TString msg = s3head.GetRequest(); - - TUrl connurl; - - fUrl = fServer; - - if (fProxy.IsValid()) - connurl = fProxy; - else - connurl = fUrl; - - TSocket *s = 0; - for (Int_t i = 0; i < 5; i++) { - s = new TSocket(connurl.GetHost(), connurl.GetPort()); - if (!s->IsValid()) { - delete s; - if (gSystem->GetErrno() == EADDRINUSE || gSystem->GetErrno() == EISCONN) { - s = 0; - gSystem->Sleep(i*10); - } else { - Error("GetHead", "cannot connect to host %s (errno=%d)", fUrl.GetHost(), - gSystem->GetErrno()); - return -1; - } - } else - break; - } - if (!s) - return -1; - - if (s->SendRaw(msg.Data(), msg.Length()) == -1) { - Error("GetHead", "error sending command to host %s", fUrl.GetHost()); - delete s; - return -1; - } - - char line[8192]; - Int_t n, ret = 0, redirect = 0; - - while ((n = GetLine(s, line, sizeof(line))) >= 0) { - if (n == 0) { - if (gDebug > 0) - Info("GetHead", "got all headers"); - delete s; - if (fBasicUrlOrg != "" && !redirect) { - // set back to original url in case of temp redirect - SetMsgReadBuffer10(); - fMsgGetHead = ""; - } - if (ret < 0) - return ret; - if (redirect) - return GetHead(); - return 0; - } - - if (gDebug > 0) - Info("GetHead", "header: %s", line); - - TString res = line; - if (res.BeginsWith("HTTP/1.")) { - if (res.BeginsWith("HTTP/1.1")) { - if (!fHTTP11) { - fMsgGetHead = ""; - fMsgReadBuffer10 = ""; - } - fHTTP11 = kTRUE; - } - TString scode = res(9, 3); - Int_t code = scode.Atoi(); - if (code >= 500) { - if (code == 500) - fHasModRoot = kTRUE; - else { - ret = -1; - TString mess = res(13, 1000); - Error("GetHead", "%s: %s (%d)", fBasicUrl.Data(), mess.Data(), code); - } - } else if (code >= 400) { - if (code == 400) - ret = -3; // command not supported - else if (code == 404) - ret = -2; // file does not exist - else { - ret = -1; - TString mess = res(13, 1000); - Error("GetHead", "%s: %s (%d)", fBasicUrl.Data(), mess.Data(), code); - } - } else if (code >= 300) { - if (code == 301 || code == 303) - redirect = 1; // permanent redirect - else if (code == 302 || code == 307) - redirect = 2; // temp redirect - else { - ret = -1; - TString mess = res(13, 1000); - Error("GetHead", "%s: %s (%d)", fBasicUrl.Data(), mess.Data(), code); - } - } else if (code > 200) { - ret = -1; - TString mess = res(13, 1000); - Error("GetHead", "%s: %s (%d)", fBasicUrl.Data(), mess.Data(), code); - } - } else if (res.BeginsWith("Content-Length:")) { - TString slen = res(16, 1000); - fSize = slen.Atoll(); - } else if (res.BeginsWith("Location:") && redirect) { - TString redir = res(10, 1000); - if (redirect == 2) // temp redirect - SetMsgReadBuffer10(redir, kTRUE); - else // permanent redirect - SetMsgReadBuffer10(redir, kFALSE); - fMsgGetHead = ""; - } - } - - delete s; - return ret; -} - -//______________________________________________________________________________ -Bool_t TAS3File::ReadBuffer(char *buf, Int_t len) -{ - return ReadBuffer10(buf,len); -} - -//______________________________________________________________________________ -Bool_t TAS3File::ReadBuffer10(char *buf, Int_t len) -{ - // Read specified byte range from Amazon S3. - // This routine connects to the Amazon S3 server, sends the - // request created by THTTPMessage and returns the buffer. - // Returns kTRUE in case of error. - - const Int_t nbuf = 1; - Long64_t pos[nbuf]; - pos[nbuf-1] = fOffset; - - Int_t lens[nbuf]; - lens[nbuf-1] = len; - - THTTPMessage s3get = THTTPMessage(kGET, fRealName, GetBucket(), - GetUrl().GetHost(), GetAuthPrefix(), - GetAccessId(), GetAccessKey(), - 0, pos, lens, nbuf); - TString msg = s3get.GetRequest(); - - Int_t n = GetFromWeb10(buf, len, msg); - if (n == -1) - return kTRUE; - // The -2 error condition typically only happens when - // GetHead() failed because not implemented, in the first call to - // ReadBuffer() in Init(), it is not checked in ReadBuffers10(). - if (n == -2) { - Error("ReadBuffer10", "%s does not exist", fBasicUrl.Data()); - MakeZombie(); - gDirectory = gROOT; - return kTRUE; - } - - fOffset += len; - - return kFALSE; -} diff --git a/net/net/src/TFileStager.cxx b/net/net/src/TFileStager.cxx index ae708194f4830..16f3523f83ca5 100644 --- a/net/net/src/TFileStager.cxx +++ b/net/net/src/TFileStager.cxx @@ -34,6 +34,9 @@ #include "TROOT.h" #include "TSystem.h" #include "TUrl.h" +#include "TCollection.h" +#include "TFileCollection.h" +#include "THashList.h" //_____________________________________________________________________________ TList* TFileStager::GetStaged(TCollection *pathlist) @@ -149,6 +152,36 @@ Int_t TFileStager::Locate(const char *u, TString &f) return 0; } +//______________________________________________________________________________ +Int_t TFileStager::LocateCollection(TFileCollection *fc, Bool_t) +{ + // Massive location of files. Returns < 0 on error, or number of files + // processed. Results are returned on the TFileCollection itself + + TFileInfo *fi; + TString endp; + TIter it(fc->GetList()); + Int_t count = 0; + + while ((fi = dynamic_cast<TFileInfo *>(it.Next()))) { + const char *ourl = fi->GetCurrentUrl()->GetUrl(); + if (!ourl) continue; + + if (Locate(ourl, endp) == 0) { + fi->AddUrl(endp.Data(), kTRUE); + fi->SetBit(TFileInfo::kStaged); + fi->ResetUrl(); + } + else { + fi->ResetBit(TFileInfo::kStaged); + } + + count++; + } + + return count; +} + //_____________________________________________________________________________ TString TFileStager::GetPathName(TObject *o) { diff --git a/net/net/src/TGSFile.cxx b/net/net/src/TGSFile.cxx deleted file mode 100644 index 2df43ef6f47fa..0000000000000 --- a/net/net/src/TGSFile.cxx +++ /dev/null @@ -1,309 +0,0 @@ -// @(#)root/net:$Id$ -// Author: Marcelo Sousa 23/08/2011 - -/************************************************************************* - * Copyright (C) 1995-2011, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TGSFile // -// // -// A TGSFile is a normal TWebFile but it reads data from the // -// Google Storage server. As a derived TWebFile class TGSFile it is // -// a read only file. The HTTP requests are generated by THTTPMessage // -// objects with the auth_prefix set as GOOG1. The user id and secret // -// pass required to sign the requests are passed through the // -// environment variables GT_ACCESS_ID and GT_ACCESS_KEY. // -// For more information check: // -// http://code.google.com/apis/storage/docs/getting-started.html // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TGSFile.h" -#include "THTTPMessage.h" -#include "TSocket.h" -#include "TROOT.h" - -#include <errno.h> -#include <stdlib.h> - -ClassImp(TGSFile) - -//______________________________________________________________________________ -TGSFile::TGSFile(const char *path, Option_t *) : TWebFile(path, "IO") -{ - // For TGSFile to properly work you need to set up - // environment variables GT_ACCESS_ID and GT_ACCESS_KEY. - // The format of the path is: server/bucket/file, e.g. - // f = new TGSFile("gs://commondatastorage.googleapis.com/roots3/hsimple.root") - - TString tpath = path; - - Int_t begPath = 5, slash = 0, i = 0; - - if (tpath.BeginsWith("gs://") == kFALSE) { - Error("TGSFile", "invalid path %s", path); - goto zombie; - } - - while (i < 2 && begPath < tpath.Length()) { - slash = tpath.Index('/', begPath); - - if (slash == kNPOS) { - Error("TGSFile","invalid path %s", path); - goto zombie; - } - - switch(i){ - case 0: - fServer = TUrl(TString(tpath(begPath,slash))); - break; - case 1: - fBucket = tpath(begPath,slash-begPath); - fRealName = "/" + tpath(slash+1, tpath.Length()-(slash+1)); - } - i++; - begPath = slash+1; - } - - fAuthPrefix = "GOOG1"; - fAccessId = gSystem->Getenv("GT_ACCESS_ID"); - fAccessKey = gSystem->Getenv("GT_ACCESS_KEY"); - if (fAccessId == "" || fAccessKey == "") { - if (fAccessId == "") Error("TGSFile", "shell variable GT_ACCESS_ID not set"); - if (fAccessKey == "") Error("TGSFile", "shell variable GT_ACCESS_KEY not set"); - goto zombie; - } - - Init(kFALSE); - return; - -zombie: - MakeZombie(); - gDirectory = gROOT; -} - -//______________________________________________________________________________ -Int_t TGSFile::GetHead() -{ - // Clone of TWebFile::GetHead except it uses THTTPMessage to generate - // the HTTP request. - - THTTPMessage s3head = THTTPMessage(kHEAD, fRealName, GetBucket(), - GetUrl().GetHost(), GetAuthPrefix(), - GetAccessId(), GetAccessKey()); - - TString msg = s3head.GetRequest(); - - TUrl connurl; - - fUrl = fServer; - - if (fProxy.IsValid()) - connurl = fProxy; - else - connurl = fUrl; - - TSocket *s = 0; - for (Int_t i = 0; i < 5; i++) { - s = new TSocket(connurl.GetHost(), connurl.GetPort()); - if (!s->IsValid()) { - delete s; - if (gSystem->GetErrno() == EADDRINUSE || gSystem->GetErrno() == EISCONN) { - s = 0; - gSystem->Sleep(i*10); - } else { - Error("GetHead", "cannot connect to host %s (errno=%d)", fUrl.GetHost(), - gSystem->GetErrno()); - return -1; - } - } else - break; - } - if (!s) - return -1; - - if (s->SendRaw(msg.Data(), msg.Length()) == -1) { - Error("GetHead", "error sending command to host %s", fUrl.GetHost()); - delete s; - return -1; - } - - char line[8192]; - Int_t n, ret = 0, redirect = 0; - - while ((n = GetLine(s, line, sizeof(line))) >= 0) { - if (n == 0) { - if (gDebug > 0) - Info("GetHead", "got all headers"); - delete s; - if (fBasicUrlOrg != "" && !redirect) { - // set back to original url in case of temp redirect - SetMsgReadBuffer10(); - fMsgGetHead = ""; - } - if (ret < 0) - return ret; - if (redirect) - return GetHead(); - return 0; - } - - if (gDebug > 0) - Info("GetHead", "header: %s", line); - - TString res = line; - if (res.BeginsWith("HTTP/1.")) { - if (res.BeginsWith("HTTP/1.1")) { - if (!fHTTP11) { - fMsgGetHead = ""; - fMsgReadBuffer10 = ""; - } - fHTTP11 = kTRUE; - } - TString scode = res(9, 3); - Int_t code = scode.Atoi(); - if (code >= 500) { - if (code == 500) - fHasModRoot = kTRUE; - else { - ret = -1; - TString mess = res(13, 1000); - Error("GetHead", "%s: %s (%d)", fBasicUrl.Data(), mess.Data(), code); - } - } else if (code >= 400) { - if (code == 400) - ret = -3; // command not supported - else if (code == 404) - ret = -2; // file does not exist - else { - ret = -1; - TString mess = res(13, 1000); - Error("GetHead", "%s: %s (%d)", fBasicUrl.Data(), mess.Data(), code); - } - } else if (code >= 300) { - if (code == 301 || code == 303) - redirect = 1; // permanent redirect - else if (code == 302 || code == 307) - redirect = 2; // temp redirect - else { - ret = -1; - TString mess = res(13, 1000); - Error("GetHead", "%s: %s (%d)", fBasicUrl.Data(), mess.Data(), code); - } - } else if (code > 200) { - ret = -1; - TString mess = res(13, 1000); - Error("GetHead", "%s: %s (%d)", fBasicUrl.Data(), mess.Data(), code); - } - } else if (res.BeginsWith("Content-Length:")) { - TString slen = res(16, 1000); - fSize = slen.Atoll(); - } else if (res.BeginsWith("Location:") && redirect) { - TString redir = res(10, 1000); - if (redirect == 2) // temp redirect - SetMsgReadBuffer10(redir, kTRUE); - else // permanent redirect - SetMsgReadBuffer10(redir, kFALSE); - fMsgGetHead = ""; - } - } - - delete s; - return ret; -} - -#if 0 -// Currently not supported on the Google Storage cloud side because -// the chunked responses are not "standard" -//______________________________________________________________________________ -Bool_t TGSFile::ReadBuffers10(char *buf, Long64_t *pos, Int_t *len, Int_t nbuf) -{ - // Read specified byte range from Google Storage. - // This routine connects to the Google Storage server, sends the - // request created by THTTPMessage and returns the buffer. - // Returns kTRUE in case of error. - - THTTPMessage gsget = THTTPMessage(kGET, fRealName, GetBucket(), - GetUrl().GetHost(), GetAuthPrefix(), - GetAccessId(), GetAccessKey(), - fOffset, pos, len, nbuf); - TString msg = gsget.GetRequest(); - Int_t size = gsget.GetLength(); - Int_t curbuf = gsget.GetCurrentBuffer(); - - //printf("Num of buffers %d, current buffer %d size %d\n",nbuf,curbuf,size); - - Int_t n = GetFromWeb10(buf, size, msg); - if (n == -1) - return kTRUE; - // The -2 error condition typically only happens when - // GetHead() failed because not implemented, in the first call to - // ReadBuffer() in Init(), it is not checked in ReadBuffers10(). - if (n == -2) { - Error("ReadBuffer10", "%s does not exist", fBasicUrl.Data()); - MakeZombie(); - gDirectory = gROOT; - return kTRUE; - } - - fOffset += size; - - if (nbuf == curbuf) { - return kFALSE; - } else { - return ReadBuffers10(&buf[size], &pos[curbuf], &len[curbuf], nbuf-curbuf); - } -} -#endif - -//______________________________________________________________________________ -Bool_t TGSFile::ReadBuffer(char *buf, Int_t len) -{ - return ReadBuffer10(buf,len); -} - -//______________________________________________________________________________ -Bool_t TGSFile::ReadBuffer10(char *buf, Int_t len) -{ - // Read specified byte range from Google Storage. - // This routine connects to the Google Storage server, sends the - // request created by THTTPMessage and returns the buffer. - // Returns kTRUE in case of error. - - const Int_t nbuf = 1; - Long64_t pos[nbuf]; - pos[nbuf-1] = fOffset; - - Int_t lens[nbuf]; - lens[nbuf-1] = len; - - THTTPMessage gsget = THTTPMessage(kGET, fRealName, GetBucket(), - GetUrl().GetHost(), GetAuthPrefix(), - GetAccessId(), GetAccessKey(), - 0, pos, lens, nbuf); - TString msg = gsget.GetRequest(); - - Int_t n = GetFromWeb10(buf, len, msg); - if (n == -1) - return kTRUE; - // The -2 error condition typically only happens when - // GetHead() failed because not implemented, in the first call to - // ReadBuffer() in Init(), it is not checked in ReadBuffers10(). - if (n == -2) { - Error("ReadBuffer10", "%s does not exist", fBasicUrl.Data()); - MakeZombie(); - gDirectory = gROOT; - return kTRUE; - } - - fOffset += len; - - return kFALSE; -} - diff --git a/net/net/src/THTTPMessage.cxx b/net/net/src/THTTPMessage.cxx deleted file mode 100644 index f35779507abf5..0000000000000 --- a/net/net/src/THTTPMessage.cxx +++ /dev/null @@ -1,252 +0,0 @@ -// @(#)root/net:$Id$ -// Author: Marcelo Sousa 23/08/2011 - -/************************************************************************* - * Copyright (C) 1995-2011, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// THTTPMessage // -// // -// A THTTPMessage object represents a generic HTTP request for the // -// Amazon S3 and the Google Storage services. It can easily be extended // -// to other API's. It assumes that each request is signed with the // -// client id and an encripted key, Base64(HMAC + SHA1 (HTTP Request)) // -// which is based on a secret key provided in the constructor. // -// For more information about the authentication : // -// Google Storage: // -// http://code.google.com/apis/storage/docs/reference/v1/developer-guidev1.html#authentication // -// Amazon S3: // -// http://awsdocs.s3.amazonaws.com/S3/latest/s3-qrc.pdf // -// At the moment THTTPMessage is used for derived classes of TWebFile // -// (read only) files supporting HEAD and GET requests. // -// // -////////////////////////////////////////////////////////////////////////// - -#include "THTTPMessage.h" -#include "TBase64.h" -#if defined(MAC_OS_X_VERSION_10_7) -#include <CommonCrypto/CommonHMAC.h> -#define SHA_DIGEST_LENGTH 20 -#else -#include <openssl/sha.h> -#include <openssl/hmac.h> -#include <openssl/evp.h> -#include <openssl/bio.h> -#include <openssl/buffer.h> -#endif - -#include <stdio.h> -#include <time.h> -#include <string.h> - -ClassImp(THTTPMessage) - -//______________________________________________________________________________ -THTTPMessage::THTTPMessage(EHTTP_Verb mverb, TString mpath, TString mbucket, TString mhost, - TString maprefix, TString maid, TString maidkey) -{ - // THTTPMessage for HTTP requests without the Range attribute. - - fVerb = mverb; - fPath = mpath; - fBucket = mbucket; - fHost = mhost; - fDate = DatimeToTString(); - fAuthPrefix = maprefix; - fAccessId = maid; - fAccessIdKey = maidkey; - fHasRange = kFALSE; - fInitByte = 0; - fOffset = 0; - fLen = 0; - fNumBuf = 0; - fCurrentBuf = 0; - fLength = 0; - - fSignature = Sign(); -} - -//______________________________________________________________________________ -THTTPMessage::THTTPMessage(EHTTP_Verb mverb, TString mpath, TString mbucket, TString mhost, - TString maprefix, TString maid, TString maidkey, Long64_t offset, - Long64_t *pos, Int_t *len, Int_t nbuf) -{ - // THTTPMessage for HTTP Get Requests with Range. - - fVerb = mverb; - fPath = mpath; - fBucket = mbucket; - fHost = mhost; - fDate = DatimeToTString(); - fAuthPrefix = maprefix; - fAccessId = maid; - fAccessIdKey = maidkey; - fHasRange = kTRUE; - fInitByte = pos; - fOffset = offset; - fLen = len; - fNumBuf = nbuf; - fCurrentBuf = 0; - fLength = 0; - - fSignature = Sign(); -} - -//______________________________________________________________________________ -THTTPMessage &THTTPMessage::operator=(const THTTPMessage &rhs) -{ - // Copy ctor. - - if (this != &rhs){ - TObject::operator=(rhs); - fVerb = rhs.fVerb; - fPath = rhs.fPath; - fBucket = rhs.fBucket; - fHost = rhs.fHost; - fDate = rhs.fDate; - fHasRange = rhs.fHasRange; - fInitByte = rhs.fInitByte; - fOffset = rhs.fOffset; - fLen = rhs.fLen; - fNumBuf = rhs.fNumBuf; - fCurrentBuf = rhs.fCurrentBuf; - fAuthPrefix = rhs.fAuthPrefix; - fAccessId = rhs.fAccessId; - fAccessIdKey = rhs.fAccessIdKey; - fSignature = rhs.fSignature; - fLength = rhs.fLength; - } - return *this; -} - -//______________________________________________________________________________ -TString THTTPMessage::Sign() -{ - // Message Signature according to: - // http://awsdocs.s3.amazonaws.com/S3/latest/s3-qrc.pdf - // and - // http://code.google.com/apis/storage/docs/reference/v1/developer-guidev1.html#authentication - - TString sign; - sign += HTTPVerbToTString() + "\n"; - sign += "\n"; // GetContentMD5() - sign += "\n"; // GetContentType() - sign += DatimeToTString() + "\n"; - - if (GetAuthPrefix() == "GOOG1") { - sign += "x-goog-api-version:1\n"; - } - - sign += "/"+GetBucket()+GetPath(); - char digest[SHA_DIGEST_LENGTH] = {0}; - TString key = GetAccessIdKey(); - -#if defined(MAC_OS_X_VERSION_10_7) - CCHmac(kCCHmacAlgSHA1, key.Data(), key.Length() , (unsigned char *) sign.Data(), sign.Length(), (unsigned char *) digest); -#else - unsigned int *sd = NULL; - HMAC(EVP_sha1(), key.Data(), key.Length() , (unsigned char *) sign.Data(), sign.Length(), (unsigned char *) digest, sd); -#endif - - return TBase64::Encode((const char *) digest, SHA_DIGEST_LENGTH); -} - -//______________________________________________________________________________ -TString THTTPMessage::HTTPVerbToTString() const -{ - EHTTP_Verb mverb = GetHTTPVerb(); - switch(mverb){ - case kGET: return TString("GET"); - case kPOST: return TString("POST"); - case kPUT: return TString("PUT"); - case kDELETE: return TString("DELETE"); - case kHEAD: return TString("HEAD"); - case kCOPY: return TString("COPY"); - default: return TString(""); - } -} - -//______________________________________________________________________________ -TString THTTPMessage::DatimeToTString() const -{ - // Generates a Date TString according to: - // http://code.google.com/apis/storage/docs/reference-headers.html#date - - time_t date_temp; - struct tm *date_format; - char date_out[128]; - - time(&date_temp); - date_format = gmtime(&date_temp); - strftime(date_out, 128, "%a, %d %b %Y %H:%M:%S GMT", date_format); - - return TString(date_out); -} - -//______________________________________________________________________________ -TString THTTPMessage::CreateHead() const -{ - return HTTPVerbToTString() + " " + GetPath() + " HTTP/1.1"; -} - -//______________________________________________________________________________ -TString THTTPMessage::CreateHost() const -{ - return (fBucket.EqualTo("")) ? "Host: "+GetHost() : "Host: "+GetBucket()+"."+GetHost(); -} - -//______________________________________________________________________________ -TString THTTPMessage::CreateDate() const -{ - return "Date: " + GetDatime(); -} - -//______________________________________________________________________________ -TString THTTPMessage::CreateAuth() const -{ - if (GetAuthPrefix() == "AWS") { - return "Authorization: " + GetAuthPrefix() + " " + GetAccessId()+":"+GetSignature(); - } else { - return "x-goog-api-version: 1\r\nAuthorization: " + GetAuthPrefix() + " " + - GetAccessId() + ":" + GetSignature(); - } -} - -//______________________________________________________________________________ -TString THTTPMessage::GetRequest() -{ - // Generates a TString with the HTTP Request. - - TString msg; - msg = CreateHead()+"\r\n"; - msg += CreateHost()+"\r\n"; - msg += CreateDate()+"\r\n"; - - Int_t n = 0; - if(HasRange()){ - msg += "Range: bytes="; - for (Int_t i = 0; i < fNumBuf; i++) { - if (n) msg += ","; - msg += fInitByte[i] + fOffset; - msg += "-"; - msg += fInitByte[i] + fOffset + fLen[i] - 1; - fLength += fLen[i]; - n += fLen[i]; - fCurrentBuf++; - if (msg.Length() > 8000) { - break; - } - } - msg += "\r\n"; - } - - msg += CreateAuth()+"\r\n"; - msg += "\r\n\r\n";; - return msg; -} diff --git a/net/net/src/TNetFile.cxx b/net/net/src/TNetFile.cxx index db61d1668a293..9fe93204cd969 100644 --- a/net/net/src/TNetFile.cxx +++ b/net/net/src/TNetFile.cxx @@ -412,7 +412,7 @@ Bool_t TNetFile::ReadBuffers(char *buf, Long64_t *pos, Int_t *len, Int_t nbuf) Double_t start = 0; if (gPerfStats) start = TTimeStamp(); - // Make the string with a list of offsets and lenghts + // Make the string with a list of offsets and lengths Long64_t total_len = 0; Long64_t actual_pos; for(Int_t i = 0; i < nbuf; i++) { @@ -423,7 +423,7 @@ Bool_t TNetFile::ReadBuffers(char *buf, Long64_t *pos, Int_t *len, Int_t nbuf) total_len += len[i]; } - // Send the command with the lenght of the info and number of buffers + // Send the command with the length of the info and number of buffers if (fSocket->Send(Form("%d %d %d", nbuf, data_buf.Length(), blockSize), kROOTD_GETS) < 0) { Error("ReadBuffers", "error sending kROOTD_GETS command"); @@ -656,7 +656,7 @@ void TNetFile::Create(const char * /*url*/, Option_t *option, Int_t netopt) // option argument with an "-", e.g.: "-recreate". Do this only // in cases when you are very sure nobody else is using the file. // To bypass the writelock on a file, to allow the reading of a file - // that is being written by another process, explicitely specify the + // that is being written by another process, explicitly specify the // "+read" option ("read" being the default option). // The netopt argument can be used to specify the size of the tcp window in // bytes (for more info see: http://www.psc.edu/networking/perf_tune.html). @@ -862,7 +862,7 @@ void TNetSystem::InitRemoteEntity(const char *url) // Check and save the host FQDN ... fHost = turl.GetHostFQDN(); - // Remote port: the deafult should be 1094 because we are here + // Remote port: the default should be 1094 because we are here // only if the protocol is "root://" fPort = turl.GetPort(); } @@ -887,7 +887,7 @@ void TNetSystem::Create(const char *url, TSocket *sock) // Check locality, taking into account possible prefixes fLocalPrefix = ""; fIsLocal = kFALSE; - // We may have been asked explicitely to go through the daemon + // We may have been asked explicitly to go through the daemon Bool_t forceRemote = gEnv->GetValue("Path.ForceRemote", 0); TString opts = TUrl(url).GetOptions(); if (opts.Contains("remote=1")) diff --git a/net/net/src/TPSocket.cxx b/net/net/src/TPSocket.cxx index 90d0fee221b44..e5b5b118d16d9 100644 --- a/net/net/src/TPSocket.cxx +++ b/net/net/src/TPSocket.cxx @@ -332,7 +332,7 @@ void TPSocket::Close(Option_t *option) // Close a parallel socket. If option is "force", calls shutdown(id,2) to // shut down the connection. This will close the connection also // for the parent of this process. Also called via the dtor (without - // option "force", call explicitely Close("force") if this is desired). + // option "force", call explicitly Close("force") if this is desired). if (!IsValid()) { diff --git a/net/net/src/TS3HTTPRequest.cxx b/net/net/src/TS3HTTPRequest.cxx new file mode 100644 index 0000000000000..fb45e3a8d32f3 --- /dev/null +++ b/net/net/src/TS3HTTPRequest.cxx @@ -0,0 +1,245 @@ +// @(#)root/net:$Id$ +// Author: Fabio Hernandez 30/01/2013 +// based on an initial version by Marcelo Sousa (class THTTPMessage) + +/************************************************************************* + * Copyright (C) 1995-2011, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////// +// // +// TS3HTTPRequest // +// // +// An object of this class represents an HTTP request extended to be // +// compatible with Amazon's S3 protocol. // +// Specifically, such a request contains an 'Authorization' header with // +// information used by the S3 server for authenticating this request. // +// The authentication information is computed based on a pair of access // +// key and secret key which are both provided to the user by the S3 // +// service provider (e.g. Amazon, Google, etc.). // +// The secret key is used to compute a signature of selected fields in // +// the request. The algorithm for computing the signature is documented // +// in: // +// // +// Google storage: // +// http://code.google.com/apis/storage/docs/reference/v1/developer-guidev1.html#authentication +// // +// Amazon: // +// http://docs.aws.amazon.com/AmazonS3/latest/dev/S3_Authentication2.html +// // +////////////////////////////////////////////////////////////////////////// + +#include "TS3HTTPRequest.h" +#include "TBase64.h" +#if defined(MAC_OS_X_VERSION_10_7) +#include <CommonCrypto/CommonHMAC.h> +#define SHA_DIGEST_LENGTH 20 +#else +#include <openssl/sha.h> +#include <openssl/hmac.h> +#include <openssl/evp.h> +#include <openssl/bio.h> +#include <openssl/buffer.h> +#endif + +#include <stdio.h> +#include <time.h> +#include <string.h> + +ClassImp(TS3HTTPRequest) + +//______________________________________________________________________________ +TS3HTTPRequest::TS3HTTPRequest() + : fAuthType(kNoAuth), fHost("NoHost") +{ +} + +//______________________________________________________________________________ +TS3HTTPRequest::TS3HTTPRequest(EHTTPVerb httpVerb, const TString& host, + const TString& bucket, const TString& objectKey, EAuthType authType, + const TString& accessKey, const TString& secretKey) +{ + // Default constructor + + fVerb = httpVerb; + fHost = host; + fBucket = bucket; + fObjectKey = objectKey; + fAuthType = authType; + fAccessKey = accessKey; + fSecretKey = secretKey; +} + +//______________________________________________________________________________ +TS3HTTPRequest::TS3HTTPRequest(const TS3HTTPRequest& r) + : TObject(r) +{ + // Copy constructor + + fVerb = r.fVerb; + fHost = r.fHost; + fBucket = r.fBucket; + fObjectKey = r.fObjectKey; + fAuthType = r.fAuthType; + fAccessKey = r.fAccessKey; + fSecretKey = r.fSecretKey; + fTimeStamp = r.fTimeStamp; +} + +//______________________________________________________________________________ +TString TS3HTTPRequest::ComputeSignature(TS3HTTPRequest::EHTTPVerb httpVerb) const +{ + // Returns this request's signature + + // Please note, the order of the fields used for computing + // the signature is important. Make sure that the changes you + // make are compatible with the reference documentation. + // + // Refs: + // AMAZON http://awsdocs.s3.amazonaws.com/S3/latest/s3-qrc.pdf + // GOOGLE: http://code.google.com/apis/storage/docs/reference/v1/developer-guidev1.html#authentication + + TString toSign = TString::Format("%s\n\n\n%s\n", // empty Content-MD5 and Content-Type + (const char*)HTTPVerbToTString(httpVerb), + (const char*)fTimeStamp); + if (fAuthType == kGoogle) { + // Must use API version 1. Google Storage API v2 only + // accepts OAuth authentication. + // This header is not strictly needed but if used for computing + // the signature, the request must contain it as a header + // (see method MakeAuthHeader) + // Ref: https://developers.google.com/storage/docs/reference/v1/apiversion1 + toSign += "x-goog-api-version:1\n"; // Lowercase, no spaces around ':' + } + + toSign += "/" + fBucket + fObjectKey; + + unsigned char digest[SHA_DIGEST_LENGTH] = {0}; +#if defined(MAC_OS_X_VERSION_10_7) + CCHmac(kCCHmacAlgSHA1, fSecretKey.Data(), fSecretKey.Length() , (unsigned char *)toSign.Data(), toSign.Length(), digest); +#else + unsigned int *sd = NULL; + HMAC(EVP_sha1(), fSecretKey.Data(), fSecretKey.Length() , (unsigned char *)toSign.Data(), toSign.Length(), digest, sd); +#endif + + return TBase64::Encode((const char *)digest, SHA_DIGEST_LENGTH); +} + +//______________________________________________________________________________ +TString TS3HTTPRequest::HTTPVerbToTString(TS3HTTPRequest::EHTTPVerb httpVerb) const +{ + switch (httpVerb) { + case kGET: return TString("GET"); + case kPOST: return TString("POST"); + case kPUT: return TString("PUT"); + case kDELETE: return TString("DELETE"); + case kHEAD: return TString("HEAD"); + case kCOPY: return TString("COPY"); + default: return TString(""); + } +} + +//______________________________________________________________________________ +TS3HTTPRequest& TS3HTTPRequest::SetTimeStamp() +{ + // Sets this request's time stamp according to: + // http://code.google.com/apis/storage/docs/reference-headers.html#date + + time_t now = time(NULL); + char result[128]; +#ifdef _REENTRANT + struct tm dateFormat; + strftime(result, sizeof(result), "%a, %d %b %Y %H:%M:%S GMT", + gmtime_r(&now, &dateFormat)); +#else + strftime(result, sizeof(result), "%a, %d %b %Y %H:%M:%S GMT", + gmtime(&now)); +#endif + fTimeStamp = result; + return *this; +} + +//______________________________________________________________________________ +TString TS3HTTPRequest::MakeRequestLine(TS3HTTPRequest::EHTTPVerb httpVerb) const +{ + // Returns the first line of a HTTP request for this object. Note that since + // we don't use the virtual host syntax which is supported by Amazon, we + // must include the bucket name in thr resource. For example, we don't use + // http://mybucket.s3.amazonaws.com/path/to/my/file but instead + // http://s3.amazonaws.com/mybucket/path/to/my/file so the HTTP request + // will be of the form "GET /mybucket/path/to/my/file HTTP/1.1" + // Also note that the path must include the leading '/'. + + return TString::Format("%s /%s%s HTTP/1.1", + (const char*)HTTPVerbToTString(httpVerb), + (const char*)fBucket, + (const char*)fObjectKey); +} + +//______________________________________________________________________________ +TString TS3HTTPRequest::MakeHostHeader() const +{ + // Returns the 'Host' header to include in the HTTP request. + + return "Host: " + fHost; +} + +//______________________________________________________________________________ +TString TS3HTTPRequest::MakeDateHeader() const +{ + // Returns the date header for this HTTP request + + return "Date: " + fTimeStamp; +} + +//______________________________________________________________________________ +TString TS3HTTPRequest::MakeAuthPrefix() const +{ + // Returns the authentication prefix + + switch (fAuthType) { + case kNoAuth: return ""; + case kGoogle: return "GOOG1"; + case kAmazon: + default: return "AWS"; + } +} + +//______________________________________________________________________________ +TString TS3HTTPRequest::MakeAuthHeader(TS3HTTPRequest::EHTTPVerb httpVerb) const +{ + // Returns the authentication header for this HTTP request + + if (fAuthType == kNoAuth) + return ""; + + return TString::Format("Authorization: %s %s:%s%s", + (const char*)MakeAuthPrefix(), + (const char*)fAccessKey, + (const char*)ComputeSignature(httpVerb), + (fAuthType == kGoogle) ? "\r\nx-goog-api-version: 1" : ""); +} + +//______________________________________________________________________________ +TString TS3HTTPRequest::GetRequest(TS3HTTPRequest::EHTTPVerb httpVerb, Bool_t appendCRLF) +{ + // Returns the HTTP request ready to be sent to the server + + // Set time stamp before computing this request's signature. The signature + // includes the date. + SetTimeStamp(); + TString request = TString::Format("%s\r\n%s\r\n%s\r\n", + (const char*)MakeRequestLine(httpVerb), + (const char*)MakeHostHeader(), + (const char*)MakeDateHeader()); + TString authHeader = MakeAuthHeader(httpVerb); + if (!authHeader.IsNull()) + request += authHeader + "\r\n"; + if (appendCRLF) + request += "\r\n"; + return request; +} diff --git a/net/net/src/TS3WebFile.cxx b/net/net/src/TS3WebFile.cxx new file mode 100644 index 0000000000000..718520bc5a481 --- /dev/null +++ b/net/net/src/TS3WebFile.cxx @@ -0,0 +1,364 @@ +// @(#)root/net:$Id$ +// Author: Fabio Hernandez 22/01/2013 +// extending an initial version by Marcelo Sousa (class TAS3File) + +/************************************************************************* + * Copyright (C) 1995-2011, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////// +// // +// TS3WebFile // +// // +// A TS3WebFile is a TWebFile which retrieves the file contents from a // +// web server implementing the REST API of the Amazon S3 protocol. This // +// class is meant to be as generic as possible to be used with files // +// hosted not only by Amazon S3 servers but also by other providers // +// implementing the core of the S3 protocol. // +// // +// The S3 protocol works on top of HTTPS (and HTTP) and imposes that // +// each HTTP request be signed using a specific convention: the request // +// must include an 'Authorization' header which contains the signature // +// of a concatenation of selected request fields. For signing the // +// request, an 'Access Key Id' and a 'Secret Access Key' need to be // +// known. These keys are used by the S3 servers to identify the client // +// and to authenticate the request as genuine. // +// // +// As an end user, you must know the Access Key and Secret Access Key // +// in order to access each S3 file. They are provided to you by your S3 // +// service provider. Those two keys can be provided to ROOT when // +// initializing an object of this class by two means: // +// a) by using the environmental variables S3_ACCESS_KEY and // +// S3_SECRET_KEY, or // +// b) by specifying them when opening each file. // +// // +// The first method is convenient if all the S3 files you want to // +// access are hosted by a single provider. The second one is more // +// flexible as it allows you to specify which credentials to use // +// on a per-file basis. See the documentation of the constructor of // +// this class for details on the syntax. // +// // +// For generating and signing the HTTP request, this class uses // +// TS3HTTPRequest. // +// // +// For more information on the details of S3 protocol please refer to: // +// "Amazon Simple Storage Service Developer Guide": // +// http://docs.amazonwebservices.com/AmazonS3/latest/dev/Welcome.html // +// // +// "Amazon Simple Storage Service REST API Reference" // +// http://docs.amazonwebservices.com/AmazonS3/latest/API/APIRest.html // +////////////////////////////////////////////////////////////////////////// + +#include "TS3WebFile.h" +#include "TROOT.h" +#include "TError.h" +#include "TSystem.h" +#include "TPRegexp.h" +#include "TEnv.h" + + +ClassImp(TS3WebFile) + +//_____________________________________________________________________________ +TS3WebFile::TS3WebFile(const char* path, Option_t* options) + : TWebFile(path, "IO") +{ + // Construct a TS3WebFile object. The path argument is a URL of one of the + // following forms: + // + // s3://host.example.com/bucket/path/to/my/file + // s3http://host.example.com/bucket/path/to/my/file + // s3https://host.example.com/bucket/path/to/my/file + // as3://host.example.com/bucket/path/to/my/file + // + // For files hosted by Google Storage, use the following forms: + // + // gs://storage.googleapis.com/bucket/path/to/my/file + // gshttp://storage.googleapis.com/bucket/path/to/my/file + // gsthttps://storage.googleapis.com/bucket/path/to/my/file + // + // The 'as3' scheme is accepted for backwards compatibility but its usage is + // deprecated. + // + // The recommended way to create an instance of this class is through + // TFile::Open, for instance: + // + // TFile* f1 = TFile::Open("s3://host.example.com/bucket/path/to/my/file") + // TFile* f2 = TFile::Open("gs://storage.googleapis.com/bucket/path/to/my/file") + // + // The specified scheme (i.e. s3, s3http, s3https, ...) determines the underlying + // transport protocol to use for downloading the file contents, namely HTTP or HTTPS. + // The 's3', 's3https', 'gs' and 'gshttps' schemes imply using HTTPS as the transport + // protocol. The 's3http', 'as3' and 'gshttp' schemes imply using HTTP as the transport + // protocol. + // + // The 'options' argument can contain 'NOPROXY' if you want to bypass + // the HTTP proxy when retrieving this file's contents. As for any TWebFile-derived + // object, the URL of the web proxy can be specified by setting an environmental + // variable 'http_proxy'. If this variable is set, we ask that proxy to route our + // requests HTTP(S) requests to the file server. + // + // In addition, you can also use the 'options' argument to provide the access key + // and secret key to be used for authentication purposes for this file by using a + // string of the form "AUTH=myAccessKey:mySecretkey". This may be useful to + // open several files hosted by different providers in the same program/macro, + // where the environemntal variables solution is not convenient (see below). + // + // If you need to specify both NOPROXY and AUTH separate them by ' ' + // (blank), for instance: + // "NOPROXY AUTH=F38XYZABCDeFgH4D0E1F:V+frt4re7J1euSNFnmaf8wwmI4AAAE7kzxZ/TTM+" + // + // Examples: + // TFile* f1 = TFile::Open("s3://host.example.com/bucket/path/to/my/file", + // "NOPROXY AUTH=F38XYZABCDeFgH4D0E1F:V+frt4re7J1euSNFnmaf8wwmI4AAAE7kzxZ/TTM+"); + // TFile* f2 = TFile::Open("s3://host.example.com/bucket/path/to/my/file", + // "AUTH=F38XYZABCDeFgH4D0E1F:V+frt4re7J1euSNFnmaf8wwmI4AAAE7kzxZ/TTM+"); + // + // If there is no authentication information in the 'options' argument + // (i.e. not AUTH="....") the values of the environmental variables + // S3_ACCESS_KEY and S3_SECRET_KEY (if set) are expected to contain + // the access key id and the secret access key, respectively. You have + // been provided with these credentials by your S3 service provider. + // + // If neither the AUTH information is provided in the 'options' argument + // nor the environmental variables are set, we try to open the file + // without providing any authentication information to the server. This + // is useful when the file is set an access control that allows for + // any unidentified user to read the file. + + // Make sure this is a valid S3 path. We accept 'as3' as a scheme, for + // backwards compatibility + Bool_t doMakeZombie = kFALSE; + TString errorMsg; + TString accessKey; + TString secretKey; + TPMERegexp rex("^([a]?s3|s3http[s]?|gs|gshttp[s]?){1}://([^/]+)/([^/]+)/([^/].*)", "i"); + if (rex.Match(TString(path)) != 5) { + errorMsg = TString::Format("invalid S3 path '%s'", path); + doMakeZombie = kTRUE; + } + else if (!ParseOptions(options, accessKey, secretKey)) { + errorMsg = TString::Format("could not parse options '%s'", options); + doMakeZombie = kTRUE; + } + + // Should we stop initializing this object? + if (doMakeZombie) { + Error("TS3WebFile", "%s", (const char*)errorMsg); + MakeZombie(); + gDirectory = gROOT; + return; + } + + // Set this S3 object's URL, the bucket name this file is located in + // and the object key + fS3Request.SetBucket(rex[3]); + fS3Request.SetObjectKey(TString::Format("/%s", (const char*)rex[4])); + + // Initialize super-classes data members (fUrl is a data member of + // super-super class TFile) + TString protocol = "https"; + if (rex[1].EndsWith("http", TString::kIgnoreCase) || + rex[1].EqualTo("as3", TString::kIgnoreCase)) + protocol = "http"; + fUrl.SetUrl(TString::Format("%s://%s/%s/%s", (const char*)protocol, + (const char*)rex[2], (const char*)rex[3], (const char*)rex[4])); + + // Set S3-specific data members. If the access and secret keys are not + // provided in the 'options' argument we look in the environmental + // variables. + const char* kAccessKeyEnv = "S3_ACCESS_KEY"; + const char* kSecretKeyEnv = "S3_SECRET_KEY"; + if (accessKey.IsNull()) + GetCredentialsFromEnv(kAccessKeyEnv, kSecretKeyEnv, accessKey, secretKey); + + // Initialize the S3 HTTP request + fS3Request.SetHost(fUrl.GetHost()); + if (accessKey.IsNull() || secretKey.IsNull()) { + // We have no authentication information, neither in the options + // nor in the enviromental variables. So may be this is a + // world-readable file, so let's continue and see if + // we can open it. + fS3Request.SetAuthType(TS3HTTPRequest::kNoAuth); + } else { + // Set the authentication information we need to use + // for this file + fS3Request.SetAuthKeys(accessKey, secretKey); + if (rex[1].BeginsWith("gs")) + fS3Request.SetAuthType(TS3HTTPRequest::kGoogle); + else + fS3Request.SetAuthType(TS3HTTPRequest::kAmazon); + } + + // Assume this server does not serve multi-range HTTP GET requests. We + // will detect this when the HTTP headers of this files are retrieved + // later in the initialization process + fUseMultiRange = kFALSE; + + // Call super-class initializer + TWebFile::Init(kFALSE); + + // Were there some errors opening this file? + if (IsZombie() && (accessKey.IsNull() || secretKey.IsNull())) { + // We could not open the file and we have no authentication information + // so inform the user so that he can check. + Error("TS3WebFile", "could not find authentication info in "\ + "'options' argument and at least one of the environment variables '%s' or '%s' is not set", + kAccessKeyEnv, kSecretKeyEnv); + } +} + + +//_____________________________________________________________________________ +Bool_t TS3WebFile::ParseOptions(Option_t* options, TString& accessKey, TString& secretKey) +{ + // Extracts the S3 authentication key pair (access key and secret key) + // from the options. The authentication credentials can be specified in + // the options provided to the constructor of this class as a string + // containing: "AUTH=<access key>:<secret key>" and can include other + // options, for instance "NOPROXY" for not using the HTTP proxy for + // accessing this file's contents. + // For instance: + // "NOPROXY AUTH=F38XYZABCDeFgHiJkLm:V+frt4re7J1euSNFnmaf8wwmI401234E7kzxZ/TTM+" + + TString optStr = (const char*)options; + if (optStr.IsNull()) + return kTRUE; + + fNoProxy = kFALSE; + if (optStr.Contains("NOPROXY", TString::kIgnoreCase)) + fNoProxy = kTRUE; + CheckProxy(); + + // Look in the options string for the authentication information. + TPMERegexp rex("(^AUTH=|^.* AUTH=)([a-z0-9]+):([a-z0-9+/]+)[\\s]*.*$", "i"); + if (rex.Match(optStr) < 4) { + Error("ParseOptions", "expecting options of the form \"AUTH=myAccessKey:mySecretKey\""); + return kFALSE; + } + accessKey = rex[2]; + secretKey = rex[3]; + if (gDebug > 0) + Info("ParseOptions", "using authentication information from 'options' argument"); + return kTRUE; +} + + +//_____________________________________________________________________________ +Int_t TS3WebFile::GetHead() +{ + // Overwrites TWebFile::GetHead() for retrieving the HTTP headers of this + // file. Uses TS3HTTPRequest to generate an HTTP HEAD request which includes + // the authorization header expected by the S3 server. + fMsgGetHead = fS3Request.GetRequest(TS3HTTPRequest::kHEAD); + return TWebFile::GetHead(); +} + + +//_____________________________________________________________________________ +void TS3WebFile::SetMsgReadBuffer10(const char* redirectLocation, Bool_t tempRedirect) +{ + // Overwrites TWebFile::SetMsgReadBuffer10() for setting the HTTP GET + // request compliant to the authentication mechanism used by the S3 + // protocol. The GET request must contain an "Authorization" header with + // the signature of the request, generated using the user's secret access + // key. + + TWebFile::SetMsgReadBuffer10(redirectLocation, tempRedirect); + fMsgReadBuffer10 = fS3Request.GetRequest(TS3HTTPRequest::kGET, kFALSE) + "Range: bytes="; + return; +} + + +//_____________________________________________________________________________ +Bool_t TS3WebFile::ReadBuffers(char* buf, Long64_t* pos, Int_t* len, Int_t nbuf) +{ + + // Overwrites TWebFile::ReadBuffers() for reading specified byte ranges. + // According to the kind of server this file is hosted by, we use a + // single HTTP request with a muti-range header or we generate multiple + // requests with a single range each. + + // Does this server support multi-range GET requests? + if (fUseMultiRange) + return TWebFile::ReadBuffers(buf, pos, len, nbuf); + + // Send multiple GET requests with a single range of bytes + // Adapted from original version by Wang Lu + for (Int_t i=0, offset=0; i < nbuf; i++) { + TString rangeHeader = TString::Format("Range: bytes=%lld-%lld\r\n\r\n", + pos[i], pos[i] + len[i] - 1); + TString s3Request = fS3Request.GetRequest(TS3HTTPRequest::kGET, kFALSE) + rangeHeader; + if (GetFromWeb10(&buf[offset], len[i], s3Request) == -1) + return kTRUE; + offset += len[i]; + } + return kFALSE; +} + + +//_____________________________________________________________________________ +void TS3WebFile::ProcessHttpHeader(const TString& headerLine) +{ + // This method is called by the super-class TWebFile when a HTTP header + // for this file is retrieved. We scan the 'Server' header to detect the + // type of S3 server this file is hosted on and to determine if it is + // known to support multi-range HTTP GET requests. Some S3 servers (for + // instance Amazon's) do not support that feature and when they + // receive a multi-range request they sent back the whole file contents. + // For this class, if the server do not support multirange requests + // we issue multiple single-range requests instead. + + TPMERegexp rex("^Server: (.+)", "i"); + if (rex.Match(headerLine) != 2) + return; + + // Extract the identity of this server and compare it to the + // identify of the servers known to support multi-range requests. + // The list of server identities is expected to be found in ROOT + // configuration. + TString serverId = rex[1].ReplaceAll("\r", "").ReplaceAll("\n", ""); + TString multirangeServers(gEnv->GetValue("TS3WebFile.Root.MultiRangeServer", "")); + fUseMultiRange = multirangeServers.Contains(serverId, TString::kIgnoreCase) ? kTRUE : kFALSE; +} + + +//_____________________________________________________________________________ +Bool_t TS3WebFile::GetCredentialsFromEnv(const char* accessKeyEnv, const char* secretKeyEnv, + TString& outAccessKey, TString& outSecretKey) +{ + // Sets the access and secret keys from the environmental variables, if + // they are both set. + + // Look first in the recommended environmental variables. Both variables + // must be set. + TString accKey = gSystem->Getenv(accessKeyEnv); + TString secKey = gSystem->Getenv(secretKeyEnv); + if (!accKey.IsNull() && !secKey.IsNull()) { + outAccessKey = accKey; + outSecretKey = secKey; + if (gDebug > 0) + Info("GetCredentialsFromEnv", "using authentication information from environmental variables '%s' and '%s'", + accessKeyEnv, secretKeyEnv); + return kTRUE; + } + + // Look now in the legacy environmental variables, for keeping backwards + // compatibility. + accKey = gSystem->Getenv("S3_ACCESS_ID"); // Legacy access key + secKey = gSystem->Getenv("S3_ACCESS_KEY"); // Legacy secret key + if (!accKey.IsNull() && !secKey.IsNull()) { + Warning("SetAuthKeys", "usage of S3_ACCESS_ID and S3_ACCESS_KEY environmental variables is deprecated."); + Warning("SetAuthKeys", "please use S3_ACCESS_KEY and S3_SECRET_KEY environmental variables."); + outAccessKey = accKey; + outSecretKey = secKey; + return kTRUE; + } + + return kFALSE; +} + diff --git a/net/net/src/TSQLServer.cxx b/net/net/src/TSQLServer.cxx index 60905b1ed89e0..62d5b70c0e5c6 100644 --- a/net/net/src/TSQLServer.cxx +++ b/net/net/src/TSQLServer.cxx @@ -21,6 +21,12 @@ // mysql://pcroot.cern.ch:3456/test, oracle://srv1.cern.ch/main, ... // // Depending on the <dbms> specified an appropriate plugin library // // will be loaded which will provide the real interface. // +// For SQLite, the syntax is slightly different: // +// sqlite://<database> // +// The string 'database' is directly passed to sqlite3_open(_v2), // +// so e.g. a filename or ":memory:" are possible values. // +// For SQLite versions >= 3.7.7, SQLITE_OPEN_URI is activated to also // +// allow URI-parameters if needed. // // // // Related classes are TSQLResult and TSQLRow. // // // @@ -132,7 +138,7 @@ void TSQLServer::SetError(Int_t code, const char* msg, const char* method) Bool_t TSQLServer::StartTransaction() { // submit "START TRANSACTION" query to database - // return kTRUE, if succesfull + // return kTRUE, if successful return Exec("START TRANSACTION"); } @@ -141,7 +147,7 @@ Bool_t TSQLServer::StartTransaction() Bool_t TSQLServer::Commit() { // submit "COMMIT" query to database - // return kTRUE, if succesfull + // return kTRUE, if successful return Exec("COMMIT"); } @@ -150,7 +156,7 @@ Bool_t TSQLServer::Commit() Bool_t TSQLServer::Rollback() { // submit "ROLLBACK" query to database - // return kTRUE, if succesfull + // return kTRUE, if successful return Exec("ROLLBACK"); } diff --git a/net/net/src/TSQLStatement.cxx b/net/net/src/TSQLStatement.cxx index 4d15f476d7cdb..2eff8cd516ce2 100644 --- a/net/net/src/TSQLStatement.cxx +++ b/net/net/src/TSQLStatement.cxx @@ -10,36 +10,36 @@ *************************************************************************/ //////////////////////////////////////////////////////////////////////////////// -// -// TSQLStatement -// +// +// TSQLStatement +// // Abstract base class defining SQL statements, which can be submitted // in bulk to DB server. -// +// // This is alternative to TSQLServer::Query() method, which allows only pure // text queries and pure text result in TSQLResult classes. // TSQLStatement is designed to support following features: -// - usage of basic data type (like int or double) as parameters +// - usage of basic data types (like int or double) as parameters // in SQL statements -// - bulk operation when inserting/updating/selecting data in data base +// - bulk operation when inserting/updating/selecting data in database // - uasge of basic data types when accessing result set of executed query // // // 1. Creation of statement // ====================================== -// To create instance of TSQLStatement class, TSQLServer::Statement() method -// should be used. Depending of the driver, used for connection to ODBC, -// appropriate object instance will be created. For the moment there are -// three different implementation of TSQLStatement class: for MySQL, -// Oracle and ODBC. Hopefully, support of ODBC will allows usage of -// statements for most existing RDBMS. -// -// // first connect to data base +// To create an instance of the TSQLStatement class, the TSQLServer::Statement() method +// should be used. Depending on the driver used for an ODBC connection, +// the appropriate object instance will be created. For the moment there are +// six different implementations of the TSQLStatement class: for MySQL, +// Oracle, SAPDB, PostgreSQL, SQLite3 and ODBC. Hopefully, support of ODBC will allow usage of +// statements for most existing RDBMS. +// +// // first, connect to the database // TSQLServer* serv = TSQLServer::Connect("mysql://hostname.domain:3306/test", // "user", "pass"); // // check if connection is ok // if ((serv!=0) && serv->IsConnected()) { -// // create statement instance +// // create instance of sql-statement // TSQLStatement* stmt = serv->Statement("CREATE TABLE TESTTABLE (ID1 INT, ID2 INT, FFIELD VARCHAR(255), FVALUE VARCHAR(255))"; // // process statement // stmt->Process(); @@ -51,105 +51,117 @@ // // 2. Insert data to data base // =============================================== -// There is a special syntax of SQL queries, which allow to use values, -// provided as parameters. For instance, insert one row in TESTTABLE, created -// with previous example, one can simply execute query like: -// +// There is a special syntax of SQL queries which allows to use values +// provided as parameters. For instance, to insert one row into the TESTTABLE created +// with the previous example, one can simply execute a query like: +// // serv->Query("INSERT INTO TESTTABLE VALUES (1, 2, \"name1\", \"value1\""); // -// But when many (100-1000) rows should be inserted, each call of +// However, when many (100-1000) rows should be inserted, each call of // TSQLServer::Query() method will cause communication loop with database -// server. As a result, insertion of data will takes too much time. +// server, and the statement has to be evaluated each time instead of using a prepared statement. +// As a result, insertion of data takes too much time. // -// TSQLStatement provides a mechanism to insert many rows at once. First of all, -// appropriate statement should be created: +// TSQLStatement provides a mechanism to insert many rows at once. +// First of all, an appropriate statement should be created: // // TSQLStatement* stmt = serv->Statement("INSERT INTO TESTTABLE (ID1, ID2, FFIELD, FVALUE) VALUES (?, ?, ?, ?)", 100); // -// Here question marks "?" indicates where statement parameters can be inserted. +// Here question marks "?" indicate where statement parameters can be inserted. // To specify values of parameters, SetInt(), SetDouble(), SetString() and other -// methods of TSQLStatement class should be used. Before parameters values -// can be specified, NextIteration() method of statement class should be called. -// For each new row first, NextIteration() called, that parameters values are -// specified. There is one limitation - once parameter set as integer via -// SetInt(), for all other rows should be specified as integer. At the end, +// methods of the TSQLStatement class should be used. Before parameters values +// can be specified, the NextIteration() method of statement class should be called. +// For each new row, NextIteration() has to be called first, then parameters values are +// specified. There is one limitation for most type-aware DBMS - once a parameter is set as integer via +// SetInt(), all other rows should be specified as integer. At the end, // TSQLStatement::Process() should be called. Here a small example: // -// // first, create statement +// // first, create statement // TSQLStatement* stmt = serv->Statement("INSERT INTO TESTTABLE (ID1, ID2, FFIELD, FVALUE) VALUES (?, ?, ?, ?)", 100); // -// for (int n=0;n<357;n++) +// for (int n=0;n<357;n++) // if (stmt->NextIteration()) { // stmt->SetInt(0, 123); // stmt->SetUInt(1, n+10); // stmt->SetString(2, Form("name %d",n), 200); // stmt->SetString(3, Form("value %d", n+10), 200); // } -// +// // stmt->Process(); // delete stmt; // -// Second argument in TSQLServer::Statement() method specifies depth of -// of buffers, used to keep parameter values (100 in example). It is not -// a limitation of rows number, which can be inserted with the statement. +// The second argument in the TSQLServer::Statement() method specifies the depth of +// of buffers which are used to keep parameter values (100 in the example). It is not +// a limitation of the number of rows which can be inserted with the statement. // When buffers are filled, they will be submitted to database and can be -// reused again. This happens transparent to the user in NextIteration() +// reused again. This happens transparent to the user in the NextIteration() // method. // // Oracle and some ODBC drivers support buffering of parameter values and, // as a result, bulk insert (update) operation. MySQL (native driver and -// MyODBC 3) does not support such mode of operation, therefore adding -// new rows will result in communication loop to database. +// MyODBC 3) does not support such a mode of operation, therefore adding +// new rows will result in communication loop to database. // -// One should also mention difference between Oracle and ODBC SQL syntax for -// parameters. ODBC (and MySQL) uses question marks to specify position, +// Local databases (SQLite3) do not use any buffering at all in the TSQLStatement +// implementation (but inside the library). They still profit from the +// usage of prepared statements. When inserting many rows into a SQLite3 database, +// consider using a transaction via the methods StartTransaction() and Commit() +// of the TSQLServer, as autocommit is active by default and causes a sync to disk +// after each single insert. +// +// One should also mention differences between Oracle and ODBC SQL syntax for +// parameters. ODBC (and MySQL) use question marks to specify the position // where parameters should be inserted (as shown in the example). Oracle uses -// :1, :2 and so on marks for specify position of parameter 0, 1, and so on. -// Therefore, similar to example query will look like: +// :1, :2 and so on as marks to specify the position of parameter 0, 1, and so on. +// Therefore, similar to the example, a query will look like: // // TSQLStatement* stmt = serv->Statement("INSERT INTO TESTTABLE (ID1, ID2, FFIELD, FVALUE) VALUES (:1, :2, :3, :4)", 100); -// -// There is a possibility to set parameter value to NULL with SetNull() method. -// If this method called for first iteration, before one should call other Set... -// to identify actual parameter type, which will be used for parameter later. +// +// SQLite3 supports both these syntaxes and some more. +// +// There is a possibility to set a parameter value to NULL with the SetNull() method. +// If this method is to be called for the first iteration, one should first call another Set... +// method to identify the actual type which will be used for the parameter later. // // // 3. Getting data from database // ============================= -// To request data from data base, SELECT statement should be used. -// After SELECT statement is created, it must be processed -// (with TSQLStatement::Process()) method and result of statement -// should be stored in internal buffers with TSQLStatement::StoreResult() -// method. Information about selected fields (columns) -// can be obtained with GetNumFields() and GetFieldName() methods. -// To recieve data for next result row, NextResultRow() method should be called. -// Value from each column can be taken with the GetInt(), GetDouble(), -// GetString() and other methods. -// -// There are no strict limitation which method should be used -// to get column values. GetString() can be used as generic method, -// which should always return correct result, but also convertion between most -// basic data types are supported. For instance, if column contains integer +// To request data from a database, the SELECT statement should be used. +// After a SELECT statement is created, it must be processed +// with the TSQLStatement::Process() method and the result of statement +// should be stored in internal buffers with the method TSQLStatement::StoreResult(). +// Information about selected fields (columns) +// can be obtained with GetNumFields() and GetFieldName() methods. +// To receive data for the next result row, NextResultRow() method should be called. +// Value from each column can be retrieved with the GetInt(), GetDouble(), +// GetString() and other methods. +// +// There are no strict limitations on which method should be used +// to get column values. GetString() can be used as a generic method, +// which should always return correct result, but also conversions between most +// basic data types are supported. For instance, if a column contains integer // values, GetInt(), GetLong64(), GetDouble() and GetString() methods can be used. -// If column has float point format, GetDouble() and GetString() methods can +// If column has floating point format, GetDouble() and GetString() methods can // be used without loss of precision while GetInt() or GetLong64() will return -// integer part of the value. One also can test, if value is NULL with IsNull() -// method. +// only the integer part of the value. One also can test whether +// a value is NULL with the IsNull() method. // -// Buffer length, specified for statement in TSQLServer::Statement() call, +// The buffer length specified for a statement in the TSQLServer::Statement() call // will also be used to allocate buffers for column values. Usage of these -// buffers is transparent for users and does not limit number of rows, -// which can be accessed with one statement. Example of select query: +// buffers is transparent for users and does not limit the number of rows +// which can be accessed with one statement. Again, local databases do not work +// with buffers inside TSQLStatement at all and ignore this value. +// Example of select query: // // stmt = serv->Statement("SELECT * FROM TESTTABLE", 100); // // process statement // if (stmt->Process()) { -// // store result of statement in buffer +// // store result of statement in buffer // stmt->StoreResult(); -// -// // display info about selected field +// +// // display info about selected field // cout << "NumFields = " << stmt->GetNumFields() << endl; -// for (int n=0;n<stmt->GetNumFields();n++) +// for (int n=0;n<stmt->GetNumFields();n++) // cout << "Field " << n << " = " << stmt->GetFieldName(n) << endl; // // // extract rows one after another @@ -160,43 +172,54 @@ // const char* name2 = stmt->GetString(3); // cout << id1 << " - " << id2 << " " << name1 << " " << name2 << endl; // } -// } +// } // // 4. Working with date/time parameters // ==================================== -// Current implementation supports date, time, date&time and timestamp -// data (all time intervals not supported yet). To set or get date/time values, -// following methods should be used: -// SetTime()/GetTime() - only time (hour:min:sec), -// SetDate()/GetDate() - only date (year-month-day), -// SetDatime()/GetDatime() - date and time +// The current implementation supports date, time, date&time and timestamp +// data (all time intervals are not supported yet). To set or get date/time values, +// the following methods should be used: +// SetTime()/GetTime() - only time (hour:min:sec), +// SetDate()/GetDate() - only date (year-month-day), +// SetDatime()/GetDatime() - date and time // SetTimestamp()/GetTimestamp() - timestamp with seconds fraction // For some of these methods TDatime type can be used as parameter / return value. -// Be aware, that TDatime supports only dates after 1995-01-01. -// There are also methods to get separately year, month, day, hour, minutes and seconds. +// Be aware that TDatime supports only dates after 1995-01-01. +// There are also methods to get year, month, day, hour, minutes and seconds separately. // -// Different SQL databases has different treatement of date/time types. +// Note that different SQL databases treat date/time types differently. // For instance, MySQL has all correspondent types (TIME, DATE, DATETIME and TIMESTAMP), // Oracle native driver supports only DATE (which is actually date and time) and TIMESTAMP -// ODBC interface provides access for time, date and timestamps. -// Therefore, one should use correct methods to access such data. -// For instance, in MySQL SQL type 'DATE' is only date (one should use GetDate() to -// access such data), while in Oracle it is date and time. Therefore, -// to get complete data from 'DATE' column in Oracle, one should use GetDatime() method. +// ODBC interface provides access for time, date and timestamps, +// for PostgreSQL, TIMESTAMP is available and can be retrieved via all methods, +// the implementation for SQLite interprets the column content as +// a timestamp with second fraction. +// Due to these differences, one should use correct methods to access such data. +// For instance, in MySQL SQL type 'DATE' is only date (one should use GetDate() to +// access such data), while in Oracle it is date and time. Therefore, +// to get complete data from a 'DATE' column in Oracle, one should use the GetDatime() method. // -// The only difference of timestamp from date/time, that it has fractional -// seconds part. Be aware, that fractional part can has different meaning -// (actual value) in different SQL plugins. +// The only difference between timestamp and date/time is that timestamp has a fractional +// seconds part. Be aware that the fractional part has different meanings +// (actual value) in different SQL plugins. +// For PostgreSQL, it is given back as microseconds, while for SQLite3, +// milliseconds correspond to the fraction (similar to the DATETIME-functions +// implemented in the SQLite3 language). // // 5. Binary data // ============== -// Most of modern data bases support just binary data, which is +// Most modern data bases support just binary data, which is // typically has SQL type name 'BLOB'. To access data in such -// columns, GetBinary()/SetBinary() methods should be used. -// Current implementation supposed, that complete content of the -// column must be retrieved at once. Therefore very big data of +// columns, GetBinary()/SetBinary() methods should be used. +// The current implementation implies that the complete content of the +// column must be retrieved at once. Therefore, very big data of // gigabytes size may cause a problem. // +// In addition, for PostgresSQL, the methods GetLargeObject()/SetLargeObject() +// are implemented with similar syntax. They retrieve a large object for the OID +// given in the column of the statement. For non-PostgreSQL databases, +// calling GetLargeObject()/SetLargeObject() is redirected to GetBinary()/SetBinary(). +// //////////////////////////////////////////////////////////////////////////////// #include "TSQLStatement.h" @@ -209,7 +232,7 @@ Int_t TSQLStatement::GetErrorCode() const // returns error code of last operation // if res==0, no error // Each specific implementation of TSQLStatement provides its own error coding - + return fErrorCode; } @@ -219,7 +242,7 @@ const char* TSQLStatement::GetErrorMsg() const // returns error message of last operation // if no errors, return 0 // Each specific implementation of TSQLStatement provides its own error messages - + return GetErrorCode()==0 ? 0 : fErrorMsg.Data(); } @@ -227,7 +250,7 @@ const char* TSQLStatement::GetErrorMsg() const void TSQLStatement::ClearError() { // reset error fields - + fErrorCode = 0; fErrorMsg = ""; } @@ -237,7 +260,7 @@ void TSQLStatement::SetError(Int_t code, const char* msg, const char* method) { // set new values for error fields // if method specified, displays error message - + fErrorCode = code; fErrorMsg = msg; if ((method!=0) && fErrorOut) @@ -248,7 +271,7 @@ void TSQLStatement::SetError(Int_t code, const char* msg, const char* method) Bool_t TSQLStatement::SetDate(Int_t npar, const TDatime& tm) { // set only date value for specified parameter from TDatime object - + return SetDate(npar, tm.GetYear(), tm.GetMonth(), tm.GetDay()); } @@ -256,7 +279,7 @@ Bool_t TSQLStatement::SetDate(Int_t npar, const TDatime& tm) Bool_t TSQLStatement::SetTime(Int_t npar, const TDatime& tm) { // set only time value for specified parameter from TDatime object - + return SetTime(npar, tm.GetHour(), tm.GetMinute(), tm.GetSecond()); } @@ -264,7 +287,7 @@ Bool_t TSQLStatement::SetTime(Int_t npar, const TDatime& tm) Bool_t TSQLStatement::SetDatime(Int_t npar, const TDatime& tm) { // set date & time value for specified parameter from TDatime object - + return SetDatime(npar, tm.GetYear(), tm.GetMonth(), tm.GetDay(), tm.GetHour(), tm.GetMinute(), tm.GetSecond()); } @@ -273,7 +296,7 @@ Bool_t TSQLStatement::SetDatime(Int_t npar, const TDatime& tm) Bool_t TSQLStatement::SetTimestamp(Int_t npar, const TDatime& tm) { // set timestamp value for specified parameter from TDatime object - + return SetTimestamp(npar, tm.GetYear(), tm.GetMonth(), tm.GetDay(), tm.GetHour(), tm.GetMinute(), tm.GetSecond(), 0); } @@ -282,26 +305,26 @@ Bool_t TSQLStatement::SetTimestamp(Int_t npar, const TDatime& tm) TDatime TSQLStatement::GetDatime(Int_t npar) { // return value of parameter in form of TDatime - // Be aware, that TDatime does not allow dates before 1995-01-01 - + // Be aware, that TDatime does not allow dates before 1995-01-01 + Int_t year, month, day, hour, min, sec; - + if (!GetDatime(npar, year, month, day, hour, min, sec)) return TDatime(); - + if (year<1995) { SetError(-1, "Date before year 1995 does not supported by TDatime type", "GetDatime"); return TDatime(); } - + return TDatime(year, month, day, hour, min, sec); } //______________________________________________________________________________ Int_t TSQLStatement::GetYear(Int_t npar) { - // return year value for parameter (if applicable) - + // return year value for parameter (if applicable) + Int_t year, month, day, hour, min, sec, frac; if (GetDate(npar, year, month, day)) return year; if (GetTimestamp(npar, year, month, day, hour, min, sec, frac)) return year; @@ -311,7 +334,7 @@ Int_t TSQLStatement::GetYear(Int_t npar) //______________________________________________________________________________ Int_t TSQLStatement::GetMonth(Int_t npar) { - // return month value for parameter (if applicable) + // return month value for parameter (if applicable) Int_t year, month, day, hour, min, sec, frac; if (GetDate(npar, year, month, day)) return month; @@ -322,7 +345,7 @@ Int_t TSQLStatement::GetMonth(Int_t npar) //______________________________________________________________________________ Int_t TSQLStatement::GetDay(Int_t npar) { - // return day value for parameter (if applicable) + // return day value for parameter (if applicable) Int_t year, month, day, hour, min, sec, frac; if (GetDate(npar, year, month, day)) return day; @@ -333,7 +356,7 @@ Int_t TSQLStatement::GetDay(Int_t npar) //______________________________________________________________________________ Int_t TSQLStatement::GetHour(Int_t npar) { - // return hours value for parameter (if applicable) + // return hours value for parameter (if applicable) Int_t year, month, day, hour, min, sec, frac; if (GetTime(npar, hour, min, sec)) return hour; @@ -344,7 +367,7 @@ Int_t TSQLStatement::GetHour(Int_t npar) //______________________________________________________________________________ Int_t TSQLStatement::GetMinute(Int_t npar) { - // return minutes value for parameter (if applicable) + // return minutes value for parameter (if applicable) Int_t year, month, day, hour, min, sec, frac; if (GetTime(npar, hour, min, sec)) return min; @@ -355,7 +378,7 @@ Int_t TSQLStatement::GetMinute(Int_t npar) //______________________________________________________________________________ Int_t TSQLStatement::GetSecond(Int_t npar) { - // return seconds value for parameter (if applicable) + // return seconds value for parameter (if applicable) Int_t year, month, day, hour, min, sec, frac; if (GetTime(npar, hour, min, sec)) return sec; @@ -367,18 +390,18 @@ Int_t TSQLStatement::GetSecond(Int_t npar) TDatime TSQLStatement::GetTimestamp(Int_t npar) { // return value of parameter in form of TDatime - // Be aware, that TDatime does not allow dates before 1995-01-01 - + // Be aware, that TDatime does not allow dates before 1995-01-01 + Int_t year, month, day, hour, min, sec, frac; - + if (!GetTimestamp(npar, year, month, day, hour, min, sec, frac)) return TDatime(); - + if (year<1995) { SetError(-1, "Date before year 1995 does not supported by TDatime type", "GetTimestamp"); return TDatime(); } - + return TDatime(year, month, day, hour, min, sec); } diff --git a/net/net/src/TSSLSocket.cxx b/net/net/src/TSSLSocket.cxx index 31919300c4c1f..533d37dca46d5 100644 --- a/net/net/src/TSSLSocket.cxx +++ b/net/net/src/TSSLSocket.cxx @@ -38,40 +38,40 @@ void TSSLSocket::WrapWithSSL(void) // New context if (!(fSSLCtx = SSL_CTX_new(SSLv23_method()))) { - Error("TSSLSocket::WrapWithSSL()", "the context could not be created"); + Error("WrapWithSSL", "the context could not be created"); goto wrapFailed; } if ((fgSSLCAFile[0] || fgSSLCAPath[0]) && SSL_CTX_load_verify_locations(fSSLCtx, fgSSLCAFile, fgSSLCAPath) == 0) { - Error("TSSLSocket::WrapWithSSL", "Could not set the CA file and/or the CA path"); + Error("WrapWithSSL", "could not set the CA file and/or the CA path"); goto wrapFailed; } if (fgSSLUCert[0] && SSL_CTX_use_certificate_chain_file(fSSLCtx, fgSSLUCert) == 0) { - Error("TSSLSocket::WrapWithSSL", "Could not set the client certificate"); + Error("WrapWithSSL", "could not set the client certificate"); goto wrapFailed; } if (fgSSLUKey[0] && SSL_CTX_use_PrivateKey_file(fSSLCtx, fgSSLUKey, SSL_FILETYPE_PEM) == 0) { - Error("TSSLSocket::WrapWithSSL", "Could not set the client private key"); + Error("WrapWithSSL", "could not set the client private key"); goto wrapFailed; } // New SSL structure if (!(fSSL = SSL_new(fSSLCtx))) { - Error("TSSLSocket::WrapWithSSL()", "cannot create the ssl struct"); + Error("WrapWithSSL", "cannot create the ssl struct"); goto wrapFailed; } // Bind to the socket if (SSL_set_fd(fSSL, fSocket) != 1) { - Error("TSSLSocket::WrapWithSSL()", "cannot bind to the socket %d", fSocket); + Error("WrapWithSSL", "cannot bind to the socket %d", fSocket); goto wrapFailed; } // Open connection if (SSL_connect(fSSL) != 1) { - Error("TSSLSocket::WrapWithSSL()", "cannot connect"); + Error("WrapWithSSL", "cannot connect"); goto wrapFailed; } @@ -178,7 +178,7 @@ void TSSLSocket::SetUpSSL(const char *cafile, const char *capath, //______________________________________________________________________________ Int_t TSSLSocket::Recv(TMessage *& /*mess */) { - Error("TSSLSocket::Recv(TMessage*&)", "Not implemented"); + Error("Recv", "not implemented"); return -1; } @@ -195,34 +195,54 @@ Int_t TSSLSocket::RecvRaw(void *buffer, Int_t length, ESendRecvOptions opt) ResetBit(TSocket::kBrokenConn); Int_t n; - - if (opt == kPeek) - n = SSL_peek(fSSL, buffer, (int)length); - else - n = SSL_read(fSSL, buffer, (int)length); - - if (n <= 0) { - if (SSL_get_error(fSSL, n) == SSL_ERROR_ZERO_RETURN || SSL_get_error(fSSL, n) == SSL_ERROR_SYSCALL) { - // Connection closed, reset or broken - SetBit(TSocket::kBrokenConn); - SSL_set_quiet_shutdown(fSSL, 1); // Socket is gone, sending "close notify" will fail - Close(); - } - return n; + Int_t offset = 0; + Int_t remain = length; + + // SSL_read/SSL_peek may not return the total length at once + while (remain > 0) { + if (opt == kPeek) + n = SSL_peek(fSSL, (char*)buffer + offset, (int)remain); + else + n = SSL_read(fSSL, (char*)buffer + offset, (int)remain); + + if (n <= 0) { + if (gDebug > 0) + Error("RecvRaw", "failed to read from the socket"); + + if (SSL_get_error(fSSL, n) == SSL_ERROR_ZERO_RETURN || SSL_get_error(fSSL, n) == SSL_ERROR_SYSCALL) { + // Connection closed, reset or broken + SetBit(TSocket::kBrokenConn); + SSL_set_quiet_shutdown(fSSL, 1); // Socket is gone, sending "close notify" will fail + Close(); + } + return n; + } + + // When peeking, just return the available data, don't loop. Otherwise, + // we may copy the same chunk of data multiple times into the + // output buffer, for instance when there is no more recent data + // in the socket's internal reception buffers. + // Note that in this case we don't update the counters of data received + // through this socket. They will be updated when the data is actually + // read. This avoids double counting. + if (opt == kPeek) return n; + + offset += n; + remain -= n; } - fBytesRecv += n; - fgBytesRecv += n; + fBytesRecv += length; + fgBytesRecv += length; Touch(); // update usage timestamp - return n; + return offset; } //______________________________________________________________________________ Int_t TSSLSocket::Send(const TMessage & /* mess */) { - Error("TSSLSocket::Send(TMessage*&)", "Not implemented"); + Error("Send", "not implemented"); return -1; } diff --git a/net/net/src/TSocket.cxx b/net/net/src/TSocket.cxx index e1e1b28cf6b52..dcc31c17ab269 100644 --- a/net/net/src/TSocket.cxx +++ b/net/net/src/TSocket.cxx @@ -385,7 +385,7 @@ void TSocket::Close(Option_t *option) // Close the socket. If option is "force", calls shutdown(id,2) to // shut down the connection. This will close the connection also // for the parent of this process. Also called via the dtor (without - // option "force", call explicitely Close("force") if this is desired). + // option "force", call explicitly Close("force") if this is desired). Bool_t force = option ? (!strcmp(option, "force") ? kTRUE : kFALSE) : kFALSE; @@ -1304,7 +1304,7 @@ TSocket *TSocket::CreateAuthSocket(const char *url, Int_t size, Int_t tcpwindows R__LOCKGUARD2(gSocketAuthMutex); - // Url to be passed to choosen constructor + // Url to be passed to chosen constructor TString eurl(url); // Parse protocol, if any diff --git a/net/net/src/TUDPSocket.cxx b/net/net/src/TUDPSocket.cxx index 8b9edc4d8191f..42917d06f34e3 100755 --- a/net/net/src/TUDPSocket.cxx +++ b/net/net/src/TUDPSocket.cxx @@ -356,7 +356,7 @@ void TUDPSocket::Close(Option_t *option) // Close the socket. If option is "force", calls shutdown(id,2) to // shut down the connection. This will close the connection also // for the parent of this process. Also called via the dtor (without - // option "force", call explicitely Close("force") if this is desired). + // option "force", call explicitly Close("force") if this is desired). Bool_t force = option ? (!strcmp(option, "force") ? kTRUE : kFALSE) : kFALSE; diff --git a/net/net/src/TWebFile.cxx b/net/net/src/TWebFile.cxx index 3cec487e51851..9e459d318d66b 100644 --- a/net/net/src/TWebFile.cxx +++ b/net/net/src/TWebFile.cxx @@ -310,6 +310,8 @@ void TWebFile::SetMsgReadBuffer10(const char *redirectLocation, Bool_t tempRedir fBasicUrl += fUrl.GetPort(); fBasicUrl += "/"; fBasicUrl += fUrl.GetFile(); + fBasicUrl += "?"; + fBasicUrl += fUrl.GetOptions(); } if (fMsgReadBuffer10 == "") { @@ -354,6 +356,8 @@ void TWebFile::CheckProxy() return; } fProxy = p; + if (gDebug > 0) + Info("CheckProxy", "using HTTP proxy %s", fProxy.GetUrl()); } } @@ -644,6 +648,9 @@ Int_t TWebFile::GetFromWeb10(char *buf, Int_t len, const TString &msg) return -1; } + if (gDebug > 0) + Info("GetFromWeb10", "sending HTTP request:\n%s", msg.Data()); + if (fSocket->SendRaw(msg.Data(), msg.Length()) == -1) { Error("GetFromWeb10", "error sending command to host %s", fUrl.GetHost()); return -1; @@ -671,10 +678,15 @@ Int_t TWebFile::GetFromWeb10(char *buf, Int_t len, const TString &msg) if (first >= 0) { Int_t ll = Int_t(last - first) + 1; - if (fSocket->RecvRaw(&buf[ltot], ll) == -1) { + Int_t rsize; + if ((rsize = fSocket->RecvRaw(&buf[ltot], ll)) == -1) { Error("GetFromWeb10", "error receiving data from host %s", fUrl.GetHost()); return -1; } + else if (ll != rsize) { + Error("GetFromWeb10", "expected %d bytes, got %d", ll, rsize); + return -1; + } ltot += ll; first = -1; @@ -885,7 +897,7 @@ Int_t TWebFile::GetHead() fMsgGetHead += "\r\n\r\n"; } TString msg = fMsgGetHead; - + TUrl connurl; if (fProxy.IsValid()) connurl = fProxy; @@ -920,6 +932,11 @@ Int_t TWebFile::GetHead() if (!s) return -1; + if (gDebug > 0) { + Info("GetHead", "connected to host %s", connurl.GetHost()); + Info("GetHead", "sending HTTP request:\n%s", msg.Data()); + } + if (s->SendRaw(msg.Data(), msg.Length()) == -1) { Error("GetHead", "error sending command to host %s", fUrl.GetHost()); delete s; @@ -950,6 +967,7 @@ Int_t TWebFile::GetHead() Info("GetHead", "header: %s", line); TString res = line; + ProcessHttpHeader(res); if (res.BeginsWith("HTTP/1.")) { if (res.BeginsWith("HTTP/1.1")) { if (!fHTTP11) { @@ -1235,6 +1253,13 @@ const char *TWebFile::GetProxy() return ""; } +//______________________________________________________________________________ +void TWebFile::ProcessHttpHeader(const TString&) +{ + // Process the HTTP header in the argument. This method is intended to be + // overwritten by subclasses that exploit the information contained in the + // HTTP headers. +} //______________________________________________________________________________ TWebSystem::TWebSystem() : TSystem("-http", "HTTP Helper System") @@ -1345,7 +1370,7 @@ Bool_t TWebSystem::AccessPathName(const char *path, EAccessMode) //______________________________________________________________________________ Int_t TWebSystem::Unlink(const char *) { - // Unlink, i.e. remove, a file or directory. Returns 0 when succesfull, + // Unlink, i.e. remove, a file or directory. Returns 0 when successful, // -1 in case of failure. Not supported for httpd. return -1; diff --git a/net/netx/CMakeLists.txt b/net/netx/CMakeLists.txt index 1cb60a4386a71..afd446da4b9e6 100644 --- a/net/netx/CMakeLists.txt +++ b/net/netx/CMakeLists.txt @@ -6,7 +6,7 @@ ROOT_USE_PACKAGE(net/net) ROOT_USE_PACKAGE(proof/proofd) -include_directories(${XROOTD_INCLUDE_DIR}) +include_directories(${XROOTD_INCLUDE_DIRS}) add_definitions(${XROOTD_CFLAGS}) #--------------------------------------------------------------------------- diff --git a/net/netx/Module.mk b/net/netx/Module.mk index e136f8ae77ae5..1a5541cc1b354 100644 --- a/net/netx/Module.mk +++ b/net/netx/Module.mk @@ -37,33 +37,23 @@ ALLMAPS += $(NETXMAP) INCLUDEFILES += $(NETXDEP) endif -# When using an external XROOTD distribution XROOTDDIRI and XROOTDDIRL -# are undefined and have to point to the specified inc and lib dirs. -ifneq ($(XRDINCDIR),) -ifeq ($(XROOTDDIRI),) -XROOTDDIRI := $(XRDINCDIR) -endif -endif -ifneq ($(XRDLIBDIR),) -ifeq ($(XROOTDDIRL),) -XROOTDDIRL := $(XRDLIBDIR) -endif -endif - # Xrootd includes -NETXINCEXTRA := $(XROOTDDIRI:%=-I%) +NETXINCEXTRA := $(XRDINCDIR:%=-I%) ifneq ($(EXTRA_XRDFLAGS),) NETXINCEXTRA += -I$(ROOT_SRCDIR)/proof/proofd/inc endif +ifeq ($(XRDINCPRIVATE),yes) +NETXINCEXTRA += -I$(XRDINCDIR)/private +endif # Xrootd client libs ifeq ($(PLATFORM),win32) -NETXLIBEXTRA += $(XROOTDDIRL)/libXrdClient.lib +NETXLIBEXTRA += $(XRDLIBDIR)/libXrdClient.lib else ifeq ($(HASXRDUTILS),no) -NETXLIBEXTRA += $(XROOTDDIRL) -lXrdOuc -lXrdSys -lXrdClient -lpthread +NETXLIBEXTRA += $(XRDLIBDIR) -lXrdOuc -lXrdSys -lXrdClient -lpthread else -NETXLIBEXTRA += $(XROOTDDIRL) -lXrdUtils -lXrdClient +NETXLIBEXTRA += $(XRDLIBDIR) -lXrdUtils -lXrdClient endif endif @@ -73,13 +63,12 @@ endif include/%.h: $(NETXDIRI)/%.h $(XROOTDMAKE) cp $< $@ -$(NETXLIB): $(NETXO) $(NETXDO) $(ORDER_) $(MAINLIBS) $(NETXLIBDEP) \ - $(XRDNETXD) +$(NETXLIB): $(NETXO) $(NETXDO) $(ORDER_) $(MAINLIBS) $(NETXLIBDEP) @$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \ "$(SOFLAGS)" libNetx.$(SOEXT) $@ "$(NETXO) $(NETXDO)" \ "$(NETXLIBEXTRA)" -$(NETXDS): $(NETXH1) $(NETXL) $(XROOTDMAKE) $(ROOTCINTTMPDEP) $(XRDPLUGINS) +$(NETXDS): $(NETXH) $(NETXL) $(XROOTDMAKE) $(ROOTCINTTMPDEP) $(MAKEDIR) @echo "Generating dictionary $@..." $(ROOTCINTTMP) -f $@ -c $(NETXINCEXTRA) $(NETXH) $(NETXL) diff --git a/net/netx/inc/TXNetFileStager.h b/net/netx/inc/TXNetFileStager.h index f9901b6452855..1bd250a631089 100644 --- a/net/netx/inc/TXNetFileStager.h +++ b/net/netx/inc/TXNetFileStager.h @@ -26,6 +26,7 @@ class TCollection; class TXNetSystem; +class TFileCollection; class TXNetFileStager : public TFileStager { @@ -41,6 +42,7 @@ class TXNetFileStager : public TFileStager { Bool_t IsStaged(const char *path); Int_t Locate(const char *path, TString &endpath); + Int_t LocateCollection(TFileCollection *fc, Bool_t addDummyUrl = kFALSE); Bool_t Matches(const char *s); Bool_t Stage(const char *path, Option_t *opt = 0); Bool_t Stage(TCollection *pathlist, Option_t *opt = 0); diff --git a/net/netx/src/TXNetFile.cxx b/net/netx/src/TXNetFile.cxx index f510ed328bf46..3b11d18dee883 100644 --- a/net/netx/src/TXNetFile.cxx +++ b/net/netx/src/TXNetFile.cxx @@ -56,6 +56,7 @@ #include "TVirtualPerfStats.h" #include <XrdClient/XrdClient.hh> +#include <XrdClient/XrdClientConn.hh> #include <XrdClient/XrdClientConst.hh> #include <XrdClient/XrdClientEnv.hh> #include <XProtocol/XProtocol.hh> diff --git a/net/netx/src/TXNetFileStager.cxx b/net/netx/src/TXNetFileStager.cxx index 4e8a2ad6e0ebc..531fa70fbd11e 100644 --- a/net/netx/src/TXNetFileStager.cxx +++ b/net/netx/src/TXNetFileStager.cxx @@ -22,6 +22,9 @@ #include "TUrl.h" #include "TXNetFileStager.h" #include "TXNetSystem.h" +#include "TFileCollection.h" +#include "TStopwatch.h" +#include "TFileInfo.h" //_____________________________________________________________________________ TXNetFileStager::TXNetFileStager(const char *url) : TFileStager("xrd") @@ -125,7 +128,7 @@ Bool_t TXNetFileStager::Stage(const char *path, Option_t *opt) } if (IsValid()) { - UChar_t o = 8; + UChar_t o = 8; // XrdProtocol.hh UChar_t p = 0; // Parse options TString xo(opt), io; @@ -207,6 +210,108 @@ Int_t TXNetFileStager::Locate(const char *path, TString &eurl) return -1; } +//_____________________________________________________________________________ +Int_t TXNetFileStager::LocateCollection(TFileCollection *fc, + Bool_t addDummyUrl) +{ + // Bulk locate request for a collection of files. A noop prepare command is + // issued beforehand to fill redirector's cache, then Locate() is issued on + // each file. Results are saved back to the input collection: when a file is + // found, the staged bit is set to on, and its endpoint URL is added, if + // different from the redirector's URL. If a file is not found, the staged + // bit is set to off. + // If addDummyUrl is kTRUE, in case file is not staged or redirector is + // identical to endpoint URL, a dummy URL is prepended, respectively: + // "noop://redir" and "noop://none". + // If the collection contains URLs with "anchors" (i.e., #fileName.root), + // they are ignored by xrootd. + // The Locate() command preserves anchors, but needs single paths to be full + // URLs beginning with root://. + // Returns < 0 in case of errors, and the number of files processed in case + // of success. + + if (!fc) { + Error("Locate", "No input collection given!"); + return -1; + } + + // Fill redirector's cache with an empty prepare request + //Int_t TXNetSystem::Prepare(TCollection *paths, + // UChar_t opt, UChar_t prio, TString *bufout) + + Int_t count = 0; + + TStopwatch ts; + Double_t timeTaken_s; + TFileInfo *fi; + + Int_t rv = fSystem->Prepare(fc->GetList(), 0, 0, NULL); + // o p + + TIter it(fc->GetList()); + + timeTaken_s = ts.RealTime(); + if (gDebug > 0) { + Info("Locate", "Bulk xprep done in %.1lfs (returned %d)", + ts.RealTime(), rv); + } + + ts.Start(); + TString surl, endp; + + while ((fi = dynamic_cast<TFileInfo *>(it.Next())) != NULL) { + + surl = fi->GetCurrentUrl()->GetUrl(); + + if (!IsValid()) { + GetPrefix(surl.Data(), fPrefix); + if (gDebug > 0) { + Info("Locate", "Stager non initialized, doing it now for %s", + fPrefix.Data()); + } + fSystem = new TXNetSystem(surl.Data()); + } + + // Locating (0=success, 1=error -- 1 includes when file is not staged) + if (fSystem->Locate(surl.Data(), endp)) { + // File not staged + fi->ResetBit(TFileInfo::kStaged); + + if (addDummyUrl) + fi->AddUrl("noop://none", kTRUE); + + if (gDebug > 1) + Info("Locate", "Not found: %s", surl.Data()); + } + else { + // File staged. Returned endpoint contains the same anchor and options. + // We just check if it is equal to one of our current URLs. + + fi->SetBit(TFileInfo::kStaged); + if (surl != endp) { + fi->AddUrl(endp.Data(), kTRUE); + } + else if (addDummyUrl) { + // Returned URL identical to redirector's URL + fi->AddUrl("noop://redir", kTRUE); + } + + if (gDebug > 1) + Info("Locate", "Found: %s --> %s", surl.Data(), endp.Data()); + } + + count++; + } + + timeTaken_s += ts.RealTime(); + if (gDebug > 0) { + Info("Locate", "All locates finished in %.1lfs", ts.RealTime()); + Info("Locate", "Mass prepare and locates took %.1lfs", timeTaken_s); + } + + return count; +} + //______________________________________________________________________________ Bool_t TXNetFileStager::Matches(const char *s) { diff --git a/net/netx/src/TXNetSystem.cxx b/net/netx/src/TXNetSystem.cxx index bcfd60d3ff8c8..d536cc52db8e2 100644 --- a/net/netx/src/TXNetSystem.cxx +++ b/net/netx/src/TXNetSystem.cxx @@ -564,7 +564,8 @@ Int_t TXNetSystem::Prepare(TCollection *paths, *buf += Form("%s\n", path.Data()); } - Info("Prepare","buffer ready: issuing prepare ..."); + Info("Prepare","buffer ready: issuing prepare (opt=%d, prio=%d) ...", + opt, prio); cg.ClientAdmin()->Prepare(buf->Data(), (kXR_char)opt, (kXR_char)prio); cg.ClientAdmin()->GoBackToRedirector(); if (!bufout) diff --git a/net/netxng/CMakeLists.txt b/net/netxng/CMakeLists.txt new file mode 100644 index 0000000000000..2720c1eb9b529 --- /dev/null +++ b/net/netxng/CMakeLists.txt @@ -0,0 +1,13 @@ +############################################################################ +# CMakeLists.txt file for building ROOT net/netxng package +# @author Lukasz Janyst <ljanyst@cern.ch> +############################################################################ + +include_directories(${XROOTD_INCLUDE_DIR}) +add_definitions(${XROOTD_CFLAGS}) + +ROOT_GENERATE_DICTIONARY(G__NetxNG *.h LINKDEF LinkDef.h) +ROOT_GENERATE_ROOTMAP(NetxNG LINKDEF LinkDef.h DEPENDENCIES RIO Thread) +ROOT_LINKER_LIBRARY(NetxNG *.cxx G__NetxNG.cxx LIBRARIES ${XROOTD_LIBRARIES} DEPENDENCIES RIO Thread) + +ROOT_INSTALL_HEADERS() diff --git a/net/netxng/Module.mk b/net/netxng/Module.mk new file mode 100644 index 0000000000000..cffc3d2c64059 --- /dev/null +++ b/net/netxng/Module.mk @@ -0,0 +1,83 @@ +# Module.mk for xrd module +# Copyright (c) 2000 Rene Brun and Fons Rademakers +# +# Author: Lukasz Janyst 11/01/2013 + +MODNAME := netxng +MODDIR := $(ROOT_SRCDIR)/net/$(MODNAME) +MODDIRS := $(MODDIR)/src +MODDIRI := $(MODDIR)/inc + +NETXNGDIR := $(MODDIR) +NETXNGDIRS := $(MODDIR)/src +NETXNGDIRI := $(MODDIR)/inc + +##### libNetxNG ##### +NETXNGL := $(MODDIRI)/LinkDef.h +NETXNGDS := $(call stripsrc,$(MODDIRS)/G__NetxNG.cxx) +NETXNGDO := $(NETXNGDS:.cxx=.o) +NETXNGDH := $(NETXNGDS:.cxx=.h) + +NETXNGH := $(filter-out $(MODDIRI)/LinkDef%,$(wildcard $(MODDIRI)/*.h)) +NETXNGS := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx)) +NETXNGO := $(call stripsrc,$(NETXNGS:.cxx=.o)) + +NETXNGDEP := $(NETXNGO:.o=.d) $(NETXNGDO:.o=.d) + +NETXNGLIB := $(LPATH)/libNetxNG.$(SOEXT) +NETXNGMAP := $(NETXNGLIB:.$(SOEXT)=.rootmap) + +# used in the main Makefile +ALLHDRS += $(patsubst $(MODDIRI)/%.h,include/%.h,$(NETXNGH)) +ALLLIBS += $(NETXNGLIB) +ALLMAPS += $(NETXNGMAP) + +# include all dependency files +INCLUDEFILES += $(NETXNGDEP) + +# Xrootd includes +NETXNGINCEXTRA := $(XRDINCDIR:%=-I%) + +# Xrootd client libs +ifeq ($(PLATFORM),win32) +NETXNGLIBEXTRA += $(XRDLIBDIR)/libXrdCl.lib +else +NETXNGLIBEXTRA += $(XRDLIBDIR) -lXrdUtils -lXrdCl +endif + +##### local rules ##### +.PHONY: all-$(MODNAME) clean-$(MODNAME) distclean-$(MODNAME) + +include/%.h: $(NETXNGDIRI)/%.h + cp $< $@ + +$(NETXNGLIB): $(NETXNGO) $(NETXNGDO) $(ORDER_) $(MAINLIBS) $(NETXNGLIBDEP) + @$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \ + "$(SOFLAGS)" libNetxNG.$(SOEXT) $@ "$(NETXNGO) $(NETXNGDO)" \ + "$(NETXNGLIBEXTRA)" + +$(NETXNGDS): $(NETXNGH) $(NETXNGL) $(XROOTDMAKE) $(ROOTCINTTMPDEP) + $(MAKEDIR) + @echo "Generating dictionary $@..." + $(ROOTCINTTMP) -f $@ -c $(NETXNGH) $(NETXNGL) + +$(NETXNGMAP): $(RLIBMAP) $(MAKEFILEDEP) $(NETXNGL) + $(RLIBMAP) -o $@ -l $(NETXNGLIB) -d $(NETXNGLIBDEPM) -c $(NETXNGL) + +all-$(MODNAME): $(NETXNGLIB) $(NETXNGMAP) + +clean-$(MODNAME): + @rm -f $(NETXNGO) $(NETXNGDO) + +clean:: clean-$(MODNAME) + +distclean-$(MODNAME): clean-$(MODNAME) + @rm -f $(NETXNGDEP) $(NETXNGDS) $(NETXNGDH) $(NETXNGLIB) $(NETXNGMAP) + +distclean:: distclean-$(MODNAME) + +$(NETXNGO) $(NETXNGDO): CXXFLAGS += $(NETXNGINCEXTRA) +ifneq ($(findstring gnu,$(COMPILER)),) +# problem in xrootd 3.3.5 headers +$(NETXNGO) $(NETXNGDO): CXXFLAGS += -Wno-unused-parameter -Wno-shadow +endif diff --git a/net/netxng/inc/LinkDef.h b/net/netxng/inc/LinkDef.h new file mode 100644 index 0000000000000..cd89ef8a47d00 --- /dev/null +++ b/net/netxng/inc/LinkDef.h @@ -0,0 +1,11 @@ +#ifdef __CINT__ + +#pragma link off all globals; +#pragma link off all classes; +#pragma link off all functions; + +#pragma link C++ class TNetXNGFile; +#pragma link C++ class TNetXNGFileStager; +#pragma link C++ class TNetXNGSystem; + +#endif diff --git a/net/netxng/inc/TNetXNGFile.h b/net/netxng/inc/TNetXNGFile.h new file mode 100644 index 0000000000000..90cdfcac504c3 --- /dev/null +++ b/net/netxng/inc/TNetXNGFile.h @@ -0,0 +1,84 @@ +// @(#)root/netxng:$Id$ +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TNetXNGFile +#define ROOT_TNetXNGFile + +//////////////////////////////////////////////////////////////////////////////// +// // +// TNetXNGFile // +// // +// Authors: Justin Salmon, Lukasz Janyst // +// CERN, 2013 // +// // +// Enables access to XRootD files using the new client. // +// // +//////////////////////////////////////////////////////////////////////////////// + +#include "TFile.h" +#include "TSemaphore.h" +#ifndef __CINT__ +#include <XrdSys/XrdSysPthread.hh> +#include <XrdCl/XrdClFileSystem.hh> +#include <XrdCl/XrdClXRootDResponses.hh> +#endif + +namespace XrdCl { + class File; + class ResponseHandler; +} + +class TNetXNGFile: public TFile { +private: +#ifndef __CINT__ + XrdCl::File *fFile; // Underlying XRootD file + XrdCl::URL *fUrl; // URL of the current file + XrdCl::OpenFlags::Flags fMode; // Open mode of the current file + XrdSysCondVar *fInitCondVar; // Used to block an async open request + // if requested + Int_t fReadvIorMax; // Max size of a single readv chunk + Int_t fReadvIovMax; // Max number of readv chunks +#endif + +public: + TNetXNGFile() : TFile(), + fFile(0), fUrl(0), fMode(XrdCl::OpenFlags::None), fInitCondVar(0), + fReadvIorMax(0), fReadvIovMax(0){} + TNetXNGFile(const char *url, Option_t *mode = "", const char *title = "", + Int_t compress = 1, Int_t netopt = 0, Bool_t parallelopen = kFALSE); + virtual ~TNetXNGFile(); + + virtual void Init(Bool_t create); + virtual void Close(const Option_t *option = ""); + virtual void Seek(Long64_t offset, ERelativeTo position = kBeg); + virtual void SetAsyncOpenStatus(EAsyncOpenStatus status); + virtual Long64_t GetSize() const; + virtual Int_t ReOpen(Option_t *modestr); + virtual Bool_t IsOpen() const; + virtual Bool_t WriteBuffer(const char *buffer, Int_t length); + virtual Bool_t ReadBuffer(char *buffer, Int_t length); + virtual Bool_t ReadBuffer(char *buffer, Long64_t position, Int_t length); + virtual Bool_t ReadBuffers(char *buffer, Long64_t *position, Int_t *length, + Int_t nbuffs); + +private: + virtual Bool_t IsUseable() const; + virtual Bool_t GetVectorReadLimits(); + virtual void SetEnv(); +#ifndef __CINT__ + XrdCl::OpenFlags::Flags ParseOpenMode(Option_t *modestr); +#endif + + TNetXNGFile(const TNetXNGFile &other); // Not implemented + TNetXNGFile &operator =(const TNetXNGFile &other); // Not implemented + + ClassDef( TNetXNGFile, 0 ) // ROOT class definition +}; + +#endif // ROOT_TNetXNGFile diff --git a/net/netxng/inc/TNetXNGFileStager.h b/net/netxng/inc/TNetXNGFileStager.h new file mode 100644 index 0000000000000..7a9440cc27d21 --- /dev/null +++ b/net/netxng/inc/TNetXNGFileStager.h @@ -0,0 +1,53 @@ +// @(#)root/netxng:$Id$ +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TNetXNGFileStager +#define ROOT_TNetXNGFileStager + +//////////////////////////////////////////////////////////////////////////////// +// // +// TNetXNGFileStager // +// // +// Authors: Lukasz Janyst, Justin Salmon // +// CERN, 2013 // +// // +// Enables access to XRootD staging capabilities using the new client. // +// // +//////////////////////////////////////////////////////////////////////////////// + +#include "TFileStager.h" + +class TCollection; +class TNetXNGSystem; +class TFileCollection; + +class TNetXNGFileStager: public TFileStager { + +private: + TNetXNGSystem *fSystem; // Used to access filesystem interface + +public: + TNetXNGFileStager(const char *url = ""); + virtual ~TNetXNGFileStager(); + + Bool_t IsStaged(const char *path); + Int_t Locate(const char *path, TString &endpath); + Int_t LocateCollection(TFileCollection *fc, Bool_t addDummyUrl = kFALSE); + Bool_t Matches(const char *s); + Bool_t Stage(const char *path, Option_t *opt = 0); + Bool_t Stage(TCollection *pathlist, Option_t *opt = 0); + Bool_t IsValid() const { return (fSystem ? kTRUE : kFALSE); } + +private: + UChar_t ParseStagePriority(Option_t *opt); + + ClassDef( TNetXNGFileStager, 0 ) //! Interface to a 'XRD' staging +}; + +#endif diff --git a/net/netxng/inc/TNetXNGSystem.h b/net/netxng/inc/TNetXNGSystem.h new file mode 100644 index 0000000000000..8184e34e96bec --- /dev/null +++ b/net/netxng/inc/TNetXNGSystem.h @@ -0,0 +1,68 @@ +// @(#)root/netxng:$Id$ +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TNetXNGSystem +#define ROOT_TNetXNGSystem + +//////////////////////////////////////////////////////////////////////////////// +// // +// TNetXNGSystem // +// // +// Authors: Justin Salmon, Lukasz Janyst // +// CERN, 2013 // +// // +// Enables access to XRootD filesystem interface using the new client. // +// // +//////////////////////////////////////////////////////////////////////////////// + +#include "TSystem.h" +#include "TCollection.h" + +#ifndef __CINT__ +#include <XrdCl/XrdClXRootDResponses.hh> +#include <XrdCl/XrdClURL.hh> +#endif + +namespace XrdCl { + class FileSystem; + class URL; + class DirectoryList; +} + +class TNetXNGSystem: public TSystem { + +private: +#ifndef __CINT__ +private: + XrdCl::URL *fUrl; // URL of this TSystem + XrdCl::FileSystem *fFileSystem; // Cached for convenience + +#endif + +public: + TNetXNGSystem(Bool_t owner = kTRUE); + TNetXNGSystem(const char *url, Bool_t owner = kTRUE); + virtual ~TNetXNGSystem(); + + virtual void* OpenDirectory(const char* dir); + virtual Int_t MakeDirectory(const char* dir); + virtual void FreeDirectory(void *dirp); + virtual const char* GetDirEntry(void *dirp); + virtual Int_t GetPathInfo(const char* path, FileStat_t &buf); + virtual Bool_t ConsistentWith(const char *path, void *dirptr); + virtual int Unlink(const char *path); + virtual Bool_t IsPathLocal(const char *path); + virtual Int_t Locate(const char* path, TString &endurl); + virtual Int_t Stage(const char* path, UChar_t priority); + virtual Int_t Stage(TCollection *files, UChar_t priority); + + ClassDef(TNetXNGSystem, 0 ) // ROOT class definition +}; + +#endif diff --git a/net/netxng/src/TNetXNGFile.cxx b/net/netxng/src/TNetXNGFile.cxx new file mode 100644 index 0000000000000..e99767da4b983 --- /dev/null +++ b/net/netxng/src/TNetXNGFile.cxx @@ -0,0 +1,798 @@ +// @(#)root/netxng:$Id$ +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +//////////////////////////////////////////////////////////////////////////////// +// // +// TNetXNGFile // +// // +// Authors: Justin Salmon, Lukasz Janyst // +// CERN, 2013 // +// // +// Enables access to XRootD files using the new client. // +// // +//////////////////////////////////////////////////////////////////////////////// + +#include "TNetXNGFile.h" +#include "TEnv.h" +#include "TSystem.h" +#include "TTimeStamp.h" +#include "TVirtualPerfStats.h" +#include "TVirtualMonitoring.h" +#include <XrdCl/XrdClURL.hh> +#include <XrdCl/XrdClFile.hh> +#include <XrdCl/XrdClXRootDResponses.hh> +#include <XrdCl/XrdClDefaultEnv.hh> +#include <iostream> + +//------------------------------------------------------------------------------ +// Open handler for async open requests +//------------------------------------------------------------------------------ +class TAsyncOpenHandler: public XrdCl::ResponseHandler +{ + public: + //------------------------------------------------------------------------ + // Constructor + //------------------------------------------------------------------------ + TAsyncOpenHandler(TNetXNGFile *file) + { + fFile = file; + fFile->SetAsyncOpenStatus(TFile::kAOSInProgress); + } + + //------------------------------------------------------------------------ + // Called when a response to open arrives + //------------------------------------------------------------------------ + virtual void HandleResponse(XrdCl::XRootDStatus *status, + XrdCl::AnyObject *response) + { + if (status->IsOK()) + { + fFile->SetAsyncOpenStatus(TFile::kAOSSuccess); + } + else + { + fFile->SetAsyncOpenStatus(TFile::kAOSFailure); + } + + delete response; + delete status; + delete this; + } + + private: + TNetXNGFile *fFile; +}; + +//------------------------------------------------------------------------------ +// Async readv handler +//------------------------------------------------------------------------------ +class TAsyncReadvHandler: public XrdCl::ResponseHandler +{ + public: + //------------------------------------------------------------------------ + // Constructor + //------------------------------------------------------------------------ + TAsyncReadvHandler(std::vector<XrdCl::XRootDStatus*> *statuses, + Int_t statusIndex, + TSemaphore *semaphore): + fStatuses(statuses), fStatusIndex(statusIndex), fSemaphore(semaphore) {} + + + //------------------------------------------------------------------------ + // Handle readv response + //------------------------------------------------------------------------ + virtual void HandleResponse(XrdCl::XRootDStatus *status, + XrdCl::AnyObject *response) + { + fStatuses->at(fStatusIndex) = status; + fSemaphore->Post(); + delete response; + delete this; + } + + private: + std::vector<XrdCl::XRootDStatus*> *fStatuses; // Pointer to status vector + Int_t fStatusIndex; // Index into status vector + TSemaphore *fSemaphore; // Synchronize the responses +}; + + +ClassImp(TNetXNGFile); + +//______________________________________________________________________________ +TNetXNGFile::TNetXNGFile(const char *url, + Option_t *mode, + const char *title, + Int_t compress, + Int_t /*netopt*/, + Bool_t parallelopen) : + TFile(url, "NET", title, compress) +{ + // Constructor + // + // param url: URL of the entry-point server to be contacted + // param mode: initial file access mode + // param title: title of the file (shown by ROOT browser) + // param compress: compression level and algorithm + // param netopt: TCP window size in bytes (unused) + // param parallelopen: open asynchronously + + using namespace XrdCl; + + fFile = new File(); + fUrl = new URL(std::string(url)); + fInitCondVar = new XrdSysCondVar(); + fUrl->SetProtocol(std::string("root")); + fMode = ParseOpenMode(mode); + + // Map ROOT and xrootd environment + SetEnv(); + + // Init the monitoring system + if (gMonitoringWriter) { + if (!fOpenPhases) { + fOpenPhases = new TList; + fOpenPhases->SetOwner(); + } + gMonitoringWriter->SendFileOpenProgress(this, fOpenPhases, "xrdopen", + kFALSE); + } + + XRootDStatus status; + if (parallelopen) { + // Open the file asynchronously + TAsyncOpenHandler *handler = new TAsyncOpenHandler(this); + status = fFile->Open(fUrl->GetURL(), fMode, Access::None, handler); + if (!status.IsOK()) { + Error("Open", "%s", status.ToStr().c_str()); + MakeZombie(); + } + return; + } + + // Open the file synchronously + status = fFile->Open(fUrl->GetURL(), fMode); + if (!status.IsOK()) { + Error("Open", "%s", status.ToStr().c_str()); + MakeZombie(); + return; + } + + // Initialize the file + TFile::Init(false); + + // Get the vector read limits + GetVectorReadLimits(); +} + +//______________________________________________________________________________ +TNetXNGFile::~TNetXNGFile() +{ + // Destructor + + if (IsOpen()) + Close(); + delete fFile; + delete fUrl; + delete fInitCondVar; +} + +//______________________________________________________________________________ +void TNetXNGFile::Init(Bool_t create) +{ + // Initialize the file. Makes sure that the file is really open before + // calling TFile::Init. It may block. + + using namespace XrdCl; + + if (fInitDone) { + if (gDebug > 1) Info("Init", "TFile::Init already called once"); + return; + } + + // If the async open didn't return yet, wait for it + if (!IsOpen() && fAsyncOpenStatus == kAOSInProgress) { + fInitCondVar->Wait(); + } + + // Notify the monitoring system + if (gMonitoringWriter) + gMonitoringWriter->SendFileOpenProgress(this, fOpenPhases, "rootinit", + kFALSE); + + // Initialize the file + TFile::Init(create); + + // Notify the monitoring system + if (gMonitoringWriter) + gMonitoringWriter->SendFileOpenProgress(this, fOpenPhases, "endopen", + kTRUE); + + // Get the vector read limits + GetVectorReadLimits(); +} + +//______________________________________________________________________________ +Long64_t TNetXNGFile::GetSize() const +{ + // Get the file size. Returns -1 in the case that the file could not be + // stat'ed. + + using namespace XrdCl; + + // Check the file isn't a zombie or closed + if (!IsUseable()) + return -1; + + bool forceStat = true; + if( fMode == XrdCl::OpenFlags::Read ) + forceStat = false; + + StatInfo *info = 0; + if( !fFile->Stat( forceStat, info ).IsOK() ) + return -1; + Long64_t size = info->GetSize(); + delete info; + return size; +} + +//______________________________________________________________________________ +Bool_t TNetXNGFile::IsOpen() const +{ + // Check if the file is open + + return fFile->IsOpen(); +} + +//______________________________________________________________________________ +void TNetXNGFile::SetAsyncOpenStatus(EAsyncOpenStatus status) +{ + // Set the status of an asynchronous file open + + fAsyncOpenStatus = status; + // Unblock Init() if it is waiting + fInitCondVar->Signal(); +} + +//______________________________________________________________________________ +void TNetXNGFile::Close(const Option_t */*option*/) +{ + // Close the file + // + // param option: if == "R", all TProcessIDs referenced by this file are + // deleted (is this valid in xrootd context?) + + TFile::Close(); + + XrdCl::XRootDStatus status = fFile->Close(); + if (!status.IsOK()) { + Error("Close", "%s", status.ToStr().c_str()); + MakeZombie(); + } +} + +//______________________________________________________________________________ +Int_t TNetXNGFile::ReOpen(Option_t *modestr) +{ + // Reopen the file with the new access mode + // + // param mode: the new access mode + // returns: 0 in case the mode was successfully modified, 1 in case + // the mode did not change (was already as requested or wrong + // input arguments) and -1 in case of failure, in which case + // the file cannot be used anymore + + using namespace XrdCl; + OpenFlags::Flags mode = ParseOpenMode(modestr); + + // Only Read and Update are valid modes + if (mode != OpenFlags::Read && mode != OpenFlags::Update) { + Error("ReOpen", "mode must be either READ or UPDATE, not %s", modestr); + return 1; + } + + // The mode is not really changing + if (mode == fMode || (mode == OpenFlags::Update + && fMode == OpenFlags::New)) { + return 1; + } + + fFile->Close(); + fMode = mode; + + XRootDStatus st = fFile->Open(fUrl->GetURL(), fMode); + if (!st.IsOK()) { + Error("ReOpen", "%s", st.ToStr().c_str()); + return 1; + } + + return 0; +} + +//______________________________________________________________________________ +Bool_t TNetXNGFile::ReadBuffer(char *buffer, Int_t length) +{ + // Read a data chunk of the given size + // + // param buffer: a pointer to a buffer big enough to hold the data + // param length: number of bytes to be read + // returns: kTRUE in case of failure + + return ReadBuffer(buffer, fOffset, length); +} + +//______________________________________________________________________________ +Bool_t TNetXNGFile::ReadBuffer(char *buffer, Long64_t position, Int_t length) +{ + // Read a data chunk of the given size, starting from the given offset + // + // param buffer: a pointer to a buffer big enough to hold the data + // param position: offset from the beginning of the file + // param length: number of bytes to be read + // returns: kTRUE in case of failure + + using namespace XrdCl; + if (gDebug > 0) + Info("ReadBuffer", "offset: %lld length: %d", position, length); + + // Check the file isn't a zombie or closed + if (!IsUseable()) + return kTRUE; + + // Try to read from cache + Int_t status; + if ((status = ReadBufferViaCache(buffer, length))) { + if (status == 2) + return kTRUE; + return kFALSE; + } + + // Read the data + uint32_t bytesRead = 0; + XRootDStatus st = fFile->Read(position, length, buffer, bytesRead); + if (gDebug > 0) + Info("ReadBuffer", "%s bytes read: %d", st.ToStr().c_str(), bytesRead); + + if (!st.IsOK()) { + Error("ReadBuffer", "%s", st.ToStr().c_str()); + return kTRUE; + } + + // Bump the globals + fOffset += length; + fBytesRead += bytesRead; + fgBytesRead += bytesRead; + fReadCalls ++; + fgReadCalls ++; + + if (gMonitoringWriter) + gMonitoringWriter->SendFileReadProgress(this); + + return kFALSE; +} + +//______________________________________________________________________________ +Bool_t TNetXNGFile::ReadBuffers(char *buffer, Long64_t *position, Int_t *length, + Int_t nbuffs) +{ + // Read scattered data chunks in one operation + // + // param buffer: a pointer to a buffer big enough to hold all of the + // requested data + // param position: position[i] is the seek position of chunk i of len + // length[i] + // param length: length[i] is the length of the chunk at offset + // position[i] + // param nbuffs: number of chunks + // returns: kTRUE in case of failure + + using namespace XrdCl; + + // Check the file isn't a zombie or closed + if (!IsUseable()) + return kTRUE; + + std::vector<ChunkList> chunkLists; + ChunkList chunks; + std::vector<XRootDStatus*> *statuses; + TSemaphore *semaphore; + Int_t totalBytes = 0; + Int_t offset = 0; + + Double_t start = 0; + if (gPerfStats) start = TTimeStamp(); + + if (fArchiveOffset) + for (Int_t i = 0; i < nbuffs; i++) + position[i] += fArchiveOffset; + + // Build a list of chunks. Put the buffers in the ChunkInfo's + for (Int_t i = 0; i < nbuffs; ++i) { + totalBytes += length[i]; + + // If the length is bigger than max readv size, split into smaller chunks + if (length[i] > fReadvIorMax) { + Int_t nsplit = length[i] / fReadvIorMax; + Int_t rem = length[i] % fReadvIorMax; + Int_t j; + + // Add as many max-size chunks as are divisible + for (j = 0; j < nsplit; ++j) { + offset = position[i] + (j * fReadvIorMax); + chunks.push_back(ChunkInfo(offset, fReadvIorMax, buffer)); + } + + // Add the remainder + offset = position[i] + (j * fReadvIorMax); + chunks.push_back(ChunkInfo(offset, rem, buffer)); + + } else { + offset = position[i]; + chunks.push_back(ChunkInfo(offset, length[i], buffer)); + } + + // If there are more than or equal to max chunks, make another chunk list + if ((Int_t) chunks.size() == fReadvIovMax) { + chunkLists.push_back(chunks); + chunks = ChunkList(); + } else if ((Int_t) chunks.size() > fReadvIovMax) { + chunkLists.push_back(ChunkList(chunks.begin(), + chunks.begin() + fReadvIovMax)); + chunks = ChunkList(chunks.begin() + fReadvIovMax, chunks.end()); + } + } + + // Push back the last chunk list + chunkLists.push_back(chunks); + + TAsyncReadvHandler *handler; + XRootDStatus status; + semaphore = new TSemaphore(0); + statuses = new std::vector<XRootDStatus*>(chunkLists.size()); + + // Read asynchronously but wait for all responses + std::vector<ChunkList>::iterator it; + for (it = chunkLists.begin(); it != chunkLists.end(); ++it) + { + handler = new TAsyncReadvHandler(statuses, it - chunkLists.begin(), + semaphore); + status = fFile->VectorRead(*it, buffer, handler); + + if (!status.IsOK()) { + Error("ReadBuffers", "%s", status.ToStr().c_str()); + return kTRUE; + } + } + + // Wait for all responses + for (it = chunkLists.begin(); it != chunkLists.end(); ++it) { + semaphore->Wait(); + } + + // Check for errors + for (it = chunkLists.begin(); it != chunkLists.end(); ++it) { + XRootDStatus *st = statuses->at(it - chunkLists.begin()); + + if (!st->IsOK()) { + Error("ReadBuffers", "%s", st->ToStr().c_str()); + delete statuses; + delete semaphore; + for( ; it != chunkLists.end(); ++it ) + { + st = statuses->at( it - chunkLists.begin() ); + delete st; + } + + return kTRUE; + } + delete st; + } + + // Bump the globals + fBytesRead += totalBytes; + fgBytesRead += totalBytes; + fReadCalls ++; + fgReadCalls ++; + + if (gPerfStats) { + fOffset = position[0]; + gPerfStats->FileReadEvent(this, position[nbuffs - 1] + length[nbuffs - 1] + - position[0], start); + } + + if (gMonitoringWriter) + gMonitoringWriter->SendFileReadProgress(this); + + delete statuses; + delete semaphore; + return kFALSE; +} + +//______________________________________________________________________________ +Bool_t TNetXNGFile::WriteBuffer(const char *buffer, Int_t length) +{ + // Write a data chunk + // + // param buffer: the data to be written + // param length: the size of the buffer + // returns: kTRUE in case of failure + + using namespace XrdCl; + + // Check the file isn't a zombie or closed + if (!IsUseable()) + return kTRUE; + + // Check the write cache + Int_t status; + if ((status = WriteBufferViaCache(buffer, length))) { + if (status == 2) + return kTRUE; + return kFALSE; + } + + // Write the data + XRootDStatus st = fFile->Write(fOffset, length, buffer); + if (!st.IsOK()) { + Error("WriteBuffer", "%s", st.ToStr().c_str()); + return kTRUE; + } + + // Bump the globals + fOffset += length; + fBytesWrite += length; + fgBytesWrite += length; + + return kFALSE; +} + +//______________________________________________________________________________ +void TNetXNGFile::Seek(Long64_t offset, ERelativeTo position) +{ + // Set the position within the file + // + // param offset: the new offset relative to position + // param position: the relative position, either kBeg, kCur or kEnd + + SetOffset(offset, position); +} + +//______________________________________________________________________________ +XrdCl::OpenFlags::Flags TNetXNGFile::ParseOpenMode(Option_t *modestr) +{ + // Parse an file open mode given as a string into an integer that the + // client can use + // + // param option: the file open mode as a string + // returns: correctly parsed option mode + + using namespace XrdCl; + OpenFlags::Flags mode = OpenFlags::None; + TString mod = ToUpper(TString(modestr)); + + if (mod == "NEW" || mod == "CREATE") mode = OpenFlags::New; + else if (mod == "RECREATE") mode = OpenFlags::Delete; + else if (mod == "UPDATE") mode = OpenFlags::Update; + else if (mod == "READ") mode = OpenFlags::Read; + + return mode; +} + +//______________________________________________________________________________ +Bool_t TNetXNGFile::IsUseable() const +{ + // Check the file is open and isn't a zombie + + if (IsZombie()) { + Error("TNetXNGFile", "Object is in 'zombie' state"); + return kFALSE; + } + + if (!IsOpen()) { + Error("TNetXNGFile", "The remote file is not open"); + return kFALSE; + } + + return kTRUE; +} + +//______________________________________________________________________________ +Bool_t TNetXNGFile::GetVectorReadLimits() +{ + // Find the server-specific readv config params. Returns kFALSE in case of + // error, kTRUE otherwise. + + using namespace XrdCl; + + // Check the file isn't a zombie or closed + if (!IsUseable()) + return kFALSE; + + URL dataServer(fFile->GetDataServer()); + FileSystem fs(dataServer); + Buffer arg; + Buffer *response; + arg.FromString(std::string("readv_ior_max readv_iov_max")); + + XRootDStatus status = fs.Query(QueryCode::Config, arg, response); + if (!status.IsOK()) { + fReadvIorMax = 2097136; + fReadvIovMax = 1024; + return kFALSE; + } + + Ssiz_t from = 0; + TString token; + fReadvIorMax = fReadvIovMax = 0; + + while (TString(response->ToString()).Tokenize(token, from, "\n")) { + if (fReadvIorMax == 0) fReadvIorMax = token.Atoi(); + else if (fReadvIovMax == 0) fReadvIovMax = token.Atoi(); + } + + delete response; + return kTRUE; +} + +//______________________________________________________________________________ +void TNetXNGFile::SetEnv() +{ + // Map ROOT and xrootd environment variables + + XrdCl::Env *env = XrdCl::DefaultEnv::GetEnv(); + const char *cenv = 0; + TString val; + + val = gEnv->GetValue("NetXNG.ConnectionWindow", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_CONNECTIONWINDOW")) + || strlen(cenv) <= 0)) + env->PutInt("ConnectionWindow", val.Atoi()); + + val = gEnv->GetValue("NetXNG.ConnectionRetry", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_CONNECTIONRETRY")) + || strlen(cenv) <= 0)) + env->PutInt("RequestTimeout", val.Atoi()); + + val = gEnv->GetValue("NetXNG.RequestTimeout", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_REQUESTTIMEOUT")) + || strlen(cenv) <= 0)) + env->PutInt("RequestTimeout", val.Atoi()); + + val = gEnv->GetValue("NetXNG.SubStreamsPerChannel", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_SUBSTREAMSPERCHANNEL")) + || strlen(cenv) <= 0)) + env->PutInt("SubStreamsPerChannel", val.Atoi()); + + val = gEnv->GetValue("NetXNG.TimeoutResolution", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_TIMEOUTRESOLUTION")) + || strlen(cenv) <= 0)) + env->PutInt("TimeoutResolution", val.Atoi()); + + val = gEnv->GetValue("NetXNG.StreamErrorWindow", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_STREAMERRORWINDOW")) + || strlen(cenv) <= 0)) + env->PutInt("StreamErrorWindow", val.Atoi()); + + val = gEnv->GetValue("NetXNG.RunForkHandler", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_RUNFORKHANDLER")) + || strlen(cenv) <= 0)) + env->PutInt("RunForkHandler", val.Atoi()); + + val = gEnv->GetValue("NetXNG.RedirectLimit", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_REDIRECTLIMIT")) + || strlen(cenv) <= 0)) + env->PutInt("RedirectLimit", val.Atoi()); + + val = gEnv->GetValue("NetXNG.WorkerThreads", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_WORKERTHREADS")) + || strlen(cenv) <= 0)) + env->PutInt("WorkerThreads", val.Atoi()); + + val = gEnv->GetValue("NetXNG.CPChunkSize", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_CPCHUNKSIZE")) + || strlen(cenv) <= 0)) + env->PutInt("CPChunkSize", val.Atoi()); + + val = gEnv->GetValue("NetXNG.CPParallelChunks", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_CPPARALLELCHUNKS")) + || strlen(cenv) <= 0)) + env->PutInt("CPParallelChunks", val.Atoi()); + + val = gEnv->GetValue("NetXNG.PollerPreference", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_POLLERPREFERENCE")) + || strlen(cenv) <= 0)) + env->PutString("PollerPreference", val.Data()); + + val = gEnv->GetValue("NetXNG.ClientMonitor", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_CLIENTMONITOR")) + || strlen(cenv) <= 0)) + env->PutString("ClientMonitor", val.Data()); + + val = gEnv->GetValue("NetXNG.ClientMonitorParam", ""); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XRD_CLIENTMONITORPARAM")) + || strlen(cenv) <= 0)) + env->PutString("ClientMonitorParam", val.Data()); + + // Old style netrc file + TString netrc; + netrc.Form("%s/.rootnetrc", gSystem->HomeDirectory()); + gSystem->Setenv("XrdSecNETRC", netrc.Data()); + + // For authentication + val = gEnv->GetValue("XSec.Pwd.ALogFile", ""); + if (val.Length() > 0) + gSystem->Setenv("XrdSecPWDALOGFILE", val.Data()); + + val = gEnv->GetValue("XSec.Pwd.ServerPuk", ""); + if (val.Length() > 0) + gSystem->Setenv("XrdSecPWDSRVPUK", val.Data()); + + val = gEnv->GetValue("XSec.GSI.CAdir", ""); + if (val.Length() > 0) + gSystem->Setenv("XrdSecGSICADIR", val.Data()); + + val = gEnv->GetValue("XSec.GSI.CRLdir", ""); + if (val.Length() > 0) + gSystem->Setenv("XrdSecGSICRLDIR", val.Data()); + + val = gEnv->GetValue("XSec.GSI.CRLextension", ""); + if (val.Length() > 0) + gSystem->Setenv("XrdSecGSICRLEXT", val.Data()); + + val = gEnv->GetValue("XSec.GSI.UserCert", ""); + if (val.Length() > 0) + gSystem->Setenv("XrdSecGSIUSERCERT", val.Data()); + + val = gEnv->GetValue("XSec.GSI.UserKey", ""); + if (val.Length() > 0) + gSystem->Setenv("XrdSecGSIUSERKEY", val.Data()); + + val = gEnv->GetValue("XSec.GSI.UserProxy", ""); + if (val.Length() > 0) + gSystem->Setenv("XrdSecGSIUSERPROXY", val.Data()); + + val = gEnv->GetValue("XSec.GSI.ProxyValid", ""); + if (val.Length() > 0) + gSystem->Setenv("XrdSecGSIPROXYVALID", val.Data()); + + val = gEnv->GetValue("XSec.GSI.ProxyKeyBits", ""); + if (val.Length() > 0) + gSystem->Setenv("XrdSecGSIPROXYKEYBITS", val.Data()); + + val = gEnv->GetValue("XSec.GSI.ProxyForward", "0"); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XrdSecGSIPROXYDEPLEN")) + || strlen(cenv) <= 0)) + gSystem->Setenv("XrdSecGSIPROXYDEPLEN", val.Data()); + + val = gEnv->GetValue("XSec.GSI.CheckCRL", "1"); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XrdSecGSICRLCHECK")) + || strlen(cenv) <= 0)) + gSystem->Setenv("XrdSecGSICRLCHECK", val.Data()); + + val = gEnv->GetValue("XSec.GSI.DelegProxy", "0"); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XrdSecGSIDELEGPROXY")) + || strlen(cenv) <= 0)) + gSystem->Setenv("XrdSecGSIDELEGPROXY", val.Data()); + + val = gEnv->GetValue("XSec.GSI.SignProxy", "1"); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XrdSecGSISIGNPROXY")) + || strlen(cenv) <= 0)) + gSystem->Setenv("XrdSecGSISIGNPROXY", val.Data()); + + val = gEnv->GetValue("XSec.Pwd.AutoLogin", "1"); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XrdSecPWDAUTOLOG")) + || strlen(cenv) <= 0)) + gSystem->Setenv("XrdSecPWDAUTOLOG", val.Data()); + + val = gEnv->GetValue("XSec.Pwd.VerifySrv", "1"); + if (val.Length() > 0 && (!(cenv = gSystem->Getenv("XrdSecPWDVERIFYSRV")) + || strlen(cenv) <= 0)) + gSystem->Setenv("XrdSecPWDVERIFYSRV", val.Data()); +} + diff --git a/net/netxng/src/TNetXNGFileStager.cxx b/net/netxng/src/TNetXNGFileStager.cxx new file mode 100644 index 0000000000000..6584f14d89ddc --- /dev/null +++ b/net/netxng/src/TNetXNGFileStager.cxx @@ -0,0 +1,195 @@ +// @(#)root/netx:$Id$ +/************************************************************************* + * Copyright (C) 1995-2004, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +//////////////////////////////////////////////////////////////////////////////// +// // +// TNetXNGFileStager // +// // +// Authors: Justin Salmon, Lukasz Janyst // +// CERN, 2013 // +// // +// Enables access to XRootD staging capabilities using the new client. // +// // +//////////////////////////////////////////////////////////////////////////////// + +#include "TNetXNGFileStager.h" +#include "TNetXNGSystem.h" +#include "THashList.h" +#include "TFileInfo.h" +#include "TFileCollection.h" +#include <XrdCl/XrdClFileSystem.hh> + +ClassImp( TNetXNGFileStager); + +//______________________________________________________________________________ +TNetXNGFileStager::TNetXNGFileStager(const char *url) : + TFileStager("xrd") +{ + // Constructor + // + // param url: the URL of the entry-point server + + fSystem = new TNetXNGSystem(url); +} + +//______________________________________________________________________________ +TNetXNGFileStager::~TNetXNGFileStager() +{ + // Destructor + + delete fSystem; +} + +//______________________________________________________________________________ +Bool_t TNetXNGFileStager::IsStaged(const char *path) +{ + // Check if a file is staged + // + // param path: the URL of the file + + FileStat_t st; + if (fSystem->GetPathInfo(path, st) != 0) { + if (gDebug > 0) + Info("IsStaged", "path %s cannot be stat'ed", path); + return kFALSE; + } + + if (R_ISOFF(st.fMode)) { + if (gDebug > 0) + Info("IsStaged", "path '%s' is offline", path); + return kFALSE; + } + + return kTRUE; +} + +//______________________________________________________________________________ +Int_t TNetXNGFileStager::Locate(const char *path, TString &url) +{ + // Get actual endpoint URL + // + // param path: the entry-point URL + // param endpath: the actual endpoint URL + // returns: 0 in the case of success and 1 if any error occurred + + return fSystem->Locate(path, url); +} + +//______________________________________________________________________________ +Int_t TNetXNGFileStager::LocateCollection(TFileCollection *fc, + Bool_t addDummyUrl) +{ + // Bulk locate request for a collection of files + // + // param fc: collection of files to be located + // param addDummyUrl: append a dummy noop URL if the file is not staged or + // redirector == endpoint + // returns: < 0 in case of errors, number of files processed + // otherwise + + if (!fc) { + Error("LocateCollection", "No input collection given"); + return -1; + } + + int numFiles = 0; + TFileInfo *info; + TIter it(fc->GetList()); + TString startUrl, endUrl; + + while ((info = dynamic_cast<TFileInfo *>(it.Next())) != NULL) { + startUrl = info->GetCurrentUrl()->GetUrl(); + + // File not staged + if (fSystem->Locate(startUrl.Data(), endUrl)) { + info->ResetBit(TFileInfo::kStaged); + + if (addDummyUrl) + info->AddUrl("noop://none", kTRUE); + + if (gDebug > 1) + Info("LocateCollection", "Not found: %s", startUrl.Data()); + } + + // File staged + else { + info->SetBit(TFileInfo::kStaged); + + if (startUrl != endUrl) { + info->AddUrl(endUrl.Data(), kTRUE); + } else if (addDummyUrl) { + // Returned URL identical to redirector URL + info->AddUrl("noop://redir", kTRUE); + } + + if (gDebug > 1) + Info("LocateCollection", "Found: %s --> %s", startUrl.Data(), + endUrl.Data()); + } + numFiles++; + } + + return numFiles; +} + +//______________________________________________________________________________ +Bool_t TNetXNGFileStager::Matches(const char *s) +{ + // Returns kTRUE if stager 's' is compatible with current stager. Avoids + // multiple instantiations of the potentially the same TNetXNGFileStager. + + return ((s && (fName == s)) ? kTRUE : kFALSE); +} + +//______________________________________________________________________________ +Bool_t TNetXNGFileStager::Stage(const char *path, Option_t *opt) +{ + // Issue a stage request for a single file + // + // param path: the path of the file to stage + // param opt: defines 'option' and 'priority' for 'Prepare': the format is + // opt = "option=o priority=p" + + Int_t priority = ParseStagePriority(opt); + return fSystem->Stage(path, priority); +} + +//______________________________________________________________________________ +Bool_t TNetXNGFileStager::Stage(TCollection *paths, Option_t *opt) +{ + // Issue stage requests for multiple files + // + // param pathlist: list of paths of files to stage + // param opt: defines 'option' and 'priority' for 'Prepare': the + // format is opt = "option=o priority=p" + + Int_t priority = ParseStagePriority(opt); + return fSystem->Stage(paths, priority); +} + +//______________________________________________________________________________ +UChar_t TNetXNGFileStager::ParseStagePriority(Option_t *opt) +{ + // Get a staging priority value from an option string + + UChar_t priority = 0; + Ssiz_t from = 0; + TString token; + + while (TString(opt).Tokenize(token, from, "[ ,|]")) { + if (token.Contains("priority=")) { + token.ReplaceAll("priority=", ""); + if (token.IsDigit()) { + priority = token.Atoi(); + } + } + } + + return priority; +} diff --git a/net/netxng/src/TNetXNGSystem.cxx b/net/netxng/src/TNetXNGSystem.cxx new file mode 100644 index 0000000000000..0950f1b6b4483 --- /dev/null +++ b/net/netxng/src/TNetXNGSystem.cxx @@ -0,0 +1,376 @@ +// @(#)root/netx:$Id$ +/************************************************************************* + * Copyright (C) 1995-2004, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +//////////////////////////////////////////////////////////////////////////////// +// // +// TNetXNGSystem // +// // +// Authors: Justin Salmon, Lukasz Janyst // +// CERN, 2013 // +// // +// Enables access to XRootD filesystem interface using the new client. // +// // +//////////////////////////////////////////////////////////////////////////////// + +#include "TNetXNGSystem.h" +#include "TFileStager.h" +#include "Rtypes.h" +#include "TList.h" +#include "TUrl.h" +#include <XrdCl/XrdClFileSystem.hh> +#include <XrdCl/XrdClXRootDResponses.hh> + +ClassImp(TNetXNGSystem); + +namespace +{ + struct DirectoryInfo { + XrdCl::URL *fUrl; // Path of this directory + XrdCl::DirectoryList *fDirList; // Directory listing + XrdCl::DirectoryList::Iterator *fDirListIter; // Iterator for this listing + + public: + DirectoryInfo(const char *dir) : fUrl(new XrdCl::URL(dir)), fDirList(0), fDirListIter(0) {} + + ~DirectoryInfo() { + delete fUrl; + delete fDirList; + } + }; +} + +//______________________________________________________________________________ +TNetXNGSystem::TNetXNGSystem(Bool_t /*owner*/) : + TSystem("-root", "Net file Helper System"), fUrl(0), fFileSystem(0) +{ + // Constructor: Create system class without connecting to server + // + // param owner: (unused) + + // Name must start with '-' to bypass the TSystem singleton check, then + // be changed to "root" + SetName("root"); +} + +//______________________________________________________________________________ +TNetXNGSystem::TNetXNGSystem(const char *url, Bool_t /*owner*/) : + TSystem("-root", "Net file Helper System") +{ + // Constructor: Create system class and connect to server + // + // param url: URL of the entry-point server to be contacted + // param owner: (unused) + + using namespace XrdCl; + + // Name must start with '-' to bypass the TSystem singleton check + SetName("root"); + fUrl = new URL(std::string(url)); + fFileSystem = new FileSystem(fUrl->GetURL()); +} + +//______________________________________________________________________________ +TNetXNGSystem::~TNetXNGSystem() +{ + // Destructor + + delete fFileSystem; + delete fUrl; +} + +//______________________________________________________________________________ +void* TNetXNGSystem::OpenDirectory(const char *dir) +{ + // Open a directory + // + // param dir: the name of the directory to open + // returns: a non-zero pointer (with no special purpose) in case of + // success, 0 in case of error + + using namespace XrdCl; + + DirectoryInfo *dirInfo = new DirectoryInfo(dir); + return (void *) dirInfo; +} + +//______________________________________________________________________________ +Int_t TNetXNGSystem::MakeDirectory(const char *dir) +{ + // Create a directory + // + // param dir: the directory name + // returns: 0 on success, -1 otherwise + + using namespace XrdCl; + URL url(dir); + XRootDStatus st = fFileSystem->MkDir(url.GetPath(), MkDirFlags::MakePath, + Access::None); + if (!st.IsOK()) { + Error("MakeDirectory", "%s", st.GetErrorMessage().c_str()); + return -1; + } + + return 0; +} + +//______________________________________________________________________________---- +void TNetXNGSystem::FreeDirectory(void *dirp) +{ + // Free a directory + // + // param dirp: the pointer to the directory to be freed + + delete (DirectoryInfo *) dirp; +} + +//______________________________________________________________________________ +const char* TNetXNGSystem::GetDirEntry(void *dirp) +{ + // Get a directory entry. + // + // param dirp: the directory pointer + // returns: 0 in case there are no more entries + + using namespace XrdCl; + DirectoryInfo *dirInfo = (DirectoryInfo *) dirp; + + if (!dirInfo->fDirList) { + XRootDStatus st = fFileSystem->DirList(dirInfo->fUrl->GetPath(), + DirListFlags::Locate, + dirInfo->fDirList); + if (!st.IsOK()) { + Error("GetDirEntry", "%s", st.GetErrorMessage().c_str()); + return 0; + } + dirInfo->fDirListIter = new DirectoryList::Iterator(dirInfo->fDirList->Begin()); + } + + if (*(dirInfo->fDirListIter) != dirInfo->fDirList->End()) { + const char *filename = (**(dirInfo->fDirListIter))->GetName().c_str(); + (*(dirInfo->fDirListIter))++; + return filename; + + } else { + return 0; + } +} + +//______________________________________________________________________________ +Int_t TNetXNGSystem::GetPathInfo(const char *path, FileStat_t &buf) +{ + // Get info about a file (stat) + // + // param path: the path of the file to stat (in) + // param buf: structure that will hold the stat info (out) + // returns: 0 if success, 1 if the file could not be stat'ed + + using namespace XrdCl; + StatInfo *info = 0; + URL target(path); + XRootDStatus st = fFileSystem->Stat(target.GetPath(), info); + + if (!st.IsOK()) { + + Error("GetPathInfo", "Error: %s", st.GetErrorMessage().c_str()); + delete info; + return 1; + + } else { + + // Flag offline files + if (info->TestFlags(StatInfo::Offline)) { + buf.fMode = kS_IFOFF; + } else { + std::stringstream sstr(info->GetId()); + Long64_t id; + sstr >> id; + + buf.fDev = (id >> 32); + buf.fIno = (id & 0x00000000FFFFFFFF); + buf.fUid = -1; // not available + buf.fGid = -1; // not available + buf.fIsLink = 0; // not available + buf.fSize = info->GetSize(); + buf.fMtime = info->GetModTime(); + + if (info->TestFlags(StatInfo::XBitSet)) + buf.fMode = (kS_IFREG | kS_IXUSR | kS_IXGRP | kS_IXOTH); + if (info->GetFlags() == 0) buf.fMode = kS_IFREG; + if (info->TestFlags(StatInfo::IsDir)) buf.fMode = kS_IFDIR; + if (info->TestFlags(StatInfo::Other)) buf.fMode = kS_IFSOCK; + if (info->TestFlags(StatInfo::IsReadable)) buf.fMode |= kS_IRUSR; + if (info->TestFlags(StatInfo::IsWritable)) buf.fMode |= kS_IWUSR; + } + } + + delete info; + return 0; +} + +//______________________________________________________________________________ +Bool_t TNetXNGSystem::ConsistentWith(const char *path, void *dirptr) +{ + // Check consistency of this helper with the one required by 'path' or + // 'dirptr' + // + // param path: the path to check + // param dirptr: the directory pointer to check + + using namespace XrdCl; + + // Standard check: only the protocol part of 'path' is required to match + Bool_t checkstd = TSystem::ConsistentWith(path, dirptr); + if (!checkstd) + return kFALSE; + + URL url(path); + Bool_t checknet = path ? kFALSE : kTRUE; + + if (gDebug > 1) + Info("ConsistentWith", "fUser:'%s' (%s), fHost:'%s' (%s), fPort:%d (%d)", + fUrl->GetUserName().c_str(), url.GetUserName().c_str(), + fUrl->GetHostName().c_str(), url.GetHostName().c_str(), + fUrl->GetPort(), url.GetPort()); + + // Require match of 'user' and 'host' + if (fUrl->GetUserName() == url.GetUserName() + && fUrl->GetHostName() == url.GetHostName() + && fUrl->GetPort() == url.GetPort()) + checknet = kTRUE; + + return (checkstd && checknet); +} + +//______________________________________________________________________________ +int TNetXNGSystem::Unlink(const char *path) +{ + // Unlink a file on the remote server + // + // param path: the path of the file to unlink + // returns: 0 on success, -1 otherwise + + using namespace XrdCl; + StatInfo *info; + URL url(path); + + // Stat the path to find out if it's a file or a directory + XRootDStatus st = fFileSystem->Stat(url.GetPath(), info); + if (!st.IsOK()) { + Error("Unlink", "%s", st.GetErrorMessage().c_str()); + delete info; + return -1; + } + + if (info->TestFlags(StatInfo::IsDir)) + st = fFileSystem->RmDir(url.GetPath()); + else + st = fFileSystem->Rm(url.GetPath()); + delete info; + + if (!st.IsOK()) { + Error("Unlink", "%s", st.GetErrorMessage().c_str()); + return -1; + } + + return 0; +} + +//______________________________________________________________________________ +Bool_t TNetXNGSystem::IsPathLocal(const char *path) +{ + // Is this path a local path? + // + // param path: the URL of the path to check + // returns: kTRUE if the path is local, kFALSE otherwise + + return TSystem::IsPathLocal(path); +} + +//______________________________________________________________________________ +Int_t TNetXNGSystem::Locate(const char *path, TString &endurl) +{ + // Get the endpoint URL of a file. + // + // param path: the entry-point URL of the file (in) + // param endurl: the endpoint URL of the file (out) + // returns: 0 in case of success and 1 if the file could not be + // stat'ed. + + using namespace XrdCl; + LocationInfo *info = 0; + URL pathUrl(path); + + // Locate the file + XRootDStatus st = fFileSystem->Locate(pathUrl.GetPath(), OpenFlags::None, + info); + if (!st.IsOK()) { + Error("Locate", "%s", st.GetErrorMessage().c_str()); + delete info; + return 1; + } + + // Return the first address + endurl = info->Begin()->GetAddress(); + delete info; + return 0; +} + +//______________________________________________________________________________ +Int_t TNetXNGSystem::Stage(const char* path, UChar_t priority) +{ + // Issue a stage request for a single file + // + // param path: the path of the file to stage + // param opt: defines 'option' and 'priority' for 'Prepare': the format is + // opt = "option=o priority=p" + // returns: 0 for success, -1 for error + + TList *files = new TList(); + files->Add((TObject *) new TUrl(path)); + return Stage((TCollection *) files, priority); +} + +//______________________________________________________________________________ +Int_t TNetXNGSystem::Stage(TCollection *files, UChar_t priority) +{ + // Issue stage requests for multiple files + // + // param pathlist: list of paths of files to stage + // param opt: defines 'option' and 'priority' for 'Prepare': the + // format is opt = "option=o priority=p" + // returns: 0 for success, -1 for error + + using namespace XrdCl; + std::vector<std::string> fileList; + TIter it(files); + TObject *object = 0; + + while ((object = (TObject *) it.Next())) { + + TString path = TFileStager::GetPathName(object); + if (path == "") { + Warning("Stage", "object is of unexpected type %s - ignoring", + object->ClassName()); + continue; + } + + fileList.push_back(std::string(URL(path.Data()).GetPath())); + } + + Buffer *response; + XRootDStatus st = fFileSystem->Prepare(fileList, PrepareFlags::Stage, + (uint8_t) priority, response); + if (!st.IsOK()) { + Error("Stage", "%s", st.GetErrorMessage().c_str()); + return -1; + } + + return 0; +} + diff --git a/net/rootd/src/rootd.cxx b/net/rootd/src/rootd.cxx index 77218ce055d5b..36834b3e02b63 100644 --- a/net/rootd/src/rootd.cxx +++ b/net/rootd/src/rootd.cxx @@ -148,7 +148,7 @@ // Where /var/spool/rootd must match the rootd home directory as // // specified in the rootd /etc/passwd entry. // // // -// - To make writeable directories for anonymous do, for example: // +// - To make writable directories for anonymous do, for example: // // // // mkdir /var/spool/rootd/pub // // chown rootd:rootd /var/spool/rootd/pub // @@ -745,6 +745,7 @@ void RootdCloseTab(int force = 0) // lock the file if (lockf(fid, F_LOCK, (off_t)1) == -1) { ErrorInfo("RootdCloseTab: error locking %s", sfile); + close(fid); return; } if (gDebug > 2) @@ -814,6 +815,7 @@ void RootdCloseTab(int force = 0) lseek(fid, 0, SEEK_SET); if (lockf(fid, F_ULOCK, (off_t)1) == -1) { ErrorInfo("RootdCloseTab: error unlocking %s", sfile); + close(fid); return; } if (gDebug > 2) diff --git a/net/rpdutils/CMakeLists.txt b/net/rpdutils/CMakeLists.txt index 06a20e7237729..0409a2489d8c4 100644 --- a/net/rpdutils/CMakeLists.txt +++ b/net/rpdutils/CMakeLists.txt @@ -9,7 +9,12 @@ ROOT_USE_PACKAGE(net/auth) ROOT_GLOB_SOURCES(rpdutilsrcs RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/src/*.cxx) list(REMOVE_ITEM rpdutilsrcs src/rpdpriv.cxx src/rpdconn.cxx) -if(GLOBUS_FOUND) +if(globus) + add_definitions(-DR__GLBS) + include_directories(${GLOBUS_INCLUDE_DIRS}) + if(GLOBUS_gsi_credential_FOUND) + add_definitions(-DR__GLBS22) + endif() else() list(REMOVE_ITEM rpdutilsrcs src/globus.cxx) endif() @@ -22,7 +27,7 @@ endif() #---static library needed for rootd and proofd -------------------------------------------- add_library(rpdutil STATIC ${rpdutilsrcs}) -ROOT_LINKER_LIBRARY(SrvAuth rpdutils.cxx ssh.cxx LIBRARIES rpdutil rsa ${CRYPTLIBS} DEPENDENCIES Net) +ROOT_LINKER_LIBRARY(SrvAuth rpdutils.cxx ssh.cxx LIBRARIES rpdutil rsa ${CRYPTLIBS} ${GLOBUS_LIBRARIES} ${OPENSSL_LIBRARIES} DEPENDENCIES Net) diff --git a/net/rpdutils/src/globus.cxx b/net/rpdutils/src/globus.cxx index 98a8cbc416d82..c539b903a8e79 100644 --- a/net/rpdutils/src/globus.cxx +++ b/net/rpdutils/src/globus.cxx @@ -560,7 +560,7 @@ int GlbsToolCheckProxy(char **subjname) } #else - // Old version: completly different ... + // Old version: completely different ... char * proxy_type; proxy_cred_desc * pcd = 0; time_t time_after; diff --git a/net/rpdutils/src/rpdutils.cxx b/net/rpdutils/src/rpdutils.cxx index b22008c544691..bfd4b5ed8f1be 100644 --- a/net/rpdutils/src/rpdutils.cxx +++ b/net/rpdutils/src/rpdutils.cxx @@ -944,7 +944,7 @@ int RpdUpdateAuthTab(int opt, const char *line, char **token, int ilck) } goingout: - if (ilck == 0) { + if (itab != ilck) { // unlock the file lseek(itab, 0, SEEK_SET); if (lockf(itab, F_ULOCK, (off_t) 1) == -1) { @@ -1520,7 +1520,8 @@ int RpdCheckOffSet(int Sec, const char *User, const char *Host, int RemId, // Reset original IDs if (getuid() != fromUid) - setresuid(fromUid,fromEUid,pw->pw_uid); + if (setresuid(fromUid, fromEUid, pw->pw_uid) == -1) + goodOfs = 0; } else { // Since we could not set the user IDs, we will @@ -2450,6 +2451,7 @@ int RpdSshAuth(const char *sstr) NetSend(kErrNoPipeInfo, kROOTD_ERR); delete[] uniquePipe; delete[] pipeFile; + close(unixFd); return auth; } else { // File open: fill it @@ -3605,7 +3607,7 @@ int RpdCheckHostsEquiv(const char *host, const char *ruser, //______________________________________________________________________________ int RpdCheckSpecialPass(const char *passwd) { - // Check recieved user's password against password in $HOME/.rootdpass. + // Check received user's password against password in $HOME/.rootdpass. // The password is retrieved in RpdUser and temporarly saved in gPasswd. // Returns 1 in case of success authentication, 0 otherwise. @@ -4516,14 +4518,17 @@ int RpdCheckSshd(int opt) localAddr.sin_port = htons(0); if (bind(sd, (struct sockaddr *) &localAddr, sizeof(localAddr)) < 0) { ErrorInfo("RpdCheckSshd: cannot bind to local port %u", gSshdPort); + close(sd); return 0; } // connect to server if (connect(sd, (struct sockaddr *) &servAddr, sizeof(servAddr)) < 0) { ErrorInfo("RpdCheckSshd: cannot connect to local port %u", gSshdPort); + close(sd); return 0; } + close(sd); // Sshd successfully contacted if (gDebug > 2) ErrorInfo("RpdCheckSshd: success!"); @@ -6634,6 +6639,7 @@ int RpdRetrieveSpecialPass(const char *usr, const char *fpw, char *pass, int lpw if (fstat(fid, &st) == -1) { ErrorInfo("RpdRetrieveSpecialPass: cannot stat descriptor %d" " %s (errno: %d)", fid, GetErrno()); + close(fid); rc = -1; goto back; } @@ -6643,6 +6649,7 @@ int RpdRetrieveSpecialPass(const char *usr, const char *fpw, char *pass, int lpw " 0%o (should be 0600)", rootdpass, (st.st_mode & 0777)); ErrorInfo("RpdRetrieveSpecialPass: %d %d", S_ISREG(st.st_mode),S_ISDIR(st.st_mode)); + close(fid); rc = -2; goto back; } diff --git a/net/rpdutils/src/ssh.cxx b/net/rpdutils/src/ssh.cxx index 5b7b2485d4f57..9967212bc678c 100644 --- a/net/rpdutils/src/ssh.cxx +++ b/net/rpdutils/src/ssh.cxx @@ -227,6 +227,7 @@ int SshToolNotifyFailure(const char *Pipe) connect(sd, (struct sockaddr *) &servAddr, sizeof(servAddr))) < 0) { ErrorInfo("SshToolNotifyFailure: cannot connect socket: exiting "); + close(sd); return 1; } // Sending "KO" ... @@ -237,6 +238,7 @@ int SshToolNotifyFailure(const char *Pipe) ("SshToolNotifyFailure: sending might have been unsuccessful (bytes send: %d)", rc); } + close(sd); return 0; } diff --git a/proof/CMakeLists.txt b/proof/CMakeLists.txt index 5a630ebd78862..5545c75f1d829 100644 --- a/proof/CMakeLists.txt +++ b/proof/CMakeLists.txt @@ -1,6 +1,10 @@ add_subdirectory(proof) add_subdirectory(proofplayer) # special CMakeListst.txt +if(afdsmgrd) + add_subdirectory(afdsmgrd) +endif() if(xrootd) add_subdirectory(proofd) add_subdirectory(proofx) + add_subdirectory(proofbench) endif() diff --git a/proof/afdsmgrd/CMakeLists.txt b/proof/afdsmgrd/CMakeLists.txt new file mode 100644 index 0000000000000..b327f7bea0a49 --- /dev/null +++ b/proof/afdsmgrd/CMakeLists.txt @@ -0,0 +1,152 @@ +############################################################################ +# CMakeLists.txt file for building PROOF's afdsmgrd +# @author Dario Berzano +############################################################################ + +# +# Variables for afdsmgrd: all of them are *absolute* paths +# + +set(AFDSMGRD_UNPACK_DIR ${CMAKE_CURRENT_BINARY_DIR}/afdsmgrd) +set(AFDSMGRD_INSTALL_DIR ${AFDSMGRD_UNPACK_DIR}/install) +set(AFDSMGRD_BUILD_DIR ${AFDSMGRD_UNPACK_DIR}/build) +set(AFDSMGRD_BIN ${AFDSMGRD_INSTALL_DIR}/bin/afdsmgrd) + +# Taking MonALISA from MONALISA_DIR, if defined, or from AliEn. If neither +# MonALISA nor AliEn are enabled, don't build afdsmgrd with MonALISA support +if(monalisa) + set(AFDSMGRD_MONALISA_DIR "${MONALISA_DIR}") +elseif(alien) + set(AFDSMGRD_MONALISA_DIR "${ALIEN_DIR}") +endif() + +# MonALISA is disabled when no MonALISA directory was given +if(AFDSMGRD_MONALISA_DIR) + set(AFDSMGRD_MONALISA_DISABLED 0) +else() + set(AFDSMGRD_MONALISA_DISABLED 1) +endif() + +# +# Pass all possible ROOT include paths to underlying CMake +# + +# Get all possible include paths into a variable (one path per line) +execute_process( + COMMAND find "${CMAKE_SOURCE_DIR}" -maxdepth 3 -name inc -type d + OUTPUT_VARIABLE AFDSMGRD_INCDIR_Raw + OUTPUT_STRIP_TRAILING_WHITESPACE +) + +# Separate paths with colons +string(REPLACE "\n" ":" AFDSMGRD_INCDIR_Path ${AFDSMGRD_INCDIR_Raw}) + +# +# Build targets +# + +# afdsmgrd steering target, always built (i.e., "phony", i.e., always ood). Let +# this target depend on ALL known ROOT libraries (TODO: Maybe there is a better +# way to get the list of ROOT libs?) +add_custom_target(afdsmgrd ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/afdsmgrdInstall) + +# make install on afdsmgrd +add_custom_command( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/afdsmgrdInstall + COMMENT "Building afdsmgrd" + DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/afdsmgrdPrepare + + COMMAND ${CMAKE_COMMAND} -E remove -f afdsmgrdInstall + + COMMAND make install -C ${AFDSMGRD_BUILD_DIR} + + # Workaround: on some configurations libdir is not created (because there is + # no need to) causing subsequent "install" command to fail + COMMAND ${CMAKE_COMMAND} -E make_directory ${AFDSMGRD_INSTALL_DIR}/lib + + COMMAND ${CMAKE_COMMAND} -E touch afdsmgrdInstall +) + +# CMake configuration of afdsmgrd +add_custom_command( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/afdsmgrdPrepare + COMMENT "Preparing afdsmgrd" + DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/afdsmgrdUnpack + + # The file afdsmgrdPrepare is created to signal a success: reset it + COMMAND ${CMAKE_COMMAND} -E remove -f afdsmgrdPrepare + + # Create build directory + COMMAND ${CMAKE_COMMAND} -E make_directory ${AFDSMGRD_BUILD_DIR} + + # Run cmake on the afdsmgrd project: mind the EXTRA_INCDIR variable + COMMAND ${CMAKE_COMMAND} -E chdir ${AFDSMGRD_BUILD_DIR} ${CMAKE_COMMAND} .. + -DCMAKE_INSTALL_PREFIX="${AFDSMGRD_INSTALL_DIR}" + -DROOTSYS="${CMAKE_BINARY_DIR}" + -DApMon_PREFIX="${AFDSMGRD_MONALISA_DIR}" + -DApMon_DISABLED="${AFDSMGRD_MONALISA_DISABLED}" + -DCMAKE_BUILD_TYPE=Release + -DEXTRA_INCDIR="${AFDSMGRD_INCDIR_Path}" + + # The following command won't be executed if previous command has failed + COMMAND ${CMAKE_COMMAND} -E touch afdsmgrdPrepare +) + +# Unpacks afdsmgrd tar.gz found in source directory into build directory (which +# is current working directory by default) +add_custom_command( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/afdsmgrdUnpack + DEPENDS Core Cint RIO Net Hist Graf Graf3d Gpad Tree Rint Postscript Matrix + Physics MathCore Thread Proof + COMMENT "Unpacking afdsmgrd tarball" + COMMAND ${CMAKE_COMMAND} -E tar xzf + ${CMAKE_CURRENT_SOURCE_DIR}/afdsmgrd-v*.tar.gz + COMMAND ${CMAKE_COMMAND} -E touch afdsmgrdUnpack +) + +# +# Install targets -- note that the trailing slashes are fundamental +# + +# etc --> <prefix>/etc/proof +install( + DIRECTORY ${AFDSMGRD_INSTALL_DIR}/etc/ + DESTINATION ${CMAKE_INSTALL_PREFIX}/etc/proof + USE_SOURCE_PERMISSIONS +) + +# bin --> <prefix>/bin +install( + DIRECTORY ${AFDSMGRD_INSTALL_DIR}/bin/ + DESTINATION ${CMAKE_INSTALL_PREFIX}/bin + USE_SOURCE_PERMISSIONS +) + +# lib --> <prefix>/etc/proof/lib +install( + DIRECTORY ${AFDSMGRD_INSTALL_DIR}/lib/ + DESTINATION ${CMAKE_INSTALL_PREFIX}/etc/proof/lib + USE_SOURCE_PERMISSIONS +) + +# libexec --> <prefix>/etc/proof +install( + DIRECTORY ${AFDSMGRD_INSTALL_DIR}/libexec/ + DESTINATION ${CMAKE_INSTALL_PREFIX}/etc/proof + USE_SOURCE_PERMISSIONS +) + +# var --> <prefix>/etc/proof/var +# Nothing goes here for the moment! +#install( +# DIRECTORY ${AFDSMGRD_INSTALL_DIR}/var/ +# DESTINATION ${CMAKE_INSTALL_PREFIX}/etc/proof/var +# USE_SOURCE_PERMISSIONS +#) + +# share --> <prefix>/etc/proof/utils/afdsmgrd +install( + DIRECTORY ${AFDSMGRD_INSTALL_DIR}/share/ + DESTINATION ${CMAKE_INSTALL_PREFIX}/etc/proof/utils/afdsmgrd + USE_SOURCE_PERMISSIONS +) diff --git a/proof/afdsmgrd/Module.mk b/proof/afdsmgrd/Module.mk index 4e4402f582f7e..9333c9eb17d20 100644 --- a/proof/afdsmgrd/Module.mk +++ b/proof/afdsmgrd/Module.mk @@ -10,66 +10,81 @@ AFDSMGRDDIR := $(MODDIR) AFDSMGRDBIN := bin/afdsmgrd AFDSMGRDTAR := $(shell cd $(AFDSMGRDDIR) && ls -1 afdsmgrd-v*.tar.gz | tail -1) +AFDSMGRDPREP := $(AFDSMGRDDIR)/afdsmgrdPrepare +AFDSMGRDINST := $(AFDSMGRDDIR)/afdsmgrdInstall +AFDSMGRDUNPACK := $(AFDSMGRDDIR)/afdsmgrdUnpack + +AFDSMGRDBUILDDIR := $(AFDSMGRDDIR)/afdsmgrd/build + # This one triggers the build from ROOT ALLEXECS += $(AFDSMGRDBIN) +# ApMon: from Makefile.config +ifeq ($(AFDSMGRDAPMON),) + AFDSMGRDAPMONDISABLED := 1 +else + AFDSMGRDAPMONDISABLED := 0 +endif + # Phony targets .PHONY: all-$(MODNAME) clean-$(MODNAME) distclean-$(MODNAME) -# The tar file is unpacked and the project is configured and built through -# afdsmgrd's custom built system. Proper variables are passed to ./configure, -# including the option to enable/disable ApMon, and files are installed under -# $ROOTSYS properly directly by invoking "make install" -$(AFDSMGRDBIN): $(ALLLIBS) - @( cd $(AFDSMGRDDIR) && \ - if [ ! -d afdsmgrd ]; then \ - echo "*** Unpacking afdsmgrd tarball ***" ; \ - tar xzf "$(AFDSMGRDTAR)" ; \ - fi && \ - cd afdsmgrd && \ - if [ ! -d build ]; then \ - ./configure --with-rootsys="$(ROOT_SRCDIR)" "$(AFDSMGRDAPMON)" \ - --prefix="$(ROOT_SRCDIR)" --root-mode ; \ - fi && \ - make install ; \ - ) +# This target is directly invoked by ROOT's make +$(AFDSMGRDBIN): $(AFDSMGRDINST) + +# Build afdsmgrd and install it under ROOT's source (ROOT_MODE is on) +$(AFDSMGRDINST): $(AFDSMGRDPREP) + @echo 'Building afdsmgrd' + @$(MAKE) install -C "$(AFDSMGRDBUILDDIR)" --no-print-directory + @touch "$(AFDSMGRDINST)" + +# Prepare afdsmgrd: run cmake +$(AFDSMGRDPREP): $(AFDSMGRDUNPACK) + @echo 'Preparing afdsmgrd' + @( mkdir -p "$(AFDSMGRDBUILDDIR)" && \ + cd "$(AFDSMGRDBUILDDIR)" && \ + cmake .. \ + -DROOT_MODE=TRUE \ + -DROOTSYS="$(ROOT_SRCDIR)" \ + -DApMon_PREFIX="$(AFDSMGRDAPMON)" \ + -DApMon_DISABLED="$(AFDSMGRDAPMONDISABLED)" \ + -DCMAKE_BUILD_TYPE=Release ) + @touch "$(AFDSMGRDPREP)" + +# Unpack latest afdsmgrd tarball +$(AFDSMGRDUNPACK): $(ALLLIBS) + @echo 'Unpacking afdsmgrd tarball' + @( cd "$(AFDSMGRDDIR)" && \ + tar xzf "$(AFDSMGRDTAR)" && \ + touch "$(AFDSMGRDUNPACK)" ) # Default target invoked when building this module all-$(MODNAME): $(AFDSMGRDBIN) -# Simple cleanup of afdsmgrd. The "clean" target of afdsmgrd is called without -# removing the directory where the source was unpacked. If the project hasn't -# been built yet, it just exits without printing a single message +# Shallow cleanup of afdsmgrd: a rebuild will be forced at next "make". This is +# a silent target if afdsmgrd hasn't been built (yet) clean-$(MODNAME): - @( rm -f $(ROOT_SRCDIR)/$(AFDSMGRDBIN) ; \ - cd "$(AFDSMGRDDIR)" ; \ - if [ -d afdsmgrd ]; then \ - echo "*** Cleaning up afdsmgrd ***" ; \ - cd afdsmgrd && \ - make clean ; \ - fi ; \ - ) - -# Append this clean-afdsmgrd action to the global "clean" target in main -# Makefile + @( if [ -f "$(AFDSMGRDBUILDDIR)/Makefile" ] ; then \ + echo 'Shallow cleanup of afdsmgrd' ; \ + $(MAKE) clean -C "$(AFDSMGRDBUILDDIR)" --no-print-directory ; \ + rm -f "$(AFDSMGRDINST)" ; \ + fi ) + +# Append this clean-afdsmgrd action to the global "clean" target clean:: clean-$(MODNAME) -# Deep cleanup of afdsmgrd. If the unpack directory exists, it is removed and a -# message is printed out. If the directory does not exist (afdsmgrd was never -# built before) it does nothing without printing a single message. Every file -# copied during afdsmgrd's "make install" is removed by means of the uninstall -# feature ("make uninstall") +# Deep cleanup of afdsmgrd: generated files are unstaged from ROOT's source +# directory and all compilation-time temporary files are removed distclean-$(MODNAME): - @( cd "$(AFDSMGRDDIR)" ; \ - if [ -d afdsmgrd ]; then \ - echo "*** Completely cleaning up afdsmgrd ***" ; \ - cd afdsmgrd && \ - make uninstall && \ - cd .. && \ - rm -r afdsmgrd ; \ - fi ; \ - ) - -# Append this distclean-afdsmgrd action to the global "distclean" target in -# main Makefile + @( if [ -f "$(AFDSMGRDBUILDDIR)/Makefile" ] ; then \ + echo 'Unstaging afdsmgrd files from ROOT' ; \ + $(MAKE) uninstall -C "$(AFDSMGRDBUILDDIR)" --no-print-directory ; \ + fi ) + @( if [ -d "$(AFDSMGRDDIR)/afdsmgrd" ] ; then \ + echo 'Deep cleanup of afdsmgrd' ; \ + rm -rf "$(AFDSMGRDPREP)" "$(AFDSMGRDINST)" "$(AFDSMGRDUNPACK)" \ + "$(AFDSMGRDDIR)/afdsmgrd" ; \ + fi ) + +# Append this distclean-afdsmgrd action to the global "distclean" target distclean:: distclean-$(MODNAME) diff --git a/proof/afdsmgrd/afdsmgrd-v0.9.6.tar.gz b/proof/afdsmgrd/afdsmgrd-v0.9.6.tar.gz deleted file mode 100644 index 8ba05553dc171..0000000000000 Binary files a/proof/afdsmgrd/afdsmgrd-v0.9.6.tar.gz and /dev/null differ diff --git a/proof/afdsmgrd/afdsmgrd-v1.1.0.tar.gz b/proof/afdsmgrd/afdsmgrd-v1.1.0.tar.gz new file mode 100644 index 0000000000000..5d862b5a4cccf Binary files /dev/null and b/proof/afdsmgrd/afdsmgrd-v1.1.0.tar.gz differ diff --git a/proof/clarens/Module.mk b/proof/clarens/Module.mk deleted file mode 100644 index 7ea7a125215a2..0000000000000 --- a/proof/clarens/Module.mk +++ /dev/null @@ -1,72 +0,0 @@ -# Module.mk for clarens module -# Copyright (c) 2004 Rene Brun and Fons Rademakers -# -# Author: Maarten Ballintijn 18/10/2004 - -MODNAME := clarens -MODDIR := $(ROOT_SRCDIR)/proof/$(MODNAME) -MODDIRS := $(MODDIR)/src -MODDIRI := $(MODDIR)/inc - -CLARENSDIR := $(MODDIR) -CLARENSDIRS := $(CLARENSDIR)/src -CLARENSDIRI := $(CLARENSDIR)/inc - -##### libClarens ##### -CLARENSL := $(MODDIRI)/LinkDef.h -CLARENSDS := $(call stripsrc,$(MODDIRS)/G__Clarens.cxx) -CLARENSDO := $(CLARENSDS:.cxx=.o) -CLARENSDH := $(CLARENSDS:.cxx=.h) - -CLARENSH := $(filter-out $(MODDIRI)/LinkDef%,$(wildcard $(MODDIRI)/*.h)) -CLARENSS := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx)) -CLARENSO := $(call stripsrc,$(CLARENSS:.cxx=.o)) - -CLARENSDEP := $(CLARENSO:.o=.d) $(CLARENSDO:.o=.d) - -CLARENSLIB := $(LPATH)/libClarens.$(SOEXT) -CLARENSMAP := $(CLARENSLIB:.$(SOEXT)=.rootmap) - -# used in the main Makefile -ALLHDRS += $(patsubst $(MODDIRI)/%.h,include/%.h,$(CLARENSH)) -ALLLIBS += $(CLARENSLIB) -ALLMAPS += $(CLARENSMAP) - -# include all dependency files -INCLUDEFILES += $(CLARENSDEP) - -##### local rules ##### -.PHONY: all-$(MODNAME) clean-$(MODNAME) distclean-$(MODNAME) - -include/%.h: $(CLARENSDIRI)/%.h - cp $< $@ - -$(CLARENSLIB): $(CLARENSO) $(CLARENSDO) $(ORDER_) $(MAINLIBS) $(CLARENSLIBDEP) - @$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \ - "$(SOFLAGS)" libClarens.$(SOEXT) $@ \ - "$(CLARENSO) $(CLARENSDO) $(CLARENSLIBS)" \ - "$(CLARENSLIBEXTRA) $(CRYPTOLIBDIR) $(CRYPTOLIB)" - -$(CLARENSDS): $(CLARENSH) $(CLARENSL) $(ROOTCINTTMPDEP) - $(MAKEDIR) - @echo "Generating dictionary $@..." - $(ROOTCINTTMP) -f $@ -c $(CLARENSH) $(CLARENSL) - -$(CLARENSMAP): $(RLIBMAP) $(MAKEFILEDEP) $(CLARENSL) - $(RLIBMAP) -o $@ -l $(CLARENSLIB) \ - -d $(CLARENSLIBDEPM) -c $(CLARENSL) - -all-$(MODNAME): $(CLARENSLIB) $(CLARENSMAP) - -clean-$(MODNAME): - @rm -f $(CLARENSO) $(CLARENSDO) - -clean:: clean-$(MODNAME) - -distclean-$(MODNAME): clean-$(MODNAME) - @rm -f $(CLARENSDEP) $(CLARENSDS) $(CLARENSDH) $(CLARENSLIB) $(CLARENSMAP) - -distclean:: distclean-$(MODNAME) - -##### extra rules ###### -$(CLARENSO) $(CLARENSDO): CXXFLAGS += $(CLARENSINC) diff --git a/proof/clarens/inc/LinkDef.h b/proof/clarens/inc/LinkDef.h deleted file mode 100644 index d277ef382e84c..0000000000000 --- a/proof/clarens/inc/LinkDef.h +++ /dev/null @@ -1,30 +0,0 @@ -/* @(#)root/clarens:$Id$ */ - -/************************************************************************* - * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifdef __CINT__ - -#pragma link off all globals; -#pragma link off all classes; -#pragma link off all functions; - -#pragma link C++ global gClarens; - -#pragma link C++ class TClarens; -#pragma link C++ class TClSession; -#pragma link C++ class TClProxy; -#pragma link C++ class TXmlRpc; -#pragma link C++ class TEcho; -#pragma link C++ class TGM; -#pragma link C++ class TGM::TFileParams; -#pragma link C++ class TLM; -#pragma link C++ class TLM::TSlaveParams; -#pragma link C++ class TSAM; - -#endif diff --git a/proof/clarens/inc/TClProxy.h b/proof/clarens/inc/TClProxy.h deleted file mode 100644 index dee361106ff7f..0000000000000 --- a/proof/clarens/inc/TClProxy.h +++ /dev/null @@ -1,44 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 26/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_TClProxy -#define ROOT_TClProxy - -////////////////////////////////////////////////////////////////////////// -// // -// TClProxy // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#ifndef ROOT_TObject -#include "TObject.h" -#endif - - -class TXmlRpc; - - -class TClProxy : public TObject { -protected: - TXmlRpc *fRpc; //RPC data - -public: - TClProxy(const Char_t *service, TXmlRpc *rpc); - virtual ~TClProxy() { } - - void Print(Option_t *option="") const; - Bool_t RpcFailed(const Char_t *member, const Char_t *what); - - ClassDef(TClProxy,0); // Clarens Proxy base -}; - -#endif diff --git a/proof/clarens/inc/TClSession.h b/proof/clarens/inc/TClSession.h deleted file mode 100644 index 71f36f9527f09..0000000000000 --- a/proof/clarens/inc/TClSession.h +++ /dev/null @@ -1,71 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 25/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_TClSession -#define ROOT_TClSession - -////////////////////////////////////////////////////////////////////////// -// // -// TClSession // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#if !defined(__CINT__) -#include "xmlrpc.h" -#include "xmlrpc_client.h" -#else -struct xmlrpc_server_info; -#endif - -#ifndef ROOT_TObject -#include "TObject.h" -#endif - -#ifndef ROOT_TUrl -#include "TUrl.h" -#endif - - -class TUrl; - - -class TClSession : public TObject { -private: - TUrl fUrl; //server we are connected to - TString fUser; //SHA1 string - TString fPassword; //SHA1 string - xmlrpc_server_info *fServerInfo; //per server data - void *fServerPubRSA; //(X509*) - - // single client certificate for the moment - static void *fgPrivRSA; - static void *fgPubRSA; - static TString fgUserCert; - static Bool_t fgInitialized; - - TClSession(const Char_t *url, const Char_t *user, const Char_t *pw, - xmlrpc_server_info *info, void *serverPubRSA); - - static Bool_t InitAuthentication(); - -public: - virtual ~TClSession() { } - - xmlrpc_server_info *GetServerInfo() {return fServerInfo;} - const Char_t *GetServer() {return fUrl.GetUrl();} - - static TClSession *Create(const Char_t *url); - - ClassDef(TClSession,0); // Clarens Session -}; - -#endif diff --git a/proof/clarens/inc/TClarens.h b/proof/clarens/inc/TClarens.h deleted file mode 100644 index aa03e9d6c1dad..0000000000000 --- a/proof/clarens/inc/TClarens.h +++ /dev/null @@ -1,64 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 21/10/2004 -// Author: Kris Gulbrandsen 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_TClarens -#define ROOT_TClarens - -////////////////////////////////////////////////////////////////////////// -// // -// TClarens // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#ifndef ROOT_TObject -#include "TObject.h" -#endif - - -class TGM; -class TLM; -class TSAM; -class TEcho; -class THashList; -class TClSession; - - -class TClarens : public TObject { -private: - Long_t fTimeout; //timeout on xmlrpc calls - THashList *fSessions; //lsit of clarens sessions by URL - - TClarens(); - - TClSession *Connect(const Char_t *url); - -public: - virtual ~TClarens(); - - void SetTimeout(Long_t msec) {fTimeout = msec;} - Int_t GetTimeout() const {return fTimeout;} - - TEcho *CreateEcho(const Char_t *echoUrl); - TGM *CreateGM(const Char_t *gmUrl); - TLM *CreateLM(const Char_t *lmUrl); - TSAM *CreateSAM(const Char_t *samUrl); - - static void Init(); - - ClassDef(TClarens,0); // Clarens main interface -}; - - -R__EXTERN TClarens *gClarens; - -#endif diff --git a/proof/clarens/inc/TEcho.h b/proof/clarens/inc/TEcho.h deleted file mode 100644 index 47bc56ca64120..0000000000000 --- a/proof/clarens/inc/TEcho.h +++ /dev/null @@ -1,44 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 25/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_TEcho -#define ROOT_TEcho - -////////////////////////////////////////////////////////////////////////// -// // -// TEcho // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#ifndef ROOT_TClProxy -#include "TClProxy.h" -#endif - - -class TString; -class TXmlRpc; - - -class TEcho : public TClProxy { -public: - TEcho(TXmlRpc *rpc); - virtual ~TEcho() { } - - Bool_t Echo(const Char_t *in, TString &out); - Bool_t Hostname(TString &name, TString &ip); - - void Benchmark(Int_t iterations); - - ClassDef(TEcho,0); // Echo proxy -}; - -#endif diff --git a/proof/clarens/inc/TGM.h b/proof/clarens/inc/TGM.h deleted file mode 100644 index 538e34f7e7fbe..0000000000000 --- a/proof/clarens/inc/TGM.h +++ /dev/null @@ -1,68 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 21/10/2004 -// Author: Kris Gulbrandsen 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_TGM -#define ROOT_TGM - -////////////////////////////////////////////////////////////////////////// -// // -// TGM // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#ifndef ROOT_TClProxy -#include "TClProxy.h" -#endif - -#ifndef ROOT_TString -#include "TString.h" -#endif - - -class TList; -class TUrl; -class TXmlRpc; - - -class TGM : public TClProxy { -public: - TGM(TXmlRpc *rpc); - virtual ~TGM() { } - - Bool_t GetVersion(TString &version); - Bool_t CreateSession(const Char_t *dataset, - TString &sessionid, - TList *&list, - TUrl &proofUrl); - Bool_t DestroySession(const Char_t *sessionid); - - struct TFileParams : public TObject { - TString fFileName; - TString fObjClass; - TString fObjName; - TString fDir; - Long64_t fFirst; - Long64_t fNum; - - TFileParams(const Char_t *file, const Char_t *cl, const Char_t *nm, - const Char_t *dir, Int_t first, Int_t num); - - void Print(Option_t *option="") const; - - ClassDef(TGM::TFileParams,0); // PEAC File description - }; - - ClassDef(TGM,0); // PEAC Global Manager proxy -}; - -#endif diff --git a/proof/clarens/inc/TLM.h b/proof/clarens/inc/TLM.h deleted file mode 100644 index f2d281d8c690a..0000000000000 --- a/proof/clarens/inc/TLM.h +++ /dev/null @@ -1,68 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 21/10/2004 -// Author: Kris Gulbrandsen 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_TLM -#define ROOT_TLM - -////////////////////////////////////////////////////////////////////////// -// // -// TLM // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#ifndef ROOT_TObject -#include "TObject.h" -#endif - -#ifndef ROOT_TClProxy -#include "TClProxy.h" -#endif - -#ifndef ROOT_TString -#include "TString.h" -#endif - - -class TList; -class TXmlRpc; - - -class TLM : public TClProxy { -public: - TLM(TXmlRpc *rpc); - virtual ~TLM() { } - - Bool_t GetVersion(TString &version); - Bool_t StartSession(const Char_t *sessionid, TList *&config, Int_t &hbf); - Bool_t DataReady(const Char_t *sessionid, Long64_t &bytesready, - Long64_t &totalbytes); - Bool_t Heartbeat(const Char_t *sessionid); - Bool_t EndSession(const Char_t *sessionid); - - struct TSlaveParams : public TObject { - TString fNode; - Int_t fPerfidx; - TString fImg; - TString fAuth; - TString fAccount; - TString fType; - - void Print(Option_t *option="") const; - - ClassDef(TLM::TSlaveParams, 0); // PEAC Slave config - }; - - ClassDef(TLM,0); // PEAC Local Manager proxy -}; - -#endif diff --git a/proof/clarens/inc/TXmlRpc.h b/proof/clarens/inc/TXmlRpc.h deleted file mode 100644 index 288d83ee75e9c..0000000000000 --- a/proof/clarens/inc/TXmlRpc.h +++ /dev/null @@ -1,64 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 25/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_TXmlRpc -#define ROOT_TXmlRpc - -////////////////////////////////////////////////////////////////////////// -// // -// TXmlRpc // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#if !defined(__CINT__) -#include "xmlrpc.h" -#include "xmlrpc_client.h" -#else -struct xmlrpc_env; -struct xmlrpc_server_info; -struct xmlrpc_value; -#endif - -#ifndef ROOT_TObject -#include "TObject.h" -#endif - -#ifndef ROOT_TClSession -#include "TClSession.h" -#endif - -class TXmlRpc : public TObject { -private: - TClSession *fSession; //Clarens session info - xmlrpc_env *fEnv; //call enviroment - TString fService; //our service - -public: - TXmlRpc(TClSession *session); - virtual ~TXmlRpc(); - - void SetService(const Char_t *svc) {fService = svc;} - const Char_t *GetService() const {return fService;} - - xmlrpc_env *GetEnv() {xmlrpc_env_clean(fEnv); - xmlrpc_env_init(fEnv); - return fEnv;} - xmlrpc_server_info *GetServerInfo() {return fSession->GetServerInfo();} - const Char_t *GetServer() {return fSession->GetServer();} - xmlrpc_value *Call(const Char_t *method, xmlrpc_value *arg); - Bool_t RpcFailed(const Char_t *where, const Char_t *what); - void PrintValue(xmlrpc_value *val); - - ClassDef(TXmlRpc,0); // XMLRPC interface class -}; - -#endif diff --git a/proof/clarens/src/TClProxy.cxx b/proof/clarens/src/TClProxy.cxx deleted file mode 100644 index 995e883509ee4..0000000000000 --- a/proof/clarens/src/TClProxy.cxx +++ /dev/null @@ -1,60 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 26/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TClProxy // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TClProxy.h" - - -#include "xmlrpc.h" -#include "xmlrpc_client.h" - - -#include "Riostream.h" -#include "TClass.h" -#include "TXmlRpc.h" - - -ClassImp(TClProxy) - - -//______________________________________________________________________________ -TClProxy::TClProxy(const Char_t *service, TXmlRpc *rpc) - : fRpc(rpc) -{ - fRpc->SetService(service); -} - -//______________________________________________________________________________ -void TClProxy::Print(Option_t *) const -{ - cout << IsA()->GetName() - << ": service " << fRpc->GetService() << " @ " - << fRpc->GetServer() << endl; -} - - -//______________________________________________________________________________ -Bool_t TClProxy::RpcFailed(const Char_t *member, const Char_t *what) -{ - // Test the environment for an error and report - TString where(this->ClassName()); - where += "::"; - where += member; - - return fRpc->RpcFailed(where, what); - -} diff --git a/proof/clarens/src/TClSession.cxx b/proof/clarens/src/TClSession.cxx deleted file mode 100644 index fc59c1771f982..0000000000000 --- a/proof/clarens/src/TClSession.cxx +++ /dev/null @@ -1,348 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 25/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TClSession // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TClSession.h" - - -#include <openssl/x509.h> -#include <openssl/pem.h> -#include <openssl/bio.h> -#include <openssl/err.h> -#include <openssl/evp.h> -#include <openssl/bn.h> - - -#include "Riostream.h" -#include "TEnv.h" -#include "TError.h" -#include "TList.h" -#include "TRandom.h" -#include "TString.h" -#include "TSystem.h" -#include "TTimeStamp.h" -#include "TUrl.h" - - -ClassImp(TClSession) - - -Bool_t TClSession::fgInitialized = kFALSE; -void *TClSession::fgPrivRSA = 0; -void *TClSession::fgPubRSA = 0; -TString TClSession::fgUserCert; - -//______________________________________________________________________________ -unsigned char *B64Encode(xmlrpc_env *env,unsigned char *instring,int len) -{ - // Utility function that encodes instring in base64, and returns a new - // string with its own memory reference. Free this memory upon - // deconstruction. - - xmlrpc_mem_block *mem; - mem=xmlrpc_base64_encode (env,instring,len); - if (env->fault_occurred) { - cerr<<"XML-RPC Fault: "<<env->fault_string<<"("<< env->fault_code<<")"<<endl; - if (mem) xmlrpc_mem_block_free (mem); - return 0; - } - - if (!mem) return 0; - int olen=xmlrpc_mem_block_size (mem); - - unsigned char *outstring=new unsigned char[olen+1]; - memcpy((void *) outstring,(void *)xmlrpc_mem_block_contents(mem),olen); - outstring[olen]='\0';// Make a proper null-terminated string - - xmlrpc_mem_block_free (mem); - return outstring; -} - -//______________________________________________________________________________ -unsigned char *B64Decode(xmlrpc_env *env, unsigned char *instring,int *len) -{ - // Utility function that encodes instring in base64, and returns a new - // string with its own memory reference. Free this memory upon - // deconstruction. - - xmlrpc_mem_block *mem; - mem=xmlrpc_base64_decode (env,(char *)instring,strlen((const char *)instring)); - if (env->fault_occurred) { - cerr<<"XML-RPC Fault: "<<env->fault_string<<"("<< env->fault_code<<")"<<endl; - if (mem) xmlrpc_mem_block_free (mem); - return 0; - } - - if (!mem) return 0; - int olen=xmlrpc_mem_block_size (mem); - unsigned char *outstring=new unsigned char[olen+1]; - memcpy((void *) outstring,(void *)xmlrpc_mem_block_contents(mem),olen); - outstring[olen]='\0';// Make a proper null-terminated string - *len=olen; - xmlrpc_mem_block_free (mem); - return outstring; -} - -//______________________________________________________________________________ -TClSession::TClSession(const Char_t *url, const Char_t *user, const Char_t *pw, - xmlrpc_server_info *info, void *serverPubRSA) - : fUrl(url), fUser(user), fPassword(pw), fServerInfo(info), fServerPubRSA(serverPubRSA) -{ -} - -//______________________________________________________________________________ -TClSession *TClSession::Create(const Char_t *url) -{ - if (!InitAuthentication()) return 0; - - if (TString(url).EndsWith("/") == kFALSE) { - ::Error("TClSession::Create", "URL must end with \"/\" (%s)", url); - return 0; - } - - // Construct user nonce value - unsigned char nonce[SHA_DIGEST_LENGTH]; - Long_t ns = TTimeStamp().GetNanoSec(); - TRandom rndm(ns); - SHA1((UChar_t*) Form("%x_%lx_%lx", gSystem->GetPid(), ns, (Long_t)rndm.Uniform(1e8)), - 22, nonce); - - xmlrpc_env env; - xmlrpc_env_init(&env); - - TString user = (char *) B64Encode(&env, nonce, SHA_DIGEST_LENGTH); - - xmlrpc_server_info *info = xmlrpc_server_info_new(&env, (char*)url); - if (env.fault_occurred) { - ::Error("TClSession::Create", "creating server info: %s (%d)", - env.fault_string, env.fault_code); - return 0; - } - - xmlrpc_server_info_set_basic_auth (&env, info, (char*)user.Data(), (char*)fgUserCert.Data()); - if (env.fault_occurred) { - ::Error("TClSession::Create", "setting basic auth: %s (%d)", - env.fault_string, env.fault_code); - return 0; - } - - xmlrpc_value *val = xmlrpc_client_call_server (&env, info, "system.auth", "()"); - if (env.fault_occurred) { - ::Error("TClSession::Create", "call system.auth(): %s (%d)", - env.fault_string, env.fault_code); - return 0; - } - - char *cert; - unsigned char *cryptServerNonce64, *cryptUserNonce64; - xmlrpc_parse_value(&env, val, "(sss)", &cert, &cryptServerNonce64, &cryptUserNonce64); - if (env.fault_occurred) { - ::Error("TClSession::Create", "parsing result: %s (%d)", - env.fault_string, env.fault_code); - return 0; - } - - BIO *b = BIO_new_mem_buf(cert,strlen(cert)); - X509 *serverCert = PEM_read_bio_X509(b, 0, 0, 0); - BIO_free(b); - if (serverCert == 0) { - ::Error("TClSession::Create", "reading cert from server response: %s", - ERR_reason_error_string(ERR_get_error())); - return 0; - } - - EVP_PKEY *serverPubKey = X509_get_pubkey(serverCert); - if (serverPubKey == 0) { - ::Error("TClSession::Create", "extracting cert from server response: %s", - ERR_reason_error_string(ERR_get_error())); - return 0; - } - - void* serverPubRSA = EVP_PKEY_get1_RSA(serverPubKey); - if (serverPubRSA == 0) { - ::Error("TClSession::Create", "extracting pub key from cert: %s", - ERR_reason_error_string(ERR_get_error())); - return 0; - } - - // user nonce first - int len; - - unsigned char *cryptNonce = B64Decode(&env, cryptUserNonce64, &len); - unsigned char *serverUstring = new unsigned char[RSA_size((RSA*)serverPubRSA)]; - len = RSA_public_decrypt(len, cryptNonce, serverUstring, - (RSA*) serverPubRSA, RSA_PKCS1_PADDING); - if (len == -1) { - ::Error("TClSession::Create", "recovering digest: %s", - ERR_reason_error_string(ERR_get_error())); - delete [] cryptNonce; - return 0; - } - serverUstring[len] = '\0'; - delete [] cryptNonce; - - // server nonce next - cryptNonce = B64Decode(&env, cryptServerNonce64, &len); - unsigned char *serverNonce = new unsigned char[RSA_size((RSA*)fgPrivRSA)]; - - len = RSA_private_decrypt(len, cryptNonce, serverNonce, - (RSA*) fgPrivRSA, RSA_PKCS1_PADDING); - if (len == -1) { - ::Error("TClSession::Create", "decoding server nonce: %s", - ERR_reason_error_string(ERR_get_error())); - delete [] cryptNonce; - return 0; - } - serverNonce[len] = '\0'; - delete [] cryptNonce; - xmlrpc_DECREF (val); - - // calculate hash of server nonce - - SHA1(serverNonce, len, nonce); - TString password = (char *) B64Encode(&env, nonce, SHA_DIGEST_LENGTH); - - xmlrpc_server_info_set_basic_auth (&env, info, (char*)user.Data(), (char*)password.Data()); - - return new TClSession(url, user, password, info, serverPubRSA); -} - -//______________________________________________________________________________ -Bool_t TClSession::InitAuthentication() -{ - if (fgInitialized) return kTRUE; - - // Initialize SSL - OpenSSL_add_all_algorithms(); - OpenSSL_add_all_ciphers(); - OpenSSL_add_all_digests(); - ERR_load_crypto_strings(); - - // Load user certificate and public key - - - BIO *bio = 0; - TString certFile(gEnv->GetValue("Clarens.CertFile", "")); - if (certFile.Length() > 0) { - bio = BIO_new_file(certFile,"r"); - } else { - certFile = Form("/tmp/x509up_u%d", gSystem->GetUid()); - if (gSystem->AccessPathName(certFile) == kFALSE) { - // yes, file exists - bio = BIO_new_file(certFile,"r"); - } else { - certFile = gSystem->HomeDirectory(); - certFile += "/.globus/usercert.pem"; - bio = BIO_new_file(certFile,"r"); - } - } - - if (bio == 0) { - ::Error("TClSession::InitAuthentication", "cannot open '%s' (%s)", - certFile.Data(), gSystem->GetError()); - return kFALSE; - } - - if (gDebug > 0) ::Info("TClSession::InitAuthentication", - "using public key: '%s'", certFile.Data()); - - X509* userCert = PEM_read_bio_X509(bio, 0,0,0); - if (!userCert) { - ::Error("TClSession::InitAuthentication", "reading user public key: %s (%ld)", - ERR_reason_error_string(ERR_get_error()), ERR_get_error()); - BIO_free(bio); - return kFALSE; - } - - BIO_free(bio); - - TString line; - Bool_t incert=kFALSE; - fgUserCert = ""; - ifstream fin(certFile); - while (!fin.eof()) { - line.ReadToDelim(fin,'\n'); - - if (line.Contains("-----BEGIN CERTIFICATE-----") || - line.Contains("-----BEGIN X509 CERTIFICATE-----")) incert=kTRUE; - - if (incert) fgUserCert += line + "\n"; - - if (line.Contains("-----END CERTIFICATE-----") || - line.Contains("-----END X509 CERTIFICATE-----")) incert=kFALSE; - } - fin.close(); - - EVP_PKEY *userPubKey = X509_get_pubkey(userCert); - if (userPubKey == 0) { - ::Error("TClSession::InitAuthentication", "extracting user public key: %s (%ld)", - ERR_reason_error_string(ERR_get_error()), ERR_get_error()); - X509_free(userCert); - return kFALSE; - } - - X509_free(userCert); - fgPubRSA = EVP_PKEY_get1_RSA(userPubKey); - if (fgPubRSA == 0) { - ::Error("TClSession::InitAuthentication", "extracting RSA structure from user public key: %s (%ld)", - ERR_reason_error_string(ERR_get_error()), ERR_get_error()); - EVP_PKEY_free(userPubKey); - return kFALSE; - } - - EVP_PKEY_free(userPubKey); - - // Load private key - - TString privfile(gEnv->GetValue("Clarens.KeyFile", "")); - if (privfile.Length() > 0) { - bio = BIO_new_file(privfile,"r"); - } else { - privfile = Form("/tmp/x509up_u%d", gSystem->GetUid()); - if (gSystem->AccessPathName(privfile) == kFALSE) { - // yes, file exists - bio = BIO_new_file(privfile,"r"); - } else { - privfile = gSystem->HomeDirectory(); - privfile += "/.globus/userkey.pem"; - bio = BIO_new_file(privfile,"r"); - } - } - - if (bio == 0) { - ::Error("TClSession::InitAuthentication", "cannot open '%s' (%s)", - privfile.Data(), gSystem->GetError()); - RSA_free((RSA*)fgPubRSA); fgPubRSA = 0; - return kFALSE; - } - - if (gDebug > 0) ::Info("TClSession::InitAuthentication", - "using private key: '%s'", privfile.Data()); - - fgPrivRSA = PEM_read_bio_RSAPrivateKey(bio, 0, 0, 0); - BIO_free(bio); - - if (fgPrivRSA == 0) { - ::Error("TClSession::InitAuthentication", "extracting RSA structure from user private key: %s (%ld)", - ERR_reason_error_string(ERR_get_error()), ERR_get_error()); - RSA_free((RSA*)fgPubRSA); fgPubRSA = 0; - return kFALSE; - } - - fgInitialized = kTRUE; - return kTRUE; -} diff --git a/proof/clarens/src/TClarens.cxx b/proof/clarens/src/TClarens.cxx deleted file mode 100644 index a88c4128f80fc..0000000000000 --- a/proof/clarens/src/TClarens.cxx +++ /dev/null @@ -1,129 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TClarens // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TClarens.h" - - -#include "TClSession.h" -#include "TEcho.h" -#include "TGM.h" -#include "THashList.h" -#include "TLM.h" -#include "TSAM.h" -#include "TXmlRpc.h" - - -namespace { - -//------------------------------------------------------------------------------ - -struct TClarensStartup { - TClarensStartup() {TClarens::Init();} -} Clarenstartup; - -}; - - -//------------------------------------------------------------------------------ - -TClarens *gClarens = 0; - -ClassImp(TClarens) - - -//______________________________________________________________________________ -TClarens::TClarens() - : fTimeout(10000), fSessions(new THashList) -{ - xmlrpc_client_init(XMLRPC_CLIENT_NO_FLAGS, "ROOT Clarens client", "1.0"); -} - - -//______________________________________________________________________________ -TClarens::~TClarens() -{ - delete fSessions; - xmlrpc_client_cleanup(); -} - - -//______________________________________________________________________________ -TClSession *TClarens::Connect(const Char_t * url) -{ - TClSession *session = (TClSession*) fSessions->FindObject(url); - - if (session == 0) { - session = TClSession::Create(url); - if (session != 0) fSessions->Add(session); - } - - return session; -} - - -//______________________________________________________________________________ -TEcho *TClarens::CreateEcho(const Char_t * echoUrl) -{ - TClSession *session = Connect(echoUrl); - - if (session == 0) return 0; - - return new TEcho(new TXmlRpc(session)); -} - - -//______________________________________________________________________________ -TGM *TClarens::CreateGM(const Char_t * gmUrl) -{ - TClSession *session = Connect(gmUrl); - - if (session == 0) return 0; - - return new TGM(new TXmlRpc(session)); -} - - -//______________________________________________________________________________ -TLM *TClarens::CreateLM(const Char_t * lmUrl) -{ - TClSession *session = Connect(lmUrl); - - if (session == 0) return 0; - - return new TLM(new TXmlRpc(session)); -} - - -//______________________________________________________________________________ -TSAM *TClarens::CreateSAM(const Char_t * samUrl) -{ - TClSession *session = Connect(samUrl); - - if (session == 0) return 0; - - return new TSAM(new TXmlRpc(session)); -} - - -//______________________________________________________________________________ -void TClarens::Init() -{ - if (gClarens == 0) { - gClarens = new TClarens; - } -} diff --git a/proof/clarens/src/TEcho.cxx b/proof/clarens/src/TEcho.cxx deleted file mode 100644 index 647aa9bc81f8f..0000000000000 --- a/proof/clarens/src/TEcho.cxx +++ /dev/null @@ -1,108 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 25/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TEcho // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TEcho.h" - - -#include "xmlrpc.h" -#include "xmlrpc_client.h" - - -#include "TString.h" -#include "TXmlRpc.h" -#include "TStopwatch.h" -#include "Riostream.h" - - -ClassImp(TEcho) - - -//______________________________________________________________________________ -TEcho::TEcho(TXmlRpc *rpc) - : TClProxy("echo", rpc) -{ -} - - -//______________________________________________________________________________ -Bool_t TEcho::Echo(const Char_t *in, TString &out) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *arg = xmlrpc_build_value(env, "(s)", in); - if (RpcFailed("Echo", "encode argument")) return kFALSE; - - xmlrpc_value *retval = fRpc->Call("echo", arg); - if (RpcFailed("Echo", "call")) return kFALSE; - - if (gDebug>1) fRpc->PrintValue(retval); - - char *o; - xmlrpc_parse_value(env, retval, "(s)", &o); - if (RpcFailed("Echo", "decode")) return kFALSE; - - out = o; - - xmlrpc_DECREF (arg); - xmlrpc_DECREF (retval); - - return kTRUE; -} - - -//______________________________________________________________________________ -Bool_t TEcho::Hostname(TString &name, TString &ip) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *retval = fRpc->Call("hostname", 0); - if (RpcFailed("Hostname", "call")) return kFALSE; - - if (gDebug>1) fRpc->PrintValue(retval); - - char *n, *i; - xmlrpc_parse_value(env, retval, "(ss)", &n, &i); - if (RpcFailed("Hostname", "decode")) return kFALSE; - - name = n; - ip = i; - - xmlrpc_DECREF (retval); - - return kTRUE; -} - - -//______________________________________________________________________________ -void TEcho::Benchmark(Int_t iterations) -{ - TStopwatch timer; - TString out; - - for(Int_t i = 0; i < iterations ; i++) { - Echo("Dummy test string", out); - } - - timer.Stop(); - - cout << - "Elapsed time is " << timer.RealTime() << " s, " << - iterations / timer.RealTime() << " calls/s for " << - iterations << " calls" << endl; -} - diff --git a/proof/clarens/src/TGM.cxx b/proof/clarens/src/TGM.cxx deleted file mode 100644 index e5ca1f8d14b88..0000000000000 --- a/proof/clarens/src/TGM.cxx +++ /dev/null @@ -1,192 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TGM // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TGM.h" - - -#include "memory" -#include "xmlrpc.h" -#include "xmlrpc_client.h" - - -#include "Riostream.h" -#include "TClass.h" -#include "TList.h" -#include "TObjString.h" -#include "TUrl.h" -#include "TXmlRpc.h" - - -ClassImp(TGM) -ClassImp(TGM::TFileParams) - - -//______________________________________________________________________________ -TGM::TGM(TXmlRpc *rpc) - : TClProxy("GM", rpc) -{ -} - - -//______________________________________________________________________________ -Bool_t TGM::GetVersion(TString &version) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *retval = fRpc->Call("version", 0); - if (RpcFailed("GetVersion", "call")) return kFALSE; - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("GetVersion", "decode")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("GetVersion", "decode errmsg")) return kFALSE; - - Error("GetVersion", "%s", errmsg); - return kFALSE; - } - - char *v; - xmlrpc_parse_value(env, val, "s", &v); - if (RpcFailed("GetVersion", "decode version")) return kFALSE; - - version = v; - - xmlrpc_DECREF (retval); - return kTRUE; -} - - -//______________________________________________________________________________ -Bool_t TGM::CreateSession(const Char_t *dataset, - TString &sessionid, - TList *&files, - TUrl &proofUrl) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *arg = xmlrpc_build_value(env, "(s)", dataset); - if (RpcFailed("CreateSession", "encode argument")) return kFALSE; - - xmlrpc_value *retval = fRpc->Call("create_session",arg); - if (RpcFailed("CreateSession", "call")) return kFALSE; - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("CreateSession", "decode")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("CreateSession", "decode errmsg")) return kFALSE; - - Error("CreateSession", "%s", errmsg); - return kFALSE; - } - - char *id, *url; - xmlrpc_value *filearray; - xmlrpc_parse_value(env, val, "(ssA)",&id, &url, &filearray); - if (RpcFailed("CreateSession", "decode results")) return kFALSE; - - sessionid = id; - proofUrl = url; - - int n = xmlrpc_array_size (env, filearray); - if (RpcFailed("CreateSession", "array size")) return kFALSE; - - std::auto_ptr<TList> ftemp(new TList); - ftemp->SetOwner(); - for(int i=0; i < n; i++) { - xmlrpc_value *entry = xmlrpc_array_get_item(env, filearray, i); - if (RpcFailed("CreateSession", "get entry")) return kFALSE; - - char *dummy, *file, *cls, *name, *dir; - Int_t size, first, n; - xmlrpc_parse_value(env, entry, "((ss)(si)(ss)(ss)(si)(si)(ss))", - &dummy, &file, &dummy, &size, &dummy, &cls, &dummy, &name, - &dummy, &first, &dummy, &n, &dummy, &dir); - if (RpcFailed("CreateSession", "decode entry")) return kFALSE; - - ftemp->Add(new TFileParams(file, cls, name, dir, first, n)); - } - - files = ftemp.release(); - xmlrpc_DECREF (arg); - xmlrpc_DECREF (retval); - - return kTRUE; -} - -//______________________________________________________________________________ -Bool_t TGM::DestroySession(const Char_t *sessionid) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *arg = xmlrpc_build_value(env, "(s)", sessionid); - if (RpcFailed("DestroySession", "encode argument")) return kFALSE; - - xmlrpc_value *retval = fRpc->Call("destroy_job", arg); - if (RpcFailed("DestroySession", "call")) return kFALSE; - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("DestroySession", "decode reply")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("DestroySession", "decode errmsg")) return kFALSE; - - Error("DestroySession", "%s", errmsg); - return kFALSE; - } - - xmlrpc_DECREF (arg); - xmlrpc_DECREF (retval); - - return kTRUE; -} - - -//______________________________________________________________________________ -TGM::TFileParams::TFileParams(const Char_t *file, const Char_t *cl, const Char_t *name, - const Char_t *dir, Int_t first, Int_t n) - : fFileName(file), fObjClass(cl), fObjName(name), fDir(dir), fFirst(first), fNum(n) -{ -} - - -//______________________________________________________________________________ -void TGM::TFileParams::Print(Option_t *) const -{ - cout << IsA()->GetName() - << ": '" << fFileName << "'" - << " " << fObjClass - << " " << fObjName - << " (" << fDir - << ") [" << fFirst << ", " << fNum << "]" - << endl; -} - diff --git a/proof/clarens/src/TLM.cxx b/proof/clarens/src/TLM.cxx deleted file mode 100644 index 6dc37bb2487bd..0000000000000 --- a/proof/clarens/src/TLM.cxx +++ /dev/null @@ -1,257 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TLM // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TLM.h" - -#include "memory" -#include <stdlib.h> -#include "xmlrpc.h" -#include "xmlrpc_client.h" - - -#include "Riostream.h" -#include "TClass.h" -#include "TList.h" -#include "TString.h" -#include "TXmlRpc.h" - - -ClassImp(TLM) -ClassImp(TLM::TSlaveParams) - - -//______________________________________________________________________________ -TLM::TLM(TXmlRpc *rpc) - : TClProxy("LM", rpc) -{ -} - - -//______________________________________________________________________________ -Bool_t TLM::GetVersion(TString &version) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *retval = fRpc->Call("version", 0); - if (RpcFailed("GetVersion", "call")) return kFALSE; - - if (gDebug>0) fRpc->PrintValue(retval); - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("GetVersion", "decode")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("GetVersion", "decode errmsg")) return kFALSE; - - Error("GetVersion", "%s", errmsg); - return kFALSE; - } - - char *v; - xmlrpc_parse_value(env, val, "s", &v); - if (RpcFailed("GetVersion", "decode version")) return kFALSE; - - version = v; - - xmlrpc_DECREF (retval); - return kTRUE; -} - - -//______________________________________________________________________________ -Bool_t TLM::StartSession(const Char_t *sessionid, TList *&config, Int_t &hbf) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *arg = xmlrpc_build_value(env, "(s)", sessionid); - if (RpcFailed("StartSession", "encode argument")) return kFALSE; - - xmlrpc_value *retval = fRpc->Call("get_config", arg); - if (RpcFailed("StartSession", "call")) return kFALSE; - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("StartSession", "decode reply")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("StartSession", "decode errmsg")) return kFALSE; - - Error("StartSession", "%s", errmsg); - return kFALSE; - } - - char *hbfs; - xmlrpc_value *nodearray; - xmlrpc_parse_value(env, val, "(sA)", &hbfs, &nodearray); - if (RpcFailed("StartSession", "decode results")) return kFALSE; - - hbf = atol(hbfs); - int n = xmlrpc_array_size (env, nodearray); - if (RpcFailed("StartSession", "array size")) return kFALSE; - - std::auto_ptr<TList> ntemp(new TList); - ntemp->SetOwner(); - // skip entry zero with the labels - for(int i=1; i < n; i++) { - xmlrpc_value *entry = xmlrpc_array_get_item(env, nodearray, i); - if (RpcFailed("StartSession", "get entry")) return kFALSE; - -//fields=['name','cpu_speed_Ghz','specint','image','start_mechanism', -// 'authentication_type','maximum_slaves'] - - char *name, *img, *startup, *auth, *max; - double mhz; - int specint; - xmlrpc_parse_value(env, entry, "(sdisssi)", &name, &mhz, &specint, - &img, &startup, &auth, &max); - if (RpcFailed("StartSession", "decode entry")) return kFALSE; - - TSlaveParams *sl = new TSlaveParams; - - sl->fNode = name; - sl->fPerfidx = specint; - sl->fImg = img; - sl->fAuth = auth; - sl->fAccount = "nobody"; - sl->fType = startup; - - ntemp->Add(sl); - } - - config = ntemp.release(); - xmlrpc_DECREF (arg); - xmlrpc_DECREF (retval); - - return kTRUE; -} - - -//______________________________________________________________________________ -Bool_t TLM::Heartbeat(const Char_t *sessionid) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *arg = xmlrpc_build_value(env, "(s)", sessionid); - if (RpcFailed("Heartbeat", "encode argument")) return kFALSE; - - xmlrpc_value *retval = fRpc->Call("alive", arg); - if (RpcFailed("Heartbeat", "call")) return kFALSE; - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("Heartbeat", "decode reply")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("Heartbeat", "decode errmsg")) return kFALSE; - - Error("Heartbeat", "%s", errmsg); - return kFALSE; - } - - return kTRUE; -} - - -//______________________________________________________________________________ -Bool_t TLM::DataReady(const Char_t *sessionid, Long64_t & bytesready, - Long64_t & bytestotal) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *arg = xmlrpc_build_value(env, "(s)", sessionid); - if (RpcFailed("DataReady", "encode argument")) return kFALSE; - - xmlrpc_value *retval = fRpc->Call("data_ready", arg); - if (RpcFailed("DataReady", "call")) return kFALSE; - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("DataReady", "decode reply")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("DataReady", "decode errmsg")) return kFALSE; - - Error("DataReady", "%s", errmsg); - return kFALSE; - } - - Int_t isReady; - Double_t ready, total; - xmlrpc_parse_value(env, val, "(bdd)", &isReady, &ready, &total); - if (RpcFailed("DataReady", "decode results")) return kFALSE; - - bytesready = (Long64_t) ready; - bytestotal = (Long64_t) total; - return isReady; -} - - -//______________________________________________________________________________ -Bool_t TLM::EndSession(const Char_t *sessionid) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *arg = xmlrpc_build_value(env, "(s)", sessionid); - if (RpcFailed("EndSession", "encode argument")) return kFALSE; - - xmlrpc_value *retval = fRpc->Call("destroy_job", arg); - if (RpcFailed("EndSession", "call")) return kFALSE; - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("EndSession", "decode reply")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("EndSession", "decode errmsg")) return kFALSE; - - Error("EndSession", "%s", errmsg); - return kFALSE; - } - return kTRUE; -} - - - -//______________________________________________________________________________ -void TLM::TSlaveParams::Print(Option_t * /*option*/) const -{ - cout << IsA()->GetName() - << ": " << fNode - << ", " << fPerfidx - << ", " << fImg - << ", " << fAuth - << ", " << fAccount - << ", " << fType - << endl; -} diff --git a/proof/clarens/src/TSAM.cxx b/proof/clarens/src/TSAM.cxx deleted file mode 100644 index 58acdfaf9831a..0000000000000 --- a/proof/clarens/src/TSAM.cxx +++ /dev/null @@ -1,260 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TSAM // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TSAM.h" - -#include "memory" -#include <stdlib.h> -#include "xmlrpc.h" -#include "xmlrpc_client.h" - - -#include "TString.h" -#include "TObjString.h" -#include "TList.h" -#include "TXmlRpc.h" -#include "TGM.h" - - -ClassImp(TSAM) - - -//______________________________________________________________________________ -TSAM::TSAM(TXmlRpc *rpc) - : TClProxy("SAM", rpc) -{ -} - - -//______________________________________________________________________________ -Bool_t TSAM::GetVersion(TString &version) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *retval = fRpc->Call("version", 0); - if (RpcFailed("GetVersion", "call")) return kFALSE; - - if (gDebug>0) fRpc->PrintValue(retval); - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("GetVersion", "decode")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("GetVersion", "decode errmsg")) return kFALSE; - - Error("GetVersion", "%s", errmsg); - return kFALSE; - } - - char *v; - xmlrpc_parse_value(env, val, "s", &v); - if (RpcFailed("GetVersion", "decode version")) return kFALSE; - - version = v; - - xmlrpc_DECREF (retval); - return kTRUE; -} - - -//______________________________________________________________________________ -Bool_t TSAM::GetDatasets(TList *&datasets) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *retval = fRpc->Call("list_datasets", 0); - if (RpcFailed("GetDatasets", "call")) return kFALSE; - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("GetDatasets", "decode reply")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("GetDatasets", "decode errmsg")) return kFALSE; - - Error("GetDatasets", "%s", errmsg); - return kFALSE; - } - - int n = xmlrpc_array_size (env, val); - if (RpcFailed("GetDatasets", "array size")) return kFALSE; - - std::auto_ptr<TList> temp(new TList); - temp->SetOwner(); - for(int i=0; i < n; i++) { - xmlrpc_value *entry = xmlrpc_array_get_item(env, val, i); - if (RpcFailed("GetDatasets", "get entry")) return kFALSE; - - char *ds; - xmlrpc_parse_value(env, entry, "s", &ds); - if (RpcFailed("GetDatasets", "decode entry")) return kFALSE; - - temp->Add(new TObjString(ds)); - } - - xmlrpc_DECREF (retval); - - datasets = temp.release(); - return kTRUE; -} - - -//______________________________________________________________________________ -Bool_t TSAM::GetDSetLocations(const Char_t *dataset, TList *&lmUrls) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *arg = xmlrpc_build_value(env, "(s)", dataset); - if (RpcFailed("GetDSetLocations", "encode argument")) return kFALSE; - - xmlrpc_value *retval = fRpc->Call("dataset_locations", arg); - if (RpcFailed("GetDSetLocations", "call")) return kFALSE; - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("GetDSetLocations", "decode reply")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("GetDSetLocations", "decode errmsg")) return kFALSE; - - Error("GetDSetLocations", "%s", errmsg); - return kFALSE; - } - - int n = xmlrpc_array_size (env, val); - if (RpcFailed("GetDSetLocations", "array size")) return kFALSE; - - std::auto_ptr<TList> temp(new TList); - temp->SetOwner(); - for(int i=0; i < n; i++) { - xmlrpc_value *entry = xmlrpc_array_get_item(env, val, i); - if (RpcFailed("GetDSetLocations", "get entry")) return kFALSE; - - char *ds; - xmlrpc_parse_value(env, entry, "s", &ds); - if (RpcFailed("GetDSetLocations", "decode entry")) return kFALSE; - - temp->Add(new TObjString(ds)); - } - - xmlrpc_DECREF (arg); - xmlrpc_DECREF (retval); - - lmUrls = temp.release(); - return kTRUE; -} - - -//______________________________________________________________________________ -Bool_t TSAM::GetDSetFiles(const Char_t *dataset, const Char_t *lmUrl, TList *&files) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *arg = xmlrpc_build_value(env, "(ss)", dataset, lmUrl); - if (RpcFailed("GetDSetFiles", "encode argument")) return kFALSE; - - xmlrpc_value *retval = fRpc->Call("dataset_files", arg); - if (RpcFailed("GetDSetFiles", "call")) return kFALSE; - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("GetDSetFiles", "decode reply")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("GetDSetetFiles", "decode errmsg")) return kFALSE; - - Error("GetDSetFiles", "%s", errmsg); - return kFALSE; - } - - int n = xmlrpc_array_size (env, val); - if (RpcFailed("GetDSetFiles", "array size")) return kFALSE; - - std::auto_ptr<TList> temp(new TList); - temp->SetOwner(); - for(int i=0; i < n; i++) { - xmlrpc_value *entry = xmlrpc_array_get_item(env, val, i); - if (RpcFailed("GetDSetFiles", "get entry")) return kFALSE; - - char *dummy, *file, *cls, *name, *dir; - Int_t size, first, n; - xmlrpc_parse_value(env, entry, "((ss)(si)(ss)(ss)(si)(si)(ss))", - &dummy, &file, &dummy, &size, &dummy, &cls, &dummy, &name, - &dummy, &first, &dummy, &n, &dummy, &dir); - if (RpcFailed("GetDSetFiles", "decode entry")) return kFALSE; - - temp->Add(new TGM::TFileParams(file, cls, name, dir, first, n)); - } - - xmlrpc_DECREF (arg); - xmlrpc_DECREF (retval); - - files = temp.release(); - return kTRUE; -} - - -//______________________________________________________________________________ -Bool_t TSAM::GetDSetSize(const Char_t *dataset, Long64_t &size) -{ - xmlrpc_env *env = fRpc->GetEnv(); - - xmlrpc_value *arg = xmlrpc_build_value(env, "(s)", dataset); - if (RpcFailed("GetDSetSize", "encode argument")) return kFALSE; - - xmlrpc_value *retval = fRpc->Call("dataset_size", arg); - if (RpcFailed("GetDSetSize", "call")) return kFALSE; - - char *rc; - xmlrpc_value *val; - xmlrpc_parse_value(env, retval, "(sV)", &rc, &val); - if (RpcFailed("GetDSetSize", "decode reply")) return kFALSE; - - if (strcmp(rc, "SUCCESS") != 0) { - char *errmsg; - xmlrpc_parse_value(env, val, "s", &errmsg); - if (RpcFailed("GetDSetSize", "decode errmsg")) return kFALSE; - - Error("GetDSetSize", "%s", errmsg); - return kFALSE; - } - - double d; - xmlrpc_parse_value(env, val, "d", &d); - if (RpcFailed("GetDSetSize", "decode version")) return kFALSE; - - xmlrpc_DECREF (arg); - xmlrpc_DECREF (retval); - - size = static_cast<Long64_t>(d); - - return kTRUE; -} diff --git a/proof/clarens/src/TXmlRpc.cxx b/proof/clarens/src/TXmlRpc.cxx deleted file mode 100644 index 47ac4971f4afb..0000000000000 --- a/proof/clarens/src/TXmlRpc.cxx +++ /dev/null @@ -1,260 +0,0 @@ -// @(#)root/clarens:$Id$ -// Author: Maarten Ballintijn 25/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TXmlRpc // -// // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TXmlRpc.h" - - -#include "TClSession.h" -#include "TError.h" - - - - -namespace { - -void print_values(int level, xmlrpc_env *env, xmlrpc_value *in); - -Bool_t report_error(xmlrpc_env *env, const char *what) -{ - if (env->fault_occurred) { - printf("Error decoding %s: %s (%d)", what, env->fault_string, - env->fault_code); - } - return env->fault_occurred; -} - - -int get_int(xmlrpc_env *env, xmlrpc_value *in) -{ - int i = 0; - xmlrpc_parse_value(env, in, "i", &i); - report_error(env,"int"); - return(i); -} - - -int get_boolean(xmlrpc_env *env, xmlrpc_value *in) -{ - int i = 0; - xmlrpc_parse_value(env, in, "b", &i); - report_error(env,"bool"); - return(i); -} - - -double get_double(xmlrpc_env *env, xmlrpc_value *in) -{ - double d = 0; - xmlrpc_parse_value(env, in, "d", &d); - report_error(env,"double"); - return(d); -} - - -char* get_timestamp(xmlrpc_env *env, xmlrpc_value *in) -{ - char *s = 0; - - xmlrpc_parse_value(env, in, "8", &s); - report_error(env,"timestamp"); - return(s); -} - - -char* get_string(xmlrpc_env *env, xmlrpc_value *in){ - char* s = 0; - - xmlrpc_parse_value(env, in, "s", &s); - report_error(env,"string"); - return(s); -} - - -char* get_base64(xmlrpc_env *env, xmlrpc_value *in) -{ - char *s = 0; - - xmlrpc_parse_value(env, in, "6", &s); - report_error(env,"base64"); - return(s); -} - - -void get_struct(int level, xmlrpc_env *env, xmlrpc_value *in){ - int i, size = 0; - xmlrpc_value *key, *value; - TString space(' ', level * 3); - - size = xmlrpc_struct_size(env, in); - if (report_error(env,"struct")) return; - - for(i=0; i < size; i++){ - xmlrpc_struct_get_key_and_value(env, in, i, &key, &value); - if (report_error(env,"struct member")) return; - - char *keystr = get_string(env, key); - if (env->fault_occurred) return; - - printf("%s%s:\n", space.Data(), keystr); - print_values(level+1, env, value); - if (env->fault_occurred) return; - } -} - - -void get_array(int level, xmlrpc_env *env, xmlrpc_value *in) -{ - int i, size = 0; - xmlrpc_value *el; - - size = xmlrpc_array_size(env, in); - if (report_error(env,"array")) return; - - for(i=0; i < size; i++){ - el = xmlrpc_array_get_item( env, in, i); - if (report_error(env,"array element")) return; - - print_values(level, env, el); - if (env->fault_occurred) return; - } -} - - -void print_values(int level, xmlrpc_env *env, xmlrpc_value *in) -{ - TString space(' ', level * 3); - - printf("%s", space.Data()); - - /* What did we get back? */ - switch (xmlrpc_value_type(in)) { - case (XMLRPC_TYPE_INT): - printf("int %d\n", get_int(env, in)); - break; - case (XMLRPC_TYPE_BOOL): - printf("bool %s\n", get_boolean(env, in) ? "true" : "false" ); - break; - case (XMLRPC_TYPE_DOUBLE): - printf("double %g\n", get_double(env, in)); - break; - case (XMLRPC_TYPE_DATETIME): - printf("timestamp %s\n", - get_timestamp(env, in)); - break; - case (XMLRPC_TYPE_STRING): - printf("string '%s'\n", get_string(env, in)); - break; - case (XMLRPC_TYPE_BASE64): - printf("base64 %s\n", - get_base64(env, in)); - break; - case (XMLRPC_TYPE_ARRAY): - printf("(\n"); - get_array(level+1, env, in); - printf("%s)\n", space.Data()); - break; - case (XMLRPC_TYPE_STRUCT): - printf("{\n"); - get_struct(level+1, env, in); - printf("%s}\n", space.Data()); - break; - case (XMLRPC_TYPE_C_PTR): - printf("Got a C pointer?!\n"); - break; - case (XMLRPC_TYPE_DEAD): - printf("Got a 0xDEADr?!\n"); - break; - default: - printf("UNKNOWN XML-RPC DATATYPE\n"); - } -} - - -}; - - -ClassImp(TXmlRpc) - -//______________________________________________________________________________ -TXmlRpc::TXmlRpc(TClSession *session) - : fSession(session) -{ - fEnv = new xmlrpc_env; - xmlrpc_env_init(fEnv); -} - - -//______________________________________________________________________________ -TXmlRpc::~TXmlRpc() -{ - delete fEnv; -} - - -//______________________________________________________________________________ -xmlrpc_value *TXmlRpc::Call(const Char_t *method, xmlrpc_value *arg) -{ - // Make an XMLRPC call - - TString m = fService + "." + method; - - xmlrpc_value *retval = xmlrpc_client_call_server( fEnv, - fSession->GetServerInfo(), (char *) m.Data(), - (char *) (arg == 0 ? "()" : "V"), arg); - - if (gDebug > 1) { - if (retval != 0) { - Info("Call", "%s: returns:", m.Data()); - PrintValue(retval); - } else { - Info("Call", "%s: no return value", m.Data()); - } - } - - return retval; -} - - -//______________________________________________________________________________ -Bool_t TXmlRpc::RpcFailed(const Char_t *where, const Char_t *what) -{ - // Test the environment for an error and report - - if (fEnv->fault_occurred) { - ::Error(where, "%s: %s (%d)", what, - fEnv->fault_string, fEnv->fault_code); - return kTRUE; - } - - return kFALSE; -} - - -//______________________________________________________________________________ -void TXmlRpc::PrintValue(xmlrpc_value *val) -{ - // Pretty print a, possibly complex, xmlrpc value - - xmlrpc_env *env = new xmlrpc_env; xmlrpc_env_init(env); - - print_values(0, env, val); - - xmlrpc_env_clean(env); -} - - diff --git a/proof/doc/confman/ConfigProofPoD.md b/proof/doc/confman/ConfigProofPoD.md new file mode 100644 index 0000000000000..14301009be4de --- /dev/null +++ b/proof/doc/confman/ConfigProofPoD.md @@ -0,0 +1,194 @@ +Setup a static PROOF cluster with PROOF on Demand +================================================= + +Introduction +------------ + +Using PROOF on Demand is our current recommended way of running a PROOF +cluster. The usage of PoD is in particular helpful for the following +reasons: + +- **Sandboxing.** Each user get their own personal PROOF cluster, + separated from the others: a problem occurring on one personal + cluster does not affect the workflow of other users. + +- **Easier administration and self-servicing.** A user can restart their + personal PROOF cluster in case of troubles without waiting for a + system administrator's intervention. + +- **Efficient multiuser scheduling.** PROOF on Demand makes PROOF run on + top of an existing resource management system, moving the problem of + scheduling many concurrent users outside of PROOF. + +This guide particularly refers to the setup of a static PROOF cluster +running on physical hosts: the recommended setup is in practice the same +as the ready-to-go Virtual Analysis Facility. If you want to use PROOF +on the clouds there is no configuration to go through. + +Setup a resource management system +---------------------------------- + +Although PROOF on Demand can run on a cluster of nodes without using a +resource management system (using `pod-ssh`), it is recommended to setup a +dedicated one to benefit from the scheduling in a multiuser environment, or a +dedicated queue on an existing one. + +As there's a variety of resource management systems, this guide does not cover +their setup. The RMS preconfigured for the Virtual Analysis Facility is +[HTCondor](http://research.cs.wisc.edu/htcondor/), which we recommend primarily +because it has dynamic addition of workers built in. + +Configuration steps for all nodes +--------------------------------- + +### Setup CernVM-FS + +[CernVM-FS](http://cernvm.cern.ch/portal/filesystem) should be installed +on all machines as the preferred method for software distribution. + +> Configuration instructions for the latest CernVM-FS can be found +> [here](http://cernvm.cern.ch/portal/filesystem/techinformation). + +A brief step-by-step procedure to install CernVM-FS is hereby described. + +- Download and install the latest stable version from + [here](http://cernvm.cern.ch/portal/filesystem): pick one which is + appropriate to your operating system. You need the `cvmfs` package, + you *don't* need the `cvmfs-devel` or `cvmfs-server` ones. + +- As root user, run: + + # cvmfs_config setup + +- Start the `autofs` service: how to to this depends on your operating + system. + + On Ubuntu using Upstart: + + # restart autofs + + On RHEL-based or older Ubuntus: + + # service autofs restart + +- Prepare a `/etc/cvmfs/default.local` file (create it if it does not + exists) with the following configuration bits: + + ``` {.bash} + CVMFS_HTTP_PROXY=http://your-proxy-server.domain.ch:3128,DIRECT + CVMFS_REPOSITORIES=your-experiment.cern.ch,sft.cern.ch + CVMFS_QUOTA_LIMIT=50000 + ``` + + You need to properly specify your closest HTTP caching proxy: + separate many of them via commas. The last fallback value, `DIRECT`, + tells cvmfs to connect directly without using any proxy at all. + + Among the list of repositories (comma-separated), always specify + `sft.cern.ch` and the one containing the software to your experiment + (e.g., `cms.cern.ch`). + + The quota limit is, in Megabytes, the amount of local disk space to + use as cache. + +- Check the configuration and repositories with: + + # cvmfs_config chksetup + OK + # cvmfs_config probe + Probing /cvmfs/cms.cern.ch... OK + Probing /cvmfs/sft.cern.ch... OK + +> You might need special configurations for some custom software +> repositories! Special cases are not covered in this guide. + +### Firewall configuration + +[PROOF on Demand](http://pod.gsi.de/) is very flexible in handling +various cases of network topologies. The best solution would be to allow +all TCP communications between the cluster machines. + +No other incoming communication is required from the outside. + +Configuration steps for the head node only +------------------------------------------ + +### Setup HTTPS+SSH (sshcertauth) authentication + +> Latest recommended sshcertauth version is 0.8.5. +> +> [Download](https://github.com/dberzano/sshcertauth/archive/v0.8.5.zip) +> and [read the +> instructions](http://newton.ph.unito.it/~berzano/w/doku.php?id=proof:sshcertauth). + +If you want your users to connect to the PROOF cluster using their Grid +user certificate and private key you might be interested in installing +sshcertauth. Please refer to the [installation +guide](http://newton.ph.unito.it/~berzano/w/doku.php?id=proof:sshcertauth) +for further information. + +### PROOF on Demand + +> Latest recommended PROOF on Demand version is 3.12. +> +> **On CernVM-FS:** `/cvmfs/sft.cern.ch/lcg/external/PoD/3.12` +> +> **Source code:** [PoD download page](http://pod.gsi.de/download.html) +> and [Installation +> instructions](http://pod.gsi.de/doc/3.12/Installation.html) + +[PROOF on Demand](http://pod.gsi.de/) is required on the head node and on the +user's client. + +In case your experiment provides a version of PoD on CernVM-FS you can use +that one. Experiment-independent versions are available from the PH-SFT +cvmfs repository. + +Only if you have specific reasons while you want to use a customly built +PoD version, download the source code and compile it using the +installation instructions. + +Please note that [CMake](http://www.cmake.org/) and +[Boost](http://www.boost.org/) are required to build PoD. + +- After you have built PoD, install it with: + + make install + +- After installing PoD, run: + + pod-server getbins + + This has to be done only once and downloads the binary packages that + will be dynamically transferred to the worker nodes as binary + payload, and prevents us from installing PoD on each cluster node. + + It is important to do this step now, because in case PoD has been + installed in a directory where the user has no write privileges, as + in the case of system-wide installations, the user won't be able to + download those required packages in the PoD binary directory. + +> There is no need to "configure" PoD for your specific cluster: it is +> just enough to install it on your head node. +> +> PoD does not have any system-wide persistent daemon running or any +> system-wide configuration to be performed. Also, no part of PoD will +> be ever run as root. +> +> Do not worry about environment or software configuration at this time: +> there is no system configuration for that. All the environment for +> your software dependencies will be set via proper scripts from the PoD +> client. +> +> PoD client configuration and running is properly covered in the +> appropriate manual page. + +### Firewall configuration + +The head node only requires **TCP ports 22 (SSH) and 443 (HTTPS)** to accept +connections from the outside. Users will get an authentication "token" +from port 443 and all PROOF traffic will be automatically tunneled in a +SSH connection on port 22 by PoD. + +In case you are not using the HTTPS+SSH token+authentication method, access to +the sole port 22 is all you need. diff --git a/proof/doc/confman/DatasetStager.md b/proof/doc/confman/DatasetStager.md new file mode 100644 index 0000000000000..e93067069bdc9 --- /dev/null +++ b/proof/doc/confman/DatasetStager.md @@ -0,0 +1,183 @@ +The Dataset Stager +================== + +Overview +-------- + +The [Dataset Stager (afdsmgrd)](http://afdsmgrd.googlecode.com/) is +a daemon that coordinates the transfer of data from a remote storage +to your local storage. + +For each file to transfer, a script is called. The script can be +customized to support your source and destination protocol. + +Staging requests are issued from the ROOT console, where you can also +control the progress of your staging. How to request stagings and how to +check current transfer progress from ROOT is explained in the [PROOF interface +to AliEn file catalog documentation](TDataSetManagerAliEn.html). + +Installation +------------ + +The Dataset Stager is distributed both on a repository on its own and as +part of ROOT. The easiest way to compile it is to do it inside ROOT. + +Installing from ROOT +-------------------- + +When configuring the ROOT source, enable the Dataset Stager by adding +`--enable-afdsmgrd`. Check in the list of enabled features if you have +"afdsmgrd". + +After running `make` (and, optionally, `make install`) you'll find the +daemon in the same directory of `root.exe`. + +The configuration file and init.d startup script will be in +`$ROOTSYS/etc/proof`. The daemon can and **must** run as unprivileged +user. + +Configuration +------------- + +The Dataset Stager can share its configuration file with PROOF, as +some directives are the same and unknown directives are just ignored. + +Directives are one per line and lines beginning with a pound sign (`#`) +are used for comments. + +> The configuration file is automatically checked at each loop: this +> means you can change configuration without restarting the daemon or +> stopping your current transfers. + +A detailed description of each directive follows. + +set *VARIABLE=value* +: This statement will substitute every occurrence of `$VARIABLE` with + its *value* in the rest of the configuration file. You can have + multiple `set` statements. + +xpd.stagereqrepo [dir:]*directory* +: This directive is shared with PROOF: *directory* is the full path to + the dataset repository. **Defaults to empty:** without this + directive the daemon is not operative. + + The `dir:` prefix is optional. + +dsmgrd.purgenoopds *true|false* +: Set it to *true* **(default is false)** to remove a dataset when no file to stage + is found. If no file to stage is found, but corrupted files exist, the + dataset is kept to signal failures. Used in combination with `xpd.stagereqrepo` + makes it "disposable": only the datasets effectively needed for signaling + the staging status will be kept, improving scalability and stability. + +dsmgrd.urlregex *regex* *subst* +: Each source URL present in the datasets will be matched to *regex* + and substituted to *subst*. *regex* supports grouping using + parentheses, and groups can be referenced in order using the dollar + sign with a number (`$1` for instance) in *subst*. + + Matching and substitution for multiple URL schemas are supported by + using in addition directives `dsmgrd.urlregex2` up to + `dsmgrd.urlregex4` which have the same syntax of this one. + + Example of URL translation via regexp: + + > - Configuration line: + > + > dsmgrd.urlregex alien://(.*)$ root://xrd.cern.ch/$1 + > + > - Source URL: + > + > alien:///alice/data/2012/LHC12b/000178209/ESDs/pass1/12000178209061.17/AliESDs.root + > + > - Resulting URL: + > + > root://xrd.cern.ch//alice/data/2012/LHC12b/000178209/ESDs/pass1/12000178209061.17/AliESDs.root + > +dsmgrd.sleepsecs *secs* +: Seconds to sleep between each loop. The dataset stager checks at + each loop the status of the managed transfers. Defaults to **30 + seconds**. + +dsmgrd.scandseveryloops *n* +: Every `n` loops, the dataset repository is checked for newly + incoming staging requests. Defaults to **10**. + +dsmgrd.parallelxfrs *n* +: Number of concurrent transfers. Defaults to **8**. + +dsmgrd.stagecmd *shell\_command* +: Command to run in order to stage each file. It might be whatever you + want (executable, shell script...). If you add `$URLTOSTAGE` and/or + `$TREENAME` in the *shell\_command*, they'll be substituted + respectively with the destination URL and the default ROOT tree name + in the file (as specified in the dataset staging request from ROOT). + + An example: + + dsmgrd.stagecmd /path/to/afdsmgrd-xrd-stage-verify.sh "$URLTOSTAGE" "$TREENAME" + + Return value of the command is ignored: standard output is + considered, as explained here. + + Defaults to `/bin/false`. + +dsmgrd.cmdtimeoutsecs *secs* +: Timeout on staging command, expressed in seconds: after this + timeout, the command is considered failed and it is killed (in first + place with `SIGSTOP`, then if it is unresponsive with `SIGKILL`). It + defaults to zero, which means "no timeout", i.e. external command + may run forever, if no value is specified. Defaults to **0 (no + timeout)**. + +dsmgrd.corruptafterfails *n* +: Set this to a number above zero to tell the daemon to mark files as + corrupted after a certain number of either download or verification + failures. A value of **0 (default)** tells the daemon to retry + forever. + +Configuring the MonALISA monitoring plugin +------------------------------------------ + +The Dataset Stager supports generic monitoring plugins. The only plugin +distributed with the stager is the MonALISA monitoring plugin. + +dsmgrd.notifyplugin */path/to/libafdsmgrd\_notify\_apmon.so* +: Set it to the path of the MonALISA plugin shared object. By default, + notification plugin is disabled. + +dsmgrd.apmonurl *apmon://apmon.cern.ch* +: This variable tells the ApMon notification plugin how to contact one + or more MonALISA server(s) to activate monitoring via ApMon. It + supports two kinds of URLs: + + - `http[s]://host/path/configuration_file.conf` (a remote file + where to fetch the list of servers from) + + - `apmon://[:password@]monalisahost[:8884]` (a single server to + contact directly) + + If the variable is not set, yet the plugin is loaded, MonALISA + monitoring is inhibited until a valid configuration variable is + provided. + +dsmgrd.apmonprefix *MY::CLUSTER::PREFIX* +: Since MonALISA organizes information in "clusters" and "hosts", here + you can specify what to use as cluster prefix for monitoring + datasets information and daemon status. If this variable is not set, + MonALISA monitoring is inhibited. Please note that the suffix + `_datasets` or `_status` is appended for each of the two types of + monitoring. + +A sample configuration file +--------------------------- + + xpd.stagereqrepo /opt/aaf/var/proof/datasets + dsmgrd.purgenoopds true + dsmgrd.urlregex alien://(.*)$ /storage$1 + dsmgrd.sleepsecs 20 + dsmgrd.scandseveryloops 30 + dsmgrd.parallelxfrs 10 + dsmgrd.stagecmd /opt/aaf/bin/af-xrddm-verify.sh "$URLTOSTAGE" "$TREENAME" + dsmgrd.cmdtimeoutsecs 3600 + dsmgrd.corruptafterfails 0 diff --git a/proof/doc/confman/DeployVirtualAnalysisFacility.md b/proof/doc/confman/DeployVirtualAnalysisFacility.md new file mode 100644 index 0000000000000..a4f5430d817c9 --- /dev/null +++ b/proof/doc/confman/DeployVirtualAnalysisFacility.md @@ -0,0 +1,220 @@ +Deploying the Virtual Analysis Facility +======================================= + +Introduction +------------ + +Thanks to CernVM and PROOF on Demand, it is possible to deploy a ready +to use Virtual Analysis Facility on your cloud (either public, private +or even your desktop computer). + +On the server side, "configuring" the Virtual Analysis Facility is +simply a matter of starting a certain number of CernVM virtual machines +that will become part of your PROOF cluster. CernVM uses +contextualization to specialize each virtual machine to be either a head +node or a worker node. + +The Virtual Analysis Facility comes with many preconfigured things: + +- a HTCondor cluster capable of running PROOF on Demand + +- certificate authentication + +- your experiment's software (if available on CernVM-FS) + +Obtain the CernVM image and contextualization +--------------------------------------------- + +### Download the CernVM bare image + +The Virtual Analysis Facility currently works with *CernVM Batch 2.7.1 +64-bit*. This means that you need to have this CernVM image available +either on your local hard disk (in case of a desktop deployment) or in +your cloud's image repository. + +> For convenience we provide the direct link for the working versions: +> +> - [CernVM 2.7.1 batch 64-bit for +> **KVM**](https://cernvm.cern.ch/releases/19/cernvm-batch-node-2.7.1-2-3-x86_64.hdd.gz) +> +> - [CernVM 2.7.1 batch 64-bit for +> **Xen**](https://cernvm.cern.ch/releases/19/cernvm-batch-node-2.7.1-2-3-x86_64.ext3.gz) +> +> Images are gzipped. In most cases you'll need to gunzip them before +> registering to your image repository. + +### Create VM configuration profiles + +CernVM images are base images supporting boot-time customization via +configuration profiles called "contexts". Context creation can be +performed through the [CernVM Online](https://cernvm-online.cern.ch/) +website. The site is immediately accessible if you have a CERN account. + +Go to your [CernVM Online +Dashboard](https://cernvm-online.cern.ch/dashboard), click on the +**Create new context...** dropdown and select **Virtual Analysis Facility +node**. + +There's only a few parameters to configure. + +Context name +: A name for your context (such as *VAF Master for ATLAS*). Any name + will work. + +Role +: Use this to configure either a *master* or a *slave*. + +VAF master (only available when configuring a slave) +: IP address or FQDN of the Virtual Analysis Facility master. + +Auth method +: Choose between *ALICE LDAP* (useful only for ALICE users) or *Pool + accounts* (good for authenticating all the other Grid users). + +Num. pool accounts (only available when using pool accounts auth) +: Number of pool accounts to create. + +Proxy for CVMFS +: An URL specifying the proxy server for CernVM-FS, such as + `http://ca-proxy.cern.ch:3128/`. If you leave it empty, proxy will + be automatically discovered. + +HTCondor shared secret +: VMs part of the same cluster should have the same value of this + field. It is used to mutually authenticate VMs and it is used like a + password. + +Context password +: Current profile will be saved on the [CernVM Online + repository](http://cernvm-online.cern.ch/). If you don't want the + information there to be publicly available to other users, type in + a value for protecting the context with an encryption password. + +You will have to create a profile for the **master** and the **slave**. Since +most of the configuration variables are the same (like the *HTCondor +shared secret*) you can create one, clone it and change only what's +needed to change. + +Deploy it on the cloud +---------------------- + +Provided you have access to a certain cloud API, you'll need to +instantiate a certain number of CernVM batch images with proper +contextualization: one for the master, as many as you want as slaves. + +CernVM supports contextualization through the "user data" field +supported by all cloud infrastructures. + +Each cloud infrastructure has a different method of setting the "user +data". The following description will focus on: + +- [OpenNebula](http://opennebula.org/) + +- OpenStack (such as the [CERN Agile + infrastructure](https://openstack.cern.ch/)) + +- [Amazon EC2](http://aws.amazon.com/ec2/)-compatible interfaces via + the open [Eucalyptus](http://www.eucalyptus.com/) + [Euca2ools](http://www.eucalyptus.com/eucalyptus-cloud/tools): many popular + clouds support such interface and tools + +### Download the CernVM Online contextualizations + +Go to the CernVM Online Dashboard page where you have previously +customized the contexts for your master and your slaves. + +Click on the rightmost button on the line of the desired context and +select **Get rendered context** from the dropdown: save the output to a +text file (such as `my_vaf_context.txt`, the name we will use in the +examples that follow). This file will be subsequently passed as the so +called "user-data" file to the cloud API. + +> Repeat the operation for both the master context and the slave +> context. + +### OpenStack API: nova + +Example of a CernVM instantiation using `nova`: + +``` {.bash} +nova boot \ + --flavor m1.xlarge \ + --image cernvm-batch-node-2.6.0-4-1-x86_64 \ + --key-name my_default_keyparir \ + --user-data my_vaf_context.txt \ + Name-Of-My-New-VM +``` + +The `--user-data` option requires the context file we've just +downloaded. + +### EC2 API: euca-tools + +Example of a CernVM instantiation using `euca-tools`: + +``` {.bash} +euca-run-instances \ + --instance-type m1.xlarge \ + --key my_default_keyparir \ + --user-data-file my_vaf_context.txt \ + cernvm-batch-node-2.6.0-4-1-x86_64 +``` + +The `--user-data-file` option is the context file we've just downloaded. + +### OpenNebula + +An example VM definition follows: + +``` {.ruby} +CONTEXT=[ + EC2_USER_DATA="<base64_encoded_string>", +] +CPU="6" +VCPU="6" +DISK=[ + IMAGE="cernvm-batch-node-2.6.0-4-1-x86_64", + TARGET="vda" ] +MEMORY="16000" +NAME="CernVM-VAF-Node" +NIC=[ + NETWORK="My-OpenNebula-VNet" ] +OS=[ + ARCH="x86_64" ] +``` + +The `<base64_encoded_string>` requires the base64 version of the whole +downloaded context definition. You can obtain it by running: + + cat my_vaf_context.txt | base64 | tr -d '\n' + +Network security groups +----------------------- + +In order to make the Virtual Analysis Facility work properly, the +firewall of your infrastructure must be configured to allow some +connections. + +Some ports need to allow "external" connections while other ports might +be safely opened to allow only connections from other nodes of the +Virtual Analysis Facility. + +### Ports to open on all nodes + +HTCondor ports +: Allow **TCP and UDP range 9600-9700** only between nodes of the Virtual + Analysis Facility. + +Only HTCondor and PoD communication is needed between the nodes. No HTCondor +ports need to be opened to the world. + +### Additional ports to open on the front end node + +HTTPS +: Allow **TCP 443** from all + +SSH +: Allow **TCP 22** from all + +No other ports need to be opened from the outside. Your definition of +*allow from all* might vary. diff --git a/proof/doc/confman/Makefile b/proof/doc/confman/Makefile new file mode 100644 index 0000000000000..12bd6d9f8f134 --- /dev/null +++ b/proof/doc/confman/Makefile @@ -0,0 +1,54 @@ +# +# Makefile for creating HTML out of Markdown for the PROOF configuration +# manual. +# +# Pandoc is used for the conversion. Thanks to Olivier Couet for the Markdown +# ROOT documentation generation scripts. +# +# Pandoc sample installation on OSX (using Homebrew): +# +# $> brew install haskell-platform +# $> cabal install pandoc +# $> export PATH=$HOME/.cabal/bin:$PATH +# + +PANDOC_OPTS := -s -S --toc --chapters --number-sections -f markdown -H css/github.css +PANDOC_OPTS_INDEX := -s -S -f markdown -H css/github.css + +INPUT_MDS := \ + ConfigProofPoD.md \ + DeployVirtualAnalysisFacility.md \ + UsingVirtualAnalysisFacility.md \ + TDataSetManagerAliEn.md \ + DatasetStager.md + +INDEX_MD := index.md +INDEX_HTML := index.html + +OUTPUT_HTML = $(INPUT_MDS:.md=.html) + +.PHONY: all html clean + +all: html + +html: idx $(OUTPUT_HTML) + +idx: + @echo Generating HTML index + @(echo "Index" > $(INDEX_MD) ; \ + echo "=====" >> $(INDEX_MD) ; \ + echo "" >> $(INDEX_MD) ; \ + for Md in $(INPUT_MDS) ; do \ + echo "1. [$$(head -n1 $$Md)]($${Md%.*}.html)" ; \ + done >> $(INDEX_MD) ) + @pandoc $(PANDOC_OPTS_INDEX) $(INDEX_MD) -o $(INDEX_HTML) + +%.html: %.md + @echo Generating HTML: $@ + @(OFFSET=$$(for F in $(INPUT_MDS) ; do echo $$F ; done | grep -n $< | cut -d: -f1) ; \ + let OFFSET-- ; \ + pandoc $(PANDOC_OPTS) --number-offset $$OFFSET $< -o $@) + +clean: + @echo Cleaning up + @rm -f $(OUTPUT_HTML) $(INDEX_MD) $(INDEX_HTML) diff --git a/proof/doc/confman/TDataSetManagerAliEn.md b/proof/doc/confman/TDataSetManagerAliEn.md new file mode 100644 index 0000000000000..80a4998a59273 --- /dev/null +++ b/proof/doc/confman/TDataSetManagerAliEn.md @@ -0,0 +1,429 @@ +A PROOF interface to the AliEn file catalog +=========================================== + +Overview +-------- + +Datasets have been invented to provide PROOF users a cleaner access to +sets of uniform data: each dataset has a name which helps identifying +the kind of data stored, plus some meta-information, such as: + +- default tree name + +- number of events in the default tree + +- file size + +- integrity information: *is my file corrupted?* + +- locality information: *is my remote file available on a local + storage?* + +Datasets are also used by the [staging daemon +afdsmgrd](http://afdsmgrd.googlecode.com/) to trigger data staging, +*i.e.* to request some data from being transferred from a remote storage +to the local analysis facility disks. + +PROOF datasets are handled by the *dataset manager*, a generic catalog of +datasets which has been historically implemented by the class +`TDataSetManagerFile`, which stored each dataset inside a ROOT file. + +This dataset manager has been conceived for a small *(i.e., hundreds)* +number of datasets which reflected data stored on the local analysis facility +disks. As the PROOF analysis model became popular in ALICE, the number +of datasets grew posing many problems. + +- To give the possibility to process remote data, current datasets + mimick file catalog functionalities by including also lists of files + currently not staged on the local analysis facility. + +- Since users can create their own datasets, in many cases containing + duplicate data, it has become demanding to provide maintenance and + support. + +- Locality information in datasets is static: this means that, if a + file gets deleted from a disk, the corresponding dataset(s) must be + synchronized manually. + +### An interface to the AliEn file catalog + +The new `TDataSetManagerAliEn` class is a new dataset manager which acts +as an intermediate layer between PROOF datasets and the AliEn file +catalog. + +Dataset names do not represent any longer a static list of files: +instead, it represents a **query string** to the AliEn file catalog that +creates a dataset dynamically. + +**Locality information** is also filled on the fly by contacting the local +file server: for instance, in case a *xrootd* pool of disks is used, +fresh online information along with the exact host (endpoint) where each +file is located is provided dynamically in a reasonable amount of time. + +Both file catalog queries and locality information are cached on ROOT +files: cache is shared between users and its expiration time is +configurable. + +Since dataset information is now volatile, a separate and more +straightforward method for issuing staging requests has also been +provided. + +Configuration +------------- + +### PROOF + +Using the new dataset manager requires the `xpd.datasetsrc` directive in +the xproofd configuration file: + + xpd.datasetsrc alien cache:/path/to/dataset/cache urltemplate:http://myserver:1234/data<path> cacheexpiresecs:86400 + +alien +: Tells PROOF that the dataset manager is the AliEn interface (as + opposed to `file`). + +cache +: Specify a path *on the local filesystem* of the host running user's + PROOF master. + + > This path is not a URL but just a local path. Moreover, the path + > must be visible from the host that will run each user's master, + > since a separate dataset manager instance is created per user. + + > If the cache directory does not exist, it is created, if possible, + > with open permissions (`rwxrwxrwx`). On a production environment + > it is advisable to create the cache directory manually beforehand + > with the same permissions. + +urltemplate +: Template used for translating between an `alien://` URL and the + local storage's URL. + + `<path>` is written literally and will be substituted with the full + AliEn path without the protocol. + + > An example on how URL translation works: + > + > - Template URL: + > + > root://alice-caf.cern.ch/<path> + > + > - Source URL: + > + > alien:///alice/data/2012/LHC12b/000178209/ESDs/pass1/12000178209061.17/AliESDs.root + > + > - Resulting URL: + > + > root://alice-caf.cern.ch//alice/data/2012/LHC12b/000178209/ESDs/pass1/12000178209061.17/AliESDs.root + > +cacheexpiresecs +: Number of seconds before cached information is considered expired + and refetched *(e.g., 86400 for one day)*. + +### PROOF-Lite + +One of the advantages of such a dynamic AliEn catalog interface is that +it is possible to use it with PROOF-Lite. + +By default, PROOF-Lite creates on the client session (which acts as a +master as well) a file-based dataset manager. To enable the AliEn +dataset manager in a PROOF-Lite session, run: + +``` {.cpp} +gEnv->SetValue("Proof.DataSetManager", + "alien cache:/path/to/dataset/cache " + "urltemplate:root://alice-caf.cern.ch/<path> " + "cacheexpiresecs:86400"); +TProof::Open(""); +``` + +where the parameters meaning has been described in the previous section. + +> Please note that the environment must be set **before** opening the +> PROOF-Lite session! + +Usage +----- + +The new dataset manager is backwards-compatible with the legacy +interface: each time you want to process or obtain a dataset, instead of +specifying a string containing a dataset name you will specify a query +string to the file catalog. + +### Query string format + +The query string is the string you will use in place of the dataset +name. It does not correspond to a static dataset: instead it represents +a virtual dataset whose information is filled in on the fly. + +There are two different formats you can use: + +- specify data features (such as period and run numbers) for **official + data or Monte Carlo** + +- specify the **AliEn find** command parameters directly + +In the query string it is also possible to specify if you want to +process data from AliEn, only staged data or data from AliEn in "cache +mode". + +#### Official data and Monte Carlo format + +These are the string formats to be used respectively for official data +and official Monte Carlo productions: + + Data;Period=<LHCPERIOD>;Variant=[ESDs|AODXXX];Run=<RUNLIST>;Pass=<PASS> + + Sim;Period=<LHCPERIOD>;Variant=[ESDs|AODXXX];Run=<RUNLIST>; + +Period +: The LHC period. + + Example of valid values: `LHC10h`, `LHC11h_2`, `LHC11f_Technical` + +Variant +: Data variant, which might be `ESDs` (or `ESD`) for ESDs and `AODXXX` + for AODs corresponding to the *XXX* set. + + Example of valid values: `ESDs`, `AOD073`, `AOD086` + +Run +: Runs to be processed, in the form of a single run (`130831`), an + inclusive range (`130831-130833`), or a list of runs and/or ranges + (`130831-130835,130840,130842`). + + Duplicate runs are automatically removed, so in case you specify + `130831-130835,130833` run number 130833 will be processed only + once. + +Pass *(only for data, not for Monte Carlo)* +: The pass number or name. In case you specify only a number `X`, it + will be expanded to `passX`. + + Example of valid values: `1`, `pass1`, `pass2`, `cpass1_muon` + +This is an example of a full valid string: + + Data;Period=LHC10h;Variant=AOD086;Run=130831-130833;Pass=pass1 + +#### AliEn find format + +Whenever a user would like to process data which has not been produced +officially, or whose directory structure in the AliEn file catalog is +non-standard, an interface to the AliEn shell's `find` command is +provided. + +This is the command format: + + Find;BasePath=<BASEPATH>;FileName=<FILENAME>;Anchor=<ANCHOR>;TreeName=<TREENAME>;Regexp=<REGEXP> + +Parameters `BasePath` and `FileName` are passed as-is to the AliEn [find +command](http://alien2.cern.ch/index.php?option=com_content&view=article&id=53&Itemid=99#Searching_for_files), +and are mandatory. + +Parameters `Anchor`, `TreeName` and `Regexp` are optional. + +Here's a detailed description of the parameters. + +BasePath +: Start search under the specified path on the AliEn file catalog. + + Jolly characters are supported: the asterisk (`*`) and the + percentage sign (`%`) are interchangeable. + + Examples of valid values are: + + /alice/data/2010/LHC10h/000123456/*.* + /alice/cern.ch/user/d/dummy/my_pp_production/%.% + +FileName +: File name to look for. + + Examples of valid values are: `root_archive.zip`, `aod_archive.zip`, + `custom_archive.zip`, `AliAOD.root. + +Anchor *(optional)* +: In case `FileName` is a zip archive, the anchor is the name of a + ROOT file inside the archive to point to. + + Examples of valid values are: `AliAOD.root`, `AliESDs.root`, + `MyRootFile.root`. + + > Using the AliEn file catalog it is possible to point directly to a + > ROOT file stored in an archive without using the anchor. + > + > There is however a substantial difference in how data is + > retrieved, especially during staging: auxiliary ROOT files + > *(friends)* are stored inside the archive along with the "main" + > file, so that when you use the archive as `FileName` with the + > proper `Anchor` you are still referencing to the same file, but + > you are giving instructions of downloading the archive. + > + > Using the ROOT file name directly must be done in very special + > cases (*i.e.*, to save space) and only when one is completely sure + > that no external files in the archive are required for analysis. + +TreeName *(optional)* +: Name of each file's default tree. + + Examples of valid values are: `/aodTree`, `/esdTree`, `/myCustomTree`, + `/TheDirectory/TheTree`. + +Regexp *(optional)* +: Additional extended regular expression applied after find command is + run, to fine-grain search results. + + Only `alien://` paths matching the regular expression are + considered, others are discarded. + + Examples of valid values are: + + /[0-9]{6}/[0-9]{3,4} + \.root$ + + > ROOT class + > [TPMERegexp](http://root.cern.ch/root/html/TPMERegexp.html) is + > used to perform regular expression matching. + + +Example of an AliEn raw find dataset string: + + Find;BasePath=/alice/data/2010/LHC10h/000139505/ESDs/pass1/*.*;FileName=root_archive.zip;Anchor=AliESDs.root + +#### Data access modes + +It is possible to append to the format string the `Mode` specifier that +affects the way URLs are generated. + + Mode=[local|remote|cache] + +This parameter is optional and defaults to `local`. Description of each +possible value follows: + +local +: Local storage is checked for the presence of data you requested. + Output URLs will be relative to your local storage. Also, locality + information *(i.e., is your file staged?)* is filled. + + If you run a PROOF analysis on a dataset with this mode specified, + only data marked as "staged" will be processed. + + This method is the preferred one, since it does not overload the + remote storage, and it enables users to process partially-staged + datasets, or partially-reconstructed runs, without the need to + manually update static datasets. + + > This is the default if no mode is specified, and it is also the + > most efficient one. + > + > Despite it might take some time (up to a couple of minutes to + > locate ~4000 files), returned information is always reliable + > (because it's dynamic) and speeds up analysis (because analysis + > will always be run only on files having local copies). + > + > Moreover this information is cached for a configurable period of + > time, so that subsequent calls to the same dataset will be faster. + +remote +: Only AliEn URLs are returned. + + A PROOF analysis run on a dataset with this mode specified will + always obtain data from a remote storage, according to the AliEn + file catalog. + + > Tasks run on remote data are usually much slower than using local + > storage. + +cache +: URLs pointing to local copies of files are returned, but does not check + whether the file is locally present or not. + + If local storage is configured for retrieving from AliEn files that + are not available locally (which is the case of xrootd with vMSS), + then data will be downloaded *while analysis is running*. + + It is called *cache mode* because it treats the local storage as a + cache for the remote storage. + + > This mode is usually very slow on a busy analysis facility since + > retrieving data in real time without any kind of scheduling is + > inefficient. It also conflicts with the preferred method, which is + > to stage data asynchronously using the [stager + > daemon](http://afdsmgrd.googlecode.com/). + +#### Force cache refresh + +If the cached information for a certain AliEn file catalog query is wrong, +it is possible to force querying the catalog again by using the keyword +`ForceUpdate`: + + Data;ForceUpdate;Period=LHC10h;Variant=AOD086;Run=130831-130833;Pass=pass1 + +### Staging requests + +Issuing staging requests and keeping track of them requires an auxiliary +database that can be read and updated by the [data stager +daemon](http://afdsmgrd.googlecode.com/). + +Whenever a staging request is issued, a ROOT file containing the dataset +is saved in a special directory on the master's filesystem, monitored by +the file stager. + +#### PROOF configuration + +In the xproofd configuration file, there is a directive to specify the +directory used as repository for staging requests: + + xpd.stagereqrepo [dir:]/path/to/local/directory + +> The literal `dir:` prefix is optional. + +This directive is shared between PROOF and the stager daemon, so that the +same configuration file can be used for both. + +Permissions on this directory must be kept open. + +> Versions of the stager daemon prior to v1.0.7 do not support open +> permissions and the staging repository directive. + +#### Request and monitor staging + +Staging requests and monitoring can be done from within a PROOF session. + +`gProof->RequestStagingDataSet("QueryString")` +: Requests staging of the dataset specified via the query string. + + Staging request is honored if the stager daemon is running. + + > In order to avoid requesting to stage undesired data, it is + > advisable to check in advance the results of your query string: + > + > `gProof->ShowDataSet("QueryString")` + +`TProof->ShowStagingStatusDataSet("QueryString"[, "opts"])` +: Shows progress status of a previously given staging request with + data specified by the query string. + + Options are optional, and passed as-is to the `::Print()` method. + + > It is possible to show all the files marked as corrupted by the + > daemon: + > + > gProof->ShowStagingStatusDataSet("QueryString", "C") + > + > Or all the files successfully staged and not corrupted: + > + > gProof->ShowStagingStatusDataSet("QueryString", "Sc") + +`gProof->GetStagingStatusDataSet("QueryString")` +: Gets a `TFileCollection` containing information on the staging + request specified by the query string. + + Works exactly like `ShowStagingStatusDataSet()` but returns an + object instead of displaying information on the screen. + +`gProof->CancelStagingDataSet("QueryString")` +: Removes a dataset from the list of staging requests. Datasets used + as staging requests are usually removed automatically by the staging + daemon if everything went right, so this command is used mostly to + purge a completed staging request when it has some corrupted files. diff --git a/proof/doc/confman/UsingVirtualAnalysisFacility.md b/proof/doc/confman/UsingVirtualAnalysisFacility.md new file mode 100644 index 0000000000000..7a9325de8f70a --- /dev/null +++ b/proof/doc/confman/UsingVirtualAnalysisFacility.md @@ -0,0 +1,379 @@ +Using the Virtual Analysis Facility +=================================== + +Introduction +------------ + +The Virtual Analysis Facility can be easily used by having installed on +your client the following software: + +- [ROOT](http://root.cern.ch/) + +- [PROOF on Demand](http://pod.gsi.de/) + +- The VAF client *(see below)*: a convenience tool that sets up the + environment for your experiment's software both on your client and + on the PROOF worker nodes + +> If you are the end user, you'll probably might skip the part that +> concerns how to configure the VAF client: your system administrator +> has probably and conveniently set it up for you. + +The Virtual Analysis Facility client +------------------------------------ + +The Virtual Analysis Facility client takes care of setting the +environment for the end user required by your software's experiment. The +environment will both be set on the client and on each PROOF node. + +Technically it is a Bash shell script which provides shortcuts for PROOF +on Demand commands and ensures local and remote environment consistency: +by executing it you enter a new clean environment where all your +software dependencies have already been set up. + +Local and remote environment configuration is split into a series of +files, which give the possibility to: + +- have a system-wide, sysadmin-provided experiment configuration + +- execute user actions either *before* or *after* the execution of the + system-wide script (for instance, choosing the preferred version of + the experiment's software) + +- transfer a custom user **payload** on each PROOF worker (for instance, + user's client-generated Grid credentials to make PROOF workers + capable of accessing a remote authenticated storage) + +Configuration files are searched for in two different locations: + +- a system-wide directory: `<client_install_dir>/etc` + +- user's home directory: `~/.vaf` + +> A system-wide configuration file always has precedence over user's +> configuration. It is thus possible for the sysadmin to enforce a +> policy where some scripts cannot ever be overridden. + +Thanks to this separation, users can maintain an uncluttered directory +with very simple configuration files that contain only what really needs +or is allowed to be customized: for instance, user might specify a single line +containing the needed ROOT version, while all the technicalities to set +up the environment are taken care of inside system-installed scripts, +leaving the user's configuration directory clean and uncluttered. + +### Local environment configuration + +All the local environment files are loaded at the time of the +client's startup following a certain order + +- `common.before` + +- `local.before` + +- `local.conf` + +- `$VafConf_LocalPodLocation/PoD_env.sh` + +- `common.after` + +- `local.after` + +The `common.*` files are sourced both for the local and the remote +environment. This might be convenient to avoid repeating the same +configuration in different places. + +Each file is looked for first in the system-wide directory and then in +the user's directory. If a configuration file does not exist, it is +silently skipped. + +The `$VafConf_LocalPodLocation/PoD_env.sh` environment script, provided +with each PROOF on Demand installation, *must exist*: without this file, +the VAF client won't start. + +### List of VAF-specific variables + +There are some special variables that need to be set in one of the above +configuration files. + +`$VafConf_LocalPodLocation` +: Full path to the PoD installation on the client. + + > The `$VafConf_LocalPodLocation` variable must be set before the + > `PoD_env.sh` script gets sourced, so set it either in + > `common.before`, `local.before` or `local.conf`. Since PoD is + > usually system-wide installed, its location is normally + > system-wide set in either the `local.conf` file by the system + > administrator. + +`$VafConf_RemotePodLocation` +: Full path to the PoD installation on the VAF master node. + + *Note: this variable should be set in the configuration files for + the local environment despite it refers to a software present on the + remote nodes.* + +`$VafConf_PodRms` *(optional)* +: Name of the Resource Management System used for submitting PoD jobs. + Run `pod-submit -l` to see the possible values. + + If not set, defaults to `condor`. + +`$VafConf_PodQueue` *(optional)* +: Queue name where to submit PoD jobs. + + If no queue has been given, the default one configured on your RMS + will be used. + +### Remote environment configuration + +All the PoD commands sent to the VAF master will live in the environment +loaded via using the following scripts. + +Similarly to the local environment, configuration is split in different files +to allow for a system-wide configuration, which has precedence over +user's configuration in the home directory. If a script cannot be found, +it will be silently skipped. + +- `<output_of_payload>` + +- `common.before` + +- `remote.before` + +- `remote.conf` + +- `common.after` + +- `remote.after` + +For an explanation on how to pass extra data to the workers safely +through the payload, see below. + +### Payload: sending local files to the remote nodes + +In many cases it is necessary to send some local data to the remote +workers: it is very common, for instance, to distribute a local Grid +authentication proxy on the remote workers to let them authenticate to +access a data storage. + +The `payload` file must be an executable generating some output that +will be prepended to the remote environment preparation. Differently +than the other environment scripts, it is not executed: instead, it is +first run, then *the output it produces will be executed*. + +Let's see a practical example to better understand how it works. We need +to send our Grid proxy to the master node. + +This is our `payload` executable script: + +``` {.bash} +#!/bin/bash +echo "echo '`cat /tmp/x509up_u$UID | base64 | tr -d '\r\n'`'" \ + "| base64 -d > /tmp/x509up_u\$UID" +``` + +This script will be executed locally, providing another "script line" as +output: + +``` {.bash} +echo 'VGhpcyBpcyB0aGUgZmFrZSBjb250ZW50IG9mIG91ciBHcmlkIHByb3h5IGZpbGUuCg==' | base64 -d > /tmp/x509up_u$UID +``` + +This line will be prepended to the remote environment script and will be +executed before anything else on the remote node: it will effectively +decode the Base64 string back to the proxy file and write it into the +`/tmp` directory. Note also that the first `$UID` is not escaped and +will be substituted *locally* with your user ID *on your client +machine*, while the second one has the dollar escaped (`\$UID`) and will +be substituted *remotely* with your user ID *on the remote node*. + +> It is worth noting that the remote environment scripts will be sent to +> the remote node using a secure connection (SSH), thus there is no +> concern in placing sensitive user data there. + +Installing the Virtual Analysis Facility client +----------------------------------------------- + +### Download the client from Git + +The Virtual Analysis Facility client is available on +[GitHub](https://github.com/dberzano/virtual-analysis-facility): + +``` {.bash} +git clone git://github.com/dberzano/virtual-analysis-facility.git /dest/dir +``` + +The client will be found in `/dest/dir/client/bin/vaf-enter`: it is +convenient to add it to the `$PATH` so that the users might simply start +it by typing `vaf-enter`. + +### Install the experiment's configuration files system-wide + +A system administrator might find convenient to install the experiment +environment scripts system-wide. + +Configuration scripts for LHC experiments are shipped with the VAF +client and can be found in +`/dest/dir/client/config-samples/<experiment_name>`. To make them used +by default by the VAF client, place them in the `/dest/dir/etc` +directory like this: + +``` {.bash} +rsync -a /dest/dir/client/config-samples/<experiment_name>/ /dest/dir/etc/ +``` + +Remember that the trailing slash in the source directory name has a +meaning in `rsync` and must not be omitted. + +> Remember that system-wide configuration files will always have +> precedence over user's configuration files, so *don't place there +> files that are supposed to be provided by the user!* + +Entering the Virtual Analysis Facility environment +-------------------------------------------------- + +The Virtual Analysis Facility client is a wrapper around commands sent +to the remote host by means of PROOF on Demand's `pod-remote`. The VAF +client takes care of setting up passwordless SSH from your client node +to the VAF master. + +### Getting the credentials + +> You can skip this paragraph if the remote server wasn't configured for +> HTTPS+SSH authentication. + +In our example we will assume that the remote server's name is +`cloud-gw-213.to.infn.it`: substitute it with your remote endpoint. + +First, check that you have your Grid certificate and private key +installed both in your browser and in the `~/.globus` directory of your +client. + +Point your browser to `https://cloud-gw-213.to.infn.it/auth/`: you'll +probably be asked for a certificate to choose for authentication. Pick +one and you'll be presented with the following web page: + +![Web authentication with sshcertauth](img/sshcertauth-web.png) + +The webpage clearly explains you what to do next. + +### Customizing user's configuration + +Before entering the VAF environment, you should customize the user's +configuration. How to do so depends on your experiment, but usually you +should essentially specify the version of the experiment's software you +need. + +For instance, in the CMS use case, only one file is needed: +`~/.vaf/common.before`, which contains something like: + +``` {.bash} +# Version of CMSSW (as reported by "scram list") +export VafCmsswVersion='CMSSW_5_3_9_sherpa2beta2' +``` + +### Entering the VAF environment + +Open a terminal on your client machine (can be either your local +computer or a remote user interface) and type: + + vaf-enter <username>@cloud-gw-213.to.infn.it + +You'll substitute `<username>` with the username that either your system +administrator or the web authentication (if you used it) provided you. + +You'll be presented with a neat shell which looks like the following: + + Entering VAF environment: dberzano@cloud-gw-213.to.infn.it + Remember: you are still in a shell on your local computer! + pod://dberzano@cloud-gw-213.to.infn.it [~] > + +This shell runs on your local computer and it has the environment +properly set up. + +PoD and PROOF workflow +---------------------- + +> The following operations are valid inside the `vaf-enter` environment. + +### Start your PoD server + +With PROOF on Demand, each user has the control of its own personal +PROOF cluster. The first thing to do is to start the PoD server and the +PROOF master like this: + + vafctl --start + +A successful output will be similar to: + + ** Starting remote PoD server on dberzano@cloud-gw-213.to.infn.it:/cvmfs/sft.cern.ch/lcg/external/PoD/3.12/x86_64-slc5-gcc41-python24-boost1.53 + ** Server is started. Use "pod-info -sd" to check the status of the server. + +### Request and wait for workers + +Now the server is started but you don't have any worker available. To +request for `<n>` workers, do: + + vafreq <n> + +To check how many workers became available for use: + + pod-info -n + +To continuously update the check (`Ctrl-C` to terminate): + + vafcount + +Example of output: + + Updating every 5 seconds. Press Ctrl-C to stop monitoring... + [20130411-172235] 0 + [20130411-172240] 0 + [20130411-172245] 12 + [20130411-172250] 12 + ... + +To execute a command after a certain number of workers is available (in +the example we wait for 5 workers then start ROOT): + + vafwait 5 && root -l + +> Workers take some time before becoming available. Also, it is possible +> that not all the requested workers will be satisfied. + +### Start ROOT and use PROOF + +When you are satisfied with the available number of active workers, you +may start your PROOF analysis. Start ROOT, and from its prompt connect +to PROOF like this: + + root [0] TProof::Open("pod://"); + +Example of output: + + Starting master: opening connection ... + Starting master: OK + Opening connections to workers: OK (12 workers) + Setting up worker servers: OK (12 workers) + PROOF set to parallel mode (12 workers) + +### Stop or restart your PoD cluster + +At the end of your session, remember to free the workers by stopping +your PoD server: + + vafctl --stop + +> PoD will stop the PROOF master and the workers after detecting they've +> been idle for a certain amount of time anyway, but it is a good habit +> to stop it for yourself when you're finished using it, so that you are +> immediately freeing resources and let them be available for other +> users. + +In case of a major PROOF failure (i.e., crash), you can simply restart +your personal PROOF cluster by running: + + vafctl --start + +PoD will stop and restart the PROOF master. You'll need to request the +workers again at this point. diff --git a/proof/doc/confman/css/github.css b/proof/doc/confman/css/github.css new file mode 100755 index 0000000000000..13903c0a74982 --- /dev/null +++ b/proof/doc/confman/css/github.css @@ -0,0 +1,300 @@ +<style> +body { + font-family: Helvetica, arial, sans-serif; + font-size: 14px; + line-height: 1.6; + padding-top: 10px; + padding-bottom: 10px; + background-color: white; + padding: 30px; } + +body > *:first-child { + margin-top: 0 !important; } +body > *:last-child { + margin-bottom: 0 !important; } + +a { + text-decoration: none; + color: #4183C4; } +a.absent { + color: #cc0000; } +a.anchor { + display: block; + padding-left: 30px; + margin-left: -30px; + cursor: pointer; + position: absolute; + top: 0; + left: 0; + bottom: 0; } + +h1, h2, h3, h4, h5, h6 { + margin: 20px 0 10px; + padding: 0; + font-weight: bold; + -webkit-font-smoothing: antialiased; + cursor: text; + position: relative; } + +h1:hover a.anchor, h2:hover a.anchor, h3:hover a.anchor, h4:hover a.anchor, h5:hover a.anchor, h6:hover a.anchor { + background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA09pVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMy1jMDExIDY2LjE0NTY2MSwgMjAxMi8wMi8wNi0xNDo1NjoyNyAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNiAoMTMuMCAyMDEyMDMwNS5tLjQxNSAyMDEyLzAzLzA1OjIxOjAwOjAwKSAgKE1hY2ludG9zaCkiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6OUM2NjlDQjI4ODBGMTFFMTg1ODlEODNERDJBRjUwQTQiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6OUM2NjlDQjM4ODBGMTFFMTg1ODlEODNERDJBRjUwQTQiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDo5QzY2OUNCMDg4MEYxMUUxODU4OUQ4M0REMkFGNTBBNCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo5QzY2OUNCMTg4MEYxMUUxODU4OUQ4M0REMkFGNTBBNCIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PsQhXeAAAABfSURBVHjaYvz//z8DJYCRUgMYQAbAMBQIAvEqkBQWXI6sHqwHiwG70TTBxGaiWwjCTGgOUgJiF1J8wMRAIUA34B4Q76HUBelAfJYSA0CuMIEaRP8wGIkGMA54bgQIMACAmkXJi0hKJQAAAABJRU5ErkJggg==) no-repeat 10px center; + text-decoration: none; } + +h1 tt, h1 code { + font-size: inherit; } + +h2 tt, h2 code { + font-size: inherit; } + +h3 tt, h3 code { + font-size: inherit; } + +h4 tt, h4 code { + font-size: inherit; } + +h5 tt, h5 code { + font-size: inherit; } + +h6 tt, h6 code { + font-size: inherit; } + +h1 { + font-size: 28px; + color: black; } + +h2 { + font-size: 24px; + border-bottom: 1px solid #cccccc; + color: black; } + +h3 { + font-size: 18px; } + +h4 { + font-size: 16px; } + +h5 { + font-size: 14px; } + +h6 { + color: #777777; + font-size: 14px; } + +p, blockquote, ul, ol, dl, li, table, pre { + margin: 15px 0; } + +hr { + background: transparent url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAYAAAAECAYAAACtBE5DAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6OENDRjNBN0E2NTZBMTFFMEI3QjRBODM4NzJDMjlGNDgiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6OENDRjNBN0I2NTZBMTFFMEI3QjRBODM4NzJDMjlGNDgiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDo4Q0NGM0E3ODY1NkExMUUwQjdCNEE4Mzg3MkMyOUY0OCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo4Q0NGM0E3OTY1NkExMUUwQjdCNEE4Mzg3MkMyOUY0OCIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PqqezsUAAAAfSURBVHjaYmRABcYwBiM2QSA4y4hNEKYDQxAEAAIMAHNGAzhkPOlYAAAAAElFTkSuQmCC) repeat-x 0 0; + border: 0 none; + color: #cccccc; + height: 4px; + padding: 0; +} + +body > h2:first-child { + margin-top: 0; + padding-top: 0; } +body > h1:first-child { + margin-top: 0; + padding-top: 0; } + body > h1:first-child + h2 { + margin-top: 0; + padding-top: 0; } +body > h3:first-child, body > h4:first-child, body > h5:first-child, body > h6:first-child { + margin-top: 0; + padding-top: 0; } + +a:first-child h1, a:first-child h2, a:first-child h3, a:first-child h4, a:first-child h5, a:first-child h6 { + margin-top: 0; + padding-top: 0; } + +h1 p, h2 p, h3 p, h4 p, h5 p, h6 p { + margin-top: 0; } + +li p.first { + display: inline-block; } +li { + margin: 0; } +ul, ol { + padding-left: 30px; } + +ul :first-child, ol :first-child { + margin-top: 0; } + +dl { + padding: 0; } + dl dt { + font-size: 14px; + font-weight: bold; + font-style: italic; + padding: 0; + margin: 15px 0 5px; } + dl dt:first-child { + padding: 0; } + dl dt > :first-child { + margin-top: 0; } + dl dt > :last-child { + margin-bottom: 0; } + dl dd { + margin: 0 0 15px; + padding: 0 15px; } + dl dd > :first-child { + margin-top: 0; } + dl dd > :last-child { + margin-bottom: 0; } + +blockquote { + border-left: 4px solid #dddddd; + padding: 0 15px; + color: #777777; } + blockquote > :first-child { + margin-top: 0; } + blockquote > :last-child { + margin-bottom: 0; } + +table { + padding: 0;border-collapse: collapse; } + table tr { + border-top: 1px solid #cccccc; + background-color: white; + margin: 0; + padding: 0; } + table tr:nth-child(2n) { + background-color: #f8f8f8; } + table tr th { + font-weight: bold; + border: 1px solid #cccccc; + margin: 0; + padding: 6px 13px; } + table tr td { + border: 1px solid #cccccc; + margin: 0; + padding: 6px 13px; } + table tr th :first-child, table tr td :first-child { + margin-top: 0; } + table tr th :last-child, table tr td :last-child { + margin-bottom: 0; } + +img { + max-width: 100%; } + +span.frame { + display: block; + overflow: hidden; } + span.frame > span { + border: 1px solid #dddddd; + display: block; + float: left; + overflow: hidden; + margin: 13px 0 0; + padding: 7px; + width: auto; } + span.frame span img { + display: block; + float: left; } + span.frame span span { + clear: both; + color: #333333; + display: block; + padding: 5px 0 0; } +span.align-center { + display: block; + overflow: hidden; + clear: both; } + span.align-center > span { + display: block; + overflow: hidden; + margin: 13px auto 0; + text-align: center; } + span.align-center span img { + margin: 0 auto; + text-align: center; } +span.align-right { + display: block; + overflow: hidden; + clear: both; } + span.align-right > span { + display: block; + overflow: hidden; + margin: 13px 0 0; + text-align: right; } + span.align-right span img { + margin: 0; + text-align: right; } +span.float-left { + display: block; + margin-right: 13px; + overflow: hidden; + float: left; } + span.float-left span { + margin: 13px 0 0; } +span.float-right { + display: block; + margin-left: 13px; + overflow: hidden; + float: right; } + span.float-right > span { + display: block; + overflow: hidden; + margin: 13px auto 0; + text-align: right; } + +code, tt { + margin: 0 2px; + padding: 0 5px; + white-space: nowrap; + border: 1px solid #eaeaea; + background-color: #f8f8f8; + border-radius: 3px; } + +pre code { + margin: 0; + padding: 0; + white-space: pre; + border: none; + background: transparent; } + +.highlight pre { + background-color: #f8f8f8; + border: 1px solid #cccccc; + font-size: 13px; + line-height: 19px; + overflow: auto; + padding: 6px 10px; + border-radius: 3px; } + +pre { + background-color: #f8f8f8; + border: 1px solid #cccccc; + font-size: 13px; + line-height: 19px; + overflow: auto; + padding: 6px 10px; + border-radius: 3px; } + pre code, pre tt { + background-color: transparent; + border: none; } + +sup { + font-size: 0.83em; + vertical-align: super; + line-height: 0; +} +* { + -webkit-print-color-adjust: exact; +} +@media screen and (min-width: 914px) { + body { + width: 854px; + margin:0 auto; + } +} +@media print { + table, pre { + page-break-inside: avoid; + } + pre { + word-wrap: break-word; + } +} +</style> diff --git a/proof/doc/confman/img/sshcertauth-web.png b/proof/doc/confman/img/sshcertauth-web.png new file mode 100644 index 0000000000000..801117cc588cc Binary files /dev/null and b/proof/doc/confman/img/sshcertauth-web.png differ diff --git a/proof/doc/v522/index.html b/proof/doc/v522/index.html index 75d762abd344e..a5dcc44155e81 100644 --- a/proof/doc/v522/index.html +++ b/proof/doc/v522/index.html @@ -197,7 +197,7 @@ <h3>PROOF</h3> <li>Avoid duplicating worker logs in the master log file unless -when explicitely needed by the request (Exec(...), Print(...)) or when +when explicitly needed by the request (Exec(...), Print(...)) or when an error occured</li><li>Fix problem with the determination and transmission of the name of the object to be processed. The problem appeared when processing files diff --git a/proof/doc/v534/index.html b/proof/doc/v534/index.html index 44bfb1b7e4460..a400515eb717a 100644 --- a/proof/doc/v534/index.html +++ b/proof/doc/v534/index.html @@ -3,7 +3,7 @@ <a name="proof"></a> <h3>PROOF System</h3> <ul> - <li style="font-style: italic;">Added functionality</li> + <li style="font-style: italic;">Added functionality <ul> <li>Added interface to simplify the creation of the performance tree: two new methods TProof::SetPerfTree("<file>") and @@ -47,7 +47,8 @@ <h3>PROOF System</h3> a dedicated new class TStatsFeedback, and uses a TStatsFeedback instead of TDrawFeedback to display the feedback. </li> </ul> - <li style="font-style: italic;">Improvements</li> + </li> + <li style="font-style: italic;">Improvements <ul> <li>Add to TProofMgr two static functions to upload files. These functions are both called UploadFiles and differ in the first argument, @@ -83,7 +84,8 @@ <h3>PROOF System</h3> when a directory or file with the name of the package did already exist in the local working directory. </li> </ul> - <li style="font-style: italic;">Fixes</li> + </li> + <li style="font-style: italic;">Fixes <ul> <li>Fix merging issue affecting automatic dataset creation when only one worker is active.</li> @@ -99,5 +101,6 @@ <h3>PROOF System</h3> template in 'xpd.multiuser'. </li> </ul> + </li> </ul> diff --git a/proof/peac/Module.mk b/proof/peac/Module.mk deleted file mode 100644 index a762f89c00d1b..0000000000000 --- a/proof/peac/Module.mk +++ /dev/null @@ -1,110 +0,0 @@ -# Module.mk for peac module -# Copyright (c) 2004 Rene Brun and Fons Rademakers -# -# Author: Maarten Ballintijn 18/10/2004 - -MODNAME := peac -MODDIR := $(ROOT_SRCDIR)/proof/$(MODNAME) -MODDIRS := $(MODDIR)/src -MODDIRI := $(MODDIR)/inc - -PEACDIR := $(MODDIR) -PEACDIRS := $(PEACDIR)/src -PEACDIRI := $(PEACDIR)/inc - -##### libPeac ##### -PEACL := $(MODDIRI)/LinkDef.h -PEACDS := $(call stripsrc,$(MODDIRS)/G__Peac.cxx) -PEACDO := $(PEACDS:.cxx=.o) -PEACDH := $(PEACDS:.cxx=.h) - -PEACH := $(filter-out $(MODDIRI)/LinkDef%,$(wildcard $(MODDIRI)/*.h)) -PEACS := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx)) -PEACO := $(call stripsrc,$(PEACS:.cxx=.o)) - -PEACDEP := $(PEACO:.o=.d) $(PEACDO:.o=.d) - -PEACLIB := $(LPATH)/libPeac.$(SOEXT) -PEACMAP := $(PEACLIB:.$(SOEXT)=.rootmap) - -##### libPeacGui ##### -PEACGUIL := $(MODDIRI)/LinkDefGui.h -PEACGUIDS := $(call stripsrc,$(MODDIRS)/G__PeacGui.cxx) -PEACGUIDO := $(PEACGUIDS:.cxx=.o) -PEACGUIDH := $(PEACGUIDS:.cxx=.h) - -PEACGUIH := $(MODDIRI)/TProofStartupDialog.h -PEACGUIS := $(MODDIRS)/TProofStartupDialog.cxx -PEACGUIO := $(call stripsrc,$(PEACGUIS:.cxx=.o)) - -PEACGUIDEP := $(PEACGUIO:.o=.d) $(PEACGUIDO:.o=.d) - -PEACGUILIB := $(LPATH)/libPeacGui.$(SOEXT) -PEACGUIMAP := $(PEACGUILIB:.$(SOEXT)=.rootmap) - -# remove GUI files from PEAC files -PEACH := $(filter-out $(PEACGUIH),$(PEACH)) -PEACS := $(filter-out $(PEACGUIS),$(PEACS)) -PEACO := $(filter-out $(PEACGUIO),$(PEACO)) -PEACDEP := $(filter-out $(PEACGUIDEP),$(PEACDEP)) - -# used in the main Makefile -ALLHDRS += $(patsubst $(MODDIRI)/%.h,include/%.h,$(PEACH)) -ALLHDRS += $(patsubst $(MODDIRI)/%.h,include/%.h,$(PEACGUIH)) -ALLLIBS += $(PEACLIB) $(PEACGUILIB) -ALLMAPS += $(PEACMAP) $(PEACGUIMAP) - -# include all dependency files -INCLUDEFILES += $(PEACDEP) $(PEACGUIDEP) - -##### local rules ##### -.PHONY: all-$(MODNAME) clean-$(MODNAME) distclean-$(MODNAME) - -include/%.h: $(PEACDIRI)/%.h - cp $< $@ - -$(PEACLIB): $(PEACO) $(PEACDO) $(ORDER_) $(MAINLIBS) $(PEACLIBDEP) - @$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \ - "$(SOFLAGS)" libPeac.$(SOEXT) $@ "$(PEACO) $(PEACDO)" \ - "$(PEACLIBEXTRA)" - -$(PEACDS): $(PEACH) $(PEACL) $(ROOTCINTTMPDEP) - $(MAKEDIR) - @echo "Generating dictionary $@..." - $(ROOTCINTTMP) -f $@ -c $(PEACH) $(PEACL) - -$(PEACMAP): $(RLIBMAP) $(MAKEFILEDEP) $(PEACL) - $(RLIBMAP) -o $@ -l $(PEACLIB) \ - -d $(PEACLIBDEPM) -c $(PEACL) - -$(PEACGUILIB): $(PEACGUIO) $(PEACGUIDO) $(ORDER_) $(MAINLIBS) $(PEACGUILIBDEP) - @$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \ - "$(SOFLAGS)" libPeacGui.$(SOEXT) $@ \ - "$(PEACGUIO) $(PEACGUIDO)" \ - "$(PEACGUILIBEXTRA)" - -$(PEACGUIDS): $(PEACGUIH) $(PEACGUIL) $(ROOTCINTTMPDEP) - $(MAKEDIR) - @echo "Generating dictionary $@..." - $(ROOTCINTTMP) -f $@ -c $(PEACGUIH) $(PEACGUIL) - -$(PEACGUIMAP): $(RLIBMAP) $(MAKEFILEDEP) $(PEACGUIL) - $(RLIBMAP) -o $(PEACGUIMAP) -l $(PEACGUILIB) \ - -d $(PEACGUILIBDEPM) -c $(PEACGUIL) - -all-$(MODNAME): $(PEACLIB) $(PEACGUILIB) $(PEACMAP) $(PEACGUIMAP) - -clean-$(MODNAME): - @rm -f $(PEACO) $(PEACDO) $(PEACGUIO) $(PEACGUIDO) - -clean:: clean-$(MODNAME) - -distclean-$(MODNAME): clean-$(MODNAME) - @rm -f $(PEACDEP) $(PEACDS) $(PEACDH) $(PEACLIB) \ - $(PEACGUIDEP) $(PEACGUIDS) $(PEACGUIDH) $(PEACGUILIB) \ - $(PEACMAP) $(PEACGUIMAP) - -distclean:: distclean-$(MODNAME) - -##### extra rules ###### -$(PEACO): CXXFLAGS += $(CLARENSINC) diff --git a/proof/peac/inc/LinkDef.h b/proof/peac/inc/LinkDef.h deleted file mode 100644 index f6f93ecfdc00a..0000000000000 --- a/proof/peac/inc/LinkDef.h +++ /dev/null @@ -1,22 +0,0 @@ -/* @(#)root/peac:$Id$ */ - -/************************************************************************* - * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifdef __CINT__ - -#pragma link off all globals; -#pragma link off all classes; -#pragma link off all functions; - -#pragma link C++ global gPEAC; - -#pragma link C++ class TPEAC; -#pragma link C++ class TProofPEAC; - -#endif diff --git a/proof/peac/inc/LinkDefGui.h b/proof/peac/inc/LinkDefGui.h deleted file mode 100644 index f94912f466537..0000000000000 --- a/proof/peac/inc/LinkDefGui.h +++ /dev/null @@ -1,19 +0,0 @@ -/* @(#)root/peac:$Id$ */ - -/************************************************************************* - * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifdef __CINT__ - -#pragma link off all globals; -#pragma link off all classes; -#pragma link off all functions; - -#pragma link C++ class TProofStartupDialog; - -#endif diff --git a/proof/peac/inc/TPEAC.h b/proof/peac/inc/TPEAC.h deleted file mode 100644 index 2f94a760daefc..0000000000000 --- a/proof/peac/inc/TPEAC.h +++ /dev/null @@ -1,62 +0,0 @@ -// @(#)root/peac:$Id$ -// Author: Maarten Ballintijn 21/10/2004 -// Author: Kris Gulbrandsen 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_TPEAC -#define ROOT_TPEAC - -////////////////////////////////////////////////////////////////////////// -// // -// TPEAC // -// // -// Setup of a PROOF session using PEAC // -// // -////////////////////////////////////////////////////////////////////////// - -#ifndef ROOT_TObject -#include "TObject.h" -#endif - -#ifndef ROOT_TString -#include "TString.h" -#endif - - -class TGM; -class TDSet; -class TProof; - - -class TPEAC : public TObject { - -private: - TGM *fGM; //global manager object - TString fSessionID; //session id gotten from clarens - TString fDataSet; //dataset used to create session - TProof *fProof; //proof session started in StartSession - - TPEAC(); - -public: - virtual ~TPEAC(); - - static void Init(); - TDSet *StartSession(const Char_t *dataset); - void EndSession(); - void EndSessionCallback(); - - ClassDef(TPEAC,0) // Manage PROOF sessions using PEAC -}; - - -R__EXTERN TPEAC *gPEAC; - -#endif diff --git a/proof/peac/inc/TProofPEAC.h b/proof/peac/inc/TProofPEAC.h deleted file mode 100644 index a582c011aba8f..0000000000000 --- a/proof/peac/inc/TProofPEAC.h +++ /dev/null @@ -1,65 +0,0 @@ -// @(#)root/peac:$Id$ -// Author: Maarten Ballintijn 21/10/2004 -// Author: Kris Gulbrandsen 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_TProofPEAC -#define ROOT_TProofPEAC - -////////////////////////////////////////////////////////////////////////// -// // -// TProofPEAC // -// // -// This class implements a PROOF session which uses PEAC // -// // -////////////////////////////////////////////////////////////////////////// - -#ifndef ROOT_TProof -#include "TProof.h" -#endif -#ifndef ROOT_TString -#include "TString.h" -#endif - -class TLM; -class TCondor; -class TTimer; - -class TProofPEAC : public TProof { - -friend class TCondor; - -private: - TString fSession; //PEAC session identifier - TLM *fLM; //connection to PEAC local manager - Int_t fHBPeriod; //requested heartbeat period in seconds - TCondor *fCondor; //condor instance for condor slaves - TTimer *fTimer; //timer for delayed Condor COD suspend - TTimer *fHeartbeatTimer; //timer for sending heartbeat to local manager - -protected: - virtual Bool_t StartSlaves(Bool_t parallel=kTRUE,Bool_t attach=kFALSE); - TString GetJobAd(); - -public: - TProofPEAC(const char *masterurl, const char *sessionid = 0, - const char *confdir = 0, Int_t loglevel = 0, - const char *alias = 0, TProofMgr *mgr = 0); - virtual ~TProofPEAC(); - - virtual Bool_t IsDataReady(Long64_t &totalbytes, Long64_t &bytesready); - virtual void SendHeartbeat(); - virtual void SetActive(Bool_t active = kTRUE); - virtual void Close(Option_t *option=""); - - ClassDef(TProofPEAC,0) // PROOF using PEAC -}; - -#endif diff --git a/proof/peac/inc/TProofStartupDialog.h b/proof/peac/inc/TProofStartupDialog.h deleted file mode 100644 index 6a55e01f6ac46..0000000000000 --- a/proof/peac/inc/TProofStartupDialog.h +++ /dev/null @@ -1,66 +0,0 @@ -// @(#)root/peac:$Id$ -// Author: Maarten Ballintijn 21/10/2004 -// Author: Kris Gulbrandsen 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOT_TProofStartupDialog -#define ROOT_TProofStartupDialog - -////////////////////////////////////////////////////////////////////////// -// // -// TProofStartupDialog // -// // -// This class provides a query progress bar for data being staged. // -// // -////////////////////////////////////////////////////////////////////////// - -#ifndef ROOT_TTime -#include "TTime.h" -#endif - - -class TGTransientFrame; -class TGProgressBar; -class TGTextButton; -class TGCheckButton; -class TGLabel; -class TProof; - - -class TProofStartupDialog { - -private: - TProof *fProof; - TGTransientFrame *fDialog; // transient frame, main dialog window - TGProgressBar *fBar; // progress bar - TGLabel *fFilesBytes; - TGLabel *fStaged; - TGLabel *fTotal; - TGLabel *fRate; - TTime fStartTime; - TTime fEndTime; - Long64_t fPrevStaged; - Int_t fFiles; - Long64_t fTotalBytes; - - -public: - TProofStartupDialog(TProof *proof, const Char_t *dataset, - Int_t nfiles, Long64_t totalbytes); - virtual ~TProofStartupDialog(); - void Progress(Long64_t totalbytes, Long64_t bytesready); - - void CloseWindow(); - void DoClose(); - - ClassDef(TProofStartupDialog,0) // PROOF startup and data staging dialog -}; - -#endif diff --git a/proof/peac/src/TPEAC.cxx b/proof/peac/src/TPEAC.cxx deleted file mode 100644 index 5b79cf37055c2..0000000000000 --- a/proof/peac/src/TPEAC.cxx +++ /dev/null @@ -1,222 +0,0 @@ -// @(#)root/peac:$Id$ -// Author: Maarten Ballintijn 21/10/2004 -// Author: Kris Gulbrandsen 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TPEAC // -// // -// This class implements the setup of a PROOF session using PEAC // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TPEAC.h" - -#include "TClarens.h" -#include "TDSet.h" -#include "TEnv.h" -#include "TGM.h" -#include "TObjString.h" -#include "TPluginManager.h" -#include "TROOT.h" -#include "TSystem.h" -#include "TUrl.h" -#include "TProof.h" - - -namespace { - -//------------------------------------------------------------------------------ - -struct TPEACStartup { - TPEACStartup() {TPEAC::Init();} -} PEACStartup; - -//------------------------------------------------------------------------------ - -}; - - -TPEAC *gPEAC = 0; - -ClassImp(TPEAC) - - -//______________________________________________________________________________ -TPEAC::TPEAC() - : fGM(0), fProof(0) -{ - TClarens::Init(); -} - - -//______________________________________________________________________________ -TPEAC::~TPEAC() -{ - if (!fSessionID.IsNull()) EndSession(); - delete fGM; -} - - -//______________________________________________________________________________ -void TPEAC::Init() -{ - if (gPEAC == 0) { - gPEAC = new TPEAC; - } -} - - -//______________________________________________________________________________ -TDSet *TPEAC::StartSession(const Char_t *dataset) -{ - if (fGM == 0) { - - const Char_t *gmUrl = gEnv->GetValue("PEAC.GmUrl", - "http://localhost:8080/clarens/"); - - fGM = gClarens->CreateGM(gmUrl); - - if (!fGM) { - Error("TPEAC", "Could not get Global Manager for URL: %s", gmUrl); - return 0; - } - } - - if (!fSessionID.IsNull()) { - Error("StartSession", "Session associated with dataset '%s' still open", - fDataSet.Data()); - Error("StartSession", "That session must end before" - " starting a new session"); - return 0; - } - - if (gDebug > 0) fGM->Print(); - - TList* files = 0; - TString sessionid; - TUrl purl(""); - if (!fGM->CreateSession(dataset, sessionid, files, purl)) { - delete fGM; - fGM = 0; - return 0; - } - - // session successfully created - - if (gDebug > 0) { - Info("StartSession", "sessionid = %s @ %s", sessionid.Data(), purl.GetUrl()); - files->Print(); - } - - // construct TDSet - TDSet *dset = 0; - TIter NextFile(files); - while (TGM::TFileParams *fp = dynamic_cast<TGM::TFileParams*>(NextFile())) { - - if (dset == 0) dset = new TDSet(fp->fObjClass, fp->fObjName, fp->fDir); - - dset->Add(fp->fFileName, fp->fObjName, fp->fDir, fp->fFirst, fp->fNum); - } - Int_t nfiles = files->GetSize(); - delete files; - - // save session id - fSessionID = sessionid; - fDataSet = dataset; - - // start proof - fProof = TProof::Open(purl.GetUrl(), Form("peac:%s", sessionid.Data())); - - if (!fProof || !fProof->IsValid()) { - Error("StartSession", "PROOF session could not be started"); - EndSession(); - delete dset; - return 0; - } - - //call EndSession when proof is destroyed - fProof->Connect("~TProof()", "TPEAC", this, "EndSessionCallback()"); - - //wait until data is ready - Long64_t totalbytes, bytesready; - Bool_t dataready = fProof->IsDataReady(totalbytes, bytesready); - - //make a progress bar - either the user deletes it or it deletes itself - if (!gROOT->IsBatch()) { - if (TPluginManager *pm = gROOT->GetPluginManager()) { - if (TPluginHandler *h = pm->FindHandler("TProofStartupDialog")) { - if(h->LoadPlugin() != -1) { - h->ExecPlugin(4, fProof, dataset, nfiles, totalbytes); - //trigger progress atleast once - dataready = fProof->IsDataReady(totalbytes, bytesready); - } - } - } - } - - if (!dataready) { - gSystem->Sleep(500); - while (!fProof->IsDataReady(totalbytes, bytesready)) { - gSystem->Sleep(500); - } - } - - return dset; -} - - -//______________________________________________________________________________ -void TPEAC::EndSessionCallback() -{ - if (fSessionID.IsNull()) { - Error("EndSession", "No session active. Don't call EndSessionCallback() directly"); - return; - } - - if (!fGM) { - Error("EndSession", "Global manager does not exist"); - return; - } - - if (fProof) { - fProof->Disconnect("~TProof()", this, "EndSessionCallback()"); - fProof = 0; - } - fGM->DestroySession(fSessionID); - fSessionID = ""; - fDataSet = ""; - -} - - -//______________________________________________________________________________ -void TPEAC::EndSession() -{ - if (fSessionID.IsNull()) { - Info("EndSession", "No session active"); - return; - } - - if (!fGM) { - Error("EndSession", "Global manager does not exist"); - return; - } - - if (fProof) { - fProof->Disconnect("~TProof()", this, "EndSessionCallback()"); - delete fProof; - fProof = 0; - } - fGM->DestroySession(fSessionID); - fSessionID = ""; - fDataSet = ""; -} diff --git a/proof/peac/src/TProofPEAC.cxx b/proof/peac/src/TProofPEAC.cxx deleted file mode 100644 index 1e57f0922271a..0000000000000 --- a/proof/peac/src/TProofPEAC.cxx +++ /dev/null @@ -1,281 +0,0 @@ -// @(#)root/peac:$Id$ -// Author: Maarten Ballintijn 21/10/2004 -// Author: Kris Gulbrandsen 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TProofPEAC // -// // -// This class implements the setup of a PROOF session using PEAC // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TClarens.h" -#include "TCondor.h" -#include "TDSet.h" -#include "TEnv.h" -#include "TError.h" -#include "TList.h" -#include "TLM.h" -#include "TMonitor.h" -#include "TProofPEAC.h" -#include "TProofServ.h" -#include "TSlave.h" -#include "TSystem.h" -#include "TTimer.h" -#include "TUrl.h" - -ClassImp(TProofPEAC) - - -//______________________________________________________________________________ -TProofPEAC::TProofPEAC(const char *masterurl, const char *sessionid, - const char *confdir, Int_t loglevel, - const char *, TProofMgr *mgr) - : fCondor(0), fTimer(0) -{ - // Start PEAC proof session - - // This may be needed during init - fManager = mgr; - - if (!strncasecmp(sessionid, "peac:", 5)) - sessionid+=5; - - Init(masterurl, sessionid, confdir, loglevel); - -} - -//______________________________________________________________________________ -TProofPEAC::~TProofPEAC() -{ - // Destroy PEAC proof session - - delete fCondor; - delete fTimer; - if (fLM) { - delete fHeartbeatTimer; - fHeartbeatTimer = 0; - fLM->EndSession(fSession); - delete fLM; - fLM = 0; - } - -} - -//------------------------------------------------------------------------------ -Bool_t TProofPEAC::StartSlaves(Bool_t,Bool_t) -{ - - if (IsMaster()) { - - TClarens::Init(); - const Char_t *lmUrl = gEnv->GetValue("PEAC.LmUrl", - "http://localhost:8080/clarens/"); - fLM = gClarens->CreateLM(lmUrl); - if (!fLM) { - Error("StartSlaves", "Could not connect to local manager for url '%s'", - lmUrl); - return kFALSE; - } - - TUrl url(lmUrl); - TString lm = url.GetHost(); - Int_t lmPort = url.GetPort(); - fSession = fConfFile; - - PDB(kGlobal,1) Info("StartSlaves", "PEAC mode: host: %s port: %d session: %s", - lm.Data(), lmPort, fSession.Data()); - - TList* config = 0; - if(!fLM->StartSession(fSession, config, fHBPeriod)) { - Error("StartSlaves", "Could not start session '%s' for local manager '%s'", - fSession.Data(), lmUrl); - return kFALSE; - } - - TList csl; - - TIter NextSlave(config); - Int_t ord = 0; - TString jobad; - while (TLM::TSlaveParams *sp = dynamic_cast<TLM::TSlaveParams*>(NextSlave())) { - - PDB(kGlobal,1) Info("StartSlaves", "node: %s", sp->fNode.Data()); - - // create slave server - - if (sp->fType == "inetd") { - TString fullord = TString(gProofServ->GetOrdinal()) + "." + ((Long_t) ord); - ord++; - TSlave *slave = CreateSlave(sp->fNode, fullord, - sp->fPerfidx, sp->fImg, Form("~/%s", kPROOF_WorkDir)); - fSlaves->Add(slave); - if (slave->IsValid()) { - fAllMonitor->Add(slave->GetSocket()); - PDB(kGlobal,3) - Info("StartSlaves", "slave on host %s created and added to list", - sp->fNode.Data()); - } else { - fBadSlaves->Add(slave); - PDB(kGlobal,3) - Info("StartSlaves", "slave on host %s created and added to list of bad slaves", - sp->fNode.Data()); - } - } else if (sp->fType == "cod") { - if (fCondor == 0) { - fCondor = new TCondor; - jobad = GetJobAd(); - - fImage = fCondor->GetImage(gSystem->HostName()); - if (fImage.Length() == 0) { - Error("StartSlaves", "no image found for node %s", - gSystem->HostName()); - delete fCondor; - fCondor = 0; - } - } - - if (fCondor != 0) { - TCondorSlave *c = fCondor->Claim(sp->fNode, jobad); - - if (c != 0) { - csl.Add(c); - } else { - Info("StartSlaves", "node: %s not claimed", sp->fNode.Data()); - } - } - } else { - Error("StartSlaves", "unknown slave type (%s)", sp->fType.Data()); - } - } - delete config; - - TIter next(&csl); - TCondorSlave *cs; - while ((cs = (TCondorSlave*)next()) != 0) { - // Get slave FQDN ... - TString SlaveFqdn; - TInetAddress SlaveAddr = gSystem->GetHostByName(cs->fHostname); - if (SlaveAddr.IsValid()) - SlaveFqdn = SlaveAddr.GetHostName(); - - // who do we believe for perf & img, Condor for the moment - TString fullord = TString(gProofServ->GetOrdinal()) + "." + ((Long_t) ord); - ord++; - TSlave *slave = CreateSlave(cs->fHostname, fullord, - cs->fPerfIdx, cs->fImage, Form("~/%s", kPROOF_WorkDir)); - - fSlaves->Add(slave); - if (slave->IsValid()) { - fAllMonitor->Add(slave->GetSocket()); - PDB(kGlobal,3) - Info("StartSlaves", "slave on host %s created and added to list (port %d)", - cs->fHostname.Data(),cs->fPort); - } else { - fBadSlaves->Add(slave); - PDB(kGlobal,3) - Info("StartSlaves", "slave on host %s created and added to list of bad slaves (port %d)", - cs->fHostname.Data(),cs->fPort); - } - } - - //create and start heartbeat timer - fHeartbeatTimer = new TTimer; - fHeartbeatTimer->Connect("Timeout()", "TProofPEAC", this, "SendHeartbeat()"); - fHeartbeatTimer->Start(fHBPeriod*1000, kFALSE); - } else { - return TProof::StartSlaves(kTRUE); - } - - return kTRUE; -} - -//______________________________________________________________________________ -void TProofPEAC::Close(Option_t *option) -{ - - TProof::Close(option); - - if (fLM) { - delete fHeartbeatTimer; - fHeartbeatTimer = 0; - fLM->EndSession(fSession); - delete fLM; - fLM = 0; - } - -} - -//______________________________________________________________________________ -void TProofPEAC::SetActive(Bool_t active) -{ - // Suspend or resume PROOF via Condor. - - if (fCondor) { - if (fTimer == 0) { - fTimer = new TTimer(); - } - if (active) { - PDB(kCondor,1) Info("SetActive","-- Condor Resume --"); - fTimer->Stop(); - if (fCondor->GetState() == TCondor::kSuspended) - fCondor->Resume(); - } else { - Int_t delay = 10000; // milli seconds - PDB(kCondor,1) Info("SetActive","-- Delayed Condor Suspend (%d msec) --", delay); - fTimer->Connect("Timeout()", "TCondor", fCondor, "Suspend()"); - fTimer->Start(10000, kTRUE); // single shot - } - } -} - -//______________________________________________________________________________ -TString TProofPEAC::GetJobAd() -{ - TString ad; - - ad = "JobUniverse = 5\n"; // vanilla - ad += Form("Cmd = \"%s/bin/proofd\"\n", GetConfDir()); - ad += "Iwd = \"/tmp\"\n"; - ad += "In = \"/dev/null\"\n"; - ad += "Out = \"/tmp/proofd.out.$(Port)\"\n"; - ad += "Err = \"/tmp/proofd.err.$(Port)\"\n"; - ad += Form("Args = \"-f -p $(Port) -d %d %s\"\n", GetLogLevel(), GetConfDir()); - - return ad; -} - -//______________________________________________________________________________ -Bool_t TProofPEAC::IsDataReady(Long64_t &totalbytes, Long64_t &bytesready) -{ - Bool_t dataready = kFALSE; - if (IsMaster()) { - dataready = fLM ? fLM->DataReady(fSession, bytesready, totalbytes) : kFALSE; - ////// for testing - //static Long64_t total = 10; - //static Long64_t ready = -1; - //ready++; - //totalbytes=total; - //bytesready=ready; - if (totalbytes>bytesready) dataready=kFALSE; - ////// - } else { - dataready = TProof::IsDataReady(totalbytes, bytesready); - } - return dataready; -} - -//______________________________________________________________________________ -void TProofPEAC::SendHeartbeat() -{ - if (fLM) fLM->Heartbeat(fSession); -} diff --git a/proof/peac/src/TProofStartupDialog.cxx b/proof/peac/src/TProofStartupDialog.cxx deleted file mode 100644 index a95a6a8847716..0000000000000 --- a/proof/peac/src/TProofStartupDialog.cxx +++ /dev/null @@ -1,213 +0,0 @@ -// @(#)root/peac:$Id$ -// Author: Maarten Ballintijn 21/10/2004 -// Author: Kris Gulbrandsen 21/10/2004 - -/************************************************************************* - * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -////////////////////////////////////////////////////////////////////////// -// // -// TProofStartupDialog // -// // -// This class provides a query progress bar for data being staged. // -// // -////////////////////////////////////////////////////////////////////////// - -#include "TProofStartupDialog.h" -#include "TGLabel.h" -#include "TGButton.h" -#include "TGProgressBar.h" -#include "TSystem.h" -#include "TTimer.h" -#include "TProof.h" - - -ClassImp(TProofStartupDialog) - -//______________________________________________________________________________ -TProofStartupDialog::TProofStartupDialog(TProof *proof, - const Char_t *dataset, - Int_t nfiles, - Long64_t totalbytes) -{ - // Create data staging progress dialog. - - fProof = proof; - fPrevStaged = 0; - fFiles = nfiles; - fTotalBytes = totalbytes; - - const TGWindow *main = gClient->GetRoot(); - fDialog = new TGTransientFrame(main, main, 10, 10); - fDialog->Connect("CloseWindow()", "TProofStartupDialog", this, "DoClose()"); - fDialog->DontCallClose(); - - // title label - char buf[256]; - sprintf(buf, "Staging files for data set '%s'", dataset); - fDialog->AddFrame(new TGLabel(fDialog, buf), - new TGLayoutHints(kLHintsNormal, 10, 10, 20, 0)); - sprintf(buf, "%d files, number of bytes %lld", fFiles, fTotalBytes); - fFilesBytes = new TGLabel(fDialog, buf); - fDialog->AddFrame(fFilesBytes, new TGLayoutHints(kLHintsNormal, 10, 10, 5, 0)); - - // progress bar - fBar = new TGHProgressBar(fDialog, TGProgressBar::kFancy, 450); - fBar->SetBarColor("green"); - fDialog->AddFrame(fBar, new TGLayoutHints(kLHintsTop | kLHintsLeft | - kLHintsExpandX, 10, 10, 20, 20)); - - // status labels - TGHorizontalFrame *hf1 = new TGHorizontalFrame(fDialog, 0, 0); - TGCompositeFrame *cf1 = new TGCompositeFrame(hf1, 110, 0, kFixedWidth); - fStaged = new TGLabel(cf1, "Estimated time left:"); - cf1->AddFrame(fStaged); - hf1->AddFrame(cf1); - fTotal= new TGLabel(hf1, "- sec (- bytes of - staged)"); - hf1->AddFrame(fTotal, new TGLayoutHints(kLHintsNormal, 10, 10, 0, 0)); - fDialog->AddFrame(hf1, new TGLayoutHints(kLHintsNormal, 10, 10, 5, 0)); - - TGHorizontalFrame *hf2 = new TGHorizontalFrame(fDialog, 0, 0); - TGCompositeFrame *cf2 = new TGCompositeFrame(hf2, 110, 0, kFixedWidth); - cf2->AddFrame(new TGLabel(cf2, "Staging rate:")); - hf2->AddFrame(cf2); - fRate = new TGLabel(hf2, "- bytes/sec"); - hf2->AddFrame(fRate, new TGLayoutHints(kLHintsNormal, 10, 10, 0, 0)); - fDialog->AddFrame(hf2, new TGLayoutHints(kLHintsNormal, 10, 10, 5, 0)); - - // stop and close buttons - TGHorizontalFrame *hf3 = new TGHorizontalFrame(fDialog, 60, 20, kFixedWidth); - - UInt_t nb = 0, width = 0, height = 0; - - // place button frame (hf3) at the bottom - fDialog->AddFrame(hf3, new TGLayoutHints(kLHintsBottom | kLHintsCenterX, 10, 10, 20, 10)); - - // keep buttons centered and with the same width - hf3->Resize((width + 40) * nb, height); - - // connect slot to proof progress signal - if (fProof) - fProof->Connect("IsDataReady(Long64_t,Long64_t)", "TProofStartupDialog", - this, "Progress(Long64_t,Long64_t)"); - - // set dialog title - fDialog->SetWindowName("Data Staging Progress"); - - // map all widgets and calculate size of dialog - fDialog->MapSubwindows(); - - width = fDialog->GetDefaultWidth(); - height = fDialog->GetDefaultHeight(); - - fDialog->Resize(width, height); - - // position relative to the parent window (which is the root window) - Window_t wdum; - int ax, ay; - - gVirtualX->TranslateCoordinates(main->GetId(), main->GetId(), - (((TGFrame *) main)->GetWidth() - width) >> 1, - (((TGFrame *) main)->GetHeight() - height) >> 1, - ax, ay, wdum); - fDialog->Move(ax, ay); - fDialog->SetWMPosition(ax, ay); - - // make the message box non-resizable - fDialog->SetWMSize(width, height); - fDialog->SetWMSizeHints(width, height, width, height, 0, 0); - - fDialog->SetMWMHints(kMWMDecorAll | kMWMDecorResizeH | kMWMDecorMaximize | - kMWMDecorMinimize | kMWMDecorMenu, - kMWMFuncAll | kMWMFuncResize | kMWMFuncMaximize | - kMWMFuncMinimize, - kMWMInputModeless); - - // popup dialog and wait till user replies - fDialog->MapWindow(); - - fStartTime = gSystem->Now(); -} - -//______________________________________________________________________________ -void TProofStartupDialog::Progress(Long64_t totalbytes, Long64_t bytesready) -{ - // Update progress bar and status labels. - - if (fPrevStaged == bytesready) - return; - - char buf[256]; - if (fTotalBytes != totalbytes) { - fTotalBytes = totalbytes; - sprintf(buf, "%d files, number of bytes %lld", fFiles, fTotalBytes); - fFilesBytes->SetText(buf); - } - - Float_t pos = Float_t(Double_t(bytesready * 100)/Double_t(totalbytes)); - fBar->SetPosition(pos); - - // get current time - fEndTime = gSystem->Now(); - TTime tdiff = fEndTime - fStartTime; - Float_t eta = 0; - if (bytesready) - eta = ((Float_t)((Long_t)tdiff)*totalbytes/Float_t(bytesready) - Long_t(tdiff))/1000.; - - if (bytesready == totalbytes) { - fStaged->SetText("Staged:"); - sprintf(buf, "%lld bytes in %.1f sec", totalbytes, Long_t(tdiff)/1000.); - fTotal->SetText(buf); - - if (fProof) { - fProof->Disconnect("IsDataReady(Long64_t,Long64_t)", this, - "Progress(Long64_t,Long64_t)"); - fProof = 0; - } - - DoClose(); - } else { - sprintf(buf, "%.1f sec (%lld bytes of %lld staged)", eta, bytesready, - totalbytes); - fTotal->SetText(buf); - sprintf(buf, "%.1f bytes/sec", Float_t(bytesready)/Long_t(tdiff)*1000.); - fRate->SetText(buf); - } - fPrevStaged = bytesready; - - fDialog->Layout(); -} - -//______________________________________________________________________________ -TProofStartupDialog::~TProofStartupDialog() -{ - // Cleanup dialog. - - if (fProof) - fProof->Disconnect("IsDataReady(Long64_t,Long64_t)", this, - "Progress(Long64_t,Long64_t)"); - - fDialog->Cleanup(); - delete fDialog; -} - -//______________________________________________________________________________ -void TProofStartupDialog::CloseWindow() -{ - // Called when dialog is closed. - - delete this; -} - -//______________________________________________________________________________ -void TProofStartupDialog::DoClose() -{ - // Close dialog. - - TTimer::SingleShot(500, "TProofStartupDialog", this, "CloseWindow()"); -} diff --git a/proof/pq2/src/pq2wrappers.cxx b/proof/pq2/src/pq2wrappers.cxx index a53601e36ae6b..2a4354c232971 100644 --- a/proof/pq2/src/pq2wrappers.cxx +++ b/proof/pq2/src/pq2wrappers.cxx @@ -38,6 +38,9 @@ extern TString ferr; extern TString fres; extern Int_t gverbose; +// How to start PROOF (new VerifyDataSet wants it parallel) +static bool doParallel = kFALSE; + Int_t getProof(const char *where, Int_t verbose = 1); Int_t getDSMgr(const char *where); @@ -46,6 +49,7 @@ void DataSetCache(bool clear, const char *ds) { // ShowCache wrapper if (gIsProof) { + doParallel = kFALSE; if (!gProof && getProof("DataSetCache", 0) != 0) return; return (clear ? gProof->ClearDataSetCache(ds) : gProof->ShowDataSetCache(ds)); } else { @@ -64,6 +68,7 @@ void ShowDataSets(const char *ds, const char *opt) { // ShowDataSets wrapper if (gIsProof) { + doParallel = kFALSE; if (!gProof && getProof("ShowDataSets", 0) != 0) return; return gProof->ShowDataSets(ds, opt); } else { @@ -80,6 +85,7 @@ TFileCollection *GetDataSet(const char *ds, const char *server) // GetDataSet wrapper TFileCollection *fc = 0; if (gIsProof) { + doParallel = kFALSE; if (!gProof && getProof("GetDataSet") != 0) return fc; return gProof->GetDataSet(ds, server); } else { @@ -96,6 +102,7 @@ TMap *GetDataSets(const char *owner, const char *server, const char *opt) // GetDataSets wrapper TMap *dss = 0; if (gIsProof) { + doParallel = kFALSE; if (!gProof && getProof("GetDataSets") != 0) return dss; return gProof->GetDataSets(owner, server); } else { @@ -141,6 +148,7 @@ Int_t RemoveDataSet(const char *dsname) { // RemoveDataSet wrapper if (gIsProof) { + doParallel = kFALSE; if (!gProof && getProof("RemoveDataSet") != 0) return -1; return gProof->RemoveDataSet(dsname); } else { @@ -165,6 +173,13 @@ Int_t VerifyDataSet(const char *dsname, const char *opt, const char *redir) if (!(srvmaps.IsNull())) { TProof::AddEnvVar("DATASETSRVMAPS", srvmaps); } + TString sopt(opt); + doParallel = (sopt.Contains("S")) ? kFALSE : kTRUE; + if (gProof && doParallel && gProof->GetParallel() == 0) { + gProof->Close(); + delete gProof; + gProof = 0; + } if (!gProof && getProof("VerifyDataSet") != 0) return -1; if ((rc = gProof->VerifyDataSet(dsname, opt)) == 0) { // Success; partial at least. Check if all files are staged @@ -192,6 +207,7 @@ Bool_t ExistsDataSet(const char *dsname) { // ExistsDataSet wrapper if (gIsProof) { + doParallel = kFALSE; if (!gProof && getProof("ExistsDataSet") != 0) return kFALSE; return gProof->ExistsDataSet(dsname); } else { @@ -206,6 +222,7 @@ Int_t RegisterDataSet(const char *dsname, TFileCollection *fc, const char* opt) { // RegisterDataSet wrapper if (gIsProof) { + doParallel = kFALSE; if (!gProof && getProof("GetDataSet") != 0) return -1; return gProof->RegisterDataSet(dsname, fc, opt); } else { @@ -221,7 +238,8 @@ Int_t getProof(const char *where, Int_t verbose) // Open a PROOF session at gUrl { redirguard rog(flog.Data(), "a", verbose); - TProof::Open(gUrl.GetUrl(), "masteronly"); + const char *popt = (doParallel) ? "" : "masteronly"; + TProof::Open(gUrl.GetUrl(), popt); } if (!gProof || !gProof->IsValid()) { Printf("getProof:%s: problems starting a PROOF session at '%s'", where, gUrl.GetUrl()); diff --git a/proof/proof/CMakeLists.txt b/proof/proof/CMakeLists.txt index c295af94769f6..15bfb451f6eeb 100644 --- a/proof/proof/CMakeLists.txt +++ b/proof/proof/CMakeLists.txt @@ -9,11 +9,26 @@ ROOT_USE_PACKAGE(io/io) ROOT_USE_PACKAGE(core/thread) include_directories(${CMAKE_SOURCE_DIR}/proof/proofplayer/inc) # To avoid circular dependencies :-( +ROOT_GLOB_HEADERS(headers RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}/inc inc/*.h) +ROOT_GLOB_SOURCES(sources RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}/src src/*.cxx) + +#--- AliEn Dataset manager only if AliEn is available +if(alien) + add_definitions(-DALIENDSMGR) +else() + list(REMOVE_ITEM headers TDataSetManagerAliEn.h) + list(REMOVE_ITEM sources TDataSetManagerAliEn.cxx) +endif() + #--- if gcc 4.5.2 on Linux (Debian) use -O instead of -O2 (compiler bug) if(ROOT_PLATFORM MATCHES "linux" AND CMAKE_COMPILER_IS_GNUCXX AND GCC_VERSION VERSION_GREATER 4.5 AND GCC_VERSION VERSION_LESS 4.6) set_source_files_properties(src/TDataSetManager.cxx src/TDSet PROPERTIES COMPILE_FLAGS "-O") endif() -ROOT_STANDARD_LIBRARY_PACKAGE(Proof DEPENDENCIES Net Tree Thread RIO MathCore) +ROOT_GENERATE_DICTIONARY(G__Proof ${headers} LINKDEF LinkDef.h) +ROOT_GENERATE_ROOTMAP(Proof LINKDEF LinkDef.h DEPENDENCIES Net Tree Thread RIO MathCore) +ROOT_LINKER_LIBRARY(Proof ${sources} G__Proof.cxx DEPENDENCIES Net Tree Thread RIO MathCore) +ROOT_INSTALL_HEADERS() + diff --git a/proof/proof/Module.mk b/proof/proof/Module.mk index 6886269859364..9ca5ca6719e76 100644 --- a/proof/proof/Module.mk +++ b/proof/proof/Module.mk @@ -18,10 +18,20 @@ PROOFDS := $(call stripsrc,$(MODDIRS)/G__Proof.cxx) PROOFDO := $(PROOFDS:.cxx=.o) PROOFDH := $(PROOFDS:.cxx=.h) -PROOFH := $(filter-out $(MODDIRI)/LinkDef%,$(wildcard $(MODDIRI)/*.h)) -PROOFS := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx)) -PROOFO := $(call stripsrc,$(PROOFS:.cxx=.o)) +PROOFH_ALL := $(filter-out $(MODDIRI)/LinkDef%,$(wildcard $(MODDIRI)/*.h)) +PROOFS_ALL := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx)) + +# Build AliEn dataset manager only when AliEn is enabled +ifeq ($(BUILDALIEN),yes) + ALIENDSMGR := -DALIENDSMGR + PROOFH := $(PROOFH_ALL) + PROOFS := $(PROOFS_ALL) +else + PROOFS := $(filter-out $(MODDIRS)/TDataSetManagerAliEn%,$(PROOFS_ALL)) + PROOFH := $(filter-out $(MODDIRI)TDataSetManagerAliEn%,$(PROOFH_ALL)) +endif +PROOFO := $(call stripsrc,$(PROOFS:.cxx=.o)) PROOFDEP := $(PROOFO:.o=.d) $(PROOFDO:.o=.d) PROOFLIB := $(LPATH)/libProof.$(SOEXT) @@ -49,7 +59,7 @@ $(PROOFLIB): $(PROOFO) $(PROOFDO) $(ORDER_) $(MAINLIBS) $(PROOFLIBDEP) $(PROOFDS): $(PROOFH) $(PROOFL) $(ROOTCINTTMPDEP) $(MAKEDIR) @echo "Generating dictionary $@..." - $(ROOTCINTTMP) -f $@ -c $(PROOFH) $(PROOFL) + $(ROOTCINTTMP) -f $@ -c $(ALIENDSMGR) $(PROOFH) $(PROOFL) $(PROOFMAP): $(RLIBMAP) $(MAKEFILEDEP) $(PROOFL) $(RLIBMAP) -o $@ -l $(PROOFLIB) \ diff --git a/proof/proof/inc/LinkDef.h b/proof/proof/inc/LinkDef.h index 28657c356f033..20b1cc987edc0 100644 --- a/proof/proof/inc/LinkDef.h +++ b/proof/proof/inc/LinkDef.h @@ -53,9 +53,17 @@ #pragma link C++ class TMergerInfo; #pragma link C++ class TProofProgressInfo; #pragma link C++ class TProofOutputList+; +#pragma link C++ class TProofOutputFile+; #pragma link C++ class TDataSetManager; #pragma link C++ class TDataSetManagerFile; + +// Dictionary for TDataSetManagerAliEn only if requested +#ifdef ALIENDSMGR +#pragma link C++ class TDataSetManagerAliEn; +#pragma link C++ class TAliEnFind; +#endif + #pragma link C++ class TSelVerifyDataSet+; // For backward compatibility with old client / masters diff --git a/proof/proof/inc/TDSet.h b/proof/proof/inc/TDSet.h index ebc371798f311..a824e8150dc9d 100644 --- a/proof/proof/inc/TDSet.h +++ b/proof/proof/inc/TDSet.h @@ -93,6 +93,7 @@ class TDSetElement : public TNamed { TString fDataSet; // Name of the dataset of which this element is part TList *fAssocObjList; // List of objects associated to this element // (e.g. TObjString describing associated files) + Float_t fMaxProcTime; // Max processing time in secs; -1 no limit Bool_t HasBeenLookedUp() const { return TestBit(kHasBeenLookedUp); } @@ -140,9 +141,12 @@ class TDSetElement : public TNamed { void SetLookedUp() { SetBit(kHasBeenLookedUp); } TFileInfo *GetFileInfo(const char *type = "TTree"); + Float_t GetMaxProcTime() const { return fMaxProcTime; } + void SetMaxProcTime(Float_t mpt) { fMaxProcTime = mpt; } + Int_t MergeElement(TDSetElement *elem); - ClassDef(TDSetElement,8) // A TDSet element + ClassDef(TDSetElement,9) // A TDSet element }; diff --git a/proof/proof/inc/TDataSetManagerAliEn.h b/proof/proof/inc/TDataSetManagerAliEn.h new file mode 100644 index 0000000000000..dc6213013b2ba --- /dev/null +++ b/proof/proof/inc/TDataSetManagerAliEn.h @@ -0,0 +1,145 @@ +// @(#)root/proof:$Id: 511148a2a899e02c8f5b86a7d87caee2e5979f9d $ +// Author: Dario Berzano, 26.11.12 + +/************************************************************************* + * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TDataSetManagerAliEn +#define ROOT_TDataSetManagerAliEn + +////////////////////////////////////////////////////////////////////////// +// // +// TDataSetManagerAliEn // +// // +// Implementation of TDataSetManager dynamically creating datasets // +// by querying the AliEn file catalog. // +// // +////////////////////////////////////////////////////////////////////////// + +#ifndef ROOT_TDataSetManager +#include "TDataSetManager.h" +#endif + +#ifndef ROOT_TDataSetManagerFile +#include "TDataSetManagerFile.h" +#endif + +#include "TFileStager.h" +#include "TPRegexp.h" +#include "TObjString.h" +#include "TObjArray.h" +#include "TFileCollection.h" +#include "TFileInfo.h" +#include "TGridResult.h" +#include "TGrid.h" +#include "THashList.h" +#include "TSystem.h" + +typedef enum { kDataRemote, kDataCache, kDataLocal } EDataMode; + +class TAliEnFind : public TObject { + + private: + + TString fBasePath; + TString fFileName; + TString fTreeName; + TString fRegexpRaw; + TString fAnchor; + Bool_t fArchSubst; + TPMERegexp *fRegexp; + TString fSearchId; + TGridResult *fGridResult; + + inline virtual void InvalidateSearchId(); + inline virtual void InvalidateGridResult(); + + public: + + TAliEnFind(const TString &basePath = "", const TString &fileName = "", + const TString &anchor = "", const Bool_t archSubst = kFALSE, + const TString &treeName = "", const TString ®exp = ""); + + TAliEnFind(const TAliEnFind &src); + TAliEnFind &operator=(const TAliEnFind &rhs); + + virtual ~TAliEnFind(); + + virtual TGridResult *GetGridResult(Bool_t forceNewQuery = kFALSE); + + virtual const TString &GetBasePath() const { return fBasePath; }; + virtual const TString &GetFileName() const { return fFileName; }; + virtual const TString &GetAnchor() const { return fAnchor; }; + virtual const TString &GetTreeName() const { return fTreeName; }; + virtual Bool_t GetArchSubst() const { return fArchSubst; }; + virtual const TPMERegexp *GetRegexp() const { return fRegexp; }; + + virtual void SetBasePath(const char *basePath); + virtual void SetFileName(const char *fileName); + virtual void SetAnchor(const char *anchor); + virtual void SetTreeName(const char *fileName); + virtual void SetArchSubst(Bool_t archSubst); + virtual void SetRegexp(const char *regexp); + + virtual const char *GetSearchId(); + virtual TFileCollection *GetCollection(Bool_t forceNewQuery = kFALSE); + virtual void Print(Option_t* opt = "") const; + + ClassDef(TAliEnFind, 0); // Interface to the AliEn find command + +}; + +class TDataSetManagerAliEn : public TDataSetManager { + + protected: + + TPMERegexp *fUrlRe; + TString fUrlTpl; + TDataSetManagerFile *fCache; + Long_t fCacheExpire_s; + + static std::vector<Int_t> *ExpandRunSpec(TString &runSpec); + + static Bool_t ParseCustomFindUri(TString &uri, TString &basePath, + TString &fileName, TString &anchor, TString &treeName, + TString ®exp); + + static Bool_t ParseOfficialDataUri(TString &uri, Bool_t sim, + TString &period, Int_t &year, std::vector<Int_t> *&runList, + Bool_t &esd, Int_t &aodNum, TString &pass); + + virtual void Init(TString cacheDir, TString urlTpl, + ULong_t cacheExpire_s); + + virtual TList *GetFindCommandsFromUri(TString &uri, EDataMode &dataMode, Bool_t &forceUpdate); + + public: + + TDataSetManagerAliEn() : TDataSetManager(0, 0, 0) {} + TDataSetManagerAliEn(const char *cacheDir, const char *urlTpl, + ULong_t cacheExpire_s); + TDataSetManagerAliEn(const char *, const char *, const char *cfgStr); + + virtual ~TDataSetManagerAliEn(); + virtual TFileCollection *GetDataSet(const char *uri, const char * = 0); + virtual Bool_t ExistsDataSet(const char *uri); + + // Not implemented functionalities + virtual Int_t RegisterDataSet(const char *, TFileCollection *, + const char *); + virtual TMap *GetDataSets(const char *, UInt_t); + virtual void ShowDataSets(const char * = "*", const char * = ""); + virtual Bool_t RemoveDataSet(const char *uri); + virtual Int_t ScanDataSet(const char *, UInt_t); + virtual Int_t ShowCache(const char *); + virtual Int_t ClearCache(const char *); + + ClassDef(TDataSetManagerAliEn, 0) // Dataset to AliEn catalog interface +}; + +#endif diff --git a/proof/proof/inc/TDataSetManagerFile.h b/proof/proof/inc/TDataSetManagerFile.h index 75f56afa95d72..554604cb0a8a5 100644 --- a/proof/proof/inc/TDataSetManagerFile.h +++ b/proof/proof/inc/TDataSetManagerFile.h @@ -14,9 +14,9 @@ ////////////////////////////////////////////////////////////////////////// // // -// TDataSetManagerFile // +// TDataSetManagerFile // // // -// Implementation of TDataSetManager handling datasets from root // +// Implementation of TDataSetManager handling datasets from root // // files under a specific directory path // // // ////////////////////////////////////////////////////////////////////////// @@ -42,6 +42,7 @@ class TDataSetManagerFile : public TDataSetManager { Bool_t fUseCache; // True if the cache is used for browsing remote repositories TString fLocalCacheDir; // Local cache when the repository is remote Int_t fCacheUpdatePeriod; // Period for checking for new updated information + Bool_t fOpenPerms; // True if file permissions must be open // Local cache handling void InitLocalCache(); @@ -96,6 +97,7 @@ class TDataSetManagerFile : public TDataSetManager { const char *GetStageOpts() const { return fStageOpts; } Int_t WriteDataSet(const char *group, const char *user, const char *dsName, TFileCollection *dataset, UInt_t option = 0, TMD5 *checksum = 0); + Long_t GetModTime(const char *uri); ClassDef(TDataSetManagerFile, 0) // DataSet manager for files }; diff --git a/proof/proof/inc/TProof.h b/proof/proof/inc/TProof.h index 448f491394d42..43a01d5dcc71f 100644 --- a/proof/proof/inc/TProof.h +++ b/proof/proof/inc/TProof.h @@ -33,6 +33,9 @@ #ifndef ROOT_TString #include "TString.h" #endif +#ifndef ROOT_TMacro +#include "TMacro.h" +#endif #ifndef ROOT_MessageTypes #include "MessageTypes.h" #endif @@ -94,6 +97,7 @@ class TVirtualMutex; class TFileCollection; class TMap; class TDataSetManager; +class TDataSetManagerFile; class TMacro; class TSelector; @@ -133,9 +137,11 @@ class TSelector; // 31 -> 32: New log path trasmission // 32 -> 33: Development cycle 5.29/04 (fixed worker activation, new startup technology, ...) // 33 -> 34: Development cycle 5.33/02 (fix load issue, ...) +// 34 -> 35: Development cycle 5.99/01 (PLite on workers, staging requests in separate dsmgr...) +// 35 -> 36: SetParallel in dynamic mode (changes default in GoParallel), cancel staging requests // PROOF magic constants -const Int_t kPROOF_Protocol = 34; // protocol version number +const Int_t kPROOF_Protocol = 36; // protocol version number const Int_t kPROOF_Port = 1093; // IANA registered PROOF port const char* const kPROOF_ConfFile = "proof.conf"; // default config file const char* const kPROOF_ConfDir = "/usr/local/root"; // default config dir @@ -153,6 +159,7 @@ const char* const kPROOF_TerminateWorker = "+++ terminating +++"; // signal work const char* const kPROOF_WorkerIdleTO = "+++ idle-timeout +++"; // signal worker idle timeout in MarkBad const char* const kPROOF_InputDataFile = "inputdata.root"; // Default input data file name const char* const kPROOF_MissingFiles = "MissingFiles"; // Missingfile list name +const Long64_t kPROOF_DynWrkPollInt_s = 10; // minimum number of seconds between two polls for dyn wrks #ifndef R__WIN32 const char* const kCP = "/bin/cp -fp"; @@ -252,10 +259,12 @@ class TSlaveInfo : public TObject { SysInfo_t GetSysInfo() const { return fSysInfo; } void SetStatus(ESlaveStatus stat) { fStatus = stat; } void SetSysInfo(SysInfo_t si); + void SetOrdinal(const char *ord) { fOrdinal = ord; } Int_t Compare(const TObject *obj) const; Bool_t IsSortable() const { return kTRUE; } void Print(Option_t *option="") const; + Bool_t IsEqual(const TObject* obj) const; ClassDef(TSlaveInfo,4) //basic info on workers }; @@ -307,18 +316,22 @@ class TMergerInfo : public TObject { ClassDef(TMergerInfo,0) // Basic info on merger, i.e. worker serving as merger }; -// Small auxilliary class for merging progress notification +// Small auxiliary class for merging progress notification class TProofMergePrg { private: TString fExp; Int_t fIdx; Int_t fNWrks; + Int_t fLastNWrks; static char fgCr[4]; public: - TProofMergePrg() : fExp(), fIdx(-1), fNWrks(-1) { } + TProofMergePrg() : fExp(), fIdx(-1), fNWrks(-1), fLastNWrks(-1) { } - const char *Export() { fExp.Form("%c (%d workers still sending) ", fgCr[fIdx], fNWrks); - return fExp.Data(); } + const char *Export(Bool_t &changed) { + fExp.Form("%c (%d workers still sending) ", fgCr[fIdx], fNWrks); + changed = (fLastNWrks != fNWrks || fLastNWrks == -1) ? kTRUE : kFALSE; + fLastNWrks = fNWrks; + return fExp.Data(); } void DecreaseNWrks() { fNWrks--; } void IncreaseNWrks() { fNWrks++; } void IncreaseIdx() { fIdx++; if (fIdx == 4) fIdx = 0; } @@ -451,7 +464,10 @@ friend class TXProofServ; // to access EUrgent kGetQuota = 10, //Get quota info per group kShowQuota = 11, //Show quotas kSetDefaultTreeName = 12, //Set the default tree name - kCache = 13 //Show/clear cache + kCache = 13, //Show/clear cache + kRequestStaging = 14, //Request staging of a dataset + kStagingStatus = 15, //Obtain staging status for the given dataset + kCancelStaging = 16 //Cancels dataset staging request }; enum ESendFileOpt { kAscii = 0x0, @@ -471,12 +487,18 @@ friend class TXProofServ; // to access EUrgent kBuildAll = 0, kCollectBuildResults = 1 }; + enum EParCheckVersionOpt { + kDontCheck = 0, + kCheckROOT = 1, + kCheckSVN = 2 + }; enum EProofShowQuotaOpt { kPerGroup = 0x1, kPerUser = 0x2 }; Bool_t fValid; //is this a valid proof object + Bool_t fTty; //TRUE if connected to a terminal TString fMaster; //master server ("" if a master); used in the browser TString fWorkDir; //current work directory on remote servers TString fGroup; //PROOF group of this user @@ -486,7 +508,11 @@ friend class TXProofServ; // to access EUrgent TList *fRecvMessages; //Messages received during collect not yet processed TList *fSlaveInfo; //!list returned by kPROOF_GETSLAVEINFO Bool_t fSendGroupView; //if true send new group view + Bool_t fIsPollingWorkers; //will be set to kFALSE to prevent recursive dyn workers check in dyn mode + Long64_t fLastPollWorkers_s; //timestamp (in seconds) of last poll for workers, -1 if never checked TList *fActiveSlaves; //list of active slaves (subset of all slaves) + TString fActiveSlavesSaved;// comma-separated list of active slaves (before last call to + // SetParallel or Activate/DeactivateWorkers) TList *fInactiveSlaves; //list of inactive slaves (good but not used for processing) TList *fUniqueSlaves; //list of all active slaves with unique file systems TList *fAllUniqueSlaves; //list of all active slaves with unique file systems, including all submasters @@ -522,6 +548,9 @@ friend class TXProofServ; // to access EUrgent FILE *fLogFileW; //temp file to redirect logs FILE *fLogFileR; //temp file to read redirected logs Bool_t fLogToWindowOnly; //send log to window only + + Bool_t fSaveLogToMacro; // Whether to save received logs to TMacro fMacroLog (use with care) + TMacro fMacroLog; // Macro with the saved (last) log TProofMergePrg fMergePrg; //Merging progress @@ -564,6 +593,8 @@ friend class TXProofServ; // to access EUrgent Int_t fRedirectNext; TString fPerfTree; // If non-null triggers saving of the performance info into fPerfTree + + TList *fWrksOutputReady; // List of workers ready to send output (in control output sending mode) static TPluginHandler *fgLogViewer; // Log dialog box plugin @@ -577,6 +608,7 @@ friend class TXProofServ; // to access EUrgent TString fImage; //master's image name Int_t fProtocol; //remote PROOF server protocol version number TList *fSlaves; //list of all slave servers as in config file + TList *fTerminatedSlaveInfos; //list of unique infos of terminated slaves TList *fBadSlaves; //dead slaves (subset of all slaves) TMonitor *fAllMonitor; //monitor activity on all valid slave sockets Bool_t fDataReady; //true if data is ready to be analyzed @@ -617,12 +649,13 @@ friend class TXProofServ; // to access EUrgent void AskStatistics(); void AskParallel(); Int_t GoParallel(Int_t nodes, Bool_t accept = kFALSE, Bool_t random = kFALSE); + Int_t GoMoreParallel(Int_t nWorkersToAdd); Int_t SetParallelSilent(Int_t nodes, Bool_t random = kFALSE); void RecvLogFile(TSocket *s, Int_t size); void NotifyLogMsg(const char *msg, const char *sfx = "\n"); - Int_t BuildPackage(const char *package, EBuildPackageOpt opt = kBuildAll); - Int_t BuildPackageOnClient(const char *package, Int_t opt = 0, TString *path = 0); - Int_t LoadPackage(const char *package, Bool_t notOnClient = kFALSE, TList *loadopts = 0); + Int_t BuildPackage(const char *package, EBuildPackageOpt opt = kBuildAll, Int_t chkveropt = 2); + Int_t BuildPackageOnClient(const char *package, Int_t opt = 0, TString *path = 0, Int_t chkveropt = 2); + Int_t LoadPackage(const char *package, Bool_t notOnClient = kFALSE, TList *loadopts = 0, TList *workers = 0); Int_t LoadPackageOnClient(const char *package, TList *loadopts = 0); Int_t UnloadPackage(const char *package); Int_t UnloadPackageOnClient(const char *package); @@ -653,6 +686,7 @@ friend class TXProofServ; // to access EUrgent Int_t HandleInputMessage(TSlave *wrk, TMessage *m, Bool_t deactonfail = kFALSE); void HandleSubmerger(TMessage *mess, TSlave *sl); void SetMonitor(TMonitor *mon = 0, Bool_t on = kTRUE); + Int_t PollForNewWorkers(); void ReleaseMonitor(TMonitor *mon); @@ -669,7 +703,9 @@ friend class TXProofServ; // to access EUrgent Int_t GetNumberOfBadSlaves() const; Bool_t IsEndMaster() const { return fEndMaster; } - Int_t ModifyWorkerLists(const char *ord, Bool_t add); + Int_t ModifyWorkerLists(const char *ord, Bool_t add, Bool_t save); + void RestoreActiveList(); + void SaveActiveList(); Bool_t IsSync() const { return fSync; } void InterruptCurrentMonitor(); @@ -737,6 +773,8 @@ friend class TXProofServ; // to access EUrgent void SetDSet(TDSet *dset) { fDSet = dset; } virtual void ValidateDSet(TDSet *dset); + + Int_t VerifyDataSetParallel(const char *uri, const char *optStr); TPluginHandler *GetProgressDialog() const { return fProgressDialog; } @@ -750,6 +788,8 @@ friend class TXProofServ; // to access EUrgent // Fast enable/disable feedback from Process void SetFeedback(TString &opt, TString &optfb, Int_t action); + // Output file handling during Process + Int_t HandleOutputOptions(TString &opt, TString &target, Int_t action); static void *SlaveStartupThread(void *arg); @@ -777,6 +817,12 @@ friend class TXProofServ; // to access EUrgent Int_t Ping(); void Touch(); Int_t Exec(const char *cmd, Bool_t plusMaster = kFALSE); + Int_t Exec(const char *cmd, const char *ord, Bool_t logtomacro = kFALSE); + + TString Getenv(const char *env, const char *ord = "0"); + Int_t GetRC(const char *RCenv, Int_t &env, const char *ord = "0"); + Int_t GetRC(const char *RCenv, Double_t &env, const char *ord = "0"); + Int_t GetRC(const char *RCenv, TString &env, const char *ord = "0"); virtual Long64_t Process(TDSet *dset, const char *selector, Option_t *option = "", Long64_t nentries = -1, @@ -825,7 +871,10 @@ friend class TXProofServ; // to access EUrgent void StopProcess(Bool_t abort, Int_t timeout = -1); void Browse(TBrowser *b); - Int_t SetParallel(Int_t nodes = 9999, Bool_t random = kFALSE); + virtual Int_t Echo(const TObject *obj); + virtual Int_t Echo(const char *str); + + Int_t SetParallel(Int_t nodes = -1, Bool_t random = kFALSE); void SetLogLevel(Int_t level, UInt_t mask = TProofDebug::kAll); void Close(Option_t *option=""); @@ -841,17 +890,17 @@ friend class TXProofServ; // to access EUrgent Int_t ClearPackages(); Int_t ClearPackage(const char *package); Int_t DownloadPackage(const char *par, const char *dstdir = 0); - Int_t EnablePackage(const char *package, Bool_t notOnClient = kFALSE); + Int_t EnablePackage(const char *package, Bool_t notOnClient = kFALSE, TList *workers = 0); Int_t EnablePackage(const char *package, const char *loadopts, - Bool_t notOnClient = kFALSE); + Bool_t notOnClient = kFALSE, TList *workers = 0); Int_t EnablePackage(const char *package, TList *loadopts, - Bool_t notOnClient = kFALSE); - Int_t UploadPackage(const char *par, EUploadPackageOpt opt = kUntar); + Bool_t notOnClient = kFALSE, TList *workers = 0); + Int_t UploadPackage(const char *par, EUploadPackageOpt opt = kUntar, TList *workers = 0); virtual Int_t Load(const char *macro, Bool_t notOnClient = kFALSE, Bool_t uniqueOnly = kTRUE, TList *wrks = 0); - Int_t AddDynamicPath(const char *libpath, Bool_t onClient = kFALSE, TList *wrks = 0); - Int_t AddIncludePath(const char *incpath, Bool_t onClient = kFALSE, TList *wrks = 0); + Int_t AddDynamicPath(const char *libpath, Bool_t onClient = kFALSE, TList *wrks = 0, Bool_t doCollect = kTRUE); + Int_t AddIncludePath(const char *incpath, Bool_t onClient = kFALSE, TList *wrks = 0, Bool_t doCollect = kTRUE); Int_t RemoveDynamicPath(const char *libpath, Bool_t onClient = kFALSE); Int_t RemoveIncludePath(const char *incpath, Bool_t onClient = kFALSE); @@ -868,18 +917,22 @@ friend class TXProofServ; // to access EUrgent void ShowDataSetQuota(Option_t* opt = 0); virtual Bool_t ExistsDataSet(const char *dataset); - void ShowDataSet(const char *dataset = "", const char* opt = "M"); + void ShowDataSet(const char *dataset = "", const char* opt = "filter:SsCc"); virtual Int_t RemoveDataSet(const char *dataset, const char* optStr = ""); virtual Int_t VerifyDataSet(const char *dataset, const char* optStr = ""); virtual TFileCollection *GetDataSet(const char *dataset, const char* optStr = ""); TList *FindDataSets(const char *searchString, const char* optStr = ""); + virtual Bool_t RequestStagingDataSet(const char *dataset); + virtual TFileCollection *GetStagingStatusDataSet(const char *dataset); + virtual void ShowStagingStatusDataSet(const char *dataset, const char *optStr = "filter:SsCc"); + virtual Bool_t CancelStagingDataSet(const char *dataset); virtual Int_t SetDataSetTreeName( const char *dataset, const char *treename); virtual void ShowDataSetCache(const char *dataset = 0); virtual void ClearDataSetCache(const char *dataset = 0); - void ShowData(); + virtual void ShowData(); void ClearData(UInt_t what = kUnregistered, const char *dsname = 0); const char *GetMaster() const { return fMaster; } @@ -912,11 +965,12 @@ friend class TXProofServ; // to access EUrgent Float_t GetRealTime() const { return fRealTime; } Float_t GetCpuTime() const { return fCpuTime; } - Bool_t IsLite() const { return (fServType == TProofMgr::kProofLite); } - Bool_t IsProofd() const { return (fServType == TProofMgr::kProofd); } + Bool_t IsLite() const { return (fServType == TProofMgr::kProofLite) ? kTRUE : kFALSE; } + Bool_t IsProofd() const { return (fServType == TProofMgr::kProofd) ? kTRUE : kFALSE; } Bool_t IsFolder() const { return kTRUE; } Bool_t IsMaster() const { return fMasterServ; } Bool_t IsValid() const { return fValid; } + Bool_t IsTty() const { return fTty; } Bool_t IsParallel() const { return GetParallel() > 0 ? kTRUE : kFALSE; } Bool_t IsIdle() const { return (fNotIdle <= 0) ? kTRUE : kFALSE; } Bool_t IsWaiting() const { return fIsWaiting; } @@ -939,6 +993,7 @@ friend class TXProofServ; // to access EUrgent TList *GetInputList(); TObject *GetOutput(const char *name); TList *GetOutputList(); + static TObject *GetOutput(const char *name, TList *out); void ShowMissingFiles(TQueryResult *qr = 0); TFileCollection *GetMissingFiles(TQueryResult *qr = 0); @@ -995,6 +1050,8 @@ friend class TXProofServ; // to access EUrgent void ShowLog(const char *queryref); Bool_t SendingLogToWindow() const { return fLogToWindowOnly; } void SendLogToWindow(Bool_t mode) { fLogToWindowOnly = mode; } + + TMacro *GetMacroLog() { return &fMacroLog; } void ResetProgressDialogStatus() { fProgressDialogStarted = kFALSE; } @@ -1015,8 +1072,8 @@ friend class TXProofServ; // to access EUrgent TProofMgr *GetManager() { return fManager; } void SetManager(TProofMgr *mgr); - Int_t ActivateWorker(const char *ord); - Int_t DeactivateWorker(const char *ord); + Int_t ActivateWorker(const char *ord, Bool_t save = kTRUE); + Int_t DeactivateWorker(const char *ord, Bool_t save = kTRUE); const char *GetDataPoolUrl() const { return fManager ? fManager->GetMssUrl() : 0; } void SetDataPoolUrl(const char *url) { if (fManager) fManager->SetMssUrl(url); } diff --git a/proof/proof/inc/TProofLite.h b/proof/proof/inc/TProofLite.h index 8550d740b3da0..f8d6a23412c37 100644 --- a/proof/proof/inc/TProofLite.h +++ b/proof/proof/inc/TProofLite.h @@ -72,10 +72,11 @@ friend class TProofPlayerLite; void NotifyStartUp(const char *action, Int_t done, Int_t tot); Int_t SetProofServEnv(const char *ord); Int_t InitDataSetManager(); - Int_t RegisterDataSets(TList *in, TList *out); + void ResolveKeywords(TString &s, const char *logfile); - void SendInputDataFile(); + void SendInputDataFile(); + void ShowDataDir(const char *dirname); protected: TProofLite() : TProof() { } // For derived classes to use @@ -133,6 +134,9 @@ friend class TProofPlayerLite; Int_t Load(const char *macro, Bool_t notOnClient = kFALSE, Bool_t uniqueOnly = kTRUE, TList *wrks = 0); + // Data management + void ShowData(); + // Query management TList *GetListOfQueries(Option_t *opt = ""); Int_t Remove(const char *ref, Bool_t all); diff --git a/proof/proof/inc/TProofLog.h b/proof/proof/inc/TProofLog.h index 5d579564fccba..27ac4719d5ca4 100644 --- a/proof/proof/inc/TProofLog.h +++ b/proof/proof/inc/TProofLog.h @@ -1,4 +1,4 @@ -// @(#)root/proof:$Id$ +// @(#)root/proof:$Id: 5d579564fccbadad9cd6f81ccb7726dddea80e0d $ // Author: G. Ganis 31/08/06 /************************************************************************* @@ -64,7 +64,7 @@ friend class TXProofMgr; TList *GetListOfLogs() const { return fElem; } Int_t Grep(const char *txt, Int_t from = 0); void Print(Option_t *opt = 0) const; - void Prt(const char *what); + void Prt(const char *what, Bool_t newline = kTRUE); Int_t Retrieve(const char *ord = "*", TProofLog::ERetrieveOpt opt = TProofLog::kTrailing, const char *fname = 0, const char *pattern = 0); diff --git a/proof/proof/inc/TProofMgr.h b/proof/proof/inc/TProofMgr.h index 43bece57f8a4f..44b3659601133 100644 --- a/proof/proof/inc/TProofMgr.h +++ b/proof/proof/inc/TProofMgr.h @@ -124,7 +124,7 @@ class TProofMgr : public TNamed { virtual void Grep(const char *, const char * = 0, const char * = 0) { } virtual void Ls(const char * = "~/", const char * = 0, const char * = 0) { } virtual void More(const char *, const char * = 0, const char * = 0) { } - virtual Int_t Rm(const char *, const char * = 0, const char * = 0) { return -1; } + virtual Int_t Rm(const char *, const char * = 0, const char * = 0); virtual void Tail(const char *, const char * = 0, const char * = 0) { } virtual Int_t Md5sum(const char *, TString &, const char * = 0) { return -1; } virtual Int_t Stat(const char *, FileStat_t &, const char * = 0) { return -1; } diff --git a/proof/proofplayer/inc/TProofOutputFile.h b/proof/proof/inc/TProofOutputFile.h similarity index 88% rename from proof/proofplayer/inc/TProofOutputFile.h rename to proof/proof/inc/TProofOutputFile.h index 98dcf40e5d2ba..3006962d62125 100644 --- a/proof/proofplayer/inc/TProofOutputFile.h +++ b/proof/proof/inc/TProofOutputFile.h @@ -26,7 +26,6 @@ #endif class TCollection; -class TProofOutputFile; class TString; class TList; class TFile; @@ -82,7 +81,12 @@ friend class TProofPlayerRemote; protected: public: - enum EStatusBits { kOutputFileNameSet = BIT(16)}; + enum EStatusBits { + kOutputFileNameSet = BIT(16), + kRetrieve = BIT(17), // If set, the file is copied to the final destination via the client + kSwapFile = BIT(18) // Set when the represented file is the result of the automatic + // save-to-file functionality + }; TProofOutputFile() : fDir(), fRawDir(), fFileName(), fOptionsAnchor(), fOutputFileName(), fWorkerOrdinal(), fLocalHost(), fIsLocal(kFALSE), fMerged(kFALSE), fRunType(kMerge), fTypeOpt(kRemote), fMergeHistosOneGo(kFALSE), @@ -106,6 +110,10 @@ friend class TProofPlayerRemote; Bool_t IsMerged() const { return fMerged; } Bool_t IsRegister() const { return ((fTypeOpt & kRegister) || (fTypeOpt & kVerify)) ? kTRUE : kFALSE; } + Bool_t IsRetrieve() const { return (TestBit(TProofOutputFile::kRetrieve)) ? kTRUE : kFALSE; } + void SetRetrieve(Bool_t on = kTRUE) { if (on) { SetBit(TProofOutputFile::kRetrieve); + } else { ResetBit(TProofOutputFile::kRetrieve); }} + Int_t AdoptFile(TFile *f); // Adopt a TFile already open TFile* OpenFile(const char *opt); // Open a file with the specified name in fFileName1 Long64_t Merge(TCollection *list); @@ -115,7 +123,7 @@ friend class TProofPlayerRemote; static Int_t AssertDir(const char *dirpath); - ClassDef(TProofOutputFile,4) // Wrapper class to steer the merging of files produced on workers + ClassDef(TProofOutputFile,5) // Wrapper class to steer the merging of files produced on workers }; #endif diff --git a/proof/proof/inc/TProofServ.h b/proof/proof/inc/TProofServ.h index 1b8c8b65d1689..f4a813afa38bb 100644 --- a/proof/proof/inc/TProofServ.h +++ b/proof/proof/inc/TProofServ.h @@ -44,6 +44,7 @@ #endif class TDataSetManager; +class TDataSetManagerFile; class TDSet; class TDSetElement; class TFileCollection; @@ -97,7 +98,9 @@ friend class TXProofServ; TString fQueryDir; //directory containing query results and status TString fDataSetDir; //directory containing info about known data sets TString fDataDir; //directory containing data files produced during queries + TString fDataDirOpts; //Url type options for fDataDir TString fAdminPath; //admin path for this session + TString fOutputFile; //path with the temporary results of the current or last query TProofLockPath *fPackageLock; //package dir locker TProofLockPath *fCacheLock; //cache dir locker TProofLockPath *fQueryLock; //query dir locker @@ -122,7 +125,8 @@ friend class TXProofServ; Float_t fRealTime; //real time spent executing commands Float_t fCpuTime; //CPU time spent executing commands TStopwatch fLatency; //measures latency of packet requests - TStopwatch fCompute; //measures time spend processing a packet + TStopwatch fCompute; //measures time spent processing a packet + TStopwatch fSaveOutput; //measures time spent saving the partial result Int_t fQuerySeqNum; //sequential number of the current or last query Int_t fTotSessions; //Total number of PROOF sessions on the cluster @@ -152,6 +156,7 @@ friend class TXProofServ; Int_t fCompressMsg; // Compression level for messages TDataSetManager* fDataSetManager; // dataset manager + TDataSetManagerFile *fDataSetStgRepo; // repository for staging requests Bool_t fSendLogToMaster; // On workers, controls logs sending to master @@ -200,9 +205,6 @@ friend class TXProofServ; // Results handling Int_t SendResults(TSocket *sock, TList *outlist = 0, TQueryResult *pq = 0); Bool_t AcceptResults(Int_t connections, TVirtualProofPlayer *mergerPlayer); - - TMap *GetDataSetNodeMap(const char *dsn, TString &emsg); - Int_t RegisterDataSets(TList *in, TList *out); // Waiting queries handlers void SetIdle(Bool_t st = kTRUE); @@ -254,10 +256,12 @@ friend class TXProofServ; const char *GetGroup() const { return fGroup; } const char *GetWorkDir() const { return fWorkDir; } const char *GetImage() const { return fImage; } - const char *GetSessionTag() const { return fTopSessionTag; } + const char *GetSessionTag() const { return fSessionTag; } + const char *GetTopSessionTag() const { return fTopSessionTag; } const char *GetSessionDir() const { return fSessionDir; } const char *GetPackageDir() const { return fPackageDir; } const char *GetDataDir() const { return fDataDir; } + const char *GetDataDirOpts() const { return fDataDirOpts; } Int_t GetProtocol() const { return fProtocol; } const char *GetOrdinal() const { return fOrdinal; } Int_t GetGroupId() const { return fGroupId; } @@ -343,6 +347,14 @@ friend class TXProofServ; static void SetLastMsg(const char *lastmsg); static void SetLastEntry(Long64_t lastentry); + // To handle local data server related paths + static void FilterLocalroot(TString &path, const char *url = "root://dum/"); + static void GetLocalServer(TString &dsrv); + + // To prepara ethe map of files to process + static TMap *GetDataSetNodeMap(TFileCollection *fc, TString &emsg); + static Int_t RegisterDataSets(TList *in, TList *out, TDataSetManager *dsm, TString &e); + static Bool_t IsActive(); static TProofServ *This(); @@ -421,9 +433,10 @@ class TProofServLogHandlerGuard { class TShutdownTimer : public TTimer { private: TProofServ *fProofServ; + Int_t fTimeout; public: - TShutdownTimer(TProofServ *p, Int_t delay) : TTimer(delay, kFALSE), fProofServ(p) { } + TShutdownTimer(TProofServ *p, Int_t delay); Bool_t Notify(); }; diff --git a/proof/proof/inc/TSlave.h b/proof/proof/inc/TSlave.h index 3110eda217a3c..e2c4f8a8ebf5e 100644 --- a/proof/proof/inc/TSlave.h +++ b/proof/proof/inc/TSlave.h @@ -58,6 +58,9 @@ friend class TXSlave; enum ESlaveType { kMaster, kSlave }; enum ESlaveStatus { kInvalid, kActive, kInactive }; + enum EStatusBits { + kOutputRequested = BIT(15) // If output has been requested + }; private: diff --git a/proof/proof/inc/TVirtualProofPlayer.h b/proof/proof/inc/TVirtualProofPlayer.h index fc41f209ebf3e..8ba1d787a3712 100644 --- a/proof/proof/inc/TVirtualProofPlayer.h +++ b/proof/proof/inc/TVirtualProofPlayer.h @@ -60,6 +60,7 @@ class TVirtualProofPlayer : public TObject, public TQObject { virtual Long64_t Process(TDSet *set, TSelector *selector, Option_t *option = "", Long64_t nentries = -1, Long64_t firstentry = 0) = 0; + virtual Bool_t JoinProcess(TList *workers) = 0; virtual Long64_t Finalize(Bool_t force = kFALSE, Bool_t sync = kFALSE) = 0; virtual Long64_t Finalize(TQueryResult *qr) = 0; virtual Long64_t DrawSelect(TDSet *set, const char *varexp, @@ -134,6 +135,9 @@ class TVirtualProofPlayer : public TObject, public TQObject { virtual TVirtualPacketizer *GetPacketizer() const { return 0; } + virtual void SetOutputFilePath(const char *fp) = 0; + virtual Int_t SavePartialResults(Bool_t queryend = kFALSE, Bool_t force = kFALSE) = 0; + static TVirtualProofPlayer *Create(const char *player, TProof *p, TSocket *s = 0); ClassDef(TVirtualProofPlayer,0) // Abstract PROOF player diff --git a/proof/proof/src/TDSet.cxx b/proof/proof/src/TDSet.cxx index ec14c79f435ba..66de197754a42 100644 --- a/proof/proof/src/TDSet.cxx +++ b/proof/proof/src/TDSet.cxx @@ -124,6 +124,7 @@ TDSetElement::TDSetElement(const char *file, const char *objname, const char *di fAssocObjList = 0; if (dir) fDirectory = dir; + fMaxProcTime = -1.; ResetBit(kWriteV3); ResetBit(kHasBeenLookedUp); @@ -149,6 +150,7 @@ TDSetElement::TDSetElement(const TDSetElement& elem) fFriends = 0; fDataSet = elem.fDataSet; fAssocObjList = 0; + fMaxProcTime = elem.fMaxProcTime; ResetBit(kWriteV3); ResetBit(kHasBeenLookedUp); ResetBit(kEmpty); @@ -451,17 +453,9 @@ Long64_t TDSetElement::GetEntries(Bool_t isTree, Bool_t openfile) } // Record end-point Url and mark as looked-up; be careful to change - // nothing in the file name, otherwise some cross-checks may fail - TUrl *eu = (TUrl *) file->GetEndpointUrl(); - if (eu) { - eu->SetOptions(TUrl(fname).GetOptions()); - eu->SetAnchor(TUrl(fname).GetAnchor()); - if (strlen(eu->GetProtocol()) > 0 && strcmp(eu->GetProtocol(), "file")) - fName = eu->GetUrl(); - else - fName = eu->GetFileAndOptions(); - } - SetBit(kHasBeenLookedUp); + // nothing in the file name, otherwise some cross-checks may fail. + // The lookup is only performed if not yet done + if (Lookup(kFALSE) != 0) Warning("GetEntries", "lookup problems for %s", GetName()); TDirectory *dirsave = gDirectory; if (!file->cd(fDirectory)) { @@ -995,8 +989,14 @@ void TDSet::SetObjName(const char *objname) { // Set/change object name. - if (objname) + if (objname) { fObjName = objname; + TIter next(GetListOfElements()); + TDSetElement *e; + while ((e = (TDSetElement *) next())) { + e->SetTitle(objname); + } + } } //______________________________________________________________________________ diff --git a/proof/proof/src/TDSetProxy.cxx b/proof/proof/src/TDSetProxy.cxx index 79b3576ab54fe..57c9c2babf087 100644 --- a/proof/proof/src/TDSetProxy.cxx +++ b/proof/proof/src/TDSetProxy.cxx @@ -65,7 +65,7 @@ TDSetElement *TDSetProxy::Next(Long64_t totalEntries) fCurrent = fServ->GetNextPacket(totalEntries); - // Check log file lenght (before processing the next packet, so we have the + // Check log file length (before processing the next packet, so we have the // chance to keep the latest logs) fServ->TruncateLogFile(); diff --git a/proof/proof/src/TDataSetManager.cxx b/proof/proof/src/TDataSetManager.cxx index d916ac25eb78a..8b89cf473a493 100644 --- a/proof/proof/src/TDataSetManager.cxx +++ b/proof/proof/src/TDataSetManager.cxx @@ -492,7 +492,7 @@ Int_t TDataSetManager::ScanDataSet(const char *uri, const char *opts) // L, locateonly: only locate the selected files // S, stageonly: issue a stage request for the selected files not yet staged // - // 'auxilliary' field + // 'auxiliary' field // V, verbose: notify the actions // // Returns 0 on success, -1 if any failure occurs. @@ -845,8 +845,37 @@ Bool_t TDataSetManager::ParseUri(const char *uri, // Only non-null parameters are filled by this function. // Returns kTRUE in case of success. - // Append trailing slash if missing when wildcards are enabled TString uristr(uri); + + // If URI contains fields in the form "Field=Value;" it is a virtual URI and + // should be treated differently + if ((uristr.Index('=') >= 0) && (uristr.Index(';') >= 0)) { + + // URI is composed of two parts: a name (dsName), and the tree after the + // pound sign + + Warning("ParseUri", + "Dataset URI looks like a virtual URI, treating it as such. " + "No group and user will be parsed!"); + + TPMERegexp reVirtualUri("^([^#]+)(#(.*))?$"); + Int_t nm = reVirtualUri.Match(uristr); + + if (nm >= 2) { + if (dsGroup) *dsGroup = ""; + if (dsUser) *dsUser = ""; + if (dsName) *dsName = reVirtualUri[1]; + if (dsTree) { + if (nm == 4) *dsTree = reVirtualUri[3]; + else *dsTree = ""; + } + } + else return kFALSE; // should never happen! + + return kTRUE; + } + + // Append trailing slash if missing when wildcards are enabled Int_t pc = 0; if (wildcards && uristr.Length() > 0) { pc = uristr.CountChar('/'); @@ -1408,7 +1437,7 @@ Bool_t TDataSetManager::CheckStagedStatus(TFileInfo *fileInfo, Int_t fopt, Int_t fileInfo->ResetUrl(); if (!fileInfo->GetCurrentUrl()) { - ::Error("TDataSetManager::ScanDataSet", "GetCurrentUrl() returned 0 for %s", + ::Error("TDataSetManager::CheckStagedStatus", "GetCurrentUrl() returned 0 for %s", fileInfo->GetFirstUrl()->GetUrl()); return kFALSE; } @@ -1441,7 +1470,7 @@ Bool_t TDataSetManager::CheckStagedStatus(TFileInfo *fileInfo, Int_t fopt, Int_t // Actually access the file char tmpChar = 0; if (file->ReadBuffer(&tmpChar, 1)) - ::Warning("TDataSetManager::ScanDataSet", "problems reading 1 byte from open file"); + ::Warning("TDataSetManager::CheckStagedStatus", "problems reading 1 byte from open file"); // Count touched = kTRUE; } @@ -1449,7 +1478,7 @@ Bool_t TDataSetManager::CheckStagedStatus(TFileInfo *fileInfo, Int_t fopt, Int_t delete file; } else { // File could not be opened, reset staged bit - if (dbg) ::Info("TDataSetManager::ScanDataSet", "file %s disappeared", url.GetUrl()); + if (dbg) ::Info("TDataSetManager::CheckStagedStatus", "file %s disappeared", url.GetUrl()); fileInfo->ResetBit(TFileInfo::kStaged); disappeared = kTRUE; changed = kTRUE; @@ -1492,11 +1521,11 @@ Bool_t TDataSetManager::CheckStagedStatus(TFileInfo *fileInfo, Int_t fopt, Int_t if (stager) { result = stager->IsStaged(url.GetUrl()); if (gDebug > 0) - ::Info("TDataSetManager::ScanDataSet", "IsStaged: %s: %d", url.GetUrl(), result); + ::Info("TDataSetManager::CheckStagedStatus", "IsStaged: %s: %d", url.GetUrl(), result); if (createStager) SafeDelete(stager); } else { - ::Warning("TDataSetManager::ScanDataSet", + ::Warning("TDataSetManager::CheckStagedStatus", "could not get stager instance for '%s'", url.GetUrl()); } @@ -1655,7 +1684,13 @@ Int_t TDataSetManager::ScanFile(TFileInfo *fileinfo, Bool_t dbg) // We need a raw open firts to get the real size of the file TUrl urlNoAnchor(furl); urlNoAnchor.SetAnchor(""); - urlNoAnchor.SetOptions("filetype=raw"); + TString unaopts = urlNoAnchor.GetOptions(); + if (!unaopts.IsNull()) { + unaopts += "&filetype=raw"; + } else { + unaopts = "filetype=raw"; + } + urlNoAnchor.SetOptions(unaopts); // Wait max 5 secs per file if (!(file = TFile::Open(urlNoAnchor.GetUrl(), fileopt))) return rc; @@ -1667,12 +1702,26 @@ Int_t TDataSetManager::ScanFile(TFileInfo *fileinfo, Bool_t dbg) // Add url of the disk server in front of the list if (file->GetEndpointUrl()) { + // add endpoint url if it is not a local file TUrl eurl(*(file->GetEndpointUrl())); - eurl.SetOptions(url->GetOptions()); - eurl.SetAnchor(url->GetAnchor()); - fileinfo->AddUrl(eurl.GetUrl(), kTRUE); - if (gDebug > 0) ::Info("TDataSetManager::ScanFile", "added URL %s", eurl.GetUrl()); + if (strcmp(eurl.GetProtocol(), "file") || + !strcmp(eurl.GetProtocol(), url->GetProtocol())) { + + eurl.SetOptions(url->GetOptions()); + eurl.SetAnchor(url->GetAnchor()); + + // Fix the hostname + if (!strcmp(eurl.GetHost(), "localhost") || !strcmp(eurl.GetHost(), "127.0.0.1") || + !strcmp(eurl.GetHost(), "localhost.localdomain")) { + eurl.SetHost(TUrl(gSystem->HostName()).GetHostFQDN()); + } + // Add only if different + if (strcmp(eurl.GetUrl(), url->GetUrl())) + fileinfo->AddUrl(eurl.GetUrl(), kTRUE); + + if (gDebug > 0) ::Info("TDataSetManager::ScanFile", "added URL %s", eurl.GetUrl()); + } } else { ::Warning("TDataSetManager::ScanFile", "end-point URL undefined for file %s", file->GetName()); } @@ -1701,14 +1750,26 @@ Int_t TDataSetManager::ScanFile(TFileInfo *fileinfo, Bool_t dbg) if (file->GetSize() > 0) fileinfo->SetSize(file->GetSize()); fileinfo->SetBit(TFileInfo::kStaged); - // Add url of the disk server in front of the list + // Add url of the disk server in front of the list if it is not a local file TUrl eurl(*(file->GetEndpointUrl())); - eurl.SetOptions(url->GetOptions()); - eurl.SetAnchor(url->GetAnchor()); - fileinfo->AddUrl(eurl.GetUrl(), kTRUE); - if (gDebug > 0) ::Info("TDataSetManager::ScanFile", "added URL %s", eurl.GetUrl()); + if (strcmp(eurl.GetProtocol(), "file") || + !strcmp(eurl.GetProtocol(), url->GetProtocol())) { + eurl.SetOptions(url->GetOptions()); + eurl.SetAnchor(url->GetAnchor()); + + // Fix the hostname + if (!strcmp(eurl.GetHost(), "localhost") || !strcmp(eurl.GetHost(), "127.0.0.1") || + !strcmp(eurl.GetHost(), "localhost.localdomain")) { + eurl.SetHost(TUrl(gSystem->HostName()).GetHostFQDN()); + } + // Add only if different + if (strcmp(eurl.GetUrl(), url->GetUrl())) + fileinfo->AddUrl(eurl.GetUrl(), kTRUE); + + if (gDebug > 0) ::Info("TDataSetManager::ScanFile", "added URL %s", eurl.GetUrl()); + } fileinfo->SetUUID(file->GetUUID().AsString()); } rc = 0; diff --git a/proof/proof/src/TDataSetManagerAliEn.cxx b/proof/proof/src/TDataSetManagerAliEn.cxx new file mode 100644 index 0000000000000..0843295405209 --- /dev/null +++ b/proof/proof/src/TDataSetManagerAliEn.cxx @@ -0,0 +1,1092 @@ +// @(#)root/base:$Id$ +// Author: Dario Berzano, 26.11.12 + +/************************************************************************* + * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////// +// // +// TDataSetManagerAliEn // +// // +// Implementation of TDataSetManager dynamically creating datasets // +// by querying the AliEn file catalog. Retrieved information is cached. // +// // +////////////////////////////////////////////////////////////////////////// + +#include "TDataSetManagerAliEn.h" +#include "TError.h" + +ClassImp(TAliEnFind); + +//______________________________________________________________________________ +TAliEnFind::TAliEnFind(const TString &basePath, const TString &fileName, + const TString &anchor, const Bool_t archSubst, const TString &treeName, + const TString ®exp) : + fBasePath(basePath), fFileName(fileName), fTreeName(treeName), + fRegexpRaw(regexp), fAnchor(anchor), fArchSubst(archSubst), fRegexp(0), + fSearchId(""), fGridResult(0) +{ + // Constructor + + if (fArchSubst) fAnchor = ""; // no anchor when substituting zipfile + if (!fRegexpRaw.IsNull()) + fRegexp = new TPMERegexp(regexp); +} + +//______________________________________________________________________________ +TAliEnFind::TAliEnFind(const TAliEnFind &src) : TObject() +{ + // Copy constructor. Cached query result is not copied + + fBasePath = src.fBasePath; + fFileName = src.fFileName; + fAnchor = src.fAnchor; + fArchSubst = src.fArchSubst; + fTreeName = src.fTreeName; + fRegexpRaw = src.fRegexpRaw; + + if (src.fRegexp) + fRegexp = new TPMERegexp( *(src.fRegexp) ); + else + fRegexp = NULL; + + fGridResult = NULL; +} + +//______________________________________________________________________________ +TAliEnFind &TAliEnFind::operator=(const TAliEnFind &rhs) +{ + // Assignment operator. Cached query result is not copied + + if (&rhs != this) { + fBasePath = rhs.fBasePath; + fFileName = rhs.fFileName; + fAnchor = rhs.fAnchor; + fArchSubst = rhs.fArchSubst; + fTreeName = rhs.fTreeName; + + SetRegexp(rhs.fRegexpRaw); + + InvalidateSearchId(); + InvalidateGridResult(); + } + + return *this; +} + +//______________________________________________________________________________ +TAliEnFind::~TAliEnFind() +{ + // Destructor + + if (fRegexp) delete fRegexp; + if (fGridResult) delete fGridResult; +} + +//______________________________________________________________________________ +TGridResult *TAliEnFind::GetGridResult(Bool_t forceNewQuery) +{ + // Query the AliEn file catalog + + if (fGridResult && !forceNewQuery) { + if (gDebug >= 1) + Info("GetGridResult", "Returning cached AliEn find results"); + return fGridResult; + } + else if (gDebug >= 1) { + Info("GetGridResult", "Querying AliEn file catalog"); + } + + InvalidateGridResult(); + + if (!gGrid) { + TGrid::Connect("alien:"); + if (!gGrid) return NULL; + } + + if (gDebug >= 1) { + Info("GetGridResult", "AliEn find %s %s [regexp=%s]", + fBasePath.Data(), fFileName.Data(), fRegexpRaw.Data()); + } + + fGridResult = gGrid->Query(fBasePath.Data(), fFileName.Data()); + if (!fGridResult) return NULL; + + if (fRegexp || fArchSubst || (fAnchor != "")) { + + TPMERegexp *reArchSubst = NULL; + TString substWith; + if (fArchSubst) { + TString temp; + temp.Form("/%s$", fFileName.Data()); + reArchSubst = new TPMERegexp(temp.Data()); + substWith.Form("/root_archive.zip#%s", fFileName.Data()); + } + + TIter it(fGridResult); + TMap *map; + TObjString *os; + TString tUrl; + + while (( map = dynamic_cast<TMap *>(it.Next()) ) != NULL) { + + os = dynamic_cast<TObjString *>( map->GetValue("turl") ); + if (!os) continue; + tUrl = os->String(); + + if (fRegexp && (fRegexp->Match(tUrl) == 0)) { + // Remove object if it does not match expression + TObject *exmap = fGridResult->Remove(map); + if (exmap) delete exmap; // Remove() does not delete + } + + if (reArchSubst) { + reArchSubst->Substitute(tUrl, substWith, kFALSE); + os->SetString(tUrl.Data()); + } + else if (fAnchor) { + tUrl.Append("#"); + tUrl.Append(fAnchor); + os->SetString(tUrl.Data()); + } + } + + if (reArchSubst) delete reArchSubst; + } + + return fGridResult; +} + +//______________________________________________________________________________ +const char *TAliEnFind::GetSearchId() +{ + if (fSearchId.IsNull()) { + TString searchIdStr; + searchIdStr.Form("BasePath=%s FileName=%s Anchor=%s ArchSubst=%d " + "TreeName=%s Regexp=%s", + fBasePath.Data(), fFileName.Data(), fAnchor.Data(), fArchSubst, + fTreeName.Data(), fRegexpRaw.Data()); + TMD5 *md5 = new TMD5(); + md5->Update( (const UChar_t *)searchIdStr.Data(), + (UInt_t)searchIdStr.Length() ); + md5->Final(); + fSearchId = md5->AsString(); + delete md5; + } + if (gDebug >= 2) + Info("GetSearchId", "Returning search ID %s", fSearchId.Data()); + return fSearchId.Data(); +} + +//______________________________________________________________________________ +TFileCollection *TAliEnFind::GetCollection(Bool_t forceNewQuery) +{ + GetGridResult(forceNewQuery); + if (!fGridResult) return NULL; + + Int_t nEntries = fGridResult->GetEntries(); + TFileCollection *fc = new TFileCollection(); + + for (Int_t i=0; i<nEntries; i++) { + + Long64_t size = TString(fGridResult->GetKey(i, "size")).Atoll(); + + TString tUrl = fGridResult->GetKey(i, "turl"); + + if (gDebug >= 2) + Info("GetCollection", ">> %s", tUrl.Data()); + + // Append to TFileCollection: url, size, guid, md5 + TFileInfo *fi = new TFileInfo( tUrl, size, fGridResult->GetKey(i, "guid"), + fGridResult->GetKey(i, "md5") ); + + fc->Add(fi); + + } + + if (fTreeName != "") + fc->SetDefaultTreeName(fTreeName.Data()); + + fc->Update(); // needed for summary info + + return fc; +} + +//______________________________________________________________________________ +void TAliEnFind::Print(Option_t* opt) const +{ + if (opt) {} // silence warning + Printf("BasePath=%s FileName=%s Anchor=%s ArchSubst=%d " + "TreeName=%s Regexp=%s (query %s a result)", + fBasePath.Data(), fFileName.Data(), fAnchor.Data(), fArchSubst, + fTreeName.Data(), fRegexpRaw.Data(), (fGridResult ? "has" : "has not")); +} + +//______________________________________________________________________________ +void TAliEnFind::SetBasePath(const char *basePath) +{ + if (fBasePath.EqualTo(basePath)) return; + fBasePath = basePath; + InvalidateGridResult(); + InvalidateSearchId(); +} + +//______________________________________________________________________________ +void TAliEnFind::SetFileName(const char *fileName) +{ + if (fFileName.EqualTo(fileName)) return; + fFileName = fileName; + InvalidateGridResult(); + InvalidateSearchId(); +} + +//______________________________________________________________________________ +void TAliEnFind::SetAnchor(const char *anchor) +{ + if (fAnchor.EqualTo(anchor)) return; + fAnchor = anchor; + InvalidateGridResult(); + InvalidateSearchId(); +} + +//______________________________________________________________________________ +void TAliEnFind::SetTreeName(const char *treeName) +{ + if (fTreeName.EqualTo(treeName)) return; + fTreeName = treeName; + InvalidateSearchId(); +} + +//______________________________________________________________________________ +void TAliEnFind::SetArchSubst(Bool_t archSubst) +{ + if (fArchSubst == archSubst) return; + fArchSubst = archSubst; + InvalidateGridResult(); + InvalidateSearchId(); +} + +//______________________________________________________________________________ +void TAliEnFind::SetRegexp(const char *regexp) +{ + if (fRegexpRaw.EqualTo(regexp)) return; + + fRegexpRaw = regexp; + if (fRegexp) delete fRegexp; + if (!fRegexpRaw.IsNull()) + fRegexp = new TPMERegexp(regexp); + else + fRegexp = NULL; + + InvalidateGridResult(); + InvalidateSearchId(); +} + +//______________________________________________________________________________ +void TAliEnFind::InvalidateSearchId() +{ + if (!fSearchId.IsNull()) + fSearchId = ""; +} + +//______________________________________________________________________________ +void TAliEnFind::InvalidateGridResult() +{ + if (fGridResult) { + delete fGridResult; + fGridResult = NULL; + } +} + +ClassImp(TDataSetManagerAliEn); + +//______________________________________________________________________________ +void TDataSetManagerAliEn::Init(TString cacheDir, TString urlTpl, + ULong_t cacheExpire_s) +{ + fCacheExpire_s = cacheExpire_s; + fUrlRe = new TPMERegexp("^alien://(.*)$"); + fUrlTpl = urlTpl; + fUrlTpl.ReplaceAll("<path>", "$1"); + + TString dsDirFmt; + dsDirFmt.Form("dir:%s perms:open", cacheDir.Data()); + fCache = new TDataSetManagerFile("_cache_", "_cache_", dsDirFmt); + + if (fCache->TestBit(TObject::kInvalidObject)) { + Error("Init", "Cannot initialize cache on directory %s", cacheDir.Data()); + SetBit(TObject::kInvalidObject); + return; + } + + // Provided for compatibility + ResetBit(TDataSetManager::kAllowRegister); // impossible to register + ResetBit(TDataSetManager::kCheckQuota); // quota control off + + if (gDebug >= 1) { + Info("TDataSetManagerAliEn", "Caching on %s", cacheDir.Data()); + Info("TDataSetManagerAliEn", "URL schema: %s", urlTpl.Data()); + Info("TDataSetManagerAliEn", "Cache expires after: %lus", cacheExpire_s); + } +} + +//______________________________________________________________________________ +TDataSetManagerAliEn::TDataSetManagerAliEn(const char *cacheDir, + const char *urlTpl, ULong_t cacheExpire_s) + : TDataSetManager("", "", ""), fUrlRe(0), fCache(0) +{ + Init(cacheDir, urlTpl, cacheExpire_s); +} + +//______________________________________________________________________________ +TDataSetManagerAliEn::TDataSetManagerAliEn(const char *, const char *, + const char *cfgStr) : TDataSetManager("", "", ""), fUrlRe(0), fCache(0) +{ + // Compatibility with the plugin manager + + TPMERegexp reCache("(^| )cache:([^ ]+)( |$)"); + if (reCache.Match(cfgStr) != 4) { + Error("TDataSetManagerAliEn", "No cache directory specified"); + SetBit(TObject::kInvalidObject); + return; + } + + TPMERegexp reUrlTpl("(^| )urltemplate:([^ ]+)( |$)"); + if (reUrlTpl.Match(cfgStr) != 4) { + Error("TDataSetManagerAliEn", "No local URL template specified"); + SetBit(TObject::kInvalidObject); + return; + } + + TPMERegexp reCacheExpire("(^| )cacheexpiresecs:([0-9]+)( |$)"); + if (reCacheExpire.Match(cfgStr) != 4) { + Error("TDataSetManagerAliEn", "No cache expiration set"); + SetBit(TObject::kInvalidObject); + return; + } + + Init(reCache[2], reUrlTpl[2], (ULong_t)reCacheExpire[2].Atoll()); +} + +//______________________________________________________________________________ +TDataSetManagerAliEn::~TDataSetManagerAliEn() +{ + if (fCache) delete fCache; + if (fUrlRe) delete fUrlRe; +} + +//______________________________________________________________________________ +TList *TDataSetManagerAliEn::GetFindCommandsFromUri(TString &uri, + EDataMode &dataMode, Bool_t &forceUpdate) +{ + // Parse kind + TPMERegexp reKind("^(Data;|Sim;|Find;)"); + if (reKind.Match(uri) != 2) { + Error("GetFindCommandsFromUri", "Data, Sim or Find not specified"); + return NULL; + } + + // Parse data mode (remote, local, cache -- optional) + TPMERegexp reMode("(^|;)Mode=([A-Za-z]+)(;|$)"); + if (reMode.Match(uri) != 4) { + dataMode = kDataLocal; // default + } + else { + if (reMode[2].EqualTo("remote", TString::kIgnoreCase)) + dataMode = kDataRemote; + else if (reMode[2].EqualTo("local", TString::kIgnoreCase)) + dataMode = kDataLocal; + else if (reMode[2].EqualTo("cache", TString::kIgnoreCase)) + dataMode = kDataCache; + else { + Error("GetFindCommandsFromUri", + "Wrong analysis mode specified: use one of: Mode=remote, local, cache"); + return NULL; // no mode is ok, but wrong mode is not + } + } + + TList *findCommands = NULL; + + if (reKind[1].BeginsWith("Find")) { + + TString basePath; + TString fileName; + TString anchor; + TString treeName; + TString regexp; + + // Custom search URI + if (!ParseCustomFindUri(uri, basePath, fileName, anchor, + treeName, regexp)) { + Error("GetFindCommandsFromUri", "Malformed AliEn find command"); + return NULL; + } + + findCommands = new TList(); + findCommands->SetOwner(); + findCommands->Add( new TAliEnFind(basePath, fileName, anchor, kFALSE, + treeName, regexp) ); + + } + else { // Data or Sim + Bool_t sim = (reKind[1][0] == 'S'); + TString lhcPeriod; + Int_t year; + std::vector<Int_t> *runList; + Bool_t esd; + Int_t aodNum; + TString pass; + + if (!ParseOfficialDataUri(uri, sim, lhcPeriod, year, runList, esd, + aodNum, pass)) { + Error("GetFindCommandsFromUri", "Invalid parameters"); + return NULL; + } + + findCommands = new TList(); + findCommands->SetOwner(kTRUE); + + TString basePathRun; + + if (!gGrid) { + TGrid::Connect("alien:"); + if (!gGrid) { + delete findCommands; + delete runList; + return NULL; + } + } + + if (sim) { + // Montecarlo init. + // Check whether this period is in /alice/sim/<period> or in + // /alice/sim/<year>/<period> and act properly, since naming convention + // is unclear! + + // Check once for all + basePathRun.Form("/alice/sim/%s", lhcPeriod.Data()); // no year + if (!gGrid->Cd(basePathRun.Data())) { + basePathRun.Form("/alice/sim/%d/%s", year, lhcPeriod.Data()); + } + } + else { + // Real data init. + // Parse the pass string: if it starts with a number, prepend "pass" + if ((pass[0] >= '0') && (pass[0] <= '9')) pass.Prepend("pass"); + basePathRun.Form("/alice/data/%d/%s", year, lhcPeriod.Data()); + } + + // Form a list of valid runs (to avoid unnecessary queries when run ranges + // are specified) + std::vector<Int_t> validRuns; + { + TGridResult *validRunDirs = gGrid->Ls( basePathRun.Data() ); + if (!validRunDirs) return NULL; + + TIter nrd(validRunDirs); + TMap *dir; + TObjString *os; + validRuns.resize( (size_t)(validRunDirs->GetEntries()) ); + + while (( dir = dynamic_cast<TMap *>(nrd()) ) != NULL) { + os = dynamic_cast<TObjString *>( dir->GetValue("name") ); + if (!os) continue; + Int_t run = (os->String()).Atoi(); + if (run > 0) validRuns.push_back(run); + } + } + + for (UInt_t i=0; i<runList->size(); i++) { + + // Check if current run is valid + Bool_t valid = kFALSE; + for (UInt_t j=0; j<validRuns.size(); j++) { + if (validRuns[j] == (*runList)[i]) { + valid = kTRUE; + break; + } + } + if (!valid) { + //if (gDebug >=1) { + Warning("TDataSetManagerAliEn::GetFindCommandsFromUri", + "Avoiding unnecessary find on run %d: not found", (*runList)[i]); + //} + continue; + } + else { + Info("TDataSetManagerAliEn::GetFindCommandsFromUri", + "Run found: %d", (*runList)[i]); + } + + // Here we need to assemble the find string + TString basePath, fileName, temp; + + if (sim) { + // Montecarlo + temp.Form("/%06d", runList->at(i)); + basePath = basePathRun + temp; + + if (!esd) { + temp.Form("/AOD%03d", aodNum); + basePath.Append(temp); + } + } + else { + // Real data + temp.Form("/%09d/ESDs/%s", runList->at(i), pass.Data()); + basePath = basePathRun + temp; + if (esd) { + basePath.Append("/*.*"); + } + else { + temp.Form("/AOD%03d", aodNum); + basePath.Append(temp); + } + } + + TString treeName; + + // File name and tree name + if (esd) { + fileName = "AliESDs.root"; + treeName = "/esdTree"; + } + else { + fileName = "AliAOD.root"; + treeName = "/aodTree"; + } + + findCommands->Add( new TAliEnFind(basePath, fileName, "", kTRUE, + treeName) ); + + } + + delete runList; + + } + + // Force update or use cache (when possible) + TPMERegexp reForceUpdate("(^|;)ForceUpdate(;|$)"); + forceUpdate = (reForceUpdate.Match(uri) == 3); + + // If no valid data was found, then findCommands is NULL + return findCommands; +} + +//______________________________________________________________________________ +Bool_t TDataSetManagerAliEn::ParseCustomFindUri(TString &uri, + TString &basePath, TString &fileName, TString &anchor, TString &treeName, + TString ®exp) +{ + + // Copy URI to a dummy URI parsed to look for unrecognized stuff; initial + // part is known ("Find;") and stripped + TString checkUri = uri(5, uri.Length()); + + // Mode and ForceUpdate (strip them from the check string) + TPMERegexp reMode("(^|;)(Mode=[A-Za-z]+)(;|$)"); + if (reMode.Match(uri) == 4) + checkUri.ReplaceAll(reMode[2], ""); + TPMERegexp reForceUpdate("(^|;)(ForceUpdate)(;|$)"); + if (reForceUpdate.Match(uri) == 4) + checkUri.ReplaceAll(reForceUpdate[2], ""); + + // Base path + TPMERegexp reBasePath("(^|;)(BasePath=([^; ]+))(;|$)"); + if (reBasePath.Match(uri) != 5) { + ::Error("TDataSetManagerAliEn::ParseCustomFindUri", + "Base path not specified"); + return kFALSE; + } + checkUri.ReplaceAll(reBasePath[2], ""); + basePath = reBasePath[3]; + + // File name + TPMERegexp reFileName("(^|;)(FileName=([^; ]+))(;|$)"); + if (reFileName.Match(uri) != 5) { + ::Error("TDataSetManagerAliEn::ParseCustomFindUri", + "File name not specified"); + return kFALSE; + } + checkUri.ReplaceAll(reFileName[2], ""); + fileName = reFileName[3]; + + // Anchor (optional) + TPMERegexp reAnchor("(^|;)(Anchor=([^; ]+))(;|$)"); + if (reAnchor.Match(uri) != 5) + anchor = ""; + else { + checkUri.ReplaceAll(reAnchor[2], ""); + anchor = reAnchor[3]; + } + + // Tree name (optional) + TPMERegexp reTreeName("(^|;)(Tree=(/[^; ]+))(;|$)"); + if (reTreeName.Match(uri) != 5) + treeName = ""; + else { + checkUri.ReplaceAll(reTreeName[2], ""); + treeName = reTreeName[3]; + } + + // Regexp (optional) + TPMERegexp reRegexp("(^|;)(Regexp=([^; ]+))(;|$)"); + if (reRegexp.Match(uri) != 5) + regexp = ""; + else { + checkUri.ReplaceAll(reRegexp[2], ""); + regexp = reRegexp[3]; + } + + // Check for unparsed stuff; parsed stuff has been stripped from checkUri + checkUri.ReplaceAll(";", ""); + checkUri.ReplaceAll(" ", ""); + if (!checkUri.IsNull()) { + ::Error("TDataSetManagerAliEn::ParseCustomFindUri", + "There are unrecognized parameters in the dataset find string"); + return kFALSE; + } + return kTRUE; +} + +//______________________________________________________________________________ +Bool_t TDataSetManagerAliEn::ParseOfficialDataUri(TString &uri, Bool_t sim, + TString &period, Int_t &year, std::vector<Int_t> *&runList, Bool_t &esd, + Int_t &aodNum, TString &pass) +{ + + // Copy URI to a dummy URI parsed to look for unrecognized stuff + TString checkUri; + + // Strip the initial part (either "Data;" or "Sim;") + { + Ssiz_t idx = uri.Index(";"); + checkUri = uri(idx, uri.Length()); + } + + // Mode and ForceUpdate (strip them from the check string) + TPMERegexp reMode("(^|;)(Mode=[A-Za-z]+)(;|$)"); + if (reMode.Match(uri) == 4) + checkUri.ReplaceAll(reMode[2], ""); + TPMERegexp reForceUpdate("(^|;)(ForceUpdate)(;|$)"); + if (reForceUpdate.Match(uri) == 4) + checkUri.ReplaceAll(reForceUpdate[2], ""); + + // + // Parse LHC period + // + + TPMERegexp rePeriod("(^|;)(Period=(LHC([0-9]{2})[^;]*))(;|$)"); + if (rePeriod.Match(uri) != 6) { + ::Error("TDataSetManagerAliEn::ParseOfficialDataUri", + "LHC period not specified (e.g. Period=LHC10h)"); + return kFALSE; + } + + checkUri.ReplaceAll(rePeriod[2], ""); + period = rePeriod[3]; + year = rePeriod[4].Atoi() + 2000; + + // + // Parse data format (ESDs or AODXXX) + // + + TPMERegexp reFormat("(^|;)(Variant=(ESDs?|AOD([0-9]{3})))(;|$)"); + if (reFormat.Match(uri) != 6) { + ::Error("TDataSetManagerAliEn::ParseOfficialDataUri", + "Data variant (e.g., Variant=ESD or AOD079) not specified"); + return kFALSE; + } + + checkUri.ReplaceAll(reFormat[2], ""); + if (reFormat[3].BeginsWith("ESD")) esd = kTRUE; + else { + esd = kFALSE; + aodNum = reFormat[4].Atoi(); + } + + // + // Parse pass: mandatory on Data, useless on Sim + // + + TPMERegexp rePass("(^|;)(Pass=([a-zA-Z_0-9-]+))(;|$)"); + if ((!sim) && (rePass.Match(uri) != 5)) { + ::Error("TDataSetManagerAliEn::ParseOfficialDataUri", + "Pass (e.g., Pass=cpass1_muon) is mandatory on real data"); + return kFALSE; + } + checkUri.ReplaceAll(rePass[2], ""); + pass = rePass[3]; + + // + // Parse run list + // + + TPMERegexp reRun("(^|;)(Run=([0-9,-]+))(;|$)"); + if (reRun.Match(uri) != 5) { + ::Error("TDataSetManagerAliEn::ParseOfficialDataUri", + "Run or run range not specified (e.g., Run=139104-139107,139306)"); + return kFALSE; + } + checkUri.ReplaceAll(reRun[2], ""); + TString runListStr = reRun[3]; + runList = ExpandRunSpec(runListStr); // must be freed by caller + + // Check for unparsed stuff; parsed stuff has been stripped from checkUri + checkUri.ReplaceAll(";", ""); + checkUri.ReplaceAll(" ", ""); + if (!checkUri.IsNull()) { + ::Error("TDataSetManagerAliEn::ParseOfficialDataUri", + "There are unrecognized parameters in dataset string"); + return kFALSE; + } + + return kTRUE; +} + +//______________________________________________________________________________ +std::vector<Int_t> *TDataSetManagerAliEn::ExpandRunSpec(TString &runSpec) { + + std::vector<Int_t> *runNumsPtr = new std::vector<Int_t>(); + std::vector<Int_t> &runNums = *runNumsPtr; + + TObjArray *runs = runSpec.Tokenize(":,"); + runs->SetOwner(); + TIter run(runs); + TObjString *runOs; + + while ( (runOs = dynamic_cast<TObjString *>(run.Next())) ) { + + TString runStr = runOs->String(); + + TPMERegexp p("^([0-9]+)-([0-9]+)$"); + if (p.Match(runStr) == 3) { + Int_t r1 = p[1].Atoi(); + Int_t r2 = p[2].Atoi(); + + if (r1 > r2) { + // Swap + r1 = r1 ^ r2; + r2 = r1 ^ r2; + r1 = r1 ^ r2; + } + + for (Int_t r=r1; r<=r2; r++) { + runNums.push_back(r); + } + } + else { + runNums.push_back(runStr.Atoi()); + } + } + + delete runs; + + // Bubble sort (slow) + for (UInt_t i=0; i<runNums.size(); i++) { + for (UInt_t j=i+1; j<runNums.size(); j++) { + if (runNums[j] < runNums[i]) { + runNums[i] = runNums[i] ^ runNums[j]; + runNums[j] = runNums[i] ^ runNums[j]; + runNums[i] = runNums[i] ^ runNums[j]; + } + } + } + + // Remove duplicates + { + std::vector<Int_t>::iterator itr = runNums.begin(); + Int_t prevVal = 0; // unneeded but silences uninitialized warning + while (itr != runNums.end()) { + if ((itr == runNums.begin()) || (prevVal != *itr)) { + prevVal = *itr; + itr++; + } + else { + itr = runNums.erase(itr); + } + } + } + + return runNumsPtr; + +} + +//______________________________________________________________________________ +TFileCollection *TDataSetManagerAliEn::GetDataSet(const char *uri, const char *) +{ + TFileCollection *fc = NULL; // global collection + + TString sUri(uri); + EDataMode dataMode; + Bool_t forceUpdate; + TList *findCmds = GetFindCommandsFromUri(sUri, dataMode, forceUpdate); + if (!findCmds) return NULL; + + fc = new TFileCollection(); // this fc will contain all data + + TFileStager *fstg = NULL; // used and reused for bulk lookup + TFileInfo *fi; + + TIter it(findCmds); + TAliEnFind *af; + while ((af = dynamic_cast<TAliEnFind *>(it.Next())) != NULL) { + + TString cachedUri = af->GetSearchId(); + TFileCollection *newFc = NULL; + Bool_t saveToCache = kFALSE; + Bool_t fillLocality = kFALSE; + + // Check modified time + Long_t mtime = fCache->GetModTime(cachedUri.Data()); + Long_t now = gSystem->Now(); + now = now/1000 + 788914800; // magic is secs between Jan 1st 1970 and 1995 + + if (forceUpdate) { + if (gDebug >= 1) + Info("GetDataSet", "Ignoring cached query result: forcing update"); + } + else if ((mtime > 0) && (now-mtime > fCacheExpire_s)) { + if (gDebug >= 1) + Info("GetDataSet", "Dataset cache has expired"); + } + else { + if (gDebug >= 1) + Info("GetDataSet", "Getting file collection from cache"); + newFc = fCache->GetDataSet(cachedUri.Data()); + } + + if (!newFc) { + + if (gDebug >= 1) + Info("GetDataSet", "Getting file collection from AliEn"); + + newFc = af->GetCollection(); + if (!newFc) { + Error("GetDataSet", "Cannot get collection from AliEn"); + delete findCmds; + delete fc; + return NULL; + } + + // Dataset was not cached. Just got from AliEn. Either fill with endpoint, + // if kDataLocal, or fill with dummy data, if kDataRemote/kDataLocal. + // Inside this scope we are processing data that will be cached, and not + // data actually returned to the user + + // Add redirector's URL + TIter itCache(newFc->GetList()); + TString tUrl; + while ((fi = dynamic_cast<TFileInfo *>(itCache.Next()))) { + tUrl = fi->GetCurrentUrl()->GetUrl(); + fUrlRe->Substitute(tUrl, fUrlTpl); + fi->AddUrl(tUrl.Data(), kTRUE); // kTRUE == prepend URL + fi->ResetUrl(); + } + + // Add endpoint? + if (dataMode == kDataLocal) { + fillLocality = kTRUE; // will fill + } + else { + // Don't make the user waste time: don't cache dataset locality info at + // this time, and signal our ignorance with a dummy URL + if (gDebug >= 1) + Info("GetDataSet", "Not caching data locality information now"); + itCache.Reset(); + while ((fi = dynamic_cast<TFileInfo *>(itCache.Next()))) + fi->AddUrl("noop://unknown", kTRUE); + } + + // Update summary information and save to cache! + saveToCache = kTRUE; + + } // end dataset just got from AliEn + else { + + // Reading dataset from cache. Check if it has endpoint information. + Bool_t hasEndp = kTRUE; + + fi = dynamic_cast<TFileInfo *>(newFc->GetList()->At(0)); + if (fi) { + if ((strcmp(fi->GetCurrentUrl()->GetProtocol(), "noop") == 0) && + (strcmp(fi->GetCurrentUrl()->GetHost(), "unknown") == 0)) { + if (gDebug >= 1) + Info("GetDataSet", "No dataset locality information in cache"); + hasEndp = kFALSE; + } + } + + if ((dataMode == kDataLocal) && !hasEndp) { + // Fill missing locality information now + + // Remove first dummy URL everywhere + TIter itCache(newFc->GetList()); + while ((fi = dynamic_cast<TFileInfo *>(itCache.Next()))) { + fi->RemoveUrlAt(0); + //fi->RemoveUrl("noop://unknown"); + } + + fillLocality = kTRUE; // will locate + saveToCache = kTRUE; // will cache + } + + } // end processing dataset from cache + + // Fill locality: initialize stager, locate URLs + if (fillLocality) { + fi = dynamic_cast<TFileInfo *>(newFc->GetList()->At(0)); + if (fi) { + Info("GetDataSet", "Filling dataset locality information: " + "it might take time, be patient!"); + + // Lazy stager initialization + if (!fstg) fstg = TFileStager::Open(fi->GetCurrentUrl()->GetUrl()); + + if (!fstg) { // seems nonsense but look carefully :) + Error("GetDataSet", "Can't create file stager"); + delete newFc; + delete fc; + delete findCmds; + return NULL; + } + else { + Int_t rv = fstg->LocateCollection(newFc, kTRUE); + if (rv < 0) { + Error("GetDataSet", "Endpoint lookup returned an error"); + delete fstg; + delete newFc; + delete fc; + delete findCmds; + return NULL; + } + else if (gDebug >= 1) { + Info("GetDataSet", "Lookup successful for %d file(s)", rv); + } + } + } // end if fi + } + + // Save (back) to cache if requested + if (saveToCache) { + newFc->Update(); + TString group, user, name; + fCache->ParseUri(cachedUri, &group, &user, &name); + if (fCache->WriteDataSet(group, user, name, newFc) == 0) { + // Non-fatal error, but warn user + Warning("GetDataSet", "Could not cache retrieved information"); + } + } + + // Just print the newFc (debug) + //newFc->Print("filter:SsCc"); + + // Now we prepare the final dataset, by appending proper information from + // newFc to fc + + TIter itCache(newFc->GetList()); + while ((fi = dynamic_cast<TFileInfo *>(itCache.Next()))) { + + // We no longer have unknowns. Instead we might have: redir, none. Let's + // eliminate them. For each entry we always have three URLs + + if (dataMode == kDataRemote) { + // Set everything as staged and remove first two URLs: only AliEn needed + fi->SetBit(TFileInfo::kStaged); + fi->RemoveUrlAt(0); + fi->RemoveUrlAt(0); + } + else if (dataMode == kDataCache) { + // Access from redirector, pretend that everything is staged + fi->SetBit(TFileInfo::kStaged); + fi->RemoveUrlAt(0); + } + else { // dataMode == kLocal + // Remove dummy URLs, trust staged bit + fi->RemoveUrl("noop://none"); + fi->RemoveUrl("noop://redir"); + } + + // Append to big file collection used for analysis + TFileInfo *newFi = new TFileInfo(*fi); + fc->Add(newFi); + + } + + // Set default tree + if (!fc->GetDefaultTreeName()) + fc->SetDefaultTreeName(newFc->GetDefaultTreeName()); + + delete newFc; + + } // end loop over find commands + + delete findCmds; + if (fstg) delete fstg; + + fc->Update(); + return fc; +} + +//______________________________________________________________________________ +Bool_t TDataSetManagerAliEn::ExistsDataSet(const char *uri) +{ + TFileCollection *fc = GetDataSet(uri); + Bool_t existsNonEmpty = (fc && (fc->GetNFiles() > 0)); + if (fc) delete fc; + return existsNonEmpty; +} + +//______________________________________________________________________________ +Int_t TDataSetManagerAliEn::RegisterDataSet(const char *, TFileCollection *, + const char *) +{ + MayNotUse("RegisterDataSet"); + return -1; +} + +//______________________________________________________________________________ +TMap *TDataSetManagerAliEn::GetDataSets(const char *, UInt_t) +{ + MayNotUse("GetDataSets"); + return NULL; +} + +//______________________________________________________________________________ +void TDataSetManagerAliEn::ShowDataSets(const char *, const char *) +{ + MayNotUse("ShowDataSets"); +} + +//______________________________________________________________________________ +Bool_t TDataSetManagerAliEn::RemoveDataSet(const char *) +{ + MayNotUse("RemoveDataSet"); + return kFALSE; +} + +//______________________________________________________________________________ +Int_t TDataSetManagerAliEn::ScanDataSet(const char *, UInt_t) +{ + MayNotUse("ScanDataSet"); + return -1; +} + +//______________________________________________________________________________ +Int_t TDataSetManagerAliEn::ShowCache(const char *) +{ + MayNotUse("ShowCache"); + return -1; +} + +//______________________________________________________________________________ +Int_t TDataSetManagerAliEn::ClearCache(const char *) +{ + MayNotUse("ClearCache"); + return -1; +} diff --git a/proof/proof/src/TDataSetManagerFile.cxx b/proof/proof/src/TDataSetManagerFile.cxx index 0140129a08d90..840885feb186c 100644 --- a/proof/proof/src/TDataSetManagerFile.cxx +++ b/proof/proof/src/TDataSetManagerFile.cxx @@ -118,6 +118,29 @@ void TDataSetManagerFile::Init() return; } } + else if (fOpenPerms) { + + // Directory creation was OK: let's open permissions if requested + TString t; + Int_t rr = 0; + + t.Form("%s/%s/%s", fDataSetDir.Data(), fGroup.Data(), fUser.Data()); + rr += gSystem->Chmod(t.Data(), 0777); + + t.Form("%s/%s", fDataSetDir.Data(), fGroup.Data()); + rr += gSystem->Chmod(t.Data(), 0777); + + rr += gSystem->Chmod(fDataSetDir.Data(), 0777); + + if (rr < 0) { + t.Form("%s/%s/%s", fDataSetDir.Data(), fGroup.Data(), + fUser.Data()); + Warning("Init", + "problems setting perms of dataset directory %s (#%d)", + t.Data(), TSystem::GetErrno()); + } + + } } // If not in sandbox, construct the base URI using session defaults @@ -291,9 +314,10 @@ void TDataSetManagerFile::ParseInitOpts(const char *ins) // The <datasetdir> is mandatory. // See TDataSetManager::ParseInitOpts for the available // base options. - // The base options are laready initialized by the base constructor + // The base options are already initialized by the base constructor SetBit(TObject::kInvalidObject); + fOpenPerms = kFALSE; // Needs something in if (!ins || strlen(ins) <= 0) return; @@ -306,6 +330,8 @@ void TDataSetManagerFile::ParseInitOpts(const char *ins) fDataSetDir = tok(4, tok.Length()); if (tok.BeginsWith("mss:")) fMSSUrl = tok(4, tok.Length()); + if (tok == "perms:open") + fOpenPerms = kTRUE; } // The directory is mandatory @@ -417,6 +443,13 @@ Int_t TDataSetManagerFile::NotifyUpdate(const char *group, const char *user, } // Write off the new content mac.SaveSource(fListFile.Data()); + if (fOpenPerms) { + if (gSystem->Chmod(fListFile.Data(), 0666) < 0) { + Warning("NotifyUpdate", + "can't set permissions of dataset list file %s (#%d)", + fListFile.Data(), TSystem::GetErrno()); + } + } if (!(newMd5 = TMD5::FileChecksum(fListFile.Data()))) { Error("NotifyUpdate", "problems calculating new checksum of %s", fListFile.Data()); SafeDelete(oldMd5); @@ -492,7 +525,14 @@ Int_t TDataSetManagerFile::CreateLsFile(const char *group, const char *user, Warning("CreateLsFile", "problems setting ownership on file '%s' (errno: %d)", lsfile.Data(), TSystem::GetErrno()); } - if (chmod(lsfile.Data(), 0644) != 0) { + if (fOpenPerms) { + if (gSystem->Chmod(lsfile.Data(), 0666) < 0) { + Warning("NotifyUpdate", + "can't set permissions of list file %s (#%d)", + lsfile.Data(), TSystem::GetErrno()); + } + } + else if (chmod(lsfile.Data(), 0644) != 0) { Warning("CreateLsFile", "problems setting permissions on file '%s' (errno: %d)", lsfile.Data(), TSystem::GetErrno()); } @@ -1428,11 +1468,27 @@ Int_t TDataSetManagerFile::WriteDataSet(const char *group, const char *user, Error("WriteDataSet", "unlink of %s failed", md5path.Data()); return 0; } + else if (fOpenPerms) { + if (gSystem->Chmod(path.Data(), 0666) < 0) { + Warning("NotifyUpdate", + "can't set permissions of dataset file %s (#%d)", + path.Data(), TSystem::GetErrno()); + } + } + // Save md5 sum, otherwise the file was changed in the meanwhile and is not overwritten here if (ChecksumDataSet(path, md5path, md5sum) != 0) { Error("WriteDataSet", "problems calculating checksum of %s", path.Data()); return 0; } + else if (fOpenPerms) { + if (gSystem->Chmod(md5path.Data(), 0666) < 0) { + Warning("NotifyUpdate", + "can't set permissions of dataset MD5 checksum file %s (#%d)", + md5path.Data(), TSystem::GetErrno()); + } + } + FileStat_t st; if (gSystem->GetPathInfo(path, st) != 0) { Error("WriteDataSet", "could not 'stat' the version of '%s'!", path.Data()); @@ -1909,3 +1965,25 @@ void TDataSetManagerFile::UpdateUsedSpace() // Scan the existing datasets GetDataSets(0, 0, 0, (UInt_t)kQuotaUpdate); } + +//______________________________________________________________________________ +Long_t TDataSetManagerFile::GetModTime(const char *uri) +{ + // Gets last dataset modification time. Returns -1 on error, or number of + // seconds since epoch on success + + TString group, user, name, md5path; + if (!ParseUri(uri, &group, &user, &name)) { + return -1; + } + + TString path( GetDataSetPath(group, user, name, md5path) ); + + Long_t modTime; + if (gSystem->GetPathInfo(path.Data(), + (Long_t *)0, (Long_t *)0, (Long_t *)0, &modTime)) { + return -1; + } + + return modTime; +} diff --git a/proof/proof/src/TProof.cxx b/proof/proof/src/TProof.cxx index e49b06947c742..89aaaba907c10 100644 --- a/proof/proof/src/TProof.cxx +++ b/proof/proof/src/TProof.cxx @@ -63,6 +63,7 @@ #include "TParameter.h" #include "TProof.h" #include "TProofNodeInfo.h" +#include "TProofOutputFile.h" #include "TVirtualProofPlayer.h" #include "TVirtualPacketizer.h" #include "TProofServ.h" @@ -81,8 +82,10 @@ #include "TUrl.h" #include "TFileCollection.h" #include "TDataSetManager.h" +#include "TDataSetManagerFile.h" #include "TMacro.h" #include "TSelector.h" +#include "TPRegexp.h" TProof *gProof = 0; TVirtualMutex *gProofMutex = 0; @@ -101,7 +104,7 @@ Bool_t TProofInterruptHandler::Notify() { // TProof interrupt handler. - if (isatty(0) == 0 || isatty(1) == 0 || fProof->GetRemoteProtocol() < 22) { + if (!fProof->IsTty() || fProof->GetRemoteProtocol() < 22) { // Cannot ask the user : abort any remote processing fProof->StopProcess(kTRUE); @@ -110,7 +113,7 @@ Bool_t TProofInterruptHandler::Notify() // Real stop or request to switch to asynchronous? const char *a = 0; if (fProof->GetRemoteProtocol() < 22) { - a = Getline("\nSwith to asynchronous mode not supported remotely:" + a = Getline("\nSwitch to asynchronous mode not supported remotely:" "\nEnter S/s to stop, Q/q to quit, any other key to continue: "); } else { a = Getline("\nEnter A/a to switch asynchronous, S/s to stop, Q/q to quit," @@ -184,6 +187,17 @@ Int_t TSlaveInfo::Compare(const TObject *obj) const return 0; } +//______________________________________________________________________________ +Bool_t TSlaveInfo::IsEqual(const TObject* obj) const +{ + // Used to compare slaveinfos by ordinal. + + if (!obj) return kFALSE; + const TSlaveInfo *si = dynamic_cast<const TSlaveInfo*>(obj); + if (!si) return kFALSE; + return (strcmp(GetOrdinal(), si->GetOrdinal()) == 0); +} + //______________________________________________________________________________ void TSlaveInfo::Print(Option_t *opt) const { @@ -357,7 +371,7 @@ TProof::TProof(const char *masterurl, const char *conffile, const char *confdir, // file and other PROOF related files are (like motd and noproof files). // Loglevel is the log level (default = 1). User specified custom config // files will be first looked for in $HOME/.conffile. - + // Default initializations InitMembers(); @@ -386,16 +400,6 @@ TProof::TProof(const char *masterurl, const char *conffile, const char *confdir, if (fUrl.GetPort() == TUrl(" ").GetPort()) fUrl.SetPort(TUrl("proof:// ").GetPort()); - // User - if (strlen(fUrl.GetUser()) <= 0) { - // Get user logon name - UserGroup_t *pw = gSystem->GetUserInfo(); - if (pw) { - fUrl.SetUser(pw->fUser); - delete pw; - } - } - // Make sure to store the FQDN, so to get a solid reference for subsequent checks if (!strcmp(fUrl.GetHost(), "__master__")) fMaster = fUrl.GetHost(); @@ -434,9 +438,37 @@ TProof::TProof(const char *masterurl, const char *conffile, const char *confdir, // Flag that we are a client if (TestBit(TProof::kIsClient)) if (!gSystem->Getenv("ROOTPROOFCLIENT")) gSystem->Setenv("ROOTPROOFCLIENT",""); - + Init(masterurl, conffile, confdir, loglevel, alias); + // If the user was not set, get it from the master + if (strlen(fUrl.GetUser()) <= 0) { + TString usr, emsg; + if (Exec("gProofServ->GetUser()", "0", kTRUE) == 0) { + TObjString *os = fMacroLog.GetLineWith("const char"); + if (os) { + Ssiz_t fst = os->GetString().First('\"'); + Ssiz_t lst = os->GetString().Last('\"'); + usr = os->GetString()(fst+1, lst-fst-1); + } else { + emsg = "could not find 'const char *' string in macro log"; + } + } else { + emsg = "could not retrieve user info"; + } + if (!emsg.IsNull()) { + // Get user logon name + UserGroup_t *pw = gSystem->GetUserInfo(); + if (pw) { + usr = pw->fUser; + delete pw; + } + Warning("TProof", "%s: using local default %s", emsg.Data(), usr.Data()); + } + // Set the user name in the main URL + fUrl.SetUser(usr.Data()); + } + // If called by a manager, make sure it stays in last position // for cleaning if (mgr) { @@ -479,10 +511,13 @@ void TProof::InitMembers() // Default initializations fValid = kFALSE; + fTty = kFALSE; fRecvMessages = 0; fSlaveInfo = 0; fMasterServ = kFALSE; fSendGroupView = kFALSE; + fIsPollingWorkers = kFALSE; + fLastPollWorkers_s = -1; fActiveSlaves = 0; fInactiveSlaves = 0; fUniqueSlaves = 0; @@ -511,6 +546,8 @@ void TProof::InitMembers() fLogFileW = 0; fLogFileR = 0; fLogToWindowOnly = kFALSE; + fSaveLogToMacro = kFALSE; + fMacroLog.SetName("ProofLogMacro"); fWaitingSlaves = 0; fQueries = 0; @@ -534,6 +571,7 @@ void TProof::InitMembers() fProtocol = -1; fSlaves = 0; + fTerminatedSlaveInfos = 0; fBadSlaves = 0; fAllMonitor = 0; fDataReady = kFALSE; @@ -561,6 +599,8 @@ void TProof::InitMembers() fPerfTree = ""; + fWrksOutputReady = 0; + fSelector = 0; // Check if the user defined a list of environment variables to send over: @@ -628,6 +668,7 @@ TProof::~TProof() SafeDelete(fUniqueSlaves); SafeDelete(fAllUniqueSlaves); SafeDelete(fNonUniqueMasters); + SafeDelete(fTerminatedSlaveInfos); SafeDelete(fBadSlaves); SafeDelete(fAllMonitor); SafeDelete(fActiveMonitor); @@ -648,6 +689,10 @@ TProof::~TProof() SafeDelete(fInputData); SafeDelete(fRunningDSets); SafeDelete(fCloseMutex); + if (fWrksOutputReady) { + fWrksOutputReady->SetOwner(kFALSE); + delete fWrksOutputReady; + } // remove file with redirected logs if (TestBit(TProof::kIsClient)) { @@ -694,6 +739,9 @@ Int_t TProof::Init(const char *, const char *conffile, fValid = kFALSE; + // Connected to terminal? + fTty = (isatty(0) == 0 || isatty(1) == 0) ? kFALSE : kTRUE; + // If in attach mode, options is filled with additional info Bool_t attach = kFALSE; if (strlen(fUrl.GetOptions()) > 0) { @@ -820,6 +868,9 @@ Int_t TProof::Init(const char *, const char *conffile, fAllUniqueMonitor = new TMonitor; fCurrentMonitor = 0; + fTerminatedSlaveInfos = new TList; + fTerminatedSlaveInfos->SetOwner(kTRUE); + fPackageLock = 0; fEnabledPackagesOnClient = 0; fLoadedMacros = 0; @@ -832,7 +883,7 @@ Int_t TProof::Init(const char *, const char *conffile, if (enableSchemaEvolution) { TMessage::EnableSchemaEvolutionForAll(); } else { - Info("TProof", "automatic schema evolution in TMessage explicitely disabled"); + Info("TProof", "automatic schema evolution in TMessage explicitly disabled"); } if (IsMaster()) { @@ -864,6 +915,7 @@ Int_t TProof::Init(const char *, const char *conffile, Int_t from = 0; TString ldir; while (globpack.Tokenize(ldir, from, ":")) { + TProofServ::ResolveKeywords(ldir); if (gSystem->AccessPathName(ldir, kReadPermission)) { Warning("Init", "directory for global packages %s does not" " exist or is not readable", ldir.Data()); @@ -905,6 +957,12 @@ Int_t TProof::Init(const char *, const char *conffile, // Start slaves (the old, static, per-session way) if (!StartSlaves(attach)) return 0; + // Client: Is Master in dynamic startup mode? + if (!IsMaster()) { + Int_t dyn; + GetRC("Proof.DynamicStartup", dyn); + if (dyn != 0) fDynamicStartup = kTRUE; + } } } @@ -918,7 +976,14 @@ Int_t TProof::Init(const char *, const char *conffile, fAllMonitor->DeActivateAll(); // By default go into parallel mode - GoParallel(9999, attach); + Int_t nwrk = GetRemoteProtocol() > 35 ? -1 : 9999; + TNamed *n = 0; + if (TProof::GetEnvVars() && + (n = (TNamed *) TProof::GetEnvVars()->FindObject("PROOF_NWORKERS"))) { + TString s(n->GetTitle()); + if (s.IsDigit()) nwrk = s.Atoi(); + } + GoParallel(nwrk, attach); // Send relevant initial state to slaves if (!attach) @@ -1039,7 +1104,7 @@ void TProof::ParseConfigField(const char *config) // Check if we have to add a var if (wrk == "" || wrk.BeginsWith("valgrind_opts:")) { wrk.ReplaceAll("valgrind_opts:",""); - var.Form("%s --log-file=<logfilewrk>.valgrind.log %s%s", cmd.Data(), wrk.Data(), cq); + var.Form("%s --log-file=<logfilewrk>.__valgrind__.log %s%s", cmd.Data(), wrk.Data(), cq); TProof::AddEnvVar("PROOF_SLAVE_WRAPPERCMD", var); TString nwrks("2"); Int_t inw = opt.Index('#'); @@ -1055,8 +1120,8 @@ void TProof::ParseConfigField(const char *config) } wrklab = nwrks; // Register the additional worker log in the session file - // (for the master is done automatically) - TProof::AddEnvVar("PROOF_ADDITIONALLOG", "valgrind.log*"); + // (for the master this is done automatically) + TProof::AddEnvVar("PROOF_ADDITIONALLOG", "__valgrind__.log*"); } else if (wrk != "") { wrklab = "ALL"; } @@ -1080,12 +1145,36 @@ void TProof::ParseConfigField(const char *config) Printf(" ---> (Reminder: this debug run makes sense only if you are running a debug version of ROOT)"); Printf(" "); + } else if (opt.BeginsWith("igprof-pp")) { + + // IgProf profiling on master and worker. PROOF does not set the + // environment for you: proper environment variables (like PATH and + // LD_LIBRARY_PATH) should be set externally + + Printf("*** Requested IgProf performance profiling ***"); + TString addLogExt = "__igprof.pp__.log"; + TString addLogFmt = "igprof -pk -pp -t proofserv.exe -o %s.%s"; + TString tmp; + + if (IsLite()) { + addLogFmt.Append("\""); + addLogFmt.Prepend("\""); + } + + tmp.Form(addLogFmt.Data(), "<logfilemst>", addLogExt.Data()); + TProof::AddEnvVar("PROOF_MASTER_WRAPPERCMD", tmp.Data()); + + tmp.Form(addLogFmt.Data(), "<logfilewrk>", addLogExt.Data()); + TProof::AddEnvVar("PROOF_SLAVE_WRAPPERCMD", tmp.Data() ); + + TProof::AddEnvVar("PROOF_ADDITIONALLOG", addLogExt.Data()); + } else if (opt.BeginsWith("workers=")) { // Request for a given number of workers (within the max) or worker // startup combination: // workers=5 start max 5 workers (or less, if less are assigned) - // workers=2x start max 2 workers (or less, if less are assigned) + // workers=2x start max 2 workers per node (or less, if less are assigned) opt.ReplaceAll("workers=",""); TProof::AddEnvVar("PROOF_NWORKERS", opt); } @@ -1170,7 +1259,8 @@ Int_t TProof::AddWorkers(TList *workerList) UInt_t nSlavesDone = 0; Int_t ord = 0; - // Loop over all workers and start them + // Loop over all new workers and start them + Bool_t goMoreParallel = (fSlaves->GetEntries() > 0); // a list of TSlave objects for workers that are being added TList *addedWorkers = new TList(); @@ -1183,6 +1273,7 @@ Int_t TProof::AddWorkers(TList *workerList) TListIter next(workerList); TObject *to; TProofNodeInfo *worker; + TSlaveInfo *dummysi = new TSlaveInfo(); while ((to = next())) { // Get the next worker from the list worker = (TProofNodeInfo *)to; @@ -1203,6 +1294,11 @@ Int_t TProof::AddWorkers(TList *workerList) fullord.Form("%s.%d", gProofServ->GetOrdinal(), ord); } + // Remove worker from the list of workers terminated gracefully + dummysi->SetOrdinal(fullord); + TSlaveInfo *rmsi = (TSlaveInfo *)fTerminatedSlaveInfos->Remove(dummysi); + if (rmsi) SafeDelete(rmsi); + // Create worker server TString wn(worker->GetNodeName()); if (wn == "localhost" || wn.BeginsWith("localhost.")) wn = gSystem->HostName(); @@ -1220,8 +1316,8 @@ Int_t TProof::AddWorkers(TList *workerList) // Add to global list (we will add to the monitor list after // finalizing the server startup) Bool_t slaveOk = kTRUE; + fSlaves->Add(slave); if (slave->IsValid()) { - fSlaves->Add(slave); addedWorkers->Add(slave); } else { slaveOk = kFALSE; @@ -1242,6 +1338,7 @@ Int_t TProof::AddWorkers(TList *workerList) ord++; } //end of the worker loop + SafeDelete(dummysi); // Cleanup SafeDelete(workerList); @@ -1279,27 +1376,59 @@ Int_t TProof::AddWorkers(TList *workerList) // use fEnabledPackages, fLoadedMacros, // gSystem->GetDynamicPath() and gSystem->GetIncludePath() // no need to load packages that are only loaded and not enabled (dyn mode) + Int_t nwrk = GetRemoteProtocol() > 35 ? -1 : 9999; + TNamed *n = 0; + if (TProof::GetEnvVars() && + (n = (TNamed *) TProof::GetEnvVars()->FindObject("PROOF_NWORKERS"))) { + TString s(n->GetTitle()); + if (s.IsDigit()) nwrk = s.Atoi(); + } - SetParallel(99999, 0); + if (fDynamicStartup && goMoreParallel) { - TList *tmpEnabledPackages = gProofServ->GetEnabledPackages(); + PDB(kGlobal, 3) + Info("AddWorkers", "Will invoke GoMoreParallel()"); + Int_t nw = GoMoreParallel(nwrk); + PDB(kGlobal, 3) + Info("AddWorkers", "GoMoreParallel()=%d", nw); - if (tmpEnabledPackages && tmpEnabledPackages->GetSize() > 0) { - TIter nxp(tmpEnabledPackages); - TObjString *os = 0; - while ((os = (TObjString *) nxp())) { + } + else { + // Not in Dynamic Workers mode + PDB(kGlobal, 3) + Info("AddWorkers", "Will invoke GoParallel()"); + GoParallel(nwrk, kFALSE, 0); + } + + if (gProofServ && gProofServ->GetEnabledPackages() && + gProofServ->GetEnabledPackages()->GetSize() > 0) { + TIter nxp(gProofServ->GetEnabledPackages()); + TPair *pck = 0; + while ((pck = (TPair *) nxp())) { // Upload and Enable methods are intelligent and avoid // re-uploading or re-enabling of a package to a node that has it. - if (UploadPackage(os->GetName()) >= 0) - EnablePackage(os->GetName(), (TList *)0, kTRUE); + if (fDynamicStartup && goMoreParallel) { + // Upload only on added workers + PDB(kGlobal, 3) + Info("AddWorkers", "Will invoke UploadPackage() and EnablePackage() on added workers"); + if (UploadPackage(pck->GetName(), kUntar, addedWorkers) >= 0) + EnablePackage(pck->GetName(), (TList *) pck->Value(), kTRUE, addedWorkers); + } + else { + PDB(kGlobal, 3) + Info("AddWorkers", "Will invoke UploadPackage() and EnablePackage() on all workers"); + if (UploadPackage(pck->GetName()) >= 0) + EnablePackage(pck->GetName(), (TList *) pck->Value(), kTRUE); + } } } - if (fLoadedMacros) { TIter nxp(fLoadedMacros); TObjString *os = 0; while ((os = (TObjString *) nxp())) { + PDB(kGlobal, 3) + Info("AddWorkers", "Will invoke Load() on selected workers"); Printf("Loading a macro : %s", os->GetName()); Load(os->GetName(), kTRUE, kTRUE, addedWorkers); } @@ -1308,19 +1437,41 @@ Int_t TProof::AddWorkers(TList *workerList) TString dyn = gSystem->GetDynamicPath(); dyn.ReplaceAll(":", " "); dyn.ReplaceAll("\"", " "); - AddDynamicPath(dyn, kFALSE, addedWorkers); + PDB(kGlobal, 3) + Info("AddWorkers", "Will invoke AddDynamicPath() on selected workers"); + AddDynamicPath(dyn, kFALSE, addedWorkers, fDynamicStartup); + TString inc = gSystem->GetIncludePath(); inc.ReplaceAll("-I", " "); inc.ReplaceAll("\"", " "); - AddIncludePath(inc, kFALSE, addedWorkers); + PDB(kGlobal, 3) + Info("AddWorkers", "Will invoke AddIncludePath() on selected workers"); + AddIncludePath(inc, kFALSE, addedWorkers, fDynamicStartup); + + // Update list of current workers + PDB(kGlobal, 3) + Info("AddWorkers", "Will invoke SaveWorkerInfo()"); + SaveWorkerInfo(); + + // Inform the client that the number of workers has changed + if (fDynamicStartup && gProofServ) { + PDB(kGlobal, 3) + Info("AddWorkers", "Will invoke SendParallel()"); + gProofServ->SendParallel(kTRUE); + + if (goMoreParallel && fPlayer) { + // In case we are adding workers dynamically to an existing process, we + // should invoke a special player's Process() to set only added workers + // to the proper state + PDB(kGlobal, 3) + Info("AddWorkers", "Will send the PROCESS message to selected workers"); + fPlayer->JoinProcess(addedWorkers); + } + } // Cleanup delete addedWorkers; - // Inform the client that the number of workers is changed - if (fDynamicStartup && gProofServ) - gProofServ->SendParallel(kTRUE); - return 0; } @@ -2488,6 +2639,13 @@ Int_t TProof::Collect(TMonitor *mon, Long_t timeout, Int_t endtype, Bool_t deact // If timeout >= 0, wait at most timeout seconds (timeout = -1 by default, // which means wait forever). // If defined (>= 0) endtype is the message that stops this collection. + // Collect also stops its execution from time to time to check for new + // workers in Dynamic Startup mode. + + Int_t collectId = gRandom->Integer(9999); + + PDB(kCollect, 3) + Info("Collect", ">>>>>> Entering collect responses #%04d", collectId); // Reset the status flag and clear the messages in the list, if any fStatus = 0; @@ -2555,7 +2713,19 @@ Int_t TProof::Collect(TMonitor *mon, Long_t timeout, Int_t endtype, Bool_t deact } } + // Preemptive poll for new workers on the master only in Dynamic Mode and only + // during processing (TODO: should work on Top Master only) + if (TestBit(TProof::kIsMaster) && !IsIdle() && fDynamicStartup && !fIsPollingWorkers && + ((fLastPollWorkers_s == -1) || (time(0)-fLastPollWorkers_s >= kPROOF_DynWrkPollInt_s))) { + fIsPollingWorkers = kTRUE; + PollForNewWorkers(); + fLastPollWorkers_s = time(0); + fIsPollingWorkers = kFALSE; + } + // Wait for a ready socket + PDB(kCollect, 3) + Info("Collect", "Will invoke Select() #%04d", collectId); TSocket *s = mon->Select(1000); if (s && s != (TSocket *)(-1)) { @@ -2594,13 +2764,41 @@ Int_t TProof::Collect(TMonitor *mon, Long_t timeout, Int_t endtype, Bool_t deact if (s == (TSocket *)(-1) && nto > 0) nto--; } + + // Check if there are workers with ready output to be sent and ask the first to send it + if (IsMaster() && fWrksOutputReady && fWrksOutputReady->GetSize() > 0) { + // Maximum number of concurrent sendings + Int_t mxws = gEnv->GetValue("Proof.ControlSendOutput", 1); + if (TProof::GetParameter(fPlayer->GetInputList(), "PROOF_ControlSendOutput", mxws) != 0) + mxws = gEnv->GetValue("Proof.ControlSendOutput", 1); + TIter nxwr(fWrksOutputReady); + TSlave *wrk = 0; + while (mxws && (wrk = (TSlave *) nxwr())) { + if (!wrk->TestBit(TSlave::kOutputRequested)) { + // Ask worker for output + TMessage sendoutput(kPROOF_SENDOUTPUT); + PDB(kCollect, 2) + Info("Collect", "worker %s was asked to send its output to master", + wrk->GetOrdinal()); + if (wrk->GetSocket()->Send(sendoutput) != 1) { + wrk->SetBit(TSlave::kOutputRequested); + mxws--; + } + } else { + // Count + mxws--; + } + } + } + // Check if we need to check the socket activity (we do it every 10 cycles ~ 10 sec) sto = -1; if (--nsto <= 0) { sto = (Long_t) actto; nsto = 60; } - } + + } // end loop over active monitors // If timed-out, deactivate the remaining sockets if (nto == 0) { @@ -2637,9 +2835,89 @@ Int_t TProof::Collect(TMonitor *mon, Long_t timeout, Int_t endtype, Bool_t deact ActivateAsyncInput(); + PDB(kCollect, 3) + Info("Collect", "<<<<<< Exiting collect responses #%04d", collectId); + return cnt; } +//______________________________________________________________________________ +Int_t TProof::PollForNewWorkers() +{ + // Asks the PROOF Serv for new workers in Dynamic Startup mode and activates + // them. Returns the number of new workers found, or <0 on errors. + + // Requests for worker updates + Int_t dummy = 0; + TList *reqWorkers = new TList(); + reqWorkers->SetOwner(kFALSE); + + if (!TestBit(TProof::kIsMaster)) { + Error("PollForNewWorkers", "Can't invoke: not on a master -- should not happen!"); + return -1; + } + if (!gProofServ) { + Error("PollForNewWorkers", "No ProofServ available -- should not happen!"); + return -1; + } + + gProofServ->GetWorkers(reqWorkers, dummy, kTRUE); // last 2 are dummy + + // List of new workers only (TProofNodeInfo) + TList *newWorkers = new TList(); + newWorkers->SetOwner(kTRUE); + + TIter next(reqWorkers); + TProofNodeInfo *ni; + TString fullOrd; + while (( ni = dynamic_cast<TProofNodeInfo *>(next()) )) { + + // Form the full ordinal + fullOrd.Form("%s.%s", gProofServ->GetOrdinal(), ni->GetOrdinal().Data()); + + TIter nextInner(fSlaves); + TSlave *sl; + Bool_t found = kFALSE; + while (( sl = dynamic_cast<TSlave *>(nextInner()) )) { + if ( strcmp(sl->GetOrdinal(), fullOrd.Data()) == 0 ) { + found = kTRUE; + break; + } + } + + if (found) delete ni; + else { + newWorkers->Add(ni); + PDB(kGlobal, 1) + Info("PollForNewWorkers", "New worker found: %s:%s", + ni->GetNodeName().Data(), fullOrd.Data()); + } + } + + delete reqWorkers; // not owner + + Int_t nNewWorkers = newWorkers->GetEntries(); + + // Add the new workers + if (nNewWorkers > 0) { + PDB(kGlobal, 1) + Info("PollForNewWorkers", "Requesting to add %d new worker(s)", newWorkers->GetEntries()); + Int_t rv = AddWorkers(newWorkers); + if (rv < 0) { + Error("PollForNewWorkers", "Call to AddWorkers() failed (got %d < 0)", rv); + return -1; + } + // Don't delete newWorkers: AddWorkers() will do that + } + else { + PDB(kGlobal, 2) + Info("PollForNewWorkers", "No new worker found"); + delete newWorkers; + } + + return nNewWorkers; +} + //______________________________________________________________________________ void TProof::CleanGDirectory(TList *ol) { @@ -2843,6 +3121,11 @@ Int_t TProof::HandleInputMessage(TSlave *sl, TMessage *mess, Bool_t deactonfail) // Deactivate the worker, if required if (deactonfail) DeactivateWorker(sl->fOrdinal); } + // Remove from the workers-ready list + if (fWrksOutputReady && fWrksOutputReady->FindObject(sl)) { + sl->ResetBit(TSlave::kOutputRequested); + fWrksOutputReady->Remove(sl); + } rc = 1; break; @@ -2933,6 +3216,20 @@ Int_t TProof::HandleInputMessage(TSlave *sl, TMessage *mess, Bool_t deactonfail) } break; + case kPROOF_SENDOUTPUT: + { // Worker is ready to send output: make sure the relevant bit is reset + sl->ResetBit(TSlave::kOutputRequested); + PDB(kGlobal,2) + Info("HandleInputMessage","kPROOF_SENDOUTPUT: enter (%s)", sl->GetOrdinal()); + // Create the list if not yet done + if (!fWrksOutputReady) { + fWrksOutputReady = new TList; + fWrksOutputReady->SetOwner(kFALSE); + } + fWrksOutputReady->Add(sl); + } + break; + case kPROOF_OUTPUTOBJECT: { PDB(kGlobal,2) @@ -2974,11 +3271,13 @@ Int_t TProof::HandleInputMessage(TSlave *sl, TMessage *mess, Bool_t deactonfail) // Increment counter on the client side fMergePrg.IncreaseIdx(); TString msg; - msg.Form("%s: merging output objects ... %s", prefix, fMergePrg.Export()); - if (gProofServ) + Bool_t changed = kFALSE; + msg.Form("%s: merging output objects ... %s", prefix, fMergePrg.Export(changed)); + if (gProofServ) { gProofServ->SendAsynMessage(msg.Data(), kFALSE); - else + } else if (IsTty() || changed) { fprintf(stderr, "%s\r", msg.Data()); + } // Add or merge it if ((fPlayer->AddOutputObject(o) == 1)) { // Remove the object if it has been merged @@ -3050,7 +3349,7 @@ Int_t TProof::HandleInputMessage(TSlave *sl, TMessage *mess, Bool_t deactonfail) } else { PDB(kGlobal,2) Info("HandleInputMessage", - "%s: kPROOF_OUTPUTLIST: ouputlist is empty", sl->GetOrdinal()); + "%s: kPROOF_OUTPUTLIST: outputlist is empty", sl->GetOrdinal()); } } else { Warning("HandleInputMessage", @@ -3288,9 +3587,15 @@ Int_t TProof::HandleInputMessage(TSlave *sl, TMessage *mess, Bool_t deactonfail) SetName(stag); // In the TSlave object sl->SetSessionTag(stag); - // New servers send also the group + // Server may have also sent the group if ((mess->BufferSize() > mess->Length())) (*mess) >> fGroup; + // Server may have also sent the user + if ((mess->BufferSize() > mess->Length())) { + TString usr; + (*mess) >> usr; + if (!usr.IsNull()) fUrl.SetUser(usr.Data()); + } } break; @@ -4018,8 +4323,8 @@ Bool_t TProof::CreateMerger(TSlave *sl, Int_t port) workers = (fWorkersToMerge / mergersToCreate) + rest; } else { Int_t workersOnHost = 0; - for (Int_t i = 0; i < fSlaves->GetSize(); i++) { - if(!strcmp(sl->GetName(), fSlaves->At(i)->GetName())) workersOnHost++; + for (Int_t i = 0; i < fActiveSlaves->GetSize(); i++) { + if(!strcmp(sl->GetName(), fActiveSlaves->At(i)->GetName())) workersOnHost++; } workers = workersOnHost - 1; } @@ -4169,6 +4474,16 @@ void TProof::MarkBad(TSlave *wrk, const char *reason) fUniqueSlaves->Remove(wrk); fAllUniqueSlaves->Remove(wrk); fNonUniqueMasters->Remove(wrk); + + // we add it to the list of terminated slave infos instead, so that it + // stays available in the .workers persistent file + TSlaveInfo *si = new TSlaveInfo( + wrk->GetOrdinal(), + Form("%s@%s:%d", wrk->GetUser(), wrk->GetName(), wrk->GetPort()), + 0, "", wrk->GetWorkDir()); + if (!fTerminatedSlaveInfos->Contains(si)) fTerminatedSlaveInfos->Add(si); + else delete si; + delete wrk; } else { fBadSlaves->Add(wrk); @@ -4428,6 +4743,327 @@ void TProof::Print(Option_t *option) const } } +//______________________________________________________________________________ +Int_t TProof::HandleOutputOptions(TString &opt, TString &target, Int_t action) +{ + // Extract from opt information about output handling settings. + // The understood keywords are: + // of=<file>, outfile=<file> output file location + // ds=<dsname>, dataset=<dsname> dataset name ('of' and 'ds' are + // mutually exclusive,execution stops + // if both are found) + // sft[=<opt>], savetofile[=<opt>] control saving to file + // + // For 'mvf', the <opt> integer has the following meaning: + // <opt> = <how>*10 + <force> + // <force> = 0 save to file if memory threshold is reached + // (the memory threshold is set by the cluster + // admin); in case an output file is defined, the + // files are merged at the end; + // 1 save results to file. + // <how> = 0 save at the end of the query + // 1 save results after each packet (to reduce the + // loss in case of crash). + // + // Setting 'ds' automatically sets 'mvf=1'; it is still possible to set 'mvf=11' + // to save results after each packet. + // + // The separator from the next option is either a ' ' or a ';' + // + // All recognized settings are removed from the input string opt. + // If action == 0, set up the output file accordingly, if action == 1 clean related + // output file settings. + // If the final target file is local then 'target' is set to the final local path + // when action == 0 and used to retrieve the file with TFile::Cp when action == 1. + // + // Output file settings are in the form + // + // <previous_option>of=name <next_option> + // <previous_option>outfile=name,...;<next_option> + // + // The separator from the next option is either a ' ' or a ';' + // Called interanally by TProof::Process. + // + // Returns 0 on success, -1 on error. + + TString outfile, dsname, stfopt; + if (action == 0) { + TString tagf, tagd, tags, oo; + Ssiz_t from = 0, iof = kNPOS, iod = kNPOS, ios = kNPOS; + while (opt.Tokenize(oo, from, "[; ]")) { + if (oo.BeginsWith("of=")) { + tagf = "of="; + iof = opt.Index(tagf); + } else if (oo.BeginsWith("outfile=")) { + tagf = "outfile="; + iof = opt.Index(tagf); + } else if (oo.BeginsWith("ds")) { + tagd = "ds"; + iod = opt.Index(tagd); + } else if (oo.BeginsWith("dataset")) { + tagd = "dataset"; + iod = opt.Index(tagd); + } else if (oo.BeginsWith("stf")) { + tags = "stf"; + ios = opt.Index(tags); + } else if (oo.BeginsWith("savetofile")) { + tags = "savetofile"; + ios = opt.Index(tags); + } + } + // Check consistency + if (iof != kNPOS && iod != kNPOS) { + Error("HandleOutputOptions", "options 'of'/'outfile' and 'ds'/'dataset' are incompatible!"); + return -1; + } + + // Check output file first + if (iof != kNPOS) { + from = iof + tagf.Length(); + if (!opt.Tokenize(outfile, from, "[; ]") || outfile.IsNull()) { + Error("HandleOutputOptions", "could not extract output file settings string! (%s)", opt.Data()); + return -1; + } + // For removal from original options string + tagf += outfile; + } + // Check dataset + if (iod != kNPOS) { + from = iod + tagd.Length(); + if (!opt.Tokenize(dsname, from, "[; ]")) + if (gDebug > 0) Info("HandleOutputOptions", "no dataset name found: use default"); + // For removal from original options string + tagd += dsname; + // The name may be empty or beginning with a '=' + if (dsname.BeginsWith("=")) dsname.Replace(0, 1, ""); + if (dsname.Contains("|V")) { + target = "ds|V"; + dsname.ReplaceAll("|V", ""); + } + if (dsname.IsNull()) dsname = "dataset_<qtag>"; + } + // Check stf + if (ios != kNPOS) { + from = ios + tags.Length(); + if (!opt.Tokenize(stfopt, from, "[; ]")) + if (gDebug > 0) Info("HandleOutputOptions", "save-to-file not found: use defualt"); + // For removal from original options string + tags += stfopt; + // It must be digit + if (!stfopt.IsNull()) { + if (stfopt.BeginsWith("=")) stfopt.Replace(0,1,""); + if (!stfopt.IsNull()) { + if (!stfopt.IsDigit()) { + Error("HandleOutputOptions", "save-to-file option must be a digit! (%s)", stfopt.Data()); + return -1; + } + } else { + // Default + stfopt = "1"; + } + } else { + // Default + stfopt = "1"; + } + } + // Remove from original options string + opt.ReplaceAll(tagf, ""); + opt.ReplaceAll(tagd, ""); + opt.ReplaceAll(tags, ""); + } + + // Parse now + if (action == 0) { + // Output file + if (!outfile.IsNull()) { + if (!outfile.BeginsWith("master:")) { + if (gSystem->AccessPathName(gSystem->DirName(outfile.Data()), kWritePermission)) { + Warning("HandleOutputOptions", + "directory '%s' for the output file does not exists or is not writable:" + " saving to master", gSystem->DirName(outfile.Data())); + outfile.Form("master:%s", gSystem->BaseName(outfile.Data())); + } else { + if (!IsLite()) { + // The target file is local, so we need to retrieve it + target = outfile; + if (!stfopt.IsNull()) { + outfile.Form("master:%s", gSystem->BaseName(target.Data())); + } else { + outfile = ""; + } + } + } + } + if (outfile.BeginsWith("master:")) { + outfile.ReplaceAll("master:", ""); + if (outfile.IsNull() || !gSystem->IsAbsoluteFileName(outfile)) { + // Get the master data dir + TString ddir, emsg; + if (!IsLite()) { + if (Exec("gProofServ->GetDataDir()", "0", kTRUE) == 0) { + TObjString *os = fMacroLog.GetLineWith("const char"); + if (os) { + Ssiz_t fst = os->GetString().First('\"'); + Ssiz_t lst = os->GetString().Last('\"'); + ddir = os->GetString()(fst+1, lst-fst-1); + } else { + emsg = "could not find 'const char *' string in macro log! cannot continue"; + } + } else { + emsg = "could not retrieve master data directory info! cannot continue"; + } + if (!emsg.IsNull()) { + Error("HandleOutputOptions", "%s", emsg.Data()); + return -1; + } + } + if (!ddir.IsNull()) ddir += "/"; + if (outfile.IsNull()) { + outfile.Form("%s<file>", ddir.Data()); + } else { + outfile.Insert(0, TString::Format("%s", ddir.Data())); + } + } + } + // Set the parameter + if (!outfile.IsNull()) { + if (!outfile.BeginsWith("of:")) outfile.Insert(0, "of:"); + SetParameter("PROOF_DefaultOutputOption", outfile.Data()); + } + } + // Dataset creation + if (!dsname.IsNull()) { + dsname.Insert(0, "ds:"); + // Set the parameter + SetParameter("PROOF_DefaultOutputOption", dsname.Data()); + // Check the Save-To-File option + if (!stfopt.IsNull()) { + Int_t ostf = (Int_t) stfopt.Atoi(); + if (ostf%10 <= 0) { + Warning("HandleOutputOptions", "Dataset required bu Save-To-File disabled: enabling!"); + stfopt.Form("%d", ostf+1); + } + } else { + // Minimal setting + stfopt = "1"; + } + } + // Save-To-File options + if (!stfopt.IsNull()) { + // Set the parameter + SetParameter("PROOF_SavePartialResults", (Int_t) stfopt.Atoi()); + } + } else { + // Retrieve the file, if required + if (GetOutputList()) { + if (target == "ds|V") { + // Find the dataset + dsname = ""; + TIter nxo(GetOutputList()); + TObject *o = 0; + while ((o = nxo())) { + if (o->InheritsFrom(TFileCollection::Class())) { + VerifyDataSet(o->GetName()); + dsname = o->GetName(); + break; + } + } + if (!dsname.IsNull()) { + TFileCollection *fc = GetDataSet(dsname); + if (fc) { + fc->Print(); + } else { + Warning("HandleOutputOptions", "could not retrieve TFileCollection for dataset '%s'", dsname.Data()); + } + } else { + Warning("HandleOutputOptions", "dataset not found!"); + } + } else { + Bool_t targetcopied = kFALSE; + TProofOutputFile *pf = 0; + if (!target.IsNull()) + pf = (TProofOutputFile *) GetOutputList()->FindObject(gSystem->BaseName(target.Data())); + if (pf) { + // Copy the file + if (strcmp(TUrl(pf->GetOutputFileName(), kTRUE).GetUrl(), + TUrl(target, kTRUE).GetUrl())) { + if (TFile::Cp(pf->GetOutputFileName(), target)) { + Printf(" Output successfully copied to %s", target.Data()); + targetcopied = kTRUE; + } else { + Warning("HandleOutputOptions", "problems copying output to %s", target.Data()); + } + } + } + TFile *fout = 0; + TObject *o = 0; + TIter nxo(GetOutputList()); + Bool_t swapcopied = kFALSE; + while ((o = nxo())) { + TProofOutputFile *pof = dynamic_cast<TProofOutputFile *>(o); + if (pof) { + if (pof->TestBit(TProofOutputFile::kSwapFile) && !target.IsNull()) { + if (pof == pf && targetcopied) continue; + // Copy the file + if (strcmp(TUrl(pf->GetOutputFileName(), kTRUE).GetUrl(), + TUrl(target, kTRUE).GetUrl())) { + if (TFile::Cp(pof->GetOutputFileName(), target)) { + Printf(" Output successfully copied to %s", target.Data()); + swapcopied = kTRUE; + } else { + Warning("HandleOutputOptions", "problems copying output to %s", target.Data()); + } + } + } else if (pof->IsRetrieve()) { + // Retrieve this file to the local path indicated in the title + if (strcmp(TUrl(pf->GetOutputFileName(), kTRUE).GetUrl(), + TUrl(pof->GetTitle(), kTRUE).GetUrl())) { + if (TFile::Cp(pof->GetOutputFileName(), pof->GetTitle())) { + Printf(" Output successfully copied to %s", pof->GetTitle()); + } else { + Warning("HandleOutputOptions", + "problems copying %s to %s", pof->GetOutputFileName(), pof->GetTitle()); + } + } + } + } + } + if (!target.IsNull() && !swapcopied) { + if (!fout && !pf) { + fout = TFile::Open(target, "RECREATE"); + if (!fout || (fout && fout->IsZombie())) { + SafeDelete(fout); + Warning("HandleOutputOptions", "problems opening output file %s", target.Data()); + } + } + if (fout) { + nxo.Reset(); + while ((o = nxo())) { + TProofOutputFile *pof = dynamic_cast<TProofOutputFile *>(o); + if (!pof) { + // Write the object to the open output file + o->Write(); + } + } + } + } + // Clean-up + if (fout) { + fout->Close(); + SafeDelete(fout); + Printf(" Output saved to %s", target.Data()); + } + } + } + // Remove the parameter + DeleteParameters("PROOF_DefaultOutputOption"); + // Remove the parameter + DeleteParameters("PROOF_SavePartialResults"); + } + // Done + return 0; +} + //______________________________________________________________________________ void TProof::SetFeedback(TString &opt, TString &optfb, Int_t action) { @@ -4439,9 +5075,10 @@ void TProof::SetFeedback(TString &opt, TString &optfb, Int_t action) // Feedback requirements are in the form // // <previous_option>fb=name1,name2,name3,... <next_option> - // <previous_option>feedback=name1,name2,name3,... <next_option> + // <previous_option>feedback=name1,name2,name3,...;<next_option> // // The special name 'stats' triggers feedback about events and packets. + // The separator from the next option is either a ' ' or a ';'. // Called interanally by TProof::Process. Ssiz_t from = 0; @@ -4521,9 +5158,11 @@ Long64_t TProof::Process(TDSet *dset, const char *selector, Option_t *option, // Set PROOF to running state SetRunStatus(TProof::kRunning); - TString opt(option), optfb; + TString opt(option), optfb, outfile; // Enable feedback, if required if (opt.Contains("fb=") || opt.Contains("feedback=")) SetFeedback(opt, optfb, 0); + // Define output file, either from 'opt' or the default one + if (HandleOutputOptions(opt, outfile, 0) != 0) return -1; // Resolve query mode fSync = (GetQueryMode(opt) == kSync); @@ -4550,6 +5189,15 @@ Long64_t TProof::Process(TDSet *dset, const char *selector, Option_t *option, sh = gSystem->RemoveSignalHandler(gApplication->GetSignalHandler()); } + // Make sure we get a fresh result + fOutputList.Clear(); + + // Make sure that the workers ready list is empty + if (fWrksOutputReady) { + fWrksOutputReady->SetOwner(kFALSE); + fWrksOutputReady->Clear(); + } + Long64_t rv = -1; if (selector && strlen(selector)) { rv = fPlayer->Process(dset, selector, opt.Data(), nentries, first); @@ -4562,6 +5210,8 @@ Long64_t TProof::Process(TDSet *dset, const char *selector, Option_t *option, // Disable feedback, if required if (!optfb.IsNull()) SetFeedback(opt, optfb, 1); + // Finalise output file settings (opt is ignored in here) + if (HandleOutputOptions(opt, outfile, 1) != 0) return -1; if (fSync) { // reactivate the default application interrupt handler @@ -4875,7 +5525,7 @@ Long64_t TProof::Process(const char *dsetname, const char *selector, } else if (fSelector) { retval = Process(dset, fSelector, option, nentries, first); } else { - Error("Process", "neither a selecrot file nor a selector object have" + Error("Process", "neither a selector file nor a selector object have" " been specified: cannot process!"); } // Cleanup @@ -5464,6 +6114,12 @@ void TProof::RecvLogFile(TSocket *s, Int_t size) const Int_t kMAXBUF = 16384; //32768 //16384 //65536; char buf[kMAXBUF]; + // If macro saving is enabled prepare macro + if (fSaveLogToMacro && fMacroLog.GetListOfLines()) { + fMacroLog.GetListOfLines()->SetOwner(kTRUE); + fMacroLog.GetListOfLines()->Clear(); + } + // Append messages to active logging unit Int_t fdout = -1; if (!fLogToWindowOnly) { @@ -5485,9 +6141,9 @@ void TProof::RecvLogFile(TSocket *s, Int_t size) left = kMAXBUF-1; rec = s->RecvRaw(&buf, left); filesize = (rec > 0) ? (filesize + rec) : filesize; - if (!fLogToWindowOnly) { + if (!fLogToWindowOnly && !fSaveLogToMacro) { if (rec > 0) { - + char *p = buf; r = rec; while (r) { @@ -5510,6 +6166,8 @@ void TProof::RecvLogFile(TSocket *s, Int_t size) if (rec > 0) { buf[rec] = 0; EmitVA("LogMessage(const char*,Bool_t)", 2, buf, kFALSE); + // If macro saving is enabled add to TMacro + if (fSaveLogToMacro) fMacroLog.AddLine(buf); } } @@ -5734,10 +6392,9 @@ Int_t TProof::Exec(const char *cmd, ESlaves list, Bool_t plusMaster) if (IsLite()) { gROOT->ProcessLine(cmd); } else { - Int_t n = GetParallel(); - SetParallelSilent(0); + DeactivateWorker("*"); Int_t res = SendCommand(cmd, list); - SetParallelSilent(n); + ActivateWorker("restore"); if (res < 0) return res; } @@ -5745,6 +6402,48 @@ Int_t TProof::Exec(const char *cmd, ESlaves list, Bool_t plusMaster) return SendCommand(cmd, list); } +//______________________________________________________________________________ +Int_t TProof::Exec(const char *cmd, const char *ord, Bool_t logtomacro) +{ + // Send command to be executed on node of ordinal 'ord' (use "0" for master). + // Command can be any legal command line command. Commands like + // ".x file.C" or ".L file.C" will cause the file file.C to be send + // to the PROOF cluster. + // If logtomacro is TRUE the text result of the action is saved in the fMacroLog + // TMacro, accessible via TMacro::GetMacroLog(); + // Returns -1 in case of error, >=0 in case of succes. + + if (!IsValid()) return -1; + + TString s = cmd; + s = s.Strip(TString::kBoth); + + if (!s.Length()) return 0; + + Int_t res = 0; + if (IsLite()) { + gROOT->ProcessLine(cmd); + } else { + Bool_t oldRedirLog = fRedirLog; + fRedirLog = kTRUE; + // Deactivate all workers + DeactivateWorker("*"); + fRedirLog = kFALSE; + // Reactivate the target ones, if needed + if (strcmp(ord, "master") && strcmp(ord, "0")) ActivateWorker(ord); + // Honour log-to-macro-saving settings + Bool_t oldSaveLog = fSaveLogToMacro; + fSaveLogToMacro = logtomacro; + res = SendCommand(cmd, kActive); + fSaveLogToMacro = oldSaveLog; + fRedirLog = kTRUE; + ActivateWorker("restore"); + fRedirLog = oldRedirLog; + } + // Done + return res; +} + //______________________________________________________________________________ Int_t TProof::SendCommand(const char *cmd, ESlaves list) { @@ -5764,6 +6463,102 @@ Int_t TProof::SendCommand(const char *cmd, ESlaves list) return fStatus; } +//______________________________________________________________________________ +TString TProof::Getenv(const char *env, const char *ord) +{ + // Get value of environment variable 'env' on node 'ord' + + // The command to be executed + TString cmd = TString::Format("gSystem->Getenv(\"%s\")", env); + if (Exec(cmd.Data(), ord, kTRUE) != 0) return TString(""); + // Get the line + TObjString *os = fMacroLog.GetLineWith("const char"); + if (os) { + TString info; + Ssiz_t from = 0; + os->GetString().Tokenize(info, from, "\""); + os->GetString().Tokenize(info, from, "\""); + if (gDebug > 0) Printf("%s: '%s'", env, info.Data()); + return info; + } + return TString(""); +} + +//______________________________________________________________________________ +Int_t TProof::GetRC(const char *rcenv, Int_t &env, const char *ord) +{ + // Get into 'env' the value of integer RC env variable 'rcenv' on node 'ord' + + // The command to be executed + TString cmd = TString::Format("if (gEnv->Lookup(\"%s\")) { gEnv->GetValue(\"%s\",\"\"); }", rcenv, rcenv); + // Exectute the command saving the logs to macro + if (Exec(cmd.Data(), ord, kTRUE) != 0) return -1; + // Get the line + TObjString *os = fMacroLog.GetLineWith("const char"); + Int_t rc = -1; + if (os) { + Ssiz_t fst = os->GetString().First('\"'); + Ssiz_t lst = os->GetString().Last('\"'); + TString info = os->GetString()(fst+1, lst-fst-1); + if (info.IsDigit()) { + env = info.Atoi(); + rc = 0; + if (gDebug > 0) + Printf("%s: %d", rcenv, env); + } + } + return rc; +} + +//______________________________________________________________________________ +Int_t TProof::GetRC(const char *rcenv, Double_t &env, const char *ord) +{ + // Get into 'env' the value of double RC env variable 'rcenv' on node 'ord' + + // The command to be executed + TString cmd = TString::Format("if (gEnv->Lookup(\"%s\")) { gEnv->GetValue(\"%s\",\"\"); }", rcenv, rcenv); + // Exectute the command saving the logs to macro + if (Exec(cmd.Data(), ord, kTRUE) != 0) return -1; + // Get the line + TObjString *os = fMacroLog.GetLineWith("const char"); + Int_t rc = -1; + if (os) { + Ssiz_t fst = os->GetString().First('\"'); + Ssiz_t lst = os->GetString().Last('\"'); + TString info = os->GetString()(fst+1, lst-fst-1); + if (info.IsFloat()) { + env = info.Atof(); + rc = 0; + if (gDebug > 0) + Printf("%s: %f", rcenv, env); + } + } + return rc; +} + +//______________________________________________________________________________ +Int_t TProof::GetRC(const char *rcenv, TString &env, const char *ord) +{ + // Get into 'env' the value of string RC env variable 'rcenv' on node 'ord' + + // The command to be executed + TString cmd = TString::Format("if (gEnv->Lookup(\"%s\")) { gEnv->GetValue(\"%s\",\"\"); }", rcenv, rcenv); + // Exectute the command saving the logs to macro + if (Exec(cmd.Data(), ord, kTRUE) != 0) return -1; + // Get the line + TObjString *os = fMacroLog.GetLineWith("const char"); + Int_t rc = -1; + if (os) { + Ssiz_t fst = os->GetString().First('\"'); + Ssiz_t lst = os->GetString().Last('\"'); + env = os->GetString()(fst+1, lst-fst-1); + rc = 0; + if (gDebug > 0) + Printf("%s: %s", rcenv, env.Data()); + } + return rc; +} + //______________________________________________________________________________ Int_t TProof::SendCurrentState(ESlaves list) { @@ -6034,6 +6829,33 @@ Int_t TProof::SendFile(const char *file, Int_t opt, const char *rfile, TSlave *w return (fStatus != 0) ? -1 : nsl; } +//______________________________________________________________________________ +Int_t TProof::Echo(const TObject *obj) +{ + // Sends an object to master and workers and expect them to send back a + // message with the output of its TObject::Print(). Returns -1 on error, the + // number of workers that received the objects on success. + + if (!IsValid() || !obj) return -1; + TMessage mess(kPROOF_ECHO); + mess.WriteObject(obj); + return Broadcast(mess); +} + +//______________________________________________________________________________ +Int_t TProof::Echo(const char *str) +{ + // Sends a string to master and workers and expect them to echo it back to + // the client via a message. It is a special case of the generic Echo() + // that works with TObjects. Returns -1 on error, the number of workers that + // received the message on success. + + TObjString *os = new TObjString(str); + Int_t rv = Echo(os); + delete os; + return rv; +} + //______________________________________________________________________________ Int_t TProof::SendObject(const TObject *obj, ESlaves list) { @@ -6101,7 +6923,7 @@ Int_t TProof::SetParallelSilent(Int_t nodes, Bool_t random) if (!IsValid()) return -1; if (TestBit(TProof::kIsMaster)) { - GoParallel(nodes, kFALSE, random); + if (!fDynamicStartup) GoParallel(nodes, kFALSE, random); return SendCurrentState(); } else { PDB(kGlobal,1) Info("SetParallelSilent", "request %d node%s", nodes, @@ -6122,6 +6944,10 @@ Int_t TProof::SetParallel(Int_t nodes, Bool_t random) // Tell PROOF how many slaves to use in parallel. Returns the number of // parallel slaves. Returns -1 in case of error. + if (fDynamicStartup && nodes < 0) { + if (gSystem->Getenv("PROOF_NWORKERS")) gSystem->Unsetenv("PROOF_NWORKERS"); + } + Int_t n = SetParallelSilent(nodes, random); if (TestBit(TProof::kIsClient)) { if (n < 1) { @@ -6132,10 +6958,114 @@ Int_t TProof::SetParallel(Int_t nodes, Bool_t random) subfix += ", randomly selected"; Printf("PROOF set to parallel mode (%d worker%s)", n, subfix.Data()); } + } else if (fDynamicStartup && nodes >= 0) { + if (gSystem->Getenv("PROOF_NWORKERS")) gSystem->Unsetenv("PROOF_NWORKERS"); + gSystem->Setenv("PROOF_NWORKERS", TString::Format("%d", nodes)); } return n; } +//______________________________________________________________________________ +Int_t TProof::GoMoreParallel(Int_t nWorkersToAdd) +{ + // Add nWorkersToAdd workers to current list of workers. This function is + // works on the master only, and only when an analysis is ongoing. A message + // is sent back to the client when we go "more" parallel. + // Returns -1 on error, number of total (not added!) workers on success. + + if (!IsValid() || !IsMaster() || IsIdle()) { + Error("GoMoreParallel", "Can't invoke here -- should not happen!"); + return -1; + } + if (!gProofServ) { + Error("GoMoreParallel", "No ProofServ available -- should not happen!"); + return -1; + } + + TSlave *sl = 0x0; + TIter next( fSlaves ); + Int_t nAddedWorkers = 0; + + while (((nAddedWorkers < nWorkersToAdd) || (nWorkersToAdd == -1)) && + (( sl = dynamic_cast<TSlave *>( next() ) ))) { + + // If worker is of an invalid type, break everything: it should not happen! + if ((sl->GetSlaveType() != TSlave::kSlave) && + (sl->GetSlaveType() != TSlave::kMaster)) { + Error("GoMoreParallel", "TSlave is neither a Master nor a Slave: %s:%s", + sl->GetName(), sl->GetOrdinal()); + R__ASSERT(0); + } + + // Skip current worker if it is not a good candidate + if ((!sl->IsValid()) || (fBadSlaves->FindObject(sl)) || + (strcmp("IGNORE", sl->GetImage()) == 0)) { + PDB(kGlobal, 2) + Info("GoMoreParallel", "Worker %s:%s won't be considered", + sl->GetName(), sl->GetOrdinal()); + continue; + } + + // Worker is good but it is already active: skip it + if (fActiveSlaves->FindObject(sl)) { + Info("GoMoreParallel", "Worker %s:%s is already active: skipping", + sl->GetName(), sl->GetOrdinal()); + continue; + } + + // + // From here on: worker is a good candidate + // + + if (sl->GetSlaveType() == TSlave::kSlave) { + sl->SetStatus(TSlave::kActive); + fActiveSlaves->Add(sl); + fInactiveSlaves->Remove(sl); + fActiveMonitor->Add(sl->GetSocket()); + nAddedWorkers++; + PDB(kGlobal, 2) + Info("GoMoreParallel", "Worker %s:%s marked as active!", + sl->GetName(), sl->GetOrdinal()); + } + else { + // Can't add masters dynamically: this should not happen! + Error("GoMoreParallel", "Dynamic addition of master is not supported"); + R__ASSERT(0); + } + + } // end loop over all slaves + + // Get slave status (will set the slaves fWorkDir correctly) + PDB(kGlobal, 3) + Info("GoMoreParallel", "Will invoke AskStatistics() -- implies a Collect()"); + AskStatistics(); + + // Find active slaves with unique image + PDB(kGlobal, 3) + Info("GoMoreParallel", "Will invoke FindUniqueSlaves()"); + FindUniqueSlaves(); + + // Send new group-view to slaves + PDB(kGlobal, 3) + Info("GoMoreParallel", "Will invoke SendGroupView()"); + SendGroupView(); + + PDB(kGlobal, 3) + Info("GoMoreParallel", "Will invoke GetParallel()"); + Int_t nTotalWorkers = GetParallel(); + + // Notify the client that we've got more workers, and print info on + // Master's log as well + TString s; + s.Form("PROOF just went more parallel (%d additional worker%s, %d worker%s total)", + nAddedWorkers, (nAddedWorkers == 1) ? "" : "s", + nTotalWorkers, (nTotalWorkers == 1) ? "" : "s"); + gProofServ->SendAsynMessage(s); + Info("GoMoreParallel", "%s", s.Data()); + + return nTotalWorkers; +} + //______________________________________________________________________________ Int_t TProof::GoParallel(Int_t nodes, Bool_t attach, Bool_t random) { @@ -6148,8 +7078,6 @@ Int_t TProof::GoParallel(Int_t nodes, Bool_t attach, Bool_t random) if (!IsValid()) return -1; - if (nodes < 0) nodes = 0; - fActiveSlaves->Clear(); fActiveMonitor->RemoveAll(); @@ -6174,7 +7102,7 @@ Int_t TProof::GoParallel(Int_t nodes, Bool_t attach, Bool_t random) sl->SetStatus(TSlave::kInactive); } } - Int_t nwrks = (nodes > wlst->GetSize()) ? wlst->GetSize() : nodes; + Int_t nwrks = (nodes < 0 || nodes > wlst->GetSize()) ? wlst->GetSize() : nodes; int cnt = 0; fEndMaster = TestBit(TProof::kIsMaster) ? kTRUE : kFALSE; while (cnt < nwrks) { @@ -6291,7 +7219,7 @@ void TProof::ClearData(UInt_t what, const char *dsname) // Check whether we need to prompt TString prompt, a("Y"); Bool_t force = (what & kForceClear) ? kTRUE : kFALSE; - Bool_t doask = (!force && isatty(0) != 0 && isatty(1) != 0) ? kTRUE : kFALSE; + Bool_t doask = (!force && IsTty()) ? kTRUE : kFALSE; // If all just send the request if ((what & TProof::kPurge)) { @@ -6909,7 +7837,7 @@ Int_t TProof::DisablePackages() } //______________________________________________________________________________ -Int_t TProof::BuildPackage(const char *package, EBuildPackageOpt opt) +Int_t TProof::BuildPackage(const char *package, EBuildPackageOpt opt, Int_t chkveropt) { // Build specified package. Executes the PROOF-INF/BUILD.sh // script if it exists on all unique nodes. If opt is kBuildOnSlavesNoWait @@ -6943,7 +7871,7 @@ Int_t TProof::BuildPackage(const char *package, EBuildPackageOpt opt) Int_t st = 0; if (buildOnClient) { if (TestBit(TProof::kIsClient) && fPackageLock) fPackageLock->Lock(); - if ((st = BuildPackageOnClient(pac, 1, &pdir) != 0)) { + if ((st = BuildPackageOnClient(pac, 1, &pdir, chkveropt) != 0)) { if (TestBit(TProof::kIsClient) && fPackageLock) fPackageLock->Unlock(); return -1; } @@ -6951,11 +7879,11 @@ Int_t TProof::BuildPackage(const char *package, EBuildPackageOpt opt) if (opt <= kBuildAll && (!IsLite() || !buildOnClient)) { TMessage mess(kPROOF_CACHE); - mess << Int_t(kBuildPackage) << pac; + mess << Int_t(kBuildPackage) << pac << chkveropt; Broadcast(mess, kUnique); TMessage mess2(kPROOF_CACHE); - mess2 << Int_t(kBuildSubPackage) << pac; + mess2 << Int_t(kBuildSubPackage) << pac << chkveropt; Broadcast(mess2, fNonUniqueMasters); } @@ -6963,7 +7891,7 @@ Int_t TProof::BuildPackage(const char *package, EBuildPackageOpt opt) // by first forwarding the build commands to the master and slaves // and only then building locally we build in parallel if (buildOnClient) { - st = BuildPackageOnClient(pac, 2, &pdir); + st = BuildPackageOnClient(pac, 2, &pdir, chkveropt); if (TestBit(TProof::kIsClient) && fPackageLock) fPackageLock->Unlock(); } @@ -6979,7 +7907,7 @@ Int_t TProof::BuildPackage(const char *package, EBuildPackageOpt opt) } //______________________________________________________________________________ -Int_t TProof::BuildPackageOnClient(const char *pack, Int_t opt, TString *path) +Int_t TProof::BuildPackageOnClient(const char *pack, Int_t opt, TString *path, Int_t chkveropt) { // Build specified package on the client. Executes the PROOF-INF/BUILD.sh // script if it exists on the client. @@ -7106,6 +8034,7 @@ Int_t TProof::BuildPackageOnClient(const char *pack, Int_t opt, TString *path) // read version from file proofvers.txt, and if current version is // not the same do a "BUILD.sh clean" + Bool_t goodver = kTRUE; Bool_t savever = kFALSE; Int_t rev = -1; TString v; @@ -7116,9 +8045,13 @@ Int_t TProof::BuildPackageOnClient(const char *pack, Int_t opt, TString *path) r.Gets(f); rev = (!r.IsNull() && r.IsDigit()) ? r.Atoi() : -1; fclose(f); + if (chkveropt == kCheckROOT || chkveropt == kCheckSVN) { + if (v != gROOT->GetVersion()) goodver = kFALSE; + if (goodver && chkveropt == kCheckSVN) + if (gROOT->GetSvnRevision() > 0 && rev != gROOT->GetSvnRevision()) goodver = kFALSE; + } } - if (!f || v != gROOT->GetVersion() || - (gROOT->GetSvnRevision() > 0 && rev != gROOT->GetSvnRevision())) { + if (!f || !goodver) { savever = kTRUE; Info("BuildPackageOnClient", "%s: version change (current: %s:%d, build: %s:%d): cleaning ... ", @@ -7175,7 +8108,8 @@ Int_t TProof::BuildPackageOnClient(const char *pack, Int_t opt, TString *path) } //______________________________________________________________________________ -Int_t TProof::LoadPackage(const char *package, Bool_t notOnClient, TList *loadopts) +Int_t TProof::LoadPackage(const char *package, Bool_t notOnClient, + TList *loadopts, TList *workers) { // Load specified package. Executes the PROOF-INF/SETUP.C script // on all active nodes. If notOnClient = true, don't load package @@ -7205,10 +8139,20 @@ Int_t TProof::LoadPackage(const char *package, Bool_t notOnClient, TList *loadop TMessage mess(kPROOF_CACHE); mess << Int_t(kLoadPackage) << pac; if (loadopts) mess << loadopts; - Broadcast(mess); + // On the master, workers that fail are deactivated Bool_t deactivateOnFailure = (IsMaster()) ? kTRUE : kFALSE; - Collect(kActive, -1, -1, deactivateOnFailure); + + if (workers) { + PDB(kPackage, 3) + Info("LoadPackage", "Sending load message to selected workers only"); + Broadcast(mess, workers); + Collect(workers, -1, -1, deactivateOnFailure); + } + else { + Broadcast(mess); + Collect(kActive, -1, -1, deactivateOnFailure); + } return fStatus; } @@ -7481,21 +8425,23 @@ Int_t TProof::UnloadPackages() } //______________________________________________________________________________ -Int_t TProof::EnablePackage(const char *package, Bool_t notOnClient) +Int_t TProof::EnablePackage(const char *package, Bool_t notOnClient, + TList *workers) { // Enable specified package. Executes the PROOF-INF/BUILD.sh // script if it exists followed by the PROOF-INF/SETUP.C script. // In case notOnClient = true, don't enable the package on the client. // The default is to enable packages also on the client. + // If specified, enables packages only on the specified workers. // Returns 0 in case of success and -1 in case of error. // Provided for backward compatibility. - return EnablePackage(package, (TList *)0, notOnClient); + return EnablePackage(package, (TList *)0, notOnClient, workers); } //______________________________________________________________________________ Int_t TProof::EnablePackage(const char *package, const char *loadopts, - Bool_t notOnClient) + Bool_t notOnClient, TList *workers) { // Enable specified package. Executes the PROOF-INF/BUILD.sh // script if it exists followed by the PROOF-INF/SETUP.C script. @@ -7503,21 +8449,60 @@ Int_t TProof::EnablePackage(const char *package, const char *loadopts, // The default is to enable packages also on the client. // It is is possible to specify options for the loading step via 'loadopts'; // the string will be passed passed as argument to SETUP. + // Special option 'chkv=<o>' (or 'checkversion=<o>') can be used to control + // plugin version checking during building: possible choices are: + // off no check; failure may occur at loading + // on check ROOT version [default] + // svn check ROOT version and SVN revision number. + // (Use ';', ' ' or '|' to separate 'chkv=<o>' from the rest.) + // If specified, enables packages only on the specified workers. // Returns 0 in case of success and -1 in case of error. TList *optls = 0; if (loadopts && strlen(loadopts)) { if (fProtocol > 28) { - optls = new TList; - optls->Add(new TObjString(loadopts)); - optls->SetOwner(kTRUE); + TObjString *os = new TObjString(loadopts); + // Filter out 'checkversion=off|on|svn' or 'chkv=...' + os->String().ReplaceAll("checkversion=", "chkv="); + Ssiz_t fcv = kNPOS, lcv = kNPOS; + if ((fcv = os->String().Index("chkv=")) != kNPOS) { + TRegexp re("[; |]"); + if ((lcv = os->String().Index(re, fcv)) == kNPOS) { + lcv = os->String().Length(); + } + TString ocv = os->String()(fcv, lcv - fcv); + Int_t cvopt = -1; + if (ocv.EndsWith("=off") || ocv.EndsWith("=0")) + cvopt = (Int_t) kDontCheck; + else if (ocv.EndsWith("=on") || ocv.EndsWith("=1")) + cvopt = (Int_t) kCheckROOT; + else if (ocv.EndsWith("=svn") || ocv.EndsWith("=2")) + cvopt = (Int_t) kCheckSVN; + else + Warning("EnablePackage", "'checkversion' option unknown from argument: '%s' - ignored", ocv.Data()); + if (cvopt > -1) { + if (gDebug > 0) + Info("EnablePackage", "setting check version option from argument: %d", cvopt); + optls = new TList; + optls->Add(new TParameter<Int_t>("PROOF_Package_CheckVersion", (Int_t) cvopt)); + // Remove the special option from; we leave a separator if there were two (one before and one after) + if (lcv != kNPOS && fcv == 0) ocv += os->String()[lcv]; + if (fcv > 0 && os->String().Index(re, fcv - 1) == fcv - 1) os->String().Remove(fcv - 1, 1); + os->String().ReplaceAll(ocv.Data(), ""); + } + } + if (!os->String().IsNull()) { + if (!optls) optls = new TList; + optls->Add(new TObjString(os->String().Data())); + } + if (optls) optls->SetOwner(kTRUE); } else { // Notify Warning("EnablePackage", "remote server does not support options: ignoring the option string"); } } // Run - Int_t rc = EnablePackage(package, optls, notOnClient); + Int_t rc = EnablePackage(package, optls, notOnClient, workers); // Clean up SafeDelete(optls); // Done @@ -7526,7 +8511,7 @@ Int_t TProof::EnablePackage(const char *package, const char *loadopts, //______________________________________________________________________________ Int_t TProof::EnablePackage(const char *package, TList *loadopts, - Bool_t notOnClient) + Bool_t notOnClient, TList *workers) { // Enable specified package. Executes the PROOF-INF/BUILD.sh // script if it exists followed by the PROOF-INF/SETUP.C script. @@ -7553,16 +8538,40 @@ Int_t TProof::EnablePackage(const char *package, TList *loadopts, if (notOnClient) opt = kDontBuildOnClient; - if (BuildPackage(pac, opt) == -1) + // Get check version option; user settings have priority + Int_t chkveropt = kCheckROOT; + TString ocv = gEnv->GetValue("Proof.Package.CheckVersion", ""); + if (!ocv.IsNull()) { + if (ocv == "off" || ocv == "0") + chkveropt = (Int_t) kDontCheck; + else if (ocv == "on" || ocv == "1") + chkveropt = (Int_t) kCheckROOT; + else if (ocv == "svn" || ocv == "2") + chkveropt = (Int_t) kCheckSVN; + else + Warning("EnablePackage", "'checkversion' option unknown from rootrc: '%s' - ignored", ocv.Data()); + } + if (loadopts) { + TParameter<Int_t> *pcv = (TParameter<Int_t> *) loadopts->FindObject("PROOF_Package_CheckVersion"); + if (pcv) { + chkveropt = pcv->GetVal(); + loadopts->Remove(pcv); + delete pcv; + } + } + if (gDebug > 0) + Info("EnablePackage", "using check version option: %d", chkveropt); + + if (BuildPackage(pac, opt, chkveropt) == -1) return -1; - TList *optls = loadopts; + TList *optls = (loadopts && loadopts->GetSize() > 0) ? loadopts : 0; if (optls && fProtocol <= 28) { Warning("EnablePackage", "remote server does not support options: ignoring the option list"); optls = 0; } - if (LoadPackage(pac, notOnClient, optls) == -1) + if (LoadPackage(pac, notOnClient, optls, workers) == -1) return -1; return 0; @@ -7663,7 +8672,8 @@ Int_t TProof::DownloadPackage(const char *pack, const char *dstdir) } //______________________________________________________________________________ -Int_t TProof::UploadPackage(const char *pack, EUploadPackageOpt opt) +Int_t TProof::UploadPackage(const char *pack, EUploadPackageOpt opt, + TList *workers) { // Upload a PROOF archive (PAR file). A PAR file is a compressed // tar file with one special additional directory, PROOF-INF @@ -7687,17 +8697,22 @@ Int_t TProof::UploadPackage(const char *pack, EUploadPackageOpt opt) if (!IsValid()) return -1; - TString par = pack; - if (!par.EndsWith(".par")) - // The client specified only the name: add the extension + TString par(pack), base, name; + if (par.EndsWith(".par")) { + base = gSystem->BaseName(par); + name = base(0, base.Length() - strlen(".par")); + } else { + name = gSystem->BaseName(par); + base.Form("%s.par", name.Data()); par += ".par"; + } // Default location is the local working dir; then the package dir gSystem->ExpandPathName(par); if (gSystem->AccessPathName(par, kReadPermission)) { TString tried = par; // Try the package dir - par.Form("%s/%s", fPackageDir.Data(), gSystem->BaseName(par)); + par.Form("%s/%s", fPackageDir.Data(), base.Data()); if (gSystem->AccessPathName(par, kReadPermission)) { // Is the package a global one if (fGlobalPackageDirList && fGlobalPackageDirList->GetSize() > 0) { @@ -7706,7 +8721,7 @@ Int_t TProof::UploadPackage(const char *pack, EUploadPackageOpt opt) TNamed *nm = 0; TString pdir; while ((nm = (TNamed *)nxd())) { - pdir.Form("%s/%s", nm->GetTitle(), pack); + pdir.Form("%s/%s", nm->GetTitle(), name.Data()); if (!gSystem->AccessPathName(pdir, kReadPermission)) { // Package found, stop searching break; @@ -7740,9 +8755,11 @@ Int_t TProof::UploadPackage(const char *pack, EUploadPackageOpt opt) TMD5 *md5 = TMD5::FileChecksum(par); - if (!md5 || (md5 && UploadPackageOnClient(par, opt, md5) == -1)) { - if (md5) delete md5; - return -1; + if (TestBit(TProof::kIsClient)) { + if (!md5 || (md5 && UploadPackageOnClient(par, opt, md5) == -1)) { + if (md5) delete md5; + return -1; + } } // Nothing more to do if we are a Lite-session @@ -7752,7 +8769,7 @@ Int_t TProof::UploadPackage(const char *pack, EUploadPackageOpt opt) } TString smsg; - smsg.Form("+%s", gSystem->BaseName(par)); + smsg.Form("+%s", base.Data()); TMessage mess(kPROOF_CHECKFILE); mess << smsg << (*md5); @@ -7772,8 +8789,11 @@ Int_t TProof::UploadPackage(const char *pack, EUploadPackageOpt opt) mess3 << (UInt_t) opt; } - // loop over all selected nodes - TIter next(fUniqueSlaves); + // Loop over all slaves with unique fs image, or to a selected + // list of workers, if specified + if (!workers) + workers = fUniqueSlaves; + TIter next(workers); TSlave *sl = 0; while ((sl = (TSlave *) next())) { if (!sl->IsValid()) @@ -7787,8 +8807,7 @@ Int_t TProof::UploadPackage(const char *pack, EUploadPackageOpt opt) if (fProtocol > 5) { // remote directory is locked, upload file over the open channel - smsg.Form("%s/%s/%s", sl->GetProofWorkDir(), kPROOF_PackDir, - gSystem->BaseName(par)); + smsg.Form("%s/%s/%s", sl->GetProofWorkDir(), kPROOF_PackDir, base.Data()); if (SendFile(par, (kBinary | kForce | kCpBin | kForward), smsg.Data(), sl) < 0) { Error("UploadPackage", "%s: problems uploading file %s", sl->GetOrdinal(), par.Data()); @@ -7800,7 +8819,7 @@ Int_t TProof::UploadPackage(const char *pack, EUploadPackageOpt opt) if (!ftp.IsZombie()) { smsg.Form("%s/%s", sl->GetProofWorkDir(), kPROOF_PackDir); ftp.cd(smsg.Data()); - ftp.put(par, gSystem->BaseName(par)); + ftp.put(par, base.Data()); } } @@ -7810,7 +8829,7 @@ Int_t TProof::UploadPackage(const char *pack, EUploadPackageOpt opt) Collect(sl, fCollectTimeout, kPROOF_CHECKFILE); if (fCheckFileStatus == 0) { Error("UploadPackage", "%s: unpacking of package %s failed", - sl->GetOrdinal(), gSystem->BaseName(par)); + sl->GetOrdinal(), base.Data()); return -1; } } @@ -7830,7 +8849,7 @@ Int_t TProof::UploadPackage(const char *pack, EUploadPackageOpt opt) if (fCheckFileStatus == 0) { // error -> package should have been found Error("UploadPackage", "package %s did not exist on submaster %s", - par.Data(), ma->GetOrdinal()); + base.Data(), ma->GetOrdinal()); return -1; } } @@ -8172,7 +9191,8 @@ Int_t TProof::Load(const char *macro, Bool_t notOnClient, Bool_t uniqueWorkers, } //______________________________________________________________________________ -Int_t TProof::AddDynamicPath(const char *libpath, Bool_t onClient, TList *wrks) +Int_t TProof::AddDynamicPath(const char *libpath, Bool_t onClient, TList *wrks, + Bool_t doCollect) { // Add 'libpath' to the lib path search. // Multiple paths can be specified at once separating them with a comma or @@ -8199,17 +9219,22 @@ Int_t TProof::AddDynamicPath(const char *libpath, Bool_t onClient, TList *wrks) m << TString("-"); // Forward the request - if (wrks) + if (wrks) { Broadcast(m, wrks); - else + if (doCollect) + Collect(wrks, fCollectTimeout); + } + else { Broadcast(m); - Collect(kActive, fCollectTimeout); + Collect(kActive, fCollectTimeout); + } return 0; } //______________________________________________________________________________ -Int_t TProof::AddIncludePath(const char *incpath, Bool_t onClient, TList *wrks) +Int_t TProof::AddIncludePath(const char *incpath, Bool_t onClient, TList *wrks, + Bool_t doCollect) { // Add 'incpath' to the inc path search. // Multiple paths can be specified at once separating them with a comma or @@ -8236,11 +9261,15 @@ Int_t TProof::AddIncludePath(const char *incpath, Bool_t onClient, TList *wrks) m << TString("-"); // Forward the request - if (wrks) + if (wrks) { Broadcast(m, wrks); - else + if (doCollect) + Collect(wrks, fCollectTimeout); + } + else { Broadcast(m); - Collect(kActive, fCollectTimeout); + Collect(kActive, fCollectTimeout); + } return 0; } @@ -8485,9 +9514,10 @@ void TProof::PrintProgress(Long64_t total, Long64_t processed, } Float_t evtrti = (procTime > 0. && processed > 0) ? processed / procTime : -1.; Float_t mbsrti = (procTime > 0. && bytesread > 0) ? bytesread / procTime : -1.; + TString sunit("B/s"); if (evtrti > 0.) { + Float_t remainingTime = (total >= processed) ? (total - processed) / evtrti : -1; if (mbsrti > 0.) { - TString sunit("B/s"); const Float_t toK = 1024., toM = 1048576., toG = 1073741824.; if (mbsrti >= toG) { mbsrti /= toG; @@ -8499,18 +9529,19 @@ void TProof::PrintProgress(Long64_t total, Long64_t processed, mbsrti /= toK; sunit = "kB/s"; } - fprintf(stderr, "| %.02f %% [%.1f evts/s, %.1f %s]\r", - (total ? ((100.0*processed)/total) : 100.0), evtrti, mbsrti, sunit.Data()); + fprintf(stderr, "| %.02f %% [%.1f evts/s, %.1f %s, time left: %.1f s]\r", + (total ? ((100.0*processed)/total) : 100.0), evtrti, mbsrti, sunit.Data(), remainingTime); } else { - fprintf(stderr, "| %.02f %% [%.1f evts/s]\r", - (total ? ((100.0*processed)/total) : 100.0), evtrti); + fprintf(stderr, "| %.02f %% [%.1f evts/s, time left: %.1f s]\r", + (total ? ((100.0*processed)/total) : 100.0), evtrti, remainingTime); } } else { fprintf(stderr, "| %.02f %%\r", (total ? ((100.0*processed)/total) : 100.0)); } - if (processed >= total) - fprintf(stderr, "\n"); + if (processed >= total) { + fprintf(stderr, "\n Query processing time: %.1f s\n", procTime); + } } //______________________________________________________________________________ @@ -9080,8 +10111,45 @@ TObject *TProof::GetOutput(const char *name) // Get specified object that has been produced during the processing // (see Process()). - // Can be called by MarkBad on the master before the player is initialized - return (fPlayer) ? fPlayer->GetOutput(name) : (TObject *)0; + + if (TestBit(TProof::kIsMaster)) + // Can be called by MarkBad on the master before the player is initialized + return (fPlayer) ? fPlayer->GetOutput(name) : (TObject *)0; + + // This checks also associated output files + return (GetOutputList()) ? GetOutputList()->FindObject(name) : (TObject *)0; +} + +//______________________________________________________________________________ +TObject *TProof::GetOutput(const char *name, TList *out) +{ + // Find object 'name' in list 'out' or in the files specified in there + + TObject *o = 0; + if (!name || (name && strlen(name) <= 0) || + !out || (out && out->GetSize() <= 0)) return o; + if ((o = out->FindObject(name))) return o; + + // For the time being we always check for all the files; this may require + // some caching + TProofOutputFile *pf = 0; + TIter nxo(out); + while ((o = nxo())) { + if ((pf = dynamic_cast<TProofOutputFile *> (o))) { + TFile *f = 0; + if (!(f = (TFile *) gROOT->GetListOfFiles()->FindObject(pf->GetOutputFileName()))) { + TString fn = TString::Format("%s/%s", pf->GetDir(), pf->GetFileName()); + f = TFile::Open(fn.Data()); + if (!f || (f && f->IsZombie())) { + ::Warning("TProof::GetOutput", "problems opening file %s", fn.Data()); + } + } + if (f && (o = f->Get(name))) return o; + } + } + + // Done, unsuccessfully + return o; } //______________________________________________________________________________ @@ -9089,6 +10157,7 @@ TList *TProof::GetOutputList() { // Get list with all object created during processing (see Process()). + if (fOutputList.GetSize() > 0) return &fOutputList; if (fPlayer) { fOutputList.AttachList(fPlayer->GetOutputList()); return &fOutputList; @@ -10294,6 +11363,115 @@ TList* TProof::FindDataSets(const char* /*searchString*/, const char* /*optStr*/ return (TList *) 0; } +//______________________________________________________________________________ +Bool_t TProof::RequestStagingDataSet(const char *dataset) +{ + // Allows users to request staging of a particular dataset. Requests are + // saved in a special dataset repository and must be honored by the endpoint. + + if (fProtocol < 35) { + Error("RequestStagingDataSet", + "functionality not supported by the server"); + return kFALSE; + } + + TMessage mess(kPROOF_DATASETS); + mess << Int_t(kRequestStaging); + mess << TString(dataset); + Broadcast(mess); + + Collect(); + if (fStatus != 0) { + Error("RequestStagingDataSet", "staging request was unsuccessful"); + return kFALSE; + } + + return kTRUE; +} + +//______________________________________________________________________________ +Bool_t TProof::CancelStagingDataSet(const char *dataset) +{ + // Cancels a dataset staging request. Returns kTRUE on success, kFALSE on + // failure. Dataset not found equals to a failure. + + if (fProtocol < 36) { + Error("CancelStagingDataSet", + "functionality not supported by the server"); + return kFALSE; + } + + TMessage mess(kPROOF_DATASETS); + mess << Int_t(kCancelStaging); + mess << TString(dataset); + Broadcast(mess); + + Collect(); + if (fStatus != 0) { + Error("CancelStagingDataSet", "cancel staging request was unsuccessful"); + return kFALSE; + } + + return kTRUE; +} + +//______________________________________________________________________________ +TFileCollection *TProof::GetStagingStatusDataSet(const char *dataset) +{ + // Obtains a TFileCollection showing the staging status of the specified + // dataset. A valid dataset manager and dataset staging requests repository + // must be present on the endpoint. + + if (fProtocol < 35) { + Error("GetStagingStatusDataSet", + "functionality not supported by the server"); + return NULL; + } + + TMessage nameMess(kPROOF_DATASETS); + nameMess << Int_t(kStagingStatus); + nameMess << TString(dataset); + if (Broadcast(nameMess) < 0) { + Error("GetStagingStatusDataSet", "sending request failed"); + return NULL; + } + + Collect(kActive, fCollectTimeout); + TFileCollection *fc = NULL; + + if (fStatus < 0) { + Error("GetStagingStatusDataSet", "problem processing the request"); + } + else if (fStatus == 0) { + TMessage *retMess = (TMessage *)fRecvMessages->First(); + if (retMess && (retMess->What() == kMESS_OK)) { + fc = (TFileCollection *)( + retMess->ReadObject(TFileCollection::Class()) ); + if (!fc) + Error("GetStagingStatusDataSet", "error reading list of files"); + } + else { + Error("GetStagingStatusDataSet", + "response message not found or wrong type (%p)", retMess); + } + } + //else {} + + return fc; +} + +//______________________________________________________________________________ +void TProof::ShowStagingStatusDataSet(const char *dataset, const char *opt) +{ + // Like GetStagingStatusDataSet, but displays results immediately + + TFileCollection *fc = GetStagingStatusDataSet(dataset); + if (fc) { + fc->Print(opt); + delete fc; + } +} + //______________________________________________________________________________ Int_t TProof::VerifyDataSet(const char *uri, const char *optStr) { @@ -10335,7 +11513,26 @@ Int_t TProof::VerifyDataSet(const char *uri, const char *optStr) return nmissingfiles; } - //Let PROOF master prepare node-files map + // Request for parallel verification: can only be done if we have workers + if (!IsParallel() && !fDynamicStartup) { + Error("VerifyDataSet", "PROOF is in sequential mode (no workers): cannot do parallel verification."); + Error("VerifyDataSet", "Either start PROOF with some workers or force sequential adding 'S' as option."); + return -1; + } + + // Do parallel verification + return VerifyDataSetParallel(uri, optStr); +} + +//______________________________________________________________________________ +Int_t TProof::VerifyDataSetParallel(const char *uri, const char *optStr) +{ + // Internal function for parallel dataset verification used TProof::VerifyDataSet and + // TProofLite::VerifyDataSet + + Int_t nmissingfiles = 0; + + // Let PROOF master prepare node-files map SetParameter("PROOF_FilesToProcess", Form("dataset:%s", uri)); // Use TPacketizerFile @@ -10347,6 +11544,7 @@ Int_t TProof::VerifyDataSet(const char *uri, const char *optStr) SetParameter("PROOF_VerifyDataSet", uri); // Add options SetParameter("PROOF_VerifyDataSetOption", optStr); + SetParameter("PROOF_SavePartialResults", (Int_t)0); Int_t oldifiip = -1; if (TProof::GetParameter(GetInputList(), "PROOF_IncludeFileInfoInPacket", oldifiip) != 0) oldifiip = -1; SetParameter("PROOF_IncludeFileInfoInPacket", (Int_t)1); @@ -10357,8 +11555,6 @@ Int_t TProof::VerifyDataSet(const char *uri, const char *optStr) const char* stageoption=""; SetParameter("PROOF_StageOption", stageoption); - GetInputList()->Print(); - // Process verification in parallel Process("TSelVerifyDataSet", (Long64_t) 1); @@ -10379,6 +11575,7 @@ Int_t TProof::VerifyDataSet(const char *uri, const char *optStr) } else { DeleteParameters("PROOF_IncludeFileInfoInPacket"); } + DeleteParameters("PROOF_SavePartialResults"); // Merge outputs Int_t nopened = 0; @@ -10416,10 +11613,10 @@ Int_t TProof::VerifyDataSet(const char *uri, const char *optStr) } } - Info("VerifyDataset", "%s: changed? %d (# files opened = %d, # files touched = %d," - " # missing files = %d)", - uri, changed_ds, nopened, ntouched, nmissingfiles); - + Info("VerifyDataSetParallel", "%s: changed? %d (# files opened = %d, # files touched = %d," + " # missing files = %d)", + uri, changed_ds, nopened, ntouched, nmissingfiles); + // Done return nmissingfiles; } @@ -10491,7 +11688,7 @@ void TProof::InterruptCurrentMonitor() } //_____________________________________________________________________________ -Int_t TProof::ActivateWorker(const char *ord) +Int_t TProof::ActivateWorker(const char *ord, Bool_t save) { // Make sure that the worker identified by the ordinal number 'ord' is // in the active list. The request will be forwarded to the master @@ -10504,11 +11701,11 @@ Int_t TProof::ActivateWorker(const char *ord) // Return <0 if something went wrong (-2 if at least one worker was not found) // or the number of workers with status change (on master; 0 on client). - return ModifyWorkerLists(ord, kTRUE); + return ModifyWorkerLists(ord, kTRUE, save); } //_____________________________________________________________________________ -Int_t TProof::DeactivateWorker(const char *ord) +Int_t TProof::DeactivateWorker(const char *ord, Bool_t save) { // Remove the worker identified by the ordinal number 'ord' from the // the active list. The request will be forwarded to the master @@ -10521,11 +11718,11 @@ Int_t TProof::DeactivateWorker(const char *ord) // Return <0 if something went wrong (-2 if at least one worker was not found) // or the number of workers with status change (on master; 0 on client). - return ModifyWorkerLists(ord, kFALSE); + return ModifyWorkerLists(ord, kFALSE, save); } //_____________________________________________________________________________ -Int_t TProof::ModifyWorkerLists(const char *ord, Bool_t add) +Int_t TProof::ModifyWorkerLists(const char *ord, Bool_t add, Bool_t save) { // Modify the worker active/inactive list by making the worker identified by // the ordinal number 'ord' active (add == TRUE) or inactive (add == FALSE). @@ -10535,6 +11732,8 @@ Int_t TProof::ModifyWorkerLists(const char *ord, Bool_t add) // with the worker. The end-master will move the worker from one list to the // other active and rebuild the list of unique active workers. // Use ord = "*" to deactivate all active workers. + // If save is TRUE the current active list is saved before any modification is + // done; re-running with ord = "restore" restores the saved list // Return <0 if something went wrong (-2 if at least one worker was not found) // or the number of workers with status change (on master; 0 on client). @@ -10544,17 +11743,19 @@ Int_t TProof::ModifyWorkerLists(const char *ord, Bool_t add) "an ordinal number - e.g. \"0.4\" or \"*\" for all - is required as input"); return -1; } - Bool_t allord = strcmp(ord, "*") ? kFALSE : kTRUE; - - // Create the hash list of ordinal numbers - THashList *ords = 0; - if (!allord) { - ords = new THashList(); - TString oo(ord), o; - Int_t from = 0; - while(oo.Tokenize(o, from, ",")) - ords->Add(new TObjString(o)); + if (gDebug > 0) + Info("ModifyWorkerLists", "ord: '%s' (add: %d, save: %d)", ord, add, save); + + if (IsEndMaster()) { + if (!strcmp(ord, "restore")) { + // We are asked to restore the previous settings + RestoreActiveList(); + } else { + if (save) SaveActiveList(); + } } + + Bool_t allord = strcmp(ord, "*") ? kFALSE : kTRUE; Bool_t fw = kTRUE; // Whether to forward one step down Bool_t rs = kFALSE; // Whether to rescan for unique workers @@ -10564,8 +11765,18 @@ Int_t TProof::ModifyWorkerLists(const char *ord, Bool_t add) TList *out = (add) ? fActiveSlaves : fInactiveSlaves; Int_t nwc = 0; - if (TestBit(TProof::kIsMaster)) { - fw = IsEndMaster() ? kFALSE : kTRUE; + if (IsEndMaster()) { + // Create the hash list of ordinal numbers + THashList *ords = 0; + if (!allord) { + ords = new THashList(); + TString oo(ord), o; + Int_t from = 0; + while(oo.Tokenize(o, from, ",")) + if (o.BeginsWith(gProofServ->GetOrdinal())) ords->Add(new TObjString(o)); + } + // We do not need to send forward + fw = kFALSE; // Look for the worker in the initial list TObject *os = 0; TSlave *wrk = 0; @@ -10642,7 +11853,8 @@ Int_t TProof::ModifyWorkerLists(const char *ord, Bool_t add) if (fStatus != 0) { nwc = (fStatus < nwc) ? fStatus : nwc; if (fStatus == -2) { - if (gDebug > 0) Warning("ModifyWorkerLists", "request not completely full filled"); + if (gDebug > 0) + Warning("ModifyWorkerLists", "request not completely full filled"); } else { Error("ModifyWorkerLists", "request failed"); } @@ -10664,6 +11876,33 @@ Int_t TProof::ModifyWorkerLists(const char *ord, Bool_t add) return nwc; } +//_____________________________________________________________________________ +void TProof::SaveActiveList() +{ + // Save current list of active workers + + if (!fActiveSlavesSaved.IsNull()) fActiveSlavesSaved = ""; + if (fInactiveSlaves->GetSize() == 0) { + fActiveSlavesSaved = "*"; + } else { + TIter nxw(fActiveSlaves); + TSlave *wk = 0; + while ((wk = (TSlave *)nxw())) { fActiveSlavesSaved += TString::Format("%s,", wk->GetOrdinal()); } + } +} + +//_____________________________________________________________________________ +void TProof::RestoreActiveList() +{ + // Restore saved list of active workers + + // Clear the current active list + DeactivateWorker("*", kFALSE); + // Restore the previous active list + if (!fActiveSlavesSaved.IsNull()) + ActivateWorker(fActiveSlavesSaved, kFALSE); +} + //_____________________________________________________________________________ TProof *TProof::Open(const char *cluster, const char *conffile, const char *confdir, Int_t loglevel) @@ -10784,7 +12023,7 @@ TProof *TProof::Open(const char *cluster, const char *conffile, if (mgr && mgr->IsValid()) { // If XProofd we always attempt an attach first (unless - // explicitely not requested). + // explicitly not requested). Bool_t attach = (create || mgr->IsProofd() || mgr->IsLite()) ? kFALSE : kTRUE; if (attach) { TProofDesc *d = 0; @@ -10902,7 +12141,7 @@ void TProof::ResetEnvVars() //______________________________________________________________________________ void TProof::SaveWorkerInfo() { - // Save informations about the worker set in the file .workers in the working + // Save information about the worker set in the file .workers in the working // dir. Called each time there is a change in the worker setup, e.g. by // TProof::MarkBad(). @@ -10934,38 +12173,76 @@ void TProof::SaveWorkerInfo() // Do we need to register an additional line for another log? TString addlogext; + TString addLogTag; if (gSystem->Getenv("PROOF_ADDITIONALLOG")) { addlogext = gSystem->Getenv("PROOF_ADDITIONALLOG"); + TPMERegexp reLogTag("^__(.*)__\\.log"); // $ + if (reLogTag.Match(addlogext) == 2) { + addLogTag = reLogTag[1]; + } + else { + addLogTag = "+++"; + } if (gDebug > 0) Info("SaveWorkerInfo", "request for additional line with ext: '%s'", addlogext.Data()); } + // Used to eliminate datetime and PID from workdir to obtain log file name + TPMERegexp re("(.*?)-[0-9]+-[0-9]+$"); + // Loop over the list of workers (active is any worker not flagged as bad) TIter nxa(fSlaves); TSlave *wrk = 0; + TString logfile; while ((wrk = (TSlave *) nxa())) { Int_t status = (fBadSlaves && fBadSlaves->FindObject(wrk)) ? 0 : 1; + logfile = wrk->GetWorkDir(); + if (re.Match(logfile) == 2) logfile = re[1]; + else continue; // invalid (should not happen) // Write out record for this worker fprintf(fwrk,"%s@%s:%d %d %s %s.log\n", wrk->GetUser(), wrk->GetName(), wrk->GetPort(), status, - wrk->GetOrdinal(), wrk->GetWorkDir()); + wrk->GetOrdinal(), logfile.Data()); // Additional line, if required if (addlogext.Length() > 0) { - fprintf(fwrk,"%s@%s:%d %d %s %s.%s\n", + fprintf(fwrk,"%s@%s:%d %d %s(%s) %s.%s\n", wrk->GetUser(), wrk->GetName(), wrk->GetPort(), status, - wrk->GetOrdinal(), wrk->GetWorkDir(), addlogext.Data()); + wrk->GetOrdinal(), addLogTag.Data(), logfile.Data(), addlogext.Data()); } + } - + // Loop also over the list of bad workers (if they failed to startup they are not in - // the overall list) + // the overall list TIter nxb(fBadSlaves); while ((wrk = (TSlave *) nxb())) { + logfile = wrk->GetWorkDir(); + if (re.Match(logfile) == 2) logfile = re[1]; + else continue; // invalid (should not happen) if (!fSlaves->FindObject(wrk)) { // Write out record for this worker fprintf(fwrk,"%s@%s:%d 0 %s %s.log\n", wrk->GetUser(), wrk->GetName(), wrk->GetPort(), - wrk->GetOrdinal(), wrk->GetWorkDir()); + wrk->GetOrdinal(), logfile.Data()); + } + } + + // Eventually loop over the list of gracefully terminated workers: we'll get + // logfiles from those workers as well. They'll be shown with a special + // status of "2" + TIter nxt(fTerminatedSlaveInfos); + TSlaveInfo *sli; + while (( sli = (TSlaveInfo *)nxt() )) { + logfile = sli->GetDataDir(); + if (re.Match(logfile) == 2) logfile = re[1]; + else continue; // invalid (should not happen) + fprintf(fwrk, "%s 2 %s %s.log\n", + sli->GetName(), sli->GetOrdinal(), logfile.Data()); + // Additional line, if required + if (addlogext.Length() > 0) { + fprintf(fwrk, "%s 2 %s(%s) %s.%s\n", + sli->GetName(), sli->GetOrdinal(), addLogTag.Data(), + logfile.Data(), addlogext.Data()); } } @@ -11118,49 +12395,95 @@ Int_t TProof::AssertDataSet(TDSet *dset, TList *input, // defined: assume that a dataset, stored on the PROOF master by that // name, should be processed. if (!dataset) { - TString dsns(dsname.Data()), dsn1; - Int_t from1 = 0; - while (dsns.Tokenize(dsn1, from1, "[, ]")) { - TString dsn2, enl; - Int_t from2 = 0; - TFileCollection *fc = 0; - while (dsn1.Tokenize(dsn2, from2, "|")) { - enl = ""; - Int_t ienl = dsn2.Index("?enl="); - if (ienl != kNPOS) { - enl = dsn2(ienl + 5, dsn2.Length()); - dsn2.Remove(ienl); - } - if ((fc = mgr->GetDataSet(dsn2.Data()))) { - // Save dataset name in TFileInfo's title to use it in TDset - TIter nxfi(fc->GetList()); - TFileInfo *fi = 0; - while ((fi = (TFileInfo *) nxfi())) { fi->SetTitle(dsn2.Data()); } - dsnparse = dsn2; - if (!dataset) { - // This is our dataset - dataset = fc; - } else { - // Add it to the dataset - dataset->Add(fc); - SafeDelete(fc); + + // First of all check if the full string (except the "entry list" part) + // is the name of a single existing dataset: if it is, don't break it + // into parts + TString dsns( dsname.Data() ), enl; + Ssiz_t eli = dsns.Index("?enl="); + TFileCollection *fc; + if (eli != kNPOS) { + enl = dsns(eli+5, dsns.Length()); + dsns.Remove(eli, dsns.Length()-eli); + } + + // Check if the entry list is valid. If it has spaces, commas, or pipes, + // it is not considered as valid and we revert to the "multiple datasets" + // case + Bool_t validEnl = ((enl.Index("|") == kNPOS) && + (enl.Index(",") == kNPOS) && (enl.Index(" ") == kNPOS)); + + if (validEnl && (( fc = mgr->GetDataSet(dsns) ))) { + + // + // String corresponds to ONE dataset only + // + + TIter nxfi(fc->GetList()); + TFileInfo *fi; + while (( fi = (TFileInfo *)nxfi() )) + fi->SetTitle(dsns.Data()); + dataset = fc; + dsnparse = dsns; // without entry list + + // Adds the entry list (or empty string if not specified) + datasets->Add( new TPair(dataset, new TObjString( enl.Data() )) ); + + } + else { + + // + // String does NOT correspond to one dataset: check if many datasets + // were specified instead + // + + dsns = dsname.Data(); + TString dsn1; + Int_t from1 = 0; + while (dsns.Tokenize(dsn1, from1, "[, ]")) { + TString dsn2; + Int_t from2 = 0; + while (dsn1.Tokenize(dsn2, from2, "|")) { + enl = ""; + Int_t ienl = dsn2.Index("?enl="); + if (ienl != kNPOS) { + enl = dsn2(ienl + 5, dsn2.Length()); + dsn2.Remove(ienl); + } + if ((fc = mgr->GetDataSet(dsn2.Data()))) { + // Save dataset name in TFileInfo's title to use it in TDset + TIter nxfi(fc->GetList()); + TFileInfo *fi; + while ((fi = (TFileInfo *) nxfi())) { fi->SetTitle(dsn2.Data()); } + dsnparse = dsn2; + if (!dataset) { + // This is our dataset + dataset = fc; + } else { + // Add it to the dataset + dataset->Add(fc); + SafeDelete(fc); + } } } - } - // The dataset name(s) in the first element - if (dataset) { - if (dataset->GetList()->First()) - ((TFileInfo *)(dataset->GetList()->First()))->SetTitle(dsn1.Data()); - // Add it to the local list - if (enl.IsNull()) { - datasets->Add(new TPair(dataset, new TObjString(""))); - } else { + // The dataset name(s) in the first element + if (dataset) { + if (dataset->GetList()->First()) + ((TFileInfo *)(dataset->GetList()->First()))->SetTitle(dsn1.Data()); + // Add it to the local list datasets->Add(new TPair(dataset, new TObjString(enl.Data()))); } + // Reset the pointer + dataset = 0; } - // Reset the pointer - dataset = 0; + } + + // + // At this point the dataset(s) to be processed, if any, are found in the + // "datasets" variable + // + if (!datasets || datasets->GetSize() <= 0) { emsg.Form("no dataset(s) found on the master corresponding to: %s", dsname.Data()); return -1; @@ -11719,5 +13042,3 @@ Int_t TProof::SavePerfTree(const char *pf, const char *ref) // Done return 0; } - - diff --git a/proof/proof/src/TProofLite.cxx b/proof/proof/src/TProofLite.cxx index 3ee36d6e6c690..6ad4d0f23f696 100644 --- a/proof/proof/src/TProofLite.cxx +++ b/proof/proof/src/TProofLite.cxx @@ -148,6 +148,9 @@ Int_t TProofLite::Init(const char *, const char *conffile, fValid = kFALSE; + // Connected to terminal? + fTty = (isatty(0) == 0 || isatty(1) == 0) ? kFALSE : kTRUE; + if (TestBit(TProof::kIsMaster)) { // Fill default conf file and conf dir if (!conffile || strlen(conffile) == 0) @@ -226,7 +229,8 @@ Int_t TProofLite::Init(const char *, const char *conffile, fQueryLock, fLogFileW); // Apply quotas, if any - if (fQMgr && fQMgr->ApplyMaxQueries(10) != 0) + Int_t maxq = gEnv->GetValue("ProofLite.MaxQueriesSaved", 10); + if (fQMgr && fQMgr->ApplyMaxQueries(maxq) != 0) Warning("Init", "problems applying fMaxQueries"); if (InitDataSetManager() != 0) @@ -275,6 +279,9 @@ Int_t TProofLite::Init(const char *, const char *conffile, fCurrentMonitor = 0; fServSock = 0; + fTerminatedSlaveInfos = new TList; + fTerminatedSlaveInfos->SetOwner(kTRUE); + // Control how to start the workers; copy-on-write (fork) is *very* // experimental and available on Unix only. fForkStartup = kFALSE; @@ -299,6 +306,7 @@ Int_t TProofLite::Init(const char *, const char *conffile, Int_t from = 0; TString ldir; while (globpack.Tokenize(ldir, from, ":")) { + TProofServ::ResolveKeywords(ldir); if (gSystem->AccessPathName(ldir, kReadPermission)) { Warning("Init", "directory for global packages %s does not" " exist or is not readable", ldir.Data()); @@ -336,7 +344,7 @@ Int_t TProofLite::Init(const char *, const char *conffile, fAllMonitor->DeActivateAll(); // By default go into parallel mode - GoParallel(9999, kFALSE); + GoParallel(-1, kFALSE); // Send relevant initial state to slaves SendInitialState(); @@ -415,15 +423,39 @@ Int_t TProofLite::GetNumberOfWorkers(const char *url) return 0; } + TString nw; Int_t nWorkers = -1; + Bool_t urlSetting = kFALSE; if (url && strlen(url)) { - TString o(url); - Int_t in = o.Index("workers="); + nw = url; + Int_t in = nw.Index("workers="); if (in != kNPOS) { - o.Remove(0, in + strlen("workers=")); - while (!o.IsDigit()) - o.Remove(o.Length()-1); - nWorkers = (!o.IsNull()) ? o.Atoi() : nWorkers; + nw.Remove(0, in + strlen("workers=")); + while (!nw.IsDigit()) + nw.Remove(nw.Length()-1); + if (!nw.IsNull()) { + if ((nWorkers = nw.Atoi()) <= 0) { + ::Warning("TProofLite::GetNumberOfWorkers", + "number of workers specified by 'workers='" + " is non-positive: using default"); + } else { + urlSetting = kFALSE; + } + } + } + } + if (!urlSetting && fgProofEnvList) { + // Check PROOF_NWORKERS + TNamed *nm = (TNamed *) fgProofEnvList->FindObject("PROOF_NWORKERS"); + if (nm) { + nw = nm->GetTitle(); + if (nw.IsDigit()) { + if ((nWorkers = nw.Atoi()) == 0) { + ::Warning("TProofLite::GetNumberOfWorkers", + "number of workers specified by 'workers='" + " is non-positive: using default"); + } + } } } if (nWorkers <= 0) { @@ -583,8 +615,8 @@ Int_t TProofLite::SetupWorkers(Int_t opt, TList *startedWorkers) } // Monitor good workers + fSlaves->Add(wrk); if (wrk->IsValid()) { - fSlaves->Add(wrk); if (opt == 1) fActiveSlaves->Add(wrk); fAllMonitor->Add(wrk->GetSocket()); // Record also in the list for termination @@ -621,7 +653,7 @@ Int_t TProofLite::SetupWorkers(Int_t opt, TList *startedWorkers) // Update group view SendGroupView(); // By default go into parallel mode - SetParallel(9999, 0); + SetParallel(-1, 0); } // Done return 0; @@ -950,6 +982,7 @@ void TProofLite::SetQueryRunning(TProofQueryResult *pq) pq->SetRunning(startlog, parlist, GetParallel()); // Bytes and CPU at start (we will calculate the differential at end) + AskStatistics(); pq->SetProcessInfo(pq->GetEntries(), GetCpuTime(), GetBytesRead()); } @@ -995,9 +1028,11 @@ Long64_t TProofLite::Process(TDSet *dset, const char *selector, Option_t *option // For the time being cannot accept other queries if not idle, even if in async // mode; needs to set up an event handler to manage that - TString opt(option), optfb; + TString opt(option), optfb, outfile; // Enable feedback, if required if (opt.Contains("fb=") || opt.Contains("feedback=")) SetFeedback(opt, optfb, 0); + // Define output file, either from 'opt' or the default one + if (HandleOutputOptions(opt, outfile, 0) != 0) return -1; // Resolve query mode fSync = (GetQueryMode(opt) == kSync); @@ -1033,8 +1068,8 @@ Long64_t TProofLite::Process(TDSet *dset, const char *selector, Option_t *option // If just a name was given to identify the dataset, retrieve it from the // local files // Make sure the dataset contains the information needed + TString emsg; if ((!hasNoData) && dset->GetListOfElements()->GetSize() == 0) { - TString emsg; if (TProof::AssertDataSet(dset, fPlayer->GetInputList(), fDataSetManager, emsg) != 0) { Error("Process", "from AssertDataSet: %s", emsg.Data()); return -1; @@ -1043,6 +1078,38 @@ Long64_t TProofLite::Process(TDSet *dset, const char *selector, Option_t *option Error("Process", "no files to process!"); return -1; } + } else if (hasNoData) { + // Check if we are required to process with TPacketizerFile a registered dataset + TNamed *ftp = dynamic_cast<TNamed *>(fPlayer->GetInputList()->FindObject("PROOF_FilesToProcess")); + if (ftp) { + TString dsn(ftp->GetTitle()); + if (!dsn.Contains(":") || dsn.BeginsWith("dataset:")) { + dsn.ReplaceAll("dataset:", ""); + // Make sure we have something in input and a dataset manager + if (!fDataSetManager) { + emsg.Form("dataset manager not initialized!"); + } else { + TFileCollection *fc = 0; + // Get the dataset + if (!(fc = fDataSetManager->GetDataSet(dsn))) { + emsg.Form("requested dataset '%s' does not exists", dsn.Data()); + } else { + TMap *fcmap = TProofServ::GetDataSetNodeMap(fc, emsg); + if (fcmap) { + fPlayer->GetInputList()->Remove(ftp); + delete ftp; + fcmap->SetOwner(kTRUE); + fcmap->SetName("PROOF_FilesToProcess"); + fPlayer->GetInputList()->Add(fcmap); + } + } + } + if (!emsg.IsNull()) { + Error("HandleProcess", "%s", emsg.Data()); + return -1; + } + } + } } TString selec(selector), varexp, selection, objname; @@ -1061,11 +1128,26 @@ Long64_t TProofLite::Process(TDSet *dset, const char *selector, Option_t *option // Create instance of query results (the data set is added after Process) TProofQueryResult *pq = MakeQueryResult(nentries, opt, first, 0, selec); + // Check if queries must be saved into files + // Automatic saving is controlled by ProofLite.AutoSaveQueries + Bool_t savequeries = + (!strcmp(gEnv->GetValue("ProofLite.AutoSaveQueries", "off"), "on")) ? kTRUE : kFALSE; + + // Keep queries in memory and how many (-1 = all, 0 = none, ...) + Int_t memqueries = gEnv->GetValue("ProofLite.MaxQueriesMemory", 10); + // If not a draw action add the query to the main list if (!(pq->IsDraw())) { - if (fQMgr->Queries()) fQMgr->Queries()->Add(pq); + if (fQMgr->Queries()) { + if (memqueries > 0 && fQMgr->Queries()->GetSize() >= memqueries) { + // Remove oldest + TObject *qfst = fQMgr->Queries()->First(); + fQMgr->Queries()->Remove(qfst); + } + if (memqueries >= 0) fQMgr->Queries()->Add(pq); + } // Also save it to queries dir - fQMgr->SaveQuery(pq); + if (savequeries) fQMgr->SaveQuery(pq); } // Set the query number @@ -1075,10 +1157,11 @@ Long64_t TProofLite::Process(TDSet *dset, const char *selector, Option_t *option SetQueryRunning(pq); // Save to queries dir, if not standard draw - if (!(pq->IsDraw())) - fQMgr->SaveQuery(pq); - else + if (!(pq->IsDraw())) { + if (savequeries) fQMgr->SaveQuery(pq); + } else { fQMgr->IncrementDrawQueries(); + } // Start or reset the progress dialog if (!gROOT->IsBatch()) { @@ -1126,6 +1209,9 @@ Long64_t TProofLite::Process(TDSet *dset, const char *selector, Option_t *option sh = gSystem->RemoveSignalHandler(gApplication->GetSignalHandler()); } + // Make sure we get a fresh result + fOutputList.Clear(); + // Start the additional workers now if using fork-based startup TList *startedWorkers = 0; if (fForkStartup) { @@ -1187,8 +1273,10 @@ Long64_t TProofLite::Process(TDSet *dset, const char *selector, Option_t *option if (fDataSetManager && fPlayer->GetOutputList()) { TNamed *psr = (TNamed *) fPlayer->GetOutputList()->FindObject("PROOFSERV_RegisterDataSet"); if (psr) { - if (RegisterDataSets(fPlayer->GetInputList(), fPlayer->GetOutputList()) != 0) - Warning("ProcessNext", "problems registering produced datasets"); + TString err; + if (TProofServ::RegisterDataSets(fPlayer->GetInputList(), + fPlayer->GetOutputList(), fDataSetManager, err) != 0) + Warning("ProcessNext", "problems registering produced datasets: %s", err.Data()); fPlayer->GetOutputList()->Remove(psr); delete psr; } @@ -1198,9 +1286,7 @@ Long64_t TProofLite::Process(TDSet *dset, const char *selector, Option_t *option AskStatistics(); if (!(pq->IsDraw())) { if (fQMgr->FinalizeQuery(pq, this, fPlayer)) { - // Automatic saving is controlled by ProofLite.AutoSaveQueries - if (!strcmp(gEnv->GetValue("ProofLite.AutoSaveQueries", "off"), "on")) - fQMgr->SaveQuery(pq, -1); + if (savequeries) fQMgr->SaveQuery(pq, -1); } } @@ -1212,10 +1298,13 @@ Long64_t TProofLite::Process(TDSet *dset, const char *selector, Option_t *option // If the last object, notify the GUI that the result arrived QueryResultReady(Form("%s:%s", pq->GetTitle(), pq->GetName())); // Keep in memory only light info about a query - if (!(pq->IsDraw())) { - if (fQMgr && fQMgr->Queries()) + if (!(pq->IsDraw()) && memqueries >= 0) { + if (fQMgr && fQMgr->Queries()) { + TQueryResult *pqr = pq->CloneInfo(); + if (pqr) fQMgr->Queries()->Add(pqr); // Remove from the fQueries list fQMgr->Queries()->Remove(pq); + } } // To get the prompt back TString msg; @@ -1229,6 +1318,8 @@ Long64_t TProofLite::Process(TDSet *dset, const char *selector, Option_t *option SetPerfTree(0); } } + // Finalise output file settings (opt is ignored in here) + if (HandleOutputOptions(opt, outfile, 1) != 0) return -1; // Done return rv; @@ -1779,6 +1870,16 @@ Bool_t TProofLite::RegisterDataSet(const char *uri, return kFALSE; } + Bool_t parallelverify = kFALSE; + TString sopt(optStr); + if (sopt.Contains("V") && !sopt.Contains("S")) { + // We do verification in parallel later on; just register for now + parallelverify = kTRUE; + sopt.ReplaceAll("V", ""); + } + // This would screw up things remotely, make sure is not there + sopt.ReplaceAll("S", ""); + Bool_t result = kTRUE; if (fDataSetManager->TestBit(TDataSetManager::kAllowRegister)) { // Check the list @@ -1787,18 +1888,28 @@ Bool_t TProofLite::RegisterDataSet(const char *uri, result = kFALSE; } // Register the dataset (quota checks are done inside here) - result = (fDataSetManager->RegisterDataSet(uri, dataSet, optStr) == 0) + result = (fDataSetManager->RegisterDataSet(uri, dataSet, sopt) == 0) ? kTRUE : kFALSE; } else { - Info("RegisterDataSets", "dataset registration not allowed"); + Info("RegisterDataSet", "dataset registration not allowed"); result = kFALSE; } if (!result) Error("RegisterDataSet", "dataset was not saved"); + // If old server or not verifying in parallel we are done + if (!parallelverify) return result; + + // If we are here it means that we will verify in parallel + sopt += "V"; + if (VerifyDataSet(uri, sopt) < 0){ + Error("RegisterDataSet", "problems verifying dataset '%s'", uri); + return kFALSE; + } + // Done - return result; + return kTRUE; } //______________________________________________________________________________ @@ -1930,7 +2041,7 @@ Int_t TProofLite::RemoveDataSet(const char *uri, const char *) } //______________________________________________________________________________ -Int_t TProofLite::VerifyDataSet(const char *uri, const char *) +Int_t TProofLite::VerifyDataSet(const char *uri, const char *optStr) { // Verify if all files in the specified dataset are available. // Print a list and return the number of missing files. @@ -1941,15 +2052,20 @@ Int_t TProofLite::VerifyDataSet(const char *uri, const char *) } Int_t rc = -1; - if (fDataSetManager->TestBit(TDataSetManager::kAllowVerify)) { - rc = fDataSetManager->ScanDataSet(uri); - } else { - Info("VerifyDataSet", "dataset verification not allowed"); - return -1; - } + TString sopt(optStr); + if (sopt.Contains("S")) { + if (fDataSetManager->TestBit(TDataSetManager::kAllowVerify)) { + rc = fDataSetManager->ScanDataSet(uri); + } else { + Info("VerifyDataSet", "dataset verification not allowed"); + rc = -1; + } + return rc; + } + // Done - return rc; + return VerifyDataSetParallel(uri, optStr); } //______________________________________________________________________________ @@ -2149,75 +2265,47 @@ void TProofLite::FindUniqueSlaves() } //______________________________________________________________________________ -Int_t TProofLite::RegisterDataSets(TList *in, TList *out) +void TProofLite::ShowData() { - // Register TFileCollections in 'out' as datasets according to the rules in 'in' - - PDB(kDataset, 1) Info("RegisterDataSets", "enter"); - - if (!in || !out) return 0; - - TString msg; - TIter nxo(out); - TObject *o = 0; - while ((o = nxo())) { - // Only file collections TFileCollection - TFileCollection *ds = dynamic_cast<TFileCollection*> (o); - if (ds) { - // The tag and register option - TNamed *fcn = 0; - TString tag = TString::Format("DATASET_%s", ds->GetName()); - if (!(fcn = (TNamed *) out->FindObject(tag))) continue; - // Register option - TString regopt(fcn->GetTitle()); - // Register this dataset - if (fDataSetManager) { - if (fDataSetManager->TestBit(TDataSetManager::kAllowRegister)) { - // Extract the list - if (ds->GetList()->GetSize() > 0) { - // Register the dataset (quota checks are done inside here) - msg.Form("Registering and verifying dataset '%s' ... ", ds->GetName()); - Info("RegisterDataSets", "%s", msg.Data()); - // Always allow verification for this action - Bool_t allowVerify = fDataSetManager->TestBit(TDataSetManager::kAllowVerify) ? kTRUE : kFALSE; - if (regopt.Contains("V") && !allowVerify) - fDataSetManager->SetBit(TDataSetManager::kAllowVerify); - Int_t rc = fDataSetManager->RegisterDataSet(ds->GetName(), ds, regopt); - // Reset to the previous state if needed - if (regopt.Contains("V") && !allowVerify) - fDataSetManager->ResetBit(TDataSetManager::kAllowVerify); - if (rc != 0) { - Warning("RegisterDataSets", - "failure registering dataset '%s'", ds->GetName()); - msg.Form("Registering and verifying dataset '%s' ... failed! See log for more details", ds->GetName()); - } else { - Info("RegisterDataSets", "dataset '%s' successfully registered", ds->GetName()); - msg.Form("Registering and verifying dataset '%s' ... OK", ds->GetName()); - } - Info("RegisterDataSets", "%s", msg.Data()); - // Notify - PDB(kDataset, 2) { - Info("RegisterDataSets","printing collection"); - ds->Print("F"); - } - } else { - Warning("RegisterDataSets", "collection '%s' is empty", o->GetName()); - } - } else { - Info("RegisterDataSets", "dataset registration not allowed"); - return -1; - } - } else { - Error("RegisterDataSets", "dataset manager is undefined!"); - return -1; + // List contents of the data directory in the sandbox. + // This is the place where files produced by the client queries are kept + + if (!IsValid()) return; + + // Get worker infos + TList *wrki = GetListOfSlaveInfos(); + TSlaveInfo *wi = 0; + TIter nxwi(wrki); + while ((wi = (TSlaveInfo *) nxwi())) { + ShowDataDir(wi->GetDataDir()); + } +} + +//______________________________________________________________________________ +void TProofLite::ShowDataDir(const char *dirname) +{ + // List contents of the data directory 'dirname' + + if (!dirname) return; + + FileStat_t dirst; + if (gSystem->GetPathInfo(dirname, dirst) != 0) return; + if (!R_ISDIR(dirst.fMode)) return; + + void *dirp = gSystem->OpenDirectory(dirname); + TString fn; + const char *ent = 0; + while ((ent = gSystem->GetDirEntry(dirp))) { + fn.Form("%s/%s", dirname, ent); + FileStat_t st; + if (gSystem->GetPathInfo(fn.Data(), st) == 0) { + if (R_ISREG(st.fMode)) { + Printf("lite:0| %s", fn.Data()); + } else if (R_ISREG(st.fMode)) { + ShowDataDir(fn.Data()); } - // Cleanup temporary stuff - out->Remove(fcn); - SafeDelete(fcn); } } - - PDB(kDataset, 1) Info("RegisterDataSets", "exit"); // Done - return 0; + return; } diff --git a/proof/proof/src/TProofLog.cxx b/proof/proof/src/TProofLog.cxx index e097351d89df8..5ad8eba2dc5d8 100644 --- a/proof/proof/src/TProofLog.cxx +++ b/proof/proof/src/TProofLog.cxx @@ -107,9 +107,9 @@ Int_t TProofLog::Retrieve(const char *ord, TProofLog::ERetrieveOpt opt, } else { nd++; } - Int_t frac = (nd + nb) / nel * 100; - msg.Form("Retrieving logs: %d ok, %d not ok (%d %% processed) \r", nd, nb, frac); - Prt(msg.Data()); + Float_t frac = ((Float_t)nd + (Float_t)nb) * 100. / (Float_t)nel; + msg.Form("Retrieving logs: %d ok, %d not ok (%.0f%% processed)\r", nd, nb, frac); + Prt(msg.Data(), kFALSE); } } Prt("\n"); @@ -177,7 +177,7 @@ void TProofLog::Print(Option_t *opt) const } //________________________________________________________________________ -void TProofLog::Prt(const char *what) +void TProofLog::Prt(const char *what, Bool_t newline) { // Special printing procedure @@ -187,7 +187,8 @@ void TProofLog::Prt(const char *what) Emit("Prt(const char*)", what); } else { FILE *where = (fFILE) ? (FILE *)fFILE : stderr; - fprintf(where, "%s\n", what); + fputs(what, where); + if (newline) fputc('\n', where); } } } @@ -375,29 +376,43 @@ Int_t TProofLogElem::Retrieve(TProofLog::ERetrieveOpt opt, const char *pattern) // Make sure we have a reference manager if (!fLogger->fMgr || !fLogger->fMgr->IsValid()) { - Warning("Retrieve","No reference manager: corruption?"); + Warning("Retrieve", "No reference manager: corruption?"); return -1; } + // Print some info on the file + if (gDebug >= 2) { + Info("Retrieve", "Retrieving from ordinal %s file %s with pattern %s", + GetName(), GetTitle(), (pattern ? pattern : "(no pattern)")); + } + // Determine offsets if (opt == TProofLog::kAll) { // Re-read everything fFrom = 0; fTo = -1; + if (gDebug >= 1) + Info("Retrieve", "Retrieving the whole file"); } else if (opt == TProofLog::kLeading) { // Read leading part fFrom = 0; fTo = fgMaxTransferSize; + if (gDebug >= 1) + Info("Retrieve", "Retrieving the leading %lld lines of file", fTo); } else if (opt == TProofLog::kGrep) { // Retrieve lines containing 'pattern', which must be defined if (!pattern || strlen(pattern) <= 0) { Error("Retrieve", "option 'Grep' requires a pattern"); return -1; } + if (gDebug >= 1) + Info("Retrieve", "Retrieving only lines filtered with %s", pattern); } else { // Read trailing part fFrom = -fgMaxTransferSize; fTo = -1; + if (gDebug >= 1) + Info("Retrieve", "Retrieving the last %lld lines of file", -fFrom); } // Reset the macro @@ -410,10 +425,21 @@ Int_t TProofLogElem::Retrieve(TProofLog::ERetrieveOpt opt, const char *pattern) // Readout the buffer TObjString *os = 0; if (fLogger->fMgr) { - if (opt == TProofLog::kGrep) - os = fLogger->fMgr->ReadBuffer(GetTitle(), pattern); + TString fileName = GetTitle(); + if (fileName.Contains("__igprof.pp__")) { + // File is an IgProf log. Override all patterns and preprocess it + if (gDebug >= 1) + Info("Retrieve", "Retrieving analyzed IgProf performance profile"); + TString analyzeAndFilter = \ + "|( T=`mktemp` && cat > \"$T\" ; igprof-analyse -d -g \"$T\" ; rm -f \"$T\" )"; + if (pattern && (*pattern == '|')) + analyzeAndFilter.Append(pattern); + os = fLogger->fMgr->ReadBuffer(fileName.Data(), analyzeAndFilter.Data()); + } + else if (opt == TProofLog::kGrep) + os = fLogger->fMgr->ReadBuffer(fileName.Data(), pattern); else - os = fLogger->fMgr->ReadBuffer(GetTitle(), fFrom, len); + os = fLogger->fMgr->ReadBuffer(fileName.Data(), fFrom, len); } if (os) { // Loop over lines diff --git a/proof/proof/src/TProofMgr.cxx b/proof/proof/src/TProofMgr.cxx index 0f96960db6bd5..328961cdf0088 100644 --- a/proof/proof/src/TProofMgr.cxx +++ b/proof/proof/src/TProofMgr.cxx @@ -90,16 +90,6 @@ TProofMgr::TProofMgr(const char *url, Int_t, const char *alias) fUrl.SetPort(port); } - // Make sure that the user is defined - if (strlen(fUrl.GetUser()) <= 0) { - // Fill in the default user - UserGroup_t *pw = gSystem->GetUserInfo(); - if (pw) { - fUrl.SetUser(pw->fUser); - delete pw; - } - } - // Check and save the host FQDN ... if (strcmp(fUrl.GetHost(), "__lite__")) { if (strcmp(fUrl.GetHost(), fUrl.GetHostFQDN())) @@ -1021,6 +1011,33 @@ TFileCollection *TProofMgr::UploadFiles(const char *srcfiles, return ds; } +//______________________________________________________________________________ +Int_t TProofMgr::Rm(const char *what, const char *, const char *) +{ + // Run 'rm' on 'what'. Locally it is just a call to TSystem::Unlink . + + Int_t rc = -1; + // Nothing to do if not in contact with proofserv + if (!IsValid()) { + Error("Rm", "invalid TProofMgr - do nothing"); + return rc; + } + // Nothing to do if not in contact with proofserv + if (!what || (what && strlen(what) <= 0)) { + Error("Rm", "path undefined!"); + return rc; + } + + TUrl u(what); + if (!strcmp(u.GetProtocol(), "file")) { + rc = gSystem->Unlink(u.GetFile()); + } else { + rc = gSystem->Unlink(what); + } + // Done + return (rc == 0) ? 0 : -1; +} + // // TProofDesc // @@ -1031,7 +1048,7 @@ ClassImp(TProofDesc) void TProofDesc::Print(Option_t *) const { // Dump the content to the screen. - const char *st[] = { "unknown", "idle", "processsing", "shutting down"}; + const char *st[] = { "unknown", "idle", "processing", "shutting down"}; Printf("// # %d", fLocalId); Printf("// alias: %s, url: \"%s\"", GetTitle(), GetUrl()); diff --git a/proof/proofplayer/src/TProofOutputFile.cxx b/proof/proof/src/TProofOutputFile.cxx similarity index 93% rename from proof/proofplayer/src/TProofOutputFile.cxx rename to proof/proof/src/TProofOutputFile.cxx index 9c3054778efaa..cb1c74218037b 100644 --- a/proof/proofplayer/src/TProofOutputFile.cxx +++ b/proof/proof/src/TProofOutputFile.cxx @@ -46,6 +46,8 @@ TProofOutputFile::TProofOutputFile(const char *path, fMerged = kFALSE; fMerger = 0; fDataSet = 0; + ResetBit(TProofOutputFile::kRetrieve); + ResetBit(TProofOutputFile::kSwapFile); Init(path, dsname); } @@ -114,12 +116,17 @@ void TProofOutputFile::Init(const char *path, const char *dsname) fFileName = u.GetFile(); // The name is used to identify this entity SetName(gSystem->BaseName(fFileName.Data())); - if (dsname && strlen(dsname) > 0) { - // This is the dataset name in case such option is chosen - SetTitle(dsname); - } else { - // Default dataset name - SetTitle(GetName()); + // The title is the dataset name in the case such option is chosen. + // In the merging case it can be the final location of the file on the client if the retrieve + // option is chosen; if the case, this set in TProofPlayer::MergeOutputFiles. + if (fRunType == kDataset) { + if (dsname && strlen(dsname) > 0) { + // This is the dataset name in case such option is chosen + SetTitle(dsname); + } else { + // Default dataset name + SetTitle(GetName()); + } } // Options and anchor, if any if (u.GetOptions() && strlen(u.GetOptions()) > 0) @@ -187,16 +194,10 @@ void TProofOutputFile::Init(const char *path, const char *dsname) // Make sure the the path exists if (AssertDir(dirPath) != 0) Error("Init", "problems asserting path '%s'", dirPath.Data()); - // Check if a local data server has been specified - if (gSystem->Getenv("LOCALDATASERVER")) { - fDir = gSystem->Getenv("LOCALDATASERVER"); - if (!fDir.EndsWith("/")) fDir += "/"; - } - TString dirProto = TUrl(fDir).GetProtocol(); - // Remove prefix, if any, if included and if Xrootd - TString pfx = gEnv->GetValue("Path.Localroot",""); - if (!pfx.IsNull() && dirPath.BeginsWith(pfx) && - (dirProto == "root" || dirProto == "xrd")) dirPath.Remove(0, pfx.Length()); + // Take into account local server settings + TProofServ::GetLocalServer(fDir); + TProofServ::FilterLocalroot(dirPath, fDir); + // The path to be used to address the file fDir += dirPath; } // Notify @@ -260,7 +261,7 @@ TFile* TProofOutputFile::OpenFile(const char* opt) // Create the path TString fileLoc; fileLoc.Form("%s/%s%s", fRawDir.Data(), fFileName.Data(), fOptionsAnchor.Data()); - + // Open the file TFile *retFile = TFile::Open(fileLoc, opt); @@ -277,34 +278,34 @@ Int_t TProofOutputFile::AdoptFile(TFile *f) Error("AdoptFile", "file is undefined or zombie!"); return -1; } - if (!f->GetEndpointUrl()) { + const TUrl *u = f->GetEndpointUrl(); + if (!u) { Error("AdoptFile", "file end-point url is undefined!"); return -1; } // Set the name and dir - TUrl u(*(f->GetEndpointUrl())); fIsLocal = kFALSE; - if (!strcmp(u.GetProtocol(), "file")) { + if (!strcmp(u->GetProtocol(), "file")) { fIsLocal = kTRUE; - fDir = u.GetFile(); + fDir = u->GetFile(); } else { - fDir = u.GetUrl(); + fDir = u->GetUrl(); } fFileName = gSystem->BaseName(fDir.Data()); fDir.ReplaceAll(fFileName, ""); fRawDir = fDir; - // Remove prefix, if any - TString pfx = gEnv->GetValue("Path.Localroot",""); - if (!pfx.IsNull()) fDir.ReplaceAll(pfx, ""); - // Include the local data server info, if any - if (gSystem->Getenv("LOCALDATASERVER")) { - TString localDS(gSystem->Getenv("LOCALDATASERVER")); - if (!localDS.EndsWith("/")) localDS += "/"; - fDir.Insert(0, localDS); + // If local remove prefix, if any + if (fIsLocal) { + TString localDS; + TProofServ::GetLocalServer(localDS); + if (!localDS.IsNull()) { + TProofServ::FilterLocalroot(fDir, localDS); + fDir.Insert(0, localDS); + } } - + return 0; } @@ -378,7 +379,7 @@ Long64_t TProofOutputFile::Merge(TCollection* list) // Add special local URL to keep track of the file path.Form("%s/%s?node=%s", GetDir(kTRUE), GetFileName(), GetLocalHost()); fi->AddUrl(path); - fi->Print(); + PDB(kOutput,2) fi->Print(); // Now add to the dataset dataset->Add(fi); } @@ -404,7 +405,7 @@ Long64_t TProofOutputFile::Merge(TCollection* list) // Add special local URL to keep track of the file path.Form("%s/%s?node=%s", pFile->GetDir(kTRUE), pFile->GetFileName(), pFile->GetLocalHost()); fi->AddUrl(path); - fi->Print(); + PDB(kOutput,2) fi->Print(); // Now add to the dataset dataset->Add(fi); } diff --git a/proof/proof/src/TProofServ.cxx b/proof/proof/src/TProofServ.cxx index 67851394b7a2f..6e1b59e5dd03b 100644 --- a/proof/proof/src/TProofServ.cxx +++ b/proof/proof/src/TProofServ.cxx @@ -385,6 +385,17 @@ TProofServLogHandlerGuard::~TProofServLogHandlerGuard() } //--- Special timer to control delayed shutdowns ----------------------------// +//______________________________________________________________________________ +TShutdownTimer::TShutdownTimer(TProofServ *p, Int_t delay) + : TTimer(delay, kFALSE), fProofServ(p) +{ + // Construtor + + fTimeout = gEnv->GetValue("ProofServ.ShutdownTimeout", 20); + // Backward compaitibility: until 5.32 the variable was called ProofServ.ShutdonwTimeout + fTimeout = gEnv->GetValue("ProofServ.ShutdonwTimeout", fTimeout); +} + //______________________________________________________________________________ Bool_t TShutdownTimer::Notify() { @@ -392,7 +403,7 @@ Bool_t TShutdownTimer::Notify() // process will be aborted. if (gDebug > 0) - Info ("Notify","checking activity on the input socket"); + printf("TShutdownTimer::Notify: checking activity on the input socket\n"); // Check activity on the socket TSocket *xs = 0; @@ -401,22 +412,20 @@ Bool_t TShutdownTimer::Notify() TTimeStamp ts = xs->GetLastUsage(); Long_t dt = (Long_t)(now.GetSec() - ts.GetSec()) * 1000 + (Long_t)(now.GetNanoSec() - ts.GetNanoSec()) / 1000000 ; - Int_t to = gEnv->GetValue("ProofServ.ShutdownTimeout", 20); - // Backward compaitibility: until 5.32 the variable was called ProofServ.ShutdonwTimeout - to = gEnv->GetValue("ProofServ.ShutdonwTimeout", to); - if (dt > to * 60000) { - Printf("TShutdownTimer::Notify: input socket: %p: did not show any activity" - " during the last %d mins: aborting", xs, to); + if (dt > fTimeout * 60000) { + printf("TShutdownTimer::Notify: input socket: %p: did not show any activity" + " during the last %d mins: aborting\n", xs, fTimeout); // At this point we lost our controller: we need to abort to avoid // hidden timeouts or loops gSystem->Abort(); } else { if (gDebug > 0) - Info("Notify", "input socket: %p: show activity" - " %ld secs ago", xs, dt / 60000); + printf("TShutdownTimer::Notify: input socket: %p: show activity" + " %ld secs ago\n", xs, dt / 60000); } } - Start(-1, kFALSE); + // Needed for the next shot + Reset(); return kTRUE; } @@ -664,6 +673,7 @@ TProofServ::TProofServ(Int_t *argc, char **argv, FILE *flog) fInflateFactor = 1000; fDataSetManager = 0; // Initialized in Setup() + fDataSetStgRepo = 0; // Initialized in Setup() fInputHandler = 0; @@ -762,7 +772,7 @@ TProofServ::TProofServ(Int_t *argc, char **argv, FILE *flog) if (enableSchemaEvolution) { TMessage::EnableSchemaEvolutionForAll(); } else { - Info("TProofServ", "automatic schema evolution in TMessage explicitely disabled"); + Info("TProofServ", "automatic schema evolution in TMessage explicitly disabled"); } } @@ -823,7 +833,7 @@ Int_t TProofServ::CreateServer() if (!fLogFile) { RedirectOutput(); - // If for some reason we failed setting a redirection fole for the logs + // If for some reason we failed setting a redirection file for the logs // we cannot continue if (!fLogFile || (fLogFileDes = fileno(fLogFile)) < 0) { LogToMaster(); @@ -991,6 +1001,8 @@ TProofServ::~TProofServ() SafeDelete(fCacheLock); SafeDelete(fQueryLock); SafeDelete(fGlobalPackageDirList); + SafeDelete(fDataSetManager); + SafeDelete(fDataSetStgRepo); close(fLogFileDes); } @@ -1186,6 +1198,9 @@ TDSetElement *TProofServ::GetNextPacket(Long64_t totalEntries) // used to flag files as missing req << totalEntries; + // Send the time spent in saving the partial result to file + if (fProtocol > 34) req << fSaveOutput.RealTime(); + PDB(kLoop, 1) { PDB(kLoop, 2) status->Print(); Info("GetNextPacket","cacheSize: %lld, learnent: %d", cacheSize, learnent); @@ -1208,6 +1223,14 @@ TDSetElement *TProofServ::GetNextPacket(Long64_t totalEntries) return 0; } + // Save the current output + if (fPlayer) { + fSaveOutput.Start(); + if (fPlayer->SavePartialResults(kFALSE) < 0) + Warning("GetNextPacket", "problems saving partial results"); + fSaveOutput.Stop(); + } + TDSetElement *e = 0; Bool_t notdone = kTRUE; while (notdone) { @@ -1321,7 +1344,7 @@ void TProofServ::HandleSocketInput() Int_t rc = 0; TString exmsg; - // Check log file lenght (before the action, so we have the chance to keep the + // Check log file length (before the action, so we have the chance to keep the // latest logs) TruncateLogFile(); @@ -1453,7 +1476,7 @@ Int_t TProofServ::HandleSocketInput(TMessage *mess, Bool_t all) { // Process input coming from the client or from the master server. // If 'all' is kFALSE, process only those messages that can be handled - // during qurey processing. + // during query processing. // Returns -1 if the message could not be processed, <-1 if something went // wrong. Returns 1 if the action may have changed the parallel state. // Returns 2 if the message has to be enqueued. @@ -1485,7 +1508,7 @@ Int_t TProofServ::HandleSocketInput(TMessage *mess, Bool_t all) TString fn; if (TProof::GetFileInCmd(str, fn)) CopyFromCache(fn, 1); - if (IsParallel()) { + if (IsParallel() && fProof && !fProof->UseDynamicStartup()) { fProof->SendCommand(str); } else { PDB(kGlobal, 1) @@ -1628,6 +1651,23 @@ Int_t TProofServ::HandleSocketInput(TMessage *mess, Bool_t all) } break; + case kPROOF_SENDOUTPUT: + { + PDB(kGlobal, 1) Info("HandleSocketInput:kPROOF_SENDOUTPUT", + "worker was asked to send output to master"); + Int_t sorc = 0; + if (SendResults(fSocket, fPlayer->GetOutputList()) != 0) { + Error("HandleSocketInput:kPROOF_SENDOUTPUT", "problems sending output list"); + sorc = 1; + } + // Signal the master that we are idle + fSocket->Send(kPROOF_SETIDLE); + SetIdle(kTRUE); + DeletePlayer(); + SendLogFile(sorc); + } + break; + case kPROOF_QUERYLIST: { HandleQueryList(mess); @@ -1818,17 +1858,17 @@ Int_t TProofServ::HandleSocketInput(TMessage *mess, Bool_t all) } else { TProofServLogHandlerGuard hg(fLogFile, fSocket, "", fRealTimeLog); PDB(kGlobal, 1) Info("HandleSocketInput:kPROOF_CACHE","enter"); - Int_t status = HandleCache(mess, pslb); + Int_t hcrc = HandleCache(mess, pslb); // Notify - SendLogFile(status); + SendLogFile(hcrc); } break; case kPROOF_WORKERLISTS: - { Int_t xrc = -1; + { Int_t wlrc = -1; if (all) { if (IsMaster()) - xrc = HandleWorkerLists(mess); + wlrc = HandleWorkerLists(mess); else Warning("HandleSocketInput:kPROOF_WORKERLISTS", "Action meaning-less on worker nodes: protocol error?"); @@ -1836,7 +1876,7 @@ Int_t TProofServ::HandleSocketInput(TMessage *mess, Bool_t all) rc = -1; } // Notify - SendLogFile(xrc); + SendLogFile(wlrc); } break; @@ -1844,10 +1884,34 @@ Int_t TProofServ::HandleSocketInput(TMessage *mess, Bool_t all) if (all) { PDB(kGlobal, 1) Info("HandleSocketInput:kPROOF_GETSLAVEINFO", "Enter"); if (IsMaster()) { - TList *info = fProof->GetListOfSlaveInfos(); - TMessage answ(kPROOF_GETSLAVEINFO); - answ << info; - fSocket->Send(answ); + + Bool_t ok = kTRUE; + // if the session does not have workers and is in the dynamic mode + if (fProof->UseDynamicStartup()) { + ok = kFALSE; + // get the a list of workers and start them + Int_t pc = 0; + TList* workerList = new TList(); + EQueryAction retVal = GetWorkers(workerList, pc); + if (retVal != TProofServ::kQueryStop && retVal != TProofServ::kQueryEnqueued) { + if (Int_t ret = fProof->AddWorkers(workerList) < 0) { + Error("HandleSocketInput:kPROOF_GETSLAVEINFO", + "adding a list of worker nodes returned: %d", ret); + } + } else { + Error("HandleSocketInput:kPROOF_GETSLAVEINFO", + "getting list of worker nodes returned: %d", retVal); + } + ok = kTRUE; + } + if (ok) { + TList *info = fProof->GetListOfSlaveInfos(); + TMessage answ(kPROOF_GETSLAVEINFO); + answ << info; + fSocket->Send(answ); + // stop the workers + if (IsMaster() && fProof->UseDynamicStartup()) fProof->RemoveWorkers(0); + } } else { TMessage answ(kPROOF_GETSLAVEINFO); TList *info = new TList; @@ -1969,13 +2033,13 @@ Int_t TProofServ::HandleSocketInput(TMessage *mess, Bool_t all) break; case kPROOF_DATASETS: - { Int_t xrc = -1; + { Int_t dsrc = -1; if (fProtocol > 16) { - xrc = HandleDataSets(mess, pslb); + dsrc = HandleDataSets(mess, pslb); } else { Error("HandleSocketInput", "old client: no or incompatible dataset support"); } - SendLogFile(xrc); + SendLogFile(dsrc); } break; @@ -2078,6 +2142,75 @@ Int_t TProofServ::HandleSocketInput(TMessage *mess, Bool_t all) } break; + case kPROOF_ECHO: + { // Echo request: an object has been sent along. If the object is a + // string, it is simply echoed back to the client from the master + // and each worker. Elsewhere, the output of TObject::Print() is + // sent. Received object is disposed after usage. + + TObject *obj = mess->ReadObject(0x0); // class type ignored + + if (IsMaster()) { + // We are on master + // dbTODO: forward on dynamic startup when wrks are up + if (IsParallel() && fProof && !fProof->UseDynamicStartup()) { + fProof->Echo(obj); // forward to lower layer + } + } + + TMessage rmsg(kPROOF_MESSAGE); + TString smsg; + + if (obj->InheritsFrom(TObjString::Class())) { + // It's a string: echo it + smsg.Form("Echo response from %s:%s: %s", + gSystem->HostName(), GetOrdinal(), + ((TObjString *)obj)->String().Data()); + } + else { + // Not a string: collect Print() output and send it + + // Output to tempfile + TString tmpfn = "echo-out-"; + FILE *tf = gSystem->TempFileName(tmpfn, fDataDir); + if (!tf || (gSystem->RedirectOutput(tmpfn.Data()) == -1)) { + Error("HandleSocketInput", "Can't redirect output"); + if (tf) { + fclose(tf); + gSystem->Unlink(tmpfn); + } + rc = -1; + delete obj; + break; + } + //cout << obj->ClassName() << endl; + obj->Print(); + gSystem->RedirectOutput(0x0); // restore + fclose(tf); + + // Read file back and send it via message + smsg.Form("*** Echo response from %s:%s ***\n", + gSystem->HostName(), GetOrdinal()); + TMacro *fr = new TMacro(); + fr->ReadFile(tmpfn); + TIter nextLine(fr->GetListOfLines()); + TObjString *line; + while (( line = (TObjString *)nextLine() )) { + smsg.Append( line->String() ); + } + + // Close the reader (TMacro) and remove file + delete fr; + gSystem->Unlink(tmpfn); + } + + // Send message and dispose object + rmsg << smsg; + GetSocket()->Send(rmsg); + delete obj; + } + break; + default: Error("HandleSocketInput", "unknown command %d", what); rc = -2; @@ -2359,7 +2492,7 @@ Bool_t TProofServ::IsParallel() const // True if in parallel mode. if (IsMaster() && fProof) - return fProof->IsParallel(); + return fProof->IsParallel() || fProof->UseDynamicStartup() ; // false in case we are a slave return kFALSE; @@ -2533,7 +2666,7 @@ void TProofServ::SendLogFile(Int_t status, Int_t start, Int_t end) fflush(stdout); // On workers we do not send the logs to masters (to avoid duplication of - // text) unless asked explicitely, e.g. after an Exec(...) request. + // text) unless asked explicitly, e.g. after an Exec(...) request. if (!IsMaster()) { if (!fSendLogToMaster) { FlushLogFile(); @@ -2646,7 +2779,11 @@ void TProofServ::SendParallel(Bool_t async) Int_t nparallel = 0; if (IsMaster()) { + PDB(kGlobal, 2) + Info("SendParallel", "Will invoke AskParallel()"); fProof->AskParallel(); + PDB(kGlobal, 2) + Info("SendParallel", "Will invoke GetParallel()"); nparallel = fProof->GetParallel(); } else { nparallel = 1; @@ -2666,7 +2803,7 @@ Int_t TProofServ::UnloadPackage(const char *package) // does not currently remove entry from interpreter include path. // Returns -1 in case of error, 0 otherwise. - TObjString *pack = (TObjString *) fEnabledPackages->FindObject(package); + TPair *pack = (TPair *) fEnabledPackages->FindObject(package); if (pack) { // Remove entry from include path @@ -2703,8 +2840,8 @@ Int_t TProofServ::UnloadPackages() // Iterate over packages and remove each package TIter nextpackage(fEnabledPackages); - while (TObjString* objstr = dynamic_cast<TObjString*>(nextpackage())) - if (UnloadPackage(objstr->String()) != 0) + while (TPair *pck = dynamic_cast<TPair *>(nextpackage())) + if (UnloadPackage(pck->GetName()) != 0) return -1; PDB(kPackage, 1) @@ -2980,9 +3117,13 @@ Int_t TProofServ::SetupCommon() // Check and make sure "data" directory exists fDataDir = gEnv->GetValue("ProofServ.DataDir",""); + Ssiz_t isep = kNPOS; if (fDataDir.IsNull()) { // Use default fDataDir.Form("%s/%s/<ord>/<stag>", fWorkDir.Data(), kPROOF_DataDir); + } else if ((isep = fDataDir.Last(' ')) != kNPOS) { + fDataDirOpts = fDataDir(isep + 1, fDataDir.Length()); + fDataDir.Remove(isep); } ResolveKeywords(fDataDir); if (gSystem->AccessPathName(fDataDir)) @@ -3052,6 +3193,7 @@ Int_t TProofServ::SetupCommon() fGlobalPackageDirList = new THashList(); fGlobalPackageDirList->SetOwner(); } + ResolveKeywords(ldir); fGlobalPackageDirList->Add(new TNamed(key,ldir)); Info("SetupCommon", "directory for global packages %s added to the list", ldir.Data()); @@ -3094,7 +3236,7 @@ Int_t TProofServ::SetupCommon() // Create 'queries' locker instance and lock it fQueryLock = new TProofLockPath(TString::Format("%s/%s%s-%s", gSystem->TempDirectory(), - kPROOF_QueryLockFile, fTopSessionTag.Data(), + kPROOF_QueryLockFile, fSessionTag.Data(), TString(fQueryDir).ReplaceAll("/","%").Data())); fQueryLock->Lock(); // Create the query manager @@ -3109,8 +3251,7 @@ Int_t TProofServ::SetupCommon() if (IsMaster()) { // Send session tag to client TMessage m(kPROOF_SESSIONTAG); - m << fTopSessionTag; - if (GetProtocol() > 24) m << fGroup; + m << fTopSessionTag << fGroup << fUser; fSocket->Send(m); // Group priority fGroupPriority = GetPriority(); @@ -3171,6 +3312,29 @@ Int_t TProofServ::SetupCommon() SafeDelete(fDataSetManager); } } + // Dataset manager for staging requests + TString dsReqCfg = gEnv->GetValue("Proof.DataSetStagingRequests", ""); + if (!dsReqCfg.IsNull()) { + TPMERegexp reReqDir("(^| )(dir:)?([^ ]+)( |$)"); + + if (reReqDir.Match(dsReqCfg) == 5) { + TString dsDirFmt; + dsDirFmt.Form("dir:%s perms:open", reReqDir[3].Data()); + fDataSetStgRepo = new TDataSetManagerFile("_stage_", "_stage_", + dsDirFmt); + if (fDataSetStgRepo && + fDataSetStgRepo->TestBit(TObject::kInvalidObject)) { + Warning("SetupCommon", + "failed init of dataset staging requests repository"); + SafeDelete(fDataSetStgRepo); + } + } else { + Warning("SetupCommon", + "specify, with [dir:]<path>, a valid path for staging requests"); + } + } else if (gProofDebugLevel > 0) { + Warning("SetupCommon", "no repository for staging requests available"); + } } // Quotas @@ -3489,12 +3653,12 @@ void TProofServ::SetQueryRunning(TProofQueryResult *pq) // Build the list of loaded PAR packages TString parlist = ""; TIter nxp(fEnabledPackages); - TObjString *os= 0; - while ((os = (TObjString *)nxp())) { + TPair *pck= 0; + while ((pck = (TPair *)nxp())) { if (parlist.Length() <= 0) - parlist = os->GetName(); + parlist = pck->GetName(); else - parlist += TString::Format(";%s",os->GetName()); + parlist += TString::Format(";%s", pck->GetName()); } if (fProof) { @@ -3624,32 +3788,21 @@ void TProofServ::HandleArchive(TMessage *mess, TString *slb) } //______________________________________________________________________________ -TMap *TProofServ::GetDataSetNodeMap(const char *dsn, TString &emsg) +TMap *TProofServ::GetDataSetNodeMap(TFileCollection *fc, TString &emsg) { - // Get a map {server-name, list-of-files} for the daset dsn to be used in + // Get a map {server-name, list-of-files} for collection 'fc' to be used in // TPacketizerFile. Returns a pointer to the map (ownership of the caller). // Or (TMap *)0 and an error message in emsg. TMap *fcmap = 0; emsg = ""; - // Make sure we have something in input and a dataset manager - if (!fDataSetManager) { - emsg.Form("dataset manager not initialized!"); - return fcmap; - } - if (!dsn || (dsn && strlen(dsn) <= 0)) { - emsg.Form("dataset name undefined!"); + // Sanity checks + if (!fc) { + emsg.Form("file collection undefined!"); return fcmap; } - TFileCollection *fc = 0; - // Get the dataset - if (!(fc = fDataSetManager->GetDataSet(dsn))) { - emsg.Form("requested dataset '%s' does not exists", dsn); - return fcmap; - } - // Prepare data set map fcmap = new TMap(); @@ -3738,8 +3891,26 @@ void TProofServ::HandleProcess(TMessage *mess, TString *slb) if (!dsn.Contains(":") || dsn.BeginsWith("dataset:")) { dsn.ReplaceAll("dataset:", ""); // Get the map for TPacketizerFile - TMap *fcmap = GetDataSetNodeMap(dsn, emsg); - if (!fcmap) { + // Make sure we have something in input and a dataset manager + if (!fDataSetManager) { + emsg.Form("dataset manager not initialized!"); + } else { + TFileCollection *fc = 0; + // Get the dataset + if (!(fc = fDataSetManager->GetDataSet(dsn))) { + emsg.Form("requested dataset '%s' does not exists", dsn.Data()); + } else { + TMap *fcmap = GetDataSetNodeMap(fc, emsg); + if (fcmap) { + input->Remove(ftp); + delete ftp; + fcmap->SetOwner(kTRUE); + fcmap->SetName("PROOF_FilesToProcess"); + input->Add(fcmap); + } + } + } + if (!emsg.IsNull()) { SendAsynMessage(TString::Format("HandleProcess on %s: %s", fPrefix.Data(), emsg.Data())); Error("HandleProcess", "%s", emsg.Data()); @@ -3747,11 +3918,6 @@ void TProofServ::HandleProcess(TMessage *mess, TString *slb) if (sync) SendLogFile(); return; } - input->Remove(ftp); - delete ftp; - fcmap->SetOwner(kTRUE); - fcmap->SetName("PROOF_FilesToProcess"); - input->Add(fcmap); } } } @@ -3950,6 +4116,7 @@ void TProofServ::HandleProcess(TMessage *mess, TString *slb) // Reset latency stopwatch fLatency.Reset(); + fSaveOutput.Reset(); // Process PDB(kGlobal, 1) Info("HandleProcess", "calling %s::Process()", fPlayer->IsA()->GetName()); @@ -3993,62 +4160,104 @@ void TProofServ::HandleProcess(TMessage *mess, TString *slb) SafeDelete(enl); SafeDelete(evl); - // Check if we are in merging mode (i.e. parameter PROOF_UseMergers exists) - Bool_t isInMergingMode = kFALSE; - if (!(TestBit(TProofServ::kHighMemory))) { - Int_t nm = 0; - if (TProof::GetParameter(input, "PROOF_UseMergers", nm) == 0) { - isInMergingMode = (nm >= 0) ? kTRUE : kFALSE; - } - } - PDB(kGlobal, 2) Info("HandleProcess", "merging mode check: %d", isInMergingMode); + Bool_t outok = (fPlayer->GetExitStatus() != TVirtualProofPlayer::kAborted && + fPlayer->GetOutputList()) ? kTRUE : kFALSE; + if (outok) { + // Check if in controlled output sending mode + Int_t cso = gEnv->GetValue("Proof.ControlSendOutput", 1); + if (TProof::GetParameter(input, "PROOF_ControlSendOutput", cso) != 0) + cso = gEnv->GetValue("Proof.ControlSendOutput", 1); + if (cso > 0) { + + // Control output sending mode: wait for the master to ask for the objects. + // Allows controls of memory usage on the master. + TMessage msg(kPROOF_SENDOUTPUT); + fSocket->Send(msg); - if (!IsMaster() && isInMergingMode && - fPlayer->GetExitStatus() != TVirtualProofPlayer::kAborted && fPlayer->GetOutputList()) { - // Worker in merging mode. - //---------------------------- - // First, it reports only the size of its output to the master - // + port on which it can possibly accept outputs from other workers if it becomes a merger - // Master will later tell it where it should send the output (either to the master or to some merger) - // or if it should become a merger + // Set idle + SetIdle(kTRUE); - TMessage msg_osize(kPROOF_SUBMERGER); - msg_osize << Int_t(TProof::kOutputSize); - msg_osize << fPlayer->GetOutputList()->GetEntries(); + // Do not cleanup the player yet: it will be used in sending output activities + deleteplayer = kFALSE; - fMergingSocket = new TServerSocket(0); - Int_t merge_port = 0; - if (fMergingSocket) { - PDB(kGlobal, 2) - Info("HandleProcess", "possible port for merging connections: %d", - fMergingSocket->GetLocalPort()); - merge_port = fMergingSocket->GetLocalPort(); - } - msg_osize << merge_port; - fSocket->Send(msg_osize); + PDB(kGlobal, 1) + Info("HandleProcess", "controlled mode: worker %s has finished," + " sizes sent to master", fOrdinal.Data()); + } else { - // Set idle - SetIdle(kTRUE); - // Do not cleanup the player yet: it will be used in sub-merging activities - deleteplayer = kFALSE; + // Check if we are in merging mode (i.e. parameter PROOF_UseMergers exists) + Bool_t isInMergingMode = kFALSE; + if (!(TestBit(TProofServ::kHighMemory))) { + Int_t nm = 0; + if (TProof::GetParameter(input, "PROOF_UseMergers", nm) == 0) { + isInMergingMode = (nm >= 0) ? kTRUE : kFALSE; + } + } + PDB(kGlobal, 2) Info("HandleProcess", "merging mode check: %d", isInMergingMode); + + if (!IsMaster() && isInMergingMode) { + // Worker in merging mode. + //---------------------------- + // First, it reports only the size of its output to the master + // + port on which it can possibly accept outputs from other workers if it becomes a merger + // Master will later tell it where it should send the output (either to the master or to some merger) + // or if it should become a merger + + TMessage msg_osize(kPROOF_SUBMERGER); + msg_osize << Int_t(TProof::kOutputSize); + msg_osize << fPlayer->GetOutputList()->GetEntries(); + + fMergingSocket = new TServerSocket(0); + Int_t merge_port = 0; + if (fMergingSocket) { + PDB(kGlobal, 2) + Info("HandleProcess", "possible port for merging connections: %d", + fMergingSocket->GetLocalPort()); + merge_port = fMergingSocket->GetLocalPort(); + } + msg_osize << merge_port; + fSocket->Send(msg_osize); + + // Set idle + SetIdle(kTRUE); + + // Do not cleanup the player yet: it will be used in sub-merging activities + deleteplayer = kFALSE; + + PDB(kSubmerger, 2) Info("HandleProcess", "worker %s has finished", fOrdinal.Data()); + + } else { + // Sub-master OR worker not in merging mode + // --------------------------------------------- + PDB(kGlobal, 2) Info("HandleProcess", "sending result directly to master"); + if (SendResults(fSocket, fPlayer->GetOutputList()) != 0) + Warning("HandleProcess","problems sending output list"); + + // Masters reset the mergers, if any + if (IsMaster()) fProof->ResetMergers(); + + // Signal the master that we are idle + fSocket->Send(kPROOF_SETIDLE); + + // Set idle + SetIdle(kTRUE); + + // Notify the user + SendLogFile(); + } + - PDB(kSubmerger, 2) Info("HandleProcess", "worker %s has finished", fOrdinal.Data()); - } else { - // Sub-master OR worker not in merging mode - // --------------------------------------------- - if (fPlayer->GetExitStatus() != TVirtualProofPlayer::kAborted && fPlayer->GetOutputList()) { - PDB(kGlobal, 2) Info("HandleProcess", "sending result directly to master"); - if (SendResults(fSocket, fPlayer->GetOutputList()) != 0) - Warning("HandleProcess","problems sending output list"); - } else { - if (fPlayer->GetExitStatus() != TVirtualProofPlayer::kAborted) - Warning("HandleProcess","the output list is empty!"); - if (SendResults(fSocket) != 0) - Warning("HandleProcess", "problems sending output list"); } + } else { + // No output list + if (fPlayer->GetExitStatus() != TVirtualProofPlayer::kAborted) + Warning("HandleProcess","the output list is empty!"); + if (SendResults(fSocket) != 0) + Warning("HandleProcess", "problems sending output list"); + // Masters reset the mergers, if any if (IsMaster()) fProof->ResetMergers(); @@ -4461,8 +4670,9 @@ void TProofServ::ProcessNext(TString *slb) if (fDataSetManager && fPlayer->GetOutputList()) { TNamed *psr = (TNamed *) fPlayer->GetOutputList()->FindObject("PROOFSERV_RegisterDataSet"); if (psr) { - if (RegisterDataSets(input, fPlayer->GetOutputList()) != 0) - Warning("ProcessNext", "problems registering produced datasets"); + TString emsg; + if (RegisterDataSets(input, fPlayer->GetOutputList(), fDataSetManager, emsg) != 0) + Warning("ProcessNext", "problems registering produced datasets: %s", emsg.Data()); do { fPlayer->GetOutputList()->Remove(psr); delete psr; @@ -4477,6 +4687,31 @@ void TProofServ::ProcessNext(TString *slb) fQMgr->SaveQuery(pq, fMaxQueries); } + // If we were requested to save results on the master and we are not in save-to-file mode + // then we save the results + if (IsTopMaster() && fPlayer->GetOutputList()) { + Bool_t save = kTRUE; + TIter nxo(fPlayer->GetOutputList()); + TObject *xo = 0; + while ((xo = nxo())) { + if (xo->InheritsFrom("TProofOutputFile") && xo->TestBit(TProofOutputFile::kSwapFile)) { + save = kFALSE; + break; + } + } + if (save) { + TNamed *nof = (TNamed *) input->FindObject("PROOF_DefaultOutputOption"); + if (nof) { + TString oopt(nof->GetTitle()); + if (oopt.BeginsWith("of:")) { + oopt.Replace(0, 3, ""); + if (!oopt.IsNull()) fPlayer->SetOutputFilePath(oopt); + fPlayer->SavePartialResults(kTRUE, kTRUE); + } + } + } + } + // Send back the results TQueryResult *pqr = pq->CloneInfo(); // At least the TDSet name in the light object @@ -4528,18 +4763,22 @@ void TProofServ::ProcessNext(TString *slb) } //______________________________________________________________________________ -Int_t TProofServ::RegisterDataSets(TList *in, TList *out) +Int_t TProofServ::RegisterDataSets(TList *in, TList *out, + TDataSetManager *dsm, TString &msg) { // Register TFileCollections in 'out' as datasets according to the rules in 'in' PDB(kDataset, 1) - Info("RegisterDataSets", "enter: %d objs in the output list", (out ? out->GetSize() : -1)); - - if (!in || !out) return 0; + ::Info("TProofServ::RegisterDataSets", + "enter: %d objs in the output list", (out ? out->GetSize() : -1)); + if (!in || !out || !dsm) { + ::Error("TProofServ::RegisterDataSets", "invalid inputs: %p, %p, %p", in, out, dsm); + return 0; + } + msg = ""; THashList tags; TList torm; - TString msg; TIter nxo(out); TObject *o = 0; while ((o = nxo())) { @@ -4565,51 +4804,41 @@ Int_t TProofServ::RegisterDataSets(TList *in, TList *out) regopt.ReplaceAll(":sortidx:", ""); } // Register this dataset - if (fDataSetManager) { - if (fDataSetManager->TestBit(TDataSetManager::kAllowRegister)) { - // Extract the list - if (ds->GetList()->GetSize() > 0) { - // Register the dataset (quota checks are done inside here) - msg.Form("Registering and verifying dataset '%s' ... ", ds->GetName()); - SendAsynMessage(msg.Data(), kFALSE); - Int_t rc = 0; - FlushLogFile(); - { TProofServLogHandlerGuard hg(fLogFile, fSocket); - // Always allow verification for this action - Bool_t allowVerify = fDataSetManager->TestBit(TDataSetManager::kAllowVerify) ? kTRUE : kFALSE; - if (regopt.Contains("V") && !allowVerify) - fDataSetManager->SetBit(TDataSetManager::kAllowVerify); - rc = fDataSetManager->RegisterDataSet(ds->GetName(), ds, regopt); - // Reset to the previous state if needed - if (regopt.Contains("V") && !allowVerify) - fDataSetManager->ResetBit(TDataSetManager::kAllowVerify); - } - if (rc != 0) { - Warning("RegisterDataSets", - "failure registering dataset '%s'", ds->GetName()); - msg.Form("Registering and verifying dataset '%s' ... failed! See log for more details", ds->GetName()); - } else { - Info("RegisterDataSets", "dataset '%s' successfully registered", ds->GetName()); - msg.Form("Registering and verifying dataset '%s' ... OK", ds->GetName()); - // Add tag to the list of processed tags to avoid double processing - // (there may be more objects with the same name, created by each worker) - tags.Add(new TObjString(tag)); - } - SendAsynMessage(msg.Data(), kTRUE); - // Notify - PDB(kDataset, 2) { - Info("RegisterDataSets","printing collection"); - ds->Print("F"); - } + if (dsm->TestBit(TDataSetManager::kAllowRegister)) { + // Extract the list + if (ds->GetList()->GetSize() > 0) { + // Register the dataset (quota checks are done inside here) + const char *vfmsg = regopt.Contains("V") ? " and verifying" : ""; + msg.Form("Registering%s dataset '%s' ... ", vfmsg, ds->GetName()); + // Always allow verification for this action + Bool_t allowVerify = dsm->TestBit(TDataSetManager::kAllowVerify) ? kTRUE : kFALSE; + if (regopt.Contains("V") && !allowVerify) dsm->SetBit(TDataSetManager::kAllowVerify); + // Main action + Int_t rc = dsm->RegisterDataSet(ds->GetName(), ds, regopt); + // Reset to the previous state if needed + if (regopt.Contains("V") && !allowVerify) dsm->ResetBit(TDataSetManager::kAllowVerify); + if (rc != 0) { + ::Warning("TProofServ::RegisterDataSets", + "failure registering or verifying dataset '%s'", ds->GetName()); + msg.Form("Registering%s dataset '%s' ... failed! See log for more details", vfmsg, ds->GetName()); } else { - Warning("RegisterDataSets", "collection '%s' is empty", o->GetName()); + ::Info("TProofServ::RegisterDataSets", "dataset '%s' successfully registered%s", + ds->GetName(), (strlen(vfmsg) > 0) ? " and verified" : ""); + msg.Form("Registering%s dataset '%s' ... OK", vfmsg, ds->GetName()); + // Add tag to the list of processed tags to avoid double processing + // (there may be more objects with the same name, created by each worker) + tags.Add(new TObjString(tag)); + } + // Notify + PDB(kDataset, 2) { + ::Info("TProofServ::RegisterDataSets", "printing collection"); + ds->Print("F"); } } else { - Info("RegisterDataSets", "dataset registration not allowed"); - return -1; + ::Warning("TProofServ::RegisterDataSets", "collection '%s' is empty", o->GetName()); } } else { - Error("RegisterDataSets", "dataset manager is undefined!"); + ::Info("TProofServ::RegisterDataSets", "dataset registration not allowed"); return -1; } } @@ -4626,7 +4855,7 @@ Int_t TProofServ::RegisterDataSets(TList *in, TList *out) } tags.SetOwner(kTRUE); - PDB(kDataset, 1) Info("RegisterDataSets", "exit"); + PDB(kDataset, 1) ::Info("TProofServ::RegisterDataSets", "exit"); // Done return 0; } @@ -5165,6 +5394,7 @@ Int_t TProofServ::HandleCache(TMessage *mess, TString *slb) Bool_t all = kFALSE; TMessage msg; Bool_t fromglobal = kFALSE; + Int_t chkveropt = TProof::kCheckROOT; // Default: check ROOT version // Notification message TString noth; @@ -5258,6 +5488,7 @@ Int_t TProofServ::HandleCache(TMessage *mess, TString *slb) break; case TProof::kBuildPackage: (*mess) >> package; + if ((mess->BufferSize() > mess->Length())) (*mess) >> chkveropt; // always follows BuildPackage so no need to check for PROOF-INF pdir = fPackageDir + "/" + package; @@ -5322,6 +5553,7 @@ Int_t TProofServ::HandleCache(TMessage *mess, TString *slb) // read version from file proofvers.txt, and if current version is // not the same do a "BUILD.sh clean" + Bool_t goodver = kTRUE; Bool_t savever = kFALSE; TString v; Int_t rev = -1; @@ -5332,9 +5564,13 @@ Int_t TProofServ::HandleCache(TMessage *mess, TString *slb) r.Gets(f); rev = (!r.IsNull() && r.IsDigit()) ? r.Atoi() : -1; fclose(f); + if (chkveropt == TProof::kCheckROOT || chkveropt == TProof::kCheckSVN) { + if (v != gROOT->GetVersion()) goodver = kFALSE; + if (goodver && chkveropt == TProof::kCheckSVN) + if (gROOT->GetSvnRevision() > 0 && rev != gROOT->GetSvnRevision()) goodver = kFALSE; + } } - if (!f || v != gROOT->GetVersion() || - (gROOT->GetSvnRevision() > 0 && rev != gROOT->GetSvnRevision())) { + if (!f || !goodver) { if (!fromglobal || !gSystem->AccessPathName(pdir, kWritePermission)) { savever = kTRUE; SendAsynMessage(TString::Format("%s: %s: version change (current: %s:%d," @@ -5429,7 +5665,7 @@ Int_t TProofServ::HandleCache(TMessage *mess, TString *slb) PDB(kPackage, 1) Info("HandleCache", "package %s successfully built", package.Data()); } - if (slb) slb->Form("%d %s %d", type, package.Data(), status); + if (slb) slb->Form("%d %s %d %d", type, package.Data(), status, chkveropt); break; case TProof::kLoadPackage: (*mess) >> package; @@ -5597,7 +5833,9 @@ Int_t TProofServ::HandleCache(TMessage *mess, TString *slb) gROOT->ProcessLine(TString(".include ") + package); // if successful add to list and propagate to slaves - fEnabledPackages->Add(new TObjString(package)); + TPair *pck = (optls && optls->GetSize() > 0) ? new TPair(new TObjString(package), optls->Clone()) + : new TPair(new TObjString(package), 0); + fEnabledPackages->Add(pck); if (IsMaster()) { if (optls && optls->GetSize() > 0) { // List argument @@ -5627,8 +5865,8 @@ Int_t TProofServ::HandleCache(TMessage *mess, TString *slb) } { TIter next(fEnabledPackages); - while (TObjString *str = (TObjString*) next()) - printf("%s\n", str->GetName()); + while (TPair *pck = (TPair *) next()) + printf("%s\n", pck->GetName()); } if (IsMaster() && all) fProof->ShowEnabledPackages(all); @@ -5669,9 +5907,10 @@ Int_t TProofServ::HandleCache(TMessage *mess, TString *slb) break; case TProof::kBuildSubPackage: (*mess) >> package; + if ((mess->BufferSize() > mess->Length())) (*mess) >> chkveropt; if (IsMaster()) - fProof->BuildPackage(package); - if (slb) slb->Form("%d %s", type, package.Data()); + fProof->BuildPackage(package, TProof::kBuildAll, chkveropt); + if (slb) slb->Form("%d %s %d", type, package.Data(), chkveropt); break; case TProof::kUnloadPackage: (*mess) >> package; @@ -5709,8 +5948,17 @@ Int_t TProofServ::HandleCache(TMessage *mess, TString *slb) break; case TProof::kListEnabledPackages: msg.Reset(kPROOF_PACKAGE_LIST); - msg << type << fEnabledPackages; - fSocket->Send(msg); + { TList *epl = new TList; + if (fEnabledPackages->GetSize() > 0) { + TIter nxp(fEnabledPackages); + TObject *o = 0; + while ((o = nxp())) { epl->Add(new TObjString(o->GetName()));} + } + msg << type << epl; + fSocket->Send(msg); + epl->SetOwner(); + delete epl; + } if (slb) slb->Form("%d", type); break; case TProof::kListPackages: @@ -5803,6 +6051,7 @@ Int_t TProofServ::HandleWorkerLists(TMessage *mess) switch (type) { case TProof::kActivateWorker: (*mess) >> ord; + if (ord != "*" && !ord.BeginsWith(GetOrdinal()) && ord != "restore") break; if (fProof) { Int_t nact = fProof->GetListOfActiveSlaves()->GetSize(); Int_t nactmax = fProof->GetListOfSlaves()->GetSize() - @@ -5812,13 +6061,15 @@ Int_t TProofServ::HandleWorkerLists(TMessage *mess) Int_t nactnew = fProof->GetListOfActiveSlaves()->GetSize(); if (ord == "*") { if (nactnew == nactmax) { - Info("HandleWorkerList", "all workers (re-)activated"); + PDB(kGlobal, 1) Info("HandleWorkerList", "all workers (re-)activated"); } else { - Info("HandleWorkerList", "%d workers could not be (re-)activated", nactmax - nactnew); + if (IsEndMaster()) + PDB(kGlobal, 1) Info("HandleWorkerList", "%d workers could not be (re-)activated", nactmax - nactnew); } } else { if (nactnew == (nact + nwc)) { - Info("HandleWorkerList","worker(s) %s (re-)activated", ord.Data()); + if (nwc > 0) + PDB(kGlobal, 1) Info("HandleWorkerList","worker(s) %s (re-)activated", ord.Data()); } else { if (nwc != -2) { Error("HandleWorkerList", "some worker(s) could not be (re-)activated;" @@ -5829,7 +6080,7 @@ Int_t TProofServ::HandleWorkerLists(TMessage *mess) } } } else { - Info("HandleWorkerList","all workers are already active"); + PDB(kGlobal, 1) Info("HandleWorkerList","all workers are already active"); } } else { Warning("HandleWorkerList","undefined PROOF session: protocol error?"); @@ -5837,6 +6088,7 @@ Int_t TProofServ::HandleWorkerLists(TMessage *mess) break; case TProof::kDeactivateWorker: (*mess) >> ord; + if (ord != "*" && !ord.BeginsWith(GetOrdinal()) && ord != "restore") break; if (fProof) { Int_t nact = fProof->GetListOfActiveSlaves()->GetSize(); if (nact > 0) { @@ -5844,13 +6096,15 @@ Int_t TProofServ::HandleWorkerLists(TMessage *mess) Int_t nactnew = fProof->GetListOfActiveSlaves()->GetSize(); if (ord == "*") { if (nactnew == 0) { - Info("HandleWorkerList","all workers deactivated"); + PDB(kGlobal, 1) Info("HandleWorkerList","all workers deactivated"); } else { - Info("HandleWorkerList","%d workers could not be deactivated", nactnew); + if (IsEndMaster()) + PDB(kGlobal, 1) Info("HandleWorkerList","%d workers could not be deactivated", nactnew); } } else { if (nactnew == (nact - nwc)) { - Info("HandleWorkerList","worker(s) %s deactivated", ord.Data()); + if (nwc > 0) + PDB(kGlobal, 1) Info("HandleWorkerList","worker(s) %s deactivated", ord.Data()); } else { if (nwc != -2) { Error("HandleWorkerList", "some worker(s) could not be deactivated:" @@ -5861,7 +6115,7 @@ Int_t TProofServ::HandleWorkerLists(TMessage *mess) } } } else { - Info("HandleWorkerList","all workers are already inactive"); + PDB(kGlobal, 1) Info("HandleWorkerList","all workers are already inactive"); } } else { Warning("HandleWorkerList","undefined PROOF session: protocol error?"); @@ -6554,6 +6808,9 @@ Int_t TProofServ::HandleDataSets(TMessage *mess, TString *slb) TString dsUser, dsGroup, dsName, dsTree, uri, opt; Int_t rc = 0; + // Invalid characters in dataset URI + TPMERegexp reInvalid("[^A-Za-z0-9._-]"); // from ParseUri + // Message type Int_t type = 0; (*mess) >> type; @@ -6596,6 +6853,116 @@ Int_t TProofServ::HandleDataSets(TMessage *mess, TString *slb) } break; + case TProof::kRequestStaging: + { + (*mess) >> uri; // TString + + if (!fDataSetStgRepo) { + Error("HandleDataSets", + "no dataset staging request repository available"); + return -1; + } + + // Transform input URI in a valid dataset name + TString validUri = uri; + while (reInvalid.Substitute(validUri, "_")) {} + + // Check if dataset exists beforehand: if it does, staging has + // already been requested + if (fDataSetStgRepo->ExistsDataSet(validUri.Data())) { + Warning("HandleDataSet", "staging of %s already requested", + uri.Data()); + return -1; + } + + // Try to get dataset from current manager + TFileCollection *fc = fDataSetManager->GetDataSet(uri.Data()); + if (!fc || (fc->GetNFiles() == 0)) { + Error("HandleDataSets", "empty dataset or no dataset returned"); + if (fc) delete fc; + return -1; + } + + // Reset all staged bits and remove unnecessary URLs (all but last) + TIter it(fc->GetList()); + TFileInfo *fi; + while ((fi = dynamic_cast<TFileInfo *>(it.Next()))) { + fi->ResetBit(TFileInfo::kStaged); + Int_t nToErase = fi->GetNUrls() - 1; + for (Int_t i=0; i<nToErase; i++) + fi->RemoveUrlAt(0); + } + + fc->Update(); // absolutely necessary + + // Save request + fDataSetStgRepo->ParseUri(validUri, &dsGroup, &dsUser, &dsName); + if (fDataSetStgRepo->WriteDataSet(dsGroup, dsUser, + dsName, fc) == 0) { + // Error, can't save dataset + Error("HandleDataSet", + "can't register staging request for %s", uri.Data()); + delete fc; + return -1; + } + + Info("HandleDataSets", + "Staging request registered for %s", uri.Data()); + + delete fc; + return 0; // success (-1 == failure) + } + break; + + case TProof::kStagingStatus: + { + if (!fDataSetStgRepo) { + Error("HandleDataSets", + "no dataset staging request repository available"); + return -1; + } + + (*mess) >> uri; // TString + + // Transform URI in a valid dataset name + while (reInvalid.Substitute(uri, "_")) {} + + // Get the list + TFileCollection *fc = fDataSetStgRepo->GetDataSet(uri.Data()); + if (fc) { + fSocket->SendObject(fc, kMESS_OK); + delete fc; + return 0; + } + else { + // No such dataset: not an error, but don't send message + Info("HandleDataSets", "no pending staging request for %s", + uri.Data()); + return 0; + } + } + break; + + case TProof::kCancelStaging: + { + if (!fDataSetStgRepo) { + Error("HandleDataSets", + "no dataset staging request repository available"); + return -1; + } + + (*mess) >> uri; + + // Transform URI in a valid dataset name + while (reInvalid.Substitute(uri, "_")) {} + + if (!fDataSetStgRepo->RemoveDataSet(uri.Data())) + return -1; // failure + + return 0; // success + } + break; + case TProof::kShowDataSets: { (*mess) >> uri >> opt; @@ -7037,12 +7404,18 @@ Int_t TProofServ::Fork() //______________________________________________________________________________ void TProofServ::ResolveKeywords(TString &fname, const char *path) { - // Replace <ord>, <user>, <u>, <group>, <stag>, <qnum> and <file> placeholders in fname + // Replace <ord>, <user>, <u>, <group>, <stag>, <qnum>, <file>, <rver> and + // <build> placeholders in fname. + // Here, <rver> is the root version in integer form, e.g. 53403, and <build> a + // string includign version, architecture and compiler version, e.g. + // '53403_linuxx8664gcc_gcc46' . // Replace <user>, if any if (fname.Contains("<user>")) { if (gProofServ && gProofServ->GetUser() && strlen(gProofServ->GetUser())) { fname.ReplaceAll("<user>", gProofServ->GetUser()); + } else if (gProof && gProof->GetUser() && strlen(gProof->GetUser())) { + fname.ReplaceAll("<user>", gProof->GetUser()); } else { fname.ReplaceAll("<user>", "nouser"); } @@ -7052,23 +7425,32 @@ void TProofServ::ResolveKeywords(TString &fname, const char *path) if (gProofServ && gProofServ->GetUser() && strlen(gProofServ->GetUser())) { TString u(gProofServ->GetUser()[0]); fname.ReplaceAll("<u>", u); + } else if (gProof && gProof->GetUser() && strlen(gProof->GetUser())) { + TString u(gProof->GetUser()[0]); + fname.ReplaceAll("<u>", u); } else { fname.ReplaceAll("<u>", "n"); } } // Replace <group>, if any if (fname.Contains("<group>")) { - if (gProofServ && gProofServ->GetGroup() && strlen(gProofServ->GetGroup())) + if (gProofServ && gProofServ->GetGroup() && strlen(gProofServ->GetGroup())) { fname.ReplaceAll("<group>", gProofServ->GetGroup()); - else + } else if (gProof && gProof->GetGroup() && strlen(gProof->GetGroup())) { + fname.ReplaceAll("<group>", gProof->GetGroup()); + } else { fname.ReplaceAll("<group>", "default"); + } } // Replace <stag>, if any if (fname.Contains("<stag>")) { - if (gProofServ && gProofServ->GetSessionTag() && strlen(gProofServ->GetSessionTag())) + if (gProofServ && gProofServ->GetSessionTag() && strlen(gProofServ->GetSessionTag())) { fname.ReplaceAll("<stag>", gProofServ->GetSessionTag()); - else + } else if (gProof && gProof->GetSessionTag() && strlen(gProof->GetSessionTag())) { + fname.ReplaceAll("<stag>", gProof->GetSessionTag()); + } else { ::Warning("TProofServ::ResolveKeywords", "session tag undefined: ignoring"); + } } // Replace <ord>, if any if (fname.Contains("<ord>")) { @@ -7088,6 +7470,17 @@ void TProofServ::ResolveKeywords(TString &fname, const char *path) if (fname.Contains("<file>") && path && strlen(path) > 0) { fname.ReplaceAll("<file>", path); } + // Replace <rver>, if any + if (fname.Contains("<rver>")) { + TString v = TString::Format("%d", gROOT->GetVersionInt()); + fname.ReplaceAll("<rver>", v); + } + // Replace <build>, if any + if (fname.Contains("<build>")) { + TString b = TString::Format("%d_%s_%s", gROOT->GetVersionInt(), gSystem->GetBuildArch(), + gSystem->GetBuildCompilerVersion()); + fname.ReplaceAll("<build>", b); + } } //______________________________________________________________________________ @@ -7248,6 +7641,42 @@ Float_t TProofServ::GetMemStop() return fgMemStop; } +//______________________________________________________________________________ +void TProofServ::GetLocalServer(TString &dsrv) +{ + // Extract LOCALDATASERVER info in 'dsrv' + + // Check if a local data server has been specified + if (gSystem->Getenv("LOCALDATASERVER")) { + dsrv = gSystem->Getenv("LOCALDATASERVER"); + if (!dsrv.EndsWith("/")) dsrv += "/"; + } + + // Done + return; +} + +//______________________________________________________________________________ +void TProofServ::FilterLocalroot(TString &path, const char *dsrv) +{ + // If 'path' is local and 'dsrv' is Xrootd, apply 'path.Localroot' settings, + // if any. + // The final path via the server is dsrv+path. + + TUrl u(path, kTRUE); + if (!strcmp(u.GetProtocol(), "file")) { + // Remove prefix, if any, if included and if Xrootd + TString pfx = gEnv->GetValue("Path.Localroot",""); + if (!pfx.IsNull() && !strncmp(u.GetFile(), pfx.Data(), pfx.Length())) { + TString srvp = TUrl(dsrv).GetProtocol(); + if (srvp == "root" || srvp == "xrd") path.Remove(0, pfx.Length()); + } + } + + // Done + return; +} + //______________________________________________________________________________ Int_t TProofLockPath::Lock() { diff --git a/proof/proof/src/TQueryResultManager.cxx b/proof/proof/src/TQueryResultManager.cxx index 3ed2bb9dc7082..20705875eba08 100644 --- a/proof/proof/src/TQueryResultManager.cxx +++ b/proof/proof/src/TQueryResultManager.cxx @@ -660,12 +660,15 @@ Bool_t TQueryResultManager::FinalizeQuery(TProofQueryResult *pq, "query %d: unknown exit status (%d)", qn, player->GetExitStatus()); } - // Fill some variables; in the CPU time we include also the time used on the - // master fro preparing and merging + // Fill some variables; in the CPU time we do not include anymore the time + // used on the master for preparing and merging, because we want to measure + // the efficiency or farction of time useful for work doen by workers PDB(kGlobal, 1) Info("FinalizeQuery", "cpu: %.4f, saved: %.4f, master: %.4f", cpu, pq->GetUsedCPU() ,GetCpuTime()); - pq->SetProcessInfo(np, cpu - pq->GetUsedCPU() + GetCpuTime()); +// pq->SetProcessInfo(np, cpu - pq->GetUsedCPU() + GetCpuTime()); + // We take the difference because this is the total CPU time of the session + pq->SetProcessInfo(np, cpu - pq->GetUsedCPU()); pq->RecordEnd(st, out); // Save the logs into the query result instance diff --git a/proof/proofbench/CMakeLists.txt b/proof/proofbench/CMakeLists.txt new file mode 100644 index 0000000000000..c1923d850d9df --- /dev/null +++ b/proof/proofbench/CMakeLists.txt @@ -0,0 +1,14 @@ +############################################################################ +# CMakeLists.txt file for building ROOT proof/proofbench package +############################################################################ + +ROOT_USE_PACKAGE(proof/proof) +ROOT_USE_PACKAGE(proof/proofplayer) + +ROOT_GLOB_HEADERS(headers inc/TProof*.h) +ROOT_GLOB_SOURCES(sources src/TProof*.cxx) + +ROOT_GENERATE_DICTIONARY(G__ProofBench ${headers} LINKDEF LinkDef.h) +ROOT_GENERATE_ROOTMAP(ProofBench LINKDEF LinkDef.h DEPENDENCIES Net RIO) +ROOT_LINKER_LIBRARY(ProofBench ${sources} G__ProofBench.cxx LIBRARIES Core DEPENDENCIES Hist Gpad ProofPlayer) +ROOT_INSTALL_HEADERS() diff --git a/proof/proofbench/Module.mk b/proof/proofbench/Module.mk index e672238420ac4..be77d5b0579b3 100644 --- a/proof/proofbench/Module.mk +++ b/proof/proofbench/Module.mk @@ -7,7 +7,7 @@ MODNAME := proofbench MODDIR := $(ROOT_SRCDIR)/proof/$(MODNAME) MODDIRS := $(MODDIR)/src MODDIRI := $(MODDIR)/inc -PBPARDIR := $(ROOT_SRCDIR)/etc/proof/proofbench +PBPARDIR := etc/proof/proofbench PROOFBENCHDIR := $(MODDIR) PROOFBENCHDIRS := $(PROOFBENCHDIR)/src @@ -40,7 +40,7 @@ PBDPARS += $(wildcard $(MODDIRS)/TSel*.cxx) PBDPARH := $(filter-out $(MODDIRI)/TSelHist%, $(PBDPARH)) PBDPARS := $(filter-out $(MODDIRS)/TSelHist%, $(PBDPARS)) -PBDPAR := $(call stripsrc,$(PBPARDIR)/ProofBenchDataSel.par) +PBDPAR := $(PBPARDIR)/ProofBenchDataSel.par ##### ProofBenchCPUSel PAR file ##### PBCPARDIR := $(call stripsrc,$(PROOFBENCHDIRS)/ProofBenchCPUSel) @@ -48,7 +48,7 @@ PBCPARINF := $(PBCPARDIR)/PROOF-INF PBCPARH := $(MODDIRI)/TProofBenchTypes.h $(MODDIRI)/TSelHist.h PBCPARS := $(MODDIRS)/TSelHist.cxx -PBCPAR := $(call stripsrc,$(PBPARDIR)/ProofBenchCPUSel.par) +PBCPAR := $(PBPARDIR)/ProofBenchCPUSel.par # used in the main Makefile ALLHDRS += $(patsubst $(MODDIRI)/%.h,include/%.h,$(PROOFBENCHH)) @@ -81,6 +81,7 @@ $(PROOFBENCHMAP): $(RLIBMAP) $(MAKEFILEDEP) $(PROOFBENCHL) -d $(PROOFBENCHLIBDEPM) -c $(PROOFBENCHL) $(PBDPAR): $(PBDPARH) $(PBDPARS) + $(MAKEDIR) @echo "Generating PAR file $@..." @(if test -d $(PBDPARDIR); then \ rm -fr $(PBDPARDIR); \ @@ -101,16 +102,17 @@ $(PBDPAR): $(PBDPARH) $(PBDPARS) done; \ echo " return 0;" >> $(PBDPARINF)/SETUP.C ; \ echo "}" >> $(PBDPARINF)/SETUP.C ; \ - builddir=$(PWD); \ + builddir=`pwd`; \ cd $(call stripsrc,$(PROOFBENCHDIRS)); \ par=`basename $(PBDPAR)`; \ pardir=`basename $(PBDPARDIR)`; \ - tar cf - $$pardir | gzip > $$par; \ - mv $$par $(PBPARDIR); \ + tar cf - $$pardir | gzip > $$par || exit 1; \ + mv $$par $$builddir/$(PBPARDIR) || exit 1; \ cd $$builddir; \ rm -fr $(PBDPARDIR)) $(PBCPAR): $(PBCPARH) $(PBCPARS) + $(MAKEDIR) @echo "Generating PAR file $@..." @(if test -d $(PBCPARDIR); then \ rm -fr $(PBCPARDIR); \ @@ -131,12 +133,12 @@ $(PBCPAR): $(PBCPARH) $(PBCPARS) done; \ echo " return 0;" >> $(PBCPARINF)/SETUP.C ; \ echo "}" >> $(PBCPARINF)/SETUP.C ; \ - builddir=$(PWD); \ + builddir=`pwd`; \ cd $(call stripsrc,$(PROOFBENCHDIRS)); \ par=`basename $(PBCPAR)`; \ pardir=`basename $(PBCPARDIR)`; \ - tar cf - $$pardir | gzip > $$par; \ - mv $$par $(PBPARDIR); \ + tar cf - $$pardir | gzip > $$par || exit 1; \ + mv $$par $$builddir/$(PBPARDIR) || exit 1; \ cd $$builddir; \ rm -fr $(PBCPARDIR)) diff --git a/proof/proofbench/inc/TProofBench.h b/proof/proofbench/inc/TProofBench.h index 8a8a152675207..68002bf6b94aa 100644 --- a/proof/proofbench/inc/TProofBench.h +++ b/proof/proofbench/inc/TProofBench.h @@ -33,6 +33,8 @@ class TF1; class TFile; +class TGraphErrors; +class TProfile; class TProof; class TProofBenchRunCPU; class TProofBenchRunDataRead; @@ -55,6 +57,8 @@ class TProofBench : public TObject { TPBReadType *fReadType; // Type of read (partial, full) TString fDataSet; // Name of the dataset Int_t fNFilesWrk; // Number of files generated files per worker + Int_t fNumWrkMax; // Max number of workers (required for dynamic setups) + Bool_t fReleaseCache; // Release cache for data reads between runs TString fCPUSel; // Selector to be used for CPU benchmarks TString fCPUPar; // List of par files to be loaded for CPU benchmarks @@ -71,10 +75,21 @@ class TProofBench : public TObject { TNamed *fDescription; // Strings describing the cluster for this test (saved in the output file) + static TGraphErrors *GetGraph(TDirectory *d, const char *pfn, + Int_t &nb, Double_t &xmi, Double_t &xmx, + Double_t &ymi, Double_t &ymx, Int_t &kmx, TProfile *&pf); + static TF1 *fgFp1; // Simple 1st degree polynomial static TF1 *fgFp1n; // Normalized 1st degree static TF1 *fgFp2; // Simple 2nd degree polynomial static TF1 *fgFp2n; // Normalized 2nd degree + static TF1 *fgFp3; // Function with varying Rcpu + static TF1 *fgFp3n; // Normalized Function with varying Rcpu + + static TF1 *fgFio; // Function used for I/O rate fits + static TF1 *fgFioV; // Function used for I/O rate fits with non-constant Rcpu + + static TList *fgGraphs; // List of TGraphErrors created by Draw actions static void AssertFittingFun(Double_t mi, Double_t mx); @@ -105,6 +120,7 @@ class TProofBench : public TObject { void SetHistType(TPBHistType *histtype) { fHistType = histtype; } void SetNHist(Int_t nh) { fNHist = nh; } void SetReadType(TPBReadType *readtype) { fReadType = readtype; } + void SetReleaseCache(Bool_t on = kTRUE) { fReleaseCache = on; } void SetCPUSel(const char *sel) { fCPUSel = sel; } void SetCPUPar(const char *par) { fCPUPar = par; } @@ -119,9 +135,14 @@ class TProofBench : public TObject { Bool_t GetDebug() { return fDebug; } - static void DrawCPU(const char *outfile, const char *opt = "std:", Bool_t verbose = kFALSE, Int_t dofit = 0); - static void DrawDataSet(const char *outfile, const char *opt = "std:", const char *type = "mbs", Bool_t verbose = kFALSE); + static void DrawCPU(const char *outfile, const char *opt = "std:", Bool_t verbose = kFALSE, + Int_t dofit = 0, Int_t n0 = -1, Int_t n1 = -1); + static void DrawDataSet(const char *outfile, const char *opt = "std:", const char *type = "mbs", Bool_t verbose = kFALSE, + Int_t dofit = 0, Int_t n0 = -1, Int_t n1 = -1); static void GetPerfSpecs(const char *path = ".", Int_t degfit = 1); + static void DrawEfficiency(const char *outfile, const char *opt = "", Bool_t verbose = kFALSE); + + static TList *GetGraphs() { return fgGraphs; } ClassDef(TProofBench, 0) // Steering class for PROOF benchmarks }; diff --git a/proof/proofbench/inc/TProofBenchRunCPU.h b/proof/proofbench/inc/TProofBenchRunCPU.h index 55baab1794117..4763c97225199 100644 --- a/proof/proofbench/inc/TProofBenchRunCPU.h +++ b/proof/proofbench/inc/TProofBenchRunCPU.h @@ -34,6 +34,7 @@ class TCanvas; class TList; class TProof; class TProfile; +class TLegend; class TH2; class TTree; @@ -67,8 +68,14 @@ class TProofBenchRunCPU : public TProofBenchRun { TProfile *fProfile_perfstat_event; TH2 *fHist_perfstat_event; + TProfile *fProfile_perfstat_evtmax; + TProfile *fNorm_perfstat_evtmax; TProfile *fProfile_queryresult_event; TProfile *fNorm_queryresult_event; + TProfile *fProfile_cpu_eff; + + TLegend *fProfLegend; // Legend for profiles + TLegend *fNormLegend; // Legend for norms TString fName; //name of CPU run diff --git a/proof/proofbench/inc/TProofBenchRunDataRead.h b/proof/proofbench/inc/TProofBenchRunDataRead.h index b81eb633779c7..77af86bfffc68 100644 --- a/proof/proofbench/inc/TProofBenchRunDataRead.h +++ b/proof/proofbench/inc/TProofBenchRunDataRead.h @@ -36,6 +36,7 @@ class TProof; class TCanvas; class TH2; class TProfile; +class TLegend; class TTree; class TFileCollection; @@ -59,6 +60,7 @@ class TProofBenchRunDataRead : public TProofBenchRun { Int_t fStep; //test to be performed every fStep workers Int_t fDebug; //debug switch Int_t fFilesPerWrk; //# of files to be processed per worker + Bool_t fReleaseCache; // Release cache for data reads between runs TDirectory *fDirProofBench; //directory for proof outputs @@ -67,12 +69,22 @@ class TProofBenchRunDataRead : public TProofBenchRun { TList *fListPerfPlots; //list of performance plots TProfile *fProfile_perfstat_event; TH2 *fHist_perfstat_event; + TProfile *fProfile_perfstat_evtmax; + TProfile *fNorm_perfstat_evtmax; TProfile *fProfile_queryresult_event; TProfile *fNorm_queryresult_event; TProfile *fProfile_perfstat_IO; TH2 *fHist_perfstat_IO; + TProfile *fProfile_perfstat_IOmax; + TProfile *fNorm_perfstat_IOmax; TProfile *fProfile_queryresult_IO; TProfile *fNorm_queryresult_IO; + TProfile *fProfile_cpu_eff; + + TLegend *fProfLegend_evt; // Legend for profiles evts + TLegend *fNormLegend_evt; // Legend for norms evts + TLegend *fProfLegend_mb; // Legend for profiles mbs + TLegend *fNormLegend_mb; // Legend for norms mbs TCanvas *fCPerfProfiles; //canvas for performance profile histograms @@ -115,6 +127,7 @@ class TProofBenchRunDataRead : public TProofBenchRun { void SetDebug(Int_t debug) { fDebug = debug; } void SetDirProofBench(TDirectory* dir) { fDirProofBench = dir; } void SetFilesPerWrk(Int_t fpw) { fFilesPerWrk = fpw; } + void SetReleaseCache(Bool_t on = kTRUE) { fReleaseCache = on; } TPBReadType *GetReadType() const { return fReadType; } Long64_t GetNEvents() const { return fNEvents; } diff --git a/proof/proofbench/inc/TProofNodes.h b/proof/proofbench/inc/TProofNodes.h index 342e3875abe28..2e4b02088c5bf 100644 --- a/proof/proofbench/inc/TProofNodes.h +++ b/proof/proofbench/inc/TProofNodes.h @@ -37,6 +37,7 @@ class TProofNodes: public TObject { Int_t fNNodes; // Number of nodes Int_t fNWrks; // Number of workers Int_t fNActiveWrks; // Number of active workers + Int_t fNCores; // Number of total cores void Build(); public: @@ -48,6 +49,7 @@ class TProofNodes: public TObject { Int_t GetMaxWrksPerNode() const { return fMaxWrksNode; } Int_t GetNWorkersCluster() const { return fNWrks; } Int_t GetNNodes() const { return fNNodes; } + Int_t GetNCores() const { return fNCores; } Int_t GetMinWrksPerNode() const { return fMinWrksNode; } Int_t GetNActives() const { return fNActiveWrks; } TMap* GetMapOfNodes() const { return fNodes; } diff --git a/proof/proofbench/inc/TProofPerfAnalysis.h b/proof/proofbench/inc/TProofPerfAnalysis.h index f633596a48b99..fac555dbbaa46 100644 --- a/proof/proofbench/inc/TProofPerfAnalysis.h +++ b/proof/proofbench/inc/TProofPerfAnalysis.h @@ -38,7 +38,11 @@ class TTree; class TProofPerfAnalysis : public TNamed { public: // public because of Sun CC bug + class TFileInfo; + class TPackInfo; + class TWrkEntry; class TWrkInfo; + class TWrkInfoFile; private: TFile *fFile; // The open performance file @@ -46,6 +50,7 @@ class TProofPerfAnalysis : public TNamed { TString fTreeName; // The name of the performance tree TTree *fTree; // The performance tree TSortedList fWrksInfo; // Sorted list of workers info + TSortedList fFilesInfo; // Sorted list of files info Float_t fInitTime; // End of initialization time for this query Float_t fMergeTime; // Begin of merging time for this query Float_t fMaxTime; // Max time for this query (slowest worker) @@ -54,21 +59,33 @@ class TProofPerfAnalysis : public TNamed { Double_t fEvtRateMax; // Max event processing rate per packet Double_t fMBRateMax; // Max MB processing rate per packet Double_t fLatencyMax; // Max retrieval latency per packet + TH1F *fEvtRate; // Event processing rate vs query time + TH1F *fEvtRateRun; // Event processing rate running avg vs query time + TH1F *fMBRate; // Byte processing rate vs query time + TH1F *fMBRateRun; // Byte processing rate running avg vs query time + Double_t fEvtRateAvgMax; // Max running event processing rate + Double_t fMBRateAvgMax; // Max running MB processing rate + Double_t fEvtRateAvg; // Average event processing rate + Double_t fMBRateAvg; // Average MB processing rate - static Int_t fgDebug; // Verbosity level + Int_t fDebug; // Local verbosity level + + static Bool_t fgDebug; // Global verbosity on/off Int_t CompareOrd(const char *ord1, const char *ord2); void FillFileDist(TH1F *hf, TH1F *hb, TH2F *hx, Bool_t wdet = kFALSE); void FillFileDistOneSrv(TH1F *hx, Bool_t wdet = kFALSE); void FillWrkInfo(Bool_t force = kFALSE); + void FillFileInfo(Bool_t force = kFALSE); TString GetCanvasTitle(const char *t); - void GetFileInfo(TList *wl, TList *sl); + void GetWrkFileList(TList *wl, TList *sl); void LoadTree(TDirectory *dir); public: TProofPerfAnalysis(const char *perffile, const char *title = "", const char *treename = "PROOF_PerfStats"); + TProofPerfAnalysis(TTree *tree, const char *title = ""); virtual ~TProofPerfAnalysis(); Bool_t IsValid() const { return (fFile && fTree) ? kTRUE : kFALSE; } @@ -81,8 +98,23 @@ class TProofPerfAnalysis : public TNamed { void WorkerActivity(); // Analyse the worker activity void PrintWrkInfo(Int_t showlast = 10); // Print workers info void PrintWrkInfo(const char *wrk); // Print worker info by name - + + void PrintFileInfo(Int_t showlast = 10, const char *opt = "", const char *out = 0); // Print file info + void PrintFileInfo(const char *fn, const char *opt = "P", const char *out = 0); // Print file info by name + void FileProcPlot(const char *fn, const char *out = 0); // Plot info about file processing + void FileRatePlot(const char *fns = 0); // Plot info about file processing rates + + Double_t GetEvtRateAvgMax() const { return fEvtRateAvgMax; } // Max running event processing rate + Double_t GetMBRateAvgMax() const { return fMBRateAvgMax; } // Max running MB processing rate + Double_t GetEvtRateAvg() const { return fEvtRateAvg; } // Average event processing rate + Double_t GetMBRateAvg() const { return fMBRateAvg; } // Average MB processing rate + void GetAverages(Double_t &evtmax, Double_t &mbmax, Double_t &evt, Double_t &mb) const + { evtmax = fEvtRateAvgMax; mbmax = fMBRateAvgMax; evt = fEvtRateAvg; mb = fMBRateAvg; return; } + + void Summary(Option_t *opt = "", const char *out = ""); + void SetDebug(Int_t d = 0); // Setter for the verbosity level + static void SetgDebug(Bool_t on = kTRUE); // Overall verbosity level ClassDef(TProofPerfAnalysis, 0) // Set of tools to analyse the performance tree }; diff --git a/proof/proofbench/src/TProofBench.cxx b/proof/proofbench/src/TProofBench.cxx index d158f4aaea236..8012dc298d059 100644 --- a/proof/proofbench/src/TProofBench.cxx +++ b/proof/proofbench/src/TProofBench.cxx @@ -45,6 +45,7 @@ #include "TMath.h" #include "TProfile.h" #include "TStyle.h" +#include "TLegend.h" ClassImp(TProofBench) @@ -54,6 +55,14 @@ TF1 *TProofBench::fgFp1 = 0; TF1 *TProofBench::fgFp1n = 0; TF1 *TProofBench::fgFp2 = 0; TF1 *TProofBench::fgFp2n = 0; +TF1 *TProofBench::fgFp3 = 0; +TF1 *TProofBench::fgFp3n = 0; +TF1 *TProofBench::fgFio = 0; +TF1 *TProofBench::fgFioV = 0; +static Int_t gFioVn0 = -1; // Number of real cores for fgFioV +static Int_t gFioVn1 = -1; // Number of real+hyper cores for fgFioV + +TList *TProofBench::fgGraphs = new TList; //_____________________________________________________________________ Double_t funp1(Double_t *xx, Double_t *par) @@ -91,11 +100,79 @@ Double_t funp2n(Double_t *xx, Double_t *par) return res; } +//_____________________________________________________________________ +Double_t funio(Double_t *xx, Double_t *par) +{ + // I/O saturated rate function + + Double_t sat = par[0] / par[1] * (xx[0] * par[1] / par[2] - 1.); + if (xx[0] < par[2] / par[1]) sat = 0.; + Double_t res = par[0] * xx[0] / (1. + sat); + return res; +} + +//_____________________________________________________________________ +Double_t funiov(Double_t *xx, Double_t *par) +{ + // I/O saturated rate function with varying Rcpu + + // par[0] = rio + // par[1] = b1 + // par[2] = b2 + // par[3] = nc + // par[4] = ri + + Double_t rio = par[0] / par[3] * xx[0]; + if (xx[0] > par[3]) rio = par[0]; + + Double_t rcpu = par[1] * xx[0]; + if (xx[0] > gFioVn0) rcpu = par[1]*gFioVn0 + par[2]*(xx[0] - gFioVn0); + if (xx[0] > gFioVn1) rcpu = par[1]*gFioVn0 + par[2]*(gFioVn1 - gFioVn0); + + Double_t res = 1. / (1./par[4] + 1./rio + 1./rcpu); + + return res; +} + +//_____________________________________________________________________ +Double_t funcpuv(Double_t *xx, Double_t *par) +{ + // Function with varying Rcpu + + // par[0] = offset + // par[1] = rate contribution from real cores + // par[2] = rate contribution from hyper cores + + Double_t n = (xx[0] - par[0]); + Double_t rcpu = par[1] * n; + if (xx[0] > gFioVn0) rcpu = par[1]*gFioVn0 + par[2]*(n - gFioVn0); + if (xx[0] > gFioVn1) rcpu = par[1]*gFioVn0 + par[2]*(gFioVn1 - gFioVn0); + + return rcpu; +} + +//_____________________________________________________________________ +Double_t funcpuvn(Double_t *xx, Double_t *par) +{ + // Function with varying Rcpu normalized + + // par[0] = offset + // par[1] = rate contribution from real cores + // par[2] = rate contribution from hyper cores + + Double_t n = (xx[0] - par[0]); + Double_t rcpu = par[1] * n; + if (xx[0] > gFioVn0) rcpu = par[1]*gFioVn0 + par[2]*(n - gFioVn0); + if (xx[0] > gFioVn1) rcpu = par[1]*gFioVn0 + par[2]*(gFioVn1 - gFioVn0); + + return rcpu / xx[0]; +} + //______________________________________________________________________________ TProofBench::TProofBench(const char *url, const char *outfile, const char *proofopt) : fUnlinkOutfile(kFALSE), fProofDS(0), fOutFile(0), fNtries(4), fHistType(0), fNHist(16), fReadType(0), - fDataSet("BenchDataSet"), fNFilesWrk(4), + fDataSet("BenchDataSet"), fNFilesWrk(2), fReleaseCache(kTRUE), fDataGenSel(kPROOF_BenchSelDataGenDef), fRunCPU(0), fRunDS(0), fDS(0), fDebug(kFALSE), fDescription(0) { @@ -110,6 +187,33 @@ TProofBench::TProofBench(const char *url, const char *outfile, const char *proof Error("TProofBench", "could not open a valid PROOF session - cannot continue"); return; } + // Get the size of the cluster + fNumWrkMax = fProof->GetParallel(); + if (fProof->UseDynamicStartup() && TProof::GetEnvVars()) { + // It must be passed as PROOF option 'workers=N' and recorded in the envs vars + TNamed *n = (TNamed *) TProof::GetEnvVars()->FindObject("PROOF_NWORKERS"); + if (!n) { + Error("TProofBench", "dynamic mode: you must specify the max number of workers"); + fProof->Close(); + SafeDelete(fProof); + return; + } + TString sn(n->GetTitle()); + if (sn.IsDigit()) fNumWrkMax = sn.Atoi(); + if (!sn.IsDigit()) { + Error("TProofBench", "dynamic mode: wrong specification of the max number of" + " workers ('%s')", n->GetTitle()); + fProof->Close(); + SafeDelete(fProof); + return; + } + } + if (fNumWrkMax <= 0) { + Error("TProofBench", "wrong max number of workers ('%d')", fNumWrkMax); + fProof->Close(); + SafeDelete(fProof); + return; + } // By default we use the same instance for dataset actions fProofDS = fProof; // The object is now valid @@ -119,7 +223,7 @@ TProofBench::TProofBench(const char *url, const char *outfile, const char *proof TString host(TString::Format("PROOF at %s", u.GetHost())); if (!strcmp(u.GetProtocol(), "lite")) host.Form("PROOF-Lite on %s", gSystem->HostName()); fDescription = new TNamed("PB_description", - TString::Format("%s, %d workers", host.Data(), fProof->GetParallel()).Data()); + TString::Format("%s, %d workers", host.Data(), fNumWrkMax).Data()); Printf(" Run description: %s", fDescription->GetTitle()); // Set output file if (SetOutFile(outfile, kFALSE) != 0) @@ -193,7 +297,7 @@ Int_t TProofBench::SetOutFile(const char *outfile, Bool_t verbose) TDatime dat; const char *lite = (fProof->IsLite()) ? "-lite" : ""; fOutFileName.Form("proofbench-%s%s-%dw-%d-%.2d%.2d.root", - fProof->GetMaster(), lite, fProof->GetParallel(), + fProof->GetMaster(), lite, fNumWrkMax, dat.GetDate(), dat.GetHour(), dat.GetMinute()); Info("SetOutFile", "using default output file: '%s'", fOutFileName.Data()); fUnlinkOutfile = kTRUE; @@ -272,17 +376,25 @@ Int_t TProofBench::RunCPUx(Long64_t nevents, Int_t start, Int_t stop) } //______________________________________________________________________________ -void TProofBench::DrawCPU(const char *outfile, const char *opt, Bool_t verbose, Int_t dofit) +void TProofBench::DrawCPU(const char *outfile, const char *opt, Bool_t verbose, + Int_t dofit, Int_t n0, Int_t n1) { // Draw the CPU speedup plot. - // opt = 'std:' draw standard evt/s plot + // opt = 'typewhat', e.g. 'std:max:' + // type = 'std:' draw standard evt/s plot // 'stdx:' draw standard evt/s plot, 1 worker per node // 'norm:' draw normalized plot // 'normx:' draw normalized plot, 1 worker per node + // what = 'max:' draw max rate + // 'avg:' draw average rate + // 'all:' draw max and average rate on same plot (default) // dofit = 0 no fit // 1 fit with the relevant '1st degree related' function // 2 fit with the relevant '2nd degree related' function - // + // 3 fit with varying rcpu function + // n0 = for dofit == 3, number of real cores + // n1 = for dofit == 3, number of total cores (real + hyperthreaded) + // // Get the TProfile an create the graphs TFile *fout = TFile::Open(outfile, "READ"); @@ -296,101 +408,127 @@ void TProofBench::DrawCPU(const char *outfile, const char *opt, Bool_t verbose, TNamed *nmdesc = (TNamed *) fout->Get("PB_description"); if (nmdesc) description = nmdesc->GetTitle(); + // Parse option TString oo(opt); - const char *dirn = (oo.Contains("x:")) ? "RunCPUx" : "RunCPU"; + Bool_t isNorm = (oo.Contains("norm")) ? kTRUE : kFALSE; + Bool_t isX = (oo.Contains("stdx:") || oo.Contains("normx:")) ? kTRUE : kFALSE; + Bool_t doAvg = kTRUE, doMax = kTRUE; + if (oo.Contains("avg:")) doMax = kFALSE; + if (oo.Contains("max:")) doAvg = kFALSE; + + const char *dirn = (isX) ? "RunCPUx" : "RunCPU"; TDirectory *d = (TDirectory *) fout->Get(dirn); if (!d) { - ::Error("DrawCPU", "could not find directory 'RunCPU' ..."); + ::Error("DrawCPU", "could not find directory '%s' ...", dirn); fout->Close(); delete fout; return; } d->cd(); - TString hprofn; - Bool_t isnorm = kFALSE; - if (!strcmp(opt, "std:")) { - hprofn = "Prof_CPU_QR_Evts"; - } else if (!strcmp(opt, "stdx:")) { - hprofn = "Prof_x_CPU_QR_Evts"; - } else if (!strcmp(opt, "norm:")) { - hprofn = "Norm_CPU_QR_Evts"; - isnorm = kTRUE; - } else if (!strcmp(opt, "normx:")) { - hprofn = "Norm_x_CPU_QR_Evts"; - isnorm = kTRUE; - } else { - ::Error("DrawCPU", "unknown option '%s'", opt); - fout->Close(); - delete fout; - return; - } - TProfile *pf = 0; - TList *keylist = d->GetListOfKeys(); - TKey *key = 0; - TIter nxk(keylist); - while ((key = (TKey *) nxk())) { - if (TString(key->GetName()).BeginsWith(hprofn)) { - pf = (TProfile *) d->Get(key->GetName()); - break; + + TString hprofn, hmaxn; + const char *lx = (isX) ? "_x" : ""; + const char *ln = (isNorm) ? "Norm" : "Prof"; + hprofn.Form("%s%s_CPU_QR_Evts", ln, lx); + hmaxn.Form("%s%s_CPU_PS_MaxEvts", ln, lx); + + Double_t xmin = -1., xmax = -1.; + Double_t ami = -1., amx = -1., mmi = -1., mmx = -1.; + Int_t kamx = -1, kmmx = -1, nbins = -1; + Double_t ymx = -1., ymi = -1.; + + TProfile *pfav = 0; + TGraphErrors *grav = 0; + if (doAvg) { + if (!(grav = GetGraph(d, hprofn, nbins, xmin, xmax, ami, amx, kamx, pfav))) { + ::Error("DrawCPU", "could not find '%s' ...", hprofn.Data()); + fout->Close(); + delete fout; + return; } + ymx = amx; + ymi = ami; } - if (!pf) { - ::Error("DrawCPU", "could not find '%s' ...", hprofn.Data()); - fout->Close(); - delete fout; - return; - } - - Int_t nbins = pf->GetNbinsX(); - TGraphErrors *gr = new TGraphErrors(nbins); - Double_t xx, ex, yy, ey, ymi = pf->GetBinContent(1), ymx = ymi; - Int_t k =1, kmx = -1; - for (;k <= nbins; k++) { - xx = pf->GetBinCenter(k); - ex = pf->GetBinWidth(k) * .001; - yy = pf->GetBinContent(k); - ey = pf->GetBinError(k); - if (k == 1) { - ymi = yy; - ymx = yy; - kmx = k; - } else { - if (yy < ymi) ymi = yy; - if (yy > ymx) { ymx = yy; kmx = k; } + TProfile *pfmx = 0; + TGraphErrors *grmx = 0; + if (doMax) { + if (!(grmx = GetGraph(d, hmaxn, nbins, xmin, xmax, mmi, mmx, kmmx, pfmx))) { + ::Warning("DrawCPU", "could not find '%s': feature added in 5.34/11", hmaxn.Data()); + if (!grav) { + // Nothing to do if not asked for the average + fout->Close(); + delete fout; + return; + } + doMax = kFALSE; } - gr->SetPoint(k-1, xx, yy); - gr->SetPointError(k-1, ex, ey); + if (mmx > ymx) ymx = mmx; + if ((ymi > 0 && mmi < ymi) || (ymi < 0.)) ymi = mmi; } + TProfile *pf = (doMax) ? pfmx : pfav; + Int_t kmx = (doMax) ? kmmx : kamx; + // Create the canvas TCanvas *cpu = new TCanvas("cpu", "Rate vs wrks",204,69,1050,502); cpu->Range(-3.106332,0.7490716,28.1362,1.249867); - gStyle->SetOptTitle(0); - gr->SetFillColor(1); - gr->SetLineColor(13); - gr->SetMarkerStyle(21); - gr->SetMarkerSize(1.2); - - TH1F *hgr = new TH1F("Graph-CPU"," CPU speed-up", nbins*4,0,nbins+1); + TH1F *hgr = new TH1F("Graph-CPU"," CPU speed-up", nbins*4, xmin, xmax); hgr->SetMaximum(ymx + (ymx-ymi)*0.2); hgr->SetMinimum(0); + if (isNorm) hgr->SetMaximum(ymx*1.2); hgr->SetDirectory(0); hgr->SetStats(0); -// hgr->CenterTitle(true); hgr->GetXaxis()->SetTitle(pf->GetXaxis()->GetTitle()); hgr->GetXaxis()->CenterTitle(true); hgr->GetXaxis()->SetLabelSize(0.05); hgr->GetXaxis()->SetTitleSize(0.06); hgr->GetXaxis()->SetTitleOffset(0.62); - hgr->GetYaxis()->SetLabelSize(0.06); - gr->SetHistogram(hgr); + hgr->GetYaxis()->SetTitleSize(0.08); + hgr->GetYaxis()->SetTitleOffset(0.52); + hgr->GetYaxis()->SetTitle("Rate (events/s)"); - if (verbose) gr->Print(); - - gr->Draw("alp"); + TLegend *leg = 0; + if (isNorm) { + leg = new TLegend(0.7, 0.8, 0.9, 0.9); + } else { + leg = new TLegend(0.1, 0.8, 0.3, 0.9); + } + + gStyle->SetOptTitle(0); + if (doAvg) { + grav->SetFillColor(1); + grav->SetLineColor(13); + grav->SetMarkerColor(4); + grav->SetMarkerStyle(21); + grav->SetMarkerSize(1.2); + grav->SetHistogram(hgr); + + if (verbose) grav->Print(); + grav->Draw("alp"); + leg->AddEntry(grav, "Average", "P"); + } + if (doMax) { + grmx->SetFillColor(1); + grmx->SetLineColor(13); + grmx->SetMarkerColor(2); + grmx->SetMarkerStyle(29); + grmx->SetMarkerSize(1.8); + grmx->SetHistogram(hgr); + + if (verbose) grmx->Print(); + if (doAvg) { + grmx->Draw("lpSAME"); + } else { + grmx->Draw("alp"); + } + leg->AddEntry(grmx, "Maximum", "P"); + } + leg->Draw(); + gPad->Update(); if (dofit > 0) { + TGraphErrors *gr = (doMax) ? grmx : grav; // Make sure the fitting functions are defined Double_t xmi = 0.9; if (nbins > 5) xmi = 1.5; @@ -399,7 +537,7 @@ void TProofBench::DrawCPU(const char *outfile, const char *opt, Bool_t verbose, // Starting point for the parameters and fit Double_t normrate = -1.; if (dofit == 1) { - if (isnorm) { + if (isNorm) { fgFp1n->SetParameter(0, pf->GetBinContent(1)); fgFp1n->SetParameter(1, pf->GetBinContent(nbins-1)); gr->Fit(fgFp1n); @@ -410,10 +548,10 @@ void TProofBench::DrawCPU(const char *outfile, const char *opt, Bool_t verbose, fgFp1->SetParameter(1, pf->GetBinContent(1)); gr->Fit(fgFp1); if (verbose) fgFp1->Print(); - normrate = fgFp1->GetParameter(1); + normrate = fgFp1->Derivative(1.); } - } else { - if (isnorm) { + } else if (dofit == 2) { + if (isNorm) { fgFp2n->SetParameter(0, pf->GetBinContent(1)); fgFp2n->SetParameter(1, pf->GetBinContent(nbins-1)); fgFp2n->SetParameter(2, 0.); @@ -426,12 +564,31 @@ void TProofBench::DrawCPU(const char *outfile, const char *opt, Bool_t verbose, fgFp2->SetParameter(2, 0.); gr->Fit(fgFp2); if (verbose) fgFp2->Print(); - normrate = fgFp2->GetParameter(1); + normrate = fgFp2->Derivative(1.); + } + } else { + // Starting point for the parameters and fit + gFioVn0 = (n0 > 0) ? n0 : (Int_t) (nbins + .1)/2.; + gFioVn1 = (n1 > 0) ? n1 : (Int_t) (nbins + .1); + if (isNorm) { + fgFp3n->SetParameter(0, 0.); + fgFp3n->SetParameter(1, pf->GetBinContent(1)); + fgFp3n->SetParameter(2, pf->GetBinContent(nbins-1)); + gr->Fit(fgFp3n); + if (verbose) fgFp3n->Print(); + normrate = pf->GetBinContent(1); + } else { + fgFp3->SetParameter(0, 0.); + fgFp3->SetParameter(1, 0.); + fgFp3->SetParameter(2, pf->GetBinContent(1)); + gr->Fit(fgFp3); + if (verbose) fgFp3->Print(); + normrate = fgFp3->Derivative(1.); } } // Notify the cluster performance parameters - if (!isnorm) { + if (!isNorm) { printf("* ************************************************************ *\n"); printf("* *\r"); printf("* Cluster: %s\n", description.Data()); @@ -452,6 +609,67 @@ void TProofBench::DrawCPU(const char *outfile, const char *opt, Bool_t verbose, } // Close the file fout->Close(); + if (grav) fgGraphs->Add(grav); + if (grmx) fgGraphs->Add(grmx); +} + +//______________________________________________________________________________ +TGraphErrors *TProofBench::GetGraph(TDirectory *d, const char *pfn, Int_t &nb, + Double_t &xmi, Double_t &xmx, + Double_t &ymi, Double_t &ymx, Int_t &kmx, TProfile *&pf) +{ + // Get from TDirectory 'd' the TProfile named 'pfn' and create the graph. + // Return also the max y in mx. + + // Sanity checks + if (!d || !pfn || (pfn && strlen(pfn) <= 0)) { + ::Error("TProofBench::GetGraph", "directory or name not defined!"); + return (TGraphErrors *)0; + } + + TList *keylist = d->GetListOfKeys(); + TKey *key = 0; + TIter nxk(keylist); + while ((key = (TKey *) nxk())) { + if (TString(key->GetName()).BeginsWith(pfn)) { + pf = (TProfile *) d->Get(key->GetName()); + break; + } + } + // Sanity checks + if (!pf) { + ::Error("TProofBench::GetGraph", "TProfile for '%s' not found in directory '%s'", pfn, d->GetName()); + return (TGraphErrors *)0; + } + + nb = pf->GetNbinsX(); + TGraphErrors *gr = new TGraphErrors(nb); + gr->SetName(TString::Format("Graph_%s", pfn)); + Double_t xx, ex, yy, ey; + ymi = pf->GetBinContent(1); + ymx = ymi; + xmi = pf->GetBinCenter(1) - pf->GetBinWidth(1)/2. ; + xmx = pf->GetBinCenter(nb) + pf->GetBinWidth(nb)/2. ; + kmx = -1; + for (Int_t k = 1;k <= nb; k++) { + xx = pf->GetBinCenter(k); + ex = pf->GetBinWidth(k) * .001; + yy = pf->GetBinContent(k); + ey = pf->GetBinError(k); + if (k == 1) { + ymi = yy; + ymx = yy; + kmx = k; + } else { + if (yy < ymi) ymi = yy; + if (yy > ymx) { ymx = yy; kmx = k; } + } + gr->SetPoint(k-1, xx, yy); + gr->SetPointError(k-1, ex, ey); + } + + // Done + return gr; } //______________________________________________________________________________ @@ -479,6 +697,25 @@ void TProofBench::AssertFittingFun(Double_t mi, Double_t mx) fgFp2n->SetParNames("decay", "norm rate", "deviation"); } + if (!fgFp3) { + fgFp3 = new TF1("funcpuv", funcpuv, mi, mx, 3); + fgFp3->SetParNames("offset", "slope real", "slope hyper"); + } + + if (!fgFp3n) { + fgFp3n = new TF1("funcpuvn", funcpuvn, mi, mx, 3); + fgFp3n->SetParNames("offset", "slope real", "slope hyper"); + } + + if (!fgFio) { + fgFio = new TF1("funio", funio, mi, mx, 3); + fgFio->SetParNames("R1", "RIO", "TotIO"); + } + if (!fgFioV) { + fgFioV = new TF1("funiov", funiov, mi, mx, 5); + fgFioV->SetParNames("rio", "b1", "b2", "nc", "ri"); + } + } //______________________________________________________________________________ @@ -647,13 +884,14 @@ Int_t TProofBench::RunDataSet(const char *dset, } fUnlinkOutfile = kFALSE; - ReleaseCache(dset); + if (fReleaseCache) ReleaseCache(dset); SafeDelete(fRunDS); TPBReadType *readType = fReadType; if (!readType) readType = new TPBReadType(TPBReadType::kReadOpt); fRunDS = new TProofBenchRunDataRead(fDS, readType, fOutFile); if (!fDataSel.IsNull()) fRunDS->SetSelName(fDataSel); if (!fDataPar.IsNull()) fRunDS->SetParList(fDataPar); + fRunDS->SetReleaseCache(fReleaseCache); fRunDS->Run(dset, start, stop, step, fNtries, fDebug, -1); if (!fReadType) SafeDelete(readType); @@ -699,15 +937,25 @@ Int_t TProofBench::RunDataSetx(const char *dset, Int_t start, Int_t stop) //______________________________________________________________________________ void TProofBench::DrawDataSet(const char *outfile, - const char *opt, const char *type, Bool_t verbose) + const char *opt, const char *type, Bool_t verbose, + Int_t dofit, Int_t n0, Int_t n1) { // Draw the CPU speedup plot. - // opt = 'std:' Standard scaling plot - // 'norm:' Normalized scaling plot - // 'stdx:' Standard scaling plot, 1 worker per node - // 'normx:' Normalized scaling plot, 1 worker per node + // opt = 'typewhat', e.g. 'std:max:' + // type = 'std:' draw standard plot + // 'stdx:' draw standard plot, 1 worker per node + // 'norm:' draw normalized plot + // 'normx:' draw normalized plot, 1 worker per node + // what = 'max:' draw max rate + // 'avg:' draw average rate + // 'all:' draw max and average rate on same plot (default) // type = 'mbs' MB/s scaling plots (default) // 'evts' Event/s scaling plots + // dofit = 0 no fit + // 1 fit with default 3 parameter saturated I/O formula + // 2 fit with 4 parameter saturated I/O formula (varying Rcpu) + // n0 = for dofit == 2, number of real cores + // n1 = for dofit == 2, number of total cores (real + hyperthreaded) // // Get the TProfile an create the graphs @@ -716,100 +964,309 @@ void TProofBench::DrawDataSet(const char *outfile, ::Error("DrawDataSet", "could not open file '%s' ...", outfile); return; } + + // Get description + TString description("<not available>"); + TNamed *nmdesc = (TNamed *) fout->Get("PB_description"); + if (nmdesc) description = nmdesc->GetTitle(); + + // Parse option TString oo(opt); - const char *dirn = (oo.Contains("x:")) ? "RunDataReadx" : "RunDataRead"; + Bool_t isNorm = (oo.Contains("norm")) ? kTRUE : kFALSE; + Bool_t isX = (oo.Contains("stdx:") || oo.Contains("normx:")) ? kTRUE : kFALSE; + Bool_t doAvg = kTRUE, doMax = kTRUE; + if (oo.Contains("avg:")) doMax = kFALSE; + if (oo.Contains("max:")) doAvg = kFALSE; + + const char *dirn = (isX) ? "RunDataReadx" : "RunDataRead"; TDirectory *d = (TDirectory *) fout->Get(dirn); if (!d) { - ::Error("DrawDataSet", "could not find directory 'RunDataRead' ..."); + ::Error("DrawCPU", "could not find directory '%s' ...", dirn); fout->Close(); delete fout; return; } d->cd(); - TString hprofn, typ("QR_IO"); - if (type && !strcmp(type, "evts")) typ = "QR_Evts"; - - if (!strcmp(opt, "std:")) { - hprofn.Form("Prof_DataRead_%s", typ.Data()); - } else if (!strcmp(opt, "stdx:")) { - hprofn.Form("Prof_x_DataRead_%s", typ.Data()); - } else if (!strcmp(opt, "norm:")) { - hprofn.Form("Norm_DataRead_%s", typ.Data()); - } else if (!strcmp(opt, "absx:")) { - hprofn.Form("Norm_x_DataRead_%s", typ.Data()); + TString hprofn, hmaxn; + const char *lx = (isX) ? "_x" : ""; + const char *ln = (isNorm) ? "Norm" : "Prof"; + Bool_t isIO = kTRUE; + if (type && !strcmp(type, "evts")) { + hprofn.Form("%s%s_DataRead_QR_Evts", ln, lx); + hmaxn.Form("%s%s_DataRead_PS_MaxEvts", ln, lx); + isIO = kFALSE; } else { - ::Error("DrawDataSet", "unknown option '%s'", opt); - fout->Close(); - delete fout; + hprofn.Form("%s%s_DataRead_QR_IO", ln, lx); + hmaxn.Form("%s%s_DataRead_PS_MaxIO", ln, lx); + } + + Double_t xmin = -1., xmax = -1.; + Double_t ami = -1., amx = -1., mmi = -1., mmx = -1.; + Int_t kamx = -1, kmmx = -1, nbins = -1; + Double_t ymx = -1., ymi = -1.; + + TProfile *pfav = 0; + TGraphErrors *grav = 0; + if (doAvg) { + if (!(grav = GetGraph(d, hprofn, nbins, xmin, xmax, ami, amx, kamx, pfav))) { + ::Error("DrawCPU", "could not find '%s' ...", hprofn.Data()); + fout->Close(); + delete fout; + return; + } + ymx = amx; + ymi = ami; + } + TProfile *pfmx = 0; + TGraphErrors *grmx = 0; + if (doMax) { + if (!(grmx = GetGraph(d, hmaxn, nbins, xmin, xmax, mmi, mmx, kmmx, pfmx))) { + ::Warning("DrawCPU", "could not find '%s': feature added in 5.34/11", hmaxn.Data()); + if (!grav) { + // Nothing to do if not asked for the average + fout->Close(); + delete fout; + return; + } + doMax = kFALSE; + } + if (mmx > ymx) ymx = mmx; + if ((ymi > 0 && mmi < ymi) || (ymi < 0.)) ymi = mmi; + } + + TProfile *pf = (doMax) ? pfmx : pfav; + Int_t kmx = (doMax) ? kmmx : kamx; + + // Create the canvas + TCanvas *cpu = new TCanvas("dataset", "Rate vs wrks",204,69,1050,502); + cpu->Range(-3.106332,0.7490716,28.1362,1.249867); + + TH1F *hgr = new TH1F("Graph-DataSet"," Data Read speed-up", nbins*4, xmin, xmax); + hgr->SetMaximum(ymx + (ymx-ymi)*0.2); + hgr->SetMinimum(0); + if (isNorm) hgr->SetMaximum(ymx*1.2); + hgr->SetDirectory(0); + hgr->SetStats(0); + hgr->GetXaxis()->SetTitle(pf->GetXaxis()->GetTitle()); + hgr->GetXaxis()->CenterTitle(true); + hgr->GetXaxis()->SetLabelSize(0.05); + hgr->GetXaxis()->SetTitleSize(0.06); + hgr->GetXaxis()->SetTitleOffset(0.62); + hgr->GetYaxis()->SetLabelSize(0.06); + hgr->GetYaxis()->SetTitleSize(0.08); + hgr->GetYaxis()->SetTitleOffset(0.52); + if (isIO) { + hgr->GetYaxis()->SetTitle("Rate (MB/s)"); + } else { + hgr->GetYaxis()->SetTitle("Rate (events/s)"); + } + + TLegend *leg = 0; + if (isNorm) { + leg = new TLegend(0.7, 0.8, 0.9, 0.9); + } else { + leg = new TLegend(0.1, 0.8, 0.3, 0.9); + } + + if (doAvg) { + grav->SetFillColor(1); + grav->SetLineColor(13); + grav->SetMarkerColor(4); + grav->SetMarkerStyle(21); + grav->SetMarkerSize(1.2); + grav->SetHistogram(hgr); + + if (verbose) grav->Print(); + grav->Draw("alp"); + leg->AddEntry(grav, "Average", "P"); + } + if (doMax) { + grmx->SetFillColor(1); + grmx->SetLineColor(13); + grmx->SetMarkerColor(2); + grmx->SetMarkerStyle(29); + grmx->SetMarkerSize(1.8); + grmx->SetHistogram(hgr); + + if (verbose) grmx->Print(); + if (doAvg) { + grmx->Draw("lpSAME"); + } else { + grmx->Draw("alp"); + } + leg->AddEntry(grmx, "Maximum", "P"); + } + leg->Draw(); + gPad->Update(); + + Double_t normrate = -1.; + if (dofit > 0) { + TGraphErrors *gr = (doMax) ? grmx : grav; + // Make sure the fitting functions are defined + Double_t xmi = 0.9; + if (nbins > 5) xmi = 1.5; + AssertFittingFun(xmi, nbins + .1); + + if (dofit == 1) { + // Starting point for the parameters and fit + fgFio->SetParameter(0, pf->GetBinContent(1)); + fgFio->SetParameter(1, pf->GetBinContent(nbins-1)); + fgFio->SetParameter(2, pf->GetBinContent(nbins-1)); + gr->Fit(fgFio); + if (verbose) fgFio->Print(); + normrate = fgFio->Derivative(1.); + } else if (dofit > 1) { + // Starting point for the parameters and fit + gFioVn0 = (n0 > 0) ? n0 : (Int_t) (nbins + .1)/2.; + gFioVn1 = (n1 > 0) ? n1 : (Int_t) (nbins + .1); + fgFioV->SetParameter(0, 20.); + fgFioV->SetParameter(1, pf->GetBinContent(1)); + fgFioV->SetParameter(2, pf->GetBinContent(1)); + fgFioV->SetParameter(3, 4.); + fgFioV->SetParameter(4, 1000.); + + gr->Fit(fgFioV); + if (verbose) fgFio->Print(); + normrate = fgFioV->Derivative(1.); + } + } + + // Notify the cluster performance parameters + if (!isNorm) { + printf("* ************************************************************ *\n"); + printf("* *\r"); + printf("* Cluster: %s\n", description.Data()); + printf("* Performance measurement from scalability plot: *\n"); + printf("* *\r"); + if (isIO) { + printf("* rate max: %.3f\tMB/s (@ %d workers)\n", ymx, kmx); + printf("* *\r"); + printf("* per-worker rate: %.3f\tMB/s \n", normrate); + } else { + printf("* rate max: %.3f\tevts/s (@ %d workers)\n", ymx, kmx); + } + printf("* ************************************************************ *\n"); + } + // Close the file + fout->Close(); + if (grav) fgGraphs->Add(grav); + if (grmx) fgGraphs->Add(grmx); +} + +//______________________________________________________________________________ +void TProofBench::DrawEfficiency(const char *outfile, + const char *opt, Bool_t verbose) +{ + // Draw the efficiency plot. + // opt = 'cpu' or 'data' (default the first found) + // + + // Get the TProfile an create the graphs + TFile *fout = TFile::Open(outfile, "READ"); + if (!fout || (fout && fout->IsZombie())) { + ::Error("DrawEfficiency", "could not open file '%s' ...", outfile); return; } - TProfile *pf = 0; - TList *keylist = d->GetListOfKeys(); - TKey *key = 0; - TIter nxk(keylist); - while ((key = (TKey *) nxk())) { - if (TString(key->GetName()).BeginsWith(hprofn)) { - pf = (TProfile *) d->Get(key->GetName()); + + // Get description + TString description("<not available>"); + TNamed *nmdesc = (TNamed *) fout->Get("PB_description"); + if (nmdesc) description = nmdesc->GetTitle(); + + // Parse option + TString oo(opt), ln("CPU"); + const char *dirs[4] = { "RunCPU", "RunCPUx", "RunDataRead", "RunDataReadx"}; + const char *labs[4] = { "CPU", "CPU", "DataRead", "DataRead"}; + Int_t fst = 0, lst = 3; + if (oo == "cpu") { + lst = 0; + } else if (oo == "cpux") { + fst = 1; + lst = 1; + } else if (oo.BeginsWith("data")) { + if (oo.EndsWith("x")) { + fst = 3; + lst = 3; + } else { + fst = 2; + lst = 2; + } + } + const char *dirn = 0; + TDirectory *d = 0; + for (Int_t i = fst; i <= lst; i++) { + if ((d = (TDirectory *) fout->Get(dirs[i]))) { + dirn = dirs[i]; + ln = labs[i]; break; } } - if (!pf) { - ::Error("DrawDataSet", "could not find '%s' ...", hprofn.Data()); + if (!d && !dirn) { + ::Error("DrawEfficiency", "could not find directory ..."); fout->Close(); delete fout; return; } - Int_t nbins = pf->GetNbinsX(); - TGraphErrors *gr = new TGraphErrors(nbins); - Double_t xx, ex, yy, ey, ymi = pf->GetBinContent(1), ymx = ymi; - Int_t k =1; - for (;k <= nbins; k++) { - xx = pf->GetBinCenter(k); - ex = pf->GetBinWidth(k) * .001; - yy = pf->GetBinContent(k); - ey = pf->GetBinError(k); - if (k == 1) { - ymi = yy; - ymx = yy; - } else { - if (yy < ymi) ymi = yy; - if (yy > ymx) ymx = yy; - } - gr->SetPoint(k-1, xx, yy); - gr->SetPointError(k-1, ex, ey); - Printf("%d %f %f", (Int_t)xx, yy, ey); + d->cd(); + + TString hprof; + hprof.Form("Prof_%s_CPU_eff", ln.Data()); + + Double_t xmin = -1., xmax = -1.; + Int_t kmx = -1, nbins = -1; + Double_t ymx = -1., ymi = -1.; + + TProfile *pf = 0; + TGraphErrors *gr = 0; + if (!(gr = GetGraph(d, hprof, nbins, xmin, xmax, ymi, ymx, kmx, pf))) { + ::Error("DrawEfficiency", "could not find '%s' ...", hprof.Data()); + fout->Close(); + delete fout; + return; } // Create the canvas - TCanvas *cpu = new TCanvas("dataset", "Rate vs wrks",204,69,1050,502); + TCanvas *cpu = new TCanvas("efficiency", "efficiency vs wrks",204,69,1050,502); cpu->Range(-3.106332,0.7490716,28.1362,1.249867); - gStyle->SetOptTitle(0); - gr->SetFillColor(1); - gr->SetLineColor(13); - gr->SetMarkerStyle(21); - gr->SetMarkerSize(1.2); - - TH1F *hgr = new TH1F("Graph-DataSet"," Data Read speed-up", nbins*4,0,nbins+1); - hgr->SetMaximum(ymx + (ymx-ymi)*0.2); + TH1F *hgr = new TH1F("Graph-Efficiency","CPU effectiveness", nbins*4, xmin, xmax); + hgr->SetMaximum(1.2); hgr->SetMinimum(0); hgr->SetDirectory(0); hgr->SetStats(0); -// hgr->CenterTitle(true); hgr->GetXaxis()->SetTitle(pf->GetXaxis()->GetTitle()); hgr->GetXaxis()->CenterTitle(true); hgr->GetXaxis()->SetLabelSize(0.05); hgr->GetXaxis()->SetTitleSize(0.06); hgr->GetXaxis()->SetTitleOffset(0.62); hgr->GetYaxis()->SetLabelSize(0.06); + hgr->GetYaxis()->SetTitleSize(0.08); + hgr->GetYaxis()->SetTitleOffset(0.52); + hgr->GetYaxis()->SetTitle("CPU effectiveness"); + + gr->SetFillColor(1); + gr->SetLineColor(13); + gr->SetMarkerColor(4); + gr->SetMarkerStyle(21); + gr->SetMarkerSize(1.2); gr->SetHistogram(hgr); if (verbose) gr->Print(); - gr->Draw("alp"); - + + // Notify the cluster performance parameters + printf("* ************************************************************ *\n"); + printf("* *\r"); + printf("* Cluster: %s\n", description.Data()); + printf("* CPU effectiveness measurement: *\n"); + printf("* *\r"); + printf("* effectiveness max: %.3f (@ %d workers)\n", ymx, kmx); + printf("* *\r"); + printf("* ************************************************************ *\n"); + // Close the file fout->Close(); + if (gr) fgGraphs->Add(gr); } //______________________________________________________________________________ diff --git a/proof/proofbench/src/TProofBenchRunCPU.cxx b/proof/proofbench/src/TProofBenchRunCPU.cxx index 47a2b21742802..6a9062e2ba63f 100644 --- a/proof/proofbench/src/TProofBenchRunCPU.cxx +++ b/proof/proofbench/src/TProofBenchRunCPU.cxx @@ -22,6 +22,7 @@ #include "TProofBenchRunCPU.h" #include "TProofNodes.h" +#include "TProofPerfAnalysis.h" #include "TFileCollection.h" #include "TFileInfo.h" #include "TProof.h" @@ -45,6 +46,7 @@ #include "TStyle.h" #include "TProofNodes.h" #include "TGraphErrors.h" +#include "TLegend.h" ClassImp(TProofBenchRunCPU) @@ -60,7 +62,9 @@ TProofBenchRunCPU::TProofBenchRunCPU(TPBHistType *histtype, Int_t nhists, fStep(step), fDraw(draw), fDebug(debug), fDirProofBench(dirproofbench), fNodes(nodes), fListPerfPlots(0), fCanvas(0), fProfile_perfstat_event(0), fHist_perfstat_event(0), - fProfile_queryresult_event(0), fNorm_queryresult_event(0), fName(0) + fProfile_perfstat_evtmax(0), fNorm_perfstat_evtmax(0), + fProfile_queryresult_event(0), fNorm_queryresult_event(0), fProfile_cpu_eff(0), + fProfLegend(0), fNormLegend(0), fName(0) { // Default constructor @@ -90,6 +94,8 @@ TProofBenchRunCPU::~TProofBenchRunCPU() SafeDelete(fListPerfPlots); SafeDelete(fCanvas); SafeDelete(fNodes); + SafeDelete(fProfLegend); + SafeDelete(fNormLegend); } //______________________________________________________________________________ @@ -103,6 +109,9 @@ void TProofBenchRunCPU::BuildHistos(Int_t start, Int_t stop, Int_t step, Bool_t Double_t ns_min = start - step/2.; Double_t ns_max = quotient*step + start + step/2.; + fProfLegend = new TLegend(0.1, 0.8, 0.3, 0.9); + fNormLegend = new TLegend(0.7, 0.8, 0.9, 0.9); + TString axtitle("Active Workers"), namelab(GetName()), sellab(GetSelName()); if (nx) { axtitle = "Active Workers/Node"; @@ -112,6 +121,23 @@ void TProofBenchRunCPU::BuildHistos(Int_t start, Int_t stop, Int_t step, Bool_t sellab.Form("%s_%s", GetSelName(), GetNameStem().Data()); TString name, title; + + // Book perfstat profile (max evts) + name.Form("Prof_%s_PS_MaxEvts_%s", namelab.Data(), sellab.Data()); + title.Form("Profile %s PerfStat Event - %s", namelab.Data(), sellab.Data()); + fProfile_perfstat_evtmax = new TProfile(name, title, ndiv, ns_min, ns_max); + fProfile_perfstat_evtmax->SetDirectory(fDirProofBench); + fProfile_perfstat_evtmax->GetYaxis()->SetTitle("Events/sec"); + fProfile_perfstat_evtmax->GetXaxis()->SetTitle(axtitle); + fProfile_perfstat_evtmax->SetMarkerStyle(23); + fProfile_perfstat_evtmax->SetMarkerColor(2); + if ((o = fListPerfPlots->FindObject(name))) { + fListPerfPlots->Remove(o); + delete o; + } + fListPerfPlots->Add(fProfile_perfstat_evtmax); + fProfLegend->AddEntry(fProfile_perfstat_evtmax, "Maximum"); + // Book perfstat profile name.Form("Prof_%s_PS_Evts_%s", namelab.Data(), sellab.Data()); title.Form("Profile %s PerfStat Event - %s", namelab.Data(), sellab.Data()); @@ -125,6 +151,7 @@ void TProofBenchRunCPU::BuildHistos(Int_t start, Int_t stop, Int_t step, Bool_t delete o; } fListPerfPlots->Add(fProfile_perfstat_event); + fProfLegend->AddEntry(fProfile_perfstat_event, "Average"); // Book perfstat histogram name.Form("Hist_%s_PS_Evts_%s", namelab.Data(), sellab.Data()); @@ -140,6 +167,22 @@ void TProofBenchRunCPU::BuildHistos(Int_t start, Int_t stop, Int_t step, Bool_t } fListPerfPlots->Add(fHist_perfstat_event); + // Book normalized perfstat profile (max evts) + name.Form("Norm_%s_PS_MaxEvts_%s", namelab.Data(), sellab.Data()); + title.Form("Profile %s Normalized PerfStat Event - %s", namelab.Data(), sellab.Data()); + fNorm_perfstat_evtmax = new TProfile(name, title, ndiv, ns_min, ns_max); + fNorm_perfstat_evtmax->SetDirectory(fDirProofBench); + fNorm_perfstat_evtmax->GetYaxis()->SetTitle("Events/sec"); + fNorm_perfstat_evtmax->GetXaxis()->SetTitle(axtitle); + fNorm_perfstat_evtmax->SetMarkerStyle(23); + fNorm_perfstat_evtmax->SetMarkerColor(2); + if ((o = fListPerfPlots->FindObject(name))) { + fListPerfPlots->Remove(o); + delete o; + } + fListPerfPlots->Add(fNorm_perfstat_evtmax); + fNormLegend->AddEntry(fNorm_perfstat_evtmax, "Maximum"); + // Book queryresult profile name.Form("Prof_%s_QR_Evts_%s", namelab.Data(), sellab.Data()); title.Form("Profile %s QueryResult Event - %s", namelab.Data(), sellab.Data()); @@ -167,6 +210,21 @@ void TProofBenchRunCPU::BuildHistos(Int_t start, Int_t stop, Int_t step, Bool_t delete o; } fListPerfPlots->Add(fNorm_queryresult_event); + fNormLegend->AddEntry(fNorm_queryresult_event, "Average"); + + // Book CPU efficiency profile + name.Form("Prof_%s_CPU_eff_%s", namelab.Data(), sellab.Data()); + title.Form("Profile %s CPU efficiency - %s", namelab.Data(), sellab.Data()); + fProfile_cpu_eff = new TProfile(name, title, ndiv, ns_min, ns_max); + fProfile_cpu_eff->SetDirectory(fDirProofBench); + fProfile_cpu_eff->GetYaxis()->SetTitle("Efficiency"); + fProfile_cpu_eff->GetXaxis()->SetTitle(axtitle); + fProfile_cpu_eff->SetMarkerStyle(22); + if ((o = fListPerfPlots->FindObject(name))) { + fListPerfPlots->Remove(o); + delete o; + } + fListPerfPlots->Add(fProfile_cpu_eff); } //______________________________________________________________________________ @@ -285,10 +343,14 @@ void TProofBenchRunCPU::Run(Long64_t nevents, Int_t start, Int_t stop, Int_t npad = 1; //pad number Int_t nnodes = fNodes->GetNNodes(); // Number of machines + Int_t ncores = fNodes->GetNCores(); // Number of cores - Double_t ymi = -1., ymx = -1.; + Double_t ymi = -1., ymx = -1., emx = -1.; for (Int_t nactive = start; nactive <= stop; nactive += step) { + // For CPU effectiveness (ok for lite; should do it properly for standard clusters) + Int_t ncoren = (nactive < ncores) ? nactive : ncores; + // Actvate the wanted workers Int_t nw = -1; if (nx) { @@ -335,6 +397,38 @@ void TProofBenchRunCPU::Run(Long64_t nevents, Int_t start, Int_t stop, //FillPerfStatPerfPlots(t, profile_perfstat_event, nactive); FillPerfStatPerfPlots(t, nactive); + TProofPerfAnalysis pfa(t); + Double_t pf_eventrate = pfa.GetEvtRateAvgMax(); +// if (pf_eventrate > emx) emx = pf_eventrate; + fProfile_perfstat_evtmax->Fill(nactive, pf_eventrate); + fCanvas->cd(npad); + fProfile_perfstat_evtmax->SetMaximum(emx*1.6); + fProfile_perfstat_evtmax->SetMinimum(0.); + fProfile_perfstat_evtmax->Draw("L"); + fProfLegend->Draw(); + gPad->Update(); + // The normalised histos + // Use the first bin to set the Y range for the histo + Double_t nert = nx ? pf_eventrate/nactive/nnodes : pf_eventrate/nactive; + fNorm_perfstat_evtmax->Fill(nactive, nert); + Double_t y1 = fNorm_perfstat_evtmax->GetBinContent(1); + Double_t e1 = fNorm_perfstat_evtmax->GetBinError(1); + Double_t dy = 5 * e1; + if (dy / y1 < 0.2) dy = y1 * 0.2; + if (dy > y1) dy = y1*.999999; + if (ymi < 0.) ymi = y1 - dy; + if (fNorm_perfstat_evtmax->GetBinContent(nactive) < ymi) + ymi = fNorm_perfstat_evtmax->GetBinContent(nactive) / 2.; + if (ymx < 0.) ymx = y1 + dy; + if (fNorm_perfstat_evtmax->GetBinContent(nactive) > ymx) + ymx = fNorm_perfstat_evtmax->GetBinContent(nactive) * 1.5; + fNorm_perfstat_evtmax->SetMaximum(ymx); + fNorm_perfstat_evtmax->SetMinimum(ymi); + fCanvas->cd(npad + 1); + fNorm_perfstat_evtmax->Draw("L"); + fNormLegend->Draw(); + gPad->Update(); + // Build up new name TString newname = TString::Format("%s_%s_%dwrks%dthtry", t->GetName(), GetName(), nactive, j); t->SetName(newname); @@ -363,8 +457,10 @@ void TProofBenchRunCPU::Run(Long64_t nevents, Int_t start, Int_t stop, // Performance measures from TQueryResult + const char *drawopt = t ? "LSAME" : "L"; TQueryResult *queryresult = fProof->GetQueryResult(); if (queryresult) { + queryresult->Print("F"); TDatime qr_start = queryresult->GetStartTime(); TDatime qr_end = queryresult->GetEndTime(); Float_t qr_proc = queryresult->GetProcTime(); @@ -373,11 +469,21 @@ void TProofBenchRunCPU::Run(Long64_t nevents, Int_t start, Int_t stop, // Calculate event rate Double_t qr_eventrate = qr_entries / Double_t(qr_proc); + if (qr_eventrate > emx) emx = qr_eventrate; + + // Calculate and fill CPU efficiency + Float_t qr_cpu_eff = -1.; + if (qr_proc > 0.) { + qr_cpu_eff = queryresult->GetUsedCPU() / ncoren / qr_proc ; + fProfile_cpu_eff->Fill(nactive, qr_cpu_eff); + Printf("cpu_eff: %f", qr_cpu_eff); + } // Fill and draw fProfile_queryresult_event->Fill(nactive, qr_eventrate); fCanvas->cd(npad); - fProfile_queryresult_event->Draw(); + fProfile_queryresult_event->Draw(drawopt); + fProfLegend->Draw(); gPad->Update(); // The normalised histo Double_t nert = nx ? qr_eventrate/nactive/nnodes : qr_eventrate/nactive; @@ -395,9 +501,11 @@ void TProofBenchRunCPU::Run(Long64_t nevents, Int_t start, Int_t stop, if (fNorm_queryresult_event->GetBinContent(nactive) > ymx) ymx = fNorm_queryresult_event->GetBinContent(nactive) * 1.5; fNorm_queryresult_event->SetMaximum(ymx); - fNorm_queryresult_event->SetMinimum(ymi); +// fNorm_queryresult_event->SetMinimum(ymi); + fNorm_queryresult_event->SetMinimum(0.); fCanvas->cd(npad+1); - fNorm_queryresult_event->Draw(); + fNorm_queryresult_event->Draw(drawopt); + fNormLegend->Draw(); } else { Warning("Run", "TQueryResult not found!"); } @@ -408,9 +516,14 @@ void TProofBenchRunCPU::Run(Long64_t nevents, Int_t start, Int_t stop, // Make the result persistent fCanvas->cd(npad); - fProfile_queryresult_event->DrawCopy(); + fProfile_queryresult_event->SetMaximum(1.6*emx); + fProfile_queryresult_event->DrawCopy("L"); + fProfile_perfstat_evtmax->DrawCopy("LSAME"); + fProfLegend->Draw(); fCanvas->cd(npad + 1); - fNorm_queryresult_event->DrawCopy(); + fNorm_queryresult_event->DrawCopy("L"); + fNorm_perfstat_evtmax->DrawCopy("LSAME"); + fNormLegend->Draw(); gPad->Update(); //save performance profiles to file diff --git a/proof/proofbench/src/TProofBenchRunDataRead.cxx b/proof/proofbench/src/TProofBenchRunDataRead.cxx index c003c860cade0..4a3ec2428e449 100644 --- a/proof/proofbench/src/TProofBenchRunDataRead.cxx +++ b/proof/proofbench/src/TProofBenchRunDataRead.cxx @@ -25,6 +25,7 @@ #include "TProofBenchRunDataRead.h" #include "TProofBenchDataSet.h" +#include "TProofPerfAnalysis.h" #include "TProofNodes.h" #include "TFileCollection.h" #include "TFileInfo.h" @@ -48,6 +49,7 @@ #include "TQueryResult.h" #include "TMath.h" #include "TStyle.h" +#include "TLegend.h" #include "TROOT.h" ClassImp(TProofBenchRunDataRead) @@ -60,11 +62,16 @@ TProofBenchRunDataRead::TProofBenchRunDataRead(TProofBenchDataSet *pbds, TPBRead : TProofBenchRun(proof, kPROOF_BenchSelDataDef), fProof(proof), fReadType(readtype), fDS(pbds), fNEvents(nevents), fNTries(ntries), fStart(start), fStop(stop), fStep(step), - fDebug(debug), fFilesPerWrk(2), fDirProofBench(dirproofbench), fNodes(nodes), + fDebug(debug), fFilesPerWrk(2), fReleaseCache(kTRUE), + fDirProofBench(dirproofbench), fNodes(nodes), fListPerfPlots(0), fProfile_perfstat_event(0), fHist_perfstat_event(0), + fProfile_perfstat_evtmax(0), fNorm_perfstat_evtmax(0), fProfile_queryresult_event(0), fNorm_queryresult_event(0), - fProfile_perfstat_IO(0), fHist_perfstat_IO(0), fProfile_queryresult_IO(0), - fNorm_queryresult_IO(0), fCPerfProfiles(0), fName(0) + fProfile_perfstat_IO(0), fHist_perfstat_IO(0), + fProfile_perfstat_IOmax(0), + fProfile_queryresult_IO(0), fNorm_queryresult_IO(0), fProfile_cpu_eff(0), + fProfLegend_evt(0), fNormLegend_evt(0), fProfLegend_mb(0), fNormLegend_mb(0), + fCPerfProfiles(0), fName(0) { // Default constructor @@ -94,6 +101,10 @@ TProofBenchRunDataRead::~TProofBenchRunDataRead() fDirProofBench=0; SafeDelete(fListPerfPlots); if (fCPerfProfiles) delete fCPerfProfiles; + SafeDelete(fProfLegend_evt); + SafeDelete(fProfLegend_mb); + SafeDelete(fNormLegend_evt); + SafeDelete(fNormLegend_mb); } //______________________________________________________________________________ @@ -138,7 +149,6 @@ void TProofBenchRunDataRead::Run(const char *dset, Int_t start, Int_t stop, Bool_t nx = kFALSE; if (step == -2){ nx = kTRUE; - start = fStart; step = 1; } @@ -218,10 +228,15 @@ void TProofBenchRunDataRead::Run(const char *dset, Int_t start, Int_t stop, Int_t npad = 1; //pad number Int_t nnodes = fNodes->GetNNodes(); // Number of machines + Int_t ncores = fNodes->GetNCores(); // Number of cores - Double_t ymi = -1., ymx = -1., ymiio = -1., ymxio = -1.; + Bool_t drawpf = kFALSE; + Double_t ymi = -1., ymx = -1., emx =- 1, ymiio = -1., ymxio = -1., mbmx = -1.; for (Int_t nactive = start; nactive <= stop; nactive += step) { + // For CPU effectiveness (ok for lite; should do it properly for standard clusters) + Int_t ncoren = (nactive < ncores) ? nactive : ncores; + // Actvate the wanted workers Int_t nw = -1; if (nx) { @@ -262,7 +277,7 @@ void TProofBenchRunDataRead::Run(const char *dset, Int_t start, Int_t stop, // Cleanup run const char *dsnr = (fDS->IsProof(fProof)) ? dsn.Data() : dsname.Data(); - fDS->ReleaseCache(dsnr); + if (fReleaseCache) fDS->ReleaseCache(dsnr); DeleteParameters(); SetParameters(); @@ -284,10 +299,68 @@ void TProofBenchRunDataRead::Run(const char *dset, Int_t start, Int_t stop, TTree *t = 0; if (l) t = dynamic_cast<TTree*>(l->FindObject(perfstats_name.Data())); if (t) { + drawpf = kTRUE; TTree* tnew=(TTree*)t->Clone("tnew"); FillPerfStatProfiles(tnew, nactive); + TProofPerfAnalysis pfa(tnew); + Double_t pf_eventrate = pfa.GetEvtRateAvgMax(); + Double_t pf_IOrate = pfa.GetMBRateAvgMax(); + fProfile_perfstat_evtmax->Fill(nactive, pf_eventrate); + fCPerfProfiles->cd(npad); + fProfile_perfstat_evtmax->SetMaximum(1.6*emx); + fProfile_perfstat_evtmax->SetMinimum(0.); + fProfile_perfstat_evtmax->Draw(); + fProfLegend_evt->Draw(); + gPad->Update(); + fProfile_perfstat_IOmax->Fill(nactive, pf_IOrate); + fCPerfProfiles->cd(npad + 2); + fProfile_perfstat_IOmax->SetMaximum(1.6*mbmx); + fProfile_perfstat_IOmax->SetMinimum(0.); + fProfile_perfstat_IOmax->Draw(); + fProfLegend_mb->Draw(); + gPad->Update(); + // The normalised histos + // Use the first bin to set the Y range for the histo + Double_t nert = nx ? pf_eventrate/nactive/nnodes : pf_eventrate/nactive; + fNorm_perfstat_evtmax->Fill(nactive, nert); + Double_t y1 = fNorm_perfstat_evtmax->GetBinContent(1); + Double_t e1 = fNorm_perfstat_evtmax->GetBinError(1); + Double_t dy = 5 * e1; + if (dy / y1 < 0.2) dy = y1 * 0.2; + if (dy > y1) dy = y1*.999999; + if (ymi < 0.) ymi = y1 - dy; + if (fNorm_perfstat_evtmax->GetBinContent(nactive) < ymi) + ymi = fNorm_perfstat_evtmax->GetBinContent(nactive) / 2.; + if (ymx < 0.) ymx = y1 + dy; + if (fNorm_perfstat_evtmax->GetBinContent(nactive) > ymx) + ymx = fNorm_perfstat_evtmax->GetBinContent(nactive) * 1.5; + fNorm_perfstat_evtmax->SetMaximum(ymx); + fNorm_perfstat_evtmax->SetMinimum(ymi); + fCPerfProfiles->cd(npad + 1); + fNorm_perfstat_evtmax->Draw(); + gPad->Update(); + // + Double_t niort = nx ? pf_IOrate/nactive/nnodes : pf_IOrate/nactive; + fNorm_perfstat_IOmax->Fill(nactive, niort); + y1 = fNorm_perfstat_IOmax->GetBinContent(1); + e1 = fNorm_perfstat_IOmax->GetBinError(1); + dy = 5 * e1; + if (dy / y1 < 0.2) dy = y1 * 0.2; + if (dy > y1) dy = y1*.999999; + if (ymiio < 0.) ymiio = y1 - dy; + if (fNorm_perfstat_IOmax->GetBinContent(nactive) < ymiio) + ymiio = fNorm_perfstat_IOmax->GetBinContent(nactive) / 2.; + if (ymxio < 0.) ymxio = y1 + dy; + if (fNorm_perfstat_IOmax->GetBinContent(nactive) > ymxio) + ymxio = fNorm_perfstat_IOmax->GetBinContent(nactive) * 1.5; + fNorm_perfstat_IOmax->SetMaximum(ymxio); + fNorm_perfstat_IOmax->SetMinimum(ymiio); + fCPerfProfiles->cd(npad + 3); + fNorm_perfstat_IOmax->Draw(); + gPad->Update(); + //change the name TString newname = TString::Format("%s_%s_%dwrks%dthtry", t->GetName(), GetName(), nactive, j); tnew->SetName(newname); @@ -313,6 +386,8 @@ void TProofBenchRunDataRead::Run(const char *dset, Int_t start, Int_t stop, Error("Run", "PROOF output list is empty!"); } + // + const char *drawopt = t ? "SAME" : ""; // Performance measures from TQueryResult TQueryResult *queryresult = fProof->GetQueryResult(); if (queryresult) { @@ -323,15 +398,25 @@ void TProofBenchRunDataRead::Run(const char *dset, Int_t start, Int_t stop, Long64_t qr_entries = queryresult->GetEntries(); + // Calculate and fill CPU efficiency + Float_t qr_cpu_eff = -1.; + if (qr_proc > 0.) { + qr_cpu_eff = queryresult->GetUsedCPU() / ncoren / qr_proc ; + fProfile_cpu_eff->Fill(nactive, qr_cpu_eff); + Printf("cpu_eff: %f", qr_cpu_eff); + } + // Calculate event rate, fill and draw Double_t qr_eventrate=0; qr_eventrate = qr_entries / Double_t(qr_proc); + if (qr_eventrate > emx) emx = qr_eventrate; fProfile_queryresult_event->Fill(nactive, qr_eventrate); fCPerfProfiles->cd(npad); fProfile_queryresult_event->SetMinimum(0.); - fProfile_queryresult_event->Draw(); + fProfile_queryresult_event->Draw(drawopt); + fProfLegend_evt->Draw(); gPad->Update(); // Calculate IO rate, fill and draw @@ -340,11 +425,13 @@ void TProofBenchRunDataRead::Run(const char *dset, Int_t start, Int_t stop, const Double_t Dmegabytes = 1024*1024; qr_IOrate = qr_bytes / Dmegabytes / Double_t(qr_proc); + if (qr_IOrate > mbmx) mbmx = qr_IOrate; fProfile_queryresult_IO->Fill(nactive, qr_IOrate); fCPerfProfiles->cd(npad + 2); fProfile_queryresult_IO->SetMinimum(0.); - fProfile_queryresult_IO->Draw(); + fProfile_queryresult_IO->Draw(drawopt); + fProfLegend_mb->Draw(); gPad->Update(); // The normalised histos @@ -362,10 +449,11 @@ void TProofBenchRunDataRead::Run(const char *dset, Int_t start, Int_t stop, if (ymx < 0.) ymx = y1 + dy; if (fNorm_queryresult_event->GetBinContent(nactive) > ymx) ymx = fNorm_queryresult_event->GetBinContent(nactive) * 1.5; - fNorm_queryresult_event->SetMaximum(ymx); +// fNorm_queryresult_event->SetMaximum(ymx); fNorm_queryresult_event->SetMinimum(ymi); fCPerfProfiles->cd(npad + 1); - fNorm_queryresult_event->Draw(); + fNorm_queryresult_event->Draw(drawopt); + fNormLegend_evt->Draw(); gPad->Update(); // Double_t niort = nx ? qr_IOrate/nactive/nnodes : qr_IOrate/nactive; @@ -381,10 +469,11 @@ void TProofBenchRunDataRead::Run(const char *dset, Int_t start, Int_t stop, if (ymxio < 0.) ymxio = y1 + dy; if (fNorm_queryresult_IO->GetBinContent(nactive) > ymxio) ymxio = fNorm_queryresult_IO->GetBinContent(nactive) * 1.5; - fNorm_queryresult_IO->SetMaximum(ymxio); +// fNorm_queryresult_IO->SetMaximum(ymxio); fNorm_queryresult_IO->SetMinimum(ymiio); fCPerfProfiles->cd(npad + 3); - fNorm_queryresult_IO->Draw(); + fNorm_queryresult_IO->Draw(drawopt); + fNormLegend_mb->Draw(); gPad->Update(); } fCPerfProfiles->cd(0); @@ -396,13 +485,23 @@ void TProofBenchRunDataRead::Run(const char *dset, Int_t start, Int_t stop, // Make the result persistent fCPerfProfiles->cd(npad); + fProfile_queryresult_event->SetMaximum(1.6*emx); fProfile_queryresult_event->DrawCopy(); + if (drawpf) fProfile_perfstat_evtmax->DrawCopy("SAME"); + fProfLegend_evt->Draw(); fCPerfProfiles->cd(npad + 2); + fProfile_queryresult_IO->SetMaximum(1.6*mbmx); fProfile_queryresult_IO->DrawCopy(); + if (drawpf) fProfile_perfstat_IOmax->DrawCopy("SAME"); + fProfLegend_mb->Draw(); fCPerfProfiles->cd(npad + 1); fNorm_queryresult_event->DrawCopy(); + if (drawpf) fNorm_perfstat_evtmax->DrawCopy("SAME"); + fNormLegend_evt->Draw(); fCPerfProfiles->cd(npad + 3); fNorm_queryresult_IO->DrawCopy(); + if (drawpf) fNorm_perfstat_IOmax->DrawCopy("SAME"); + fProfLegend_mb->Draw(); gPad->Update(); //save performance profiles to file @@ -664,7 +763,7 @@ Int_t TProofBenchRunDataRead::SetParameters() if (!fReadType) fReadType = new TPBReadType(TPBReadType::kReadOpt); fProof->AddInput(fReadType); fProof->SetParameter("PROOF_BenchmarkDebug", Int_t(fDebug)); - // Fo Mac Os X only: do not OS cache the files read + // For Mac Os X only: do not OS cache the files read fProof->SetParameter("PROOF_DontCacheFiles", Int_t(1)); return 0; } @@ -696,6 +795,11 @@ void TProofBenchRunDataRead::BuildHistos(Int_t start, Int_t stop, Int_t step, Bo Double_t ns_min = start - step/2.; Double_t ns_max = quotient*step + start + step/2.; + fProfLegend_evt = new TLegend(0.1, 0.8, 0.3, 0.9); + fNormLegend_evt = new TLegend(0.7, 0.8, 0.9, 0.9); + fProfLegend_mb = new TLegend(0.1, 0.8, 0.3, 0.9); + fNormLegend_mb = new TLegend(0.7, 0.8, 0.9, 0.9); + TString axtitle("Active Workers"), namelab(GetName()), sellab(GetSelName()); if (nx) { axtitle = "Active Workers/Node"; @@ -705,6 +809,23 @@ void TProofBenchRunDataRead::BuildHistos(Int_t start, Int_t stop, Int_t step, Bo sellab.Form("%s_%s", GetSelName(), GetNameStem().Data()); TString name, title; + + // Book perfstat profile (max evts) + name.Form("Prof_%s_PS_MaxEvts_%s", namelab.Data(), sellab.Data()); + title.Form("Profile %s PerfStat Event- %s", namelab.Data(), sellab.Data()); + fProfile_perfstat_evtmax = new TProfile(name, title, ndiv, ns_min, ns_max); + fProfile_perfstat_evtmax->SetDirectory(fDirProofBench); + fProfile_perfstat_evtmax->GetYaxis()->SetTitle("Events/sec"); + fProfile_perfstat_evtmax->GetXaxis()->SetTitle(axtitle); + fProfile_perfstat_evtmax->SetMarkerStyle(23); + fProfile_perfstat_evtmax->SetMarkerStyle(2); + if ((o = fListPerfPlots->FindObject(name))) { + fListPerfPlots->Remove(o); + delete o; + } + fListPerfPlots->Add(fProfile_perfstat_evtmax); + fProfLegend_evt->AddEntry(fProfile_perfstat_evtmax, "Maximum"); + // Book perfstat profile (evts) name.Form("Prof_%s_PS_Evts_%s", namelab.Data(), sellab.Data()); title.Form("Profile %s PerfStat Event - %s", namelab.Data(), sellab.Data()); @@ -733,6 +854,22 @@ void TProofBenchRunDataRead::BuildHistos(Int_t start, Int_t stop, Int_t step, Bo } fListPerfPlots->Add(fHist_perfstat_event); + // Book normalized perfstat profile (max evts) + name.Form("Norm_%s_PF_MaxEvts_%s", namelab.Data(), sellab.Data()); + title.Form("Profile %s Normalized QueryResult Event - %s", namelab.Data(), sellab.Data()); + fNorm_perfstat_evtmax = new TProfile(name, title, ndiv, ns_min, ns_max); + fNorm_perfstat_evtmax->SetDirectory(fDirProofBench); + fNorm_perfstat_evtmax->GetYaxis()->SetTitle("Events/sec"); + fNorm_perfstat_evtmax->GetXaxis()->SetTitle(axtitle); + fNorm_perfstat_evtmax->SetMarkerStyle(23); + fNorm_perfstat_evtmax->SetMarkerColor(2); + if ((o = fListPerfPlots->FindObject(name))) { + fListPerfPlots->Remove(o); + delete o; + } + fListPerfPlots->Add(fNorm_perfstat_evtmax); + fNormLegend_evt->AddEntry(fNorm_perfstat_evtmax, "Maximum"); + // Book queryresult profile (evts) name.Form("Prof_%s_QR_Evts_%s", namelab.Data(), sellab.Data()); title.Form("Profile %s QueryResult Event - %s", namelab.Data(), sellab.Data()); @@ -746,6 +883,7 @@ void TProofBenchRunDataRead::BuildHistos(Int_t start, Int_t stop, Int_t step, Bo delete o; } fListPerfPlots->Add(fProfile_queryresult_event); + fProfLegend_evt->AddEntry(fProfile_queryresult_event, "Average"); // Book normalized queryresult profile (evts) name.Form("Norm_%s_QR_Evts_%s", namelab.Data(), sellab.Data()); @@ -760,6 +898,7 @@ void TProofBenchRunDataRead::BuildHistos(Int_t start, Int_t stop, Int_t step, Bo delete o; } fListPerfPlots->Add(fNorm_queryresult_event); + fNormLegend_evt->AddEntry(fNorm_queryresult_event, "Average"); // Book perfstat profile (mbs) name.Form("Prof_%s_PS_IO_%s", namelab.Data(), sellab.Data()); @@ -789,6 +928,38 @@ void TProofBenchRunDataRead::BuildHistos(Int_t start, Int_t stop, Int_t step, Bo } fListPerfPlots->Add(fHist_perfstat_IO); + // Book perfstat profile (max mbs) + name.Form("Prof_%s_PS_MaxIO_%s", namelab.Data(), sellab.Data()); + title.Form("Profile %s PerfStat I/O - %s", namelab.Data(), sellab.Data()); + fProfile_perfstat_IOmax = new TProfile(name, title, ndiv, ns_min, ns_max); + fProfile_perfstat_IOmax->SetDirectory(fDirProofBench); + fProfile_perfstat_IOmax->GetYaxis()->SetTitle("MB/sec"); + fProfile_perfstat_IOmax->GetXaxis()->SetTitle(axtitle); + fProfile_perfstat_IOmax->SetMarkerStyle(21); + fProfile_perfstat_IOmax->SetMarkerColor(2); + if ((o = fListPerfPlots->FindObject(name))) { + fListPerfPlots->Remove(o); + delete o; + } + fListPerfPlots->Add(fProfile_perfstat_IOmax); + fProfLegend_mb->AddEntry(fProfile_perfstat_IOmax, "Maximum"); + + // Book normalized perfstat profile (max mbs) + name.Form("Norm_%s_PS_MaxIO_%s", namelab.Data(), sellab.Data()); + title.Form("Profile %s Normalized PerfStat I/O - %s", namelab.Data(), sellab.Data()); + fNorm_perfstat_IOmax = new TProfile(name, title, ndiv, ns_min, ns_max); + fNorm_perfstat_IOmax->SetDirectory(fDirProofBench); + fNorm_perfstat_IOmax->GetYaxis()->SetTitle("MB/sec"); + fNorm_perfstat_IOmax->GetXaxis()->SetTitle(axtitle); + fNorm_perfstat_IOmax->SetMarkerStyle(23); + fNorm_perfstat_IOmax->SetMarkerColor(2); + if ((o = fListPerfPlots->FindObject(name))) { + fListPerfPlots->Remove(o); + delete o; + } + fListPerfPlots->Add(fNorm_perfstat_IOmax); + fNormLegend_mb->AddEntry(fNorm_perfstat_IOmax, "Maximum"); + // Book queryresult profile (mbs) name.Form("Prof_%s_QR_IO_%s", namelab.Data(), sellab.Data()); title.Form("Profile %s QueryResult I/O - %s", namelab.Data(), sellab.Data()); @@ -802,6 +973,7 @@ void TProofBenchRunDataRead::BuildHistos(Int_t start, Int_t stop, Int_t step, Bo delete o; } fListPerfPlots->Add(fProfile_queryresult_IO); + fProfLegend_mb->AddEntry(fProfile_queryresult_IO, "Average"); // Book normalized queryresult profile (mbs) name.Form("Norm_%s_QR_IO_%s", namelab.Data(), sellab.Data()); @@ -816,4 +988,19 @@ void TProofBenchRunDataRead::BuildHistos(Int_t start, Int_t stop, Int_t step, Bo delete o; } fListPerfPlots->Add(fNorm_queryresult_IO); + fNormLegend_mb->AddEntry(fNorm_queryresult_IO, "Average"); + + // Book CPU efficiency profile + name.Form("Prof_%s_CPU_eff_%s", namelab.Data(), sellab.Data()); + title.Form("Profile %s CPU efficiency - %s", namelab.Data(), sellab.Data()); + fProfile_cpu_eff = new TProfile(name, title, ndiv, ns_min, ns_max); + fProfile_cpu_eff->SetDirectory(fDirProofBench); + fProfile_cpu_eff->GetYaxis()->SetTitle("Efficiency"); + fProfile_cpu_eff->GetXaxis()->SetTitle(axtitle); + fProfile_cpu_eff->SetMarkerStyle(22); + if ((o = fListPerfPlots->FindObject(name))) { + fListPerfPlots->Remove(o); + delete o; + } + fListPerfPlots->Add(fProfile_cpu_eff); } diff --git a/proof/proofbench/src/TProofNodes.cxx b/proof/proofbench/src/TProofNodes.cxx index 41739c537ee06..fd1b13df64407 100644 --- a/proof/proofbench/src/TProofNodes.cxx +++ b/proof/proofbench/src/TProofNodes.cxx @@ -29,7 +29,7 @@ ClassImp(TProofNodes) TProofNodes::TProofNodes(TProof* proof) : fProof(proof), fNodes(0), fActiveNodes(0), fMaxWrksNode(-1), fMinWrksNode(-1), - fNNodes(0), fNWrks(0), fNActiveWrks(0) + fNNodes(0), fNWrks(0), fNActiveWrks(0), fNCores(0) { // Constructor @@ -105,6 +105,10 @@ void TProofNodes::Build() node = dynamic_cast<TList *>(fNodes->GetValue(key)); if (node) { fNNodes++; + // Number of cores + si = (TSlaveInfo *) node->First(); + fNCores += si->fSysInfo.fCpus; + // Number of workers fNWrks += node->GetSize(); if (fMinWrksNode == -1 || (node->GetSize() < fMinWrksNode)) { fMinWrksNode = node->GetSize(); diff --git a/proof/proofbench/src/TProofPerfAnalysis.cxx b/proof/proofbench/src/TProofPerfAnalysis.cxx index daaa11e9b0ffe..ad3b4e51d455c 100644 --- a/proof/proofbench/src/TProofPerfAnalysis.cxx +++ b/proof/proofbench/src/TProofPerfAnalysis.cxx @@ -33,9 +33,10 @@ #include "TStyle.h" #include "TSystem.h" #include "TTree.h" +#include "TMath.h" // -// Auxilliary internal class +// Auxilliary internal classes //_______________________________________________________________________ class TProofPerfAnalysis::TWrkInfo : public TNamed { public: @@ -92,14 +93,132 @@ class TProofPerfAnalysis::TWrkInfo : public TNamed { return 1; } }; -Int_t TProofPerfAnalysis::fgDebug = 0; + +class TProofPerfAnalysis::TPackInfo : public TNamed { +public: + TPackInfo(const char *ord, const char *host) : TNamed(ord, host), fStart(0), fStop(-1), fSize(0), fMBRate(0.) { } + TPackInfo(const char *ord, const char *host, Float_t start, Float_t stop, Long64_t sz, Double_t mbr) + : TNamed(ord, host), fStart(start), fStop(stop), fSize(sz), fMBRate(mbr) { } + Float_t fStart; // When the packet has been assigned + Float_t fStop; // When the packet has been finished + Long64_t fSize; // Packet size + Double_t fMBRate; // Processing rate MB/s + void Print(Option_t *opt= "") const { + if (!strcmp(opt, "S")) { + Printf(" \t%10lld evts, \t%12.2f MB/s, \t%12.3f -> %12.3f s", fSize, fMBRate, fStart, fStop); + } else { + Printf(" %s:\t%s \t%10lld evts, \t%12.2f MB/s, \t%12.3f -> %12.3f s", GetTitle(), GetName(), fSize, fMBRate, fStart, fStop); + } + } +}; + +class TProofPerfAnalysis::TWrkInfoFile : public TNamed { +public: + TWrkInfoFile(const char *ord, const char *name) : TNamed(ord, name) { } + ~TWrkInfoFile() {fPackets.SetOwner(kFALSE); fPackets.Clear();} + TList fPackets; // Packest from this file processed by this worker + void Print(Option_t *opt= "") const { + if (!strcmp(opt, "R")) { + Printf(" Worker: %s,\tpacket(s): %d", GetName(), fPackets.GetSize()); + } else { + Printf(" Worker: %s,\t%d packet(s) from file: %s", GetName(), fPackets.GetSize(), GetTitle()); + } + TIter nxp(&fPackets); + TObject *o = 0; + while ((o = nxp())) { o->Print("S"); } + } +}; + +class TProofPerfAnalysis::TWrkEntry : public TObject { +public: + TWrkEntry(Double_t xx, Double_t er, Double_t mbr, Double_t pt) : fXx(xx), fEvtRate(er), fMBRate(mbr), fProcTime(pt) { } + Double_t fXx; // Bin center + Double_t fEvtRate; // Event processing rate from this worker for this packet + Double_t fMBRate; // I/O processing rate from this worker for this packet + Double_t fProcTime; // Processing time + void Print(Option_t * = "") const { Printf("%.4f \t%.3f evt/s \t%.3f MB/s \t%.3f s ", fXx, fEvtRate, fMBRate, fProcTime); } +}; + +//_______________________________________________________________________ +class TProofPerfAnalysis::TFileInfo : public TNamed { +public: + TFileInfo(const char *name, const char *srv) : + TNamed(name, srv), fPackets(0), fRPackets(0), fStart(0), fStop(-1), + fSizeAvg(0), fSizeMax(-1.), fSizeMin(-1.), + fMBRateAvg(0), fMBRateMax(-1.), fMBRateMin(-1.), fSizeP(0), + fRateP(0), fRatePRemote(0), fMBRateP(0), fMBRatePRemote(0) { } + virtual ~TFileInfo() {SafeDelete(fSizeP); + SafeDelete(fRateP); SafeDelete(fRatePRemote); + SafeDelete(fMBRateP); SafeDelete(fMBRatePRemote); + fPackList.SetOwner(kTRUE); fPackList.Clear(); + fWrkList.SetOwner(kTRUE); fWrkList.Clear(); + fRWrkList.SetOwner(kTRUE); fRWrkList.Clear();} + + Int_t fPackets; // Number of packets from this file + Int_t fRPackets; // Number of different remote workers processing this file + + TList fPackList; // List of packet info + TList fWrkList; // List of worker names processing this packet + TList fRWrkList; // List of remote worker names processing this packet + + Float_t fStart; // When the first packet has been assigned + Float_t fStop; // When the last packet has been finished + + Long64_t fSizeAvg; // Average Packet size + Long64_t fSizeMax; // Max packet size + Long64_t fSizeMin; // Min packet size + + Double_t fMBRateAvg; // Average MB rate + Double_t fMBRateMax; // Max MB rate + Double_t fMBRateMin; // Min MB rate + + TGraph *fSizeP; // Packet size vs packet (all) + TGraph *fRateP; // Event processing rate vs packet (all) + TGraph *fRatePRemote; // Event processing rate vs packet (remote workers) + TGraph *fMBRateP; // Byte processing rate vs packet (all) + TGraph *fMBRatePRemote; // Byte processing rate vs packet (remote workers) + + void Print(Option_t *opt = "") const { + Printf(" +++ TFileInfo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ "); + Printf(" +++ Server: %s", GetTitle()); + Printf(" +++ File: %s", GetName()); + Printf(" +++ Processing interval: %f -> %f", fStart, fStop); + Printf(" +++ Packets: %d (%d remote)", fPackets, fRPackets); + Printf(" +++ Processing wrks: %d (%d remote)", fWrkList.GetSize(), fRWrkList.GetSize()); + if (!strcmp(opt, "P")) fPackList.Print(); + if (!strcmp(opt, "WP")) fWrkList.Print("R"); + if (fPackets > 0) { + Printf(" +++ MB rates: %f MB/s (avg), %f MB/s (min), %f MB/s (max)", + fMBRateAvg / fPackets, fMBRateMin, fMBRateMax); + Printf(" +++ Sizes: %lld (avg), %lld (min), %lld (max)", + fSizeAvg / fPackets, fSizeMin, fSizeMax); + } + Printf(" +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ "); + } + + Int_t Compare(const TObject *o) const { TFileInfo *wi = (TFileInfo *)o; + if (wi) { + if (fStop < wi->fStop) { + return -1; + } else if (fStop == wi->fStop) { + return 0; + } + } + return 1; } +}; + +Bool_t TProofPerfAnalysis::fgDebug = kTRUE; //________________________________________________________________________ TProofPerfAnalysis::TProofPerfAnalysis(const char *perffile, const char *title, const char *treename) : TNamed(perffile, title), fTreeName(treename), fInitTime(-1.), fMergeTime(-1.), fMaxTime(-1.), fEvents(0), fPackets(0), - fEvtRateMax(-1.), fMBRateMax(-1.), fLatencyMax(-1.) + fEvtRateMax(-1.), fMBRateMax(-1.), fLatencyMax(-1.), + fEvtRate(0), fEvtRateRun(0), fMBRate(0), fMBRateRun(0), + fEvtRateAvgMax(-1.), fMBRateAvgMax(-1.), + fEvtRateAvg(-1.), fMBRateAvg(0), + fDebug(0) { // Constructor: open the file and attach to the tree @@ -112,6 +231,7 @@ TProofPerfAnalysis::TProofPerfAnalysis(const char *perffile, SafeDelete(fFile); Error("TProofPerfAnalysis", "problems opening file '%s'", perffile ? perffile : "<undef>"); + SetBit(TObject::kInvalidObject); return; } @@ -132,6 +252,7 @@ TProofPerfAnalysis::TProofPerfAnalysis(const char *perffile, Error("TProofPerfAnalysis", "directory '%s' not found or not loadable", fDirName.Data()); fFile->Close(); SafeDelete(fFile); + SetBit(TObject::kInvalidObject); return; } } @@ -142,12 +263,60 @@ TProofPerfAnalysis::TProofPerfAnalysis(const char *perffile, Error("TProofPerfAnalysis", "tree '%s' not found or not loadable", fTreeName.Data()); fFile->Close(); SafeDelete(fFile); + SetBit(TObject::kInvalidObject); return; } - Printf(" +++ TTree '%s' has %lld entries", fTreeName.Data(), fTree->GetEntries()); + if (fgDebug) + Printf(" +++ TTree '%s' has %lld entries", fTreeName.Data(), fTree->GetEntries()); // Init worker information FillWrkInfo(); + + // Init file information + FillFileInfo(); + + // Done + return; +} + +//________________________________________________________________________ +TProofPerfAnalysis::TProofPerfAnalysis(TTree *tree, const char *title) + : TNamed("", title), fFile(0), + fInitTime(-1.), fMergeTime(-1.), fMaxTime(-1.), + fEvents(0), fPackets(0), + fEvtRateMax(-1.), fMBRateMax(-1.), fLatencyMax(-1.), + fEvtRate(0), fEvtRateRun(0), fMBRate(0), fMBRateRun(0), + fEvtRateAvgMax(-1.), fMBRateAvgMax(-1.), + fEvtRateAvg(-1.), fMBRateAvg(0), + fDebug(0) +{ + // Constructor: open the file and attach to the tree + + // The tree must be defined + if (!tree) { + SetBit(TObject::kInvalidObject); + return; + } + + // Use default title, if not specified + if (!title) SetTitle("PROOF Performance Analysis"); + + fTree = tree; + fTreeName = fTree->GetName(); + SetName(TString::Format("heap_%s", fTreeName.Data())); + + // Adjust the name, if requested + if (fTreeName.BeginsWith("+")) + fTreeName.Replace(0, 1, "PROOF_PerfStats"); + + if (fgDebug) + Printf(" +++ TTree '%s' has %lld entries", fTreeName.Data(), fTree->GetEntries()); + + // Init worker information + FillWrkInfo(); + + // Init file information + FillFileInfo(); // Done return; @@ -209,7 +378,7 @@ void TProofPerfAnalysis::LoadTree(TDirectory *dir) if (tn.Index(re) != kNPOS) { if ((fTree = dynamic_cast<TTree *>(dir->Get(tn)))) { fTreeName = tn; - Printf(" +++ Found and loaded TTree '%s'", tn.Data()); + if (fgDebug) Printf(" +++ Found and loaded TTree '%s'", tn.Data()); return; } } @@ -234,7 +403,7 @@ void TProofPerfAnalysis::FileDist(Bool_t writedet) // Fill file info TList *wrkList = new TList; TList *srvList = new TList; - GetFileInfo(wrkList, srvList); + GetWrkFileList(wrkList, srvList); Info("FileDist", "%d workers were active during this query", wrkList->GetSize()); Info("FileDist", "%d servers were active during this query", srvList->GetSize()); @@ -407,7 +576,7 @@ void TProofPerfAnalysis::FileDist(Bool_t writedet) } //________________________________________________________________________ -void TProofPerfAnalysis::GetFileInfo(TList *wl, TList *sl) +void TProofPerfAnalysis::GetWrkFileList(TList *wl, TList *sl) { // Fill file info @@ -705,6 +874,64 @@ void TProofPerfAnalysis::PrintWrkInfo(const char *wn) } } +//________________________________________________________________________ +void TProofPerfAnalysis::PrintFileInfo(Int_t showlast, const char *opt, const char *out) +{ + // Print information for all or the slowest showlast workers. + // Use showlast < 0 to print all + + RedirectHandle_t rh; + if (out && strlen(out) > 0) gSystem->RedirectOutput(out, "w", &rh); + + // Create the sorted list + Int_t k = fFilesInfo.GetSize(); + TIter nxf(&fFilesInfo); + TFileInfo *fi = 0; + while ((fi = (TFileInfo *)nxf())) { + // Print info about files processed last + k--; + if (showlast < 0 || k < showlast) fi->Print(opt); + } + + if (out && strlen(out) > 0) gSystem->RedirectOutput(0, 0, &rh); +} + +//________________________________________________________________________ +void TProofPerfAnalysis::PrintFileInfo(const char *fn, const char *opt, const char *out) +{ + // Print information for file 'fn' (path including directory) or server 'fn'. + // Multiple specifications separated by ',' + // or ' ' are supported, as well as wildcards '*', e.g. 'pippo.root, h4mu*,lxb10*" + + if (!fn || (fn && strlen(fn) <= 0)) { + Error("PrintFileInfo", "file path must be defined!"); + return; + } + + RedirectHandle_t rh; + if (out && strlen(out) > 0) gSystem->RedirectOutput(out, "w", &rh); + + // Check exact name + TFileInfo *fi = (TFileInfo *) fFilesInfo.FindObject(fn); + if (fi) { + fi->Print(opt); + } else { + // Check matching + TString fw(fn), f; + TIter nxf(&fFilesInfo); + while ((fi = (TFileInfo *)nxf())) { + TString n(fi->GetName()), s(fi->GetTitle()); + Ssiz_t from = 0; + while (fw.Tokenize(f, from, "[, ]")) { + TRegexp re(f, kTRUE); + if (n.Index(re) != kNPOS || s.Index(re) != kNPOS) fi->Print(opt); + } + } + } + + if (out && strlen(out) > 0) gSystem->RedirectOutput(0, 0, &rh); +} + //________________________________________________________________________ void TProofPerfAnalysis::FillWrkInfo(Bool_t force) { @@ -729,14 +956,79 @@ void TProofPerfAnalysis::FillWrkInfo(Bool_t force) TPerfEvent* pep = &pe; fTree->SetBranchAddress("PerfEvents",&pep); Long64_t entries = fTree->GetEntries(); + + // First determine binning for global rates + Int_t nraw = entries * 2, jj = 0, kk = 0; + Double_t *xraw = new Double_t[nraw]; + for (Long64_t k=0; k<entries; k++) { + fTree->GetEntry(k); + // Analyse only packets + if (pe.fType == TVirtualPerfStats::kPacket) { + Float_t stop = pe.fTimeStamp.GetSec() + 1e-9*pe.fTimeStamp.GetNanoSec(); + Float_t start = stop - pe.fProcTime; + // Bins + xraw[jj++] = start; + xraw[jj++] = stop; + } + } + Int_t nbins = jj; + Int_t *jidx = new Int_t[nbins]; + memset(jidx, 0, nbins * sizeof(Int_t)); + TMath::Sort(nbins, xraw, jidx, kFALSE); + Double_t *xbins = new Double_t[nbins]; + jj = 0; + for (kk = 0; kk < nbins; kk++) { + Double_t xtmp = xraw[jidx[kk]]; + if (jj == 0 || xtmp > xbins[jj - 1] + .5) { + xbins[jj] = xtmp; + jj++; + } + } + nbins = jj; + delete [] xraw; + delete [] jidx; + + // Create the global histograms + Int_t nbin = nbins - 1; + TObject *o = 0; + if ((o = gDirectory->FindObject("gEvtRate"))) delete o; + fEvtRate = new TH1F("gEvtRate", "Total event processing rate (evt/s)", nbin, xbins); + fEvtRate->SetMinimum(0.); + fEvtRate->SetStats(kFALSE); + fEvtRate->SetFillColor(kCyan-8); + fEvtRate->GetXaxis()->SetTitle("Query Processing Time (s)"); + if ((o = gDirectory->FindObject("gEvtRateAvg"))) delete o; + fEvtRateRun = new TH1F("gEvtRateAvg", "Event processing rate running average (evt/s)", nbin, xbins); + fEvtRateRun->SetMinimum(0.); + fEvtRateRun->SetStats(kFALSE); + fEvtRateRun->SetLineColor(kBlue); + fEvtRateRun->GetXaxis()->SetTitle("Query Processing Time (s)"); + if ((o = gDirectory->FindObject("gMBRate"))) delete o; + fMBRate = new TH1F("gMBRate", "Total processing rate (MB/s)", nbin, xbins); + fMBRate->SetMinimum(0.); + fMBRate->SetStats(kFALSE); + fMBRate->SetFillColor(kCyan-8); + fMBRate->GetXaxis()->SetTitle("Query Processing Time (s)"); + if ((o = gDirectory->FindObject("gMBRateAvg"))) delete o; + fMBRateRun = new TH1F("gMBRateAvg", "Processing rate running average (MB/s)", nbin, xbins); + fMBRateRun->SetMinimum(0.); + fMBRateRun->SetStats(kFALSE); + fMBRateRun->SetLineColor(kBlue); + fMBRateRun->GetXaxis()->SetTitle("Query Processing Time (s)"); + // Not needed any longer + delete [] xbins; + + THashList gBins; + TList *gwl = 0, *gbl = 0; + + // Extract the worker info now TWrkInfo *wi = 0; for (Long64_t k=0; k<entries; k++) { fTree->GetEntry(k); // Analyse only packets if (pe.fType == TVirtualPerfStats::kPacket) { // Find out the worker instance - wi = (TWrkInfo *) wl->FindObject(pe.fSlave.Data()); - if (!wi) { + if (!(wi = (TWrkInfo *) wl->FindObject(pe.fSlave.Data()))) { wi = new TWrkInfo(pe.fSlave.Data(), pe.fSlaveName.Data()); wl->Add(wi); wi->fRateT = new TGraph(100); @@ -746,20 +1038,22 @@ void TProofPerfAnalysis::FillWrkInfo(Bool_t force) wi->fLatencyT = new TGraph(100); } // Add Info now + Float_t stop = pe.fTimeStamp.GetSec() + 1e-9*pe.fTimeStamp.GetNanoSec(); + Float_t start = stop - pe.fProcTime; if (wi->fPackets <= 0) { - wi->fStart = pe.fTimeStamp.GetSec() + 1e-9*pe.fTimeStamp.GetNanoSec() - pe.fProcTime; + wi->fStart = start; } else { - wi->fStop = pe.fTimeStamp.GetSec() + 1e-9*pe.fTimeStamp.GetNanoSec(); + wi->fStop = stop; } TUrl uf(pe.fFileName), uw(pe.fSlaveName); - fMaxTime = pe.fTimeStamp.GetSec() + 1e-9*pe.fTimeStamp.GetNanoSec(); + fMaxTime = stop; wi->fEventsProcessed += pe.fEventsProcessed; wi->fBytesRead += pe.fBytesRead; wi->fLatency += pe.fLatency; wi->fProcTime += pe.fProcTime; wi->fCpuTime += pe.fCpuTime; // Fill graphs - Double_t tt = pe.fTimeStamp.GetSec() + 1e-9*pe.fTimeStamp.GetNanoSec(); + Double_t tt = stop; Double_t ert = pe.fEventsProcessed / pe.fProcTime ; Double_t brt = pe.fBytesRead / pe.fProcTime / 1024. / 1024. ; wi->fRateT->SetPoint(wi->fPackets, tt, ert); @@ -774,8 +1068,35 @@ void TProofPerfAnalysis::FillWrkInfo(Bool_t force) if (ert > fEvtRateMax) fEvtRateMax = ert; if (brt > fMBRateMax) fMBRateMax = brt; if (pe.fLatency > fLatencyMax) fLatencyMax = pe.fLatency; + + // Fill global rate histos + for (kk = 1; kk <= nbins; kk++) { + Double_t mi = fEvtRate->GetBinLowEdge(kk); + if (mi > stop) break; + Double_t wd = fEvtRate->GetBinWidth(kk); + Double_t mx = mi + wd; + Double_t xx = fEvtRate->GetBinCenter(kk); + // Overlap length + Double_t olap = stop - mi; + if (start > mi) olap = mx - start; + if (olap >= 0) { + TString sb = TString::Format("%d", kk); + if (!(gbl = (TList *) gBins.FindObject(sb))) { + gbl = new TList; + gbl->SetName(sb); + gBins.Add(gbl); + } + if (!(gwl = (TList *) gbl->FindObject(pe.fSlave))) { + gwl = new TList; + gwl->SetName(pe.fSlave); + gbl->Add(gwl); + } + gwl->Add(new TWrkEntry(xx, ert, brt, pe.fProcTime)); + } + } + // Notify - if (fgDebug > 1) { + if (fDebug > 1) { if (pe.fProcTime > 0.) { Printf(" +++ %s #:%d at:%fs lat:%fs proc:%fs evts:%lld bytes:%lld (rates:%f evt/s, %f MB/s)", wi->GetName(), wi->fPackets, fMaxTime - pe.fProcTime, @@ -788,21 +1109,77 @@ void TProofPerfAnalysis::FillWrkInfo(Bool_t force) } } else if (pe.fType == TVirtualPerfStats::kStart) { Float_t start = pe.fTimeStamp.GetSec() + 1e-9*pe.fTimeStamp.GetNanoSec(); - if (fgDebug > 1) Printf(" +++ %s Start: %f s", pe.fEvtNode.Data(), start); + if (fDebug > 1) Printf(" +++ %s Start: %f s", pe.fEvtNode.Data(), start); } else if (pe.fType == TVirtualPerfStats::kStop) { Float_t stop = pe.fTimeStamp.GetSec() + 1e-9*pe.fTimeStamp.GetNanoSec(); - if (fgDebug > 1) Printf(" +++ %s Stop: %f s", pe.fEvtNode.Data(), stop); + if (fDebug > 1) Printf(" +++ %s Stop: %f s", pe.fEvtNode.Data(), stop); + } else { + if (fDebug > 2) Printf(" +++ Event type: %d", pe.fType); + } + } + + TIter nxb(&gBins); + gbl = 0; + while ((gbl = (TList *) nxb())) { + gwl = 0; + TIter nxw(gbl); + while ((gwl = (TList *) nxw())) { + Double_t er = 0, br = 0, pt = 0, xx = 0; + TIter nxp(gwl); + TWrkEntry *we = 0; + while ((we = (TWrkEntry *) nxp())) { + if (we->fProcTime > 0) { + er += we->fEvtRate * we->fProcTime; + br += we->fMBRate * we->fProcTime; + pt += we->fProcTime; + } + xx = we->fXx; + } + if (pt > 0.) { + er /= pt; + br /= pt; + fEvtRate->Fill(xx, er); + if (br > 0.) fMBRate->Fill(xx, br); + } + } + } + + // Running averages + Double_t er = 0, br = 0, pt = 0; + for (kk = 1; kk < nbins; kk++) { + Double_t wd = fEvtRate->GetBinWidth(kk); + Double_t wx = fEvtRate->GetBinCenter(kk); + Double_t wer = fEvtRate->GetBinContent(kk); + Double_t wbr = fMBRate->GetBinContent(kk); + + if (kk == 1) { + er = wer; + br = wbr; + pt = wd; } else { - if (fgDebug > 2) Printf(" +++ Event type: %d", pe.fType); + er *= pt; + br *= pt; + pt += wd; + er += wer * wd; + br += wbr * wd; + er /= pt; + br /= pt; } + if (er > fEvtRateAvgMax) fEvtRateAvgMax = er; + if (br > fMBRateAvgMax) fMBRateAvgMax = br; + fEvtRateAvg = er; + fMBRateAvg = br; + // Fill + fEvtRateRun->Fill(wx, er); + fMBRateRun->Fill(wx, br); } + + // Final analysis to find relevant times - fMergeTime = fMaxTime; TIter nxw(wl); while ((wi = (TWrkInfo *) nxw())) { fWrksInfo.Add(wi); if (wi->fStart > fInitTime) fInitTime = wi->fStart; - if (wi->fStop < fMergeTime || fMergeTime < 0.) fMergeTime = wi->fStop; // Resize the graphs wi->fRateT->Set(wi->fPackets); wi->fRateRemoteT->Set(wi->fRemotePackets); @@ -813,6 +1190,16 @@ void TProofPerfAnalysis::FillWrkInfo(Bool_t force) wl->SetOwner(kFALSE); delete wl; + // Final analysis to find relevant times + fMergeTime = fMaxTime; + Int_t rsw = (fWrksInfo.GetSize() > 1) ? 2 : 2, ksw = 0; + TIter nxsw(&fWrksInfo); + while ((wi = (TWrkInfo *) nxsw())) { + if (wi->fStop > 0.) ksw++; + if (ksw == rsw) break; + } + if (wi) fMergeTime = wi->fStop; + // (Re-)create the event and packet distribution histograms SafeDelete(fEvents); SafeDelete(fPackets); @@ -838,9 +1225,162 @@ void TProofPerfAnalysis::FillWrkInfo(Bool_t force) fPackets->GetXaxis()->SetTitle("Worker"); // Print summary - Printf(" +++ %d workers were active during this query", fWrksInfo.GetSize()); - Printf(" +++ Total query time: %f secs (init: %f secs, merge: %f secs)", - fMaxTime, fInitTime, fMaxTime - fMergeTime); + if (fgDebug) Summary(); +} + +//________________________________________________________________________ +void TProofPerfAnalysis::Summary(Option_t *opt, const char *out) +{ + // Print summary of query. Use opt = 'S' for compact version. + // Output to 'out' or to screen. + + TString o(out); + RedirectHandle_t rh; + if (!o.IsNull()) { + const char *m = (o.BeginsWith("+")) ? "a" : "w"; + o.Remove(TString::kLeading, '+'); + gSystem->RedirectOutput(o, m, &rh); + } + + // Print summary + if (!strcmp(opt, "S")) { + // Short version + Printf("%d %f %f %f %f %f %f %f", + fWrksInfo.GetSize(), fMaxTime, fInitTime, fMaxTime - fMergeTime, + fEvtRateAvg, fEvtRateAvgMax, fMBRateAvg, fMBRateAvgMax); + } else { + // Long version + Printf(" +++ %d workers were active during this query", fWrksInfo.GetSize()); + Printf(" +++ Total query time: %f secs (init: %f secs, merge: %f secs)", + fMaxTime, fInitTime, fMaxTime - fMergeTime); + Printf(" +++ Avg processing rates: %.4f evts/s, %.4f MB/s", fEvtRateAvg, fMBRateAvg); + Printf(" +++ Max processing rates: %.4f evts/s, %.4f MB/s", fEvtRateAvgMax, fMBRateAvgMax); + } + + if (!o.IsNull()) gSystem->RedirectOutput(0, 0, &rh); +} + +//________________________________________________________________________ +void TProofPerfAnalysis::FillFileInfo(Bool_t force) +{ + // Fill basic worker info; if 'force' rescan the TTree even already done + + // Nothing to do if already called + if (fFilesInfo.GetSize() > 0 && !force) return; + + // Cleanup existing information + fFilesInfo.SetOwner(kTRUE); + fFilesInfo.Clear(); + + TList *fl = new TList; + // Extract worker information + TPerfEvent pe; + TPerfEvent* pep = &pe; + fTree->SetBranchAddress("PerfEvents",&pep); + Long64_t entries = fTree->GetEntries(); + TFileInfo *fi = 0; + for (Long64_t k=0; k<entries; k++) { + fTree->GetEntry(k); + // Analyse only packets + if (pe.fType == TVirtualPerfStats::kPacket) { + TUrl uf(pe.fFileName); + TString srv(uf.GetUrl()); + Int_t ifn = srv.Index(uf.GetFile()); + if (ifn != kNPOS) srv.Remove(ifn); + // Find out the file instance + fi = (TFileInfo *) fl->FindObject(uf.GetFile()); + if (!fi) { + fi = new TFileInfo(uf.GetFile(), srv.Data()); + fl->Add(fi); + fi->fSizeP = new TGraph(10); + fi->fRateP = new TGraph(10); + fi->fRatePRemote = new TGraph(10); + fi->fMBRateP = new TGraph(10); + fi->fMBRatePRemote = new TGraph(10); + } + // Add Info now + Float_t stop = pe.fTimeStamp.GetSec() + 1e-9*pe.fTimeStamp.GetNanoSec(); + Float_t start = stop - pe.fProcTime; + if (fi->fPackets <= 0) { + fi->fStart = start; + } else { + fi->fStop = stop; + } + TUrl uw(pe.fSlaveName); + + // Fill size graphs + fi->fSizeP->SetPoint(fi->fPackets, (Double_t) fi->fPackets, (Double_t) pe.fEventsProcessed); + fi->fSizeAvg += pe.fEventsProcessed; + if (pe.fEventsProcessed > fi->fSizeMax || fi->fSizeMax < 0.) fi->fSizeMax = pe.fEventsProcessed; + if (pe.fEventsProcessed < fi->fSizeMin || fi->fSizeMin < 0.) fi->fSizeMin = pe.fEventsProcessed; + + // Fill rate graphs + Double_t tt = pe.fTimeStamp.GetSec() + 1e-9*pe.fTimeStamp.GetNanoSec(); + Double_t ert = pe.fEventsProcessed / pe.fProcTime ; + Double_t brt = pe.fBytesRead / pe.fProcTime / 1024. / 1024. ; + fi->fRateP->SetPoint(fi->fPackets, tt, ert); + if (brt > 0.) fi->fMBRateP->SetPoint(fi->fPackets, tt, brt); + if (!pe.fFileName.IsNull() && strcmp(uf.GetHostFQDN(), uw.GetHostFQDN())) { + if (!(fi->fRWrkList.FindObject(pe.fSlave))) fi->fRWrkList.Add(new TNamed(pe.fSlave, pe.fSlaveName)); + fi->fRatePRemote->SetPoint(fi->fRPackets, tt, ert); + fi->fMBRatePRemote->SetPoint(fi->fRPackets, tt, brt); + fi->fRPackets++; + } + fi->fPackets++; + if (brt > 0) { + fi->fMBRateAvg += brt; + if (brt > fi->fMBRateMax || fi->fMBRateMax < 0.) fi->fMBRateMax = brt; + if (brt < fi->fMBRateMin || fi->fMBRateMin < 0.) fi->fMBRateMin = brt; + } + + // Packet info + TPackInfo *pi = new TPackInfo(pe.fSlave, pe.fSlaveName, start, stop, pe.fEventsProcessed, brt); + fi->fPackList.Add(pi); + TWrkInfoFile *wif = 0; + if (!(wif = (TWrkInfoFile *) fi->fWrkList.FindObject(pe.fSlave))) { + wif = new TWrkInfoFile(pe.fSlave, uf.GetFile()); + fi->fWrkList.Add(wif); + } + wif->fPackets.Add(pi); + + // Notify + if (fDebug > 1) { + if (pe.fProcTime > 0.) { + Printf(" +++ %s #:%d at:%fs lat:%fs proc:%fs evts:%lld bytes:%lld (rates:%f evt/s, %f MB/s)", + fi->GetName(), fi->fPackets, fMaxTime - pe.fProcTime, + pe.fLatency, pe.fProcTime, pe.fEventsProcessed, pe.fBytesRead, + ert, brt); + } else { + Printf(" +++ %s #:%d at:%fs lat:%fs proc:%fs rate:-- evt/s (-- bytes/s)", + fi->GetName(), fi->fPackets, fMaxTime, pe.fLatency, pe.fProcTime); + } + } + } else if (pe.fType == TVirtualPerfStats::kStart) { + Float_t start = pe.fTimeStamp.GetSec() + 1e-9*pe.fTimeStamp.GetNanoSec(); + if (fDebug > 1) Printf(" +++ %s Start: %f s", pe.fEvtNode.Data(), start); + } else if (pe.fType == TVirtualPerfStats::kStop) { + Float_t stop = pe.fTimeStamp.GetSec() + 1e-9*pe.fTimeStamp.GetNanoSec(); + if (fDebug > 1) Printf(" +++ %s Stop: %f s", pe.fEvtNode.Data(), stop); + } else { + if (fDebug > 2) Printf(" +++ Event type: %d", pe.fType); + } + } + // Final analysis to find relevant times + TIter nxf(fl); + while ((fi = (TFileInfo *) nxf())) { + fFilesInfo.Add(fi); + // Resize the graphs + fi->fRateP->Set(fi->fPackets); + fi->fRatePRemote->Set(fi->fRPackets); + fi->fMBRateP->Set(fi->fPackets); + fi->fMBRatePRemote->Set(fi->fRPackets); + } + fl->SetOwner(kFALSE); + delete fl; + + // Print summary + if (fgDebug) + Printf(" +++ %d files were processed during this query", fFilesInfo.GetSize()); } //________________________________________________________________________ @@ -848,9 +1388,17 @@ void TProofPerfAnalysis::SetDebug(Int_t d) { // Static setter for the verbosity level - fgDebug = d; + fDebug = d; } + +//________________________________________________________________________ +void TProofPerfAnalysis::SetgDebug(Bool_t on) +{ + // Static setter for the verbosity level + + fgDebug = on; +} //________________________________________________________________________ void TProofPerfAnalysis::EventDist() { @@ -881,20 +1429,28 @@ void TProofPerfAnalysis::RatePlot(const char *wrks) { // Show event processing or MB processing rate plot vs time - // Create the histograms - TObject *o = 0; - if ((o = gDirectory->FindObject("rt1"))) delete o; - TH1F *hrt1 = new TH1F("rt1", "Evt processing rate (evt/s)", 100, 0., fMaxTime); - hrt1->SetMinimum(0.); - hrt1->SetMaximum(1.05*fEvtRateMax); - hrt1->SetStats(kFALSE); - hrt1->GetXaxis()->SetTitle("Query Processing Time (s)"); - if ((o = gDirectory->FindObject("rt2"))) delete o; - TH1F *hrt2 = new TH1F("rt2", "MB processing rate (MB/s)", 100, 0., fMaxTime); - hrt2->SetMinimum(0.); - hrt2->SetMaximum(1.05*fMBRateMax); - hrt2->SetStats(kFALSE); - hrt2->GetXaxis()->SetTitle("Query Processing Time (s)"); + Bool_t global = (wrks && !strcmp(wrks, "global")) ? kTRUE : kFALSE; + + TH1F *hrt1 = 0, *hrt2 = 0; + if (global) { + hrt1 = fEvtRate; + hrt2 = fMBRate; + } else { + // Create the histograms + TObject *o = 0; + if ((o = gDirectory->FindObject("rt1"))) delete o; + hrt1 = new TH1F("rt1", "Evt processing rate (evt/s)", 100, 0., fMaxTime); + hrt1->SetMinimum(0.); + hrt1->SetMaximum(1.05*fEvtRateMax); + hrt1->SetStats(kFALSE); + hrt1->GetXaxis()->SetTitle("Query Processing Time (s)"); + if ((o = gDirectory->FindObject("rt2"))) delete o; + hrt2 = new TH1F("rt2", "MB processing rate (MB/s)", 100, 0., fMaxTime); + hrt2->SetMinimum(0.); + hrt2->SetMaximum(1.05*fMBRateMax); + hrt2->SetStats(kFALSE); + hrt2->GetXaxis()->SetTitle("Query Processing Time (s)"); + } // Display histo frames TCanvas *c1 = new TCanvas("rates", GetCanvasTitle("Processing rates"), 800,10,700,780); @@ -902,12 +1458,17 @@ void TProofPerfAnalysis::RatePlot(const char *wrks) TPad *pad1 = (TPad *) c1->GetPad(1); pad1->cd(); hrt1->Draw(); + if (global) fEvtRateRun->Draw("SAME"); TPad *pad2 = (TPad *) c1->GetPad(2); pad2->cd(); hrt2->Draw(); + if (global) fMBRateRun->Draw("SAME"); c1->cd(); c1->Update(); + // Done if global + if (global) return; + // Which workers? THashList *wl = 0; TString ww(wrks); @@ -921,6 +1482,7 @@ void TProofPerfAnalysis::RatePlot(const char *wrks) } // Now plot the graphs per worker + Int_t ci = 40, cir = 30, ic = 0; TIter nxw(&fWrksInfo); TWrkInfo *wi = 0; while ((wi = (TWrkInfo *) nxw())) { @@ -928,25 +1490,30 @@ void TProofPerfAnalysis::RatePlot(const char *wrks) if (wi->fRateT && wi->fRateT->GetN() > 0) { wi->fRateT->SetNameTitle(wi->GetName(), wi->GetTitle()); pad1->cd(); + wi->fRateT->SetLineColor(ci); wi->fRateT->Draw("L"); } if (wi->fRateRemoteT && wi->fRateRemoteT->GetN() > 0) { wi->fRateRemoteT->SetNameTitle(wi->GetName(), wi->GetTitle()); pad1->cd(); - wi->fRateRemoteT->SetLineColor(kRed); + wi->fRateRemoteT->SetLineColor(cir); wi->fRateRemoteT->Draw("L"); } if (wi->fMBRateT && wi->fMBRateT->GetN() > 0) { wi->fMBRateT->SetNameTitle(wi->GetName(), wi->GetTitle()); pad2->cd(); + wi->fMBRateT->SetLineColor(ci); wi->fMBRateT->Draw("L"); } if (wi->fMBRateRemoteT && wi->fMBRateRemoteT->GetN() > 0) { wi->fMBRateRemoteT->SetNameTitle(wi->GetName(), wi->GetTitle()); pad2->cd(); - wi->fMBRateRemoteT->SetLineColor(kRed); + wi->fMBRateRemoteT->SetLineColor(cir); wi->fMBRateRemoteT->Draw("L"); } + ic++; + ci = ic%10 + 40; + cir = ic%10 + 30; c1->cd(); c1->Update(); } @@ -992,14 +1559,18 @@ void TProofPerfAnalysis::LatencyPlot(const char *wrks) } // Now plot the graphs per worker + Int_t ci = 40, ic = 0; TIter nxw(&fWrksInfo); TWrkInfo *wi = 0; while ((wi = (TWrkInfo *) nxw())) { if (wl && !wl->FindObject(wi->GetName())) continue; if (wi->fLatencyT) { wi->fLatencyT->SetNameTitle(wi->GetName(), wi->GetTitle()); + wi->fLatencyT->SetLineColor(ci); wi->fLatencyT->Draw("L"); } + ic++; + ci = ic%10 + 40; c1->cd(); c1->Update(); } @@ -1010,3 +1581,210 @@ void TProofPerfAnalysis::LatencyPlot(const char *wrks) delete wl; } } + +//________________________________________________________________________ +void TProofPerfAnalysis::FileProcPlot(const char *fn, const char *out) +{ + // Show event processing or MB processing rate plot vs time + + if (!fn || strlen(fn) <= 0) { + Error("FileRatePlot", "file name is mandatory!"); + return; + } + // Get the file info object + TFileInfo *fi = (TFileInfo *) fFilesInfo.FindObject(fn); + if (!fi) { + Error("FileRatePlot", "TFileInfo object for '%s' not found!", fn); + return; + } + + // Output text file, if required + FILE *fo = stdout; + if (out && strlen(out) > 0) { + if (!(fo = fopen(out, "w"))) { + Warning("FileRatePlot", "problems creating '%s': logging to stdout", out); + fo = stdout; + } else { + Printf(" Details logged to %s", out); + } + } + + // Get bins + Int_t nbins = fi->fPackList.GetSize() * 2; + Double_t *xraw = new Double_t[nbins]; + Int_t jj = 0; + TPackInfo *pi = 0; + TIter nxp(&(fi->fPackList)); + while ((pi = (TPackInfo *) nxp())) { + // Bins + xraw[jj++] = pi->fStart; + xraw[jj++] = pi->fStop; + } + Int_t *jidx = new Int_t[nbins]; + memset(jidx, 0, nbins * sizeof(Int_t)); + TMath::Sort(nbins, xraw, jidx, kFALSE); + Double_t *xbins = new Double_t[nbins]; + Int_t kk =0; + for (kk = 0; kk < nbins; kk++) { + xbins[kk] = xraw[jidx[kk]]; + } + delete [] xraw; + delete [] jidx; + + // Create the histograms + Int_t nbin = nbins - 1; + TObject *o = 0; + if ((o = gDirectory->FindObject("rt1"))) delete o; + TH1F *hrt1 = new TH1F("rt1", "Total processing rate (MB/s)", nbins - 1, xbins); + hrt1->SetMinimum(0.); + hrt1->SetStats(kFALSE); + hrt1->GetXaxis()->SetTitle("Query Processing Time (s)"); + if ((o = gDirectory->FindObject("rt2"))) delete o; + TH1F *hrt2 = new TH1F("rt2", "Number of processing workers", nbins - 1, xbins); + hrt2->SetMinimum(0.); + hrt2->SetMaximum(1.2*fWrksInfo.GetSize()); + hrt2->SetStats(kFALSE); + hrt2->GetXaxis()->SetTitle("Query Processing Time (s)"); + if ((o = gDirectory->FindObject("rt3"))) delete o; + TH1F *hrt3 = new TH1F("rt3", "Total processing events", nbins - 1, xbins); + hrt3->SetMinimum(0.); + hrt3->SetStats(kFALSE); + hrt3->GetXaxis()->SetTitle("Query Processing Time (s)"); + if ((o = gDirectory->FindObject("rt4"))) delete o; + TH1F *hrt4 = new TH1F("rt4", "Weighted processing rate (MB/s)", nbins - 1, xbins); + hrt4->SetMinimum(0.); + hrt4->SetStats(kFALSE); + hrt4->GetXaxis()->SetTitle("Query Processing Time (s)"); + // Not needed any longer + delete [] xbins; + + // Fill histos now + Int_t ii = 0; + for (ii = 1; ii <= nbin; ii++) { + Double_t mi = hrt1->GetBinLowEdge(ii); + Double_t wd = hrt1->GetBinWidth(ii); + Double_t mx = mi + wd; + Double_t xx = hrt1->GetBinCenter(ii); + fprintf(fo, " Bin: %d/%d [%f, %f]\n", ii, nbin, mi, mx); + pi = 0; + kk = 0; + nxp.Reset(); + while ((pi = (TPackInfo *) nxp())) { + // Overlap length + Double_t olap = pi->fStop - mi; + if (pi->fStart > mi) olap = mx - pi->fStart; + if (olap >= 0) { + hrt1->Fill(xx, pi->fMBRate); + hrt2->Fill(xx, 1.); + hrt3->Fill(xx, pi->fSize); + hrt4->Fill(xx, pi->fMBRate * pi->fSize); + fprintf(fo, " %d: %s \t%lld \tevts \t%f \tMB/s\n", kk++, pi->GetName(), pi->fSize, pi->fMBRate); + } + } + } + if (fo != stdout) fclose(fo); + + // Display histo frames + TCanvas *c1 = new TCanvas("rates", GetCanvasTitle("File processing info"), 800,10,700,780); + c1->Divide(1,3); + TPad *pad1 = (TPad *) c1->GetPad(1); + pad1->cd(); + hrt1->Draw(); + TPad *pad2 = (TPad *) c1->GetPad(2); + pad2->cd(); + hrt2->Draw(); + TPad *pad4 = (TPad *) c1->GetPad(3); + pad4->cd(); + hrt4->Divide(hrt3); + hrt4->Draw(); + c1->cd(); + c1->Update(); +} + +//________________________________________________________________________ +void TProofPerfAnalysis::FileRatePlot(const char *fns) +{ + // Show MB processing rate plot per file vs time + + // Create the histograms + TObject *o = 0; + if ((o = gDirectory->FindObject("rt1"))) delete o; + TH1F *hrt1 = new TH1F("rt1", "Event processing rate per packet (evt/s)", 100, 0., fMaxTime); + hrt1->SetMinimum(0.); + hrt1->SetMaximum(1.05*fEvtRateMax); + hrt1->SetStats(kFALSE); + hrt1->GetXaxis()->SetTitle("Query Processing Time (s)"); + if ((o = gDirectory->FindObject("rt2"))) delete o; + TH1F *hrt2 = new TH1F("rt2", "I/O processing rate per packet (MB/s)", 100, 0., fMaxTime); + hrt2->SetMinimum(0.); + hrt2->SetMaximum(1.05*fMBRateMax); + hrt2->SetStats(kFALSE); + hrt2->GetXaxis()->SetTitle("Query Processing Time (s)"); + + // Display histo frames + TCanvas *c1 = new TCanvas("rates", GetCanvasTitle("Processing rates"), 800,10,700,780); + c1->Divide(1,2); + TPad *pad1 = (TPad *) c1->GetPad(1); + pad1->cd(); + hrt1->Draw(); + TPad *pad2 = (TPad *) c1->GetPad(2); + pad2->cd(); + hrt2->Draw(); + c1->cd(); + c1->Update(); + + // Which workers? + THashList *fl = 0; + TString fw(fns); + if (!fw.IsNull() && fw != "*" && fw != "all") { + TString w; + Ssiz_t from = 0; + while ((fw.Tokenize(w, from, ","))) { + if (!fl) fl = new THashList(); + fl->Add(new TObjString(w.Data())); + } + } + + // Now plot the graphs per worker + Int_t ci = 40, cir = 30, ic = 0; + TIter nxf(&fFilesInfo); + TFileInfo *fi = 0; + while ((fi = (TFileInfo *) nxf())) { + if (fl && !fl->FindObject(fi->GetName())) continue; + if (fi->fRateP && fi->fRateP->GetN() > 0) { + fi->fRateP->SetNameTitle(fi->GetName(), fi->GetTitle()); + pad1->cd(); + fi->fRateP->SetLineColor(ci); + fi->fRateP->Draw("L"); + } + if (fi->fRatePRemote && fi->fRatePRemote->GetN() > 0) { + fi->fRatePRemote->SetNameTitle(fi->GetName(), fi->GetTitle()); + pad1->cd(); + fi->fRatePRemote->SetLineColor(cir); + fi->fRatePRemote->Draw("L"); + } + if (fi->fMBRateP && fi->fMBRateP->GetN() > 0) { + fi->fMBRateP->SetNameTitle(fi->GetName(), fi->GetTitle()); + pad2->cd(); + fi->fMBRateP->SetLineColor(ci); + fi->fMBRateP->Draw("L"); + } + if (fi->fMBRatePRemote && fi->fMBRatePRemote->GetN() > 0) { + fi->fMBRatePRemote->SetNameTitle(fi->GetName(), fi->GetTitle()); + pad2->cd(); + fi->fMBRatePRemote->SetLineColor(cir); + fi->fMBRatePRemote->Draw("L"); + } + ic++; + ci = ic%10 + 40; + cir = ic%10 + 30; + c1->cd(); + c1->Update(); + } + + // Cleanup + if (fl) { + fl->SetOwner(kTRUE); + delete fl; + } +} diff --git a/proof/proofbench/src/TSelEventGen.cxx b/proof/proofbench/src/TSelEventGen.cxx index 563e6cab8cfb2..a29e96f35b823 100644 --- a/proof/proofbench/src/TSelEventGen.cxx +++ b/proof/proofbench/src/TSelEventGen.cxx @@ -357,24 +357,12 @@ Bool_t TSelEventGen::Process(Long64_t entry) TString fndset(filename); // Set the Url for remote access - TString dsrv, seed; - seed = TString::Format("%s/%s", gSystem->HostName(), filename.Data()); + TString seed = TString::Format("%s/%s", gSystem->HostName(), filename.Data()), dsrv; TUrl basedirurl(filename, kTRUE); if (!strcmp(basedirurl.GetProtocol(), "file")) { - if (gSystem->Getenv("LOCALDATASERVER")) { - dsrv = gSystem->Getenv("LOCALDATASERVER"); - if (!dsrv.EndsWith("/")) dsrv += "/"; - } else { - dsrv.Form("root://%s/", TUrl(gSystem->HostName()).GetHostFQDN()); - } - TString srvProto = TUrl(dsrv).GetProtocol(); - - // Remove prefix, if any, if included and if Xrootd - TString pfx = gEnv->GetValue("Path.Localroot",""); - if (!pfx.IsNull() && fndset.BeginsWith(pfx) && - (srvProto == "root" || srvProto == "xrd")) fndset.Remove(0, pfx.Length()); + TProofServ::GetLocalServer(dsrv); + TProofServ::FilterLocalroot(fndset, dsrv); } - //generate files Long64_t neventstogenerate = fNEvents; diff --git a/proof/proofd/CMakeLists.txt b/proof/proofd/CMakeLists.txt index 4653861b1c673..20068344b6171 100644 --- a/proof/proofd/CMakeLists.txt +++ b/proof/proofd/CMakeLists.txt @@ -7,19 +7,25 @@ ROOT_USE_PACKAGE(proof/proof) ROOT_USE_PACKAGE(net/rpdutils) ROOT_USE_PACKAGE(net/auth) -include_directories(${XROOTD_INCLUDE_DIR}) +include_directories(${XROOTD_INCLUDE_DIRS}) add_definitions(${XROOTD_CFLAGS}) if(WIN32) ROOT_LINKER_LIBRARY(XrdProofd XProofProtUtils.cxx LIBRARIES ${XROOTD_LIBRARIES}) else() ROOT_EXECUTABLE(proofd proofd.cxx ${CMAKE_SOURCE_DIR}/core/clib/src/strlcat.c - LIBRARIES ${XROOTD_LIBRARIES} rpdutil rsa ${OPENSSL_LIBRARIES} ${CRYPTLIBS} ) - ROOT_EXECUTABLE(xproofd X*.cxx ${CMAKE_SOURCE_DIR}/net/rpdutils/src/rpdconn.cxx + LIBRARIES ${XROOTD_LIBRARIES} rpdutil rsa ${GLOBUS_LIBRARIES} ${OPENSSL_LIBRARIES} ${CRYPTLIBS} ) + ROOT_EXECUTABLE(xproofd X*.cxx ${CMAKE_SOURCE_DIR}/net/rpdutils/src/rpdconn.cxx LIBRARIES ${XROOTD_LIBRARIES} ${SYSLIBS}) - ROOT_LINKER_LIBRARY(XrdProofd X*.cxx ${CMAKE_SOURCE_DIR}/net/rpdutils/src/rpdconn.cxx + ROOT_LINKER_LIBRARY(XrdProofd X*.cxx ${CMAKE_SOURCE_DIR}/net/rpdutils/src/rpdconn.cxx LIBRARIES ${XROOTD_LIBRARIES} rpdutil ${CMAKE_THREAD_LIBS_INIT} ${CMAKE_DL_LIBS}) set_target_properties(XrdProofd PROPERTIES LINK_INTERFACE_LIBRARIES "" ) endif() +if(builtin_xrootd) + add_dependencies(XrdProofd XROOTD) + add_dependencies(xproofd XROOTD) + add_dependencies(proofd XROOTD) +endif() + ROOT_INSTALL_HEADERS() diff --git a/proof/proofd/Module.mk b/proof/proofd/Module.mk index 36c0c44306140..ad3b0c36877ed 100644 --- a/proof/proofd/Module.mk +++ b/proof/proofd/Module.mk @@ -127,6 +127,10 @@ XPROOFDEXE := bin/xproofd ifeq ($(HASXRD),yes) XPDINCEXTRA := $(XROOTDDIRI:%=-I%) XPDINCEXTRA += $(PROOFDDIRI:%=-I%) +ifeq ($(XRDINCPRIVATE),yes) +XPDINCEXTRA += -I$(XRDINCDIR)/private +endif + ifeq ($(HASXRDUTILS),no) diff --git a/proof/proofd/inc/XpdObject.h b/proof/proofd/inc/XpdObject.h new file mode 100644 index 0000000000000..dd7f22ca57e70 --- /dev/null +++ b/proof/proofd/inc/XpdObject.h @@ -0,0 +1,100 @@ +// @(#)root/proofd:$Id$ +// Author: Gerardo Ganis Feb 2013 + +/************************************************************************* + * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////// +// // +// XpdObject // +// // +// Authors: G. Ganis, CERN, 2013 // +// // +// Auxilliary class to stack protocols. // +// Adapted version of XrdObject. // +// // +////////////////////////////////////////////////////////////////////////// + +#ifndef ROOT_XpdObject +#define ROOT_XpdObject + +#include <string.h> +#include <strings.h> +#include <time.h> +#include <sys/types.h> +#include "Xrd/XrdJob.hh" +#include "XrdOuc/XrdOucTrace.hh" +#include "XrdSys/XrdSysPthread.hh" + +class XpdObjectQ; +class XrdProofdProtocol; +class XrdScheduler; + +class XpdObject { +public: + friend class XpdObjectQ; + + // Item() supplies the item value associated with itself (used with Next()). + XrdProofdProtocol *objectItem() { return fItem; } + + // Next() supplies the next list node. + XpdObject *nextObject() { return fNext; } + + // Set the item pointer + void setItem(XrdProofdProtocol *ival) { fItem = ival; } + + XpdObject(XrdProofdProtocol *ival=0) { fNext = 0; fItem = ival; fQTime = 0; } + ~XpdObject() {} + +private: + XpdObject *fNext; + XrdProofdProtocol *fItem; + time_t fQTime; // Only used for time-managed objects +}; + +/******************************************************************************/ +/* x r d _ O b j e c t Q */ +/******************************************************************************/ + +// Note to properly cleanup this type of queue you must call Set() at least +// once to cause the time element to be sceduled. + +class XrdOucTrace; + +class XpdObjectQ : public XrdJob { +public: + + XrdProofdProtocol *Pop(); + void Push(XpdObject *Node); + void Set(int inQMax, time_t agemax=1800); + void Set(XrdScheduler *sp, XrdOucTrace *tp, int traceChk = 0) + {fSched = sp; fTrace = tp; fTraceON = traceChk;} + void DoIt(); + + XpdObjectQ(const char *id, const char *desc) : XrdJob(desc) + {fCurage = fCount = 0; fMaxage = 0; fTraceID = id; + fMaxinQ = 32; fMininQ = 16; fFirst = 0; } + + ~XpdObjectQ() {} + +private: + + XrdSysMutex fQMutex; + XpdObject *fFirst; + int fCount; + int fCurage; + int fMininQ; + int fMaxinQ; + time_t fMaxage; + XrdOucTrace *fTrace; + XrdScheduler *fSched; + int fTraceON; + const char *fTraceID; +}; + +#endif diff --git a/proof/proofd/inc/XpdSysDNS.h b/proof/proofd/inc/XpdSysDNS.h index ed996529b4cf3..b19b7229409f9 100644 --- a/proof/proofd/inc/XpdSysDNS.h +++ b/proof/proofd/inc/XpdSysDNS.h @@ -4,7 +4,7 @@ // #include "XrdProofdXrdVers.h" -#if ROOTXRDVERS < ROOT_XrdUtils +#if defined(ROOT_XrdNoUtils) #define XrdSysDNS XrdNetDNS #include "XrdNet/XrdNetDNS.hh" #else diff --git a/proof/proofd/inc/XrdProofdAux.h b/proof/proofd/inc/XrdProofdAux.h index 3c6dea583eb14..d981ccc939b85 100644 --- a/proof/proofd/inc/XrdProofdAux.h +++ b/proof/proofd/inc/XrdProofdAux.h @@ -18,7 +18,7 @@ // // // Authors: G. Ganis, CERN, 2007 // // // -// Small auxilliary classes used in XrdProof // +// Small auxiliary classes used in XrdProof // // // ////////////////////////////////////////////////////////////////////////// #include <list> @@ -219,14 +219,22 @@ class XrdProofdPipe { // class XrdProofdDSInfo { public: - XrdOucString fType; // Backend type - XrdOucString fUrl; // URL from where to take the information - bool fLocal; // TRUE if on the local file system - bool fRW; // TRUE if users can modify their area - XrdOucString fOpts; // Options for this source + XrdOucString fType; // Backend type + XrdOucString fUrl; // URL from where to take the information + bool fLocal; // TRUE if on the local file system + bool fRW; // TRUE if users can modify their area + XrdOucString fOpts; // Options for this source + XrdOucString fObscure; // Obscure options to pass through XrdProofdDSInfo(const char *t, const char *u, bool local, bool rw, - const char *o = "Ar:Av:") : - fType(t), fUrl(u), fLocal(local), fRW(rw), fOpts(o) { } + const char *o = "Ar:Av:", const char *obscure = "") : + fType(t), fUrl(u), fLocal(local), fRW(rw), fOpts(o), + fObscure(obscure) { } + XrdOucString ToString() const { + return "Type=" + fType + "; URL=" + fUrl + + "; Local=" + (fLocal ? "Yes" : "No") + + "; RW=" + (fRW ? "Yes" : "No") + "; Options=" + fOpts + + "; Obscure=" + fObscure; + } }; // diff --git a/proof/proofd/inc/XrdProofdClient.h b/proof/proofd/inc/XrdProofdClient.h index 17d0ed2367f11..6c73248cd3431 100644 --- a/proof/proofd/inc/XrdProofdClient.h +++ b/proof/proofd/inc/XrdProofdClient.h @@ -45,7 +45,7 @@ class XrdProofdClient { public: XrdProofdClient(XrdProofUI ui, - bool master, bool changeown, XrdSysError *edest, const char *tmp); + bool master, bool changeown, XrdSysError *edest, const char *tmp, int rtime); virtual ~XrdProofdClient(); @@ -105,6 +105,7 @@ class XrdProofdClient { bool fChangeOwn; // TRUE if ownership must be changed where relevant bool fIsValid; // TRUE if the instance is complete bool fAskedToTouch; // TRUE if a touch request has already been sent for this client + int fReconnectTimeOut; // Time given for disconnected clients to reconnect XrdProofUI fUI; // user info XrdROOT *fROOT; // ROOT vers instance to be used for proofserv @@ -133,18 +134,20 @@ class XrdClientID { XrdProofdProtocol *fP; XrdProofdResponse *fR; unsigned short fSid; + int fResetTime; void SetR() { fR = (fP && fSid > 0) ? fP->Response(fSid) : 0;} public: XrdClientID(XrdProofdProtocol *pt = 0, unsigned short id = 0) - { fP = pt; fSid = id; SetR();} + { fP = pt; fSid = id; SetR(); fResetTime = -1; } ~XrdClientID() { } XrdProofdClient *C() const { return fP->Client(); } bool IsValid() const { return (fP != 0); } XrdProofdProtocol *P() const { return fP; } XrdProofdResponse *R() const { return fR; } - void Reset() { fP = 0; fSid = 0; SetR(); } + void Reset() { fP = 0; fSid = 0; SetR(); fResetTime = time(0); } + int ResetTime() { return fResetTime; } void SetP(XrdProofdProtocol *p) { fP = p; SetR();} void SetSid(unsigned short sid) { fSid = sid; SetR();} unsigned short Sid() const { return fSid; } diff --git a/proof/proofd/inc/XrdProofdClientMgr.h b/proof/proofd/inc/XrdProofdClientMgr.h index 2c75f3668d245..1feacdf17f1b6 100644 --- a/proof/proofd/inc/XrdProofdClientMgr.h +++ b/proof/proofd/inc/XrdProofdClientMgr.h @@ -40,8 +40,9 @@ class XrdProofdConfig; class XrdProofdManager; class XrdProofdProtocol; class XrdProtocol_Config; -class XrdSysError; class XrdSecService; +class XrdSysError; +class XrdSysPlugin; class XrdProofdClientMgr : public XrdProofdConfig { @@ -49,7 +50,8 @@ class XrdProofdClientMgr : public XrdProofdConfig { XrdSysRecMutex *fMutex; XrdProofdManager *fMgr; XrdOucString fSecLib; - XrdSecService *fCIA; // Authentication Server + XrdSecService *fCIA; // Security framework + XrdSysPlugin *fSecPlugin; // Security framework plugin int fCheckFrequency; XrdProofdPipe fPipe; diff --git a/proof/proofd/inc/XrdProofdManager.h b/proof/proofd/inc/XrdProofdManager.h index 703801d58f664..e77419df1e087 100644 --- a/proof/proofd/inc/XrdProofdManager.h +++ b/proof/proofd/inc/XrdProofdManager.h @@ -89,7 +89,9 @@ class XrdProofdManager : public XrdProofdConfig { const char *WorkDir() const { return fWorkDir.c_str(); } const char *DataDir() const { return fDataDir.c_str(); } const char *DataDirOpts() const { return fDataDirOpts.c_str(); } + const char *DataDirUrlOpts() const { return fDataDirUrlOpts.c_str(); } const char *DataSetExp() const { return fDataSetExp.c_str(); } + const char *StageReqRepo() const { return fStageReqRepo.c_str(); } const char *RootdExe() const { return fRootdExe.c_str(); } const char **RootdArgs() const { return fRootdArgsPtrs; } @@ -138,7 +140,10 @@ class XrdProofdManager : public XrdProofdConfig { XrdOucString fLocalroot; // Local root prefix (directive oss.localroot) XrdOucString fDataDir; // Directory under which to create the sub-dirs for users data XrdOucString fDataDirOpts; // String specifying options for fDataDir handling + XrdOucString fDataDirUrlOpts; // String specifying URL type options for fDataDir XrdOucString fDataSetExp; // List of local dataset repositories to be asserted + XrdOucString fStageReqRepo; // Directive for staging requests + XrdOucString fRootdExe; // Path to 'rootd' to be use for protocol 'rootd://' std::list<XrdOucString> fRootdArgs;// Rootd arguments @@ -181,6 +186,7 @@ class XrdProofdManager : public XrdProofdConfig { int DoDirectiveAllowedUsers(char *, XrdOucStream *, bool); int DoDirectiveDataDir(char *, XrdOucStream *, bool); int DoDirectiveDataSetSrc(char *, XrdOucStream *, bool); + int DoDirectiveDataSetReqRepo(char *, XrdOucStream *, bool); int DoDirectiveFilterLibPaths(char *, XrdOucStream *, bool); int DoDirectiveGroupfile(char *, XrdOucStream *, bool); int DoDirectiveMaxOldLogs(char *, XrdOucStream *, bool); diff --git a/proof/proofd/inc/XrdProofdProofServMgr.h b/proof/proofd/inc/XrdProofdProofServMgr.h index 45eea1a3ddab1..de1c44abb6a44 100644 --- a/proof/proofd/inc/XrdProofdProofServMgr.h +++ b/proof/proofd/inc/XrdProofdProofServMgr.h @@ -23,6 +23,7 @@ ////////////////////////////////////////////////////////////////////////// #include <list> +#include <map> #include "XpdSysPthread.h" @@ -41,6 +42,9 @@ class XrdSysLogger; #define PSMMAXCNTS 3 #define PSMCNTOK(t) (t >= 0 && t < PSMMAXCNTS) +// Security handle +typedef int (*XrdSecCredsSaver_t)(XrdSecCredentials *, const char *fn, const XrdProofUI &ui); + // Aux structure for session set env inputs typedef struct { XrdProofdProofServ *fPS; @@ -158,6 +162,10 @@ class XrdProofdProofServMgr : public XrdProofdConfig { std::list<XrdProofdProofServ *> fActiveSessions; // List of active sessions (non-idle) std::list<XpdClientSessions *> *fRecoverClients; // List of client potentially recovering + std::map<XrdProofdProtocol*,int> fDestroyTimes; // Tracks destroyed sessions + + XrdSecCredsSaver_t fCredsSaver; // If defined, function to be used to save the credentials + int DoDirectiveProofServMgr(char *, XrdOucStream *, bool); int DoDirectivePutEnv(char *, XrdOucStream *, bool); int DoDirectivePutRc(char *, XrdOucStream *, bool); @@ -230,6 +238,8 @@ class XrdProofdProofServMgr : public XrdProofdConfig { bool IsClientRecovering(const char *usr, const char *grp, int &deadline); void SetReconnectTime(bool on = 1); + bool Alive(XrdProofdProtocol *p); + int Process(XrdProofdProtocol *p); XrdSysSemWait *ProcessSem() { return &fProcessSem; } @@ -257,14 +267,18 @@ class XrdProofdProofServMgr : public XrdProofdConfig { int CleanupProofServ(bool all = 0, const char *usr = 0); + void FormFileNameInSessionDir(XrdProofdProtocol *p, + XrdProofdProofServ *xps, + const char *sessiondir, + const char *extension, + XrdOucString &outfn); + void GetTagDirs(int opt, XrdProofdProtocol *p, XrdProofdProofServ *xps, XrdOucString &sesstag, XrdOucString &topsesstag, XrdOucString &sessiondir, XrdOucString &sesswrkdir); int SetProofServEnv(XrdProofdProtocol *p, void *in); int SetProofServEnvOld(XrdProofdProtocol *p, void *in); - - int SaveAFSkey(XrdSecCredentials *c, const char *fn, XrdProofUI ui); int SetUserEnvironment(XrdProofdProtocol *p); static int SetProofServEnv(XrdProofdManager *m, XrdROOT *r); diff --git a/proof/proofd/inc/XrdProofdProtocol.h b/proof/proofd/inc/XrdProofdProtocol.h index aa508d850bdbb..9766620c65b08 100644 --- a/proof/proofd/inc/XrdProofdProtocol.h +++ b/proof/proofd/inc/XrdProofdProtocol.h @@ -38,10 +38,10 @@ #include "XpdSysPthread.h" #include "Xrd/XrdLink.hh" -#include "Xrd/XrdObject.hh" #include "Xrd/XrdProtocol.hh" #include "XrdOuc/XrdOucString.hh" #include "XrdSec/XrdSecInterface.hh" +#include "XpdObject.h" #include "XProofProtocol.h" class XrdBuffer; @@ -131,7 +131,7 @@ class XrdProofdProtocol : XrdProtocol { // // Protocol variables - XrdObject<XrdProofdProtocol> fProtLink; + XpdObject fProtLink; XrdBuffer *fArgp; XrdLink *fLink; @@ -176,7 +176,7 @@ class XrdProofdProtocol : XrdProtocol { // static bool fgConfigDone; static int fgCount; - static XrdObjectQ<XrdProofdProtocol> fgProtStack; + static XpdObjectQ fgProtStack; static XrdBuffManager *fgBPool; // Buffer manager static int fgMaxBuffsz; // Maximum buffer size we can have static XrdSysRecMutex fgBMutex; // Buffer management mutex diff --git a/proof/proofd/inc/XrdProofdResponse.h b/proof/proofd/inc/XrdProofdResponse.h index 87f0af7b4e44f..23740cf4c2733 100644 --- a/proof/proofd/inc/XrdProofdResponse.h +++ b/proof/proofd/inc/XrdProofdResponse.h @@ -36,9 +36,7 @@ class XrdLink; class XrdProofdResponse { public: - XrdProofdResponse() { fLink = 0; *fTrsid = '\0'; fSID = 0; - fResp.dlen = 0; fResp.status = 0; - fResp.streamid[0] = 0; fResp.streamid[1] = 0; } + XrdProofdResponse() { Reset(); } virtual ~XrdProofdResponse() {} inline const char *STRID() { return (const char *)fTrsid;} @@ -79,6 +77,11 @@ class XrdProofdResponse void GetSID(unsigned short &sid); void SetTrsid(); + void Reset() { XrdSysMutexHelper mh(fMutex); + fLink = 0; *fTrsid = '\0'; fSID = 0; + fResp.dlen = 0; fResp.status = 0; + fResp.streamid[0] = 0; fResp.streamid[1] = 0; } + // To protect from concurrent use XrdSysRecMutex fMutex; diff --git a/proof/proofd/inc/XrdProofdXrdVers.h b/proof/proofd/inc/XrdProofdXrdVers.h index 00a6a832aae2a..5917163d61788 100644 --- a/proof/proofd/inc/XrdProofdXrdVers.h +++ b/proof/proofd/inc/XrdProofdXrdVers.h @@ -18,10 +18,15 @@ // This is when libXrdNetUtil appeared #define ROOT_XrdNetUtil 20100729 -// This is when the PhyConn interface changed -#define ROOT_PhyConnNoReuse 300000002 - -// This is when the header and library packaging changed -#define ROOT_XrdUtils 300010000 +// This is when the PhyConn interface changed (v3.0.2) +#define ROOT_PhyConnNoReuse 20110126 + +// This is when the header and library packaging changed (v3.1.0) +#if (ROOTXRDVERS < 30000000 && ROOTXRDVERS < 20111021) || \ + (ROOTXRDVERS >= 30000000 && ROOTXRDVERS < 300010000) +# define ROOT_XrdNoUtils +#else +# undef ROOT_XrdNoUtils +#endif #endif diff --git a/proof/proofd/src/XpdObject.cxx b/proof/proofd/src/XpdObject.cxx new file mode 100644 index 0000000000000..b81e66fc00b11 --- /dev/null +++ b/proof/proofd/src/XpdObject.cxx @@ -0,0 +1,125 @@ +// @(#)root/proofd:$Id$ +// Author: Gerardo Ganis Feb 2013 + +/************************************************************************* + * Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////// +// // +// XpdObject // +// // +// Authors: G. Ganis, CERN, 2013 // +// // +// Auxilliary class to stack protocols. // +// // +////////////////////////////////////////////////////////////////////////// + +#include "XpdObject.h" +#include "XrdProofdAux.h" +#include "XrdProofdProtocol.h" +#include "Xrd/XrdScheduler.hh" +#include "XrdOuc/XrdOucTrace.hh" + +//_______________________________________________________________________ +XrdProofdProtocol *XpdObjectQ::Pop() +{ + // Pop up a protocol object + + XpdObject *node; + fQMutex.Lock(); + if ((node = fFirst)) { + fFirst = fFirst->fNext; + fCount--; + } + fQMutex.UnLock(); + if (node) return node->fItem; + return (XrdProofdProtocol *)0; +} + +//_______________________________________________________________________ +void XpdObjectQ::Push(XpdObject *node) +{ + // Push back a protocol + + node->fQTime = fCurage; + fQMutex.Lock(); + if (fCount >= fMaxinQ) { + delete node->fItem; + } else { + node->fNext = fFirst; + fFirst = node; + fCount++; + } + fQMutex.UnLock(); +} + +//_______________________________________________________________________ +void XpdObjectQ::Set(int inQMax, time_t agemax) +{ + // Lock the data area and set the values + + fQMutex.Lock(); + fMaxinQ = inQMax; fMaxage = agemax; + if (!(fMininQ = inQMax/2)) fMininQ = 1; + fQMutex.UnLock(); + + // Schedule ourselves using the new values + if (agemax > 0) + fSched->Schedule((XrdJob *)this, agemax + time(0)); +} + +//_______________________________________________________________________ +void XpdObjectQ::DoIt() +{ + // Process method + + XpdObject *pp, *p; + int oldcnt, agemax; + + // Lock the anchor and see if we met the threshold for deletion + // + fQMutex.Lock(); + agemax = fMaxage; + if ((oldcnt = fCount) > fMininQ) { + + // Prepare to scan down the queue. + if ((pp = fFirst)) { + p = pp->fNext; + } else { p = 0; } + + // Find the first object that's been idle for too long + while(p && (p->fQTime >= fCurage)) { pp = p; p = p->fNext;} + + // Now delete half of the idle objects. The object queue element must be + // part of the actual object being deleted for this to properly work. + if (pp) { + while (p) { + pp->fNext = p->fNext; + delete p->fItem; + fCount--; + p = ((pp = pp->fNext) ? pp->fNext : 0); + } + } + } + + // Increase the age and unlock the queue + fCurage++; + fQMutex.UnLock(); + + // Trace as needed + if (fTraceON && fTrace->Tracing(fTraceON)) + {fTrace->Beg(fTraceID); + cerr <<Comment <<" trim done; " <<fCount <<" of " <<oldcnt <<" kept"; + fTrace->End(); + } + + // Reschedule ourselves if we must do so + if (agemax > 0) + fSched->Schedule((XrdJob *)this, agemax+time(0)); +} + diff --git a/proof/proofd/src/XrdProofConn.cxx b/proof/proofd/src/XrdProofConn.cxx index d37a472a3d48f..75ea02e671420 100644 --- a/proof/proofd/src/XrdProofConn.cxx +++ b/proof/proofd/src/XrdProofConn.cxx @@ -27,11 +27,11 @@ #include "XpdSysPthread.h" #include "XrdProofConn.h" +#include "XrdProofdAux.h" #include "XProofProtocol.h" #include "XrdClient/XrdClientConnMgr.hh" #include "XrdClient/XrdClientConst.hh" -#include "XrdClient/XrdClientDebug.hh" #include "XrdClient/XrdClientEnv.hh" #include "XrdClient/XrdClientLogConnection.hh" #include "XrdClient/XrdClientPhyConnection.hh" @@ -40,6 +40,7 @@ #include "XrdOuc/XrdOucErrInfo.hh" #include "XrdOuc/XrdOucString.hh" #include "XrdSec/XrdSecInterface.hh" +#include "XrdSys/XrdSysLogger.hh" #include "XrdSys/XrdSysPlatform.hh" // Dynamic libs @@ -85,9 +86,6 @@ int XrdProofConn::fgTimeWait = 2; // seconds XrdSysPlugin *XrdProofConn::fgSecPlugin = 0; // Sec library plugin void *XrdProofConn::fgSecGetProtocol = 0; // Sec protocol getter -#ifndef SafeDelete -#define SafeDelete(x) { if (x) { delete x; x = 0; } } -#endif #define URLTAG "["<<fUrl.Host<<":"<<fUrl.Port<<"]" //_____________________________________________________________________________ @@ -297,8 +295,8 @@ XrdProofConn::~XrdProofConn() } // Cleanup mutex - SafeDelete(fMutex); - SafeDelete(fConnectInterruptMtx); + SafeDel(fMutex); + SafeDel(fConnectInterruptMtx); } //_____________________________________________________________________________ @@ -553,7 +551,7 @@ XrdClientMessage *XrdProofConn::SendRecv(XPClientRequest *req, const void *reqDa TRACE(XERR, "reallocating "<<dataRecvSize<<" bytes"); free((void *) *answData); *answData = 0; - SafeDelete(xmsg); + SafeDel(xmsg); return xmsg; } } @@ -581,7 +579,7 @@ XrdClientMessage *XrdProofConn::SendRecv(XPClientRequest *req, const void *reqDa XPD::convertRespStatusToChar(xmsg->fHdr.status)<< "] (server "<<URLTAG<<") - Abort"); // We cannot continue - SafeDelete(xmsg); + SafeDel(xmsg); return xmsg; } // The last message may be empty: not an error @@ -672,7 +670,7 @@ XrdClientMessage *XrdProofConn::SendReq(XPClientRequest *req, const void *reqDat } if (abortcmd) { // Cleanup if failed - SafeDelete(answMex); + SafeDel(answMex); } else if (!resp) { // Sleep a while before retrying int sleeptime = 1; @@ -1055,7 +1053,7 @@ bool XrdProofConn::Login() if (ug.length() > 8) { // The name must go in the attached buffer because the login structure // can accomodate at most 8 chars - strcpy( (char *)reqhdr.login.username, "?>buf" ); + strncpy( (char *)reqhdr.login.username, "?>buf", sizeof(reqhdr.login.username)); // Add the name to the login buffer, if not already done during // a previous login (for example if we are reconnecting ...) if (fLoginBuffer.find("|usr:") == STR_NPOS) { @@ -1066,7 +1064,7 @@ bool XrdProofConn::Login() memcpy((void *)reqhdr.login.username, (void *)(ug.c_str()), ug.length()); if (ug.length() < 8) reqhdr.login.username[ug.length()] = '\0'; } else { - strcpy((char *)reqhdr.login.username, "????" ); + strncpy((char *)reqhdr.login.username, "????", sizeof(reqhdr.login.username)); } // This is the place to send a token for fast authentication @@ -1183,15 +1181,14 @@ bool XrdProofConn::Login() // We failed the aythentication attempt: cannot continue notdone = 0; - if (plist) - delete[] plist; + delete[] plist; } else { // We are successfully done resp = 1; notdone = 0; } // Cleanup - SafeDelete(xrsp); + SafeDel(xrsp); } else { // We failed but we are done with this attempt resp = 0; @@ -1262,7 +1259,7 @@ XrdSecProtocol *XrdProofConn::Authenticate(char *plist, int plsiz) // Initialize the security library plugin, if needed XrdOucString libsec; if (!fgSecPlugin) { -#if ROOTXRDVERS >= ROOT_XrdUtils +#if !defined(ROOT_XrdNoUtils) libsec = "libXrdSec"; libsec += LT_MODULE_EXT; #else @@ -1321,7 +1318,7 @@ XrdSecProtocol *XrdProofConn::Authenticate(char *plist, int plsiz) reqhdr.header.dlen = (credentials) ? credentials->size : 0; char *credbuf = (credentials) ? credentials->buffer : 0; xrsp = SendReq(&reqhdr, credbuf, &srvans, "XrdProofConn::Authenticate"); - SafeDelete(credentials); + SafeDel(credentials); status = (xrsp) ? xrsp->HeaderStatus() : kXR_error; dlen = (xrsp) ? xrsp->DataLen() : 0; TRACE(HDBG, "server reply: status: "<<status<<" dlen: "<<dlen); @@ -1335,7 +1332,7 @@ XrdSecProtocol *XrdProofConn::Authenticate(char *plist, int plsiz) // // then get next part of the credentials credentials = protocol->getCredentials(secToken, &ei); - SafeDelete(secToken); // nb: srvans is released here + SafeDel(secToken); // nb: srvans is released here srvans = 0; if (!credentials) { TRACE(XERR, "cannot obtain credentials"); @@ -1349,7 +1346,7 @@ XrdSecProtocol *XrdProofConn::Authenticate(char *plist, int plsiz) // Server does not implement yet full cycling, so we are // allowed to try the handshake only for one protocol; we // cleanup the message and fail; - SafeDelete(xrsp); + SafeDel(xrsp); failed = 1; break; } else { @@ -1365,7 +1362,7 @@ XrdSecProtocol *XrdProofConn::Authenticate(char *plist, int plsiz) } } // Cleanup message - SafeDelete(xrsp); + SafeDel(xrsp); } // If we are done diff --git a/proof/proofd/src/XrdProofGroup.cxx b/proof/proofd/src/XrdProofGroup.cxx index bccc6863f9f11..321df5337e554 100644 --- a/proof/proofd/src/XrdProofGroup.cxx +++ b/proof/proofd/src/XrdProofGroup.cxx @@ -324,15 +324,20 @@ int XrdProofGroupMgr::Config(const char *fn) // Return the number of active groups or -1 in case of error. XPDLOC(GMGR, "GroupMgr::Config") - if (!fn || strlen(fn) <= 0) { - // This call is to reset existing info and remain with - // the 'default' group only - XrdSysMutexHelper mhp(fMutex); - // Reset existing info - fGroups.Purge(); - // Create "default" group - fGroups.Add("default", new XrdProofGroup("default")); - return fGroups.Num();; + if ((!fn || strlen(fn) <= 0)) { + if (fCfgFile.fName != fn) { + // This call is to reset existing info and remain with + // the 'default' group only + XrdSysMutexHelper mhp(fMutex); + // Reset existing info + fGroups.Purge(); + // Create "default" group + fGroups.Add("default", new XrdProofGroup("default")); + // Reset fCfgFile + fCfgFile.fName = ""; + fCfgFile.fMtime = 0; + } + return fGroups.Num(); } // Did the file changed ? diff --git a/proof/proofd/src/XrdProofSched.cxx b/proof/proofd/src/XrdProofSched.cxx index df9b5bddba479..b61ec9cc01e94 100644 --- a/proof/proofd/src/XrdProofSched.cxx +++ b/proof/proofd/src/XrdProofSched.cxx @@ -516,7 +516,7 @@ int XrdProofSched::GetWorkers(XrdProofdProofServ *xps, } } else { if (maxnum > 0) { - // This is over-conservative for sub-selectiob (random, or round-robin options) + // This is over-conservative for sub-selection (random, or round-robin options) // A better solution should be implemented for that. int nactsess = mst->GetNActiveSessions(); TRACE(REQ, "act sess ... " << nactsess); @@ -531,7 +531,7 @@ int XrdProofSched::GetWorkers(XrdProofdProofServ *xps, } // Make sure that something has been found - if (!acws || acws->size() <= 1) { + if (!acws || (acws && acws->size() <= 1)) { if (fUseFIFO) { // Enqueue the query/session // the returned list of workers was not filled @@ -540,17 +540,19 @@ int XrdProofSched::GetWorkers(XrdProofdProofServ *xps, if (TRACING(REQ)) xps->DumpQueries(); // Notify enqueing TRACE(REQ, "no workers currently available: session enqueued"); + SafeDel(acwseff); return 2; } else { TRACE(XERR, "no worker available: do nothing"); - if (acwseff) { delete acwseff; acwseff = 0; } + SafeDel(acwseff); return -1; } } - // If the session has already assigned workers just return - if (xps->Workers()->Num() > 0) { + // If a non-dynamic session already has assigned workers just return + if (!isDynamic && (xps->Workers()->Num() > 0)) { // Current assignement is valid + SafeDel(acwseff); return 1; } @@ -692,7 +694,8 @@ int XrdProofSched::Reschedule() // resume, assigning it workers and sending a resume message. // In this way there is not possibility of interference with other GetWorkers // return 0 in case of success and -1 in case of an error - XPDDOM(SCHED) + + XPDLOC(SCHED, "Sched::Reschedule") if (fUseFIFO && TRACING(DBG)) DumpQueues("Reschedule"); @@ -700,6 +703,10 @@ int XrdProofSched::Reschedule() // Any advanced scheduling algorithms can be done here XrdProofdProofServ *xps = FirstSession(); + if (!xps) { + TRACE(XERR, "got undefined session: protocol error!"); + return -1; + } XrdOucString wrks; // Call GetWorkers in the manager to mark the assignment. XrdOucString qtag; @@ -712,6 +719,7 @@ int XrdProofSched::Reschedule() } if (fMgr->GetWorkers(wrks, xps, qtag.c_str()) < 0 ) { // Something wrong + TRACE(XERR, "failure from GetWorkers: protocol error!"); return -1; } else { // Send buffer diff --git a/proof/proofd/src/XrdProofWorker.cxx b/proof/proofd/src/XrdProofWorker.cxx index 90b750d2b67f9..ef00e90890539 100644 --- a/proof/proofd/src/XrdProofWorker.cxx +++ b/proof/proofd/src/XrdProofWorker.cxx @@ -53,7 +53,7 @@ XrdProofWorker::~XrdProofWorker() { // Destructor - SafeDelete(fMutex); + SafeDel(fMutex); } //______________________________________________________________________________ diff --git a/proof/proofd/src/XrdProofdAdmin.cxx b/proof/proofd/src/XrdProofdAdmin.cxx index 0547252f328c0..48702e585375f 100644 --- a/proof/proofd/src/XrdProofdAdmin.cxx +++ b/proof/proofd/src/XrdProofdAdmin.cxx @@ -543,6 +543,7 @@ int XrdProofdAdmin::SetGroupProperties(XrdProofdProtocol *p) TRACEP(p, XERR, "received group does not match the user's one"); response->Send(kXR_InvalidRequest, "SetGroupProperties: received group does not match the user's one"); + SafeDelArray(grp); return 0; } @@ -558,6 +559,7 @@ int XrdProofdAdmin::SetGroupProperties(XrdProofdProtocol *p) TRACEP(p, XERR, "problem sending message on the pipe"); response->Send(kXR_ServerError, "SetGroupProperties: problem sending message on the pipe"); + SafeDelArray(grp); return 0; } } @@ -565,6 +567,8 @@ int XrdProofdAdmin::SetGroupProperties(XrdProofdProtocol *p) // Notify TRACEP(p, REQ, "priority for group '"<< grp<<"' has been set to "<<priority); + SafeDelArray(grp); + // Acknowledge user response->Send(); @@ -775,14 +779,27 @@ int XrdProofdAdmin::QueryLogPaths(XrdProofdProtocol *p) bool ismaster = (access(wfile.c_str(), F_OK) == 0) ? 1 : 0; // Scan the directory to add the top master (only if top master) - XrdOucString xo; - int ilog, idas; + XrdOucString xo, logtag; + int ilog, idas, iund1, iund2; struct dirent *ent = 0; while ((ent = (struct dirent *)readdir(dir))) { xo = ent->d_name; bool recordinfo = 0; if ((ilog = xo.find(".log")) != STR_NPOS) { xo.replace(".log", ""); + + // If it is an "additional" logfile, extract a "tag" identifying it + // from the filename. Tag is in format: __<tag>__ + iund1 = xo.find("__"); + if (iund1 != STR_NPOS) { + iund2 = xo.rfind("__"); + if ((iund2 != STR_NPOS) && (iund2 != iund1)) { + logtag = xo; + logtag.erase(iund2); + logtag.erase(0, iund1+2); + } + } + if ((idas = xo.find('-')) != STR_NPOS) xo.erase(0, idas + 1); if ((idas = xo.find('-')) != STR_NPOS) xo.erase(idas); if (ord.length() > 0 && (ord == xo)) { @@ -796,6 +813,7 @@ int XrdProofdAdmin::QueryLogPaths(XrdProofdProtocol *p) } if (recordinfo) { rmsg += "|"; rmsg += xo; + if (logtag != "") { rmsg += '('; rmsg += logtag; rmsg += ')'; } rmsg += " proof://"; rmsg += fMgr->Host(); rmsg += ':'; rmsg += fMgr->Port(); rmsg += '/'; rmsg += sdir; rmsg += '/'; rmsg += ent->d_name; @@ -1250,7 +1268,7 @@ int XrdProofdAdmin::Exec(XrdProofdProtocol *p) } } // Cleanup answer - SafeDelete(xrsp); + SafeDel(xrsp); } } @@ -1497,7 +1515,7 @@ int XrdProofdAdmin::ExecCmd(XrdProofdProtocol *p, XrdProofdResponse *r, // Fill the buffer and go char msg[256]; int islink = S_ISLNK(st.st_mode); - sprintf(msg, "%ld %ld %d %d %d %lld %ld %d", (long)st.st_dev, + snprintf(msg, 256, "%ld %ld %d %d %d %lld %ld %d", (long)st.st_dev, (long)st.st_ino, st.st_mode, (int)(st.st_uid), (int)(st.st_gid), (kXR_int64)st.st_size, st.st_mtime, islink); emsg = msg; @@ -1582,7 +1600,7 @@ int XrdProofdAdmin::ExecCmd(XrdProofdProtocol *p, XrdProofdResponse *r, } // Close the pipe int rcpc = 0; - if (rc == 0 && (rcpc = pclose(fp)) == -1) { + if ((rcpc = pclose(fp)) == -1) { emsg = "could not close the command pipe"; rc = 1; } @@ -1823,52 +1841,53 @@ int XrdProofdAdmin::GetFile(XrdProofdProtocol *p) } else { // Send the size as OK message char sizmsg[64]; - sprintf(sizmsg, "%lld", (kXR_int64) st.st_size); + snprintf(sizmsg, 64, "%lld", (kXR_int64) st.st_size); response->Send((const char *) &sizmsg[0]); TRACEP(p, XERR, "size is "<<sizmsg<<" bytes"); - } - // Now we send the content - const int kMAXBUF = 16384; - char buf[kMAXBUF]; - off_t pos = 0; - lseek(fd, pos, SEEK_SET); - - while (rc == 0 && pos < st.st_size) { - off_t left = st.st_size - pos; - if (left > kMAXBUF) left = kMAXBUF; - - int siz; - while ((siz = read(fd, &buf[0], left)) < 0 && errno == EINTR) - errno = 0; - if (siz < 0 || siz != left) { - emsg = "error reading from file: errno: "; - emsg += (int) errno; - rc = 1; - break; - } - int src = 0; - if ((src = response->Send(kXR_attn, kXPD_msg, (void *)&buf[0], left)) != 0) { - emsg = "error reading from file: errno: "; - emsg += src; - rc = 1; - break; + // Now we send the content + const int kMAXBUF = 16384; + char buf[kMAXBUF]; + off_t pos = 0; + lseek(fd, pos, SEEK_SET); + + while (rc == 0 && pos < st.st_size) { + off_t left = st.st_size - pos; + if (left > kMAXBUF) left = kMAXBUF; + + int siz; + while ((siz = read(fd, &buf[0], left)) < 0 && errno == EINTR) + errno = 0; + if (siz < 0 || siz != left) { + emsg = "error reading from file: errno: "; + emsg += (int) errno; + rc = 1; + break; + } + + int src = 0; + if ((src = response->Send(kXR_attn, kXPD_msg, (void *)&buf[0], left)) != 0) { + emsg = "error reading from file: errno: "; + emsg += src; + rc = 1; + break; + } + // Re-position + pos += left; + // Reset the timeout + if (pp.Post(0, "") != 0) { + rc = 1; + break; + } } - // Re-position - pos += left; - // Reset the timeout - if (pp.Post(0, "") != 0) { - rc = 1; - break; + // Close the file + close(fd); + // Send error, if any + if (rc != 0) { + TRACEP(p, XERR, emsg); + response->Send(kXR_attn, kXPD_srvmsg, 0, (char *) emsg.c_str(), emsg.length()); } } - // Close the file - close(fd); - // Send error, if any - if (rc != 0) { - TRACEP(p, XERR, emsg); - response->Send(kXR_attn, kXPD_srvmsg, 0, (char *) emsg.c_str(), emsg.length()); - } } // Send error, if any @@ -1983,7 +2002,7 @@ int XrdProofdAdmin::PutFile(XrdProofdProtocol *p) return 0; } // Extract size - sscanf(ssiz.c_str(), "%lld", &size); + size = atoll(ssiz.c_str()); if (size < 0) { TRACEP(p, XERR, "cannot resolve size!"); response->Send(kXR_InvalidRequest, "cannot resolve size!"); @@ -2419,7 +2438,7 @@ int XrdProofdAdmin::CpFile(XrdProofdProtocol *p) } // Close the pipe if not in error state (otherwise we may block here) int rcpc = 0; - if (rc == 0 && (rcpc = pclose(fp)) == -1) { + if ((rcpc = pclose(fp)) == -1) { emsg = "error while trying to close the command pipe"; rc = 1; } diff --git a/proof/proofd/src/XrdProofdAux.cxx b/proof/proofd/src/XrdProofdAux.cxx index 5639f412d1372..5aaca071cfdfd 100644 --- a/proof/proofd/src/XrdProofdAux.cxx +++ b/proof/proofd/src/XrdProofdAux.cxx @@ -15,7 +15,7 @@ // // // Authors: G. Ganis, CERN, 2007 // // // -// Small auxilliary classes used in XrdProof // +// Small auxiliary classes used in XrdProof // // // ////////////////////////////////////////////////////////////////////////// #include "XrdProofdPlatform.h" @@ -395,7 +395,7 @@ void XrdProofdAux::LogEmsgToFile(const char *flog, const char *emsg, const char if (flog && strlen(flog)) { // Open the file in write-only, append mode int logfd = open(flog, O_WRONLY|O_APPEND, 0644); - if (logfd > 0) { + if (logfd >= 0) { fcntl(logfd, F_SETFD, FD_CLOEXEC); // Attach a logger to the file XrdSysLogger logger(logfd, 0); @@ -431,43 +431,18 @@ int XrdProofdAux::AssertDir(const char *path, XrdProofUI ui, bool changeown) if (!path || strlen(path) <= 0) return -1; - - struct stat st; - if (stat(path,&st) != 0) { - if (errno == ENOENT) { - - { XrdSysPrivGuard pGuard((uid_t)0, (gid_t)0); - if (XpdBadPGuard(pGuard, ui.fUid) && changeown) { - TRACE(XERR, "could not get privileges to create dir"); - return -1; - } - - if (mkdir(path, 0755) != 0) { - TRACE(XERR, "unable to create dir: "<<path<<" (errno: "<<errno<<")"); - return -1; - } - } - if (stat(path,&st) != 0) { - TRACE(XERR, "unable to stat dir: "<<path<<" (errno: "<<errno<<")"); - return -1; - } - } else { - // Failure: stop - TRACE(XERR, "unable to stat dir: "<<path<<" (errno: "<<errno<<")"); - return -1; - } + XrdSysPrivGuard pGuard((uid_t)0, (gid_t)0); + if (XpdBadPGuard(pGuard, ui.fUid) && changeown) { + TRACE(XERR, "could not get privileges to change ownership"); + return -1; } - // Make sure the ownership is right - if (changeown && - ((int) st.st_uid != ui.fUid || (int) st.st_gid != ui.fGid)) { - - XrdSysPrivGuard pGuard((uid_t)0, (gid_t)0); - if (XpdBadPGuard(pGuard, ui.fUid)) { - TRACE(XERR, "could not get privileges to change ownership"); - return -1; - } + if (mkdir(path, 0755) != 0 && (errno != EEXIST)) { + TRACE(XERR, "unable to create dir: "<<path<<" (errno: "<<errno<<")"); + return -1; + } + if (changeown) { // Set ownership of the path to the client if (chown(path, ui.fUid, ui.fGid) == -1) { TRACE(XERR, "cannot set user ownership on path (errno: "<<errno<<")"); @@ -535,22 +510,9 @@ int XrdProofdAux::ChangeOwn(const char *path, XrdProofUI ui) if (!path || strlen(path) <= 0) return -1; - - struct stat st; - if (stat(path,&st) != 0) { - // Failure: stop - TRACE(XERR, "unable to stat path: "<<path<<" (errno: "<<errno<<")"); - return -1; - } - - // If is a directory apply this on it - if (S_ISDIR(st.st_mode)) { + DIR *dir = opendir(path); + if (dir) { // Loop over the dir - DIR *dir = opendir(path); - if (!dir) { - TRACE(XERR,"cannot open "<<path<< "- errno: "<< errno); - return -1; - } XrdOucString proot(path); if (!proot.endswith('/')) proot += "/"; @@ -560,38 +522,22 @@ int XrdProofdAux::ChangeOwn(const char *path, XrdProofUI ui) XrdOucString fn(proot); fn += ent->d_name; - struct stat xst; - if (stat(fn.c_str(),&xst) == 0) { - // If is a directory apply this on it - if (S_ISDIR(xst.st_mode)) { - if (XrdProofdAux::ChangeOwn(fn.c_str(), ui) != 0) { - TRACE(XERR, "problems changing recursively ownership of: "<<fn); - closedir(dir); - return -1; - } - } else { - // Get the privileges, if needed - XrdSysPrivGuard pGuard((uid_t)0, (gid_t)0); - if (XpdBadPGuard(pGuard, ui.fUid)) { - TRACE(XERR, "could not get privileges to change ownership"); - closedir(dir); - return -1; - } - // Set ownership of the path to the client - if (chown(fn.c_str(), ui.fUid, ui.fGid) == -1) { - closedir(dir); - TRACE(XERR, "cannot set user ownership on path (errno: "<<errno<<")"); - return -1; - } - } - } else { - TRACE(XERR, "unable to stat dir: "<<fn<<" (errno: "<<errno<<")"); + // Apply recursively + if (XrdProofdAux::ChangeOwn(fn.c_str(), ui) != 0) { + TRACE(XERR, "problems changing recursively ownership of: "<<fn); + closedir(dir); + return -1; } } // Close the directory closedir(dir); - } else if (((int) st.st_uid != ui.fUid) || ((int) st.st_gid != ui.fGid)) { + } else { + // If it was a directory and opening failed, we fail + if (errno != 0 && (errno != ENOTDIR)) { + TRACE(XERR,"cannot open "<<path<< "- errno: "<< errno); + return -1; + } // Get the privileges, if needed XrdSysPrivGuard pGuard((uid_t)0, (gid_t)0); if (XpdBadPGuard(pGuard, ui.fUid)) { @@ -604,7 +550,6 @@ int XrdProofdAux::ChangeOwn(const char *path, XrdProofUI ui) return -1; } } - // We are done return 0; } @@ -1157,8 +1102,10 @@ int XrdProofdAux::GetIDFromPath(const char *path, XrdOucString &emsg) FILE *fid = fopen(path, "r"); if (fid) { char line[64]; - if (fgets(line, sizeof(line), fid)) - sscanf(line, "%d", &id); + if (fgets(line, sizeof(line), fid)) { + if (line[strlen(line)-1] == '\n') line[strlen(line)-1] = 0; + id = atoi(line); + } fclose(fid); } else if (errno != ENOENT) { XPDFORM(emsg, "GetIDFromPath: error reading id from: %s (errno: %d)", @@ -1485,18 +1432,10 @@ int XrdProofdAux::MvDir(const char *oldpath, const char *newpath) if (S_ISDIR(st.st_mode)) { mode_t srcmode = st.st_mode; // Create dest sub-dir - if (stat(dstentry.c_str(), &st) == 0) { - if (!S_ISDIR(st.st_mode)) { - TRACE(XERR, "destination path already exists and is not a directory: "<<dstentry); - rc = -ENOTDIR; - break; - } - } else { - if (mkdir(dstentry.c_str(), srcmode) != 0) { - TRACE(XERR, "cannot create entry "<<dstentry<<" ; error: "<<errno); - rc = -errno; - break; - } + if (mkdir(dstentry.c_str(), srcmode) != 0 && (errno != EEXIST)) { + TRACE(XERR, "cannot create entry "<<dstentry<<" ; error: "<<errno); + rc = -errno; + break; } if ((rc = XrdProofdAux::MvDir(srcentry.c_str(), dstentry.c_str())) != 0) { TRACE(XERR, "problems moving "<<srcentry<<" to "<<dstentry<<"; error: "<<-rc); @@ -1584,7 +1523,7 @@ int XrdProofdAux::ReadMsg(int fd, XrdOucString &msg) msg += buf; } // Update counters - len -= nr; + len = (nr >= len) ? 0 : len - nr; } while (nr > 0 && len > 0); TRACE(HDBG,fd<<": buf: "<<buf); @@ -1603,10 +1542,12 @@ int XrdProofdAux::ParsePidPath(const char *path, { // Parse a path in the form of "<before>[.<pid>][.<after>]", filling 'rest' // and returning 'pid'. - // Return 0 if pid is not defined; 'before' is filled with the string preceeding + // Return 0 if pid is not defined; 'before' is filled with the string preceding // <pid>, <after> with the string following <pid>. XPDLOC(AUX, "ParsePidPath") + before = ""; + after = ""; long int pid = -1; if (path && strlen(path)) { pid = 0; @@ -1640,7 +1581,8 @@ int XrdProofdAux::ParsePidPath(const char *path, } } - TRACE(HDBG,"path: "<<path<<" --> before: '"<<before<<"', pid: "<<pid<<", after: '"<<after<<"'"); + TRACE(HDBG,"path: "<<(path ? path : "<nul>")<<" --> before: '"<<before + <<"', pid: "<<pid<<", after: '"<<after<<"'"); // Done return pid; @@ -2321,19 +2263,19 @@ void XrdProofdAux::Form(XrdOucString &s, const char *fmt, } } else if (s[k+1] == 'd') { if (nii < ni) { - sprintf(si,"%d", ii[nii++]); + snprintf(si, 32, "%d", ii[nii++]); s.replace("%d", si, k, k + 1); replaced = 1; } } else if (s[k+1] == 'u') { if (nui < nu) { - sprintf(si,"%u", ui); + snprintf(si, 32, "%u", ui); s.replace("%u", si, k, k + 1); replaced = 1; } } else if (s[k+1] == 'p') { if (npp < np) { - sprintf(sp,"%p", pp[npp++]); + snprintf(sp, 32, "%p", pp[npp++]); s.replace("%p", sp, k, k + 1); replaced = 1; } diff --git a/proof/proofd/src/XrdProofdClient.cxx b/proof/proofd/src/XrdProofdClient.cxx index ce80b03990e8c..0068222edfca2 100644 --- a/proof/proofd/src/XrdProofdClient.cxx +++ b/proof/proofd/src/XrdProofdClient.cxx @@ -34,7 +34,7 @@ //__________________________________________________________________________ XrdProofdClient::XrdProofdClient(XrdProofUI ui, bool master, bool changeown, - XrdSysError *, const char *adminpath) + XrdSysError *, const char *adminpath, int rtime) : fSandbox(ui, master, changeown) { // Constructor @@ -48,6 +48,7 @@ XrdProofdClient::XrdProofdClient(XrdProofUI ui, bool master, bool changeown, fAskedToTouch = 0; fChangeOwn = changeown; fLauncher = 0; + fReconnectTimeOut = rtime; // Make sure the admin path exists XPDFORM(fAdminPath, "%s/%s.%s", adminpath, ui.fUser.c_str(), ui.fGroup.c_str()); @@ -64,7 +65,7 @@ XrdProofdClient::XrdProofdClient(XrdProofUI ui, bool master, bool changeown, // We must have a valid sandbox if (fSandbox.IsValid()) fIsValid = 1; - // The session launcher (we may have a plugin here, on day ...) + // The session launcher (we may have a plugin here, one day ...) fLauncher = new XrdProofdLauncher(this); } @@ -73,6 +74,7 @@ XrdProofdClient::~XrdProofdClient() { // Destructor + SafeDel(fLauncher); } //__________________________________________________________________________ @@ -103,6 +105,11 @@ int XrdProofdClient::GetClientID(XrdProofdProtocol *p) // Search for free places in the existing vector for (ic = 0; ic < (int)fClients.size() ; ic++) { if (fClients[ic] && !fClients[ic]->IsValid()) { + int rtime = fClients[ic]->ResetTime(); + if ((rtime >= 0) && ((time(0) - rtime) < fReconnectTimeOut)) { + // The session using this cid disconnected too recently, do not reuse yet + continue; + } cid = fClients[ic]; cid->Reset(); break; @@ -266,8 +273,10 @@ XrdProofdProofServ *XrdProofdClient::GetServObj(int id) xps = fProofServs[id]; } } - xps->SetID(id); - xps->SetValid(); + if (xps) { + xps->SetID(id); + xps->SetValid(); + } if (TRACING(DBG)) { { XrdSysMutexHelper mh(fMutex); if (fIsValid) { @@ -385,7 +394,7 @@ int XrdProofdClient::ResetClientSlot(int ic) //______________________________________________________________________________ XrdProofdProtocol *XrdProofdClient::GetProtocol(int ic) { - // Reset slot at 'ic' + // Return protocol attached to client slot at 'ic' XPDLOC(CMGR, "Client::GetProtocol") TRACE(DBG, "enter: ic: " << ic); diff --git a/proof/proofd/src/XrdProofdClientMgr.cxx b/proof/proofd/src/XrdProofdClientMgr.cxx index 28d978e155fc6..982fc158363f3 100644 --- a/proof/proofd/src/XrdProofdClientMgr.cxx +++ b/proof/proofd/src/XrdProofdClientMgr.cxx @@ -33,6 +33,7 @@ #include "XrdOuc/XrdOucErrInfo.hh" #include "XrdOuc/XrdOucStream.hh" #include "XrdSec/XrdSecInterface.hh" +#include "XrdSys/XrdSysPlugin.hh" #include "XrdProofdClient.h" #include "XrdProofdClientMgr.h" @@ -71,7 +72,7 @@ void *XrdProofdClientCron(void *p) return (void *)0; } XrdProofdProofServMgr *smgr = mc->fSessionMgr; - if (!(mgr)) { + if (!(smgr)) { TRACE(REQ, "undefined session manager: cannot start"); return (void *)0; } @@ -93,45 +94,9 @@ void *XrdProofdClientCron(void *p) continue; } // Parse type - XrdOucString buf; if (msg.Type() == XrdProofdClientMgr::kClientDisconnect) { - // Read admin path and pointer to the client instance - XrdOucString adminpath; - rc = msg.Get(adminpath); - void *cp = 0; - rc = (rc == 0) ? msg.Get(&cp) : rc; - XrdProofdClient *c = (XrdProofdClient *)cp; - int cid = -1; - rc = (rc == 0) ? msg.Get(cid) : rc; - int pid = -1; - rc = (rc == 0) ? msg.Get(pid) : rc; - if (rc != 0) { - TRACE(XERR, "kClientDisconnect: problems parsing message: '"<< - msg.Buf()<<"'; errno: "<<-rc); - continue; - } - TRACE(DBG, "kClientDisconnect: got: '"<<adminpath<<"', "<<c<<", "<<cid); - if (c) { - // Reset the corresponding client slot in the list of this client - c->ResetClientSlot(cid); - } else { - TRACE(XERR, "kClientDisconnect: problems getting pointer to client instance: "<<c); - } - - // Remove the client admin path - if (adminpath != "????") { - adminpath.erase(adminpath.rfind("/cid")); - if ((rc = XrdProofdAux::RmDir(adminpath.c_str())) != 0) { - TRACE(XERR, "kClientDisconnect: problems removing admin path; errno: "<<-rc); - continue; - } - } - - // Tell the session manager that a client has gone - XPDFORM(buf, "%d", pid); - smgr->Pipe()->Post(XrdProofdProofServMgr::kClientDisconnect, buf.c_str()); - TRACE(DBG,"sending to ProofServMgr: "<<buf); - + // Obsolete + TRACE(XERR, "obsolete type: XrdProofdClientMgr::kClientDisconnect"); } else { TRACE(XERR, "unknown type: "<<msg.Type()); continue; @@ -151,7 +116,7 @@ void *XrdProofdClientCron(void *p) //______________________________________________________________________________ XrdProofdClientMgr::XrdProofdClientMgr(XrdProofdManager *mgr, XrdProtocol_Config *pi, XrdSysError *e) - : XrdProofdConfig(pi->ConfigFN, e) + : XrdProofdConfig(pi->ConfigFN, e), fSecPlugin(0) { // Constructor XPDLOC(CMGR, "XrdProofdClientMgr") @@ -335,7 +300,7 @@ int XrdProofdClientMgr::Login(XrdProofdProtocol *p) TRACEP(p, HDBG, "enter"); - // If this server is explicitely required to be a worker node or a + // If this server is explicitly required to be a worker node or a // submaster, check whether the requesting host is allowed to connect if (p->Request()->login.role[0] != 'i' && (fMgr->SrvType() == kXPD_MasterWorker || fMgr->SrvType() == kXPD_Master)) { @@ -382,6 +347,13 @@ int XrdProofdClientMgr::Login(XrdProofdProtocol *p) return 0; } + TRACE(ALL," hostname: '"<<p->Link()->Host()<<"'"); + // + // Check if in any-server mode (localhost connections always are) + bool anyserver = (fMgr->SrvType() == kXPD_AnyServer || + !strcmp(p->Link()->Host(), "localhost") || + !strcmp(p->Link()->Host(), "127.0.0.0")) ? 1 : 0; + // Find out the connection type: 'i', internal, means this is a proofsrv calling back. bool needauth = 0; bool ismaster = (fMgr->SrvType() == kXPD_TopMaster || fMgr->SrvType() == kXPD_Master) ? 1 : 0; @@ -395,7 +367,7 @@ int XrdProofdClientMgr::Login(XrdProofdProtocol *p) response->SetTag("int"); break; case 'M': - if (fMgr->SrvType() == kXPD_AnyServer || ismaster) { + if (anyserver || ismaster) { p->SetConnType(kXPD_ClientMaster); needauth = 1; response->SetTag("m2c"); @@ -407,7 +379,7 @@ int XrdProofdClientMgr::Login(XrdProofdProtocol *p) } break; case 'm': - if (fMgr->SrvType() == kXPD_AnyServer || ismaster) { + if (anyserver || ismaster) { p->SetConnType(kXPD_MasterMaster); needauth = 1; response->SetTag("m2m"); @@ -419,7 +391,7 @@ int XrdProofdClientMgr::Login(XrdProofdProtocol *p) } break; case 's': - if (fMgr->SrvType() == kXPD_AnyServer || fMgr->SrvType() == kXPD_MasterWorker) { + if (anyserver || fMgr->SrvType() == kXPD_MasterWorker) { p->SetConnType(kXPD_MasterWorker); needauth = 1; response->SetTag("w2m"); @@ -496,26 +468,22 @@ int XrdProofdClientMgr::Login(XrdProofdProtocol *p) response->SendI((kXR_int32)XPROOFD_VERSBIN, (void *)pp, i); p->SetStatus((XPD_NEED_MAP | XPD_NEED_AUTH)); return 0; - } else { - response->SendI((kXR_int32)XPROOFD_VERSBIN); - p->SetStatus(XPD_LOGGEDIN); - if (pp) - p->SetAuthEntity(); - } - } else { - // Check the client at theis point; the XrdProofdClient instance is created - // in here, if everything else goes well - int rccc = 0; - if ((rccc = CheckClient(p, p->UserIn(), emsg)) != 0) { - TRACEP(p, XERR, emsg); - XErrorCode rcode = (rccc == -2) ? (XErrorCode) kXR_NotAuthorized - : (XErrorCode) kXR_InvalidRequest; - response->Send(rcode, emsg.c_str()); - return 0; + } else if (pp) { + p->SetAuthEntity(); } - rc = response->SendI((kXR_int32)XPROOFD_VERSBIN); - p->SetStatus(XPD_LOGGEDIN); } + // Check the client at this point; the XrdProofdClient instance is created + // in here, if everything else goes well + int rccc = 0; + if ((rccc = CheckClient(p, p->UserIn(), emsg)) != 0) { + TRACEP(p, XERR, emsg); + XErrorCode rcode = (rccc == -2) ? (XErrorCode) kXR_NotAuthorized + : (XErrorCode) kXR_InvalidRequest; + response->Send(rcode, emsg.c_str()); + return 0; + } + rc = response->SendI((kXR_int32)XPROOFD_VERSBIN); + p->SetStatus(XPD_LOGGEDIN); // Map the client return MapClient(p, 1); @@ -595,7 +563,7 @@ int XrdProofdClientMgr::CheckClient(XrdProofdProtocol *p, c->SetROOT(fMgr->ROOTMgr()->DefaultVersion()); if (c->IsValid()) { // Set the group, if any - c->SetGroup(g->Name()); + c->SetGroup(gname.c_str()); } } else { emsg = "unable to instantiate object for client "; @@ -711,7 +679,7 @@ int XrdProofdClientMgr::MapClient(XrdProofdProtocol *p, bool all) TRACEP(p, XERR, msg.c_str()); } // Update counters - fNDisconnected--; + if(fNDisconnected) fNDisconnected--; } else { // The index of the next free slot will be the unique ID @@ -803,12 +771,16 @@ int XrdProofdClientMgr::CheckAdminPath(XrdProofdProtocol *p, // Create the path now XPDFORM(cidpath, "%s/%s/cid", p->Client()->AdminPath(), lid.c_str()); - // Check last access time - int rc = 0; + // Create disconnected path + XrdOucString discpath; + XPDFORM(discpath, "%s/%s/disconnected", p->Client()->AdminPath(), lid.c_str()); + + // Check last access time of disconnected if available, otherwise cid bool expired = false; struct stat st; - if ((rc = stat(cidpath.c_str(), &st)) != 0 || - (expired = ((int)(time(0) - st.st_atime) > fReconnectTimeOut))) { + int rc = stat(discpath.c_str(), &st); + if (rc != 0) rc = stat(cidpath.c_str(), &st); + if (rc != 0 || (expired = ((int)(time(0) - st.st_atime) > fReconnectTimeOut))) { if (expired || (rc != 0 && errno != ENOENT)) { // Remove the file cidpath.replace("/cid", ""); @@ -901,8 +873,9 @@ int XrdProofdClientMgr::ParsePreviousClients(XrdOucString &emsg) if (!fd) { TRACE(XERR, "unable to create path: " <<discpath); xrm = 1; + } else { + fclose(fd); } - fclose(fd); if (!xrm) fNDisconnected++; } @@ -1006,13 +979,6 @@ int XrdProofdClientMgr::CheckClients() // during last cycle and it did not do it, so we close // the link xclose = 1; - // This clients looks like disconnected - FILE *fd = fopen(discpath.c_str(), "w"); - if (!fd) { - TRACE(XERR, "unable to create path: " <<discpath); - } else { - fclose(fd); - } } } } @@ -1020,14 +986,6 @@ int XrdProofdClientMgr::CheckClients() // No id info, clean xrm = 1; } - // If too old remove the entry - if (xrm) { - discpath.replace("/disconnected", ""); - TRACE(DBG, "removing path "<<discpath); - if ((rc = XrdProofdAux::RmDir(discpath.c_str())) != 0) { - TRACE(XERR, "problems removing "<<discpath<<"; error: "<<-rc); - } - } // If inactive since too long, close the associated link if (xclose) { // Get the client id @@ -1044,11 +1002,15 @@ int XrdProofdClientMgr::CheckClients() p->Link()->Close(); } else { TRACE(XERR, "protocol or link associated with ID "<<cid<<" are invalid"); + xrm = 1; } } else { TRACE(XERR, "could not resolve client id from "<<cidpath); + xrm = 1; } - + } + // If too old remove the entry + if (xrm) { discpath.replace("/disconnected", ""); TRACE(DBG, "removing path "<<discpath); if ((rc = XrdProofdAux::RmDir(discpath.c_str())) != 0) { @@ -1113,8 +1075,9 @@ int XrdProofdClientMgr::Auth(XrdProofdProtocol *p) p->AuthProt()->Entity.tident = p->Link()->ID; } // Set the wanted login name - char *u = new char[strlen("XrdSecLOGINUSER=")+strlen(p->UserIn())+2]; - sprintf(u, "XrdSecLOGINUSER=%s", p->UserIn()); + size_t len = strlen("XrdSecLOGINUSER=")+strlen(p->UserIn())+2; + char *u = new char[len]; + snprintf(u, len, "XrdSecLOGINUSER=%s", p->UserIn()); putenv(u); // Now try to authenticate the client using the current protocol @@ -1218,18 +1181,17 @@ XrdSecService *XrdProofdClientMgr::LoadSecurity() return 0; } - // Open the security library - void *lh = 0; - if (!(lh = dlopen(seclib, RTLD_NOW))) { - TRACE(XERR, dlerror()<<" opening shared library "<< seclib); - return 0; + // Create the plug-in instance + if (!(fSecPlugin = new XrdSysPlugin((fEDest ? fEDest : (XrdSysError *)0), seclib))) { + TRACE(XERR, "could not create plugin instance for "<<seclib); + return (XrdSecService *)0; } - // Get the server object creator - XrdSecServLoader_t ep = 0; - if (!(ep = (XrdSecServLoader_t)dlsym(lh, "XrdSecgetService"))) { - TRACE(XERR, dlerror() <<" finding XrdSecgetService() in "<<seclib); - return 0; + // Get the function + XrdSecServLoader_t ep = (XrdSecServLoader_t) fSecPlugin->getPlugin("XrdSecgetService"); + if (!ep) { + TRACE(XERR, "could not find 'XrdSecgetService()' in "<<seclib); + return (XrdSecService *)0; } // Extract in a temporary file the directives prefixed "xpd.sec..." (filtering @@ -1237,6 +1199,7 @@ XrdSecService *XrdProofdClientMgr::LoadSecurity() int nd = 0; char *rcfn = FilterSecConfig(nd); if (!rcfn) { + SafeDelete(fSecPlugin); if (nd == 0) { // No directives to be processed TRACE(XERR, "no security directives: strong authentication disabled"); @@ -1251,6 +1214,9 @@ XrdSecService *XrdProofdClientMgr::LoadSecurity() XrdSecService *cia = 0; if (!(cia = (*ep)((fEDest ? fEDest->logger() : (XrdSysLogger *)0), rcfn))) { TRACE(XERR, "Unable to create security service object via " << seclib); + SafeDelete(fSecPlugin); + unlink(rcfn); + delete[] rcfn; return 0; } // Notify @@ -1305,15 +1271,19 @@ char *XrdProofdClientMgr::FilterSecConfig(int &nd) nd++; // Create the output file, if not yet done if (!rcfn) { - rcfn = new char[strlen(fMgr->TMPdir()) + strlen("/xpdcfn_XXXXXX") + 2]; - sprintf(rcfn, "%s/xpdcfn_XXXXXX", fMgr->TMPdir()); + size_t len = strlen(fMgr->TMPdir()) + strlen("/xpdcfn_XXXXXX") + 2; + rcfn = new char[len]; + snprintf(rcfn, len, "%s/xpdcfn_XXXXXX", fMgr->TMPdir()); + mode_t oldum = umask(022); if ((fd = mkstemp(rcfn)) < 0) { delete[] rcfn; nd = (errno > 0) ? -errno : -1; fclose(fin); rcfn = 0; + oldum = umask(oldum); return rcfn; } + oldum = umask(oldum); } XrdOucString slin = lin; // Strip the prefix "xpd." @@ -1327,7 +1297,7 @@ char *XrdProofdClientMgr::FilterSecConfig(int &nd) // Close files fclose(fin); - close(fd); + if (fd >= 0) close(fd); return rcfn; } @@ -1365,7 +1335,7 @@ XrdProofdClient *XrdProofdClientMgr::GetClient(const char *usr, const char *grp, ui.fUser = usr; ui.fGroup = grp; bool full = (fMgr->SrvType() != kXPD_Worker) ? 1 : 0; - c = new XrdProofdClient(ui, full, fMgr->ChangeOwn(), fEDest, fClntAdminPath.c_str()); + c = new XrdProofdClient(ui, full, fMgr->ChangeOwn(), fEDest, fClntAdminPath.c_str(), fReconnectTimeOut); newclient = 1; bool freeclient = 1; if (c && c->IsValid()) { diff --git a/proof/proofd/src/XrdProofdConfig.cxx b/proof/proofd/src/XrdProofdConfig.cxx index d5af57a401597..ec2292a5ef037 100644 --- a/proof/proofd/src/XrdProofdConfig.cxx +++ b/proof/proofd/src/XrdProofdConfig.cxx @@ -156,6 +156,7 @@ int XrdProofdConfig::ParseFile(bool rcf) } } } + close(cfgFD); // Done return 0; diff --git a/proof/proofd/src/XrdProofdLauncher.cxx b/proof/proofd/src/XrdProofdLauncher.cxx index 9aad84c687367..9399634831c7b 100644 --- a/proof/proofd/src/XrdProofdLauncher.cxx +++ b/proof/proofd/src/XrdProofdLauncher.cxx @@ -73,11 +73,12 @@ XrdNetPeer *XrdProofdLauncher::Launch(ProofdLaunch_t *in, int &pid) // Create server socket to get the call back rpdunixsrv *unixsrv = new rpdunixsrv(xps->UNIXSockPath()); - if (!unixsrv || !unixsrv->isvalid(0)) { + if (!unixsrv || (unixsrv && !unixsrv->isvalid(0))) { XPDFORM(emsg, "could not start unix server connection on path '%s' (errno: %d)", xps->UNIXSockPath(), (int)errno); TRACE(XERR, emsg); XrdProofdAux::LogEmsgToFile(in->fErrLog.c_str(), emsg.c_str(), npfx.c_str()); + SafeDel(unixsrv); return peer; } @@ -92,6 +93,7 @@ XrdNetPeer *XrdProofdLauncher::Launch(ProofdLaunch_t *in, int &pid) XPDFORM(emsg, "failure from 'system' (errno: %d)", (int)errno); TRACE(XERR, emsg); XrdProofdAux::LogEmsgToFile(in->fErrLog.c_str(), emsg.c_str(), npfx.c_str()); + SafeDel(unixsrv); return peer; } @@ -99,12 +101,14 @@ XrdNetPeer *XrdProofdLauncher::Launch(ProofdLaunch_t *in, int &pid) // Accept a connection from the second server int err; rpdunix *uconn = unixsrv->accept(in->fIntWait, &err); - if (!uconn || !uconn->isvalid(0)) { + if (!uconn || (uconn && !uconn->isvalid(0))) { XPDFORM(emsg, "failure accepting callback (errno: %d)", -err); TRACE(XERR, emsg); XrdProofdAux::LogEmsgToFile(in->fErrLog.c_str(), emsg.c_str(), npfx.c_str()); + SafeDel(uconn); return peer; } + SafeDel(unixsrv); TRACE(ALL, "proofserv connected!"); // diff --git a/proof/proofd/src/XrdProofdManager.cxx b/proof/proofd/src/XrdProofdManager.cxx index ddf0b0ce7277e..4961a3e72743c 100644 --- a/proof/proofd/src/XrdProofdManager.cxx +++ b/proof/proofd/src/XrdProofdManager.cxx @@ -123,6 +123,7 @@ XrdProofdManager::XrdProofdManager(XrdProtocol_Config *pi, XrdSysError *edest) fPort = XPD_DEF_PORT; fImage = ""; // image name for these servers fSockPathDir = ""; + fStageReqRepo = ""; fTMPdir = "/tmp"; fWorkDir = ""; fMUWorkDir = ""; @@ -137,6 +138,7 @@ XrdProofdManager::XrdProofdManager(XrdProtocol_Config *pi, XrdSysError *edest) // Data dir fDataDir = ""; // Default <workdir>/<user>/data fDataDirOpts = ""; // Default: no action + fDataDirUrlOpts = ""; // Default: none // Rootd file serving enabled by default in readonly mode fRootdExe = "<>"; @@ -338,7 +340,7 @@ int XrdProofdManager::CheckUser(const char *usr, const char *grp, // Policy: check first the general directive for groups; a user of a specific group // (both UNIX or PROOF groups) can be rejected by prefixing a '-'. // The group check fails if active (the allowedgroups directive has entries) and at - // least of the two groups (UNIX or PROOF) are explicitely denied. + // least of the two groups (UNIX or PROOF) are explicitly denied. // The result of the group check is superseeded by any explicit speicification in the // allowedusers, either positive or negative. // @@ -352,13 +354,13 @@ int XrdProofdManager::CheckUser(const char *usr, const char *grp, // User 'katy' is allowed because part of PROOF group 'student'; // users 'jack' and 'john' are denied because not part of PROOF group 'student' (no 'allowedusers' directive) // 3. xpd.allowedgroups alfa,-student - // User 'katy' is denied because part of PROOF group 'student' which is explicitely denied; + // User 'katy' is denied because part of PROOF group 'student' which is explicitly denied; // users 'jack' and 'john' are allowed becasue part of UNIX group 'alfa' (no 'allowedusers' directive) // 4. xpd.allowedgroups alfa,-student // xpd.allowedusers katy,-jack - // User 'katy' is allowed because explicitely allowed by the 'allowedusers' directive; - // user 'jack' is denied because explicitely denied by the 'allowedusers' directive; - // user 'john' is allowed because part of 'alfa' and not explicitely denied by the 'allowedusers' directive + // User 'katy' is allowed because explicitly allowed by the 'allowedusers' directive; + // user 'jack' is denied because explicitly denied by the 'allowedusers' directive; + // user 'john' is allowed because part of 'alfa' and not explicitly denied by the 'allowedusers' directive // (the allowedgroups directive is in this case ignored for users 'katy' and 'jack'). bool grpok = 1; @@ -428,7 +430,7 @@ int XrdProofdManager::CheckUser(const char *usr, const char *grp, usrok = 1; e = ""; } - // We fail if either the user is explicitely denied or it is not explicitely allowed + // We fail if either the user is explicitly denied or it is not explicitly allowed // and the group is denied if (usrok == -1 || (!grpok && usrok != 1)) return -1; } @@ -473,6 +475,7 @@ XrdProofSched *XrdProofdManager::LoadScheduler() } } } + close(cfgFD); } else { XPDFORM(m, "failure opening config file; errno: %d", errno); TRACE(XERR, m); @@ -504,12 +507,14 @@ XrdProofSched *XrdProofdManager::LoadScheduler() // Get the scheduler object if (!(sched = (*ep)(cfn, this, fGroupsMgr, cfn, fEDest))) { TRACE(XERR, "unable to create scheduler object from " << lib); + delete h; return (XrdProofSched *)0; } + delete h; } // Check result if (!(sched->IsValid())) { - TRACE(XERR, " unable to instantiate the " << sched->Name() << " scheduler using " << cfn); + TRACE(XERR, " unable to instantiate the " << sched->Name() << " scheduler using " << (cfn ? cfn : "<nul>")); delete sched; return (XrdProofSched *)0; } @@ -747,20 +752,23 @@ int XrdProofdManager::Config(bool rcf) // Data directory, if specified if (fDataDir.length() > 0) { - // Make sure it exists - if (XrdProofdAux::AssertDir(fDataDir.c_str(), ui, fChangeOwn) != 0) { - XPDERR("unable to assert data dir: " << fDataDir); - return -1; - } - // Get the right privileges now - XrdSysPrivGuard pGuard((uid_t)ui.fUid, (gid_t)ui.fGid); - if (XpdBadPGuard(pGuard, ui.fUid)) { - TRACE(XERR, "could not get privileges to set/change ownership of " << fDataDir); - return -1; - } - if (chmod(fDataDir.c_str(), 0777) != 0) { - XPDERR("problems setting permissions 0777 data dir: " << fDataDir); - return -1; + if (fDataDir.endswith('/')) fDataDir.erasefromend(1); + if (fDataDirOpts.length() > 0) { + // Make sure it exists + if (XrdProofdAux::AssertDir(fDataDir.c_str(), ui, fChangeOwn) != 0) { + XPDERR("unable to assert data dir: " << fDataDir << " (opts: "<<fDataDirOpts<<")"); + return -1; + } + // Get the right privileges now + XrdSysPrivGuard pGuard((uid_t)ui.fUid, (gid_t)ui.fGid); + if (XpdBadPGuard(pGuard, ui.fUid)) { + TRACE(XERR, "could not get privileges to set/change ownership of " << fDataDir); + return -1; + } + if (chmod(fDataDir.c_str(), 0777) != 0) { + XPDERR("problems setting permissions 0777 data dir: " << fDataDir); + return -1; + } } TRACE(ALL, "data directories under: " << fDataDir); } @@ -804,18 +812,25 @@ int XrdProofdManager::Config(bool rcf) std::list<XrdProofdDSInfo *>::iterator ii = fDataSetSrcs.begin(); bool goodsrc = 0; for (ii = fDataSetSrcs.begin(); ii != fDataSetSrcs.end();) { - if (!(goodsrc = ValidateLocalDataSetSrc((*ii)->fUrl, (*ii)->fLocal))) { - XPDERR("source " << (*ii)->fUrl << " could not be validated"); - ii = fDataSetSrcs.erase(ii); + TRACE(ALL, ">> Defined dataset: " << (*ii)->ToString()); + if ((*ii)->fType == "file") { + if (!(goodsrc = ValidateLocalDataSetSrc((*ii)->fUrl, (*ii)->fLocal))) { + XPDERR("source " << (*ii)->fUrl << " could not be validated"); + ii = fDataSetSrcs.erase(ii); + } else { + // Check next + ii++; + } } else { - // Check next + // Validate only "file" datasets + TRACE(ALL, "Skipping validation (no \"file\" type dataset source)"); ii++; } } if (fDataSetSrcs.size() > 0) { TRACE(ALL, fDataSetSrcs.size() << " dataset sources defined"); for (ii = fDataSetSrcs.begin(); ii != fDataSetSrcs.end(); ii++) { - TRACE(ALL, " url:" << (*ii)->fUrl << ", local:" << (*ii)->fLocal << ", rw:" << (*ii)->fRW); + TRACE(ALL, ">> Valid dataset: " << (*ii)->ToString()); if ((*ii)->fLocal && (*ii)->fRW) { if (fDataSetExp.length() > 0) fDataSetExp += ","; fDataSetExp += ((*ii)->fUrl).c_str(); @@ -935,7 +950,7 @@ int XrdProofdManager::Config(bool rcf) // Groups if (!fGroupsMgr) - // Create default group, if none explicitely requested + // Create default group, if none explicitly requested fGroupsMgr = new XrdProofGroupMgr; if (fGroupsMgr) @@ -1106,12 +1121,14 @@ bool XrdProofdManager::ValidateLocalDataSetSrc(XrdOucString &url, bool &local) // Assert the file with lock file path if (goodsrc) { fnpath.replace("/dataset.list", "/lock.location"); - if (access(fnpath.c_str(), F_OK) != 0) { - FILE *flck = fopen(fnpath.c_str(), "w"); - if (!flck) { - TRACE(XERR, "Cannot open file '" << fnpath << "' with the lock file path; errno: " << errno); - } else { - // Write the default lock file path + FILE *flck = fopen(fnpath.c_str(), "a"); + if (!flck) { + TRACE(XERR, "Cannot open file '" << fnpath << "' with the lock file path; errno: " << errno); + } else { + errno = 0; + off_t ofs = lseek(fileno(flck), 0, SEEK_CUR); + if (ofs == 0) { + // New file: write the default lock file path XrdOucString fnlock(url); fnlock.replace("/", "%"); fnlock.replace(":", "%"); @@ -1119,10 +1136,15 @@ bool XrdProofdManager::ValidateLocalDataSetSrc(XrdOucString &url, bool &local) fprintf(flck, "%s\n", fnlock.c_str()); if (fclose(flck) != 0) TRACE(XERR, "Problems closing file '" << fnpath << "'; errno: " << errno); + flck = 0; if (XrdProofdAux::ChangeOwn(fnpath.c_str(), ui) != 0) { TRACE(XERR, "Problems asserting ownership of " << fnpath); } + } else if (ofs == (off_t)(-1)) { + TRACE(XERR, "Problems getting current position on file '" << fnpath << "'; errno: " << errno); } + if (flck && fclose(flck) != 0) + TRACE(XERR, "Problems closing file '" << fnpath << "'; errno: " << errno); } } // Make sure that everybody can modify the file for updates @@ -1132,6 +1154,9 @@ bool XrdProofdManager::ValidateLocalDataSetSrc(XrdOucString &url, bool &local) } } } + else { + TRACE(ALL, "New dataset with no URL!"); + } // Done return goodsrc; } @@ -1166,6 +1191,7 @@ void XrdProofdManager::RegisterDirectives() Register("image", new XrdProofdDirective("image", (void *)&fImage, &DoDirectiveString)); Register("workdir", new XrdProofdDirective("workdir", (void *)&fWorkDir, &DoDirectiveString)); Register("sockpathdir", new XrdProofdDirective("sockpathdir", (void *)&fSockPathDir, &DoDirectiveString)); + Register("stagereqrepo", new XrdProofdDirective("stagereqrepo", (void *)&fStageReqRepo, &DoDirectiveString)); } //______________________________________________________________________________ @@ -1180,6 +1206,7 @@ int XrdProofdManager::ResolveKeywords(XrdOucString &s, XrdProofdClient *pcl) // <group> user group // <uid> user ID // <gid> user group ID + // <effuser> effective user name (for multiuser or user mapping modes) // Return the number of keywords resolved. XPDLOC(ALL, "Manager::ResolveKeywords") @@ -1207,6 +1234,15 @@ int XrdProofdManager::ResolveKeywords(XrdOucString &s, XrdProofdClient *pcl) nk++; } + // Parse <effuser> of the process + if (s.find("<effuser>") != STR_NPOS) { + XrdProofUI eui; + if (XrdProofdAux::GetUserInfo(geteuid(), eui) == 0) { + if (s.replace("<effuser>", eui.fUser.c_str())) + nk++; + } + } + // Parse <user> if (pcl) if (s.replace("<user>", pcl->User())) @@ -1626,7 +1662,7 @@ int XrdProofdManager::DoDirectiveDataSetSrc(char *val, XrdOucStream *cfg, bool) return -1; // URL for this source - XrdOucString type(val), url, opts; + XrdOucString type(val), url, opts, obscure; bool rw = 0, local = 0, goodsrc = 1; char *nxt = 0; while ((nxt = cfg->GetWord())) { @@ -1634,8 +1670,13 @@ int XrdProofdManager::DoDirectiveDataSetSrc(char *val, XrdOucStream *cfg, bool) rw = 1; } else if (!strncmp(nxt, "url:", 4)) { url = nxt + 4; + XrdClientUrlInfo u(url); + if (u.Proto == "" && u.HostWPort == "") local = 1; } else if (!strncmp(nxt, "opt:", 4)) { opts = nxt + 4; + } else { + obscure += nxt; + obscure += " "; } } @@ -1654,10 +1695,12 @@ int XrdProofdManager::DoDirectiveDataSetSrc(char *val, XrdOucStream *cfg, bool) if (opts.length() <= 0) { opts = rw ? "Ar:Av:" : "-Ar:-Av:"; } + XrdProofdDSInfo *dsi = new XrdProofdDSInfo(type.c_str(), url.c_str(), + local, rw, opts.c_str(), obscure.c_str()); if (haslocal || !local) { - fDataSetSrcs.push_back(new XrdProofdDSInfo(type.c_str(), url.c_str(), local, rw, opts.c_str())); + fDataSetSrcs.push_back(dsi); } else { - fDataSetSrcs.push_front(new XrdProofdDSInfo(type.c_str(), url.c_str(), local, rw, opts.c_str())); + fDataSetSrcs.push_front(dsi); } } return 0; @@ -1674,12 +1717,20 @@ int XrdProofdManager::DoDirectiveDataDir(char *val, XrdOucStream *cfg, bool) // Data directory and write permissions fDataDir = val; + fDataDirOpts = ""; + fDataDirUrlOpts = ""; XrdOucString opts; char *nxt = 0; while ((nxt = cfg->GetWord()) && (opts.length() == 0)) { opts = nxt; } if (opts.length() > 0) fDataDirOpts = opts; + // Check if URL type options have been spcified in the main url + int iq = STR_NPOS; + if ((iq = fDataDir.rfind('?')) != STR_NPOS) { + fDataDirUrlOpts.assign(fDataDir, iq + 1); + fDataDir.erase(iq); + } // Done return 0; diff --git a/proof/proofd/src/XrdProofdNetMgr.cxx b/proof/proofd/src/XrdProofdNetMgr.cxx index a8c3d9f507e68..3170d034d44a5 100644 --- a/proof/proofd/src/XrdProofdNetMgr.cxx +++ b/proof/proofd/src/XrdProofdNetMgr.cxx @@ -491,7 +491,7 @@ void * XrdProofdNetMgr::ProcessBonjourUpdate(void * context) w++; haveit = 0; while (w != mgr->fRegWorkers.end()) { - TRACE(HDBG,"registerd node: "<< (*w)->fHost <<", port: "<<(*w)->fPort); + TRACE(HDBG,"registered node: "<< (*w)->fHost <<", port: "<<(*w)->fPort); if ((*w)->fHost == i->GetHostName() && (*w)->fPort == i->GetPort()) { (*w)->fActive = true; haveit = 1; @@ -1156,12 +1156,16 @@ int XrdProofdNetMgr::ReadBuffer(XrdProofdProtocol *p) TRACEP(p, DBG, emsg); } response->Send(); + SafeDelArray(pattern); + SafeFree(filen); return 0; } else { XPDFORM(emsg, "could not read buffer from %s %s", (local) ? "local file " : "remote file ", file); TRACEP(p, XERR, emsg); response->Send(kXR_InvalidRequest, emsg.c_str()); + SafeDelArray(pattern); + SafeFree(filen); return 0; } } else { @@ -1386,15 +1390,19 @@ char *XrdProofdNetMgr::ReadBufferLocal(const char *path, if (pat && strlen(pat) > 0) { lcmd = strlen(pat) + strlen(file) + 20; cmd = new char[lcmd]; - if (opt == 2) { - sprintf(cmd, "grep -v %s %s", pat, file); - } else { - sprintf(cmd, "grep %s %s", pat, file); + if (opt == 1) { + snprintf(cmd, lcmd, "grep %s %s", pat, file); + } else if (opt == 2) { + snprintf(cmd, lcmd, "grep -v %s %s", pat, file); + } else if (opt == 3) { + snprintf(cmd, lcmd, "cat %s | %s", file, pat); + } else { // should not be here + snprintf(cmd, lcmd, "cat %s", file); } } else { lcmd = strlen(file) + 10; cmd = new char[lcmd]; - sprintf(cmd, "cat %s", file); + snprintf(cmd, lcmd, "cat %s", file); } TRACE(DBG, "cmd: " << cmd); @@ -1555,7 +1563,7 @@ char *XrdProofdNetMgr::ReadLogPaths(const char *url, const char *msg, int isess) reqhdr.proof.int1 = kQueryLogPaths; reqhdr.proof.int2 = isess; reqhdr.proof.sid = -1; - reqhdr.header.dlen = strlen(msg); + reqhdr.header.dlen = msg ? strlen(msg) : 0; const void *btmp = (const void *) msg; char **vout = &buf; // Send over diff --git a/proof/proofd/src/XrdProofdPriorityMgr.cxx b/proof/proofd/src/XrdProofdPriorityMgr.cxx index c65d6c9848719..a83059a1a3b88 100644 --- a/proof/proofd/src/XrdProofdPriorityMgr.cxx +++ b/proof/proofd/src/XrdProofdPriorityMgr.cxx @@ -451,11 +451,11 @@ int XrdProofdPriorityMgr::DoDirectiveSchedOpt(char *val, XrdOucStream *cfg, bool if (o.beginswith("min:")) { // The overall inflating factor o.replace("min:",""); - sscanf(o.c_str(), "%d", &pmin); + pmin = o.atoi(); } else if (o.beginswith("max:")) { // The overall inflating factor o.replace("max:",""); - sscanf(o.c_str(), "%d", &pmax); + pmax = o.atoi(); } else { if (o == "central") opt = kXPD_sched_central; diff --git a/proof/proofd/src/XrdProofdProofServ.cxx b/proof/proofd/src/XrdProofdProofServ.cxx index e292e59470e35..f11d3f8f4e252 100644 --- a/proof/proofd/src/XrdProofdProofServ.cxx +++ b/proof/proofd/src/XrdProofdProofServ.cxx @@ -21,13 +21,6 @@ // Tracing utils #include "XrdProofdTrace.h" -#ifndef SafeDelete -#define SafeDelete(x) { if (x) { delete x; x = 0; } } -#endif -#ifndef SafeDelArray -#define SafeDelArray(x) { if (x) { delete[] x; x = 0; } } -#endif - //__________________________________________________________________________ XrdProofdProofServ::XrdProofdProofServ() { @@ -71,8 +64,8 @@ XrdProofdProofServ::~XrdProofdProofServ() { // Destructor - SafeDelete(fStartMsg); - SafeDelete(fPingSem); + SafeDel(fStartMsg); + SafeDel(fPingSem); std::vector<XrdClientID *>::iterator i; for (i = fClients.begin(); i != fClients.end(); i++) @@ -89,7 +82,7 @@ XrdProofdProofServ::~XrdProofdProofServ() // Remove the associated UNIX socket path unlink(fUNIXSockPath.c_str()); - SafeDelete(fMutex); + SafeDel(fMutex); } //__________________________________________________________________________ @@ -183,8 +176,13 @@ int XrdProofdProofServ::Reset(const char *msg, int type) XPDFORM(fn, "%s.status", fAdminPath.c_str()); FILE *fpid = fopen(fn.c_str(), "r"); if (fpid) { - if (fscanf(fpid, "%d", &st) <= 0) + char line[64]; + if (fgets(line, sizeof(line), fpid)) { + if (line[strlen(line)-1] == '\n') line[strlen(line)-1] = 0; + st = atoi(line); + } else { TRACE(XERR,"problems reading from file "<<fn); + } fclose(fpid); } TRACE(DBG,"file: "<<fn<<", st:"<<st); @@ -212,8 +210,8 @@ void XrdProofdProofServ::Reset() fResponse = 0; fProtocol = 0; fParent = 0; - SafeDelete(fStartMsg); - SafeDelete(fPingSem); + SafeDel(fStartMsg); + SafeDel(fPingSem); fSrvPID = -1; fID = -1; fIsShutdown = false; @@ -249,7 +247,7 @@ void XrdProofdProofServ::DeleteUNIXSock() { // Delete the current UNIX socket - SafeDelete(fUNIXSock); + SafeDel(fUNIXSock); unlink(fUNIXSockPath.c_str()); fUNIXSockPath = ""; } @@ -341,7 +339,12 @@ int XrdProofdProofServ::FreeClientID(int pid) for (i = fClients.begin(); i != fClients.end(); ++i) { if ((*i) && (*i)->P()) { if ((*i)->P()->Pid() == pid || (*i)->P()->Pid() == -1) { + if (fProtocol == (*i)->P()) { + SetProtocol(0); + SetConnection(0); + } (*i)->Reset(); + if (fParent == (*i)) SetParent(0); fNClients--; // Record time of last disconnection if (fNClients <= 0) @@ -565,8 +568,10 @@ int XrdProofdProofServ::BroadcastPriority(int priority) if (!fResponse || fResponse->Send(kXR_attn, kXPD_priority, buf, len) != 0) { // Failure TRACE(XERR,"problems telling proofserv"); + SafeDelArray(buf); return -1; } + SafeDelArray(buf); TRACE(DBG, "priority "<<priority<<" sent over"); // Done return 0; @@ -682,25 +687,22 @@ int XrdProofdProofServ::CreateUNIXSock(XrdSysError *edest) fUNIXSock = new XrdNet(edest); // Make sure the admin path exists - struct stat st; - if (fAdminPath.length() > 0 && - stat(fAdminPath.c_str(), &st) != 0 && (errno == ENOENT)) {; - FILE *fadm = fopen(fAdminPath.c_str(), "w"); - fclose(fadm); + if (fAdminPath.length() > 0) { + FILE *fadm = fopen(fAdminPath.c_str(), "a"); + if (fadm) { + fclose(fadm); + } else { + TRACE(XERR, "unable to open / create admin path "<< fAdminPath << "; errno = "<<errno); + return -1; + } } // Check the path - bool rm = 0, ok = 0; - if (stat(fUNIXSockPath.c_str(), &st) == 0 || (errno != ENOENT)) rm = 1; - if (rm && unlink(fUNIXSockPath.c_str()) != 0) { - if (!S_ISSOCK(st.st_mode)) { - TRACE(XERR, "non-socket path exists: unable to delete it: " <<fUNIXSockPath); - return -1; - } else { - XPDPRT("WARNING: socket path exists: unable to delete it:" - " try to use it anyway " <<fUNIXSockPath); - ok = 1; - } + bool ok = 0; + if (unlink(fUNIXSockPath.c_str()) != 0 && (errno != ENOENT)) { + XPDPRT("WARNING: path exists: unable to delete it:" + " try to use it anyway " <<fUNIXSockPath); + ok = 1; } // Create the path @@ -752,32 +754,24 @@ int XrdProofdProofServ::SetAdminPath(const char *a, bool assert, bool setown) // If we are not asked to assert the file we are done if (!assert) return 0; - // The session file - struct stat st; - if (stat(a, &st) != 0 && errno == ENOENT) { - // Create the file - FILE *fpid = fopen(a, "w"); - if (fpid) { - fclose(fpid); - } else { - TRACE(XERR, "unable to open / create admin path "<< fAdminPath << "; errno = "<<errno); - return -1; - } + // Check if the session file exists + FILE *fpid = fopen(a, "a"); + if (fpid) { + fclose(fpid); + } else { + TRACE(XERR, "unable to open / create admin path "<< fAdminPath << "; errno = "<<errno); + return -1; } - // The status file + // Check if the status file exists XrdOucString fn; XPDFORM(fn, "%s.status", a); - if (stat(fn.c_str(), &st) != 0 && errno == ENOENT) { - // Create the file - FILE *fpid = fopen(fn.c_str(), "w"); - if (fpid) { - fprintf(fpid, "%d", fStatus); - fclose(fpid); - } else { - TRACE(XERR, "unable to open / create status path "<< fn << "; errno = "<<errno); - return -1; - } + if ((fpid = fopen(fn.c_str(), "a"))) { + fprintf(fpid, "%d", fStatus); + fclose(fpid); + } else { + TRACE(XERR, "unable to open / create status path "<< fn << "; errno = "<<errno); + return -1; } if (setown) { @@ -791,13 +785,6 @@ int XrdProofdProofServ::SetAdminPath(const char *a, bool assert, bool setown) TRACE(XERR, "unable to give ownership of the status file "<< fn << " to user; errno = "<<errno); return -1; } - // Check - if (stat(fn.c_str(), &st) != 0) { - TRACE(XERR, "creation/assertion of the status path "<< fn << " failed; errno = "<<errno); - return -1; - } else { - TRACE(ALL, "creation/assertion of the status path "<< fn << " was successful!"); - } } // Done @@ -995,7 +982,7 @@ void XrdProofdProofServ::SendClusterInfo(int nsess, int nacti) // Failure TRACE(XERR,"problems sending proofserv"); } - + SafeDelArray(buf); } //__________________________________________________________________________ diff --git a/proof/proofd/src/XrdProofdProofServMgr.cxx b/proof/proofd/src/XrdProofdProofServMgr.cxx index 7aa9d74a16547..504ce68873920 100644 --- a/proof/proofd/src/XrdProofdProofServMgr.cxx +++ b/proof/proofd/src/XrdProofdProofServMgr.cxx @@ -11,7 +11,7 @@ ////////////////////////////////////////////////////////////////////////// // // -// XrdProofdProofServMgr // +// XrdProofdProofServMgr // // // // Author: G. Ganis, CERN, 2008 // // // @@ -32,8 +32,7 @@ #include "XrdOuc/XrdOucRash.hh" #include "XrdOuc/XrdOucStream.hh" #include "XrdSys/XrdSysPriv.hh" -#include "XrdSut/XrdSutAux.hh" - +#include "XrdSys/XrdSysPlugin.hh" #include "XrdProofdClient.h" #include "XrdProofdClientMgr.h" #include "XrdProofdManager.h" @@ -143,22 +142,9 @@ void *XrdProofdProofServCron(void *p) // Notify action TRACE(REQ, "kSessionRemoval: session: "<<fpid<< " has been removed from the active list"); - } else if (msg.Type() == XrdProofdProofServMgr::kClientDisconnect) { - // A client just disconnected: we free the slots in the proofserv sesssions and - // we check the sessions status to see if any of them must be terminated - // read process id - int pid = 0; - if ((rc = msg.Get(pid)) != 0) { - TRACE(XERR, "kClientDisconnect: problems receiving process ID (buf: '"<< - msg.Buf()<<"'); errno: "<<-rc); - continue; - } - TRACE(REQ, "kClientDisconnect: a client just disconnected: "<<pid); - // Free slots in the proof serv instances - mgr->DisconnectFromProofServ(pid); - TRACE(DBG, "quick check of active sessions"); - // Quick check of active sessions in case of disconnections - mgr->CheckActiveSessions(0); + } else if (msg.Type() == XrdProofdProofServMgr::kClientDisconnect) { + // Obsolete + TRACE(XERR, "obsolete type: XrdProofdProofServMgr::kClientDisconnect"); } else if (msg.Type() == XrdProofdProofServMgr::kCleanSessions) { // Request for cleanup all sessions of a client (or all clients) XpdSrvMgrCreateCnt cnt(mgr, XrdProofdProofServMgr::kCleanSessionsCnt); @@ -300,6 +286,8 @@ XrdProofdProofServMgr::XrdProofdProofServMgr(XrdProofdManager *mgr, fCurrentSessions = 0; fSeqSessionN = 0; + + fCredsSaver = 0; // Defaults can be changed via 'proofservmgr' fCheckFrequency = 30; @@ -442,8 +430,8 @@ int XrdProofdProofServMgr::AddSession(XrdProofdProtocol *p, XrdProofdProofServ * TRACE(REQ, "adding new active session ..."); // Check inputs - if (!s || !p || !p->Client()) { - TRACE(XERR,"invalid inputs: "<<p<<", "<<s<<", "<<p->Client()); + if (!s || !p->Client()) { + TRACE(XERR,"invalid inputs: "<<(s ? "" : "s, ") <<", "<< (p->Client() ? "" : "p->Client()")); return -1; } XrdProofdClient *c = p->Client(); @@ -470,7 +458,7 @@ bool XrdProofdProofServMgr::IsSessionSocket(const char *fpid) // Check inputs if (!fpid || strlen(fpid) <= 0) { - TRACE(XERR, "invalid input: "<<fpid); + TRACE(XERR, "invalid input: "<<(fpid ? fpid : "<nul>")); return 0; } @@ -508,7 +496,7 @@ int XrdProofdProofServMgr::MvSession(const char *fpid) // Check inputs if (!fpid || strlen(fpid) <= 0) { - TRACE(XERR, "invalid input: "<<fpid); + TRACE(XERR, "invalid input: "<<(fpid ? fpid : "<nul>")); return -1; } @@ -560,7 +548,7 @@ int XrdProofdProofServMgr::RmSession(const char *fpid) // Check inputs if (!fpid || strlen(fpid) <= 0) { - TRACE(XERR, "invalid input: "<<fpid); + TRACE(XERR, "invalid input: "<< (fpid ? fpid : "<nul>")); return -1; } @@ -583,11 +571,11 @@ int XrdProofdProofServMgr::TouchSession(const char *fpid, const char *fpath) // Update the access time for the session pid file to the current time XPDLOC(SMGR, "ProofServMgr::TouchSession") - TRACE(REQ, "touching "<<fpid<<", "<<fpath<<" ..."); + TRACE(REQ, "touching "<<(fpid ? fpid : "<nul>")<<", "<<(fpath ? fpath : "<nul>")<<" ..."); // Check inputs if (!fpid || strlen(fpid) <= 0) { - TRACE(XERR, "invalid input: "<<fpid); + TRACE(XERR, "invalid input: "<<(fpid ? fpid : "<nul>")); return -1; } @@ -617,7 +605,7 @@ int XrdProofdProofServMgr::VerifySession(const char *fpid, // Check inputs if (!fpid || strlen(fpid) <= 0) { - TRACE(XERR, "invalid input: "<<fpid); + TRACE(XERR, "invalid input: "<<(fpid ? fpid : "<nul>")); return -1; } @@ -675,7 +663,7 @@ int XrdProofdProofServMgr::DeleteFromSessions(const char *fpid) // Check inputs if (!fpid || strlen(fpid) <= 0) { - TRACE(XERR, "invalid input: "<<fpid); + TRACE(XERR, "invalid input: "<<(fpid ? fpid : "<nul>")); return -1; } @@ -861,7 +849,7 @@ bool XrdProofdProofServMgr::IsClientRecovering(const char *usr, const char *grp, XPDLOC(SMGR, "ProofServMgr::IsClientRecovering") if (!usr || !grp) { - TRACE(XERR, "invalid inputs: usr: "<<usr<<", grp:"<<grp<<" ..."); + TRACE(XERR, "invalid inputs: usr: "<<(usr ? usr : "")<<", grp:"<<(grp ? grp : "")<<" ..."); return false; } @@ -1139,7 +1127,17 @@ int XrdProofdProofServMgr::CleanClientSessions(const char *usr, int srvtype) while (ii != tobedel.end()) { XPDFORM(key, "%d", *ii); XrdSysMutexHelper mhp(fMutex); - fSessions.Del(key.c_str()); + XrdProofdProofServ *xps = fSessions.Find(key.c_str()); + bool active = 0; + std::list<XrdProofdProofServ *>::iterator ixps = fActiveSessions.begin(); + while (ixps != fActiveSessions.end()) { + if (*ixps == xps) { + active = 1; + break; + } + ixps++; + } + if (!active) fSessions.Del(key.c_str()); ii++; } @@ -1654,7 +1652,7 @@ XrdProofdProofServ *XrdProofdProofServMgr::PrepareProofServ(XrdProofdProtocol *p TRACEP(p, REQ, msg); if (p->ConnType() == kXPD_ClientMaster) { // Notify the client if using a version different from the default one - if (p->Client()->ROOT() != fMgr->ROOTMgr()->DefaultVersion()) { + if (fMgr && p->Client()->ROOT() != fMgr->ROOTMgr()->DefaultVersion()) { XPDFORM(msg, "++++ Using NON-default ROOT version: %s ++++\n", xps->ROOT()->Export()); r->Send(kXR_attn, kXPD_srvmsg, (char *) msg.c_str(), msg.length()); } @@ -1810,7 +1808,7 @@ int XrdProofdProofServMgr::CreateFork(XrdProofdProtocol *p) } // Start setting up the unique tag and relevant dirs for this session - ProofServEnv_t in = {xps, loglevel, cffile.c_str(), "", "", "", "", "", 1}; + ProofServEnv_t in = {xps, loglevel, cffile.c_str(), "", "", tag.c_str(), "", "", 1}; GetTagDirs(0, p, xps, in.fSessionTag, in.fTopSessionTag, in.fSessionDir, in.fWrkDir); // Fork an agent process to handle this session @@ -1818,18 +1816,21 @@ int XrdProofdProofServMgr::CreateFork(XrdProofdProtocol *p) TRACEP(p, FORK,"Forking external proofsrv"); if (!(pid = fMgr->Sched()->Fork("proofsrv"))) { - // Finalize unique tag and relevant dirs for this session and create log file path + // Finalize unique tag and relevant dirs for this session GetTagDirs((int)getpid(), p, xps, in.fSessionTag, in.fTopSessionTag, in.fSessionDir, in.fWrkDir); - XPDFORM(in.fLogFile, "%s.log", in.fWrkDir.c_str()); + + // Create log file path + FormFileNameInSessionDir(p, xps, in.fSessionDir.c_str(), "log", in.fLogFile); // Log to the session log file from now on if (fLogger) fLogger->Bind(in.fLogFile.c_str()); TRACE(FORK, "log file: "<<in.fLogFile); - XrdOucString pmsg = "child process "; + XrdOucString pmsg = "*** spawned child process "; pmsg += (int) getpid(); - TRACE(FORK, pmsg); + pmsg += " ***"; + TRACE(ALL, pmsg); // These files belongs to the client if (chown(in.fLogFile.c_str(), p->Client()->UI().fUid, p->Client()->UI().fGid) != 0) @@ -1905,20 +1906,29 @@ int XrdProofdProofServMgr::CreateFork(XrdProofdProtocol *p) char *argvv[6] = {0}; + // We set to the user environment + if (!fMgr) { + emsg = "XrdProofdManager instance undefined!"; + TRACE(XERR, emsg); + if (fcp.Post(0, emsg.c_str()) != 0) + TRACE(XERR, "cannot write to internal pipe; errno: "<<errno); + exit(1); + } char *sxpd = 0; - if (fMgr && fMgr->AdminPath()) { + if (fMgr->AdminPath()) { // We add our admin path to be able to identify processes coming from us - sxpd = new char[strlen(fMgr->AdminPath()) + strlen("xpdpath:") + 1]; - sprintf(sxpd, "xpdpath:%s", fMgr->AdminPath()); + size_t len = strlen(fMgr->AdminPath()) + strlen("xpdpath:") + 1; + sxpd = new char[len]; + snprintf(sxpd, len, "xpdpath:%s", fMgr->AdminPath()); } else { // We add our PID to be able to identify processes coming from us sxpd = new char[10]; - sprintf(sxpd, "%d", getppid()); + snprintf(sxpd, 10, "%d", getppid()); } // Log level char slog[10] = {0}; - sprintf(slog, "%d", loglevel); + snprintf(slog, 10, "%d", loglevel); // start server argvv[0] = (char *) xps->ROOT()->PrgmSrv(); @@ -1982,9 +1992,12 @@ int XrdProofdProofServMgr::CreateFork(XrdProofdProtocol *p) TRACEP(p, FORK,"Parent process: child is "<<pid); XrdOucString emsg; - // Finalize unique tag and relevant dirs for this session and create log file path + // Finalize unique tag and relevant dirs for this session GetTagDirs((int)pid, p, xps, in.fSessionTag, in.fTopSessionTag, in.fSessionDir, in.fWrkDir); - XPDFORM(in.fLogFile, "%s.log", in.fWrkDir.c_str()); + + // Create log file path + FormFileNameInSessionDir(p, xps, in.fSessionDir.c_str(), "log", in.fLogFile); + TRACEP(p, FORK, "log file: "<<in.fLogFile); // Log prefix @@ -2144,6 +2157,8 @@ int XrdProofdProofServMgr::CreateFork(XrdProofdProtocol *p) fpc.Close(); fcp.Close(); + TRACEP(p, FORK, "tags: tag:"<<in.fSessionTag<<" top:"<<in.fTopSessionTag<<" xps:"<<xps->Tag()); + // Notify the user if (prc <= 0) { // Timed-out or failed: we are done; if timed-out finalize the notification message @@ -2359,7 +2374,7 @@ int XrdProofdProofServMgr::Create(XrdProofdProtocol *p) <<","<<p->CID()<<","<<loglevel<<"}"); // Start setting up the unique tag and relevant dirs for this session - ProofServEnv_t in = {xps, loglevel, cffile.c_str(), "", "", "", "", "", 0}; + ProofServEnv_t in = {xps, loglevel, cffile.c_str(), "", "", tag.c_str(), "", "", 0}; GetTagDirs(0, p, xps, in.fSessionTag, in.fTopSessionTag, in.fSessionDir, in.fWrkDir); XrdOucString emsg; @@ -2383,7 +2398,7 @@ int XrdProofdProofServMgr::Create(XrdProofdProtocol *p) return 0; } - // Create the RC-file and env-file paths for this session: for masters this will be temporary + // Create the RC-file and env-file paths for this session: for masters this will be temporarily // located in the sandbox XrdOucString rcfile, envfile; if (p->ConnType() == kXPD_ClientMaster) { @@ -2489,6 +2504,7 @@ int XrdProofdProofServMgr::Create(XrdProofdProtocol *p) emsg += errlog; emsg.insert(npfx, 0); response->Send(kXP_ServerError, emsg.c_str()); + SafeDel(peersrv); return 0; } @@ -2531,9 +2547,10 @@ int XrdProofdProofServMgr::Create(XrdProofdProtocol *p) TRACEP(p, XERR, emsg.c_str()); emsg.insert(npfx, 0); response->Send(kXR_attn, kXPD_errmsg, (char *) emsg.c_str(), emsg.length()); + SafeDel(peersrv); return 0; } - SafeDelete(peersrv); + SafeDel(peersrv); // Set the group, if any xps->SetGroup(p->Client()->Group()); @@ -2633,11 +2650,11 @@ int XrdProofdProofServMgr::ResolveSession(const char *fpid) // Handle a request to recover a session after stop&restart XPDLOC(SMGR, "ProofServMgr::ResolveSession") - TRACE(REQ, "resolving "<< fpid<<" ..."); + TRACE(REQ, "resolving "<< (fpid ? fpid : "<nul>")<<" ..."); // Check inputs if (!fpid || strlen(fpid)<= 0 || !(fMgr->ClientMgr()) || !fRecoverClients) { - TRACE(XERR, "invalid inputs: "<<fpid<<", "<<fMgr->ClientMgr()<< + TRACE(XERR, "invalid inputs: "<<(fpid ? fpid : "<nul>")<<", "<<fMgr->ClientMgr()<< ", "<<fRecoverClients); return -1; } @@ -2931,6 +2948,9 @@ int XrdProofdProofServMgr::Destroy(XrdProofdProtocol *p) p->Client()->TerminateSessions(kXPD_AnyServer, xpsref, msg.c_str(), Pipe(), fMgr->ChangeOwn()); + // Add to destroyed list + fDestroyTimes[p] = time(0); + // Notify to user response->Send(); @@ -3007,26 +3027,30 @@ int XrdProofdProofServMgr::SetProofServEnvOld(XrdProofdProtocol *p, void *input) XrdOucString udir = p->Client()->Sandbox()->Dir(); TRACE(DBG, "working dir for "<<p->Client()->User()<<" is: "<<udir); - ev = new char[strlen("ROOTPROOFSESSDIR=") + in->fWrkDir.length() + 2]; - sprintf(ev, "ROOTPROOFSESSDIR=%s", in->fWrkDir.c_str()); + size_t len = strlen("ROOTPROOFSESSDIR=") + in->fWrkDir.length() + 2; + ev = new char[len]; + snprintf(ev, len, "ROOTPROOFSESSDIR=%s", in->fWrkDir.c_str()); putenv(ev); TRACE(DBG, ev); // Log level - ev = new char[strlen("ROOTPROOFLOGLEVEL=")+5]; - sprintf(ev, "ROOTPROOFLOGLEVEL=%d", in->fLogLevel); + len = strlen("ROOTPROOFLOGLEVEL=") + 5; + ev = new char[len]; + snprintf(ev, len, "ROOTPROOFLOGLEVEL=%d", in->fLogLevel); putenv(ev); TRACE(DBG, ev); // Ordinal number - ev = new char[strlen("ROOTPROOFORDINAL=")+strlen(xps->Ordinal())+2]; - sprintf(ev, "ROOTPROOFORDINAL=%s", xps->Ordinal()); + len = strlen("ROOTPROOFORDINAL=")+strlen(xps->Ordinal()) + 2; + ev = new char[len]; + snprintf(ev, len, "ROOTPROOFORDINAL=%s", xps->Ordinal()); putenv(ev); TRACE(DBG, ev); // ROOT Version tag if not the default one - ev = new char[strlen("ROOTVERSIONTAG=")+strlen(p->Client()->ROOT()->Tag())+2]; - sprintf(ev, "ROOTVERSIONTAG=%s", p->Client()->ROOT()->Tag()); + len = strlen("ROOTVERSIONTAG=")+strlen(p->Client()->ROOT()->Tag())+2; + ev = new char[len]; + snprintf(ev, len, "ROOTVERSIONTAG=%s", p->Client()->ROOT()->Tag()); putenv(ev); TRACE(DBG, ev); @@ -3067,28 +3091,20 @@ int XrdProofdProofServMgr::SetProofServEnvOld(XrdProofdProtocol *p, void *input) // The credential buffer, if any XrdSecCredentials *creds = p->AuthProt()->getCredentials(); if (creds) { - int lev = strlen("XrdSecCREDS=")+creds->size; - ev = new char[lev+1]; + len = strlen("XrdSecCREDS=")+creds->size; + ev = new char[len + 1]; strcpy(ev, "XrdSecCREDS="); - memcpy(ev+strlen("XrdSecCREDS="), creds->buffer, creds->size); - ev[lev] = 0; + memcpy(ev + strlen("XrdSecCREDS="), creds->buffer, creds->size); + ev[len] = 0; putenv(ev); TRACE(DBG, "XrdSecCREDS set"); - - // If 'pwd', save AFS key, if any - if (!strncmp(p->AuthProt()->Entity.prot, "pwd", 3)) { + if (fCredsSaver) { XrdOucString credsdir = udir; credsdir += "/.creds"; // Make sure the directory exists if (!XrdProofdAux::AssertDir(credsdir.c_str(), p->Client()->UI(), fMgr->ChangeOwn())) { - if (SaveAFSkey(creds, credsdir.c_str(), p->Client()->UI()) == 0) { - ev = new char[strlen("ROOTPROOFAFSCREDS=")+credsdir.length()+strlen("/.afs")+2]; - sprintf(ev, "ROOTPROOFAFSCREDS=%s/.afs", credsdir.c_str()); - putenv(ev); - fprintf(fenv, "ROOTPROOFAFSCREDS has been set\n"); - TRACE(DBG, ev); - } else { - TRACE(DBG, "problems in saving AFS key"); + if ((*fCredsSaver)(creds, credsdir.c_str(), p->Client()->UI()) != 0) { + TRACE(DBG, "problems in saving authentication creds under "<<credsdir); } } else { TRACE(XERR, "unable to create creds dir: "<<credsdir); @@ -3209,8 +3225,9 @@ int XrdProofdProofServMgr::SetProofServEnvOld(XrdProofdProtocol *p, void *input) } } // The list of names, ','-separated - ev = new char[strlen("PROOF_ALLVARS=") + namelist.length() + 2]; - sprintf(ev, "PROOF_ALLVARS=%s", namelist.c_str()); + len = strlen("PROOF_ALLVARS=") + namelist.length() + 2; + ev = new char[len]; + snprintf(ev, len, "PROOF_ALLVARS=%s", namelist.c_str()); putenv(ev); fprintf(fenv, "%s\n", ev); TRACE(DBG, ev); @@ -3242,6 +3259,7 @@ int XrdProofdProofServMgr::SetProofServEnv(XrdProofdManager *mgr, XrdROOT *r) XPDLOC(SMGR, "ProofServMgr::SetProofServEnv") char *ev = 0; + size_t len = 0; TRACE(REQ, "ROOT dir: "<< (r ? r->Dir() : "*** undef ***")); @@ -3249,34 +3267,40 @@ int XrdProofdProofServMgr::SetProofServEnv(XrdProofdManager *mgr, XrdROOT *r) char *libdir = (char *) r->LibDir(); char *ldpath = 0; if (mgr->BareLibPath() && strlen(mgr->BareLibPath()) > 0) { - ldpath = new char[32 + strlen(libdir) + strlen(mgr->BareLibPath())]; - sprintf(ldpath, "%s=%s:%s", XPD_LIBPATH, libdir, mgr->BareLibPath()); + len = 32 + strlen(libdir) + strlen(mgr->BareLibPath()); + ldpath = new char[len]; + snprintf(ldpath, len, "%s=%s:%s", XPD_LIBPATH, libdir, mgr->BareLibPath()); } else { - ldpath = new char[32 + strlen(libdir)]; - sprintf(ldpath, "%s=%s", XPD_LIBPATH, libdir); + len = 32 + strlen(libdir); + ldpath = new char[len]; + snprintf(ldpath, len, "%s=%s", XPD_LIBPATH, libdir); } putenv(ldpath); // Set ROOTSYS char *rootsys = (char *) r->Dir(); - ev = new char[15 + strlen(rootsys)]; - sprintf(ev, "ROOTSYS=%s", rootsys); + len = 15 + strlen(rootsys); + ev = new char[len]; + snprintf(ev, len, "ROOTSYS=%s", rootsys); putenv(ev); // Set bin directory char *bindir = (char *) r->BinDir(); - ev = new char[15 + strlen(bindir)]; - sprintf(ev, "ROOTBINDIR=%s", bindir); + len = 15 + strlen(bindir); + ev = new char[len]; + snprintf(ev, len, "ROOTBINDIR=%s", bindir); putenv(ev); // Set conf dir char *confdir = (char *) r->DataDir(); - ev = new char[20 + strlen(confdir)]; - sprintf(ev, "ROOTCONFDIR=%s", confdir); + len = 20 + strlen(confdir); + ev = new char[len]; + snprintf(ev, len, "ROOTCONFDIR=%s", confdir); putenv(ev); // Set TMPDIR - ev = new char[20 + strlen(mgr->TMPdir())]; - sprintf(ev, "TMPDIR=%s", mgr->TMPdir()); + len = 20 + strlen(mgr->TMPdir()); + ev = new char[len]; + snprintf(ev, len, "TMPDIR=%s", mgr->TMPdir()); putenv(ev); // Done @@ -3288,6 +3312,36 @@ int XrdProofdProofServMgr::SetProofServEnv(XrdProofdManager *mgr, XrdROOT *r) return -1; } +//______________________________________________________________________________ +void XrdProofdProofServMgr::FormFileNameInSessionDir(XrdProofdProtocol *p, + XrdProofdProofServ *xps, + const char *sessiondir, + const char *extension, + XrdOucString &outfn) +{ + XrdOucString host = fMgr->Host(); + XrdOucString ord = xps->Ordinal(); + XrdOucString role; + + // Shorten host name + if (host.find(".") != STR_NPOS) + host.erase(host.find(".")); + + if (p->ConnType() == kXPD_MasterWorker) role = "worker"; + else role = "master"; + + // File name format: + // <sessiondir>/[master|worker]-<ordinal>-<host>.<ext> + // No PID is contained + XPDFORM(outfn, "%s/%s-%s-%s.%s", + sessiondir, + role.c_str(), + ord.c_str(), + host.c_str(), + extension + ); +} + //______________________________________________________________________________ void XrdProofdProofServMgr::GetTagDirs(int pid, XrdProofdProtocol *p, XrdProofdProofServ *xps, @@ -3309,11 +3363,11 @@ void XrdProofdProofServMgr::GetTagDirs(int pid, XPDFORM(sesstag, "%s-%d-", host.c_str(), (int)time(0)); // Session dir - topsesstag = sesstag; sessiondir = udir; if (p->ConnType() == kXPD_ClientMaster) { sessiondir += "/session-"; sessiondir += sesstag; + topsesstag = sesstag; } else { sessiondir += "/"; sessiondir += xps->Tag(); @@ -3333,8 +3387,8 @@ void XrdProofdProofServMgr::GetTagDirs(int pid, sesstag += pid; // Session dir - topsesstag = sesstag; if (p->ConnType() == kXPD_ClientMaster) { + topsesstag = sesstag; sessiondir += pid; xps->SetTag(sesstag.c_str()); } @@ -3357,7 +3411,7 @@ void XrdProofdProofServMgr::GetTagDirs(int pid, } else { TRACE(XERR, "negative pid ("<<pid<<"): should not have got here!"); } - + // Done return; } @@ -3439,18 +3493,16 @@ int XrdProofdProofServMgr::SetProofServEnv(XrdProofdProtocol *p, void *input) return -1; } - // Create the rootrc and env files - TRACE(DBG, "creating env file"); - XrdOucString rcfile = in->fWrkDir; - rcfile += ".rootrc"; + // Create .rootrc and .env files + TRACE(DBG, "creating rc and env files"); + XrdOucString rcfile, envfile; + FormFileNameInSessionDir(p, xps, in->fSessionDir.c_str(), "rootrc", rcfile); if (CreateProofServRootRc(p, in, rcfile.c_str()) != 0) { TRACE(XERR, "problems creating RC file "<<rcfile.c_str()); return -1; } - // Now save the exported env variables, for the record - XrdOucString envfile = in->fWrkDir; - envfile += ".env"; + FormFileNameInSessionDir(p, xps, in->fSessionDir.c_str(), "env", envfile); if (CreateProofServEnvFile(p, in, envfile.c_str(), rcfile.c_str()) != 0) { TRACE(XERR, "problems creating environment file "<<envfile.c_str()); return -1; @@ -3508,6 +3560,7 @@ int XrdProofdProofServMgr::CreateProofServEnvFile(XrdProofdProtocol *p, void *in TRACE(REQ, "environment file: "<< envfn); char *ev = 0; + size_t len = 0; // Forwarded sec credentials, if any if (p->AuthProt()) { @@ -3533,28 +3586,21 @@ int XrdProofdProofServMgr::CreateProofServEnvFile(XrdProofdProtocol *p, void *in // The credential buffer, if any XrdSecCredentials *creds = p->AuthProt()->getCredentials(); if (creds) { - int lev = strlen("XrdSecCREDS=")+creds->size; + int lev = strlen("XrdSecCREDS=") + creds->size; ev = new char[lev+1]; - strcpy(ev, "XrdSecCREDS="); + strncpy(ev, "XrdSecCREDS=", lev); memcpy(ev+strlen("XrdSecCREDS="), creds->buffer, creds->size); ev[lev] = 0; PutEnv(ev, in->fOld); TRACE(DBG, "XrdSecCREDS set"); - // If 'pwd', save AFS key, if any - if (!strncmp(p->AuthProt()->Entity.prot, "pwd", 3)) { + if (fCredsSaver) { XrdOucString credsdir = p->Client()->Sandbox()->Dir(); credsdir += "/.creds"; // Make sure the directory exists if (!XrdProofdAux::AssertDir(credsdir.c_str(), p->Client()->UI(), fMgr->ChangeOwn())) { - if (SaveAFSkey(creds, credsdir.c_str(), p->Client()->UI()) == 0) { - ev = new char[strlen("ROOTPROOFAFSCREDS=")+credsdir.length()+strlen("/.afs")+2]; - sprintf(ev, "ROOTPROOFAFSCREDS=%s/.afs", credsdir.c_str()); - fprintf(fenv, "ROOTPROOFAFSCREDS has been set\n"); - TRACE(DBG, ev); - PutEnv(ev, in->fOld); - } else { - TRACE(DBG, "problems in saving AFS key"); + if ((*fCredsSaver)(creds, credsdir.c_str(), p->Client()->UI()) != 0) { + TRACE(DBG, "problems in saving authentication creds under "<<credsdir); } } else { TRACE(XERR, "unable to create creds dir: "<<credsdir); @@ -3579,24 +3625,27 @@ int XrdProofdProofServMgr::CreateProofServEnvFile(XrdProofdProtocol *p, void *in // RC file if (in->fOld) { - ev = new char[strlen("ROOTRCFILE=")+strlen(rcfn)+2]; - sprintf(ev, "ROOTRCFILE=%s", rcfn); + len = strlen("ROOTRCFILE=") + strlen(rcfn) + 2; + ev = new char[len]; + snprintf(ev, len, "ROOTRCFILE=%s", rcfn); fprintf(fenv, "%s\n", ev); TRACE(DBG, ev); PutEnv(ev, in->fOld); } // ROOT version tag (needed in building packages) - ev = new char[strlen("ROOTVERSIONTAG=")+strlen(p->Client()->ROOT()->Tag())+2]; - sprintf(ev, "ROOTVERSIONTAG=%s", p->Client()->ROOT()->Tag()); + len = strlen("ROOTVERSIONTAG=") + strlen(p->Client()->ROOT()->Tag()) + 2; + ev = new char[len]; + snprintf(ev, len, "ROOTVERSIONTAG=%s", p->Client()->ROOT()->Tag()); fprintf(fenv, "%s\n", ev); TRACE(DBG, ev); PutEnv(ev, in->fOld); // Log file in the log dir if (in->fOld) { - ev = new char[strlen("ROOTPROOFLOGFILE=") + in->fLogFile.length() + 2]; - sprintf(ev, "ROOTPROOFLOGFILE=%s", in->fLogFile.c_str()); + len = strlen("ROOTPROOFLOGFILE=") + in->fLogFile.length() + 2; + ev = new char[len]; + snprintf(ev, len, "ROOTPROOFLOGFILE=%s", in->fLogFile.c_str()); fprintf(fenv, "%s\n", ev); xps->SetFileout(in->fLogFile.c_str()); TRACE(DBG, ev); @@ -3607,19 +3656,29 @@ int XrdProofdProofServMgr::CreateProofServEnvFile(XrdProofdProtocol *p, void *in XrdOucString locdatasrv; if (strlen(fMgr->RootdExe()) <= 0) { XPDFORM(locdatasrv, "root://%s", fMgr->Host()); - } else { - XPDFORM(locdatasrv, "rootd://%s:%d", fMgr->Host(), fMgr->Port()); - } - ev = new char[strlen("LOCALDATASERVER=") + locdatasrv.length() + 2]; - sprintf(ev, "LOCALDATASERVER=%s", locdatasrv.c_str()); + } else { + XrdOucString uh(fMgr->Host()); + if (fMgr->MultiUser()) { + XPDFORM(uh, "%s@%s", fMgr->EffectiveUser(), fMgr->Host()); + } else { + XPDFORM(uh, "<effuser>@%s", fMgr->Host()); + } + XPDFORM(locdatasrv, "rootd://%s:%d", uh.c_str(), fMgr->Port()); + } + int nrk = fMgr->ResolveKeywords(locdatasrv, p->Client()); + TRACE(HDBG, nrk << " placeholders resolved for LOCALDATASERVER"); + len = strlen("LOCALDATASERVER=") + locdatasrv.length() + 2; + ev = new char[len]; + snprintf(ev, len, "LOCALDATASERVER=%s", locdatasrv.c_str()); fprintf(fenv, "%s\n", ev); TRACE(DBG, ev); PutEnv(ev, in->fOld); // Xrootd config file if (CfgFile()) { - ev = new char[strlen("XRDCF=")+strlen(CfgFile())+2]; - sprintf(ev, "XRDCF=%s", CfgFile()); + len = strlen("XRDCF=") + strlen(CfgFile()) + 2; + ev = new char[len]; + snprintf(ev, len, "XRDCF=%s", CfgFile()); fprintf(fenv, "%s\n", ev); TRACE(DBG, ev); PutEnv(ev, in->fOld); @@ -3682,8 +3741,9 @@ int XrdProofdProofServMgr::CreateProofServEnvFile(XrdProofdProtocol *p, void *in } } // The list of names, ','-separated - ev = new char[strlen("PROOF_ALLVARS=") + namelist.length() + 2]; - sprintf(ev, "PROOF_ALLVARS=%s", namelist.c_str()); + len = strlen("PROOF_ALLVARS=") + namelist.length() + 2; + ev = new char[len]; + snprintf(ev, len, "PROOF_ALLVARS=%s", namelist.c_str()); fprintf(fenv, "%s\n", ev); TRACE(DBG, ev); PutEnv(ev, in->fOld); @@ -3795,10 +3855,12 @@ int XrdProofdProofServMgr::CreateProofServRootRc(XrdProofdProtocol *p, fprintf(frc, "ProofServ.Image: %s\n", fMgr->Image()); } - // Session tag + // Session tags if (in->fOld) { fprintf(frc, "# Session tag\n"); - fprintf(frc, "ProofServ.SessionTag: %s\n", in->fTopSessionTag.c_str()); + fprintf(frc, "ProofServ.SessionTag: %s\n", in->fSessionTag.c_str()); + fprintf(frc, "# Top Session tag\n"); + fprintf(frc, "ProofServ.TopSessionTag: %s\n", in->fTopSessionTag.c_str()); } // Session admin path @@ -3923,10 +3985,18 @@ int XrdProofdProofServMgr::CreateProofServRootRc(XrdProofdProtocol *p, rc += (*ii)->fUrl; rc += " opt:"; rc += (*ii)->fOpts; + rc += " "; + rc += (*ii)->fObscure; } fprintf(frc, "%s\n", rc.c_str()); } + // If applicable, add staging requests repository directive initiator + if (strlen(fMgr->StageReqRepo()) > 0) { + fprintf(frc, "# Dataset staging requests repository\n"); + fprintf(frc, "Proof.DataSetStagingRequests: %s\n", fMgr->StageReqRepo()); + } + // If applicable, add datadir location if (fMgr->DataDir() && strlen(fMgr->DataDir()) > 0) { fprintf(frc, "# Data directory\n"); @@ -3934,7 +4004,11 @@ int XrdProofdProofServMgr::CreateProofServRootRc(XrdProofdProtocol *p, XPDFORM(rc, "ProofServ.DataDir: %s/%s/%s/%s/%s", fMgr->DataDir(), p->Client()->Group(), p->Client()->User(), xps->Ordinal(), in->fSessionTag.c_str()); - fprintf(frc, "%s\n", rc.c_str()); + if (fMgr->DataDirUrlOpts() && strlen(fMgr->DataDirUrlOpts()) > 0) { + fprintf(frc, "%s %s\n", rc.c_str(), fMgr->DataDirUrlOpts()); + } else { + fprintf(frc, "%s\n", rc.c_str()); + } } // Done with this @@ -4317,7 +4391,7 @@ int XrdProofdProofServMgr::CleanupProofServ(bool all, const char *usr) // Our parent ID as a string char cpid[10]; - sprintf(cpid, "%d", getpid()); + snprintf(cpid, 10, "%d", getpid()); // Run it ... XrdOucString pids = ":"; @@ -4432,7 +4506,9 @@ int XrdProofdProofServMgr::SetUserOwnerships(XrdProofdProtocol *p, for (int i = 0; i < 3; i++) { if (XrdProofdAux::AssertDir(dus[i].c_str(), p->Client()->UI(), fMgr->ChangeOwn()) == 0) { if (XrdProofdAux::ChangeMod(dus[i].c_str(), mode) != 0) { + std::ios_base::fmtflags oflags = std::cerr.flags(); TRACE(XERR, "problems setting permissions "<< oct << mode<<" on: "<<dus[i]); + std::cerr.flags(oflags); } } else { TRACE(XERR, "problems asserting: "<<dus[i]); @@ -4479,15 +4555,18 @@ int XrdProofdProofServMgr::SetUserEnvironment(XrdProofdProtocol *p) return -1; } + size_t len = 0; // set HOME env - char *h = new char[8 + strlen(p->Client()->Sandbox()->Dir())]; - sprintf(h, "HOME=%s", p->Client()->Sandbox()->Dir()); + len = 8 + strlen(p->Client()->Sandbox()->Dir()); + char *h = new char[len]; + snprintf(h, len, "HOME=%s", p->Client()->Sandbox()->Dir()); putenv(h); TRACE(DBG, "set "<<h); // set USER env - char *u = new char[8 + strlen(p->Client()->User())]; - sprintf(u, "USER=%s", p->Client()->User()); + len = 8 + strlen(p->Client()->User()); + char *u = new char[len]; + snprintf(u, len, "USER=%s", p->Client()->User()); putenv(u); TRACE(DBG, "set "<<u); @@ -4521,84 +4600,6 @@ int XrdProofdProofServMgr::SetUserEnvironment(XrdProofdProtocol *p) return 0; } -//______________________________________________________________________________ -int XrdProofdProofServMgr::SaveAFSkey(XrdSecCredentials *c, - const char *dir, XrdProofUI ui) -{ - // Save the AFS key, if any, for usage in proofserv in file 'dir'/.afs . - // Return 0 on success, -1 on error. - XPDLOC(SMGR, "ProofServMgr::SaveAFSkey") - - // Check file name - if (!dir || strlen(dir) <= 0) { - TRACE(XERR, "dir name undefined"); - return -1; - } - - // Check credentials - if (!c) { - TRACE(XERR, "credentials undefined"); - return -1; - } - TRACE(REQ, "dir: "<<dir); - - // Decode credentials - int lout = 0; - char *out = new char[c->size]; - if (XrdSutFromHex(c->buffer, out, lout) != 0) { - TRACE(XERR, "problems unparsing hex string"); - delete [] out; - return -1; - } - - // Locate the key - char *key = out + 5; - if (strncmp(key, "afs:", 4)) { - TRACE(DBG, "string does not contain an AFS key"); - delete [] out; - return 0; - } - key += 4; - - // Save to file, if not existing already - XrdOucString fn = dir; - fn += "/.afs"; - - int rc = 0; - struct stat st; - if (stat(fn.c_str(), &st) != 0 && errno == ENOENT) { - - // Open the file, truncating if already existing - int fd = open(fn.c_str(), O_WRONLY | O_CREAT | O_TRUNC, 0600); - if (fd <= 0) { - TRACE(XERR, "problems creating file - errno: " << errno); - delete [] out; - return -1; - } - // Write out the key - int lkey = lout - 9; - if (XrdProofdAux::Write(fd, key, lkey) != lkey) { - TRACE(XERR, "problems writing to file - errno: " << errno); - rc = -1; - } - - // Cleanup - delete [] out; - close(fd); - } else { - TRACE(XERR, "cannot stat existing file "<<fn<<" - errno: " << errno); - delete [] out; - return -1; - } - - // Make sure the file is owned by the user - if (XrdProofdAux::ChangeOwn(fn.c_str(), ui) != 0) { - TRACE(XERR, "can't change ownership of "<<fn); - } - - return rc; -} - //__________________________________________________________________________ XrdProofdProofServ *XrdProofdProofServMgr::GetActiveSession(int pid) { @@ -4660,12 +4661,17 @@ void XrdProofdProofServMgr::BroadcastClusterInfo() } si++; } - XPDPRT("tot: "<<tot<<", act: "<<act); - // Now propagate - si = fActiveSessions.begin(); - while (si != fActiveSessions.end()) { - if ((*si)->Status() == kXPD_running) (*si)->SendClusterInfo(tot, act); - si++; + if (tot > 0) { + XPDPRT("tot: "<<tot<<", act: "<<act); + // Now propagate to master or sub-masters + si = fActiveSessions.begin(); + while (si != fActiveSessions.end()) { + if ((*si)->Status() == kXPD_running && + (*si)->SrvType() != kXPD_Worker) (*si)->SendClusterInfo(tot, act); + si++; + } + } else { + TRACE(DBG, "No master or submaster controlled by this manager"); } } @@ -4717,6 +4723,30 @@ void XrdProofdProofServMgr::SetReconnectTime(bool on) } } +//__________________________________________________________________________ +bool XrdProofdProofServMgr::Alive(XrdProofdProtocol* p) +{ + // Check destroyed status + // + + XrdSysMutexHelper mhp(fMutex); + + bool alive = true; + int now = time(0); + std::map<XrdProofdProtocol*,int>::iterator iter = fDestroyTimes.begin(); + while (iter != fDestroyTimes.end()) { + int rect = now - iter->second; + if (rect < fReconnectTimeOut) { + if (p == iter->first) alive = false; + } else { + fDestroyTimes.erase(iter); + } + iter++; + } + + return alive; +} + //__________________________________________________________________________ static int FreeClientID(const char *, XrdProofdProofServ *ps, void *s) { @@ -4894,9 +4924,10 @@ int XrdProofSessionInfo::SaveToFile(const char *file) // Check inputs if (!file || strlen(file) <= 0) { - TRACE(XERR,"invalid input: "<<file); + TRACE(XERR,"invalid input: "<< (file ? file : "<nul>")); return -1; } + TRACE(HDBG,"session saved to file: "<<file); // Create the file FILE *fpid = fopen(file, "w"); @@ -4957,7 +4988,7 @@ int XrdProofSessionInfo::ReadFromFile(const char *file) // Check inputs if (!file || strlen(file) <= 0) { - TRACE(XERR,"invalid input: "<<file); + TRACE(XERR,"invalid input: "<<(file ? file : "<nul>")); return -1; } @@ -4967,42 +4998,58 @@ int XrdProofSessionInfo::ReadFromFile(const char *file) FILE *fpid = fopen(file,"r"); if (fpid) { char line[4096]; - char v1[512], v2[512], v3[512]; + XrdOucString sline, t; + int from = 0; if (fgets(line, sizeof(line), fpid)) { - if (sscanf(line, "%s %s", v1, v2) == 2) { - fUser = v1; - fGroup = v2; - } else { - TRACE(XERR,"warning: corrupted line? "<<line); - } + if (line[strlen(line)-1] == '\n') line[strlen(line)-1] = '\0'; + sline = line; + if ((from = sline.tokenize(fUser, from, ' ')) == -1) + TRACE(XERR,"warning: fUser: corrupted line? "<<line<<" (file: "<<file<<")"); + if ((from = sline.tokenize(fGroup, from, ' ')) == -1) + TRACE(XERR,"warning: fGroup: corrupted line? "<<line<<" (file: "<<file<<")"); } if (fgets(line, sizeof(line), fpid)) { - int l = strlen(line); - if (line[l-1] == '\n') line[l-1] = '\0'; + if (line[strlen(line)-1] == '\n') line[strlen(line)-1] = '\0'; fUnixPath = line; } if (fgets(line, sizeof(line), fpid)) { - sscanf(line, "%d %d %d", &fPid, &fID, &fSrvType); + if (line[strlen(line)-1] == '\n') line[strlen(line)-1] = '\0'; + sline = line; + from = 0; + if ((from = sline.tokenize(t, from, ' ')) == -1) + TRACE(XERR,"warning: fPid: corrupted line? "<<line<<" (file: "<<file<<")"); + fPid = t.atoi(); + if ((from = sline.tokenize(t, from, ' ')) == -1) + TRACE(XERR,"warning: fID: corrupted line? "<<line<<" (file: "<<file<<")"); + fID = t.atoi(); + if ((from = sline.tokenize(t, from, ' ')) == -1) + TRACE(XERR,"warning: fSrvType: corrupted line? "<<line<<" (file: "<<file<<")"); + fSrvType = t.atoi(); } if (fgets(line, sizeof(line), fpid)) { - int ns = 0; - if ((ns = sscanf(line, "%s %s %s", v1, v2, v3)) >= 2) { - fOrdinal = v1; - fTag = v2; - fAlias = (ns == 3) ? v3 : ""; - } else { - TRACE(XERR,"warning: corrupted line? "<<line); - } + if (line[strlen(line)-1] == '\n') line[strlen(line)-1] = '\0'; + sline = line; + from = 0; + if ((from = sline.tokenize(fOrdinal, from, ' ')) == -1) + TRACE(XERR,"warning: fOrdinal: corrupted line? "<<line<<" (file: "<<file<<")"); + if ((from = sline.tokenize(fTag, from, ' ')) == -1) + TRACE(XERR,"warning: fTag: corrupted line? "<<line<<" (file: "<<file<<")"); + if ((from = sline.tokenize(fAlias, from, ' ')) == -1) + TRACE(HDBG,"fAlias undefined "<<line); } if (fgets(line, sizeof(line), fpid)) { + if (line[strlen(line)-1] == '\n') line[strlen(line)-1] = '\0'; fLogFile = line; } if (fgets(line, sizeof(line), fpid)) { - if (sscanf(line, "%d %s", &fSrvProtVers, v1) == 2) { - fROOTTag = v1; - } else { - TRACE(XERR,"warning: corrupted line? "<<line); - } + if (line[strlen(line)-1] == '\n') line[strlen(line)-1] = '\0'; + sline = line; + from = 0; + if ((from = sline.tokenize(t, from, ' ')) == -1) + TRACE(XERR,"warning: fSrvProtVers: corrupted line? "<<line<<" (file: "<<file<<")"); + fSrvProtVers = t.atoi(); + if ((from = sline.tokenize(fROOTTag, from, ' ')) == -1) + TRACE(XERR,"warning: fROOTTag: corrupted line? "<<line<<" (file: "<<file<<")"); } // All the remaining into fUserEnvs fUserEnvs = ""; @@ -5015,7 +5062,7 @@ int XrdProofSessionInfo::ReadFromFile(const char *file) while ((len = read(fileno(fpid), line, wanted)) < 0 && errno == EINTR) errno = 0; - if (len < wanted) { + if (len < 0 || len < wanted) { break; } else { line[len] = '\0'; @@ -5044,7 +5091,8 @@ int XrdProofSessionInfo::ReadFromFile(const char *file) if (fpid) { char line[64]; if (fgets(line, sizeof(line), fpid)) { - sscanf(line, "%d", &fStatus); + if (line[strlen(line)-1] == '\n') line[strlen(line)-1] = 0; + fStatus = atoi(line); } // Done fclose(fpid); diff --git a/proof/proofd/src/XrdProofdProtocol.cxx b/proof/proofd/src/XrdProofdProtocol.cxx index e61bdce33f900..6d169ba1b3ac6 100644 --- a/proof/proofd/src/XrdProofdProtocol.cxx +++ b/proof/proofd/src/XrdProofdProtocol.cxx @@ -29,6 +29,7 @@ #include "XrdVersion.hh" #include "Xrd/XrdBuffer.hh" +#include "Xrd/XrdScheduler.hh" #include "XrdProofdClient.h" #include "XrdProofdClientMgr.h" @@ -54,8 +55,7 @@ static XrdSysLogger gMainLogger; // // Static area: general protocol managing section int XrdProofdProtocol::fgCount = 0; -XrdObjectQ<XrdProofdProtocol> - XrdProofdProtocol::fgProtStack("ProtStack", +XpdObjectQ XrdProofdProtocol::fgProtStack("ProtStack", "xproofd protocol anchor"); XrdSysRecMutex XrdProofdProtocol::fgBMutex; // Buffer management mutex XrdBuffManager *XrdProofdProtocol::fgBPool = 0; @@ -190,20 +190,21 @@ int XrdgetProtocolPort(const char * /*pname*/, char * /*parms*/, XrdProtocol_Con // This function is called early on to determine the port we need to use. The // The default is ostensibly 1093 but can be overidden; which we allow. - XrdProofdProtCfg pcfg(pi->ConfigFN, pi->eDest); - // Init some relevant quantities for tracing - XrdProofdTrace = new XrdOucTrace(pi->eDest); - pcfg.Config(0); - // Default XPD_DEF_PORT (1093) int port = XPD_DEF_PORT; - if (pcfg.fPort > 0) { - port = pcfg.fPort; - } else { - port = (pi && pi->Port > 0) ? pi->Port : XPD_DEF_PORT; - } + if (pi) { + XrdProofdProtCfg pcfg(pi->ConfigFN, pi->eDest); + // Init some relevant quantities for tracing + XrdProofdTrace = new XrdOucTrace(pi->eDest); + pcfg.Config(0); + if (pcfg.fPort > 0) { + port = pcfg.fPort; + } else { + port = (pi && pi->Port > 0) ? pi->Port : XPD_DEF_PORT; + } + } return port; }} @@ -352,7 +353,7 @@ XrdProtocol *XrdProofdProtocol::Match(XrdLink *lp) // Bind the protocol to the link and return the protocol xp->fLink = lp; - strcpy(xp->fSecEntity.prot, "host"); + snprintf(xp->fSecEntity.prot, XrdSecPROTOIDSIZE, "host"); xp->fSecEntity.host = strdup((char *)lp->Host()); // Dummy data used by 'proofd' @@ -507,10 +508,9 @@ void XrdProofdProtocol::Reset() // Cleanup existing XrdProofdResponse objects std::vector<XrdProofdResponse *>::iterator ii = fResponses.begin(); // One per each logical connection while (ii != fResponses.end()) { - delete *ii; + (*ii)->Reset(); ii++; } - fResponses.clear(); } //______________________________________________________________________________ @@ -542,8 +542,12 @@ int XrdProofdProtocol::Configure(char *, XrdProtocol_Config *pi) // Schedule protocol object cleanup; the maximum number of objects // and the max age are taken from XrdXrootdProtocol: this may need // some optimization in the future. +#if 1 fgProtStack.Set(pi->Sched, XrdProofdTrace, TRACE_MEM); fgProtStack.Set((pi->ConnMax/3 ? pi->ConnMax/3 : 30), 60*60); +#else + fgProtStack.Set(pi->Sched, 3600); +#endif // Default tracing options: always trace logins and errors for all // domains; if the '-d' option was specified on the command line then @@ -734,16 +738,36 @@ void XrdProofdProtocol::Recycle(XrdLink *, int, const char *) XrdProofdClient *pmgr = fPClient; if (pmgr) { - - if (!Internal()) { - // Signal the client manager that a client has just gone - if (fgMgr && fgMgr->ClientMgr()) { - TRACE(HDBG, "fAdminPath: "<<fAdminPath); - XPDFORM(buf, "%s %p %d %d", fAdminPath.c_str(), pmgr, fCID, fPid); - TRACE(DBG, "sending to ClientMgr: "<<buf); - fgMgr->ClientMgr()->Pipe()->Post(XrdProofdClientMgr::kClientDisconnect, buf.c_str()); + TRACE(REQ,"External disconnection of protocol associated with pid "<<fPid); + + // Write disconnection file + XrdOucString discpath(fAdminPath); + discpath.replace("/cid", "/disconnected"); + FILE *fd = fopen(discpath.c_str(), "w"); + if (!fd && errno != ENOENT) { + TRACE(XERR, "unable to create path: " <<discpath<<" (errno: "<<errno<<")"); + } else if (fd) { + fclose(fd); + } + + // Remove protocol and response from attached client/proofserv instances + // Set reconnect flag if proofserv instances attached to this client are still running + pmgr->ResetClientSlot(fCID); + if(fgMgr && fgMgr->SessionMgr()) { + XrdSysMutexHelper mhp(fgMgr->SessionMgr()->Mutex()); + + fgMgr->SessionMgr()->DisconnectFromProofServ(fPid); + if((fConnType == 0) && fgMgr->SessionMgr()->Alive(this)) { + TRACE(REQ, "Non-destroyed proofserv processes attached to this protocol ("<<this<< + "), setting reconnect time"); + fgMgr->SessionMgr()->SetReconnectTime(true); + } + fgMgr->SessionMgr()->CheckActiveSessions(0); + } else { + TRACE(XERR, "No XrdProofdMgr ("<<fgMgr<<") or SessionMgr (" + <<(fgMgr ? fgMgr->SessionMgr() : (void *) -1)<<")") } } else { @@ -752,19 +776,30 @@ void XrdProofdProtocol::Recycle(XrdLink *, int, const char *) // of proxy servers and to notify the attached clients. // Tell the session manager that this session has gone if (fgMgr && fgMgr->SessionMgr()) { + XrdSysMutexHelper mhp(fgMgr->SessionMgr()->Mutex()); TRACE(HDBG, "fAdminPath: "<<fAdminPath); buf.assign(fAdminPath, fAdminPath.rfind('/') + 1, -1); - TRACE(DBG, "sending to ProofServMgr: "<<buf); - fgMgr->SessionMgr()->Pipe()->Post(XrdProofdProofServMgr::kSessionRemoval, buf.c_str()); + fgMgr->SessionMgr()->DeleteFromSessions(buf.c_str()); + // Move the entry to the terminated sessions area + fgMgr->SessionMgr()->MvSession(buf.c_str()); + } + else { + TRACE(XERR,"No XrdProofdMgr ("<<fgMgr<<") or SessionMgr ("<<fgMgr->SessionMgr()<<")") } } } - // Set fields to starting point (debugging mostly) Reset(); // Push ourselves on the stack fgProtStack.Push(&fProtLink); +#if 0 + if(fgProtStack.Push(&fProtLink) != 0) { + XrdProofdProtocol *xp = fProtLink.objectItem(); + fProtLink.setItem(0); + delete xp; + } +#endif } //______________________________________________________________________________ @@ -1409,7 +1444,7 @@ void XrdProofdProtocol::TouchAdminPath() apath.replace(".status", ""); rc = XrdProofdAux::Touch(apath.c_str()); } - if (rc != 0) { + if (rc != 0 && rc != -ENOENT) { const char *type = Internal() ? "internal" : "external"; TRACEP(this, XERR, type<<": problems touching "<<apath<<"; errno: "<<-rc); } diff --git a/proof/proofd/src/XrdProofdResponse.cxx b/proof/proofd/src/XrdProofdResponse.cxx index 6f135dc6754be..c97db8d559b6d 100644 --- a/proof/proofd/src/XrdProofdResponse.cxx +++ b/proof/proofd/src/XrdProofdResponse.cxx @@ -48,6 +48,16 @@ #define XPRTRACING(a) ((a != 0) || (TRACING(RSP))) // Check link macro #define CHECKLINK \ + { XrdSysMutexHelper mh(fMutex); \ + if (!fLink) { \ + TRACE(XERR, "link is undefined! "); \ + return 0; \ + } else if (fLink->FDnum() < 0) { \ + TRACE(XERR, "link descriptor invalid for link "<<fLink<<"! ("<< fLink->FDnum()<<")"); \ + return 0; \ + } \ + } +#define CHECKLINKNOMTX \ if (!fLink) { \ TRACE(XERR, "link is undefined! "); \ return 0; \ @@ -551,17 +561,29 @@ int XrdProofdResponse::LinkSend(const char *buff, int len, XrdOucString &emsg) // The link is closed in case of error, because we cannot use it anymore // and the counter part needs to reconnect. // Return 0 on success, -1 on failure. + XPDLOC(RSP, "Response::LinkSend:1") + + XrdSysMutexHelper mxh(fMutex); + CHECKLINKNOMTX; int rc = 0; // If we fail we close the link, and ask the client to reconnect if ((rc = fLink->Send(buff, len)) < 0) { XPDFORM(emsg, "problems sending %d bytes", len); +#if 0 fLink->Close(); } // Done return ((rc < 0) ? fLink->setEtext("send failure") : 0); +#else + fLink = 0; + return -1; + } + // Done + return 0; +#endif } //______________________________________________________________________________ @@ -572,19 +594,30 @@ int XrdProofdResponse::LinkSend(const struct iovec *iov, // Functionality a la 'writev' is simulated by segmenting the sending. // This allows to avoid a recovery problem with 'writev'. // Return 0 on success, -1 on failure. + XPDLOC(RSP, "Response::LinkSend:2") int rc = 0; + XrdSysMutexHelper mxh(fMutex); + CHECKLINKNOMTX; // If we fail we close the link, and ask the client to reconnect if ((rc = fLink->Send(iov, iocnt, 0)) < 0) { int bytes = 0; for (int i = 0; i < iocnt; i++) bytes += iov[i].iov_len; XPDFORM(emsg, "problems sending %d bytes (writev)", bytes); +#if 0 fLink->Close(); } // Done return ((rc < 0) ? fLink->setEtext("send (writev) failure") : 0); +#else + fLink = 0; + return -1; + } + // Done + return 0; +#endif } //______________________________________________________________________________ @@ -622,9 +655,8 @@ void XrdProofdResponse::GetSID(unsigned short &sid) { // Get stream ID (to be able to restore it later - { XrdSysMutexHelper mh(fMutex); - memcpy((void *)&sid, (void *)&fResp.streamid[0], sizeof(sid)); - } + XrdSysMutexHelper mh(fMutex); + memcpy((void *)&sid, (void *)&fResp.streamid[0], sizeof(sid)); } //______________________________________________________________________________ @@ -643,20 +675,10 @@ void XrdProofdResponse::Set(ServerResponseHeader *resp) void XrdProofdResponse::Set(XrdLink *l) { // Set the link to be used by this response - XPDLOC(RSP, "Response::Set") { XrdSysMutexHelper mh(fMutex); fLink = l; - } - GetSID(fSID); - if (fLink) { - if (fLink->FDnum() < 0) { - TRACE(XERR, "link descriptor invalid for link "<<fLink<<"! ("<< fLink->FDnum()<<")"); - } else { - TRACE(DBG,"using link "<<fLink<<", descriptor:"<<fLink->FDnum()); - } - } else { - TRACE(XERR,"link is undefined!"); + memcpy((void *)&fSID, (void *)&fResp.streamid[0], sizeof(fSID)); } } diff --git a/proof/proofd/src/XrdROOT.cxx b/proof/proofd/src/XrdROOT.cxx index 5edb3bbf4021e..323751ef312d8 100644 --- a/proof/proofd/src/XrdROOT.cxx +++ b/proof/proofd/src/XrdROOT.cxx @@ -191,7 +191,7 @@ int XrdROOT::ParseROOTVersionInfo() // Read the file char *pv = 0; - XrdOucString tkn; + XrdOucString tkn, sline; char line[1024]; while (fgets(line, sizeof(line), fv)) { if (fRelease.length() <= 0 && (pv = (char *) strstr(line, "ROOT_RELEASE"))) { @@ -201,13 +201,15 @@ int XrdROOT::ParseROOTVersionInfo() fRelease = pv; fRelease.replace("\"",""); } else if ((pv = (char *) strstr(line, "ROOT_SVN_REVISION"))) { - if (line[strlen(line)-1] == '\n') - line[strlen(line)-1] = 0; - sscanf(pv, "ROOT_SVN_REVISION %d", &fSvnRevision); + if (line[strlen(line)-1] == '\n') line[strlen(line)-1] = 0; + pv += strlen("ROOT_SVN_REVISION"); + while (pv[0] == ' ') pv++; + fSvnRevision = atoi(pv); } else if ((pv = (char *) strstr(line, "ROOT_VERSION_CODE"))) { - if (line[strlen(line)-1] == '\n') - line[strlen(line)-1] = 0; - sscanf(pv, "ROOT_VERSION_CODE %d", &fVersionCode); + if (line[strlen(line)-1] == '\n') line[strlen(line)-1] = 0; + pv += strlen("ROOT_VERSION_CODE"); + while (pv[0] == ' ') pv++; + fVersionCode = atoi(pv); } } @@ -262,11 +264,15 @@ int XrdROOT::ParseReleaseString(const char *release, if (!release || strlen(release) <= 0) return -1; - XrdOucString rel(release, 7); - rel.replace(".", " "); - rel.replace("/", " "); - - sscanf(rel.c_str(), "%d %d %d", &maj, &min, &patch); + XrdOucString rel(release, 7), tkn; + int from = 0; + if ((from = rel.tokenize(tkn, from, '.')) == -1) return -1; + maj = atoi(tkn.c_str()); + if ((from = rel.tokenize(tkn, from, '/')) == -1) return -1; + min = atoi(tkn.c_str()); + if ((from = rel.tokenize(tkn, from, ' ')) == -1) return -1; + patch = atoi(tkn.c_str()); + return 0; } @@ -438,7 +444,7 @@ int XrdROOTMgr::DoDirectiveRootSys(char *val, XrdOucStream *cfg, bool) if ((*ori)->Match(rootc->Dir(), rootc->Tag())) { if ((*ori)->IsParked()) { (*ori)->SetValid(); - SafeDelete(rootc); + SafeDel(rootc); break; } } @@ -456,7 +462,7 @@ int XrdROOTMgr::DoDirectiveRootSys(char *val, XrdOucStream *cfg, bool) fROOT.push_back(rootc); } else { TRACE(XERR, "could not validate "<<rootc->Export()); - SafeDelete(rootc); + SafeDel(rootc); } } } @@ -522,8 +528,9 @@ int XrdROOTMgr::Validate(XrdROOT *r, XrdScheduler *sched) // Log to the session log file from now on fLogger->Bind(logfile.c_str()); // Transfer the info to proofserv - char *ev = new char[strlen("ROOTPROOFLOGFILE=") + logfile.length() + 2]; - sprintf(ev, "ROOTPROOFLOGFILE=%s", logfile.c_str()); + size_t len = strlen("ROOTPROOFLOGFILE=") + logfile.length() + 2; + char *ev = new char[len]; + snprintf(ev, len, "ROOTPROOFLOGFILE=%s", logfile.c_str()); putenv(ev); if (debug && rootrc.length() > 0) { // Create .rootrc @@ -533,8 +540,9 @@ int XrdROOTMgr::Validate(XrdROOT *r, XrdScheduler *sched) fclose(frc); } // Transfer the info to proofserv - ev = new char[strlen("ROOTRCFILE=") + rootrc.length() + 2]; - sprintf(ev, "ROOTRCFILE=%s", rootrc.c_str()); + len = strlen("ROOTRCFILE=") + rootrc.length() + 2; + ev = new char[len]; + snprintf(ev, len, "ROOTRCFILE=%s", rootrc.c_str()); putenv(ev); } } @@ -562,7 +570,7 @@ int XrdROOTMgr::Validate(XrdROOT *r, XrdScheduler *sched) // Set Open socket char *ev = new char[25]; - sprintf(ev, "ROOTOPENSOCK=%d", fp[1]); + snprintf(ev, 25, "ROOTOPENSOCK=%d", fp[1]); putenv(ev); // Prepare for execution: we need to acquire the identity of diff --git a/proof/proofd/src/proofd.cxx b/proof/proofd/src/proofd.cxx index c346a7217ba66..61cb236b2a127 100644 --- a/proof/proofd/src/proofd.cxx +++ b/proof/proofd/src/proofd.cxx @@ -102,7 +102,7 @@ // -noauth do not require client authentication // // -p port# specifies a different port to listen on // // -s <sshd_port> specifies the port number for the sshd daemon // -// (deafult is 22) // +// (default is 22) // // -S keytabfile use this keytab file, instead of the default // // (option only supported when compiled with // // Kerberos5 support) // diff --git a/proof/proofd/src/proofexecv.cxx b/proof/proofd/src/proofexecv.cxx index cde903228b78e..d4b6d0fdaf6fc 100644 --- a/proof/proofd/src/proofexecv.cxx +++ b/proof/proofd/src/proofexecv.cxx @@ -161,8 +161,10 @@ void start_rootd(int argc, char **argv) // Force stdin/out to point to the socket FD (this will also bypass the // close on exec setting for the socket) - dup2(fd, STDIN_FILENO); - dup2(fd, STDOUT_FILENO); + if (dup2(fd, STDIN_FILENO) != 0) + Info("WARNING: failure duplicating STDIN (errno: %d)", errno); + if (dup2(fd, STDOUT_FILENO) != 0) + Info("WARNING: failure duplicating STDOUT (errno: %d)", errno); // Prepare execv int na = argc - 4; @@ -182,6 +184,7 @@ void start_rootd(int argc, char **argv) // We should not be here!!! Info("ERROR: returned from execv: bad, bad sign !!!"); + delete [] argvv; return; } @@ -281,6 +284,7 @@ void start_ps(int argc, char **argv) rpdunix *uconn = new rpdunix(sockpath.c_str()); if (!uconn || (uconn && !uconn->isvalid(0))) { Info("ERROR: failure calling back parent on '%s'", sockpath.c_str()); + if (uconn) delete uconn; return; } @@ -288,6 +292,7 @@ void start_ps(int argc, char **argv) int rcc = 0; if ((rcc = uconn->send((int) getpid())) != 0) { Info("ERROR: failure sending pid to parent (errno: %d)", -rcc); + delete uconn; return; } @@ -295,6 +300,7 @@ void start_ps(int argc, char **argv) rpdmsg msg; if ((rcc = uconn->recv(msg)) != 0) { Info("ERROR: failure receiving admin path and executable from parent (errno: %d)", -rcc); + delete uconn; return; } int ppid; @@ -309,6 +315,7 @@ void start_ps(int argc, char **argv) msg.reset(); if ((rcc = uconn->recv(msg)) != 0) { Info("ERROR: failure receiving information about dataset and data dir(s) from parent (errno: %d)", -rcc); + delete uconn; return; } int euid; @@ -323,6 +330,7 @@ void start_ps(int argc, char **argv) if (setownerships(euid, user, group, creds, datasetsrcs, datadir, ddiropts, ord, stag) != 0) { Info("ERROR: problems setting relevant user ownerships"); + delete uconn; return; } @@ -330,29 +338,34 @@ void start_ps(int argc, char **argv) if (mvfile(tenvfile, envfile, uid, gid, 0644) != 0) { Info("ERROR: problems renaming '%s' to '%s' (errno: %d)", tenvfile.c_str(), envfile.c_str(), errno); + delete uconn; return; } // Move the rootrc file in the session directory if (mvfile(trcfile, rcfile, uid, gid, 0644) != 0) { Info("ERROR: problems renaming '%s' to '%s' (errno: %d)", trcfile.c_str(), rcfile.c_str(), errno); + delete uconn; return; } // Add missing information to the rc file if (completercfile(rcfile, userdir, stag, adminpath) != 0) { Info("ERROR: problems completing '%s'", rcfile.c_str()); + delete uconn; return; } // Set the environment following the content of the env file if (setproofservenv(envfile, logfile, rcfile) != 0) { Info("ERROR: problems setting environment from '%s'", envfile.c_str()); + delete uconn; return; } // Export the file descriptor if (exportsock(uconn) != 0) { Info("ERROR: problems exporting file descriptor"); + delete uconn; return; } delete uconn; @@ -383,12 +396,12 @@ void start_ps(int argc, char **argv) } else { // We add our PID to be able to identify processes coming from us sxpd = new char[10]; - sprintf(sxpd, "%d", ppid); + snprintf(sxpd, 10, "%d", ppid); } // Log level char slog[10] = {0}; - sprintf(slog, "%d", gDebug); + snprintf(slog, 10, "%d", gDebug); // Fill arguments argvv[0] = (char *) pspath.c_str(); @@ -428,14 +441,15 @@ int loginuser(const std::string &home, const std::string &user, uid_t uid, gid_t } // set HOME env - char *h = new char[8 + home.length()]; - sprintf(h, "HOME=%s", home.c_str()); + size_t len = home.length() + 8; + char *h = new char[len]; + snprintf(h, len, "HOME=%s", home.c_str()); putenv(h); if (gDebug > 0) Info("loginuser: set '%s'", h); // set USER env - char *u = new char[8 + user.length()]; - sprintf(u, "USER=%s", user.c_str()); + char *u = new char[len]; + snprintf(u, len, "USER=%s", user.c_str()); putenv(u); if (gDebug > 0) Info("loginuser: set '%s'", u); @@ -476,32 +490,16 @@ int assertdir(const std::string &path, uid_t u, gid_t g, unsigned int mode) Info("assertdir: ERROR: could not get privileges (errno: %d)", errno); return -1; } - - struct stat st; - if (stat(path.c_str(), &st) != 0) { - if (errno == ENOENT) { - if (mkdir(path.c_str(), mode) != 0) { - Info("assertdir: ERROR: unable to create path: %s (errno: %d)", path.c_str(), errno); - return -1; - } - if (stat(path.c_str(), &st) != 0) { - Info("assertdir: ERROR: unable to stat path: %s after creation! (errno: %d)", path.c_str(), errno); - return -1; - } - } else { - // Failure: stop - Info("assertdir: ERROR: unable to stat path: %s (errno: %d)", path.c_str(), errno); - return -1; - } - } - // Make sure the ownership is right - if (st.st_uid != u || st.st_gid != g) { - // Set ownership of the path to the client - if (chown(path.c_str(), u, g) == -1) { - Info("assertdir: ERROR: unable to set ownership on path: %s (errno: %d)", path.c_str(), errno); - return -1; - } + // Make the directory: ignore failure if already existing ... + if (mkdir(path.c_str(), mode) != 0 && (errno != EEXIST)) { + Info("assertdir: ERROR: unable to create path: %s (errno: %d)", path.c_str(), errno); + return -1; + } + // Set ownership of the path to the client + if (chown(path.c_str(), u, g) == -1) { + Info("assertdir: ERROR: unable to set ownership on path: %s (errno: %d)", path.c_str(), errno); + return -1; } // We are done @@ -529,35 +527,16 @@ int mvfile(const std::string &from, const std::string &to, uid_t u, gid_t g, uns return -1; } - // Check the final destination - struct stat st; - if (stat(to.c_str(), &st) != 0) { - if (errno == ENOENT) { - Info("mvfile: ERROR: operation apparently OK but final path '%s' does not exist(!)", to.c_str()); - return -1; - } else { - // Failure: stop - Info("mvfile: ERROR: unable to stat final path: %s (errno: %d)", to.c_str(), errno); - return -1; - } - } - - // Make sure the access mode is right - if (st.st_mode != mode) { - // Set ownership of the path to the client - if (chmod(to.c_str(), mode) == -1) { - Info("mvfile: ERROR: unable to set mode %o on path: %s (errno: %d)", mode, to.c_str(), errno); - return -1; - } + // Set ownership of the path to the client + if (chmod(to.c_str(), mode) == -1) { + Info("mvfile: ERROR: unable to set mode %o on path: %s (errno: %d)", mode, to.c_str(), errno); + return -1; } // Make sure the ownership is right - if (st.st_uid != u || st.st_gid != g) { - // Set ownership of the path to the client - if (chown(to.c_str(), u, g) == -1) { - Info("mvfile: ERROR: unable to set ownership on path: %s (errno: %d)", to.c_str(), errno); - return -1; - } + if (chown(to.c_str(), u, g) == -1) { + Info("mvfile: ERROR: unable to set ownership on path: %s (errno: %d)", to.c_str(), errno); + return -1; } // We are done @@ -815,7 +794,6 @@ int setownerships(int euid, const std::string &us, const std::string &gr, return 0; } - //_____________________________________________________________________________ int changeown(const std::string &path, uid_t u, gid_t g) { @@ -825,23 +803,10 @@ int changeown(const std::string &path, uid_t u, gid_t g) if (path.length() <= 0) return -1; - struct stat st; - if (stat(path.c_str(), &st) != 0) { - // Failure: stop - Info("changeown: ERROR: problems stat-ing '%s' (errno: %d)", - path.c_str(), (int)errno); - return -1; - } - // If is a directory apply this on it - if (S_ISDIR(st.st_mode)) { + DIR *dir = opendir(path.c_str()); + if (dir) { // Loop over the dir - DIR *dir = opendir(path.c_str()); - if (!dir) { - Info("changeown: ERROR: problems opening '%s' (errno: %d)", - path.c_str(), (int)errno); - return -1; - } std::string proot(path); if (!(proot.rfind('/') != proot.length() - 1)) proot += "/"; @@ -851,42 +816,25 @@ int changeown(const std::string &path, uid_t u, gid_t g) std::string fn(proot); fn += ent->d_name; - struct stat xst; - if (stat(fn.c_str(), &xst) == 0) { - // If is a directory apply this on it - if (S_ISDIR(xst.st_mode)) { - if (changeown(fn.c_str(), u, g) != 0) { - Info("changeown: ERROR: problems changing recursively ownership of '%s'", - fn.c_str()); - closedir(dir); - return -1; - } - } else { - // Get the privileges, if needed - rpdprivguard pguard((uid_t)0, (gid_t)0); - if (rpdbadpguard(pguard, u)) { - Info("changeown: ERROR: could not get privileges (errno: %d)", errno); - closedir(dir); - return -1; - } - // Set ownership of the path to the client - if (chown(fn.c_str(), u, g) == -1) { - Info("changeown: ERROR: cannot set user ownership on path '%s' (errno: %d)", - fn.c_str(), errno); - closedir(dir); - return -1; - } - } - } else { - Info("changeown: ERROR: problems stat-ing '%s' (errno: %d)", - fn.c_str(), (int)errno); + // Apply recursively + if (changeown(fn.c_str(), u, g) != 0) { + Info("changeown: ERROR: problems changing recursively ownership of '%s'", + fn.c_str()); + closedir(dir); + return -1; } + } // Close the directory closedir(dir); - - } else if ((st.st_uid != u) || (st.st_gid != g)) { - // Get the privileges, if needed + } else { + // If it was a directory and opening failed, we fail + if (errno != 0 && (errno != ENOTDIR)) { + Info("changeown: ERROR: problems opening '%s' (errno: %d)", + path.c_str(), (int)errno); + return -1; + } + // Else it may be a file ... get the privileges, if needed rpdprivguard pguard((uid_t)0, (gid_t)0); if (rpdbadpguard(pguard, u)) { Info("changeown: ERROR: could not get privileges (errno: %d)", errno); diff --git a/proof/proofplayer/inc/LinkDef.h b/proof/proofplayer/inc/LinkDef.h index c8a4090e9825d..9413c9f748f58 100644 --- a/proof/proofplayer/inc/LinkDef.h +++ b/proof/proofplayer/inc/LinkDef.h @@ -46,7 +46,6 @@ #pragma link C++ class TDrawFeedback+; #pragma link C++ class TStatsFeedback+; #pragma link C++ class TStatus-; -#pragma link C++ class TProofOutputFile+; #pragma link C++ class TOutputListSelectorDataMap+; diff --git a/proof/proofplayer/inc/TEventIter.h b/proof/proofplayer/inc/TEventIter.h index 84bbd68a9b2f5..b29c41929de52 100644 --- a/proof/proofplayer/inc/TEventIter.h +++ b/proof/proofplayer/inc/TEventIter.h @@ -72,6 +72,8 @@ class TEventIter : public TObject { TEntryList *fEntryList; //! entry list for processing Long64_t fEntryListPos; //! current position in the entrylist + TList *fPackets; // list of packets processed packets + Int_t LoadDir(); // Load the directory pointed to by fElem public: @@ -88,6 +90,8 @@ class TEventIter : public TObject { virtual void PreProcessEvent(Long64_t) = 0; virtual void StopProcess(Bool_t abort); + TList *GetPackets() { return fPackets; } + static TEventIter *Create(TDSet *dset, TSelector *sel, Long64_t first, Long64_t num); ClassDef(TEventIter,0) // Event iterator used by TProofPlayer's diff --git a/proof/proofplayer/inc/TPacketizerUnit.h b/proof/proofplayer/inc/TPacketizerUnit.h index affe4bee0b536..120103e931988 100644 --- a/proof/proofplayer/inc/TPacketizerUnit.h +++ b/proof/proofplayer/inc/TPacketizerUnit.h @@ -49,21 +49,28 @@ class TPacketizerUnit : public TVirtualPacketizer { private: TList *fPackets; // All processed packets TMap *fWrkStats; // Worker status, keyed by correspondig TSlave + TList *fWrkExcluded; // List of nodes excluded from distribution + // (submasters with no active workers) TStopwatch *fStopwatch; // For measuring the start time of each packet Long64_t fProcessing; // Event being processed Long64_t fAssigned; // Entries processed or being processed. Double_t fCalibFrac; // Size of the calibrating packet as fraction of Ntot/Nwrk Long64_t fNumPerWorker; // Number of cycles per worker, if this option // is chosen + Bool_t fFixedNum; // Whether we must assign a fixed number of cycles per worker + + Long64_t fPacketSeq; // Sequential number of the last packet assigned + TList *fInput; // Input list TPacketizerUnit(); TPacketizerUnit(const TPacketizerUnit&); // no implementation, will generate - void operator=(const TPacketizerUnit&); // error on accidental usage + void operator=(const TPacketizerUnit&); // error on accidental usage public: TPacketizerUnit(TList *slaves, Long64_t num, TList *input, TProofProgressStatus *st = 0); virtual ~TPacketizerUnit(); + Int_t AssignWork(TDSet * /*dset*/, Long64_t /*first*/, Long64_t num); TDSetElement *GetNextPacket(TSlave *sl, TMessage *r); Double_t GetCurrentTime(); @@ -71,6 +78,8 @@ class TPacketizerUnit : public TVirtualPacketizer { Float_t GetCurrentRate(Bool_t &all); Int_t GetActiveWorkers() { return fWrkStats->GetSize(); } + Int_t AddWorkers(TList *workers); + ClassDef(TPacketizerUnit,0) //Generate work packets for parallel processing }; diff --git a/proof/proofplayer/inc/TProofPlayer.h b/proof/proofplayer/inc/TProofPlayer.h index 58693c03bb90c..ed24792becf89 100644 --- a/proof/proofplayer/inc/TProofPlayer.h +++ b/proof/proofplayer/inc/TProofPlayer.h @@ -69,7 +69,8 @@ class TStatus; class TTimer; class THashList; class TH1; - +class TFile; +class TStopwatch; //------------------------------------------------------------------------ @@ -80,7 +81,7 @@ class TProofPlayer : public TVirtualProofPlayer { protected: TList *fInput; //-> list with input objects - TList *fOutput; // list with output objects + THashList *fOutput; // list with output objects TSelector *fSelector; //! the latest selector Bool_t fCreateSelObj; //! kTRUE when fSelector has been created locally TClass *fSelectorClass; //! class of the latest selector @@ -107,6 +108,15 @@ class TProofPlayer : public TVirtualProofPlayer { TTimer *fDispatchTimer; //Dispatch pending events while processing + TTimer *fProcTimeTimer; //Notifies reaching of allowed max proc time + TStopwatch *fProcTime; //Packet proc time + + TString fOutputFilePath; //Path to file with (partial) results of the query + TFile *fOutputFile; //TFile object attached to fOutputFilePath + Long_t fSaveMemThreshold; //Threshold for saving output to file + Bool_t fSavePartialResults; //Whether to save the partial results + Bool_t fSaveResultsPerPacket; //Whether to save partial results after each packet + static THashList *fgDrawInputPars; // List of input parameters to be kept on drawing actions void *GetSender() { return this; } //used to set gTQSender @@ -135,7 +145,8 @@ class TProofPlayer : public TVirtualProofPlayer { void MapOutputListToDataMembers() const; public: - enum EStatusBits { kDispatchOneEvent = BIT(15), kIsProcessing = BIT(16) }; + enum EStatusBits { kDispatchOneEvent = BIT(15), kIsProcessing = BIT(16), + kMaxProcTimeReached = BIT(17), kMaxProcTimeExtended = BIT(18) }; TProofPlayer(TProof *proof = 0); virtual ~TProofPlayer(); @@ -146,6 +157,7 @@ class TProofPlayer : public TVirtualProofPlayer { Long64_t Process(TDSet *set, TSelector *selector, Option_t *option = "", Long64_t nentries = -1, Long64_t firstentry = 0); + virtual Bool_t JoinProcess(TList *workers); TVirtualPacketizer *GetPacketizer() const { return 0; } Long64_t Finalize(Bool_t force = kFALSE, Bool_t sync = kFALSE); Long64_t Finalize(TQueryResult *qr); @@ -219,6 +231,9 @@ class TProofPlayer : public TVirtualProofPlayer { Long64_t GetCacheSize(); Int_t GetLearnEntries(); + void SetOutputFilePath(const char *fp) { fOutputFilePath = fp; } + Int_t SavePartialResults(Bool_t queryend = kFALSE, Bool_t force = kFALSE); + void SetProcessing(Bool_t on = kTRUE); TProofProgressStatus *GetProgressStatus() const { return fProgressStatus; } @@ -286,8 +301,10 @@ class TProofPlayerRemote : public TProofPlayer { Bool_t fMergeFiles; // is True when merging output files centrally is needed TDSet *fDSet; //!tdset for current processing ErrorHandlerFunc_t fErrorHandler; // Store previous handler when redirecting output - Bool_t fUseTH1Merge; // If kTRUE forces use of TH1::Merge [kFALSE] + Bool_t fMergeTH1OneByOne; // If kTRUE forces TH1 merge one-by-one [kTRUE] TH1 *fProcPackets; //!Histogram with packets being processed (owned by TPerfStats) + TMessage *fProcessMessage; // Process message to replay when adding new workers dynamically + TString fSelectorFileName; // Current Selector's name, set by Process() virtual Bool_t HandleTimer(TTimer *timer); Int_t InitPacketizer(TDSet *dset, Long64_t nentries, @@ -307,7 +324,8 @@ class TProofPlayerRemote : public TProofPlayer { TProofPlayerRemote(TProof *proof = 0) : fProof(proof), fOutputLists(0), fFeedback(0), fFeedbackLists(0), fPacketizer(0), fMergeFiles(kFALSE), fDSet(0), fErrorHandler(0), - fUseTH1Merge(kFALSE), fProcPackets(0) + fMergeTH1OneByOne(kTRUE), fProcPackets(0), + fProcessMessage(0) { fProgressStatus = new TProofProgressStatus(); } virtual ~TProofPlayerRemote(); // Owns the fOutput list virtual Long64_t Process(TDSet *set, const char *selector, @@ -316,6 +334,7 @@ class TProofPlayerRemote : public TProofPlayer { virtual Long64_t Process(TDSet *set, TSelector *selector, Option_t *option = "", Long64_t nentries = -1, Long64_t firstentry = 0); + virtual Bool_t JoinProcess(TList *workers); virtual Long64_t Finalize(Bool_t force = kFALSE, Bool_t sync = kFALSE); virtual Long64_t Finalize(TQueryResult *qr); Long64_t DrawSelect(TDSet *set, const char *varexp, diff --git a/proof/proofplayer/inc/TStatus.h b/proof/proofplayer/inc/TStatus.h index 247e422d9cf1f..322e2793aa067 100644 --- a/proof/proofplayer/inc/TStatus.h +++ b/proof/proofplayer/inc/TStatus.h @@ -39,7 +39,9 @@ namespace std { using ::set; using ::string; } class TStatus : public TNamed { public: - enum EProcStatus { kNotOk = 15}; // True if status of things are not OK + enum EProcStatus { + kNotOk = BIT(15) // True if status of things are not OK + }; private: TList fMsgs; // list of error messages diff --git a/proof/proofplayer/inc/TVirtualPacketizer.h b/proof/proofplayer/inc/TVirtualPacketizer.h index 5e45945df6a30..a9c72f8a24298 100644 --- a/proof/proofplayer/inc/TVirtualPacketizer.h +++ b/proof/proofplayer/inc/TVirtualPacketizer.h @@ -132,6 +132,7 @@ class TVirtualPacketizer : public TObject { virtual void StopProcess(Bool_t abort, Bool_t stoptimer = kFALSE); TList *GetFailedPackets() { return fFailedPackets; } void SetFailedPackets(TList *list) { fFailedPackets = list; } + virtual Int_t AddWorkers(TList *workers); Long64_t GetBytesRead() const { return (fProgressStatus? fProgressStatus->GetBytesRead() : 0); } Long64_t GetReadCalls() const { return (fProgressStatus? fProgressStatus->GetReadCalls() : 0); } diff --git a/proof/proofplayer/src/TEventIter.cxx b/proof/proofplayer/src/TEventIter.cxx index 1c9834140a477..fa9a0d77c23d2 100644 --- a/proof/proofplayer/src/TEventIter.cxx +++ b/proof/proofplayer/src/TEventIter.cxx @@ -72,6 +72,15 @@ TEventIter::TEventIter() fElemNum = 0; fElemCur = -1; ResetBit(TEventIter::kData); + + if ((fPackets = new TList)) { + TString n("ProcessedPackets_"); + if (gProofServ) n += gProofServ->GetOrdinal(); + fPackets->SetName(n); + Info("TEventIter", "fPackets list '%s' created", n.Data()); + } else { + Warning("TEventIter", "fPackets list could not be created"); + } } //______________________________________________________________________________ @@ -96,6 +105,15 @@ TEventIter::TEventIter(TDSet *dset, TSelector *sel, Long64_t first, Long64_t num fElemNum = 0; fElemCur = -1; ResetBit(TEventIter::kData); + + if ((fPackets = new TList)) { + TString n("ProcessedPackets_"); + if (gProofServ) n += gProofServ->GetOrdinal(); + fPackets->SetName(n); + Info("TEventIter", "fPackets list '%s' created", n.Data()); + } else { + Warning("TEventIter", "fPackets list could not be created"); + } } //______________________________________________________________________________ @@ -103,6 +121,10 @@ TEventIter::~TEventIter() { // Destructor + if (fPackets) { + fPackets->SetOwner(kTRUE); + SafeDelete(fPackets); + } delete fFile; } @@ -253,14 +275,28 @@ Int_t TEventIterUnit::GetNextPacket(Long64_t &fst, Long64_t &num, if (fDSet->TestBit(TDSet::kIsLocal)) { if (fElem) { - SafeDelete(fElem); + if (fPackets) { + fPackets->Add(fElem); + PDB(kLoop, 2) + Info("GetNextEvent", "packet added to list (sz: %d)", fPackets->GetSize()); + fElem = 0; + } else { + SafeDelete(fElem); + } return -1; } else { fElem = new TDSetElement("", "", "", 0, fNum); fElem->SetBit(TDSetElement::kEmpty); } } else { - SafeDelete(fElem); + if (fPackets && fElem) { + fPackets->Add(fElem); + PDB(kLoop, 2) + Info("GetNextEvent", "packet added to list (sz: %d)", fPackets->GetSize()); + fElem = 0; + } else { + SafeDelete(fElem); + } if (!(fElem = fDSet->Next())) return -1; } @@ -302,14 +338,28 @@ Long64_t TEventIterUnit::GetNextEvent() if (fDSet->TestBit(TDSet::kIsLocal)) { if (fElem) { - SafeDelete(fElem); + if (fPackets) { + fPackets->Add(fElem); + PDB(kLoop, 2) + Info("GetNextEvent", "packet added to list (sz: %d)", fPackets->GetSize()); + fElem = 0; + } else { + SafeDelete(fElem); + } return -1; } else { fElem = new TDSetElement("", "", "", 0, fNum); fElem->SetBit(TDSetElement::kEmpty); } } else { - SafeDelete(fElem); + if (fPackets && fElem) { + fPackets->Add(fElem); + PDB(kLoop, 2) + Info("GetNextEvent", "packet added to list (sz: %d)", fPackets->GetSize()); + fElem = 0; + } else { + SafeDelete(fElem); + } if (!(fElem = fDSet->Next())) return -1; } @@ -388,7 +438,15 @@ Int_t TEventIterObj::GetNextPacket(Long64_t &first, Long64_t &num, fOldBytesRead = bytesRead; } - SafeDelete(fElem); + if (fElem) { + // Save it to the list of processed packets + if (fPackets) { + fPackets->Add(fElem); + fElem = 0; + } else { + SafeDelete(fElem); + } + } fElem = fDSet->Next(fKeys->GetSize()); if (fElem && fElem->GetEntryList()) { Error("GetNextPacket", "entry- or event-list not available"); @@ -495,7 +553,15 @@ Long64_t TEventIterObj::GetNextEvent() fOldBytesRead = bytesRead; } - SafeDelete(fElem); + if (fElem) { + // Save it to the list of processed packets + if (fPackets) { + fPackets->Add(fElem); + fElem = 0; + } else { + SafeDelete(fElem); + } + } fElem = fDSet->Next(fKeys->GetSize()); if (fElem && fElem->GetEntryList()) { Error("GetNextEvent", "Entry- or event-list not available"); @@ -945,7 +1011,15 @@ Int_t TEventIterTree::GetNextPacket(Long64_t &first, Long64_t &num, fOldBytesRead = totBytesRead; } - SafeDelete(fElem); + if (fElem) { + // Save it to the list of processed packets + if (fPackets) { + fPackets->Add(fElem); + fElem = 0; + } else { + SafeDelete(fElem); + } + } while (!fElem) { // For a corrupted/invalid file the request for a new packet is with totalEntries = -1 // (the default) so that the packetizer invalidates the element @@ -1115,9 +1189,15 @@ Long64_t TEventIterTree::GetNextEvent() if (fElem) { rest = fElem->GetNum(); if (fElemCur >= 0) rest -= (fElemCur + 1 - fElemFirst); + // Save it to the list of processed packets + if (fPackets) { + fPackets->Add(fElem); + fElem = 0; + } else { + SafeDelete(fElem); + } } - SafeDelete(fElem); while (!fElem) { // For a corrupted/invalid file the request for a new packet is with totalEntries = -1 // (the default) so that the packetizer invalidates the element diff --git a/proof/proofplayer/src/TPacketizerFile.cxx b/proof/proofplayer/src/TPacketizerFile.cxx index 86ca40627b712..9c5cd21c065c8 100644 --- a/proof/proofplayer/src/TPacketizerFile.cxx +++ b/proof/proofplayer/src/TPacketizerFile.cxx @@ -109,7 +109,7 @@ TPacketizerFile::TPacketizerFile(TList *workers, Long64_t, TList *input, return; } - // Check if the files not explicitely assigned have to be processed + // Check if the files not explicitly assigned have to be processed Int_t procnotass = 1; if (TProof::GetParameter(input, "PROOF_ProcessNotAssigned", procnotass) == 0) { if (procnotass == 0) { diff --git a/proof/proofplayer/src/TPacketizerUnit.cxx b/proof/proofplayer/src/TPacketizerUnit.cxx index 8a50ceca7766c..ed9f8ef764015 100644 --- a/proof/proofplayer/src/TPacketizerUnit.cxx +++ b/proof/proofplayer/src/TPacketizerUnit.cxx @@ -94,6 +94,7 @@ TPacketizerUnit::TSlaveStat::TSlaveStat(TSlave *slave, TList *input) // Initialize the circularity ntple for speed calculations fCircNtp = new TNtupleD("Speed Circ Ntp", "Circular process info","tm:ev"); + fCircNtp->SetDirectory(0); TProof::GetParameter(input, "PROOF_TPacketizerUnitCircularity", fCircLvl); fCircLvl = (fCircLvl > 0) ? fCircLvl : 5; fCircNtp->SetCircular(fCircLvl); @@ -106,7 +107,6 @@ TPacketizerUnit::TSlaveStat::~TSlaveStat() { // Destructor - fCircNtp->SetDirectory(0); SafeDelete(fCircNtp); } @@ -179,12 +179,16 @@ TPacketizerUnit::TPacketizerUnit(TList *slaves, Long64_t num, TList *input, // Init pointer members fWrkStats = 0; fPackets = 0; + fInput = input; + fFixedNum = kFALSE; Int_t fixednum = -1; - if (TProof::GetParameter(input, "PROOF_PacketizerFixedNum", fixednum) != 0 || fixednum <= 0) - fixednum = 0; - if (fixednum == 1) + if (TProof::GetParameter(input, "PROOF_PacketizerFixedNum", fixednum) != 0 || fixednum <= 0) { + fFixedNum = kFALSE; + } else { Info("TPacketizerUnit", "forcing the same cycles on each worker"); + fFixedNum = kTRUE; + } fCalibFrac = 0.01; if (TProof::GetParameter(input, "PROOF_PacketizerCalibFrac", fCalibFrac) != 0 || fCalibFrac <= 0) @@ -214,6 +218,7 @@ TPacketizerUnit::TPacketizerUnit(TList *slaves, Long64_t num, TList *input, fProcessing = 0; fAssigned = 0; + fPacketSeq = 0; fStopwatch = new TStopwatch(); @@ -222,29 +227,72 @@ TPacketizerUnit::TPacketizerUnit(TList *slaves, Long64_t num, TList *input, fWrkStats = new TMap; fWrkStats->SetOwner(kFALSE); + fWrkExcluded = 0; TSlave *slave; TIter si(slaves); - while ((slave = (TSlave*) si.Next())) - fWrkStats->Add(slave, new TSlaveStat(slave, input)); + while ((slave = (TSlave*) si.Next())) { + if (slave->GetParallel() > 0) { + fWrkStats->Add(slave, new TSlaveStat(slave, input)); + } else { + if (!fWrkExcluded) { + fWrkExcluded = new TList; + fWrkExcluded->SetOwner(kFALSE); + } + PDB(kPacketizer,2) + Info("TPacketizerUnit", "node '%s' has NO active worker: excluded from work distribution", slave->GetOrdinal()); + fWrkExcluded->Add(slave); + } + } - fTotalEntries = num; + fTotalEntries = 0; fNumPerWorker = -1; - if (fixednum == 1 && fWrkStats->GetSize() > 0) { - // Approximate number: the exact number is determined in GetNextPacket - fNumPerWorker = fTotalEntries / fWrkStats->GetSize(); - if (fNumPerWorker == 0) fNumPerWorker = 1; - } + if (num > 0 && AssignWork(0,0,num) != 0) + Warning("TPacketizerUnit", "some problems assigning work"); // Save the config parameters in the dedicated list so that they will be saved // in the outputlist and therefore in the relevant TQueryResult - fConfigParams->Add(new TParameter<Long64_t>("PROOF_PacketizerFixedNum", fNumPerWorker)); fConfigParams->Add(new TParameter<Float_t>("PROOF_PacketizerCalibFrac", fCalibFrac)); fStopwatch->Start(); PDB(kPacketizer,1) Info("TPacketizerUnit", "return"); } +//______________________________________________________________________________ +Int_t TPacketizerUnit::AssignWork(TDSet *, Long64_t, Long64_t num) +{ + // Assign work to be done to this packetizer + + if (num < 0) { + Error("AssignWork", "assigned a negative number (%lld) of cycles - protocol error?", num); + return -1; + } + + fTotalEntries += num; + PDB(kPacketizer,1) + Info("AssignWork", "assigned %lld additional cycles (new total: %lld)", num, fTotalEntries); + + // Update fixed number counter + if (fFixedNum && fWrkStats->GetSize() > 0) { + // Approximate number: the exact number is determined in GetNextPacket + fNumPerWorker = fTotalEntries / fWrkStats->GetSize(); + if (fNumPerWorker == 0) fNumPerWorker = 1; + } + + // Update/Save the config parameters in the dedicated list so that they will be saved + // in the outputlist and therefore in the relevant TQueryResult + TParameter<Long64_t> *fn = + (TParameter<Long64_t> *) fConfigParams->FindObject("PROOF_PacketizerFixedNum"); + if (fn) { + fn->SetVal(fNumPerWorker); + } else { + fConfigParams->Add(new TParameter<Long64_t>("PROOF_PacketizerFixedNum", fNumPerWorker)); + } + + // Done + return 0; +} + //______________________________________________________________________________ TPacketizerUnit::~TPacketizerUnit() { @@ -253,6 +301,7 @@ TPacketizerUnit::~TPacketizerUnit() if (fWrkStats) fWrkStats->DeleteValues(); SafeDelete(fWrkStats); + SafeDelete(fWrkExcluded); SafeDelete(fPackets); SafeDelete(fStopwatch); } @@ -303,7 +352,15 @@ TDSetElement *TPacketizerUnit::GetNextPacket(TSlave *sl, TMessage *r) // Find slave TSlaveStat *slstat = (TSlaveStat*) fWrkStats->GetValue(sl); - R__ASSERT(slstat != 0); + if (!slstat) { + // If the worker is none of the known lists, we issue a warning + if (!fWrkExcluded->FindObject(sl)) { + Warning("GetNextPacket", "Received a packet request from an unknown slave: %s:%s", + sl->GetName(), sl->GetOrdinal()); + } + // Just return, this worker node is not active + return 0; + } PDB(kPacketizer,2) Info("GetNextPacket","worker-%s: fAssigned %lld\t", sl->GetOrdinal(), fAssigned); @@ -323,7 +380,7 @@ TDSetElement *TPacketizerUnit::GetNextPacket(TSlave *sl, TMessage *r) // Calculate the progress made in the last packet TProofProgressStatus *progress = 0; if (status) { - // upadte the worker status + // update the worker status numev = status->GetEntries() - slstat->GetEntriesProcessed(); progress = slstat->AddProcessed(status); if (progress) { @@ -374,9 +431,24 @@ TDSetElement *TPacketizerUnit::GetNextPacket(TSlave *sl, TMessage *r) } if (fAssigned == fTotalEntries) { - // Send last timer message - HandleTimer(0); - return 0; + Bool_t done = kTRUE; + // If we are on a submaster, check if there is something else to do + if (gProofServ && gProofServ->IsMaster() && !gProofServ->IsTopMaster()) { + TDSetElement *nxe = gProofServ->GetNextPacket(); + if (nxe) { + if (AssignWork(0,0,nxe->GetNum()) == 0) { + if (fAssigned < fTotalEntries) done = kFALSE; + } else { + Error("GetNextPacket", "problems assigning additional work: stop"); + } + SafeDelete(nxe); + } + } + if (done) { + // Send last timer message + HandleTimer(0); + return 0; + } } if (fStop) { @@ -430,10 +502,10 @@ TDSetElement *TPacketizerUnit::GetNextPacket(TSlave *sl, TMessage *r) if (wrkStat->fRate > 0) { nrm++; sumRate += wrkStat->fRate; - PDB(kPacketizer,3) - Info("GetNextPacket", "%d: worker-%s: rate %lf /s (sum: %lf /s)", - nrm, tmpWrk->GetOrdinal(), wrkStat->fRate, sumRate); } + PDB(kPacketizer,3) + Info("GetNextPacket", "%d: worker-%s: rate %lf /s (sum: %lf /s)", + nrm, tmpWrk->GetOrdinal(), wrkStat->fRate, sumRate); } else { Warning("GetNextPacket", "dynamic_cast<TSlaveStat *> failing on value for '%s (%s)'! Skipping", tmpWrk->GetName(), tmpWrk->GetOrdinal()); @@ -491,15 +563,19 @@ TDSetElement *TPacketizerUnit::GetNextPacket(TSlave *sl, TMessage *r) fProcessing = (num < (fTotalEntries - fAssigned)) ? num : (fTotalEntries - fAssigned); - // Set the informations of the current slave + // Set the information of the current slave slstat->fLastProcessed = fProcessing; // Set the start time of the current packet slstat->fTimeInstant = cTime; + + // Update the sequential number + fPacketSeq++; + TString sseq = TString::Format("p%lld", fPacketSeq); PDB(kPacketizer,2) Info("GetNextPacket", "worker-%s: num %lld, processing %lld, remaining %lld",sl->GetOrdinal(), num, fProcessing, (fTotalEntries - fAssigned - fProcessing)); - TDSetElement *elem = new TDSetElement("", "", "", fAssigned, fProcessing); + TDSetElement *elem = new TDSetElement(sseq, sseq, "", fAssigned, fProcessing); elem->SetBit(TDSetElement::kEmpty); // Update the total counter @@ -507,3 +583,32 @@ TDSetElement *TPacketizerUnit::GetNextPacket(TSlave *sl, TMessage *r) return elem; } + +//______________________________________________________________________________ +Int_t TPacketizerUnit::AddWorkers(TList *workers) +{ + // Adds new workers. Returns the number of workers added, or -1 on failure. + + if (!workers) { + Error("AddWorkers", "Null list of new workers!"); + return -1; + } + + Int_t curNumOfWrks = fWrkStats->GetEntries(); + + TSlave *sl; + TIter next(workers); + while (( sl = dynamic_cast<TSlave*>(next()) )) + fWrkStats->Add(sl, new TSlaveStat(sl, fInput)); + + fNumPerWorker = -1; + if (fFixedNum && fWrkStats->GetSize() > 0) { + // Approximate number: the exact number is determined in GetNextPacket + fNumPerWorker = (fNumPerWorker * curNumOfWrks) / fWrkStats->GetSize(); + if (fNumPerWorker == 0) fNumPerWorker = 1; + } + + fConfigParams->Add(new TParameter<Long64_t>("PROOF_PacketizerFixedNum", fNumPerWorker)); + + return fWrkStats->GetEntries(); +} diff --git a/proof/proofplayer/src/TPerfStats.cxx b/proof/proofplayer/src/TPerfStats.cxx index 4520d8506207f..014c2bc4304ca 100644 --- a/proof/proofplayer/src/TPerfStats.cxx +++ b/proof/proofplayer/src/TPerfStats.cxx @@ -481,7 +481,7 @@ void TPerfStats::PacketEvent(const char *slave, const char* slavename, const cha Int_t est = (pst) ? pst->GetExitStatus() : -1; values.Add(new TParameter<int>("status", est)); // Root version - TString rver = TString::Format("%s|r%d", gROOT->GetVersion(), gROOT->GetSvnRevision()); + TString rver = TString::Format("%s|%s", gROOT->GetVersion(), gROOT->GetGitCommit()); values.Add(new TNamed("rootver", rver.Data())); for (Int_t i = 0; i < fMonSenders.GetEntries(); i++) { @@ -678,7 +678,7 @@ void TPerfStats::WriteQueryLog() Int_t est = (pst) ? pst->GetExitStatus() : -1; values.Add(new TParameter<int>("status", est)); // Root version - TString rver = TString::Format("%s|r%d", gROOT->GetVersion(), gROOT->GetSvnRevision()); + TString rver = TString::Format("%s|%s", gROOT->GetVersion(), gROOT->GetGitCommit()); values.Add(new TNamed("rootver", rver.Data())); for (Int_t i = 0; i < fMonSenders.GetEntries(); i++) { diff --git a/proof/proofplayer/src/TProofDraw.cxx b/proof/proofplayer/src/TProofDraw.cxx index 6b1c9b18fedf0..071b95419eafb 100644 --- a/proof/proofplayer/src/TProofDraw.cxx +++ b/proof/proofplayer/src/TProofDraw.cxx @@ -159,7 +159,10 @@ Bool_t TProofDraw::Notify() return kFALSE; } if (!fStatus->IsOk()) return kFALSE; - if (!fManager) return kFALSE; + if (!fManager) { + fAbort = TSelector::kAbortProcess; + return kFALSE; + } fManager->UpdateFormulaLeaves(); return kTRUE; } @@ -866,6 +869,7 @@ void TProofDrawHist::Terminate(void) TList l; l.Add(fHistogram); h->Merge(&l); + l.Remove(fHistogram); fOutput->Remove(fHistogram); delete fHistogram; } else { @@ -1307,6 +1311,7 @@ void TProofDrawProfile::Terminate(void) TList l; l.Add(fProfile); pf->Merge(&l); + l.Remove(fProfile); fOutput->Remove(fProfile); delete fProfile; } else { @@ -1549,6 +1554,7 @@ void TProofDrawProfile2D::Terminate(void) TList l; l.Add(fProfile); pf->Merge(&l); + l.Remove(fProfile); fOutput->Remove(fProfile); delete fProfile; } else { diff --git a/proof/proofplayer/src/TProofPlayer.cxx b/proof/proofplayer/src/TProofPlayer.cxx index 947260b5d481c..c6cbd6dedd6e4 100644 --- a/proof/proofplayer/src/TProofPlayer.cxx +++ b/proof/proofplayer/src/TProofPlayer.cxx @@ -59,6 +59,7 @@ #include "TStatus.h" #include "TEventList.h" #include "TProofLimitsFinder.h" +#include "THashList.h" #include "TSortedList.h" #include "TTree.h" #include "TEntryList.h" @@ -75,6 +76,7 @@ #include "TVirtualMonitoring.h" #include "TParameter.h" #include "TOutputListSelectorDataMap.h" +#include "TStopwatch.h" // Timeout exception #define kPEX_STOPPED 1001 @@ -125,8 +127,7 @@ Bool_t TDispatchTimer::Notify() // events while processing. We must act as fast as possible here, so // we just set a flag submitting a request for dispatching pending events - if (gDebug > 0) - Info ("Notify","called!"); + if (gDebug > 0) printf("TDispatchTimer::Notify: called!\n"); fPlayer->SetBit(TProofPlayer::kDispatchOneEvent); @@ -135,6 +136,33 @@ Bool_t TDispatchTimer::Notify() return kTRUE; } +// +// Special timer to notify reach of max packet proc time +//______________________________________________________________________________ +class TProctimeTimer : public TTimer { +private: + TProofPlayer *fPlayer; + +public: + TProctimeTimer(TProofPlayer *p, Long_t to) : TTimer(to, kFALSE), fPlayer(p) { } + + Bool_t Notify(); +}; +//______________________________________________________________________________ +Bool_t TProctimeTimer::Notify() +{ + // Handle expiration of the timer associated with dispatching pending + // events while processing. We must act as fast as possible here, so + // we just set a flag submitting a request for dispatching pending events + + if (gDebug > 0) printf("TProctimeTimer::Notify: called!\n"); + + fPlayer->SetBit(TProofPlayer::kMaxProcTimeReached); + + // One shot only + return kTRUE; +} + // // Special timer to handle stop/abort request via exception raising //______________________________________________________________________________ @@ -176,8 +204,7 @@ Bool_t TStopTimer::Notify() // We raise an exception which will be processed in the // event loop. - if (gDebug > 0) - Info ("Notify","called!"); + if (gDebug > 0) printf("TStopTimer::Notify: called!\n"); if (fAbort) Throw(kPEX_ABORTED); @@ -199,21 +226,28 @@ TProofPlayer::TProofPlayer(TProof *) fFeedbackTimer(0), fFeedbackPeriod(2000), fEvIter(0), fSelStatus(0), fTotalEvents(0), fReadBytesRun(0), fReadCallsRun(0), fProcessedRun(0), - fQueryResults(0), fQuery(0), fDrawQueries(0), - fMaxDrawQueries(1), fStopTimer(0), fStopTimerMtx(0), fDispatchTimer(0) + fQueryResults(0), fQuery(0), fPreviousQuery(0), fDrawQueries(0), + fMaxDrawQueries(1), fStopTimer(0), fStopTimerMtx(0), fDispatchTimer(0), + fProcTimeTimer(0), fProcTime(0), + fOutputFile(0), + fSaveMemThreshold(-1), fSavePartialResults(kFALSE), fSaveResultsPerPacket(kFALSE) { // Default ctor. fInput = new TList; fExitStatus = kFinished; fProgressStatus = new TProofProgressStatus(); + ResetBit(TProofPlayer::kDispatchOneEvent); ResetBit(TProofPlayer::kIsProcessing); + ResetBit(TProofPlayer::kMaxProcTimeReached); + ResetBit(TProofPlayer::kMaxProcTimeExtended); static Bool_t initLimitsFinder = kFALSE; if (!initLimitsFinder && gProofServ && !gProofServ->IsMaster()) { THLimitsFinder::SetLimitsFinder(new TProofLimitsFinder); initLimitsFinder = kTRUE; } + } //______________________________________________________________________________ @@ -229,6 +263,8 @@ TProofPlayer::~TProofPlayer() SafeDelete(fEvIter); SafeDelete(fQueryResults); SafeDelete(fDispatchTimer); + SafeDelete(fProcTimeTimer); + SafeDelete(fProcTime); SafeDelete(fStopTimer); } @@ -717,6 +753,213 @@ void TProofPlayer::DeleteDrawFeedback(TDrawFeedback *f) delete f; } +//______________________________________________________________________________ +Int_t TProofPlayer::SavePartialResults(Bool_t queryend, Bool_t force) +{ + // Save the partial results of this query to a dedicated file under the user + // data directory. The file name has the form + // <session_tag>.q<query_seq_num>.root + // The file pat and the file are created if not existing already. + // Only objects in the outputlist not being TProofOutputFile are saved. + // The packets list 'packets' is saved if given. + // Trees not attached to any file are attached to the open file. + // If 'queryend' is kTRUE evrything is written out (TTrees included). + // The actual saving action is controlled by 'force' and by fSavePartialResults / + // fSaveResultsPerPacket: + // + // fSavePartialResults = kFALSE/kTRUE no-saving/saving + // fSaveResultsPerPacket = kFALSE/kTRUE save-per-query/save-per-packet + // + // The function CheckMemUsage sets fSavePartialResults = 1 if fSaveMemThreshold > 0 and + // ProcInfo_t::fMemResident >= fSaveMemThreshold: from that point on partial results + // are always saved and expensive calls to TSystem::GetProcInfo saved. + // The switch fSaveResultsPerPacket is instead controlled by the user or admin + // who can also force saving in all cases; parameter PROOF_SavePartialResults or + // RC env ProofPlayer.SavePartialResults . + // However, if 'force' is kTRUE, fSavePartialResults and fSaveResultsPerPacket + // are ignored. + // Return -1 in case of problems, 0 otherwise. + + Bool_t save = (force || (fSavePartialResults && + (queryend || fSaveResultsPerPacket))) ? kTRUE : kFALSE; + if (!save) { + PDB(kOutput, 2) + Info("SavePartialResults", "partial result saving disabled"); + return 0; + } + + // Sanity check + if (!gProofServ) { + Error("SavePartialResults", "gProofServ undefined: something really wrong going on!!!"); + return -1; + } + if (!fOutput) { + Error("SavePartialResults", "fOutput undefined: something really wrong going on!!!"); + return -1; + } + + PDB(kOutput, 1) + Info("SavePartialResults", "start saving partial results {%d,%d,%d,%d}", + queryend, force, fSavePartialResults, fSaveResultsPerPacket); + + // Get list of processed packets from the iterator + PDB(kOutput, 2) Info("SavePartialResults", "fEvIter: %p", fEvIter); + + TList *packets = (fEvIter) ? fEvIter->GetPackets() : 0; + PDB(kOutput, 2) Info("SavePartialResults", "list of packets: %p, sz: %d", + packets, (packets ? packets->GetSize(): -1)); + + // Open the file + const char *oopt = "UPDATE"; + // Check if the file has already been defined + TString baseName(fOutputFilePath); + if (fOutputFilePath.IsNull()) { + baseName.Form("output-%s.q%d.root", gProofServ->GetTopSessionTag(), gProofServ->GetQuerySeqNum()); + if (gProofServ->GetDataDirOpts() && strlen(gProofServ->GetDataDirOpts()) > 0) { + fOutputFilePath.Form("%s/%s?%s", gProofServ->GetDataDir(), baseName.Data(), + gProofServ->GetDataDirOpts()); + } else { + fOutputFilePath.Form("%s/%s", gProofServ->GetDataDir(), baseName.Data()); + } + Info("SavePartialResults", "file with (partial) output: '%s'", fOutputFilePath.Data()); + oopt = "RECREATE"; + } + // Open the file in write mode + if (!(fOutputFile = TFile::Open(fOutputFilePath, oopt)) || + (fOutputFile && fOutputFile->IsZombie())) { + Error("SavePartialResults", "cannot open '%s' for writing", fOutputFilePath.Data()); + SafeDelete(fOutputFile); + return -1; + } + + // Save current directory + TDirectory *curdir = gDirectory; + fOutputFile->cd(); + + // Write first the packets list, if required + if (packets) { + TDirectory *packetsDir = fOutputFile->mkdir("packets"); + if (packetsDir) packetsDir->cd(); + packets->Write(0, TObject::kSingleKey | TObject::kOverwrite); + fOutputFile->cd(); + } + + Bool_t notempty = kFALSE; + // Write out the output list + TList torm; + TIter nxo(fOutput); + TObject *o = 0; + while ((o = nxo())) { + // Skip output file drivers + if (o->InheritsFrom(TProofOutputFile::Class())) continue; + // Skip control objets + if (!strncmp(o->GetName(), "PROOF_", 6)) continue; + // Skip data members mapping + if (o->InheritsFrom(TOutputListSelectorDataMap::Class())) continue; + // Skip missing file info + if (!strcmp(o->GetName(), "MissingFiles")) continue; + // Trees need a special treatment + if (o->InheritsFrom("TTree")) { + TTree *t = (TTree *) o; + TDirectory *d = t->GetDirectory(); + // If the tree is not attached to any file ... + if (!d || (d && !d->InheritsFrom("TFile"))) { + // ... we attach it + t->SetDirectory(fOutputFile); + } + if (t->GetDirectory() == fOutputFile) { + if (queryend) { + // ... we write it out + o->Write(0, TObject::kOverwrite); + // At least something in the file + notempty = kTRUE; + // Flag for removal from the outputlist + torm.Add(o); + // Prevent double-deletion attempts + t->SetDirectory(0); + } else { + // ... or we set in automatic flush mode + t->SetAutoFlush(); + } + } + } else if (queryend || fSaveResultsPerPacket) { + // Save overwriting what's already there + o->Write(0, TObject::kOverwrite); + // At least something in the file + notempty = kTRUE; + // Flag for removal from the outputlist + if (queryend) torm.Add(o); + } + } + + // Restore previous directory + gDirectory = curdir; + + // Close the file if required + if (notempty) { + if (!fOutput->FindObject(baseName)) { + TProofOutputFile *po = 0; + // Get directions + TNamed *nm = (TNamed *) fInput->FindObject("PROOF_DefaultOutputOption"); + TString oname = (nm) ? nm->GetTitle() : fOutputFilePath.Data(); + if (nm && oname.BeginsWith("ds:")) { + oname.Replace(0, 3, ""); + TString qtag = + TString::Format("%s_q%d", gProofServ->GetTopSessionTag(), gProofServ->GetQuerySeqNum()); + oname.ReplaceAll("<qtag>", qtag); + // Create the TProofOutputFile for dataset creation + po = new TProofOutputFile(baseName, "DRO", oname.Data()); + } else { + Bool_t hasddir = kFALSE; + // Create the TProofOutputFile for automatic merging + po = new TProofOutputFile(baseName, "M"); + if (oname.BeginsWith("of:")) oname.Replace(0, 3, ""); + if (gProofServ->IsTopMaster()) { + if (!strcmp(TUrl(oname, kTRUE).GetProtocol(), "file")) { + TString dsrv; + TProofServ::GetLocalServer(dsrv); + TProofServ::FilterLocalroot(oname, dsrv); + oname.Insert(0, dsrv); + } + } else { + if (nm) { + // The name has been sent by the client: resolve local place holders + oname.ReplaceAll("<file>", baseName); + } else { + // We did not get any indication; the final file will be in the datadir on + // the top master and it will be resolved there + oname.Form("<datadir>/%s", baseName.Data()); + hasddir = kTRUE; + } + } + po->SetOutputFileName(oname.Data()); + if (hasddir) + // Reset the bit, so that <datadir> has a chance to be resolved in AddOutputObject + po->ResetBit(TProofOutputFile::kOutputFileNameSet); + po->SetName(gSystem->BaseName(oname.Data())); + } + po->AdoptFile(fOutputFile); + fOutput->Add(po); + // Flag the nature of this file + po->SetBit(TProofOutputFile::kSwapFile); + } + } + fOutputFile->Close(); + SafeDelete(fOutputFile); + + // If last call, cleanup the output list from objects saved to file + if (queryend && torm.GetSize() > 0) { + TIter nxrm(&torm); + while ((o = nxrm())) { fOutput->Remove(o); } + } + torm.SetOwner(kFALSE); + + PDB(kOutput, 1) + Info("SavePartialResults", "partial results saved to file"); + // We are done + return 0; +} + //______________________________________________________________________________ Int_t TProofPlayer::AssertSelector(const char *selector_file) { @@ -762,6 +1005,7 @@ void TProofPlayer::UpdateProgressInfo() fProgressStatus->IncEntries(fProcessedRun); fProgressStatus->SetBytesRead(TFile::GetFileBytesRead()-fReadBytesRun); fProgressStatus->SetReadCalls(TFile::GetFileReadCalls()-fReadCallsRun); + fProgressStatus->SetLastUpdate(); if (gMonitoringWriter) gMonitoringWriter->SendProcessingProgress(fProgressStatus->GetEntries(), fReadBytesRun, kFALSE); @@ -798,7 +1042,7 @@ Long64_t TProofPlayer::Process(TDSet *dset, const char *selector_file, version = fSelector->Version(); if (version == 0 && IsClient()) fSelector->GetOutputList()->Clear(); - fOutput = fSelector->GetOutputList(); + fOutput = (THashList *) fSelector->GetOutputList(); if (gProofServ) TPerfStats::Start(fInput, fOutput); @@ -849,6 +1093,34 @@ Long64_t TProofPlayer::Process(TDSet *dset, const char *selector_file, } fEvIter = TEventIter::Create(dset, fSelector, first, nentries); + // Control file object swap + // <how>*10 + <force> + // <how> = 0 end of run + // 1 after each packet + // <force> = 0 no, swap only if memory threshold is reached + // 1 swap in all cases, accordingly to <how> + Int_t opt = 0; + if (TProof::GetParameter(fInput, "PROOF_SavePartialResults", opt) != 0) { + opt = gEnv->GetValue("ProofPlayer.SavePartialResults", 0); + } + fSaveResultsPerPacket = (opt >= 10) ? kTRUE : kFALSE; + fSavePartialResults = (opt%10 > 0) ? kTRUE : kFALSE; + Info("Process", "save partial results? %d per-packet? %d", fSavePartialResults, fSaveResultsPerPacket); + + // Memory threshold for file object swap + Float_t memfrac = gEnv->GetValue("ProofPlayer.SaveMemThreshold", -1.); + if (memfrac > 0.) { + // The threshold is per core + SysInfo_t si; + if (gSystem->GetSysInfo(&si) == 0) { + fSaveMemThreshold = (Long_t) ((memfrac * si.fPhysRam * 1024.) / si.fCpus); + Info("Process", "memory threshold for saving objects to file set to %ld kB", + fSaveMemThreshold); + } else { + Error("Process", "cannot get SysInfo_t (!)"); + } + } + if (version == 0) { PDB(kLoop,1) Info("Process","Call Begin(0)"); fSelector->Begin(0); @@ -872,6 +1144,10 @@ Long64_t TProofPlayer::Process(TDSet *dset, const char *selector_file, return -1; } ENDTRY; + // Save the results, if needed, closing the file + if (SavePartialResults(kFALSE) < 0) + Warning("Process", "problems seetting up file-object swapping"); + // Create feedback lists, if required SetupFeedback(); @@ -926,6 +1202,8 @@ Long64_t TProofPlayer::Process(TDSet *dset, const char *selector_file, Long64_t fst = -1, num; TEntryList *enl = 0; TEventList *evl = 0; + Long_t maxproctime = -1; + Bool_t newrun = kFALSE; while ((fEvIter->GetNextPacket(fst, num, &enl, &evl) != -1) && !fSelStatus->TestBit(TStatus::kNotOk) && fSelector->GetAbort() == TSelector::kContinue) { @@ -958,9 +1236,58 @@ Long64_t TProofPlayer::Process(TDSet *dset, const char *selector_file, } TProofServ::SetLastMsg(lastMsg); } + // Set the max proc time, if any + if (dset->Current()->GetMaxProcTime() >= 0.) + maxproctime = (Long_t) (1000 * dset->Current()->GetMaxProcTime()); + newrun = (dset->Current()->TestBit(TDSetElement::kNewPacket)) ? kTRUE : kFALSE; } - while (num--) { + ResetBit(TProofPlayer::kMaxProcTimeReached); + ResetBit(TProofPlayer::kMaxProcTimeExtended); + // Setup packet proc time measurement + if (maxproctime > 0) { + if (!fProcTimeTimer) fProcTimeTimer = new TProctimeTimer(this, maxproctime); + fProcTimeTimer->Start(maxproctime, kTRUE); // One shot + if (!fProcTime) fProcTime = new TStopwatch(); + fProcTime->Reset(); // Reset counters + } + Long64_t refnum = num; + if (refnum < 0 && maxproctime <= 0) { + wmsg.Form("neither entries nor max proc time specified:" + " risk of infinite loop: processing aborted"); + Error("Process", "%s", wmsg.Data()); + if (gProofServ) { + wmsg.Insert(0, TString::Format("ERROR:%s, entry:%lld, ", + gProofServ->GetOrdinal(), fProcessedRun)); + gProofServ->SendAsynMessage(wmsg.Data()); + } + fExitStatus = kAborted; + ResetBit(TProofPlayer::kIsProcessing); + break; + } + while (refnum < 0 || num--) { + + // Did we use all our time? + if (TestBit(TProofPlayer::kMaxProcTimeReached)) { + fProcTime->Stop(); + if (!newrun && !TestBit(TProofPlayer::kMaxProcTimeExtended) && refnum > 0) { + // How much are we left with? + Float_t xleft = (refnum > num) ? (Float_t) num / (Float_t) (refnum) : 1.; + if (xleft < 0.2) { + // Give another try, 1.5 times the remaining measured expected time + Long_t mpt = (Long_t) (1500 * num / ((Double_t)(refnum - num) / fProcTime->RealTime())); + SetBit(TProofPlayer::kMaxProcTimeExtended); + fProcTimeTimer->Start(mpt, kTRUE); // One shot + ResetBit(TProofPlayer::kMaxProcTimeReached); + } + } + if (TestBit(TProofPlayer::kMaxProcTimeReached)) { + Info("Process", "max proc time reached (%ld msecs): packet processing stopped:\n%s", + maxproctime, lastMsg.Data()); + + break; + } + } if (!(!fSelStatus->TestBit(TStatus::kNotOk) && fSelector->GetAbort() == TSelector::kContinue)) break; @@ -1065,9 +1392,10 @@ Long64_t TProofPlayer::Process(TDSet *dset, const char *selector_file, // Clean-up the envelop for the current element TPair *currentElem = 0; if ((currentElem = (TPair *) fInput->FindObject("PROOF_CurrentElement"))) { - fInput->Remove(currentElem); - delete currentElem->Key(); - delete currentElem; + if ((currentElem = (TPair *) fInput->Remove(currentElem))) { + delete currentElem->Key(); + delete currentElem; + } } // Final memory footprint @@ -1094,6 +1422,10 @@ Long64_t TProofPlayer::Process(TDSet *dset, const char *selector_file, StopFeedback(); + // Save the results, if needed, closing the file + if (SavePartialResults(kTRUE) < 0) + Warning("Process", "problems saving the results to file"); + SafeDelete(fEvIter); // Finalize @@ -1105,9 +1437,21 @@ Long64_t TProofPlayer::Process(TDSet *dset, const char *selector_file, while ((o = nxo())) { // Special treatment for files if (o->IsA() == TProofOutputFile::Class()) { - ((TProofOutputFile *)o)->SetWorkerOrdinal(gProofServ->GetOrdinal()); - if (!strcmp(((TProofOutputFile *)o)->GetDir(),"")) - ((TProofOutputFile *)o)->SetDir(gProofServ->GetSessionDir()); + TProofOutputFile *of = (TProofOutputFile *)o; + of->Print(); + of->SetWorkerOrdinal(gProofServ->GetOrdinal()); + const char *dir = of->GetDir(); + if (!dir || (dir && strlen(dir) <= 0)) { + of->SetDir(gProofServ->GetSessionDir()); + } else if (dir && strlen(dir) > 0) { + TUrl u(dir); + if (!strcmp(u.GetHost(), "localhost") || !strcmp(u.GetHost(), "127.0.0.1") || + !strcmp(u.GetHost(), "localhost.localdomain")) { + u.SetHost(TUrl(gSystem->HostName()).GetHostFQDN()); + of->SetDir(u.GetUrl(kTRUE)); + } + of->Print(); + } } } @@ -1159,6 +1503,14 @@ Long64_t TProofPlayer::Process(TDSet *dset, TSelector *selector, return Process(dset, (const char *)0, option, nentries, first); } +//______________________________________________________________________________ +Bool_t TProofPlayer::JoinProcess(TList *) +{ + // Not implemented: meaningful only in the remote player. Returns kFALSE. + + return kFALSE; +} + //______________________________________________________________________________ Bool_t TProofPlayer::CheckMemUsage(Long64_t &mfreq, Bool_t &w80r, Bool_t &w80v, TString &wmsg) @@ -1211,6 +1563,9 @@ Bool_t TProofPlayer::CheckMemUsage(Long64_t &mfreq, Bool_t &w80r, w80r = kFALSE; } } + // In saving-partial-results mode flag the saving regime when reached to save expensive calls + // to TSystem::GetProcInfo in SavePartialResults + if (fSaveMemThreshold > 0 && pi.fMemResident >= fSaveMemThreshold) fSavePartialResults = kTRUE; } } // Done @@ -1525,6 +1880,9 @@ TProofPlayerRemote::~TProofPlayerRemote() // Objects stored in maps are already deleted when merging the feedback SafeDelete(fFeedbackLists); SafeDelete(fPacketizer); + + if (fProcessMessage) + SafeDelete(fProcessMessage); } //______________________________________________________________________________ @@ -1541,10 +1899,10 @@ Int_t TProofPlayerRemote::InitPacketizer(TDSet *dset, Long64_t nentries, fExitStatus = kFinished; // This is done here to pickup on the fly changes - Int_t usemerge = 0; - if (TProof::GetParameter(fInput, "PROOF_UseTH1Merge", usemerge) != 0) - usemerge = gEnv->GetValue("ProofPlayer.UseTH1Merge", 0); - fUseTH1Merge = (usemerge == 1) ? kTRUE : kFALSE; + Int_t honebyone = 1; + if (TProof::GetParameter(fInput, "PROOF_MergeTH1OneByOne", honebyone) != 0) + honebyone = gEnv->GetValue("ProofPlayer.MergeTH1OneByOne", 1); + fMergeTH1OneByOne = (honebyone == 1) ? kTRUE : kFALSE; Bool_t noData = dset->TestBit(TDSet::kEmpty) ? kTRUE : kFALSE; @@ -1636,7 +1994,7 @@ Int_t TProofPlayerRemote::InitPacketizer(TDSet *dset, Long64_t nentries, } else { listOfMissingFiles = new TList; } - // Do the lookup; we only skip it if explicitely requested so. + // Do the lookup; we only skip it if explicitly requested so. TString lkopt; if (TProof::GetParameter(fInput, "PROOF_LookupOpt", lkopt) != 0 || lkopt != "none") dset->Lookup(kTRUE, &listOfMissingFiles); @@ -1760,10 +2118,8 @@ Int_t TProofPlayerRemote::InitPacketizer(TDSet *dset, Long64_t nentries, AddOutputObject(listOfMissingFiles); } TStatus *tmpStatus = (TStatus *)GetOutput("PROOF_Status"); - if (!tmpStatus) { - tmpStatus = new TStatus(); - AddOutputObject(tmpStatus); - } + if (!tmpStatus) AddOutputObject((tmpStatus = new TStatus())); + // Estimate how much data are missing Int_t ngood = dset->GetListOfElements()->GetSize(); Int_t nbad = listOfMissingFiles->GetSize(); @@ -1796,7 +2152,8 @@ Long64_t TProofPlayerRemote::Process(TDSet *dset, const char *selector_file, // The return value is -1 in case of an error and TSelector::GetStatus() in // in case of success. - PDB(kGlobal,1) Info("Process","Enter"); + PDB(kGlobal,1) Info("Process", "Enter"); + fDSet = dset; fExitStatus = kFinished; @@ -1808,7 +2165,7 @@ Long64_t TProofPlayerRemote::Process(TDSet *dset, const char *selector_file, // delete fOutput; if (!fOutput) - fOutput = new TList; + fOutput = new THashList; else fOutput->Clear(); @@ -1819,9 +2176,12 @@ Long64_t TProofPlayerRemote::Process(TDSet *dset, const char *selector_file, } else { TPerfStats::Setup(fInput); } + + TStopwatch elapsed; // Define filename TString fn; + fSelectorFileName = selector_file; if (fCreateSelObj) { if(!SendSelector(selector_file)) return -1; @@ -1981,7 +2341,10 @@ Long64_t TProofPlayerRemote::Process(TDSet *dset, const char *selector_file, TEventList *evl = (!fProof->IsMaster() && !enl) ? dynamic_cast<TEventList *>(set->GetEntryList()) : (TEventList *)0; if (fProof->fProtocol > 14) { + if (fProcessMessage) delete fProcessMessage; + fProcessMessage = new TMessage(kPROOF_PROCESS); mesg << set << fn << fInput << opt << num << fst << evl << sync << enl; + (*fProcessMessage) << set << fn << fInput << opt << num << fst << evl << sync << enl; } else { mesg << set << fn << fInput << opt << num << fst << evl << sync; if (enl) @@ -2035,10 +2398,11 @@ Long64_t TProofPlayerRemote::Process(TDSet *dset, const char *selector_file, // The progress timer will now stop itself at the next call fPacketizer->SetBit(TVirtualPacketizer::kIsDone); // Store process info + elapsed.Stop(); if (fQuery) fQuery->SetProcessInfo(0, 0., fPacketizer->GetBytesRead(), fPacketizer->GetInitTime(), - fPacketizer->GetProcTime()); + elapsed.RealTime()); } StopFeedback(); @@ -2085,7 +2449,7 @@ Long64_t TProofPlayerRemote::Process(TDSet *dset, const char *selector_file, Long64_t rc = -1; if (!IsClient() || GetExitStatus() != TProofPlayer::kAborted) rc = Finalize(kFALSE,sync); - + // Remove temporary input objects, if any if (inputtmp) { TIter nxi(inputtmp); @@ -2124,6 +2488,55 @@ Long64_t TProofPlayerRemote::Process(TDSet *dset, TSelector *selector, return Process(dset, selector->ClassName(), option, nentries, first); } + +//______________________________________________________________________________ +Bool_t TProofPlayerRemote::JoinProcess(TList *workers) +{ + // Prepares the given list of new workers to join a progressing process. + // Returns kTRUE on success, kFALSE otherwise. + + if (!fProcessMessage || !fProof || !fPacketizer) { + Error("Process", "Should not happen: fProcessMessage=%p fProof=%p fPacketizer=%p", + fProcessMessage, fProof, fPacketizer); + return kFALSE; + } + + if (!workers || !fProof->IsMaster()) { + Error("Process", "Invalid call"); + return kFALSE; + } + + PDB(kGlobal, 1) + Info("Process", "Preparing %d new worker(s) to process", workers->GetEntries()); + + // Sends the file associated to the TSelector, if necessary + if (fCreateSelObj) { + PDB(kGlobal, 2) + Info("Process", "Sending selector file %s", fSelectorFileName.Data()); + if(!SendSelector(fSelectorFileName.Data())) { + Error("Process", "Problems in sending selector file %s", fSelectorFileName.Data()); + return kFALSE; + } + } + + PDB(kGlobal, 2) + Info("Process", "Adding new workers to the packetizer"); + if (fPacketizer->AddWorkers(workers) == -1) { + Error("Process", "Cannot add new workers to the packetizer!"); + return kFALSE; // TODO: make new wrks inactive + } + + PDB(kGlobal, 2) + Info("Process", "Broadcasting process message to new workers"); + fProof->Broadcast(*fProcessMessage, workers); + + // Don't call Collect(): we came here from a global Collect() already which + // will take care of new workers as well + + return kTRUE; + +} + //______________________________________________________________________________ Bool_t TProofPlayerRemote::MergeOutputFiles() { @@ -2152,16 +2565,77 @@ Bool_t TProofPlayerRemote::MergeOutputFiles() pf->Print(); continue; } - // Set the output file - if (!filemerger->OutputFile(pf->GetOutputFileName())) { - Error("MergeOutputFiles", "cannot open the output file"); - continue; - } // If only one instance the list in the merger is not yet created: do it now if (!pf->IsMerged()) { + PDB(kOutput,2) pf->Print(); TString fileLoc = TString::Format("%s/%s", pf->GetDir(), pf->GetFileName()); filemerger->AddFile(fileLoc); } + // Datadir + TString ddir, ddopts; + if (gProofServ) { + ddir.Form("%s/", gProofServ->GetDataDir()); + if (gProofServ->GetDataDirOpts()) ddopts= gProofServ->GetDataDirOpts(); + } + // Set the output file + TString outfile(pf->GetOutputFileName()); + if (outfile.Contains("<datadir>/")) { + outfile.ReplaceAll("<datadir>/", ddir.Data()); + if (!ddopts.IsNull()) + outfile += TString::Format("?%s", ddopts.Data()); + pf->SetOutputFileName(outfile); + } + if ((gProofServ && gProofServ->IsTopMaster()) || (fProof && fProof->IsLite())) { + TFile::EFileType ftyp = TFile::kLocal; + TString srv; + TProofServ::GetLocalServer(srv); + TUrl usrv(srv); + Bool_t localFile = kFALSE; + if (pf->IsRetrieve()) { + // This file will be retrieved by the client: we created it in the data dir + // and save the file URL on the client in the title + if (outfile.BeginsWith("client:")) outfile.Replace(0, 7, ""); + TString bn = gSystem->BaseName(TUrl(outfile.Data(), kTRUE).GetFile()); + // The output file path on the master + outfile.Form("%s%s", ddir.Data(), bn.Data()); + // Save the client path in the title if not defined yet + if (strlen(pf->GetTitle()) <= 0) pf->SetTitle(bn); + // The file is local + localFile = kTRUE; + } else { + // Check if the file is on the master or elsewhere + if (outfile.BeginsWith("master:")) outfile.Replace(0, 7, ""); + // Check locality + TUrl uof(outfile.Data(), kTRUE); + TString lfn; + ftyp = TFile::GetType(uof.GetUrl(), "RECREATE", &lfn); + if (ftyp == TFile::kLocal && !srv.IsNull()) { + // Check if is a different server + if (uof.GetPort() > 0 && usrv.GetPort() > 0 && + usrv.GetPort() != uof.GetPort()) ftyp = TFile::kNet; + } + // If it is really local set the file name + if (ftyp == TFile::kLocal) outfile = lfn; + // The file maybe local + if (ftyp == TFile::kLocal || ftyp == TFile::kFile) localFile = kTRUE; + } + // The remote output file name (the one to be used by the client) + TString outfilerem(outfile); + // For local files we add the local server + if (localFile) { + // Remove prefix, if any, if included and if Xrootd + TProofServ::FilterLocalroot(outfilerem, srv); + outfilerem.Insert(0, srv); + } + // Save the new remote output filename + pf->SetOutputFileName(outfilerem); + // Align the filename + pf->SetFileName(gSystem->BaseName(outfilerem)); + } + if (!filemerger->OutputFile(outfile)) { + Error("MergeOutputFiles", "cannot open the output file"); + continue; + } // Merge PDB(kSubmerger,2) filemerger->PrintFiles(""); if (!filemerger->Merge()) { @@ -2174,7 +2648,12 @@ Bool_t TProofPlayerRemote::MergeOutputFiles() TIter next(fileList); TObjString *url = 0; while((url = (TObjString*)next())) { - gSystem->Unlink(url->GetString()); + TUrl u(url->GetName()); + if (!strcmp(u.GetProtocol(), "file")) { + gSystem->Unlink(u.GetFile()); + } else { + gSystem->Unlink(url->GetName()); + } } } // Reset the merger @@ -2216,7 +2695,7 @@ Bool_t TProofPlayerRemote::MergeOutputFiles() fOutput->Remove(pf); if (!rmList) rmList = new TList; rmList->Add(pf); - fOutput->Print(); + PDB(kOutput,2) fOutput->Print(); } } } @@ -2356,10 +2835,7 @@ Long64_t TProofPlayerRemote::Finalize(Bool_t force, Bool_t sync) AddOutputObject(failedPackets); TStatus *status = (TStatus *)GetOutput("PROOF_Status"); - if (!status) { - status = new TStatus(); - AddOutputObject(status); - } + if (!status) AddOutputObject((status = new TStatus())); status->Add("Some packets were not processed! Check the the" " 'FailedPackets' list in the output list"); } @@ -2380,15 +2856,21 @@ Long64_t TProofPlayerRemote::Finalize(Bool_t force, Bool_t sync) Warning("Finalize", "undefined output list in the selector! Protocol error?"); } + // We need to do this because the output list can be modified in TSelector::Terminate + // in a way to invalidate existing objects; so we clean the links when still valid and + // we re-copy back later + fOutput->SetOwner(kFALSE); + fOutput->Clear("nodelete"); + + // Map output objects to selector members SetSelectorDataMembersFromOutputList(); PDB(kLoop,1) Info("Finalize","Call Terminate()"); - fOutput->Clear("nodelete"); fSelector->Terminate(); rv = fSelector->GetStatus(); - // copy the output list back and clean the selector's list + // Copy the output list back and clean the selector's list TIter it(output); while(TObject* o = it()) { fOutput->Add(o); @@ -2406,19 +2888,28 @@ Long64_t TProofPlayerRemote::Finalize(Bool_t force, Bool_t sync) if (!fCreateSelObj) { fInput->Remove(fSelector); fOutput->Remove(fSelector); - output->Remove(fSelector); + if (output) output->Remove(fSelector); + fSelector = 0; } // We have transferred copy of the output objects in TQueryResult, // so now we can cleanup the selector, making sure that we do not // touch the output objects - output->SetOwner(kFALSE); + if (output) { output->SetOwner(kFALSE); output->Clear("nodelete"); } if (fCreateSelObj) SafeDelete(fSelector); // Delete fOutput (not needed anymore, cannot be finalized twice), // making sure that the objects saved in TQueryResult are not deleted fOutput->SetOwner(kFALSE); + fOutput->Clear("nodelete"); SafeDelete(fOutput); + + } else { + + // Cleanup + fOutput->SetOwner(); + SafeDelete(fSelector); + if (!fCreateSelObj) fSelector = 0; } } PDB(kGlobal,1) Info("Process","exit"); @@ -2456,7 +2947,7 @@ Long64_t TProofPlayerRemote::Finalize(TQueryResult *qr) // Reset the list if (!fOutput) - fOutput = new TList; + fOutput = new THashList; else fOutput->Clear(); @@ -2474,7 +2965,7 @@ Long64_t TProofPlayerRemote::Finalize(TQueryResult *qr) TList *tmp = (TList *) qr->GetOutputList(); if (!tmp) { gSystem->RedirectOutput(0); - Info("Finalize(TQueryResult *)", "ouputlist is empty"); + Info("Finalize(TQueryResult *)", "outputlist is empty"); return -1; } TList *out = fOutput; @@ -2633,43 +3124,56 @@ void TProofPlayerRemote::MergeOutput() while ((obj = nxo())) { TProofOutputFile *pf = dynamic_cast<TProofOutputFile *>(obj); if (pf) { - PDB(kOutput,2) Info("MergeOutput","found TProofOutputFile '%s'", obj->GetName()); - TString dir(pf->GetOutputFileName()); - PDB(kOutput,2) Info("MergeOutput","outputfilename: '%s'", dir.Data()); - // The dir - if (dir.Last('/') != kNPOS) dir.Remove(dir.Last('/')+1); - PDB(kOutput,2) Info("MergeOutput","dir: '%s'", dir.Data()); - pf->SetDir(dir); - // The raw dir; for xrootd based system we include teh 'localroot', if any - TUrl u(dir); - dir = u.GetFile(); - TString pfx = gEnv->GetValue("Path.Localroot",""); - if (!pfx.IsNull() && - (!strcmp(u.GetProtocol(), "root") || !strcmp(u.GetProtocol(), "xrd"))) - dir.Insert(0, pfx); - PDB(kOutput,2) Info("MergeOutput","rawdir: '%s'", dir.Data()); - pf->SetDir(dir, kTRUE); - // The worker ordinal - pf->SetWorkerOrdinal(gProofServ ? gProofServ->GetOrdinal() : "0"); - // The saved output file name, if any - key.Form("PROOF_OutputFileName_%s", pf->GetFileName()); - if ((nm = (TNamed *) fOutput->FindObject(key.Data()))) { - pf->SetOutputFileName(nm->GetTitle()); - rmlist.Add(nm); - } else if (TestBit(TVirtualProofPlayer::kIsSubmerger)) { - pf->SetOutputFileName(0); - pf->ResetBit(TProofOutputFile::kOutputFileNameSet); - } - // The filename (order is important to exclude '.merger' from the key) - dir = pf->GetFileName(); - if (TestBit(TVirtualProofPlayer::kIsSubmerger)) { - dir += ".merger"; - pf->SetMerged(kFALSE); - } else { - if (dir.EndsWith(".merger")) dir.Remove(dir.Last('.')); + if (gProofServ) { + PDB(kOutput,2) Info("MergeOutput","found TProofOutputFile '%s'", obj->GetName()); + TString dir(pf->GetOutputFileName()); + PDB(kOutput,2) Info("MergeOutput","outputfilename: '%s'", dir.Data()); + // The dir + if (dir.Last('/') != kNPOS) dir.Remove(dir.Last('/')+1); + PDB(kOutput,2) Info("MergeOutput","dir: '%s'", dir.Data()); + pf->SetDir(dir); + // The raw dir; for xrootd based system we include the 'localroot', if any + TUrl u(dir); + dir = u.GetFile(); + TString pfx = gEnv->GetValue("Path.Localroot",""); + if (!pfx.IsNull() && + (!strcmp(u.GetProtocol(), "root") || !strcmp(u.GetProtocol(), "xrd"))) + dir.Insert(0, pfx); + PDB(kOutput,2) Info("MergeOutput","rawdir: '%s'", dir.Data()); + pf->SetDir(dir, kTRUE); + // The worker ordinal + pf->SetWorkerOrdinal(gProofServ ? gProofServ->GetOrdinal() : "0"); + // The saved output file name, if any + key.Form("PROOF_OutputFileName_%s", pf->GetFileName()); + if ((nm = (TNamed *) fOutput->FindObject(key.Data()))) { + pf->SetOutputFileName(nm->GetTitle()); + rmlist.Add(nm); + } else if (TestBit(TVirtualProofPlayer::kIsSubmerger)) { + pf->SetOutputFileName(0); + pf->ResetBit(TProofOutputFile::kOutputFileNameSet); + } + // The filename (order is important to exclude '.merger' from the key) + dir = pf->GetFileName(); + if (TestBit(TVirtualProofPlayer::kIsSubmerger)) { + dir += ".merger"; + pf->SetMerged(kFALSE); + } else { + if (dir.EndsWith(".merger")) dir.Remove(dir.Last('.')); + } + pf->SetFileName(dir); + } else if (fProof->IsLite()) { + // The ordinal + pf->SetWorkerOrdinal("0"); + // The dir + pf->SetDir(gSystem->DirName(pf->GetOutputFileName())); + // The filename and raw dir + TUrl u(pf->GetOutputFileName(), kTRUE); + pf->SetFileName(gSystem->BaseName(u.GetFile())); + pf->SetDir(gSystem->DirName(u.GetFile()), kTRUE); + // Notify the output path + Printf("\nOutput file: %s", pf->GetOutputFileName()); } - pf->SetFileName(dir); - } else { + } else { PDB(kOutput,2) Info("MergeOutput","output object '%s' is not a TProofOutputFile", obj->GetName()); } } @@ -2794,7 +3298,7 @@ Int_t TProofPlayerRemote::AddOutputObject(TObject *obj) // Create the output list, if not yet done if (!fOutput) - fOutput = new TList; + fOutput = new THashList; // Flag about merging Bool_t merged = kTRUE; @@ -2856,45 +3360,53 @@ Int_t TProofPlayerRemote::AddOutputObject(TObject *obj) TProofOutputFile *pf = dynamic_cast<TProofOutputFile*>(obj); if (pf) { fMergeFiles = kTRUE; - if (!IsClient()) { + if (!IsClient() || fProof->IsLite()) { if (pf->IsMerge()) { Bool_t hasfout = (pf->GetOutputFileName() && strlen(pf->GetOutputFileName()) > 0 && pf->TestBit(TProofOutputFile::kOutputFileNameSet)) ? kTRUE : kFALSE; Bool_t setfout = (!hasfout || TestBit(TVirtualProofPlayer::kIsSubmerger)) ? kTRUE : kFALSE; if (setfout) { - // If submerger, save first the existing filename, if any - if (TestBit(TVirtualProofPlayer::kIsSubmerger) && hasfout) { - TString key = TString::Format("PROOF_OutputFileName_%s", pf->GetFileName()); - if (!fOutput->FindObject(key.Data())) - fOutput->Add(new TNamed(key.Data(), pf->GetOutputFileName())); + + TString ddir, ddopts; + if (gProofServ) { + ddir.Form("%s/", gProofServ->GetDataDir()); + if (gProofServ->GetDataDirOpts()) ddopts = gProofServ->GetDataDirOpts(); } - TString of; - if (gSystem->Getenv("LOCALDATASERVER")) { - of = gSystem->Getenv("LOCALDATASERVER"); - } else { - // Assume an xroot server running on the machine - of.Form("root://%s", gSystem->HostName()); - if (gSystem->Getenv("XRDPORT")) { - TString sp(gSystem->Getenv("XRDPORT")); - if (sp.IsDigit()) - of += Form(":%s", sp.Data()); + // Set the output file + TString outfile(pf->GetOutputFileName()); + outfile.ReplaceAll("<datadir>/", ddir.Data()); + if (!ddopts.IsNull()) outfile += TString::Format("?%s", ddopts.Data()); + pf->SetOutputFileName(outfile); + + if (gProofServ) { + // If submerger, save first the existing filename, if any + if (TestBit(TVirtualProofPlayer::kIsSubmerger) && hasfout) { + TString key = TString::Format("PROOF_OutputFileName_%s", pf->GetFileName()); + if (!fOutput->FindObject(key.Data())) + fOutput->Add(new TNamed(key.Data(), pf->GetOutputFileName())); } + TString of; + TProofServ::GetLocalServer(of); + if (of.IsNull()) { + // Assume an xroot server running on the machine + of.Form("root://%s/", gSystem->HostName()); + if (gSystem->Getenv("XRDPORT")) { + TString sp(gSystem->Getenv("XRDPORT")); + if (sp.IsDigit()) + of.Form("root://%s:%s/", gSystem->HostName(), sp.Data()); + } + } + TString sessionPath(gProofServ->GetSessionDir()); + TProofServ::FilterLocalroot(sessionPath, of); + of += TString::Format("%s/%s", sessionPath.Data(), pf->GetFileName()); + if (TestBit(TVirtualProofPlayer::kIsSubmerger)) { + if (!of.EndsWith(".merger")) of += ".merger"; + } else { + if (of.EndsWith(".merger")) of.Remove(of.Last('.')); + } + pf->SetOutputFileName(of); } - TString sessionPath(gProofServ->GetSessionDir()); - // Take into account a prefix, if included and if xrootd - TString sproto = TUrl(sessionPath).GetProtocol(); - TString pfx = gEnv->GetValue("Path.Localroot",""); - if (!pfx.IsNull() && sessionPath.BeginsWith(pfx) && - (sproto == "root" || sproto == "xrd")) - sessionPath.Remove(0, pfx.Length()); - of += TString::Format("/%s/%s", sessionPath.Data(), pf->GetFileName()); - if (TestBit(TVirtualProofPlayer::kIsSubmerger)) { - if (!of.EndsWith(".merger")) of += ".merger"; - } else { - if (of.EndsWith(".merger")) of.Remove(of.Last('.')); - } - pf->SetOutputFileName(of); } // Notify PDB(kOutput, 1) pf->Print(); @@ -2948,7 +3460,7 @@ void TProofPlayerRemote::AddOutput(TList *out) // Create the output list, if not yet done if (!fOutput) - fOutput = new TList; + fOutput = new THashList; // Process event lists first Bool_t merged = kTRUE; @@ -3199,70 +3711,38 @@ TObject *TProofPlayerRemote::HandleHistogram(TObject *obj, Bool_t &merged) return (TObject *)0; } else { - - if (!fUseTH1Merge) { - // Check if we can 'Add' the histogram to an existing one; this is more efficient - // then using Merge - TH1 *hout = (TH1*) fOutput->FindObject(h->GetName()); - if (hout) { - // Do they have the same binning and ranges? - Bool_t samebin = HistoSameAxis(hout, h); - if (samebin) { - hout->Add(h); - PDB(kOutput,2) - Info("HandleHistogram", "histogram '%s' just added", h->GetName()); - merged = kTRUE; // So it will be deleted - return (TObject *)0; - } else { - // Remove the existing histo from the output list ... - fOutput->Remove(hout); - // ... and create either the list to merge in one-go at the end - // (more efficient than merging one by one) or, if too big, merge - // these two and start the 'one-by-one' technology - Int_t hsz = h->GetNbinsX() * h->GetNbinsY() * h->GetNbinsZ(); - if (gProofServ && hsz > gProofServ->GetMsgSizeHWM()) { - list = new TList; - list->Add(hout); - h->Merge(list); - list->SetOwner(); - delete list; - return h; - } else { - list = new TList; - list->SetName(h->GetName()); - list->SetOwner(); - fOutputLists->Add(list); - // Add the existing and the incoming histos - list->Add(hout); - list->Add(h); - // Done - return (TObject *)0; - } - } - } else { - // This is the first one; add it to the output list - fOutput->Add(h); - return (TObject *)0; - } - - } else { - - // Histogram has already been projected + // Check if we can 'Add' the histogram to an existing one; this is more efficient + // then using Merge + TH1 *hout = (TH1*) fOutput->FindObject(h->GetName()); + if (hout) { + // Remove the existing histo from the output list ... + fOutput->Remove(hout); + // ... and create either the list to merge in one-go at the end + // (more efficient than merging one by one) or, if too big, merge + // these two and start the 'one-by-one' technology Int_t hsz = h->GetNbinsX() * h->GetNbinsY() * h->GetNbinsZ(); - if (gProofServ && hsz > gProofServ->GetMsgSizeHWM()) { - // Large histo: merge one-by-one - return obj; + if (fMergeTH1OneByOne || (gProofServ && hsz > gProofServ->GetMsgSizeHWM())) { + list = new TList; + list->Add(hout); + h->Merge(list); + list->SetOwner(); + delete list; + return h; } else { - // Create the list to merge in one-go at the end (more efficient - // than merging one by one) list = new TList; list->SetName(h->GetName()); list->SetOwner(); fOutputLists->Add(list); + // Add the existing and the incoming histos + list->Add(hout); list->Add(h); // Done return (TObject *)0; } + } else { + // This is the first one; add it to the output list + fOutput->Add(h); + return (TObject *)0; } } } @@ -3848,7 +4328,7 @@ Bool_t TProofPlayerSlave::HandleTimer(TTimer *) fb->SetOwner(kFALSE); if (fOutput == 0) { - fOutput = fSelector->GetOutputList(); + fOutput = (THashList *) fSelector->GetOutputList(); } if (fOutput) { @@ -3949,7 +4429,7 @@ Long64_t TProofPlayerSuperMaster::Process(TDSet *dset, const char *selector_file if (!proof) return -1; delete fOutput; - fOutput = new TList; + fOutput = new THashList; TPerfStats::Start(fInput, fOutput); diff --git a/proof/proofplayer/src/TProofPlayerLite.cxx b/proof/proofplayer/src/TProofPlayerLite.cxx index 770133268110d..f8427c7532207 100644 --- a/proof/proofplayer/src/TProofPlayerLite.cxx +++ b/proof/proofplayer/src/TProofPlayerLite.cxx @@ -25,7 +25,7 @@ #include "TDSetProxy.h" #include "TEntryList.h" #include "TEventList.h" -#include "TList.h" +#include "THashList.h" #include "TMap.h" #include "TMessage.h" #include "TObjString.h" @@ -120,13 +120,15 @@ Long64_t TProofPlayerLite::Process(TDSet *dset, const char *selector_file, // delete fOutput; if (!fOutput) - fOutput = new TList; + fOutput = new THashList; else fOutput->Clear(); TPerfStats::Setup(fInput); TPerfStats::Start(fInput, fOutput); + TStopwatch elapsed; + TMessage mesg(kPROOF_PROCESS); TString fn(gSystem->BaseName(selector_file)); @@ -281,10 +283,11 @@ Long64_t TProofPlayerLite::Process(TDSet *dset, const char *selector_file, // The progress timer will now stop itself at the next call fPacketizer->SetBit(TVirtualPacketizer::kIsDone); // Store process info + elapsed.Stop(); if (fQuery) fQuery->SetProcessInfo(0, 0., fPacketizer->GetBytesRead(), fPacketizer->GetInitTime(), - fPacketizer->GetProcTime()); + elapsed.RealTime()); } StopFeedback(); @@ -386,13 +389,14 @@ Long64_t TProofPlayerLite::Finalize(Bool_t force, Bool_t sync) if (!fCreateSelObj) { fInput->Remove(fSelector); fOutput->Remove(fSelector); - output->Remove(fSelector); + if (output) output->Remove(fSelector); + fSelector = 0; } // We have transferred copy of the output objects in TQueryResult, // so now we can cleanup the selector, making sure that we do not // touch the output objects - output->SetOwner(kFALSE); + if (output) output->SetOwner(kFALSE); if (fCreateSelObj) SafeDelete(fSelector); // Delete fOutput (not needed anymore, cannot be finalized twice), @@ -404,7 +408,8 @@ Long64_t TProofPlayerLite::Finalize(Bool_t force, Bool_t sync) // Cleanup fOutput->SetOwner(); SafeDelete(fSelector); - } + if (!fCreateSelObj) fSelector = 0; + } PDB(kGlobal,1) Info("Finalize","exit"); return rv; diff --git a/proof/proofplayer/src/TVirtualPacketizer.cxx b/proof/proofplayer/src/TVirtualPacketizer.cxx index eebacef512a1c..5a2529deb314c 100644 --- a/proof/proofplayer/src/TVirtualPacketizer.cxx +++ b/proof/proofplayer/src/TVirtualPacketizer.cxx @@ -115,6 +115,7 @@ TVirtualPacketizer::TVirtualPacketizer(TList *input, TProofProgressStatus *st) fCircN = 5; TProof::GetParameter(input, "PROOF_ProgressCircularity", fCircN); fCircProg->SetCircular(fCircN); + fCircProg->SetDirectory(0); // Check if we need to start the progress timer (multi-packetizers do not want // timers from the packetizers they control ...) @@ -168,7 +169,6 @@ TVirtualPacketizer::~TVirtualPacketizer() { // Destructor. - fCircProg->SetDirectory(0); SafeDelete(fCircProg); SafeDelete(fProgress); SafeDelete(fFailedPackets); @@ -320,6 +320,11 @@ Bool_t TVirtualPacketizer::HandleTimer(TTimer *) evtrti = GetCurrentRate(all); Double_t xall = (all) ? 1. : 0.; GetEstEntriesProcessed(0, estent, estmb, estrc); + if (estent >= fTotalEntries) { + estent = GetEntriesProcessed(); + estmb = GetBytesRead(); + estrc = GetReadCalls(); + } // Fill entry Double_t evts = (Double_t) estent; Double_t mbs = (estmb > 0) ? estmb / TMath::Power(2.,20.) : 0.; //--> MB @@ -429,3 +434,14 @@ void TVirtualPacketizer::SetInitTime() Info("SetInitTime","fInitTime set to %f s", fInitTime); } } + +//______________________________________________________________________________ +Int_t TVirtualPacketizer::AddWorkers(TList *) +{ + // Adds new workers. Must be implemented by each real packetizer properly. + // Returns the number of workers added, or -1 on failure. + + Warning("AddWorkers", "Not implemented for this packetizer"); + + return -1; +} diff --git a/proof/proofx/CMakeLists.txt b/proof/proofx/CMakeLists.txt index f53c890adde68..f953fd4a1bf12 100644 --- a/proof/proofx/CMakeLists.txt +++ b/proof/proofx/CMakeLists.txt @@ -16,7 +16,7 @@ else() ROOT_GLOB_SOURCES(sources RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}/src ${CMAKE_CURRENT_SOURCE_DIR}/src/*.cxx) endif() -include_directories(${XROOTD_INCLUDE_DIR}) +include_directories(${XROOTD_INCLUDE_DIRS}) link_directories(${XROOTD_LIBRARY_DIR}) add_definitions(${XROOTD_CFLAGS}) diff --git a/proof/proofx/Module.mk b/proof/proofx/Module.mk index faeefabfede30..4fd55c65b3c0a 100644 --- a/proof/proofx/Module.mk +++ b/proof/proofx/Module.mk @@ -63,6 +63,9 @@ endif PROOFXINCEXTRA := $(PROOFXDIRI:%=-I%) PROOFXINCEXTRA += $(XROOTDDIRI:%=-I%) PROOFXINCEXTRA += $(PROOFDDIRI:%=-I%) +ifeq ($(XRDINCPRIVATE),yes) +PROOFXINCEXTRA += -I$(XRDINCDIR)/private +endif # Xrootd client libs ifeq ($(PLATFORM),win32) diff --git a/proof/proofx/inc/TXSocket.h b/proof/proofx/inc/TXSocket.h index ba2c0be46fb98..8917e4e1d233c 100644 --- a/proof/proofx/inc/TXSocket.h +++ b/proof/proofx/inc/TXSocket.h @@ -110,7 +110,7 @@ friend class TXUnixSocket; // Interrupts TMutex *fIMtx; // To protect interrupt queue kXR_int32 fILev; // Highest received interrupt - Bool_t fIForward; // Wheter the interrupt should be propagated + Bool_t fIForward; // Whether the interrupt should be propagated // Process ID of the instatiating process (to signal interrupts) Int_t fPid; diff --git a/proof/proofx/src/TXProofMgr.cxx b/proof/proofx/src/TXProofMgr.cxx index 5ba25dce4cba4..cc4f70319802c 100644 --- a/proof/proofx/src/TXProofMgr.cxx +++ b/proof/proofx/src/TXProofMgr.cxx @@ -427,7 +427,7 @@ TList *TXProofMgr::QuerySessions(Option_t *opt) Int_t id = -1, st = -1; TString al, tg, tk; Ssiz_t from = 0; - while ((to->GetString()[from] == ' ')) { from++; } + while (to->GetString()[from] == ' ') { from++; } if (!to->GetString().Tokenize(tk, from, " ") || !tk.IsDigit()) continue; id = tk.Atoi(); if (!to->GetString().Tokenize(tg, from, " ")) continue; @@ -685,25 +685,37 @@ TObjString *TXProofMgr::ReadBuffer(const char *fin, Long64_t ofs, Int_t len) //______________________________________________________________________________ TObjString *TXProofMgr::ReadBuffer(const char *fin, const char *pattern) { - // Read, via the coordinator, lines containing 'pattern' in 'file'. - // Returns a TObjString with the content or 0, in case of failure + // Read, via the coordinator, 'fin' filtered. If 'pattern' starts with '|', + // it represents a command filtering the output. Elsewhere, it is a grep + // pattern. Returns a TObjString with the content or 0 in case of failure // Nothing to do if not in contact with proofserv if (!IsValid()) { - Warning("ReadBuffer","invalid TXProofMgr - do nothing"); + Warning("ReadBuffer", "invalid TXProofMgr - do nothing"); return (TObjString *)0; } + const char *ptr; + Int_t type; // 1 = grep, 2 = grep -v, 3 = pipe through cmd + if (*pattern == '|') { + ptr = &pattern[1]; // strip first char if it is a command + type = 3; + } + else { + ptr = pattern; + type = 1; + } + // Prepare the buffer - Int_t plen = strlen(pattern); + Int_t plen = strlen(ptr); Int_t lfi = strlen(fin); char *buf = new char[lfi + plen + 1]; memcpy(buf, fin, lfi); - memcpy(buf+lfi, pattern, plen); + memcpy(buf+lfi, ptr, plen); buf[lfi+plen] = 0; // Send the request - return fSocket->SendCoordinator(kReadBuffer, buf, plen, 0, 1); + return fSocket->SendCoordinator(kReadBuffer, buf, plen, 0, type); } //______________________________________________________________________________ @@ -772,18 +784,18 @@ Int_t TXProofMgr::SendMsgToUsers(const char *msg, const char *usr) const Int_t kMAXBUF = 32768; char buf[kMAXBUF] = {0}; char *p = &buf[0]; - Int_t space = kMAXBUF - 1; - Int_t len = 0; + size_t space = kMAXBUF - 1; Int_t lusr = 0; // A specific user? if (usr && strlen(usr) > 0 && (strlen(usr) != 1 || usr[0] != '*')) { lusr = (strlen(usr) + 3); - sprintf(buf, "u:%s ", usr); + snprintf(buf, kMAXBUF, "u:%s ", usr); p += lusr; space -= lusr; } + ssize_t len = 0; // Is it from file ? if (!gSystem->AccessPathName(msg, kFileExists)) { // From file: can we read it ? @@ -798,14 +810,27 @@ Int_t TXProofMgr::SendMsgToUsers(const char *msg, const char *usr) return -1; } // Determine the number of bytes to be read from the file. - Int_t left = (Int_t) lseek(fileno(f), (off_t) 0, SEEK_END); - lseek(fileno(f), (off_t) 0, SEEK_SET); + size_t left = 0; + off_t rcsk = lseek(fileno(f), (off_t) 0, SEEK_END); + if ((rcsk != (off_t)(-1))) { + left = (size_t) rcsk; + if ((lseek(fileno(f), (off_t) 0, SEEK_SET) == (off_t)(-1))) { + Error("SendMsgToUsers", "cannot rewind open file (seek to 0)"); + fclose(f); + return -1; + } + } else { + Error("SendMsgToUsers", "cannot get size of open file (seek to END)"); + fclose(f); + return -1; + } // Now readout from file - Int_t wanted = left; + size_t wanted = left; if (wanted > space) { wanted = space; Warning("SendMsgToUsers", - "requested to send %d bytes: max size is %d bytes: truncating", left, space); + "requested to send %lld bytes: max size is %lld bytes: truncating", + (Long64_t)left, (Long64_t)space); } do { while ((len = read(fileno(f), p, wanted)) < 0 && @@ -817,17 +842,20 @@ Int_t TXProofMgr::SendMsgToUsers(const char *msg, const char *usr) } // Update counters - left -= len; + left = (len >= (ssize_t)left) ? 0 : left - len; p += len; wanted = (left > kMAXBUF-1) ? kMAXBUF-1 : left; } while (len > 0 && left > 0); + // Close file + fclose(f); } else { // Add the message to the buffer len = strlen(msg); - if (len > space) { + if (len > (ssize_t)space) { Warning("SendMsgToUsers", - "requested to send %d bytes: max size is %d bytes: truncating", len, space); + "requested to send %lld bytes: max size is %lld bytes: truncating", + (Long64_t)len, (Long64_t)space); len = space; } memcpy(p, msg, len); @@ -1101,6 +1129,7 @@ Int_t TXProofMgr::Stat(const char *what, FileStat_t &st, const char *where) // Show the result, if any if (os) { if (gDebug > 1) Printf("%s", os->GetName()); +#if 0 Int_t mode, uid, gid, islink; Long_t dev, ino, mtime; Long64_t size; @@ -1121,6 +1150,27 @@ Int_t TXProofMgr::Stat(const char *what, FileStat_t &st, const char *where) st.fSize = size; st.fMtime = mtime; st.fIsLink = (islink == 1); +#else + TString tkn; + Ssiz_t from = 0; + if (!os->GetString().Tokenize(tkn, from, "[ ]+") || !tkn.IsDigit()) return -1; + st.fDev = tkn.Atoi(); + if (st.fDev == -1) return -1; + if (!os->GetString().Tokenize(tkn, from, "[ ]+") || !tkn.IsDigit()) return -1; + st.fIno = tkn.Atoi(); + if (!os->GetString().Tokenize(tkn, from, "[ ]+") || !tkn.IsDigit()) return -1; + st.fMode = tkn.Atoi(); + if (!os->GetString().Tokenize(tkn, from, "[ ]+") || !tkn.IsDigit()) return -1; + st.fUid = tkn.Atoi(); + if (!os->GetString().Tokenize(tkn, from, "[ ]+") || !tkn.IsDigit()) return -1; + st.fGid = tkn.Atoi(); + if (!os->GetString().Tokenize(tkn, from, "[ ]+") || !tkn.IsDigit()) return -1; + st.fSize = tkn.Atoll(); + if (!os->GetString().Tokenize(tkn, from, "[ ]+") || !tkn.IsDigit()) return -1; + st.fMtime = tkn.Atoi(); + if (!os->GetString().Tokenize(tkn, from, "[ ]+") || !tkn.IsDigit()) return -1; + st.fIsLink = (tkn.Atoi() == 1) ? kTRUE : kFALSE; +#endif // Cleanup SafeDelete(os); @@ -1368,8 +1418,14 @@ Int_t TXProofMgr::GetFile(const char *remote, const char *local, const char *opt if (os) { // The message contains the size - Long64_t size; - sscanf(os->GetName(), "%lld", &size); + TString ssz(os->GetName()); + ssz.ReplaceAll(" ", ""); + if (!ssz.IsDigit()) { + Error("GetFile", "received non-digit size string: '%s' ('%s')", os->GetName(), ssz.Data()); + close(fdout); + return rc; + } + Long64_t size = ssz.Atoll(); if (size <= 0) { Error("GetFile", "received null or negative size: %lld", size); close(fdout); diff --git a/proof/proofx/src/TXProofServ.cxx b/proof/proofx/src/TXProofServ.cxx index d37c39a37b796..4bc1316739870 100644 --- a/proof/proofx/src/TXProofServ.cxx +++ b/proof/proofx/src/TXProofServ.cxx @@ -634,9 +634,9 @@ Int_t TXProofServ::Setup() char str[512]; if (IsMaster()) { - sprintf(str, "**** Welcome to the PROOF server @ %s ****", gSystem->HostName()); + snprintf(str, 512, "**** Welcome to the PROOF server @ %s ****", gSystem->HostName()); } else { - sprintf(str, "**** PROOF worker server @ %s started ****", gSystem->HostName()); + snprintf(str, 512, "**** PROOF worker server @ %s started ****", gSystem->HostName()); } if (fSocket->Send(str) != 1+static_cast<Int_t>(strlen(str))) { @@ -674,11 +674,30 @@ Int_t TXProofServ::Setup() fWorkDir = gEnv->GetValue("ProofServ.Sandbox", Form("~/%s", kPROOF_WorkDir)); // Get Session tag - if ((fTopSessionTag = gEnv->GetValue("ProofServ.SessionTag", "-1")) == "-1") { + if ((fSessionTag = gEnv->GetValue("ProofServ.SessionTag", "-1")) == "-1") { Error("Setup", "Session tag missing"); return -1; } - fSessionTag = fTopSessionTag; + // Get top session tag, i.e. the tag of the PROOF session + if ((fTopSessionTag = gEnv->GetValue("ProofServ.TopSessionTag", "-1")) == "-1") { + fTopSessionTag = ""; + // Try to extract it from log file path (for backward compatibility) + if (gSystem->Getenv("ROOTPROOFLOGFILE")) { + fTopSessionTag = gSystem->DirName(gSystem->Getenv("ROOTPROOFLOGFILE")); + Ssiz_t lstl; + if ((lstl = fTopSessionTag.Last('/')) != kNPOS) fTopSessionTag.Remove(0, lstl + 1); + if (fTopSessionTag.BeginsWith("session-")) { + fTopSessionTag.Remove(0, strlen("session-")); + } else { + fTopSessionTag = ""; + } + } + if (fTopSessionTag.IsNull()) { + Error("Setup", "top session tag missing"); + return -1; + } + } + // Make sure the process ID is in the tag TString spid = Form("-%d", gSystem->GetPid()); if (!fSessionTag.EndsWith(spid)) { @@ -746,11 +765,10 @@ TProofServ::EQueryAction TXProofServ::GetWorkers(TList *workers, TProofServ::EQueryAction rc = kQueryStop; - // If user config files are enabled, check them first + // User config files, when enabled, override cluster-wide configuration if (gEnv->GetValue("ProofServ.UseUserCfg", 0) != 0) { Int_t pc = 1; - if ((rc = TProofServ::GetWorkers(workers, pc)) == kQueryOK) - return rc; + return TProofServ::GetWorkers(workers, pc); } // seqnum of the query for which we call getworkers @@ -788,8 +806,8 @@ TProofServ::EQueryAction TXProofServ::GetWorkers(TList *workers, } if (s.IsDigit()) { nwrks = s.Atoi(); - if (nwrks > 0) { - // Notify + if (!dynamicStartup && (nwrks > 0)) { + // Notify, except in dynamic workers mode to avoid flooding TString msg; if (pernode) { msg.Form("+++ Starting max %d workers per node following the setting of PROOF_NWORKERS", nwrks); @@ -821,35 +839,42 @@ TProofServ::EQueryAction TXProofServ::GetWorkers(TList *workers, SafeDelete(master); } // Now the workers - while (fl.Tokenize(tok, from, "&") && (nwrks == -1 || nwrks > 0)) { + while (fl.Tokenize(tok, from, "&")) { if (!tok.IsNull()) { - // We have the minimal set of information to start - rc = kQueryOK; - if (pernode && nodecnt) { - TProofNodeInfo *ni = new TProofNodeInfo(tok); - TParameter<Int_t> *p = 0; - Int_t nw = 0; - if (!(p = (TParameter<Int_t> *) nodecnt->FindObject(ni->GetNodeName().Data()))) { - p = new TParameter<Int_t>(ni->GetNodeName().Data(), nw); - nodecnt->Add(p); - } - nw = p->GetVal(); - if (gDebug > 0) - Info("GetWorkers","%p: name: %s (%s) val: %d (nwrks: %d)", - p, p->GetName(), ni->GetNodeName().Data(), nw, nwrks); - if (nw < nwrks) { - if (workers) workers->Add(ni); - nw++; - p->SetVal(nw); + if (nwrks == -1 || nwrks > 0) { + // We have the minimal set of information to start + rc = kQueryOK; + if (pernode && nodecnt) { + TProofNodeInfo *ni = new TProofNodeInfo(tok); + TParameter<Int_t> *p = 0; + Int_t nw = 0; + if (!(p = (TParameter<Int_t> *) nodecnt->FindObject(ni->GetNodeName().Data()))) { + p = new TParameter<Int_t>(ni->GetNodeName().Data(), nw); + nodecnt->Add(p); + } + nw = p->GetVal(); + if (gDebug > 0) + Info("GetWorkers","%p: name: %s (%s) val: %d (nwrks: %d)", + p, p->GetName(), ni->GetNodeName().Data(), nw, nwrks); + if (nw < nwrks) { + if (workers) workers->Add(ni); + nw++; + p->SetVal(nw); + } else { + // Two many workers on this machine already + SafeDelete(ni); + } } else { - // Two many workers on this machine already - SafeDelete(ni); + if (workers) + workers->Add(new TProofNodeInfo(tok)); + // Count down + if (nwrks != -1) nwrks--; } } else { - if (workers) - workers->Add(new TProofNodeInfo(tok)); - // Count down - if (nwrks != -1) nwrks--; + // Release this worker (to cleanup the session list in the coordinator and get a fresh + // and correct list next call) + TProofNodeInfo *ni = new TProofNodeInfo(tok); + ReleaseWorker(ni->GetOrdinal().Data()); } } } @@ -891,7 +916,7 @@ Bool_t TXProofServ::HandleError(const void *) fProof->Close("S"); // Avoid communicating back anything to the coordinator (it is gone) - ((TXSocket *)fSocket)->SetSessionID(-1); + if (fSocket) ((TXSocket *)fSocket)->SetSessionID(-1); Terminate(0); @@ -1149,7 +1174,7 @@ void TXProofServ::ReleaseWorker(const char *ord) // Send message to intermediate coordinator to release worker of last ordinal // ord. - Info("ReleaseWorker","releasing: %s", ord); + if (gDebug > 2) Info("ReleaseWorker","releasing: %s", ord); ((TXSocket *)fSocket)->SendCoordinator(kReleaseWorker, ord); } diff --git a/proof/proofx/src/TXSocket.cxx b/proof/proofx/src/TXSocket.cxx index 5071ed8bb9f7b..b226145b5756a 100644 --- a/proof/proofx/src/TXSocket.cxx +++ b/proof/proofx/src/TXSocket.cxx @@ -445,12 +445,6 @@ UnsolRespProcResult TXSocket::ProcessUnsolicitedMsg(XrdClientUnsolMsgSender *, } // Local processing ... - if (!m) { - Error("ProcessUnsolicitedMsg", "undefined message - disabling"); - PostMsg(kPROOF_STOP); - return rc; - } - Int_t len = 0; if ((len = m->DataLen()) < (int)sizeof(kXR_int32)) { Error("ProcessUnsolicitedMsg", "empty or bad-formed message - disabling"); @@ -1000,8 +994,10 @@ Int_t TXSocket::Flush() } // Reset the asynchronous queue - while (sz--) - fASem.TryWait(); + while (sz--) { + if (fASem.TryWait() == 1) + Printf("Warning in TXSocket::Flush: semaphore counter already 0 (sz: %d)", sz); + } fAQue.clear(); } } @@ -1088,6 +1084,7 @@ Bool_t TXSocket::Create(Bool_t attach) } else { Error("Create","session ID is undefined!"); fSessionID = -1; + if (srvresp) free(srvresp); return kFALSE; } @@ -1134,8 +1131,7 @@ Bool_t TXSocket::Create(Bool_t attach) // Cleanup SafeDelete(xrsp); - if (srvresp) - free(srvresp); + if (srvresp) free(srvresp); // Notify return kTRUE; @@ -1150,6 +1146,7 @@ Bool_t TXSocket::Create(Bool_t attach) if (fConn->GetOpenError() == kXP_TooManySess) { // Avoid to contact the server any more fSessionID = -1; + if (srvresp) free(srvresp); return kFALSE; } else { // Print error msg, if any @@ -1167,6 +1164,7 @@ Bool_t TXSocket::Create(Bool_t attach) Error("Create", "%d creation/attachment attempts failed: no attempts left", gEnv->GetValue("XProof.CreationRetries", 4)); + if (srvresp) free(srvresp); } // Creation retries // The session is invalid: reset the sessionID to invalid state (it was our protocol @@ -1290,6 +1288,7 @@ Bool_t TXSocket::Ping(const char *ord) // Cleanup SafeDelete(xrsp); + if (pans) free(pans); } else { if (XPD::clientMarshall(&Request) == 0) { @@ -1446,12 +1445,15 @@ Int_t TXSocket::PickUpReady() Error("PickUpReady","queue is empty - protocol error ?"); return -1; } - fBufCur = fAQue.front(); + if (!(fBufCur = fAQue.front())) { + Error("PickUpReady","got invalid buffer - protocol error ?"); + return -1; + } // Remove message from the queue fAQue.pop_front(); + // Set number of available bytes - if (fBufCur) - fByteLeft = fBufCur->fLen; + fByteLeft = fBufCur->fLen; if (gDebug > 2) Info("PickUpReady", "%p: %s: got message (%d bytes)", @@ -1511,10 +1513,9 @@ TXSockBuf *TXSocket::PopUpSpare(Int_t size) } // Create a new buffer - char *b = (char *)malloc(size); - if (b) - buf = new TXSockBuf(b, size); + buf = new TXSockBuf((char *)malloc(size), size); nBuf++; + if (gDebug > 2) Info("PopUpSpare","asked: %d, spare: %d/%d, maxsz: %d, NEW buf %p, sz: %d", size, (int) fgSQue.size(), nBuf, maxsz, buf, buf->fSiz); @@ -2094,7 +2095,7 @@ Int_t TXSocket::Reconnect() Int_t tryreconnect = gEnv->GetValue("TXSocket.Reconnect", 1); if (tryreconnect == 0 || fXrdProofdVersion < 1005) { if (tryreconnect == 0) - Info("Reconnect","%p: reconnection attempts explicitely disabled!", this); + Info("Reconnect","%p: reconnection attempts explicitly disabled!", this); else Info("Reconnect","%p: server does not support reconnections (protocol: %d < 1005)", this, fXrdProofdVersion); @@ -2121,9 +2122,13 @@ Int_t TXSocket::Reconnect() } if (gDebug > 0) { - Info("Reconnect", "%p (c:%p): attempt %s (logid: %d)", this, fConn, - ((fConn && fConn->IsValid()) ? "succeeded!" : "failed"), - fConn->GetLogConnID() ); + if (fConn) { + Info("Reconnect", "%p (c:%p): attempt %s (logid: %d)", this, fConn, + (fConn->IsValid() ? "succeeded!" : "failed"), + fConn->GetLogConnID() ); + } else { + Info("Reconnect", "%p (c:0x0): attempt failed", this); + } } // Done diff --git a/proof/proofx/src/TXUnixSocket.cxx b/proof/proofx/src/TXUnixSocket.cxx index d5e7fcc69a297..7d30f4366af19 100644 --- a/proof/proofx/src/TXUnixSocket.cxx +++ b/proof/proofx/src/TXUnixSocket.cxx @@ -72,7 +72,7 @@ Int_t TXUnixSocket::Reconnect() Int_t tryreconnect = gEnv->GetValue("TXSocket.Reconnect", 1); if (tryreconnect == 0 || fXrdProofdVersion < 1005) { if (tryreconnect == 0) - Info("Reconnect","%p: reconnection attempts explicitely disabled!", this); + Info("Reconnect","%p: reconnection attempts explicitly disabled!", this); else Info("Reconnect","%p: server does not support reconnections (protocol: %d < 1005)", this, fXrdProofdVersion); diff --git a/roofit/CMakeLists.txt b/roofit/CMakeLists.txt index a921698a837bf..4de943753c94c 100644 --- a/roofit/CMakeLists.txt +++ b/roofit/CMakeLists.txt @@ -8,6 +8,7 @@ endif() ROOT_USE_PACKAGE(math/mathcore) ROOT_USE_PACKAGE(math/foam) ROOT_USE_PACKAGE(math/minuit) +ROOT_USE_PACKAGE(math/smatrix) ROOT_USE_PACKAGE(proof/proof) if(mathmore OR ROOT_mathmore_FOUND) diff --git a/roofit/doc/v520/index.html b/roofit/doc/v520/index.html index a2f0fec5212fa..d3d1b78ba352f 100644 --- a/roofit/doc/v520/index.html +++ b/roofit/doc/v520/index.html @@ -198,7 +198,7 @@ <h4>New operator class <tt>RooLinearMorph</tt></h4> p.d.f fbar(x) is then calculated as fbar(alpha*x1+(1-alpha)*x2) = f1(x1)*f2(x2) / ( alpha*f2(x2) + (1-alpha)*f1(x1) ). Given that it is not easily possible to calculate the value of RooLinearMorph at a given value of x, the value for all values of x are calculated in one by (through a scan over y) - and stored in a cache. NB: The range of the interpolation paramater does not need to be [0,1], it can + and stored in a cache. NB: The range of the interpolation parameter does not need to be [0,1], it can be anything. diff --git a/roofit/doc/v532/index.html b/roofit/doc/v532/index.html index 34c13e1525ce7..47d1bb38c8068 100644 --- a/roofit/doc/v532/index.html +++ b/roofit/doc/v532/index.html @@ -26,7 +26,7 @@ <h3>RooFit Package</h3> </p></li> <li><p>New algorithmic optimization in the caching of pdfs. So far - in the likelihood - two classes of objects are identified: those that change with every event (i.e. the pdf) and those that change - only with the paramaters (typically pdf normalization integrals). Pdfs are always recalculated + only with the parameters (typically pdf normalization integrals). Pdfs are always recalculated for every event, whereas integrals are only evaluated when needed. The exception to the first type are pdfs that only depend on constant parameters (or no parameters) - these are identified at the beginning, and precalculated once to avoid recalculating an expression with the same outcome for every iteration of the likelihood calculation @@ -38,7 +38,7 @@ <h3>RooFit Package</h3> likelihood evaluation if selected columns need to be updated because parameters have changed. The speed gain of this optimization depends much on the structure of the pdf: in models with many free parameters most of the likelihood evaluations are executed when MINUIT calculates numerical likelihood derivatives which vary - one paramater at a time and the speedup is potentially larger. In models with few free parameters the + one parameter at a time and the speedup is potentially larger. In models with few free parameters the effect will be smaller. </p><p> The new per-component caching strategy is enabled by default for all pdfs that are a component of diff --git a/roofit/histfactory/CMakeLists.txt b/roofit/histfactory/CMakeLists.txt index 59d193ab7970e..ee552f99ec66f 100644 --- a/roofit/histfactory/CMakeLists.txt +++ b/roofit/histfactory/CMakeLists.txt @@ -12,11 +12,11 @@ ROOT_GENERATE_ROOTMAP(HistFactory LINKDEF LinkDef.h ROOT_LINKER_LIBRARY(HistFactory *.cxx G__HistFactory.cxx LIBRARIES Core Cint DEPENDENCIES RooFit RooFitCore Tree RIO Hist Matrix MathCore Minuit Foam Graf Gpad RooStats XMLParser) -ROOT_EXECUTABLE(hist2workspace MakeModelAndMeasurements.cxx - LIBRARIES HistFactory RooFit RooFitCore Tree RIO Matrix Hist ${ROOT_MATHMORE_LIBRARY} MathCore +ROOT_EXECUTABLE(hist2workspace MakeModelAndMeasurements.cxx hist2workspace.cxx + LIBRARIES HistFactory RooFit RooFitCore Tree RIO Matrix Hist ${ROOT_MATHMORE_LIBRARY} ${GSL_LIBRARIES} MathCore Graf Gpad Minuit Foam RooStats XMLParser) #ROOT_INSTALL_HEADERS() -install(DIRECTORY inc/RooStats/HistFactory/ DESTINATION include/RooStats/HistFactory +install(DIRECTORY inc/RooStats/HistFactory/ DESTINATION ${CMAKE_INSTALL_INCDIR}/RooStats/HistFactory PATTERN ".svn" EXCLUDE REGEX "LinkDef" EXCLUDE ) diff --git a/roofit/histfactory/Module.mk b/roofit/histfactory/Module.mk index 82b28fcde3e04..9c1862a5de866 100644 --- a/roofit/histfactory/Module.mk +++ b/roofit/histfactory/Module.mk @@ -19,7 +19,7 @@ HF_PREPAREHISTFACTORY := bin/prepareHistFactory ##### tf_makeworkspace.exe ##### -HF_MAKEWORKSPACEEXES := $(MODDIRS)/MakeModelAndMeasurements.cxx +HF_MAKEWORKSPACEEXES := $(MODDIRS)/MakeModelAndMeasurements.cxx $(MODDIRS)/hist2workspace.cxx HF_MAKEWORKSPACEEXEO := $(call stripsrc,$(HF_MAKEWORKSPACEEXES:.cxx=.o)) HF_MAKEWORKSPACEEXEDEP := $(HF_MAKEWORKSPACEEXEO:.o=.d) @@ -49,6 +49,7 @@ HF_LIBS = -Llib -lRooFit -lRooFitCore -lTree -lRIO -lMatrix \ HF_LIBS += -lHistFactory ifeq ($(BUILDMATHMORE),yes) HF_LIBS += -lMathMore +HF_LIBS += $(GSLLIBDIR) $(GSLLIBS) endif endif @@ -65,7 +66,13 @@ HISTFACTORYDH := $(HISTFACTORYDS:.cxx=.h) HISTFACTORYH := $(filter-out $(MODDIRI)/LinkDef%,$(wildcard $(MODDIRI)/RooStats/HistFactory/*.h)) HISTFACTORYS := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx)) HISTFACTORYO := $(call stripsrc,$(HISTFACTORYS:.cxx=.o)) - +#location of header files for rootcint (cannot use absolute path for win32) +ifeq ($(PLATFORM),win32) +# convert mingw's /x/ to x:/ such that rootcint can handle it. +HISTFACTORYDICTI := $(shell echo $(MODDIRI) | sed 's,^/\(.\)/,\1:/,') +else +HISTFACTORYDICTI := $(MODDIRI) +endif HISTFACTORYDEP := $(HISTFACTORYO:.o=.d) $(HISTFACTORYDO:.o=.d) @@ -91,7 +98,6 @@ include/RooStats/HistFactory/%.h: $(HISTFACTORYDIRI)/RooStats/HistFactory/%.h fi) cp $< $@ - $(HISTFACTORYLIB): $(HISTFACTORYO) $(HISTFACTORYDO) $(ORDER_) $(MAINLIBS) \ $(HISTFACTORYLIBDEP) @$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \ @@ -102,33 +108,25 @@ $(HISTFACTORYLIB): $(HISTFACTORYO) $(HISTFACTORYDO) $(ORDER_) $(MAINLIBS) \ $(HISTFACTORYDS): $(HISTFACTORYH) $(HISTFACTORYL) $(ROOTCINTTMPDEP) $(MAKEDIR) @echo "Generating dictionary $@..." - $(ROOTCINTTMP) -f $@ -c $(HISTFACTORYH) $(HISTFACTORYL) + $(ROOTCINTTMP) -f $@ -c -I$(HISTFACTORYDICTI) $(HISTFACTORYH) $(HISTFACTORYL) $(HISTFACTORYMAP): $(RLIBMAP) $(MAKEFILEDEP) $(HISTFACTORYL) $(RLIBMAP) -o $@ -l $(HISTFACTORYLIB) \ -d $(HISTFACTORYLIBDEPM) -c $(HISTFACTORYL) - -$(HF_MAKEWORKSPACEEXE): $(HF_MAKEWORKSPACEEXEO) $(ROOTLIBSDEP) $(RINTLIB) $(HISTFACTORYLIBDEPM) \ - $(HF_PREPAREHISTFACTORY) $(HISTFACTORYLIB) +$(HF_MAKEWORKSPACEEXE): $(HF_MAKEWORKSPACEEXEO) $(ROOTLIBSDEP) $(RINTLIB) \ + $(HISTFACTORYLIBDEPM) $(HF_PREPAREHISTFACTORY) $(HISTFACTORYLIB) $(LD) $(LDFLAGS) -o $@ $(HF_MAKEWORKSPACEEXEO) $(ROOTICON) \ - $(ROOTULIBS) $(RPATH) $(ROOTLIBS) $(RINTLIBS) $(HF_LIBS) $(SYSLIBS) - -#$(HF_MAKEWORKSPACEEXE2): $(HF_MAKEWORKSPACEEXEO) $(ROOTLIBSDEP) $(RINTLIB) $(HISTFACTORYLIBDEPM) \ -# $(HF_PREPAREHISTFACTORY) $(HISTFACTORYLIB) -# $(LD) $(LDFLAGS) -o $@ $(HF_MAKEWORKSPACEEXEO) $(ROOTICON) \ -# $(ROOTULIBS) $(RPATH) $(ROOTLIBS) $(RINTLIBS) $(HF_LIBS) $(SYSLIBS) + $(ROOTULIBS) $(RPATH) $(ROOTLIBS) $(RINTLIBS) $(HF_LIBS) \ + $(SYSLIBS) $(HF_PREPAREHISTFACTORY): $(MODDIRC)/prepareHistFactory cp $(MODDIRC)/prepareHistFactory $@ chmod +x $@ +ALLEXECS += $(HF_MAKEWORKSPACEEXE) -ALLEXECS += $(HF_MAKEWORKSPACEEXE) # $(HF_MAKEWORKSPACEEXE2) - - - -all-$(MODNAME): $(HISTFACTORYLIB) $(HISTFACTORYMAP) $(HF_MAKEWORKSPACEEXE) #$(HF_MAKEWORKSPACEEXE2) +all-$(MODNAME): $(HISTFACTORYLIB) $(HISTFACTORYMAP) $(HF_MAKEWORKSPACEEXE) clean-$(MODNAME): @rm -f $(HISTFACTORYO) $(HISTFACTORYDO) diff --git a/roofit/histfactory/inc/LinkDef.h b/roofit/histfactory/inc/LinkDef.h index 85142bdf59cea..27aada9344e5d 100644 --- a/roofit/histfactory/inc/LinkDef.h +++ b/roofit/histfactory/inc/LinkDef.h @@ -5,6 +5,17 @@ #pragma link off all classes; #pragma link off all functions; + +#pragma link C++ namespace RooStats; +#pragma link C++ namespace RooStats::HistFactory; + +// for auto-loading namespaces +#ifdef USE_FOR_AUTLOADING +#pragma link C++ class RooStats::HistFactory; +#pragma link C++ class RooStats; +#endif + + #pragma link C++ class PiecewiseInterpolation- ; #pragma link C++ class ParamHistFunc+ ; #pragma link C++ class RooStats::HistFactory::LinInterpVar+ ; @@ -12,26 +23,29 @@ #pragma link C++ class RooStats::HistFactory::EstimateSummary+ ; #pragma link C++ class RooStats::HistFactory::HistoToWorkspaceFactory+ ; #pragma link C++ class RooStats::HistFactory::HistoToWorkspaceFactoryFast+ ; -//#pragma link C++ class RooStats::HistFactory::HistoToWorkspaceFactoryNew+ ; +#pragma link C++ class RooStats::HistFactory::RooBarlowBeestonLL+ ; +#pragma link C++ class RooStats::HistFactory::HistFactorySimultaneous+ ; +#pragma link C++ class RooStats::HistFactory::HistFactoryNavigation+ ; #pragma link C++ class RooStats::HistFactory::ConfigParser+ ; - #pragma link C++ class RooStats::HistFactory::Measurement+ ; +#pragma read sourceClass="RooStats::HistFactory::Measurement" targetClass="RooStats::HistFactory::Measurement" checksum="[973506941]" source="std::string fPOI" target="fPOI" code="{ fPOI.push_back(onfile.fPOI) ; }" + #pragma link C++ class RooStats::HistFactory::Channel+ ; #pragma link C++ class RooStats::HistFactory::Sample+ ; #pragma link C++ class RooStats::HistFactory::Data+ ; +#pragma link C++ class RooStats::HistFactory::Asimov+ ; #pragma link C++ class RooStats::HistFactory::StatError+ ; #pragma link C++ class RooStats::HistFactory::StatErrorConfig+ ; #pragma link C++ class RooStats::HistFactory::PreprocessFunction+ ; - #pragma link C++ class std::vector< RooStats::HistFactory::Channel >+ ; #pragma link C++ class std::vector< RooStats::HistFactory::Sample >+ ; -#pragma link C++ defined_in "include/RooStats/HistFactory/MakeModelAndMeasurementsFast.h"; -#pragma link C++ defined_in "include/RooStats/HistFactory/Systematics.h"; - - +// make dictionary for all the C++ classes defined in these following files +#pragma link C++ defined_in "RooStats/HistFactory/MakeModelAndMeasurementsFast.h"; +#pragma link C++ defined_in "RooStats/HistFactory/Systematics.h"; +#pragma link C++ defined_in "RooStats/HistFactory/HistFactoryModelUtils.h"; #endif diff --git a/roofit/histfactory/inc/RooStats/HistFactory/Asimov.h b/roofit/histfactory/inc/RooStats/HistFactory/Asimov.h new file mode 100644 index 0000000000000..b43e15a06c88a --- /dev/null +++ b/roofit/histfactory/inc/RooStats/HistFactory/Asimov.h @@ -0,0 +1,54 @@ +// @(#)root/roostats:$Id$ +// Author: George Lewis, Kyle Cranmer +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef HISTFACTORY_ASIMOV_H +#define HISTFACTORY_ASIMOV_H + +#include <string> +#include <vector> +#include <map> + +#include "RooWorkspace.h" + +namespace RooStats{ + namespace HistFactory { + + class Asimov { + + public: + + Asimov() {;} + Asimov(std::string Name) : fName(Name) {;} + + void ConfigureWorkspace( RooWorkspace* ); + + std::string GetName() { return fName; } + void SetName(const std::string& name) { fName = name; } + + void SetFixedParam(const std::string& param, bool constant=true) { fParamsToFix[param] = constant; } + void SetParamValue(const std::string& param, double value) { fParamValsToSet[param] = value; } + + std::map< std::string, bool >& GetParamsToFix() { return fParamsToFix; } + std::map< std::string, double >& GetParamsToSet() { return fParamValsToSet; } + + protected: + + std::string fName; + + std::map<std::string, bool> fParamsToFix; + std::map< std::string, double > fParamValsToSet; + + }; + + + } // namespace HistFactory +} // namespace RooStats + +#endif diff --git a/roofit/histfactory/inc/RooStats/HistFactory/Channel.h b/roofit/histfactory/inc/RooStats/HistFactory/Channel.h index 519ca57241d1f..2e781bd99e4fe 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/Channel.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/Channel.h @@ -1,3 +1,12 @@ +// @(#)root/roostats:$Id$ +// Author: George Lewis, Kyle Cranmer +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ #ifndef HISTFACTORY_CHANNEL_H #define HISTFACTORY_CHANNEL_H @@ -22,29 +31,42 @@ class Channel { Channel(); Channel(std::string Name, std::string InputFile=""); - + // set name of channel void SetName( const std::string& Name ) { fName = Name; } + // get name of channel std::string GetName() { return fName; } - + // set name of input file containing histograms void SetInputFile( const std::string& file ) { fInputFile = file; } + // get name of input file std::string GetInputFile() { return fInputFile; } - + // set path for histograms in input file void SetHistoPath( const std::string& file ) { fHistoPath = file; } + // get path to histograms in input file std::string GetHistoPath() { return fHistoPath; } + // set data object void SetData( const RooStats::HistFactory::Data& data ) { fData = data; } void SetData( std::string HistoName, std::string InputFile, std::string HistoPath="" ); void SetData( double Val ); void SetData( TH1* hData ); + // get data object RooStats::HistFactory::Data& GetData() { return fData; } + // add additional data object + void AddAdditionalData( const RooStats::HistFactory::Data& data ) { fAdditionalData.push_back(data); } + // retrieve vector of additional data objects + std::vector<RooStats::HistFactory::Data>& GetAdditionalData() { return fAdditionalData; } + void SetStatErrorConfig( double RelErrorThreshold, Constraint::Type ConstraintType ); void SetStatErrorConfig( double RelErrorThreshold, std::string ConstraintType ); + // define treatment of statistical uncertainties void SetStatErrorConfig( RooStats::HistFactory::StatErrorConfig Config ) { fStatErrorConfig = Config; } + // get information about threshold for statistical uncertainties and constraint term HistFactory::StatErrorConfig& GetStatErrorConfig() { return fStatErrorConfig; } void AddSample( RooStats::HistFactory::Sample sample ); + // get vector of samples for this channel std::vector< RooStats::HistFactory::Sample >& GetSamples() { return fSamples; } void Print(std::ostream& = std::cout); @@ -61,6 +83,10 @@ class Channel { HistFactory::Data fData; + // One can add additional datasets + // These are simply added to the xml under a different name + std::vector<RooStats::HistFactory::Data> fAdditionalData; + HistFactory::StatErrorConfig fStatErrorConfig; std::vector< RooStats::HistFactory::Sample > fSamples; diff --git a/roofit/histfactory/inc/RooStats/HistFactory/ConfigParser.h b/roofit/histfactory/inc/RooStats/HistFactory/ConfigParser.h index 99731bccae1d0..d7351346c2e31 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/ConfigParser.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/ConfigParser.h @@ -21,18 +21,11 @@ #include "TFile.h" #include "TXMLAttr.h" -//#include "RooStats/HistFactory/EstimateSummary.h" - - #include "RooStats/HistFactory/Channel.h" #include "RooStats/HistFactory/Measurement.h" #include "RooStats/HistFactory/Sample.h" -//using namespace std; - -// KC: Should make this a class and have it do some of what is done in MakeModelAndMeasurements - namespace RooStats{ namespace HistFactory { @@ -42,18 +35,9 @@ namespace RooStats{ // The "main" method std::vector< RooStats::HistFactory::Measurement > GetMeasurementsFromXML(std::string input); - - - // Another alternet method - // void FillMeasurementsAndChannelsFromXML(std::string input, - // std::vector< RooStats::HistFactory::Measurement >&, - // std::vector< RooStats::HistFactory::Channel >&); - - RooStats::HistFactory::Measurement CreateMeasurementFromDriverNode( TXMLNode* node ); RooStats::HistFactory::Channel ParseChannelXMLFile( std::string filen ); - // Helpers used to process a channel HistFactory::Data CreateDataElement( TXMLNode* node ); HistFactory::Sample CreateSampleElement( TXMLNode* node ); @@ -69,16 +53,8 @@ namespace RooStats{ HistFactory::StatError ActivateStatError( TXMLNode* node ); HistFactory::PreprocessFunction ParseFunctionConfig( TXMLNode* functionNode ); - // To be deprecated - /* - typedef pair<double,double> UncertPair; - void AddSystematic( RooStats::HistFactory::EstimateSummary &, TXMLNode*, string, string,string); - void ReadXmlConfig( string, vector<RooStats::HistFactory::Channel>& , Double_t ); - */ - protected: - bool CheckTrueFalse( std::string val, std::string Name ); bool IsAcceptableNode( TXMLNode* functionNode ); @@ -87,7 +63,6 @@ namespace RooStats{ // to these cached values std::string m_currentInputFile; std::string m_currentChannel; - // std::string m_currentHistoName; std::string m_currentHistoPath; }; diff --git a/roofit/histfactory/inc/RooStats/HistFactory/Data.h b/roofit/histfactory/inc/RooStats/HistFactory/Data.h index ba40d3cb82834..6cfb488366983 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/Data.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/Data.h @@ -1,3 +1,12 @@ +// @(#)root/roostats:$Id$ +// Author: George Lewis, Kyle Cranmer +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ #ifndef HISTFACTORY_DATA_H #define HISTFACTORY_DATA_H @@ -17,8 +26,11 @@ class Data { public: //friend class Channel; - Data() {;} + Data(); Data( std::string HistoName, std::string InputFile, std::string HistoPath="" ); + + std::string GetName() { return fName; } + void SetName(const std::string& name) { fName=name; } void SetInputFile(const std::string& InputFile) { fInputFile = InputFile; } std::string GetInputFile() { return fInputFile; } @@ -29,14 +41,16 @@ class Data { void SetHistoPath(const std::string& HistoPath) { fHistoPath = HistoPath; } std::string GetHistoPath() { return fHistoPath; } - void Print(std::ostream& = std::cout); + void PrintXML( std::ostream& ); void writeToFile( std::string FileName, std::string DirName ); TH1* GetHisto(); void SetHisto(TH1* Hist) { fhData = Hist; fHistoName=Hist->GetName(); } protected: + + std::string fName; std::string fInputFile; std::string fHistoName; diff --git a/roofit/histfactory/inc/RooStats/HistFactory/FlexibleInterpVar.h b/roofit/histfactory/inc/RooStats/HistFactory/FlexibleInterpVar.h index 4c6a2f75de485..c4bb7d58ff0fc 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/FlexibleInterpVar.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/FlexibleInterpVar.h @@ -14,6 +14,7 @@ #include "RooAbsPdf.h" #include "RooRealProxy.h" #include "RooListProxy.h" +#include <vector> class RooRealVar; class RooArgList ; @@ -27,11 +28,15 @@ namespace HistFactory{ FlexibleInterpVar() ; FlexibleInterpVar(const char *name, const char *title, const RooArgList& _paramList, - double nominal, vector<double> low, vector<double> high); + Double_t nominal, const RooArgList& low, const RooArgList& high); FlexibleInterpVar(const char *name, const char *title, - const RooArgList& _paramList, double nominal, vector<double> low, - vector<double> high,vector<int> code); + const RooArgList& _paramList, + double nominal, std::vector<double> low, std::vector<double> high); + + FlexibleInterpVar(const char *name, const char *title, + const RooArgList& _paramList, double nominal, std::vector<double> low, + std::vector<double> high,std::vector<int> code); FlexibleInterpVar(const char *name, const char *title); FlexibleInterpVar(const FlexibleInterpVar&, const char*); @@ -39,24 +44,35 @@ namespace HistFactory{ void setInterpCode(RooAbsReal& param, int code); void setAllInterpCodes(int code); void setGlobalBoundary(double boundary) {_interpBoundary = boundary;} + void setNominal(Double_t newNominal); + void setLow(RooAbsReal& param, Double_t newLow); + void setHigh(RooAbsReal& param, Double_t newHigh); void printAllInterpCodes(); virtual TObject* clone(const char* newname) const { return new FlexibleInterpVar(*this, newname); } virtual ~FlexibleInterpVar() ; + virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose = kFALSE, TString indent = "") const; + virtual void printFlexibleInterpVars(ostream& os) const; protected: RooListProxy _paramList ; Double_t _nominal; - vector<double> _low; - vector<double> _high; - vector<int> _interpCode; + std::vector<double> _low; + std::vector<double> _high; + std::vector<int> _interpCode; Double_t _interpBoundary; TIterator* _paramIter ; //! do not persist + mutable Bool_t _logInit ; //! + mutable std::vector<double> _logLo ; //! cached logs + mutable std::vector<double> _logHi ; //! cached logs + mutable std::vector<double> _powLo ; //! cached powers + mutable std::vector<double> _powHi ; //! cached powers + Double_t evaluate() const; ClassDef(RooStats::HistFactory::FlexibleInterpVar,2) // flexible interpolation diff --git a/roofit/histfactory/inc/RooStats/HistFactory/HistFactoryException.h b/roofit/histfactory/inc/RooStats/HistFactory/HistFactoryException.h index 7df687e81c321..c419545d58d35 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/HistFactoryException.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/HistFactoryException.h @@ -1,20 +1,35 @@ +// @(#)root/roostats:$Id$ +// Author: George Lewis, Kyle Cranmer +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + #ifndef HISTFACTORY_EXCEPTION #define HISTFACTORY_EXCEPTION - #include <iostream> #include <exception> -using namespace std; -class hf_exc: public exception -{ - virtual const char* what() const throw() - { - return "HistFactory - Exception"; + +namespace RooStats{ + namespace HistFactory{ + + class hf_exc: public std::exception + { + virtual const char* what() const throw() + { + return "HistFactory - Exception"; + } + }; + } -}; +} -static hf_exc bad_hf; +//static hf_exc bad_hf; #endif diff --git a/roofit/histfactory/inc/RooStats/HistFactory/HistFactoryModelUtils.h b/roofit/histfactory/inc/RooStats/HistFactory/HistFactoryModelUtils.h new file mode 100644 index 0000000000000..e56a960f38804 --- /dev/null +++ b/roofit/histfactory/inc/RooStats/HistFactory/HistFactoryModelUtils.h @@ -0,0 +1,37 @@ + +#ifndef HIST_FACTORY_MODEL_UTILS_H +#define HIST_FACTORY_MODEL_UTILS_H + +#include "RooAbsPdf.h" +#include "RooArgSet.h" +#include "RooDataSet.h" +#include "RooStats/HistFactory/ParamHistFunc.h" + +namespace RooStats { +namespace HistFactory { + + std::string channelNameFromPdf( RooAbsPdf* channelPdf ); + +// void getChannelsFromModel( RooAbsPdf* model, RooArgSet* channels, +// RooArgSet* channelsWithConstraints ); + + + void FactorizeHistFactoryPdf(const RooArgSet&, RooAbsPdf&, RooArgList&, RooArgList&); + bool getStatUncertaintyFromChannel( RooAbsPdf* channel, ParamHistFunc*& paramfunc, + RooArgList* gammaList ); + + RooAbsPdf* getSumPdfFromChannel( RooAbsPdf* channel ); + + void getDataValuesForObservables( std::map< std::string, std::vector<double> >& ChannelBinDataMap, + RooAbsData* data, RooAbsPdf* simPdf ); + + + int getStatUncertaintyConstraintTerm( RooArgList* constraints, RooRealVar* gamma_stat, + RooAbsReal*& pois_mean, RooRealVar*& tau ); + +} +} + + + +#endif diff --git a/roofit/histfactory/inc/RooStats/HistFactory/HistFactoryNavigation.h b/roofit/histfactory/inc/RooStats/HistFactory/HistFactoryNavigation.h new file mode 100644 index 0000000000000..806eaeb6022e4 --- /dev/null +++ b/roofit/histfactory/inc/RooStats/HistFactory/HistFactoryNavigation.h @@ -0,0 +1,201 @@ + +#include <map> + +#include "TH1.h" +#include "THStack.h" + +#include "RooDataSet.h" +#include "RooRealVar.h" +#include "RooProduct.h" +#include "RooStats/HistFactory/Measurement.h" +#include "RooStats/ModelConfig.h" + + +namespace RooStats { + namespace HistFactory { + + class HistFactoryNavigation { + + + public: + + // Initialze based on an already-created HistFactory Model + HistFactoryNavigation(ModelConfig* mc); + HistFactoryNavigation(const std::string& File, + const std::string& WorkspaceName="combined", + const std::string& ModelConfigName="ModelConfig"); + HistFactoryNavigation(RooAbsPdf* model, RooArgSet* observables); + + virtual ~HistFactoryNavigation() {} + + // Should pretty print all channels and the current values
 + void PrintState(); + // Should pretty print this and the current values + void PrintState(const std::string& channel); + + // Print the current values and errors of pdf parameters + void PrintParameters(bool IncludeConstantParams=false); + + // Print parameters that effect a particular channel + void PrintChannelParameters(const std::string& channel, + bool IncludeConstantParams=false); + + // Print parameters that effect a particular sample + void PrintSampleParameters(const std::string& channel, const std::string& sample, + bool IncludeConstantParams=false); + + // Print the different components that make up a sample + // (NormFactors, Statistical Uncertainties, Interpolation, etc) + void PrintSampleComponents(const std::string& channel, const std::string& sample); + + // Print a "HistFactory style" RooDataSet in a readable way + void PrintDataSet(RooDataSet* data, const std::string& channel=""); + + // Print the model and the data, comparing channel by channel + void PrintModelAndData(RooDataSet* data); + + // The value of the ith bin for the total in that channel + double GetBinValue(int bin, const std::string& channel); + // The value of the ith bin for that sample and channel
 + double GetBinValue(int bin, const std::string& channel, const std::string& sample); + + // The (current) histogram for that sample + // This includes all parameters and interpolation + TH1* GetSampleHist(const std::string& channel, + const std::string& sample, const std::string& name=""); + + // Get the total channel histogram for this channel + TH1* GetChannelHist(const std::string& channel, const std::string& name=""); + + // Get a histogram from the dataset for this channel + TH1* GetDataHist(RooDataSet* data, const std::string& channel, const std::string& name=""); + + // Get a stack of all samples in a channel + THStack* GetChannelStack(const std::string& channel, const std::string& name=""); + + // Draw a stack of the channel, and include data if the pointer is supplied + void DrawChannel(const std::string& channel, RooDataSet* data=NULL); + + // Get the RooAbsReal function for a given sample in a given channel + RooAbsReal* SampleFunction(const std::string& channel, const std::string& sample); + + // Get the set of observables for a given channel + RooArgSet* GetObservableSet(const std::string& channel); + + // Get the constraint term for a given systematic (alpha or gamma) + RooAbsReal* GetConstraintTerm(const std::string& parameter); + + // Get the uncertainty based on the constraint term for a given systematic + double GetConstraintUncertainty(const std::string& parameter); + + // Find a node in the pdf and replace it with a new node + // These nodes can be functions, pdf's, RooRealVar's, etc + // Will do minimial checking to make sure the replacement makes sense + void ReplaceNode(const std::string& ToReplace, RooAbsArg* ReplaceWith); + + // Set any RooRealVar's const (or not const) if they match + // the supplied regular expression + void SetConstant(const std::string& regExpr=".*", bool constant=true); + + void SetMaxBinToPrint(int max) { _maxBinToPrint = max; } + int GetMaxBinToPrint() const { return _maxBinToPrint; } + + void SetMinBinToPrint(int min) { _minBinToPrint = min; } + int GetMinBinToPrint() const { return _minBinToPrint; } + + // Get the model for this channel + RooAbsPdf* GetModel() const { return fModel; } + + // + RooAbsPdf* GetChannelPdf(const std::string& channel); + + + std::vector< std::string > GetChannelSampleList(const std::string& channel); + + // Return the RooRealVar by the same name used in the model + // If not found, return NULL + RooRealVar* var(const std::string& varName) const; + + /* + // Add a channel to the pdf + // Combine the data if it is provided + void AddChannel(const std::string& channel, RooAbsPdf* pdf, RooDataSet* data=NULL); + */ + + /* + // Add a constraint term to the pdf + // This method requires that the pdf NOT be simultaneous + void AddConstraintTerm(RooAbsArg* constraintTerm); + + // Add a constraint term to the pdf of a particular channel + // This method requires that the pdf be simultaneous + // OR that the channel string match the channel that the pdf represents + void AddConstraintTerm(RooAbsArg* constraintTerm, const std::string& channel); + */ + + protected: + + // Set the title and bin widths + void SetPrintWidths(const std::string& channel); + + // Fetch the node information for the pdf in question, and + // save it in the varous collections in this class + void _GetNodes(ModelConfig* mc); + void _GetNodes(RooAbsPdf* model, const RooArgSet* observables); + + // Print a histogram's contents to the screen + // void PrettyPrintHistogram(TH1* hist); + void PrintMultiDimHist(TH1* hist, int bin_print_width); + + // Make a histogram from a funciton + // Edit so it can take a RooArgSet of parameters + TH1* MakeHistFromRooFunction( RooAbsReal* func, RooArgList vars, std::string name="Hist" ); + + // Get a map of sample names to their functions for a particular channel + std::map< std::string, RooAbsReal*> GetSampleFunctionMap(const std::string& channel); + + private: + + // The HistFactory Pdf Pointer + RooAbsPdf* fModel; + + // The observables + RooArgSet* fObservables; + + int _minBinToPrint; + int _maxBinToPrint; + + int _label_print_width; + int _bin_print_width; + + // The list of channels + std::vector<std::string> fChannelNameVec; + + // Map of channel names to their full pdf's + std::map< std::string, RooAbsPdf* > fChannelPdfMap; + + // Map of channel names to pdf without constraint + std::map< std::string, RooAbsPdf* > fChannelSumNodeMap; + + // Map of channel names to their set of ovservables + std::map< std::string, RooArgSet*> fChannelObservMap; + + // Map of Map of Channel, Sample names to Function Nodes + // Used by doing: fChannelSampleFunctionMap["MyChannel"]["MySample"] + std::map< std::string, std::map< std::string, RooAbsReal*> > fChannelSampleFunctionMap; + + // Internal method implementation of finding a daughter node + // from a parent node (looping over all generations) + RooAbsArg* findChild(const std::string& name, RooAbsReal* parent) const; + + // Recursively get all products of products + RooArgSet _GetAllProducts(RooProduct* node); + + + protected: + ClassDef(RooStats::HistFactory::HistFactoryNavigation,2) + + }; + + } +} diff --git a/roofit/histfactory/inc/RooStats/HistFactory/HistFactorySimultaneous.h b/roofit/histfactory/inc/RooStats/HistFactory/HistFactorySimultaneous.h new file mode 100644 index 0000000000000..b45aae22f8483 --- /dev/null +++ b/roofit/histfactory/inc/RooStats/HistFactory/HistFactorySimultaneous.h @@ -0,0 +1,57 @@ +/***************************************************************************** + * Project: RooFit * + * Package: RooFitCore * + * File: $Id$ + * Authors: * + * WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu * + * DK, David Kirkby, UC Irvine, dkirkby@uci.edu * + * * + * Copyright (c) 2000-2005, Regents of the University of California * + * and Stanford University. All rights reserved. * + * * + * Redistribution and use in source and binary forms, * + * with or without modification, are permitted according to the terms * + * listed in LICENSE (http://roofit.sourceforge.net/license.txt) * + *****************************************************************************/ +#ifndef HISTFACTORY_SIMULTANEOUS +#define HISTFACTORY_SIMULTANEOUS + +//#include "THashList.h" +#include "RooSimultaneous.h" + +namespace RooStats{ +namespace HistFactory{ + + +class HistFactorySimultaneous : public RooSimultaneous { +public: + + // Constructors, assignment etc + inline HistFactorySimultaneous() : RooSimultaneous() {} //_plotCoefNormRange(0) { } + HistFactorySimultaneous(const char *name, const char *title, RooAbsCategoryLValue& indexCat) ; + HistFactorySimultaneous(const char *name, const char *title, std::map<std::string,RooAbsPdf*> pdfMap, RooAbsCategoryLValue& inIndexCat) ; + HistFactorySimultaneous(const char *name, const char *title, const RooArgList& pdfList, RooAbsCategoryLValue& indexCat) ; + HistFactorySimultaneous(const HistFactorySimultaneous& other, const char* name=0); + HistFactorySimultaneous(const RooSimultaneous& other, const char* name=0); + ~HistFactorySimultaneous(); + + virtual TObject* clone(const char* newname) const { return new HistFactorySimultaneous(*this,newname) ; } + + virtual RooAbsReal* createNLL(RooAbsData& data, const RooLinkedList& cmdList); + + virtual RooAbsReal* createNLL(RooAbsData& data, + const RooCmdArg& arg1 = RooCmdArg::none(), const RooCmdArg& arg2 = RooCmdArg::none(), + const RooCmdArg& arg3 = RooCmdArg::none(), const RooCmdArg& arg4 = RooCmdArg::none(), + const RooCmdArg& arg5 = RooCmdArg::none(), const RooCmdArg& arg6 = RooCmdArg::none(), + const RooCmdArg& arg7 = RooCmdArg::none(), const RooCmdArg& arg8 = RooCmdArg::none()); + + +protected: + + ClassDef(RooStats::HistFactory::HistFactorySimultaneous,2) // Simultaneous operator p.d.f, functions like C++ 'switch()' on input p.d.fs operating on index category5A +}; + +} +} + +#endif diff --git a/roofit/histfactory/inc/RooStats/HistFactory/HistoToWorkspaceFactory.h b/roofit/histfactory/inc/RooStats/HistFactory/HistoToWorkspaceFactory.h index 2b19df24ff242..b60a30feb21b4 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/HistoToWorkspaceFactory.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/HistoToWorkspaceFactory.h @@ -37,58 +37,59 @@ namespace HistFactory{ public: - HistoToWorkspaceFactory( string, string , vector<string> , double =200, double =20, int =0, int =6, TFile * =0); + HistoToWorkspaceFactory( std::string, std::string , std::vector<std::string> , double =200, double =20, int =0, int =6, TFile * =0); HistoToWorkspaceFactory(); virtual ~HistoToWorkspaceFactory(); - void AddEfficiencyTerms(RooWorkspace* proto, string prefix, string interpName, - map<string,pair<double,double> > systMap, - vector<string>& likelihoodTermNames, vector<string>& totSystTermNames); + void AddEfficiencyTerms(RooWorkspace* proto, std::string prefix, std::string interpName, + std::map<std::string,std::pair<double,double> > systMap, + std::vector<std::string>& likelihoodTermNames, std::vector<std::string>& totSystTermNames); - string AddNormFactor(RooWorkspace *, string & , string & , EstimateSummary & , bool ); + std::string AddNormFactor(RooWorkspace *, std::string & , std::string & , EstimateSummary & , bool ); - void AddMultiVarGaussConstraint(RooWorkspace* proto, string prefix,int lowBin, int highBin, vector<string>& likelihoodTermNames); + void AddMultiVarGaussConstraint(RooWorkspace* proto, std::string prefix,int lowBin, int highBin, std::vector<std::string>& likelihoodTermNames); - void AddPoissonTerms(RooWorkspace* proto, string prefix, string obsPrefix, string expPrefix, int lowBin, int highBin, - vector<string>& likelihoodTermNames); + void AddPoissonTerms(RooWorkspace* proto, std::string prefix, std::string obsPrefix, std::string expPrefix, int lowBin, int highBin, + std::vector<std::string>& likelihoodTermNames); //void Combine_old(); - RooWorkspace * MakeCombinedModel(vector<string>, vector<RooWorkspace*>); + RooWorkspace * MakeCombinedModel(std::vector<std::string>, std::vector<RooWorkspace*>); - //void Combine_ratio(vector<string> , vector<RooWorkspace*>); + //void Combine_ratio(std::vector<std::string> , std::vector<RooWorkspace*>); - void Customize(RooWorkspace* proto, const char* pdfNameChar, map<string,string> renameMap); + void Customize(RooWorkspace* proto, const char* pdfNameChar, std::map<std::string,std::string> renameMap); - void EditSyst(RooWorkspace* proto, const char* pdfNameChar, map<string,double> gammaSyst, map<string,double> uniformSyst, map<string,double> logNormSyst); + void EditSyst(RooWorkspace* proto, const char* pdfNameChar, std::map<std::string,double> gammaSyst, std::map<std::string,double> uniformSyst, std::map<std::string,double> logNormSyst); - void FormatFrameForLikelihood(RooPlot* frame, string XTitle=string("#sigma / #sigma_{SM}"), string YTitle=string("-log likelihood")); + void FormatFrameForLikelihood(RooPlot* frame, std::string XTitle=std::string("#sigma / #sigma_{SM}"), std::string YTitle=std::string("-log likelihood")); - void LinInterpWithConstraint(RooWorkspace* proto, TH1* nominal, vector<TH1*> lowHist, vector<TH1*> highHist, - vector<string> sourceName, string prefix, string productPrefix, string systTerm, - int lowBin, int highBin, vector<string>& likelihoodTermNames); + void LinInterpWithConstraint(RooWorkspace* proto, TH1* nominal, std::vector<TH1*> lowHist, std::vector<TH1*> highHist, + std::vector<std::string> sourceName, std::string prefix, std::string productPrefix, std::string systTerm, + int lowBin, int highBin, std::vector<std::string>& likelihoodTermNames); - TDirectory* Makedirs( TDirectory* file, vector<string> names ); + TDirectory* Makedirs( TDirectory* file, std::vector<std::string> names ); - RooWorkspace* MakeSingleChannelModel(vector<RooStats::HistFactory::EstimateSummary> summary, vector<string> systToFix, bool doRatio=false); + RooWorkspace* MakeSingleChannelModel(std::vector<RooStats::HistFactory::EstimateSummary> summary, std::vector<std::string> systToFix, bool doRatio=false); - void MakeTotalExpected(RooWorkspace* proto, string totName, string /**/, string /**/, - int lowBin, int highBin, vector<string>& syst_x_expectedPrefixNames, - vector<string>& normByNames); + void MakeTotalExpected(RooWorkspace* proto, std::string totName, std::string /**/, std::string /**/, + int lowBin, int highBin, std::vector<std::string>& syst_x_expectedPrefixNames, + std::vector<std::string>& normByNames); - TDirectory* Mkdir( TDirectory * file, string name ); + TDirectory* Mkdir( TDirectory * file, std::string name ); - void PrintCovarianceMatrix(RooFitResult* result, RooArgSet* params, string filename); - void ProcessExpectedHisto(TH1* hist,RooWorkspace* proto, string prefix, string productPrefix, string systTerm, double low, double high, int lowBin, int highBin); - void SetObsToExpected(RooWorkspace* proto, string obsPrefix, string expPrefix, int lowBin, int highBin); - void FitModel(RooWorkspace *, string, string, string, bool=false ); + void PrintCovarianceMatrix(RooFitResult* result, RooArgSet* params, std::string filename); + void ProcessExpectedHisto(TH1* hist,RooWorkspace* proto, std::string prefix, std::string productPrefix, std::string systTerm, double low, double high, int lowBin, int highBin); + void SetObsToExpected(RooWorkspace* proto, std::string obsPrefix, std::string expPrefix, int lowBin, int highBin); + void FitModel(RooWorkspace *, std::string, std::string, std::string, bool=false ); std::string FilePrefixStr(std::string); - string fFileNamePrefix; - string fRowTitle; - vector<string> fSystToFix; - double fNomLumi, fLumiError; + + std::string fFileNamePrefix; + std::string fRowTitle; + std::vector<std::string> fSystToFix; + double fNomLumi, fLumiError; int fLowBin, fHighBin; std::stringstream fResultsPrefixStr; TFile * fOut_f; diff --git a/roofit/histfactory/inc/RooStats/HistFactory/HistoToWorkspaceFactoryFast.h b/roofit/histfactory/inc/RooStats/HistFactory/HistoToWorkspaceFactoryFast.h index 2c5c9c2b53aa5..e81d2a014edae 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/HistoToWorkspaceFactoryFast.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/HistoToWorkspaceFactoryFast.h @@ -27,106 +27,120 @@ #include <TH1.h> #include <TDirectory.h> -#include "RooStats/HistFactory/EstimateSummary.h" -#include "RooStats/HistFactory/Measurement.h" - - +#include "RooStats/HistFactory/Systematics.h" class ParamHistFunc; namespace RooStats{ -namespace HistFactory{ - class HistoToWorkspaceFactoryFast: public TObject { - - public: - - HistoToWorkspaceFactoryFast( string, string , vector<string> , double =200, double =20, int =0, int =6, TFile* =NULL); - HistoToWorkspaceFactoryFast( RooStats::HistFactory::Measurement& Meas ); - static void ConfigureWorkspaceForMeasurement( const std::string& ModelName, RooWorkspace* ws_single, Measurement& measurement ); - - HistoToWorkspaceFactoryFast(); - virtual ~HistoToWorkspaceFactoryFast(); - - RooWorkspace* MakeSingleChannelModel( Measurement& measurement, Channel& channel ); - static RooWorkspace* MakeCombinedModel( Measurement& measurement ); - - void SetFunctionsToPreprocess(vector<string> lines){ fPreprocessFunctions = lines;} - - void AddEfficiencyTerms(RooWorkspace* proto, string prefix, string interpName, - map<string,pair<double,double> > systMap, - vector<string>& likelihoodTermNames, vector<string>& totSystTermNames); - - string AddNormFactor(RooWorkspace *, string & , string & , EstimateSummary & , bool ); - - void AddMultiVarGaussConstraint(RooWorkspace* proto, string prefix,int lowBin, int highBin, vector<string>& likelihoodTermNames); - - void AddPoissonTerms(RooWorkspace* proto, string prefix, string obsPrefix, string expPrefix, int lowBin, int highBin, - vector<string>& likelihoodTermNames); - - //void Combine_old(); - - RooWorkspace * MakeCombinedModel(vector<string>, vector<RooWorkspace*>); - - //void Combine_ratio(vector<string> , vector<RooWorkspace*>); - - void Customize(RooWorkspace* proto, const char* pdfNameChar, map<string,string> renameMap); - - static void EditSyst(RooWorkspace* proto, const char* pdfNameChar, - map<string,double> gammaSyst, map<string,double> uniformSyst, map<string,double> logNormSyst, map<string,double> noSyst); - - //void FormatFrameForLikelihood(RooPlot* frame, string XTitle=string("#sigma / #sigma_{SM}"), string YTitle=string("-log likelihood")); - - - void LinInterpWithConstraint(RooWorkspace* proto, TH1* nominal, vector<TH1*> lowHist, vector<TH1*> highHist, - vector<string> sourceName, string prefix, string productPrefix, string systTerm, - int lowBin, int highBin, vector<string>& likelihoodTermNames); - - TDirectory* Makedirs( TDirectory* file, vector<string> names ); - - RooWorkspace* MakeSingleChannelModel(vector<RooStats::HistFactory::EstimateSummary> summary, vector<string> systToFix, bool doRatio=false); - - void MakeTotalExpected(RooWorkspace* proto, string totName, string /**/, string /**/, - int lowBin, int highBin, vector<string>& syst_x_expectedPrefixNames, - vector<string>& normByNames); - - TDirectory* Mkdir( TDirectory * file, string name ); - - static void PrintCovarianceMatrix(RooFitResult* result, RooArgSet* params, string filename); - void ProcessExpectedHisto(TH1* hist,RooWorkspace* proto, string prefix, string productPrefix, string systTerm, double low, double high, int lowBin, int highBin); - void SetObsToExpected(RooWorkspace* proto, string obsPrefix, string expPrefix, int lowBin, int highBin); - //void FitModel(const std::string& FileNamePrefix, RooWorkspace *, string, string, TFile*, FILE*); - //std::string FilePrefixStr(std::string); - - TH1* MakeScaledUncertaintyHist( const std::string& Name, std::vector< std::pair<TH1*,TH1*> > HistVec ); - TH1* MakeAbsolUncertaintyHist( const std::string& Name, const TH1* Hist ); - RooArgList createStatConstraintTerms( RooWorkspace* proto, vector<string>& constraintTerms, ParamHistFunc& paramHist, TH1* uncertHist, - EstimateSummary::ConstraintType type, Double_t minSigma ); + namespace HistFactory{ + + // Forward Declarations FTW + class Measurement; + class Channel; + class Sample; + + class HistoToWorkspaceFactoryFast: public TObject { - inline void SetObsNameVec(const std::vector<std::string>& obsNameVec) { fObsNameVec = obsNameVec; } - inline void SetObsName(const std::string& obsName) { fObsNameVec.clear(); fObsNameVec.push_back(obsName); fObsName = obsName; } - inline void AddObsName(const std::string& obsName) { fObsNameVec.push_back(obsName); } + public: + + + HistoToWorkspaceFactoryFast(); + HistoToWorkspaceFactoryFast( RooStats::HistFactory::Measurement& Meas ); + virtual ~HistoToWorkspaceFactoryFast(); + + static void ConfigureWorkspaceForMeasurement( const std::string& ModelName, + RooWorkspace* ws_single, + Measurement& measurement ); - //string fFileNamePrefix; - //string fRowTitle; - vector<string> fSystToFix; - double fNomLumi, fLumiError; - int fLowBin, fHighBin; - //std::stringstream fResultsPrefixStr; - //TFile * fOut_f; - // FILE * pFile; + RooWorkspace* MakeSingleChannelModel( Measurement& measurement, Channel& channel ); + RooWorkspace* MakeCombinedModel(std::vector<std::string>, std::vector<RooWorkspace*>); - private: + static RooWorkspace* MakeCombinedModel( Measurement& measurement ); + static void PrintCovarianceMatrix(RooFitResult* result, RooArgSet* params, + std::string filename); + + void SetFunctionsToPreprocess(std::vector<std::string> lines) { fPreprocessFunctions=lines; } + + protected: + + void AddEfficiencyTerms(RooWorkspace* proto, std::string prefix, std::string interpName, + std::vector<OverallSys>& systList, + std::vector<std::string>& likelihoodTermNames, + std::vector<std::string>& totSystTermNames); + + std::string AddNormFactor(RooWorkspace* proto, std::string& channel, + std::string& sigmaEpsilon, Sample& sample, bool doRatio); + + void AddMultiVarGaussConstraint(RooWorkspace* proto, std::string prefix, + int lowBin, int highBin, + std::vector<std::string>& likelihoodTermNames); + + void AddPoissonTerms(RooWorkspace* proto, std::string prefix, std::string obsPrefix, + std::string expPrefix, int lowBin, int highBin, + std::vector<std::string>& likelihoodTermNames); + + static void EditSyst(RooWorkspace* proto, const char* pdfNameChar, + std::map<std::string,double> gammaSyst, + std::map<std::string,double> uniformSyst, + std::map<std::string,double> logNormSyst, + std::map<std::string,double> noSyst); + + void LinInterpWithConstraint(RooWorkspace* proto, TH1* nominal, std::vector<HistoSys>, + std::string prefix, std::string productPrefix, + std::string systTerm, + std::vector<std::string>& likelihoodTermNames); + + RooWorkspace* MakeSingleChannelWorkspace(Measurement& measurement, Channel& channel); + + void MakeTotalExpected(RooWorkspace* proto, std::string totName, + std::vector<std::string>& syst_x_expectedPrefixNames, + std::vector<std::string>& normByNames); + + RooDataSet* MergeDataSets(RooWorkspace* combined, + std::vector<RooWorkspace*> wspace_vec, + std::vector<std::string> channel_names, + std::string dataSetName, + RooArgList obsList, + RooCategory* channelCat); + + void ProcessExpectedHisto(TH1* hist, RooWorkspace* proto, std::string prefix, + std::string productPrefix, std::string systTerm ); + + void SetObsToExpected(RooWorkspace* proto, std::string obsPrefix, std::string expPrefix, + int lowBin, int highBin); + + TH1* MakeScaledUncertaintyHist(const std::string& Name, + std::vector< std::pair<TH1*, TH1*> > HistVec ); + + TH1* MakeAbsolUncertaintyHist( const std::string& Name, const TH1* Hist ); + + RooArgList createStatConstraintTerms( RooWorkspace* proto, + std::vector<std::string>& constraintTerms, + ParamHistFunc& paramHist, TH1* uncertHist, + Constraint::Type type, Double_t minSigma ); + + void ConfigureHistFactoryDataset(RooDataSet* obsData, TH1* nominal, RooWorkspace* proto, + std::vector<std::string> obsNameVec); + + std::vector<std::string> fSystToFix; + std::map<std::string, double> fParamValues; + double fNomLumi; + double fLumiError; + int fLowBin; + int fHighBin; + + private: - void GuessObsNameVec(TH1* hist); + void GuessObsNameVec(TH1* hist); - std::vector<std::string> fObsNameVec; - std::string fObsName; - vector<string> fPreprocessFunctions; + std::vector<std::string> fObsNameVec; + std::string fObsName; + std::vector<std::string> fPreprocessFunctions; - ClassDef(RooStats::HistFactory::HistoToWorkspaceFactoryFast,3) - }; + ClassDef(RooStats::HistFactory::HistoToWorkspaceFactoryFast,3) + }; -} + } } #endif diff --git a/roofit/histfactory/inc/RooStats/HistFactory/LinInterpVar.h b/roofit/histfactory/inc/RooStats/HistFactory/LinInterpVar.h index 4821f7717d26f..3225ad7f726af 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/LinInterpVar.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/LinInterpVar.h @@ -26,7 +26,7 @@ namespace HistFactory{ LinInterpVar() ; LinInterpVar(const char *name, const char *title, - const RooArgList& _paramList, double nominal, vector<double> low, vector<double> high); + const RooArgList& _paramList, double nominal, std::vector<double> low, std::vector<double> high); LinInterpVar(const char *name, const char *title); LinInterpVar(const LinInterpVar&, const char*); @@ -39,8 +39,8 @@ namespace HistFactory{ RooListProxy _paramList ; double _nominal; - vector<double> _low; - vector<double> _high; + std::vector<double> _low; + std::vector<double> _high; TIterator* _paramIter ; //! do not persist diff --git a/roofit/histfactory/inc/RooStats/HistFactory/MakeModelAndMeasurementsFast.h b/roofit/histfactory/inc/RooStats/HistFactory/MakeModelAndMeasurementsFast.h index 9b4946aa43ac8..c4ae64eab8420 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/MakeModelAndMeasurementsFast.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/MakeModelAndMeasurementsFast.h @@ -1,21 +1,34 @@ -#ifndef MAKEMODELANDMEASUREMENTSFAST_H -#define MAKEMODELANDMEASUREMENTSFAST_H +#ifndef HISTFACTORY_MAKEMODELANDMEASUREMENTSFAST_H +#define HISTFACTORY_MAKEMODELANDMEASUREMENTSFAST_H + +#include <string> +#include <vector> + +#include "RooStats/HistFactory/Measurement.h" +#include "RooStats/HistFactory/Channel.h" +#include "RooStats/HistFactory/EstimateSummary.h" + +#include "RooWorkspace.h" +#include "RooPlot.h" +#include "TFile.h" + namespace RooStats{ namespace HistFactory{ + //void fastDriver(std::string input); RooWorkspace* MakeModelAndMeasurementFast( RooStats::HistFactory::Measurement& measurement ); //RooWorkspace* MakeModelFast( RooStats::HistFactory::Measurement& measurement ); - std::vector<EstimateSummary> GetChannelEstimateSummaries(RooStats::HistFactory::Measurement& measurement, RooStats::HistFactory::Channel& channel); + std::vector<RooStats::HistFactory::EstimateSummary> GetChannelEstimateSummaries(RooStats::HistFactory::Measurement& measurement, RooStats::HistFactory::Channel& channel); // void ConfigureWorkspaceForMeasurement( const std::string&, RooWorkspace*, RooStats::HistFactory::Measurement&); - void FormatFrameForLikelihood(RooPlot* frame, string XTitle=string("#sigma / #sigma_{SM}"), string YTitle=string("-log likelihood")); - void FitModel(RooWorkspace *, string data_name="obsData"); - void FitModelAndPlot(const std::string& MeasurementName, const std::string& FileNamePrefix, RooWorkspace *, string, string, TFile*, FILE*); + void FormatFrameForLikelihood(RooPlot* frame, std::string xTitle=std::string("#sigma / #sigma_{SM}"), std::string yTitle=std::string("-log likelihood")); + void FitModel(RooWorkspace *, std::string data_name="obsData"); + void FitModelAndPlot(const std::string& measurementName, const std::string& fileNamePrefix, RooWorkspace *, std::string, std::string, TFile*, FILE*); } } diff --git a/roofit/histfactory/inc/RooStats/HistFactory/Measurement.h b/roofit/histfactory/inc/RooStats/HistFactory/Measurement.h index 545c31a128206..27b6816241551 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/Measurement.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/Measurement.h @@ -1,3 +1,12 @@ +// @(#)root/roostats:$Id$ +// Author: George Lewis, Kyle Cranmer +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ #ifndef HISTFACTORY_MEASUREMENT_H #define HISTFACTORY_MEASUREMENT_H @@ -13,7 +22,7 @@ #include "PreprocessFunction.h" #include "RooStats/HistFactory/Channel.h" - +#include "RooStats/HistFactory/Asimov.h" namespace RooStats{ namespace HistFactory { @@ -27,32 +36,57 @@ class Measurement : public TNamed { // Measurement( const Measurement& other ); // Copy Measurement(const char* Name, const char* Title=""); - // std::string Name; - - + // set output prefix void SetOutputFilePrefix( const std::string& prefix ) { fOutputFilePrefix = prefix; } + // retrieve prefix for output files std::string GetOutputFilePrefix() { return fOutputFilePrefix; } - void SetPOI( const std::string& POI ) { fPOI = POI; } - std::string GetPOI() { return fPOI; } + // insert PoI at beginning of vector of PoIs + void SetPOI( const std::string& POI ) { fPOI.insert( fPOI.begin(), POI ); } + // append parameter to vector of PoIs + void AddPOI( const std::string& POI ) { fPOI.push_back(POI); } + // get name of PoI at given index + std::string GetPOI(unsigned int i=0) { return fPOI.at(i); } + // get vector of PoI names + std::vector<std::string>& GetPOIList() { return fPOI; } - void AddConstantParam( const std::string& param ) { fConstantParams.push_back( param ); } + // Add a parameter to be set as constant + // (Similar to ParamSetting method below) + void AddConstantParam( const std::string& param ); + // empty vector of constant parameters void ClearConstantParams() { fConstantParams.clear(); } + // get vector of all constant parameters std::vector< std::string >& GetConstantParams() { return fConstantParams; } + // Set a parameter to a specific value + // (And optionally fix it) + void SetParamValue( const std::string& param, double value); + // get map: parameter name <--> parameter value + std::map<std::string, double>& GetParamValues() { return fParamValues; } + // clear map of parameter values + void ClearParamValues() { fParamValues.clear(); } + + void AddPreprocessFunction( std::string name, std::string expression, std::string dependencies ); + // add a preprocess function object void AddFunctionObject( const RooStats::HistFactory::PreprocessFunction function) { fFunctionObjects.push_back( function ); } void SetFunctionObjects( std::vector< RooStats::HistFactory::PreprocessFunction > objects ) { fFunctionObjects = objects; } + // get vector of defined function objects std::vector< RooStats::HistFactory::PreprocessFunction >& GetFunctionObjects() { return fFunctionObjects; } + std::vector< std::string > GetPreprocessFunctions(); - void AddPreprocessFunction( const std::string& function ) { fPreprocessFunctions.push_back( function ); } - void SetPreprocessFunctions( std::vector< std::string > functions ) { fPreprocessFunctions = functions; } - std::vector< std::string >& GetPreprocessFunctions() { return fPreprocessFunctions; } - void ClearPreprocessFunctions() { fPreprocessFunctions.clear(); } + // get vector of defined Asimov Datasets + std::vector< RooStats::HistFactory::Asimov >& GetAsimovDatasets() { return fAsimovDatasets; } + // add an Asimov Dataset + void AddAsimovDataset( RooStats::HistFactory::Asimov dataset ) { fAsimovDatasets.push_back(dataset); } + // set integrated luminosity used to normalise histograms (if NormalizeByTheory is true for this sample) void SetLumi(double Lumi ) { fLumi = Lumi; } + // set relative uncertainty on luminosity void SetLumiRelErr( double RelErr ) { fLumiRelErr = RelErr; } + // retrieve integrated luminosity double GetLumi() { return fLumi; } + // retrieve relative uncertainty on luminosity double GetLumiRelErr() { return fLumiRelErr; } void SetBinLow( int BinLow ) { fBinLow = BinLow; } @@ -60,6 +94,7 @@ class Measurement : public TNamed { int GetBinLow() { return fBinLow; } int GetBinHigh() { return fBinHigh; } + // do not produce any plots or tables, just save the model void SetExportOnly( bool ExportOnly ) { fExportOnly = ExportOnly; } bool GetExportOnly() { return fExportOnly; } @@ -69,6 +104,7 @@ class Measurement : public TNamed { std::vector< RooStats::HistFactory::Channel >& GetChannels() { return fChannels; } RooStats::HistFactory::Channel& GetChannel( std::string ); + // add a completely configured channel void AddChannel( RooStats::HistFactory::Channel chan ) { fChannels.push_back( chan ); } bool HasChannel( std::string ); @@ -77,43 +113,53 @@ class Measurement : public TNamed { void CollectHistograms(); + void AddGammaSyst(std::string syst, double uncert); + void AddLogNormSyst(std::string syst, double uncert); + void AddUniformSyst(std::string syst); + void AddNoSyst(std::string syst); + std::map< std::string, double >& GetGammaSyst() { return fGammaSyst; } std::map< std::string, double >& GetUniformSyst() { return fUniformSyst; } std::map< std::string, double >& GetLogNormSyst() { return fLogNormSyst; } std::map< std::string, double >& GetNoSyst() { return fNoSyst; } - private: + // Configurables of this measurement std::string fOutputFilePrefix; - std::string fPOI; + std::vector<std::string> fPOI; + double fLumi; + double fLumiRelErr; + int fBinLow; + int fBinHigh; + bool fExportOnly; + std::string fInterpolationScheme; + // Channels that make up this measurement std::vector< RooStats::HistFactory::Channel > fChannels; + + // List of Parameters to be set constant std::vector< std::string > fConstantParams; + + // Map of parameter names to inital values to be set + std::map< std::string, double > fParamValues; + + // List of Preprocess Function objects std::vector< RooStats::HistFactory::PreprocessFunction > fFunctionObjects; - std::vector< std::string > fPreprocessFunctions; - //std::vector< std::string > constraintTerms; + // List of Asimov datasets to generate + std::vector< RooStats::HistFactory::Asimov > fAsimovDatasets; + + // List of Alternate constraint terms std::map< std::string, double > fGammaSyst; std::map< std::string, double > fUniformSyst; std::map< std::string, double > fLogNormSyst; std::map< std::string, double > fNoSyst; - - double fLumi; - double fLumiRelErr; - - int fBinLow; - int fBinHigh; - - bool fExportOnly; - bool fSaveExtra; - - std::string fInterpolationScheme; std::string GetDirPath( TDirectory* dir ); - ClassDef(RooStats::HistFactory::Measurement, 1); + ClassDef(RooStats::HistFactory::Measurement, 3); }; diff --git a/roofit/histfactory/inc/RooStats/HistFactory/ParamHistFunc.h b/roofit/histfactory/inc/RooStats/HistFactory/ParamHistFunc.h index 3fab4355de015..55c78f02b5463 100755 --- a/roofit/histfactory/inc/RooStats/HistFactory/ParamHistFunc.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/ParamHistFunc.h @@ -1,18 +1,13 @@ -/***************************************************************************** - * Project: RooFit * - * Package: RooFitCore * - * File: $Id: ParamHistFunc.h,v 1.3 2007/05/11 09:11:30 verkerke Exp $ - * Authors: * - * WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu * - * DK, David Kirkby, UC Irvine, dkirkby@uci.edu * - * * - * Copyright (c) 2000-2005, Regents of the University of California * - * and Stanford University. All rights reserved. * - * * - * Redistribution and use in source and binary forms, * - * with or without modification, are permitted according to the terms * - * listed in LICENSE (http://roofit.sourceforge.net/license.txt) * - *****************************************************************************/ +// @(#)root/roostats:$Id: cranmer $ +// Author: George Lewis, Kyle Cranmer +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + #ifndef ROO_PARAMHISTFUNC #define ROO_PARAMHISTFUNC @@ -36,22 +31,19 @@ class ParamHistFunc : public RooAbsReal { ParamHistFunc() ; ParamHistFunc(const char *name, const char *title, const RooArgList& vars, const RooArgList& paramSet ); ParamHistFunc(const char *name, const char *title, const RooArgList& vars, const RooArgList& paramSet, const TH1* hist ); - // Not yet fully implemented: - //ParamHistFunc(const char *name, const char *title, const RooRealVar& var, const RooArgList& paramSet, const RooAbsReal& nominal ); virtual ~ParamHistFunc() ; - ParamHistFunc(const ParamHistFunc& other, const char* name = 0); virtual TObject* clone(const char* newname) const { return new ParamHistFunc(*this, newname); } - // void printMetaArgs(ostream& os) const ; - const RooArgList& paramList() const { return _paramSet ; } - Int_t numBins() const { return _dataSet.numEntries(); } // Number of bins (called numEntries in RooDataHist) void setParamConst( Int_t, Bool_t=kTRUE ); + void setConstant(bool constant); + + void setShape(TH1* shape); RooRealVar& getParameter() const ; RooRealVar& getParameter( Int_t masterIdx ) const ; @@ -59,15 +51,13 @@ class ParamHistFunc : public RooAbsReal { const RooArgSet* get(Int_t masterIdx) const { return _dataSet.get( masterIdx ) ; } const RooArgSet* get(const RooArgSet& coord) const { return _dataSet.get( coord ) ; } - + double binVolume() const { return _dataSet.binVolume(); } virtual Bool_t forceAnalyticalInt(const RooAbsArg&) const { return kTRUE ; } Int_t getAnalyticalIntegralWN(RooArgSet& allVars, RooArgSet& analVars, const RooArgSet* normSet,const char* rangeName=0) const ; Double_t analyticalIntegralWN(Int_t code, const RooArgSet* normSet, const char* rangeName=0) const ; - - static RooArgList createParamSet(RooWorkspace& w, const std::string&, const RooArgList& Vars); static RooArgList createParamSet(RooWorkspace& w, const std::string&, const RooArgList& Vars, Double_t, Double_t); static RooArgList createParamSet(const std::string&, Int_t, Double_t, Double_t); @@ -92,7 +82,7 @@ class ParamHistFunc : public RooAbsReal { RooArgList _funcIntList ; RooArgList _lowIntList ; RooArgList _highIntList ; - // will want vector<RooRealVar*> for low and high also + // will want std::vector<RooRealVar*> for low and high also } ; mutable RooObjCacheManager _normIntMgr ; // The integration cache manager @@ -105,6 +95,7 @@ class ParamHistFunc : public RooAbsReal { Int_t _numBins; mutable std::map<Int_t, Int_t> _binMap; mutable RooDataHist _dataSet; + Bool_t _Normalized; // std::vector< Double_t > _nominalVals; // The nominal vals when gamma = 1.0 ( = 1.0 by default) RooArgList _ownedList ; // List of owned components diff --git a/roofit/histfactory/inc/RooStats/HistFactory/PiecewiseInterpolation.h b/roofit/histfactory/inc/RooStats/HistFactory/PiecewiseInterpolation.h index c895446d75e5c..7afbbe284ba6a 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/PiecewiseInterpolation.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/PiecewiseInterpolation.h @@ -37,7 +37,7 @@ class PiecewiseInterpolation : public RooAbsReal { // virtual Double_t defaultErrorLevel() const ; - // void printMetaArgs(ostream& os) const ; + // void printMetaArgs(std::ostream& os) const ; const RooArgList& lowList() const { return _lowSet ; } const RooArgList& highList() const { return _highSet ; } @@ -74,7 +74,7 @@ class PiecewiseInterpolation : public RooAbsReal { RooArgList _funcIntList ; RooArgList _lowIntList ; RooArgList _highIntList ; - // will want vector<RooRealVar*> for low and high also + // will want std::vector<RooRealVar*> for low and high also } ; mutable RooObjCacheManager _normIntMgr ; // The integration cache manager diff --git a/roofit/histfactory/inc/RooStats/HistFactory/PreprocessFunction.h b/roofit/histfactory/inc/RooStats/HistFactory/PreprocessFunction.h index 6faa9c1facfe4..17f5c3e0bd4ed 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/PreprocessFunction.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/PreprocessFunction.h @@ -13,7 +13,13 @@ namespace HistFactory { PreprocessFunction(); + + PreprocessFunction(std::string Name, std::string Expression, std::string Dependents); + std::string GetCommand(std::string Name, std::string Expression, std::string Dependents); + + void Print(std::ostream& = std::cout); + void PrintXML(std::ostream& ); void SetName( const std::string& Name) { fName = Name; } std::string GetName() { return fName; } diff --git a/roofit/histfactory/inc/RooStats/HistFactory/RooBarlowBeestonLL.h b/roofit/histfactory/inc/RooStats/HistFactory/RooBarlowBeestonLL.h new file mode 100644 index 0000000000000..d789241a68356 --- /dev/null +++ b/roofit/histfactory/inc/RooStats/HistFactory/RooBarlowBeestonLL.h @@ -0,0 +1,136 @@ +// @(#)root/roostats:$Id$ +// Author: George Lewis, Kyle Cranmer +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOBARLOWBEESTONLL +#define ROOBARLOWBEESTONLL + +#include "RooAbsReal.h" +#include "RooRealProxy.h" +#include "RooSetProxy.h" +#include <map> +#include <set> +#include <string> + +class RooMinuit ; + +namespace RooStats{ + namespace HistFactory{ + +class RooBarlowBeestonLL : public RooAbsReal { +public: + + RooBarlowBeestonLL() ; + RooBarlowBeestonLL(const char *name, const char *title, RooAbsReal& nll /*, const RooArgSet& observables*/); + RooBarlowBeestonLL(const RooBarlowBeestonLL& other, const char* name=0) ; + virtual TObject* clone(const char* newname) const { return new RooBarlowBeestonLL(*this,newname); } + virtual ~RooBarlowBeestonLL() ; + + // A simple class to store the + // necessary objects for a + // single gamma in a single channel + class BarlowCache { + public: + BarlowCache() : hasStatUncert(false), gamma(NULL), + observables(NULL), bin_center(NULL), + tau(NULL), nom_pois_mean(NULL), + sumPdf(NULL), nData(-1) {} + bool hasStatUncert; + RooRealVar* gamma; + RooArgSet* observables; + RooArgSet* bin_center; // Snapshot + RooRealVar* tau; + RooAbsReal* nom_pois_mean; + RooAbsReal* sumPdf; + double nData; + double binVolume; + void SetBinCenter() const; + /* + // Restore original values and constant status of observables + TIterator* iter = obsSetOrig->createIterator() ; + RooRealVar* var ; + while((var=(RooRealVar*)iter->Next())) { + RooRealVar* target = (RooRealVar*) _obs.find(var->GetName()) ; + target->setVal(var->getVal()) ; + target->setConstant(var->isConstant()) ; + } + */ + + }; + + + void initializeBarlowCache(); + + RooArgSet* getParameters(const RooArgSet* depList, Bool_t stripDisconnected=kTRUE) const; + + // void setAlwaysStartFromMin(Bool_t flag) { _startFromMin = flag ; } + // Bool_t alwaysStartFromMin() const { return _startFromMin ; } + + //RooMinuit* minuit() { return _minuit ; } + RooAbsReal& nll() { return const_cast<RooAbsReal&>(_nll.arg()) ; } + // const RooArgSet& bestFitParams() const ; + // const RooArgSet& bestFitObs() const ; + + // virtual RooAbsReal* createProfile(const RooArgSet& paramsOfInterest) ; + + virtual Bool_t redirectServersHook(const RooAbsCollection& /*newServerList*/, Bool_t /*mustReplaceAll*/, Bool_t /*nameChange*/, Bool_t /*isRecursive*/) ; + + // void clearAbsMin() { _absMinValid = kFALSE ; } + + // Int_t numEval() const { return _neval ; } + + void setPdf(RooAbsPdf* pdf) { _pdf = pdf; } + void setDataset(RooAbsData* data) { _data = data; } + + //void FactorizePdf(const RooArgSet &observables, RooAbsPdf &pdf, + // RooArgList &obsTerms, RooArgList &constraints) const; + + +protected: + + // void validateAbsMin() const ; + + + RooRealProxy _nll ; // Input -log(L) function + /* + RooSetProxy _obs ; // Parameters of profile likelihood + RooSetProxy _par ; // Marginialized parameters of likelihood + */ + RooAbsPdf* _pdf; + RooAbsData* _data; + mutable std::map< std::string, std::vector< BarlowCache > > _barlowCache; + mutable std::set< std::string > _statUncertParams; + // Bool_t _startFromMin ; // Always start minimization for global minimum? + + /* + TIterator* _piter ; //! Iterator over profile likelihood parameters to be minimized + TIterator* _oiter ; //! Iterator of profile likelihood output parameter(s) + */ + + // mutable RooMinuit* _minuit ; //! Internal minuit instance + + // mutable Bool_t _absMinValid ; // flag if absmin is up-to-date + // mutable Double_t _absMin ; // absolute minimum of -log(L) + // mutable RooArgSet _paramAbsMin ; // Parameter values at absolute minimum + // mutable RooArgSet _obsAbsMin ; // Observable values at absolute minimum + mutable std::map<std::string,bool> _paramFixed ; // Parameter constant status at last time of use + // mutable Int_t _neval ; // Number evaluations used in last minimization + Double_t evaluate() const ; + //Double_t evaluate_bad() const ; + + +private: + + ClassDef(RooStats::HistFactory::RooBarlowBeestonLL,0) // Real-valued function representing a Barlow-Beeston minimized profile likelihood of external (likelihood) function +}; + + } +} + +#endif diff --git a/roofit/histfactory/inc/RooStats/HistFactory/Sample.h b/roofit/histfactory/inc/RooStats/HistFactory/Sample.h index b6912a324be8c..542f325c496ff 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/Sample.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/Sample.h @@ -1,17 +1,24 @@ +// @(#)root/roostats:$Id$ +// Author: George Lewis, Kyle Cranmer +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ #ifndef HISTFACTORY_SAMPLE_H #define HISTFACTORY_SAMPLE_H - #include <string> #include <fstream> #include <vector> #include <iostream> #include "TRef.h" +class TH1; #include "RooStats/HistFactory/Systematics.h" -//#include "RooStats/HistFactory/HistCollector.h" - namespace RooStats{ namespace HistFactory { @@ -20,21 +27,18 @@ class Sample { public: - //friend class Channel; - // - // Nominal definitions - // Sample(); Sample(std::string Name); Sample(std::string Name, std::string HistoName, std::string InputFile, std::string HistoPath=""); - + ~Sample(); void Print(std::ostream& = std::cout); - void PrintXML( ofstream& xml ); + void PrintXML( std::ofstream& xml ); void writeToFile( std::string FileName, std::string DirName ); TH1* GetHisto(); + // set histogram for this sample void SetHisto( TH1* histo ) { fhNominal = histo; fHistoName=histo->GetName(); } void SetValue( Double_t Val ); @@ -44,36 +48,54 @@ class Sample { void ActivateStatError( std::string HistoName, std::string InputFile, std::string HistoPath="" ); void AddOverallSys( std::string Name, Double_t Low, Double_t High ); + void AddOverallSys( const OverallSys& Sys ); + void AddNormFactor( std::string Name, Double_t Val, Double_t Low, Double_t High, bool Const=false ); + void AddNormFactor( const NormFactor& Factor ); void AddHistoSys( std::string Name, std::string HistoNameLow, std::string HistoFileLow, std::string HistoPathLow, std::string HistoNameHigh, std::string HistoFileHigh, std::string HistoPathHigh ); + void AddHistoSys( const HistoSys& Sys ); + void AddHistoFactor( std::string Name, std::string HistoNameLow, std::string HistoFileLow, std::string HistoPathLow, - std::string HistoNameHigh, std::string HistoFileHigh, std::string HistoPathHigh ); + std::string HistoNameHigh, std::string HistoFileHigh, std::string HistoPathHigh ); + void AddHistoFactor( const HistoFactor& Factor ); void AddShapeFactor( std::string Name ); - void AddShapeSys( std::string Name, Constraint::Type ConstraintType, std::string HistoName, std::string HistoFile, std::string HistoPath="" ); + void AddShapeFactor( const ShapeFactor& Factor ); + void AddShapeSys( std::string Name, Constraint::Type ConstraintType, std::string HistoName, std::string HistoFile, std::string HistoPath="" ); + void AddShapeSys( const ShapeSys& Sys ); + // defines whether the normalization scale with luminosity void SetNormalizeByTheory( bool norm ) { fNormalizeByTheory = norm; } + // does the normalization scale with luminosity bool GetNormalizeByTheory() { return fNormalizeByTheory; } - + // get name of sample std::string GetName() { return fName; } + // set name of sample void SetName(const std::string& Name) { fName = Name; } - + // get input ROOT file std::string GetInputFile() { return fInputFile; } + // set input ROOT file void SetInputFile(const std::string& InputFile) { fInputFile = InputFile; } + // get histogram name std::string GetHistoName() { return fHistoName; } + // set histogram name void SetHistoName(const std::string& HistoName) { fHistoName = HistoName; } + // get histogram path std::string GetHistoPath() { return fHistoPath; } + // set histogram path void SetHistoPath(const std::string& HistoPath) { fHistoPath = HistoPath; } + // get name of associated channel std::string GetChannelName() { return fChannelName; } + // set name of associated channel void SetChannelName(const std::string& ChannelName) { fChannelName = ChannelName; } @@ -124,6 +146,7 @@ class Sample { // The Nominal Shape TRef fhNominal; + TH1* fhCountingHist; }; diff --git a/roofit/histfactory/inc/RooStats/HistFactory/Systematics.h b/roofit/histfactory/inc/RooStats/HistFactory/Systematics.h index 15ac128f69217..1422832594602 100644 --- a/roofit/histfactory/inc/RooStats/HistFactory/Systematics.h +++ b/roofit/histfactory/inc/RooStats/HistFactory/Systematics.h @@ -1,8 +1,16 @@ +// @(#)root/roostats:$Id$ +// Author: George Lewis, Kyle Cranmer +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ #ifndef HISTFACTORY_SYSTEMATICS_H #define HISTFACTORY_SYSTEMATICS_H - #include <string> #include <fstream> #include <iostream> @@ -10,24 +18,33 @@ #include "TH1.h" #include "TRef.h" -//#include "RooStats/HistFactory/HistCollector.h" - namespace RooStats{ namespace HistFactory { - - namespace Constraint{ + namespace Constraint { enum Type{ Gaussian, Poisson }; std::string Name( Type type ); - Type GetType( std::string Name ); + Type GetType( const std::string& Name ); } + // Base class for common functions + /* + class Systematic { + + public: + + virtual void Print(std::ostream& = std::cout); + virtual void writeToFile(const std::string& FileName, + const std::string& Directory); + + + }; + */ class OverallSys { public: - //friend class Channel; void SetName( const std::string& Name ) { fName = Name; } std::string GetName() { return fName; } @@ -38,6 +55,7 @@ namespace HistFactory { double GetHigh() { return fHigh; } void Print(std::ostream& = std::cout); + void PrintXML(std::ostream&); protected: std::string fName; @@ -50,7 +68,6 @@ namespace HistFactory { class NormFactor { public: - //friend class Channel; NormFactor(); @@ -69,6 +86,7 @@ namespace HistFactory { double GetHigh() { return fHigh; } void Print(std::ostream& = std::cout); + void PrintXML(std::ostream&); protected: @@ -84,21 +102,19 @@ namespace HistFactory { class HistoSys { public: - //friend class Channel; - - - HistoSys() : fhLow(NULL), fhHigh(NULL ) {;} + HistoSys() : fhLow(NULL), fhHigh(NULL) {;} + HistoSys(const std::string& Name) : fName(Name), fhLow(NULL), fhHigh(NULL) {;} void Print(std::ostream& = std::cout); - void writeToFile( std::string FileName, std::string DirName ); + void PrintXML(std::ostream&); + void writeToFile( const std::string& FileName, const std::string& DirName ); void SetHistoLow( TH1* Low ) { fhLow = Low; } void SetHistoHigh( TH1* High ) { fhHigh = High; } TH1* GetHistoLow(); TH1* GetHistoHigh(); - void SetName( const std::string& Name ) { fName = Name; } std::string GetName() { return fName; } @@ -121,7 +137,6 @@ namespace HistFactory { std::string GetHistoPathLow() { return fHistoPathLow; } std::string GetHistoPathHigh() { return fHistoPathHigh; } - protected: std::string fName; @@ -144,13 +159,10 @@ namespace HistFactory { class HistoFactor { public: - //friend class Channel; - - void SetName( const std::string& Name ) { fName = Name; } std::string GetName() { return fName; } - + void SetInputFileLow( const std::string& InputFileLow ) { fInputFileLow = InputFileLow; } void SetInputFileHigh( const std::string& InputFileHigh ) { fInputFileHigh = InputFileHigh; } @@ -170,16 +182,14 @@ namespace HistFactory { std::string GetHistoPathHigh() { return fHistoPathHigh; } void Print(std::ostream& = std::cout); - void writeToFile( std::string FileName, std::string DirName ); - + void writeToFile( const std::string& FileName, const std::string& DirName ); + void PrintXML(std::ostream&); TH1* GetHistoLow(); TH1* GetHistoHigh(); void SetHistoLow( TH1* Low ) { fhLow = Low; } void SetHistoHigh( TH1* High ) { fhHigh = High; } - - protected: std::string fName; @@ -202,8 +212,6 @@ namespace HistFactory { class ShapeSys { public: - //friend class Channel; - void SetName( const std::string& Name ) { fName = Name; } std::string GetName() { return fName; } @@ -217,19 +225,16 @@ namespace HistFactory { void SetHistoPath( const std::string& HistoPath ) { fHistoPath = HistoPath; } std::string GetHistoPath() { return fHistoPath; } - void Print(std::ostream& = std::cout); - void writeToFile( std::string FileName, std::string DirName ); + void PrintXML(std::ostream&); + void writeToFile( const std::string& FileName, const std::string& DirName ); TH1* GetErrorHist(); void SetErrorHist(TH1* hError) { fhError = hError; } - - void SetConstraintType( Constraint::Type ConstrType ) { fConstraintType = ConstrType; } Constraint::Type GetConstraintType() { return fConstraintType; } - protected: std::string fName; @@ -247,29 +252,67 @@ namespace HistFactory { class ShapeFactor { public: - //friend class Channel; + ShapeFactor(); + void SetName( const std::string& Name ) { fName = Name; } std::string GetName() { return fName; } - void Print(std::ostream& = std::cout); + void PrintXML(std::ostream&); + void writeToFile( const std::string& FileName, const std::string& DirName); + + void SetInitialShape(TH1* shape) { fhInitialShape = shape; } + TH1* GetInitialShape() { return fhInitialShape; } + + void SetConstant(bool constant) { fConstant = constant; } + bool IsConstant() { return fConstant; } + + bool HasInitialShape() { return fHasInitialShape; } + + void SetInputFile( const std::string& InputFile ) { + fInputFile = InputFile; + fHasInitialShape=true; + } + std::string GetInputFile() { return fInputFile; } + + void SetHistoName( const std::string& HistoName ) { + fHistoName = HistoName; + fHasInitialShape=true; + } + std::string GetHistoName() { return fHistoName; } + + void SetHistoPath( const std::string& HistoPath ) { + fHistoPath = HistoPath; + fHasInitialShape=true; + } + std::string GetHistoPath() { return fHistoPath; } protected: std::string fName; + bool fConstant; + + // A histogram representing + // the initial shape + bool fHasInitialShape; + std::string fHistoName; + std::string fHistoPath; + std::string fInputFile; + TH1* fhInitialShape; + }; class StatError { public: - //friend class Channel; StatError() : fActivate(false), fUseHisto(false), fhError(NULL) {;} void Print(std::ostream& = std::cout); - void writeToFile( std::string FileName, std::string DirName ); + void PrintXML(std::ostream&); + void writeToFile( const std::string& FileName, const std::string& DirName ); void Activate( bool IsActive=true ) { fActivate = IsActive; } bool GetActivate() { return fActivate; } @@ -290,7 +333,6 @@ namespace HistFactory { TH1* GetErrorHist(); void SetErrorHist(TH1* Error) { fhError = Error; } - protected: bool fActivate; @@ -307,11 +349,10 @@ namespace HistFactory { class StatErrorConfig { public: - //friend class Channel; - StatErrorConfig() : fRelErrorThreshold( .05 ), fConstraintType( Constraint::Gaussian ) {;} void Print(std::ostream& = std::cout); + void PrintXML(std::ostream&); void SetRelErrorThreshold( double Threshold ) { fRelErrorThreshold = Threshold; } double GetRelErrorThreshold() { return fRelErrorThreshold; } @@ -319,7 +360,6 @@ namespace HistFactory { void SetConstraintType( Constraint::Type ConstrType ) { fConstraintType = ConstrType; } Constraint::Type GetConstraintType() { return fConstraintType; } - protected: double fRelErrorThreshold; diff --git a/roofit/histfactory/src/Asimov.cxx b/roofit/histfactory/src/Asimov.cxx new file mode 100644 index 0000000000000..874d66a421dd7 --- /dev/null +++ b/roofit/histfactory/src/Asimov.cxx @@ -0,0 +1,119 @@ +// @(#)root/roostats:$Id$ +// Author: Kyle Cranmer, George Lewis +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +//_________________________________________________ +/* +BEGIN_HTML +<p> +</p> +END_HTML +*/ +// + +#include "RooRealVar.h" +#include "RooStats/HistFactory/HistFactoryException.h" + +#include "RooStats/HistFactory/Asimov.h" + +void RooStats::HistFactory::Asimov::ConfigureWorkspace(RooWorkspace* wspace) { + + // Here is where we set the values, and constantness + // of all parameters in the workspace before creating + // an asimov dataset + + /* + // Okay, y'all, first we're going to create a snapshot + // of the current state of the variables in the workspace + + std::string ListOfVariableNames = ""; + for( std::map< std::string, double >::iterator itr = fParamValsToSet.begin(); + itr != fParamValsToSet.end(); ++itr) { + // Extend the Variable Name list + ListOfVariableNames += "," + itr->first; + } + for( std::map< std::string, bool >::iterator itr = fParamsToFix.begin(); + itr != fParamsToFix.end(); ++itr) { + // Extend the Variable Name list + ListOfVariableNames += "," + itr->first; + } + + // Save a snapshot + std::string SnapShotName = "NominalParamValues"; + wspace->saveSnapshot(SnapShotName.c_str(), ListOfVariableNames.c_str()); + */ + + // + // First we set all parameters to their given values + // + + + for( std::map< std::string, double >::iterator itr = fParamValsToSet.begin(); + itr != fParamValsToSet.end(); ++itr) { + + std::string param = itr->first; + double val = itr->second; + + // Try to get the variable in the workspace + RooRealVar* var = wspace->var(param.c_str()); + if( !var ) { + std::cout << "Error: Trying to set variable: " << var + << " to a specific value in creation of asimov dataset: " << fName + << " but this variable doesn't appear to exist in the workspace" + << std::endl; + throw hf_exc(); + } + + // Check that the desired value is in the range of the variable + double inRange = var->inRange(val, NULL); + if( !inRange ) { + std::cout << "Error: Attempting to set variable: " << var + << " to value: " << val << ", however it appears" + << " that this is not withn the variable's range: " + << "[" << var->getMin() << ", " << var->getMax() << "]" + << std::endl; + throw hf_exc(); + } + + // Set its value + std::cout << "Configuring Asimov Dataset: Setting " << param + << " = " << val << std::endl; + var->setVal( val ); + } + + + // + // Then, we set any variables to constant + // + + for( std::map< std::string, bool >::iterator itr = fParamsToFix.begin(); + itr != fParamsToFix.end(); ++itr) { + + std::string param = itr->first; + bool isConstant = itr->second; + + // Try to get the variable in the workspace + RooRealVar* var = wspace->var(param.c_str()); + if( !var ) { + std::cout << "Error: Trying to set variable: " << var + << " constant in creation of asimov dataset: " << fName + << " but this variable doesn't appear to exist in the workspace" + << std::endl; + throw hf_exc(); + } + + std::cout << "Configuring Asimov Dataset: Setting " << param + << " to constant " << std::endl; + var->setConstant( isConstant ); + + } + + return; + +} diff --git a/roofit/histfactory/src/Channel.cxx b/roofit/histfactory/src/Channel.cxx index f422582c3fd6b..4346566db573d 100644 --- a/roofit/histfactory/src/Channel.cxx +++ b/roofit/histfactory/src/Channel.cxx @@ -1,19 +1,50 @@ +// @(#)root/roostats:$Id$ +// Author: Kyle Cranmer, George Lewis +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +//_________________________________________________ +/* +BEGIN_HTML +<p> +This class encapsulates all information for the statistical interpretation of one experiment. +It can be combined with other channels (e.g. for the combination of multiple experiments, or +to constrain nuisance parameters with information obtained in a control region). +A channel contains one or more samples which describe the contribution from different processes +to this measurement. +</p> +END_HTML +*/ +// + -#include "stdlib.h" + +#include "RooStats/HistFactory/Channel.h" +#include <stdlib.h> #include "TFile.h" #include "TTimeStamp.h" #include "RooStats/HistFactory/HistFactoryException.h" -#include "RooStats/HistFactory/Channel.h" - +using namespace std; RooStats::HistFactory::Channel::Channel() : - fName( "" ) { ; } + fName( "" ) +{ + // standard constructor +} RooStats::HistFactory::Channel::Channel(std::string ChanName, std::string ChanInputFile) : - fName( ChanName ), fInputFile( ChanInputFile ) { ; } + fName( ChanName ), fInputFile( ChanInputFile ) +{ + // create channel with given name and input file +} namespace RooStats{ namespace HistFactory{ @@ -24,13 +55,16 @@ namespace RooStats{ } -void RooStats::HistFactory::Channel::AddSample( RooStats::HistFactory::Sample sample ) { +void RooStats::HistFactory::Channel::AddSample( RooStats::HistFactory::Sample sample ) +{ + // add fully configured sample to channel + sample.SetChannelName( GetName() ); fSamples.push_back( sample ); } void RooStats::HistFactory::Channel::Print( std::ostream& stream ) { - + // print information of channel to given stream stream << "\t Channel Name: " << fName << "\t InputFile: " << fInputFile @@ -62,7 +96,6 @@ void RooStats::HistFactory::Channel::Print( std::ostream& stream ) { void RooStats::HistFactory::Channel::PrintXML( std::string Directory, std::string Prefix ) { // Create an XML file for this channel - std::cout << "Printing XML Files for channel: " << GetName() << std::endl; std::string XMLName = Prefix + fName + ".xml"; @@ -70,19 +103,10 @@ void RooStats::HistFactory::Channel::PrintXML( std::string Directory, std::strin ofstream xml( XMLName.c_str() ); - // Add the time xml << "<!--" << std::endl; xml << "This xml file created automatically on: " << std::endl; -/* - time_t t = time(0); // get time now - struct tm * now = localtime( &t ); - xml << (now->tm_year + 1900) << '-' - << (now->tm_mon + 1) << '-' - << now->tm_mday - << std::endl; -*/ -// LM: use TTimeStamp since time_t does not work on Windows + // LM: use TTimeStamp since time_t does not work on Windows TTimeStamp t; UInt_t year = 0; UInt_t month = 0; @@ -92,9 +116,7 @@ void RooStats::HistFactory::Channel::PrintXML( std::string Directory, std::strin << month << '-' << day << std::endl; - xml << "-->" << std::endl; - // Add the DOCTYPE xml << "<!DOCTYPE Channel SYSTEM 'HistFactorySchema.dtd'> " << std::endl << std::endl; @@ -102,16 +124,20 @@ void RooStats::HistFactory::Channel::PrintXML( std::string Directory, std::strin // Add the Channel xml << " <Channel Name=\"" << fName << "\" InputFile=\"" << fInputFile << "\" >" << std::endl << std::endl; + fData.PrintXML( xml ); + /* xml << " <Data HistoName=\"" << fData.GetHistoName() << "\" " << "InputFile=\"" << fData.GetInputFile() << "\" " << "HistoPath=\"" << fData.GetHistoPath() << "\" " << " /> " << std::endl << std::endl; + */ - + fStatErrorConfig.PrintXML( xml ); + /* xml << " <StatErrorConfig RelErrorThreshold=\"" << fStatErrorConfig.GetRelErrorThreshold() << "\" " << "ConstraintType=\"" << Constraint::Name( fStatErrorConfig.GetConstraintType() ) << "\" " << "/> " << std::endl << std::endl; - + */ for( unsigned int i = 0; i < fSamples.size(); ++i ) { fSamples.at(i).PrintXML( xml ); @@ -119,20 +145,18 @@ void RooStats::HistFactory::Channel::PrintXML( std::string Directory, std::strin } xml << std::endl; - xml << " </Channel> " << std::endl; - xml.close(); std::cout << "Finished printing XML files" << std::endl; - - } void RooStats::HistFactory::Channel::SetData( std::string DataHistoName, std::string DataInputFile, std::string DataHistoPath ) { + // set data for this channel by specifying the name of the histogram, + // the external ROOT file and the path to the histogram inside the ROOT file fData.SetHistoName( DataHistoName ); fData.SetInputFile( DataInputFile ); @@ -142,7 +166,8 @@ void RooStats::HistFactory::Channel::SetData( std::string DataHistoName, std::st -void RooStats::HistFactory::Channel::SetData( TH1* hData ) { +void RooStats::HistFactory::Channel::SetData( TH1* hData ) { + // set data directly to some histogram fData.SetHisto( hData ); } @@ -189,10 +214,19 @@ void RooStats::HistFactory::Channel::CollectHistograms() { // Get the Data Histogram: - fData.SetHisto( GetHistogram(fData.GetInputFile(), - fData.GetHistoPath(), - fData.GetHistoName()) ); - + if( fData.GetInputFile() != "" ) { + fData.SetHisto( GetHistogram(fData.GetInputFile(), + fData.GetHistoPath(), + fData.GetHistoName()) ); + } + + // Collect any histograms for additional Datasets + for( unsigned int i=0; i < fAdditionalData.size(); ++i) { + RooStats::HistFactory::Data& data = fAdditionalData.at(i); + if( data.GetInputFile() != "" ) { + data.SetHisto( GetHistogram(data.GetInputFile(), data.GetHistoPath(),data.GetHistoName()) ); + } + } // Get the histograms for the samples: for( unsigned int sampItr = 0; sampItr < fSamples.size(); ++sampItr ) { @@ -210,9 +244,7 @@ void RooStats::HistFactory::Channel::CollectHistograms() { // Get the StatError Histogram (if necessary) - if( sample.GetStatError().GetUseHisto() ) { - sample.GetStatError().SetErrorHist( GetHistogram(sample.GetStatError().GetInputFile(), sample.GetStatError().GetHistoPath(), sample.GetStatError().GetHistoName()) ); @@ -259,6 +291,20 @@ void RooStats::HistFactory::Channel::CollectHistograms() { shapeSys.GetHistoName()) ); } // End Loop over ShapeSys + + // Get any initial shape for a ShapeFactor + for( unsigned int shapeFactorItr = 0; shapeFactorItr < sample.GetShapeFactorList().size(); ++shapeFactorItr ) { + + RooStats::HistFactory::ShapeFactor& shapeFactor = sample.GetShapeFactorList().at( shapeFactorItr ); + + // Check if we need an InitialShape + if( shapeFactor.HasInitialShape() ) { + TH1* hist = GetHistogram( shapeFactor.GetInputFile(), shapeFactor.GetHistoPath(), + shapeFactor.GetHistoName() ); + shapeFactor.SetInitialShape( hist ); + } + + } // End Loop over ShapeFactor } // End Loop over Samples @@ -274,9 +320,9 @@ bool RooStats::HistFactory::Channel::CheckHistograms() { try { - if( fData.GetHisto() == NULL ) { + if( fData.GetHisto() == NULL && fData.GetInputFile() != "" ) { std::cout << "Error: Data Histogram for channel " << GetName() << " is NULL." << std::endl; - throw bad_hf; + throw hf_exc(); } // Get the histograms for the samples: @@ -287,14 +333,38 @@ bool RooStats::HistFactory::Channel::CheckHistograms() { // Get the nominal histogram: if( sample.GetHisto() == NULL ) { std::cout << "Error: Nominal Histogram for sample " << sample.GetName() << " is NULL." << std::endl; - throw bad_hf; + throw hf_exc(); + } + else { + + // Check if any bins are negative + std::vector<int> NegativeBinNumber; + std::vector<double> NegativeBinContent; + TH1* histNominal = sample.GetHisto(); + for(int ibin=1; ibin<=histNominal->GetNbinsX(); ++ibin) { + if(histNominal->GetBinContent(ibin) < 0) { + NegativeBinNumber.push_back(ibin); + NegativeBinContent.push_back(histNominal->GetBinContent(ibin)); + } + } + if(NegativeBinNumber.size()>0) { + std::cout << "WARNING: Nominal Histogram " << histNominal->GetName() << " for Sample = " << sample.GetName() + << " in Channel = " << GetName() << " has negative entries in bin numbers = "; + + for(unsigned int ibin=0; ibin<NegativeBinNumber.size(); ++ibin) { + if(ibin>0) std::cout << " , " ; + std::cout << NegativeBinNumber[ibin] << " : " << NegativeBinContent[ibin] ; + } + std::cout << std::endl; + } + } // Get the StatError Histogram (if necessary) if( sample.GetStatError().GetUseHisto() ) { if( sample.GetStatError().GetErrorHist() == NULL ) { std::cout << "Error: Statistical Error Histogram for sample " << sample.GetName() << " is NULL." << std::endl; - throw bad_hf; + throw hf_exc(); } } @@ -307,12 +377,12 @@ bool RooStats::HistFactory::Channel::CheckHistograms() { if( histoSys.GetHistoLow() == NULL ) { std::cout << "Error: HistoSyst Low for Systematic " << histoSys.GetName() << " in sample " << sample.GetName() << " is NULL." << std::endl; - throw bad_hf; + throw hf_exc(); } if( histoSys.GetHistoHigh() == NULL ) { std::cout << "Error: HistoSyst High for Systematic " << histoSys.GetName() << " in sample " << sample.GetName() << " is NULL." << std::endl; - throw bad_hf; + throw hf_exc(); } } // End Loop over HistoSys @@ -326,12 +396,12 @@ bool RooStats::HistFactory::Channel::CheckHistograms() { if( histoFactor.GetHistoLow() == NULL ) { std::cout << "Error: HistoSyst Low for Systematic " << histoFactor.GetName() << " in sample " << sample.GetName() << " is NULL." << std::endl; - throw bad_hf; + throw hf_exc(); } if( histoFactor.GetHistoHigh() == NULL ) { std::cout << "Error: HistoSyst High for Systematic " << histoFactor.GetName() << " in sample " << sample.GetName() << " is NULL." << std::endl; - throw bad_hf; + throw hf_exc(); } } // End Loop over HistoFactor @@ -345,7 +415,7 @@ bool RooStats::HistFactory::Channel::CheckHistograms() { if( shapeSys.GetErrorHist() == NULL ) { std::cout << "Error: HistoSyst High for Systematic " << shapeSys.GetName() << " in sample " << sample.GetName() << " is NULL." << std::endl; - throw bad_hf; + throw hf_exc(); } } // End Loop over ShapeSys @@ -353,7 +423,7 @@ bool RooStats::HistFactory::Channel::CheckHistograms() { } // End Loop over Samples } - catch(exception& e) + catch(std::exception& e) { std::cout << e.what() << std::endl; return false; @@ -382,7 +452,7 @@ TH1* RooStats::HistFactory::Channel::GetHistogram(std::string InputFile, std::st TFile* inFile = TFile::Open( InputFile.c_str() ); if( !inFile ) { std::cout << "Error: Unable to open input file: " << InputFile << std::endl; - throw bad_hf; + throw hf_exc(); } std::cout << "Opened input file: " << InputFile << ": " << inFile << std::endl; @@ -401,16 +471,16 @@ TH1* RooStats::HistFactory::Channel::GetHistogram(std::string InputFile, std::st try{ hist = dynamic_cast<TH1*>( inFile->Get( HistNameFull.c_str() ) ); } - catch(exception& e) + catch(std::exception& e) { std::cout << "Failed to cast object to TH1*" << std::endl; std::cout << e.what() << std::endl; - throw bad_hf; + throw hf_exc(); } if( !hist ) { std::cout << "Failed to get histogram: " << HistNameFull << " in file: " << InputFile << std::endl; - throw bad_hf; + throw hf_exc(); } @@ -421,7 +491,7 @@ TH1* RooStats::HistFactory::Channel::GetHistogram(std::string InputFile, std::st std::cerr << "filename: " << InputFile << "path: " << HistoPath << "obj: " << HistoName << std::endl; - throw bad_hf; + throw hf_exc(); } else { ptr->SetDirectory(0); // for the current histogram h diff --git a/roofit/histfactory/src/ConfigParser.cxx b/roofit/histfactory/src/ConfigParser.cxx index 73302fcbb4c44..f41a8b3f09177 100644 --- a/roofit/histfactory/src/ConfigParser.cxx +++ b/roofit/histfactory/src/ConfigParser.cxx @@ -29,7 +29,7 @@ using namespace RooStats; using namespace HistFactory; - +using namespace std; std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsFromXML( string input ) { @@ -51,6 +51,7 @@ std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsF if( parseError ) { std::cerr << "Loading of xml document \"" << input << "\" failed" << std::endl; + throw hf_exc(); } @@ -63,7 +64,7 @@ std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsF // Check that it is the proper DOCTYPE if( rootNode->GetNodeName() != TString( "Combination" ) ){ std::cout << "Error: Driver DOCTYPE not equal to 'Combination'" << std::endl; - throw bad_hf; + throw hf_exc(); } // Loop over the Combination's attributes @@ -79,7 +80,7 @@ std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsF if( attrName == TString( "" ) ) { std::cout << " Error: Attribute for 'Combination' with no name found" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( attrName == TString( "OutputFilePrefix" ) ) { @@ -96,7 +97,7 @@ std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsF else { std::cout << " Error: Unknown attribute for 'Combination' encountered: " << attrName << std::endl; - throw bad_hf; + throw hf_exc(); } // node = node->GetNextNode(); @@ -112,6 +113,11 @@ std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsF node = rootNode->GetChildren(); while( node != 0 ) { if( node->GetNodeName() == TString( "Input" ) ) { + if( node->GetText() == NULL ) { + std::cout << "Error: node: " << node->GetName() + << " has no text." << std::endl; + throw hf_exc(); + } xml_channel_files.push_back(node->GetText()); } node = node->GetNextNode(); @@ -120,8 +126,8 @@ std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsF // If no channel xml files are found, exit if(xml_channel_files.empty()){ cerr << "no input channels found" << endl; - throw bad_hf; - return measurement_list; + throw hf_exc(); + //return measurement_list; } else { std::cout << "Found Channels: "; @@ -130,11 +136,14 @@ std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsF } // Get the list of functions - // These apply to all measurements + // These apply to all measurements, so we + // first create the list of preprocess functions + // (before we create the list of measurements) + // and then we add them to all measurements // For now, we create this list twice // simply for compatability - std::vector< std::string > preprocessFunctions; + // std::vector< std::string > preprocessFunctions; std::vector< RooStats::HistFactory::PreprocessFunction > functionObjects; node = rootNode->GetChildren(); @@ -144,7 +153,7 @@ std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsF // For now, add both the objects itself and // it's command string (for easy compatability) RooStats::HistFactory::PreprocessFunction Func = ParseFunctionConfig( node ); - preprocessFunctions.push_back( Func.GetCommand() ); + // preprocessFunctions.push_back( Func.GetCommand() ); functionObjects.push_back( Func ); } node = node->GetNextNode(); @@ -159,7 +168,7 @@ std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsF if( node->GetNodeName() == TString( "" ) ) { std::cout << "Error: Node found in Measurement Driver XML with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( node->GetNodeName() == TString( "Measurement" ) ) { @@ -184,18 +193,17 @@ std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsF else { std::cout << "Error: Unknown node found in Measurement Driver XML: " << node->GetNodeName() << std::endl; - throw bad_hf; + throw hf_exc(); } node = node->GetNextNode(); - } std::cout << "Done Processing Measurements" << std::endl; if( measurement_list.size() == 0 ) { std::cout << "Error: No Measurements found in XML Driver File" << std::endl; - throw bad_hf; + throw hf_exc(); } else { std::cout << "Found Measurements: "; @@ -203,17 +211,15 @@ std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsF std::cout << std::endl; } - // Add the preprocessed functions to each measurement - for( unsigned int i = 0; i < measurement_list.size(); ++i) { - measurement_list.at(i).SetPreprocessFunctions( preprocessFunctions ); - } + // for( unsigned int i = 0; i < measurement_list.size(); ++i) { + // measurement_list.at(i).SetPreprocessFunctions( preprocessFunctions ); + // } // Add the preprocessed functions to each measurement for( unsigned int i = 0; i < measurement_list.size(); ++i) { measurement_list.at(i).SetFunctionObjects( functionObjects ); } - // Create an instance of the class // that collects histograms //HistCollector collector; @@ -243,364 +249,19 @@ std::vector< RooStats::HistFactory::Measurement > ConfigParser::GetMeasurementsF for( unsigned int j = 0; j < channel_list.size(); ++j ) { measurement.GetChannels().push_back( channel_list.at(j) ); } - } - - } - catch(exception& e) + catch(std::exception& e) { std::cout << e.what() << std::endl; - throw bad_hf; + throw hf_exc(); } - - return measurement_list; - } -// DEPRECATED: -/* -void ConfigParser::FillMeasurementsAndChannelsFromXML(string input, - std::vector< RooStats::HistFactory::Measurement >& measurement_list, - std::vector< RooStats::HistFactory::Channel >& channel_list ) { - - - // Open an input "Driver" XML file (input), - // Parse that file and its channel files - // and fill the input vectors with the lists of - // measurements and channels - - - // Open the Driver XML File - TDOMParser xmlparser; - Int_t parseError = xmlparser.ParseFile( input.c_str() ); - if( parseError ) { - std::cerr << "Loading of xml document \"" << input - << "\" failed" << std::endl; - } - - - // Read the Driver XML File - cout << "reading input : " << input << endl; - TXMLDocument* xmldoc = xmlparser.GetXMLDocument(); - TXMLNode* rootNode = xmldoc->GetRootNode(); - - - // Check that it is the proper DOCTYPE - if( rootNode->GetNodeName() != TString( "Combination" ) ){ - std::cout << "Error: Driver DOCTYPE not equal to 'Combination'" << std::endl; - throw bad_hf; - } - - // Loop over the Combination's attributes - std::string OutputFilePrefix; - - TListIter attribIt = rootNode->GetAttributes(); - TXMLAttr* curAttr = 0; - while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { - - // Get the Name, Val of this node - TString attrName = curAttr->GetName(); - std::string attrVal = curAttr->GetValue(); - - if( attrName == TString( "" ) ) { - std::cout << " Error: Attribute for 'Combination' with no name found" << std::endl; - throw bad_hf; - } - - else if( attrName == TString( "OutputFilePrefix" ) ) { - OutputFilePrefix = string(curAttr->GetValue()); - std::cout << "output file prefix is : " << OutputFilePrefix << endl; - } - - / * - else if( attrName == TString( "InputFile" ) ) { - channel.InputFile = attrVal ; - } - * / - - else { - std::cout << " Error: Unknown attribute for 'Combination' encountered: " - << attrName << std::endl; - throw bad_hf; - } - - // node = node->GetNextNode(); - - } - - TXMLNode* node = NULL; - - // Get the list of channel XML files to combine - // Do this first so we can quickly exit - // if no channels are found - std::vector< std::string > xml_channel_files; - node = rootNode->GetChildren(); - while( node != 0 ) { - if( node->GetNodeName() == TString( "Input" ) ) { - xml_channel_files.push_back(node->GetText()); - } - node = node->GetNextNode(); - } - - // If no channel xml files are found, exit - if(xml_channel_files.empty()){ - cerr << "no input channels found" << endl; - exit(1); - } - else { - std::cout << "Found Channels: "; - for( unsigned int i=0; i < xml_channel_files.size(); ++i ) std::cout << " " << xml_channel_files.at(i); - std::cout << std::endl; - } - - // Get the list of functions - // These apply to all measurements - std::vector< std::string > preprocessFunctions; - node = rootNode->GetChildren(); - while( node != 0 ) { - if( node->GetNodeName() == TString( "Function" ) ) { - preprocessFunctions.push_back( ParseFunctionConfig( node ) ); - } - node = node->GetNextNode(); - } - - std::cout << std::endl; - - // Fill the list of measurements - //std::vector< HistFactory::Measurement > measurement_list; - node = rootNode->GetChildren(); - while( node != 0 ) { - - if( node->GetNodeName() == TString( "" ) ) { - std::cout << "Error: Node found in Measurement Driver XML with no name" << std::endl; - throw bad_hf; - } - - else if( node->GetNodeName() == TString( "Measurement" ) ) { - HistFactory::Measurement measurement = CreateMeasurementFromDriverNode( node ); - // Set the prefix (obtained above) - measurement.OutputFilePrefix = OutputFilePrefix; - measurement_list.push_back( measurement ); - } - - else if( node->GetNodeName() == TString( "Function" ) ) { - // Already processed these (directly above) - ; - } - - else if( node->GetNodeName() == TString( "Input" ) ) { - // Already processed these (directly above) - ; - } - - else if( IsAcceptableNode( node ) ) { ; } - - else { - std::cout << "Error: Unknown node found in Measurement Driver XML: " - << node->GetNodeName() << std::endl; - throw bad_hf; - } - - node = node->GetNextNode(); - - } - - std::cout << "Done Processing Measurements" << std::endl; - - if( measurement_list.size() == 0 ) { - std::cout << "Error: No Measurements found in XML Driver File" << std::endl; - throw bad_hf; - } - else { - std::cout << "Found Measurements: "; - for( unsigned int i=0; i < measurement_list.size(); ++i ) std::cout << " " << measurement_list.at(i).GetName(); - std::cout << std::endl; - } - - - // Add the preprocessed functions to each measurement - for( unsigned int i = 0; i < measurement_list.size(); ++i) { - measurement_list.at(i).preprocessFunctions = preprocessFunctions; - } - - // Create an instance of the class - // that collects histograms - HistCollector collector; - - // Fill the list of channels - // std::vector< HistFactory::Channel > channel_list; - for( unsigned int i = 0; i < xml_channel_files.size(); ++i ) { - std::string channel_xml = xml_channel_files.at(i); - std::cout << "Parsing Channel: " << channel_xml << std::endl; - HistFactory::Channel channel = ParseChannelXMLFile( channel_xml ); - - // Get the histograms for the channel - collector.CollectHistograms( channel ); - - channel_list.push_back( channel ); - } - - // Finally, add the channels to the measurements: - for( unsigned int i = 0; i < measurement_list.size(); ++i) { - - HistFactory::Measurement& measurement = measurement_list.at(i); - - for( unsigned int j = 0; j < channel_list.size(); ++j ) { - measurement.channels.push_back( channel_list.at(j) ); - } - - } - -} -*/ - - // At this point, we have fully processed - // the XML. Thus, we are done. - - // Remember, the vectors: - // - measurement_list - // - channel_list - // are filled by reference from this - // function's argument list - // Cheers. - - - // --------------------------------------------------------------- // - // --------------------------------------------------------------- // - - /* - // At this point, we have all the information we need - // from the xml files. - - // We will make the measurements 1-by-1 - // This part will be migrated to the - // MakeModelAndMeasurements function, - // but is here for now. - - for(unsigned int i = 0; i < measurement_list.size(); ++i) { - - HistFactory::Measurement measurement = measurement_list.at(i); - - // Add the channels to this measurement - for( unsigned int chanItr = 0; chanItr < channel_list.size(); ++chanItr ) { - measurement.channels.push_back( channel_list.at( chanItr ) ); - } - - - // Create the workspaces for the channels - vector<RooWorkspace*> channel_workspaces; - vector<string> channel_names; - TFile* outFile = new TFile(outputFileName.c_str(), "recreate"); - HistoToWorkspaceFactory factory(outputFileNamePrefix, rowTitle, systToFix, nominalLumi, lumiError, lowBin, highBin , outFile); - - - // Loop over channels and make the individual - // channel fits: - - - // read the xml for each channel and combine - - for( unsigned int chanItr = 0; chanItr < channel_list.size(); ++chanItr ) { - - HistFactory::Channel channel = channel_list.at( chanItr ); - - string ch_name=channel.Name; - channel_names.push_back(ch_name); - - RooWorkspace* ws = factory.MakeSingleChannelModel( channel ); - channel_workspaces.push_back(ws); - - // set poi in ModelConfig - ModelConfig* proto_config = (ModelConfig *) ws->obj("ModelConfig"); - - std::cout << "Setting Parameter of Interest as :" << measurement.POI << endl; - RooRealVar* poi = (RooRealVar*) ws->var( (measurement.POI).c_str() ); - RooArgSet * params= new RooArgSet; - if(poi){ - params->add(*poi); - } - proto_config->SetParametersOfInterest(*params); - - - // Gamma/Uniform Constraints: - // turn some Gaussian constraints into Gamma/Uniform/LogNorm constraints, rename model newSimPdf - if( measurement.gammaSyst.size()>0 || measurement.uniformSyst.size()>0 || measurement.logNormSyst.size()>0) { - factory.EditSyst( ws, ("model_"+ch_name).c_str(), gammaSyst, uniformSyst, logNormSyst); - proto_config->SetPdf( *ws->pdf("newSimPdf") ); - } - - // fill out ModelConfig and export - RooAbsData* expData = ws->data("expData"); - if(poi){ - proto_config->GuessObsAndNuisance(*expData); - } - ws->writeToFile( (outputFileNamePrefix+"_"+ch_name+"_"+rowTitle+"_model.root").c_str() ); - - // do fit unless exportOnly requested - if(!exportOnly){ - if(!poi){ - cout <<"can't do fit for this channel, no parameter of interest"<<endl; - } else{ - factory.FitModel(ws, ch_name, "newSimPdf", "expData", false); - } - } - fprintf(factory.pFile, " & " ); - } - - - // Now, combine the channels - RooWorkspace* ws=factory.MakeCombinedModel(channel_names, channel_workspaces); - // Gamma/Uniform Constraints: - // turn some Gaussian constraints into Gamma/Uniform/logNormal constraints, rename model newSimPdf - if(gammaSyst.size()>0 || uniformSyst.size()>0 || logNormSyst.size()>0) - factory.EditSyst(ws, "simPdf", gammaSyst, uniformSyst, logNormSyst); - // - // set parameter of interest according to the configuration - // - ModelConfig * combined_config = (ModelConfig *) ws->obj("ModelConfig"); - cout << "Setting Parameter of Interest as :" << measurement.POI << endl; - RooRealVar* poi = (RooRealVar*) ws->var( (measurement.POI).c_str() ); - //RooRealVar* poi = (RooRealVar*) ws->var((POI+"_comb").c_str()); - RooArgSet * params= new RooArgSet; - cout << poi << endl; - if(poi){ - params->add(*poi); - } - combined_config->SetParametersOfInterest(*params); - ws->Print(); - - // Set new PDF if there are gamma/uniform constraint terms - if(gammaSyst.size()>0 || uniformSyst.size()>0 || logNormSyst.size()>0) - combined_config->SetPdf(*ws->pdf("newSimPdf")); - - RooAbsData* simData = ws->data("simData"); - combined_config->GuessObsAndNuisance(*simData); - // ws->writeToFile(("results/model_combined_edited.root").c_str()); - ws->writeToFile( (outputFileNamePrefix+"_combined_"+rowTitle+"_model.root").c_str() ); - - // TO DO: - // Totally factorize the statistical test in "fit Model" to a different area - if(!exportOnly){ - if(!poi){ - cout <<"can't do fit for this channel, no parameter of interest"<<endl; - } else{ - factory.FitModel(ws, "combined", "simPdf", "simData", false); - } - } - - - } // End Loop over measurement_list - - // Done - */ - - - HistFactory::Measurement ConfigParser::CreateMeasurementFromDriverNode( TXMLNode* node ) { @@ -623,7 +284,7 @@ HistFactory::Measurement ConfigParser::CreateMeasurementFromDriverNode( TXMLNode if( curAttr->GetName() == TString( "" ) ) { std::cout << "Found XML attribute in Measurement with no name" << std::endl; // ADD Output Here - throw bad_hf; + throw hf_exc(); } else if( curAttr->GetName() == TString( "Name" ) ) { //rowTitle=curAttr->GetValue(); @@ -652,37 +313,123 @@ HistFactory::Measurement ConfigParser::CreateMeasurementFromDriverNode( TXMLNode else { std::cout << "Found unknown XML attribute in Measurement: " << curAttr->GetName() << std::endl; - throw bad_hf; + throw hf_exc(); } } // End Loop over attributes - // Then, get the properties of the children nodes TXMLNode* child = node->GetChildren(); while( child != 0 ) { if( child->GetNodeName() == TString( "" ) ) { std::cout << "Found XML child node of Measurement with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( child->GetNodeName() == TString( "POI" ) ) { - measurement.SetPOI( child->GetText() ); + if( child->GetText() == NULL ) { + std::cout << "Error: node: " << child->GetName() + << " has no text." << std::endl; + throw hf_exc(); + } + //poi// measurement.SetPOI( child->GetText() ); + AddSubStrings( measurement.GetPOIList(), child->GetText() ); } else if( child->GetNodeName() == TString( "ParamSetting" ) ) { TListIter paramIt = child->GetAttributes(); TXMLAttr* curParam = 0; while( ( curParam = dynamic_cast< TXMLAttr* >( paramIt() ) ) != 0 ) { - if( curParam->GetName() == TString( "Const" ) ) { + + if( curParam->GetName() == TString( "" ) ) { + std::cout << "Error: Found tag attribute with no name in ParamSetting" << std::endl; + throw hf_exc(); + } + else if( curParam->GetName() == TString( "Const" ) ) { if(curParam->GetValue()==TString("True")){ // Fix here...? + if( child->GetText() == NULL ) { + std::cout << "Error: node: " << child->GetName() + << " has no text." << std::endl; + throw hf_exc(); + } AddSubStrings( measurement.GetConstantParams(), child->GetText() ); } } + else if( curParam->GetName() == TString( "Val" ) ) { + double val = atof(curParam->GetValue()); + if( child->GetText() == NULL ) { + std::cout << "Error: node: " << child->GetName() + << " has no text." << std::endl; + throw hf_exc(); + } + std::vector<std::string> child_nodes = GetChildrenFromString(child->GetText()); + for(unsigned int i = 0; i < child_nodes.size(); ++i) { + measurement.SetParamValue( child_nodes.at(i), val); + } + // AddStringValPairToMap( measurement.GetParamValues(), val, child->GetText() ); + } + else { + std::cout << "Found tag attribute with unknown name in ParamSetting: " + << curAttr->GetName() << std::endl; + throw hf_exc(); + } + } + } + + else if( child->GetNodeName() == TString( "Asimov" ) ) { + + //std::string name; + //std::map<string, double> fixedParams; + + // Now, create and configure an asimov object + // and add it to the measurement + RooStats::HistFactory::Asimov asimov; + std::string ParamFixString; + + // Loop over attributes + attribIt = child->GetAttributes(); + curAttr = 0; + while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { + + if( curAttr->GetName() == TString( "" ) ) { + std::cout << "Error: Found tag attribute with no name in ConstraintTerm" << std::endl; + throw hf_exc(); + } + + else if( curAttr->GetName() == TString( "Name" ) ) { + std::string name = curAttr->GetValue(); + asimov.SetName( name ); + } + + else if( curAttr->GetName() == TString( "FixParams" ) ) { + ParamFixString = curAttr->GetValue(); + //std::map<std::string, double> fixedParams = ExtractParamMapFromString(FixParamList); + //asimov.GetFixedParams() = fixedParams; + } + + else { + std::cout << "Found tag attribute with unknown name in ConstraintTerm: " + << curAttr->GetName() << std::endl; + throw hf_exc(); + } + } + + // Add any parameters to the asimov dataset + // to be fixed during the fitting and dataset generation + if( ParamFixString=="" ) { + std::cout << "Warning: Asimov Dataset with name: " << asimov.GetName() + << " added, but no parameters are set to be fixed" << std::endl; + } + else { + AddParamsToAsimov( asimov, ParamFixString ); + } + + measurement.AddAsimovDataset( asimov ); + } else if( child->GetNodeName() == TString( "ConstraintTerm" ) ) { @@ -695,6 +442,11 @@ HistFactory::Measurement ConfigParser::CreateMeasurementFromDriverNode( TXMLNode map<string,double> logNormSyst; // Get the list of parameters in this tag: + if( child->GetText() == NULL ) { + std::cout << "Error: node: " << child->GetName() + << " has no text." << std::endl; + throw hf_exc(); + } AddSubStrings(syst, child->GetText()); // Now, loop over this tag's attributes @@ -704,7 +456,7 @@ HistFactory::Measurement ConfigParser::CreateMeasurementFromDriverNode( TXMLNode if( curAttr->GetName() == TString( "" ) ) { std::cout << "Error: Found tag attribute with no name in ConstraintTerm" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( curAttr->GetName() == TString( "Type" ) ) { @@ -718,7 +470,7 @@ HistFactory::Measurement ConfigParser::CreateMeasurementFromDriverNode( TXMLNode else { std::cout << "Found tag attribute with unknown name in ConstraintTerm: " << curAttr->GetName() << std::endl; - throw bad_hf; + throw hf_exc(); } } // End Loop over tag attributes @@ -730,10 +482,9 @@ HistFactory::Measurement ConfigParser::CreateMeasurementFromDriverNode( TXMLNode if( ! (type=="Gamma" || type=="Uniform" || type=="LogNormal" || type=="NoConstraint") ) { std::cout << "Error: Encountered unknown type for ConstraintTerm: " << type << std::endl; - throw bad_hf; + throw hf_exc(); } - if (type=="Gamma" && rel!=0) { for (vector<string>::const_iterator it=syst.begin(); it!=syst.end(); it++) { // Fix Here...? @@ -761,7 +512,6 @@ HistFactory::Measurement ConfigParser::CreateMeasurementFromDriverNode( TXMLNode measurement.GetNoSyst()[(*it).c_str()] = 1.0; // MB : dummy value } } - } // End adding of Constraint terms @@ -770,11 +520,10 @@ HistFactory::Measurement ConfigParser::CreateMeasurementFromDriverNode( TXMLNode else { std::cout << "Found XML child of Measurement with unknown name: " << child->GetNodeName() << std::endl; - throw bad_hf; + throw hf_exc(); } child = child->GetNextNode(); - } measurement.PrintTree(); @@ -786,81 +535,6 @@ HistFactory::Measurement ConfigParser::CreateMeasurementFromDriverNode( TXMLNode - - -// Deprecated -/* -HistFactory::Channel ConfigParser::ReadXmlConfig( string filen, Double_t lumi ) { - - - - // Open an xml file, - // parse it, and return - // a list of channels - - - TString lumiStr; - lumiStr+=lumi; - lumiStr.ReplaceAll(' ', TString()); - - std::cout << "Parsing file: " << filen ; - - TDOMParser xmlparser; - string channelName; - string inputFileName; - string histoName; - string histoPathName; - - // reading in the file and parse by DOM - Int_t parseError = xmlparser.ParseFile( filen.c_str() ); - if( parseError ) { - std::cout << "Loading of xml document \"" << filen - << "\" failed" << std::endl; - } - - - HistFactory::Measurement measurement; - - TXMLDocument* xmldoc = xmlparser.GetXMLDocument(); - TXMLNode* rootNode = xmldoc->GetRootNode(); - - // not assuming that combination is the only option - // single channel is also ok - - if( rootNode->GetNodeName() == TString( "" ) ){ - - std::cout << "Error: Encounterd XML with no DOCTYPE" << std::endl; - throw bad_hf; - - } - - - else if( rootNode->GetNodeName() == TString( "Channel" ) ){ - - HistFactory::Channel channel = ParseChannelXMLFile( rootNode ); - measurement.channels.push_back( channel ); - - } - - else if( rootNode->GetNodeName() == TString( "Combination" ) ){ - - ConfigureMeasurementFromDriverXML( measurement ); - - std::cout << "Stuff" << std::endl; - - } - // above two are the only options - else { - std::cout << "Found XML file with unknown DOCTYPE: " << rootNode->GetNodeName() - << std::endl; - throw bad_hf; - } - - -} -*/ - - HistFactory::Channel ConfigParser::ParseChannelXMLFile( string filen ) { /* @@ -878,9 +552,9 @@ HistFactory::Channel ConfigParser::ParseChannelXMLFile( string filen ) { if( parseError ) { std::cout << "Loading of xml document \"" << filen << "\" failed" << std::endl; + throw hf_exc(); } - TXMLDocument* xmldoc = xmlparser.GetXMLDocument(); TXMLNode* rootNode = xmldoc->GetRootNode(); @@ -892,7 +566,7 @@ HistFactory::Channel ConfigParser::ParseChannelXMLFile( string filen ) { << std::endl; std::cout << " DOCTYPE for channels must be 'Channel' " << " Check that your XML is properly written" << std::endl; - throw bad_hf; + throw hf_exc(); } // Now, create the channel, @@ -902,7 +576,9 @@ HistFactory::Channel ConfigParser::ParseChannelXMLFile( string filen ) { HistFactory::Channel channel; // Set the default values: - + channel.SetInputFile( "" ); + channel.SetHistoPath( "" ); + // Walk through the root node and // get its attributes TListIter attribIt = rootNode->GetAttributes(); @@ -915,7 +591,7 @@ HistFactory::Channel ConfigParser::ParseChannelXMLFile( string filen ) { if( attrName == TString( "" ) ) { std::cout << " Error: Attribute for 'Channel' with no name found" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( attrName == TString( "Name" ) ) { @@ -927,14 +603,14 @@ HistFactory::Channel ConfigParser::ParseChannelXMLFile( string filen ) { std::cout << "Setting InputFile for this channel: " << attrVal << std::endl; channel.SetInputFile( attrVal ); // Set the current (cached) value - m_currentInputFile = attrVal; + m_currentInputFile = attrVal; } else if( curAttr->GetName() == TString( "HistoPath" ) ) { std::cout << "Setting HistoPath for this channel: " << attrVal << std::endl; // Set the current (cached) value channel.SetHistoPath( attrVal ); - m_currentHistoPath = attrVal; + m_currentHistoPath = attrVal; } else if( curAttr->GetName() == TString( "HistoName" ) ) { @@ -946,18 +622,16 @@ HistFactory::Channel ConfigParser::ParseChannelXMLFile( string filen ) { else { std::cout << " Error: Unknown attribute for 'Channel' encountered: " << attrName << std::endl; - throw bad_hf; + throw hf_exc(); } - } // End loop over the channel tag's attributes - // Check that the channel was properly initiated: if( channel.GetName() == "" ) { std::cout << "Error: Channel created with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } m_currentChannel = channel.GetName(); @@ -967,15 +641,34 @@ HistFactory::Channel ConfigParser::ParseChannelXMLFile( string filen ) { TXMLNode* node = rootNode->GetChildren(); + bool firstData=true; + while( node != 0 ) { + // Restore the Channel-Wide Defaults + m_currentInputFile = channel.GetInputFile(); + m_currentHistoPath = channel.GetHistoPath(); + if( node->GetNodeName() == TString( "" ) ) { std::cout << "Error: Encountered node in Channel with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( node->GetNodeName() == TString( "Data" ) ) { - channel.SetData( CreateDataElement(node) ); + if( firstData ) { + RooStats::HistFactory::Data data = CreateDataElement(node); + if( data.GetName() != "" ) { + std::cout << "Error: You can only rename the datasets of additional data sets. " + << " Remove the 'Name=" << data.GetName() << "' tag" + << " from channel: " << channel.GetName() << std::endl; + throw hf_exc(); + } + channel.SetData( data ); + firstData=false; + } + else { + channel.AddAdditionalData( CreateDataElement(node) ); + } } else if( node->GetNodeName() == TString( "StatErrorConfig" ) ) { @@ -990,14 +683,13 @@ HistFactory::Channel ConfigParser::ParseChannelXMLFile( string filen ) { else { std::cout << "Error: Encountered node in Channel with unknown name: " << node->GetNodeName() << std::endl; - throw bad_hf; + throw hf_exc(); } node = node->GetNextNode(); } // End loop over tags in this channel - std::cout << "Created Channel: " << std::endl; channel.Print(); @@ -1007,298 +699,6 @@ HistFactory::Channel ConfigParser::ParseChannelXMLFile( string filen ) { - - /* - - // Setup default values: - EstimateSummary::ConstraintType StatConstraintType = EstimateSummary::Gaussian; //"Gaussian"; - Double_t RelErrorThreshold = .05; - node = rootNode->GetChildren(); - while( node != 0 ) { - if( node->GetNodeName() == TString( "StatErrorConfig" ) ) { - - // Loop over the node's attributes - attribIt = node->GetAttributes(); - curAttr = 0; - while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { - - if( curAttr->GetName() == TString( "RelErrorThreshold" ) ) { - RelErrorThreshold = atof(curAttr->GetValue()) ; - } - - if( curAttr->GetName() == TString( "ConstraintType" ) ) { - // Allowable Values: Gaussian - if( curAttr->GetValue()==TString("Gaussian") || curAttr->GetValue()==TString("Gauss") ) StatConstraintType = EstimateSummary::Gaussian; - else if( curAttr->GetValue()==TString("Poisson") || curAttr->GetValue()==TString("Pois") ) StatConstraintType = EstimateSummary::Poisson; - else cout << "Invalid Stat Constraint Type: " << curAttr->GetValue() << endl; - } - } // End: Loop Over Attributes - - } // End: Loop Over Nodes - node = node->GetNextNode(); - } - - - node = rootNode->GetChildren(); - while( node != 0 ) { - - if( node->GetNodeName() == TString( "Sample" ) ) { - inputFileName_cache=inputFileName; - histoName_cache=histoName; - histoPathName_cache=histoPathName; - EstimateSummary sample_channel; - sample_channel.channel=channelName; - - // Set the Stat Paramaters - // (These are uniform over a channel, but - // they are only used if a particular sample - // requests to use them) - sample_channel.StatConstraintType=StatConstraintType; - sample_channel.RelErrorThreshold=RelErrorThreshold; - - // For each sample, include a possible - // external histogram for the stat error: - / * - string statErrorName=""; - string statErrorPath=""; - string statErrorFile=""; - * / - attribIt = node->GetAttributes(); - curAttr = 0; - while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { - if( curAttr->GetName() == TString( "Name" ) ) { - // name of the smaple - sample_channel.name=curAttr->GetValue(); - } - if( curAttr->GetName() == TString( "InputFile" ) ) { - inputFileName = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "HistoName" ) ) { - histoName = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "HistoPath" ) ) { - histoPathName=curAttr->GetValue(); - } - if( curAttr->GetName() == TString( "NormalizeByTheory" ) ) { - if((curAttr->GetValue()==TString("False"))){ - sample_channel.normName=lumiStr; - } - } - / * - if( curAttr->GetName() == TString( "IncludeStatError" ) ) { - if((curAttr->GetValue()==TString("True"))){ - sample_channel.IncludeStatError = true; // Added McStat - } - } - if( curAttr->GetName() == TString( "ShapeFactorName" ) ) { - sample_channel.shapeFactorName = curAttr->GetValue(); - } - * / - } // (Casting to TH1F* here... - cout << "Getting nominal histogram: " << histoPathName << "/" << histoName << " in file " << inputFileName << endl; - //sample_channel.nominal = (TH1F*) GetHisto(inputFileName, histoPathName, histoName); - sample_channel.nominal = GetHisto(inputFileName, histoPathName, histoName); - // Set the rel Error hist later, - // if necessary - //sample_channel.relStatError = NULL; - - TXMLNode* sys = node->GetChildren(); - AddSystematic(sample_channel, sys, inputFileName, histoPathName, histoName); - summary.push_back(sample_channel); - inputFileName=inputFileName_cache; - histoName=histoName_cache; - histoPathName=histoPathName_cache; - //sample_channel.print(); - } - node = node->GetNextNode(); - } - - */ - -/* -void HistFactory::AddSystematic( EstimateSummary & sample_channel, TXMLNode* node, string inputFileName, string histoPathName, string histoName){ - - while( node != 0 ) { - - if( node->GetNodeName() == TString( "NormFactor" ) ){ - TListIter attribIt = node->GetAttributes(); - EstimateSummary::NormFactor norm; - TXMLAttr* curAttr = 0; - while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { - if( curAttr->GetName() == TString( "Name" ) ) { - norm.name = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "Val" ) ) { - norm.val = atof(curAttr->GetValue()) ; - } - if( curAttr->GetName() == TString( "Low" ) ) { - norm.low = atof(curAttr->GetValue()) ; - } - if( curAttr->GetName() == TString( "High" ) ) { - norm.high = atof(curAttr->GetValue()) ; - } - if( curAttr->GetName() == TString( "Const" ) ) { - norm.constant = (curAttr->GetValue()==TString("True")); - } - } - - sample_channel.normFactor.push_back(norm); - } - - if( node->GetNodeName() == TString( "HistoSys" ) ){ - TListIter attribIt = node->GetAttributes(); - TXMLAttr* curAttr = 0; - string Name, histoPathHigh, histoPathLow, - histoNameLow, histoNameHigh, inputFileHigh, inputFileLow; - inputFileLow=inputFileName; inputFileHigh=inputFileName; - histoPathLow=histoPathName; histoPathHigh=histoPathName; - histoNameLow=histoName; histoNameHigh=histoName; - while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { - if( curAttr->GetName() == TString( "Name" ) ) { - Name = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "InputFileHigh" ) ) { - inputFileHigh = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "HistoPathHigh" ) ) { - histoPathHigh = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "HistoNameHigh" ) ) { - histoNameHigh = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "InputFileLow" ) ) { - inputFileLow = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "HistoPathLow" ) ) { - histoPathLow = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "HistoNameLow" ) ) { - histoNameLow = curAttr->GetValue() ; - } - } - //sample_channel.AddSyst(Name, - // (TH1F*) GetHisto( inputFileLow, histoPathLow, histoNameLow), - // (TH1F*) GetHisto( inputFileHigh, histoPathHigh, histoNameHigh)); - sample_channel.AddSyst(Name, - GetHisto( inputFileLow, histoPathLow, histoNameLow), - GetHisto( inputFileHigh, histoPathHigh, histoNameHigh)); - } - - if( node->GetNodeName() == TString( "OverallSys" ) ){ - TListIter attribIt = node->GetAttributes(); - TXMLAttr* curAttr = 0; - string Name; - Double_t Low=0, High=0; - while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { - if( curAttr->GetName() == TString( "Name" ) ) { - Name = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "High" ) ) { - High = atof(curAttr->GetValue()) ; - } - if( curAttr->GetName() == TString( "Low" ) ) { - Low = atof(curAttr->GetValue()) ; - } - } - sample_channel.overallSyst[Name] = UncertPair(Low, High); - } - - - if( node->GetNodeName() == TString( "StatError" ) ){ - TListIter attribIt = node->GetAttributes(); - TXMLAttr* curAttr = 0; - bool statErrorActivate = false; - string statHistName = ""; - string statHistPath = ""; - string statHistFile = inputFileName; - - while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { - if( curAttr->GetName() == TString( "Activate" ) ) { - if( curAttr->GetValue() == TString("True") ) statErrorActivate = true; - } - if( curAttr->GetName() == TString( "InputFile" ) ) { - statHistFile = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "HistoName" ) ) { - statHistName = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "HistoPath" ) ) { - statHistPath = curAttr->GetValue() ; - } - } - if( statErrorActivate) { - sample_channel.IncludeStatError = true; - // Get an external histogram if necessary - if( statHistName != "" ) { - cout << "Getting rel StatError histogram: " << statHistPath << "/" << statHistName << " in file " << statHistFile << endl; - sample_channel.relStatError = (TH1*) GetHisto(statHistFile, statHistPath, statHistName); - } else { - sample_channel.relStatError = NULL; - } - } - } // END: StatError Node - - if( node->GetNodeName() == TString( "ShapeFactor" ) ){ - TListIter attribIt = node->GetAttributes(); - TXMLAttr* curAttr = 0; - string Name=""; - while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { - if( curAttr->GetName() == TString( "Name" ) ) { - Name = curAttr->GetValue() ; - } - } - sample_channel.shapeFactorName=Name; - } // END: ShapeFactor Node - - if( node->GetNodeName() == TString( "ShapeSys" ) ){ - TListIter attribIt = node->GetAttributes(); - TXMLAttr* curAttr = 0; - string Name=""; - string HistoName; - string HistoPath; - string HistoFile = inputFileName; - EstimateSummary::ConstraintType ConstraintType = EstimateSummary::Gaussian; //"Gaussian"; - - while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { - if( curAttr->GetName() == TString( "Name" ) ) { - Name = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "HistoName" ) ) { - HistoName = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "HistoPath" ) ) { - HistoPath = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "HistoFile" ) ) { - HistoFile = curAttr->GetValue() ; - } - if( curAttr->GetName() == TString( "ConstraintType" ) ) { - if( curAttr->GetValue()==TString("Gaussian") || curAttr->GetValue()==TString("Gauss") ) ConstraintType = EstimateSummary::Gaussian; - else if( curAttr->GetValue()==TString("Poisson") || curAttr->GetValue()==TString("Pois") ) ConstraintType = EstimateSummary::Poisson; - } - } - // Now, set the EstimateSummary accordingly - EstimateSummary::ShapeSys Sys; - Sys.name = Name; - Sys.hist = NULL; - cout << "Getting rel ShapeSys constraint histogram: " << HistoPath << "/" << HistoName << " in file " << HistoFile << endl; - Sys.hist = (TH1*) GetHisto(HistoFile, HistoPath, HistoName); - if( Sys.hist == NULL ) { - cout << "Failed to get histogram: " << HistoPath << "/" <<HistoName << " in file " << HistoFile << endl; - } - Sys.constraint = ConstraintType; - sample_channel.shapeSysts.push_back( Sys ); - } // END: ShapeFactor Node - - - node=node->GetNextNode(); - } - - -} -*/ - - HistFactory::Data ConfigParser::CreateDataElement( TXMLNode* node ) { std::cout << "Creating Data Element" << std::endl; @@ -1321,7 +721,11 @@ HistFactory::Data ConfigParser::CreateDataElement( TXMLNode* node ) { if( attrName == TString( "" ) ) { std::cout << " Error: Attribute for 'Data' with no name found" << std::endl; - throw bad_hf; + throw hf_exc(); + } + + else if( attrName == TString( "Name" ) ) { + data.SetName( attrVal ); } else if( attrName == TString( "InputFile" ) ) { @@ -1340,7 +744,7 @@ HistFactory::Data ConfigParser::CreateDataElement( TXMLNode* node ) { else { std::cout << " Error: Unknown attribute for 'Data' encountered: " << attrName << std::endl; - throw bad_hf; + throw hf_exc(); } } @@ -1348,19 +752,19 @@ HistFactory::Data ConfigParser::CreateDataElement( TXMLNode* node ) { // Check the properties of the data node: if( data.GetInputFile() == "" ) { std::cout << "Error: Data Node has no InputFile" << std::endl; - throw bad_hf; + throw hf_exc(); } if( data.GetHistoName() == "" ) { std::cout << "Error: Data Node has no HistoName" << std::endl; - throw bad_hf; + throw hf_exc(); } std::cout << "Created Data Node with" << " InputFile: " << data.GetInputFile() << " HistoName: " << data.GetHistoName() - << " HistoPath: " << data.GetHistoPath() - << std::endl; - + << " HistoPath: " << data.GetHistoPath(); + if( data.GetName() != "") std::cout << " Name: " << data.GetName(); + std::cout << std::endl; // data.hist = GetHisto(data.FileName, data.HistoPath, data.HistoName); @@ -1379,7 +783,6 @@ HistFactory::StatErrorConfig ConfigParser::CreateStatErrorConfigElement( TXMLNod config.SetConstraintType( Constraint::Gaussian ); config.SetRelErrorThreshold( 0.05 ); // 5% - // Loop over the node's attributes TListIter attribIt = node->GetAttributes(); TXMLAttr* curAttr = 0; @@ -1398,7 +801,7 @@ HistFactory::StatErrorConfig ConfigParser::CreateStatErrorConfigElement( TXMLNod if( attrVal == "" ) { std::cout << "Error: Bad Value for StatErrorConfig Constraint Type Found" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( attrVal=="Gaussian" || attrVal=="Gauss" ) { @@ -1413,11 +816,9 @@ HistFactory::StatErrorConfig ConfigParser::CreateStatErrorConfigElement( TXMLNod else { cout << "Invalid Stat Constraint Type: " << curAttr->GetValue() << endl; - throw bad_hf; + throw hf_exc(); } - } - } // End: Loop Over Attributes std::cout << "Created StatErrorConfig Element with" @@ -1455,7 +856,7 @@ HistFactory::Sample ConfigParser::CreateSampleElement( TXMLNode* node ) { if( attrName == TString( "" ) ) { std::cout << " Error: Attribute for 'Sample' with no name found" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( attrName == TString( "Name" ) ) { @@ -1464,6 +865,7 @@ HistFactory::Sample ConfigParser::CreateSampleElement( TXMLNode* node ) { else if( attrName == TString( "InputFile" ) ) { sample.SetInputFile( attrVal ); + m_currentInputFile = attrVal; } else if( attrName == TString( "HistoName" ) ) { @@ -1472,6 +874,7 @@ HistFactory::Sample ConfigParser::CreateSampleElement( TXMLNode* node ) { else if( attrName == TString( "HistoPath" ) ) { sample.SetHistoPath( attrVal ); + m_currentHistoPath = attrVal; } else if( attrName == TString( "NormalizeByTheory" ) ) { @@ -1479,37 +882,36 @@ HistFactory::Sample ConfigParser::CreateSampleElement( TXMLNode* node ) { /* if( attrVal == "" ) { std::cout << "Error: Attribute 'NormalizeByTheory' in Sample has no value" << std::endl; - throw bad_hf; + throw hf_exc(); } else if ( attrVal == "True" || attrVal == "true" ) sample.NormalizeByTheory = true; else if ( attrVal == "False" || attrVal == "false" ) sample.NormalizeByTheory = false; else { std::cout << "Error: Attribute 'NormalizeByTheory' in Sample has unknown value: " << attrVal << std::endl; std::cout << "Value must be 'True' or 'False' " << std::endl; - throw bad_hf; + throw hf_exc(); } */ } else { std::cout << " Error: Unknown attribute for 'Sample' encountered: " << attrName << std::endl; - throw bad_hf; + throw hf_exc(); } - } // Quickly check the properties of the Sample Node if( sample.GetName() == "" ) { std::cout << "Error: Sample Node has no Name" << std::endl; - throw bad_hf; + throw hf_exc(); } if( sample.GetInputFile() == "" ) { std::cout << "Error: Sample Node has no InputFile" << std::endl; - throw bad_hf; + throw hf_exc(); } if( sample.GetHistoName() == "" ) { std::cout << "Error: Sample Node has no HistoName" << std::endl; - throw bad_hf; + throw hf_exc(); } @@ -1521,7 +923,7 @@ HistFactory::Sample ConfigParser::CreateSampleElement( TXMLNode* node ) { if( child->GetNodeName() == TString( "" ) ) { std::cout << "Error: Encountered node in Sample with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( child->GetNodeName() == TString( "NormFactor" ) ) { @@ -1557,13 +959,12 @@ HistFactory::Sample ConfigParser::CreateSampleElement( TXMLNode* node ) { else { std::cout << "Error: Encountered node in Sample with unknown name: " << child->GetNodeName() << std::endl; - throw bad_hf; + throw hf_exc(); } child=child->GetNextNode(); } - std::cout << "Created Sample Node with" << " Name: " << sample.GetName() << " InputFile: " << sample.GetInputFile() @@ -1571,7 +972,6 @@ HistFactory::Sample ConfigParser::CreateSampleElement( TXMLNode* node ) { << " HistoPath: " << sample.GetHistoPath() << std::endl; - // sample.hist = GetHisto(sample.FileName, sample.HistoPath, sample.HistoName); return sample; @@ -1594,7 +994,7 @@ HistFactory::NormFactor ConfigParser::MakeNormFactor( TXMLNode* node ) { if( attrName == TString( "" ) ){ std::cout << "Error: Encountered Element in NormFactor with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( curAttr->GetName() == TString( "Name" ) ) { @@ -1616,14 +1016,32 @@ HistFactory::NormFactor ConfigParser::MakeNormFactor( TXMLNode* node ) { else { std::cout << "Error: Encountered Element in NormFactor with unknown name: " << attrName << std::endl; - throw bad_hf; + throw hf_exc(); } } // End loop over properties if( norm.GetName() == "" ) { std::cout << "Error: NormFactor Node has no Name" << std::endl; - throw bad_hf; + throw hf_exc(); + } + + if( norm.GetLow() >= norm.GetHigh() ) { + std::cout << "Error: NormFactor: " << norm.GetName() + << " has lower limit >= its upper limit: " + << " Lower: " << norm.GetLow() + << " Upper: " << norm.GetHigh() + << ". Please Fix" << std::endl; + throw hf_exc(); + } + if( norm.GetVal() > norm.GetHigh() || norm.GetVal() < norm.GetLow() ) { + std::cout << "Error: NormFactor: " << norm.GetName() + << " has initial value not within its range: " + << " Val: " << norm.GetVal() + << " Lower: " << norm.GetLow() + << " Upper: " << norm.GetHigh() + << ". Please Fix" << std::endl; + throw hf_exc(); } norm.Print(); @@ -1657,15 +1075,13 @@ HistFactory::HistoSys ConfigParser::MakeHistoSys( TXMLNode* node ) { HistFactory::HistoSys histoSys; + // Set Default values histoSys.SetInputFileLow( m_currentInputFile ); histoSys.SetHistoPathLow( m_currentHistoPath ); histoSys.SetInputFileHigh( m_currentInputFile ); histoSys.SetHistoPathHigh( m_currentHistoPath ); - - // MUST SET DEFAULT VALUES!!!!J!LH:OIH:OIHO:H - TListIter attribIt = node->GetAttributes(); TXMLAttr* curAttr = 0; /* @@ -1684,14 +1100,14 @@ HistFactory::HistoSys ConfigParser::MakeHistoSys( TXMLNode* node ) { if( attrName == TString( "" ) ){ std::cout << "Error: Encountered Element in HistoSys with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( curAttr->GetName() == TString( "Name" ) ) { histoSys.SetName( attrVal ); } - else if( curAttr->GetName() == TString( "InputFileHigh" ) ) { + else if( curAttr->GetName() == TString( "HistoFileHigh" ) ) { histoSys.SetInputFileHigh( attrVal ); } else if( curAttr->GetName() == TString( "HistoPathHigh" ) ) { @@ -1701,7 +1117,7 @@ HistFactory::HistoSys ConfigParser::MakeHistoSys( TXMLNode* node ) { histoSys.SetHistoNameHigh( attrVal ); } - else if( curAttr->GetName() == TString( "InputFileLow" ) ) { + else if( curAttr->GetName() == TString( "HistoFileLow" ) ) { histoSys.SetInputFileLow( attrVal ); } else if( curAttr->GetName() == TString( "HistoPathLow" ) ) { @@ -1714,7 +1130,7 @@ HistFactory::HistoSys ConfigParser::MakeHistoSys( TXMLNode* node ) { else { std::cout << "Error: Encountered Element in HistoSys with unknown name: " << attrName << std::endl; - throw bad_hf; + throw hf_exc(); } } // End loop over properties @@ -1722,23 +1138,23 @@ HistFactory::HistoSys ConfigParser::MakeHistoSys( TXMLNode* node ) { if( histoSys.GetName() == "" ) { std::cout << "Error: HistoSys Node has no Name" << std::endl; - throw bad_hf; + throw hf_exc(); } if( histoSys.GetInputFileHigh() == "" ) { std::cout << "Error: HistoSysSample Node has no InputFileHigh" << std::endl; - throw bad_hf; + throw hf_exc(); } if( histoSys.GetInputFileLow() == "" ) { std::cout << "Error: HistoSysSample Node has no InputFileLow" << std::endl; - throw bad_hf; + throw hf_exc(); } if( histoSys.GetHistoNameHigh() == "" ) { std::cout << "Error: HistoSysSample Node has no HistoNameHigh" << std::endl; - throw bad_hf; + throw hf_exc(); } if( histoSys.GetHistoNameLow() == "" ) { std::cout << "Error: HistoSysSample Node has no HistoNameLow" << std::endl; - throw bad_hf; + throw hf_exc(); } @@ -1755,7 +1171,6 @@ HistFactory::OverallSys ConfigParser::MakeOverallSys( TXMLNode* node ) { HistFactory::OverallSys overallSys; - // MUST SET DEFAULT VALUES!!!!J!LH:OIH:OIHO:H TListIter attribIt = node->GetAttributes(); TXMLAttr* curAttr = 0; while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { @@ -1766,7 +1181,7 @@ HistFactory::OverallSys ConfigParser::MakeOverallSys( TXMLNode* node ) { if( attrName == TString( "" ) ){ std::cout << "Error: Encountered Element in OverallSys with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( attrName == TString( "Name" ) ) { @@ -1782,14 +1197,14 @@ HistFactory::OverallSys ConfigParser::MakeOverallSys( TXMLNode* node ) { else { std::cout << "Error: Encountered Element in OverallSys with unknown name: " << attrName << std::endl; - throw bad_hf; + throw hf_exc(); } } if( overallSys.GetName() == "" ) { std::cout << "Error: Encountered OverallSys with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } @@ -1808,7 +1223,14 @@ HistFactory::ShapeFactor ConfigParser::MakeShapeFactor( TXMLNode* node ) { TListIter attribIt = node->GetAttributes(); TXMLAttr* curAttr = 0; - string Name=""; + + // A Shape Factor may or may not include an initial shape + // This will be set by strings pointing to a histogram + // If we don't see a 'HistoName' attribute, we assume + // that an initial shape is not being set + std::string ShapeInputFile = m_currentInputFile; + std::string ShapeInputPath = m_currentHistoPath; + while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { // Get the Name, Val of this node @@ -1817,26 +1239,55 @@ HistFactory::ShapeFactor ConfigParser::MakeShapeFactor( TXMLNode* node ) { if( attrName == TString( "" ) ){ std::cout << "Error: Encountered Element in ShapeFactor with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( attrName == TString( "Name" ) ) { shapeFactor.SetName( attrVal ); } + else if( attrName == TString( "Const" ) ) { + shapeFactor.SetConstant( CheckTrueFalse(attrVal, "ShapeFactor" ) ); + } + + else if( attrName == TString( "HistoName" ) ) { + shapeFactor.SetHistoName( attrVal ); + } + + else if( attrName == TString( "InputFile" ) ) { + ShapeInputFile = attrVal; + } + + else if( attrName == TString( "HistoPath" ) ) { + ShapeInputPath = attrVal; + } else { std::cout << "Error: Encountered Element in ShapeFactor with unknown name: " << attrName << std::endl; - throw bad_hf; + throw hf_exc(); } } if( shapeFactor.GetName() == "" ) { std::cout << "Error: Encountered ShapeFactor with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } + // Set the Histogram name, path, and file + // if an InitialHist is set + if( shapeFactor.HasInitialShape() ) { + if( shapeFactor.GetHistoName() == "" ) { + std::cout << "Error: ShapeFactor: " << shapeFactor.GetName() + << " is configured to have an initial shape, but " + << "its histogram doesn't have a name" + << std::endl; + throw hf_exc(); + } + shapeFactor.SetHistoPath( ShapeInputPath ); + shapeFactor.SetInputFile( ShapeInputFile ); + } + shapeFactor.Print(); return shapeFactor; @@ -1849,8 +1300,9 @@ HistFactory::ShapeSys ConfigParser::MakeShapeSys( TXMLNode* node ) { std::cout << "Making ShapeSys" << std::endl; HistFactory::ShapeSys shapeSys; - shapeSys.SetConstraintType( Constraint::Gaussian ); + // Set the default values + shapeSys.SetConstraintType( Constraint::Gaussian ); shapeSys.SetInputFile( m_currentInputFile ); shapeSys.SetHistoPath( m_currentHistoPath ); @@ -1868,7 +1320,7 @@ HistFactory::ShapeSys ConfigParser::MakeShapeSys( TXMLNode* node ) { if( attrName == TString( "" ) ){ std::cout << "Error: Encountered Element in ShapeSys with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( attrName == TString( "Name" ) ) { @@ -1890,7 +1342,7 @@ HistFactory::ShapeSys ConfigParser::MakeShapeSys( TXMLNode* node ) { else if( attrName == TString( "ConstraintType" ) ) { if( attrVal=="" ) { std::cout << "Error: ShapeSys Constraint type is empty" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( attrVal=="Gaussian" || attrVal=="Gauss" ) { shapeSys.SetConstraintType( Constraint::Gaussian ); @@ -1900,14 +1352,14 @@ HistFactory::ShapeSys ConfigParser::MakeShapeSys( TXMLNode* node ) { } else { cout << "Error: Encountered unknown ShapeSys Constraint type: " << attrVal << endl; - throw bad_hf; + throw hf_exc(); } } else { std::cout << "Error: Encountered Element in ShapeSys with unknown name: " << attrName << std::endl; - throw bad_hf; + throw hf_exc(); } } // End loop over attributes @@ -1915,15 +1367,15 @@ HistFactory::ShapeSys ConfigParser::MakeShapeSys( TXMLNode* node ) { if( shapeSys.GetName() == "" ) { std::cout << "Error: Encountered ShapeSys with no Name" << std::endl; - throw bad_hf; + throw hf_exc(); } if( shapeSys.GetInputFile() == "" ) { std::cout << "Error: Encountered ShapeSys with no InputFile" << std::endl; - throw bad_hf; + throw hf_exc(); } if( shapeSys.GetHistoName() == "" ) { std::cout << "Error: Encountered ShapeSys with no HistoName" << std::endl; - throw bad_hf; + throw hf_exc(); } shapeSys.Print(); @@ -1932,33 +1384,16 @@ HistFactory::ShapeSys ConfigParser::MakeShapeSys( TXMLNode* node ) { } - /* - - // Now, set the EstimateSummary accordingly - EstimateSummary::ShapeSys Sys; - Sys.name = Name; - Sys.hist = NULL; - cout << "Getting rel ShapeSys constraint histogram: " << HistoPath << "/" << HistoName << " in file " << HistoFile << endl; - Sys.hist = (TH1*) GetHisto(HistoFile, HistoPath, HistoName); - if( Sys.hist == NULL ) { - cout << "Failed to get histogram: " << HistoPath << "/" <<HistoName << " in file " << HistoFile << endl; - } - Sys.constraint = ConstraintType; - */ - HistFactory::StatError ConfigParser::ActivateStatError( TXMLNode* node ) { std::cout << "Activating StatError" << std::endl; - // Have to figiure this out: - // Must use this channel's constraint type - // as defined by the StatErrorConfig - + // Set default values HistFactory::StatError statError; statError.Activate( false ); statError.SetUseHisto( false ); - + statError.SetHistoName( "" ); // Loop over the node's attributes TListIter attribIt = node->GetAttributes(); @@ -1971,7 +1406,7 @@ HistFactory::StatError ConfigParser::ActivateStatError( TXMLNode* node ) { if( attrName == TString( "" ) ){ std::cout << "Error: Encountered Element in ActivateStatError with no name" << std::endl; - throw bad_hf; + throw hf_exc(); } else if( attrName == TString( "Activate" ) ) { @@ -1993,13 +1428,18 @@ HistFactory::StatError ConfigParser::ActivateStatError( TXMLNode* node ) { else { std::cout << "Error: Encountered Element in ActivateStatError with unknown name: " << attrName << std::endl; - throw bad_hf; + throw hf_exc(); } } // End: Loop Over Attributes // Based on the input, determine // if we should use a histogram or not: + // Logic: One turns on using a histogram + // by setting the attribute "HistoName" + // If this is set AND the InputFile or + // HistoPath aren't set, we set those + // to the current default values if( statError.GetHistoName() != "" ) { statError.SetUseHisto( true ); @@ -2008,6 +1448,9 @@ HistFactory::StatError ConfigParser::ActivateStatError( TXMLNode* node ) { if( statError.GetInputFile() == "" ) { statError.SetInputFile( m_currentInputFile ); } + if( statError.GetHistoPath() == "" ) { + statError.SetHistoPath( m_currentHistoPath ); + } } @@ -2034,27 +1477,51 @@ RooStats::HistFactory::PreprocessFunction ConfigParser::ParseFunctionConfig( TXM std::cout << "Parsing FunctionConfig" << std::endl; - RooStats::HistFactory::PreprocessFunction func; - //std::string name, expression, dependents; TListIter attribIt = functionNode->GetAttributes(); TXMLAttr* curAttr = 0; + + std::string Name = ""; + std::string Expression = ""; + std::string Dependents = ""; + + // Add protection to ensure that all parts are there while( ( curAttr = dynamic_cast< TXMLAttr* >( attribIt() ) ) != 0 ) { if( curAttr->GetName() == TString( "Name" ) ) { - func.SetName( curAttr->GetValue() ); + Name = curAttr->GetValue(); + //func.SetName( curAttr->GetValue() ); //name = curAttr->GetValue() ; } if( curAttr->GetName() == TString( "Expression" ) ) { - func.SetExpression( curAttr->GetValue() ); + Expression = curAttr->GetValue(); + //func.SetExpression( curAttr->GetValue() ); } if( curAttr->GetName() == TString( "Dependents" ) ) { - func.SetDependents( curAttr->GetValue() ); + Dependents = curAttr->GetValue(); + //func.SetDependents( curAttr->GetValue() ); } } - std::string command = "expr::"+func.GetName()+"('"+func.GetExpression()+"',{"+func.GetDependents()+"})"; - func.SetCommand( command ); - // cout << "will pre-process this line " << ret <<endl; + if( Name=="" ){ + std::cout << "Error processing PreprocessFunction: Name attribute is empty" << std::endl; + throw hf_exc(); + } + if( Expression=="" ){ + std::cout << "Error processing PreprocessFunction: Expression attribute is empty" << std::endl; + throw hf_exc(); + } + if( Dependents=="" ){ + std::cout << "Error processing PreprocessFunction: Dependents attribute is empty" << std::endl; + throw hf_exc(); + } + + RooStats::HistFactory::PreprocessFunction func(Name, Expression, Dependents); + + std::cout << "Created Preprocess Function: " << func.GetCommand() << std::endl; + + //std::string command = "expr::"+func.GetName()+"('"+func.GetExpression()+"',{"+func.GetDependents()+"})"; + //func.SetCommand( command ); + // // cout << "will pre-process this line " << ret <<endl; return func; } @@ -2080,14 +1547,14 @@ bool ConfigParser::CheckTrueFalse( std::string attrVal, std::string NodeTitle ) if( attrVal == "" ) { std::cout << "Error: In " << NodeTitle << " Expected either 'True' or 'False' but found empty" << std::endl; - throw bad_hf; + throw hf_exc(); } else if ( attrVal == "True" || attrVal == "true" ) return true; else if ( attrVal == "False" || attrVal == "false" ) return false; else { std::cout << "Error: In " << NodeTitle << " Expected either 'True' or 'False' but found: " << attrVal << std::endl; - throw bad_hf; + throw hf_exc(); } return false; diff --git a/roofit/histfactory/src/Data.cxx b/roofit/histfactory/src/Data.cxx index d8fbe10d90739..535151297a544 100644 --- a/roofit/histfactory/src/Data.cxx +++ b/roofit/histfactory/src/Data.cxx @@ -1,9 +1,32 @@ +// @(#)root/roostats:$Id$ +// Author: Kyle Cranmer, George Lewis +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +//_________________________________________________ +/* +BEGIN_HTML +<p> +</p> +END_HTML +*/ +// #include "RooStats/HistFactory/Data.h" -RooStats::HistFactory::Data::Data( std::string HistoName, std::string InputFile, std::string HistoPath ) : +RooStats::HistFactory::Data::Data() : fName("") { + ; +} + +RooStats::HistFactory::Data::Data( std::string HistoName, std::string InputFile, + std::string HistoPath ) : fInputFile( InputFile ), fHistoName( HistoName ), fHistoPath( HistoPath ) {;} TH1* RooStats::HistFactory::Data::GetHisto() { @@ -24,15 +47,28 @@ void RooStats::HistFactory::Data::Print( std::ostream& stream ) { void RooStats::HistFactory::Data::writeToFile( std::string OutputFileName, std::string DirName ) { TH1* histData = GetHisto(); - histData->Write(); + + if( histData != NULL) { + + histData->Write(); - // Set the location of the data - // in the output measurement + // Set the location of the data + // in the output measurement - fInputFile = OutputFileName; - fHistoName = histData->GetName(); - fHistoPath = DirName; + fInputFile = OutputFileName; + fHistoName = histData->GetName(); + fHistoPath = DirName; - return; + } } + + +void RooStats::HistFactory::Data::PrintXML( std::ostream& xml ) { + + xml << " <Data HistoName=\"" << GetHistoName() << "\" " + << "InputFile=\"" << GetInputFile() << "\" " + << "HistoPath=\"" << GetHistoPath() << "\" " + << " /> " << std::endl << std::endl; + +} diff --git a/roofit/histfactory/src/FlexibleInterpVar.cxx b/roofit/histfactory/src/FlexibleInterpVar.cxx index 54a9e1852a806..6a0278e84bae1 100644 --- a/roofit/histfactory/src/FlexibleInterpVar.cxx +++ b/roofit/histfactory/src/FlexibleInterpVar.cxx @@ -20,7 +20,6 @@ END_HTML #include "RooFit.h" -#include "Riostream.h" #include "Riostream.h" #include <math.h> #include "TMath.h" @@ -33,6 +32,8 @@ END_HTML #include "RooStats/HistFactory/FlexibleInterpVar.h" +using namespace std; + ClassImp(RooStats::HistFactory::FlexibleInterpVar) using namespace RooStats; @@ -45,18 +46,60 @@ FlexibleInterpVar::FlexibleInterpVar() _paramIter = _paramList.createIterator() ; _nominal = 0; _interpBoundary=1.; + _logInit = kFALSE ; } //_____________________________________________________________________________ FlexibleInterpVar::FlexibleInterpVar(const char* name, const char* title, const RooArgList& paramList, - double nominal, vector<double> low, vector<double> high) : + Double_t nominal, vector<double> low, vector<double> high) : RooAbsReal(name, title), _paramList("paramList","List of paramficients",this), _nominal(nominal), _low(low), _high(high), _interpBoundary(1.) { + _logInit = kFALSE ; + _paramIter = _paramList.createIterator() ; + + + TIterator* paramIter = paramList.createIterator() ; + RooAbsArg* param ; + while((param = (RooAbsArg*)paramIter->Next())) { + if (!dynamic_cast<RooAbsReal*>(param)) { + coutE(InputArguments) << "FlexibleInterpVar::ctor(" << GetName() << ") ERROR: paramficient " << param->GetName() + << " is not of type RooAbsReal" << endl ; + assert(0) ; + } + _paramList.add(*param) ; + _interpCode.push_back(0); // default code + } + delete paramIter ; + +} + +//_____________________________________________________________________________ +FlexibleInterpVar::FlexibleInterpVar(const char* name, const char* title, + const RooArgList& paramList, + double nominal, const RooArgList& low, const RooArgList& high) : + RooAbsReal(name, title), + _paramList("paramList","List of paramficients",this), + _nominal(nominal), _interpBoundary(1.) +{ + + RooFIter lowIter = low.fwdIterator() ; + RooAbsReal* val ; + while ((val = (RooAbsReal*) lowIter.next())) { + _low.push_back(val->getVal()) ; + } + + RooFIter highIter = high.fwdIterator() ; + while ((val = (RooAbsReal*) highIter.next())) { + _high.push_back(val->getVal()) ; + } + + + _logInit = kFALSE ; _paramIter = _paramList.createIterator() ; @@ -75,6 +118,9 @@ FlexibleInterpVar::FlexibleInterpVar(const char* name, const char* title, } + + + //_____________________________________________________________________________ FlexibleInterpVar::FlexibleInterpVar(const char* name, const char* title, const RooArgList& paramList, @@ -85,6 +131,7 @@ FlexibleInterpVar::FlexibleInterpVar(const char* name, const char* title, _nominal(nominal), _low(low), _high(high), _interpCode(code), _interpBoundary(1.) { + _logInit = kFALSE ; _paramIter = _paramList.createIterator() ; @@ -108,7 +155,7 @@ FlexibleInterpVar::FlexibleInterpVar(const char* name, const char* title) : _paramList("paramList","List of coefficients",this) { // Constructor of flat polynomial function - + _logInit = kFALSE ; _paramIter = _paramList.createIterator() ; } @@ -120,6 +167,7 @@ FlexibleInterpVar::FlexibleInterpVar(const FlexibleInterpVar& other, const char* { // Copy constructor + _logInit = kFALSE ; _paramIter = _paramList.createIterator() ; } @@ -145,6 +193,8 @@ void FlexibleInterpVar::setInterpCode(RooAbsReal& param, int code){ << " is now " << code << endl ; _interpCode.at(index) = code; } + // GHL: Adding suggestion by Swagato: + setValueDirty(); } //_____________________________________________________________________________ @@ -153,6 +203,50 @@ void FlexibleInterpVar::setAllInterpCodes(int code){ for(unsigned int i=0; i<_interpCode.size(); ++i){ _interpCode.at(i) = code; } + // GHL: Adding suggestion by Swagato: + setValueDirty(); + +} + +//_____________________________________________________________________________ +void FlexibleInterpVar::setNominal(Double_t newNominal){ + + coutW(InputArguments) << "FlexibleInterpVar::setNominal : nominal is now " << newNominal << endl ; + _nominal = newNominal; + + setValueDirty(); +} + +//_____________________________________________________________________________ +void FlexibleInterpVar::setLow(RooAbsReal& param, Double_t newLow){ + + int index = _paramList.index(¶m); + if(index<0){ + coutE(InputArguments) << "FlexibleInterpVar::setLow ERROR: " << param.GetName() + << " is not in list" << endl ; + } else { + coutW(InputArguments) << "FlexibleInterpVar::setLow : " << param.GetName() + << " is now " << newLow << endl ; + _low.at(index) = newLow; + } + + setValueDirty(); +} + +//_____________________________________________________________________________ +void FlexibleInterpVar::setHigh(RooAbsReal& param, Double_t newHigh){ + + int index = _paramList.index(¶m); + if(index<0){ + coutE(InputArguments) << "FlexibleInterpVar::setHigh ERROR: " << param.GetName() + << " is not in list" << endl ; + } else { + coutW(InputArguments) << "FlexibleInterpVar::setHigh : " << param.GetName() + << " is now " << newHigh << endl ; + _high.at(index) = newHigh; + } + + setValueDirty(); } //_____________________________________________________________________________ @@ -160,6 +254,9 @@ void FlexibleInterpVar::printAllInterpCodes(){ for(unsigned int i=0; i<_interpCode.size(); ++i){ coutI(InputArguments) <<"interp code for " << _paramList.at(i)->GetName() << " = " << _interpCode.at(i) <<endl; + // GHL: Adding suggestion by Swagato: + if( _low.at(i) <= 0.001 ) coutE(InputArguments) << GetName() << ", " << _paramList.at(i)->GetName() << ": low value = " << _low.at(i) << endl; + if( _high.at(i) <= 0.001 ) coutE(InputArguments) << GetName() << ", " << _paramList.at(i)->GetName() << ": high value = " << _high.at(i) << endl; } } @@ -179,80 +276,109 @@ Double_t FlexibleInterpVar::evaluate() const while((param=(RooAbsReal*)_paramIter->Next())) { // param->Print("v"); - if(_interpCode.at(i)==0){ + + Int_t icode = _interpCode[i] ; + switch(icode) { + + case 0: { // piece-wise linear if(param->getVal()>0) - total += param->getVal()*(_high.at(i) - _nominal ); + total += param->getVal()*(_high[i] - _nominal ); else - total += param->getVal()*(_nominal - _low.at(i)); - } else if(_interpCode.at(i)==1){ + total += param->getVal()*(_nominal - _low[i]); + break ; + } + case 1: { // pice-wise log if(param->getVal()>=0) - total *= pow(_high.at(i)/_nominal, +param->getVal()); + total *= pow(_high[i]/_nominal, +param->getVal()); else - total *= pow(_low.at(i)/_nominal, -param->getVal()); - } else if(_interpCode.at(i)==2){ + total *= pow(_low[i]/_nominal, -param->getVal()); + break ; + } + case 2: { // parabolic with linear - double a = 0.5*(_high.at(i)+_low.at(i))-_nominal; - double b = 0.5*(_high.at(i)-_low.at(i)); + double a = 0.5*(_high[i]+_low[i])-_nominal; + double b = 0.5*(_high[i]-_low[i]); double c = 0; if(param->getVal()>1 ){ - total += (2*a+b)*(param->getVal()-1)+_high.at(i)-_nominal; + total += (2*a+b)*(param->getVal()-1)+_high[i]-_nominal; } else if(param->getVal()<-1 ) { - total += -1*(2*a-b)*(param->getVal()+1)+_low.at(i)-_nominal; + total += -1*(2*a-b)*(param->getVal()+1)+_low[i]-_nominal; } else { total += a*pow(param->getVal(),2) + b*param->getVal()+c; } - } else if(_interpCode.at(i)==3){ + break ; + } + case 3: { //parabolic version of log-normal - double a = 0.5*(_high.at(i)+_low.at(i))-_nominal; - double b = 0.5*(_high.at(i)-_low.at(i)); + double a = 0.5*(_high[i]+_low[i])-_nominal; + double b = 0.5*(_high[i]-_low[i]); double c = 0; if(param->getVal()>1 ){ - total += (2*a+b)*(param->getVal()-1)+_high.at(i)-_nominal; + total += (2*a+b)*(param->getVal()-1)+_high[i]-_nominal; } else if(param->getVal()<-1 ) { - total += -1*(2*a-b)*(param->getVal()+1)+_low.at(i)-_nominal; + total += -1*(2*a-b)*(param->getVal()+1)+_low[i]-_nominal; } else { total += a*pow(param->getVal(),2) + b*param->getVal()+c; } - - } else if(_interpCode.at(i)==4){ // Aaron Armbruster - exponential extrapolation, polynomial interpolation + break ; + } + case 4: { double boundary = _interpBoundary; // piece-wise log + parabolic if(param->getVal()>=boundary) { - total *= pow(_high.at(i)/_nominal, +param->getVal()); + total *= pow(_high[i]/_nominal, +param->getVal()); } else if (param->getVal() < boundary && param->getVal() > -boundary && boundary != 0) { double x0 = boundary; double x = param->getVal(); -// double pow_up = pow(_high.at(i)/_nominal, x0); -// double pow_down = pow(_low.at(i)/_nominal, x0); -// double pow_up_log = pow_up*TMath::Log(_high.at(i)); -// double pow_down_log =-pow_down*TMath::Log(_low.at(i)); -// double pow_up_log2 = pow_up_log*TMath::Log(_high.at(i)); -// double pow_down_log2=-pow_down*TMath::Log(_low.at(i)); - - -//fcns+der are eq at bd -// double a = 1./(4*pow(x0, 1))*(3*A0 - x0*S1); -// double b = 1./(4*pow(x0, 2))*(4*S0 - x0*A1 - 8); -// double c = -1./(4*pow(x0, 3))*( A0 - x0*S1); -// double d = -1./(4*pow(x0, 4))*(2*S0 - x0*A1 - 4); -// total *= 1 + a*x + b*pow(x, 2) + c*pow(x, 3) + d*pow(x, 4); - - -//fcns+der+2nd_der are eq at bd - - double pow_up = pow(_high.at(i)/_nominal, x0); - double pow_down = pow(_low.at(i)/_nominal, x0); - double pow_up_log = pow_up*TMath::Log(_high.at(i)); - double pow_down_log = -pow_down*TMath::Log(_low.at(i)); - double pow_up_log2 = pow_up_log*TMath::Log(_high.at(i)); - double pow_down_log2= pow_down_log*TMath::Log(_low.at(i)); - + if (!_logInit) { + + _logInit=kTRUE ; + + _logHi.resize(_high.size()) ; + for (unsigned int j=0 ; j<_high.size() ; j++) { + _logHi[j] = TMath::Log(_high.at(j)) ; + } + _logLo.resize(_low.size()) ; + for (unsigned int j=0 ; j<_low.size() ; j++) { + _logLo[j] = TMath::Log(_low.at(j)) ; + } + + _powHi.resize(_high.size()) ; + for (unsigned int j=0 ; j<_high.size() ; j++) { + _powHi[j] = pow(_high.at(j)/_nominal, x0); + } + _powLo.resize(_low.size()) ; + for (unsigned int j=0 ; j<_low.size() ; j++) { + _powLo[j] = pow(_low.at(j)/_nominal, x0); + } + + } + + // GHL: Swagato's suggestions + // if( _low[i] == 0 ) _low[i] = 0.0001; + // if( _high[i] == 0 ) _high[i] = 0.0001; + + // GHL: Swagato's suggestions + double pow_up = _powHi[i] ; + double pow_down = _powLo[i] ; + double pow_up_log = _high[i] <= 0.0 ? 0.0 : pow_up*_logHi[i] ; + double pow_down_log = _low[i] <= 0.0 ? 0.0 : -pow_down*_logLo[i] ; + double pow_up_log2 = _high[i] <= 0.0 ? 0.0 : pow_up_log*_logHi[i] ; + double pow_down_log2= _low[i] <= 0.0 ? 0.0 : -pow_down_log*_logLo[i] ; + /* + double pow_up = pow(_high[i]/_nominal, x0); + double pow_down = pow(_low[i]/_nominal, x0); + double pow_up_log = pow_up*TMath::Log(_high[i]); + double pow_down_log = -pow_down*TMath::Log(_low[i]); + double pow_up_log2 = pow_up_log*TMath::Log(_high[i]); + double pow_down_log2= pow_down_log*TMath::Log(_low[i]); + */ double S0 = (pow_up+pow_down)/2; double A0 = (pow_up-pow_down)/2; double S1 = (pow_up_log+pow_down_log)/2; @@ -268,16 +394,21 @@ Double_t FlexibleInterpVar::evaluate() const double e = 1./(8*pow(x0, 5))*( + 3*A0 - 3*x0*S1 + x0*x0*A2); double f = 1./(8*pow(x0, 6))*( -8 + 8*S0 - 5*x0*A1 + x0*x0*S2); - total *= 1 + a*x + b*pow(x, 2) + c*pow(x, 3) + d*pow(x, 4) + e*pow(x, 5) + f*pow(x, 6); + double xx = x*x ; + double xxx = xx*x ; + total *= 1 + a*x + b*xx + c*xxx + d*xx*xx + e*xxx*xx + f*xxx*xxx; } else if (param->getVal()<=-boundary) - { - total *= pow(_low.at(i)/_nominal, -param->getVal()); + { + total *= pow(_low[i]/_nominal, -param->getVal()); } - } else { + break ; + } + default: { coutE(InputArguments) << "FlexibleInterpVar::evaluate ERROR: " << param->GetName() << " with unknown interpolation code" << endl ; } + } ++i; } @@ -288,5 +419,22 @@ Double_t FlexibleInterpVar::evaluate() const return total; } +void FlexibleInterpVar::printMultiline(ostream& os, Int_t contents, + Bool_t verbose, TString indent) const +{ + RooAbsReal::printMultiline(os,contents,verbose,indent); + os << indent << "--- FlexibleInterpVar ---" << endl; + printFlexibleInterpVars(os); +} + +void FlexibleInterpVar::printFlexibleInterpVars(ostream& os) const +{ + _paramIter->Reset(); + for (int i=0;i<(int)_low.size();i++) { + RooAbsReal* param=(RooAbsReal*)_paramIter->Next(); + os << setw(36) << param->GetName()<<": "<<setw(7) << _low[i]<<" "<<setw(7) << _high[i] + <<endl; + } +} diff --git a/roofit/histfactory/src/Helper.cxx b/roofit/histfactory/src/Helper.cxx index 941565ec18cf4..9268d28fa6775 100644 --- a/roofit/histfactory/src/Helper.cxx +++ b/roofit/histfactory/src/Helper.cxx @@ -20,335 +20,908 @@ END_HTML //#define DEBUG + +#include <sstream> #include "Helper.h" #include "RooStats/ModelConfig.h" #include "RooArgSet.h" #include "RooRealVar.h" +#include "RooMinimizer.h" +#include "RooSimultaneous.h" +#include "RooCategory.h" +#include "RooFitResult.h" + +using namespace std; + +namespace RooStats { + namespace HistFactory { -namespace RooStats{ -namespace HistFactory{ - vector<pair<string, string> > get_comb(vector<string> names){ - vector<pair<string, string> > list; - for(vector<string>::iterator itr=names.begin(); itr!=names.end(); ++itr){ - vector<string>::iterator itr2=itr; - for(itr2++; itr2!=names.end(); ++itr2){ - list.push_back(pair<string, string>(*itr, *itr2)); + + vector< pair<std::string, std::string> > get_comb(vector<std::string> names){ + vector< pair<std::string, std::string> > list; + for(vector<std::string>::iterator itr=names.begin(); itr!=names.end(); ++itr){ + vector<std::string>::iterator itr2=itr; + for(itr2++; itr2!=names.end(); ++itr2){ + list.push_back(pair<std::string, std::string>(*itr, *itr2)); + } } + return list; } - return list; - } - vector<EstimateSummary>* loadSavedInputs(TFile* outFile, string channel ){ - outFile->ShowStreamerInfo(); + vector<EstimateSummary>* loadSavedInputs(TFile* outFile, std::string channel ){ + outFile->ShowStreamerInfo(); - vector<EstimateSummary>* summaries = new vector<EstimateSummary>; - outFile->cd(channel.c_str()); + vector<EstimateSummary>* summaries = new vector<EstimateSummary>; + outFile->cd(channel.c_str()); - // loop through estimate summaries - TIter next(gDirectory->GetListOfKeys()); - EstimateSummary* summary; - while ((summary=(EstimateSummary*) next())) { -// if(summary){ + // loop through estimate summaries + TIter next(gDirectory->GetListOfKeys()); + EstimateSummary* summary; + while ((summary=(EstimateSummary*) next())) { + // if(summary){ summary->Print(); - cout << "was able to read summary with name " << summary->name << endl; - cout << " nominal hist = " << summary->nominal << endl; + cout << "was able to read summary with name " << summary->name << std::endl; + cout << " nominal hist = " << summary->nominal << std::endl; if(summary->nominal) - cout << " hist name = " << summary->nominal->GetName() <<endl; - cout << "still ok" << endl; + cout << " hist name = " << summary->nominal->GetName() <<endl; + cout << "still ok" << std::endl; summaries->push_back(*summary); -//L.M. This code cannot be reached- remove it -// } -// else{ -// cout << "was not able to read summary" << endl; -// } - } - return summaries; - } + //L.M. This code cannot be reached- remove it + // } + // else{ + // cout << "was not able to read summary" << std::endl; + // } + } + return summaries; + } - void saveInputs(TFile* outFile, string channel, vector<EstimateSummary> summaries){ - vector<EstimateSummary>::iterator it = summaries.begin(); - vector<EstimateSummary>::iterator end = summaries.end(); - vector<TH1*>::iterator histIt; - vector<TH1*>::iterator histEnd; - outFile->mkdir(channel.c_str()); + void saveInputs(TFile* outFile, std::string channel, vector<EstimateSummary> summaries){ + vector<EstimateSummary>::iterator it = summaries.begin(); + vector<EstimateSummary>::iterator end = summaries.end(); + vector<TH1*>::iterator histIt; + vector<TH1*>::iterator histEnd; + outFile->mkdir(channel.c_str()); - for(; it!=end; ++it){ - if(channel != it->channel){ - cout << "channel mismatch" << endl; - return; - } - outFile->cd(channel.c_str()); + for(; it!=end; ++it){ + if(channel != it->channel){ + cout << "channel mismatch" << std::endl; + return; + } + outFile->cd(channel.c_str()); - // write the EstimateSummary object - it->Write(); + // write the EstimateSummary object + it->Write(); - gDirectory->mkdir(it->name.c_str()); - gDirectory->cd(it->name.c_str()); + gDirectory->mkdir(it->name.c_str()); + gDirectory->cd(it->name.c_str()); - it->nominal->Write(); + it->nominal->Write(); - histIt = it->lowHists.begin(); - histEnd = it->lowHists.end(); - for(; histIt!=histEnd; ++histIt) - (*histIt)->Write(); + histIt = it->lowHists.begin(); + histEnd = it->lowHists.end(); + for(; histIt!=histEnd; ++histIt) + (*histIt)->Write(); - histIt = it->highHists.begin(); - histEnd = it->highHists.end(); - for(; histIt!=histEnd; ++histIt) - (*histIt)->Write(); + histIt = it->highHists.begin(); + histEnd = it->highHists.end(); + for(; histIt!=histEnd; ++histIt) + (*histIt)->Write(); + } } - } - TH1 * GetHisto( TFile * inFile, const string name ){ + TH1 * GetHisto( TFile * inFile, const std::string name ){ - if(!inFile || name.empty()){ - cerr << "Not all necessary info are set to access the input file. Check your config" << endl; - cerr << "fileptr: " << inFile - << "path/obj: " << name << endl; - return 0; - } - #ifdef DEBUG - cout << "Retrieving " << name ; - #endif - TH1 * ptr = (TH1 *) (inFile->Get( name.c_str() )->Clone()); - #ifdef DEBUG - cout << " found at " << ptr << " with integral " << ptr->Integral() << " and mean " << ptr->GetMean() << endl; - #endif - if (ptr) ptr->SetDirectory(0); // for the current histogram h - //TH1::AddDirectory(kFALSE); - return ptr; + if(!inFile || name.empty()){ + cerr << "Not all necessary info are set to access the input file. Check your config" << std::endl; + cerr << "fileptr: " << inFile + << "path/obj: " << name << std::endl; + return 0; + } +#ifdef DEBUG + cout << "Retrieving " << name ; +#endif + TH1 * ptr = (TH1 *) (inFile->Get( name.c_str() )->Clone()); +#ifdef DEBUG + cout << " found at " << ptr << " with integral " << ptr->Integral() << " and mean " << ptr->GetMean() << std::endl; +#endif + if (ptr) ptr->SetDirectory(0); // for the current histogram h + //TH1::AddDirectory(kFALSE); + return ptr; - } + } + + TH1 * GetHisto( const std::string file, const std::string path, const std::string obj){ + +#ifdef DEBUG + cout << "Retrieving " << file << ":" << path << obj ; +#endif + + TFile inFile(file.c_str()); + TH1 * ptr = (TH1 *) (inFile.Get( (path+obj).c_str() )->Clone()); + +#ifdef DEBUG + cout << " found at " << ptr << " with integral " << ptr->Integral() + << " and mean " << ptr->GetMean() << std::endl; +#endif + // if(file.empty() || path.empty() || obj.empty()){ + + if(!ptr){ + cerr << "Not all necessary info are set to access the input file. Check your config" + << std::endl; + cerr << "filename: " << file + << "path: " << path + << "obj: " << obj << std::endl; + } + else + ptr->SetDirectory(0); // for the current histogram h + + return ptr; - TH1 * GetHisto( const string file, const string path, const string obj){ - - #ifdef DEBUG - cout << "Retrieving " << file << ":" << path << obj ; - #endif - TFile inFile(file.c_str()); - TH1 * ptr = (TH1 *) (inFile.Get( (path+obj).c_str() )->Clone()); - #ifdef DEBUG - cout << " found at " << ptr << " with integral " << ptr->Integral() << " and mean " << ptr->GetMean() << endl; - #endif - // if(file.empty() || path.empty() || obj.empty()){ - if(!ptr){ - cerr << "Not all necessary info are set to access the input file. Check your config" << endl; - cerr << "filename: " << file - << "path: " << path - << "obj: " << obj << endl; } - else - ptr->SetDirectory(0); // for the current histogram h - return ptr; + void AddSubStrings( vector<std::string> & vs, std::string s){ + const std::string delims("\\ "); + std::string::size_type begIdx, endIdx; + begIdx=s.find_first_not_of(delims); + while(begIdx!=string::npos){ + endIdx=s.find_first_of(delims, begIdx); + if(endIdx==string::npos) endIdx=s.length(); + vs.push_back(s.substr(begIdx,endIdx-begIdx)); + begIdx=s.find_first_not_of(delims, endIdx); + } + } - } + // Turn a std::string of "children" (space separated items) + // into a vector of std::strings + std::vector<std::string> GetChildrenFromString( std::string str ) { + + std::vector<std::string> child_vec; + + const std::string delims("\\ "); + std::string::size_type begIdx, endIdx; + begIdx=str.find_first_not_of(delims); + while(begIdx!=string::npos){ + endIdx=str.find_first_of(delims, begIdx); + if(endIdx==string::npos) endIdx=str.length(); + std::string child_name = str.substr(begIdx,endIdx-begIdx); + child_vec.push_back(child_name); + begIdx=str.find_first_not_of(delims, endIdx); + } - void AddSubStrings( vector<string> & vs, string s){ - const string delims("\\ "); - string::size_type begIdx, endIdx; - begIdx=s.find_first_not_of(delims); - while(begIdx!=string::npos){ - endIdx=s.find_first_of(delims, begIdx); - if(endIdx==string::npos) endIdx=s.length(); - vs.push_back(s.substr(begIdx,endIdx-begIdx)); - begIdx=s.find_first_not_of(delims, endIdx); + return child_vec; } - } - /* - bool AddSummaries( vector<EstimateSummary> & channel, vector<vector<EstimateSummary> > &master){ - string channel_str=channel[0].channel; - for( unsigned int proc=1; proc < channel.size(); proc++){ + // Turn a std::string of "children" (space separated items) + // into a vector of std::strings + void AddParamsToAsimov( RooStats::HistFactory::Asimov& asimov, std::string str ) { + + // First, split the string into a list + // each describing a parameter + std::vector<std::string> string_list = GetChildrenFromString( str ); + + // Next, go through each one and split based + // on the '=' to separate the name from the val + // and fill the map + std::map<std::string, double> param_map; + + for( unsigned int i=0; i < string_list.size(); ++i) { + + std::string param = string_list.at(i); + // Split the string + size_t eql_location = param.find("="); + + // If there is no '=' deliminator, we only + // set the variable constant + if( eql_location==string::npos ) { + asimov.SetFixedParam(param); + } + else { + + std::string param_name = param.substr(0,eql_location); + double param_val = atof( param.substr(eql_location+1, param.size()).c_str() ); + + std::cout << "ASIMOV - Param Name: " << param_name + << " Param Val: " << param_val << std::endl; + // Give the params a value AND set them constant + asimov.SetParamValue(param_name, param_val); + asimov.SetFixedParam(param_name); + } + + } + + return; + + } + + + + /* + bool AddSummaries( vector<EstimateSummary> & channel, vector<vector<EstimateSummary> > &master){ + std::string channel_str=channel[0].channel; + for( unsigned int proc=1; proc < channel.size(); proc++){ if(channel[proc].channel != channel_str){ - std::cout << "Illegal channel description, should be " << channel_str << " but found " << channel.at(proc).channel << std::endl; - std::cout << "name " << channel.at(proc).name << std::endl; - exit(1); + std::cout << "Illegal channel description, should be " << channel_str << " but found " << channel.at(proc).channel << std::endl; + std::cout << "name " << channel.at(proc).name << std::endl; + exit(1); } master.push_back(channel); - } - return true; - }*/ + } + return true; + }*/ + // Looking to deprecate this function and convert entirely to Measurements + std::vector<EstimateSummary> GetChannelEstimateSummaries(Measurement& measurement, + Channel& channel) { -std::vector<EstimateSummary> GetChannelEstimateSummaries(Measurement& measurement, Channel& channel) { + // Convert a "Channel" into a list of "Estimate Summaries" + // This should only be a temporary function, as the + // EstimateSummary class should be deprecated - // Convert a "Channel" into a list of "Estimate Summaries" - // This should only be a temporary function, as the - // EstimateSummary class should be deprecated + std::vector<EstimateSummary> channel_estimateSummary; + std::cout << "Processing data: " << std::endl; - std::vector<EstimateSummary> channel_estimateSummary; + // Add the data + EstimateSummary data_es; + data_es.name = "Data"; + data_es.channel = channel.GetName(); + TH1* data_hist = (TH1*) channel.GetData().GetHisto(); + if( data_hist != NULL ) { + //data_es.nominal = (TH1*) channel.GetData().GetHisto()->Clone(); + data_es.nominal = data_hist; + channel_estimateSummary.push_back( data_es ); + } - std::cout << "Processing data: " << std::endl; + // Add the samples + for( unsigned int sampleItr = 0; sampleItr < channel.GetSamples().size(); ++sampleItr ) { - // Add the data - EstimateSummary data_es; - data_es.name = "Data"; - data_es.channel = channel.GetName(); - data_es.nominal = (TH1*) channel.GetData().GetHisto()->Clone(); - channel_estimateSummary.push_back( data_es ); + EstimateSummary sample_es; + RooStats::HistFactory::Sample& sample = channel.GetSamples().at( sampleItr ); - // Add the samples - for( unsigned int sampleItr = 0; sampleItr < channel.GetSamples().size(); ++sampleItr ) { + std::cout << "Processing sample: " << sample.GetName() << std::endl; - EstimateSummary sample_es; - RooStats::HistFactory::Sample& sample = channel.GetSamples().at( sampleItr ); + // Define the mapping + sample_es.name = sample.GetName(); + sample_es.channel = sample.GetChannelName(); + sample_es.nominal = (TH1*) sample.GetHisto()->Clone(); - std::cout << "Processing sample: " << sample.GetName() << std::endl; + std::cout << "Checking NormalizeByTheory" << std::endl; - // Define the mapping - sample_es.name = sample.GetName(); - sample_es.channel = sample.GetChannelName(); - sample_es.nominal = (TH1*) sample.GetHisto()->Clone(); + if( sample.GetNormalizeByTheory() ) { + sample_es.normName = "" ; // Really bad, confusion convention + } + else { + TString lumiStr; + lumiStr += measurement.GetLumi(); + lumiStr.ReplaceAll(' ', TString()); + sample_es.normName = lumiStr ; + } - std::cout << "Checking NormalizeByTheory" << std::endl; + std::cout << "Setting the Histo Systs" << std::endl; - if( sample.GetNormalizeByTheory() ) { - sample_es.normName = "" ; // Really bad, confusion convention - } - else { - TString lumiStr; - lumiStr += measurement.GetLumi(); - lumiStr.ReplaceAll(' ', TString()); - sample_es.normName = lumiStr ; - } + // Set the Histo Systs: + for( unsigned int histoItr = 0; histoItr < sample.GetHistoSysList().size(); ++histoItr ) { - std::cout << "Setting the Histo Systs" << std::endl; + RooStats::HistFactory::HistoSys& histoSys = sample.GetHistoSysList().at( histoItr ); - // Set the Histo Systs: - for( unsigned int histoItr = 0; histoItr < sample.GetHistoSysList().size(); ++histoItr ) { + sample_es.systSourceForHist.push_back( histoSys.GetName() ); + sample_es.lowHists.push_back( (TH1*) histoSys.GetHistoLow()->Clone() ); + sample_es.highHists.push_back( (TH1*) histoSys.GetHistoHigh()->Clone() ); - RooStats::HistFactory::HistoSys& histoSys = sample.GetHistoSysList().at( histoItr ); + } - sample_es.systSourceForHist.push_back( histoSys.GetName() ); - sample_es.lowHists.push_back( (TH1*) histoSys.GetHistoLow()->Clone() ); - sample_es.highHists.push_back( (TH1*) histoSys.GetHistoHigh()->Clone() ); + std::cout << "Setting the NormFactors" << std::endl; - } + for( unsigned int normItr = 0; normItr < sample.GetNormFactorList().size(); ++normItr ) { - std::cout << "Setting the NormFactors" << std::endl; + RooStats::HistFactory::NormFactor& normFactor = sample.GetNormFactorList().at( normItr ); - for( unsigned int normItr = 0; normItr < sample.GetNormFactorList().size(); ++normItr ) { + EstimateSummary::NormFactor normFactor_es; + normFactor_es.name = normFactor.GetName(); + normFactor_es.val = normFactor.GetVal(); + normFactor_es.high = normFactor.GetHigh(); + normFactor_es.low = normFactor.GetLow(); + normFactor_es.constant = normFactor.GetConst(); + + sample_es.normFactor.push_back( normFactor_es ); - RooStats::HistFactory::NormFactor& normFactor = sample.GetNormFactorList().at( normItr ); + } - EstimateSummary::NormFactor normFactor_es; - normFactor_es.name = normFactor.GetName(); - normFactor_es.val = normFactor.GetVal(); - normFactor_es.high = normFactor.GetHigh(); - normFactor_es.low = normFactor.GetLow(); - normFactor_es.constant = normFactor.GetConst(); - + std::cout << "Setting the OverallSysList" << std::endl; - sample_es.normFactor.push_back( normFactor_es ); + for( unsigned int sysItr = 0; sysItr < sample.GetOverallSysList().size(); ++sysItr ) { - } + RooStats::HistFactory::OverallSys& overallSys = sample.GetOverallSysList().at( sysItr ); - std::cout << "Setting the OverallSysList" << std::endl; + std::pair<double, double> DownUpPair( overallSys.GetLow(), overallSys.GetHigh() ); + sample_es.overallSyst[ overallSys.GetName() ] = DownUpPair; // - for( unsigned int sysItr = 0; sysItr < sample.GetOverallSysList().size(); ++sysItr ) { + } - RooStats::HistFactory::OverallSys& overallSys = sample.GetOverallSysList().at( sysItr ); + std::cout << "Checking Stat Errors" << std::endl; - std::pair<double, double> DownUpPair( overallSys.GetLow(), overallSys.GetHigh() ); - sample_es.overallSyst[ overallSys.GetName() ] = DownUpPair; // + // Do Stat Error + sample_es.IncludeStatError = sample.GetStatError().GetActivate(); - } + // Set the error and error threshold + sample_es.RelErrorThreshold = channel.GetStatErrorConfig().GetRelErrorThreshold(); + if( sample.GetStatError().GetErrorHist() ) { + sample_es.relStatError = (TH1*) sample.GetStatError().GetErrorHist()->Clone(); + } + else { + sample_es.relStatError = NULL; + } - std::cout << "Checking Stat Errors" << std::endl; - // Do Stat Error - sample_es.IncludeStatError = sample.GetStatError().GetActivate(); + // Set the constraint type; + Constraint::Type type = channel.GetStatErrorConfig().GetConstraintType(); - // Set the error and error threshold - sample_es.RelErrorThreshold = channel.GetStatErrorConfig().GetRelErrorThreshold(); - if( sample.GetStatError().GetErrorHist() ) { - sample_es.relStatError = (TH1*) sample.GetStatError().GetErrorHist()->Clone(); - } - else { - sample_es.relStatError = NULL; - } + // Set the default + sample_es.StatConstraintType = EstimateSummary::Gaussian; + if( type == Constraint::Gaussian) { + std::cout << "Using Gaussian StatErrors" << std::endl; + sample_es.StatConstraintType = EstimateSummary::Gaussian; + } + if( type == Constraint::Poisson ) { + std::cout << "Using Poisson StatErrors" << std::endl; + sample_es.StatConstraintType = EstimateSummary::Poisson; + } - // Set the constraint type; - Constraint::Type type = channel.GetStatErrorConfig().GetConstraintType(); - // Set the default - sample_es.StatConstraintType = EstimateSummary::Gaussian; + std::cout << "Getting the shape Factor" << std::endl; - if( type == Constraint::Gaussian) { - std::cout << "Using Gaussian StatErrors" << std::endl; - sample_es.StatConstraintType = EstimateSummary::Gaussian; - } - if( type == Constraint::Poisson ) { - std::cout << "Using Poisson StatErrors" << std::endl; - sample_es.StatConstraintType = EstimateSummary::Poisson; - } + // Get the shape factor + if( sample.GetShapeFactorList().size() > 0 ) { + sample_es.shapeFactorName = sample.GetShapeFactorList().at(0).GetName(); + } + if( sample.GetShapeFactorList().size() > 1 ) { + std::cout << "Error: Only One Shape Factor currently supported" << std::endl; + throw hf_exc(); + } - std::cout << "Getting the shape Factor" << std::endl; + std::cout << "Setting the ShapeSysts" << std::endl; + + // Get the shape systs: + for( unsigned int shapeItr=0; shapeItr < sample.GetShapeSysList().size(); ++shapeItr ) { + + RooStats::HistFactory::ShapeSys& shapeSys = sample.GetShapeSysList().at( shapeItr ); + + EstimateSummary::ShapeSys shapeSys_es; + shapeSys_es.name = shapeSys.GetName(); + shapeSys_es.hist = shapeSys.GetErrorHist(); + + // Set the constraint type; + Constraint::Type systype = shapeSys.GetConstraintType(); + + // Set the default + shapeSys_es.constraint = EstimateSummary::Gaussian; + + if( systype == Constraint::Gaussian) { + shapeSys_es.constraint = EstimateSummary::Gaussian; + } + if( systype == Constraint::Poisson ) { + shapeSys_es.constraint = EstimateSummary::Poisson; + } + + sample_es.shapeSysts.push_back( shapeSys_es ); + + } + + std::cout << "Adding this sample" << std::endl; + + // Push back + channel_estimateSummary.push_back( sample_es ); + + } + + return channel_estimateSummary; - // Get the shape factor - if( sample.GetShapeFactorList().size() > 0 ) { - sample_es.shapeFactorName = sample.GetShapeFactorList().at(0).GetName(); - } - if( sample.GetShapeFactorList().size() > 1 ) { - std::cout << "Error: Only One Shape Factor currently supported" << std::endl; - throw bad_hf; } - std::cout << "Setting the ShapeSysts" << std::endl; - // Get the shape systs: - for( unsigned int shapeItr=0; shapeItr < sample.GetShapeSysList().size(); ++shapeItr ) { + /* + void unfoldConstraints(RooArgSet& initial, RooArgSet& final, RooArgSet& obs, RooArgSet& nuis, int& counter) { + // + // Loop through an initial set of constraints + // and create a final list of constraints + // This is done recursively + + + if (counter > 50) { + cout << "ERROR::Couldn't unfold constraints!" << std::endl; + cout << "Initial: " << std::endl; + initial.Print("v"); + cout << std::endl; + cout << "Final: " << std::endl; + final.Print("v"); + return; + } + + TIterator* itr = initial.createIterator(); + RooAbsPdf* pdf; + while ((pdf = (RooAbsPdf*)itr->Next())) { + RooArgSet nuis_tmp = nuis; + RooArgSet constraint_set(*pdf->getAllConstraints(obs, nuis_tmp, false)); + //if (constraint_set.getSize() > 1) + //{ + string className(pdf->ClassName()); + if (className != "RooGaussian" && className != "RooLognormal" && className != "RooGamma" && className != "RooPoisson" && className != "RooBifurGauss") { + counter++; + unfoldConstraints(constraint_set, final, obs, nuis, counter); + } + else { + final.add(*pdf); + } + } + delete itr; + } + */ + /* + RooAbsData* makeAsimovData(ModelConfig* mcInWs, bool doConditional, RooWorkspace* combWS, + RooAbsPdf* combPdf, RooDataSet* combData, bool b_only, double doMuHat, + double muVal, bool signalInjection, bool doNuisPro) { + //////////////////// + //make asimov data// + //////////////////// + + // mcInWs -> The ModelCofig for this likelihood + // doConditional -> Minimize parameters for asimov quantities + // b_only -> Make the 'background only' asimov dataset, ie mu=0 (set muVal = 0) + // doNuisPro -> Set all nuisance parameters to '0' and to constant + // before minimizing. This should be done with *care*!! + // i.e. It should probably be removed as an option. + // signalInjection -> If true, then do the following: + // Perform the fit with m=0 + // After the fit, set the value to mu=muVal + // so that the asimov is created with that value of mu fixed + // doMuHat -> Set 'mu' to be float during the fit (in the range -10 to 100) + // Even if it floats in the fit, it is still set to + // 'muVal' before the dataset is made (so the only difference + // comes from the other parameters that can float simultaneously with mu + + // Defaults: + // double doMuHat = false + // double muVal = -999, + // bool signalInjection = false + // bool doNuisPro = true + + if( b_only ) muVal = 0.0; + + int _printLevel = 0; + + // If using signal injection or a non-zero mu value, + // add a suffix showing that value + std::stringstream muStr; + if(signalInjection || !b_only) { + muStr << "_" << muVal; + } + + // Create the name of the resulting dataset + std::string dataSetName; + if(signalInjection) dataSetName = "signalInjection" + muStr.str(); + else dataSetName = "asimovData" + muStr.str(); + + // Set the parameter of interest + // to the 'background' value + RooRealVar* mu = (RooRealVar*) mcInWs->GetParametersOfInterest()->first(); + if(signalInjection){ + std::cout << "Asimov: Setting " << mu->GetName() << " value to 0 for fit" << std::endl; + mu->setVal(0); + } + else { + std::cout << "Asimov: Setting " << mu->GetName() << " value to " << muVal << " for fit" << std::endl; + mu->setVal(muVal); + } - RooStats::HistFactory::ShapeSys& shapeSys = sample.GetShapeSysList().at( shapeItr ); + // Get necessary info from the ModelConfig + RooArgSet mc_obs = *mcInWs->GetObservables(); + RooArgSet mc_globs = *mcInWs->GetGlobalObservables(); + RooArgSet mc_nuis = *mcInWs->GetNuisanceParameters(); + + // Create a set of constraint terms, which + // is stored in 'constraint_set' + // Make some temporary variables and use the + // unfoldConstrants function to do this. + RooArgSet constraint_set; + int counter_tmp = 0; + RooArgSet mc_nuis_tmp = mc_nuis; + RooArgSet constraint_set_tmp(*combPdf->getAllConstraints(mc_obs, mc_nuis_tmp, false)); + unfoldConstraints(constraint_set_tmp, constraint_set, mc_obs, mc_nuis_tmp, counter_tmp); + + // Now that we have the constraint terms, we + // can create the full lists of nuisance parameters + // and global variables + RooArgList nui_list("ordered_nuis"); + RooArgList glob_list("ordered_globs"); + + TIterator* cIter = constraint_set.createIterator(); + RooAbsArg* arg; + while ((arg = (RooAbsArg*)cIter->Next())) { + RooAbsPdf* pdf = (RooAbsPdf*) arg; + if (!pdf) continue; + + TIterator* nIter = mc_nuis.createIterator(); + RooRealVar* thisNui = NULL; + RooAbsArg* nui_arg; + while((nui_arg = (RooAbsArg*)nIter->Next())) { + if(pdf->dependsOn(*nui_arg)) { + thisNui = (RooRealVar*) nui_arg; + break; + } + } + delete nIter; + + // need this in case the observable isn't fundamental. + // in this case, see which variable is dependent on the nuisance parameter and use that. + RooArgSet* components = pdf->getComponents(); + components->remove(*pdf); + if(components->getSize()) { + TIterator* itr1 = components->createIterator(); + RooAbsArg* arg1; + while ((arg1 = (RooAbsArg*)itr1->Next())) { + TIterator* itr2 = components->createIterator(); + RooAbsArg* arg2; + while ((arg2 = (RooAbsArg*)itr2->Next())) { + if(arg1 == arg2) continue; + if(arg2->dependsOn(*arg1)) { + components->remove(*arg1); + } + } + delete itr2; + } + delete itr1; + } + if (components->getSize() > 1) { + std::cout << "ERROR::Couldn't isolate proper nuisance parameter" << std::endl; + return NULL; + } + else if (components->getSize() == 1) { + thisNui = (RooRealVar*)components->first(); + } + + TIterator* gIter = mc_globs.createIterator(); + RooRealVar* thisGlob = NULL; + RooAbsArg* glob_arg; + while ((glob_arg = (RooAbsArg*)gIter->Next())) + { + if (pdf->dependsOn(*glob_arg)) + { + thisGlob = (RooRealVar*)glob_arg; + break; + } + } + delete gIter; + + if (!thisNui || !thisGlob) + { + std::cout << "WARNING::Couldn't find nui or glob for constraint: " << pdf->GetName() << std::endl; + continue; + } + + if (_printLevel >= 1) std::cout << "Pairing nui: " << thisNui->GetName() << ", with glob: " << thisGlob->GetName() << ", from constraint: " << pdf->GetName() << std::endl; + + nui_list.add(*thisNui); + glob_list.add(*thisGlob); + + } // End Loop over Constraint Terms + delete cIter; + + //save the snapshots of nominal parameters + combWS->saveSnapshot("nominalGlobs",glob_list); + combWS->saveSnapshot("nominalNuis", nui_list); + + RooArgSet nuiSet_tmp(nui_list); + + // Interesting line here: + if(!doMuHat) { + std::cout << "Asimov: Setting mu constant in fit" << std::endl; + mu->setConstant(true); + } + else { + std::cout << "Asimov: Letting mu float in fit (muHat)" << std::endl; + mu->setRange(-10,100); + } - EstimateSummary::ShapeSys shapeSys_es; - shapeSys_es.name = shapeSys.GetName(); - shapeSys_es.hist = shapeSys.GetErrorHist(); + // Conditional: "Minimize the parameters" + if(doConditional) { + + std::cout << "Starting minimization.." << std::endl; + + // Consider removing this option: + if(!doNuisPro) { + std::cout << "Asimov: Setting nuisance parameters constant in the fit (ARE YOU SURE YOU WANT THIS)" << std::endl; + TIterator* nIter = nuiSet_tmp.createIterator(); + RooRealVar* thisNui = NULL; + while((thisNui = (RooRealVar*) nIter->Next())) { + thisNui->setVal(0); + thisNui->setConstant(); + } + delete nIter; + // This should be checked, we don't want to + if(combWS->var("Lumi")) { + combWS->var("Lumi")->setVal(1); + combWS->var("Lumi")->setConstant(); + } + } + + // Create the nll and its minimizer + RooAbsReal* nll = combPdf->createNLL(*combData, RooFit::Constrain(nuiSet_tmp)); + RooMinimizer minim(*nll); + minim.setStrategy(2); + minim.setPrintLevel(999); + + // Do the minimization + std::cout << "Minimizing to make Asimov dataset:" << std::endl; + int status = minim.minimize(ROOT::Math::MinimizerOptions::DefaultMinimizerType().c_str(), "migrad"); + if (status == 0) { + // status==0 means fit was successful + std::cout << "Successfully minimized to make Asimov dataset:" << std::endl; + RooFitResult* fit_result = minim.lastMinuitFit(); + std::cout << "Asimov: Final Fitted Parameters" << std::endl; + fit_result->Print("V"); + } else{ + std::cout << "Fit failed for mu = " << mu->getVal() << " with status " << status << std::endl; + std::cout << "Trying minuit..." << std::endl; + status = minim.minimize("Minuit", "migrad"); + if (status != 0) { + cout << "Fit failed for mu = " << mu->getVal() << " with status " << status << std::endl; + throw hf_exc(); + } + } + + // Undo the 'doNuisPro' part + // Again, may want to remove this + if (!doNuisPro) { + TIterator* nIter = nuiSet_tmp.createIterator(); + RooRealVar* thisNui = NULL; + while ((thisNui = (RooRealVar*)nIter->Next())) { + thisNui->setConstant(false); + } + delete nIter; + if (combWS->var("Lumi")) { + combWS->var("Lumi")->setConstant(false); + } + } + + std::cout << "Done" << std::endl; + } // END: DoConditional + + mu->setConstant(false); + + //loop over the nui/glob list, grab the corresponding variable from the tmp ws, + // and set the glob to the value of the nui + int nrNuis = nui_list.getSize(); + if (nrNuis != glob_list.getSize()) { + std::cout << "ERROR::nui_list.getSize() != glob_list.getSize()!" << std::endl; + return NULL; + } - // Set the constraint type; - Constraint::Type systype = shapeSys.GetConstraintType(); + for(int i=0; i<nrNuis; i++) { + RooRealVar* nui = (RooRealVar*) nui_list.at(i); + RooRealVar* glob = (RooRealVar*) glob_list.at(i); - // Set the default - shapeSys_es.constraint = EstimateSummary::Gaussian; + if (_printLevel >= 1) std::cout << "nui: " << nui << ", glob: " << glob << std::endl; + if (_printLevel >= 1) std::cout << "Setting glob: " << glob->GetName() << ", which had previous val: " << glob->getVal() << ", to conditional val: " << nui->getVal() << std::endl; - if( systype == Constraint::Gaussian) { - shapeSys_es.constraint = EstimateSummary::Gaussian; + glob->setVal(nui->getVal()); } - if( systype == Constraint::Poisson ) { - shapeSys_es.constraint = EstimateSummary::Poisson; + + //save the snapshots of conditional parameters + //cout << "Saving conditional snapshots" << std::endl; + combWS->saveSnapshot(("conditionalGlobs"+muStr.str()).c_str(),glob_list); + combWS->saveSnapshot(("conditionalNuis" +muStr.str()).c_str(), nui_list); + + if(!doConditional) { + combWS->loadSnapshot("nominalGlobs"); + combWS->loadSnapshot("nominalNuis"); } - sample_es.shapeSysts.push_back( shapeSys_es ); + //cout << "Making asimov" << std::endl; + //make the asimov data (snipped from Kyle) - } + // Restore the value of mu to the target value + mu->setVal(muVal); - std::cout << "Adding this sample" << std::endl; + ModelConfig* mc = mcInWs; - // Push back - channel_estimateSummary.push_back( sample_es ); + int iFrame=0; - } + const char* weightName = "weightVar"; + RooArgSet obsAndWeight; + obsAndWeight.add(*mc->GetObservables()); - return channel_estimateSummary; + // Get the weightVar, or create one if necessary + RooRealVar* weightVar = combWS->var(weightName); // NULL; + // if (!(weightVar = combWS->var(weightName))) + if( weightVar==NULL ) { + combWS->import(*(new RooRealVar(weightName, weightName, 1,0,1000))); + weightVar = combWS->var(weightName); + } + if (_printLevel >= 1) std::cout << "weightVar: " << weightVar << std::endl; + obsAndWeight.add(*combWS->var(weightName)); -} + ////////////////////////////////////////////////////// + ////////////////////////////////////////////////////// + ////////////////////////////////////////////////////// + ////////////////////////////////////////////////////// + ////////////////////////////////////////////////////// + // MAKE ASIMOV DATA FOR OBSERVABLES + // dummy var can just have one bin since it's a dummy + if(combWS->var("ATLAS_dummyX")) combWS->var("ATLAS_dummyX")->setBins(1); + if (_printLevel >= 1) std::cout << " check expectedData by category" << std::endl; + RooSimultaneous* simPdf = dynamic_cast<RooSimultaneous*>(mc->GetPdf()); + // Create the pointer to be returned + RooDataSet* asimovData=NULL; + // If the pdf isn't simultaneous: + if(!simPdf) { + // Get pdf associated with state from simpdf + RooAbsPdf* pdftmp = mc->GetPdf();//simPdf->getPdf(channelCat->getLabel()) ; + + // Generate observables defined by the pdf associated with this state + RooArgSet* obstmp = pdftmp->getObservables(*mc->GetObservables()) ; -} + if (_printLevel >= 1) { + obstmp->Print(); + } + + + asimovData = new RooDataSet(dataSetName.c_str(), dataSetName.c_str(), + RooArgSet(obsAndWeight), RooFit::WeightVar(*weightVar)); + + RooRealVar* thisObs = ((RooRealVar*)obstmp->first()); + double expectedEvents = pdftmp->expectedEvents(*obstmp); + double thisNorm = 0; + for(int jj=0; jj<thisObs->numBins(); ++jj){ + thisObs->setBin(jj); + + thisNorm=pdftmp->getVal(obstmp)*thisObs->getBinWidth(jj); + if (thisNorm*expectedEvents <= 0) + { + cout << "WARNING::Detected bin with zero expected events (" << thisNorm*expectedEvents << ") ! Please check your inputs. Obs = " << thisObs->GetName() << ", bin = " << jj << std::endl; + } + if (thisNorm*expectedEvents > 0 && thisNorm*expectedEvents < pow(10.0, 18)) asimovData->add(*mc->GetObservables(), thisNorm*expectedEvents); + } + + if (_printLevel >= 1) + { + asimovData->Print(); + std::cout <<"sum entries "<<asimovData->sumEntries()<<endl; + } + if(asimovData->sumEntries()!=asimovData->sumEntries()){ + std::cout << "sum entries is nan"<<endl; + exit(1); + } + + // don't import, return (of course) + //combWS->import(*asimovData); + } + else + { + + // If it IS a simultaneous pdf + + std::cout << "found a simPdf: " << simPdf << std::endl; + map<std::string, RooDataSet*> asimovDataMap; + + RooCategory* channelCat = (RooCategory*)&simPdf->indexCat(); + TIterator* iter = channelCat->typeIterator() ; + RooCatType* tt = NULL; + int nrIndices = 0; + while((tt=(RooCatType*) iter->Next())) { + nrIndices++; + } + + for (int i=0;i<nrIndices;i++){ + + channelCat->setIndex(i); + + std::cout << "Checking channel: " << channelCat->getLabel() << std::endl; + iFrame++; + // Get pdf associated with state from simpdf + RooAbsPdf* pdftmp = simPdf->getPdf(channelCat->getLabel()) ; + + // Generate observables defined by the pdf associated with this state + RooArgSet* obstmp = pdftmp->getObservables(*mc->GetObservables()) ; + + if (_printLevel >= 1) { + obstmp->Print(); + cout << "on type " << channelCat->getLabel() << " " << iFrame << std::endl; + } + + RooDataSet* obsDataUnbinned = new RooDataSet(Form("combAsimovData%d",iFrame),Form("combAsimovData%d",iFrame), + RooArgSet(obsAndWeight,*channelCat), RooFit::WeightVar(*weightVar)); + RooRealVar* thisObs = ((RooRealVar*)obstmp->first()); + double expectedEvents = pdftmp->expectedEvents(*obstmp); + double thisNorm = 0; + TString pdftmp_name = pdftmp->GetName(); + + if (!expectedEvents) { + std::cout << "Not expected events" << std::endl; + if (pdftmp_name == "model_E") + ((RooRealVar*)obstmp->first())->setVal(combWS->function("p_e")->getVal()); + + else if (pdftmp_name == "model_MU") + ((RooRealVar*)obstmp->first())->setVal(combWS->function("p_mu")->getVal()); + + else if ((pdftmp_name == "model_ratio_ELMU") || (pdftmp_name == "model_comb")) { + //((RooRealVar*)obstmp->first())->setVal(combWS->function("p_comb")->getVal()); + double p_asimov_val = combWS->var("p_asimov")->getVal(); + std::cout << "p_asimov val: " << p_asimov_val << std::endl; + ((RooRealVar*)obstmp->first())->setVal(combWS->var("p_asimov")->getVal()); + } + + else { + std::cout << "Failed to set asimov data for non-extended pdf" << std::endl; + exit(1); + } + obsDataUnbinned->add(*mc->GetObservables()); + + } + else { + std::cout << "expected events" << std::endl; + for(int jj=0; jj<thisObs->numBins(); ++jj){ + thisObs->setBin(jj); + + thisNorm=pdftmp->getVal(obstmp)*thisObs->getBinWidth(jj); + if (thisNorm*expectedEvents <= 0) + { + std::cout << "WARNING::Detected bin with zero expected events (" << thisNorm*expectedEvents << ") ! Please check your inputs. Obs = " << thisObs->GetName() << ", bin = " << jj << std::endl; + } + if (thisNorm*expectedEvents > pow(10.0, -9) && thisNorm*expectedEvents < pow(10.0, 9)) obsDataUnbinned->add(*mc->GetObservables(), thisNorm*expectedEvents); + } + } + + if (_printLevel >= 1) + { + obsDataUnbinned->Print(); + std::cout <<"sum entries "<<obsDataUnbinned->sumEntries()<<endl; + } + if(obsDataUnbinned->sumEntries()!=obsDataUnbinned->sumEntries()){ + cout << "sum entries is nan"<<endl; + exit(1); + } + + asimovDataMap[string(channelCat->getLabel())] = obsDataUnbinned;//tempData; + + if (_printLevel >= 1) + { + std::cout << "channel: " << channelCat->getLabel() << ", data: "; + obsDataUnbinned->Print(); + std::cout << std::endl; + } + } + + channelCat->setIndex(0); + + asimovData = new RooDataSet(dataSetName.c_str(),dataSetName.c_str(), + RooArgSet(obsAndWeight,*channelCat), RooFit::Index(*channelCat), + RooFit::Import(asimovDataMap), RooFit::WeightVar(*weightVar)); + + // Don't import, return (of course) + //combWS->import(*asimovData); + } // End if over simultaneous pdf + + combWS->loadSnapshot("nominalNuis"); + combWS->loadSnapshot("nominalGlobs"); + + return asimovData; + + } + */ + } } diff --git a/roofit/histfactory/src/Helper.h b/roofit/histfactory/src/Helper.h index 9eb17dae175a2..4f15e495989af 100644 --- a/roofit/histfactory/src/Helper.h +++ b/roofit/histfactory/src/Helper.h @@ -21,23 +21,42 @@ #include "RooStats/HistFactory/Measurement.h" #include "RooStats/HistFactory/HistFactoryException.h" #include "RooWorkspace.h" +#include "RooStats/ModelConfig.h" +#include "RooDataSet.h" -using namespace std; - namespace RooStats{ -namespace HistFactory{ - vector<EstimateSummary>* loadSavedInputs(TFile* outFile, string channel ); - void saveInputs(TFile* outFile, string channel, vector<EstimateSummary> summaries); - TH1 * GetHisto( TFile * inFile, const string name ); - TH1 * GetHisto( const string file, const string path, const string obj ); - bool AddSummaries( vector<EstimateSummary> & summary, vector<vector<EstimateSummary> > &master); - vector<pair<string, string> > get_comb(vector<string> names); - void AddSubStrings( vector<string> & vs, string s); + namespace HistFactory{ - std::vector<EstimateSummary> GetChannelEstimateSummaries(Measurement& measurement, Channel& channel); + std::vector<EstimateSummary>* loadSavedInputs(TFile* outFile, std::string channel ); + void saveInputs(TFile* outFile, std::string channel, std::vector<EstimateSummary> summaries); + TH1 * GetHisto( TFile * inFile, const std::string name ); + + TH1 * GetHisto( const std::string file, const std::string path, const std::string obj ); + + bool AddSummaries( std::vector<EstimateSummary> & summary, std::vector<std::vector<EstimateSummary> > &master); + + std::vector<std::pair<std::string, std::string> > get_comb(std::vector<std::string> names); + + void AddSubStrings( std::vector<std::string> & vs, std::string s); + + std::vector<std::string> GetChildrenFromString( std::string str ); + + //void AddStringValPairToMap( std::map<std::string, double>& map, double val, std::string children); + + std::vector<EstimateSummary> GetChannelEstimateSummaries(Measurement& measurement, Channel& channel); + + + void AddParamsToAsimov( RooStats::HistFactory::Asimov& asimov, std::string str ); + + /* + RooAbsData* makeAsimovData(ModelConfig* mcInWs, bool doConditional, RooWorkspace* combWS, RooAbsPdf* combPdf, RooDataSet* combData, bool b_only, double doMuHat = false, double muVal = -999, bool signalInjection = false, bool doNuisPro = true); + void unfoldConstraints(RooArgSet& initial, RooArgSet& final, RooArgSet& obs, RooArgSet& nuis, int& counter); + */ + + } } -} + #endif diff --git a/roofit/histfactory/src/HistFactoryModelUtils.cxx b/roofit/histfactory/src/HistFactoryModelUtils.cxx new file mode 100644 index 0000000000000..38e97ab51315b --- /dev/null +++ b/roofit/histfactory/src/HistFactoryModelUtils.cxx @@ -0,0 +1,424 @@ + +// A set of utils for navegating HistFactory models +#include <stdexcept> +#include <typeinfo> + +#include "RooStats/HistFactory/ParamHistFunc.h" +#include "TIterator.h" +#include "RooAbsArg.h" +#include "RooAbsPdf.h" +#include "RooArgSet.h" +#include "RooArgList.h" +#include "RooSimultaneous.h" +#include "RooCategory.h" +#include "RooRealVar.h" +#include "RooProdPdf.h" +#include "TH1.h" + +#include "RooStats/HistFactory/HistFactorySimultaneous.h" +#include "RooStats/HistFactory/HistFactoryModelUtils.h" + +namespace RooStats{ +namespace HistFactory{ + + + std::string channelNameFromPdf( RooAbsPdf* channelPdf ) { + std::string channelPdfName = channelPdf->GetName(); + std::string ChannelName = channelPdfName.substr(6, channelPdfName.size() ); + return ChannelName; + } + + RooAbsPdf* getSumPdfFromChannel( RooAbsPdf* sim_channel ) { + + bool verbose=false; + + if(verbose) std::cout << "Getting the RooRealSumPdf for the channel: " + << sim_channel->GetName() << std::endl; + + std::string channelPdfName = sim_channel->GetName(); + std::string ChannelName = channelPdfName.substr(6, channelPdfName.size() ); + + // Now, get the RooRealSumPdf + // ie the channel WITHOUT constraints + std::string realSumPdfName = ChannelName + "_model"; + + RooAbsPdf* sum_pdf = NULL; + TIterator* iter_sum_pdf = sim_channel->getComponents()->createIterator(); //serverIterator(); + bool FoundSumPdf=false; + RooAbsArg* sum_pdf_arg=NULL; + while((sum_pdf_arg=(RooAbsArg*)iter_sum_pdf->Next())) { + std::string NodeClassName = sum_pdf_arg->ClassName(); + if( NodeClassName == std::string("RooRealSumPdf") ) { + FoundSumPdf=true; + sum_pdf = (RooAbsPdf*) sum_pdf_arg; + break; + } + } + if( ! FoundSumPdf ) { + if(verbose) { + std::cout << "Failed to find RooRealSumPdf for channel: " << sim_channel->GetName() << std::endl; + sim_channel->getComponents()->Print("V"); + } + sum_pdf=NULL; + //throw std::runtime_error("Failed to find RooRealSumPdf for channel"); + } + else { + if(verbose) std::cout << "Found RooRealSumPdf: " << sum_pdf->GetName() << std::endl; + } + delete iter_sum_pdf; + iter_sum_pdf = NULL; + + return sum_pdf; + + } + + + void FactorizeHistFactoryPdf(const RooArgSet &observables, RooAbsPdf &pdf, RooArgList &obsTerms, RooArgList &constraints) { + // utility function to factorize constraint terms from a pdf + // (from G. Petrucciani) + const std::type_info & id = typeid(pdf); + if (id == typeid(RooProdPdf)) { + RooProdPdf *prod = dynamic_cast<RooProdPdf *>(&pdf); + RooArgList list(prod->pdfList()); + for (int i = 0, n = list.getSize(); i < n; ++i) { + RooAbsPdf *pdfi = (RooAbsPdf *) list.at(i); + FactorizeHistFactoryPdf(observables, *pdfi, obsTerms, constraints); + } + } else if (id == typeid(RooSimultaneous) || id == typeid(HistFactorySimultaneous) ) { //|| id == typeid(RooSimultaneousOpt)) { + RooSimultaneous *sim = dynamic_cast<RooSimultaneous *>(&pdf); + RooAbsCategoryLValue *cat = (RooAbsCategoryLValue *) sim->indexCat().Clone(); + for (int ic = 0, nc = cat->numBins((const char *)0); ic < nc; ++ic) { + cat->setBin(ic); + FactorizeHistFactoryPdf(observables, *sim->getPdf(cat->getLabel()), obsTerms, constraints); + } + delete cat; + } else if (pdf.dependsOn(observables)) { + if (!obsTerms.contains(pdf)) obsTerms.add(pdf); + } else { + if (!constraints.contains(pdf)) constraints.add(pdf); + } + } + + /* + void getChannelsFromModel( RooAbsPdf* model, RooArgSet* channels, RooArgSet* channelsWithConstraints ) { + + // Loop through the model + // Find all channels + + std::string modelClassName = model->ClassName(); + + if( modelClassName == std::string("RooSimultaneous") || model->InheritsFrom("RooSimultaneous") ) { + + TIterator* simServerItr = model->serverIterator(); + + // Loop through the child nodes of the sim pdf + // and find the channel nodes + RooAbsArg* sim_channel_arg = NULL; + while(( sim_channel = (RooAbsArg*) simServerItr->Next() )) { + + RooAbsPdf* sim_channel = (RooAbsPdf*) sim_channel_arg; + + // Ignore the Channel Cat + std::string channelPdfName = sim_channel->GetName(); + std::string channelClassName = sim_channel->ClassName(); + if( channelClassName == std::string("RooCategory") ) continue; + + // If we got here, we found a channel. + // Format is model_<ChannelName> + + std::string ChannelName = channelPdfName.substr(6, channelPdfName.size() ); + + // Now, get the RooRealSumPdf + RooAbsPdf* sum_pdf = getSumPdfFromChannel( sim_channel ); + + + / * + // Now, get the RooRealSumPdf + // ie the channel WITHOUT constraints + + std::string realSumPdfName = ChannelName + "_model"; + + RooAbsPdf* sum_pdf = NULL; + TIterator* iter_sum_pdf = sim_channel->getComponents()->createIterator(); //serverIterator(); + bool FoundSumPdf=false; + RooAbsArg* sum_pdf_arg=NULL; + while((sum_pdf_arg=(RooAbsArg*)iter_sum_pdf->Next())) { + + std::string NodeClassName = sum_pdf_arg->ClassName(); + if( NodeClassName == std::string("RooRealSumPdf") ) { + FoundSumPdf=true; + sum_pdf = (RooAbsPdf*) sum_pdf_arg; + break; + } + } + if( ! FoundSumPdf ) { + std::cout << "Failed to find RooRealSumPdf for channel: " << sim_channel->GetName() << std::endl; + sim_channel->getComponents()->Print("V"); + throw std::runtime_error("Failed to find RooRealSumPdf for channel"); + } + delete iter_sum_pdf; + iter_sum_pdf = NULL; + * / + + // Okay, now add to the arg sets + channels->add( *sum_pdf ); + channelsWithConstraints->add( *sim_channel ); + + } + + delete simServerItr; + + } + else { + std::cout << "Model is not a RooSimultaneous or doesn't derive from one." << std::endl; + std::cout << "HistFactoryModelUtils isn't yet implemented for these pdf's" << std::endl; + } + + } + */ + + bool getStatUncertaintyFromChannel( RooAbsPdf* channel, ParamHistFunc*& paramfunc, RooArgList* gammaList ) { + + bool verbose=false; + + // Find the servers of this channel + //TIterator* iter = channel->serverIterator(); + TIterator* iter = channel->getComponents()->createIterator(); //serverIterator(); + bool FoundParamHistFunc=false; + RooAbsArg* paramfunc_arg = NULL; + while(( paramfunc_arg = (RooAbsArg*) iter->Next() )) { + std::string NodeName = paramfunc_arg->GetName(); + std::string NodeClassName = paramfunc_arg->ClassName(); + if( NodeClassName != std::string("ParamHistFunc") ) continue; + if( NodeName.find("mc_stat_") != std::string::npos ) { + FoundParamHistFunc=true; + paramfunc = (ParamHistFunc*) paramfunc_arg; + break; + } + } + if( ! FoundParamHistFunc || !paramfunc ) { + if(verbose) std::cout << "Failed to find ParamHistFunc for channel: " << channel->GetName() << std::endl; + return false; + } + + delete iter; + iter = NULL; + + // Now, get the set of gamma's + gammaList = (RooArgList*) &( paramfunc->paramList()); + if(verbose) gammaList->Print("V"); + + return true; + + } + + + void getDataValuesForObservables( std::map< std::string, std::vector<double> >& ChannelBinDataMap, + RooAbsData* data, RooAbsPdf* pdf ) { + + bool verbose=false; + + //std::map< std::string, std::vector<int> ChannelBinDataMap; + + RooSimultaneous* simPdf = (RooSimultaneous*) pdf; + + // get category label + RooArgSet* allobs = (RooArgSet*) data->get(); + TIterator* obsIter = allobs->createIterator(); + RooCategory* cat = NULL; + RooAbsArg* temp = NULL; + while( (temp=(RooAbsArg*) obsIter->Next())) { + // use dynamic cast here instead + if( strcmp(temp->ClassName(),"RooCategory")==0){ + cat = (RooCategory*) temp; + break; + } + } + if(verbose) { + if(!cat) std::cout <<"didn't find category"<< std::endl; + else std::cout <<"found category"<< std::endl; + } + delete obsIter; + + // split dataset + TList* dataByCategory = data->split(*cat); + if(verbose) dataByCategory->Print(); + // note : + // RooAbsData* dataForChan = (RooAbsData*) dataByCategory->FindObject(""); + + // loop over channels + RooCategory* channelCat = (RooCategory*) (&simPdf->indexCat()); + TIterator* iter = channelCat->typeIterator() ; + RooCatType* tt = NULL; + while((tt=(RooCatType*) iter->Next())) { + + // Get pdf associated with state from simpdf + RooAbsPdf* pdftmp = simPdf->getPdf(tt->GetName()) ; + + std::string ChannelName = pdftmp->GetName(); //tt->GetName(); + if(verbose) std::cout << "Getting data for channel: " << ChannelName << std::endl; + ChannelBinDataMap[ ChannelName ] = std::vector<double>(); + + RooAbsData* dataForChan = (RooAbsData*) dataByCategory->FindObject(tt->GetName()); + if(verbose) dataForChan->Print(); + + // Generate observables defined by the pdf associated with this state + RooArgSet* obstmp = pdftmp->getObservables(*dataForChan->get()) ; + RooRealVar* obs = ((RooRealVar*)obstmp->first()); + if(verbose) obs->Print(); + + //double expected = pdftmp->expectedEvents(*obstmp); + + // set value to desired value (this is just an example) + // double obsVal = obs->getVal(); + // set obs to desired value of observable + // obs->setVal( obsVal ); + //double fracAtObsValue = pdftmp->getVal(*obstmp); + + // get num events expected in bin for obsVal + // double nu = expected * fracAtObsValue; + + // an easier way to get n + TH1* histForN = dataForChan->createHistogram("HhstForN",*obs); + for(int i=1; i<=histForN->GetNbinsX(); ++i){ + double n = histForN->GetBinContent(i); + if(verbose) std::cout << "n" << i << " = " << n << std::endl; + ChannelBinDataMap[ ChannelName ].push_back( n ); + } + delete histForN; + + } // End Loop Over Categories + + delete iter; + return; + + } + + + int getStatUncertaintyConstraintTerm( RooArgList* constraints, RooRealVar* gamma_stat, + RooAbsReal*& pois_nom, RooRealVar*& tau ) { + // Given a set of constraint terms, + // find the poisson constraint for the + // given gamma and return the mean + // as well as the 'tau' parameter + + bool verbose=false; + + // To get the constraint term, loop over all constraint terms + // and look for the gamma_stat name as well as '_constraint' + // std::string constraintTermName = std::string(gamma_stat->GetName()) + "_constraint"; + TIterator* iter_list = constraints->createIterator(); + RooAbsArg* term_constr=NULL; + bool FoundConstraintTerm=false; + RooAbsPdf* constraintTerm=NULL; + while((term_constr=(RooAbsArg*)iter_list->Next())) { + std::string TermName = term_constr->GetName(); + // std::cout << "Checking if is a constraint term: " << TermName << std::endl; + + //if( TermName.find(gamma_stat->GetName())!=string::npos ) { + if( term_constr->dependsOn( *gamma_stat) ) { + if( TermName.find("_constraint")!=std::string::npos ) { + FoundConstraintTerm=true; + constraintTerm = (RooAbsPdf*) term_constr; + break; + } + } + } + if( FoundConstraintTerm==false ) { + std::cout << "Error: Couldn't find constraint term for parameter: " << gamma_stat->GetName() + << " among constraints: " << constraints->GetName() << std::endl; + constraints->Print("V"); + throw std::runtime_error("Failed to find Gamma ConstraintTerm"); + return -1; + } + delete iter_list; + + /* + RooAbsPdf* constraintTerm = (RooAbsPdf*) constraints->find( constraintTermName.c_str() ); + if( constraintTerm == NULL ) { + std::cout << "Error: Couldn't find constraint term: " << constraintTermName + << " for parameter: " << gamma_stat->GetName() + << std::endl; + throw std::runtime_error("Failed to find Gamma ConstraintTerm"); + return -1; + } + */ + + // Find the "data" of the poisson term + // This is the nominal value + bool FoundNomMean=false; + TIterator* iter_pois = constraintTerm->serverIterator(); //constraint_args + RooAbsArg* term_pois ; + while((term_pois=(RooAbsArg*)iter_pois->Next())) { + std::string serverName = term_pois->GetName(); + //std::cout << "Checking Server: " << serverName << std::endl; + if( serverName.find("nom_")!=std::string::npos ) { + FoundNomMean = true; + pois_nom = (RooRealVar*) term_pois; + } + } + if( !FoundNomMean || !pois_nom ) { + std::cout << "Error: Did not find Nominal Pois Mean parameter in gamma constraint term PoissonMean: " + << constraintTerm->GetName() << std::endl; + throw std::runtime_error("Failed to find Nom Pois Mean"); + } + else { + if(verbose) std::cout << "Found Poisson 'data' term: " << pois_nom->GetName() << std::endl; + } + delete iter_pois; + + // Taking the constraint term (a Poisson), find + // the "mean" which is the product: gamma*tau + // Then, from that mean, find tau + TIterator* iter_constr = constraintTerm->serverIterator(); //constraint_args + RooAbsArg* pois_mean_arg=NULL; + bool FoundPoissonMean = false; + while(( pois_mean_arg = (RooAbsArg*) iter_constr->Next() )) { + std::string serverName = pois_mean_arg->GetName(); + if( pois_mean_arg->dependsOn( *gamma_stat ) ) { + FoundPoissonMean=true; + // pois_mean = (RooAbsReal*) pois_mean_arg; + break; + } + } + if( !FoundPoissonMean || !pois_mean_arg ) { + std::cout << "Error: Did not find PoissonMean parameter in gamma constraint term: " + << constraintTerm->GetName() << std::endl; + throw std::runtime_error("Failed to find PoissonMean"); + return -1; + } + else { + if(verbose) std::cout << "Found Poisson 'mean' term: " << pois_mean_arg->GetName() << std::endl; + } + delete iter_constr; + + + TIterator* iter_product = pois_mean_arg->serverIterator(); //constraint_args + RooAbsArg* term_in_product ; + bool FoundTau=false; + while((term_in_product=(RooAbsArg*)iter_product->Next())) { + std::string serverName = term_in_product->GetName(); + //std::cout << "Checking Server: " << serverName << std::endl; + if( serverName.find("_tau")!=std::string::npos ) { + FoundTau = true; + tau = (RooRealVar*) term_in_product; + } + } + if( !FoundTau || !tau ) { + std::cout << "Error: Did not find Tau parameter in gamma constraint term PoissonMean: " + << pois_mean_arg->GetName() << std::endl; + throw std::runtime_error("Failed to find Tau"); + } + else { + if(verbose) std::cout << "Found Poisson 'tau' term: " << tau->GetName() << std::endl; + } + delete iter_product; + + return 0; + + } + + + +} // close RooStats namespace +} // close HistFactory namespace diff --git a/roofit/histfactory/src/HistFactoryNavigation.cxx b/roofit/histfactory/src/HistFactoryNavigation.cxx new file mode 100644 index 0000000000000..629f9e045c40d --- /dev/null +++ b/roofit/histfactory/src/HistFactoryNavigation.cxx @@ -0,0 +1,1309 @@ + +#include <iomanip> +#include <sstream> + +#include "TFile.h" +#include "TRegexp.h" +#include "TCanvas.h" +#include "TLegend.h" +#include "TMath.h" + +#include "RooRealSumPdf.h" +#include "RooProduct.h" +#include "RooMsgService.h" +#include "RooCategory.h" +#include "RooSimultaneous.h" +#include "RooWorkspace.h" + +#include "RooStats/HistFactory/HistFactoryNavigation.h" +#include "RooStats/HistFactory/HistFactoryException.h" + + +ClassImp(RooStats::HistFactory::HistFactoryNavigation); + + +namespace RooStats { + namespace HistFactory { + + + // CONSTRUCTOR + HistFactoryNavigation::HistFactoryNavigation(ModelConfig* mc) + : _minBinToPrint(-1), _maxBinToPrint(-1), + _label_print_width(20), _bin_print_width(12) { + + if( !mc ) { + std::cout << "Error: The supplied ModelConfig is NULL " << std::endl; + throw hf_exc(); + } + + // Save the model pointer + RooAbsPdf* pdf_in_mc = mc->GetPdf(); + if( !pdf_in_mc ) { + std::cout << "Error: The pdf found in the ModelConfig: " << mc->GetName() + << " is NULL" << std::endl; + throw hf_exc(); + } + + // Set the PDF member + fModel = mc->GetPdf(); + + // Get the observables + RooArgSet* observables_in_mc = const_cast<RooArgSet*>(mc->GetObservables()); + if( !observables_in_mc ) { + std::cout << "Error: Observable set in the ModelConfig: " << mc->GetName() + << " is NULL" << std::endl; + throw hf_exc(); + } + if( observables_in_mc->getSize() == 0 ) { + std::cout << "Error: Observable list: " << observables_in_mc->GetName() + << " found in ModelConfig: " << mc->GetName() + << " has no entries." << std::endl; + throw hf_exc(); + } + + // Set the observables member + fObservables = observables_in_mc; + + // Initialize the rest of the members + _GetNodes(fModel, fObservables); + + } + + + // CONSTRUCTOR + HistFactoryNavigation::HistFactoryNavigation(const std::string& FileName, + const std::string& WorkspaceName, + const std::string& ModelConfigName) : + _minBinToPrint(-1), _maxBinToPrint(-1), + _label_print_width(20), _bin_print_width(12) { + + // Open the File + TFile* file = new TFile(FileName.c_str()); + if( !file ) { + std::cout << "Error: Failed to open file: " << FileName << std::endl; + throw hf_exc(); + } + + // Get the workspace + RooWorkspace* wspace = (RooWorkspace*) file->Get(WorkspaceName.c_str()); + if( !wspace ) { + std::cout << "Error: Failed to get workspace: " << WorkspaceName + << " from file: " << FileName << std::endl; + throw hf_exc(); + } + + // Get the ModelConfig + ModelConfig* mc = (ModelConfig*) wspace->obj(ModelConfigName.c_str()); + if( !mc ) { + std::cout << "Error: Failed to find ModelConfig: " << ModelConfigName + << " from workspace: " << WorkspaceName + << " in file: " << FileName << std::endl; + throw hf_exc(); + } + + // Save the model pointer + RooAbsPdf* pdf_in_mc = mc->GetPdf(); + if( !pdf_in_mc ) { + std::cout << "Error: The pdf found in the ModelConfig: " << ModelConfigName + << " is NULL" << std::endl; + throw hf_exc(); + } + + // Set the PDF member + fModel = pdf_in_mc; + + // Get the observables + RooArgSet* observables_in_mc = const_cast<RooArgSet*>(mc->GetObservables()); + if( !observables_in_mc ) { + std::cout << "Error: Observable set in the ModelConfig: " << ModelConfigName + << " is NULL" << std::endl; + throw hf_exc(); + } + if( observables_in_mc->getSize() == 0 ) { + std::cout << "Error: Observable list: " << observables_in_mc->GetName() + << " found in ModelConfig: " << ModelConfigName + << " in file: " << FileName + << " has no entries." << std::endl; + throw hf_exc(); + } + + // Set the observables member + fObservables = observables_in_mc; + + // Initialize the rest of the members + _GetNodes(fModel, fObservables); + + } + + + // CONSTRUCTOR + HistFactoryNavigation::HistFactoryNavigation(RooAbsPdf* model, RooArgSet* observables) : + _minBinToPrint(-1), _maxBinToPrint(-1), + _label_print_width(20), _bin_print_width(12) { + + // Save the model pointer + if( !model ) { + std::cout << "Error: The supplied pdf is NULL" << std::endl; + throw hf_exc(); + } + + // Set the PDF member + fModel = model; + + // Get the observables + if( !observables ) { + std::cout << "Error: Supplied Observable set is NULL" << std::endl; + throw hf_exc(); + } + if( observables->getSize() == 0 ) { + std::cout << "Error: Observable list: " << observables->GetName() + << " has no entries." << std::endl; + throw hf_exc(); + } + + // Initialize the rest of the members + _GetNodes(fModel, fObservables); + + } + + + void HistFactoryNavigation::PrintMultiDimHist(TH1* hist, int bin_print_width) { + + // This is how ROOT makes us loop over histograms :( + int current_bin = 0; + int num_bins = hist->GetNbinsX()*hist->GetNbinsY()*hist->GetNbinsZ(); + for(int i = 0; i < num_bins; ++i) { + // Avoid the overflow/underflow + current_bin++; + while( hist->IsBinUnderflow(current_bin) || + hist->IsBinOverflow(current_bin) ) { + current_bin++; + } + // Check that we should print this bin + if( _minBinToPrint != -1 && i < _minBinToPrint) continue; + if( _maxBinToPrint != -1 && i > _maxBinToPrint) break; + std::cout << std::setw(bin_print_width) << hist->GetBinContent(current_bin); + } + std::cout << std::endl; + + } + + + + RooAbsPdf* HistFactoryNavigation::GetChannelPdf(const std::string& channel) { + + std::map< std::string, RooAbsPdf* >::iterator itr; + itr = fChannelPdfMap.find(channel); + + if( itr == fChannelPdfMap.end() ) { + std::cout << "Warning: Could not find channel: " << channel + << " in pdf: " << fModel->GetName() << std::endl; + return NULL; + } + + RooAbsPdf* pdf = itr->second; + if( pdf == NULL ) { + std::cout << "Warning: Pdf associated with channel: " << channel + << " is NULL" << std::endl; + return NULL; + } + + return pdf; + + } + + void HistFactoryNavigation::PrintState(const std::string& channel) { + + //int label_print_width = 20; + //int bin_print_width = 12; + std::cout << std::endl << channel << ":" << std::endl; + + // Get the map of Samples for this channel + std::map< std::string, RooAbsReal*> SampleFunctionMap = GetSampleFunctionMap(channel); + + // Set the size of the print width if necessary + /* + for( std::map< std::string, RooAbsReal*>::iterator itr = SampleFunctionMap.begin(); + itr != SampleFunctionMap.end(); ++itr) { + std::string sample_name = itr->first; + label_print_width = TMath::Max(label_print_width, (int)sample_name.size()+2); + } + */ + + // Loop over the SampleFunctionMap and print the individual histograms + // to get the total histogram for the channel + int num_bins = 0; + std::map< std::string, RooAbsReal*>::iterator itr = SampleFunctionMap.begin(); + for( ; itr != SampleFunctionMap.end(); ++itr) { + + std::string sample_name = itr->first; + std::string tmp_name = sample_name + channel + "_pretty_tmp"; + TH1* sample_hist = GetSampleHist(channel, sample_name, tmp_name); + num_bins = sample_hist->GetNbinsX()*sample_hist->GetNbinsY()*sample_hist->GetNbinsZ(); + std::cout << std::setw(_label_print_width) << sample_name; + + // Print the content of the histogram + PrintMultiDimHist(sample_hist, _bin_print_width); + delete sample_hist; + + } + + // Make the line break as a set of "===============" ... + std::string line_break; + int high_bin = _maxBinToPrint==-1 ? num_bins : TMath::Min(_maxBinToPrint, (int)num_bins); + int low_bin = _minBinToPrint==-1 ? 1 : _minBinToPrint; + int break_length = (high_bin - low_bin + 1) * _bin_print_width; + break_length += _label_print_width; + for(int i = 0; i < break_length; ++i) { + line_break += "="; + } + std::cout << line_break << std::endl; + + std::string tmp_name = channel + "_pretty_tmp"; + TH1* channel_hist = GetChannelHist(channel, tmp_name); + std::cout << std::setw(_label_print_width) << "TOTAL:"; + + // Print the Histogram + PrintMultiDimHist(channel_hist, _bin_print_width); + delete channel_hist; + + return; + + } + + + void HistFactoryNavigation::PrintState() { + // Loop over channels and print their states, one after another + for(unsigned int i = 0; i < fChannelNameVec.size(); ++i) { + PrintState(fChannelNameVec.at(i)); + } + } + + + void HistFactoryNavigation::SetPrintWidths(const std::string& channel) { + + // Get the map of Samples for this channel + std::map< std::string, RooAbsReal*> SampleFunctionMap = GetSampleFunctionMap(channel); + + // Get the max of the samples + for( std::map< std::string, RooAbsReal*>::iterator itr = SampleFunctionMap.begin(); + itr != SampleFunctionMap.end(); ++itr) { + std::string sample_name = itr->first; + _label_print_width = TMath::Max(_label_print_width, (int)sample_name.size()+2); + } + + _label_print_width = TMath::Max( _label_print_width, (int)channel.size() + 7); + } + + + void HistFactoryNavigation::PrintDataSet(RooDataSet* data, + const std::string& channel_to_print) { + + // Print the contents of a 'HistFactory' RooDataset + // These are stored in a somewhat odd way that makes + // them difficult to inspect for humans. + // They have the following layout: + // ===================================================== + // ChannelA ChannelB ChannelCat Weight + // ----------------------------------------------------- + // bin_1_center 0 ChannelA bin_1_height + // bin_2_center 0 ChannelA bin_2_height + // 0 bin_1_center ChannelB bin_1_height + // 0 bin_2_center ChannelB bin_2_height + // ...etc... + // ===================================================== + + // int label_print_width = 20; + // int bin_print_width = 12; + + // Get the Data Histogram for this channel + for( unsigned int i_chan=0; i_chan < fChannelNameVec.size(); ++i_chan) { + + std::string channel_name = fChannelNameVec.at(i_chan); + + // If we pass a channel string, we only print that one channel + if( channel_to_print != "" && channel_name != channel_to_print) continue; + + TH1* data_hist = GetDataHist(data, channel_name, channel_name+"_tmp"); + std::cout << std::setw(_label_print_width) << channel_name + " (data)"; + + // Print the Histogram + PrintMultiDimHist(data_hist, _bin_print_width); + delete data_hist; + } + } + + + void HistFactoryNavigation::PrintModelAndData(RooDataSet* data) { + // Loop over all channels and print model + // (including all samples) and compare + // it to the supplied dataset + + for( unsigned int i = 0; i < fChannelNameVec.size(); ++i) { + std::string channel = fChannelNameVec.at(i); + SetPrintWidths(channel); + PrintState(channel); + PrintDataSet(data, channel); + } + + std::cout << std::endl; + + } + + + void HistFactoryNavigation::PrintParameters(bool IncludeConstantParams) { + + // Get the list of parameters + RooArgSet* params = fModel->getParameters(*fObservables); + + std::cout << std::endl; + + // Create the title row + std::cout << std::setw(30) << "Parameter"; + std::cout << std::setw(15) << "Value" + << std::setw(15) << "Error Low" + << std::setw(15) << "Error High" + << std::endl; + + // Loop over the parameters and print their values, etc + TIterator* paramItr = params->createIterator(); + RooRealVar* param = NULL; + while( (param=(RooRealVar*)paramItr->Next()) ) { + + if( !IncludeConstantParams && param->isConstant() ) continue; + + std::cout << std::setw(30) << param->GetName(); + std::cout << std::setw(15) << param->getVal(); + if( !param->isConstant() ) { + std::cout << std::setw(15) << param->getErrorLo() << std::setw(15) << param->getErrorHi(); + } + std::cout<< std::endl; + } + + std::cout << std::endl; + + return; + } + + void HistFactoryNavigation::PrintChannelParameters(const std::string& channel, + bool IncludeConstantParams) { + + // Get the list of parameters + RooArgSet* params = fModel->getParameters(*fObservables); + + // Get the pdf for this channel + RooAbsPdf* channel_pdf = GetChannelPdf(channel); + + std::cout << std::endl; + + // Create the title row + std::cout << std::setw(30) << "Parameter"; + std::cout << std::setw(15) << "Value" + << std::setw(15) << "Error Low" + << std::setw(15) << "Error High" + << std::endl; + + // Loop over the parameters and print their values, etc + TIterator* paramItr = params->createIterator(); + RooRealVar* param = NULL; + while( (param=(RooRealVar*)paramItr->Next()) ) { + + if( !IncludeConstantParams && param->isConstant() ) continue; + + if( findChild(param->GetName(), channel_pdf)==NULL ) continue; + + std::cout << std::setw(30) << param->GetName(); + std::cout << std::setw(15) << param->getVal(); + if( !param->isConstant() ) { + std::cout << std::setw(15) << param->getErrorLo() << std::setw(15) << param->getErrorHi(); + } + std::cout<< std::endl; + } + + std::cout << std::endl; + + return; + } + + + void HistFactoryNavigation::PrintSampleParameters(const std::string& channel, + const std::string& sample, + bool IncludeConstantParams) { + + // Get the list of parameters + RooArgSet* params = fModel->getParameters(*fObservables); + + // Get the pdf for this channel + RooAbsReal* sample_func = SampleFunction(channel, sample); + + std::cout << std::endl; + + // Create the title row + std::cout << std::setw(30) << "Parameter"; + std::cout << std::setw(15) << "Value" + << std::setw(15) << "Error Low" + << std::setw(15) << "Error High" + << std::endl; + + // Loop over the parameters and print their values, etc + TIterator* paramItr = params->createIterator(); + RooRealVar* param = NULL; + while( (param=(RooRealVar*)paramItr->Next()) ) { + + if( !IncludeConstantParams && param->isConstant() ) continue; + + if( findChild(param->GetName(), sample_func)==NULL ) continue; + + std::cout << std::setw(30) << param->GetName(); + std::cout << std::setw(15) << param->getVal(); + if( !param->isConstant() ) { + std::cout << std::setw(15) << param->getErrorLo() << std::setw(15) << param->getErrorHi(); + } + std::cout<< std::endl; + } + + std::cout << std::endl; + + return; + } + + + + double HistFactoryNavigation::GetBinValue(int bin, const std::string& channel) { + // Get the total bin height for the ith bin (ROOT indexing convention) + // in channel 'channel' + // (Could be optimized, it uses an intermediate histogram for now...) + + // Get the histogram, fetch the bin content, and return + TH1* channel_hist_tmp = GetChannelHist(channel, (channel+"_tmp").c_str()); + double val = channel_hist_tmp->GetBinContent(bin); + delete channel_hist_tmp; + return val; + } + + + double HistFactoryNavigation::GetBinValue(int bin, const std::string& channel, const std::string& sample){ + // Get the total bin height for the ith bin (ROOT indexing convention) + // in channel 'channel' + // (This will be slow if you plan on looping over it. + // Could be optimized, it uses an intermediate histogram for now...) + + // Get the histogram, fetch the bin content, and return + TH1* sample_hist_tmp = GetSampleHist(channel, sample, (channel+"_tmp").c_str()); + double val = sample_hist_tmp->GetBinContent(bin); + delete sample_hist_tmp; + return val; + } + + + std::map< std::string, RooAbsReal*> HistFactoryNavigation::GetSampleFunctionMap(const std::string& channel) { + // Get a map of strings to function pointers, + // which each function cooresponds to a sample + + std::map< std::string, std::map< std::string, RooAbsReal*> >::iterator channel_itr; + channel_itr = fChannelSampleFunctionMap.find(channel); + if( channel_itr==fChannelSampleFunctionMap.end() ){ + std::cout << "Error: Channel: " << channel << " not found in Navigation" << std::endl; + throw hf_exc(); + } + + return channel_itr->second; + } + + + RooAbsReal* HistFactoryNavigation::SampleFunction(const std::string& channel, const std::string& sample){ + // Return the function object pointer cooresponding + // to a particular sample in a particular channel + + std::map< std::string, std::map< std::string, RooAbsReal*> >::iterator channel_itr; + channel_itr = fChannelSampleFunctionMap.find(channel); + if( channel_itr==fChannelSampleFunctionMap.end() ){ + std::cout << "Error: Channel: " << channel << " not found in Navigation" << std::endl; + throw hf_exc(); + } + + std::map< std::string, RooAbsReal*>& SampleMap = channel_itr->second; + std::map< std::string, RooAbsReal*>::iterator sample_itr; + sample_itr = SampleMap.find(sample); + if( sample_itr==SampleMap.end() ){ + std::cout << "Error: Sample: " << sample << " not found in Navigation" << std::endl; + throw hf_exc(); + } + + return sample_itr->second; + + } + + + RooArgSet* HistFactoryNavigation::GetObservableSet(const std::string& channel) { + // Get the observables for a particular channel + + std::map< std::string, RooArgSet*>::iterator channel_itr; + channel_itr = fChannelObservMap.find(channel); + if( channel_itr==fChannelObservMap.end() ){ + std::cout << "Error: Channel: " << channel << " not found in Navigation" << std::endl; + throw hf_exc(); + } + + return channel_itr->second; + + } + + + TH1* HistFactoryNavigation::GetSampleHist(const std::string& channel, const std::string& sample, + const std::string& hist_name) { + // Get a histogram of the expected values for + // a particular sample in a particular channel + // Give a name, or a default one will be used + + RooArgList observable_list( *GetObservableSet(channel) ); + + std::string name = hist_name; + if(hist_name=="") name = channel + "_" + sample + "_hist"; + + RooAbsReal* sample_function = SampleFunction(channel, sample); + + return MakeHistFromRooFunction( sample_function, observable_list, name ); + + } + + + TH1* HistFactoryNavigation::GetChannelHist(const std::string& channel, const std::string& hist_name) { + // Get a histogram of the total expected value + // per bin for this channel + // Give a name, or a default one will be used + + RooArgList observable_list( *GetObservableSet(channel) ); + + std::map< std::string, RooAbsReal*> SampleFunctionMap = GetSampleFunctionMap(channel); + + // Okay, 'loop' once + TH1* total_hist=NULL; + std::map< std::string, RooAbsReal*>::iterator itr = SampleFunctionMap.begin(); + for( ; itr != SampleFunctionMap.end(); ++itr) { + std::string sample_name = itr->first; + std::string tmp_hist_name = sample_name + "_hist_tmp"; + RooAbsReal* sample_function = itr->second; + TH1* sample_hist = MakeHistFromRooFunction(sample_function, observable_list, + tmp_hist_name); + total_hist = (TH1*) sample_hist->Clone("TotalHist"); + delete sample_hist; + break; + } + total_hist->Reset(); + + // Loop over the SampleFunctionMap and add up all the histograms + // to get the total histogram for the channel + itr = SampleFunctionMap.begin(); + for( ; itr != SampleFunctionMap.end(); ++itr) { + std::string sample_name = itr->first; + std::string tmp_hist_name = sample_name + "_hist_tmp"; + RooAbsReal* sample_function = itr->second; + TH1* sample_hist = MakeHistFromRooFunction(sample_function, observable_list, + tmp_hist_name); + total_hist->Add(sample_hist); + delete sample_hist; + } + + if(hist_name=="") total_hist->SetName(hist_name.c_str()); + else total_hist->SetName( (channel + "_hist").c_str() ); + + return total_hist; + + } + + + std::vector< std::string > HistFactoryNavigation::GetChannelSampleList(const std::string& channel) { + + std::vector<std::string> sample_list; + + std::map< std::string, RooAbsReal*> sample_map = fChannelSampleFunctionMap[channel]; + std::map< std::string, RooAbsReal*>::iterator itr = sample_map.begin();; + for( ; itr != sample_map.end(); ++itr) { + sample_list.push_back( itr->first ); + } + + return sample_list; + + } + + + THStack* HistFactoryNavigation::GetChannelStack(const std::string& channel, + const std::string& name) { + + THStack* stack = new THStack(name.c_str(), ""); + + std::vector< std::string > samples = GetChannelSampleList(channel); + + // Add the histograms + for( unsigned int i=0; i < samples.size(); ++i) { + std::string sample_name = samples.at(i); + TH1* hist = GetSampleHist(channel, sample_name, sample_name+"_tmp"); + hist->SetLineColor(2+i); + hist->SetFillColor(2+i); + stack->Add(hist); + } + + return stack; + + } + + + TH1* HistFactoryNavigation::GetDataHist(RooDataSet* data, const std::string& channel, + const std::string& name) { + + // TO DO: + // MAINTAIN THE ACTUAL RANGE, USING THE OBSERVABLES + // MAKE IT WORK FOR MULTI-DIMENSIONAL + // + + // If the dataset covers multiple categories, + // Split the dataset based on the categories + if(strcmp(fModel->ClassName(),"RooSimultaneous")==0){ + + // If so, get a list of the component pdf's: + RooSimultaneous* simPdf = (RooSimultaneous*) fModel; + RooCategory* channelCat = (RooCategory*) (&simPdf->indexCat()); + + TList* dataset_list = data->split(*channelCat); + + data = dynamic_cast<RooDataSet*>( dataset_list->FindObject(channel.c_str()) ); + + } + + RooArgList vars( *GetObservableSet(channel) ); + + int dim = vars.getSize(); + + TH1* hist = NULL; + + if( dim==1 ) { + RooRealVar* varX = (RooRealVar*) vars.at(0); + hist = data->createHistogram( name.c_str(),*varX, RooFit::Binning(varX->getBinning()) ); + } + else if( dim==2 ) { + RooRealVar* varX = (RooRealVar*) vars.at(0); + RooRealVar* varY = (RooRealVar*) vars.at(1); + hist = data->createHistogram( name.c_str(),*varX, RooFit::Binning(varX->getBinning()), + RooFit::YVar(*varY, RooFit::Binning(varY->getBinning())) ); + } + else if( dim==3 ) { + RooRealVar* varX = (RooRealVar*) vars.at(0); + RooRealVar* varY = (RooRealVar*) vars.at(1); + RooRealVar* varZ = (RooRealVar*) vars.at(2); + hist = data->createHistogram( name.c_str(),*varX, RooFit::Binning(varX->getBinning()), + RooFit::YVar(*varY, RooFit::Binning(varY->getBinning())), + RooFit::YVar(*varZ, RooFit::Binning(varZ->getBinning())) ); + } + else { + std::cout << "Error: To Create Histogram from RooDataSet, Dimension must be 1, 2, or 3" << std::endl; + std::cout << "Observables: " << std::endl; + vars.Print("V"); + throw hf_exc(); + } + + return hist; + + } + + + void HistFactoryNavigation::DrawChannel(const std::string& channel, RooDataSet* data) { + + // Get the stack + THStack* stack = GetChannelStack(channel, channel+"_stack_tmp"); + + stack->Draw(); + + if( data!=NULL ) { + TH1* data_hist = GetDataHist(data, channel, channel+"_data_tmp"); + data_hist->Draw("SAME"); + } + + } + + + + RooArgSet HistFactoryNavigation::_GetAllProducts(RooProduct* node) { + + // An internal method to recursively get all products, + // including if a RooProduct is a Product of RooProducts + // etc + + RooArgSet allTerms; + + // Get All Subnodes of this product + RooArgSet productComponents = node->components(); + + // Loop over the subnodes and add + TIterator* itr = productComponents.createIterator(); + RooAbsArg* arg = NULL; + while( (arg=(RooAbsArg*)itr->Next()) ) { + std::string ClassName = arg->ClassName(); + if( ClassName == "RooProduct" ) { + RooProduct* prod = dynamic_cast<RooProduct*>(arg); + allTerms.add( _GetAllProducts(prod) ); + } + else { + allTerms.add(*arg); + } + } + delete itr; + + return allTerms; + + } + + + + + void HistFactoryNavigation::_GetNodes(RooAbsPdf* modelPdf, const RooArgSet* observables) { + + // Get the pdf from the ModelConfig + //RooAbsPdf* modelPdf = mc->GetPdf(); + //RooArgSet* observables = mc->GetObservables(); + + // Create vectors to hold the channel pdf's + // as well as the set of observables for each channel + //std::map< std::string, RooAbsPdf* > channelPdfMap; + //std::map< std::string, RooArgSet* > channelObservMap; + + // Check if it is a simultaneous pdf or not + // (if it's an individual channel, it won't be, if it's + // combined, it's simultaneous) + // Fill the channel vectors based on the structure + // (Obviously, if it's not simultaneous, there will be + // only one entry in the vector for the single channel) + if(strcmp(modelPdf->ClassName(),"RooSimultaneous")==0){ + + // If so, get a list of the component pdf's: + RooSimultaneous* simPdf = (RooSimultaneous*) modelPdf; + RooCategory* channelCat = (RooCategory*) (&simPdf->indexCat()); + + // Iterate over the categories and get the + // pdf and observables for each category + TIterator* iter = channelCat->typeIterator() ; + RooCatType* tt = NULL; + while((tt=(RooCatType*) iter->Next())) { + std::string ChannelName = tt->GetName(); + fChannelNameVec.push_back( ChannelName ); + RooAbsPdf* pdftmp = simPdf->getPdf(ChannelName.c_str()) ; + RooArgSet* obstmp = pdftmp->getObservables(*observables) ; + fChannelPdfMap[ChannelName] = pdftmp; + fChannelObservMap[ChannelName] = obstmp; + } + + } else { + RooArgSet* obstmp = modelPdf->getObservables(*observables) ; + // The channel name is model_CHANNEL + std::string ChannelName = modelPdf->GetName(); + ChannelName = ChannelName.replace(0, 6, ""); + fChannelNameVec.push_back(ChannelName); + fChannelPdfMap[ChannelName] = modelPdf; + fChannelObservMap[ChannelName] = obstmp; + + } + + // Okay, now we have maps of the pdfs + // and the observable list per channel + // We then loop over the channel pdfs: + // and find their RooRealSumPdfs + // std::map< std::string, RooRealSumPdf* > channelSumNodeMap; + + for( unsigned int i = 0; i < fChannelNameVec.size(); ++i ) { + + std::string ChannelName = fChannelNameVec.at(i); + RooAbsPdf* pdf = fChannelPdfMap[ChannelName]; + //std::string Name = fChannelNameMap[ChannelName]; + + // Loop over the pdf's components and find + // the (one) that is a RooRealSumPdf + // Based on the mode, we assume that node is + // the "unconstrained" pdf node for that channel + RooArgSet* components = pdf->getComponents(); + TIterator* argItr = components->createIterator(); + RooAbsArg* arg = NULL; + while( (arg=(RooAbsArg*)argItr->Next()) ) { + std::string ClassName = arg->ClassName(); + if( ClassName == "RooRealSumPdf" ) { + fChannelSumNodeMap[ChannelName] = (RooRealSumPdf*) arg; + break; + } + } + } + + // Okay, now we have all necessary + // nodes filled for each channel. + for( unsigned int i = 0; i < fChannelNameVec.size(); ++i ) { + + std::string ChannelName = fChannelNameVec.at(i); + RooRealSumPdf* sumPdf = dynamic_cast<RooRealSumPdf*>(fChannelSumNodeMap[ChannelName]); + + // We now take the RooRealSumPdf and loop over + // its component functions. The RooRealSumPdf turns + // a list of functions (expected events or bin heights + // per sample) and turns it into a pdf. + // Therefore, we loop over it to find the expected + // height for the various samples + + // First, create a map to store the function nodes + // for each sample in this channel + std::map< std::string, RooAbsReal*> sampleFunctionMap; + + // Loop over the sample nodes in this + // channel's RooRealSumPdf + RooArgList nodes = sumPdf->funcList(); + TIterator* sampleItr = nodes.createIterator(); + RooAbsArg* sample; + while( (sample=(RooAbsArg*)sampleItr->Next()) ) { + + // Cast this node as a function + RooAbsReal* func = (RooAbsReal*) sample; + + // Do a bit of work to get the name of each sample + std::string SampleName = sample->GetName(); + if( SampleName.find("L_x_") != std::string::npos ) { + size_t index = SampleName.find("L_x_"); + SampleName.replace( index, 4, "" ); + } + if( SampleName.find(ChannelName.c_str()) != std::string::npos ) { + size_t index = SampleName.find(ChannelName.c_str()); + SampleName = SampleName.substr(0, index-1); + } + + // And simply save this node into our map + sampleFunctionMap[SampleName] = func; + + } + + fChannelSampleFunctionMap[ChannelName] = sampleFunctionMap; + + // Okay, now we have a list of histograms + // representing the samples for this channel. + + } + + } + + + RooAbsArg* HistFactoryNavigation::findChild(const std::string& name, RooAbsReal* parent) const { + + RooAbsArg* term=NULL; + + // Check if it is a "component", + // ie a sub node: + RooArgSet* components = parent->getComponents(); + TIterator* argItr = components->createIterator(); + RooAbsArg* arg = NULL; + while( (arg=(RooAbsArg*)argItr->Next()) ) { + std::string ArgName = arg->GetName(); + if( ArgName == name ) { + term = arg; //dynamic_cast<RooAbsReal*>(arg); + break; + } + } + delete components; + delete argItr; + + if( term != NULL ) return term; + + // If that failed, + // Check if it's a Parameter + // (ie a RooRealVar) + RooArgSet* args = new RooArgSet(); + RooArgSet* paramSet = parent->getParameters(args); + TIterator* paramItr = paramSet->createIterator(); + RooAbsArg* param = NULL; + while( (param=(RooAbsArg*)paramItr->Next()) ) { + std::string ParamName = param->GetName(); + if( ParamName == name ) { + term = param; //dynamic_cast<RooAbsReal*>(arg); + break; + } + } + delete args; + delete paramSet; + delete paramItr; + + /* Not sure if we want to be silent + But since we're returning a pointer which can be NULL, + I think it's the user's job to do checks on it. + A dereference will always cause a crash, so it won't + be silent for long... + if( term==NULL ) { + std::cout << "Error: Failed to find node: " << name + << " as a child of: " << parent->GetName() + << std::endl; + } + */ + + return term; + + } + + + RooAbsReal* HistFactoryNavigation::GetConstraintTerm(const std::string& parameter) { + + std::string ConstraintTermName = parameter + "Constraint"; + + // First, as a sanity check, let's see if the parameter + // itself actually exists and if the model depends on it: + RooRealVar* param = dynamic_cast<RooRealVar*>(findChild(parameter, fModel)); + if( param==NULL ) { + std::cout << "Error: Couldn't Find parameter: " << parameter << " in model." + << std::endl; + return NULL; + } + + // The "gamma"'s use a different constraint term name + if( parameter.find("gamma_stat_") != std::string::npos ) { + ConstraintTermName = parameter + "_constraint"; + } + + // Now, get the constraint itself + RooAbsReal* term = dynamic_cast<RooAbsReal*>(findChild(ConstraintTermName, fModel)); + + if( term==NULL ) { + std::cout << "Error: Couldn't Find constraint term for parameter: " << parameter + << " (Looked for '" << ConstraintTermName << "')" << std::endl; + return NULL; + } + + return term; + + } + + + double HistFactoryNavigation::GetConstraintUncertainty(const std::string& parameter) { + + RooAbsReal* constraintTerm = GetConstraintTerm(parameter); + if( constraintTerm==NULL ) { + std::cout << "Error: Cannot get uncertainty because parameter: " << parameter + << " has no constraint term" << std::endl; + throw hf_exc(); + } + + // Get the type of constraint + std::string ConstraintType = constraintTerm->IsA()->GetName(); + + // Find its value + double sigma = 0.0; + + if( ConstraintType == "" ) { + std::cout << "Error: Constraint type is an empty string." + << " This simply should not be." << std::endl; + throw hf_exc(); + } + else if( ConstraintType == "RooGaussian" ){ + + // Gaussian errors are the 'sigma' in the constraint term + + // Get the name of the 'sigma' for the gaussian + // (I don't know of a way of doing RooGaussian::GetSigma() ) + // For alpha's, the sigma points to a global RooConstVar + // with the name "1" + // For gamma_stat_*, the sigma is named *_sigma + std::string sigmaName = ""; + if( parameter.find("alpha_")!=std::string::npos ) { + sigmaName = "1";; + } + else if( parameter.find("gamma_stat_")!=std::string::npos ) { + sigmaName = parameter + "_sigma"; + } + + // Get the sigma and its value + RooAbsReal* sigmaVar = dynamic_cast<RooAbsReal*>(constraintTerm->findServer(sigmaName.c_str())); + if( sigmaVar==NULL ) { + std::cout << "Error: Failed to find the 'sigma' node: " << sigmaName + << " in the RooGaussian: " << constraintTerm->GetName() << std::endl; + throw hf_exc(); + } + // If we find the uncertainty: + sigma = sigmaVar->getVal(); + } + else if( ConstraintType == "RooPoisson" ){ + // Poisson errors are given by inverting: tau = 1 / (sigma*sigma) + std::string tauName = "nom_" + parameter; + RooAbsReal* tauVar = dynamic_cast<RooAbsReal*>( constraintTerm->findServer(tauName.c_str()) ); + if( tauVar==NULL ) { + std::cout << "Error: Failed to find the nominal 'tau' node: " << tauName + << " for the RooPoisson: " << constraintTerm->GetName() << std::endl; + throw hf_exc(); + } + double tau_val = tauVar->getVal(); + sigma = 1.0 / TMath::Sqrt( tau_val ); + } + else { + std::cout << "Error: Encountered unknown constraint type for Stat Uncertainties: " + << ConstraintType << std::endl; + throw hf_exc(); + } + + return sigma; + + } + + void HistFactoryNavigation::ReplaceNode(const std::string& ToReplace, RooAbsArg* ReplaceWith) { + + // First, check that the node to replace is actually a node: + RooAbsArg* nodeToReplace = findChild(ToReplace, fModel); + if( nodeToReplace==NULL ) { + std::cout << "Error: Cannot replace node: " << ToReplace + << " because this node wasn't found in: " << fModel->GetName() + << std::endl; + throw hf_exc(); + } + + // Now that we have the node we want to replace, we have to + // get its parent node + + // Do this by looping over the clients and replacing their servers + // (NOTE: This happens for ALL clients across the pdf) + TIterator* clientItr = nodeToReplace->clientIterator(); + RooAbsArg* client=NULL; + while((client=(RooAbsArg*)clientItr->Next())) { + + // Check if this client is a member of our pdf + // (We probably don't want to mess with clients + // if they aren't...) + if( findChild(client->GetName(), fModel)==NULL ) continue; + + // Now, do the replacement: + bool valueProp=false; + bool shapeProp=false; + client->replaceServer( *nodeToReplace, *ReplaceWith, valueProp, shapeProp ); + std::cout << "Replaced: " << ToReplace << " with: " << ReplaceWith->GetName() + << " in node: " << client->GetName() << std::endl; + + } + delete clientItr; + + return; + + } + + + void HistFactoryNavigation::PrintSampleComponents(const std::string& channel, + const std::string& sample) { + + // Get the Sample Node + RooAbsReal* sampleNode = SampleFunction(channel, sample); + + // Get the observables for this channel + RooArgList observable_list( *GetObservableSet(channel) ); + + // Make the total histogram for this sample + std::string total_Name = sampleNode->GetName(); + TH1* total_hist= MakeHistFromRooFunction( sampleNode, observable_list, total_Name + "_tmp"); + unsigned int num_bins = total_hist->GetNbinsX()*total_hist->GetNbinsY()*total_hist->GetNbinsZ(); + + RooArgSet components; + + // Let's see what it is... + int label_print_width = 30; + int bin_print_width = 12; + if( strcmp(sampleNode->ClassName(),"RooProduct")==0){ + RooProduct* prod = dynamic_cast<RooProduct*>(sampleNode); + components.add( _GetAllProducts(prod) ); + } + else { + components.add(*sampleNode); + } + + /////// NODE SIZE + { + TIterator* itr = components.createIterator(); + RooAbsArg* arg = NULL; + while( (arg=(RooAbsArg*)itr->Next()) ) { + RooAbsReal* component = dynamic_cast<RooAbsReal*>(arg); + std::string NodeName = component->GetName(); + label_print_width = TMath::Max(label_print_width, (int)NodeName.size()+2); + } + } + + // Now, loop over the components and print them out: + std::cout << std::endl; + std::cout << "Channel: " << channel << " Sample: " << sample << std::endl; + std::cout << std::setw(label_print_width) << "Factor"; + + for(unsigned int i=0; i < num_bins; ++i) { + if( _minBinToPrint != -1 && (int)i < _minBinToPrint) continue; + if( _maxBinToPrint != -1 && (int)i > _maxBinToPrint) break; + std::stringstream sstr; + sstr << "Bin" << i; + std::cout << std::setw(bin_print_width) << sstr.str(); + } + std::cout << std::endl; + + TIterator* itr = components.createIterator(); + RooAbsArg* arg = NULL; + while( (arg=(RooAbsArg*)itr->Next()) ) { + RooAbsReal* component = dynamic_cast<RooAbsReal*>(arg); + std::string NodeName = component->GetName(); + + // Make a histogram for this node + // Do some horrible things to prevent some really + // annoying messages from being printed + RooFit::MsgLevel levelBefore = RooMsgService::instance().globalKillBelow(); + RooMsgService::instance().setGlobalKillBelow(RooFit::FATAL); + TH1* hist=NULL; + try { + hist = MakeHistFromRooFunction( component, observable_list, NodeName+"_tmp"); + } catch(...) { + RooMsgService::instance().setGlobalKillBelow(levelBefore); + throw; + } + RooMsgService::instance().setGlobalKillBelow(levelBefore); + + // Print the hist + std::cout << std::setw(label_print_width) << NodeName; + + // Print the Histogram + PrintMultiDimHist(hist, bin_print_width); + delete hist; + } + ///// + std::string line_break; + int high_bin = _maxBinToPrint==-1 ? num_bins : TMath::Min(_maxBinToPrint, (int)num_bins); + int low_bin = _minBinToPrint==-1 ? 1 : _minBinToPrint; + int break_length = (high_bin - low_bin + 1) * bin_print_width; + break_length += label_print_width; + for(int i = 0; i < break_length; ++i) { + line_break += "="; + } + std::cout << line_break << std::endl; + + std::cout << std::setw(label_print_width) << "TOTAL:"; + PrintMultiDimHist(total_hist, bin_print_width); + /* + for(unsigned int i = 0; i < num_bins; ++i) { + if( _minBinToPrint != -1 && (int)i < _minBinToPrint) continue; + if( _maxBinToPrint != -1 && (int)i > _maxBinToPrint) break; + std::cout << std::setw(bin_print_width) << total_hist->GetBinContent(i+1); + } + std::cout << std::endl << std::endl; + */ + delete total_hist; + + return; + + } + + + TH1* HistFactoryNavigation::MakeHistFromRooFunction( RooAbsReal* func, RooArgList vars, + std::string name ) { + + // Turn a RooAbsReal* into a TH1* based + // on a template histogram. + // The 'vars' arg list defines the x (and y and z variables) + // Loop over the bins of the Template, + // find the bin centers, + // Scan the input Var over those bin centers, + // and use the value of the function + // to make the new histogram + + // Make the new histogram + // Cone and empty the template + // TH1* hist = (TH1*) histTemplate.Clone( name.c_str() ); + + int dim = vars.getSize(); + + TH1* hist=NULL; + + if( dim==1 ) { + RooRealVar* varX = (RooRealVar*) vars.at(0); + hist = func->createHistogram( name.c_str(),*varX, RooFit::Binning(varX->getBinning()), RooFit::Scaling(false) ); + } + else if( dim==2 ) { + RooRealVar* varX = (RooRealVar*) vars.at(0); + RooRealVar* varY = (RooRealVar*) vars.at(1); + hist = func->createHistogram( name.c_str(),*varX, RooFit::Binning(varX->getBinning()), RooFit::Scaling(false), + RooFit::YVar(*varY, RooFit::Binning(varY->getBinning())) ); + } + else if( dim==3 ) { + RooRealVar* varX = (RooRealVar*) vars.at(0); + RooRealVar* varY = (RooRealVar*) vars.at(1); + RooRealVar* varZ = (RooRealVar*) vars.at(2); + hist = func->createHistogram( name.c_str(),*varX, RooFit::Binning(varX->getBinning()), RooFit::Scaling(false), + RooFit::YVar(*varY, RooFit::Binning(varY->getBinning())), + RooFit::YVar(*varZ, RooFit::Binning(varZ->getBinning())) ); + } + else { + std::cout << "Error: To Create Histogram from RooAbsReal function, Dimension must be 1, 2, or 3" << std::endl; + throw hf_exc(); + } + + return hist; + } + + // A simple wrapper to use a ModelConfig + void HistFactoryNavigation::_GetNodes(ModelConfig* mc) { + RooAbsPdf* modelPdf = mc->GetPdf(); + const RooArgSet* observables = mc->GetObservables(); + _GetNodes(modelPdf, observables); + } + + + void HistFactoryNavigation::SetConstant(const std::string& regExpr, bool constant) { + + // Regex FTW + + TString RegexTString(regExpr); + TRegexp theRegExpr(RegexTString); + + // Now, loop over all variables and + // set the constant as + + // Get the list of parameters + RooArgSet* params = fModel->getParameters(*fObservables); + + std::cout << std::endl; + + // Create the title row + std::cout << std::setw(30) << "Parameter"; + std::cout << std::setw(15) << "Value" + << std::setw(15) << "Error Low" + << std::setw(15) << "Error High" + << std::endl; + + // Loop over the parameters and print their values, etc + TIterator* paramItr = params->createIterator(); + RooRealVar* param = NULL; + while( (param=(RooRealVar*)paramItr->Next()) ) { + + std::string ParamName = param->GetName(); + TString ParamNameTString(ParamName); + + // Use the Regex to skip all parameters that don't match + //if( theRegExpr.Index(ParamNameTString, ParamName.size()) == -1 ) continue; + Ssiz_t dummy; + if( theRegExpr.Index(ParamNameTString, &dummy) == -1 ) continue; + + param->setConstant( constant ); + std::cout << "Setting param: " << ParamName << " constant" + << " (matches regex: " << regExpr << ")" << std::endl; + } + } + + RooRealVar* HistFactoryNavigation::var(const std::string& varName) const { + + RooAbsArg* arg = findChild(varName, fModel); + if( !arg ) return NULL; + + RooRealVar* var_obj = dynamic_cast<RooRealVar*>(arg); + return var_obj; + + } + + /* + void HistFactoryNavigation::AddChannel(const std::string& channel, RooAbsPdf* pdf, + RooDataSet* data=NULL) { + + } + */ + + } // namespace HistFactory +} // namespace RooStats + + + + diff --git a/roofit/histfactory/src/HistFactorySimultaneous.cxx b/roofit/histfactory/src/HistFactorySimultaneous.cxx new file mode 100644 index 0000000000000..c129956617cd3 --- /dev/null +++ b/roofit/histfactory/src/HistFactorySimultaneous.cxx @@ -0,0 +1,128 @@ +/***************************************************************************** + * Project: RooFit * + * Package: RooFitCore * + * @(#)root/roofitcore:$Id$ + * Authors: * + * WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu * + * DK, David Kirkby, UC Irvine, dkirkby@uci.edu * + * * + * Copyright (c) 2000-2005, Regents of the University of California * + * and Stanford University. All rights reserved. * + * * + * Redistribution and use in source and binary forms, * + * with or without modification, are permitted according to the terms * + * listed in LICENSE (http://roofit.sourceforge.net/license.txt) * + *****************************************************************************/ + +////////////////////////////////////////////////////////////////////////////// +// +// BEGIN_HTML +// RooSimultaneous facilitates simultaneous fitting of multiple PDFs +// to subsets of a given dataset. +// <p> +// The class takes an index category, which is interpreted as +// the data subset indicator, and a list of PDFs, each associated +// with a state of the index category. RooSimultaneous always returns +// the value of the PDF that is associated with the current value +// of the index category +// <p> +// Extended likelihood fitting is supported if all components support +// extended likelihood mode. The expected number of events by a RooSimultaneous +// is that of the component p.d.f. selected by the index category +// END_HTML +// + + +#include "RooNLLVar.h" + +#include "RooStats/HistFactory/RooBarlowBeestonLL.h" +#include "RooStats/HistFactory/HistFactorySimultaneous.h" + +using namespace std ; + +ClassImp(RooStats::HistFactory::HistFactorySimultaneous) +; + + +//_____________________________________________________________________________ +RooStats::HistFactory::HistFactorySimultaneous::HistFactorySimultaneous(const char *name, const char *title, + RooAbsCategoryLValue& inIndexCat) : + RooSimultaneous(name, title, inIndexCat ) {} + + +//_____________________________________________________________________________ +RooStats::HistFactory::HistFactorySimultaneous::HistFactorySimultaneous(const char *name, const char *title, + const RooArgList& inPdfList, RooAbsCategoryLValue& inIndexCat) : + RooSimultaneous(name, title, inPdfList, inIndexCat) {} + + +//_____________________________________________________________________________ +RooStats::HistFactory::HistFactorySimultaneous::HistFactorySimultaneous(const char *name, const char *title, + map<string,RooAbsPdf*> pdfMap, RooAbsCategoryLValue& inIndexCat) : + RooSimultaneous(name, title, pdfMap, inIndexCat) {} + + +//_____________________________________________________________________________ +RooStats::HistFactory::HistFactorySimultaneous::HistFactorySimultaneous(const HistFactorySimultaneous& other, const char* name) : + RooSimultaneous(other, name) {} + +//_____________________________________________________________________________ +RooStats::HistFactory::HistFactorySimultaneous::HistFactorySimultaneous(const RooSimultaneous& other, const char* name) : + RooSimultaneous(other, name) {} + +//_____________________________________________________________________________ +RooStats::HistFactory::HistFactorySimultaneous::~HistFactorySimultaneous() +{ + // Destructor +} + + +//_____________________________________________________________________________ +RooAbsReal* RooStats::HistFactory::HistFactorySimultaneous::createNLL(RooAbsData& data, + const RooCmdArg& arg1, const RooCmdArg& arg2, + const RooCmdArg& arg3, const RooCmdArg& arg4, + const RooCmdArg& arg5, const RooCmdArg& arg6, + const RooCmdArg& arg7, const RooCmdArg& arg8) { + + // Probably not necessary because createNLL is virtual... + + RooLinkedList l ; + l.Add((TObject*)&arg1) ; l.Add((TObject*)&arg2) ; + l.Add((TObject*)&arg3) ; l.Add((TObject*)&arg4) ; + l.Add((TObject*)&arg5) ; l.Add((TObject*)&arg6) ; + l.Add((TObject*)&arg7) ; l.Add((TObject*)&arg8) ; + return createNLL(data,l) ; + +} + + +//_____________________________________________________________________________ + +RooAbsReal* RooStats::HistFactory::HistFactorySimultaneous::createNLL(RooAbsData& data, const RooLinkedList& cmdList) { + + // We want to overload the method createNLL so it return + // a RooBarlow-Beeston NLL function, which can be used + // in HistFactory to minimize statistical uncertainty analytically + // + // The only problem is one of ownership + // This HistFactorySimultaneous and the RooAbsData& data must + // exist for as long as the RooBarlowBeestonLL does + // + // This could be solved if we instead refer to the cloned + // pdf's and data set in the nll that we create here, but + // it's unclear how to do so + // + // Also, check for ownership/memory issue with the newly created nll + // and whether RooBarlowBeestonLL owns it, etc + + // Create a standard nll + RooNLLVar* nll = (RooNLLVar*) RooSimultaneous::createNLL( data, cmdList ); + + RooBarlowBeestonLL* bbnll = new RooBarlowBeestonLL("bbnll", "bbnll", *nll); //, *observables); + bbnll->setPdf( this ); + bbnll->setDataset( &data ); + bbnll->initializeBarlowCache(); + + return bbnll; + +} diff --git a/roofit/histfactory/src/HistoToWorkspaceFactory.cxx b/roofit/histfactory/src/HistoToWorkspaceFactory.cxx index 127e3c4761323..5a09ee1faf682 100644 --- a/roofit/histfactory/src/HistoToWorkspaceFactory.cxx +++ b/roofit/histfactory/src/HistoToWorkspaceFactory.cxx @@ -67,9 +67,9 @@ END_HTML // specific to this package //#include "RooStats/HistFactory/Helper.h" -#include "Helper.h" #include "RooStats/HistFactory/LinInterpVar.h" #include "RooStats/HistFactory/HistoToWorkspaceFactory.h" +#include "Helper.h" #define VERBOSE @@ -430,11 +430,11 @@ namespace HistFactory{ string pdfName(pdfNameChar); map<string,string>::iterator it; string edit="EDIT::customized("+pdfName+","; - string preceed=""; + string precede=""; for(it=renameMap.begin(); it!=renameMap.end(); ++it) { cout << it->first + "=" + it->second << endl; - edit+=preceed + it->first + "=" + it->second; - preceed=","; + edit+=precede + it->first + "=" + it->second; + precede=","; } edit+=")"; cout << edit<< endl; @@ -452,7 +452,7 @@ namespace HistFactory{ string edit="EDIT::newSimPdf("+pdfName+","; string editList; string lastPdf=pdfName; - string preceed=""; + string precede=""; unsigned int numReplacements = 0; unsigned int nskipped = 0; map<string,double>::iterator it; @@ -507,10 +507,10 @@ namespace HistFactory{ // replace alphas with alphaOfBeta and replace constraints //cout << "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint" << endl; - editList+=preceed + "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint"; - preceed=","; + editList+=precede + "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint"; + precede=","; // cout << "alpha_"+it->first+"=alphaOfBeta_"+ it->first << endl; - editList+=preceed + "alpha_"+it->first+"=alphaOfBeta_"+ it->first; + editList+=precede + "alpha_"+it->first+"=alphaOfBeta_"+ it->first; /* if( proto->pdf(("alpha_"+it->first+"Constraint").c_str()) && proto->var(("alpha_"+it->first).c_str()) ) @@ -524,7 +524,7 @@ namespace HistFactory{ edit="EDIT::"+lastPdf+"_("+lastPdf+","+editList+")"; lastPdf+="_"; // append an underscore for the edit editList=""; // reset edit list - preceed=""; + precede=""; cout << "Going to issue this edit command\n" << edit<< endl; proto->factory( edit.c_str() ); RooAbsPdf* newOne = proto->pdf(lastPdf.c_str()); @@ -559,10 +559,10 @@ namespace HistFactory{ // replace alphas with alphaOfBeta and replace constraints cout << "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint" << endl; - editList+=preceed + "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint"; - preceed=","; + editList+=precede + "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint"; + precede=","; cout << "alpha_"+it->first+"=alphaOfBeta_"+ it->first << endl; - editList+=preceed + "alpha_"+it->first+"=alphaOfBeta_"+ it->first; + editList+=precede + "alpha_"+it->first+"=alphaOfBeta_"+ it->first; if( proto->pdf(("alpha_"+it->first+"Constraint").c_str()) && proto->var(("alpha_"+it->first).c_str()) ) cout << " checked they are there" << proto->pdf(("alpha_"+it->first+"Constraint").c_str()) << " " << proto->var(("alpha_"+it->first).c_str()) << endl; @@ -574,7 +574,7 @@ namespace HistFactory{ edit="EDIT::"+lastPdf+"_("+lastPdf+","+editList+")"; lastPdf+="_"; // append an underscore for the edit editList=""; // reset edit list - preceed=""; + precede=""; cout << edit<< endl; proto->factory( edit.c_str() ); RooAbsPdf* newOne = proto->pdf(lastPdf.c_str()); @@ -626,10 +626,10 @@ namespace HistFactory{ // replace alphas with alphaOfBeta and replace constraints cout << "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint" << endl; - editList+=preceed + "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint"; - preceed=","; + editList+=precede + "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint"; + precede=","; cout << "alpha_"+it->first+"=alphaOfBeta_"+ it->first << endl; - editList+=preceed + "alpha_"+it->first+"=alphaOfBeta_"+ it->first; + editList+=precede + "alpha_"+it->first+"=alphaOfBeta_"+ it->first; if( proto->pdf(("alpha_"+it->first+"Constraint").c_str()) && proto->var(("alpha_"+it->first).c_str()) ) cout << " checked they are there" << proto->pdf(("alpha_"+it->first+"Constraint").c_str()) << " " << proto->var(("alpha_"+it->first).c_str()) << endl; @@ -641,7 +641,7 @@ namespace HistFactory{ edit="EDIT::"+lastPdf+"_("+lastPdf+","+editList+")"; lastPdf+="_"; // append an underscore for the edit editList=""; // reset edit list - preceed=""; + precede=""; cout << edit<< endl; proto->factory( edit.c_str() ); RooAbsPdf* newOne = proto->pdf(lastPdf.c_str()); diff --git a/roofit/histfactory/src/HistoToWorkspaceFactoryFast.cxx b/roofit/histfactory/src/HistoToWorkspaceFactoryFast.cxx index 5af765911576c..67f91393a80a0 100644 --- a/roofit/histfactory/src/HistoToWorkspaceFactoryFast.cxx +++ b/roofit/histfactory/src/HistoToWorkspaceFactoryFast.cxx @@ -22,7 +22,6 @@ END_HTML #include "RooGlobalFunc.h" #endif -// Roofit/Roostat include #include "RooDataSet.h" #include "RooRealVar.h" #include "RooConstVar.h" @@ -55,6 +54,7 @@ END_HTML #include "RooStats/ModelConfig.h" #include "RooStats/HistFactory/PiecewiseInterpolation.h" #include "RooStats/HistFactory/ParamHistFunc.h" +#include "RooStats/AsymptoticCalculator.h" #include "TH2F.h" #include "TH3F.h" @@ -71,11 +71,11 @@ END_HTML #include "TMatrixDSym.h" // specific to this package -//#include "RooStats/HistFactory/Helper.h" -#include "Helper.h" #include "RooStats/HistFactory/LinInterpVar.h" #include "RooStats/HistFactory/FlexibleInterpVar.h" #include "RooStats/HistFactory/HistoToWorkspaceFactoryFast.h" +#include "RooStats/HistFactory/Measurement.h" +#include "Helper.h" #include <algorithm> @@ -90,7 +90,6 @@ END_HTML using namespace RooFit ; using namespace RooStats ; using namespace std ; -//using namespace RooMsgService ; ClassImp(RooStats::HistFactory::HistoToWorkspaceFactoryFast) @@ -98,57 +97,23 @@ namespace RooStats{ namespace HistFactory{ HistoToWorkspaceFactoryFast::HistoToWorkspaceFactoryFast() : - fNomLumi(0), fLumiError(0), + fNomLumi(1.0), fLumiError(0), fLowBin(0), fHighBin(0) {} HistoToWorkspaceFactoryFast::~HistoToWorkspaceFactoryFast(){ } - HistoToWorkspaceFactoryFast::HistoToWorkspaceFactoryFast(string /*filePrefix*/, string /*row*/, vector<string> syst, double nomL, double lumiE, int low, int high, TFile* /*file*/): - //fFileNamePrefix(filePrefix), - //fRowTitle(row), - fSystToFix(syst), - fNomLumi(nomL), - fLumiError(lumiE), - fLowBin(low), - fHighBin(high) { - - /* - fResultsPrefixStr<< "_" << fRowTitle; - while(fRowTitle.find("\\ ")!=string::npos){ - int pos=fRowTitle.find("\\ "); - fRowTitle.replace(pos, 1, ""); - } - */ - //RooMsgService::instance().setGlobalKillBelow(RooFit::ERROR) ; - - } - HistoToWorkspaceFactoryFast::HistoToWorkspaceFactoryFast(RooStats::HistFactory::Measurement& measurement ) : - // fFileNamePrefix( measurement.GetOutputFilePrefix() ), - // fRowTitle( measurement.GetName() ), fSystToFix( measurement.GetConstantParams() ), + fParamValues( measurement.GetParamValues() ), fNomLumi( measurement.GetLumi() ), fLumiError( measurement.GetLumi()*measurement.GetLumiRelErr() ), fLowBin( measurement.GetBinLow() ), fHighBin( measurement.GetBinHigh() ) { - - // Configure the prefix string - /* - fResultsPrefixStr<< "_" << fRowTitle; - while(fRowTitle.find("\\ ")!=string::npos){ - int pos=fRowTitle.find("\\ "); - fRowTitle.replace(pos, 1, ""); - } - */ - // Set Preprocess functions SetFunctionsToPreprocess( measurement.GetPreprocessFunctions() ); - - - //RooMsgService::instance().setGlobalKillBelow(RooFit::ERROR) ; } @@ -160,33 +125,112 @@ namespace HistFactory{ // Make a ModelConfig and configure it ModelConfig * proto_config = (ModelConfig *) ws_single->obj("ModelConfig"); - cout << "Setting Parameter of Interest as :" << measurement.GetPOI() << endl; - RooRealVar* poi = (RooRealVar*) ws_single->var( (measurement.GetPOI()).c_str() ); + if( proto_config == NULL ) { + std::cout << "Error: Did not find 'ModelConfig' object in file: " << ws_single->GetName() + << std::endl; + throw hf_exc(); + } + + std::vector<std::string> poi_list = measurement.GetPOIList(); + if( poi_list.size()==0 ) { + std::cout << "Warining: No Parametetrs of interest are set" << std::endl; + } + + cout << "Setting Parameter(s) of Interest as: "; + for(unsigned int i = 0; i < poi_list.size(); ++i) { + cout << poi_list.at(i) << " "; + } + cout << endl; + RooArgSet * params= new RooArgSet; - if(poi){ - params->add(*poi); + for( unsigned int i = 0; i < poi_list.size(); ++i ) { + std::string poi_name = poi_list.at(i); + RooRealVar* poi = (RooRealVar*) ws_single->var( poi_name.c_str() ); + if(poi){ + params->add(*poi); + } + else { + std::cout << "WARNING: Can't find parameter of interest: " << poi_name + << " in Workspace. Not setting in ModelConfig." << std::endl; + //throw hf_exc(); + } } proto_config->SetParametersOfInterest(*params); + // Name of an 'edited' model, if necessary + std::string NewModelName = "newSimPdf"; // <- This name is hard-coded in HistoToWorkspaceFactoryFast::EditSyt. Probably should be changed to : std::string("new") + ModelName; + // Activate Additional Constraint Terms - if( measurement.GetGammaSyst().size()>0 || measurement.GetUniformSyst().size()>0 || measurement.GetLogNormSyst().size()>0 || measurement.GetNoSyst().size()>0) { - //factory.EditSyst( ws_single, ("model_"+ch_name).c_str(), measurement.GetGammaSyst(), measurement.GetUniformSyst(), measurement.GetLogNormSyst(), measurement.GetNoSyst()); - HistoToWorkspaceFactoryFast::EditSyst( ws_single, (ModelName).c_str(), measurement.GetGammaSyst(), measurement.GetUniformSyst(), measurement.GetLogNormSyst(), measurement.GetNoSyst()); - std::string NewModelName = "newSimPdf"; // <- This name is hard-coded in HistoToWorkspaceFactoryFast::EditSyt. Probably should be changed to : std::string("new") + ModelName; + if( measurement.GetGammaSyst().size() > 0 + || measurement.GetUniformSyst().size() > 0 + || measurement.GetLogNormSyst().size() > 0 + || measurement.GetNoSyst().size() > 0) { + HistoToWorkspaceFactoryFast::EditSyst( ws_single, (ModelName).c_str(), + measurement.GetGammaSyst(), + measurement.GetUniformSyst(), + measurement.GetLogNormSyst(), + measurement.GetNoSyst()); + proto_config->SetPdf( *ws_single->pdf( "newSimPdf" ) ); } // Set the ModelConfig's Params of Interest RooAbsData* expData = ws_single->data("asimovData"); - if(poi){ + if( !expData ) { + std::cout << "Error: Failed to find dataset: " << expData + << " in workspace" << std::endl; + throw hf_exc(); + } + if(poi_list.size()!=0){ proto_config->GuessObsAndNuisance(*expData); } + // Now, let's loop over any additional asimov datasets + // that we need to make + + // Get the pdf + // Notice that we get the "new" pdf, this is the one that is + // used in the creation of these asimov datasets since they + // are fitted (or may be, at least). + RooAbsPdf* pdf = ws_single->pdf(NewModelName.c_str()); + if( !pdf ) pdf = ws_single->pdf( ModelName.c_str() ); + const RooArgSet* observables = ws_single->set("observables"); + + // Create a SnapShot of the nominal values + std::string SnapShotName = "NominalParamValues"; + ws_single->saveSnapshot(SnapShotName.c_str(), ws_single->allVars()); + + for( unsigned int i=0; i<measurement.GetAsimovDatasets().size(); ++i) { + + // Set the variable values and "const" ness with the workspace + RooStats::HistFactory::Asimov& asimov = measurement.GetAsimovDatasets().at(i); + std::string AsimovName = asimov.GetName(); + + std::cout << "Generating additional Asimov Dataset: " << AsimovName << std::endl; + asimov.ConfigureWorkspace(ws_single); + RooDataSet* asimov_dataset = + (RooDataSet*) AsymptoticCalculator::GenerateAsimovData(*pdf, *observables); + + std::cout << "Importing Asimov dataset" << std::endl; + double failure = ws_single->import(*asimov_dataset, Rename(AsimovName.c_str())); + if( failure ) { + std::cout << "Error: Failed to import Asimov dataset: " << AsimovName + << std::endl; + throw hf_exc(); + } + + // Load the snapshot at the end of every loop iteration + // so we start each loop with a "clean" snapshot + ws_single->loadSnapshot(SnapShotName.c_str()); + + } + // Cool, we're done return; // ws_single; } + // We want to eliminate this interface and use the measurment directly RooWorkspace* HistoToWorkspaceFactoryFast::MakeSingleChannelModel( Measurement& measurement, Channel& channel ) { // This is a pretty light-weight wrapper function @@ -201,12 +245,14 @@ namespace HistFactory{ // Get the channel's name string ch_name = channel.GetName(); - // First, turn the channel into a vector of estimate summaries - std::vector<EstimateSummary> channel_estimateSummary = GetChannelEstimateSummaries( measurement, channel ); - - // Then, use HistFactory on that vector to create the workspace - RooWorkspace* ws_single = this->MakeSingleChannelModel(channel_estimateSummary, measurement.GetConstantParams()); - + // Create a workspace for a SingleChannel from the Measurement Object + RooWorkspace* ws_single = this->MakeSingleChannelWorkspace(measurement, channel); + if( ws_single == NULL ) { + std::cout << "Error: Failed to make Single-Channel workspace for channel: " << ch_name + << " and measurement: " << measurement.GetName() << std::endl; + throw hf_exc(); + } + // Finally, configure that workspace based on // properties of the measurement HistoToWorkspaceFactoryFast::ConfigureWorkspaceForMeasurement( "model_"+ch_name, ws_single, measurement ); @@ -228,16 +274,12 @@ namespace HistFactory{ // it a one-liner // First, we create an instance of a HistFactory - HistoToWorkspaceFactoryFast factory( measurement ); - // Loop over the channels and create the individual workspaces - vector<RooWorkspace*> channel_workspaces; vector<string> channel_names; - for( unsigned int chanItr = 0; chanItr < measurement.GetChannels().size(); ++chanItr ) { HistFactory::Channel& channel = measurement.GetChannels().at( chanItr ); @@ -245,13 +287,13 @@ namespace HistFactory{ if( ! channel.CheckHistograms() ) { std::cout << "MakeModelAndMeasurementsFast: Channel: " << channel.GetName() << " has uninitialized histogram pointers" << std::endl; - throw bad_hf; - return NULL; + throw hf_exc(); } string ch_name = channel.GetName(); channel_names.push_back(ch_name); + // GHL: Renaming to 'MakeSingleChannelWorkspace' RooWorkspace* ws_single = factory.MakeSingleChannelModel( measurement, channel ); channel_workspaces.push_back(ws_single); @@ -261,34 +303,25 @@ namespace HistFactory{ // Now, combine the individual channel workspaces to // form the combined workspace - RooWorkspace* ws = factory.MakeCombinedModel( channel_names, channel_workspaces ); // Configure the workspace - HistoToWorkspaceFactoryFast::ConfigureWorkspaceForMeasurement( "simPdf", ws, measurement ); - // Done. Return the pointer + // Delete channel workspaces + for (vector<RooWorkspace*>::iterator iter = channel_workspaces.begin() ; iter != channel_workspaces.end() ; ++iter) { + delete *iter ; + } + // Done. Return the pointer return ws; - - } - - /* - string HistoToWorkspaceFactoryFast::FilePrefixStr(string prefix){ - - stringstream ss; - ss << prefix << "_" << fNomLumi<< "_" << fLumiError<< "_" << fLowBin<< "_" << fHighBin<< "_"<<fRowTitle; - - return ss.str(); } - */ - void HistoToWorkspaceFactoryFast::ProcessExpectedHisto(TH1* hist,RooWorkspace* proto, string prefix, string - productPrefix, string systTerm, double /*low*/ , double - /*high*/, int /*lowBin*/, int /*highBin*/ ){ + void HistoToWorkspaceFactoryFast::ProcessExpectedHisto(TH1* hist,RooWorkspace* proto, + string prefix, string productPrefix, + string systTerm ) { if(hist) { cout << "processing hist " << hist->GetName() << endl; } else { @@ -330,14 +363,12 @@ namespace HistFactory{ RooDataHist* histDHist = new RooDataHist((prefix+"nominalDHist").c_str(),"",observables,hist); RooHistFunc* histFunc = new RooHistFunc((prefix+"_nominal").c_str(),"",observables,*histDHist,0) ; - //RooHistPdf* histPdf = new RooHistPdf((prefix+"_nominalpdf").c_str(),"",observables,*histDHist,0); proto->import(*histFunc); - //proto->import(*histPdf); /// now create the product of the overall efficiency times the sigma(params) for this estimate proto->factory(("prod:"+productPrefix+"("+prefix+"_nominal,"+systTerm+")").c_str() ); - // proto->Print(); + } void HistoToWorkspaceFactoryFast::AddMultiVarGaussConstraint(RooWorkspace* proto, string prefix,int lowBin, int highBin, vector<string>& constraintTermNames){ @@ -360,6 +391,7 @@ namespace HistFactory{ else { Cov(i,j) = 0; } } } + // can't make MultiVarGaussian with factory yet, do it by hand RooArgList floating( *(proto->set(prefix.c_str() ) ) ); RooMultiVarGaussian constraint((prefix+"Constraint").c_str(),"", @@ -370,10 +402,12 @@ namespace HistFactory{ constraintTermNames.push_back(constraint.GetName()); } + void HistoToWorkspaceFactoryFast::LinInterpWithConstraint(RooWorkspace* proto, TH1* nominal, + std::vector<HistoSys> histoSysList, + string prefix, string productPrefix, + string systTerm, + vector<string>& constraintTermNames){ - void HistoToWorkspaceFactoryFast::LinInterpWithConstraint(RooWorkspace* proto, TH1* nominal, vector<TH1*> lowHist, vector<TH1*> highHist, - vector<string> sourceName, string prefix, string productPrefix, string systTerm, - int /*lowBin*/, int /*highBin */, vector<string>& constraintTermNames){ // these are the nominal predictions: eg. the mean of some space of variations // later fill these in a loop over histogram bins @@ -395,10 +429,16 @@ namespace HistFactory{ std::vector<std::string>::iterator itr = fObsNameVec.begin(); for (int idx=0; itr!=fObsNameVec.end(); ++itr, ++idx ) { if ( !proto->var(itr->c_str()) ) { - TAxis* axis(0); + TAxis* axis(NULL); if (idx==0) { axis = nominal->GetXaxis(); } - if (idx==1) { axis = nominal->GetYaxis(); } - if (idx==2) { axis = nominal->GetZaxis(); } + else if (idx==1) { axis = nominal->GetYaxis(); } + else if (idx==2) { axis = nominal->GetZaxis(); } + else { + std::cout << "Error: Too many observables. " + << "HistFactory only accepts up to 3 observables (3d) " + << std::endl; + throw hf_exc(); + } Int_t nbins = axis->GetNbins(); Double_t xmin = axis->GetXmin(); Double_t xmax = axis->GetXmax(); @@ -416,20 +456,26 @@ namespace HistFactory{ RooArgList params( ("alpha_Hist") ); // range is set using defined macro (see top of the page) string range=string("[")+alpha_Low+","+alpha_High+"]"; - for(unsigned int j=0; j<lowHist.size(); ++j){ + + // Loop over the HistoSys list + for(unsigned int j=0; j<histoSysList.size(); ++j){ std::stringstream str; str<<"_"<<j; - RooRealVar* temp = (RooRealVar*) proto->var(("alpha_"+sourceName.at(j)).c_str()); + HistoSys& histoSys = histoSysList.at(j); + string histoSysName = histoSys.GetName(); + + RooRealVar* temp = (RooRealVar*) proto->var(("alpha_" + histoSysName).c_str()); if(!temp){ - temp = (RooRealVar*) proto->factory(("alpha_"+sourceName.at(j)+range).c_str()); + + temp = (RooRealVar*) proto->factory(("alpha_" + histoSysName + range).c_str()); // now add a constraint term for these parameters - string command=("Gaussian::alpha_"+sourceName.at(j)+"Constraint(alpha_"+sourceName.at(j)+",nom_alpha_"+sourceName.at(j)+"[0.,-10,10],1.)"); + string command=("Gaussian::alpha_"+histoSysName+"Constraint(alpha_"+histoSysName+",nom_alpha_"+histoSysName+"[0.,-10,10],1.)"); cout << command << endl; constraintTermNames.push_back( proto->factory( command.c_str() )->GetName() ); - proto->var(("nom_alpha_"+sourceName.at(j)).c_str())->setConstant(); - const_cast<RooArgSet*>(proto->set("globalObservables"))->add(*proto->var(("nom_alpha_"+sourceName.at(j)).c_str())); + proto->var(("nom_alpha_"+histoSysName).c_str())->setConstant(); + const_cast<RooArgSet*>(proto->set("globalObservables"))->add(*proto->var(("nom_alpha_"+histoSysName).c_str())); } params.add(* temp ); } @@ -438,13 +484,14 @@ namespace HistFactory{ // get low/high variations to interpolate between vector<double> low, high; RooArgSet lowSet, highSet; - for(unsigned int j=0; j<lowHist.size(); ++j){ + //ES// for(unsigned int j=0; j<lowHist.size(); ++j){ + for(unsigned int j=0; j<histoSysList.size(); ++j){ std::stringstream str; str<<"_"<<j; - lowHist.at(j); - highHist.at(j); - RooDataHist* lowDHist = new RooDataHist((prefix+str.str()+"lowDHist").c_str(),"",observables,lowHist.at(j)); - RooDataHist* highDHist = new RooDataHist((prefix+str.str()+"highDHist").c_str(),"",observables,highHist.at(j)); + + HistoSys& histoSys = histoSysList.at(j); + RooDataHist* lowDHist = new RooDataHist((prefix+str.str()+"lowDHist").c_str(),"",observables, histoSys.GetHistoLow()); + RooDataHist* highDHist = new RooDataHist((prefix+str.str()+"highDHist").c_str(),"",observables, histoSys.GetHistoHigh()); RooHistFunc* lowFunc = new RooHistFunc((prefix+str.str()+"low").c_str(),"",observables,*lowDHist,0) ; RooHistFunc* highFunc = new RooHistFunc((prefix+str.str()+"high").c_str(),"",observables,*highDHist,0) ; lowSet.add(*lowFunc); @@ -454,63 +501,75 @@ namespace HistFactory{ // this is sigma(params), a piece-wise linear interpolation PiecewiseInterpolation interp(prefix.c_str(),"",*nominalFunc,lowSet,highSet,params); interp.setPositiveDefinite(); - interp.setAllInterpCodes(0); // MB : change default to 1? = piece-wise log interpolation from pice-wise linear (=0) + interp.setAllInterpCodes(4); // LM: change to 4 (piece-wise linear to 6th order polynomial interpolation + linear extrapolation ) // KC: interpo codes 1 etc. don't have proper analytic integral. RooArgSet observableSet(observables); interp.setBinIntegrator(observableSet); interp.forceNumInt(); - // cout << "check: " << interp.getVal() << endl; proto->import(interp); // individual params have already been imported in first loop of this function // now create the product of the overall efficiency times the sigma(params) for this estimate proto->factory(("prod:"+productPrefix+"("+prefix+","+systTerm+")").c_str() ); - // proto->Print(); } - string HistoToWorkspaceFactoryFast::AddNormFactor(RooWorkspace * proto, string & channel, string & sigmaEpsilon, EstimateSummary & es, bool doRatio){ + // GHL: Consider passing the NormFactor list instead of the entire sample + string HistoToWorkspaceFactoryFast::AddNormFactor(RooWorkspace* proto, string& channel, string& sigmaEpsilon, Sample& sample, bool doRatio){ string overallNorm_times_sigmaEpsilon ; string prodNames; - vector<EstimateSummary::NormFactor> norm=es.normFactor; + + vector<NormFactor> normList = sample.GetNormFactorList(); vector<string> normFactorNames, rangeNames; - if(norm.size()){ - for(vector<EstimateSummary::NormFactor>::iterator itr=norm.begin(); itr!=norm.end(); ++itr){ - cout << "making normFactor: " << itr->name << endl; - // remove "doRatio" and name can be changed when ws gets imported to the combined model. - std::stringstream range; - range<<"["<<itr->val<<","<<itr->low<<","<<itr->high<<"]"; + + if(normList.size() > 0){ + + for(vector<NormFactor>::iterator itr = normList.begin(); itr != normList.end(); ++itr){ + + NormFactor& norm = *itr; string varname; - if(!prodNames.empty()) prodNames+=","; + if(!prodNames.empty()) prodNames += ","; if(doRatio) { - varname=itr->name+"_"+channel; + varname = norm.GetName() + "_" + channel; } else { - varname=itr->name; + varname=norm.GetName(); } - proto->factory((varname+range.str()).c_str()); - if(itr->constant){ + + // GHL: Check that the NormFactor doesn't already exist + // (it may have been created as a function expression + // during preprocessing) + std::stringstream range; + range << "[" << norm.GetVal() << "," << norm.GetLow() << "," << norm.GetHigh() << "]"; + + if( proto->obj(varname.c_str()) == NULL) { + cout << "making normFactor: " << norm.GetName() << endl; + // remove "doRatio" and name can be changed when ws gets imported to the combined model. + proto->factory((varname + range.str()).c_str()); + } + + if(norm.GetConst()) { // proto->var(varname.c_str())->setConstant(); // cout <<"setting " << varname << " constant"<<endl; - cout <<"WARNING: Const attribute to <NormFactor> tag is deprecated, will ignore."<< - " Instead, add \n\t<ParamSetting Const=\"True\">"<<varname<<"</ParamSetting>\n"<< - " to your top-level XML's <Measurment> entry"<< endl; + cout << "WARNING: Const attribute to <NormFactor> tag is deprecated, will ignore." << + " Instead, add \n\t<ParamSetting Const=\"True\">" << varname << "</ParamSetting>\n" << + " to your top-level XML's <Measurment> entry" << endl; } prodNames+=varname; rangeNames.push_back(range.str()); normFactorNames.push_back(varname); } - overallNorm_times_sigmaEpsilon = es.name+"_"+channel+"_overallNorm_x_sigma_epsilon"; - proto->factory(("prod::"+overallNorm_times_sigmaEpsilon+"("+prodNames+","+sigmaEpsilon+")").c_str()); + + overallNorm_times_sigmaEpsilon = sample.GetName() + "_" + channel + "_overallNorm_x_sigma_epsilon"; + proto->factory(("prod::" + overallNorm_times_sigmaEpsilon + "(" + prodNames + "," + sigmaEpsilon + ")").c_str()); } unsigned int rangeIndex=0; for( vector<string>::iterator nit = normFactorNames.begin(); nit!=normFactorNames.end(); ++nit){ if( count (normFactorNames.begin(), normFactorNames.end(), *nit) > 1 ){ cout <<"WARNING: <NormFactor Name =\""<<*nit<<"\"> is duplicated for <Sample Name=\"" - << es.name <<"\">, but only one factor will be included. \n Instead, define something like" - // << "\n\t<Function Name=\""<<*nit<<"Squared\" Expresion=\""<<*nit<<"\" Var=\""<<*nit<<range<<"\">" + << sample.GetName() << "\">, but only one factor will be included. \n Instead, define something like" << "\n\t<Function Name=\""<<*nit<<"Squared\" Expresion=\""<<*nit<<"*"<<*nit<<"\" Var=\""<<*nit<<rangeNames.at(rangeIndex) << "\"> \nin your top-level XML's <Measurment> entry and use <NormFactor Name=\""<<*nit<<"Squared\" in your channel XML file."<< endl; } @@ -523,46 +582,56 @@ namespace HistFactory{ return sigmaEpsilon; } + void HistoToWorkspaceFactoryFast::AddEfficiencyTerms(RooWorkspace* proto, string prefix, + string interpName, + std::vector<OverallSys>& systList, + vector<string>& constraintTermNames, + vector<string>& totSystTermNames) { - void HistoToWorkspaceFactoryFast::AddEfficiencyTerms(RooWorkspace* proto, string prefix, string interpName, - map<string,pair<double,double> > systMap, - vector<string>& constraintTermNames, vector<string>& totSystTermNames){ // add variables for all the relative overall uncertainties we expect - // range is set using defined macro (see top of the page) + string range=string("[0,")+alpha_Low+","+alpha_High+"]"; - //string range="[0,-1,1]"; totSystTermNames.push_back(prefix); - //bool first=true; + RooArgSet params(prefix.c_str()); vector<double> lowVec, highVec; - for(map<string,pair<double,double> >::iterator it=systMap.begin(); it!=systMap.end(); ++it){ + + for(unsigned int i = 0; i < systList.size(); ++i) { + + OverallSys& sys = systList.at(i); + // add efficiency term - RooRealVar* temp = (RooRealVar*) proto->var((prefix+ it->first).c_str()); - if(!temp){ - temp = (RooRealVar*) proto->factory((prefix+ it->first +range).c_str()); + RooRealVar* temp = (RooRealVar*) proto->var((prefix + sys.GetName()).c_str()); + if(!temp) { + + temp = (RooRealVar*) proto->factory((prefix + sys.GetName() + range).c_str()); + string command=("Gaussian::" + prefix + sys.GetName() + + "Constraint(" + prefix + sys.GetName() + + ",nom_" + prefix + sys.GetName() + "[0.,-10,10],1.)"); - string command=("Gaussian::"+prefix+it->first+"Constraint("+prefix+it->first+",nom_"+prefix+it->first+"[0.,-10,10],1.)"); cout << command << endl; - constraintTermNames.push_back( proto->factory( command.c_str() )->GetName() ); - proto->var(("nom_"+prefix+it->first).c_str())->setConstant(); - const_cast<RooArgSet*>(proto->set("globalObservables"))->add(*proto->var(("nom_"+prefix+it->first).c_str())); + constraintTermNames.push_back( proto->factory( command.c_str() )->GetName() ); + proto->var(("nom_" + prefix + sys.GetName()).c_str())->setConstant(); + const_cast<RooArgSet*>(proto->set("globalObservables"))->add(*proto->var(("nom_" + prefix + sys.GetName()).c_str())); } + params.add(*temp); // add constraint in terms of bifrucated gauss with low/high as sigmas std::stringstream lowhigh; - double low = it->second.first; - double high = it->second.second; + double low = sys.GetLow(); + double high = sys.GetHigh(); lowVec.push_back(low); highVec.push_back(high); } - if(systMap.size()>0){ + + if(systList.size() > 0){ // this is epsilon(alpha_j), a piece-wise linear interpolation // LinInterpVar interp( (interpName).c_str(), "", params, 1., lowVec, highVec); - FlexibleInterpVar interp( (interpName).c_str(), "", params, 1., lowVec, highVec); - interp.setAllInterpCodes(1); // changing default to piece-wise log interpolation from pice-wise linear + FlexibleInterpVar interp( (interpName).c_str(), "", params, 1., lowVec, highVec); + interp.setAllInterpCodes(4); // LM: change to 4 (piece-wise linear to 6th order polynomial interpolation + linear extrapolation ) proto->import(interp); // params have already been imported in first loop of this function } else{ // some strange behavior if params,lowVec,highVec are empty. @@ -574,8 +643,8 @@ namespace HistFactory{ } - void HistoToWorkspaceFactoryFast::MakeTotalExpected(RooWorkspace* proto, string totName, string /**/, string /**/, - int /*lowBin*/, int /*highBin */, vector<string>& syst_x_expectedPrefixNames, + void HistoToWorkspaceFactoryFast::MakeTotalExpected(RooWorkspace* proto, string totName, + vector<string>& syst_x_expectedPrefixNames, vector<string>& normByNames){ // for ith bin calculate totN_i = lumi * sum_j expected_j * syst_j @@ -602,7 +671,7 @@ namespace HistFactory{ str<<"_"<<j; // repatative, but we need one coeff for each term in the sum // maybe can be avoided if we don't use bin width as coefficient - command=string(Form("binWidth_%s_%d[%f]",obsNameVecStr.c_str(),j,binWidth)); + command=string(Form("binWidth_%s_%d[%e]",obsNameVecStr.c_str(),j,binWidth)); proto->factory(command.c_str()); proto->var(Form("binWidth_%s_%d",obsNameVecStr.c_str(),j))->setConstant(); coeffList+=prepend+"binWidth_"+obsNameVecStr+str.str(); @@ -612,12 +681,10 @@ namespace HistFactory{ proto->factory(command.c_str()); shapeList+=prepend+"L_x_"+syst_x_expectedPrefixNames.at(j); prepend=","; - // add to num int to product // tempFunc->specialIntegratorConfig(kTRUE)->method1D().setLabel("RooBinIntegrator") ; // tempFunc->forceNumInt(); - } @@ -652,7 +719,6 @@ namespace HistFactory{ proto->import(tot); - // proto->Print(); } @@ -710,40 +776,33 @@ namespace HistFactory{ tree->Fill(); RooDataSet* data = new RooDataSet("expData","", tree, obsList); // one experiment - proto->import(*data); + delete tree; + delete [] obsForTree; - } + proto->import(*data); - void HistoToWorkspaceFactoryFast::Customize(RooWorkspace* proto, const char* pdfNameChar, map<string,string> renameMap) { - cout << "in customizations" << endl; - string pdfName(pdfNameChar); - map<string,string>::iterator it; - string edit="EDIT::customized("+pdfName+","; - string preceed=""; - for(it=renameMap.begin(); it!=renameMap.end(); ++it) { - cout << it->first + "=" + it->second << endl; - edit+=preceed + it->first + "=" + it->second; - preceed=","; - } - edit+=")"; - cout << edit<< endl; - proto->factory( edit.c_str() ); } //_____________________________________________________________ void HistoToWorkspaceFactoryFast::EditSyst(RooWorkspace* proto, const char* pdfNameChar, - map<string,double> gammaSyst, map<string,double> uniformSyst, map<string,double> logNormSyst, map<string,double> noSyst) { + map<string,double> gammaSyst, + map<string,double> uniformSyst, + map<string,double> logNormSyst, + map<string,double> noSyst) { string pdfName(pdfNameChar); - //cout << "HistoToWorkspaceFactoryFast::EditSyst() : gamma = " << gammaSyst.size() << ", uniform = " << uniformSyst.size() << ", noconst = " << noSyst.size() << endl; - ModelConfig * combined_config = (ModelConfig *) proto->obj("ModelConfig"); + if( combined_config==NULL ) { + std::cout << "Error: Failed to find object 'ModelConfig' in workspace: " + << proto->GetName() << std::endl; + throw hf_exc(); + } // const RooArgSet * constrainedParams=combined_config->GetNuisanceParameters(); // RooArgSet temp(*constrainedParams); string edit="EDIT::newSimPdf("+pdfName+","; string editList; string lastPdf=pdfName; - string preceed=""; + string precede=""; unsigned int numReplacements = 0; unsigned int nskipped = 0; map<string,double>::iterator it; @@ -789,19 +848,19 @@ namespace HistFactory{ proto->factory(Form("PolyVar::alphaOfBeta_%s(beta_%s,{%f,%f})",it->first.c_str(),it->first.c_str(),-1./scale,1./scale)); // set beta const status to be same as alpha - if(proto->var(Form("alpha_%s",it->first.c_str()))->isConstant()) + if(proto->var(Form("alpha_%s",it->first.c_str()))->isConstant()) { proto->var(Form("beta_%s",it->first.c_str()))->setConstant(true); - else + } + else { proto->var(Form("beta_%s",it->first.c_str()))->setConstant(false); + } // set alpha const status to true // proto->var(Form("alpha_%s",it->first.c_str()))->setConstant(true); // replace alphas with alphaOfBeta and replace constraints - //cout << "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint" << endl; - editList+=preceed + "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint"; - preceed=","; - // cout << "alpha_"+it->first+"=alphaOfBeta_"+ it->first << endl; - editList+=preceed + "alpha_"+it->first+"=alphaOfBeta_"+ it->first; + editList+=precede + "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint"; + precede=","; + editList+=precede + "alpha_"+it->first+"=alphaOfBeta_"+ it->first; /* if( proto->pdf(("alpha_"+it->first+"Constraint").c_str()) && proto->var(("alpha_"+it->first).c_str()) ) @@ -815,7 +874,7 @@ namespace HistFactory{ edit="EDIT::"+lastPdf+"_("+lastPdf+","+editList+")"; lastPdf+="_"; // append an underscore for the edit editList=""; // reset edit list - preceed=""; + precede=""; cout << "Going to issue this edit command\n" << edit<< endl; proto->factory( edit.c_str() ); RooAbsPdf* newOne = proto->pdf(lastPdf.c_str()); @@ -850,10 +909,10 @@ namespace HistFactory{ // replace alphas with alphaOfBeta and replace constraints cout << "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint" << endl; - editList+=preceed + "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint"; - preceed=","; + editList+=precede + "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint"; + precede=","; cout << "alpha_"+it->first+"=alphaOfBeta_"+ it->first << endl; - editList+=preceed + "alpha_"+it->first+"=alphaOfBeta_"+ it->first; + editList+=precede + "alpha_"+it->first+"=alphaOfBeta_"+ it->first; if( proto->pdf(("alpha_"+it->first+"Constraint").c_str()) && proto->var(("alpha_"+it->first).c_str()) ) cout << " checked they are there" << proto->pdf(("alpha_"+it->first+"Constraint").c_str()) << " " << proto->var(("alpha_"+it->first).c_str()) << endl; @@ -865,7 +924,7 @@ namespace HistFactory{ edit="EDIT::"+lastPdf+"_("+lastPdf+","+editList+")"; lastPdf+="_"; // append an underscore for the edit editList=""; // reset edit list - preceed=""; + precede=""; cout << edit<< endl; proto->factory( edit.c_str() ); RooAbsPdf* newOne = proto->pdf(lastPdf.c_str()); @@ -917,10 +976,10 @@ namespace HistFactory{ // replace alphas with alphaOfBeta and replace constraints cout << "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint" << endl; - editList+=preceed + "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint"; - preceed=","; + editList+=precede + "alpha_"+it->first+"Constraint=beta_" + it->first+ "Constraint"; + precede=","; cout << "alpha_"+it->first+"=alphaOfBeta_"+ it->first << endl; - editList+=preceed + "alpha_"+it->first+"=alphaOfBeta_"+ it->first; + editList+=precede + "alpha_"+it->first+"=alphaOfBeta_"+ it->first; if( proto->pdf(("alpha_"+it->first+"Constraint").c_str()) && proto->var(("alpha_"+it->first).c_str()) ) cout << " checked they are there" << proto->pdf(("alpha_"+it->first+"Constraint").c_str()) << " " << proto->var(("alpha_"+it->first).c_str()) << endl; @@ -932,7 +991,7 @@ namespace HistFactory{ edit="EDIT::"+lastPdf+"_("+lastPdf+","+editList+")"; lastPdf+="_"; // append an underscore for the edit editList=""; // reset edit list - preceed=""; + precede=""; cout << edit<< endl; proto->factory( edit.c_str() ); RooAbsPdf* newOne = proto->pdf(lastPdf.c_str()); @@ -961,15 +1020,15 @@ namespace HistFactory{ // replace constraints cout << "alpha_"+it->first+"Constraint=one" << endl; - editList+=preceed + "alpha_"+it->first+"Constraint=one"; - preceed=","; + editList+=precede + "alpha_"+it->first+"Constraint=one"; + precede=","; // EDIT seems to die if the list of edits is too long. So chunck them up. if(numReplacements%10 == 0 && numReplacements+nskipped!=gammaSyst.size()){ edit="EDIT::"+lastPdf+"_("+lastPdf+","+editList+")"; lastPdf+="_"; // append an underscore for the edit editList=""; // reset edit list - preceed=""; + precede=""; cout << edit << endl; proto->factory( edit.c_str() ); RooAbsPdf* newOne = proto->pdf(lastPdf.c_str()); @@ -999,7 +1058,6 @@ namespace HistFactory{ FILE* covFile = fopen ((filename).c_str(),"w"); - TIter iti = params->createIterator(); TIter itj = params->createIterator(); RooRealVar *myargi, *myargj; @@ -1028,37 +1086,44 @@ namespace HistFactory{ /////////////////////////////////////////////// - RooWorkspace* HistoToWorkspaceFactoryFast::MakeSingleChannelModel(vector<EstimateSummary> summary, vector<string> systToFix, bool doRatio) - { + RooWorkspace* HistoToWorkspaceFactoryFast::MakeSingleChannelWorkspace(Measurement& measurement, Channel& channel) { + + // Set these by hand inside the function + vector<string> systToFix = measurement.GetConstantParams(); + bool doRatio=false; + // to time the macro TStopwatch t; t.Start(); - string channel=summary[0].channel; - + //ES// string channel_name=summary[0].channel; + string channel_name = channel.GetName(); + /// MB: reset observable names for each new channel. fObsNameVec.clear(); /// MB: label observables x,y,z, depending on histogram dimensionality - if (fObsNameVec.empty()) { GuessObsNameVec( summary.at(0).nominal ); } + /// GHL: Give it the first sample's nominal histogram as a template + /// since the data histogram may not be present + TH1* channel_hist_template = channel.GetSamples().at(0).GetHisto(); + if (fObsNameVec.empty()) { GuessObsNameVec(channel_hist_template); } for ( unsigned int idx=0; idx<fObsNameVec.size(); ++idx ) { - fObsNameVec[idx] = "obs_" + fObsNameVec[idx] + "_" + summary[0].channel ; + fObsNameVec[idx] = "obs_" + fObsNameVec[idx] + "_" + channel_name ; } if (fObsNameVec.empty()) { - // fObsName.c_str()=Form("%s_%s",summary.at(0).nominal->GetXaxis()->GetName()],summary[0].channel.c_str()); // set name ov observable - fObsName= "obs_"+summary[0].channel; // set name ov observable + fObsName= "obs_" + channel_name; // set name ov observable fObsNameVec.push_back( fObsName ); } R__ASSERT( fObsNameVec.size()>=1 && fObsNameVec.size()<=3 ); - cout << "\n\n-------------------\nStarting to process " << channel << " channel with " << fObsNameVec.size() << " observables" << endl; + cout << "\n\n-------------------\nStarting to process " << channel_name << " channel with " << fObsNameVec.size() << " observables" << endl; // // our main workspace that we are using to construct the model // - RooWorkspace* proto = new RooWorkspace(summary[0].channel.c_str(),(summary[0].channel+" workspace").c_str()); + RooWorkspace* proto = new RooWorkspace(channel_name.c_str(), (channel_name+" workspace").c_str()); ModelConfig * proto_config = new ModelConfig("ModelConfig", proto); proto_config->SetWorkspace(*proto); @@ -1070,20 +1135,18 @@ namespace HistFactory{ proto->Print(); } - RooArgSet likelihoodTerms("likelihoodTerms"), constraintTerms("constraintTerms"); - vector<string> likelihoodTermNames, constraintTermNames, totSystTermNames,syst_x_expectedPrefixNames, normalizationNames; + vector<string> likelihoodTermNames, constraintTermNames, totSystTermNames, syst_x_expectedPrefixNames, normalizationNames; vector< pair<string,string> > statNamePairs; vector< pair<TH1*,TH1*> > statHistPairs; // <nominal, error> std::string statFuncName; // the name of the ParamHistFunc std::string statNodeName; // the name of the McStat Node - EstimateSummary::ConstraintType statConstraintType=EstimateSummary::Gaussian; - Double_t statRelErrorThreshold=0.0; + // Constraint::Type statConstraintType=Constraint::Gaussian; + // Double_t statRelErrorThreshold=0.0; string prefix, range; - ///////////////////////////// // shared parameters // this is ratio of lumi to nominal lumi. We will include relative uncertainty in model @@ -1106,17 +1169,23 @@ namespace HistFactory{ /////////////////////////////////// // loop through estimates, add expectation, floating bin predictions, // and terms that constrain floating to expectation via uncertainties - vector<EstimateSummary>::iterator it = summary.begin(); - for(; it!=summary.end(); ++it){ - if(it->name=="Data") continue; + // GHL: Loop over samples instead, which doesn't contain the data + vector<Sample>::iterator it = channel.GetSamples().begin(); + for(; it!=channel.GetSamples().end(); ++it) { + + //ES// string overallSystName = it->name+"_"+it->channel+"_epsilon"; + Sample& sample = (*it); + string overallSystName = sample.GetName() + "_" + channel_name + "_epsilon"; - string overallSystName = it->name+"_"+it->channel+"_epsilon"; string systSourcePrefix = "alpha_"; - AddEfficiencyTerms(proto,systSourcePrefix, overallSystName, - it->overallSyst, constraintTermNames /*likelihoodTermNames*/, totSystTermNames); - overallSystName = AddNormFactor(proto, channel, overallSystName, *it, doRatio); + // constraintTermNames and totSystTermNames are vectors that are passed + // by reference and filled by this method + AddEfficiencyTerms(proto,systSourcePrefix, overallSystName, + sample.GetOverallSysList(), constraintTermNames , totSystTermNames); + // GHL: Consider passing the NormFactor list instead of the entire sample + overallSystName = AddNormFactor(proto, channel_name, overallSystName, sample, doRatio); // Create the string for the object // that is added to the RooRealSumPdf @@ -1124,106 +1193,159 @@ namespace HistFactory{ string syst_x_expectedPrefix = ""; // get histogram - TH1* nominal = it->nominal; + //ES// TH1* nominal = it->nominal; + TH1* nominal = sample.GetHisto(); // MB : HACK no option to have both non-hist variations and hist variations ? // get histogram - if(it->lowHists.size() == 0){ - cout << it->name+"_"+it->channel+" has no variation histograms " <<endl; - string expPrefix=it->name+"_"+it->channel;//+"_expN"; - syst_x_expectedPrefix=it->name+"_"+it->channel+"_overallSyst_x_Exp"; - ProcessExpectedHisto(nominal,proto,expPrefix,syst_x_expectedPrefix,overallSystName,atoi(NoHistConst_Low),atoi(NoHistConst_High),fLowBin,fHighBin); - //syst_x_expectedPrefixNames.push_back(syst_x_expectedPrefix); - } else if(it->lowHists.size() != it->highHists.size()){ - cout << "problem in "+it->name+"_"+it->channel - << " number of low & high variation histograms don't match" << endl; - return 0; - } else { - string constraintPrefix = it->name+"_"+it->channel+"_Hist_alpha"; // name of source for variation - syst_x_expectedPrefix = it->name+"_"+it->channel+"_overallSyst_x_HistSyst"; - LinInterpWithConstraint(proto, nominal, it->lowHists, it->highHists, it->systSourceForHist, - constraintPrefix, syst_x_expectedPrefix, overallSystName, - fLowBin, fHighBin, constraintTermNames /*likelihoodTermNames*/); - //syst_x_expectedPrefixNames.push_back(syst_x_expectedPrefix); + // GHL: Okay, this is going to be non-trivial. + // We will loop over histosys's, which contain both + // the low hist and the high hist together. + + // Logic: + // - If we have no HistoSys's, do part A + // - else, if the histo syst's don't match, return (we ignore this case) + // - finally, we take the syst's and apply the linear interpolation w/ constraint + + if(sample.GetHistoSysList().size() == 0) { + + // If no HistoSys + cout << sample.GetName() + "_" + channel_name + " has no variation histograms " << endl; + string expPrefix = sample.GetName() + "_" + channel_name; //+"_expN"; + syst_x_expectedPrefix = sample.GetName() + "_" + channel_name + "_overallSyst_x_Exp"; + + ProcessExpectedHisto(sample.GetHisto(), proto, expPrefix, syst_x_expectedPrefix, + overallSystName); + } + else { + // If there ARE HistoSys(s) + // name of source for variation + string constraintPrefix = sample.GetName() + "_" + channel_name + "_Hist_alpha"; + syst_x_expectedPrefix = sample.GetName() + "_" + channel_name + "_overallSyst_x_HistSyst"; + // constraintTermNames are passed by reference and appended to, + // overallSystName is a std::string for this sample + + LinInterpWithConstraint(proto, nominal, sample.GetHistoSysList(), + constraintPrefix, syst_x_expectedPrefix, overallSystName, + constraintTermNames); } - //////////////////////////////////// // Add StatErrors to this Channel // //////////////////////////////////// - if( it->IncludeStatError ) { + if( sample.GetStatError().GetActivate() ) { if( fObsNameVec.size() > 3 ) { - std::cout << "Cannot include Stat Error for histograms of more than 3 dimensions." << std::endl; + std::cout << "Cannot include Stat Error for histograms of more than 3 dimensions." + << std::endl; + throw hf_exc(); } else { // If we are using StatUncertainties, we multiply this object // by the ParamHistFunc and then pass that to the // RooRealSumPdf by appending it's name to the list - std::cout << "Sample: " << it->name << " to be included in Stat Error " - << "for channel " << it->channel + std::cout << "Sample: " << sample.GetName() << " to be included in Stat Error " + << "for channel " << channel_name << std::endl; - statConstraintType = it->StatConstraintType; - statRelErrorThreshold = it->RelErrorThreshold; + /* + Constraint::Type type = channel.GetStatErrorConfig().GetConstraintType(); + statConstraintType = Constraint::Gaussian; + if( type == Constraint::Gaussian) { + std::cout << "Using Gaussian StatErrors" << std::endl; + statConstraintType = Constraint::Gaussian; + } + if( type == Constraint::Poisson ) { + std::cout << "Using Poisson StatErrors" << std::endl; + statConstraintType = Constraint::Poisson; + } + */ + + //statRelErrorThreshold = channel.GetStatErrorConfig().GetRelErrorThreshold(); // First, get the uncertainty histogram // and push it back to our vectors - TH1* statErrorHist = it->relStatError; + //if( sample.GetStatError().GetErrorHist() ) { + //statErrorHist = (TH1*) sample.GetStatError().GetErrorHist()->Clone(); + //} + //if( statErrorHist == NULL ) { + + // We need to get the *ABSOLUTE* uncertainty for use in Stat Uncertainties + // This can be done in one of two ways: + // - Use the built-in Errors in the TH1 itself (they are aboslute) + // - Take the supplied *RELATIVE* error and multiply by the nominal string UncertName = syst_x_expectedPrefix + "_StatAbsolUncert"; - - if( statErrorHist == NULL ) { + TH1* statErrorHist = NULL; + + if( sample.GetStatError().GetErrorHist() == NULL ) { // Make the absolute stat error std::cout << "Making Statistical Uncertainty Hist for " - << " Channel: " << it->channel - << " Sample: " << it->name + << " Channel: " << channel_name + << " Sample: " << sample.GetName() << std::endl; statErrorHist = MakeAbsolUncertaintyHist( UncertName, nominal ); } else { + statErrorHist = (TH1*) sample.GetStatError().GetErrorHist()->Clone(); // We assume the (relative) error is provided. // We must turn it into an absolute error // using the nominal histogram std::cout << "Using external histogram for Stat Errors for " - << " Channel: " << it->channel - << " Sample: " << it->name + << " Channel: " << channel_name + << " Sample: " << sample.GetName() << std::endl; std::cout << "Error Histogram: " << statErrorHist->GetName() << std::endl; + // Multiply the relative stat uncertainty by the + // nominal to get the overall stat uncertainty statErrorHist->Multiply( nominal ); statErrorHist->SetName( UncertName.c_str() ); } // Save the nominal and error hists // for the building of constraint terms - statHistPairs.push_back( pair<TH1*,TH1*>(nominal,statErrorHist) ); - - // Next, try to get the flexible ParamHistFunc/ + statHistPairs.push_back( pair<TH1*,TH1*>(nominal, statErrorHist) ); + + // To do the 'conservative' version, we would need to do some + // intervention here. We would probably need to create a different + // ParamHistFunc for each sample in the channel. The would nominally + // use the same gamma's, so we haven't increased the number of parameters + // However, if a bin in the 'nominal' histogram is 0, we simply need to + // change the parameter in that bin in the ParamHistFunc for this sample. + // We also need to add a constraint term. + // Actually, we'd probably not use the ParamHistFunc...? + // we could remove the dependence in this ParamHistFunc on the ith gamma + // and then create the poisson term: Pois(tau | n_exp)Pois(data | n_exp) + + + // Next, try to get the ParamHistFunc (it may have been + // created by another sample in this channel) // or create it if it doesn't yet exist: - statFuncName = "mc_stat_" + it->channel; + statFuncName = "mc_stat_" + channel_name; ParamHistFunc* paramHist = (ParamHistFunc*) proto->function( statFuncName.c_str() ); if( paramHist == NULL ) { // Get a RooArgSet of the observables: - // Names in the lsit fObsNameVec: + // Names in the list fObsNameVec: RooArgList observables; std::vector<std::string>::iterator itr = fObsNameVec.begin(); for (int idx=0; itr!=fObsNameVec.end(); ++itr, ++idx ) { observables.add( *proto->var(itr->c_str()) ); } - // RooRealVar* var = (RooRealVar*) observables.first(); - // Create the list of terms to // control the bin heights: - std::string ParamSetPrefix = "gamma_stat_" + it->channel; + std::string ParamSetPrefix = "gamma_stat_" + channel_name; Double_t gammaMin = 0.0; Double_t gammaMax = 10.0; - RooArgList statFactorParams = ParamHistFunc::createParamSet(*proto, ParamSetPrefix.c_str(), observables, gammaMin, gammaMax); + RooArgList statFactorParams = ParamHistFunc::createParamSet(*proto, + ParamSetPrefix.c_str(), + observables, + gammaMin, gammaMax); ParamHistFunc statUncertFunc(statFuncName.c_str(), statFuncName.c_str(), - observables, statFactorParams ); + observables, statFactorParams ); proto->import( statUncertFunc, RecycleConflictNodes() ); @@ -1231,11 +1353,10 @@ namespace HistFactory{ } // END: If Statement: Create ParamHistFunc - // Create the node as a product // of this function and the // expected value from MC - statNodeName = it->name+"_"+it->channel+"_overallSyst_x_StatUncert"; + statNodeName = sample.GetName() + "_" + channel_name + "_overallSyst_x_StatUncert"; RooAbsReal* expFunc = (RooAbsReal*) proto->function( syst_x_expectedPrefix.c_str() ); RooProduct nodeWithMcStat(statNodeName.c_str(), statNodeName.c_str(), @@ -1256,50 +1377,96 @@ namespace HistFactory{ // Create a ShapeFactor for this channel // /////////////////////////////////////////// - if( it->shapeFactorName != "" ) { + if( sample.GetShapeFactorList().size() > 0 ) { - if( fObsNameVec.size() >3 ) { - std::cout << "Cannot include Stat Error for histograms of more than 3 dimensions." << std::endl; + if( fObsNameVec.size() > 3 ) { + std::cout << "Cannot include Stat Error for histograms of more than 3 dimensions." + << std::endl; + throw hf_exc(); } else { - - std::cout << "Sample: " << it->name << " in channel: " << it->channel - << " to be include a ShapeFactor." - << std::endl; + std::cout << "Sample: " << sample.GetName() << " in channel: " << channel_name + << " to be include a ShapeFactor." + << std::endl; - std::string funcName = it->channel + "_" + it->shapeFactorName + "_shapeFactor"; - ParamHistFunc* paramHist = (ParamHistFunc*) proto->function( funcName.c_str() ); - if( paramHist == NULL ) { + std::vector<ParamHistFunc*> paramHistFuncList; + std::vector<std::string> shapeFactorNameList; - RooArgList observables; - std::vector<std::string>::iterator itr = fObsNameVec.begin(); - for (int idx=0; itr!=fObsNameVec.end(); ++itr, ++idx ) { - observables.add( *proto->var(itr->c_str()) ); - } - - // RooRealVar* var = (RooRealVar*) observables.first(); + for(unsigned int i=0; i < sample.GetShapeFactorList().size(); ++i) { - // Create the Parameters - std::string funcParams = "gamma_" + it->shapeFactorName; - RooArgList shapeFactorParams = ParamHistFunc::createParamSet(*proto, funcParams.c_str(), observables, 0, 1000); + ShapeFactor& shapeFactor = sample.GetShapeFactorList().at(i); + + std::string funcName = channel_name + "_" + shapeFactor.GetName() + "_shapeFactor"; + ParamHistFunc* paramHist = (ParamHistFunc*) proto->function( funcName.c_str() ); + if( paramHist == NULL ) { + + RooArgList observables; + std::vector<std::string>::iterator itr = fObsNameVec.begin(); + for (int idx=0; itr!=fObsNameVec.end(); ++itr, ++idx ) { + observables.add( *proto->var(itr->c_str()) ); + } + + // Create the Parameters + std::string funcParams = "gamma_" + shapeFactor.GetName(); - // Create the Function - ParamHistFunc shapeFactorFunc( funcName.c_str(), funcName.c_str(), + // GHL: Again, we are putting hard ranges on the gamma's + // We should change this to range from 0 to /inf + RooArgList shapeFactorParams = ParamHistFunc::createParamSet(*proto, + funcParams.c_str(), + observables, 0, 1000); + + // Create the Function + ParamHistFunc shapeFactorFunc( funcName.c_str(), funcName.c_str(), observables, shapeFactorParams ); + + // Set an initial shape, if requested + if( shapeFactor.GetInitialShape() != NULL ) { + TH1* initialShape = shapeFactor.GetInitialShape(); + std::cout << "Setting Shape Factor: " << shapeFactor.GetName() + << " to have initial shape from hist: " + << initialShape->GetName() + << std::endl; + shapeFactorFunc.setShape( initialShape ); + } + + // Set the variables constant, if requested + if( shapeFactor.IsConstant() ) { + std::cout << "Setting Shape Factor: " << shapeFactor.GetName() + << " to be constant" << std::endl; + shapeFactorFunc.setConstant(true); + } - proto->import( shapeFactorFunc, RecycleConflictNodes() ); - paramHist = (ParamHistFunc*) proto->function( funcName.c_str() ); + proto->import( shapeFactorFunc, RecycleConflictNodes() ); + paramHist = (ParamHistFunc*) proto->function( funcName.c_str() ); - } // End: Create ShapeFactor ParamHistFunc + } // End: Create ShapeFactor ParamHistFunc + + paramHistFuncList.push_back(paramHist); + shapeFactorNameList.push_back(funcName); + + } // End loop over ShapeFactor Systematics // Now that we have the right ShapeFactor, // we multiply the expected function - std::string shapeFactorNodeName = syst_x_expectedPrefix + "_x_" + funcName; + //std::string shapeFactorNodeName = syst_x_expectedPrefix + "_x_" + funcName; + // Dynamically build the name as a long product + std::string shapeFactorNodeName = syst_x_expectedPrefix; + for( unsigned int i=0; i < shapeFactorNameList.size(); ++i) { + shapeFactorNodeName += "_x_" + shapeFactorNameList.at(i); + } RooAbsReal* expFunc = (RooAbsReal*) proto->function( syst_x_expectedPrefix.c_str() ); - RooProduct nodeWithShapeFactor(shapeFactorNodeName.c_str(), shapeFactorNodeName.c_str(), - RooArgSet(*paramHist, *expFunc) ); + RooArgSet nodesForProduct(*expFunc); + for( unsigned int i=0; i < paramHistFuncList.size(); ++i) { + nodesForProduct.add( *paramHistFuncList.at(i) ); + } + //RooProduct nodeWithShapeFactor(shapeFactorNodeName.c_str(), + // shapeFactorNodeName.c_str(), + //RooArgSet(*paramHist, *expFunc) ); + RooProduct nodeWithShapeFactor(shapeFactorNodeName.c_str(), + shapeFactorNodeName.c_str(), + nodesForProduct ); proto->import( nodeWithShapeFactor, RecycleConflictNodes() ); @@ -1316,16 +1483,18 @@ namespace HistFactory{ // Create a ShapeSys for this channel // //////////////////////////////////////// - if( it->shapeSysts.size() != 0 ) { + if( sample.GetShapeSysList().size() != 0 ) { if( fObsNameVec.size() > 3 ) { - std::cout << "Cannot include Stat Error for histograms of more than 3 dimensions." << std::endl; + std::cout << "Cannot include Stat Error for histograms of more than 3 dimensions." + << std::endl; + throw hf_exc(); } else { // List of ShapeSys ParamHistFuncs std::vector<string> ShapeSysNames; - for( unsigned int i = 0; i < it->shapeSysts.size(); ++i) { + for( unsigned int i = 0; i < sample.GetShapeSysList().size(); ++i) { // Create the ParamHistFunc's // Create their constraint terms and add them @@ -1336,12 +1505,12 @@ namespace HistFactory{ // Send the name of that product to the RooRealSumPdf - EstimateSummary::ShapeSys Sys = it->shapeSysts.at(i); - - std::cout << "Sample: " << it->name << " in channel: " << it->channel + RooStats::HistFactory::ShapeSys& shapeSys = sample.GetShapeSysList().at(i); + + std::cout << "Sample: " << sample.GetName() << " in channel: " << channel_name << " to include a ShapeSys." << std::endl; - std::string funcName = it->channel + "_" + Sys.name + "_ShapeSys"; + std::string funcName = channel_name + "_" + shapeSys.GetName() + "_ShapeSys"; ShapeSysNames.push_back( funcName ); ParamHistFunc* paramHist = (ParamHistFunc*) proto->function( funcName.c_str() ); if( paramHist == NULL ) { @@ -1351,15 +1520,15 @@ namespace HistFactory{ RooArgList observables; std::vector<std::string>::iterator itr = fObsNameVec.begin(); - for (int idx=0; itr!=fObsNameVec.end(); ++itr, ++idx ) { + for(; itr!=fObsNameVec.end(); ++itr ) { observables.add( *proto->var(itr->c_str()) ); } - - // RooRealVar* var = (RooRealVar*) observables.first(); // Create the Parameters - std::string funcParams = "gamma_" + Sys.name; - RooArgList shapeFactorParams = ParamHistFunc::createParamSet(*proto, funcParams.c_str(), observables,0,10); + std::string funcParams = "gamma_" + shapeSys.GetName(); + RooArgList shapeFactorParams = ParamHistFunc::createParamSet(*proto, + funcParams.c_str(), + observables, 0, 10); // Create the Function ParamHistFunc shapeFactorFunc( funcName.c_str(), funcName.c_str(), @@ -1375,15 +1544,26 @@ namespace HistFactory{ // as well as the list of constraint terms (constraintTermNames) // The syst should be a fractional error - TH1* shapeErrorHist = Sys.hist; - EstimateSummary::ConstraintType shapeConstraintType = Sys.constraint; + TH1* shapeErrorHist = shapeSys.GetErrorHist(); + + // Constraint::Type shapeConstraintType = Constraint::Gaussian; + Constraint::Type systype = shapeSys.GetConstraintType(); + if( systype == Constraint::Gaussian) { + systype = Constraint::Gaussian; + } + if( systype == Constraint::Poisson ) { + systype = Constraint::Poisson; + } + Double_t minShapeUncertainty = 0.0; - RooArgList shapeConstraints = createStatConstraintTerms(proto, constraintTermNames, *paramHist, shapeErrorHist, - shapeConstraintType, minShapeUncertainty); + RooArgList shapeConstraints = createStatConstraintTerms(proto, constraintTermNames, + *paramHist, shapeErrorHist, + systype, + minShapeUncertainty); } // End: Loop over ShapeSys vector in this EstimateSummary - // Now that we have the list of ShapeSys ParamHistFunc names, + // Now that we have the list of ShapeSys ParamHistFunc names, // we create the total RooProduct // we multiply the expected functio @@ -1407,36 +1587,42 @@ namespace HistFactory{ syst_x_expectedPrefix = nodeWithShapeFactor.GetName(); } // End: NumObsVar == 1 - - - } // End: ShapeSysts Size != 0 - - - - + } // End: GetShapeSysList.size() != 0 // Append the name of the "node" // that is to be summed with the // RooRealSumPdf syst_x_expectedPrefixNames.push_back(syst_x_expectedPrefix); - if(it->normName=="") - normalizationNames.push_back( "Lumi" ); - else - normalizationNames.push_back( it->normName); + // GHL: This was pretty confusing before, + // hopefully using the measurement directly + // will improve it + if( sample.GetNormalizeByTheory() ) { + normalizationNames.push_back( "Lumi" ); + } + else { + TString lumiParamString; + lumiParamString += measurement.GetLumi(); + lumiParamString.ReplaceAll(' ', TString()); + normalizationNames.push_back(lumiParamString.Data()); + } + } // END: Loop over EstimateSummaries // proto->Print(); - // If a non-zero number of samples call for // Stat Uncertainties, create the statFactor functions - if( statHistPairs.size() > 0 ) { // Create the histogram of (binwise) // stat uncertainties: TH1* fracStatError = MakeScaledUncertaintyHist( statNodeName + "_RelErr", statHistPairs ); + if( fracStatError == NULL ) { + std::cout << "Error: Failed to make ScaledUncertaintyHist for: " + << statNodeName << std::endl; + throw hf_exc(); + } // Using this TH1* of fractinal stat errors, // create a set of constraint terms: @@ -1451,17 +1637,31 @@ namespace HistFactory{ // EstimateSummary looped over (but all // should be the same) - RooArgList statConstraints = createStatConstraintTerms(proto, constraintTermNames, *chanStatUncertFunc, fracStatError, - statConstraintType, statRelErrorThreshold); + // Get the type of StatError constraint from the channel + Constraint::Type statConstraintType = channel.GetStatErrorConfig().GetConstraintType(); + if( statConstraintType == Constraint::Gaussian) { + std::cout << "Using Gaussian StatErrors in channel: " << channel.GetName() << std::endl; + } + if( statConstraintType == Constraint::Poisson ) { + std::cout << "Using Poisson StatErrors in channel: " << channel.GetName() << std::endl; + } + + double statRelErrorThreshold = channel.GetStatErrorConfig().GetRelErrorThreshold(); + RooArgList statConstraints = createStatConstraintTerms(proto, constraintTermNames, + *chanStatUncertFunc, fracStatError, + statConstraintType, + statRelErrorThreshold); } // END: Loop over stat Hist Pairs /////////////////////////////////// // for ith bin calculate totN_i = lumi * sum_j expected_j * syst_j - MakeTotalExpected(proto,channel+"_model",channel,"Lumi",fLowBin,fHighBin, - syst_x_expectedPrefixNames, normalizationNames); - likelihoodTermNames.push_back(channel+"_model"); + //MakeTotalExpected(proto,channel_name+"_model",channel_name,"Lumi",fLowBin,fHighBin, + // syst_x_expectedPrefixNames, normalizationNames); + MakeTotalExpected(proto, channel_name+"_model", //channel_name,"Lumi",fLowBin,fHighBin, + syst_x_expectedPrefixNames, normalizationNames); + likelihoodTermNames.push_back(channel_name+"_model"); ////////////////////////////////////// // fix specified parameters @@ -1482,20 +1682,35 @@ namespace HistFactory{ if(auxMeas){ const_cast<RooArgSet*>(proto->set("globalObservables"))->remove(*auxMeas); } else{ - cout << "could not corresponding auxiliary measurement " << Form("nom_%s",temp->GetName()) << endl; + cout << "could not corresponding auxiliary measurement " + << Form("nom_%s",temp->GetName()) << endl; } } else { - cout << "could not find variable " << systToFix.at(i) << " could not set it to constant" << endl; + cout << "could not find variable " << systToFix.at(i) + << " could not set it to constant" << endl; } } ////////////////////////////////////// // final proto model for(unsigned int i=0; i<constraintTermNames.size(); ++i){ - constraintTerms.add(* (proto->arg(constraintTermNames[i].c_str())) ); + RooAbsArg* proto_arg = (proto->arg(constraintTermNames[i].c_str())); + if( proto_arg==NULL ) { + std::cout << "Error: Cannot find arg set: " << constraintTermNames.at(i) + << " in workspace: " << proto->GetName() << std::endl; + throw hf_exc(); + } + constraintTerms.add( *proto_arg ); + // constraintTerms.add(* proto_arg(proto->arg(constraintTermNames[i].c_str())) ); } for(unsigned int i=0; i<likelihoodTermNames.size(); ++i){ - likelihoodTerms.add(* (proto->arg(likelihoodTermNames[i].c_str())) ); + RooAbsArg* proto_arg = (proto->arg(likelihoodTermNames[i].c_str())); + if( proto_arg==NULL ) { + std::cout << "Error: Cannot find arg set: " << constraintTermNames.at(i) + << " in workspace: " << proto->GetName() << std::endl; + throw hf_exc(); + } + likelihoodTerms.add( *proto_arg ); } proto->defineSet("constraintTerms",constraintTerms); proto->defineSet("likelihoodTerms",likelihoodTerms); @@ -1504,26 +1719,26 @@ namespace HistFactory{ // list of observables RooArgList observables; std::string observablesStr; + std::vector<std::string>::iterator itr = fObsNameVec.begin(); - for (int idx=0; itr!=fObsNameVec.end(); ++itr, ++idx ) { + for(; itr!=fObsNameVec.end(); ++itr ) { observables.add( *proto->var(itr->c_str()) ); if (!observablesStr.empty()) { observablesStr += ","; } observablesStr += *itr; } - proto->defineSet("observablesSet",Form("%s",observablesStr.c_str())); - + // We create two sets, one for backwards compatability + // The other to make a consistent naming convention + // between individual channels and the combined workspace + proto->defineSet("observables", Form("%s",observablesStr.c_str())); + proto->defineSet("observablesSet", Form("%s",observablesStr.c_str())); + // Create the ParamHistFunc // after observables have been made - - - - - cout <<"-----------------------------------------"<<endl; cout <<"import model into workspace" << endl; - RooProdPdf* model = new RooProdPdf(("model_"+channel).c_str(), // MB : have changed this into conditional pdf. Much faster for toys! + RooProdPdf* model = new RooProdPdf(("model_"+channel_name).c_str(), // MB : have changed this into conditional pdf. Much faster for toys! "product of Poissons accross bins for a single channel", constraintTerms, Conditional(likelihoodTerms,observables)); //likelihoodTerms); proto->import(*model,RecycleConflictNodes()); @@ -1543,32 +1758,48 @@ namespace HistFactory{ const char* weightName="weightVar"; proto->factory(Form("%s[0,-1e10,1e10]",weightName)); proto->defineSet("obsAndWeight",Form("%s,%s",weightName,observablesStr.c_str())); - RooAbsData* data = model->generateBinned(observables,ExpectedData()); + + /* Old code for generating the asimov + Asimov generation is now done later... + + RooAbsData* asimov_data = model->generateBinned(observables,ExpectedData()); /// Asimov dataset RooDataSet* asimovDataUnbinned = new RooDataSet("asimovData","",*proto->set("obsAndWeight"),weightName); - /* - double binWidthW(1.0); - itr = fObsNameVec.begin(); - for (; itr!=fObsNameVec.end(); ++itr) { - std::string obsName = *itr; - binWidthW *= proto->var(obsName.c_str())->numBins()/(proto->var(obsName.c_str())->getMax() - proto->var(obsName.c_str())->getMin()) ; - } - */ - for(int i=0; i<data->numEntries(); ++i){ - data->get(i)->Print("v"); + for(int i=0; i<asimov_data->numEntries(); ++i){ + asimov_data->get(i)->Print("v"); //cout << "GREPME : " << i << " " << data->weight() <<endl; - asimovDataUnbinned->add( *data->get(i), data->weight() ); + asimovDataUnbinned->add( *asimov_data->get(i), asimov_data->weight() ); } proto->import(*asimovDataUnbinned); + */ + + // New Asimov Generation: Use the code in the Asymptotic calculator + // Need to get the ModelConfig... + RooDataSet* asimov_dataset = (RooDataSet*) AsymptoticCalculator::GenerateAsimovData(*model, observables); + proto->import(*asimov_dataset, Rename("asimovData")); + // GHL: Determine to use data if the hist isn't 'NULL' + if(channel.GetData().GetHisto() != NULL) { - if (summary.at(0).name=="Data") { + Data& data = channel.GetData(); + TH1* mnominal = data.GetHisto(); + if( !mnominal ) { + std::cout << "Error: Data histogram for channel: " << channel.GetName() + << " is NULL" << std::endl; + throw hf_exc(); + } // THis works and is natural, but the memory size of the simultaneous dataset grows exponentially with channels RooDataSet* obsDataUnbinned = new RooDataSet("obsData","",*proto->set("obsAndWeight"),weightName); - TH1* mnominal = summary.at(0).nominal; + + ConfigureHistFactoryDataset( obsDataUnbinned, mnominal, + proto, fObsNameVec ); + + /* + //ES// TH1* mnominal = summary.at(0).nominal; + TH1* mnominal = data.GetHisto(); TAxis* ax = mnominal->GetXaxis(); TAxis* ay = mnominal->GetYaxis(); TAxis* az = mnominal->GetZaxis(); @@ -1597,15 +1828,117 @@ namespace HistFactory{ } } } + */ + + proto->import(*obsDataUnbinned); + } // End: Has non-null 'data' entry + + + for(unsigned int i=0; i < channel.GetAdditionalData().size(); ++i) { + Data& data = channel.GetAdditionalData().at(i); + std::string dataName = data.GetName(); + TH1* mnominal = data.GetHisto(); + if( !mnominal ) { + std::cout << "Error: Additional Data histogram for channel: " << channel.GetName() + << " with name: " << dataName << " is NULL" << std::endl; + throw hf_exc(); + } + + // THis works and is natural, but the memory size of the simultaneous dataset grows exponentially with channels + RooDataSet* obsDataUnbinned = new RooDataSet(dataName.c_str(), dataName.c_str(), + *proto->set("obsAndWeight"), weightName); + + ConfigureHistFactoryDataset( obsDataUnbinned, mnominal, + proto, fObsNameVec ); + + /* + //ES// TH1* mnominal = summary.at(0).nominal; + TH1* mnominal = data.GetHisto(); + TAxis* ax = mnominal->GetXaxis(); + TAxis* ay = mnominal->GetYaxis(); + TAxis* az = mnominal->GetZaxis(); + + for (int i=1; i<=ax->GetNbins(); ++i) { // 1 or more dimension + Double_t xval = ax->GetBinCenter(i); + proto->var( fObsNameVec[0].c_str() )->setVal( xval ); + if (fObsNameVec.size()==1) { + Double_t fval = mnominal->GetBinContent(i); + obsDataUnbinned->add( *proto->set("obsAndWeight"), fval ); + } else { // 2 or more dimensions + for (int j=1; j<=ay->GetNbins(); ++j) { + Double_t yval = ay->GetBinCenter(j); + proto->var( fObsNameVec[1].c_str() )->setVal( yval ); + if (fObsNameVec.size()==2) { + Double_t fval = mnominal->GetBinContent(i,j); + obsDataUnbinned->add( *proto->set("obsAndWeight"), fval ); + } else { // 3 dimensions + for (int k=1; k<=az->GetNbins(); ++k) { + Double_t zval = az->GetBinCenter(k); + proto->var( fObsNameVec[2].c_str() )->setVal( zval ); + Double_t fval = mnominal->GetBinContent(i,j,k); + obsDataUnbinned->add( *proto->set("obsAndWeight"), fval ); + } + } + } + } + } + */ + proto->import(*obsDataUnbinned); - } + } // End: Has non-null 'data' entry proto->Print(); return proto; } + void HistoToWorkspaceFactoryFast::ConfigureHistFactoryDataset( RooDataSet* obsDataUnbinned, + TH1* mnominal, + RooWorkspace* proto, + std::vector<std::string> ObsNameVec) { + + // Take a RooDataSet and fill it with the entries + // from a TH1*, using the observable names to + // determine the columns + + //ES// TH1* mnominal = summary.at(0).nominal; + // TH1* mnominal = data.GetHisto(); + TAxis* ax = mnominal->GetXaxis(); + TAxis* ay = mnominal->GetYaxis(); + TAxis* az = mnominal->GetZaxis(); + + for (int i=1; i<=ax->GetNbins(); ++i) { // 1 or more dimension + + Double_t xval = ax->GetBinCenter(i); + proto->var( ObsNameVec[0].c_str() )->setVal( xval ); + + if(ObsNameVec.size()==1) { + Double_t fval = mnominal->GetBinContent(i); + obsDataUnbinned->add( *proto->set("obsAndWeight"), fval ); + } else { // 2 or more dimensions + + for(int j=1; j<=ay->GetNbins(); ++j) { + Double_t yval = ay->GetBinCenter(j); + proto->var( ObsNameVec[1].c_str() )->setVal( yval ); + + if(ObsNameVec.size()==2) { + Double_t fval = mnominal->GetBinContent(i,j); + obsDataUnbinned->add( *proto->set("obsAndWeight"), fval ); + } else { // 3 dimensions + + for(int k=1; k<=az->GetNbins(); ++k) { + Double_t zval = az->GetBinCenter(k); + proto->var( ObsNameVec[2].c_str() )->setVal( zval ); + Double_t fval = mnominal->GetBinContent(i,j,k); + obsDataUnbinned->add( *proto->set("obsAndWeight"), fval ); + } + } + } + } + } + } + void HistoToWorkspaceFactoryFast::GuessObsNameVec(TH1* hist) { fObsNameVec.clear(); @@ -1687,9 +2020,12 @@ namespace HistFactory{ // now with weighted datasets // First Asimov - RooDataSet * simData=NULL; + //RooDataSet * simData=NULL; combined->factory("weightVar[0,-1e10,1e10]"); obsList.add(*combined->var("weightVar")); + + // Loop over channels and create the asimov + /* for(unsigned int i = 0; i< ch_names.size(); ++i){ cout << "merging data for channel " << ch_names[i].c_str() << endl; RooDataSet * tempData=new RooDataSet(ch_names[i].c_str(),"", obsList, Index(*channelCat), @@ -1704,44 +2040,94 @@ namespace HistFactory{ } if (simData) combined->import(*simData,Rename("asimovData")); + */ + RooDataSet* asimov_combined = (RooDataSet*) AsymptoticCalculator::GenerateAsimovData(*simPdf, + obsList); + if( asimov_combined ) { + combined->import( *asimov_combined, Rename("asimovData")); + } + else { + std::cout << "Error: Failed to create combined asimov dataset" << std::endl; + throw hf_exc(); + } + + // Now merge the observable datasets across the channels + if(chs[0]->data("obsData") != NULL) { + MergeDataSets(combined, chs, ch_names, "obsData", obsList, channelCat); + } - // now obs - if(chs[0]->data("obsData")){ - simData=NULL; + /* + if(chs[0]->data("obsData") != NULL){ + RooDataSet * simData=NULL; + //simData=NULL; + + // Loop through channels, get their individual datasets, + // and add them to the combined dataset for(unsigned int i = 0; i< ch_names.size(); ++i){ cout << "merging data for channel " << ch_names[i].c_str() << endl; - RooDataSet * tempData=new RooDataSet(ch_names[i].c_str(),"", obsList, Index(*channelCat), - WeightVar("weightVar"), - Import(ch_names[i].c_str(),*(RooDataSet*)chs[i]->data("obsData"))); - if(simData){ + + RooDataSet* obsDataInChannel = (RooDataSet*) chs[i]->data("obsData"); + RooDataSet * tempData = new RooDataSet(ch_names[i].c_str(),"", obsList, Index(*channelCat), + WeightVar("weightVar"), + Import(ch_names[i].c_str(),*obsDataInChannel)); + // *(RooDataSet*) chs[i]->data("obsData"))); + if(simData) { simData->append(*tempData); delete tempData; - }else{ + } + else { simData = tempData; } - } + } // End Loop Over Channels - if (simData) combined->import(*simData,Rename("obsData")); - } - + // Check that we successfully created the dataset + // and import it into the workspace + if(simData) { + combined->import(*simData, Rename("obsData")); + } + else { + std::cout << "Error: Unable to merge observable datasets" << std::endl; + throw hf_exc(); + } + + } // End 'if' on data != NULL + */ + + // Now, create any additional Asimov datasets that + // are configured in the measurement // obsList.Print(); // combined->import(obsList); // combined->Print(); + obsList.add(*channelCat); combined->defineSet("observables",obsList); combined_config->SetObservables(*combined->set("observables")); - combined->Print(); cout << "\n\n----------------\n Importing combined model" << endl; combined->import(*simPdf,RecycleConflictNodes()); //combined->import(*simPdf, RenameVariable("SigXsecOverSM","SigXsecOverSM_comb")); - cout << "check pointer " << simPdf << endl; + // cout << "check pointer " << simPdf << endl; // cout << "check val " << simPdf->getVal() << endl; + std::map< std::string, double>::iterator param_itr = fParamValues.begin(); + for( ; param_itr != fParamValues.end(); ++param_itr ){ + // make sure they are fixed + std::string paramName = param_itr->first; + double paramVal = param_itr->second; + + RooRealVar* temp = combined->var( paramName.c_str() ); + if(temp) { + temp->setVal( paramVal ); + cout <<"setting " << paramName << " to the value: " << paramVal << endl; + } else + cout << "could not find variable " << paramName << " could not set its value" << endl; + } + + for(unsigned int i=0; i<fSystToFix.size(); ++i){ // make sure they are fixed RooRealVar* temp = combined->var((fSystToFix.at(i)).c_str()); @@ -1768,6 +2154,59 @@ namespace HistFactory{ } + RooDataSet* HistoToWorkspaceFactoryFast::MergeDataSets(RooWorkspace* combined, + std::vector<RooWorkspace*> wspace_vec, + std::vector<std::string> channel_names, + std::string dataSetName, + RooArgList obsList, + RooCategory* channelCat) { + + // Create the total dataset + RooDataSet* simData=NULL; + + // Loop through channels, get their individual datasets, + // and add them to the combined dataset + for(unsigned int i = 0; i< channel_names.size(); ++i){ + + // Grab the dataset for the existing channel + std::cout << "Merging data for channel " << channel_names[i].c_str() << std::endl; + RooDataSet* obsDataInChannel = (RooDataSet*) wspace_vec[i]->data(dataSetName.c_str()); + if( !obsDataInChannel ) { + std::cout << "Error: Can't find DataSet: " << dataSetName + << " in channel: " << channel_names.at(i) + << std::endl; + throw hf_exc(); + } + + // Create the new Dataset + RooDataSet * tempData = new RooDataSet(channel_names[i].c_str(),"", + obsList, Index(*channelCat), + WeightVar("weightVar"), + Import(channel_names[i].c_str(),*obsDataInChannel)); + if(simData) { + simData->append(*tempData); + delete tempData; + } + else { + simData = tempData; + } + } // End Loop Over Channels + + // Check that we successfully created the dataset + // and import it into the workspace + if(simData) { + combined->import(*simData, Rename(dataSetName.c_str())); + } + else { + std::cout << "Error: Unable to merge observable datasets" << std::endl; + throw hf_exc(); + } + + return simData; + + } + + TH1* HistoToWorkspaceFactoryFast::MakeAbsolUncertaintyHist( const std::string& Name, const TH1* Nominal ) { // Take a nominal TH1* and create @@ -1797,9 +2236,9 @@ namespace HistFactory{ << " bin error for bin " << i_bin << " is NAN. Not using Error!!!" << std::endl; - throw -1; + throw hf_exc(); //histError = sqrt( histContent ); - histError = 0; + //histError = 0; } // Check that histError ! < 0 @@ -1895,8 +2334,8 @@ namespace HistFactory{ << " bin error for bin " << binNumber << " is NAN. Not using error!!" << std::endl; - throw -1; - histError = 0; + throw hf_exc(); + //histError = 0; } TotalBinContent.at(i_bins) += histValue; @@ -1941,8 +2380,7 @@ namespace HistFactory{ std::cout << " HistErrorsSqr: " << ErrorsSqr << " TotalVal: " << TotalVal << std::endl; - throw -1; - return NULL; + throw hf_exc(); } // 0th entry in vector is @@ -1965,9 +2403,10 @@ namespace HistFactory{ - RooArgList HistoToWorkspaceFactoryFast::createStatConstraintTerms( RooWorkspace* proto, vector<string>& constraintTermNames, - ParamHistFunc& paramHist, TH1* uncertHist, - EstimateSummary::ConstraintType type, Double_t minSigma ) { + RooArgList HistoToWorkspaceFactoryFast:: + createStatConstraintTerms( RooWorkspace* proto, vector<string>& constraintTermNames, + ParamHistFunc& paramHist, TH1* uncertHist, + Constraint::Type type, Double_t minSigma ) { // Take a RooArgList of RooAbsReal's and @@ -1987,21 +2426,19 @@ namespace HistFactory{ RooArgList paramSet = paramHist.paramList(); - // Must get the full size of the TH1 // (No direct method to do this...) Int_t numBins = uncertHist->GetNbinsX()*uncertHist->GetNbinsY()*uncertHist->GetNbinsZ(); Int_t numParams = paramSet.getSize(); // Int_t numBins = uncertHist->GetNbinsX()*uncertHist->GetNbinsY()*uncertHist->GetNbinsZ(); - // Check that there are N elements // in the RooArgList if( numBins != numParams ) { - std::cout << "createStatConstraintTerms: bad number of bins" << std::endl; + std::cout << "Error: In createStatConstraintTerms, encountered bad number of bins" << std::endl; std::cout << "Given histogram with " << numBins << " bins," << " but require exactly " << numParams << std::endl; - return ConstraintTerms; + throw hf_exc(); } Int_t TH1BinNumber = 0; @@ -2013,7 +2450,6 @@ namespace HistFactory{ TH1BinNumber++; } - RooRealVar& gamma = (RooRealVar&) (paramSet[i]); std::cout << "Creating constraint for: " << gamma.GetName() @@ -2040,69 +2476,65 @@ namespace HistFactory{ gamma.setMax( 1 + 5*sigma ); // gamma.setMin( TMath::Max(1. - 5*sigma, 0.) ); gamma.setMin( 0. ); - - - // Make Constraint Term - std::string constrName = string(gamma.GetName()) + "_constraint"; - std::string nomName = string("nom_") + gamma.GetName(); - std::string sigmaName = string(gamma.GetName()) + "_sigma"; - std::string poisMeanName = string(gamma.GetName()) + "_poisMean"; + // Make Constraint Term + std::string constrName = string(gamma.GetName()) + "_constraint"; + std::string nomName = string("nom_") + gamma.GetName(); + std::string sigmaName = string(gamma.GetName()) + "_sigma"; + std::string poisMeanName = string(gamma.GetName()) + "_poisMean"; + if( type == Constraint::Gaussian ) { - if( type == EstimateSummary::Gaussian ) { - - // Type 1 : RooGaussian + // Type 1 : RooGaussian - // Make sigma + // Make sigma - RooConstVar constrSigma( sigmaName.c_str(), sigmaName.c_str(), sigma ); - //proto->import( constrSigma, RecycleConflictNodes() ); - //proto->import( constrSigma ); - + RooConstVar constrSigma( sigmaName.c_str(), sigmaName.c_str(), sigma ); + //proto->import( constrSigma, RecycleConflictNodes() ); + //proto->import( constrSigma ); - // Make "observed" value - RooRealVar constrNom(nomName.c_str(), nomName.c_str(), 1.0,0,10); - constrNom.setConstant( true ); + // Make "observed" value + RooRealVar constrNom(nomName.c_str(), nomName.c_str(), 1.0,0,10); + constrNom.setConstant( true ); - // Make the constraint: - RooGaussian gauss( constrName.c_str(), constrName.c_str(), - constrNom, gamma, constrSigma ); + // Make the constraint: + RooGaussian gauss( constrName.c_str(), constrName.c_str(), + constrNom, gamma, constrSigma ); - proto->import( gauss, RecycleConflictNodes() ); - //proto->import( gauss ); + proto->import( gauss, RecycleConflictNodes() ); + //proto->import( gauss ); - } else if( type == EstimateSummary::Poisson ) { + } else if( type == Constraint::Poisson ) { - Double_t tau = 1/sigma/sigma; // this is correct Poisson equivalent to a Gaussian with mean 1 and stdev sigma + Double_t tau = 1/sigma/sigma; // this is correct Poisson equivalent to a Gaussian with mean 1 and stdev sigma - // Make nominal "observed" value - RooRealVar constrNom(nomName.c_str(), nomName.c_str(), tau); - constrNom.setMin(0); - constrNom.setConstant( true ); + // Make nominal "observed" value + RooRealVar constrNom(nomName.c_str(), nomName.c_str(), tau); + constrNom.setMin(0); + constrNom.setConstant( true ); - // Make the scaling term - std::string scalingName = string(gamma.GetName()) + "_tau"; - RooConstVar poissonScaling( scalingName.c_str(), scalingName.c_str(), tau); + // Make the scaling term + std::string scalingName = string(gamma.GetName()) + "_tau"; + RooConstVar poissonScaling( scalingName.c_str(), scalingName.c_str(), tau); - // Make mean for scaled Poisson - RooProduct constrMean( poisMeanName.c_str(), poisMeanName.c_str(), RooArgSet(gamma, poissonScaling) ); - //proto->import( constrSigma, RecycleConflictNodes() ); - //proto->import( constrSigma ); - - // Type 2 : RooPoisson - RooPoisson pois(constrName.c_str(), constrName.c_str(), constrNom, constrMean); - pois.setNoRounding(true); - proto->import( pois, RecycleConflictNodes() ); - + // Make mean for scaled Poisson + RooProduct constrMean( poisMeanName.c_str(), poisMeanName.c_str(), RooArgSet(gamma, poissonScaling) ); + //proto->import( constrSigma, RecycleConflictNodes() ); + //proto->import( constrSigma ); + + // Type 2 : RooPoisson + RooPoisson pois(constrName.c_str(), constrName.c_str(), constrNom, constrMean); + pois.setNoRounding(true); + proto->import( pois, RecycleConflictNodes() ); - } else { + } else { - std::cout << "Error: Did not recognize Stat Error constraint term type: " - << type << " for : " << paramHist.GetName() << std::endl; - } + std::cout << "Error: Did not recognize Stat Error constraint term type: " + << type << " for : " << paramHist.GetName() << std::endl; + throw hf_exc(); + } - // If the sigma value is less + // If the sigma value is less // than a supplied threshold, // set the variable to constant if( sigma < minSigma ) { @@ -2112,51 +2544,25 @@ namespace HistFactory{ << std::endl; gamma.setConstant(kTRUE); } - + constraintTermNames.push_back( constrName ); ConstraintTerms.add( *proto->pdf(constrName.c_str()) ); // Add the "observed" value to the // list of global observables: RooArgSet* globalSet = const_cast<RooArgSet*>(proto->set("globalObservables")); - + RooRealVar* nomVarInWorkspace = proto->var(nomName.c_str()); if( ! globalSet->contains(*nomVarInWorkspace) ) { globalSet->add( *nomVarInWorkspace ); } - - + } // end loop over parameters - - + return ConstraintTerms; } - - - TDirectory * HistoToWorkspaceFactoryFast::Makedirs( TDirectory * file, vector<string> names ){ - if(! file) return file; - string path=""; - TDirectory* ptr=0; - for(vector<string>::iterator itr=names.begin(); itr != names.end(); ++itr){ - if( ! path.empty() ) path+="/"; - path+=(*itr); - ptr=file->GetDirectory(path.c_str()); - if( ! ptr ) ptr=file->mkdir((*itr).c_str()); - file=file->GetDirectory(path.c_str()); - } - return ptr; - } - TDirectory * HistoToWorkspaceFactoryFast::Mkdir( TDirectory * file, string name ){ - if(! file) return file; - TDirectory* ptr=0; - ptr=file->GetDirectory(name.c_str()); - if( ! ptr ) ptr=file->mkdir(name.c_str()); - return ptr; - } - -} - -} +} // namespace RooStats +} // namespace HistFactory diff --git a/roofit/histfactory/src/LinInterpVar.cxx b/roofit/histfactory/src/LinInterpVar.cxx index 04ae43ab7adc3..8313c20adb727 100644 --- a/roofit/histfactory/src/LinInterpVar.cxx +++ b/roofit/histfactory/src/LinInterpVar.cxx @@ -32,6 +32,8 @@ END_HTML #include "RooStats/HistFactory/LinInterpVar.h" +using namespace std; + ClassImp(RooStats::HistFactory::LinInterpVar) using namespace RooStats; diff --git a/roofit/histfactory/src/MakeModelAndMeasurements.cxx b/roofit/histfactory/src/MakeModelAndMeasurements.cxx index 91883a4672d97..2cd406d5b142d 100644 --- a/roofit/histfactory/src/MakeModelAndMeasurements.cxx +++ b/roofit/histfactory/src/MakeModelAndMeasurements.cxx @@ -86,15 +86,19 @@ END_HTML #include "RooStats/HistFactory/ConfigParser.h" #include "RooStats/HistFactory/EstimateSummary.h" #include "RooStats/HistFactory/HistoToWorkspaceFactory.h" +#include "RooStats/HistFactory/HistFactoryException.h" using namespace RooFit; using namespace RooStats; using namespace HistFactory; +using namespace std; + void topDriver(string input); -void fastDriver(string input); // in MakeModelAndMeasurementsFast +// void fastDriver(string input); // in MakeModelAndMeasurementsFast +/* //_____________________________batch only_____________________ #ifndef __CINT__ @@ -113,6 +117,9 @@ int main(int argc, char** argv) { catch (std::string str) { cerr << "caught exception: " << str << endl ; } + catch( const exception& e ) { + cerr << "Caught Exception: " << e.what() << endl; + } } if(argc==3){ @@ -125,6 +132,9 @@ int main(int argc, char** argv) { catch (std::string str) { cerr << "caught exception: " << str << endl ; } + catch( const exception& e ) { + cerr << "Caught Exception: " << e.what() << endl; + } else if(flag=="-number_counting_form") try { topDriver(input); @@ -132,6 +142,10 @@ int main(int argc, char** argv) { catch (std::string str) { cerr << "caught exception: " << str << endl ; } + catch( const exception& e ) { + cerr << "Caught Exception: " << e.what() << endl; + } + else cerr <<"unrecognized flag. Options are -standard_form or -number_counting_form"<<endl; @@ -140,7 +154,7 @@ int main(int argc, char** argv) { } #endif - +*/ void topDriver( string input ) { @@ -210,6 +224,11 @@ void topDriver( string input ) { std::vector< EstimateSummary > dummy; RooWorkspace* ws = factory.MakeSingleChannelModel( dummy, measurement.GetConstantParams() ); + if( ws==NULL ) { + std::cout << "Failed to create SingleChannelModel for channel: " << channel.GetName() + << " and measurement: " << measurement.GetName() << std::endl; + throw hf_exc(); + } //RooWorkspace* ws = factory.MakeSingleChannelModel( channel ); channel_workspaces.push_back(ws); @@ -263,6 +282,10 @@ void topDriver( string input ) { // Now, combine the channels RooWorkspace* ws=factory.MakeCombinedModel(channel_names, channel_workspaces); + if( ws == NULL ) { + std::cout << "Error: Failed to create workspace" << std::endl; + throw hf_exc(); + } // Gamma/Uniform Constraints: // turn some Gaussian constraints into Gamma/Uniform/logNormal constraints, rename model newSimPdf if( measurement.GetGammaSyst().size()>0 || measurement.GetUniformSyst().size()>0 || measurement.GetLogNormSyst().size()>0) diff --git a/roofit/histfactory/src/MakeModelAndMeasurementsFast.cxx b/roofit/histfactory/src/MakeModelAndMeasurementsFast.cxx index 050e565339398..2fef680a45f26 100644 --- a/roofit/histfactory/src/MakeModelAndMeasurementsFast.cxx +++ b/roofit/histfactory/src/MakeModelAndMeasurementsFast.cxx @@ -86,174 +86,90 @@ // from this package #include "Helper.h" -#include "RooStats/HistFactory/ConfigParser.h" #include "RooStats/HistFactory/EstimateSummary.h" #include "RooStats/HistFactory/Measurement.h" #include "RooStats/HistFactory/HistoToWorkspaceFactoryFast.h" -//#include "RooStats/HistFactory/HistoToWorkspaceFactoryNew.h" #include "RooStats/HistFactory/HistFactoryException.h" #include "RooStats/HistFactory/MakeModelAndMeasurementsFast.h" using namespace RooFit; -using namespace RooStats; -using namespace HistFactory; +//using namespace RooStats; +//using namespace HistFactory; - -void fastDriver(string input){ - // TO DO: - // would like to fully factorize the XML parsing. - // No clear need to have some here and some in ConfigParser - - - // Make the list of measurements and channels - std::vector< HistFactory::Measurement > measurement_list; - std::vector< HistFactory::Channel > channel_list; - - HistFactory::ConfigParser xmlParser; - - measurement_list = xmlParser.GetMeasurementsFromXML( input ); - - // Fill them using the XML parser - // xmlParser.FillMeasurementsAndChannelsFromXML( input, measurement_list, channel_list ); - - // At this point, we have all the information we need - // from the xml files. - - - // We will make the measurements 1-by-1 - // This part will be migrated to the - // MakeModelAndMeasurements function, - // but is here for now. - - - /* Now setup the measurement */ - // At this point, all we need - // is the list of measurements - - for(unsigned int i = 0; i < measurement_list.size(); ++i) { - - HistFactory::Measurement measurement = measurement_list.at(i); - - measurement.CollectHistograms(); - - MakeModelAndMeasurementFast( measurement ); - - } - - return; - -} - -/* - Moved to HistoToWorkspaceFactoryFast -std::vector<EstimateSummary> RooStats::HistFactory::GetChannelEstimateSummaries(RooStats::HistFactory::Measurement& measurement, RooStats::HistFactory::Channel& channel) { - -*/ - -/* -void RooStats::HistFactory::ConfigureWorkspaceForMeasurement( const std::string& ModelName, RooWorkspace* ws_single, RooStats::HistFactory::Measurement& measurement ) { - -*/ +//using namespace std; RooWorkspace* RooStats::HistFactory::MakeModelAndMeasurementFast( RooStats::HistFactory::Measurement& measurement ) { - - /* - // Add the channels to this measurement - for( unsigned int chanItr = 0; chanItr < channel_list.size(); ++chanItr ) { - measurement.channels.push_back( channel_list.at( chanItr ) ); - } - */ // This will be returned RooWorkspace* ws = NULL; + TFile* outFile = NULL; + FILE* tableFile=NULL; try { - std::cout << "Making Model and Measurements (Fast) for measurement: " << measurement.GetName() << std::endl; double lumiError = measurement.GetLumi()*measurement.GetLumiRelErr(); std::cout << "using lumi = " << measurement.GetLumi() << " and lumiError = " << lumiError - << " including bins between " << measurement.GetBinLow() << " and " << measurement.GetBinHigh() << std::endl; + << " including bins between " << measurement.GetBinLow() << " and " << measurement.GetBinHigh() << std::endl; std::cout << "fixing the following parameters:" << std::endl; - for(vector<string>::iterator itr=measurement.GetConstantParams().begin(); itr!=measurement.GetConstantParams().end(); ++itr){ - cout << " " << *itr << endl; + for(std::vector<std::string>::iterator itr=measurement.GetConstantParams().begin(); itr!=measurement.GetConstantParams().end(); ++itr){ + std::cout << " " << *itr << std::endl; } std::string rowTitle = measurement.GetName(); - vector<RooWorkspace*> channel_workspaces; - vector<string> channel_names; - + std::vector<RooWorkspace*> channel_workspaces; + std::vector<std::string> channel_names; + // Create the outFile // This holds the TGraphs that are created during the fit std::string outputFileName = measurement.GetOutputFilePrefix() + "_" + measurement.GetName() + ".root"; std::cout << "Creating the output file: " << outputFileName << std::endl; - TFile* outFile = new TFile(outputFileName.c_str(), "recreate"); + outFile = new TFile(outputFileName.c_str(), "recreate"); + // Create the table file // This holds the table of fitted values and errors std::string tableFileName = measurement.GetOutputFilePrefix() + "_results.table"; std::cout << "Creating the table file: " << tableFileName << std::endl; - FILE* tableFile = fopen( tableFileName.c_str(), "a"); + tableFile = fopen( tableFileName.c_str(), "a"); std::cout << "Creating the HistoToWorkspaceFactoryFast factory" << std::endl; - HistoToWorkspaceFactoryFast factory( measurement ); - - // USING OLD VERSION... - /* - TFile* dummyFile = NULL; // TEMPORARY !!!!! - HistoToWorkspaceFactoryFast factory(measurement.GetOutputFilePrefix(), rowTitle, measurement.GetConstantParams(), - measurement.GetLumi(), lumiError, - measurement.GetBinLow(), measurement.GetBinHigh(), dummyFile ); - */ - - std::cout << "Setting preprocess functions" << std::endl; - + // Make the factory, and do some preprocessing // HistoToWorkspaceFactoryFast factory(measurement, rowTitle, outFile); + std::cout << "Setting preprocess functions" << std::endl; factory.SetFunctionsToPreprocess( measurement.GetPreprocessFunctions() ); - // for results tables fprintf(tableFile, " %s &", rowTitle.c_str() ); - /*** - First: Loop to make the individual channels - ***/ - - + // First: Loop to make the individual channels for( unsigned int chanItr = 0; chanItr < measurement.GetChannels().size(); ++chanItr ) { HistFactory::Channel& channel = measurement.GetChannels().at( chanItr ); - if( ! channel.CheckHistograms() ) { std::cout << "MakeModelAndMeasurementsFast: Channel: " << channel.GetName() << " has uninitialized histogram pointers" << std::endl; - throw bad_hf; - return NULL; + throw hf_exc(); } - string ch_name = channel.GetName(); - channel_names.push_back(ch_name); - + // Make the workspace for this individual channel + std::string ch_name = channel.GetName(); std::cout << "Starting to process channel: " << ch_name << std::endl; - + channel_names.push_back(ch_name); RooWorkspace* ws_single = factory.MakeSingleChannelModel( measurement, channel ); - channel_workspaces.push_back(ws_single); - // Get the Paramater of Interest as a RooRealVar - RooRealVar* poi = (RooRealVar*) ws_single->var( (measurement.GetPOI()).c_str() ); - - // Make the output - std::string ChannelFileName = measurement.GetOutputFilePrefix() + "_" + ch_name + "_" + rowTitle + "_model.root"; + std::string ChannelFileName = measurement.GetOutputFilePrefix() + "_" + + ch_name + "_" + rowTitle + "_model.root"; ws_single->writeToFile( ChannelFileName.c_str() ); // Now, write the measurement to the file @@ -268,19 +184,25 @@ RooWorkspace* RooStats::HistFactory::MakeModelAndMeasurementFast( RooStats::Hist std::cout << "Successfully wrote channel to file" << std::endl; chanFile->Close(); + // Get the Paramater of Interest as a RooRealVar + RooRealVar* poi = dynamic_cast<RooRealVar*>( ws_single->var( (measurement.GetPOI()).c_str() ) ); + // do fit unless exportOnly requested if(! measurement.GetExportOnly()){ - if(!poi){ - cout <<"can't do fit for this channel, no parameter of interest"<<endl; - } else{ - if(ws_single->data("obsData")){ - FitModelAndPlot(measurement.GetName(), measurement.GetOutputFilePrefix(), ws_single, ch_name, "obsData", outFile, tableFile); + if(!poi) { + std::cout << "Can't do fit for: " << measurement.GetName() + << ", no parameter of interest" << std::endl; + } else { + if(ws_single->data("obsData")) { + FitModelAndPlot(measurement.GetName(), measurement.GetOutputFilePrefix(), ws_single, + ch_name, "obsData", outFile, tableFile); } else { - FitModelAndPlot(measurement.GetName(), measurement.GetOutputFilePrefix(), ws_single, ch_name, "asimovData", outFile, tableFile); + FitModelAndPlot(measurement.GetName(), measurement.GetOutputFilePrefix(), ws_single, + ch_name, "asimovData", outFile, tableFile); } } } - + fprintf(tableFile, " & " ); } // End loop over channels @@ -290,7 +212,6 @@ RooWorkspace* RooStats::HistFactory::MakeModelAndMeasurementFast( RooStats::Hist "combine" : will do the individual cross-section measurements plus combination ***/ - // Use HistFactory to combine the individual channel workspaces ws = factory.MakeCombinedModel(channel_names, channel_workspaces); @@ -298,27 +219,35 @@ RooWorkspace* RooStats::HistFactory::MakeModelAndMeasurementFast( RooStats::Hist HistoToWorkspaceFactoryFast::ConfigureWorkspaceForMeasurement( "simPdf", ws, measurement ); // Get the Parameter of interest as a RooRealVar - RooRealVar* poi = (RooRealVar*) ws->var( (measurement.GetPOI()).c_str() ); - - // ws->writeToFile(("results/model_combined_edited.root").c_str()); - //ws->writeToFile((measurement.OutputFilePrefix+"_combined_"+rowTitle+"_model.root").c_str()); - std::string CombinedFileName = measurement.GetOutputFilePrefix()+"_combined_"+rowTitle+"_model.root"; + RooRealVar* poi = dynamic_cast<RooRealVar*>( ws->var( (measurement.GetPOI()).c_str() ) ); + + std::string CombinedFileName = measurement.GetOutputFilePrefix() + "_combined_" + + rowTitle + "_model.root"; + std::cout << "Writing combined workspace to file: " << CombinedFileName << std::endl; ws->writeToFile( CombinedFileName.c_str() ); - std::cout << "About to write combined measurement to file" << std::endl; + std::cout << "Writing combined measurement to file: " << CombinedFileName << std::endl; TFile* combFile = TFile::Open( CombinedFileName.c_str(), "UPDATE" ); + if( combFile == NULL ) { + std::cout << "Error: Failed to open file " << CombinedFileName << std::endl; + throw hf_exc(); + } measurement.writeToFile( combFile ); combFile->Close(); - - // TO DO: - // Totally factorize the statistical test in "fit Model" to a different area + + // Fit the combined model if(! measurement.GetExportOnly()){ - if(!poi){ - cout <<"can't do fit for this channel, no parameter of interest"<<endl; - } else{ + if(!poi) { + std::cout << "Can't do fit for: " << measurement.GetName() + << ", no parameter of interest" << std::endl; + } + else { if(ws->data("obsData")){ - FitModelAndPlot(measurement.GetName(), measurement.GetOutputFilePrefix(), ws, "combined", "obsData", outFile, tableFile); - } else { - FitModelAndPlot(measurement.GetName(), measurement.GetOutputFilePrefix(), ws, "combined", "asimovData", outFile, tableFile); + FitModelAndPlot(measurement.GetName(), measurement.GetOutputFilePrefix(), ws,"combined", + "obsData", outFile, tableFile); + } + else { + FitModelAndPlot(measurement.GetName(), measurement.GetOutputFilePrefix(), ws,"combined", + "asimovData", outFile, tableFile); } } } @@ -331,170 +260,213 @@ RooWorkspace* RooStats::HistFactory::MakeModelAndMeasurementFast( RooStats::Hist fclose( tableFile ); } - catch(exception& e) - { - std::cout << e.what() << std::endl; - throw bad_hf; - return NULL; - } - + catch(...) { + if( tableFile ) fclose(tableFile); + if(outFile) outFile->Close(); + throw; + } + return ws; - } - /////////////////////////////////////////////// -void RooStats::HistFactory::FitModelAndPlot(const std::string& MeasurementName, const std::string& FileNamePrefix, RooWorkspace * combined, string channel, string data_name, TFile* outFile, FILE* tableFile ) - { - - cout << "In Fit Model"<<endl; - ModelConfig * combined_config = (ModelConfig *) combined->obj("ModelConfig"); - if(!combined_config){ - cout << "no model config " << "ModelConfig" << " exiting" << endl; - return; - } - // RooDataSet * simData = (RooDataSet *) combined->obj(data_name.c_str()); - RooAbsData* simData = combined->data(data_name.c_str()); - if(!simData){ - cout << "no data " << data_name << " exiting" << endl; - return; - } - // const RooArgSet * constrainedParams=combined_config->GetNuisanceParameters(); - const RooArgSet * POIs=combined_config->GetParametersOfInterest(); - if(!POIs){ - cout << "no poi " << data_name << " exiting" << endl; - return; - } +/////////////////////////////////////////////// +void RooStats::HistFactory::FitModelAndPlot(const std::string& MeasurementName, + const std::string& FileNamePrefix, + RooWorkspace * combined, std::string channel, + std::string data_name, + TFile* outFile, FILE* tableFile ) { + + if( outFile == NULL ) { + std::cout << "Error: Output File in FitModelAndPlot is NULL" << std::endl; + throw hf_exc(); + } - //RooAbsPdf* model=combined->pdf(model_name.c_str()); - RooAbsPdf* model=combined_config->GetPdf(); - // RooArgSet* allParams = model->getParameters(*simData); - - /////////////////////////////////////// - //Do combined fit - //RooMsgService::instance().setGlobalKillBelow(RooMsgService::INFO) ; - cout << "\n\n---------------" << endl; - cout << "---------------- Doing "<< channel << " Fit" << endl; - cout << "---------------\n\n" << endl; - // RooFitResult* result = model->fitTo(*simData, Minos(kTRUE), Save(kTRUE), PrintLevel(1)); - model->fitTo(*simData, Minos(kTRUE), PrintLevel(1)); - // PrintCovarianceMatrix(result, allParams, "results/"+FilePrefixStr(channel)+"_corrMatrix.table" ); + if( tableFile == NULL ) { + std::cout << "Error: tableFile in FitModelAndPlot is NULL" << std::endl; + throw hf_exc(); + } - if( outFile != NULL ) { + if( combined == NULL ) { + std::cout << "Error: Supplied workspace in FitModelAndPlot is NULL" << std::endl; + throw hf_exc(); + } - // - // assuming there is only on poi - // + ModelConfig* combined_config = (ModelConfig *) combined->obj("ModelConfig"); + if(!combined_config){ + std::cout << "Error: no ModelConfig found in Measurement: " + << MeasurementName << std::endl; + throw hf_exc(); + } - RooRealVar* poi = 0; // (RooRealVar*) POIs->first(); - // for results tables - TIterator* params_itr=POIs->createIterator(); - TObject* params_obj=0; - while((params_obj=params_itr->Next())){ - poi = (RooRealVar*) params_obj; - cout << "printing results for " << poi->GetName() << " at " << poi->getVal()<< " high " << poi->getErrorLo() << " low " << poi->getErrorHi()<<endl; - } - fprintf(tableFile, " %.4f / %.4f ", poi->getErrorLo(), poi->getErrorHi()); - - RooAbsReal* nll = model->createNLL(*simData); - RooAbsReal* profile = nll->createProfile(*poi); - RooPlot* frame = poi->frame(); - FormatFrameForLikelihood(frame); - TCanvas* c1 = new TCanvas( channel.c_str(), "",800,600); - nll->plotOn(frame, ShiftToZero(), LineColor(kRed), LineStyle(kDashed)); - profile->plotOn(frame); - frame->SetMinimum(0); - frame->SetMaximum(2.); - frame->Draw(); - // c1->SaveAs( ("results/"+FilePrefixStr(channel)+"_profileLR.eps").c_str() ); - c1->SaveAs( (FileNamePrefix+"_"+channel+"_"+MeasurementName+"_profileLR.eps").c_str() ); - delete c1; - - outFile->mkdir(channel.c_str())->mkdir("Summary")->cd(); - - RooCurve* curve=frame->getCurve(); - Int_t curve_N=curve->GetN(); - Double_t* curve_x=curve->GetX(); - delete frame; - - // - // Verbose output from MINUIT - // - /* - RooMsgService::instance().setGlobalKillBelow(RooFit::DEBUG) ; - profile->getVal(); - RooMinuit* minuit = ((RooProfileLL*) profile)->minuit(); - minuit->setPrintLevel(5) ; // Print MINUIT messages - minuit->setVerbose(5) ; // Print RooMinuit messages with parameter - // changes (corresponds to the Verbose() option of fitTo() - */ + RooAbsData* simData = combined->data(data_name.c_str()); + if(!simData){ + std::cout << "Error: Failed to get dataset: " << data_name + << " in measurement: " << MeasurementName << std::endl; + throw hf_exc(); + } - Double_t * x_arr = new Double_t[curve_N]; - Double_t * y_arr_nll = new Double_t[curve_N]; - // Double_t y_arr_prof_nll[curve_N]; - // Double_t y_arr_prof[curve_N]; - - for(int i=0; i<curve_N; i++){ - double f=curve_x[i]; - poi->setVal(f); - x_arr[i]=f; - y_arr_nll[i]=nll->getVal(); - } + const RooArgSet* POIs = combined_config->GetParametersOfInterest(); + if(!POIs) { + std::cout << "Not Fitting Model for measurement: " << MeasurementName + << ", no poi found" << std::endl; + // Should I throw an exception here? + return; + } - TGraph * g = new TGraph(curve_N, x_arr, y_arr_nll); - //g->SetName( (FilePrefixStr(channel) +"_nll").c_str()); - g->SetName( (FileNamePrefix +"_nll").c_str() ); - g->Write(); - delete g; - delete [] x_arr; - delete [] y_arr_nll; + RooAbsPdf* model = combined_config->GetPdf(); + if( model==NULL ) { + std::cout << "Error: Failed to find pdf in ModelConfig: " << combined_config->GetName() + << std::endl; + throw hf_exc(); + } - } + // Save a Snapshot + RooArgSet PoiPlusNuisance( *combined_config->GetNuisanceParameters() ); + PoiPlusNuisance.add( *combined_config->GetParametersOfInterest() ); + combined->saveSnapshot("InitialValues", PoiPlusNuisance); + + /////////////////////////////////////// + // Do the fit + std::cout << "\n\n---------------" << std::endl; + std::cout << "---------------- Doing "<< channel << " Fit" << std::endl; + std::cout << "---------------\n\n" << std::endl; + model->fitTo(*simData, Minos(kTRUE), PrintLevel(1)); + + // If there are no parameters of interest, + // we exit the function here + if( POIs->getSize()==0 ) { + std::cout << "WARNING: No POIs found in measurement: " << MeasurementName << std::endl; + return; + } + + // Loop over all POIs and print their fitted values + RooRealVar* poi = NULL; // (RooRealVar*) POIs->first(); + TIterator* params_itr = POIs->createIterator(); + TObject* poi_obj=NULL; + while( (poi_obj=params_itr->Next()) ) { + //poi = (RooRealVar*) poi_obj; + poi = dynamic_cast<RooRealVar*>(poi_obj); + std::cout << "printing results for " << poi->GetName() + << " at " << poi->getVal()<< " high " + << poi->getErrorLo() << " low " + << poi->getErrorHi() << std::endl; + } + + // But we only make detailed plots and tables + // for the 'first' POI + poi = dynamic_cast<RooRealVar*>(POIs->first()); + + // Print the MINOS errors to the TableFile + fprintf(tableFile, " %.4f / %.4f ", poi->getErrorLo(), poi->getErrorHi()); + + // Make the Profile Likelihood Plot + RooAbsReal* nll = model->createNLL(*simData); + RooAbsReal* profile = nll->createProfile(*poi); + if( profile==NULL ) { + std::cout << "Error: Failed to make ProfileLikelihood for: " << poi->GetName() + << " using model: " << model->GetName() + << " and data: " << simData->GetName() + << std::endl; + throw hf_exc(); + } + + RooPlot* frame = poi->frame(); + if( frame == NULL ) { + std::cout << "Error: Failed to create RooPlot frame for: " << poi->GetName() << std::endl; + throw hf_exc(); + } + + // Draw the likelihood curve + FormatFrameForLikelihood(frame); + TCanvas* ProfileLikelihoodCanvas = new TCanvas( channel.c_str(), "",800,600); + nll->plotOn(frame, ShiftToZero(), LineColor(kRed), LineStyle(kDashed)); + profile->plotOn(frame); + frame->SetMinimum(0); + frame->SetMaximum(2.); + frame->Draw(); + std::string ProfilePlotName = FileNamePrefix+"_"+channel+"_"+MeasurementName+"_profileLR.eps"; + ProfileLikelihoodCanvas->SaveAs( ProfilePlotName.c_str() ); + delete ProfileLikelihoodCanvas; + + // Now, we save our results to the 'output' file + // (I'm not sure if users actually look into this file, + // but adding additional information and useful plots + // may make it more attractive) + + // Save to the output file + TDirectory* channel_dir = outFile->mkdir(channel.c_str()); + if( channel_dir == NULL ) { + std::cout << "Error: Failed to make channel directory: " << channel << std::endl; + throw hf_exc(); + } + TDirectory* summary_dir = channel_dir->mkdir("Summary"); + if( summary_dir == NULL ) { + std::cout << "Error: Failed to make Summary directory for channel: " + << channel << std::endl; + throw hf_exc(); + } + summary_dir->cd(); - /** find out what's inside the workspace **/ - //combined->Print(); + // Save a graph of the profile likelihood curve + RooCurve* curve=frame->getCurve(); + Int_t curve_N=curve->GetN(); + Double_t* curve_x=curve->GetX(); + delete frame; + Double_t * x_arr = new Double_t[curve_N]; + Double_t * y_arr_nll = new Double_t[curve_N]; + + for(int i=0; i<curve_N; i++){ + double f=curve_x[i]; + poi->setVal(f); + x_arr[i]=f; + y_arr_nll[i]=nll->getVal(); } + TGraph* g = new TGraph(curve_N, x_arr, y_arr_nll); + g->SetName( (FileNamePrefix +"_nll").c_str() ); + g->Write(); + delete g; + delete [] x_arr; + delete [] y_arr_nll; + + // Finally, restore the initial values + combined->loadSnapshot("InitialValues"); + +} + -void RooStats::HistFactory::FitModel(RooWorkspace * combined, string data_name ) - { +void RooStats::HistFactory::FitModel(RooWorkspace * combined, std::string data_name ) { - cout << "In Fit Model"<<endl; + std::cout << "In Fit Model" << std::endl; ModelConfig * combined_config = (ModelConfig *) combined->obj("ModelConfig"); if(!combined_config){ - cout << "no model config " << "ModelConfig" << " exiting" << endl; + std::cout << "no model config " << "ModelConfig" << " exiting" << std::endl; return; } - // RooDataSet * simData = (RooDataSet *) combined->obj(data_name.c_str()); + RooAbsData* simData = combined->data(data_name.c_str()); if(!simData){ - cout << "no data " << data_name << " exiting" << endl; + std::cout << "no data " << data_name << " exiting" << std::endl; return; } - // const RooArgSet * constrainedParams=combined_config->GetNuisanceParameters(); + const RooArgSet * POIs=combined_config->GetParametersOfInterest(); if(!POIs){ - cout << "no poi " << data_name << " exiting" << endl; + std::cout << "no poi " << data_name << " exiting" << std::endl; return; } - //RooAbsPdf* model=combined->pdf(model_name.c_str()); RooAbsPdf* model=combined_config->GetPdf(); - // RooArgSet* allParams = model->getParameters(*simData); - - /////////////////////////////////////// - //Do combined fit - //RooMsgService::instance().setGlobalKillBelow(RooMsgService::INFO) ; - // RooFitResult* result = model->fitTo(*simData, Minos(kTRUE), Save(kTRUE), PrintLevel(1)); model->fitTo(*simData, Minos(kTRUE), PrintLevel(1)); - // PrintCovarianceMatrix(result, allParams, "results/"+FilePrefixStr(channel)+"_corrMatrix.table" ); - + } -void RooStats::HistFactory::FormatFrameForLikelihood(RooPlot* frame, string /*XTitle*/, string YTitle){ +void RooStats::HistFactory::FormatFrameForLikelihood(RooPlot* frame, std::string /*XTitle*/, + std::string YTitle){ gStyle->SetCanvasBorderMode(0); gStyle->SetPadBorderMode(0); @@ -526,9 +498,3 @@ void RooStats::HistFactory::FormatFrameForLikelihood(RooPlot* frame, string /*XT } - - -/* -Removed. Use instead HistoToWorkspaceFactoryFast.MakeCombinedModel() -RooWorkspace* RooStats::HistFactory::MakeModelFast( RooStats::HistFactory::Measurement& measurement ) { -*/ diff --git a/roofit/histfactory/src/Measurement.cxx b/roofit/histfactory/src/Measurement.cxx index 2952c540e2628..748d954377620 100644 --- a/roofit/histfactory/src/Measurement.cxx +++ b/roofit/histfactory/src/Measurement.cxx @@ -1,6 +1,30 @@ +// @(#)root/roostats:$Id$ +// Author: Kyle Cranmer, George Lewis +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +//_________________________________________________ +/* +BEGIN_HTML +<p> +The RooStats::HistFactory::Measurement class can be used to construct a model +by combining multiple RooStats::HistFactory::Channel objects. It also allows +to set some general properties like the integrated luminosity, its relative +uncertainty or the functional form of constraints on nuisance parameters. +</p> +END_HTML +*/ +// + #include <ctime> #include <iostream> +#include <algorithm> #include <sys/stat.h> #include "TSystem.h" #include "TTimeStamp.h" @@ -8,12 +32,17 @@ #include "RooStats/HistFactory/Measurement.h" #include "RooStats/HistFactory/HistFactoryException.h" +using namespace std; + ClassImp(RooStats::HistFactory::Measurement) ; RooStats::HistFactory::Measurement::Measurement() : - fPOI( "" ), fLumi( 1.0 ), fLumiRelErr( .10 ), - fBinLow( 0 ), fBinHigh( 1 ), fExportOnly( false ) { ; } + fPOI(), fLumi( 1.0 ), fLumiRelErr( .10 ), + fBinLow( 0 ), fBinHigh( 1 ), fExportOnly( false ) +{ + // standard constructor +} /* RooStats::HistFactory::Measurement::Measurement(const Measurement& other) : @@ -23,16 +52,117 @@ RooStats::HistFactory::Measurement::Measurement(const Measurement& other) : constantParams( other.constantParams ), { ; } */ - - RooStats::HistFactory::Measurement::Measurement(const char* Name, const char* Title) : TNamed( Name, Title ), - fPOI( "" ), fLumi( 1.0 ), fLumiRelErr( .10 ), - fBinLow( 0 ), fBinHigh( 1 ), fExportOnly( false ) { ; } + fPOI(), fLumi( 1.0 ), fLumiRelErr( .10 ), + fBinLow( 0 ), fBinHigh( 1 ), fExportOnly( false ) +{ + // standard constructor specifying name and title of measurement +} + + +void RooStats::HistFactory::Measurement::AddConstantParam( const std::string& param ) +{ + // set a parameter in the model to be constant + // the parameter does not have to exist yet, the information will be used when + // the model is actually created + + // Check if the parameter is already set constant + // We don't need to set it constant twice, + // and we issue a warning in case this is a hint + // of a possible bug + + if( std::find(fConstantParams.begin(), fConstantParams.end(), param) != fConstantParams.end() ) { + std::cout << "Warning: Setting parameter: " << param + << " to constant, but it is already listed as constant. " + << "You may ignore this warning." + << std::endl; + return; + } + + fConstantParams.push_back( param ); + +} + +void RooStats::HistFactory::Measurement::SetParamValue( const std::string& param, double value ) +{ + // set parameter of the model to given value + + // Check if this parameter is already set to a value + // If so, issue a warning + // (Not sure if we want to throw an exception here, or + // issue a warning and move along. Thoughts?) + if( fParamValues.find(param) != fParamValues.end() ) { + std::cout << "Warning: Chainging parameter: " << param + << " value from: " << fParamValues[param] + << " to: " << value + << std::endl; + } + + // Store the parameter and its value + std::cout << "Setting parameter: " << param + << " value to " << value + << std::endl; + + fParamValues[param] = value; + +} + +void RooStats::HistFactory::Measurement::AddPreprocessFunction( std::string name, std::string expression, std::string dependencies ) +{ + // Add a preprocessed function by giving the function a name, + // a functional expression, and a string with a bracketed list of dependencies (eg "SigXsecOverSM[0,3]") + + PreprocessFunction func(name, expression, dependencies); + AddFunctionObject(func); + +} + + +std::vector<std::string> RooStats::HistFactory::Measurement::GetPreprocessFunctions() +{ + // returns a list of defined proprocess function expressions + + std::vector<std::string> PreprocessFunctionExpressions; + for( unsigned int i = 0; i < fFunctionObjects.size(); ++i ) { + std::string expression = fFunctionObjects.at(i).GetCommand(); + PreprocessFunctionExpressions.push_back( expression ); + } + return PreprocessFunctionExpressions; +} + +void RooStats::HistFactory::Measurement::AddGammaSyst(std::string syst, double uncert) +{ + // set constraint term for given systematic to Gamma distribution + + fGammaSyst[syst] = uncert; +} + +void RooStats::HistFactory::Measurement::AddLogNormSyst(std::string syst, double uncert) +{ + // set constraint term for given systematic to LogNormal distribution + + fLogNormSyst[syst] = uncert; +} + +void RooStats::HistFactory::Measurement::AddUniformSyst(std::string syst) +{ + // set constraint term for given systematic to uniform distribution + fUniformSyst[syst] = 1.0; // Is this parameter simply a dummy? +} +void RooStats::HistFactory::Measurement::AddNoSyst(std::string syst) +{ + // define given systematics to have no external constraint + + fNoSyst[syst] = 1.0; // dummy value +} -bool RooStats::HistFactory::Measurement::HasChannel( std::string ChanName ) { + +bool RooStats::HistFactory::Measurement::HasChannel( std::string ChanName ) +{ + // is the given channel part of this measurement for( unsigned int i = 0; i < fChannels.size(); ++i ) { @@ -47,7 +177,10 @@ bool RooStats::HistFactory::Measurement::HasChannel( std::string ChanName ) { } -RooStats::HistFactory::Channel& RooStats::HistFactory::Measurement::GetChannel( std::string ChanName ) { +RooStats::HistFactory::Channel& RooStats::HistFactory::Measurement::GetChannel( std::string ChanName ) +{ + // get channel with given name from this measurement + // throws an exception in case the channel is not found for( unsigned int i = 0; i < fChannels.size(); ++i ) { @@ -62,9 +195,10 @@ RooStats::HistFactory::Channel& RooStats::HistFactory::Measurement::GetChannel( std::cout << "Error: Did not find channel: " << ChanName << " in measurement: " << GetName() << std::endl; - throw bad_hf; + throw hf_exc(); - return RooStats::HistFactory::BadChannel; + // No Need to return after throwing exception + // return RooStats::HistFactory::BadChannel; } @@ -76,12 +210,17 @@ RooStats::HistFactory::Channel& RooStats::HistFactory::Measurement::GetChannel( } */ -void RooStats::HistFactory::Measurement::PrintTree( std::ostream& stream ) { - +void RooStats::HistFactory::Measurement::PrintTree( std::ostream& stream ) +{ + // print information about measurement object in tree-like structure to given stream + stream << "Measurement Name: " << GetName() << "\t OutputFilePrefix: " << fOutputFilePrefix - << "\t POI: " << fPOI - << "\t Lumi: " << fLumi + << "\t POI: "; + for(unsigned int i = 0; i < fPOI.size(); ++i) { + stream << fPOI.at(i); + } + stream << "\t Lumi: " << fLumi << "\t LumiRelErr: " << fLumiRelErr << "\t BinLow: " << fBinLow << "\t BinHigh: " << fBinHigh @@ -97,10 +236,10 @@ void RooStats::HistFactory::Measurement::PrintTree( std::ostream& stream ) { stream << std::endl; } - if( fPreprocessFunctions.size() != 0 ) { + if( fFunctionObjects.size() != 0 ) { stream << "Preprocess Functions: "; - for( unsigned int i = 0; i < fPreprocessFunctions.size(); ++i ) { - stream << " " << fPreprocessFunctions.at(i); + for( unsigned int i = 0; i < fFunctionObjects.size(); ++i ) { + stream << " " << fFunctionObjects.at(i).GetCommand(); } stream << std::endl; } @@ -118,7 +257,10 @@ void RooStats::HistFactory::Measurement::PrintTree( std::ostream& stream ) { -void RooStats::HistFactory::Measurement::PrintXML( std::string Directory, std::string NewOutputPrefix ) { +void RooStats::HistFactory::Measurement::PrintXML( std::string Directory, std::string NewOutputPrefix ) +{ + // create XML files for this measurement in the given directory + // XML files can be configured with a different output prefix // Create an XML file for this measurement // First, create the XML driver @@ -127,9 +269,14 @@ void RooStats::HistFactory::Measurement::PrintXML( std::string Directory, std::s // First, check that the directory exists: // LM : fixes for Windows - gSystem->MakeDirectory(Directory.c_str() ); - //mkdir( Directory.c_str(), 0777 ); - + if( gSystem->OpenDirectory( Directory.c_str() ) == 0 ) { + int success = gSystem->MakeDirectory(Directory.c_str() ); + if( success != 0 ) { + std::cout << "Error: Failed to make directory: " << Directory << std::endl; + throw hf_exc(); + } + } + // If supplied new Prefix, use that one: std::cout << "Printing XML Files for measurement: " << GetName() << std::endl; @@ -141,7 +288,7 @@ void RooStats::HistFactory::Measurement::PrintXML( std::string Directory, std::s if( ! xml.is_open() ) { std::cout << "Error opening xml file: " << XMLName << std::endl; - throw bad_hf; + throw hf_exc(); } @@ -167,7 +314,6 @@ void RooStats::HistFactory::Measurement::PrintXML( std::string Directory, std::s << day << std::endl; - xml << "-->" << std::endl; // Add the doctype @@ -177,12 +323,15 @@ void RooStats::HistFactory::Measurement::PrintXML( std::string Directory, std::s xml << "<Combination OutputFilePrefix=\"" << NewOutputPrefix /*OutputFilePrefix*/ << "\" >" << std::endl << std::endl; // Add the Preprocessed Functions - for( unsigned int i = 0; i < fPreprocessFunctions.size(); ++i ) { + for( unsigned int i = 0; i < fFunctionObjects.size(); ++i ) { RooStats::HistFactory::PreprocessFunction func = fFunctionObjects.at(i); + func.PrintXML(xml); + /* xml << "<Function Name=\"" << func.GetName() << "\" " << "Expression=\"" << func.GetExpression() << "\" " << "Dependents=\"" << func.GetDependents() << "\" " << "/>" << std::endl; + */ } xml << std::endl; @@ -198,21 +347,58 @@ void RooStats::HistFactory::Measurement::PrintXML( std::string Directory, std::s xml << " <Measurement Name=\"" << GetName() << "\" " << "Lumi=\"" << fLumi << "\" " << "LumiRelErr=\"" << fLumiRelErr << "\" " - << "BinLow=\"" << fBinLow << "\" " - << "BinHigh=\"" << fBinHigh << "\" " + //<< "BinLow=\"" << fBinLow << "\" " + // << "BinHigh=\"" << fBinHigh << "\" " << "ExportOnly=\"" << (fExportOnly ? std::string("True") : std::string("False")) << "\" " << " >" << std::endl; // Set the POI - xml << " <POI>" << fPOI << "</POI> " << std::endl; + xml << " <POI>" ; + for(unsigned int i = 0; i < fPOI.size(); ++i) { + if(i==0) xml << fPOI.at(i); + else xml << " " << fPOI.at(i); + } + xml << "</POI> " << std::endl; // Set the Constant Parameters - xml << " <ParamSetting Const=\"True\">"; - for( unsigned int i = 0; i < fConstantParams.size(); ++i ) { - xml << fConstantParams.at(i) << " "; + if(fConstantParams.size()) { + xml << " <ParamSetting Const=\"True\">"; + for( unsigned int i = 0; i < fConstantParams.size(); ++i ) { + if (i==0) xml << fConstantParams.at(i); + else xml << " " << fConstantParams.at(i);; + } + xml << "</ParamSetting>" << std::endl; } - xml << "</ParamSetting>" << std::endl; + + // Set the Parameters with new Constraint Terms + std::map<std::string, double>::iterator ConstrItr; + + // Gamma + for( ConstrItr = fGammaSyst.begin(); ConstrItr != fGammaSyst.end(); ++ConstrItr ) { + xml << "<ConstraintTerm Type=\"Gamma\" RelativeUncertainty=\"" + << ConstrItr->second << "\">" << ConstrItr->first + << "</ConstraintTerm>" << std::endl; + } + // Uniform + for( ConstrItr = fUniformSyst.begin(); ConstrItr != fUniformSyst.end(); ++ConstrItr ) { + xml << "<ConstraintTerm Type=\"Uniform\" RelativeUncertainty=\"" + << ConstrItr->second << "\">" << ConstrItr->first + << "</ConstraintTerm>" << std::endl; + } + // LogNormal + for( ConstrItr = fLogNormSyst.begin(); ConstrItr != fLogNormSyst.end(); ++ConstrItr ) { + xml << "<ConstraintTerm Type=\"LogNormal\" RelativeUncertainty=\"" + << ConstrItr->second << "\">" << ConstrItr->first + << "</ConstraintTerm>" << std::endl; + } + // NoSyst + for( ConstrItr = fNoSyst.begin(); ConstrItr != fNoSyst.end(); ++ConstrItr ) { + xml << "<ConstraintTerm Type=\"NoSyst\" RelativeUncertainty=\"" + << ConstrItr->second << "\">" << ConstrItr->first + << "</ConstraintTerm>" << std::endl; + } + // Close the Measurement xml << " </Measurement> " << std::endl << std::endl; @@ -238,12 +424,16 @@ void RooStats::HistFactory::Measurement::PrintXML( std::string Directory, std::s -void RooStats::HistFactory::Measurement::writeToFile( TFile* file ) { - +void RooStats::HistFactory::Measurement::writeToFile( TFile* file ) +{ + // A measurement, once fully configured, can be saved into a ROOT + // file. This will persitify the Measurement object, along with any + // channels and samples that have been added to it. It can then be + // loaded, potentially modified, and used to create new models. + // Write every histogram to the file. // Edit the measurement to point to this file // and to point to each histogram in this file - // Then write the measurement itself. // Create a tempory measurement @@ -271,7 +461,7 @@ void RooStats::HistFactory::Measurement::writeToFile( TFile* file ) { if( ! channel.CheckHistograms() ) { std::cout << "Measurement.writeToFile(): Channel: " << chanName << " has uninitialized histogram pointers" << std::endl; - throw bad_hf; + throw hf_exc(); return; } @@ -284,11 +474,19 @@ void RooStats::HistFactory::Measurement::writeToFile( TFile* file ) { // for this channel TDirectory* chanDir = file->mkdir( (chanName + "_hists").c_str() ); + if( chanDir == NULL ) { + std::cout << "Error: Cannot create channel " << (chanName + "_hists") + << std::endl; + throw hf_exc(); + } chanDir->cd(); // Save the data: - TDirectory* dataDir = chanDir->mkdir( "data" ); + if( dataDir == NULL ) { + std::cout << "Error: Cannot make directory " << chanDir << std::endl; + throw hf_exc(); + } dataDir->cd(); channel.fData.writeToFile( OutputFileName, GetDirPath(dataDir) ); @@ -318,13 +516,17 @@ void RooStats::HistFactory::Measurement::writeToFile( TFile* file ) { file->cd(); chanDir->cd(); TDirectory* sampleDir = chanDir->mkdir( sampName.c_str() ); + if( sampleDir == NULL ) { + std::cout << "Error: Directory " << sampName << " not created properly" << std::endl; + throw hf_exc(); + } std::string sampleDirPath = GetDirPath( sampleDir ); if( ! sampleDir ) { std::cout << "Error making directory: " << sampName << " in directory: " << chanName << std::endl; - throw bad_hf; + throw hf_exc(); } // Write the data file to this directory @@ -348,6 +550,8 @@ void RooStats::HistFactory::Measurement::writeToFile( TFile* file ) { // Write the histograms associated with // systematics + + /* THIS IS WHAT I"M COMMENTING sample.GetStatError().writeToFile( OutputFileName, sampleDirPath ); // Must write all systematics that contain internal histograms @@ -362,7 +566,7 @@ void RooStats::HistFactory::Measurement::writeToFile( TFile* file ) { for( unsigned int i = 0; i < sample.GetShapeSysList().size(); ++i ) { sample.GetShapeSysList().at(i).writeToFile( OutputFileName, sampleDirPath ); } - + END COMMENT */ /* sample.statError.writeToFile( OutputFileName, sampleDirPath ); @@ -400,8 +604,8 @@ void RooStats::HistFactory::Measurement::writeToFile( TFile* file ) { } -std::string RooStats::HistFactory::Measurement::GetDirPath( TDirectory* dir ) { - +std::string RooStats::HistFactory::Measurement::GetDirPath( TDirectory* dir ) +{ // Return the directory's path, // stripped of unnecessary prefixes @@ -429,7 +633,16 @@ std::string RooStats::HistFactory::Measurement::GetDirPath( TDirectory* dir ) { -void RooStats::HistFactory::Measurement::CollectHistograms() { +void RooStats::HistFactory::Measurement::CollectHistograms() +{ + // The most common way to add histograms to channels is to have them + // stored in ROOT files and to give HistFactory the location of these + // files. This means providing the path to the ROOT file and the path + // and name of the histogram within that file. When providing these + // in a script, HistFactory doesn't load the histogram from the file + // right away. Instead, once all such histograms have been supplied, + // one should run this method to open all ROOT files and to copy and + // save all necessary histograms. for( unsigned int chanItr = 0; chanItr < fChannels.size(); ++chanItr) { diff --git a/roofit/histfactory/src/ParamHistFunc.cxx b/roofit/histfactory/src/ParamHistFunc.cxx index 3246da8d3cb5b..94578689ae14f 100755 --- a/roofit/histfactory/src/ParamHistFunc.cxx +++ b/roofit/histfactory/src/ParamHistFunc.cxx @@ -1,22 +1,33 @@ -/***************************************************************************** - - *****************************************************************************/ - -////////////////////////////////////////////////////////////////////////////// -// -// BEGIN_HTML -// ParamHistFunc -// END_HTML +// @(#)root/roostats:$Id: cranmer $ +// Author: Kyle Cranmer, George Lewis +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +//_________________________________________________ +/* +BEGIN_HTML +<p> +</p> +END_HTML +*/ // #include <sstream> +#include <math.h> +#include <stdexcept> + #include "TMath.h" #include "TH1.h" #include "Riostream.h" #include "Riostream.h" -#include <math.h> + #include "RooFit.h" #include "RooStats/HistFactory/ParamHistFunc.h" @@ -40,11 +51,40 @@ #include "RooWorkspace.h" #include "RooBinning.h" +//using namespace std; + ClassImp(ParamHistFunc); +/* + + A class which maps the current values of a RooRealVar + (or a set of RooRealVars) to one of a number of RooRealVars: + + ParamHistFunc: {val1, val2, ...} -> {gamma (RooRealVar)} + + The intended interpretation is that each parameter in the + range represent the height of a bin over the domain + space. + + The 'createParamSet' is an easy way to create these + parameters from a set of observables. They are + stored using the "TH1" ordering convention (as compared + to the RooDataHist convention, which is used internally + and one must map between the two). + + All indices include '0' + + gamma_i_j = paramSet[ size(i)*j + i ] + + ie assuming the dimensions are 5*5: + gamma_2_1 = paramSet[ 5*1 + 2 ] = paramSet[7] + + */ + + //_____________________________________________________________________________ -ParamHistFunc::ParamHistFunc() +ParamHistFunc::ParamHistFunc() : _numBins(0) { ; } @@ -55,9 +95,9 @@ ParamHistFunc::ParamHistFunc(const char* name, const char* title, const RooArgList& vars, const RooArgList& paramSet) : RooAbsReal(name, title), _dataVars("!dataVars","data Vars", this), - _paramSet("!paramSet","bin paramaters", this), + _paramSet("!paramSet","bin parameters", this), _numBins(0), - _dataSet( (string(name)+"_dataSet").c_str(), "", vars) + _dataSet( (std::string(name)+"_dataSet").c_str(), "", vars) { // Create a function which returns binewise-values @@ -79,13 +119,13 @@ ParamHistFunc::ParamHistFunc(const char* name, const char* title, // Set the binning // //_binning = var.getBinning().clone() ; - // Create the set of paramaters + // Create the set of parameters // controlling the height of each bin // Get the number of bins _numBins = GetNumBins( vars ); - // Add the paramaters (with checking) + // Add the parameters (with checking) addVarSet( vars ); addParamSet( paramSet ); @@ -100,9 +140,9 @@ ParamHistFunc::ParamHistFunc(const char* name, const char* title, RooAbsReal(name, title), // _dataVar("!dataVar","data Var", this, (RooRealVar&) var), _dataVars("!dataVars","data Vars", this), - _paramSet("!paramSet","bin paramaters", this), + _paramSet("!paramSet","bin parameters", this), _numBins(0), - _dataSet( (string(name)+"_dataSet").c_str(), "", vars, Hist) + _dataSet( (std::string(name)+"_dataSet").c_str(), "", vars, Hist) { // Create a function which returns binewise-values @@ -120,7 +160,7 @@ ParamHistFunc::ParamHistFunc(const char* name, const char* title, // Get the number of bins _numBins = GetNumBins( vars ); - // Add the paramaters (with checking) + // Add the parameters (with checking) addVarSet( vars ); addParamSet( paramSet ); @@ -129,7 +169,6 @@ ParamHistFunc::ParamHistFunc(const char* name, const char* title, Int_t ParamHistFunc::GetNumBins( const RooArgSet& vars ) { - // A helper method to get the number of bins if( vars.getSize() == 0 ) return 0; @@ -140,7 +179,8 @@ Int_t ParamHistFunc::GetNumBins( const RooArgSet& vars ) { RooAbsArg* comp ; while((comp = (RooAbsArg*) varIter.next())) { if (!dynamic_cast<RooRealVar*>(comp)) { - cout << "ParamHistFunc::GetNumBins" << vars.GetName() << ") ERROR: component " << comp->GetName() + std::cout << "ParamHistFunc::GetNumBins" << vars.GetName() << ") ERROR: component " + << comp->GetName() << " in vars list is not of type RooRealVar" << std::endl ; RooErrorHandler::softAbort() ; return -1; @@ -183,33 +223,26 @@ Int_t ParamHistFunc::getCurrentBin() const { // Get the index of the gamma parameter associated // with the current bin + // This number is the "RooDataSet" style index + // and it must be because it uses the RooDataSet method directly + // This is intended to be fed into the getParameter(Int_t) method: + // + // RooRealVar currentParam = getParameter( getCurrentBin() ); Int_t dataSetIndex = _dataSet.getIndex( _dataVars ); // calcTreeIndex(); - return dataSetIndex; - /* - Int_t currentIndex = -1; - if( _binMap.find( dataSetIndex ) != _binMap.end() ) { - currentIndex = _binMap[ dataSetIndex ]; - } - else { - std::cout << "Error: ParamHistFunc internal bin index map " - << "not properly configured" << std::endl; - throw -1; - return -1; - } - - return currentIndex; - */ - } + //_____________________________________________________________________________ RooRealVar& ParamHistFunc::getParameter( Int_t index ) const { // Get the parameter associate with the the // input RooDataHist style index + // It uses the binMap to convert the RooDataSet style index + // into the TH1 style index (which is how they are stored + // internally in the '_paramSet' vector Int_t gammaIndex = -1; if( _binMap.find( index ) != _binMap.end() ) { @@ -224,44 +257,86 @@ RooRealVar& ParamHistFunc::getParameter( Int_t index ) const { return (RooRealVar&) _paramSet[gammaIndex]; } + //_____________________________________________________________________________ RooRealVar& ParamHistFunc::getParameter() const { Int_t index = getCurrentBin(); return getParameter( index ); } -void ParamHistFunc::setParamConst( Int_t index, Bool_t varConst ) { +void ParamHistFunc::setParamConst( Int_t index, Bool_t varConst ) { RooRealVar& var = getParameter( index ); var.setConstant( varConst ); } +void ParamHistFunc::setConstant( bool constant ) { + for( int i=0; i < numBins(); ++i) { + setParamConst(i, constant); + } +} + //_____________________________________________________________________________ -RooArgList ParamHistFunc::createParamSet(RooWorkspace& w, const std::string& Prefix, const RooArgList& vars) { +void ParamHistFunc::setShape( TH1* shape ) { + + int num_hist_bins = shape->GetNbinsX()*shape->GetNbinsY()*shape->GetNbinsZ(); + + if( num_hist_bins != numBins() ) { + std::cout << "Error - ParamHistFunc: cannot set Shape of ParamHistFunc: " << GetName() + << " using histogram: " << shape->GetName() + << ". Bins don't match" << std::endl; + throw std::runtime_error("setShape"); + } + + + Int_t TH1BinNumber = 0; + for( Int_t i = 0; i < numBins(); ++i) { + + TH1BinNumber++; + + while( shape->IsBinUnderflow(TH1BinNumber) || shape->IsBinOverflow(TH1BinNumber) ){ + TH1BinNumber++; + } + + //RooRealVar& var = dynamic_cast<RooRealVar&>(getParameter(i)); + RooRealVar& var = dynamic_cast<RooRealVar&>(_paramSet[i]); + var.setVal( shape->GetBinContent(TH1BinNumber) ); + } + +} + + +//_____________________________________________________________________________ +RooArgList ParamHistFunc::createParamSet(RooWorkspace& w, const std::string& Prefix, + const RooArgList& vars) { // Create the list of RooRealVar // parameters which represent the // height of the histogram bins. - // Store them in a list + // The list 'vars' represents the + // observables (corresponding to histogram bins) + // that these newly created parameters will + // be mapped to. (ie, we create one parameter + // per observable in vars and per bin in each observable) + // Store them in a list using: // _paramSet.add( createParamSet() ); + // This list is stored in the "TH1" index order // Get the number of bins // in the nominal histogram - RooArgList paramSet; Int_t numVars = vars.getSize(); Int_t numBins = GetNumBins( vars ); - if( numVars == 0 ) { - cout << "Warning - ParamHistFunc::createParamSet() :" + std::cout << "Warning - ParamHistFunc::createParamSet() :" << " No Variables provided. Not making constraint terms." - << endl; + << std::endl; return paramSet; } @@ -274,8 +349,6 @@ RooArgList ParamHistFunc::createParamSet(RooWorkspace& w, const std::string& Pre VarNameStream << Prefix << "_bin_" << i; std::string VarName = VarNameStream.str(); - - RooRealVar gamma( VarName.c_str(), VarName.c_str(), 1.0 ); // "Hard-Code" a minimum of 0.0 gamma.setMin( 0.0 ); @@ -289,7 +362,6 @@ RooArgList ParamHistFunc::createParamSet(RooWorkspace& w, const std::string& Pre } } - else if( numVars == 2 ) { // Create a vector of indices @@ -363,60 +435,8 @@ RooArgList ParamHistFunc::createParamSet(RooWorkspace& w, const std::string& Pre } } - - else { - - cout << " Error: ParamHistFunc doesn't support dimensions > 3D " << endl; - - /* - // Create a vector of indices - // all starting at 0 - std::vector< Int_t > Indices(numVars, 0); - - // Loop over vars: - RooFIter varIter = vars.fwdIterator() ; - Int_t VarIndex = 0; - RooAbsArg* comp ; - while((comp = (RooAbsArg*) varIter.next())) { - - RooRealVar* var = (RooRealVar*) comp; - - // For each bin, create a RooRealVar - for( Int_t i = 0; i < var->numBins(); ++i) { - - if( i != 0 ) Indices.at(VarIndex)++; - - // Make the name of the var: - // Varname_bin_0_2_1 where x=0, y=2, z=1 (etc) - std::stringstream VarNameStream; - VarNameStream << Prefix << "_bin"; - for(Int_t j = 0; j < numVars; ++j) { - VarNameStream << "_" << Indices.at(j);; - } - std::string VarName = VarNameStream.str(); - - RooRealVar gamma( VarName.c_str(), VarName.c_str(), 1.0 ); - // "Hard-Code" a minimum of 0.0 - gamma.setMin( 0.0 ); - gamma.setConstant( false ); - - w.import( gamma, RooFit::RecycleConflictNodes() ); - RooRealVar* gamma_wspace = (RooRealVar*) w.var( VarName.c_str() ); - - paramSet.add( *gamma_wspace ); - - // Increase the bin index on this var - // (Used in naming) - - } - - // Increase the Int_t iterator - // over variables - VarIndex++; - - } - */ + std::cout << " Error: ParamHistFunc doesn't support dimensions > 3D " << std::endl; } return paramSet; @@ -425,87 +445,48 @@ RooArgList ParamHistFunc::createParamSet(RooWorkspace& w, const std::string& Pre //_____________________________________________________________________________ -RooArgList ParamHistFunc::createParamSet(RooWorkspace& w, const std::string& Prefix, const RooArgList& vars, +RooArgList ParamHistFunc::createParamSet(RooWorkspace& w, const std::string& Prefix, + const RooArgList& vars, Double_t gamma_min, Double_t gamma_max) { - - RooArgList params = ParamHistFunc::createParamSet( w, Prefix, vars ); - - RooFIter paramIter = params.fwdIterator() ; - RooAbsArg* comp ; - while((comp = (RooAbsArg*) paramIter.next())) { - - RooRealVar* var = (RooRealVar*) comp; - - var->setMin( gamma_min ); - var->setMax( gamma_max ); - } - - return params; - - /* - // Create the list of RooRealVar // parameters which represent the // height of the histogram bins. - // Store them in a list + // The list 'vars' represents the + // observables (corresponding to histogram bins) + // that these newly created parameters will + // be mapped to. (ie, we create one parameter + // per observable in vars and per bin in each observable) + // Store them in a list using: // _paramSet.add( createParamSet() ); + // This list is stored in the "TH1" index order // Get the number of bins // in the nominal histogram - - - RooArgList paramSet; - - if( gamma_max <= gamma_min ) { - std::cout << "Warming: gamma_min <= gamma_max: Using default values (0, 10)" << std::endl; + // We also set the parameters to have nominal min and max values - gamma_min = 0.0; - gamma_max = 10.0; - - } - - Double_t gamma_nominal = 1.0; - - if( gamma_nominal < gamma_min ) { - gamma_nominal = gamma_min; - } - - if( gamma_nominal > gamma_max ) { - gamma_nominal = gamma_max; - } - - - // For each bin, create a RooRealVar - for( Int_t i = 0; i < numBins; ++i) { - - std::stringstream VarNameStream; - VarNameStream << Prefix << "_bin_" << i; - std::string VarName = VarNameStream.str(); - - RooRealVar gamma( VarName.c_str(), VarName.c_str(), - gamma_nominal, gamma_min, gamma_max ); - gamma.setConstant( false ); - - w.import( gamma, RooFit::RecycleConflictNodes() ); - RooRealVar* gamma_wspace = (RooRealVar*) w.var( VarName.c_str() ); + RooArgList params = ParamHistFunc::createParamSet( w, Prefix, vars ); - paramSet.add( *gamma_wspace ); + RooFIter paramIter = params.fwdIterator() ; + RooAbsArg* comp ; + while((comp = (RooAbsArg*) paramIter.next())) { + + RooRealVar* var = (RooRealVar*) comp; + var->setMin( gamma_min ); + var->setMax( gamma_max ); } - - return paramSet; - */ + return params; } - //_____________________________________________________________________________ -RooArgList ParamHistFunc::createParamSet(const std::string& Prefix, Int_t numBins, Double_t gamma_min, Double_t gamma_max) { +RooArgList ParamHistFunc::createParamSet(const std::string& Prefix, Int_t numBins, + Double_t gamma_min, Double_t gamma_max) { // Create the list of RooRealVar // parameters which represent the @@ -516,7 +497,6 @@ RooArgList ParamHistFunc::createParamSet(const std::string& Prefix, Int_t numBin // Get the number of bins // in the nominal histogram - RooArgList paramSet; @@ -539,7 +519,6 @@ RooArgList ParamHistFunc::createParamSet(const std::string& Prefix, Int_t numBin gamma_nominal = gamma_max; } - // For each bin, create a RooRealVar for( Int_t i = 0; i < numBins; ++i) { @@ -554,11 +533,11 @@ RooArgList ParamHistFunc::createParamSet(const std::string& Prefix, Int_t numBin } - return paramSet; } + //_____________________________________________________________________________ Int_t ParamHistFunc::addVarSet( const RooArgList& vars ) { @@ -576,8 +555,9 @@ Int_t ParamHistFunc::addVarSet( const RooArgList& vars ) { RooAbsArg* comp ; while((comp = (RooAbsArg*) varIter.next())) { if (!dynamic_cast<RooRealVar*>(comp)) { - coutE(InputArguments) << "ParamHistFunc::(" << GetName() << ") ERROR: component " << comp->GetName() - << " in variables list is not of type RooRealVar" << std::endl ; + coutE(InputArguments) << "ParamHistFunc::(" << GetName() << ") ERROR: component " + << comp->GetName() << " in variables list is not of type RooRealVar" + << std::endl; RooErrorHandler::softAbort() ; return 1; } @@ -587,7 +567,6 @@ Int_t ParamHistFunc::addVarSet( const RooArgList& vars ) { } - Int_t numBinsX = 1; Int_t numBinsY = 1; Int_t numBinsZ = 1; @@ -634,12 +613,12 @@ Int_t ParamHistFunc::addVarSet( const RooArgList& vars ) { } } } - return 0; } + //_____________________________________________________________________________ Int_t ParamHistFunc::addParamSet( const RooArgList& params ) { @@ -654,7 +633,7 @@ Int_t ParamHistFunc::addParamSet( const RooArgList& params ) { if( numVarBins != numElements ) { std::cout << "ParamHistFunc::addParamSet - ERROR - " - << "Supplied list of paramaters " << params.GetName() + << "Supplied list of parameters " << params.GetName() << " has " << numElements << " elements but the ParamHistFunc" << GetName() << " has " << numVarBins << " bins." << std::endl; @@ -671,8 +650,9 @@ Int_t ParamHistFunc::addParamSet( const RooArgList& params ) { RooAbsArg* comp ; while((comp = (RooAbsArg*) paramIter.next())) { if (!dynamic_cast<RooRealVar*>(comp)) { - coutE(InputArguments) << "ParamHistFunc::(" << GetName() << ") ERROR: component " << comp->GetName() - << " in paramater list is not of type RooRealVar" << std::endl ; + coutE(InputArguments) << "ParamHistFunc::(" << GetName() << ") ERROR: component " + << comp->GetName() << " in paramater list is not of type RooRealVar" + << std::endl; RooErrorHandler::softAbort() ; return 1; } @@ -693,22 +673,8 @@ Double_t ParamHistFunc::evaluate() const // Find the bin cooresponding to the current // value of the RooRealVar: - /* - Int_t currentBin = getCurrentBin(); - RooRealVar* param = (RooRealVar*) &(_paramSet[currentBin]); - */ - RooRealVar* param = (RooRealVar*) &(getParameter()); - Double_t value = param->getVal(); - - /* - cout << "ParamHistFunc - Current Bin: " << currentBin - << " param pointer: " << param - << " param val: " << paramVal - << " val: " << value - << endl; - */ return value; } @@ -716,7 +682,8 @@ Double_t ParamHistFunc::evaluate() const //_____________________________________________________________________________ Int_t ParamHistFunc::getAnalyticalIntegralWN(RooArgSet& allVars, RooArgSet& analVars, - const RooArgSet* normSet, const char* /*rangeName*/) const + const RooArgSet* normSet, + const char* /*rangeName*/) const { // Advertise that all integrals can be handled internally. @@ -727,10 +694,6 @@ Int_t ParamHistFunc::getAnalyticalIntegralWN(RooArgSet& allVars, RooArgSet& anal // Select subset of allVars that are actual dependents analVars.add(allVars) ; - // RooArgSet* normSet = normSet2 ? getObservables(normSet2) : 0 ; - // RooArgSet* normSet = getObservables(); - // RooArgSet* normSet = 0; - // Check if this configuration was created before Int_t sterileIdx(-1) ; @@ -747,49 +710,12 @@ Int_t ParamHistFunc::getAnalyticalIntegralWN(RooArgSet& allVars, RooArgSet& anal return code+1 ; - - // Make list of function projection and normalization integrals - // RooAbsReal* param ; - // RooAbsReal *func ; - // const RooArgSet* nset = _paramList.nset() ; - - // do nominal - /* - func = (RooAbsReal*) &( _dataVar.arg() ); - RooAbsReal* funcInt = func->createIntegral(analVars) ; - cache->_funcIntList.addOwned(*funcInt) ; - - - // Implement integration here - - // do variations - //_lowIter->Reset() ; - //_highIter->Reset() ; - _paramIter->Reset() ; - int i=0; - while((param=(RooAbsReal*)_paramIter->Next())) { - - / * - func = (RooAbsReal*)_lowIter->Next() ; - funcInt = func->createIntegral(analVars) ; - cache->_lowIntList.addOwned(*funcInt) ; - - func = (RooAbsReal*)_highIter->Next() ; - funcInt = func->createIntegral(analVars) ; - cache->_highIntList.addOwned(*funcInt) ; - * / - ++i; - - } -*/ - } - - //_____________________________________________________________________________ -Double_t ParamHistFunc::analyticalIntegralWN(Int_t /*code*/, const RooArgSet* /*normSet2*/,const char* /*rangeName*/) const +Double_t ParamHistFunc::analyticalIntegralWN(Int_t /*code*/, const RooArgSet* /*normSet2*/, + const char* /*rangeName*/) const { // Implement analytical integrations by doing appropriate weighting from component integrals // functions to integrators of components @@ -810,17 +736,17 @@ Double_t ParamHistFunc::analyticalIntegralWN(Int_t /*code*/, const RooArgSet* /* // Get the bin volume _dataSet.get( nominalItr ); - Double_t binVolume = _dataSet.binVolume(); //_binning->binWidth( nominalItr ); + Double_t binVolumeDS = _dataSet.binVolume(); //_binning->binWidth( nominalItr ); // Finally, get the subtotal - value += paramVal*binVolume; + value += paramVal*binVolumeDS; ++nominalItr; /* std::cout << "Integrating : " << " bin: " << nomValue - << " binVolume: " << binVolume + << " binVolume: " << binVolumeDS << " paramValue: " << paramVal << " nomValue: " << nomValue << " subTotal: " << value @@ -836,7 +762,8 @@ Double_t ParamHistFunc::analyticalIntegralWN(Int_t /*code*/, const RooArgSet* /* //_____________________________________________________________________________ -list<Double_t>* ParamHistFunc::plotSamplingHint(RooAbsRealLValue& obs, Double_t xlo, Double_t xhi) const +std::list<Double_t>* ParamHistFunc::plotSamplingHint(RooAbsRealLValue& /*obs*/, Double_t /*xlo*/, + Double_t /*xhi*/) const { // Return sampling hint for making curves of (projections) of this function // as the recursive division strategy of RooCurve cannot deal efficiently @@ -844,6 +771,7 @@ list<Double_t>* ParamHistFunc::plotSamplingHint(RooAbsRealLValue& obs, Double_t return 0; + /* // copied and edited from RooHistFunc RooAbsLValue* lvarg = &obs; @@ -869,11 +797,13 @@ list<Double_t>* ParamHistFunc::plotSamplingHint(RooAbsRealLValue& obs, Double_t } return hint ; + */ } //______________________________________________________________________________ -std::list<Double_t>* ParamHistFunc::binBoundaries(RooAbsRealLValue& obs, Double_t xlo, Double_t xhi) const +std::list<Double_t>* ParamHistFunc::binBoundaries(RooAbsRealLValue& /*obs*/, Double_t /*xlo*/, + Double_t /*xhi*/) const { // Return sampling hint for making curves of (projections) of this function // as the recursive division strategy of RooCurve cannot deal efficiently @@ -881,6 +811,7 @@ std::list<Double_t>* ParamHistFunc::binBoundaries(RooAbsRealLValue& obs, Double_ return 0; + /* // copied and edited from RooHistFunc RooAbsLValue* lvarg = &obs; @@ -899,4 +830,5 @@ std::list<Double_t>* ParamHistFunc::binBoundaries(RooAbsRealLValue& obs, Double_ } return hint ; + */ } diff --git a/roofit/histfactory/src/PiecewiseInterpolation.cxx b/roofit/histfactory/src/PiecewiseInterpolation.cxx index 528dae718a5a9..c3c6660a08cc2 100644 --- a/roofit/histfactory/src/PiecewiseInterpolation.cxx +++ b/roofit/histfactory/src/PiecewiseInterpolation.cxx @@ -9,7 +9,7 @@ // END_HTML // - +#include <exception> #include "RooFit.h" #include "Riostream.h" @@ -27,6 +27,8 @@ #include "RooMsgService.h" #include "RooNumIntConfig.h" +using namespace std; + ClassImp(PiecewiseInterpolation) ; @@ -153,7 +155,6 @@ Double_t PiecewiseInterpolation::evaluate() const RooAbsReal* param ; RooAbsReal* high ; RooAbsReal* low ; - // const RooArgSet* nset = _paramList.nset() ; int i=0; RooFIter lowIter(_lowSet.fwdIterator()) ; @@ -164,26 +165,26 @@ Double_t PiecewiseInterpolation::evaluate() const low = (RooAbsReal*)lowIter.next() ; high = (RooAbsReal*)highIter.next() ; - /* // MB : old bit of interpolation code - if(param->getVal()>0) - sum += param->getVal()*(high->getVal() - nominal ); - else - sum += param->getVal()*(nominal - low->getVal()); - */ - //cout << "interp code is " << _interpCode.at(i) << endl; - if(_interpCode.empty() || _interpCode.at(i)==0){ + Int_t icode = _interpCode[i] ; + + switch(icode) { + case 0: { // piece-wise linear if(param->getVal()>0) sum += param->getVal()*(high->getVal() - nominal ); else sum += param->getVal()*(nominal - low->getVal()); - } else if(_interpCode.at(i)==1){ + break ; + } + case 1: { // pice-wise log if(param->getVal()>=0) sum *= pow(high->getVal()/nominal, +param->getVal()); else sum *= pow(low->getVal()/nominal, -param->getVal()); - } else if(_interpCode.at(i)==2){ + break ; + } + case 2: { // parabolic with linear double a = 0.5*(high->getVal()+low->getVal())-nominal; double b = 0.5*(high->getVal()-low->getVal()); @@ -195,7 +196,9 @@ Double_t PiecewiseInterpolation::evaluate() const } else { sum += a*pow(param->getVal(),2) + b*param->getVal()+c; } - } else if(_interpCode.at(i)==3){ + break ; + } + case 3: { //parabolic version of log-normal double a = 0.5*(high->getVal()+low->getVal())-nominal; double b = 0.5*(high->getVal()-low->getVal()); @@ -207,41 +210,38 @@ Double_t PiecewiseInterpolation::evaluate() const } else { sum += a*pow(param->getVal(),2) + b*param->getVal()+c; } - - } else if (_interpCode.at(i) == 4){ // AA - 6th order poly interp + linear extrap + break ; + } + case 4: { - double x0 = 1.0;//boundary; - double x = param->getVal(); - - if (x > x0 || x < -x0) - { - if(x>0) - sum += x*(high->getVal() - nominal ); - else - sum += x*(nominal - low->getVal()); - } - else - { + // WVE **************************************************************** + // WVE *** THIS CODE IS CRITICAL TO HISTFACTORY FIT CPU PERFORMANCE *** + // WVE *** Do not modify unless you know what you are doing... *** + // WVE **************************************************************** + + double x = param->getVal(); + if (x>1) { + sum += x*(high->getVal() - nominal ); + } else if (x<-1) { + sum += x*(nominal - low->getVal()); + } else { double eps_plus = high->getVal() - nominal; double eps_minus = nominal - low->getVal(); double S = (eps_plus + eps_minus)/2; - double A = (eps_plus - eps_minus)/2; - -//fcns+der+2nd_der are eq at bd - double a = S; - double b = 15*A/(8*x0); - //double c = 0; - double d = -10*A/(8*x0*x0*x0); - //double e = 0; - double f = 3*A/(8*x0*x0*x0*x0*x0); - - double val = nominal + a*x + b*pow(x, 2) + 0/*c*pow(x, 3)*/ + d*pow(x, 4) + 0/*e*pow(x, 5)*/ + f*pow(x, 6); + double A = (eps_plus - eps_minus)/16; + + //fcns+der+2nd_der are eq at bd + double xx = x*x ; + double xxxx = xx*xx ; + double val = nominal + S*x + A*(15*xx - 10*xxxx + 3*xxxx*xx); if (val < 0) val = 0; - //cout << "Using interp code 4, val = " << val << endl; sum += val-nominal; } - - } else if (_interpCode.at(i) == 5){ // AA - 4th order poly interp + linear extrap + break ; + + // WVE **************************************************************** + } + case 5: { double x0 = 1.0;//boundary; double x = param->getVal(); @@ -260,7 +260,7 @@ Double_t PiecewiseInterpolation::evaluate() const double S = (eps_plus + eps_minus)/2; double A = (eps_plus - eps_minus)/2; -//fcns+der are eq at bd + //fcns+der are eq at bd double a = S; double b = 3*A/(2*x0); //double c = 0; @@ -273,16 +273,17 @@ Double_t PiecewiseInterpolation::evaluate() const sum += val-nominal; } - - - } else { + break ; + } + default: { coutE(InputArguments) << "PiecewiseInterpolation::evaluate ERROR: " << param->GetName() - << " with unknown interpolation code" << endl ; + << " with unknown interpolation code" << icode << endl ; + break ; + } } - ++i; } - + if(_positiveDefinite && (sum<0)){ sum = 1e-6; sum = 0; @@ -297,7 +298,6 @@ Double_t PiecewiseInterpolation::evaluate() const } - //_____________________________________________________________________________ Bool_t PiecewiseInterpolation::setBinIntegrator(RooArgSet& allVars) { @@ -347,7 +347,7 @@ Int_t PiecewiseInterpolation::getAnalyticalIntegralWN(RooArgSet& allVars, RooArg RooFIter paramIterExtra(_paramSet.fwdIterator()) ; int i=0; while( paramIterExtra.next() ) { - if(!_interpCode.empty() && _interpCode.at(i)!=0){ + if(!_interpCode.empty() && _interpCode[i]!=0){ // can't factorize integral cout <<"can't factorize integral"<<endl; return 0; @@ -485,6 +485,10 @@ Double_t PiecewiseInterpolation::analyticalIntegralWN(Int_t code, const RooArgSe // old integral, only works for linear and not positive definite CacheElem* cache = (CacheElem*) _normIntMgr.getObjByIndex(code-1) ; + if( cache==NULL ) { + std::cout << "Error: Cache Element is NULL" << std::endl; + throw std::exception(); + } // old integral, only works for linear and not positive definite RooFIter funcIntIter = cache->_funcIntList.fwdIterator() ; @@ -653,6 +657,7 @@ void PiecewiseInterpolation::Streamer(TBuffer &R__b) if (R__b.IsReading()) { R__b.ReadClassBuffer(PiecewiseInterpolation::Class(),this); specialIntegratorConfig(kTRUE)->method1D().setLabel("RooBinIntegrator") ; + if (_interpCode.empty()) _interpCode.resize(_paramSet.getSize()); } else { R__b.WriteClassBuffer(PiecewiseInterpolation::Class(),this); } diff --git a/roofit/histfactory/src/PreprocessFunction.cxx b/roofit/histfactory/src/PreprocessFunction.cxx index 354d711efe758..03282934006d4 100644 --- a/roofit/histfactory/src/PreprocessFunction.cxx +++ b/roofit/histfactory/src/PreprocessFunction.cxx @@ -1,9 +1,37 @@ +// @(#)root/roostats:$Id$ +// Author: Kyle Cranmer, George Lewis +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +//_________________________________________________ +/* +BEGIN_HTML +<p> +</p> +END_HTML +*/ +// #include "RooStats/HistFactory/PreprocessFunction.h" RooStats::HistFactory::PreprocessFunction::PreprocessFunction() {;} +RooStats::HistFactory::PreprocessFunction::PreprocessFunction(std::string Name, std::string Expression, std::string Dependents) : + fName(Name), fExpression(Expression), fDependents(Dependents) { + fCommand = GetCommand(Name, Expression, Dependents); +} + +std::string RooStats::HistFactory::PreprocessFunction::GetCommand(std::string Name, std::string Expression, std::string Dependents) { + std::string command = "expr::"+Name+"('"+Expression+"',{"+Dependents+"})"; + return command; +} + void RooStats::HistFactory::PreprocessFunction::Print( std::ostream& stream ) { @@ -13,3 +41,10 @@ void RooStats::HistFactory::PreprocessFunction::Print( std::ostream& stream ) { << std::endl; } + +void RooStats::HistFactory::PreprocessFunction::PrintXML( std::ostream& xml ) { + xml << "<Function Name=\"" << GetName() << "\" " + << "Expression=\"" << GetExpression() << "\" " + << "Dependents=\"" << GetDependents() << "\" " + << "/>" << std::endl; +} diff --git a/roofit/histfactory/src/RooBarlowBeestonLL.cxx b/roofit/histfactory/src/RooBarlowBeestonLL.cxx new file mode 100644 index 0000000000000..637bc6841389b --- /dev/null +++ b/roofit/histfactory/src/RooBarlowBeestonLL.cxx @@ -0,0 +1,755 @@ +// @(#)root/roostats:$Id$ +// Author: Kyle Cranmer, George Lewis +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////////// +// +// BEGIN_HTML +// Class RooBarlowBeestonLL implements the profile likelihood estimator for +// a given likelihood and set of parameters of interest. The value return by +// RooBarlowBeestonLL is the input likelihood nll minimized w.r.t all nuisance parameters +// (which are all parameters except for those listed in the constructor) minus +// the -log(L) of the best fit. Note that this function is slow to evaluate +// as a MIGRAD minimization step is executed for each function evaluation +// END_HTML +// + +#include <stdexcept> +#include <math.h> + +#include "Riostream.h" + +#include "RooFit.h" +#include "RooStats/HistFactory/RooBarlowBeestonLL.h" +#include "RooAbsReal.h" +#include "RooAbsData.h" +//#include "RooMinuit.h" +#include "RooMsgService.h" +#include "RooRealVar.h" +#include "RooMsgService.h" +#include "RooNLLVar.h" + +#include "RooStats/RooStatsUtils.h" +#include "RooProdPdf.h" +#include "RooCategory.h" +#include "RooSimultaneous.h" +#include "RooArgList.h" +#include "RooAbsCategoryLValue.h" + +#include "RooStats/HistFactory/ParamHistFunc.h" +#include "RooStats/HistFactory/HistFactoryModelUtils.h" + +using namespace std ; + +ClassImp(RooStats::HistFactory::RooBarlowBeestonLL) + + +//_____________________________________________________________________________ + RooStats::HistFactory::RooBarlowBeestonLL::RooBarlowBeestonLL() : + RooAbsReal("RooBarlowBeestonLL","RooBarlowBeestonLL"), + _nll(), +// _obs("paramOfInterest","Parameters of interest",this), +// _par("nuisanceParam","Nuisance parameters",this,kFALSE,kFALSE), + _pdf(NULL), _data(NULL) +{ + // Default constructor + // Should only be used by proof. + // _piter = _par.createIterator() ; + // _oiter = _obs.createIterator() ; +} + + +//_____________________________________________________________________________ +RooStats::HistFactory::RooBarlowBeestonLL::RooBarlowBeestonLL(const char *name, const char *title, + RooAbsReal& nllIn /*, const RooArgSet& observables*/) : + RooAbsReal(name,title), + _nll("input","-log(L) function",this,nllIn), + // _obs("paramOfInterest","Parameters of interest",this), + // _par("nuisanceParam","Nuisance parameters",this,kFALSE,kFALSE), + _pdf(NULL), _data(NULL) +{ + // Constructor of profile likelihood given input likelihood nll w.r.t + // the given set of variables. The input log likelihood is minimized w.r.t + // to all other variables of the likelihood at each evaluation and the + // value of the global log likelihood minimum is always subtracted. + + // Determine actual parameters and observables + /* + RooArgSet* actualObs = nllIn.getObservables(observables) ; + RooArgSet* actualPars = nllIn.getParameters(observables) ; + + _obs.add(*actualObs) ; + _par.add(*actualPars) ; + + delete actualObs ; + delete actualPars ; + + _piter = _par.createIterator() ; + _oiter = _obs.createIterator() ; + */ +} + + + +//_____________________________________________________________________________ +RooStats::HistFactory::RooBarlowBeestonLL::RooBarlowBeestonLL(const RooBarlowBeestonLL& other, const char* name) : + RooAbsReal(other,name), + _nll("nll",this,other._nll), + // _obs("obs",this,other._obs), + // _par("par",this,other._par), + _pdf(NULL), _data(NULL), + _paramFixed(other._paramFixed) +{ + // Copy constructor + + // _piter = _par.createIterator() ; + // _oiter = _obs.createIterator() ; + + // _paramAbsMin.addClone(other._paramAbsMin) ; + // _obsAbsMin.addClone(other._obsAbsMin) ; + +} + + + +//_____________________________________________________________________________ +RooStats::HistFactory::RooBarlowBeestonLL::~RooBarlowBeestonLL() +{ + // Destructor + + // Delete instance of minuit if it was ever instantiated + // if (_minuit) { + // delete _minuit ; + // } + + + //delete _piter ; + //delete _oiter ; +} + + +//_____________________________________________________________________________ +void RooStats::HistFactory::RooBarlowBeestonLL::BarlowCache::SetBinCenter() const { + TIterator* iter = bin_center->createIterator() ; + RooRealVar* var; + while((var=(RooRealVar*)iter->Next())) { + RooRealVar* target = (RooRealVar*) observables->find(var->GetName()) ; + target->setVal(var->getVal()) ; + } + delete iter; +} + + +//_____________________________________________________________________________ +void RooStats::HistFactory::RooBarlowBeestonLL::initializeBarlowCache() { + + bool verbose=false; + + if(!_data) { + std::cout << "Error: Must initialize data before initializing cache" << std::endl; + throw std::runtime_error("Uninitialized Data"); + } + if(!_pdf) { + std::cout << "Error: Must initialize model pdf before initializing cache" << std::endl; + throw std::runtime_error("Uninitialized model pdf"); + } + + // Get the data bin values for all channels and bins + std::map< std::string, std::vector<double> > ChannelBinDataMap; + getDataValuesForObservables( ChannelBinDataMap, _data, _pdf ); + + // Get a list of constraint terms + RooArgList obsTerms; + RooArgList constraints; + RooArgSet* obsSet = _pdf->getObservables(*_data); + FactorizeHistFactoryPdf(*obsSet, *_pdf, obsTerms, constraints); + + if( obsTerms.getSize() == 0 ) { + std::cout << "Error: Found no observable terms with pdf: " << _pdf->GetName() + << " using dataset: " << _data->GetName() << std::endl; + return; + } + if( constraints.getSize() == 0 ) { + std::cout << "Error: Found no constraint terms with pdf: " << _pdf->GetName() + << " using dataset: " << _data->GetName() << std::endl; + return; + } + + /* + // Get the channels for this pdf + RooArgSet* channels = new RooArgSet(); + RooArgSet* channelsWithConstraints = new RooArgSet(); + getChannelsFromModel( _pdf, channels, channelsWithConstraints ); + */ + + // Loop over the channels + RooSimultaneous* simPdf = (RooSimultaneous*) _pdf; + RooCategory* channelCat = (RooCategory*) (&simPdf->indexCat()); + TIterator* iter = channelCat->typeIterator() ; + RooCatType* tt = NULL; + while((tt=(RooCatType*) iter->Next())) { + /* + std::string ChannelName = tt->GetName(); + + HHChannel_hh_edit + + TIterator* iter_channels = channelsWithConstraints->createIterator(); + RooAbsPdf* channelPdf=NULL; + while(( channelPdf=(RooAbsPdf*)iter_channels->Next() )) { + + std::string channel_name = RooStats::channelNameFromPdf( channelPdf ); + */ + + // Warning: channel cat name is not necesarily the same name + // as the pdf's (for example, if someone does edits) + RooAbsPdf* channelPdf = simPdf->getPdf(tt->GetName()); + std::string channel_name = channelPdf->GetName(); + + // First, we check if this channel uses Stat Uncertainties: + RooArgList* gammas = new RooArgList(); + ParamHistFunc* param_func=NULL; + bool hasStatUncert = getStatUncertaintyFromChannel( channelPdf, param_func, gammas ); + if( ! hasStatUncert ) { + if(verbose) { + std::cout << "Channel: " << channel_name + << " doesn't have statistical uncertainties" + << std::endl; + } + continue; + } + else { + if(verbose) std::cout << "Found ParamHistFunc: " << param_func->GetName() << std::endl; + } + + // Now, loop over the bins in this channel + // To Do: Check that the index convention + // still works for 2-d (ie matches the + // convention in ParamHistFunc, etc) + int num_bins = param_func->numBins(); + + // Initialize the vector to the number of bins, allowing + // us to skip gamma's if they are constant + + std::vector<BarlowCache> temp_cache( num_bins ); + bool channel_has_stat_uncertainty=false; + + for( Int_t bin_index = 0; bin_index < num_bins; ++bin_index ) { + + // Create a cache object + BarlowCache cache; + + // Get the gamma for this bin, and skip if it's constant + RooRealVar* gamma_stat = &(param_func->getParameter(bin_index)); + if( gamma_stat->isConstant() ) { + if(verbose) std::cout << "Ignoring constant gamma: " << gamma_stat->GetName() << std::endl; + continue; + } + else { + cache.hasStatUncert=true; + channel_has_stat_uncertainty=true; + cache.gamma = gamma_stat; + _statUncertParams.insert( gamma_stat->GetName() ); + } + + // Store a snapshot of the bin center + RooArgSet* bin_center = (RooArgSet*) param_func->get( bin_index )->snapshot(); + cache.bin_center = bin_center; + cache.observables = obsSet; + + cache.binVolume = param_func->binVolume(); + + // Delete this part, simply a comment + RooArgList obs_list( *(cache.bin_center) ); + + // Get the gamma's constraint term + RooAbsReal* pois_mean = NULL; + RooRealVar* tau = NULL; + getStatUncertaintyConstraintTerm( &constraints, gamma_stat, pois_mean, tau ); + if( !tau || !pois_mean ) { + std::cout << "Failed to find pois mean or tau parameter for " << gamma_stat->GetName() << std::endl; + } + else { + if(verbose) std::cout << "Found pois mean and tau for parameter: " << gamma_stat->GetName() + << " tau: " << tau->GetName() << " " << tau->getVal() + << " pois_mean: " << pois_mean->GetName() << " " << pois_mean->getVal() + << std::endl; + } + + cache.tau = tau; + cache.nom_pois_mean = pois_mean; + + // Get the RooRealSumPdf + RooAbsPdf* sum_pdf = getSumPdfFromChannel( channelPdf ); + if( sum_pdf == NULL ) { + std::cout << "Failed to find RooRealSumPdf in channel " << channel_name + << ", therefor skipping this channel for analytic uncertainty minimization" + << std::endl; + channel_has_stat_uncertainty=false; + break; + } + cache.sumPdf = sum_pdf; + + // And set the data value for this bin + if( ChannelBinDataMap.find(channel_name) == ChannelBinDataMap.end() ) { + std::cout << "Error: channel with name: " << channel_name + << " not found in BinDataMap" << std::endl; + throw runtime_error("BinDataMap"); + } + double nData = ChannelBinDataMap[channel_name].at(bin_index); + cache.nData = nData; + + temp_cache.at(bin_index) = cache; + //_barlowCache[channel_name].at(bin_index) = cache; + + } // End: Loop over bins + + if( channel_has_stat_uncertainty ) { + std::cout << "Adding channel: " << channel_name + << " to the barlow cache" << std::endl; + _barlowCache[channel_name] = temp_cache; + } + + + } // End: Loop over channels + + + + // Successfully initialized the cache + // Printing some info + /* + std::map< std::string, std::vector< BarlowCache > >::iterator iter_cache; + for( iter_cache = _barlowCache.begin(); iter_cache != _barlowCache.end(); ++iter_cache ) { + + std::string channel_name = (*iter_cache).first; + std::vector< BarlowCache >& channel_cache = (*iter_cache).second; + + + for( unsigned int i = 0; i < channel_cache.size(); ++i ) { + BarlowCache& bin_cache = channel_cache.at(i); + + + RooRealVar* gamma = bin_cache.gamma; + RooRealVar* tau = bin_cache.tau; + RooAbsReal* pois_mean = bin_cache.nom_pois_mean; + RooAbsPdf* sum_pdf = (RooAbsPdf*) bin_cache.sumPdf; + double binVolume = bin_cache.binVolume; + + + if( !bin_cache.hasStatUncert ) { + std::cout << "Barlow Cache for Channel: " << channel_name + << " Bin: " << i + << " NO STAT UNCERT" + << std::endl; + } + else { + std::cout << "Barlow Cache for Channel: " << channel_name + << " Bin: " << i + << " gamma: " << gamma->GetName() + << " tau: " << tau->GetName() + << " pois_mean: " << pois_mean->GetName() + << " sum_pdf: " << sum_pdf->GetName() + << " binVolume: " << binVolume + << std::endl; + } + + } + } + */ + +} + + +//_____________________________________________________________________________ +RooArgSet* RooStats::HistFactory::RooBarlowBeestonLL::getParameters(const RooArgSet* depList, Bool_t stripDisconnected) const { + + RooArgSet* allArgs = RooAbsArg::getParameters( depList, stripDisconnected ); + + TIterator* iter_args = allArgs->createIterator(); + RooRealVar* arg; + while((arg=(RooRealVar*)iter_args->Next())) { + std::string arg_name = arg->GetName(); + + // If there is a gamma in the name, + // strip it from the list of dependencies + + if( _statUncertParams.find(arg_name.c_str()) != _statUncertParams.end() ) { + allArgs->remove( *arg, kTRUE ); + } + + } + + return allArgs; + +} + + +/* +//_____________________________________________________________________________ +const RooArgSet& RooStats::HistFactory::RooBarlowBeestonLL::bestFitParams() const +{ + validateAbsMin() ; + return _paramAbsMin ; +} + + +//_____________________________________________________________________________ +const RooArgSet& RooStats::HistFactory::RooBarlowBeestonLL::bestFitObs() const +{ + validateAbsMin() ; + return _obsAbsMin ; +} +*/ + + + +//_____________________________________________________________________________ +/* +RooAbsReal* RooStats::HistFactory::RooBarlowBeestonLL::createProfile(const RooArgSet& paramsOfInterest) +{ + // Optimized implementation of createProfile for profile likelihoods. + // Return profile of original function in terms of stated parameters + // of interest rather than profiling recursively. + + return nll().createProfile(paramsOfInterest) ; +} +*/ + + +/* +void RooStats::HistFactory::RooBarlowBeestonLL::FactorizePdf(const RooArgSet &observables, RooAbsPdf &pdf, RooArgList &obsTerms, RooArgList &constraints) const { + // utility function to factorize constraint terms from a pdf + // (from G. Petrucciani) + const std::type_info & id = typeid(pdf); + if (id == typeid(RooProdPdf)) { + RooProdPdf *prod = dynamic_cast<RooProdPdf *>(&pdf); + RooArgList list(prod->pdfList()); + for (int i = 0, n = list.getSize(); i < n; ++i) { + RooAbsPdf *pdfi = (RooAbsPdf *) list.at(i); + FactorizePdf(observables, *pdfi, obsTerms, constraints); + } + } else if (id == typeid(RooSimultaneous) ) { //|| id == typeid(RooSimultaneousOpt)) { + RooSimultaneous *sim = dynamic_cast<RooSimultaneous *>(&pdf); + RooAbsCategoryLValue *cat = (RooAbsCategoryLValue *) sim->indexCat().Clone(); + for (int ic = 0, nc = cat->numBins((const char *)0); ic < nc; ++ic) { + cat->setBin(ic); + FactorizePdf(observables, *sim->getPdf(cat->getLabel()), obsTerms, constraints); + } + delete cat; + } else if (pdf.dependsOn(observables)) { + if (!obsTerms.contains(pdf)) obsTerms.add(pdf); + } else { + if (!constraints.contains(pdf)) constraints.add(pdf); + } +} +*/ + + + +//_____________________________________________________________________________ +Double_t RooStats::HistFactory::RooBarlowBeestonLL::evaluate() const +{ + + /* + // Loop over the cached bins and channels + RooArgSet* channels = new RooArgSet(); + RooArgSet* channelsWithConstraints = new RooArgSet(); + RooStats::getChannelsFromModel( _pdf, channels, channelsWithConstraints ); + + // Loop over channels + TIterator* iter_channels = channelsWithConstraints->createIterator(); + RooAbsPdf* channelPdf=NULL; + while(( channelPdf=(RooAbsPdf*)iter_channels->Next() )) { + std::string channel_name = channelPdf->GetName(); //RooStats::channelNameFromPdf( channelPdf ); + */ + + // Loop over the channels (keys to the map) + //clock_t time_before_setVal, time_after_setVal; + //time_before_setVal=clock(); + std::map< std::string, std::vector< BarlowCache > >::iterator iter_cache; + for( iter_cache = _barlowCache.begin(); iter_cache != _barlowCache.end(); ++iter_cache ) { + + std::string channel_name = (*iter_cache).first; + std::vector< BarlowCache >& channel_cache = (*iter_cache).second; + + /* Slower way to find the channel vector: + // Get the vector of bin uncertainty caches for this channel + if( _barlowCache.find( channel_name ) == _barlowCache.end() ) { + std::cout << "Error: channel: " << channel_name + << " not found in barlow Cache" << std::endl; + throw runtime_error("Channel not in barlow cache"); + } + + std::vector< BarlowCache >& channel_cache = _barlowCache[ channel_name ]; + */ + + // Loop over the bins in the cache + // Set all gamma's to 0 + for( unsigned int i = 0; i < channel_cache.size(); ++i ) { + BarlowCache& bin_cache = channel_cache.at(i); + if( !bin_cache.hasStatUncert ) continue; + RooRealVar* gamma = bin_cache.gamma; + gamma->setVal(0.0); + } + std::vector< double > nu_b_vec( channel_cache.size() ); + for( unsigned int i = 0; i < channel_cache.size(); ++i ) { + BarlowCache& bin_cache = channel_cache.at(i); + if( !bin_cache.hasStatUncert ) continue; + + RooAbsPdf* sum_pdf = (RooAbsPdf*) bin_cache.sumPdf; + RooArgSet* obsSet = bin_cache.observables; + double binVolume = bin_cache.binVolume; + + bin_cache.SetBinCenter(); + double nu_b = sum_pdf->getVal(*obsSet)*sum_pdf->expectedEvents(*obsSet)*binVolume; + nu_b_vec.at(i) = nu_b; + } + + // Loop over the bins in the cache + // Set all gamma's to 1 + for( unsigned int i = 0; i < channel_cache.size(); ++i ) { + BarlowCache& bin_cache = channel_cache.at(i); + if( !bin_cache.hasStatUncert ) continue; + RooRealVar* gamma = bin_cache.gamma; + gamma->setVal(1.0); + } + std::vector< double > nu_b_stat_vec( channel_cache.size() ); + for( unsigned int i = 0; i < channel_cache.size(); ++i ) { + BarlowCache& bin_cache = channel_cache.at(i); + if( !bin_cache.hasStatUncert ) continue; + + RooAbsPdf* sum_pdf = (RooAbsPdf*) bin_cache.sumPdf; + RooArgSet* obsSet = bin_cache.observables; + double binVolume = bin_cache.binVolume; + + bin_cache.SetBinCenter(); + double nu_b_stat = sum_pdf->getVal(*obsSet)*sum_pdf->expectedEvents(*obsSet)*binVolume - nu_b_vec.at(i); + nu_b_stat_vec.at(i) = nu_b_stat; + } + //time_after_setVal=clock(); + + // Done with the first loops. + // Now evaluating the function + + //clock_t time_before_eval, time_after_eval; + + // Loop over the bins in the cache + //time_before_eval=clock(); + for( unsigned int i = 0; i < channel_cache.size(); ++i ) { + + BarlowCache& bin_cache = channel_cache.at(i); + + if( !bin_cache.hasStatUncert ) { + //std::cout << "Bin: " << i << " of " << channel_cache.size() + // << " in channel: " << channel_name + // << " doesn't have stat uncertainties" << std::endl; + continue; + } + + // Set the observable to the bin center + bin_cache.SetBinCenter(); + + // Get the cached objects + RooRealVar* gamma = bin_cache.gamma; + RooRealVar* tau = bin_cache.tau; + RooAbsReal* pois_mean = bin_cache.nom_pois_mean; + //RooAbsPdf* sum_pdf = (RooAbsPdf*) bin_cache.sumPdf; + //RooArgSet* obsSet = bin_cache.observables; + //double binVolume = bin_cache.binVolume; + + // Get the values necessary for + // the analytic minimization + double nu_b = nu_b_vec.at(i); + double nu_b_stat = nu_b_stat_vec.at(i); + + double tau_val = tau->getVal(); + double nData = bin_cache.nData; + double m_val = pois_mean->getVal(); + + // Initialize the minimized value of gamma + double gamma_hat_hat = 1.0; + + // Check that the quadratic term is > 0 + if(nu_b_stat > 0.00000001) { + + double A = nu_b_stat*nu_b_stat + tau_val*nu_b_stat; + double B = nu_b*tau_val + nu_b*nu_b_stat - nData*nu_b_stat - m_val*nu_b_stat; + double C = -1*m_val*nu_b; + + double discrim = B*B-4*A*C; + + if( discrim < 0 ) { + std::cout << "Warning: Discriminant (B*B - 4AC) < 0" << std::endl; + std::cout << "Warning: Taking B*B - 4*A*C == 0" << std::endl; + discrim=0; + //throw runtime_error("BarlowBeestonLL::evaluate() : B*B - 4AC < 0"); + } + if( A <= 0 ) { + std::cout << "Warning: A <= 0" << std::endl; + throw runtime_error("BarlowBeestonLL::evaluate() : A < 0"); + } + + gamma_hat_hat = ( -1*B + TMath::Sqrt(discrim) ) / (2*A); + } + + // If the quadratic term is 0, we simply + // use a linear equation + else { + gamma_hat_hat = m_val/tau_val; + } + + // Check for NAN + if( TMath::IsNaN(gamma_hat_hat) ) { + std::cout << "ERROR: gamma hat hat is NAN" << std::endl; + throw runtime_error("BarlowBeestonLL::evaluate() : gamma hat hat is NAN"); + } + + if( gamma_hat_hat <= 0 ) { + std::cout << "WARNING: gamma hat hat <= 0. Setting to 0" << std::endl; + gamma_hat_hat = 0; + } + + /* + std::cout << "n: " << bin_cache.nData << " " + << "nu_stat: " << nu_b_stat << " " + << "nu: " << nu_b << " " + << "tau: " << tau->getVal() << " " + << "m: " << pois_mean->getVal() << " " + << "A: " << A << " " + << "B: " << B << " " + << "C: " << C << " " + << "gamma hat hat: " << gamma_hat_hat + << std::endl; + */ + + gamma->setVal( gamma_hat_hat ); + + } + + //time_after_eval=clock(); + + //float time_setVal = ((float) time_after_setVal - (float) time_before_setVal) / ((float) CLOCKS_PER_SEC); + //float time_eval = ((float) time_after_eval - (float) time_before_eval) / ((float) CLOCKS_PER_SEC); + + /* + std::cout << "Barlow timing for channel: " << channel_name + << " SetVal: " << time_setVal + << " Eval: " << time_eval + << std::endl; + */ + } + + + return _nll; + +} + + + +/* +//_____________________________________________________________________________ +void RooStats::HistFactory::RooBarlowBeestonLL::validateAbsMin() const +{ + // Check that parameters and likelihood value for 'best fit' are still valid. If not, + // because the best fit has never been calculated, or because constant parameters have + // changed value or parameters have changed const/float status, the minimum is recalculated + + // Check if constant status of any of the parameters have changed + if (_absMinValid) { + _piter->Reset() ; + RooAbsArg* par ; + while((par=(RooAbsArg*)_piter->Next())) { + if (_paramFixed[par->GetName()] != par->isConstant()) { + cxcoutI(Minimization) << "RooStats::HistFactory::RooBarlowBeestonLL::evaluate(" << GetName() << ") constant status of parameter " << par->GetName() << " has changed from " + << (_paramFixed[par->GetName()]?"fixed":"floating") << " to " << (par->isConstant()?"fixed":"floating") + << ", recalculating absolute minimum" << endl ; + _absMinValid = kFALSE ; + break ; + } + } + } + + + // If we don't have the absolute minimum w.r.t all observables, calculate that first + if (!_absMinValid) { + + cxcoutI(Minimization) << "RooStats::HistFactory::RooBarlowBeestonLL::evaluate(" << GetName() << ") determining minimum likelihood for current configurations w.r.t all observable" << endl ; + + + // Save current values of non-marginalized parameters + RooArgSet* obsStart = (RooArgSet*) _obs.snapshot(kFALSE) ; + + // Start from previous global minimum + if (_paramAbsMin.getSize()>0) { + const_cast<RooSetProxy&>(_par).assignValueOnly(_paramAbsMin) ; + } + if (_obsAbsMin.getSize()>0) { + const_cast<RooSetProxy&>(_obs).assignValueOnly(_obsAbsMin) ; + } + + // Find minimum with all observables floating + const_cast<RooSetProxy&>(_obs).setAttribAll("Constant",kFALSE) ; + _minuit->migrad() ; + + // Save value and remember + _absMin = _nll ; + _absMinValid = kTRUE ; + + // Save parameter values at abs minimum as well + _paramAbsMin.removeAll() ; + + // Only store non-constant parameters here! + RooArgSet* tmp = (RooArgSet*) _par.selectByAttrib("Constant",kFALSE) ; + _paramAbsMin.addClone(*tmp) ; + delete tmp ; + + _obsAbsMin.addClone(_obs) ; + + // Save constant status of all parameters + _piter->Reset() ; + RooAbsArg* par ; + while((par=(RooAbsArg*)_piter->Next())) { + _paramFixed[par->GetName()] = par->isConstant() ; + } + + if (dologI(Minimization)) { + cxcoutI(Minimization) << "RooStats::HistFactory::RooBarlowBeestonLL::evaluate(" << GetName() << ") minimum found at (" ; + + RooAbsReal* arg ; + Bool_t first=kTRUE ; + _oiter->Reset() ; + while ((arg=(RooAbsReal*)_oiter->Next())) { + ccxcoutI(Minimization) << (first?"":", ") << arg->GetName() << "=" << arg->getVal() ; + first=kFALSE ; + } + ccxcoutI(Minimization) << ")" << endl ; + } + + // Restore original parameter values + const_cast<RooSetProxy&>(_obs) = *obsStart ; + delete obsStart ; + + } +} +*/ + + +//_____________________________________________________________________________ +Bool_t RooStats::HistFactory::RooBarlowBeestonLL::redirectServersHook(const RooAbsCollection& /*newServerList*/, Bool_t /*mustReplaceAll*/, + Bool_t /*nameChange*/, Bool_t /*isRecursive*/) +{ + /* + if (_minuit) { + delete _minuit ; + _minuit = 0 ; + } + */ + return kFALSE ; +} + + diff --git a/roofit/histfactory/src/Sample.cxx b/roofit/histfactory/src/Sample.cxx index 12fee536825cd..4d5b7836c7573 100644 --- a/roofit/histfactory/src/Sample.cxx +++ b/roofit/histfactory/src/Sample.cxx @@ -1,25 +1,52 @@ - +// @(#)root/roostats:$Id$ +// Author: Kyle Cranmer, George Lewis +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +//_________________________________________________ +/* +BEGIN_HTML +<p> +</p> +END_HTML +*/ +// + +#include "TH1.h" #include "RooStats/HistFactory/Sample.h" +#include "RooStats/HistFactory/HistFactoryException.h" //#include "TClass.h" RooStats::HistFactory::Sample::Sample() : - fNormalizeByTheory(false), fStatErrorActivate(false) { ; } + fNormalizeByTheory(false), fStatErrorActivate(false), fhNominal(), fhCountingHist(0) { ; } RooStats::HistFactory::Sample::Sample(std::string SampName, std::string SampHistoName, std::string SampInputFile, std::string SampHistoPath) : fName( SampName ), fInputFile( SampInputFile), fHistoName( SampHistoName ), fHistoPath( SampHistoPath ), - fNormalizeByTheory(true), fStatErrorActivate(false) { ; } + fNormalizeByTheory(true), fStatErrorActivate(false), fhNominal(), + fhCountingHist(0) { ; } RooStats::HistFactory::Sample::Sample(std::string SampName) : fName( SampName ), fInputFile( "" ), fHistoName( "" ), fHistoPath( "" ), - fNormalizeByTheory(true), fStatErrorActivate(false) { ; } + fNormalizeByTheory(true), fStatErrorActivate(false),fhNominal(), + fhCountingHist(0) { ; } +RooStats::HistFactory::Sample::~Sample() { + if(fhCountingHist) + delete fhCountingHist; +} -TH1* RooStats::HistFactory::Sample::GetHisto() { - return (TH1*) fhNominal.GetObject(); +TH1* RooStats::HistFactory::Sample::GetHisto() { + TH1* histo = (TH1*) fhNominal.GetObject(); + return histo; } @@ -35,6 +62,24 @@ void RooStats::HistFactory::Sample::writeToFile( std::string OutputFileName, std fHistoName = histNominal->GetName(); fHistoPath = DirName; + // Write this sample's StatError + GetStatError().writeToFile( OutputFileName, DirName ); + + // Must write all systematics that contain internal histograms + // (This is not all systematics) + for( unsigned int i = 0; i < GetHistoSysList().size(); ++i ) { + GetHistoSysList().at(i).writeToFile( OutputFileName, DirName ); + } + for( unsigned int i = 0; i < GetHistoFactorList().size(); ++i ) { + GetHistoFactorList().at(i).writeToFile( OutputFileName, DirName ); + } + for( unsigned int i = 0; i < GetShapeSysList().size(); ++i ) { + GetShapeSysList().at(i).writeToFile( OutputFileName, DirName ); + } + for( unsigned int i = 0; i < GetShapeFactorList().size(); ++i ) { + GetShapeFactorList().at(i).writeToFile( OutputFileName, DirName ); + } + return; } @@ -50,12 +95,15 @@ void RooStats::HistFactory::Sample::SetValue( Double_t val ) { std::string SampleHistName = fName + "_hist"; // Histogram has 1-bin (hard-coded) - TH1F* hSample = new TH1F( SampleHistName.c_str(), SampleHistName.c_str(), 1, 0, 1 ); - hSample->SetBinContent( 1, val ); + if(fhCountingHist) + delete fhCountingHist; + + fhCountingHist = new TH1F( SampleHistName.c_str(), SampleHistName.c_str(), 1, 0, 1 ); + fhCountingHist->SetBinContent( 1, val ); // Set the histogram of the internally held data // node of this channel to this newly created histogram - SetHisto( hSample ); + SetHisto( fhCountingHist ); } @@ -112,7 +160,10 @@ void RooStats::HistFactory::Sample::PrintXML( std::ofstream& xml ) { << " NormalizeByTheory=\"" << (fNormalizeByTheory ? std::string("True") : std::string("False")) << "\" " << ">" << std::endl; + // Print Stat Error (if necessary) + fStatError.PrintXML( xml ); + /* if( fStatError.GetActivate() ) { xml << " <StatError Activate=\"" << (fStatError.GetActivate() ? std::string("True") : std::string("False")) << "\" " << " InputFile=\"" << fStatError.GetInputFile() << "\" " @@ -120,26 +171,36 @@ void RooStats::HistFactory::Sample::PrintXML( std::ofstream& xml ) { << " HistoPath=\"" << fStatError.GetHistoPath() << "\" " << " /> " << std::endl; } - + */ + + // Now, print the systematics: for( unsigned int i = 0; i < fOverallSysList.size(); ++i ) { RooStats::HistFactory::OverallSys sys = fOverallSysList.at(i); + sys.PrintXML(xml); + /* xml << " <OverallSys Name=\"" << sys.GetName() << "\" " << " High=\"" << sys.GetHigh() << "\" " << " Low=\"" << sys.GetLow() << "\" " << " /> " << std::endl; + */ } for( unsigned int i = 0; i < fNormFactorList.size(); ++i ) { RooStats::HistFactory::NormFactor sys = fNormFactorList.at(i); + sys.PrintXML(xml); + /* xml << " <NormFactor Name=\"" << sys.GetName() << "\" " << " Val=\"" << sys.GetVal() << "\" " << " High=\"" << sys.GetHigh() << "\" " << " Low=\"" << sys.GetLow() << "\" " << " Const=\"" << (sys.GetConst() ? std::string("True") : std::string("False")) << "\" " << " /> " << std::endl; + */ } for( unsigned int i = 0; i < fHistoSysList.size(); ++i ) { RooStats::HistFactory::HistoSys sys = fHistoSysList.at(i); + sys.PrintXML(xml); + /* xml << " <HistoSys Name=\"" << sys.GetName() << "\" " << " InputFileLow=\"" << sys.GetInputFileLow() << "\" " @@ -150,9 +211,12 @@ void RooStats::HistFactory::Sample::PrintXML( std::ofstream& xml ) { << " HistoNameHigh=\"" << sys.GetHistoNameHigh() << "\" " << " HistoPathHigh=\"" << sys.GetHistoPathHigh() << "\" " << " /> " << std::endl; + */ } for( unsigned int i = 0; i < fHistoFactorList.size(); ++i ) { RooStats::HistFactory::HistoFactor sys = fHistoFactorList.at(i); + sys.PrintXML(xml); + /* xml << " <HistoFactor Name=\"" << sys.GetName() << "\" " << " InputFileLow=\"" << sys.GetInputFileLow() << "\" " @@ -163,9 +227,12 @@ void RooStats::HistFactory::Sample::PrintXML( std::ofstream& xml ) { << " HistoNameHigh=\"" << sys.GetHistoNameHigh() << "\" " << " HistoPathHigh=\"" << sys.GetHistoPathHigh() << "\" " << " /> " << std::endl; + */ } for( unsigned int i = 0; i < fShapeSysList.size(); ++i ) { RooStats::HistFactory::ShapeSys sys = fShapeSysList.at(i); + sys.PrintXML(xml); + /* xml << " <ShapeSys Name=\"" << sys.GetName() << "\" " << " InputFile=\"" << sys.GetInputFile() << "\" " @@ -173,18 +240,20 @@ void RooStats::HistFactory::Sample::PrintXML( std::ofstream& xml ) { << " HistoPath=\"" << sys.GetHistoPath() << "\" " << " ConstraintType=\"" << std::string(Constraint::Name(sys.GetConstraintType())) << "\" " << " /> " << std::endl; + */ } for( unsigned int i = 0; i < fShapeFactorList.size(); ++i ) { RooStats::HistFactory::ShapeFactor sys = fShapeFactorList.at(i); + sys.PrintXML(xml); + /* xml << " <ShapeFactor Name=\"" << sys.GetName() << "\" " << " /> " << std::endl; + */ } - // Finally, close the tag xml << " </Sample>" << std::endl; - } @@ -226,6 +295,10 @@ void RooStats::HistFactory::Sample::AddOverallSys( std::string SysName, Double_t } +void RooStats::HistFactory::Sample::AddOverallSys( const OverallSys& Sys ) { + fOverallSysList.push_back(Sys); +} + void RooStats::HistFactory::Sample::AddNormFactor( std::string SysName, Double_t SysVal, Double_t SysLow, Double_t SysHigh, bool SysConst ) { RooStats::HistFactory::NormFactor norm; @@ -240,8 +313,13 @@ void RooStats::HistFactory::Sample::AddNormFactor( std::string SysName, Double_t } +void RooStats::HistFactory::Sample::AddNormFactor( const NormFactor& Factor ) { + fNormFactorList.push_back( Factor ); +} + -void RooStats::HistFactory::Sample::AddHistoSys( std::string SysName, std::string SysHistoNameLow, std::string SysHistoFileLow, std::string SysHistoPathLow, +void RooStats::HistFactory::Sample::AddHistoSys( std::string SysName, +std::string SysHistoNameLow, std::string SysHistoFileLow, std::string SysHistoPathLow, std::string SysHistoNameHigh, std::string SysHistoFileHigh, std::string SysHistoPathHigh ) { RooStats::HistFactory::HistoSys sys; @@ -259,12 +337,14 @@ void RooStats::HistFactory::Sample::AddHistoSys( std::string SysName, std::strin } +void RooStats::HistFactory::Sample::AddHistoSys( const HistoSys& Sys ) { + fHistoSysList.push_back( Sys ); +} + void RooStats::HistFactory::Sample::AddHistoFactor( std::string SysName, std::string SysHistoNameLow, std::string SysHistoFileLow, std::string SysHistoPathLow, std::string SysHistoNameHigh, std::string SysHistoFileHigh, std::string SysHistoPathHigh ) { - - RooStats::HistFactory::HistoFactor factor; factor.SetName( SysName ); @@ -280,6 +360,9 @@ void RooStats::HistFactory::Sample::AddHistoFactor( std::string SysName, std::st } +void RooStats::HistFactory::Sample::AddHistoFactor( const HistoFactor& Factor ) { + fHistoFactorList.push_back(Factor); +} void RooStats::HistFactory::Sample::AddShapeFactor( std::string SysName ) { @@ -290,6 +373,12 @@ void RooStats::HistFactory::Sample::AddShapeFactor( std::string SysName ) { } + +void RooStats::HistFactory::Sample::AddShapeFactor( const ShapeFactor& Factor ) { + fShapeFactorList.push_back(Factor); +} + + void RooStats::HistFactory::Sample::AddShapeSys( std::string SysName, Constraint::Type SysConstraintType, std::string SysHistoName, std::string SysHistoFile, std::string SysHistoPath ) { RooStats::HistFactory::ShapeSys sys; @@ -303,3 +392,7 @@ void RooStats::HistFactory::Sample::AddShapeSys( std::string SysName, Constraint fShapeSysList.push_back( sys ); } + +void RooStats::HistFactory::Sample::AddShapeSys( const ShapeSys& Sys ) { + fShapeSysList.push_back(Sys); +} diff --git a/roofit/histfactory/src/Systematics.cxx b/roofit/histfactory/src/Systematics.cxx index dde21b6273853..87882f822a00d 100644 --- a/roofit/histfactory/src/Systematics.cxx +++ b/roofit/histfactory/src/Systematics.cxx @@ -1,3 +1,21 @@ +// @(#)root/roostats:$Id$ +// Author: Kyle Cranmer, George Lewis +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +//_________________________________________________ +/* +BEGIN_HTML +<p> +</p> +END_HTML +*/ +// #include "RooStats/HistFactory/Systematics.h" @@ -5,7 +23,6 @@ // Constraints - std::string RooStats::HistFactory::Constraint::Name( Constraint::Type type ) { if( type == Constraint::Gaussian ) return "Gaussian"; @@ -13,11 +30,11 @@ std::string RooStats::HistFactory::Constraint::Name( Constraint::Type type ) { return ""; } -RooStats::HistFactory::Constraint::Type RooStats::HistFactory::Constraint::GetType( std::string Name ) { +RooStats::HistFactory::Constraint::Type RooStats::HistFactory::Constraint::GetType( const std::string& Name ) { if( Name == "" ) { std::cout << "Error: Given empty name for ConstraintType" << std::endl; - throw bad_hf; + throw hf_exc(); } else if ( Name == "Gaussian" || Name == "Gauss" ) { @@ -30,13 +47,15 @@ RooStats::HistFactory::Constraint::Type RooStats::HistFactory::Constraint::GetTy else { std::cout << "Error: Unknown name given for Constraint Type: " << Name << std::endl; - throw bad_hf; + throw hf_exc(); } } // Norm Factor -RooStats::HistFactory::NormFactor::NormFactor() {;} +RooStats::HistFactory::NormFactor::NormFactor() : fName(""), fVal(1.0), + fLow(1.0), fHigh(1.0), + fConst(true) {;} void RooStats::HistFactory::NormFactor::Print( std::ostream& stream ) { stream << "\t \t Name: " << fName @@ -47,6 +66,15 @@ void RooStats::HistFactory::NormFactor::Print( std::ostream& stream ) { << std::endl; } +void RooStats::HistFactory::NormFactor::PrintXML( std::ostream& xml ) { + xml << " <NormFactor Name=\"" << GetName() << "\" " + << " Val=\"" << GetVal() << "\" " + << " High=\"" << GetHigh() << "\" " + << " Low=\"" << GetLow() << "\" " + << " Const=\"" << (GetConst() ? std::string("True") : std::string("False")) << "\" " + << " /> " << std::endl; +} + // Overall Sys void RooStats::HistFactory::OverallSys::Print( std::ostream& stream ) { stream << "\t \t Name: " << fName @@ -55,14 +83,22 @@ void RooStats::HistFactory::OverallSys::Print( std::ostream& stream ) { << std::endl; } -// HistoSys +void RooStats::HistFactory::OverallSys::PrintXML( std::ostream& xml ) { + xml << " <OverallSys Name=\"" << GetName() << "\" " + << " High=\"" << GetHigh() << "\" " + << " Low=\"" << GetLow() << "\" " + << " /> " << std::endl; +} +// HistoSys TH1* RooStats::HistFactory::HistoSys::GetHistoLow() { - return (TH1*) fhLow.GetObject(); + TH1* histo_low = (TH1*) fhLow.GetObject(); + return histo_low; } TH1* RooStats::HistFactory::HistoSys::GetHistoHigh() { - return (TH1*) fhHigh.GetObject(); + TH1* histo_high = (TH1*) fhHigh.GetObject(); + return histo_high; } void RooStats::HistFactory::HistoSys::Print( std::ostream& stream ) { @@ -76,35 +112,60 @@ void RooStats::HistFactory::HistoSys::Print( std::ostream& stream ) { << std::endl; } +void RooStats::HistFactory::HistoSys::PrintXML( std::ostream& xml ) { + xml << " <HistoSys Name=\"" << GetName() << "\" " + << " InputFileLow=\"" << GetInputFileLow() << "\" " + << " HistoNameLow=\"" << GetHistoNameLow() << "\" " + << " HistoPathLow=\"" << GetHistoPathLow() << "\" " + + << " InputFileHigh=\"" << GetInputFileHigh() << "\" " + << " HistoNameHigh=\"" << GetHistoNameHigh() << "\" " + << " HistoPathHigh=\"" << GetHistoPathHigh() << "\" " + << " /> " << std::endl; +} -void RooStats::HistFactory::HistoSys::writeToFile( std::string FileName, std::string DirName ) { +void RooStats::HistFactory::HistoSys::writeToFile( const std::string& FileName, + const std::string& DirName ) { // This saves the histograms to a file and // changes the name of the local file and histograms TH1* histLow = GetHistoLow(); + if( histLow==NULL ) { + std::cout << "Error: Cannot write " << GetName() + << " to file: " << FileName + << " HistoLow is NULL" + << std::endl; + throw hf_exc(); + } histLow->Write(); fInputFileLow = FileName; fHistoPathLow = DirName; fHistoNameLow = histLow->GetName(); TH1* histHigh = GetHistoHigh(); + if( histHigh==NULL ) { + std::cout << "Error: Cannot write " << GetName() + << " to file: " << FileName + << " HistoHigh is NULL" + << std::endl; + throw hf_exc(); + } histHigh->Write(); fInputFileHigh = FileName; fHistoPathHigh = DirName; fHistoNameHigh = histHigh->GetName(); - return; } - // Shape Sys TH1* RooStats::HistFactory::ShapeSys::GetErrorHist() { - return (TH1*) fhError.GetObject(); + TH1* error_hist = (TH1*) fhError.GetObject(); + return error_hist; } @@ -116,9 +177,28 @@ void RooStats::HistFactory::ShapeSys::Print( std::ostream& stream ) { << std::endl; } -void RooStats::HistFactory::ShapeSys::writeToFile( std::string FileName, std::string DirName ) { + +void RooStats::HistFactory::ShapeSys::PrintXML( std::ostream& xml ) { + xml << " <ShapeSys Name=\"" << GetName() << "\" " + << " InputFile=\"" << GetInputFile() << "\" " + << " HistoName=\"" << GetHistoName() << "\" " + << " HistoPath=\"" << GetHistoPath() << "\" " + << " ConstraintType=\"" << std::string(Constraint::Name(GetConstraintType())) << "\" " + << " /> " << std::endl; +} + + +void RooStats::HistFactory::ShapeSys::writeToFile( const std::string& FileName, + const std::string& DirName ) { TH1* histError = GetErrorHist(); + if( histError==NULL ) { + std::cout << "Error: Cannot write " << GetName() + << " to file: " << FileName + << " ErrorHist is NULL" + << std::endl; + throw hf_exc(); + } histError->Write(); fInputFile = FileName; fHistoPath = DirName; @@ -129,6 +209,8 @@ void RooStats::HistFactory::ShapeSys::writeToFile( std::string FileName, std::st } + + // HistoFactor void RooStats::HistFactory::HistoFactor::Print( std::ostream& stream ) { @@ -144,27 +226,44 @@ void RooStats::HistFactory::HistoFactor::Print( std::ostream& stream ) { TH1* RooStats::HistFactory::HistoFactor::GetHistoLow() { - return (TH1*) fhLow.GetObject(); + TH1* histo_low = (TH1*) fhLow.GetObject(); + return histo_low; } TH1* RooStats::HistFactory::HistoFactor::GetHistoHigh() { - return (TH1*) fhHigh.GetObject(); + TH1* histo_high = (TH1*) fhHigh.GetObject(); + return histo_high; } -void RooStats::HistFactory::HistoFactor::writeToFile( std::string FileName, std::string DirName ) { +void RooStats::HistFactory::HistoFactor::writeToFile( const std::string& FileName, + const std::string& DirName ) { // This saves the histograms to a file and // changes the name of the local file and histograms TH1* histLow = GetHistoLow(); + if( histLow==NULL ) { + std::cout << "Error: Cannot write " << GetName() + << " to file: " << FileName + << " HistoLow is NULL" + << std::endl; + throw hf_exc(); + } histLow->Write(); fInputFileLow = FileName; fHistoPathLow = DirName; fHistoNameLow = histLow->GetName(); TH1* histHigh = GetHistoHigh(); + if( histHigh==NULL ) { + std::cout << "Error: Cannot write " << GetName() + << " to file: " << FileName + << " HistoHigh is NULL" + << std::endl; + throw hf_exc(); + } histHigh->Write(); fInputFileHigh = FileName; fHistoPathHigh = DirName; @@ -174,23 +273,94 @@ void RooStats::HistFactory::HistoFactor::writeToFile( std::string FileName, std: } +void RooStats::HistFactory::HistoFactor::PrintXML( std::ostream& xml ) { + xml << " <HistoFactor Name=\"" << GetName() << "\" " + + << " InputFileLow=\"" << GetInputFileLow() << "\" " + << " HistoNameLow=\"" << GetHistoNameLow() << "\" " + << " HistoPathLow=\"" << GetHistoPathLow() << "\" " + + << " InputFileHigh=\"" << GetInputFileHigh() << "\" " + << " HistoNameHigh=\"" << GetHistoNameHigh() << "\" " + << " HistoPathHigh=\"" << GetHistoPathHigh() << "\" " + << " /> " << std::endl; +} + + // Shape Factor +RooStats::HistFactory::ShapeFactor::ShapeFactor() : fConstant(false), + fHasInitialShape(false), + fhInitialShape(NULL) {;} void RooStats::HistFactory::ShapeFactor::Print( std::ostream& stream ) { - stream << "\t \t Name: " << fName - << std::endl; + + stream << "\t \t Name: " << fName << std::endl; + + if( fHistoName != "" ) { + stream << "\t \t " + << " Shape Hist Name: " << fHistoName + << " Shape Hist Path Name: " << fHistoPath + << " Shape Hist FileName: " << fInputFile + << std::endl; + } + + if( fConstant ) { stream << "\t \t ( Constant ): " << std::endl; } + } -// Stat Error +void RooStats::HistFactory::ShapeFactor::writeToFile( const std::string& FileName, + const std::string& DirName ) { + + if( HasInitialShape() ) { + TH1* histInitialShape = GetInitialShape(); + if( histInitialShape==NULL ) { + std::cout << "Error: Cannot write " << GetName() + << " to file: " << FileName + << " InitialShape is NULL" + << std::endl; + throw hf_exc(); + } + histInitialShape->Write(); + fInputFile = FileName; + fHistoPath = DirName; + fHistoName = histInitialShape->GetName(); + } + + return; + +} + +void RooStats::HistFactory::ShapeFactor::PrintXML( std::ostream& xml ) { + xml << " <ShapeFactor Name=\"" << GetName() << "\" "; + if( fHasInitialShape ) { + xml << " InputFile=\"" << GetInputFile() << "\" " + << " HistoName=\"" << GetHistoName() << "\" " + << " HistoPath=\"" << GetHistoPath() << "\" "; + } + xml << " /> " << std::endl; +} + +// Stat Error Config void RooStats::HistFactory::StatErrorConfig::Print( std::ostream& stream ) { stream << "\t \t RelErrorThreshold: " << fRelErrorThreshold << "\t ConstraintType: " << Constraint::Name( fConstraintType ) << std::endl; } +void RooStats::HistFactory::StatErrorConfig::PrintXML( std::ostream& xml ) { + xml << " <StatErrorConfig RelErrorThreshold=\"" << GetRelErrorThreshold() + << "\" " + << "ConstraintType=\"" << Constraint::Name( GetConstraintType() ) + << "\" " + << "/> " << std::endl << std::endl; + +} + + +// Stat Error TH1* RooStats::HistFactory::StatError::GetErrorHist() { return (TH1*) fhError.GetObject(); } @@ -204,13 +374,33 @@ void RooStats::HistFactory::StatError::Print( std::ostream& stream ) { << std::endl; } -void RooStats::HistFactory::StatError::writeToFile( std::string OutputFileName, std::string DirName ) { +void RooStats::HistFactory::StatError::PrintXML( std::ostream& xml ) { + + if( GetActivate() ) { + xml << " <StatError Activate=\"" + << (GetActivate() ? std::string("True") : std::string("False")) + << "\" " + << " InputFile=\"" << GetInputFile() << "\" " + << " HistoName=\"" << GetHistoName() << "\" " + << " HistoPath=\"" << GetHistoPath() << "\" " + << " /> " << std::endl; + } + +} + + +void RooStats::HistFactory::StatError::writeToFile( const std::string& OutputFileName, + const std::string& DirName ) { if( fUseHisto ) { std::string statErrorHistName = "statisticalErrors"; TH1* hStatError = GetErrorHist(); + if( hStatError == NULL ) { + std::cout << "Error: Stat Error error hist is NULL" << std::endl; + throw hf_exc(); + } hStatError->Write(statErrorHistName.c_str()); fInputFile = OutputFileName; diff --git a/roofit/histfactory/src/hist2workspace.cxx b/roofit/histfactory/src/hist2workspace.cxx new file mode 100644 index 0000000000000..02228c707e83c --- /dev/null +++ b/roofit/histfactory/src/hist2workspace.cxx @@ -0,0 +1,136 @@ +// @(#)root/roostats:$Id$ +// Author: Kyle Cranmer, George Lewis +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +//_________________________________________________ +/* +BEGIN_HTML +<p> +</p> +END_HTML +*/ +// + +#include <string> +#include <exception> +#include <vector> + +//void topDriver(string input); // in MakeModelAndMeasurements +//void fastDriver(string input); // in MakeModelAndMeasurementsFast + +//#include "RooStats/HistFactory/MakeModelAndMeasurements.h" +#include "RooStats/HistFactory/ConfigParser.h" +#include "RooStats/HistFactory/MakeModelAndMeasurementsFast.h" + +//_____________________________batch only_____________________ +#ifndef __CINT__ + +namespace RooStats { + namespace HistFactory { + void fastDriver(std::string input) { + + // Create the initial list of measurements and channels + std::vector< HistFactory::Measurement > measurement_list; + // std::vector< HistFactory::Channel > channel_list; + + // Fill them using the XML parser + HistFactory::ConfigParser xmlParser; + measurement_list = xmlParser.GetMeasurementsFromXML( input ); + + // At this point, we have all the information we need + // from the xml files. + + // We will make the measurements 1-by-1 + for(unsigned int i = 0; i < measurement_list.size(); ++i) { + HistFactory::Measurement measurement = measurement_list.at(i); + measurement.CollectHistograms(); + MakeModelAndMeasurementFast( measurement ); + } + + return; + + } + } // namespace RooStats +} // namespace HistFactory + + +int main(int argc, char** argv) { + + if( !(argc > 1) ) { + std::cerr << "need input file" << std::endl; + exit(1); + } + + if(argc==2){ + std::string input(argv[1]); + try { + RooStats::HistFactory::fastDriver(input); + } + catch(std::string str) { + std::cerr << "hist2workspace - Caught exception: " << str << std::endl ; + exit(1); + } + catch( const std::exception& e ) { + std::cerr << "hist2workspace - Caught Exception: " << e.what() << std::endl; + exit(1); + } + catch(...) { + exit(1); + } + } + + if(argc==3){ + std::string flag(argv[1]); + std::string input(argv[2]); + + if(flag=="-standard_form") { + try { + RooStats::HistFactory::fastDriver(input); + } + catch(std::string str) { + std::cerr << "hist2workspace - Caught exception: " << str << std::endl ; + exit(1); + } + catch( const std::exception& e ) { + std::cerr << "hist2workspace - Caught Exception: " << e.what() << std::endl; + exit(1); + } + catch(...) { + std::cerr << "hist2workspace - Caught Exception" << std::endl; + exit(1); + } + } + + else if(flag=="-number_counting_form") { + std::cout << "ERROR: 'number_counting_form' is now depricated." << std::endl; + /* + try { + //topDriver(input); + } + catch (std::string str) { + std::cerr << "caught exception: " << str << std::endl ; + } + catch( const std::exception& e ) { + std::cerr << "Caught Exception: " << e.what() << std::endl; + } + */ + return 255; + } + + else { + std::cerr << "Unrecognized flag. " << std::endl; + return 255; + } + } + + return 0; + +} + +#endif diff --git a/roofit/roofit/inc/Roo2DKeysPdf.h b/roofit/roofit/inc/Roo2DKeysPdf.h index 88c3a9a9247ad..4d0d92ca11bfb 100644 --- a/roofit/roofit/inc/Roo2DKeysPdf.h +++ b/roofit/roofit/inc/Roo2DKeysPdf.h @@ -65,7 +65,7 @@ class Roo2DKeysPdf : public RooAbsPdf Double_t getSigma(const char * axis) const; // print content and basic information about the data - void PrintInfo(ostream &) const; + void PrintInfo(std::ostream &) const; // save PDF to a file as a TH2F *, TTree * or both // this is so that you only need to compute the PDF once and diff --git a/roofit/roofit/inc/RooCFunction1Binding.h b/roofit/roofit/inc/RooCFunction1Binding.h index 330b5de0016f3..a4f07f95ff0d8 100644 --- a/roofit/roofit/inc/RooCFunction1Binding.h +++ b/roofit/roofit/inc/RooCFunction1Binding.h @@ -28,14 +28,10 @@ namespace RooFit { typedef Double_t (*CFUNCD1D)(Double_t) ; typedef Double_t (*CFUNCD1I)(Int_t) ; -RooAbsReal* bindFunction(const char* name,void* func,RooAbsReal& x) ; -RooAbsPdf* bindPdf(const char* name,void* func,RooAbsReal& x) ; -#ifndef __CINT__ RooAbsReal* bindFunction(const char* name,CFUNCD1D func,RooAbsReal& x) ; RooAbsReal* bindFunction(const char* name,CFUNCD1I func,RooAbsReal& x) ; RooAbsPdf* bindPdf(const char* name,CFUNCD1D func,RooAbsReal& x) ; RooAbsPdf* bindPdf(const char* name,CFUNCD1I func,RooAbsReal& x) ; -#endif } @@ -123,13 +119,7 @@ class RooCFunction1Ref : public TObject { return fmap().lookupArgName(_ptr,iarg) ; } - static RooCFunction1Map<VO,VI>& fmap() { - // Return reference to function pointer-to-name mapping service - if (!_fmap) { - _fmap = new RooCFunction1Map<VO,VI> ; - } - return *_fmap ; - } + static RooCFunction1Map<VO,VI>& fmap(); private: @@ -153,7 +143,7 @@ template<class VO, class VI> void RooCFunction1Ref<VO,VI>::Streamer(TBuffer &R__b) { // Custom streamer for function pointer reference object. When writing, - // the function pointer is substituted by its registerd name. When function + // the function pointer is substituted by its registered name. When function // is unregistered name 'UNKNOWN' is written and a warning is issues. When // reading back, the embedded name is converted back to a function pointer // using the mapping service. When name UNKNOWN is encountered a warning is @@ -175,7 +165,7 @@ void RooCFunction1Ref<VO,VI>::Streamer(TBuffer &R__b) if (tmpName=="UNKNOWN" && R__v>0) { - coutW(ObjectHandling) << "WARNING: Objected embeds function pointer to unknown function, object will not be functional" << endl ; + coutW(ObjectHandling) << "WARNING: Objected embeds function pointer to unknown function, object will not be functional" << std::endl ; _ptr = dummyFunction ; } else { @@ -185,7 +175,7 @@ void RooCFunction1Ref<VO,VI>::Streamer(TBuffer &R__b) if (_ptr==0) { coutW(ObjectHandling) << "ERROR: Objected embeds pointer to function named " << tmpName - << " but no such function is registered, object will not be functional" << endl ; + << " but no such function is registered, object will not be functional" << std::endl ; } } @@ -207,7 +197,7 @@ void RooCFunction1Ref<VO,VI>::Streamer(TBuffer &R__b) } temp; temp._funcptr = _ptr; coutW(ObjectHandling) << "WARNING: Cannot persist unknown function pointer " << Form("%p",temp._ptr) - << " written object will not be functional when read back" << endl ; + << " written object will not be functional when read back" << std::endl ; tmpName="UNKNOWN" ; } @@ -232,7 +222,7 @@ class RooCFunction1Binding : public RooAbsReal { virtual TObject* clone(const char* newname) const { return new RooCFunction1Binding(*this,newname); } inline virtual ~RooCFunction1Binding() { } - void printArgs(ostream& os) const { + void printArgs(std::ostream& os) const { // Print object arguments and name/address of function pointer os << "[ function=" << func.name() << " " ; for (Int_t i=0 ; i<numProxies() ; i++) { @@ -296,7 +286,7 @@ class RooCFunction1PdfBinding : public RooAbsPdf { virtual TObject* clone(const char* newname) const { return new RooCFunction1PdfBinding(*this,newname); } inline virtual ~RooCFunction1PdfBinding() { } - void printArgs(ostream& os) const { + void printArgs(std::ostream& os) const { // Print object arguments and name/address of function pointer os << "[ function=" << func.name() << " " ; for (Int_t i=0 ; i<numProxies() ; i++) { diff --git a/roofit/roofit/inc/RooCFunction2Binding.h b/roofit/roofit/inc/RooCFunction2Binding.h index fa796c48ce1df..3b655e0928c0b 100644 --- a/roofit/roofit/inc/RooCFunction2Binding.h +++ b/roofit/roofit/inc/RooCFunction2Binding.h @@ -31,9 +31,6 @@ typedef Double_t (*CFUNCD2DI)(Double_t,Int_t) ; typedef Double_t (*CFUNCD2II)(Int_t,Int_t) ; -RooAbsReal* bindFunction(const char* name,void* func,RooAbsReal& x, RooAbsReal& y) ; -RooAbsPdf* bindPdf(const char* name,void* func,RooAbsReal& x, RooAbsReal& y) ; -#ifndef __CINT__ RooAbsReal* bindFunction(const char* name,CFUNCD2DD func,RooAbsReal& x, RooAbsReal& y) ; RooAbsReal* bindFunction(const char* name,CFUNCD2ID func,RooAbsReal& x, RooAbsReal& y) ; RooAbsReal* bindFunction(const char* name,CFUNCD2UD func,RooAbsReal& x, RooAbsReal& y) ; @@ -44,7 +41,6 @@ RooAbsPdf* bindPdf(const char* name,CFUNCD2ID func,RooAbsReal& x, RooAbsReal& y) RooAbsPdf* bindPdf(const char* name,CFUNCD2UD func,RooAbsReal& x, RooAbsReal& y) ; RooAbsPdf* bindPdf(const char* name,CFUNCD2DI func,RooAbsReal& x, RooAbsReal& y) ; RooAbsPdf* bindPdf(const char* name,CFUNCD2II func,RooAbsReal& x, RooAbsReal& y) ; -#endif } @@ -184,7 +180,7 @@ void RooCFunction2Ref<VO,VI1,VI2>::Streamer(TBuffer &R__b) if (tmpName=="UNKNOWN" && R__v>0) { - coutW(ObjectHandling) << "WARNING: Objected embeds function pointer to unknown function, object will not be functional" << endl ; + coutW(ObjectHandling) << "WARNING: Objected embeds function pointer to unknown function, object will not be functional" << std::endl ; _ptr = dummyFunction ; } else { @@ -194,7 +190,7 @@ void RooCFunction2Ref<VO,VI1,VI2>::Streamer(TBuffer &R__b) if (_ptr==0) { coutW(ObjectHandling) << "ERROR: Objected embeds pointer to function named " << tmpName - << " but no such function is registered, object will not be functional" << endl ; + << " but no such function is registered, object will not be functional" << std::endl ; } } @@ -210,7 +206,7 @@ void RooCFunction2Ref<VO,VI1,VI2>::Streamer(TBuffer &R__b) TString tmpName = fmap().lookupName(_ptr) ; if (tmpName.Length()==0) { coutW(ObjectHandling) << "WARNING: Cannot persist unknown function pointer " << Form("0x%lx", (ULong_t)_ptr) - << " written object will not be functional when read back" << endl ; + << " written object will not be functional when read back" << std::endl ; tmpName="UNKNOWN" ; } @@ -235,7 +231,7 @@ class RooCFunction2Binding : public RooAbsReal { virtual TObject* clone(const char* newname) const { return new RooCFunction2Binding(*this,newname); } inline virtual ~RooCFunction2Binding() { } - void printArgs(ostream& os) const { + void printArgs(std::ostream& os) const { // Print object arguments and name/address of function pointer os << "[ function=" << func.name() << " " ; for (Int_t i=0 ; i<numProxies() ; i++) { @@ -303,7 +299,7 @@ class RooCFunction2PdfBinding : public RooAbsPdf { virtual TObject* clone(const char* newname) const { return new RooCFunction2PdfBinding(*this,newname); } inline virtual ~RooCFunction2PdfBinding() { } - void printArgs(ostream& os) const { + void printArgs(std::ostream& os) const { // Print object arguments and name/address of function pointer os << "[ function=" << func.name() << " " ; for (Int_t i=0 ; i<numProxies() ; i++) { diff --git a/roofit/roofit/inc/RooCFunction3Binding.h b/roofit/roofit/inc/RooCFunction3Binding.h index d614d1ffad992..ba287102eaf78 100644 --- a/roofit/roofit/inc/RooCFunction3Binding.h +++ b/roofit/roofit/inc/RooCFunction3Binding.h @@ -31,9 +31,6 @@ typedef Double_t (*CFUNCD3UDU)(UInt_t,Double_t,UInt_t) ; typedef Double_t (*CFUNCD3UDD)(UInt_t,Double_t,Double_t) ; typedef Double_t (*CFUNCD3UUD)(UInt_t,UInt_t,Double_t) ; -RooAbsReal* bindFunction(const char* name,void* func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z) ; -RooAbsPdf* bindPdf(const char* name,void* func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z) ; -#ifndef __CINT__ RooAbsReal* bindFunction(const char* name,CFUNCD3DDD func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z) ; RooAbsReal* bindFunction(const char* name,CFUNCD3DDB func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z) ; RooAbsReal* bindFunction(const char* name,CFUNCD3DII func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z) ; @@ -46,7 +43,6 @@ RooAbsPdf* bindPdf(const char* name,CFUNCD3DII func,RooAbsReal& x, RooAbsReal& y RooAbsPdf* bindPdf(const char* name,CFUNCD3UDU func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z) ; RooAbsPdf* bindPdf(const char* name,CFUNCD3UDD func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z) ; RooAbsPdf* bindPdf(const char* name,CFUNCD3UUD func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z) ; -#endif } @@ -188,7 +184,7 @@ void RooCFunction3Ref<VO,VI1,VI2,VI3>::Streamer(TBuffer &R__b) if (tmpName=="UNKNOWN" && R__v>0) { - coutW(ObjectHandling) << "WARNING: Objected embeds function pointer to unknown function, object will not be functional" << endl ; + coutW(ObjectHandling) << "WARNING: Objected embeds function pointer to unknown function, object will not be functional" << std::endl ; _ptr = dummyFunction ; } else { @@ -198,7 +194,7 @@ void RooCFunction3Ref<VO,VI1,VI2,VI3>::Streamer(TBuffer &R__b) if (_ptr==0) { coutW(ObjectHandling) << "ERROR: Objected embeds pointer to function named " << tmpName - << " but no such function is registered, object will not be functional" << endl ; + << " but no such function is registered, object will not be functional" << std::endl ; } } @@ -220,7 +216,7 @@ void RooCFunction3Ref<VO,VI1,VI2,VI3>::Streamer(TBuffer &R__b) } temp; temp._funcptr = _ptr; coutW(ObjectHandling) << "WARNING: Cannot persist unknown function pointer " << Form("%p",temp._ptr) - << " written object will not be functional when read back" << endl ; + << " written object will not be functional when read back" << std::endl ; tmpName="UNKNOWN" ; } @@ -245,7 +241,7 @@ class RooCFunction3Binding : public RooAbsReal { virtual TObject* clone(const char* newname) const { return new RooCFunction3Binding(*this,newname); } inline virtual ~RooCFunction3Binding() { } - void printArgs(ostream& os) const { + void printArgs(std::ostream& os) const { // Print object arguments and name/address of function pointer os << "[ function=" << func.name() << " " ; for (Int_t i=0 ; i<numProxies() ; i++) { @@ -316,7 +312,7 @@ class RooCFunction3PdfBinding : public RooAbsPdf { virtual TObject* clone(const char* newname) const { return new RooCFunction3PdfBinding(*this,newname); } inline virtual ~RooCFunction3PdfBinding() { } - void printArgs(ostream& os) const { + void printArgs(std::ostream& os) const { // Print object arguments and name/address of function pointer os << "[ function=" << func.name() << " " ; for (Int_t i=0 ; i<numProxies() ; i++) { diff --git a/roofit/roofit/inc/RooCFunction4Binding.h b/roofit/roofit/inc/RooCFunction4Binding.h index feef876df0692..b4ef55921e505 100644 --- a/roofit/roofit/inc/RooCFunction4Binding.h +++ b/roofit/roofit/inc/RooCFunction4Binding.h @@ -28,16 +28,12 @@ typedef Double_t (*CFUNCD4DDDD)(Double_t,Double_t,Double_t,Double_t) ; typedef Double_t (*CFUNCD4DDDI)(Double_t,Double_t,Double_t,Int_t) ; typedef Double_t (*CFUNCD4DDDB)(Double_t,Double_t,Double_t,Bool_t) ; -RooAbsReal* bindFunction(const char* name,void* func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z, RooAbsReal& w) ; -RooAbsPdf* bindPdf(const char* name,void* func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z, RooAbsReal& w) ; -#ifndef __CINT__ RooAbsReal* bindFunction(const char* name,CFUNCD4DDDD func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z, RooAbsReal& w) ; RooAbsReal* bindFunction(const char* name,CFUNCD4DDDI func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z, RooAbsReal& w) ; RooAbsReal* bindFunction(const char* name,CFUNCD4DDDB func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z, RooAbsReal& w) ; RooAbsPdf* bindPdf(const char* name,CFUNCD4DDDD func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z, RooAbsReal& w) ; RooAbsPdf* bindPdf(const char* name,CFUNCD4DDDI func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z, RooAbsReal& w) ; RooAbsPdf* bindPdf(const char* name,CFUNCD4DDDB func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z, RooAbsReal& w) ; -#endif } @@ -182,7 +178,7 @@ void RooCFunction4Ref<VO,VI1,VI2,VI3,VI4>::Streamer(TBuffer &R__b) if (tmpName=="UNKNOWN" && R__v>0) { - coutW(ObjectHandling) << "WARNING: Objected embeds function pointer to unknown function, object will not be functional" << endl ; + coutW(ObjectHandling) << "WARNING: Objected embeds function pointer to unknown function, object will not be functional" << std::endl ; _ptr = dummyFunction ; } else { @@ -192,7 +188,7 @@ void RooCFunction4Ref<VO,VI1,VI2,VI3,VI4>::Streamer(TBuffer &R__b) if (_ptr==0) { coutW(ObjectHandling) << "ERROR: Objected embeds pointer to function named " << tmpName - << " but no such function is registered, object will not be functional" << endl ; + << " but no such function is registered, object will not be functional" << std::endl ; } } @@ -208,7 +204,7 @@ void RooCFunction4Ref<VO,VI1,VI2,VI3,VI4>::Streamer(TBuffer &R__b) TString tmpName = fmap().lookupName(_ptr) ; if (tmpName.Length()==0) { coutW(ObjectHandling) << "WARNING: Cannot persist unknown function pointer " << Form("0x%lx",(ULong_t)_ptr) - << " written object will not be functional when read back" << endl ; + << " written object will not be functional when read back" << std::endl ; tmpName="UNKNOWN" ; } @@ -233,7 +229,7 @@ class RooCFunction4Binding : public RooAbsReal { virtual TObject* clone(const char* newname) const { return new RooCFunction4Binding(*this,newname); } inline virtual ~RooCFunction4Binding() { } - void printArgs(ostream& os) const { + void printArgs(std::ostream& os) const { // Print object arguments and name/address of function pointer os << "[ function=" << func.name() << " " ; for (Int_t i=0 ; i<numProxies() ; i++) { @@ -306,7 +302,7 @@ class RooCFunction4PdfBinding : public RooAbsPdf { virtual TObject* clone(const char* newname) const { return new RooCFunction4PdfBinding(*this,newname); } inline virtual ~RooCFunction4PdfBinding() { } - void printArgs(ostream& os) const { + void printArgs(std::ostream& os) const { // Print object arguments and name/address of function pointer os << "[ function=" << func.name() << " " ; for (Int_t i=0 ; i<numProxies() ; i++) { diff --git a/roofit/roofit/inc/RooChebychev.h b/roofit/roofit/inc/RooChebychev.h index 48460c2167d06..d270133a004fc 100644 --- a/roofit/roofit/inc/RooChebychev.h +++ b/roofit/roofit/inc/RooChebychev.h @@ -42,6 +42,7 @@ class RooChebychev : public RooAbsPdf { RooListProxy _coefList ; Double_t evaluate() const; + Double_t evalAnaInt(const Double_t x) const; ClassDef(RooChebychev,1) // Chebychev polynomial PDF }; diff --git a/roofit/roofit/inc/RooFunctor1DBinding.h b/roofit/roofit/inc/RooFunctor1DBinding.h index 5fa448aa578f0..90eeea3daaea2 100644 --- a/roofit/roofit/inc/RooFunctor1DBinding.h +++ b/roofit/roofit/inc/RooFunctor1DBinding.h @@ -43,7 +43,7 @@ class RooFunctor1DBinding : public RooAbsReal { RooFunctor1DBinding(const RooFunctor1DBinding& other, const char* name=0) ; virtual TObject* clone(const char* newname) const { return new RooFunctor1DBinding(*this,newname); } inline virtual ~RooFunctor1DBinding() {} - void printArgs(ostream& os) const ; + void printArgs(std::ostream& os) const ; protected: @@ -69,7 +69,7 @@ class RooFunctor1DPdfBinding : public RooAbsPdf { RooFunctor1DPdfBinding(const RooFunctor1DPdfBinding& other, const char* name=0) ; virtual TObject* clone(const char* newname) const { return new RooFunctor1DPdfBinding(*this,newname); } inline virtual ~RooFunctor1DPdfBinding() {} - void printArgs(ostream& os) const ; + void printArgs(std::ostream& os) const ; protected: diff --git a/roofit/roofit/inc/RooFunctorBinding.h b/roofit/roofit/inc/RooFunctorBinding.h index ccf3531380845..de1e201edd433 100644 --- a/roofit/roofit/inc/RooFunctorBinding.h +++ b/roofit/roofit/inc/RooFunctorBinding.h @@ -43,7 +43,7 @@ class RooFunctorBinding : public RooAbsReal { RooFunctorBinding(const RooFunctorBinding& other, const char* name=0) ; virtual TObject* clone(const char* newname) const { return new RooFunctorBinding(*this,newname); } inline virtual ~RooFunctorBinding() { delete[] x ; } - void printArgs(ostream& os) const ; + void printArgs(std::ostream& os) const ; protected: @@ -70,7 +70,7 @@ class RooFunctorPdfBinding : public RooAbsPdf { RooFunctorPdfBinding(const RooFunctorPdfBinding& other, const char* name=0) ; virtual TObject* clone(const char* newname) const { return new RooFunctorPdfBinding(*this,newname); } inline virtual ~RooFunctorPdfBinding() { delete[] x ; } - void printArgs(ostream& os) const ; + void printArgs(std::ostream& os) const ; protected: diff --git a/roofit/roofit/inc/RooGExpModel.h b/roofit/roofit/inc/RooGExpModel.h index c3d36fea5923d..7e2d01c9239fb 100644 --- a/roofit/roofit/inc/RooGExpModel.h +++ b/roofit/roofit/inc/RooGExpModel.h @@ -16,9 +16,12 @@ #ifndef ROO_GEXP_MODEL #define ROO_GEXP_MODEL +#include <cmath> +#include <complex> + +#include "Rtypes.h" #include "RooResolutionModel.h" #include "RooRealProxy.h" -#include "RooComplex.h" #include "RooMath.h" class RooGExpModel : public RooResolutionModel { @@ -76,35 +79,24 @@ class RooGExpModel : public RooResolutionModel { //Double_t calcDecayConv(Double_t sign, Double_t tau, Double_t sig, Double_t rtau) const ; Double_t calcDecayConv(Double_t sign, Double_t tau, Double_t sig, Double_t rtau, Double_t fsign) const ; // modified FMV,08/13/03 - RooComplex calcSinConv(Double_t sign, Double_t sig, Double_t tau, Double_t omega, Double_t rtau, Double_t fsign) const ; + std::complex<Double_t> calcSinConv(Double_t sign, Double_t sig, Double_t tau, Double_t omega, Double_t rtau, Double_t fsign) const ; Double_t calcSinConv(Double_t sign, Double_t sig, Double_t tau, Double_t rtau, Double_t fsign) const ; - RooComplex calcSinConvNorm(Double_t sign, Double_t tau, Double_t omega, + std::complex<Double_t> calcSinConvNorm(Double_t sign, Double_t tau, Double_t omega, Double_t sig, Double_t rtau, Double_t fsign, const char* rangeName) const ; // modified FMV,07/24/03 Double_t calcSinConvNorm(Double_t sign, Double_t tau, Double_t sig, Double_t rtau, Double_t fsign, const char* rangeName) const ; // added FMV,08/18/03 //Double_t calcSinhConv(Double_t sign, Double_t sign1, Double_t sign2, Double_t tau, Double_t dgamma, Double_t sig, Double_t rtau, Double_t fsign) const ; //Double_t calcCoshConv(Double_t sign, Double_t tau, Double_t dgamma, Double_t sig, Double_t rtau, Double_t fsign) const ; virtual Double_t evaluate() const ; - RooComplex evalCerfApprox(Double_t swt, Double_t u, Double_t c) const ; + static std::complex<Double_t> evalCerfApprox(Double_t swt, Double_t u, Double_t c); // Calculate exp(-u^2) cwerf(swt*c + i(u+c)), taking care of numerical instabilities - inline RooComplex evalCerf(Double_t swt, Double_t u, Double_t c) const { - RooComplex z(swt*c,u+c); - return (z.im()>-4.0) ? RooMath::FastComplexErrFunc(z)*exp(-u*u) : evalCerfApprox(swt,u,c) ; + static inline std::complex<Double_t> evalCerf(Double_t swt, Double_t u, Double_t c) + { + std::complex<Double_t> z(swt*c,u+c); + return (z.imag()>-4.0) ? RooMath::faddeeva_fast(z)*std::exp(-u*u) : evalCerfApprox(swt,u,c) ; } - // Calculate Re(exp(-u^2) cwerf(swt*c + i(u+c))), taking care of numerical instabilities - inline Double_t evalCerfRe(Double_t swt, Double_t u, Double_t c) const { - RooComplex z(swt*c,u+c); - return (z.im()>-4.0) ? RooMath::FastComplexErrFuncRe(z)*exp(-u*u) : evalCerfApprox(swt,u,c).re() ; - } - - // Calculate Im(exp(-u^2) cwerf(swt*c + i(u+c))), taking care of numerical instabilities - inline Double_t evalCerfIm(Double_t swt, Double_t u, Double_t c) const { - RooComplex z(swt*c,u+c); - return (z.im()>-4.0) ? RooMath::FastComplexErrFuncIm(z)*exp(-u*u) : evalCerfApprox(swt,u,c).im() ; - } - // Calculate Re(exp(-u^2) cwerf(i(u+c))) // added FMV, 08/17/03 inline Double_t evalCerfRe(Double_t u, Double_t c) const { @@ -118,7 +110,7 @@ class RooGExpModel : public RooResolutionModel { // Calculate common normalization factors // added FMV,07/24/03 - RooComplex evalCerfInt(Double_t sign, Double_t wt, Double_t tau, Double_t umin, Double_t umax, Double_t c) const ; + std::complex<Double_t> evalCerfInt(Double_t sign, Double_t wt, Double_t tau, Double_t umin, Double_t umax, Double_t c) const ; Double_t evalCerfInt(Double_t sign, Double_t tau, Double_t umin, Double_t umax, Double_t c) const ; RooRealProxy sigma ; diff --git a/roofit/roofit/inc/RooGaussModel.h b/roofit/roofit/inc/RooGaussModel.h index d8297d71eaf57..28960683ec099 100644 --- a/roofit/roofit/inc/RooGaussModel.h +++ b/roofit/roofit/inc/RooGaussModel.h @@ -16,9 +16,11 @@ #ifndef ROO_GAUSS_MODEL #define ROO_GAUSS_MODEL +#include <cmath> +#include <complex> + #include "RooResolutionModel.h" #include "RooRealProxy.h" -#include "RooComplex.h" #include "RooMath.h" class RooGaussModel : public RooResolutionModel { @@ -61,28 +63,17 @@ class RooGaussModel : public RooResolutionModel { protected: virtual Double_t evaluate() const ; - RooComplex evalCerfApprox(Double_t swt, Double_t u, Double_t c) const ; + static std::complex<Double_t> evalCerfApprox(Double_t swt, Double_t u, Double_t c); // Calculate exp(-u^2) cwerf(swt*c + i(u+c)), taking care of numerical instabilities - inline RooComplex evalCerf(Double_t swt, Double_t u, Double_t c) const { - RooComplex z(swt*c,u+c); - return (z.im()>-4.0) ? RooMath::FastComplexErrFunc(z)*exp(-u*u) : evalCerfApprox(swt,u,c) ; + static inline std::complex<Double_t> evalCerf(Double_t swt, Double_t u, Double_t c) + { + std::complex<Double_t> z(swt*c,u+c); + return (z.imag()>-4.0) ? (std::exp(-u*u)*RooMath::faddeeva_fast(z)) : evalCerfApprox(swt,u,c); } - // Calculate Re(exp(-u^2) cwerf(swt*c + i(u+c))), taking care of numerical instabilities - inline Double_t evalCerfRe(Double_t swt, Double_t u, Double_t c) const { - RooComplex z(swt*c,u+c); - return (z.im()>-4.0) ? RooMath::FastComplexErrFuncRe(z)*exp(-u*u) : evalCerfApprox(swt,u,c).re() ; - } - - // Calculate Im(exp(-u^2) cwerf(swt*c + i(u+c))), taking care of numerical instabilities - inline Double_t evalCerfIm(Double_t swt, Double_t u, Double_t c) const { - RooComplex z(swt*c,u+c); - return (z.im()>-4.0) ? RooMath::FastComplexErrFuncIm(z)*exp(-u*u) : evalCerfApprox(swt,u,c).im() ; - } - // Calculate common normalization factors - RooComplex evalCerfInt(Double_t sign, Double_t wt, Double_t tau, Double_t umin, Double_t umax, Double_t c) const ; + std::complex<Double_t> evalCerfInt(Double_t sign, Double_t wt, Double_t tau, Double_t umin, Double_t umax, Double_t c) const; Bool_t _flatSFInt ; diff --git a/roofit/roofit/inc/RooGaussian.h b/roofit/roofit/inc/RooGaussian.h index b1237ad722675..6b9f43c6c872e 100644 --- a/roofit/roofit/inc/RooGaussian.h +++ b/roofit/roofit/inc/RooGaussian.h @@ -36,6 +36,8 @@ class RooGaussian : public RooAbsPdf { Int_t getGenerator(const RooArgSet& directVars, RooArgSet &generateVars, Bool_t staticInitOK=kTRUE) const; void generateEvent(Int_t code); + Double_t getLogVal(const RooArgSet* set) const ; + protected: RooRealProxy x ; diff --git a/roofit/roofit/inc/RooKeysPdf.h b/roofit/roofit/inc/RooKeysPdf.h index 6c5662a2438aa..b94915c2c54d6 100644 --- a/roofit/roofit/inc/RooKeysPdf.h +++ b/roofit/roofit/inc/RooKeysPdf.h @@ -32,9 +32,18 @@ class RooKeysPdf : public RooAbsPdf { RooKeysPdf(const char *name, const char *title, RooAbsReal& x, RooDataSet& data, Mirror mirror= NoMirror, Double_t rho=1); + RooKeysPdf(const char *name, const char *title, + RooAbsReal& x, RooRealVar& xdata, RooDataSet& data, Mirror mirror= NoMirror, + Double_t rho=1); RooKeysPdf(const RooKeysPdf& other, const char* name=0); virtual TObject* clone(const char* newname) const {return new RooKeysPdf(*this,newname); } virtual ~RooKeysPdf(); + + virtual Int_t getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVars, + const char* rangeName = 0) const; + virtual Double_t analyticalIntegral(Int_t code, const char* rangeName = 0) const; + virtual Int_t getMaxVal(const RooArgSet& vars) const; + virtual Double_t maxVal(Int_t code) const; void LoadDataSet( RooDataSet& data); diff --git a/roofit/roofit/inc/RooMomentMorph.h b/roofit/roofit/inc/RooMomentMorph.h index d770c79cff992..fbed5297c60cd 100644 --- a/roofit/roofit/inc/RooMomentMorph.h +++ b/roofit/roofit/inc/RooMomentMorph.h @@ -26,7 +26,7 @@ class RooChangeTracker ; class RooMomentMorph : public RooAbsPdf { public: - enum Setting { Linear, NonLinear, NonLinearPosFractions, NonLinearLinFractions } ; + enum Setting { Linear, NonLinear, NonLinearPosFractions, NonLinearLinFractions, SineLinear } ; RooMomentMorph() ; @@ -40,6 +40,8 @@ class RooMomentMorph : public RooAbsPdf { void setMode(const Setting& setting) { _setting = setting; } + void useHorizontalMorphing(bool val) { _useHorizMorph = val; } + virtual Bool_t selfNormalized() const { // P.d.f is self normalized return kTRUE ; @@ -48,6 +50,7 @@ class RooMomentMorph : public RooAbsPdf { virtual Double_t getVal(const RooArgSet* set=0) const ; RooAbsPdf* sumPdf(const RooArgSet* nset) ; + protected: class CacheElem : public RooAbsCacheElement { @@ -89,7 +92,9 @@ class RooMomentMorph : public RooAbsPdf { Setting _setting; - ClassDef(RooMomentMorph,1) // Your description goes here... + bool _useHorizMorph; + + ClassDef(RooMomentMorph,3) // Your description goes here... }; #endif diff --git a/roofit/roofit/inc/RooMultiBinomial.h b/roofit/roofit/inc/RooMultiBinomial.h index 0bfd6c019abaa..37c887dab5a14 100644 --- a/roofit/roofit/inc/RooMultiBinomial.h +++ b/roofit/roofit/inc/RooMultiBinomial.h @@ -13,7 +13,7 @@ * listed in LICENSE (http://roofit.sourceforge.net/license.txt) * *****************************************************************************/ #ifndef ROO_MULTIBINOMIAL -#define ROO_MUTLIBINOMIAL +#define ROO_MULTIBINOMIAL #include "RooAbsReal.h" #include "RooListProxy.h" diff --git a/roofit/roofit/inc/RooNDKeysPdf.h b/roofit/roofit/inc/RooNDKeysPdf.h index eb291ad4299d8..004d1a4a30a23 100644 --- a/roofit/roofit/inc/RooNDKeysPdf.h +++ b/roofit/roofit/inc/RooNDKeysPdf.h @@ -1,7 +1,7 @@ /***************************************************************************** * Project: RooFit * * Package: RooFitModels * - * File: $Id$ + * File: $Id: RooNDKeysPdf.h 44368 2012-05-30 15:38:44Z axel $ * Authors: * * Max Baak, CERN, mbaak@cern.ch * * * @@ -12,8 +12,8 @@ * with or without modification, are permitted according to the terms * * listed in LICENSE (http://roofit.sourceforge.net/license.txt) * *****************************************************************************/ -#ifndef ROO_KEYS_PDF -#define ROO_KEYS_PDF +#ifndef ROO_NDKEYS_PDF +#define ROO_NDKEYS_PDF #include "RooAbsPdf.h" #include "RooRealProxy.h" @@ -56,6 +56,10 @@ class RooNDKeysPdf : public RooAbsPdf { const RooArgList& varList, RooDataSet& data, TString options="a", Double_t rho=1, Double_t nSigma=3, Bool_t rotate=kTRUE) ; + RooNDKeysPdf(const char *name, const char *title, + const RooArgList& varList, RooDataSet& data, const TVectorD& rho, + TString options="a", Double_t nSigma=3, Bool_t rotate=kTRUE) ; + RooNDKeysPdf(const char *name, const char *title, RooAbsReal& x, RooDataSet& data, Mirror mirror= NoMirror, Double_t rho=1, Double_t nSigma=3, Bool_t rotate=kTRUE) ; @@ -139,11 +143,11 @@ class RooNDKeysPdf : public RooAbsPdf { mutable std::vector<std::vector<Double_t> >* _weights; //! #ifndef __CINT__ - mutable std::vector<iiVec> _sortIdcs; - mutable std::vector<itVec> _sortTVIdcs; + mutable std::vector<iiVec> _sortIdcs; //! + mutable std::vector<itVec> _sortTVIdcs; //! #endif - mutable std::vector<string> _varName; + mutable std::vector<std::string> _varName; mutable std::vector<Double_t> _rho; mutable RooArgSet _dataVars; mutable std::vector<Double_t> _x; @@ -191,7 +195,7 @@ class RooNDKeysPdf : public RooAbsPdf { } }; - ClassDef(RooNDKeysPdf,0) // General N-dimensional non-parametric kernel estimation p.d.f + ClassDef(RooNDKeysPdf,1) // General N-dimensional non-parametric kernel estimation p.d.f }; #endif diff --git a/roofit/roofit/inc/RooNovosibirsk.h b/roofit/roofit/inc/RooNovosibirsk.h index 3f2bbb79a9717..faabe94974235 100644 --- a/roofit/roofit/inc/RooNovosibirsk.h +++ b/roofit/roofit/inc/RooNovosibirsk.h @@ -37,6 +37,9 @@ class RooNovosibirsk : public RooAbsPdf { virtual TObject* clone(const char* newname) const { return new RooNovosibirsk(*this,newname); } + Int_t getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVars, const char* rangeName=0) const ; + Double_t analyticalIntegral(Int_t code, const char* rangeName=0) const ; + // An empty constructor is usually ok inline virtual ~RooNovosibirsk() { } diff --git a/roofit/roofit/inc/RooPoisson.h b/roofit/roofit/inc/RooPoisson.h index 954e643efa6d9..fdf1939abcb7e 100644 --- a/roofit/roofit/inc/RooPoisson.h +++ b/roofit/roofit/inc/RooPoisson.h @@ -32,6 +32,8 @@ class RooPoisson : public RooAbsPdf { void setNoRounding(bool flag = kTRUE){_noRounding = flag;} void protectNegativeMean(bool flag = kTRUE){_protectNegative = flag;} + Double_t getLogVal(const RooArgSet* set=0) const ; + protected: RooRealProxy x ; diff --git a/roofit/roofit/inc/RooTFnBinding.h b/roofit/roofit/inc/RooTFnBinding.h index 275dd6d0dd26f..6017abd2f5200 100644 --- a/roofit/roofit/inc/RooTFnBinding.h +++ b/roofit/roofit/inc/RooTFnBinding.h @@ -23,7 +23,7 @@ class RooTFnBinding : public RooAbsReal { virtual TObject* clone(const char* newname) const { return new RooTFnBinding(*this,newname); } inline virtual ~RooTFnBinding() { } - void printArgs(ostream& os) const ; + void printArgs(std::ostream& os) const ; protected: diff --git a/roofit/roofit/inc/RooTFnPdfBinding.h b/roofit/roofit/inc/RooTFnPdfBinding.h index caff266d38872..23c84172a753f 100644 --- a/roofit/roofit/inc/RooTFnPdfBinding.h +++ b/roofit/roofit/inc/RooTFnPdfBinding.h @@ -21,7 +21,7 @@ class RooTFnPdfBinding : public RooAbsPdf { virtual TObject* clone(const char* newname) const { return new RooTFnPdfBinding(*this,newname); } inline virtual ~RooTFnPdfBinding() { } - void printArgs(ostream& os) const ; + void printArgs(std::ostream& os) const ; protected: diff --git a/roofit/roofit/src/Roo1DMomentMorphFunction.cxx b/roofit/roofit/src/Roo1DMomentMorphFunction.cxx index 7e1b8a92503ad..ab80fd4f57541 100644 --- a/roofit/roofit/src/Roo1DMomentMorphFunction.cxx +++ b/roofit/roofit/src/Roo1DMomentMorphFunction.cxx @@ -27,6 +27,8 @@ #include "TMath.h" +using namespace std; + ClassImp(Roo1DMomentMorphFunction) diff --git a/roofit/roofit/src/Roo2DKeysPdf.cxx b/roofit/roofit/src/Roo2DKeysPdf.cxx index 805249401a9b4..73bc20905143b 100644 --- a/roofit/roofit/src/Roo2DKeysPdf.cxx +++ b/roofit/roofit/src/Roo2DKeysPdf.cxx @@ -37,6 +37,8 @@ //#include <math.h> +using namespace std; + ClassImp(Roo2DKeysPdf) diff --git a/roofit/roofit/src/Roo2DMomentMorphFunction.cxx b/roofit/roofit/src/Roo2DMomentMorphFunction.cxx index a5d62066d6284..51fb44e00ce13 100644 --- a/roofit/roofit/src/Roo2DMomentMorphFunction.cxx +++ b/roofit/roofit/src/Roo2DMomentMorphFunction.cxx @@ -65,6 +65,8 @@ */ +using namespace std; + ClassImp(Roo2DMomentMorphFunction) diff --git a/roofit/roofit/src/RooArgusBG.cxx b/roofit/roofit/src/RooArgusBG.cxx index 3133a5bc12ebd..1ccaf704bcf76 100644 --- a/roofit/roofit/src/RooArgusBG.cxx +++ b/roofit/roofit/src/RooArgusBG.cxx @@ -33,6 +33,8 @@ #include "RooMath.h" #include "TMath.h" +using namespace std; + ClassImp(RooArgusBG) diff --git a/roofit/roofit/src/RooBCPEffDecay.cxx b/roofit/roofit/src/RooBCPEffDecay.cxx index 6d33a14f92bfa..86793cd315301 100644 --- a/roofit/roofit/src/RooBCPEffDecay.cxx +++ b/roofit/roofit/src/RooBCPEffDecay.cxx @@ -32,6 +32,8 @@ #include "RooBCPEffDecay.h" #include "RooRealIntegral.h" +using namespace std; + ClassImp(RooBCPEffDecay) ; diff --git a/roofit/roofit/src/RooBCPGenDecay.cxx b/roofit/roofit/src/RooBCPGenDecay.cxx index ccb44ca97a8e9..f1710d04884d3 100644 --- a/roofit/roofit/src/RooBCPGenDecay.cxx +++ b/roofit/roofit/src/RooBCPGenDecay.cxx @@ -34,6 +34,8 @@ #include "RooBCPGenDecay.h" #include "RooRealIntegral.h" +using namespace std; + ClassImp(RooBCPGenDecay) ; diff --git a/roofit/roofit/src/RooBDecay.cxx b/roofit/roofit/src/RooBDecay.cxx index e75e6fdb92247..6cf1d536c8059 100644 --- a/roofit/roofit/src/RooBDecay.cxx +++ b/roofit/roofit/src/RooBDecay.cxx @@ -34,6 +34,8 @@ #include "RooRealVar.h" #include "RooRandom.h" +using namespace std; + ClassImp(RooBDecay); diff --git a/roofit/roofit/src/RooBMixDecay.cxx b/roofit/roofit/src/RooBMixDecay.cxx index be9c66c18e1f8..88d456ad2b027 100644 --- a/roofit/roofit/src/RooBMixDecay.cxx +++ b/roofit/roofit/src/RooBMixDecay.cxx @@ -32,6 +32,8 @@ #include "RooRealIntegral.h" #include "RooRandom.h" +using namespace std; + ClassImp(RooBMixDecay) ; diff --git a/roofit/roofit/src/RooBernstein.cxx b/roofit/roofit/src/RooBernstein.cxx index 889415f65d2c8..52bc7b5f6d18d 100644 --- a/roofit/roofit/src/RooBernstein.cxx +++ b/roofit/roofit/src/RooBernstein.cxx @@ -32,6 +32,8 @@ #include "RooRealVar.h" #include "RooArgList.h" +using namespace std; + ClassImp(RooBernstein) ; @@ -78,18 +80,45 @@ RooBernstein::RooBernstein(const RooBernstein& other, const char* name) : Double_t RooBernstein::evaluate() const { - Double_t xmin = _x.min(); Double_t xmax = _x.max(); - Int_t degree= _coefList.getSize()-1; // n+1 polys of degree n + Double_t xmin = _x.min(); + Double_t x = (_x - xmin) / (_x.max() - xmin); // rescale to [0,1] + Int_t degree = _coefList.getSize() - 1; // n+1 polys of degree n + RooFIter iter = _coefList.fwdIterator(); - Double_t temp=0, tempx=0; - RooFIter iter = _coefList.fwdIterator() ; - for (int i=0; i<=degree; ++i){ - tempx = (_x-xmin)/(xmax-xmin); // rescale to [0,1] - temp += ((RooAbsReal*)iter.next())->getVal() * - TMath::Binomial(degree, i) * pow(tempx,i) * pow(1-tempx,degree-i); + if(degree == 0) { + + return ((RooAbsReal *)iter.next())->getVal(); + + } else if(degree == 1) { + + Double_t a0 = ((RooAbsReal *)iter.next())->getVal(); // c0 + Double_t a1 = ((RooAbsReal *)iter.next())->getVal() - a0; // c1 - c0 + return a1 * x + a0; + + } else if(degree == 2) { + + Double_t a0 = ((RooAbsReal *)iter.next())->getVal(); // c0 + Double_t a1 = 2 * (((RooAbsReal *)iter.next())->getVal() - a0); // 2 * (c1 - c0) + Double_t a2 = ((RooAbsReal *)iter.next())->getVal() - a1 - a0; // c0 - 2 * c1 + c2 + return (a2 * x + a1) * x + a0; + + } else if(degree > 2) { + + Double_t t = x; + Double_t s = 1 - x; + + Double_t result = ((RooAbsReal *)iter.next())->getVal() * s; + for(Int_t i = 1; i < degree; i++) { + result = (result + t * TMath::Binomial(degree, i) * ((RooAbsReal *)iter.next())->getVal()) * s; + t *= x; + } + result += t * ((RooAbsReal *)iter.next())->getVal(); + + return result; } - return temp; + // in case list of arguments passed is empty + return TMath::SignalingNaN(); } diff --git a/roofit/roofit/src/RooBifurGauss.cxx b/roofit/roofit/src/RooBifurGauss.cxx index 8395139b4d94e..4fc212b94cea0 100644 --- a/roofit/roofit/src/RooBifurGauss.cxx +++ b/roofit/roofit/src/RooBifurGauss.cxx @@ -32,6 +32,8 @@ #include "RooAbsReal.h" #include "RooMath.h" +using namespace std; + ClassImp(RooBifurGauss) static const char rcsid[] = diff --git a/roofit/roofit/src/RooBlindTools.cxx b/roofit/roofit/src/RooBlindTools.cxx index 412437d829ff7..ee4848c76a884 100644 --- a/roofit/roofit/src/RooBlindTools.cxx +++ b/roofit/roofit/src/RooBlindTools.cxx @@ -29,6 +29,8 @@ #include <string.h> #include <ctype.h> +using namespace std; + ClassImp(RooBlindTools) diff --git a/roofit/roofit/src/RooBreitWigner.cxx b/roofit/roofit/src/RooBreitWigner.cxx index 13a279c6f306f..6cf366dc5d203 100644 --- a/roofit/roofit/src/RooBreitWigner.cxx +++ b/roofit/roofit/src/RooBreitWigner.cxx @@ -35,6 +35,8 @@ #include "RooRealVar.h" // #include "RooFitTools/RooRandom.h" +using namespace std; + ClassImp(RooBreitWigner) diff --git a/roofit/roofit/src/RooBukinPdf.cxx b/roofit/roofit/src/RooBukinPdf.cxx index 55e75cf36dd80..c02e12ac8297f 100644 --- a/roofit/roofit/src/RooBukinPdf.cxx +++ b/roofit/roofit/src/RooBukinPdf.cxx @@ -46,6 +46,8 @@ #include "RooRealVar.h" #include "TMath.h" +using namespace std; + ClassImp(RooBukinPdf) diff --git a/roofit/roofit/src/RooCBShape.cxx b/roofit/roofit/src/RooCBShape.cxx index c5d930e690447..60d2fdfd99ef0 100644 --- a/roofit/roofit/src/RooCBShape.cxx +++ b/roofit/roofit/src/RooCBShape.cxx @@ -33,6 +33,8 @@ #include "RooMath.h" #include "TMath.h" +using namespace std; + ClassImp(RooCBShape) ; diff --git a/roofit/roofit/src/RooCFunction1Binding.cxx b/roofit/roofit/src/RooCFunction1Binding.cxx index 35e388eaa7371..ff2d3a157d61e 100644 --- a/roofit/roofit/src/RooCFunction1Binding.cxx +++ b/roofit/roofit/src/RooCFunction1Binding.cxx @@ -39,21 +39,28 @@ templateClassImp(RooCFunction1Ref) template<> RooCFunction1Map<double,double>* RooCFunction1Ref<double,double>::_fmap = 0 ; template<> RooCFunction1Map<double,int>* RooCFunction1Ref<double,int>::_fmap = 0 ; +template<> +RooCFunction1Map<double,double>& RooCFunction1Ref<double,double>::fmap() + { + // Return reference to function pointer-to-name mapping service + if (!_fmap) { + _fmap = new RooCFunction1Map<double,double> ; + } + return *_fmap ; + } +template<> +RooCFunction1Map<double,int>& RooCFunction1Ref<double,int>::fmap() + { + // Return reference to function pointer-to-name mapping service + if (!_fmap) { + _fmap = new RooCFunction1Map<double,int> ; + } + return *_fmap ; + } namespace RooFit { - RooAbsReal* bindFunction(const char* name,void* func,RooAbsReal& x) - { - // This function is for use in CINT, which does not properly handly - // overloading on function pointer types, so we do it here explicitly - if (RooCintUtils::matchFuncPtrArgs(func,"int")) return new RooCFunction1Binding<Double_t,Int_t>(name,name,(CFUNCD1I)func,x) ; - if (RooCintUtils::matchFuncPtrArgs(func,"double")) return new RooCFunction1Binding<Double_t,Double_t>(name,name,(CFUNCD1D)func,x) ; - oocoutE((TObject*)0,InputArguments) << "bindFunction::ERROR No matching RooCFunction1Binding<> class found for function " << RooCintUtils::functionName(func) << endl ; - return 0 ; - } - - RooAbsReal* bindFunction(const char* name,CFUNCD1D func,RooAbsReal& x) { return new RooCFunction1Binding<Double_t,Double_t>(name,name,func,x) ; } @@ -62,17 +69,6 @@ namespace RooFit { return new RooCFunction1Binding<Double_t,Int_t>(name,name,func,x) ; } - RooAbsPdf* bindPdf(const char* name,void* func,RooAbsReal& x) - { - // This function is for use in CINT, which does not properly handly - // overloading on function pointer types, so we do it here explicitly - if (RooCintUtils::matchFuncPtrArgs(func,"int")) return new RooCFunction1PdfBinding<Double_t,Int_t>(name,name,(CFUNCD1I)func,x) ; - if (RooCintUtils::matchFuncPtrArgs(func,"double")) return new RooCFunction1PdfBinding<Double_t,Double_t>(name,name,(CFUNCD1D)func,x) ; - oocoutE((TObject*)0,InputArguments) << "bindFunction::ERROR No matching RooCFunction1PdfBinding<> class found for function " << RooCintUtils::functionName(func) << endl ; - return 0 ; - } - - RooAbsPdf* bindPdf(const char* name,CFUNCD1D func,RooAbsReal& x) { return new RooCFunction1PdfBinding<Double_t,Double_t>(name,name,func,x) ; } diff --git a/roofit/roofit/src/RooCFunction2Binding.cxx b/roofit/roofit/src/RooCFunction2Binding.cxx index 173eb5febb7d2..7426f2adccd1d 100644 --- a/roofit/roofit/src/RooCFunction2Binding.cxx +++ b/roofit/roofit/src/RooCFunction2Binding.cxx @@ -45,18 +45,6 @@ template<> RooCFunction2Map<double,int,int> *RooCFunction2Ref<double,int,int>::_ namespace RooFit { - RooAbsReal* bindFunction(const char* name,void* func,RooAbsReal& x, RooAbsReal& y) { - // This function is for use in CINT, which does not properly handly - // overloading on function pointer types, so we do it here explicitly - if (RooCintUtils::matchFuncPtrArgs(func,"double,double")) return new RooCFunction2Binding<Double_t,Double_t,Double_t>(name,name,(CFUNCD2DD)func,x,y) ; - if (RooCintUtils::matchFuncPtrArgs(func,"int,double")) return new RooCFunction2Binding<Double_t,Int_t,Double_t>(name,name,(CFUNCD2ID)func,x,y) ; - if (RooCintUtils::matchFuncPtrArgs(func,"unsigned int,double")) return new RooCFunction2Binding<Double_t,UInt_t,Double_t>(name,name,(CFUNCD2UD)func,x,y) ; - if (RooCintUtils::matchFuncPtrArgs(func,"double,int")) return new RooCFunction2Binding<Double_t,Double_t,Int_t>(name,name,(CFUNCD2DI)func,x,y) ; - if (RooCintUtils::matchFuncPtrArgs(func,"int,int")) return new RooCFunction2Binding<Double_t,Int_t,Int_t>(name,name,(CFUNCD2II)func,x,y) ; - oocoutE((TObject*)0,InputArguments) << "bindFunction::ERROR No matching RooCFunction2Binding<> class found for function " << RooCintUtils::functionName(func) << endl ; - return 0 ; - } - RooAbsReal* bindFunction(const char* name,CFUNCD2DD func,RooAbsReal& x, RooAbsReal& y) { return new RooCFunction2Binding<Double_t,Double_t,Double_t>(name,name,func,x,y) ; } @@ -77,18 +65,6 @@ namespace RooFit { return new RooCFunction2Binding<Double_t,Int_t,Int_t>(name,name,func,x,y) ; } - RooAbsPdf* bindPdf(const char* name,void* func,RooAbsReal& x, RooAbsReal& y) { - // This function is for use in CINT, which does not properly handly - // overloading on function pointer types, so we do it here explicitly - if (RooCintUtils::matchFuncPtrArgs(func,"double,double")) return new RooCFunction2PdfBinding<Double_t,Double_t,Double_t>(name,name,(CFUNCD2DD)func,x,y) ; - if (RooCintUtils::matchFuncPtrArgs(func,"int,double")) return new RooCFunction2PdfBinding<Double_t,Int_t,Double_t>(name,name,(CFUNCD2ID)func,x,y) ; - if (RooCintUtils::matchFuncPtrArgs(func,"unsigned int,double")) return new RooCFunction2PdfBinding<Double_t,UInt_t,Double_t>(name,name,(CFUNCD2UD)func,x,y) ; - if (RooCintUtils::matchFuncPtrArgs(func,"double,int")) return new RooCFunction2PdfBinding<Double_t,Double_t,Int_t>(name,name,(CFUNCD2DI)func,x,y) ; - if (RooCintUtils::matchFuncPtrArgs(func,"int,int")) return new RooCFunction2PdfBinding<Double_t,Int_t,Int_t>(name,name,(CFUNCD2II)func,x,y) ; - oocoutE((TObject*)0,InputArguments) << "bindPdf::ERROR No matching RooCFunction2PdfBinding<> class found for function " << RooCintUtils::functionName(func) << endl ; - return 0 ; - } - RooAbsPdf* bindPdf(const char* name,CFUNCD2DD func,RooAbsReal& x, RooAbsReal& y) { return new RooCFunction2PdfBinding<Double_t,Double_t,Double_t>(name,name,func,x,y) ; } diff --git a/roofit/roofit/src/RooCFunction3Binding.cxx b/roofit/roofit/src/RooCFunction3Binding.cxx index 5a11106940b39..4a30edd23157b 100644 --- a/roofit/roofit/src/RooCFunction3Binding.cxx +++ b/roofit/roofit/src/RooCFunction3Binding.cxx @@ -45,19 +45,6 @@ template<> RooCFunction3Map<double,unsigned int,unsigned int,double>* RooCFuncti namespace RooFit { - RooAbsReal* bindFunction(const char* name,void* func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z) { - // This function is for use in CINT, which does not properly handly - // overloading on function pointer types, so we do it here explicitly - if (RooCintUtils::matchFuncPtrArgs(func,"double,double,double")) return new RooCFunction3Binding<Double_t,Double_t,Double_t,Double_t>(name,name,(CFUNCD3DDD)func,x,y,z) ; - if (RooCintUtils::matchFuncPtrArgs(func,"double,double,bool")) return new RooCFunction3Binding<Double_t,Double_t,Double_t,Bool_t>(name,name,(CFUNCD3DDB)func,x,y,z) ; - if (RooCintUtils::matchFuncPtrArgs(func,"double,int,int")) return new RooCFunction3Binding<Double_t,Double_t,Int_t,Int_t>(name,name,(CFUNCD3DII)func,x,y,z) ; - if (RooCintUtils::matchFuncPtrArgs(func,"unsigned int,double,unsigned int")) return new RooCFunction3Binding<Double_t,UInt_t,Double_t,UInt_t>(name,name,(CFUNCD3UDU)func,x,y,z) ; - if (RooCintUtils::matchFuncPtrArgs(func,"unsigned int,double,double")) return new RooCFunction3Binding<Double_t,UInt_t,Double_t,Double_t>(name,name,(CFUNCD3UDD)func,x,y,z) ; - if (RooCintUtils::matchFuncPtrArgs(func,"unsigned int,unsigned int,double")) return new RooCFunction3Binding<Double_t,UInt_t,UInt_t,Double_t>(name,name,(CFUNCD3UUD)func,x,y,z) ; - oocoutE((TObject*)0,InputArguments) << "bindFunction::ERROR No matching RooCFunction3Binding<> class found for function " << RooCintUtils::functionName(func) << endl ; - return 0 ; - } - RooAbsReal* bindFunction(const char* name,CFUNCD3DDD func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z) { return new RooCFunction3Binding<Double_t,Double_t,Double_t,Double_t>(name,name,func,x,y,z) ; } @@ -82,20 +69,6 @@ namespace RooFit { return new RooCFunction3Binding<Double_t,UInt_t,UInt_t,Double_t>(name,name,func,x,y,z) ; } - - RooAbsPdf* bindPdf(const char* name,void* func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z) { - // This function is for use in CINT, which does not properly handly - // overloading on function pointer types, so we do it here explicitly - if (RooCintUtils::matchFuncPtrArgs(func,"double,double,double")) return new RooCFunction3PdfBinding<Double_t,Double_t,Double_t,Double_t>(name,name,(CFUNCD3DDD)func,x,y,z) ; - if (RooCintUtils::matchFuncPtrArgs(func,"double,double,bool")) return new RooCFunction3PdfBinding<Double_t,Double_t,Double_t,Bool_t>(name,name,(CFUNCD3DDB)func,x,y,z) ; - if (RooCintUtils::matchFuncPtrArgs(func,"double,int,int")) return new RooCFunction3PdfBinding<Double_t,Double_t,Int_t,Int_t>(name,name,(CFUNCD3DII)func,x,y,z) ; - if (RooCintUtils::matchFuncPtrArgs(func,"unsigned int,double,unsigned int")) return new RooCFunction3PdfBinding<Double_t,UInt_t,Double_t,UInt_t>(name,name,(CFUNCD3UDU)func,x,y,z) ; - if (RooCintUtils::matchFuncPtrArgs(func,"unsigned int,double,double")) return new RooCFunction3PdfBinding<Double_t,UInt_t,Double_t,Double_t>(name,name,(CFUNCD3UDD)func,x,y,z) ; - if (RooCintUtils::matchFuncPtrArgs(func,"unsigned int,unsigned int,double")) return new RooCFunction3PdfBinding<Double_t,UInt_t,UInt_t,Double_t>(name,name,(CFUNCD3UUD)func,x,y,z) ; - oocoutE((TObject*)0,InputArguments) << "bindPdf::ERROR No matching RooCFunction3PdfBinding<> class found for function " << RooCintUtils::functionName(func) << endl ; - return 0 ; - } - RooAbsPdf* bindPdf(const char* name,CFUNCD3DDD func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z) { return new RooCFunction3PdfBinding<Double_t,Double_t,Double_t,Double_t>(name,name,func,x,y,z) ; } diff --git a/roofit/roofit/src/RooCFunction4Binding.cxx b/roofit/roofit/src/RooCFunction4Binding.cxx index bed79d0c94f87..204501f214646 100644 --- a/roofit/roofit/src/RooCFunction4Binding.cxx +++ b/roofit/roofit/src/RooCFunction4Binding.cxx @@ -43,17 +43,6 @@ template<> RooCFunction4Map<double,double,double,double,bool>* RooCFunction4Ref< namespace RooFit { - RooAbsReal* bindFunction(const char* name,void* func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z, RooAbsReal& w) { - // This function is for use in CINT, which does not properly handly - // overloading on function pointer types, so we do it here explicitly - if (RooCintUtils::matchFuncPtrArgs(func,"double,double,double,double")) return new RooCFunction4Binding<Double_t,Double_t,Double_t,Double_t,Double_t>(name,name,(CFUNCD4DDDD)func,x,y,z,w) ; - if (RooCintUtils::matchFuncPtrArgs(func,"double,double,double,int")) return new RooCFunction4Binding<Double_t,Double_t,Double_t,Double_t,Int_t>(name,name,(CFUNCD4DDDI)func,x,y,z,w) ; - if (RooCintUtils::matchFuncPtrArgs(func,"double,double,double,bool")) return new RooCFunction4Binding<Double_t,Double_t,Double_t,Double_t,Bool_t>(name,name,(CFUNCD4DDDB)func,x,y,z,w) ; - oocoutE((TObject*)0,InputArguments) << "bindFunction::ERROR No matching RooCFunction4Binding<> class found for function " << RooCintUtils::functionName(func) << endl ; - return 0 ; - } - - RooAbsReal* bindFunction(const char* name,CFUNCD4DDDD func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z, RooAbsReal& w) { return new RooCFunction4Binding<Double_t,Double_t,Double_t,Double_t,Double_t>(name,name,func,x,y,z,w) ; } @@ -66,18 +55,6 @@ namespace RooFit { return new RooCFunction4Binding<Double_t,Double_t,Double_t,Double_t,Bool_t>(name,name,func,x,y,z,w) ; } - - RooAbsPdf* bindPdf(const char* name,void* func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z, RooAbsReal& w) { - // This function is for use in CINT, which does not properly handly - // overloading on function pointer types, so we do it here explicitly - if (RooCintUtils::matchFuncPtrArgs(func,"double,double,double,double")) return new RooCFunction4PdfBinding<Double_t,Double_t,Double_t,Double_t,Double_t>(name,name,(CFUNCD4DDDD)func,x,y,z,w) ; - if (RooCintUtils::matchFuncPtrArgs(func,"double,double,double,int")) return new RooCFunction4PdfBinding<Double_t,Double_t,Double_t,Double_t,Int_t>(name,name,(CFUNCD4DDDI)func,x,y,z,w) ; - if (RooCintUtils::matchFuncPtrArgs(func,"double,double,double,bool")) return new RooCFunction4PdfBinding<Double_t,Double_t,Double_t,Double_t,Bool_t>(name,name,(CFUNCD4DDDB)func,x,y,z,w) ; - oocoutE((TObject*)0,InputArguments) << "bindPdf::ERROR No matching RooCFunction4PdfBinding<> class found for function " << RooCintUtils::functionName(func) << endl ; - return 0 ; - } - - RooAbsPdf* bindPdf(const char* name,CFUNCD4DDDD func,RooAbsReal& x, RooAbsReal& y, RooAbsReal& z, RooAbsReal& w) { return new RooCFunction4PdfBinding<Double_t,Double_t,Double_t,Double_t,Double_t>(name,name,func,x,y,z,w) ; } diff --git a/roofit/roofit/src/RooChebychev.cxx b/roofit/roofit/src/RooChebychev.cxx index cfcff04871117..2cf724d56bfe3 100644 --- a/roofit/roofit/src/RooChebychev.cxx +++ b/roofit/roofit/src/RooChebychev.cxx @@ -20,17 +20,27 @@ // END_HTML // +#include <cmath> +#include <iostream> + #include "RooFit.h" #include "Riostream.h" -#include "Riostream.h" -#include <math.h> #include "RooChebychev.h" #include "RooAbsReal.h" #include "RooRealVar.h" #include "RooArgList.h" +#if defined(__my_func__) +#undef __my_func__ +#endif +#if defined(WIN32) +#define __my_func__ __FUNCTION__ +#else +#define __my_func__ __func__ +#endif + ClassImp(RooChebychev) ; @@ -53,8 +63,9 @@ RooChebychev::RooChebychev(const char* name, const char* title, RooAbsArg* coef ; while((coef = (RooAbsArg*)coefIter->Next())) { if (!dynamic_cast<RooAbsReal*>(coef)) { - cout << "RooChebychev::ctor(" << GetName() << ") ERROR: coefficient " << coef->GetName() - << " is not of type RooAbsReal" << endl ; + std::cerr << "RooChebychev::ctor(" << GetName() << + ") ERROR: coefficient " << coef->GetName() << + " is not of type RooAbsReal" << std::endl ; assert(0) ; } _coefList.add(*coef) ; @@ -72,11 +83,11 @@ RooChebychev::RooChebychev(const RooChebychev& other, const char* name) : { } -inline static double p0(double ,double a) { return a; } -inline static double p1(double t,double a,double b) { return a*t+b; } -inline static double p2(double t,double a,double b,double c) { return p1(t,p1(t,a,b),c); } -inline static double p3(double t,double a,double b,double c,double d) { return p2(t,p1(t,a,b),c,d); } -inline static double p4(double t,double a,double b,double c,double d,double e) { return p3(t,p1(t,a,b),c,d,e); } +inline static double p0(double ,double a) { return a; } +inline static double p1(double t,double a,double b) { return a*t+b; } +inline static double p2(double t,double a,double b,double c) { return p1(t,p1(t,a,b),c); } +inline static double p3(double t,double a,double b,double c,double d) { return p2(t,p1(t,a,b),c,d); } +inline static double p4(double t,double a,double b,double c,double d,double e) { return p3(t,p1(t,a,b),c,d,e); } //_____________________________________________________________________________ @@ -95,20 +106,19 @@ Double_t RooChebychev::evaluate() const case 3: sum+=((RooAbsReal&)_coefList[2]).getVal()*x*p1(x2,4,-3); case 2: sum+=((RooAbsReal&)_coefList[1]).getVal()*p1(x2,2,-1); case 1: sum+=((RooAbsReal&)_coefList[0]).getVal()*x; - case 0: sum+=1; + case 0: sum+=1; break; + default: std::cerr << "In " << __my_func__ << " (" << __FILE__ << ", line " << + __LINE__ << "): Higher order Chebychev polynomials currently " + "unimplemented." << std::endl; + assert(false); } return sum; } //_____________________________________________________________________________ -Int_t RooChebychev::getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVars, const char* rangeName) const +Int_t RooChebychev::getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVars, const char* /* rangeName */) const { - // No analytical calculation available (yet) of integrals over subranges - if (rangeName && strlen(rangeName)) { - return 0 ; - } - if (matchArgs(allVars, analVars, _x)) return 1; return 0; } @@ -117,19 +127,48 @@ Int_t RooChebychev::getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVar //_____________________________________________________________________________ Double_t RooChebychev::analyticalIntegral(Int_t code, const char* rangeName) const { - assert(code==1) ; - // WVE check that this works all right for sub ranges - Double_t xmin = _x.min(rangeName); Double_t xmax = _x.max(rangeName); - Double_t norm(0) ; - switch(_coefList.getSize()) { - // coverity[MISSING_BREAK] - case 7: case 6: norm+=((RooAbsReal&)_coefList[5]).getVal()*(-1 + 18./3. - 48./5. + 32./7.); - // coverity[MISSING_BREAK] - case 5: case 4: norm+=((RooAbsReal&)_coefList[3]).getVal()*( 1 - 8./3. + 8./5.); - // coverity[MISSING_BREAK] - case 3: case 2: norm+=((RooAbsReal&)_coefList[1]).getVal()*(-1 + 2./3.); - case 1: case 0: norm+= 1; + assert(1 == code); + + // the full range of the function is mapped to the normalised [-1, 1] range + const Double_t xminfull(_x.min()), xmaxfull(_x.max()); + const Double_t fullRange = xmaxfull - xminfull; + + // define limits of the integration range on a normalised scale + Double_t minScaled = -1., maxScaled = +1.; + + // check to see if integral of a subrange is requested + if (rangeName && 0 != rangeName[0]) { + assert(xminfull <= _x.min(rangeName) && _x.min(rangeName) <= xmaxfull); + assert(xminfull <= _x.max(rangeName) && _x.max(rangeName) <= xmaxfull); + minScaled = -1. + 2. * (_x.min(rangeName) - xminfull) / fullRange; + maxScaled = +1. - 2. * (xmaxfull - _x.max(rangeName)) / fullRange; + } + + // return half of the range since the normalised range runs from -1 to 1 + // which has a range of two + return 0.5 * fullRange * (evalAnaInt(maxScaled) - evalAnaInt(minScaled)); +} + +Double_t RooChebychev::evalAnaInt(const Double_t x) const +{ + const Double_t x2 = x * x; + Double_t sum = 0.; + switch (_coefList.getSize()) { + case 7: sum+=((RooAbsReal&)_coefList[6]).getVal()*x2*p3(x2,8.,-112./6.,14.,-7./2.); + case 6: sum+=((RooAbsReal&)_coefList[5]).getVal()*x*p3(x2,32./7.,-48./5.,6.,-1.); + case 5: sum+=((RooAbsReal&)_coefList[4]).getVal()*x2*p2(x2,16./6.,-5.,2.5); + case 4: sum+=((RooAbsReal&)_coefList[3]).getVal()*x*p2(x2,8./5.,-8./3.,1.); + case 3: sum+=((RooAbsReal&)_coefList[2]).getVal()*x2*p1(x2,1.,-3./2.); + case 2: sum+=((RooAbsReal&)_coefList[1]).getVal()*x*p1(x2,2./3.,-1.); + case 1: sum+=((RooAbsReal&)_coefList[0]).getVal()*x2*.5; + case 0: sum+=x; break; + + default: std::cerr << "In " << __my_func__ << " (" << __FILE__ << ", line " << + __LINE__ << "): Higher order Chebychev polynomials currently " + "unimplemented." << std::endl; + assert(false); } - norm *= xmax-xmin; - return norm; + return sum; } + +#undef __my_func__ diff --git a/roofit/roofit/src/RooChi2MCSModule.cxx b/roofit/roofit/src/RooChi2MCSModule.cxx index ae57f17957759..a73fc5c12ec1e 100644 --- a/roofit/roofit/src/RooChi2MCSModule.cxx +++ b/roofit/roofit/src/RooChi2MCSModule.cxx @@ -42,6 +42,8 @@ +using namespace std; + ClassImp(RooChi2MCSModule) ; diff --git a/roofit/roofit/src/RooChiSquarePdf.cxx b/roofit/roofit/src/RooChiSquarePdf.cxx index 398ba352e5ab8..5af10f102f9d8 100644 --- a/roofit/roofit/src/RooChiSquarePdf.cxx +++ b/roofit/roofit/src/RooChiSquarePdf.cxx @@ -26,6 +26,8 @@ #include "RooAbsReal.h" #include "RooRealVar.h" +using namespace std; + ClassImp(RooChiSquarePdf) ; diff --git a/roofit/roofit/src/RooDecay.cxx b/roofit/roofit/src/RooDecay.cxx index 393dc9036e75a..37ea992a3ef5f 100644 --- a/roofit/roofit/src/RooDecay.cxx +++ b/roofit/roofit/src/RooDecay.cxx @@ -30,6 +30,8 @@ #include "RooRealVar.h" #include "RooRandom.h" +using namespace std; + ClassImp(RooDecay) ; diff --git a/roofit/roofit/src/RooDstD0BG.cxx b/roofit/roofit/src/RooDstD0BG.cxx index bc07953bab758..e27b5ad418f5f 100644 --- a/roofit/roofit/src/RooDstD0BG.cxx +++ b/roofit/roofit/src/RooDstD0BG.cxx @@ -37,6 +37,8 @@ #include "RooIntegrator1D.h" #include "RooAbsFunc.h" +using namespace std; + ClassImp(RooDstD0BG) static const char rcsid[] = diff --git a/roofit/roofit/src/RooExponential.cxx b/roofit/roofit/src/RooExponential.cxx index db0391181b88e..30e73d926cbec 100644 --- a/roofit/roofit/src/RooExponential.cxx +++ b/roofit/roofit/src/RooExponential.cxx @@ -30,6 +30,8 @@ #include "RooExponential.h" #include "RooRealVar.h" +using namespace std; + ClassImp(RooExponential) diff --git a/roofit/roofit/src/RooGExpModel.cxx b/roofit/roofit/src/RooGExpModel.cxx index 974c127b91e24..8f4fb9ae4f417 100644 --- a/roofit/roofit/src/RooGExpModel.cxx +++ b/roofit/roofit/src/RooGExpModel.cxx @@ -35,6 +35,8 @@ #include "RooMath.h" #include "TMath.h" +using namespace std; + ClassImp(RooGExpModel) ; @@ -185,7 +187,7 @@ Double_t RooGExpModel::evaluate() const //Double_t xprime = x/rtau ; //Double_t c = sig/(root2*rtau) ; //Double_t u = xprime/(2*c) ; - //Double_t result = 0.5*evalCerfRe(fsign*u,c) ; // sign=-1 ! + //Double_t result = 0.5*evalCerf(fsign*u,c).real() ; // sign=-1 ! if (_basisCode!=0 && basisSign==Both) result *= 2 ; //cout << "1st form " << "x= " << x << " result= " << result << endl; @@ -217,8 +219,8 @@ Double_t RooGExpModel::evaluate() const << omega << ", tau = " << tau << endl ; Double_t result(0) ; if (wt==0.) return result ; - if (basisSign!=Minus) result += -1*calcSinConv(+1,sig,tau,omega,rtau,fsign).im() ; - if (basisSign!=Plus) result += -1*calcSinConv(-1,sig,tau,omega,rtau,fsign).im() ; + if (basisSign!=Minus) result += -1*calcSinConv(+1,sig,tau,omega,rtau,fsign).imag() ; + if (basisSign!=Plus) result += -1*calcSinConv(-1,sig,tau,omega,rtau,fsign).imag() ; //cout << "4th form " << "x= " << x << " result= " << result << endl; return result ; } @@ -228,8 +230,8 @@ Double_t RooGExpModel::evaluate() const if (verboseEval()>2) cout << "RooGExpModel::evaluate(" << GetName() << ") 5th form omega = " << omega << ", tau = " << tau << endl ; Double_t result(0) ; - if (basisSign!=Minus) result += calcSinConv(+1,sig,tau,omega,rtau,fsign).re() ; - if (basisSign!=Plus) result += calcSinConv(-1,sig,tau,omega,rtau,fsign).re() ; + if (basisSign!=Minus) result += calcSinConv(+1,sig,tau,omega,rtau,fsign).real() ; + if (basisSign!=Plus) result += calcSinConv(-1,sig,tau,omega,rtau,fsign).real() ; //cout << "5th form " << "x= " << x << " result= " << result << endl; return result ; } @@ -301,7 +303,7 @@ Double_t RooGExpModel::logErfC(Double_t xx) const //_____________________________________________________________________________ -RooComplex RooGExpModel::calcSinConv(Double_t sign, Double_t sig, Double_t tau, Double_t omega, Double_t rtau, Double_t fsign) const +std::complex<Double_t> RooGExpModel::calcSinConv(Double_t sign, Double_t sig, Double_t tau, Double_t omega, Double_t rtau, Double_t fsign) const { static Double_t root2(sqrt(2.)) ; @@ -314,11 +316,11 @@ RooComplex RooGExpModel::calcSinConv(Double_t sign, Double_t sig, Double_t tau, Double_t u2= fsign*s2/(2*c2) ; //Double_t u2= s2/(2*c2) ; - RooComplex eins(1,0); - RooComplex k(1/tau,sign*omega); + std::complex<Double_t> eins(1,0); + std::complex<Double_t> k(1/tau,sign*omega); //return (evalCerf(-sign*omega*tau,u1,c1)+evalCerf(0,u2,c2)*fsign*sign) / (eins + k*fsign*sign*rtau) ; - return (evalCerf(-sign*omega*tau,u1,c1)+RooComplex(evalCerfRe(u2,c2),0)*fsign*sign) / (eins + k*fsign*sign*rtau) ; + return (evalCerf(-sign*omega*tau,u1,c1)+std::complex<Double_t>(evalCerfRe(u2,c2),0)*fsign*sign) / (eins + k*fsign*sign*rtau) ; // equivalent form, added FMV, 07/24/03 //return (evalCerf(-sign*omega*tau,-sign*u1,c1)+evalCerf(0,fsign*u2,c2)*fsign*sign) / (eins + k*fsign*sign*rtau) ; } @@ -344,7 +346,7 @@ Double_t RooGExpModel::calcSinConv(Double_t sign, Double_t sig, Double_t tau, Do Double_t k(1/tau); return (evalCerfRe(u1,c1)+evalCerfRe(u2,c2)*fsign*sign) / (eins + k*fsign*sign*rtau) ; // equivalent form, added FMV, 07/24/03 - //return (evalCerfRe(-sign*u1,c1)+evalCerfRe(fsign*u2,c2)*fsign*sign) / (eins + k*fsign*sign*rtau) ; + //return (evalCerf(-sign*u1,c1).real()+evalCerf(fsign*u2,c2).real()*fsign*sign) / (eins + k*fsign*sign*rtau) ; } @@ -621,11 +623,11 @@ Double_t RooGExpModel::analyticalIntegral(Int_t code, const char* rangeName) con //cout << "sin integral" << endl; Double_t result(0) ; if (wt==0) return result ; - //if (basisSign!=Minus) result += calcSinConvNorm(+1,tau,omega).im() ; - //if (basisSign!=Plus) result += calcSinConvNorm(-1,tau,omega).im() ; + //if (basisSign!=Minus) result += calcSinConvNorm(+1,tau,omega).imag() ; + //if (basisSign!=Plus) result += calcSinConvNorm(-1,tau,omega).imag() ; // finite+asymtotic normalization, added FMV, 07/24/03 - if (basisSign!=Minus) result += -1*calcSinConvNorm(+1,tau,omega,sig,rtau,fsign,rangeName).im(); - if (basisSign!=Plus) result += -1*calcSinConvNorm(-1,tau,omega,sig,rtau,fsign,rangeName).im(); + if (basisSign!=Minus) result += -1*calcSinConvNorm(+1,tau,omega,sig,rtau,fsign,rangeName).imag(); + if (basisSign!=Plus) result += -1*calcSinConvNorm(-1,tau,omega,sig,rtau,fsign,rangeName).imag(); //cout << "Integral 4th form " << " result= " << result*ssfInt << endl; return result*ssfInt ; } @@ -636,11 +638,11 @@ Double_t RooGExpModel::analyticalIntegral(Int_t code, const char* rangeName) con << ") 5th form omega = " << omega << ", tau = " << tau << endl ; //cout << "cos integral" << endl; Double_t result(0) ; - //if (basisSign!=Minus) result += calcSinConvNorm(+1,tau,omega).re() ; - //if (basisSign!=Plus) result += calcSinConvNorm(-1,tau,omega).re() ; + //if (basisSign!=Minus) result += calcSinConvNorm(+1,tau,omega).real() ; + //if (basisSign!=Plus) result += calcSinConvNorm(-1,tau,omega).real() ; // finite+asymtotic normalization, added FMV, 07/24/03 - if (basisSign!=Minus) result += calcSinConvNorm(+1,tau,omega,sig,rtau,fsign,rangeName).re(); - if (basisSign!=Plus) result += calcSinConvNorm(-1,tau,omega,sig,rtau,fsign,rangeName).re(); + if (basisSign!=Minus) result += calcSinConvNorm(+1,tau,omega,sig,rtau,fsign,rangeName).real(); + if (basisSign!=Plus) result += calcSinConvNorm(-1,tau,omega,sig,rtau,fsign,rangeName).real(); //cout << "Integral 5th form " << " result= " << result*ssfInt << endl; return result*ssfInt ; } @@ -694,11 +696,11 @@ Double_t RooGExpModel::analyticalIntegral(Int_t code, const char* rangeName) con // modified FMV, 07/24/03. Finite+asymtotic normalization //_____________________________________________________________________________ -RooComplex RooGExpModel::calcSinConvNorm(Double_t sign, Double_t tau, Double_t omega, +std::complex<Double_t> RooGExpModel::calcSinConvNorm(Double_t sign, Double_t tau, Double_t omega, Double_t sig, Double_t rtau, Double_t fsign, const char* rangeName) const { // old code (asymptotic normalization only) - // RooComplex z(1/tau,sign*omega); + // std::complex<Double_t> z(1/tau,sign*omega); // return z*2/(omega*omega+1/(tau*tau)); static Double_t root2(sqrt(2.)) ; @@ -714,11 +716,11 @@ RooComplex RooGExpModel::calcSinConvNorm(Double_t sign, Double_t tau, Double_t o Double_t umin2= smin2/(2*c2) ; Double_t umax2= smax2/(2*c2) ; - RooComplex eins(1,0); - RooComplex k(1/tau,sign*omega); - RooComplex term1 = evalCerfInt(sign,-sign*omega*tau, tau, -sign*umin1, -sign*umax1, c1); - //RooComplex term2 = evalCerfInt(-fsign,0., rtau, fsign*umin2, fsign*umax2, c2)*RooComplex(fsign*sign,0); - RooComplex term2 = RooComplex(evalCerfInt(-fsign, rtau, fsign*umin2, fsign*umax2, c2)*fsign*sign,0); + std::complex<Double_t> eins(1,0); + std::complex<Double_t> k(1/tau,sign*omega); + std::complex<Double_t> term1 = evalCerfInt(sign,-sign*omega*tau, tau, -sign*umin1, -sign*umax1, c1); + //std::complex<Double_t> term2 = evalCerfInt(-fsign,0., rtau, fsign*umin2, fsign*umax2, c2)*std::complex<Double_t>(fsign*sign,0); + std::complex<Double_t> term2 = std::complex<Double_t>(evalCerfInt(-fsign, rtau, fsign*umin2, fsign*umax2, c2)*fsign*sign,0); return (term1+term2)/(eins + k*fsign*sign*rtau) ; } @@ -759,15 +761,15 @@ Double_t RooGExpModel::calcSinConvNorm(Double_t sign, Double_t tau, Double_t sig // added FMV, 07/24/03 //_____________________________________________________________________________ -RooComplex RooGExpModel::evalCerfInt(Double_t sign, Double_t wt, Double_t tau, Double_t umin, Double_t umax, Double_t c) const +std::complex<Double_t> RooGExpModel::evalCerfInt(Double_t sign, Double_t wt, Double_t tau, Double_t umin, Double_t umax, Double_t c) const { - RooComplex diff; + std::complex<Double_t> diff; if (_asympInt) { - diff = RooComplex(2,0) ; + diff = std::complex<Double_t>(2,0) ; } else { - diff = RooComplex(sign,0.)*(evalCerf(wt,umin,c) - evalCerf(wt,umax,c) + RooMath::erf(umin) - RooMath::erf(umax)); + diff = std::complex<Double_t>(sign,0.)*(evalCerf(wt,umin,c) - evalCerf(wt,umax,c) + RooMath::erf(umin) - RooMath::erf(umax)); } - return RooComplex(tau/(1.+wt*wt),0)*RooComplex(1,wt)*diff; + return std::complex<Double_t>(tau/(1.+wt*wt),0)*std::complex<Double_t>(1,wt)*diff; } // added FMV, 08/17/03. Modified FMV, 08/30/03 @@ -791,19 +793,19 @@ Double_t RooGExpModel::evalCerfInt(Double_t sign, Double_t tau, Double_t umin, D //_____________________________________________________________________________ -RooComplex RooGExpModel::evalCerfApprox(Double_t swt, Double_t u, Double_t c) const +std::complex<Double_t> RooGExpModel::evalCerfApprox(Double_t swt, Double_t u, Double_t c) { // use the approximation: erf(z) = exp(-z*z)/(sqrt(pi)*z) // to explicitly cancel the divergent exp(y*y) behaviour of // CWERF for z = x + i y with large negative y static Double_t rootpi= sqrt(atan2(0.,-1.)); - RooComplex z(swt*c,u+c); - RooComplex zc(u+c,-swt*c); - RooComplex zsq= z*z; - RooComplex v= -zsq - u*u; + std::complex<Double_t> z(swt*c,u+c); + std::complex<Double_t> zc(u+c,-swt*c); + std::complex<Double_t> zsq= z*z; + std::complex<Double_t> v= -zsq - u*u; - return v.exp()*(-zsq.exp()/(zc*rootpi) + 1)*2 ; + return std::exp(v)*(-std::exp(zsq)/(zc*rootpi) + 1.)*2.; } diff --git a/roofit/roofit/src/RooGamma.cxx b/roofit/roofit/src/RooGamma.cxx index 2f256809a6f9e..1227e80fe3d27 100644 --- a/roofit/roofit/src/RooGamma.cxx +++ b/roofit/roofit/src/RooGamma.cxx @@ -50,6 +50,8 @@ #include <Math/PdfFuncMathCore.h> #include <Math/ProbFuncMathCore.h> +using namespace std; + ClassImp(RooGamma) diff --git a/roofit/roofit/src/RooGaussModel.cxx b/roofit/roofit/src/RooGaussModel.cxx index 688111ddc153a..5b58d34107c17 100644 --- a/roofit/roofit/src/RooGaussModel.cxx +++ b/roofit/roofit/src/RooGaussModel.cxx @@ -29,10 +29,11 @@ #include "Riostream.h" #include "Riostream.h" #include "RooGaussModel.h" -#include "RooMath.h" #include "RooRealConstant.h" #include "RooRandom.h" +using namespace std; + ClassImp(RooGaussModel) ; @@ -138,9 +139,9 @@ Double_t RooGaussModel::evaluate() const //cout << "RooGaussModel::evaluate(" << GetName() << ") basisCode = " << _basisCode << endl ; // *** 1st form: Straight Gaussian, used for unconvoluted PDF or expBasis with 0 lifetime *** - static Double_t root2(sqrt(2.)) ; - static Double_t root2pi(sqrt(2*atan2(0.,-1.))) ; - static Double_t rootpi(sqrt(atan2(0.,-1.))) ; + static Double_t root2(std::sqrt(2.)) ; + static Double_t root2pi(std::sqrt(2.*std::atan2(0.,-1.))) ; + static Double_t rootpi(std::sqrt(std::atan2(0.,-1.))) ; BasisType basisType = (BasisType)( (_basisCode == 0) ? 0 : (_basisCode/10) + 1 ); BasisSign basisSign = (BasisSign)( _basisCode - 10*(basisType-1) - 2 ) ; @@ -155,7 +156,7 @@ Double_t RooGaussModel::evaluate() const Double_t xprime = (x-(mean*msf))/(sigma*ssf) ; if (verboseEval()>2) cout << "RooGaussModel::evaluate(" << GetName() << ") 1st form" << endl ; - Double_t result = exp(-0.5*xprime*xprime)/(sigma*ssf*root2pi) ; + Double_t result = std::exp(-0.5*xprime*xprime)/(sigma*ssf*root2pi) ; if (_basisCode!=0 && basisSign==Both) result *= 2 ; return result ; } @@ -178,8 +179,8 @@ Double_t RooGaussModel::evaluate() const if (basisType==expBasis || (basisType==cosBasis && _x==0.)) { if (verboseEval()>2) cout << "RooGaussModel::evaluate(" << GetName() << ") 3d form tau=" << tau << endl ; Double_t result(0) ; - if (basisSign!=Minus) result += evalCerfRe(0,-u,c) ; - if (basisSign!=Plus) result += evalCerfRe(0, u,c) ; + if (basisSign!=Minus) result += evalCerf(0,-u,c).real(); + if (basisSign!=Plus) result += evalCerf(0, u,c).real(); if (TMath::IsNaN(result)) { cxcoutE(Tracing) << "RooGaussModel::getVal(" << GetName() << ") got nan during case 1 " << endl; } return result ; } @@ -189,8 +190,8 @@ Double_t RooGaussModel::evaluate() const if (verboseEval()>2) cout << "RooGaussModel::evaluate(" << GetName() << ") 4th form omega = " << omega << ", tau = " << tau << endl ; Double_t result(0) ; if (_x==0.) return result ; - if (basisSign!=Minus) result += -evalCerfIm(-_x,-u,c) ; - if (basisSign!=Plus) result += -evalCerfIm( _x, u,c) ; + if (basisSign!=Minus) result += -evalCerf(-_x,-u,c).imag(); + if (basisSign!=Plus) result += -evalCerf( _x, u,c).imag(); if (TMath::IsNaN(result)) cxcoutE(Tracing) << "RooGaussModel::getVal(" << GetName() << ") got nan during case 3 " << endl; return result ; } @@ -199,8 +200,8 @@ Double_t RooGaussModel::evaluate() const if (basisType==cosBasis) { if (verboseEval()>2) cout << "RooGaussModel::evaluate(" << GetName() << ") 5th form omega = " << omega << ", tau = " << tau << endl ; Double_t result(0) ; - if (basisSign!=Minus) result += evalCerfRe(-_x,-u,c) ; - if (basisSign!=Plus) result += evalCerfRe( _x, u,c) ; + if (basisSign!=Minus) result += evalCerf(-_x,-u,c).real(); + if (basisSign!=Plus) result += evalCerf( _x, u,c).real(); if (TMath::IsNaN(result)) cxcoutE(Tracing) << "RooGaussModel::getVal(" << GetName() << ") got nan during case 4 " << endl; return result ; } @@ -210,8 +211,8 @@ Double_t RooGaussModel::evaluate() const if (verboseEval()>2) cout << "RooGaussModel::evaluate(" << GetName() << ") 8th form tau = " << tau << endl ; Double_t result(0); int sgn = ( basisType == coshBasis ? +1 : -1 ); - if (basisSign!=Minus) result += 0.5*( evalCerfRe(0,-u,c*(1-_y))+sgn*evalCerfRe(0,-u,c*(1+_y))) ; - if (basisSign!=Plus) result += 0.5*(sgn*evalCerfRe(0, u,c*(1-_y))+ evalCerfRe(0, u,c*(1+_y))) ; + if (basisSign!=Minus) result += 0.5*( evalCerf(0,-u,c*(1-_y)).real()+sgn*evalCerf(0,-u,c*(1+_y)).real()) ; + if (basisSign!=Plus) result += 0.5*(sgn*evalCerf(0, u,c*(1-_y)).real()+ evalCerf(0, u,c*(1+_y)).real()) ; if (TMath::IsNaN(result)) cxcoutE(Tracing) << "RooGaussModel::getVal(" << GetName() << ") got nan during case 8 " << endl; return result ; } @@ -221,8 +222,8 @@ Double_t RooGaussModel::evaluate() const if (verboseEval()>2) cout << "RooGaussModel::evaluate(" << GetName() << ") 6th form tau = " << tau << endl ; assert(basisSign==Plus); // This should only be for positive times - Double_t f0 = exp(-xprime+c*c) * RooMath::erfc(-u+c); - Double_t f1 = exp(-u*u); + Double_t f0 = std::exp(-xprime+c*c) * RooMath::erfc(-u+c); + Double_t f1 = std::exp(-u*u); return (xprime - 2*c*c)*f0 + (2*c/rootpi)*f1 ; } @@ -231,8 +232,8 @@ Double_t RooGaussModel::evaluate() const if (verboseEval()>2) cout << "RooGaussModel::evaluate(" << GetName() << ") 7th form tau = " << tau << endl ; assert(basisSign==Plus); // This should only be for positive times - Double_t f0 = exp(-xprime+c*c) * RooMath::erfc(-u+c); - Double_t f1 = exp(-u*u); + Double_t f0 = std::exp(-xprime+c*c) * RooMath::erfc(-u+c); + Double_t f1 = std::exp(-u*u); Double_t x2c2 = xprime - 2*c*c; return ( x2c2*x2c2*f0 + (2*c/rootpi)*x2c2*f1 + 2*c*c*f0 ); } @@ -298,9 +299,9 @@ Int_t RooGaussModel::getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVa //_____________________________________________________________________________ Double_t RooGaussModel::analyticalIntegral(Int_t code, const char* rangeName) const { - static Double_t root2 = sqrt(2.) ; - //static Double_t rootPiBy2 = sqrt(atan2(0.0,-1.0)/2.0); - static Double_t rootpi = sqrt(atan2(0.0,-1.0)); + static const Double_t root2 = std::sqrt(2.) ; + //static Double_t rootPiBy2 = std::sqrt(std::atan2(0.0,-1.0)/2.0); + static const Double_t rootpi = std::sqrt(std::atan2(0.0,-1.0)); Double_t ssfInt(1.0) ; // Code must be 1 or 2 @@ -356,8 +357,8 @@ Double_t RooGaussModel::analyticalIntegral(Int_t code, const char* rangeName) co if (basisType==expBasis || (basisType==cosBasis && omega==0.)) { if (verboseEval()>0) cout << "RooGaussModel::analyticalIntegral(" << GetName() << ") 3d form tau=" << tau << endl ; Double_t result(0) ; - if (basisSign!=Minus) result += evalCerfInt(+1,0,tau,-umin,-umax,c).re(); - if (basisSign!=Plus) result += evalCerfInt(-1,0,tau, umin, umax,c).re(); + if (basisSign!=Minus) result += evalCerfInt(+1,0,tau,-umin,-umax,c).real(); + if (basisSign!=Plus) result += evalCerfInt(-1,0,tau, umin, umax,c).real(); if (TMath::IsNaN(result)) { cxcoutE(Tracing) << "RooGaussModel::analyticalIntegral(" << GetName() << ") got nan during case 3 " << endl; } return result*ssfInt ; } @@ -370,8 +371,8 @@ Double_t RooGaussModel::analyticalIntegral(Int_t code, const char* rangeName) co if (verboseEval()>0) cout << "RooGaussModel::analyticalIntegral(" << GetName() << ") 4th form omega = " << omega << ", tau = " << tau << endl ; Double_t result(0) ; if (_x==0) return result*ssfInt ; - if (basisSign!=Minus) result += -1*evalCerfInt(+1,-_x,tau,-umin,-umax,c).im(); - if (basisSign!=Plus) result += -1*evalCerfInt(-1, _x,tau, umin, umax,c).im(); + if (basisSign!=Minus) result += -1*evalCerfInt(+1,-_x,tau,-umin,-umax,c).imag(); + if (basisSign!=Plus) result += -1*evalCerfInt(-1, _x,tau, umin, umax,c).imag(); if (TMath::IsNaN(result)) { cxcoutE(Tracing) << "RooGaussModel::analyticalIntegral(" << GetName() << ") got nan during case 4 " << endl; } return result*ssfInt ; } @@ -380,8 +381,8 @@ Double_t RooGaussModel::analyticalIntegral(Int_t code, const char* rangeName) co if (basisType==cosBasis) { if (verboseEval()>0) cout << "RooGaussModel::analyticalIntegral(" << GetName() << ") 5th form omega = " << omega << ", tau = " << tau << endl ; Double_t result(0) ; - if (basisSign!=Minus) result += evalCerfInt(+1,-_x,tau,-umin,-umax,c).re(); - if (basisSign!=Plus) result += evalCerfInt(-1, _x,tau, umin, umax,c).re(); + if (basisSign!=Minus) result += evalCerfInt(+1,-_x,tau,-umin,-umax,c).real(); + if (basisSign!=Plus) result += evalCerfInt(-1, _x,tau, umin, umax,c).real(); if (TMath::IsNaN(result)) { cxcoutE(Tracing) << "RooGaussModel::analyticalIntegral(" << GetName() << ") got nan during case 5 " << endl; } return result*ssfInt ; } @@ -392,8 +393,8 @@ Double_t RooGaussModel::analyticalIntegral(Int_t code, const char* rangeName) co if (verboseEval()>0) {cout << "RooGaussModel::analyticalIntegral(" << GetName() << ") 8th form tau=" << tau << endl ; } Double_t result(0) ; int sgn = ( basisType == coshBasis ? +1 : -1 ); - if (basisSign!=Minus) result += 0.5*( evalCerfInt(+1,0,tau/(1-_y),-umin,-umax,c*(1-_y)).re()+ sgn*evalCerfInt(+1,0,tau/(1+_y),-umin,-umax,c*(1+_y)).re()); - if (basisSign!=Plus) result += 0.5*(sgn*evalCerfInt(-1,0,tau/(1-_y), umin, umax,c*(1-_y)).re()+ evalCerfInt(-1,0,tau/(1+_y), umin, umax,c*(1+_y)).re()); + if (basisSign!=Minus) result += 0.5*( evalCerfInt(+1,0,tau/(1-_y),-umin,-umax,c*(1-_y)).real()+ sgn*evalCerfInt(+1,0,tau/(1+_y),-umin,-umax,c*(1+_y)).real()); + if (basisSign!=Plus) result += 0.5*(sgn*evalCerfInt(-1,0,tau/(1-_y), umin, umax,c*(1-_y)).real()+ evalCerfInt(-1,0,tau/(1+_y), umin, umax,c*(1+_y)).real()); if (TMath::IsNaN(result)) { cxcoutE(Tracing) << "RooGaussModel::analyticalIntegral(" << GetName() << ") got nan during case 6 " << endl; } return result*ssfInt ; } @@ -403,15 +404,15 @@ Double_t RooGaussModel::analyticalIntegral(Int_t code, const char* rangeName) co if (verboseEval()>0) cout << "RooGaussModel::analyticalIntegral(" << GetName() << ") 6th form tau=" << tau << endl ; Double_t f0 = RooMath::erf(-umax) - RooMath::erf(-umin); - Double_t f1 = exp(-umax*umax) - exp(-umin*umin); + Double_t f1 = std::exp(-umax*umax) - std::exp(-umin*umin); - Double_t tmp1 = exp(-xpmax)*RooMath::erfc(-umax + c); - Double_t tmp2 = exp(-xpmin)*RooMath::erfc(-umin + c); + Double_t tmp1 = std::exp(-xpmax)*RooMath::erfc(-umax + c); + Double_t tmp2 = std::exp(-xpmin)*RooMath::erfc(-umin + c); Double_t f2 = tmp1 - tmp2; Double_t f3 = xpmax*tmp1 - xpmin*tmp2; - Double_t expc2 = exp(c*c); + Double_t expc2 = std::exp(c*c); return -tau*( f0 + (2*c/rootpi)*f1 + @@ -426,20 +427,20 @@ Double_t RooGaussModel::analyticalIntegral(Int_t code, const char* rangeName) co Double_t f0 = RooMath::erf(-umax) - RooMath::erf(-umin); - Double_t tmpA1 = exp(-umax*umax); - Double_t tmpA2 = exp(-umin*umin); + Double_t tmpA1 = std::exp(-umax*umax); + Double_t tmpA2 = std::exp(-umin*umin); Double_t f1 = tmpA1 - tmpA2; Double_t f2 = umax*tmpA1 - umin*tmpA2; - Double_t tmpB1 = exp(-xpmax)*RooMath::erfc(-umax + c); - Double_t tmpB2 = exp(-xpmin)*RooMath::erfc(-umin + c); + Double_t tmpB1 = std::exp(-xpmax)*RooMath::erfc(-umax + c); + Double_t tmpB2 = std::exp(-xpmin)*RooMath::erfc(-umin + c); Double_t f3 = tmpB1 - tmpB2; Double_t f4 = xpmax*tmpB1 - xpmin*tmpB2; Double_t f5 = xpmax*xpmax*tmpB1 - xpmin*xpmin*tmpB2; - Double_t expc2 = exp(c*c); + Double_t expc2 = std::exp(c*c); return -tau*( 2*f0 + (4*c/rootpi)*((1-c*c)*f1 + c*f2) + @@ -450,34 +451,38 @@ Double_t RooGaussModel::analyticalIntegral(Int_t code, const char* rangeName) co return 0 ; } - - //_____________________________________________________________________________ -RooComplex RooGaussModel::evalCerfApprox(Double_t _x, Double_t u, Double_t c) const +std::complex<Double_t> RooGaussModel::evalCerfApprox(Double_t _x, Double_t u, Double_t c) { - // use the approximation: erf(z) = exp(-z*z)/(sqrt(pi)*z) + // use the approximation: erf(z) = exp(-z*z)/(std::sqrt(pi)*z) // to explicitly cancel the divergent exp(y*y) behaviour of // CWERF for z = x + i y with large negative y - static Double_t rootpi= sqrt(atan2(0.,-1.)); - RooComplex z(_x*c,u+c); - RooComplex zc(u+c,-_x*c); - RooComplex zsq= z*z; - RooComplex v= -zsq - u*u; + static const Double_t rootpi= std::sqrt(std::atan2(0.,-1.)); + const std::complex<Double_t> z(_x * c, u + c); + const std::complex<Double_t> zc(u + c, - _x * c); + const std::complex<Double_t> zsq((z.real() + z.imag()) * (z.real() - z.imag()), + 2. * z.real() * z.imag()); + const std::complex<Double_t> v(-zsq.real() - u*u, -zsq.imag()); + const std::complex<Double_t> ev = std::exp(v); + const std::complex<Double_t> mez2zcrootpi = -std::exp(zsq)/(zc*rootpi); - return v.exp()*(-zsq.exp()/(zc*rootpi) + 1)*2 ; + return 2. * (ev * (mez2zcrootpi + 1.)); } //_____________________________________________________________________________ -RooComplex RooGaussModel::evalCerfInt(Double_t sign, Double_t _x, Double_t tau, Double_t umin, Double_t umax, Double_t c) const +std::complex<Double_t> RooGaussModel::evalCerfInt(Double_t sign, Double_t _x, Double_t tau, Double_t umin, Double_t umax, Double_t c) const { - RooComplex diff; - if (_asympInt) { - diff = RooComplex(2,0) ; - } else { - diff = RooComplex(sign,0.)*(evalCerf(_x,umin,c) - evalCerf(_x,umax,c) + RooMath::erf(umin) - RooMath::erf(umax)); + std::complex<Double_t> diff(2., 0.); + if (!_asympInt) { + diff = evalCerf(_x,umin,c); + diff -= evalCerf(_x,umax,c); + diff += RooMath::erf(umin) - RooMath::erf(umax); + diff *= sign; } - return RooComplex(tau/(1.+_x*_x),0)*RooComplex(1,_x)*diff; + diff *= std::complex<Double_t>(1., _x); + diff *= tau / (1.+_x*_x); + return diff; } //_____________________________________________________________________________ diff --git a/roofit/roofit/src/RooGaussian.cxx b/roofit/roofit/src/RooGaussian.cxx index 3a4a1ff5085de..1e3dcdc0503d7 100644 --- a/roofit/roofit/src/RooGaussian.cxx +++ b/roofit/roofit/src/RooGaussian.cxx @@ -33,6 +33,8 @@ #include "RooRandom.h" #include "RooMath.h" +using namespace std; + ClassImp(RooGaussian) @@ -64,12 +66,34 @@ Double_t RooGaussian::evaluate() const Double_t arg= x - mean; Double_t sig = sigma ; Double_t ret =exp(-0.5*arg*arg/(sig*sig)) ; -// cout << "gauss(" << GetName() << ") x = " << x << " mean = " << mean << " sigma = " << sigma << " ret = " << ret << endl ; +// if (gDebug>2) { +// cout << "gauss(" << GetName() << ") x = " << x << " mean = " << mean << " sigma = " << sigma << " ret = " << ret << endl ; +// } return ret ; } +//_____________________________________________________________________________ +Double_t RooGaussian::getLogVal(const RooArgSet* set) const +{ + // calculate and return the negative log-likelihood of the Poisson + return RooAbsPdf::getLogVal(set) ; +// Double_t prob = getVal(set) ; +// return log(prob) ; + + Double_t arg= x - mean; + Double_t sig = sigma ; + + //static const Double_t rootPiBy2 = sqrt(atan2(0.0,-1.0)/2.0); + //Double_t extra = -0.5*arg*arg/(sig*sig) - log(2*rootPiBy2*sig) ; + Double_t extra = -0.5*arg*arg/(sig*sig) - log(analyticalIntegral(1,0)) ; + + return extra ; + +} + + //_____________________________________________________________________________ Int_t RooGaussian::getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVars, const char* /*rangeName*/) const { @@ -91,7 +115,9 @@ Double_t RooGaussian::analyticalIntegral(Int_t code, const char* rangeName) cons Double_t ret = 0; if(code==1){ ret = rootPiBy2*sigma*(RooMath::erf((x.max(rangeName)-mean)/xscale)-RooMath::erf((x.min(rangeName)-mean)/xscale)); -// cout << "Int_gauss_dx(mean=" << mean << ",sigma=" << sigma << ", xmin=" << x.min(rangeName) << ", xmax=" << x.max(rangeName) << ")=" << ret << endl ; +// if (gDebug>2) { +// cout << "Int_gauss_dx(mean=" << mean << ",sigma=" << sigma << ", xmin=" << x.min(rangeName) << ", xmax=" << x.max(rangeName) << ")=" << ret << endl ; +// } } else if(code==2) { ret = rootPiBy2*sigma*(RooMath::erf((mean.max(rangeName)-x)/xscale)-RooMath::erf((mean.min(rangeName)-x)/xscale)); } else{ diff --git a/roofit/roofit/src/RooHistConstraint.cxx b/roofit/roofit/src/RooHistConstraint.cxx index 65bfa9b194829..7c194ac8ceac0 100644 --- a/roofit/roofit/src/RooHistConstraint.cxx +++ b/roofit/roofit/src/RooHistConstraint.cxx @@ -16,6 +16,8 @@ #include <math.h> #include "TMath.h" +using namespace std; + ClassImp(RooHistConstraint) RooHistConstraint::RooHistConstraint(const char *name, const char *title, const RooArgSet& phfSet, Int_t threshold) : diff --git a/roofit/roofit/src/RooIntegralMorph.cxx b/roofit/roofit/src/RooIntegralMorph.cxx index 5dcf642e8ef8f..960137addbfe6 100644 --- a/roofit/roofit/src/RooIntegralMorph.cxx +++ b/roofit/roofit/src/RooIntegralMorph.cxx @@ -88,6 +88,8 @@ #include "RooDataHist.h" #include "TH1.h" +using namespace std; + ClassImp(RooIntegralMorph) diff --git a/roofit/roofit/src/RooJeffreysPrior.cxx b/roofit/roofit/src/RooJeffreysPrior.cxx index a2f66641fcccf..f4739970ef3de 100644 --- a/roofit/roofit/src/RooJeffreysPrior.cxx +++ b/roofit/roofit/src/RooJeffreysPrior.cxx @@ -29,6 +29,8 @@ #include "RooNumIntConfig.h" #include "RooRealVar.h" +using namespace std; + ClassImp(RooJeffreysPrior) ; diff --git a/roofit/roofit/src/RooKeysPdf.cxx b/roofit/roofit/src/RooKeysPdf.cxx index e4345d7779df9..3481cb9eee8af 100644 --- a/roofit/roofit/src/RooKeysPdf.cxx +++ b/roofit/roofit/src/RooKeysPdf.cxx @@ -16,6 +16,8 @@ *****************************************************************************/ #include "RooFit.h" +#include <limits> +#include <algorithm> #include <math.h> #include "Riostream.h" #include "TMath.h" @@ -26,6 +28,8 @@ #include "RooRandom.h" #include "RooDataSet.h" +using namespace std; + ClassImp(RooKeysPdf) @@ -62,7 +66,7 @@ RooKeysPdf::RooKeysPdf(const char *name, const char *title, RooAbsReal& x, RooDataSet& data, Mirror mirror, Double_t rho) : RooAbsPdf(name,title), - _x("x","Dependent",this,x), + _x("x","observable",this,x), _nEvents(0), _dataPts(0), _dataWgts(0), @@ -75,7 +79,36 @@ RooKeysPdf::RooKeysPdf(const char *name, const char *title, { // cache stuff about x snprintf(_varName, 128,"%s", x.GetName()); - RooRealVar real= (RooRealVar&)(_x.arg()); + RooAbsRealLValue& real= (RooRealVar&)(_x.arg()); + _lo = real.getMin(); + _hi = real.getMax(); + _binWidth = (_hi-_lo)/(_nPoints-1); + + // form the lookup table + LoadDataSet(data); +} + + + +//_____________________________________________________________________________ +RooKeysPdf::RooKeysPdf(const char *name, const char *title, + RooAbsReal& xpdf, RooRealVar& xdata, RooDataSet& data, + Mirror mirror, Double_t rho) : + RooAbsPdf(name,title), + _x("x","Observable",this,xpdf), + _nEvents(0), + _dataPts(0), + _dataWgts(0), + _weights(0), + _mirrorLeft(mirror==MirrorLeft || mirror==MirrorBoth || mirror==MirrorLeftAsymRight), + _mirrorRight(mirror==MirrorRight || mirror==MirrorBoth || mirror==MirrorAsymLeftRight), + _asymLeft(mirror==MirrorAsymLeft || mirror==MirrorAsymLeftRight || mirror==MirrorAsymBoth), + _asymRight(mirror==MirrorAsymRight || mirror==MirrorLeftAsymRight || mirror==MirrorAsymBoth), + _rho(rho) +{ + // cache stuff about x + snprintf(_varName, 128,"%s", xdata.GetName()); + RooAbsRealLValue& real= (RooRealVar&)(xdata); _lo = real.getMin(); _hi = real.getMax(); _binWidth = (_hi-_lo)/(_nPoints-1); @@ -148,7 +181,7 @@ RooKeysPdf::LoadDataSet( RooDataSet& data) { Int_t i, idata=0; for (i=0; i<data.numEntries(); i++) { const RooArgSet *values= data.get(i); - RooRealVar real= (RooRealVar&)(values->operator[](_varName)); + RooRealVar& real= (RooRealVar&)(values->operator[](_varName)); _dataPts[idata]= real.getVal(); _dataWgts[idata] = data.weight() ; @@ -195,24 +228,87 @@ RooKeysPdf::LoadDataSet( RooDataSet& data) { Double_t RooKeysPdf::evaluate() const { Int_t i = (Int_t)floor((Double_t(_x)-_lo)/_binWidth); if (i<0) { - cerr << "got point below lower bound:" - << Double_t(_x) << " < " << _lo - << " -- performing linear extrapolation..." << endl; +// cerr << "got point below lower bound:" +// << Double_t(_x) << " < " << _lo +// << " -- performing linear extrapolation..." << endl; i=0; } if (i>_nPoints-1) { - cerr << "got point above upper bound:" - << Double_t(_x) << " > " << _hi - << " -- performing linear extrapolation..." << endl; +// cerr << "got point above upper bound:" +// << Double_t(_x) << " > " << _hi +// << " -- performing linear extrapolation..." << endl; i=_nPoints-1; } Double_t dx = (Double_t(_x)-(_lo+i*_binWidth))/_binWidth; // for now do simple linear interpolation. // one day replace by splines... - return (_lookupTable[i]+dx*(_lookupTable[i+1]-_lookupTable[i])); + Double_t ret = (_lookupTable[i]+dx*(_lookupTable[i+1]-_lookupTable[i])); + if (ret<0) ret=0 ; + return ret ; } +Int_t RooKeysPdf::getAnalyticalIntegral( + RooArgSet& allVars, RooArgSet& analVars, const char* /* rangeName */) const +{ + if (matchArgs(allVars, analVars, _x)) return 1; + return 0; +} + +Double_t RooKeysPdf::analyticalIntegral(Int_t code, const char* rangeName) const +{ + assert(1 == code); + // this code is based on _lookupTable and uses linear interpolation, just as + // evaluate(); integration is done using the trapez rule + const Double_t xmin = std::max(_lo, _x.min(rangeName)); + const Double_t xmax = std::min(_hi, _x.max(rangeName)); + const Int_t imin = (Int_t)floor((xmin - _lo) / _binWidth); + const Int_t imax = std::min((Int_t)floor((xmax - _lo) / _binWidth), + _nPoints - 1); + Double_t sum = 0.; + // sum up complete bins in middle + if (imin + 1 < imax) + sum += _lookupTable[imin + 1] + _lookupTable[imax]; + for (Int_t i = imin + 2; i < imax; ++i) + sum += 2. * _lookupTable[i]; + sum *= _binWidth * 0.5; + // treat incomplete bins + const Double_t dxmin = (xmin - (_lo + imin * _binWidth)) / _binWidth; + const Double_t dxmax = (xmax - (_lo + imax * _binWidth)) / _binWidth; + if (imin < imax) { + // first bin + sum += _binWidth * (1. - dxmin) * 0.5 * (_lookupTable[imin + 1] + + _lookupTable[imin] + dxmin * + (_lookupTable[imin + 1] - _lookupTable[imin])); + // last bin + sum += _binWidth * dxmax * 0.5 * (_lookupTable[imax] + + _lookupTable[imax] + dxmax * + (_lookupTable[imax + 1] - _lookupTable[imax])); + } else if (imin == imax) { + // first bin == last bin + sum += _binWidth * (dxmax - dxmin) * 0.5 * ( + _lookupTable[imin] + dxmin * + (_lookupTable[imin + 1] - _lookupTable[imin]) + + _lookupTable[imax] + dxmax * + (_lookupTable[imax + 1] - _lookupTable[imax])); + } + return sum; +} + +Int_t RooKeysPdf::getMaxVal(const RooArgSet& vars) const +{ + if (vars.contains(*_x.absArg())) return 1; + return 0; +} + +Double_t RooKeysPdf::maxVal(Int_t code) const +{ + assert(1 == code); + Double_t max = -std::numeric_limits<Double_t>::max(); + for (Int_t i = 0; i <= _nPoints; ++i) + if (max < _lookupTable[i]) max = _lookupTable[i]; + return max; +} //_____________________________________________________________________________ Double_t RooKeysPdf::evaluateFull( Double_t x ) const { @@ -247,7 +343,6 @@ Double_t RooKeysPdf::evaluateFull( Double_t x ) const { return y/(sqrt2pi*_sumWgt); } - //_____________________________________________________________________________ Double_t RooKeysPdf::g(Double_t x,Double_t sigmav) const { diff --git a/roofit/roofit/src/RooLandau.cxx b/roofit/roofit/src/RooLandau.cxx index 670e67c639c6d..4c3c5ccc04c83 100644 --- a/roofit/roofit/src/RooLandau.cxx +++ b/roofit/roofit/src/RooLandau.cxx @@ -28,6 +28,8 @@ #include "RooLandau.h" #include "RooRandom.h" +using namespace std; + ClassImp(RooLandau) diff --git a/roofit/roofit/src/RooLegendre.cxx b/roofit/roofit/src/RooLegendre.cxx index 3e03241276e7d..9b7199f2a25c8 100644 --- a/roofit/roofit/src/RooLegendre.cxx +++ b/roofit/roofit/src/RooLegendre.cxx @@ -22,12 +22,15 @@ #include "Riostream.h" #include <math.h> #include <string> +#include <algorithm> #include "RooLegendre.h" #include "RooAbsReal.h" #include "Math/SpecFunc.h" #include "TMath.h" +using namespace std; + ClassImp(RooLegendre) ; @@ -84,8 +87,9 @@ Double_t RooLegendre::evaluate() const // Note: P_0^0 = 1, so P_l^m = P_l^m P_0^0 #ifdef R__HAS_MATHMORE double r = 1; - if (_l1!=0||_m1!=0) r *= ROOT::Math::assoc_legendre(_l1,_m1,_ctheta); - if (_l2!=0||_m2!=0) r *= ROOT::Math::assoc_legendre(_l2,_m2,_ctheta); + double ctheta = std::max(-1., std::min((double)_ctheta, +1.)); + if (_l1!=0||_m1!=0) r *= ROOT::Math::assoc_legendre(_l1,_m1,ctheta); + if (_l2!=0||_m2!=0) r *= ROOT::Math::assoc_legendre(_l2,_m2,ctheta); if ((_m1+_m2)%2==1) r = -r; return r; #else diff --git a/roofit/roofit/src/RooLognormal.cxx b/roofit/roofit/src/RooLognormal.cxx index 719031911b82e..18723af69a87d 100644 --- a/roofit/roofit/src/RooLognormal.cxx +++ b/roofit/roofit/src/RooLognormal.cxx @@ -41,6 +41,8 @@ #include <Math/PdfFuncMathCore.h> #include <Math/ProbFuncMathCore.h> +using namespace std; + ClassImp(RooLognormal) diff --git a/roofit/roofit/src/RooMomentMorph.cxx b/roofit/roofit/src/RooMomentMorph.cxx index 27e4af2e39cdd..1164e50966d98 100644 --- a/roofit/roofit/src/RooMomentMorph.cxx +++ b/roofit/roofit/src/RooMomentMorph.cxx @@ -22,12 +22,15 @@ #include "RooChangeTracker.h" #include "TMath.h" +#include "TH1.h" + +using namespace std; ClassImp(RooMomentMorph) //_____________________________________________________________________________ -RooMomentMorph::RooMomentMorph() : _curNormSet(0), _mref(0), _M(0) +RooMomentMorph::RooMomentMorph() : _curNormSet(0), _mref(0), _M(0), _useHorizMorph(true) { // coverity[UNINIT_CTOR] _varItr = _varList.createIterator() ; @@ -48,7 +51,8 @@ RooMomentMorph::RooMomentMorph(const char *name, const char *title, m("m","m",this,_m), _varList("varList","List of variables",this), _pdfList("pdfList","List of pdfs",this), - _setting(setting) + _setting(setting), + _useHorizMorph(true) { // CTOR @@ -98,7 +102,8 @@ RooMomentMorph::RooMomentMorph(const char *name, const char *title, m("m","m",this,_m), _varList("varList","List of variables",this), _pdfList("pdfList","List of pdfs",this), - _setting(setting) + _setting(setting), + _useHorizMorph(true) { // CTOR @@ -159,7 +164,8 @@ RooMomentMorph::RooMomentMorph(const RooMomentMorph& other, const char* name) : m("m",this,other.m), _varList("varList",this,other._varList), _pdfList("pdfList",this,other._pdfList), - _setting(other._setting) + _setting(other._setting), + _useHorizMorph(other._useHorizMorph) { _mref = new TVectorD(*other._mref) ; _varItr = _varList.createIterator() ; @@ -213,9 +219,9 @@ void RooMomentMorph::initialize() } //_____________________________________________________________________________ -RooMomentMorph::CacheElem* RooMomentMorph::getCache(const RooArgSet* nset) const +RooMomentMorph::CacheElem* RooMomentMorph::getCache(const RooArgSet* /*nset*/) const { - CacheElem* cache = (CacheElem*) _cacheMgr.getObj(nset,(RooArgSet*)0) ; + CacheElem* cache = (CacheElem*) _cacheMgr.getObj(0,(RooArgSet*)0) ; if (cache) { return cache ; } @@ -228,7 +234,7 @@ RooMomentMorph::CacheElem* RooMomentMorph::getCache(const RooArgSet* nset) const vector<RooAbsReal*> myrms(nVar,null); vector<RooAbsReal*> mypos(nVar,null); vector<RooAbsReal*> slope(nPdf*nVar,null); - vector<RooAbsReal*> offset(nPdf*nVar,null); + vector<RooAbsReal*> offs(nPdf*nVar,null); vector<RooAbsReal*> transVar(nPdf*nVar,null); vector<RooAbsReal*> transPdf(nPdf,null); @@ -246,79 +252,129 @@ RooMomentMorph::CacheElem* RooMomentMorph::getCache(const RooArgSet* nset) const else coefList2.add(*(RooRealVar*)(fracl.at(i))) ; ownedComps.add(*(RooRealVar*)(fracl.at(i))) ; } - // mean and sigma - RooArgList varList(_varList) ; - for (Int_t i=0; i<nPdf; ++i) { - for (Int_t j=0; j<nVar; ++j) { - std::string meanName = Form("%s_mean_%d_%d",GetName(),i,j); - std::string sigmaName = Form("%s_sigma_%d_%d",GetName(),i,j); - -// cout << "RooMomentMorph::getCache(" << GetName() << ") nset = " << (nset?*nset:RooArgSet()) << " creating moment for pdf " -// << _pdfList.at(i)->GetName() << " for observable " << varList.at(j)->GetName() << endl ; - - RooMoment* mom = nset ? ((RooAbsPdf*)_pdfList.at(i))->sigma((RooRealVar&)*varList.at(j),*nset) - : ((RooAbsPdf*)_pdfList.at(i))->sigma((RooRealVar&)*varList.at(j)) ; - - sigmarv[ij(i,j)] = mom ; - meanrv[ij(i,j)] = mom->mean() ; - - ownedComps.add(*sigmarv[ij(i,j)]) ; - } - } - // slope and offset (to be set later, depend on m) - for (Int_t j=0; j<nVar; ++j) { - RooArgList meanList("meanList"); - RooArgList rmsList("rmsList"); + RooAddPdf* theSumPdf = 0; + std::string sumpdfName = Form("%s_sumpdf",GetName()); + + if (_useHorizMorph) { + // mean and sigma + RooArgList varList(_varList) ; for (Int_t i=0; i<nPdf; ++i) { - meanList.add(*meanrv[ij(i,j)]); - rmsList.add(*sigmarv[ij(i,j)]); + for (Int_t j=0; j<nVar; ++j) { + + std::string meanName = Form("%s_mean_%d_%d",GetName(),i,j); + std::string sigmaName = Form("%s_sigma_%d_%d",GetName(),i,j); + + RooAbsPdf* thisPdf = (RooAbsPdf*)_pdfList.at(i); + + // fast calculation of mean and RMS for RooHistPdfs + if (thisPdf->IsA()->InheritsFrom("RooHistPdf") && nVar>1) { + + RooRealVar& var_j = (RooRealVar&)*varList.at(j); + + RooArgList notJ(_varList); + notJ.remove(var_j); + + //Make a ROOT histogram from the RooHistPdf + RooCmdArg zVarArg=RooCmdArg::none(); + if (nVar==3) zVarArg=RooFit::ZVar(*(RooRealVar*)notJ.at(1)); + + TH1 * hist = thisPdf->createHistogram("testProjection", var_j, + RooFit::YVar(*(RooRealVar*)notJ.at(0)), + zVarArg); + + //Read out the mean and sigma (RMS is historical name) + double histmean = hist->GetMean(1); // 1 gives mean along x-axis + double histsigma = hist->GetRMS(1); + + delete hist; + + sigmarv[ij(i,j)] = new RooRealVar(sigmaName.c_str(),sigmaName.c_str(), histsigma); + meanrv [ij(i,j)] = new RooRealVar(meanName.c_str(), meanName.c_str(), histmean); + + } + else { + + if (nVar>1) { + + //Create an integral over all observables except the j-th positioned one (and any variables in nset) + RooArgSet * notJ = new RooArgSet( varList, "notJ" ); + RooRealVar& var_j = (RooRealVar&)*varList.at(j); + notJ->remove( var_j ); + + RooAbsReal * intTest = thisPdf->createIntegral( *notJ ); + + //Get the mean and sigma with respect to the j-th observable + sigmarv[ij(i,j)] = intTest->sigma( var_j ); + meanrv [ij(i,j)] = intTest->mean ( var_j ); + } + else { + RooMoment* mom = ((RooAbsPdf*)_pdfList.at(i))->sigma((RooRealVar&)*varList.at(j)) ; + + sigmarv[ij(i,j)] = mom ; + meanrv[ij(i,j)] = mom->mean() ; + } + } + ownedComps.add(*sigmarv[ij(i,j)]) ; + } } - std::string myrmsName = Form("%s_rms_%d",GetName(),j); - std::string myposName = Form("%s_pos_%d",GetName(),j); - myrms[j] = new RooAddition(myrmsName.c_str(),myrmsName.c_str(),rmsList,coefList2); - mypos[j] = new RooAddition(myposName.c_str(),myposName.c_str(),meanList,coefList2); - ownedComps.add(RooArgSet(*myrms[j],*mypos[j])) ; - } - // construction of unit pdfs - _pdfItr->Reset(); - RooAbsPdf* pdf; - RooArgList transPdfList; - - for (Int_t i=0; i<nPdf; ++i) { - _varItr->Reset() ; - RooRealVar* var ; - - pdf = (RooAbsPdf*)_pdfItr->Next(); - std::string pdfName = Form("pdf_%d",i); - RooCustomizer cust(*pdf,pdfName.c_str()); - + + // slope and offset (to be set later, depend on m) for (Int_t j=0; j<nVar; ++j) { - // slope and offset formulas - std::string slopeName = Form("%s_slope_%d_%d",GetName(),i,j); - std::string offsetName = Form("%s_offset_%d_%d",GetName(),i,j); - slope[ij(i,j)] = new RooFormulaVar(slopeName.c_str(),"@0/@1",RooArgList(*sigmarv[ij(i,j)],*myrms[j])); - offset[ij(i,j)] = new RooFormulaVar(offsetName.c_str(),"@0-(@1*@2)",RooArgList(*meanrv[ij(i,j)],*mypos[j],*slope[ij(i,j)])); - ownedComps.add(RooArgSet(*slope[ij(i,j)],*offset[ij(i,j)])) ; - // linear transformations, so pdf can be renormalized - var = (RooRealVar*)(_varItr->Next()); - std::string transVarName = Form("%s_transVar_%d_%d",GetName(),i,j); - //transVar[ij(i,j)] = new RooFormulaVar(transVarName.c_str(),transVarName.c_str(),"@0*@1+@2",RooArgList(*var,*slope[ij(i,j)],*offset[ij(i,j)])); - transVar[ij(i,j)] = new RooLinearVar(transVarName.c_str(),transVarName.c_str(),*var,*slope[ij(i,j)],*offset[ij(i,j)]); - - ownedComps.add(*transVar[ij(i,j)]) ; - cust.replaceArg(*var,*transVar[ij(i,j)]); + RooArgList meanList("meanList"); + RooArgList rmsList("rmsList"); + for (Int_t i=0; i<nPdf; ++i) { + meanList.add(*meanrv[ij(i,j)]); + rmsList.add(*sigmarv[ij(i,j)]); + } + std::string myrmsName = Form("%s_rms_%d",GetName(),j); + std::string myposName = Form("%s_pos_%d",GetName(),j); + myrms[j] = new RooAddition(myrmsName.c_str(),myrmsName.c_str(),rmsList,coefList2); + mypos[j] = new RooAddition(myposName.c_str(),myposName.c_str(),meanList,coefList2); + ownedComps.add(RooArgSet(*myrms[j],*mypos[j])) ; + } + // construction of unit pdfs + _pdfItr->Reset(); + RooAbsPdf* pdf; + RooArgList transPdfList; + + for (Int_t i=0; i<nPdf; ++i) { + _varItr->Reset() ; + RooRealVar* var ; + + pdf = (RooAbsPdf*)_pdfItr->Next(); + std::string pdfName = Form("pdf_%d",i); + RooCustomizer cust(*pdf,pdfName.c_str()); + + for (Int_t j=0; j<nVar; ++j) { + // slope and offset formulas + std::string slopeName = Form("%s_slope_%d_%d",GetName(),i,j); + std::string offsetName = Form("%s_offset_%d_%d",GetName(),i,j); + slope[ij(i,j)] = new RooFormulaVar(slopeName.c_str(),"@0/@1",RooArgList(*sigmarv[ij(i,j)],*myrms[j])); + offs[ij(i,j)] = new RooFormulaVar(offsetName.c_str(),"@0-(@1*@2)",RooArgList(*meanrv[ij(i,j)],*mypos[j],*slope[ij(i,j)])); + ownedComps.add(RooArgSet(*slope[ij(i,j)],*offs[ij(i,j)])) ; + // linear transformations, so pdf can be renormalized + var = (RooRealVar*)(_varItr->Next()); + std::string transVarName = Form("%s_transVar_%d_%d",GetName(),i,j); + //transVar[ij(i,j)] = new RooFormulaVar(transVarName.c_str(),transVarName.c_str(),"@0*@1+@2",RooArgList(*var,*slope[ij(i,j)],*offs[ij(i,j)])); + transVar[ij(i,j)] = new RooLinearVar(transVarName.c_str(),transVarName.c_str(),*var,*slope[ij(i,j)],*offs[ij(i,j)]); + + ownedComps.add(*transVar[ij(i,j)]) ; + cust.replaceArg(*var,*transVar[ij(i,j)]); + } + transPdf[i] = (RooAbsPdf*) cust.build() ; + transPdfList.add(*transPdf[i]); + ownedComps.add(*transPdf[i]) ; } - transPdf[i] = (RooAbsPdf*) cust.build() ; - transPdfList.add(*transPdf[i]); - ownedComps.add(*transPdf[i]) ; + // sum pdf + + + theSumPdf = new RooAddPdf(sumpdfName.c_str(),sumpdfName.c_str(),transPdfList,coefList); + } + else { + theSumPdf = new RooAddPdf(sumpdfName.c_str(),sumpdfName.c_str(),_pdfList,coefList); } - // sum pdf - - std::string sumpdfName = Form("%s_sumpdf",GetName()); - - RooAbsPdf* theSumPdf = new RooAddPdf(sumpdfName.c_str(),sumpdfName.c_str(),transPdfList,coefList); theSumPdf->addOwnedComponents(ownedComps) ; // change tracker for fraction parameters @@ -328,7 +384,7 @@ RooMomentMorph::CacheElem* RooMomentMorph::getCache(const RooArgSet* nset) const // Store it in the cache cache = new CacheElem(*theSumPdf,*tracker,fracl) ; - _cacheMgr.setObj(nset,0,cache,0) ; + _cacheMgr.setObj(0,0,cache,0) ; return cache ; } @@ -431,6 +487,12 @@ void RooMomentMorph::CacheElem::calculateFractions(const RooMomentMorph& self, B case NonLinear: // default already set above break; + + case SineLinear: + mfrac = TMath::Sin( TMath::PiOver2()*mfrac ); // this gives a continuous differentiable transition between grid points. + + // now fall through to Linear case + case Linear: for (Int_t i=0; i<2*nPdf; ++i) ((RooRealVar*)frac(i))->setVal(0.); diff --git a/roofit/roofit/src/RooNDKeysPdf.cxx b/roofit/roofit/src/RooNDKeysPdf.cxx index c8364bba203dd..40ba1f7123280 100644 --- a/roofit/roofit/src/RooNDKeysPdf.cxx +++ b/roofit/roofit/src/RooNDKeysPdf.cxx @@ -1,7 +1,7 @@ /***************************************************************************** * Project: RooFit * * Package: RooFitModels * - * File: $Id$ + * File: $Id: RooNDKeysPdf.cxx 31258 2009-11-17 22:41:06Z wouter $ * Authors: * * Max Baak, CERN, mbaak@cern.ch * * * @@ -102,6 +102,50 @@ RooNDKeysPdf::RooNDKeysPdf(const char *name, const char *title, createPdf(); } +//_____________________________________________________________________________ +RooNDKeysPdf::RooNDKeysPdf(const char *name, const char *title, + const RooArgList& varList, RooDataSet& data, const TVectorD& rho, + TString options, Double_t nSigma, Bool_t rotate) : + RooAbsPdf(name,title), + _varList("varList","List of variables",this), + _data(data), + _options(options), + _widthFactor(-1.0), + _nSigma(nSigma), + _weights(&_weights0), + _rotate(rotate) +{ + // Constructor + _varItr = _varList.createIterator() ; + + TIterator* varItr = varList.createIterator() ; + RooAbsArg* var ; + for (Int_t i=0; (var = (RooAbsArg*)varItr->Next()); ++i) { + if (!dynamic_cast<RooAbsReal*>(var)) { + coutE(InputArguments) << "RhhNDKeysPdf::ctor(" << GetName() << ") ERROR: variable " << var->GetName() + << " is not of type RooAbsReal" << endl ; + assert(0) ; + } + _varList.add(*var) ; + _varName.push_back(var->GetName()); + } + delete varItr ; + + // copy rho widths + if( _varList.getSize() != rho.GetNrows() ) { + coutE(InputArguments) << "ERROR: RhhNDKeysPdf::RhhNDKeysPdf() : The vector-size of rho is different from that of varList." + << "Unable to create the PDF." << endl; + assert ( _varList.getSize()==rho.GetNrows() ); + } + + // negative width factor will serve as a switch in initialize() + // negative value means that a vector has been provided as input, + // and that _rho has already been set ... + _rho.resize( rho.GetNrows() ); + for (Int_t j=0; j<rho.GetNrows(); j++) { _rho[j]=rho[j]; /*cout<<"RooNDKeysPdf c'tor, _rho["<<j<<"]="<<_rho[j]<<endl;*/ } + + createPdf(); // calls initialize ... +} //_____________________________________________________________________________ @@ -281,13 +325,17 @@ RooNDKeysPdf::createPdf(Bool_t firstCall) const initialize(); } + // copy dataset, calculate sigma_i's, determine min and max event weight loadDataSet(firstCall); + // mirror dataset around dataset boundaries -- does not depend on event weights if (_mirror) mirrorDataSet(); + // store indices and weights of events with high enough weights loadWeightSet(); + // store indices of events in variable boundaries and box shell. //calculateShell(&_fullBoxInfo); // calculate normalization needed in analyticalIntegral() @@ -298,6 +346,7 @@ RooNDKeysPdf::createPdf(Bool_t firstCall) const // determine static and/or adaptive bandwidth calculateBandWidth(); + } @@ -366,7 +415,10 @@ RooNDKeysPdf::initialize() const //_sortIdcs.resize(_nDim); _sortTVIdcs.resize(_nDim); - _rho.resize(_nDim,_widthFactor); + //rdh _rho.resize(_nDim,_widthFactor); + + if (_widthFactor>0) { _rho.resize(_nDim,_widthFactor); } + // else: _rho has been provided as external input _x.resize(_nDim,0.); _x0.resize(_nDim,0.); @@ -412,11 +464,13 @@ RooNDKeysPdf::loadDataSet(Bool_t firstCall) const // first some initialization _nEventsW=0.; + TMatrixD mat(_nDim,_nDim); if (!_covMat) _covMat = new TMatrixDSym(_nDim); if (!_corrMat) _corrMat= new TMatrixDSym(_nDim); if (!_rotMat) _rotMat = new TMatrixD(_nDim,_nDim); - if (!_sigmaR) _sigmaR = new TVectorD(_nDim); + if (!_sigmaR) _sigmaR = new TVectorD(_nDim); + mat.Zero(); _covMat->Zero(); _corrMat->Zero(); @@ -432,6 +486,7 @@ RooNDKeysPdf::loadDataSet(Bool_t firstCall) const _idx.clear(); for (Int_t i=0; i<_nEvents; i++) { + _data.get(i); // fills dVars _idx.push_back(i); vector<Double_t>& point = _dataPts[i]; @@ -442,9 +497,9 @@ RooNDKeysPdf::loadDataSet(Bool_t firstCall) const _nEventsW += myweight; for (Int_t j=0; j<_nDim; j++) { - for (Int_t k=0; k<_nDim; k++) + for (Int_t k=0; k<_nDim; k++) { mat(j,k) += dVars[j]->getVal() * dVars[k]->getVal() * myweight; - + } // only need to do once if (firstCall) point[j] = pointV[j] = dVars[j]->getVal(); @@ -452,6 +507,7 @@ RooNDKeysPdf::loadDataSet(Bool_t firstCall) const _x0[j] += 1. * myweight; _x1[j] += point[j] * myweight ; _x2[j] += point[j] * point[j] * myweight ; + if (_x2[j]!=_x2[j]) exit(3); // only need to do once if (firstCall) { @@ -469,17 +525,25 @@ RooNDKeysPdf::loadDataSet(Bool_t firstCall) const _mean[j] = _x1[j]/_x0[j]; _sigma[j] = sqrt(_x2[j]/_x0[j]-_mean[j]*_mean[j]); } - + + TMatrixDSym covMatRho(_nDim); // covariance matrix times rho parameters for (Int_t j=0; j<_nDim; j++) { - for (Int_t k=0; k<_nDim; k++) - (*_covMat)(j,k) = mat(j,k)/_x0[j] - _mean[j]*_mean[k] ; + for (Int_t k=0; k<_nDim; k++) { + (*_covMat)(j,k) = mat(j,k)/_x0[j] - _mean[j]*_mean[k]; + covMatRho(j,k) = (mat(j,k)/_x0[j] - _mean[j]*_mean[k]) * _rho[j] * _rho[k]; + } } - + // find decorrelation matrix and eigenvalues (R) - TMatrixDSymEigen evCalculator(*_covMat); - *_rotMat = evCalculator.GetEigenVectors(); + TMatrixDSymEigen evCalculatorRho(covMatRho); + *_rotMat = evCalculatorRho.GetEigenVectors(); *_rotMat = _rotMat->T(); // transpose - *_sigmaR = evCalculator.GetEigenValues(); + *_sigmaR = evCalculatorRho.GetEigenValues(); + + + // set rho = 1 because sigmaR now contains rho + for (Int_t j=0; j<_nDim; j++) { _rho[j] = 1.; } + for (Int_t j=0; j<_nDim; j++) { (*_sigmaR)[j] = sqrt((*_sigmaR)[j]); } for (Int_t j=0; j<_nDim; j++) { @@ -505,11 +569,18 @@ RooNDKeysPdf::loadDataSet(Bool_t firstCall) const _sigmaR->Print(); } + // use raw sigmas (without rho) for sigmaAvgR + TMatrixDSymEigen evCalculator(*_covMat); + TVectorD sigmaRraw = evCalculator.GetEigenValues(); + for (Int_t j=0; j<_nDim; j++) { sigmaRraw[j] = sqrt(sigmaRraw[j]); } + _sigmaAvgR=1.; - for (Int_t j=0; j<_nDim; j++) { _sigmaAvgR *= (*_sigmaR)[j]; } + //for (Int_t j=0; j<_nDim; j++) { _sigmaAvgR *= (*_sigmaR)[j]; } + for (Int_t j=0; j<_nDim; j++) { _sigmaAvgR *= sigmaRraw[j]; } _sigmaAvgR = TMath::Power(_sigmaAvgR, 1./_d) ; for (Int_t i=0; i<_nEvents; i++) { + TVectorD& pointR = _dataPtsR[i]; pointR *= *_rotMat; } @@ -535,6 +606,9 @@ RooNDKeysPdf::mirrorDataSet() const for (Int_t j=0; j<_nDim; j++) { _xDatLo3s[j] = _xDatLo[j] + _nSigma * (_rho[j] * _n * _sigma[j]); _xDatHi3s[j] = _xDatHi[j] - _nSigma * (_rho[j] * _n * _sigma[j]); + + //cout<<"xDatLo3s["<<j<<"]="<<_xDatLo3s[j]<<endl; + //cout<<"xDatHi3s["<<j<<"]="<<_xDatHi3s[j]<<endl; } vector<Double_t> dummy(_nDim,0.); @@ -648,6 +722,11 @@ RooNDKeysPdf::calculateShell(BoxInfo* bi) const bi->xVarLoP3s[j] = bi->xVarLo[j] + _nSigma * (_rho[j] * _n * _sigma[j]); bi->xVarHiM3s[j] = bi->xVarHi[j] - _nSigma * (_rho[j] * _n * _sigma[j]); bi->xVarHiP3s[j] = bi->xVarHi[j] + _nSigma * (_rho[j] * _n * _sigma[j]); + + //cout<<"bi->xVarLoM3s["<<j<<"]="<<bi->xVarLoM3s[j]<<endl; + //cout<<"bi->xVarLoP3s["<<j<<"]="<<bi->xVarLoP3s[j]<<endl; + //cout<<"bi->xVarHiM3s["<<j<<"]="<<bi->xVarHiM3s[j]<<endl; + //cout<<"bi->xVarHiM3s["<<j<<"]="<<bi->xVarHiM3s[j]<<endl; } map<Int_t,Double_t>::iterator wMapItr = _wMap.begin(); @@ -767,13 +846,20 @@ RooNDKeysPdf::calculateBandWidth() const for (Int_t i=0; i<_nEvents; i++) { vector<Double_t>& weight = _weights0[i]; - for (Int_t j=0; j<_nDim; j++) { weight[j] = _rho[j] * _n * (*_sigmaR)[j] ; } + for (Int_t j=0; j<_nDim; j++) { + weight[j] = _rho[j] * _n * (*_sigmaR)[j] ; + //cout<<"j: "<<j<<", rho="<<_rho[j]<<", _n: "<<_n<<", sigmaR="<<(*_sigmaR)[j]<<", weight="<<weight[j]<<endl; + } } + // adaptive width if(_options.Contains("a")) { cxcoutD(Eval) << "RooNDKeysPdf::calculateBandWidth() Using adaptive bandwidth." << endl; - + + double sqrt12=sqrt(12.); + double sqrtSigmaAvgR=sqrt(_sigmaAvgR); + vector<Double_t> dummy(_nDim,0.); _weights1.resize(_nEvents,dummy); @@ -784,8 +870,9 @@ RooNDKeysPdf::calculateBandWidth() const vector<Double_t>& weight = _weights1[i]; for (Int_t j=0; j<_nDim; j++) { - Double_t norm = (_rho[j]*_n*(*_sigmaR)[j]) / sqrt(_sigmaAvgR) ; - weight[j] = norm * f / sqrt(12.) ; // note additional factor of sqrt(12) compared with HEP-EX/0011057 + Double_t norm = (_rho[j]*_n*(*_sigmaR)[j]) / sqrtSigmaAvgR ; + //cout<<"norm["<<j<<"]="<<norm<<endl; + weight[j] = norm * f / sqrt12 ; // note additional factor of sqrt(12) compared with HEP-EX/0011057 } } _weights = &_weights1; @@ -857,6 +944,8 @@ RooNDKeysPdf::loopRange(vector<Double_t>& x, map<Int_t,Bool_t>& ibMap) const for (Int_t j=0; j<_nDim; j++) { xRm[j] -= _nSigma * (_rho[j] * _n * (*_sigmaR)[j]); xRp[j] += _nSigma * (_rho[j] * _n * (*_sigmaR)[j]); + //cout<<"xRm["<<j<<"]="<<xRm[j]<<endl; + //cout<<"xRp["<<j<<"]="<<xRp[j]<<endl; } vector<TVectorD> xvecRm(1,xRm); @@ -936,6 +1025,7 @@ RooNDKeysPdf::evaluate() const } Double_t val = gauss(_x,*_weights); + //cout<<"returning "<<val<<endl; if (val>=1E-20) return val ; diff --git a/roofit/roofit/src/RooNonCPEigenDecay.cxx b/roofit/roofit/src/RooNonCPEigenDecay.cxx index bd527e0fefa47..8537f3cae394a 100644 --- a/roofit/roofit/src/RooNonCPEigenDecay.cxx +++ b/roofit/roofit/src/RooNonCPEigenDecay.cxx @@ -54,6 +54,8 @@ #include "TMath.h" #include "RooRealIntegral.h" +using namespace std; + ClassImp(RooNonCPEigenDecay); #define Debug_RooNonCPEigenDecay 1 diff --git a/roofit/roofit/src/RooNonCentralChiSquare.cxx b/roofit/roofit/src/RooNonCentralChiSquare.cxx index 565725fb164cb..08fbc9c0a3756 100644 --- a/roofit/roofit/src/RooNonCentralChiSquare.cxx +++ b/roofit/roofit/src/RooNonCentralChiSquare.cxx @@ -49,6 +49,8 @@ #include "RooMsgService.h" +using namespace std; + ClassImp(RooNonCentralChiSquare) RooNonCentralChiSquare::RooNonCentralChiSquare(const char *name, const char *title, diff --git a/roofit/roofit/src/RooNovosibirsk.cxx b/roofit/roofit/src/RooNovosibirsk.cxx index 9e3a629ba621d..8dd5f0fc68233 100644 --- a/roofit/roofit/src/RooNovosibirsk.cxx +++ b/roofit/roofit/src/RooNovosibirsk.cxx @@ -6,7 +6,10 @@ * DB, Dieter Best, UC Irvine, best@slac.stanford.edu * * HT, Hirohisa Tanaka SLAC tanaka@slac.stanford.edu * * * - * Copyright (c) 2000-2005, Regents of the University of California * + * Updated version with analytical integral * + * MP, Marko Petric, J. Stefan Institute, marko.petric@ijs.si * + * * + * Copyright (c) 2000-2013, Regents of the University of California * * and Stanford University. All rights reserved. * * * * Redistribution and use in source and binary forms, * @@ -17,7 +20,11 @@ ////////////////////////////////////////////////////////////////////////////// // // BEGIN_HTML +// // RooNovosibirsk implements the Novosibirsk function +// +// Function taken from H. Ikeda et al. NIM A441 (2000), p. 401 (Belle Collaboration) +// // END_HTML // @@ -30,6 +37,8 @@ #include "RooNovosibirsk.h" #include "RooRealVar.h" +using namespace std; + ClassImp(RooNovosibirsk) @@ -49,6 +58,7 @@ RooNovosibirsk::RooNovosibirsk(const char *name, const char *title, } + //_____________________________________________________________________________ RooNovosibirsk::RooNovosibirsk(const RooNovosibirsk& other, const char *name): RooAbsPdf(other,name), @@ -60,31 +70,154 @@ RooNovosibirsk::RooNovosibirsk(const RooNovosibirsk& other, const char *name): } + //_____________________________________________________________________________ -Double_t RooNovosibirsk::evaluate() const { - // Put the formula for your PDF's value here. Use the pre-computed - // value of _norm to normalize the result. - - double qa=0,qb=0,qc=0,qx=0,qy=0; - - if(TMath::Abs(tail) < 1.e-7) - qc = 0.5*TMath::Power(((x-peak)/width),2); - else { - qa = tail*sqrt(log(4.)); - qb = sinh(qa)/qa; - qx = (x-peak)/width*qb; - qy = 1.+tail*qx; +Double_t RooNovosibirsk::evaluate() const +{ + //If tail=eta=0 the Belle distribution becomes gaussian + if (TMath::Abs(tail) < 1.e-7) { + return TMath::Exp( -0.5 * TMath::Power( ( (x - peak) / width ), 2 )); + } - //---- Cutting curve from right side - - if( qy > 1.E-7) - qc = 0.5*(TMath::Power((log(qy)/tail),2) + tail*tail); - else - qc = 15.0; + Double_t arg = 1.0 - ( x - peak ) * tail / width; + + if (arg < 1.e-7) { + //Argument of logaritem negative. Real continuation -> function equals zero + return 0.0; } + + Double_t log = TMath::Log(arg); + static const Double_t xi = 2.3548200450309494; // 2 Sqrt( Ln(4) ) + + Double_t width_zero = ( 2.0 / xi ) * TMath::ASinH( tail * xi * 0.5 ); + Double_t width_zero2 = width_zero * width_zero; + Double_t exponent = ( -0.5 / (width_zero2) * log * log ) - ( width_zero2 * 0.5 ); + + return TMath::Exp(exponent) ; +} + + - //---- Normalize the result - return exp(-qc); +//_____________________________________________________________________________ +Int_t RooNovosibirsk::getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVars, const char* ) const +{ + if (matchArgs(allVars,analVars,x)) return 1 ; + if (matchArgs(allVars,analVars,peak)) return 2 ; + + //The other two integrals over tali and width are not integrable + + return 0 ; +} + + + +//_____________________________________________________________________________ +Double_t RooNovosibirsk::analyticalIntegral(Int_t code, const char* rangeName) const +{ + assert(code==1 || code==2) ; + + //The range is defined as [A,B] + + //Numerical values need for the evaluation of the integral + static const Double_t sqrt2 = 1.4142135623730950; // Sqrt(2) + static const Double_t sqlog2 = 0.832554611157697756; //Sqrt( Log(2) ) + static const Double_t sqlog4 = 1.17741002251547469; //Sqrt( Log(4) ) + static const Double_t log4 = 1.38629436111989062; //Log(2) + static const Double_t rootpiby2 = 1.2533141373155003; // Sqrt(pi/2) + static const Double_t sqpibylog2 = 2.12893403886245236; //Sqrt( pi/Log(2) ) + + if (code==1) { + Double_t A = x.min(rangeName); + Double_t B = x.max(rangeName); + + Double_t result = 0; + + + //If tail==0 the function becomes gaussian, thus we return a gassian integral + if (TMath::Abs(tail) < 1.e-7) { + + Double_t xscale = sqrt2*width; + + result = rootpiby2*width*(TMath::Erf((B-peak)/xscale)-TMath::Erf((A-peak)/xscale)); + + return result; + + } + + // If the range is not defined correctly the function becomes complex + Double_t log_argument_A = ( (peak - A)*tail + width ) / width ; + Double_t log_argument_B = ( (peak - B)*tail + width ) / width ; + + //lower limit + if ( log_argument_A < 1.e-7) { + log_argument_A = 1.e-7; + } + + //upper limit + if ( log_argument_B < 1.e-7) { + log_argument_B = 1.e-7; + } + + Double_t term1 = TMath::ASinH( tail * sqlog4 ); + Double_t term1_2 = term1 * term1; + + //Calculate the error function arguments + Double_t erf_termA = ( term1_2 - log4 * TMath::Log( log_argument_A ) ) / ( 2 * term1 * sqlog2 ); + Double_t erf_termB = ( term1_2 - log4 * TMath::Log( log_argument_B ) ) / ( 2 * term1 * sqlog2 ); + + result = 0.5 / tail * width * term1 * ( TMath::Erf(erf_termB) - TMath::Erf(erf_termA)) * sqpibylog2; + + return result; + + } else if (code==2) { + Double_t A = x.min(rangeName); + Double_t B = x.max(rangeName); + + Double_t result = 0; + + + //If tail==0 the function becomes gaussian, thus we return a gassian integral + if (TMath::Abs(tail) < 1.e-7) { + + Double_t xscale = sqrt2*width; + + result = rootpiby2*width*(TMath::Erf((B-x)/xscale)-TMath::Erf((A-x)/xscale)); + + return result; + + } + + // If the range is not defined correctly the function becomes complex + Double_t log_argument_A = ( (A - x)*tail + width ) / width; + Double_t log_argument_B = ( (B - x)*tail + width ) / width; + + //lower limit + if ( log_argument_A < 1.e-7) { + log_argument_A = 1.e-7; + } + + //upper limit + if ( log_argument_B < 1.e-7) { + log_argument_B = 1.e-7; + } + + Double_t term1 = TMath::ASinH( tail * sqlog4 ); + Double_t term1_2 = term1 * term1; + + //Calculate the error function arguments + Double_t erf_termA = ( term1_2 - log4 * TMath::Log( log_argument_A ) ) / ( 2 * term1 * sqlog2 ); + Double_t erf_termB = ( term1_2 - log4 * TMath::Log( log_argument_B ) ) / ( 2 * term1 * sqlog2 ); + + result = 0.5 / tail * width * term1 * ( TMath::Erf(erf_termB) - TMath::Erf(erf_termA)) * sqpibylog2; + + return result; + + } + + // Emit fatal error + coutF(Eval) << "Error in RooNovosibirsk::analyticalIntegral" << std::endl; + // Put dummy return here to avoid compiler warnings + return 1.0 ; } diff --git a/roofit/roofit/src/RooParamHistFunc.cxx b/roofit/roofit/src/RooParamHistFunc.cxx index a0fed0019f595..2ebc72dccc42c 100644 --- a/roofit/roofit/src/RooParamHistFunc.cxx +++ b/roofit/roofit/src/RooParamHistFunc.cxx @@ -14,6 +14,8 @@ #include <math.h> #include "TMath.h" +using namespace std; + ClassImp(RooParamHistFunc) ; diff --git a/roofit/roofit/src/RooParametricStepFunction.cxx b/roofit/roofit/src/RooParametricStepFunction.cxx index a7098b66e8877..1d2913ddbde48 100644 --- a/roofit/roofit/src/RooParametricStepFunction.cxx +++ b/roofit/roofit/src/RooParametricStepFunction.cxx @@ -52,6 +52,8 @@ #include "RooRealVar.h" #include "RooArgList.h" +using namespace std; + ClassImp(RooParametricStepFunction) ; diff --git a/roofit/roofit/src/RooPoisson.cxx b/roofit/roofit/src/RooPoisson.cxx index c6b6934fae7cf..d3c78ba05a132 100644 --- a/roofit/roofit/src/RooPoisson.cxx +++ b/roofit/roofit/src/RooPoisson.cxx @@ -24,6 +24,8 @@ #include "TMath.h" #include "Math/ProbFuncMathCore.h" +using namespace std; + ClassImp(RooPoisson) @@ -71,12 +73,58 @@ Double_t RooPoisson::evaluate() const +//_____________________________________________________________________________ +Double_t RooPoisson::getLogVal(const RooArgSet* s) const +{ + // calculate and return the negative log-likelihood of the Poisson + return RooAbsPdf::getLogVal(s) ; +// Double_t prob = getVal(s) ; +// return prob ; + + // Make inputs to naming conventions of RooAbsPdf::extendedTerm + Double_t expected=mean ; + Double_t observed=x ; + + // Explicitly handle case Nobs=Nexp=0 + if (fabs(expected)<1e-10 && fabs(observed)<1e-10) { + return 0 ; + } + + // Explicitly handle case Nexp=0 + if (fabs(observed)<1e-10) { + return -1*expected; + } + + // Michaels code for log(poisson) in RooAbsPdf::extendedTer with an approximated log(observed!) term + Double_t extra=0; + if(observed<1000000) { + extra = -observed*log(expected)+expected+TMath::LnGamma(observed+1.); + } else { + //if many observed events, use Gauss approximation + Double_t sigma_square=expected; + Double_t diff=observed-expected; + extra=-log(sigma_square)/2 + (diff*diff)/(2*sigma_square); + } + +// if (fabs(extra)>100 || log(prob)>100) { +// cout << "RooPoisson::getLogVal(" << GetName() << ") mu=" << expected << " x = " << x << " -log(P) = " << extra << " log(evaluate()) = " << log(prob) << endl ; +// } + +// if (fabs(extra+log(prob))>1) { +// cout << "RooPoisson::getLogVal(" << GetName() << ") WARNING mu=" << expected << " x = " << x << " -log(P) = " << extra << " log(evaluate()) = " << log(prob) << endl ; +// } + + //return log(prob); + return -extra-analyticalIntegral(1,0) ; //log(prob); + +} //_____________________________________________________________________________ Int_t RooPoisson::getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVars, const char* /*rangeName*/) const { if (matchArgs(allVars,analVars,x)) return 1 ; + if (matchArgs(allVars, analVars, mean)) return 2; return 0 ; } @@ -85,57 +133,73 @@ Int_t RooPoisson::getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVars, //_____________________________________________________________________________ Double_t RooPoisson::analyticalIntegral(Int_t code, const char* rangeName) const { - assert(code==1) ; + assert(code == 1 || code == 2) ; if(_protectNegative && mean<0) return exp(-2*mean); // make it fall quickly - // Implement integral over x as summation. Add special handling in case - // range boundaries are not on integer values of x - Double_t xmin = x.min(rangeName) ; - Double_t xmax = x.max(rangeName) ; + if (code == 1) { + // Implement integral over x as summation. Add special handling in case + // range boundaries are not on integer values of x + Double_t xmin = x.min(rangeName) ; + Double_t xmax = x.max(rangeName) ; - // Protect against negative lower boundaries - if (xmin<0) xmin=0 ; + // Protect against negative lower boundaries + if (xmin<0) xmin=0 ; - Int_t ixmin = Int_t (xmin) ; - Int_t ixmax = Int_t (xmax)+1 ; + Int_t ixmin = Int_t (xmin) ; + Int_t ixmax = Int_t (xmax)+1 ; - Double_t fracLoBin = 1-(xmin-ixmin) ; - Double_t fracHiBin = 1-(ixmax-xmax) ; + Double_t fracLoBin = 1-(xmin-ixmin) ; + Double_t fracHiBin = 1-(ixmax-xmax) ; - if (!x.hasMax()) { - if (xmin<1e-6) { - return 1 ; - } else { + if (!x.hasMax()) { + if (xmin<1e-6) { + return 1 ; + } else { // Return 1 minus integral from 0 to x.min() - if(ixmin == 0){ // first bin - return TMath::Poisson(0, mean)*(xmin-0); - } - Double_t sum(0) ; - sum += TMath::Poisson(0,mean)*fracLoBin ; - sum+= ROOT::Math::poisson_cdf(ixmin-2, mean) - ROOT::Math::poisson_cdf(0,mean) ; - sum += TMath::Poisson(ixmin-1,mean)*fracHiBin ; - return 1-sum ; + if(ixmin == 0){ // first bin + return TMath::Poisson(0, mean)*(xmin-0); + } + Double_t sum(0) ; + sum += TMath::Poisson(0,mean)*fracLoBin ; + sum+= ROOT::Math::poisson_cdf(ixmin-2, mean) - ROOT::Math::poisson_cdf(0,mean) ; + sum += TMath::Poisson(ixmin-1,mean)*fracHiBin ; + return 1-sum ; + } } - } - if(ixmin == ixmax-1){ // first bin - return TMath::Poisson(ixmin, mean)*(xmax-xmin); - } - - Double_t sum(0) ; - sum += TMath::Poisson(ixmin,mean)*fracLoBin ; - if (RooNumber::isInfinite(xmax)){ - sum+= 1.-ROOT::Math::poisson_cdf(ixmin,mean) ; - } else { - sum+= ROOT::Math::poisson_cdf(ixmax-2, mean) - ROOT::Math::poisson_cdf(ixmin,mean) ; - sum += TMath::Poisson(ixmax-1,mean)*fracHiBin ; - } + if(ixmin == ixmax-1){ // first bin + return TMath::Poisson(ixmin, mean)*(xmax-xmin); + } + + Double_t sum(0) ; + sum += TMath::Poisson(ixmin,mean)*fracLoBin ; + if (RooNumber::isInfinite(xmax)){ + sum+= 1.-ROOT::Math::poisson_cdf(ixmin,mean) ; + } else { + sum+= ROOT::Math::poisson_cdf(ixmax-2, mean) - ROOT::Math::poisson_cdf(ixmin,mean) ; + sum += TMath::Poisson(ixmax-1,mean)*fracHiBin ; + } - return sum ; + return sum ; + + } else if(code == 2) { + + // the integral with respect to the mean is the integral of a gamma distribution + Double_t mean_min = mean.min(rangeName); + Double_t mean_max = mean.max(rangeName); + + Double_t ix; + if(_noRounding) ix = x + 1; + else ix = Int_t(TMath::Floor(x)) + 1.0; // negative ix does not need protection (gamma returns 0.0) + + return ROOT::Math::gamma_cdf(mean_max, ix, 1.0) - ROOT::Math::gamma_cdf(mean_min, ix, 1.0); + } + + return 0; } diff --git a/roofit/roofit/src/RooPolynomial.cxx b/roofit/roofit/src/RooPolynomial.cxx index e8fdb3b37d6ed..cd78b78d8fc72 100644 --- a/roofit/roofit/src/RooPolynomial.cxx +++ b/roofit/roofit/src/RooPolynomial.cxx @@ -38,6 +38,8 @@ #include "RooRealVar.h" #include "RooArgList.h" +using namespace std; + ClassImp(RooPolynomial) ; diff --git a/roofit/roofit/src/RooSpHarmonic.cxx b/roofit/roofit/src/RooSpHarmonic.cxx index 364683645fac0..440fad39412e3 100644 --- a/roofit/roofit/src/RooSpHarmonic.cxx +++ b/roofit/roofit/src/RooSpHarmonic.cxx @@ -51,6 +51,8 @@ #include "Math/SpecFunc.h" #include "TMath.h" +using namespace std; + ClassImp(RooSpHarmonic) ; diff --git a/roofit/roofit/src/RooStepFunction.cxx b/roofit/roofit/src/RooStepFunction.cxx index 8ed184ac71983..91af6b5b2d457 100644 --- a/roofit/roofit/src/RooStepFunction.cxx +++ b/roofit/roofit/src/RooStepFunction.cxx @@ -40,6 +40,8 @@ #include "RooMsgService.h" #include "RooMath.h" +using namespace std; + ClassImp(RooStepFunction) ; @@ -49,6 +51,7 @@ RooStepFunction::RooStepFunction() { // Constructor _coefIter = _coefList.createIterator() ; + _boundIter = _boundaryList.createIterator() ; _interpolate = kFALSE ; } @@ -78,6 +81,7 @@ RooStepFunction::RooStepFunction(const char* name, const char* title, } delete coefIter ; + _boundIter = _boundaryList.createIterator() ; TIterator* boundaryIter = boundaryList.createIterator() ; RooAbsArg* boundary ; while((boundary = (RooAbsArg*)boundaryIter->Next())) { diff --git a/roofit/roofit/src/RooTFnBinding.cxx b/roofit/roofit/src/RooTFnBinding.cxx index 7efa7c2312cea..792ff9f140a11 100644 --- a/roofit/roofit/src/RooTFnBinding.cxx +++ b/roofit/roofit/src/RooTFnBinding.cxx @@ -13,6 +13,8 @@ #include "RooAbsCategory.h" #include "TF3.h" +using namespace std; + ClassImp(RooTFnBinding) RooTFnBinding::RooTFnBinding(const char *name, const char *title, TF1* _func, const RooArgList& _list) : diff --git a/roofit/roofit/src/RooTFnPdfBinding.cxx b/roofit/roofit/src/RooTFnPdfBinding.cxx index 65d066aef33ce..7316db5b8f314 100644 --- a/roofit/roofit/src/RooTFnPdfBinding.cxx +++ b/roofit/roofit/src/RooTFnPdfBinding.cxx @@ -13,6 +13,8 @@ #include "RooAbsCategory.h" #include "TF3.h" +using namespace std; + ClassImp(RooTFnPdfBinding) RooTFnPdfBinding::RooTFnPdfBinding(const char *name, const char *title, TF1* _func, const RooArgList& _list) : diff --git a/roofit/roofit/src/RooUnblindCPAsymVar.cxx b/roofit/roofit/src/RooUnblindCPAsymVar.cxx index 286bae3cc7ba9..0cbfe01d26100 100644 --- a/roofit/roofit/src/RooUnblindCPAsymVar.cxx +++ b/roofit/roofit/src/RooUnblindCPAsymVar.cxx @@ -37,6 +37,8 @@ #include "RooUnblindCPAsymVar.h" +using namespace std; + ClassImp(RooUnblindCPAsymVar) ; diff --git a/roofit/roofit/src/RooUnblindOffset.cxx b/roofit/roofit/src/RooUnblindOffset.cxx index 4e663cc169118..efc26a071b099 100644 --- a/roofit/roofit/src/RooUnblindOffset.cxx +++ b/roofit/roofit/src/RooUnblindOffset.cxx @@ -37,6 +37,8 @@ #include "RooUnblindOffset.h" +using namespace std; + ClassImp(RooUnblindOffset) ; diff --git a/roofit/roofit/src/RooUnblindPrecision.cxx b/roofit/roofit/src/RooUnblindPrecision.cxx index 3e989143bc1db..f4508ea501d86 100644 --- a/roofit/roofit/src/RooUnblindPrecision.cxx +++ b/roofit/roofit/src/RooUnblindPrecision.cxx @@ -37,6 +37,8 @@ #include "RooUnblindPrecision.h" +using namespace std; + ClassImp(RooUnblindPrecision) ; diff --git a/roofit/roofit/src/RooUnblindUniform.cxx b/roofit/roofit/src/RooUnblindUniform.cxx index b8ab7037302ae..49dced0063186 100644 --- a/roofit/roofit/src/RooUnblindUniform.cxx +++ b/roofit/roofit/src/RooUnblindUniform.cxx @@ -36,6 +36,8 @@ #include "RooUnblindUniform.h" +using namespace std; + ClassImp(RooUnblindUniform) ; diff --git a/roofit/roofit/src/RooUniform.cxx b/roofit/roofit/src/RooUniform.cxx index 4e66888efe031..41632f6ffe652 100644 --- a/roofit/roofit/src/RooUniform.cxx +++ b/roofit/roofit/src/RooUniform.cxx @@ -33,6 +33,8 @@ #include "RooMath.h" #include "RooArgSet.h" +using namespace std; + ClassImp(RooUniform) diff --git a/roofit/roofit/src/RooVoigtian.cxx b/roofit/roofit/src/RooVoigtian.cxx index 4cf7f18e48c05..bfc78e9afb44c 100644 --- a/roofit/roofit/src/RooVoigtian.cxx +++ b/roofit/roofit/src/RooVoigtian.cxx @@ -26,19 +26,20 @@ // END_HTML // +#include <cmath> +#include <complex> #include "RooFit.h" #include "Riostream.h" -#include "Riostream.h" -#include <math.h> #include "RooVoigtian.h" #include "RooAbsReal.h" #include "RooRealVar.h" -#include "RooComplex.h" #include "RooMath.h" +using namespace std; + ClassImp(RooVoigtian) @@ -92,14 +93,14 @@ Double_t RooVoigtian::evaluate() const Double_t c = 1./(sqrt(2.)*s); Double_t a = 0.5*c*w; Double_t u = c*arg; - RooComplex z(u,a) ; - RooComplex v(0.) ; + std::complex<Double_t> z(u,a) ; + std::complex<Double_t> v(0.) ; if (_doFast) { - v = RooMath::FastComplexErrFunc(z); + v = RooMath::faddeeva_fast(z); } else { - v = RooMath::ComplexErrFunc(z); + v = RooMath::faddeeva(z); } - return c*_invRootPi*v.re(); + return c*_invRootPi*v.real(); } diff --git a/roofit/roofitcore/CMakeLists.txt b/roofit/roofitcore/CMakeLists.txt index 9ec66bc54212d..d04cbf912a341 100644 --- a/roofit/roofitcore/CMakeLists.txt +++ b/roofit/roofitcore/CMakeLists.txt @@ -31,7 +31,8 @@ set(headers3 RooRandomizeParamMCSModule.h RooRangeBinning.h RooRealAnalytic.h Ro RooProjectedPdf.h RooWorkspace.h RooProfileLL.h RooAbsCachedPdf.h RooAbsSelfCachedPdf.h RooHistPdf.h RooCachedPdf.h RooFFTConvPdf.h RooDataHistSliceIter.h RooCacheManager.h RooAbsCache.h RooAbsCacheElement.h RooObjCacheManager.h RooExtendedTerm.h RooSentinel.h - RooParamBinning.h RooConstraintSum.h RooRecursiveFraction.h RooDataWeightedAverage.h + RooParamBinning.h) +set(headers4 RooConstraintSum.h RooRecursiveFraction.h RooDataWeightedAverage.h RooSimWSTool.h RooFracRemainder.h RooAbsCachedReal.h RooAbsSelfCachedReal.h RooCachedReal.h RooNumCdf.h RooChangeTracker.h RooNumRunningInt.h RooHistFunc.h RooExpensiveObjectCache.h RooBinningCategory.h RooCintUtils.h RooFactoryWSTool.h RooTFoamBinding.h RooFunctor.h @@ -40,15 +41,16 @@ set(headers3 RooRandomizeParamMCSModule.h RooRangeBinning.h RooRealAnalytic.h Ro RooMultiVarGaussian.h RooXYChi2Var.h RooAbsDataStore.h RooTreeDataStore.h RooTreeData.h RooMinimizer.h RooMinimizerFcn.h RooMoment.h RooStudyManager.h RooAbsStudy.h RooGenFitStudy.h RooProofDriverSelector.h RooStudyPackage.h RooCompositeDataStore.h RooRangeBoolean.h - RooVectorDataStore.h RooUnitTest.h) + RooVectorDataStore.h RooUnitTest.h RooExtendedBinding.h) ROOT_GENERATE_DICTIONARY(G__RooFitCore1 ${headers1} LINKDEF LinkDef1.h) ROOT_GENERATE_DICTIONARY(G__RooFitCore2 ${headers2} LINKDEF LinkDef2.h) ROOT_GENERATE_DICTIONARY(G__RooFitCore3 ${headers3} LINKDEF LinkDef3.h) +ROOT_GENERATE_DICTIONARY(G__RooFitCore4 ${headers4} LINKDEF LinkDef4.h) -ROOT_GENERATE_ROOTMAP(RooFitCore LINKDEF LinkDef1.h LinkDef2.h LinkDef3.h +ROOT_GENERATE_ROOTMAP(RooFitCore LINKDEF LinkDef1.h LinkDef2.h LinkDef3.h LinkDef4.h DEPENDENCIES Hist Graf Matrix Tree Minuit RIO MathCore Foam ) -ROOT_LINKER_LIBRARY(RooFitCore *.cxx G__RooFitCore1.cxx G__RooFitCore2.cxx G__RooFitCore3.cxx LIBRARIES Core Cint +ROOT_LINKER_LIBRARY(RooFitCore *.cxx G__RooFitCore1.cxx G__RooFitCore2.cxx G__RooFitCore3.cxx G__RooFitCore4.cxx LIBRARIES Core Cint DEPENDENCIES Hist Graf Matrix Tree Minuit RIO MathCore Foam) ROOT_INSTALL_HEADERS() diff --git a/roofit/roofitcore/Module.mk b/roofit/roofitcore/Module.mk index 16e37baf7956e..8a7910be0ff29 100644 --- a/roofit/roofitcore/Module.mk +++ b/roofit/roofitcore/Module.mk @@ -16,15 +16,18 @@ ROOFITCOREDIRI := $(ROOFITCOREDIR)/inc ROOFITCOREL1 := $(MODDIRI)/LinkDef1.h ROOFITCOREL2 := $(MODDIRI)/LinkDef2.h ROOFITCOREL3 := $(MODDIRI)/LinkDef3.h +ROOFITCOREL4 := $(MODDIRI)/LinkDef4.h ROOFITCOREDS1 := $(call stripsrc,$(MODDIRS)/G__RooFitCore1.cxx) ROOFITCOREDS2 := $(call stripsrc,$(MODDIRS)/G__RooFitCore2.cxx) ROOFITCOREDS3 := $(call stripsrc,$(MODDIRS)/G__RooFitCore3.cxx) +ROOFITCOREDS4 := $(call stripsrc,$(MODDIRS)/G__RooFitCore4.cxx) ROOFITCOREDO1 := $(ROOFITCOREDS1:.cxx=.o) ROOFITCOREDO2 := $(ROOFITCOREDS2:.cxx=.o) ROOFITCOREDO3 := $(ROOFITCOREDS3:.cxx=.o) -ROOFITCOREL := $(ROOFITCOREL1) $(ROOFITCOREL2) $(ROOFITCOREL3) -ROOFITCOREDS := $(ROOFITCOREDS1) $(ROOFITCOREDS2) $(ROOFITCOREDS3) -ROOFITCOREDO := $(ROOFITCOREDO1) $(ROOFITCOREDO2) $(ROOFITCOREDO3) +ROOFITCOREDO4 := $(ROOFITCOREDS4:.cxx=.o) +ROOFITCOREL := $(ROOFITCOREL1) $(ROOFITCOREL2) $(ROOFITCOREL3) $(ROOFITCOREL4) +ROOFITCOREDS := $(ROOFITCOREDS1) $(ROOFITCOREDS2) $(ROOFITCOREDS3) $(ROOFITCOREDS4) +ROOFITCOREDO := $(ROOFITCOREDO1) $(ROOFITCOREDO2) $(ROOFITCOREDO3) $(ROOFITCOREDO4) ROOFITCOREDH := $(ROOFITCOREDS:.cxx=.h) ROOFITCOREH1 := Roo1DTable.h RooAbsArg.h RooAbsBinning.h RooAbsCategory.h \ @@ -79,7 +82,9 @@ ROOFITCOREH3 := RooRandomizeParamMCSModule.h RooRangeBinning.h RooRealAnalytic RooProjectedPdf.h RooWorkspace.h RooProfileLL.h RooAbsCachedPdf.h RooAbsSelfCachedPdf.h \ RooHistPdf.h RooCachedPdf.h RooFFTConvPdf.h RooDataHistSliceIter.h RooCacheManager.h \ RooAbsCache.h RooAbsCacheElement.h RooObjCacheManager.h RooExtendedTerm.h RooSentinel.h \ - RooParamBinning.h RooConstraintSum.h RooRecursiveFraction.h RooDataWeightedAverage.h \ + RooParamBinning.h + +ROOFITCOREH4 := RooConstraintSum.h RooRecursiveFraction.h RooDataWeightedAverage.h \ RooSimWSTool.h RooFracRemainder.h RooAbsCachedReal.h \ RooAbsSelfCachedReal.h RooCachedReal.h RooNumCdf.h RooChangeTracker.h \ RooNumRunningInt.h RooHistFunc.h RooExpensiveObjectCache.h \ @@ -89,12 +94,13 @@ ROOFITCOREH3 := RooRandomizeParamMCSModule.h RooRangeBinning.h RooRealAnalytic RooMultiVarGaussian.h RooXYChi2Var.h RooAbsDataStore.h RooTreeDataStore.h RooTreeData.h \ RooMinimizer.h RooMinimizerFcn.h RooMoment.h RooStudyManager.h RooAbsStudy.h \ RooGenFitStudy.h RooProofDriverSelector.h RooStudyPackage.h RooCompositeDataStore.h \ - RooRangeBoolean.h RooVectorDataStore.h RooUnitTest.h + RooRangeBoolean.h RooVectorDataStore.h RooUnitTest.h RooExtendedBinding.h ROOFITCOREH1 := $(patsubst %,$(MODDIRI)/%,$(ROOFITCOREH1)) ROOFITCOREH2 := $(patsubst %,$(MODDIRI)/%,$(ROOFITCOREH2)) ROOFITCOREH3 := $(patsubst %,$(MODDIRI)/%,$(ROOFITCOREH3)) -ROOFITCOREH := $(ROOFITCOREH1) $(ROOFITCOREH2) $(ROOFITCOREH3) +ROOFITCOREH4 := $(patsubst %,$(MODDIRI)/%,$(ROOFITCOREH4)) +ROOFITCOREH := $(ROOFITCOREH1) $(ROOFITCOREH2) $(ROOFITCOREH3) $(ROOFITCOREH4) ROOFITCORES := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx)) ROOFITCOREO := $(call stripsrc,$(ROOFITCORES:.cxx=.o)) @@ -122,7 +128,7 @@ $(ROOFITCORELIB): $(ROOFITCOREO) $(ROOFITCOREDO) $(ORDER_) $(MAINLIBS) \ @$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \ "$(SOFLAGS)" libRooFitCore.$(SOEXT) $@ \ "$(ROOFITCOREO) $(ROOFITCOREDO)" \ - "$(ROOFITCORELIBEXTRA)" + "$(ROOFITCORELIBEXTRA) $(OSTHREADLIBDIR) $(OSTHREADLIB)" $(ROOFITCOREDS1): $(ROOFITCOREH1) $(ROOFITCOREL1) $(ROOTCINTTMPDEP) $(MAKEDIR) @@ -139,6 +145,11 @@ $(ROOFITCOREDS3): $(ROOFITCOREH3) $(ROOFITCOREL3) $(ROOTCINTTMPDEP) @echo "Generating dictionary $@..." $(ROOTCINTTMP) -f $@ -c $(ROOFITCOREH3) $(ROOFITCOREL3) +$(ROOFITCOREDS4): $(ROOFITCOREH4) $(ROOFITCOREL4) $(ROOTCINTTMPDEP) + $(MAKEDIR) + @echo "Generating dictionary $@..." + $(ROOTCINTTMP) -f $@ -c $(ROOFITCOREH4) $(ROOFITCOREL4) + $(ROOFITCOREMAP): $(RLIBMAP) $(MAKEFILEDEP) $(ROOFITCOREL) $(RLIBMAP) -o $@ -l $(ROOFITCORELIB) \ -d $(ROOFITCORELIBDEPM) -c $(ROOFITCOREL) @@ -160,3 +171,4 @@ distclean:: distclean-$(MODNAME) $(ROOFITCOREDO1): NOOPT = $(OPT) $(ROOFITCOREDO2): NOOPT = $(OPT) $(ROOFITCOREDO3): NOOPT = $(OPT) +$(ROOFITCOREDO4): NOOPT = $(OPT) diff --git a/roofit/roofitcore/inc/LinkDef1.h b/roofit/roofitcore/inc/LinkDef1.h index 7c495af9e855d..c534931ab7dfb 100644 --- a/roofit/roofitcore/inc/LinkDef1.h +++ b/roofit/roofitcore/inc/LinkDef1.h @@ -4,8 +4,11 @@ #pragma link off all functions; #pragma link C++ class Roo1DTable+ ; #pragma link C++ class RooAbsArg- ; +#pragma link C++ class RooRefArray- ; #pragma read sourceClass="RooAbsArg" targetClass="RooAbsArg" version="[1-4]" source="TList _proxyList" target="_proxyList" \ code="{ TIterator* iter = onfile._proxyList.MakeIterator() ; TObject* tmpObj ; while ((tmpObj = iter->Next())) { _proxyList.Add(tmpObj) ; } delete iter ; }" +#pragma read sourceClass="RooAbsArg" targetClass="RooAbsArg" version="[5]" source="TRefArray _proxyList" target="_proxyList" \ + code="{ _proxyList.GetSize() ; if (onfile._proxyList.GetSize()>0) { RooAbsArg::_ioEvoList[newObj] = new TRefArray(onfile._proxyList) ; } }" #pragma link C++ class RooAbsBinning- ; #pragma link C++ class RooAbsCategory+ ; #pragma link C++ class RooAbsCategoryLValue+ ; @@ -37,7 +40,7 @@ #pragma link C++ class RooArgProxy+ ; #pragma link C++ class RooArgSet+ ; #pragma link C++ class RooBinnedGenContext+ ; -#pragma link C++ class RooBinning- ; +#pragma link C++ class RooBinning-; #pragma link C++ class RooBrentRootFinder+ ; #pragma link C++ class RooCategory- ; #pragma link C++ class RooCategoryProxy+ ; @@ -65,7 +68,6 @@ #pragma link C++ class RooEffProd+ ; #pragma link C++ class RooExtendPdf+ ; #pragma link off class RooErrorHandler+ ; -#pragma link off class RooNag+ ; #endif diff --git a/roofit/roofitcore/inc/LinkDef2.h b/roofit/roofitcore/inc/LinkDef2.h index a027db9ca1b14..a13107ddf2f82 100644 --- a/roofit/roofitcore/inc/LinkDef2.h +++ b/roofit/roofitcore/inc/LinkDef2.h @@ -65,10 +65,11 @@ #pragma link C++ class RooPrintable+ ; #pragma link C++ class RooProdGenContext+ ; #pragma link C++ class RooProduct+ ; +#pragma read sourceClass="RooProduct" targetClass="RooProduct" version="[1]" source="RooSetProxy _compRSet" target="_compRSet" code="{ _compRSet.add(onfile._compRSet) ; }" +#pragma read sourceClass="RooProduct" targetClass="RooProduct" version="[1]" source="RooSetProxy _compCSet" target="_compCSet" code="{ _compCSet.add(onfile._compCSet) ; }" #pragma link C++ class RooPullVar+ ; #pragma link C++ class RooQuasiRandomGenerator+ ; #pragma link C++ class RooRandom+ ; #pragma link off class RooErrorHandler+ ; -#pragma link off class RooNag+ ; #endif diff --git a/roofit/roofitcore/inc/LinkDef3.h b/roofit/roofitcore/inc/LinkDef3.h index bd6df16d9e856..2912b83a2082b 100644 --- a/roofit/roofitcore/inc/LinkDef3.h +++ b/roofit/roofitcore/inc/LinkDef3.h @@ -2,9 +2,9 @@ #pragma link off all globals; #pragma link off all classes; #pragma link off all functions; -#pragma link C++ class RooCacheManager<vector<double> >+ ; -#pragma link C++ class list<RooAbsData*>+ ; -#pragma link C++ class map<string,RooAbsData*>+ ; +#pragma link C++ class RooCacheManager<std::vector<double> >+ ; +#pragma link C++ class std::list<RooAbsData*>+ ; +#pragma link C++ class std::map<string,RooAbsData*>+ ; #pragma link C++ class RooCacheManager<RooAbsCacheElement>+ ; #pragma link C++ class RooRandomizeParamMCSModule+ ; #pragma link C++ class RooRangeBinning+ ; @@ -48,8 +48,8 @@ #pragma link C++ class RooWorkspace- ; #pragma link C++ class RooWorkspace::CodeRepo- ; #pragma link C++ class RooWorkspace::WSDir+ ; -#pragma link C++ class list<TObject*>+ ; -#pragma link C++ class list<RooAbsData*>+ ; +#pragma link C++ class std::list<TObject*>+ ; +#pragma link C++ class std::list<RooAbsData*>+ ; #pragma link C++ class RooProfileLL+ ; #pragma link C++ class RooAbsCachedPdf+ ; #pragma link C++ class RooAbsSelfCachedPdf+ ; @@ -63,76 +63,6 @@ #pragma link C++ class RooExtendedTerm+ ; #pragma link C++ class RooSentinel+ ; #pragma link C++ class RooParamBinning+ ; -#pragma link C++ class RooConstraintSum+ ; -#pragma link C++ class RooRecursiveFraction+ ; -#pragma link C++ class RooDataWeightedAverage+ ; -#pragma link C++ class RooSimWSTool+ ; -#pragma link C++ class RooSimWSTool::SplitRule+ ; -#pragma link C++ class RooSimWSTool::BuildConfig+ ; -#pragma link C++ class RooSimWSTool::MultiBuildConfig+ ; -#pragma link C++ class RooSimWSTool::ObjSplitRule+ ; -#pragma link C++ class RooSimWSTool::ObjBuildConfig+ ; -#pragma link C++ class RooFracRemainder+ ; -#pragma link C++ class RooAbsCachedReal+ ; -#pragma link C++ class RooAbsSelfCachedReal+ ; -#pragma link C++ class RooCachedReal+ ; -#pragma link C++ class RooNumCdf+ ; -#pragma link C++ class RooChangeTracker+ ; -#pragma link C++ class RooNumRunningInt+ ; -#pragma link C++ class RooHistFunc- ; -#pragma link C++ class RooExpensiveObjectCache+ ; -#pragma link C++ class RooExpensiveObjectCache::ExpensiveObject+ ; -#pragma link C++ class std::map<std::string,RooAbsPdf*>+ ; -// The nomap options excludes the class from the roomap file -#pragma link C++ options=nomap class std::map<std::string,TH1*>+ ; -#pragma link C++ class std::map<std::string,RooAbsDataStore*>+ ; -#pragma link C++ class std::list<RooAbsData*>+ ; -#pragma link C++ class std::list<TObject*>+ ; -#pragma link C++ class RooFactoryWSTool+ ; -#pragma link C++ class RooBinningCategory+ ; -#pragma link C++ class RooDerivative+ ; -#pragma link C++ class RooFunctor+ ; -#pragma link C++ class RooGenFunction+ ; -#pragma link C++ class RooMultiGenFunction+ ; -#pragma link C++ class RooTFoamBinding+ ; -#pragma link C++ class RooAdaptiveIntegratorND+ ; -#pragma link C++ class RooAbsNumGenerator+ ; -#pragma link C++ class RooFoamGenerator+ ; -#pragma link C++ class RooNumGenConfig+ ; -#pragma link C++ class RooNumGenFactory+ ; -#pragma link C++ class RooMultiVarGaussian+ ; -#pragma link C++ class RooMultiVarGaussian::AnaIntData+ ; -#pragma link C++ class RooMultiVarGaussian::GenData+ ; -#pragma link C++ class RooXYChi2Var+ ; -#pragma link C++ class RooAbsDataStore+ ; -#pragma link C++ class RooTreeDataStore- ; -#pragma link C++ class RooCompositeDataStore+ ; -#pragma link C++ class RooTreeData+ ; -#pragma link C++ class RooRangeBoolean+ ; -#pragma link C++ class RooVectorDataStore- ; -#pragma link C++ class RooVectorDataStore::RealVector- ; -#pragma link C++ class RooVectorDataStore::RealFullVector- ; -#pragma link C++ class RooVectorDataStore::CatVector- ; -#pragma link C++ class std::pair<std::string,RooAbsData*>+ ; -#pragma link C++ class pair<int,RooLinkedListElem*>+ ; -#pragma link C++ class RooUnitTest+ ; -#ifndef __ROOFIT_NOROOMINIMIZER -#pragma link C++ class RooMinimizer+ ; -#pragma link C++ class RooMinimizerFcn+ ; -#endif -#pragma link C++ class RooMoment+ ; -#pragma link C++ class RooStudyManager+ ; -#pragma link C++ class RooStudyPackage+ ; -#pragma link C++ class RooAbsStudy+ ; -#pragma link C++ class RooGenFitStudy+ ; -#pragma link C++ class RooProofDriverSelector+ ; -#pragma link C++ class list<RooAbsStudy*>+ ; -#pragma link C++ class map<string,RooDataSet*>+ ; -#pragma link C++ class map<string,RooDataHist*>+ ; -// The nomap options excludes the class from the roomap file -#pragma link C++ options=nomap class map<string,TH1*>+ ; -#pragma link C++ namespace RooCintUtils+ ; #pragma link off class RooErrorHandler+ ; -#pragma link off class RooNag+ ; #endif diff --git a/roofit/roofitcore/inc/LinkDef4.h b/roofit/roofitcore/inc/LinkDef4.h new file mode 100644 index 0000000000000..cdcfa5a1f7e51 --- /dev/null +++ b/roofit/roofitcore/inc/LinkDef4.h @@ -0,0 +1,77 @@ +#ifdef __CINT__ +#pragma link off all globals; +#pragma link off all classes; +#pragma link off all functions; +#pragma link C++ class RooConstraintSum+ ; +#pragma link C++ class RooRecursiveFraction+ ; +#pragma link C++ class RooDataWeightedAverage+ ; +#pragma link C++ class RooSimWSTool+ ; +#pragma link C++ class RooSimWSTool::SplitRule+ ; +#pragma link C++ class RooSimWSTool::BuildConfig+ ; +#pragma link C++ class RooSimWSTool::MultiBuildConfig+ ; +#pragma link C++ class RooSimWSTool::ObjSplitRule+ ; +#pragma link C++ class RooSimWSTool::ObjBuildConfig+ ; +#pragma link C++ class RooFracRemainder+ ; +#pragma link C++ class RooAbsCachedReal+ ; +#pragma link C++ class RooAbsSelfCachedReal+ ; +#pragma link C++ class RooCachedReal+ ; +#pragma link C++ class RooNumCdf+ ; +#pragma link C++ class RooChangeTracker+ ; +#pragma link C++ class RooNumRunningInt+ ; +#pragma link C++ class RooHistFunc- ; +#pragma link C++ class RooExpensiveObjectCache+ ; +#pragma link C++ class RooExpensiveObjectCache::ExpensiveObject+ ; +#pragma link C++ class std::map<std::string,RooAbsPdf*>+ ; +// The nomap options excludes the class from the roomap file +#pragma link C++ options=nomap class std::map<std::string,TH1*>+ ; +#pragma link C++ class std::map<std::string,RooAbsDataStore*>+ ; +#pragma link C++ class std::list<RooAbsData*>+ ; +#pragma link C++ class std::list<TObject*>+ ; +#pragma link C++ class RooFactoryWSTool+ ; +#pragma link C++ class RooBinningCategory+ ; +#pragma link C++ class RooDerivative+ ; +#pragma link C++ class RooFunctor+ ; +#pragma link C++ class RooGenFunction+ ; +#pragma link C++ class RooMultiGenFunction+ ; +#pragma link C++ class RooTFoamBinding+ ; +#pragma link C++ class RooAdaptiveIntegratorND+ ; +#pragma link C++ class RooAbsNumGenerator+ ; +#pragma link C++ class RooFoamGenerator+ ; +#pragma link C++ class RooNumGenConfig+ ; +#pragma link C++ class RooNumGenFactory+ ; +#pragma link C++ class RooMultiVarGaussian+ ; +#pragma link C++ class RooMultiVarGaussian::AnaIntData+ ; +#pragma link C++ class RooMultiVarGaussian::GenData+ ; +#pragma link C++ class RooXYChi2Var+ ; +#pragma link C++ class RooAbsDataStore+ ; +#pragma link C++ class RooTreeDataStore- ; +#pragma link C++ class RooCompositeDataStore+ ; +#pragma link C++ class RooTreeData+ ; +#pragma link C++ class RooRangeBoolean+ ; +#pragma link C++ class RooVectorDataStore- ; +#pragma link C++ class RooVectorDataStore::RealVector- ; +#pragma link C++ class RooVectorDataStore::RealFullVector- ; +#pragma link C++ class RooVectorDataStore::CatVector- ; +#pragma link C++ class std::pair<std::string,RooAbsData*>+ ; +#pragma link C++ class std::pair<int,RooLinkedListElem*>+ ; +#pragma link C++ class RooUnitTest+ ; +#ifndef __ROOFIT_NOROOMINIMIZER +#pragma link C++ class RooMinimizer+ ; +#pragma link C++ class RooMinimizerFcn+ ; +#endif +#pragma link C++ class RooMoment+ ; +#pragma link C++ class RooStudyManager+ ; +#pragma link C++ class RooStudyPackage+ ; +#pragma link C++ class RooAbsStudy+ ; +#pragma link C++ class RooGenFitStudy+ ; +#pragma link C++ class RooProofDriverSelector+ ; +#pragma link C++ class RooExtendedBinding+ ; +#pragma link C++ class std::list<RooAbsStudy*>+ ; +#pragma link C++ class std::map<string,RooDataSet*>+ ; +#pragma link C++ class std::map<string,RooDataHist*>+ ; +// The nomap options excludes the class from the roomap file +#pragma link C++ options=nomap class std::map<string,TH1*>+ ; +#pragma link C++ namespace RooCintUtils+ ; +#pragma link off class RooErrorHandler+ ; +#endif + diff --git a/roofit/roofitcore/inc/Roo1DTable.h b/roofit/roofitcore/inc/Roo1DTable.h index 55eb3c2eb7bdc..6349f61a5b958 100644 --- a/roofit/roofitcore/inc/Roo1DTable.h +++ b/roofit/roofitcore/inc/Roo1DTable.h @@ -37,14 +37,16 @@ class Roo1DTable : public RooTable { virtual void fill(RooAbsCategory& cat, Double_t weight=1.0) ; Double_t get(const char* label, Bool_t silent=kFALSE) const ; Double_t getFrac(const char* label, Bool_t silent=kFALSE) const ; + Double_t get(const int index, Bool_t silent=kFALSE) const ; + Double_t getFrac(const int index, Bool_t silent=kFALSE) const ; Double_t getOverflow() const ; // Printing interface (human readable) - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printValue(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printValue(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; virtual Int_t defaultPrintContents(Option_t* opt) const ; inline virtual void Print(Option_t *options= 0) const { diff --git a/roofit/roofitcore/inc/RooAbsAnaConvPdf.h b/roofit/roofitcore/inc/RooAbsAnaConvPdf.h index 3d7765f23c174..5722ee6a874ee 100644 --- a/roofit/roofitcore/inc/RooAbsAnaConvPdf.h +++ b/roofit/roofitcore/inc/RooAbsAnaConvPdf.h @@ -44,7 +44,7 @@ class RooAbsAnaConvPdf : public RooAbsPdf { virtual ~RooAbsAnaConvPdf(); Int_t declareBasis(const char* expression, const RooArgList& params) ; - virtual void printMultiline(ostream& stream, Int_t contents, Bool_t verbose=kFALSE, TString indent= "") const ; + virtual void printMultiline(std::ostream& stream, Int_t contents, Bool_t verbose=kFALSE, TString indent= "") const ; // Coefficient normalization access inline Double_t getCoefNorm(Int_t coefIdx, const RooArgSet& nset, const char* rangeName) const { diff --git a/roofit/roofitcore/inc/RooAbsArg.h b/roofit/roofitcore/inc/RooAbsArg.h index 56ca0979be68d..3223f133769ad 100644 --- a/roofit/roofitcore/inc/RooAbsArg.h +++ b/roofit/roofitcore/inc/RooAbsArg.h @@ -28,6 +28,7 @@ #include <map> #include <set> #include <deque> +#include <stack> #include <iostream> @@ -50,6 +51,18 @@ class RooWorkspace ; class RooRealProxy ; /* class TGraphStruct ; */ +class RooRefArray : public TObjArray { + public: + RooRefArray() : TObjArray() { + } ; + RooRefArray(const RooRefArray& other) : TObjArray(other) { + } + virtual ~RooRefArray() {} ; + protected: + ClassDef(RooRefArray,1) // Helper class for proxy lists +} ; + + class RooAbsArg : public TNamed, public RooPrintable { public: @@ -58,9 +71,9 @@ class RooAbsArg : public TNamed, public RooPrintable { virtual ~RooAbsArg(); RooAbsArg(const char *name, const char *title); RooAbsArg(const RooAbsArg& other, const char* name=0) ; - virtual TObject* clone(const char* newname) const = 0 ; + virtual TObject* clone(const char* newname=0) const = 0 ; virtual TObject* Clone(const char* newname=0) const { - return clone(newname?newname:GetName()) ; + return clone(newname) ; } virtual RooAbsArg* cloneTree(const char* newname=0) const ; @@ -68,7 +81,7 @@ class RooAbsArg : public TNamed, public RooPrintable { virtual Bool_t isDerived() const { // Does value or shape of this arg depend on any other arg? return kTRUE ; - //cout << IsA()->GetName() << "::isDerived(" << GetName() << ") = " << (_serverList.GetSize()>0 || _proxyList.GetSize()>0) << endl ; + //std::cout << IsA()->GetName() << "::isDerived(" << GetName() << ") = " << (_serverList.GetSize()>0 || _proxyList.GetSize()>0) << std::endl ; //return (_serverList.GetSize()>0 || _proxyList.GetSize()>0)?kTRUE:kFALSE; } Bool_t isCloneOf(const RooAbsArg& other) const ; @@ -208,22 +221,22 @@ class RooAbsArg : public TNamed, public RooPrintable { void attachDataStore(const RooAbsDataStore &set); // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) = 0 ; - virtual void writeToStream(ostream& os, Bool_t compact) const = 0 ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) = 0 ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const = 0 ; inline virtual void Print(Option_t *options= 0) const { // Printing interface (human readable) printStream(defaultPrintStream(),defaultPrintContents(options),defaultPrintStyle(options)); } - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printAddress(ostream& os) const ; - virtual void printArgs(ostream& os) const ; - virtual void printMetaArgs(ostream& /*os*/) const {} ; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const; - virtual void printTree(ostream& os, TString indent="") const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printAddress(std::ostream& os) const ; + virtual void printArgs(std::ostream& os) const ; + virtual void printMetaArgs(std::ostream& /*os*/) const {} ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const; + virtual void printTree(std::ostream& os, TString indent="") const ; virtual Int_t defaultPrintContents(Option_t* opt) const ; @@ -238,7 +251,7 @@ class RooAbsArg : public TNamed, public RooPrintable { void setStringAttribute(const Text_t* key, const Text_t* value) ; const Text_t* getStringAttribute(const Text_t* key) const ; inline const std::map<std::string,std::string>& stringAttributes() const { - // Returns map<string,string> with all string attributes defined + // Returns std::map<string,string> with all string attributes defined return _stringAttrib ; } @@ -252,7 +265,7 @@ class RooAbsArg : public TNamed, public RooPrintable { inline Bool_t isConstant() const { // Returns true if 'Constant' attribute is set - return getAttribute("Constant") ; + return _isConstant ; //getAttribute("Constant") ; } RooLinkedList getCloningAncestors() const ; @@ -270,6 +283,7 @@ class RooAbsArg : public TNamed, public RooPrintable { static void setDirtyInhibit(Bool_t flag) ; virtual Bool_t operator==(const RooAbsArg& other) = 0 ; + virtual Bool_t isIdentical(const RooAbsArg& other, Bool_t assumeSameType=kFALSE) = 0 ; // Range management virtual Bool_t inRange(const char*) const { @@ -301,14 +315,14 @@ class RooAbsArg : public TNamed, public RooPrintable { virtual void constOptimizeTestStatistic(ConstOpCode opcode, Bool_t doAlsoTrackingOpt=kTRUE) ; void graphVizTree(const char* fileName, const char* delimiter="\n", bool useTitle=false, bool useLatex=false) ; - void graphVizTree(ostream& os, const char* delimiter="\n", bool useTitle=false, bool useLatex=false) ; + void graphVizTree(std::ostream& os, const char* delimiter="\n", bool useTitle=false, bool useLatex=false) ; /* TGraphStruct* graph(Bool_t useFactoryTag=kFALSE, Double_t textSize=0.03) ; */ void printComponentTree(const char* indent="",const char* namePat=0, Int_t nLevel=999) ; void printCompactTree(const char* indent="",const char* fileName=0, const char* namePat=0, RooAbsArg* client=0) ; - void printCompactTree(ostream& os, const char* indent="", const char* namePat=0, RooAbsArg* client=0) ; - virtual void printCompactTreeHook(ostream& os, const char *ind="") ; + void printCompactTree(std::ostream& os, const char* indent="", const char* namePat=0, RooAbsArg* client=0) ; + virtual void printCompactTreeHook(std::ostream& os, const char *ind="") ; // Dirty state accessor inline Bool_t isShapeDirty() const { @@ -382,7 +396,16 @@ class RooAbsArg : public TNamed, public RooPrintable { inline OperMode operMode() const { return _operMode ; } void setOperMode(OperMode mode, Bool_t recurseADirty=kTRUE) ; - static UInt_t crc32(const char* data) ; + static UInt_t crc32(const char* data); + static UInt_t crc32(const char* data, ULong_t sz, UInt_t crc = 0); + + static const UInt_t fnv1a32start = 2166136261u; + static UInt_t fnv1a32(const char* data); + static UInt_t fnv1a32(const char* data, ULong_t sz, UInt_t hash = fnv1a32start); + + static const ULong64_t fnv1a64start = (ULong64_t(3421674724u) << 32) | ULong64_t(2216829733u); + static ULong64_t fnv1a64(const char* data); + static ULong64_t fnv1a64(const char* data, ULong_t sz, ULong64_t hash = fnv1a64start); Bool_t addOwnedComponents(const RooArgSet& comps) ; const RooArgSet* ownedComponents() const { return _ownedComponents ; } @@ -448,7 +471,7 @@ class RooAbsArg : public TNamed, public RooPrintable { RooRefCountList _clientList ; // list of client objects RooRefCountList _clientListShape ; // subset of clients that requested shape dirty flag propagation RooRefCountList _clientListValue ; // subset of clients that requested value dirty flag propagation - TRefArray _proxyList ; // list of proxies + RooRefArray _proxyList ; // list of proxies std::deque<RooAbsCache*> _cacheList ; // list of caches TIterator* _clientShapeIter ; //! Iterator over _clientListShape TIterator* _clientValueIter ; //! Iterator over _clientListValue @@ -468,7 +491,7 @@ class RooAbsArg : public TNamed, public RooPrintable { RooAbsArg *findNewServer(const RooAbsCollection &newSet, Bool_t nameChange) const; RooExpensiveObjectCache& expensiveObjectCache() const ; - void setExpensiveObjectCache(RooExpensiveObjectCache& cache) { _eocache = &cache ; } + virtual void setExpensiveObjectCache(RooExpensiveObjectCache& cache) { _eocache = &cache ; } virtual Bool_t importWorkspaceHook(RooWorkspace&) { return kFALSE ; } ; @@ -497,7 +520,7 @@ class RooAbsArg : public TNamed, public RooPrintable { std::map<std::string,std::string> _stringAttrib ; // String attributes std::set<std::string> _boolAttribTransient ; //! Transient boolean attributes (not copied in ctor) - void printAttribList(ostream& os) const; + void printAttribList(std::ostream& os) const; // Hooks for RooTreeData interface friend class RooCompositeDataStore ; @@ -518,8 +541,8 @@ class RooAbsArg : public TNamed, public RooPrintable { TString cleanBranchName() const ; // Global - friend ostream& operator<<(ostream& os, const RooAbsArg &arg); - friend istream& operator>>(istream& is, RooAbsArg &arg) ; + friend std::ostream& operator<<(std::ostream& os, const RooAbsArg &arg); + friend std::istream& operator>>(std::istream& is, RooAbsArg &arg) ; // Debug stuff static Bool_t _verboseDirty ; // Static flag controlling verbose messaging for dirty state changes @@ -546,11 +569,21 @@ class RooAbsArg : public TNamed, public RooPrintable { mutable RooExpensiveObjectCache* _eocache ; // Pointer to global cache manager for any expensive components created by this object mutable TNamed* _namePtr ; //! Do not persist. Pointer to global instance of string that matches object named + Bool_t _isConstant ; //! Cached isConstant status + +/* RooArgSet _leafNodeCache ; //! Cached leaf nodes */ +/* RooArgSet _branchNodeCache //! Cached branch nodes */ + + public: + virtual void ioStreamerPass2() ; + static void ioStreamerPass2Finalize() ; + static std::map<RooAbsArg*,TRefArray*> _ioEvoList ; // temporary holding list for proxies needed in schema evolution + static std::stack<RooAbsArg*> _ioReadStack ; // reading stack - ClassDef(RooAbsArg,5) // Abstract variable + ClassDef(RooAbsArg,6) // Abstract variable }; -ostream& operator<<(ostream& os, const RooAbsArg &arg); -istream& operator>>(istream& is, RooAbsArg &arg) ; +std::ostream& operator<<(std::ostream& os, const RooAbsArg &arg); +std::istream& operator>>(std::istream& is, RooAbsArg &arg) ; #endif diff --git a/roofit/roofitcore/inc/RooAbsBinning.h b/roofit/roofitcore/inc/RooAbsBinning.h index 4f09d6d4722f7..7e358f2b0c971 100644 --- a/roofit/roofitcore/inc/RooAbsBinning.h +++ b/roofit/roofitcore/inc/RooAbsBinning.h @@ -69,11 +69,11 @@ class RooAbsBinning : public TNamed, public RooPrintable { printStream(defaultPrintStream(),defaultPrintContents(options),defaultPrintStyle(options)); } - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printArgs(ostream& os) const ; - virtual void printValue(ostream& os) const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printArgs(std::ostream& os) const ; + virtual void printValue(std::ostream& os) const ; virtual Bool_t isParameterized() const { diff --git a/roofit/roofitcore/inc/RooAbsCache.h b/roofit/roofitcore/inc/RooAbsCache.h index 76eb9b4273aa5..797af722b06f0 100644 --- a/roofit/roofitcore/inc/RooAbsCache.h +++ b/roofit/roofitcore/inc/RooAbsCache.h @@ -35,7 +35,7 @@ class RooAbsCache { virtual void operModeHook() ; virtual void optimizeCacheMode(const RooArgSet&, RooArgSet&, RooLinkedList& ) ; virtual void findConstantNodes(const RooArgSet&, RooArgSet& , RooLinkedList&) ; - virtual void printCompactTreeHook(ostream&, const char *) ; + virtual void printCompactTreeHook(std::ostream&, const char *) ; virtual void wireCache() {} ; virtual ~RooAbsCache() ; diff --git a/roofit/roofitcore/inc/RooAbsCachedReal.h b/roofit/roofitcore/inc/RooAbsCachedReal.h index b08722f364a32..5d7f90b68def4 100644 --- a/roofit/roofitcore/inc/RooAbsCachedReal.h +++ b/roofit/roofitcore/inc/RooAbsCachedReal.h @@ -59,7 +59,7 @@ class RooAbsCachedReal : public RooAbsReal { class FuncCacheElem : public RooAbsCacheElement { public: FuncCacheElem(const RooAbsCachedReal& self, const RooArgSet* nset) ; - virtual ~FuncCacheElem() {} ; + virtual ~FuncCacheElem() ; // Cache management functions virtual RooArgList containedArgs(Action) ; @@ -69,11 +69,19 @@ class RooAbsCachedReal : public RooAbsReal { RooDataHist* hist() { return _hist ; } RooChangeTracker* paramTracker() { return _paramTracker ; } + RooAbsReal* sourceClone() { return _sourceClone ; } + void setSourceClone(RooAbsReal* newSource) { delete _sourceClone ; _sourceClone = newSource ; } + + Bool_t cacheSource() { return _cacheSource ; } + void setCacheSource(Bool_t flag) { _cacheSource = flag ; } + private: // Payload - RooHistFunc* _func ; + RooHistFunc* _func ; RooChangeTracker* _paramTracker ; - RooDataHist* _hist ; + RooDataHist* _hist ; + RooAbsReal* _sourceClone ; + Bool_t _cacheSource ; } ; FuncCacheElem* getCache(const RooArgSet* nset) const ; diff --git a/roofit/roofitcore/inc/RooAbsCategory.h b/roofit/roofitcore/inc/RooAbsCategory.h index 8e5eb205c8365..ff8d2a7f91676 100644 --- a/roofit/roofitcore/inc/RooAbsCategory.h +++ b/roofit/roofitcore/inc/RooAbsCategory.h @@ -48,6 +48,7 @@ class RooAbsCategory : public RooAbsArg { Bool_t operator!=(const char* label) { return !operator==(label);} virtual Bool_t operator==(const RooAbsArg& other) ; Bool_t operator!=(const RooAbsArg& other) { return !operator==(other);} + virtual Bool_t isIdentical(const RooAbsArg& other, Bool_t assumeSameType=kFALSE) ; Bool_t isValidIndex(Int_t index) const ; Bool_t isValidLabel(const char* label) const ; @@ -64,11 +65,11 @@ class RooAbsCategory : public RooAbsArg { Roo1DTable *createTable(const char *label) const ; // I/O streaming interface - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; - virtual void printValue(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printValue(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; virtual Bool_t isIntegrationSafeLValue(const RooArgSet* /*set*/) const { // Is this l-value object safe for use as integration observable diff --git a/roofit/roofitcore/inc/RooAbsCategoryLValue.h b/roofit/roofitcore/inc/RooAbsCategoryLValue.h index 0a563fb39b558..2fcdc8326421e 100644 --- a/roofit/roofitcore/inc/RooAbsCategoryLValue.h +++ b/roofit/roofitcore/inc/RooAbsCategoryLValue.h @@ -52,6 +52,7 @@ class RooAbsCategoryLValue : public RooAbsCategory, public RooAbsLValue { virtual void randomize(const char* rangeName=0); virtual const RooAbsBinning* getBinningPtr(const char* /*rangeName*/) const { return 0 ; } + virtual std::list<std::string> getBinningNames() const { return std::list<std::string>(1, "") ; } virtual Int_t getBin(const RooAbsBinning* /*ptr*/) const { return getBin((const char*)0) ; } @@ -66,8 +67,8 @@ class RooAbsCategoryLValue : public RooAbsCategory, public RooAbsLValue { } // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; protected: diff --git a/roofit/roofitcore/inc/RooAbsCollection.h b/roofit/roofitcore/inc/RooAbsCollection.h index 9ad9443f80c06..751449ebb0c80 100644 --- a/roofit/roofitcore/inc/RooAbsCollection.h +++ b/roofit/roofitcore/inc/RooAbsCollection.h @@ -119,11 +119,11 @@ class RooAbsCollection : public TObject, public RooPrintable { std::string contentsString() const ; - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printValue(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printValue(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; virtual Int_t defaultPrintContents(Option_t* opt) const ; @@ -132,7 +132,7 @@ class RooAbsCollection : public TObject, public RooPrintable { const RooCmdArg& arg3=RooCmdArg(), const RooCmdArg& arg4=RooCmdArg(), const RooCmdArg& arg5=RooCmdArg(), const RooCmdArg& arg6=RooCmdArg(), const RooCmdArg& arg7=RooCmdArg(), const RooCmdArg& arg8=RooCmdArg()) const ; - void printLatex(ostream& ofs, Int_t ncol, const char* option="NEYU", Int_t sigDigit=1, + void printLatex(std::ostream& ofs, Int_t ncol, const char* option="NEYU", Int_t sigDigit=1, const RooLinkedList& siblingLists=RooLinkedList(), const RooCmdArg* formatCmd=0) const ; void setName(const char *name) { diff --git a/roofit/roofitcore/inc/RooAbsData.h b/roofit/roofitcore/inc/RooAbsData.h index 46047e963034f..6616c04fe1b52 100644 --- a/roofit/roofitcore/inc/RooAbsData.h +++ b/roofit/roofitcore/inc/RooAbsData.h @@ -79,8 +79,9 @@ class RooAbsData : public TNamed, public RooPrintable { return &_vars ; } virtual Double_t weight() const = 0 ; // DERIVED + virtual Double_t weightSquared() const = 0 ; // DERIVED virtual Bool_t valid() const { return kTRUE ; } - enum ErrorType { Poisson, SumW2, None, Auto } ; + enum ErrorType { Poisson, SumW2, None, Auto, Expected } ; virtual Double_t weightError(ErrorType etype=Poisson) const ; virtual void weightError(Double_t& lo, Double_t& hi, ErrorType etype=Poisson) const ; virtual const RooArgSet* get(Int_t index) const ; @@ -158,10 +159,10 @@ class RooAbsData : public TNamed, public RooPrintable { printStream(defaultPrintStream(),defaultPrintContents(options),defaultPrintStyle(options)); } - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; virtual Int_t defaultPrintContents(Option_t* opt) const ; @@ -209,13 +210,15 @@ class RooAbsData : public TNamed, public RooPrintable { static Bool_t releaseVars(RooAbsData*) ; enum StorageType { Tree, Vector} ; - static StorageType defaultStorageType ; static void setDefaultStorageType(StorageType s) ; + static StorageType getDefaultStorageType(); protected: + static StorageType defaultStorageType ; + Double_t corrcov(RooRealVar &x,RooRealVar &y, const char* cutSpec, const char* cutRange, Bool_t corr) const ; TMatrixDSym* corrcovMatrix(const RooArgList& vars, const char* cutSpec, const char* cutRange, Bool_t corr) const ; @@ -235,7 +238,7 @@ class RooAbsData : public TNamed, public RooPrintable { friend class RooAbsOptTestStatistic ; friend class RooAbsCachedPdf ; - virtual void cacheArgs(const RooAbsArg* owner, RooArgSet& varSet, const RooArgSet* nset=0) ; + virtual void cacheArgs(const RooAbsArg* owner, RooArgSet& varSet, const RooArgSet* nset=0, Bool_t skipZeroWeights=kFALSE) ; virtual void resetCache() ; virtual void setArgStatus(const RooArgSet& set, Bool_t active) ; virtual void attachCache(const RooAbsArg* newOwner, const RooArgSet& cachedVars) ; diff --git a/roofit/roofitcore/inc/RooAbsDataStore.h b/roofit/roofitcore/inc/RooAbsDataStore.h index 5cd68cd5f1f19..0f4cae06abe86 100644 --- a/roofit/roofitcore/inc/RooAbsDataStore.h +++ b/roofit/roofitcore/inc/RooAbsDataStore.h @@ -85,24 +85,24 @@ class RooAbsDataStore : public TNamed, public RooPrintable { printStream(defaultPrintStream(),defaultPrintContents(options),defaultPrintStyle(options)); } - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printArgs(ostream& os) const ; - virtual void printValue(ostream& os) const ; - void printMultiline(ostream& os, Int_t content, Bool_t verbose, TString indent) const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printArgs(std::ostream& os) const ; + virtual void printValue(std::ostream& os) const ; + void printMultiline(std::ostream& os, Int_t content, Bool_t verbose, TString indent) const ; virtual Int_t defaultPrintContents(Option_t* opt) const ; // Constant term optimizer interface - virtual void cacheArgs(const RooAbsArg* cacheOwner, RooArgSet& varSet, const RooArgSet* nset=0) = 0 ; + virtual void cacheArgs(const RooAbsArg* cacheOwner, RooArgSet& varSet, const RooArgSet* nset=0, Bool_t skipZeroWeights=kFALSE) = 0 ; virtual const RooAbsArg* cacheOwner() = 0 ; virtual void attachCache(const RooAbsArg* newOwner, const RooArgSet& cachedVars) = 0 ; virtual void setArgStatus(const RooArgSet& set, Bool_t active) = 0 ; const RooArgSet& cachedVars() const { return _cachedVars ; } virtual void resetCache() = 0 ; - virtual void recalculateCache(const RooArgSet* /*proj*/, Int_t /*firstEvent*/, Int_t /*lastEvent*/, Int_t /*stepSize*/) {} ; + virtual void recalculateCache(const RooArgSet* /*proj*/, Int_t /*firstEvent*/, Int_t /*lastEvent*/, Int_t /*stepSize*/, Bool_t /* skipZeroWeights*/) {} ; virtual void setDirtyProp(Bool_t flag) { _doDirtyProp = flag ; } Bool_t dirtyProp() const { return _doDirtyProp ; } @@ -115,7 +115,7 @@ class RooAbsDataStore : public TNamed, public RooPrintable { virtual void dump() {} virtual void loadValues(const RooAbsDataStore *tds, const RooFormulaVar* select=0, const char* rangeName=0, Int_t nStart=0, Int_t nStop=2000000000) = 0 ; - + protected: RooArgSet _vars ; diff --git a/roofit/roofitcore/inc/RooAbsGenContext.h b/roofit/roofitcore/inc/RooAbsGenContext.h index c5f8e22a470b2..23c6fe21439ff 100644 --- a/roofit/roofitcore/inc/RooAbsGenContext.h +++ b/roofit/roofitcore/inc/RooAbsGenContext.h @@ -29,7 +29,7 @@ class RooAbsGenContext : public TNamed, public RooPrintable { Bool_t _verbose= kFALSE) ; virtual ~RooAbsGenContext(); - virtual RooDataSet *generate(Int_t nEvents= 0, Bool_t skipInit=kFALSE, Bool_t extendedMode=kFALSE); + virtual RooDataSet *generate(Double_t nEvents= 0, Bool_t skipInit=kFALSE, Bool_t extendedMode=kFALSE); Bool_t isValid() const { // If true generator context is in a valid state @@ -54,11 +54,11 @@ class RooAbsGenContext : public TNamed, public RooPrintable { virtual void attach(const RooArgSet& params) ; - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printArgs(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printArgs(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const; virtual Int_t defaultPrintContents(Option_t* opt) const ; virtual StyleOption defaultPrintStyle(Option_t* opt) const ; diff --git a/roofit/roofitcore/inc/RooAbsHiddenReal.h b/roofit/roofitcore/inc/RooAbsHiddenReal.h index 63e85b7a52bce..209d070151ad8 100644 --- a/roofit/roofitcore/inc/RooAbsHiddenReal.h +++ b/roofit/roofitcore/inc/RooAbsHiddenReal.h @@ -34,11 +34,11 @@ class RooAbsHiddenReal : public RooAbsReal { virtual ~RooAbsHiddenReal(); // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; // Printing interface (human readable) - virtual void printValue(ostream& stream) const ; + virtual void printValue(std::ostream& stream) const ; inline Bool_t isHidden() const { // If true, hiding mode is active diff --git a/roofit/roofitcore/inc/RooAbsLValue.h b/roofit/roofitcore/inc/RooAbsLValue.h index 9f3c8b06bfe3b..c2be3eb5750bf 100644 --- a/roofit/roofitcore/inc/RooAbsLValue.h +++ b/roofit/roofitcore/inc/RooAbsLValue.h @@ -16,6 +16,9 @@ #ifndef ROO_ABS_LVALUE #define ROO_ABS_LVALUE +#include <list> +#include <string> + #include "Riosfwd.h" #include "Rtypes.h" @@ -36,6 +39,7 @@ class RooAbsLValue { virtual void randomize(const char* rangeName=0) = 0 ; virtual const RooAbsBinning* getBinningPtr(const char* rangeName) const = 0 ; + virtual std::list<std::string> getBinningNames() const = 0; virtual Int_t getBin(const RooAbsBinning*) const = 0 ; protected: diff --git a/roofit/roofitcore/inc/RooAbsNumGenerator.h b/roofit/roofitcore/inc/RooAbsNumGenerator.h index 7a69fd9e3a09c..363608a26fb37 100644 --- a/roofit/roofitcore/inc/RooAbsNumGenerator.h +++ b/roofit/roofitcore/inc/RooAbsNumGenerator.h @@ -57,10 +57,10 @@ class RooAbsNumGenerator : public TNamed, public RooPrintable { printStream(defaultPrintStream(),defaultPrintContents(options),defaultPrintStyle(options)); } - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printArgs(ostream& os) const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printArgs(std::ostream& os) const ; void attachParameters(const RooArgSet& vars) ; diff --git a/roofit/roofitcore/inc/RooAbsOptTestStatistic.h b/roofit/roofitcore/inc/RooAbsOptTestStatistic.h index 7c45acf71b53c..9d0f297d03c8d 100644 --- a/roofit/roofitcore/inc/RooAbsOptTestStatistic.h +++ b/roofit/roofitcore/inc/RooAbsOptTestStatistic.h @@ -33,7 +33,7 @@ class RooAbsOptTestStatistic : public RooAbsTestStatistic { RooAbsOptTestStatistic() ; RooAbsOptTestStatistic(const char *name, const char *title, RooAbsReal& real, RooAbsData& data, const RooArgSet& projDeps, const char* rangeName=0, const char* addCoefRangeName=0, - Int_t nCPU=1, Bool_t interleave=kFALSE, Bool_t verbose=kTRUE, Bool_t splitCutRange=kFALSE, + Int_t nCPU=1, RooFit::MPSplit interleave=RooFit::BulkPartition, Bool_t verbose=kTRUE, Bool_t splitCutRange=kFALSE, Bool_t cloneInputData=kTRUE) ; RooAbsOptTestStatistic(const RooAbsOptTestStatistic& other, const char* name=0); virtual ~RooAbsOptTestStatistic(); @@ -68,7 +68,7 @@ class RooAbsOptTestStatistic : public RooAbsTestStatistic { void constOptimizeTestStatistic(ConstOpCode opcode, Bool_t doAlsoTrackingOpt=kTRUE) ; virtual Bool_t redirectServersHook(const RooAbsCollection& newServerList, Bool_t mustReplaceAll, Bool_t nameChange, Bool_t isRecursive) ; - virtual void printCompactTreeHook(ostream& os, const char* indent="") ; + virtual void printCompactTreeHook(std::ostream& os, const char* indent="") ; virtual RooArgSet requiredExtraObservables() const { return RooArgSet() ; } void optimizeCaching() ; void optimizeConstantTerms(Bool_t,Bool_t=kTRUE) ; diff --git a/roofit/roofitcore/inc/RooAbsPdf.h b/roofit/roofitcore/inc/RooAbsPdf.h index 8da267e13e896..c9d43561a995d 100644 --- a/roofit/roofitcore/inc/RooAbsPdf.h +++ b/roofit/roofitcore/inc/RooAbsPdf.h @@ -56,8 +56,8 @@ class RooAbsPdf : public RooAbsReal { const RooCmdArg& arg1=RooCmdArg::none(),const RooCmdArg& arg2=RooCmdArg::none(), const RooCmdArg& arg3=RooCmdArg::none(),const RooCmdArg& arg4=RooCmdArg::none(), const RooCmdArg& arg5=RooCmdArg::none(),const RooCmdArg& arg6=RooCmdArg::none()) ; - RooDataSet *generate(const RooArgSet &whatVars, Int_t nEvents = 0, Bool_t verbose=kFALSE, Bool_t autoBinned=kTRUE, - const char* binnedTag="", Bool_t expectedData=kFALSE) const; + RooDataSet *generate(const RooArgSet &whatVars, Double_t nEvents = 0, Bool_t verbose=kFALSE, Bool_t autoBinned=kTRUE, + const char* binnedTag="", Bool_t expectedData=kFALSE, Bool_t extended = kFALSE) const; RooDataSet *generate(const RooArgSet &whatVars, const RooDataSet &prototype, Int_t nEvents= 0, Bool_t verbose=kFALSE, Bool_t randProtoOrder=kFALSE, Bool_t resampleProto=kFALSE) const; @@ -111,6 +111,7 @@ class RooAbsPdf : public RooAbsReal { ) const { return RooAbsReal::plotOn(frame,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10) ; } + virtual RooPlot* plotOn(RooPlot* frame, RooLinkedList& cmdList) const ; virtual RooPlot* paramOn(RooPlot* frame, @@ -186,11 +187,6 @@ class RooAbsPdf : public RooAbsReal { virtual Double_t getValV(const RooArgSet* set=0) const ; virtual Double_t getLogVal(const RooArgSet* set=0) const ; - void setNormValueCaching(Int_t minNumIntDim, Int_t ipOrder=2) ; - Int_t minDimNormValueCaching() const { return _minDimNormValueCache ; } - Int_t intOrderNormValueCaching() const { return _valueCacheIntOrder ; } - - Double_t getNorm(const RooArgSet& nset) const { // Get p.d.f normalization term needed for observables 'nset' return getNorm(&nset) ; @@ -232,8 +228,8 @@ class RooAbsPdf : public RooAbsReal { } // Printing interface (human readable) - virtual void printValue(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printValue(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; static void verboseEval(Int_t stat) ; static int verboseEval() ; @@ -249,6 +245,7 @@ class RooAbsPdf : public RooAbsReal { } void setNormRangeOverride(const char* rangeName) ; + const RooAbsReal* getNormIntegral(const RooArgSet& nset) const { return getNormObj(0,&nset,0) ; } protected: @@ -257,7 +254,7 @@ class RooAbsPdf : public RooAbsReal { protected: RooDataSet *generate(RooAbsGenContext& context, const RooArgSet& whatVars, const RooDataSet* prototype, - Int_t nEvents, Bool_t verbose, Bool_t randProtoOrder, Bool_t resampleProto, Bool_t skipInit=kFALSE, + Double_t nEvents, Bool_t verbose, Bool_t randProtoOrder, Bool_t resampleProto, Bool_t skipInit=kFALSE, Bool_t extended=kFALSE) const ; // Implementation version @@ -266,9 +263,6 @@ class RooAbsPdf : public RooAbsReal { Double_t xmax= 0.99,Double_t ymax=0.95, const RooCmdArg* formatCmd=0) ; - virtual RooPlot* plotOn(RooPlot* frame, RooLinkedList& cmdList) const ; - void plotOnCompSelect(RooArgSet* selNodes) const ; - virtual RooPlot *plotOn(RooPlot *frame, PlotOpt o) const; friend class RooEffGenContext ; @@ -306,8 +300,6 @@ class RooAbsPdf : public RooAbsReal { mutable Double_t _rawValue ; mutable RooAbsReal* _norm ; //! Normalization integral (owned by _normMgr) mutable RooArgSet* _normSet ; //! Normalization set with for above integral - Int_t _minDimNormValueCache ; // Minimum number of numerically integrated dimensions to activate normalization value caching - Int_t _valueCacheIntOrder ; // Interpolation order for numeric integral value cache class CacheElem : public RooAbsCacheElement { public: @@ -347,7 +339,7 @@ class RooAbsPdf : public RooAbsReal { TString _normRange ; // Normalization range static TString _normRangeOverride ; - ClassDef(RooAbsPdf,3) // Abstract PDF with normalization support + ClassDef(RooAbsPdf,4) // Abstract PDF with normalization support }; diff --git a/roofit/roofitcore/inc/RooAbsProxy.h b/roofit/roofitcore/inc/RooAbsProxy.h index ded2c72799d91..f6118e324f21c 100644 --- a/roofit/roofitcore/inc/RooAbsProxy.h +++ b/roofit/roofitcore/inc/RooAbsProxy.h @@ -48,7 +48,7 @@ class RooAbsProxy { // Return normalization set to be used for evaluation of contents return _nset ; } - virtual void print(ostream& os, Bool_t addContents=kFALSE) const ; + virtual void print(std::ostream& os, Bool_t addContents=kFALSE) const ; protected: diff --git a/roofit/roofitcore/inc/RooAbsReal.h b/roofit/roofitcore/inc/RooAbsReal.h index 55f3900844e0c..c85bc45bc6878 100644 --- a/roofit/roofitcore/inc/RooAbsReal.h +++ b/roofit/roofitcore/inc/RooAbsReal.h @@ -62,7 +62,7 @@ class RooAbsReal : public RooAbsArg { // Return value and unit accessors inline Double_t getVal(const RooArgSet* set=0) const { -/* if (_fast && !_inhibitDirty) cout << "RooAbsReal::getVal(" << GetName() << ") CLEAN value = " << _value << endl ; */ +/* if (_fast && !_inhibitDirty && std::string("RooHistFunc")==IsA()->GetName()) std::cout << "RooAbsReal::getVal(" << GetName() << ") CLEAN value = " << _value << std::endl ; */ #ifndef _WIN32 return (_fast && !_inhibitDirty) ? _value : getValV(set) ; #else @@ -77,6 +77,9 @@ class RooAbsReal : public RooAbsArg { Bool_t operator==(Double_t value) const ; virtual Bool_t operator==(const RooAbsArg& other) ; + virtual Bool_t isIdentical(const RooAbsArg& other, Bool_t assumeSameType=kFALSE) ; + + inline const Text_t *getUnit() const { // Return string with unit description return _unit.Data(); @@ -108,6 +111,7 @@ class RooAbsReal : public RooAbsArg { // and all integrals are calculated numerically _forceNumInt = flag ; } + Bool_t getForceNumInt() const { return _forceNumInt ; } // Chi^2 fits to histograms virtual RooFitResult* chi2FitTo(RooDataHist& data, const RooCmdArg& arg1=RooCmdArg::none(), const RooCmdArg& arg2=RooCmdArg::none(), @@ -235,24 +239,24 @@ class RooAbsReal : public RooAbsArg { Bool_t correctForBinVolume=kFALSE, Bool_t showProgress=kFALSE) const ; // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; // Printing interface (human readable) - virtual void printValue(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printValue(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; static void setCacheCheck(Bool_t flag) ; // Evaluation error logging class EvalError { public: - EvalError() { _msg[0] = 0 ; _srvval[0] = 0 ; } - EvalError(const EvalError& other) { strlcpy(_msg,other._msg,1024) ; strlcpy(_srvval,other._srvval,1024) ; } ; - void setMessage(const char* tmp) ; - void setServerValues(const char* tmp) ; - char _msg[1024] ; - char _srvval[1024] ; + EvalError() { } + EvalError(const EvalError& other) : _msg(other._msg), _srvval(other._srvval) { } + void setMessage(const char* tmp) { std::string s(tmp); s.swap(_msg); } + void setServerValues(const char* tmp) { std::string s(tmp); s.swap(_srvval); } + std::string _msg; + std::string _srvval; } ; enum ErrorLoggingMode { PrintErrors, CollectErrors, CountErrors, Ignore } ; @@ -260,7 +264,7 @@ class RooAbsReal : public RooAbsArg { static void setEvalErrorLoggingMode(ErrorLoggingMode m) ; void logEvalError(const char* message, const char* serverValueString=0) const ; static void logEvalError(const RooAbsReal* originator, const char* origName, const char* message, const char* serverValueString=0) ; - static void printEvalErrors(ostream&os=std::cout, Int_t maxPerNode=10000000) ; + static void printEvalErrors(std::ostream&os=std::cout, Int_t maxPerNode=10000000) ; static Int_t numEvalErrors() ; static Int_t numEvalErrorItems() ; @@ -300,11 +304,14 @@ class RooAbsReal : public RooAbsArg { virtual Bool_t setData(RooAbsData& /*data*/, Bool_t /*cloneData*/=kTRUE) { return kTRUE ; } -protected: - - // PlotOn with command list - virtual RooPlot* plotOn(RooPlot* frame, RooLinkedList& cmdList) const ; + virtual void enableOffsetting(Bool_t) {} ; + virtual Bool_t isOffsetting() const { return kFALSE ; } + virtual Double_t offset() const { return 0 ; } + + static void setHideOffset(Bool_t flag); + static Bool_t hideOffset() ; +protected: // Hook for objects with normalization-dependent parameters interperetation virtual void selectNormalization(const RooArgSet* depSet=0, Bool_t force=kFALSE) ; virtual void selectNormalizationRange(const char* rangeName=0, Bool_t force=kFALSE) ; @@ -319,7 +326,7 @@ class RooAbsReal : public RooAbsArg { Bool_t isSelectedComp() const ; - + public: const RooAbsReal* createPlotProjection(const RooArgSet& depVars, const RooArgSet& projVars) const ; const RooAbsReal* createPlotProjection(const RooArgSet& depVars, const RooArgSet& projVars, RooArgSet*& cloneSet) const ; @@ -329,6 +336,7 @@ class RooAbsReal : public RooAbsArg { RooFitResult* chi2FitDriver(RooAbsReal& fcn, RooLinkedList& cmdList) ; + void plotOnCompSelect(RooArgSet* selNodes) const ; RooPlot* plotOnWithErrorBand(RooPlot* frame,const RooFitResult& fr, Double_t Z, const RooArgSet* params, const RooLinkedList& argList, Bool_t method1) const ; // Support interface for subclasses to advertise their analytic integration @@ -374,6 +382,7 @@ class RooAbsReal : public RooAbsArg { virtual void setTreeBranchStatus(TTree& t, Bool_t active) ; virtual void fillTreeBranch(TTree& t) ; + friend class RooRealBinding ; Double_t _plotMin ; // Minimum of plot range Double_t _plotMax ; // Maximum of plot range Int_t _plotBins ; // Number of plot bins @@ -384,6 +393,7 @@ class RooAbsReal : public RooAbsArg { mutable Float_t _floatValue ; //! Transient cache for floating point values from tree branches mutable Int_t _intValue ; //! Transient cache for integer values from tree branches + mutable Bool_t _boolValue ; //! Transient cache for bool values from tree branches mutable UChar_t _byteValue ; //! Transient cache for byte values from tree branches mutable Char_t _sbyteValue ; //! Transient cache for signed byte values from tree branches mutable UInt_t _uintValue ; //! Transient cache for unsigned integer values from tree branches @@ -405,7 +415,7 @@ class RooAbsReal : public RooAbsArg { PlotOpt() : drawOptions("L"), scaleFactor(1.0), stype(Relative), projData(0), binProjData(kFALSE), projSet(0), precision(1e-3), shiftToZero(kFALSE),projDataSet(0),normRangeName(0),rangeLo(0),rangeHi(0),postRangeFracScale(kFALSE),wmode(RooCurve::Extended), projectionRangeName(0),curveInvisible(kFALSE), curveName(0),addToCurveName(0),addToWgtSelf(1.),addToWgtOther(1.), - numCPU(1),interleave(kTRUE),curveNameSuffix(""), numee(10), eeval(0), doeeval(kFALSE), progress(kFALSE) {} ; + numCPU(1),interleave(RooFit::Interleave),curveNameSuffix(""), numee(10), eeval(0), doeeval(kFALSE), progress(kFALSE) {} ; Option_t* drawOptions ; Double_t scaleFactor ; ScaleType stype ; @@ -427,7 +437,7 @@ class RooAbsReal : public RooAbsArg { Double_t addToWgtSelf ; Double_t addToWgtOther ; Int_t numCPU ; - Bool_t interleave ; + RooFit::MPSplit interleave ; const char* curveNameSuffix ; Int_t numee ; Double_t eeval ; @@ -437,6 +447,12 @@ class RooAbsReal : public RooAbsArg { // Plot implementation functions virtual RooPlot *plotOn(RooPlot* frame, PlotOpt o) const; + +public: + // PlotOn with command list + virtual RooPlot* plotOn(RooPlot* frame, RooLinkedList& cmdList) const ; + + protected: virtual RooPlot *plotAsymOn(RooPlot *frame, const RooAbsCategoryLValue& asymCat, PlotOpt o) const; @@ -463,7 +479,7 @@ class RooAbsReal : public RooAbsArg { static Bool_t _globalSelectComp ; // Global activation switch for component selection mutable RooArgSet* _lastNSet ; //! - + static Bool_t _hideOffset ; // Offset hiding flag ClassDef(RooAbsReal,2) // Abstract real-valued variable }; diff --git a/roofit/roofitcore/inc/RooAbsRealLValue.h b/roofit/roofitcore/inc/RooAbsRealLValue.h index b8b335bfae360..24798e1ba1239 100644 --- a/roofit/roofitcore/inc/RooAbsRealLValue.h +++ b/roofit/roofitcore/inc/RooAbsRealLValue.h @@ -90,11 +90,11 @@ class RooAbsRealLValue : public RooAbsReal, public RooAbsLValue { inline void setConstant(Bool_t value= kTRUE) { setAttribute("Constant",value); setValueDirty() ; setShapeDirty() ; } // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; // Printing interface (human readable) - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; // Build 1-dimensional plots diff --git a/roofit/roofitcore/inc/RooAbsString.h b/roofit/roofitcore/inc/RooAbsString.h index 02db999965b81..9e6f15073ceea 100644 --- a/roofit/roofitcore/inc/RooAbsString.h +++ b/roofit/roofitcore/inc/RooAbsString.h @@ -35,13 +35,14 @@ class RooAbsString : public RooAbsArg { virtual const char* getVal() const ; Bool_t operator==(const char*) const ; virtual Bool_t operator==(const RooAbsArg& other) ; + virtual Bool_t isIdentical(const RooAbsArg& other, Bool_t assumeSameType=kFALSE) ; // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; // Printing interface (human readable) - virtual void printValue(ostream& os) const ; + virtual void printValue(std::ostream& os) const ; RooAbsArg *createFundamental(const char* newname=0) const; diff --git a/roofit/roofitcore/inc/RooAbsTestStatistic.h b/roofit/roofitcore/inc/RooAbsTestStatistic.h index 4d79d010a2495..0f88ab8faa62e 100644 --- a/roofit/roofitcore/inc/RooAbsTestStatistic.h +++ b/roofit/roofitcore/inc/RooAbsTestStatistic.h @@ -20,6 +20,7 @@ #include "RooAbsReal.h" #include "RooSetProxy.h" #include "RooRealProxy.h" +#include "TStopwatch.h" #include <string> class RooArgSet ; @@ -34,18 +35,19 @@ typedef RooAbsData* pRooAbsData ; typedef RooRealMPFE* pRooRealMPFE ; class RooAbsTestStatistic : public RooAbsReal { + friend class RooRealMPFE; public: // Constructors, assignment etc RooAbsTestStatistic() ; RooAbsTestStatistic(const char *name, const char *title, RooAbsReal& real, RooAbsData& data, const RooArgSet& projDeps, const char* rangeName=0, const char* addCoefRangeName=0, - Int_t nCPU=1, Bool_t interleave=kFALSE, Bool_t verbose=kTRUE, Bool_t splitCutRange=kTRUE) ; + Int_t nCPU=1, RooFit::MPSplit interleave=RooFit::BulkPartition, Bool_t verbose=kTRUE, Bool_t splitCutRange=kTRUE) ; RooAbsTestStatistic(const RooAbsTestStatistic& other, const char* name=0); virtual ~RooAbsTestStatistic(); virtual RooAbsTestStatistic* create(const char *name, const char *title, RooAbsReal& real, RooAbsData& data, const RooArgSet& projDeps, const char* rangeName=0, const char* addCoefRangeName=0, - Int_t nCPU=1, Bool_t interleave=kFALSE, Bool_t verbose=kTRUE, Bool_t splitCutRange=kFALSE) = 0 ; + Int_t nCPU=1, RooFit::MPSplit interleave=RooFit::BulkPartition, Bool_t verbose=kTRUE, Bool_t splitCutRange=kFALSE, Bool_t binnedL=kFALSE) = 0 ; virtual void constOptimizeTestStatistic(ConstOpCode opcode, Bool_t doAlsoTrackingOpt=kTRUE) ; @@ -54,17 +56,23 @@ class RooAbsTestStatistic : public RooAbsReal { // Default value of global normalization factor is 1.0 return 1.0 ; } - + Bool_t setData(RooAbsData& data, Bool_t cloneData=kTRUE) ; + void enableOffsetting(Bool_t flag) ; + Bool_t isOffsetting() const { return _doOffset ; } + virtual Double_t offset() const { return _offset ; } + virtual Double_t offsetCarry() const { return _offsetCarry; } + protected: - virtual void printCompactTreeHook(ostream& os, const char* indent="") ; + virtual void printCompactTreeHook(std::ostream& os, const char* indent="") ; virtual Bool_t redirectServersHook(const RooAbsCollection& newServerList, Bool_t mustReplaceAll, Bool_t nameChange, Bool_t isRecursive) ; virtual Double_t evaluate() const ; virtual Double_t evaluatePartition(Int_t firstEvent, Int_t lastEvent, Int_t stepSize) const = 0 ; + virtual Double_t getCarry() const; void setMPSet(Int_t setNum, Int_t numSets) ; void setSimCount(Int_t simCount) { @@ -121,18 +129,25 @@ class RooAbsTestStatistic : public RooAbsReal { Int_t _nEvents ; // Total number of events in test statistic calculation Int_t _setNum ; // Partition number of this instance in parallel calculation mode Int_t _numSets ; // Total number of partitions in parallel calculation mode + Int_t _extSet ; //! Number of designated set to calculated extended term // Simultaneous mode data Int_t _nGof ; // Number of sub-contexts pRooAbsTestStatistic* _gofArray ; //! Array of sub-contexts representing part of the combined test statistic - + std::vector<RooFit::MPSplit> _gofSplitMode ; //! GOF MP Split mode specified by component (when Auto is active) + // Parallel mode data Int_t _nCPU ; // Number of processors to use in parallel calculation mode pRooRealMPFE* _mpfeArray ; //! Array of parallel execution frond ends - Bool_t _mpinterl ; // Use interleaving strategy rather than N-wise split for partioning of dataset for multiprocessor-split + RooFit::MPSplit _mpinterl ; // Use interleaving strategy rather than N-wise split for partioning of dataset for multiprocessor-split + Bool_t _doOffset ; // Apply interval value offset to control numeric precision? + mutable Double_t _offset ; //! Offset + mutable Double_t _offsetCarry; //! avoids loss of precision + mutable Double_t _evalCarry; //! carry of Kahan sum in evaluatePartition + + ClassDef(RooAbsTestStatistic,2) // Abstract base class for real-valued test statistics - ClassDef(RooAbsTestStatistic,1) // Abstract base class for real-valued test statistics }; #endif diff --git a/roofit/roofitcore/inc/RooAddGenContext.h b/roofit/roofitcore/inc/RooAddGenContext.h index ca2b6cee17db2..79311f479d2a7 100644 --- a/roofit/roofitcore/inc/RooAddGenContext.h +++ b/roofit/roofitcore/inc/RooAddGenContext.h @@ -42,7 +42,7 @@ class RooAddGenContext : public RooAbsGenContext { virtual void attach(const RooArgSet& params) ; - virtual void printMultiline(ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; protected: diff --git a/roofit/roofitcore/inc/RooAddModel.h b/roofit/roofitcore/inc/RooAddModel.h index f8f50aa19409f..1350ec4ea62f3 100644 --- a/roofit/roofitcore/inc/RooAddModel.h +++ b/roofit/roofitcore/inc/RooAddModel.h @@ -81,7 +81,7 @@ class RooAddModel : public RooResolutionModel { void fixCoefRange(const char* rangeName) ; virtual void resetErrorCounters(Int_t resetValue=10) ; - void printMetaArgs(ostream& os) const ; + void printMetaArgs(std::ostream& os) const ; protected: diff --git a/roofit/roofitcore/inc/RooAddPdf.h b/roofit/roofitcore/inc/RooAddPdf.h index 8b0ec12495a12..4e67db7115e23 100644 --- a/roofit/roofitcore/inc/RooAddPdf.h +++ b/roofit/roofitcore/inc/RooAddPdf.h @@ -86,7 +86,7 @@ class RooAddPdf : public RooAbsPdf { virtual std::list<Double_t>* binBoundaries(RooAbsRealLValue& /*obs*/, Double_t /*xlo*/, Double_t /*xhi*/) const ; Bool_t isBinnedDistribution(const RooArgSet& obs) const ; - void printMetaArgs(ostream& os) const ; + void printMetaArgs(std::ostream& os) const ; protected: diff --git a/roofit/roofitcore/inc/RooAddition.h b/roofit/roofitcore/inc/RooAddition.h index 224ea121b464d..4d3a0b2a5997a 100644 --- a/roofit/roofitcore/inc/RooAddition.h +++ b/roofit/roofitcore/inc/RooAddition.h @@ -27,7 +27,7 @@ class RooAddition : public RooAbsReal { public: RooAddition() ; - RooAddition(const char *name, const char *title, const RooArgSet& sumSet, Bool_t takeOwnerShip=kFALSE) ; + RooAddition(const char *name, const char *title, const RooArgList& sumSet, Bool_t takeOwnerShip=kFALSE) ; RooAddition(const char *name, const char *title, const RooArgList& sumSet1, const RooArgList& sumSet2, Bool_t takeOwnerShip=kFALSE) ; virtual ~RooAddition() ; @@ -36,7 +36,7 @@ class RooAddition : public RooAbsReal { virtual Double_t defaultErrorLevel() const ; - void printMetaArgs(ostream& os) const ; + void printMetaArgs(std::ostream& os) const ; const RooArgList& list1() const { return _set ; } const RooArgList& list() const { return _set ; } @@ -54,6 +54,8 @@ class RooAddition : public RooAbsReal { virtual std::list<Double_t>* plotSamplingHint(RooAbsRealLValue& /*obs*/, Double_t /*xlo*/, Double_t /*xhi*/) const ; Bool_t isBinnedDistribution(const RooArgSet& obs) const ; + virtual void enableOffsetting(Bool_t) ; + protected: RooArgList _ownedList ; // List of owned components diff --git a/roofit/roofitcore/inc/RooArgList.h b/roofit/roofitcore/inc/RooArgList.h index 1b6c94ed7e812..284f37379ba50 100644 --- a/roofit/roofitcore/inc/RooArgList.h +++ b/roofit/roofitcore/inc/RooArgList.h @@ -88,8 +88,8 @@ class RooArgList : public RooAbsCollection { } // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) ; RooAbsArg& operator[](Int_t idx) const ; diff --git a/roofit/roofitcore/inc/RooArgProxy.h b/roofit/roofitcore/inc/RooArgProxy.h index f71a539db24ff..f9deaaaf0c74b 100644 --- a/roofit/roofitcore/inc/RooArgProxy.h +++ b/roofit/roofitcore/inc/RooArgProxy.h @@ -43,7 +43,7 @@ class RooArgProxy : public TNamed, public RooAbsProxy { // Return name of proxy return GetName() ; } - virtual void print(ostream& os, Bool_t addContents=kFALSE) const ; + virtual void print(std::ostream& os, Bool_t addContents=kFALSE) const ; protected: diff --git a/roofit/roofitcore/inc/RooArgSet.h b/roofit/roofitcore/inc/RooArgSet.h index 63e62cf5e1674..5d9f3ecfefac1 100644 --- a/roofit/roofitcore/inc/RooArgSet.h +++ b/roofit/roofitcore/inc/RooArgSet.h @@ -103,12 +103,12 @@ class RooArgSet : public RooAbsCollection { RooAbsArg& operator[](const char* name) const ; - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) { + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) { // I/O streaming interface (machine readable) return readFromStream(is, compact, 0, 0, verbose) ; } - Bool_t readFromStream(istream& is, Bool_t compact, const char* flagReadAtt, const char* section, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact, const char* section=0) const; + Bool_t readFromStream(std::istream& is, Bool_t compact, const char* flagReadAtt, const char* section, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact, const char* section=0) const; void writeToFile(const char* fileName) const ; Bool_t readFromFile(const char* fileName, const char* flagReadAtt=0, const char* section=0, Bool_t verbose=kFALSE) ; diff --git a/roofit/roofitcore/inc/RooBinnedGenContext.h b/roofit/roofitcore/inc/RooBinnedGenContext.h index c17c5afe72af7..ee8e135270cf6 100644 --- a/roofit/roofitcore/inc/RooBinnedGenContext.h +++ b/roofit/roofitcore/inc/RooBinnedGenContext.h @@ -33,13 +33,13 @@ class RooBinnedGenContext : public RooAbsGenContext { const RooArgSet* auxProto=0, Bool_t _verbose= kFALSE); virtual ~RooBinnedGenContext(); - RooDataSet* generate(Int_t nEvents=0, Bool_t skipInit=kFALSE, Bool_t extendedMode=kFALSE) ; + RooDataSet* generate(Double_t nEvents=0, Bool_t skipInit=kFALSE, Bool_t extendedMode=kFALSE) ; virtual void setProtoDataOrder(Int_t*) {} virtual void attach(const RooArgSet& params) ; - virtual void printMultiline(ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; virtual void setExpectedData(Bool_t) ; diff --git a/roofit/roofitcore/inc/RooBinning.h b/roofit/roofitcore/inc/RooBinning.h index 4838574579695..af2011001c6ca 100644 --- a/roofit/roofitcore/inc/RooBinning.h +++ b/roofit/roofitcore/inc/RooBinning.h @@ -21,72 +21,73 @@ #include "RooDouble.h" #include "RooAbsBinning.h" #include "RooNumber.h" -#include <set> -class RooAbsPdf ; -class RooRealVar ; +#include <vector> +class RooAbsPdf; +class RooRealVar; class RooBinning : public RooAbsBinning { public: - RooBinning(Double_t xlo=-RooNumber::infinity(), Double_t xhi=RooNumber::infinity(), const char* name=0) ; - RooBinning(Int_t nBins, Double_t xlo, Double_t xhi, const char* name=0) ; - RooBinning(Int_t nBins, const Double_t* boundaries, const char* name=0) ; - RooBinning(const RooBinning& other, const char* name=0) ; - RooAbsBinning* clone(const char* name=0) const { return new RooBinning(*this,name?name:GetName()) ; } - ~RooBinning() ; + RooBinning(Double_t xlo = -RooNumber::infinity(), Double_t xhi = RooNumber::infinity(), const char* name = 0); + RooBinning(Int_t nBins, Double_t xlo, Double_t xhi, const char* name = 0); + RooBinning(Int_t nBins, const Double_t* boundaries, const char* name = 0); + RooBinning(const RooBinning& other, const char* name = 0); + RooAbsBinning* clone(const char* name = 0) const { return new RooBinning(*this,name?name:GetName()); } + ~RooBinning(); - virtual Int_t numBoundaries() const { + virtual Int_t numBoundaries() const { // Return the number boundaries - return _nbins+1 ; + return _nbins+1; } - virtual Int_t binNumber(Double_t x) const ; - virtual Int_t rawBinNumber(Double_t x) const ; - virtual Double_t nearestBoundary(Double_t x) const ; + virtual Int_t binNumber(Double_t x) const; + virtual Int_t rawBinNumber(Double_t x) const; + virtual Double_t nearestBoundary(Double_t x) const; - virtual void setRange(Double_t xlo, Double_t xhi) ; + virtual void setRange(Double_t xlo, Double_t xhi); - virtual Double_t lowBound() const { + virtual Double_t lowBound() const { // Return the lower bound value - return _xlo ; + return _xlo; } - virtual Double_t highBound() const { + virtual Double_t highBound() const { // Return the upper bound value - return _xhi ; + return _xhi; } - virtual Double_t averageBinWidth() const { + virtual Double_t averageBinWidth() const { // Return the average bin width - return (highBound()-lowBound())/numBins() ; + return (highBound() - lowBound()) / numBins(); } - virtual Double_t* array() const ; - - virtual Double_t binCenter(Int_t bin) const ; - virtual Double_t binWidth(Int_t bin) const ; - virtual Double_t binLow(Int_t bin) const ; - virtual Double_t binHigh(Int_t bin) const ; - - Bool_t addBoundary(Double_t boundary) ; - void addBoundaryPair(Double_t boundary, Double_t mirrorPoint=0) ; - void addUniform(Int_t nBins, Double_t xlo, Double_t xhi) ; - Bool_t removeBoundary(Double_t boundary) ; - - Bool_t hasBoundary(Double_t boundary) ; - + virtual Double_t* array() const; + + virtual Double_t binCenter(Int_t bin) const; + virtual Double_t binWidth(Int_t bin) const; + virtual Double_t binLow(Int_t bin) const; + virtual Double_t binHigh(Int_t bin) const; + + Bool_t addBoundary(Double_t boundary); + void addBoundaryPair(Double_t boundary, Double_t mirrorPoint = 0); + void addUniform(Int_t nBins, Double_t xlo, Double_t xhi); + Bool_t removeBoundary(Double_t boundary); + + Bool_t hasBoundary(Double_t boundary); + protected: - Bool_t binEdges(Int_t bin, Double_t& xlo, Double_t& xhi) const ; - void updateBinCount() ; + Bool_t binEdges(Int_t bin, Double_t& xlo, Double_t& xhi) const; + void updateBinCount(); - Double_t _xlo ; // Lower bound - Double_t _xhi ; // Upper bound - Bool_t _ownBoundLo ; // Does the lower bound coincide with a bin boundary - Bool_t _ownBoundHi ; // Does the upper bound coincide with a bin boundary - Int_t _nbins ; // Numer of bins + Double_t _xlo; // Lower bound + Double_t _xhi; // Upper bound + Bool_t _ownBoundLo; // Does the lower bound coincide with a bin boundary + Bool_t _ownBoundHi; // Does the upper bound coincide with a bin boundary + Int_t _nbins; // Numer of bins - std::set<Double_t> _boundaries ; // Boundaries - mutable Double_t* _array ; //! Array of boundaries + std::vector<Double_t> _boundaries; // Boundaries + mutable Double_t* _array; //! Array of boundaries + mutable Int_t _blo; //! bin number for _xlo - ClassDef(RooBinning,2) // Generic binning specification + ClassDef(RooBinning,3) // Generic binning specification }; #endif diff --git a/roofit/roofitcore/inc/RooBinningCategory.h b/roofit/roofitcore/inc/RooBinningCategory.h index da4908090a220..b01cd5da2ab4b 100644 --- a/roofit/roofitcore/inc/RooBinningCategory.h +++ b/roofit/roofitcore/inc/RooBinningCategory.h @@ -26,17 +26,17 @@ class RooBinningCategory : public RooAbsCategory { public: // Constructors etc. inline RooBinningCategory() { } - RooBinningCategory(const char *name, const char *title, RooAbsRealLValue& inputVar, const char* binningName=0); + RooBinningCategory(const char *name, const char *title, RooAbsRealLValue& inputVar, const char* binningName=0, const char* catTypeName=0); RooBinningCategory(const RooBinningCategory& other, const char *name=0) ; virtual TObject* clone(const char* newname) const { return new RooBinningCategory(*this, newname); } virtual ~RooBinningCategory(); // Printing interface (human readable) - virtual void printMultiline(ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; protected: - void initialize() ; + void initialize(const char* catTypeName=0) ; RooRealProxy _inputVar ; // Input variable that is mapped TString _bname ; // Name of the binning specification to be used to perform the mapping diff --git a/roofit/roofitcore/inc/RooCacheManager.h b/roofit/roofitcore/inc/RooCacheManager.h index 4c1078027c8fc..a75948813d84a 100644 --- a/roofit/roofitcore/inc/RooCacheManager.h +++ b/roofit/roofitcore/inc/RooCacheManager.h @@ -18,7 +18,6 @@ #include "Rtypes.h" -#include "Riostream.h" #include "RooMsgService.h" #include "RooNormSetCache.h" #include "RooAbsReal.h" @@ -94,12 +93,12 @@ class RooCacheManager : public RooAbsCache { void wireCache() { if (_size==0) { - oocoutI(_owner,Optimization) << "RooCacheManager::wireCache(" << _owner->GetName() << ") no cached elements!" << endl ; + oocoutI(_owner,Optimization) << "RooCacheManager::wireCache(" << _owner->GetName() << ") no cached elements!" << std::endl ; } else if (_size==1) { - oocoutI(_owner,Optimization) << "RooCacheManager::wireCache(" << _owner->GetName() << ") now wiring cache" << endl ; + oocoutI(_owner,Optimization) << "RooCacheManager::wireCache(" << _owner->GetName() << ") now wiring cache" << std::endl ; _wired=kTRUE ; } else if (_size>1) { - oocoutI(_owner,Optimization) << "RooCacheManager::wireCache(" << _owner->GetName() << ") cache cannot be wired because it contains more than one element" << endl ; + oocoutI(_owner,Optimization) << "RooCacheManager::wireCache(" << _owner->GetName() << ") cache cannot be wired because it contains more than one element" << std::endl ; } } @@ -168,7 +167,7 @@ RooCacheManager<T>::RooCacheManager(const RooCacheManager& other, RooAbsArg* own _wired = kFALSE ; _lastIndex = -1 ; -// cout << "RooCacheManager:cctor(" << this << ")" << endl ; +// std::cout << "RooCacheManager:cctor(" << this << ")" << std::endl ; Int_t i ; for (i=0 ; i<other._size ; i++) { @@ -317,7 +316,7 @@ T* RooCacheManager<T>::getObjByIndex(Int_t index) const if (index<0||index>=_size) { oocoutE(_owner,ObjectHandling) << "RooCacheManager::getNormListByIndex: ERROR index (" - << index << ") out of range [0," << _size-1 << "]" << endl ; + << index << ") out of range [0," << _size-1 << "]" << std::endl ; return 0 ; } return _object[index] ; @@ -330,7 +329,7 @@ const RooNameSet* RooCacheManager<T>::nameSet1ByIndex(Int_t index) const if (index<0||index>=_size) { oocoutE(_owner,ObjectHandling) << "RooCacheManager::getNormListByIndex: ERROR index (" - << index << ") out of range [0," << _size-1 << "]" << endl ; + << index << ") out of range [0," << _size-1 << "]" << std::endl ; return 0 ; } return &_nsetCache[index].nameSet1() ; @@ -343,7 +342,7 @@ const RooNameSet* RooCacheManager<T>::nameSet2ByIndex(Int_t index) const if (index<0||index>=_size) { oocoutE(_owner,ObjectHandling) << "RooCacheManager::getNormListByIndex: ERROR index (" - << index << ") out of range [0," << _size-1 << "]" << endl ; + << index << ") out of range [0," << _size-1 << "]" << std::endl ; return 0 ; } return &_nsetCache[index].nameSet2() ; diff --git a/roofit/roofitcore/inc/RooCachedReal.h b/roofit/roofitcore/inc/RooCachedReal.h index f06b680f8b8ac..d7fe96aca0606 100644 --- a/roofit/roofitcore/inc/RooCachedReal.h +++ b/roofit/roofitcore/inc/RooCachedReal.h @@ -19,7 +19,7 @@ class RooCachedReal : public RooAbsCachedReal { public: - RooCachedReal() { + RooCachedReal() : _cacheSource(kFALSE) { // coverity[UNINIT_CTOR] } RooCachedReal(const char *name, const char *title, RooAbsReal& _func, const RooArgSet& cacheObs); @@ -40,6 +40,9 @@ class RooCachedReal : public RooAbsCachedReal { return _useCdfBoundaries ; } + Bool_t cacheSource() const { return _cacheSource ; } + void setCacheSource(Bool_t flag) { _cacheSource = flag ; } + protected: virtual const char* inputBaseName() const { @@ -56,15 +59,18 @@ class RooCachedReal : public RooAbsCachedReal { void operModeHook() ; + virtual FuncCacheElem* createCache(const RooArgSet* nset) const ; + virtual const char* payloadUniqueSuffix() const { return func.arg().aggregateCacheUniqueSuffix() ; } RooRealProxy func ; // Proxy to function being cached RooSetProxy _cacheObs ; // Variables to be cached Bool_t _useCdfBoundaries ; // Are c.d.f boundary conditions used by the RooHistFuncs? + Bool_t _cacheSource ; // Keep an attached clone of the source in the cache for fast operation private: - ClassDef(RooCachedReal,1) // P.d.f class that wraps another p.d.f and caches its output + ClassDef(RooCachedReal,2) // P.d.f class that wraps another p.d.f and caches its output }; diff --git a/roofit/roofitcore/inc/RooCatType.h b/roofit/roofitcore/inc/RooCatType.h index 49f9fe2eb0eca..181a380773403 100644 --- a/roofit/roofitcore/inc/RooCatType.h +++ b/roofit/roofitcore/inc/RooCatType.h @@ -86,10 +86,10 @@ class RooCatType : public TObject, public RooPrintable { _value = newValue ; } - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printValue(ostream& os) const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printValue(std::ostream& os) const ; inline virtual void Print(Option_t *options= 0) const { // Printing interface diff --git a/roofit/roofitcore/inc/RooCategory.h b/roofit/roofitcore/inc/RooCategory.h index ed69fe90c54e8..1480891a627eb 100644 --- a/roofit/roofitcore/inc/RooCategory.h +++ b/roofit/roofitcore/inc/RooCategory.h @@ -49,8 +49,8 @@ class RooCategory : public RooAbsCategoryLValue { virtual Bool_t setLabel(const char* label, Bool_t printError=kTRUE) ; // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; // We implement a fundamental type of AbsArg that can be stored in a dataset inline virtual Bool_t isFundamental() const { diff --git a/roofit/roofitcore/inc/RooChi2Var.h b/roofit/roofitcore/inc/RooChi2Var.h index b56fd8e5eae2d..9768938ff274b 100644 --- a/roofit/roofitcore/inc/RooChi2Var.h +++ b/roofit/roofitcore/inc/RooChi2Var.h @@ -40,18 +40,18 @@ class RooChi2Var : public RooAbsOptTestStatistic { RooChi2Var(const char *name, const char *title, RooAbsPdf& pdf, RooDataHist& data, Bool_t extended=kFALSE, const char* rangeName=0, const char* addCoefRangeName=0, - Int_t nCPU=1, Bool_t interleave=kFALSE, Bool_t verbose=kTRUE, Bool_t splitCutRange=kTRUE, RooDataHist::ErrorType=RooDataHist::SumW2) ; + Int_t nCPU=1, RooFit::MPSplit interleave=RooFit::BulkPartition, Bool_t verbose=kTRUE, Bool_t splitCutRange=kTRUE, RooDataHist::ErrorType=RooDataHist::SumW2) ; RooChi2Var(const char *name, const char *title, RooAbsReal& func, RooDataHist& data, const RooArgSet& projDeps, FuncMode funcMode, const char* rangeName=0, const char* addCoefRangeName=0, - Int_t nCPU=1, Bool_t interleave=kFALSE, Bool_t verbose=kTRUE, Bool_t splitCutRange=kTRUE, RooDataHist::ErrorType=RooDataHist::SumW2) ; + Int_t nCPU=1, RooFit::MPSplit interleave=RooFit::BulkPartition, Bool_t verbose=kTRUE, Bool_t splitCutRange=kTRUE, RooDataHist::ErrorType=RooDataHist::SumW2) ; RooChi2Var(const RooChi2Var& other, const char* name=0); virtual TObject* clone(const char* newname) const { return new RooChi2Var(*this,newname); } virtual RooAbsTestStatistic* create(const char *name, const char *title, RooAbsReal& pdf, RooAbsData& dhist, const RooArgSet& projDeps, const char* rangeName=0, const char* addCoefRangeName=0, - Int_t nCPU=1, Bool_t interleave=kFALSE,Bool_t verbose=kTRUE, Bool_t splitCutRange=kTRUE) { + Int_t nCPU=1, RooFit::MPSplit interleave=RooFit::BulkPartition,Bool_t verbose=kTRUE, Bool_t splitCutRange=kTRUE, Bool_t = kFALSE) { // Virtual constructor return new RooChi2Var(name,title,(RooAbsPdf&)pdf,(RooDataHist&)dhist,projDeps,_funcMode,rangeName, addCoefRangeName,nCPU,interleave,verbose, splitCutRange,_etype) ; diff --git a/roofit/roofitcore/inc/RooCintUtils.h b/roofit/roofitcore/inc/RooCintUtils.h index 2e6e59c2c4154..c15f43458753b 100644 --- a/roofit/roofitcore/inc/RooCintUtils.h +++ b/roofit/roofitcore/inc/RooCintUtils.h @@ -24,8 +24,6 @@ namespace RooCintUtils { std::pair<std::list<std::string>,unsigned int> ctorArgs(const char* classname, UInt_t nMinArgs=0) ; Bool_t isEnum(const char* typeName) ; Bool_t isValidEnumValue(const char* typeName, const char* value) ; - const char* functionName(void* func) ; - Bool_t matchFuncPtrArgs(void* func, const char* args) ; Bool_t isTypeDef(const char* trueName, const char* aliasName) ; std::string trueName(const char* typeDefName) ; diff --git a/roofit/roofitcore/inc/RooClassFactory.h b/roofit/roofitcore/inc/RooClassFactory.h index c4afd5735e8d1..68df6054928ff 100644 --- a/roofit/roofitcore/inc/RooClassFactory.h +++ b/roofit/roofitcore/inc/RooClassFactory.h @@ -45,7 +45,7 @@ class RooClassFactory : public TNamed, public RooPrintable { static Bool_t makePdf(const char* name, const char* realArgNames=0, const char* catArgNames=0, const char* expression="1.0", Bool_t hasAnaInt=kFALSE, Bool_t hasIntGen=kFALSE, const char* intExpression=0) ; static Bool_t makeFunction(const char* name, const char* realArgNames=0, const char* catArgNames=0, - const char* expresion="1.0", Bool_t hasAnaInt=kFALSE, const char* intExpression=0) ; + const char* expression="1.0", Bool_t hasAnaInt=kFALSE, const char* intExpression=0) ; static Bool_t makeClass(const char* className, const char* name, const char* realArgNames=0, const char* catArgNames=0, const char* expression="1.0", Bool_t hasAnaInt=kFALSE, Bool_t hasIntGen=kFALSE, const char* intExpression=0) ; diff --git a/roofit/roofitcore/inc/RooComplex.h b/roofit/roofitcore/inc/RooComplex.h index 9840198dccd81..9cce555b2a1c6 100644 --- a/roofit/roofitcore/inc/RooComplex.h +++ b/roofit/roofitcore/inc/RooComplex.h @@ -16,9 +16,15 @@ #ifndef ROO_COMPLEX #define ROO_COMPLEX +#if !defined(ROO_MATH) && !defined(ROO_COMPLEX_CXX) && !defined(__CINT__) && !defined(__CLING__) && \ + !defined(R__DICTIONARY_FILENAME) +#warning "RooComplex is deprecated, use std::complex instead!" +#endif + #include <math.h> #include "Rtypes.h" #include "Riosfwd.h" +#include <complex> // This is a bare-bones complex class adapted from the CINT complex.h header, // and introduced to support the complex error function in RooMath. The main @@ -28,9 +34,13 @@ class RooComplex { public: - inline RooComplex(Double_t a=0, Double_t b=0) : _re(a), _im(b) { } - virtual ~RooComplex() {} ; + + inline RooComplex(std::complex<Double_t> c) : _re(c.real()), _im(c.imag()) { } + + inline RooComplex(Double_t a=0, Double_t b=0) : _re(a), _im(b) { warn(); } + virtual ~RooComplex() { } inline RooComplex& operator=(const RooComplex& other) { + warn(); if (&other==this) return *this ; this->_re= other._re; this->_im= other._im; @@ -94,10 +104,13 @@ class RooComplex { void Print() const; private: Double_t _re,_im; + + void warn() const; + ClassDef(RooComplex,0) // a non-persistent bare-bones complex class }; // output formatting -ostream& operator<<(ostream& os, const RooComplex& z); +std::ostream& operator<<(std::ostream& os, const RooComplex& z); #endif diff --git a/roofit/roofitcore/inc/RooCompositeDataStore.h b/roofit/roofitcore/inc/RooCompositeDataStore.h index 91f09ebf95478..b03b452b46f9d 100644 --- a/roofit/roofitcore/inc/RooCompositeDataStore.h +++ b/roofit/roofitcore/inc/RooCompositeDataStore.h @@ -85,12 +85,12 @@ class RooCompositeDataStore : public RooAbsDataStore { virtual void resetBuffers() ; // Constant term optimizer interface - virtual void cacheArgs(const RooAbsArg* owner, RooArgSet& varSet, const RooArgSet* nset=0) ; + virtual void cacheArgs(const RooAbsArg* owner, RooArgSet& varSet, const RooArgSet* nset=0, Bool_t skipZeroWeights=kFALSE) ; virtual const RooAbsArg* cacheOwner() { return 0 ; } virtual void setArgStatus(const RooArgSet& set, Bool_t active) ; virtual void resetCache() ; - virtual void recalculateCache(const RooArgSet* /*proj*/, Int_t /*firstEvent*/, Int_t /*lastEvent*/, Int_t /*stepSize*/) ; + virtual void recalculateCache(const RooArgSet* /*proj*/, Int_t /*firstEvent*/, Int_t /*lastEvent*/, Int_t /*stepSize*/, Bool_t /*skipZeroWeights*/) ; void loadValues(const RooAbsDataStore *tds, const RooFormulaVar* select=0, const char* rangeName=0, Int_t nStart=0, Int_t nStop=2000000000) ; diff --git a/roofit/roofitcore/inc/RooConstVar.h b/roofit/roofitcore/inc/RooConstVar.h index 035824517dd62..4f58b3e2f3591 100644 --- a/roofit/roofitcore/inc/RooConstVar.h +++ b/roofit/roofitcore/inc/RooConstVar.h @@ -34,7 +34,7 @@ class RooConstVar : public RooAbsReal { virtual ~RooConstVar(); virtual Double_t getValV(const RooArgSet* set=0) const ; - void writeToStream(ostream& os, Bool_t compact) const ; + void writeToStream(std::ostream& os, Bool_t compact) const ; virtual Bool_t isDerived() const { // Does value or shape of this arg depend on any other arg? diff --git a/roofit/roofitcore/inc/RooConstraintSum.h b/roofit/roofitcore/inc/RooConstraintSum.h index 8cc5cc8633a69..24a45d11ea10d 100644 --- a/roofit/roofitcore/inc/RooConstraintSum.h +++ b/roofit/roofitcore/inc/RooConstraintSum.h @@ -19,6 +19,7 @@ #include "RooAbsReal.h" #include "RooListProxy.h" #include "RooSetProxy.h" +#include "TStopwatch.h" class RooRealVar; class RooArgList ; @@ -33,6 +34,8 @@ class RooConstraintSum : public RooAbsReal { RooConstraintSum(const RooConstraintSum& other, const char* name = 0); virtual TObject* clone(const char* newname) const { return new RooConstraintSum(*this, newname); } + const RooArgList& list() { return _set1 ; } + protected: RooListProxy _set1 ; // Set of constraint terms diff --git a/roofit/roofitcore/inc/RooConvGenContext.h b/roofit/roofitcore/inc/RooConvGenContext.h index fee75239d79a8..d48eee2538f73 100644 --- a/roofit/roofitcore/inc/RooConvGenContext.h +++ b/roofit/roofitcore/inc/RooConvGenContext.h @@ -43,7 +43,7 @@ class RooConvGenContext : public RooAbsGenContext { virtual void attach(const RooArgSet& params) ; - virtual void printMultiline(ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; protected: diff --git a/roofit/roofitcore/inc/RooCurve.h b/roofit/roofitcore/inc/RooCurve.h index 286d5a78d559e..d344ddf3b9f13 100644 --- a/roofit/roofitcore/inc/RooCurve.h +++ b/roofit/roofitcore/inc/RooCurve.h @@ -51,10 +51,10 @@ class RooCurve : public TGraph, public RooPlotable { Double_t getFitRangeNEvt() const; - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const; inline virtual void Print(Option_t *options= 0) const { // Printing interface diff --git a/roofit/roofitcore/inc/RooCustomizer.h b/roofit/roofitcore/inc/RooCustomizer.h index d0c22ef7748e5..2cb1c5dd3c69a 100644 --- a/roofit/roofitcore/inc/RooCustomizer.h +++ b/roofit/roofitcore/inc/RooCustomizer.h @@ -59,11 +59,11 @@ class RooCustomizer : public TNamed, public RooPrintable { } // Printing interface - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printArgs(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent= "") const; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printArgs(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent= "") const; inline virtual void Print(Option_t *options= 0) const { // Printing interface diff --git a/roofit/roofitcore/inc/RooDataHist.h b/roofit/roofitcore/inc/RooDataHist.h index 3d43be9a96104..a2201ec0579c2 100644 --- a/roofit/roofitcore/inc/RooDataHist.h +++ b/roofit/roofitcore/inc/RooDataHist.h @@ -16,15 +16,16 @@ #ifndef ROO_DATA_HIST #define ROO_DATA_HIST +#include <map> +#include <vector> +#include <string> +#include <utility> + #include "RooAbsData.h" #include "RooDirItem.h" #include "RooArgSet.h" #include "RooNameSet.h" #include "RooCacheManager.h" -#include <vector> -#include <list> -#include <map> -#include <string> class TObject ; class RooAbsArg; @@ -90,11 +91,13 @@ class RooDataHist : public RooAbsData, public RooDirItem { Double_t sum(Bool_t correctForBinSize, Bool_t inverseCorr=kFALSE) const ; Double_t sum(const RooArgSet& sumSet, const RooArgSet& sliceSet, Bool_t correctForBinSize, Bool_t inverseCorr=kFALSE) ; + Double_t sum(const RooArgSet& sumSet, const RooArgSet& sliceSet, Bool_t correctForBinSize, Bool_t inverseCorr, const std::map<const RooAbsArg*, std::pair<Double_t, Double_t> >& ranges); virtual Double_t weight() const { // Return weight of current bin return _curWeight ; } + Double_t weightSquared() const ; Double_t weight(const RooArgSet& bin, Int_t intOrder=1, Bool_t correctForBinSize=kFALSE, Bool_t cdfBoundaries=kFALSE, Bool_t oneSafe=kFALSE) ; Double_t binVolume() const { return _curVolume ; } Double_t binVolume(const RooArgSet& bin) ; @@ -116,9 +119,9 @@ class RooDataHist : public RooAbsData, public RooDirItem { virtual void reset() ; void dump2() ; - virtual void printMultiline(ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; - virtual void printArgs(ostream& os) const ; - virtual void printValue(ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printArgs(std::ostream& os) const ; + virtual void printValue(std::ostream& os) const ; void SetName(const char *name) ; void SetNameTitle(const char *name, const char* title) ; @@ -146,6 +149,7 @@ class RooDataHist : public RooAbsData, public RooDirItem { Int_t nStart=0, Int_t nStop=2000000000, Bool_t copyCache=kTRUE) ; Double_t interpolateDim(RooRealVar& dim, const RooAbsBinning* binning, Double_t xval, Int_t intOrder, Bool_t correctForBinSize, Bool_t cdfBoundaries) ; void calculatePartialBinVolume(const RooArgSet& dimSet) const ; + void checkBinBounds() const; void adjustBinning(const RooArgList& vars, TH1& href, Int_t* offset=0) ; void importTH1(const RooArgList& vars, TH1& histo, Double_t initWgt, Bool_t doDensityCorrection) ; @@ -177,8 +181,9 @@ class RooDataHist : public RooAbsData, public RooDirItem { mutable std::vector<Double_t>* _pbinv ; //! Partial bin volume array mutable RooCacheManager<std::vector<Double_t> > _pbinvCacheMgr ; //! Cache manager for arrays of partial bin volumes - std::list<RooAbsLValue*> _lvvars ; //! List of observables casted as RooAbsLValue - std::list<const RooAbsBinning*> _lvbins ; //! List of used binnings associated with lvalues + std::vector<RooAbsLValue*> _lvvars ; //! List of observables casted as RooAbsLValue + std::vector<const RooAbsBinning*> _lvbins ; //! List of used binnings associated with lvalues + mutable std::vector<std::vector<Double_t> > _binbounds; //! list of bin bounds per dimension private: diff --git a/roofit/roofitcore/inc/RooDataSet.h b/roofit/roofitcore/inc/RooDataSet.h index fd498d863b18a..2331af2946cb6 100644 --- a/roofit/roofitcore/inc/RooDataSet.h +++ b/roofit/roofitcore/inc/RooDataSet.h @@ -94,6 +94,7 @@ class RooDataSet : public RooAbsData, public RooDirItem { virtual Bool_t isNonPoissonWeighted() const ; virtual Double_t weight() const ; + virtual Double_t weightSquared() const ; virtual void weightError(Double_t& lo, Double_t& hi,ErrorType etype=SumW2) const ; Double_t weightError(ErrorType etype=SumW2) const ; @@ -121,9 +122,9 @@ class RooDataSet : public RooAbsData, public RooDirItem { TH2F* createHistogram(const RooAbsRealLValue& var1, const RooAbsRealLValue& var2, Int_t nx, Int_t ny, const char* cuts="", const char *name="hist") const; - void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; - virtual void printArgs(ostream& os) const ; - virtual void printValue(ostream& os) const ; + void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printArgs(std::ostream& os) const ; + virtual void printValue(std::ostream& os) const ; void SetName(const char *name) ; void SetNameTitle(const char *name, const char* title) ; diff --git a/roofit/roofitcore/inc/RooDataWeightedAverage.h b/roofit/roofitcore/inc/RooDataWeightedAverage.h index d979f97c61b62..3fc3590400b4a 100644 --- a/roofit/roofitcore/inc/RooDataWeightedAverage.h +++ b/roofit/roofitcore/inc/RooDataWeightedAverage.h @@ -28,14 +28,14 @@ class RooDataWeightedAverage : public RooAbsOptTestStatistic { } ; RooDataWeightedAverage(const char *name, const char *title, RooAbsReal& real, RooAbsData& data, const RooArgSet& projDeps, - Int_t nCPU=1, Bool_t interleave=kFALSE, Bool_t showProgress=kFALSE, Bool_t verbose=kTRUE) ; + Int_t nCPU=1, RooFit::MPSplit interleave=RooFit::BulkPartition, Bool_t showProgress=kFALSE, Bool_t verbose=kTRUE) ; RooDataWeightedAverage(const RooDataWeightedAverage& other, const char* name=0); virtual TObject* clone(const char* newname) const { return new RooDataWeightedAverage(*this,newname); } virtual RooAbsTestStatistic* create(const char *name, const char *title, RooAbsReal& real, RooAbsData& adata, const RooArgSet& projDeps, const char* /*rangeName*/=0, const char* /*addCoefRangeName*/=0, - Int_t nCPU=1, Bool_t interleave=kFALSE, Bool_t verbose=kTRUE, Bool_t /*splitCutRange*/=kFALSE) { + Int_t nCPU=1, RooFit::MPSplit interleave=RooFit::BulkPartition, Bool_t verbose=kTRUE, Bool_t /*splitCutRange*/=kFALSE, Bool_t = kFALSE) { // Virtual constructor return new RooDataWeightedAverage(name,title,real,adata,projDeps,nCPU,interleave,verbose) ; } diff --git a/roofit/roofitcore/inc/RooEllipse.h b/roofit/roofitcore/inc/RooEllipse.h index 3b610f20b99b2..e6be5fb06c513 100644 --- a/roofit/roofitcore/inc/RooEllipse.h +++ b/roofit/roofitcore/inc/RooEllipse.h @@ -26,10 +26,10 @@ class RooEllipse : public TGraph, public RooPlotable { virtual ~RooEllipse(); - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const; inline virtual void Print(Option_t *options= 0) const { // Printing interface diff --git a/roofit/roofitcore/inc/RooErrorVar.h b/roofit/roofitcore/inc/RooErrorVar.h index 76d44ef6db7e5..08d8e455d1ffe 100644 --- a/roofit/roofitcore/inc/RooErrorVar.h +++ b/roofit/roofitcore/inc/RooErrorVar.h @@ -55,8 +55,8 @@ class RooErrorVar : public RooAbsRealLValue { } // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; // Set/get finite fit range limits inline void setMin(Double_t value) { @@ -83,6 +83,7 @@ class RooErrorVar : public RooAbsRealLValue { const RooAbsBinning& getBinning(const char* name=0, Bool_t verbose=kTRUE, Bool_t createOnTheFly=kFALSE) const ; RooAbsBinning& getBinning(const char* name=0, Bool_t verbose=kTRUE, Bool_t createOnTheFly=kFALSE) ; Bool_t hasBinning(const char* name) const ; + std::list<std::string> getBinningNames() const ; // Set infinite fit range limits inline void removeMin(const char* name=0) { diff --git a/roofit/roofitcore/inc/RooExtendedBinding.h b/roofit/roofitcore/inc/RooExtendedBinding.h new file mode 100644 index 0000000000000..3229e5d0b65cb --- /dev/null +++ b/roofit/roofitcore/inc/RooExtendedBinding.h @@ -0,0 +1,35 @@ +/***************************************************************************** + * Project: RooFit * + * * + * This code was autogenerated by RooClassFactory * + *****************************************************************************/ + +#ifndef ROOEXTENDEDBINDING +#define ROOEXTENDEDBINDING + +#include "RooAbsReal.h" +#include "RooRealProxy.h" +#include "RooCategoryProxy.h" +#include "RooAbsPdf.h" +#include "RooAbsCategory.h" + +class RooExtendedBinding : public RooAbsReal { +public: + RooExtendedBinding() {} ; + RooExtendedBinding(const char *name, const char *title, RooAbsPdf& _pdf); + RooExtendedBinding(const RooExtendedBinding& other, const char* name=0) ; + virtual TObject* clone(const char* newname) const { return new RooExtendedBinding(*this,newname); } + inline virtual ~RooExtendedBinding() { } + +protected: + + RooRealProxy pdf ; + + Double_t evaluate() const ; + +private: + + ClassDef(RooExtendedBinding,1) // Your description goes here... +}; + +#endif diff --git a/roofit/roofitcore/inc/RooFFTConvPdf.h b/roofit/roofitcore/inc/RooFFTConvPdf.h index b21954a022e3e..7c6ea7af00d34 100644 --- a/roofit/roofitcore/inc/RooFFTConvPdf.h +++ b/roofit/roofitcore/inc/RooFFTConvPdf.h @@ -55,7 +55,7 @@ class RooFFTConvPdf : public RooAbsCachedPdf { void setBufferStrategy(BufStrat bs) ; void setBufferFraction(Double_t frac) ; - void printMetaArgs(ostream& os) const ; + void printMetaArgs(std::ostream& os) const ; // Propagate maximum value estimate of pdf1 as convolution can only result in lower max values virtual Int_t getMaxVal(const RooArgSet& vars) const { return _pdf1.arg().getMaxVal(vars) ; } diff --git a/roofit/roofitcore/inc/RooFitCore_LinkDef.h b/roofit/roofitcore/inc/RooFitCore_LinkDef.h index 28dba2afa193f..b6fcaa6c35aa2 100644 --- a/roofit/roofitcore/inc/RooFitCore_LinkDef.h +++ b/roofit/roofitcore/inc/RooFitCore_LinkDef.h @@ -11,7 +11,6 @@ #pragma link C++ class RooAbsBinning- ; #pragma link C++ class Roo* ; #pragma link off class RooErrorHandler ; -#pragma link off class RooNag ; #pragma link C++ class RooRandomizeParamMCSModule::UniParam ; #pragma link C++ class RooRandomizeParamMCSModule::GausParam ; diff --git a/roofit/roofitcore/inc/RooFitResult.h b/roofit/roofitcore/inc/RooFitResult.h index bdbf853d7886f..9866229bade2c 100644 --- a/roofit/roofitcore/inc/RooFitResult.h +++ b/roofit/roofitcore/inc/RooFitResult.h @@ -55,12 +55,12 @@ class RooFitResult : public TNamed, public RooPrintable, public RooDirItem { static RooFitResult* lastMinuitFit(const RooArgList& varList=RooArgList()) ; // Printing interface (human readable) - virtual void printValue(ostream& os) const ; - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printArgs(ostream& os) const ; - void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printValue(std::ostream& os) const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printArgs(std::ostream& os) const ; + void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; inline virtual void Print(Option_t *options= 0) const { // Printing interface @@ -79,8 +79,8 @@ class RooFitResult : public TNamed, public RooPrintable, public RooDirItem { } inline UInt_t numStatusHistory() const { return _statusHistory.size() ; } - Int_t statusCodeHistory(UInt_t icycle) ; - const char* statusLabelHistory(UInt_t icycle) ; + Int_t statusCodeHistory(UInt_t icycle) const ; + const char* statusLabelHistory(UInt_t icycle) const ; inline Int_t covQual() const { // Return MINUIT quality code of covariance matrix @@ -159,7 +159,6 @@ class RooFitResult : public TNamed, public RooPrintable, public RooDirItem { friend class RooMinuit ; friend class RooMinimizer ; - friend class RooNag ; void setCovarianceMatrix(TMatrixDSym& V) ; void setConstParList(const RooArgList& list) ; void setInitParList(const RooArgList& list) ; diff --git a/roofit/roofitcore/inc/RooFormula.h b/roofit/roofitcore/inc/RooFormula.h index 9f3efd4ffaedb..4ba41f9c6b5de 100644 --- a/roofit/roofitcore/inc/RooFormula.h +++ b/roofit/roofitcore/inc/RooFormula.h @@ -55,12 +55,12 @@ class RooFormula : public TFormula, public RooPrintable { Bool_t reCompile(const char* newFormula) ; - virtual void printValue(ostream& os) const ; - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printArgs(ostream& os) const ; - void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printValue(std::ostream& os) const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printArgs(std::ostream& os) const ; + void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; inline virtual void Print(Option_t *options= 0) const { // Printing interface (human readable) diff --git a/roofit/roofitcore/inc/RooFormulaVar.h b/roofit/roofitcore/inc/RooFormulaVar.h index b719e0e26f433..275fddbc5870b 100644 --- a/roofit/roofitcore/inc/RooFormulaVar.h +++ b/roofit/roofitcore/inc/RooFormulaVar.h @@ -45,12 +45,12 @@ class RooFormulaVar : public RooAbsReal { } // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; // Printing interface (human readable) - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent= "") const ; - void printMetaArgs(ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent= "") const ; + void printMetaArgs(std::ostream& os) const ; // Debugging void dumpFormula() { formula().dump() ; } diff --git a/roofit/roofitcore/inc/RooGenCategory.h b/roofit/roofitcore/inc/RooGenCategory.h index 9173eedb5ac88..cc71f3ba63a64 100644 --- a/roofit/roofitcore/inc/RooGenCategory.h +++ b/roofit/roofitcore/inc/RooGenCategory.h @@ -38,11 +38,11 @@ class RooGenCategory : public RooAbsCategory { virtual ~RooGenCategory(); // Printing interface (human readable) - virtual void printMultiline(ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent= "") const ; + virtual void printMultiline(std::ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent= "") const ; // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; protected: diff --git a/roofit/roofitcore/inc/RooGenContext.h b/roofit/roofitcore/inc/RooGenContext.h index f6518ca1dcf4e..11f7dc77df170 100644 --- a/roofit/roofitcore/inc/RooGenContext.h +++ b/roofit/roofitcore/inc/RooGenContext.h @@ -33,7 +33,7 @@ class RooGenContext : public RooAbsGenContext { const RooArgSet* auxProto=0, Bool_t verbose=kFALSE, const RooArgSet* forceDirect=0); virtual ~RooGenContext(); - virtual void printMultiline(ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; virtual void attach(const RooArgSet& params) ; diff --git a/roofit/roofitcore/inc/RooGenericPdf.h b/roofit/roofitcore/inc/RooGenericPdf.h index b3b7c8d950672..24bc10e512b92 100644 --- a/roofit/roofitcore/inc/RooGenericPdf.h +++ b/roofit/roofitcore/inc/RooGenericPdf.h @@ -33,12 +33,12 @@ class RooGenericPdf : public RooAbsPdf { virtual ~RooGenericPdf(); // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; // Printing interface (human readable) - void printMultiline(ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; - void printMetaArgs(ostream& os) const ; + void printMultiline(std::ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + void printMetaArgs(std::ostream& os) const ; // Debugging void dumpFormula() { formula().dump() ; } diff --git a/roofit/roofitcore/inc/RooGlobalFunc.h b/roofit/roofitcore/inc/RooGlobalFunc.h index 5ba1e45ec54c4..092015831f558 100644 --- a/roofit/roofitcore/inc/RooGlobalFunc.h +++ b/roofit/roofitcore/inc/RooGlobalFunc.h @@ -57,6 +57,7 @@ enum MsgLevel { DEBUG=0, INFO=1, PROGRESS=2, WARNING=3, ERROR=4, FATAL=5 } ; enum MsgTopic { Generation=1, Minimization=2, Plotting=4, Fitting=8, Integration=16, LinkStateMgmt=32, Eval=64, Caching=128, Optimization=256, ObjectHandling=512, InputArguments=1024, Tracing=2048, Contents=4096, DataHandling=8192, NumIntegration=16384 } ; +enum MPSplit { BulkPartition=0, Interleave=1, SimComponents=2, Hybrid=3 } ; // RooAbsReal::plotOn arguments RooCmdArg DrawOption(const char* opt) ; @@ -116,11 +117,11 @@ RooCmdArg Import(const char* state, TH1& histo) ; RooCmdArg Import(const std::map<std::string,TH1*>&) ; RooCmdArg Import(const char* state, RooDataHist& dhist) ; RooCmdArg Import(const std::map<std::string,RooDataHist*>&) ; -RooCmdArg Import(TH1& histo, Bool_t importDensity=kTRUE) ; +RooCmdArg Import(TH1& histo, Bool_t importDensity=kFALSE) ; // RooDataSet::ctor arguments -RooCmdArg WeightVar(const char* name) ; -RooCmdArg WeightVar(const RooRealVar& arg) ; +RooCmdArg WeightVar(const char* name, Bool_t reinterpretAsWeight=kFALSE) ; +RooCmdArg WeightVar(const RooRealVar& arg, Bool_t reinterpretAsWeight=kFALSE) ; RooCmdArg Import(const char* state, RooDataSet& data) ; RooCmdArg Import(const std::map<std::string,RooDataSet*>& ) ; RooCmdArg Link(const char* state, RooAbsData& data) ; @@ -135,7 +136,7 @@ RooCmdArg OwnLinked() ; // RooChi2Var::ctor arguments RooCmdArg Extended(Bool_t flag=kTRUE) ; RooCmdArg DataError(Int_t) ; -RooCmdArg NumCPU(Int_t nCPU, Bool_t interleave=kFALSE) ; +RooCmdArg NumCPU(Int_t nCPU, Int_t interleave=0) ; // RooAbsPdf::printLatex arguments RooCmdArg Columns(Int_t ncol) ; @@ -183,6 +184,7 @@ RooCmdArg SplitRange(Bool_t flag=kTRUE) ; RooCmdArg SumCoefRange(const char* rangeName) ; RooCmdArg Constrain(const RooArgSet& params) ; RooCmdArg GlobalObservables(const RooArgSet& globs) ; +RooCmdArg GlobalObservablesTag(const char* tagName) ; RooCmdArg Constrained() ; RooCmdArg ExternalConstraints(const RooArgSet& constraintPdfs) ; RooCmdArg PrintEvalErrors(Int_t numErrors) ; @@ -191,6 +193,7 @@ RooCmdArg SumW2Error(Bool_t flag) ; RooCmdArg CloneData(Bool_t flag) ; RooCmdArg Integrate(Bool_t flag) ; RooCmdArg Minimizer(const char* type, const char* alg=0) ; +RooCmdArg Offset(Bool_t flag=kTRUE) ; // RooAbsPdf::paramOn arguments RooCmdArg Label(const char* str) ; @@ -220,6 +223,10 @@ RooCmdArg ZVar(const RooAbsRealLValue& var, const RooCmdArg& arg=RooCmdArg::none RooCmdArg AxisLabel(const char* name) ; RooCmdArg Scaling(Bool_t flag) ; + +// RooAbsReal::createHistogram arguments +RooCmdArg IntrinsicBinning(Bool_t flag=kTRUE) ; + // RooAbsReal::createIntegral arguments RooCmdArg NormSet(const RooArgSet& nset) ; RooCmdArg NumIntConfig(const RooNumIntConfig& cfg) ; @@ -254,19 +261,20 @@ RooCmdArg ObjectName(const char* name) ; RooCmdArg ClassName(const char* name) ; RooCmdArg BaseClassName(const char* name) ; RooCmdArg TagName(const char* name) ; -RooCmdArg OutputStream(ostream& os) ; +RooCmdArg OutputStream(std::ostream& os) ; RooCmdArg Prefix(Bool_t flag) ; RooCmdArg Color(Color_t color) ; - // RooWorkspace::import() arguments -RooCmdArg RenameConflictNodes(const char* suffix) ; +RooCmdArg RenameConflictNodes(const char* suffix, Bool_t renameOrigNodes=kFALSE) ; RooCmdArg RenameAllNodes(const char* suffix) ; RooCmdArg RenameAllVariables(const char* suffix) ; RooCmdArg RenameAllVariablesExcept(const char* suffix,const char* exceptionList) ; RooCmdArg RenameVariable(const char* inputName, const char* outputName) ; RooCmdArg Rename(const char* suffix) ; RooCmdArg RecycleConflictNodes(Bool_t flag=kTRUE) ; +RooCmdArg Embedded(Bool_t flag=kTRUE) ; +RooCmdArg NoRecursion(Bool_t flag=kTRUE) ; // RooSimCloneTool::build() arguments RooCmdArg SplitParam(const char* varname, const char* catname) ; @@ -282,6 +290,12 @@ RooCmdArg ScanNumCdf() ; RooCmdArg ScanAllCdf() ; RooCmdArg ScanNoCdf() ; +// Generic container arguments (to be able to supply more command line arguments) +RooCmdArg MultiArg(const RooCmdArg& arg1, const RooCmdArg& arg2, + const RooCmdArg& arg3=RooCmdArg::none(),const RooCmdArg& arg4=RooCmdArg::none(), + const RooCmdArg& arg5=RooCmdArg::none(),const RooCmdArg& arg6=RooCmdArg::none(), + const RooCmdArg& arg7=RooCmdArg::none(),const RooCmdArg& arg8=RooCmdArg::none()) ; + RooConstVar& RooConst(Double_t val) ; diff --git a/roofit/roofitcore/inc/RooGrid.h b/roofit/roofitcore/inc/RooGrid.h index 1f984337f0104..09c6375981bd0 100644 --- a/roofit/roofitcore/inc/RooGrid.h +++ b/roofit/roofitcore/inc/RooGrid.h @@ -28,10 +28,10 @@ class RooGrid : public TObject, public RooPrintable { virtual ~RooGrid(); // Printing interface - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const; inline virtual void Print(Option_t *options= 0) const { printStream(defaultPrintStream(),defaultPrintContents(options),defaultPrintStyle(options)); diff --git a/roofit/roofitcore/inc/RooHist.h b/roofit/roofitcore/inc/RooHist.h index d7d0b6a1cb489..8a9ead548be04 100644 --- a/roofit/roofitcore/inc/RooHist.h +++ b/roofit/roofitcore/inc/RooHist.h @@ -53,10 +53,10 @@ class RooHist : public TGraphAsymmErrors, public RooPlotable { // add a datapoint for the efficiency (n1)/(n1+n2), using a sum-of-weights error void addEfficiencyBinWithError(Axis_t binCenter, Double_t n1, Double_t n2, Double_t en1, Double_t en2, Double_t binWidth= 0, Double_t xErrorFrac=1.0, Double_t scaleFactor=1.0); - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent= "") const; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent= "") const; inline virtual void Print(Option_t *options= 0) const { // Printing interface diff --git a/roofit/roofitcore/inc/RooHistFunc.h b/roofit/roofitcore/inc/RooHistFunc.h index 375de59e52fb3..94dc046879cc5 100644 --- a/roofit/roofitcore/inc/RooHistFunc.h +++ b/roofit/roofitcore/inc/RooHistFunc.h @@ -74,6 +74,9 @@ class RooHistFunc : public RooAbsReal { protected: + Bool_t importWorkspaceHook(RooWorkspace& ws) ; + Bool_t areIdentical(const RooDataHist& dh1, const RooDataHist& dh2) ; + Double_t evaluate() const; Double_t totalVolume() const ; friend class RooAbsCachedReal ; diff --git a/roofit/roofitcore/inc/RooHistPdf.h b/roofit/roofitcore/inc/RooHistPdf.h index 5c26934e034ae..182213fce132f 100644 --- a/roofit/roofitcore/inc/RooHistPdf.h +++ b/roofit/roofitcore/inc/RooHistPdf.h @@ -85,6 +85,8 @@ class RooHistPdf : public RooAbsPdf { protected: + Bool_t areIdentical(const RooDataHist& dh1, const RooDataHist& dh2) ; + Bool_t importWorkspaceHook(RooWorkspace& ws) ; Double_t evaluate() const; diff --git a/roofit/roofitcore/inc/RooLinearVar.h b/roofit/roofitcore/inc/RooLinearVar.h index c032ed9933874..bd8c9c7162818 100644 --- a/roofit/roofitcore/inc/RooLinearVar.h +++ b/roofit/roofitcore/inc/RooLinearVar.h @@ -43,13 +43,14 @@ class RooLinearVar : public RooAbsRealLValue { virtual Bool_t hasBinning(const char* name) const ; virtual const RooAbsBinning& getBinning(const char* name=0, Bool_t verbose=kTRUE, Bool_t createOnTheFly=kFALSE) const ; virtual RooAbsBinning& getBinning(const char* name=0, Bool_t verbose=kTRUE, Bool_t createOnTheFly=kFALSE) ; + virtual std::list<std::string> getBinningNames() const; virtual Double_t jacobian() const ; virtual Bool_t isJacobianOK(const RooArgSet& depList) const ; // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; // Printing interface (human readable) diff --git a/roofit/roofitcore/inc/RooLinkedList.h b/roofit/roofitcore/inc/RooLinkedList.h index 9a15818f75e0e..8152e68a05202 100644 --- a/roofit/roofitcore/inc/RooLinkedList.h +++ b/roofit/roofitcore/inc/RooLinkedList.h @@ -16,15 +16,22 @@ #ifndef ROO_LINKED_LIST #define ROO_LINKED_LIST +#include <map> +#include <list> + #include "TNamed.h" #include "RooLinkedListElem.h" #include "RooHashTable.h" -#include <list> class RooLinkedListIter ; class RooFIter ; class TIterator ; class RooAbsArg ; +namespace RooLinkedListImplDetails { + class Chunk; + class Pool; +} + class RooLinkedList : public TObject { public: // Constructor @@ -77,6 +84,7 @@ class RooLinkedList : public TObject { const char* GetName() const { return _name.Data() ; } void SetName(const char* name) { _name = name ; } + void useNptr(Bool_t flag) { _useNptr = flag ; } protected: @@ -89,8 +97,6 @@ class RooLinkedList : public TObject { virtual void Add(TObject* arg, Int_t refCount) ; - void swapWithNext(RooLinkedListElem* elem) ; - RooLinkedListElem* findLink(const TObject* arg) const ; Int_t _hashThresh ; // Size threshold for hashing @@ -100,14 +106,19 @@ class RooLinkedList : public TObject { RooHashTable* _htableName ; //! Hash table by name RooHashTable* _htableLink ; //! Hash table by link pointer - Int_t _curStoreSize ; //! - Int_t _curStoreUsed ; //! - std::list<std::pair<Int_t,RooLinkedListElem*> > _storeList ; //! - RooLinkedListElem* _curStore ; //! - TString _name ; - - ClassDef(RooLinkedList,2) // Doubly linked list for storage of RooAbsArg objects + Bool_t _useNptr ; //! + +private: + template <bool ascending> + static RooLinkedListElem* mergesort_impl(RooLinkedListElem* l1, + const unsigned sz, RooLinkedListElem** tail = 0); + /// memory pool for quick allocation of RooLinkedListElems + typedef RooLinkedListImplDetails::Pool Pool; + /// shared memory pool for allocation of RooLinkedListElems + static Pool* _pool; //! + + ClassDef(RooLinkedList,3) // Doubly linked list for storage of RooAbsArg objects }; diff --git a/roofit/roofitcore/inc/RooLinkedListElem.h b/roofit/roofitcore/inc/RooLinkedListElem.h index ec5788d1428bb..6ff92b50ec0e1 100644 --- a/roofit/roofitcore/inc/RooLinkedListElem.h +++ b/roofit/roofitcore/inc/RooLinkedListElem.h @@ -22,14 +22,19 @@ class TObject ; class RooLinkedListElem ; class TBuffer ; +namespace RooLinkedListImplDetails { + class Chunk; + class Pool; +} + class RooLinkedListElem { public: // Initial element ctor RooLinkedListElem() : - _prev(0), _next(0), _arg(0), _refCount(0), _suc(0) { + _prev(0), _next(0), _arg(0), _refCount(0) { } - void init(TObject* arg, RooLinkedListElem* after=0, Int_t* suc=0) { + void init(TObject* arg, RooLinkedListElem* after=0) { _arg = arg ; _refCount = 1 ; @@ -41,8 +46,6 @@ class RooLinkedListElem { _next->_prev = this ; } } - _suc = suc ; - (*_suc)++ ; } void release() { @@ -50,17 +53,16 @@ class RooLinkedListElem { if (_next) _next->_prev = _prev ; _prev = 0 ; _next = 0 ; - (*_suc)-- ; } RooLinkedListElem(TObject* arg) : // Constructor with payload - _prev(0), _next(0), _arg(arg), _refCount(1), _suc(0) { + _prev(0), _next(0), _arg(arg), _refCount(1) { } RooLinkedListElem(TObject* arg, RooLinkedListElem* after) : // Constructor with payload and next chain element - _prev(after), _next(after->_next), _arg(arg), _refCount(1), _suc(0) { + _prev(after), _next(after->_next), _arg(arg), _refCount(1) { // Insert self in link after->_next = this ; @@ -81,20 +83,21 @@ class RooLinkedListElem { protected: friend class RooHashTable ; friend class RooLinkedList ; + friend class RooLinkedListImplDetails::Pool; + friend class RooLinkedListImplDetails::Chunk; friend class RooLinkedListIter ; friend class RooFIter ; RooLinkedListElem* _prev ; // Link to previous element in list RooLinkedListElem* _next ; // Link to next element in list TObject* _arg ; // Link to contents Int_t _refCount ; //! Reference count - Int_t* _suc ; //! Store use count protected: // Forbidden RooLinkedListElem(const RooLinkedListElem&) ; - ClassDef(RooLinkedListElem,0) // Element of RooLinkedList container class + ClassDef(RooLinkedListElem,1) // Element of RooLinkedList container class } ; diff --git a/roofit/roofitcore/inc/RooLinkedListIter.h b/roofit/roofitcore/inc/RooLinkedListIter.h index 8a5057718c1ef..58b98ee7fd69c 100644 --- a/roofit/roofitcore/inc/RooLinkedListIter.h +++ b/roofit/roofitcore/inc/RooLinkedListIter.h @@ -55,19 +55,13 @@ class RooLinkedListIter : public TIterator { RooLinkedListIter(const RooLinkedList* list, Bool_t forward) : - TIterator(), _forward(forward), _list(list) - { - // Constructor from list with direction - _ptr = _list->_first ; - _cptr = _ptr; - } + TIterator(), _list(list), _ptr(forward ? _list->_first : _list->_last), + _forward(forward) + { } RooLinkedListIter(const RooLinkedListIter& other) : - TIterator(other), - _forward(other._forward), - _cptr(other._cptr), - _ptr(other._ptr), - _list(other._list) + TIterator(other), _list(other._list), _ptr(other._ptr), + _forward(other._forward) { // Copy constructor } @@ -83,7 +77,6 @@ class RooLinkedListIter : public TIterator { if (iter) { _list = iter->_list ; _ptr = iter->_ptr ; - _cptr = iter->_cptr; _forward = iter->_forward ; } return *this ; @@ -97,7 +90,6 @@ class RooLinkedListIter : public TIterator { virtual TObject *Next() { // Return next element in collection if (!_ptr) return 0 ; - _cptr = _ptr; TObject* arg = _ptr->_arg ; _ptr = _forward ? _ptr->_next : _ptr->_prev ; return arg ; @@ -106,7 +98,6 @@ class RooLinkedListIter : public TIterator { TObject *NextNV() { // Return next element in collection if (!_ptr) return 0 ; - _cptr = _ptr; TObject* arg = _ptr->_arg ; _ptr = _forward ? _ptr->_next : _ptr->_prev ; return arg ; @@ -116,38 +107,31 @@ class RooLinkedListIter : public TIterator { virtual void Reset() { // Return iterator to first element in collection _ptr = _forward ? _list->_first : _list->_last ; - _cptr = _ptr; } bool operator!=(const TIterator &aIter) const { - if (nullptr == &aIter) - return _cptr; - if ((aIter.IsA() == RooLinkedListIter::Class())) { - const RooLinkedListIter &iter(dynamic_cast<const RooLinkedListIter &>(aIter)); - return (_cptr != iter._cptr); - } + if (nullptr == &aIter) return _ptr; + const RooLinkedListIter *iter(dynamic_cast<const RooLinkedListIter*>(&aIter)); + if (iter) return (_ptr != iter->_ptr); return false; // for base class we don't implement a comparison } bool operator!=(const RooLinkedListIter &aIter) const { - if (nullptr == (&aIter)) - return _cptr; - - return (_cptr != aIter._cptr); + if (nullptr == (&aIter)) return _ptr; + return (_ptr != aIter._ptr); } virtual TObject *operator*() const { // Return element iterator points to - return (_cptr ? _cptr->_arg : nullptr); + return (_ptr ? _ptr->_arg : nullptr); } protected: - Bool_t _forward ; // Iterator direction - const RooLinkedListElem* _cptr ; //! Current link element - const RooLinkedListElem* _ptr ; //! Next link element const RooLinkedList* _list ; //! Collection iterated over + const RooLinkedListElem* _ptr ; //! Next link element + Bool_t _forward ; // Iterator direction - ClassDef(RooLinkedListIter,1) // Iterator for RooLinkedList container class + ClassDef(RooLinkedListIter,2) // Iterator for RooLinkedList container class } ; diff --git a/roofit/roofitcore/inc/RooListProxy.h b/roofit/roofitcore/inc/RooListProxy.h index b8f918f7dbe03..f47a4955c5d64 100644 --- a/roofit/roofitcore/inc/RooListProxy.h +++ b/roofit/roofitcore/inc/RooListProxy.h @@ -47,7 +47,7 @@ class RooListProxy : public RooArgList, public RooAbsProxy { RooListProxy& operator=(const RooArgList& other) ; - virtual void print(ostream& os, Bool_t addContents=kFALSE) const ; + virtual void print(std::ostream& os, Bool_t addContents=kFALSE) const ; protected: diff --git a/roofit/roofitcore/inc/RooMappedCategory.h b/roofit/roofitcore/inc/RooMappedCategory.h index ad1cdc2341725..4343706ce3c6d 100644 --- a/roofit/roofitcore/inc/RooMappedCategory.h +++ b/roofit/roofitcore/inc/RooMappedCategory.h @@ -38,12 +38,12 @@ class RooMappedCategory : public RooAbsCategory { Bool_t map(const char* inKeyRegExp, const char* outKeyName, Int_t outKeyNum=NoCatIdx) ; // Printing interface (human readable) - void printMultiline(ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; - void printMetaArgs(ostream& os) const ; + void printMultiline(std::ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + void printMetaArgs(std::ostream& os) const ; // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; class Entry { diff --git a/roofit/roofitcore/inc/RooMath.h b/roofit/roofitcore/inc/RooMath.h index acbff60b223ae..1d07608aeae0d 100644 --- a/roofit/roofitcore/inc/RooMath.h +++ b/roofit/roofitcore/inc/RooMath.h @@ -16,79 +16,220 @@ #ifndef ROO_MATH #define ROO_MATH +#include <cmath> +#include <complex> + +#include "Rtypes.h" +#include "TMath.h" #include "RooComplex.h" -#include <math.h> -#include <fstream> +#if defined(__my_func__) +#undef __my_func__ +#endif +#if defined(WIN32) +#define __my_func__ __FUNCTION__ +#else +#define __my_func__ __func__ +#endif -typedef RooComplex* pRooComplex ; -typedef Double_t* pDouble_t ; +typedef Double_t* pDouble_t; class RooMath { public: - virtual ~RooMath() {} ; - - // CERNLIB complex error function - static RooComplex ComplexErrFunc(Double_t re, Double_t im= 0); - static RooComplex ComplexErrFunc(const RooComplex& z); - - // Interpolated CERF with automatic interpolation order selection - static RooComplex FastComplexErrFunc(const RooComplex& z) ; - - // Interpolated Re(CERF) with automatic interpolation order selection - static Double_t FastComplexErrFuncRe(const RooComplex& z) ; - - // Interpolated Im(CERF) with automatic interpolation order selection - static Double_t FastComplexErrFuncIm(const RooComplex& z) ; - - // Interpolated complex error function at specified interpolation order - static RooComplex ITPComplexErrFunc(const RooComplex& z, Int_t nOrder) ; - static Double_t ITPComplexErrFuncRe(const RooComplex& z, Int_t nOrder) ; - static Double_t ITPComplexErrFuncIm(const RooComplex& z, Int_t nOrder) ; - - // Switch to use file cache for CERF lookup table - static void cacheCERF(Bool_t flag=kTRUE) ; + virtual ~RooMath() {}; + + /** @brief evaluate Faddeeva function for complex argument + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-02-21 + * + * Calculate the value of the Faddeeva function @f$w(z) = \exp(-z^2) + * \mathrm{erfc}(-i z)@f$. + * + * The method described in + * + * S.M. Abrarov, B.M. Quine: "Efficient algotithmic implementation of + * Voigt/complex error function based on exponential series approximation" + * published in Applied Mathematics and Computation 218 (2011) 1894-1902 + * doi:10.1016/j.amc.2011.06.072 + * + * is used. At the heart of the method (equation (14) of the paper) is the + * following Fourier series based approximation: + * + * @f[ w(z) \approx \frac{i}{2\sqrt{\pi}}\left( + * \sum^N_{n=0} a_n \tau_m\left( + * \frac{1-e^{i(n\pi+\tau_m z)}}{n\pi + \tau_m z} - + * \frac{1-e^{i(-n\pi+\tau_m z)}}{n\pi - \tau_m z} + * \right) - a_0 \frac{1-e^{i \tau_m z}}{z} + * \right) @f] + * + * The coefficients @f$a_b@f$ are given by: + * + * @f[ a_n=\frac{2\sqrt{\pi}}{\tau_m} + * \exp\left(-\frac{n^2\pi^2}{\tau_m^2}\right) @f] + * + * To achieve machine accuracy in double precision floating point arithmetic + * for most of the upper half of the complex plane, chose @f$t_m=12@f$ and + * @f$N=23@f$ as is done in the paper. + * + * There are two complications: For Im(z) negative, the exponent in the + * equation above becomes so large that the roundoff in the rest of the + * calculation is amplified enough that the result cannot be trusted. + * Therefore, for Im(z) < 0, the symmetry of the erfc function under the + * transformation z --> -z is used to avoid accuracy issues for Im(z) < 0 by + * formulating the problem such that the calculation can be done for Im(z) > 0 + * where the accuracy of the method is fine, and some postprocessing then + * yields the desired final result. + * + * Second, the denominators in the equation above become singular at + * @f$z = n * pi / 12@f$ (for 0 <= n < 24). In a tiny disc around these + * points, Taylor expansions are used to overcome that difficulty. + * + * This routine precomputes everything it can, and tries to write out complex + * operations to minimise subroutine calls, e.g. for the multiplication of + * complex numbers. + * + * In the square -8 <= Re(z) <= 8, -8 <= Im(z) <= 8, the routine is accurate + * to better than 4e-13 relative, the average relative error is better than + * 7e-16. On a modern x86_64 machine, the routine is roughly three times as + * fast than the old CERNLIB implementation and offers better accuracy. + * + * For large @f$|z|@f$, the familiar continued fraction approximation + * + * @f[ w(z)=\frac{-iz/\sqrt{\pi}}{-z^2+\frac{1/2}{1+\frac{2/2}{-z^2 + + * \frac{3/2}{1+\frac{4/2}{-z^2+\frac{5/2}{1+\frac{6/2}{-z^2+\frac{7/2 + * }{1+\frac{8/2}{-z^2+\frac{9/2}{1+\ldots}}}}}}}}}} @f] + * + * is used, truncated at the ellipsis ("...") in the formula; for @f$|z| > + * 12@f$, @f$Im(z)>0@f$ it will give full double precision at a smaller + * computational cost than the method described above. (For @f$|z|>12@f$, + * @f$Im(z)<0@f$, the symmetry property @f$w(x-iy)=2e^{-(x+iy)^2-w(x+iy)}@f$ + * is used. + */ + static std::complex<double> faddeeva(std::complex<double> z); + /** @brief evaluate Faddeeva function for complex argument (fast version) + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-02-21 + * + * Calculate the value of the Faddeeva function @f$w(z) = \exp(-z^2) + * \mathrm{erfc}(-i z)@f$. + * + * This is the "fast" version of the faddeeva routine above. Fast means that + * is takes roughly half the amount of CPU of the slow version of the + * routine, but is a little less accurate. + * + * To be fast, chose @f$t_m=8@f$ and @f$N=11@f$ which should give accuracies + * around 1e-7. + * + * In the square -8 <= Re(z) <= 8, -8 <= Im(z) <= 8, the routine is accurate + * to better than 4e-7 relative, the average relative error is better than + * 5e-9. On a modern x86_64 machine, the routine is roughly five times as + * fast than the old CERNLIB implementation, or about 30% faster than the + * interpolation/lookup table based fast method used previously in RooFit, + * and offers better accuracy than the latter (the relative error is roughly + * a factor 280 smaller than the old interpolation/table lookup routine). + * + * For large @f$|z|@f$, the familiar continued fraction approximation + * + * @f[ w(z)=\frac{-iz/\sqrt{\pi}}{-z^2+\frac{1/2}{1+\frac{2/2}{-z^2 + + * \frac{3/2}{1+\ldots}}}} @f] + * + * is used, truncated at the ellipsis ("...") in the formula; for @f$|z| > + * 8@f$, @f$Im(z)>0@f$ it will give full float precision at a smaller + * computational cost than the method described above. (For @f$|z|>8@f$, + * @f$Im(z)<0@f$, the symmetry property @f$w(x-iy)=2e^{-(x+iy)^2-w(x+iy)}@f$ + * is used. + */ + static std::complex<double> faddeeva_fast(std::complex<double> z); + + /** @brief complex erf function + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-02-21 + * + * Calculate erf(z) for complex z. + */ + static std::complex<double> erf(const std::complex<double> z); + + /** @brief complex erf function (fast version) + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-02-21 + * + * Calculate erf(z) for complex z. Use the code in faddeeva_fast to save some time. + */ + static std::complex<double> erf_fast(const std::complex<double> z); + /** @brief complex erfc function + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-02-21 + * + * Calculate erfc(z) for complex z. + */ + static std::complex<double> erfc(const std::complex<double> z); + /** @brief complex erfc function (fast version) + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-02-21 + * + * Calculate erfc(z) for complex z. Use the code in faddeeva_fast to save some time. + */ + static std::complex<double> erfc_fast(const std::complex<double> z); // 1-D nth order polynomial interpolation routines static Double_t interpolate(Double_t yArr[],Int_t nOrder, Double_t x) ; static Double_t interpolate(Double_t xa[], Double_t ya[], Int_t n, Double_t x) ; - static Double_t erf(Double_t x) ; - static Double_t erfc(Double_t x) ; - - static void cleanup() ; - - // Allocate and initialize CERF lookup grid - static void initFastCERF(Int_t reBins= 800, Double_t reMin=-4.0, Double_t reMax=4.0, - Int_t imBins=1000, Double_t imMin=-4.0, Double_t imMax=6.0) ; + static inline Double_t erf(Double_t x) + { return TMath::Erf(x); } + static inline Double_t erfc(Double_t x) + { return TMath::Erfc(x); } + + /// deprecated function + static RooComplex ComplexErrFunc(Double_t re, Double_t im = 0.) + { warn(__my_func__, "RooMath::faddeeva"); std::complex<Double_t> z = faddeeva(std::complex<Double_t>(re, im)); return RooComplex(z.real(), z.imag()); } + /// deprecated function + static RooComplex ComplexErrFunc(const RooComplex& zz) + { warn(__my_func__, "RooMath::faddeeva"); std::complex<Double_t> z = faddeeva(std::complex<Double_t>(zz.re(), zz.im())); return RooComplex(z.real(), z.imag()); } + /// deprecated function + static RooComplex ComplexErrFuncFast(const RooComplex& zz) + { warn(__my_func__, "RooMath::faddeeva_fast"); std::complex<Double_t> z = faddeeva_fast(std::complex<Double_t>(zz.re(), zz.im())); return RooComplex(z.real(), z.imag()); } + /// deprecated function + static Double_t ComplexErrFuncFastRe(const RooComplex& zz) + { warn(__my_func__, "RooMath::faddeeva_fast"); std::complex<Double_t> z = faddeeva_fast(std::complex<Double_t>(zz.re(), zz.im())); return z.real(); } + /// deprecated function + static Double_t ComplexErrFuncFastIm(const RooComplex& zz) + { warn(__my_func__, "RooMath::faddeeva_fast"); std::complex<Double_t> z = faddeeva_fast(std::complex<Double_t>(zz.re(), zz.im())); return z.imag(); } + /// deprecated function + static RooComplex ITPComplexErrFuncFast(const RooComplex& zz, Int_t) + { warn(__my_func__, "RooMath::faddeeva_fast"); std::complex<Double_t> z = faddeeva_fast(std::complex<Double_t>(zz.re(), zz.im())); return RooComplex(z.real(), z.imag()); } + /// deprecated function + static Double_t ITPComplexErrFuncFastRe(const RooComplex& zz, Int_t) + { warn(__my_func__, "RooMath::faddeeva_fast"); std::complex<Double_t> z = faddeeva_fast(std::complex<Double_t>(zz.re(), zz.im())); return z.real(); } + /// deprecated function + static Double_t ITPComplexErrFuncFastIm(const RooComplex& zz, Int_t) + { warn(__my_func__, "RooMath::faddeeva_fast"); std::complex<Double_t> z = faddeeva_fast(std::complex<Double_t>(zz.re(), zz.im())); return z.imag(); } + /// deprecated function + static void cacheCERF(Bool_t) { warn(__my_func__); } + /// deprecated function + static void cleanup() { warn(__my_func__); } + /// deprecated function + static void initFastCERF(Int_t /*reBins = 800*/, Double_t /*reMin = -4.0*/, Double_t /*reMax = 4.0*/, + Int_t /*imBins = 1000*/, Double_t /*imMin = -4.0*/, Double_t /*imMax = 6.0*/) + { + warn(__my_func__); + } + private: + // deprecation warnings + static void warn(const char* oldfun, const char* newfun = 0); - static Bool_t loadCache() ; - static void storeCache() ; - static const char* cacheFileName() ; - - // CERF lookup grid - static pDouble_t* _imCerfArray ; // Lookup table for Im part of complex error function - static pDouble_t* _reCerfArray ; // Lookup table for Re part of complex error function - - // CERF grid dimensions and parameters - static Int_t _reBins ; // Number of grid points in real dimension of CERF-LUT - static Double_t _reMin ; // Low edge of real dimension of CERF-LUT - static Double_t _reMax ; // High edge of real dimension of CERF-LUT - static Double_t _reRange ; // Range in real dimension of CERF-LUT - static Double_t _reStep ; // Grid spacing in real dimension of CERF-LUT - - static Int_t _imBins ; // Number of grid points in imaginary dimension of CERF-LUT - static Double_t _imMin ; // Low edge of imaginary dimension of CERF-LUT - static Double_t _imMax ; // High edge of imaginary dimension of CERF-LUT - static Double_t _imRange ; // Range in imaginary dimension of CERF-LUT - static Double_t _imStep ; // Grid spacing in imaginary dimension of CERF-LUT - - static Bool_t _cacheTable ; // Switch activating use of file cache for CERF-LUT - ClassDef(RooMath,0) // math utility routines }; +#undef __my_func__ + #endif diff --git a/roofit/roofitcore/inc/RooMinimizer.h b/roofit/roofitcore/inc/RooMinimizer.h index 5dd382e09093b..83bb97fd302b2 100644 --- a/roofit/roofitcore/inc/RooMinimizer.h +++ b/roofit/roofitcore/inc/RooMinimizer.h @@ -47,7 +47,10 @@ class RooMinimizer : public TObject { void setErrorLevel(Double_t level) ; void setEps(Double_t eps) ; void optimizeConst(Int_t flag) ; - void setEvalErrorWall(Bool_t flag) { _fcn->SetEvalErrorWall(flag); } + void setEvalErrorWall(Bool_t flag) { fitterFcn()->SetEvalErrorWall(flag); } + void setOffsetting(Bool_t flag) ; + void setMaxIterations(Int_t n) ; + void setMaxFunctionCalls(Int_t n) ; RooFitResult* fit(const char* options) ; @@ -67,10 +70,10 @@ class RooMinimizer : public TObject { Double_t n4=0, Double_t n5=0, Double_t n6=0) ; Int_t setPrintLevel(Int_t newLevel) ; - void setPrintEvalErrors(Int_t numEvalErrors) { _fcn->SetPrintEvalErrors(numEvalErrors); } - void setVerbose(Bool_t flag=kTRUE) { _verbose = flag ; _fcn->SetVerbose(flag); } + void setPrintEvalErrors(Int_t numEvalErrors) { fitterFcn()->SetPrintEvalErrors(numEvalErrors); } + void setVerbose(Bool_t flag=kTRUE) { _verbose = flag ; fitterFcn()->SetVerbose(flag); } void setProfile(Bool_t flag=kTRUE) { _profile = flag ; } - Bool_t setLogFile(const char* logf=0) { return _fcn->SetLogFile(logf); } + Bool_t setLogFile(const char* logf=0) { return fitterFcn()->SetLogFile(logf); } void setMinimizerType(const char* type) ; @@ -78,6 +81,12 @@ class RooMinimizer : public TObject { static RooFitResult* lastMinuitFit(const RooArgList& varList=RooArgList()) ; void saveStatus(const char* label, Int_t status) { _statusHistory.push_back(std::pair<std::string,int>(label,status)) ; } + + Int_t evalCounter() const { return fitterFcn()->evalCounter() ; } + void zeroEvalCount() { fitterFcn()->zeroEvalCount() ; } + + ROOT::Fit::Fitter* fitter() ; + const ROOT::Fit::Fitter* fitter() const ; protected: @@ -87,9 +96,12 @@ class RooMinimizer : public TObject { void profileStart() ; void profileStop() ; - inline Int_t getNPar() const { return _fcn->NDim() ; } - inline ofstream* logfile() const { return _fcn->GetLogFile(); } - inline Double_t& maxFCN() { return _fcn->GetMaxFCN() ; } + inline Int_t getNPar() const { return fitterFcn()->NDim() ; } + inline std::ofstream* logfile() { return fitterFcn()->GetLogFile(); } + inline Double_t& maxFCN() { return fitterFcn()->GetMaxFCN() ; } + + const RooMinimizerFcn* fitterFcn() const { return ( fitter()->GetFCN() ? ((RooMinimizerFcn*) fitter()->GetFCN()) : _fcn ) ; } + RooMinimizerFcn* fitterFcn() { return ( fitter()->GetFCN() ? ((RooMinimizerFcn*) fitter()->GetFCN()) : _fcn ) ; } private: @@ -102,6 +114,7 @@ class RooMinimizer : public TObject { Bool_t _verbose ; TStopwatch _timer ; TStopwatch _cumulTimer ; + Bool_t _profileStart ; TMatrixDSym* _extV ; diff --git a/roofit/roofitcore/inc/RooMinimizerFcn.h b/roofit/roofitcore/inc/RooMinimizerFcn.h index 60c1e06ebc75e..effa8d30ded95 100644 --- a/roofit/roofitcore/inc/RooMinimizerFcn.h +++ b/roofit/roofitcore/inc/RooMinimizerFcn.h @@ -36,6 +36,7 @@ class RooMinimizerFcn : public ROOT::Math::IBaseFunctionMultiDim { RooMinimizerFcn(RooAbsReal *funct, RooMinimizer *context, bool verbose = false); + RooMinimizerFcn(const RooMinimizerFcn& other); virtual ~RooMinimizerFcn(); virtual ROOT::Math::IBaseFunctionMultiDim* Clone() const; @@ -49,7 +50,7 @@ class RooMinimizerFcn : public ROOT::Math::IBaseFunctionMultiDim { void SetEvalErrorWall(Bool_t flag) { _doEvalErrorWall = flag ; } void SetPrintEvalErrors(Int_t numEvalErrors) { _printEvalErrors = numEvalErrors ; } Bool_t SetLogFile(const char* inLogfile); - ofstream* GetLogFile() { return _logfile; } + std::ofstream* GetLogFile() { return _logfile; } void SetVerbose(Bool_t flag=kTRUE) { _verbose = flag ; } Double_t& GetMaxFCN() { return _maxFCN; } @@ -60,6 +61,10 @@ class RooMinimizerFcn : public ROOT::Math::IBaseFunctionMultiDim { void BackProp(const ROOT::Fit::FitResult &results); void ApplyCovarianceMatrix(TMatrixDSym& V); + Int_t evalCounter() const { return _evalCounter ; } + void zeroEvalCount() { _evalCounter = 0 ; } + + private: Double_t GetPdfParamVal(Int_t index); @@ -72,8 +77,11 @@ class RooMinimizerFcn : public ROOT::Math::IBaseFunctionMultiDim { virtual double DoEval(const double * x) const; + void updateFloatVec() ; private: + + mutable Int_t _evalCounter ; RooAbsReal *_funct; RooMinimizer *_context; @@ -84,10 +92,11 @@ class RooMinimizerFcn : public ROOT::Math::IBaseFunctionMultiDim { Bool_t _doEvalErrorWall; int _nDim; - ofstream *_logfile; + std::ofstream *_logfile; bool _verbose; RooArgList* _floatParamList; + std::vector<RooAbsArg*> _floatParamVec ; RooArgList* _constParamList; RooArgList* _initFloatParamList; RooArgList* _initConstParamList; diff --git a/roofit/roofitcore/inc/RooMinuit.h b/roofit/roofitcore/inc/RooMinuit.h index 22b0b83cde432..296b126c9dae4 100644 --- a/roofit/roofitcore/inc/RooMinuit.h +++ b/roofit/roofitcore/inc/RooMinuit.h @@ -49,6 +49,7 @@ class RooMinuit : public TObject { void setEps(Double_t eps) ; void optimizeConst(Int_t flag) ; void setEvalErrorWall(Bool_t flag) { _doEvalErrorWall = flag ; } + void setOffsetting(Bool_t flag) ; RooFitResult* fit(const char* options) ; @@ -93,7 +94,7 @@ class RooMinuit : public TObject { void backProp() ; inline Int_t getNPar() const { return _nPar ; } - inline ofstream* logfile() const { return _logfile ; } + inline std::ofstream* logfile() const { return _logfile ; } inline Double_t& maxFCN() { return _maxFCN ; } Double_t getPdfParamVal(Int_t index) ; @@ -129,7 +130,7 @@ class RooMinuit : public TObject { RooAbsReal* _func ; Double_t _maxFCN ; - ofstream* _logfile ; + std::ofstream* _logfile ; Bool_t _verbose ; TStopwatch _timer ; TStopwatch _cumulTimer ; diff --git a/roofit/roofitcore/inc/RooMsgService.h b/roofit/roofitcore/inc/RooMsgService.h index 66da1aae5db11..6ed6bee4f68c9 100644 --- a/roofit/roofitcore/inc/RooMsgService.h +++ b/roofit/roofitcore/inc/RooMsgService.h @@ -136,7 +136,7 @@ class RooMsgService : public TObject { Color_t color ; Bool_t prefix ; - ostream* os ; + std::ostream* os ; } ; @@ -163,8 +163,8 @@ class RooMsgService : public TObject { void showPid(Bool_t flag) { _showPid = flag ; } // Back end -- Send message or check if particular logging configuration is active - ostream& log(const RooAbsArg* self, RooFit::MsgLevel level, RooFit::MsgTopic facility, Bool_t forceSkipPrefix=kFALSE) ; - ostream& log(const TObject* self, RooFit::MsgLevel level, RooFit::MsgTopic facility, Bool_t forceSkipPrefix=kFALSE) ; + std::ostream& log(const RooAbsArg* self, RooFit::MsgLevel level, RooFit::MsgTopic facility, Bool_t forceSkipPrefix=kFALSE) ; + std::ostream& log(const TObject* self, RooFit::MsgLevel level, RooFit::MsgTopic facility, Bool_t forceSkipPrefix=kFALSE) ; Bool_t isActive(const RooAbsArg* self, RooFit::MsgTopic facility, RooFit::MsgLevel level) ; Bool_t isActive(const TObject* self, RooFit::MsgTopic facility, RooFit::MsgLevel level) ; diff --git a/roofit/roofitcore/inc/RooMultiCategory.h b/roofit/roofitcore/inc/RooMultiCategory.h index ba7a4855bc013..f0b53e84c48aa 100644 --- a/roofit/roofitcore/inc/RooMultiCategory.h +++ b/roofit/roofitcore/inc/RooMultiCategory.h @@ -33,11 +33,11 @@ class RooMultiCategory : public RooAbsCategory { virtual ~RooMultiCategory(); // Printing interface (human readable) - virtual void printMultiline(ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; const RooArgSet& inputCatList() const { return _catSet ; } diff --git a/roofit/roofitcore/inc/RooMultiVarGaussian.h b/roofit/roofitcore/inc/RooMultiVarGaussian.h index 0f34f43819cf2..1a56192339853 100644 --- a/roofit/roofitcore/inc/RooMultiVarGaussian.h +++ b/roofit/roofitcore/inc/RooMultiVarGaussian.h @@ -32,8 +32,8 @@ class RooMultiVarGaussian : public RooAbsPdf { public: RooMultiVarGaussian() {} ; - RooMultiVarGaussian(const char *name, const char *title, const RooArgList& xvec, const RooFitResult& fr, Bool_t reduceToConditional=kTRUE) ; RooMultiVarGaussian(const char *name, const char *title, const RooArgList& xvec, const RooArgList& mu, const TMatrixDSym& covMatrix) ; + RooMultiVarGaussian(const char *name, const char *title, const RooArgList& xvec, const RooFitResult& fr, Bool_t reduceToConditional=kTRUE) ; RooMultiVarGaussian(const char *name, const char *title, const RooArgList& xvec, const TVectorD& mu, const TMatrixDSym& covMatrix) ; RooMultiVarGaussian(const char *name, const char *title, const RooArgList& xvec,const TMatrixDSym& covMatrix) ; void setAnaIntZ(Double_t z) { _z = z ; } @@ -55,15 +55,15 @@ class RooMultiVarGaussian : public RooAbsPdf { public: TMatrixD S22bar ; Double_t S22det ; - vector<int> pmap ; + std::vector<int> pmap ; Int_t nint ; } ; class GenData { public: TMatrixD UT ; - vector<int> omap ; - vector<int> pmap ; + std::vector<int> omap ; + std::vector<int> pmap ; TVectorD mu1 ; TVectorD mu2 ; TMatrixD S12S22I ; @@ -83,11 +83,11 @@ class RooMultiVarGaussian : public RooAbsPdf { Int_t b3 ; } ; - static void blockDecompose(const TMatrixD& input, const vector<int>& map1, const vector<int>& map2, TMatrixDSym& S11, TMatrixD& S12, TMatrixD& S21, TMatrixDSym& S22) ; + static void blockDecompose(const TMatrixD& input, const std::vector<int>& map1, const std::vector<int>& map2, TMatrixDSym& S11, TMatrixD& S12, TMatrixD& S21, TMatrixDSym& S22) ; protected: - void decodeCode(Int_t code, vector<int>& map1, vector<int>& map2) const; + void decodeCode(Int_t code, std::vector<int>& map1, std::vector<int>& map2) const; AnaIntData& anaIntData(Int_t code) const ; GenData& genData(Int_t code) const ; diff --git a/roofit/roofitcore/inc/RooNLLVar.h b/roofit/roofitcore/inc/RooNLLVar.h index c7ffa9793801f..5ac6a6574556f 100644 --- a/roofit/roofitcore/inc/RooNLLVar.h +++ b/roofit/roofitcore/inc/RooNLLVar.h @@ -19,6 +19,9 @@ #include "RooAbsOptTestStatistic.h" #include "RooCmdArg.h" #include "RooAbsPdf.h" +#include <vector> + +class RooRealSumPdf ; class RooNLLVar : public RooAbsOptTestStatistic { public: @@ -26,25 +29,27 @@ class RooNLLVar : public RooAbsOptTestStatistic { // Constructors, assignment etc RooNLLVar() { _first = kTRUE ; } RooNLLVar(const char *name, const char* title, RooAbsPdf& pdf, RooAbsData& data, - const RooCmdArg& arg1 , const RooCmdArg& arg2=RooCmdArg::none(),const RooCmdArg& arg3=RooCmdArg::none(), + const RooCmdArg& arg1=RooCmdArg::none(), const RooCmdArg& arg2=RooCmdArg::none(),const RooCmdArg& arg3=RooCmdArg::none(), const RooCmdArg& arg4=RooCmdArg::none(), const RooCmdArg& arg5=RooCmdArg::none(),const RooCmdArg& arg6=RooCmdArg::none(), const RooCmdArg& arg7=RooCmdArg::none(), const RooCmdArg& arg8=RooCmdArg::none(),const RooCmdArg& arg9=RooCmdArg::none()) ; RooNLLVar(const char *name, const char *title, RooAbsPdf& pdf, RooAbsData& data, - Bool_t extended=kFALSE, const char* rangeName=0, const char* addCoefRangeName=0, - Int_t nCPU=1, Bool_t interleave=kFALSE, Bool_t verbose=kTRUE, Bool_t splitRange=kFALSE, Bool_t cloneData=kTRUE) ; - + Bool_t extended, const char* rangeName=0, const char* addCoefRangeName=0, + Int_t nCPU=1, RooFit::MPSplit interleave=RooFit::BulkPartition, Bool_t verbose=kTRUE, Bool_t splitRange=kFALSE, + Bool_t cloneData=kTRUE, Bool_t binnedL=kFALSE) ; + RooNLLVar(const char *name, const char *title, RooAbsPdf& pdf, RooAbsData& data, const RooArgSet& projDeps, Bool_t extended=kFALSE, const char* rangeName=0, - const char* addCoefRangeName=0, Int_t nCPU=1, Bool_t interleave=kFALSE, Bool_t verbose=kTRUE, Bool_t splitRange=kFALSE, Bool_t cloneData=kTRUE) ; + const char* addCoefRangeName=0, Int_t nCPU=1, RooFit::MPSplit interleave=RooFit::BulkPartition, Bool_t verbose=kTRUE, Bool_t splitRange=kFALSE, + Bool_t cloneData=kTRUE, Bool_t binnedL=kFALSE) ; RooNLLVar(const RooNLLVar& other, const char* name=0); virtual TObject* clone(const char* newname) const { return new RooNLLVar(*this,newname); } virtual RooAbsTestStatistic* create(const char *name, const char *title, RooAbsReal& pdf, RooAbsData& adata, const RooArgSet& projDeps, const char* rangeName, const char* addCoefRangeName=0, - Int_t nCPU=1, Bool_t interleave=kFALSE, Bool_t verbose=kTRUE, Bool_t splitRange=kFALSE) { - return new RooNLLVar(name,title,(RooAbsPdf&)pdf,adata,projDeps,_extended,rangeName, addCoefRangeName, nCPU, interleave,verbose,splitRange,kFALSE) ; + Int_t nCPU=1, RooFit::MPSplit interleave=RooFit::BulkPartition, Bool_t verbose=kTRUE, Bool_t splitRange=kFALSE, Bool_t binnedL=kFALSE) { + return new RooNLLVar(name,title,(RooAbsPdf&)pdf,adata,projDeps,_extended,rangeName, addCoefRangeName, nCPU, interleave,verbose,splitRange,kFALSE,binnedL) ; } virtual ~RooNLLVar(); @@ -63,8 +68,14 @@ class RooNLLVar : public RooAbsOptTestStatistic { virtual Double_t evaluatePartition(Int_t firstEvent, Int_t lastEvent, Int_t stepSize) const ; Bool_t _weightSq ; // Apply weights squared? mutable Bool_t _first ; //! - - ClassDef(RooNLLVar,1) // Function representing (extended) -log(L) of p.d.f and dataset + Double_t _offsetSaveW2; //! + Double_t _offsetCarrySaveW2; //! + + mutable std::vector<Double_t> _binw ; //! + mutable RooRealSumPdf* _binnedPdf ; //! + + ClassDef(RooNLLVar,2) // Function representing (extended) -log(L) of p.d.f and dataset }; #endif + diff --git a/roofit/roofitcore/inc/RooNameSet.h b/roofit/roofitcore/inc/RooNameSet.h index 30c13c3057870..a28edc349503c 100644 --- a/roofit/roofitcore/inc/RooNameSet.h +++ b/roofit/roofitcore/inc/RooNameSet.h @@ -17,7 +17,7 @@ #define ROO_NAME_SET #include "TString.h" -#include "RooAbsArg.h" +#include "TObject.h" #include "RooPrintable.h" class RooArgSet ; @@ -33,26 +33,30 @@ class RooNameSet : public TObject, public RooPrintable { void refill(const RooArgSet& argSet) ; RooArgSet* select(const RooArgSet& list) const ; - Bool_t operator==(const RooNameSet& other) ; + Bool_t operator==(const RooNameSet& other) const; RooNameSet& operator=(const RooNameSet&) ; + Bool_t operator<(const RooNameSet& other) const ; - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printValue(ostream& os) const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printValue(std::ostream& os) const ; inline virtual void Print(Option_t *options= 0) const { printStream(defaultPrintStream(),defaultPrintContents(options),defaultPrintStyle(options)); } void setNameList(const char* givenList) ; + const char* content() const { return _nameList ? _nameList : ""; } +private: Int_t _len ; char* _nameList ; //[_len] protected: void extendBuffer(Int_t inc) ; + static void strdup(Int_t& dstlen, char* &dstbuf, const char* str); ClassDef(RooNameSet,1) // A sterile version of RooArgSet, containing only the names of the contained RooAbsArgs }; diff --git a/roofit/roofitcore/inc/RooNormSetCache.h b/roofit/roofitcore/inc/RooNormSetCache.h index 60054d647899f..1bb98a85dec3b 100644 --- a/roofit/roofitcore/inc/RooNormSetCache.h +++ b/roofit/roofitcore/inc/RooNormSetCache.h @@ -31,7 +31,7 @@ typedef RooArgSet* pRooArgSet ; class RooNormSetCache { public: - RooNormSetCache(Int_t regSize=64) ; + RooNormSetCache(Int_t regSize=32) ; RooNormSetCache(const RooNormSetCache& other) ; virtual ~RooNormSetCache() ; diff --git a/roofit/roofitcore/inc/RooNumConvPdf.h b/roofit/roofitcore/inc/RooNumConvPdf.h index 69a5364c95f34..e279cfa2f5dce 100644 --- a/roofit/roofitcore/inc/RooNumConvPdf.h +++ b/roofit/roofitcore/inc/RooNumConvPdf.h @@ -53,7 +53,7 @@ class RooNumConvPdf : public RooAbsPdf { RooAbsReal& pdf() const { return const_cast<RooAbsReal&>(_origPdf.arg()) ; } RooAbsReal& model() const { return const_cast<RooAbsReal&>(_origModel.arg()) ; } - void printMetaArgs(ostream& os) const ; + void printMetaArgs(std::ostream& os) const ; protected: diff --git a/roofit/roofitcore/inc/RooNumConvolution.h b/roofit/roofitcore/inc/RooNumConvolution.h index 3bb2b36721ded..37fe497b152ea 100644 --- a/roofit/roofitcore/inc/RooNumConvolution.h +++ b/roofit/roofitcore/inc/RooNumConvolution.h @@ -64,7 +64,7 @@ class RooNumConvolution : public RooAbsReal { void initialize() const ; Bool_t redirectServersHook(const RooAbsCollection& newServerList, Bool_t mustReplaceAll, Bool_t nameChange, Bool_t isRecursive) ; - virtual void printCompactTreeHook(ostream& os, const char* indent="") ; + virtual void printCompactTreeHook(std::ostream& os, const char* indent="") ; RooNumIntConfig _convIntConfig ; // Configuration of numeric convolution integral ; mutable RooConvIntegrandBinding* _integrand ; //! Binding of Convolution Integrand function diff --git a/roofit/roofitcore/inc/RooNumGenConfig.h b/roofit/roofitcore/inc/RooNumGenConfig.h index 64a1834c56fbb..8beb8975da3b8 100644 --- a/roofit/roofitcore/inc/RooNumGenConfig.h +++ b/roofit/roofitcore/inc/RooNumGenConfig.h @@ -45,7 +45,7 @@ class RooNumGenConfig : public TObject, public RooPrintable { const RooArgSet& getConfigSection(const char* name) const ; RooArgSet& getConfigSection(const char* name) ; - void printMultiline(ostream &os, Int_t content, Bool_t verbose, TString indent= "") const; + void printMultiline(std::ostream &os, Int_t content, Bool_t verbose, TString indent= "") const; inline virtual void Print(Option_t *options= 0) const { printStream(defaultPrintStream(),defaultPrintContents(options),defaultPrintStyle(options)); diff --git a/roofit/roofitcore/inc/RooNumIntConfig.h b/roofit/roofitcore/inc/RooNumIntConfig.h index ab5bc98a95406..1da3baa35a9c3 100644 --- a/roofit/roofitcore/inc/RooNumIntConfig.h +++ b/roofit/roofitcore/inc/RooNumIntConfig.h @@ -63,7 +63,7 @@ class RooNumIntConfig : public TObject, public RooPrintable { const RooArgSet& getConfigSection(const char* name) const ; RooArgSet& getConfigSection(const char* name) ; - void printMultiline(ostream &os, Int_t content, Bool_t verbose, TString indent= "") const; + void printMultiline(std::ostream &os, Int_t content, Bool_t verbose, TString indent= "") const; virtual StyleOption defaultPrintStyle(Option_t* opt) const ; inline virtual void Print(Option_t *options= 0) const { diff --git a/roofit/roofitcore/inc/RooParamBinning.h b/roofit/roofitcore/inc/RooParamBinning.h index 55415ca297151..49cbe6ecd293e 100644 --- a/roofit/roofitcore/inc/RooParamBinning.h +++ b/roofit/roofitcore/inc/RooParamBinning.h @@ -47,7 +47,7 @@ class RooParamBinning : public RooAbsBinning { virtual Double_t averageBinWidth() const { return _binw ; } virtual Double_t* array() const ; - void printMultiline(ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + void printMultiline(std::ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; virtual void insertHook(RooAbsRealLValue&) const ; virtual void removeHook(RooAbsRealLValue&) const ; diff --git a/roofit/roofitcore/inc/RooPlot.h b/roofit/roofitcore/inc/RooPlot.h index 355ee5ae9d018..30b28fec3d5fe 100644 --- a/roofit/roofitcore/inc/RooPlot.h +++ b/roofit/roofitcore/inc/RooPlot.h @@ -115,12 +115,12 @@ class RooPlot : public TNamed, public RooPrintable { void remove(const char* name=0, Bool_t deleteToo=kTRUE) ; // ascii printing - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printArgs(ostream& os) const ; - virtual void printValue(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printArgs(std::ostream& os) const ; + virtual void printValue(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; virtual Int_t defaultPrintContents(Option_t* opt) const ; @@ -172,6 +172,9 @@ class RooPlot : public TNamed, public RooPrintable { void Browse(TBrowser *b) ; + static Bool_t addDirectoryStatus() ; + static Bool_t setAddDirectoryStatus(Bool_t flag) ; + protected: RooPlot(const RooPlot& other); // cannot be copied @@ -214,6 +217,8 @@ class RooPlot : public TNamed, public RooPrintable { TDirectory* _dir ; //! non-persistent + static Bool_t _addDirStatus ; // static flag controlling AutoDirectoryAdd feature + ClassDef(RooPlot,2) // Plot frame and container for graphics objects }; diff --git a/roofit/roofitcore/inc/RooPlotable.h b/roofit/roofitcore/inc/RooPlotable.h index 3bb0547cc1847..d2789c8a9b81d 100644 --- a/roofit/roofitcore/inc/RooPlotable.h +++ b/roofit/roofitcore/inc/RooPlotable.h @@ -47,7 +47,7 @@ class RooPlotable : public RooPrintable { virtual Double_t getFitRangeNEvt(Double_t xlo, Double_t xhi) const = 0; virtual Double_t getFitRangeBinW() const = 0; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent= "") const; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent= "") const; TObject *crossCast(); protected: diff --git a/roofit/roofitcore/inc/RooPrintable.h b/roofit/roofitcore/inc/RooPrintable.h index 2158d9cd70123..89123d73739a8 100644 --- a/roofit/roofitcore/inc/RooPrintable.h +++ b/roofit/roofitcore/inc/RooPrintable.h @@ -33,20 +33,20 @@ class RooPrintable { // Master print function enum ContentsOption { kName=1, kClassName=2, kValue=4, kArgs=8, kExtras=16, kAddress=32, kTitle=64, kCollectionHeader=128} ; // Can be ORed enum StyleOption { kInline=1, kSingleLine=2, kStandard=3, kVerbose=4, kTreeStructure=5 } ; // Exclusive - virtual void printStream(ostream& os, Int_t contents, StyleOption style, TString indent="") const ; + virtual void printStream(std::ostream& os, Int_t contents, StyleOption style, TString indent="") const ; // Virtual hook function for class-specific content implementation - virtual void printAddress(ostream& os) const ; - virtual void printName(ostream& os) const ; - virtual void printTitle(ostream& os) const ; - virtual void printClassName(ostream& os) const ; - virtual void printValue(ostream& os) const ; - virtual void printArgs(ostream& os) const ; - virtual void printExtras(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; - virtual void printTree(ostream& os, TString indent="") const ; + virtual void printAddress(std::ostream& os) const ; + virtual void printName(std::ostream& os) const ; + virtual void printTitle(std::ostream& os) const ; + virtual void printClassName(std::ostream& os) const ; + virtual void printValue(std::ostream& os) const ; + virtual void printArgs(std::ostream& os) const ; + virtual void printExtras(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printTree(std::ostream& os, TString indent="") const ; - static ostream& defaultPrintStream(ostream *os= 0); + static std::ostream& defaultPrintStream(std::ostream *os= 0); virtual Int_t defaultPrintContents(Option_t* opt) const ; virtual StyleOption defaultPrintStyle(Option_t* opt) const ; @@ -63,7 +63,7 @@ class RooPrintable { }; namespace RooFit { -ostream& operator<<(ostream& os, const RooPrintable& rp) ; +std::ostream& operator<<(std::ostream& os, const RooPrintable& rp) ; } #ifndef __CINT__ diff --git a/roofit/roofitcore/inc/RooProdGenContext.h b/roofit/roofitcore/inc/RooProdGenContext.h index cebee68aa6c7d..846a8306d7bb1 100644 --- a/roofit/roofitcore/inc/RooProdGenContext.h +++ b/roofit/roofitcore/inc/RooProdGenContext.h @@ -35,7 +35,7 @@ class RooProdGenContext : public RooAbsGenContext { virtual ~RooProdGenContext(); virtual void setProtoDataOrder(Int_t* lut) ; - virtual void printMultiline(ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; virtual void attach(const RooArgSet& params) ; diff --git a/roofit/roofitcore/inc/RooProdPdf.h b/roofit/roofitcore/inc/RooProdPdf.h index b08091f4d2884..03f20bae13b12 100644 --- a/roofit/roofitcore/inc/RooProdPdf.h +++ b/roofit/roofitcore/inc/RooProdPdf.h @@ -81,7 +81,7 @@ class RooProdPdf : public RooAbsPdf { virtual std::list<Double_t>* binBoundaries(RooAbsRealLValue& /*obs*/, Double_t /*xlo*/, Double_t /*xhi*/) const ; Bool_t isBinnedDistribution(const RooArgSet& obs) const ; - void printMetaArgs(ostream& os) const ; + void printMetaArgs(std::ostream& os) const ; virtual void selectNormalizationRange(const char* rangeName=0, Bool_t force=kFALSE) ; void fixRefRange(const char* rangeName) ; @@ -93,6 +93,8 @@ class RooProdPdf : public RooAbsPdf { Bool_t redirectServersHook(const RooAbsCollection& /*newServerList*/, Bool_t /*mustReplaceAll*/, Bool_t /*nameChange*/, Bool_t /*isRecursive*/) ; RooArgSet* getConnectedParameters(const RooArgSet& observables) const ; + + RooArgSet* findPdfNSet(RooAbsPdf& pdf) const ; protected: @@ -155,7 +157,6 @@ class RooProdPdf : public RooAbsPdf { virtual RooAbsGenContext* genContext(const RooArgSet &vars, const RooDataSet *prototype=0, const RooArgSet *auxProto=0, Bool_t verbose= kFALSE) const ; - RooArgSet* findPdfNSet(RooAbsPdf& pdf) const ; mutable RooAICRegistry _genCode ; //! Registry of composite direct generator codes diff --git a/roofit/roofitcore/inc/RooProduct.h b/roofit/roofitcore/inc/RooProduct.h index bfab51fda6cee..2510acca3b176 100644 --- a/roofit/roofitcore/inc/RooProduct.h +++ b/roofit/roofitcore/inc/RooProduct.h @@ -17,7 +17,7 @@ #define ROO_PRODUCT #include "RooAbsReal.h" -#include "RooSetProxy.h" +#include "RooListProxy.h" #include "RooCacheManager.h" #include "RooObjCacheManager.h" @@ -33,7 +33,7 @@ class RooProduct : public RooAbsReal { public: RooProduct() ; - RooProduct(const char *name, const char *title, const RooArgSet& _prodSet) ; + RooProduct(const char *name, const char *title, const RooArgList& _prodSet) ; RooProduct(const RooProduct& other, const char* name = 0); virtual TObject* clone(const char* newname) const { return new RooProduct(*this, newname); } @@ -50,7 +50,7 @@ class RooProduct : public RooAbsReal { class ProdMap ; - void printMetaArgs(ostream& os) const ; + void printMetaArgs(std::ostream& os) const ; virtual std::list<Double_t>* binBoundaries(RooAbsRealLValue& /*obs*/, Double_t /*xlo*/, Double_t /*xhi*/) const ; virtual std::list<Double_t>* plotSamplingHint(RooAbsRealLValue& /*obs*/, Double_t /*xlo*/, Double_t /*xhi*/) const ; @@ -58,8 +58,8 @@ class RooProduct : public RooAbsReal { protected: - RooSetProxy _compRSet ; - RooSetProxy _compCSet ; + RooListProxy _compRSet ; + RooListProxy _compCSet ; TIterator* _compRIter ; //! do not persist TIterator* _compCIter ; //! do not persist @@ -83,7 +83,7 @@ class RooProduct : public RooAbsReal { - ClassDef(RooProduct,1) // Product of RooAbsReal and/or RooAbsCategory terms + ClassDef(RooProduct,2) // Product of RooAbsReal and/or RooAbsCategory terms }; #endif diff --git a/roofit/roofitcore/inc/RooProfileLL.h b/roofit/roofitcore/inc/RooProfileLL.h index c2323efd15ab0..6970c0700f70c 100644 --- a/roofit/roofitcore/inc/RooProfileLL.h +++ b/roofit/roofitcore/inc/RooProfileLL.h @@ -18,8 +18,11 @@ #include <map> #include <string> -class RooMinuit ; - +class RooMinimizer ; +class RooMinuit ; + +#define MINIMIZER RooMinimizer + class RooProfileLL : public RooAbsReal { public: @@ -32,7 +35,7 @@ class RooProfileLL : public RooAbsReal { void setAlwaysStartFromMin(Bool_t flag) { _startFromMin = flag ; } Bool_t alwaysStartFromMin() const { return _startFromMin ; } - RooMinuit* minuit() { return _minuit ; } + MINIMIZER* minimizer() { return _minimizer ; } RooAbsReal& nll() { return const_cast<RooAbsReal&>(_nll.arg()) ; } const RooArgSet& bestFitParams() const ; const RooArgSet& bestFitObs() const ; @@ -49,6 +52,7 @@ class RooProfileLL : public RooAbsReal { protected: void validateAbsMin() const ; + void initializeMinimizer() const ; RooRealProxy _nll ; // Input -log(L) function RooSetProxy _obs ; // Parameters of profile likelihood @@ -58,7 +62,7 @@ class RooProfileLL : public RooAbsReal { TIterator* _piter ; //! Iterator over profile likelihood parameters to be minimized TIterator* _oiter ; //! Iterator of profile likelihood output parameter(s) - mutable RooMinuit* _minuit ; //! Internal minuit instance + mutable MINIMIZER* _minimizer ; //! Internal minuit instance mutable Bool_t _absMinValid ; // flag if absmin is up-to-date mutable Double_t _absMin ; // absolute minimum of -log(L) diff --git a/roofit/roofitcore/inc/RooProjectedPdf.h b/roofit/roofitcore/inc/RooProjectedPdf.h index 5fc72a745cdbf..ef4bbee6b79b8 100644 --- a/roofit/roofitcore/inc/RooProjectedPdf.h +++ b/roofit/roofitcore/inc/RooProjectedPdf.h @@ -43,7 +43,7 @@ class RooProjectedPdf : public RooAbsPdf { // Handle projection of projection explicitly virtual RooAbsPdf* createProjection(const RooArgSet& iset) ; - void printMetaArgs(ostream& os) const ; + void printMetaArgs(std::ostream& os) const ; protected: diff --git a/roofit/roofitcore/inc/RooRandom.h b/roofit/roofitcore/inc/RooRandom.h index 7d1e5589d70aa..1fa4a852fa678 100644 --- a/roofit/roofitcore/inc/RooRandom.h +++ b/roofit/roofitcore/inc/RooRandom.h @@ -27,6 +27,7 @@ class RooRandom { virtual ~RooRandom() {} ; static TRandom *randomGenerator(); + static void setRandomGenerator(TRandom* gen); static Double_t uniform(TRandom *generator= randomGenerator()); static void uniform(UInt_t dimension, Double_t vector[], TRandom *generator= randomGenerator()); static UInt_t integer(UInt_t max, TRandom *generator= randomGenerator()); @@ -38,6 +39,15 @@ class RooRandom { private: RooRandom(); + + static TRandom* _theGenerator; // random number generator + static RooQuasiRandomGenerator* _theQuasiGenerator; // quasi random number sequence generator + + // free resources when library is unloaded + struct Guard { ~Guard(); }; + static struct Guard guard; + friend struct RooRandom::Guard; + ClassDef(RooRandom,0) // Random number generator interface }; diff --git a/roofit/roofitcore/inc/RooRealBinding.h b/roofit/roofitcore/inc/RooRealBinding.h index c35f761389a9d..58a6315f77bc6 100644 --- a/roofit/roofitcore/inc/RooRealBinding.h +++ b/roofit/roofitcore/inc/RooRealBinding.h @@ -17,6 +17,7 @@ #define ROO_REAL_BINDING #include "RooAbsFunc.h" +#include <list> class RooAbsRealLValue; class RooAbsReal; @@ -50,7 +51,11 @@ class RooRealBinding : public RooAbsFunc { Bool_t _clipInvalid ; mutable Double_t* _xsave ; const TNamed* _rangeName ; //! - + + mutable std::list<RooAbsReal*> _compList ; //! + mutable std::list<Double_t> _compSave ; //! + mutable Double_t _funcSave ; //! + ClassDef(RooRealBinding,0) // Function binding to RooAbsReal object }; diff --git a/roofit/roofitcore/inc/RooRealIntegral.h b/roofit/roofitcore/inc/RooRealIntegral.h index 25ede672bc1be..2f42a71de4b32 100644 --- a/roofit/roofitcore/inc/RooRealIntegral.h +++ b/roofit/roofitcore/inc/RooRealIntegral.h @@ -45,8 +45,8 @@ class RooRealIntegral : public RooAbsReal { Bool_t isValid() const { return _valid; } - void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; - void printMetaArgs(ostream& os) const ; + void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + void printMetaArgs(std::ostream& os) const ; const RooArgSet& numIntCatVars() const { return _sumList ; } const RooArgSet& numIntRealVars() const { return _intList ; } diff --git a/roofit/roofitcore/inc/RooRealMPFE.h b/roofit/roofitcore/inc/RooRealMPFE.h index 0399c91e28640..e8035995c5ab9 100644 --- a/roofit/roofitcore/inc/RooRealMPFE.h +++ b/roofit/roofitcore/inc/RooRealMPFE.h @@ -21,8 +21,11 @@ #include "RooListProxy.h" #include "RooArgList.h" #include "RooMPSentinel.h" +#include "TStopwatch.h" +#include <vector> class RooArgSet ; +namespace RooFit { class BidirMMapPipe; } class RooRealMPFE : public RooAbsReal { public: @@ -40,18 +43,23 @@ class RooRealMPFE : public RooAbsReal { void applyNLLWeightSquared(Bool_t flag) ; + void enableOffsetting(Bool_t flag) ; + + void followAsSlave(RooRealMPFE& master) { _updateMaster = &master ; } + protected: // Function evaluation virtual Double_t evaluate() const ; friend class RooAbsTestStatistic ; virtual void constOptimizeTestStatistic(ConstOpCode opcode, Bool_t doAlsoTracking=kTRUE) ; + virtual Double_t getCarry() const; enum State { Initialize,Client,Server,Inline } ; State _state ; - enum Message { SendReal=0, SendCat=1, Calculate=2, Retrieve=3, ReturnValue=4, Terminate=5, - ConstOpt=6, Verbose=7, RetrieveErrors=8, SendError=9, LogEvalError=10, ApplyNLLW2=11 } ; + enum Message { SendReal=0, SendCat, Calculate, Retrieve, ReturnValue, Terminate, + ConstOpt, Verbose, LogEvalError, ApplyNLLW2, EnableOffset, CalculateNoOffset } ; void initialize() ; void initVars() ; @@ -60,7 +68,6 @@ class RooRealMPFE : public RooAbsReal { void doApplyNLLW2(Bool_t flag) ; RooRealProxy _arg ; // Function to calculate in parallel process - RooListProxy _vars ; // Variables RooArgList _saveVars ; // Copy of variables mutable Bool_t _calcInProgress ; @@ -69,14 +76,18 @@ class RooRealMPFE : public RooAbsReal { Bool_t _inlineMode ; mutable Bool_t _forceCalc ; mutable RooAbsReal::ErrorLoggingMode _remoteEvalErrorLoggingState ; - Int_t _pid ; // PID of child process - Int_t _pipeToClient[2] ; // Pipe to client process - Int_t _pipeToServer[2] ; // Pipe to server process + RooFit::BidirMMapPipe *_pipe; //! connection to child + + mutable std::vector<Bool_t> _valueChanged ; //! Flags if variable needs update on server-side + mutable std::vector<Bool_t> _constChanged ; //! Flags if variable needs update on server-side + RooRealMPFE* _updateMaster ; //! Update master + mutable Bool_t _retrieveDispatched ; //! + mutable Double_t _evalCarry; //! static RooMPSentinel _sentinel ; - ClassDef(RooRealMPFE,1) // Multi-process front-end for parallel calculation of a real valued function + ClassDef(RooRealMPFE,2) // Multi-process front-end for parallel calculation of a real valued function }; #endif diff --git a/roofit/roofitcore/inc/RooRealSumPdf.h b/roofit/roofitcore/inc/RooRealSumPdf.h index 71fe3a8f6117b..8a0a2e81a3490 100644 --- a/roofit/roofitcore/inc/RooRealSumPdf.h +++ b/roofit/roofitcore/inc/RooRealSumPdf.h @@ -52,13 +52,19 @@ class RooRealSumPdf : public RooAbsPdf { return expectedEvents(&nset) ; } - void printMetaArgs(ostream& os) const ; + virtual Bool_t selfNormalized() const { return getAttribute("BinnedLikelihoodActive") ; } + + void printMetaArgs(std::ostream& os) const ; virtual std::list<Double_t>* binBoundaries(RooAbsRealLValue& /*obs*/, Double_t /*xlo*/, Double_t /*xhi*/) const ; virtual std::list<Double_t>* plotSamplingHint(RooAbsRealLValue& /*obs*/, Double_t /*xlo*/, Double_t /*xhi*/) const ; Bool_t isBinnedDistribution(const RooArgSet& obs) const ; + void setFloor(Bool_t flag) { _doFloor = flag ; } + Bool_t getFloor() const { return _doFloor ; } + static void setFloorGlobal(Bool_t flag) { _doFloorGlobal = flag ; } + static Bool_t getFloorGlobal() { return _doFloorGlobal ; } protected: @@ -80,10 +86,13 @@ class RooRealSumPdf : public RooAbsPdf { TIterator* _funcIter ; //! Iterator over FUNC list TIterator* _coefIter ; //! Iterator over coefficient list Bool_t _extended ; // Allow use as extended p.d.f. + + Bool_t _doFloor ; // Introduce floor at zero in pdf + static Bool_t _doFloorGlobal ; // Global flag for introducing floor at zero in pdf private: - ClassDef(RooRealSumPdf,2) // PDF constructed from a sum of (non-pdf) functions + ClassDef(RooRealSumPdf,3) // PDF constructed from a sum of (non-pdf) functions }; #endif diff --git a/roofit/roofitcore/inc/RooRealVar.h b/roofit/roofitcore/inc/RooRealVar.h index 780eb7aa02367..a6e9b6df082c9 100644 --- a/roofit/roofitcore/inc/RooRealVar.h +++ b/roofit/roofitcore/inc/RooRealVar.h @@ -16,6 +16,8 @@ #ifndef ROO_REAL_VAR #define ROO_REAL_VAR +#include <list> +#include <string> #include "Riosfwd.h" #include <math.h> #include <float.h> @@ -30,6 +32,7 @@ class RooArgSet ; class RooErrorVar ; class RooVectorDataStore ; +class RooExpensiveObjectCache ; class RooRealVar : public RooAbsRealLValue { public: @@ -79,6 +82,7 @@ class RooRealVar : public RooAbsRealLValue { Bool_t hasBinning(const char* name) const ; const RooAbsBinning& getBinning(const char* name=0, Bool_t verbose=kTRUE, Bool_t createOnTheFly=kFALSE) const ; RooAbsBinning& getBinning(const char* name=0, Bool_t verbose=kTRUE, Bool_t createOnTheFly=kFALSE) ; + std::list<std::string> getBinningNames() const ; // Set infinite fit range limits inline void removeMin(const char* name=0) { getBinning(name).setMin(-RooNumber::infinity()) ; } @@ -86,8 +90,8 @@ class RooRealVar : public RooAbsRealLValue { inline void removeRange(const char* name=0) { getBinning(name).setRange(-RooNumber::infinity(),RooNumber::infinity()) ; } // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; // We implement a fundamental type of AbsArg that can be stored in a dataset inline virtual Bool_t isFundamental() const { return kTRUE; } @@ -95,13 +99,13 @@ class RooRealVar : public RooAbsRealLValue { // Force to be a leaf-node of any expression tree, even if we have (shape) servers virtual Bool_t isDerived() const { // Does value or shape of this arg depend on any other arg? - return (_serverList.GetSize()>0 || _proxyList.GetSize()>0)?kTRUE:kFALSE; + return (_serverList.GetSize()>0 || _proxyList.GetEntries()>0)?kTRUE:kFALSE; } // Printing interface (human readable) - virtual void printValue(ostream& os) const ; - virtual void printExtras(ostream& os) const ; - virtual void printMultiline(ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printValue(std::ostream& os) const ; + virtual void printExtras(std::ostream& os) const ; + virtual void printMultiline(std::ostream& os, Int_t contents, Bool_t verbose=kFALSE, TString indent="") const ; virtual Int_t defaultPrintContents(Option_t* opt) const ; @@ -148,6 +152,8 @@ class RooRealVar : public RooAbsRealLValue { } return _sharedProp ; } + + virtual void setExpensiveObjectCache(RooExpensiveObjectCache&) { ; } // variables don't need caches static RooSharedPropertiesList _sharedPropList; // List of properties shared among clone sets static RooRealVarSharedProperties _nullProp ; // Null property diff --git a/roofit/roofitcore/inc/RooResolutionModel.h b/roofit/roofitcore/inc/RooResolutionModel.h index a0290f052ed38..3213d451f51cc 100644 --- a/roofit/roofitcore/inc/RooResolutionModel.h +++ b/roofit/roofitcore/inc/RooResolutionModel.h @@ -21,6 +21,8 @@ #include "RooRealVar.h" #include "RooFormulaVar.h" +class RooAbsAnaConvPdf; + class RooResolutionModel : public RooAbsPdf { public: @@ -31,6 +33,10 @@ class RooResolutionModel : public RooAbsPdf { virtual TObject* clone(const char* newname) const = 0 ; virtual ~RooResolutionModel(); + virtual RooAbsGenContext* modelGenContext(const RooAbsAnaConvPdf&, const RooArgSet&, + const RooDataSet*, const RooArgSet*, + Bool_t) const { return 0; } + Double_t getValV(const RooArgSet* nset=0) const ; virtual RooResolutionModel* convolution(RooFormulaVar* basis, RooAbsArg* owner) const ; RooRealVar& convVar() const ; @@ -45,7 +51,7 @@ class RooResolutionModel : public RooAbsPdf { inline const RooFormulaVar& basis() const { return _basis?*_basis:*identity() ; } Bool_t isConvolved() { return _basis ? kTRUE : kFALSE ; } - virtual void printMultiline(ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; static void cleanup() ; diff --git a/roofit/roofitcore/inc/RooSetProxy.h b/roofit/roofitcore/inc/RooSetProxy.h index a853a6385cdac..25ee4aa173410 100644 --- a/roofit/roofitcore/inc/RooSetProxy.h +++ b/roofit/roofitcore/inc/RooSetProxy.h @@ -55,7 +55,7 @@ class RooSetProxy : public RooArgSet, public RooAbsProxy { Bool_t remove(const RooAbsCollection& list, Bool_t silent=kFALSE, Bool_t matchByNameOnly=kFALSE) ; virtual void removeAll() ; - virtual void print(ostream& os, Bool_t addContents=kFALSE) const ; + virtual void print(std::ostream& os, Bool_t addContents=kFALSE) const ; RooSetProxy& operator=(const RooArgSet& other) ; diff --git a/roofit/roofitcore/inc/RooSimGenContext.h b/roofit/roofitcore/inc/RooSimGenContext.h index 538bf80ee64c4..c7ae552a0edb5 100644 --- a/roofit/roofitcore/inc/RooSimGenContext.h +++ b/roofit/roofitcore/inc/RooSimGenContext.h @@ -34,7 +34,7 @@ class RooSimGenContext : public RooAbsGenContext { virtual void attach(const RooArgSet& params) ; - virtual void printMultiline(ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; protected: diff --git a/roofit/roofitcore/inc/RooSimSplitGenContext.h b/roofit/roofitcore/inc/RooSimSplitGenContext.h index 616117141fdcc..925ffff0fa652 100644 --- a/roofit/roofitcore/inc/RooSimSplitGenContext.h +++ b/roofit/roofitcore/inc/RooSimSplitGenContext.h @@ -33,9 +33,9 @@ class RooSimSplitGenContext : public RooAbsGenContext { virtual void attach(const RooArgSet& params) ; - virtual void printMultiline(ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream &os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; - virtual RooDataSet *generate(Int_t nEvents= 0, Bool_t skipInit=kFALSE, Bool_t extendedMode=kFALSE); + virtual RooDataSet *generate(Double_t nEvents= 0, Bool_t skipInit=kFALSE, Bool_t extendedMode=kFALSE); virtual void setExpectedData(Bool_t) ; diff --git a/roofit/roofitcore/inc/RooSimWSTool.h b/roofit/roofitcore/inc/RooSimWSTool.h index b506e2eefc1dc..f82fb41907785 100644 --- a/roofit/roofitcore/inc/RooSimWSTool.h +++ b/roofit/roofitcore/inc/RooSimWSTool.h @@ -76,6 +76,27 @@ class RooSimWSTool : public TNamed, public RooPrintable { } ; +class RooSimWSTool::SplitRule : public TNamed { +public: + SplitRule(const char* pdfName="") : TNamed(pdfName,pdfName) {} ; + virtual ~SplitRule() {} ; + void splitParameter(const char* paramList, const char* categoryList) ; + void splitParameterConstrained(const char* paramNameList, const char* categoryNameList, const char* remainderStateName) ; + +protected: + + friend class RooSimWSTool ; + friend class BuildConfig ; + friend class MultiBuildConfig ; + void configure(const RooCmdArg& arg1=RooCmdArg::none(),const RooCmdArg& arg2=RooCmdArg::none(), + const RooCmdArg& arg3=RooCmdArg::none(),const RooCmdArg& arg4=RooCmdArg::none(), + const RooCmdArg& arg5=RooCmdArg::none(),const RooCmdArg& arg6=RooCmdArg::none()) ; + + std::list<std::string> _miStateNameList ; + std::map<std::string, std::pair<std::list<std::string>,std::string> > _paramSplitMap ; //<paramName,<std::list<splitCatSet>,remainderStateName>> + ClassDef(SplitRule,0) // Split rule specification for prototype p.d.f +} ; + class RooSimWSTool::BuildConfig { @@ -123,26 +144,6 @@ class RooSimWSTool::MultiBuildConfig : public RooSimWSTool::BuildConfig -class RooSimWSTool::SplitRule : public TNamed { -public: - SplitRule(const char* pdfName="") : TNamed(pdfName,pdfName) {} ; - virtual ~SplitRule() {} ; - void splitParameter(const char* paramList, const char* categoryList) ; - void splitParameterConstrained(const char* paramNameList, const char* categoryNameList, const char* remainderStateName) ; - -protected: - - friend class RooSimWSTool ; - friend class BuildConfig ; - friend class MultiBuildConfig ; - void configure(const RooCmdArg& arg1=RooCmdArg::none(),const RooCmdArg& arg2=RooCmdArg::none(), - const RooCmdArg& arg3=RooCmdArg::none(),const RooCmdArg& arg4=RooCmdArg::none(), - const RooCmdArg& arg5=RooCmdArg::none(),const RooCmdArg& arg6=RooCmdArg::none()) ; - - std::list<std::string> _miStateNameList ; - std::map<std::string, std::pair<std::list<std::string>,std::string> > _paramSplitMap ; //<paramName,<list<splitCatSet>,remainderStateName>> - ClassDef(SplitRule,0) // Split rule specification for prototype p.d.f - } ; @@ -155,7 +156,7 @@ class RooSimWSTool::ObjSplitRule { friend class RooSimWSTool ; friend class RooSimWSTool::ObjBuildConfig ; std::list<const RooCatType*> _miStateList ; - std::map<RooAbsArg*, std::pair<RooArgSet,std::string> > _paramSplitMap ; //<paramName,<list<splitCatSet>,remainderStateName>> + std::map<RooAbsArg*, std::pair<RooArgSet,std::string> > _paramSplitMap ; //<paramName,<std::list<splitCatSet>,remainderStateName>> ClassDef(ObjSplitRule,0) // Validated RooSimWSTool split rule } ; diff --git a/roofit/roofitcore/inc/RooSimultaneous.h b/roofit/roofitcore/inc/RooSimultaneous.h index b7654da14e156..ae24be0e21832 100644 --- a/roofit/roofitcore/inc/RooSimultaneous.h +++ b/roofit/roofitcore/inc/RooSimultaneous.h @@ -68,6 +68,7 @@ class RooSimultaneous : public RooAbsPdf { const RooCmdArg& arg9=RooCmdArg(), const RooCmdArg& arg10=RooCmdArg()) const { return RooAbsReal::plotOn(frame,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10) ; } + virtual RooPlot* plotOn(RooPlot* frame, RooLinkedList& cmdList) const ; // Backward compatibility function virtual RooPlot *plotOn(RooPlot *frame, Option_t* drawOptions, Double_t scaleFactor=1.0, @@ -87,7 +88,6 @@ class RooSimultaneous : public RooAbsPdf { protected: void initialize(RooAbsCategoryLValue& inIndexCat, std::map<std::string,RooAbsPdf*> pdfMap) ; - virtual RooPlot* plotOn(RooPlot* frame, RooLinkedList& cmdList) const ; virtual void selectNormalization(const RooArgSet* depSet=0, Bool_t force=kFALSE) ; virtual void selectNormalizationRange(const char* rangeName=0, Bool_t force=kFALSE) ; diff --git a/roofit/roofitcore/inc/RooStreamParser.h b/roofit/roofitcore/inc/RooStreamParser.h index 32f9acd3d11e9..6a5fa6d49df96 100644 --- a/roofit/roofitcore/inc/RooStreamParser.h +++ b/roofit/roofitcore/inc/RooStreamParser.h @@ -22,8 +22,8 @@ class RooStreamParser { public: // Constructors, assignment etc. - RooStreamParser(istream& is) ; - RooStreamParser(istream& is, const TString& errPrefix) ; + RooStreamParser(std::istream& is) ; + RooStreamParser(std::istream& is, const TString& errPrefix) ; virtual ~RooStreamParser(); TString readToken() ; @@ -49,14 +49,14 @@ class RooStreamParser { protected: - istream* _is ; + std::istream* _is ; Bool_t _atEOL ; Bool_t _atEOF ; TString _prefix ; TString _punct ; - ClassDef(RooStreamParser,0) // Utility class that parses iostream data into tokens + ClassDef(RooStreamParser,0) // Utility class that parses std::iostream data into tokens }; #endif diff --git a/roofit/roofitcore/inc/RooStringVar.h b/roofit/roofitcore/inc/RooStringVar.h index 0713ddfb41660..7fded7b84c8df 100644 --- a/roofit/roofitcore/inc/RooStringVar.h +++ b/roofit/roofitcore/inc/RooStringVar.h @@ -40,8 +40,8 @@ class RooStringVar : public RooAbsString { inline virtual Bool_t isFundamental() const { return kTRUE; } // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; protected: diff --git a/roofit/roofitcore/inc/RooSuperCategory.h b/roofit/roofitcore/inc/RooSuperCategory.h index b47b8f803aae3..3804fb708b843 100644 --- a/roofit/roofitcore/inc/RooSuperCategory.h +++ b/roofit/roofitcore/inc/RooSuperCategory.h @@ -36,11 +36,11 @@ class RooSuperCategory : public RooAbsCategoryLValue { virtual Bool_t setLabel(const char* label, Bool_t printError=kTRUE) ; // Printing interface (human readable) - virtual void printMultiline(ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; // I/O streaming interface (machine readable) - virtual Bool_t readFromStream(istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; - virtual void writeToStream(ostream& os, Bool_t compact) const ; + virtual Bool_t readFromStream(std::istream& is, Bool_t compact, Bool_t verbose=kFALSE) ; + virtual void writeToStream(std::ostream& os, Bool_t compact) const ; TIterator* MakeIterator() const ; const RooArgSet& inputCatList() const { return _catSet ; } diff --git a/roofit/roofitcore/inc/RooThresholdCategory.h b/roofit/roofitcore/inc/RooThresholdCategory.h index b77754741be2e..9f8d519e69876 100644 --- a/roofit/roofitcore/inc/RooThresholdCategory.h +++ b/roofit/roofitcore/inc/RooThresholdCategory.h @@ -35,9 +35,9 @@ class RooThresholdCategory : public RooAbsCategory { Bool_t addThreshold(Double_t upperLimit, const char* catName, Int_t catIdx=-99999) ; // Printing interface (human readable) - virtual void printMultiline(ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; + virtual void printMultiline(std::ostream& os, Int_t content, Bool_t verbose=kFALSE, TString indent="") const ; - void writeToStream(ostream& os, Bool_t compact) const ; + void writeToStream(std::ostream& os, Bool_t compact) const ; protected: diff --git a/roofit/roofitcore/inc/RooTrace.h b/roofit/roofitcore/inc/RooTrace.h index c3a9fba367072..7fc0e86c688c1 100644 --- a/roofit/roofitcore/inc/RooTrace.h +++ b/roofit/roofitcore/inc/RooTrace.h @@ -17,40 +17,68 @@ #define ROO_TRACE #include <assert.h> +#include <map> #include "Riosfwd.h" #include "RooLinkedList.h" +#ifndef __CINT__ +#define TRACE_CREATE RooTrace::create(this); +#define TRACE_DESTROY RooTrace::destroy(this); +#endif + class RooTrace { public: - + RooTrace() ; virtual ~RooTrace() {} ; static void create(const TObject* obj) ; static void destroy(const TObject* obj) ; + + static void createSpecial(const char* name, int size) ; + static void destroySpecial(const char* name) ; static void active(Bool_t flag) ; static void verbose(Bool_t flag) ; static void dump() ; - static void dump(ostream& os, Bool_t sinceMarked=kFALSE) ; + static void dump(std::ostream& os, Bool_t sinceMarked=kFALSE) ; static void mark() ; + + static void printObjectCounts() ; static void callgrind_zero() ; static void callgrind_dump() ; + + static RooTrace& instance() ; protected: - static void create2(const TObject* obj) ; - static void destroy2(const TObject* obj) ; + static RooTrace* _instance ; + + void dump3(std::ostream&, Bool_t sinceMarked) ; + + void mark3() ; + void printObjectCounts3() ; + + void create2(const TObject* obj) ; + void destroy2(const TObject* obj) ; + + void create3(const TObject* obj) ; + void destroy3(const TObject* obj) ; + + void createSpecial3(const char* name, int size) ; + void destroySpecial3(const char* name) ; void addPad(const TObject* ref, Bool_t doPad) ; Bool_t removePad(const TObject* ref) ; - static Bool_t _active ; - static Bool_t _verbose ; - - static RooLinkedList _list ; - static RooLinkedList _markList ; + Bool_t _active ; + Bool_t _verbose ; + RooLinkedList _list ; + RooLinkedList _markList ; + std::map<TClass*,int> _objectCount ; + std::map<std::string,int> _specialCount ; + std::map<std::string,int> _specialSize ; ClassDef(RooTrace,0) // Memory tracer utility for RooFit objects }; diff --git a/roofit/roofitcore/inc/RooTreeData.h b/roofit/roofitcore/inc/RooTreeData.h index d557131796098..2b0e8f82cfd35 100644 --- a/roofit/roofitcore/inc/RooTreeData.h +++ b/roofit/roofitcore/inc/RooTreeData.h @@ -26,7 +26,8 @@ class RooTreeData : public RooAbsData { public: // Constructors, factory methods etc. - RooTreeData() {} ; + RooTreeData() : _tree(0) {} ; + const TTree *GetTree() const { return _tree; } private: diff --git a/roofit/roofitcore/inc/RooTreeDataStore.h b/roofit/roofitcore/inc/RooTreeDataStore.h index 73a1dd005ff9c..871c6a49d750b 100644 --- a/roofit/roofitcore/inc/RooTreeDataStore.h +++ b/roofit/roofitcore/inc/RooTreeDataStore.h @@ -103,7 +103,7 @@ class RooTreeDataStore : public RooAbsDataStore { void Draw(Option_t* option = "") ; // Constant term optimizer interface - virtual void cacheArgs(const RooAbsArg* owner, RooArgSet& varSet, const RooArgSet* nset=0) ; + virtual void cacheArgs(const RooAbsArg* owner, RooArgSet& varSet, const RooArgSet* nset=0, Bool_t skipZeroWeights=kFALSE) ; virtual const RooAbsArg* cacheOwner() { return _cacheOwner ; } virtual void setArgStatus(const RooArgSet& set, Bool_t active) ; virtual void resetCache() ; diff --git a/roofit/roofitcore/inc/RooTruthModel.h b/roofit/roofitcore/inc/RooTruthModel.h index 25f5168b809c7..55bb98365088f 100644 --- a/roofit/roofitcore/inc/RooTruthModel.h +++ b/roofit/roofitcore/inc/RooTruthModel.h @@ -43,6 +43,10 @@ class RooTruthModel : public RooResolutionModel { virtual Int_t basisCode(const char* name) const ; + virtual RooAbsGenContext* modelGenContext(const RooAbsAnaConvPdf& convPdf, const RooArgSet &vars, + const RooDataSet *prototype=0, const RooArgSet* auxProto=0, + Bool_t verbose= kFALSE) const; + Int_t getGenerator(const RooArgSet& directVars, RooArgSet &generateVars, Bool_t staticInitOK=kTRUE) const; void generateEvent(Int_t code); diff --git a/roofit/roofitcore/inc/RooVectorDataStore.h b/roofit/roofitcore/inc/RooVectorDataStore.h index fa69854d1cc7b..8b4c0a2c4e7e7 100644 --- a/roofit/roofitcore/inc/RooVectorDataStore.h +++ b/roofit/roofitcore/inc/RooVectorDataStore.h @@ -59,6 +59,9 @@ class RooVectorDataStore : public RooAbsDataStore { // Write current row virtual Int_t fill() ; + // reserve storage for nEvt entries + virtual void reserve(Int_t nEvt); + // Retrieve a row using RooAbsDataStore::get ; virtual const RooArgSet* get(Int_t index) const ; @@ -95,10 +98,10 @@ class RooVectorDataStore : public RooAbsDataStore { // Constant term optimizer interface virtual const RooAbsArg* cacheOwner() { return _cacheOwner ; } - virtual void cacheArgs(const RooAbsArg* owner, RooArgSet& varSet, const RooArgSet* nset=0) ; + virtual void cacheArgs(const RooAbsArg* owner, RooArgSet& varSet, const RooArgSet* nset=0, Bool_t skipZeroWeights=kTRUE) ; virtual void attachCache(const RooAbsArg* newOwner, const RooArgSet& cachedVars) ; virtual void resetCache() ; - virtual void recalculateCache(const RooArgSet* /*proj*/, Int_t firstEvent, Int_t lastEvent, Int_t stepSize) ; + virtual void recalculateCache(const RooArgSet* /*proj*/, Int_t firstEvent, Int_t lastEvent, Int_t stepSize, Bool_t skipZeroWeights) ; virtual void setArgStatus(const RooArgSet& set, Bool_t active) ; @@ -128,40 +131,55 @@ class RooVectorDataStore : public RooAbsDataStore { class RealVector { public: - RealVector(UInt_t initialCapacity=100) : - _nativeReal(0), _real(0), _buf(0), _nativeBuf(0), _vec0(0), _tracker(0) { - _vec.reserve(initialCapacity) ; + RealVector(UInt_t initialCapacity=(4096 / sizeof(Double_t))) : + _nativeReal(0), _real(0), _buf(0), _nativeBuf(0), _vec0(0), _tracker(0), _nset(0) { + _vec.reserve(initialCapacity); } - RealVector(RooAbsReal* arg, UInt_t initialCapacity=100) : - _nativeReal(arg), _real(0), _buf(0), _nativeBuf(0), _vec0(0), _tracker(0) { - _vec.reserve(initialCapacity) ; + RealVector(RooAbsReal* arg, UInt_t initialCapacity=(4096 / sizeof(Double_t))) : + _nativeReal(arg), _real(0), _buf(0), _nativeBuf(0), _vec0(0), _tracker(0), _nset(0) { + _vec.reserve(initialCapacity); } virtual ~RealVector() { - if (_tracker) delete _tracker ; + delete _tracker; + if (_nset) delete _nset ; } RealVector(const RealVector& other, RooAbsReal* real=0) : - _vec(other._vec), _nativeReal(real?real:other._nativeReal), _real(real?real:other._real), _buf(other._buf), _nativeBuf(other._nativeBuf) { + _vec(other._vec), _nativeReal(real?real:other._nativeReal), _real(real?real:other._real), _buf(other._buf), _nativeBuf(other._nativeBuf), _nset(0) { _vec0 = _vec.size()>0 ? &_vec.front() : 0 ; if (other._tracker) { _tracker = new RooChangeTracker(Form("track_%s",_nativeReal->GetName()),"tracker",other._tracker->parameters()) ; } else { _tracker = 0 ; } + if (other._nset) { + _nset = new RooArgSet(*other._nset) ; + } } RealVector& operator=(const RealVector& other) { - if (&other==this) return *this ; - _nativeReal = other._nativeReal ; - _real = other._real ; - _buf = other._buf ; - _nativeBuf = other._nativeBuf ; - _vec = other._vec ; - _vec0 = _vec.size()>0 ? &_vec.front() : 0 ; - return *this ; + if (&other==this) return *this; + _nativeReal = other._nativeReal; + _real = other._real; + _buf = other._buf; + _nativeBuf = other._nativeBuf; + if (other._vec.size() <= _vec.capacity() / 2 && _vec.capacity() > (4096 / sizeof(Double_t))) { + std::vector<Double_t> tmp; + tmp.reserve(std::max(other._vec.size(), 4096 / sizeof(Double_t))); + tmp.assign(other._vec.begin(), other._vec.end()); + _vec.swap(tmp); + } else { + _vec = other._vec; + } + _vec0 = _vec.size()>0 ? &_vec.front() : 0; + return *this; } + + void setNset(RooArgSet* newNset) { _nset = newNset ? new RooArgSet(*newNset) : 0 ; } + + RooArgSet* nset() const { return _nset ; } void setBufArg(RooAbsReal* arg) { _nativeReal = arg ; } const RooAbsReal* bufArg() const { return _nativeReal ; } @@ -196,13 +214,15 @@ class RooVectorDataStore : public RooAbsDataStore { } ; void write(Int_t i) { -/* cout << "write(" << this << ") [" << i << "] nativeReal = " << _nativeReal << " = " << _nativeReal->GetName() << " real = " << _real << " buf = " << _buf << " value = " << *_buf << " native getVal() = " << _nativeReal->getVal() << " getVal() = " << _real->getVal() << endl ; */ +/* std::cout << "write(" << this << ") [" << i << "] nativeReal = " << _nativeReal << " = " << _nativeReal->GetName() << " real = " << _real << " buf = " << _buf << " value = " << *_buf << " native getVal() = " << _nativeReal->getVal() << " getVal() = " << _real->getVal() << std::endl ; */ _vec[i] = *_buf ; } void reset() { - _vec.clear() ; - _vec0 = &_vec.front() ; + // make sure the vector releases the underlying memory + std::vector<Double_t> tmp; + _vec.swap(tmp); + _vec0 = 0; } inline void get(Int_t idx) const { @@ -216,8 +236,24 @@ class RooVectorDataStore : public RooAbsDataStore { Int_t size() const { return _vec.size() ; } void resize(Int_t siz) { - _vec.resize(siz) ; - _vec0 = &_vec.front() ; + if (siz < Int_t(_vec.capacity()) / 2 && _vec.capacity() > (4096 / sizeof(Double_t))) { + // do an expensive copy, if we save at least a factor 2 in size + std::vector<Double_t> tmp; + tmp.reserve(std::max(siz, Int_t(4096 / sizeof(Double_t)))); + if (!_vec.empty()) + tmp.assign(_vec.begin(), std::min(_vec.end(), _vec.begin() + siz)); + if (Int_t(tmp.size()) != siz) + tmp.resize(siz); + _vec.swap(tmp); + } else { + _vec.resize(siz); + } + _vec0 = &_vec.front(); + } + + void reserve(Int_t siz) { + _vec.reserve(siz); + _vec0 = &_vec.front(); } protected: @@ -231,19 +267,20 @@ class RooVectorDataStore : public RooAbsDataStore { Double_t* _nativeBuf ; //! Double_t* _vec0 ; //! RooChangeTracker* _tracker ; // + RooArgSet* _nset ; //! ClassDef(RealVector,1) // STL-vector-based Data Storage class } ; class RealFullVector : public RealVector { public: - RealFullVector(UInt_t initialCapacity=100) : RealVector(initialCapacity), + RealFullVector(UInt_t initialCapacity=(4096 / sizeof(Double_t))) : RealVector(initialCapacity), _bufE(0), _bufEL(0), _bufEH(0), _nativeBufE(0), _nativeBufEL(0), _nativeBufEH(0), _vecE(0), _vecEL(0), _vecEH(0) { } - RealFullVector(RooAbsReal* arg, UInt_t initialCapacity=100) : + RealFullVector(RooAbsReal* arg, UInt_t initialCapacity=(4096 / sizeof(Double_t))) : RealVector(arg,initialCapacity), _bufE(0), _bufEL(0), _bufEH(0), _nativeBufE(0), _nativeBufEL(0), _nativeBufEH(0), @@ -273,22 +310,41 @@ class RooVectorDataStore : public RooAbsDataStore { } RealFullVector& operator=(const RealFullVector& other) { - if (&other==this) return *this ; - RealVector::operator=(other) ; - _bufE = other._bufE ; - _bufEL = other._bufEL ; - _bufEH = other._bufEH ; - _nativeBufE = other._nativeBufE ; - _nativeBufEL = other._nativeBufEL ; - _nativeBufEH = other._nativeBufEH ; - _vecE = other._vecE ? new std::vector<Double_t>(*other._vecE) : 0 ; - _vecEL = other._vecEL ? new std::vector<Double_t>(*other._vecEL) : 0 ; - _vecEH = other._vecEH ? new std::vector<Double_t>(*other._vecEH) : 0 ; - return *this ; + if (&other==this) return *this; + RealVector::operator=(other); + _bufE = other._bufE; + _bufEL = other._bufEL; + _bufEH = other._bufEH; + _nativeBufE = other._nativeBufE; + _nativeBufEL = other._nativeBufEL; + _nativeBufEH = other._nativeBufEH; + std::vector<Double_t>* src[3] = { other._vecE, other._vecEL, other._vecEH }; + std::vector<Double_t>* dst[3] = { _vecE, _vecEL, _vecEH }; + for (unsigned i = 0; i < 3; ++i) { + if (src[i]) { + if (dst[i]) { + if (dst[i]->size() <= src[i]->capacity() / 2 && + src[i]->capacity() > (4096 / sizeof(Double_t))) { + std::vector<Double_t> tmp; + tmp.reserve(std::max(src[i]->size(), 4096 / sizeof(Double_t))); + tmp.assign(src[i]->begin(), src[i]->end()); + dst[i]->swap(tmp); + } else { + *dst[i] = *src[i]; + } + } else { + dst[i] = new std::vector<Double_t>(*src[i]); + } + } else { + delete dst[i]; + dst[i] = 0; + } + } + return *this; } void setErrorBuffer(Double_t* newBuf) { -/* cout << "setErrorBuffer(" << _nativeReal->GetName() << ") newBuf = " << newBuf << endl ; */ +/* std::cout << "setErrorBuffer(" << _nativeReal->GetName() << ") newBuf = " << newBuf << std::endl ; */ _bufE = newBuf ; if (!_vecE) _vecE = new std::vector<Double_t> ; _vecE->reserve(_vec.capacity()) ; @@ -334,10 +390,19 @@ class RooVectorDataStore : public RooAbsDataStore { } void reset() { - RealVector::reset() ; - if (_vecE) _vecE->clear() ; - if (_vecEL) _vecEL->clear() ; - if (_vecEH) _vecEH->clear() ; + RealVector::reset(); + if (_vecE) { + std::vector<Double_t> tmp; + _vecE->swap(tmp); + } + if (_vecEL) { + std::vector<Double_t> tmp; + _vecEL->swap(tmp); + } + if (_vecEH) { + std::vector<Double_t> tmp; + _vecEH->swap(tmp); + } } inline void get(Int_t idx) const { @@ -348,10 +413,33 @@ class RooVectorDataStore : public RooAbsDataStore { } void resize(Int_t siz) { - RealVector::resize(siz) ; - if (_vecE) _vecE->resize(siz) ; - if (_vecEL) _vecEL->resize(siz) ; - if (_vecEH) _vecEH->resize(siz) ; + RealVector::resize(siz); + std::vector<Double_t>* vlist[3] = { _vecE, _vecEL, _vecEH }; + for (unsigned i = 0; i < 3; ++i) { + if (!vlist[i]) continue; + if (vlist[i]) { + if (siz < Int_t(vlist[i]->capacity()) / 2 && vlist[i]->capacity() > (4096 / sizeof(Double_t))) { + // if we gain a factor of 2 in memory, we copy and swap + std::vector<Double_t> tmp; + tmp.reserve(std::max(siz, Int_t(4096 / sizeof(Double_t)))); + if (!vlist[i]->empty()) + tmp.assign(vlist[i]->begin(), + std::min(_vec.end(), _vec.begin() + siz)); + if (Int_t(tmp.size()) != siz) + tmp.resize(siz); + vlist[i]->swap(tmp); + } else { + vlist[i]->resize(siz); + } + } + } + } + + void reserve(Int_t siz) { + RealVector::reserve(siz); + if (_vecE) _vecE->reserve(siz); + if (_vecEL) _vecEL->reserve(siz); + if (_vecEH) _vecEH->reserve(siz); } private: @@ -369,16 +457,16 @@ class RooVectorDataStore : public RooAbsDataStore { class CatVector { public: - CatVector(UInt_t initialCapacity=100) : + CatVector(UInt_t initialCapacity=(4096 / sizeof(RooCatType))) : _cat(0), _buf(0), _nativeBuf(0), _vec0(0) { - _vec.reserve(initialCapacity) ; + _vec.reserve(initialCapacity); } - CatVector(RooAbsCategory* cat, UInt_t initialCapacity=100) : + CatVector(RooAbsCategory* cat, UInt_t initialCapacity=(4096 / sizeof(RooCatType))) : _cat(cat), _buf(0), _nativeBuf(0), _vec0(0) { - _vec.reserve(initialCapacity) ; + _vec.reserve(initialCapacity); } virtual ~CatVector() { @@ -391,13 +479,20 @@ class RooVectorDataStore : public RooAbsDataStore { } CatVector& operator=(const CatVector& other) { - if (&other==this) return *this ; - _cat = other._cat ; - _buf = other._buf ; - _nativeBuf = other._nativeBuf ; - _vec = other._vec ; - _vec0 = _vec.size()>0 ? &_vec.front() : 0 ; - return *this ; + if (&other==this) return *this; + _cat = other._cat; + _buf = other._buf; + _nativeBuf = other._nativeBuf; + if (other._vec.size() <= _vec.capacity() / 2 && _vec.capacity() > (4096 / sizeof(RooCatType))) { + std::vector<RooCatType> tmp; + tmp.reserve(std::max(other._vec.size(), 4096 / sizeof(RooCatType))); + tmp.assign(other._vec.begin(), other._vec.end()); + _vec.swap(tmp); + } else { + _vec = other._vec; + } + _vec0 = _vec.size()>0 ? &_vec.front() : 0; + return *this; } void setBuffer(RooCatType* newBuf) { @@ -417,8 +512,10 @@ class RooVectorDataStore : public RooAbsDataStore { _vec[i]=*_buf ; } ; void reset() { - _vec.clear() ; - _vec0 = &_vec.front() ; + // make sure the vector releases the underlying memory + std::vector<RooCatType> tmp; + _vec.swap(tmp); + _vec0 = 0; } inline void get(Int_t idx) const { _buf->assignFast(*(_vec0+idx)) ; @@ -429,13 +526,28 @@ class RooVectorDataStore : public RooAbsDataStore { Int_t size() const { return _vec.size() ; } void resize(Int_t siz) { - _vec.resize(siz) ; - _vec0 = &_vec.front() ; + if (siz < Int_t(_vec.capacity()) / 2 && _vec.capacity() > (4096 / sizeof(RooCatType))) { + // do an expensive copy, if we save at least a factor 2 in size + std::vector<RooCatType> tmp; + tmp.reserve(std::max(siz, Int_t(4096 / sizeof(RooCatType)))); + if (!_vec.empty()) + tmp.assign(_vec.begin(), std::min(_vec.end(), _vec.begin() + siz)); + if (Int_t(tmp.size()) != siz) + tmp.resize(siz); + _vec.swap(tmp); + } else { + _vec.resize(siz); + } + _vec0 = &_vec.front(); } - void setBufArg(RooAbsCategory* arg) { _cat = arg ; } - const RooAbsCategory* bufArg() const { return _cat ; } + void reserve(Int_t siz) { + _vec.reserve(siz); + _vec0 = &_vec.front(); + } + void setBufArg(RooAbsCategory* arg) { _cat = arg; } + const RooAbsCategory* bufArg() const { return _cat; } private: friend class RooVectorDataStore ; @@ -487,7 +599,8 @@ class RooVectorDataStore : public RooAbsDataStore { // First try a match by name std::vector<RealVector*>::iterator iter = _realStoreList.begin() ; for (; iter!=_realStoreList.end() ; ++iter) { - if (std::string((*iter)->bufArg()->GetName())==real->GetName()) { + //if (std::string((*iter)->bufArg()->GetName())==real->GetName()) { + if ((*iter)->bufArg()->namePtr()==real->namePtr()) { rv = (*iter) ; return rv ; } @@ -496,7 +609,8 @@ class RooVectorDataStore : public RooAbsDataStore { // Then check if an entry already exists for a full real std::vector<RealFullVector*>::iterator iter2 = _realfStoreList.begin() ; for (; iter2!=_realfStoreList.end() ; ++iter2) { - if (std::string((*iter2)->bufArg()->GetName())==real->GetName()) { + //if (std::string((*iter2)->bufArg()->GetName())==real->GetName()) { + if ((*iter2)->bufArg()->namePtr()==real->namePtr()) { // Return full vector as RealVector base class here return (*iter2) ; } @@ -577,7 +691,10 @@ class RooVectorDataStore : public RooAbsDataStore { RealVector* tmp = *iter2 ; _realStoreList.erase(iter2) ; delete tmp ; - _firstReal = &_realStoreList.front() ; + if (_realStoreList.size() > 0) + _firstReal = &_realStoreList.front() ; + else + _firstReal = 0; _nReal-- ; return _realfStoreList.back() ; @@ -613,6 +730,7 @@ class RooVectorDataStore : public RooAbsDataStore { RealFullVector** _firstRealF ; //! do not persist CatVector** _firstCat ; //! do not persist Double_t _sumWeight ; + Double_t _sumWeightCarry; Double_t* _extWgtArray ; //! External weight array Double_t* _extWgtErrLoArray ; //! External weight array - low error @@ -627,7 +745,7 @@ class RooVectorDataStore : public RooAbsDataStore { RooVectorDataStore* _cache ; //! Optimization cache RooAbsArg* _cacheOwner ; //! Cache owner - ClassDef(RooVectorDataStore,1) // STL-vector-based Data Storage class + ClassDef(RooVectorDataStore,2) // STL-vector-based Data Storage class }; diff --git a/roofit/roofitcore/inc/RooWorkspace.h b/roofit/roofitcore/inc/RooWorkspace.h index f7bf174c1a51c..9c9a39245c415 100644 --- a/roofit/roofitcore/inc/RooWorkspace.h +++ b/roofit/roofitcore/inc/RooWorkspace.h @@ -54,10 +54,22 @@ class RooWorkspace : public TNamed { Bool_t importClassCode(TClass* theClass, Bool_t doReplace=kFALSE) ; // Import functions for dataset, functions, generic objects - Bool_t import(const RooAbsArg& arg, const RooCmdArg& arg1=RooCmdArg(),const RooCmdArg& arg2=RooCmdArg(),const RooCmdArg& arg3=RooCmdArg()) ; - Bool_t import(const RooArgSet& args, const RooCmdArg& arg1=RooCmdArg(),const RooCmdArg& arg2=RooCmdArg(),const RooCmdArg& arg3=RooCmdArg()) ; - Bool_t import(RooAbsData& data, const RooCmdArg& arg1=RooCmdArg(),const RooCmdArg& arg2=RooCmdArg(),const RooCmdArg& arg3=RooCmdArg()) ; - Bool_t import(const char *fileSpec, const RooCmdArg& arg1=RooCmdArg(),const RooCmdArg& arg2=RooCmdArg(),const RooCmdArg& arg3=RooCmdArg()) ; + Bool_t import(const RooAbsArg& arg, + const RooCmdArg& arg1=RooCmdArg(),const RooCmdArg& arg2=RooCmdArg(),const RooCmdArg& arg3=RooCmdArg(), + const RooCmdArg& arg4=RooCmdArg(),const RooCmdArg& arg5=RooCmdArg(),const RooCmdArg& arg6=RooCmdArg(), + const RooCmdArg& arg7=RooCmdArg(),const RooCmdArg& arg8=RooCmdArg(),const RooCmdArg& arg9=RooCmdArg()) ; + Bool_t import(const RooArgSet& args, + const RooCmdArg& arg1=RooCmdArg(),const RooCmdArg& arg2=RooCmdArg(),const RooCmdArg& arg3=RooCmdArg(), + const RooCmdArg& arg4=RooCmdArg(),const RooCmdArg& arg5=RooCmdArg(),const RooCmdArg& arg6=RooCmdArg(), + const RooCmdArg& arg7=RooCmdArg(),const RooCmdArg& arg8=RooCmdArg(),const RooCmdArg& arg9=RooCmdArg()) ; + Bool_t import(RooAbsData& data, + const RooCmdArg& arg1=RooCmdArg(),const RooCmdArg& arg2=RooCmdArg(),const RooCmdArg& arg3=RooCmdArg(), + const RooCmdArg& arg4=RooCmdArg(),const RooCmdArg& arg5=RooCmdArg(),const RooCmdArg& arg6=RooCmdArg(), + const RooCmdArg& arg7=RooCmdArg(),const RooCmdArg& arg8=RooCmdArg(),const RooCmdArg& arg9=RooCmdArg()) ; + Bool_t import(const char *fileSpec, + const RooCmdArg& arg1=RooCmdArg(),const RooCmdArg& arg2=RooCmdArg(),const RooCmdArg& arg3=RooCmdArg(), + const RooCmdArg& arg4=RooCmdArg(),const RooCmdArg& arg5=RooCmdArg(),const RooCmdArg& arg6=RooCmdArg(), + const RooCmdArg& arg7=RooCmdArg(),const RooCmdArg& arg8=RooCmdArg(),const RooCmdArg& arg9=RooCmdArg()) ; Bool_t import(TObject& object, Bool_t replaceExisting=kFALSE) ; Bool_t import(TObject& object, const char* aliasName, Bool_t replaceExisting=kFALSE) ; @@ -78,6 +90,7 @@ class RooWorkspace : public TNamed { Bool_t saveSnapshot(const char* name, const char* paramNames) ; Bool_t saveSnapshot(const char* name, const RooArgSet& params, Bool_t importValues=kFALSE) ; Bool_t loadSnapshot(const char* name) ; + const RooArgSet* getSnapshot(const char* name) const ; void merge(const RooWorkspace& /*other*/) {} ; @@ -92,6 +105,7 @@ class RooWorkspace : public TNamed { RooCategory* cat(const char* name) const ; RooAbsCategory* catfunc(const char* name) const ; RooAbsData* data(const char* name) const ; + RooAbsData* embeddedData(const char* name) const ; RooAbsArg* arg(const char* name) const ; RooAbsArg* fundArg(const char* name) const ; RooArgSet argSet(const char* nameList) const ; @@ -108,6 +122,7 @@ class RooWorkspace : public TNamed { RooArgSet allPdfs() const ; RooArgSet allResolutionModels() const ; std::list<RooAbsData*> allData() const ; + std::list<RooAbsData*> allEmbeddedData() const ; std::list<TObject*> allGenericObjects() const ; Bool_t makeDir() ; @@ -141,6 +156,14 @@ class RooWorkspace : public TNamed { class CodeRepo : public TObject { public: CodeRepo(RooWorkspace* wspace=0) : _wspace(wspace), _compiledOK(kTRUE) {} ; + + CodeRepo(const CodeRepo& other, RooWorkspace* wspace=0) : TObject(other) , + _wspace(wspace?wspace:other._wspace), + _c2fmap(other._c2fmap), + _fmap(other._fmap), + _ehmap(other._ehmap), + _compiledOK(other._compiledOK) {} ; + virtual ~CodeRepo() {} ; Bool_t autoImportClass(TClass* tc, Bool_t doReplace=kFALSE) ; @@ -150,6 +173,8 @@ class RooWorkspace : public TNamed { std::string listOfClassNames() const ; + + class ClassRelInfo { public: TString _baseName; @@ -165,13 +190,21 @@ class RooWorkspace : public TNamed { Bool_t _extracted ; } ; + + class ExtraHeader { + public: + TString _hname ; + TString _hfile ; + } ; + protected: RooWorkspace* _wspace ; // owning workspace std::map<TString,ClassRelInfo> _c2fmap ; // List of contained classes std::map<TString,ClassFiles> _fmap ; // List of contained files + std::map<TString,ExtraHeader> _ehmap ; // List of extra header files Bool_t _compiledOK ; //! Flag indicating that classes compiled OK - ClassDef(CodeRepo,1) ; // Code repository for RooWorkspace + ClassDef(CodeRepo,2) ; // Code repository for RooWorkspace } ; @@ -222,6 +255,7 @@ class RooWorkspace : public TNamed { RooArgSet _allOwnedNodes ; // List of owned pdfs and components RooLinkedList _dataList ; // List of owned datasets + RooLinkedList _embeddedDataList ; // List of owned datasets that are embedded in pdfs RooLinkedList _views ; // List of model views RooLinkedList _snapshots ; // List of parameter snapshots RooLinkedList _genObjects ; // List of generic objects @@ -240,7 +274,7 @@ class RooWorkspace : public TNamed { Bool_t _openTrans ; //! Is there a transaction open? RooArgSet _sandboxNodes ; //! Sandbox for incoming objects in a transaction - ClassDef(RooWorkspace,7) // Persistable project container for (composite) pdfs, functions, variables and datasets + ClassDef(RooWorkspace,8) // Persistable project container for (composite) pdfs, functions, variables and datasets } ; diff --git a/roofit/roofitcore/inc/RooXYChi2Var.h b/roofit/roofitcore/inc/RooXYChi2Var.h index 519cda6c9de99..5447c7b2590e4 100644 --- a/roofit/roofitcore/inc/RooXYChi2Var.h +++ b/roofit/roofitcore/inc/RooXYChi2Var.h @@ -40,7 +40,7 @@ class RooXYChi2Var : public RooAbsOptTestStatistic { virtual TObject* clone(const char* newname) const { return new RooXYChi2Var(*this,newname); } virtual RooAbsTestStatistic* create(const char *name, const char *title, RooAbsReal& pdf, RooAbsData& adata, - const RooArgSet&, const char*, const char*,Int_t, Bool_t,Bool_t, Bool_t) { + const RooArgSet&, const char*, const char*,Int_t, RooFit::MPSplit,Bool_t, Bool_t, Bool_t) { // Virtual constructor return new RooXYChi2Var(name,title,pdf,(RooDataSet&)adata) ; } diff --git a/roofit/roofitcore/src/BidirMMapPipe.cxx b/roofit/roofitcore/src/BidirMMapPipe.cxx new file mode 100644 index 0000000000000..72f53a3496fd2 --- /dev/null +++ b/roofit/roofitcore/src/BidirMMapPipe.cxx @@ -0,0 +1,1964 @@ +/** @file BidirMMapPipe.cxx + * + * implementation of BidirMMapPipe, a class which forks off a child process + * and serves as communications channel between parent and child + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-07-07 + */ +#ifndef _WIN32 +#include <map> +#include <cerrno> +#include <limits> +#include <string> +#include <cstdlib> +#include <cstring> +#include <iostream> +#include <algorithm> +#include <exception> + +#include <poll.h> +#include <fcntl.h> +#include <signal.h> +#include <unistd.h> +#include <pthread.h> +#include <sys/mman.h> +#include <sys/stat.h> +#include <sys/wait.h> +#include <sys/socket.h> + +#include "BidirMMapPipe.h" + +#define BEGIN_NAMESPACE_ROOFIT namespace RooFit { +#define END_NAMESPACE_ROOFIT } + +BEGIN_NAMESPACE_ROOFIT + +/// namespace for implementation details of BidirMMapPipe +namespace BidirMMapPipe_impl { + /** @brief exception to throw if low-level OS calls go wrong + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-07-07 + */ + class BidirMMapPipeException : public std::exception + { + private: + enum { + s_sz = 256 ///< length of buffer + }; + char m_buf[s_sz]; ///< buffer containing the error message + + /// for the POSIX version of strerror_r + static int dostrerror_r(int err, char* buf, std::size_t sz, + int (*f)(int, char*, std::size_t)) + { return f(err, buf, sz); } + /// for the GNU version of strerror_r + static int dostrerror_r(int, char*, std::size_t, + char* (*f)(int, char*, std::size_t)); + public: + /// constructor taking error code, hint on operation (msg) + BidirMMapPipeException(const char* msg, int err); + /// return a destcription of what went wrong + virtual const char* what() const throw() { return m_buf; } + }; + + BidirMMapPipeException::BidirMMapPipeException(const char* msg, int err) + { + std::size_t msgsz = std::strlen(msg); + if (msgsz) { + msgsz = std::min(msgsz, std::size_t(s_sz)); + std::copy(msg, msg + msgsz, m_buf); + if (msgsz < s_sz) { m_buf[msgsz] = ':'; ++msgsz; } + if (msgsz < s_sz) { m_buf[msgsz] = ' '; ++msgsz; } + } + if (msgsz < s_sz) { + // UGLY: GNU and POSIX cannot agree on prototype and behaviour, so + // have to sort it out with overloads + dostrerror_r(err, &m_buf[msgsz], s_sz - msgsz, ::strerror_r); + } + m_buf[s_sz - 1] = 0; // enforce zero-termination + } + + int BidirMMapPipeException::dostrerror_r(int err, char* buf, + std::size_t sz, char* (*f)(int, char*, std::size_t)) + { + buf[0] = 0; + char *tmp = f(err, buf, sz); + if (tmp && tmp != buf) { + std::strncpy(buf, tmp, sz); + buf[sz - 1] = 0; + if (std::strlen(tmp) > sz - 1) return ERANGE; + } + return 0; + } + + /** @brief class representing the header structure in an mmapped page + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-07-07 + * + * contains a field to put pages into a linked list, a field for the size + * of the data being transmitted, and a field for the position until which + * the data has been read + */ + class Page + { + private: + // use as small a data type as possible to maximise payload area + // of pages + short m_next; ///< next page in list (in pagesizes) + unsigned short m_size; ///< size of payload (in bytes) + unsigned short m_pos; ///< index of next byte in payload area + /// copy construction forbidden + Page(const Page&) {} + /// assertignment forbidden + Page& operator=(const Page&) + { return *reinterpret_cast<Page*>(0); } + public: + /// constructor + Page() : m_next(0), m_size(0), m_pos(0) + { + // check that short is big enough - must be done at runtime + // because the page size is not known until runtime + assert(std::numeric_limits<unsigned short>::max() >= + PageChunk::pagesize()); + } + /// set pointer to next page + void setNext(const Page* p); + /// return pointer to next page + Page* next() const; + /// return reference to size field + unsigned short& size() { return m_size; } + /// return size (of payload data) + unsigned size() const { return m_size; } + /// return reference to position field + unsigned short& pos() { return m_pos; } + /// return position + unsigned pos() const { return m_pos; } + /// return pointer to first byte in payload data area of page + inline unsigned char* begin() const + { return reinterpret_cast<unsigned char*>(const_cast<Page*>(this)) + + sizeof(Page); } + /// return pointer to first byte in payload data area of page + inline unsigned char* end() const + { return reinterpret_cast<unsigned char*>(const_cast<Page*>(this)) + + PageChunk::pagesize(); } + /// return the capacity of the page + static unsigned capacity() + { return PageChunk::pagesize() - sizeof(Page); } + /// true if page empty + bool empty() const { return !m_size; } + /// true if page partially filled + bool filled() const { return !empty(); } + /// free space left (to be written to) + unsigned free() const { return capacity() - m_size; } + /// bytes remaining to be read + unsigned remaining() const { return m_size - m_pos; } + /// true if page completely full + bool full() const { return !free(); } + }; + + void Page::setNext(const Page* p) + { + if (!p) { + m_next = 0; + } else { + const char* p1 = reinterpret_cast<char*>(this); + const char* p2 = reinterpret_cast<const char*>(p); + std::ptrdiff_t tmp = p2 - p1; + // difference must be divisible by page size + assert(!(tmp % PageChunk::pagesize())); + tmp /= static_cast<std::ptrdiff_t>(PageChunk::pagesize()); + m_next = tmp; + // no truncation when saving in a short + assert(m_next == tmp); + // final check: next() must return p + assert(next() == p); + } + } + + Page* Page::next() const + { + if (!m_next) return 0; + char* ptmp = reinterpret_cast<char*>(const_cast<Page*>(this)); + ptmp += std::ptrdiff_t(m_next) * PageChunk::pagesize(); + return reinterpret_cast<Page*>(ptmp); + } + + /** @brief class representing a page pool + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-07-24 + * + * pool of mmapped pages (on systems which support it, on all others, the + * functionality is emulated with dynamically allocated memory) + * + * in most operating systems there is a limit to how many mappings any one + * process is allowed to request; for this reason, we mmap a relatively + * large amount up front, and then carve off little pieces as we need them + */ + class PagePool { + private: + /// convenience typedef + typedef BidirMMapPipeException Exception; + + enum { + minsz = 7, ///< minimum chunk size (just below 1 << minsz bytes) + maxsz = 20, ///< maximum chunk size (just below 1 << maxsz bytes) + szincr = 1 ///< size class increment (sz = 1 << (minsz + k * szincr)) + }; + /// a chunk of memory in the pool + typedef BidirMMapPipe_impl::PageChunk Chunk; + /// list of chunks + typedef std::list<Chunk*> ChunkList; + + friend class BidirMMapPipe_impl::PageChunk; + public: + /// convenience typedef + typedef PageChunk::MMapVariety MMapVariety; + /// constructor + PagePool(unsigned nPagesPerGroup); + /// destructor + ~PagePool(); + /// pop a free element out of the pool + Pages pop(); + + /// return page size of the system + static unsigned pagesize() { return PageChunk::pagesize(); } + /// return variety of mmap supported on the system + static MMapVariety mmapVariety() + { return PageChunk::mmapVariety(); } + + /// return number of pages per group (ie. as returned by pop()) + unsigned nPagesPerGroup() const { return m_nPgPerGrp; } + + /// zap the pool (unmap all but Pages p) + void zap(Pages& p); + + private: + /// list of chunks used by the pool + ChunkList m_chunks; + /// list of chunks used by the pool which are not full + ChunkList m_freelist; + /// chunk size map (histogram of chunk sizes) + unsigned m_szmap[(maxsz - minsz) / szincr]; + /// current chunk size + int m_cursz; + /// page group size + unsigned m_nPgPerGrp; + + /// adjust _cursz to current largest block + void updateCurSz(int sz, int incr); + /// find size of next chunk to allocate (in a hopefully smart way) + int nextChunkSz() const; + /// release a chunk + void putOnFreeList(Chunk* chunk); + /// release a chunk + void release(Chunk* chunk); + }; + + Pages::Pages(PageChunk* parent, Page* pages, unsigned npg) : + m_pimpl(new impl) + { + assert(npg < 256); + m_pimpl->m_parent = parent; + m_pimpl->m_pages = pages; + m_pimpl->m_refcnt = 1; + m_pimpl->m_npages = npg; + /// initialise pages + for (unsigned i = 0; i < m_pimpl->m_npages; ++i) new(page(i)) Page(); + } + + unsigned PageChunk::s_pagesize = PageChunk::getPageSize(); + PageChunk::MMapVariety PageChunk::s_mmapworks = PageChunk::Unknown; + + Pages::~Pages() + { + if (m_pimpl && !--(m_pimpl->m_refcnt)) { + if (m_pimpl->m_parent) m_pimpl->m_parent->push(*this); + delete m_pimpl; + } + } + + Pages::Pages(const Pages& other) : + m_pimpl(other.m_pimpl) + { ++(m_pimpl->m_refcnt); } + + Pages& Pages::operator=(const Pages& other) + { + if (&other == this) return *this; + if (--(m_pimpl->m_refcnt)) { + if (m_pimpl->m_parent) m_pimpl->m_parent->push(*this); + delete m_pimpl; + } + m_pimpl = other.m_pimpl; + ++(m_pimpl->m_refcnt); + return *this; + } + + unsigned Pages::pagesize() { return PageChunk::pagesize(); } + + Page* Pages::page(unsigned pgno) const + { + assert(pgno < m_pimpl->m_npages); + unsigned char* pptr = + reinterpret_cast<unsigned char*>(m_pimpl->m_pages); + pptr += pgno * pagesize(); + return reinterpret_cast<Page*>(pptr); + } + + unsigned Pages::pageno(Page* p) const + { + const unsigned char* pptr = + reinterpret_cast<const unsigned char*>(p); + const unsigned char* bptr = + reinterpret_cast<const unsigned char*>(m_pimpl->m_pages); + assert(0 == ((pptr - bptr) % pagesize())); + const unsigned nr = (pptr - bptr) / pagesize(); + assert(nr < m_pimpl->m_npages); + return nr; + } + + unsigned PageChunk::getPageSize() + { + // find out page size of system + long pgsz = sysconf(_SC_PAGESIZE); + if (-1 == pgsz) throw Exception("sysconf", errno); + if (pgsz > 512 && pgsz > long(sizeof(Page))) + return pgsz; + + // in case of failure or implausible value, use a safe default: 4k + // page size, and do not try to mmap + s_mmapworks = Copy; + return 1 << 12; + } + + PageChunk::PageChunk(PagePool* parent, + unsigned length, unsigned nPgPerGroup) : + m_begin(dommap(length)), + m_end(reinterpret_cast<void*>( + reinterpret_cast<unsigned char*>(m_begin) + length)), + m_parent(parent), m_nPgPerGrp(nPgPerGroup), m_nUsedGrp(0) + { + // ok, push groups of pages onto freelist here + unsigned char* p = reinterpret_cast<unsigned char*>(m_begin); + unsigned char* pend = reinterpret_cast<unsigned char*>(m_end); + while (p < pend) { + m_freelist.push_back(reinterpret_cast<void*>(p)); + p += nPgPerGroup * PagePool::pagesize(); + } + } + + PageChunk::~PageChunk() + { + if (m_parent) assert(empty()); + if (m_begin) domunmap(m_begin, len()); + } + + bool PageChunk::contains(const Pages& p) const + { return p.m_pimpl->m_parent == this; } + + Pages PageChunk::pop() + { + assert(!m_freelist.empty()); + void* p = m_freelist.front(); + m_freelist.pop_front(); + ++m_nUsedGrp; + return Pages(this, reinterpret_cast<Page*>(p), m_nPgPerGrp); + } + + void PageChunk::push(const Pages& p) + { + assert(contains(p)); + bool wasempty = m_freelist.empty(); + m_freelist.push_front(reinterpret_cast<void*>(p[0u])); + --m_nUsedGrp; + if (m_parent) { + // notify parent if we need to be put on the free list again + if (wasempty) m_parent->putOnFreeList(this); + // notify parent if we're empty + if (empty()) return m_parent->release(this); + } + } + + void* PageChunk::dommap(unsigned len) + { + assert(len && 0 == (len % s_pagesize)); + // ok, the idea here is to try the different methods of mmapping, and + // choose the first one that works. we have four flavours: + // 1 - anonymous mmap (best) + // 2 - mmap of /dev/zero (about as good as anonymous mmap, but a tiny + // bit more tedious to set up, since you need to open/close a + // device file) + // 3 - mmap of a temporary file (very tedious to set up - need to + // create a temporary file, delete it, make the underlying storage + // large enough, then mmap the fd and close it) + // 4 - if all those fail, we malloc the buffers, and copy the data + // through the OS (then we're no better than normal pipes) + static bool msgprinted = false; + if (Anonymous == s_mmapworks || Unknown == s_mmapworks) { +#if defined(MAP_ANONYMOUS) +#undef MYANONFLAG +#define MYANONFLAG MAP_ANONYMOUS +#elif defined(MAP_ANON) +#undef MYANONFLAG +#define MYANONFLAG MAP_ANON +#else +#undef MYANONFLAG +#endif +#ifdef MYANONFLAG + void* retVal = ::mmap(0, len, PROT_READ | PROT_WRITE, + MYANONFLAG | MAP_SHARED, -1, 0); + if (MAP_FAILED == retVal) { + if (Anonymous == s_mmapworks) throw Exception("mmap", errno); + } else { + assert(Unknown == s_mmapworks || Anonymous == s_mmapworks); + s_mmapworks = Anonymous; + if (!msgprinted) { + std::cerr << " INFO: In " << __func__ << " (" << + __FILE__ << ", line " << __LINE__ << + "): anonymous mmapping works, excellent!" << + std::endl; + msgprinted = true; + } + return retVal; + } +#endif +#undef MYANONFLAG + } + if (DevZero == s_mmapworks || Unknown == s_mmapworks) { + // ok, no anonymous mappings supported directly, so try to map + // /dev/zero which has much the same effect on many systems + int fd = ::open("/dev/zero", O_RDWR); + if (-1 == fd) + throw Exception("open /dev/zero", errno); + void* retVal = ::mmap(0, len, + PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); + if (MAP_FAILED == retVal) { + int errsv = errno; + ::close(fd); + if (DevZero == s_mmapworks) throw Exception("mmap", errsv); + } else { + assert(Unknown == s_mmapworks || DevZero == s_mmapworks); + s_mmapworks = DevZero; + } + if (-1 == ::close(fd)) + throw Exception("close /dev/zero", errno); + if (!msgprinted) { + std::cerr << " INFO: In " << __func__ << " (" << __FILE__ << + ", line " << __LINE__ << "): mmapping /dev/zero works, " + "very good!" << std::endl; + msgprinted = true; + } + return retVal; + } + if (FileBacked == s_mmapworks || Unknown == s_mmapworks) { + char name[] = "/tmp/BidirMMapPipe-XXXXXX"; + int fd; + // open temp file + if (-1 == (fd = ::mkstemp(name))) throw Exception("mkstemp", errno); + // remove it, but keep fd open + if (-1 == ::unlink(name)) { + int errsv = errno; + ::close(fd); + throw Exception("unlink", errsv); + } + // make it the right size: lseek + if (-1 == ::lseek(fd, len - 1, SEEK_SET)) { + int errsv = errno; + ::close(fd); + throw Exception("lseek", errsv); + } + // make it the right size: write a byte + if (1 != ::write(fd, name, 1)) { + int errsv = errno; + ::close(fd); + throw Exception("write", errsv); + } + // do mmap + void* retVal = ::mmap(0, len, + PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); + if (MAP_FAILED == retVal) { + int errsv = errno; + ::close(fd); + if (FileBacked == s_mmapworks) throw Exception("mmap", errsv); + } else { + assert(Unknown == s_mmapworks || FileBacked == s_mmapworks); + s_mmapworks = FileBacked; + } + if (-1 == ::close(fd)) { + int errsv = errno; + ::munmap(retVal, len); + throw Exception("close", errsv); + } + if (!msgprinted) { + std::cerr << " INFO: In " << __func__ << " (" << __FILE__ << + ", line " << __LINE__ << "): mmapping temporary files " + "works, good!" << std::endl; + msgprinted = true; + } + return retVal; + } + if (Copy == s_mmapworks || Unknown == s_mmapworks) { + // fallback solution: mmap does not work on this OS (or does not + // work for what we want to use it), so use a normal buffer of + // memory instead, and collect data in that buffer - this needs an + // additional write/read to/from the pipe(s), but there you go... + if (!msgprinted) { + std::cerr << "WARNING: In " << __func__ << " (" << __FILE__ << + ", line " << __LINE__ << "): anonymous mmapping of " + "shared buffers failed, falling back to read/write on " + " pipes!" << std::endl; + msgprinted = true; + } + s_mmapworks = Copy; + void* retVal = std::malloc(len); + if (!retVal) throw Exception("malloc", errno); + return retVal; + } + // should never get here + assert(false); + return 0; + } + + void PageChunk::domunmap(void* addr, unsigned len) + { + assert(len && 0 == (len % s_pagesize)); + if (addr) { + assert(Unknown != s_mmapworks); + if (Copy != s_mmapworks) { + if (-1 == ::munmap(addr, len)) + throw Exception("munmap", errno); + } else { + std::free(addr); + } + } + } + + void PageChunk::zap(Pages& p) + { + // try to mprotect the other bits of the pool with no access... + // we'd really like a version of mremap here that can unmap all the + // other pages in the chunk, but that does not exist, so we protect + // the other pages in this chunk such that they may neither be read, + // written nor executed, only the pages we're interested in for + // communications stay readable and writable + // + // if an OS does not support changing the protection of a part of an + // mmapped area, the mprotect calls below should just fail and not + // change any protection, so we're a little less safe against + // corruption, but everything should still work + if (Copy != s_mmapworks) { + unsigned char* p0 = reinterpret_cast<unsigned char*>(m_begin); + unsigned char* p1 = reinterpret_cast<unsigned char*>(p[0u]); + unsigned char* p2 = p1 + p.npages() * pagesize(); + unsigned char* p3 = reinterpret_cast<unsigned char*>(m_end); + if (p1 != p0) ::mprotect(p0, p1 - p0, PROT_NONE); + if (p2 != p3) ::mprotect(p2, p3 - p2, PROT_NONE); + } + m_parent = 0; + m_freelist.clear(); + m_nUsedGrp = 1; + p.m_pimpl->m_parent = 0; + m_begin = m_end = 0; + // commit suicide + delete this; + } + + PagePool::PagePool(unsigned nPgPerGroup) : + m_cursz(minsz), m_nPgPerGrp(nPgPerGroup) + { std::fill(m_szmap, m_szmap + ((maxsz - minsz) / szincr), 0); } + + PagePool::~PagePool() + { + m_freelist.clear(); + for (ChunkList::iterator it = m_chunks.begin(); m_chunks.end() != it; ++it) + delete *it; + m_chunks.clear(); + } + + void PagePool::zap(Pages& p) + { + // unmap all pages but those pointed to by p + m_freelist.clear(); + for (ChunkList::iterator it = m_chunks.begin(); m_chunks.end() != it; ++it) { + if ((*it)->contains(p)) { + (*it)->zap(p); + } else { + delete *it; + } + } + m_chunks.clear(); + std::fill(m_szmap, m_szmap + ((maxsz - minsz) / szincr), 0); + m_cursz = minsz; + } + + Pages PagePool::pop() + { + if (m_freelist.empty()) { + // allocate and register new chunk and put it on the freelist + const int sz = nextChunkSz(); + Chunk *c = new Chunk(this, + sz * m_nPgPerGrp * pagesize(), m_nPgPerGrp); + m_chunks.push_front(c); + m_freelist.push_back(c); + updateCurSz(sz, +1); + } + // get free element from first chunk on _freelist + Chunk* c = m_freelist.front(); + Pages p(c->pop()); + // full chunks are removed from _freelist + if (c->full()) m_freelist.pop_front(); + return p; + } + + void PagePool::release(PageChunk* chunk) + { + assert(chunk->empty()); + // find chunk on freelist and remove + ChunkList::iterator it = std::find( + m_freelist.begin(), m_freelist.end(), chunk); + if (m_freelist.end() == it) + throw Exception("PagePool::release(PageChunk*)", EINVAL); + m_freelist.erase(it); + // find chunk in m_chunks and remove + it = std::find(m_chunks.begin(), m_chunks.end(), chunk); + if (m_chunks.end() == it) + throw Exception("PagePool::release(PageChunk*)", EINVAL); + m_chunks.erase(it); + const unsigned sz = chunk->len() / (pagesize() * m_nPgPerGrp); + delete chunk; + updateCurSz(sz, -1); + } + + void PagePool::putOnFreeList(PageChunk* chunk) + { + assert(!chunk->full()); + m_freelist.push_back(chunk); + } + + void PagePool::updateCurSz(int sz, int incr) + { + m_szmap[(sz - minsz) / szincr] += incr; + m_cursz = minsz; + for (int i = (maxsz - minsz) / szincr; i--; ) { + if (m_szmap[i]) { + m_cursz += i * szincr; + break; + } + } + } + + int PagePool::nextChunkSz() const + { + // no chunks with space available, figure out chunk size + int sz = m_cursz; + if (m_chunks.empty()) { + // if we start allocating chunks, we start from minsz + sz = minsz; + } else { + if (minsz >= sz) { + // minimal sized chunks are always grown + sz = minsz + szincr; + } else { + if (1 != m_chunks.size()) { + // if we have more than one completely filled chunk, grow + sz += szincr; + } else { + // just one chunk left, try shrinking chunk size + sz -= szincr; + } + } + } + // clamp size to allowed range + if (sz > maxsz) sz = maxsz; + if (sz < minsz) sz = minsz; + return sz; + } +} + +// static BidirMMapPipe members +pthread_mutex_t BidirMMapPipe::s_openpipesmutex = PTHREAD_MUTEX_INITIALIZER; +std::list<BidirMMapPipe*> BidirMMapPipe::s_openpipes; +BidirMMapPipe_impl::PagePool* BidirMMapPipe::s_pagepool = 0; +unsigned BidirMMapPipe::s_pagepoolrefcnt = 0; + +BidirMMapPipe_impl::PagePool& BidirMMapPipe::pagepool() +{ + if (!s_pagepool) + s_pagepool = new BidirMMapPipe_impl::PagePool(TotPages); + return *s_pagepool; +} + +void BidirMMapPipe::teardownall(void) +{ + pthread_mutex_lock(&s_openpipesmutex); + while (!s_openpipes.empty()) { + BidirMMapPipe *p = s_openpipes.front(); + pthread_mutex_unlock(&s_openpipesmutex); + if (p->m_childPid) kill(p->m_childPid, SIGTERM); + p->doClose(true, true); + pthread_mutex_lock(&s_openpipesmutex); + } + pthread_mutex_unlock(&s_openpipesmutex); +} + +BidirMMapPipe::BidirMMapPipe(const BidirMMapPipe&) : + m_pages(pagepool().pop()) +{ + // free pages again + { BidirMMapPipe_impl::Pages p; p.swap(m_pages); } + if (!s_pagepoolrefcnt) { + delete s_pagepool; + s_pagepool = 0; + } +} + +BidirMMapPipe::BidirMMapPipe(bool useExceptions, bool useSocketpair) : + m_pages(pagepool().pop()), m_busylist(0), m_freelist(0), m_dirtylist(0), + m_inpipe(-1), m_outpipe(-1), m_flags(failbit), m_childPid(0), + m_parentPid(::getpid()) + +{ + ++s_pagepoolrefcnt; + assert(TotPages && 0 == (TotPages & 1) && TotPages <= 256); + int fds[4] = { -1, -1, -1, -1 }; + int myerrno; + static bool firstcall = true; + if (useExceptions) m_flags |= exceptionsbit; + + try { + if (firstcall) { + firstcall = false; + // register a cleanup handler to make sure all BidirMMapPipes are torn + // down, and child processes are sent a SIGTERM + if (0 != atexit(BidirMMapPipe::teardownall)) + throw Exception("atexit", errno); + } + + // build free lists + for (unsigned i = 1; i < TotPages; ++i) + m_pages[i - 1]->setNext(m_pages[i]); + m_pages[PagesPerEnd - 1]->setNext(0); + if (!useSocketpair) { + // create pipes + if (0 != ::pipe(&fds[0])) throw Exception("pipe", errno); + if (0 != ::pipe(&fds[2])) throw Exception("pipe", errno); + } else { + if (0 != ::socketpair(AF_UNIX, SOCK_STREAM, 0, &fds[0])) + throw Exception("socketpair", errno); + } + // fork the child + pthread_mutex_lock(&s_openpipesmutex); + char c; + switch ((m_childPid = ::fork())) { + case -1: // error in fork() + myerrno = errno; + pthread_mutex_unlock(&s_openpipesmutex); + m_childPid = 0; + throw Exception("fork", myerrno); + case 0: // child + // put the ends in the right place + if (-1 != fds[2]) { + // pair of pipes + if (-1 == ::close(fds[0]) || (-1 == ::close(fds[3]))) { + myerrno = errno; + pthread_mutex_unlock(&s_openpipesmutex); + throw Exception("close", myerrno); + } + fds[0] = fds[3] = -1; + m_outpipe = fds[1]; + m_inpipe = fds[2]; + } else { + // socket pair + if (-1 == ::close(fds[0])) { + myerrno = errno; + pthread_mutex_unlock(&s_openpipesmutex); + throw Exception("close", myerrno); + } + fds[0] = -1; + m_inpipe = m_outpipe = fds[1]; + } + // close other pipes our parent may have open - we have no business + // reading from/writing to those... + for (std::list<BidirMMapPipe*>::iterator it = s_openpipes.begin(); + s_openpipes.end() != it; ) { + BidirMMapPipe* p = *it; + it = s_openpipes.erase(it); + p->doClose(true, true); + } + pagepool().zap(m_pages); + s_pagepoolrefcnt = 0; + delete s_pagepool; + s_pagepool = 0; + s_openpipes.push_front(this); + pthread_mutex_unlock(&s_openpipesmutex); + // ok, put our pages on freelist + m_freelist = m_pages[PagesPerEnd]; + // handshare with other end (to make sure it's alive)... + c = 'C'; // ...hild + if (1 != xferraw(m_outpipe, &c, 1, ::write)) + throw Exception("handshake: xferraw write", EPIPE); + if (1 != xferraw(m_inpipe, &c, 1, ::read)) + throw Exception("handshake: xferraw read", EPIPE); + if ('P' != c) throw Exception("handshake", EPIPE); + break; + default: // parent + // put the ends in the right place + if (-1 != fds[2]) { + // pair of pipes + if (-1 == ::close(fds[1]) || -1 == ::close(fds[2])) { + myerrno = errno; + pthread_mutex_unlock(&s_openpipesmutex); + throw Exception("close", myerrno); + } + fds[1] = fds[2] = -1; + m_outpipe = fds[3]; + m_inpipe = fds[0]; + } else { + // socketpair + if (-1 == ::close(fds[1])) { + myerrno = errno; + pthread_mutex_unlock(&s_openpipesmutex); + throw Exception("close", myerrno); + } + fds[1] = -1; + m_inpipe = m_outpipe = fds[0]; + } + // put on list of open pipes (so we can kill child processes + // if things go wrong) + s_openpipes.push_front(this); + pthread_mutex_unlock(&s_openpipesmutex); + // ok, put our pages on freelist + m_freelist = m_pages[0u]; + // handshare with other end (to make sure it's alive)... + c = 'P'; // ...arent + if (1 != xferraw(m_outpipe, &c, 1, ::write)) + throw Exception("handshake: xferraw write", EPIPE); + if (1 != xferraw(m_inpipe, &c, 1, ::read)) + throw Exception("handshake: xferraw read", EPIPE); + if ('C' != c) throw Exception("handshake", EPIPE); + break; + } + // mark file descriptors for close on exec (we do not want to leak the + // connection to anything we happen to exec) + int fdflags = 0; + if (-1 == ::fcntl(m_outpipe, F_GETFD, &fdflags)) + throw Exception("fcntl", errno); + fdflags |= FD_CLOEXEC; + if (-1 == ::fcntl(m_outpipe, F_SETFD, fdflags)) + throw Exception("fcntl", errno); + if (m_inpipe != m_outpipe) { + if (-1 == ::fcntl(m_inpipe, F_GETFD, &fdflags)) + throw Exception("fcntl", errno); + fdflags |= FD_CLOEXEC; + if (-1 == ::fcntl(m_inpipe, F_SETFD, fdflags)) + throw Exception("fcntl", errno); + } + // ok, finally, clear the failbit + m_flags &= ~failbit; + // all done + } catch (const BidirMMapPipe::Exception& e) { + if (0 != m_childPid) kill(m_childPid, SIGTERM); + for (int i = 0; i < 4; ++i) + if (-1 != fds[i] && 0 != fds[i]) ::close(fds[i]); + { + // free resources associated with mmapped pages + BidirMMapPipe_impl::Pages p; p.swap(m_pages); + } + if (!--s_pagepoolrefcnt) { + delete s_pagepool; + s_pagepool = 0; + } + throw e; + } +} + +int BidirMMapPipe::close() +{ + assert(!(m_flags & failbit)); + return doClose(false); +} + +int BidirMMapPipe::doClose(bool force, bool holdlock) +{ + if (m_flags & failbit) return 0; + // flush data to be written + if (!force && -1 != m_outpipe && -1 != m_inpipe) flush(); + // shut down the write direction (no more writes from our side) + if (m_inpipe == m_outpipe) { + if (-1 != m_outpipe && !force && -1 == ::shutdown(m_outpipe, SHUT_WR)) + throw Exception("shutdown", errno); + m_outpipe = -1; + } else { + if (-1 != m_outpipe && -1 == ::close(m_outpipe)) + if (!force) throw Exception("close", errno); + m_outpipe = -1; + } + // shut down the write direction (no more writes from our side) + // drain anything the other end might still want to send + if (!force && -1 != m_inpipe) { + // **************** THIS IS EXTREMELY UGLY: **************** + // POLLHUP is not set reliably on pipe/socket shutdown on all + // platforms, unfortunately, so we poll for readability here until + // the other end closes, too + // + // the read loop below ensures that the other end sees the POLLIN that + // is set on shutdown instead, and goes ahead to close its end + // + // if we don't do this, and close straight away, the other end + // will catch a SIGPIPE or similar, and we don't want that + int err; + struct pollfd fds; + fds.fd = m_inpipe; + fds.events = POLLIN; + fds.revents = 0; + do { + while ((err = ::poll(&fds, 1, 1 << 20)) >= 0) { + if (fds.revents & (POLLERR | POLLHUP | POLLNVAL)) break; + if (fds.revents & POLLIN) { + char c; + if (1 > ::read(m_inpipe, &c, 1)) break; + } + } + } while (0 > err && EINTR == errno); + // ignore all other poll errors + } + // close read end + if (-1 != m_inpipe && -1 == ::close(m_inpipe)) + if (!force) throw Exception("close", errno); + m_inpipe = -1; + // unmap memory + try { + { BidirMMapPipe_impl::Pages p; p.swap(m_pages); } + if (!--s_pagepoolrefcnt) { + delete s_pagepool; + s_pagepool = 0; + } + } catch (const std::exception& e) { + if (!force) throw e; + } + m_busylist = m_freelist = m_dirtylist = 0; + // wait for child process + int retVal = 0; + if (isParent()) { + int tmp; + do { + tmp = waitpid(m_childPid, &retVal, 0); + } while (-1 == tmp && EINTR == errno); + if (-1 == tmp) + if (!force) throw Exception("waitpid", errno); + m_childPid = 0; + } + // remove from list of open pipes + if (!holdlock) pthread_mutex_lock(&s_openpipesmutex); + std::list<BidirMMapPipe*>::iterator it = std::find( + s_openpipes.begin(), s_openpipes.end(), this); + if (s_openpipes.end() != it) s_openpipes.erase(it); + if (!holdlock) pthread_mutex_unlock(&s_openpipesmutex); + m_flags |= failbit; + return retVal; +} + +BidirMMapPipe::~BidirMMapPipe() +{ doClose(false); } + +BidirMMapPipe::size_type BidirMMapPipe::xferraw( + int fd, void* addr, size_type len, + ssize_t (*xferfn)(int, void*, std::size_t)) +{ + size_type xferred = 0; + unsigned char* buf = reinterpret_cast<unsigned char*>(addr); + while (len) { + ssize_t tmp = xferfn(fd, buf, len); + if (tmp > 0) { + xferred += tmp; + len -= tmp; + buf += tmp; + continue; + } else if (0 == tmp) { + // check for end-of-file on pipe + break; + } else if (-1 == tmp) { + // ok some error occurred, so figure out if we want to retry of throw + switch (errno) { + default: + // if anything was transferred, return number of bytes + // transferred so far, we can start throwing on the next + // transfer... + if (xferred) return xferred; + // else throw + throw Exception("xferraw", errno); + case EAGAIN: // fallthrough intended +#if defined(EWOULDBLOCK) && EWOULDBLOCK != EAGAIN + case EWOULDBLOCK: // fallthrough intended +#endif + std::cerr << " ERROR: In " << __func__ << " (" << + __FILE__ << ", line " << __LINE__ << + "): expect transfer to block!" << std::endl; + case EINTR: + break; + } + continue; + } else { + throw Exception("xferraw: unexpected return value from read/write", + errno); + } + } + return xferred; +} + +void BidirMMapPipe::sendpages(Page* plist) +{ + if (plist) { + unsigned char pg = m_pages[plist]; + if (1 == xferraw(m_outpipe, &pg, 1, ::write)) { + if (BidirMMapPipe_impl::PageChunk::Copy == + BidirMMapPipe_impl::PageChunk::mmapVariety()) { + // ok, have to copy pages through pipe + for (Page* p = plist; p; p = p->next()) { + if (sizeof(Page) + p->size() != + xferraw(m_outpipe, p, sizeof(Page) + p->size(), + ::write)) { + throw Exception("sendpages: short write", EPIPE); + } + } + } + } else { + throw Exception("sendpages: short write", EPIPE); + } + } else { assert(plist); } +} + +unsigned BidirMMapPipe::recvpages() +{ + unsigned char pg; + unsigned retVal = 0; + Page *plisthead = 0, *plisttail = 0; + if (1 == xferraw(m_inpipe, &pg, 1, ::read)) { + plisthead = plisttail = m_pages[pg]; + // ok, have number of pages + if (BidirMMapPipe_impl::PageChunk::Copy == + BidirMMapPipe_impl::PageChunk::mmapVariety()) { + // ok, need to copy pages through pipe + for (; plisttail; ++retVal) { + Page* p = plisttail; + if (sizeof(Page) == xferraw(m_inpipe, p, sizeof(Page), + ::read)) { + plisttail = p->next(); + if (!p->size()) continue; + // break in case of read error + if (p->size() != xferraw(m_inpipe, p->begin(), p->size(), + ::read)) break; + } + } + } else { + retVal = lenPageList(plisthead); + } + } + // put list of pages we just received into correct lists (busy/free) + if (plisthead) feedPageLists(plisthead); + // ok, retVal contains the number of pages read, so put them on the + // correct lists + return retVal; +} + +unsigned BidirMMapPipe::recvpages_nonblock() +{ + struct pollfd fds; + fds.fd = m_inpipe; + fds.events = POLLIN; + fds.revents = 0; + unsigned retVal = 0; + do { + int rc = ::poll(&fds, 1, 0); + if (0 > rc) { + if (EINTR == errno) continue; + break; + } + if (1 == retVal && fds.revents & POLLIN && + !(fds.revents & (POLLNVAL | POLLERR))) { + // ok, we can read without blocking, so the other end has + // something for us + return recvpages(); + } else { + break; + } + } while (true); + return retVal; +} + +unsigned BidirMMapPipe::lenPageList(const Page* p) +{ + unsigned n = 0; + for ( ; p; p = p->next()) ++n; + return n; +} + +void BidirMMapPipe::feedPageLists(Page* plist) +{ + assert(plist); + // get end of busy list + Page *blend = m_busylist; + while (blend && blend->next()) blend = blend->next(); + // ok, might have to send free pages to other end, and (if we do have to + // send something to the other end) while we're at it, send any dirty + // pages which are completely full, too + Page *sendlisthead = 0, *sendlisttail = 0; + // loop over plist + while (plist) { + Page* p = plist; + plist = p->next(); + p->setNext(0); + if (p->size()) { + // busy page... + p->pos() = 0; + // put at end of busy list + if (blend) blend->setNext(p); + else m_busylist = p; + blend = p; + } else { + // free page... + // Very simple algorithm: once we're done with a page, we send it back + // where it came from. If it's from our end, we put it on the free list, if + // it's from the other end, we send it back. + if ((isParent() && m_pages[p] >= PagesPerEnd) || + (isChild() && m_pages[p] < PagesPerEnd)) { + // page "belongs" to other end + if (!sendlisthead) sendlisthead = p; + if (sendlisttail) sendlisttail->setNext(p); + sendlisttail = p; + } else { + // add page to freelist + p->setNext(m_freelist); + m_freelist = p; + } + } + } + // check if we have to send stuff to the other end + if (sendlisthead) { + // go through our list of dirty pages, and see what we can + // send along + Page* dp; + while ((dp = m_dirtylist) && dp->full()) { + Page* p = dp; + // move head of dirty list + m_dirtylist = p->next(); + // queue for sending + p->setNext(0); + sendlisttail->setNext(p); + sendlisttail = p; + } + // poll if the other end is still alive - this needs that we first + // close the write pipe of the other end when the remote end of the + // connection is shutting down in doClose; we'll see that because we + // get a POLLHUP on our inpipe + const int nfds = (m_outpipe == m_inpipe) ? 1 : 2; + struct pollfd fds[2]; + fds[0].fd = m_outpipe; + fds[0].events = fds[0].revents = 0; + if (m_outpipe != m_inpipe) { + fds[1].fd = m_inpipe; + fds[1].events = fds[1].revents = 0; + } else { + fds[0].events |= POLLIN; + } + int retVal = 0; + do { + retVal = ::poll(fds, nfds, 0); + if (0 > retVal && EINTR == errno) + continue; + break; + } while (true); + if (0 <= retVal) { + bool ok = !(fds[0].revents & (POLLERR | POLLNVAL | POLLHUP)); + if (m_outpipe != m_inpipe) { + ok = ok && !(fds[1].revents & (POLLERR | POLLNVAL | POLLHUP)); + } else { + if (ok && fds[0].revents & POLLIN) { + unsigned ret = recvpages(); + if (!ret) ok = false; + } + } + + if (ok) sendpages(sendlisthead); + // (if the pipe is dead already, we don't care that we leak the + // contents of the pages on the send list here, so that is why + // there's no else clause here) + } else { + throw Exception("feedPageLists: poll", errno); + } + } +} + +void BidirMMapPipe::markPageDirty(Page* p) +{ + assert(p); + assert(p == m_freelist); + // remove from freelist + m_freelist = p->next(); + p->setNext(0); + // append to dirty list + Page* dl = m_dirtylist; + while (dl && dl->next()) dl = dl->next(); + if (dl) dl->setNext(p); + else m_dirtylist = p; +} + +BidirMMapPipe::Page* BidirMMapPipe::busypage() +{ + // queue any pages available for reading we can without blocking + recvpages_nonblock(); + Page* p; + // if there are no busy pages, try to get them from the other end, + // block if we have to... + while (!(p = m_busylist)) if (!recvpages()) return 0; + return p; +} + +BidirMMapPipe::Page* BidirMMapPipe::dirtypage() +{ + // queue any pages available for reading we can without blocking + recvpages_nonblock(); + Page* p = m_dirtylist; + // go to end of dirty list + if (p) while (p->next()) p = p->next(); + if (!p || p->full()) { + // need to append free page, so get one + while (!(p = m_freelist)) if (!recvpages()) return 0; + markPageDirty(p); + } + return p; +} + +void BidirMMapPipe::flush() +{ return doFlush(true); } + +void BidirMMapPipe::doFlush(bool forcePartialPages) +{ + assert(!(m_flags & failbit)); + // build a list of pages to flush + Page *flushlisthead = 0, *flushlisttail = 0; + while (m_dirtylist) { + Page* p = m_dirtylist; + if (!forcePartialPages && !p->full()) break; + // remove dirty page from dirty list + m_dirtylist = p->next(); + p->setNext(0); + // and send it to other end + if (!flushlisthead) flushlisthead = p; + if (flushlisttail) flushlisttail->setNext(p); + flushlisttail = p; + } + if (flushlisthead) sendpages(flushlisthead); +} + +void BidirMMapPipe::purge() +{ + assert(!(m_flags & failbit)); + // join busy and dirty lists + { + Page *l = m_busylist; + while (l && l->next()) l = l->next(); + if (l) l->setNext(m_dirtylist); + else m_busylist = m_dirtylist; + } + // empty busy and dirty pages + for (Page* p = m_busylist; p; p = p->next()) p->size() = 0; + // put them on the free list + if (m_busylist) feedPageLists(m_busylist); + m_busylist = m_dirtylist = 0; +} + +BidirMMapPipe::size_type BidirMMapPipe::bytesReadableNonBlocking() +{ + // queue all pages waiting for consumption in the pipe before we give an + // answer + recvpages_nonblock(); + size_type retVal = 0; + for (Page* p = m_busylist; p; p = p->next()) + retVal += p->size() - p->pos(); + return retVal; +} + +BidirMMapPipe::size_type BidirMMapPipe::bytesWritableNonBlocking() +{ + // queue all pages waiting for consumption in the pipe before we give an + // answer + recvpages_nonblock(); + // check if we could write to the pipe without blocking (we need to know + // because we might need to check if flushing of dirty pages would block) + bool couldwrite = false; + { + struct pollfd fds; + fds.fd = m_outpipe; + fds.events = POLLOUT; + fds.revents = 0; + int retVal = 0; + do { + retVal = ::poll(&fds, 1, 0); + if (0 > retVal) { + if (EINTR == errno) continue; + throw Exception("bytesWritableNonBlocking: poll", errno); + } + if (1 == retVal && fds.revents & POLLOUT && + !(fds.revents & (POLLNVAL | POLLERR | POLLHUP))) + couldwrite = true; + break; + } while (true); + } + // ok, start counting bytes + size_type retVal = 0; + unsigned npages = 0; + // go through the dirty list + for (Page* p = m_dirtylist; p; p = p->next()) { + ++npages; + // if page only partially filled + if (!p->full()) + retVal += p->free(); + if (npages >= FlushThresh && !couldwrite) break; + } + // go through the free list + for (Page* p = m_freelist; p && (!m_dirtylist || + npages < FlushThresh || couldwrite); p = p->next()) { + ++npages; + retVal += Page::capacity(); + } + return retVal; +} + +BidirMMapPipe::size_type BidirMMapPipe::read(void* addr, size_type sz) +{ + assert(!(m_flags & failbit)); + size_type nread = 0; + unsigned char *ap = reinterpret_cast<unsigned char*>(addr); + try { + while (sz) { + // find next page to read from + Page* p = busypage(); + if (!p) { + m_flags |= eofbit; + return nread; + } + unsigned char* pp = p->begin() + p->pos(); + size_type csz = std::min(size_type(p->remaining()), sz); + std::copy(pp, pp + csz, ap); + nread += csz; + ap += csz; + sz -= csz; + p->pos() += csz; + assert(p->size() >= p->pos()); + if (p->size() == p->pos()) { + // if no unread data remains, page is free + m_busylist = p->next(); + p->setNext(0); + p->size() = 0; + feedPageLists(p); + } + } + } catch (const Exception& e) { + m_flags |= rderrbit; + if (m_flags & exceptionsbit) throw e; + } + return nread; +} + +BidirMMapPipe::size_type BidirMMapPipe::write(const void* addr, size_type sz) +{ + assert(!(m_flags & failbit)); + size_type written = 0; + const unsigned char *ap = reinterpret_cast<const unsigned char*>(addr); + try { + while (sz) { + // find next page to write to + Page* p = dirtypage(); + if (!p) { + m_flags |= eofbit; + return written; + } + unsigned char* pp = p->begin() + p->size(); + size_type csz = std::min(size_type(p->free()), sz); + std::copy(ap, ap + csz, pp); + written += csz; + ap += csz; + p->size() += csz; + sz -= csz; + assert(p->capacity() >= p->size()); + if (p->full()) { + // if page is full, see if we're above the flush threshold of + // 3/4 of our pages + if (lenPageList(m_dirtylist) >= FlushThresh) + doFlush(false); + } + } + } catch (const Exception& e) { + m_flags |= wrerrbit; + if (m_flags & exceptionsbit) throw e; + } + return written; +} + +int BidirMMapPipe::poll(BidirMMapPipe::PollVector& pipes, int timeout) +{ + // go through pipes, and change flags where we already know without really + // polling - stuff where we don't need poll to wait for its timeout in the + // OS... + bool canskiptimeout = false; + std::vector<unsigned> masks(pipes.size(), ~(Readable | Writable)); + std::vector<unsigned>::iterator mit = masks.begin(); + for (PollVector::iterator it = pipes.begin(); pipes.end() != it; + ++it, ++mit) { + PollEntry& pe = *it; + pe.revents = None; + // null pipe pointer or closed pipe is invalid + if (!pe.pipe || pe.pipe->closed()) pe.revents |= Invalid; + // check for error + if (pe.pipe->bad()) pe.revents |= Error; + // check for end of file + if (pe.pipe->eof()) pe.revents |= EndOfFile; + // check if readable + if (pe.events & Readable) { + *mit |= Readable; + if (pe.pipe->m_busylist) pe.revents |= Readable; + } + // check if writable + if (pe.events & Writable) { + *mit |= Writable; + if (pe.pipe->m_freelist) { + pe.revents |= Writable; + } else { + Page *dl = pe.pipe->m_dirtylist; + while (dl && dl->next()) dl = dl->next(); + if (dl && dl->pos() < Page::capacity()) + pe.revents |= Writable; + } + } + if (pe.revents) canskiptimeout = true; + } + // set up the data structures required for the poll syscall + std::vector<pollfd> fds; + fds.reserve(2 * pipes.size()); + std::map<int, PollEntry*> fds2pipes; + for (PollVector::const_iterator it = pipes.begin(); + pipes.end() != it; ++it) { + const PollEntry& pe = *it; + struct pollfd tmp; + fds2pipes.insert(std::make_pair((tmp.fd = pe.pipe->m_inpipe), + const_cast<PollEntry*>(&pe))); + tmp.events = tmp.revents = 0; + // we always poll for readability; this allows us to queue pages + // early + tmp.events |= POLLIN; + if (pe.pipe->m_outpipe != tmp.fd) { + // ok, it's a pair of pipes + fds.push_back(tmp); + fds2pipes.insert(std::make_pair( + unsigned(tmp.fd = pe.pipe->m_outpipe), + const_cast<PollEntry*>(&pe))); + tmp.events = 0; + + } + if (pe.events & Writable) tmp.events |= POLLOUT; + fds.push_back(tmp); + } + // poll + int retVal = 0; + do { + retVal = ::poll(&fds[0], fds.size(), canskiptimeout ? 0 : timeout); + if (0 > retVal) { + if (EINTR == errno) continue; + throw Exception("poll", errno); + } + break; + } while (true); + // fds may have changed state, so update... + for (std::vector<pollfd>::iterator it = fds.begin(); + fds.end() != it; ++it) { + pollfd& fe = *it; + //if (!fe.revents) continue; + --retVal; + PollEntry& pe = *fds2pipes[fe.fd]; +oncemore: + if (fe.revents & POLLNVAL && fe.fd == pe.pipe->m_inpipe) + pe.revents |= ReadInvalid; + if (fe.revents & POLLNVAL && fe.fd == pe.pipe->m_outpipe) + pe.revents |= WriteInvalid; + if (fe.revents & POLLERR && fe.fd == pe.pipe->m_inpipe) + pe.revents |= ReadError; + if (fe.revents & POLLERR && fe.fd == pe.pipe->m_outpipe) + pe.revents |= WriteError; + if (fe.revents & POLLHUP && fe.fd == pe.pipe->m_inpipe) + pe.revents |= ReadEndOfFile; + if (fe.revents & POLLHUP && fe.fd == pe.pipe->m_outpipe) + pe.revents |= WriteEndOfFile; + if ((fe.revents & POLLIN) && fe.fd == pe.pipe->m_inpipe && + !(fe.revents & (POLLNVAL | POLLERR))) { + // ok, there is at least one page for us to receive from the + // other end + if (0 == pe.pipe->recvpages()) continue; + // more pages there? + do { + int tmp = ::poll(&fe, 1, 0); + if (tmp > 0) goto oncemore; // yippie! I don't even feel bad! + if (0 > tmp) { + if (EINTR == errno) continue; + throw Exception("poll", errno); + } + break; + } while (true); + } + if (pe.pipe->m_busylist) pe.revents |= Readable; + if (fe.revents & POLLOUT && fe.fd == pe.pipe->m_outpipe) { + if (pe.pipe->m_freelist) { + pe.revents |= Writable; + } else { + Page *dl = pe.pipe->m_dirtylist; + while (dl && dl->next()) dl = dl->next(); + if (dl && dl->pos() < Page::capacity()) + pe.revents |= Writable; + } + } + } + // apply correct masks, and count pipes with pending events + int npipes = 0; + mit = masks.begin(); + for (PollVector::iterator it = pipes.begin(); + pipes.end() != it; ++it, ++mit) + if ((it->revents &= *mit)) ++npipes; + return npipes; +} + +BidirMMapPipe& BidirMMapPipe::operator<<(const char* str) +{ + size_t sz = std::strlen(str); + *this << sz; + if (sz) write(str, sz); + return *this; +} + +BidirMMapPipe& BidirMMapPipe::operator>>(char* (&str)) +{ + size_t sz = 0; + *this >> sz; + if (good() && !eof()) { + str = reinterpret_cast<char*>(std::realloc(str, sz + 1)); + if (!str) throw Exception("realloc", errno); + if (sz) read(str, sz); + str[sz] = 0; + } + return *this; +} + +BidirMMapPipe& BidirMMapPipe::operator<<(const std::string& str) +{ + size_t sz = str.size(); + *this << sz; + write(str.data(), sz); + return *this; +} + +BidirMMapPipe& BidirMMapPipe::operator>>(std::string& str) +{ + str.clear(); + size_t sz = 0; + *this >> sz; + if (good() && !eof()) { + str.reserve(sz); + for (unsigned char c; sz--; str.push_back(c)) *this >> c; + } + return *this; +} + +END_NAMESPACE_ROOFIT + +#ifdef TEST_BIDIRMMAPPIPE +using namespace RooFit; + +int simplechild(BidirMMapPipe& pipe) +{ + // child does an echo loop + while (pipe.good() && !pipe.eof()) { + // read a string + std::string str; + pipe >> str; + if (!pipe) return -1; + if (pipe.eof()) break; + if (!str.empty()) { + std::cout << "[CHILD] : read: " << str << std::endl; + str = "... early in the morning?"; + } + pipe << str << BidirMMapPipe::flush; + // did our parent tell us to shut down? + if (str.empty()) break; + if (!pipe) return -1; + if (pipe.eof()) break; + std::cout << "[CHILD] : wrote: " << str << std::endl; + } + pipe.close(); + return 0; +} + +#include <sstream> +int randomchild(BidirMMapPipe& pipe) +{ + // child sends out something at random intervals + ::srand48(::getpid()); + { + // wait for parent's go ahead signal + std::string s; + pipe >> s; + } + // no shutdown sequence needed on this side - we're producing the data, + // and the parent can just read until we're done (when it'll get EOF) + for (int i = 0; i < 5; ++i) { + // sleep a random time between 0 and .9 seconds + ::usleep(int(1e6 * ::drand48())); + std::ostringstream buf; + buf << "child pid " << ::getpid() << " sends message " << i; + std::string str = buf.str(); + std::cout << "[CHILD] : " << str << std::endl; + pipe << str << BidirMMapPipe::flush; + if (!pipe) return -1; + if (pipe.eof()) break; + } + // tell parent we're shutting down + pipe << "" << BidirMMapPipe::flush; + // wait for parent to acknowledge + std::string s; + pipe >> s; + pipe.close(); + return 0; +} + +int benchchildrtt(BidirMMapPipe& pipe) +{ + // child does the equivalent of listening for pings and sending the + // packet back + char* str = 0; + while (pipe && !pipe.eof()) { + pipe >> str; + if (!pipe) { + std::free(str); + pipe.close(); + return -1; + } + if (pipe.eof()) break; + pipe << str << BidirMMapPipe::flush; + // if we have just completed the shutdown handshake, we break here + if (!std::strlen(str)) break; + } + std::free(str); + pipe.close(); + return 0; +} + +int benchchildsink(BidirMMapPipe& pipe) +{ + // child behaves like a sink + char* str = 0; + while (pipe && !pipe.eof()) { + pipe >> str; + if (!std::strlen(str)) break; + } + pipe << "" << BidirMMapPipe::flush; + std::free(str); + pipe.close(); + return 0; +} + +int benchchildsource(BidirMMapPipe& pipe) +{ + // child behaves like a source + char* str = 0; + for (unsigned i = 0; i <= 24; ++i) { + str = reinterpret_cast<char*>(std::realloc(str, (1 << i) + 1)); + std::memset(str, '4', 1 << i); + str[1 << i] = 0; + for (unsigned j = 0; j < 1 << 7; ++j) { + pipe << str; + if (!pipe || pipe.eof()) { + std::free(str); + pipe.close(); + return -1; + } + } + // tell parent we're done with this block size + pipe << "" << BidirMMapPipe::flush; + } + // tell parent to shut down + pipe << "" << BidirMMapPipe::flush; + std::free(str); + pipe.close(); + return 0; +} + +BidirMMapPipe* spawnChild(int (*childexec)(BidirMMapPipe&)) +{ + // create a pipe with the given child at the remote end + BidirMMapPipe *p = new BidirMMapPipe(); + if (p->isChild()) { + int retVal = childexec(*p); + delete p; + std::exit(retVal); + } + return p; +} + +#include <sys/time.h> +#include <iomanip> +int main() +{ + // simple echo loop test + { + std::cout << "[PARENT]: simple challenge-response test, " + "one child:" << std::endl; + BidirMMapPipe* pipe = spawnChild(simplechild); + for (int i = 0; i < 5; ++i) { + std::string str("What shall we do with a drunken sailor..."); + *pipe << str << BidirMMapPipe::flush; + if (!*pipe) return -1; + std::cout << "[PARENT]: wrote: " << str << std::endl; + *pipe >> str; + if (!*pipe) return -1; + std::cout << "[PARENT]: read: " << str << std::endl; + } + // send shutdown string + *pipe << "" << BidirMMapPipe::flush; + // wait for shutdown handshake + std::string s; + *pipe >> s; + int retVal = pipe->close(); + std::cout << "[PARENT]: exit status of child: " << retVal << + std::endl; + if (retVal) return retVal; + delete pipe; + } + // simple poll test - children send 5 results in random intervals + { + unsigned nch = 20; + std::cout << std::endl << "[PARENT]: polling test, " << nch << + " children:" << std::endl; + typedef BidirMMapPipe::PollEntry PollEntry; + // poll data structure + BidirMMapPipe::PollVector pipes; + pipes.reserve(nch); + // spawn children + for (unsigned i = 0; i < nch; ++i) { + std::cout << "[PARENT]: spawning child " << i << std::endl; + pipes.push_back(PollEntry(spawnChild(randomchild), + BidirMMapPipe::Readable)); + } + // wake children up + std::cout << "[PARENT]: waking up children" << std::endl; + for (unsigned i = 0; i < nch; ++i) + *pipes[i].pipe << "" << BidirMMapPipe::flush; + std::cout << "[PARENT]: waiting for events on children's pipes" << std::endl; + // while at least some children alive + while (!pipes.empty()) { + // poll, wait until status change (infinite timeout) + int npipes = BidirMMapPipe::poll(pipes, -1); + // scan for pipes with changed status + for (std::vector<PollEntry>::iterator it = pipes.begin(); + npipes && pipes.end() != it; ) { + if (!it->revents) { + // unchanged, next one + ++it; + continue; + } + --npipes; // maybe we can stop early... + // read from pipes which are readable + if (it->revents & BidirMMapPipe::Readable) { + std::string s; + *(it->pipe) >> s; + if (!s.empty()) { + std::cout << "[PARENT]: Read from pipe " << it->pipe << + ": " << s << std::endl; + ++it; + continue; + } else { + // child is shutting down... + *(it->pipe) << "" << BidirMMapPipe::flush; + goto childcloses; + } + } + // retire pipes with error or end-of-file condition + if (it->revents & (BidirMMapPipe::Error | + BidirMMapPipe::EndOfFile | + BidirMMapPipe::Invalid)) { + std::cerr << "[DEBUG]: Event on pipe " << it->pipe << + " revents" << + ((it->revents & BidirMMapPipe::Readable) ? " Readable" : "") << + ((it->revents & BidirMMapPipe::Writable) ? " Writable" : "") << + ((it->revents & BidirMMapPipe::ReadError) ? " ReadError" : "") << + ((it->revents & BidirMMapPipe::WriteError) ? " WriteError" : "") << + ((it->revents & BidirMMapPipe::ReadEndOfFile) ? " ReadEndOfFile" : "") << + ((it->revents & BidirMMapPipe::WriteEndOfFile) ? " WriteEndOfFile" : "") << + ((it->revents & BidirMMapPipe::ReadInvalid) ? " ReadInvalid" : "") << + ((it->revents & BidirMMapPipe::WriteInvalid) ? " WriteInvalid" : "") << + std::endl; +childcloses: + int retVal = it->pipe->close(); + std::cout << "[PARENT]: child exit status: " << + retVal << ", number of children still alive: " << + (pipes.size() - 1) << std::endl; + if (retVal) return retVal; + delete it->pipe; + it = pipes.erase(it); + continue; + } + } + } + } + // little benchmark - round trip time + { + std::cout << std::endl << "[PARENT]: benchmark: round-trip times vs block size" << std::endl; + for (unsigned i = 0; i <= 24; ++i) { + char *s = new char[1 + (1 << i)]; + std::memset(s, 'A', 1 << i); + s[1 << i] = 0; + const unsigned n = 1 << 7; + double avg = 0., min = 1e42, max = -1e42; + BidirMMapPipe *pipe = spawnChild(benchchildrtt); + for (unsigned j = n; j--; ) { + struct timeval t1; + ::gettimeofday(&t1, 0); + *pipe << s << BidirMMapPipe::flush; + if (!*pipe || pipe->eof()) break; + *pipe >> s; + if (!*pipe || pipe->eof()) break; + struct timeval t2; + ::gettimeofday(&t2, 0); + t2.tv_sec -= t1.tv_sec; + t2.tv_usec -= t1.tv_usec; + double dt = 1e-6 * double(t2.tv_usec) + double(t2.tv_sec); + if (dt < min) min = dt; + if (dt > max) max = dt; + avg += dt; + } + // send a shutdown string + *pipe << "" << BidirMMapPipe::flush; + // get child's shutdown ok + *pipe >> s; + avg /= double(n); + avg *= 1e6; min *= 1e6; max *= 1e6; + int retVal = pipe->close(); + if (retVal) { + std::cout << "[PARENT]: child exited with code " << retVal << std::endl; + return retVal; + } + delete pipe; + // there is a factor 2 in the formula for the transfer rate below, + // because we transfer data of twice the size of the block - once + // to the child, and once for the return trip + std::cout << "block size " << std::setw(9) << (1 << i) << + " avg " << std::setw(7) << avg << " us min " << + std::setw(7) << min << " us max " << std::setw(7) << max << + "us speed " << std::setw(9) << + 2. * (double(1 << i) / double(1 << 20) / (1e-6 * avg)) << + " MB/s" << std::endl; + delete[] s; + } + std::cout << "[PARENT]: all children had exit code 0" << std::endl; + } + // little benchmark - child as sink + { + std::cout << std::endl << "[PARENT]: benchmark: raw transfer rate with child as sink" << std::endl; + for (unsigned i = 0; i <= 24; ++i) { + char *s = new char[1 + (1 << i)]; + std::memset(s, 'A', 1 << i); + s[1 << i] = 0; + const unsigned n = 1 << 7; + double avg = 0., min = 1e42, max = -1e42; + BidirMMapPipe *pipe = spawnChild(benchchildsink); + for (unsigned j = n; j--; ) { + struct timeval t1; + ::gettimeofday(&t1, 0); + // streaming mode - we do not flush here + *pipe << s; + if (!*pipe || pipe->eof()) break; + struct timeval t2; + ::gettimeofday(&t2, 0); + t2.tv_sec -= t1.tv_sec; + t2.tv_usec -= t1.tv_usec; + double dt = 1e-6 * double(t2.tv_usec) + double(t2.tv_sec); + if (dt < min) min = dt; + if (dt > max) max = dt; + avg += dt; + } + // send a shutdown string + *pipe << "" << BidirMMapPipe::flush; + // get child's shutdown ok + *pipe >> s; + avg /= double(n); + avg *= 1e6; min *= 1e6; max *= 1e6; + int retVal = pipe->close(); + if (retVal) { + std::cout << "[PARENT]: child exited with code " << retVal << std::endl; + return retVal; + } + delete pipe; + std::cout << "block size " << std::setw(9) << (1 << i) << + " avg " << std::setw(7) << avg << " us min " << + std::setw(7) << min << " us max " << std::setw(7) << max << + "us speed " << std::setw(9) << + (double(1 << i) / double(1 << 20) / (1e-6 * avg)) << + " MB/s" << std::endl; + delete[] s; + } + std::cout << "[PARENT]: all children had exit code 0" << std::endl; + } + // little benchmark - child as source + { + std::cout << std::endl << "[PARENT]: benchmark: raw transfer rate with child as source" << std::endl; + char *s = 0; + double avg = 0., min = 1e42, max = -1e42; + unsigned n = 0, bsz = 0; + BidirMMapPipe *pipe = spawnChild(benchchildsource); + while (*pipe && !pipe->eof()) { + struct timeval t1; + ::gettimeofday(&t1, 0); + // streaming mode - we do not flush here + *pipe >> s; + if (!*pipe || pipe->eof()) break; + struct timeval t2; + ::gettimeofday(&t2, 0); + t2.tv_sec -= t1.tv_sec; + t2.tv_usec -= t1.tv_usec; + double dt = 1e-6 * double(t2.tv_usec) + double(t2.tv_sec); + if (std::strlen(s)) { + ++n; + if (dt < min) min = dt; + if (dt > max) max = dt; + avg += dt; + bsz = std::strlen(s); + } else { + if (!n) break; + // next block size + avg /= double(n); + avg *= 1e6; min *= 1e6; max *= 1e6; + + std::cout << "block size " << std::setw(9) << bsz << + " avg " << std::setw(7) << avg << " us min " << + std::setw(7) << min << " us max " << std::setw(7) << + max << "us speed " << std::setw(9) << + (double(bsz) / double(1 << 20) / (1e-6 * avg)) << + " MB/s" << std::endl; + n = 0; + avg = 0.; + min = 1e42; + max = -1e42; + } + } + int retVal = pipe->close(); + std::cout << "[PARENT]: child exited with code " << retVal << std::endl; + if (retVal) return retVal; + delete pipe; + std::free(s); + } + return 0; +} +#endif // TEST_BIDIRMMAPPIPE +#endif // _WIN32 + +// vim: ft=cpp:sw=4:tw=78 diff --git a/roofit/roofitcore/src/BidirMMapPipe.h b/roofit/roofitcore/src/BidirMMapPipe.h new file mode 100644 index 0000000000000..84569d7f0421a --- /dev/null +++ b/roofit/roofitcore/src/BidirMMapPipe.h @@ -0,0 +1,977 @@ +/** @file BidirMMapPipe.h + * + * header file for BidirMMapPipe, a class which forks off a child process and + * serves as communications channel between parent and child + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-07-07 + */ + +#ifndef BIDIRMMAPPIPE_H +#define BIDIRMMAPPIPE_H + +#include <unistd.h> // for ssize_t + +#include <list> +#include <vector> +#include <cassert> +#include <cstring> + +#define BEGIN_NAMESPACE_ROOFIT namespace RooFit { +#define END_NAMESPACE_ROOFIT } + +BEGIN_NAMESPACE_ROOFIT + +/// namespace for implementation details of BidirMMapPipe +namespace BidirMMapPipe_impl { + // forward declarations + class BidirMMapPipeException; + class Page; + class PagePool; + class Pages; + + /** @brief class representing a chunk of pages + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-07-24 + * + * allocating pages from the OS happens in chunks in order to not exhaust + * the maximum allowed number of memory mappings per process; this class + * takes care of such a chunk + * + * a page chunk allows callers to obtain or release pages in groups of + * continuous pages of fixed size + */ + class PageChunk { + public: + /// type of mmap support found + typedef enum { + Unknown, ///< don't know yet what'll work + Copy, ///< mmap doesn't work, have to copy back and forth + FileBacked, ///< mmapping a temp file works + DevZero, ///< mmapping /dev/zero works + Anonymous ///< anonymous mmap works + } MMapVariety; + + private: + static unsigned s_pagesize; ///< system page size (run-time determined) + /// mmap variety that works on this system + static MMapVariety s_mmapworks; + + /// convenience typedef + typedef BidirMMapPipeException Exception; + + void* m_begin; ///< pointer to start of mmapped area + void* m_end; ///< pointer one behind end of mmapped area + // FIXME: cannot keep freelist inline - other end may need that + // data, and we'd end up overwriting the page header + std::list<void*> m_freelist; ///< free pages list + PagePool* m_parent; ///< parent page pool + unsigned m_nPgPerGrp; ///< number of pages per group + unsigned m_nUsedGrp; ///< number of used page groups + + /// determine page size at run time + static unsigned getPageSize(); + + /// mmap pages, len is length of mmapped area in bytes + static void* dommap(unsigned len); + /// munmap pages p, len is length of mmapped area in bytes + static void domunmap(void* p, unsigned len); + /// forbid copying + PageChunk(const PageChunk&) {} + /// forbid assignment + PageChunk& operator=(const PageChunk&) { return *this; } + public: + /// return the page size of the system + static unsigned pagesize() { return s_pagesize; } + /// return mmap variety support found + static MMapVariety mmapVariety() { return s_mmapworks; } + + /// constructor + PageChunk(PagePool* parent, unsigned length, unsigned nPgPerGroup); + + /// destructor + ~PageChunk(); + + /// return if p is contained in this PageChunk + bool contains(const Pages& p) const; + + /// pop a group of pages off the free list + Pages pop(); + + /// push a group of pages onto the free list + void push(const Pages& p); + + /// return length of chunk + unsigned len() const + { + return reinterpret_cast<unsigned char*>(m_end) - + reinterpret_cast<unsigned char*>(m_begin); + } + /// return number of pages per page group + unsigned nPagesPerGroup() const { return m_nPgPerGrp; } + + /// return true if no used page groups in this chunk + bool empty() const { return !m_nUsedGrp; } + + /// return true if no free page groups in this chunk + bool full() const { return m_freelist.empty(); } + + /// free all pages except for those pointed to by p + void zap(Pages& p); + }; + + /** @brief handle class for a number of Pages + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-07-24 + * + * the associated pages are continuous in memory + */ + class Pages { + private: + /// implementation + typedef struct { + PageChunk *m_parent; ///< pointer to parent pool + Page* m_pages; ///< pointer to first page + unsigned m_refcnt; ///< reference counter + unsigned char m_npages; ///< length in pages + } impl; + public: + /// default constructor + Pages() : m_pimpl(0) { } + + /// destructor + ~Pages(); + + /** @brief copy constructor + * + * copy Pages handle to new object - old object loses ownership, + * and becomes a dangling handle + */ + Pages(const Pages& other); + + /** @brief assignment operator + * + * assign Pages handle to new object - old object loses ownership, + * and becomes a dangling handle + */ + Pages& operator=(const Pages& other); + + /// return page size + static unsigned pagesize(); + + /// return number of pages accessible + unsigned npages() const { return m_pimpl->m_npages; } + + /// return page number pageno + Page* page(unsigned pgno) const; + + /// return page number pageno + Page* operator[](unsigned pgno) const { return page(pgno); } + + /// perform page to page number mapping + unsigned pageno(Page* p) const; + + /// perform page to page number mapping + unsigned operator[](Page* p) const { return pageno(p); } + + /// swap with other's contents + void swap(Pages& other) + { + impl* tmp = other.m_pimpl; + other.m_pimpl = m_pimpl; + m_pimpl = tmp; + } + + private: + /// page pool is our friend - it's allowed to construct Pages + friend class BidirMMapPipe_impl::PageChunk; + + /// pointer to implementation + impl* m_pimpl; + + /// constructor + Pages(PageChunk* parent, Page* pages, unsigned npg); + }; +} + +/** @brief BidirMMapPipe creates a bidirectional channel between the current + * process and a child it forks. + * + * @author Manuel Schiller <manuel.schiller@nikhef.nl> + * @date 2013-07-07 + * + * This class creates a bidirectional channel between this process and a child + * it creates with fork(). + * + * The channel is comrised of a small shared pool of buffer memory mmapped into + * both process spaces, and two pipes to synchronise the exchange of data. The + * idea behind using the pipes at all is to have some primitive which we can + * block on without having to worry about atomic operations or polling, leaving + * these tasks to the OS. In case the anonymous mmap cannot be performed on the + * OS the code is running on (for whatever reason), the code falls back to + * mmapping /dev/zero, mmapping a temporary file, or (if those all fail), a + * dynamically allocated buffer which is then transmitted through the pipe(s), + * a slightly slower alternative (because the data is copied more often). + * + * The channel supports five major operations: read(), write(), flush(), + * purge() and close(). Reading and writing may block until the required buffer + * space is available. Writes may queue up data to be sent to the other end + * until either enough pages are full, or the user calls flush which forces + * any unsent buffers to be sent to the other end. flush forces any data that + * is to be sent to be sent. purge discards any buffered data waiting to be + * read and/or sent. Closing the channel on the child returns zero, closing it + * on the parent returns the child's exit status. + * + * The class also provides operator<< and operator>> for C++-style I/O for + * basic data types (bool, char, short, int, long, long long, float, double + * and their unsigned counterparts). Data is transmitted binary (i.e. no + * formatting to strings like std::cout does). There are also overloads to + * support C-style zero terminated strings and std::string. In terms of + * performance, the former is to be preferred. + * + * If the caller needs to multiplex input and output to/from several pipes, the + * class provides the poll() method which allows to block until an event occurs + * on any of the polled pipes. + * + * After the BidirMMapPipe is closed, no further operations may be performed on + * that object, save for the destructor which may still be called. + * + * If the BidirMMapPipe has not properly been closed, the destructor will call + * close. However, the exit code of the child is lost in that case. + * + * Closing the object causes the mmapped memory to be unmapped and the two + * pipes to be closed. We also install an atexit handler in the process of + * creating BidirMMapPipes. This ensures that when the current process + * terminates, a SIGTERM signal is sent to the child processes created for all + * unclosed pipes to avoid leaving zombie processes in the OS's process table. + * + * BidirMMapPipe creation, closing and destruction are thread safe. If the + * BidirMMapPipe is used in more than one thread, the other operations have to + * be protected with a mutex (or something similar), though. + * + * End of file (other end closed its pipe, or died) is indicated with the eof() + * method, serious I/O errors set a flags (bad(), fail()), and also throw + * exceptions. For normal read/write operations, they can be suppressed (i.e. + * error reporting only using flags) with a constructor argument. + * + * Technicalities: + * - there is a pool of mmapped pages, half the pages are allocated to the + * parent process, half to the child + * - when one side has accumulated enough data (or a flush forces dirty pages + * out to the other end), it sends these pages to the other end by writing a + * byte containing the page number into the pipe + * - the other end (which has the pages mmapped, too) reads the page number(s) + * and puts the corresponding pages on its busy list + * - as the other ends reads, it frees busy pages, and eventually tries to put + * them on the its list; if a page belongs to the other end of the + * connection, it is sent back + * - lists of pages are sent across the pipe, not individual pages, in order + * to minimise the number of read/write operations needed + * - when mmap works properly, only one bytes containing the page number of + * the page list head is sent back and forth; the contents of that page + * allow to access the rest of the page list sent, and page headers on the + * list tell the receiving end if the page is free or has to be added to the + * busy list + * - when mmap does not work, we transfer one byte to indicate the head of the + * page list sent, and for each page on the list of sent pages, the page + * header and the page payload is sent (if the page is free, we only + * transmit the page header, and we never transmit more payload than + * the page actually contains) + * - in the child, all open BidirMMapPipes but the current one are closed. this + * is done for two reasons: first, to conserve file descriptors and address + * space. second, if more than one process is meant to use such a + * BidirMMapPipe, synchronisation issues arise which can lead to bugs that + * are hard to find and understand. it's much better to come up with a design + * which does not need pipes to be shared among more than two processes. + * + * Here is a trivial example of a parent and a child talking to each other over + * a BidirMMapPipe: + * @code + * #include <string> + * #include <iostream> + * #include <cstdlib> + * + * #include "BidirMMapPipe.h" + * + * int simplechild(BidirMMapPipe& pipe) + * { + * // child does an echo loop + * while (pipe.good() && !pipe.eof()) { + * // read a string + * std::string str; + * pipe >> str; + * if (!pipe) return -1; + * if (pipe.eof()) break; + * // check if parent wants us to shut down + * if (!str.empty()) { + * std::cout << "[CHILD] : read: " << str << std::endl; + * str = "... early in the morning?"; + * } + * pipe << str << BidirMMapPipe::flush; + * if (str.empty()) break; + * if (!pipe) return -1; + * std::cout << "[CHILD] : wrote: " << str << std::endl; + * } + * // send shutdown request acknowledged + * pipe << "" << BidirMMapPipe::flush; + * + * pipe.close(); + * return 0; + * } + * + * BidirMMapPipe* spawnChild(int (*childexec)(BidirMMapPipe&)) + * { + * BidirMMapPipe *p = new BidirMMapPipe(); + * if (p->isChild()) { + * int retVal = childexec(*p); + * delete p; + * std::exit(retVal); + * } + * return p; + * } + * + * int main() + * { + * std::cout << "[PARENT]: simple challenge-response test, one child:" << + * std::endl; + * BidirMMapPipe* pipe = spawnChild(simplechild); + * for (int i = 0; i < 5; ++i) { + * std::string str("What shall we do with a drunken sailor..."); + * *pipe << str << BidirMMapPipe::flush; + * if (!*pipe) return -1; + * std::cout << "[PARENT]: wrote: " << str << std::endl; + * *pipe >> str; + * if (!*pipe) return -1; + * std::cout << "[PARENT]: read: " << str << std::endl; + * } + * // ask child to shut down + * pipe << "" << BidirMMapPipe::flush; + * // wait for it to see the shutdown request + * std::string s; + * pipe >> s; + * std::cout << "[PARENT]: exit status of child: " << pipe->close() << + * std::endl; + * delete pipe; + * return 0; + * } + * @endcode + * + * When designing your own protocols to use over the pipe, there are a few + * things to bear in mind: + * - Do as http does: When building a request, send all the options and + * properties of that request with the request itself in a single go (one + * flush). Then, the server has everything it needs, and hopefully, it'll + * shut up for a while and to let the client do something useful in the + * meantime... The same goes when the server replies to the request: include + * everything there is to know about the result of the request in the reply. + * - The expensive operation should be the request that is made, all other + * operations should somehow be formulated as options or properties to that + * request. + * - Include a shutdown handshake in whatever protocol you send over the + * pipe. That way, you can shut things down in a controlled way. Otherwise, + * and depending on your OS's scheduling quirks, you may catch a SIGPIPE if + * one end closes its pipe while the other is still trying to read. + */ +class BidirMMapPipe { +#ifndef _WIN32 + public: + /// type used to represent sizes + typedef std::size_t size_type; + /// convenience typedef for BidirMMapPipeException + typedef BidirMMapPipe_impl::BidirMMapPipeException Exception; + /// flag bits for partial C++ iostream compatibility + enum { + eofbit = 1, ///< end of file reached + failbit = 2, ///< logical failure (e.g. pipe closed) + rderrbit = 4, ///< read error + wrerrbit = 8, ///< write error + badbit = rderrbit | wrerrbit, ///< general I/O error + exceptionsbit = 16 ///< error reporting with exceptions + }; + + /** @brief constructor (forks!) + * + * Creates a bidirectional communications channel between this process + * and a child the constructor forks. On return from the constructor, + * isParent() and isChild() can be used to tell the parent end from the + * child end of the pipe. In the child, all other open BidirMMapPipes + * are closed. + * + * @param useExceptions read()/write() error reporting also done using + * exceptions + * @param useSocketpair use a socketpair instead of a pair or pipes + * + * Normally, exceptions are thrown for all serious I/O errors (apart + * from end of file). Setting useExceptions to false will force the + * read() and write() methods to only report serious I/O errors using + * flags. + * + * When useSocketpair is true, use a pair of Unix domain sockets + * created using socketpair instead a pair of pipes. The advantage is + * that only one pair of file descriptors is needed instead of two + * pairs which are needed for the pipe pair. Performance should very + * similar on most platforms, especially if mmap works, since only + * very little data is sent through the pipe(s)/socketpair. + */ + BidirMMapPipe(bool useExceptions = true, bool useSocketpair = false); + + /** @brief destructor + * + * closes this end of pipe + */ + ~BidirMMapPipe(); + + /** @brief read from pipe + * + * @param addr where to put read data + * @param sz size of data to read (in bytes) + * @returns size of data read, or 0 in case of end-of-file + * + * read may block until data from other end is available. It will + * return 0 if the other end closed the pipe. + */ + size_type read(void* addr, size_type sz); + + /** @brief wirte to pipe + * + * @param addr where to get data to write from + * @param sz size of data to write (in bytes) + * @returns size of data written, or 0 in case of end-of-file + * + * write may block until data can be written to other end (depends a + * bit on available buffer space). It will return 0 if the other end + * closed the pipe. The data is queued to be written on the next + * convenient occasion, or it can be forced out with flush(). + */ + size_type write(const void* addr, size_type sz); + + /** @brief flush buffers with unwritten data + * + * This forces unwritten data to be written to the other end. The call + * will block until this has been done (or the attempt failed with an + * error). + */ + void flush(); + + /** @brief purge buffered data waiting to be read and/or written + * + * Discards all internal buffers. + */ + void purge(); + + /** @brief number of bytes that can be read without blocking + * + * @returns number of bytes that can be read without blocking + */ + size_type bytesReadableNonBlocking(); + + /** @brief number of bytes that can be written without blocking + * + * @returns number of bytes that can be written without blocking + */ + size_type bytesWritableNonBlocking(); + + /** @brief flush buffers, close pipe + * + * Flush buffers, discard unread data, closes the pipe. If the pipe is + * in the parent process, it waits for the child. + * + * @returns exit code of child process in parent, zero in child + */ + int close(); + + /** @brief return PID of the process on the other end of the pipe + * + * @returns PID of the process running on the remote end + */ + pid_t pidOtherEnd() const + { return isChild() ? m_parentPid : m_childPid; } + + /// condition flags for poll + enum PollFlags { + None = 0, ///< nothing special on this pipe + Readable = 1, ///< pipe has data for reading + Writable = 2, ///< pipe can be written to + ReadError = 4, ///< pipe error read end + WriteError = 8, ///< pipe error Write end + Error = ReadError | WriteError, ///< pipe error + ReadEndOfFile = 32, ///< read pipe in end-of-file state + WriteEndOfFile = 64,///< write pipe in end-of-file state + EndOfFile = ReadEndOfFile | WriteEndOfFile, ///< end of file + ReadInvalid = 64, ///< read end of pipe invalid + WriteInvalid = 128, ///< write end of pipe invalid + Invalid = ReadInvalid | WriteInvalid ///< invalid pipe + }; + + /// for poll() interface + class PollEntry { + public: + BidirMMapPipe* pipe; ///< pipe of interest + unsigned events; ///< events of interest (or'ed bitmask) + unsigned revents; ///< events that happened (or'ed bitmask) + /// poll a pipe for all events + PollEntry(BidirMMapPipe* _pipe) : + pipe(_pipe), events(None), revents(None) { } + /// poll a pipe for specified events + PollEntry(BidirMMapPipe* _pipe, int _events) : + pipe(_pipe), events(_events), revents(None) { } + }; + /// convenience typedef for poll() interface + typedef std::vector<PollEntry> PollVector; + + /** @brief poll a set of pipes for events (ready to read from, ready to + * write to, error) + * + * @param pipes set of pipes to check + * @param timeout timeout in milliseconds + * @returns positive number: number of pipes which have + * status changes, 0: timeout, or no pipes with + * status changed, -1 on error + * + * Timeout can be zero (check for specified events, and return), finite + * (wait at most timeout milliseconds before returning), or -1 + * (infinite). The poll method returns when the timeout has elapsed, + * or if an event occurs on one of the pipes being polled, whichever + * happens earlier. + * + * Pipes is a vector of one or more PollEntries, which each list a pipe + * and events to poll for. If events is left empty (zero), all + * conditions are polled for, otherwise only the indicated ones. On + * return, the revents fields contain the events that occurred for each + * pipe; error Error, EndOfFile or Invalid events are always set, + * regardless of wether they were in the set of requested events. + * + * poll may block slightly longer than specified by timeout due to OS + * timer granularity and OS scheduling. Due to its implementation, the + * poll call can also return early if the remote end of the page sends + * a free page while polling (which is put on that pipe's freelist), + * while that pipe is polled for e.g Reading. The status of the pipe is + * indicated correctly in revents, and the caller can simply poll + * again. (The reason this is done this way is because it helps to + * replenish the pool of free pages and queue busy pages without + * blocking.) + * + * Here's a piece of example code waiting on two pipes; if they become + * readable they are read: + * @code + * #include <unistd.h> + * #include <cstdlib> + * #include <string> + * #include <sstream> + * #include <iostream> + * + * #include "BidirMMapPipe.h" + * + * // what to execute in the child + * int randomchild(BidirMMapPipe& pipe) + * { + * ::srand48(::getpid()); + * for (int i = 0; i < 5; ++i) { + * // sleep a random time between 0 and .9 seconds + * ::usleep(int(1e6 * ::drand48())); + * std::ostringstream buf; + * buf << "child pid " << ::getpid() << " sends message " << i; + * std::cout << "[CHILD] : " << buf.str() << std::endl; + * pipe << buf.str() << BidirMMapPipe::flush; + * if (!pipe) return -1; + * if (pipe.eof()) break; + * } + * // tell parent we're done + * pipe << "" << BidirMMapPipe::flush; + * // wait for parent to acknowledge + * std::string s; + * pipe >> s; + * pipe.close(); + * return 0; + * } + * + * // function to spawn a child + * BidirMMapPipe* spawnChild(int (*childexec)(BidirMMapPipe&)) + * { + * BidirMMapPipe *p = new BidirMMapPipe(); + * if (p->isChild()) { + * int retVal = childexec(*p); + * delete p; + * std::exit(retVal); + * } + * return p; + * } + * + * int main() + * { + * typedef BidirMMapPipe::PollEntry PollEntry; + * // poll data structure + * BidirMMapPipe::PollVector pipes; + * pipes.reserve(3); + * // spawn children + * for (int i = 0; i < 3; ++i) { + * pipes.push_back(PollEntry(spawnChild(randomchild), + * BidirMMapPipe::Readable)); + * } + * // while at least some children alive + * while (!pipes.empty()) { + * // poll, wait until status change (infinite timeout) + * int npipes = BidirMMapPipe::poll(pipes, -1); + * // scan for pipes with changed status + * for (std::vector<PollEntry>::iterator it = pipes.begin(); + * npipes && pipes.end() != it; ) { + * if (!it->revents) { + * // unchanged, next one + * ++it; + * continue; + * } + * --npipes; // maybe we can stop early... + * // read from pipes which are readable + * if (it->revents & BidirMMapPipe::Readable) { + * std::string s; + * *(it->pipe) >> s; + * if (!s.empty()) { + * std::cout << "[PARENT]: Read from pipe " << + * it->pipe << ": " << s << std::endl; + * ++it; + * continue; + * } else { + * // child is shutting down... + * *(it->pipe) << "" << BidirMMapPipe::flush; + * goto childcloses; + * } + * } + * // retire pipes with error or end-of-file condition + * if (it->revents & (BidirMMapPipe::Error | + * BidirMMapPipe::EndOfFile | + * BidirMMapPipe::Invalid)) { + * std::cout << "[PARENT]: Error on pipe " << + * it->pipe << " revents " << it->revents << + * std::endl; + * childcloses: + * std::cout << "[PARENT]:\tchild exit status: " << + * it->pipe->close() << std::endl; + * if (retVal) return retVal; + * delete it->pipe; + * it = pipes.erase(it); + * continue; + * } + * } + * } + * return 0; + * } + * @endcode + */ + static int poll(PollVector& pipes, int timeout); + + /** @brief return if this end of the pipe is the parent end + * + * @returns true if parent end of pipe + */ + bool isParent() const { return m_childPid; } + + /** @brief return if this end of the pipe is the child end + * + * @returns true if child end of pipe + */ + bool isChild() const { return !m_childPid; } + + /** @brief if BidirMMapPipe uses a socketpair for communications + * + * @returns true if BidirMMapPipe uses a socketpair for communications + */ + bool usesSocketpair() const { return m_inpipe == m_outpipe; } + + /** @brief if BidirMMapPipe uses a pipe pair for communications + * + * @returns true if BidirMMapPipe uses a pipe pair for communications + */ + bool usesPipepair() const { return m_inpipe != m_outpipe; } + + /** @brief return flags (end of file, BidirMMapPipe closed, ...) + * + * @returns flags (end of file, BidirMMapPipe closed, ...) + */ + int rdstate() const { return m_flags; } + + /** @brief true if end-of-file + * + * @returns true if end-of-file + */ + bool eof() const { return m_flags & eofbit; } + + /** @brief logical failure (e.g. I/O on closed BidirMMapPipe) + * + * @returns true in case of grave logical error (I/O on closed pipe,...) + */ + bool fail() const { return m_flags & failbit; } + + /** @brief true on I/O error + * + * @returns true on I/O error + */ + bool bad() const { return m_flags & badbit; } + + /** @brief status of stream is good + * + * @returns true if pipe is good (no errors, eof, ...) + */ + bool good() const { return !(m_flags & (eofbit | failbit | badbit)); } + + /** @brief true if closed + * + * @returns true if stream is closed + */ + bool closed() const { return m_flags & failbit; } + + /** @brief return true if not serious error (fail/bad) + * + * @returns true if stream is does not have serious error (fail/bad) + * + * (if EOF, this is still true) + */ + operator bool() const { return !fail() && !bad(); } + + /** @brief return true if serious error (fail/bad) + * + * @returns true if stream has a serious error (fail/bad) + */ + bool operator!() const { return fail() || bad(); } + +#ifdef STREAMOP +#undef STREAMOP +#endif +#define STREAMOP(TYPE) \ + BidirMMapPipe& operator<<(const TYPE& val) \ + { write(&val, sizeof(TYPE)); return *this; } \ + BidirMMapPipe& operator>>(TYPE& val) \ + { read(&val, sizeof(TYPE)); return *this; } + STREAMOP(bool); ///< C++ style stream operators for bool + STREAMOP(char); ///< C++ style stream operators for char + STREAMOP(short); ///< C++ style stream operators for short + STREAMOP(int); ///< C++ style stream operators for int + STREAMOP(long); ///< C++ style stream operators for long + STREAMOP(long long); ///< C++ style stream operators for long long + STREAMOP(unsigned char); ///< C++ style stream operators for unsigned char + STREAMOP(unsigned short); ///< C++ style stream operators for unsigned short + STREAMOP(unsigned int); ///< C++ style stream operators for unsigned int + STREAMOP(unsigned long); ///< C++ style stream operators for unsigned long + STREAMOP(unsigned long long); ///< C++ style stream operators for unsigned long long + STREAMOP(float); ///< C++ style stream operators for float + STREAMOP(double); ///< C++ style stream operators for double +#undef STREAMOP + + /** @brief write a C-style string + * + * @param str C-style string + * @returns pipe written to + */ + BidirMMapPipe& operator<<(const char* str); + + /** @brief read a C-style string + * + * @param str pointer to string (space allocated with malloc!) + * @returns pipe read from + * + * since this is for C-style strings, we use malloc/realloc/free for + * strings. passing in a NULL pointer is valid here, and the routine + * will use realloc to allocate a chunk of memory of the right size. + */ + BidirMMapPipe& operator>>(char* (&str)); + + /** @brief write a std::string object + * + * @param str string to write + * @returns pipe written to + */ + BidirMMapPipe& operator<<(const std::string& str); + + /** @brief read a std::string object + * + * @param str string to be read + * @returns pipe read from + */ + BidirMMapPipe& operator>>(std::string& str); + + /** @brief write raw pointer to T to other side + * + * NOTE: This will not write the pointee! Only the value of the + * pointer is transferred. + * + * @param tptr pointer to be written + * @returns pipe written to + */ + template<class T> BidirMMapPipe& operator<<(const T* tptr) + { write(&tptr, sizeof(tptr)); return *this; } + + /** @brief read raw pointer to T from other side + * + * NOTE: This will not read the pointee! Only the value of the + * pointer is transferred. + * + * @param tptr pointer to be read + * @returns pipe read from + */ + template<class T> BidirMMapPipe& operator>>(T* &tptr) + { read(&tptr, sizeof(tptr)); return *this; } + + /** @brief I/O manipulator support + * + * @param f manipulator + * @returns pipe with manipulator applied + * + * example: + * @code + * pipe << BidirMMapPipe::flush; + * @endcode + */ + BidirMMapPipe& operator<<(BidirMMapPipe& (*manip)(BidirMMapPipe&)) + { return manip(*this); } + + /** @brief I/O manipulator support + * + * @param f manipulator + * @returns pipe with manipulator applied + * + * example: + * @code + * pipe >> BidirMMapPipe::purge; + * @endcode + */ + BidirMMapPipe& operator>>(BidirMMapPipe& (*manip)(BidirMMapPipe&)) + { return manip(*this); } + + /// for usage a la "pipe << flush;" + static BidirMMapPipe& flush(BidirMMapPipe& pipe) { pipe.flush(); return pipe; } + /// for usage a la "pipe << purge;" + static BidirMMapPipe& purge(BidirMMapPipe& pipe) { pipe.purge(); return pipe; } + + private: + /// copy-construction forbidden + BidirMMapPipe(const BidirMMapPipe&); + /// assignment forbidden + BidirMMapPipe& operator=(const BidirMMapPipe&) { return *this; } + + /// page is our friend + friend class BidirMMapPipe_impl::Page; + /// convenience typedef for Page + typedef BidirMMapPipe_impl::Page Page; + + /// tuning constants + enum { + // TotPages = 16 will give 32k buffers at 4k page size for both + // parent and child; if your average message to send is larger + // than this, consider raising the value (max 256) + TotPages = 16, ///< pages shared (child + parent) + + PagesPerEnd = TotPages / 2, ///< pages per pipe end + + // if FlushThresh pages are filled, the code forces a flush; 3/4 + // of the pages available seems to work quite well + FlushThresh = (3 * PagesPerEnd) / 4 ///< flush threshold + }; + + // per-class members + static pthread_mutex_t s_openpipesmutex; ///< protects s_openpipes + /// list of open BidirMMapPipes + static std::list<BidirMMapPipe*> s_openpipes; + /// pool of mmapped pages + static BidirMMapPipe_impl::PagePool* s_pagepool; + /// page pool reference counter + static unsigned s_pagepoolrefcnt; + + /// return page pool + static BidirMMapPipe_impl::PagePool& pagepool(); + + // per-instance members + BidirMMapPipe_impl::Pages m_pages; ///< mmapped pages + Page* m_busylist; ///< linked list: busy pages (data to be read) + Page* m_freelist; ///< linked list: free pages + Page* m_dirtylist; ///< linked list: dirty pages (data to be sent) + int m_inpipe; ///< pipe end from which data may be read + int m_outpipe; ///< pipe end to which data may be written + int m_flags; ///< flags (e.g. end of file) + pid_t m_childPid; ///< pid of the child (zero if we're child) + pid_t m_parentPid; ///< pid of the parent + + /// cleanup routine - at exit, we want our children to get a SIGTERM... + static void teardownall(void); + + /// return length of a page list + static unsigned lenPageList(const Page* list); + + /** "feed" the busy and free lists with a list of pages + * + * @param plist linked list of pages + * + * goes through plist, puts free pages from plist onto the freelist + * (or sends them to the remote end if they belong there), and puts + * non-empty pages on plist onto the busy list + */ + void feedPageLists(Page* plist); + + /// put on dirty pages list + void markPageDirty(Page* p); + + /// transfer bytes through the pipe (reading, writing, may block) + static size_type xferraw(int fd, void* addr, size_type len, + ssize_t (*xferfn)(int, void*, std::size_t)); + /// transfer bytes through the pipe (reading, writing, may block) + static size_type xferraw(int fd, void* addr, const size_type len, + ssize_t (*xferfn)(int, const void*, std::size_t)) + { + return xferraw(fd, addr, len, + reinterpret_cast<ssize_t (*)( + int, void*, std::size_t)>(xferfn)); + } + + /** @brief send page(s) to the other end (may block) + * + * @param plist linked list of pages to send + * + * the implementation gathers the different write(s) whereever + * possible; if mmap works, this results in a single write to transfer + * the list of pages sent, if we need to copy things through the pipe, + * we have one write to transfer which pages are sent, and then one + * write per page. + */ + void sendpages(Page* plist); + + /** @brief receive a pages from the other end (may block), queue them + * + * @returns number of pages received + * + * this is an application-level scatter read, which gets the list of + * pages to read from the pipe. if mmap works, it needs only one read + * call (to get the head of the list of pages transferred). if we need + * to copy pages through the pipe, we need to add one read for each + * empty page, and two reads for each non-empty page. + */ + unsigned recvpages(); + + /** @brief receive pages from other end (non-blocking) + * + * @returns number of pages received + * + * like recvpages(), but does not block if nothing is available for + * reading + */ + unsigned recvpages_nonblock(); + + /// get a busy page to read data from (may block) + Page* busypage(); + /// get a dirty page to write data to (may block) + Page* dirtypage(); + + /// close the pipe (no flush if forced) + int doClose(bool force, bool holdlock = false); + /// perform the flush + void doFlush(bool forcePartialPages = true); +#endif //_WIN32 +}; + +END_NAMESPACE_ROOFIT + +#undef BEGIN_NAMESPACE_ROOFIT +#undef END_NAMESPACE_ROOFIT + +#endif // BIDIRMMAPPIPE_H + +// vim: ft=cpp:sw=4:tw=78 diff --git a/roofit/roofitcore/src/Roo1DTable.cxx b/roofit/roofitcore/src/Roo1DTable.cxx index a232387c72fba..965baf0187a02 100644 --- a/roofit/roofitcore/src/Roo1DTable.cxx +++ b/roofit/roofitcore/src/Roo1DTable.cxx @@ -250,6 +250,33 @@ Double_t Roo1DTable::get(const char* label, Bool_t silent) const +//_____________________________________________________________________________ +Double_t Roo1DTable::get(const int index, Bool_t silent) const +{ + // Return the table entry named 'label'. Zero is returned if given + // label doesn't occur in table. + + const RooCatType* cat = 0; + int i = 0; + for (; i < _types.GetEntries(); ++i) { + cat = static_cast<const RooCatType*>(_types[i]); + if (cat->getVal() == index) { + break; + } else { + cat = 0; + } + } + if (!cat) { + if (!silent) { + coutE(InputArguments) << "Roo1DTable::get: ERROR: no such entry: " << index << endl ; + } + return 0 ; + } + return _count[i] ; +} + + + //_____________________________________________________________________________ Double_t Roo1DTable::getOverflow() const { @@ -277,6 +304,23 @@ Double_t Roo1DTable::getFrac(const char* label, Bool_t silent) const +//_____________________________________________________________________________ +Double_t Roo1DTable::getFrac(const int index, Bool_t silent) const +{ + // Return the fraction of entries in the table contained in the slot named 'label'. + // The normalization includes the number of overflows. + // Zero is returned if given label doesn't occur in table. + + if (_total) { + return get(index, silent) / _total ; + } else { + if (!silent) coutW(Contents) << "Roo1DTable::getFrac: WARNING table empty, returning 0" << endl ; + return 0. ; + } +} + + + //_____________________________________________________________________________ Bool_t Roo1DTable::isIdentical(const RooTable& other) { diff --git a/roofit/roofitcore/src/RooAICRegistry.cxx b/roofit/roofitcore/src/RooAICRegistry.cxx index 9c538315a2003..4afbff2a7e56f 100644 --- a/roofit/roofitcore/src/RooAICRegistry.cxx +++ b/roofit/roofitcore/src/RooAICRegistry.cxx @@ -33,6 +33,8 @@ #include "Riostream.h" +using namespace std; + ClassImp(RooAICRegistry) ; @@ -81,7 +83,6 @@ RooAICRegistry::~RooAICRegistry() if (_asArr2[i]) delete _asArr2[i]; if (_asArr3[i]) delete _asArr3[i]; if (_asArr4[i]) delete _asArr4[i]; - i++ ; } } diff --git a/roofit/roofitcore/src/RooAbsAnaConvPdf.cxx b/roofit/roofitcore/src/RooAbsAnaConvPdf.cxx index 4c80911988a00..1812139ad0310 100644 --- a/roofit/roofitcore/src/RooAbsAnaConvPdf.cxx +++ b/roofit/roofitcore/src/RooAbsAnaConvPdf.cxx @@ -70,6 +70,8 @@ #include "RooConvCoefVar.h" #include "RooNameReg.h" +using namespace std; + ClassImp(RooAbsAnaConvPdf) ; @@ -231,7 +233,7 @@ Bool_t RooAbsAnaConvPdf::changeModel(const RooResolutionModel& newModel) } delete cIter ; - // Check if all convolutions were succesfully built + // Check if all convolutions were successfully built if (!allOK) { // Delete new basis functions created sofar TIterator* iter = newConvSet.createIterator() ; @@ -262,22 +264,18 @@ RooAbsGenContext* RooAbsAnaConvPdf::genContext(const RooArgSet &vars, const RooD // and the smearing separately, adding them a posteriori. If this is not possible return // a (slower) generic generation context that uses accept/reject sampling + // Check if the resolution model specifies a special context to be used. + RooResolutionModel* conv = dynamic_cast<RooResolutionModel*>(_model.absArg()); + assert(conv); RooArgSet* modelDep = _model.absArg()->getObservables(&vars) ; modelDep->remove(*convVar(),kTRUE,kTRUE) ; Int_t numAddDep = modelDep->getSize() ; delete modelDep ; - if (dynamic_cast<RooTruthModel*>(_model.absArg())) { - // Truth resolution model: use generic context explicitly allowing generation of convolution variable - RooArgSet forceDirect(*convVar()) ; - return new RooGenContext(*this,vars,prototype,auxProto,verbose,&forceDirect) ; - } - // Check if physics PDF and resolution model can both directly generate the convolution variable RooArgSet dummy ; Bool_t pdfCanDir = (getGenerator(*convVar(),dummy) != 0) ; - RooResolutionModel* conv = (RooResolutionModel*) _convSet.at(0) ; Bool_t resCanDir = conv && (conv->getGenerator(*convVar(),dummy)!=0) && conv->isDirectGenSafe(*convVar()) ; if (numAddDep>0 || !pdfCanDir || !resCanDir) { @@ -291,6 +289,9 @@ RooAbsGenContext* RooAbsAnaConvPdf::genContext(const RooArgSet &vars, const RooD coutI(Generation) << "RooAbsAnaConvPdf::genContext(" << GetName() << ") Using regular accept/reject generator for convolution p.d.f because: " << reason.c_str() << endl ; return new RooGenContext(*this,vars,prototype,auxProto,verbose) ; } + + RooAbsGenContext* context = conv->modelGenContext(*this, vars, prototype, auxProto, verbose); + if (context) return context; // Any other resolution model: use specialized generator context return new RooConvGenContext(*this,vars,prototype,auxProto,verbose) ; diff --git a/roofit/roofitcore/src/RooAbsArg.cxx b/roofit/roofitcore/src/RooAbsArg.cxx index 7af809b799c8d..100223aa0432a 100644 --- a/roofit/roofitcore/src/RooAbsArg.cxx +++ b/roofit/roofitcore/src/RooAbsArg.cxx @@ -76,9 +76,12 @@ ClassImp(RooAbsArg) Bool_t RooAbsArg::_verboseDirty(kFALSE) ; Bool_t RooAbsArg::_inhibitDirty(kFALSE) ; - Bool_t RooAbsArg::inhibitDirty() { return _inhibitDirty ; } +std::map<RooAbsArg*,TRefArray*> RooAbsArg::_ioEvoList ; +std::stack<RooAbsArg*> RooAbsArg::_ioReadStack ; + + //_____________________________________________________________________________ RooAbsArg::RooAbsArg() : TNamed(), @@ -88,7 +91,8 @@ RooAbsArg::RooAbsArg() : _ownedComponents(0), _prohibitServerRedirect(kFALSE), _eocache(0), - _namePtr(0) + _namePtr(0), + _isConstant(kFALSE) { // Default constructor @@ -97,7 +101,6 @@ RooAbsArg::RooAbsArg() : _namePtr = (TNamed*) RooNameReg::instance().constPtr(GetName()) ; - RooTrace::create(this) ; } //_____________________________________________________________________________ @@ -111,7 +114,8 @@ RooAbsArg::RooAbsArg(const char *name, const char *title) : _ownedComponents(0), _prohibitServerRedirect(kFALSE), _eocache(0), - _namePtr(0) + _namePtr(0), + _isConstant(kFALSE) { // Create an object with the specified name and descriptive title. // The newly created object has no clients or servers and has its @@ -121,7 +125,6 @@ RooAbsArg::RooAbsArg(const char *name, const char *title) : _clientShapeIter = _clientListShape.MakeIterator() ; _clientValueIter = _clientListValue.MakeIterator() ; - RooTrace::create(this) ; } @@ -137,13 +140,20 @@ RooAbsArg::RooAbsArg(const RooAbsArg& other, const char* name) _ownedComponents(0), _prohibitServerRedirect(kFALSE), _eocache(other._eocache), - _namePtr(other._namePtr) + _namePtr(other._namePtr), + _isConstant(other._isConstant) { // Copy constructor transfers all boolean and string properties of the original // object. Transient properties and client-server links are not copied // Use name in argument, if supplied - if (name) SetName(name) ; + if (name) { + SetName(name) ; + } else { + // Same name, Ddon't recalculate name pointer (expensive) + TNamed::SetName(other.GetName()) ; + _namePtr = other._namePtr ; + } // Copy server list by hand RooFIter sIter = other._serverList.fwdIterator() ; @@ -164,7 +174,6 @@ RooAbsArg::RooAbsArg(const RooAbsArg& other, const char* name) //setAttribute(Form("CloneOf(%08x)",&other)) ; //cout << "RooAbsArg::cctor(" << this << ") #bools = " << _boolAttrib.size() << " #strings = " << _stringAttrib.size() << endl ; - RooTrace::create(this) ; } @@ -212,7 +221,6 @@ RooAbsArg::~RooAbsArg() _ownedComponents = 0 ; } - RooTrace::destroy(this) ; } @@ -247,12 +255,14 @@ void RooAbsArg::setAttribute(const Text_t* name, Bool_t value) { // Set (default) or clear a named boolean attribute of this object. + // Preserve backward compatibility - any strong + if(string("Constant")==name) { + _isConstant = value ; + } + if (value) { - _boolAttrib.insert(name) ; - - } else { - + } else { set<string>::iterator iter = _boolAttrib.find(name) ; if (iter != _boolAttrib.end()) { _boolAttrib.erase(iter) ; @@ -488,6 +498,10 @@ void RooAbsArg::treeNodeServerList(RooAbsCollection* list, const RooAbsArg* arg, // Fill supplied list with nodes of the arg tree, following all server links, // starting with ourself as top node. +// if (arg==0) { +// cout << "treeNodeServerList(" << GetName() << ") doBranch=" << (doBranch?"T":"F") << " doLeaf = " << (doLeaf?"T":"F") << " valueOnly=" << (valueOnly?"T":"F") << endl ; +// } + if (!arg) { // if (list->getHashTableSize()==0) { // list->setHashTableSize(1000) ; @@ -498,7 +512,9 @@ void RooAbsArg::treeNodeServerList(RooAbsCollection* list, const RooAbsArg* arg, // Decide if to add current node if ((doBranch&&doLeaf) || (doBranch&&arg->isDerived()) || - (doLeaf&&arg->isFundamental()&&(!(recurseFundamental&&arg->isDerived()))) ) { + (doLeaf&&arg->isFundamental()&&(!(recurseFundamental&&arg->isDerived()))) || + (doLeaf && !arg->isFundamental() && !arg->isDerived())) { + list->add(*arg,kTRUE) ; } @@ -983,22 +999,15 @@ Bool_t RooAbsArg::redirectServers(const RooAbsCollection& newSetOrig, Bool_t mus setValueDirty() ; setShapeDirty() ; - // Take self out of newset disallowing cyclical dependencies - RooAbsCollection* newSet2 = (RooAbsCollection*) newSet->clone("newSet2") ; - newSet2->remove(*this,kTRUE,kTRUE) ; - // Process the proxies Bool_t allReplaced=kTRUE ; for (int i=0 ; i<numProxies() ; i++) { - // WVE: Need to make exception here too for newServer != this RooAbsProxy* p = getProxy(i) ; if (!p) continue ; - Bool_t ret2 = p->changePointer(*newSet2,nameChange) ; + Bool_t ret2 = p->changePointer(*newSet,nameChange,kFALSE) ; allReplaced &= ret2 ; } - - delete newSet2 ; - + if (mustReplaceAll && !allReplaced) { coutE(LinkStateMgmt) << "RooAbsArg::redirectServers(" << GetName() << "): ERROR, some proxies could not be adjusted" << endl ; @@ -1200,7 +1209,11 @@ void RooAbsArg::registerProxy(RooListProxy& proxy) } // Register proxy itself + Int_t nProxyOld = _proxyList.GetEntries() ; _proxyList.Add(&proxy) ; + if (_proxyList.GetEntries()!=nProxyOld+1) { + cout << "RooAbsArg::registerProxy(" << GetName() << ") proxy registration failure! nold=" << nProxyOld << " nnew=" << _proxyList.GetEntries() << endl ; + } } @@ -1862,52 +1875,124 @@ TString RooAbsArg::cleanBranchName() const UInt_t RooAbsArg::crc32(const char* data) { // Calculate crc32 checksum on given string - - // Calculate and extract length of string - Int_t len = strlen(data) ; - if (len<4) { - oocoutE((RooAbsArg*)0,InputArguments) << "RooAbsReal::crc32 cannot calculate checksum of less than 4 bytes of data" << endl ; - return 0 ; - } - - // Initialize CRC table on first use - static Bool_t init(kFALSE) ; - static unsigned int crctab[256]; - if (!init) { - int i, j; - unsigned int crc; - for (i = 0; i < 256; i++){ - crc = i << 24; - for (j = 0; j < 8; j++) { - if (crc & 0x80000000) { - crc = (crc << 1) ^ 0x04c11db7 ; - } else { - crc = crc << 1; - } - } - crctab[i] = crc; - } - init = kTRUE ; - } - - unsigned int result(0); - int i(0); - - result = *data++ << 24; - result |= *data++ << 16; - result |= *data++ << 8; - result |= *data++; - result = ~ result; - len -=4; - - for (i=0; i<len; i++) { - result = (result << 8 | *data++) ^ crctab[result >> 24]; - } - - return ~result; + unsigned long sz = strlen(data); + switch (strlen(data)) { + case 0: + return 0; + case 1: + return data[0]; + case 2: + return (data[0] << 8) | data[1]; + case 3: + return (data[0] << 16) | (data[1] << 8) | data[2]; + case 4: + return (data[0] << 24) | (data[1] << 16) | (data[2] << 8) | data[3]; + default: + return crc32(data + 4, sz - 4, (data[0] << 24) | (data[1] << 16) | + (data[2] << 8) | data[3]); + } +} + + +UInt_t RooAbsArg::crc32(const char* data, ULong_t sz, UInt_t crc) +{ + // update CRC32 with new data + + // use precomputed table, rather than computing it on the fly + static const UInt_t crctab[256] = { 0x00000000, + 0x04c11db7, 0x09823b6e, 0x0d4326d9, 0x130476dc, 0x17c56b6b, + 0x1a864db2, 0x1e475005, 0x2608edb8, 0x22c9f00f, 0x2f8ad6d6, + 0x2b4bcb61, 0x350c9b64, 0x31cd86d3, 0x3c8ea00a, 0x384fbdbd, + 0x4c11db70, 0x48d0c6c7, 0x4593e01e, 0x4152fda9, 0x5f15adac, + 0x5bd4b01b, 0x569796c2, 0x52568b75, 0x6a1936c8, 0x6ed82b7f, + 0x639b0da6, 0x675a1011, 0x791d4014, 0x7ddc5da3, 0x709f7b7a, + 0x745e66cd, 0x9823b6e0, 0x9ce2ab57, 0x91a18d8e, 0x95609039, + 0x8b27c03c, 0x8fe6dd8b, 0x82a5fb52, 0x8664e6e5, 0xbe2b5b58, + 0xbaea46ef, 0xb7a96036, 0xb3687d81, 0xad2f2d84, 0xa9ee3033, + 0xa4ad16ea, 0xa06c0b5d, 0xd4326d90, 0xd0f37027, 0xddb056fe, + 0xd9714b49, 0xc7361b4c, 0xc3f706fb, 0xceb42022, 0xca753d95, + 0xf23a8028, 0xf6fb9d9f, 0xfbb8bb46, 0xff79a6f1, 0xe13ef6f4, + 0xe5ffeb43, 0xe8bccd9a, 0xec7dd02d, 0x34867077, 0x30476dc0, + 0x3d044b19, 0x39c556ae, 0x278206ab, 0x23431b1c, 0x2e003dc5, + 0x2ac12072, 0x128e9dcf, 0x164f8078, 0x1b0ca6a1, 0x1fcdbb16, + 0x018aeb13, 0x054bf6a4, 0x0808d07d, 0x0cc9cdca, 0x7897ab07, + 0x7c56b6b0, 0x71159069, 0x75d48dde, 0x6b93dddb, 0x6f52c06c, + 0x6211e6b5, 0x66d0fb02, 0x5e9f46bf, 0x5a5e5b08, 0x571d7dd1, + 0x53dc6066, 0x4d9b3063, 0x495a2dd4, 0x44190b0d, 0x40d816ba, + 0xaca5c697, 0xa864db20, 0xa527fdf9, 0xa1e6e04e, 0xbfa1b04b, + 0xbb60adfc, 0xb6238b25, 0xb2e29692, 0x8aad2b2f, 0x8e6c3698, + 0x832f1041, 0x87ee0df6, 0x99a95df3, 0x9d684044, 0x902b669d, + 0x94ea7b2a, 0xe0b41de7, 0xe4750050, 0xe9362689, 0xedf73b3e, + 0xf3b06b3b, 0xf771768c, 0xfa325055, 0xfef34de2, 0xc6bcf05f, + 0xc27dede8, 0xcf3ecb31, 0xcbffd686, 0xd5b88683, 0xd1799b34, + 0xdc3abded, 0xd8fba05a, 0x690ce0ee, 0x6dcdfd59, 0x608edb80, + 0x644fc637, 0x7a089632, 0x7ec98b85, 0x738aad5c, 0x774bb0eb, + 0x4f040d56, 0x4bc510e1, 0x46863638, 0x42472b8f, 0x5c007b8a, + 0x58c1663d, 0x558240e4, 0x51435d53, 0x251d3b9e, 0x21dc2629, + 0x2c9f00f0, 0x285e1d47, 0x36194d42, 0x32d850f5, 0x3f9b762c, + 0x3b5a6b9b, 0x0315d626, 0x07d4cb91, 0x0a97ed48, 0x0e56f0ff, + 0x1011a0fa, 0x14d0bd4d, 0x19939b94, 0x1d528623, 0xf12f560e, + 0xf5ee4bb9, 0xf8ad6d60, 0xfc6c70d7, 0xe22b20d2, 0xe6ea3d65, + 0xeba91bbc, 0xef68060b, 0xd727bbb6, 0xd3e6a601, 0xdea580d8, + 0xda649d6f, 0xc423cd6a, 0xc0e2d0dd, 0xcda1f604, 0xc960ebb3, + 0xbd3e8d7e, 0xb9ff90c9, 0xb4bcb610, 0xb07daba7, 0xae3afba2, + 0xaafbe615, 0xa7b8c0cc, 0xa379dd7b, 0x9b3660c6, 0x9ff77d71, + 0x92b45ba8, 0x9675461f, 0x8832161a, 0x8cf30bad, 0x81b02d74, + 0x857130c3, 0x5d8a9099, 0x594b8d2e, 0x5408abf7, 0x50c9b640, + 0x4e8ee645, 0x4a4ffbf2, 0x470cdd2b, 0x43cdc09c, 0x7b827d21, + 0x7f436096, 0x7200464f, 0x76c15bf8, 0x68860bfd, 0x6c47164a, + 0x61043093, 0x65c52d24, 0x119b4be9, 0x155a565e, 0x18197087, + 0x1cd86d30, 0x029f3d35, 0x065e2082, 0x0b1d065b, 0x0fdc1bec, + 0x3793a651, 0x3352bbe6, 0x3e119d3f, 0x3ad08088, 0x2497d08d, + 0x2056cd3a, 0x2d15ebe3, 0x29d4f654, 0xc5a92679, 0xc1683bce, + 0xcc2b1d17, 0xc8ea00a0, 0xd6ad50a5, 0xd26c4d12, 0xdf2f6bcb, + 0xdbee767c, 0xe3a1cbc1, 0xe760d676, 0xea23f0af, 0xeee2ed18, + 0xf0a5bd1d, 0xf464a0aa, 0xf9278673, 0xfde69bc4, 0x89b8fd09, + 0x8d79e0be, 0x803ac667, 0x84fbdbd0, 0x9abc8bd5, 0x9e7d9662, + 0x933eb0bb, 0x97ffad0c, 0xafb010b1, 0xab710d06, 0xa6322bdf, + 0xa2f33668, 0xbcb4666d, 0xb8757bda, 0xb5365d03, 0xb1f740b4 + }; + + crc = ~crc; + while (sz--) crc = (crc << 8) ^ UInt_t(*data++) ^ crctab[crc >> 24]; + + return ~crc; +} + +UInt_t RooAbsArg::fnv1a32(const char* data) +{ + // calculate 32 bit FNV1A hash of string + return fnv1a32(data, strlen(data)); +} + +UInt_t RooAbsArg::fnv1a32(const char* data, ULong_t sz, UInt_t hash) +{ + // update 32 bit FNV1A hash + const UInt_t fnv1a32mult = 16777619u; + while (sz--) { + hash ^= *data++; + hash *= fnv1a32mult; + } + return hash; +} + +ULong64_t RooAbsArg::fnv1a64(const char* data) +{ + // calculate 64 bit FNV1A hash of string + return fnv1a64(data, strlen(data)); +} + +ULong64_t RooAbsArg::fnv1a64(const char* data, ULong_t sz, ULong64_t hash) +{ + // update 64 bit FNV1A hash + const ULong64_t fnv1a64mult = (ULong64_t(1) << 40) | ULong64_t(435); + while (sz--) { + hash ^= *data++; + hash *= fnv1a64mult; + } + return hash; } - //_____________________________________________________________________________ void RooAbsArg::printCompactTreeHook(ostream&, const char *) { @@ -2285,9 +2370,115 @@ void RooAbsArg::Streamer(TBuffer &R__b) // Stream an object of class RooAbsArg. if (R__b.IsReading()) { - R__b.ReadClassBuffer(RooAbsArg::Class(),this); - _namePtr = (TNamed*) RooNameReg::instance().constPtr(GetName()) ; + _ioReadStack.push(this) ; + R__b.ReadClassBuffer(RooAbsArg::Class(),this); + _ioReadStack.pop() ; + _namePtr = (TNamed*) RooNameReg::instance().constPtr(GetName()) ; + _isConstant = getAttribute("Constant") ; + } else { + R__b.WriteClassBuffer(RooAbsArg::Class(),this); + } +} + +//______________________________________________________________________________ +void RooAbsArg::ioStreamerPass2() +{ + // Method called by workspace container to finalize schema evolution issues + // that cannot be handled in a single ioStreamer pass. + // + // A second pass is typically needed when evolving data member of RooAbsArg-derived + // classes that are container classes with references to other members, which may + // not yet be 'live' in the first ioStreamer() evolution pass. + // + // Classes may overload this function, but must call the base method in the + // overloaded call to ensure base evolution is handled properly + + + // Handling of v5-v6 migration (TRefArray _proxyList --> RooRefArray _proxyList) + map<RooAbsArg*,TRefArray*>::iterator iter = _ioEvoList.find(this) ; + if (iter != _ioEvoList.end()) { + + // Transfer contents of saved TRefArray to RooRefArray now + for (int i=0 ; i < iter->second->GetEntries() ; i++) { + _proxyList.Add(iter->second->At(i)) ; + } + // Delete TRefArray and remove from list + delete iter->second ; + _ioEvoList.erase(iter) ; + } +} + + + + +//______________________________________________________________________________ +void RooAbsArg::ioStreamerPass2Finalize() +{ + // Method called by workspace container to finalize schema evolution issues + // that cannot be handled in a single ioStreamer pass. This static finalize method + // is called after ioStreamerPass2() is called on each directly listed object + // in the workspace. It's purpose is to complete schema evolution of any + // objects in the workspace that are not directly listed as content elements + // (e.g. analytical convolution tokens ) + + + // Handling of v5-v6 migration (TRefArray _proxyList --> RooRefArray _proxyList) + map<RooAbsArg*,TRefArray*>::iterator iter = _ioEvoList.begin() ; + while (iter != _ioEvoList.end()) { + + // Transfer contents of saved TRefArray to RooRefArray now + for (int i=0 ; i < iter->second->GetEntries() ; i++) { + iter->first->_proxyList.Add(iter->second->At(i)) ; + } + + // Save iterator position for deletion after increment + map<RooAbsArg*,TRefArray*>::iterator iter_tmp = iter ; + + iter++ ; + + // Delete TRefArray and remove from list + delete iter_tmp->second ; + _ioEvoList.erase(iter_tmp) ; + + } + +} + + +//______________________________________________________________________________ +void RooRefArray::Streamer(TBuffer &R__b) +{ + // Stream an object of class RooRefArray. + + UInt_t R__s, R__c; + if (R__b.IsReading()) { + + Version_t R__v = R__b.ReadVersion(&R__s, &R__c); if (R__v) { } + + // Make temporary refArray and read that from the streamer + TRefArray* refArray = new TRefArray ; + refArray->Streamer(R__b) ; + R__b.CheckByteCount(R__s, R__c, refArray->IsA()); + + // Schedule deferred processing of TRefArray into proxy list + RooAbsArg::_ioEvoList[RooAbsArg::_ioReadStack.top()] = refArray ; + } else { - R__b.WriteClassBuffer(RooAbsArg::Class(),this); + + R__c = R__b.WriteVersion(RooRefArray::IsA(), kTRUE); + + // Make a temporary refArray and write that to the streamer + TRefArray refArray ; + TIterator* iter = MakeIterator() ; + TObject* tmpObj ; while ((tmpObj = iter->Next())) { + refArray.Add(tmpObj) ; + } + delete iter ; + + refArray.Streamer(R__b) ; + R__b.SetByteCount(R__c, kTRUE) ; + } } + + diff --git a/roofit/roofitcore/src/RooAbsBinning.cxx b/roofit/roofitcore/src/RooAbsBinning.cxx index 07d3591136050..6476cd4c2ac2e 100644 --- a/roofit/roofitcore/src/RooAbsBinning.cxx +++ b/roofit/roofitcore/src/RooAbsBinning.cxx @@ -31,6 +31,8 @@ #include "Riostream.h" +using namespace std; + ClassImp(RooAbsBinning) ; diff --git a/roofit/roofitcore/src/RooAbsCache.cxx b/roofit/roofitcore/src/RooAbsCache.cxx index 4ce5fe52a6eaf..2006a701577d7 100644 --- a/roofit/roofitcore/src/RooAbsCache.cxx +++ b/roofit/roofitcore/src/RooAbsCache.cxx @@ -32,6 +32,8 @@ #include "RooAbsArg.h" #include "RooArgList.h" +using namespace std; + ClassImp(RooAbsCache) ; diff --git a/roofit/roofitcore/src/RooAbsCacheElement.cxx b/roofit/roofitcore/src/RooAbsCacheElement.cxx index 1a62c6c731a6f..efe36cf4fb7c1 100644 --- a/roofit/roofitcore/src/RooAbsCacheElement.cxx +++ b/roofit/roofitcore/src/RooAbsCacheElement.cxx @@ -32,6 +32,8 @@ #include "RooAbsArg.h" #include "RooArgList.h" +using namespace std; + ClassImp(RooAbsCacheElement) ; diff --git a/roofit/roofitcore/src/RooAbsCachedReal.cxx b/roofit/roofitcore/src/RooAbsCachedReal.cxx index 78e915b8b5140..8e86f092acec4 100644 --- a/roofit/roofitcore/src/RooAbsCachedReal.cxx +++ b/roofit/roofitcore/src/RooAbsCachedReal.cxx @@ -145,6 +145,13 @@ RooAbsCachedReal::FuncCacheElem* RooAbsCachedReal::getCache(const RooArgSet* nse cache = createCache(nset) ; + // Set cache function data to ADirty since function will need update every time in cache update process + RooFIter iarg( cache->hist()->get()->fwdIterator() ); + RooAbsArg *arg(0); + while ( (arg=iarg.next()) ) { + arg->setOperMode(ADirty); + } + // Check if we have contents registered already in global expensive object cache RooDataHist* htmp = (RooDataHist*) expensiveObjectCache().retrieveObject(cache->hist()->GetName(),RooDataHist::Class(),cache->paramTracker()->parameters()) ; @@ -181,6 +188,10 @@ RooAbsCachedReal::FuncCacheElem::FuncCacheElem(const RooAbsCachedReal& self, con // meta object that tracks changes in declared parameters of p.d.f // through actualParameters() + // Disable source caching by default + _cacheSource = kFALSE ; + _sourceClone = 0 ; + RooArgSet* nset2 = self.actualObservables(nset?*nset:RooArgSet()) ; RooArgSet orderedObs ; @@ -216,6 +227,7 @@ RooAbsCachedReal::FuncCacheElem::FuncCacheElem(const RooAbsCachedReal& self, con // makes the correct decisions _func->addServerList(*params) ; + delete observables ; delete params ; delete nset2 ; @@ -223,7 +235,19 @@ RooAbsCachedReal::FuncCacheElem::FuncCacheElem(const RooAbsCachedReal& self, con } +//_____________________________________________________________________________ +RooAbsCachedReal::FuncCacheElem::~FuncCacheElem() +{ + if (_sourceClone) { delete _sourceClone ; } + delete _paramTracker ; + delete _func ; + delete _hist ; +} + + + +//_____________________________________________________________________________ TString RooAbsCachedReal::cacheNameSuffix(const RooArgSet& nset) const { // Construct unique suffix name for cache p.d.f object @@ -279,6 +303,9 @@ RooArgList RooAbsCachedReal::FuncCacheElem::containedArgs(Action) RooArgList ret(*func()) ; ret.add(*_paramTracker) ; + if (_sourceClone) { + ret.add(*_sourceClone) ; + } return ret ; } diff --git a/roofit/roofitcore/src/RooAbsCategory.cxx b/roofit/roofitcore/src/RooAbsCategory.cxx index bfb42b6e3d4d3..e16ee35984366 100644 --- a/roofit/roofitcore/src/RooAbsCategory.cxx +++ b/roofit/roofitcore/src/RooAbsCategory.cxx @@ -44,6 +44,8 @@ #include "RooMsgService.h" #include "RooVectorDataStore.h" +using namespace std; + ClassImp(RooAbsCategory) ; @@ -191,6 +193,19 @@ Bool_t RooAbsCategory::operator==(const RooAbsArg& other) } +//_____________________________________________________________________________ +Bool_t RooAbsCategory::isIdentical(const RooAbsArg& other, Bool_t assumeSameType) +{ + if (!assumeSameType) { + const RooAbsCategory* otherCat = dynamic_cast<const RooAbsCategory*>(&other) ; + return otherCat ? operator==(otherCat->getIndex()) : kFALSE ; + } else { + return getIndex()==((RooAbsCategory&)other).getIndex() ; + } +} + + + //_____________________________________________________________________________ Bool_t RooAbsCategory::isValidIndex(Int_t index) const diff --git a/roofit/roofitcore/src/RooAbsCategoryLValue.cxx b/roofit/roofitcore/src/RooAbsCategoryLValue.cxx index e08c1defee107..bf119107396a7 100644 --- a/roofit/roofitcore/src/RooAbsCategoryLValue.cxx +++ b/roofit/roofitcore/src/RooAbsCategoryLValue.cxx @@ -42,6 +42,8 @@ #include "RooRandom.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooAbsCategoryLValue) ; diff --git a/roofit/roofitcore/src/RooAbsCollection.cxx b/roofit/roofitcore/src/RooAbsCollection.cxx index 2ba38dc2be301..f379f196c77d2 100644 --- a/roofit/roofitcore/src/RooAbsCollection.cxx +++ b/roofit/roofitcore/src/RooAbsCollection.cxx @@ -215,6 +215,7 @@ RooAbsCollection* RooAbsCollection::snapshot(Bool_t deepCopy) const delete output ; return 0 ; } + output->setHashTableSize(0) ; return output ; } @@ -622,9 +623,15 @@ Bool_t RooAbsCollection::remove(const RooAbsArg& var, Bool_t , Bool_t matchByNam _list.Remove(arg) ; anyFound=kTRUE ; } else if (matchByNameOnly) { - if (!name.CompareTo(arg->GetName())) { + //if (!name.CompareTo(arg->GetName())) { + if (var.namePtr()==arg->namePtr()) { + TObject* contObj = _list.FindObject(arg) ; _list.Remove(arg) ; anyFound=kTRUE ; + if (_ownCont && contObj) { + //cout << "RooAbsCollection::remove() deleting instance " << contObj << " named " << contObj->GetName() << endl ; + delete contObj ; + } } } } diff --git a/roofit/roofitcore/src/RooAbsData.cxx b/roofit/roofitcore/src/RooAbsData.cxx index a61bd4e31d0a7..1bf12a4668e3b 100644 --- a/roofit/roofitcore/src/RooAbsData.cxx +++ b/roofit/roofitcore/src/RooAbsData.cxx @@ -42,6 +42,7 @@ #include "RooAbsDataStore.h" #include "RooVectorDataStore.h" #include "RooTreeDataStore.h" +#include "RooDataHist.h" #include "RooCompositeDataStore.h" #include "RooCategory.h" @@ -58,6 +59,8 @@ #include "TH3.h" +using namespace std; + ClassImp(RooAbsData) ; @@ -73,6 +76,13 @@ void RooAbsData::setDefaultStorageType(RooAbsData::StorageType s) } +//_____________________________________________________________________________ +RooAbsData::StorageType RooAbsData::getDefaultStorageType( ) +{ + return defaultStorageType; +} + + //_____________________________________________________________________________ void RooAbsData::claimVars(RooAbsData* data) { @@ -131,7 +141,7 @@ RooAbsData::RooAbsData(const char *name, const char *title, const RooArgSet& var } delete iter ; - // reconnect any paramaterized ranges to internal dataset observables + // reconnect any parameterized ranges to internal dataset observables iter = _vars.createIterator() ; while((0 != (var= (RooAbsArg*)iter->Next()))) { var->attachDataSet(*this) ; @@ -156,7 +166,7 @@ RooAbsData::RooAbsData(const RooAbsData& other, const char* newname) : claimVars(this) ; _vars.addClone(other._vars) ; - // reconnect any paramaterized ranges to internal dataset observables + // reconnect any parameterized ranges to internal dataset observables TIterator* iter = _vars.createIterator() ; RooAbsArg* var ; while((0 != (var= (RooAbsArg*)iter->Next()))) { @@ -293,10 +303,10 @@ const RooArgSet* RooAbsData::get(Int_t index) const //_____________________________________________________________________________ -void RooAbsData::cacheArgs(const RooAbsArg* cacheOwner, RooArgSet& varSet, const RooArgSet* nset) +void RooAbsData::cacheArgs(const RooAbsArg* cacheOwner, RooArgSet& varSet, const RooArgSet* nset, Bool_t skipZeroWeights) { // Internal method -- Cache given set of functions with data - _dstore->cacheArgs(cacheOwner,varSet,nset) ; + _dstore->cacheArgs(cacheOwner,varSet,nset,skipZeroWeights) ; } @@ -803,7 +813,9 @@ Roo1DTable* RooAbsData::table(const RooArgSet& catSet, const char* cuts, const c RooAbsArg* arg ; while((arg=(RooAbsArg*)iter->Next())) { if (dynamic_cast<RooAbsCategory*>(arg)) { - catSet2.add(*arg) ; + RooAbsCategory* varsArg = dynamic_cast<RooAbsCategory*>(_vars.find(arg->GetName())) ; + if (varsArg != 0) catSet2.add(*varsArg) ; + else catSet2.add(*arg) ; if (prodName.length()>1) { prodName += " x " ; } @@ -1598,7 +1610,7 @@ TList* RooAbsData::split(const RooAbsCategory& splitCat, Bool_t createEmptyDataS // variable exists (can happen with composite datastores) Bool_t addWV(kFALSE) ; RooRealVar newweight("weight","weight",-1e9,1e9) ; - if (isWeighted()) { + if (isWeighted() && !IsA()->InheritsFrom(RooDataHist::Class())) { subsetVars.add(newweight) ; addWV = kTRUE ; } @@ -1616,19 +1628,23 @@ TList* RooAbsData::split(const RooAbsCategory& splitCat, Bool_t createEmptyDataS // Loop over dataset and copy event to matching subset - Int_t i ; - for (i=0 ; i<numEntries() ; i++) { - const RooArgSet* row = get(i) ; - RooAbsData* subset = (RooAbsData*) dsetList->FindObject(cloneCat->getLabel()) ; + const bool propWeightSquared = isWeighted(); + for (Int_t i = 0; i < numEntries(); ++i) { + const RooArgSet* row = get(i); + RooAbsData* subset = (RooAbsData*) dsetList->FindObject(cloneCat->getLabel()); if (!subset) { - subset = emptyClone(cloneCat->getLabel(),cloneCat->getLabel(),&subsetVars,(addWV?"weight":0)) ; - dsetList->Add((RooAbsArg*)subset) ; + subset = emptyClone(cloneCat->getLabel(),cloneCat->getLabel(),&subsetVars,(addWV?"weight":0)); + dsetList->Add((RooAbsArg*)subset); + } + if (!propWeightSquared) { + subset->add(*row, weight()); + } else { + subset->add(*row, weight(), weightSquared()); } - subset->add(*row,weight()) ; } - delete cloneSet ; - return dsetList ; + delete cloneSet; + return dsetList; } diff --git a/roofit/roofitcore/src/RooAbsFunc.cxx b/roofit/roofitcore/src/RooAbsFunc.cxx index 6a7d05546b000..9750c9613af18 100644 --- a/roofit/roofitcore/src/RooAbsFunc.cxx +++ b/roofit/roofitcore/src/RooAbsFunc.cxx @@ -32,6 +32,8 @@ #include "RooAbsFunc.h" #include "RooAbsFunc.h" +using namespace std; + ClassImp(RooAbsFunc) ; diff --git a/roofit/roofitcore/src/RooAbsGenContext.cxx b/roofit/roofitcore/src/RooAbsGenContext.cxx index 16a0eae83545b..5170e3a6ff5d4 100644 --- a/roofit/roofitcore/src/RooAbsGenContext.cxx +++ b/roofit/roofitcore/src/RooAbsGenContext.cxx @@ -41,6 +41,8 @@ #include "Riostream.h" +using namespace std; + ClassImp(RooAbsGenContext) ; @@ -135,13 +137,14 @@ RooDataSet* RooAbsGenContext::createDataSet(const char* name, const char* title, //_____________________________________________________________________________ -RooDataSet *RooAbsGenContext::generate(Int_t nEvents, Bool_t skipInit, Bool_t extendedMode) +RooDataSet *RooAbsGenContext::generate(Double_t nEvents, Bool_t skipInit, Bool_t extendedMode) { // Generate the specified number of events with nEvents>0 and // and return a dataset containing the generated events. With nEvents<=0, // generate the number of events in the prototype dataset, if available, - // or else the expected number of events, if non-zero. The returned - // dataset belongs to the caller. Return zero in case of an error. + // or else the expected number of events, if non-zero. + // If extendedMode = true generate according to a Poisson(nEvents) + // The returned dataset belongs to the caller. Return zero in case of an error. // Generation of individual events is delegated to a virtual generateEvent() // method. A virtual initGenerator() method is also called just before the // first call to generateEvent(). @@ -171,10 +174,14 @@ RooDataSet *RooAbsGenContext::generate(Int_t nEvents, Bool_t skipInit, Bool_t ex } coutI(Generation) << ClassName() << "::" << GetName() << ":generate: will generate " << nEvents << " events" << endl; + } if (extendedMode) { - nEvents = RooRandom::randomGenerator()->Poisson(nEvents) ; + double nExpEvents = nEvents; + nEvents = RooRandom::randomGenerator()->Poisson(nEvents) ; + cxcoutI(Generation) << " Extended mode active, number of events generated (" << nEvents << ") is Poisson fluctuation on " + << GetName() << "::expectedEvents() = " << nExpEvents << endl ; } // check that any prototype dataset still defines the variables we need @@ -236,7 +243,7 @@ RooDataSet *RooAbsGenContext::generate(Int_t nEvents, Bool_t skipInit, Bool_t ex } // delegate the generation of the rest of this event to our subclass implementation - generateEvent(*_theEvent, nEvents - _genData->numEntries()); + generateEvent(*_theEvent, (Int_t)(nEvents - _genData->numEntries())); // WVE add check that event is in normRange diff --git a/roofit/roofitcore/src/RooAbsHiddenReal.cxx b/roofit/roofitcore/src/RooAbsHiddenReal.cxx index d28facd00a13b..87a4630816dcb 100644 --- a/roofit/roofitcore/src/RooAbsHiddenReal.cxx +++ b/roofit/roofitcore/src/RooAbsHiddenReal.cxx @@ -36,6 +36,8 @@ #include "RooCategory.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooAbsHiddenReal) ; diff --git a/roofit/roofitcore/src/RooAbsIntegrator.cxx b/roofit/roofitcore/src/RooAbsIntegrator.cxx index 6b99064353091..00a7fb86567a4 100644 --- a/roofit/roofitcore/src/RooAbsIntegrator.cxx +++ b/roofit/roofitcore/src/RooAbsIntegrator.cxx @@ -33,6 +33,8 @@ #include "RooMsgService.h" #include "TClass.h" +using namespace std; + ClassImp(RooAbsIntegrator) ; diff --git a/roofit/roofitcore/src/RooAbsLValue.cxx b/roofit/roofitcore/src/RooAbsLValue.cxx index ea0c1a9167b18..fa488924b55b8 100644 --- a/roofit/roofitcore/src/RooAbsLValue.cxx +++ b/roofit/roofitcore/src/RooAbsLValue.cxx @@ -30,6 +30,8 @@ #include "RooAbsLValue.h" #include "RooAbsLValue.h" +using namespace std; + ClassImp(RooAbsLValue) ; diff --git a/roofit/roofitcore/src/RooAbsMCStudyModule.cxx b/roofit/roofitcore/src/RooAbsMCStudyModule.cxx index 01f1b82018ea3..b775fbf5f1b15 100644 --- a/roofit/roofitcore/src/RooAbsMCStudyModule.cxx +++ b/roofit/roofitcore/src/RooAbsMCStudyModule.cxx @@ -34,6 +34,8 @@ #include "RooFit.h" #include "RooAbsMCStudyModule.h" +using namespace std; + ClassImp(RooAbsMCStudyModule) ; diff --git a/roofit/roofitcore/src/RooAbsNumGenerator.cxx b/roofit/roofitcore/src/RooAbsNumGenerator.cxx index 750def0a8b7fc..de8997f3e6eab 100644 --- a/roofit/roofitcore/src/RooAbsNumGenerator.cxx +++ b/roofit/roofitcore/src/RooAbsNumGenerator.cxx @@ -42,6 +42,8 @@ #include <assert.h> +using namespace std; + ClassImp(RooAbsNumGenerator) ; diff --git a/roofit/roofitcore/src/RooAbsOptTestStatistic.cxx b/roofit/roofitcore/src/RooAbsOptTestStatistic.cxx index e56506d23278b..f8d76ecc24952 100644 --- a/roofit/roofitcore/src/RooAbsOptTestStatistic.cxx +++ b/roofit/roofitcore/src/RooAbsOptTestStatistic.cxx @@ -61,6 +61,8 @@ #include "RooTrace.h" #include "RooVectorDataStore.h" +using namespace std; + ClassImp(RooAbsOptTestStatistic) ; @@ -93,7 +95,7 @@ RooAbsOptTestStatistic:: RooAbsOptTestStatistic() //_____________________________________________________________________________ RooAbsOptTestStatistic::RooAbsOptTestStatistic(const char *name, const char *title, RooAbsReal& real, RooAbsData& indata, const RooArgSet& projDeps, const char* rangeName, const char* addCoefRangeName, - Int_t nCPU, Bool_t interleave, Bool_t verbose, Bool_t splitCutRange, Bool_t /*cloneInputData*/) : + Int_t nCPU, RooFit::MPSplit interleave, Bool_t verbose, Bool_t splitCutRange, Bool_t /*cloneInputData*/) : RooAbsTestStatistic(name,title,real,indata,projDeps,rangeName, addCoefRangeName, nCPU, interleave, verbose, splitCutRange), _projDeps(0), _sealed(kFALSE), @@ -277,10 +279,6 @@ void RooAbsOptTestStatistic::initSlave(RooAbsReal& real, RooAbsData& indata, con } _ownData = kTRUE ; - _dataClone->attachBuffers(*_funcObsSet) ; - setEventCount(_dataClone->numEntries()) ; - - // ****************************************************************** // *** PART 3 *** Make adjustments for fit ranges, if specified * @@ -290,7 +288,7 @@ void RooAbsOptTestStatistic::initSlave(RooAbsReal& real, RooAbsData& indata, con RooArgSet* dataObsSet = (RooArgSet*) _dataClone->get() ; if (rangeName && strlen(rangeName)) { cxcoutI(Fitting) << "RooAbsOptTestStatistic::ctor(" << GetName() << ") constructing test statistic for sub-range named " << rangeName << endl ; -// cout << "now adjusting observable ranges to requested fit range" << endl ; + //cout << "now adjusting observable ranges to requested fit range" << endl ; // Adjust FUNC normalization ranges to requested fitRange, store original ranges for RooAddPdf coefficient interpretation iter = _funcObsSet->fwdIterator() ; @@ -308,8 +306,8 @@ void RooAbsOptTestStatistic::initSlave(RooAbsReal& real, RooAbsData& indata, con // Adjust range of function observable to those of given named range realObs->setRange(realObs->getMin(rangeName),realObs->getMax(rangeName)) ; -// cout << "RAOTS::ctor() setting normalization range on observable " -// << realObs->GetName() << " to [" << realObs->getMin() << "," << realObs->getMax() << "]" << endl ; +// cout << "RAOTS::ctor() setting normalization range on observable " +// << realObs->GetName() << " to [" << realObs->getMin() << "," << realObs->getMax() << "]" << endl ; // Adjust range of data observable to those of given named range RooRealVar* dataObs = (RooRealVar*) dataObsSet->find(realObs->GetName()) ; @@ -359,6 +357,12 @@ void RooAbsOptTestStatistic::initSlave(RooAbsReal& real, RooAbsData& indata, con } + // This is deferred from part 2 - but must happen after part 3 - otherwise invalid bins cannot be properly marked in cacheValidEntries + _dataClone->attachBuffers(*_funcObsSet) ; + setEventCount(_dataClone->numEntries()) ; + + + // ********************************************************************* // *** PART 4 *** Adjust normalization range for projected observables * @@ -369,17 +373,17 @@ void RooAbsOptTestStatistic::initSlave(RooAbsReal& real, RooAbsData& indata, con _projDeps = (RooArgSet*) projDeps.snapshot(kFALSE) ; - RooArgSet* tobedel = (RooArgSet*) _normSet->selectCommon(*_projDeps) ; + //RooArgSet* tobedel = (RooArgSet*) _normSet->selectCommon(*_projDeps) ; _normSet->remove(*_projDeps,kTRUE,kTRUE) ; - // Delete owned projected dependent copy in _normSet - TIterator* ii = tobedel->createIterator() ; - RooAbsArg* aa ; - while((aa=(RooAbsArg*)ii->Next())) { - delete aa ; - } - delete ii ; - delete tobedel ; +// // Delete owned projected dependent copy in _normSet +// TIterator* ii = tobedel->createIterator() ; +// RooAbsArg* aa ; +// while((aa=(RooAbsArg*)ii->Next())) { +// delete aa ; +// } +// delete ii ; +// delete tobedel ; // Mark all projected dependents as such RooArgSet *projDataDeps = (RooArgSet*) _funcObsSet->selectCommon(*_projDeps) ; @@ -445,13 +449,16 @@ Double_t RooAbsOptTestStatistic::combinedValue(RooAbsReal** array, Int_t n) cons // values // Default implementation returns sum of components - Double_t sum(0) ; - Int_t i ; - for (i=0 ; i<n ; i++) { - Double_t tmp = array[i]->getVal() ; - // if (tmp==0) return 0 ; WVE no longer needed - sum += tmp ; + Double_t sum(0), carry(0); + for (Int_t i = 0; i < n; ++i) { + Double_t y = array[i]->getValV(); + carry += reinterpret_cast<RooAbsOptTestStatistic*>(array[i])->getCarry(); + y -= carry; + const Double_t t = sum + y; + carry = (t - sum) - y; + sum = t; } + _evalCarry = carry; return sum ; } @@ -639,6 +646,22 @@ void RooAbsOptTestStatistic::optimizeConstantTerms(Bool_t activate, Bool_t apply RooAbsArg* parg ; while ((parg=piter.next())) { parg->setAttribute("CacheAndTrack") ; + RooArgSet* pdf_nset = prod->findPdfNSet((RooAbsPdf&)(*parg)) ; + + if (pdf_nset) { + // Check if conditional normalization is specified + if (string("nset")==pdf_nset->GetName() && pdf_nset->getSize()>0) { + RooNameSet n(*pdf_nset) ; + parg->setStringAttribute("CATNormSet",n.content()) ; + } + if (string("cset")==pdf_nset->GetName()) { + RooNameSet c(*pdf_nset) ; + parg->setStringAttribute("CATCondSet",c.content()) ; + } + } else { + coutW(Optimization) << "RooAbsOptTestStatistic::optimizeConstantTerms(" << GetName() << ") WARNING RooProdPdf::" << prod->GetName() + << " does not specify a normalization set for component " << parg->GetName() << endl ; + } trackNodes.add(*aarg) ; } } else { @@ -681,8 +704,8 @@ void RooAbsOptTestStatistic::optimizeConstantTerms(Bool_t activate, Bool_t apply // _funcClone->Print("t") ; - // Cache constant nodes with dataset - _dataClone->cacheArgs(this,_cachedNodes,_normSet) ; + // Cache constant nodes with dataset - also cache entries corresponding to zero-weights in data when using BinnedLikelihood + _dataClone->cacheArgs(this,_cachedNodes,_normSet,!_funcClone->getAttribute("BinnedLikelihood")) ; // cout << "ROATS::oCT(" << GetName() << ") funcClone structure dump AFTER cacheArgs" << endl ; // _funcClone->Print("t") ; @@ -701,10 +724,23 @@ void RooAbsOptTestStatistic::optimizeConstantTerms(Bool_t activate, Bool_t apply RooArgSet actualTrackNodes(_cachedNodes) ; actualTrackNodes.remove(*constNodes) ; if (constNodes->getSize()>0) { - coutI(Minimization) << " The following expressions have been identified as constant and will be precalculated and cached: " << *constNodes << endl ; + if (constNodes->getSize()<20) { + coutI(Minimization) << " The following expressions have been identified as constant and will be precalculated and cached: " << *constNodes << endl ; + } else { + coutI(Minimization) << " A total of " << constNodes->getSize() << " expressions have been identified as constant and will be precalculated and cached." << endl ; + } +// RooFIter i = constNodes->fwdIterator() ; +// RooAbsArg* cnode ; +// while((cnode=i.next())) { +// cout << cnode->IsA()->GetName() << "::" << cnode->GetName() << endl ; +// } } if (actualTrackNodes.getSize()>0) { - coutI(Minimization) << " The following expressions will be evaluated in cache-and-track mode: " << actualTrackNodes << endl ; + if (actualTrackNodes.getSize()<20) { + coutI(Minimization) << " The following expressions will be evaluated in cache-and-track mode: " << actualTrackNodes << endl ; + } else { + coutI(Minimization) << " A total of " << constNodes->getSize() << " expressions will be evaluated in cache-and-track-mode." << endl ; + } } delete constNodes ; @@ -745,19 +781,6 @@ Bool_t RooAbsOptTestStatistic::setDataSlave(RooAbsData& indata, Bool_t cloneData // a range specification on the data, the cloneData argument is ignore and // the data is always cloned. -// static Bool_t first = kTRUE ; -// if (first) { -// cout << "RAOTS::setDataSlave(" << this << ") activating tracing" << endl ; -// RooTrace::active(kTRUE) ; -// RooTrace::mark() ; -// first = kFALSE ; -// } else { -// cout << "RAOTS::setDataSlave(" << this << ") dump and mark" << endl ; -// RooTrace::dump(cout,kTRUE) ; -// RooTrace::mark() ; -// } - - if (operMode()==SimMaster) { //cout << "ROATS::setDataSlave() ERROR this is SimMaster _funcClone = " << _funcClone << endl ; diff --git a/roofit/roofitcore/src/RooAbsPdf.cxx b/roofit/roofitcore/src/RooAbsPdf.cxx index 754ccc41ccbb8..0e590c1fcfac8 100644 --- a/roofit/roofitcore/src/RooAbsPdf.cxx +++ b/roofit/roofitcore/src/RooAbsPdf.cxx @@ -152,8 +152,11 @@ #include "RooChi2Var.h" #include "RooMinimizer.h" #include "RooRealIntegral.h" +#include "Math/CholeskyDecomp.h" #include <string> +using namespace std; + ClassImp(RooAbsPdf) ; ClassImp(RooAbsPdf::GenSpec) @@ -164,7 +167,7 @@ Bool_t RooAbsPdf::_evalError = kFALSE ; TString RooAbsPdf::_normRangeOverride ; //_____________________________________________________________________________ -RooAbsPdf::RooAbsPdf() : _norm(0), _normSet(0), _minDimNormValueCache(999), _valueCacheIntOrder(2), _specGeneratorConfig(0) +RooAbsPdf::RooAbsPdf() : _norm(0), _normSet(0), _specGeneratorConfig(0) { // Default constructor _errorCount = 0 ; @@ -178,7 +181,7 @@ RooAbsPdf::RooAbsPdf() : _norm(0), _normSet(0), _minDimNormValueCache(999), _val //_____________________________________________________________________________ RooAbsPdf::RooAbsPdf(const char *name, const char *title) : - RooAbsReal(name,title), _norm(0), _normSet(0), _minDimNormValueCache(999), _valueCacheIntOrder(2), _normMgr(this,10), _selectComp(kTRUE), _specGeneratorConfig(0) + RooAbsReal(name,title), _norm(0), _normSet(0), _normMgr(this,10), _selectComp(kTRUE), _specGeneratorConfig(0) { // Constructor with name and title only resetErrorCounters() ; @@ -190,7 +193,7 @@ RooAbsPdf::RooAbsPdf(const char *name, const char *title) : //_____________________________________________________________________________ RooAbsPdf::RooAbsPdf(const char *name, const char *title, Double_t plotMin, Double_t plotMax) : - RooAbsReal(name,title,plotMin,plotMax), _norm(0), _normSet(0), _minDimNormValueCache(999), _valueCacheIntOrder(2), _normMgr(this,10), _selectComp(kTRUE), _specGeneratorConfig(0) + RooAbsReal(name,title,plotMin,plotMax), _norm(0), _normSet(0), _normMgr(this,10), _selectComp(kTRUE), _specGeneratorConfig(0) { // Constructor with name, title, and plot range resetErrorCounters() ; @@ -201,7 +204,7 @@ RooAbsPdf::RooAbsPdf(const char *name, const char *title, //_____________________________________________________________________________ RooAbsPdf::RooAbsPdf(const RooAbsPdf& other, const char* name) : - RooAbsReal(other,name), _norm(0), _normSet(0), _minDimNormValueCache(other._minDimNormValueCache), _valueCacheIntOrder(other._valueCacheIntOrder), + RooAbsReal(other,name), _norm(0), _normSet(0), _normMgr(other._normMgr,this), _selectComp(other._selectComp), _normRange(other._normRange) { // Copy constructor @@ -289,7 +292,7 @@ Double_t RooAbsPdf::getValV(const RooArgSet* nset) const _value = 0 ; } else { _value = rawVal / normVal ; -// cout << "RooAbsPdf::getValV(" << GetName() << ") writing _value = " << _value << endl ; +// cout << "RooAbsPdf::getValV(" << GetName() << ") writing _value = " << rawVal << "/" << normVal << " = " << _value << endl ; } clearValueAndShapeDirty() ; //setValueDirty(kFALSE) ; @@ -472,31 +475,43 @@ Bool_t RooAbsPdf::syncNormalization(const RooArgSet* nset, Bool_t adjustProxies) const char* nr = (_normRangeOverride.Length()>0 ? _normRangeOverride.Data() : (_normRange.Length()>0 ? _normRange.Data() : 0)) ; // cout << "RooAbsPdf::syncNormalization(" << GetName() << ") rangeName for normalization is " << (nr?nr:"<null>") << endl ; - RooRealIntegral* normInt = (RooRealIntegral*) createIntegral(*depList,*getIntegratorConfig(),nr) ; + RooAbsReal* normInt = createIntegral(*depList,*getIntegratorConfig(),nr) ; normInt->getVal() ; // cout << "resulting normInt = " << normInt->GetName() << endl ; - RooArgSet* normParams = normInt->getVariables() ; - if (normParams->getSize()>0 && normParams->getSize()<3 && normInt->numIntRealVars().getSize()>=_minDimNormValueCache) { - coutI(Caching) << "RooAbsPdf::syncNormalization(" << GetName() << ") INFO: constructing " << normParams->getSize() - << "-dim value cache for normalization integral over " << *depList << endl ; - string name = Form("%s_CACHE_[%s]",normInt->GetName(),normParams->contentsString().c_str()) ; - RooCachedReal* cachedNorm = new RooCachedReal(name.c_str(),name.c_str(),*normInt,*normParams) ; - cachedNorm->setInterpolationOrder(_valueCacheIntOrder) ; - cachedNorm->addOwnedComponents(*normInt) ; - _norm = cachedNorm ; - } else { - _norm = normInt ; - } - delete normParams ; + const char* cacheParamsStr = getStringAttribute("CACHEPARAMINT") ; + if (cacheParamsStr && strlen(cacheParamsStr)) { + + RooArgSet* intParams = normInt->getVariables() ; + + RooNameSet cacheParamNames ; + cacheParamNames.setNameList(cacheParamsStr) ; + RooArgSet* cacheParams = cacheParamNames.select(*intParams) ; + + if (cacheParams->getSize()>0) { + cxcoutD(Caching) << "RooAbsReal::createIntObj(" << GetName() << ") INFO: constructing " << cacheParams->getSize() + << "-dim value cache for integral over " << *depList << " as a function of " << *cacheParams << " in range " << (nr?nr:"<default>") << endl ; + string name = Form("%s_CACHE_[%s]",normInt->GetName(),cacheParams->contentsString().c_str()) ; + RooCachedReal* cachedIntegral = new RooCachedReal(name.c_str(),name.c_str(),*normInt,*cacheParams) ; + cachedIntegral->setInterpolationOrder(2) ; + cachedIntegral->addOwnedComponents(*normInt) ; + cachedIntegral->setCacheSource(kTRUE) ; + if (normInt->operMode()==ADirty) { + cachedIntegral->setOperMode(ADirty) ; + } + normInt= cachedIntegral ; + } + + delete cacheParams ; + delete intParams ; + } + _norm = normInt ; } - - - + // Register new normalization with manager (takes ownership) cache = new CacheElem(*_norm) ; _normMgr.setObj(nset,cache) ; - + // cout << "making new object " << _norm->GetName() << endl ; delete depList ; @@ -505,35 +520,6 @@ Bool_t RooAbsPdf::syncNormalization(const RooArgSet* nset, Bool_t adjustProxies) -//_____________________________________________________________________________ -void RooAbsPdf::setNormValueCaching(Int_t minNumIntDim, Int_t ipOrder) -{ - // Activate caching of normalization integral values in a interpolated histogram - // for integrals that exceed the specified minimum number of numerically integrated - // dimensions, _and_ of which the integral has at most 2 parameters. - // - // The cache is scanned with a granularity defined by a binning named "cache" in the - // scanned integral parameters and is interpolated to given order. - // The cache values are kept for the livetime of the ROOT session/application - // and are persisted along with the object in case the p.d.f. is persisted - // in a RooWorkspace - // - // This feature can substantially speed up fits and improve convergence with slow - // multi-dimensional integrals whose value varies slowly with the parameters so that the - // an interpolated histogram is a good approximation of the true integral value. - // The improved convergence behavior is a result of making the value of the normalization - // integral deterministic for each value of the parameters. If (multi-dimensional) numeric - // integrals are calculated at insufficient precision (>=1e-7) MINUIT convergence may - // be impaired by the effects numerical noise that can cause that subsequent evaluations - // of an integral at the same point in parameter space can give slightly different answers. - - _minDimNormValueCache = minNumIntDim ; - _valueCacheIntOrder = ipOrder ; -} - - - - //_____________________________________________________________________________ Bool_t RooAbsPdf::traceEvalHook(Double_t value) const { @@ -612,6 +598,11 @@ Double_t RooAbsPdf::getLogVal(const RooArgSet* nset) const // An error message is printed if the argument of the log is negative. Double_t prob = getVal(nset) ; + + if (fabs(prob)>1e6) { + coutW(Eval) << "RooAbsPdf::getLogVal(" << GetName() << ") WARNING: large likelihood value: " << prob << endl ; + } + if(prob < 0) { logEvalError("getLogVal() top-level p.d.f evaluates to a negative number") ; @@ -624,6 +615,13 @@ Double_t RooAbsPdf::getLogVal(const RooArgSet* nset) const return log((double)0); } + + if (TMath::IsNaN(prob)) { + logEvalError("getLogVal() top-level p.d.f evaluates to NaN") ; + + return log((double)0); + + } return log(prob); } @@ -653,8 +651,38 @@ Double_t RooAbsPdf::extendedTerm(Double_t observed, const RooArgSet* nset) const return 0; } + + // Explicitly handle case Nobs=Nexp=0 + if (fabs(expected)<1e-10 && fabs(observed)<1e-10) { + return 0 ; + } + + // Check for errors in Nexpected + if (expected<0 || TMath::IsNaN(expected)) { + logEvalError("extendedTerm #expected events is <0 or NaN") ; + return 0 ; + } + // calculate and return the negative log-likelihood of the Poisson // factor for this dataset, dropping the constant log(observed!) + // Double_t extra=0; + // if(observed<1000000) { + // Double_t Delta1 = (expected-observed); + // Double_t Delta2 = observed*(log(expected)-log(observed+1)); + // Double_t Const3 = 0.5*log(observed+1); + // extra= Delta1 - Delta2 + Const3; + + // cout << " extra obs = " << observed << " exp = " << expected << endl ; + // cout << " extra orig = " << expected - observed*log(expected) << endl ; + // cout << " extra orig fix = " << expected - observed*log(expected) + log(TMath::Gamma(observed+1)) << endl ; + // cout << " extra new = " << extra << endl ; + + // } else { + // Double_t sigma_square=expected; + // Double_t diff=observed-expected; + // extra=-log(sigma_square)/2 + (diff*diff)/(2*sigma_square); + // } + Double_t extra= expected - observed*log(expected); // cout << "RooAbsPdf::extendedTerm(" << GetName() << ") observed = " << observed << " expected = " << expected << endl ; @@ -685,8 +713,22 @@ RooAbsReal* RooAbsPdf::createNLL(RooAbsData& data, const RooCmdArg& arg1, const // Range(const char* name) -- Fit only data inside range with given name // Range(Double_t lo, Double_t hi) -- Fit only data inside given range. A range named "fit" is created on the fly on all observables. // Multiple comma separated range names can be specified. - // SumCoefRange(const char* name) -- Set the range in which to interpret the coefficients of RooAddPdf components - // NumCPU(int num) -- Parallelize NLL calculation on num CPUs + // SumCoefRange(const char* name) -- Set the range in which to interpret the coefficients of RooAddPdf components + // NumCPU(int num, int strat) -- Parallelize NLL calculation on num CPUs + // + // Strategy 0 = RooFit::BulkPartition (Default) --> Divide events in N equal chunks + // Strategy 1 = RooFit::Interleave --> Process event i%N in process N. Recommended for binned data with + // a substantial number of zero-bins, which will be distributed across processes more equitably in this strategy + // Strategy 2 = RooFit::SimComponents --> Process each component likelihood of a RooSimultaneous fully in a single process + // and distribute components over processes. This approach can be benificial if normalization calculation time + // dominates the total computation time of a component (since the normalization calculation must be performed + // in each process in strategies 0 and 1. However beware that if the RooSimultaneous components do not share many + // parameters this strategy is inefficient: as most minuit-induced likelihood calculations involve changing + // a single parameter, only 1 of the N processes will be active most of the time if RooSimultaneous components + // do not share many parameters + // Strategy 3 = RooFit::Hybrid --> Follow strategy 0 for all RooSimultaneous components, except those with less than + // 30 dataset entries, for which strategy 2 is followed. + // // Optimize(Bool_t flag) -- Activate constant term optimization (on by default) // SplitRange(Bool_t flag) -- Use separate fit ranges in a simultaneous fit. Actual range name for each // subsample is assumed to by rangeName_{indexState} where indexState @@ -695,8 +737,12 @@ RooAbsReal* RooAbsPdf::createNLL(RooAbsData& data, const RooCmdArg& arg1, const // ExternalConstraints(const RooArgSet& ) -- Include given external constraints to likelihood // GlobalObservables(const RooArgSet&) -- Define the set of normalization observables to be used for the constraint terms. // If none are specified the constrained parameters are used + // GlobalObservablesTag(const char* tagName) -- Define the set of normalization observables to be used for the constraint terms by a string attribute + // associated with pdf observables that match he given tagName // Verbose(Bool_t flag) -- Constrols RooFit informational messages in likelihood construction // CloneData(Bool flag) -- Use clone of dataset in NLL (default is true) + // Offset(Bool_t) -- Offset likelihood by initial value (so that starting value of FCN in minuit is zero). This + // can improve numeric stability in simultaneously fits with components with large likelihood values // // @@ -728,11 +774,13 @@ RooAbsReal* RooAbsPdf::createNLL(RooAbsData& data, const RooLinkedList& cmdList) pc.defineString("rangeName","RangeWithName",0,"",kTRUE) ; pc.defineString("addCoefRange","SumCoefRange",0,"") ; + pc.defineString("globstag","GlobalObservablesTag",0,"") ; pc.defineDouble("rangeLo","Range",0,-999.) ; pc.defineDouble("rangeHi","Range",1,-999.) ; pc.defineInt("splitRange","SplitRange",0,0) ; pc.defineInt("ext","Extended",0,2) ; pc.defineInt("numcpu","NumCPU",0,1) ; + pc.defineInt("interleave","NumCPU",1,0) ; pc.defineInt("verbose","Verbose",0,0) ; pc.defineInt("optConst","Optimize",0,0) ; pc.defineInt("cloneData","CloneData",2,0) ; @@ -740,11 +788,12 @@ RooAbsReal* RooAbsPdf::createNLL(RooAbsData& data, const RooLinkedList& cmdList) pc.defineSet("cPars","Constrain",0,0) ; pc.defineSet("glObs","GlobalObservables",0,0) ; pc.defineInt("constrAll","Constrained",0,0) ; + pc.defineInt("doOffset","OffsetLikelihood",0,0) ; pc.defineSet("extCons","ExternalConstraints",0,0) ; pc.defineMutex("Range","RangeWithName") ; pc.defineMutex("Constrain","Constrained") ; - - + pc.defineMutex("GlobalObservables","GlobalObservablesTag") ; + // Process and check varargs pc.process(cmdList) ; if (!pc.ok(kTRUE)) { @@ -754,19 +803,45 @@ RooAbsReal* RooAbsPdf::createNLL(RooAbsData& data, const RooLinkedList& cmdList) // Decode command line arguments const char* rangeName = pc.getString("rangeName",0,kTRUE) ; const char* addCoefRangeName = pc.getString("addCoefRange",0,kTRUE) ; + const char* globsTag = pc.getString("globstag",0,kTRUE) ; Int_t ext = pc.getInt("ext") ; Int_t numcpu = pc.getInt("numcpu") ; + RooFit::MPSplit interl = (RooFit::MPSplit) pc.getInt("interleave") ; + Int_t splitr = pc.getInt("splitRange") ; Bool_t verbose = pc.getInt("verbose") ; Int_t optConst = pc.getInt("optConst") ; Int_t cloneData = pc.getInt("cloneData") ; + Int_t doOffset = pc.getInt("doOffset") ; // If no explicit cloneData command is specified, cloneData is set to true if optimization is activated if (cloneData==2) { cloneData = optConst ; } + + RooArgSet* cPars = pc.getSet("cPars") ; RooArgSet* glObs = pc.getSet("glObs") ; + if (pc.hasProcessed("GlobalObservablesTag")) { + if (glObs) delete glObs ; + RooArgSet* allVars = getVariables() ; + glObs = (RooArgSet*) allVars->selectByAttrib(globsTag,kTRUE) ; + coutI(Minimization) << "User-defined specification of global observables definition with tag named '" << globsTag << "'" << endl ; + delete allVars ; + } else if (!pc.hasProcessed("GlobalObservables")) { + + // Neither GlobalObservables nor GlobalObservablesTag has been processed - try if a default tag is defined in the head node + // Check if head not specifies default global observable tag + const char* defGlobObsTag = getStringAttribute("DefaultGlobalObservablesTag") ; + if (defGlobObsTag) { + coutI(Minimization) << "p.d.f. provides built-in specification of global observables definition with tag named '" << defGlobObsTag << "'" << endl ; + if (glObs) delete glObs ; + RooArgSet* allVars = getVariables() ; + glObs = (RooArgSet*) allVars->selectByAttrib(defGlobObsTag,kTRUE) ; + } + } + + Bool_t doStripDisconnected=kFALSE ; // If no explicit list of parameters to be constrained is specified apply default algorithm @@ -816,7 +891,7 @@ RooAbsReal* RooAbsPdf::createNLL(RooAbsData& data, const RooLinkedList& cmdList) // Simple case: default range, or single restricted range //cout<<"FK: Data test 1: "<<data.sumEntries()<<endl; - nll = new RooNLLVar(baseName.c_str(),"-log(likelihood)",*this,data,projDeps,ext,rangeName,addCoefRangeName,numcpu,kFALSE,verbose,splitr,cloneData) ; + nll = new RooNLLVar(baseName.c_str(),"-log(likelihood)",*this,data,projDeps,ext,rangeName,addCoefRangeName,numcpu,interl,verbose,splitr,cloneData) ; } else { // Composite case: multiple ranges @@ -826,7 +901,7 @@ RooAbsReal* RooAbsPdf::createNLL(RooAbsData& data, const RooLinkedList& cmdList) strlcpy(buf,rangeName,bufSize) ; char* token = strtok(buf,",") ; while(token) { - RooAbsReal* nllComp = new RooNLLVar(Form("%s_%s",baseName.c_str(),token),"-log(likelihood)",*this,data,projDeps,ext,token,addCoefRangeName,numcpu,kFALSE,verbose,splitr,cloneData) ; + RooAbsReal* nllComp = new RooNLLVar(Form("%s_%s",baseName.c_str(),token),"-log(likelihood)",*this,data,projDeps,ext,token,addCoefRangeName,numcpu,interl,verbose,splitr,cloneData) ; nllList.add(*nllComp) ; token = strtok(0,",") ; } @@ -852,7 +927,9 @@ RooAbsReal* RooAbsPdf::createNLL(RooAbsData& data, const RooLinkedList& cmdList) if (allConstraints.getSize()>0 && cPars) { coutI(Minimization) << " Including the following contraint terms in minimization: " << allConstraints << endl ; - + if (glObs) { + coutI(Minimization) << "The following global observables have been defined: " << *glObs << endl ; + } nllCons = new RooConstraintSum(Form("%s_constr",baseName.c_str()),"nllCons",allConstraints,glObs ? *glObs : *cPars) ; nllCons->setOperMode(ADirty) ; RooAbsReal* orignll = nll ; @@ -869,6 +946,11 @@ RooAbsReal* RooAbsPdf::createNLL(RooAbsData& data, const RooLinkedList& cmdList) if (doStripDisconnected) { delete cPars ; } + + if (doOffset) { + nll->enableOffsetting(kTRUE) ; + } + return nll ; } @@ -883,7 +965,7 @@ RooFitResult* RooAbsPdf::fitTo(RooAbsData& data, const RooCmdArg& arg1, const Ro { // Fit PDF to given dataset. If dataset is unbinned, an unbinned maximum likelihood is performed. If the dataset // is binned, a binned maximum likelihood is performed. By default the fit is executed through the MINUIT - // commands MIGRAD, HESSE and MINOS in succession. + // commands MIGRAD, HESSE in succession. // // The following named arguments are supported // @@ -895,7 +977,21 @@ RooFitResult* RooAbsPdf::fitTo(RooAbsData& data, const RooCmdArg& arg1, const Ro // Range(Double_t lo, Double_t hi) -- Fit only data inside given range. A range named "fit" is created on the fly on all observables. // Multiple comma separated range names can be specified. // SumCoefRange(const char* name) -- Set the range in which to interpret the coefficients of RooAddPdf components - // NumCPU(int num) -- Parallelize NLL calculation on num CPUs + // NumCPU(int num, int strat) -- Parallelize NLL calculation on num CPUs + // + // Strategy 0 = RooFit::BulkPartition (Default) --> Divide events in N equal chunks + // Strategy 1 = RooFit::Interleave --> Process event i%N in process N. Recommended for binned data with + // a substantial number of zero-bins, which will be distributed across processes more equitably in this strategy + // Strategy 2 = RooFit::SimComponents --> Process each component likelihood of a RooSimultaneous fully in a single process + // and distribute components over processes. This approach can be benificial if normalization calculation time + // dominates the total computation time of a component (since the normalization calculation must be performed + // in each process in strategies 0 and 1. However beware that if the RooSimultaneous components do not share many + // parameters this strategy is inefficient: as most minuit-induced likelihood calculations involve changing + // a single parameter, only 1 of the N processes will be active most of the time if RooSimultaneous components + // do not share many parameters + // Strategy 3 = RooFit::Hybrid --> Follow strategy 0 for all RooSimultaneous components, except those with less than + // 30 dataset entries, for which strategy 2 is followed. + // // SplitRange(Bool_t flag) -- Use separate fit ranges in a simultaneous fit. Actual range name for each // subsample is assumed to by rangeName_{indexState} where indexState // is the state of the master index category of the simultaneous fit @@ -904,6 +1000,8 @@ RooFitResult* RooAbsPdf::fitTo(RooAbsData& data, const RooCmdArg& arg1, const Ro // GlobalObservables(const RooArgSet&) -- Define the set of normalization observables to be used for the constraint terms. // If none are specified the constrained parameters are used // ExternalConstraints(const RooArgSet& ) -- Include given external constraints to likelihood + // Offset(Bool_t) -- Offset likelihood by initial value (so that starting value of FCN in minuit is zero). This + // can improve numeric stability in simultaneously fits with components with large likelihood values // // Options to control flow of fit procedure // ---------------------------------------- @@ -924,7 +1022,7 @@ RooFitResult* RooAbsPdf::fitTo(RooAbsData& data, const RooCmdArg& arg1, const Ro // InitialHesse(Bool_t flag) -- Flag controls if HESSE before MIGRAD as well, off by default // Optimize(Bool_t flag) -- Activate constant term optimization of test statistic during minimization (on by default) // Hesse(Bool_t flag) -- Flag controls if HESSE is run after MIGRAD, on by default - // Minos(Bool_t flag) -- Flag controls if MINOS is run after HESSE, on by default + // Minos(Bool_t flag) -- Flag controls if MINOS is run after HESSE, off by default // Minos(const RooArgSet& set) -- Only run MINOS on given subset of arguments // Save(Bool_t flag) -- Flac controls if RooFitResult object is produced and returned, off by default // Strategy(Int_t flag) -- Set Minuit strategy (0 through 2, default is 1) @@ -977,7 +1075,7 @@ RooFitResult* RooAbsPdf::fitTo(RooAbsData& data, const RooLinkedList& cmdList) RooCmdConfig pc(Form("RooAbsPdf::fitTo(%s)",GetName())) ; RooLinkedList fitCmdList(cmdList) ; - RooLinkedList nllCmdList = pc.filterCmdList(fitCmdList,"ProjectedObservables,Extended,Range,RangeWithName,SumCoefRange,NumCPU,SplitRange,Constrained,Constrain,ExternalConstraints,CloneData,GlobalObservables") ; + RooLinkedList nllCmdList = pc.filterCmdList(fitCmdList,"ProjectedObservables,Extended,Range,RangeWithName,SumCoefRange,NumCPU,SplitRange,Constrained,Constrain,ExternalConstraints,CloneData,GlobalObservables,GlobalObservablesTag,OffsetLikelihood") ; pc.defineString("fitOpt","FitOptions",0,"") ; pc.defineInt("optConst","Optimize",0,2) ; @@ -995,6 +1093,7 @@ RooFitResult* RooAbsPdf::fitTo(RooAbsData& data, const RooLinkedList& cmdList) pc.defineInt("doEEWall","EvalErrorWall",0,1) ; pc.defineInt("doWarn","Warnings",0,1) ; pc.defineInt("doSumW2","SumW2Error",0,-1) ; + pc.defineInt("doOffset","OffsetLikelihood",0,0) ; pc.defineString("mintype","Minimizer",0,"OldMinuit") ; pc.defineString("minalg","Minimizer",1,"minuit") ; pc.defineObject("minosSet","Minos",0,0) ; @@ -1064,7 +1163,6 @@ RooFitResult* RooAbsPdf::fitTo(RooAbsData& data, const RooLinkedList& cmdList) } RooAbsReal* nll = createNLL(data,nllCmdList) ; - RooFitResult *ret = 0 ; // Instantiate MINUIT @@ -1125,74 +1223,56 @@ RooFitResult* RooAbsPdf::fitTo(RooAbsData& data, const RooLinkedList& cmdList) m.hesse() ; } - if (doSumW2==1) { - + if (doSumW2==1 && m.getNPar()>0) { // Make list of RooNLLVar components of FCN - list<RooNLLVar*> nllComponents ; - RooArgSet* comps = nll->getComponents() ; - RooAbsArg* arg ; - TIterator* citer = comps->createIterator() ; - while((arg=(RooAbsArg*)citer->Next())) { - RooNLLVar* nllComp = dynamic_cast<RooNLLVar*>(arg) ; - if (nllComp) { - nllComponents.push_back(nllComp) ; - } + RooArgSet* comps = nll->getComponents(); + vector<RooNLLVar*> nllComponents; + nllComponents.reserve(comps->getSize()); + TIterator* citer = comps->createIterator(); + RooAbsArg* arg; + while ((arg=(RooAbsArg*)citer->Next())) { + RooNLLVar* nllComp = dynamic_cast<RooNLLVar*>(arg); + if (!nllComp) continue; + nllComponents.push_back(nllComp); } - delete citer ; - delete comps ; + delete citer; + delete comps; // Calculated corrected errors for weighted likelihood fits - RooFitResult* rw = m.save() ; - for (list<RooNLLVar*>::iterator iter1=nllComponents.begin() ; iter1!=nllComponents.end() ; iter1++) { - (*iter1)->applyWeightSquared(kTRUE) ; + RooFitResult* rw = m.save(); + for (vector<RooNLLVar*>::iterator it = nllComponents.begin(); nllComponents.end() != it; ++it) { + (*it)->applyWeightSquared(kTRUE); } coutI(Fitting) << "RooAbsPdf::fitTo(" << GetName() << ") Calculating sum-of-weights-squared correction matrix for covariance matrix" << endl ; - m.hesse() ; - RooFitResult* rw2 = m.save() ; - for (list<RooNLLVar*>::iterator iter2=nllComponents.begin() ; iter2!=nllComponents.end() ; iter2++) { - (*iter2)->applyWeightSquared(kFALSE) ; + m.hesse(); + RooFitResult* rw2 = m.save(); + for (vector<RooNLLVar*>::iterator it = nllComponents.begin(); nllComponents.end() != it; ++it) { + (*it)->applyWeightSquared(kFALSE); } // Apply correction matrix - const TMatrixDSym& V = rw->covarianceMatrix() ; - TMatrixDSym C = rw2->covarianceMatrix() ; - - // Invert C - Double_t det(0) ; - C.Invert(&det) ; - if (det==0) { + const TMatrixDSym& matV = rw->covarianceMatrix(); + TMatrixDSym matC = rw2->covarianceMatrix(); + using ROOT::Math::CholeskyDecompGenDim; + CholeskyDecompGenDim<Double_t> decomp(matC.GetNrows(), matC); + if (!decomp) { coutE(Fitting) << "RooAbsPdf::fitTo(" << GetName() << ") ERROR: Cannot apply sum-of-weights correction to covariance matrix: correction matrix calculated with weight-squared is singular" <<endl ; } else { - - // Calculate corrected covariance matrix = V C-1 V - TMatrixD VCV(V,TMatrixD::kMult,TMatrixD(C,TMatrixD::kMult,V)) ; - - // Make matrix explicitly symmetric - Int_t n = VCV.GetNrows() ; - TMatrixDSym VCVsym(n) ; - for (Int_t i=0 ; i<n ; i++) { - for (Int_t j=i ; j<n ; j++) { - if (i==j) { - VCVsym(i,j) = VCV(i,j) ; - } - if (i!=j) { - Double_t deltaRel = (VCV(i,j)-VCV(j,i))/sqrt(VCV(i,i)*VCV(j,j)) ; - if (fabs(deltaRel)>1e-3) { - coutW(Fitting) << "RooAbsPdf::fitTo(" << GetName() << ") WARNING: Corrected covariance matrix is not (completely) symmetric: V[" << i << "," << j << "] = " - << VCV(i,j) << " V[" << j << "," << i << "] = " << VCV(j,i) << " explicitly restoring symmetry by inserting average value" << endl ; - } - VCVsym(i,j) = (VCV(i,j)+VCV(j,i))/2 ; - } - } - } - + // replace C by its inverse + decomp.Invert(matC); + // the class lies about the matrix being symmetric, so fill in the + // part above the diagonal + for (int i = 0; i < matC.GetNrows(); ++i) + for (int j = 0; j < i; ++j) matC(j, i) = matC(i, j); + matC.Similarity(matV); + // C now contiains V C^-1 V // Propagate corrected errors to parameters objects - m.applyCovarianceMatrix(VCVsym) ; + m.applyCovarianceMatrix(matC); } - delete rw ; - delete rw2 ; + delete rw; + delete rw2; } if (minos) { @@ -1271,7 +1351,7 @@ RooFitResult* RooAbsPdf::fitTo(RooAbsData& data, const RooLinkedList& cmdList) m.hesse() ; } - if (doSumW2==1) { + if (doSumW2==1 && m.getNPar()>0) { // Make list of RooNLLVar components of FCN list<RooNLLVar*> nllComponents ; @@ -1300,43 +1380,26 @@ RooFitResult* RooAbsPdf::fitTo(RooAbsData& data, const RooLinkedList& cmdList) } // Apply correction matrix - const TMatrixDSym& V = rw->covarianceMatrix() ; - TMatrixDSym C = rw2->covarianceMatrix() ; - - // Invert C - Double_t det(0) ; - C.Invert(&det) ; - if (det==0) { + const TMatrixDSym& matV = rw->covarianceMatrix(); + TMatrixDSym matC = rw2->covarianceMatrix(); + using ROOT::Math::CholeskyDecompGenDim; + CholeskyDecompGenDim<Double_t> decomp(matC.GetNrows(), matC); + if (!decomp) { coutE(Fitting) << "RooAbsPdf::fitTo(" << GetName() << ") ERROR: Cannot apply sum-of-weights correction to covariance matrix: correction matrix calculated with weight-squared is singular" <<endl ; } else { - - // Calculate corrected covariance matrix = V C-1 V - TMatrixD VCV(V,TMatrixD::kMult,TMatrixD(C,TMatrixD::kMult,V)) ; - - // Make matrix explicitly symmetric - Int_t n = VCV.GetNrows() ; - TMatrixDSym VCVsym(n) ; - for (Int_t i=0 ; i<n ; i++) { - for (Int_t j=i ; j<n ; j++) { - if (i==j) { - VCVsym(i,j) = VCV(i,j) ; - } - if (i!=j) { - Double_t deltaRel = (VCV(i,j)-VCV(j,i))/sqrt(VCV(i,i)*VCV(j,j)) ; - if (fabs(deltaRel)>1e-3) { - coutW(Fitting) << "RooAbsPdf::fitTo(" << GetName() << ") WARNING: Corrected covariance matrix is not (completely) symmetric: V[" << i << "," << j << "] = " - << VCV(i,j) << " V[" << j << "," << i << "] = " << VCV(j,i) << " explicitly restoring symmetry by inserting average value" << endl ; - } - VCVsym(i,j) = (VCV(i,j)+VCV(j,i))/2 ; - } - } - } - + // replace C by its inverse + decomp.Invert(matC); + // the class lies about the matrix being symmetric, so fill in the + // part above the diagonal + for (int i = 0; i < matC.GetNrows(); ++i) + for (int j = 0; j < i; ++j) matC(j, i) = matC(i, j); + matC.Similarity(matV); + // C now contiains V C^-1 V // Propagate corrected errors to parameters objects - m.applyCovarianceMatrix(VCVsym) ; + m.applyCovarianceMatrix(matC); } - + delete rw ; delete rw2 ; } @@ -1384,7 +1447,7 @@ RooFitResult* RooAbsPdf::chi2FitTo(RooDataHist& data, const RooLinkedList& cmdLi // Pull arguments to be passed to chi2 construction from list RooLinkedList fitCmdList(cmdList) ; - RooLinkedList chi2CmdList = pc.filterCmdList(fitCmdList,"Range,RangeWithName,NumCPU,Optimize,ProjectedObservables,AddCoefRange,SplitRange") ; + RooLinkedList chi2CmdList = pc.filterCmdList(fitCmdList,"Range,RangeWithName,NumCPU,Optimize,ProjectedObservables,AddCoefRange,SplitRange,DataError,Extended") ; RooAbsReal* chi2 = createChi2(data,chi2CmdList) ; RooFitResult* ret = chi2FitDriver(*chi2,fitCmdList) ; @@ -1409,16 +1472,77 @@ RooAbsReal* RooAbsPdf::createChi2(RooDataHist& data, const RooCmdArg& arg1, con // Options to control construction of the chi^2 // ------------------------------------------ // Extended() -- Use expected number of events of an extended p.d.f as normalization - // DataError() -- Choose between Poisson errors and Sum-of-weights errors + // DataError() -- Choose between Expected error [RooAbsData::Expected] , or Observed error (e.g. Sum-of-weights [RooAbsData:SumW2] or Poisson interval [RooAbsData::Poisson] ) + // Default is AUTO : Expected error for unweighted data, Sum-of-weights for weighted data // NumCPU() -- Activate parallel processing feature // Range() -- Fit only selected region // SumCoefRange() -- Set the range in which to interpret the coefficients of RooAddPdf components // SplitRange() -- Fit range is split by index catory of simultaneous PDF // ConditionalObservables() -- Define projected observables - string name = Form("chi2_%s_%s",GetName(),data.GetName()) ; + RooLinkedList cmdList ; + cmdList.Add((TObject*)&arg1) ; cmdList.Add((TObject*)&arg2) ; + cmdList.Add((TObject*)&arg3) ; cmdList.Add((TObject*)&arg4) ; + cmdList.Add((TObject*)&arg5) ; cmdList.Add((TObject*)&arg6) ; + cmdList.Add((TObject*)&arg7) ; cmdList.Add((TObject*)&arg8) ; + + RooCmdConfig pc(Form("RooAbsPdf::createChi2(%s)",GetName())) ; + pc.defineString("rangeName","RangeWithName",0,"",kTRUE) ; + pc.allowUndefined(kTRUE) ; + pc.process(cmdList) ; + if (!pc.ok(kTRUE)) { + return 0 ; + } + const char* rangeName = pc.getString("rangeName",0,kTRUE) ; - return new RooChi2Var(name.c_str(),name.c_str(),*this,data,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8) ; + // Construct Chi2 + RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::CollectErrors) ; + RooAbsReal* chi2 ; + string baseName = Form("chi2_%s_%s",GetName(),data.GetName()) ; + + if (!rangeName || strchr(rangeName,',')==0) { + // Simple case: default range, or single restricted range + + chi2 = new RooChi2Var(baseName.c_str(),baseName.c_str(),*this,data,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8) ; + + } else { + + // Find which argument is RangeWithName + const RooCmdArg* rarg(0) ; + string rcmd = "RangeWithName" ; + if (arg1.GetName()==rcmd) rarg = &arg1 ; + if (arg2.GetName()==rcmd) rarg = &arg2 ; + if (arg3.GetName()==rcmd) rarg = &arg3 ; + if (arg4.GetName()==rcmd) rarg = &arg4 ; + if (arg5.GetName()==rcmd) rarg = &arg5 ; + if (arg6.GetName()==rcmd) rarg = &arg6 ; + if (arg7.GetName()==rcmd) rarg = &arg7 ; + if (arg8.GetName()==rcmd) rarg = &arg8 ; + + // Composite case: multiple ranges + RooArgList chi2List ; + const size_t bufSize = strlen(rangeName)+1; + char* buf = new char[bufSize] ; + strlcpy(buf,rangeName,bufSize) ; + char* token = strtok(buf,",") ; + while(token) { + RooCmdArg subRangeCmd = RooFit::Range(token) ; + // Construct chi2 while substituting original RangeWithName argument with subrange argument created above + RooAbsReal* chi2Comp = new RooChi2Var(Form("%s_%s",baseName.c_str(),token),"chi^2",*this,data, + &arg1==rarg?subRangeCmd:arg1,&arg2==rarg?subRangeCmd:arg2, + &arg3==rarg?subRangeCmd:arg3,&arg4==rarg?subRangeCmd:arg4, + &arg5==rarg?subRangeCmd:arg5,&arg6==rarg?subRangeCmd:arg6, + &arg7==rarg?subRangeCmd:arg7,&arg8==rarg?subRangeCmd:arg8) ; + chi2List.add(*chi2Comp) ; + token = strtok(0,",") ; + } + delete[] buf ; + chi2 = new RooAddition(baseName.c_str(),"chi^2",chi2List,kTRUE) ; + } + RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::PrintErrors) ; + + + return chi2 ; } @@ -1649,23 +1773,25 @@ RooDataSet *RooAbsPdf::generate(const RooArgSet& whatVars, const RooCmdArg& arg1 Bool_t extended = pc.getInt("extended") ; Bool_t autoBinned = pc.getInt("autoBinned") ; const char* binnedTag = pc.getString("binnedTag") ; - Int_t nEvents = pc.getInt("nEvents") ; + Int_t nEventsI = pc.getInt("nEvents") ; + Double_t nEventsD = pc.getInt("nEventsD") ; //Bool_t verbose = pc.getInt("verbose") ; Bool_t expectedData = pc.getInt("expectedData") ; + Double_t nEvents = (nEventsD>0) ? nEventsD : Double_t(nEventsI); + // Force binned mode for expected data mode if (expectedData) { binnedTag="*" ; } if (extended) { - nEvents = RooRandom::randomGenerator()->Poisson(nEvents==0?expectedEvents(&whatVars):nEvents) ; - cxcoutI(Generation) << " Extended mode active, number of events generated (" << nEvents << ") is Poisson fluctuation on " - << GetName() << "::expectedEvents() = " << nEvents << endl ; - // If Poisson fluctuation results in zero events, stop here - if (nEvents==0) { - return new RooDataSet("emptyData","emptyData",whatVars) ; - } + if (nEvents == 0) nEvents = expectedEvents(&whatVars); + // nEvents = RooRandom::randomGenerator()->Poisson(nEvents==0 ? expectedEvents(&whatVars) : nEvents ) ; + // // If Poisson fluctuation results in zero events, stop here + // if (nEvents==0) { + // return new RooDataSet("emptyData","emptyData",whatVars) ; + // } } else if (nEvents==0) { cxcoutI(Generation) << "No number of events specified , number of events generated is " << GetName() << "::expectedEvents() = " << expectedEvents(&whatVars)<< endl ; @@ -1679,12 +1805,12 @@ RooDataSet *RooAbsPdf::generate(const RooArgSet& whatVars, const RooCmdArg& arg1 } - // Forward to appropiate implementation + // Forward to appropriate implementation RooDataSet* data ; if (protoData) { - data = generate(whatVars,*protoData,nEvents,verbose,randProto,resampleProto) ; + data = generate(whatVars,*protoData,Int_t(nEvents),verbose,randProto,resampleProto) ; } else { - data = generate(whatVars,nEvents,verbose,autoBinned,binnedTag,expectedData) ; + data = generate(whatVars,nEvents,verbose,autoBinned,binnedTag,expectedData, extended) ; } // Rename dataset to given name if supplied @@ -1797,8 +1923,9 @@ RooDataSet *RooAbsPdf::generate(RooAbsPdf::GenSpec& spec) const //Int_t nEvt = spec._extended ? RooRandom::randomGenerator()->Poisson(spec._nGen) : spec._nGen ; //Int_t nEvt = spec._extended ? RooRandom::randomGenerator()->Poisson(spec._nGen==0?expectedEvents(spec._whatVars):spec._nGen) : spec._nGen ; - Int_t nEvt = spec._nGen==0? Int_t(expectedEvents(spec._whatVars)+0.5) : spec._nGen ; + //Int_t nEvt = spec._nGen == 0 ? RooRandom::randomGenerator()->Poisson(expectedEvents(spec._whatVars)) : spec._nGen; + Double_t nEvt = spec._nGen == 0 ? expectedEvents(spec._whatVars) : spec._nGen; RooDataSet* ret = generate(*spec._genContext,spec._whatVars,spec._protoData, nEvt,kFALSE,spec._randProto,spec._resampleProto, spec._init,spec._extended) ; @@ -1811,7 +1938,7 @@ RooDataSet *RooAbsPdf::generate(RooAbsPdf::GenSpec& spec) const //_____________________________________________________________________________ -RooDataSet *RooAbsPdf::generate(const RooArgSet &whatVars, Int_t nEvents, Bool_t verbose, Bool_t autoBinned, const char* binnedTag, Bool_t expectedData) const +RooDataSet *RooAbsPdf::generate(const RooArgSet &whatVars, Double_t nEvents, Bool_t verbose, Bool_t autoBinned, const char* binnedTag, Bool_t expectedData, Bool_t extended) const { // Generate a new dataset containing the specified variables with // events sampled from our distribution. Generate the specified @@ -1833,7 +1960,7 @@ RooDataSet *RooAbsPdf::generate(const RooArgSet &whatVars, Int_t nEvents, Bool_t RooDataSet *generated = 0; if(0 != context && context->isValid()) { - generated= context->generate(nEvents); + generated= context->generate(nEvents, kFALSE, extended); } else { coutE(Generation) << "RooAbsPdf::generate(" << GetName() << ") cannot create a valid context" << endl; @@ -1847,7 +1974,7 @@ RooDataSet *RooAbsPdf::generate(const RooArgSet &whatVars, Int_t nEvents, Bool_t //_____________________________________________________________________________ RooDataSet *RooAbsPdf::generate(RooAbsGenContext& context, const RooArgSet &whatVars, const RooDataSet *prototype, - Int_t nEvents, Bool_t /*verbose*/, Bool_t randProtoOrder, Bool_t resampleProto, + Double_t nEvents, Bool_t /*verbose*/, Bool_t randProtoOrder, Bool_t resampleProto, Bool_t skipInit, Bool_t extended) const { // Internal method @@ -1864,7 +1991,7 @@ RooDataSet *RooAbsPdf::generate(RooAbsGenContext& context, const RooArgSet &what if (randProtoOrder && prototype && prototype->numEntries()!=nEvents) { coutI(Generation) << "RooAbsPdf::generate (Re)randomizing event order in prototype dataset (Nevt=" << nEvents << ")" << endl ; - Int_t* newOrder = randomizeProtoOrder(prototype->numEntries(),nEvents,resampleProto) ; + Int_t* newOrder = randomizeProtoOrder(prototype->numEntries(),Int_t(nEvents),resampleProto) ; context.setProtoDataOrder(newOrder) ; delete[] newOrder ; } @@ -2087,7 +2214,8 @@ RooDataHist *RooAbsPdf::generateBinned(const RooArgSet& whatVars, const RooCmdAr const char* dsetName = pc.getString("dsetName") ; if (extended) { - nEvents = (nEvents==0?Int_t(expectedEvents(&whatVars)+0.5):nEvents) ; + //nEvents = (nEvents==0?Int_t(expectedEvents(&whatVars)+0.5):nEvents) ; + nEvents = (nEvents==0 ? expectedEvents(&whatVars) :nEvents) ; cxcoutI(Generation) << " Extended mode active, number of events generated (" << nEvents << ") is Poisson fluctuation on " << GetName() << "::expectedEvents() = " << nEvents << endl ; // If Poisson fluctuation results in zero events, stop here @@ -2099,7 +2227,7 @@ RooDataHist *RooAbsPdf::generateBinned(const RooArgSet& whatVars, const RooCmdAr << GetName() << "::expectedEvents() = " << expectedEvents(&whatVars)<< endl ; } - // Forward to appropiate implementation + // Forward to appropriate implementation RooDataHist* data = generateBinned(whatVars,nEvents,expectedData,extended) ; // Rename dataset to given name if supplied @@ -2138,8 +2266,9 @@ RooDataHist *RooAbsPdf::generateBinned(const RooArgSet &whatVars, Double_t nEven delete hist ; return 0 ; } else { - // Don't round in expectedData mode - if (expectedData) { + + // Don't round in expectedData or extended mode + if (expectedData || extended) { nEvents = expectedEvents(&whatVars) ; } else { nEvents = Int_t(expectedEvents(&whatVars)+0.5) ; @@ -2303,6 +2432,9 @@ RooPlot* RooAbsPdf::plotOn(RooPlot* frame, RooLinkedList& cmdList) const // VLines() -- Add vertical lines to y=0 at end points of curve // Precision(Double_t eps) -- Control precision of drawn curve w.r.t to scale of plot, default is 1e-3. Higher precision // will result in more and more densely spaced curve points + // A negative precision value will disable adaptive point spacing and restrict sampling to + // the grid point of points defined by the binning of the plotted observabled (recommended for + // expensive functions such as profile likelihoods) // Invisble(Bool_t flag) -- Add curve to frame, but do not display. Useful in combination AddTo() @@ -2488,6 +2620,7 @@ RooPlot* RooAbsPdf::plotOn(RooPlot* frame, RooLinkedList& cmdList) const // Append overriding scale factor command at end of original command list RooCmdArg tmp = RooFit::Normalization(scaleFactor,Raw) ; + tmp.setInt(1,1) ; // Flag this normalization command as created for internal use (so that VisualizeError can strip it) cmdList.Add(&tmp) ; // Was a component selected requested @@ -2552,80 +2685,6 @@ RooPlot* RooAbsPdf::plotOn(RooPlot* frame, RooLinkedList& cmdList) const -//_____________________________________________________________________________ -void RooAbsPdf::plotOnCompSelect(RooArgSet* selNodes) const -{ - // Helper function for plotting of composite p.d.fs. Given - // a set of selected components that should be plotted, - // find all nodes that (in)directly depend on these selected - // nodes. Mark all directly and indirecty selected nodes - // as 'selected' using the selectComp() method - - // Get complete set of tree branch nodes - RooArgSet branchNodeSet ; - branchNodeServerList(&branchNodeSet) ; - - // Discard any non-PDF nodes - TIterator* iter = branchNodeSet.createIterator() ; - RooAbsArg* arg ; - while((arg=(RooAbsArg*)iter->Next())) { - if (!dynamic_cast<RooAbsReal*>(arg)) { - branchNodeSet.remove(*arg) ; - } - } - - // If no set is specified, restored all selection bits to kTRUE - if (!selNodes) { - // Reset PDF selection bits to kTRUE - iter->Reset() ; - while((arg=(RooAbsArg*)iter->Next())) { - ((RooAbsReal*)arg)->selectComp(kTRUE) ; - } - delete iter ; - return ; - } - - - // Add all nodes below selected nodes - iter->Reset() ; - TIterator* sIter = selNodes->createIterator() ; - RooArgSet tmp ; - while((arg=(RooAbsArg*)iter->Next())) { - sIter->Reset() ; - RooAbsArg* selNode ; - while((selNode=(RooAbsArg*)sIter->Next())) { - if (selNode->dependsOn(*arg)) { - tmp.add(*arg,kTRUE) ; - } - } - } - delete sIter ; - - // Add all nodes that depend on selected nodes - iter->Reset() ; - while((arg=(RooAbsArg*)iter->Next())) { - if (arg->dependsOn(*selNodes)) { - tmp.add(*arg,kTRUE) ; - } - } - - tmp.remove(*selNodes,kTRUE) ; - tmp.remove(*this) ; - selNodes->add(tmp) ; - coutI(Plotting) << "RooAbsPdf::plotOn(" << GetName() << ") indirectly selected PDF components: " << tmp << endl ; - - // Set PDF selection bits according to selNodes - iter->Reset() ; - while((arg=(RooAbsArg*)iter->Next())) { - Bool_t select = selNodes->find(arg->GetName()) ? kTRUE : kFALSE ; - ((RooAbsReal*)arg)->selectComp(select) ; - } - - delete iter ; -} - - - //_____________________________________________________________________________ // coverity[PASS_BY_VALUE] @@ -3055,7 +3114,7 @@ RooArgSet* RooAbsPdf::getAllConstraints(const RooArgSet& observables, RooArgSet& while((arg=(RooAbsArg*)iter->Next())) { RooAbsPdf* pdf = dynamic_cast<RooAbsPdf*>(arg) ; if (pdf && !ret->find(pdf->GetName())) { - RooArgSet* compRet = pdf->getConstraints(observables,constrainedParams,stripDisconnected) ; + RooArgSet* compRet = pdf->getConstraints(observables,constrainedParams,stripDisconnected) ; if (compRet) { ret->add(*compRet,kFALSE) ; delete compRet ; diff --git a/roofit/roofitcore/src/RooAbsProxy.cxx b/roofit/roofitcore/src/RooAbsProxy.cxx index 5dca26264194a..73cb51b451636 100644 --- a/roofit/roofitcore/src/RooAbsProxy.cxx +++ b/roofit/roofitcore/src/RooAbsProxy.cxx @@ -34,6 +34,8 @@ // +using namespace std; + ClassImp(RooAbsProxy) ; diff --git a/roofit/roofitcore/src/RooAbsReal.cxx b/roofit/roofitcore/src/RooAbsReal.cxx index 95d4a015f35a4..d5aec1dc16d7b 100644 --- a/roofit/roofitcore/src/RooAbsReal.cxx +++ b/roofit/roofitcore/src/RooAbsReal.cxx @@ -39,6 +39,7 @@ #include "RooAbsReal.h" #include "RooArgSet.h" #include "RooArgList.h" +#include "RooBinning.h" #include "RooPlot.h" #include "RooCurve.h" #include "RooRealVar.h" @@ -69,6 +70,9 @@ #include "RooCmdConfig.h" #include "RooXYChi2Var.h" #include "RooMinuit.h" +#ifndef __ROOFIT_NOROOMINIMIZER +#include "RooMinimizer.h" +#endif #include "RooChi2Var.h" #include "RooFitResult.h" #include "RooMoment.h" @@ -103,6 +107,10 @@ ClassImp(RooAbsReal) Bool_t RooAbsReal::_cacheCheck(kFALSE) ; Bool_t RooAbsReal::_globalSelectComp = kFALSE ; +Bool_t RooAbsReal::_hideOffset = kTRUE ; + +void RooAbsReal::setHideOffset(Bool_t flag) { _hideOffset = flag ; } +Bool_t RooAbsReal::hideOffset() { return _hideOffset ; } RooAbsReal::ErrorLoggingMode RooAbsReal::_evalErrorMode = RooAbsReal::PrintErrors ; Int_t RooAbsReal::_evalErrorCount = 0 ; @@ -148,8 +156,8 @@ RooAbsReal::RooAbsReal(const char *name, const char *title, Double_t inMinVal, //_____________________________________________________________________________ RooAbsReal::RooAbsReal(const RooAbsReal& other, const char* name) : RooAbsArg(other,name), _plotMin(other._plotMin), _plotMax(other._plotMax), - _plotBins(other._plotBins), _value(other._value), _unit(other._unit), _forceNumInt(other._forceNumInt), - _treeVar(other._treeVar), _selectComp(other._selectComp), _lastNSet(0) + _plotBins(other._plotBins), _value(other._value), _unit(other._unit), _label(other._label), + _forceNumInt(other._forceNumInt), _treeVar(other._treeVar), _selectComp(other._selectComp), _lastNSet(0) { // coverity[UNINIT_CTOR] // Copy constructor @@ -193,6 +201,17 @@ Bool_t RooAbsReal::operator==(const RooAbsArg& other) } +//_____________________________________________________________________________ +Bool_t RooAbsReal::isIdentical(const RooAbsArg& other, Bool_t assumeSameType) +{ + if (!assumeSameType) { + const RooAbsReal* otherReal = dynamic_cast<const RooAbsReal*>(&other) ; + return otherReal ? operator==(otherReal->getVal()) : kFALSE ; + } else { + return getVal()==((RooAbsReal&)other).getVal() ; + } +} + //_____________________________________________________________________________ TString RooAbsReal::getTitle(Bool_t appendUnit) const @@ -227,9 +246,12 @@ Double_t RooAbsReal::getValV(const RooArgSet* nset) const _value = traceEval(nset) ; // clearValueDirty() ; } -// cout << "RooAbsReal::getValV(" << GetName() << ") writing _value = " << _value << endl ; + // cout << "RooAbsReal::getValV(" << GetName() << ") writing _value = " << _value << endl ; + + Double_t ret(_value) ; + if (hideOffset()) ret += offset() ; - return _value ; + return ret ; } @@ -628,12 +650,13 @@ RooAbsReal* RooAbsReal::createIntObj(const RooArgSet& iset2, const RooArgSet* ns RooArgSet* cacheParams = cacheParamNames.select(*intParams) ; if (cacheParams->getSize()>0) { - coutI(Caching) << "RooAbsReal::createIntObj(" << GetName() << ") INFO: constructing " << cacheParams->getSize() + cxcoutD(Caching) << "RooAbsReal::createIntObj(" << GetName() << ") INFO: constructing " << cacheParams->getSize() << "-dim value cache for integral over " << iset2 << " as a function of " << *cacheParams << " in range " << (rangeName?rangeName:"<none>") << endl ; string name = Form("%s_CACHE_[%s]",integral->GetName(),cacheParams->contentsString().c_str()) ; RooCachedReal* cachedIntegral = new RooCachedReal(name.c_str(),name.c_str(),*integral,*cacheParams) ; cachedIntegral->setInterpolationOrder(2) ; cachedIntegral->addOwnedComponents(*integral) ; + cachedIntegral->setCacheSource(kTRUE) ; if (integral->operMode()==ADirty) { cachedIntegral->setOperMode(ADirty) ; } @@ -677,7 +700,7 @@ void RooAbsReal::findInnerMostIntegration(const RooArgSet& allObs, RooArgSet& in if (arglv) { // Check if range is parameterized - RooAbsBinning& binning = arglv->getBinning(rangeName,kTRUE,kTRUE) ; + RooAbsBinning& binning = arglv->getBinning(rangeName,kFALSE,kTRUE) ; if (binning.isParameterized()) { RooArgSet* loBoundObs = binning.lowBoundFunc()->getObservables(allObs) ; RooArgSet* hiBoundObs = binning.highBoundFunc()->getObservables(allObs) ; @@ -1006,8 +1029,6 @@ TH1 *RooAbsReal::fillHistogram(TH1 *hist, const RooArgList &plotVars, delete pciter ; - - // Call checkObservables RooArgSet allDeps(plotClones) ; if (projectedVars) { @@ -1021,6 +1042,7 @@ TH1 *RooAbsReal::fillHistogram(TH1 *hist, const RooArgList &plotVars, // Create a standalone projection object to use for calculating bin contents RooArgSet *cloneSet = 0; const RooAbsReal *projected= createPlotProjection(plotClones,projectedVars,cloneSet,0,condObs); + cxcoutD(Plotting) << "RooAbsReal::fillHistogram(" << GetName() << ") plot projection object is " << projected->GetName() << endl ; // Prepare to loop over the histogram bins @@ -1259,11 +1281,13 @@ TH1 *RooAbsReal::createHistogram(const char *name, const RooAbsRealLValue& xvar, // name -- Name of the ROOT histogram // xvar -- Observable to be mapped on x axis of ROOT histogram // + // IntrinsicBinning() -- Apply binning defined by function or pdf (as advertised via binBoundaries() method) // Binning(const char* name) -- Apply binning with given name to x axis of histogram // Binning(RooAbsBinning& binning) -- Apply specified binning to x axis of histogram // Binning(int nbins, [double lo, double hi]) -- Apply specified binning to x axis of histogram // ConditionalObservables(const RooArgSet& set) -- Do not normalized PDF over following observables when projecting PDF into histogram // Scaling(Bool_t) -- Apply density-correction scaling (multiply by bin volume), default is kTRUE + // Extended(Bool_t) -- Plot event yield instead of probability density (for extended pdfs only) // // YVar(const RooAbsRealLValue& var,...) -- Observable to be mapped on y axis of ROOT histogram // ZVar(const RooAbsRealLValue& var,...) -- Observable to be mapped on z axis of ROOT histogram @@ -1293,9 +1317,18 @@ TH1* RooAbsReal::createHistogram(const char *name, const RooAbsRealLValue& xvar, // Define configuration for this method RooCmdConfig pc(Form("RooAbsReal::createHistogram(%s)",GetName())) ; pc.defineInt("scaling","Scaling",0,1) ; + pc.defineInt("intBinning","IntrinsicBinning",0,2) ; + pc.defineInt("extended","Extended",0,2) ; + + pc.defineObject("compSet","SelectCompSet",0) ; + pc.defineString("compSpec","SelectCompSpec",0) ; pc.defineSet("projObs","ProjectedObservables",0,0) ; pc.defineObject("yvar","YVar",0,0) ; pc.defineObject("zvar","ZVar",0,0) ; + pc.defineMutex("SelectCompSet","SelectCompSpec") ; + pc.defineMutex("IntrinsicBinning","Binning") ; + pc.defineMutex("IntrinsicBinning","BinningName") ; + pc.defineMutex("IntrinsicBinning","BinningSpec") ; pc.allowUndefined() ; // Process & check varargs @@ -1318,17 +1351,192 @@ TH1* RooAbsReal::createHistogram(const char *name, const RooAbsRealLValue& xvar, RooArgSet* intObs = 0 ; Bool_t doScaling = pc.getInt("scaling") ; + Int_t doIntBinning = pc.getInt("intBinning") ; + Int_t doExtended = pc.getInt("extended") ; + + // If doExtended is two, selection is automatic, set to 1 of pdf is extended, to zero otherwise + const RooAbsPdf* pdfSelf = dynamic_cast<const RooAbsPdf*>(this) ; + if (!pdfSelf && doExtended>0) { + coutW(InputArguments) << "RooAbsReal::createHistogram(" << GetName() << ") WARNING extended mode requested for a non-pdf object, ignored" << endl ; + doExtended=0 ; + } + if (pdfSelf && doExtended==1 && pdfSelf->extendMode()==RooAbsPdf::CanNotBeExtended) { + coutW(InputArguments) << "RooAbsReal::createHistogram(" << GetName() << ") WARNING extended mode requested for a non-extendable pdf, ignored" << endl ; + doExtended=0 ; + } + if (pdfSelf && doExtended==2) { + doExtended = pdfSelf->extendMode()==RooAbsPdf::CanNotBeExtended ? 0 : 1 ; + } + + const char* compSpec = pc.getString("compSpec") ; + const RooArgSet* compSet = (const RooArgSet*) pc.getObject("compSet") ; + Bool_t haveCompSel = ( (compSpec && strlen(compSpec)>0) || compSet) ; + + RooBinning* intBinning(0) ; + if (doIntBinning>0) { + // Given RooAbsPdf* pdf and RooRealVar* obs + list<Double_t>* bl = binBoundaries((RooRealVar&)xvar,xvar.getMin(),xvar.getMax()) ; + if (!bl) { + // Only emit warning when intrinsic binning is explicitly requested + if (doIntBinning==1) { + coutW(InputArguments) << "RooAbsReal::createHistogram(" << GetName() + << ") WARNING, intrinsic model binning requested for histogram, but model does not define bin boundaries, reverting to default binning"<< endl ; + } + } else { + if (doIntBinning==2) { + coutI(InputArguments) << "RooAbsReal::createHistogram(" << GetName() + << ") INFO: Model has intrinsic binning definition, selecting that binning for the histogram"<< endl ; + } + Double_t* ba = new Double_t[bl->size()] ; int i=0 ; + for (list<double>::iterator it=bl->begin() ; it!=bl->end() ; ++it) { ba[i++] = *it ; } + intBinning = new RooBinning(bl->size()-1,ba) ; + delete[] ba ; + } + } RooLinkedList argListCreate(argList) ; - pc.stripCmdList(argListCreate,"Scaling,ProjectedObservables") ; + pc.stripCmdList(argListCreate,"Scaling,ProjectedObservables,IntrinsicBinning,SelectCompSet,SelectCompSpec,Extended") ; + + TH1* histo(0) ; + if (intBinning) { + RooCmdArg tmp = RooFit::Binning(*intBinning) ; + argListCreate.Add(&tmp) ; + histo = xvar.createHistogram(name,argListCreate) ; + delete intBinning ; + } else { + histo = xvar.createHistogram(name,argListCreate) ; + } + + // Do component selection here + if (haveCompSel) { + + // Get complete set of tree branch nodes + RooArgSet branchNodeSet ; + branchNodeServerList(&branchNodeSet) ; + + // Discard any non-RooAbsReal nodes + TIterator* iter = branchNodeSet.createIterator() ; + RooAbsArg* arg ; + while((arg=(RooAbsArg*)iter->Next())) { + if (!dynamic_cast<RooAbsReal*>(arg)) { + branchNodeSet.remove(*arg) ; + } + } + delete iter ; + + RooArgSet* dirSelNodes ; + if (compSet) { + dirSelNodes = (RooArgSet*) branchNodeSet.selectCommon(*compSet) ; + } else { + dirSelNodes = (RooArgSet*) branchNodeSet.selectByName(compSpec) ; + } + if (dirSelNodes->getSize()>0) { + coutI(Plotting) << "RooAbsPdf::createHistogram(" << GetName() << ") directly selected PDF components: " << *dirSelNodes << endl ; + + // Do indirect selection and activate both + plotOnCompSelect(dirSelNodes) ; + } else { + if (compSet) { + coutE(Plotting) << "RooAbsPdf::createHistogram(" << GetName() << ") ERROR: component selection set " << *compSet << " does not match any components of p.d.f." << endl ; + } else { + coutE(Plotting) << "RooAbsPdf::createHistogram(" << GetName() << ") ERROR: component selection expression '" << compSpec << "' does not select any components of p.d.f." << endl ; + } + return 0 ; + } + delete dirSelNodes ; + } + + Double_t scaleFactor(1.0) ; + if (doExtended) { + scaleFactor = pdfSelf->expectedEvents(vars) ; + doScaling=kFALSE ; + } + + fillHistogram(histo,vars,scaleFactor,intObs,doScaling,projObs,kFALSE) ; + + // Deactivate component selection + if (haveCompSel) { + plotOnCompSelect(0) ; + } - TH1* histo = xvar.createHistogram(name,argListCreate) ; - fillHistogram(histo,vars,1.0,intObs,doScaling,projObs,kFALSE) ; return histo ; } +//_____________________________________________________________________________ +void RooAbsReal::plotOnCompSelect(RooArgSet* selNodes) const +{ + // Helper function for plotting of composite p.d.fs. Given + // a set of selected components that should be plotted, + // find all nodes that (in)directly depend on these selected + // nodes. Mark all directly and indirecty selected nodes + // as 'selected' using the selectComp() method + + // Get complete set of tree branch nodes + RooArgSet branchNodeSet ; + branchNodeServerList(&branchNodeSet) ; + + // Discard any non-PDF nodes + TIterator* iter = branchNodeSet.createIterator() ; + RooAbsArg* arg ; + while((arg=(RooAbsArg*)iter->Next())) { + if (!dynamic_cast<RooAbsReal*>(arg)) { + branchNodeSet.remove(*arg) ; + } + } + + // If no set is specified, restored all selection bits to kTRUE + if (!selNodes) { + // Reset PDF selection bits to kTRUE + iter->Reset() ; + while((arg=(RooAbsArg*)iter->Next())) { + ((RooAbsReal*)arg)->selectComp(kTRUE) ; + } + delete iter ; + return ; + } + + + // Add all nodes below selected nodes + iter->Reset() ; + TIterator* sIter = selNodes->createIterator() ; + RooArgSet tmp ; + while((arg=(RooAbsArg*)iter->Next())) { + sIter->Reset() ; + RooAbsArg* selNode ; + while((selNode=(RooAbsArg*)sIter->Next())) { + if (selNode->dependsOn(*arg)) { + tmp.add(*arg,kTRUE) ; + } + } + } + delete sIter ; + + // Add all nodes that depend on selected nodes + iter->Reset() ; + while((arg=(RooAbsArg*)iter->Next())) { + if (arg->dependsOn(*selNodes)) { + tmp.add(*arg,kTRUE) ; + } + } + + tmp.remove(*selNodes,kTRUE) ; + tmp.remove(*this) ; + selNodes->add(tmp) ; + coutI(Plotting) << "RooAbsPdf::plotOn(" << GetName() << ") indirectly selected PDF components: " << tmp << endl ; + + // Set PDF selection bits according to selNodes + iter->Reset() ; + while((arg=(RooAbsArg*)iter->Next())) { + Bool_t select = selNodes->find(arg->GetName()) ? kTRUE : kFALSE ; + ((RooAbsReal*)arg)->selectComp(select) ; + } + + delete iter ; +} + + //_____________________________________________________________________________ RooPlot* RooAbsReal::plotOn(RooPlot* frame, const RooCmdArg& arg1, const RooCmdArg& arg2, @@ -1575,7 +1783,7 @@ RooPlot* RooAbsReal::plotOn(RooPlot* frame, RooLinkedList& argList) const o.binProjData = pc.getInt("binProjData") ; o.projDataSet = (const RooArgSet*) pc.getObject("projDataSet") ; o.numCPU = pc.getInt("numCPU") ; - o.interleave = pc.getInt("interleave") ; + o.interleave = (RooFit::MPSplit) pc.getInt("interleave") ; o.eeval = pc.getDouble("evalErrorVal") ; o.doeeval = pc.getInt("doEvalError") ; @@ -2244,8 +2452,8 @@ RooPlot* RooAbsReal::plotAsymOn(RooPlot *frame, const RooAbsCategoryLValue& asym depPos.add(projDataVars) ; depNeg.add(projDataVars) ; - const RooAbsReal *posProj = funcPos->createPlotProjection(depPos, &projectedVars, posProjCompList) ; - const RooAbsReal *negProj = funcNeg->createPlotProjection(depNeg, &projectedVars, negProjCompList) ; + const RooAbsReal *posProj = funcPos->createPlotProjection(depPos, &projectedVars, posProjCompList, o.projectionRangeName) ; + const RooAbsReal *negProj = funcNeg->createPlotProjection(depNeg, &projectedVars, negProjCompList, o.projectionRangeName) ; if (!posProj || !negProj) { coutE(Plotting) << "RooAbsReal::plotAsymOn(" << GetName() << ") Unable to create projections, abort" << endl ; return frame ; @@ -2513,10 +2721,24 @@ RooPlot* RooAbsReal::plotOnWithErrorBand(RooPlot* frame,const RooFitResult& fr, // that at least 30 curves are expected to be outside the N% interval, and is minimally 100 (e.g. Z=1->Ncurve=100, Z=2->Ncurve=659, Z=3->Ncurve=11111) // Intervals from the sampling method can be asymmetric, and may perform better in the presence of strong correlations - RooLinkedList plotArgList(argList) ; + RooLinkedList plotArgListTmp(argList) ; RooCmdConfig pc(Form("RooAbsPdf::plotOn(%s)",GetName())) ; - pc.stripCmdList(plotArgList,"VisualizeError,MoveToBack") ; - + pc.stripCmdList(plotArgListTmp,"VisualizeError,MoveToBack") ; + + // Strip any 'internal normalization' arguments from list + RooLinkedList plotArgList ; + RooFIter iter = plotArgListTmp.fwdIterator() ; + RooCmdArg* cmd ; + while ((cmd=(RooCmdArg*)iter.next())) { + if (std::string("Normalization")==cmd->GetName()) { + if (((RooCmdArg*)cmd)->getInt(1)!=0) { + } else { + plotArgList.Add(cmd) ; + } + } else { + plotArgList.Add(cmd) ; + } + } // Generate central value curve RooLinkedList tmp(plotArgList) ; @@ -2608,8 +2830,9 @@ RooPlot* RooAbsReal::plotOnWithErrorBand(RooPlot* frame,const RooFitResult& fr, fr.covarianceMatrix(): fr.reducedCovarianceMatrix(paramList)) ; + for (Int_t ivar=0 ; ivar<paramList.getSize() ; ivar++) { - + RooRealVar& rrv = (RooRealVar&)fpf[fpf_idx[ivar]] ; Double_t cenVal = rrv.getVal() ; @@ -2617,11 +2840,14 @@ RooPlot* RooAbsReal::plotOnWithErrorBand(RooPlot* frame,const RooFitResult& fr, // Make Plus variation ((RooRealVar*)paramList.at(ivar))->setVal(cenVal+Z*errVal) ; + + RooLinkedList tmp2(plotArgList) ; cloneFunc->plotOn(frame,tmp2) ; plusVar.push_back(frame->getCurve()) ; frame->remove(0,kFALSE) ; + // Make Minus variation ((RooRealVar*)paramList.at(ivar))->setVal(cenVal-Z*errVal) ; RooLinkedList tmp3(plotArgList) ; @@ -2874,6 +3100,8 @@ void RooAbsReal::copyCache(const RooAbsArg* source, Bool_t /*valueOnly*/, Bool_t _value = other->_intValue ; } else if (source->getAttribute("BYTE_TREE_BRANCH")) { _value = other->_byteValue ; + } else if (source->getAttribute("BOOL_TREE_BRANCH")) { + _value = other->_boolValue ; } else if (source->getAttribute("SIGNEDBYTE_TREE_BRANCH")) { _value = other->_sbyteValue ; } else if (source->getAttribute("UNSIGNED_INTEGER_TREE_BRANCH")) { @@ -2948,6 +3176,12 @@ void RooAbsReal::attachToTree(TTree& t, Int_t bufSize) setAttribute("BYTE_TREE_BRANCH",kTRUE) ; _treeVar = kTRUE ; t.SetBranchAddress(cleanName,&_byteValue) ; + } else if (!typeName.CompareTo("Bool_t")) { + coutI(Eval) << "RooAbsReal::attachToTree(" << GetName() << ") TTree Bool_t branch " << GetName() + << " will be converted to double precision" << endl ; + setAttribute("BOOL_TREE_BRANCH",kTRUE) ; + _treeVar = kTRUE ; + t.SetBranchAddress(cleanName,&_boolValue) ; } else if (!typeName.CompareTo("Char_t")) { coutI(Eval) << "RooAbsReal::attachToTree(" << GetName() << ") TTree Char_t branch " << GetName() << " will be converted to double precision" << endl ; @@ -3310,34 +3544,6 @@ Double_t RooAbsReal::maxVal(Int_t /*code*/) const -//_____________________________________________________________________________ -void RooAbsReal::EvalError::setMessage(const char* tmp) -{ - if (strlen(tmp)<1023) { - strlcpy(_msg,tmp,1023) ; - } else { - strncpy(_msg,tmp,1020); - _msg[1020]='.' ; _msg[1021]='.' ; - _msg[1022]='.' ; _msg[1023]=0 ; - } -} - - - -//_____________________________________________________________________________ -void RooAbsReal::EvalError::setServerValues(const char* tmp) -{ - if (strlen(tmp)<1023) { - strlcpy(_srvval,tmp,1023) ; - } else { - strncpy(_srvval,tmp,1020); - _srvval[1020]='.' ; _srvval[1021]='.' ; - _srvval[1022]='.' ; _srvval[1023]=0 ; - } -} - - - //_____________________________________________________________________________ void RooAbsReal::logEvalError(const RooAbsReal* originator, const char* origName, const char* message, const char* serverValueString) { @@ -4098,9 +4304,7 @@ RooAbsReal* RooAbsReal::createChi2(RooDataHist& data, const RooLinkedList& cmdLi } delete iter ; - // Construct chi2 - string name = Form("chi2_%s_%s",GetName(),data.GetName()) ; - return new RooChi2Var(name.c_str(),name.c_str(),*this,data,*cmds[0],*cmds[1],*cmds[2],*cmds[3],*cmds[4],*cmds[5],*cmds[6],*cmds[7]) ; + return createChi2(data,*cmds[0],*cmds[1],*cmds[2],*cmds[3],*cmds[4],*cmds[5],*cmds[6],*cmds[7]) ; } @@ -4268,6 +4472,8 @@ RooFitResult* RooAbsReal::chi2FitDriver(RooAbsReal& fcn, RooLinkedList& cmdList) pc.defineInt("ext","Extended",0,2) ; pc.defineInt("numee","PrintEvalErrors",0,10) ; pc.defineInt("doWarn","Warnings",0,1) ; + pc.defineString("mintype","Minimizer",0,"OldMinuit") ; + pc.defineString("minalg","Minimizer",1,"minuit") ; pc.defineObject("minosSet","Minos",0,0) ; pc.defineMutex("FitOptions","Verbose") ; @@ -4286,6 +4492,12 @@ RooFitResult* RooAbsReal::chi2FitDriver(RooAbsReal& fcn, RooLinkedList& cmdList) // Decode command line arguments const char* fitOpt = pc.getString("fitOpt",0,kTRUE) ; +#ifdef __ROOFIT_NOROOMINIMIZER + const char* minType =0 ; +#else + const char* minType = pc.getString("mintype","OldMinuit") ; + const char* minAlg = pc.getString("minalg","minuit") ; +#endif Int_t optConst = pc.getInt("optConst") ; Int_t verbose = pc.getInt("verbose") ; Int_t doSave = pc.getInt("doSave") ; @@ -4299,77 +4511,154 @@ RooFitResult* RooAbsReal::chi2FitDriver(RooAbsReal& fcn, RooLinkedList& cmdList) Int_t doWarn = pc.getInt("doWarn") ; const RooArgSet* minosSet = static_cast<RooArgSet*>(pc.getObject("minosSet")) ; - // Instantiate MINUIT - RooMinuit m(fcn) ; + RooFitResult *ret = 0 ; - if (doWarn==0) { - m.setNoWarn() ; - } - - m.setPrintEvalErrors(numee) ; - if (plevel!=1) { - m.setPrintLevel(plevel) ; - } +#ifdef __ROOFIT_NOROOMINIMIZER + if (true) { +#else + if ("OldMinuit" == string(minType)) { +#endif + // Instantiate MINUIT + RooMinuit m(fcn) ; - if (optConst) { - // Activate constant term optimization - m.optimizeConst(1) ; - } + if (doWarn==0) { + m.setNoWarn() ; + } - RooFitResult *ret = 0 ; + m.setPrintEvalErrors(numee) ; + if (plevel!=1) { + m.setPrintLevel(plevel) ; + } + + if (optConst) { + // Activate constant term optimization + m.optimizeConst(optConst); + } - if (fitOpt) { + if (fitOpt) { - // Play fit options as historically defined - ret = m.fit(fitOpt) ; - - } else { + // Play fit options as historically defined + ret = m.fit(fitOpt) ; + + } else { + + if (verbose) { + // Activate verbose options + m.setVerbose(1) ; + } + if (doTimer) { + // Activate timer options + m.setProfile(1) ; + } + + if (strat!=1) { + // Modify fit strategy + m.setStrategy(strat) ; + } + + if (initHesse) { + // Initialize errors with hesse + m.hesse() ; + } + + // Minimize using migrad + m.migrad() ; + + if (hesse) { + // Evaluate errors with Hesse + m.hesse() ; + } + + if (minos) { + // Evaluate errs with Minos + if (minosSet) { + m.minos(*minosSet) ; + } else { + m.minos() ; + } + } + + // Optionally return fit result + if (doSave) { + string name = Form("fitresult_%s",fcn.GetName()) ; + string title = Form("Result of fit of %s ",GetName()) ; + ret = m.save(name.c_str(),title.c_str()) ; + } - if (verbose) { - // Activate verbose options - m.setVerbose(1) ; } - if (doTimer) { - // Activate timer options - m.setProfile(1) ; + } else { +#ifndef __ROOFIT_NOROOMINIMIZER + // Instantiate MINUIT + RooMinimizer m(fcn) ; + m.setMinimizerType(minType); + + if (doWarn==0) { + // m.setNoWarn() ; WVE FIX THIS } - - if (strat!=1) { - // Modify fit strategy - m.setStrategy(strat) ; + + m.setPrintEvalErrors(numee) ; + if (plevel!=1) { + m.setPrintLevel(plevel) ; } - if (initHesse) { - // Initialize errors with hesse - m.hesse() ; + if (optConst) { + // Activate constant term optimization + m.optimizeConst(optConst); } - // Minimize using migrad - m.migrad() ; + if (fitOpt) { - if (hesse) { - // Evaluate errors with Hesse - m.hesse() ; - } + // Play fit options as historically defined + ret = m.fit(fitOpt) ; - if (minos) { - // Evaluate errs with Minos - if (minosSet) { - m.minos(*minosSet) ; - } else { - m.minos() ; + } else { + + if (verbose) { + // Activate verbose options + m.setVerbose(1) ; + } + if (doTimer) { + // Activate timer options + m.setProfile(1) ; } - } - // Optionally return fit result - if (doSave) { - string name = Form("fitresult_%s",fcn.GetName()) ; - string title = Form("Result of fit of %s ",GetName()) ; - ret = m.save(name.c_str(),title.c_str()) ; - } + if (strat!=1) { + // Modify fit strategy + m.setStrategy(strat) ; + } + + if (initHesse) { + // Initialize errors with hesse + m.hesse() ; + } + + // Minimize using migrad + m.minimize(minType, minAlg) ; + if (hesse) { + // Evaluate errors with Hesse + m.hesse() ; + } + + if (minos) { + // Evaluate errs with Minos + if (minosSet) { + m.minos(*minosSet) ; + } else { + m.minos() ; + } + } + + // Optionally return fit result + if (doSave) { + string name = Form("fitresult_%s",fcn.GetName()) ; + string title = Form("Result of fit of %s ",GetName()) ; + ret = m.save(name.c_str(),title.c_str()) ; + } + } +#endif } - + // Cleanup return ret ; diff --git a/roofit/roofitcore/src/RooAbsRealLValue.cxx b/roofit/roofitcore/src/RooAbsRealLValue.cxx index db30eca1efed6..e3973cb7648ac 100644 --- a/roofit/roofitcore/src/RooAbsRealLValue.cxx +++ b/roofit/roofitcore/src/RooAbsRealLValue.cxx @@ -59,6 +59,8 @@ +using namespace std; + ClassImp(RooAbsRealLValue) //_____________________________________________________________________________ @@ -502,8 +504,9 @@ Bool_t RooAbsRealLValue::fitRangeOKForPlotting() const Bool_t RooAbsRealLValue::inRange(const char* name) const { // Check if current value is inside range with given name - - return (getVal() >= getMin(name) && getVal() <= getMax(name)) ; + Double_t val = getVal() ; + Double_t epsilon = 1e-8 * fabs(val) ; + return (val >= getMin(name)-epsilon && val <= getMax(name)+epsilon) ; } diff --git a/roofit/roofitcore/src/RooAbsRootFinder.cxx b/roofit/roofitcore/src/RooAbsRootFinder.cxx index 9033572f05e4b..a8638796ed1c8 100644 --- a/roofit/roofitcore/src/RooAbsRootFinder.cxx +++ b/roofit/roofitcore/src/RooAbsRootFinder.cxx @@ -31,6 +31,8 @@ #include "RooMsgService.h" #include "Riostream.h" +using namespace std; + ClassImp(RooAbsRootFinder) ; diff --git a/roofit/roofitcore/src/RooAbsString.cxx b/roofit/roofitcore/src/RooAbsString.cxx index 9b042bd39e46f..b25d495ef380d 100644 --- a/roofit/roofitcore/src/RooAbsString.cxx +++ b/roofit/roofitcore/src/RooAbsString.cxx @@ -39,6 +39,8 @@ #include "RooStringVar.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooAbsString) ; @@ -107,6 +109,18 @@ Bool_t RooAbsString::operator==(const char* value) const } +//_____________________________________________________________________________ +Bool_t RooAbsString::isIdentical(const RooAbsArg& other, Bool_t assumeSameType) +{ + if (!assumeSameType) { + const RooAbsString* otherString = dynamic_cast<const RooAbsString*>(&other) ; + return otherString ? operator==(otherString->getVal()) : kFALSE ; + } else { + return !TString(getVal()).CompareTo(((RooAbsString&)other).getVal()) ; ; + } +} + + //_____________________________________________________________________________ Bool_t RooAbsString::operator==(const RooAbsArg& other) diff --git a/roofit/roofitcore/src/RooAbsTestStatistic.cxx b/roofit/roofitcore/src/RooAbsTestStatistic.cxx index 60192eb5d241d..e297801e7c5fd 100644 --- a/roofit/roofitcore/src/RooAbsTestStatistic.cxx +++ b/roofit/roofitcore/src/RooAbsTestStatistic.cxx @@ -47,34 +47,27 @@ #include "RooRealMPFE.h" #include "RooErrorHandler.h" #include "RooMsgService.h" +#include "TTimeStamp.h" +#include "RooProdPdf.h" +#include "RooRealSumPdf.h" #include <string> +using namespace std; + ClassImp(RooAbsTestStatistic) ; //_____________________________________________________________________________ -RooAbsTestStatistic::RooAbsTestStatistic() +RooAbsTestStatistic::RooAbsTestStatistic() : + _func(0), _data(0), _projDeps(0), _splitRange(0), _simCount(0), + _verbose(kFALSE), _init(kFALSE), _gofOpMode(Slave), _nEvents(0), _setNum(0), + _numSets(0), _extSet(0), _nGof(0), _gofArray(0), _nCPU(1), _mpfeArray(0), + _mpinterl(RooFit::BulkPartition), _doOffset(kFALSE), _offset(0), + _offsetCarry(0), _evalCarry(0) { - // Default constructor - _func = 0 ; - _data = 0 ; - _projDeps = 0 ; - _init = kFALSE ; - _gofArray = 0 ; - _mpfeArray = 0 ; - _projDeps = 0 ; - _gofOpMode = Slave ; - _mpinterl = kFALSE ; - _nCPU = 1 ; - _nEvents = 0 ; - _nGof = 0 ; - _numSets = 0 ; - _setNum = 0 ; - _simCount = 0 ; - _splitRange = 0 ; - _verbose = kFALSE ; + // Default constructor } @@ -82,7 +75,7 @@ RooAbsTestStatistic::RooAbsTestStatistic() //_____________________________________________________________________________ RooAbsTestStatistic::RooAbsTestStatistic(const char *name, const char *title, RooAbsReal& real, RooAbsData& data, const RooArgSet& projDeps, const char* rangeName, const char* addCoefRangeName, - Int_t nCPU, Bool_t interleave, Bool_t verbose, Bool_t splitCutRange) : + Int_t nCPU, RooFit::MPSplit interleave, Bool_t verbose, Bool_t splitCutRange) : RooAbsReal(name,title), _paramSet("paramSet","Set of parameters",this), _func(&real), @@ -97,7 +90,11 @@ RooAbsTestStatistic::RooAbsTestStatistic(const char *name, const char *title, Ro _gofArray(0), _nCPU(nCPU), _mpfeArray(0), - _mpinterl(interleave) + _mpinterl(interleave), + _doOffset(kFALSE), + _offset(0), + _offsetCarry(0), + _evalCarry(0) { // Constructor taking function (real), a dataset (data), a set of projected observables (projSet). If // rangeName is not null, only events in the dataset inside the range will be used in the test @@ -112,7 +109,6 @@ RooAbsTestStatistic::RooAbsTestStatistic(const char *name, const char *title, Ro // If splitCutRange is true, a different rangeName constructed as rangeName_{catName} will be used // as range definition for each index state of a RooSimultaneous - // Register all parameters as servers RooArgSet* params = real.getParameters(&data) ; _paramSet.add(*params) ; @@ -139,6 +135,7 @@ RooAbsTestStatistic::RooAbsTestStatistic(const char *name, const char *title, Ro } _setNum = 0 ; + _extSet = 0 ; _numSets = 1 ; _init = kFALSE ; _nEvents = data.numEntries() ; @@ -160,9 +157,14 @@ RooAbsTestStatistic::RooAbsTestStatistic(const RooAbsTestStatistic& other, const _verbose(other._verbose), _nGof(0), _gofArray(0), + _gofSplitMode(other._gofSplitMode), _nCPU(other._nCPU), _mpfeArray(0), - _mpinterl(other._mpinterl) + _mpinterl(other._mpinterl), + _doOffset(other._doOffset), + _offset(other._offset), + _offsetCarry(other._offsetCarry), + _evalCarry(other._evalCarry) { // Copy constructor @@ -190,6 +192,7 @@ RooAbsTestStatistic::RooAbsTestStatistic(const RooAbsTestStatistic& other, const } _setNum = 0 ; + _extSet = 0 ; _numSets = 1 ; _init = kFALSE ; _nEvents = _data->numEntries() ; @@ -204,25 +207,18 @@ RooAbsTestStatistic::~RooAbsTestStatistic() { // Destructor - if (_gofOpMode==MPMaster && _init) { - Int_t i ; - for (i=0 ; i<_nCPU ; i++) { - delete _mpfeArray[i] ; - } + if (MPMaster == _gofOpMode && _init) { + for (Int_t i = 0; i < _nCPU; ++i) delete _mpfeArray[i]; delete[] _mpfeArray ; } - if (_gofOpMode==SimMaster && _init) { - Int_t i ; - for (i=0 ; i<_nGof ; i++) { - delete _gofArray[i] ; - } + if (SimMaster == _gofOpMode && _init) { + for (Int_t i = 0; i < _nGof; ++i) delete _gofArray[i]; delete[] _gofArray ; } - if (_projDeps) { - delete _projDeps ; - } + delete _projDeps ; + } @@ -241,52 +237,94 @@ Double_t RooAbsTestStatistic::evaluate() const const_cast<RooAbsTestStatistic*>(this)->initialize() ; } - if (_gofOpMode==SimMaster) { - + if (SimMaster == _gofOpMode) { // Evaluate array of owned GOF objects - Double_t ret = combinedValue((RooAbsReal**)_gofArray,_nGof) ; + Double_t ret = 0.; + + if (_mpinterl == RooFit::BulkPartition || _mpinterl == RooFit::Interleave ) { + ret = combinedValue((RooAbsReal**)_gofArray,_nGof); + } else { + Double_t sum = 0., carry = 0.; + for (Int_t i = 0 ; i < _nGof; ++i) { + if (i % _numSets == _setNum || (_mpinterl==RooFit::Hybrid && _gofSplitMode[i] != RooFit::SimComponents )) { + Double_t y = _gofArray[i]->getValV(); + carry += _gofArray[i]->getCarry(); + y -= carry; + const Double_t t = sum + y; + carry = (t - sum) - y; + sum = t; + } + } + ret = sum ; + _evalCarry = carry; + } // Only apply global normalization if SimMaster doesn't have MP master if (numSets()==1) { -// cout << "RooAbsTestStatistic::evaluate(" << GetName() << ") A dividing ret= " << ret << " by globalNorm of " << globalNormalization() << endl ; - ret /= globalNormalization() ; + const Double_t norm = globalNormalization(); + ret /= norm; + _evalCarry /= norm; } return ret ; - } else if (_gofOpMode==MPMaster) { - + } else if (MPMaster == _gofOpMode) { + // Start calculations in parallel - Int_t i ; - for (i=0 ; i<_nCPU ; i++) { - _mpfeArray[i]->calculate() ; + for (Int_t i = 0; i < _nCPU; ++i) _mpfeArray[i]->calculate(); + + + Double_t sum(0), carry = 0.; + for (Int_t i = 0; i < _nCPU; ++i) { + Double_t y = _mpfeArray[i]->getValV(); + carry += _mpfeArray[i]->getCarry(); + y -= carry; + const Double_t t = sum + y; + carry = (t - sum) - y; + sum = t; } - Double_t ret = combinedValue((RooAbsReal**)_mpfeArray,_nCPU)/globalNormalization() ; + + Double_t ret = sum ; + _evalCarry = carry; return ret ; } else { // Evaluate as straight FUNC - Int_t nFirst, nLast, nStep ; - if (_mpinterl) { + Int_t nFirst(0), nLast(_nEvents), nStep(1) ; + + switch (_mpinterl) { + case RooFit::BulkPartition: + nFirst = _nEvents * _setNum / _numSets ; + nLast = _nEvents * (_setNum+1) / _numSets ; + nStep = 1 ; + break; + + case RooFit::Interleave: nFirst = _setNum ; nLast = _nEvents ; nStep = _numSets ; - } else { - nFirst = _nEvents * _setNum / _numSets ; - nLast = _nEvents * (_setNum+1) / _numSets ; + break ; + + case RooFit::SimComponents: + nFirst = 0 ; + nLast = _nEvents ; nStep = 1 ; + break ; + + case RooFit::Hybrid: + throw(std::string("this should never happen")) ; + break ; } + Double_t ret = evaluatePartition(nFirst,nLast,nStep); - //cout << "nCPU = " << _nCPU << (_mpinterl?"INTERLEAVE":"BULK") << " nFirst = " << nFirst << " nLast = " << nLast << " nStep = " << nStep << endl ; - - Double_t ret = evaluatePartition(nFirst,nLast,nStep) ; if (numSets()==1) { -// cout << "RooAbsTestStatistic::evaluate(" << GetName() << ") B dividing ret= " << ret << " by globalNorm of " << globalNormalization() << endl ; - ret /= globalNormalization() ; + const Double_t norm = globalNormalization(); + ret /= norm; + _evalCarry /= norm; } - + return ret ; } @@ -301,15 +339,15 @@ Bool_t RooAbsTestStatistic::initialize() // infrastructure for simultaneous p.d.f processing and/or // parallelized processing if requested - if (_init) return kFALSE ; + if (_init) return kFALSE; - if (_gofOpMode==MPMaster) { + if (MPMaster == _gofOpMode) { initMPMode(_func,_data,_projDeps,_rangeName.size()?_rangeName.c_str():0,_addCoefRangeName.size()?_addCoefRangeName.c_str():0) ; - } else if (_gofOpMode==SimMaster) { + } else if (SimMaster == _gofOpMode) { initSimMode((RooSimultaneous*)_func,_data,_projDeps,_rangeName.size()?_rangeName.c_str():0,_addCoefRangeName.size()?_addCoefRangeName.c_str():0) ; } - _init = kTRUE ; - return kFALSE ; + _init = kTRUE; + return kFALSE; } @@ -318,28 +356,23 @@ Bool_t RooAbsTestStatistic::initialize() Bool_t RooAbsTestStatistic::redirectServersHook(const RooAbsCollection& newServerList, Bool_t mustReplaceAll, Bool_t nameChange, Bool_t) { // Forward server redirect calls to component test statistics - - if (_gofOpMode==SimMaster && _gofArray) { + if (SimMaster == _gofOpMode && _gofArray) { // Forward to slaves - Int_t i ; - for (i=0 ; i<_nGof ; i++) { + for (Int_t i = 0; i < _nGof; ++i) { if (_gofArray[i]) { - _gofArray[i]->recursiveRedirectServers(newServerList,mustReplaceAll,nameChange) ; + _gofArray[i]->recursiveRedirectServers(newServerList,mustReplaceAll,nameChange); } } - } else if (_gofOpMode==MPMaster && _mpfeArray) { - + } else if (MPMaster == _gofOpMode&& _mpfeArray) { // Forward to slaves - Int_t i ; - for (i=0 ; i<_nCPU ; i++) { + for (Int_t i = 0; i < _nCPU; ++i) { if (_mpfeArray[i]) { - _mpfeArray[i]->recursiveRedirectServers(newServerList,mustReplaceAll,nameChange) ; -// cout << "redirecting servers on " << _mpfeArray[i]->GetName() << endl ; + _mpfeArray[i]->recursiveRedirectServers(newServerList,mustReplaceAll,nameChange); +// cout << "redirecting servers on " << _mpfeArray[i]->GetName() << endl; } } - } - return kFALSE ; + return kFALSE; } @@ -349,20 +382,18 @@ void RooAbsTestStatistic::printCompactTreeHook(ostream& os, const char* indent) { // Add extra information on component test statistics when printing // itself as part of a tree structure - - if (_gofOpMode==SimMaster) { + if (SimMaster == _gofOpMode) { // Forward to slaves - Int_t i ; os << indent << "RooAbsTestStatistic begin GOF contents" << endl ; - for (i=0 ; i<_nGof ; i++) { + for (Int_t i = 0; i < _nGof; ++i) { if (_gofArray[i]) { - TString indent2(indent) ; - indent2 += Form("[%d] ",i) ; - _gofArray[i]->printCompactTreeHook(os,indent2) ; + TString indent2(indent); + indent2 += Form("[%d] ",i); + _gofArray[i]->printCompactTreeHook(os,indent2); } } - os << indent << "RooAbsTestStatistic end GOF contents" << endl ; - } else if (_gofOpMode==MPMaster) { + os << indent << "RooAbsTestStatistic end GOF contents" << endl; + } else if (MPMaster == _gofOpMode) { // WVE implement this } } @@ -374,16 +405,19 @@ void RooAbsTestStatistic::constOptimizeTestStatistic(ConstOpCode opcode, Bool_t { // Forward constant term optimization management calls to component // test statistics - Int_t i ; - initialize() ; - if (_gofOpMode==SimMaster) { + initialize(); + if (SimMaster == _gofOpMode) { // Forward to slaves - for (i=0 ; i<_nGof ; i++) { - if (_gofArray[i]) _gofArray[i]->constOptimizeTestStatistic(opcode,doAlsoTrackingOpt) ; + for (Int_t i = 0; i < _nGof; ++i) { + // In SimComponents Splitting strategy only constOptimize the terms that are actually used + RooFit::MPSplit effSplit = (_mpinterl!=RooFit::Hybrid) ? _mpinterl : _gofSplitMode[i]; + if ( (i % _numSets == _setNum) || (effSplit != RooFit::SimComponents) ) { + if (_gofArray[i]) _gofArray[i]->constOptimizeTestStatistic(opcode,doAlsoTrackingOpt); + } } - } else if (_gofOpMode==MPMaster) { - for (i=0 ; i<_nCPU ; i++) { - _mpfeArray[i]->constOptimizeTestStatistic(opcode,doAlsoTrackingOpt) ; + } else if (MPMaster == _gofOpMode) { + for (Int_t i = 0; i < _nCPU; ++i) { + _mpfeArray[i]->constOptimizeTestStatistic(opcode,doAlsoTrackingOpt); } } } @@ -394,14 +428,14 @@ void RooAbsTestStatistic::constOptimizeTestStatistic(ConstOpCode opcode, Bool_t void RooAbsTestStatistic::setMPSet(Int_t inSetNum, Int_t inNumSets) { // Set MultiProcessor set number identification of this instance - - _setNum = inSetNum ; _numSets = inNumSets ; - if (_gofOpMode==SimMaster) { + _setNum = inSetNum; _numSets = inNumSets; + _extSet = _mpinterl==RooFit::SimComponents ? _setNum : (_numSets - 1); + + if (SimMaster == _gofOpMode) { // Forward to slaves - initialize() ; - Int_t i ; - for (i=0 ; i<_nGof ; i++) { - if (_gofArray[i]) _gofArray[i]->setMPSet(inSetNum,inNumSets) ; + initialize(); + for (Int_t i = 0; i < _nGof; ++i) { + if (_gofArray[i]) _gofArray[i]->setMPSet(inSetNum,inNumSets); } } } @@ -414,27 +448,27 @@ void RooAbsTestStatistic::initMPMode(RooAbsReal* real, RooAbsData* data, const R // Initialize multi-processor calculation mode. Create component test statistics in separate // processed that are connected to this process through a RooAbsRealMPFE front-end class. - Int_t i ; - _mpfeArray = new pRooRealMPFE[_nCPU] ; + _mpfeArray = new pRooRealMPFE[_nCPU]; // Create proto-goodness-of-fit - RooAbsTestStatistic* gof = create(GetName(),GetTitle(),*real,*data,*projDeps,rangeName,addCoefRangeName,1,_mpinterl,_verbose,_splitRange) ; - gof->recursiveRedirectServers(_paramSet) ; - - for (i=0 ; i<_nCPU ; i++) { - - gof->setMPSet(i,_nCPU) ; - gof->SetName(Form("%s_GOF%d",GetName(),i)) ; - gof->SetTitle(Form("%s_GOF%d",GetTitle(),i)) ; - - Bool_t doInline = (i==_nCPU-1) ; - if (!doInline) coutI(Eval) << "RooAbsTestStatistic::initMPMode: starting remote server process #" << i << endl ; - _mpfeArray[i] = new RooRealMPFE(Form("%s_%lx_MPFE%d",GetName(),(ULong_t)this,i),Form("%s_%lx_MPFE%d",GetTitle(),(ULong_t)this,i),*gof,doInline) ; - _mpfeArray[i]->initialize() ; - if (doInline) { - _mpfeArray[i]->addOwnedComponents(*gof) ; + RooAbsTestStatistic* gof = create(GetName(),GetTitle(),*real,*data,*projDeps,rangeName,addCoefRangeName,1,_mpinterl,_verbose,_splitRange); + gof->recursiveRedirectServers(_paramSet); + + for (Int_t i = 0; i < _nCPU; ++i) { + gof->setMPSet(i,_nCPU); + gof->SetName(Form("%s_GOF%d",GetName(),i)); + gof->SetTitle(Form("%s_GOF%d",GetTitle(),i)); + + ccoutD(Eval) << "RooAbsTestStatistic::initMPMode: starting remote server process #" << i << endl; + _mpfeArray[i] = new RooRealMPFE(Form("%s_%lx_MPFE%d",GetName(),(ULong_t)this,i),Form("%s_%lx_MPFE%d",GetTitle(),(ULong_t)this,i),*gof,false); + //_mpfeArray[i]->setVerbose(kTRUE,kTRUE); + _mpfeArray[i]->initialize(); + if (i > 0) { + _mpfeArray[i]->followAsSlave(*_mpfeArray[0]); } } + _mpfeArray[_nCPU - 1]->addOwnedComponents(*gof); + coutI(Eval) << "RooAbsTestStatistic::initMPMode: started " << _nCPU << " remote server process." << endl; //cout << "initMPMode --- done" << endl ; return ; } @@ -451,80 +485,119 @@ void RooAbsTestStatistic::initSimMode(RooSimultaneous* simpdf, RooAbsData* data, // each of them. - RooAbsCategoryLValue& simCat = (RooAbsCategoryLValue&) simpdf->indexCat() ; + RooAbsCategoryLValue& simCat = (RooAbsCategoryLValue&) simpdf->indexCat(); - TString simCatName(simCat.GetName()) ; - TList* dsetList = const_cast<RooAbsData*>(data)->split(simCat,processEmptyDataSets()) ; + TString simCatName(simCat.GetName()); + TList* dsetList = const_cast<RooAbsData*>(data)->split(simCat,processEmptyDataSets()); if (!dsetList) { - coutE(Fitting) << "RooAbsTestStatistic::initSimMode(" << GetName() << ") ERROR: index category of simultaneous pdf is missing in dataset, aborting" << endl ; - throw std::string("RooAbsTestStatistic::initSimMode() ERROR, index category of simultaneous pdf is missing in dataset, aborting") ; + coutE(Fitting) << "RooAbsTestStatistic::initSimMode(" << GetName() << ") ERROR: index category of simultaneous pdf is missing in dataset, aborting" << endl; + throw std::string("RooAbsTestStatistic::initSimMode() ERROR, index category of simultaneous pdf is missing in dataset, aborting"); //RooErrorHandler::softAbort() ; } // Count number of used states - Int_t n(0) ; - _nGof = 0 ; - RooCatType* type ; - TIterator* catIter = simCat.typeIterator() ; - while((type=(RooCatType*)catIter->Next())){ - + Int_t n = 0; + _nGof = 0; + RooCatType* type; + TIterator* catIter = simCat.typeIterator(); + while ((type = (RooCatType*) catIter->Next())) { // Retrieve the PDF for this simCat state - RooAbsPdf* pdf = simpdf->getPdf(type->GetName()) ; - RooAbsData* dset = (RooAbsData*) dsetList->FindObject(type->GetName()) ; + RooAbsPdf* pdf = simpdf->getPdf(type->GetName()); + RooAbsData* dset = (RooAbsData*) dsetList->FindObject(type->GetName()); - if (pdf && dset && (dset->sumEntries()!=0. || processEmptyDataSets() )) { - _nGof++ ; + if (pdf && dset && (0. != dset->sumEntries() || processEmptyDataSets())) { + ++_nGof; } } // Allocate arrays - _gofArray = new pRooAbsTestStatistic[_nGof] ; + _gofArray = new pRooAbsTestStatistic[_nGof]; + _gofSplitMode.resize(_nGof); // Create array of regular fit contexts, containing subset of data and single fitCat PDF - catIter->Reset() ; - while((type=(RooCatType*)catIter->Next())){ - + catIter->Reset(); + while ((type = (RooCatType*) catIter->Next())) { // Retrieve the PDF for this simCat state - RooAbsPdf* pdf = simpdf->getPdf(type->GetName()) ; - RooAbsData* dset = (RooAbsData*) dsetList->FindObject(type->GetName()) ; + RooAbsPdf* pdf = simpdf->getPdf(type->GetName()); + RooAbsData* dset = (RooAbsData*) dsetList->FindObject(type->GetName()); - if (pdf && dset && (dset->sumEntries()!=0. || processEmptyDataSets())) { - coutI(Fitting) << "RooAbsTestStatistic::initSimMode: creating slave calculator #" << n << " for state " << type->GetName() - << " (" << dset->numEntries() << " dataset entries)" << endl ; + if (pdf && dset && (0. != dset->sumEntries() || processEmptyDataSets())) { + ccoutI(Fitting) << "RooAbsTestStatistic::initSimMode: creating slave calculator #" << n << " for state " << type->GetName() + << " (" << dset->numEntries() << " dataset entries)" << endl; + + // WVE HACK determine if we have a RooRealSumPdf and then treat it like a binned likelihood + RooAbsPdf* binnedPdf = 0 ; + if (pdf->getAttribute("BinnedLikelihood") && pdf->IsA()->InheritsFrom(RooRealSumPdf::Class())) { + // Simplest case: top-level of component is a RRSP + binnedPdf = pdf ; + } else if (pdf->IsA()->InheritsFrom(RooProdPdf::Class())) { + // Default case: top-level pdf is a product of RRSP and other pdfs + RooFIter iter = ((RooProdPdf*)pdf)->pdfList().fwdIterator() ; + RooAbsArg* component ; + while ((component = iter.next())) { + if (component->getAttribute("BinnedLikelihood") && component->IsA()->InheritsFrom(RooRealSumPdf::Class())) { + binnedPdf = (RooAbsPdf*) component ; + } + } + } + // WVE END HACK + // Below here directly pass binnedPdf instead of PROD(binnedPdf,constraints) as constraints are evaluated elsewhere anyway + // and omitting them reduces model complexity and associated handling/cloning times if (_splitRange && rangeName) { - _gofArray[n] = create(type->GetName(),type->GetName(),*pdf,*dset,*projDeps, - Form("%s_%s",rangeName,type->GetName()),addCoefRangeName,_nCPU*(_mpinterl?-1:1),_mpinterl,_verbose,_splitRange) ; + _gofArray[n] = create(type->GetName(),type->GetName(),(binnedPdf?*binnedPdf:*pdf),*dset,*projDeps, + Form("%s_%s",rangeName,type->GetName()),addCoefRangeName,_nCPU*(_mpinterl?-1:1),_mpinterl,_verbose,_splitRange,(binnedPdf?kTRUE:kFALSE)); } else { - _gofArray[n] = create(type->GetName(),type->GetName(),*pdf,*dset,*projDeps, - rangeName,addCoefRangeName,_nCPU,_mpinterl,_verbose,_splitRange) ; + _gofArray[n] = create(type->GetName(),type->GetName(),(binnedPdf?*binnedPdf:*pdf),*dset,*projDeps, + rangeName,addCoefRangeName,_nCPU,_mpinterl,_verbose,_splitRange,(binnedPdf?kTRUE:kFALSE)); + } + _gofArray[n]->setSimCount(_nGof); + + // Fill per-component split mode with Bulk Partition for now so that Auto will map to bulk-splitting of all components + if (_mpinterl==RooFit::Hybrid) { + if (dset->numEntries()<10) { + //cout << "RAT::initSim("<< GetName() << ") MP mode is auto, setting split mode for component "<< n << " to SimComponents"<< endl ; + _gofSplitMode[n] = RooFit::SimComponents; + _gofArray[n]->_mpinterl = RooFit::SimComponents; + } else { + //cout << "RAT::initSim("<< GetName() << ") MP mode is auto, setting split mode for component "<< n << " to BulkPartition"<< endl ; + _gofSplitMode[n] = RooFit::BulkPartition; + _gofArray[n]->_mpinterl = RooFit::BulkPartition; + } } - _gofArray[n]->setSimCount(_nGof) ; // Servers may have been redirected between instantiation and (deferred) initialization - _gofArray[n]->recursiveRedirectServers(_paramSet) ; - n++ ; + RooArgSet* actualParams = pdf->getParameters(dset); + RooArgSet* selTargetParams = (RooArgSet*) _paramSet.selectCommon(*actualParams); + + _gofArray[n]->recursiveRedirectServers(*selTargetParams); + + delete selTargetParams; + delete actualParams; + + ++n; + } else { - if ((!dset || (dset->sumEntries()==0. && !processEmptyDataSets()) ) && pdf) { + if ((!dset || (0. != dset->sumEntries() && !processEmptyDataSets())) && pdf) { if (_verbose) { - coutI(Fitting) << "RooAbsTestStatistic::initSimMode: state " << type->GetName() - << " has no data entries, no slave calculator created" << endl ; + ccoutD(Fitting) << "RooAbsTestStatistic::initSimMode: state " << type->GetName() + << " has no data entries, no slave calculator created" << endl; } } } } + coutI(Fitting) << "RooAbsTestStatistic::initSimMode: created " << n << " slave calculators." << endl; // Delete datasets by hand as TList::Delete() doesn't see our datasets as 'on the heap'... - TIterator* iter = dsetList->MakeIterator() ; - TObject* ds ; - while((ds=iter->Next())) { - delete ds ; + TIterator* iter = dsetList->MakeIterator(); + TObject* ds; + while((ds = iter->Next())) { + delete ds; } - delete iter ; - - delete dsetList ; - delete catIter ; + delete iter; + delete dsetList; + delete catIter; } @@ -536,51 +609,88 @@ Bool_t RooAbsTestStatistic::setData(RooAbsData& indata, Bool_t cloneData) // a range specification on the data, the cloneData argument is ignore and // the data is always cloned. - switch(operMode()) { + // Trigger refresh of likelihood offsets + if (isOffsetting()) { + enableOffsetting(kFALSE); + enableOffsetting(kTRUE); + } + switch(operMode()) { case Slave: // Delegate to implementation - return setDataSlave(indata,cloneData) ; - + return setDataSlave(indata, cloneData); case SimMaster: // Forward to slaves - // cout << "RATS::setData(" << GetName() << ") SimMaster, calling setDataSlave() on slave nodes" << endl ; + // cout << "RATS::setData(" << GetName() << ") SimMaster, calling setDataSlave() on slave nodes" << endl; if (indata.canSplitFast()) { - for (Int_t i=0 ; i<_nGof ; i++) { - RooAbsData* compData = indata.getSimData(_gofArray[i]->GetName()) ; - _gofArray[i]->setDataSlave(*compData,cloneData) ; + for (Int_t i = 0; i < _nGof; ++i) { + RooAbsData* compData = indata.getSimData(_gofArray[i]->GetName()); + _gofArray[i]->setDataSlave(*compData, cloneData); } - } else if (indata.numEntries()==0) { + } else if (0 == indata.numEntries()) { // For an unsplit empty dataset, simply assign empty dataset to each component - for (Int_t i=0 ; i<_nGof ; i++) { - _gofArray[i]->setDataSlave(indata,cloneData) ; + for (Int_t i = 0; i < _nGof; ++i) { + _gofArray[i]->setDataSlave(indata, cloneData); } } else { -// cout << "NONEMPTY DATASET WITHOUT FAST SPLIT SUPPORT! "<< indata.GetName() << endl ; - const RooAbsCategoryLValue* indexCat = & ((RooSimultaneous*)_func)->indexCat() ; - TList* dlist = indata.split(*indexCat,kTRUE) ; - for (Int_t i=0 ; i<_nGof ; i++) { - RooAbsData* compData = (RooAbsData*) dlist->FindObject(_gofArray[i]->GetName()) ; - // cout << "component data for index " << _gofArray[i]->GetName() << " is " << compData << endl ; +// cout << "NONEMPTY DATASET WITHOUT FAST SPLIT SUPPORT! "<< indata.GetName() << endl; + const RooAbsCategoryLValue* indexCat = & ((RooSimultaneous*)_func)->indexCat(); + TList* dlist = indata.split(*indexCat, kTRUE); + for (Int_t i = 0; i < _nGof; ++i) { + RooAbsData* compData = (RooAbsData*) dlist->FindObject(_gofArray[i]->GetName()); + // cout << "component data for index " << _gofArray[i]->GetName() << " is " << compData << endl; if (compData) { - _gofArray[i]->setDataSlave(*compData,kFALSE,kTRUE) ; + _gofArray[i]->setDataSlave(*compData,kFALSE,kTRUE); } else { - coutE(DataHandling) << "RooAbsTestStatistic::setData(" << GetName() << ") ERROR: Cannot find component data for state " << _gofArray[i]->GetName() << endl ; - } + coutE(DataHandling) << "RooAbsTestStatistic::setData(" << GetName() << ") ERROR: Cannot find component data for state " << _gofArray[i]->GetName() << endl; + } } - } - break ; - + break; case MPMaster: // Not supported - coutF(DataHandling) << "RooAbsTestStatistic::setData(" << GetName() << ") FATAL: setData() is not supported in multi-processor mode" << endl ; - throw string("RooAbsTestStatistic::setData is not supported in MPMaster mode") ; - break ; + coutF(DataHandling) << "RooAbsTestStatistic::setData(" << GetName() << ") FATAL: setData() is not supported in multi-processor mode" << endl; + throw string("RooAbsTestStatistic::setData is not supported in MPMaster mode"); + break; } - return kTRUE ; + return kTRUE; } +void RooAbsTestStatistic::enableOffsetting(Bool_t flag) +{ + // Apply internal value offsetting to control numeric precision + if (!_init) { + const_cast<RooAbsTestStatistic*>(this)->initialize() ; + } + + switch(operMode()) { + case Slave: + _doOffset = flag ; + // Clear offset if feature is disabled to that it is recalculated next time it is enabled + if (!_doOffset) { + _offset = 0 ; + _offsetCarry = 0; + } + setValueDirty() ; + break ; + case SimMaster: + _doOffset = flag; + for (Int_t i = 0; i < _nGof; ++i) { + _gofArray[i]->enableOffsetting(flag); + } + break ; + case MPMaster: + _doOffset = flag; + for (Int_t i = 0; i < _nCPU; ++i) { + _mpfeArray[i]->enableOffsetting(flag); + } + break; + } +} + + +Double_t RooAbsTestStatistic::getCarry() const +{ return _evalCarry; } diff --git a/roofit/roofitcore/src/RooAcceptReject.cxx b/roofit/roofitcore/src/RooAcceptReject.cxx index b64d62f19c8ff..4f3d836b41d68 100644 --- a/roofit/roofitcore/src/RooAcceptReject.cxx +++ b/roofit/roofitcore/src/RooAcceptReject.cxx @@ -49,6 +49,8 @@ #include <assert.h> +using namespace std; + ClassImp(RooAcceptReject) ; diff --git a/roofit/roofitcore/src/RooAdaptiveIntegratorND.cxx b/roofit/roofitcore/src/RooAdaptiveIntegratorND.cxx index 206b5be7faf4c..fa828baee1383 100644 --- a/roofit/roofitcore/src/RooAdaptiveIntegratorND.cxx +++ b/roofit/roofitcore/src/RooAdaptiveIntegratorND.cxx @@ -41,6 +41,8 @@ +using namespace std; + ClassImp(RooAdaptiveIntegratorND) ; diff --git a/roofit/roofitcore/src/RooAddGenContext.cxx b/roofit/roofitcore/src/RooAddGenContext.cxx index 39db886dc271c..9736115b6ec4f 100644 --- a/roofit/roofitcore/src/RooAddGenContext.cxx +++ b/roofit/roofitcore/src/RooAddGenContext.cxx @@ -40,6 +40,8 @@ #include "RooRandom.h" #include "RooAddModel.h" +using namespace std; + ClassImp(RooAddGenContext) ; @@ -68,7 +70,7 @@ RooAddGenContext::RooAddGenContext(const RooAddPdf &model, const RooArgSet &vars { RooArgSet coefNSet(vars) ; coefNSet.add(*prototype->get()) ; - _pdf->fixAddCoefNormalization(coefNSet) ; + _pdf->fixAddCoefNormalization(coefNSet,kFALSE) ; } model._pdfIter->Reset() ; diff --git a/roofit/roofitcore/src/RooAddModel.cxx b/roofit/roofitcore/src/RooAddModel.cxx index b8acb4d7d1715..fa44d6fd29578 100644 --- a/roofit/roofitcore/src/RooAddModel.cxx +++ b/roofit/roofitcore/src/RooAddModel.cxx @@ -61,6 +61,8 @@ +using namespace std; + ClassImp(RooAddModel) ; diff --git a/roofit/roofitcore/src/RooAddPdf.cxx b/roofit/roofitcore/src/RooAddPdf.cxx index 0a90fa0521a1f..2a22d2c6edcac 100644 --- a/roofit/roofitcore/src/RooAddPdf.cxx +++ b/roofit/roofitcore/src/RooAddPdf.cxx @@ -70,6 +70,8 @@ #include <algorithm> +using namespace std; + ClassImp(RooAddPdf) ; @@ -87,7 +89,7 @@ RooAddPdf::RooAddPdf() : _pdfIter = _pdfList.createIterator() ; _coefIter = _coefList.createIterator() ; - _coefCache = new Double_t[10] ; + _coefCache = new Double_t[100] ; _coefErrCount = _errorCount ; } @@ -112,7 +114,7 @@ RooAddPdf::RooAddPdf(const char *name, const char *title) : _pdfIter = _pdfList.createIterator() ; _coefIter = _coefList.createIterator() ; - _coefCache = new Double_t[10] ; + _coefCache = new Double_t[100] ; _coefErrCount = _errorCount ; } @@ -830,7 +832,7 @@ Double_t RooAddPdf::evaluate() const Double_t pdfVal = pdf->getVal(nset) ; if (pdf->isSelectedComp()) { value += pdfVal*_coefCache[i] ; - // cout << "RooAddPdf::EVALUATE(" << GetName() << ") adding pdf " << pdf->GetName() << " value = " << pdfVal << " coef = " << _coefCache[i] << endl ; +// cout << "RooAddPdf::EVALUATE(" << GetName() << ") adding pdf " << pdf->GetName() << " value = " << pdfVal << " coef = " << _coefCache[i] << endl ; } i++ ; } diff --git a/roofit/roofitcore/src/RooAddition.cxx b/roofit/roofitcore/src/RooAddition.cxx index f7894b7eb324f..7b4771d2e8e28 100644 --- a/roofit/roofitcore/src/RooAddition.cxx +++ b/roofit/roofitcore/src/RooAddition.cxx @@ -57,7 +57,7 @@ RooAddition::RooAddition() //_____________________________________________________________________________ -RooAddition::RooAddition(const char* name, const char* title, const RooArgSet& sumSet, Bool_t takeOwnership) +RooAddition::RooAddition(const char* name, const char* title, const RooArgList& sumSet, Bool_t takeOwnership) : RooAbsReal(name, title) , _set("!set","set of components",this) , _setIter( _set.createIterator() ) // yes, _setIter is defined _after_ _set ;-) @@ -174,6 +174,7 @@ Double_t RooAddition::evaluate() const return sum ; } + //_____________________________________________________________________________ Double_t RooAddition::defaultErrorLevel() const { @@ -223,6 +224,18 @@ Double_t RooAddition::defaultErrorLevel() const } +//_____________________________________________________________________________ +void RooAddition::enableOffsetting(Bool_t flag) +{ + _setIter->Reset() ; + + RooAbsReal* arg; + while((arg=(RooAbsReal*)_setIter->Next())) { + arg->enableOffsetting(flag) ; + } +} + + //_____________________________________________________________________________ Bool_t RooAddition::setData(RooAbsData& data, Bool_t cloneData) diff --git a/roofit/roofitcore/src/RooArgList.cxx b/roofit/roofitcore/src/RooArgList.cxx index 067ce17315658..82411b9f6075f 100644 --- a/roofit/roofitcore/src/RooArgList.cxx +++ b/roofit/roofitcore/src/RooArgList.cxx @@ -54,6 +54,8 @@ #include "RooTrace.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooArgList) ; diff --git a/roofit/roofitcore/src/RooArgProxy.cxx b/roofit/roofitcore/src/RooArgProxy.cxx index 9c7ffbbd50f6a..a90da3b910390 100644 --- a/roofit/roofitcore/src/RooArgProxy.cxx +++ b/roofit/roofitcore/src/RooArgProxy.cxx @@ -105,11 +105,12 @@ Bool_t RooArgProxy::changePointer(const RooAbsCollection& newServerList, Bool_t // Change proxied object to object of same name in given list. If nameChange is true // the replacement object can have a different name and is identified as the replacement object by // the existence of a boolean attribute "origName:MyName" where MyName is the name of this instance - + RooAbsArg* newArg ; Bool_t initEmpty = _arg ? kFALSE : kTRUE ; if (_arg) { newArg= _arg->findNewServer(newServerList, nameChange); + if (newArg==_owner) newArg = 0 ; } else if (factoryInitMode) { newArg = newServerList.first() ; _owner->addServer(*newArg,_valueServer,_shapeServer) ; diff --git a/roofit/roofitcore/src/RooBanner.cxx b/roofit/roofitcore/src/RooBanner.cxx index af65a37e5c5eb..3a2ec0877e16b 100644 --- a/roofit/roofitcore/src/RooBanner.cxx +++ b/roofit/roofitcore/src/RooBanner.cxx @@ -1,6 +1,5 @@ #include "RooFit.h" -#include "Rtypes.h" #include "Rtypes.h" #include "Riostream.h" @@ -11,7 +10,9 @@ // END_HTML // -const char* VTAG="3.53" ; +using namespace std; + +const char* VTAG="3.59" ; Int_t doBanner() @@ -19,7 +20,7 @@ Int_t doBanner() #ifndef __ROOFIT_NOBANNER cout << endl << "\033[1mRooFit v" << VTAG << " -- Developed by Wouter Verkerke and David Kirkby\033[0m " << endl - << " Copyright (C) 2000-2012 NIKHEF, University of California & Stanford University" << endl + << " Copyright (C) 2000-2013 NIKHEF, University of California & Stanford University" << endl << " All rights reserved, please read http://roofit.sourceforge.net/license.txt" << endl << endl ; #endif return 0 ; diff --git a/roofit/roofitcore/src/RooBinIntegrator.cxx b/roofit/roofitcore/src/RooBinIntegrator.cxx index 114e859e83865..d4aa56e5eea74 100644 --- a/roofit/roofitcore/src/RooBinIntegrator.cxx +++ b/roofit/roofitcore/src/RooBinIntegrator.cxx @@ -40,6 +40,8 @@ +using namespace std; + ClassImp(RooBinIntegrator) ; diff --git a/roofit/roofitcore/src/RooBinnedGenContext.cxx b/roofit/roofitcore/src/RooBinnedGenContext.cxx index cd9d885b4af4a..7bcc3ed6d32cc 100644 --- a/roofit/roofitcore/src/RooBinnedGenContext.cxx +++ b/roofit/roofitcore/src/RooBinnedGenContext.cxx @@ -36,6 +36,8 @@ #include "RooDataSet.h" #include "RooRandom.h" +using namespace std; + ClassImp(RooBinnedGenContext) ; @@ -131,7 +133,7 @@ void RooBinnedGenContext::setExpectedData(Bool_t flag) //_____________________________________________________________________________ -RooDataSet *RooBinnedGenContext::generate(Int_t nEvt, Bool_t /*skipInit*/, Bool_t extended) +RooDataSet *RooBinnedGenContext::generate(Double_t nEvt, Bool_t /*skipInit*/, Bool_t extended) { // Scale to number of events and introduce Poisson fluctuations @@ -146,7 +148,7 @@ RooDataSet *RooBinnedGenContext::generate(Int_t nEvt, Bool_t /*skipInit*/, Bool_ return 0 ; } else { // Don't round in expectedData mode - if (_expectedData) { + if (_expectedData || extended) { nEvents = _pdf->expectedEvents(_vars) ; } else { nEvents = Int_t(_pdf->expectedEvents(_vars)+0.5) ; @@ -229,18 +231,7 @@ RooDataSet *RooBinnedGenContext::generate(Int_t nEvt, Bool_t /*skipInit*/, Bool_ wudata->add(*_hist->get(),histOut[i]) ; } - } else if (_expectedData) { - - // Second pass for expectedData mode -- Normalize to exact number of requested events - // Minor difference may be present in first round due to difference between - // bin average and bin integral in sampling bins - Double_t corr = nEvents/_hist->sumEntries() ; - for (int i=0 ; i<_hist->numEntries() ; i++) { - _hist->get(i) ; - wudata->add(*_hist->get(),_hist->weight()*corr) ; - } - - } + } return wudata ; diff --git a/roofit/roofitcore/src/RooBinning.cxx b/roofit/roofitcore/src/RooBinning.cxx index 748f9b5bdd3df..35c01c1ac4211 100644 --- a/roofit/roofitcore/src/RooBinning.cxx +++ b/roofit/roofitcore/src/RooBinning.cxx @@ -15,16 +15,18 @@ *****************************************************************************/ ////////////////////////////////////////////////////////////////////////////// -// -// BEGIN_HTML +// +// BEGIN_HTML // Class RooBinning is an implements RooAbsBinning in terms // of an array of boundary values, posing no constraints on the choice // of binning, thus allowing variable bin sizes. Various methods allow // the user to add single bin boundaries, mirrored pairs, or sets of -// uniformly spaced boundaries. +// uniformly spaced boundaries. // END_HTML // +#include <cmath> +#include <algorithm> #include "RooFit.h" #include "Riostream.h" @@ -37,376 +39,268 @@ #include "RooMsgService.h" #include "TList.h" +using namespace std; + ClassImp(RooBinning) ; //_____________________________________________________________________________ -RooBinning::RooBinning(Double_t xlo, Double_t xhi, const char* name) : - RooAbsBinning(name), - _xlo(0), - _xhi(0), - _ownBoundLo(kTRUE), - _ownBoundHi(kTRUE), - _array(0) +RooBinning::RooBinning(Double_t xlo, Double_t xhi, const char* name) : + RooAbsBinning(name), + _xlo(0), _xhi(0), _ownBoundLo(kTRUE), _ownBoundHi(kTRUE), + _array(0), _blo(0) { // Constructor for an initially empty binning defining the range [xlo,xhi] - - setRange(xlo,xhi) ; + setRange(xlo,xhi); } - - //_____________________________________________________________________________ -RooBinning::RooBinning(Int_t nbins, Double_t xlo, Double_t xhi, const char* name) : - RooAbsBinning(name), - _xlo(0), - _xhi(0), - _ownBoundLo(kTRUE), - _ownBoundHi(kTRUE), - _array(0) +RooBinning::RooBinning(Int_t nbins, Double_t xlo, Double_t xhi, const char* name) : + RooAbsBinning(name), + _xlo(0), _xhi(0), _ownBoundLo(kTRUE), _ownBoundHi(kTRUE), + _array(0), _blo(0) { // Constructor for a uniform binning in 'nbins' bins in the range [xlo,xhi] - - // Uniform bin size constructor - setRange(xlo,xhi) ; - addUniform(nbins,xlo,xhi) ; + _boundaries.reserve(1 + nbins); + setRange(xlo, xhi); + addUniform(nbins, xlo, xhi); } - - - //_____________________________________________________________________________ -RooBinning::RooBinning(Int_t nbins, const Double_t* boundaries, const char* name) : +RooBinning::RooBinning(Int_t nbins, const Double_t* boundaries, const char* name) : RooAbsBinning(name), - _xlo(0), - _xhi(0), - _ownBoundLo(kTRUE), - _ownBoundHi(kTRUE), - _array(0) + _xlo(0), _xhi(0), _ownBoundLo(kTRUE), _ownBoundHi(kTRUE), + _array(0), _blo(0) { // Constructor for a binning in the range[xlo,xhi] with 'nbins' bin boundaries listed // array 'boundaries' // Variable bin size constructor - setRange(boundaries[0],boundaries[nbins]) ; - while(nbins--) addBoundary(boundaries[nbins]) ; + _boundaries.reserve(1 + nbins); + setRange(boundaries[0], boundaries[nbins]); + while (nbins--) addBoundary(boundaries[nbins]); } - - //_____________________________________________________________________________ -RooBinning::RooBinning(const RooBinning& other, const char* name) : - RooAbsBinning(name), - _boundaries(other._boundaries), - _array(0) -{ +RooBinning::RooBinning(const RooBinning& other, const char* name) : + RooAbsBinning(name), _xlo(other._xlo), _xhi(other._xhi), + _ownBoundLo(other._ownBoundLo), _ownBoundHi(other._ownBoundHi), + _nbins(other._nbins), _boundaries(other._boundaries), _array(0), + _blo(other._blo) +{ // Copy constructor - _xlo = other._xlo ; - _xhi = other._xhi ; - _ownBoundLo = other._ownBoundLo ; - _ownBoundHi = other._ownBoundHi ; - _nbins = other._nbins ; } - - //_____________________________________________________________________________ -RooBinning::~RooBinning() +RooBinning::~RooBinning() { // Destructor - - if (_array) delete[] _array ; - + delete[] _array; } - //_____________________________________________________________________________ -Bool_t RooBinning::addBoundary(Double_t boundary) -{ +Bool_t RooBinning::addBoundary(Double_t boundary) +{ // Add bin boundary at given value - - if (_boundaries.find(boundary)!=_boundaries.end()) { - // If boundary previously existed as range delimiter, + std::vector<Double_t>::iterator it = + std::lower_bound(_boundaries.begin(), _boundaries.end(), boundary); + if (_boundaries.end() != it && *it == boundary) { + // If boundary previously existed as range delimiter, // convert to regular boundary now - if (boundary==_xlo) _ownBoundLo = kFALSE ; - if (boundary==_xhi) _ownBoundHi = kFALSE ; - return kFALSE ; + if (boundary == _xlo) _ownBoundLo = kFALSE; + if (boundary == _xhi) _ownBoundHi = kFALSE; + return kFALSE; } - // Add a new boundary - _boundaries.insert(boundary) ; - updateBinCount() ; - return kTRUE ; + _boundaries.insert(it, boundary); + updateBinCount(); + return kTRUE; } - - //_____________________________________________________________________________ -void RooBinning::addBoundaryPair(Double_t boundary, Double_t mirrorPoint) +void RooBinning::addBoundaryPair(Double_t boundary, Double_t mirrorPoint) { // Add pair of boundaries: one at 'boundary' and one at 2*mirrorPoint-boundary - - addBoundary(boundary) ; - addBoundary(2*mirrorPoint-boundary) ; + addBoundary(boundary); + addBoundary(2. * mirrorPoint - boundary); } - - //_____________________________________________________________________________ Bool_t RooBinning::removeBoundary(Double_t boundary) { // Remove boundary at given value - - if (_boundaries.find(boundary)!=_boundaries.end()) { - _boundaries.erase(boundary) ; - return kFALSE ; + std::vector<Double_t>::iterator it = std::lower_bound(_boundaries.begin(), + _boundaries.end(), boundary); + if (_boundaries.end() != it && *it == boundary) { + _boundaries.erase(it); + // if some moron deletes the boundaries corresponding to the current + // range, we need to make sure that we do not get into an undefined state, + // so _xlo and _xhi need to be set to some valid values + if (_boundaries.empty()) { + _xlo = _xhi = 0.; + } else { + if (boundary == _xlo) _xlo = _boundaries.front(); + if (boundary == _xhi) _xhi = _boundaries.back(); + } + updateBinCount(); + return kFALSE; } - // Return error status - no boundary found - return kTRUE ; + return kTRUE; } - - //_____________________________________________________________________________ Bool_t RooBinning::hasBoundary(Double_t boundary) { // Check if boundary exists at given value - - return (_boundaries.find(boundary)!=_boundaries.end()) ; + return std::binary_search(_boundaries.begin(), _boundaries.end(), boundary); } - - //_____________________________________________________________________________ void RooBinning::addUniform(Int_t nbins, Double_t xlo, Double_t xhi) { // Add array of nbins uniformly sized bins in range [xlo,xhi] - - Int_t i ; - Double_t binw = (xhi-xlo)/nbins ; - for (i=0 ; i<=nbins ; i++) - addBoundary(xlo+i*binw) ; + _boundaries.reserve(_boundaries.size() + nbins + 1); + for (Int_t i = 0; i <= nbins; ++i) + addBoundary((double(nbins - i) / double(nbins)) * xlo + + (double(i) / double(nbins)) * xhi); } - - //_____________________________________________________________________________ Int_t RooBinning::binNumber(Double_t x) const { // Return sequential bin number that contains value x where bin // zero is the first bin with an upper boundary above the lower bound // of the range - - Int_t n(0) ; - for (set<Double_t>::const_iterator iter = _boundaries.begin() ; iter!=_boundaries.end() ; ++iter) { - if (x<*iter) { - return n ; - } - - // Only increment counter in valid range - if (*iter> _xlo && n<_nbins-1) n++ ; - } - return n; + return std::max(0, std::min(_nbins, rawBinNumber(x) - _blo)); } - - //_____________________________________________________________________________ -Int_t RooBinning::rawBinNumber(Double_t x) const +Int_t RooBinning::rawBinNumber(Double_t x) const { // Return sequential bin number that contains value x where bin // zero is the first bin that is defined, regardless if that bin // is outside the current defined range - - - // Determine 'raw' bin number (i.e counting all defined boundaries) for given value - Int_t n(0) ; - - for (set<Double_t>::const_iterator iter = _boundaries.begin() ; iter!=_boundaries.end() ; ++iter) { - if (x<*iter) return n>0?n-1:0 ; - n++ ; - } - return n-1; + std::vector<Double_t>::const_iterator it = std::lower_bound( + _boundaries.begin(), _boundaries.end(), x); + // always return valid bin number + while (_boundaries.begin() != it && + (_boundaries.end() == it || _boundaries.end() == it + 1 || x < *it)) --it; + return it - _boundaries.begin(); } - - //_____________________________________________________________________________ -Double_t RooBinning::nearestBoundary(Double_t x) const +Double_t RooBinning::nearestBoundary(Double_t x) const { // Return the value of the nearest boundary to x - - Int_t bn = binNumber(x) ; - if (fabs(binLow(bn)-x)<fabs(binHigh(bn)-x)) { - return binLow(bn) ; - } else { - return binHigh(bn) ; - } + Double_t xl, xh; + binEdges(binNumber(x), xl, xh); + return (std::abs(xl - x) < std::abs(xh - x)) ? xl : xh; } - - //_____________________________________________________________________________ Double_t* RooBinning::array() const { // Return array of boundary values - if (_array) delete[] _array ; - _array = new Double_t[numBoundaries()] ; - - Int_t i(0) ; - for (set<Double_t>::const_iterator iter = _boundaries.begin() ; iter!=_boundaries.end() ; ++iter) { - if (*iter>=_xlo && *iter <=_xhi) { - _array[i++] = *iter ; - } - } - return _array ; + delete[] _array; + _array = new Double_t[numBoundaries()]; + std::copy(&_boundaries[_blo], &_boundaries[_blo + _nbins + 1], _array); + return _array; } - - //_____________________________________________________________________________ -void RooBinning::setRange(Double_t xlo, Double_t xhi) +void RooBinning::setRange(Double_t xlo, Double_t xhi) { // Change the defined range associated with this binning. // Bins that lie outside the new range [xlo,xhi] will not be // removed, but will be 'inactive', i.e. the new 0 bin will // be the first bin with an upper boundarie > xlo - - if (xlo>xhi) { - coutE(InputArguments) << "RooUniformBinning::setRange: ERROR low bound > high bound" << endl ; - return ; - } - - // Remove previous boundaries - - for (set<Double_t>::iterator iter = _boundaries.begin() ; iter!=_boundaries.end() ;) { - if ((*iter == _xlo && _ownBoundLo) || (*iter == _xhi && _ownBoundHi)) { - _boundaries.erase(iter++) ; - } else { - ++iter ; - } - } - - // Insert boundaries at range delimiter, if necessary - _ownBoundLo = kFALSE ; - _ownBoundHi = kFALSE ; - if (!hasBoundary(xlo)) { - addBoundary(xlo) ; - _ownBoundLo = kTRUE ; + if (xlo > xhi) { + coutE(InputArguments) << "RooBinning::setRange: ERROR low bound > high bound" << endl; + return; } - if (!hasBoundary(xhi)) { - addBoundary(xhi) ; - _ownBoundHi = kTRUE ; - } - - _xlo = xlo ; - _xhi = xhi ; - - // Count number of bins with new range - updateBinCount() ; + // Remove previous boundaries + if (_ownBoundLo) removeBoundary(_xlo); + if (_ownBoundHi) removeBoundary(_xhi); + // Insert boundaries at range delimiter, if necessary + _ownBoundLo = addBoundary(xlo); + _ownBoundHi = addBoundary(xhi); + _xlo = xlo, _xhi = xhi; + // Count number of bins with new range + updateBinCount(); } - - - //_____________________________________________________________________________ void RooBinning::updateBinCount() { // Update the internal bin counter - - Int_t i(-1) ; - for (set<Double_t>::const_iterator iter = _boundaries.begin() ; iter!=_boundaries.end() ; ++iter) { - if (*iter>=_xlo && *iter <=_xhi) { - i++ ; - } + if (_boundaries.size() <= 1) { + _nbins = -1; + return; } - _nbins = i ; + _blo = rawBinNumber(_xlo); + std::vector<Double_t>::const_iterator it = std::lower_bound( + _boundaries.begin(), _boundaries.end(), _xhi); + if (_boundaries.begin() != it && (_boundaries.end() == it || _xhi < *it)) --it; + const Int_t bhi = it - _boundaries.begin(); + _nbins = bhi - _blo; } - - //_____________________________________________________________________________ -Bool_t RooBinning::binEdges(Int_t bin, Double_t& xlo, Double_t& xhi) const +Bool_t RooBinning::binEdges(Int_t bin, Double_t& xlo, Double_t& xhi) const { // Return upper and lower bound of bin 'bin'. If the return value // is true an error occurred - - if (bin<0 || bin>= _nbins) { - coutE(InputArguments) << "RooBinning::binEdges ERROR: bin number must be in range (0," << _nbins << ")" << endl ; - return kTRUE ; + if (0 > bin || bin >= _nbins) { + coutE(InputArguments) << "RooBinning::binEdges ERROR: bin number must be in range (0," << _nbins << ")" << endl; + return kTRUE; } - - // Determine sequential bin number for given value - Int_t n(0) ; - for (set<Double_t>::const_iterator iter = _boundaries.begin() ; iter!=_boundaries.end() ; ++iter) { - - if (n==bin && *iter>=_xlo) { - xlo = *iter ; - iter++ ; - xhi = *iter ; - return kFALSE ; - } - - // Only increment counter in valid range - if (*iter>= _xlo && n<_nbins-1) n++ ; - } - - return kTRUE ; + xlo = _boundaries[bin + _blo], xhi = _boundaries[bin + _blo + 1]; + return kFALSE; } - - //_____________________________________________________________________________ -Double_t RooBinning::binCenter(Int_t bin) const +Double_t RooBinning::binCenter(Int_t bin) const { // Return the position of the center of bin 'bin' - Double_t xlo,xhi ; - if (binEdges(bin,xlo,xhi)) return 0 ; - return (xlo+xhi)/2 ; + Double_t xlo, xhi; + if (binEdges(bin, xlo, xhi)) return 0; + return 0.5 * (xlo + xhi); } - - //_____________________________________________________________________________ -Double_t RooBinning::binWidth(Int_t bin) const +Double_t RooBinning::binWidth(Int_t bin) const { // Return the width of the requested bin - Double_t xlo,xhi ; - if (binEdges(bin,xlo,xhi)) return 0 ; - return (xhi-xlo); + Double_t xlo, xhi; + if (binEdges(bin, xlo, xhi)) return 0; + return (xhi - xlo); } - - //_____________________________________________________________________________ -Double_t RooBinning::binLow(Int_t bin) const +Double_t RooBinning::binLow(Int_t bin) const { // Return the lower bound of the requested bin - Double_t xlo,xhi ; - if (binEdges(bin,xlo,xhi)) return 0 ; - return xlo ; + Double_t xlo, xhi; + if (binEdges(bin, xlo, xhi)) return 0; + return xlo; } - - //_____________________________________________________________________________ -Double_t RooBinning::binHigh(Int_t bin) const +Double_t RooBinning::binHigh(Int_t bin) const { // Return the upper bound of the requested bin - Double_t xlo,xhi ; - if (binEdges(bin,xlo,xhi)) return 0 ; - return xhi ; + Double_t xlo, xhi; + if (binEdges(bin, xlo, xhi)) return 0; + return xhi; } - - //______________________________________________________________________________ void RooBinning::Streamer(TBuffer &R__b) { @@ -416,31 +310,45 @@ void RooBinning::Streamer(TBuffer &R__b) UInt_t R__s, R__c; Version_t R__v = R__b.ReadVersion(&R__s, &R__c); if (R__v) { } - if (R__v>1) { - R__b.ReadClassBuffer(RooBinning::Class(),this,R__v,R__s,R__c); - } else { - RooAbsBinning::Streamer(R__b); - R__b >> _xlo; - R__b >> _xhi; - R__b >> _ownBoundLo; - R__b >> _ownBoundHi; - R__b >> _nbins; - - // Convert TList to set<double> - TList boundaries ; - boundaries.Streamer(R__b); - TIterator* iter = boundaries.MakeIterator() ; - RooDouble* elem ; - while((elem=(RooDouble*)iter->Next())) { - _boundaries.insert(*elem) ; - } - delete iter ; - - R__b.CheckByteCount(R__s, R__c, RooBinning::IsA()); + switch (R__v) { + case 3: + // current version - fallthrough intended + case 2: + // older version with std::set<Double_t> instead of + // std::vector<Double_t>, apparently ROOT is clever enough to not care + // about set vs vector + R__b.ReadClassBuffer(RooBinning::Class(), this, R__v, R__s, R__c); + break; + case 1: + { + RooAbsBinning::Streamer(R__b); + R__b >> _xlo; + R__b >> _xhi; + R__b >> _ownBoundLo; + R__b >> _ownBoundHi; + R__b >> _nbins; + + _boundaries.clear(); + // Convert TList to std::vector<Double_t> + TList tmp; + tmp.Streamer(R__b); + _boundaries.reserve(tmp.GetSize()); + TIterator* it = tmp.MakeIterator(); + for (RooDouble* el = (RooDouble*) it->Next(); el; + el = (RooDouble*) it->Next()) _boundaries.push_back(*el); + delete it; + } + R__b.CheckByteCount(R__s, R__c, RooBinning::IsA()); + break; + default: + throw std::string("Unknown class version!"); + } + if (_boundaries.size() > 2) { + std::sort(_boundaries.begin(), _boundaries.end()); + _boundaries.erase(std::unique(_boundaries.begin(), _boundaries.end()), + _boundaries.end()); } } else { R__b.WriteClassBuffer(RooBinning::Class(),this); } } - - diff --git a/roofit/roofitcore/src/RooBinningCategory.cxx b/roofit/roofitcore/src/RooBinningCategory.cxx index 6fa94e1eaa7cb..00878354fe202 100644 --- a/roofit/roofitcore/src/RooBinningCategory.cxx +++ b/roofit/roofitcore/src/RooBinningCategory.cxx @@ -35,19 +35,21 @@ #include "RooThreshEntry.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooBinningCategory) //_____________________________________________________________________________ RooBinningCategory::RooBinningCategory(const char *name, const char *title, RooAbsRealLValue& inputVar, - const char* binningName) : + const char* binningName, const char* catTypeName) : RooAbsCategory(name, title), _inputVar("inputVar","Input category",this,inputVar), _bname(binningName) { // Constructor with input function to be mapped and name and index of default // output state of unmapped values - initialize() ; + initialize(catTypeName) ; } @@ -72,14 +74,15 @@ RooBinningCategory::~RooBinningCategory() //_____________________________________________________________________________ -void RooBinningCategory::initialize() +void RooBinningCategory::initialize(const char* catTypeName) { // Iterator over all bins in input variable and define corresponding state labels Int_t nbins = ((RooAbsRealLValue&)_inputVar.arg()).getBinning(_bname.Length()>0?_bname.Data():0).numBins() ; for (Int_t i=0 ; i<nbins ; i++) { - string name = (_bname.Length()>0) ? Form("%s_%s_bin%d",_inputVar.arg().GetName(),_bname.Data(),i) - : Form("%s_bin%d",_inputVar.arg().GetName(),i) ; + string name = catTypeName!=0 ? Form("%s%d",catTypeName,i) + : (_bname.Length()>0 ? Form("%s_%s_bin%d",_inputVar.arg().GetName(),_bname.Data(),i) + : Form("%s_bin%d",_inputVar.arg().GetName(),i)) ; defineType(name.c_str(),i) ; } } diff --git a/roofit/roofitcore/src/RooBrentRootFinder.cxx b/roofit/roofitcore/src/RooBrentRootFinder.cxx index 73e570b181d5c..294f3c844b0da 100644 --- a/roofit/roofitcore/src/RooBrentRootFinder.cxx +++ b/roofit/roofitcore/src/RooBrentRootFinder.cxx @@ -32,6 +32,8 @@ #include "Riostream.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooBrentRootFinder) ; diff --git a/roofit/roofitcore/src/RooCachedPdf.cxx b/roofit/roofitcore/src/RooCachedPdf.cxx index 407978f25d1e7..7a40c813f6d04 100644 --- a/roofit/roofitcore/src/RooCachedPdf.cxx +++ b/roofit/roofitcore/src/RooCachedPdf.cxx @@ -26,6 +26,8 @@ #include "RooDataHist.h" #include "RooHistPdf.h" +using namespace std; + ClassImp(RooCachedPdf) ; diff --git a/roofit/roofitcore/src/RooCachedReal.cxx b/roofit/roofitcore/src/RooCachedReal.cxx index 1a5ec1128920b..ccb5323764ed9 100644 --- a/roofit/roofitcore/src/RooCachedReal.cxx +++ b/roofit/roofitcore/src/RooCachedReal.cxx @@ -25,6 +25,9 @@ #include "RooMsgService.h" #include "RooDataHist.h" #include "RooHistPdf.h" +#include "RooChangeTracker.h" + +using namespace std; ClassImp(RooCachedReal) ; @@ -34,7 +37,8 @@ ClassImp(RooCachedReal) RooCachedReal::RooCachedReal(const char *name, const char *title, RooAbsReal& _func) : RooAbsCachedReal(name,title), func("func","func",this,_func), - _useCdfBoundaries(kFALSE) + _useCdfBoundaries(kFALSE), + _cacheSource(kFALSE) { // Constructor taking name, title and function to be cached. To control // granularity of the binning of the cache histogram set the desired properties @@ -52,7 +56,8 @@ RooCachedReal::RooCachedReal(const char *name, const char *title, RooAbsReal& _f RooAbsCachedReal(name,title), func("func","func",this,_func), _cacheObs("cacheObs","cacheObs",this,kFALSE,kFALSE), - _useCdfBoundaries(kFALSE) + _useCdfBoundaries(kFALSE), + _cacheSource(kFALSE) { // Constructor taking name, title and function to be cached and // fixed choice of variable to cache. To control granularity of the @@ -80,7 +85,8 @@ RooCachedReal::RooCachedReal(const RooCachedReal& other, const char* name) : RooAbsCachedReal(other,name), func("func",this,other.func), _cacheObs("cacheObs",this,other._cacheObs), - _useCdfBoundaries(other._useCdfBoundaries) + _useCdfBoundaries(other._useCdfBoundaries), + _cacheSource(other._cacheSource) { // Copy constructor } @@ -94,6 +100,23 @@ RooCachedReal::~RooCachedReal() } +//_____________________________________________________________________________ +RooAbsCachedReal::FuncCacheElem* RooCachedReal::createCache(const RooArgSet* nset) const +{ + // Interface function to create an internal cache object that represent + // each cached function configuration. This interface allows to create and + // return a class derived from RooAbsCachedReal::FuncCacheElem so that + // a derived class fillCacheObject implementation can utilize extra functionality + // defined in such a derived cache class + + FuncCacheElem* ret = RooAbsCachedReal::createCache(nset) ; + if (_cacheSource) { + ret->setCacheSource(kTRUE) ; + } + return ret ; +} + + //_____________________________________________________________________________ void RooCachedReal::fillCacheObject(RooAbsCachedReal::FuncCacheElem& cache) const @@ -104,9 +127,27 @@ void RooCachedReal::fillCacheObject(RooAbsCachedReal::FuncCacheElem& cache) cons coutP(Eval) << "RooCachedReal::fillCacheObject(" << GetName() << ") filling multi-dimensional cache (" << cache.hist()->numEntries() << " points)" ; } - func.arg().fillDataHist(cache.hist(),0,1.0,kFALSE,kFALSE) ; - cache.func()->setCdfBoundaries(_useCdfBoundaries) ; + // Make deep clone of self and attach to dataset observables + if (!cache.sourceClone()) { + RooAbsArg* sourceClone = func.arg().cloneTree() ; + cache.setSourceClone((RooAbsReal*)sourceClone) ; + cache.sourceClone()->recursiveRedirectServers(*cache.hist()->get()) ; + cache.sourceClone()->recursiveRedirectServers(cache.paramTracker()->parameters()); + } + + // Iterator over all bins of RooDataHist and fill weights + for (Int_t i=0 ; i<cache.hist()->numEntries() ; i++) { + const RooArgSet* obs = cache.hist()->get(i) ; + Double_t binVal = cache.sourceClone()->getVal(obs) ; + cache.hist()->set(binVal) ; + } + // Delete source clone if we don't cache it + if (!cache.cacheSource()) { + cache.setSourceClone(0) ; + } + + cache.func()->setCdfBoundaries(_useCdfBoundaries) ; if (cache.hist()->get()->getSize()>1) { ccoutP(Eval) << endl ; } diff --git a/roofit/roofitcore/src/RooCatType.cxx b/roofit/roofitcore/src/RooCatType.cxx index f2457e7c0deb5..0f47563f4aedf 100644 --- a/roofit/roofitcore/src/RooCatType.cxx +++ b/roofit/roofitcore/src/RooCatType.cxx @@ -33,6 +33,8 @@ #include "Riostream.h" +using namespace std; + ClassImp(RooCatType) ; diff --git a/roofit/roofitcore/src/RooCategory.cxx b/roofit/roofitcore/src/RooCategory.cxx index dab5d24cc2c1c..da85435f3794f 100644 --- a/roofit/roofitcore/src/RooCategory.cxx +++ b/roofit/roofitcore/src/RooCategory.cxx @@ -37,6 +37,8 @@ #include "RooStreamParser.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooCategory) ; @@ -257,9 +259,14 @@ void RooCategory::addToRange(const char* name, const char* stateNameList) //_____________________________________________________________________________ Bool_t RooCategory::isStateInRange(const char* rangeName, const char* stateName) const { + // If no range is specified [ i.e. the default range ] all category states are in range + if (!rangeName) { + return kTRUE ; + } + // Check that both input arguments are not null pointers - if (!rangeName||!stateName) { - coutE(InputArguments) << "RooCategory::isStateInRange(" << GetName() << ") ERROR: must specificy valid range name and state name" << endl ; + if (!stateName) { + coutE(InputArguments) << "RooCategory::isStateInRange(" << GetName() << ") ERROR: must specificy valid state name" << endl ; return kFALSE ; } diff --git a/roofit/roofitcore/src/RooCategoryProxy.cxx b/roofit/roofitcore/src/RooCategoryProxy.cxx index 4076217cbbe75..cf6d1df9e8278 100644 --- a/roofit/roofitcore/src/RooCategoryProxy.cxx +++ b/roofit/roofitcore/src/RooCategoryProxy.cxx @@ -32,6 +32,8 @@ #include "RooArgSet.h" #include "RooCategoryProxy.h" +using namespace std; + ClassImp(RooCategoryProxy) ; diff --git a/roofit/roofitcore/src/RooChi2Var.cxx b/roofit/roofitcore/src/RooChi2Var.cxx index e4c7900b2f597..1918498794b1e 100644 --- a/roofit/roofitcore/src/RooChi2Var.cxx +++ b/roofit/roofitcore/src/RooChi2Var.cxx @@ -42,6 +42,8 @@ #include "RooAbsDataStore.h" +using namespace std; + ClassImp(RooChi2Var) ; @@ -57,6 +59,7 @@ RooChi2Var::RooChi2Var(const char *name, const char* title, RooAbsReal& func, Ro RooCmdConfig::decodeStringOnTheFly("RooChi2Var::RooChi2Var","RangeWithName",0,"",arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9), 0, RooCmdConfig::decodeIntOnTheFly("RooChi2Var::RooChi2Var","NumCPU",0,1,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9), + RooFit::Interleave, RooCmdConfig::decodeIntOnTheFly("RooChi2Var::RooChi2Var","Verbose",0,1,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9), 0) // RooChi2Var constructor. Optional arguments taken @@ -67,15 +70,25 @@ RooChi2Var::RooChi2Var(const char *name, const char* title, RooAbsReal& func, Ro // Verbose() -- Verbose output of GOF framework { RooCmdConfig pc("RooChi2Var::RooChi2Var") ; - pc.defineInt("etype","DataError",0,(Int_t)RooDataHist::SumW2) ; + pc.defineInt("etype","DataError",0,(Int_t)RooDataHist::Auto) ; + pc.defineInt("extended","Extended",0,kFALSE) ; pc.allowUndefined() ; pc.process(arg1) ; pc.process(arg2) ; pc.process(arg3) ; pc.process(arg4) ; pc.process(arg5) ; pc.process(arg6) ; pc.process(arg7) ; pc.process(arg8) ; pc.process(arg9) ; - _funcMode = Function ; + if (func.IsA()->InheritsFrom(RooAbsPdf::Class())) { + _funcMode = pc.getInt("extended") ? ExtendedPdf : Pdf ; + } else { + _funcMode = Function ; + } _etype = (RooDataHist::ErrorType) pc.getInt("etype") ; + + if (_etype==RooAbsData::Auto) { + _etype = hdata.isNonPoissonWeighted()? RooAbsData::SumW2 : RooAbsData::Expected ; + } + } @@ -91,6 +104,7 @@ RooChi2Var::RooChi2Var(const char *name, const char* title, RooAbsPdf& pdf, RooD RooCmdConfig::decodeStringOnTheFly("RooChi2Var::RooChi2Var","RangeWithName",0,"",arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9), RooCmdConfig::decodeStringOnTheFly("RooChi2Var::RooChi2Var","AddCoefRange",0,"",arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9), RooCmdConfig::decodeIntOnTheFly("RooChi2Var::RooChi2Var","NumCPU",0,1,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9), + RooFit::Interleave, RooCmdConfig::decodeIntOnTheFly("RooChi2Var::RooChi2Var","Verbose",0,1,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9), RooCmdConfig::decodeIntOnTheFly("RooChi2Var::RooChi2Var","SplitRange",0,0,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9)) // RooChi2Var constructor. Optional arguments taken @@ -106,7 +120,7 @@ RooChi2Var::RooChi2Var(const char *name, const char* title, RooAbsPdf& pdf, RooD { RooCmdConfig pc("RooChi2Var::RooChi2Var") ; pc.defineInt("extended","Extended",0,kFALSE) ; - pc.defineInt("etype","DataError",0,(Int_t)RooDataHist::SumW2) ; + pc.defineInt("etype","DataError",0,(Int_t)RooDataHist::Auto) ; pc.allowUndefined() ; pc.process(arg1) ; pc.process(arg2) ; pc.process(arg3) ; @@ -115,6 +129,9 @@ RooChi2Var::RooChi2Var(const char *name, const char* title, RooAbsPdf& pdf, RooD _funcMode = pc.getInt("extended") ? ExtendedPdf : Pdf ; _etype = (RooDataHist::ErrorType) pc.getInt("etype") ; + if (_etype==RooAbsData::Auto) { + _etype = hdata.isNonPoissonWeighted()? RooAbsData::SumW2 : RooAbsData::Expected ; + } } @@ -122,7 +139,7 @@ RooChi2Var::RooChi2Var(const char *name, const char* title, RooAbsPdf& pdf, RooD //_____________________________________________________________________________ RooChi2Var::RooChi2Var(const char *name, const char *title, RooAbsPdf& pdf, RooDataHist& hdata, Bool_t extended, const char* cutRange, const char* addCoefRange, - Int_t nCPU, Bool_t interleave, Bool_t verbose, Bool_t splitCutRange, RooDataHist::ErrorType etype) : + Int_t nCPU, RooFit::MPSplit interleave, Bool_t verbose, Bool_t splitCutRange, RooDataHist::ErrorType etype) : RooAbsOptTestStatistic(name,title,pdf,hdata,RooArgSet(),cutRange,addCoefRange,nCPU,interleave,verbose,splitCutRange), _etype(etype), _funcMode(extended?ExtendedPdf:Pdf) { @@ -147,7 +164,7 @@ RooChi2Var::RooChi2Var(const char *name, const char *title, RooAbsPdf& pdf, RooD //_____________________________________________________________________________ RooChi2Var::RooChi2Var(const char *name, const char *title, RooAbsReal& func, RooDataHist& hdata, const RooArgSet& projDeps, RooChi2Var::FuncMode fmode, const char* cutRange, const char* addCoefRange, - Int_t nCPU, Bool_t interleave, Bool_t verbose, Bool_t splitCutRange, RooDataHist::ErrorType etype) : + Int_t nCPU, RooFit::MPSplit interleave, Bool_t verbose, Bool_t splitCutRange, RooDataHist::ErrorType etype) : RooAbsOptTestStatistic(name,title,func,hdata,projDeps,cutRange,addCoefRange,nCPU,interleave,verbose,splitCutRange), _etype(etype), _funcMode(fmode) { @@ -194,14 +211,18 @@ Double_t RooChi2Var::evaluatePartition(Int_t firstEvent, Int_t lastEvent, Int_t { // Calculate chi^2 in partition from firstEvent to lastEvent using given stepSize + // Throughout the calculation, we use Kahan's algorithm for summing to + // prevent loss of precision - this is a factor four more expensive than + // straight addition, but since evaluating the PDF is usually much more + // expensive than that, we tolerate the additional cost... Int_t i ; - Double_t result(0) ; + Double_t result(0), carry(0); - _dataClone->store()->recalculateCache( _projDeps, firstEvent, lastEvent, stepSize ) ; + _dataClone->store()->recalculateCache( _projDeps, firstEvent, lastEvent, stepSize, kFALSE) ; // Determine normalization factor depending on type of input function - Double_t normFactor(Function) ; + Double_t normFactor(1) ; switch (_funcMode) { case Function: normFactor=1 ; break ; case Pdf: normFactor = _dataClone->sumEntries() ; break ; @@ -210,42 +231,49 @@ Double_t RooChi2Var::evaluatePartition(Int_t firstEvent, Int_t lastEvent, Int_t // Loop over bins of dataset RooDataHist* hdata = (RooDataHist*) _dataClone ; - for (i=firstEvent ; i<lastEvent ; i+=stepSize) { + for (i=firstEvent ; i<lastEvent ; i+=stepSize) { // get the data values for this event hdata->get(i); - if (!hdata->valid()) { - continue ; - } + if (!hdata->valid()) continue; + + const Double_t nData = hdata->weight() ; - Double_t nData = hdata->weight() ; + const Double_t nPdf = _funcClone->getVal(_normSet) * normFactor * hdata->binVolume() ; - Double_t nPdf = _funcClone->getVal(_normSet) * normFactor * hdata->binVolume() ; + const Double_t eExt = nPdf-nData ; - Double_t eExt = nPdf-nData ; - // Double_t eIntLo,eIntHi ; -// hdata->weightError(eIntLo,eIntHi,_etype) ; -// Double_t eInt = (eExt>0) ? eIntHi : eIntLo ; - Double_t eInt = sqrt(nPdf) ; + Double_t eInt ; + if (_etype != RooAbsData::Expected) { + Double_t eIntLo,eIntHi ; + hdata->weightError(eIntLo,eIntHi,_etype) ; + eInt = (eExt>0) ? eIntHi : eIntLo ; + } else { + eInt = sqrt(nPdf) ; + } // Skip cases where pdf=0 and there is no data - if (eInt==0. && nData==0. && nPdf==0) continue ; - + if (0. == eInt * eInt && 0. == nData * nData && 0. == nPdf * nPdf) continue ; + // Return 0 if eInt=0, special handling in MINUIT will follow - if (eInt==0.) { + if (0. == eInt * eInt) { coutE(Eval) << "RooChi2Var::RooChi2Var(" << GetName() << ") INFINITY ERROR: bin " << i << " has zero error" << endl ; - return 0 ; + return 0.; } - - //cout << "Chi2Var[" << i << "] nData = " << nData << " nPdf = " << nPdf << " errorExt = " << eExt << " errorInt = " << eInt << " contrib = " << eExt*eExt/(eInt*eInt) << endl ; - - result += eExt*eExt/(eInt*eInt) ; + +// cout << "Chi2Var[" << i << "] nData = " << nData << " nPdf = " << nPdf << " errorExt = " << eExt << " errorInt = " << eInt << " contrib = " << eExt*eExt/(eInt*eInt) << endl ; + + Double_t term = eExt*eExt/(eInt*eInt) ; + Double_t y = term - carry; + Double_t t = result + y; + carry = (t - result) - y; + result = t; } - - + + _evalCarry = carry; return result ; } diff --git a/roofit/roofitcore/src/RooCintUtils.cxx b/roofit/roofitcore/src/RooCintUtils.cxx index 49e22165056ff..4e7bae24aa466 100644 --- a/roofit/roofitcore/src/RooCintUtils.cxx +++ b/roofit/roofitcore/src/RooCintUtils.cxx @@ -23,13 +23,9 @@ #include "RooCintUtils.h" -// #if ROOT_VERSION_CODE >= ROOT_VERSION(5,20,00) -// #include "cint/Api.h" -// #else -#include "Api.h" -// #endif - #include "RooMsgService.h" +#include "TInterpreter.h" + #include <string.h> #include <string> #include <iostream> @@ -40,11 +36,6 @@ using namespace std ; namespace RooCintUtils { - const char* functionName(void* func) - { - return G__p2f2funcname(func); - } - pair<list<string>,unsigned int> ctorArgs(const char* classname, UInt_t nMinArg) { // Utility function for RooFactoryWSTool. Return arguments of 'first' non-default, non-copy constructor of any RooAbsArg @@ -54,58 +45,53 @@ namespace RooCintUtils Int_t nreq(0) ; list<string> ret ; - G__ClassInfo cls(classname); - G__MethodInfo func(cls); - while(func.Next()) { + ClassInfo_t* cls = gInterpreter->ClassInfo_Factory(classname); + MethodInfo_t* func = gInterpreter->MethodInfo_Factory(cls); + while(gInterpreter->MethodInfo_Next(func)) { ret.clear() ; nreq=0 ; // Find 'the' constructor // Skip non-public methods - if (!(func.Property()&G__BIT_ISPUBLIC)) { + if (!(gInterpreter->MethodInfo_Property(func) & kIsPublic)) { continue ; } // Return type must be class name - if (string(classname)!= func.Type()->Name()) { + if (string(classname) != gInterpreter->MethodInfo_TypeName(func)) { continue ; } // Skip default constructor - if (func.NArg()==0 || func.NArg()==func.NDefaultArg()) { - continue ; - } - - // Skip copy constructor - G__MethodArgInfo arg1(func); - arg1.Next() ; - string tmp(Form("const %s&",classname)) ; - if (tmp==arg1.Type()->Name()) { + int nargs = gInterpreter->MethodInfo_NArg(func); + if (nargs==0 || nargs==gInterpreter->MethodInfo_NDefaultArg(func)) { continue ; } - // Examine definition of remaining ctor - G__MethodArgInfo arg(func); - - - // Require that first to arguments are of type const char* - while(arg.Next()) { - if (nreq<2 && string("const char*") != arg.Type()->Name()) { + MethodArgInfo_t* arg = gInterpreter->MethodArgInfo_Factory(func); + while (gInterpreter->MethodArgInfo_Next(arg)) { + // Require that first two arguments are of type const char* + const char* argTypeName = gInterpreter->MethodArgInfo_TypeName(arg); + if (nreq<2 && ((string("char*") != argTypeName + && !(gInterpreter->MethodArgInfo_Property(arg) & kIsConstPointer)) + && string("const char*") != argTypeName)) { continue ; } - ret.push_back(arg.Type()->Name()) ; - if(!arg.DefaultValue()) nreq++ ; + ret.push_back(argTypeName) ; + if(!gInterpreter->MethodArgInfo_DefaultValue(arg)) nreq++ ; } + gInterpreter->MethodArgInfo_Delete(arg); // Check that the number of required arguments is at least nMinArg if (ret.size()<nMinArg) { continue ; } - return pair<list<string>,unsigned int>(ret,nreq) ; - + break; } + gInterpreter->MethodInfo_Delete(func); + gInterpreter->ClassInfo_Delete(cls); return pair<list<string>,unsigned int>(ret,nreq) ; } @@ -113,9 +99,10 @@ namespace RooCintUtils Bool_t isEnum(const char* classname) { // Returns true if given type is an enum - G__ClassInfo cls(classname); - long property = cls.Property(); - return (property&G__BIT_ISENUM) ; + ClassInfo_t* cls = gInterpreter->ClassInfo_Factory(classname); + long property = gInterpreter->ClassInfo_Property(cls); + gInterpreter->ClassInfo_Delete(cls); + return (property&kIsEnum) ; } @@ -133,80 +120,36 @@ namespace RooCintUtils value = strrchr(value,':')+1 ; } - G__ClassInfo cls(className); - G__DataMemberInfo dm(cls); - while (dm.Next()) { + ClassInfo_t* cls = gInterpreter->ClassInfo_Factory(className); + DataMemberInfo_t* dm = gInterpreter->DataMemberInfo_Factory(cls); + while (gInterpreter->DataMemberInfo_Next(dm)) { // Check if this data member represents an enum value - if (string(Form("const %s",typeName))==dm.Type()->Name()) { - if (string(value)==dm.Name()) { + if (string(Form("const %s",typeName))==gInterpreter->DataMemberInfo_TypeName(dm)) { + if (string(value)==gInterpreter->DataMemberInfo_Name(dm)) { + gInterpreter->DataMemberInfo_Delete(dm); + gInterpreter->ClassInfo_Delete(cls); return kTRUE ; } } } + gInterpreter->DataMemberInfo_Delete(dm); + gInterpreter->ClassInfo_Delete(cls); return kFALSE ; } - - Bool_t matchFuncPtrArgs(void* func, const char* args) - { - // Returns TRUE if given pointer to function takes true arguments as listed in string args - - // Retrieve CINT name of function - const char* fname=G__p2f2funcname(func); - if (!fname) { - oocoutE((TObject*)0,InputArguments) << "bindFunction::ERROR CINT cannot resolve name of function " << func << endl ; - return kFALSE ; - } - - // Seperate namespace part from method name - char buf[1024] ; - strlcpy(buf,fname,256) ; - const char* methodName(0), *scopeName = buf ; - for(int i=strlen(buf)-1 ; i>0 ; i--) { - if (buf[i]==':' && buf[i-1]==':') { - buf[i-1] = 0 ; - methodName = buf+i+1 ; - break ; - } - } - - // Get info on scope - G__ClassInfo scope(scopeName); - - // Loop over all methods in scope - G__MethodInfo method(scope); - while(method.Next()) { - // If method name matches, check argument list - if (string(methodName?methodName:"")==method.Name()) { - - // Construct list of arguments - string s ; - G__MethodArgInfo arg(method); - while(arg.Next()) { - if (s.length()>0) s += "," ; - s += arg.Type()->TrueName() ; - } - - if (s==args) { - return kTRUE ; - } - } - } - - // Fill s with comma separate list of methods true argument names - return kFALSE ; - } - - } - Bool_t RooCintUtils::isTypeDef(const char* trueName, const char* aliasName) { // Returns true if aliasName is a typedef for trueName - G__TypedefInfo t; - while(t.Next()) { - if (string(trueName)==t.TrueName() && string(aliasName)==t.Name()) return kTRUE ; + TypedefInfo_t* t = gInterpreter->TypedefInfo_Factory(); + while(gInterpreter->TypedefInfo_Next(t)) { + if (string(trueName)==gInterpreter->TypedefInfo_TrueName(t) + && string(aliasName)==gInterpreter->TypedefInfo_Name(t)) { + gInterpreter->TypedefInfo_Delete(t); + return kTRUE ; + } } + gInterpreter->TypedefInfo_Delete(t); return kFALSE ; } @@ -214,12 +157,15 @@ Bool_t RooCintUtils::isTypeDef(const char* trueName, const char* aliasName) std::string RooCintUtils::trueName(const char* aliasName) { // Returns the true type for a given typedef name. - G__TypedefInfo t; - while(t.Next()) { - if (string(aliasName)==t.Name()) { - return trueName(string(t.TrueName()).c_str()) ; + TypedefInfo_t* t = gInterpreter->TypedefInfo_Factory(); + while(gInterpreter->TypedefInfo_Next(t)) { + if (string(aliasName)==gInterpreter->TypedefInfo_Name(t)) { + std::string ret = trueName(string(gInterpreter->TypedefInfo_TrueName(t)).c_str()) ; + gInterpreter->TypedefInfo_Delete(t); + return ret; } } + gInterpreter->TypedefInfo_Delete(t); return string(aliasName) ; } diff --git a/roofit/roofitcore/src/RooCmdArg.cxx b/roofit/roofitcore/src/RooCmdArg.cxx index fd7b2354e990c..a7a53590bece0 100644 --- a/roofit/roofitcore/src/RooCmdArg.cxx +++ b/roofit/roofitcore/src/RooCmdArg.cxx @@ -35,6 +35,8 @@ #include "RooArgSet.h" #include <string> +using namespace std; + ClassImp(RooCmdArg) ; diff --git a/roofit/roofitcore/src/RooCmdConfig.cxx b/roofit/roofitcore/src/RooCmdConfig.cxx index 96d25a87eeff0..29fbefc634c61 100644 --- a/roofit/roofitcore/src/RooCmdConfig.cxx +++ b/roofit/roofitcore/src/RooCmdConfig.cxx @@ -42,6 +42,8 @@ #include "Riostream.h" +using namespace std; + ClassImp(RooCmdConfig) ; @@ -240,7 +242,7 @@ const char* RooCmdConfig::missingArgs() const void RooCmdConfig::defineDependency(const char* refArgName, const char* neededArgName) { // Define that processing argument name refArgName requires processing - // of argument named neededArgName to succesfully complete parsing + // of argument named neededArgName to successfully complete parsing TNamed* dep = new TNamed(refArgName,neededArgName) ; _yList.Add(dep) ; @@ -634,7 +636,9 @@ Bool_t RooCmdConfig::process(const RooCmdArg& arg) } } - if (!anyField && !_allowUndefined) { + Bool_t multiArg = !TString("MultiArg").CompareTo(opc) ; + + if (!anyField && !_allowUndefined && !multiArg) { coutE(InputArguments) << _name << " ERROR: unrecognized command: " << opc << endl ; } @@ -753,7 +757,7 @@ const RooLinkedList& RooCmdConfig::getObjectList(const char* name) //_____________________________________________________________________________ Bool_t RooCmdConfig::ok(Bool_t verbose) const { - // Return true of parsing was succesfull + // Return true of parsing was successful if (_rList.GetSize()==0 && !_error) return kTRUE ; diff --git a/roofit/roofitcore/src/RooComplex.cxx b/roofit/roofitcore/src/RooComplex.cxx index 09463cdcddcc0..f6f02c910e3e4 100644 --- a/roofit/roofitcore/src/RooComplex.cxx +++ b/roofit/roofitcore/src/RooComplex.cxx @@ -23,13 +23,23 @@ #include "RooFit.h" -#include "RooComplex.h" +#define ROO_COMPLEX_CXX #include "RooComplex.h" #include "Riostream.h" #include <iomanip> +using namespace std; + ClassImp(RooComplex) +void RooComplex::warn() const +{ + static int nwarns = 0; + if (nwarns < 1<<12) { + cout << "[#0] WARN: RooComplex is deprecated. Please use std::complex<Double_t> in your code instead." << std::endl; + ++nwarns; + } +} //_____________________________________________________________________________ void RooComplex::Print() const { diff --git a/roofit/roofitcore/src/RooCompositeDataStore.cxx b/roofit/roofitcore/src/RooCompositeDataStore.cxx index 5f69f76cab632..1a8efb7709e5f 100644 --- a/roofit/roofitcore/src/RooCompositeDataStore.cxx +++ b/roofit/roofitcore/src/RooCompositeDataStore.cxx @@ -118,12 +118,12 @@ Bool_t RooCompositeDataStore::valid() const //_____________________________________________________________________________ -void RooCompositeDataStore::recalculateCache(const RooArgSet* proj, Int_t firstEvent, Int_t lastEvent, Int_t stepSize) +void RooCompositeDataStore::recalculateCache(const RooArgSet* proj, Int_t firstEvent, Int_t lastEvent, Int_t stepSize, Bool_t skipZeroWeights) { // Forward recalculate request to all subsets map<int,RooAbsDataStore*>::const_iterator iter ; for (iter = _dataMap.begin() ; iter!=_dataMap.end() ; ++iter) { - iter->second->recalculateCache(proj,firstEvent,lastEvent,stepSize) ; + iter->second->recalculateCache(proj,firstEvent,lastEvent,stepSize,skipZeroWeights) ; } } @@ -170,6 +170,7 @@ const RooArgSet* RooCompositeDataStore::get(Int_t idx) const continue ; } const_cast<RooCompositeDataStore*>(this)->_vars = (*iter->second->get(idx-offset)) ; + _indexCat->setIndex(iter->first) ; _curStore = iter->second ; _curIndex = idx-offset ; @@ -284,6 +285,9 @@ RooAbsArg* RooCompositeDataStore::addColumn(RooAbsArg& newVar, Bool_t adjustRang for (iter = _dataMap.begin() ; iter!=_dataMap.end() ; ++iter) { ret = iter->second->addColumn(newVar,adjustRange) ; } + if (ret) { + _vars.add(*ret) ; + } return ret ; } @@ -299,6 +303,9 @@ RooArgSet* RooCompositeDataStore::addColumns(const RooArgList& varList) for (iter = _dataMap.begin() ; iter!=_dataMap.end() ; ++iter) { ret = iter->second->addColumns(varList) ; } + if (ret) { + _vars.add(*ret) ; + } return ret ; } @@ -353,11 +360,11 @@ void RooCompositeDataStore::reset() //_____________________________________________________________________________ -void RooCompositeDataStore::cacheArgs(const RooAbsArg* owner, RooArgSet& newVarSet, const RooArgSet* nset) +void RooCompositeDataStore::cacheArgs(const RooAbsArg* owner, RooArgSet& newVarSet, const RooArgSet* nset, Bool_t skipZeroWeights) { map<int,RooAbsDataStore*>::const_iterator iter ; for (iter = _dataMap.begin() ; iter!=_dataMap.end() ; ++iter) { - iter->second->cacheArgs(owner,newVarSet,nset) ; + iter->second->cacheArgs(owner,newVarSet,nset,skipZeroWeights) ; } } diff --git a/roofit/roofitcore/src/RooConstVar.cxx b/roofit/roofitcore/src/RooConstVar.cxx index 05d0ba7549e9a..b7efd1c9f342c 100644 --- a/roofit/roofitcore/src/RooConstVar.cxx +++ b/roofit/roofitcore/src/RooConstVar.cxx @@ -27,6 +27,8 @@ #include "Riostream.h" #include "RooConstVar.h" +using namespace std; + ClassImp(RooConstVar) ; diff --git a/roofit/roofitcore/src/RooConstraintSum.cxx b/roofit/roofitcore/src/RooConstraintSum.cxx index 5d49edb96eec5..923831063238f 100644 --- a/roofit/roofitcore/src/RooConstraintSum.cxx +++ b/roofit/roofitcore/src/RooConstraintSum.cxx @@ -41,6 +41,8 @@ #include "RooChi2Var.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooConstraintSum) ; @@ -54,6 +56,7 @@ RooConstraintSum::RooConstraintSum() + //_____________________________________________________________________________ RooConstraintSum::RooConstraintSum(const char* name, const char* title, const RooArgSet& constraintSet, const RooArgSet& normSet) : RooAbsReal(name, title), @@ -112,7 +115,6 @@ RooConstraintSum::~RooConstraintSum() Double_t RooConstraintSum::evaluate() const { // Return sum of -log of constraint p.d.f.s - Double_t sum(0); RooAbsReal* comp ; RooFIter setIter1 = _set1.fwdIterator() ; diff --git a/roofit/roofitcore/src/RooConvCoefVar.cxx b/roofit/roofitcore/src/RooConvCoefVar.cxx index 7b65269c8e9dc..4a658c7613334 100644 --- a/roofit/roofitcore/src/RooConvCoefVar.cxx +++ b/roofit/roofitcore/src/RooConvCoefVar.cxx @@ -31,6 +31,8 @@ #include "RooAbsAnaConvPdf.h" #include "RooConvCoefVar.h" +using namespace std; + ClassImp(RooConvCoefVar) ; diff --git a/roofit/roofitcore/src/RooConvGenContext.cxx b/roofit/roofitcore/src/RooConvGenContext.cxx index ae1784b945370..b75d8066c359f 100644 --- a/roofit/roofitcore/src/RooConvGenContext.cxx +++ b/roofit/roofitcore/src/RooConvGenContext.cxx @@ -39,6 +39,8 @@ #include "Riostream.h" +using namespace std; + ClassImp(RooConvGenContext) ; @@ -142,7 +144,8 @@ RooConvGenContext::RooConvGenContext(const RooNumConvPdf &model, const RooArgSet _modelVars = new RooArgSet(*_modelVarsOwned) ; _convVarName = model.conv().cloneVar().GetName() ; _modelGen = ((RooAbsPdf&)model.conv().cloneModel()).genContext(*_modelVars,prototype,auxProto,verbose) ; - _modelCloneSet = 0 ; + _modelCloneSet = new RooArgSet ; + _modelCloneSet->add(model.conv().cloneModel()) ; if (prototype) { _pdfVars->add(*prototype->get()) ; diff --git a/roofit/roofitcore/src/RooConvIntegrandBinding.cxx b/roofit/roofitcore/src/RooConvIntegrandBinding.cxx index aa2619217cfc1..8e6bd98124acc 100644 --- a/roofit/roofitcore/src/RooConvIntegrandBinding.cxx +++ b/roofit/roofitcore/src/RooConvIntegrandBinding.cxx @@ -34,6 +34,8 @@ #include <assert.h> +using namespace std; + ClassImp(RooConvIntegrandBinding) ; diff --git a/roofit/roofitcore/src/RooCurve.cxx b/roofit/roofitcore/src/RooCurve.cxx index fcb69d10801ae..640919de3fce7 100644 --- a/roofit/roofitcore/src/RooCurve.cxx +++ b/roofit/roofitcore/src/RooCurve.cxx @@ -375,7 +375,12 @@ void RooCurve::addPoints(const RooAbsFunc &func, Double_t xlo, Double_t xhi, break ; } x2= *iter2 ; - addRange(func,x1,x2,yval[step-1],yval[step],prec*yrangeEst,minDx,numee,doEEVal,eeVal); + if (prec<0) { + // If precision is <0, no attempt at recursive interpolation is made + addPoint(x2,yval[step]) ; + } else { + addRange(func,x1,x2,yval[step-1],yval[step],prec*yrangeEst,minDx,numee,doEEVal,eeVal); + } step++ ; } addPoint(xhi,yval[minPoints-1]) ; @@ -555,7 +560,6 @@ Double_t RooCurve::chiSquare(const RooHist& hist, Int_t nFitParam) const // Check if point is in range of curve if (x<xstart || x>xstop) continue ; - nbin++ ; eyl = hist.GetEYlow()[i] ; eyh = hist.GetEYhigh()[i] ; exl = hist.GetEXlow()[i] ; @@ -568,6 +572,7 @@ Double_t RooCurve::chiSquare(const RooHist& hist, Int_t nFitParam) const if (y!=0) { Double_t pull = (y>avg) ? ((y-avg)/eyl) : ((y-avg)/eyh) ; chisq += pull*pull ; + nbin++ ; } } @@ -871,7 +876,7 @@ Bool_t RooCurve::isIdentical(const RooCurve& other, Double_t tol) const ret=kFALSE ; } } - + return ret ; } diff --git a/roofit/roofitcore/src/RooCustomizer.cxx b/roofit/roofitcore/src/RooCustomizer.cxx index 72643e657f4a6..3d5fe86ed0e40 100644 --- a/roofit/roofitcore/src/RooCustomizer.cxx +++ b/roofit/roofitcore/src/RooCustomizer.cxx @@ -149,6 +149,8 @@ static char *strtok_r(char *s1, const char *s2, char **lasts) #endif +using namespace std; + ClassImp(RooCustomizer) ; @@ -330,7 +332,7 @@ RooAbsArg* RooCustomizer::build(Bool_t verbose) // that were created in the cloning proces // Execute build - RooAbsArg* ret = doBuild(_name,verbose) ; + RooAbsArg* ret = doBuild(_name.Length()>0?_name.Data():0,verbose) ; // Make root object own all cloned nodes @@ -408,7 +410,7 @@ RooAbsArg* RooCustomizer::doBuild(const char* masterCatState, Bool_t verbose) nodeList.add(_masterBranchList) ; TIterator* nIter = nodeList.createIterator() ; -// cout << "loop over " << nodeList.getSize() << " nodes" << endl ; + // cout << "loop over " << nodeList.getSize() << " nodes" << endl ; while((node=(RooAbsArg*)nIter->Next())) { RooAbsArg* theSplitArg = !_sterile?(RooAbsArg*) _splitArgList.FindObject(node->GetName()):0 ; if (theSplitArg) { @@ -419,8 +421,10 @@ RooAbsArg* RooCustomizer::doBuild(const char* masterCatState, Bool_t verbose) } TString newName(node->GetName()) ; - newName.Append("_") ; - newName.Append(splitCat->getLabel()) ; + if (masterCatState) { + newName.Append("_") ; + newName.Append(splitCat->getLabel()) ; + } // Check if this node instance already exists RooAbsArg* specNode = _cloneNodeListAll ? _cloneNodeListAll->find(newName) : _cloneNodeListOwned->find(newName) ; @@ -437,7 +441,12 @@ RooAbsArg* RooCustomizer::doBuild(const char* masterCatState, Bool_t verbose) TString nameAttrib("ORIGNAME:") ; nameAttrib.Append(node->GetName()) ; specNode->setAttribute(nameAttrib) ; - specNode->setStringAttribute("ORIGNAME",node->GetName()) ; + + if (!specNode->getStringAttribute("origName")) { + specNode->setStringAttribute("origName",node->GetName()) ; + } + + } else { @@ -453,13 +462,17 @@ RooAbsArg* RooCustomizer::doBuild(const char* masterCatState, Bool_t verbose) // Create a new clone RooAbsArg* clone = (RooAbsArg*) node->Clone(newName.Data()) ; + clone->setStringAttribute("factory_tag",0) ; clone->SetTitle(newTitle) ; // Affix attribute with old name to clone to support name changing server redirect TString nameAttrib("ORIGNAME:") ; nameAttrib.Append(node->GetName()) ; clone->setAttribute(nameAttrib) ; - //specNode->setStringAttribute("ORIGNAME",node->GetName()) ; + + if (!clone->getStringAttribute("origName")) { + clone->setStringAttribute("origName",node->GetName()) ; + } // Add to one-time use list and life-time use list clonedMasterNodes.add(*clone) ; @@ -538,15 +551,21 @@ RooAbsArg* RooCustomizer::doBuild(const char* masterCatState, Bool_t verbose) TIterator* iter = masterBranchesToBeCloned.createIterator() ; while((branch=(RooAbsArg*)iter->Next())) { TString newName(branch->GetName()) ; - newName.Append("_") ; - newName.Append(masterCatState) ; + if (masterCatState) { + newName.Append("_") ; + newName.Append(masterCatState) ; + } // Affix attribute with old name to clone to support name changing server redirect RooAbsArg* clone = (RooAbsArg*) branch->Clone(newName.Data()) ; + clone->setStringAttribute("factory_tag",0) ; TString nameAttrib("ORIGNAME:") ; nameAttrib.Append(branch->GetName()) ; clone->setAttribute(nameAttrib) ; - clone->setStringAttribute("ORIGNAME",branch->GetName()) ; + + if (!clone->getStringAttribute("origName")) { + clone->setStringAttribute("origName",branch->GetName()) ; + } clonedMasterBranches.add(*clone) ; @@ -654,6 +673,7 @@ void RooCustomizer::setCloneBranchSet(RooArgSet& cloneBranchSet) //_____________________________________________________________________________ std::string RooCustomizer::CustIFace::create(RooFactoryWSTool& ft, const char* typeName, const char* instanceName, std::vector<std::string> args) { + // Check number of arguments if (args.size()<2) { throw string(Form("RooCustomizer::CustIFace::create() ERROR: expect at least 2 arguments for EDIT: the input object and at least one $Replace() rule")) ; @@ -663,13 +683,17 @@ std::string RooCustomizer::CustIFace::create(RooFactoryWSTool& ft, const char* t throw string(Form("RooCustomizer::CustIFace::create() ERROR: unknown type requested: %s",typeName)) ; } - // Check that first arg exists as RooAbsArg RooAbsArg* arg = ft.ws().arg(args[0].c_str()) ; if (!arg) { throw string(Form("RooCustomizer::CustIFace::create() ERROR: input RooAbsArg %s does not exist",args[0].c_str())) ; } + // If name of new object is same as original, execute in sterile mode (i.e no suffixes attached), and rename original nodes in workspace upon import + if (args[0]==instanceName) { + instanceName=0 ; + } + // Create a customizer RooCustomizer cust(*arg,instanceName) ; @@ -696,7 +720,7 @@ std::string RooCustomizer::CustIFace::create(RooFactoryWSTool& ft, const char* t char* saveptr ; char* tok = strtok_r(buf2,",)",&saveptr) ; while(tok) { - cout << "$REMOVE is restricted to " << tok << endl ; + //cout << "$REMOVE is restricted to " << tok << endl ; subst->setAttribute(Form("REMOVE_FROM_%s",tok)) ; tok = strtok_r(0,",)",&saveptr) ; } @@ -723,11 +747,14 @@ std::string RooCustomizer::CustIFace::create(RooFactoryWSTool& ft, const char* t throw string(Form("RooCustomizer::CustIFace::create() ERROR in customizer build, object %snot created",instanceName)) ; } - // Set the desired name of the top level node - targ->SetName(instanceName) ; - // Import the object into the workspace - ft.ws().import(*targ,RooFit::Silence()) ; - - return string(instanceName) ; + if (instanceName) { + // Set the desired name of the top level node + targ->SetName(instanceName) ; + ft.ws().import(cust.cloneBranchList(),RooFit::Silence(),RooFit::NoRecursion(kTRUE)) ; + } else { + ft.ws().import(cust.cloneBranchList(),RooFit::Silence(),RooFit::RenameConflictNodes("orig",1),RooFit::NoRecursion(kTRUE)) ; + } + + return string(instanceName?instanceName:targ->GetName()) ; } diff --git a/roofit/roofitcore/src/RooDLLSignificanceMCSModule.cxx b/roofit/roofitcore/src/RooDLLSignificanceMCSModule.cxx index aa722ae6a781d..3951b892b427e 100644 --- a/roofit/roofitcore/src/RooDLLSignificanceMCSModule.cxx +++ b/roofit/roofitcore/src/RooDLLSignificanceMCSModule.cxx @@ -42,6 +42,8 @@ +using namespace std; + ClassImp(RooDLLSignificanceMCSModule) ; diff --git a/roofit/roofitcore/src/RooDataHist.cxx b/roofit/roofitcore/src/RooDataHist.cxx index 40c2557e0351f..22c751338f972 100644 --- a/roofit/roofitcore/src/RooDataHist.cxx +++ b/roofit/roofitcore/src/RooDataHist.cxx @@ -167,7 +167,7 @@ RooDataHist::RooDataHist(const char *name, const char *title, const RooArgList& _dstore = (defaultStorageType==Tree) ? ((RooAbsDataStore*) new RooTreeDataStore(name,title,_vars)) : ((RooAbsDataStore*) new RooVectorDataStore(name,title,_vars)) ; - importTH1Set(vars, indexCat, histMap, wgt, kTRUE) ; + importTH1Set(vars, indexCat, histMap, wgt, kFALSE) ; _dstore->setExternalWeightArray(_wgt,_errLo,_errHi,_sumw2) ; } @@ -219,7 +219,7 @@ RooDataHist::RooDataHist(const char *name, const char *title, const RooArgList& assert(0) ; } - importTH1(vars,*const_cast<TH1*>(hist),wgt, kTRUE) ; + importTH1(vars,*const_cast<TH1*>(hist),wgt, kFALSE) ; _dstore->setExternalWeightArray(_wgt,_errLo,_errHi,_sumw2) ; } @@ -328,7 +328,7 @@ RooDataHist::RooDataHist(const char *name, const char *title, const RooArgList& hmap[token] = (TH1*) hiter->Next() ; token = strtok(0,",") ; } - importTH1Set(vars,*indexCat,hmap,initWgt,kTRUE) ; + importTH1Set(vars,*indexCat,hmap,initWgt,kFALSE) ; } else { // Initialize importing mapped set of RooDataHists @@ -394,7 +394,7 @@ void RooDataHist::importTH1(const RooArgList& vars, TH1& histo, Double_t wgt, Bo zmin = offset[2] ; volume *= (zvar->getMax()-zvar->getMin()) ; } - Double_t avgBV = volume / numEntries() ; + //Double_t avgBV = volume / numEntries() ; // cout << "average bin volume = " << avgBV << endl ; Int_t ix(0),iy(0),iz(0) ; @@ -406,18 +406,16 @@ void RooDataHist::importTH1(const RooArgList& vars, TH1& histo, Double_t wgt, Bo if (zvar) { for (iz=0 ; iz < zvar->getBins() ; iz++) { zvar->setBin(iz) ; - Double_t bv = doDensityCorrection ? binVolume(vset)/avgBV : 1; + Double_t bv = doDensityCorrection ? binVolume(vset) : 1; add(vset,bv*histo.GetBinContent(ix+1+xmin,iy+1+ymin,iz+1+zmin)*wgt,bv*TMath::Power(histo.GetBinError(ix+1+xmin,iy+1+ymin,iz+1+zmin)*wgt,2)) ; } } else { - Double_t bv = doDensityCorrection ? binVolume(vset)/avgBV : 1; + Double_t bv = doDensityCorrection ? binVolume(vset) : 1; add(vset,bv*histo.GetBinContent(ix+1+xmin,iy+1+ymin)*wgt,bv*TMath::Power(histo.GetBinError(ix+1+xmin,iy+1+ymin)*wgt,2)) ; } } } else { - Double_t bv = doDensityCorrection ? binVolume(vset)/avgBV : 1 ; -// cout << " RooDataHist(" << GetName() << ") ix = " << ix << " binVolume = " << bv << " binContent = " << histo.GetBinContent(ix+1+xmin) -// << " wgt = " << wgt << " value in RDH = " << bv*histo.GetBinContent(ix+1+xmin)*wgt << endl ; + Double_t bv = doDensityCorrection ? binVolume(vset) : 1 ; add(vset,bv*histo.GetBinContent(ix+1+xmin)*wgt,bv*TMath::Power(histo.GetBinError(ix+1+xmin)*wgt,2)) ; } } @@ -772,25 +770,25 @@ void RooDataHist::initialize(const char* binningName, Bool_t fillTree) RooAbsArg* real ; _iterator->Reset() ; while((real=(RooAbsArg*)_iterator->Next())) { - if (dynamic_cast<RooAbsReal*>(real)) _realVars.add(*real) ; + if (dynamic_cast<RooAbsReal*>(real)) _realVars.add(*real); } _realIter = _realVars.createIterator() ; // Fill array of LValue pointers to variables - _iterator->Reset() ; - RooAbsArg* rvarg ; + _iterator->Reset(); + RooAbsArg* rvarg; while((rvarg=(RooAbsArg*)_iterator->Next())) { if (binningName) { - RooRealVar* rrv = dynamic_cast<RooRealVar*>(rvarg) ; + RooRealVar* rrv = dynamic_cast<RooRealVar*>(rvarg); if (rrv) { - rrv->setBinning(rrv->getBinning(binningName)) ; + rrv->setBinning(rrv->getBinning(binningName)); } } // coverity[FORWARD_NULL] - _lvvars.push_back(dynamic_cast<RooAbsLValue*>(rvarg)) ; + _lvvars.push_back(dynamic_cast<RooAbsLValue*>(rvarg)); // coverity[FORWARD_NULL] - const RooAbsBinning* binning = dynamic_cast<RooAbsLValue*>(rvarg)->getBinningPtr(0) ; - _lvbins.push_back(binning ? binning->clone() : 0) ; + const RooAbsBinning* binning = dynamic_cast<RooAbsLValue*>(rvarg)->getBinningPtr(0); + _lvbins.push_back(binning ? binning->clone() : 0); } @@ -852,9 +850,10 @@ void RooDataHist::initialize(const char* binningName, Bool_t fillTree) RooAbsLValue* arglv = dynamic_cast<RooAbsLValue*>(arg2) ; arglv->setBin(idx) ; theBinVolume *= arglv->getBinWidth(idx) ; -// cout << "init: binv[" << idx << "] = " << theBinVolume << endl ; +// cout << "init: bin width at idx=" << idx << " = " << arglv->getBinWidth(idx) << " binv[" << idx << "] = " << theBinVolume << endl ; } _binv[ibin] = theBinVolume ; +// cout << "binv[" << ibin << "] = " << theBinVolume << endl ; fill() ; } @@ -862,6 +861,23 @@ void RooDataHist::initialize(const char* binningName, Bool_t fillTree) } +//_____________________________________________________________________________ +void RooDataHist::checkBinBounds() const +{ + if (!_binbounds.empty()) return; + for (std::vector<const RooAbsBinning*>::const_iterator it = _lvbins.begin(); + _lvbins.end() != it; ++it) { + _binbounds.push_back(std::vector<Double_t>()); + if (*it) { + std::vector<Double_t>& bounds = _binbounds.back(); + bounds.reserve(2 * (*it)->numBins()); + for (Int_t i = 0; i < (*it)->numBins(); ++i) { + bounds.push_back((*it)->binLow(i)); + bounds.push_back((*it)->binHigh(i)); + } + } + } +} //_____________________________________________________________________________ RooDataHist::RooDataHist(const RooDataHist& other, const char* newname) : @@ -1038,7 +1054,7 @@ RooDataHist::~RooDataHist() if (_binv) delete[] _binv ; if (_realIter) delete _realIter ; if (_binValid) delete[] _binValid ; - list<const RooAbsBinning*>::iterator iter = _lvbins.begin() ; + vector<const RooAbsBinning*>::iterator iter = _lvbins.begin() ; while(iter!=_lvbins.end()) { delete *iter ; iter++ ; @@ -1072,8 +1088,8 @@ Int_t RooDataHist::calcTreeIndex() const // to the bin enclosing the current coordinates of the internal argset Int_t masterIdx(0), i(0) ; - list<RooAbsLValue*>::const_iterator iter = _lvvars.begin() ; - list<const RooAbsBinning*>::const_iterator biter = _lvbins.begin() ; + vector<RooAbsLValue*>::const_iterator iter = _lvvars.begin() ; + vector<const RooAbsBinning*>::const_iterator biter = _lvbins.begin() ; for (;iter!=_lvvars.end() ; ++iter) { const RooAbsBinning* binning = (*biter) ; masterIdx += _idxMult[i++]*(*iter)->getBin(binning) ; @@ -1132,6 +1148,13 @@ RooPlot *RooDataHist::plotOn(RooPlot *frame, PlotOpt o) const +//_____________________________________________________________________________ +Double_t RooDataHist::weightSquared() const { + return _curSumW2 ; +} + + + //_____________________________________________________________________________ Double_t RooDataHist::weight(const RooArgSet& bin, Int_t intOrder, Bool_t correctForBinSize, Bool_t cdfBoundaries, Bool_t oneSafe) { @@ -1150,6 +1173,7 @@ Double_t RooDataHist::weight(const RooArgSet& bin, Int_t intOrder, Bool_t correc return 0 ; } + // Handle no-interpolation case if (intOrder==0) { _vars.assignValueOnly(bin,oneSafe) ; @@ -1253,7 +1277,11 @@ void RooDataHist::weightError(Double_t& lo, Double_t& hi, ErrorType etype) const switch (etype) { case Auto: - throw string(Form("RooDataHist::weightError(%s) weight type Auto not allowed here",GetName())) ; + throw string(Form("RooDataHist::weightError(%s) error type Auto not allowed here",GetName())) ; + break ; + + case Expected: + throw string(Form("RooDataHist::weightError(%s) error type Expected not allowed here",GetName())) ; break ; case Poisson: @@ -1502,12 +1530,15 @@ Double_t RooDataHist::sum(Bool_t correctForBinSize, Bool_t inverseBinCor) const checkInit() ; Int_t i ; - Double_t total(0) ; + Double_t total(0), carry(0); for (i=0 ; i<_arrSize ; i++) { Double_t theBinVolume = correctForBinSize ? (inverseBinCor ? 1/_binv[i] : _binv[i]) : 1.0 ; // cout << "total += " << _wgt[i] << "*" << theBinVolume << endl ; - total += _wgt[i]*theBinVolume ; + Double_t y = _wgt[i]*theBinVolume - carry; + Double_t t = total + y; + carry = (t - total) - y; + total = t; } return total ; @@ -1561,7 +1592,7 @@ Double_t RooDataHist::sum(const RooArgSet& sumSet, const RooArgSet& sliceSet, Bo } // Loop over entire data set, skipping masked entries - Double_t total(0) ; + Double_t total(0), carry(0); Int_t ibin ; for (ibin=0 ; ibin<_arrSize ; ibin++) { @@ -1581,7 +1612,10 @@ Double_t RooDataHist::sum(const RooArgSet& sumSet, const RooArgSet& sliceSet, Bo if (!skip) { Double_t theBinVolume = correctForBinSize ? (inverseBinCor ? 1/(*_pbinv)[i] : (*_pbinv)[i] ) : 1.0 ; // cout << "adding bin[" << ibin << "] to sum wgt = " << _wgt[ibin] << " binv = " << theBinVolume << endl ; - total += _wgt[ibin]*theBinVolume ; + Double_t y = _wgt[ibin]*theBinVolume - carry; + Double_t t = total + y; + carry = (t - total) - y; + total = t; } } delete ssIter ; @@ -1594,6 +1628,109 @@ Double_t RooDataHist::sum(const RooArgSet& sumSet, const RooArgSet& sliceSet, Bo return total ; } +//_____________________________________________________________________________ +Double_t RooDataHist::sum(const RooArgSet& sumSet, const RooArgSet& sliceSet, + Bool_t correctForBinSize, Bool_t inverseBinCor, + const std::map<const RooAbsArg*, std::pair<Double_t, Double_t> >& ranges) +{ + // Return the sum of the weights of a multi-dimensional slice of the histogram + // by summing only over the dimensions specified in sumSet. + // + // The coordinates of all other dimensions are fixed to those given in sliceSet + // + // If correctForBinSize is specified, the sum of weights + // is multiplied by the M-dimensional bin volume, (M = N(sumSet)), + // or the fraction of it that falls inside the range rangeName, + // making the return value the integral over the function + // represented by this histogram + // + // If correctForBinSize is not specified, the weights are multiplied by the + // fraction of the bin volume that falls inside the range, i.e. a factor or + // binVolumeInRange/totalBinVolume. + + checkInit(); + checkBinBounds(); + RooArgSet varSave; + varSave.addClone(_vars); + { + RooArgSet sliceOnlySet(sliceSet); + sliceOnlySet.remove(sumSet,kTRUE,kTRUE); + _vars = sliceOnlySet; + } + + // Calculate mask and refence plot bins for non-iterating variables, + // and get ranges for iterating variables + std::vector<bool> mask(_vars.getSize()); + std::vector<Int_t> refBin(_vars.getSize()); + std::vector<Double_t> rangeLo(_vars.getSize(), -std::numeric_limits<Double_t>::infinity()); + std::vector<Double_t> rangeHi(_vars.getSize(), +std::numeric_limits<Double_t>::infinity()); + + _iterator->Reset(); + RooAbsArg* arg; + for (Int_t i = 0; (arg=(RooAbsArg*)_iterator->Next()); ++i) { + RooAbsArg* sumsetv = sumSet.find(*arg); + RooAbsArg* slicesetv = sliceSet.find(*arg); + mask[i] = !sumsetv; + if (mask[i]) { + // coverity[FORWARD_NULL] + refBin[i] = (dynamic_cast<RooAbsLValue*>(arg))->getBin(); + } + std::map<const RooAbsArg*, std::pair<Double_t, Double_t> >::const_iterator + it = ranges.find(sumsetv ? sumsetv : slicesetv); + if (ranges.end() != it) { + rangeLo[i] = it->second.first; + rangeHi[i] = it->second.second; + } + } + + // Loop over entire data set, skipping masked entries + Double_t total(0), carry(0); + for (Int_t ibin = 0; ibin < _arrSize; ++ibin) { + // Check if this bin belongs in selected slice + _iterator->Reset(); + Bool_t skip(kFALSE); + // coverity[UNUSED_VALUE] + for (Int_t ivar = 0, tmp = ibin; + (!skip && (arg=(RooAbsArg*)_iterator->Next())); ++ivar) { + const Int_t idx = tmp / _idxMult[ivar]; + tmp -= idx*_idxMult[ivar]; + if (mask[ivar] && idx!=refBin[ivar]) skip=kTRUE; + } + if (skip) continue; + _iterator->Reset(); + // work out bin volume + Double_t theBinVolume = 1.; + for (Int_t ivar = 0, tmp = ibin; + (arg=(RooAbsArg*)_iterator->Next()); ++ivar) { + const Int_t idx = tmp / _idxMult[ivar]; + tmp -= idx*_idxMult[ivar]; + if (_binbounds[ivar].empty()) continue; + const Double_t binLo = _binbounds[ivar][2 * idx]; + const Double_t binHi = _binbounds[ivar][2 * idx + 1]; + if (binHi < rangeLo[ivar] || binLo > rangeHi[ivar]) { + // bin is outside of allowed range - effective bin volume is zero + theBinVolume = 0.; + break; + } + theBinVolume *= + (std::min(rangeHi[ivar], binHi) - std::max(rangeLo[ivar], binLo)); + } + const Double_t corrPartial = theBinVolume / _binv[ibin]; + if (0. == corrPartial) continue; + const Double_t corr = correctForBinSize ? (inverseBinCor ? 1. / _binv[ibin] : _binv[ibin] ) : 1.0; + //cout << "adding bin[" << ibin << "] to sum wgt = " << _wgt[ibin] << " binv = " << theBinVolume << " _binv[" << ibin << "] " << _binv[ibin] << endl; + + const Double_t y = _wgt[ibin] * corr * corrPartial - carry; + const Double_t t = total + y; + carry = (t - total) - y; + total = t; + } + + _vars = varSave; + + return total; +} + //_____________________________________________________________________________ @@ -1663,10 +1800,13 @@ Int_t RooDataHist::numEntries() const Double_t RooDataHist::sumEntries() const { Int_t i ; - Double_t n(0) ; + Double_t n(0), carry(0); for (i=0 ; i<_arrSize ; i++) { if (!_binValid || _binValid[i]) { - n+= _wgt[i] ; + Double_t y = _wgt[i] - carry; + Double_t t = n + y; + carry = (t - n) - y; + n = t; } } return n ; @@ -1683,14 +1823,7 @@ Double_t RooDataHist::sumEntries(const char* cutSpec, const char* cutRange) cons checkInit() ; if (cutSpec==0 && cutRange==0) { - Int_t i ; - Double_t n(0) ; - for (i=0 ; i<_arrSize ; i++) { - if (!_binValid || _binValid[i]) { - n+= _wgt[i] ; - } - } - return n ; + return sumEntries(); } else { // Setup RooFormulaVar for cutSpec if it is present @@ -1700,7 +1833,7 @@ Double_t RooDataHist::sumEntries(const char* cutSpec, const char* cutRange) cons } // Otherwise sum the weights in the event - Double_t sumw(0) ; + Double_t sumw(0), carry(0); Int_t i ; for (i=0 ; i<numEntries() ; i++) { get(i) ; @@ -1708,7 +1841,10 @@ Double_t RooDataHist::sumEntries(const char* cutSpec, const char* cutRange) cons if (cutRange && !_vars.allInRange(cutRange)) continue ; if (!_binValid || _binValid[i]) { - sumw += weight() ; + Double_t y = weight() - carry; + Double_t t = sumw + y; + carry = (t - sumw) - y; + sumw = t; } } diff --git a/roofit/roofitcore/src/RooDataHistSliceIter.cxx b/roofit/roofitcore/src/RooDataHistSliceIter.cxx index 78d11375bf21a..c83c2c88802c6 100644 --- a/roofit/roofitcore/src/RooDataHistSliceIter.cxx +++ b/roofit/roofitcore/src/RooDataHistSliceIter.cxx @@ -36,6 +36,8 @@ #include "RooAbsLValue.h" #include "RooDataHistSliceIter.h" +using namespace std; + ClassImp(RooDataHistSliceIter) ; diff --git a/roofit/roofitcore/src/RooDataProjBinding.cxx b/roofit/roofitcore/src/RooDataProjBinding.cxx index c68d4b8012761..86f5c56f10f87 100644 --- a/roofit/roofitcore/src/RooDataProjBinding.cxx +++ b/roofit/roofitcore/src/RooDataProjBinding.cxx @@ -44,6 +44,8 @@ +using namespace std; + ClassImp(RooDataProjBinding) ; diff --git a/roofit/roofitcore/src/RooDataSet.cxx b/roofit/roofitcore/src/RooDataSet.cxx index 8ab3effbc54d6..322f224d054e8 100644 --- a/roofit/roofitcore/src/RooDataSet.cxx +++ b/roofit/roofitcore/src/RooDataSet.cxx @@ -56,6 +56,8 @@ char* operator+( streampos&, char* ); #endif +using namespace std; + ClassImp(RooDataSet) ; @@ -245,9 +247,11 @@ RooDataSet::RooDataSet(const char* name, const char* title, const RooArgSet& var pc.defineObject("cutVar","CutVar",0) ; pc.defineString("cutRange","CutRange",0,"") ; pc.defineString("wgtVarName","WeightVarName",0,"") ; + pc.defineInt("newWeight1","WeightVarName",0,0) ; pc.defineString("fname","ImportFromFile",0,"") ; pc.defineString("tname","ImportFromFile",1,"") ; pc.defineObject("wgtVar","WeightVar",0) ; + pc.defineInt("newWeight2","WeightVar",0,0) ; pc.defineObject("dummy1","ImportDataSliceMany",0) ; pc.defineObject("dummy2","LinkDataSliceMany",0) ; pc.defineSet("errorSet","StoreError",0) ; @@ -291,7 +295,7 @@ RooDataSet::RooDataSet(const char* name, const char* title, const RooArgSet& var const char* fname = pc.getString("fname") ; const char* tname = pc.getString("tname") ; Int_t ownLinked = pc.getInt("ownLinked") ; - + Int_t newWeight = pc.getInt("newWeight1") + pc.getInt("newWeight2") ; // Case 1 --- Link multiple dataset as slices if (lnkSliceNames) { @@ -352,6 +356,13 @@ RooDataSet::RooDataSet(const char* name, const char* title, const RooArgSet& var if (wgtVar) { wgtVarName = wgtVar->GetName() ; } + + // Clone weight variable of imported dataset if we are not weighted + if (!wgtVar && !wgtVarName && impData && impData->_wgtVar) { + _wgtVar = (RooRealVar*) impData->_wgtVar->createFundamental() ; + _vars.addOwned(*_wgtVar) ; + wgtVarName = _wgtVar->GetName() ; + } // Create empty datastore RooTreeDataStore* tstore(0) ; @@ -361,6 +372,12 @@ RooDataSet::RooDataSet(const char* name, const char* title, const RooArgSet& var tstore = new RooTreeDataStore(name,title,_vars,wgtVarName) ; _dstore = tstore ; } else if (defaultStorageType==Vector) { + if (wgtVarName && newWeight) { + RooAbsArg* wgttmp = _vars.find(wgtVarName) ; + if (wgttmp) { + wgttmp->setAttribute("NewWeight") ; + } + } vstore = new RooVectorDataStore(name,title,_vars,wgtVarName) ; _dstore = vstore ; } else { @@ -371,8 +388,8 @@ RooDataSet::RooDataSet(const char* name, const char* title, const RooArgSet& var // Make import mapping if index category is specified map<string,RooDataSet*> hmap ; if (indexCat) { - char tmp[10000] ; - strlcpy(tmp,impSliceNames,10000) ; + char tmp[100000] ; + strlcpy(tmp,impSliceNames,100000) ; char* token = strtok(tmp,",") ; TIterator* hiter = impSliceData.MakeIterator() ; while(token) { @@ -418,8 +435,10 @@ RooDataSet::RooDataSet(const char* name, const char* title, const RooArgSet& var if (wgtVarName && *wgtVarName) { // Use the supplied weight column initialize(wgtVarName) ; + } else { if (impData && impData->_wgtVar && vars.find(impData->_wgtVar->GetName())) { + // Use the weight column of the source data set initialize(impData->_wgtVar->GetName()) ; @@ -976,6 +995,17 @@ Double_t RooDataSet::weight() const +//_____________________________________________________________________________ +Double_t RooDataSet::weightSquared() const +{ + // Return event weight of current event + + return store()->weight()*store()->weight() ; +} + + + + //_____________________________________________________________________________ void RooDataSet::weightError(Double_t& lo, Double_t& hi, ErrorType etype) const { @@ -1014,11 +1044,14 @@ Double_t RooDataSet::sumEntries() const } // Otherwise sum the weights in the event - Double_t sumw(0) ; + Double_t sumw(0), carry(0); Int_t i ; for (i=0 ; i<numEntries() ; i++) { get(i) ; - sumw += weight() ; + Double_t y = weight() - carry; + Double_t t = sumw + y; + carry = (t - sumw) - y; + sumw = t; } return sumw ; @@ -1043,13 +1076,16 @@ Double_t RooDataSet::sumEntries(const char* cutSpec, const char* cutRange) const } // Otherwise sum the weights in the event - Double_t sumw(0) ; + Double_t sumw(0), carry(0); Int_t i ; for (i=0 ; i<numEntries() ; i++) { get(i) ; if (select && select->eval()==0.) continue ; if (cutRange && !_vars.allInRange(cutRange)) continue ; - sumw += weight() ; + Double_t y = weight() - carry; + Double_t t = sumw + y; + carry = (t - sumw) - y; + sumw = t; } if (select) delete select ; diff --git a/roofit/roofitcore/src/RooDataWeightedAverage.cxx b/roofit/roofitcore/src/RooDataWeightedAverage.cxx index 4726f9d4a3af3..8683727adfd56 100644 --- a/roofit/roofitcore/src/RooDataWeightedAverage.cxx +++ b/roofit/roofitcore/src/RooDataWeightedAverage.cxx @@ -41,13 +41,15 @@ +using namespace std; + ClassImp(RooDataWeightedAverage) ; //_____________________________________________________________________________ RooDataWeightedAverage::RooDataWeightedAverage(const char *name, const char *title, RooAbsReal& pdf, RooAbsData& indata, - const RooArgSet& projdeps, Int_t nCPU, Bool_t interleave, Bool_t showProgress, Bool_t verbose) : + const RooArgSet& projdeps, Int_t nCPU, RooFit::MPSplit interleave, Bool_t showProgress, Bool_t verbose) : RooAbsOptTestStatistic(name,title,pdf,indata,projdeps,0,0,nCPU,interleave,verbose,kFALSE), _showProgress(showProgress) { @@ -103,7 +105,7 @@ Double_t RooDataWeightedAverage::evaluatePartition(Int_t firstEvent, Int_t lastE Int_t i ; Double_t result(0) ; - _dataClone->store()->recalculateCache( _projDeps, firstEvent, lastEvent, stepSize ) ; + _dataClone->store()->recalculateCache( _projDeps, firstEvent, lastEvent, stepSize,kFALSE) ; if (setNum()==0 && _showProgress) { ccoutP(Plotting) << "." ; diff --git a/roofit/roofitcore/src/RooDerivative.cxx b/roofit/roofitcore/src/RooDerivative.cxx index 7314315a0f9e6..f3f34067088f4 100644 --- a/roofit/roofitcore/src/RooDerivative.cxx +++ b/roofit/roofitcore/src/RooDerivative.cxx @@ -43,6 +43,8 @@ #include "Math/WrappedFunction.h" #include "Math/RichardsonDerivator.h" +using namespace std; + ClassImp(RooDerivative) ; diff --git a/roofit/roofitcore/src/RooDirItem.cxx b/roofit/roofitcore/src/RooDirItem.cxx index 6fee88f0cb41e..56a166b1a5bd3 100644 --- a/roofit/roofitcore/src/RooDirItem.cxx +++ b/roofit/roofitcore/src/RooDirItem.cxx @@ -33,6 +33,8 @@ #include "TString.h" #include "RooDirItem.h" +using namespace std; + ClassImp(RooDirItem) ; diff --git a/roofit/roofitcore/src/RooDouble.cxx b/roofit/roofitcore/src/RooDouble.cxx index eda8141fc333e..b78ca2a96f789 100644 --- a/roofit/roofitcore/src/RooDouble.cxx +++ b/roofit/roofitcore/src/RooDouble.cxx @@ -26,6 +26,8 @@ #include "RooDouble.h" #include <string> +using namespace std; + ClassImp(RooDouble) ; diff --git a/roofit/roofitcore/src/RooEffGenContext.cxx b/roofit/roofitcore/src/RooEffGenContext.cxx index 305eb02fd55bb..4994afff76a95 100644 --- a/roofit/roofitcore/src/RooEffGenContext.cxx +++ b/roofit/roofitcore/src/RooEffGenContext.cxx @@ -31,6 +31,8 @@ #include "RooAbsPdf.h" #include "RooRandom.h" +using namespace std; + ClassImp(RooEffGenContext); //_____________________________________________________________________________ @@ -88,7 +90,7 @@ void RooEffGenContext::generateEvent(RooArgSet &theEvent, Int_t remaining) double val = _eff->getVal(); if (val > _maxEff && !_eff->getMaxVal(*_vars)) { coutE(Generation) << ClassName() << "::" << GetName() - << ":generateEvent: value of efficiency is larger than assumed maximum of 1." << endl; + << ":generateEvent: value of efficiency is larger than assumed maximum of 1." << std::endl; continue; } if (val > RooRandom::uniform() * _maxEff) { diff --git a/roofit/roofitcore/src/RooEffProd.cxx b/roofit/roofitcore/src/RooEffProd.cxx index 3af4ad27bd97d..5ca3b8b6cad1f 100644 --- a/roofit/roofitcore/src/RooEffProd.cxx +++ b/roofit/roofitcore/src/RooEffProd.cxx @@ -28,6 +28,8 @@ #include "RooNameReg.h" #include "RooRealVar.h" +using namespace std; + ClassImp(RooEffProd) ; diff --git a/roofit/roofitcore/src/RooEfficiency.cxx b/roofit/roofitcore/src/RooEfficiency.cxx index cfeaa77c49e83..99fc203b2e740 100644 --- a/roofit/roofitcore/src/RooEfficiency.cxx +++ b/roofit/roofitcore/src/RooEfficiency.cxx @@ -35,6 +35,8 @@ #include "RooStreamParser.h" #include "RooArgList.h" +using namespace std; + ClassImp(RooEfficiency) ; diff --git a/roofit/roofitcore/src/RooEllipse.cxx b/roofit/roofitcore/src/RooEllipse.cxx index f06b2da2ad087..744817f973624 100644 --- a/roofit/roofitcore/src/RooEllipse.cxx +++ b/roofit/roofitcore/src/RooEllipse.cxx @@ -35,6 +35,8 @@ #include <math.h> #include <assert.h> +using namespace std; + ClassImp(RooEllipse) diff --git a/roofit/roofitcore/src/RooErrorVar.cxx b/roofit/roofitcore/src/RooErrorVar.cxx index 351d99b947a4b..13e9ececa0ab3 100644 --- a/roofit/roofitcore/src/RooErrorVar.cxx +++ b/roofit/roofitcore/src/RooErrorVar.cxx @@ -38,6 +38,8 @@ +using namespace std; + ClassImp(RooErrorVar) ; @@ -147,7 +149,21 @@ RooAbsBinning& RooErrorVar::getBinning(const char* name, Bool_t /*verbose*/, Boo return *binning ; } - +//_____________________________________________________________________________ +std::list<std::string> RooErrorVar::getBinningNames() const +{ + // Get a list of all binning names. An empty name implies the default binning. + // A 0 pointer should be passed to getBinning in this case. + std::list<std::string> binningNames(1, ""); + + RooFIter iter = _altBinning.fwdIterator(); + const RooAbsArg* binning = 0; + while((binning = iter.next())) { + const char* name = binning->GetName(); + binningNames.push_back(name); + } + return binningNames; +} //_____________________________________________________________________________ void RooErrorVar::setBinning(const RooAbsBinning& binning, const char* name) diff --git a/roofit/roofitcore/src/RooExtendPdf.cxx b/roofit/roofitcore/src/RooExtendPdf.cxx index 64b3ff59d4017..ec5422f92b15f 100644 --- a/roofit/roofitcore/src/RooExtendPdf.cxx +++ b/roofit/roofitcore/src/RooExtendPdf.cxx @@ -49,6 +49,8 @@ +using namespace std; + ClassImp(RooExtendPdf) ; diff --git a/roofit/roofitcore/src/RooExtendedBinding.cxx b/roofit/roofitcore/src/RooExtendedBinding.cxx new file mode 100644 index 0000000000000..910cd9e70694d --- /dev/null +++ b/roofit/roofitcore/src/RooExtendedBinding.cxx @@ -0,0 +1,41 @@ +/***************************************************************************** + * Project: RooFit * + * * + * This code was autogenerated by RooClassFactory * + *****************************************************************************/ + +// Your description goes here... + +#include "Riostream.h" + +#include "RooExtendedBinding.h" +#include "RooAbsPdf.h" +#include "RooAbsCategory.h" +#include <math.h> +#include "TMath.h" + +ClassImp(RooExtendedBinding) + + RooExtendedBinding::RooExtendedBinding(const char *name, const char *title, RooAbsPdf& _pdf) : + RooAbsReal(name,title), + pdf("pdf","pdf",this,_pdf) + { + } + + + RooExtendedBinding::RooExtendedBinding(const RooExtendedBinding& other, const char* name) : + RooAbsReal(other,name), + pdf("pdf",this,other.pdf) + { + } + + + + Double_t RooExtendedBinding::evaluate() const + { + // ENTER EXPRESSION IN TERMS OF VARIABLE ARGUMENTS HERE + return ((RooAbsPdf&)pdf.arg()).expectedEvents(0) ; + } + + + diff --git a/roofit/roofitcore/src/RooExtendedTerm.cxx b/roofit/roofitcore/src/RooExtendedTerm.cxx index 6d3dcea16cf87..8eb291d81dc85 100644 --- a/roofit/roofitcore/src/RooExtendedTerm.cxx +++ b/roofit/roofitcore/src/RooExtendedTerm.cxx @@ -26,6 +26,8 @@ #include "RooFit.h" #include "RooExtendedTerm.h" +using namespace std; + ClassImp(RooExtendedTerm) ; diff --git a/roofit/roofitcore/src/RooFFTConvPdf.cxx b/roofit/roofitcore/src/RooFFTConvPdf.cxx index ad5205f49ebc8..2710aa6aa2280 100644 --- a/roofit/roofitcore/src/RooFFTConvPdf.cxx +++ b/roofit/roofitcore/src/RooFFTConvPdf.cxx @@ -150,7 +150,7 @@ RooFFTConvPdf::RooFFTConvPdf(const char *name, const char *title, RooRealVar& co convVar.setBinning(convVar.getBinning(),"cache") ; } - _shift2 = (convVar.getMax()+convVar.getMin())/2 ; + _shift2 = (convVar.getMax("cache")+convVar.getMin("cache"))/2 ; calcParams() ; @@ -180,7 +180,7 @@ RooFFTConvPdf::RooFFTConvPdf(const char *name, const char *title, RooAbsReal& pd convVar.setBinning(convVar.getBinning(),"cache") ; } - _shift2 = (convVar.getMax()+convVar.getMin())/2 ; + _shift2 = (convVar.getMax("cache")+convVar.getMin("cache"))/2 ; calcParams() ; } @@ -244,20 +244,19 @@ RooFFTConvPdf::FFTCacheElem::FFTCacheElem(const RooFFTConvPdf& self, const RooAr PdfCacheElem(self,nsetIn), fftr2c1(0),fftr2c2(0),fftc2r(0) { - // Clone input pdf and attach to dataset RooAbsPdf* clonePdf1 = (RooAbsPdf*) self._pdf1.arg().cloneTree() ; RooAbsPdf* clonePdf2 = (RooAbsPdf*) self._pdf2.arg().cloneTree() ; clonePdf1->attachDataSet(*hist()) ; clonePdf2->attachDataSet(*hist()) ; - + // Shift observable RooRealVar* convObs = (RooRealVar*) hist()->get()->find(self._x.arg().GetName()) ; // Install FFT reference range string refName = Form("refrange_fft_%s",self.GetName()) ; convObs->setRange(refName.c_str(),convObs->getMin(),convObs->getMax()) ; - + if (self._shift1!=0) { RooLinearVar* shiftObs1 = new RooLinearVar(Form("%s_shifted_FFTBuffer1",convObs->GetName()),"shiftObs1", *convObs,RooFit::RooConst(1),RooFit::RooConst(-1*self._shift1)) ; @@ -390,7 +389,7 @@ void RooFFTConvPdf::fillCacheObject(RooAbsCachedPdf::PdfCacheElem& cache) const delete histArg ; } -// cout << "RooFFTConvPdf::fillCacheObject() otherObs = " << otherObs << endl ; + //cout << "RooFFTConvPdf::fillCacheObject() otherObs = " << otherObs << endl ; // Handle trivial scenario -- no other observables if (otherObs.getSize()==0) { diff --git a/roofit/roofitcore/src/RooFitResult.cxx b/roofit/roofitcore/src/RooFitResult.cxx index 015498387602b..41584381d424c 100644 --- a/roofit/roofitcore/src/RooFitResult.cxx +++ b/roofit/roofitcore/src/RooFitResult.cxx @@ -56,6 +56,8 @@ +using namespace std; + ClassImp(RooFitResult) ; @@ -186,7 +188,7 @@ void RooFitResult::setFinalParList(const RooArgList& list) //_____________________________________________________________________________ -Int_t RooFitResult::statusCodeHistory(UInt_t icycle) +Int_t RooFitResult::statusCodeHistory(UInt_t icycle) const { if (icycle>=_statusHistory.size()) { coutE(InputArguments) << "RooFitResult::statusCodeHistory(" << GetName() @@ -199,7 +201,7 @@ Int_t RooFitResult::statusCodeHistory(UInt_t icycle) //_____________________________________________________________________________ -const char* RooFitResult::statusLabelHistory(UInt_t icycle) +const char* RooFitResult::statusLabelHistory(UInt_t icycle) const { if (icycle>=_statusHistory.size()) { coutE(InputArguments) << "RooFitResult::statusLabelHistory(" << GetName() @@ -606,7 +608,7 @@ void RooFitResult::fillCorrMatrix(const std::vector<double>& globalCC, const TMa for(int i=0 ; i<_CM->GetNcols() ; i++) { (*_GC)[i] = globalCC[i] ; } - fillLegacyCorrMatrix() ; + //fillLegacyCorrMatrix() ; } @@ -806,7 +808,7 @@ Bool_t RooFitResult::isIdentical(const RooFitResult& other, Double_t tol, Double } } - // Only examine correlations for cases with >1 floating paramater + // Only examine correlations for cases with >1 floating parameter if (_finalPars->getSize()>1) { fillLegacyCorrMatrix() ; @@ -1246,7 +1248,7 @@ RooAbsPdf* RooFitResult::createHessePdf(const RooArgSet& params) const // Calculate offset vectors mu1 and mu2 RooArgList mu1 ; for (UInt_t i=0 ; i<map1.size() ; i++) { - RooRealVar* parclone = (RooRealVar*) _finalPars->at(map1[i])->Clone(Form("%s_centralvalue",_finalPars->at(i)->GetName())) ; + RooRealVar* parclone = (RooRealVar*) _finalPars->at(map1[i])->Clone(Form("%s_centralvalue",_finalPars->at(map1[i])->GetName())) ; parclone->setConstant(kTRUE) ; mu1.add(*parclone) ; } diff --git a/roofit/roofitcore/src/RooFoamGenerator.cxx b/roofit/roofitcore/src/RooFoamGenerator.cxx index e47538d4c8cb2..555113f75fa17 100644 --- a/roofit/roofitcore/src/RooFoamGenerator.cxx +++ b/roofit/roofitcore/src/RooFoamGenerator.cxx @@ -48,6 +48,8 @@ #include <assert.h> +using namespace std; + ClassImp(RooFoamGenerator) ; diff --git a/roofit/roofitcore/src/RooFormula.cxx b/roofit/roofitcore/src/RooFormula.cxx index 76086d8506ca3..dd97a21510a3b 100644 --- a/roofit/roofitcore/src/RooFormula.cxx +++ b/roofit/roofitcore/src/RooFormula.cxx @@ -40,6 +40,9 @@ #include "RooAbsCategory.h" #include "RooArgList.h" #include "RooMsgService.h" +#include "RooTrace.h" + +using namespace std; ClassImp(RooFormula) @@ -49,6 +52,7 @@ RooFormula::RooFormula() : TFormula(), _nset(0) { // Default constructor // coverity[UNINIT_CTOR] + TRACE_CREATE } @@ -74,6 +78,7 @@ RooFormula::RooFormula(const char* name, const char* formula, const RooArgList& _isOK = kFALSE ; return ; } + TRACE_CREATE } @@ -96,6 +101,7 @@ RooFormula::RooFormula(const RooFormula& other, const char* name) : Compile() ; _compiled=kTRUE ; + TRACE_CREATE } @@ -127,6 +133,7 @@ RooFormula::~RooFormula() // Destructor _labelList.Delete() ; + TRACE_DESTROY } @@ -184,7 +191,7 @@ Bool_t RooFormula::changeDependents(const RooAbsCollection& newDeps, Bool_t must // Change used variables to those with the same name in given list // If mustReplaceAll is true and error is generated if one of the // elements of newDeps is not found as a server - + //Change current servers to new servers with the same name given in list Bool_t errorStat(kFALSE) ; int i ; @@ -206,6 +213,11 @@ Bool_t RooFormula::changeDependents(const RooAbsCollection& newDeps, Bool_t must RooAbsReal* replace = (RooAbsReal*) arg->findNewServer(newDeps,nameChange) ; if (replace) { _origList.Replace(arg,replace) ; + if (arg->getStringAttribute("origName")) { + replace->setStringAttribute("origName",arg->getStringAttribute("origName")) ; + } else { + replace->setStringAttribute("origName",arg->GetName()) ; + } } else if (mustReplaceAll) { errorStat = kTRUE ; } @@ -331,6 +343,13 @@ Int_t RooFormula::DefinedVariable(TString &name) } else { // Access by name arg= (RooAbsArg*) _origList.FindObject(argName) ; + if (!arg) { + for (RooLinkedListIter it = _origList.iterator(); RooAbsArg* v = dynamic_cast<RooAbsArg*>(it.Next());) { + if (!TString(argName).CompareTo(v->getStringAttribute("origName"))) { + arg= v ; + } + } + } } // Check that arg exists @@ -358,7 +377,8 @@ Int_t RooFormula::DefinedVariable(TString &name) Int_t i ; for(i=0 ; i<_useList.GetSize() ; i++) { RooAbsArg* var = (RooAbsArg*) _useList.At(i) ; - Bool_t varMatch = !TString(var->GetName()).CompareTo(arg->GetName()) ; + //Bool_t varMatch = !TString(var->GetName()).CompareTo(arg->GetName()) ; + Bool_t varMatch = !TString(var->GetName()).CompareTo(arg->GetName()) && !TString(var->getStringAttribute("origName")).CompareTo(arg->GetName()); if (varMatch) { TString& lbl= ((TObjString*) _labelList.At(i))->String() ; diff --git a/roofit/roofitcore/src/RooFormulaVar.cxx b/roofit/roofitcore/src/RooFormulaVar.cxx index 369c4aaf8273e..b5c99bf330582 100644 --- a/roofit/roofitcore/src/RooFormulaVar.cxx +++ b/roofit/roofitcore/src/RooFormulaVar.cxx @@ -16,12 +16,12 @@ ////////////////////////////////////////////////////////////////////////////// // -// RooRealVar is a generic implementation of a real valued object +// RooFormulaVar is a generic implementation of a real valued object // which takes a RooArgList of servers and a C++ expression string defining how // its value should be calculated from the given list of servers. -// RooRealVar uses a RooFormula object to perform the expression evaluation. +// RooFormulaVar uses a RooFormula object to perform the expression evaluation. // -// If RooAbsPdf objects are supplied to RooRealVar as servers, their +// If RooAbsPdf objects are supplied to RooFormulaVar as servers, their // raw (unnormalized) values will be evaluated. Use RooGenericPdf, which // constructs generic PDF functions, to access their properly normalized // values. @@ -29,8 +29,8 @@ // The string expression can be any valid TFormula expression referring to the // listed servers either by name or by their ordinal list position: // -// RooRealVar("gen","x*y",RooArgList(x,y)) or -// RooRealVar("gen","@0*@1",RooArgList(x,y)) +// RooFormulaVar("gen","x*y",RooArgList(x,y)) or +// RooFormulaVar("gen","@0*@1",RooArgList(x,y)) // // The latter form, while slightly less readable, is more versatile because it // doesn't hardcode any of the variable names it expects @@ -46,8 +46,10 @@ #include "RooNLLVar.h" #include "RooChi2Var.h" #include "RooMsgService.h" +#include "RooTrace.h" +using namespace std; ClassImp(RooFormulaVar) @@ -64,6 +66,7 @@ RooFormulaVar::RooFormulaVar(const char *name, const char *title, const char* in _actualVars.add(dependents) ; if (_actualVars.getSize()==0) _value = traceEval(0) ; + TRACE_CREATE } @@ -79,6 +82,7 @@ RooFormulaVar::RooFormulaVar(const char *name, const char *title, const RooArgLi _actualVars.add(dependents) ; if (_actualVars.getSize()==0) _value = traceEval(0) ; + TRACE_CREATE } @@ -90,6 +94,7 @@ RooFormulaVar::RooFormulaVar(const RooFormulaVar& other, const char* name) : _formula(0), _formExpr(other._formExpr) { // Copy constructor + TRACE_CREATE } @@ -100,6 +105,7 @@ RooFormulaVar::~RooFormulaVar() // Destructor if (_formula) delete _formula ; + TRACE_DESTROY } @@ -139,7 +145,7 @@ Bool_t RooFormulaVar::isValidReal(Double_t /*value*/, Bool_t /*printError*/) con Bool_t RooFormulaVar::redirectServersHook(const RooAbsCollection& newServerList, Bool_t mustReplaceAll, Bool_t nameChange, Bool_t /*isRecursive*/) { // Propagate server change information to embedded RooFormula object - return _formula ? _formula->changeDependents(newServerList,mustReplaceAll,nameChange) : kFALSE ; + return formula().changeDependents(newServerList,mustReplaceAll,nameChange) ; } diff --git a/roofit/roofitcore/src/RooFracRemainder.cxx b/roofit/roofitcore/src/RooFracRemainder.cxx index 95b1d70f09b2d..315d858c2dea2 100644 --- a/roofit/roofitcore/src/RooFracRemainder.cxx +++ b/roofit/roofitcore/src/RooFracRemainder.cxx @@ -39,6 +39,8 @@ #include "RooArgSet.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooFracRemainder) ; diff --git a/roofit/roofitcore/src/RooFunctor.cxx b/roofit/roofitcore/src/RooFunctor.cxx index 3f6454166f50c..c1a4eb8f553e4 100644 --- a/roofit/roofitcore/src/RooFunctor.cxx +++ b/roofit/roofitcore/src/RooFunctor.cxx @@ -36,6 +36,8 @@ +using namespace std; + ClassImp(RooFunctor) ; diff --git a/roofit/roofitcore/src/RooGaussKronrodIntegrator1D.cxx b/roofit/roofitcore/src/RooGaussKronrodIntegrator1D.cxx index 2d23e26bcd103..18ebf97c58ed6 100644 --- a/roofit/roofitcore/src/RooGaussKronrodIntegrator1D.cxx +++ b/roofit/roofitcore/src/RooGaussKronrodIntegrator1D.cxx @@ -57,6 +57,8 @@ #include "RooMsgService.h" +using namespace std; + ClassImp(RooGaussKronrodIntegrator1D) ; diff --git a/roofit/roofitcore/src/RooGenCategory.cxx b/roofit/roofitcore/src/RooGenCategory.cxx index a89774cdbbd75..bc9ee618f8046 100644 --- a/roofit/roofitcore/src/RooGenCategory.cxx +++ b/roofit/roofitcore/src/RooGenCategory.cxx @@ -48,6 +48,8 @@ #include "Api.h" #endif +using namespace std; + ClassImp(RooGenCategory) diff --git a/roofit/roofitcore/src/RooGenContext.cxx b/roofit/roofitcore/src/RooGenContext.cxx index 9035cc8b24052..4ed2dce559bcc 100644 --- a/roofit/roofitcore/src/RooGenContext.cxx +++ b/roofit/roofitcore/src/RooGenContext.cxx @@ -49,6 +49,8 @@ +using namespace std; + ClassImp(RooGenContext) ; diff --git a/roofit/roofitcore/src/RooGenFitStudy.cxx b/roofit/roofitcore/src/RooGenFitStudy.cxx index 098ee9742ac56..e2e17edbd9284 100644 --- a/roofit/roofitcore/src/RooGenFitStudy.cxx +++ b/roofit/roofitcore/src/RooGenFitStudy.cxx @@ -172,13 +172,14 @@ Bool_t RooGenFitStudy::initialize() _ngenVar = new RooRealVar("ngen","number of generated events",0) ; _params = _fitPdf->getParameters(_genObs) ; + RooArgSet modelParams(*_params) ; _initParams = (RooArgSet*) _params->snapshot() ; _params->add(*_nllVar) ; _params->add(*_ngenVar) ; _genSpec = _genPdf->prepareMultiGen(_genObs,(RooCmdArg&)*_genOpts.At(0),(RooCmdArg&)*_genOpts.At(1),(RooCmdArg&)*_genOpts.At(2)) ; - registerSummaryOutput(*_params) ; + registerSummaryOutput(*_params,modelParams) ; return kFALSE ; } diff --git a/roofit/roofitcore/src/RooGenFunction.cxx b/roofit/roofitcore/src/RooGenFunction.cxx index ecfa08f97cc2f..a396131ef63f3 100644 --- a/roofit/roofitcore/src/RooGenFunction.cxx +++ b/roofit/roofitcore/src/RooGenFunction.cxx @@ -36,6 +36,8 @@ +using namespace std; + ClassImp(RooGenFunction) ; diff --git a/roofit/roofitcore/src/RooGenProdProj.cxx b/roofit/roofitcore/src/RooGenProdProj.cxx index 8bb079eaef355..2e3b80320f3aa 100644 --- a/roofit/roofitcore/src/RooGenProdProj.cxx +++ b/roofit/roofitcore/src/RooGenProdProj.cxx @@ -43,6 +43,8 @@ #include "RooErrorHandler.h" #include "RooProduct.h" +using namespace std; + ClassImp(RooGenProdProj) ; @@ -71,6 +73,9 @@ RooGenProdProj::RooGenProdProj(const char *name, const char *title, const RooArg // Constructor for a normalization projection of the product of p.d.f.s _prodSet // integrated over _intSet in range isetRangeName while normalized over _normSet + // Set expensive object cache to that of first item in prodSet + setExpensiveObjectCache(_prodSet.first()->expensiveObjectCache()) ; + // Create owners of components created in ctor _compSetOwnedN = new RooArgSet ; _compSetOwnedD = new RooArgSet ; @@ -229,6 +234,7 @@ RooAbsReal* RooGenProdProj::makeIntegral(const char* name, const RooArgSet& comp prodName = Form("%s_%s",GetName(),name) ; } RooProduct* prod = new RooProduct(prodName,"product",prodSet) ; + prod->setExpensiveObjectCache(expensiveObjectCache()) ; prod->setOperMode(_operMode) ; // Declare owndership of product diff --git a/roofit/roofitcore/src/RooGenericPdf.cxx b/roofit/roofitcore/src/RooGenericPdf.cxx index fa0659ea2192e..3e9fff1c3909f 100644 --- a/roofit/roofitcore/src/RooGenericPdf.cxx +++ b/roofit/roofitcore/src/RooGenericPdf.cxx @@ -45,6 +45,8 @@ +using namespace std; + ClassImp(RooGenericPdf) diff --git a/roofit/roofitcore/src/RooGlobalFunc.cxx b/roofit/roofitcore/src/RooGlobalFunc.cxx index 8a15af3488a17..2e193f26d8a84 100644 --- a/roofit/roofitcore/src/RooGlobalFunc.cxx +++ b/roofit/roofitcore/src/RooGlobalFunc.cxx @@ -18,7 +18,6 @@ #include "RooFit.h" -#include "RooGlobalFunc.h" #include "RooGlobalFunc.h" #include "RooCategory.h" #include "RooRealConstant.h" @@ -30,6 +29,8 @@ #include "RooAbsPdf.h" #include "TH1.h" +using namespace std; + namespace RooFit { // RooAbsReal::plotOn arguments @@ -118,8 +119,8 @@ namespace RooFit { // RooDataSet::ctor arguments - RooCmdArg WeightVar(const char* name) { return RooCmdArg("WeightVarName",0,0,0,0,name,0,0,0) ; } - RooCmdArg WeightVar(const RooRealVar& arg) { return RooCmdArg("WeightVar",0,0,0,0,0,0,&arg,0) ; } + RooCmdArg WeightVar(const char* name, Bool_t reinterpretAsWeight) { return RooCmdArg("WeightVarName",reinterpretAsWeight,0,0,0,name,0,0,0) ; } + RooCmdArg WeightVar(const RooRealVar& arg, Bool_t reinterpretAsWeight) { return RooCmdArg("WeightVar",reinterpretAsWeight,0,0,0,0,0,&arg,0) ; } RooCmdArg Link(const char* state, RooAbsData& data) { return RooCmdArg("LinkDataSlice",0,0,0,0,state,0,&data,0) ;} RooCmdArg Import(const char* state, RooDataSet& data) { return RooCmdArg("ImportDataSlice",0,0,0,0,state,0,&data,0) ; } RooCmdArg Import(RooDataSet& data) { return RooCmdArg("ImportData",0,0,0,0,0,0,&data,0) ; } @@ -152,7 +153,7 @@ namespace RooFit { // RooChi2Var::ctor arguments RooCmdArg Extended(Bool_t flag) { return RooCmdArg("Extended",flag,0,0,0,0,0,0,0) ; } RooCmdArg DataError(Int_t etype) { return RooCmdArg("DataError",(Int_t)etype,0,0,0,0,0,0,0) ; } - RooCmdArg NumCPU(Int_t nCPU, Bool_t interleave) { return RooCmdArg("NumCPU",nCPU,interleave,0,0,0,0,0,0) ; } + RooCmdArg NumCPU(Int_t nCPU, Int_t interleave) { return RooCmdArg("NumCPU",nCPU,interleave,0,0,0,0,0,0) ; } // RooAbsCollection::printLatex arguments RooCmdArg Columns(Int_t ncol) { return RooCmdArg("Columns",ncol,0,0,0,0,0,0,0) ; } @@ -195,6 +196,7 @@ namespace RooFit { RooCmdArg SumCoefRange(const char* rangeName) { return RooCmdArg("SumCoefRange",0,0,0,0,rangeName,0,0,0) ; } RooCmdArg Constrain(const RooArgSet& params) { return RooCmdArg("Constrain",0,0,0,0,0,0,0,0,0,0,¶ms) ; } RooCmdArg GlobalObservables(const RooArgSet& globs) { return RooCmdArg("GlobalObservables",0,0,0,0,0,0,0,0,0,0,&globs) ; } + RooCmdArg GlobalObservablesTag(const char* tagName) { return RooCmdArg("GlobalObservablesTag",0,0,0,0,tagName,0,0,0) ; } RooCmdArg Constrained() { return RooCmdArg("Constrained",kTRUE,0,0,0,0,0,0,0) ; } RooCmdArg ExternalConstraints(const RooArgSet& cpdfs) { return RooCmdArg("ExternalConstraints",0,0,0,0,0,0,&cpdfs,0,0,0,&cpdfs) ; } RooCmdArg PrintEvalErrors(Int_t numErrors) { return RooCmdArg("PrintEvalErrors",numErrors,0,0,0,0,0,0,0) ; } @@ -203,6 +205,7 @@ namespace RooFit { RooCmdArg CloneData(Bool_t flag) { return RooCmdArg("CloneData",flag,0,0,0,0,0,0,0) ; } RooCmdArg Integrate(Bool_t flag) { return RooCmdArg("Integrate",flag,0,0,0,0,0,0,0) ; } RooCmdArg Minimizer(const char* type, const char* alg) { return RooCmdArg("Minimizer",0,0,0,0,type,alg,0,0) ; } + RooCmdArg Offset(Bool_t flag) { return RooCmdArg("OffsetLikelihood",flag,0,0,0,0,0,0,0) ; } // RooAbsPdf::paramOn arguments @@ -235,6 +238,9 @@ namespace RooFit { RooCmdArg AxisLabel(const char* name) { return RooCmdArg("AxisLabel",0,0,0,0,name,0,0,0) ; } RooCmdArg Scaling(Bool_t flag) { return RooCmdArg("Scaling",flag,0,0,0,0,0,0,0) ; } + // RooAbsReal::createHistogram arguments + RooCmdArg IntrinsicBinning(Bool_t flag) { return RooCmdArg("IntrinsicBinning",flag,0,0,0,0,0,0,0) ; } + // RooAbsData::createHistogram arguments RooCmdArg AutoSymBinning(Int_t nbins, Double_t marginFactor) { return RooCmdArg("AutoRangeData",1,nbins,marginFactor,0,0,0,0,0) ; } RooCmdArg AutoBinning(Int_t nbins, Double_t marginFactor) { return RooCmdArg("AutoRangeData",0,nbins,marginFactor,0,0,0,0,0) ; } @@ -290,19 +296,21 @@ namespace RooFit { RooCmdArg ClassName(const char* name) { return RooCmdArg("ClassName",0,0,0,0,name,0,0,0) ; } RooCmdArg BaseClassName(const char* name) { return RooCmdArg("BaseClassName",0,0,0,0,name,0,0,0) ; } RooCmdArg TagName(const char* name) { return RooCmdArg("LabelName",0,0,0,0,name,0,0,0) ; } - RooCmdArg OutputStream(ostream& os) { return RooCmdArg("OutputStream",0,0,0,0,0,0,reinterpret_cast<TObject*>(&os),0) ; } + RooCmdArg OutputStream(ostream& os) { return RooCmdArg("OutputStream",0,0,0,0,0,0,reinterpret_cast<TObject*>(&os),0) ; } RooCmdArg Prefix(Bool_t flag) { return RooCmdArg("Prefix",flag,0,0,0,0,0,0,0) ; } RooCmdArg Color(Color_t color) { return RooCmdArg("Color",color,0,0,0,0,0,0,0) ; } // RooWorkspace::import() arguments - RooCmdArg RenameConflictNodes(const char* suffix) { return RooCmdArg("RenameConflictNodes",0,0,0,0,suffix,0,0,0) ; } + RooCmdArg RenameConflictNodes(const char* suffix, Bool_t ro) { return RooCmdArg("RenameConflictNodes",ro,0,0,0,suffix,0,0,0) ; } RooCmdArg RecycleConflictNodes(Bool_t flag) { return RooCmdArg("RecycleConflictNodes",flag,0,0,0,0,0,0,0) ; } RooCmdArg RenameAllNodes(const char* suffix) { return RooCmdArg("RenameAllNodes",0,0,0,0,suffix,0,0,0) ; } RooCmdArg RenameAllVariables(const char* suffix) { return RooCmdArg("RenameAllVariables",0,0,0,0,suffix,0,0,0) ; } RooCmdArg RenameAllVariablesExcept(const char* suffix, const char* except) { return RooCmdArg("RenameAllVariables",0,0,0,0,suffix,except,0,0) ; } RooCmdArg RenameVariable(const char* in, const char* out) { return RooCmdArg("RenameVar",0,0,0,0,in,out,0,0) ; } RooCmdArg Rename(const char* suffix) { return RooCmdArg("Rename",0,0,0,0,suffix,0,0,0) ; } + RooCmdArg Embedded(Bool_t flag) { return RooCmdArg("Embedded",flag,0,0,0,0,0,0,0) ; } + RooCmdArg NoRecursion(Bool_t flag) { return RooCmdArg("NoRecursion",flag,0,0,0,0,0,0,0) ; } // RooSimCloneTool::build() arguments RooCmdArg SplitParam(const char* varname, const char* catname) { return RooCmdArg("SplitParam",0,0,0,0,varname,catname,0,0) ; } @@ -318,6 +326,14 @@ namespace RooFit { RooCmdArg ScanAllCdf() { return RooCmdArg("ScanAllCdf",1,0,0,0,0,0,0,0) ; } RooCmdArg ScanNoCdf() { return RooCmdArg("ScanNoCdf",1,0,0,0,0,0,0,0) ; } + + RooCmdArg MultiArg(const RooCmdArg& arg1,const RooCmdArg& arg2,const RooCmdArg& arg3,const RooCmdArg& arg4, + const RooCmdArg& arg5,const RooCmdArg& arg6,const RooCmdArg& arg7,const RooCmdArg& arg8) { + RooCmdArg ret("MultiArg",0,0,0,0,0,0,0,0) ; ret.addArg(arg1) ; ret.addArg(arg2) ; + ret.addArg(arg3) ; ret.addArg(arg4) ; ret.addArg(arg5) ; ret.addArg(arg6) ; ret.addArg(arg7) ; ret.addArg(arg8) ; + ret.setProcessRecArgs(kTRUE,kFALSE) ; return ret ; + } + RooConstVar& RooConst(Double_t val) { return RooRealConstant::value(val) ; } diff --git a/roofit/roofitcore/src/RooGrid.cxx b/roofit/roofitcore/src/RooGrid.cxx index dc85e681db4ca..bcf19e5f232f6 100644 --- a/roofit/roofitcore/src/RooGrid.cxx +++ b/roofit/roofitcore/src/RooGrid.cxx @@ -38,6 +38,8 @@ #include "Riostream.h" #include <iomanip> +using namespace std; + ClassImp(RooGrid) ; diff --git a/roofit/roofitcore/src/RooHashTable.cxx b/roofit/roofitcore/src/RooHashTable.cxx index e7ec9cd5d16c3..c42c09987381a 100644 --- a/roofit/roofitcore/src/RooHashTable.cxx +++ b/roofit/roofitcore/src/RooHashTable.cxx @@ -24,6 +24,8 @@ #include "RooAbsArg.h" #include "RooSetPair.h" +using namespace std; + ClassImp(RooHashTable) ; @@ -87,6 +89,7 @@ void RooHashTable::add(TObject* arg, TObject* hashArg) Int_t slot = hash(hashArg?hashArg:arg) % _size ; if (!_arr[slot]) { _arr[slot] = new RooLinkedList(0) ; + _arr[slot]->useNptr(kFALSE) ; _usedSlots++ ; } _arr[slot]->Add(arg); diff --git a/roofit/roofitcore/src/RooHist.cxx b/roofit/roofitcore/src/RooHist.cxx index 3920fccd53338..65fbd7583e853 100644 --- a/roofit/roofitcore/src/RooHist.cxx +++ b/roofit/roofitcore/src/RooHist.cxx @@ -38,6 +38,8 @@ #include <iomanip> #include <math.h> +using namespace std; + ClassImp(RooHist) ; diff --git a/roofit/roofitcore/src/RooHistError.cxx b/roofit/roofitcore/src/RooHistError.cxx index 2c27e85829e0d..8ebfa21caa162 100644 --- a/roofit/roofitcore/src/RooHistError.cxx +++ b/roofit/roofitcore/src/RooHistError.cxx @@ -33,6 +33,8 @@ #include "Riostream.h" #include <assert.h> +using namespace std; + ClassImp(RooHistError) ; diff --git a/roofit/roofitcore/src/RooHistFunc.cxx b/roofit/roofitcore/src/RooHistFunc.cxx index 94be455f3e2a3..a0c3f223b0c06 100644 --- a/roofit/roofitcore/src/RooHistFunc.cxx +++ b/roofit/roofitcore/src/RooHistFunc.cxx @@ -31,8 +31,10 @@ #include "RooMsgService.h" #include "RooRealVar.h" #include "RooCategory.h" +#include "RooWorkspace.h" +using namespace std; ClassImp(RooHistFunc) ; @@ -245,7 +247,6 @@ Double_t RooHistFunc::analyticalIntegral(Int_t code, const char* /*rangeName*/) } // Partial integration scenario, retrieve set of variables, calculate partial sum - RooArgSet intSet ; TIterator* iter = _depList.createIterator() ; RooAbsArg* arg ; @@ -272,7 +273,7 @@ list<Double_t>* RooHistFunc::plotSamplingHint(RooAbsRealLValue& obs, Double_t xl // with the vertical lines that occur in a non-interpolated histogram // No hints are required when interpolation is used - if (_intOrder>0) { + if (_intOrder>1) { return 0 ; } @@ -315,7 +316,7 @@ std::list<Double_t>* RooHistFunc::binBoundaries(RooAbsRealLValue& obs, Double_t // with the vertical lines that occur in a non-interpolated histogram // No hints are required when interpolation is used - if (_intOrder>0) { + if (_intOrder>1) { return 0 ; } @@ -343,6 +344,83 @@ std::list<Double_t>* RooHistFunc::binBoundaries(RooAbsRealLValue& obs, Double_t } +//_____________________________________________________________________________ +Bool_t RooHistFunc::importWorkspaceHook(RooWorkspace& ws) +{ + // Check if our datahist is already in the workspace + std::list<RooAbsData*> allData = ws.allEmbeddedData() ; + std::list<RooAbsData*>::const_iterator iter ; + for (iter = allData.begin() ; iter != allData.end() ; ++iter) { + // If your dataset is already in this workspace nothing needs to be done + if (*iter == _dataHist) { + return kFALSE ; + } + } + + // Check if dataset with given name already exists + RooAbsData* wsdata = ws.embeddedData(_dataHist->GetName()) ; + + if (wsdata) { + + // Yes it exists - now check if it is identical to our internal histogram + if (wsdata->InheritsFrom(RooDataHist::Class())) { + + // Check if histograms are identical + if (areIdentical((RooDataHist&)*wsdata,*_dataHist)) { + + // Exists and is of correct type, and identical -- adjust internal pointer to WS copy + _dataHist = (RooDataHist*) wsdata ; + } else { + + // not identical, clone rename and import + TString uniqueName = Form("%s_%s",_dataHist->GetName(),GetName()) ; + Bool_t flag = ws.import(*_dataHist,RooFit::Rename(uniqueName.Data()),RooFit::Embedded()) ; + if (flag) { + coutE(ObjectHandling) << " RooHistPdf::importWorkspaceHook(" << GetName() << ") unable to import clone of underlying RooDataHist with unique name " << uniqueName << ", abort" << endl ; + return kTRUE ; + } + _dataHist = (RooDataHist*) ws.embeddedData(uniqueName.Data()) ; + } + + } else { + + // Exists and is NOT of correct type: clone rename and import + TString uniqueName = Form("%s_%s",_dataHist->GetName(),GetName()) ; + Bool_t flag = ws.import(*_dataHist,RooFit::Rename(uniqueName.Data()),RooFit::Embedded()) ; + if (flag) { + coutE(ObjectHandling) << " RooHistPdf::importWorkspaceHook(" << GetName() << ") unable to import clone of underlying RooDataHist with unique name " << uniqueName << ", abort" << endl ; + return kTRUE ; + } + _dataHist = (RooDataHist*) ws.embeddedData(uniqueName.Data()) ; + + } + return kFALSE ; + } + + // We need to import our datahist into the workspace + ws.import(*_dataHist,RooFit::Embedded()) ; + + // Redirect our internal pointer to the copy in the workspace + _dataHist = (RooDataHist*) ws.embeddedData(_dataHist->GetName()) ; + return kFALSE ; +} + + +//_____________________________________________________________________________ +Bool_t RooHistFunc::areIdentical(const RooDataHist& dh1, const RooDataHist& dh2) +{ + if (fabs(dh1.sumEntries()-dh2.sumEntries())>1e-8) return kFALSE ; + if (dh1.numEntries() != dh2.numEntries()) return kFALSE ; + for (int i=0 ; i < dh1.numEntries() ; i++) { + dh1.get(i) ; + dh2.get(i) ; + if (fabs(dh1.weight()-dh2.weight())>1e-8) return kFALSE ; + } + return kTRUE ; +} + + + //______________________________________________________________________________ void RooHistFunc::Streamer(TBuffer &R__b) { diff --git a/roofit/roofitcore/src/RooHistPdf.cxx b/roofit/roofitcore/src/RooHistPdf.cxx index 8f252e090072f..2c830180af2b5 100644 --- a/roofit/roofitcore/src/RooHistPdf.cxx +++ b/roofit/roofitcore/src/RooHistPdf.cxx @@ -33,9 +33,12 @@ #include "RooRealVar.h" #include "RooCategory.h" #include "RooWorkspace.h" +#include "RooGlobalFunc.h" +using namespace std; + ClassImp(RooHistPdf) ; @@ -91,6 +94,20 @@ RooHistPdf::RooHistPdf(const char *name, const char *title, const RooArgSet& var _histObsIter = _histObsList.createIterator() ; _pdfObsIter = _pdfObsList.createIterator() ; + + + // Adjust ranges of _histObsList to those of _dataHist + RooFIter oiter = _histObsList.fwdIterator() ; + RooAbsArg* hobs ; + while ((hobs = oiter.next())) { + // Guaranteed to succeed, since checked above in ctor + RooAbsArg* dhobs = dhist.get()->find(hobs->GetName()) ; + RooRealVar* dhreal = dynamic_cast<RooRealVar*>(dhobs) ; + if (dhreal){ + ((RooRealVar*)hobs)->setRange(dhreal->getMin(),dhreal->getMax()) ; + } + } + } @@ -142,6 +159,18 @@ RooHistPdf::RooHistPdf(const char *name, const char *title, const RooArgList& pd _histObsIter = _histObsList.createIterator() ; _pdfObsIter = _pdfObsList.createIterator() ; + + // Adjust ranges of _histObsList to those of _dataHist + RooFIter oiter = _histObsList.fwdIterator() ; + RooAbsArg* hobs ; + while ((hobs = oiter.next())) { + // Guaranteed to succeed, since checked above in ctor + RooAbsArg* dhobs = dhist.get()->find(hobs->GetName()) ; + RooRealVar* dhreal = dynamic_cast<RooRealVar*>(dhobs) ; + if (dhreal){ + ((RooRealVar*)hobs)->setRange(dhreal->getMin(),dhreal->getMax()) ; + } + } } @@ -198,6 +227,9 @@ Double_t RooHistPdf::evaluate() const if (harg != parg) { parg->syncCache() ; harg->copyCache(parg,kTRUE) ; + if (!harg->inRange(0)) { + return 0 ; + } } } } @@ -205,9 +237,7 @@ Double_t RooHistPdf::evaluate() const Double_t ret = _dataHist->weight(_histObsList,_intOrder,_unitNorm?kFALSE:kTRUE,_cdfBoundaries) ; if (ret<0) { ret=0 ; - } - - //cout << "RooHistPdf::evaluate(" << GetName() << ") ret = " << ret << " at " << ((RooAbsReal*)_histObsList.first())->getVal() << endl ; + } return ret ; } @@ -240,11 +270,20 @@ Double_t RooHistPdf::totVolume() const } namespace { - bool fullRange(const RooAbsArg& x ,const char* range) { - if (range == 0 || strlen(range) == 0 ) return true; + bool fullRange(const RooAbsArg& x, const RooAbsArg& y ,const char* range) + { const RooAbsRealLValue *_x = dynamic_cast<const RooAbsRealLValue*>(&x); - if (!_x) return false; - return ( _x->getMin(range) == _x->getMin() && _x->getMax(range) == _x->getMax() ) ; + const RooAbsRealLValue *_y = dynamic_cast<const RooAbsRealLValue*>(&y); + if (!_x || !_y) return false; + if (!range || !strlen(range) || !_x->hasRange(range) || + _x->getBinningPtr(range)->isParameterized()) { + // parameterized ranges may be full range now, but that might change, + // so return false + if (range && strlen(range) && _x->getBinningPtr(range)->isParameterized()) + return false; + return (_x->getMin() == _y->getMin() && _x->getMax() == _y->getMax()); + } + return (_x->getMin(range) == _y->getMin() && _x->getMax(range) == _y->getMax()); } } @@ -258,113 +297,95 @@ Int_t RooHistPdf::getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVars, // histogram. If interpolation is used on the integral over // all histogram observables is supported - // First make list of pdf observables to histogram observables // and select only those for which the integral is over the full range - RooArgList hobsl(_histObsList),pobsl(_pdfObsList) ; - RooArgSet allVarsHist ; - TIterator* iter = allVars.createIterator() ; - RooAbsArg* pdfobs ; - while((pdfobs=(RooAbsArg*)iter->Next())) { - Int_t idx = pobsl.index(pdfobs) ; - if (idx>=0) { - RooAbsArg* hobs = hobsl.at(idx) ; - if (hobs && fullRange( *hobs, rangeName ) ) { - allVarsHist.add(*hobs) ; + RooFIter it = _pdfObsList.fwdIterator(); + RooFIter jt = _histObsList.fwdIterator(); + Int_t code = 0, frcode = 0, n = 0; + for (RooAbsArg *pa = 0, *ha = 0; (pa = it.next()) && (ha = jt.next()); ++n) { + if (allVars.find(*pa)) { + code |= 2 << n; + analVars.add(*pa); + if (fullRange(*pa, *ha, rangeName)) { + frcode |= 2 << n; } } } - delete iter ; - // Simplest scenario, integrate over all dependents - RooAbsCollection *allVarsCommon = allVarsHist.selectCommon(_histObsList) ; - Bool_t intAllObs = (allVarsCommon->getSize()==_histObsList.getSize()) ; - delete allVarsCommon ; - if (intAllObs) { - analVars.add(allVars) ; - return 1000 ; - } - - // Disable partial analytical integrals if interpolation is used -// if (_intOrder>0) { -// return 0 ; -// } - - // Find subset of _histObsList that integration is requested over - RooArgSet* allVarsSel = (RooArgSet*) allVarsHist.selectCommon(_histObsList) ; - if (allVarsSel->getSize()==0) { - delete allVarsSel ; - return 0 ; + if (code == frcode) { + // integrate over full range of all observables - use bit 0 to indicate + // full range integration over all observables + code |= 1; } - - // Partial integration scenarios. - // Build unique code from bit mask of integrated variables in depList - Int_t code(0),n(0) ; - iter = _histObsList.createIterator() ; - RooAbsArg* arg ; - while((arg=(RooAbsArg*)iter->Next())) { - if (allVars.find(arg->GetName())) { - code |= (1<<n) ; - analVars.add(*pobsl.at(n)) ; - } - n++ ; + // Disable partial analytical integrals if interpolation is used, and we + // integrate over sub-ranges, but leave them enabled when we integrate over + // the full range of one or several variables + if (_intOrder > 0 && !(code & 1)) { + analVars.removeAll(); + return 0; } - delete iter ; - - return code ; - + return (code >= 2) ? code : 0; } //_____________________________________________________________________________ -Double_t RooHistPdf::analyticalIntegral(Int_t code, const char* /*rangeName*/) const +Double_t RooHistPdf::analyticalIntegral(Int_t code, const char* rangeName) const { // Return integral identified by 'code'. The actual integration // is deferred to RooDataHist::sum() which implements partial // or complete summation over the histograms contents - // WVE needs adaptation for rangeName feature - // Simplest scenario, integration over all dependents - if (code==1000) { - return _dataHist->sum(kFALSE) ; + // Simplest scenario, full-range integration over all dependents + if (((2 << _histObsList.getSize()) - 1) == code) { + return _dataHist->sum(kFALSE); } - // Partial integration scenario, retrieve set of variables, calculate partial sum - RooArgSet intSet ; - TIterator* iter = _histObsList.createIterator() ; - RooAbsArg* arg ; - Int_t n(0) ; - while((arg=(RooAbsArg*)iter->Next())) { - if (code & (1<<n)) { - intSet.add(*arg) ; + // Partial integration scenario, retrieve set of variables, calculate partial + // sum, figure out integration ranges (if needed) + RooArgSet intSet; + std::map<const RooAbsArg*, std::pair<Double_t, Double_t> > ranges; + RooFIter it = _pdfObsList.fwdIterator(); + RooFIter jt = _histObsList.fwdIterator(); + Int_t n(0); + for (RooAbsArg *pa = 0, *ha = 0; (pa = it.next()) && (ha = jt.next()); ++n) { + if (code & (2 << n)) { + intSet.add(*ha); } - n++ ; - } - delete iter ; - - // WVE must sync hist slice list values to pdf slice list - // Transfer values from - if (_pdfObsList.getSize()>0) { - _histObsIter->Reset() ; - _pdfObsIter->Reset() ; - RooAbsArg* harg, *parg ; - while((harg=(RooAbsArg*)_histObsIter->Next())) { - parg = (RooAbsArg*)_pdfObsIter->Next() ; - if (harg != parg) { - parg->syncCache() ; - harg->copyCache(parg,kTRUE) ; + if (!(code & 1)) { + RooAbsRealLValue* rlv = dynamic_cast<RooAbsRealLValue*>(pa); + if (rlv) { + const RooAbsBinning* binning = rlv->getBinningPtr(rangeName); + if (rlv->hasRange(rangeName)) { + ranges[ha] = std::make_pair( + rlv->getMin(rangeName), rlv->getMax(rangeName)); + } else if (binning) { + if (!binning->isParameterized()) { + ranges[ha] = std::make_pair( + binning->lowBound(), binning->highBound()); + } else { + ranges[ha] = std::make_pair( + binning->lowBoundFunc()->getVal(), binning->highBoundFunc()->getVal()); + } + } } } - } - + // WVE must sync hist slice list values to pdf slice list + // Transfer values from + if (ha != pa) { + pa->syncCache(); + ha->copyCache(pa,kTRUE); + } + } - Double_t ret = _dataHist->sum(intSet,_histObsList,kTRUE,kTRUE) ; + Double_t ret = (code & 1) ? + _dataHist->sum(intSet,_histObsList,kTRUE,kTRUE) : + _dataHist->sum(intSet,_histObsList,kTRUE,kTRUE, ranges); -// cout << "intSet = " << intSet << endl ; -// cout << "slice position = " << endl ; -// _histObsList.Print("v") ; -// cout << "RooHistPdf::ai(" << GetName() << ") code = " << code << " ret = " << ret << endl ; +// cout << "intSet = " << intSet << endl ; +// cout << "slice position = " << endl ; +// _histObsList.Print("v") ; +// cout << "RooHistPdf::ai(" << GetName() << ") code = " << code << " ret = " << ret << endl ; return ret ; } @@ -384,13 +405,27 @@ list<Double_t>* RooHistPdf::plotSamplingHint(RooAbsRealLValue& obs, Double_t xlo } // Check that observable is in dataset, if not no hint is generated - RooAbsLValue* lvarg = dynamic_cast<RooAbsLValue*>(_dataHist->get()->find(obs.GetName())) ; - if (!lvarg) { + _histObsIter->Reset() ; + _pdfObsIter->Reset() ; + RooAbsArg *pdfObs, *histObs, *dhObs(0) ; + while ((pdfObs = (RooAbsArg*)_pdfObsIter->Next()) && !dhObs) { + histObs = (RooAbsArg*) _histObsIter->Next() ; + if (TString(obs.GetName())==pdfObs->GetName()) { + dhObs = _dataHist->get()->find(histObs->GetName()) ; + } + } + + if (!dhObs) { + return 0 ; + } + RooAbsLValue* lval = dynamic_cast<RooAbsLValue*>(dhObs) ; + if (!lval) { return 0 ; } // Retrieve position of all bin boundaries - const RooAbsBinning* binning = lvarg->getBinningPtr(0) ; + + const RooAbsBinning* binning = lval->getBinningPtr(0) ; Double_t* boundaries = binning->array() ; list<Double_t>* hint = new list<Double_t> ; @@ -483,6 +518,23 @@ Double_t RooHistPdf::maxVal(Int_t code) const } + + +//_____________________________________________________________________________ +Bool_t RooHistPdf::areIdentical(const RooDataHist& dh1, const RooDataHist& dh2) +{ + if (fabs(dh1.sumEntries()-dh2.sumEntries())>1e-8) return kFALSE ; + if (dh1.numEntries() != dh2.numEntries()) return kFALSE ; + for (int i=0 ; i < dh1.numEntries() ; i++) { + dh1.get(i) ; + dh2.get(i) ; + if (fabs(dh1.weight()-dh2.weight())>1e-8) return kFALSE ; + } + return kTRUE ; +} + + + //_____________________________________________________________________________ Bool_t RooHistPdf::importWorkspaceHook(RooWorkspace& ws) { @@ -497,28 +549,50 @@ Bool_t RooHistPdf::importWorkspaceHook(RooWorkspace& ws) } // Check if dataset with given name already exists - RooAbsData* wsdata = ws.data(_dataHist->GetName()) ; + RooAbsData* wsdata = ws.embeddedData(_dataHist->GetName()) ; + if (wsdata) { + + // Yes it exists - now check if it is identical to our internal histogram if (wsdata->InheritsFrom(RooDataHist::Class())) { - // Exists and is of correct type -- adjust internal pointer - _dataHist = (RooDataHist*) wsdata ; - return kFALSE ; + + // Check if histograms are identical + if (areIdentical((RooDataHist&)*wsdata,*_dataHist)) { + + // Exists and is of correct type, and identical -- adjust internal pointer to WS copy + _dataHist = (RooDataHist*) wsdata ; + } else { + + // not identical, clone rename and import + TString uniqueName = Form("%s_%s",_dataHist->GetName(),GetName()) ; + Bool_t flag = ws.import(*_dataHist,RooFit::Rename(uniqueName.Data()),RooFit::Embedded()) ; + if (flag) { + coutE(ObjectHandling) << " RooHistPdf::importWorkspaceHook(" << GetName() << ") unable to import clone of underlying RooDataHist with unique name " << uniqueName << ", abort" << endl ; + return kTRUE ; + } + _dataHist = (RooDataHist*) ws.embeddedData(uniqueName.Data()) ; + } + } else { - // Exists and is NOT of correct type -- abort + + // Exists and is NOT of correct type: clone rename and import + TString uniqueName = Form("%s_%s",_dataHist->GetName(),GetName()) ; + Bool_t flag = ws.import(*_dataHist,RooFit::Rename(uniqueName.Data()),RooFit::Embedded()) ; + if (flag) { + coutE(ObjectHandling) << " RooHistPdf::importWorkspaceHook(" << GetName() << ") unable to import clone of underlying RooDataHist with unique name " << uniqueName << ", abort" << endl ; + return kTRUE ; + } + _dataHist = (RooDataHist*) ws.embeddedData(uniqueName.Data()) ; } + return kFALSE ; } - + // We need to import our datahist into the workspace - Bool_t flag = ws.import(*_dataHist) ; - if (flag) { - coutE(ObjectHandling) << "RooHistPdf::importWorkspaceHook(" << GetName() - << ") error importing RooDataHist into workspace: dataset of different type with same name already exists." << endl ; - return kTRUE ; - } + ws.import(*_dataHist,RooFit::Embedded()) ; // Redirect our internal pointer to the copy in the workspace - _dataHist = (RooDataHist*) ws.data(_dataHist->GetName()) ; + _dataHist = (RooDataHist*) ws.embeddedData(_dataHist->GetName()) ; return kFALSE ; } diff --git a/roofit/roofitcore/src/RooImproperIntegrator1D.cxx b/roofit/roofitcore/src/RooImproperIntegrator1D.cxx index a1c80dd81dcd2..579934169061f 100644 --- a/roofit/roofitcore/src/RooImproperIntegrator1D.cxx +++ b/roofit/roofitcore/src/RooImproperIntegrator1D.cxx @@ -41,6 +41,8 @@ +using namespace std; + ClassImp(RooImproperIntegrator1D) ; diff --git a/roofit/roofitcore/src/RooInt.cxx b/roofit/roofitcore/src/RooInt.cxx index f328cff6b3ae3..667e794928a57 100644 --- a/roofit/roofitcore/src/RooInt.cxx +++ b/roofit/roofitcore/src/RooInt.cxx @@ -27,6 +27,8 @@ #include "RooInt.h" #include "RooInt.h" +using namespace std; + ClassImp(RooInt) ; diff --git a/roofit/roofitcore/src/RooIntegrator1D.cxx b/roofit/roofitcore/src/RooIntegrator1D.cxx index 5d867c5fa5380..167581a6f4904 100644 --- a/roofit/roofitcore/src/RooIntegrator1D.cxx +++ b/roofit/roofitcore/src/RooIntegrator1D.cxx @@ -40,6 +40,8 @@ +using namespace std; + ClassImp(RooIntegrator1D) ; diff --git a/roofit/roofitcore/src/RooIntegrator2D.cxx b/roofit/roofitcore/src/RooIntegrator2D.cxx index 2194639418369..be6d9dac14f15 100644 --- a/roofit/roofitcore/src/RooIntegrator2D.cxx +++ b/roofit/roofitcore/src/RooIntegrator2D.cxx @@ -35,6 +35,8 @@ #include <assert.h> +using namespace std; + ClassImp(RooIntegrator2D) ; diff --git a/roofit/roofitcore/src/RooIntegratorBinding.cxx b/roofit/roofitcore/src/RooIntegratorBinding.cxx index dd3b76805b713..e6922b6fdfccb 100644 --- a/roofit/roofitcore/src/RooIntegratorBinding.cxx +++ b/roofit/roofitcore/src/RooIntegratorBinding.cxx @@ -27,6 +27,8 @@ #include "RooIntegratorBinding.h" #include "RooIntegratorBinding.h" +using namespace std; + ClassImp(RooIntegratorBinding) ; diff --git a/roofit/roofitcore/src/RooInvTransform.cxx b/roofit/roofitcore/src/RooInvTransform.cxx index 40c5f33d5de77..f41a8e1066cf0 100644 --- a/roofit/roofitcore/src/RooInvTransform.cxx +++ b/roofit/roofitcore/src/RooInvTransform.cxx @@ -33,6 +33,8 @@ #include "Riostream.h" #include <math.h> +using namespace std; + ClassImp(RooInvTransform) ; diff --git a/roofit/roofitcore/src/RooLinTransBinning.cxx b/roofit/roofitcore/src/RooLinTransBinning.cxx index 53227b9a0496a..745d4e1eed539 100644 --- a/roofit/roofitcore/src/RooLinTransBinning.cxx +++ b/roofit/roofitcore/src/RooLinTransBinning.cxx @@ -29,6 +29,8 @@ #include "RooLinTransBinning.h" #include "RooLinTransBinning.h" +using namespace std; + ClassImp(RooLinTransBinning) ; diff --git a/roofit/roofitcore/src/RooLinearVar.cxx b/roofit/roofitcore/src/RooLinearVar.cxx index 372490b92ecbf..d40e7ca7593f7 100644 --- a/roofit/roofitcore/src/RooLinearVar.cxx +++ b/roofit/roofitcore/src/RooLinearVar.cxx @@ -57,25 +57,27 @@ +using namespace std; + ClassImp(RooLinearVar) //_____________________________________________________________________________ RooLinearVar::RooLinearVar(const char *name, const char *title, RooAbsRealLValue& variable, - const RooAbsReal& slope, const RooAbsReal& offset, const char *unit) : + const RooAbsReal& slope, const RooAbsReal& offs, const char *unit) : RooAbsRealLValue(name, title, unit), - _binning(variable.getBinning(),slope.getVal(),offset.getVal()), + _binning(variable.getBinning(),slope.getVal(),offs.getVal()), _var("var","variable",this,variable,kTRUE,kTRUE), _slope("slope","slope",this,(RooAbsReal&)slope), - _offset("offset","offset",this,(RooAbsReal&)offset) + _offset("offset","offset",this,(RooAbsReal&)offs) { // Constructor with RooAbsRealLValue variable and RooAbsReal slope and offset // Slope and offset may not depend on variable - if (slope.dependsOnValue(variable) || offset.dependsOnValue(variable)) { + if (slope.dependsOnValue(variable) || offs.dependsOnValue(variable)) { coutE(InputArguments) << "RooLinearVar::RooLinearVar(" << GetName() << "): ERROR, slope(" << slope.GetName() << ") and offset(" - << offset.GetName() << ") may not depend on variable(" + << offs.GetName() << ") may not depend on variable(" << variable.GetName() << ")" << endl ; assert(0) ; } @@ -225,7 +227,7 @@ void RooLinearVar::writeToStream(ostream& os, Bool_t compact) const } // If binning is not found return default binning, if creation is not requested - if (!createOnTheFly) { + if (!_var.arg().hasRange(name) && !createOnTheFly) { return _binning ; } @@ -246,6 +248,22 @@ const RooAbsBinning& RooLinearVar::getBinning(const char* name, Bool_t verbose, return const_cast<RooLinearVar*>(this)->getBinning(name,verbose,createOnTheFly) ; } +//_____________________________________________________________________________ +std::list<std::string> RooLinearVar::getBinningNames() const +{ + // Get a list of all binning names. An empty name implies the default binning. + // A 0 pointer should be passed to getBinning in this case. + std::list<std::string> binningNames(1, ""); + + RooFIter iter = _altBinning.fwdIterator(); + const RooAbsArg* binning = 0; + while((binning = iter.next())) { + const char* name = binning->GetName(); + binningNames.push_back(name); + } + + return binningNames; +} //_____________________________________________________________________________ Bool_t RooLinearVar::hasBinning(const char* name) const diff --git a/roofit/roofitcore/src/RooLinkedList.cxx b/roofit/roofitcore/src/RooLinkedList.cxx index 1b0abb7ff7a4b..fc52578e13b07 100644 --- a/roofit/roofitcore/src/RooLinkedList.cxx +++ b/roofit/roofitcore/src/RooLinkedList.cxx @@ -26,6 +26,8 @@ // END_HTML // +#include <algorithm> + #include "RooFit.h" #include "Riostream.h" @@ -35,94 +37,249 @@ #include "RooAbsArg.h" #include "RooMsgService.h" - - +using namespace std; ClassImp(RooLinkedList) ; +namespace RooLinkedListImplDetails { + /// a chunk of memory in a pool for quick allocation of RooLinkedListElems + class Chunk { + public: + /// constructor + Chunk(Int_t sz) : + _sz(sz), _free(capacity()), + _chunk(new RooLinkedListElem[_free]), _freelist(_chunk) + { + // initialise free list + for (Int_t i = 0; i < _free; ++i) + _chunk[i]._next = (i + 1 < _free) ? &_chunk[i + 1] : 0; + } + /// destructor + ~Chunk() { delete[] _chunk; } + /// chunk capacity + Int_t capacity() const + { return (1 << _sz) / sizeof(RooLinkedListElem); } + /// chunk free elements + Int_t free() const { return _free; } + /// chunk occupied elements + Int_t size() const { return capacity() - free(); } + /// return size class + int szclass() const { return _sz; } + /// chunk full? + bool full() const { return !free(); } + /// chunk empty? + bool empty() const { return capacity() == free(); } + /// return address of chunk + const void* chunkaddr() const { return _chunk; } + /// check if el is in this chunk + bool contains(RooLinkedListElem* el) const + { return _chunk <= el && el < &_chunk[capacity()]; } + /// pop a free element off the free list + RooLinkedListElem* pop_free_elem() + { + if (!_freelist) return 0; + RooLinkedListElem* retVal = _freelist; + _freelist = retVal->_next; + retVal->_arg = 0; retVal->_refCount = 0; + retVal->_prev = retVal->_next = 0; + --_free; + return retVal; + } + /// push a free element back onto the freelist + void push_free_elem(RooLinkedListElem* el) + { + el->_next = _freelist; + _freelist = el; + ++_free; + } + private: + Int_t _sz; ///< chunk capacity + Int_t _free; ///< length of free list + RooLinkedListElem* _chunk; ///< chunk from which elements come + RooLinkedListElem* _freelist; ///< list of free elements + + /// forbid copying + Chunk(const Chunk&); + // forbid assignment + Chunk& operator=(const Chunk&); + }; + + class Pool { + private: + enum { + minsz = 7, ///< minimum chunk size (just below 1 << minsz bytes) + maxsz = 20, ///< maximum chunk size (just below 1 << maxsz bytes) + szincr = 1 ///< size class increment (sz = 1 << (minsz + k * szincr)) + }; + /// a chunk of memory in the pool + typedef RooLinkedListImplDetails::Chunk Chunk; + typedef std::list<Chunk*> ChunkList; + typedef std::map<const void*, Chunk*> AddrMap; + public: + /// constructor + Pool(); + /// destructor + ~Pool(); + /// acquire the pool + inline void acquire() { ++_refCount; } + /// release the pool, return true if the pool is unused + inline bool release() { return 0 == --_refCount; } + /// pop a free element out of the pool + RooLinkedListElem* pop_free_elem(); + /// push a free element back into the pool + void push_free_elem(RooLinkedListElem* el); + private: + AddrMap _addrmap; + ChunkList _freelist; + UInt_t _szmap[(maxsz - minsz) / szincr]; + Int_t _cursz; + UInt_t _refCount; + + /// adjust _cursz to current largest block + void updateCurSz(Int_t sz, Int_t incr); + /// find size of next chunk to allocate (in a hopefully smart way) + Int_t nextChunkSz() const; + }; + + Pool::Pool() : _cursz(minsz), _refCount(0) + { + std::fill(_szmap, _szmap + ((maxsz - minsz) / szincr), 0); + } + + Pool::~Pool() + { + _freelist.clear(); + for (AddrMap::iterator it = _addrmap.begin(); _addrmap.end() != it; ++it) + delete it->second; + _addrmap.clear(); + } + RooLinkedListElem* Pool::pop_free_elem() + { + if (_freelist.empty()) { + // allocate and register new chunk and put it on the freelist + const Int_t sz = nextChunkSz(); + Chunk *c = new Chunk(sz); + _addrmap[c->chunkaddr()] = c; + _freelist.push_back(c); + updateCurSz(sz, +1); + } + // get free element from first chunk on _freelist + Chunk* c = _freelist.front(); + RooLinkedListElem* retVal = c->pop_free_elem(); + // full chunks are removed from _freelist + if (c->full()) _freelist.pop_front(); + return retVal; + } + + void Pool::push_free_elem(RooLinkedListElem* el) + { + // find from which chunk el came + AddrMap::iterator ci = _addrmap.lower_bound(el); + if (!_addrmap.empty() && _addrmap.begin() != ci && ci->first != el) --ci; + // ci should now point to the chunk which might contain el + if (_addrmap.empty() || !ci->second->contains(el)) { + // el is not in any chunk we know about, so just delete it + delete el; + return; + } + Chunk *c = ci->second; + const bool moveToFreelist = c->full(); + c->push_free_elem(el); + if (c->empty()) { + // delete chunk if all empty + ChunkList::iterator it = std::find( _freelist.begin(), _freelist.end(), c); + if (_freelist.end() != it) _freelist.erase(it); + _addrmap.erase(ci->first); + updateCurSz(c->szclass(), -1); + delete c; + } else if (moveToFreelist) { + _freelist.push_back(c); + } + } + + void Pool::updateCurSz(Int_t sz, Int_t incr) + { + _szmap[(sz - minsz) / szincr] += incr; + _cursz = minsz; + for (int i = (maxsz - minsz) / szincr; i--; ) { + if (_szmap[i]) { + _cursz += i * szincr; + break; + } + } + } + + Int_t Pool::nextChunkSz() const + { + // no chunks with space available, figure out chunk size + Int_t sz = _cursz; + if (_addrmap.empty()) { + // if we start allocating chunks, we start from minsz + sz = minsz; + } else { + if (minsz >= sz) { + // minimal sized chunks are always grown + sz = minsz + szincr; + } else { + if (1 != _addrmap.size()) { + // if we have more than one completely filled chunk, grow + sz += szincr; + } else { + // just one chunk left, try shrinking chunk size + sz -= szincr; + } + } + } + // clamp size to allowed range + if (sz > maxsz) sz = maxsz; + if (sz < minsz) sz = minsz; + return sz; + } +} + +RooLinkedList::Pool* RooLinkedList::_pool = 0; //_____________________________________________________________________________ RooLinkedList::RooLinkedList(Int_t htsize) : - _hashThresh(htsize), _size(0), _first(0), _last(0), _htableName(0), _htableLink(0), _curStoreSize(2), _curStoreUsed(0) + _hashThresh(htsize), _size(0), _first(0), _last(0), _htableName(0), _htableLink(0), _useNptr(kFALSE) { - _curStore = new RooLinkedListElem[_curStoreSize] ; - _storeList.push_back(pair<Int_t,RooLinkedListElem*>(0,_curStore)) ; + if (!_pool) _pool = new Pool; + _pool->acquire(); } - - - //_____________________________________________________________________________ RooLinkedList::RooLinkedList(const RooLinkedList& other) : TObject(other), _hashThresh(other._hashThresh), _size(0), _first(0), _last(0), _htableName(0), _htableLink(0), - _curStoreSize(2), _curStoreUsed(0), _name(other._name) + _name(other._name), _useNptr(other._useNptr) { // Copy constructor - - _curStore = new RooLinkedListElem[other.GetSize()] ; - _curStoreSize = other.GetSize() ; - _storeList.push_back(pair<Int_t,RooLinkedListElem*>(0,_curStore)) ; - + if (!_pool) _pool = new Pool; + _pool->acquire(); if (other._htableName) _htableName = new RooHashTable(other._htableName->size()) ; if (other._htableLink) _htableLink = new RooHashTable(other._htableLink->size(),RooHashTable::Pointer) ; - RooLinkedListElem* elem = other._first ; - while(elem) { + for (RooLinkedListElem* elem = other._first; elem; elem = elem->_next) { Add(elem->_arg, elem->_refCount) ; - elem = elem->_next ; } - - _curStore = new RooLinkedListElem[2] ; - _storeList.push_back(pair<Int_t,RooLinkedListElem*>(0,_curStore)) ; - _curStoreSize = 2 ; - _curStoreUsed = 0 ; - } - - //_____________________________________________________________________________ RooLinkedListElem* RooLinkedList::createElement(TObject* obj, RooLinkedListElem* elem) { // cout << "RooLinkedList::createElem(" << this << ") obj = " << obj << " elem = " << elem << endl ; - - if (_curStoreUsed==_curStoreSize) { - - // Remove empty stores ; - Bool_t anyDel(kFALSE) ; - for (list<pair<Int_t,RooLinkedListElem*> >::iterator iter = _storeList.begin() ; iter != _storeList.end() ; ++iter) { - if (iter->first==0) { - anyDel = kTRUE ; - delete[] iter->second ; - iter = _storeList.erase(iter) ; - } - } - - if (!anyDel) { - _curStoreSize *= 2 ; - } - _curStore = new RooLinkedListElem[_curStoreSize] ; - _storeList.push_back(pair<Int_t,RooLinkedListElem*>(0,_curStore)) ; - _curStoreUsed = 0 ; - } - - RooLinkedListElem* ret = _curStore+_curStoreUsed ; -// cout << "initializing slot " << _curStoreUsed << " of store " << _curStore << " = " << ret << endl ; - ret->init(obj,elem,&(_storeList.back().first)) ; - _curStoreUsed++ ; + RooLinkedListElem* ret = _pool->pop_free_elem(); + ret->init(obj, elem); return ret ; } - //_____________________________________________________________________________ void RooLinkedList::deleteElement(RooLinkedListElem* elem) { elem->release() ; + _pool->push_free_elem(elem); //delete elem ; } - - //_____________________________________________________________________________ RooLinkedList& RooLinkedList::operator=(const RooLinkedList& other) { @@ -131,18 +288,16 @@ RooLinkedList& RooLinkedList::operator=(const RooLinkedList& other) // Prevent self-assignment if (&other==this) return *this ; + // remove old elements + Clear(); // Copy elements - RooLinkedListElem* elem = other._first ; - while(elem) { + for (RooLinkedListElem* elem = other._first; elem; elem = elem->_next) { Add(elem->_arg) ; - elem = elem->_next ; } return *this ; } - - //_____________________________________________________________________________ void RooLinkedList::setHashTableSize(Int_t size) { @@ -183,9 +338,6 @@ void RooLinkedList::setHashTableSize(Int_t size) } } - - - //_____________________________________________________________________________ RooLinkedList::~RooLinkedList() { @@ -201,17 +353,12 @@ RooLinkedList::~RooLinkedList() } Clear() ; - - // Delete store - Int_t i=0 ; - for (list<pair<Int_t,RooLinkedListElem*> >::iterator iter=_storeList.begin() ; iter!=_storeList.end() ; ++iter) { - delete[] iter->second ; - i++ ; + if (_pool->release()) { + delete _pool; + _pool = 0; } } - - //_____________________________________________________________________________ RooLinkedListElem* RooLinkedList::findLink(const TObject* arg) const { @@ -232,8 +379,6 @@ RooLinkedListElem* RooLinkedList::findLink(const TObject* arg) const } - - //_____________________________________________________________________________ void RooLinkedList::Add(TObject* arg, Int_t refCount) { @@ -274,9 +419,6 @@ void RooLinkedList::Add(TObject* arg, Int_t refCount) } - - - //_____________________________________________________________________________ Bool_t RooLinkedList::Remove(TObject* arg) { @@ -304,9 +446,6 @@ Bool_t RooLinkedList::Remove(TObject* arg) return kTRUE ; } - - - //_____________________________________________________________________________ TObject* RooLinkedList::At(Int_t index) const { @@ -325,9 +464,6 @@ TObject* RooLinkedList::At(Int_t index) const return ptr->_arg ; } - - - //_____________________________________________________________________________ Bool_t RooLinkedList::Replace(const TObject* oldArg, const TObject* newArg) { @@ -351,8 +487,6 @@ Bool_t RooLinkedList::Replace(const TObject* oldArg, const TObject* newArg) return kTRUE ; } - - //_____________________________________________________________________________ TObject* RooLinkedList::FindObject(const char* name) const { @@ -362,8 +496,6 @@ TObject* RooLinkedList::FindObject(const char* name) const return find(name) ; } - - //_____________________________________________________________________________ TObject* RooLinkedList::FindObject(const TObject* obj) const { @@ -374,18 +506,14 @@ TObject* RooLinkedList::FindObject(const TObject* obj) const return elem ? elem->_arg : 0 ; } - - //_____________________________________________________________________________ void RooLinkedList::Clear(Option_t *) { // Remove all elements from collection - RooLinkedListElem* elem = _first; - while(elem) { - RooLinkedListElem* next = elem->_next ; + for (RooLinkedListElem *elem = _first, *next; elem; elem = next) { + next = elem->_next ; deleteElement(elem) ; - elem = next ; } _first = 0 ; _last = 0 ; @@ -403,8 +531,6 @@ void RooLinkedList::Clear(Option_t *) } } - - //_____________________________________________________________________________ void RooLinkedList::Delete(Option_t *) { @@ -435,20 +561,31 @@ void RooLinkedList::Delete(Option_t *) } } - - - //_____________________________________________________________________________ TObject* RooLinkedList::find(const char* name) const { // Return pointer to object with given name in collection. // If no such object is found, return null pointer. + if (_htableName) return _htableName->find(name) ; RooLinkedListElem* ptr = _first ; + + if (_useNptr) { + const TNamed* nptr = RooNameReg::instance().constPtr(name) ; + + while(ptr) { + if ((((RooAbsArg*)ptr->_arg)->namePtr() == nptr)) { + return ptr->_arg ; + } + ptr = ptr->_next ; + } + return 0 ; + } + while(ptr) { - if (!strcmp(ptr->_arg->GetName(),name)) { + if (!strcmp(ptr->_arg->GetName(),name)) { return ptr->_arg ; } ptr = ptr->_next ; @@ -456,8 +593,6 @@ TObject* RooLinkedList::find(const char* name) const return 0 ; } - - //_____________________________________________________________________________ RooAbsArg* RooLinkedList::findArg(const RooAbsArg* arg) const { @@ -478,8 +613,6 @@ RooAbsArg* RooLinkedList::findArg(const RooAbsArg* arg) const return 0 ; } - - //_____________________________________________________________________________ Int_t RooLinkedList::IndexOf(const TObject* arg) const { @@ -496,8 +629,6 @@ Int_t RooLinkedList::IndexOf(const TObject* arg) const return -1 ; } - - //_____________________________________________________________________________ Int_t RooLinkedList::IndexOf(const char* name) const { @@ -514,8 +645,6 @@ Int_t RooLinkedList::IndexOf(const char* name) const return -1 ; } - - //_____________________________________________________________________________ void RooLinkedList::Print(const char* opt) const { @@ -529,21 +658,18 @@ void RooLinkedList::Print(const char* opt) const } } - //_____________________________________________________________________________ RooLinkedListIter RooLinkedList::iterator(Bool_t dir) const { return RooLinkedListIter(this,dir) ; } - //_____________________________________________________________________________ RooFIter RooLinkedList::fwdIterator() const { return RooFIter(this) ; } - //_____________________________________________________________________________ TIterator* RooLinkedList::MakeIterator(Bool_t dir) const { @@ -551,67 +677,117 @@ TIterator* RooLinkedList::MakeIterator(Bool_t dir) const return new RooLinkedListIter(this,dir) ; } - - - //_____________________________________________________________________________ void RooLinkedList::Sort(Bool_t ascend) { - // Sort elements of this list according to their - // TObject::Compare() ranking via a simple - // bubble sort algorithm - - if (_size<2) return ; - - Bool_t working(kTRUE) ; - while(working) { - working = kFALSE ; - RooLinkedListElem* ptr = _first; - while(ptr && ptr->_next) { - if ((ascend && ptr->_arg->Compare(ptr->_next->_arg)>0) || - (!ascend && ptr->_arg->Compare(ptr->_next->_arg)<0)) { - swapWithNext(ptr) ; - working = kTRUE ; - } - ptr = ptr->_next ; - } - } - - return ; + if (ascend) _first = mergesort_impl<true>(_first, _size, &_last); + else _first = mergesort_impl<false>(_first, _size, &_last); } - - //_____________________________________________________________________________ -void RooLinkedList::swapWithNext(RooLinkedListElem* elemB) +template <bool ascending> +RooLinkedListElem* RooLinkedList::mergesort_impl( + RooLinkedListElem* l1, const unsigned sz, RooLinkedListElem** tail) { - // Swap given to elements in the linked list. Auxiliary function for Sort() - - RooLinkedListElem* elemA = elemB->_prev ; - RooLinkedListElem* elemC = elemB->_next ; - if (!elemC) return ; - - RooLinkedListElem* elemD = elemC->_next ; - - if (elemA) { - elemA->_next = elemC ; - } else { - _first = elemC ; - } - elemB->_prev = elemC ; - elemB->_next = elemD ; - elemC->_prev = elemA ; - elemC->_next = elemB ; - if (elemD) { - elemD->_prev = elemB ; - } else { - _last = elemB ; + // length 0, 1 lists are sorted + if (!l1 || sz < 2) { + // if desired, update the tail of the (newly merged sorted) list + if (tail) *tail = l1; + return l1; + } + if (sz <= 16) { + // for short lists, we sort in an array +#if !defined(_WIN32) && !defined(R__SOLARIS_CC50) + RooLinkedListElem *arr[sz]; +#else // _WIN32 && Solaris + // apparently, MSVC is not clever enough to figure out that sz cannot be + // zero and is at most sixteen, so we allocate a fixed size array on the + // stack instead + RooLinkedListElem *arr[16]; +#endif // _WIN32 + for (int i = 0; l1; l1 = l1->_next, ++i) arr[i] = l1; + // straight insertion sort + { + int i = 1; + do { + int j = i - 1; + RooLinkedListElem *tmp = arr[i]; + while (0 <= j) { + const bool inOrder = ascending ? + (tmp->_arg->Compare(arr[j]->_arg) <= 0) : + (arr[j]->_arg->Compare(tmp->_arg) <= 0); + if (!inOrder) break; + arr[j + 1] = arr[j]; + --j; + } + arr[j + 1] = tmp; + ++i; + } while (int(sz) != i); + } + // link elements in array + arr[0]->_prev = arr[sz - 1]->_next = 0; + for (int i = 0; i < int(sz - 1); ++i) { + arr[i]->_next = arr[i + 1]; + arr[i + 1]->_prev = arr[i]; + } + if (tail) *tail = arr[sz - 1]; + return arr[0]; + } + // find middle of l1, and let a second list l2 start there + RooLinkedListElem *l2 = l1; + for (RooLinkedListElem *end = l2; end->_next; end = end->_next) { + end = end->_next; + l2 = l2->_next; + if (!end->_next) break; + } + // disconnect the two sublists + l2->_prev->_next = 0; + l2->_prev = 0; + // sort the two sublists (only recurse if we have to) + if (l1->_next) l1 = mergesort_impl<ascending>(l1, sz / 2); + if (l2->_next) l2 = mergesort_impl<ascending>(l2, sz - sz / 2); + // merge the two (sorted) sublists + // l: list head, t: list tail of merged list + RooLinkedListElem *l = (ascending ? (l1->_arg->Compare(l2->_arg) <= 0) : + (l2->_arg->Compare(l1->_arg) <= 0)) ? l1 : l2; + RooLinkedListElem *t = l; + if (l == l2) { + RooLinkedListElem* tmp = l1; + l1 = l2; + l2 = tmp; + } + l1 = l1->_next; + while (l1 && l2) { + const bool inOrder = ascending ? (l1->_arg->Compare(l2->_arg) <= 0) : + (l2->_arg->Compare(l1->_arg) <= 0); + if (!inOrder) { + // insert l2 just before l1 + if (l1->_prev) { + l1->_prev->_next = l2; + l2->_prev = l1->_prev; + } + // swap l2 and l1 + RooLinkedListElem *tmp = l1; + l1 = l2; + l2 = tmp; + } + // move forward in l1 + t = l1; + l1 = l1->_next; } - return ; + // attach l2 at t + if (l2) { + l2->_prev = t; + if (t) t->_next = l2; + } + // if desired, update the tail of the (newly merged sorted) list + if (tail) { + for (l1 = t; l1; l1 = l1->_next) t = l1; + *tail = t; + } + // return the head of the sorted list + return l; } - - - // void Roo1DTable::Streamer(TBuffer &R__b) // { // // Stream an object of class Roo1DTable. @@ -623,8 +799,6 @@ void RooLinkedList::swapWithNext(RooLinkedListElem* elemB) // } // } - - //_____________________________________________________________________________ void RooLinkedList::Streamer(TBuffer &R__b) { @@ -663,3 +837,4 @@ void RooLinkedList::Streamer(TBuffer &R__b) R__b << _name ; } } + diff --git a/roofit/roofitcore/src/RooLinkedListElem.cxx b/roofit/roofitcore/src/RooLinkedListElem.cxx index e3ca004087487..cfee9f519d13d 100644 --- a/roofit/roofitcore/src/RooLinkedListElem.cxx +++ b/roofit/roofitcore/src/RooLinkedListElem.cxx @@ -28,6 +28,8 @@ #include "RooLinkedListElem.h" +using namespace std; + ClassImp(RooLinkedListElem) ; diff --git a/roofit/roofitcore/src/RooLinkedListIter.cxx b/roofit/roofitcore/src/RooLinkedListIter.cxx index 4dd7119f53276..0511d5f77d32f 100644 --- a/roofit/roofitcore/src/RooLinkedListIter.cxx +++ b/roofit/roofitcore/src/RooLinkedListIter.cxx @@ -26,6 +26,8 @@ #include "RooLinkedListIter.h" #include "RooLinkedListIter.h" +using namespace std; + ClassImp(RooLinkedListIter) ; diff --git a/roofit/roofitcore/src/RooList.cxx b/roofit/roofitcore/src/RooList.cxx index f9749344093ff..eb6a5efc550db 100644 --- a/roofit/roofitcore/src/RooList.cxx +++ b/roofit/roofitcore/src/RooList.cxx @@ -30,6 +30,8 @@ #include "Riostream.h" +using namespace std; + ClassImp(RooList) diff --git a/roofit/roofitcore/src/RooListProxy.cxx b/roofit/roofitcore/src/RooListProxy.cxx index 4bb41ced23a4f..758b163f73714 100644 --- a/roofit/roofitcore/src/RooListProxy.cxx +++ b/roofit/roofitcore/src/RooListProxy.cxx @@ -35,6 +35,8 @@ #include "RooArgList.h" #include "RooAbsArg.h" +using namespace std; + ClassImp(RooListProxy) ; @@ -91,7 +93,7 @@ Bool_t RooListProxy::add(const RooAbsArg& var, Bool_t valueServer, Bool_t shapeS // of inserted object to list owner Bool_t ret=RooArgList::add(var,silent) ; - if (ret) { + if (ret && _owner) { _owner->addServer((RooAbsArg&)var,valueServer,shapeServer) ; } return ret ; @@ -194,7 +196,9 @@ Bool_t RooListProxy::changePointer(const RooAbsCollection& newServerList, Bool_t TIterator* iter = newServerList.createIterator() ; RooAbsArg* arg ; while((arg=(RooAbsArg*)iter->Next())) { - add(*arg,kTRUE) ; + if (arg!=_owner) { + add(*arg,kTRUE) ; + } } delete iter ; } else { @@ -207,7 +211,7 @@ Bool_t RooListProxy::changePointer(const RooAbsCollection& newServerList, Bool_t while ((arg=(RooAbsArg*)_iter->Next())) { RooAbsArg* newArg= arg->findNewServer(newServerList, nameChange); - if (newArg) error |= !RooArgList::replace(*arg,*newArg) ; + if (newArg && newArg!=_owner) error |= !RooArgList::replace(*arg,*newArg) ; } return !error ; } diff --git a/roofit/roofitcore/src/RooMCIntegrator.cxx b/roofit/roofitcore/src/RooMCIntegrator.cxx index 569f8dd80106a..8c9d75e98fcf1 100644 --- a/roofit/roofitcore/src/RooMCIntegrator.cxx +++ b/roofit/roofitcore/src/RooMCIntegrator.cxx @@ -43,6 +43,8 @@ +using namespace std; + ClassImp(RooMCIntegrator) ; diff --git a/roofit/roofitcore/src/RooMCStudy.cxx b/roofit/roofitcore/src/RooMCStudy.cxx index 9881ba18862fb..36a592efe022c 100644 --- a/roofit/roofitcore/src/RooMCStudy.cxx +++ b/roofit/roofitcore/src/RooMCStudy.cxx @@ -202,7 +202,7 @@ RooMCStudy::RooMCStudy(const RooAbsPdf& model, const RooArgSet& observables, _perExptGenParams = kTRUE ; - coutI(Generation) << "RooMCStudy::RooMCStudy: INFO have pdf with constraints, will generate paramaters from constraint pdf for each experiment" << endl ; + coutI(Generation) << "RooMCStudy::RooMCStudy: INFO have pdf with constraints, will generate parameters from constraint pdf for each experiment" << endl ; } else { diff --git a/roofit/roofitcore/src/RooMPSentinel.cxx b/roofit/roofitcore/src/RooMPSentinel.cxx index c16a6afef57bb..e1d54df8dbc16 100644 --- a/roofit/roofitcore/src/RooMPSentinel.cxx +++ b/roofit/roofitcore/src/RooMPSentinel.cxx @@ -31,6 +31,8 @@ #include "RooMPSentinel.h" #include "RooRealMPFE.h" +using namespace std; + ClassImp(RooMPSentinel) ; diff --git a/roofit/roofitcore/src/RooMapCatEntry.cxx b/roofit/roofitcore/src/RooMapCatEntry.cxx index 3c0838d0d5d8a..a41703628dcfb 100644 --- a/roofit/roofitcore/src/RooMapCatEntry.cxx +++ b/roofit/roofitcore/src/RooMapCatEntry.cxx @@ -26,6 +26,8 @@ #include "RooMapCatEntry.h" #include "TString.h" +using namespace std; + ClassImp(RooMapCatEntry) ; diff --git a/roofit/roofitcore/src/RooMath.cxx b/roofit/roofitcore/src/RooMath.cxx index c58e8e1830994..21c6c729dfeeb 100644 --- a/roofit/roofitcore/src/RooMath.cxx +++ b/roofit/roofitcore/src/RooMath.cxx @@ -20,313 +20,575 @@ // // +#include <complex> +#include <cmath> +#include <algorithm> + #include "RooFit.h" #include "RooMath.h" -#include "RooMath.h" -#include "TMath.h" -#include <math.h> #include "Riostream.h" #include "RooMsgService.h" -#include "RooSentinel.h" -#include "TSystem.h" + +using namespace std; ClassImp(RooMath) ; -RooComplex RooMath::FastComplexErrFunc(const RooComplex& z) -{ - return ITPComplexErrFunc(z,z.im()>0?3:4) ; -} - -Double_t RooMath::FastComplexErrFuncRe(const RooComplex& z) -{ - return ITPComplexErrFuncRe(z,z.im()>0?3:4) ; -} - -Double_t RooMath::FastComplexErrFuncIm(const RooComplex& z) -{ - return ITPComplexErrFuncIm(z,z.im()>0?3:4) ; -} - -void RooMath::cacheCERF(Bool_t flag) -{ - _cacheTable = flag ; -} - - -RooComplex RooMath::ComplexErrFunc(Double_t re, Double_t im) { - // Return CERNlib complex error function for Z(re,im) - return ComplexErrFunc(RooComplex(re,im)); -} - -RooComplex RooMath::ComplexErrFunc(const RooComplex& Z) { - // Return CERNlib complex error function - // - // This code is translated from the fortran version in the CERN mathlib. - // (see ftp://asisftp.cern.ch/cernlib/share/pro/src/mathlib/gen/c/cwerf64.F) - - RooComplex ZH,S,T,V; - static RooComplex R[38]; - - static const Double_t Z1= 1, HF= Z1/2, Z10= 10; - static const Double_t C1= 74/Z10, C2= 83/Z10, C3= Z10/32, C4 = 16/Z10; - static const Double_t C = 1.12837916709551257, P = pow(2*C4,33); - static const RooComplex zero(0); - - Double_t X(Z.re()),Y(Z.im()), XA(fabs(X)), YA(fabs(Y)); - int N; - if((YA < C1) && (XA < C2)) { - ZH= RooComplex(YA+C4,XA); - R[37]=zero; - N= 36; - while(N > 0) { - T=ZH+R[N+1].conj()*N; - R[N--]=(T*HF)/T.abs2(); - } - Double_t XL=P; - S=zero; - N= 33; - while(N > 0) { - XL=C3*XL; - S=R[N--]*(S+XL); +namespace faddeeva_impl { + static inline void cexp(double& re, double& im) + { + // with gcc on unix machines and on x86_64, we can gain by hand-coding + // exp(z) for the x87 coprocessor; other platforms have the default + // routines as fallback implementation, and compilers other than gcc on + // x86_64 generate better code with the default routines; also avoid + // the inline assembly code when the copiler is not optimising code, or + // is optimising for code size + // (we insist on __unix__ here, since the assemblers on other OSs + // typically do not speak AT&T syntax as gas does...) +#if !defined(__GNUC__) || !defined(__unix__) || !defined(__x86_64__) || \ + !defined(__OPTIMIZE__) || defined(__OPTIMIZE_SIZE__) || \ + defined(__INTEL_COMPILER) || defined(__clang__) || \ + defined(__OPEN64__) || defined(__PATHSCALE__) + const double e = std::exp(re); + re = e * std::cos(im); + im = e * std::sin(im); +#else + __asm__ ( + "fxam\n\t" // examine st(0): NaN? Inf? + "fstsw %%ax\n\t" + "movb $0x45,%%dh\n\t" + "andb %%ah,%%dh\n\t" + "cmpb $0x05,%%dh\n\t" + "jz 1f\n\t" // have NaN or infinity, handle below + "fldl2e\n\t" // load log2(e) + "fmulp\n\t" // re * log2(e) + "fld %%st(0)\n\t" // duplicate re * log2(e) + "frndint\n\t" // int(re * log2(e)) + "fsubr %%st,%%st(1)\n\t" // st(1) = x = frac(re * log2(e)) + "fxch\n\t" // swap st(0), st(1) + "f2xm1\n\t" // 2^x - 1 + "fld1\n\t" // st(0) = 1 + "faddp\n\t" // st(0) = 2^x + "fscale\n\t" // 2 ^ (int(re * log2(e)) + x) + "fstp %%st(1)\n\t" // pop st(1) + "jmp 2f\n\t" + "1:\n\t" // handle NaN, Inf... + "testl $0x200, %%eax\n\t"// -infinity? + "jz 2f\n\t" + "fstp %%st\n\t" // -Inf, so pop st(0) + "fldz\n\t" // st(0) = 0 + "2:\n\t" // here. we have st(0) == exp(re) + "fxch\n\t" // st(0) = im, st(1) = exp(re) + "fsincos\n\t" // st(0) = cos(im), st(1) = sin(im) + "fnstsw %%ax\n\t" + "testl $0x400,%%eax\n\t" + "jz 4f\n\t" // |im| too large for fsincos? + "fldpi\n\t" // st(0) = pi + "fadd %%st(0)\n\t" // st(0) *= 2; + "fxch %%st(1)\n\t" // st(0) = im, st(1) = 2 * pi + "3:\n\t" + "fprem1\n\t" // st(0) = fmod(im, 2 * pi) + "fnstsw %%ax\n\t" + "testl $0x400,%%eax\n\t" + "jnz 3b\n\t" // fmod done? + "fstp %%st(1)\n\t" // yes, pop st(1) == 2 * pi + "fsincos\n\t" // st(0) = cos(im), st(1) = sin(im) + "4:\n\t" // all fine, fsincos succeeded + "fmul %%st(2)\n\t" // st(0) *= st(2) + "fxch %%st(2)\n\t" // st(2)=exp(re)*cos(im),st(0)=exp(im) + "fmulp %%st(1)\n\t" // st(1)=exp(re)*sin(im), pop st(0) + : "=t" (im), "=u" (re): "0" (re), "1" (im) : + "eax", "dh", "cc", "st(5)", "st(6)", "st(7)"); +#endif } - V=S*C; - } - else { - ZH=RooComplex(YA,XA); - R[1]=zero; - N= 9; - while(N > 0) { - T=ZH+R[1].conj()*N; - R[1]=(T*HF)/T.abs2(); - N--; + + template <class T, unsigned N, unsigned NTAYLOR, unsigned NCF> + static inline std::complex<T> faddeeva_smabmq_impl( + T zre, T zim, const T tm, + const T (&a)[N], const T (&npi)[N], + const T (&taylorarr)[N * NTAYLOR * 2]) + { + // catch singularities in the Fourier representation At + // z = n pi / tm, and provide a Taylor series expansion in those + // points, and only use it when we're close enough to the real axis + // that there is a chance we need it + const T zim2 = zim * zim; + const T maxnorm = T(9) / T(1000000); + if (zim2 < maxnorm) { + // we're close enough to the real axis that we need to worry about + // singularities + const T dnsing = tm * zre / npi[1]; + const T dnsingmax2 = (T(N) - T(1) / T(2)) * (T(N) - T(1) / T(2)); + if (dnsing * dnsing < dnsingmax2) { + // we're in the interesting range of the real axis as well... + // deal with Re(z) < 0 so we only need N different Taylor + // expansions; use w(-x+iy) = conj(w(x+iy)) + const bool negrez = zre < T(0); + // figure out closest singularity + const int nsing = int(std::abs(dnsing) + T(1) / T(2)); + // and calculate just how far we are from it + const T zmnpire = std::abs(zre) - npi[nsing]; + const T zmnpinorm = zmnpire * zmnpire + zim2; + // close enough to one of the singularities? + if (zmnpinorm < maxnorm) { + const T* coeffs = &taylorarr[nsing * NTAYLOR * 2]; + // calculate value of taylor expansion... + // (note: there's no chance to vectorize this one, since + // the value of the next iteration depend on the ones from + // the previous iteration) + T sumre = coeffs[0], sumim = coeffs[1]; + for (unsigned i = 1; i < NTAYLOR; ++i) { + const T re = sumre * zmnpire - sumim * zim; + const T im = sumim * zmnpire + sumre * zim; + sumre = re + coeffs[2 * i + 0]; + sumim = im + coeffs[2 * i + 1]; + } + // undo the flip in real part of z if needed + if (negrez) return std::complex<T>(sumre, -sumim); + else return std::complex<T>(sumre, sumim); + } + } + } + // negative Im(z) is treated by calculating for -z, and using the + // symmetry properties of erfc(z) + const bool negimz = zim < T(0); + if (negimz) { + zre = -zre; + zim = -zim; + } + const T znorm = zre * zre + zim2; + if (znorm > tm * tm) { + // use continued fraction approximation for |z| large + const T isqrtpi = 5.64189583547756287e-01; + const T z2re = (zre + zim) * (zre - zim); + const T z2im = T(2) * zre * zim; + T cfre = T(1), cfim = T(0), cfnorm = T(1); + for (unsigned k = NCF; k; --k) { + cfre = +(T(k) / T(2)) * cfre / cfnorm; + cfim = -(T(k) / T(2)) * cfim / cfnorm; + if (k & 1) cfre -= z2re, cfim -= z2im; + else cfre += T(1); + cfnorm = cfre * cfre + cfim * cfim; + } + T sumre = (zim * cfre - zre * cfim) * isqrtpi / cfnorm; + T sumim = -(zre * cfre + zim * cfim) * isqrtpi / cfnorm; + if (negimz) { + // use erfc(-z) = 2 - erfc(z) to get good accuracy for + // Im(z) < 0: 2 / exp(z^2) - w(z) + T ez2re = -z2re, ez2im = -z2im; + faddeeva_impl::cexp(ez2re, ez2im); + return std::complex<T>(T(2) * ez2re - sumre, + T(2) * ez2im - sumim); + } else { + return std::complex<T>(sumre, sumim); + } + } + const T twosqrtpi = 3.54490770181103205e+00; + const T tmzre = tm * zre, tmzim = tm * zim; + // calculate exp(i tm z) + T eitmzre = -tmzim, eitmzim = tmzre; + faddeeva_impl::cexp(eitmzre, eitmzim); + // form 1 +/- exp (i tm z) + const T numerarr[4] = { + T(1) - eitmzre, -eitmzim, T(1) + eitmzre, +eitmzim + }; + // form tm z * (1 +/- exp(i tm z)) + const T numertmz[4] = { + tmzre * numerarr[0] - tmzim * numerarr[1], + tmzre * numerarr[1] + tmzim * numerarr[0], + tmzre * numerarr[2] - tmzim * numerarr[3], + tmzre * numerarr[3] + tmzim * numerarr[2] + }; + // common subexpressions for use inside the loop + const T reimtmzm2 = T(-2) * tmzre * tmzim; + const T imtmz2 = tmzim * tmzim; + const T reimtmzm22 = reimtmzm2 * reimtmzm2; + // on non-x86_64 architectures, when the compiler is producing + // unoptimised code and when optimising for code size, we use the + // straightforward implementation, but for x86_64, we use the + // brainf*cked code below that the gcc vectorizer likes to gain a few + // clock cycles; non-gcc compilers also get the normal code, since they + // usually do a better job with the default code (and yes, it's a pain + // that they're all pretending to be gcc) +#if (!defined(__x86_64__)) || !defined(__OPTIMIZE__) || \ + defined(__OPTIMIZE_SIZE__) || defined(__INTEL_COMPILER) || \ + defined(__clang__) || defined(__OPEN64__) || \ + defined(__PATHSCALE__) || !defined(__GNUC__) + T sumre = (-a[0] / znorm) * (numerarr[0] * zre + numerarr[1] * zim); + T sumim = (-a[0] / znorm) * (numerarr[1] * zre - numerarr[0] * zim); + for (unsigned i = 0; i < N; ++i) { + const unsigned j = (i << 1) & 2; + // denominator + const T wk = imtmz2 + (npi[i] + tmzre) * (npi[i] - tmzre); + // norm of denominator + const T norm = wk * wk + reimtmzm22; + const T f = T(2) * tm * a[i] / norm; + // sum += a[i] * numer / wk + sumre -= f * (numertmz[j] * wk + numertmz[j + 1] * reimtmzm2); + sumim -= f * (numertmz[j + 1] * wk - numertmz[j] * reimtmzm2); + } +#else + // BEGIN fully vectorisable code - enjoy reading... ;) + T tmp[2 * N]; + for (unsigned i = 0; i < N; ++i) { + const T wk = imtmz2 + (npi[i] + tmzre) * (npi[i] - tmzre); + tmp[2 * i + 0] = wk; + tmp[2 * i + 1] = T(2) * tm * a[i] / (wk * wk + reimtmzm22); + } + for (unsigned i = 0; i < N / 2; ++i) { + T wk = tmp[4 * i + 0], f = tmp[4 * i + 1]; + tmp[4 * i + 0] = -f * (numertmz[0] * wk + numertmz[1] * reimtmzm2); + tmp[4 * i + 1] = -f * (numertmz[1] * wk - numertmz[0] * reimtmzm2); + wk = tmp[4 * i + 2], f = tmp[4 * i + 3]; + tmp[4 * i + 2] = -f * (numertmz[2] * wk + numertmz[3] * reimtmzm2); + tmp[4 * i + 3] = -f * (numertmz[3] * wk - numertmz[2] * reimtmzm2); + } + if (N & 1) { + // we may have missed one element in the last loop; if so, process + // it now... + const T wk = tmp[2 * N - 2], f = tmp[2 * N - 1]; + tmp[2 * (N - 1) + 0] = -f * (numertmz[0] * wk + numertmz[1] * reimtmzm2); + tmp[2 * (N - 1) + 1] = -f * (numertmz[1] * wk - numertmz[0] * reimtmzm2); + } + T sumre = (-a[0] / znorm) * (numerarr[0] * zre + numerarr[1] * zim); + T sumim = (-a[0] / znorm) * (numerarr[1] * zre - numerarr[0] * zim); + for (unsigned i = 0; i < N; ++i) { + sumre += tmp[2 * i + 0]; + sumim += tmp[2 * i + 1]; + } + // END fully vectorisable code +#endif + // prepare the result + if (negimz) { + // use erfc(-z) = 2 - erfc(z) to get good accuracy for + // Im(z) < 0: 2 / exp(z^2) - w(z) + const T z2im = -T(2) * zre * zim; + const T z2re = -(zre + zim) * (zre - zim); + T ez2re = z2re, ez2im = z2im; + faddeeva_impl::cexp(ez2re, ez2im); + return std::complex<T>(T(2) * ez2re + sumim / twosqrtpi, + T(2) * ez2im - sumre / twosqrtpi); + } else { + return std::complex<T>(-sumim / twosqrtpi, sumre / twosqrtpi); + } } - V=R[1]*C; - } - if(YA==0) V=RooComplex(exp(-(XA*XA)),V.im()); - if(Y < 0) { - RooComplex tmp(XA,YA); - tmp= -tmp*tmp; - V=tmp.exp()*2-V; - if(X > 0) V= V.conj(); - } - else { - if(X < 0) V= V.conj(); - } - return V; + static const double npi24[24] = { // precomputed values n * pi + 0.00000000000000000e+00, 3.14159265358979324e+00, 6.28318530717958648e+00, + 9.42477796076937972e+00, 1.25663706143591730e+01, 1.57079632679489662e+01, + 1.88495559215387594e+01, 2.19911485751285527e+01, 2.51327412287183459e+01, + 2.82743338823081391e+01, 3.14159265358979324e+01, 3.45575191894877256e+01, + 3.76991118430775189e+01, 4.08407044966673121e+01, 4.39822971502571053e+01, + 4.71238898038468986e+01, 5.02654824574366918e+01, 5.34070751110264851e+01, + 5.65486677646162783e+01, 5.96902604182060715e+01, 6.28318530717958648e+01, + 6.59734457253856580e+01, 6.91150383789754512e+01, 7.22566310325652445e+01, + }; + static const double a24[24] = { // precomputed Fourier coefficient prefactors + 2.95408975150919338e-01, 2.75840233292177084e-01, 2.24573955224615866e-01, + 1.59414938273911723e-01, 9.86657664154541891e-02, 5.32441407876394120e-02, + 2.50521500053936484e-02, 1.02774656705395362e-02, 3.67616433284484706e-03, + 1.14649364124223317e-03, 3.11757015046197600e-04, 7.39143342960301488e-05, + 1.52794934280083635e-05, 2.75395660822107093e-06, 4.32785878190124505e-07, + 5.93003040874588103e-08, 7.08449030774820423e-09, 7.37952063581678038e-10, + 6.70217160600200763e-11, 5.30726516347079017e-12, 3.66432411346763916e-13, + 2.20589494494103134e-14, 1.15782686262855879e-15, 5.29871142946730482e-17, + }; + static const double taylorarr24[24 * 12] = { + // real part imaginary part, low order coefficients last + // nsing = 0 + 0.00000000000000000e-00, 3.00901111225470020e-01, + 5.00000000000000000e-01, 0.00000000000000000e-00, + 0.00000000000000000e-00, -7.52252778063675049e-01, + -1.00000000000000000e-00, 0.00000000000000000e-00, + 0.00000000000000000e-00, 1.12837916709551257e+00, + 1.00000000000000000e-00, 0.00000000000000000e-00, + // nsing = 1 + -2.22423508493755319e-01, 1.87966717746229718e-01, + 3.41805419240637628e-01, 3.42752593807919263e-01, + 4.66574321730757753e-01, -5.59649213591058097e-01, + -8.05759710273191021e-01, -5.38989366115424093e-01, + -4.88914083733395200e-01, 9.80580906465856792e-01, + 9.33757118080975970e-01, 2.82273885115127769e-01, + // nsing = 2 + -2.60522586513312894e-01, -4.26259455096092786e-02, + 1.36549702008863349e-03, 4.39243227763478846e-01, + 6.50591493715480700e-01, -1.23422352472779046e-01, + -3.43379903564271318e-01, -8.13862662890748911e-01, + -7.96093943501906645e-01, 6.11271022503935772e-01, + 7.60213717643090957e-01, 4.93801903948967945e-01, + // nsing = 3 + -1.18249853727020186e-01, -1.90471659765411376e-01, + -2.59044664869706839e-01, 2.69333898502392004e-01, + 4.99077838344125714e-01, 2.64644800189075006e-01, + 1.26114512111568737e-01, -7.46519337025968199e-01, + -8.47666863706379907e-01, 1.89347715957263646e-01, + 5.39641485816297176e-01, 5.97805988669631615e-01, + // nsing = 4 + 4.94825297066481491e-02, -1.71428212158876197e-01, + -2.97766677111471585e-01, 1.60773286596649656e-02, + 1.88114210832460682e-01, 4.11734391195006462e-01, + 3.98540613293909842e-01, -4.63321903522162715e-01, + -6.99522070542463639e-01, -1.32412024008354582e-01, + 3.33997185986131785e-01, 6.01983450812696742e-01, + // nsing = 5 + 1.18367078448232332e-01, -6.09533063579086850e-02, + -1.74762998833038991e-01, -1.39098099222000187e-01, + -6.71534655984154549e-02, 3.34462251996496680e-01, + 4.37429678577360024e-01, -1.59613865629038012e-01, + -4.71863911886034656e-01, -2.92759316465055762e-01, + 1.80238737704018306e-01, 5.42834914744283253e-01, + // nsing = 6 + 8.87698096005701290e-02, 2.84339354980994902e-02, + -3.18943083830766399e-02, -1.53946887977045862e-01, + -1.71825061547624858e-01, 1.70734367410600348e-01, + 3.33690792296469441e-01, 3.97048587678703930e-02, + -2.66422678503135697e-01, -3.18469797424381480e-01, + 8.48049724711137773e-02, 4.60546329221462864e-01, + // nsing = 7 + 2.99767046276705077e-02, 5.34659695701718247e-02, + 4.53131030251822568e-02, -9.37915401977138648e-02, + -1.57982359988083777e-01, 3.82170507060760740e-02, + 1.98891589845251706e-01, 1.17546677047049354e-01, + -1.27514335237079297e-01, -2.72741112680307074e-01, + 3.47906344595283767e-02, 3.82277517244493224e-01, + // nsing = 8 + -7.35922494437203395e-03, 3.72011290318534610e-02, + 5.66783220847204687e-02, -3.21015398169199501e-02, + -1.00308737825172555e-01, -2.57695148077963515e-02, + 9.67294850588435368e-02, 1.18174625238337507e-01, + -5.21266530264988508e-02, -2.08850084114630861e-01, + 1.24443217440050976e-02, 3.19239968065752286e-01, + // nsing = 9 + -1.66126772808035320e-02, 1.46180329587665321e-02, + 3.85927576915247303e-02, 1.18910471133003227e-03, + -4.94003498320899806e-02, -3.93468443660139110e-02, + 3.92113167048952835e-02, 9.03306084789976219e-02, + -1.82889636251263500e-02, -1.53816215444915245e-01, + 3.88103861995563741e-03, 2.72090310854550347e-01, + // nsing = 10 + -1.21245068916826880e-02, 1.59080224420074489e-03, + 1.91116222508366035e-02, 1.05879549199053302e-02, + -1.97228428219695318e-02, -3.16962067712639397e-02, + 1.34110372628315158e-02, 6.18045654429108837e-02, + -5.52574921865441838e-03, -1.14259663804569455e-01, + 1.05534036292203489e-03, 2.37326534898818288e-01, + // nsing = 11 + -5.96835002183177493e-03, -2.42594931567031205e-03, + 7.44753817476594184e-03, 9.33450807578394386e-03, + -6.52649522783026481e-03, -2.08165802069352019e-02, + 3.89988065678848650e-03, 4.12784313451549132e-02, + -1.44110721106127920e-03, -8.76484782997757425e-02, + 2.50210184908121337e-04, 2.11131066219336647e-01, + // nsing = 12 + -2.24505212235034193e-03, -2.38114524227619446e-03, + 2.36375918970809340e-03, 5.97324040603806266e-03, + -1.81333819936645381e-03, -1.28126250720444051e-02, + 9.69251586187208358e-04, 2.83055679874589732e-02, + -3.24986363596307374e-04, -6.97056268370209313e-02, + 5.17231862038123061e-05, 1.90681117197597520e-01, + // nsing = 13 + -6.76887607549779069e-04, -1.48589685249767064e-03, + 6.22548369472046953e-04, 3.43871156746448680e-03, + -4.26557147166379929e-04, -7.98854145009655400e-03, + 2.06644460919535524e-04, 2.03107152586353217e-02, + -6.34563929410856987e-05, -5.71425144910115832e-02, + 9.32252179140502456e-06, 1.74167663785025829e-01, + // nsing = 14 + -1.67596437777156162e-04, -8.05384193869903178e-04, + 1.37627277777023791e-04, 1.97652692602724093e-03, + -8.54392244879459717e-05, -5.23088906415977167e-03, + 3.78965577556493513e-05, 1.52191559129376333e-02, + -1.07393019498185646e-05, -4.79347862153366295e-02, + 1.46503970628861795e-06, 1.60471011683477685e-01, + // nsing = 15 + -3.45715760630978778e-05, -4.31089554210205493e-04, + 2.57350138106549737e-05, 1.19449262097417514e-03, + -1.46322227517372253e-05, -3.61303766799909378e-03, + 5.99057675687392260e-06, 1.17993805017130890e-02, + -1.57660578509526722e-06, -4.09165023743669707e-02, + 2.00739683204152177e-07, 1.48879348585662670e-01, + // nsing = 16 + -5.99735188857573424e-06, -2.42949218855805052e-04, + 4.09249090936269722e-06, 7.67400152727128171e-04, + -2.14920611287648034e-06, -2.60710519575546230e-03, + 8.17591694958640978e-07, 9.38581640137393053e-03, + -2.00910914042737743e-07, -3.54045580123653803e-02, + 2.39819738182594508e-08, 1.38916449405613711e-01, + // nsing = 17 + -8.80708505155966658e-07, -1.46479474515521504e-04, + 5.55693207391871904e-07, 5.19165587844615415e-04, + -2.71391142598826750e-07, -1.94439427580099576e-03, + 9.64641799864928425e-08, 7.61536975207357980e-03, + -2.22357616069432967e-08, -3.09762939485679078e-02, + 2.49806920458212581e-09, 1.30247401712293206e-01, + // nsing = 18 + -1.10007111030476390e-07, -9.35886150886691786e-05, + 6.46244096997824390e-08, 3.65267193418479043e-04, + -2.95175785569292542e-08, -1.48730955943961081e-03, + 9.84949251974795537e-09, 6.27824679148707177e-03, + -2.13827217704781576e-09, -2.73545766571797965e-02, + 2.26877724435352177e-10, 1.22627158810895267e-01, + // nsing = 19 + -1.17302439957657553e-08, -6.24890956722053332e-05, + 6.45231881609786173e-09, 2.64799907072561543e-04, + -2.76943921343331654e-09, -1.16094187847598385e-03, + 8.71074689656480749e-10, 5.24514377390761210e-03, + -1.78730768958639407e-10, -2.43489203319091538e-02, + 1.79658223341365988e-11, 1.15870972518909888e-01, + // nsing = 20 + -1.07084502471985403e-09, -4.31515421260633319e-05, + 5.54152563270547927e-10, 1.96606443937168357e-04, + -2.24423474431542338e-10, -9.21550077887211094e-04, + 6.67734377376211580e-11, 4.43201203646827019e-03, + -1.29896907717633162e-11, -2.18236356404862774e-02, + 1.24042409733678516e-12, 1.09836276968151848e-01, + // nsing = 21 + -8.38816525569060600e-11, -3.06091807093959821e-05, + 4.10033961556230842e-11, 1.48895624771753491e-04, + -1.57238128435253905e-11, -7.42073499862065649e-04, + 4.43938379112418832e-12, 3.78197089773957382e-03, + -8.21067867869285873e-13, -1.96793607299577220e-02, + 7.46725770201828754e-14, 1.04410965521273064e-01, + // nsing = 22 + -5.64848922712870507e-12, -2.22021942382507691e-05, + 2.61729537775838587e-12, 1.14683068921649992e-04, + -9.53316139085394895e-13, -6.05021573565916914e-04, + 2.56116039498542220e-13, 3.25530796858307225e-03, + -4.51482829896525004e-14, -1.78416955716514289e-02, + 3.91940313268087086e-15, 9.95054815464739996e-02, + // nsing = 23 + -3.27482357793897640e-13, -1.64138890390689871e-05, + 1.44278798346454523e-13, 8.96362542918265398e-05, + -5.00524303437266481e-14, -4.98699756861136127e-04, + 1.28274026095767213e-14, 2.82359118537843949e-03, + -2.16009593993917109e-15, -1.62538825704327487e-02, + 1.79368667683853708e-16, 9.50473084594884184e-02 + }; + + const double npi11[11] = { // precomputed values n * pi + 0.00000000000000000e+00, 3.14159265358979324e+00, 6.28318530717958648e+00, + 9.42477796076937972e+00, 1.25663706143591730e+01, 1.57079632679489662e+01, + 1.88495559215387594e+01, 2.19911485751285527e+01, 2.51327412287183459e+01, + 2.82743338823081391e+01, 3.14159265358979324e+01 + }; + const double a11[11] = { // precomputed Fourier coefficient prefactors + 4.43113462726379007e-01, 3.79788034073635143e-01, 2.39122407410867584e-01, + 1.10599187402169792e-01, 3.75782250080904725e-02, 9.37936104296856288e-03, + 1.71974046186334976e-03, 2.31635559000523461e-04, 2.29192401420125452e-05, + 1.66589592139340077e-06, 8.89504561311882155e-08 + }; + const double taylorarr11[11 * 6] = { + // real part imaginary part, low order coefficients last + // nsing = 0 + -1.00000000000000000e+00, 0.00000000000000000e+00, + 0.00000000000000000e-01, 1.12837916709551257e+00, + 1.00000000000000000e+00, 0.00000000000000000e+00, + // nsing = 1 + -5.92741768247463996e-01, -7.19914991991294310e-01, + -6.73156763521649944e-01, 8.14025039279059577e-01, + 8.57089811121701143e-01, 4.00248106586639754e-01, + // nsing = 2 + 1.26114512111568737e-01, -7.46519337025968199e-01, + -8.47666863706379907e-01, 1.89347715957263646e-01, + 5.39641485816297176e-01, 5.97805988669631615e-01, + // nsing = 3 + 4.43238482668529408e-01, -3.03563167310638372e-01, + -5.88095866853990048e-01, -2.32638360700858412e-01, + 2.49595637924601714e-01, 5.77633779156009340e-01, + // nsing = 4 + 3.33690792296469441e-01, 3.97048587678703930e-02, + -2.66422678503135697e-01, -3.18469797424381480e-01, + 8.48049724711137773e-02, 4.60546329221462864e-01, + // nsing = 5 + 1.42043544696751869e-01, 1.24094227867032671e-01, + -8.31224229982140323e-02, -2.40766729258442100e-01, + 2.11669512031059302e-02, 3.48650139549945097e-01, + // nsing = 6 + 3.92113167048952835e-02, 9.03306084789976219e-02, + -1.82889636251263500e-02, -1.53816215444915245e-01, + 3.88103861995563741e-03, 2.72090310854550347e-01, + // nsing = 7 + 7.37741897722738503e-03, 5.04625223970221539e-02, + -2.87394336989990770e-03, -9.96122819257496929e-02, + 5.22745478269428248e-04, 2.23361039070072101e-01, + // nsing = 8 + 9.69251586187208358e-04, 2.83055679874589732e-02, + -3.24986363596307374e-04, -6.97056268370209313e-02, + 5.17231862038123061e-05, 1.90681117197597520e-01, + // nsing = 9 + 9.01625563468897100e-05, 1.74961124275657019e-02, + -2.65745127697337342e-05, -5.22070356354932341e-02, + 3.75952450449939411e-06, 1.67018782142871146e-01, + // nsing = 10 + 5.99057675687392260e-06, 1.17993805017130890e-02, + -1.57660578509526722e-06, -4.09165023743669707e-02, + 2.00739683204152177e-07, 1.48879348585662670e-01 + }; } - - -void RooMath::initFastCERF(Int_t reBins, Double_t reMin, Double_t reMax, Int_t imBins, Double_t imMin, Double_t imMax) +std::complex<double> RooMath::faddeeva(std::complex<double> z) { - // Allocate and initialize lookup table for interpolated complex error function - // for given grid parameters - - // Store grid dimensions and related parameters - _reBins = reBins ; - _imBins = imBins ; - _reMin = reMin ; - _reMax = reMax ; - _reRange = _reMax-_reMin ; - _reStep = _reRange/_reBins ; - - _imMin = imMin ; - _imMax = imMax ; - _imRange = _imMax-_imMin ; - _imStep = _imRange/_imBins ; - - oocxcoutD((TObject*)0,Eval) << endl - << "RooMath::initFastCERF: Allocating Complex Error Function lookup table" << endl - << " Re: " << _reBins << " bins in range (" << _reMin << "," << _reMax << ")" << endl - << " Im: " << _imBins << " bins in range (" << _imMin << "," << _imMax << ")" << endl - << " Allocation size : " << _reBins*_imBins * 2 * sizeof(Double_t) / 1024 << " kB" << endl ; - - - // Allocate storage matrix for Im(cerf) and Re(cerf) and fill it using ComplexErrFunc() - RooSentinel::activate() ; - Int_t imIdx,reIdx ; - _reCerfArray = new pDouble_t[_imBins] ; - _imCerfArray = new pDouble_t[_imBins] ; - for (imIdx=0 ; imIdx<_imBins ; imIdx++) { - _reCerfArray[imIdx] = new Double_t[_reBins] ; - _imCerfArray[imIdx] = new Double_t[_reBins] ; - } - - Bool_t cacheLoaded(kFALSE) ; - if (!_cacheTable || !(cacheLoaded=loadCache())) { - - oocxcoutD((TObject*)0,Eval) << endl - << " Filling table: |..................................................|\r" - << " Filling table: |" ; - - // Allocate storage matrix for Im(cerf) and Re(cerf) and fill it using ComplexErrFunc() - for (imIdx=0 ; imIdx<_imBins ; imIdx++) { - if (imIdx % (_imBins/50) ==0) { - ooccxcoutD((TObject*)0,Eval) << ">" ; cout.flush() ; - } - for (reIdx=0 ; reIdx<_reBins ; reIdx++) { - RooComplex val=ComplexErrFunc(_reMin+reIdx*_reStep,_imMin+imIdx*_imStep) ; - _reCerfArray[imIdx][reIdx] = val.re(); - _imCerfArray[imIdx][reIdx] = val.im() ; - } - } - ooccoutI((TObject*)0,Eval) << endl ; - } - - if (_cacheTable && !cacheLoaded) storeCache() ; + return faddeeva_impl::faddeeva_smabmq_impl<double, 24, 6, 9>( + z.real(), z.imag(), 12., faddeeva_impl::a24, + faddeeva_impl::npi24, faddeeva_impl::taylorarr24); } - -void RooMath::cleanup() +std::complex<double> RooMath::faddeeva_fast(std::complex<double> z) { - if (_reCerfArray) { - for (Int_t imIdx=0 ; imIdx<_imBins ; imIdx++) { - delete[] _reCerfArray[imIdx] ; - delete[] _imCerfArray[imIdx] ; - } - delete[] _reCerfArray ; - delete[] _imCerfArray ; - _reCerfArray = 0 ; - _imCerfArray = 0 ; - } - + return faddeeva_impl::faddeeva_smabmq_impl<double, 11, 3, 3>( + z.real(), z.imag(), 8., faddeeva_impl::a11, + faddeeva_impl::npi11, faddeeva_impl::taylorarr11); } - -RooComplex RooMath::ITPComplexErrFunc(const RooComplex& z, Int_t nOrder) +std::complex<double> RooMath::erfc(const std::complex<double> z) { - // Return complex error function interpolated from lookup tabel created - // by initFastCERF(). Interpolation is performed in Im and Re plane - // to specified order. - - // Initialize grid - if (!_reCerfArray) initFastCERF() ; - - // Located nearest grid point - Double_t imPrime = (z.im()-_imMin) / _imStep ; - Double_t rePrime = (z.re()-_reMin) / _reStep ; - - // Calculate corners of nOrder X nOrder grid box - Int_t imIdxLo = Int_t(imPrime - 1.0*nOrder/2 + 0.5) ; - Int_t imIdxHi = imIdxLo+nOrder-1 ; - Int_t reIdxLo = Int_t(rePrime - 1.0*nOrder/2 + 0.5) ; - Int_t reIdxHi = reIdxLo+nOrder-1 ; - - // Check if the box is fully contained in the grid - if (imIdxLo<0 || imIdxHi>_imBins-1 || reIdxLo<0 || reIdxHi>_reBins-1) { - return ComplexErrFunc(z) ; - } - - // Allocate temporary array space for interpolation - Int_t imIdx /*, reIdx*/ ; - Double_t imYR[10] ; - Double_t imYI[10] ; - - // Loop over imaginary grid points - for (imIdx=imIdxLo ; imIdx<=imIdxHi ; imIdx++) { - // Interpolate real array and store as array point for imaginary interpolation - imYR[imIdx-imIdxLo] = interpolate(&_reCerfArray[imIdx][reIdxLo],nOrder,rePrime-reIdxLo) ; - imYI[imIdx-imIdxLo] = interpolate(&_imCerfArray[imIdx][reIdxLo],nOrder,rePrime-reIdxLo) ; - } - // Interpolate imaginary arrays and construct complex return value - Double_t re = interpolate(imYR,nOrder,imPrime-imIdxLo) ; - Double_t im = interpolate(imYI,nOrder,imPrime-imIdxLo) ; - return RooComplex(re,im) ; + double re = -z.real() * z.real() + z.imag() * z.imag(); + double im = -2. * z.real() * z.imag(); + faddeeva_impl::cexp(re, im); + return (z.real() >= 0.) ? + (std::complex<double>(re, im) * + faddeeva(std::complex<double>(-z.imag(), z.real()))) : + (2. - std::complex<double>(re, im) * + faddeeva(std::complex<double>(z.imag(), -z.real()))); } - - - - -Double_t RooMath::ITPComplexErrFuncRe(const RooComplex& z, Int_t nOrder) +std::complex<double> RooMath::erfc_fast(const std::complex<double> z) { - // Return real component of complex error function interpolated from - // lookup table created by initFastCERF(). Interpolation is performed in - // Im and Re plane to specified order. This functions is noticably faster - // than ITPComplexErrrFunc().re() because only the real lookup table - // is interpolated - - // Initialize grid - if (!_reCerfArray) initFastCERF() ; - - // Located nearest grid point - Double_t imPrime = (z.im()-_imMin) / _imStep ; - Double_t rePrime = (z.re()-_reMin) / _reStep ; - - // Calculate corners of nOrder X nOrder grid box - Int_t imIdxLo = Int_t(imPrime - 1.0*nOrder/2 + 0.5) ; - Int_t imIdxHi = imIdxLo+nOrder-1 ; - Int_t reIdxLo = Int_t(rePrime - 1.0*nOrder/2 + 0.5) ; - Int_t reIdxHi = reIdxLo+nOrder-1 ; - - // Check if the box is fully contained in the grid - if (imIdxLo<0 || imIdxHi>_imBins-1 || reIdxLo<0 || reIdxHi>_reBins-1) { - //cout << "RooMath::ITPComplexErrFuncRe: (" << z.re() << "," << z.im() << ") outside interpolation grid" << endl ; - return ComplexErrFunc(z).re() ; - } - - if (nOrder==1) return _reCerfArray[imIdxLo][reIdxLo] ; - - Int_t imIdx ; - Double_t imYR[10] ; - - // Allocate temporary array space for interpolation - for (imIdx=imIdxLo ; imIdx<=imIdxHi ; imIdx++) { - // Interpolate real array and store as array point for imaginary interpolation - imYR[imIdx-imIdxLo] = interpolate(&_reCerfArray[imIdx][reIdxLo],nOrder,rePrime-reIdxLo) ; - } - // Interpolate imaginary arrays and construct complex return value - return interpolate(imYR,nOrder,imPrime-imIdxLo) ; + double re = -z.real() * z.real() + z.imag() * z.imag(); + double im = -2. * z.real() * z.imag(); + faddeeva_impl::cexp(re, im); + return (z.real() >= 0.) ? + (std::complex<double>(re, im) * + faddeeva_fast(std::complex<double>(-z.imag(), z.real()))) : + (2. - std::complex<double>(re, im) * + faddeeva_fast(std::complex<double>(z.imag(), -z.real()))); } - - -Double_t RooMath::ITPComplexErrFuncIm(const RooComplex& z, Int_t nOrder) +std::complex<double> RooMath::erf(const std::complex<double> z) { - // Return real component of complex error function interpolated from - // lookup table created by initFastCERF(). Interpolation is performed in - // Im and Re plane to specified order. This functions is noticably faster - // than ITPComplexErrrFunc().im() because only the imaginary lookup table - // is interpolated - - // Initialize grid - if (!_reCerfArray) initFastCERF() ; - - // Located nearest grid point - Double_t imPrime = (z.im()-_imMin) / _imStep ; - Double_t rePrime = (z.re()-_reMin) / _reStep ; - - // Calculate corners of nOrder X nOrder grid box - Int_t imIdxLo = Int_t(imPrime - 1.0*nOrder/2 + 0.5) ; - Int_t imIdxHi = imIdxLo+nOrder-1 ; - Int_t reIdxLo = Int_t(rePrime - 1.0*nOrder/2 + 0.5) ; - Int_t reIdxHi = reIdxLo+nOrder-1 ; - - // Check if the box is fully contained in the grid - if (imIdxLo<0 || imIdxHi>_imBins-1 || reIdxLo<0 || reIdxHi>_reBins-1) { - return ComplexErrFunc(z).im() ; - } - - // Allocate temporary array space for interpolation - Int_t imIdx ; - Double_t imYI[10] ; - - // Loop over imaginary grid points - for (imIdx=imIdxLo ; imIdx<=imIdxHi ; imIdx++) { - // Interpolate real array and store as array point for imaginary interpolation - imYI[imIdx-imIdxLo] = interpolate(&_imCerfArray[imIdx][reIdxLo],nOrder,rePrime-reIdxLo) ; - } - // Interpolate imaginary arrays and construct complex return value - return interpolate(imYI,nOrder,imPrime-imIdxLo) ; + double re = -z.real() * z.real() + z.imag() * z.imag(); + double im = -2. * z.real() * z.imag(); + faddeeva_impl::cexp(re, im); + return (z.real() >= 0.) ? + (1. - std::complex<double>(re, im) * + faddeeva(std::complex<double>(-z.imag(), z.real()))) : + (std::complex<double>(re, im) * + faddeeva(std::complex<double>(z.imag(), -z.real())) - 1.); } - - - +std::complex<double> RooMath::erf_fast(const std::complex<double> z) +{ + double re = -z.real() * z.real() + z.imag() * z.imag(); + double im = -2. * z.real() * z.imag(); + faddeeva_impl::cexp(re, im); + return (z.real() >= 0.) ? + (1. - std::complex<double>(re, im) * + faddeeva_fast(std::complex<double>(-z.imag(), z.real()))) : + (std::complex<double>(re, im) * + faddeeva_fast(std::complex<double>(z.imag(), -z.real())) - 1.); +} Double_t RooMath::interpolate(Double_t ya[], Int_t n, Double_t x) @@ -408,87 +670,21 @@ Double_t RooMath::interpolate(Double_t xa[], Double_t ya[], Int_t n, Double_t x) } - -Bool_t RooMath::loadCache() +#include <map> +void RooMath::warn(const char* oldfun, const char* newfun) { - // Load the complex error function lookup table from the cache file - - const char* fName = cacheFileName() ; - // Open cache file - ifstream ifs(fName) ; - - // Return immediately if file doesn't exist - if (ifs.fail()) return kFALSE ; - - oocxcoutD((TObject*)0,Eval) << endl << " Filling table from cache file " << fName << endl ; - - // Load data in memory arrays - Bool_t ok(kTRUE) ; - Int_t i ; - for (i=0 ; i<_imBins ; i++) { - ifs.read((char*)_imCerfArray[i],_reBins*sizeof(Double_t)) ; - if (ifs.fail()) ok=kFALSE ; - ifs.read((char*)_reCerfArray[i],_reBins*sizeof(Double_t)) ; - if (ifs.fail()) ok=kFALSE ; - } - - // Issue error message on partial read failure - if (!ok) { - oocoutE((TObject*)0,Eval) << "RooMath::loadCERFCache: error reading file " << cacheFileName() << endl ; - } - return ok ; -} - - -void RooMath::storeCache() -{ - // Store the complex error function lookup table in the cache file - - ofstream ofs(cacheFileName()) ; - - oocxcoutI((TObject*)0,Eval) << endl << " Writing table to cache file " << cacheFileName() << endl ; - Int_t i ; - for (i=0 ; i<_imBins ; i++) { - ofs.write((char*)_imCerfArray[i],_reBins*sizeof(Double_t)) ; - ofs.write((char*)_reCerfArray[i],_reBins*sizeof(Double_t)) ; - } -} - - - -const char* RooMath::cacheFileName() -{ - // Construct and return the name of the complex error function cache file - static char fileName[1024] ; - snprintf(fileName,1024,"/tmp/RooMath_CERFcache_R%04d_I%04d_%d.dat",_reBins,_imBins,gSystem->GetUid()) ; - return fileName ; -} - - -Double_t RooMath::erf(Double_t x) -{ - return TMath::Erf(x) ; -} - -Double_t RooMath::erfc(Double_t x) -{ - return TMath::Erfc(x) ; + static std::map<const char*, int> nwarn; + if (nwarn[oldfun] < 1<<12) { + ++nwarn[oldfun]; + if (newfun) { + std::cout << "[#0] WARN: RooMath::" << oldfun << + " is deprecated, please use " << + newfun << " instead." << std::endl; + } else { + std::cout << "[#0] WARN: RooMath::" << oldfun << + " is deprecated, and no longer needed, " + "you can remove the call to " << + oldfun << " entirely." << std::endl; + } + } } - - - -// Instantiation of static members -Int_t RooMath::_reBins(0) ; -Int_t RooMath::_imBins(0) ; -Double_t RooMath::_reMin(0) ; -Double_t RooMath::_reMax(0) ; -Double_t RooMath::_reRange(0) ; -Double_t RooMath::_reStep(0) ; -Double_t RooMath::_imMin(0) ; -Double_t RooMath::_imMax(0) ; -Double_t RooMath::_imRange(0) ; -Double_t RooMath::_imStep(0) ; -pDouble_t* RooMath::_reCerfArray = 0; -pDouble_t* RooMath::_imCerfArray = 0; -Bool_t RooMath::_cacheTable(kTRUE) ; - diff --git a/roofit/roofitcore/src/RooMinimizer.cxx b/roofit/roofitcore/src/RooMinimizer.cxx index 75671955e2544..ffa2507bf3ecf 100644 --- a/roofit/roofitcore/src/RooMinimizer.cxx +++ b/roofit/roofitcore/src/RooMinimizer.cxx @@ -77,6 +77,8 @@ char* operator+( streampos&, char* ); #endif +using namespace std; + ClassImp(RooMinimizer) ; @@ -119,6 +121,7 @@ RooMinimizer::RooMinimizer(RooAbsReal& function) _optConst = kFALSE ; _verbose = kFALSE ; _profile = kFALSE ; + _profileStart = kFALSE ; _printLevel = 1 ; _minimizerType = "Minuit"; // default minimizer @@ -182,6 +185,28 @@ void RooMinimizer::setStrategy(Int_t istrat) +//_____________________________________________________________________________ +void RooMinimizer::setMaxIterations(Int_t n) +{ + // Change maximum number of MINUIT iterations + // (RooMinimizer default 500 * #parameters) + _theFitter->Config().MinimizerOptions().SetMaxIterations(n); +} + + + + +//_____________________________________________________________________________ +void RooMinimizer::setMaxFunctionCalls(Int_t n) +{ + // Change maximum number of likelihood function calss from MINUIT + // (RooMinimizer default 500 * #parameters) + _theFitter->Config().MinimizerOptions().SetMaxFunctionCalls(n); +} + + + + //_____________________________________________________________________________ void RooMinimizer::setErrorLevel(Double_t level) { @@ -206,6 +231,14 @@ void RooMinimizer::setEps(Double_t eps) } +//_____________________________________________________________________________ +void RooMinimizer::setOffsetting(Bool_t flag) +{ + // Enable internal likelihood offsetting for enhanced numeric precision + _func->enableOffsetting(flag) ; +} + + //_____________________________________________________________________________ @@ -218,6 +251,23 @@ void RooMinimizer::setMinimizerType(const char* type) +//_____________________________________________________________________________ +ROOT::Fit::Fitter* RooMinimizer::fitter() +{ + // Return underlying ROOT fitter object + return _theFitter ; +} + + +//_____________________________________________________________________________ +const ROOT::Fit::Fitter* RooMinimizer::fitter() const +{ + // Return underlying ROOT fitter object + return _theFitter ; +} + + + //_____________________________________________________________________________ RooFitResult* RooMinimizer::fit(const char* options) { @@ -587,7 +637,7 @@ RooFitResult* RooMinimizer::save(const char* userName, const char* userTitle) title = userTitle ? userTitle : Form("%s", _func->GetTitle()) ; RooFitResult* fitRes = new RooFitResult(name,title) ; - // Move eventual fixed paramaters in floatList to constList + // Move eventual fixed parameters in floatList to constList Int_t i ; RooArgList saveConstList(*(_fcn->GetConstParamList())) ; RooArgList saveFloatInitList(*(_fcn->GetInitFloatParamList())) ; @@ -728,7 +778,8 @@ void RooMinimizer::profileStart() // Start profiling timer if (_profile) { _timer.Start() ; - _cumulTimer.Start(kFALSE) ; + _cumulTimer.Start(_profileStart?kFALSE:kTRUE) ; + _profileStart = kTRUE ; } } diff --git a/roofit/roofitcore/src/RooMinimizerFcn.cxx b/roofit/roofitcore/src/RooMinimizerFcn.cxx index 0755db27ff413..6019456a7e4b8 100644 --- a/roofit/roofitcore/src/RooMinimizerFcn.cxx +++ b/roofit/roofitcore/src/RooMinimizerFcn.cxx @@ -38,6 +38,8 @@ #include "RooMinimizer.h" +using namespace std; + RooMinimizerFcn::RooMinimizerFcn(RooAbsReal *funct, RooMinimizer* context, bool verbose) : _funct(funct), _context(context), @@ -48,6 +50,8 @@ RooMinimizerFcn::RooMinimizerFcn(RooAbsReal *funct, RooMinimizer* context, _verbose(verbose) { + _evalCounter = 0 ; + // Examine parameter list RooArgSet* paramSet = _funct->getParameters(RooArgSet()); RooArgList paramList(*paramSet); @@ -79,6 +83,8 @@ RooMinimizerFcn::RooMinimizerFcn(RooAbsReal *funct, RooMinimizer* context, delete pIter; _nDim = _floatParamList->getSize(); + + updateFloatVec() ; // Save snapshot of initial lists _initFloatParamList = (RooArgList*) _floatParamList->snapshot(kFALSE) ; @@ -86,6 +92,28 @@ RooMinimizerFcn::RooMinimizerFcn(RooAbsReal *funct, RooMinimizer* context, } + + +RooMinimizerFcn::RooMinimizerFcn(const RooMinimizerFcn& other) : ROOT::Math::IBaseFunctionMultiDim(other), + _evalCounter(other._evalCounter), + _funct(other._funct), + _context(other._context), + _maxFCN(other._maxFCN), + _numBadNLL(other._numBadNLL), + _printEvalErrors(other._printEvalErrors), + _doEvalErrorWall(other._doEvalErrorWall), + _nDim(other._nDim), + _logfile(other._logfile), + _verbose(other._verbose), + _floatParamVec(other._floatParamVec) +{ + _floatParamList = new RooArgList(*other._floatParamList) ; + _constParamList = new RooArgList(*other._constParamList) ; + _initFloatParamList = (RooArgList*) other._initFloatParamList->snapshot(kFALSE) ; + _initConstParamList = (RooArgList*) other._initConstParamList->snapshot(kFALSE) ; +} + + RooMinimizerFcn::~RooMinimizerFcn() { delete _floatParamList; @@ -94,11 +122,13 @@ RooMinimizerFcn::~RooMinimizerFcn() delete _initConstParamList; } + ROOT::Math::IBaseFunctionMultiDim* RooMinimizerFcn::Clone() const { - return new RooMinimizerFcn(_funct,_context,_verbose); + return new RooMinimizerFcn(*this) ; } + Bool_t RooMinimizerFcn::Synchronize(std::vector<ROOT::Fit::ParameterSettings>& parameters, Bool_t optConst, Bool_t verbose) { @@ -157,6 +187,7 @@ Bool_t RooMinimizerFcn::Synchronize(std::vector<ROOT::Fit::ParameterSettings>& p // Handle floatParamList for(index= 0; index < _floatParamList->getSize(); index++) { RooRealVar *par= dynamic_cast<RooRealVar*>(_floatParamList->at(index)) ; + if (!par) continue ; Double_t pstep(0) ; @@ -177,10 +208,10 @@ Bool_t RooMinimizerFcn::Synchronize(std::vector<ROOT::Fit::ParameterSettings>& p } // Set the limits, if not infinite - if (par->hasMin() && par->hasMax()) { + if (par->hasMin() ) pmin = par->getMin(); + if (par->hasMax() ) pmax = par->getMax(); - } // Calculate step size pstep = par->getError(); @@ -222,10 +253,15 @@ Bool_t RooMinimizerFcn::Synchronize(std::vector<ROOT::Fit::ParameterSettings>& p par->getVal(), pstep, pmin,pmax)); - } else { + } + else { parameters.push_back(ROOT::Fit::ParameterSettings(par->GetName(), par->getVal(), pstep)); + if (par->hasMin() ) + parameters.back().SetLowerLimit(pmin); + else if (par->hasMax() ) + parameters.back().SetUpperLimit(pmax); } continue; @@ -286,7 +322,12 @@ Bool_t RooMinimizerFcn::Synchronize(std::vector<ROOT::Fit::ParameterSettings>& p if (oldVar!=par->getVal() || oldVlo!=pmin || oldVhi != pmax || oldVerr!=pstep) { parameters[index].SetValue(par->getVal()); parameters[index].SetStepSize(pstep); - parameters[index].SetLimits(pmin,pmax); + if (par->hasMin() && par->hasMax() ) + parameters[index].SetLimits(pmin,pmax); + else if (par->hasMin() ) + parameters[index].SetLowerLimit(pmin); + else if (par->hasMax() ) + parameters[index].SetUpperLimit(pmax); } // Inform user about changes in verbose mode @@ -329,6 +370,8 @@ Bool_t RooMinimizerFcn::Synchronize(std::vector<ROOT::Fit::ParameterSettings>& p } + updateFloatVec() ; + return 0 ; } @@ -442,7 +485,9 @@ void RooMinimizerFcn::ApplyCovarianceMatrix(TMatrixDSym& V) Bool_t RooMinimizerFcn::SetPdfParamVal(const Int_t &index, const Double_t &value) const { - RooRealVar* par = (RooRealVar*)_floatParamList->at(index); + //RooRealVar* par = (RooRealVar*)_floatParamList->at(index); + RooRealVar* par = (RooRealVar*)_floatParamVec[index] ; + if (par->getVal()!=value) { if (_verbose) cout << par->GetName() << "=" << value << ", " ; @@ -454,6 +499,22 @@ Bool_t RooMinimizerFcn::SetPdfParamVal(const Int_t &index, const Double_t &value } + +//_____________________________________________________________________________ +void RooMinimizerFcn::updateFloatVec() +{ + _floatParamVec.clear() ; + RooFIter iter = _floatParamList->fwdIterator() ; + RooAbsArg* arg ; + _floatParamVec = std::vector<RooAbsArg*>(_floatParamList->getSize()) ; + Int_t i(0) ; + while((arg=iter.next())) { + _floatParamVec[i++] = arg ; + } +} + + + double RooMinimizerFcn::DoEval(const double *x) const { @@ -463,9 +524,12 @@ double RooMinimizerFcn::DoEval(const double *x) const SetPdfParamVal(index,x[index]); } - // Calculate the function for these parameters + // Calculate the function for these parameters + RooAbsReal::setHideOffset(kFALSE) ; double fvalue = _funct->getVal(); - if (RooAbsPdf::evalError() || RooAbsReal::numEvalErrors()>0) { + RooAbsReal::setHideOffset(kTRUE) ; + + if (RooAbsPdf::evalError() || RooAbsReal::numEvalErrors()>0 || fvalue>1e30) { if (_printEvalErrors>=0) { @@ -493,7 +557,7 @@ double RooMinimizerFcn::DoEval(const double *x) const } if (_doEvalErrorWall) { - fvalue = _maxFCN ; + fvalue = _maxFCN+1 ; } RooAbsPdf::clearEvalError() ; @@ -507,11 +571,13 @@ double RooMinimizerFcn::DoEval(const double *x) const if (_logfile) (*_logfile) << setprecision(15) << fvalue << setprecision(4) << endl; if (_verbose) { - cout << "\nprevFCN = " << setprecision(10) + cout << "\nprevFCN" << (_funct->isOffsetting()?"-offset":"") << " = " << setprecision(10) << fvalue << setprecision(4) << " " ; cout.flush() ; } + _evalCounter++ ; + return fvalue; } diff --git a/roofit/roofitcore/src/RooMinuit.cxx b/roofit/roofitcore/src/RooMinuit.cxx index 22aee24f27407..8089dd623cf11 100644 --- a/roofit/roofitcore/src/RooMinuit.cxx +++ b/roofit/roofitcore/src/RooMinuit.cxx @@ -73,6 +73,8 @@ char* operator+( streampos&, char* ); #endif +using namespace std; + ClassImp(RooMinuit) ; @@ -246,6 +248,14 @@ void RooMinuit::setEps(Double_t eps) +//_____________________________________________________________________________ +void RooMinuit::setOffsetting(Bool_t flag) +{ + // Enable internal likelihood offsetting for enhanced numeric precision + _func->enableOffsetting(flag) ; +} + + //_____________________________________________________________________________ RooFitResult* RooMinuit::fit(const char* options) { @@ -377,14 +387,18 @@ Int_t RooMinuit::minos() RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::CollectErrors) ; RooAbsReal::clearEvalErrorLog() ; _status= _theFitter->ExecuteCommand("MINOS",arglist,1); + // check also the status of Minos looking at fCstatu + if (_status == 0 && gMinuit->fCstatu != "SUCCESSFUL") { + if (gMinuit->fCstatu == "FAILURE" || + gMinuit->fCstatu == "PROBLEMS") _status = 5; + _status = 6; + } + RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::PrintErrors) ; profileStop() ; backProp() ; - cout << "MINOS: status = " << _status << endl ; - saveStatus("MINOS",_status) ; - return _status ; } @@ -428,6 +442,12 @@ Int_t RooMinuit::minos(const RooArgSet& minosParamList) RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::CollectErrors) ; RooAbsReal::clearEvalErrorLog() ; _status= _theFitter->ExecuteCommand("MINOS",arglist,1+nMinosPar); + // check also the status of Minos looking at fCstatu + if (_status == 0 && gMinuit->fCstatu != "SUCCESSFUL") { + if (gMinuit->fCstatu == "FAILURE" || + gMinuit->fCstatu == "PROBLEMS") _status = 5; + _status = 6; + } RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::PrintErrors) ; profileStop() ; backProp() ; @@ -872,7 +892,7 @@ RooFitResult* RooMinuit::save(const char* userName, const char* userTitle) RooFitResult* fitRes = new RooFitResult(name,title) ; - // Move eventual fixed paramaters in floatList to constList + // Move eventual fixed parameters in floatList to constList Int_t i ; RooArgList saveConstList(*_constParamList) ; RooArgList saveFloatInitList(*_initFloatParamList) ; @@ -1139,7 +1159,7 @@ void RooMinuit::updateFloatVec() _floatParamVec.clear() ; RooFIter iter = _floatParamList->fwdIterator() ; RooAbsArg* arg ; - _floatParamVec.reserve(_floatParamList->getSize()) ; + _floatParamVec.resize(_floatParamList->getSize()) ; Int_t i(0) ; while((arg=iter.next())) { _floatParamVec[i++] = arg ; @@ -1162,6 +1182,7 @@ void RooMinuit::applyCovarianceMatrix(TMatrixDSym& V) if (_floatParamList->at(i)->isConstant()) { continue ; } + cout << "setting parameter " << i << " error to " << sqrt((*_extV)(i,i)) << endl ; setPdfParamErr(i, sqrt((*_extV)(i,i))) ; } @@ -1189,9 +1210,11 @@ void RooMinuitGlue(Int_t& /*np*/, Double_t* /*gin*/, } // Calculate the function for these parameters + RooAbsReal::setHideOffset(kFALSE) ; f= context->_func->getVal() ; + RooAbsReal::setHideOffset(kTRUE) ; context->_evalCounter++ ; - if ( RooAbsPdf::evalError() || RooAbsReal::numEvalErrors()>0 ) { + if ( RooAbsPdf::evalError() || RooAbsReal::numEvalErrors()>0 || f>1e30) { if (context->_printEvalErrors>=0) { @@ -1219,7 +1242,7 @@ void RooMinuitGlue(Int_t& /*np*/, Double_t* /*gin*/, } if (context->_doEvalErrorWall) { - f = maxFCN ; + f = maxFCN+1 ; } RooAbsPdf::clearEvalError() ; @@ -1228,11 +1251,11 @@ void RooMinuitGlue(Int_t& /*np*/, Double_t* /*gin*/, } else if (f>maxFCN) { maxFCN = f ; } - + // Optional logging if (logf) (*logf) << setprecision(15) << f << setprecision(4) << endl; if (verbose) { - cout << "\nprevFCN = " << setprecision(10) << f << setprecision(4) << " " ; + cout << "\nprevFCN" << (context->_func->isOffsetting()?"-offset":"") << " = " << setprecision(10) << f << setprecision(4) << " " ; cout.flush() ; } } diff --git a/roofit/roofitcore/src/RooMultiCatIter.cxx b/roofit/roofitcore/src/RooMultiCatIter.cxx index dbb35405a7247..510d3cf68152f 100644 --- a/roofit/roofitcore/src/RooMultiCatIter.cxx +++ b/roofit/roofitcore/src/RooMultiCatIter.cxx @@ -39,6 +39,8 @@ #include "RooAbsCategoryLValue.h" #include "RooMultiCatIter.h" +using namespace std; + ClassImp(RooMultiCatIter) ; diff --git a/roofit/roofitcore/src/RooMultiCategory.cxx b/roofit/roofitcore/src/RooMultiCategory.cxx index a3d826f8adc69..cf390e8879e0a 100644 --- a/roofit/roofitcore/src/RooMultiCategory.cxx +++ b/roofit/roofitcore/src/RooMultiCategory.cxx @@ -40,6 +40,8 @@ #include "RooAbsCategory.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooMultiCategory) ; diff --git a/roofit/roofitcore/src/RooMultiGenFunction.cxx b/roofit/roofitcore/src/RooMultiGenFunction.cxx index 603d300793eae..efce7ec40217f 100644 --- a/roofit/roofitcore/src/RooMultiGenFunction.cxx +++ b/roofit/roofitcore/src/RooMultiGenFunction.cxx @@ -36,6 +36,8 @@ +using namespace std; + ClassImp(RooMultiGenFunction) ; diff --git a/roofit/roofitcore/src/RooMultiVarGaussian.cxx b/roofit/roofitcore/src/RooMultiVarGaussian.cxx index cac8a4ec2d5ba..c2e8458282e6b 100644 --- a/roofit/roofitcore/src/RooMultiVarGaussian.cxx +++ b/roofit/roofitcore/src/RooMultiVarGaussian.cxx @@ -36,6 +36,8 @@ #include "TDecompChol.h" #include "RooFitResult.h" +using namespace std; + ClassImp(RooMultiVarGaussian) ; diff --git a/roofit/roofitcore/src/RooNLLVar.cxx b/roofit/roofitcore/src/RooNLLVar.cxx index ed8521c63d88b..1de5d53d08325 100644 --- a/roofit/roofitcore/src/RooNLLVar.cxx +++ b/roofit/roofitcore/src/RooNLLVar.cxx @@ -26,8 +26,11 @@ // END_HTML // +#include <algorithm> + #include "RooFit.h" #include "Riostream.h" +#include "TMath.h" #include "RooNLLVar.h" #include "RooAbsData.h" @@ -36,9 +39,9 @@ #include "RooMsgService.h" #include "RooAbsDataStore.h" #include "RooRealMPFE.h" - +#include "RooRealSumPdf.h" #include "RooRealVar.h" - +#include "RooProdPdf.h" ClassImp(RooNLLVar) ; @@ -57,7 +60,7 @@ RooNLLVar::RooNLLVar(const char *name, const char* title, RooAbsPdf& pdf, RooAbs RooCmdConfig::decodeStringOnTheFly("RooNLLVar::RooNLLVar","RangeWithName",0,"",arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9), RooCmdConfig::decodeStringOnTheFly("RooNLLVar::RooNLLVar","AddCoefRange",0,"",arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9), RooCmdConfig::decodeIntOnTheFly("RooNLLVar::RooNLLVar","NumCPU",0,1,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9), - kFALSE, + RooFit::BulkPartition, RooCmdConfig::decodeIntOnTheFly("RooNLLVar::RooNLLVar","Verbose",0,1,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9), RooCmdConfig::decodeIntOnTheFly("RooNLLVar::RooNLLVar","SplitRange",0,0,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9), RooCmdConfig::decodeIntOnTheFly("RooNLLVar::RooNLLVar","CloneData",0,1,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9)) @@ -84,7 +87,12 @@ RooNLLVar::RooNLLVar(const char *name, const char* title, RooAbsPdf& pdf, RooAbs _extended = pc.getInt("extended") ; _weightSq = kFALSE ; _first = kTRUE ; + _offset = 0.; + _offsetCarry = 0.; + _offsetSaveW2 = 0.; + _offsetCarrySaveW2 = 0.; + _binnedPdf = 0 ; } @@ -92,15 +100,44 @@ RooNLLVar::RooNLLVar(const char *name, const char* title, RooAbsPdf& pdf, RooAbs //_____________________________________________________________________________ RooNLLVar::RooNLLVar(const char *name, const char *title, RooAbsPdf& pdf, RooAbsData& indata, Bool_t extended, const char* rangeName, const char* addCoefRangeName, - Int_t nCPU, Bool_t interleave, Bool_t verbose, Bool_t splitRange, Bool_t cloneData) : + Int_t nCPU, RooFit::MPSplit interleave, Bool_t verbose, Bool_t splitRange, Bool_t cloneData, Bool_t binnedL) : RooAbsOptTestStatistic(name,title,pdf,indata,RooArgSet(),rangeName,addCoefRangeName,nCPU,interleave,verbose,splitRange,cloneData), _extended(extended), _weightSq(kFALSE), - _first(kTRUE) + _first(kTRUE), _offsetSaveW2(0.), _offsetCarrySaveW2(0.) { // Construct likelihood from given p.d.f and (binned or unbinned dataset) // For internal use. + // If binned likelihood flag is set, pdf is a RooRealSumPdf representing a yield vector + // for a binned likelihood calculation + _binnedPdf = binnedL ? (RooRealSumPdf*)_funcClone : 0 ; + + // Retrieve and cache bin widths needed to convert unnormalized binnedPdf values back to yields + if (_binnedPdf) { + + // The Active label will disable pdf integral calculations + _binnedPdf->setAttribute("BinnedLikelihoodActive") ; + + RooArgSet* obs = _funcClone->getObservables(_dataClone) ; + if (obs->getSize()!=1) { + _binnedPdf = 0 ; + } else { + RooRealVar* var = (RooRealVar*) obs->first() ; + std::list<Double_t>* boundaries = _binnedPdf->binBoundaries(*var,var->getMin(),var->getMax()) ; + std::list<Double_t>::iterator biter = boundaries->begin() ; + _binw.resize(boundaries->size()-1) ; + Double_t lastBound = (*biter) ; + biter++ ; + int ibin=0 ; + while (biter!=boundaries->end()) { + _binw[ibin] = (*biter) - lastBound ; + lastBound = (*biter) ; + ibin++ ; + biter++ ; + } + } + } } @@ -108,16 +145,41 @@ RooNLLVar::RooNLLVar(const char *name, const char *title, RooAbsPdf& pdf, RooAbs //_____________________________________________________________________________ RooNLLVar::RooNLLVar(const char *name, const char *title, RooAbsPdf& pdf, RooAbsData& indata, const RooArgSet& projDeps, Bool_t extended, const char* rangeName,const char* addCoefRangeName, - Int_t nCPU,Bool_t interleave,Bool_t verbose, Bool_t splitRange, Bool_t cloneData) : + Int_t nCPU,RooFit::MPSplit interleave,Bool_t verbose, Bool_t splitRange, Bool_t cloneData, Bool_t binnedL) : RooAbsOptTestStatistic(name,title,pdf,indata,projDeps,rangeName,addCoefRangeName,nCPU,interleave,verbose,splitRange,cloneData), _extended(extended), _weightSq(kFALSE), - _first(kTRUE) + _first(kTRUE), _offsetSaveW2(0.), _offsetCarrySaveW2(0.) { // Construct likelihood from given p.d.f and (binned or unbinned dataset) // For internal use. + // If binned likelihood flag is set, pdf is a RooRealSumPdf representing a yield vector + // for a binned likelihood calculation + _binnedPdf = binnedL ? (RooRealSumPdf*)_funcClone : 0 ; + // Retrieve and cache bin widths needed to convert unnormalized binnedPdf values back to yields + if (_binnedPdf) { + + RooArgSet* obs = _funcClone->getObservables(_dataClone) ; + if (obs->getSize()!=1) { + _binnedPdf = 0 ; + } else { + RooRealVar* var = (RooRealVar*) obs->first() ; + std::list<Double_t>* boundaries = _binnedPdf->binBoundaries(*var,var->getMin(),var->getMax()) ; + std::list<Double_t>::iterator biter = boundaries->begin() ; + _binw.resize(boundaries->size()-1) ; + Double_t lastBound = (*biter) ; + biter++ ; + int ibin=0 ; + while (biter!=boundaries->end()) { + _binw[ibin] = (*biter) - lastBound ; + lastBound = (*biter) ; + ibin++ ; + biter++ ; + } + } + } } @@ -127,9 +189,12 @@ RooNLLVar::RooNLLVar(const RooNLLVar& other, const char* name) : RooAbsOptTestStatistic(other,name), _extended(other._extended), _weightSq(other._weightSq), - _first(kTRUE) -{ + _first(kTRUE), _offsetSaveW2(other._offsetSaveW2), + _offsetCarrySaveW2(other._offsetCarrySaveW2), + _binw(other._binw) { // Copy constructor + + _binnedPdf = other._binnedPdf ? (RooRealSumPdf*)_funcClone : 0 ; } @@ -148,21 +213,18 @@ RooNLLVar::~RooNLLVar() void RooNLLVar::applyWeightSquared(Bool_t flag) { if (_gofOpMode==Slave) { - _weightSq = flag ; - setValueDirty() ; - + if (flag != _weightSq) { + _weightSq = flag; + std::swap(_offset, _offsetSaveW2); + std::swap(_offsetCarry, _offsetCarrySaveW2); + } + setValueDirty(); } else if ( _gofOpMode==MPMaster) { - - for (Int_t i=0 ; i<_nCPU ; i++) { - _mpfeArray[i]->applyNLLWeightSquared(flag) ; - } - + for (Int_t i=0 ; i<_nCPU ; i++) + _mpfeArray[i]->applyNLLWeightSquared(flag); } else if ( _gofOpMode==SimMaster) { - - for (Int_t i=0 ; i<_nGof ; i++) { - ((RooNLLVar*)_gofArray[i])->applyWeightSquared(flag) ; - } - + for (Int_t i=0 ; i<_nGof ; i++) + ((RooNLLVar*)_gofArray[i])->applyWeightSquared(flag); } } @@ -176,81 +238,177 @@ Double_t RooNLLVar::evaluatePartition(Int_t firstEvent, Int_t lastEvent, Int_t s // and the zero event is processed the extended term is added to the return // likelihood. + // Throughout the calculation, we use Kahan's algorithm for summing to + // prevent loss of precision - this is a factor four more expensive than + // straight addition, but since evaluating the PDF is usually much more + // expensive than that, we tolerate the additional cost... Int_t i ; - Double_t result(0) ; + Double_t result(0), carry(0); RooAbsPdf* pdfClone = (RooAbsPdf*) _funcClone ; // cout << "RooNLLVar::evaluatePartition(" << GetName() << ") projDeps = " << (_projDeps?*_projDeps:RooArgSet()) << endl ; + + _dataClone->store()->recalculateCache( _projDeps, firstEvent, lastEvent, stepSize,(_binnedPdf?kFALSE:kTRUE) ) ; - _dataClone->store()->recalculateCache( _projDeps, firstEvent, lastEvent, stepSize ) ; + Double_t sumWeight(0), sumWeightCarry(0); - Double_t sumWeight(0) ; - for (i=firstEvent ; i<lastEvent ; i+=stepSize) { - - // get the data values for this event - //Double_t wgt = _dataClone->weight(i) ; - //if (wgt==0) continue ; + // If pdf is marked as binned - do a binned likelihood calculation here (sum of log-Poisson for each bin) + if (_binnedPdf) { - _dataClone->get(i) ; - //cout << "NLL - now loading event #" << i << endl ; -// _funcObsSet->Print("v") ; - + for (i=firstEvent ; i<lastEvent ; i+=stepSize) { + + _dataClone->get(i) ; + + if (!_dataClone->valid()) continue; + + Double_t eventWeight = _dataClone->weight(); - if (!_dataClone->valid()) { - continue ; - } - if (_dataClone->weight()==0) continue ; + // Calculate log(Poisson(N|mu) for this bin + Double_t N = eventWeight ; + Double_t mu = _binnedPdf->getVal()*_binw[i] ; + //cout << "RooNLLVar::binnedL(" << GetName() << ") N=" << N << " mu = " << mu << endl ; + if (mu<=0 && N>0) { - Double_t eventWeight = _dataClone->weight() ; - if (_weightSq) eventWeight *= eventWeight ; + // Catch error condition: data present where zero events are predicted + logEvalError(Form("Observed %f events in bin %d with zero event yield",N,i)) ; + + } else if (fabs(mu)<1e-10 && fabs(N)<1e-10) { - Double_t term = eventWeight * pdfClone->getLogVal(_normSet); - //cout << "term = " << term << endl ; - sumWeight += eventWeight ; + // Special handling of this case since log(Poisson(0,0)=0 but can't be calculated with usual log-formula + // since log(mu)=0. No update of result is required since term=0. - result-= term; - } - - // include the extended maximum likelihood term, if requested - if(_extended && firstEvent==0) { - if (_weightSq) { - // Calculate sum of weights-squared here for extended term - - Double_t sumW2(0) ; - for (i=0 ; i<_dataClone->numEntries() ; i++) { - _dataClone->get(i) ; - Double_t eventWeight = _dataClone->weight() ; - sumW2 += eventWeight * eventWeight ; + } else { + + Double_t term = -1*(-mu + N*log(mu) - TMath::LnGamma(N+1)) ; + + // Kahan summation of sumWeight + Double_t y = eventWeight - sumWeightCarry; + Double_t t = sumWeight + y; + sumWeightCarry = (t - sumWeight) - y; + sumWeight = t; + + // Kahan summation of result + y = term - carry; + t = result + y; + carry = (t - result) - y; + result = t; } - //cout << "weight squared extended mode: sumW2 = " << sumW2 << " sumentries = " << _dataClone->sumEntries() << endl ; - - result+= pdfClone->extendedTerm(sumW2 , _dataClone->get()); + } - } else { - result+= pdfClone->extendedTerm(_dataClone->sumEntries(),_dataClone->get()); + + } else { + + for (i=firstEvent ; i<lastEvent ; i+=stepSize) { + + _dataClone->get(i) ; + + if (!_dataClone->valid()) continue; + + Double_t eventWeight = _dataClone->weight(); + if (0. == eventWeight * eventWeight) continue ; + if (_weightSq) eventWeight = _dataClone->weightSquared() ; + + Double_t term = -eventWeight * pdfClone->getLogVal(_normSet); + + + Double_t y = eventWeight - sumWeightCarry; + Double_t t = sumWeight + y; + sumWeightCarry = (t - sumWeight) - y; + sumWeight = t; + + y = term - carry; + t = result + y; + carry = (t - result) - y; + result = t; } - } + + // include the extended maximum likelihood term, if requested + if(_extended && _setNum==_extSet) { + if (_weightSq) { + + // Calculate sum of weights-squared here for extended term + Double_t sumW2(0), sumW2carry(0); + for (i=0 ; i<_dataClone->numEntries() ; i++) { + _dataClone->get(i); + Double_t y = _dataClone->weightSquared() - sumW2carry; + Double_t t = sumW2 + y; + sumW2carry = (t - sumW2) - y; + sumW2 = t; + + + } + + Double_t expected= pdfClone->expectedEvents(_dataClone->get()); + + // Adjust calculation of extended term with W^2 weighting: adjust poisson such that + // estimate of Nexpected stays at the same value, but has a different variance, rescale + // both the observed and expected count of the Poisson with a factor sum[w] / sum[w^2] + // i.e. change Poisson(Nobs = sum[w]| Nexp ) --> Poisson( sum[w] * sum[w] / sum[w^2] | Nexp * sum[w] / sum[w^2] ) + + Double_t observedW2 = ( _dataClone->sumEntries() * _dataClone->sumEntries() ) / sumW2 ; + Double_t expectedW2 = expected * _dataClone->sumEntries() / sumW2 ; + Double_t extra= expectedW2 - observedW2*log(expectedW2); + + // Double_t y = pdfClone->extendedTerm(sumW2, _dataClone->get()) - carry; + + Double_t y = extra - carry ; + Double_t t = result + y; + carry = (t - result) - y; + result = t; + } else { + Double_t y = pdfClone->extendedTerm(_dataClone->sumEntries(), _dataClone->get()) - carry; + Double_t t = result + y; + carry = (t - result) - y; + result = t; + } + } + } + // If part of simultaneous PDF normalize probability over // number of simultaneous PDFs: -sum(log(p/n)) = -sum(log(p)) + N*log(n) if (_simCount>1) { - result += sumWeight*log(1.0*_simCount) ; + Double_t y = sumWeight*log(1.0*_simCount) - carry; + Double_t t = result + y; + carry = (t - result) - y; + result = t; } - -// cout << "RooNLLVar(first=" << firstEvent << ", last=" << lastEvent << ", step=" << stepSize << ") result = " << result << endl ; + + //timer.Stop() ; + //cout << "RooNLLVar::evalPart(" << GetName() << ") SET=" << _setNum << " first=" << firstEvent << ", last=" << lastEvent << ", step=" << stepSize << ") result = " << result << " CPU = " << timer.CpuTime() << endl ; // At the end of the first full calculation, wire the caches if (_first) { _first = kFALSE ; _funcClone->wireAllCaches() ; } - + + // Check if value offset flag is set. + if (_doOffset) { + + // If no offset is stored enable this feature now + if (_offset==0 && result !=0 ) { + coutI(Minimization) << "RooNLLVar::evaluatePartition(" << GetName() << ") first = "<< firstEvent << " last = " << lastEvent << " Likelihood offset now set to " << result << std::endl ; + _offset = result ; + _offsetCarry = carry; + } + + // Substract offset + Double_t y = -_offset - (carry + _offsetCarry); + Double_t t = result + y; + carry = (t - result) - y; + result = t; + } + + + _evalCarry = carry; return result ; } + diff --git a/roofit/roofitcore/src/RooNameSet.cxx b/roofit/roofitcore/src/RooNameSet.cxx index bc4b1c6744305..65ebd9f84db76 100644 --- a/roofit/roofitcore/src/RooNameSet.cxx +++ b/roofit/roofitcore/src/RooNameSet.cxx @@ -25,6 +25,10 @@ // END_HTML // +#include <cstring> +#include <algorithm> +#include <cassert> + #include "RooFit.h" #include "Riostream.h" @@ -34,202 +38,189 @@ #include "RooArgSet.h" #include "RooArgList.h" - - ClassImp(RooNameSet) ; +//_____________________________________________________________________________ +void RooNameSet::strdup(Int_t& dstlen, char* &dstbuf, const char* src) +{ + // copy src to dst, keep dstlen up to date, make sure zero length strings + // do not take memory + dstlen = src ? std::strlen(src) : 0; + if (dstlen) ++dstlen; + char *buf = dstlen ? new char[dstlen] : 0; + if (buf) std::strcpy(buf, src); + delete[] dstbuf; + dstbuf = buf; +} //_____________________________________________________________________________ -RooNameSet::RooNameSet() +RooNameSet::RooNameSet() : _len(0), _nameList(0) { // Default constructor - - _len = 256 ; - _nameList = new char[_len] ; - _nameList[0] = 0 ; - } - - - //_____________________________________________________________________________ -RooNameSet::RooNameSet(const RooArgSet& argSet) +RooNameSet::RooNameSet(const RooArgSet& argSet) : _len(0), _nameList(0) { // Construct from RooArgSet - - _len = 256 ; - _nameList = new char[_len] ; - _nameList[0] = 0 ; - refill(argSet) ; + refill(argSet); } - - //_____________________________________________________________________________ -RooNameSet::RooNameSet(const RooNameSet& other) : TObject(other), RooPrintable(other), _nameList() +RooNameSet::RooNameSet(const RooNameSet& other) : + TObject(other), RooPrintable(other), _len(0), _nameList(0) { // Copy constructor - - _len = other._len ; - _nameList = new char[_len] ; - strlcpy(_nameList,other._nameList,_len) ; + strdup(_len, _nameList, other._nameList); } - - //_____________________________________________________________________________ -void RooNameSet::extendBuffer(Int_t inc) +RooNameSet::~RooNameSet() { - // Increment internal buffer by specified amount - char * newbuf = new char[_len+inc] ; - strncpy(newbuf,_nameList,_len) ; - delete[] _nameList ; - _nameList = newbuf ; - _len += inc ; + // Destructor + delete[] _nameList; } - - //_____________________________________________________________________________ -void RooNameSet::setNameList(const char* givenList) +RooNameSet& RooNameSet::operator=(const RooNameSet& other) { - // Increment internal buffer by specified amount - _len = strlen(givenList) ; - char * newbuf = new char[_len+1] ; - strncpy(newbuf,givenList,_len+1) ; - delete[] _nameList ; - _nameList = newbuf ; -} + // Assignment operator + // Check comparison against self + if (&other == this || _nameList == other._nameList) return *this; + + strdup(_len, _nameList, other._nameList); + return *this; +} //_____________________________________________________________________________ -void RooNameSet::refill(const RooArgSet& argSet) +Bool_t RooNameSet::operator==(const RooNameSet& other) const { - // Refill internal contents from names in given argSet - - RooArgList tmp(argSet) ; - tmp.sort() ; - TIterator* iter = tmp.createIterator() ; - RooAbsArg* arg ; - char *ptr=_nameList ; - char *end=_nameList+_len-2 ; - *ptr = 0 ; - while((arg=(RooAbsArg*)iter->Next())) { - const char* argName = arg->GetName() ; - while((*ptr++ = *argName++)) { - if (ptr>=end) { - // Extend buffer - Int_t offset = ptr-_nameList ; - extendBuffer(256) ; - ptr = _nameList + offset ; - end = _nameList + _len - 2; - } - } - *(ptr-1) = ':' ; - } - if (ptr>_nameList) *(ptr-1)= 0 ; - delete iter ; -} + // Comparison operator + // Check comparison against self + if (&other == this || _nameList == other._nameList) return kTRUE; + return _nameList && other._nameList && + 0 == std::strcmp(_nameList, other._nameList); +} //_____________________________________________________________________________ -RooArgSet* RooNameSet::select(const RooArgSet& list) const +Bool_t RooNameSet::operator<(const RooNameSet& other) const { - // Construct a RooArgSet of objects in input 'list' - // whose names match to those in the internal name - // list of RooNameSet - - RooArgSet* output = new RooArgSet ; + if (&other == this) return kFALSE; + if (!_nameList) return other._nameList; + if (!other._nameList) return kFALSE; + return std::strcmp(_nameList, other._nameList) < 0; +} - char *buffer = new char[strlen(_nameList)+1] ; - strlcpy(buffer,_nameList,strlen(_nameList)+1) ; - char* token = strtok(buffer,":") ; - - while(token) { - RooAbsArg* arg = list.find(token) ; - if (arg) output->add(*arg) ; - token = strtok(0,":") ; +//_____________________________________________________________________________ +void RooNameSet::extendBuffer(Int_t inc) +{ + if (!inc) return; + assert(inc > 0 || _len >= -inc); + int newsz = _len + inc; + if (newsz <= 1 || !_len) newsz = 0; + char* newbuf = newsz ? new char[newsz] : 0; + if (newbuf && _nameList) { + std::strncpy(newbuf, _nameList, std::min(_len, newsz)); + newbuf[newsz - 1] = 0; } - - delete[] buffer ; - - return output ; + delete[] _nameList; + _nameList = newbuf; + _len = newsz; } - - //_____________________________________________________________________________ -RooNameSet::~RooNameSet() +void RooNameSet::setNameList(const char* givenList) { - // Destructor - - delete[] _nameList ; + strdup(_len, _nameList, givenList); } - - //_____________________________________________________________________________ -Bool_t RooNameSet::operator==(const RooNameSet& other) +void RooNameSet::refill(const RooArgSet& argSet) { - // Comparison operator - - // Check comparison against self - if (&other==this) return kTRUE ; - - // First check for equal length - if (strlen(_nameList) != strlen(other._nameList)) return kFALSE ; - - return (!strcmp(_nameList,other._nameList)) ; + // Refill internal contents from names in given argSet + delete[] _nameList; + _nameList = 0; + _len = 0; + if (0 == argSet.getSize()) return; + + RooArgList tmp(argSet); + tmp.sort(); + // figure out the length of the array we need + RooAbsArg* arg = 0; + for (RooFIter it = tmp.fwdIterator(); 0 != (arg = it.next()); + _len += 1 + std::strlen(arg->GetName())) { } + if (_len <= 1) _len = 0; + // allocate it + _nameList = _len ? new char[_len] : 0; + if (_nameList) { + // copy in the names of the objects + char *p = _nameList; + for (RooFIter it = tmp.fwdIterator(); 0 != (arg = it.next()); ) { + const char *name = arg->GetName(); + std::strcpy(p, name); + while (*p) ++p; + *p++ = ':'; + } + // zero-terminate properly + *--p = 0; + } } - - //_____________________________________________________________________________ -RooNameSet& RooNameSet::operator=(const RooNameSet& other) +RooArgSet* RooNameSet::select(const RooArgSet& list) const { - // Assignment operator + // Construct a RooArgSet of objects in input 'list' + // whose names match to those in the internal name + // list of RooNameSet - delete[] _nameList ; + RooArgSet* output = new RooArgSet; + if (!_nameList || !std::strlen(_nameList)) return output; - _len = other._len ; - _nameList = new char[_len] ; - strlcpy(_nameList,other._nameList,_len) ; + // need to copy _nameList because std::strtok modifies the string + char* tmp = 0; + int dummy = 0; + strdup(dummy, tmp, _nameList); - return *this ; -} + char* token = std::strtok(tmp, ":"); + while (token) { + RooAbsArg* arg = list.find(token); + if (arg) output->add(*arg); + token = std::strtok(0, ":"); + } + delete[] tmp; + return output; +} //_____________________________________________________________________________ -void RooNameSet::printName(ostream& os) const +void RooNameSet::printName(std::ostream& os) const { // Print name of nameset - os << GetName() ; + os << GetName(); } - //_____________________________________________________________________________ -void RooNameSet::printTitle(ostream& os) const +void RooNameSet::printTitle(std::ostream& os) const { // Print title of nameset - os << GetTitle() ; + os << GetTitle(); } - //_____________________________________________________________________________ -void RooNameSet::printClassName(ostream& os) const +void RooNameSet::printClassName(std::ostream& os) const { // Print class name of nameset - os << IsA()->GetName() ; + os << IsA()->GetName(); } - //_____________________________________________________________________________ -void RooNameSet::printValue(ostream& os) const +void RooNameSet::printValue(std::ostream& os) const { // Print value of nameset, i.e the list of names - os << _nameList ; + os << content(); } diff --git a/roofit/roofitcore/src/RooNumCdf.cxx b/roofit/roofitcore/src/RooNumCdf.cxx index fcccd1c854422..f71a0b9ff5b57 100644 --- a/roofit/roofitcore/src/RooNumCdf.cxx +++ b/roofit/roofitcore/src/RooNumCdf.cxx @@ -33,6 +33,8 @@ #include "RooHistPdf.h" #include "RooRealVar.h" +using namespace std; + ClassImp(RooNumCdf) ; diff --git a/roofit/roofitcore/src/RooNumConvPdf.cxx b/roofit/roofitcore/src/RooNumConvPdf.cxx index 2318cb7fca380..dd9dc311a43b1 100644 --- a/roofit/roofitcore/src/RooNumConvPdf.cxx +++ b/roofit/roofitcore/src/RooNumConvPdf.cxx @@ -79,6 +79,8 @@ +using namespace std; + ClassImp(RooNumConvPdf) ; diff --git a/roofit/roofitcore/src/RooNumConvolution.cxx b/roofit/roofitcore/src/RooNumConvolution.cxx index 3184b4864a390..24327d4f7a41e 100644 --- a/roofit/roofitcore/src/RooNumConvolution.cxx +++ b/roofit/roofitcore/src/RooNumConvolution.cxx @@ -75,6 +75,8 @@ #include "RooMsgService.h" +using namespace std; + ClassImp(RooNumConvolution) ; diff --git a/roofit/roofitcore/src/RooNumGenConfig.cxx b/roofit/roofitcore/src/RooNumGenConfig.cxx index ed6c6ac5757d5..9f1b002d55d0d 100644 --- a/roofit/roofitcore/src/RooNumGenConfig.cxx +++ b/roofit/roofitcore/src/RooNumGenConfig.cxx @@ -36,6 +36,8 @@ +using namespace std; + ClassImp(RooNumGenConfig) ; diff --git a/roofit/roofitcore/src/RooNumIntConfig.cxx b/roofit/roofitcore/src/RooNumIntConfig.cxx index b177958872ae6..885cc6132dc67 100644 --- a/roofit/roofitcore/src/RooNumIntConfig.cxx +++ b/roofit/roofitcore/src/RooNumIntConfig.cxx @@ -36,6 +36,8 @@ +using namespace std; + ClassImp(RooNumIntConfig) ; diff --git a/roofit/roofitcore/src/RooNumRunningInt.cxx b/roofit/roofitcore/src/RooNumRunningInt.cxx index 106825b0c1ed3..24ca2cd220c14 100644 --- a/roofit/roofitcore/src/RooNumRunningInt.cxx +++ b/roofit/roofitcore/src/RooNumRunningInt.cxx @@ -36,6 +36,8 @@ #include "RooHistPdf.h" #include "RooRealVar.h" +using namespace std; + ClassImp(RooNumRunningInt) ; diff --git a/roofit/roofitcore/src/RooNumber.cxx b/roofit/roofitcore/src/RooNumber.cxx index 8ad2c0f9d739e..05ad902adbd6d 100644 --- a/roofit/roofitcore/src/RooNumber.cxx +++ b/roofit/roofitcore/src/RooNumber.cxx @@ -24,6 +24,8 @@ #include "RooFit.h" #include "RooNumber.h" +using namespace std; + ClassImp(RooNumber) ; diff --git a/roofit/roofitcore/src/RooParamBinning.cxx b/roofit/roofitcore/src/RooParamBinning.cxx index f81cda3412429..9033da01603e6 100644 --- a/roofit/roofitcore/src/RooParamBinning.cxx +++ b/roofit/roofitcore/src/RooParamBinning.cxx @@ -35,6 +35,8 @@ #include "Riostream.h" +using namespace std; + ClassImp(RooParamBinning) ; diff --git a/roofit/roofitcore/src/RooPlot.cxx b/roofit/roofitcore/src/RooPlot.cxx index dcb1d8cde6ee3..09206b25c838d 100644 --- a/roofit/roofitcore/src/RooPlot.cxx +++ b/roofit/roofitcore/src/RooPlot.cxx @@ -69,9 +69,16 @@ #include <string.h> #include <assert.h> +using namespace std; + ClassImp(RooPlot) ; +Bool_t RooPlot::_addDirStatus = kTRUE ; + +Bool_t RooPlot::addDirectoryStatus() { return _addDirStatus ; } +Bool_t RooPlot::setAddDirectoryStatus(Bool_t flag) { Bool_t ret = flag ; _addDirStatus = flag ; return ret ; } + //_____________________________________________________________________________ RooPlot::RooPlot() : _hist(0), _plotVarClone(0), _plotVarSet(0), _normVars(0), _normObj(0), _dir(0) @@ -81,7 +88,7 @@ RooPlot::RooPlot() : _hist(0), _plotVarClone(0), _plotVarSet(0), _normVars(0), _ _iterator= _items.MakeIterator() ; - if (gDirectory) { + if (gDirectory && addDirectoryStatus()) { _dir = gDirectory ; gDirectory->Append(this) ; } @@ -95,9 +102,16 @@ RooPlot::RooPlot(Double_t xmin, Double_t xmax) : { // Constructor of RooPlot with range [xmin,xmax] + Bool_t histAddDirStatus = TH1::AddDirectoryStatus(); TH1::AddDirectory(kFALSE) ; + _hist = new TH1D(histName(),"A RooPlot",100,xmin,xmax) ; - TH1::AddDirectory(kTRUE) ; + _hist->Sumw2(kFALSE) ; + _hist->GetSumw2()->Set(0) ; + + + TH1::AddDirectory(histAddDirStatus) ; + // Create an empty frame with the specified x-axis limits. initialize(); @@ -113,9 +127,14 @@ RooPlot::RooPlot(Double_t xmin, Double_t xmax, Double_t ymin, Double_t ymax) : { // Construct of a two-dimensioanl RooPlot with ranges [xmin,xmax] x [ymin,ymax] + Bool_t histAddDirStatus = TH1::AddDirectoryStatus(); TH1::AddDirectory(kFALSE) ; + _hist = new TH1D(histName(),"A RooPlot",100,xmin,xmax) ; - TH1::AddDirectory(kFALSE) ; + _hist->Sumw2(kFALSE) ; + _hist->GetSumw2()->Set(0) ; + + TH1::AddDirectory(histAddDirStatus) ; SetMinimum(ymin); SetMaximum(ymax); @@ -131,9 +150,14 @@ RooPlot::RooPlot(const RooAbsRealLValue &var1, const RooAbsRealLValue &var2) : // Construct a two-dimensional RooPlot with ranges and properties taken // from variables var1 and var2 + Bool_t histAddDirStatus = TH1::AddDirectoryStatus(); TH1::AddDirectory(kFALSE) ; + _hist = new TH1D(histName(),"A RooPlot",100,var1.getMin(),var1.getMax()) ; - TH1::AddDirectory(kTRUE) ; + _hist->Sumw2(kFALSE) ; + _hist->GetSumw2()->Set(0) ; + + TH1::AddDirectory(histAddDirStatus) ; if(!var1.hasMin() || !var1.hasMax()) { coutE(InputArguments) << "RooPlot::RooPlot: cannot create plot for variable without finite limits: " @@ -163,9 +187,14 @@ RooPlot::RooPlot(const RooAbsRealLValue &var1, const RooAbsRealLValue &var2, // from variables var1 and var2 but with an overriding range definition // of [xmin,xmax] x [ymin,ymax] + Bool_t histAddDirStatus = TH1::AddDirectoryStatus(); TH1::AddDirectory(kFALSE) ; + _hist = new TH1D(histName(),"A RooPlot",100,xmin,xmax) ; - TH1::AddDirectory(kTRUE) ; + _hist->Sumw2(kFALSE) ; + _hist->GetSumw2()->Set(0) ; + + TH1::AddDirectory(histAddDirStatus) ; SetMinimum(ymin); SetMaximum(ymax); @@ -183,9 +212,14 @@ RooPlot::RooPlot(const char* name, const char* title, const RooAbsRealLValue &va // Create an 1-dimensional with all properties taken from 'var', but // with an explicit range [xmin,xmax] and a default binning of 'nbins' + Bool_t histAddDirStatus = TH1::AddDirectoryStatus(); TH1::AddDirectory(kFALSE) ; + _hist = new TH1D(name,title,nbins,xmin,xmax) ; - TH1::AddDirectory(kTRUE) ; + _hist->Sumw2(kFALSE) ; + _hist->GetSumw2()->Set(0) ; + + TH1::AddDirectory(histAddDirStatus) ; // plotVar can be a composite in case of a RooDataSet::plot, need deepClone _plotVarSet = (RooArgSet*) RooArgSet(var).snapshot() ; @@ -208,9 +242,14 @@ RooPlot::RooPlot(const RooAbsRealLValue &var, Double_t xmin, Double_t xmax, Int_ // Create an 1-dimensional with all properties taken from 'var', but // with an explicit range [xmin,xmax] and a default binning of 'nbins' + Bool_t histAddDirStatus = TH1::AddDirectoryStatus(); TH1::AddDirectory(kFALSE) ; + _hist = new TH1D(histName(),"RooPlot",nbins,xmin,xmax) ; - TH1::AddDirectory(kTRUE) ; + _hist->Sumw2(kFALSE) ; + _hist->GetSumw2()->Set(0) ; + + TH1::AddDirectory(histAddDirStatus) ; // plotVar can be a composite in case of a RooDataSet::plot, need deepClone _plotVarSet = (RooArgSet*) RooArgSet(var).snapshot() ; @@ -248,7 +287,7 @@ void RooPlot::initialize() SetName(histName()) ; - if (gDirectory) { + if (gDirectory && addDirectoryStatus()) { _dir = gDirectory ; gDirectory->Append(this) ; } @@ -495,6 +534,8 @@ void RooPlot::updateYAxis(Double_t ymin, Double_t ymax, const char *label) if(GetMaximum() < ymax) { _defYmax = ymax ; SetMaximum(ymax); + // if we don't do this - Unzoom on y-axis will reset upper bound to 1 + _hist->SetBinContent(1,ymax) ; } if(GetMinimum() > ymin) { _defYmin = ymin ; @@ -507,13 +548,23 @@ void RooPlot::updateYAxis(Double_t ymin, Double_t ymax, const char *label) //_____________________________________________________________________________ -void RooPlot::Draw(Option_t *options) +void RooPlot::Draw(Option_t *option) { // Draw this plot and all of the elements it contains. The specified options // only apply to the drawing of our frame. The options specified in our add...() // methods will be used to draw each object we contain. - _hist->Draw(options); + TString optArg = option ; + optArg.ToLower() ; + + // This draw options prevents the histogram with one dummy entry + // to be drawn + if (optArg.Contains("same")) { + _hist->Draw("FUNCSAME"); + } else { + _hist->Draw("FUNC"); + } + _iterator->Reset(); TObject *obj = 0; while((obj= _iterator->Next())) { diff --git a/roofit/roofitcore/src/RooPlotable.cxx b/roofit/roofitcore/src/RooPlotable.cxx index 1bdf7ae2b4598..dc34138ed7d5e 100644 --- a/roofit/roofitcore/src/RooPlotable.cxx +++ b/roofit/roofitcore/src/RooPlotable.cxx @@ -30,6 +30,8 @@ #include "TObject.h" #include "Riostream.h" +using namespace std; + ClassImp(RooPlotable) ; diff --git a/roofit/roofitcore/src/RooPolyVar.cxx b/roofit/roofitcore/src/RooPolyVar.cxx index db27427ae7732..9b139d03f3909 100644 --- a/roofit/roofitcore/src/RooPolyVar.cxx +++ b/roofit/roofitcore/src/RooPolyVar.cxx @@ -41,6 +41,8 @@ #include "RooMsgService.h" #include "TMath.h" +using namespace std; + ClassImp(RooPolyVar) ; diff --git a/roofit/roofitcore/src/RooPrintable.cxx b/roofit/roofitcore/src/RooPrintable.cxx index 8520d137c5ce9..6814aaba7a04c 100644 --- a/roofit/roofitcore/src/RooPrintable.cxx +++ b/roofit/roofitcore/src/RooPrintable.cxx @@ -40,6 +40,8 @@ #include "TNamed.h" #include "TClass.h" +using namespace std; + ClassImp(RooPrintable) ; diff --git a/roofit/roofitcore/src/RooProdGenContext.cxx b/roofit/roofitcore/src/RooProdGenContext.cxx index bd47c24cd7bae..fbeb731bc9f94 100644 --- a/roofit/roofitcore/src/RooProdGenContext.cxx +++ b/roofit/roofitcore/src/RooProdGenContext.cxx @@ -37,6 +37,8 @@ +using namespace std; + ClassImp(RooProdGenContext) ; diff --git a/roofit/roofitcore/src/RooProdPdf.cxx b/roofit/roofitcore/src/RooProdPdf.cxx index fa90c29c4064d..5d1ecee0f416b 100644 --- a/roofit/roofitcore/src/RooProdPdf.cxx +++ b/roofit/roofitcore/src/RooProdPdf.cxx @@ -95,6 +95,8 @@ static char *strtok_r(char *s1, const char *s2, char **lasts) #include "TSystem.h" +using namespace std; + ClassImp(RooProdPdf) ; @@ -1744,6 +1746,8 @@ std::vector<RooAbsReal*> RooProdPdf::processProductTerm(const RooArgSet* nset, c const char* name = makeRGPPName("GENPROJ_",*term,termISet,termNSet,isetRangeName) ; RooAbsReal* partInt = new RooGenProdProj(name,name,*term,termISet,termNSet,isetRangeName,normRange()) ; + partInt->setExpensiveObjectCache(expensiveObjectCache()) ; + partInt->setStringAttribute("PROD_TERM_TYPE","IVa") ; //partInt->setOperMode(operMode()) ; diff --git a/roofit/roofitcore/src/RooProduct.cxx b/roofit/roofitcore/src/RooProduct.cxx index a5b6872ec1f98..01365fad9dfde 100644 --- a/roofit/roofitcore/src/RooProduct.cxx +++ b/roofit/roofitcore/src/RooProduct.cxx @@ -85,7 +85,7 @@ RooProduct::~RooProduct() //_____________________________________________________________________________ -RooProduct::RooProduct(const char* name, const char* title, const RooArgSet& prodSet) : +RooProduct::RooProduct(const char* name, const char* title, const RooArgList& prodSet) : RooAbsReal(name, title), _compRSet("!compRSet","Set of real product components",this), _compCSet("!compCSet","Set of category product components",this), diff --git a/roofit/roofitcore/src/RooProfileLL.cxx b/roofit/roofitcore/src/RooProfileLL.cxx index 9cbd590d566e0..e5678d09d5aa7 100644 --- a/roofit/roofitcore/src/RooProfileLL.cxx +++ b/roofit/roofitcore/src/RooProfileLL.cxx @@ -27,6 +27,7 @@ #include "RooProfileLL.h" #include "RooAbsReal.h" #include "RooMinuit.h" +#include "RooMinimizer.h" #include "RooMsgService.h" #include "RooRealVar.h" #include "RooMsgService.h" @@ -43,7 +44,7 @@ ClassImp(RooProfileLL) _obs("paramOfInterest","Parameters of interest",this), _par("nuisanceParam","Nuisance parameters",this,kFALSE,kFALSE), _startFromMin(kTRUE), - _minuit(0), + _minimizer(0), _absMinValid(kFALSE), _absMin(0), _neval(0) @@ -63,7 +64,7 @@ RooProfileLL::RooProfileLL(const char *name, const char *title, _obs("paramOfInterest","Parameters of interest",this), _par("nuisanceParam","Nuisance parameters",this,kFALSE,kFALSE), _startFromMin(kTRUE), - _minuit(0), + _minimizer(0), _absMinValid(kFALSE), _absMin(0), _neval(0) @@ -96,7 +97,7 @@ RooProfileLL::RooProfileLL(const RooProfileLL& other, const char* name) : _obs("obs",this,other._obs), _par("par",this,other._par), _startFromMin(other._startFromMin), - _minuit(0), + _minimizer(0), _absMinValid(kFALSE), _absMin(0), _paramFixed(other._paramFixed), @@ -120,8 +121,8 @@ RooProfileLL::~RooProfileLL() // Destructor // Delete instance of minuit if it was ever instantiated - if (_minuit) { - delete _minuit ; + if (_minimizer) { + delete _minimizer ; } delete _piter ; @@ -162,6 +163,23 @@ RooAbsReal* RooProfileLL::createProfile(const RooArgSet& paramsOfInterest) +//_____________________________________________________________________________ +void RooProfileLL::initializeMinimizer() const +{ + coutI(Minimization) << "RooProfileLL::evaluate(" << GetName() << ") Creating instance of MINUIT" << endl ; + + Bool_t smode = RooMsgService::instance().silentMode() ; + RooMsgService::instance().setSilentMode(kTRUE) ; + _minimizer = new MINIMIZER(const_cast<RooAbsReal&>(_nll.arg())) ; + if (!smode) RooMsgService::instance().setSilentMode(kFALSE) ; + + //_minimizer->setPrintLevel(-999) ; + //_minimizer->setNoWarn() ; + //_minimizer->setVerbose(1) ; +} + + + //_____________________________________________________________________________ Double_t RooProfileLL::evaluate() const { @@ -169,18 +187,9 @@ Double_t RooProfileLL::evaluate() const // parameters that are not considered observables of this profile // likelihood object. - // Instantiate minuit if we haven't done that already - if (!_minuit) { - coutI(Minimization) << "RooProfileLL::evaluate(" << GetName() << ") Creating instance of MINUIT" << endl ; - - Bool_t smode = RooMsgService::instance().silentMode() ; - RooMsgService::instance().setSilentMode(kTRUE) ; - _minuit = new RooMinuit(const_cast<RooAbsReal&>(_nll.arg())) ; - if (!smode) RooMsgService::instance().setSilentMode(kFALSE) ; - - _minuit->setPrintLevel(-999) ; - //_minuit->setNoWarn() ; - //_minuit->setVerbose(1) ; + // Instantiate minimizer if we haven't done that already + if (!_minimizer) { + initializeMinimizer() ; } // Save current value of observables @@ -198,9 +207,15 @@ Double_t RooProfileLL::evaluate() const const_cast<RooProfileLL&>(*this)._par = _paramAbsMin ; } - _minuit->zeroEvalCount() ; - _minuit->migrad() ; - _neval = _minuit->evalCounter() ; + _minimizer->zeroEvalCount() ; + + //TString minim=::ROOT::Math::MinimizerOptions::DefaultMinimizerType().c_str(); + //TString algorithm = ROOT::Math::MinimizerOptions::DefaultMinimizerAlgo().c_str(); + //if (algorithm == "Migrad") algorithm = "Minimize"; // prefer to use Minimize instead of Migrad + //_minimizer->minimize(minim.Data(),algorithm.Data()); + + _minimizer->migrad() ; + _neval = _minimizer->evalCounter() ; // Restore original values and constant status of observables TIterator* iter = obsSetOrig->createIterator() ; @@ -246,7 +261,11 @@ void RooProfileLL::validateAbsMin() const cxcoutI(Minimization) << "RooProfileLL::evaluate(" << GetName() << ") determining minimum likelihood for current configurations w.r.t all observable" << endl ; - + + if (!_minimizer) { + initializeMinimizer() ; + } + // Save current values of non-marginalized parameters RooArgSet* obsStart = (RooArgSet*) _obs.snapshot(kFALSE) ; @@ -260,7 +279,12 @@ void RooProfileLL::validateAbsMin() const // Find minimum with all observables floating const_cast<RooSetProxy&>(_obs).setAttribAll("Constant",kFALSE) ; - _minuit->migrad() ; + + //TString minim=::ROOT::Math::MinimizerOptions::DefaultMinimizerType().c_str(); + //TString algorithm = ROOT::Math::MinimizerOptions::DefaultMinimizerAlgo().c_str(); + //if (algorithm == "Migrad") algorithm = "Minimize"; // prefer to use Minimize instead of Migrad + //_minimizer->minimize(minim.Data(),algorithm.Data()); + _minimizer->migrad() ; // Save value and remember _absMin = _nll ; @@ -309,9 +333,9 @@ void RooProfileLL::validateAbsMin() const Bool_t RooProfileLL::redirectServersHook(const RooAbsCollection& /*newServerList*/, Bool_t /*mustReplaceAll*/, Bool_t /*nameChange*/, Bool_t /*isRecursive*/) { - if (_minuit) { - delete _minuit ; - _minuit = 0 ; + if (_minimizer) { + delete _minimizer ; + _minimizer = 0 ; } return kFALSE ; } diff --git a/roofit/roofitcore/src/RooProjectedPdf.cxx b/roofit/roofitcore/src/RooProjectedPdf.cxx index 95979a42d30a5..f15911aa200a4 100644 --- a/roofit/roofitcore/src/RooProjectedPdf.cxx +++ b/roofit/roofitcore/src/RooProjectedPdf.cxx @@ -37,6 +37,7 @@ #include "RooRealVar.h" #include "RooNameReg.h" +using namespace std; ClassImp(RooProjectedPdf) ; diff --git a/roofit/roofitcore/src/RooProofDriverSelector.cxx b/roofit/roofitcore/src/RooProofDriverSelector.cxx index e2b9c9df7fbb7..ff0ea3b897fb4 100644 --- a/roofit/roofitcore/src/RooProofDriverSelector.cxx +++ b/roofit/roofitcore/src/RooProofDriverSelector.cxx @@ -42,6 +42,7 @@ #endif using namespace RooFit ; +using namespace std ; void RooProofDriverSelector::SlaveBegin(TTree * /*tree*/) { diff --git a/roofit/roofitcore/src/RooPullVar.cxx b/roofit/roofitcore/src/RooPullVar.cxx index b9f91549ff56b..aeff76533df0d 100644 --- a/roofit/roofitcore/src/RooPullVar.cxx +++ b/roofit/roofitcore/src/RooPullVar.cxx @@ -35,6 +35,8 @@ #include "RooAbsReal.h" #include "RooRealVar.h" +using namespace std; + ClassImp(RooPullVar) ; diff --git a/roofit/roofitcore/src/RooQuasiRandomGenerator.cxx b/roofit/roofitcore/src/RooQuasiRandomGenerator.cxx index 32d5373a9a645..f547056b9561d 100644 --- a/roofit/roofitcore/src/RooQuasiRandomGenerator.cxx +++ b/roofit/roofitcore/src/RooQuasiRandomGenerator.cxx @@ -37,6 +37,8 @@ #include "Riostream.h" #include <assert.h> +using namespace std; + ClassImp(RooQuasiRandomGenerator) ; diff --git a/roofit/roofitcore/src/RooRandom.cxx b/roofit/roofitcore/src/RooRandom.cxx index d22837015df95..043de1881c300 100644 --- a/roofit/roofitcore/src/RooRandom.cxx +++ b/roofit/roofitcore/src/RooRandom.cxx @@ -21,6 +21,7 @@ // By default a private copy of TRandom3 is used to generate all random numbers. // END_HTML // +#include <cassert> #include "RooFit.h" @@ -30,12 +31,19 @@ #include "TRandom3.h" -#include <assert.h> +using namespace std; ClassImp(RooRandom) ; +TRandom* RooRandom::_theGenerator = 0; +RooQuasiRandomGenerator* RooRandom::_theQuasiGenerator = 0; +RooRandom::Guard RooRandom::guard; + +//_____________________________________________________________________________ +RooRandom::Guard::~Guard() +{ delete RooRandom::_theGenerator; delete RooRandom::_theQuasiGenerator; } //_____________________________________________________________________________ TRandom *RooRandom::randomGenerator() @@ -43,21 +51,27 @@ TRandom *RooRandom::randomGenerator() // Return a pointer to a singleton random-number generator // implementation. Creates the object the first time it is called. - static TRandom *_theGenerator= 0; - if(0 == _theGenerator) _theGenerator= new TRandom3(); + if (!_theGenerator) _theGenerator= new TRandom3(); return _theGenerator; } +//_____________________________________________________________________________ +void RooRandom::setRandomGenerator(TRandom* gen) +{ + // set the random number generator; takes ownership of the object passed as parameter + if (_theGenerator) delete _theGenerator; + _theGenerator = gen; +} + //_____________________________________________________________________________ RooQuasiRandomGenerator *RooRandom::quasiGenerator() { // Return a pointer to a singleton quasi-random generator // implementation. Creates the object the first time it is called. - static RooQuasiRandomGenerator *_theGenerator= 0; - if(0 == _theGenerator) _theGenerator= new RooQuasiRandomGenerator(); - return _theGenerator; + if(!_theQuasiGenerator) _theQuasiGenerator= new RooQuasiRandomGenerator(); + return _theQuasiGenerator; } @@ -74,8 +88,7 @@ Double_t RooRandom::uniform(TRandom *generator) void RooRandom::uniform(UInt_t dimension, Double_t vector[], TRandom *generator) { // Fill the vector provided with random numbers uniformly distributed from (0,1) - - for(UInt_t index= 0; index < dimension; index++) vector[index]= uniform(generator); + generator->RndmArray(dimension, vector); } diff --git a/roofit/roofitcore/src/RooRangeBinning.cxx b/roofit/roofitcore/src/RooRangeBinning.cxx index 401b87b8d06d0..ee78dc5f82c2c 100644 --- a/roofit/roofitcore/src/RooRangeBinning.cxx +++ b/roofit/roofitcore/src/RooRangeBinning.cxx @@ -33,6 +33,8 @@ #include "RooRangeBinning.h" +using namespace std; + ClassImp(RooRangeBinning) ; diff --git a/roofit/roofitcore/src/RooRangeBoolean.cxx b/roofit/roofitcore/src/RooRangeBoolean.cxx index 40524e75c10e8..5d4a681fd1e34 100644 --- a/roofit/roofitcore/src/RooRangeBoolean.cxx +++ b/roofit/roofitcore/src/RooRangeBoolean.cxx @@ -35,6 +35,8 @@ #include "RooMsgService.h" #include "TMath.h" +using namespace std; + ClassImp(RooRangeBoolean) ; diff --git a/roofit/roofitcore/src/RooRealAnalytic.cxx b/roofit/roofitcore/src/RooRealAnalytic.cxx index 3f785c6cf42da..fd78658700938 100644 --- a/roofit/roofitcore/src/RooRealAnalytic.cxx +++ b/roofit/roofitcore/src/RooRealAnalytic.cxx @@ -31,6 +31,8 @@ #include <assert.h> +using namespace std; + ClassImp(RooRealAnalytic) ; diff --git a/roofit/roofitcore/src/RooRealBinding.cxx b/roofit/roofitcore/src/RooRealBinding.cxx index e399a1d25b5ab..80dd6bd9817a2 100644 --- a/roofit/roofitcore/src/RooRealBinding.cxx +++ b/roofit/roofitcore/src/RooRealBinding.cxx @@ -37,13 +37,15 @@ +using namespace std; + ClassImp(RooRealBinding) ; //_____________________________________________________________________________ RooRealBinding::RooRealBinding(const RooAbsReal& func, const RooArgSet &vars, const RooArgSet* nset, Bool_t clipInvalid, const TNamed* rangeName) : - RooAbsFunc(vars.getSize()), _func(&func), _vars(0), _nset(nset), _clipInvalid(clipInvalid), _xsave(0), _rangeName(rangeName) + RooAbsFunc(vars.getSize()), _func(&func), _vars(0), _nset(nset), _clipInvalid(clipInvalid), _xsave(0), _rangeName(rangeName), _funcSave(0) { // Construct a lightweight function binding of RooAbsReal func to // variables 'vars'. Use the provided nset as normalization set to @@ -80,7 +82,7 @@ RooRealBinding::RooRealBinding(const RooAbsReal& func, const RooArgSet &vars, co //_____________________________________________________________________________ RooRealBinding::RooRealBinding(const RooRealBinding& other, const RooArgSet* nset) : RooAbsFunc(other), _func(other._func), _nset(nset?nset:other._nset), _xvecValid(other._xvecValid), - _clipInvalid(other._clipInvalid), _xsave(0), _rangeName(other._rangeName) + _clipInvalid(other._clipInvalid), _xsave(0), _rangeName(other._rangeName), _funcSave(other._funcSave) { // Construct a lightweight function binding of RooAbsReal func to // variables 'vars'. Use the provided nset as normalization set to @@ -118,13 +120,32 @@ void RooRealBinding::saveXVec() const if (!_xsave) { _xsave = new Double_t[getDimension()] ; - for (UInt_t i=0 ; i<getDimension() ; i++) { - _xsave[i] = _vars[i]->getVal() ; + RooArgSet* comps = _func->getComponents() ; + RooFIter iter = comps->fwdIterator() ; + RooAbsArg* arg ; + while ((arg=iter.next())) { + if (dynamic_cast<RooAbsReal*>(arg)) { + _compList.push_back((RooAbsReal*)(arg)) ; + _compSave.push_back(0) ; + } } + delete comps ; + } + _funcSave = _func->_value ; + + // Save components + list<RooAbsReal*>::iterator ci = _compList.begin() ; + list<Double_t>::iterator si = _compSave.begin() ; + while(ci!=_compList.end()) { + *si = (*ci)->_value ; + si++ ; ci++ ; } + + for (UInt_t i=0 ; i<getDimension() ; i++) { + _xsave[i] = _vars[i]->getVal() ; + } } - //_____________________________________________________________________________ void RooRealBinding::restoreXVec() const { @@ -134,6 +155,16 @@ void RooRealBinding::restoreXVec() const if (!_xsave) { return ; } + _func->_value = _funcSave ; + + // Restore components + list<RooAbsReal*>::iterator ci = _compList.begin() ; + list<Double_t>::iterator si = _compSave.begin() ; + while (ci!=_compList.end()) { + (*ci)->_value = *si ; + ci++ ; si++ ; + } + for (UInt_t i=0 ; i<getDimension() ; i++) { _vars[i]->setVal(_xsave[i]) ; } diff --git a/roofit/roofitcore/src/RooRealConstant.cxx b/roofit/roofitcore/src/RooRealConstant.cxx index be510f4fae61a..12b7936f005a8 100644 --- a/roofit/roofitcore/src/RooRealConstant.cxx +++ b/roofit/roofitcore/src/RooRealConstant.cxx @@ -39,6 +39,8 @@ #include "RooArgList.h" #include "RooSentinel.h" +using namespace std; + ClassImp(RooRealConstant) ; @@ -65,7 +67,7 @@ void RooRealConstant::cleanup() RooConstVar& RooRealConstant::value(Double_t value) { // Return a constant value object with given value. - // Return previously created object if avaliable, + // Return previously created object if available, // otherwise create a new one on the fly. // Lookup existing constant diff --git a/roofit/roofitcore/src/RooRealIntegral.cxx b/roofit/roofitcore/src/RooRealIntegral.cxx index 1cb8d9e8d3c4b..fc455f20950c1 100644 --- a/roofit/roofitcore/src/RooRealIntegral.cxx +++ b/roofit/roofitcore/src/RooRealIntegral.cxx @@ -50,6 +50,8 @@ #include "RooConstVar.h" #include "RooDouble.h" +using namespace std; + ClassImp(RooRealIntegral) ; @@ -264,6 +266,16 @@ RooRealIntegral::RooRealIntegral(const char *name, const char *title, } } } + + // Eliminate exclLVBranches that do not depend on any LVServer + bIter->Reset() ; + while((branch=(RooAbsArg*)bIter->Next())) { + if (!branch->dependsOnValue(exclLVServers)) { + //cout << "LV branch " << branch->GetName() << " does not depend on any LVServer (" << exclLVServers << ") and will be removed" << endl ; + exclLVBranches.remove(*branch,kTRUE,kTRUE) ; + } + } + delete sIter ; delete bIter ; @@ -759,6 +771,7 @@ RooRealIntegral::~RooRealIntegral() delete _facListIter ; delete _jacListIter ; if (_sumCatIter) delete _sumCatIter ; + if (_params) delete _params ; } diff --git a/roofit/roofitcore/src/RooRealMPFE.cxx b/roofit/roofitcore/src/RooRealMPFE.cxx index 88fb841be3f32..e35cabe195261 100644 --- a/roofit/roofitcore/src/RooRealMPFE.cxx +++ b/roofit/roofitcore/src/RooRealMPFE.cxx @@ -45,12 +45,10 @@ #include "RooFit.h" #ifndef _WIN32 -#include <unistd.h> -#include <sys/types.h> -#include <sys/wait.h> +#include "BidirMMapPipe.h" #endif -#include <errno.h> +#include <cstdlib> #include <sstream> #include "RooRealMPFE.h" #include "RooArgSet.h" @@ -60,11 +58,15 @@ #include "RooMPSentinel.h" #include "RooMsgService.h" #include "RooNLLVar.h" +#include "RooTrace.h" #include "TSystem.h" RooMPSentinel RooRealMPFE::_sentinel ; +using namespace std; +using namespace RooFit; + ClassImp(RooRealMPFE) ; @@ -80,7 +82,9 @@ RooRealMPFE::RooRealMPFE(const char *name, const char *title, RooAbsReal& arg, B _verboseServer(kFALSE), _inlineMode(calcInline), _remoteEvalErrorLoggingState(RooAbsReal::PrintErrors), - _pid(0) + _pipe(0), + _updateMaster(0), + _retrieveDispatched(kFALSE), _evalCarry(0.) { // Construct front-end object for object 'arg' whose evaluation will be calculated // asynchronously in a separate process. If calcInline is true the value of 'arg' @@ -90,6 +94,7 @@ RooRealMPFE::RooRealMPFE(const char *name, const char *title, RooAbsReal& arg, B #endif initVars() ; _sentinel.add(*this) ; + } @@ -106,7 +111,9 @@ RooRealMPFE::RooRealMPFE(const RooRealMPFE& other, const char* name) : _inlineMode(other._inlineMode), _forceCalc(other._forceCalc), _remoteEvalErrorLoggingState(other._remoteEvalErrorLoggingState), - _pid(0) + _pipe(0), + _updateMaster(0), + _retrieveDispatched(kFALSE), _evalCarry(other._evalCarry) { // Copy constructor. Initializes in clean state so that upon eval // this instance will create its own server processes @@ -122,10 +129,8 @@ RooRealMPFE::~RooRealMPFE() { // Destructor - if (_state==Client) { - standby() ; - } - _sentinel.remove(*this) ; + if (_state==Client) standby(); + _sentinel.remove(*this); } @@ -141,21 +146,32 @@ void RooRealMPFE::initVars() // Retrieve non-constant parameters RooArgSet* vars = _arg.arg().getParameters(RooArgSet()) ; - RooArgSet* ncVars = (RooArgSet*) vars->selectByAttrib("Constant",kFALSE) ; - RooArgList varList(*ncVars) ; + //RooArgSet* ncVars = (RooArgSet*) vars->selectByAttrib("Constant",kFALSE) ; + RooArgList varList(*vars) ; // Save in lists _vars.add(varList) ; _saveVars.addClone(varList) ; + _valueChanged.resize(_vars.getSize()) ; + _constChanged.resize(_vars.getSize()) ; // Force next calculation _forceCalc = kTRUE ; delete vars ; - delete ncVars ; + //delete ncVars ; } - +Double_t RooRealMPFE::getCarry() const +{ + if (_inlineMode) { + RooAbsTestStatistic* tmp = dynamic_cast<RooAbsTestStatistic*>(_arg.absArg()); + if (tmp) return tmp->getCarry(); + else return 0.; + } else { + return _evalCarry; + } +} //_____________________________________________________________________________ void RooRealMPFE::initialize() @@ -170,42 +186,32 @@ void RooRealMPFE::initialize() } #ifndef _WIN32 - // Fork server process and setup IPC - - // Make client/server pipes - UInt_t tmp1 = pipe(_pipeToClient) ; - UInt_t tmp2 = pipe(_pipeToServer) ; - if (tmp1 || tmp2) perror("pipe") ; - // Clear eval error log prior to forking // to avoid confusions... clearEvalErrorLog() ; - - _pid = fork() ; - - if (_pid==0) { - + // Fork server process and setup IPC + _pipe = new BidirMMapPipe(); + + if (_pipe->isChild()) { // Start server loop + RooTrace::callgrind_zero() ; _state = Server ; - serverLoop() ; - + serverLoop(); + // Kill server at end of service - coutI(Minimization) << "RooRealMPFE::initialize(" << GetName() - << ") server process terminating" << endl ; - _exit(0) ; + if (_verboseServer) ccoutD(Minimization) << "RooRealMPFE::initialize(" << + GetName() << ") server process terminating" << endl ; - } else if (_pid>0) { - + delete _arg.absArg(); + delete _pipe; + _exit(0) ; + } else { // Client process - fork successul - coutI(Minimization) << "RooRealMPFE::initialize(" << GetName() - << ") successfully forked server process " << _pid << endl ; + if (_verboseClient) ccoutD(Minimization) << "RooRealMPFE::initialize(" << + GetName() << ") successfully forked server process " << + _pipe->pidOtherEnd() << endl ; _state = Client ; _calcInProgress = kFALSE ; - - } else { - // Client process - fork failed - coutE(Minimization) << "RooRealMPFE::initialize(" << GetName() << ") ERROR fork() failed" << endl ; - _state = Inline ; } #endif // _WIN32 } @@ -219,8 +225,7 @@ void RooRealMPFE::serverLoop() // only when an incoming TERMINATE message is received. #ifndef _WIN32 - Bool_t doLoop(kTRUE) ; - Message msg ; + int msg ; Int_t idx, index, numErrors ; Double_t value ; @@ -228,75 +233,111 @@ void RooRealMPFE::serverLoop() clearEvalErrorLog() ; - while(doLoop) { - ssize_t n = read(_pipeToServer[0],&msg,sizeof(msg)) ; - if (n<0&&_verboseServer) perror("read") ; + while(*_pipe && !_pipe->eof()) { + *_pipe >> msg; + if (Terminate == msg) { + if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() + << ") IPC fromClient> Terminate" << endl; + // send terminate acknowledged to client + *_pipe << msg << BidirMMapPipe::flush; + break; + } switch (msg) { case SendReal: { - UInt_t tmp1 = read(_pipeToServer[0],&idx,sizeof(Int_t)) ; - UInt_t tmp2 = read(_pipeToServer[0],&value,sizeof(Double_t)) ; - UInt_t tmp3 = read(_pipeToServer[0],&isConst,sizeof(Bool_t)) ; - if (tmp1+tmp2+tmp3<sizeof(Int_t)+sizeof(Double_t)+sizeof(Bool_t)) perror("read") ; - if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() - << ") IPC fromClient> SendReal [" << idx << "]=" << value << endl ; - ((RooRealVar*)_vars.at(idx))->setVal(value) ; - ((RooRealVar*)_vars.at(idx))->setConstant(isConst) ; + *_pipe >> idx >> value >> isConst; + if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() + << ") IPC fromClient> SendReal [" << idx << "]=" << value << endl ; + RooRealVar* rvar = (RooRealVar*)_vars.at(idx) ; + rvar->setVal(value) ; + if (rvar->isConstant() != isConst) { + rvar->setConstant(isConst) ; + } } break ; case SendCat: { - UInt_t tmp1 = read(_pipeToServer[0],&idx,sizeof(Int_t)) ; - UInt_t tmp2 = read(_pipeToServer[0],&index,sizeof(Int_t)) ; - if (tmp1+tmp2<sizeof(Int_t)+sizeof(Int_t)) perror("read") ; - if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() - << ") IPC fromClient> SendCat [" << idx << "]=" << index << endl ; - ((RooCategory*)_vars.at(idx))->setIndex(index) ; + *_pipe >> idx >> index; + if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() + << ") IPC fromClient> SendCat [" << idx << "]=" << index << endl ; + ((RooCategory*)_vars.at(idx))->setIndex(index) ; } break ; case Calculate: if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() - << ") IPC fromClient> Calculate" << endl ; + << ") IPC fromClient> Calculate" << endl ; _value = _arg ; break ; - case Retrieve: - { + case CalculateNoOffset: if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() - << ") IPC fromClient> Retrieve" << endl ; - msg = ReturnValue ; - UInt_t tmp1 = write(_pipeToClient[1],&msg,sizeof(Message)) ; - UInt_t tmp2 = write(_pipeToClient[1],&_value,sizeof(Double_t)) ; - numErrors = numEvalErrors() ; - UInt_t tmp3 = write(_pipeToClient[1],&numErrors,sizeof(Int_t)) ; - if (tmp1+tmp2+tmp3<sizeof(Message)+sizeof(Double_t)+sizeof(Int_t)) perror("write") ; + << ") IPC fromClient> Calculate" << endl ; - if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() - << ") IPC toClient> ReturnValue " << _value << " NumError " << numErrors << endl ; - } + RooAbsReal::setHideOffset(kFALSE) ; + _value = _arg ; + RooAbsReal::setHideOffset(kTRUE) ; break ; + case Retrieve: + { + if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() + << ") IPC fromClient> Retrieve" << endl ; + msg = ReturnValue; + numErrors = numEvalErrors(); + *_pipe << msg << _value << getCarry() << numErrors; + + if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() + << ") IPC toClient> ReturnValue " << _value << " NumError " << numErrors << endl ; + + if (numErrors) { + // Loop over errors + std::string objidstr; + { + ostringstream oss2; + // Format string with object identity as this cannot be evaluated on the other side + oss2 << "PID" << gSystem->GetPid() << "/"; + printStream(oss2,kName|kClassName|kArgs,kInline); + objidstr = oss2.str(); + } + std::map<const RooAbsArg*,pair<string,list<EvalError> > >::const_iterator iter = evalErrorIter(); + const RooAbsArg* ptr = 0; + for (int i = 0; i < numEvalErrorItems(); ++i) { + list<EvalError>::const_iterator iter2 = iter->second.second.begin(); + for (; iter->second.second.end() != iter2; ++iter2) { + ptr = iter->first; + *_pipe << ptr << iter2->_msg << iter2->_srvval << objidstr; + if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() + << ") IPC toClient> sending error log Arg " << iter->first << " Msg " << iter2->_msg << endl ; + } + } + // let other end know that we're done with the list of errors + ptr = 0; + *_pipe << ptr; + // Clear error list on local side + clearEvalErrorLog(); + } + *_pipe << BidirMMapPipe::flush; + } + break; + case ConstOpt: { - ConstOpCode code ; - Bool_t doTrack ; - UInt_t tmp1 = read(_pipeToServer[0],&code,sizeof(ConstOpCode)) ; - UInt_t tmp2 = read(_pipeToServer[0],&doTrack,sizeof(Bool_t)) ; - if ((tmp1+tmp2)<sizeof(ConstOpCode)) perror("read") ; - if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() - << ") IPC fromClient> ConstOpt " << code << " doTrack = " << (doTrack?"T":"F") << endl ; - ((RooAbsReal&)_arg.arg()).constOptimizeTestStatistic(code,doTrack) ; - break ; + Bool_t doTrack ; + int code; + *_pipe >> code >> doTrack; + if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() + << ") IPC fromClient> ConstOpt " << code << " doTrack = " << (doTrack?"T":"F") << endl ; + ((RooAbsReal&)_arg.arg()).constOptimizeTestStatistic(static_cast<RooAbsArg::ConstOpCode>(code),doTrack) ; + break ; } case Verbose: { Bool_t flag ; - UInt_t tmp1 = read(_pipeToServer[0],&flag,sizeof(Bool_t)) ; - if (tmp1<sizeof(Bool_t)) perror("read") ; + *_pipe >> flag; if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() << ") IPC fromClient> Verbose " << (flag?1:0) << endl ; _verboseServer = flag ; @@ -307,8 +348,7 @@ void RooRealMPFE::serverLoop() case ApplyNLLW2: { Bool_t flag ; - UInt_t tmp1 = read(_pipeToServer[0],&flag,sizeof(Bool_t)) ; - if (tmp1<sizeof(Bool_t)) perror("read") ; + *_pipe >> flag; if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() << ") IPC fromClient> ApplyNLLW2 " << (flag?1:0) << endl ; @@ -317,81 +357,37 @@ void RooRealMPFE::serverLoop() } break ; - case Terminate: - if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() - << ") IPC fromClient> Terminate" << endl ; - doLoop = kFALSE ; - break ; - - case LogEvalError: + case EnableOffset: { - RooAbsReal::ErrorLoggingMode flag2 ; - UInt_t tmp1 = read(_pipeToServer[0],&flag2,sizeof(RooAbsReal::ErrorLoggingMode)) ; - if (tmp1<sizeof(RooAbsReal::ErrorLoggingMode)) perror("read") ; - RooAbsReal::setEvalErrorLoggingMode(flag2) ; + Bool_t flag ; + *_pipe >> flag; if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() - << ") IPC fromClient> LogEvalError flag = " << flag2 << endl ; + << ") IPC fromClient> EnableOffset " << (flag?1:0) << endl ; + + // Enable likelihoof offsetting here + ((RooAbsReal&)_arg.arg()).enableOffsetting(flag) ; } break ; - case RetrieveErrors: - - if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() - << ") IPC fromClient> RetrieveErrors" << endl ; - - // Loop over errors + case LogEvalError: { - std::map<const RooAbsArg*,pair<string,list<EvalError> > >::const_iterator iter = evalErrorIter() ; - for (int i=0 ; i<numEvalErrorItems() ; i++) { - list<EvalError>::const_iterator iter2 = iter->second.second.begin() ; - for (;iter2!=iter->second.second.end();++iter2) { - - // Reply with SendError message - msg = SendError ; - UInt_t tmp1 = write(_pipeToClient[1],&msg,sizeof(Message)) ; - UInt_t tmp2 = write(_pipeToClient[1],&iter->first,sizeof(RooAbsReal*)) ; - - UInt_t ntext = strlen(iter2->_msg) ; - UInt_t tmp3 = write(_pipeToClient[1],&ntext,sizeof(Int_t)) ; - UInt_t tmp4 = write(_pipeToClient[1],iter2->_msg,ntext+1) ; - - UInt_t ntext2 = strlen(iter2->_srvval) ; - UInt_t tmp5 = write(_pipeToClient[1],&ntext2,sizeof(Int_t)) ; - UInt_t tmp6 = write(_pipeToClient[1],iter2->_srvval,ntext2+1) ; - - // Format string with object identity as this cannot be evaluated on the other side - ostringstream oss2 ; - oss2 << "PID" << gSystem->GetPid() << "/" ; - printStream(oss2,kName|kClassName|kArgs,kInline) ; - UInt_t ntext3 = strlen(oss2.str().c_str()) ; - UInt_t tmp7 = write(_pipeToClient[1],&ntext3,sizeof(Int_t)) ; - UInt_t tmp8 = write(_pipeToClient[1],oss2.str().c_str(),ntext3+1) ; - - if (tmp1+tmp2+tmp3+tmp4+tmp5+tmp6+tmp7+tmp8< - sizeof(Message)+sizeof(RooAbsReal*)+sizeof(Int_t)+ntext+1+sizeof(Int_t)+ntext2+1+sizeof(Int_t)+ntext3+1) - perror("write") ; - - if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() - << ") IPC toClient> SendError Arg " << iter->first << " Msg " << iter2->_msg << endl ; - } - } - - RooAbsReal* null(0) ; - UInt_t tmp1 = write(_pipeToClient[1],&msg,sizeof(Message)) ; - UInt_t tmp2 = write(_pipeToClient[1],&null,sizeof(RooAbsReal*)) ; - if (tmp1+tmp2<sizeof(Message)+sizeof(RooAbsReal*)) perror("read") ; - + int iflag2; + *_pipe >> iflag2; + RooAbsReal::ErrorLoggingMode flag2 = static_cast<RooAbsReal::ErrorLoggingMode>(iflag2); + RooAbsReal::setEvalErrorLoggingMode(flag2) ; + if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() + << ") IPC fromClient> LogEvalError flag = " << flag2 << endl ; } - // Clear error list on local side - clearEvalErrorLog() ; break ; + default: if (_verboseServer) cout << "RooRealMPFE::serverLoop(" << GetName() << ") IPC fromClient> Unknown message (code = " << msg << ")" << endl ; break ; } } + #endif // _WIN32 } @@ -405,14 +401,16 @@ void RooRealMPFE::calculate() const // returns immediately. The calculated value can be retrieved // using getVal() + // Start asynchronous calculation of arg value if (_state==Initialize) { + // cout << "RooRealMPFE::calculate(" << GetName() << ") initializing" << endl ; const_cast<RooRealMPFE*>(this)->initialize() ; } // Inline mode -- Calculate value now if (_state==Inline) { - //cout << "RooRealMPFE::calculate(" << GetName() << ") performing Inline calculation NOW" << endl ; + // cout << "RooRealMPFE::calculate(" << GetName() << ") performing Inline calculation NOW" << endl ; _value = _arg ; clearValueDirty() ; } @@ -420,47 +418,59 @@ void RooRealMPFE::calculate() const #ifndef _WIN32 // Compare current value of variables with saved values and send changes to server if (_state==Client) { - Int_t i ; - for (i=0 ; i<_vars.getSize() ; i++) { - RooAbsArg* var = _vars.at(i) ; - RooAbsArg* saveVar = _saveVars.at(i) ; - - if (!(*var==*saveVar) || (var->isConstant() != saveVar->isConstant()) || _forceCalc) { + // cout << "RooRealMPFE::calculate(" << GetName() << ") state is Client trigger remote calculation" << endl ; + Int_t i(0) ; + RooFIter viter = _vars.fwdIterator() ; + RooFIter siter = _saveVars.fwdIterator() ; + + //for (i=0 ; i<_vars.getSize() ; i++) { + RooAbsArg *var, *saveVar ; + while((var = viter.next())) { + saveVar = siter.next() ; + + //Bool_t valChanged = !(*var==*saveVar) ; + Bool_t valChanged,constChanged ; + if (!_updateMaster) { + valChanged = !var->isIdentical(*saveVar,kTRUE) ; + constChanged = (var->isConstant() != saveVar->isConstant()) ; + _valueChanged[i] = valChanged ; + _constChanged[i] = constChanged ; + } else { + valChanged = _updateMaster->_valueChanged[i] ; + constChanged = _updateMaster->_constChanged[i] ; + } + + if ( valChanged || constChanged || _forceCalc) { + //cout << "RooRealMPFE::calculate(" << GetName() << " variable " << var->GetName() << " changed " << endl ; if (_verboseClient) cout << "RooRealMPFE::calculate(" << GetName() << ") variable " << _vars.at(i)->GetName() << " changed" << endl ; - - ((RooRealVar*)saveVar)->setConstant(var->isConstant()) ; + if (constChanged) { + ((RooRealVar*)saveVar)->setConstant(var->isConstant()) ; + } saveVar->copyCache(var) ; // send message to server if (dynamic_cast<RooAbsReal*>(var)) { - Message msg = SendReal ; + int msg = SendReal ; Double_t val = ((RooAbsReal*)var)->getVal() ; Bool_t isC = var->isConstant() ; - UInt_t tmp1 = write(_pipeToServer[1],&msg,sizeof(msg)) ; - UInt_t tmp2 = write(_pipeToServer[1],&i,sizeof(Int_t)) ; - UInt_t tmp3 = write(_pipeToServer[1],&val,sizeof(Double_t)) ; - UInt_t tmp4 = write(_pipeToServer[1],&isC,sizeof(Bool_t)) ; - if (tmp1+tmp2+tmp3+tmp4<sizeof(Message)+sizeof(Int_t)+sizeof(Double_t)+sizeof(Bool_t)) perror("write") ; + *_pipe << msg << i << val << isC; if (_verboseServer) cout << "RooRealMPFE::calculate(" << GetName() << ") IPC toServer> SendReal [" << i << "]=" << val << (isC?" (Constant)":"") << endl ; } else if (dynamic_cast<RooAbsCategory*>(var)) { - Message msg = SendCat ; + int msg = SendCat ; UInt_t idx = ((RooAbsCategory*)var)->getIndex() ; - UInt_t tmp5 = write(_pipeToServer[1],&msg,sizeof(msg)) ; - UInt_t tmp6 = write(_pipeToServer[1],&i,sizeof(Int_t)) ; - UInt_t tmp7 = write(_pipeToServer[1],&idx,sizeof(Int_t)) ; - if (tmp5+tmp6+tmp7<sizeof(Message)+sizeof(Int_t)+sizeof(Int_t)) perror("write") ; + *_pipe << msg << i << idx; if (_verboseServer) cout << "RooRealMPFE::calculate(" << GetName() << ") IPC toServer> SendCat [" << i << "]=" << idx << endl ; } } + i++ ; } - Message msg = Calculate ; - UInt_t tmp8 = write(_pipeToServer[1],&msg,sizeof(msg)) ; - if (tmp8<sizeof(Message)) perror("write") ; + int msg = hideOffset() ? Calculate : CalculateNoOffset; + *_pipe << msg; if (_verboseServer) cout << "RooRealMPFE::calculate(" << GetName() << ") IPC toServer> Calculate " << endl ; @@ -469,10 +479,18 @@ void RooRealMPFE::calculate() const _calcInProgress = kTRUE ; _forceCalc = kFALSE ; + msg = Retrieve ; + *_pipe << msg << BidirMMapPipe::flush; + if (_verboseServer) cout << "RooRealMPFE::evaluate(" << GetName() + << ") IPC toServer> Retrieve " << endl ; + _retrieveDispatched = kTRUE ; + } else if (_state!=Inline) { cout << "RooRealMPFE::calculate(" << GetName() << ") ERROR not in Client or Inline mode" << endl ; } + + #endif // _WIN32 } @@ -486,6 +504,7 @@ Double_t RooRealMPFE::getValV(const RooArgSet* /*nset*/) const // with a call to calculate() start it now. This function blocks // until remote process has finished calculation and returns // remote value + if (isValueDirty()) { // Cache is dirty, no calculation has been started yet @@ -501,7 +520,8 @@ Double_t RooRealMPFE::getValV(const RooArgSet* /*nset*/) const // Cache is clean and calculated value is in cache } - return _value ; +// cout << "RooRealMPFE::getValV(" << GetName() << ") value = " << Form("%5.10f",_value) << endl ; + return _value ; } @@ -519,83 +539,61 @@ Double_t RooRealMPFE::evaluate() const return_value = _arg ; } else if (_state==Client) { #ifndef _WIN32 - Message msg ; - Double_t value ; + bool needflush = false; + int msg; + Double_t value; // If current error loggin state is not the same as remote state // update the remote state if (evalErrorLoggingMode() != _remoteEvalErrorLoggingState) { msg = LogEvalError ; - UInt_t tmp1 = write(_pipeToServer[1],&msg,sizeof(Message)) ; RooAbsReal::ErrorLoggingMode flag = evalErrorLoggingMode() ; - UInt_t tmp2 = write(_pipeToServer[1],&flag,sizeof(RooAbsReal::ErrorLoggingMode)) ; + *_pipe << msg << flag; + needflush = true; _remoteEvalErrorLoggingState = evalErrorLoggingMode() ; - if (tmp1+tmp2<sizeof(Message)+sizeof(RooAbsReal::ErrorLoggingMode)) perror("write") ; } - msg = Retrieve ; - UInt_t tmp1 = write(_pipeToServer[1],&msg,sizeof(Message)) ; - if (_verboseServer) cout << "RooRealMPFE::evaluate(" << GetName() - << ") IPC toServer> Retrieve " << endl ; - if (tmp1<sizeof(Message)) perror("write") ; + if (!_retrieveDispatched) { + msg = Retrieve ; + *_pipe << msg; + needflush = true; + if (_verboseServer) cout << "RooRealMPFE::evaluate(" << GetName() + << ") IPC toServer> Retrieve " << endl ; + } + if (needflush) *_pipe << BidirMMapPipe::flush; + _retrieveDispatched = kFALSE ; - UInt_t tmp2 = read(_pipeToClient[0],&msg,sizeof(Message)) ; + + Int_t numError; + + *_pipe >> msg >> value >> _evalCarry >> numError; + if (msg!=ReturnValue) { cout << "RooRealMPFE::evaluate(" << GetName() << ") ERROR: unexpected message from server process: " << msg << endl ; return 0 ; } - UInt_t tmp3 = read(_pipeToClient[0],&value,sizeof(Double_t)) ; if (_verboseServer) cout << "RooRealMPFE::evaluate(" << GetName() << ") IPC fromServer> ReturnValue " << value << endl ; - Int_t numError ; - UInt_t tmp4 = read(_pipeToClient[0],&numError,sizeof(Int_t)) ; if (_verboseServer) cout << "RooRealMPFE::evaluate(" << GetName() << ") IPC fromServer> NumErrors " << numError << endl ; - if (tmp2+tmp3+tmp4<sizeof(Message)+sizeof(Double_t)+sizeof(Int_t)) perror("read") ; - - - // Retrieve remote errors and feed into local error queue - if (numError>0) { - msg=RetrieveErrors ; - UInt_t tmp5 = write(_pipeToServer[1],&msg,sizeof(Message)) ; - if (tmp5<sizeof(Message)) perror("write") ; - if (_verboseServer) cout << "RooRealMPFE::evaluate(" << GetName() - << ") IPC toServer> RetrieveErrors " << endl ; - - while(true) { - RooAbsReal* ptr(0) ; - Int_t ntext1,ntext2,ntext3 ; - char msgbuf1[1024] ; - char msgbuf2[1024] ; - char msgbuf3[1024] ; - UInt_t tmp12= read(_pipeToClient[0],&msg,sizeof(Message)) ; - UInt_t tmp13= read(_pipeToClient[0],&ptr,sizeof(RooAbsReal*)) ; - if (tmp12+tmp13<sizeof(Message)+sizeof(RooAbsReal*)) perror("read") ; - if (ptr==0) { - break ; - } - - UInt_t tmp6 = read(_pipeToClient[0],&ntext1,sizeof(Int_t)) ; - if (ntext1>1023) ntext1=1023 ; if (ntext1<0) ntext1=0 ; - UInt_t tmp7 = read(_pipeToClient[0],msgbuf1,ntext1+1) ; - UInt_t tmp8 = read(_pipeToClient[0],&ntext2,sizeof(Int_t)) ; - if (ntext2>1023) ntext2=1023 ; if (ntext2<0) ntext2=0 ; - UInt_t tmp9 = read(_pipeToClient[0],msgbuf2,ntext2+1) ; - UInt_t tmp10= read(_pipeToClient[0],&ntext3,sizeof(Int_t)) ; - if (ntext3>1023) ntext3=1023 ; if (ntext3<0) ntext3=0 ; - UInt_t tmp11= read(_pipeToClient[0],msgbuf3,ntext3+1) ; - if (tmp6+tmp7+tmp8+tmp9+tmp10+tmp11<sizeof(Int_t)+ntext1+1+sizeof(Int_t)+ntext2+1+sizeof(Int_t)+ntext3+1) perror("read") ; - + if (numError) { + // Retrieve remote errors and feed into local error queue + char *msgbuf1 = 0, *msgbuf2 = 0, *msgbuf3 = 0; + RooAbsArg *ptr = 0; + while (true) { + *_pipe >> ptr; + if (!ptr) break; + *_pipe >> msgbuf1 >> msgbuf2 >> msgbuf3; if (_verboseServer) cout << "RooRealMPFE::evaluate(" << GetName() - << ") IPC fromServer> SendError Arg " << ptr << " Msg " << msgbuf1 << endl ; - - // WVE: null char is read from pipe - // coverity[STRING_NULL] - logEvalError(ptr,msgbuf3,msgbuf1,msgbuf2) ; + << ") IPC fromServer> retrieving error log Arg " << ptr << " Msg " << msgbuf1 << endl ; + + logEvalError(reinterpret_cast<RooAbsReal*>(ptr),msgbuf3,msgbuf1,msgbuf2) ; } - + std::free(msgbuf1); + std::free(msgbuf2); + std::free(msgbuf3); } // Mark end of calculation in progress @@ -618,25 +616,32 @@ void RooRealMPFE::standby() #ifndef _WIN32 if (_state==Client) { - - // Terminate server process ; - Message msg = Terminate ; - UInt_t tmp1 = write(_pipeToServer[1],&msg,sizeof(msg)) ; - if (tmp1<sizeof(Message)) perror("write") ; - if (_verboseServer) cout << "RooRealMPFE::standby(" << GetName() - << ") IPC toServer> Terminate " << endl ; - + if (_pipe->good()) { + // Terminate server process ; + if (_verboseServer) cout << "RooRealMPFE::standby(" << GetName() + << ") IPC toServer> Terminate " << endl; + int msg = Terminate; + *_pipe << msg << BidirMMapPipe::flush; + // read handshake + msg = 0; + *_pipe >> msg; + if (Terminate != msg || 0 != _pipe->close()) { + std::cerr << "In " << __func__ << "(" << __FILE__ ", " << __LINE__ << + "): Server shutdown failed." << std::endl; + } + } else { + if (_verboseServer) { + std::cerr << "In " << __func__ << "(" << __FILE__ ", " << + __LINE__ << "): Pipe has already shut down, not sending " + "Terminate to server." << std::endl; + } + } // Close pipes - close(_pipeToClient[0]) ; - close(_pipeToClient[1]) ; - close(_pipeToServer[0]) ; - close(_pipeToServer[1]) ; - - // Release resource of child process - waitpid(_pid,0,0) ; + delete _pipe; + _pipe = 0; // Revert to initialize state - _state = Initialize ; + _state = Initialize; } #endif // _WIN32 } @@ -651,11 +656,10 @@ void RooRealMPFE::constOptimizeTestStatistic(ConstOpCode opcode, Bool_t doAlsoTr #ifndef _WIN32 if (_state==Client) { - Message msg = ConstOpt ; - UInt_t tmp1 = write(_pipeToServer[1],&msg,sizeof(msg)) ; - UInt_t tmp2 = write(_pipeToServer[1],&opcode,sizeof(ConstOpCode)) ; - UInt_t tmp3 = write(_pipeToServer[1],&doAlsoTracking,sizeof(Bool_t)) ; - if (tmp1+tmp2+tmp3<sizeof(Message)+sizeof(ConstOpCode)+sizeof(Bool_t)) perror("write") ; + + int msg = ConstOpt ; + int op = opcode; + *_pipe << msg << op << doAlsoTracking; if (_verboseServer) cout << "RooRealMPFE::constOptimize(" << GetName() << ") IPC toServer> ConstOpt " << opcode << endl ; @@ -664,7 +668,7 @@ void RooRealMPFE::constOptimizeTestStatistic(ConstOpCode opcode, Bool_t doAlsoTr #endif // _WIN32 if (_state==Inline) { - ((RooAbsReal&)_arg.arg()).constOptimizeTestStatistic(opcode) ; + ((RooAbsReal&)_arg.arg()).constOptimizeTestStatistic(opcode,doAlsoTracking) ; } } @@ -678,10 +682,8 @@ void RooRealMPFE::setVerbose(Bool_t clientFlag, Bool_t serverFlag) #ifndef _WIN32 if (_state==Client) { - Message msg = Verbose ; - UInt_t tmp1 = write(_pipeToServer[1],&msg,sizeof(msg)) ; - UInt_t tmp2 = write(_pipeToServer[1],&serverFlag,sizeof(Bool_t)) ; - if (tmp1+tmp2<sizeof(Message)+sizeof(Bool_t)) perror("write") ; + int msg = Verbose ; + *_pipe << msg << serverFlag; if (_verboseServer) cout << "RooRealMPFE::setVerbose(" << GetName() << ") IPC toServer> Verbose " << (serverFlag?1:0) << endl ; } @@ -698,11 +700,9 @@ void RooRealMPFE::applyNLLWeightSquared(Bool_t flag) #ifndef _WIN32 if (_state==Client) { - Message msg = ApplyNLLW2 ; - UInt_t tmp1 = write(_pipeToServer[1],&msg,sizeof(msg)) ; - UInt_t tmp2 = write(_pipeToServer[1],&flag,sizeof(Bool_t)) ; - if (tmp1+tmp2<sizeof(Message)+sizeof(Bool_t)) perror("write") ; - if (_verboseServer) cout << "RooRealMPFE::setVerbose(" << GetName() + int msg = ApplyNLLW2 ; + *_pipe << msg << flag; + if (_verboseServer) cout << "RooRealMPFE::applyNLLWeightSquared(" << GetName() << ") IPC toServer> ApplyNLLW2 " << (flag?1:0) << endl ; } #endif // _WIN32 @@ -710,7 +710,6 @@ void RooRealMPFE::applyNLLWeightSquared(Bool_t flag) } - //_____________________________________________________________________________ void RooRealMPFE::doApplyNLLW2(Bool_t flag) { @@ -719,3 +718,24 @@ void RooRealMPFE::doApplyNLLW2(Bool_t flag) nll->applyWeightSquared(flag) ; } } + + +//_____________________________________________________________________________ +void RooRealMPFE::enableOffsetting(Bool_t flag) +{ + // Control verbose messaging related to inter process communication + // on both client and server side + +#ifndef _WIN32 + if (_state==Client) { + int msg = EnableOffset ; + *_pipe << msg << flag; + if (_verboseServer) cout << "RooRealMPFE::enableOffsetting(" << GetName() + << ") IPC toServer> EnableOffset " << (flag?1:0) << endl ; + } +#endif // _WIN32 + ((RooAbsReal&)_arg.arg()).enableOffsetting(flag) ; +} + + + diff --git a/roofit/roofitcore/src/RooRealProxy.cxx b/roofit/roofitcore/src/RooRealProxy.cxx index 63c8309e90538..c784f5c4ec74b 100644 --- a/roofit/roofitcore/src/RooRealProxy.cxx +++ b/roofit/roofitcore/src/RooRealProxy.cxx @@ -33,6 +33,8 @@ #include "RooRealProxy.h" #include "RooRealVar.h" +using namespace std; + ClassImp(RooRealProxy) ; diff --git a/roofit/roofitcore/src/RooRealSumPdf.cxx b/roofit/roofitcore/src/RooRealSumPdf.cxx index 9ca88fed4b380..1f302f0a45384 100644 --- a/roofit/roofitcore/src/RooRealSumPdf.cxx +++ b/roofit/roofitcore/src/RooRealSumPdf.cxx @@ -42,12 +42,16 @@ #include "RooRealIntegral.h" #include "RooMsgService.h" #include "RooNameReg.h" +#include "RooTrace.h" #include <memory> #include <algorithm> +using namespace std; + ClassImp(RooRealSumPdf) ; +Bool_t RooRealSumPdf::_doFloorGlobal = kFALSE ; //_____________________________________________________________________________ RooRealSumPdf::RooRealSumPdf() @@ -57,6 +61,8 @@ RooRealSumPdf::RooRealSumPdf() _funcIter = _funcList.createIterator() ; _coefIter = _coefList.createIterator() ; _extended = kFALSE ; + _doFloor = kFALSE ; + TRACE_CREATE } @@ -68,11 +74,13 @@ RooRealSumPdf::RooRealSumPdf(const char *name, const char *title) : _haveLastCoef(kFALSE), _funcList("!funcList","List of functions",this), _coefList("!coefList","List of coefficients",this), - _extended(kFALSE) + _extended(kFALSE), + _doFloor(kFALSE) { // Constructor with name and title _funcIter = _funcList.createIterator() ; _coefIter = _coefList.createIterator() ; + TRACE_CREATE } @@ -85,7 +93,8 @@ RooRealSumPdf::RooRealSumPdf(const char *name, const char *title, _haveLastCoef(kFALSE), _funcList("!funcList","List of functions",this), _coefList("!coefList","List of coefficients",this), - _extended(kFALSE) + _extended(kFALSE), + _doFloor(kFALSE) { // Construct p.d.f consisting of coef1*func1 + (1-coef1)*func2 // The input coefficients and functions are allowed to be negative @@ -98,6 +107,7 @@ RooRealSumPdf::RooRealSumPdf(const char *name, const char *title, _funcList.add(func1) ; _funcList.add(func2) ; _coefList.add(coef1) ; + TRACE_CREATE } @@ -109,7 +119,8 @@ RooRealSumPdf::RooRealSumPdf(const char *name, const char *title, const RooArgLi _haveLastCoef(kFALSE), _funcList("!funcList","List of functions",this), _coefList("!coefList","List of coefficients",this), - _extended(extended) + _extended(extended), + _doFloor(kFALSE) { // Constructor p.d.f implementing sum_i [ coef_i * func_i ], if N_coef==N_func // or sum_i [ coef_i * func_i ] + (1 - sum_i [ coef_i ] )* func_N if Ncoef==N_func-1 @@ -160,6 +171,7 @@ RooRealSumPdf::RooRealSumPdf(const char *name, const char *title, const RooArgLi delete funcIter ; delete coefIter ; + TRACE_CREATE } @@ -172,12 +184,14 @@ RooRealSumPdf::RooRealSumPdf(const RooRealSumPdf& other, const char* name) : _haveLastCoef(other._haveLastCoef), _funcList("!funcList",this,other._funcList), _coefList("!coefList",this,other._coefList), - _extended(other._extended) + _extended(other._extended), + _doFloor(other._doFloor) { // Copy constructor _funcIter = _funcList.createIterator() ; _coefIter = _coefList.createIterator() ; + TRACE_CREATE } @@ -188,6 +202,8 @@ RooRealSumPdf::~RooRealSumPdf() // Destructor delete _funcIter ; delete _coefIter ; + + TRACE_DESTROY } @@ -222,7 +238,7 @@ Double_t RooRealSumPdf::evaluate() const func = (RooAbsReal*)funcIter.next() ; Double_t coefVal = coef->getVal() ; if (coefVal) { - cxcoutD(Eval) << "RooRealSumPdf::eval(" << GetName() << ") coefVal = " << coefVal << " funcVal = " << func->getVal() << endl ; + cxcoutD(Eval) << "RooRealSumPdf::eval(" << GetName() << ") coefVal = " << coefVal << " funcVal = " << func->IsA()->GetName() << "::" << func->GetName() << " = " << func->getVal() << endl ; if (func->isSelectedComp()) { value += func->getVal()*coefVal ; } @@ -247,6 +263,11 @@ Double_t RooRealSumPdf::evaluate() const } } + // Introduce floor if so requested + if (value<0 && (_doFloor || _doFloorGlobal)) { + value = 0 ; + } + return value ; } @@ -381,8 +402,8 @@ Double_t RooRealSumPdf::analyticalIntegralWN(Int_t code, const RooArgSet* normSe Double_t coefVal = coef->getVal(normSet2) ; if (coefVal) { assert(func); - if (func->isSelectedComp()) { - assert(funcInt); + if (normSet2 ==0 || func->isSelectedComp()) { + assert(funcInt); value += funcInt->getVal()*coefVal ; } lastCoef -= coef->getVal(normSet2) ; @@ -392,7 +413,7 @@ Double_t RooRealSumPdf::analyticalIntegralWN(Int_t code, const RooArgSet* normSe if (!_haveLastCoef) { // Add last func with correct coefficient funcInt = (RooAbsReal*) funcIntIter.next() ; - if (func->isSelectedComp()) { + if (normSet2 ==0 || func->isSelectedComp()) { assert(funcInt); value += funcInt->getVal()*lastCoef ; } @@ -437,7 +458,6 @@ Double_t RooRealSumPdf::analyticalIntegralWN(Int_t code, const RooArgSet* normSe //_____________________________________________________________________________ Double_t RooRealSumPdf::expectedEvents(const RooArgSet* nset) const { - // return getNorm(nset) ; Double_t n = getNorm(nset) ; if (n<0) { logEvalError("Expected number of events is negative") ; diff --git a/roofit/roofitcore/src/RooRealVar.cxx b/roofit/roofitcore/src/RooRealVar.cxx index d41f9463db0c7..a1fda0a6f2ac7 100644 --- a/roofit/roofitcore/src/RooRealVar.cxx +++ b/roofit/roofitcore/src/RooRealVar.cxx @@ -45,6 +45,8 @@ #include "RooVectorDataStore.h" +using namespace std; + ClassImp(RooRealVar) ; @@ -299,7 +301,30 @@ RooAbsBinning& RooRealVar::getBinning(const char* name, Bool_t verbose, Bool_t c return *binning ; } +//_____________________________________________________________________________ +std::list<std::string> RooRealVar::getBinningNames() const +{ + // Get a list of all binning names. An empty name implies the default binning and + // a NULL pointer should be passed to getBinning in this case. + std::list<std::string> binningNames; + if (_binning) { + binningNames.push_back(""); + } + RooFIter iter = _altNonSharedBinning.fwdIterator(); + const RooAbsArg* binning = 0; + while((binning = iter.next())) { + const char* name = binning->GetName(); + binningNames.push_back(string(name)); + } + iter = sharedProp()->_altBinning.fwdIterator(); + binning = 0; + while((binning = iter.next())) { + const char* name = binning->GetName(); + binningNames.push_back(string(name)); + } + return binningNames; +} //_____________________________________________________________________________ void RooRealVar::setBinning(const RooAbsBinning& binning, const char* name) diff --git a/roofit/roofitcore/src/RooRealVarSharedProperties.cxx b/roofit/roofitcore/src/RooRealVarSharedProperties.cxx index 6c409aef10b42..bcb044a538d40 100644 --- a/roofit/roofitcore/src/RooRealVarSharedProperties.cxx +++ b/roofit/roofitcore/src/RooRealVarSharedProperties.cxx @@ -28,6 +28,8 @@ #include "Riostream.h" +using namespace std; + ClassImp(RooRealVarSharedProperties) ; diff --git a/roofit/roofitcore/src/RooRecursiveFraction.cxx b/roofit/roofitcore/src/RooRecursiveFraction.cxx index 1438856461563..9f1131fc165c5 100644 --- a/roofit/roofitcore/src/RooRecursiveFraction.cxx +++ b/roofit/roofitcore/src/RooRecursiveFraction.cxx @@ -40,6 +40,8 @@ #include "RooChi2Var.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooRecursiveFraction) ; diff --git a/roofit/roofitcore/src/RooRefCountList.cxx b/roofit/roofitcore/src/RooRefCountList.cxx index 5bc0b97d6f5da..310463a19bc19 100644 --- a/roofit/roofitcore/src/RooRefCountList.cxx +++ b/roofit/roofitcore/src/RooRefCountList.cxx @@ -32,6 +32,8 @@ #include "Riostream.h" #include <stdlib.h> +using namespace std; + ClassImp(RooRefCountList) ; diff --git a/roofit/roofitcore/src/RooResolutionModel.cxx b/roofit/roofitcore/src/RooResolutionModel.cxx index 971f2b8ad9193..eeaf1cb98a184 100644 --- a/roofit/roofitcore/src/RooResolutionModel.cxx +++ b/roofit/roofitcore/src/RooResolutionModel.cxx @@ -68,6 +68,8 @@ #include "RooMsgService.h" #include "RooSentinel.h" +using namespace std; + ClassImp(RooResolutionModel) ; diff --git a/roofit/roofitcore/src/RooScaledFunc.cxx b/roofit/roofitcore/src/RooScaledFunc.cxx index 854b54a3d8290..97fe7b75dac3c 100644 --- a/roofit/roofitcore/src/RooScaledFunc.cxx +++ b/roofit/roofitcore/src/RooScaledFunc.cxx @@ -28,6 +28,8 @@ #include "RooScaledFunc.h" #include "RooScaledFunc.h" +using namespace std; + ClassImp(RooScaledFunc) ; diff --git a/roofit/roofitcore/src/RooSegmentedIntegrator1D.cxx b/roofit/roofitcore/src/RooSegmentedIntegrator1D.cxx index 96f21ac002a3b..cb92f0cc862f5 100644 --- a/roofit/roofitcore/src/RooSegmentedIntegrator1D.cxx +++ b/roofit/roofitcore/src/RooSegmentedIntegrator1D.cxx @@ -38,6 +38,8 @@ +using namespace std; + ClassImp(RooSegmentedIntegrator1D) ; diff --git a/roofit/roofitcore/src/RooSegmentedIntegrator2D.cxx b/roofit/roofitcore/src/RooSegmentedIntegrator2D.cxx index 959197fe463f1..4455e0e84effc 100644 --- a/roofit/roofitcore/src/RooSegmentedIntegrator2D.cxx +++ b/roofit/roofitcore/src/RooSegmentedIntegrator2D.cxx @@ -39,6 +39,8 @@ +using namespace std; + ClassImp(RooSegmentedIntegrator2D) ; diff --git a/roofit/roofitcore/src/RooSentinel.cxx b/roofit/roofitcore/src/RooSentinel.cxx index 3ce1888b48b09..68e57dd08ab9f 100644 --- a/roofit/roofitcore/src/RooSentinel.cxx +++ b/roofit/roofitcore/src/RooSentinel.cxx @@ -42,7 +42,6 @@ #include "RooRealConstant.h" #include "RooResolutionModel.h" #include "RooExpensiveObjectCache.h" -#include "RooMath.h" Bool_t RooSentinel::_active = kFALSE ; @@ -59,7 +58,6 @@ static void CleanUpRooFitAtExit() RooArgSet::cleanup() ; RooRealConstant::cleanup() ; RooResolutionModel::cleanup() ; - RooMath::cleanup() ; RooExpensiveObjectCache::cleanup() ; } diff --git a/roofit/roofitcore/src/RooSetPair.cxx b/roofit/roofitcore/src/RooSetPair.cxx index 833f4dd09b782..fa1e669d80005 100644 --- a/roofit/roofitcore/src/RooSetPair.cxx +++ b/roofit/roofitcore/src/RooSetPair.cxx @@ -27,6 +27,8 @@ #include "RooSetPair.h" +using namespace std; + ClassImp(RooSetPair) ; diff --git a/roofit/roofitcore/src/RooSetProxy.cxx b/roofit/roofitcore/src/RooSetProxy.cxx index c187928e02ff9..20a4c82f8c9f3 100644 --- a/roofit/roofitcore/src/RooSetProxy.cxx +++ b/roofit/roofitcore/src/RooSetProxy.cxx @@ -38,6 +38,8 @@ #include "RooArgSet.h" #include "RooAbsArg.h" +using namespace std; + ClassImp(RooSetProxy) ; @@ -264,7 +266,9 @@ Bool_t RooSetProxy::changePointer(const RooAbsCollection& newServerList, Bool_t TIterator* iter = newServerList.createIterator() ; RooAbsArg* arg ; while((arg=(RooAbsArg*)iter->Next())) { - add(*arg,kTRUE) ; + if (arg!=_owner) { + add(*arg,kTRUE) ; + } } delete iter ; } else { @@ -278,7 +282,7 @@ Bool_t RooSetProxy::changePointer(const RooAbsCollection& newServerList, Bool_t while ((arg=(RooAbsArg*)_iter->Next())) { RooAbsArg* newArg= arg->findNewServer(newServerList, nameChange); - if (newArg) error |= !RooArgSet::replace(*arg,*newArg) ; + if (newArg && newArg!=_owner) error |= !RooArgSet::replace(*arg,*newArg) ; } return !error ; } diff --git a/roofit/roofitcore/src/RooSharedProperties.cxx b/roofit/roofitcore/src/RooSharedProperties.cxx index 826d63690abd0..50cda662e8054 100644 --- a/roofit/roofitcore/src/RooSharedProperties.cxx +++ b/roofit/roofitcore/src/RooSharedProperties.cxx @@ -31,6 +31,8 @@ using std::cout ; using std::endl ; +using namespace std; + ClassImp(RooSharedProperties) ; diff --git a/roofit/roofitcore/src/RooSharedPropertiesList.cxx b/roofit/roofitcore/src/RooSharedPropertiesList.cxx index f06e19fc973f3..7608e7333bd8c 100644 --- a/roofit/roofitcore/src/RooSharedPropertiesList.cxx +++ b/roofit/roofitcore/src/RooSharedPropertiesList.cxx @@ -32,6 +32,8 @@ using std::cout ; using std::endl ; +using namespace std; + ClassImp(RooSharedPropertiesList) ; diff --git a/roofit/roofitcore/src/RooSimGenContext.cxx b/roofit/roofitcore/src/RooSimGenContext.cxx index 06f0bc4fee465..2cf38085146d8 100644 --- a/roofit/roofitcore/src/RooSimGenContext.cxx +++ b/roofit/roofitcore/src/RooSimGenContext.cxx @@ -40,6 +40,8 @@ using namespace RooFit ; #include <string> +using namespace std; + ClassImp(RooSimGenContext) ; diff --git a/roofit/roofitcore/src/RooSimSplitGenContext.cxx b/roofit/roofitcore/src/RooSimSplitGenContext.cxx index 14b64ce52fcd5..3bb7650ea3304 100644 --- a/roofit/roofitcore/src/RooSimSplitGenContext.cxx +++ b/roofit/roofitcore/src/RooSimSplitGenContext.cxx @@ -40,6 +40,8 @@ using namespace RooFit ; #include <string> +using namespace std; + ClassImp(RooSimSplitGenContext) ; @@ -205,18 +207,18 @@ void RooSimSplitGenContext::initGenerator(const RooArgSet &theEvent) //_____________________________________________________________________________ -RooDataSet* RooSimSplitGenContext::generate(Int_t nEvents, Bool_t skipInit, Bool_t extendedMode) +RooDataSet* RooSimSplitGenContext::generate(Double_t nEvents, Bool_t skipInit, Bool_t extendedMode) { if(!isValid()) { coutE(Generation) << ClassName() << "::" << GetName() << ": context is not valid" << endl; return 0; } - + + // Calculate the expected number of events if necessary if(nEvents <= 0) { nEvents= _expectedEvents; } - coutI(Generation) << ClassName() << "::" << GetName() << ":generate: will generate " << nEvents << " events" << endl; @@ -229,15 +231,15 @@ RooDataSet* RooSimSplitGenContext::generate(Int_t nEvents, Bool_t skipInit, Bool } // Generate lookup table from expected event counts - vector<Int_t> nGen(_numPdf) ; - if (extendedMode) { - + vector<Double_t> nGen(_numPdf) ; + if (extendedMode ) { _proxyIter->Reset() ; RooRealProxy* proxy ; Int_t i(0) ; while((proxy=(RooRealProxy*)_proxyIter->Next())) { RooAbsPdf* pdf=(RooAbsPdf*)proxy->absArg() ; - nGen[i] = Int_t(pdf->expectedEvents(&_allVarsPdf)+0.5) ; + //nGen[i] = Int_t(pdf->expectedEvents(&_allVarsPdf)+0.5) ; + nGen[i] = pdf->expectedEvents(&_allVarsPdf) ; i++ ; } @@ -269,6 +271,7 @@ RooDataSet* RooSimSplitGenContext::generate(Int_t nEvents, Bool_t skipInit, Bool } } } + // Now loop over states diff --git a/roofit/roofitcore/src/RooSimWSTool.cxx b/roofit/roofitcore/src/RooSimWSTool.cxx index 00aaf87b21c7d..27124b6383dab 100644 --- a/roofit/roofitcore/src/RooSimWSTool.cxx +++ b/roofit/roofitcore/src/RooSimWSTool.cxx @@ -641,7 +641,7 @@ std::string RooSimWSTool::makeSplitName(const RooArgSet& splitCatSet) //_____________________________________________________________________________ void RooSimWSTool::SplitRule::splitParameter(const char* paramNameList, const char* categoryNameList) { - // Specify that parameters names listed in paramNameList be splitted in (product of) category(s) + // Specify that parameters names listed in paramNameList be split in (product of) category(s) // listed in categoryNameList char paramBuf[4096] ; @@ -669,7 +669,7 @@ void RooSimWSTool::SplitRule::splitParameter(const char* paramNameList, const ch //_____________________________________________________________________________ void RooSimWSTool::SplitRule::splitParameterConstrained(const char* paramNameList, const char* categoryNameList, const char* remainderStateName) { - // Specify that parameters names listed in paramNameList be splitted in constrained way in (product of) category(s) + // Specify that parameters names listed in paramNameList be split in constrained way in (product of) category(s) // listed in categoryNameList and that remainder fraction formula be put in state with name remainderStateName char paramBuf[4096] ; diff --git a/roofit/roofitcore/src/RooStreamParser.cxx b/roofit/roofitcore/src/RooStreamParser.cxx index 9bdbe6af919b9..c6776a6702f9b 100644 --- a/roofit/roofitcore/src/RooStreamParser.cxx +++ b/roofit/roofitcore/src/RooStreamParser.cxx @@ -50,6 +50,8 @@ #include "RooNumber.h" +using namespace std; + ClassImp(RooStreamParser) @@ -128,6 +130,7 @@ TString RooStreamParser::readToken() // Smart tokenizer. Absorb white space and token must be either punctuation or alphanum Bool_t first(kTRUE), quotedString(kFALSE), lineCont(kFALSE) ; char buffer[10240], c(0), cnext, cprev=' ' ; + Bool_t haveINF(kFALSE) ; Int_t bufptr(0) ; // Check for end of file @@ -156,7 +159,8 @@ TString RooStreamParser::readToken() // Read next char _is->get(c) ; - + + // Terminate at EOF, EOL or trouble if (_is->eof() || _is->fail() || c=='\n') break ; @@ -174,9 +178,23 @@ TString RooStreamParser::readToken() // If '-' or '/' see what the next character is if (c == '.' || c=='-' || c=='+' || c=='/' || c=='\\') { _is->get(cnext) ; + + + if (cnext=='I' || cnext=='i') { + char tmp1,tmp2 ; + _is->get(tmp1) ; + _is->get(tmp2) ; + _is->putback(tmp2) ; + _is->putback(tmp1) ; + haveINF = ((cnext=='I' && tmp1 == 'N' && tmp2 == 'F') || (cnext=='i' && tmp1 == 'n' && tmp2 == 'f')) ; + } else { + haveINF = kFALSE ; + } + _is->putback(cnext) ; } + // Check for line continuation marker if (c=='\\' && cnext=='\\') { // Kill rest of line including endline marker @@ -204,9 +222,10 @@ TString RooStreamParser::readToken() } if (!quotedString) { - // Decide if next char is punctuation (exempt - and . that are part of floating point numbers, or +/- preceeding INF) + // Decide if next char is punctuation (exempt - and . that are part of floating point numbers, or +/- preceding INF) if (isPunctChar(c) && !(c=='.' && (isdigit(cnext)||isdigit(cprev))) - && !((c=='-'||c=='+') && (isdigit(cnext)||cnext=='.'||cnext=='i'||cnext=='I'))) { + && (!first || !((c=='-'||c=='+') && (isdigit(cnext)||cnext=='.'||haveINF)))) { + if (first) { // Make this a one-char punctuation token buffer[bufptr++]=c ; diff --git a/roofit/roofitcore/src/RooStringVar.cxx b/roofit/roofitcore/src/RooStringVar.cxx index ccf700f82f591..b71a789edb44f 100644 --- a/roofit/roofitcore/src/RooStringVar.cxx +++ b/roofit/roofitcore/src/RooStringVar.cxx @@ -36,6 +36,8 @@ +using namespace std; + ClassImp(RooStringVar) diff --git a/roofit/roofitcore/src/RooSuperCategory.cxx b/roofit/roofitcore/src/RooSuperCategory.cxx index 1a5ef516df103..ba894f902cb9b 100644 --- a/roofit/roofitcore/src/RooSuperCategory.cxx +++ b/roofit/roofitcore/src/RooSuperCategory.cxx @@ -45,6 +45,8 @@ #include "RooAbsCategoryLValue.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooSuperCategory) ; diff --git a/roofit/roofitcore/src/RooTFoamBinding.cxx b/roofit/roofitcore/src/RooTFoamBinding.cxx index 00eb32ccc25e8..a05eedb06eaeb 100644 --- a/roofit/roofitcore/src/RooTFoamBinding.cxx +++ b/roofit/roofitcore/src/RooTFoamBinding.cxx @@ -35,6 +35,8 @@ +using namespace std; + ClassImp(RooTFoamBinding) ; diff --git a/roofit/roofitcore/src/RooTObjWrap.cxx b/roofit/roofitcore/src/RooTObjWrap.cxx index 110bc5aab75d7..939a9def16a5a 100644 --- a/roofit/roofitcore/src/RooTObjWrap.cxx +++ b/roofit/roofitcore/src/RooTObjWrap.cxx @@ -26,6 +26,8 @@ #include "RooTObjWrap.h" #include "RooTObjWrap.h" +using namespace std; + ClassImp(RooTObjWrap) ; diff --git a/roofit/roofitcore/src/RooTable.cxx b/roofit/roofitcore/src/RooTable.cxx index fb9375363e0a5..a9bbdcee01b7d 100644 --- a/roofit/roofitcore/src/RooTable.cxx +++ b/roofit/roofitcore/src/RooTable.cxx @@ -30,6 +30,8 @@ +using namespace std; + ClassImp(RooTable) diff --git a/roofit/roofitcore/src/RooThreshEntry.cxx b/roofit/roofitcore/src/RooThreshEntry.cxx index 577f52c3e6732..37e8f0f1dd8ac 100644 --- a/roofit/roofitcore/src/RooThreshEntry.cxx +++ b/roofit/roofitcore/src/RooThreshEntry.cxx @@ -27,6 +27,8 @@ #include "TClass.h" #include "RooThreshEntry.h" +using namespace std; + ClassImp(RooThreshEntry) ; diff --git a/roofit/roofitcore/src/RooThresholdCategory.cxx b/roofit/roofitcore/src/RooThresholdCategory.cxx index 39d82943d94ca..d77c5ec567424 100644 --- a/roofit/roofitcore/src/RooThresholdCategory.cxx +++ b/roofit/roofitcore/src/RooThresholdCategory.cxx @@ -35,6 +35,8 @@ #include "RooThreshEntry.h" #include "RooMsgService.h" +using namespace std; + ClassImp(RooThresholdCategory) diff --git a/roofit/roofitcore/src/RooTrace.cxx b/roofit/roofitcore/src/RooTrace.cxx index 329491c0135a1..5cbfdb9456dd1 100644 --- a/roofit/roofitcore/src/RooTrace.cxx +++ b/roofit/roofitcore/src/RooTrace.cxx @@ -36,23 +36,38 @@ + +using namespace std; + ClassImp(RooTrace) ; +RooTrace* RooTrace::_instance=0 ; + -Bool_t RooTrace::_active(kFALSE) ; -Bool_t RooTrace::_verbose(kFALSE) ; -RooLinkedList RooTrace::_list ; -RooLinkedList RooTrace::_markList ; +//_____________________________________________________________________________ +RooTrace& RooTrace::instance() +{ + if (_instance==0) _instance = new RooTrace() ; + return *_instance ; +} + + +//_____________________________________________________________________________ +RooTrace::RooTrace() : _active(kFALSE), _verbose(kFALSE) +{ +} //_____________________________________________________________________________ void RooTrace::create(const TObject* obj) { // Register creation of object 'obj' - - if (_active) create2(obj) ; + RooTrace& instance = RooTrace::instance() ; + if (instance._active) { + instance.create3(obj) ; + } } @@ -60,17 +75,56 @@ void RooTrace::create(const TObject* obj) void RooTrace::destroy(const TObject* obj) { // Register deletion of object 'obj' + RooTrace& instance = RooTrace::instance() ; + if (instance._active) { + instance.destroy3(obj) ; + } +} + - if (_active) destroy2(obj) ; +//_____________________________________________________________________________ +void RooTrace::createSpecial(const char* name, int size) +{ + RooTrace& instance = RooTrace::instance() ; + if (instance._active) { + instance.createSpecial3(name,size) ; + } } +//_____________________________________________________________________________ +void RooTrace::destroySpecial(const char* name) +{ + RooTrace& instance = RooTrace::instance() ; + if (instance._active) { + instance.destroySpecial3(name) ; + } +} + + + +//_____________________________________________________________________________ +void RooTrace::createSpecial3(const char* name, int size) +{ + _specialCount[name]++ ; + _specialSize[name] = size ; +} + + +//_____________________________________________________________________________ +void RooTrace::destroySpecial3(const char* name) +{ + _specialCount[name]-- ; +} + + + //_____________________________________________________________________________ void RooTrace::active(Bool_t flag) { // If flag is true, memory tracing is activated - - _active = flag ; + + RooTrace::instance()._active = flag ; } @@ -80,11 +134,13 @@ void RooTrace::verbose(Bool_t flag) // If flag is true, a message will be printed at each // object creation or deletion - _verbose = flag ; + RooTrace::instance()._verbose = flag ; } + + //_____________________________________________________________________________ void RooTrace::create2(const TObject* obj) { @@ -114,8 +170,37 @@ void RooTrace::destroy2(const TObject* obj) +//_____________________________________________________________________________ +void RooTrace::create3(const TObject* obj) +{ + // Back end function of create(), register creation of object 'obj' + _objectCount[obj->IsA()]++ ; +} + + + + +//_____________________________________________________________________________ +void RooTrace::destroy3(const TObject* obj) +{ + // Back end function of destroy(), register deletion of object 'obj' + _objectCount[obj->IsA()]-- ; +} + + + //_____________________________________________________________________________ void RooTrace::mark() +{ + // Put marker in object list, that allows to dump contents of list + // relative to this marker + RooTrace::instance().mark3() ; +} + + + +//_____________________________________________________________________________ +void RooTrace::mark3() { // Put marker in object list, that allows to dump contents of list // relative to this marker @@ -129,12 +214,19 @@ void RooTrace::mark() void RooTrace::dump() { // Dump contents of object registry to stdout - dump(cout,kFALSE) ; + RooTrace::instance().dump3(cout,kFALSE) ; } //_____________________________________________________________________________ void RooTrace::dump(ostream& os, Bool_t sinceMarked) +{ + RooTrace::instance().dump3(os,sinceMarked) ; +} + + +//_____________________________________________________________________________ +void RooTrace::dump3(ostream& os, Bool_t sinceMarked) { // Dump contents of object register to stream 'os'. If sinceMarked is // true, only object created after the last call to mark() are shown. @@ -154,6 +246,32 @@ void RooTrace::dump(ostream& os, Bool_t sinceMarked) } +//_____________________________________________________________________________ +void RooTrace::printObjectCounts() +{ + RooTrace::instance().printObjectCounts3() ; +} + +//_____________________________________________________________________________ +void RooTrace::printObjectCounts3() +{ + Double_t total(0) ; + for (map<TClass*,int>::iterator iter = _objectCount.begin() ; iter != _objectCount.end() ; ++iter) { + Double_t tot= 1.0*(iter->first->Size()*iter->second)/(1024*1024) ; + cout << " class " << iter->first->GetName() << " count = " << iter->second << " sizeof = " << iter->first->Size() << " total memory = " << Form("%5.2f",tot) << " Mb" << endl ; + total+=tot ; + } + + for (map<string,int>::iterator iter = _specialCount.begin() ; iter != _specialCount.end() ; ++iter) { + int size = _specialSize[iter->first] ; + Double_t tot=1.0*(size*iter->second)/(1024*1024) ; + cout << " speeial " << iter->first << " count = " << iter->second << " sizeof = " << size << " total memory = " << Form("%5.2f",tot) << " Mb" << endl ; + total+=tot ; + } + cout << "Grand total memory = " << Form("%5.2f",total) << " Mb" << endl ; + +} + //_____________________________________________________________________________ void RooTrace::callgrind_zero() @@ -164,7 +282,7 @@ void RooTrace::callgrind_zero() // To trigger callgrind zero counter action, run callgrind with // argument '--zero-before=RooTrace::callgrind_zero()' (include single quotes in cmdline) - oocoutP((TObject*)0,Tracing) << "RooTrace::callgrind_zero()" << endl ; + ooccoutD((TObject*)0,Tracing) << "RooTrace::callgrind_zero()" << endl ; } //_____________________________________________________________________________ @@ -176,5 +294,5 @@ void RooTrace::callgrind_dump() // To trigger callgrind dumping action, run callgrind with // argument '--dump-before=RooTrace::callgrind_dump()' (include single quotes in cmdline) - oocoutP((TObject*)0,Tracing) << "RooTrace::callgrind_dump()" << endl ; + ooccoutD((TObject*)0,Tracing) << "RooTrace::callgrind_dump()" << endl ; } diff --git a/roofit/roofitcore/src/RooTreeData.cxx b/roofit/roofitcore/src/RooTreeData.cxx index 532b26b344522..e362adef5a06e 100644 --- a/roofit/roofitcore/src/RooTreeData.cxx +++ b/roofit/roofitcore/src/RooTreeData.cxx @@ -28,6 +28,8 @@ #include "Riostream.h" +using namespace std; + ClassImp(RooTreeData) ; diff --git a/roofit/roofitcore/src/RooTreeDataStore.cxx b/roofit/roofitcore/src/RooTreeDataStore.cxx index 13e57144854af..4e1e12557187f 100644 --- a/roofit/roofitcore/src/RooTreeDataStore.cxx +++ b/roofit/roofitcore/src/RooTreeDataStore.cxx @@ -763,7 +763,11 @@ void RooTreeDataStore::weightError(Double_t& lo, Double_t& hi, RooAbsData::Error switch (etype) { case RooAbsData::Auto: - throw string(Form("RooDataHist::weightError(%s) weight type Auto not allowed here",GetName())) ; + throw string(Form("RooDataHist::weightError(%s) error type Auto not allowed here",GetName())) ; + break ; + + case RooAbsData::Expected: + throw string(Form("RooDataHist::weightError(%s) error type Expected not allowed here",GetName())) ; break ; case RooAbsData::Poisson: @@ -1076,20 +1080,28 @@ Double_t RooTreeDataStore::sumEntries() const { if (_wgtVar) { - Double_t sum(0) ; + Double_t sum(0), carry(0); Int_t nevt = numEntries() ; for (int i=0 ; i<nevt ; i++) { get(i) ; - sum += _wgtVar->getVal() ; + // Kahan's algorithm for summing to avoid loss of precision + Double_t y = _wgtVar->getVal() - carry; + Double_t t = sum + y; + carry = (t - sum) - y; + sum = t; } return sum ; } else if (_extWgtArray) { - Double_t sum(0) ; + Double_t sum(0) , carry(0); Int_t nevt = numEntries() ; for (int i=0 ; i<nevt ; i++) { - sum += _extWgtArray[i] ; + // Kahan's algorithm for summing to avoid loss of precision + Double_t y = _extWgtArray[i] - carry; + Double_t t = sum + y; + carry = (t - sum) - y; + sum = t; } return sum ; @@ -1120,7 +1132,7 @@ void RooTreeDataStore::reset() //_____________________________________________________________________________ -void RooTreeDataStore::cacheArgs(const RooAbsArg* owner, RooArgSet& newVarSet, const RooArgSet* nset) +void RooTreeDataStore::cacheArgs(const RooAbsArg* owner, RooArgSet& newVarSet, const RooArgSet* nset, Bool_t /*skipZeroWeights*/) { // Cache given RooAbsArgs with this tree: The tree is // given direct write access of the args internal cache diff --git a/roofit/roofitcore/src/RooTruthModel.cxx b/roofit/roofitcore/src/RooTruthModel.cxx index 5f731396c3b04..418e466b88155 100644 --- a/roofit/roofitcore/src/RooTruthModel.cxx +++ b/roofit/roofitcore/src/RooTruthModel.cxx @@ -28,9 +28,11 @@ #include "RooFit.h" -#include "Riostream.h" #include "Riostream.h" #include "RooTruthModel.h" +#include "RooGenContext.h" +#include "RooAbsAnaConvPdf.h" + #include <algorithm> using namespace std ; @@ -329,6 +331,17 @@ Double_t RooTruthModel::analyticalIntegral(Int_t code, const char* rangeName) co } +//_____________________________________________________________________________ +RooAbsGenContext* RooTruthModel::modelGenContext +(const RooAbsAnaConvPdf& convPdf, const RooArgSet &vars, const RooDataSet *prototype, + const RooArgSet* auxProto, Bool_t verbose) const +{ + RooArgSet forceDirect(convVar()) ; + return new RooGenContext(dynamic_cast<const RooAbsPdf&>(convPdf), vars, prototype, + auxProto, verbose, &forceDirect) ; +} + + //_____________________________________________________________________________ Int_t RooTruthModel::getGenerator(const RooArgSet& directVars, RooArgSet &generateVars, Bool_t /*staticInitOK*/) const diff --git a/roofit/roofitcore/src/RooUniformBinning.cxx b/roofit/roofitcore/src/RooUniformBinning.cxx index 76fb6e6f695c8..db4880c5cc227 100644 --- a/roofit/roofitcore/src/RooUniformBinning.cxx +++ b/roofit/roofitcore/src/RooUniformBinning.cxx @@ -33,6 +33,8 @@ #include "Riostream.h" +using namespace std; + ClassImp(RooUniformBinning) ; diff --git a/roofit/roofitcore/src/RooUnitTest.cxx b/roofit/roofitcore/src/RooUnitTest.cxx index 19b4cdd46aadd..19eda12e72b99 100644 --- a/roofit/roofitcore/src/RooUnitTest.cxx +++ b/roofit/roofitcore/src/RooUnitTest.cxx @@ -146,7 +146,7 @@ RooWorkspace* RooUnitTest::getWS(const char* refName) { RooWorkspace* ws = dynamic_cast<RooWorkspace*>(_refFile->Get(refName)) ; if (!ws) { - cout << "stressRooFit ERROR: cannot retrieve RooWorkspace " << refName + cout << "RooUnitTest ERROR: cannot retrieve RooWorkspace " << refName << " from reference file, skipping " << endl ; return 0 ; } @@ -215,7 +215,7 @@ Bool_t RooUnitTest::runCompTests() // Retrieve benchmark RooPlot* bmark = dynamic_cast<RooPlot*>(_refFile->Get(iter->second.c_str())) ; if (!bmark) { - cout << "stressRooFit ERROR: cannot retrieve RooPlot " << iter->second << " from reference file, skipping " << endl ; + cout << "RooUnitTest ERROR: cannot retrieve RooPlot " << iter->second << " from reference file, skipping " << endl ; ret = kFALSE ; ++iter ; continue ; @@ -239,7 +239,7 @@ Bool_t RooUnitTest::runCompTests() TObject* objRef = bmark->findObject(obj->GetName()) ; if (!objRef) { - cout << "stressRooFit ERROR: cannot retrieve object " << obj->GetName() << " from reference RooPlot " << iter->second << ", skipping" << endl ; + cout << "RooUnitTest ERROR: cannot retrieve object " << obj->GetName() << " from reference RooPlot " << iter->second << ", skipping" << endl ; ret = kFALSE ; break ; } @@ -249,7 +249,7 @@ Bool_t RooUnitTest::runCompTests() RooHist* testHist = static_cast<RooHist*>(obj) ; RooHist* refHist = static_cast<RooHist*>(objRef) ; if (!testHist->isIdentical(*refHist,htol())) { - cout << "stressRooFit ERROR: comparison of object " << obj->IsA()->GetName() << "::" << obj->GetName() + cout << "RooUnitTest ERROR: comparison of object " << obj->IsA()->GetName() << "::" << obj->GetName() << " fails comparison with counterpart in reference RooPlot " << bmark->GetName() << endl ; if (compPlot) { @@ -271,7 +271,7 @@ Bool_t RooUnitTest::runCompTests() RooCurve* testCurve = static_cast<RooCurve*>(obj) ; RooCurve* refCurve = static_cast<RooCurve*>(objRef) ; if (!testCurve->isIdentical(*refCurve,ctol())) { - cout << "stressRooFit ERROR: comparison of object " << obj->IsA()->GetName() << "::" << obj->GetName() + cout << "RooUnitTest ERROR: comparison of object " << obj->IsA()->GetName() << "::" << obj->GetName() << " fails comparison with counterpart in reference RooPlot " << bmark->GetName() << endl ; if (compPlot) { @@ -295,8 +295,8 @@ Bool_t RooUnitTest::runCompTests() } if (anyFail && compPlot) { - cout << "stressRooFit INFO: writing comparison plot " << compPlot->GetName() << " of failed test to stressRooFit_DEBUG.root" << endl ; - TFile fdbg("stressRooFit_DEBUG.root","UPDATE") ; + cout << "RooUnitTest INFO: writing comparison plot " << compPlot->GetName() << " of failed test to RooUnitTest_DEBUG.root" << endl ; + TFile fdbg("RooUnitTest_DEBUG.root","UPDATE") ; compPlot->Write() ; fdbg.Close() ; } else { @@ -310,7 +310,7 @@ Bool_t RooUnitTest::runCompTests() // Writing mode - cout <<"stressRooFit: Writing reference RooPlot " << iter->first << " as benchmark " << iter->second << endl ; + cout <<"RooUnitTest: Writing reference RooPlot " << iter->first << " as benchmark " << iter->second << endl ; _refFile->cd() ; iter->first->Write(iter->second.c_str()) ; gMemDir->cd() ; @@ -330,7 +330,7 @@ Bool_t RooUnitTest::runCompTests() // Retrieve benchmark RooFitResult* bmark = dynamic_cast<RooFitResult*>(_refFile->Get(iter2->second.c_str())) ; if (!bmark) { - cout << "stressRooFit ERROR: cannot retrieve RooFitResult " << iter2->second << " from reference file, skipping " << endl ; + cout << "RooUnitTest ERROR: cannot retrieve RooFitResult " << iter2->second << " from reference file, skipping " << endl ; ++iter2 ; ret = kFALSE ; continue ; @@ -341,7 +341,7 @@ Bool_t RooUnitTest::runCompTests() } if (!iter2->first->isIdentical(*bmark,fptol(),fctol())) { - cout << "stressRooFit ERROR: comparison of object " << iter2->first->IsA()->GetName() << "::" << iter2->first->GetName() + cout << "RooUnitTest ERROR: comparison of object " << iter2->first->IsA()->GetName() << "::" << iter2->first->GetName() << " fails comparison with counterpart in reference RooFitResult " << bmark->GetName() << endl ; ret = kFALSE ; } @@ -354,7 +354,7 @@ Bool_t RooUnitTest::runCompTests() // Writing mode - cout <<"stressRooFit: Writing reference RooFitResult " << iter2->first << " as benchmark " << iter2->second << endl ; + cout <<"RooUnitTest: Writing reference RooFitResult " << iter2->first << " as benchmark " << iter2->second << endl ; _refFile->cd() ; iter2->first->Write(iter2->second.c_str()) ; gMemDir->cd() ; @@ -373,7 +373,7 @@ Bool_t RooUnitTest::runCompTests() // Retrieve benchmark RooDouble* ref = dynamic_cast<RooDouble*>(_refFile->Get(iter3->second.c_str())) ; if (!ref) { - cout << "stressRooFit ERROR: cannot retrieve RooDouble " << iter3->second << " from reference file, skipping " << endl ; + cout << "RooUnitTest ERROR: cannot retrieve RooDouble " << iter3->second << " from reference file, skipping " << endl ; ++iter3 ; ret = kFALSE ; continue ; @@ -384,7 +384,7 @@ Bool_t RooUnitTest::runCompTests() } if (fabs(iter3->first - (Double_t)(*ref))>vtol() ) { - cout << "stressRooFit ERROR: comparison of value " << iter3->first << " fails comparison with reference " << ref->GetName() << endl ; + cout << "RooUnitTest ERROR: comparison of value " << iter3->first << " fails comparison with reference " << ref->GetName() << endl ; ret = kFALSE ; } @@ -393,7 +393,7 @@ Bool_t RooUnitTest::runCompTests() // Writing mode - cout <<"stressRooFit: Writing reference Double_t " << iter3->first << " as benchmark " << iter3->second << endl ; + cout <<"RooUnitTest: Writing reference Double_t " << iter3->first << " as benchmark " << iter3->second << endl ; _refFile->cd() ; RooDouble* rd = new RooDouble(iter3->first) ; rd->Write(iter3->second.c_str()) ; @@ -414,7 +414,7 @@ Bool_t RooUnitTest::runCompTests() // Retrieve benchmark RooTable* bmark = dynamic_cast<RooTable*>(_refFile->Get(iter4->second.c_str())) ; if (!bmark) { - cout << "stressRooFit ERROR: cannot retrieve RooTable " << iter4->second << " from reference file, skipping " << endl ; + cout << "RooUnitTest ERROR: cannot retrieve RooTable " << iter4->second << " from reference file, skipping " << endl ; ++iter4 ; ret = kFALSE ; continue ; @@ -425,7 +425,7 @@ Bool_t RooUnitTest::runCompTests() } if (!iter4->first->isIdentical(*bmark)) { - cout << "stressRooFit ERROR: comparison of object " << iter4->first->IsA()->GetName() << "::" << iter4->first->GetName() + cout << "RooUnitTest ERROR: comparison of object " << iter4->first->IsA()->GetName() << "::" << iter4->first->GetName() << " fails comparison with counterpart in reference RooTable " << bmark->GetName() << endl ; ret = kFALSE ; } @@ -438,7 +438,7 @@ Bool_t RooUnitTest::runCompTests() // Writing mode - cout <<"stressRooFit: Writing reference RooTable " << iter4->first << " as benchmark " << iter4->second << endl ; + cout <<"RooUnitTest: Writing reference RooTable " << iter4->first << " as benchmark " << iter4->second << endl ; _refFile->cd() ; iter4->first->Write(iter4->second.c_str()) ; gMemDir->cd() ; @@ -455,7 +455,7 @@ Bool_t RooUnitTest::runCompTests() // Writing mode - cout <<"stressRooFit: Writing reference RooWorkspace " << iter5->first << " as benchmark " << iter5->second << endl ; + cout <<"RooUnitTest: Writing reference RooWorkspace " << iter5->first << " as benchmark " << iter5->second << endl ; _refFile->cd() ; iter5->first->Write(iter5->second.c_str()) ; gMemDir->cd() ; @@ -475,7 +475,7 @@ Bool_t RooUnitTest::runCompTests() // Retrieve benchmark TH1* bmark = dynamic_cast<TH1*>(_refFile->Get(iter6->second.c_str())) ; if (!bmark) { - cout << "stressRooFit ERROR: cannot retrieve TH1 " << iter6->second << " from reference file, skipping " << endl ; + cout << "RooUnitTest ERROR: cannot retrieve TH1 " << iter6->second << " from reference file, skipping " << endl ; ++iter6 ; ret = kFALSE ; continue ; @@ -487,14 +487,14 @@ Bool_t RooUnitTest::runCompTests() if (!areTHidentical(iter6->first,bmark)) { // coverity[NULL_RETURNS] - cout << "stressRooFit ERROR: comparison of object " << iter6->first->IsA()->GetName() << "::" << iter6->first->GetName() + cout << "RooUnitTest ERROR: comparison of object " << iter6->first->IsA()->GetName() << "::" << iter6->first->GetName() << " fails comparison with counterpart in reference TH1 " << bmark->GetName() << endl ; if (_debug) { - cout << "stressRooFit INFO: writing THx " << iter6->first->GetName() << " and " << bmark->GetName() - << " of failed test to stressRooFit_DEBUG.root" << endl ; - TFile fdbg("stressRooFit_DEBUG.root","UPDATE") ; + cout << "RooUnitTest INFO: writing THx " << iter6->first->GetName() << " and " << bmark->GetName() + << " of failed test to RooUnitTest_DEBUG.root" << endl ; + TFile fdbg("RooUnitTest_DEBUG.root","UPDATE") ; iter6->first->SetName(Form("%s_test",iter6->first->GetName())) ; iter6->first->Write() ; bmark->SetName(Form("%s_ref",bmark->GetName())) ; @@ -513,7 +513,7 @@ Bool_t RooUnitTest::runCompTests() // Writing mode - cout <<"stressRooFit: Writing reference TH1 " << iter6->first << " as benchmark " << iter6->second << endl ; + cout <<"RooUnitTest: Writing reference TH1 " << iter6->first << " as benchmark " << iter6->second << endl ; _refFile->cd() ; iter6->first->Write(iter6->second.c_str()) ; gMemDir->cd() ; @@ -580,7 +580,7 @@ Bool_t RooUnitTest::runTest() } if (RooMsgService::instance().errorCount()>0) { - cout << "RooFitUnitTest: ERROR messages were logged, failing test" << endl ; + cout << "RooUnitTest: ERROR messages were logged, failing test" << endl ; return kFALSE ; } diff --git a/roofit/roofitcore/src/RooVectorDataStore.cxx b/roofit/roofitcore/src/RooVectorDataStore.cxx index 9c946ab364ff1..f9305b8bcc927 100644 --- a/roofit/roofitcore/src/RooVectorDataStore.cxx +++ b/roofit/roofitcore/src/RooVectorDataStore.cxx @@ -35,6 +35,7 @@ #include "RooFormulaVar.h" #include "RooRealVar.h" #include "RooCategory.h" +#include "RooNameSet.h" #include "RooHistError.h" #include <iomanip> @@ -61,6 +62,7 @@ RooVectorDataStore::RooVectorDataStore() : _firstRealF(0), _firstCat(0), _sumWeight(0), + _sumWeightCarry(0), _extWgtArray(0), _extWgtErrLoArray(0), _extWgtErrHiArray(0), @@ -89,6 +91,7 @@ RooVectorDataStore::RooVectorDataStore(const char* name, const char* title, cons _firstRealF(0), _firstCat(0), _sumWeight(0), + _sumWeightCarry(0), _extWgtArray(0), _extWgtErrLoArray(0), _extWgtErrHiArray(0), @@ -108,7 +111,6 @@ RooVectorDataStore::RooVectorDataStore(const char* name, const char* title, cons delete iter ; setAllBuffersNative() ; - } @@ -179,6 +181,7 @@ RooVectorDataStore::RooVectorDataStore(const RooVectorDataStore& other, const ch _nCat(0), _nEntries(other._nEntries), _sumWeight(other._sumWeight), + _sumWeightCarry(other._sumWeightCarry), _extWgtArray(other._extWgtArray), _extWgtErrLoArray(other._extWgtErrLoArray), _extWgtErrHiArray(other._extWgtErrHiArray), @@ -231,6 +234,7 @@ RooVectorDataStore::RooVectorDataStore(const RooTreeDataStore& other, const RooA _firstRealF(0), _firstCat(0), _sumWeight(0), + _sumWeightCarry(0), _extWgtArray(0), _extWgtErrLoArray(0), _extWgtErrHiArray(0), @@ -252,6 +256,7 @@ RooVectorDataStore::RooVectorDataStore(const RooTreeDataStore& other, const RooA setAllBuffersNative() ; // now copy contents of tree storage here + reserve(other.numEntries()); for (Int_t i=0 ; i<other.numEntries() ; i++) { other.get(i) ; _varsww = other._varsww ; @@ -271,6 +276,7 @@ RooVectorDataStore::RooVectorDataStore(const RooVectorDataStore& other, const Ro _nCat(0), _nEntries(other._nEntries), _sumWeight(other._sumWeight), + _sumWeightCarry(other._sumWeightCarry), _extWgtArray(other._extWgtArray), _extWgtErrLoArray(other._extWgtErrLoArray), _extWgtErrHiArray(other._extWgtErrHiArray), @@ -346,6 +352,7 @@ RooVectorDataStore::RooVectorDataStore(const char *name, const char *title, RooA _firstRealF(0), _firstCat(0), _sumWeight(0), + _sumWeightCarry(0), _extWgtArray(0), _extWgtErrLoArray(0), _extWgtErrHiArray(0), @@ -379,7 +386,7 @@ RooVectorDataStore::RooVectorDataStore(const char *name, const char *title, RooA loadValues(&tds,cloneVar,cutRange,nStart,nStop); - if (cloneVar) delete cloneVar ; + delete cloneVar ; } @@ -406,7 +413,7 @@ RooVectorDataStore::~RooVectorDataStore() delete *iter2 ; } - if (_cache) delete _cache ; + delete _cache ; } @@ -439,7 +446,11 @@ Int_t RooVectorDataStore::fill() for ( ; iter2!=_catStoreList.end() ; ++iter2) { (*iter2)->fill() ; } - _sumWeight += _wgtVar ? _wgtVar->getVal() : 1. ; + // use Kahan's algorithm to sum up weights to avoid loss of precision + Double_t y = (_wgtVar ? _wgtVar->getVal() : 1.) - _sumWeightCarry; + Double_t t = _sumWeight + y; + _sumWeightCarry = (t - _sumWeight) - y; + _sumWeight = t; _nEntries++ ; return 0 ; @@ -647,7 +658,11 @@ void RooVectorDataStore::weightError(Double_t& lo, Double_t& hi, RooAbsData::Err switch (etype) { case RooAbsData::Auto: - throw string(Form("RooDataHist::weightError(%s) weight type Auto not allowed here",GetName())) ; + throw string(Form("RooDataHist::weightError(%s) error type Auto not allowed here",GetName())) ; + break ; + + case RooAbsData::Expected: + throw string(Form("RooDataHist::weightError(%s) error type Expected not allowed here",GetName())) ; break ; case RooAbsData::Poisson: @@ -726,6 +741,23 @@ void RooVectorDataStore::loadValues(const RooAbsDataStore *ads, const RooFormula Bool_t isTDS = dynamic_cast<const RooTreeDataStore*>(ads) ; Bool_t isVDS = dynamic_cast<const RooVectorDataStore*>(ads) ; + + // Check if weight is being renamed - if so set flag to enable special handling in copy loop + Bool_t weightRename(kFALSE) ; + Bool_t newWeightVar = _wgtVar ? _wgtVar->getAttribute("NewWeight") : kFALSE ; + + if (_wgtVar && isVDS && ((RooVectorDataStore*)(ads))->_wgtVar) { + if (string(_wgtVar->GetName())!=((RooVectorDataStore*)(ads))->_wgtVar->GetName() && !newWeightVar) { + weightRename=kTRUE ; + } + } + if (_wgtVar && isTDS && ((RooTreeDataStore*)(ads))->_wgtVar) { + if (string(_wgtVar->GetName())!=((RooTreeDataStore*)(ads))->_wgtVar->GetName() && !newWeightVar) { + weightRename=kTRUE ; + } + } + + reserve(numEntries() + (nevent - nStart)); for(Int_t i=nStart; i < nevent ; ++i) { ads->get(i) ; @@ -737,8 +769,14 @@ void RooVectorDataStore::loadValues(const RooAbsDataStore *ads, const RooFormula if (isTDS) { _varsww.assignValueOnly(((RooTreeDataStore*)ads)->_varsww) ; + if (weightRename) { + _wgtVar->setVal(((RooTreeDataStore*)ads)->_wgtVar->getVal()) ; + } } else if (isVDS) { _varsww.assignValueOnly(((RooVectorDataStore*)ads)->_varsww) ; + if (weightRename) { + _wgtVar->setVal(((RooVectorDataStore*)ads)->_wgtVar->getVal()) ; + } } else { _varsww.assignValueOnly(*ads->get()) ; } @@ -950,6 +988,7 @@ RooAbsDataStore* RooVectorDataStore::merge(const RooArgSet& allVars, list<RooAbs RooVectorDataStore* mergedStore = new RooVectorDataStore("merged","merged",allVars) ; Int_t nevt = dstoreList.front()->numEntries() ; + mergedStore->reserve(nevt); for (int i=0 ; i<nevt ; i++) { // Copy data from self @@ -968,12 +1007,27 @@ RooAbsDataStore* RooVectorDataStore::merge(const RooArgSet& allVars, list<RooAbs - +void RooVectorDataStore::reserve(Int_t nEvts) +{ + vector<RealVector*>::iterator iter = _realStoreList.begin() ; + for ( ; iter!=_realStoreList.end() ; ++iter) { + (*iter)->reserve(nEvts); + } + vector<RealFullVector*>::iterator iter3 = _realfStoreList.begin() ; + for ( ; iter3!=_realfStoreList.end() ; ++iter3) { + (*iter3)->reserve(nEvts); + } + vector<CatVector*>::iterator iter2 = _catStoreList.begin() ; + for ( ; iter2!=_catStoreList.end() ; ++iter2) { + (*iter2)->reserve(nEvts); + } +} //_____________________________________________________________________________ void RooVectorDataStore::append(RooAbsDataStore& other) { Int_t nevt = other.numEntries() ; + reserve(nevt + numEntries()); for (int i=0 ; i<nevt ; i++) { _vars = *other.get(i) ; if (_wgtVar) { @@ -998,7 +1052,7 @@ Int_t RooVectorDataStore::numEntries() const void RooVectorDataStore::reset() { _nEntries=0 ; - _sumWeight=0 ; + _sumWeight=_sumWeightCarry=0 ; vector<RealVector*>::iterator iter = _realStoreList.begin() ; for ( ; iter!=_realStoreList.end() ; ++iter) { (*iter)->reset() ; @@ -1022,7 +1076,7 @@ struct less_dep : public binary_function<RooAbsArg*, RooAbsArg*, bool> { }; //_____________________________________________________________________________ -void RooVectorDataStore::cacheArgs(const RooAbsArg* owner, RooArgSet& newVarSet, const RooArgSet* nset) +void RooVectorDataStore::cacheArgs(const RooAbsArg* owner, RooArgSet& newVarSet, const RooArgSet* nset, Bool_t skipZeroWeights) { // Cache given RooAbsArgs with this tree: The tree is // given direct write access of the args internal cache @@ -1032,11 +1086,8 @@ void RooVectorDataStore::cacheArgs(const RooAbsArg* owner, RooArgSet& newVarSet, // precalculated value and it's dirty flag will be cleared. // Delete previous cache, if any - if (_cache) { - delete _cache ; - _cache = 0 ; - } - + delete _cache ; + _cache = 0 ; // Reorder cached elements. First constant nodes, then tracked nodes in order of dependence @@ -1084,7 +1135,7 @@ void RooVectorDataStore::cacheArgs(const RooAbsArg* owner, RooArgSet& newVarSet, checkInit() ; list<RooArgSet*> vlist ; - RooArgSet cloneSet ; + RooArgList cloneSet ; while((var=(RooAbsArg*)vIter->Next())) { @@ -1107,50 +1158,98 @@ void RooVectorDataStore::cacheArgs(const RooAbsArg* owner, RooArgSet& newVarSet, RooAbsArg::setDirtyInhibit(kTRUE) ; + vector<RooArgSet*> nsetList ; + list<RooArgSet*> argObsList ; + // Now need to attach branch buffers of clones TIterator* it = cloneSet.createIterator() ; + RooArgSet *anset(0), *acset(0) ; while ((arg=(RooAbsArg*)it->Next())) { arg->attachToVStore(*newCache) ; + + RooArgSet* argObs = nset ? arg->getObservables(*nset) : arg->getVariables() ; + argObsList.push_back(argObs) ; + + RooArgSet* normSet(0) ; + const char* catNset = arg->getStringAttribute("CATNormSet") ; + if (catNset) { +// cout << "RooVectorDataStore::cacheArgs() cached node " << arg->GetName() << " has a normalization set specification CATNormSet = " << catNset << endl ; + RooNameSet rns ; + rns.setNameList(catNset) ; + anset = rns.select(nset?*nset:RooArgSet()) ; + normSet = (RooArgSet*) anset->selectCommon(*argObs) ; + + } + const char* catCset = arg->getStringAttribute("CATCondSet") ; + if (catCset) { +// cout << "RooVectorDataStore::cacheArgs() cached node " << arg->GetName() << " has a conditional observable set specification CATCondSet = " << catCset << endl ; + RooNameSet rns ; + rns.setNameList(catCset) ; + acset = rns.select(nset?*nset:RooArgSet()) ; + + argObs->remove(*acset,kTRUE,kTRUE) ; + normSet = argObs ; + } + + // now construct normalization set for component from cset/nset spec +// if (normSet) { +// cout << "RooVectorDaraStore::cacheArgs() component " << arg->GetName() << " has custom normalization set " << *normSet << endl ; +// } + nsetList.push_back(normSet) ; } delete it ; // Fill values of of placeholder + newCache->reserve(numEntries()); for (int i=0 ; i<numEntries() ; i++) { getNative(i) ; - - cIter->Reset() ; - while((cloneArg=(RooAbsArg*)cIter->Next())) { - cloneArg->syncCache(nset) ; -// cout << "RVDS::cacheArgs writing #" << i << " " ; cloneArg->Print() ; + if (weight()!=0 || !skipZeroWeights) { + cIter->Reset() ; + vector<RooArgSet*>::iterator niter = nsetList.begin() ; + while((cloneArg=(RooAbsArg*)cIter->Next())) { + // WVE need to intervene here for condobs from ProdPdf + RooArgSet* argNset = *niter ; + cloneArg->syncCache(argNset?argNset:nset) ; + ++niter ; + } } newCache->fill() ; } - delete cIter ; RooAbsArg::setDirtyInhibit(kFALSE) ; - for (list<RooArgSet*>::iterator iter = vlist.begin() ; iter!=vlist.end() ; ++iter) { - delete *iter ; - } - + // Now need to attach branch buffers of original function objects it = orderedArgs.createIterator() ; while ((arg=(RooAbsArg*)it->Next())) { arg->attachToVStore(*newCache) ; - + // Activate change tracking mode, if requested if (!arg->getAttribute("ConstantExpression") && dynamic_cast<RooAbsReal*>(arg)) { RealVector* rv = newCache->addReal((RooAbsReal*)arg) ; RooArgSet* deps = arg->getParameters(_vars) ; rv->setDependents(*deps) ; + + // WV lookup normalization set and associate with RealVector + // find ordinal number of arg in original list + Int_t idx = cloneSet.index(arg->GetName()) ; + coutI(Optimization) << "RooVectorDataStore::cacheArg() element " << arg->GetName() << " has change tracking enabled on parameters " << *deps << endl ; + rv->setNset(nsetList[idx]) ; delete deps ; } } delete it ; + for (list<RooArgSet*>::iterator iter = vlist.begin() ; iter!=vlist.end() ; ++iter) { + delete *iter ; + } + for (list<RooArgSet*>::iterator iter = argObsList.begin() ; iter!=argObsList.end() ; ++iter) { + delete *iter ; + } + _cache = newCache ; _cache->setDirtyProp(_doDirtyProp) ; } @@ -1161,7 +1260,7 @@ void RooVectorDataStore::cacheArgs(const RooAbsArg* owner, RooArgSet& newVarSet, typedef RooVectorDataStore::RealVector* pRealVector ; //_____________________________________________________________________________ -void RooVectorDataStore::recalculateCache( const RooArgSet *projectedArgs, Int_t firstEvent, Int_t lastEvent, Int_t stepSize) +void RooVectorDataStore::recalculateCache( const RooArgSet *projectedArgs, Int_t firstEvent, Int_t lastEvent, Int_t stepSize, Bool_t skipZeroWeights) { if (!_cache) return ; @@ -1179,9 +1278,13 @@ void RooVectorDataStore::recalculateCache( const RooArgSet *projectedArgs, Int_t } } + // If no recalculations are neede stop here + if (ntv==0) { + return ; + } // Refill caches of elements that require recalculation // cout << "recalc error count before update = " << RooAbsReal::numEvalErrors() << endl ; - RooAbsReal::ErrorLoggingMode origMode = RooAbsReal::evalErrorLoggingMode() ; + //RooAbsReal::ErrorLoggingMode origMode = RooAbsReal::evalErrorLoggingMode() ; RooArgSet* ownedNset = 0 ; RooArgSet* usedNset = 0 ; if (projectedArgs && projectedArgs->getSize()>0) { @@ -1197,19 +1300,25 @@ void RooVectorDataStore::recalculateCache( const RooArgSet *projectedArgs, Int_t for (int i=firstEvent ; i<lastEvent ; i+=stepSize) { get(i) ; Bool_t zeroWeight = (weight()==0) ; - if (zeroWeight) { -// cout << "update - slot " << i << " has zero weight, ignoring event errors" << endl ; - RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::Ignore) ; - } - for (int j=0 ; j<ntv ; j++) { - tv[j]->_nativeReal->_valueDirty=kTRUE ; - tv[j]->_nativeReal->getValV(usedNset) ; - // cout << "updating tracked cache slot " << i << " element " ; tv[j]->_nativeReal->Print() ; - tv[j]->write(i) ; - } - if (zeroWeight) { - RooAbsReal::setEvalErrorLoggingMode(origMode) ; + if (!zeroWeight || !skipZeroWeights) { + for (int j=0 ; j<ntv ; j++) { + tv[j]->_nativeReal->_valueDirty=kTRUE ; + tv[j]->_nativeReal->getValV(tv[j]->_nset ? tv[j]->_nset : usedNset) ; + tv[j]->write(i) ; + } } +// if (zeroWeight) { +// // cout << "update - slot " << i << " has zero weight, ignoring event errors" << endl ; +// RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::Ignore) ; +// } +// for (int j=0 ; j<ntv ; j++) { +// tv[j]->_nativeReal->_valueDirty=kTRUE ; +// tv[j]->_nativeReal->getValV(tv[j]->_nset ? tv[j]->_nset : usedNset) ; +// tv[j]->write(i) ; +// } +// if (zeroWeight) { +// RooAbsReal::setEvalErrorLoggingMode(origMode) ; +// } } // cout << "recalculate: end of updating" << endl ; @@ -1219,9 +1328,7 @@ void RooVectorDataStore::recalculateCache( const RooArgSet *projectedArgs, Int_t tv[j]->_nativeReal->setOperMode(RooAbsArg::AClean) ; } - if (ownedNset) { - delete ownedNset ; - } + delete ownedNset ; } @@ -1274,11 +1381,9 @@ void RooVectorDataStore::attachCache(const RooAbsArg* newOwner, const RooArgSet& //_____________________________________________________________________________ void RooVectorDataStore::resetCache() { - if (_cache) { - delete _cache ; - _cache = 0 ; - _cacheOwner = 0 ; - } + delete _cache ; + _cache = 0 ; + _cacheOwner = 0 ; return ; } @@ -1373,9 +1478,12 @@ void RooVectorDataStore::Streamer(TBuffer &R__b) if (R__b.IsReading()) { R__b.ReadClassBuffer(RooVectorDataStore::Class(),this); - _firstReal = &_realStoreList.front() ; - _firstRealF = &_realfStoreList.front() ; - _firstCat = &_catStoreList.front() ; + if (_realStoreList.size() > 0) + _firstReal = &_realStoreList.front() ; + if (_realfStoreList.size() > 0) + _firstRealF = &_realfStoreList.front() ; + if (_catStoreList.size() > 0) + _firstCat = &_catStoreList.front() ; for (vector<RealVector*>::iterator iter1 = _realStoreList.begin() ; iter1!=_realStoreList.end() ; ++iter1) { RooAbsArg* arg = _varsww.find((*iter1)->_nativeReal->GetName()) ; @@ -1416,9 +1524,16 @@ void RooVectorDataStore::RealFullVector::Streamer(TBuffer &R__b) // Stream an object of class RooVectorDataStore::RealFullVector. if (R__b.IsReading()) { - R__b.ReadClassBuffer(RooVectorDataStore::RealFullVector::Class(),this); + R__b.ReadClassBuffer(RooVectorDataStore::RealFullVector::Class(),this); + + // WVE - It seems that ROOT persistence turns null pointers to vectors into pointers to null-sized vectors + // Intervene here to remove those null-sized vectors and replace with null pointers to not break + // assumptions made elsewhere in this class + if (_vecE && _vecE->empty()) { delete _vecE ; _vecE = 0 ; } + if (_vecEL && _vecEL->empty()) { delete _vecEL ; _vecEL = 0 ; } + if (_vecEH && _vecEH->empty()) { delete _vecEH ; _vecEH = 0 ; } } else { - R__b.WriteClassBuffer(RooVectorDataStore::RealFullVector::Class(),this); + R__b.WriteClassBuffer(RooVectorDataStore::RealFullVector::Class(),this); } } diff --git a/roofit/roofitcore/src/RooWorkspace.cxx b/roofit/roofitcore/src/RooWorkspace.cxx index 1f132500b8115..2707eec2214c1 100644 --- a/roofit/roofitcore/src/RooWorkspace.cxx +++ b/roofit/roofitcore/src/RooWorkspace.cxx @@ -44,6 +44,8 @@ #include "RooMsgService.h" #include "RooConstVar.h" #include "RooResolutionModel.h" +#include "RooPlot.h" +#include "RooRandom.h" #include "TInterpreter.h" #include "TClassTable.h" #include "TBaseClass.h" @@ -56,7 +58,6 @@ #include "TROOT.h" #include "TFile.h" #include "TH1.h" -#include "Api.h" #include <map> #include <string> #include <list> @@ -166,7 +167,7 @@ RooWorkspace::RooWorkspace(const char* name, Bool_t doCINTExport) : //_____________________________________________________________________________ RooWorkspace::RooWorkspace(const RooWorkspace& other) : - TNamed(other), _uuid(other._uuid), _classes(this), _dir(0), _factory(0), _doExport(kFALSE), _openTrans(kFALSE) + TNamed(other), _uuid(other._uuid), _classes(other._classes,this), _dir(0), _factory(0), _doExport(kFALSE), _openTrans(kFALSE) { // Workspace copy constructor @@ -235,14 +236,17 @@ RooWorkspace::~RooWorkspace() //_____________________________________________________________________________ -Bool_t RooWorkspace::import(const char* fileSpec, const RooCmdArg& arg1, const RooCmdArg& arg2, const RooCmdArg& arg3) +Bool_t RooWorkspace::import(const char* fileSpec, + const RooCmdArg& arg1, const RooCmdArg& arg2, const RooCmdArg& arg3, + const RooCmdArg& arg4, const RooCmdArg& arg5, const RooCmdArg& arg6, + const RooCmdArg& arg7, const RooCmdArg& arg8, const RooCmdArg& arg9) { // Import a RooAbsArg or RooAbsData set from a workspace in a file. Filespec should be constructed as "filename:wspacename:objectname" // The arguments will be passed on to the relevant RooAbsArg& or RooAbsData& import call // Parse file/workspace/objectname specification - char buf[1024] ; - strlcpy(buf,fileSpec,1024) ; + char buf[10240] ; + strlcpy(buf,fileSpec,10240) ; char* filename = strtok(buf,":") ; char* wsname = strtok(0,":") ; char* objname = strtok(0,":") ; @@ -271,13 +275,13 @@ Bool_t RooWorkspace::import(const char* fileSpec, const RooCmdArg& arg1, const R // Check that workspace contains object and forward to appropriate import method RooAbsArg* warg = w->arg(objname) ; if (warg) { - Bool_t ret = import(*warg,arg1,arg2,arg3) ; + Bool_t ret = import(*warg,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9) ; delete f ; return ret ; } RooAbsData* wdata = w->data(objname) ; if (wdata) { - Bool_t ret = import(*wdata,arg1,arg2,arg3) ; + Bool_t ret = import(*wdata,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9) ; delete f ; return ret ; } @@ -289,7 +293,10 @@ Bool_t RooWorkspace::import(const char* fileSpec, const RooCmdArg& arg1, const R //_____________________________________________________________________________ -Bool_t RooWorkspace::import(const RooArgSet& args, const RooCmdArg& arg1, const RooCmdArg& arg2, const RooCmdArg& arg3) +Bool_t RooWorkspace::import(const RooArgSet& args, + const RooCmdArg& arg1, const RooCmdArg& arg2, const RooCmdArg& arg3, + const RooCmdArg& arg4, const RooCmdArg& arg5, const RooCmdArg& arg6, + const RooCmdArg& arg7, const RooCmdArg& arg8, const RooCmdArg& arg9) { // Import multiple RooAbsArg objects into workspace. For details on arguments see documentation // of import() method for single RooAbsArg @@ -298,7 +305,7 @@ Bool_t RooWorkspace::import(const RooArgSet& args, const RooCmdArg& arg1, const RooAbsArg* oneArg ; Bool_t ret(kFALSE) ; while((oneArg=(RooAbsArg*)iter->Next())) { - ret |= import(*oneArg,arg1,arg2,arg3) ; + ret |= import(*oneArg,arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9) ; } return ret ; } @@ -306,7 +313,10 @@ Bool_t RooWorkspace::import(const RooArgSet& args, const RooCmdArg& arg1, const //_____________________________________________________________________________ -Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const RooCmdArg& arg2, const RooCmdArg& arg3) +Bool_t RooWorkspace::import(const RooAbsArg& inArg, + const RooCmdArg& arg1, const RooCmdArg& arg2, const RooCmdArg& arg3, + const RooCmdArg& arg4, const RooCmdArg& arg5, const RooCmdArg& arg6, + const RooCmdArg& arg7, const RooCmdArg& arg8, const RooCmdArg& arg9) { // Import a RooAbsArg object, e.g. function, p.d.f or variable into the workspace. This import function clones the input argument and will // own the clone. If a composite object is offered for import, e.g. a p.d.f with parameters and observables, the @@ -335,11 +345,18 @@ Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const args.Add((TObject*)&arg1) ; args.Add((TObject*)&arg2) ; args.Add((TObject*)&arg3) ; + args.Add((TObject*)&arg4) ; + args.Add((TObject*)&arg5) ; + args.Add((TObject*)&arg6) ; + args.Add((TObject*)&arg7) ; + args.Add((TObject*)&arg8) ; + args.Add((TObject*)&arg9) ; // Select the pdf-specific commands RooCmdConfig pc(Form("RooWorkspace::import(%s)",GetName())) ; pc.defineString("conflictSuffix","RenameConflictNodes",0) ; + pc.defineInt("renameConflictOrig","RenameConflictNodes",0,0) ; pc.defineString("allSuffix","RenameAllNodes",0) ; pc.defineString("allVarsSuffix","RenameAllVariables",0) ; pc.defineString("allVarsExcept","RenameAllVariables",1) ; @@ -348,6 +365,7 @@ Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const pc.defineString("factoryTag","FactoryTag",0) ; pc.defineInt("useExistingNodes","RecycleConflictNodes",0,0) ; pc.defineInt("silence","Silence",0,0) ; + pc.defineInt("noRecursion","NoRecursion",0,0) ; pc.defineMutex("RenameConflictNodes","RenameAllNodes") ; pc.defineMutex("RenameConflictNodes","RecycleConflictNodes") ; pc.defineMutex("RenameAllNodes","RecycleConflictNodes") ; @@ -366,8 +384,11 @@ Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const const char* exceptVars = pc.getString("allVarsExcept") ; const char* varChangeIn = pc.getString("varChangeIn") ; const char* varChangeOut = pc.getString("varChangeOut") ; + Bool_t renameConflictOrig = pc.getInt("renameConflictOrig") ; Int_t useExistingNodes = pc.getInt("useExistingNodes") ; Int_t silence = pc.getInt("silence") ; + Int_t noRecursion = pc.getInt("noRecursion") ; + // Turn zero length strings into null pointers if (suffixC && strlen(suffixC)==0) suffixC = 0 ; @@ -381,19 +402,19 @@ Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const if (strlen(varChangeIn)>0) { // Parse comma separated lists into map<string,string> - char tmp[1024] ; - strlcpy(tmp,varChangeIn,1024) ; + char tmp[10240] ; + strlcpy(tmp,varChangeIn,10240) ; list<string> tmpIn,tmpOut ; - char* ptr = strtok(tmp,",") ; + char* ptr = strtok(tmp,", ") ; while (ptr) { tmpIn.push_back(ptr) ; - ptr = strtok(0,",") ; + ptr = strtok(0,", ") ; } - strlcpy(tmp,varChangeOut,1024) ; - ptr = strtok(tmp,",") ; + strlcpy(tmp,varChangeOut,10240) ; + ptr = strtok(tmp,", ") ; while (ptr) { tmpOut.push_back(ptr) ; - ptr = strtok(0,",") ; + ptr = strtok(0,", ") ; } list<string>::iterator iin = tmpIn.begin() ; list<string>::iterator iout = tmpOut.begin() ; @@ -405,13 +426,13 @@ Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const // Process RenameAllVariables argument if specified // First convert exception list if provided std::set<string> exceptVarNames ; - char tmp[1024] ; + char tmp[10240] ; if (exceptVars && strlen(exceptVars)) { - strlcpy(tmp,exceptVars,1024) ; - char* ptr = strtok(tmp,",") ; + strlcpy(tmp,exceptVars,10240) ; + char* ptr = strtok(tmp,", ") ; while(ptr) { exceptVarNames.insert(ptr) ; - ptr = strtok(0,",") ; + ptr = strtok(0,", ") ; } } @@ -459,7 +480,11 @@ Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const // Make list of conflicting nodes RooArgSet conflictNodes ; RooArgSet branchSet ; - inArg.branchNodeServerList(&branchSet) ; + if (noRecursion) { + branchSet.add(inArg) ; + } else { + inArg.branchNodeServerList(&branchSet) ; + } TIterator* iter = branchSet.createIterator() ; RooAbsArg* branch ; while ((branch=(RooAbsArg*)iter->Next())) { @@ -478,8 +503,8 @@ Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const } // Now create a working copy of the incoming object tree - RooArgSet* cloneSet = (RooArgSet*) RooArgSet(inArg).snapshot(kTRUE) ; - RooAbsArg* cloneTop = cloneSet->find(inArg.GetName()) ; + RooArgSet* cloneSet = (RooArgSet*) RooArgSet(inArg).snapshot(noRecursion==kFALSE) ; + RooAbsArg* cloneTop = cloneSet->find(inArg.GetName()) ; // Mark all nodes for renaming if we are not in conflictOnly mode if (!conflictOnly) { @@ -488,35 +513,87 @@ Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const } // Mark nodes that are to be renamed with special attribute - TIterator* citer = conflictNodes.createIterator() ; string topName2 = cloneTop->GetName() ; - RooAbsArg* cnode ; - while ((cnode=(RooAbsArg*)citer->Next())) { - RooAbsArg* cnode2 = cloneSet->find(cnode->GetName()) ; - string origName = cnode2->GetName() ; - cnode2->SetName(Form("%s_%s",cnode2->GetName(),suffix)) ; - cnode2->SetTitle(Form("%s (%s)",cnode2->GetTitle(),suffix)) ; - string tag = Form("ORIGNAME:%s",origName.c_str()) ; - cnode2->setAttribute(tag.c_str()) ; - - // Save name of new top level node for later use - if (cnode2==cloneTop) { - topName2 = cnode2->GetName() ; - } + if (!renameConflictOrig) { + // Mark all nodes to be imported for renaming following conflict resolution protocol + TIterator* citer = conflictNodes.createIterator() ; + RooAbsArg* cnode ; + while ((cnode=(RooAbsArg*)citer->Next())) { + RooAbsArg* cnode2 = cloneSet->find(cnode->GetName()) ; + string origName = cnode2->GetName() ; + cnode2->SetName(Form("%s_%s",cnode2->GetName(),suffix)) ; + cnode2->SetTitle(Form("%s (%s)",cnode2->GetTitle(),suffix)) ; + string tag = Form("ORIGNAME:%s",origName.c_str()) ; + cnode2->setAttribute(tag.c_str()) ; + if (!cnode2->getStringAttribute("origName")) { + string tag2 = Form("%s",origName.c_str()) ; + cnode2->setStringAttribute("origName",tag2.c_str()) ; + } + + // Save name of new top level node for later use + if (cnode2==cloneTop) { + topName2 = cnode2->GetName() ; + } + + if (!silence) { + coutI(ObjectHandling) << "RooWorkspace::import(" << GetName() + << ") Resolving name conflict in workspace by changing name of imported node " + << origName << " to " << cnode2->GetName() << endl ; + } + } + delete citer ; + } else { - if (!silence) { - coutI(ObjectHandling) << "RooWorkspace::import(" << GetName() - << ") Resolving name conflict in workspace by changing name of imported node " - << origName << " to " << cnode2->GetName() << endl ; - } - } - delete citer ; + // Rename all nodes already in the workspace to 'clear the way' for the imported nodes + TIterator* citer = conflictNodes.createIterator() ; + RooAbsArg* cnode ; + while ((cnode=(RooAbsArg*)citer->Next())) { + + string origName = cnode->GetName() ; + RooAbsArg* wsnode = _allOwnedNodes.find(origName.c_str()) ; + if (wsnode) { + + if (!wsnode->getStringAttribute("origName")) { + wsnode->setStringAttribute("origName",wsnode->GetName()) ; + } + + if (!_allOwnedNodes.find(Form("%s_%s",cnode->GetName(),suffix))) { + wsnode->SetName(Form("%s_%s",cnode->GetName(),suffix)) ; + wsnode->SetTitle(Form("%s (%s)",cnode->GetTitle(),suffix)) ; + } else { + // Name with suffix already taken, add additional suffix + Int_t n=1 ; + while (true) { + string newname = Form("%s_%s_%d",cnode->GetName(),suffix,n) ; + if (!_allOwnedNodes.find(newname.c_str())) { + wsnode->SetName(newname.c_str()) ; + wsnode->SetTitle(Form("%s (%s %d)",cnode->GetTitle(),suffix,n)) ; + break ; + } + n++ ; + } + } + if (!silence) { + coutI(ObjectHandling) << "RooWorkspace::import(" << GetName() + << ") Resolving name conflict in workspace by changing name of original node " + << origName << " to " << wsnode->GetName() << endl ; + } + } else { + coutW(ObjectHandling) << "RooWorkspce::import(" << GetName() << ") Internal error: expected to find existing node " + << origName << " to be renamed, but didn't find it..." << endl ; + } + + } + delete citer ; + + } // Process any change in variable names if (strlen(varChangeIn)>0 || (suffixV && strlen(suffixV)>0)) { // Process all changes in variable names TIterator* cliter = cloneSet->createIterator() ; + RooAbsArg* cnode ; while ((cnode=(RooAbsArg*)cliter->Next())) { if (varMap.find(cnode->GetName())!=varMap.end()) { @@ -524,6 +601,11 @@ Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const cnode->SetName(varMap[cnode->GetName()].c_str()) ; string tag = Form("ORIGNAME:%s",origName.c_str()) ; cnode->setAttribute(tag.c_str()) ; + if (!cnode->getStringAttribute("origName")) { + string tag2 = Form("%s",origName.c_str()) ; + cnode->setStringAttribute("origName",tag2.c_str()) ; + } + if (!silence) { coutI(ObjectHandling) << "RooWorkspace::import(" << GetName() << ") Changing name of variable " << origName << " to " << cnode->GetName() << " on request" << endl ; @@ -539,13 +621,13 @@ Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const } // Now clone again with renaming effective - RooArgSet* cloneSet2 = (RooArgSet*) RooArgSet(*cloneTop).snapshot(kTRUE) ; + RooArgSet* cloneSet2 = (RooArgSet*) RooArgSet(*cloneTop).snapshot(noRecursion==kFALSE) ; RooAbsArg* cloneTop2 = cloneSet2->find(topName2.c_str()) ; // Make final check list of conflicting nodes RooArgSet conflictNodes2 ; RooArgSet branchSet2 ; - inArg.branchNodeServerList(&branchSet) ; + //inArg.branchNodeServerList(&branchSet) ; // WVE not needed TIterator* iter2 = branchSet2.createIterator() ; RooAbsArg* branch2 ; while ((branch2=(RooAbsArg*)iter2->Next())) { @@ -606,6 +688,8 @@ Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const // Delete clone of incoming node nodesToBeDeleted.addOwned(*node) ; + + //cout << "WV: recycling existing node " << existingNode << " = " << existingNode->GetName() << " for imported node " << node << endl ; } else { // Import node @@ -648,7 +732,11 @@ Bool_t RooWorkspace::import(const RooAbsArg& inArg, const RooCmdArg& arg1, const //_____________________________________________________________________________ -Bool_t RooWorkspace::import(RooAbsData& inData, const RooCmdArg& arg1, const RooCmdArg& arg2, const RooCmdArg& arg3) +Bool_t RooWorkspace::import(RooAbsData& inData, + const RooCmdArg& arg1, const RooCmdArg& arg2, const RooCmdArg& arg3, + const RooCmdArg& arg4, const RooCmdArg& arg5, const RooCmdArg& arg6, + const RooCmdArg& arg7, const RooCmdArg& arg8, const RooCmdArg& arg9) + { // Import a dataset (RooDataSet or RooDataHist) into the work space. The workspace will contain a copy of the data // The dataset and its variables can be renamed upon insertion with the options below @@ -664,6 +752,12 @@ Bool_t RooWorkspace::import(RooAbsData& inData, const RooCmdArg& arg1, const Roo args.Add((TObject*)&arg1) ; args.Add((TObject*)&arg2) ; args.Add((TObject*)&arg3) ; + args.Add((TObject*)&arg4) ; + args.Add((TObject*)&arg5) ; + args.Add((TObject*)&arg6) ; + args.Add((TObject*)&arg7) ; + args.Add((TObject*)&arg8) ; + args.Add((TObject*)&arg9) ; // Select the pdf-specific commands RooCmdConfig pc(Form("RooWorkspace::import(%s)",GetName())) ; @@ -671,6 +765,7 @@ Bool_t RooWorkspace::import(RooAbsData& inData, const RooCmdArg& arg1, const Roo pc.defineString("dsetName","Rename",0,"") ; pc.defineString("varChangeIn","RenameVar",0,"",kTRUE) ; pc.defineString("varChangeOut","RenameVar",1,"",kTRUE) ; + pc.defineInt("embedded","Embedded",0,0) ; // Process and check varargs pc.process(args) ; @@ -682,18 +777,21 @@ Bool_t RooWorkspace::import(RooAbsData& inData, const RooCmdArg& arg1, const Roo const char* dsetName = pc.getString("dsetName") ; const char* varChangeIn = pc.getString("varChangeIn") ; const char* varChangeOut = pc.getString("varChangeOut") ; + Bool_t embedded = pc.getInt("embedded") ; // Transform emtpy string into null pointer if (dsetName && strlen(dsetName)==0) { dsetName=0 ; } + + RooLinkedList& dataList = embedded ? _embeddedDataList : _dataList ; // Check that no dataset with target name already exists - if (dsetName && _dataList.FindObject(dsetName)) { + if (dsetName && dataList.FindObject(dsetName)) { coutE(ObjectHandling) << "RooWorkspace::import(" << GetName() << ") ERROR dataset with name " << dsetName << " already exists in workspace, import aborted" << endl ; return kTRUE ; } - if (!dsetName && _dataList.FindObject(inData.GetName())) { + if (!dsetName && dataList.FindObject(inData.GetName())) { coutE(ObjectHandling) << "RooWorkspace::import(" << GetName() << ") ERROR dataset with name " << inData.GetName() << " already exists in workspace, import aborted" << endl ; return kTRUE ; } @@ -712,15 +810,15 @@ Bool_t RooWorkspace::import(RooAbsData& inData, const RooCmdArg& arg1, const Roo if (strlen(varChangeIn)>0) { // Parse comma separated lists of variable name changes - char tmp[1024] ; - strlcpy(tmp,varChangeIn,1024) ; + char tmp[10240] ; + strlcpy(tmp,varChangeIn,10240) ; list<string> tmpIn,tmpOut ; char* ptr = strtok(tmp,",") ; while (ptr) { tmpIn.push_back(ptr) ; ptr = strtok(0,",") ; } - strlcpy(tmp,varChangeOut,1024) ; + strlcpy(tmp,varChangeOut,10240) ; ptr = strtok(tmp,",") ; while (ptr) { tmpOut.push_back(ptr) ; @@ -745,13 +843,21 @@ Bool_t RooWorkspace::import(RooAbsData& inData, const RooCmdArg& arg1, const Roo } delete iter ; - _dataList.Add(clone) ; + dataList.Add(clone) ; if (_dir) { _dir->InternalAppend(clone) ; } if (_doExport) { exportObj(clone) ; } + + // Set expensive object cache of dataset internal buffers to that of workspace + RooFIter iter2 = clone->get()->fwdIterator() ; + while ((carg=iter2.next())) { + carg->setExpensiveObjectCache(expensiveObjectCache()) ; + } + + return kFALSE ; } @@ -782,8 +888,8 @@ Bool_t RooWorkspace::defineSet(const char* name, const RooArgSet& aset, Bool_t i if (importMissing) { import(*sarg) ; } else { - coutE(InputArguments) << "RooWorkspace::defineSet(" << GetName() << ") ERROR set constituent " << sarg->GetName() - << " is not in workspace and importMissing option is disabled" << endl ; + coutE(InputArguments) << "RooWorkspace::defineSet(" << GetName() << ") ERROR set constituent \"" << sarg->GetName() + << "\" is not in workspace and importMissing option is disabled" << endl ; return kTRUE ; } } @@ -822,8 +928,8 @@ Bool_t RooWorkspace::defineSet(const char* name, const char* contentList) while(token) { // If missing, either import or report error if (!arg(token)) { - coutE(InputArguments) << "RooWorkspace::defineSet(" << GetName() << ") ERROR proposed set constituent " << token - << " is not in workspace" << endl ; + coutE(InputArguments) << "RooWorkspace::defineSet(" << GetName() << ") ERROR proposed set constituent \"" << token + << "\" is not in workspace" << endl ; return kTRUE ; } wsargs.add(*arg(token)) ; @@ -849,14 +955,14 @@ Bool_t RooWorkspace::extendSet(const char* name, const char* newContents) RooArgSet wsargs ; // Check all constituents of provided set - char buf[1024] ; - strlcpy(buf,newContents,1024) ; + char buf[10240] ; + strlcpy(buf,newContents,10240) ; char* token = strtok(buf,",") ; while(token) { // If missing, either import or report error if (!arg(token)) { - coutE(InputArguments) << "RooWorkspace::defineSet(" << GetName() << ") ERROR proposed set constituent " << token - << " is not in workspace" << endl ; + coutE(InputArguments) << "RooWorkspace::defineSet(" << GetName() << ") ERROR proposed set constituent \"" << token + << "\" is not in workspace" << endl ; return kTRUE ; } wsargs.add(*arg(token)) ; @@ -1005,7 +1111,7 @@ Bool_t RooWorkspace::commitTransaction() } delete iter ; - // Remove all commited objects from the sandbox + // Remove all committed objects from the sandbox _sandboxNodes.removeAll() ; // Mark transaction as finished @@ -1047,6 +1153,7 @@ Bool_t RooWorkspace::importClassCode(const char* pat, Bool_t doReplace) } } delete iter ; + return ret ; } @@ -1122,6 +1229,25 @@ Bool_t RooWorkspace::loadSnapshot(const char* name) } +//_____________________________________________________________________________ +const RooArgSet* RooWorkspace::getSnapshot(const char* name) const +{ + // Return the RooArgSet containgin a snapshot of variables contained in the workspace + // + // Note that the variables of the objects in the snapshots are _copies_ of the + // variables in the workspace. To load the values of a snapshot in the workspace + // variables use loadSnapshot() instead + + RooArgSet* snap = (RooArgSet*) _snapshots.find(name) ; + if (!snap) { + coutE(ObjectHandling) << "RooWorkspace::loadSnapshot(" << GetName() << ") no snapshot with name " << name << " is available" << endl ; + return 0 ; + } + + return snap ; +} + + // //_____________________________________________________________________________ // RooAbsPdf* RooWorkspace::joinPdf(const char* jointPdfName, const char* indexName, const char* inputMapping) @@ -1213,15 +1339,15 @@ RooArgSet RooWorkspace::argSet(const char* nameList) const // Return set of RooAbsArgs matching to given list of names RooArgSet ret ; - char tmp[1024] ; - strlcpy(tmp,nameList,1024) ; + char tmp[10240] ; + strlcpy(tmp,nameList,10240) ; char* token = strtok(tmp,",") ; while(token) { RooAbsArg* oneArg = arg(token) ; if (oneArg) { ret.add(*oneArg) ; } else { - coutE(InputArguments) << " RooWorkspace::argSet(" << GetName() << ") no RooAbsArg named " << token << " in workspace" << endl ; + coutE(InputArguments) << " RooWorkspace::argSet(" << GetName() << ") no RooAbsArg named \"" << token << "\" in workspace" << endl ; } token = strtok(0,",") ; } @@ -1253,6 +1379,15 @@ RooAbsData* RooWorkspace::data(const char* name) const } +//_____________________________________________________________________________ +RooAbsData* RooWorkspace::embeddedData(const char* name) const +{ + // Retrieve dataset (binned or unbinned) with given name. A null pointer is returned if not found + + return (RooAbsData*)_embeddedDataList.FindObject(name) ; +} + + //_____________________________________________________________________________ @@ -1394,6 +1529,22 @@ list<RooAbsData*> RooWorkspace::allData() const } +//_____________________________________________________________________________ +list<RooAbsData*> RooWorkspace::allEmbeddedData() const +{ + // Return list of all dataset in the workspace + + list<RooAbsData*> ret ; + TIterator* iter = _embeddedDataList.MakeIterator() ; + RooAbsData* dat ; + while((dat=(RooAbsData*)iter->Next())) { + ret.push_back(dat) ; + } + delete iter ; + return ret ; +} + + //_____________________________________________________________________________ list<TObject*> RooWorkspace::allGenericObjects() const @@ -1469,11 +1620,7 @@ Bool_t RooWorkspace::CodeRepo::autoImportClass(TClass* tc, Bool_t doReplace) // Require that class meets technical criteria to be persistable (i.e it has a default ctor) // (We also need a default ctor of abstract classes, but cannot check that through is interface // as TClass::HasDefaultCtor only returns true for callable default ctors) -#if ROOT_VERSION_CODE <= ROOT_VERSION(5,19,02) - if (!(tc->GetClassInfo()->Property()&G__BIT_ISABSTRACT) && !tc->HasDefaultConstructor()) { -#else - if (!(gCint->ClassInfo_Property(tc->GetClassInfo())&G__BIT_ISABSTRACT) && !tc->HasDefaultConstructor()) { -#endif + if (!(tc->Property() & kIsAbstract) && !tc->HasDefaultConstructor()) { oocoutW(_wspace,ObjectHandling) << "RooWorkspace::autoImportClass(" << _wspace->GetName() << ") WARNING cannot import class " << tc->GetName() << " : it cannot be persisted because it doesn't have a default constructor. Please fix " << endl ; return kFALSE ; @@ -1574,7 +1721,7 @@ Bool_t RooWorkspace::CodeRepo::autoImportClass(TClass* tc, Bool_t doReplace) } } - char buf[1024] ; + char buf[10240] ; // *** Phase 3 *** Prepare to import code from files into STL string buffer // @@ -1594,6 +1741,8 @@ Bool_t RooWorkspace::CodeRepo::autoImportClass(TClass* tc, Bool_t doReplace) string declfilebase = declfilename.substr(0,dotpos2) ; string declfileext = declfilename.substr(dotpos2+1) ; + list<string> extraHeaders ; + // If file has not beed stored yet, enter stl strings with implementation and declaration in file map if (_fmap.find(declfilebase) == _fmap.end()) { @@ -1616,8 +1765,42 @@ Bool_t RooWorkspace::CodeRepo::autoImportClass(TClass* tc, Bool_t doReplace) // Read entire file into an stl string string decl ; while(fdecl.getline(buf,1023)) { - decl += buf ; - decl += '\n' ; + + // Look for include state of self + Bool_t processedInclude = kFALSE ; + char* extincfile = 0 ; + + // Look for include of declaration file corresponding to this implementation file + if (strstr(buf,"#include")) { + // Process #include statements here + char tmp[10240] ; + strlcpy(tmp,buf,10240) ; + Bool_t stdinclude = strchr(buf,'<') ; + strtok(tmp," <\"") ; + char* incfile = strtok(0," <>\"") ; + + if (!stdinclude) { + // check if it lives in $ROOTSYS/include + TString hpath = gSystem->Getenv("ROOTSYS") ; + hpath += "/include/" ; + hpath += incfile ; + if (gSystem->AccessPathName(hpath.Data())) { + oocoutI(_wspace,ObjectHandling) << "RooWorkspace::autoImportClass(" << _wspace->GetName() << ") scheduling include file " << incfile << " for import" << endl ; + extraHeaders.push_back(incfile) ; + extincfile = incfile ; + processedInclude = kTRUE ; + } + + } + } + + if (processedInclude) { + decl += "// external include file below retrieved from workspace code storage\n" ; + decl += Form("#include \"%s\"\n",extincfile) ; + } else { + decl += buf ; + decl += '\n' ; + } } // Open implementation file @@ -1638,38 +1821,100 @@ Bool_t RooWorkspace::CodeRepo::autoImportClass(TClass* tc, Bool_t doReplace) // Look for include state of self Bool_t foundSelfInclude=kFALSE ; + Bool_t processedInclude = kFALSE ; + char* extincfile = 0 ; // Look for include of declaration file corresponding to this implementation file if (strstr(buf,"#include")) { // Process #include statements here - char tmp[1024] ; - strlcpy(tmp,buf,1024) ; + char tmp[10240] ; + strlcpy(tmp,buf,10240) ; + Bool_t stdinclude = strchr(buf,'<') ; strtok(tmp," <\"") ; - char* incfile = strtok(0," <\"") ; - + char* incfile = strtok(0," <>\"") ; + if (strstr(incfile,declfilename.c_str())) { foundSelfInclude=kTRUE ; } - } + + if (!stdinclude && !foundSelfInclude) { + // check if it lives in $ROOTSYS/include + TString hpath = gSystem->Getenv("ROOTSYS") ; + hpath += "/include/" ; + hpath += incfile ; + + if (gSystem->AccessPathName(hpath.Data())) { + oocoutI(_wspace,ObjectHandling) << "RooWorkspace::autoImportClass(" << _wspace->GetName() << ") scheduling include file " << incfile << " for import" << endl ; + extraHeaders.push_back(incfile) ; + extincfile = incfile ; + processedInclude = kTRUE ; + } + + } + } // Explicitly rewrite include of own declaration file to string // any directory prefixes, copy all other lines verbatim in stl string if (foundSelfInclude) { // If include of self is found, substitute original include // which may have directory structure with a plain include + impl += "// class declaration include file below retrieved from workspace code storage\n" ; impl += Form("#include \"%s.%s\"\n",declfilebase.c_str(),declfileext.c_str()) ; + } else if (processedInclude) { + impl += "// external include file below retrieved from workspace code storage\n" ; + impl += Form("#include \"%s\"\n",extincfile) ; } else { impl += buf ; impl += '\n' ; } } - - + // Create entry in file map _fmap[declfilebase]._hfile = decl ; _fmap[declfilebase]._cxxfile = impl ; _fmap[declfilebase]._hext = declfileext ; + // Process extra includes now + for (list<string>::iterator ehiter = extraHeaders.begin() ; ehiter != extraHeaders.end() ; ++ehiter ) { + if (_ehmap.find(*ehiter) == _ehmap.end()) { + + ExtraHeader eh ; + eh._hname = ehiter->c_str() ; + fstream fehdr(ehiter->c_str()) ; + string ehimpl ; + char buf2[1024] ; + while(fehdr.getline(buf2,1023)) { + + // Look for include of declaration file corresponding to this implementation file + if (strstr(buf2,"#include")) { + // Process #include statements here + char tmp[10240] ; + strlcpy(tmp,buf2,10240) ; + Bool_t stdinclude = strchr(buf,'<') ; + strtok(tmp," <\"") ; + char* incfile = strtok(0," <>\"") ; + + if (!stdinclude) { + // check if it lives in $ROOTSYS/include + TString hpath = gSystem->Getenv("ROOTSYS") ; + hpath += "/include/" ; + hpath += incfile ; + if (gSystem->AccessPathName(hpath.Data())) { + oocoutI(_wspace,ObjectHandling) << "RooWorkspace::autoImportClass(" << _wspace->GetName() << ") scheduling recursive include file " << incfile << " for import" << endl ; + extraHeaders.push_back(incfile) ; + } + } + } + + ehimpl += buf2 ; + ehimpl += '\n' ; + } + eh._hfile = ehimpl.c_str() ; + + _ehmap[ehiter->c_str()] = eh ; + } + } + } else { // Inform that existing file entry is being recycled because it already contained class code @@ -1720,6 +1965,7 @@ Bool_t RooWorkspace::CodeRepo::autoImportClass(TClass* tc, Bool_t doReplace) delete[] declpath ; } + return kTRUE ; } @@ -1770,14 +2016,23 @@ Bool_t RooWorkspace::import(TObject& object, Bool_t replaceExisting) << object.GetName() << " is already in workspace and replaceExisting flag is set to false" << endl ; return kTRUE ; } - TH1::AddDirectory(kFALSE) ; + + // Grab the current state of the directory Auto-Add + ROOT::DirAutoAdd_t func = object.IsA()->GetDirectoryAutoAdd(); + object.IsA()->SetDirectoryAutoAdd(0); + Bool_t tmp = RooPlot::setAddDirectoryStatus(kFALSE) ; + if (oldObj) { _genObjects.Replace(oldObj,object.Clone()) ; delete oldObj ; } else { _genObjects.Add(object.Clone()) ; } - TH1::AddDirectory(kTRUE) ; + + // Reset the state of the directory Auto-Add + object.IsA()->SetDirectoryAutoAdd(func); + RooPlot::setAddDirectoryStatus(tmp) ; + return kFALSE ; } @@ -2113,6 +2368,18 @@ void RooWorkspace::Print(Option_t* opts) const cout << endl ; } + if (_embeddedDataList.GetSize()>0) { + cout << "embedded datasets (in pdfs and functions)" << endl ; + cout << "-----------------------------------------" << endl ; + iter = _embeddedDataList.MakeIterator() ; + RooAbsData* data2 ; + while((data2=(RooAbsData*)iter->Next())) { + cout << data2->IsA()->GetName() << "::" << data2->GetName() << *data2->get() << endl ; + } + delete iter ; + cout << endl ; + } + if (_snapshots.GetSize()>0) { cout << "parameter snapshots" << endl ; cout << "-------------------" << endl ; @@ -2213,7 +2480,7 @@ void RooWorkspace::CodeRepo::Streamer(TBuffer &R__b) if (R__b.IsReading()) { UInt_t R__s, R__c; - R__b.ReadVersion(&R__s, &R__c); + Version_t R__v = R__b.ReadVersion(&R__s, &R__c); // Stream contents of ClassFiles map Int_t count(0) ; @@ -2230,11 +2497,24 @@ void RooWorkspace::CodeRepo::Streamer(TBuffer &R__b) count=0 ; R__b >> count ; while(count--) { - TString name,bname,fbase ; + TString name ; name.Streamer(R__b) ; _c2fmap[name]._baseName.Streamer(R__b) ; _c2fmap[name]._fileBase.Streamer(R__b) ; } + + if (R__v==2) { + + count=0 ; + R__b >> count ; + while(count--) { + TString name ; + name.Streamer(R__b) ; + _ehmap[name]._hname.Streamer(R__b) ; + _ehmap[name]._hfile.Streamer(R__b) ; + } + } + R__b.CheckByteCount(R__s, R__c, thisClass::IsA()); // Instantiate any classes that are not defined in current session @@ -2271,6 +2551,18 @@ void RooWorkspace::CodeRepo::Streamer(TBuffer &R__b) ++iter2 ; } + // Stream contents of ExtraHeader map + count = _ehmap.size() ; + R__b << count ; + map<TString,ExtraHeader>::iterator iter3 = _ehmap.begin() ; + while(iter3!=_ehmap.end()) { + TString key_copy(iter3->first) ; + key_copy.Streamer(R__b) ; + iter3->second._hname.Streamer(R__b) ; + iter3->second._hfile.Streamer(R__b); + ++iter3 ; + } + R__b.SetByteCount(R__c, kTRUE); } @@ -2290,11 +2582,18 @@ void RooWorkspace::Streamer(TBuffer &R__b) if (R__b.IsReading()) { R__b.ReadClassBuffer(RooWorkspace::Class(),this); - + + // Perform any pass-2 schema evolution here + RooFIter fiter = _allOwnedNodes.fwdIterator() ; + RooAbsArg* node ; + while((node=fiter.next())) { + node->ioStreamerPass2() ; + } + RooAbsArg::ioStreamerPass2Finalize() ; + // Make expensive object cache of all objects point to intermal copy. // Somehow this doesn't work OK automatically TIterator* iter = _allOwnedNodes.createIterator() ; - RooAbsArg* node ; while((node=(RooAbsArg*)iter->Next())) { node->setExpensiveObjectCache(_eocache) ; if (node->IsA()->InheritsFrom(RooAbsOptTestStatistic::Class())) { @@ -2309,7 +2608,6 @@ void RooWorkspace::Streamer(TBuffer &R__b) } else { - // Make lists of external clients of WS objects, and remove those links temporarily map<RooAbsArg*,list<RooAbsArg*> > extClients, extValueClients, extShapeClients ; @@ -2429,6 +2727,8 @@ Bool_t RooWorkspace::CodeRepo::compileClasses() // Retrieve name of directory in which to export code files string dirName = Form(_classFileExportDir.c_str(),_wspace->uuid().AsString(),_wspace->GetName()) ; + Bool_t writeExtraHeaders(kFALSE) ; + // Process all class entries in repository map<TString,ClassRelInfo>::iterator iter = _c2fmap.begin() ; while(iter!=_c2fmap.end()) { @@ -2461,8 +2761,53 @@ Bool_t RooWorkspace::CodeRepo::compileClasses() } } haveDir=kTRUE ; + } + // First write any extra header files + if (!writeExtraHeaders) { + writeExtraHeaders = kTRUE ; + + map<TString,ExtraHeader>::iterator eiter = _ehmap.begin() ; + while(eiter!=_ehmap.end()) { + + // Check if identical declaration file (header) is already written + Bool_t needEHWrite=kTRUE ; + string fdname = Form("%s/%s",dirName.c_str(),eiter->second._hname.Data()) ; + ifstream ifdecl(fdname.c_str()) ; + if (ifdecl) { + TString contents ; + char buf[10240] ; + while(ifdecl.getline(buf,10240)) { + contents += buf ; + contents += "\n" ; + } + UInt_t crcFile = RooAbsArg::crc32(contents.Data()) ; + UInt_t crcWS = RooAbsArg::crc32(eiter->second._hfile.Data()) ; + needEHWrite = (crcFile!=crcWS) ; + } + + // Write declaration file if required + if (needEHWrite) { + oocoutI(_wspace,ObjectHandling) << "RooWorkspace::CodeRepo::compileClasses() Extracting extra header file " << fdname << endl ; + + // Extra headers may contain non-existing path - create first to be sure + gSystem->MakeDirectory(gSystem->DirName(fdname.c_str())) ; + + ofstream fdecl(fdname.c_str()) ; + if (!fdecl) { + oocoutE(_wspace,ObjectHandling) << "RooWorkspace::CodeRepo::compileClasses() ERROR opening file " + << fdname << " for writing" << endl ; + return kFALSE ; + } + fdecl << eiter->second._hfile.Data() ; + fdecl.close() ; + } + eiter++ ; + } + } + + // Navigate from class to file ClassFiles& cfinfo = _fmap[iter->second._fileBase] ; @@ -2481,8 +2826,8 @@ Bool_t RooWorkspace::CodeRepo::compileClasses() ifstream ifdecl(fdname.c_str()) ; if (ifdecl) { TString contents ; - char buf[1024] ; - while(ifdecl.getline(buf,1024)) { + char buf[10240] ; + while(ifdecl.getline(buf,10240)) { contents += buf ; contents += "\n" ; } @@ -2496,7 +2841,7 @@ Bool_t RooWorkspace::CodeRepo::compileClasses() oocoutI(_wspace,ObjectHandling) << "RooWorkspace::CodeRepo::compileClasses() Extracting declaration code of class " << iter->first << ", file " << fdname << endl ; ofstream fdecl(fdname.c_str()) ; if (!fdecl) { - oocoutE(_wspace,ObjectHandling) << "RooWorkspace::CodeRepo::compileClasses() ERROR opening file" + oocoutE(_wspace,ObjectHandling) << "RooWorkspace::CodeRepo::compileClasses() ERROR opening file " << fdname << " for writing" << endl ; return kFALSE ; } @@ -2510,8 +2855,8 @@ Bool_t RooWorkspace::CodeRepo::compileClasses() ifstream ifimpl(finame.c_str()) ; if (ifimpl) { TString contents ; - char buf[1024] ; - while(ifimpl.getline(buf,1024)) { + char buf[10240] ; + while(ifimpl.getline(buf,10240)) { contents += buf ; contents += "\n" ; } @@ -2619,7 +2964,6 @@ void RooWorkspace::exportToCint(const char* nsname) return ; } - // Set flag so that future import to workspace are automatically exported to CINT _doExport = kTRUE ; @@ -2697,13 +3041,13 @@ Bool_t RooWorkspace::isValidCPPID(const char* name) void RooWorkspace::unExport() { // Delete exported reference in CINT namespace - char buf[1024] ; + char buf[10240] ; TIterator* iter = _allOwnedNodes.createIterator() ; TObject* wobj ; while((wobj=iter->Next())) { if (isValidCPPID(wobj->GetName())) { - strlcpy(buf,Form("%s::%s",_exportNSName.c_str(),wobj->GetName()),1024) ; - G__deletevariable(buf) ; + strlcpy(buf,Form("%s::%s",_exportNSName.c_str(),wobj->GetName()),10240) ; + gInterpreter->DeleteVariable(buf); } } delete iter ; diff --git a/roofit/roofitcore/src/RooXYChi2Var.cxx b/roofit/roofitcore/src/RooXYChi2Var.cxx index 6ff0c802da4f6..4961b32c5f55f 100644 --- a/roofit/roofitcore/src/RooXYChi2Var.cxx +++ b/roofit/roofitcore/src/RooXYChi2Var.cxx @@ -44,6 +44,8 @@ #include "RooRealBinding.h" #include "RooNumIntFactory.h" +using namespace std; + ClassImp(RooXYChi2Var) ; @@ -59,7 +61,7 @@ RooXYChi2Var::RooXYChi2Var() //_____________________________________________________________________________ RooXYChi2Var::RooXYChi2Var(const char *name, const char* title, RooAbsReal& func, RooDataSet& xydata, Bool_t integrate) : - RooAbsOptTestStatistic(name,title,func,xydata,RooArgSet(),0,0,1,1,0,0), + RooAbsOptTestStatistic(name,title,func,xydata,RooArgSet(),0,0,1,RooFit::Interleave,0,0), _extended(kFALSE), _integrate(integrate), _intConfig(*defaultIntegratorConfig()), @@ -87,7 +89,7 @@ RooXYChi2Var::RooXYChi2Var(const char *name, const char* title, RooAbsReal& func //_____________________________________________________________________________ RooXYChi2Var::RooXYChi2Var(const char *name, const char* title, RooAbsReal& func, RooDataSet& xydata, RooRealVar& yvar, Bool_t integrate) : - RooAbsOptTestStatistic(name,title,func,xydata,RooArgSet(),0,0,1,1,0,0), + RooAbsOptTestStatistic(name,title,func,xydata,RooArgSet(),0,0,1,RooFit::Interleave,0,0), _extended(kFALSE), _integrate(integrate), _intConfig(*defaultIntegratorConfig()), @@ -114,7 +116,7 @@ RooXYChi2Var::RooXYChi2Var(const char *name, const char* title, RooAbsReal& func //_____________________________________________________________________________ RooXYChi2Var::RooXYChi2Var(const char *name, const char* title, RooAbsPdf& extPdf, RooDataSet& xydata, Bool_t integrate) : - RooAbsOptTestStatistic(name,title,extPdf,xydata,RooArgSet(),0,0,1,1,0,0), + RooAbsOptTestStatistic(name,title,extPdf,xydata,RooArgSet(),0,0,1,RooFit::Interleave,0,0), _extended(kTRUE), _integrate(integrate), _intConfig(*defaultIntegratorConfig()), @@ -147,7 +149,7 @@ RooXYChi2Var::RooXYChi2Var(const char *name, const char* title, RooAbsPdf& extPd //_____________________________________________________________________________ RooXYChi2Var::RooXYChi2Var(const char *name, const char* title, RooAbsPdf& extPdf, RooDataSet& xydata, RooRealVar& yvar, Bool_t integrate) : - RooAbsOptTestStatistic(name,title,extPdf,xydata,RooArgSet(),0,0,1,1,0,0), + RooAbsOptTestStatistic(name,title,extPdf,xydata,RooArgSet(),0,0,1,RooFit::Interleave,0,0), _extended(kTRUE), _integrate(integrate), _intConfig(*defaultIntegratorConfig()), @@ -379,12 +381,12 @@ Double_t RooXYChi2Var::evaluatePartition(Int_t firstEvent, Int_t lastEvent, Int_ { // Calculate chi^2 in partition from firstEvent to lastEvent using given stepSize - Double_t result(0) ; + Double_t result(0), carry(0); // Loop over bins of dataset RooDataSet* xydata = (RooDataSet*) _dataClone ; - _dataClone->store()->recalculateCache( _projDeps, firstEvent, lastEvent, stepSize ) ; + _dataClone->store()->recalculateCache( _projDeps, firstEvent, lastEvent, stepSize,kFALSE ) ; for (Int_t i=firstEvent ; i<lastEvent ; i+=stepSize) { @@ -433,9 +435,14 @@ Double_t RooXYChi2Var::evaluatePartition(Int_t firstEvent, Int_t lastEvent, Int_ } // Add chi2 term - result += eExt*eExt/(eInt*eInt+ eIntX2) ; + Double_t term = eExt*eExt/(eInt*eInt+ eIntX2); + Double_t y = term - carry; + Double_t t = result + y; + carry = (t - result) - y; + result = t; } + _evalCarry = carry; return result ; } diff --git a/roofit/roofitcore/test/rf201_composite.cxx b/roofit/roofitcore/test/rf201_composite.cxx index d9e205cdd1f9f..2681a340c2ddb 100644 --- a/roofit/roofitcore/test/rf201_composite.cxx +++ b/roofit/roofitcore/test/rf201_composite.cxx @@ -36,7 +36,7 @@ class TestBasic201 : public RooFitTestUnit // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/roofit/roofitcore/test/rf202_extendedmlfit.cxx b/roofit/roofitcore/test/rf202_extendedmlfit.cxx index 549cf42c6f831..0abf38560b702 100644 --- a/roofit/roofitcore/test/rf202_extendedmlfit.cxx +++ b/roofit/roofitcore/test/rf202_extendedmlfit.cxx @@ -36,7 +36,7 @@ class TestBasic202 : public RooFitTestUnit // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/roofit/roofitcore/test/rf204_extrangefit.cxx b/roofit/roofitcore/test/rf204_extrangefit.cxx index d364aaf9b9c90..ae377ce828844 100644 --- a/roofit/roofitcore/test/rf204_extrangefit.cxx +++ b/roofit/roofitcore/test/rf204_extrangefit.cxx @@ -38,7 +38,7 @@ class TestBasic204 : public RooFitTestUnit // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/roofit/roofitcore/test/rf205_compplot.cxx b/roofit/roofitcore/test/rf205_compplot.cxx index dfc3697883859..4118985d18f12 100644 --- a/roofit/roofitcore/test/rf205_compplot.cxx +++ b/roofit/roofitcore/test/rf205_compplot.cxx @@ -36,7 +36,7 @@ class TestBasic205 : public RooFitTestUnit // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/roofit/roofitcore/test/rf602_chi2fit.cxx b/roofit/roofitcore/test/rf602_chi2fit.cxx index 4dbfed20c3ee5..f58330c403459 100644 --- a/roofit/roofitcore/test/rf602_chi2fit.cxx +++ b/roofit/roofitcore/test/rf602_chi2fit.cxx @@ -37,7 +37,7 @@ class TestBasic602 : public RooFitTestUnit // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/roofit/roofitcore/test/rf607_fitresult.cxx b/roofit/roofitcore/test/rf607_fitresult.cxx index 419dd6e450e68..67357ce76f3ca 100644 --- a/roofit/roofitcore/test/rf607_fitresult.cxx +++ b/roofit/roofitcore/test/rf607_fitresult.cxx @@ -40,7 +40,7 @@ class TestBasic607 : public RooFitTestUnit // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5,-10,10) ; RooRealVar sigma1("sigma1","width of gaussians",0.5,0.1,10) ; RooRealVar sigma2("sigma2","width of gaussians",1,0.1,10) ; diff --git a/roofit/roofitcore/test/rf801_mcstudy.cxx b/roofit/roofitcore/test/rf801_mcstudy.cxx index dc71b33bf479f..a73285ccf61cd 100644 --- a/roofit/roofitcore/test/rf801_mcstudy.cxx +++ b/roofit/roofitcore/test/rf801_mcstudy.cxx @@ -41,7 +41,7 @@ class TestBasic801 : public RooFitTestUnit RooRealVar x("x","x",0,10) ; x.setBins(40) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5,0,10) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/roofit/roostats/CMakeLists.txt b/roofit/roostats/CMakeLists.txt index 51f31adf0cb1e..ded75865654e2 100644 --- a/roofit/roostats/CMakeLists.txt +++ b/roofit/roostats/CMakeLists.txt @@ -10,6 +10,8 @@ ROOT_LINKER_LIBRARY(RooStats *.cxx G__RooStats.cxx LIBRARIES Core Cint DEPENDENCIES RooFit RooFitCore Tree RIO Hist Matrix MathCore Minuit Foam Graf Gpad ) #ROOT_INSTALL_HEADERS() -install(DIRECTORY inc/RooStats/ DESTINATION include/RooStats +install(DIRECTORY inc/RooStats/ DESTINATION ${CMAKE_INSTALL_INCDIR}/RooStats + COMPONENT headers PATTERN ".svn" EXCLUDE REGEX "LinkDef" EXCLUDE ) +set_property(GLOBAL APPEND PROPERTY ROOT_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/inc) \ No newline at end of file diff --git a/roofit/roostats/inc/LinkDef.h b/roofit/roostats/inc/LinkDef.h index 21425817a4088..b1b1647e33dc1 100644 --- a/roofit/roostats/inc/LinkDef.h +++ b/roofit/roostats/inc/LinkDef.h @@ -66,7 +66,6 @@ #pragma link C++ class RooStats::TestStatSampler+; // interface, not concrete #pragma link C++ class RooStats::DebuggingSampler+; #pragma link C++ class RooStats::ToyMCSampler+; -#pragma link C++ class RooStats::ToyMCSamplerOld+; #pragma link C++ class RooStats::ToyMCStudy+; #pragma link C++ class RooStats::ProofConfig+; #pragma link C++ class RooStats::ToyMCImportanceSampler+; @@ -120,6 +119,7 @@ #pragma link C++ function RooStats::PValueToSignificance(Double_t); #pragma link C++ function RooStats::SignificanceToPValue(Double_t); #pragma link C++ function RooStats::RemoveConstantParameters(RooArgSet* set); +#pragma link C++ function RooStats::RemoveConstantParameters(RooArgList& set); #pragma link C++ function RooStats::SetParameters(const RooArgSet* , RooArgSet* ); #pragma link C++ function RooStats::SetAllConstant(const RooAbsCollection & , bool ); #pragma link C++ function RooStats::MakeNuisancePdf(RooAbsPdf & , const RooArgSet &, const char * ); diff --git a/roofit/roostats/inc/RooStats/AsymptoticCalculator.h b/roofit/roostats/inc/RooStats/AsymptoticCalculator.h index 125bdb6d77931..ec0fd16ffe8dc 100644 --- a/roofit/roostats/inc/RooStats/AsymptoticCalculator.h +++ b/roofit/roostats/inc/RooStats/AsymptoticCalculator.h @@ -76,6 +76,10 @@ namespace RooStats { // set test statistic for one sided (upper limits) void SetOneSided(bool on) { fOneSided = on; } + // set the test statistics for two sided (in case of upper limits + // for discovery does not make really sense) + void SetTwoSided() { fOneSided = false; fOneSidedDiscovery = false;} + // set the test statistics for one-sided discovery void SetOneSidedDiscovery(bool on) { fOneSidedDiscovery = on; } @@ -113,7 +117,7 @@ namespace RooStats { static void FillBins(const RooAbsPdf & pdf, const RooArgList &obs, RooAbsData & data, int &index, double &binVolume, int &ibin); - static double EvaluateNLL(RooAbsPdf & pdf, RooAbsData& data, const RooArgSet *poiSet = 0); + static double EvaluateNLL(RooAbsPdf & pdf, RooAbsData& data, const RooArgSet * condObs, const RooArgSet *poiSet = 0 ); static bool SetObsToExpected(RooAbsPdf &pdf, const RooArgSet &obs); static bool SetObsToExpected(RooProdPdf &prod, const RooArgSet &obs); diff --git a/roofit/roostats/inc/RooStats/BayesianCalculator.h b/roofit/roostats/inc/RooStats/BayesianCalculator.h index bfc85106d7b8a..d1b5faab0a535 100644 --- a/roofit/roostats/inc/RooStats/BayesianCalculator.h +++ b/roofit/roostats/inc/RooStats/BayesianCalculator.h @@ -88,6 +88,10 @@ namespace RooStats { // Set only the Prior Pdf virtual void SetPriorPdf(RooAbsPdf& pdf) { fPriorPdf = &pdf; } + // set the conditional observables which will be used when creating the NLL + // so the pdf's will not be normalized on the conditional observables when computing the NLL + virtual void SetConditionalObservables(const RooArgSet& set) {fConditionalObs.removeAll(); fConditionalObs.add(set);} + // set the size of the test (rate of Type I error) ( Eg. 0.05 for a 95% Confidence Interval) virtual void SetTestSize( Double_t size ) { fSize = size; @@ -159,7 +163,8 @@ namespace RooStats { RooArgSet fPOI; // POI RooAbsPdf* fPriorPdf; // prior pdf (typically for the POI) RooAbsPdf* fNuisancePdf; // nuisance pdf (needed when using nuisance sampling technique) - RooArgSet fNuisanceParameters; + RooArgSet fNuisanceParameters; // nuisance parameters + RooArgSet fConditionalObs ; // conditional observables mutable RooAbsPdf* fProductPdf; // internal pointer to model * prior mutable RooAbsReal* fLogLike; // internal pointer to log likelihood function @@ -184,7 +189,7 @@ namespace RooStats { protected: - ClassDef(BayesianCalculator,1) // BayesianCalculator class + ClassDef(BayesianCalculator,2) // BayesianCalculator class }; } diff --git a/roofit/roostats/inc/RooStats/BernsteinCorrection.h b/roofit/roostats/inc/RooStats/BernsteinCorrection.h index b1db2df0cb906..bbd17aa9df0ad 100644 --- a/roofit/roostats/inc/RooStats/BernsteinCorrection.h +++ b/roofit/roostats/inc/RooStats/BernsteinCorrection.h @@ -39,7 +39,7 @@ namespace RooStats { private: Double_t fMaxCorrection; // maximum correction factor at any point - Double_t fTolerance; // probability to add an unecessary term + Double_t fTolerance; // probability to add an unnecessary term protected: ClassDef(BernsteinCorrection,1) // A utility to add polynomial corrrection terms to a model to improve the description of data. diff --git a/roofit/roostats/inc/RooStats/CombinedCalculator.h b/roofit/roostats/inc/RooStats/CombinedCalculator.h index a81eca11aef52..9f39d0f11b242 100644 --- a/roofit/roostats/inc/RooStats/CombinedCalculator.h +++ b/roofit/roostats/inc/RooStats/CombinedCalculator.h @@ -137,6 +137,7 @@ namespace RooStats { if (model.GetParametersOfInterest()) SetParameters(*model.GetParametersOfInterest()); if (model.GetSnapshot()) SetNullParameters(*model.GetSnapshot()); if (model.GetNuisanceParameters()) SetNuisanceParameters(*model.GetNuisanceParameters()); + if (model.GetConditionalObservables()) SetConditionalObservables(*model.GetConditionalObservables()); } virtual void SetNullModel( const ModelConfig &) { // to be understood what to do @@ -161,6 +162,9 @@ namespace RooStats { // set parameter values for the alternate if using a common PDF virtual void SetAlternateParameters(const RooArgSet& set) {fAlternateParams.removeAll(); fAlternateParams.add(set);} + // set conditional observables needed for computing the NLL + virtual void SetConditionalObservables(const RooArgSet& set) {fConditionalObs.removeAll(); fConditionalObs.add(set);} + protected: @@ -175,6 +179,7 @@ namespace RooStats { RooArgSet fNullParams; // RooArgSet specifying null parameters for hypothesis test RooArgSet fAlternateParams; // RooArgSet specifying alternate parameters for hypothesis test // Is it used ???? RooArgSet fNuisParams;// RooArgSet specifying nuisance parameters for interval + RooArgSet fConditionalObs; // RooArgSet specifying the conditional observables ClassDef(CombinedCalculator,1) // A base class that is for tools that can be both HypoTestCalculators and IntervalCalculators diff --git a/roofit/roostats/inc/RooStats/ConfInterval.h b/roofit/roostats/inc/RooStats/ConfInterval.h index ccbf796de6bc3..3e1087fa069cd 100644 --- a/roofit/roostats/inc/RooStats/ConfInterval.h +++ b/roofit/roostats/inc/RooStats/ConfInterval.h @@ -46,6 +46,13 @@ namespace RooStats { // destructor virtual ~ConfInterval() {} + + // operator= + ConfInterval& operator=(const ConfInterval& other) { + if (&other==this) { return *this; } + TNamed::operator=(other); + return *this; + } // check if given point is in the interval virtual Bool_t IsInInterval(const RooArgSet&) const = 0; diff --git a/roofit/roostats/inc/RooStats/DebuggingSampler.h b/roofit/roostats/inc/RooStats/DebuggingSampler.h index 3c6fa2e922642..6a67959776304 100644 --- a/roofit/roostats/inc/RooStats/DebuggingSampler.h +++ b/roofit/roostats/inc/RooStats/DebuggingSampler.h @@ -70,7 +70,7 @@ namespace RooStats { // Get the TestStatistic virtual TestStatistic* GetTestStatistic() const { // TODO change to Roo... notifications - cout << "GetTestStatistic() IS NOT IMPLEMENTED FOR THIS SAMPLER. Returning NULL." << endl; + std::cout << "GetTestStatistic() IS NOT IMPLEMENTED FOR THIS SAMPLER. Returning NULL." << std::endl; return NULL; /*fTestStatistic;*/ } @@ -102,7 +102,7 @@ namespace RooStats { // Set the TestStatistic (want the argument to be a function of the data & parameter points virtual void SetTestStatistic(TestStatistic* /*testStatistic*/) { // TODO change to Roo... notifications - cout << "SetTestStatistic(...) IS NOT IMPLEMENTED FOR THIS SAMPLER" << endl; + std::cout << "SetTestStatistic(...) IS NOT IMPLEMENTED FOR THIS SAMPLER" << std::endl; } private: diff --git a/roofit/roostats/inc/RooStats/DetailedOutputAggregator.h b/roofit/roostats/inc/RooStats/DetailedOutputAggregator.h index ab06791fe5d3b..a5a4dc3594b7f 100755 --- a/roofit/roostats/inc/RooStats/DetailedOutputAggregator.h +++ b/roofit/roostats/inc/RooStats/DetailedOutputAggregator.h @@ -1,4 +1,4 @@ -// @(#)root/roostats:$Id: DetailedOutputAggregator.h 37084 2010-11-29 21:37:13Z moneta $ +// @(#)root/roostats:$Id$ // Author: Sven Kreiss, Kyle Cranmer Nov 2010 /************************************************************************* * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * @@ -32,141 +32,57 @@ */ // -#include "RooFitResult.h" -#include "RooPullVar.h" -#include "RooDataSet.h" + +class RooAbsCollection; +class RooFitResult; +class RooDataSet; +class RooArgList; +class RooArgSet; namespace RooStats { - class DetailedOutputAggregator { - - public: - // Translate the given fit result to a RooArgSet in a generic way. - // Prefix is prepended to all variable names. - static RooArgSet *GetAsArgSet(RooFitResult *result, TString prefix="", bool withErrorsAndPulls=false) { - RooArgSet *detailedOutput = new RooArgSet; - const RooArgSet &detOut = result->floatParsFinal(); - const RooArgSet &truthSet = result->floatParsInit(); - RooRealVar* var(0); - TIterator *it = detOut.createIterator(); - for(;(var = dynamic_cast<RooRealVar*>(it->Next()));) { - RooAbsArg* clone = var->cloneTree(TString().Append(prefix).Append(var->GetName())); - clone->SetTitle( TString().Append(prefix).Append(var->GetTitle()) ); - detailedOutput->addOwned(*clone); - - if( withErrorsAndPulls ) { - TString pullname = TString().Append(prefix).Append(TString::Format("%s_pull", var->GetName())); - // TString pulldesc = TString::Format("%s pull for fit %u", var->GetTitle(), fitNumber); - RooRealVar* truth = dynamic_cast<RooRealVar*>(truthSet.find(var->GetName())); - RooPullVar pulltemp("temppull", "temppull", *var, *truth); - RooRealVar* pull = new RooRealVar(pullname, pullname, pulltemp.getVal()); - detailedOutput->addOwned(*pull); - - TString errloname = TString().Append(prefix).Append(TString::Format("%s_errlo", var->GetName())); - // TString errlodesc = TString::Format("%s low error for fit %u", var->GetTitle(), fitNumber); - RooRealVar* errlo = new RooRealVar(errloname, errloname, var->getErrorLo()); - detailedOutput->addOwned(*errlo); - - TString errhiname = TString().Append(prefix).Append(TString::Format("%s_errhi", var->GetName())); - // TString errhidesc = TString::Format("%s high error for fit %u", var->GetTitle(), fitNumber); - RooRealVar* errhi = new RooRealVar(errhiname, errhiname, var->getErrorHi()); - detailedOutput->addOwned(*errhi); - } - } - delete it; - - // monitor a few more variables - detailedOutput->addOwned( *new RooRealVar(TString().Append(prefix).Append("minNLL"), TString().Append(prefix).Append("minNLL"), result->minNll() ) ); - detailedOutput->addOwned( *new RooRealVar(TString().Append(prefix).Append("fitStatus"), TString().Append(prefix).Append("fitStatus"), result->status() ) ); - detailedOutput->addOwned( *new RooRealVar(TString().Append(prefix).Append("covQual"), TString().Append(prefix).Append("covQual"), result->covQual() ) ); - detailedOutput->addOwned( *new RooRealVar(TString().Append(prefix).Append("numInvalidNLLEval"), TString().Append(prefix).Append("numInvalidNLLEval"), result->numInvalidNLL() ) ); - return detailedOutput; - } - - DetailedOutputAggregator() { - result = NULL; - builtSet = NULL; - } - - // For each variable in aset, prepend prefix to its name and add - // to the internal store. Note this will not appear in the produced - // dataset unless CommitSet is called. - void AppendArgSet(const RooArgSet *aset, TString prefix="") { - if (aset == NULL) { - // silently ignore - //std::cout << "Attempted to append NULL" << endl; - return; - } - if (builtSet == NULL) { - builtSet = new RooArgSet(); - } - TIterator* iter = aset->createIterator(); - while(RooRealVar* v = dynamic_cast<RooRealVar*>( iter->Next() ) ) { - TString renamed(TString::Format("%s%s", prefix.Data(), v->GetName())); - if (result != NULL) { - // we already commited an argset once, so we expect all columns to already be in the set - builtSet->setRealValue(renamed, v->getVal()); - } - else { - // we never commited, so by default all columns are expected to not exist - RooRealVar *var = new RooRealVar(renamed, v->GetTitle(), v->getVal()); - if (!builtSet->addOwned(*var)) { - delete var; - builtSet->setRealValue(renamed, v->getVal()); - } - } - } - delete iter; - } - - // Commit to the result RooDataSet. - void CommitSet(double weight=1.0) { - if (result == NULL) { - result = new RooDataSet("", "", - RooArgSet( *(new RooRealVar("weight","weight",1.0)), "tmpSet" ), "weight"); - InitializeColumns(result, builtSet); - } - result->add(*builtSet, weight); - TIterator* iter = builtSet->createIterator(); - while(RooAbsArg* v = dynamic_cast<RooAbsArg*>( iter->Next() ) ) { - builtSet->setRealValue(v->GetName(), -999.0); - } - delete iter; - } - - RooDataSet *GetAsDataSet(TString name, TString title) { - RooDataSet* temp = NULL; - if( result ) { - temp = new RooDataSet( *result ); - temp->SetNameTitle( name.Data(), title.Data() ); - }else{ - temp = new RooDataSet(name.Data(), title.Data(), - RooArgSet( *(new RooRealVar("weight","weight",1.0)), "tmpSet" ), "weight"); - } - - return temp; - } - - virtual ~DetailedOutputAggregator() { - if (result != NULL) delete result; - if (builtSet != NULL) delete builtSet; - } - - private: - RooDataSet *result; - RooArgSet *builtSet; - - void InitializeColumns(RooDataSet *dset, RooArgSet *aset) { - TIterator* iter = aset->createIterator(); - while(RooAbsArg* v = dynamic_cast<RooAbsArg*>( iter->Next() ) ) { - dset->addColumn( *(new RooRealVar(v->GetName(), v->GetTitle(), -1.0))); - } - delete iter; - } - - protected: - ClassDef(DetailedOutputAggregator,1) - }; + class DetailedOutputAggregator { + + public: + + // Translate the given fit result to a RooArgSet in a generic way. + // Prefix is prepended to all variable names. + // Note that the returned set is managed by the user and the user must + // explicitly delete all the set content (the returned set does not own the content) + static RooArgSet *GetAsArgSet(RooFitResult *result, TString prefix="", bool withErrorsAndPulls=false); + + DetailedOutputAggregator() { + fResult = NULL; + fBuiltSet = NULL; + } + + // For each variable in aset, prepend prefix to its name and add + // to the internal store. Note this will not appear in the produced + // dataset unless CommitSet is called. + void AppendArgSet(const RooAbsCollection *aset, TString prefix=""); + + const RooArgList* GetAsArgList() const { + // Returns this set of detailed output. + // Note that the ownership of the returned list is not transfered + // It is managed by the DetailedOutputAggregator class + return fBuiltSet; + } + + // Commit to the result RooDataSet. + void CommitSet(double weight=1.0); + + RooDataSet *GetAsDataSet(TString name, TString title); + + virtual ~DetailedOutputAggregator(); + + private: + + RooDataSet *fResult; + RooArgList *fBuiltSet; + + protected: + ClassDef(DetailedOutputAggregator,1) + }; } #endif diff --git a/roofit/roostats/inc/RooStats/FeldmanCousins.h b/roofit/roostats/inc/RooStats/FeldmanCousins.h index a482355bb060e..a94693a8c79cb 100644 --- a/roofit/roostats/inc/RooStats/FeldmanCousins.h +++ b/roofit/roostats/inc/RooStats/FeldmanCousins.h @@ -55,21 +55,21 @@ namespace RooStats { virtual Double_t ConfidenceLevel() const {return 1.-fSize;} // Set the DataSet virtual void SetData(RooAbsData& /*data*/) { - cout << "DEPRECATED, set data in constructor" << endl; + std::cout << "DEPRECATED, set data in constructor" << std::endl; } // Set the Pdf virtual void SetPdf(RooAbsPdf& /*pdf*/) { - cout << "DEPRECATED, use ModelConfig" << endl; + std::cout << "DEPRECATED, use ModelConfig" << std::endl; } // specify the parameters of interest in the interval virtual void SetParameters(const RooArgSet& /*set*/) { - cout << "DEPRECATED, use ModelConfig" << endl; + std::cout << "DEPRECATED, use ModelConfig" << std::endl; } // specify the nuisance parameters (eg. the rest of the parameters) virtual void SetNuisanceParameters(const RooArgSet& /*set*/) { - cout << "DEPRECATED, use ModelConfig" << endl; + std::cout << "DEPRECATED, use ModelConfig" << std::endl; } // User-defined set of points to test diff --git a/roofit/roostats/inc/RooStats/HLFactory.h b/roofit/roostats/inc/RooStats/HLFactory.h index 0aaff5c064f21..8e5f6b445c830 100644 --- a/roofit/roostats/inc/RooStats/HLFactory.h +++ b/roofit/roostats/inc/RooStats/HLFactory.h @@ -96,7 +96,7 @@ namespace RooStats { /// Create the category for the combinations void fCreateCategory(); - /// Check the lenght of the lists + /// Check the length of the lists bool fNamesListsConsistent(); /// List of channels names to combine for the signal plus background pdfs diff --git a/roofit/roostats/inc/RooStats/HybridCalculator.h b/roofit/roostats/inc/RooStats/HybridCalculator.h index 0404aeffab3c7..743ce25ed810a 100644 --- a/roofit/roostats/inc/RooStats/HybridCalculator.h +++ b/roofit/roostats/inc/RooStats/HybridCalculator.h @@ -44,8 +44,10 @@ namespace RooStats { TestStatSampler* sampler=0 ) : HypoTestCalculatorGeneric(data, altModel, nullModel, sampler), - fPriorNuisanceNull(0), - fPriorNuisanceAlt(0), + fPriorNuisanceNull(MakeNuisancePdf(nullModel, "PriorNuisanceNull")), + fPriorNuisanceAlt(MakeNuisancePdf(altModel, "PriorNuisanceAlt")), + fPriorNuisanceNullExternal(false), + fPriorNuisanceAltExternal(false), fNToysNull(-1), fNToysAlt(-1), fNToysNullTail(0), @@ -54,12 +56,36 @@ namespace RooStats { } ~HybridCalculator() { + if(fPriorNuisanceNullExternal == false) delete fPriorNuisanceNull; + if(fPriorNuisanceAltExternal == false) delete fPriorNuisanceAlt; } - // Override the distribution used for marginalizing nuisance parameters that is infered from ModelConfig - virtual void ForcePriorNuisanceNull(RooAbsPdf& priorNuisance) { fPriorNuisanceNull = &priorNuisance; } - virtual void ForcePriorNuisanceAlt(RooAbsPdf& priorNuisance) { fPriorNuisanceAlt = &priorNuisance; } + // Override the distribution used for marginalizing nuisance parameters that is inferred from ModelConfig + virtual void ForcePriorNuisanceNull(RooAbsPdf& priorNuisance) { + if(fPriorNuisanceNullExternal == false) delete fPriorNuisanceNull; + fPriorNuisanceNull = &priorNuisance; fPriorNuisanceNullExternal = true; + } + virtual void ForcePriorNuisanceAlt(RooAbsPdf& priorNuisance) { + if(fPriorNuisanceAltExternal == false) delete fPriorNuisanceAlt; + fPriorNuisanceAlt = &priorNuisance; fPriorNuisanceAltExternal = true; + } + + virtual void SetNullModel(const ModelConfig &nullModel) { + fNullModel = &nullModel; + if(fPriorNuisanceNullExternal == false) { + delete fPriorNuisanceNull; + fPriorNuisanceNull = MakeNuisancePdf(nullModel, "PriorNuisanceNull"); + } + } + + virtual void SetAlternateModel(const ModelConfig &altModel) { + fAltModel = &altModel; + if(fPriorNuisanceAltExternal == false) { + delete fPriorNuisanceAlt; + fPriorNuisanceAlt = MakeNuisancePdf(altModel, "PriorNuisanceAlt"); + } + } // set number of toys void SetToys(int toysNull, int toysAlt) { fNToysNull = toysNull; fNToysAlt = toysAlt; } @@ -81,6 +107,11 @@ namespace RooStats { RooAbsPdf *fPriorNuisanceNull; RooAbsPdf *fPriorNuisanceAlt; + // these flags tell us if the nuisance pdfs came from an external resource (via ForcePriorNuisance) + // or were created internally and should be deleted + Bool_t fPriorNuisanceNullExternal; + Bool_t fPriorNuisanceAltExternal; + // different number of toys for null and alt int fNToysNull; int fNToysAlt; @@ -90,7 +121,7 @@ namespace RooStats { int fNToysAltTail; protected: - ClassDef(HybridCalculator,1) + ClassDef(HybridCalculator,2) }; } diff --git a/roofit/roostats/inc/RooStats/HybridCalculatorOriginal.h b/roofit/roostats/inc/RooStats/HybridCalculatorOriginal.h index 70dd85fd2dd1f..72fc66d071588 100644 --- a/roofit/roostats/inc/RooStats/HybridCalculatorOriginal.h +++ b/roofit/roostats/inc/RooStats/HybridCalculatorOriginal.h @@ -135,7 +135,7 @@ namespace RooStats { HybridResult* Calculate(unsigned int nToys, bool usePriors) const; void PrintMore(const char* options) const; - void PatchSetExtended(bool on = true) { fTmpDoExtended = on; std::cout << "extended patch set to " << on << endl; } // patch to test with RooPoisson (or other non-extended models) + void PatchSetExtended(bool on = true) { fTmpDoExtended = on; std::cout << "extended patch set to " << on << std::endl; } // patch to test with RooPoisson (or other non-extended models) private: diff --git a/roofit/roostats/inc/RooStats/HypoTestCalculatorGeneric.h b/roofit/roostats/inc/RooStats/HypoTestCalculatorGeneric.h index 92006f5a18d1e..3edc7ba4ff0df 100644 --- a/roofit/roostats/inc/RooStats/HypoTestCalculatorGeneric.h +++ b/roofit/roostats/inc/RooStats/HypoTestCalculatorGeneric.h @@ -76,6 +76,12 @@ namespace RooStats { // TestStatSampler, e.g. GetTestStatSampler.SetTestSize(Double_t size); TestStatSampler* GetTestStatSampler(void) const { return fTestStatSampler; } + // set this for re-using always the same toys for alternate hypothesis in + // case of calls at dofferent null parameter points + // This is useful to get more stable bands when running the HypoTest inversion + void UseSameAltToys(); + + protected: // should return zero (to be used later for conditional flow) virtual int CheckHook(void) const { return 0; } @@ -92,6 +98,8 @@ namespace RooStats { TestStatSampler *fDefaultSampler; TestStatistic *fDefaultTestStat; + unsigned int fAltToysSeed; // to have same toys for alternate + private: void SetupSampler(const ModelConfig& model) const; void SetAdaptiveLimits(Double_t obsTestStat, Bool_t forNull) const; @@ -104,7 +112,7 @@ namespace RooStats { protected: - ClassDef(HypoTestCalculatorGeneric,1) + ClassDef(HypoTestCalculatorGeneric,2) }; } diff --git a/roofit/roostats/inc/RooStats/HypoTestInverter.h b/roofit/roostats/inc/RooStats/HypoTestInverter.h index aac1aec4bee5f..6cc1976eb0733 100644 --- a/roofit/roostats/inc/RooStats/HypoTestInverter.h +++ b/roofit/roostats/inc/RooStats/HypoTestInverter.h @@ -179,7 +179,7 @@ class HypoTestInverter : public IntervalCalculator { int fMaxToys; // maximum number of toys to run HypoTestCalculatorGeneric* fCalculator0; // pointer to the calculator passed in the constructor - auto_ptr<HypoTestCalculatorGeneric> fHC; + std::auto_ptr<HypoTestCalculatorGeneric> fHC; RooRealVar* fScannedVariable; // pointer to the constrained variable mutable HypoTestInverterResult* fResults; // pointer to the result diff --git a/roofit/roostats/inc/RooStats/HypoTestInverterResult.h b/roofit/roostats/inc/RooStats/HypoTestInverterResult.h index 99dfd342e5334..448ea8280bb63 100644 --- a/roofit/roostats/inc/RooStats/HypoTestInverterResult.h +++ b/roofit/roostats/inc/RooStats/HypoTestInverterResult.h @@ -37,9 +37,17 @@ class HypoTestInverterResult : public SimpleInterval { const RooRealVar& scannedVariable, double cl ) ; + HypoTestInverterResult( const HypoTestInverterResult& other, const char* name ); + // destructor virtual ~HypoTestInverterResult(); + // operator = + HypoTestInverterResult& operator = (const HypoTestInverterResult& other); + + // remove points that appear to have failed. + int ExclusionCleanup(); + // merge with the content of another HypoTestInverterResult object bool Add( const HypoTestInverterResult& otherResult ); @@ -95,6 +103,9 @@ class HypoTestInverterResult : public SimpleInterval { // set the confidence level for the interval (eg. 0.95 for a 95% Confidence Interval) virtual void SetConfidenceLevel( Double_t cl ) { fConfidenceLevel = cl; } + // set CLs threshold for exclusion cleanup function + inline void SetCLsCleanupThreshold( Double_t th ) { fCLsCleanupThreshold = th; } + // flag to switch between using CLsb (default) or CLs as confidence level void UseCLs( bool on = true ) { fUseCLs = on; } @@ -188,6 +199,8 @@ class HypoTestInverterResult : public SimpleInterval { double fLowerLimitError; double fUpperLimitError; + double fCLsCleanupThreshold; + static double fgAsymptoticMaxSigma; // max sigma value used to scan asymptotic expected p values std::vector<double> fXValues; diff --git a/roofit/roostats/inc/RooStats/HypoTestResult.h b/roofit/roostats/inc/RooStats/HypoTestResult.h index b7a7e19e3c848..89db157f77ba5 100644 --- a/roofit/roostats/inc/RooStats/HypoTestResult.h +++ b/roofit/roostats/inc/RooStats/HypoTestResult.h @@ -67,7 +67,7 @@ namespace RooStats { // default constructor explicit HypoTestResult(const char* name = 0); - // copy constructor + // copy constructo HypoTestResult(const HypoTestResult& other); // constructor from name, null and alternate p values @@ -76,6 +76,9 @@ namespace RooStats { // destructor virtual ~HypoTestResult(); + // assignment operator + HypoTestResult & operator=(const HypoTestResult& other); + // add values from another HypoTestResult virtual void Append(const HypoTestResult *other); @@ -137,8 +140,12 @@ namespace RooStats { /// The error on the ratio CLs+b/CLb Double_t CLsError() const; + /// The error on the Null p-value Double_t NullPValueError() const; + /// The error on the significance, computed from NullPValueError via error propagation + Double_t SignificanceError() const; + void Print(const Option_t* = "") const; diff --git a/roofit/roostats/inc/RooStats/LikelihoodIntervalPlot.h b/roofit/roostats/inc/RooStats/LikelihoodIntervalPlot.h index e8807690653bf..b999dde194492 100644 --- a/roofit/roostats/inc/RooStats/LikelihoodIntervalPlot.h +++ b/roofit/roostats/inc/RooStats/LikelihoodIntervalPlot.h @@ -37,6 +37,10 @@ namespace RooStats { // Destructor of SamplingDistribution virtual ~LikelihoodIntervalPlot(); + + // returned plotted object (RooPlot or histograms) + TObject * GetPlottedObject() const { return fPlotObject; } + void SetLikelihoodInterval(LikelihoodInterval* theInterval); void SetPlotParameters(const RooArgSet *params) ; @@ -67,9 +71,9 @@ namespace RooStats { private: - Int_t fColor; - Int_t fFillStyle; - Int_t fLineColor; + Int_t fColor; // color for the contour (for 2D) or function (in 1D) + Int_t fFillStyle; // fill style for contours + Int_t fLineColor; // line color for the interval (1D) or for other contours (2D) Int_t fNdimPlot; Int_t fNPoints; // number of points used to scan the PL @@ -84,11 +88,12 @@ namespace RooStats { LikelihoodInterval *fInterval; RooArgSet *fParamsPlot; + TObject * fPlotObject; // plotted object protected: - ClassDef(LikelihoodIntervalPlot,1) // Class containing the results of the IntervalCalculator + ClassDef(LikelihoodIntervalPlot,2) // Class containing the results of the IntervalCalculator }; } diff --git a/roofit/roostats/inc/RooStats/MCMCCalculator.h b/roofit/roostats/inc/RooStats/MCMCCalculator.h index ee34cd8a4bb3e..936b73b6a2502 100644 --- a/roofit/roostats/inc/RooStats/MCMCCalculator.h +++ b/roofit/roostats/inc/RooStats/MCMCCalculator.h @@ -89,6 +89,10 @@ namespace RooStats { // specify the nuisance parameters (eg. the rest of the parameters) virtual void SetNuisanceParameters(const RooArgSet& set) {fNuisParams.removeAll(); fNuisParams.add(set);} + // set the conditional observables which will be used when creating the NLL + // so the pdf's will not be normalized on the conditional observables when computing the NLL + virtual void SetConditionalObservables(const RooArgSet& set) {fConditionalObs.removeAll(); fConditionalObs.add(set);} + // set the size of the test (rate of Type I error) ( Eg. 0.05 for a 95% Confidence Interval) virtual void SetTestSize(Double_t size) {fSize = size;} @@ -143,7 +147,7 @@ namespace RooStats { { if (epsilon < 0) coutE(InputArguments) << "MCMCInterval::SetEpsilon will not allow " - << "negative epsilon value" << endl; + << "negative epsilon value" << std::endl; else fEpsilon = epsilon; } @@ -166,7 +170,7 @@ namespace RooStats { { if (delta < 0.) coutE(InputArguments) << "MCMCInterval::SetDelta will not allow " - << "negative delta value" << endl; + << "negative delta value" << std::endl; else fDelta = delta; } @@ -177,6 +181,7 @@ namespace RooStats { RooArgSet fPOI; // parameters of interest for interval RooArgSet fNuisParams; // nuisance parameters for interval (not really used) RooArgSet fChainParams; // parameters to store in the chain (if not specified they are all of them ) + RooArgSet fConditionalObs; // conditional observables mutable ProposalFunction* fPropFunc; // Proposal function for MCMC integration RooAbsPdf * fPdf; // pointer to common PDF (owned by the workspace) RooAbsPdf * fPriorPdf; // pointer to prior PDF (owned by the workspace) @@ -210,7 +215,7 @@ namespace RooStats { delete it; } - ClassDef(MCMCCalculator,2) // Markov Chain Monte Carlo calculator for Bayesian credible intervals + ClassDef(MCMCCalculator,3) // Markov Chain Monte Carlo calculator for Bayesian credible intervals }; } diff --git a/roofit/roostats/inc/RooStats/MCMCInterval.h b/roofit/roostats/inc/RooStats/MCMCInterval.h index 69e47f5b5cd42..09c57e9d38fd8 100644 --- a/roofit/roostats/inc/RooStats/MCMCInterval.h +++ b/roofit/roostats/inc/RooStats/MCMCInterval.h @@ -238,7 +238,7 @@ namespace RooStats { { if (epsilon < 0) coutE(InputArguments) << "MCMCInterval::SetEpsilon will not allow " - << "negative epsilon value" << endl; + << "negative epsilon value" << std::endl; else fEpsilon = epsilon; } @@ -268,7 +268,7 @@ namespace RooStats { { if (delta < 0.) coutE(InputArguments) << "MCMCInterval::SetDelta will not allow " - << "negative delta value" << endl; + << "negative delta value" << std::endl; else fDelta = delta; } @@ -299,7 +299,7 @@ namespace RooStats { Double_t fLeftSideTF; // left side tail-fraction for interval Double_t fTFConfLevel; // the actual conf level of tail-fraction interval - vector<Int_t> fVector; // vector containing the Markov chain data + std::vector<Int_t> fVector; // vector containing the Markov chain data Double_t fVecWeight; // sum of weights of all entries in fVector Double_t fTFLower; // lower limit of the tail-fraction interval Double_t fTFUpper; // upper limit of the tail-fraction interval diff --git a/roofit/roostats/inc/RooStats/MaxLikelihoodEstimateTestStat.h b/roofit/roostats/inc/RooStats/MaxLikelihoodEstimateTestStat.h index 2cbdd98e33e9b..1a5d3ae0323dc 100644 --- a/roofit/roostats/inc/RooStats/MaxLikelihoodEstimateTestStat.h +++ b/roofit/roostats/inc/RooStats/MaxLikelihoodEstimateTestStat.h @@ -91,7 +91,7 @@ class MaxLikelihoodEstimateTestStat: public TestStatistic { RooStats::RemoveConstantParameters(allParams); // need to call constrain for RooSimultaneous until stripDisconnected problem fixed - RooAbsReal* nll = (RooNLLVar*) fPdf->createNLL(data, RooFit::CloneData(kFALSE),RooFit::Constrain(*allParams)); + RooAbsReal* nll = fPdf->createNLL(data, RooFit::CloneData(kFALSE),RooFit::Constrain(*allParams),RooFit::ConditionalObservables(fConditionalObs)); //RooAbsReal* nll = fPdf->createNLL(data, RooFit::CloneData(false)); @@ -149,10 +149,15 @@ class MaxLikelihoodEstimateTestStat: public TestStatistic { virtual void PValueIsRightTail(bool isright) { fUpperLimit = isright; } virtual bool PValueIsRightTail(void) const { return fUpperLimit; } + // set the conditional observables which will be used when creating the NLL + // so the pdf's will not be normalized on the conditional observables when computing the NLL + virtual void SetConditionalObservables(const RooArgSet& set) {fConditionalObs.removeAll(); fConditionalObs.add(set);} + private: RooAbsPdf *fPdf; RooRealVar *fParameter; + RooArgSet fConditionalObs; bool fUpperLimit; TString fMinimizer; Int_t fStrategy; @@ -161,7 +166,7 @@ class MaxLikelihoodEstimateTestStat: public TestStatistic { protected: - ClassDef(MaxLikelihoodEstimateTestStat,1) + ClassDef(MaxLikelihoodEstimateTestStat,2) }; } diff --git a/roofit/roostats/inc/RooStats/MinNLLTestStat.h b/roofit/roostats/inc/RooStats/MinNLLTestStat.h index 8ce6b8d095b1e..2ac7862cdca64 100755 --- a/roofit/roostats/inc/RooStats/MinNLLTestStat.h +++ b/roofit/roostats/inc/RooStats/MinNLLTestStat.h @@ -56,30 +56,45 @@ namespace RooStats { public: MinNLLTestStat() { // Proof constructor. Do not use. - proflts = 0; + fProflts = 0; } MinNLLTestStat(RooAbsPdf& pdf) { - proflts = new ProfileLikelihoodTestStat(pdf); + fProflts = new ProfileLikelihoodTestStat(pdf); + } + + MinNLLTestStat(const MinNLLTestStat& rhs) : TestStatistic(rhs), fProflts(0) { + RooAbsPdf * pdf = rhs.fProflts->GetPdf(); + if (pdf) fProflts = new ProfileLikelihoodTestStat(*pdf); + } + + MinNLLTestStat & operator=(const MinNLLTestStat& rhs) { + if (this == &rhs) return *this; + RooAbsPdf * pdf = rhs.fProflts->GetPdf(); + if (fProflts) delete fProflts; + fProflts = NULL; + if (pdf) fProflts = new ProfileLikelihoodTestStat(*pdf); + return *this; } virtual ~MinNLLTestStat() { - delete proflts; + delete fProflts; } - void SetOneSided(Bool_t flag=true) {proflts->SetOneSided(flag);} - void SetOneSidedDiscovery(Bool_t flag=true) {proflts->SetOneSidedDiscovery(flag);} - void SetReuseNLL(Bool_t flag) { proflts->SetReuseNLL(flag); } - void SetMinimizer(const char* minimizer){ proflts->SetMinimizer(minimizer); } - void SetStrategy(Int_t strategy){ proflts->SetStrategy(strategy); } - void SetTolerance(double tol){ proflts->SetTolerance(tol); } - void SetPrintLevel(Int_t printlevel){ proflts->SetPrintLevel(printlevel); } + void SetOneSided(Bool_t flag=true) {fProflts->SetOneSided(flag);} + void SetOneSidedDiscovery(Bool_t flag=true) {fProflts->SetOneSidedDiscovery(flag);} + void SetReuseNLL(Bool_t flag) { fProflts->SetReuseNLL(flag); } + void SetMinimizer(const char* minimizer){ fProflts->SetMinimizer(minimizer); } + void SetStrategy(Int_t strategy){ fProflts->SetStrategy(strategy); } + void SetTolerance(double tol){ fProflts->SetTolerance(tol); } + void SetPrintLevel(Int_t printlevel){ fProflts->SetPrintLevel(printlevel); } + void SetLOffset(Bool_t flag=kTRUE) { fProflts->SetLOffset(flag) ; } // Main interface to evaluate the test statistic on a dataset virtual Double_t Evaluate(RooAbsData& data, RooArgSet& paramsOfInterest) { - return proflts->EvaluateProfileLikelihood(1, data, paramsOfInterest); //find unconditional NLL minimum + return fProflts->EvaluateProfileLikelihood(1, data, paramsOfInterest); //find unconditional NLL minimum } - virtual void EnableDetailedOutput( bool e=true ) { proflts->EnableDetailedOutput(e); } + virtual void EnableDetailedOutput( bool e=true ) { fProflts->EnableDetailedOutput(e); } virtual const RooArgSet* GetDetailedOutput(void) const { // Returns detailed output. The value returned by this function is updated after each call to Evaluate(). @@ -88,15 +103,15 @@ namespace RooStats { // <li> the minimum nll, fitstatus and convergence quality for each fit </li> // <li> for all non-constant parameters their value, error and pull </li> // </ul> - return proflts->GetDetailedOutput(); + return fProflts->GetDetailedOutput(); } - virtual void SetVarName(const char* name) { proflts->SetVarName(name); } + virtual void SetVarName(const char* name) { fProflts->SetVarName(name); } - virtual const TString GetVarName() const { return proflts->GetVarName(); } + virtual const TString GetVarName() const { return fProflts->GetVarName(); } private: - ProfileLikelihoodTestStat* proflts; + ProfileLikelihoodTestStat* fProflts; protected: ClassDef(MinNLLTestStat,1) // implements the minimum NLL as a test statistic to be used with several tools diff --git a/roofit/roostats/inc/RooStats/ModelConfig.h b/roofit/roostats/inc/RooStats/ModelConfig.h index 209b560faa335..ccd4620070f15 100644 --- a/roofit/roostats/inc/RooStats/ModelConfig.h +++ b/roofit/roostats/inc/RooStats/ModelConfig.h @@ -108,42 +108,99 @@ class ModelConfig : public TNamed { // specify the parameters of interest in the interval virtual void SetParameters(const RooArgSet& set) { - fPOIName=std::string(GetName()) + "_POI"; - DefineSetInWS(fPOIName.c_str(), set); + if (!SetHasOnlyParameters(set,"ModelConfig::SetParameters")) return ; + fPOIName=std::string(GetName()) + "_POI"; + DefineSetInWS(fPOIName.c_str(), set); } + virtual void SetParametersOfInterest(const RooArgSet& set) { + if (!SetHasOnlyParameters(set,"ModelConfig::SetParametersOfInterest")) return ; SetParameters(set); } + // specify the parameters of interest + // through a list of comma-separated arguments already in the workspace + virtual void SetParameters(const char *argList) { + if(!GetWS()) return; + SetParameters(GetWS()->argSet(argList)); + } + virtual void SetParametersOfInterest(const char *argList) { + SetParameters(argList); + } - // specify the nuisance parameters (eg. the rest of the parameters) + // specify the nuisance parameters (e.g. the rest of the parameters) virtual void SetNuisanceParameters(const RooArgSet& set) { + if (!SetHasOnlyParameters(set,"ModelConfig::SetNuisanceParameters")) return ; fNuisParamsName=std::string(GetName()) + "_NuisParams"; DefineSetInWS(fNuisParamsName.c_str(), set); } + // specify the nuisance parameters + // through a list of comma-separated arguments already in the workspace + virtual void SetNuisanceParameters(const char *argList) { + if(!GetWS()) return; + SetNuisanceParameters(GetWS()->argSet(argList)); + } // specify the constraint parameters virtual void SetConstraintParameters(const RooArgSet& set) { + if (!SetHasOnlyParameters(set,"ModelConfig::SetConstainedParameters")) return ; fConstrParamsName=std::string(GetName()) + "_ConstrainedParams"; DefineSetInWS(fConstrParamsName.c_str(), set); } + // specify the constraint parameters + // through a list of comma-separated arguments already in the workspace + virtual void SetConstraintParameters(const char *argList) { + if(!GetWS()) return; + SetConstraintParameters(GetWS()->argSet(argList)); + } // specify the observables virtual void SetObservables(const RooArgSet& set) { + if (!SetHasOnlyParameters(set,"ModelConfig::SetObservables")) return ; fObservablesName=std::string(GetName()) + "_Observables"; DefineSetInWS(fObservablesName.c_str(), set); } + // specify the observables + // through a list of comma-separated arguments already in the workspace + virtual void SetObservables(const char *argList) { + if(!GetWS()) return; + SetObservables(GetWS()->argSet(argList)); + } // specify the conditional observables virtual void SetConditionalObservables(const RooArgSet& set) { + if (!SetHasOnlyParameters(set,"ModelConfig::SetConditionalObservables")) return ; fConditionalObsName=std::string(GetName()) + "_ConditionalObservables"; DefineSetInWS(fConditionalObsName.c_str(), set); } - // specify the conditional observables + // through a list of comma-separated arguments already in the workspace + virtual void SetConditionalObservables(const char *argList) { + if(!GetWS()) return; + SetConditionalObservables(GetWS()->argSet(argList)); + } + + // specify the global observables virtual void SetGlobalObservables(const RooArgSet& set) { + + if (!SetHasOnlyParameters(set,"ModelConfig::SetGlobalObservables")) return ; + + // make global observables constant + RooFIter iter = set.fwdIterator(); + RooAbsArg *arg = iter.next(); + while(arg != NULL) { + arg->setAttribute("Constant", kTRUE); + arg = iter.next(); + } + fGlobalObsName=std::string(GetName()) + "_GlobalObservables"; DefineSetInWS(fGlobalObsName.c_str(), set); } + // specify the global observables + // through a list of comma-separated arguments already in the workspace + virtual void SetGlobalObservables(const char *argList) { + if(!GetWS()) return; + SetGlobalObservables(GetWS()->argSet(argList)); + } // set parameter values for a particular hypothesis if using a common PDF // by saving a snapshot in the workspace @@ -156,7 +213,7 @@ class ModelConfig : public TNamed { if(GetWS()->pdf(name)) fPdfName = name; else - coutE(ObjectHandling) << "pdf "<<name<< " does not exist in workspace"<<endl; + coutE(ObjectHandling) << "pdf "<<name<< " does not exist in workspace"<<std::endl; } // specify the name of the PDF in the workspace to be used @@ -166,7 +223,7 @@ class ModelConfig : public TNamed { if(GetWS()->pdf(name)) fPriorPdfName = name; else - coutE(ObjectHandling) << "pdf "<<name<< " does not exist in workspace"<<endl; + coutE(ObjectHandling) << "pdf "<<name<< " does not exist in workspace"<<std::endl; } @@ -177,7 +234,7 @@ class ModelConfig : public TNamed { if(GetWS()->data(name)) fProtoDataName = name; else - coutE(ObjectHandling) << "dataset "<<name<< " does not exist in workspace"<<endl; + coutE(ObjectHandling) << "dataset "<<name<< " does not exist in workspace"<<std::endl; } @@ -227,6 +284,10 @@ class ModelConfig : public TNamed { virtual void Print(Option_t* option = "") const; protected: + + // helper function to check that content of a given set is exclusively parameters + Bool_t SetHasOnlyParameters(const RooArgSet& set, const char* errorMsgPrefix=0) ; + // helper functions to define a set in the WS void DefineSetInWS(const char* name, const RooArgSet& set); diff --git a/roofit/roostats/inc/RooStats/NeymanConstruction.h b/roofit/roostats/inc/RooStats/NeymanConstruction.h index 187d367d58b0f..e37219f3a68cb 100644 --- a/roofit/roostats/inc/RooStats/NeymanConstruction.h +++ b/roofit/roostats/inc/RooStats/NeymanConstruction.h @@ -66,7 +66,7 @@ namespace RooStats { // void SetNumSteps(Int_t); // This class can make regularly spaced scans based on range stored in RooRealVars. // Choose number of steps for a rastor scan (specific for each dimension) - // void SetNumSteps(map<RooAbsArg, Int_t>) + // void SetNumSteps(std::map<RooAbsArg, Int_t>) // Get the size of the test (eg. rate of Type I error) virtual Double_t Size() const {return fSize;} @@ -82,17 +82,17 @@ namespace RooStats { // Set the Pdf, add to the the workspace if not already there virtual void SetPdf(RooAbsPdf& /*pdf*/) { - cout << "DEPRECATED, use ModelConfig"<<endl; + std::cout << "DEPRECATED, use ModelConfig"<<std::endl; } // specify the parameters of interest in the interval virtual void SetParameters(const RooArgSet& /*set*/) { - cout << "DEPRECATED, use ModelConfig"<<endl; + std::cout << "DEPRECATED, use ModelConfig"<<std::endl; } // specify the nuisance parameters (eg. the rest of the parameters) virtual void SetNuisanceParameters(const RooArgSet& /*set*/) { - cout << "DEPRECATED, use ModelConfig"<<endl; + std::cout << "DEPRECATED, use ModelConfig"<<std::endl; } // set the size of the test (rate of Type I error) ( Eg. 0.05 for a 95% Confidence Interval) diff --git a/roofit/roostats/inc/RooStats/NumEventsTestStat.h b/roofit/roostats/inc/RooStats/NumEventsTestStat.h index 596db048a4e60..dffd17dd0e6f9 100644 --- a/roofit/roostats/inc/RooStats/NumEventsTestStat.h +++ b/roofit/roostats/inc/RooStats/NumEventsTestStat.h @@ -65,7 +65,7 @@ namespace RooStats { virtual Double_t Evaluate(RooAbsData& data, RooArgSet& /*paramsOfInterest*/) { if(!&data) { - cout << "Data set reference is NULL" << endl; + std::cout << "Data set reference is NULL" << std::endl; return 0; } @@ -91,7 +91,7 @@ namespace RooStats { return numEvents; } - cout << "Data set is invalid" << endl; + std::cout << "Data set is invalid" << std::endl; return 0; } diff --git a/roofit/roostats/inc/RooStats/PdfProposal.h b/roofit/roostats/inc/RooStats/PdfProposal.h index 08493d80de8db..c6c8b5f053701 100644 --- a/roofit/roostats/inc/RooStats/PdfProposal.h +++ b/roofit/roostats/inc/RooStats/PdfProposal.h @@ -116,8 +116,8 @@ namespace RooStats { protected: RooAbsPdf* fPdf; // the proposal density function - map<RooRealVar*, RooAbsReal*> fMap; // map of values in pdf to update - map<RooRealVar*, RooAbsReal*>::iterator fIt; // pdf iterator + std::map<RooRealVar*, RooAbsReal*> fMap; // map of values in pdf to update + std::map<RooRealVar*, RooAbsReal*>::iterator fIt; // pdf iterator RooArgSet fLastX; // the last point we were at Int_t fCacheSize; // how many points to generate each time Int_t fCachePosition; // our position in the cached proposal data set diff --git a/roofit/roostats/inc/RooStats/ProfileLikelihoodTestStat.h b/roofit/roostats/inc/RooStats/ProfileLikelihoodTestStat.h index c97071c47bcdf..fb882ea966817 100644 --- a/roofit/roostats/inc/RooStats/ProfileLikelihoodTestStat.h +++ b/roofit/roostats/inc/RooStats/ProfileLikelihoodTestStat.h @@ -66,8 +66,10 @@ namespace RooStats { fLastData = 0; fLimitType = twoSided; fSigned = false; + fDetailedOutputWithErrorsAndPulls = false; fDetailedOutputEnabled = false; fDetailedOutput = NULL; + fLOffset = kFALSE ; fVarName = "Profile Likelihood Ratio"; fReuseNll = false; @@ -84,8 +86,10 @@ namespace RooStats { fLastData = 0; fLimitType = twoSided; fSigned = false; + fDetailedOutputWithErrorsAndPulls = false; fDetailedOutputEnabled = false; fDetailedOutput = NULL; + fLOffset = kFALSE ; fVarName = "Profile Likelihood Ratio"; fReuseNll = false; @@ -101,6 +105,8 @@ namespace RooStats { if(fDetailedOutput) delete fDetailedOutput; } + //LM use default copy constructor and assignment copying the pointers. Is this what we want ? + void SetOneSided(Bool_t flag=true) {fLimitType = (flag ? oneSided : twoSided);} void SetOneSidedDiscovery(Bool_t flag=true) {fLimitType = (flag ? oneSidedDiscovery : twoSided);} void SetSigned(Bool_t flag=true) {fSigned = flag;} // +/- t_mu instead of t_mu>0 with one-sided settings @@ -109,8 +115,10 @@ namespace RooStats { bool IsTwoSided() const { return fLimitType == twoSided; } bool IsOneSidedDiscovery() const { return fLimitType == oneSidedDiscovery; } - static void SetAlwaysReuseNLL(Bool_t flag) { fgAlwaysReuseNll = flag ; } + static void SetAlwaysReuseNLL(Bool_t flag); + void SetReuseNLL(Bool_t flag) { fReuseNll = flag ; } + void SetLOffset(Bool_t flag=kTRUE) { fLOffset = flag ; } void SetMinimizer(const char* minimizer){ fMinimizer=minimizer;} void SetStrategy(Int_t strategy){fStrategy=strategy;} @@ -128,6 +136,7 @@ namespace RooStats { virtual void EnableDetailedOutput( bool e=true, bool withErrorsAndPulls=false ) { fDetailedOutputEnabled = e; fDetailedOutputWithErrorsAndPulls = withErrorsAndPulls; + delete fDetailedOutput; fDetailedOutput = NULL; } virtual const RooArgSet* GetDetailedOutput(void) const { @@ -139,9 +148,16 @@ namespace RooStats { // </ul> return fDetailedOutput; } - + + // set the conditional observables which will be used when creating the NLL + // so the pdf's will not be normalized on the conditional observables when computing the NLL + virtual void SetConditionalObservables(const RooArgSet& set) {fConditionalObs.removeAll(); fConditionalObs.add(set);} + virtual void SetVarName(const char* name) { fVarName = name; } virtual const TString GetVarName() const {return fVarName;} + + virtual RooAbsPdf * GetPdf() const { return fPdf; } + // const bool PValueIsRightTail(void) { return false; } // overwrites default @@ -152,7 +168,7 @@ namespace RooStats { private: RooAbsPdf* fPdf; - RooNLLVar* fNll; //! + RooAbsReal* fNll; //! const RooArgSet* fCachedBestFitParams; RooAbsData* fLastData; // Double_t fLastMLE; @@ -164,6 +180,7 @@ namespace RooStats { bool fDetailedOutputEnabled; bool fDetailedOutputWithErrorsAndPulls; RooArgSet* fDetailedOutput; //! + RooArgSet fConditionalObs; // conditional observables TString fVarName; @@ -173,10 +190,11 @@ namespace RooStats { Int_t fStrategy; Double_t fTolerance; Int_t fPrintLevel; + Bool_t fLOffset ; protected: - ClassDef(ProfileLikelihoodTestStat,8) // implements the profile likelihood ratio as a test statistic to be used with several tools + ClassDef(ProfileLikelihoodTestStat,9) // implements the profile likelihood ratio as a test statistic to be used with several tools }; } diff --git a/roofit/roostats/inc/RooStats/ProposalHelper.h b/roofit/roostats/inc/RooStats/ProposalHelper.h index 85cbe9a8a24a9..e97895b44a402 100644 --- a/roofit/roostats/inc/RooStats/ProposalHelper.h +++ b/roofit/roostats/inc/RooStats/ProposalHelper.h @@ -60,7 +60,7 @@ namespace RooStats { fCacheSize = size; else coutE(Eval) << "Warning: Requested non-positive cache size: " << - size << ". Cache size unchanged." << endl; + size << ". Cache size unchanged." << std::endl; } virtual void SetUpdateProposalParameters(Bool_t updateParams) diff --git a/roofit/roostats/inc/RooStats/RatioOfProfiledLikelihoodsTestStat.h b/roofit/roostats/inc/RooStats/RatioOfProfiledLikelihoodsTestStat.h index 4a13af3e6ea90..7c4b7ecb44765 100644 --- a/roofit/roostats/inc/RooStats/RatioOfProfiledLikelihoodsTestStat.h +++ b/roofit/roostats/inc/RooStats/RatioOfProfiledLikelihoodsTestStat.h @@ -100,82 +100,24 @@ class RatioOfProfiledLikelihoodsTestStat: public TestStatistic { if(fAltPOI) delete fAltPOI; if(fDetailedOutput) delete fDetailedOutput; } + + + // returns -logL(poi, conditional MLE of nuisance params) + // it does not subtract off the global MLE + // because nuisance parameters of null and alternate may not + // be the same. + Double_t ProfiledLikelihood(RooAbsData& data, RooArgSet& poi, RooAbsPdf& pdf); - //__________________________________________ - Double_t ProfiledLikelihood(RooAbsData& data, RooArgSet& poi, RooAbsPdf& pdf) { - // returns -logL(poi, conditonal MLE of nuisance params) - // it does not subtract off the global MLE - // because nuisance parameters of null and alternate may not - // be the same. - RooAbsReal* nll = pdf.createNLL(data, RooFit::CloneData(kFALSE)); - RooAbsReal* profile = nll->createProfile(poi); - // make sure we set the variables attached to this nll - RooArgSet* attachedSet = nll->getVariables(); - *attachedSet = poi; - // now evaluate profile to set nuisance to conditional MLE values - double nllVal = profile->getVal(); - // but we may want the nll value without subtracting off the MLE - if(!fSubtractMLE) nllVal = nll->getVal(); - - delete attachedSet; - delete profile; - delete nll; - - return nllVal; - } + // evaluate the ratio of profile likelihood + virtual Double_t Evaluate(RooAbsData& data, RooArgSet& nullParamsOfInterest); - //__________________________________________ - virtual Double_t Evaluate(RooAbsData& data, RooArgSet& nullParamsOfInterest) { - // evaluate the ratio of profile likelihood - - - int type = (fSubtractMLE) ? 0 : 2; - - // null - double nullNLL = fNullProfile.EvaluateProfileLikelihood(type, data, nullParamsOfInterest); - const RooArgSet *nullset = fNullProfile.GetDetailedOutput(); - - // alt - double altNLL = fAltProfile.EvaluateProfileLikelihood(type, data, *fAltPOI); - const RooArgSet *altset = fAltProfile.GetDetailedOutput(); - - if (fDetailedOutput != NULL) { - delete fDetailedOutput; - fDetailedOutput = NULL; - } - if (fDetailedOutputEnabled) { - fDetailedOutput = new RooArgSet(); - RooRealVar* var(0); - for(TIterator *it = nullset->createIterator();(var = dynamic_cast<RooRealVar*>(it->Next()));) { - RooRealVar* cloneVar = new RooRealVar(TString::Format("nullprof_%s", var->GetName()), - TString::Format("%s for null", var->GetTitle()), var->getVal()); - fDetailedOutput->addOwned(*cloneVar); - } - for(TIterator *it = altset->createIterator();(var = dynamic_cast<RooRealVar*>(it->Next()));) { - RooRealVar* cloneVar = new RooRealVar(TString::Format("altprof_%s", var->GetName()), - TString::Format("%s for null", var->GetTitle()), var->getVal()); - fDetailedOutput->addOwned(*cloneVar); - } - } - -/* - // set variables back to where they were - nullParamsOfInterest = *saveNullPOI; - *allVars = *saveAll; - delete saveAll; - delete allVars; -*/ - - return nullNLL -altNLL; - } - - virtual void EnableDetailedOutput( bool e=true ) { - fDetailedOutputEnabled = e; - fNullProfile.EnableDetailedOutput(fDetailedOutputEnabled); - fAltProfile.EnableDetailedOutput(fDetailedOutputEnabled); - } + virtual void EnableDetailedOutput( bool e=true ) { + fDetailedOutputEnabled = e; + fNullProfile.EnableDetailedOutput(fDetailedOutputEnabled); + fAltProfile.EnableDetailedOutput(fDetailedOutputEnabled); + } - static void SetAlwaysReuseNLL(Bool_t flag) { fgAlwaysReuseNll = flag ; } + static void SetAlwaysReuseNLL(Bool_t flag); void SetReuseNLL(Bool_t flag) { fNullProfile.SetReuseNLL(flag); @@ -198,7 +140,14 @@ class RatioOfProfiledLikelihoodsTestStat: public TestStatistic { fNullProfile.SetPrintLevel(printLevel); fAltProfile.SetPrintLevel(printLevel); } - + + // set the conditional observables which will be used when creating the NLL + // so the pdf's will not be normalized on the conditional observables when computing the NLL + virtual void SetConditionalObservables(const RooArgSet& set) { + fNullProfile.SetConditionalObservables(set); + fAltProfile.SetConditionalObservables(set); + } + virtual const RooArgSet* GetDetailedOutput(void) const { // Returns detailed output. The value returned by this function is updated after each call to Evaluate(). // The returned RooArgSet contains the following for the alternative and null hypotheses: @@ -208,6 +157,8 @@ class RatioOfProfiledLikelihoodsTestStat: public TestStatistic { // </ul> return fDetailedOutput; } + + virtual const TString GetVarName() const { return "log(L(#mu_{1},#hat{#nu}_{1}) / L(#mu_{0},#hat{#nu}_{0}))"; } @@ -217,6 +168,7 @@ class RatioOfProfiledLikelihoodsTestStat: public TestStatistic { void SetSubtractMLE(bool subtract){fSubtractMLE = subtract;} private: + ProfileLikelihoodTestStat fNullProfile; ProfileLikelihoodTestStat fAltProfile; @@ -229,7 +181,7 @@ class RatioOfProfiledLikelihoodsTestStat: public TestStatistic { protected: - ClassDef(RatioOfProfiledLikelihoodsTestStat,3) + ClassDef(RatioOfProfiledLikelihoodsTestStat,3) // implements the ratio of profiled likelihood as test statistic }; } diff --git a/roofit/roostats/inc/RooStats/RooStatsUtils.h b/roofit/roostats/inc/RooStats/RooStatsUtils.h index 39875ea4e4d6a..3efb04ca8bee9 100644 --- a/roofit/roostats/inc/RooStats/RooStatsUtils.h +++ b/roofit/roostats/inc/RooStats/RooStatsUtils.h @@ -61,7 +61,17 @@ namespace RooStats { set->remove(constSet); } - inline bool SetAllConstant(const RooAbsCollection &coll, bool constant = true) { + inline void RemoveConstantParameters(RooArgList& set){ + RooArgSet constSet; + RooLinkedListIter it = set.iterator(); + RooRealVar *myarg; + while ((myarg = (RooRealVar *)it.Next())) { + if(myarg->isConstant()) constSet.add(*myarg); + } + set.remove(constSet); + } + + inline bool SetAllConstant(const RooAbsCollection &coll, bool constant = true) { // utility function to set all variable constant in a collection // (from G. Petrucciani) bool changed = false; @@ -103,9 +113,12 @@ namespace RooStats { void FactorizePdf(RooStats::ModelConfig &model, RooAbsPdf &pdf, RooArgList &obsTerms, RooArgList &constraints); + // extract constraint terms from pdf RooAbsPdf * MakeNuisancePdf(RooAbsPdf &pdf, const RooArgSet &observables, const char *name); - RooAbsPdf * MakeNuisancePdf(const RooStats::ModelConfig &model, const char *name); + // remove constraints from pdf and return the unconstrained pdf + RooAbsPdf * MakeUnconstrainedPdf(RooAbsPdf &pdf, const RooArgSet &observables, const char *name = NULL); + RooAbsPdf * MakeUnconstrainedPdf(const RooStats::ModelConfig &model, const char *name = NULL); // Create a TTree with the given name and description. All RooRealVars in the RooDataSet are represented as branches that contain values of type Double_t. TTree* GetAsTTree(TString name, TString desc, const RooDataSet& data); diff --git a/roofit/roostats/inc/RooStats/SamplingDistPlot.h b/roofit/roostats/inc/RooStats/SamplingDistPlot.h index 31c8185ef1143..b817f9895c577 100644 --- a/roofit/roostats/inc/RooStats/SamplingDistPlot.h +++ b/roofit/roostats/inc/RooStats/SamplingDistPlot.h @@ -129,7 +129,7 @@ namespace RooStats { void addObject(TObject *obj, Option_t *drawOptions=0); // for TH1Fs only void addOtherObject(TObject *obj, Option_t *drawOptions=0); - void GetAbsoluteInterval(Float_t &theMin, Float_t &theMax, Float_t &theYMax) const; + void GetAbsoluteInterval(Double_t &theMin, Double_t &theMax, Double_t &theYMax) const; ClassDef(SamplingDistPlot,1) // Class containing the results of the HybridCalculator }; diff --git a/roofit/roostats/inc/RooStats/SimpleInterval.h b/roofit/roostats/inc/RooStats/SimpleInterval.h index ea6dc59aba848..8ed233c6456b1 100644 --- a/roofit/roostats/inc/RooStats/SimpleInterval.h +++ b/roofit/roostats/inc/RooStats/SimpleInterval.h @@ -27,6 +27,10 @@ namespace RooStats { // default constructors explicit SimpleInterval(const char* name = 0); + SimpleInterval(const SimpleInterval& other, const char* name); + + SimpleInterval& operator=(const SimpleInterval& other) ; + // constructor from name, the Parameter of interest and lower/upper bound values SimpleInterval(const char* name, const RooRealVar & var, Double_t lower, Double_t upper, Double_t cl); diff --git a/roofit/roostats/inc/RooStats/SimpleLikelihoodRatioTestStat.h b/roofit/roostats/inc/RooStats/SimpleLikelihoodRatioTestStat.h index 1b440ff825bcb..f0b76797ea8ed 100644 --- a/roofit/roostats/inc/RooStats/SimpleLikelihoodRatioTestStat.h +++ b/roofit/roostats/inc/RooStats/SimpleLikelihoodRatioTestStat.h @@ -41,7 +41,7 @@ namespace RooStats { -class SimpleLikelihoodRatioTestStat : public TestStatistic { + class SimpleLikelihoodRatioTestStat : public TestStatistic { public: @@ -80,8 +80,8 @@ class SimpleLikelihoodRatioTestStat : public TestStatistic { fAltParameters = (RooArgSet*) allAltVars->snapshot(); delete allAltVars; - fDetailedOutputEnabled = false; - fDetailedOutput = NULL; + fDetailedOutputEnabled = false; + fDetailedOutput = NULL; fReuseNll=kFALSE ; fNllNull=NULL ; @@ -104,8 +104,8 @@ class SimpleLikelihoodRatioTestStat : public TestStatistic { fNullParameters = (RooArgSet*) nullParameters.snapshot(); fAltParameters = (RooArgSet*) altParameters.snapshot(); - fDetailedOutputEnabled = false; - fDetailedOutput = NULL; + fDetailedOutputEnabled = false; + fDetailedOutput = NULL; fReuseNll=kFALSE ; fNllNull=NULL ; @@ -121,8 +121,9 @@ class SimpleLikelihoodRatioTestStat : public TestStatistic { if (fDetailedOutput) delete fDetailedOutput; } - static void SetAlwaysReuseNLL(Bool_t flag) { fAlwaysReuseNll = flag ; } - void SetReuseNLL(Bool_t flag) { fReuseNll = flag ; } + static void SetAlwaysReuseNLL(Bool_t flag); + + void SetReuseNLL(Bool_t flag) { fReuseNll = flag ; } //_________________________________________ void SetNullParameters(const RooArgSet& nullParameters) { @@ -159,94 +160,13 @@ class SimpleLikelihoodRatioTestStat : public TestStatistic { return ret; } - //______________________________ - virtual Double_t Evaluate(RooAbsData& data, RooArgSet& nullPOI) { - - if (fFirstEval && ParamsAreEqual()) { - oocoutW(fNullParameters,InputArguments) - << "Same RooArgSet used for null and alternate, so you must explicitly SetNullParameters and SetAlternateParameters or the likelihood ratio will always be 1." - << endl; - } - fFirstEval = false; - - RooFit::MsgLevel msglevel = RooMsgService::instance().globalKillBelow(); - RooMsgService::instance().setGlobalKillBelow(RooFit::FATAL); - - Bool_t reuse = (fReuseNll || fAlwaysReuseNll) ; - - Bool_t created = kFALSE ; - if (!fNllNull) { - RooArgSet* allParams = fNullPdf->getParameters(data); - fNllNull = (RooNLLVar*) fNullPdf->createNLL(data, RooFit::CloneData(kFALSE),RooFit::Constrain(*allParams)); - delete allParams; - created = kTRUE ; - } - if (reuse && !created) { - fNllNull->setData(data, kFALSE) ; - } - - // make sure we set the variables attached to this nll - RooArgSet* attachedSet = fNllNull->getVariables(); - *attachedSet = *fNullParameters; - *attachedSet = nullPOI; - double nullNLL = fNllNull->getVal(); - - //cout << endl << "SLRTS: null params:" << endl; - //attachedSet->Print("v"); - - - if (!reuse) { - delete fNllNull ; fNllNull = NULL ; - } - delete attachedSet; - - created = kFALSE ; - if (!fNllAlt) { - RooArgSet* allParams = fAltPdf->getParameters(data); - fNllAlt = (RooNLLVar*) fAltPdf->createNLL(data, RooFit::CloneData(kFALSE),RooFit::Constrain(*allParams)); - delete allParams; - created = kTRUE ; - } - if (reuse && !created) { - fNllAlt->setData(data, kFALSE) ; - } - // make sure we set the variables attached to this nll - attachedSet = fNllAlt->getVariables(); - *attachedSet = *fAltParameters; - double altNLL = fNllAlt->getVal(); - - //cout << endl << "SLRTS: alt params:" << endl; - //attachedSet->Print("v"); - - //cout << endl << "SLRTS null NLL: " << nullNLL << " alt NLL: " << altNLL << endl << endl; + // set the conditional observables which will be used when creating the NLL + // so the pdf's will not be normalized on the conditional observables when computing the NLL + virtual void SetConditionalObservables(const RooArgSet& set) {fConditionalObs.removeAll(); fConditionalObs.add(set);} - - if (!reuse) { - delete fNllAlt ; fNllAlt = NULL ; - } - delete attachedSet; - - - - // save this snapshot - if( fDetailedOutputEnabled ) { - if( !fDetailedOutput ) { - fDetailedOutput = new RooArgSet( *(new RooRealVar("nullNLL","null NLL",0)), "detailedOut_SLRTS" ); - fDetailedOutput->add( *(new RooRealVar("altNLL","alternate NLL",0)) ); - } - fDetailedOutput->setRealValue( "nullNLL", nullNLL ); - fDetailedOutput->setRealValue( "altNLL", altNLL ); - -// cout << endl << "STORING THIS AS DETAILED OUTPUT:" << endl; -// fDetailedOutput->Print("v"); -// cout << endl; - } - - - RooMsgService::instance().setGlobalKillBelow(msglevel); - return nullNLL - altNLL; - } + //______________________________ + virtual Double_t Evaluate(RooAbsData& data, RooArgSet& nullPOI); virtual void EnableDetailedOutput( bool e=true ) { fDetailedOutputEnabled = e; fDetailedOutput = NULL; } virtual const RooArgSet* GetDetailedOutput(void) const { return fDetailedOutput; } @@ -261,19 +181,20 @@ class SimpleLikelihoodRatioTestStat : public TestStatistic { RooAbsPdf* fAltPdf; RooArgSet* fNullParameters; RooArgSet* fAltParameters; + RooArgSet fConditionalObs; bool fFirstEval; bool fDetailedOutputEnabled; RooArgSet* fDetailedOutput; //! - RooNLLVar* fNllNull ; //! transient copy of the null NLL - RooNLLVar* fNllAlt ; //! transient copy of the alt NLL - static Bool_t fAlwaysReuseNll ; + RooAbsReal* fNllNull ; //! transient copy of the null NLL + RooAbsReal* fNllAlt ; //! transient copy of the alt NLL + static Bool_t fgAlwaysReuseNll ; Bool_t fReuseNll ; protected: - ClassDef(SimpleLikelihoodRatioTestStat,2) + ClassDef(SimpleLikelihoodRatioTestStat,3) }; } diff --git a/roofit/roostats/inc/RooStats/ToyMCImportanceSampler.h b/roofit/roostats/inc/RooStats/ToyMCImportanceSampler.h index 64339c5a90a29..cbe9aa2071325 100644 --- a/roofit/roostats/inc/RooStats/ToyMCImportanceSampler.h +++ b/roofit/roostats/inc/RooStats/ToyMCImportanceSampler.h @@ -75,9 +75,9 @@ class ToyMCImportanceSampler: public ToyMCSampler { using ToyMCSampler::GenerateToyData; virtual RooAbsData* GenerateToyData(RooArgSet& paramPoint, double& weight) const; - virtual RooAbsData* GenerateToyData(RooArgSet& paramPoint, double& weight, vector<double>& impNLLs, double& nullNLL) const; - virtual RooAbsData* GenerateToyData(vector<double>& weights) const; - virtual RooAbsData* GenerateToyData(vector<double>& weights, vector<double>& nullNLLs, vector<double>& impNLLs) const; + virtual RooAbsData* GenerateToyData(RooArgSet& paramPoint, double& weight, std::vector<double>& impNLLs, double& nullNLL) const; + virtual RooAbsData* GenerateToyData(std::vector<double>& weights) const; + virtual RooAbsData* GenerateToyData(std::vector<double>& weights, std::vector<double>& nullNLLs, std::vector<double>& impNLLs) const; /// specifies the pdf to sample from @@ -87,7 +87,7 @@ class ToyMCImportanceSampler: public ToyMCSampler { ) { oocoutE((TObject*)0,InputArguments) << "Index out of range. Requested index: "<<i<< " , but null densities: "<<fNullDensities.size()<< - " and importance densities: "<<fImportanceDensities.size() << endl; + " and importance densities: "<<fImportanceDensities.size() << std::endl; } fIndexGenDensity = i; @@ -103,11 +103,11 @@ class ToyMCImportanceSampler: public ToyMCSampler { // is used. The snapshot is also optional. void AddImportanceDensity(RooAbsPdf* p, const RooArgSet* s) { if( p == NULL && s == NULL ) { - oocoutI((TObject*)0,InputArguments) << "Neither density nor snapshot given. Doing nothing." << endl; + oocoutI((TObject*)0,InputArguments) << "Neither density nor snapshot given. Doing nothing." << std::endl; return; } if( p == NULL && fPdf == NULL ) { - oocoutE((TObject*)0,InputArguments) << "No density given, but snapshot is there. Aborting." << endl; + oocoutE((TObject*)0,InputArguments) << "No density given, but snapshot is there. Aborting." << std::endl; return; } @@ -124,7 +124,7 @@ class ToyMCImportanceSampler: public ToyMCSampler { // is used. The snapshot and TestStatistic is also optional. void AddNullDensity(RooAbsPdf* p, const RooArgSet* s = NULL) { if( p == NULL && s == NULL ) { - oocoutI((TObject*)0,InputArguments) << "Neither density nor snapshot nor test statistic given. Doing nothing." << endl; + oocoutI((TObject*)0,InputArguments) << "Neither density nor snapshot nor test statistic given. Doing nothing." << std::endl; return; } @@ -144,7 +144,7 @@ class ToyMCImportanceSampler: public ToyMCSampler { if( fNullDensities.size() == 1 ) { fNullDensities[0] = &pdf; } else if( fNullDensities.size() == 0) AddNullDensity( &pdf ); else{ - oocoutE((TObject*)0,InputArguments) << "Cannot use SetPdf() when already multiple null densities are specified. Please use AddNullDensity()." << endl; + oocoutE((TObject*)0,InputArguments) << "Cannot use SetPdf() when already multiple null densities are specified. Please use AddNullDensity()." << std::endl; } } // overwrite from ToyMCSampler @@ -152,11 +152,11 @@ class ToyMCImportanceSampler: public ToyMCSampler { ToyMCSampler::SetParametersForTestStat(nullpoi); if( fNullSnapshots.size() == 0 ) AddNullDensity( NULL, &nullpoi ); else if( fNullSnapshots.size() == 1 ) { - oocoutI((TObject*)0,InputArguments) << "Overwriting snapshot for the only defined null density." << endl; + oocoutI((TObject*)0,InputArguments) << "Overwriting snapshot for the only defined null density." << std::endl; if( fNullSnapshots[0] ) delete fNullSnapshots[0]; fNullSnapshots[0] = (const RooArgSet*)nullpoi.snapshot(); }else{ - oocoutE((TObject*)0,InputArguments) << "Cannot use SetParametersForTestStat() when already multiple null densities are specified. Please use AddNullDensity()." << endl; + oocoutE((TObject*)0,InputArguments) << "Cannot use SetParametersForTestStat() when already multiple null densities are specified. Please use AddNullDensity()." << std::endl; } } @@ -169,6 +169,12 @@ class ToyMCImportanceSampler: public ToyMCSampler { void SetReuseNLL(bool r = true) { fReuseNLL = r; } + // set the conditional observables which will be used when creating the NLL + // so the pdf's will not be normalized on the conditional observables when computing the NLL + // Since the class use a NLL we need to set the ocnditional onservables if they exist in the model + virtual void SetConditionalObservables(const RooArgSet& set) {fConditionalObs.removeAll(); fConditionalObs.add(set);} + + int CreateNImpDensitiesForOnePOI( RooAbsPdf& pdf, const RooArgSet& allPOI, @@ -196,24 +202,26 @@ class ToyMCImportanceSampler: public ToyMCSampler { bool fGenerateFromNull; bool fApplyVeto; + RooArgSet fConditionalObs; // set of conditional observables + // support multiple null densities - vector<RooAbsPdf*> fNullDensities; - mutable vector<const RooArgSet*> fNullSnapshots; + std::vector<RooAbsPdf*> fNullDensities; + mutable std::vector<const RooArgSet*> fNullSnapshots; // densities and snapshots to generate from - vector<RooAbsPdf*> fImportanceDensities; - vector<const RooArgSet*> fImportanceSnapshots; + std::vector<RooAbsPdf*> fImportanceDensities; + std::vector<const RooArgSet*> fImportanceSnapshots; bool fReuseNLL; toysStrategies fToysStrategy; - mutable vector<RooAbsReal*> fNullNLLs; //! - mutable vector<RooAbsReal*> fImpNLLs; //! + mutable std::vector<RooAbsReal*> fNullNLLs; //! + mutable std::vector<RooAbsReal*> fImpNLLs; //! protected: - ClassDef(ToyMCImportanceSampler,1) // An implementation of importance sampling + ClassDef(ToyMCImportanceSampler,2) // An implementation of importance sampling }; } diff --git a/roofit/roostats/inc/RooStats/ToyMCSampler.h b/roofit/roostats/inc/RooStats/ToyMCSampler.h index 31460eb18e177..8fe77b4569493 100644 --- a/roofit/roostats/inc/RooStats/ToyMCSampler.h +++ b/roofit/roostats/inc/RooStats/ToyMCSampler.h @@ -53,6 +53,8 @@ END_HTML namespace RooStats { + class DetailedOutputAggregator; + // only used inside ToyMCSampler, ie "private" in the cxx file class NuisanceParametersSampler { // Helper for ToyMCSampler. Handles all of the nuisance parameter related @@ -96,8 +98,9 @@ class ToyMCSampler: public TestStatSampler { ToyMCSampler(); ToyMCSampler(TestStatistic &ts, Int_t ntoys); virtual ~ToyMCSampler(); + + static void SetAlwaysUseMultiGen(Bool_t flag); - static void SetAlwaysUseMultiGen(Bool_t flag) { fgAlwaysUseMultiGen = flag ; } void SetUseMultiGen(Bool_t flag) { fUseMultiGen = flag ; } // main interface @@ -116,11 +119,12 @@ class ToyMCSampler: public TestStatSampler { // is used. The snapshot and TestStatistic is also optional. virtual void AddTestStatistic(TestStatistic* t = NULL) { if( t == NULL ) { - oocoutI((TObject*)0,InputArguments) << "No test statistic given. Doing nothing." << endl; + oocoutI((TObject*)0,InputArguments) << "No test statistic given. Doing nothing." << std::endl; return; } + + //if( t == NULL && fTestStatistics.size() >= 1 ) t = fTestStatistics[0]; - if( t == NULL && fTestStatistics.size() >= 1 ) t = fTestStatistics[0]; fTestStatistics.push_back( t ); } @@ -129,7 +133,7 @@ class ToyMCSampler: public TestStatSampler { // generates toy data // without weight virtual RooAbsData* GenerateToyData(RooArgSet& paramPoint, RooAbsPdf& pdf) const { - if(fExpectedNuisancePar) oocoutE((TObject*)NULL,InputArguments) << "ToyMCSampler: using expected nuisance parameters but ignoring weight. Use GetSamplingDistribution(paramPoint, weight) instead." << endl; + if(fExpectedNuisancePar) oocoutE((TObject*)NULL,InputArguments) << "ToyMCSampler: using expected nuisance parameters but ignoring weight. Use GetSamplingDistribution(paramPoint, weight) instead." << std::endl; double weight; return GenerateToyData(paramPoint, weight, pdf); } @@ -147,18 +151,7 @@ class ToyMCSampler: public TestStatSampler { return fTestStatistics[i]->Evaluate(data, nullPOI); } virtual Double_t EvaluateTestStatistic(RooAbsData& data, RooArgSet& nullPOI) { return EvaluateTestStatistic( data,nullPOI, 0 ); } - virtual RooArgList* EvaluateAllTestStatistics(RooAbsData& data, RooArgSet& nullPOI) { - RooArgList* allTS = new RooArgList( "allTS" ); - for( unsigned int i = 0; i < fTestStatistics.size(); i++ ) { - if( fTestStatistics[i] == NULL ) continue; - allTS->add( *(new RooRealVar( - TString::Format( "%s_TS%d", fSamplingDistName.c_str(),i ), - fTestStatistics[i]->GetVarName(), - fTestStatistics[i]->Evaluate( data, nullPOI ) - ) ) ); - } - return allTS; - } + virtual RooArgList* EvaluateAllTestStatistics(RooAbsData& data, const RooArgSet& poi); virtual TestStatistic* GetTestStatistic(unsigned int i) const { @@ -192,7 +185,13 @@ class ToyMCSampler: public TestStatSampler { virtual void SetPdf(RooAbsPdf& pdf) { fPdf = &pdf; ClearCache(); } // How to randomize the prior. Set to NULL to deactivate randomization. - virtual void SetPriorNuisance(RooAbsPdf* pdf) { fPriorNuisance = pdf; } + virtual void SetPriorNuisance(RooAbsPdf* pdf) { + fPriorNuisance = pdf; + if (fNuisanceParametersSampler) { + delete fNuisanceParametersSampler; + fNuisanceParametersSampler = NULL; + } + } // specify the nuisance parameters (eg. the rest of the parameters) virtual void SetNuisanceParameters(const RooArgSet& np) { fNuisancePars = &np; } // specify the observables in the dataset (needed to evaluate the test statistic) @@ -209,7 +208,7 @@ class ToyMCSampler: public TestStatSampler { // Set the TestStatistic (want the argument to be a function of the data & parameter points virtual void SetTestStatistic(TestStatistic *testStatistic, unsigned int i) { if( fTestStatistics.size() < i ) { - oocoutE((TObject*)NULL,InputArguments) << "Cannot set test statistic for this index." << endl; + oocoutE((TObject*)NULL,InputArguments) << "Cannot set test statistic for this index." << std::endl; return; } if( fTestStatistics.size() == i) @@ -234,7 +233,7 @@ class ToyMCSampler: public TestStatSampler { // Set the name of the sampling distribution used for plotting void SetSamplingDistName(const char* name) { if(name) fSamplingDistName = name; } - string GetSamplingDistName(void) { return fSamplingDistName; } + std::string GetSamplingDistName(void) { return fSamplingDistName; } // This option forces a maximum number of total toys. void SetMaxToys(Double_t t) { fMaxToys = t; } @@ -262,6 +261,8 @@ class ToyMCSampler: public TestStatSampler { protected: + const RooArgList* EvaluateAllTestStatistics(RooAbsData& data, const RooArgSet& poi, DetailedOutputAggregator& detOutAgg); + // helper for GenerateToyData RooAbsData* Generate(RooAbsPdf &pdf, RooArgSet &observables, const RooDataSet *protoData=NULL, int forceEvents=0) const; @@ -272,9 +273,9 @@ class ToyMCSampler: public TestStatSampler { // densities, snapshots, and test statistics to reweight to RooAbsPdf *fPdf; // model (can be alt or null) const RooArgSet* fParametersForTestStat; - vector<TestStatistic*> fTestStatistics; + std::vector<TestStatistic*> fTestStatistics; - string fSamplingDistName; // name of the model + std::string fSamplingDistName; // name of the model RooAbsPdf *fPriorNuisance; // prior pdf for nuisance parameters const RooArgSet *fNuisancePars; const RooArgSet *fObservables; @@ -306,9 +307,9 @@ class ToyMCSampler: public TestStatSampler { // objects below cache information and are mutable and non-persistent mutable RooArgSet* _allVars ; //! - mutable list<RooAbsPdf*> _pdfList ; //! - mutable list<RooArgSet*> _obsList ; //! - mutable list<RooAbsPdf::GenSpec*> _gsList ; //! + mutable std::list<RooAbsPdf*> _pdfList ; //! + mutable std::list<RooArgSet*> _obsList ; //! + mutable std::list<RooAbsPdf::GenSpec*> _gsList ; //! mutable RooAbsPdf::GenSpec* _gs1 ; //! GenSpec #1 mutable RooAbsPdf::GenSpec* _gs2 ; //! GenSpec #2 mutable RooAbsPdf::GenSpec* _gs3 ; //! GenSpec #3 diff --git a/roofit/roostats/inc/RooStats/ToyMCSamplerOld.h b/roofit/roostats/inc/RooStats/ToyMCSamplerOld.h deleted file mode 100644 index 90025d93541f0..0000000000000 --- a/roofit/roostats/inc/RooStats/ToyMCSamplerOld.h +++ /dev/null @@ -1,322 +0,0 @@ -// @(#)root/roostats:$Id$ -// Author: Kyle Cranmer, Lorenzo Moneta, Gregory Schott, Wouter Verkerke -// Additions and modifications by Mario Pelliccioni -/************************************************************************* - * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * - * All rights reserved. * - * * - * For the licensing terms see $ROOTSYS/LICENSE. * - * For the list of contributors see $ROOTSYS/README/CREDITS. * - *************************************************************************/ - -#ifndef ROOSTATS_ToyMCSamplerOld -#define ROOSTATS_ToyMCSamplerOld - -//_________________________________________________ -/* -BEGIN_HTML -<p> -ToyMCSamplerOld is a simple implementation of the TestStatSampler interface. -It generates Toy Monte Carlo for a given parameter point, and evaluates a -test statistic that the user specifies (passed via the RooStats::TestStatistic interface). - -Development notes: We need to provide a nice way for the user to: -<ul> - <li>specify the number of toy experiments (needed to probe a given confidence level)</li> - <li>specify if the number of events per toy experiment should be fixed (conditioning) or floating (unconditional)</li> - <li>specify if any auxiliary observations should be fixed (conditioning) or floating (unconditional)</li> - <li>specify if nuisance paramters should be part of the toy MC: eg: integrated out (Bayesian marginalization)</li> -</ul> - -All of these should be made fairly explicit in the interface. -</p> -END_HTML -*/ -// - -#ifndef ROOT_Rtypes -#include "Rtypes.h" -#endif - -#include <vector> -#include <string> -#include <sstream> - -#include "RooStats/TestStatSampler.h" -#include "RooStats/SamplingDistribution.h" -#include "RooStats/TestStatistic.h" -#include "RooStats/RooStatsUtils.h" - -#include "RooWorkspace.h" -#include "RooMsgService.h" -#include "RooAbsPdf.h" -#include "TRandom.h" - -#include "RooDataSet.h" - -namespace RooStats { - - class ToyMCSamplerOld : public TestStatSampler { - - - public: - ToyMCSamplerOld(TestStatistic &ts) { - fTestStat = &ts; - fWS = new RooWorkspace(); - fOwnsWorkspace = true; - fDataName = ""; - fPdfName = ""; - fNullPOI = 0; - fNuisParams=0; - fObservables=0; - fExtended = kTRUE; - fRand = new TRandom(); - fCounter=0; - fVarName = fTestStat->GetVarName(); - fLastDataSet = 0; - fNevents = 0; - fNtoys = 0; - fSize = 0.05; - } - - virtual ~ToyMCSamplerOld() { - if(fOwnsWorkspace) delete fWS; - if(fRand) delete fRand; - if(fLastDataSet) delete fLastDataSet; - } - - // Extended interface to append to sampling distribution more samples - virtual SamplingDistribution* AppendSamplingDistribution(RooArgSet& allParameters, - SamplingDistribution* last, - Int_t additionalMC) { - - Int_t tmp = fNtoys; - fNtoys = additionalMC; - SamplingDistribution* newSamples = GetSamplingDistribution(allParameters); - fNtoys = tmp; - - if(last){ - last->Add(newSamples); - delete newSamples; - return last; - } - - return newSamples; - } - - // Main interface to get a SamplingDistribution - virtual SamplingDistribution* GetSamplingDistribution(RooArgSet& allParameters) { - std::vector<Double_t> testStatVec; - // cout << " about to generate sampling dist " << endl; - - RooFit::MsgLevel msglevel = RooMsgService::instance().globalKillBelow(); - RooMsgService::instance().setGlobalKillBelow(RooFit::ERROR) ; - - for(Int_t i=0; i<fNtoys; ++i){ - //cout << " on toy number " << i << endl; - // RooAbsData* toydata = (RooAbsData*)GenerateToyData(allParameters); - // testStatVec.push_back( fTestStat->Evaluate(*toydata, allParameters) ); - // delete toydata; - - RooDataSet* toydata = (RooDataSet*)GenerateToyData(allParameters); - - // note, evaluation always done at fNullPOI - testStatVec.push_back( fTestStat->Evaluate(*toydata, *fNullPOI) ); - - // want to clean up memory, but delete toydata causes problem with - // nll->setData(data, noclone) because pointer to last data set is no longer valid - // delete toydata; - - // instead, delete previous data set - if(fLastDataSet) delete fLastDataSet; - fLastDataSet = toydata; - } - - RooMsgService::instance().setGlobalKillBelow(msglevel); - - // cout << " generated sampling dist " << endl; - return new SamplingDistribution( "temp",//MakeName(allParameters).c_str(), - "Sampling Distribution of Test Statistic", testStatVec, fVarName ); - } - - virtual RooAbsData* GenerateToyData(RooArgSet& allParameters) const { - // This method generates a toy dataset for the given parameter point. - - - // cout << "fNevents = " << fNevents << endl; - RooAbsPdf* pdf = fWS->pdf(fPdfName); - if(!fObservables){ - cout << "Observables not specified in ToyMCSamplerOld, will try to determine. " - << "Will ignore all constant parameters, parameters of interest, and nuisance parameters." << endl; - RooArgSet* observables = pdf->getVariables(); - RemoveConstantParameters(observables); // observables might be set constant, this is just a guess - - - if(fNullPOI) observables->remove(*fNullPOI, kFALSE, kTRUE); - if(fNuisParams) observables->remove(*fNuisParams, kFALSE, kTRUE); - cout << "will use the following as observables when generating data" << endl; - observables->Print(); - fObservables=observables; - } /*else { - cout << "obs set: will use the following as observables when generating data" << endl; - fObservables->Print(); - }*/ - - //fluctuate the number of events if fExtended is on. - // This is a bit slippery for number counting expts. where entry in data and - - /* - // model is number of events, and so number of entries in data always =1. - Int_t nEvents = fNevents; - if(fExtended) { - if( pdf->expectedEvents(*fObservables) > 0){ - // if PDF knows expected events use it instead - nEvents = fRand->Poisson(pdf->expectedEvents(*fObservables)); - } else{ - nEvents = fRand->Poisson(fNevents); - } - } - */ - - // Set the parameters to desired values for generating toys - RooArgSet* parameters = pdf->getParameters(fObservables); - RooStats::SetParameters(&allParameters, parameters); - - /* - cout << "expected events = " << pdf->expectedEvents(*observables) - << "fExtended = " << fExtended - << "fNevents = " << fNevents << " fNevents " - << "generating" << nEvents << " events " << endl; - */ - - RooFit::MsgLevel level = RooMsgService::instance().globalKillBelow(); - RooMsgService::instance().setGlobalKillBelow(RooFit::ERROR) ; - - // cout << "nEvents = " << nEvents << endl; - RooAbsData* data = NULL; - if(fExtended) { - data = (RooAbsData*)pdf->generate(*fObservables, RooFit::Extended()); - } else { - data = (RooAbsData*)pdf->generate(*fObservables, fNevents); - } - - RooMsgService::instance().setGlobalKillBelow(level) ; - delete parameters; - return data; - } - - // helper method to create meaningful names for sampling dist - string MakeName(RooArgSet& /*params*/){ - std::ostringstream str; - str<<"SamplingDist_"<< fCounter; - fCounter++; - std::string buf = str.str(); - return buf ; - } - - // Main interface to evaluate the test statistic on a dataset - virtual Double_t EvaluateTestStatistic(RooAbsData& data, RooArgSet& allParameters) { - return fTestStat->Evaluate(data, allParameters); - } - - // Get the TestStatistic - virtual TestStatistic* GetTestStatistic() const { - return fTestStat; - } - - // Get the Confidence level for the test - virtual Double_t ConfidenceLevel() const {return 1.-fSize;} - - // Common Initialization - virtual void Initialize(RooAbsArg& /*testStatistic*/, - RooArgSet& /*paramsOfInterest*/, - RooArgSet& /*nuisanceParameters*/) {} - - //set the parameters for the toyMC generation - virtual void SetNToys(const Int_t ntoy) { - fNtoys = ntoy; - } - - virtual void SetNEventsPerToy(const Int_t nevents) { - fNevents = nevents; - } - - - virtual void SetExtended(const Bool_t isExtended) { - fExtended = isExtended; - } - - // Set the DataSet, add to the the workspace if not already there - virtual void SetData(RooAbsData& data) { - if(&data){ - fWS->import(data); - fDataName = data.GetName(); - fWS->Print(); - } - } - // Set the Pdf, add to the the workspace if not already there - virtual void SetPdf(RooAbsPdf& pdf) { - if(&pdf){ - fWS->import(pdf); - fPdfName = pdf.GetName(); - } - } - - // specify the name of the dataset in the workspace to be used - virtual void SetData(const char* name) {fDataName = name;} - // specify the name of the PDF in the workspace to be used - virtual void SetPdf(const char* name) {fPdfName = name;} - // How to randomize the prior. Set to NULL to deactivate randomization. - virtual void SetPriorNuisance(RooAbsPdf* /*not supported*/) {} - - // specify the values of parameters used when evaluating test statistic - virtual void SetParametersForTestStat(const RooArgSet& nullpoi) {fNullPOI = (RooArgSet*)nullpoi.snapshot();} - // specify the nuisance parameters (eg. the rest of the parameters) - virtual void SetNuisanceParameters(const RooArgSet& set) {fNuisParams = &set;} - // specify the observables in the dataset (needed to evaluate the test statistic) - virtual void SetObservables(const RooArgSet& set) {fObservables = &set;} - // specify the conditional observables - virtual void SetGlobalObservables(const RooArgSet& ) {} - - // set the size of the test (rate of Type I error) ( Eg. 0.05 for a 95% Confidence Interval) - virtual void SetTestSize(Double_t size) {fSize = size;} - // set the confidence level for the interval (eg. 0.95 for a 95% Confidence Interval) - virtual void SetConfidenceLevel(Double_t cl) {fSize = 1.-cl;} - - // Set the TestStatistic (want the argument to be a function of the data & parameter points - virtual void SetTestStatistic(TestStatistic* testStat) { - fTestStat = testStat; - } - - // Set the name of the sampling distribution used for plotting - void SetSamplingDistName(const char* name) { if(name) fSamplingDistName = name; } - - - private: - Double_t fSize; - RooWorkspace* fWS; // a workspace that owns all the components to be used by the calculator - Bool_t fOwnsWorkspace; // flag if this object owns its workspace - string fSamplingDistName; // name of the model - const char* fPdfName; // name of common PDF in workspace - const char* fDataName; // name of data set in workspace - RooArgSet* fNullPOI; // the values of parameters used when evaluating test statistic - const RooArgSet* fNuisParams;// RooArgSet specifying nuisance parameters for interval - mutable const RooArgSet* fObservables; // RooArgSet specifying the observables in the dataset (needed to evaluate the test statistic) - TestStatistic* fTestStat; // pointer to the test statistic that is being sampled - Int_t fNtoys; // number of toys to generate - Int_t fNevents; // number of events per toy (may be ignored depending on settings) - Bool_t fExtended; // if nEvents should fluctuate - TRandom* fRand; // random generator - TString fVarName; // name of test statistic - - Int_t fCounter; // counter for naming sampling dist objects - - RooDataSet* fLastDataSet; // work around for memory issues in nllvar->setData(data, noclone) - - protected: - ClassDef(ToyMCSamplerOld,1) // A simple implementation of the TestStatSampler interface - }; -} - - -#endif diff --git a/roofit/roostats/src/AsymptoticCalculator.cxx b/roofit/roostats/src/AsymptoticCalculator.cxx index 3b0f8d75e5e66..f8e1089466ea9 100644 --- a/roofit/roostats/src/AsymptoticCalculator.cxx +++ b/roofit/roostats/src/AsymptoticCalculator.cxx @@ -37,6 +37,7 @@ #include "RooGaussian.h" #include "RooBifurGauss.h" #include "RooLognormal.h" +#include "RooDataHist.h" #include <cmath> #include <typeinfo> @@ -46,28 +47,7 @@ #include "TStopwatch.h" using namespace RooStats; - -namespace Utils { - - bool SetAllConstant(const RooAbsCollection &coll, bool constant) { - // utility function to set all variable constant in a collection - // (from G. Petrucciani) - bool changed = false; - std::auto_ptr<TIterator> iter(coll.createIterator()); - for (RooAbsArg *a = (RooAbsArg *) iter->Next(); a != 0; a = (RooAbsArg *) iter->Next()) { - RooRealVar *v = dynamic_cast<RooRealVar *>(a); - if (v && (v->isConstant() != constant)) { - changed = true; - v->setConstant(constant); - } - } - return changed; - } - - - -} - +using namespace std; ClassImp(RooStats::AsymptoticCalculator); @@ -135,16 +115,17 @@ AsymptoticCalculator::AsymptoticCalculator( allParams->snapshot(nominalParams); } - // evaluate the unconditional nll for the full model on the observed data - oocoutP((TObject*)0,Eval) << "AsymptoticCalculator: Find best unconditional NLL on observed data" << endl; - fNLLObs = EvaluateNLL( *nullPdf, *obsData); + + // evaluate the unconditional nll for the full model on the observed data + if (verbose >= 0) + oocoutP((TObject*)0,Eval) << "AsymptoticCalculator: Find best unconditional NLL on observed data" << endl; + fNLLObs = EvaluateNLL( *nullPdf, *obsData, GetNullModel()->GetConditionalObservables()); // fill also snapshot of best poi poi->snapshot(fBestFitPoi); - if (verbose > 0) { - std::cout << "Best fitted POI\n"; - fBestFitPoi.Print("v"); - std::cout << std::endl; - } + RooRealVar * muBest = dynamic_cast<RooRealVar*>(fBestFitPoi.first()); + assert(muBest); + if (verbose >= 0) + oocoutP((TObject*)0,Eval) << "Best fitted POI value = " << muBest->getVal() << " +/- " << muBest->getError() << std::endl; // keep snapshot of all best fit parameters allParams->snapshot(fBestFitParams); delete allParams; @@ -160,16 +141,36 @@ AsymptoticCalculator::AsymptoticCalculator( oocoutP((TObject*)0,Eval) << "AsymptoticCalculator: Building Asimov data Set" << endl; + // check that in case of binned models th ennumber of bins of the observables are consistent + // with the number of bins in the observed data + // This number will be used for making the Asimov data set so it will be more consistent with the + // observed data + int prevBins = 0; + RooRealVar * xobs = 0; + if (GetNullModel()->GetObservables() && GetNullModel()->GetObservables()->getSize() == 1 ) { + xobs = (RooRealVar*) (GetNullModel()->GetObservables())->first(); + if (data.IsA() == RooDataHist::Class() ) { + if (data.numEntries() != xobs->getBins() ) { + prevBins = xobs->getBins(); + oocoutW((TObject*)0,InputArguments) << "AsymptoticCalculator: number of bins in " << xobs->GetName() << " are different than data bins " + << " set the same data bins " << data.numEntries() << " in range " + << " [ " << xobs->getMin() << " , " << xobs->getMax() << " ]" << std::endl; + xobs->setBins(data.numEntries()); + } + } + } if (!nominalAsimov) { - oocoutI((TObject*)0,InputArguments) << "AsymptoticCalculator: Asimov data will be generated using fitted nuisance parameter values" << endl; + if (verbose >= 0) + oocoutI((TObject*)0,InputArguments) << "AsymptoticCalculator: Asimov data will be generated using fitted nuisance parameter values" << endl; RooArgSet * tmp = (RooArgSet*) poiAlt.snapshot(); fAsimovData = MakeAsimovData( data, nullModel, poiAlt, fAsimovGlobObs,tmp); } else { // assume use current value of nuisance as nominal ones - oocoutI((TObject*)0,InputArguments) << "AsymptoticCalculator: Asimovdata set will be generated using nominal (current) nuisance parameter values" << endl; + if (verbose >= 0) + oocoutI((TObject*)0,InputArguments) << "AsymptoticCalculator: Asimovdata set will be generated using nominal (current) nuisance parameter values" << endl; nominalParams = poiAlt; // set poi to alt value but keep nuisance at the nominal one fAsimovData = MakeAsimovData( nullModel, nominalParams, fAsimovGlobObs); } @@ -196,10 +197,11 @@ AsymptoticCalculator::AsymptoticCalculator( RooRealVar * muAlt = (RooRealVar*) poiAlt.first(); assert(muAlt); - oocoutP((TObject*)0,Eval) << "AsymptoticCalculator: Find best conditional NLL on ASIMOV data set for given alt POI ( " << - muAlt->GetName() << " ) = " << muAlt->getVal() << std::endl; + if (verbose>=0) + oocoutP((TObject*)0,Eval) << "AsymptoticCalculator: Find best conditional NLL on ASIMOV data set for given alt POI ( " << + muAlt->GetName() << " ) = " << muAlt->getVal() << std::endl; - fNLLAsimov = EvaluateNLL( *nullPdf, *fAsimovData, &poiAlt ); + fNLLAsimov = EvaluateNLL( *nullPdf, *fAsimovData, GetNullModel()->GetConditionalObservables(), &poiAlt ); // for unconditional fit //fNLLAsimov = EvaluateNLL( *nullPdf, *fAsimovData); //poi->Print("v"); @@ -207,11 +209,23 @@ AsymptoticCalculator::AsymptoticCalculator( // restore previous value globObs = globObsSnapshot; + // try to guess default configuration + // (this part should be in constructor) + RooRealVar * muNull = dynamic_cast<RooRealVar*>( nullSnapshot->first() ); + assert (muNull); + if (muNull->getVal() == muNull->getMin()) { + fOneSidedDiscovery = true; + if (verbose > 0) + oocoutI((TObject*)0,InputArguments) << "Minimum of POI is " << muNull->getMin() << " corresponds to null snapshot - default configuration is one-sided discovery formulae " << std::endl; + } + + // restore number of bins + if (prevBins > 0 && xobs) xobs->setBins(prevBins); } //_________________________________________________________________ -Double_t AsymptoticCalculator::EvaluateNLL(RooAbsPdf & pdf, RooAbsData& data, const RooArgSet *poiSet) { +Double_t AsymptoticCalculator::EvaluateNLL(RooAbsPdf & pdf, RooAbsData& data, const RooArgSet * condObs, const RooArgSet *poiSet) { int verbose = fgPrintLevel; @@ -224,8 +238,11 @@ Double_t AsymptoticCalculator::EvaluateNLL(RooAbsPdf & pdf, RooAbsData& data, RooStats::RemoveConstantParameters(allParams); // add constraint terms for all non-constant parameters + RooArgSet conditionalObs; + if (condObs) conditionalObs.add(*condObs); + // need to call constrain for RooSimultaneous until stripDisconnected problem fixed - RooAbsReal* nll = (RooNLLVar*) pdf.createNLL(data, RooFit::CloneData(kFALSE),RooFit::Constrain(*allParams)); + RooAbsReal* nll = pdf.createNLL(data, RooFit::CloneData(kFALSE),RooFit::Constrain(*allParams),RooFit::ConditionalObservables(conditionalObs)); RooArgSet* attachedSet = nll->getVariables(); @@ -427,7 +444,7 @@ HypoTestResult* AsymptoticCalculator::GetHypoTest() const { } // evaluate the conditional NLL on the observed data for the snapshot value - double condNLL = EvaluateNLL( *nullPdf, const_cast<RooAbsData&>(*GetData()), &poiTest); + double condNLL = EvaluateNLL( *nullPdf, const_cast<RooAbsData&>(*GetData()), GetNullModel()->GetConditionalObservables(), &poiTest); double qmu = 2.*(condNLL - fNLLObs); @@ -437,8 +454,9 @@ HypoTestResult* AsymptoticCalculator::GetHypoTest() const { oocoutP((TObject*)0,Eval) << "\t OBSERVED DATA : qmu = " << qmu << " condNLL = " << condNLL << " uncond " << fNLLObs << std::endl; - - if (qmu < 0 || TMath::IsNaN(fNLLObs) ) { + // this tolerance is used to avoid having negative qmu due to numerical errors + double tol = 1.E-4 * ROOT::Math::MinimizerOptions::DefaultTolerance(); + if (qmu < -tol || TMath::IsNaN(fNLLObs) ) { if (qmu < 0) oocoutW((TObject*)0,Minimization) << "AsymptoticCalculator: Found a negative value of the qmu - retry to do the unconditional fit " @@ -448,7 +466,7 @@ HypoTestResult* AsymptoticCalculator::GetHypoTest() const { << std::endl; - double nll = EvaluateNLL( *nullPdf, const_cast<RooAbsData&>(*GetData())); + double nll = EvaluateNLL( *nullPdf, const_cast<RooAbsData&>(*GetData()),GetNullModel()->GetConditionalObservables()); if (nll < fNLLObs || (TMath::IsNaN(fNLLObs) && !TMath::IsNaN(nll) ) ) { oocoutW((TObject*)0,Minimization) << "AsymptoticCalculator: Found a better unconditional minimum " @@ -476,7 +494,7 @@ HypoTestResult* AsymptoticCalculator::GetHypoTest() const { } } - if (qmu < 0 ) { + if (qmu < -tol ) { oocoutE((TObject*)0,Minimization) << "AsymptoticCalculator: qmu is still < 0 for mu = " << muTest->getVal() << " return a dummy result " << std::endl; @@ -510,7 +528,7 @@ HypoTestResult* AsymptoticCalculator::GetHypoTest() const { if (verbose > 0) oocoutP((TObject*)0,Eval) << "AsymptoticCalculator::GetHypoTest -- Find best conditional NLL on ASIMOV data set .... " << std::endl; - double condNLL_A = EvaluateNLL( *nullPdf, *fAsimovData, &poiTest); + double condNLL_A = EvaluateNLL( *nullPdf, *fAsimovData, GetNullModel()->GetConditionalObservables(), &poiTest); double qmu_A = 2.*(condNLL_A - fNLLAsimov ); @@ -528,7 +546,7 @@ HypoTestResult* AsymptoticCalculator::GetHypoTest() const { << std::endl; - double nll = EvaluateNLL( *nullPdf, *fAsimovData ); + double nll = EvaluateNLL( *nullPdf, *fAsimovData, GetNullModel()->GetConditionalObservables() ); if (nll < fNLLAsimov || (TMath::IsNaN(fNLLAsimov) && !TMath::IsNaN(nll) )) { oocoutW((TObject*)0,Minimization) << "AsymptoticCalculator: Found a better unconditional minimum for Asimov data set" @@ -592,8 +610,7 @@ HypoTestResult* AsymptoticCalculator::GetHypoTest() const { << " - using standard q asymptotic formulae " << std::endl; } } - else - useQTilde = fUseQTilde; + useQTilde = fUseQTilde; } @@ -607,7 +624,7 @@ HypoTestResult* AsymptoticCalculator::GetHypoTest() const { } if (fOneSidedDiscovery ) { if ( muHat->getVal() < muTest->getVal() ) { - oocoutI((TObject*)0,Eval) << "Using one-sided qmu - setting qmu to zero muHat = " << muHat->getVal() + oocoutI((TObject*)0,Eval) << "Using one-sided discovery qmu - setting qmu to zero muHat = " << muHat->getVal() << " muTest = " << muTest->getVal() << std::endl; qmu = 0; } @@ -629,11 +646,18 @@ HypoTestResult* AsymptoticCalculator::GetHypoTest() const { if (fOneSided || fOneSidedDiscovery) { // for one-sided PL (q_mu : equations 56,57) + if (verbose>2) { + if (fOneSided) + oocoutI((TObject*)0,Eval) << "Using one-sided limit asymptotic formula (qmu)" << endl; + else + oocoutI((TObject*)0,Eval) << "Using one-sided discovery asymptotic formula (q0)" << endl; + } pnull = ROOT::Math::normal_cdf_c( sqrtqmu, 1.); palt = ROOT::Math::normal_cdf( sqrtqmu_A - sqrtqmu, 1.); } else { // for 2-sided PL (t_mu : equations 35,36 in asymptotic paper) + if (verbose > 2) oocoutI((TObject*)0,Eval) << "Using two-sided asimptotic formula (tmu)" << endl; pnull = 2.*ROOT::Math::normal_cdf_c( sqrtqmu, 1.); palt = ROOT::Math::normal_cdf_c( sqrtqmu + sqrtqmu_A, 1.) + ROOT::Math::normal_cdf_c( sqrtqmu - sqrtqmu_A, 1.); @@ -644,6 +668,7 @@ HypoTestResult* AsymptoticCalculator::GetHypoTest() const { if (fOneSided) { // for bounded one-sided (q_mu_tilde: equations 64,65) if ( qmu > qmu_A) { + if (verbose > 2) oocoutI((TObject*)0,Eval) << "Using qmu_tilde (qmu is greater than qmu_A)" << endl; pnull = ROOT::Math::normal_cdf_c( (qmu + qmu_A)/(2 * sqrtqmu_A), 1.); palt = ROOT::Math::normal_cdf_c( (qmu - qmu_A)/(2 * sqrtqmu_A), 1.); } @@ -652,6 +677,7 @@ HypoTestResult* AsymptoticCalculator::GetHypoTest() const { // for 2 sided bounded test statistic (N.B there is no one sided discovery qtilde) // t_mu_tilde: equations 43,44 in asymptotic paper if ( qmu > qmu_A) { + if (verbose > 2) oocoutI((TObject*)0,Eval) << "Using tmu_tilde (qmu is greater than qmu_A)" << endl; pnull = ROOT::Math::normal_cdf_c(sqrtqmu,1.) + ROOT::Math::normal_cdf_c( (qmu + qmu_A)/(2 * sqrtqmu_A), 1.); palt = ROOT::Math::normal_cdf_c( sqrtqmu_A + sqrtqmu, 1.) + @@ -665,7 +691,6 @@ HypoTestResult* AsymptoticCalculator::GetHypoTest() const { // create an HypoTest result but where the sampling distributions are set to zero string resultname = "HypoTestAsymptotic_result"; HypoTestResult* res = new HypoTestResult(resultname.c_str(), pnull, palt); - res->SetBackgroundAsAlt(true); if (verbose > 0) //std::cout @@ -740,7 +765,7 @@ double AsymptoticCalculator::GetExpectedPValues(double pnull, double palt, doubl void AsymptoticCalculator::FillBins(const RooAbsPdf & pdf, const RooArgList &obs, RooAbsData & data, int &index, double &binVolume, int &ibin) { /// fill bins by looping recursivly on observables - bool debug = (fgPrintLevel == 2); + bool debug = (fgPrintLevel >= 2); RooRealVar * v = dynamic_cast<RooRealVar*>( &(obs[index]) ); if (!v) return; @@ -778,6 +803,7 @@ void AsymptoticCalculator::FillBins(const RooAbsPdf & pdf, const RooArgList &obs if (debug) { cout << "bin " << ibin << "\t"; for (int j=0; j < obs.getSize(); ++j) { cout << " " << ((RooRealVar&) obs[j]).getVal(); } + cout << " w = " << fval*expectedEvents; cout << endl; } // RooArgSet xxx(obs); @@ -797,28 +823,31 @@ void AsymptoticCalculator::FillBins(const RooAbsPdf & pdf, const RooArgList &obs bool AsymptoticCalculator::SetObsToExpected(RooProdPdf &prod, const RooArgSet &obs) { - // iterate a Prod pdf to find the Poisson or Gaussian part to set the observed value to expected one + // iterate a Prod pdf to find all the Poisson or Gaussian part to set the observed value to expected one std::auto_ptr<TIterator> iter(prod.pdfList().createIterator()); + bool ret = false; for (RooAbsArg *a = (RooAbsArg *) iter->Next(); a != 0; a = (RooAbsArg *) iter->Next()) { if (!a->dependsOn(obs)) continue; RooPoisson *pois = 0; RooGaussian * gaus = 0; if ((pois = dynamic_cast<RooPoisson *>(a)) != 0) { - return SetObsToExpected(*pois, obs); + SetObsToExpected(*pois, obs); } else if ((gaus = dynamic_cast<RooGaussian *>(a)) != 0) { - return SetObsToExpected(*gaus, obs); + SetObsToExpected(*gaus, obs); } else { // should try to add also lognormal case ? RooProdPdf *subprod = dynamic_cast<RooProdPdf *>(a); if (subprod) return SetObsToExpected(*subprod, obs); else { - oocoutE((TObject*)0,InputArguments) << "Illegal term in counting model: depends on observables, but not Poisson or Product" << endl; + oocoutE((TObject*)0,InputArguments) << "Illegal term in counting model: depends on observables, but not Poisson or Gaussian or Product" + << endl; return false; } } + ret = (pois != 0 || gaus != 0 ); } - return false; + return ret; } bool AsymptoticCalculator::SetObsToExpected(RooAbsPdf &pdf, const RooArgSet &obs) @@ -866,19 +895,29 @@ bool AsymptoticCalculator::SetObsToExpected(RooAbsPdf &pdf, const RooArgSet &obs oocoutF((TObject*)0,Generation) << "AsymptoticCalculator::SetObsExpected( " << pdfName << " ) : No observable?" << endl; return false; } + myobs->setVal(myexp->getVal()); + + if (fgPrintLevel > 2) { + std::cout << "SetObsToExpected : setting " << myobs->GetName() << " to expected value " << myexp->getVal() << " of " << myexp->GetName() << std::endl; + } + return true; } RooAbsData * AsymptoticCalculator::GenerateCountingAsimovData(RooAbsPdf & pdf, const RooArgSet & observables, const RooRealVar & , RooCategory * channelCat) { - // generate countuing Asimov data for the case when the pdf cannot be extended + // generate counting Asimov data for the case when the pdf cannot be extended // assume pdf is a RooPoisson or can be decomposed in a product of RooPoisson, // otherwise we cannot know how to make the Asimov data sets in the other cases RooArgSet obs(observables); RooProdPdf *prod = dynamic_cast<RooProdPdf *>(&pdf); RooPoisson *pois = 0; RooGaussian *gaus = 0; + + if (fgPrintLevel > 1) + std::cout << "generate counting Asimov data for pdf of type " << pdf.IsA()->GetName() << std::endl; + bool r = false; if (prod != 0) { r = SetObsToExpected(*prod, observables); @@ -887,7 +926,7 @@ RooAbsData * AsymptoticCalculator::GenerateCountingAsimovData(RooAbsPdf & pdf, c } else if ((gaus = dynamic_cast<RooGaussian *>(&pdf)) != 0) { r = SetObsToExpected(*gaus, observables); } else { - oocoutE((TObject*)0,InputArguments) << "A counting model pdf must be either a RooProdPdf or a RooPoisson" << endl; + oocoutE((TObject*)0,InputArguments) << "A counting model pdf must be either a RooProdPdf or a RooPoisson or a RooGaussian" << endl; } if (!r) return 0; int icat = 0; @@ -1100,14 +1139,15 @@ RooAbsData * AsymptoticCalculator::MakeAsimovData(RooAbsData & realData, const M RooFit::MsgLevel msglevel = RooMsgService::instance().globalKillBelow(); if (verbose < 2) RooMsgService::instance().setGlobalKillBelow(RooFit::FATAL); - + RooArgSet conditionalObs; + if (model.GetConditionalObservables()) conditionalObs.add(*model.GetConditionalObservables()); std::string minimizerType = ROOT::Math::MinimizerOptions::DefaultMinimizerType(); std::string minimizerAlgo = ROOT::Math::MinimizerOptions::DefaultMinimizerAlgo(); model.GetPdf()->fitTo(realData, RooFit::Minimizer(minimizerType.c_str(),minimizerAlgo.c_str()), RooFit::Strategy(ROOT::Math::MinimizerOptions::DefaultStrategy()), RooFit::PrintLevel(minimPrintLevel-1), RooFit::Hesse(false), - RooFit::Constrain(constrainParams)); + RooFit::Constrain(constrainParams),RooFit::ConditionalObservables(conditionalObs)); if (verbose>0) { std::cout << "fit time "; tw2.Print();} if (verbose > 1) { // after the fit the nuisance parameters will have their best fit value @@ -1122,7 +1162,7 @@ RooAbsData * AsymptoticCalculator::MakeAsimovData(RooAbsData & realData, const M } // restore the parameters which were set constant - Utils::SetAllConstant(paramsSetConstant, false); + SetAllConstant(paramsSetConstant, false); RooArgSet * allParams = model.GetPdf()->getParameters(realData); @@ -1166,7 +1206,8 @@ RooAbsData * AsymptoticCalculator::MakeAsimovData(const ModelConfig & model, con RooAbsData * asimov = GenerateAsimovData(*model.GetPdf() , *model.GetObservables() ); if (verbose>0) { - std::cout << "Generated Asimov data for observables with time : "; tw.Print(); + std::cout << "Generated Asimov data for observables "; (model.GetObservables() )->Print(); + if (verbose>1) std::cout << "\t\t\ttime for generating : "; tw.Print(); } @@ -1192,7 +1233,7 @@ RooAbsData * AsymptoticCalculator::MakeAsimovData(const ModelConfig & model, con // snapshot data global observables RooArgSet snapGlobalObsData; - Utils::SetAllConstant(gobs, true); + SetAllConstant(gobs, true); gobs.snapshot(snapGlobalObsData); @@ -1207,12 +1248,21 @@ RooAbsData * AsymptoticCalculator::MakeAsimovData(const ModelConfig & model, con // part 1: create the nuisance pdf std::auto_ptr<RooAbsPdf> nuispdf(RooStats::MakeNuisancePdf(model,"TempNuisPdf") ); - // unfold the nuisance pdf + if (nuispdf.get() == 0) { + oocoutF((TObject*)0,Generation) << "AsymptoticCalculator::MakeAsimovData: model has nuisance parameters and global obs but no nuisance pdf " + << std::endl; + } + // unfold the nuisance pdf if it is a prod pdf + RooArgList pdfList; RooProdPdf *prod = dynamic_cast<RooProdPdf *>(nuispdf.get()); - if (prod == 0) { - oocoutF((TObject*)0,Generation) << "AsymptoticCalculator::MakeAsimovData: the nuisance pdf is not a RooProdPdf!" << std::endl; + if (prod ) { + pdfList.add(prod->pdfList()); } - std::auto_ptr<TIterator> iter(prod->pdfList().createIterator()); + else + // nothing to unfold - just use the pdf + pdfList.add(*nuispdf.get()); + + std::auto_ptr<TIterator> iter(pdfList.createIterator()); for (RooAbsArg *a = (RooAbsArg *) iter->Next(); a != 0; a = (RooAbsArg *) iter->Next()) { RooAbsPdf *cterm = dynamic_cast<RooAbsPdf *>(a); assert(cterm && "AsimovUtils: a factor of the nuisance pdf is not a Pdf!"); @@ -1297,20 +1347,21 @@ RooAbsData * AsymptoticCalculator::MakeAsimovData(const ModelConfig & model, con // needed this ?? (LM) asimovGlobObs.removeAll(); - Utils::SetAllConstant(gobs, true); + SetAllConstant(gobs, true); gobs.snapshot(asimovGlobObs); // revert global observables to the data value gobs = snapGlobalObsData; if (verbose>0) { - std::cout << "Generated Asimov data for global observables " << std::endl; + std::cout << "Generated Asimov data for global observables "; + if (verbose == 1) gobs.Print(); } if (verbose > 1) { - std::cout << "Global observables for data: " << std::endl; + std::cout << "\nGlobal observables for data: " << std::endl; gobs.Print("V"); - std::cout << "Global observables for asimov: " << std::endl; + std::cout << "\nGlobal observables for asimov: " << std::endl; asimovGlobObs.Print("V"); } diff --git a/roofit/roostats/src/BayesianCalculator.cxx b/roofit/roostats/src/BayesianCalculator.cxx index d0e8a96a3b842..4268aa716fba7 100644 --- a/roofit/roostats/src/BayesianCalculator.cxx +++ b/roofit/roostats/src/BayesianCalculator.cxx @@ -88,6 +88,8 @@ END_HTML ClassImp(RooStats::BayesianCalculator) +using namespace std; + namespace RooStats { @@ -742,8 +744,10 @@ void BayesianCalculator::SetModel(const ModelConfig & model) { // assignment operator = does not do a real copy the sets (must use add method) fPOI.removeAll(); fNuisanceParameters.removeAll(); + fConditionalObs.removeAll(); if (model.GetParametersOfInterest()) fPOI.add( *(model.GetParametersOfInterest()) ); if (model.GetNuisanceParameters()) fNuisanceParameters.add( *(model.GetNuisanceParameters() ) ); + if (model.GetConditionalObservables()) fConditionalObs.add( *(model.GetConditionalObservables() ) ); // remove constant nuisance parameters RemoveConstantParameters(&fNuisanceParameters); @@ -788,7 +792,7 @@ RooAbsReal* BayesianCalculator::GetPosteriorFunction() const //constrainedParams->Print("V"); // use RooFit::Constrain() to be sure constraints terms are taken into account - fLogLike = fPdf->createNLL(*fData, RooFit::Constrain(*constrainedParams) ); + fLogLike = fPdf->createNLL(*fData, RooFit::Constrain(*constrainedParams), RooFit::ConditionalObservables(fConditionalObs) ); @@ -818,6 +822,7 @@ RooAbsReal* BayesianCalculator::GetPosteriorFunction() const } + // need do find minimum of log-likelihood in the range to shift function // to avoid numerical errors when we compute the likelihood (overflows in the exponent) // N.B.: this works for only 1 parameter of interest otherwise Minuit should be used for finding the minimum @@ -827,12 +832,14 @@ RooAbsReal* BayesianCalculator::GetPosteriorFunction() const RooRealVar* poi = dynamic_cast<RooRealVar*>( fPOI.first() ); assert(poi); + // try to reduce some error messages + //Bool_t silentMode = (RooMsgService::instance().globalKillBelow() >= RooFit::ERROR || RooMsgService::instance().silentMode()) ; + RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::CountErrors); + + coutI(Eval) << "BayesianCalculator::GetPosteriorFunction : " << " nll value " << nllVal << " poi value = " << poi->getVal() << std::endl; - // if pdf evaluates to zero, should be fixed, but this will - // stop error messages. - fLogLike->setEvalErrorLoggingMode(RooAbsReal::CountErrors); ROOT::Math::BrentMinimizer1D minim; minim.SetFunction(wnllFunc,poi->getMin(),poi->getMax() ); @@ -880,7 +887,7 @@ RooAbsReal* BayesianCalculator::GetPosteriorFunction() const RooArgSet* constrParams = fPdf->getParameters(*fData); // remove the constant parameters RemoveConstantParameters(constrParams); - fLogLike = pdfAndPrior->createNLL(*fData, RooFit::Constrain(*constrParams) ); + fLogLike = pdfAndPrior->createNLL(*fData, RooFit::Constrain(*constrParams),RooFit::ConditionalObservables(fConditionalObs) ); delete constrParams; TString likeName = TString("likelihood_times_prior_") + TString(pdfAndPrior->GetName()); @@ -900,7 +907,6 @@ RooAbsReal* BayesianCalculator::GetPosteriorFunction() const fIntegratedLikelihood = fLikelihood->createIntegral(fNuisanceParameters); - return fIntegratedLikelihood; } else if ( fIntegrationType.Contains("TOYMC") ) { @@ -943,11 +949,12 @@ RooAbsReal* BayesianCalculator::GetPosteriorFunction() const } - //fIntegratedLikelihood->setEvalErrorLoggingMode(RooAbsReal::CountErrors); - - // ccoutD(Eval) << "BayesianCalculator::GetPosteriorFunction : use ROOT numerical integration algorithm. "; - // ccoutD(Eval) << " Integrated log-likelihood = " << fIntegratedLikelihood->getVal() << std::endl; + if (RooAbsReal::numEvalErrors() > 0) + coutW(Eval) << "BayesianCalculator::GetPosteriorFunction : " << RooAbsReal::numEvalErrors() << " errors reported in evaluating log-likelihood function " + << std::endl; + RooAbsReal::clearEvalErrorLog(); + RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::PrintErrors); return fIntegratedLikelihood; @@ -1002,12 +1009,16 @@ RooPlot* BayesianCalculator::GetPosteriorPlot(bool norm, double precision ) cons if (!plot) return 0; // try to reduce some error messages - posterior->setEvalErrorLoggingMode(RooAbsReal::CountErrors); + RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::CountErrors); plot->SetTitle(TString("Posterior probability of parameter \"")+TString(poi->GetName())+TString("\"")); posterior->plotOn(plot,RooFit::Range(fLower,fUpper,kFALSE),RooFit::VLines(),RooFit::DrawOption("F"),RooFit::MoveToBack(),RooFit::FillColor(kGray),RooFit::Precision(precision)); posterior->plotOn(plot); plot->GetYaxis()->SetTitle("posterior function"); + + // reset the counts and default mode + RooAbsReal::clearEvalErrorLog(); + RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::PrintErrors); return plot; } @@ -1073,9 +1084,14 @@ SimpleInterval* BayesianCalculator::GetInterval() const return 0; } + + // get integrated likelihood (posterior function) GetPosteriorFunction(); + //Bool_t silentMode = (RooMsgService::instance().globalKillBelow() >= RooFit::ERROR || RooMsgService::instance().silentMode()) ; + RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::CountErrors); + if (fLeftSideFraction < 0 ) { // compute short intervals ComputeShortestInterval(); @@ -1110,6 +1126,15 @@ SimpleInterval* BayesianCalculator::GetInterval() const } } + + // reset the counts and default mode + if (RooAbsReal::numEvalErrors() > 0) + coutW(Eval) << "BayesianCalculator::GetInterval : " << RooAbsReal::numEvalErrors() << " errors reported in evaluating log-likelihood function " + << std::endl; + + RooAbsReal::clearEvalErrorLog(); + RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::PrintErrors); + if (!fValidInterval) { fLower = 1; fUpper = 0; coutE(Eval) << "BayesianCalculator::GetInterval - cannot compute a valid interval - return a dummy [1,0] interval" @@ -1275,11 +1300,10 @@ void BayesianCalculator::ApproximatePosterior() const { fApproxPosterior = 0; } + RooAbsReal * posterior = GetPosteriorFunction(); if (!posterior) return; - // try to reduce some error messages - posterior->setEvalErrorLoggingMode(RooAbsReal::CountErrors); TF1 * tmp = posterior->asTF(fPOI); assert(tmp != 0); diff --git a/roofit/roostats/src/BernsteinCorrection.cxx b/roofit/roostats/src/BernsteinCorrection.cxx index 9671b7b6525a2..9071883396862 100644 --- a/roofit/roostats/src/BernsteinCorrection.cxx +++ b/roofit/roostats/src/BernsteinCorrection.cxx @@ -79,6 +79,7 @@ ClassImp(RooStats::BernsteinCorrection) ; using namespace RooFit; using namespace RooStats; +using namespace std; //____________________________________ BernsteinCorrection::BernsteinCorrection(Double_t tolerance): diff --git a/roofit/roostats/src/ConfidenceBelt.cxx b/roofit/roostats/src/ConfidenceBelt.cxx index 3db49ee06ec47..cbd67564be091 100644 --- a/roofit/roostats/src/ConfidenceBelt.cxx +++ b/roofit/roostats/src/ConfidenceBelt.cxx @@ -44,6 +44,7 @@ ClassImp(RooStats::ConfidenceBelt) ; using namespace RooStats; +using namespace std; //____________________________________________________________________ ConfidenceBelt::ConfidenceBelt() : diff --git a/roofit/roostats/src/DetailedOutputAggregator.cxx b/roofit/roostats/src/DetailedOutputAggregator.cxx new file mode 100644 index 0000000000000..7a51d1789a0bc --- /dev/null +++ b/roofit/roostats/src/DetailedOutputAggregator.cxx @@ -0,0 +1,150 @@ +// @(#)root/roostats:$Id$ +// Author: Sven Kreiss, Kyle Cranmer, Lorenzo Moneta Nov 2010 +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +// implementation file of DetailedOutputAggregator + +#include <limits> + + +#include "RooFitResult.h" +#include "RooPullVar.h" +#include "RooRealVar.h" +#include "RooDataSet.h" + +#include "RooStats/DetailedOutputAggregator.h" + +namespace RooStats { + + DetailedOutputAggregator::~DetailedOutputAggregator() { + // destructor + if (fResult != NULL) delete fResult; + if (fBuiltSet != NULL) delete fBuiltSet; + } + + + RooArgSet * DetailedOutputAggregator::GetAsArgSet(RooFitResult *result, TString prefix, bool withErrorsAndPulls) { + // static function to translate the given fit result to a RooArgSet in a generic way. + // Prefix is prepended to all variable names. + // LM: caller is responsible to delete the returned list and eventually also the content of the list + // Note that the returned list is not owning the returned content + RooArgSet *detailedOutput = new RooArgSet; + const RooArgList &detOut = result->floatParsFinal(); + const RooArgList &truthSet = result->floatParsInit(); + TIterator *it = detOut.createIterator(); + while(RooAbsArg* v = dynamic_cast<RooAbsArg*>(it->Next())) { + RooAbsArg* clone = v->cloneTree(TString().Append(prefix).Append(v->GetName())); + clone->SetTitle( TString().Append(prefix).Append(v->GetTitle()) ); + RooRealVar* var = dynamic_cast<RooRealVar*>(v); + if (var) clone->setAttribute("StoreError"); + detailedOutput->add(*clone); + + if( withErrorsAndPulls && var ) { + clone->setAttribute("StoreAsymError"); + + TString pullname = TString().Append(prefix).Append(TString::Format("%s_pull", var->GetName())); + // TString pulldesc = TString::Format("%s pull for fit %u", var->GetTitle(), fitNumber); + RooRealVar* truth = dynamic_cast<RooRealVar*>(truthSet.find(var->GetName())); + RooPullVar pulltemp("temppull", "temppull", *var, *truth); + RooRealVar* pull = new RooRealVar(pullname, pullname, pulltemp.getVal()); + detailedOutput->add(*pull); + } + } + delete it; + + // monitor a few more variables + detailedOutput->add( *new RooRealVar(TString().Append(prefix).Append("minNLL"), TString().Append(prefix).Append("minNLL"), result->minNll() ) ); + detailedOutput->add( *new RooRealVar(TString().Append(prefix).Append("fitStatus"), TString().Append(prefix).Append("fitStatus"), result->status() ) ); + detailedOutput->add( *new RooRealVar(TString().Append(prefix).Append("covQual"), TString().Append(prefix).Append("covQual"), result->covQual() ) ); + detailedOutput->add( *new RooRealVar(TString().Append(prefix).Append("numInvalidNLLEval"), TString().Append(prefix).Append("numInvalidNLLEval"), result->numInvalidNLL() ) ); + return detailedOutput; + } + + void DetailedOutputAggregator::AppendArgSet(const RooAbsCollection *aset, TString prefix) { + // For each variable in aset, prepend prefix to its name and add + // to the internal store. Note this will not appear in the produced + // dataset unless CommitSet is called. + + if (aset == NULL) { + // silently ignore + //std::cout << "Attempted to append NULL" << endl; + return; + } + if (fBuiltSet == NULL) { + fBuiltSet = new RooArgList(); + } + TIterator* iter = aset->createIterator(); + while(RooAbsArg* v = dynamic_cast<RooAbsArg*>( iter->Next() ) ) { + TString renamed(TString::Format("%s%s", prefix.Data(), v->GetName())); + if (fResult == NULL) { + // we never commited, so by default all columns are expected to not exist + RooAbsArg* var = v->createFundamental(); + assert(var != NULL); + (RooArgSet(*var)) = RooArgSet(*v); + var->SetName(renamed); + if (RooRealVar* rvar= dynamic_cast<RooRealVar*>(var)) { + if (v->getAttribute("StoreError")) var->setAttribute("StoreError"); + else rvar->removeError(); + if (v->getAttribute("StoreAsymError")) var->setAttribute("StoreAsymError"); + else rvar->removeAsymError(); + } + if (fBuiltSet->addOwned(*var)) continue; // OK - can skip past setting value + } + if (RooAbsArg* var = fBuiltSet->find(renamed)) { + // we already commited an argset once, so we expect all columns to already be in the set + var->SetName(v->GetName()); + (RooArgSet(*var)) = RooArgSet(*v); // copy values and errors + var->SetName(renamed); + } + } + delete iter; + } + + // Commit to the result RooDataSet. + void DetailedOutputAggregator::CommitSet(double weight) { + if (fResult == NULL) { + // Store dataset as a tree - problem with VectorStore and StoreError (bug #94908) + RooRealVar wgt("weight","weight",1.0); + fResult = new RooDataSet("", "", RooArgSet(*fBuiltSet,wgt), RooFit::WeightVar(wgt)); + } + fResult->add(RooArgSet(*fBuiltSet), weight); + TIterator* iter = fBuiltSet->createIterator(); + while(RooAbsArg* v = dynamic_cast<RooAbsArg*>( iter->Next() ) ) { + if (RooRealVar* var= dynamic_cast<RooRealVar*>(v)) { + // Invalidate values in case we don't set some of them next time round (eg. if fit not done) + var->setVal(std::numeric_limits<Double_t>::quiet_NaN()); + var->removeError(); + var->removeAsymError(); + } + } + delete iter; + } + + + RooDataSet * DetailedOutputAggregator::GetAsDataSet(TString name, TString title) { + // Returns all detailed output as a dataset. + // Ownership of the dataset is transferred to the caller. + RooDataSet* temp = NULL; + if( fResult ) { + temp = fResult; + fResult = NULL; // we no longer own the dataset + temp->SetNameTitle( name.Data(), title.Data() ); + }else{ + RooRealVar wgt("weight","weight",1.0); + temp = new RooDataSet(name.Data(), title.Data(), RooArgSet(wgt), RooFit::WeightVar(wgt)); + } + delete fBuiltSet; + fBuiltSet = NULL; + + return temp; + } + + +} // end namespace RooStats + diff --git a/roofit/roostats/src/FeldmanCousins.cxx b/roofit/roostats/src/FeldmanCousins.cxx index 71637d64ebc7d..a05f01f62d3ca 100644 --- a/roofit/roostats/src/FeldmanCousins.cxx +++ b/roofit/roostats/src/FeldmanCousins.cxx @@ -60,6 +60,7 @@ ClassImp(RooStats::FeldmanCousins) ; using namespace RooFit; using namespace RooStats; +using namespace std; /* diff --git a/roofit/roostats/src/FrequentistCalculator.cxx b/roofit/roostats/src/FrequentistCalculator.cxx index b5b095ed99051..0134ab39a3bbd 100644 --- a/roofit/roostats/src/FrequentistCalculator.cxx +++ b/roofit/roostats/src/FrequentistCalculator.cxx @@ -15,6 +15,7 @@ MLEs. #include "RooStats/FrequentistCalculator.h" #include "RooStats/ToyMCSampler.h" +#include "RooMinimizer.h" #include "RooMinuit.h" #include "RooProfileLL.h" @@ -22,6 +23,7 @@ MLEs. ClassImp(RooStats::FrequentistCalculator) using namespace RooStats; +using namespace std; void FrequentistCalculator::PreHook() const { if (fFitInfo != NULL) { @@ -57,6 +59,7 @@ int FrequentistCalculator::PreNullHook(RooArgSet *parameterPoint, double obsTest if( fConditionalMLEsNull ) { oocoutI((TObject*)0,InputArguments) << "Using given conditional MLEs for Null." << endl; *allParams = *fConditionalMLEsNull; + // LM: fConditionalMLEsNull must be nuisance parameters otherwise an error message will be printed allButNuisance.add( *fConditionalMLEsNull ); if (fNullModel->GetNuisanceParameters()) { RooArgSet remain(*fNullModel->GetNuisanceParameters()); @@ -71,15 +74,21 @@ int FrequentistCalculator::PreNullHook(RooArgSet *parameterPoint, double obsTest oocoutI((TObject*)0,InputArguments) << "Profiling conditional MLEs for Null." << endl; RooFit::MsgLevel msglevel = RooMsgService::instance().globalKillBelow(); RooMsgService::instance().setGlobalKillBelow(RooFit::FATAL); + + RooArgSet conditionalObs; + if (fNullModel->GetConditionalObservables()) conditionalObs.add(*fNullModel->GetConditionalObservables()); - RooAbsReal* nll = fNullModel->GetPdf()->createNLL(*const_cast<RooAbsData*>(fData), RooFit::CloneData(kFALSE), RooFit::Constrain(*allParams)); + RooAbsReal* nll = fNullModel->GetPdf()->createNLL(*const_cast<RooAbsData*>(fData), RooFit::CloneData(kFALSE), RooFit::Constrain(*allParams), + RooFit::ConditionalObservables(conditionalObs)); RooProfileLL* profile = dynamic_cast<RooProfileLL*>(nll->createProfile(allButNuisance)); profile->getVal(); // this will do fit and set nuisance parameters to profiled values // Hack to extract a RooFitResult if (fStoreFitInfo) { - RooFitResult *result = profile->minuit()->save(); - fFitInfo->addOwned(*DetailedOutputAggregator::GetAsArgSet(result, "fitNull_")); + RooFitResult *result = profile->minimizer()->save(); + RooArgSet * detOutput = DetailedOutputAggregator::GetAsArgSet(result, "fitNull_"); + fFitInfo->addOwned(*detOutput); + delete detOutput; delete result; } @@ -143,6 +152,7 @@ int FrequentistCalculator::PreAltHook(RooArgSet *parameterPoint, double obsTestS if( fConditionalMLEsAlt ) { oocoutI((TObject*)0,InputArguments) << "Using given conditional MLEs for Alt." << endl; *allParams = *fConditionalMLEsAlt; + // LM: fConditionalMLEsAlt must be nuisance parameters otherwise an error message will be printed allButNuisance.add( *fConditionalMLEsAlt ); if (fAltModel->GetNuisanceParameters()) { RooArgSet remain(*fAltModel->GetNuisanceParameters()); @@ -157,15 +167,22 @@ int FrequentistCalculator::PreAltHook(RooArgSet *parameterPoint, double obsTestS oocoutI((TObject*)0,InputArguments) << "Profiling conditional MLEs for Alt." << endl; RooFit::MsgLevel msglevel = RooMsgService::instance().globalKillBelow(); RooMsgService::instance().setGlobalKillBelow(RooFit::FATAL); - - RooAbsReal* nll = fAltModel->GetPdf()->createNLL(*const_cast<RooAbsData*>(fData), RooFit::CloneData(kFALSE), RooFit::Constrain(*allParams)); + + RooArgSet conditionalObs; + if (fAltModel->GetConditionalObservables()) conditionalObs.add(*fAltModel->GetConditionalObservables()); + + RooAbsReal* nll = fAltModel->GetPdf()->createNLL(*const_cast<RooAbsData*>(fData), RooFit::CloneData(kFALSE), RooFit::Constrain(*allParams), + RooFit::ConditionalObservables(conditionalObs)); + RooProfileLL* profile = dynamic_cast<RooProfileLL*>(nll->createProfile(allButNuisance)); profile->getVal(); // this will do fit and set nuisance parameters to profiled values // Hack to extract a RooFitResult if (fStoreFitInfo) { - RooFitResult *result = profile->minuit()->save(); - fFitInfo->addOwned(*DetailedOutputAggregator::GetAsArgSet(result, "fitAlt_")); + RooFitResult *result = profile->minimizer()->save(); + RooArgSet * detOutput = DetailedOutputAggregator::GetAsArgSet(result, "fitAlt_"); + fFitInfo->addOwned(*detOutput); + delete detOutput; delete result; } diff --git a/roofit/roostats/src/HLFactory.cxx b/roofit/roostats/src/HLFactory.cxx index 68343e8c750a6..9c0ff017930e9 100644 --- a/roofit/roostats/src/HLFactory.cxx +++ b/roofit/roostats/src/HLFactory.cxx @@ -34,6 +34,8 @@ END_HTML #include "RooSimultaneous.h" +using namespace std; + ClassImp(RooStats::HLFactory) ; @@ -318,13 +320,15 @@ RooDataSet* HLFactory::GetTotDataSet(){ while ((obj = it->Next())){ ostring=(TObjString*) obj; catindex++; - RooDataSet* dummy = new RooDataSet(*(RooDataSet*)fWs->data(ostring->String()),""); + RooDataSet * data = (RooDataSet*)fWs->data(ostring->String()); + if (!data) return NULL; + RooDataSet* dummy = new RooDataSet(*data,""); fComboCat->setIndex(catindex); fComboCat->Print(); dummy->addColumn(*fComboCat); fComboDataset->append(*dummy); delete dummy; - } + } delete it; return fComboDataset; diff --git a/roofit/roostats/src/Heaviside.cxx b/roofit/roostats/src/Heaviside.cxx index 5c2a04a5e396f..3042d0bf94d47 100644 --- a/roofit/roostats/src/Heaviside.cxx +++ b/roofit/roostats/src/Heaviside.cxx @@ -26,6 +26,8 @@ END_HTML #include "RooAbsReal.h" #endif +using namespace std; + ClassImp(RooStats::Heaviside) using namespace RooFit; diff --git a/roofit/roostats/src/HybridCalculator.cxx b/roofit/roostats/src/HybridCalculator.cxx index 5880665833fa2..b5c011857c359 100644 --- a/roofit/roostats/src/HybridCalculator.cxx +++ b/roofit/roostats/src/HybridCalculator.cxx @@ -19,27 +19,18 @@ Same purpose as HybridCalculatorOriginal, but different implementation. ClassImp(RooStats::HybridCalculator) using namespace RooStats; +using namespace std; int HybridCalculator::CheckHook(void) const { - if( (fNullModel->GetNuisanceParameters() - && fNullModel->GetNuisanceParameters()->getSize()>0 - && !fPriorNuisanceNull) - || (fAltModel->GetNuisanceParameters() - && fAltModel->GetNuisanceParameters()->getSize()>0 - && !fPriorNuisanceAlt) - ){ - oocoutE((TObject*)0,InputArguments) << "Must ForceNuisancePdf, inferring posterior from ModelConfig is not yet implemented" << endl; + + if( fPriorNuisanceNull && (!fNullModel->GetNuisanceParameters() || fNullModel->GetNuisanceParameters()->getSize() == 0) ) { + oocoutE((TObject*)0,InputArguments) << "HybridCalculator - Nuisance PDF has been specified, but is unaware of which parameters are the nuisance parameters. Must set nuisance parameters in the Null ModelConfig." << endl; return -1; // error } - - if( (!fNullModel->GetNuisanceParameters() && fPriorNuisanceNull) - || (!fAltModel->GetNuisanceParameters() && fPriorNuisanceAlt) - || (fNullModel->GetNuisanceParameters() && fNullModel->GetNuisanceParameters()->getSize()==0 && fPriorNuisanceNull) - || (fAltModel->GetNuisanceParameters() && fAltModel->GetNuisanceParameters()->getSize()>0 && !fPriorNuisanceAlt) - ){ - oocoutE((TObject*)0,InputArguments) << "Nuisance PDF specified, but the pdf doesn't know which parameters are the nuisance parameters. Must set nuisance parameters in the ModelConfig" << endl; + if( fPriorNuisanceAlt && (!fAltModel->GetNuisanceParameters() || fAltModel->GetNuisanceParameters()->getSize() == 0) ) { + oocoutE((TObject*)0,InputArguments) << "HybridCalculator - Nuisance PDF has been specified, but is unaware of which parameters are the nuisance parameters. Must set nuisance parameters in the Alt ModelConfig" << endl; return -1; // error } @@ -49,30 +40,24 @@ int HybridCalculator::CheckHook(void) const { int HybridCalculator::PreNullHook(RooArgSet* /*parameterPoint*/, double obsTestStat) const { + // ****** any TestStatSampler ******** if(fPriorNuisanceNull) { // Setup Priors for ad hoc Hybrid fTestStatSampler->SetPriorNuisance(fPriorNuisanceNull); } else if( - fNullModel->GetNuisanceParameters()==NULL || - fNullModel->GetNuisanceParameters()->getSize()==0 + fNullModel->GetNuisanceParameters() == NULL || + fNullModel->GetNuisanceParameters()->getSize() == 0 ) { oocoutI((TObject*)0,InputArguments) - << "No nuisance parameters specified and no prior forced, reduces " - << "to simple hypothesis testing with no uncertainty" << endl; + << "HybridCalculator - No nuisance parameters specified for Null model and no prior forced. " + << "Case is reduced to simple hypothesis testing with no uncertainty." << endl; } else { - // TODO principled case: - // must create posterior from Model.PriorPdf and Model.Pdf - - // Note, we do not want to use "prior" for nuisance parameters: - // fTestStatSampler->SetPriorNuisance(const_cast<RooAbsPdf*>(model.GetPriorPdf())); - - oocoutE((TObject*)0,InputArguments) << "inferring posterior from ModelConfig is not yet implemented" << endl; + oocoutI((TObject*)0,InputArguments) << "HybridCalculator - Using uniform prior on nuisance parameters (Null model)." << endl; } - // ***** ToyMCSampler specific ******* // check whether TestStatSampler is a ToyMCSampler @@ -114,20 +99,13 @@ int HybridCalculator::PreAltHook(RooArgSet* /*parameterPoint*/, double obsTestSt fAltModel->GetNuisanceParameters()->getSize()==0 ) { oocoutI((TObject*)0,InputArguments) - << "No nuisance parameters specified and no prior forced, reduces " - << "to simple hypothesis testing with no uncertainty" << endl; + << "HybridCalculator - No nuisance parameters specified for Alt model and no prior forced. " + << "Case is reduced to simple hypothesis testing with no uncertainty." << endl; } else { - // TODO principled case: - // must create posterior from Model.PriorPdf and Model.Pdf - - // Note, we do not want to use "prior" for nuisance parameters: - // fTestStatSampler->SetPriorNuisance(const_cast<RooAbsPdf*>(model.GetPriorPdf())); - - oocoutE((TObject*)0,InputArguments) << "inferring posterior from ModelConfig is not yet implemented" << endl; + oocoutI((TObject*)0,InputArguments) << "HybridCalculator - Using uniform prior on nuisance parameters (Alt model)." << endl; } - // ***** ToyMCSampler specific ******* // check whether TestStatSampler is a ToyMCSampler diff --git a/roofit/roostats/src/HybridCalculatorOriginal.cxx b/roofit/roostats/src/HybridCalculatorOriginal.cxx index 7cd1db59c3332..6af12fc2f83fa 100644 --- a/roofit/roostats/src/HybridCalculatorOriginal.cxx +++ b/roofit/roostats/src/HybridCalculatorOriginal.cxx @@ -73,6 +73,8 @@ see also the following interesting references: #include "RooStats/HybridCalculatorOriginal.h" +using namespace std; + ClassImp(RooStats::HybridCalculatorOriginal) using namespace RooStats; @@ -122,7 +124,7 @@ HybridCalculatorOriginal::HybridCalculatorOriginal( RooAbsPdf& sbModel, // observables are managed by the class (they are copied in) fObservables = new RooArgList(observables); - //Try to recover the informations from the pdf's + //Try to recover the information from the pdf's //fObservables=new RooArgList("fObservables"); //fNuisanceParameters=new RooArgSet("fNuisanceParameters"); // if (priorPdf){ diff --git a/roofit/roostats/src/HybridPlot.cxx b/roofit/roostats/src/HybridPlot.cxx index e811924733810..ef5e2ae767c93 100644 --- a/roofit/roostats/src/HybridPlot.cxx +++ b/roofit/roostats/src/HybridPlot.cxx @@ -31,6 +31,8 @@ An example plot is available here: #include <algorithm> /// To build the THtml documentation +using namespace std; + ClassImp(RooStats::HybridPlot) using namespace RooStats; diff --git a/roofit/roostats/src/HybridResult.cxx b/roofit/roostats/src/HybridResult.cxx index 9f540a417ab13..d222204d0205d 100644 --- a/roofit/roostats/src/HybridResult.cxx +++ b/roofit/roostats/src/HybridResult.cxx @@ -39,6 +39,8 @@ TConfidenceLevel class (http://root.cern.ch/root/html/TConfidenceLevel.html). /// ClassImp for building the THtml documentation of the class +using namespace std; + ClassImp(RooStats::HybridResult) using namespace RooStats; diff --git a/roofit/roostats/src/HypoTestCalculatorGeneric.cxx b/roofit/roostats/src/HypoTestCalculatorGeneric.cxx index ecb39309b05ec..0a68e10af39f7 100644 --- a/roofit/roostats/src/HypoTestCalculatorGeneric.cxx +++ b/roofit/roostats/src/HypoTestCalculatorGeneric.cxx @@ -22,11 +22,13 @@ ToyMCSampler as its TestStatSampler. #include "RooAddPdf.h" +#include "RooRandom.h" + ClassImp(RooStats::HypoTestCalculatorGeneric) using namespace RooStats; - +using namespace std; //___________________________________ HypoTestCalculatorGeneric::HypoTestCalculatorGeneric( @@ -40,7 +42,8 @@ HypoTestCalculatorGeneric::HypoTestCalculatorGeneric( fData(&data), fTestStatSampler(sampler), fDefaultSampler(0), - fDefaultTestStat(0) + fDefaultTestStat(0), + fAltToysSeed(0) { // Constructor. When test stat sampler is not provided // uses ToyMCSampler and RatioOfProfiledLikelihoodsTestStat @@ -132,10 +135,15 @@ HypoTestResult* HypoTestCalculatorGeneric::GetHypoTest() const { RooArgList* allTS = NULL; if( toymcs ) { allTS = toymcs->EvaluateAllTestStatistics(*const_cast<RooAbsData*>(fData), nullP); + if (!allTS) return 0; //oocoutP((TObject*)0,Generation) << "All Test Statistics on data: " << endl; //allTS->Print("v"); RooRealVar* firstTS = (RooRealVar*)allTS->at(0); obsTestStat = firstTS->getVal(); + if (allTS->getSize()<=1) { + delete allTS; + allTS= 0; // don't save + } }else{ obsTestStat = fTestStatSampler->EvaluateTestStatistic(*const_cast<RooAbsData*>(fData), nullP); } @@ -158,7 +166,13 @@ HypoTestResult* HypoTestCalculatorGeneric::GetHypoTest() const { RooDataSet* detOut_null = NULL; if(toymcs) { detOut_null = toymcs->GetSamplingDistributions(paramPointNull); - if( detOut_null ) samp_null = new SamplingDistribution( detOut_null->GetName(), detOut_null->GetTitle(), *detOut_null ); + if( detOut_null ) { + samp_null = new SamplingDistribution( detOut_null->GetName(), detOut_null->GetTitle(), *detOut_null ); + if (detOut_null->get()->getSize()<=1) { + delete detOut_null; + detOut_null= 0; + } + } }else samp_null = fTestStatSampler->GetSamplingDistribution(paramPointNull); // set parameters back @@ -173,8 +187,29 @@ HypoTestResult* HypoTestCalculatorGeneric::GetHypoTest() const { SamplingDistribution* samp_alt = NULL; RooDataSet* detOut_alt = NULL; if(toymcs) { + + // case of re-using same toys for every points + // set a given seed + unsigned int prevSeed = 0; + if (fAltToysSeed > 0) { + prevSeed = RooRandom::integer(std::numeric_limits<unsigned int>::max()-1)+1; // want to avoid zero value + RooRandom::randomGenerator()->SetSeed(fAltToysSeed); + } + detOut_alt = toymcs->GetSamplingDistributions(paramPointAlt); - if( detOut_alt ) samp_alt = new SamplingDistribution( detOut_alt->GetName(), detOut_alt->GetTitle(), *detOut_alt ); + if( detOut_alt ) { + samp_alt = new SamplingDistribution( detOut_alt->GetName(), detOut_alt->GetTitle(), *detOut_alt ); + if (detOut_alt->get()->getSize()<=1) { + delete detOut_alt; + detOut_alt= 0; + } + } + + // restore the seed + if (prevSeed > 0) { + RooRandom::randomGenerator()->SetSeed(prevSeed); + } + }else samp_alt = fTestStatSampler->GetSamplingDistribution(paramPointAlt); @@ -197,6 +232,7 @@ HypoTestResult* HypoTestCalculatorGeneric::GetHypoTest() const { } *bothParams = *saveAll; + delete allTS; delete bothParams; delete saveAll; delete altParams; @@ -206,6 +242,11 @@ HypoTestResult* HypoTestCalculatorGeneric::GetHypoTest() const { return res; } - +//____________________________________________________ +void HypoTestCalculatorGeneric::UseSameAltToys() { + // to re-use same toys for alternate hypothesis + fAltToysSeed = RooRandom::integer(std::numeric_limits<unsigned int>::max()-1)+1; +} + diff --git a/roofit/roostats/src/HypoTestInverter.cxx b/roofit/roostats/src/HypoTestInverter.cxx index 1a35b03d17402..d67b14db768f5 100644 --- a/roofit/roostats/src/HypoTestInverter.cxx +++ b/roofit/roostats/src/HypoTestInverter.cxx @@ -62,6 +62,7 @@ The class can scan the CLs+b values or alternativly CLs (if the method HypoTestI ClassImp(RooStats::HypoTestInverter) using namespace RooStats; +using namespace std; // static variable definitions double HypoTestInverter::fgCLAccuracy = 0.005; diff --git a/roofit/roostats/src/HypoTestInverterOriginal.cxx b/roofit/roostats/src/HypoTestInverterOriginal.cxx index 381b1ad784f8c..c7332151eae0a 100644 --- a/roofit/roostats/src/HypoTestInverterOriginal.cxx +++ b/roofit/roostats/src/HypoTestInverterOriginal.cxx @@ -41,6 +41,7 @@ The class can scan the CLs+b values or alternativly CLs (if the method HypoTestI ClassImp(RooStats::HypoTestInverterOriginal) using namespace RooStats; +using namespace std; HypoTestInverterOriginal::HypoTestInverterOriginal( ) : @@ -330,7 +331,7 @@ bool HypoTestInverterOriginal::RunFixedScan( int nBins, double xMin, double xMax // check if failed status if ( status==false ) { - std::cout << "Loop interupted because of failed status\n"; + std::cout << "Loop interrupted because of failed status\n"; return false; } } diff --git a/roofit/roostats/src/HypoTestInverterPlot.cxx b/roofit/roostats/src/HypoTestInverterPlot.cxx index 0751452267c8f..7f2af3026ed99 100644 --- a/roofit/roostats/src/HypoTestInverterPlot.cxx +++ b/roofit/roostats/src/HypoTestInverterPlot.cxx @@ -33,6 +33,8 @@ #include "TPad.h" #include "Math/DistFuncMathCore.h" +using namespace std; + ClassImp(RooStats::HypoTestInverterPlot) using namespace RooStats; diff --git a/roofit/roostats/src/HypoTestInverterResult.cxx b/roofit/roostats/src/HypoTestInverterResult.cxx index 74eb27864dc94..ce32f820a44b2 100644 --- a/roofit/roostats/src/HypoTestInverterResult.cxx +++ b/roofit/roostats/src/HypoTestInverterResult.cxx @@ -41,6 +41,7 @@ ClassImp(RooStats::HypoTestInverterResult) using namespace RooStats; using namespace RooFit; +using namespace std; // initialize static value @@ -57,7 +58,8 @@ HypoTestInverterResult::HypoTestInverterResult(const char * name ) : fFittedUpperLimit(false), fInterpolOption(kLinear), fLowerLimitError(-1), - fUpperLimitError(-1) + fUpperLimitError(-1), + fCLsCleanupThreshold(0.005) { // default constructor fLowerLimit = TMath::QuietNaN(); @@ -65,6 +67,69 @@ HypoTestInverterResult::HypoTestInverterResult(const char * name ) : } +HypoTestInverterResult::HypoTestInverterResult( const HypoTestInverterResult& other, const char * name ) : + SimpleInterval(other,name), + fUseCLs(other.fUseCLs), + fIsTwoSided(other.fIsTwoSided), + fInterpolateLowerLimit(other.fInterpolateLowerLimit), + fInterpolateUpperLimit(other.fInterpolateUpperLimit), + fFittedLowerLimit(other.fFittedLowerLimit), + fFittedUpperLimit(other.fFittedUpperLimit), + fInterpolOption(other.fInterpolOption), + fLowerLimitError(other.fLowerLimitError), + fUpperLimitError(other.fUpperLimitError), + fCLsCleanupThreshold(other.fCLsCleanupThreshold) +{ + // copy constructor + fLowerLimit = TMath::QuietNaN(); + fUpperLimit = TMath::QuietNaN(); + int nOther = other.ArraySize(); + + fXValues = other.fXValues; + for (int i = 0; i < nOther; ++i) + fYObjects.Add( other.fYObjects.At(i)->Clone() ); + for (int i = 0; i < fExpPValues.GetSize() ; ++i) + fExpPValues.Add( other.fExpPValues.At(i)->Clone() ); +} + + +HypoTestInverterResult& +HypoTestInverterResult::operator=(const HypoTestInverterResult& other) +{ + if (&other==this) { + return *this ; + } + + SimpleInterval::operator = (other); + fLowerLimit = other.fLowerLimit; + fUpperLimit = other.fUpperLimit; + fUseCLs = other.fUseCLs; + fIsTwoSided = other.fIsTwoSided; + fInterpolateLowerLimit = other.fInterpolateLowerLimit; + fInterpolateUpperLimit = other.fInterpolateUpperLimit; + fFittedLowerLimit = other.fFittedLowerLimit; + fFittedUpperLimit = other.fFittedUpperLimit; + fInterpolOption = other.fInterpolOption; + fLowerLimitError = other.fLowerLimitError; + fUpperLimitError = other.fUpperLimitError; + fCLsCleanupThreshold = other.fCLsCleanupThreshold; + + int nOther = other.ArraySize(); + fXValues = other.fXValues; + + fYObjects.RemoveAll(); + for (int i=0; i < nOther; ++i) { + fYObjects.Add( other.fYObjects.At(i)->Clone() ); + } + fExpPValues.RemoveAll(); + for (int i=0; i < fExpPValues.GetSize() ; ++i) { + fExpPValues.Add( other.fExpPValues.At(i)->Clone() ); + } + + return *this; +} + + HypoTestInverterResult::HypoTestInverterResult( const char* name, const RooRealVar& scannedVariable, double cl ) : @@ -77,7 +142,8 @@ HypoTestInverterResult::HypoTestInverterResult( const char* name, fFittedUpperLimit(false), fInterpolOption(kLinear), fLowerLimitError(-1), - fUpperLimitError(-1) + fUpperLimitError(-1), + fCLsCleanupThreshold(0.005) { // constructor fYObjects.SetOwner(); @@ -90,6 +156,126 @@ HypoTestInverterResult::HypoTestInverterResult( const char* name, } +int +HypoTestInverterResult::ExclusionCleanup() +{ + const int nEntries = ArraySize(); + + // initialization + double nsig1(1.0); + double nsig2(2.0); + double p[5]; + double q[5]; + std::vector<double> qv; + qv.resize(11,-1.0); + + p[0] = ROOT::Math::normal_cdf(-nsig2); + p[1] = ROOT::Math::normal_cdf(-nsig1); + p[2] = 0.5; + p[3] = ROOT::Math::normal_cdf(nsig1); + p[4] = ROOT::Math::normal_cdf(nsig2); + + bool resultIsAsymptotic(false); + if (nEntries>=1) { + HypoTestResult* r = dynamic_cast<HypoTestResult *> ( GetResult(0) ); + assert(r!=0); + if ( !r->GetNullDistribution() && !r->GetAltDistribution() ) { + resultIsAsymptotic = true; + } + } + + int nPointsRemoved(0); + + double CLsobsprev(1.0); + std::vector<double>::iterator itr = fXValues.begin(); + + for (; itr!=fXValues.end();) { + + double x = (*itr); + int i = FindIndex(x); + //HypoTestResult* oneresult = GetResult(i); + + SamplingDistribution * s = GetExpectedPValueDist(i); + if (!s) break; + + ///////////////////////////////////////////////////////////////////////////////////////// + + const std::vector<double> & values = s->GetSamplingDistribution(); + + /// expected p-values + // special case for asymptotic results (cannot use TMath::quantile in that case) + if (resultIsAsymptotic) { + double maxSigma = 5; // == HypoTestInverterResult::fgAsymptoticMaxSigma; // MB: HACK + double dsig = 2.*maxSigma / (values.size() -1) ; + int i0 = (int) TMath::Floor ( ( -nsig2 + maxSigma )/dsig + 0.5 ); + int i1 = (int) TMath::Floor ( ( -nsig1 + maxSigma )/dsig + 0.5 ); + int i2 = (int) TMath::Floor ( ( maxSigma )/dsig + 0.5 ); + int i3 = (int) TMath::Floor ( ( nsig1 + maxSigma )/dsig + 0.5 ); + int i4 = (int) TMath::Floor ( ( nsig2 + maxSigma )/dsig + 0.5 ); + // + q[0] = values[i0]; + q[1] = values[i1]; + q[2] = values[i2]; + q[3] = values[i3]; + q[4] = values[i4]; + } else { + double * z = const_cast<double *>( &values[0] ); // need to change TMath::Quantiles + TMath::Quantiles(values.size(), 5, z, q, p, false); + } + + delete s; + + /// store useful quantities for reuse later ... + /// http://root.cern.ch/root/html532/src/RooStats__HypoTestInverterPlot.cxx.html#197 + for (int j=0; j<5; ++j) { qv[j]=q[j]; } + qv[5] = CLs(i) ; // + qv[6] = CLsError(i) ; // + qv[7] = CLb(i) ; // + qv[8] = CLbError(i) ; // + qv[9] = CLsplusb(i) ; // + qv[10] = CLsplusbError(i) ; // + double CLsobs = qv[5]; + + ///////////////////////////////////////////////////////////////////////////////////////// + + bool removeThisPoint(false); + + // 1. CLs should drop, else skip this point + if (!removeThisPoint && resultIsAsymptotic && i>=1 && CLsobs>CLsobsprev) { + //StatToolsLogger << kERROR << "Asymptotic. CLs not dropping: " << CLsobs << ". Remove this point." << GEndl; + removeThisPoint = true; + } else { CLsobsprev = CLsobs; } + + // 2. CLs should not spike, else skip this point + if (!removeThisPoint && i>=1 && CLsobs>=0.9999) { + //StatToolsLogger << kERROR << "CLs spiking at 1.0: " << CLsobs << ". Remove this point." << GEndl; + removeThisPoint = true; + } + // 3. Not interested in CLs values that become too low. + if (!removeThisPoint && i>=1 && qv[4]<fCLsCleanupThreshold) { removeThisPoint = true; } + + // to remove or not to remove + if (removeThisPoint) { + itr = fXValues.erase(itr); // returned itr has been updated. + fYObjects.RemoveAt(i); + fExpPValues.RemoveAt(i); + nPointsRemoved++; + continue; + } else { // keep + CLsobsprev = CLsobs; + itr++; + } + } + + // after cleanup, reset existing limits + fFittedUpperLimit = false; + fFittedLowerLimit = false; + FindInterpolatedLimit(1-ConfidenceLevel(),true); + + return nPointsRemoved; +} + + HypoTestInverterResult::~HypoTestInverterResult() { // destructor @@ -507,27 +693,21 @@ double HypoTestInverterResult::FindInterpolatedLimit(double target, bool lowSear // search first for min/max in the given range if (xmin >= xmax) { - // this condition is nor needed: skip it - //if ((TMath::IsNaN(fLowerLimit) || fLowerLimit == varmin ) && ( TMath::IsNaN(fUpperLimit) || fUpperLimit == varmax) ) { - - // search for maximum - double ymax = 0; - double xwithymax = varmin; - int iymax = 0; - for (int i = 0; i < n; ++i) { - double xp = 0, yp = 0; - graph.GetPoint(i, xp, yp); - if (yp > ymax) { - ymax = yp; - xwithymax = xp; - iymax = i; - } - } + + // search for maximum between the point + double * itrmax = std::max_element(graph.GetY() , graph.GetY() +n); + double ymax = *itrmax; + int iymax = itrmax - graph.GetY(); + double xwithymax = graph.GetX()[iymax]; + + //std::cout << " max of y " << iymax << " " << xwithymax << " " << ymax << " target is " << target << std::endl; + + // look if maximum is above/belove target if (ymax > target) { if (lowSearch) { if ( iymax > 0) { - // low search - xmin = varmin; + // low search (minimmum is first point or minimum range) + xmin = ( graph.GetY()[0] <= target ) ? graph.GetX()[0] : varmin; xmax = xwithymax; } else { @@ -540,7 +720,7 @@ double HypoTestInverterResult::FindInterpolatedLimit(double target, bool lowSear // up search if ( iymax < n-1 ) { xmin = xwithymax; - xmax = varmax; + xmax = ( graph.GetY()[n-1] <= target ) ? graph.GetX()[n-1] : varmax; } else { // no room for upper limit @@ -563,9 +743,11 @@ double HypoTestInverterResult::FindInterpolatedLimit(double target, bool lowSear fUpperLimit = varmax; } } -#ifdef DO_DEBUG - std::cout << " found xmin, xmax = " << xmin << " " << xmax << " for search " << lowSearch std::endl; + +#ifdef DO_DEBUG + std::cout << " found xmin, xmax = " << xmin << " " << xmax << " for search " << lowSearch << std::endl; #endif + // now come here if I have already found a lower/upper limit // i.e. I am calling routine for the second time #ifdef ISNEEDED diff --git a/roofit/roostats/src/HypoTestPlot.cxx b/roofit/roostats/src/HypoTestPlot.cxx index ff0f698fdddf3..008f2d8ea492f 100644 --- a/roofit/roostats/src/HypoTestPlot.cxx +++ b/roofit/roostats/src/HypoTestPlot.cxx @@ -16,12 +16,12 @@ #include "RooStats/HypoTestPlot.h" - +#include "TStyle.h" ClassImp(RooStats::HypoTestPlot) using namespace RooStats; -#include "TStyle.h" +using namespace std; HypoTestPlot::HypoTestPlot(HypoTestResult& result, Int_t bins, Option_t* opt) : SamplingDistPlot(bins), @@ -55,7 +55,7 @@ void HypoTestPlot::ApplyResult(HypoTestResult& result, Option_t* opt) { } if(result.HasTestStatisticData()) { - Float_t theMin(0.), theMax(0.), theYMax(0.); + Double_t theMin(0.), theMax(0.), theYMax(0.); GetAbsoluteInterval(theMin, theMax, theYMax); AddLine(result.GetTestStatisticData(), 0, result.GetTestStatisticData(), theYMax*0.66, "test statistic data"); diff --git a/roofit/roostats/src/HypoTestResult.cxx b/roofit/roostats/src/HypoTestResult.cxx index f11b045c3998c..d6e9275d19ee6 100644 --- a/roofit/roostats/src/HypoTestResult.cxx +++ b/roofit/roostats/src/HypoTestResult.cxx @@ -50,6 +50,7 @@ END_HTML ClassImp(RooStats::HypoTestResult) ; using namespace RooStats; +using namespace std; //____________________________________________________________________ @@ -113,6 +114,35 @@ HypoTestResult::~HypoTestResult() if( fAllTestStatisticsData ) delete fAllTestStatisticsData; } +//____________________________________________________________________ +HypoTestResult & HypoTestResult::operator=(const HypoTestResult& other) { + // assignment operator + + if (this == &other) return *this; + SetName(other.GetName()); + SetTitle(other.GetTitle()); + fNullPValue = other.fNullPValue; + fAlternatePValue = other.fAlternatePValue; + fNullPValueError = other.fNullPValueError; + fAlternatePValueError = other.fAlternatePValueError; + fTestStatisticData = other.fTestStatisticData; + + if( fAllTestStatisticsData ) delete fAllTestStatisticsData; + fAllTestStatisticsData = NULL; + if( fNullDistr ) delete fNullDistr; fNullDistr = NULL; + if( fAltDistr ) delete fAltDistr; fAltDistr = NULL; + if( fNullDetailedOutput ) delete fNullDetailedOutput; fNullDetailedOutput = NULL; + if( fAltDetailedOutput ) delete fAltDetailedOutput; fAltDetailedOutput = NULL; + if (fFitInfo) delete fFitInfo; fFitInfo = NULL; + + fPValueIsRightTail = other.GetPValueIsRightTail(); + fBackgroundIsAlt = other.GetBackGroundIsAlt(); + + this->Append( &other ); + + return *this; +} + void HypoTestResult::Append(const HypoTestResult* other) { // Add additional toy-MC experiments to the current results. @@ -218,6 +248,11 @@ Double_t HypoTestResult::CLsplusbError() const { return fBackgroundIsAlt ? fNullPValueError : fAlternatePValueError; } +//____________________________________________________________________ +Double_t HypoTestResult::SignificanceError() const { + // Taylor expansion series approximation for standard deviation (error propagation) + return NullPValueError() / ROOT::Math::normal_pdf(Significance()); +} //____________________________________________________________________ Double_t HypoTestResult::CLsError() const { @@ -274,26 +309,28 @@ void HypoTestResult::Print(Option_t * ) const bool fromToys = (fAltDistr || fNullDistr); - cout << endl << "Results " << GetName() << ": " << endl; - cout << " - Null p-value = " << NullPValue(); - if (fromToys) cout << " +/- " << NullPValueError(); - cout << endl; - cout << " - Significance = " << Significance() << " sigma" << endl; + std::cout << std::endl << "Results " << GetName() << ": " << endl; + std::cout << " - Null p-value = " << NullPValue(); + if (fromToys) std::cout << " +/- " << NullPValueError(); + std::cout << std::endl; + std::cout << " - Significance = " << Significance(); + if (fromToys) std::cout << " +/- " << SignificanceError() << " sigma"; + std::cout << std::endl; if(fAltDistr) - cout << " - Number of Alt toys: " << fAltDistr->GetSize() << std::endl; + std::cout << " - Number of Alt toys: " << fAltDistr->GetSize() << std::endl; if(fNullDistr) - cout << " - Number of Null toys: " << fNullDistr->GetSize() << std::endl; + std::cout << " - Number of Null toys: " << fNullDistr->GetSize() << std::endl; - if (HasTestStatisticData() ) cout << " - Test statistic evaluated on data: " << fTestStatisticData << std::endl; - cout << " - CL_b: " << CLb(); - if (fromToys) cout << " +/- " << CLbError(); - cout << std::endl; - cout << " - CL_s+b: " << CLsplusb(); - if (fromToys) cout << " +/- " << CLsplusbError(); - cout << std::endl; - cout << " - CL_s: " << CLs(); - if (fromToys) cout << " +/- " << CLsError(); - cout << std::endl; + if (HasTestStatisticData() ) std::cout << " - Test statistic evaluated on data: " << fTestStatisticData << std::endl; + std::cout << " - CL_b: " << CLb(); + if (fromToys) std::cout << " +/- " << CLbError(); + std::cout << std::endl; + std::cout << " - CL_s+b: " << CLsplusb(); + if (fromToys) std::cout << " +/- " << CLsplusbError(); + std::cout << std::endl; + std::cout << " - CL_s: " << CLs(); + if (fromToys) std::cout << " +/- " << CLsError(); + std::cout << std::endl; return; } diff --git a/roofit/roostats/src/LikelihoodInterval.cxx b/roofit/roostats/src/LikelihoodInterval.cxx index ddb8775795b4f..a27c526c7660a 100644 --- a/roofit/roostats/src/LikelihoodInterval.cxx +++ b/roofit/roostats/src/LikelihoodInterval.cxx @@ -69,7 +69,10 @@ END_HTML #include "RooProfileLL.h" #include <string> - +#include <algorithm> +#include <functional> +#include <ctype.h> // need to use c version of toupper defined here +# /* // for debugging #include "RooNLLVar.h" @@ -81,6 +84,7 @@ END_HTML ClassImp(RooStats::LikelihoodInterval) ; using namespace RooStats; +using namespace std; //____________________________________________________________________ @@ -191,7 +195,7 @@ Double_t LikelihoodInterval::LowerLimit(const RooRealVar& param, bool & status) { // Compute lower limit, check first if limit has been computed // status is a boolean flag which will b set to false in case of error - // and is true if calculation is succesfull + // and is true if calculation is successful // in case of error return also a lower limit value of zero double lower = 0; @@ -205,7 +209,7 @@ Double_t LikelihoodInterval::UpperLimit(const RooRealVar& param, bool & status) { // Compute upper limit, check first if limit has been computed // status is a boolean flag which will b set to false in case of error - // and is true if calculation is succesfull + // and is true if calculation is successful // in case of error return also a lower limit value of zero double lower = 0; @@ -257,9 +261,11 @@ bool LikelihoodInterval::CreateMinimizer() { fFunctor = std::auto_ptr<RooFunctor>(new RooFunctor(nll, RooArgSet(), params )); std::string minimType = ROOT::Math::MinimizerOptions::DefaultMinimizerType(); + std::transform(minimType.begin(), minimType.end(), minimType.begin(), (int(*)(int)) tolower ); + *minimType.begin() = toupper( *minimType.begin()); - if (minimType != "Minuit" && minimType != "Minuit2") { - ccoutE(InputArguments) << minimType << "is wrong type of minimizer for getting interval limits or contours - must use Minuit or Minuit2" << std::endl; + if (minimType != "Minuit" && minimType != "Minuit2") { + ccoutE(InputArguments) << minimType << " is wrong type of minimizer for getting interval limits or contours - must use Minuit or Minuit2" << std::endl; return false; } // create minimizer class diff --git a/roofit/roostats/src/LikelihoodIntervalPlot.cxx b/roofit/roostats/src/LikelihoodIntervalPlot.cxx index 280178dd6961d..d3d0c2716c5d0 100644 --- a/roofit/roostats/src/LikelihoodIntervalPlot.cxx +++ b/roofit/roostats/src/LikelihoodIntervalPlot.cxx @@ -25,6 +25,7 @@ object. #include <algorithm> #include <iostream> +#include <cmath> #include "TROOT.h" #include "TMath.h" @@ -33,14 +34,19 @@ object. #include "TList.h" #include "TGraph.h" #include "TPad.h" +#include "TCanvas.h" +#include "Math/DistFunc.h" #include "RooRealVar.h" #include "RooPlot.h" -//#include "RooProfileLL.h" +#include "RooMsgService.h" +#include "RooProfileLL.h" #include "TF1.h" /// ClassImp for building the THtml documentation of the class +using namespace std; + ClassImp(RooStats::LikelihoodIntervalPlot); using namespace RooStats; @@ -56,7 +62,7 @@ LikelihoodIntervalPlot::LikelihoodIntervalPlot() fColor = 0; fFillStyle = 4050; // half transparent fLineColor = 0; - fMaximum = 2.; + fMaximum = -1; fNPoints = 0; // default depends if 1D or 2D // default is variable range fXmin = 0; @@ -64,6 +70,7 @@ LikelihoodIntervalPlot::LikelihoodIntervalPlot() fYmin = 0; fYmax = -1; fPrecision = -1; // use default + fPlotObject = 0; } //_______________________________________________________ @@ -73,10 +80,10 @@ LikelihoodIntervalPlot::LikelihoodIntervalPlot(LikelihoodInterval* theInterval) fInterval = theInterval; fParamsPlot = fInterval->GetParameters(); fNdimPlot = fParamsPlot->getSize(); - fColor = kBlue; - fLineColor = kGreen; + fColor = 0; + fLineColor = 0; fFillStyle = 4050; // half transparent - fMaximum = 2.; + fMaximum = -1; fNPoints = 0; // default depends if 1D or 2D // default is variable range fXmin = 0; @@ -84,6 +91,7 @@ LikelihoodIntervalPlot::LikelihoodIntervalPlot(LikelihoodInterval* theInterval) fYmin = 0; fYmax = -1; fPrecision = -1; // use default + fPlotObject = 0; } //_______________________________________________________ @@ -115,48 +123,104 @@ void LikelihoodIntervalPlot::SetPlotParameters(const RooArgSet *params) //_____________________________________________________________________________ void LikelihoodIntervalPlot::Draw(const Option_t *options) { - // draw the Likelihood interval or contour plot - // For 1D problem draw the log profile likelihood function ratio and its interval - // The curve is draws in a RooPLot by default (i.e as a RooCurve) + // draw the log of the profiled likelihood function in 1D with the interval or + // as a 2D plot with the contours. + // Higher dimensionals intervals cannot be drawn. One needs to call + // SetPlotParameters to project interval in 1 or 2dim + // + // Options for drawing 1D interals + // + // For 1D problem the log of the profiled likelihood function is drawn bby default in a RooPlot as a + // RooCurve // The plotting range (default is the full parameter range) and the precision of the RooCurve // can be specified by using SetRange(x1,x2) and SetPrecision(eps). // SetNPoints(npoints) can also be used (default is npoints=100) - // Optionally the function can be drawn as a TF1 (option="tf1") obtained by sampling the npoints - // For 2D case, a contour is drawn. The number of contour points is controlled by - // SetNPoints(npoints) (default is npoints=40) - // In case of problems finding the contour with Minuit, the option "nominuit" can be used. - // In this case the profile likelihood function is sampled in the npoints x npoints values and then - // an approximate contour is obtained. + // Optionally the function can be drawn as a TF1 (option="tf1") obtained by sampling the given npoints + // in the given range + // + // Options for drawing 2D intervals + // + // For 2D case, a contour and optionally the profiled likelihood function is drawn by sampling npoints in + // the given range. A 2d histogram of nbinsX=nbinsY = sqrt(npoints) is used for sampling the profiled likelihood. + // The contour can be obtained by using Minuit or by the sampled histogram, + // If using Minuit, the number of points specifies the number of contour points. If using an histogram the number of + // points is approximatly the total number of bins of the histogram. + // Possible options: + // minuit/nominuit: use minuit for computing the contour + // hist/nohist : sample in an histogram the profiled likelihood + // + // Note that one can have both a drawing of the sampled likelihood and of the contour using minuit. + // The default options is "minuit nohist" + // The sampled histogram is drawn first by default using the option "colz" and then 8 probability contours at + // these CL are drawn: { 0.1,0.3,0.5,0.683,0.95,0.9973,0.9999366575,0.9999994267} re-drawing the histogram with the + // option "cont3" + // + // The drawn object (RooPlot or sampled histogram) is saved in teh class and can be retrieved using GetPlottedObject() + // In this way the user can eventually customize further the plot. + // Note that the class does not delete the plotted object. It needs, if needed, to be deleted by the user + + TIter it = fParamsPlot->createIterator(); + // we need to check if parameters to plot is different than parameters of interval + RooArgSet* intervalParams = fInterval->GetParameters(); + RooAbsArg * arg = 0; + RooArgSet extraParams; + while((arg=(RooAbsArg*)it.Next())) { + if (!intervalParams->contains(*arg) ) { + ccoutE(InputArguments) << "Parameter " << arg->GetName() << "is not in the list of LikelihoodInterval parameters " + << " - do not use for plotting " << std::endl; + fNdimPlot--; + extraParams.add(*arg); + } + } + if (extraParams.getSize() > 0) + fParamsPlot->remove(extraParams,true,true); if(fNdimPlot > 2){ - std::cout << "LikelihoodIntervalPlot::Draw(" << GetName() + ccoutE(InputArguments) << "LikelihoodIntervalPlot::Draw(" << GetName() << ") ERROR: contours for more than 2 dimensions not implemented!" << std::endl; return; } - - TIter it = fParamsPlot->createIterator(); - RooRealVar *myparam = (RooRealVar*)it.Next(); - - RooAbsReal* newProfile = fInterval->GetLikelihoodRatio(); + + // if the number of parameters to plot is less to the number of parameters of the LikelihoodInterval + // we need to re-do the profile likelihood function, otherwise those parameters will not be profiled + // when plotting + RooAbsReal* newProfile = 0; + RooAbsReal* oldProfile = fInterval->GetLikelihoodRatio(); + if (fNdimPlot != intervalParams->getSize() ) { + RooProfileLL * profilell = dynamic_cast<RooProfileLL*>(oldProfile); + if (!profilell) return; + RooAbsReal & nll = profilell->nll(); + newProfile = nll.createProfile(*fParamsPlot); + } + else { + newProfile = oldProfile; + } + + it.Reset(); + RooRealVar *myparam = (RooRealVar*) it.Next(); + + // do a dummy evaluation around minimum to be sure profilell has right minimum + if (fInterval->GetBestFitParameters() ) { + *fParamsPlot = *fInterval->GetBestFitParameters(); + newProfile->getVal(); + } // analyze options TString opt = options; opt.ToLower(); - // use RooPLot for drawing the 1D PL - // if option is TF1 use TF1 for drawing - bool useRooPlot = opt.Contains("rooplot") || ! (opt.Contains("tf1")); - opt.ReplaceAll("rooplot",""); - opt.ReplaceAll("tf1",""); - // use Minuit for drawing the contours of the PL - bool useMinuit = !opt.Contains("nominuit"); - opt.ReplaceAll("nominuit",""); - - RooPlot * frame = 0; TString title = GetTitle(); int nPoints = fNPoints; - if(fNdimPlot == 1){ + if(fNdimPlot == 1) { + + // 1D drawing options + // use RooPLot for drawing the 1D PL + // if option is TF1 use TF1 for drawing + bool useRooPlot = opt.Contains("rooplot") || ! (opt.Contains("tf1")); + opt.ReplaceAll("rooplot",""); + opt.ReplaceAll("tf1",""); + // if (title.Length() == 0) // title = "- log profile likelihood ratio"; @@ -170,6 +234,11 @@ void LikelihoodIntervalPlot::Draw(const Option_t *options) double x1 = myarg->getMin(); double x2 = myarg->getMax(); + // default color values + if (fColor == 0) fColor = kBlue; + if (fLineColor == 0) fLineColor = kGreen; + + RooPlot * frame = 0; // use TF1 for drawing the function if (!useRooPlot) { @@ -214,6 +283,7 @@ void LikelihoodIntervalPlot::Draw(const Option_t *options) f1->GetXaxis()->SetTitle(myarg->GetName()); f1->GetYaxis()->SetTitle(Form("- log #lambda(%s)",myparam->GetName())); f1->Draw(opt); + fPlotObject = f1->GetHistogram(); } else { @@ -239,19 +309,19 @@ void LikelihoodIntervalPlot::Draw(const Option_t *options) // plot RooCmdArg cmd; if (fPrecision > 0) cmd = RooFit::Precision(fPrecision); - newProfile->plotOn(frame,cmd); + newProfile->plotOn(frame,cmd,RooFit::LineColor(fColor)); frame->SetMaximum(fMaximum); frame->SetMinimum(0.); myarg->setBins(prevBins); - + fPlotObject = frame; } //myarg->setVal(xcont_max); //const Double_t Yat_Xmax = newProfile->getVal(); - Double_t Yat_Xmax = 0.5*TMath::ChisquareQuantile(fInterval->ConfidenceLevel(),1); + Double_t Yat_Xmax = 0.5*ROOT::Math::chisquared_quantile(fInterval->ConfidenceLevel(),1); TLine *Yline_cutoff = new TLine(x1,Yat_Xmax,x2,Yat_Xmax); TLine *Yline_min = new TLine(xcont_min,0.,xcont_min,Yat_Xmax); @@ -278,11 +348,28 @@ void LikelihoodIntervalPlot::Draw(const Option_t *options) return; } + + // case of 2 dimensions + else if(fNdimPlot == 2){ + //2D drawing options + + // use Minuit for drawing the contours of the PL (default case) + bool useMinuit = !opt.Contains("nominuit"); + // plot histogram in 2D + bool plotHist = !opt.Contains("nohist"); + opt.ReplaceAll("nominuit",""); + opt.ReplaceAll("nohist",""); + if (opt.Contains("minuit") ) useMinuit= true; + if (useMinuit) plotHist = false; // switch off hist by default in case of Minuit + if (opt.Contains("hist") ) plotHist= true; + opt.ReplaceAll("minuit",""); + opt.ReplaceAll("hist",""); + RooRealVar *myparamY = (RooRealVar*)it.Next(); - Double_t cont_level = TMath::ChisquareQuantile(fInterval->ConfidenceLevel(),fNdimPlot); // level for -2log LR + Double_t cont_level = ROOT::Math::chisquared_quantile(fInterval->ConfidenceLevel(),fNdimPlot); // level for -2log LR cont_level = cont_level/2; // since we are plotting -log LR RooArgList params(*newProfile->getVariables()); @@ -297,50 +384,146 @@ void LikelihoodIntervalPlot::Draw(const Option_t *options) // do a profile evaluation to start from the best fit values of parameters newProfile->getVal(); - if (title.Length() == 0) + if (title.Length() == 0) title = TString("Contour of ") + TString(myparamY->GetName() ) + TString(" vs ") + TString(myparam->GetName() ); + // add also labels + title = TString::Format("%s;%s;%s",title.Data(),myparam->GetName(),myparamY->GetName()); if (nPoints <=0) nPoints = 40; // default in 2D - if (!useMinuit) { + double xmin = myparam->getMin(); double xmax = myparam->getMax(); + double ymin = myparamY->getMin(); double ymax = myparamY->getMax(); + if (fXmin < fXmax) { xmin = fXmin; xmax = fXmax; } + if (fYmin < fYmax) { ymin = fYmin; ymax = fYmax; } + + + if (!useMinuit || plotHist) { // draw directly the TH2 from the profile LL - TH2F* hist2D = (TH2F*)newProfile->createHistogram("_hist2D",*myparam,RooFit::YVar(*myparamY),RooFit::Binning(nPoints),RooFit::Scaling(kFALSE)); - + TString histName = TString::Format("_hist2D__%s_%s",myparam->GetName(),myparamY->GetName() ); + int nBins = int( std::sqrt(double(nPoints)) + 0.5 ); + TH2* hist2D = new TH2D(histName, title, nBins, xmin, xmax, nBins, ymin, ymax ); + newProfile->fillHistogram(hist2D, RooArgList(*myparam,*myparamY), 1, 0, false, 0, false); hist2D->SetTitle(title); hist2D->SetStats(kFALSE); - hist2D->SetContour(1,&cont_level); + //neeed many color levels for drawing with option colz + if (plotHist) { - hist2D->SetFillColor(fColor); - hist2D->SetFillStyle(fFillStyle); - hist2D->SetLineColor(fLineColor); + const int nLevels = 51; + double contLevels[nLevels]; + contLevels[0] = 0.01; + double maxVal = (fMaximum > 0) ? fMaximum : hist2D->GetMaximum(); + for (int k = 1; k < nLevels; ++k) { + contLevels[k] = k*maxVal/double(nLevels-1); + } + hist2D->SetContour(nLevels,contLevels); + + if (fMaximum>0) hist2D->SetMaximum(fMaximum); + + hist2D->DrawClone("COLZ"); + } - TString tmpOpt(options); + + //need now less contours for drawing with option cont + + const int nLevels = 8; + double contLevels[nLevels]; + // last 3 are the 3,4,5 sigma levels + double confLevels[nLevels] = { 0.1,0.3,0.5,0.683,0.95,0.9973,0.9999366575,0.9999994267}; + for (int k = 0; k < nLevels; ++k) { + //contLevels[k] = 0.5*ROOT::Math::chisquared_quantile(1.-2.*ROOT::Math::normal_cdf_c(nSigmaLevels[k],1),2); + contLevels[k] = 0.5*ROOT::Math::chisquared_quantile(confLevels[k],2); + } + hist2D->SetContour(nLevels,contLevels); + hist2D->SetLineColor(fLineColor); + + // defult options for drawing a second histogram + TString tmpOpt = opt; + tmpOpt.ReplaceAll("same",""); + if (tmpOpt.Length() < 3) opt += "cont3"; + // if histo is plotted draw on top + if (plotHist) opt += TString(" same"); + hist2D->Draw(opt.Data()); + gPad->Update(); + + // case of plotting contours without minuit + if (!useMinuit) { + + // set levels of contours if make contours without minuit + TH2 * h = (TH2*) hist2D->Clone(); + h->SetContour(1,&cont_level); + + TVirtualPad * currentPad = gPad; + // o a temporary draw to get the contour graph + TCanvas * tmpCanvas = new TCanvas("tmpCanvas","tmpCanvas"); + h->Draw("CONT LIST"); + gPad->Update(); + + // get graphs from the contours + TObjArray *contoursOrig = (TObjArray*) gROOT->GetListOfSpecials()->FindObject("contours"); + // CLONE THE LIST IN CASE IT GETS DELETED + TObjArray *contours = 0; + if (contoursOrig) contours = (TObjArray*) contoursOrig->Clone(); + + delete tmpCanvas; + delete h; + gPad = currentPad; + - if(!tmpOpt.Contains("CONT")) tmpOpt.Append("CONT"); - if(!tmpOpt.Contains("LIST")) tmpOpt.Append("LIST"); // if you want the contour TGraphs + // in case of option CONT4 I need to re-mamke the Pad + if (tmpOpt.Contains("cont4")) { + Double_t bm = gPad->GetBottomMargin(); + Double_t lm = gPad->GetLeftMargin(); + Double_t rm = gPad->GetRightMargin(); + Double_t tm = gPad->GetTopMargin(); + Double_t x1 = hist2D->GetXaxis()->GetXmin(); + Double_t y1 = hist2D->GetYaxis()->GetXmin(); + Double_t x2 = hist2D->GetXaxis()->GetXmax(); + Double_t y2 = hist2D->GetYaxis()->GetXmax(); + + TPad *null=new TPad("null","null",0,0,1,1); + null->SetFillStyle(0); + null->SetFrameFillStyle(0); + null->Draw(); + null->cd(); + null->Range(x1-(x2-x1)*(lm/(1-rm-lm)), + y1-(y2-y1)*(bm/(1-tm-lm)), + x2+(x2-x1)*(rm/(1-rm-lm)), + y2+(y2-y1)*(tm/(1-tm-lm))); + + gPad->Update(); + } + - hist2D->Draw(tmpOpt.Data()); - // hist2D->Draw("cont2,list,same"); + if (contours) { + int ncontours = contours->GetSize(); + for (int icont = 0; icont < ncontours; ++icont) { + TList * contourList = (TList*)contours->At(icont); + if (contourList && contourList->GetSize() > 0) { + TIterator * itgr = contourList->MakeIterator(); + TGraph * gr = 0; + while( (gr = dynamic_cast<TGraph*>(itgr->Next()) ) ){ + gr->SetLineColor(fColor); + gr->SetLineStyle(kDashed); + gr->SetLineWidth(3); + gr->Draw("L"); + } + delete itgr; + } + } + } + else { + ccoutE(InputArguments) << "LikelihoodIntervalPlot::Draw(" << GetName() + << ") ERROR: no contours found in ListOfSpecial" << std::endl; + } - gPad->Update(); // needed for get list of specials + fPlotObject = hist2D; - // get TGraphs and add them - // gROOT->GetListOfSpecials()->Print(); - TObjArray *contours = (TObjArray*) gROOT->GetListOfSpecials()->FindObject("contours"); - if(contours){ - TList *list = (TList*)contours->At(0); - TGraph *gr1 = (TGraph*)list->First(); - gr1->SetLineColor(kBlack); - gr1->SetLineStyle(kDashed); - gr1->Draw("same"); - } else{ - std::cout << "no countours found in ListOfSpecials" << std::endl; } } - else { + if (useMinuit) { // find contours using Minuit TGraph * gr = new TGraph(nPoints+1); @@ -353,14 +536,9 @@ void LikelihoodIntervalPlot::Draw(const Option_t *options) } // add last point to same as first one to close the contour gr->SetPoint(ncp, gr->GetX()[0], gr->GetY()[0] ); - opt.Append("LF"); + opt.Append("L"); // draw first a dummy 2d histogram gfor the axis - if (!opt.Contains("same")) { - - double xmin = myparam->getMin(); double xmax = myparam->getMax(); - double ymin = myparamY->getMin(); double ymax = myparamY->getMax(); - if (fXmin < fXmax) { xmin = fXmin; xmax = fXmax; } - if (fYmin < fYmax) { ymin = fYmin; ymax = fYmax; } + if (!opt.Contains("same") && !plotHist) { TH2F* hist2D = new TH2F("_hist2D",title, nPoints, xmin, xmax, nPoints, ymin, ymax ); hist2D->GetXaxis()->SetTitle(myparam->GetName()); @@ -370,17 +548,37 @@ void LikelihoodIntervalPlot::Draw(const Option_t *options) hist2D->SetMaximum(1); // to avoid problem with subsequents draws hist2D->Draw("AXIS"); } - gr->SetFillColor(fColor); - //gr->SetFillStyle(fFillStyle); - gr->SetLineColor(kBlack); + gr->SetLineColor(fColor); + gr->SetLineWidth(3); if (opt.Contains("same")) gr->SetFillStyle(fFillStyle); // put transparent gr->Draw(opt); TString name = TString("Graph_of_") + TString(fInterval->GetName()); gr->SetName(name); + + if (!fPlotObject) fPlotObject = gr; + else if (fPlotObject->IsA() != TH2D::Class() ) fPlotObject = gr; } + // draw also the minimum + const RooArgSet * bestFitParams = fInterval->GetBestFitParameters(); + if (bestFitParams) { + TGraph * gr0 = new TGraph(1); + double x0 = bestFitParams->getRealValue(myparam->GetName()); + double y0 = bestFitParams->getRealValue(myparamY->GetName()); + gr0->SetPoint(0,x0,y0); + gr0->SetMarkerStyle(33); + gr0->SetMarkerColor(fColor); + gr0->Draw("P"); + delete bestFitParams; + } + + + } + // need to delete if a new profileLL was made + if (newProfile != oldProfile) delete newProfile; + return; } diff --git a/roofit/roostats/src/MCMCCalculator.cxx b/roofit/roostats/src/MCMCCalculator.cxx index 9dc46d018af0d..8395fa62139fa 100644 --- a/roofit/roostats/src/MCMCCalculator.cxx +++ b/roofit/roostats/src/MCMCCalculator.cxx @@ -82,6 +82,7 @@ ClassImp(RooStats::MCMCCalculator); using namespace RooFit; using namespace RooStats; +using namespace std; // default constructor MCMCCalculator::MCMCCalculator() : @@ -120,10 +121,14 @@ void MCMCCalculator::SetModel(const ModelConfig & model) { fPriorPdf = model.GetPriorPdf(); fPOI.removeAll(); fNuisParams.removeAll(); + fConditionalObs.removeAll(); if (model.GetParametersOfInterest()) fPOI.add(*model.GetParametersOfInterest()); if (model.GetNuisanceParameters()) fNuisParams.add(*model.GetNuisanceParameters()); + if (model.GetConditionalObservables()) + fConditionalObs.add( *(model.GetConditionalObservables() ) ); + } // Constructor for automatic configuration with basic settings. Uses a @@ -184,7 +189,7 @@ MCMCInterval* MCMCCalculator::GetInterval() const } RooArgSet* constrainedParams = prodPdf->getParameters(*fData); - RooAbsReal* nll = prodPdf->createNLL(*fData, Constrain(*constrainedParams)); + RooAbsReal* nll = prodPdf->createNLL(*fData, Constrain(*constrainedParams),ConditionalObservables(fConditionalObs)); delete constrainedParams; RooArgSet* params = nll->getParameters(*fData); diff --git a/roofit/roostats/src/MarkovChain.cxx b/roofit/roostats/src/MarkovChain.cxx index ac6292617f2a7..727a7abf77bbc 100644 --- a/roofit/roostats/src/MarkovChain.cxx +++ b/roofit/roostats/src/MarkovChain.cxx @@ -50,6 +50,8 @@ END_HTML #include "THnSparse.h" #endif +using namespace std; + ClassImp(RooStats::MarkovChain); using namespace RooFit; diff --git a/roofit/roostats/src/MetropolisHastings.cxx b/roofit/roostats/src/MetropolisHastings.cxx index dc231f2e5fb4f..7cd2e8fc4c776 100644 --- a/roofit/roostats/src/MetropolisHastings.cxx +++ b/roofit/roostats/src/MetropolisHastings.cxx @@ -98,6 +98,7 @@ ClassImp(RooStats::MetropolisHastings); using namespace RooFit; using namespace RooStats; +using namespace std; MetropolisHastings::MetropolisHastings() { @@ -160,8 +161,12 @@ MarkovChain* MetropolisHastings::ConstructChain() // We will need to check if log-likelihood evaluation left an error status. // Now using faster eval error logging with CountErrors. - if (fType == kLog) - fFunction->setEvalErrorLoggingMode(RooAbsReal::CountErrors); + if (fType == kLog) { + RooAbsReal::setEvalErrorLoggingMode(RooAbsReal::CountErrors); + //N.B: need to clear the count in case of previous errors ! + // the clear needs also to be done after calling setEvalErrorLoggingMode + RooAbsReal::clearEvalErrorLog(); + } bool hadEvalError = true; @@ -179,8 +184,8 @@ MarkovChain* MetropolisHastings::ConstructChain() xL = fFunction->getVal(); if (fType == kLog) { - if (fFunction->numEvalErrors() > 0) { - fFunction->clearEvalErrorLog(); + if (RooAbsReal::numEvalErrors() > 0) { + RooAbsReal::clearEvalErrorLog(); hadEvalError = true; } else hadEvalError = false; diff --git a/roofit/roostats/src/ModelConfig.cxx b/roofit/roostats/src/ModelConfig.cxx index 1d404e2aab34a..d65c304edf0a2 100644 --- a/roofit/roostats/src/ModelConfig.cxx +++ b/roofit/roostats/src/ModelConfig.cxx @@ -25,6 +25,7 @@ ClassImp(RooStats::ModelConfig) +using namespace std; namespace RooStats { @@ -74,68 +75,71 @@ void ModelConfig::GuessObsAndNuisance(const RooAbsData& data) { if(p.getSize()>0) SetNuisanceParameters(p); } + + // print Modelconfig as an info message + std::ostream& oldstream = RooPrintable::defaultPrintStream(&ccoutI(InputArguments)); Print(); + RooPrintable::defaultPrintStream(&oldstream); } void ModelConfig::Print(Option_t*) const { - // print contents - ccoutI(InputArguments) << endl << "=== Using the following for " << GetName() << " ===" << endl; + // print contents of Model on the default print stream + // It can be changed using RooPrintable + ostream& os = RooPrintable::defaultPrintStream(); - // necessary so that GetObservables()->Print("") gets piped to the - // ccoutI(InputArguments) stream - ostream& oldstream = RooPrintable::defaultPrintStream(&ccoutI(InputArguments)); + os << endl << "=== Using the following for " << GetName() << " ===" << endl; + // args if(GetObservables()){ - ccoutI(InputArguments) << "Observables: "; + os << "Observables: "; GetObservables()->Print(""); } if(GetParametersOfInterest()) { - ccoutI(InputArguments) << "Parameters of Interest: "; + os << "Parameters of Interest: "; GetParametersOfInterest()->Print(""); } if(GetNuisanceParameters()){ - ccoutI(InputArguments) << "Nuisance Parameters: "; + os << "Nuisance Parameters: "; GetNuisanceParameters()->Print(""); } if(GetGlobalObservables()){ - ccoutI(InputArguments) << "Global Observables: "; + os << "Global Observables: "; GetGlobalObservables()->Print(""); } if(GetConstraintParameters()){ - ccoutI(InputArguments) << "Constraint Parameters: "; + os << "Constraint Parameters: "; GetConstraintParameters()->Print(""); } if(GetConditionalObservables()){ - ccoutI(InputArguments) << "Conditional Observables: "; + os << "Conditional Observables: "; GetConditionalObservables()->Print(""); } if(GetProtoData()){ - ccoutI(InputArguments) << "Proto Data: "; + os << "Proto Data: "; GetProtoData()->Print(""); } // pdfs if(GetPdf()) { - ccoutI(InputArguments) << "PDF: "; + os << "PDF: "; GetPdf()->Print(""); } if(GetPriorPdf()) { - ccoutI(InputArguments) << "Prior PDF: "; + os << "Prior PDF: "; GetPriorPdf()->Print(""); } // snapshot const RooArgSet * snapshot = GetSnapshot(); if(snapshot) { - ccoutI(InputArguments) << "Snapshot: " << endl; + os << "Snapshot: " << endl; snapshot->Print("v"); delete snapshot; } - ccoutI(InputArguments) << endl; - RooPrintable::defaultPrintStream(&oldstream); + os << endl; } @@ -182,37 +186,52 @@ const RooArgSet * ModelConfig::GetSnapshot() const{ // User must delete returned RooArgSet. if ( !GetWS() ) return 0; if (!fSnapshotName.length()) return 0; + // calling loadSnapshot will also copy the current parameter values in the workspaces + // since we do not want to change the model parameters - we restore the previous ones + if (! GetWS()->set(fSnapshotName.c_str() ) )return 0; + RooArgSet snapshotVars(*GetWS()->set(fSnapshotName.c_str() ) ); + if (snapshotVars.getSize() == 0) return 0; + // make my snapshot which will contain a copy of the snapshot variables + RooArgSet tempSnapshot; + snapshotVars.snapshot(tempSnapshot); + // load snapshot value from the workspace if (!(GetWS()->loadSnapshot(fSnapshotName.c_str())) ) return 0; - - return dynamic_cast<const RooArgSet*>(GetWS()->set(fSnapshotName.c_str() )->snapshot()); + // by doing this snapshotVars will have the snapshot values - make the snapshot to return + const RooArgSet * modelSnapshot = dynamic_cast<const RooArgSet*>( snapshotVars.snapshot()); + // restore now the variables of snapshot in ws to their original values + // need to const cast since assign is not const (but in reality in just assign values and does not change the set) + // and anyway the set is const + snapshotVars.assignFast(tempSnapshot); + return modelSnapshot; } void ModelConfig::LoadSnapshot() const{ // load the snapshot from ws if it exists if ( !GetWS() ) return; - - // kill output - RooFit::MsgLevel level = RooMsgService::instance().globalKillBelow(); - RooMsgService::instance().setGlobalKillBelow(RooFit::ERROR); GetWS()->loadSnapshot(fSnapshotName.c_str()); - RooMsgService::instance().setGlobalKillBelow(level); } void ModelConfig::DefineSetInWS(const char* name, const RooArgSet& set) { // helper functions to avoid code duplication if ( !GetWS() ) return; - if ( GetWS()->set(name) ) { - GetWS()->removeSet(name); + const RooArgSet * prevSet = GetWS()->set(name); + if ( prevSet ) { + //be careful not to remove passed set in case it is the same updated + if (prevSet != &set) + GetWS()->removeSet(name); } + // suppress warning when we re-define a previously defined set (when set == prevSet ) + // and set is not removed in that case RooFit::MsgLevel level = RooMsgService::instance().globalKillBelow(); RooMsgService::instance().setGlobalKillBelow(RooFit::ERROR) ; + GetWS()->defineSet(name, set,true); RooMsgService::instance().setGlobalKillBelow(level) ; - + } void ModelConfig::ImportPdfInWS(const RooAbsPdf & pdf) { @@ -240,4 +259,21 @@ void ModelConfig::ImportDataInWS(RooAbsData & data) { } + Bool_t ModelConfig::SetHasOnlyParameters(const RooArgSet& set, const char* errorMsgPrefix) { + + RooArgSet nonparams ; + RooFIter iter = set.fwdIterator() ; + RooAbsArg* arg ; + while ((arg=iter.next())) { + if (!arg->isFundamental()) { + nonparams.add(*arg) ; + } + } + + if (errorMsgPrefix && nonparams.getSize()>0) { + cout << errorMsgPrefix << " ERROR: specified set contains non-parameters: " << nonparams << endl ; + } + return (nonparams.getSize()==0) ; + } + } // end namespace RooStats diff --git a/roofit/roostats/src/NeymanConstruction.cxx b/roofit/roostats/src/NeymanConstruction.cxx index 13e086b85be26..132c71ef56fda 100644 --- a/roofit/roostats/src/NeymanConstruction.cxx +++ b/roofit/roostats/src/NeymanConstruction.cxx @@ -73,6 +73,7 @@ ClassImp(RooStats::NeymanConstruction) ; using namespace RooFit; using namespace RooStats; +using namespace std; //_______________________________________________________ diff --git a/roofit/roostats/src/NumberCountingPdfFactory.cxx b/roofit/roostats/src/NumberCountingPdfFactory.cxx index 63dd92a28f61e..4f9f8c59a1196 100644 --- a/roofit/roostats/src/NumberCountingPdfFactory.cxx +++ b/roofit/roostats/src/NumberCountingPdfFactory.cxx @@ -65,6 +65,7 @@ ClassImp(RooStats::NumberCountingPdfFactory) ; using namespace RooStats; using namespace RooFit; +using namespace std; //_______________________________________________________ diff --git a/roofit/roostats/src/PdfProposal.cxx b/roofit/roostats/src/PdfProposal.cxx index f18dd65b2bb32..7cc55c17ac876 100644 --- a/roofit/roostats/src/PdfProposal.cxx +++ b/roofit/roostats/src/PdfProposal.cxx @@ -89,6 +89,7 @@ ClassImp(RooStats::PdfProposal); using namespace RooFit; using namespace RooStats; +using namespace std; // By default, PdfProposal does NOT own the PDF that serves as the // proposal density function diff --git a/roofit/roostats/src/PointSetInterval.cxx b/roofit/roostats/src/PointSetInterval.cxx index c6965d664bdda..82e15617e3d2d 100644 --- a/roofit/roostats/src/PointSetInterval.cxx +++ b/roofit/roostats/src/PointSetInterval.cxx @@ -40,6 +40,8 @@ #include "RooDataSet.h" #include "RooDataHist.h" +using namespace std; + ClassImp(RooStats::PointSetInterval) ; using namespace RooStats; diff --git a/roofit/roostats/src/ProfileInspector.cxx b/roofit/roostats/src/ProfileInspector.cxx index 3b5add00cf210..0032eb427a517 100644 --- a/roofit/roostats/src/ProfileInspector.cxx +++ b/roofit/roostats/src/ProfileInspector.cxx @@ -34,6 +34,7 @@ Utility class to plot conditional MLE of nuisance parameters vs. Parameters of I ClassImp(RooStats::ProfileInspector); using namespace RooStats; +using namespace std; //_______________________________________________________ ProfileInspector::ProfileInspector() diff --git a/roofit/roostats/src/ProfileLikelihoodCalculator.cxx b/roofit/roostats/src/ProfileLikelihoodCalculator.cxx index eba3a6a7cedb6..4e3d17e6acc00 100644 --- a/roofit/roostats/src/ProfileLikelihoodCalculator.cxx +++ b/roofit/roostats/src/ProfileLikelihoodCalculator.cxx @@ -67,6 +67,8 @@ END_HTML #include "Math/MinimizerOptions.h" //#include "RooProdPdf.h" +using namespace std; + ClassImp(RooStats::ProfileLikelihoodCalculator) ; using namespace RooFit; @@ -137,8 +139,9 @@ void ProfileLikelihoodCalculator::DoGlobalFit() const { int level = ROOT::Math::MinimizerOptions::DefaultPrintLevel() -1;// RooFit level starts from -1 oocoutP((TObject*)0,Minimization) << "ProfileLikelihoodCalcultor::DoGlobalFit - using " << minimType << " / " << minimAlgo << " with strategy " << strategy << std::endl; // do global fit and store fit result for further use - fFitResult = pdf->fitTo(*data, Constrain(*constrainedParams),Strategy(strategy),PrintLevel(level), - Hesse(kFALSE),Save(kTRUE),Minimizer(minimType,minimAlgo)); + fFitResult = pdf->fitTo(*data, Constrain(*constrainedParams),ConditionalObservables(fConditionalObs), + Strategy(strategy),PrintLevel(level), + Hesse(kFALSE),Save(kTRUE),Minimizer(minimType,minimAlgo)); // print fit result if (fFitResult) @@ -171,8 +174,9 @@ LikelihoodInterval* ProfileLikelihoodCalculator::GetInterval() const { RooProfileLL* profile = new RooProfileLL("pll","",*nll, *fPOI); profile->addOwnedComponents(*nll) ; // to avoid memory leak */ + + RooAbsReal * nll = pdf->createNLL(*data, CloneData(kTRUE), Constrain(*constrainedParams),ConditionalObservables(fConditionalObs)); - RooAbsReal* nll = pdf->createNLL(*data, CloneData(kTRUE), Constrain(*constrainedParams)); RooAbsReal* profile = nll->createProfile(fPOI); profile->addOwnedComponents(*nll) ; // to avoid memory leak @@ -297,7 +301,8 @@ HypoTestResult* ProfileLikelihoodCalculator::GetHypoTest() const { const char * minimAlgo = ROOT::Math::MinimizerOptions::DefaultMinimizerType().c_str(); int level = ROOT::Math::MinimizerOptions::DefaultPrintLevel()-1; // RooFit levels starts from -1 oocoutP((TObject*)0,Minimization) << "ProfileLikelihoodCalcultor::GetHypoTest - do conditional fit " << std::endl; - RooFitResult* fit2 = pdf->fitTo(*data,Constrain(*constrainedParams),Hesse(kFALSE),Strategy(0), Minos(kFALSE), + RooFitResult* fit2 = pdf->fitTo(*data,Constrain(*constrainedParams),ConditionalObservables(fConditionalObs), + Hesse(kFALSE),Strategy(0), Minos(kFALSE), Minimizer(minimType,minimAlgo), Save(kTRUE),PrintLevel(level)); // print fit result @@ -312,18 +317,25 @@ HypoTestResult* ProfileLikelihoodCalculator::GetHypoTest() const { } else { // get just the likelihood value (no need to do a fit since the likelihood is a constant function) - RooAbsReal* nll = pdf->createNLL(*data, CloneData(kTRUE), Constrain(*constrainedParams)); + RooAbsReal* nll = pdf->createNLL(*data, CloneData(kTRUE), Constrain(*constrainedParams),ConditionalObservables(fConditionalObs)); NLLatCondMLE = nll->getVal(); delete nll; } // Use Wilks' theorem to translate -2 log lambda into a signifcance/p-value Double_t deltaNLL = std::max( NLLatCondMLE-NLLatMLE, 0.); + + // get number of free parameter of interest + RemoveConstantParameters(poiList); + int ndf = poiList.getSize(); - TString name = TString("ProfileLRHypoTestResult_");// + TString(GetName() ); - HypoTestResult* htr = - new HypoTestResult(name, SignificanceToPValue(sqrt( 2*deltaNLL)), 0 ); + Double_t pvalue = ROOT::Math::chisquared_cdf_c( 2* deltaNLL, ndf); + + // in case of one dimenension (1 poi) do the one-sided p-value (need to divide by 2) + if (ndf == 1) pvalue = 0.5 * pvalue; + TString name = TString("ProfileLRHypoTestResult_");// + TString(GetName() ); + HypoTestResult* htr = new HypoTestResult(name, pvalue, 0 ); // restore previous value of poi for (unsigned int i = 0; i < oldValues.size(); ++i) { diff --git a/roofit/roostats/src/ProfileLikelihoodTestStat.cxx b/roofit/roostats/src/ProfileLikelihoodTestStat.cxx index 6fcae8c27e07a..0b7722420728f 100644 --- a/roofit/roostats/src/ProfileLikelihoodTestStat.cxx +++ b/roofit/roostats/src/ProfileLikelihoodTestStat.cxx @@ -24,9 +24,12 @@ #include "RooStats/RooStatsUtils.h" +using namespace std; Bool_t RooStats::ProfileLikelihoodTestStat::fgAlwaysReuseNll = kTRUE ; +void RooStats::ProfileLikelihoodTestStat::SetAlwaysReuseNLL(Bool_t flag) { fgAlwaysReuseNll = flag ; } + Double_t RooStats::ProfileLikelihoodTestStat::EvaluateProfileLikelihood(int type, RooAbsData& data, RooArgSet& paramsOfInterest) { // interna function to evaluate test statistics // can do depending on type: @@ -53,7 +56,7 @@ Double_t RooStats::ProfileLikelihoodTestStat::EvaluateProfileLikelihood(int type RooRealVar* firstPOI = dynamic_cast<RooRealVar*>( paramsOfInterest.first()); if (firstPOI) initial_mu_value = firstPOI->getVal(); //paramsOfInterest.getRealValue(firstPOI->GetName()); - if (fPrintLevel > 0) { + if (fPrintLevel > 1) { cout << "POIs: " << endl; paramsOfInterest.Print("v"); } @@ -70,15 +73,15 @@ Double_t RooStats::ProfileLikelihoodTestStat::EvaluateProfileLikelihood(int type RooStats::RemoveConstantParameters(allParams); // need to call constrain for RooSimultaneous until stripDisconnected problem fixed - fNll = (RooNLLVar*) fPdf->createNLL(data, RooFit::CloneData(kFALSE),RooFit::Constrain(*allParams)); + fNll = fPdf->createNLL(data, RooFit::CloneData(kFALSE),RooFit::Constrain(*allParams),RooFit::ConditionalObservables(fConditionalObs), RooFit::Offset(fLOffset)); created = kTRUE ; delete allParams; if (fPrintLevel > 1) cout << "creating NLL " << fNll << " with data = " << &data << endl ; } if (reuse && !created) { - if (fPrintLevel > 1) cout << "reusing NLL " << fNll << " new data = " << &data << endl ; - fNll->setData(data,kFALSE) ; + if (fPrintLevel > 1) cout << "reusing NLL " << fNll << " new data = " << &data << endl ; + fNll->setData(data,kFALSE) ; } @@ -105,6 +108,7 @@ Double_t RooStats::ProfileLikelihoodTestStat::EvaluateProfileLikelihood(int type double uncondML = 0; double fit_favored_mu = 0; int statusD = 0; + RooArgSet * detOutput = 0; if (type != 2) { // minimize and count eval errors fNll->clearEvalErrorLog(); @@ -117,8 +121,11 @@ Double_t RooStats::ProfileLikelihoodTestStat::EvaluateProfileLikelihood(int type if (firstPOI) fit_favored_mu = attachedSet->getRealValue(firstPOI->GetName()) ; // save this snapshot - if( fDetailedOutputEnabled ) - fDetailedOutput->addOwned(*DetailedOutputAggregator::GetAsArgSet(result, "fitUncond_", fDetailedOutputWithErrorsAndPulls)); + if( fDetailedOutputEnabled ) { + detOutput = DetailedOutputAggregator::GetAsArgSet(result, "fitUncond_", fDetailedOutputWithErrorsAndPulls); + fDetailedOutput->addOwned(*detOutput); + delete detOutput; + } delete result; } else { @@ -175,8 +182,11 @@ Double_t RooStats::ProfileLikelihoodTestStat::EvaluateProfileLikelihood(int type if (result) { condML = result->minNll(); statusN = result->status(); - if( fDetailedOutputEnabled ) - fDetailedOutput->addOwned(*DetailedOutputAggregator::GetAsArgSet(result, "fitCond_", fDetailedOutputWithErrorsAndPulls)); + if( fDetailedOutputEnabled ) { + detOutput = DetailedOutputAggregator::GetAsArgSet(result, "fitCond_", fDetailedOutputWithErrorsAndPulls); + fDetailedOutput->addOwned(*detOutput); + delete detOutput; + } delete result; } else { diff --git a/roofit/roostats/src/ProposalHelper.cxx b/roofit/roostats/src/ProposalHelper.cxx index 937538986c0b5..2d03f7c9af3fc 100644 --- a/roofit/roostats/src/ProposalHelper.cxx +++ b/roofit/roostats/src/ProposalHelper.cxx @@ -71,6 +71,7 @@ ClassImp(RooStats::ProposalHelper); using namespace RooFit; using namespace RooStats; +using namespace std; //static const Double_t DEFAULT_UNI_FRAC = 0.10; static const Double_t DEFAULT_CLUES_FRAC = 0.20; diff --git a/roofit/roostats/src/RatioOfProfiledLikelihoodsTestStat.cxx b/roofit/roostats/src/RatioOfProfiledLikelihoodsTestStat.cxx index 6d7904d7921b8..cf62e0230bbde 100644 --- a/roofit/roostats/src/RatioOfProfiledLikelihoodsTestStat.cxx +++ b/roofit/roostats/src/RatioOfProfiledLikelihoodsTestStat.cxx @@ -1,7 +1,89 @@ +// @(#)root/roostats:$Id$ +// Author: Kyle Cranmer, Lorenzo Moneta, Gregory Schott, Wouter Verkerke +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ #include "RooStats/RatioOfProfiledLikelihoodsTestStat.h" #include "RooArgSet.h" #include "RooAbsData.h" +#include "TMath.h" +#include "RooMsgService.h" +#include "RooGlobalFunc.h" + Bool_t RooStats::RatioOfProfiledLikelihoodsTestStat::fgAlwaysReuseNll = kTRUE ; + +void RooStats::RatioOfProfiledLikelihoodsTestStat::SetAlwaysReuseNLL(Bool_t flag) { fgAlwaysReuseNll = flag ; } + + //__________________________________________ +Double_t RooStats::RatioOfProfiledLikelihoodsTestStat::ProfiledLikelihood(RooAbsData& data, RooArgSet& poi, RooAbsPdf& pdf) { + // returns -logL(poi, conditonal MLE of nuisance params) + // subtract off the global MLE or not depending on the option + // It is the numerator or the denominator of the ratio (depending on the pdf) + //L.M. : not sure why this method is needed now + + int type = (fSubtractMLE) ? 0 : 2; + + // null + if ( &pdf == fNullProfile.GetPdf() ) + return fNullProfile.EvaluateProfileLikelihood(type, data, poi); + else if (&pdf == fAltProfile.GetPdf() ) + return fAltProfile.EvaluateProfileLikelihood(type, data, poi); + + oocoutE((TObject*)NULL,InputArguments) << "RatioOfProfiledLikelihoods::ProfileLikelihood - invalid pdf used for computing the profiled likelihood - return NaN" + << std::endl; + + return TMath::QuietNaN(); + +} + +//__________________________________________ +Double_t RooStats::RatioOfProfiledLikelihoodsTestStat::Evaluate(RooAbsData& data, RooArgSet& nullParamsOfInterest) { + // evaluate the ratio of profile likelihood + + + int type = (fSubtractMLE) ? 0 : 2; + + // null + double nullNLL = fNullProfile.EvaluateProfileLikelihood(type, data, nullParamsOfInterest); + const RooArgSet *nullset = fNullProfile.GetDetailedOutput(); + + // alt + double altNLL = fAltProfile.EvaluateProfileLikelihood(type, data, *fAltPOI); + const RooArgSet *altset = fAltProfile.GetDetailedOutput(); + + if (fDetailedOutput != NULL) { + delete fDetailedOutput; + fDetailedOutput = NULL; + } + if (fDetailedOutputEnabled) { + fDetailedOutput = new RooArgSet(); + RooRealVar* var(0); + for(TIterator *it = nullset->createIterator();(var = dynamic_cast<RooRealVar*>(it->Next()));) { + RooRealVar* cloneVar = new RooRealVar(TString::Format("nullprof_%s", var->GetName()), + TString::Format("%s for null", var->GetTitle()), var->getVal()); + fDetailedOutput->addOwned(*cloneVar); + } + for(TIterator *it = altset->createIterator();(var = dynamic_cast<RooRealVar*>(it->Next()));) { + RooRealVar* cloneVar = new RooRealVar(TString::Format("altprof_%s", var->GetName()), + TString::Format("%s for null", var->GetTitle()), var->getVal()); + fDetailedOutput->addOwned(*cloneVar); + } + } + +/* +// set variables back to where they were +nullParamsOfInterest = *saveNullPOI; +*allVars = *saveAll; +delete saveAll; +delete allVars; +*/ + + return nullNLL -altNLL; +} diff --git a/roofit/roostats/src/RooStatsUtils.cxx b/roofit/roostats/src/RooStatsUtils.cxx index aea18f6d1f0e0..6fe5d011c4ebf 100644 --- a/roofit/roostats/src/RooStatsUtils.cxx +++ b/roofit/roostats/src/RooStatsUtils.cxx @@ -22,36 +22,47 @@ NamespaceImp(RooStats) #include "TTree.h" +#include "RooUniform.h" #include "RooProdPdf.h" +#include "RooExtendPdf.h" #include "RooSimultaneous.h" #include "RooStats/ModelConfig.h" #include "RooStats/RooStatsUtils.h" #include <typeinfo> +using namespace std; + // this file is only for the documentation of RooStats namespace namespace RooStats { - - - void FactorizePdf(const RooArgSet &observables, RooAbsPdf &pdf, RooArgList &obsTerms, RooArgList &constraints) { + void FactorizePdf(const RooArgSet &observables, RooAbsPdf &pdf, RooArgList &obsTerms, RooArgList &constraints) { // utility function to factorize constraint terms from a pdf // (from G. Petrucciani) - const std::type_info & id = typeid(pdf); - if (id == typeid(RooProdPdf)) { - RooProdPdf *prod = dynamic_cast<RooProdPdf *>(&pdf); - RooArgList list(prod->pdfList()); - for (int i = 0, n = list.getSize(); i < n; ++i) { - RooAbsPdf *pdfi = (RooAbsPdf *) list.at(i); + const std::type_info & id = typeid(pdf); + if (id == typeid(RooProdPdf)) { + RooProdPdf *prod = dynamic_cast<RooProdPdf *>(&pdf); + RooArgList list(prod->pdfList()); + for (int i = 0, n = list.getSize(); i < n; ++i) { + RooAbsPdf *pdfi = (RooAbsPdf *) list.at(i); FactorizePdf(observables, *pdfi, obsTerms, constraints); } - } else if (id == typeid(RooSimultaneous) ) { //|| id == typeid(RooSimultaneousOpt)) { + } else if (id == typeid(RooExtendPdf)) { + TIterator *iter = pdf.serverIterator(); + // extract underlying pdf which is extended; first server is the pdf; second server is the number of events variable + RooAbsPdf *updf = dynamic_cast<RooAbsPdf *>(iter->Next()); + assert(updf != 0); + delete iter; + FactorizePdf(observables, *updf, obsTerms, constraints); + } else if (id == typeid(RooSimultaneous)) { //|| id == typeid(RooSimultaneousOpt)) { RooSimultaneous *sim = dynamic_cast<RooSimultaneous *>(&pdf); assert(sim != 0); - RooAbsCategoryLValue *cat = (RooAbsCategoryLValue *) sim->indexCat().Clone(); + RooAbsCategoryLValue *cat = (RooAbsCategoryLValue *) sim->indexCat().clone(sim->indexCat().GetName()); for (int ic = 0, nc = cat->numBins((const char *)0); ic < nc; ++ic) { cat->setBin(ic); - FactorizePdf(observables, *sim->getPdf(cat->getLabel()), obsTerms, constraints); + RooAbsPdf* catPdf = sim->getPdf(cat->getLabel()); + // it is possible that a pdf is not defined for every category + if (catPdf != 0) FactorizePdf(observables, *catPdf, obsTerms, constraints); } delete cat; } else if (pdf.dependsOn(observables)) { @@ -66,7 +77,7 @@ namespace RooStats { // utility function to factorize constraint terms from a pdf // (from G. Petrucciani) if (!model.GetObservables() ) { - oocoutE((TObject*)0,InputArguments) << "MakeNuisancePdf - invalid input model: missing observables " << endl; + oocoutE((TObject*)0,InputArguments) << "RooStatsUtils::FactorizePdf - invalid input model: missing observables" << endl; return; } return FactorizePdf(*model.GetObservables(), pdf, obsTerms, constraints); @@ -77,18 +88,105 @@ namespace RooStats { // make a nuisance pdf by factorizing out all constraint terms in a common pdf RooArgList obsTerms, constraints; FactorizePdf(observables, pdf, obsTerms, constraints); + if(constraints.getSize() == 0) { + oocoutW((TObject *)0, Eval) << "RooStatsUtils::MakeNuisancePdf - no constraints found on nuisance parameters in the input model" << endl; + return 0; + } else if(constraints.getSize() == 1) { + return dynamic_cast<RooAbsPdf *>(constraints.first()->clone(name)); + } return new RooProdPdf(name,"", constraints); } RooAbsPdf * MakeNuisancePdf(const RooStats::ModelConfig &model, const char *name) { // make a nuisance pdf by factorizing out all constraint terms in a common pdf if (!model.GetPdf() || !model.GetObservables() ) { - oocoutE((TObject*)0,InputArguments) << "MakeNuisancePdf - invalid input model " << endl; + oocoutE((TObject*)0, InputArguments) << "RooStatsUtils::MakeNuisancePdf - invalid input model: missing pdf and/or observables" << endl; return 0; } return MakeNuisancePdf(*model.GetPdf(), *model.GetObservables(), name); } + RooAbsPdf * StripConstraints(RooAbsPdf &pdf, const RooArgSet &observables) { + const std::type_info & id = typeid(pdf); + + if (id == typeid(RooProdPdf)) { + + RooProdPdf *prod = dynamic_cast<RooProdPdf *>(&pdf); + RooArgList list(prod->pdfList()); RooArgList newList; + + for (int i = 0, n = list.getSize(); i < n; ++i) { + RooAbsPdf *pdfi = (RooAbsPdf *) list.at(i); + RooAbsPdf *newPdfi = StripConstraints(*pdfi, observables); + if(newPdfi != NULL) newList.add(*newPdfi); + } + + if(newList.getSize() == 0) return NULL; // only constraints in product + // return single component (no longer a product) + else if(newList.getSize() == 1) return dynamic_cast<RooAbsPdf *>(newList.at(0)->clone(TString::Format("%s_unconstrained", + newList.at(0)->GetName()))); + else return new RooProdPdf(TString::Format("%s_unconstrained", prod->GetName()).Data(), + TString::Format("%s without constraints", prod->GetTitle()).Data(), newList); + + } else if (id == typeid(RooExtendPdf)) { + + TIterator *iter = pdf.serverIterator(); + // extract underlying pdf which is extended; first server is the pdf; second server is the number of events variable + RooAbsPdf *uPdf = dynamic_cast<RooAbsPdf *>(iter->Next()); + RooAbsReal *extended_term = dynamic_cast<RooAbsReal *>(iter->Next()); + assert(uPdf != NULL); assert(extended_term != NULL); assert(iter->Next() == NULL); + delete iter; + + RooAbsPdf *newUPdf = StripConstraints(*uPdf, observables); + if(newUPdf == NULL) return NULL; // only constraints in underlying pdf + else return new RooExtendPdf(TString::Format("%s_unconstrained", pdf.GetName()).Data(), + TString::Format("%s without constraints", pdf.GetTitle()).Data(), *newUPdf, *extended_term); + + } else if (id == typeid(RooSimultaneous)) { //|| id == typeid(RooSimultaneousOpt)) { + + RooSimultaneous *sim = dynamic_cast<RooSimultaneous *>(&pdf); assert(sim != NULL); + RooAbsCategoryLValue *cat = (RooAbsCategoryLValue *) sim->indexCat().Clone(); assert(cat != NULL); + RooArgList pdfList; + + for (int ic = 0, nc = cat->numBins((const char *)NULL); ic < nc; ++ic) { + cat->setBin(ic); + RooAbsPdf* catPdf = sim->getPdf(cat->getLabel()); + RooAbsPdf* newPdf = NULL; + // it is possible that a pdf is not defined for every category + if (catPdf != NULL) newPdf = StripConstraints(*catPdf, observables); + if (newPdf == NULL) { delete cat; return NULL; } // all channels must have observables + pdfList.add(*newPdf); + } + + return new RooSimultaneous(TString::Format("%s_unconstrained", sim->GetName()).Data(), + TString::Format("%s without constraints", sim->GetTitle()).Data(), pdfList, *cat); + + } else if (pdf.dependsOn(observables)) { + return (RooAbsPdf *) pdf.clone(TString::Format("%s_unconstrained", pdf.GetName()).Data()); + } + + return NULL; // just a constraint term + } + + RooAbsPdf * MakeUnconstrainedPdf(RooAbsPdf &pdf, const RooArgSet &observables, const char *name) { + // make a clone pdf without all constraint terms in a common pdf + RooAbsPdf * unconstrainedPdf = StripConstraints(pdf, observables); + if(!unconstrainedPdf) { + oocoutE((TObject *)NULL, InputArguments) << "RooStats::MakeUnconstrainedPdf - invalid observable list passed (observables not found in original pdf) or invalid pdf passed (without observables)" << endl; + return NULL; + } + if(name != NULL) unconstrainedPdf->SetName(name); + return unconstrainedPdf; + } + + RooAbsPdf * MakeUnconstrainedPdf(const RooStats::ModelConfig &model, const char *name) { + // make a clone pdf without all constraint terms in a common pdf + if(!model.GetPdf() || !model.GetObservables()) { + oocoutE((TObject *)NULL, InputArguments) << "RooStatsUtils::MakeUnconstrainedPdf - invalid input model: missing pdf and/or observables" << endl; + return NULL; + } + return MakeUnconstrainedPdf(*model.GetPdf(), *model.GetObservables(), name); + } + // Helper class for GetAsTTree class BranchStore { public: diff --git a/roofit/roostats/src/SPlot.cxx b/roofit/roostats/src/SPlot.cxx index 6a149f6e78095..c297e730bdb36 100644 --- a/roofit/roostats/src/SPlot.cxx +++ b/roofit/roostats/src/SPlot.cxx @@ -65,6 +65,7 @@ ClassImp(RooStats::SPlot) ; using namespace RooStats; +using namespace std; @@ -440,6 +441,8 @@ void SPlot::AddSWeight( RooAbsPdf* pdf, const RooArgList &yieldsTmp, // and all others to 0. Evaluate the pdf for each event // and store the values. + RooArgSet * pdfvars = pdf->getVariables(); + for (Int_t ievt = 0; ievt <numevents; ievt++) { // if (ievt % 100 == 0) @@ -448,7 +451,7 @@ void SPlot::AddSWeight( RooAbsPdf* pdf, const RooArgList &yieldsTmp, //FIX THIS PART, EVALUATION PROGRESS!! - RooStats::SetParameters(fSData->get(ievt), pdf->getVariables()); + RooStats::SetParameters(fSData->get(ievt), pdfvars); // RooArgSet row(*fSData->get(ievt)); @@ -479,6 +482,7 @@ void SPlot::AddSWeight( RooAbsPdf* pdf, const RooArgList &yieldsTmp, yieldvars[k]->setVal( 0 ) ; } } + delete pdfvars; // check that the likelihood normalization is fine std::vector<Double_t> norm(nspec,0) ; diff --git a/roofit/roostats/src/SamplingDistPlot.cxx b/roofit/roostats/src/SamplingDistPlot.cxx index e3a5140a49e43..36b053ecc5b98 100644 --- a/roofit/roostats/src/SamplingDistPlot.cxx +++ b/roofit/roostats/src/SamplingDistPlot.cxx @@ -105,8 +105,22 @@ Double_t SamplingDistPlot::AddSamplingDistribution(const SamplingDistribution *s TString options(drawOptions); options.ToUpper(); - Double_t xmin = *(std::min_element(fSamplingDistr.begin(), fSamplingDistr.end())); - Double_t xmax = *(std::max_element(fSamplingDistr.begin(), fSamplingDistr.end())); + Double_t xmin(TMath::Infinity()), xmax(-TMath::Infinity()); + // remove cases where xmin and xmax are +/- inf + for( unsigned int i=0; i < fSamplingDistr.size(); i++ ) { + if( fSamplingDistr[i] < xmin && fSamplingDistr[i] != -TMath::Infinity() ) { + xmin = fSamplingDistr[i]; + } + if( fSamplingDistr[i] > xmax && fSamplingDistr[i] != TMath::Infinity() ) { + xmax = fSamplingDistr[i]; + } + } + if( xmin >= xmax ) { + coutW(Plotting) << "Could not determine xmin and xmax of sampling distribution that was given to plot." << endl; + xmin = -1.0; + xmax = 1.0; + } + // add 1.5 bins left and right assert(fBins > 1); @@ -263,7 +277,7 @@ void SamplingDistPlot::Draw(Option_t * /*options */) { ApplyDefaultStyle(); - Float_t theMin(0.), theMax(0.), theYMin(NaN), theYMax(0.); + Double_t theMin(0.), theMax(0.), theYMin(NaN), theYMax(0.); GetAbsoluteInterval(theMin, theMax, theYMax); if( !IsNaN(fXMin) ) theMin = fXMin; if( !IsNaN(fXMax) ) theMax = fXMax; @@ -362,11 +376,11 @@ void SamplingDistPlot::ApplyDefaultStyle(void) { } //_____________________________________________________________________________ -void SamplingDistPlot::GetAbsoluteInterval(Float_t &theMin, Float_t &theMax, Float_t &theYMax) const +void SamplingDistPlot::GetAbsoluteInterval(Double_t &theMin, Double_t &theMax, Double_t &theYMax) const { - Float_t tmpmin = 999.; - Float_t tmpmax = -999.; - Float_t tmpYmax = -999.; + Double_t tmpmin = TMath::Infinity(); + Double_t tmpmax = -TMath::Infinity(); + Double_t tmpYmax = -TMath::Infinity(); fIterator->Reset(); diff --git a/roofit/roostats/src/SequentialProposal.cxx b/roofit/roostats/src/SequentialProposal.cxx index 34ed4f3fee9f0..439c8127dde40 100644 --- a/roofit/roostats/src/SequentialProposal.cxx +++ b/roofit/roostats/src/SequentialProposal.cxx @@ -17,6 +17,8 @@ #include <RooRandom.h> #include <RooStats/RooStatsUtils.h> +using namespace std; + ClassImp(RooStats::SequentialProposal) namespace RooStats { diff --git a/roofit/roostats/src/SimpleInterval.cxx b/roofit/roostats/src/SimpleInterval.cxx index 87d32dc4144c6..90d6cbdccb911 100644 --- a/roofit/roostats/src/SimpleInterval.cxx +++ b/roofit/roostats/src/SimpleInterval.cxx @@ -37,6 +37,8 @@ #include <string> +using namespace std; + ClassImp(RooStats::SimpleInterval) ; using namespace RooStats; @@ -49,6 +51,40 @@ SimpleInterval::SimpleInterval(const char* name) : // Default constructor } + +//____________________________________________________________________ +SimpleInterval::SimpleInterval(const SimpleInterval& other, const char* name) + : ConfInterval(name) + , fParameters(other.fParameters) + , fLowerLimit(other.fLowerLimit) + , fUpperLimit(other.fUpperLimit) + , fConfidenceLevel(other.fConfidenceLevel) +{ + //fParameters.add( other.fParameters ); +} + + +//____________________________________________________________________ +SimpleInterval& +SimpleInterval::operator=(const SimpleInterval& other) +{ + if (&other==this) { + return *this ; + } + + ConfInterval::operator = (other); + + //fParameters = other.fParameters; + fParameters.removeAll(); + fParameters.add(other.fParameters); + fLowerLimit = other.fLowerLimit; + fUpperLimit = other.fUpperLimit; + fConfidenceLevel = other.fConfidenceLevel; + + return *this ; +} + + //____________________________________________________________________ SimpleInterval::SimpleInterval(const char* name, const RooRealVar & var, Double_t lower, Double_t upper, Double_t cl) : ConfInterval(name), fParameters(var), fLowerLimit(lower), fUpperLimit(upper), fConfidenceLevel(cl) @@ -80,7 +116,7 @@ Bool_t SimpleInterval::IsInInterval(const RooArgSet ¶meterPoint) const if (point == 0) return false; - if ( point->getVal() > fUpperLimit || point->getVal() < fUpperLimit) + if ( point->getVal() > fUpperLimit || point->getVal() < fLowerLimit) return false; diff --git a/roofit/roostats/src/SimpleLikelihoodRatioTestStat.cxx b/roofit/roostats/src/SimpleLikelihoodRatioTestStat.cxx index 943f25fa644fa..f7978ae8f5dbc 100644 --- a/roofit/roostats/src/SimpleLikelihoodRatioTestStat.cxx +++ b/roofit/roostats/src/SimpleLikelihoodRatioTestStat.cxx @@ -1,4 +1,112 @@ +// @(#)root/roostats:$Id$ +// Author: Kyle Cranmer, Lorenzo Moneta, Gregory Schott, Wouter Verkerke +/************************************************************************* + * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ #include "RooStats/SimpleLikelihoodRatioTestStat.h" +#include "RooStats/RooStatsUtils.h" -Bool_t RooStats::SimpleLikelihoodRatioTestStat::fAlwaysReuseNll = kTRUE ; + +Bool_t RooStats::SimpleLikelihoodRatioTestStat::fgAlwaysReuseNll = kTRUE ; + +void RooStats::SimpleLikelihoodRatioTestStat::SetAlwaysReuseNLL(Bool_t flag) { fgAlwaysReuseNll = flag ; } + +Double_t RooStats::SimpleLikelihoodRatioTestStat::Evaluate(RooAbsData& data, RooArgSet& nullPOI) { + + if (fFirstEval && ParamsAreEqual()) { + oocoutW(fNullParameters,InputArguments) + << "Same RooArgSet used for null and alternate, so you must explicitly SetNullParameters and SetAlternateParameters or the likelihood ratio will always be 1." + << std::endl; + } + + // strip pdfs of constraints (which cancel out in the ratio) to avoid unnecessary computations and computational errors + if (fFirstEval) { + fNullPdf = RooStats::MakeUnconstrainedPdf(*fNullPdf, *fNullPdf->getObservables(data)); + fAltPdf = RooStats::MakeUnconstrainedPdf(*fAltPdf , *fAltPdf->getObservables(data) ); + } + + fFirstEval = false; + + RooFit::MsgLevel msglevel = RooMsgService::instance().globalKillBelow(); + RooMsgService::instance().setGlobalKillBelow(RooFit::FATAL); + + Bool_t reuse = (fReuseNll || fgAlwaysReuseNll) ; + + Bool_t created = kFALSE ; + if (!fNllNull) { + RooArgSet* allParams = fNullPdf->getParameters(data); + fNllNull = fNullPdf->createNLL(data, RooFit::CloneData(kFALSE),RooFit::Constrain(*allParams),RooFit::ConditionalObservables(fConditionalObs)); + delete allParams; + created = kTRUE ; + } + if (reuse && !created) { + fNllNull->setData(data, kFALSE) ; + } + + // make sure we set the variables attached to this nll + RooArgSet* attachedSet = fNllNull->getVariables(); + *attachedSet = *fNullParameters; + *attachedSet = nullPOI; + double nullNLL = fNllNull->getVal(); + + //std::cout << std::endl << "SLRTS: null params:" << std::endl; + //attachedSet->Print("v"); + + + if (!reuse) { + delete fNllNull ; fNllNull = NULL ; + } + delete attachedSet; + + created = kFALSE ; + if (!fNllAlt) { + RooArgSet* allParams = fAltPdf->getParameters(data); + fNllAlt = fAltPdf->createNLL(data, RooFit::CloneData(kFALSE),RooFit::Constrain(*allParams),RooFit::ConditionalObservables(fConditionalObs)); + delete allParams; + created = kTRUE ; + } + if (reuse && !created) { + fNllAlt->setData(data, kFALSE) ; + } + // make sure we set the variables attached to this nll + attachedSet = fNllAlt->getVariables(); + *attachedSet = *fAltParameters; + double altNLL = fNllAlt->getVal(); + + //std::cout << std::endl << "SLRTS: alt params:" << std::endl; + //attachedSet->Print("v"); + + +// std::cout << std::endl << "SLRTS null NLL: " << nullNLL << " alt NLL: " << altNLL << std::endl << std::endl; + + + if (!reuse) { + delete fNllAlt ; fNllAlt = NULL ; + } + delete attachedSet; + + + + // save this snapshot + if( fDetailedOutputEnabled ) { + if( !fDetailedOutput ) { + fDetailedOutput = new RooArgSet( *(new RooRealVar("nullNLL","null NLL",0)), "detailedOut_SLRTS" ); + fDetailedOutput->add( *(new RooRealVar("altNLL","alternate NLL",0)) ); + } + fDetailedOutput->setRealValue( "nullNLL", nullNLL ); + fDetailedOutput->setRealValue( "altNLL", altNLL ); + +// std::cout << std::endl << "STORING THIS AS DETAILED OUTPUT:" << std::endl; +// fDetailedOutput->Print("v"); +// std::cout << std::endl; + } + + + RooMsgService::instance().setGlobalKillBelow(msglevel); + return nullNLL - altNLL; +} diff --git a/roofit/roostats/src/ToyMCImportanceSampler.cxx b/roofit/roostats/src/ToyMCImportanceSampler.cxx index abc6efc63ab04..fafaaf594429f 100644 --- a/roofit/roostats/src/ToyMCImportanceSampler.cxx +++ b/roofit/roostats/src/ToyMCImportanceSampler.cxx @@ -16,8 +16,10 @@ #endif #include "RooCategory.h" +#include "TMath.h" using namespace RooFit; +using namespace std; ClassImp(RooStats::ToyMCImportanceSampler) @@ -74,13 +76,13 @@ RooDataSet* ToyMCImportanceSampler::GetSamplingDistributionsSingleWorker(RooArgS // apply strategy for how to distribute the #toys between the distributions if( fToysStrategy == EQUALTOYSPERDENSITY ) { // assuming alltoys = one null + N imp densities. And round up. - fNToys = ceil( double(allToys)/(fImportanceDensities.size()+1) ); + fNToys = TMath::CeilNint( double(allToys)/(fImportanceDensities.size()+1) ); }else if(fToysStrategy == EXPONENTIALTOYDISTRIBUTION ) { // for N densities, split the toys into (2^(N+1))-1 parts, and assign 2^0 parts to the first // density (which is the null), 2^1 to the second (first imp dens), etc, up to 2^N - fNToys = ceil( double(allToys) * pow( double(2) , i+1 ) / (pow( double(2), int(fImportanceDensities.size()+1) )-1) ); + fNToys = TMath::CeilNint( double(allToys) * pow( double(2) , i+1 ) / (pow( double(2), int(fImportanceDensities.size()+1) )-1) ); - int largestNToys = ceil( allToys * pow( double(2), int(fImportanceDensities.size()) ) / (pow( double(2), int(fImportanceDensities.size()+1) )-1) ); + int largestNToys = TMath::CeilNint( allToys * pow( double(2), int(fImportanceDensities.size()) ) / (pow( double(2), int(fImportanceDensities.size()+1) )-1) ); reweight.setVal( ((double)largestNToys) / fNToys ); } @@ -90,33 +92,32 @@ RooDataSet* ToyMCImportanceSampler::GetSamplingDistributionsSingleWorker(RooArgS RooDataSet* result = ToyMCSampler::GetSamplingDistributionsSingleWorker( paramPoint ); - // add label - densityLabel.setIndex( i ); - result->addColumn( densityLabel ); - result->addColumn( reweight ); + if (result->get()->getSize() > Int_t(fTestStatistics.size())) { + // add label + densityLabel.setIndex( i ); + result->addColumn( densityLabel ); + result->addColumn( reweight ); + } - RooArgSet columns( *result->get() ); - columns.add( *(new RooRealVar( "weight", "weight", 1.0 )) ); + if( !fullResult ) { + RooArgSet columns( *result->get() ); + RooRealVar weightVar ( "weight", "weight", 1.0 ); + columns.add( weightVar ); // cout << endl << endl << "Reweighted data columns: " << endl; // columns.Print("v"); // cout << endl; - RooDataSet* reweightedResult = new RooDataSet( "rewRes", "rewRes", columns, "weight" ); + fullResult = new RooDataSet( result->GetName(), result->GetTitle(), columns, "weight" ); + } + for( int j=0; j < result->numEntries(); j++ ) { // cout << "entry: " << j << endl; // result->get(j)->Print(); // cout << "weight: " << result->weight() << endl; // cout << "reweight: " << reweight.getVal() << endl; const RooArgSet* row = result->get(j); - reweightedResult->add( *row, result->weight()*reweight.getVal() ); + fullResult->add( *row, result->weight()*reweight.getVal() ); } delete result; - - if( !fullResult ) { - fullResult = reweightedResult; - }else{ - fullResult->append( *reweightedResult ); - delete reweightedResult; - } } // restore #toys @@ -152,7 +153,7 @@ RooAbsData* ToyMCImportanceSampler::GenerateToyData( // do not do anything if the given parameter point if fNullSnapshots[0] // ... which is the most common case if( fNullSnapshots[0] != ¶mPoint ) { - ooccoutI((TObject*)NULL,InputArguments) << "Using given parameter point. Replaces snapshot for the only null currently defined." << endl; + ooccoutD((TObject*)NULL,InputArguments) << "Using given parameter point. Replaces snapshot for the only null currently defined." << endl; if(fNullSnapshots[0]) delete fNullSnapshots[0]; fNullSnapshots.clear(); fNullSnapshots.push_back( (RooArgSet*)paramPoint.snapshot() ); @@ -234,8 +235,8 @@ RooAbsData* ToyMCImportanceSampler::GenerateToyData( // test statistics. - oocoutI((TObject*)0,InputArguments) << endl; - oocoutI((TObject*)0,InputArguments) << "GenerateToyDataImportanceSampling" << endl; + ooccoutD((TObject*)0,InputArguments) << endl; + ooccoutD((TObject*)0,InputArguments) << "GenerateToyDataImportanceSampling" << endl; if(!fObservables) { ooccoutE((TObject*)NULL,InputArguments) << "Observables not set." << endl; @@ -243,7 +244,7 @@ RooAbsData* ToyMCImportanceSampler::GenerateToyData( } if( fNullDensities.size() == 0 ) { - oocoutE((TObject*)NULL,InputArguments) << "ToyMCImportanceSampler: Need to specify the null density explicitely." << endl; + oocoutE((TObject*)NULL,InputArguments) << "ToyMCImportanceSampler: Need to specify the null density explicitly." << endl; return NULL; } @@ -345,7 +346,7 @@ RooAbsData* ToyMCImportanceSampler::GenerateToyData( // Importance Sampling: adjust weight // Sources: Alex Read, presentation by Michael Woodroofe - oocoutI((TObject*)0,InputArguments) << "About to create/calculate all nullNLLs." << endl; + ooccoutD((TObject*)0,InputArguments) << "About to create/calculate all nullNLLs." << endl; for( unsigned int i=0; i < fNullDensities.size(); i++ ) { //oocoutI((TObject*)0,InputArguments) << "Setting variables to nullSnapshot["<<i<<"]"<<endl; //fNullSnapshots[i]->Print("v"); @@ -353,7 +354,8 @@ RooAbsData* ToyMCImportanceSampler::GenerateToyData( *allVars = *fNullSnapshots[i]; if( !fNullNLLs[i] ) { RooArgSet* allParams = fNullDensities[i]->getParameters(*data); - fNullNLLs[i] = fNullDensities[i]->createNLL(*data, RooFit::CloneData(kFALSE), RooFit::Constrain(*allParams)); + fNullNLLs[i] = fNullDensities[i]->createNLL(*data, RooFit::CloneData(kFALSE), RooFit::Constrain(*allParams), + RooFit::ConditionalObservables(fConditionalObs)); delete allParams; }else{ fNullNLLs[i]->setData( *data, kFALSE ); @@ -365,7 +367,7 @@ RooAbsData* ToyMCImportanceSampler::GenerateToyData( // for each null: find minNLLVal of null and all imp densities - oocoutI((TObject*)0,InputArguments) << "About to find the minimum NLLs." << endl; + ooccoutD((TObject*)0,InputArguments) << "About to find the minimum NLLs." << endl; vector<double> minNLLVals; for( unsigned int i=0; i < nullNLLVals.size(); i++ ) minNLLVals.push_back( nullNLLVals[i] ); @@ -376,7 +378,8 @@ RooAbsData* ToyMCImportanceSampler::GenerateToyData( if( fImportanceSnapshots[i] ) *allVars = *fImportanceSnapshots[i]; if( !fImpNLLs[i] ) { RooArgSet* allParams = fImportanceDensities[i]->getParameters(*data); - fImpNLLs[i] = fImportanceDensities[i]->createNLL(*data, RooFit::CloneData(kFALSE), RooFit::Constrain(*allParams)); + fImpNLLs[i] = fImportanceDensities[i]->createNLL(*data, RooFit::CloneData(kFALSE), RooFit::Constrain(*allParams), + RooFit::ConditionalObservables(fConditionalObs)); delete allParams; }else{ fImpNLLs[i]->setData( *data, kFALSE ); @@ -387,13 +390,13 @@ RooAbsData* ToyMCImportanceSampler::GenerateToyData( for( unsigned int j=0; j < nullNLLVals.size(); j++ ) { if( impNLLVals[i] < minNLLVals[j] ) minNLLVals[j] = impNLLVals[i]; - oocoutI((TObject*)0,InputArguments) << "minNLLVals["<<j<<"]: " << minNLLVals[j] << " nullNLLVals["<<j<<"]: " << nullNLLVals[j] << " impNLLVals["<<i<<"]: " << impNLLVals[i] << endl; + ooccoutD((TObject*)0,InputArguments) << "minNLLVals["<<j<<"]: " << minNLLVals[j] << " nullNLLVals["<<j<<"]: " << nullNLLVals[j] << " impNLLVals["<<i<<"]: " << impNLLVals[i] << endl; } } // veto toys: this is a sort of "overlap removal" of the various distributions // if not vetoed: apply weight - oocoutI((TObject*)0,InputArguments) << "About to apply vetos and calculate weights." << endl; + ooccoutD((TObject*)0,InputArguments) << "About to apply vetos and calculate weights." << endl; for( unsigned int j=0; j < nullNLLVals.size(); j++ ) { if ( fApplyVeto && fGenerateFromNull && minNLLVals[j] != nullNLLVals[j] ) weights[j] = 0.0; else if( fApplyVeto && !fGenerateFromNull && minNLLVals[j] != impNLLVals[fIndexGenDensity] ) weights[j] = 0.0; @@ -404,7 +407,7 @@ RooAbsData* ToyMCImportanceSampler::GenerateToyData( weights[j] *= exp(minNLLVals[j] - nullNLLVals[j]); } - oocoutI((TObject*)0,InputArguments) << "weights["<<j<<"]: " << weights[j] << endl; + ooccoutD((TObject*)0,InputArguments) << "weights["<<j<<"]: " << weights[j] << endl; } @@ -430,7 +433,7 @@ int ToyMCImportanceSampler::CreateImpDensitiesForOnePOIAdaptively( RooAbsPdf& pd // check whether error is trustworthy if( poi.getError() > 0.01 && poi.getError() < 5.0 ) { - n = poi.getVal() / (2.*nStdDevOverlap*poi.getError()) + 1; // round up + n = TMath::CeilNint( poi.getVal() / (2.*nStdDevOverlap*poi.getError()) ); // round up oocoutI((TObject*)0,InputArguments) << "Using fitFavoredMu and error to set the number of imp points" << endl; oocoutI((TObject*)0,InputArguments) << "muhat: " << poi.getVal() << " optimize for distance: " << 2.*nStdDevOverlap*poi.getError() << endl; oocoutI((TObject*)0,InputArguments) << "n = " << n << endl; diff --git a/roofit/roostats/src/ToyMCSampler.cxx b/roofit/roostats/src/ToyMCSampler.cxx index d415b719ed10f..7389126ca872b 100644 --- a/roofit/roostats/src/ToyMCSampler.cxx +++ b/roofit/roostats/src/ToyMCSampler.cxx @@ -31,11 +31,13 @@ #include "RooStats/ToyMCStudy.h" #include "RooStats/DetailedOutputAggregator.h" #include "RooSimultaneous.h" +#include "RooCategory.h" #include "TMath.h" using namespace RooFit; +using namespace std; ClassImp(RooStats::ToyMCSampler) @@ -124,6 +126,7 @@ void NuisanceParametersSampler::Refresh() { Bool_t ToyMCSampler::fgAlwaysUseMultiGen = kFALSE ; +void ToyMCSampler::SetAlwaysUseMultiGen(Bool_t flag) { fgAlwaysUseMultiGen = flag ; } @@ -238,6 +241,41 @@ Bool_t ToyMCSampler::CheckConfig(void) { } +RooArgList* ToyMCSampler::EvaluateAllTestStatistics(RooAbsData& data, const RooArgSet& poi) { + // Evaluate all test statistics, returning result and any detailed output. + // PDF parameter values are saved in case they are modified by + // TestStatistic::Evaluate (eg. SimpleLikelihoodRatioTestStat). + DetailedOutputAggregator detOutAgg; + const RooArgList* allTS = EvaluateAllTestStatistics(data, poi, detOutAgg); + if (!allTS) return 0; + // no need to delete allTS, it is deleted in destructor of detOutAgg + return dynamic_cast<RooArgList*>(allTS->snapshot()); +} + + +const RooArgList* ToyMCSampler::EvaluateAllTestStatistics(RooAbsData& data, const RooArgSet& poi, DetailedOutputAggregator& detOutAgg) { + RooArgSet *allVars = fPdf ? fPdf->getVariables() : 0; + RooArgSet *saveAll = allVars ? dynamic_cast<RooArgSet*>(allVars->snapshot()) : 0; + for( unsigned int i = 0; i < fTestStatistics.size(); i++ ) { + if( fTestStatistics[i] == NULL ) continue; + TString name( TString::Format("%s_TS%u", fSamplingDistName.c_str(), i) ); + RooArgSet* parForTS = dynamic_cast<RooArgSet*>(poi.snapshot()); + RooRealVar ts( name, fTestStatistics[i]->GetVarName(), fTestStatistics[i]->Evaluate( data, *parForTS ) ); + RooArgList tset(ts); + detOutAgg.AppendArgSet(&tset); + delete parForTS; + if (const RooArgSet* detOut = fTestStatistics[i]->GetDetailedOutput()) { + name.Append("_"); + detOutAgg.AppendArgSet(detOut, name); + } + if (saveAll) *allVars = *saveAll; // restore values, perhaps modified by fTestStatistics[i]->Evaluate() + } + delete saveAll; + delete allVars; + return detOutAgg.GetAsArgList(); +} + + SamplingDistribution* ToyMCSampler::GetSamplingDistribution(RooArgSet& paramPointIn) { if(fTestStatistics.size() > 1) { oocoutW((TObject*)NULL, InputArguments) << "Multiple test statistics defined, but only one distribution will be returned." << endl; @@ -252,7 +290,9 @@ SamplingDistribution* ToyMCSampler::GetSamplingDistribution(RooArgSet& paramPoin return NULL; } - return new SamplingDistribution( r->GetName(), r->GetTitle(), *r ); + SamplingDistribution* samp = new SamplingDistribution( r->GetName(), r->GetTitle(), *r ); + delete r; + return samp; } @@ -307,6 +347,12 @@ RooDataSet* ToyMCSampler::GetSamplingDistributionsSingleWorker(RooArgSet& paramP // be used by ToyMCStudy on the workers (ie. when you explicitly want // a serial run although ProofConfig is present). + // Make sure the cache is clear. It is important to clear it hear, because + // the cache might be invalid even when just the firstPOI was changed, for which + // no accessor has to be called. (Fixes a bug when ToyMCSampler is + // used with the Neyman Construction) + ClearCache(); + CheckConfig(); // important to cache the paramPoint b/c test statistic might @@ -318,15 +364,6 @@ RooDataSet* ToyMCSampler::GetSamplingDistributionsSingleWorker(RooArgSet& paramP DetailedOutputAggregator detOutAgg; - - vector<TString> namesOfTSColumns; - RooArgSet* allVarsToBeSaved = new RooArgSet("tsValues"); - for( unsigned int i=0; i < fTestStatistics.size(); i++ ) { - TString name( TString::Format("%s_TS%d", fSamplingDistName.c_str(), i) ); - namesOfTSColumns.push_back( name ); - allVarsToBeSaved->addOwned( *new RooRealVar(name, fTestStatistics[i]->GetVarName(), -1) ); - } - // counts the number of toys in the limits set for adaptive sampling // (taking weights into account; always on first test statistic) Double_t toysInTails = 0.0; @@ -350,31 +387,17 @@ RooDataSet* ToyMCSampler::GetSamplingDistributionsSingleWorker(RooArgSet& paramP // set variables to requested parameter point *allVars = *saveAll; // important for example for SimpleLikelihoodRatioTestStat - *allVars = *fParametersForTestStat; RooAbsData* toydata = GenerateToyData(*paramPoint, weight); - RooArgSet* saveVarsWithGlobObsSet = (RooArgSet*)allVars->snapshot(); - detOutAgg.AppendArgSet( fGlobalObservables, "globObs_" ); - - // evaluate all test statistics - for( unsigned int tsi = 0; tsi < fTestStatistics.size(); tsi++ ) { - *allVars = *saveVarsWithGlobObsSet; - *allVars = *fParametersForTestStat; - - // evaluate test statistic; only depends on null POI - RooArgSet* parForTS = (RooArgSet*)fParametersForTestStat->snapshot(); - Double_t value = fTestStatistics[tsi]->Evaluate(*toydata, *parForTS); - delete parForTS; - allVarsToBeSaved->setRealValue( namesOfTSColumns[tsi], value ); - - // get detailed output, construct name in dataset, store - const RooArgSet *ndetout = fTestStatistics[tsi]->GetDetailedOutput(); - if (ndetout != NULL) - detOutAgg.AppendArgSet(ndetout, TString(namesOfTSColumns[tsi]).Append("_")); - - if(valueFirst < 0.0) { valueFirst = value; } - } - delete saveVarsWithGlobObsSet; + + *allVars = *fParametersForTestStat; + + const RooArgList* allTS = EvaluateAllTestStatistics(*toydata, *fParametersForTestStat, detOutAgg); + if (allTS->getSize() > Int_t(fTestStatistics.size())) + detOutAgg.AppendArgSet( fGlobalObservables, "globObs_" ); + if (RooRealVar* firstTS = dynamic_cast<RooRealVar*>(allTS->first())) + valueFirst = firstTS->getVal(); + delete toydata; // check for nan @@ -383,7 +406,6 @@ RooDataSet* ToyMCSampler::GetSamplingDistributionsSingleWorker(RooArgSet& paramP continue; } - detOutAgg.AppendArgSet(allVarsToBeSaved); detOutAgg.CommitSet(weight); // adaptive sampling checks @@ -393,8 +415,6 @@ RooDataSet* ToyMCSampler::GetSamplingDistributionsSingleWorker(RooArgSet& paramP } } - delete allVarsToBeSaved; - // clean up *allVars = *saveAll; delete saveAll; @@ -410,29 +430,32 @@ void ToyMCSampler::GenerateGlobalObservables(RooAbsPdf& pdf) const { ooccoutE((TObject*)NULL,InputArguments) << "Global Observables not set." << endl; return; } + + + if (fUseMultiGen || fgAlwaysUseMultiGen) { - - // generate one set of global observables and assign it - // has problem for sim pdfs - RooSimultaneous* simPdf = dynamic_cast<RooSimultaneous*>( &pdf ); - if (!simPdf) { - RooDataSet *one = pdf.generate(*fGlobalObservables, 1); - - const RooArgSet *values = one->get(); - if (!_allVars) { - _allVars = pdf.getVariables(); - } - *_allVars = *values; - delete one; - - } else { - - if (_pdfList.size() == 0) { - TIterator* citer = simPdf->indexCat().typeIterator(); - RooCatType* tt = NULL; - while ((tt = (RooCatType*) citer->Next())) { - RooAbsPdf* pdftmp = simPdf->getPdf(tt->GetName()); - if (pdftmp) { + // generate one set of global observables and assign it + // has problem for sim pdfs + RooSimultaneous* simPdf = dynamic_cast<RooSimultaneous*>( &pdf ); + if (!simPdf) { + RooDataSet *one = pdf.generate(*fGlobalObservables, 1); + + const RooArgSet *values = one->get(0); + if (!_allVars) { + _allVars = pdf.getVariables(); + } + *_allVars = *values; + delete one; + + } else { + + if (_pdfList.size() == 0) { + RooCategory& channelCat = (RooCategory&)simPdf->indexCat(); + int nCat = channelCat.numTypes(); + for (int i=0; i < nCat; ++i){ + channelCat.setIndex(i); + RooAbsPdf* pdftmp = simPdf->getPdf(channelCat.getLabel()); + assert(pdftmp); RooArgSet* globtmp = pdftmp->getObservables(*fGlobalObservables); RooAbsPdf::GenSpec* gs = pdftmp->prepareMultiGen(*globtmp, NumEvents(1)); _pdfList.push_back(pdftmp); @@ -440,16 +463,28 @@ void ToyMCSampler::GenerateGlobalObservables(RooAbsPdf& pdf) const { _gsList.push_back(gs); } } + + list<RooArgSet*>::iterator oiter = _obsList.begin(); + list<RooAbsPdf::GenSpec*>::iterator giter = _gsList.begin(); + for (list<RooAbsPdf*>::iterator iter = _pdfList.begin(); iter != _pdfList.end(); ++iter, ++giter, ++oiter) { + //RooDataSet* tmp = (*iter)->generate(**oiter,1) ; + RooDataSet* tmp = (*iter)->generate(**giter); + **oiter = *tmp->get(0); + delete tmp; + } } - list<RooArgSet*>::iterator oiter = _obsList.begin(); - list<RooAbsPdf::GenSpec*>::iterator giter = _gsList.begin(); - for (list<RooAbsPdf*>::iterator iter = _pdfList.begin(); iter != _pdfList.end(); ++iter, ++giter, ++oiter) { - //RooDataSet* tmp = (*iter)->generate(**oiter,1) ; - RooDataSet* tmp = (*iter)->generate(**giter); - **oiter = *tmp->get(0); - delete tmp; - } + + } else { + + // not using multigen for global observables + RooDataSet* one = pdf.generateSimGlobal( *fGlobalObservables, 1 ); + const RooArgSet *values = one->get(0); + RooArgSet* allVars = pdf.getVariables(); + *allVars = *values; + delete allVars; + delete one; + } } @@ -471,9 +506,11 @@ RooAbsData* ToyMCSampler::GenerateToyData(RooArgSet& paramPoint, double& weight, // create nuisance parameter points - if(!fNuisanceParametersSampler && fPriorNuisance && fNuisancePars) + if(!fNuisanceParametersSampler && fPriorNuisance && fNuisancePars) { fNuisanceParametersSampler = new NuisanceParametersSampler(fPriorNuisance, fNuisancePars, fNToys, fExpectedNuisancePar); - + if ((fUseMultiGen || fgAlwaysUseMultiGen) && fNuisanceParametersSampler ) + oocoutI((TObject*)NULL,InputArguments) << "Cannot use multigen when nuisance parameters vary for every toy" << endl; + } // generate global observables RooArgSet observables(*fObservables); @@ -500,6 +537,8 @@ RooAbsData* ToyMCSampler::GenerateToyData(RooArgSet& paramPoint, double& weight, // get nuisance parameter point and weight fNuisanceParametersSampler->NextPoint(allVarsMinusParamPoint, weight); + + }else{ weight = 1.0; } @@ -533,6 +572,9 @@ RooAbsData* ToyMCSampler::Generate(RooAbsPdf &pdf, RooArgSet &observables, const int events = forceEvents; if(events == 0) events = fNEvents; + // cannot use multigen when the nuisance parameters change for every toy + bool useMultiGen = (fUseMultiGen || fgAlwaysUseMultiGen) && !fNuisanceParametersSampler; + if(events == 0) { if( pdf.canBeExtended() && pdf.expectedEvents(observables) > 0) { if(fGenerateBinned) { @@ -540,7 +582,7 @@ RooAbsData* ToyMCSampler::Generate(RooAbsPdf &pdf, RooArgSet &observables, const else data = pdf.generate(observables, AllBinned(), Extended()); }else{ if(protoData) { - if (fUseMultiGen || fgAlwaysUseMultiGen) { + if (useMultiGen) { if (!_gs2) { _gs2 = pdf.prepareMultiGen(observables, Extended(), AutoBinned(fGenerateAutoBinned), GenBinned(fGenerateBinnedTag), ProtoData(*protoData, true, true)) ; } data = pdf.generate(*_gs2) ; } else { @@ -548,7 +590,7 @@ RooAbsData* ToyMCSampler::Generate(RooAbsPdf &pdf, RooArgSet &observables, const } } else { - if (fUseMultiGen || fgAlwaysUseMultiGen) { + if (useMultiGen) { if (!_gs1) { _gs1 = pdf.prepareMultiGen(observables, Extended(), AutoBinned(fGenerateAutoBinned), GenBinned(fGenerateBinnedTag) ) ; } data = pdf.generate(*_gs1) ; } else { @@ -568,14 +610,14 @@ RooAbsData* ToyMCSampler::Generate(RooAbsPdf &pdf, RooArgSet &observables, const else data = pdf.generate(observables, events, AllBinned()); }else{ if(protoData) { - if (fUseMultiGen || fgAlwaysUseMultiGen) { + if (useMultiGen) { if (!_gs3) { _gs3 = pdf.prepareMultiGen(observables, NumEvents(events), AutoBinned(fGenerateAutoBinned), GenBinned(fGenerateBinnedTag), ProtoData(*protoData, true, true)); } data = pdf.generate(*_gs3) ; } else { data = pdf.generate (observables, NumEvents(events), AutoBinned(fGenerateAutoBinned), GenBinned(fGenerateBinnedTag), ProtoData(*protoData, true, true)); } } else { - if (fUseMultiGen || fgAlwaysUseMultiGen) { + if (useMultiGen) { if (!_gs4) { _gs4 = pdf.prepareMultiGen(observables, NumEvents(events), AutoBinned(fGenerateAutoBinned), GenBinned(fGenerateBinnedTag)); } data = pdf.generate(*_gs4) ; } else { diff --git a/roofit/roostats/src/ToyMCStudy.cxx b/roofit/roostats/src/ToyMCStudy.cxx index b4a48676e19c3..c77d593753a06 100644 --- a/roofit/roostats/src/ToyMCStudy.cxx +++ b/roofit/roostats/src/ToyMCStudy.cxx @@ -25,6 +25,7 @@ ClassImp(RooStats::ToyMCStudy); ClassImp(RooStats::ToyMCPayload); +using namespace std; namespace RooStats { diff --git a/roofit/roostats/src/UniformProposal.cxx b/roofit/roostats/src/UniformProposal.cxx index 0ad2debd6adfc..7446377e65f1d 100644 --- a/roofit/roostats/src/UniformProposal.cxx +++ b/roofit/roostats/src/UniformProposal.cxx @@ -47,6 +47,8 @@ END_HTML #include "TIterator.h" #endif +using namespace std; + ClassImp(RooStats::UniformProposal); using namespace RooFit; diff --git a/roofit/roostats/src/UpperLimitMCSModule.cxx b/roofit/roostats/src/UpperLimitMCSModule.cxx index 662048fcc1aad..4f96bd9501f33 100644 --- a/roofit/roostats/src/UpperLimitMCSModule.cxx +++ b/roofit/roostats/src/UpperLimitMCSModule.cxx @@ -42,6 +42,8 @@ +using namespace std; + ClassImp(RooStats::UpperLimitMCSModule); diff --git a/rootx/CMakeLists.txt b/rootx/CMakeLists.txt index 42135fce6b971..9f960796a2080 100644 --- a/rootx/CMakeLists.txt +++ b/rootx/CMakeLists.txt @@ -4,7 +4,14 @@ ############################################################################ ROOT_USE_PACKAGE(core) - -ROOT_EXECUTABLE(root *.cxx ${CMAKE_SOURCE_DIR}/core/clib/src/strlcpy.c - LIBRARIES ${X11_LIBRARIES} ${X11_Xpm_LIB} ${X11_Xft_LIB} ${X11_Xext_LIB}) - +if(x11) + include_directories(${X11_INCLUDE_DIR}) + ROOT_EXECUTABLE(root *.cxx ${CMAKE_SOURCE_DIR}/core/clib/src/strlcpy.c + LIBRARIES ${X11_LIBRARIES} ${X11_Xpm_LIB} ${X11_Xft_LIB} ${X11_Xext_LIB}) +elseif(cocoa) + add_custom_target(root ALL + COMMAND ${CMAKE_COMMAND} -E copy_if_different ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/root.exe ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/root) + add_dependencies(root root.exe) + install(PROGRAMS ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/root + DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT applications) +endif() diff --git a/rootx/Module.mk b/rootx/Module.mk index b5f8761de6a90..9fb678e1cb1da 100644 --- a/rootx/Module.mk +++ b/rootx/Module.mk @@ -32,8 +32,13 @@ INCLUDEFILES += $(ROOTXDEP) include/%.h: $(ROOTXDIRI)/%.h cp $< $@ +ifeq ($(BUILDCOCOA),yes) +$(ROOTX): $(ROOTEXE) + ln -sf `basename $(ROOTEXE)` $(ROOTX) +else $(ROOTX): $(ROOTXO) $(STRLCPYO) $(LD) $(LDFLAGS) -o $@ $(ROOTXO) $(STRLCPYO) $(XLIBS) +endif all-$(MODNAME): $(ROOTX) diff --git a/sql/CMakeLists.txt b/sql/CMakeLists.txt index 267c2f101008b..2150aea7a5704 100644 --- a/sql/CMakeLists.txt +++ b/sql/CMakeLists.txt @@ -7,4 +7,9 @@ endif() if(odbc) add_subdirectory(odbc) endif() - +if(pgsql) + add_subdirectory(pgsql) +endif() +if(sqlite) + add_subdirectory(sqlite) +endif() diff --git a/sql/odbc/Module.mk b/sql/odbc/Module.mk index 4d818d9ed4746..debb7988c6907 100644 --- a/sql/odbc/Module.mk +++ b/sql/odbc/Module.mk @@ -69,3 +69,6 @@ distclean:: distclean-$(MODNAME) ##### extra rules ###### $(ODBCO) $(ODBCDO): CXXFLAGS += $(ODBCINCDIR:%=-I%) +ifeq ($(MACOSX_ODBC_DEPRECATED),yes) +$(ODBCO) $(ODBCDO): CXXFLAGS += -Wno-deprecated-declarations +endif diff --git a/sql/odbc/src/TODBCServer.cxx b/sql/odbc/src/TODBCServer.cxx index e1a54e242e2f6..41bc365404196 100644 --- a/sql/odbc/src/TODBCServer.cxx +++ b/sql/odbc/src/TODBCServer.cxx @@ -53,7 +53,7 @@ TODBCServer::TODBCServer(const char *db, const char *uid, const char *pw) : // Configuring unixODBC under Linux: http://www.unixodbc.org/odbcinst.html // Remarks: for variants 1 & 2 it is enough to create/configure // odbcinst.ini file. For variant 3 file odbc.ini should be created. - // Path to this files can be specified in enviromental variables like + // Path to this files can be specified in environmental variables like // export ODBCINI=/home/my/unixODBC/etc/odbc.ini // export ODBCSYSINI=/home/my/unixODBC/etc // @@ -70,7 +70,7 @@ TODBCServer::TODBCServer(const char *db, const char *uid, const char *pw) : // 1) Two additional DLLs are required: mfc71.dll & msver71.dll // They can be found either in MS VC++ 7.1 Free Toolkit or // downloaded from other Internet sites - // 2) ORACLE_HOME enviroment variable should be specified and point to + // 2) ORACLE_HOME environment variable should be specified and point to // location, where Instant Client files are extracted // 3) Run odbc_install.exe from account with administrative rights // 3) In $ORACLE_HOME/network/admin/ directory appropriate *.ora files diff --git a/sql/odbc/src/TODBCStatement.cxx b/sql/odbc/src/TODBCStatement.cxx index 1ac5ae5174ad7..d1d69e9982581 100644 --- a/sql/odbc/src/TODBCStatement.cxx +++ b/sql/odbc/src/TODBCStatement.cxx @@ -68,7 +68,7 @@ TODBCStatement::TODBCStatement(SQLHSTMT stmt, Int_t rowarrsize, Bool_t errout) : SQLSetStmtAttr(fHstmt, SQL_ATTR_PARAM_BIND_TYPE, SQL_PARAM_BIND_BY_COLUMN, 0); SQLUINTEGER setsize = fBufferPreferredSize; - retcode = SQLSetStmtAttr(fHstmt, SQL_ATTR_PARAMSET_SIZE, (SQLPOINTER) setsize, 0); + retcode = SQLSetStmtAttr(fHstmt, SQL_ATTR_PARAMSET_SIZE, (SQLPOINTER) (long) setsize, 0); ExtractErrors(retcode,"Constructor"); SQLUINTEGER getsize = 0; @@ -134,7 +134,7 @@ Bool_t TODBCStatement::Process() // if buffer used not fully, set smaller size of buffer arrays if ((fBufferCounter>0) && (fBufferCounter<fBufferLength-1)) { SQLUINTEGER setsize = fBufferCounter+1; - SQLSetStmtAttr(fHstmt, SQL_ATTR_PARAMSET_SIZE, (SQLPOINTER) setsize, 0); + SQLSetStmtAttr(fHstmt, SQL_ATTR_PARAMSET_SIZE, (SQLPOINTER) (long) setsize, 0); } retcode = SQLExecute(fHstmt); } diff --git a/sql/oracle/inc/TOracleResult.h b/sql/oracle/inc/TOracleResult.h index 516564941bd4e..15eaaa7bbbd88 100644 --- a/sql/oracle/inc/TOracleResult.h +++ b/sql/oracle/inc/TOracleResult.h @@ -23,15 +23,16 @@ #include <sys/time.h> #endif #include <occi.h> -using namespace oracle::occi; #ifdef CONST #undef CONST #endif #else +namespace oracle { namespace occi { class Connection; class Statement; class ResultSet; class MetaData; + }} #endif class TList; @@ -39,10 +40,10 @@ class TList; class TOracleResult : public TSQLResult { private: - Connection *fConn; // connection to Oracle - Statement *fStmt; // executed statement - ResultSet *fResult; // query result (rows) - std::vector<MetaData> *fFieldInfo; // info for each field in the row + oracle::occi::Connection*fConn; // connection to Oracle + oracle::occi::Statement *fStmt; // executed statement + oracle::occi::ResultSet *fResult; // query result (rows) + std::vector<oracle::occi::MetaData> *fFieldInfo; // info for each field in the row Int_t fFieldCount; // num of fields in resultset UInt_t fUpdateCount; // for dml query, mutual exclusive with above Int_t fResultType; // 0 - nothing; 1 - Select; 2 - table metainfo, 3 - update counter @@ -55,12 +56,12 @@ class TOracleResult : public TSQLResult { TOracleResult &operator=(const TOracleResult&); // Not implemented; protected: - void initResultSet(Statement *stmt); + void initResultSet(oracle::occi::Statement *stmt); void ProducePool(); public: - TOracleResult(Connection *conn, Statement *stmt); - TOracleResult(Connection *conn, const char *tableName); + TOracleResult(oracle::occi::Connection *conn, oracle::occi::Statement *stmt); + TOracleResult(oracle::occi::Connection *conn, const char *tableName); ~TOracleResult(); void Close(Option_t *opt=""); diff --git a/sql/oracle/inc/TOracleRow.h b/sql/oracle/inc/TOracleRow.h index f9742b42a1652..c04f80447c2d4 100644 --- a/sql/oracle/inc/TOracleRow.h +++ b/sql/oracle/inc/TOracleRow.h @@ -21,22 +21,23 @@ #include <sys/time.h> #endif #include <occi.h> -using namespace oracle::occi; #ifdef CONST #undef CONST #endif #else +namespace oracle { namespace occi { class ResultSet; class MetaData; + }} #endif class TOracleRow : public TSQLRow { private: - ResultSet *fResult; // current result set - std::vector<MetaData> *fFieldInfo; // metadata for columns - Int_t fFieldCount; - char **fFieldsBuffer; + oracle::occi::ResultSet *fResult; // current result set + std::vector<oracle::occi::MetaData> *fFieldInfo; // metadata for columns + Int_t fFieldCount; + char **fFieldsBuffer; Bool_t IsValid(Int_t field); @@ -47,7 +48,8 @@ class TOracleRow : public TSQLRow { void GetRowData(); public: - TOracleRow(ResultSet *rs, std::vector<MetaData> *fieldMetaData); + TOracleRow(oracle::occi::ResultSet *rs, + std::vector<oracle::occi::MetaData> *fieldMetaData); ~TOracleRow(); void Close(Option_t *opt=""); diff --git a/sql/oracle/inc/TOracleServer.h b/sql/oracle/inc/TOracleServer.h index 9e4ad94abd492..42b6ab6239b6f 100644 --- a/sql/oracle/inc/TOracleServer.h +++ b/sql/oracle/inc/TOracleServer.h @@ -21,22 +21,22 @@ #include <sys/time.h> #endif #include <occi.h> -using namespace std; -using namespace oracle::occi; #ifdef CONST #undef CONST #endif #else +namespace oracle { namespace occi { class Environment; class Connection; +}} #endif class TOracleServer : public TSQLServer { private: - Environment *fEnv; // environment of Oracle access - Connection *fConn; // connection to Oracle server + oracle::occi::Environment *fEnv; // environment of Oracle access + oracle::occi::Connection *fConn; // connection to Oracle server TString fInfo; // info string with Oracle version information static const char* fgDatimeFormat; //! format for converting date and time stamps into string diff --git a/sql/oracle/inc/TOracleStatement.h b/sql/oracle/inc/TOracleStatement.h index 61994c7c54a92..f8c593f5da136 100644 --- a/sql/oracle/inc/TOracleStatement.h +++ b/sql/oracle/inc/TOracleStatement.h @@ -18,16 +18,17 @@ #if !defined(__CINT__) #include <occi.h> -using namespace oracle::occi; #ifdef CONST #undef CONST #endif #else +namespace oracle { namespace occi { class Environment; class Connection; class Statement; class ResultSet; class MetaData; + }} #endif class TOracleStatement : public TSQLStatement { @@ -40,11 +41,11 @@ class TOracleStatement : public TSQLStatement { char* namebuf; }; - Environment *fEnv; // enviroment - Connection *fConn; // connection to Oracle - Statement *fStmt; // executed statement - ResultSet *fResult; // query result (rows) - std::vector<MetaData> *fFieldInfo; // info for each field in the row + oracle::occi::Environment *fEnv; // environment + oracle::occi::Connection *fConn; // connection to Oracle + oracle::occi::Statement *fStmt; // executed statement + oracle::occi::ResultSet *fResult; // query result (rows) + std::vector<oracle::occi::MetaData> *fFieldInfo; // info for each field in the row TBufferRec *fBuffer; // buffer of values and field names Int_t fBufferSize; // size of fBuffer Int_t fNumIterations; // size of internal statement buffer @@ -59,7 +60,10 @@ class TOracleStatement : public TSQLStatement { void CloseBuffer(); public: - TOracleStatement(Environment* env, Connection* conn, Statement* stmt, Int_t niter, Bool_t errout = kTRUE); + TOracleStatement(oracle::occi::Environment* env, + oracle::occi::Connection* conn, + oracle::occi::Statement* stmt, + Int_t niter, Bool_t errout = kTRUE); virtual ~TOracleStatement(); virtual void Close(Option_t * = ""); diff --git a/sql/oracle/src/TOracleResult.cxx b/sql/oracle/src/TOracleResult.cxx index 838bad747a8c1..dba26d990888b 100644 --- a/sql/oracle/src/TOracleResult.cxx +++ b/sql/oracle/src/TOracleResult.cxx @@ -14,7 +14,7 @@ #include "TList.h" using namespace std; - +using namespace oracle::occi; ClassImp(TOracleResult) diff --git a/sql/oracle/src/TOracleRow.cxx b/sql/oracle/src/TOracleRow.cxx index 738bac8891f28..69020b9f8fabf 100644 --- a/sql/oracle/src/TOracleRow.cxx +++ b/sql/oracle/src/TOracleRow.cxx @@ -15,6 +15,10 @@ ClassImp(TOracleRow); +using namespace std; +using namespace oracle::occi; + + //______________________________________________________________________________ TOracleRow::TOracleRow(ResultSet *rs, vector<MetaData> *fieldMetaData) { @@ -144,8 +148,12 @@ void TOracleRow::GetRowData() case SQLT_TIMESTAMP_LTZ: // TIMESTAMP WITH LOCAL TIMEZONE res = (fResult->getTimestamp(field+1)).toText(TOracleServer::GetDatimeFormat(), 0); break; - default: - Error("GetRowData","Oracle type %d not supported.", fDataType); + case SQLT_IBFLOAT: + case SQLT_IBDOUBLE: + res = fResult->getString(field+1); + break; + default: + Error("GetRowData","Oracle type %d was not yet tested - please inform ROOT developers", fDataType); continue; } diff --git a/sql/oracle/src/TOracleServer.cxx b/sql/oracle/src/TOracleServer.cxx index 727bffcdde072..275a1c6ff1ef1 100644 --- a/sql/oracle/src/TOracleServer.cxx +++ b/sql/oracle/src/TOracleServer.cxx @@ -57,6 +57,9 @@ ClassImp(TOracleServer) +using namespace std; +using namespace oracle::occi; + const char* TOracleServer::fgDatimeFormat = "MM/DD/YYYY, HH24:MI:SS"; @@ -85,6 +88,15 @@ TOracleServer::TOracleServer(const char *db, const char *uid, const char *pw) fEnv = 0; fConn = 0; + if (gDebug>0) { + // this code is necessary to guarantee, that libclntsh.so will be + // linked to libOracle.so. + sword major_version(0), minor_version(0), update_num(0), patch_num(0), port_update_num(0); + OCIClientVersion(&major_version, &minor_version, &update_num, &patch_num, &port_update_num); + Info("TOracleServer","Oracle Call Interface version %u.%u.%u.%u.%u", + (unsigned) major_version, (unsigned) minor_version, (unsigned) update_num, (unsigned) patch_num, (unsigned) port_update_num); + } + TUrl url(db); if (!url.IsValid()) { @@ -216,7 +228,7 @@ TSQLResult *TOracleServer::Query(const char *sql) Bool_t TOracleServer::Exec(const char* sql) { // Execute sql command wich does not produce any result set. - // Return kTRUE if succesfull + // Return kTRUE if successful CheckConnect("Exec", kFALSE); diff --git a/sql/oracle/src/TOracleStatement.cxx b/sql/oracle/src/TOracleStatement.cxx index 089e23f0fa4d7..5c37f38a5cdb3 100644 --- a/sql/oracle/src/TOracleStatement.cxx +++ b/sql/oracle/src/TOracleStatement.cxx @@ -25,6 +25,10 @@ ClassImp(TOracleStatement) +using namespace std; +using namespace oracle::occi; + + //______________________________________________________________________________ TOracleStatement::TOracleStatement(Environment* env, Connection* conn, Statement* stmt, Int_t niter, Bool_t errout) : TSQLStatement(errout), diff --git a/sql/pgsql/CMakeLists.txt b/sql/pgsql/CMakeLists.txt new file mode 100644 index 0000000000000..6e10b2af30012 --- /dev/null +++ b/sql/pgsql/CMakeLists.txt @@ -0,0 +1,13 @@ +############################################################################ +# CMakeLists.txt file for building ROOT sql/pgsql package +############################################################################ + +ROOT_USE_PACKAGE(io/io) +ROOT_USE_PACKAGE(net/net) + +include_directories(${POSTGRESQL_INCLUDE_DIR}) + +ROOT_GENERATE_DICTIONARY(G__PgSQL *.h LINKDEF LinkDef.h) +ROOT_GENERATE_ROOTMAP(RPgSQL LINKDEF LinkDef.h DEPENDENCIES Net RIO) +ROOT_LINKER_LIBRARY(RPgSQL *.cxx G__PgSQL.cxx LIBRARIES Core ${POSTGRESQL_LIBRARIES} DEPENDENCIES Net RIO) +ROOT_INSTALL_HEADERS() diff --git a/sql/pgsql/inc/TPgSQLServer.h b/sql/pgsql/inc/TPgSQLServer.h index f72c6959b8c1f..1fbb582a7c58f 100644 --- a/sql/pgsql/inc/TPgSQLServer.h +++ b/sql/pgsql/inc/TPgSQLServer.h @@ -28,6 +28,7 @@ class TPgSQLServer : public TSQLServer { private: PGconn *fPgSQL; // connection to PgSQL server + TString fSrvInfo; // Server info public: TPgSQLServer(const char *db, const char *uid, const char *pw); diff --git a/sql/pgsql/inc/TPgSQLStatement.h b/sql/pgsql/inc/TPgSQLStatement.h index b3ffc5482bf42..b4e1debfa77d9 100644 --- a/sql/pgsql/inc/TPgSQLStatement.h +++ b/sql/pgsql/inc/TPgSQLStatement.h @@ -36,7 +36,6 @@ struct PGresult; #endif - struct PgSQL_Stmt_t { PGconn *fConn; PGresult *fRes; @@ -68,6 +67,8 @@ class TPgSQLStatement : public TSQLStatement { void FreeBuffers(); void SetBuffersNumber(Int_t n); + void ConvertTimeToUTC(const TString &PQvalue, Int_t& year, Int_t& month, Int_t& day, Int_t& hour, Int_t& min, Int_t& sec); + public: TPgSQLStatement(PgSQL_Stmt_t* stmt, Bool_t errout = kTRUE); virtual ~TPgSQLStatement(); @@ -86,6 +87,7 @@ class TPgSQLStatement : public TSQLStatement { virtual Bool_t SetDouble(Int_t npar, Double_t value); virtual Bool_t SetString(Int_t npar, const char* value, Int_t maxsize = 256); virtual Bool_t SetBinary(Int_t npar, void* mem, Long_t size, Long_t maxsize = 0x1000); + virtual Bool_t SetLargeObject(Int_t npar, void* mem, Long_t size, Long_t maxsize = 0x1000); virtual Bool_t SetDate(Int_t npar, Int_t year, Int_t month, Int_t day); virtual Bool_t SetTime(Int_t npar, Int_t hour, Int_t min, Int_t sec); virtual Bool_t SetDatime(Int_t npar, Int_t year, Int_t month, Int_t day, Int_t hour, Int_t min, Int_t sec); @@ -110,6 +112,7 @@ class TPgSQLStatement : public TSQLStatement { virtual Double_t GetDouble(Int_t npar); virtual const char *GetString(Int_t npar); virtual Bool_t GetBinary(Int_t npar, void* &mem, Long_t& size); + virtual Bool_t GetLargeObject(Int_t npar, void* &mem, Long_t& size); virtual Bool_t GetDate(Int_t npar, Int_t& year, Int_t& month, Int_t& day); virtual Bool_t GetTime(Int_t npar, Int_t& hour, Int_t& min, Int_t& sec); virtual Bool_t GetDatime(Int_t npar, Int_t& year, Int_t& month, Int_t& day, Int_t& hour, Int_t& min, Int_t& sec); diff --git a/sql/pgsql/src/TPgSQLServer.cxx b/sql/pgsql/src/TPgSQLServer.cxx index bb0623c646631..3c52abf2f9f00 100644 --- a/sql/pgsql/src/TPgSQLServer.cxx +++ b/sql/pgsql/src/TPgSQLServer.cxx @@ -26,6 +26,7 @@ TPgSQLServer::TPgSQLServer(const char *db, const char *uid, const char *pw) // the password that should be used for the connection. fPgSQL = 0; + fSrvInfo=""; TUrl url(db); @@ -48,15 +49,28 @@ TPgSQLServer::TPgSQLServer(const char *db, const char *uid, const char *pw) TString port; port += url.GetPort(); fPgSQL = PQsetdbLogin(url.GetHost(), port, 0, 0, dbase, uid, pw); - } else + } else { fPgSQL = PQsetdbLogin(url.GetHost(), 0, 0, 0, dbase, uid, pw); - + } if (PQstatus(fPgSQL) != CONNECTION_BAD) { fType = "PgSQL"; fHost = url.GetHost(); fDB = dbase; fPort = url.GetPort(); + + // Populate server-info + fSrvInfo = "postgres "; + static const char *sql = "select setting from pg_settings where name='server_version'"; + PGresult *res = PQexec(fPgSQL, sql); + int stat = PQresultStatus(res); + if (stat == PGRES_TUPLES_OK && PQntuples(res)) { + char *vers = PQgetvalue(res,0,0); + fSrvInfo += vers; + PQclear(res); + } else { + fSrvInfo += "unknown version number"; + } } else { Error("TPgSQLServer", "connection to %s failed", url.GetHost()); MakeZombie(); @@ -295,22 +309,12 @@ const char *TPgSQLServer::ServerInfo() { // Return server info. - TString svrinfo = "postgres "; if (!IsConnected()) { Error("ServerInfo", "not connected"); return 0; } - static const char *sql = "select setting from pg_settings where name='server_version'"; - PGresult *res = PQexec(fPgSQL, sql); - int stat = PQresultStatus(res); - if (stat == PGRES_TUPLES_OK && PQntuples(res)) { - char *vers = PQgetvalue(res,0,0); - svrinfo += vers; - } else - svrinfo += "unknown version number"; - - return svrinfo; + return fSrvInfo.Data(); } //______________________________________________________________________________ @@ -348,7 +352,7 @@ TSQLStatement* TPgSQLServer::Statement(const char *, Int_t) return 0; } stmt->fConn = fPgSQL; - stmt->fRes = PQprepare(fPgSQL, "", sql, 0, (const Oid*)0); + stmt->fRes = PQprepare(fPgSQL, "preparedstmt", sql, 0, (const Oid*)0); ExecStatusType stat = PQresultStatus(stmt->fRes); if (pgsql_success(stat)) { diff --git a/sql/pgsql/src/TPgSQLStatement.cxx b/sql/pgsql/src/TPgSQLStatement.cxx index 01ba8022d310d..ab11d3470699e 100644 --- a/sql/pgsql/src/TPgSQLStatement.cxx +++ b/sql/pgsql/src/TPgSQLStatement.cxx @@ -20,6 +20,7 @@ #include "TPgSQLStatement.h" #include "TDataType.h" #include "TDatime.h" +#include "TTimeStamp.h" #include <stdlib.h> @@ -27,6 +28,8 @@ ClassImp(TPgSQLStatement) #ifdef PG_VERSION_NUM +#include "libpq/libpq-fs.h" + static const Int_t kBindStringSize = 25; //______________________________________________________________________________ @@ -46,7 +49,12 @@ TPgSQLStatement::TPgSQLStatement(PgSQL_Stmt_t* stmt, Bool_t errout): // Normal constructor. // Checks if statement contains parameters tags. - fStmt->fRes = PQdescribePrepared(fStmt->fConn,""); + // Given fRes not used, we retrieve the statement using the connection. + if (fStmt->fRes != NULL) { + PQclear(fStmt->fRes); + } + + fStmt->fRes = PQdescribePrepared(fStmt->fConn,"preparedstmt"); unsigned long paramcount = PQnparams(fStmt->fRes); fNumResultCols = PQnfields(fStmt->fRes); fIterationCount = -1; @@ -78,6 +86,9 @@ void TPgSQLStatement::Close(Option_t *) fStmt->fRes = 0; + PGresult *res=PQexec(fStmt->fConn,"DEALLOCATE preparedstmt;"); + PQclear(res); + FreeBuffers(); //TPgSQLServers responsibility to free connection fStmt->fConn=0; @@ -106,6 +117,24 @@ void TPgSQLStatement::Close(Option_t *) } \ } +#define CheckErrResult(method, pqresult, retVal) \ + { \ + ExecStatusType stmterrno=PQresultStatus(pqresult); \ + if (!pgsql_success(stmterrno)) { \ + const char* stmterrmsg = PQresultErrorMessage(fStmt->fRes); \ + SetError(stmterrno, stmterrmsg, method); \ + PQclear(res); \ + return retVal; \ + } \ + } + +#define RollBackTransaction(method) \ + { \ + PGresult *resnum=PQexec(fStmt->fConn,"COMMIT"); \ + CheckErrResult("RollBackTransaction", resnum, kFALSE); \ + PQclear(res); \ + } + // check last pgsql statement error code #define CheckGetField(method, res) \ { \ @@ -127,14 +156,20 @@ Bool_t TPgSQLStatement::Process() CheckStmt("Process",kFALSE); + // We create the prepared statement below, MUST delete the old one + // from our constructor first! + if (fStmt->fRes != NULL) { + PQclear(fStmt->fRes); + } + if (IsSetParsMode()) { - fStmt->fRes= PQexecPrepared(fStmt->fConn,"",fNumBuffers, + fStmt->fRes= PQexecPrepared(fStmt->fConn,"preparedstmt",fNumBuffers, (const char* const*)fBind, 0,0,0); } else { //result set mode - fStmt->fRes= PQexecPrepared(fStmt->fConn,"",0,(const char* const*) 0,0,0,0); + fStmt->fRes= PQexecPrepared(fStmt->fConn,"preparedstmt",0,(const char* const*) 0,0,0,0); } ExecStatusType stat = PQresultStatus(fStmt->fRes); if (!pgsql_success(stat)) @@ -159,11 +194,11 @@ Int_t TPgSQLStatement::GetNumParameters() CheckStmt("GetNumParameters", -1); - Int_t res = PQnparams(fStmt->fRes); - - CheckErrNo("GetNumParameters", kFALSE, -1); - - return res; + if (IsSetParsMode()) { + return fNumBuffers; + } else { + return 0; + } } //______________________________________________________________________________ @@ -242,7 +277,7 @@ Bool_t TPgSQLStatement::NextIteration() if (fIterationCount==0) return kTRUE; - fStmt->fRes= PQexecPrepared(fStmt->fConn,"",fNumBuffers, + fStmt->fRes= PQexecPrepared(fStmt->fConn,"preparedstmt",fNumBuffers, (const char* const*)fBind, 0,//fParamLengths, 0,//fParamFormats, @@ -260,7 +295,7 @@ void TPgSQLStatement::FreeBuffers() { // Release all buffers, used by statement. - //individual field names free()'ed by PQClear of fStmt->fRes + //individual field names free()'ed by PQclear of fStmt->fRes if (fFieldName) delete[] fFieldName; @@ -436,36 +471,111 @@ Bool_t TPgSQLStatement::GetBinary(Int_t npar, void* &mem, Long_t& size) return kTRUE; } +//______________________________________________________________________________ +Bool_t TPgSQLStatement::GetLargeObject(Int_t npar, void* &mem, Long_t& size) +{ + // Return large object whose oid is in the given field. + + Int_t objID = atoi(PQgetvalue(fStmt->fRes,fIterationCount,npar)); + + // All this needs to happen inside a transaction, or it will NOT work. + PGresult *res=PQexec(fStmt->fConn,"BEGIN"); + + CheckErrResult("GetLargeObject", res, kFALSE); + PQclear(res); + + Int_t lObjFD = lo_open(fStmt->fConn, objID, INV_READ); + + if (lObjFD<0) { + Error("GetLargeObject", "SQL Error on lo_open: %s", PQerrorMessage(fStmt->fConn)); + RollBackTransaction("GetLargeObject"); + return kFALSE; + } + // Object size is not known beforehand. + // Possible fast ways to get it are: + // (1) Create a function that does fopen, fseek, ftell on server + // (2) Query large object table with size() + // Both can not be expected to work in general, + // as (1) needs permissions and changes DB, + // and (2) needs permission. + // So we use + // (3) fopen, fseek and ftell locally. + + lo_lseek(fStmt->fConn, lObjFD, 0, SEEK_END); + Long_t sz = lo_tell(fStmt->fConn, lObjFD); + lo_lseek(fStmt->fConn, lObjFD, 0, SEEK_SET); + + if ((Long_t)sz>size) { + delete [] (unsigned char*) mem; + mem = (void*) new unsigned char[sz]; + size=sz; + } + + Int_t readBytes = lo_read(fStmt->fConn, lObjFD, (char*)mem, size); + + if (readBytes != sz) { + Error("GetLargeObject", "SQL Error on lo_read: %s", PQerrorMessage(fStmt->fConn)); + RollBackTransaction("GetLargeObject"); + return kFALSE; + } + + if (lo_close(fStmt->fConn, lObjFD) != 0) { + Error("GetLargeObject", "SQL Error on lo_close: %s", PQerrorMessage(fStmt->fConn)); + RollBackTransaction("GetLargeObject"); + return kFALSE; + } + + res=PQexec(fStmt->fConn,"COMMIT"); + + ExecStatusType stat = PQresultStatus(res); + if (!pgsql_success(stat)) { + Error("GetLargeObject", "SQL Error on COMMIT: %s", PQerrorMessage(fStmt->fConn)); + RollBackTransaction("GetLargeObject"); + return kFALSE; + } + PQclear(res); + + return kTRUE; +} + //______________________________________________________________________________ Bool_t TPgSQLStatement::GetDate(Int_t npar, Int_t& year, Int_t& month, Int_t& day) { - // Return field value as date. + // Return field value as date, in UTC. TString val=PQgetvalue(fStmt->fRes,fIterationCount,npar); TDatime d = TDatime(val.Data()); year = d.GetYear(); month = d.GetMonth(); day= d.GetDay(); + Int_t hour = d.GetHour(); + Int_t min = d.GetMinute(); + Int_t sec = d.GetSecond(); + ConvertTimeToUTC(val, year, month, day, hour, min, sec); return kTRUE; } //______________________________________________________________________________ Bool_t TPgSQLStatement::GetTime(Int_t npar, Int_t& hour, Int_t& min, Int_t& sec) { - // Return field as time. + // Return field as time, in UTC. TString val=PQgetvalue(fStmt->fRes,fIterationCount,npar); TDatime d = TDatime(val.Data()); hour = d.GetHour(); min = d.GetMinute(); sec= d.GetSecond(); + Int_t year = d.GetYear(); + Int_t month = d.GetMonth(); + Int_t day = d.GetDay(); + ConvertTimeToUTC(val, day, month, year, hour, min, sec); return kTRUE; } //______________________________________________________________________________ Bool_t TPgSQLStatement::GetDatime(Int_t npar, Int_t& year, Int_t& month, Int_t& day, Int_t& hour, Int_t& min, Int_t& sec) { - // Return field value as date & time. + // Return field value as date & time, in UTC. TString val=PQgetvalue(fStmt->fRes,fIterationCount,npar); TDatime d = TDatime(val.Data()); @@ -475,25 +585,83 @@ Bool_t TPgSQLStatement::GetDatime(Int_t npar, Int_t& year, Int_t& month, Int_t& hour = d.GetHour(); min = d.GetMinute(); sec= d.GetSecond(); + ConvertTimeToUTC(val, year, month, day, hour, min, sec); return kTRUE; } +//______________________________________________________________________________ +void TPgSQLStatement::ConvertTimeToUTC(const TString &PQvalue, Int_t& year, Int_t& month, Int_t& day, Int_t& hour, Int_t& min, Int_t& sec) +{ + // Convert timestamp value to UTC if a zone is included. + + Ssiz_t p = PQvalue.Last('.'); + // Check if timestamp has timezone + TSubString *s_zone; + Bool_t hasZone = kFALSE; + Ssiz_t tzP = PQvalue.Last('+'); + if ((tzP != kNPOS) && (tzP > p) ) { + s_zone = new TSubString(PQvalue(tzP+1,PQvalue.Length()-tzP)); + hasZone=kTRUE; + } else { + Ssiz_t tzM = PQvalue.Last('-'); + if ((tzM != kNPOS) && (tzM > p) ) { + s_zone = new TSubString(PQvalue(tzM+1,PQvalue.Length()-tzM)); + hasZone = kTRUE; + } + } + if (hasZone == kTRUE) { + // Parse timezone, might look like e.g. +00 or -00:00 + Int_t hourOffset, minuteOffset = 0; + Int_t conversions=sscanf(s_zone->Data(), "%2d:%2d", &hourOffset, &minuteOffset); + Int_t secondOffset = hourOffset*3600; + if (conversions>1) { + // Use sign from hour also for minute + secondOffset += (TMath::Sign(minuteOffset, hourOffset))*60; + } + // Use TTimeStamp so we do not have to take care of over-/underflows + TTimeStamp ts(year, month, day, hour, min, sec, 0, kTRUE, -secondOffset); + UInt_t uyear, umonth, uday, uhour, umin, usec; + ts.GetDate(kTRUE, 0, &uyear, &umonth, &uday); + ts.GetTime(kTRUE, 0, &uhour, &umin, &usec); + year=uyear; + month=umonth; + day=uday; + hour=uhour; + min=umin; + sec=usec; + delete s_zone; + } +} + //______________________________________________________________________________ Bool_t TPgSQLStatement::GetTimestamp(Int_t npar, Int_t& year, Int_t& month, Int_t& day, Int_t& hour, Int_t& min, Int_t& sec, Int_t& frac) { - // Return field as timestamp. + // Return field as timestamp, in UTC. + // Second fraction is to be interpreted as in the following example: + // 2013-01-12 12:10:23.093854+02 + // Fraction is '93854', precision is fixed in this method to 6 decimal places. + // This means the returned frac-value is always in microseconds. TString val=PQgetvalue(fStmt->fRes,fIterationCount,npar); - Ssiz_t p = val.Last('.'); - TSubString s_frac = val(p,val.Length()-p+1); - TDatime d = TDatime(val.Data()); + TDatime d(val.Data()); year = d.GetYear(); month = d.GetMonth(); day= d.GetDay(); hour = d.GetHour(); min = d.GetMinute(); sec= d.GetSecond(); - frac=atoi(s_frac.Data()); + + ConvertTimeToUTC(val, year, month, day, hour, min, sec); + + Ssiz_t p = val.Last('.'); + TSubString s_frac = val(p,val.Length()-p+1); + + // atoi ignores timezone part. + // We MUST use atof here to correctly convert the fraction of + // "12:23:01.093854" and put a limitation on precision, + // as we can only return an Int_t. + frac=(Int_t) (atof(s_frac.Data())*1.E6); + return kTRUE; } @@ -603,6 +771,59 @@ Bool_t TPgSQLStatement::SetBinary(Int_t npar, void* mem, Long_t size, Long_t max return kTRUE; } +//______________________________________________________________________________ +Bool_t TPgSQLStatement::SetLargeObject(Int_t npar, void* mem, Long_t size, Long_t /*maxsize*/) +{ + // Set parameter value to large object and immediately insert the large object into DB. + + // All this needs to happen inside a transaction, or it will NOT work. + PGresult *res=PQexec(fStmt->fConn,"BEGIN"); + + CheckErrResult("GetLargeObject", res, kFALSE); + PQclear(res); + + Int_t lObjID = lo_creat(fStmt->fConn, INV_READ | INV_WRITE); + if (lObjID<0) { + Error("SetLargeObject", "Error in SetLargeObject: %s", PQerrorMessage(fStmt->fConn)); + RollBackTransaction("GetLargeObject"); + return kFALSE; + } + + Int_t lObjFD = lo_open(fStmt->fConn, lObjID, INV_READ | INV_WRITE); + if (lObjFD<0) { + Error("SetLargeObject", "Error in SetLargeObject: %s", PQerrorMessage(fStmt->fConn)); + RollBackTransaction("GetLargeObject"); + return kFALSE; + } + + Int_t writtenBytes = lo_write(fStmt->fConn, lObjFD, (char*)mem, size); + + if (writtenBytes != size) { + Error("SetLargeObject", "SQL Error on lo_write: %s", PQerrorMessage(fStmt->fConn)); + RollBackTransaction("GetLargeObject"); + return kFALSE; + } + + if (lo_close(fStmt->fConn, lObjFD) != 0) { + Error("SetLargeObject", "SQL Error on lo_close: %s", PQerrorMessage(fStmt->fConn)); + RollBackTransaction("GetLargeObject"); + return kFALSE; + } + + res=PQexec(fStmt->fConn,"COMMIT"); + ExecStatusType stat = PQresultStatus(res); + if (!pgsql_success(stat)) { + Error("SetLargeObject", "SQL Error on COMMIT: %s", PQerrorMessage(fStmt->fConn)); + PQclear(res); + return kFALSE; + } + PQclear(res); + + snprintf(fBind[npar],kBindStringSize,"%d",lObjID); + + return kTRUE; +} + //______________________________________________________________________________ Bool_t TPgSQLStatement::SetDate(Int_t npar, Int_t year, Int_t month, Int_t day) { @@ -611,7 +832,7 @@ Bool_t TPgSQLStatement::SetDate(Int_t npar, Int_t year, Int_t month, Int_t day) TDatime d =TDatime(year,month,day,0,0,0); snprintf(fBind[npar],kBindStringSize,"%s",(char*)d.AsSQLString()); - return kFALSE; + return kTRUE; } //______________________________________________________________________________ @@ -635,12 +856,15 @@ Bool_t TPgSQLStatement::SetDatime(Int_t npar, Int_t year, Int_t month, Int_t day } //______________________________________________________________________________ -Bool_t TPgSQLStatement::SetTimestamp(Int_t npar, Int_t year, Int_t month, Int_t day, Int_t hour, Int_t min, Int_t sec, Int_t) +Bool_t TPgSQLStatement::SetTimestamp(Int_t npar, Int_t year, Int_t month, Int_t day, Int_t hour, Int_t min, Int_t sec, Int_t frac) { // Set parameter value as timestamp. + // Second fraction is assumed as value in microseconds, + // i.e. as a fraction with six decimal places. + // See GetTimestamp() for an example. TDatime d(year,month,day,hour,min,sec); - snprintf(fBind[npar],kBindStringSize,"%s",(char*)d.AsSQLString()); + snprintf(fBind[npar],kBindStringSize,"%s.%06d",(char*)d.AsSQLString(),frac); return kTRUE; } @@ -833,6 +1057,13 @@ Bool_t TPgSQLStatement::GetBinary(Int_t, void* &, Long_t&) return kFALSE; } +//______________________________________________________________________________ +Bool_t TPgSQLStatement::GetLargeObject(Int_t, void* &, Long_t&) +{ + // Return large object whose oid is in the given field. + + return kFALSE; +} //______________________________________________________________________________ Bool_t TPgSQLStatement::GetDate(Int_t, Int_t&, Int_t&, Int_t&) @@ -954,6 +1185,14 @@ Bool_t TPgSQLStatement::SetBinary(Int_t, void*, Long_t, Long_t) return kFALSE; } +//______________________________________________________________________________ +Bool_t TPgSQLStatement::SetLargeObject(Int_t, void*, Long_t, Long_t) +{ + // Set parameter value to large object and immediately insert the large object into DB. + + return kFALSE; +} + //______________________________________________________________________________ Bool_t TPgSQLStatement::SetDate(Int_t, Int_t, Int_t, Int_t) { diff --git a/sql/sqlite/CMakeLists.txt b/sql/sqlite/CMakeLists.txt new file mode 100644 index 0000000000000..63c01ba172922 --- /dev/null +++ b/sql/sqlite/CMakeLists.txt @@ -0,0 +1,13 @@ +############################################################################ +# CMakeLists.txt file for building ROOT sql/pgsql package +############################################################################ + +ROOT_USE_PACKAGE(io/io) +ROOT_USE_PACKAGE(net/net) + +include_directories(${SQLITE_INCLUDE_DIR}) + +ROOT_GENERATE_DICTIONARY(G__SQLite *.h LINKDEF LinkDef.h) +ROOT_GENERATE_ROOTMAP(RSQLite LINKDEF LinkDef.h DEPENDENCIES Net RIO) +ROOT_LINKER_LIBRARY(RSQLite *.cxx G__SQLite.cxx LIBRARIES Core ${SQLITE_LIBRARIES} DEPENDENCIES Net RIO) +ROOT_INSTALL_HEADERS() diff --git a/sql/sqlite/Module.mk b/sql/sqlite/Module.mk new file mode 100644 index 0000000000000..14754b2714b02 --- /dev/null +++ b/sql/sqlite/Module.mk @@ -0,0 +1,71 @@ +# Module.mk for sqlite module +# Copyright (c) 2013 Rene Brun and Fons Rademakers +# +# Author: o.freyermuth <o.f@cern.ch>, 01/06/2013 + +MODNAME := sqlite +MODDIR := $(ROOT_SRCDIR)/sql/$(MODNAME) +MODDIRS := $(MODDIR)/src +MODDIRI := $(MODDIR)/inc + +SQLITEDIR := $(MODDIR) +SQLITEDIRS := $(SQLITEDIR)/src +SQLITEDIRI := $(SQLITEDIR)/inc + +##### libSQLite ##### +SQLITEL := $(MODDIRI)/LinkDef.h +SQLITEDS := $(call stripsrc,$(MODDIRS)/G__SQLite.cxx) +SQLITEDO := $(SQLITEDS:.cxx=.o) +SQLITEDH := $(SQLITEDS:.cxx=.h) + +SQLITEH := $(filter-out $(MODDIRI)/LinkDef%,$(wildcard $(MODDIRI)/*.h)) +SQLITES := $(filter-out $(MODDIRS)/G__%,$(wildcard $(MODDIRS)/*.cxx)) +SQLITEO := $(call stripsrc,$(SQLITES:.cxx=.o)) + +SQLITEDEP := $(SQLITEO:.o=.d) $(SQLITEDO:.o=.d) + +SQLITELIB := $(LPATH)/libSQLite.$(SOEXT) +SQLITEMAP := $(SQLITELIB:.$(SOEXT)=.rootmap) + +# used in the main Makefile +ALLHDRS += $(patsubst $(MODDIRI)/%.h,include/%.h,$(SQLITEH)) +ALLLIBS += $(SQLITELIB) +ALLMAPS += $(SQLITEMAP) + +# include all dependency files +INCLUDEFILES += $(SQLITEDEP) + +##### local rules ##### +.PHONY: all-$(MODNAME) clean-$(MODNAME) distclean-$(MODNAME) + +include/%.h: $(SQLITEDIRI)/%.h + cp $< $@ + +$(SQLITELIB): $(SQLITEO) $(SQLITEDO) $(ORDER_) $(MAINLIBS) $(SQLITELIBDEP) + @$(MAKELIB) $(PLATFORM) $(LD) "$(LDFLAGS)" \ + "$(SOFLAGS)" libSQLite.$(SOEXT) $@ "$(SQLITEO) $(SQLITEDO)" \ + "$(SQLITELIBEXTRA) $(SQLITELIBDIR) $(SQLITECLILIB)" + +$(SQLITEDS): $(SQLITEH) $(SQLITEL) $(ROOTCINTTMPDEP) + $(MAKEDIR) + @echo "Generating dictionary $@..." + $(ROOTCINTTMP) -f $@ -c $(SQLITEH) $(SQLITEL) + +$(SQLITEMAP): $(RLIBMAP) $(MAKEFILEDEP) $(SQLITEL) + $(RLIBMAP) -o $@ -l $(SQLITELIB) \ + -d $(SQLITELIBDEPM) -c $(SQLITEL) + +all-$(MODNAME): $(SQLITELIB) $(SQLITEMAP) + +clean-$(MODNAME): + @rm -f $(SQLITEO) $(SQLITEDO) + +clean:: clean-$(MODNAME) + +distclean-$(MODNAME): clean-$(MODNAME) + @rm -f $(SQLITEDEP) $(SQLITEDS) $(SQLITEDH) $(SQLITELIB) $(SQLITEMAP) + +distclean:: distclean-$(MODNAME) + +##### extra rules ###### +$(SQLITEO) $(SQLITEDO): CXXFLAGS += $(SQLITEINCDIR:%=-I%) diff --git a/sql/sqlite/inc/LinkDef.h b/sql/sqlite/inc/LinkDef.h new file mode 100644 index 0000000000000..d270ab672e7cd --- /dev/null +++ b/sql/sqlite/inc/LinkDef.h @@ -0,0 +1,12 @@ +#ifdef __CINT__ + +#pragma link off all globals; +#pragma link off all classes; +#pragma link off all functions; + +#pragma link C++ class TSQLiteServer+; +#pragma link C++ class TSQLiteResult+; +#pragma link C++ class TSQLiteRow+; +#pragma link C++ class TSQLiteStatement+; + +#endif diff --git a/sql/sqlite/inc/TSQLiteResult.h b/sql/sqlite/inc/TSQLiteResult.h new file mode 100644 index 0000000000000..3530defcb14df --- /dev/null +++ b/sql/sqlite/inc/TSQLiteResult.h @@ -0,0 +1,45 @@ +// @(#)root/sqlite:$Id$ +// Author: o.freyermuth <o.f@cern.ch>, 01/06/2013 + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TSQLiteResult +#define ROOT_TSQLiteResult + +#ifndef ROOT_TSQLResult +#include "TSQLResult.h" +#endif + +#if !defined(__CINT__) +#include <sqlite3.h> +#else +struct sqlite3_stmt; +#endif + + +class TSQLiteResult : public TSQLResult { + +private: + sqlite3_stmt *fResult; // query result (rows) + + Bool_t IsValid(Int_t field); + +public: + TSQLiteResult(void *result); + ~TSQLiteResult(); + + void Close(Option_t *opt=""); + Int_t GetFieldCount(); + const char *GetFieldName(Int_t field); + TSQLRow *Next(); + + ClassDef(TSQLiteResult, 0) // SQLite query result +}; + +#endif diff --git a/sql/sqlite/inc/TSQLiteRow.h b/sql/sqlite/inc/TSQLiteRow.h new file mode 100644 index 0000000000000..11c35277098a8 --- /dev/null +++ b/sql/sqlite/inc/TSQLiteRow.h @@ -0,0 +1,43 @@ +// @(#)root/sqlite:$Id$ +// Author: o.freyermuth <o.f@cern.ch>, 01/06/2013 + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TPgSQLRow +#define ROOT_TPgSQLRow + +#ifndef ROOT_TSQLRow +#include "TSQLRow.h" +#endif + +#if !defined(__CINT__) +#include <sqlite3.h> +#else +struct sqlite3_stmt; +#endif + + +class TSQLiteRow : public TSQLRow { + +private: + sqlite3_stmt *fResult; // current result set + Bool_t IsValid(Int_t field); + +public: + TSQLiteRow(void *result, ULong_t rowHandle); + ~TSQLiteRow(); + + void Close(Option_t *opt=""); + ULong_t GetFieldLength(Int_t field); + const char *GetField(Int_t field); + + ClassDef(TSQLiteRow,0) // One row of SQLite query result +}; + +#endif diff --git a/sql/sqlite/inc/TSQLiteServer.h b/sql/sqlite/inc/TSQLiteServer.h new file mode 100644 index 0000000000000..264d196cecac3 --- /dev/null +++ b/sql/sqlite/inc/TSQLiteServer.h @@ -0,0 +1,57 @@ +// @(#)root/sqlite:$Id$ +// Author: o.freyermuth <o.f@cern.ch>, 01/06/2013 + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TSQLiteServer +#define ROOT_TSQLiteServer + +#ifndef ROOT_TSQLServer +#include "TSQLServer.h" +#endif + +#if !defined(__CINT__) +#include <sqlite3.h> +#else +struct sqlite3; +#endif + + + +class TSQLiteServer : public TSQLServer { + + private: + TString fSrvInfo; // Server info string + sqlite3 *fSQLite; // connection to SQLite DB + + public: + TSQLiteServer(const char *db, const char *uid=NULL, const char *pw=NULL); + ~TSQLiteServer(); + + void Close(Option_t *opt=""); + Bool_t StartTransaction(); + TSQLResult *Query(const char *sql); + Bool_t Exec(const char *sql); + TSQLStatement *Statement(const char *sql, Int_t = 100); + Bool_t HasStatement() const; + Int_t SelectDataBase(const char *dbname); + TSQLResult *GetDataBases(const char *wild = 0); + TSQLResult *GetTables(const char *dbname, const char *wild = 0); + TSQLResult *GetColumns(const char *dbname, const char *table, const char *wild = 0); + TSQLTableInfo *GetTableInfo(const char* tablename); + Int_t CreateDataBase(const char *dbname); + Int_t DropDataBase(const char *dbname); + Int_t Reload(); + Int_t Shutdown(); + const char *ServerInfo(); + + ClassDef(TSQLiteServer,0); // Connection to SQLite DB +}; + +#endif diff --git a/sql/sqlite/inc/TSQLiteStatement.h b/sql/sqlite/inc/TSQLiteStatement.h new file mode 100644 index 0000000000000..cd9c9ea9c2671 --- /dev/null +++ b/sql/sqlite/inc/TSQLiteStatement.h @@ -0,0 +1,110 @@ +// @(#)root/sqlite:$Id$ +// Author: o.freyermuth <o.f@cern.ch>, 01/06/2013 + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#ifndef ROOT_TSQLiteStatement +#define ROOT_TSQLiteStatement + +#ifndef ROOT_TSQLStatement +#include "TSQLStatement.h" +#endif + +#if !defined(__CINT__) + +#ifdef R__WIN32 +#include <winsock2.h> +#else +#include <sys/time.h> +#endif + +#include <sqlite3.h> + +#else +struct sqlite3; +struct sqlite3_stmt; +#endif + + + +struct SQLite3_Stmt_t { + sqlite3 *fConn; + sqlite3_stmt *fRes; +}; + + +class TSQLiteStatement : public TSQLStatement { + +private: + SQLite3_Stmt_t *fStmt; //! executed statement + Int_t fWorkingMode; //! 1 - setting parameters, 2 - retrieving results + Int_t fNumPars; //! Number of bindable parameters + Int_t fIterationCount; //! Iteration count + + Bool_t IsSetParsMode() const { return fWorkingMode==1; } + Bool_t IsResultSetMode() const { return fWorkingMode==2; } + + Bool_t SetSQLParamType(Int_t npar, int sqltype, bool sig, int sqlsize = 0); + + long double ConvertToNumeric(Int_t npar); + const char *ConvertToString(Int_t npar); + + Bool_t CheckBindError(const char *method, int res); + +public: + TSQLiteStatement(SQLite3_Stmt_t* stmt, Bool_t errout = kTRUE); + virtual ~TSQLiteStatement(); + + virtual void Close(Option_t * = ""); + + virtual Int_t GetBufferLength() const { return 1; } + virtual Int_t GetNumParameters(); + + virtual Bool_t SetNull(Int_t npar); + virtual Bool_t SetInt(Int_t npar, Int_t value); + virtual Bool_t SetUInt(Int_t npar, UInt_t value); + virtual Bool_t SetLong(Int_t npar, Long_t value); + virtual Bool_t SetLong64(Int_t npar, Long64_t value); + virtual Bool_t SetULong64(Int_t npar, ULong64_t value); + virtual Bool_t SetDouble(Int_t npar, Double_t value); + virtual Bool_t SetString(Int_t npar, const char* value, Int_t maxsize = 256); + virtual Bool_t SetBinary(Int_t npar, void* mem, Long_t size, Long_t maxsize = 0x1000); + virtual Bool_t SetDate(Int_t npar, Int_t year, Int_t month, Int_t day); + virtual Bool_t SetTime(Int_t npar, Int_t hour, Int_t min, Int_t sec); + virtual Bool_t SetDatime(Int_t npar, Int_t year, Int_t month, Int_t day, Int_t hour, Int_t min, Int_t sec); + virtual Bool_t SetTimestamp(Int_t npar, Int_t year, Int_t month, Int_t day, Int_t hour, Int_t min, Int_t sec, Int_t frac = 0); + + virtual Bool_t NextIteration(); + + virtual Bool_t Process(); + virtual Int_t GetNumAffectedRows(); + + virtual Bool_t StoreResult(); + virtual Int_t GetNumFields(); + virtual const char *GetFieldName(Int_t nfield); + virtual Bool_t NextResultRow(); + + virtual Bool_t IsNull(Int_t npar); + virtual Int_t GetInt(Int_t npar); + virtual UInt_t GetUInt(Int_t npar); + virtual Long_t GetLong(Int_t npar); + virtual Long64_t GetLong64(Int_t npar); + virtual ULong64_t GetULong64(Int_t npar); + virtual Double_t GetDouble(Int_t npar); + virtual const char *GetString(Int_t npar); + virtual Bool_t GetBinary(Int_t npar, void* &mem, Long_t& size); + virtual Bool_t GetDate(Int_t npar, Int_t& year, Int_t& month, Int_t& day); + virtual Bool_t GetTime(Int_t npar, Int_t& hour, Int_t& min, Int_t& sec); + virtual Bool_t GetDatime(Int_t npar, Int_t& year, Int_t& month, Int_t& day, Int_t& hour, Int_t& min, Int_t& sec); + virtual Bool_t GetTimestamp(Int_t npar, Int_t& year, Int_t& month, Int_t& day, Int_t& hour, Int_t& min, Int_t& sec, Int_t&); + + ClassDef(TSQLiteStatement, 0); // SQL statement class for SQLite DB +}; + +#endif diff --git a/sql/sqlite/src/TSQLiteResult.cxx b/sql/sqlite/src/TSQLiteResult.cxx new file mode 100644 index 0000000000000..087451fe04072 --- /dev/null +++ b/sql/sqlite/src/TSQLiteResult.cxx @@ -0,0 +1,111 @@ +// @(#)root/sqlite:$Id$ +// Author: o.freyermuth <o.f@cern.ch>, 01/06/2013 + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#include "TSQLiteResult.h" +#include "TSQLiteRow.h" + +ClassImp(TSQLiteResult) + +//______________________________________________________________________________ +TSQLiteResult::TSQLiteResult(void *result) +{ + // SQLite query result. + + fResult = (sqlite3_stmt *) result; + + // RowCount is -1, as sqlite cannot determine RowCount beforehand: + fRowCount = -1; +} + +//______________________________________________________________________________ +TSQLiteResult::~TSQLiteResult() +{ + // Cleanup SQLite query result. + + if (fResult) + Close(); +} + +//______________________________________________________________________________ +void TSQLiteResult::Close(Option_t *) +{ + // Close query result. + + if (!fResult) + return; + + sqlite3_finalize(fResult); + fResult = 0; +} + +//______________________________________________________________________________ +Bool_t TSQLiteResult::IsValid(Int_t field) +{ + // Check if result set is open and field index within range. + + if (!fResult) { + Error("IsValid", "result set closed"); + return kFALSE; + } + if (field < 0 || field >= GetFieldCount()) { + Error("IsValid", "field index out of bounds"); + return kFALSE; + } + return kTRUE; +} + +//______________________________________________________________________________ +Int_t TSQLiteResult::GetFieldCount() +{ + // Get number of fields in result. + + if (!fResult) { + Error("GetFieldCount", "result set closed"); + return 0; + } + return sqlite3_column_count(fResult); +} + +//______________________________________________________________________________ +const char *TSQLiteResult::GetFieldName(Int_t field) +{ + // Get name of specified field. + + if (!fResult) { + Error("GetFieldName", "result set closed"); + return 0; + } + return sqlite3_column_name(fResult, field); +} + +//______________________________________________________________________________ +TSQLRow *TSQLiteResult::Next() +{ + // Get next query result row. The returned object must be + // deleted by the user. + + if (!fResult) { + Error("Next", "result set closed"); + return 0; + } + + int ret = sqlite3_step(fResult); + if ((ret != SQLITE_DONE) && (ret != SQLITE_ROW)) { + Error("Statement", "SQL Error: %d %s", ret, sqlite3_errmsg(sqlite3_db_handle(fResult))); + return NULL; + } + if (ret == SQLITE_DONE) { + // Finished executing, no other row! + return NULL; + } + return new TSQLiteRow((void *) fResult, -1); +} + diff --git a/sql/sqlite/src/TSQLiteRow.cxx b/sql/sqlite/src/TSQLiteRow.cxx new file mode 100644 index 0000000000000..4598edb6375e4 --- /dev/null +++ b/sql/sqlite/src/TSQLiteRow.cxx @@ -0,0 +1,86 @@ +// @(#)root/sqlite:$Id$ +// Author: o.freyermuth <o.f@cern.ch>, 01/06/2013 + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#include "TSQLiteRow.h" + + +ClassImp(TSQLiteRow) + +//______________________________________________________________________________ +TSQLiteRow::TSQLiteRow(void *res, ULong_t /*rowHandle*/) +{ + // Single row of query result. + + fResult = (sqlite3_stmt *) res; +} + +//______________________________________________________________________________ +TSQLiteRow::~TSQLiteRow() +{ + // Destroy row object. + + if (fResult) + Close(); +} + +//______________________________________________________________________________ +void TSQLiteRow::Close(Option_t *) +{ + // Close row. + + fResult = 0; +} + +//______________________________________________________________________________ +Bool_t TSQLiteRow::IsValid(Int_t field) +{ + // Check if row is open and field index within range. + + if (field < 0 || field >= (Int_t)sqlite3_column_count(fResult)) { + Error("IsValid", "field index out of bounds"); + return kFALSE; + } + return kTRUE; +} + +//______________________________________________________________________________ +ULong_t TSQLiteRow::GetFieldLength(Int_t field) +{ + // Get length in bytes of specified field. + + if (!IsValid(field)) + return 0; + + // Should call the access-method first, so sqlite3 can check whether a NULL-terminator + // needs to be added to the byte-count, e.g. for BLOB! + sqlite3_column_text(fResult, field); + + ULong_t fieldLength = (ULong_t) sqlite3_column_bytes(fResult, field); + + if (!fieldLength) { + Error("GetFieldLength", "cannot get field length"); + return 0; + } + + return fieldLength; +} + +//______________________________________________________________________________ +const char *TSQLiteRow::GetField(Int_t field) +{ + // Get specified field from row (0 <= field < GetFieldCount()). + + if (!IsValid(field)) + return 0; + + return reinterpret_cast<const char*>(sqlite3_column_text(fResult, field)); +} + diff --git a/sql/sqlite/src/TSQLiteServer.cxx b/sql/sqlite/src/TSQLiteServer.cxx new file mode 100644 index 0000000000000..48239d7f720c1 --- /dev/null +++ b/sql/sqlite/src/TSQLiteServer.cxx @@ -0,0 +1,383 @@ +// @(#)root/sqlite:$Id$ +// Author: o.freyermuth <o.f@cern.ch>, 01/06/2013 + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +#include "TSQLiteServer.h" +#include "TSQLiteResult.h" +#include "TSQLiteStatement.h" +#include "TSQLColumnInfo.h" +#include "TList.h" +#include "TSQLTableInfo.h" +#include "TSQLRow.h" + +ClassImp(TSQLiteServer) + +//______________________________________________________________________________ +TSQLiteServer::TSQLiteServer(const char *db, const char* /*uid*/, const char* /*pw*/) +{ + // Open a connection to an SQLite DB server. The db arguments should be + // of the form "sqlite://<database>", e.g.: + // "sqlite://test.sqlite" or "sqlite://:memory:" for a temporary database + // in memory. + // Note that for SQLite versions >= 3.7.7 the full string behind + // "sqlite://" is handed to sqlite3_open_v2() with SQLITE_OPEN_URI activated, + // so all URI accepted by it can be used. + + fSQLite = NULL; + fSrvInfo = "SQLite "; + fSrvInfo += sqlite3_libversion(); + + if (strncmp(db, "sqlite://", 9)) { + TString givenProtocol(db, 9); // this TString-constructor allocs len+1 and does \0 termination already. + Error("TSQLiteServer", "protocol in db argument should be sqlite it is %s", + givenProtocol.Data()); + MakeZombie(); + return; + } + + const char *dbase = db + 9; + +#ifndef SQLITE_OPEN_URI +#define SQLITE_OPEN_URI 0x00000000 +#endif +#if SQLITE_VERSION_NUMBER >= 3005000 + Int_t error = sqlite3_open_v2(dbase, &fSQLite, SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE | SQLITE_OPEN_URI, NULL); +#else + Int_t error = sqlite3_open(dbase, &fSQLite); +#endif + + if (error == 0) { + // Set members of the abstract interface + fType = "SQLite"; + fHost = ""; + fDB = dbase; + // fPort != -1 means we are 'connected' + fPort = 0; + } else { + Error("TSQLiteServer", "opening of %s failed with error: %d %s", dbase, sqlite3_errcode(fSQLite), sqlite3_errmsg(fSQLite)); + sqlite3_close(fSQLite); + MakeZombie(); + } + +} + +//______________________________________________________________________________ +TSQLiteServer::~TSQLiteServer() +{ + // Close SQLite DB. + + if (IsConnected()) { + sqlite3_close(fSQLite); + } +} + +//______________________________________________________________________________ +void TSQLiteServer::Close(Option_t *) +{ + // Close connection to SQLite DB. + + if (!fSQLite) { + return; + } + + if (IsConnected()) { + sqlite3_close(fSQLite); + // Mark as disconnected: + fPort = -1; + fSQLite = NULL; + } +} + +//______________________________________________________________________________ +Bool_t TSQLiteServer::StartTransaction() +{ + // submit "START TRANSACTION" query to database + // return kTRUE, if successful + + return Exec("BEGIN TRANSACTION"); +} + +//______________________________________________________________________________ +TSQLResult *TSQLiteServer::Query(const char *sql) +{ + // Execute SQL command. Result object must be deleted by the user. + // Returns a pointer to a TSQLResult object if successful, 0 otherwise. + // The result object must be deleted by the user. + + if (!IsConnected()) { + Error("Query", "not connected"); + return 0; + } + + sqlite3_stmt *preparedStmt = NULL; + + // -1 as we read until we encounter a \0. + // NULL because we do not check which char was read last. +#if SQLITE_VERSION_NUMBER >= 3005000 + int retVal = sqlite3_prepare_v2(fSQLite, sql, -1, &preparedStmt, NULL); +#else + int retVal = sqlite3_prepare(fSQLite, sql, -1, &preparedStmt, NULL); +#endif + if (retVal != SQLITE_OK) { + Error("Query", "SQL Error: %d %s", retVal, sqlite3_errmsg(fSQLite)); + return 0; + } + + return new TSQLiteResult(preparedStmt); +} + +//______________________________________________________________________________ +Bool_t TSQLiteServer::Exec(const char *sql) +{ + // Execute SQL command which does not produce any result sets. + // Returns kTRUE if successful. + + if (!IsConnected()) { + Error("Exec", "not connected"); + return kFALSE; + } + + char *sqlite_err_msg; + int ret = sqlite3_exec(fSQLite, sql, NULL, NULL, &sqlite_err_msg); + if (ret != SQLITE_OK) { + Error("Exec", "SQL Error: %d %s", ret, sqlite_err_msg); + sqlite3_free(sqlite_err_msg); + return kFALSE; + } + return kTRUE; +} + + +//______________________________________________________________________________ +Int_t TSQLiteServer::SelectDataBase(const char* /*dbname*/) +{ + // Select a database. Always returns non-zero for SQLite, + // as only one DB exists per file. + + Error("SelectDataBase", "SelectDataBase command makes no sense for SQLite!"); + return -1; +} + +//______________________________________________________________________________ +TSQLResult *TSQLiteServer::GetDataBases(const char* /*wild*/) +{ + // List all available databases. Always returns 0 for SQLite, + // as only one DB exists per file. + + Error("GetDataBases", "GetDataBases command makes no sense for SQLite!"); + return 0; +} + +//______________________________________________________________________________ +TSQLResult *TSQLiteServer::GetTables(const char* /*dbname*/, const char *wild) +{ + // List all tables in the specified database. Wild is for wildcarding + // "t%" list all tables starting with "t". + // Returns a pointer to a TSQLResult object if successful, 0 otherwise. + // The result object must be deleted by the user. + + if (!IsConnected()) { + Error("GetTables", "not connected"); + return 0; + } + + TString sql = "SELECT name FROM sqlite_master where type='table'"; + if (wild) + sql += Form(" AND name LIKE '%s'", wild); + + return Query(sql); +} + +//______________________________________________________________________________ +TSQLResult *TSQLiteServer::GetColumns(const char* /*dbname*/, const char* table, + const char* wild) +{ + // List all columns in specified table (database argument is ignored). + // Wild is for wildcarding "t%" list all columns starting with "t". + // Returns a pointer to a TSQLResult object if successful, 0 otherwise. + // The result object must be deleted by the user. + // For SQLite, this fails with wildcard, as the column names are not queryable! + // If no wildcard is used, the result of PRAGMA table_info(table) is returned, + // which contains the names in field 1. + + if (!IsConnected()) { + Error("GetColumns", "not connected"); + return 0; + } + + if (wild) { + Error("GetColumns", "Not implementable for SQLite as a query with wildcard, use GetFieldNames() after SELECT instead!"); + return NULL; + } else { + TString sql = Form("PRAGMA table_info('%s')", table); + return Query(sql); + } +} + +//______________________________________________________________________________ +TSQLTableInfo *TSQLiteServer::GetTableInfo(const char* tablename) +{ + // Produces SQL table info. + // Object must be deleted by user. + + if (!IsConnected()) { + Error("GetTableInfo", "not connected"); + return 0; + } + + if ((tablename==0) || (*tablename==0)) return 0; + + TSQLResult *columnRes = GetColumns("", tablename); + + if (columnRes == NULL) { + Error("GetTableInfo", "could not query columns"); + return NULL; + } + + TList* lst = NULL; + + TSQLRow *columnRow; + + while ((columnRow = columnRes->Next()) != NULL) { + if (lst == NULL) { + lst = new TList(); + } + + // Field 3 is 'notnull', i.e. if it is 0, column is nullable + Bool_t isNullable = (strcmp(columnRow->GetField(3), "0") == 0); + + lst->Add(new TSQLColumnInfo(columnRow->GetField(1), // column name + columnRow->GetField(2), // column type name + isNullable, // isNullable defined above + -1, // SQLite is totally free about types + -1, // SQLite imposes no declarable size-limits + -1, // Field length only available querying the field + -1, // no data scale in SQLite + -1)); // SQLite does not enforce any sign(s) + delete columnRow; + } + delete columnRes; + + // lst == NULL is ok as TSQLTableInfo accepts and handles this + TSQLTableInfo* info = new TSQLTableInfo(tablename, + lst); + + return info; +} + +//______________________________________________________________________________ +Int_t TSQLiteServer::CreateDataBase(const char* /*dbname*/) +{ + // Create a database. Always returns non-zero for SQLite, + // as it has only one DB per file. + + Error("CreateDataBase", "CreateDataBase command makes no sense for SQLite!"); + return -1; +} + +//______________________________________________________________________________ +Int_t TSQLiteServer::DropDataBase(const char* /*dbname*/) +{ + // Drop (i.e. delete) a database. Always returns non-zero for SQLite, + // as it has only one DB per file. + + Error("DropDataBase", "DropDataBase command makes no sense for SQLite!"); + return -1; +} + +//______________________________________________________________________________ +Int_t TSQLiteServer::Reload() +{ + // Reload permission tables. Returns 0 if successful, non-zero + // otherwise. User must have reload permissions. + + if (!IsConnected()) { + Error("Reload", "not connected"); + return -1; + } + + Error("Reload", "not implemented"); + return 0; +} + +//______________________________________________________________________________ +Int_t TSQLiteServer::Shutdown() +{ + // Shutdown the database server. Returns 0 if successful, non-zero + // otherwise. Makes no sense for SQLite, always returns -1. + + if (!IsConnected()) { + Error("Shutdown", "not connected"); + return -1; + } + + Error("Shutdown", "not implemented"); + return -1; +} + +//______________________________________________________________________________ +Bool_t TSQLiteServer::HasStatement() const +{ + // We assume prepared statements work for all SQLite-versions. + // As we actually use the recommended sqlite3_prepare(), + // or, if possible, sqlite3_prepare_v2(), + // this already introduces the "compile time check". + + return kTRUE; +} + +//______________________________________________________________________________ +TSQLStatement* TSQLiteServer::Statement(const char *sql, Int_t) +{ + // Produce TSQLiteStatement. + + if (!sql || !*sql) { + SetError(-1, "no query string specified", "Statement"); + return 0; + } + + if (!IsConnected()) { + Error("Statement", "not connected"); + return 0; + } + + sqlite3_stmt *preparedStmt = NULL; + + // -1 as we read until we encounter a \0. + // NULL because we do not check which char was read last. +#if SQLITE_VERSION_NUMBER >= 3005000 + int retVal = sqlite3_prepare_v2(fSQLite, sql, -1, &preparedStmt, NULL); +#else + int retVal = sqlite3_prepare(fSQLite, sql, -1, &preparedStmt, NULL); +#endif + if (retVal != SQLITE_OK) { + Error("Statement", "SQL Error: %d %s", retVal, sqlite3_errmsg(fSQLite)); + return 0; + } + + SQLite3_Stmt_t *stmt = new SQLite3_Stmt_t; + stmt->fConn = fSQLite; + stmt->fRes = preparedStmt; + + return new TSQLiteStatement(stmt); +} + +//______________________________________________________________________________ +const char *TSQLiteServer::ServerInfo() +{ + // Return server info, must be deleted by user. + + if (!IsConnected()) { + Error("ServerInfo", "not connected"); + return 0; + } + + return fSrvInfo.Data(); +} diff --git a/sql/sqlite/src/TSQLiteStatement.cxx b/sql/sqlite/src/TSQLiteStatement.cxx new file mode 100644 index 0000000000000..073f1bb8c54f2 --- /dev/null +++ b/sql/sqlite/src/TSQLiteStatement.cxx @@ -0,0 +1,592 @@ +// @(#)root/sqlite:$Id$ +// Author: o.freyermuth <o.f@cern.ch>, 01/06/2013 + +/************************************************************************* + * Copyright (C) 1995-2013, Rene Brun and Fons Rademakers. * + * All rights reserved. * + * * + * For the licensing terms see $ROOTSYS/LICENSE. * + * For the list of contributors see $ROOTSYS/README/CREDITS. * + *************************************************************************/ + +////////////////////////////////////////////////////////////////////////// +// // +// SQL statement class for SQLite. // +// // +// See TSQLStatement class documentation for more details. // +// // +////////////////////////////////////////////////////////////////////////// + +#include "TSQLiteStatement.h" +#include "TDataType.h" +#include "TDatime.h" +#include "TTimeStamp.h" + +#include <stdlib.h> + +ClassImp(TSQLiteStatement) + +//______________________________________________________________________________ +TSQLiteStatement::TSQLiteStatement(SQLite3_Stmt_t* stmt, Bool_t errout): + TSQLStatement(errout), + fStmt(stmt), + fWorkingMode(0), + fNumPars(0), + fIterationCount(0) +{ + // Normal constructor. + // Checks if statement contains parameters tags. + + unsigned long paramcount = sqlite3_bind_parameter_count(fStmt->fRes); + fNumPars = paramcount; + + if (paramcount > 0) { + fWorkingMode = 1; + } else { + fWorkingMode = 2; + } +} + +//______________________________________________________________________________ +TSQLiteStatement::~TSQLiteStatement() +{ + // Destructor. + + Close(); +} + +//______________________________________________________________________________ +void TSQLiteStatement::Close(Option_t *) +{ + // Close statement. + + if (fStmt->fRes) { + sqlite3_finalize(fStmt->fRes); + } + + fStmt->fRes = 0; + fStmt->fConn = 0; + delete fStmt; +} + + +// Reset error and check that statement exists +#define CheckStmt(method, res) \ + { \ + ClearError(); \ + if (fStmt==0) { \ + SetError(-1,"Statement handle is 0",method); \ + return res; \ + } \ + } + +#define CheckErrNo(method, force, res) \ + { \ + int stmterrno = sqlite3_errcode(fStmt->fConn); \ + if ((stmterrno!=0) || force) { \ + const char* stmterrmsg = sqlite3_errmsg(fStmt->fConn); \ + if (stmterrno==0) { stmterrno = -1; stmterrmsg = "SQLite statement error"; } \ + SetError(stmterrno, stmterrmsg, method); \ + return res; \ + } \ + } + +#define CheckGetField(method, res) \ + { \ + ClearError(); \ + if (!IsResultSetMode()) { \ + SetError(-1,"Cannot get statement parameters",method); \ + return res; \ + } \ + if ((npar<0) || (npar>=fNumPars)) { \ + SetError(-1,Form("Invalid parameter number %d", npar),method); \ + return res; \ + } \ + } + + +Bool_t TSQLiteStatement::CheckBindError(const char *method, int res) +{ + if (res == SQLITE_RANGE) { + SetError(-1, Form("SQLite parameter out of bounds, error: %d %s", res, sqlite3_errmsg(fStmt->fConn)), method); + return kFALSE; + } + if (res != SQLITE_OK) { + SetError(-1, Form("SQLite error code during parameter binding, error: %d %s", res, sqlite3_errmsg(fStmt->fConn)), method); + return kFALSE; + } + return kTRUE; +} + +//________________________________________________________________________ +Bool_t TSQLiteStatement::Process() +{ + // Process statement. + + CheckStmt("Process", kFALSE); + + int res = sqlite3_step(fStmt->fRes); + if ((res != SQLITE_DONE) && (res != SQLITE_ROW)) { + SetError(-1, Form("SQLite error code during statement-stepping: %d %s", res, sqlite3_errmsg(fStmt->fConn)), "Process"); + return kFALSE; + } + + // After a DONE-step, we have to reset, note this still KEEPS the parameters bound in SQLite, + // real reset happens in finalize, but user can still reuse the query! + if (res == SQLITE_DONE) { + sqlite3_reset(fStmt->fRes); + + // If IsResultSetMode then this means we are done and should return kFALSE: + if (IsResultSetMode()) { + return kFALSE; + } + + // If IsSetParsMode then this means we just stepped and should return kTRUE: + if (IsSetParsMode()) { + return kTRUE; + } + } + + if (res == SQLITE_ROW) { + // Next row data retrieved, return kTRUE. + return kTRUE; + } + + return kFALSE; +} + +//________________________________________________________________________ +Int_t TSQLiteStatement::GetNumAffectedRows() +{ + // Return number of affected rows after statement is processed. + // Indirect changes e.g. by triggers are not counted, only direct changes + // from last completed statement are taken into account. + + CheckStmt("GetNumAffectedRows", kFALSE); + + return (Int_t) sqlite3_changes(fStmt->fConn); +} + +//______________________________________________________________________________ +Int_t TSQLiteStatement::GetNumParameters() +{ + // Return number of statement parameters. + + CheckStmt("GetNumParameters", -1); + + Int_t res = sqlite3_bind_parameter_count(fStmt->fRes); + + CheckErrNo("GetNumParameters", kFALSE, -1); + + return res; +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::StoreResult() +{ + // Store result of statement processing to access them + // via GetInt(), GetDouble() and so on methods. + // For SQLite, this is a NO-OP. + + fWorkingMode = 2; + + CheckStmt("StoreResult", kFALSE); + + return kTRUE; +} + +//______________________________________________________________________________ +Int_t TSQLiteStatement::GetNumFields() +{ + // Return number of fields in result set. + + if (fWorkingMode == 1) + return sqlite3_bind_parameter_count(fStmt->fRes); + if (fWorkingMode == 2) + return sqlite3_column_count(fStmt->fRes); + return -1; +} + +//______________________________________________________________________________ +const char* TSQLiteStatement::GetFieldName(Int_t nfield) +{ + // Returns field name in result set. + + if (!IsResultSetMode() || (nfield < 0) || (nfield >= sqlite3_column_count(fStmt->fRes))) { + return 0; + } + + return sqlite3_column_name(fStmt->fRes, nfield); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::NextResultRow() +{ + // Shift cursor to next row in result set. + + ClearError(); + + if ((fStmt == 0) || !IsResultSetMode()) return kFALSE; + + if (fIterationCount == 0) { + // The interface says user should call NextResultRow() before getting any data, + // this makes no sense at least for SQLite. + // We just return kTRUE here and only do something on second request. + fIterationCount++; + return kTRUE; + } + + return Process(); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::NextIteration() +{ + // Increment iteration counter for statement, where parameter can be set. + // Statement with parameters of previous iteration + // automatically will be applied to database. + // Actually a NO-OP for SQLite, as parameters stay bound when step-ping. + + ClearError(); + + if (!IsSetParsMode()) { + SetError(-1, "Cannot call for that statement", "NextIteration"); + return kFALSE; + } + + if (fIterationCount == 0) { + // The interface says user should call NextIteration() before binding any parameters, + // this makes no sense at least for SQLite. + // We just return kTRUE here and wait for data to really do something. + fIterationCount++; + return kTRUE; + } + + fIterationCount++; + + return Process(); +} + +//______________________________________________________________________________ +const char* TSQLiteStatement::ConvertToString(Int_t npar) +{ + // Convert field value to string. + + return reinterpret_cast<const char *>(sqlite3_column_text(fStmt->fRes, npar)); +} + +//______________________________________________________________________________ +long double TSQLiteStatement::ConvertToNumeric(Int_t npar) +{ + // Convert field to numeric. + + return (long double) sqlite3_column_double(fStmt->fRes, npar); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::IsNull(Int_t npar) +{ + // Checks if field value is null. + + CheckGetField("IsNull", kFALSE); + + return (sqlite3_column_type(fStmt->fRes, npar) == SQLITE_NULL); +} + +//______________________________________________________________________________ +Int_t TSQLiteStatement::GetInt(Int_t npar) +{ + // Get integer. + + return (Int_t) sqlite3_column_int(fStmt->fRes, npar); +} + +//______________________________________________________________________________ +UInt_t TSQLiteStatement::GetUInt(Int_t npar) +{ + // Get unsigned integer. + + return (UInt_t) sqlite3_column_int(fStmt->fRes, npar); +} + +//______________________________________________________________________________ +Long_t TSQLiteStatement::GetLong(Int_t npar) +{ + // Get long. + + return (Long_t) sqlite3_column_int64(fStmt->fRes, npar); +} + +//______________________________________________________________________________ +Long64_t TSQLiteStatement::GetLong64(Int_t npar) +{ + // Get long64. + + return (Long64_t) sqlite3_column_int64(fStmt->fRes, npar); +} + +//______________________________________________________________________________ +ULong64_t TSQLiteStatement::GetULong64(Int_t npar) +{ + // Return field value as unsigned 64-bit integer + + return (ULong64_t) sqlite3_column_int64(fStmt->fRes, npar); +} + +//______________________________________________________________________________ +Double_t TSQLiteStatement::GetDouble(Int_t npar) +{ + // Return field value as double. + + return (Double_t) sqlite3_column_double(fStmt->fRes, npar); +} + +//______________________________________________________________________________ +const char *TSQLiteStatement::GetString(Int_t npar) +{ + // Return field value as string. + + return reinterpret_cast<const char *>(sqlite3_column_text(fStmt->fRes, npar)); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::GetBinary(Int_t npar, void* &mem, Long_t& size) +{ + // Return field value as binary array. + // Memory at 'mem' will be reallocated and size updated + // to fit the data if not large enough. + + // As we retrieve "as blob", we do NOT call sqlite3_column_text() before + // sqlite3_column_bytes(), which might leave us with a non-zero terminated + // data struture, but this should be okay for BLOB. + size_t sz = sqlite3_column_bytes(fStmt->fRes, npar); + if ((Long_t)sz > size) { + delete [](unsigned char*) mem; + mem = (void*) new unsigned char[sz]; + } + size = sz; + + memcpy(mem, sqlite3_column_blob(fStmt->fRes, npar), sz); + + return kTRUE; +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::GetDate(Int_t npar, Int_t& year, Int_t& month, Int_t& day) +{ + // Return field value as date. + + TString val = reinterpret_cast<const char*>(sqlite3_column_text(fStmt->fRes, npar)); + TDatime d = TDatime(val.Data()); + year = d.GetYear(); + month = d.GetMonth(); + day = d.GetDay(); + + return kTRUE; +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::GetTime(Int_t npar, Int_t& hour, Int_t& min, Int_t& sec) +{ + // Return field as time. + + TString val = reinterpret_cast<const char*>(sqlite3_column_text(fStmt->fRes, npar)); + TDatime d = TDatime(val.Data()); + hour = d.GetHour(); + min = d.GetMinute(); + sec = d.GetSecond(); + + return kTRUE; +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::GetDatime(Int_t npar, Int_t& year, Int_t& month, Int_t& day, Int_t& hour, Int_t& min, Int_t& sec) +{ + // Return field value as date & time. + + TString val = reinterpret_cast<const char*>(sqlite3_column_text(fStmt->fRes, npar)); + TDatime d = TDatime(val.Data()); + year = d.GetYear(); + month = d.GetMonth(); + day = d.GetDay(); + hour = d.GetHour(); + min = d.GetMinute(); + sec = d.GetSecond(); + + return kTRUE; +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::GetTimestamp(Int_t npar, Int_t& year, Int_t& month, Int_t& day, Int_t& hour, Int_t& min, Int_t& sec, Int_t& frac) +{ + // Return field as timestamp. + // Second fraction is in milliseconds, which is also the precision all date and time functions of sqlite use. + + TString val = reinterpret_cast<const char*>(sqlite3_column_text(fStmt->fRes, npar)); + + Ssiz_t p = val.Last('.'); + TSubString ts_part = val(0, p); + + TDatime d(ts_part.Data()); + year = d.GetYear(); + month = d.GetMonth(); + day = d.GetDay(); + hour = d.GetHour(); + min = d.GetMinute(); + sec = d.GetSecond(); + + TSubString s_frac = val(p, val.Length() - p+1); + frac=(Int_t) (atof(s_frac.Data())*1.E3); + + return kTRUE; +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetNull(Int_t npar) +{ + // Set NULL as parameter value. + + int res = sqlite3_bind_null(fStmt->fRes, npar + 1); + + return CheckBindError("SetNull", res); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetInt(Int_t npar, Int_t value) +{ + // Set parameter value as integer. + + int res = sqlite3_bind_int(fStmt->fRes, npar + 1, value); + + return CheckBindError("SetInt", res); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetUInt(Int_t npar, UInt_t value) +{ + // Set parameter value as unsigned integer. + // Actually casted to signed integer, has to be re-casted upon read! + + int res = sqlite3_bind_int(fStmt->fRes, npar + 1, (Int_t)value); + + return CheckBindError("SetUInt", res); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetLong(Int_t npar, Long_t value) +{ + // Set parameter value as long. + + int res = sqlite3_bind_int64(fStmt->fRes, npar + 1, value); + + return CheckBindError("SetLong", res); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetLong64(Int_t npar, Long64_t value) +{ + // Set parameter value as 64-bit integer. + + int res = sqlite3_bind_int64(fStmt->fRes, npar + 1, value); + + return CheckBindError("SetLong64", res); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetULong64(Int_t npar, ULong64_t value) +{ + // Set parameter value as unsigned 64-bit integer. + // Actually casted to signed integer, has to be re-casted upon read! + + int res = sqlite3_bind_int64(fStmt->fRes, npar + 1, (Long64_t)value); + + return CheckBindError("SetULong64", res); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetDouble(Int_t npar, Double_t value) +{ + // Set parameter value as double value. + + int res = sqlite3_bind_double(fStmt->fRes, npar + 1, value); + + return CheckBindError("SetDouble", res); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetString(Int_t npar, const char* value, Int_t maxsize) +{ + // Set parameter value as string. + + int res = sqlite3_bind_text(fStmt->fRes, npar + 1, value, maxsize, SQLITE_TRANSIENT); + + return CheckBindError("SetString", res); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetBinary(Int_t npar, void* mem, Long_t size, Long_t /*maxsize*/) +{ + // Set parameter value as binary data. + // Maxsize is ignored for SQLite, we directly insert BLOB of size 'size'. + // Negative size would cause undefined behaviour, so we refuse that. + + if (size < 0) { + SetError(-1, "Passing negative value to size for BLOB to SQLite would cause undefined behaviour, refusing it!", "SetBinary"); + return kFALSE; + } + + int res = sqlite3_bind_blob(fStmt->fRes, npar + 1, mem, (size_t)size, SQLITE_TRANSIENT); + + return CheckBindError("SetBinary", res); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetDate(Int_t npar, Int_t year, Int_t month, Int_t day) +{ + // Set parameter value as date. + + TDatime d = TDatime(year, month, day, 0, 0, 0); + int res = sqlite3_bind_text(fStmt->fRes, npar + 1, (char*)d.AsSQLString(), -1, SQLITE_TRANSIENT); + + return CheckBindError("SetDate", res); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetTime(Int_t npar, Int_t hour, Int_t min, Int_t sec) +{ + // Set parameter value as time. + + TDatime d = TDatime(2000, 1, 1, hour, min, sec); + + int res = sqlite3_bind_text(fStmt->fRes, npar + 1, (char*)d.AsSQLString(), -1, SQLITE_TRANSIENT); + + return CheckBindError("SetTime", res); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetDatime(Int_t npar, Int_t year, Int_t month, Int_t day, Int_t hour, Int_t min, Int_t sec) +{ + // Set parameter value as date & time. + + TDatime d = TDatime(year, month, day, hour, min, sec); + + int res = sqlite3_bind_text(fStmt->fRes, npar + 1, (char*)d.AsSQLString(), -1, SQLITE_TRANSIENT); + + return CheckBindError("SetDatime", res); +} + +//______________________________________________________________________________ +Bool_t TSQLiteStatement::SetTimestamp(Int_t npar, Int_t year, Int_t month, Int_t day, Int_t hour, Int_t min, Int_t sec, Int_t frac) +{ + // Set parameter value as timestamp. + // The second fraction has to be in milliseconds, + // as all SQLite functions for date and time assume 3 significant digits. + + TDatime d(year,month,day,hour,min,sec); + TString value; + value.Form("%s.%03d", (char*)d.AsSQLString(), frac); + + int res = sqlite3_bind_text(fStmt->fRes, npar + 1, value.Data(), -1, SQLITE_TRANSIENT); + + return CheckBindError("SetTimestamp", res); +} diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 54355b348e031..7e3091c271eb9 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -11,8 +11,12 @@ find_package(ROOT REQUIRED) include(${ROOT_USE_FILE}) include_directories(${ROOT_INCLUDE_DIRS}) -include_directories(${ROOT_INCLUDE_DIRS}/../tutorials) - +if(DEFINED ROOT_SOURCE_DIR) # Testing using the binary tree + include_directories(${ROOT_SOURCE_DIR}/tutorials) + include_directories(${ROOT_SOURCE_DIR}/tmva/inc) +else() + include_directories(${ROOT_INCLUDE_DIRS}/../tutorials) +endif() #---environment------------------------------------------------------------------------------- ROOT_ADD_TEST(show-environment COMMAND ${CMAKE_COMMAND} -E environment) @@ -138,11 +142,17 @@ if(ROOT_roofit_FOUND) ROOT_ADD_TEST(test-stressroofit COMMAND stressRooFit FAILREGEX "FAILED") endif() +#--stressRooStats---------------------------------------------------------------------------------- +if(ROOT_roofit_FOUND) + ROOT_EXECUTABLE(stressRooStats stressRooStats.cxx LIBRARIES RooStats) + ROOT_ADD_TEST(test-stressroostats COMMAND stressRooStats FAILREGEX "FAILED") +endif() + #--stressFit--------------------------------------------------------------------------------- ROOT_EXECUTABLE(stressFit stressFit.cxx LIBRARIES MathCore Matrix) ROOT_ADD_TEST(test-stressfit COMMAND stressFit FAILREGEX "FAILED") -#--stressHitoFit----------------------------------------------------------------------------- +#--stressHistoFit----------------------------------------------------------------------------- if(ROOT_unuran_FOUND) ROOT_EXECUTABLE(stressHistoFit stressHistoFit.cxx LIBRARIES MathCore Matrix Unuran Tree Gpad) ROOT_ADD_TEST(test-stresshistofit COMMAND stressHistoFit FAILREGEX "FAILED") @@ -158,9 +168,13 @@ ROOT_ADD_TEST(test-stressiterators COMMAND stressIterators FAILREGEX "FAILED") #--stressInterpreter------------------------------------------------------------------------- ROOT_EXECUTABLE(stressInterpreter stressInterpreter.cxx LIBRARIES Core) +if(WIN32) + set(cleantmpfiles POSTCMD cmd /c del AutoDict_*) +endif() ROOT_ADD_TEST(test-stressinterpreter COMMAND stressInterpreter PRECMD ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/stressInterpreter.cxx $<TARGET_FILE_DIR:stressInterpreter>/stressInterpreter.cxx + ${cleantmpfiles} FAILREGEX "FAILED|Error") #--stressHepix------------------------------------------------------------------------------- @@ -169,8 +183,12 @@ ROOT_ADD_TEST(test-stressinterpreter COMMAND stressInterpreter #--stressProof------------------------------------------------------------------------------- if(NOT WIN32) + add_custom_target(TestData ALL COMMAND ${CMAKE_COMMAND} -DDST=${CMAKE_SOURCE_DIR}/files -P ${CMAKE_CURRENT_SOURCE_DIR}/rootDownloadData.cmake) ROOT_EXECUTABLE(stressProof stressProof.cxx LIBRARIES Proof ProofPlayer Hist) - ROOT_ADD_TEST(test-stressproof COMMAND stressProof lite:// FAILREGEX "FAILED") + ROOT_ADD_TEST(test-stressproof COMMAND stressProof lite:// + -h1 ${CMAKE_SOURCE_DIR}/files/h1 -event ${CMAKE_SOURCE_DIR}/files/event + -l /tmp/stressProof-%d.log -cleanlog -noprogress + FAILREGEX "FAILED") endif() #--testbits---------------------------------------------------------------------------------- diff --git a/test/Makefile b/test/Makefile index 1d27a205184b8..1a3e1680a2e5c 100644 --- a/test/Makefile +++ b/test/Makefile @@ -9,13 +9,26 @@ RC := root-config ifeq ($(shell which $(RC) 2>&1 | sed -ne "s@.*/$(RC)@$(RC)@p"),$(RC)) MKARCH := $(wildcard $(shell $(RC) --etcdir)/Makefile.arch) +RCONFIG := $(wildcard $(shell $(RC) --incdir)/RConfigure.h) endif ifneq ($(MKARCH),) include $(MKARCH) else +ifeq ($(ROOTSYS),) ROOTSYS = .. +endif include $(ROOTSYS)/etc/Makefile.arch endif +# Tutorials dir needed by stressProof +ifneq ($(RCONFIG),) +TUTDIR := $(wildcard $(shell grep ROOTDOCDIR $(RCONFIG) | sed "s|.*\"\(.*\)\"|\1|")/tutorials) +endif +ifeq ($(TUTDIR),) +ifeq ($(ROOTSYS),) +ROOTSYS = .. +endif +TUTDIR := $(ROOTSYS)/tutorials +endif -include ../MyConfig.mk #------------------------------------------------------------------------------ @@ -261,28 +274,36 @@ STRESSHISTO = stressHistogram.$(ObjSuf) STRESSHISTS = stressHistogram.$(SrcSuf) STRESSHIST = stressHistogram$(ExeSuf) +ifeq ($(shell $(RC) --has-sqlite),yes) +SQLITETESTO = sqlitetest.$(ObjSuf) +SQLITETESTS = sqlitetest.$(SrcSuf) +SQLITETEST = sqlitetest$(ExeSuf) +endif + -OBJS = $(EVENTO) $(MAINEVENTO) $(EVENTMTO) $(HWORLDO) $(HSIMPLEO) $(MINEXAMO) \ +OBJS = $(EVENTO) $(MAINEVENTO) $(EVENTMTO) $(HWORLDO) $(HSIMPLEO) \ + $(MINEXAMO) \ $(TSTRINGO) $(TCOLLEXO) $(VVECTORO) $(VMATRIXO) $(VLAZYO) \ $(HELLOO) $(ACLOCKO) $(STRESSO) $(TBENCHO) $(BENCHO) \ $(STRESSSHAPESO) $(TCOLLBMO) $(STRESSGEOMETRYO) $(STRESSLO) \ - $(STRESSGO) $(STRESSSPO) $(TESTBITSO) \ + $(STRESSGO) $(STRESSSPO) $(TESTBITSO) \ $(CTORTUREO) $(QPRANDOMO) $(THREADSO) $(STRESSVECO) \ - $(STRESSMATHO) $(STRESSFITO) $(STRESSHISTOFITO) $(STRESSHEPIXO) \ - $(STRESSENTRYLISTO) $(STRESSROOFITO) $(STRESSROOSTATSO) $(STRESSPROOFO) \ - $(STRESSMATHMOREO) $(STRESSTMVAO) $(STRESSINTERPO) $(STRESSITERO) \ - $(STRESSHISTO) $(STRESSGUIO) - -PROGRAMS = $(EVENT) $(EVENTMTSO) $(HWORLD) $(HSIMPLE) $(MINEXAM) $(TSTRING) \ - $(TCOLLEX) $(TCOLLBM) $(VVECTOR) $(VMATRIX) $(VLAZY) \ - $(HELLOSO) $(ACLOCKSO) $(STRESS) $(TBENCHSO) $(BENCH) \ + $(STRESSMATHO) $(STRESSFITO) $(STRESSHISTOFITO) \ + $(STRESSHEPIXO) $(STRESSENTRYLISTO) $(STRESSROOFITO) \ + $(STRESSROOSTATSO) $(STRESSPROOFO) $(STRESSMATHMOREO) \ + $(STRESSTMVAO) $(STRESSINTERPO) $(STRESSITERO) \ + $(STRESSHISTO) $(STRESSGUIO) $(SQLITETESTO) + +PROGRAMS = $(EVENT) $(EVENTMTSO) $(HWORLD) $(HSIMPLE) $(MINEXAM) \ + $(TSTRING) $(TCOLLEX) $(TCOLLBM) $(VVECTOR) $(VMATRIX) \ + $(VLAZY) $(HELLOSO) $(ACLOCKSO) $(STRESS) $(TBENCHSO) $(BENCH) \ $(STRESSSHAPES) $(STRESSGEOMETRY) $(STRESSL) $(STRESSG) \ $(TESTBITS) $(CTORTURE) $(QPRANDOM) $(THREADS) $(STRESSSP) \ $(STRESSVEC) $(STRESSFIT) $(STRESSHISTOFIT) $(STRESSHEPIX) \ - $(STRESSENTRYLIST) $(STRESSROOFIT) $(STRESSROOSTATS) $(STRESSPROOF) $(STRESSMATH) \ - $(STRESSMATHMORE) $(STRESSTMVA) $(STRESSINTERP) $(STRESSITER) \ - $(STRESSHIST) $(STRESSGUI) - + $(STRESSENTRYLIST) $(STRESSROOFIT) $(STRESSROOSTATS) \ + $(STRESSPROOF) $(STRESSMATH) \ + $(STRESSMATHMORE) $(STRESSTMVA) $(STRESSINTERP) $(STRESSITER) \ + $(STRESSHIST) $(STRESSGUI) $(SQLITETEST) OBJS += $(GUITESTO) $(GUIVIEWERO) $(TETRISO) PROGRAMS += $(GUITEST) $(GUIVIEWER) $(TETRISSO) @@ -689,12 +710,12 @@ else endif endif -$(STRESSINTERP): $(STRESSINTERPO) +$(STRESSINTERP): $(STRESSINTERPO) $(LD) $(LDFLAGS) $^ $(LIBS) $(OutPutOpt)$@ $(MT_EXE) @echo "$@ done" -$(STRESSITER): $(STRESSITERO) +$(STRESSITER): $(STRESSITERO) $(LD) $(LDFLAGS) $^ $(LIBS) $(OutPutOpt)$@ $(MT_EXE) @echo "$@ done" @@ -704,14 +725,21 @@ $(STRESSHIST): $(STRESSHISTO) $(MT_EXE) @echo "$@ done" +$(SQLITETEST): $(SQLITETESTO) + $(LD) $(LDFLAGS) $^ $(LIBS) $(OutPutOpt)$@ + $(MT_EXE) + @echo "$@ done" + clean: @rm -f $(OBJS) $(TRACKMATHSRC) core *Dict.* distclean: clean + -@(mv -f stressRooStats_ref.root stressRooStats_ref.root- >/dev/null 2>&1;true) @rm -f $(PROGRAMS) $(EVENTSO) $(EVENTLIB) *Dict.* *.def *.exp \ *.root *.ps *.so *.lib *.dll *.d *.log .def so_locations \ - files/* + files/* testdb.sqlite @rm -rf cxx_repository + -@(mv -f stressRooStats_ref.root- stressRooStats_ref.root >/dev/null 2>&1;true) -@cd RootShower && $(MAKE) distclean -@cd rhtml && $(MAKE) distclean -@cd RootIDE && $(MAKE) distclean @@ -766,7 +794,7 @@ TrackMathCoreDict.$(SrcSuf): TrackMathCore.h TrackMathCoreLinkDef.h $(ROOTCINT) -f $@ -c $^ stressProof.$(ObjSuf): stressProof.$(SrcSuf) - $(CXX) $(CXXFLAGS) -I$(ROOTSYS)/tutorials -c $< + $(CXX) $(CXXFLAGS) -I$(TUTDIR) -c $< TrackMathCoreRflx.$(SrcSuf): TrackMathCore.h TrackMathCoreRflx.xml @echo "Generating dictionary $@ using gccxml ..." diff --git a/test/Makefile.win32 b/test/Makefile.win32 index 80cfdf969e93e..cd1782388ffb6 100644 --- a/test/Makefile.win32 +++ b/test/Makefile.win32 @@ -47,6 +47,13 @@ ExeSuf = .exe DllSuf = dll OutPutOpt = -out: +## VS2012 (VC11): configure subsystem version +## See: https://blogs.msdn.com/b/vcblog/archive/2012/10/08/10357555.aspx +## (APPVER used in win32.mak to set subsystem version) +!if ([nmake /? 2>&1 | findstr /c:"Version 11\." > nul ] == 0) +APPVER = 5.01 +!endif + # Win32 system with Microsoft Visual C/C++ !include <win32.mak> CC = $(cc) @@ -74,7 +81,9 @@ LDOPT = -debug MT_EXE = mt -nologo -manifest $@.manifest -outputresource:$@;1 MT_DLL = mt -nologo -manifest $@.manifest -outputresource:$@;2 EXTRAFLAGS = -D_CRT_SECURE_NO_DEPRECATE -!else if ([nmake /? 2>&1 | findstr /c:"Version 10\." > nul ] == 0) +!else if ([nmake /? 2>&1 | findstr /c:"Version 10\." > nul ] == 0) || \ + ([nmake /? 2>&1 | findstr /c:"Version 11\." > nul ] == 0) || \ + ([nmake /? 2>&1 | findstr /c:"Version 12\." > nul ] == 0) EXTRAFLAGS = -D_CRT_SECURE_NO_DEPRECATE !else MT_EXE = @@ -103,6 +112,8 @@ GLIBS = $(LIBS) $(ROOTSYS)\lib\libGui.lib $(ROOTSYS)\lib\libGraf.lib \ LIBSALL = $(ROOTLIBS) EVENTLIB = libEvent.lib +# Tutorials dir needed by stressProof +TUTDIR = $(ROOTSYS)/tutorials #------------------------------------------------------------------------------ @@ -242,6 +253,12 @@ STRESSROOFITS = stressRooFit.$(SrcSuf) STRESSROOFIT = stressRooFit$(ExeSuf) !endif +!if exist("$(ROOTSYS)\lib\libRooStats.lib") +STRESSROOSTATSO = stressRooStats.$(ObjSuf) +STRESSROOSTATSS = stressRooStats.$(SrcSuf) +STRESSROOSTATS = stressRooStats$(ExeSuf) +!endif + STRESSFITO = stressFit.$(ObjSuf) STRESSFITS = stressFit.$(SrcSuf) STRESSFIT = stressFit$(ExeSuf) @@ -290,9 +307,13 @@ THREADSO = threads.$(ObjSuf) THREADSS = threads.$(SrcSuf) THREADS = threads$(ExeSuf) -STRESSITERO = stressIterators.$(ObjSuf) -STRESSITERS = stressIterators.$(SrcSuf) -STRESSITER = stressIterators$(ExeSuf) +STRESSINTERPO = stressInterpreter.$(ObjSuf) +STRESSINTERPS = stressInterpreter.$(SrcSuf) +STRESSINTERP = stressInterpreter$(ExeSuf) + +STRESSITERO = stressIterators.$(ObjSuf) +STRESSITERS = stressIterators.$(SrcSuf) +STRESSITER = stressIterators$(ExeSuf) STRESSHISTO = stressHistogram.$(ObjSuf) STRESSHISTS = stressHistogram.$(SrcSuf) @@ -306,9 +327,9 @@ OBJS = $(EVENTO) $(MAINEVENTO) $(EVENTMTO) $(HWORLDO) $(HSIMPLEO) $(MIN $(STRESSGO) $(STRESSSPO) $(TESTBITSO) \ $(CTORTUREO) $(QPRANDOMO) $(THREADSO) $(STRESSVECO) \ $(STRESSMATHO) $(STRESSFITO) $(STRESSHISTOFITO) $(STRESSHEPIXO) \ - $(STRESSENTRYLISTO) $(STRESSROOFITO) $(STRESSPROOFO) \ - $(STRESSMATHMOREO) $(STRESSTMVAO) $(STRESSITERO) $(STRESSHISTO) \ - $(GUITESTO) $(GUIVIEWERO) $(TETRISO) $(STRESSGUIO) \ + $(STRESSENTRYLISTO) $(STRESSROOFITO) $(STRESSROOSTATSO) $(STRESSPROOFO) \ + $(STRESSMATHMOREO) $(STRESSTMVAO) $(STRESSINTERPO) $(STRESSITERO) \ + $(STRESSHISTO) $(STRESSGUIO) $(GUITESTO) $(GUIVIEWERO) $(TETRISO) \ PROGRAMS = $(EVENT) $(EVENTMTSO) $(HWORLD) $(HSIMPLE) $(MINEXAM) $(TSTRING) \ $(TCOLLEX) $(TCOLLBM) $(VVECTOR) $(VMATRIX) $(VLAZY) \ @@ -316,9 +337,9 @@ PROGRAMS = $(EVENT) $(EVENTMTSO) $(HWORLD) $(HSIMPLE) $(MINEXAM) $(TSTRING) $(STRESSSHAPES) $(STRESSGEOMETRY) $(STRESSL) $(STRESSG) \ $(TESTBITS) $(CTORTURE) $(QPRANDOM) $(THREADS) $(STRESSSP) \ $(STRESSVEC) $(STRESSFIT) $(STRESSHISTOFIT) $(STRESSHEPIX) \ - $(STRESSENTRYLIST) $(STRESSROOFIT) $(STRESSPROOF) $(STRESSMATH) \ - $(STRESSMATHMORE) $(STRESSTMVA) $(STRESSITER) $(STRESSHIST) \ - $(GUITEST) $(GUIVIEWER) $(TETRISSO) $(STRESSGUI) \ + $(STRESSENTRYLIST) $(STRESSROOFIT) $(STRESSROOSTATS) $(STRESSPROOF) $(STRESSMATH) \ + $(STRESSMATHMORE) $(STRESSTMVA) $(STRESSINTERP) $(STRESSITER) \ + $(STRESSHIST) $(STRESSGUI) $(GUITEST) $(GUIVIEWER) $(TETRISSO) \ all: $(PROGRAMS) @@ -485,7 +506,14 @@ $(STRESSSHAPES): $(STRESSSHAPESO) !if exist("$(ROOTSYS)\lib\libRooFit.lib") $(STRESSROOFIT): $(STRESSROOFITO) - $(LD) $(LDFLAGS) $(STRESSROOFITO) $(LIBS) $(ROOTSYS)\lib\libRooFit.lib $(ROOTSYS)\lib\libRooFitCore.lib $(ROOTSYS)\lib\libHtml.lib $(ROOTSYS)\lib\libThread.lib $(ROOTSYS)\lib\libMinuit.lib $(OutPutOpt)$@ + $(LD) $(LDFLAGS) $(STRESSROOFITO) $(LIBS) $(ROOTSYS)\lib\libRooFit.lib $(ROOTSYS)\lib\libRooFitCore.lib $(ROOTSYS)\lib\libHtml.lib $(ROOTSYS)\lib\libThread.lib $(ROOTSYS)\lib\libMinuit.lib $(OutPutOpt)$@ + $(MT_EXE) + @echo "$@ done" +!endif + +!if exist("$(ROOTSYS)\lib\libRooStats.lib") +$(STRESSROOSTATS): $(STRESSROOSTATSO) + $(LD) $(LDFLAGS) $(STRESSROOSTATSO) $(LIBS) $(ROOTSYS)\lib\libRooStats.lib $(ROOTSYS)\lib\libRooFit.lib $(ROOTSYS)\lib\libRooFitCore.lib $(OutPutOpt)$@ $(MT_EXE) @echo "$@ done" !endif @@ -543,6 +571,11 @@ $(TBENCHSO): $(TBENCHO) $(LD) $(SOFLAGS) $(LDFLAGS) $(TBENCHO) $(LIBS) $(OutPutOpt)$@ $(MT_DLL) +$(STRESSINTERP): $(STRESSINTERPO) + $(LD) $(LDFLAGS) $(STRESSINTERPO) $(LIBS) $(OutPutOpt)$@ + $(MT_EXE) + @echo "$@ done" + $(STRESSITER): $(STRESSITERO) $(LD) $(LDFLAGS) $(STRESSITERO) $(LIBS) $(OutPutOpt)$@ $(MT_EXE) @@ -601,6 +634,9 @@ TrackMathCoreDict.$(SrcSuf): TrackMathCore.h TrackMathCoreLinkDef.h @echo "Generating dictionary $@ using rootcint ..." @rootcint -f $@ -c TrackMathCore.h TrackMathCoreLinkDef.h +stressProof.$(ObjSuf): stressProof.$(SrcSuf) + $(CXX) $(CXXFLAGS) $(EXTRAFLAGS) $(CXXOPT) -I$(TUTDIR) -c $** + .$(SrcSuf).$(ObjSuf): $(CXX) $(CXXFLAGS) $(EXTRAFLAGS) $(CXXOPT) -c $< diff --git a/test/RootShower/MyParticle.cxx b/test/RootShower/MyParticle.cxx index f6482e7e73593..c2e35300e8aa6 100644 --- a/test/RootShower/MyParticle.cxx +++ b/test/RootShower/MyParticle.cxx @@ -117,7 +117,7 @@ MyParticle::MyParticle(Int_t id, Int_t pType,Int_t pStat,Int_t pDecayType,const //______________________________________________________________________________ char *MyParticle::GetObjectInfo(Int_t, Int_t) const { - // Returns particle informations. + // Returns particle information. static char info[64]; sprintf(info,"Particle = %s, E = %1.3e", GetName(), Energy()); diff --git a/test/RootShower/RSHelpText.cxx b/test/RootShower/RSHelpText.cxx index c7f9de3c8b926..6e387adcd1f2a 100644 --- a/test/RootShower/RSHelpText.cxx +++ b/test/RootShower/RSHelpText.cxx @@ -107,7 +107,7 @@ const char gSimulationHelpText[] = "status :\n" " Waiting to start simulation \n" " Done - Total particles : xxx - Waiting for next simulation \n" -"You can access informations on current event by selecting Infos into the\n" +"You can access information on current event by selecting Infos into the\n" "Event menu.\n" "Select 3D View into this same menu to have a 3D view of the event into\n" "a new OpenGL window. It is also possible to do this with the context menu\n" diff --git a/test/RootShower/RootShower.cxx b/test/RootShower/RootShower.cxx index 803032045089c..56bfa3a22463d 100644 --- a/test/RootShower/RootShower.cxx +++ b/test/RootShower/RootShower.cxx @@ -1071,13 +1071,13 @@ void RootShower::OnShowerProduce() fHisto_dEdX->Fill(fEvent->GetParticle(i)->GetELoss()); for (j=0;j<fEvent->GetParticle(i)->GetNTracks();j++) fEvent->GetParticle(i)->GetTrack(j)->Draw(); - // show track by track if "show process" has been choosen + // show track by track if "show process" has been chosen // into the menu if (fShowProcess) { fCA->Modified(); fCA->Update(); // create one gif image by step if "Animated GIF" - // has been choosen into the menu + // has been chosen into the menu if (fCreateGIFs) { fCA->SaveAs("RSEvent.gif+"); } diff --git a/test/bench.cxx b/test/bench.cxx index 524305aa0d1e5..4b3b9daf8c931 100644 --- a/test/bench.cxx +++ b/test/bench.cxx @@ -305,7 +305,7 @@ int main(int argc, char **argv) } printf("* Reference machine pcbrun4.cern.ch RedHat Linux 7.3 *\n"); printf("* (Pentium IV 2.4 Ghz 512 Mbytes RAM, IDE disk) *\n"); - printf("* (send your results to rootdev@root.cern.ch) *\n"); + printf("* (send your results to rootdev@cern.ch) *\n"); printf("*******************************************************************************\n"); printf("* Time to fill the structures (seconds) Reference cx Reference *\n"); printf("*******************************************************************************\n"); diff --git a/test/guitest.cxx b/test/guitest.cxx index 91aa4975417ba..358024decf66e 100644 --- a/test/guitest.cxx +++ b/test/guitest.cxx @@ -1946,7 +1946,7 @@ void TestFileList::DoMenu(Int_t mode) if (mode<10) { fContents->SetViewMode((EListViewMode)mode); } else { - delete this; // Close menu entry choosen + delete this; // Close menu entry chosen } } diff --git a/test/histviewer/histaction.cxx b/test/histviewer/histaction.cxx index c3af527cbe094..fbe024ef688df 100644 --- a/test/histviewer/histaction.cxx +++ b/test/histviewer/histaction.cxx @@ -1007,7 +1007,7 @@ Bool_t HistAction::toDefault(Window_t id) // Does not redraw the button. // So to visually change the color needs to be followed by // the function NeedRedraw(TGWindow *). - // Input paramater - ID of the button to which the action must be applied. + // Input parameter - ID of the button to which the action must be applied. // //------------------------------------------------------------------ diff --git a/test/ios/RootBrowser/AxisFontInspector.h b/test/ios/RootBrowser/AxisFontInspector.h deleted file mode 100644 index 0d36edc185eb5..0000000000000 --- a/test/ios/RootBrowser/AxisFontInspector.h +++ /dev/null @@ -1,25 +0,0 @@ -#import "ObjectInspectorComponent.h" - -namespace ROOT_IOSObjectInspector { - -enum AxisFontInspectorMode{ -afimTitleFont, -afimLabelFont -}; - -} - -@interface AxisFontInspector : UIViewController <UIPickerViewDelegate, UIPickerViewDataSource, ObjectInspectorComponent> { -@private - __weak IBOutlet UILabel *titleLabel; - __weak IBOutlet UIPickerView *fontPicker; -} - -- (id)initWithNibName : (NSString *)nibName mode : (ROOT_IOSObjectInspector::AxisFontInspectorMode)m; - -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)o; - -- (IBAction) back; - -@end diff --git a/test/ios/RootBrowser/AxisInspector.h b/test/ios/RootBrowser/AxisInspector.h deleted file mode 100644 index 463030d16a61c..0000000000000 --- a/test/ios/RootBrowser/AxisInspector.h +++ /dev/null @@ -1,19 +0,0 @@ -#import <UIKit/UIKit.h> - -#import "ObjectInspectorComponent.h" - -@interface AxisInspector : UIViewController <ObjectInspectorComponent, UITabBarDelegate> { -@private - __weak IBOutlet UITabBar *tabBar; -} - -+ (CGRect) inspectorFrame; - -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)o; -- (NSString *) getComponentName; -- (void) resetInspector; - - - -@end diff --git a/test/ios/RootBrowser/AxisInspector.xib b/test/ios/RootBrowser/AxisInspector.xib deleted file mode 100644 index e4754913a9ed1..0000000000000 --- a/test/ios/RootBrowser/AxisInspector.xib +++ /dev/null @@ -1,4646 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<archive type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="7.10"> - <data> - <int key="IBDocument.SystemTarget">1056</int> - <string key="IBDocument.SystemVersion">11B26</string> - <string key="IBDocument.InterfaceBuilderVersion">1617</string> - <string key="IBDocument.AppKitVersion">1138</string> - <string key="IBDocument.HIToolboxVersion">566.00</string> - <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> - <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string key="NS.object.0">534</string> - </object> - <object class="NSArray" key="IBDocument.IntegratedClassDependencies"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>IBUITabBar</string> - <string>IBUIView</string> - <string>IBUITabBarItem</string> - <string>IBProxyObject</string> - </object> - <object class="NSArray" key="IBDocument.PluginDependencies"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - </object> - <object class="NSMutableDictionary" key="IBDocument.Metadata"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys" id="0"> - <bool key="EncodedWithXMLCoder">YES</bool> - </object> - <reference key="dict.values" ref="0"/> - </object> - <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBProxyObject" id="841351856"> - <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBProxyObject" id="606714003"> - <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBUIView" id="13398906"> - <reference key="NSNextResponder"/> - <int key="NSvFlags">292</int> - <object class="NSMutableArray" key="NSSubviews"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBUITabBar" id="943058069"> - <reference key="NSNextResponder" ref="13398906"/> - <int key="NSvFlags">266</int> - <string key="NSFrameSize">{250, 49}</string> - <reference key="NSSuperview" ref="13398906"/> - <reference key="NSNextKeyView"/> - <string key="NSReuseIdentifierKey">_NS:518</string> - <object class="NSColor" key="IBUIBackgroundColor"> - <int key="NSColorSpace">10</int> - <object class="NSImage" key="NSImage"> - <int key="NSImageFlags">549453824</int> - <string key="NSSize">{256, 256}</string> - <object class="NSMutableArray" key="NSReps"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray"> - <bool key="EncodedWithXMLCoder">YES</bool> - <integer value="0"/> - <object class="NSBitmapImageRep"> - <object class="NSData" key="NSTIFFRepresentation"> - <bytes key="NS.bytes">TU0AKgAEAAh1eIH/cHJ5/3Bzff9vcXX/bnB3/3Byef9vcXX/bG51/2xudf9ucHf/cHN9/2dqdP9ucXv/ -cHJ5/3Bzff9qbHP/b3F1/3N1fP9sbnX/am13/2ptd/9sbnX/am13/3l7gf91d33/bG95/2xudf9sb3n/ -bG95/2dqdP9qbXf/c3V8/3Bzff93eoP/bG51/3Bzff9sbnX/dXd9/2dqdP9qbHP/bG51/2psc/9sb3n/ -am13/2ptd/9sb3n/bG51/3V3ff97fYP/YmVu/25xe/9sb3n/c3Z//2psc/9zdXz/cHN9/2dqcf9qbHP/ -YmVu/2dqdP9nanH/am13/2xvef91eIH/Z2p0/25xe/91d33/bG51/25wd/92eHz/dXd9/29xdf9ucHf/ -eHl9/2xudf9ucHf/bG95/3Bzff9sb3n/bnF7/3l7gf9zdn//c3Z//3N2f/91eIH/c3V8/3Byef9nanT/ -bnB3/3Byef91d33/dHZ8/2psc/9sbnX/Z2p0/3N1fP9qbXf/cXN6/2psdf9wcnv/dnd9/25xe/9ucHf/ -bnB3/2ptd/92eH//a254/3Fzev9sb3n/cHJ5/25wd/9ucHf/cHN9/25wd/9wcnn/dnh8/2xudf93eX// -dXd9/2dqdP9ucXv/dXd9/3N2f/9zdXz/Z2px/2xudf9ucXv/am13/3Bzff9zdXz/cHN9/2psc/9qbXf/ -bG51/2Jlbv9qbXf/aGp0/2hqcP9rbnX/cnV//29yfP9ucXv/bnF7/25xe/9zdn//bXB1/2xvef9qbXb/ -Zmly/2Jlbv9kZ3H/Zmhu/2Rncf9kZ3H/Zmlz/2Zpc/9kZ3H/bnB3/2Jlbv9nanT/ZGdx/2Zobv9zdXz/ -ZGdx/2xvef9maXP/foCG/2xvef9ucXv/bG95/25wd/9wc33/b3F1/3l8hv91eIH/cHN9/3N1fP9sb3n/ -d3qD/25wd/9zdn//cHJ5/3Bzff9wcnn/cHN9/3Bzff9ucXv/d3l//2ptd/9ucXv/c3Z//3N2f/9wcnn/ -bnF7/3N2f/9ucHf/cHJ5/3Bzff9sb3n/cHJ5/25xe/9wc33/bnF7/3Byef9zdXz/bnB3/25xe/9zdXz/ -d3l//3N2f/9sb3n/bnB3/3Bzff9sb3n/bnF7/25wd/9wcnn/cHJ5/3Byef9sbnX/c3V8/2psc/9zdXz/ -dnh8/3Byef9kZ3H/am13/25xe/9sb3n/bnF7/25xe/9zdn//Z2p0/2xudf95e4H/Z2p0/2xvef9ucXv/ -bG51/2psc/9ucXv/cHJ5/2psc/9qbXf/Z2px/2ptd/9qbHP/cHN9/2ptd/9sbnX/bG51/3V3ff9wcnn/ -c3V8/3Byef9wc33/d3l//29xdf9zdXz/bnB3/2ptd/9qbXf/Z2px/2Zpc/9kZ3H/am13/2xvef9nanH/ -cHJ5/29xdf9wcnn/Z2px/2xudf9zdXz/b3F1/25wd/9ucHf/bnB3/25wd/9+gIb/eHl9/3N1fP9wcnn/ -cHJ5/3Byef9qbHP/bG51/3Z4fP9wcnn/dXiB/2xudf9ucXv/bG51/3Byef9nanH/ZGdx/2Zpc/9nanH/ -Z2px/2Zobv9iZW7/Zmhu/2Zobv9qbXf/c3Z//1lcZf9maXP/Z2p0/3Byef9kZ3H/bG95/2xvef9qbHP/ -am13/2Zpc/9qbXf/bG51/2xvef9wc33/dXd9/2dqdP9sb3n/dXd9/2dqdP9ucHf/c3V8/3V3ff9qbXf/ -bnF7/3d5f/9ucHf/bG51/2xudf9wc33/bG51/2xudf91d33/bnB3/3Byef9wcnn/cHJ5/29xdf9ucHf/ -Z2p0/3Byef9wc33/eXuB/3d5f/9sb3n/bnF7/2psc/9zdXz/b3F5/29yev9qbHX/bnB4/3d5f/9wcnn/ -bnB3/2xudf9ucHf/dHZ7/25wd/9ucXn/bW92/3Byef9ucHf/bG51/3N1fP9ucXv/cHN9/3V3ff9qbHP/ -dnh8/3V3ff9nanH/bnB3/3V3ff9ucHf/cHJ5/2Zpc/9qbXf/bG95/2xudf9sb3n/dXd9/3Z4fP9vcXX/ -bnF7/25wd/9nanH/c3Z//3Bzff9wcnn/bnB3/3R2ff9ucXr/bnF7/3Bzff9sb3n/dXd9/25xev90dnz/ -dXiA/3V4gP9wcnn/c3Z//3Bzff9ucXv/cHN9/3N2f/9zdn//bG95/3d6g/9sb3n/c3Z//3Bzff9ucHf/ -d3l//2dqcf9qbXf/Z2p0/3d6g/9sbnX/am13/2Zpc/9nanT/am13/2Zobv9zdXz/bnB3/2dqdP9kZ3H/ -ZGZs/3Byef9gY2z/Z2px/2Rncf9maG7/YGNs/2Zobv9kZ3H/Zmhu/2ptd/9gY2z/ZGdx/2Rncf9nanT/ -ZGdx/2psc/9maXP/ZGdx/2Zobv9maG7/YmVu/2Zpc/9qbHP/am13/2psc/9ucXv/cHN9/2xudf9nanT/ -bnF7/3V3ff9wcnn/bnB3/29xdf9zdXz/bG95/3Bzff9sb3n/c3Z//3N2f/91eIH/bnF7/3V4gf9ucXv/ -dXiB/3l7gf9zdn//am13/3Byef9zdn//cHN9/3N2f/91eIH/e36H/3Bzff9wc33/foCG/3V4gf93eoP/ -eXuB/3N2f/9ucXv/dXiB/3V3ff9vcXX/c3V8/25wd/91d33/c3V8/3d5f/9wc33/cHJ5/25wd/93eX// -c3Z//3Bzff9ucXv/cHN9/3V3ff9vcXX/c3V8/25wd/9vcXX/bnB3/2xvef9nanT/Zmhu/2ptd/9sb3n/ -Zmlz/3Byef9tb3P/bnF7/2xudf9ucHf/dXd9/2xvef9sb3n/bG95/25xe/9ucXv/e36H/3l7gf9zdn// -c3Z//3V4gf93eoP/c3Z//3N2f/9+gYr/eXyG/4GDiv9wc33/d3qD/3N1fP93eX//cHJ5/3Bzff9wc33/ -bnF7/25xe/9ucHf/b3F1/3Byef9ucXv/eXuB/36Ahv9nanT/c3Z//3Byef93eX//bW9z/3Z4fP91d33/ -bnB3/25xe/9nanT/bG95/25wd/9ucXv/dXiB/3l8hv9ucHf/c3Z//3V4gf9ucHf/dXiB/3N2f/91d33/ -am13/29xdf91d33/bnB3/2xvef9ucXv/d3qD/25xe/9wcnn/c3Z//25wd/9ucHf/cHJ5/3V3ff9vcXX/ -cHJ5/2xudf9vcXX/bG51/3Byef9ucXj/aGty/21vc/9nanT/cHN9/25wd/9vcnr/a212/21wev91d33/ -am13/2xudf9maXP/am13/3R2e/9tb3b/bnF6/2xudf9wcnn/am13/2xudf9ucXv/bG95/25xe/9wc33/ -ZGdx/3Byef9ucHf/YmVu/2psc/9wc33/bnF7/2ptd/9maG7/bW9z/25wd/9sbnX/c3V8/3d5f/91d33/ -b3F1/25xe/9ucXv/Z2p0/3V3ff9wc33/bnF7/21vdv9zdnz/cHJ5/25weP9zdXz/bnF7/3l7gf9xc3r/ -d3mA/3d5f/9zdX3/b3F1/3N1fP9sbnX/bG51/25wd/9sbnX/cHJ5/2psc/92eHz/amxz/3Bzff9ucHf/ -bW9z/3h5ff9nanH/bG51/2Jlbv91eIH/amxz/2Zpc/9iZW7/YmVu/2dqdP9maG7/c3Z//3N1fP9qbXf/ -Z2p0/2dqdP91eIH/ZGdx/2xudf9nanT/am13/2ptd/9ucXv/bnF7/21vc/91eIH/Zmlz/25wd/9wcnn/ -bnB3/25wd/9vcXX/cHJ5/21vc/9sbnX/bG95/2dqdP9sbnX/bG51/2xvef9sbnX/bnF7/25xe/9nanT/ -bnF7/3Bzff91d33/cHN9/2ptd/9qbHP/bnF7/2Zpc/9qbXf/YmVu/2ptd/9qbHP/bG95/2Rncf9ucXv/ -ZGdx/25xe/9zdXz/bG95/2Rncf9tb3P/bG95/25wd/91d33/dXiB/3t9g/9ucHf/c3V8/3t9g/9ucXv/ -dXiB/3d5f/9wcnn/bnF7/3N2f/95e4H/cHN9/3V4gf9ucXv/d3qD/3V4gf93eX//c3Z//3N1fP9zdXz/ -d3l//3Bzff9ucXv/bnF7/3N1fP9zdXz/bG51/2xvef9nanH/Z2px/2dqdP9qbHP/YmVu/2BjbP9sbnX/ -bG51/2Rncf9sb3n/bG51/2ptd/9maXP/Z2px/25xe/9qbHP/Zmlz/2Zpc/9qbHP/Z2p0/3V4gf91d33/ -cHN9/25wd/9sb3n/am13/2Zpc/9sb3n/dXd9/3Bzff91eIH/bW9z/25xe/9sbnX/c3V8/21vc/9sbnX/ -cHN9/2ptd/9qbXf/bnF7/2ptd/9sbnX/bG51/3Byef93eX//ZGdx/2xvef9ucXv/dXd9/2xudf92eHz/ -dXd9/25wd/9sbnX/amxz/2xvef9vcXX/bnB3/3Bzff93eoP/bG95/3Bzff9zdn//bG95/3N2f/9wc33/ -dXiB/25xe/9zdXz/e32D/3Bzff9ucHf/bnF7/3V3ff9vcXX/b3F1/3N1fP9tb3P/bG51/3Byef9zdXz/ -bW9z/3Byef9nanH/amxz/2psc/9ucHf/bnB3/2psc/9sbnX/amxz/3V3fP9ucHj/bW93/2psdf9vcnr/ -dXd8/25wd/9qbXf/Z2p0/25xe/9zdoD/bXB6/3J0fP9wcnf/c3V8/29xdf9ucHf/bnF7/3Byef9zdXz/ -cHN9/2ptd/91d33/eHl9/2psc/9zdXz/dnh8/3N1fP9ucXv/Zmhu/29xdf9ucHf/bnB3/25wd/92eHz/ -cHJ5/2xudf9wcnn/bG95/2Rncf9wc33/bnF7/2ttdP9maXP/bnF5/2lsdf9laHL/am13/2ptd/9zdXz/ -bm92/3R3fv91d33/bnB3/21vc/9zdXz/bW9z/3Byef9ucHf/bnB3/3N1fP9nanH/d3l//25wd/97fYP/ -c3Z//3Bzff97fYP/bnF7/21vc/9maG7/eXuB/2ptd/9qbXf/ZGdx/2Zobv9nanT/Z2px/3N2f/9wcnn/ -am13/2ptd/9qbXf/d3qD/2Rncf9qbXf/Z2p0/2xvef9qbXf/Z2p0/2ptd/9maXP/d3l//2Rncf9qbXf/ -bnB3/2ptd/9qbXf/bG51/25xe/9tb3P/bnB3/25wd/9qbHP/bG51/2xudf9qbXf/bG51/3N1fP9zdXz/ -bG51/3N1fP91d33/dXd9/25xe/9sbnX/bW9z/3Bzff9maXP/bG51/2Rncf9nanT/Z2px/2ptd/9nanT/ -bnF7/2dqdP9wc33/cHJ5/2psc/9dYGr/bG51/2ptd/9sb3n/c3V8/2ptd/91eIH/bG51/2ptd/9zdn// -am13/25xe/9sb3n/Z2p0/2psc/9nanT/bG95/2xudf9ucXv/amxz/2xvef9sb3n/cHN9/2dqcf9maXP/ -Zmlz/25xe/9sb3n/am13/2ptd/9nanT/d3l//25xe/9zdn//bnB3/25xe/9wc33/cHN9/25xe/9qbXf/ -cHJ5/3Bzff9sb3n/cHN9/25wd/9wcnn/bnB3/29xdf94eX3/cHN9/25wd/9wc33/bnB3/25xe/97fYP/ -dXiB/3V3ff9sb3n/c3V8/3Byef9sbnX/c3V8/3V3ff9ucXv/c3V8/2psc/9ucXv/am13/3N1fP9sbnX/ -bG51/3V3ff9ucHf/cHJ5/3Byef9sb3n/bnB3/25wd/92eHz/gIKG/25wd/91d33/c3V8/3d5f/9ucHf/ -dnh8/3Z4fP9ucHf/bG51/2xudf9sbnX/bG51/2ptd/9sb3n/dXiB/2Zpc/9sb3n/Zmlz/2Jlbv9qbXf/ -Z2p0/2dqdP9iZW7/YGNs/2xvef9kZ3H/YGNs/2Zpc/9kZ3H/Zmhu/2Jlbv9qbXf/ZGdx/2Zpc/9qbXf/ -bnF7/2xudf9sb3n/Zmlz/2ptd/9sbnX/am13/21wef9laHH/am13/2dqdP9zdXz/bW92/25weP9rbnj/ -b3F6/3N2fv9ucXX/bG51/2dqcf9sb3n/b3J8/2xud/9ucXr/bW9z/25xe/9ucHf/bnB3/3Byef9ucHf/ -dXd9/3N1fP9sbnX/cHJ5/3V3ff9kZ3H/am13/3N1fP9wcnn/bG95/2Jlbv9nanT/am13/2ptd/9qbXf/ -d3l//25xe/9qbXf/bnF7/2ptd/9iZW7/am13/2ptd/9nanL/Z2ly/29xef9ucHf/amxz/3N1fP9wcnn/ -cHN9/3Byef9ydX7/dXd9/29xdv9rbnj/cHJ5/25wd/9wc33/bnB3/25wd/9zdXz/amxz/3d5f/9wcnn/ -d3l//29xdf9wcnn/eXuB/2xvef9vcXX/Z2px/3t9g/9sb3n/cHN9/2xvef9ucHf/cHJ5/25xe/9+f4P/ -dXd9/3Byef9qbXf/bG51/35/g/9qbHP/cHJ5/2xvef91d33/bnB3/25xe/9zdn//bG95/3l7gf9maG7/ -bnB3/2xvef9qbXf/am13/2psc/9qbXf/bG51/2psc/9sbnX/Zmlz/2Zpc/9nanH/Z2px/2Rncf9qbXf/ -Zmlz/2Jlbv9nanT/bG95/2xvef9kZ3H/Zmhu/2Jlbv9nanT/YGNs/2Rncf9dYGr/ZGdx/2Rncf9qbXf/ -ZGdx/2xvef9iZW7/Z2p0/2ptd/9maG7/XWBq/2psc/9nanT/am13/3N1fP9ucXv/eXyG/2ptd/9nanT/ -dXd9/25wd/9zdXz/cHJ5/3Byef9vcXX/bnF7/3Bzff9wcnn/eXuB/3N1fP91eIH/dXiB/3l8hv9zdXz/ -cHJ5/25xe/95e4H/d3qD/3N2f/9zdn//cHN9/3l7gf9zdXz/bnF7/25wd/9wc33/cHN9/3N2f/9sb3n/ -bG95/3Byef9wc33/bG95/25xe/9ucXv/cHJ5/25wd/9ucHf/eXuB/3N2f/9ucHf/bG95/25wd/9wc33/ -d3qD/3d5f/91d33/bG51/3Byef9sbnX/amxz/3N1fP94eX3/dXd9/3V4gf9ucHf/cHJ5/3Byef92eHz/ -bG95/3Bzff93eoP/c3Z//3N2f/9zdXz/bnB3/25wd/9zdXz/eHl9/3+Bh/9ucHf/dnh8/3Byef93eX// -bnB3/3d6g/95e4H/bnB3/3Byef9sbnX/bnB3/2psc/9qbXf/am13/3l8hv9maXP/bnF7/2psc/9kZ3H/ -bnF7/2xvef9ucXv/amxz/2ptd/91d33/bG51/2psc/9wc33/cHN9/2xudf9maXP/cHN9/2dqcf9nanT/ -amxz/2dqdP9sbnX/am13/2Zpc/9sb3n/bG51/2xvef9sbnj/ZWhy/2dqdP9nanH/bnF7/2ttdf9rbnb/ -a252/29xeP90dnz/am13/2ptd/9nanH/cHJ5/3N1fP9tcHj/bnF6/2dqdP9qbHP/Zmhu/2psc/9nanT/ -amxz/2dqdP9qbXf/YGNs/2dqdP91d33/YmVu/2xudf9sb3n/am13/2xudf9iZW7/am13/2xvef9ucXv/ -bG51/3d5f/9ucXv/am13/3Byef9ucHf/ZGdx/25xe/9sb3n/am13/2lsdP9wcnv/b3J7/21vd/9zdXz/ -bnB3/3Bzff9rbXT/a254/25xe/9rbXX/bW9z/25wd/9tb3P/b3F1/2xvef9wcnn/c3V8/2ptd/93eX// -bnB3/3V4gf9ucXv/cHJ5/3d6g/9qbXf/bG51/2Jlbv91eIH/am13/25xe/9maXP/amxz/2ptd/9qbXf/ -e32D/3N1fP9qbXf/bG51/2psc/91eIH/YGNs/2Zpc/9kZ3H/Z2p0/2Zpc/9nanH/bG95/2Rncf9zdXz/ -YGNs/2Zpc/9nanT/amxz/2Zpc/9qbHP/bG95/2xudf9qbHP/bG51/2Zpc/9nanT/amxz/2ptd/9maXP/ -cHN9/25xe/9maXP/am13/3Bzff91d33/bG95/2xvef9tb3P/dXd9/25wd/9ucHf/Zmlz/25wd/9tb3P/ -c3V8/21vc/92eHz/bnB3/3h5ff94eX3/bG51/2dqcf9sb3n/bnF7/25xe/9zdXz/cHJ5/36Ahv9wc33/ -c3V8/3l7gf9zdXz/bnF7/25xe/9sbnX/bG51/3N1fP9zdXz/b3F1/3N1fP9ucHf/c3V8/3Byef91d33/ -b3F1/2xudf9sb3n/dnh8/3Z4fP9zdXz/cHN9/3Bzff94eX3/b3F1/3Bzff9qbHP/bnB3/2xvef9wc33/ -ZGdx/2dqdP9nanT/am13/2ptd/9ucHf/cHJ5/3Byef9sbnX/bG51/3V3ff92eHz/amxz/25xe/9ucHf/ -cHN9/3d5f/93eX//c3V8/21vc/9zdXz/bW9z/2xudf9zdn//d3qD/3V4gf95e4H/bnF7/3N2f/91eIH/ -e32D/3Byef91eIH/eXuB/3d6g/93eoP/d3qD/3Bzff9wc33/bnF7/3V4gf+Bg4r/bG95/3V3ff9wc33/ -eXuB/25xe/97fof/eXuB/3N1fP9zdn//bG95/3V4gf9wcnn/d3qD/3V4gf9/gYf/cHJ5/3d6g/9wc33/ -bG95/3V4gf9zdn//dXiB/3N1fP9zdXz/eXyG/3V4gf9zdn//e32D/3l7gf9zdn//c3V8/3d6g/9ucHf/ -bnF7/2xvef9wc33/bG95/25xe/9qbXf/cHJ5/25wd/9wcnn/cnR6/21vdv9sb3n/bnB3/3Bzff9tcHr/ -cXN7/25wd/9vcXr/bnB6/2xudf9sbnX/Z2px/3V3ff9ydX7/b3J8/2tueP9rbXT/am13/2xudf9sbnX/ -bG51/3Byef9zdXz/cHJ5/2RmbP9ucHf/dXd9/2Rncf9qbXf/bG95/2dqdP9sbnX/YmVu/2ptd/9qbXf/ -bG95/2xudf91d33/bG95/2xudf9zdXz/bG51/2Zobv9wcnn/cHJ5/2xvef9rbnf/c3V+/3F0fv9sb3n/ -c3V8/3N1fP9zdXz/bnB0/29xeP90dnz/bW94/3Byef9wc33/b3F1/25wd/9tb3P/cHJ5/3Byef9qbHP/ -dXd9/2ptd/91d33/amxz/2xudf9zdXz/YmVu/25wd/9nanH/eXuB/25wd/9ucHf/bnB3/25wd/9wcnn/ -b3F1/36Ahv91d33/bnB3/2xudf9tb3P/fn+D/2psc/9sbnX/bnB3/25xe/9sbnX/amxz/25xe/9nanT/ -d3l//2Rncf9sbnX/bnB3/21vc/9nanH/b3F1/3Bzff9ucHf/bnB3/25xe/9sb3n/c3V8/3Byef91d33/ -b3F1/3h5ff9zdXz/bG51/3Byef91d33/dXiB/3V4gf9wc33/cHN9/3N2f/9sb3n/bnF7/2dqdP9wcnn/ -bW9z/3N1fP9sbnX/cHN9/2ptd/91d33/dXd9/2xudf9iZW7/am13/2ptd/9qbXf/bnF7/3Byef9zdn// -bnF7/25xe/9zdn//cHN9/25xe/9ucXv/bG51/2ptd/9sb3n/bnF7/2ptd/9sb3n/bnB3/25wd/9wcnn/ -dXd9/2xudf9maXP/Z2p0/3Z4fP9zdXz/dXd9/3N1fP9ucHf/dnh8/2ptd/9ucXv/ZGdx/2psc/9maXP/ -am13/2Jlbv9kZ3H/ZGdx/2Rncf9iZW7/Zmlz/2Zpc/9qbXf/ZGdx/2dqcf9sb3n/bnF7/2Rncf9qbXf/ -amxz/25xe/9zdXz/dXd9/2xvef9sbnX/cHN9/21vc/9qbHP/dXd9/3V3ff91d33/eHl9/25wd/9vcXX/ -bnB3/3Z4fP9ucHf/c3Z//3Z4fP91d33/cHJ5/3N1fP9ucHf/bnB3/25wd/91d33/f4KM/3Byef9zdn// -bnF7/3d5f/9sb3n/e32D/3h5ff9ucHf/cHN9/2ptd/9zdn//bG95/3Bzff9wcnn/e36H/25wd/9wc33/ -bG95/2ptd/9zdn//dXiB/3V3ff9sb3n/bnB3/3d6g/9ucXv/bnB3/3N2f/9zdn//bnB3/2xudf9wcnn/ -bW9z/29xdf9ucHf/bnB3/2xvef9wcnn/cHN9/3Bzff9wcnn/c3Z//3N2f/9xc3r/cHJ5/3N2f/93eoP/ -cHN9/3h6gP9zdXr/d3l//3h7hP9zdn//cHN9/2dqdP93eoL/dnmB/3N2fv9wcnr/bnB3/25wd/9vcXX/ -cHJ5/25wd/91d33/dXd9/3N1fP9maG7/bnB3/3l7gf9maG7/bG51/2ptd/9sbnX/amxz/2Jlbv9sbnX/ -cHN9/2ptd/9nanH/c3V8/2dqdP9nanH/Zmlz/2Zobv9ZXGX/ZGdx/2Zpc/9iZW7/YmVt/2xud/9sb3f/ -a210/29yef9wcnn/dnh8/29xdf9tcHr/bnF7/2Zpcv9naXD/Z2pz/2Jlbv9kZmz/Zmhu/2dqdP9nanT/ -ZGdx/25wd/9maXP/c3V8/2psc/9maXP/cHJ5/2Jlbv9wcnn/bnF7/3+Bh/9zdn//dXiB/3N1fP9wc33/ -cHN9/2xvef97fYP/cHN9/2xvef9sb3n/cHJ5/3+Bh/9sb3n/cHN9/3Byef9zdn//c3V8/3Byef9zdn// -bG95/3t+h/9sb3n/dXiB/3d6g/9wcnn/am13/3Byef9wc33/cHJ5/25xe/9zdn//cHJ5/3l7gf91eIH/ -eXyG/3d6g/95fIb/d3qD/3Bzff91eIH/d3l//3l8hv91d33/cHN9/2xvef9wc33/am13/3Byef9sbnX/ -cHJ5/29xdf91d33/bG95/3Bzff9ucHf/d3qD/3h5ff9sbnX/Zmlz/2xvef9wcnn/cHJ5/3Byef91d33/ -dXiB/3d5f/9wc33/e36H/3l7gf9wc33/c3Z//25wd/9wc33/d3qD/3Bzff9wcnn/cHN9/25xe/9wc33/ -c3V8/3h5ff9vcXX/amxz/2psc/92eHz/cHJ5/3Bzff9ucXv/bG51/3V4gf9ucXv/c3V8/2dqcf9sbnX/ -cHJ5/3N1fP9qbHP/bG51/29xdf9zdXz/bW9z/2xudf9wcnn/cHJ5/2xudf9sb3n/c3V8/3Z4fP9sb3n/ -cHN9/25xe/9zdn//dXd9/3d5f/9wc33/bG95/3N2f/9ucXv/bnB3/3d5f/95e4H/d3l//3d5f/9sb3n/ -cHJ5/29xdf92eHz/bnB3/3N1fP92eHz/dXd9/3N1fP9wcnn/b3F1/2xudf9wc33/dXd9/4CChv9tb3P/ -bnF7/2xudf91d33/bW9z/3d5f/92eHz/bW9z/2xudf9nanH/cHN9/2xvef9wcnn/bnB3/3d5f/9ucHf/ -cHN9/2xvef9sb3n/dXd9/3N2f/91d33/bnB3/25wd/95e4H/bG95/25wd/9wc33/dnh8/2xudf9qbHP/ -bnB3/21vc/9sbnX/bG95/2ptd/9ucHf/bnB3/25wd/9wcnn/bW9z/3N1fP9xc3r/a253/2psc/9nanT/ -bnF7/2dqdP9vcnz/aWx2/29xev9sb3n/amxz/2xudf9iZW7/cHN9/3R2fP9xdH3/bW93/2hrcv9sb3n/ -bG51/2xvef9sbnX/dXd9/3V3ff9wcnn/amxz/2xudf93eX//Z2px/2ptd/9qbXf/am13/2xvef9maG7/ -bW9z/25wd/9wcnn/b3F1/3N1fP9sbnX/bG51/2xvef9wcnn/Zmhu/2xvef9qbXf/Zmlz/2Vocv9sb3n/ -cXR7/2xvef9zdXz/c3V8/3V3ff9ucHT/bnB1/3R2fP9sb3j/b3F2/21vdf9tb3P/bG51/25wd/9zdXz/ -c3V8/2psc/93eX//am13/3d5f/9sbnX/am13/3d5f/9sbnX/bG51/2ptd/97fYP/dXd9/3Byef9vcXX/ -cHJ5/2xvef9ucHf/eXuB/2xvef9qbXf/am13/2xudf9+gIb/amxz/3Byef9ucHf/cHJ5/25wd/9ucHf/ -bnB3/2Zpc/91d33/Z2px/3N2f/9wcnn/bnB3/2psc/9sb3n/cHN9/3N1fP9zdn//dXiB/3Byef95fIb/ -dXiB/3d6g/93eoP/e36H/3l8hv9wc33/dXiB/3l7gf9+gYr/foCG/3d6g/93eoP/d3qD/3V3ff93eoP/ -cHN9/3d6g/91eIH/e32D/3Bzff9zdn//bnB3/3l7gf94eX3/c3Z//2dqdP9zdn//c3Z//3N2f/9ucHf/ -d3l//3l7gf97fYP/d3qD/3+CjP97fof/eXuB/3l7gf91d33/dXiB/3l7gf93eoP/cHJ5/3Bzff9ucXv/ -c3Z//25xe/97fYP/c3V8/2xvef9sb3n/d3l//3N2f/9wc33/cHJ5/2xvef9ucXv/am13/3Byef9sbnX/ -bW9z/25xe/9ucXv/ZGdx/2dqdP9qbHP/cHJ5/2dqcf9maG7/bG95/2dqdP9kZ3H/ZGdx/2ptd/9wc33/ -Z2p0/2ptd/9nanH/bG95/3N1fP9wc33/bG95/2xudf9zdXz/am13/2dqdP9ucXv/c3V8/3V3ff91d33/ -bG51/25xe/9sbnX/bG95/2ptd/9ucXv/bnF7/3V3ff92eHz/cHJ5/2xudf9tb3P/c3V8/3d5f/+Agob/ -bW9z/2xvef9sb3n/eHl9/2xudf93eoP/dXd9/2ptd/9qbXf/Zmlz/3N1fP9wcnn/c3Z//3Bzff97fof/ -cHJ5/3N2f/9sb3n/bG51/3V3ff9zdXz/c3V8/25wd/9ucHf/dXiB/25xe/9sb3n/cHN9/3N2f/9tb3P/ -bG51/3N1fP9sb3n/cHN9/3Bzff9sb3n/bnB3/25xe/9ucHf/cHJ5/21vc/91d33/c3V6/21wef9ucHf/ -bnB3/3N1fP9ucHf/cXN7/2xud/9wcnn/dHZ9/25wd/9ucHf/Z2px/3V3ff90dnv/cXR7/25wd/9lZ3D/ -amxz/2xudf9qbXf/am13/3Bzff9ucXv/bnF7/2Zpc/9sbnX/c3V8/2Rncf9maXP/Zmlz/2dqcf9maXP/ -XWBq/2dqcf9nanT/Z2p0/2Zpc/9sb3n/Z2px/2dqcf9qbXf/am13/2Jlbv9qbXf/bG51/2Vocf9oa3T/ -b3J5/3J1f/9tcHr/dHeA/3V4gf97fYP/dXd9/3Z4f/95e4H/bG93/21vdv9tb3b/bG51/2ptd/9tb3P/ -dXd9/3Byef9sbnX/d3l//2xudf92eHz/bG51/2xudf93eX//bG51/2xvef9sb3n/d3qD/3N2f/9ucXv/ -bG95/3Byef9ucHf/bnB3/3d5f/9ucHf/bG51/2ptd/9ucHf/gYOK/2ptd/9zdn//cHJ5/3N2f/9wcnn/ -bnB3/2xvef9qbXf/eXuB/2dqcf95e4H/dXiB/3N2f/9wc33/dXd9/3l7gf91d33/dXd9/3d6g/91d33/ -fX6B/3t9g/9/gYf/foCG/36Ahv97fYP/eHl9/3l7gf9+f4P/gYOK/36Ahv95e4H/d3qD/3N2f/91d33/ -d3qD/3Bzff9wc33/cHN9/3l7gf9zdn//dXiB/3N1fP9/gYf/e36H/3V4gf9sb3n/c3Z//3Bzff9wc33/ -bnF7/3Z4fP9zdXz/dXd9/25xe/93eX//dnh8/3V3ff94eX3/bnB3/25wd/91d33/cHJ5/25wd/9ucHf/ -bnB3/3N1fP9wcnn/dnh8/29xdf9qbHP/bG51/3Z4fP9wcnn/c3V8/25wd/9qbXf/bnF7/25wd/9zdn// -am13/25wd/9zdXz/dXd9/2ptd/9vcXX/bG51/3N1fP9sbnX/am13/3N1fP9ucXv/bG51/2xudf9wcnn/ -eHl9/2ptd/9zdXz/c3V8/3V4gf93eoP/eXuB/3l7gf9zdXz/e32D/3V4gf9zdXz/d3qD/3t9g/9+gIb/ -foGK/3N2f/97fYP/dXiB/3d6g/9wc33/dXiB/3N2f/91eIH/c3Z//3Bzff9ucHf/bnB3/3N1fP92eHz/ -gIKG/2xvef9ucHf/bnB3/3Z4fP9qbXf/c3Z//3N1fP9qbHP/am13/2BjbP9ucXv/Z2p0/25xe/9wc33/ -dXiB/2xudf9sb3n/bG95/2ptd/9wc33/cHN9/3N1fP9tb3P/am13/3V3ff9qbXf/Z2px/2xvef9ucXv/ -amxz/2Zpc/9sb3n/bG95/25xe/9sb3n/bG51/2xudf9qbXf/Zmlz/2Zpc/9maG7/am13/2tueP9nanT/ -Zmlz/2Zpc/9nanT/Z2lv/2ptd/9maXL/a252/2xvef9qbHP/am13/2Rncf9sb3n/b3J8/3Bze/9sbnT/ -Z2lw/2xudf9wcnn/bnB3/3N1fP92eHz/cHJ5/3Byef9qbHP/bG95/3l7gf9qbXf/cHJ5/3d6g/9zdn// -c3Z//2ptd/9wc33/dXiB/3d6g/9wcnn/d3qD/3Bzff9wcnn/c3Z//3Bzff9maXP/bnF7/25xe/9sb3n/ -bG95/3N2f/9xdH7/am12/25wd/9ucXv/dXd9/2xudf9tb3b/cnV8/21veP9vcXj/bnB3/25wd/9wcnn/ -bW9z/3N1fP9zdXz/bG51/3d5f/9tb3P/dXd9/21vc/9sbnX/dXd9/2dqdP9maXP/Z2p0/3d5f/9zdXz/ -bnB3/2xudf91d33/bG95/2ptd/93eoP/c3Z//25xe/9sb3n/bnB3/4GDiv9qbXf/bG95/25wd/9ucXv/ -cHJ5/25xe/9ucHf/Z2px/3Z4fP9lZmr/c3V8/25wd/9tb3P/Z2p0/2dqcf9sb3n/amxz/2psc/9maXP/ -YmVu/2xvef9qbXf/bG95/2xvef91d33/bnF7/2xudf9sbnX/c3V8/3V3ff91d33/bG95/2xvef9qbXf/ -am13/2xvef9qbHP/cHJ5/2xudf91d33/bG51/3N1fP9vcXX/e32D/3d6g/9wc33/Z2p0/3Bzff91d33/ -c3V8/25wd/9zdn//d3l//3d5f/91d33/dXiB/3d5f/93eX//eXuB/25xe/9wc33/dXiB/3V4gf9zdn// -d3qD/35/g/97fYP/dXiB/3t+h/9zdn//bnF7/3Byef93eX//cHN9/3N2f/9wc33/bnB3/3Bzff9qbXf/ -c3V8/2dqcf9ucHf/c3V8/3N1fP9sbnX/bG51/2xudf9wc33/bG95/2ptd/9zdXz/c3V8/2psc/9sbnX/ -bnF7/3Z4fP9sbnX/bG51/2psc/9ucXv/c3V8/3N1fP9wcnn/bG51/3V3ff9sbnX/Z2p0/3Byef9wc33/ -dnh8/3d5f/9ucHf/c3Z//2xvef9zdXz/bG95/25xe/9ucHf/c3Z//3N2f/9wc33/bnB3/25wd/9zdn// -eXuB/4GDiv9ucHf/bnF7/3Bzff95e4H/cHN9/3d6g/93eoP/cHJ5/3N2f/9maXP/dXd9/3Bzff91d33/ -c3Z//3l8hv9ucHf/cHJ5/25xe/9ucHf/dXd9/3V3ff92eHz/b3F1/25wd/91d33/bG95/2xvef91eIH/ -dXiB/25xe/9sb3n/c3Z//3Bzff9wc33/cHN9/2xvef9zdXz/cHJ5/25wd/9wcnn/b3F1/3N1fP9zdXr/ -bW92/2xudf9tb3P/cHJ5/2xudv9tb3f/aWx1/25xef9ucXv/Zmhu/2dqdP9kZ3H/bG95/2xvef9vcXr/ -a252/2Vobv9sbnX/cHJ5/2xudf9zdXz/dXd9/2xvef9sb3n/Zmlz/2ptd/9zdXz/YmVu/2psc/91d33/ -cHN9/25wd/9nanH/bnB3/25xe/91eIH/bG95/3V3ff9sb3n/bnB3/3V4gf9ucXv/am13/25wd/9ucHf/ -bG95/29xeP9zdn7/dHd//21vdv9wcnn/cHJ5/3V3ff9qbXf/cHJ6/3d6g/9wc33/bnF6/3F0fv9ucXv/ -bnF7/2xudf9zdXz/cHJ5/2ptd/9zdXz/bG51/3V3ff9sbnX/b3F1/3d5f/9sbnX/amxz/29xdf92eHz/ -cHJ5/3Byef9ucHf/dXd9/2ptd/9maXP/c3Z//25xe/9sb3n/Zmlz/2psc/9/gYf/am13/2ptd/9qbHP/ -am13/21vc/9sbnX/bG51/2psc/93eX//Zmlz/3Bzff9ucXv/bnB3/2xudf9sbnX/bnB3/2xudf9sb3n/ -bnB3/2psc/9zdXz/bnB3/3N1fP9ucHf/eHl9/3Bzff9wcnn/cHN9/3d6g/95fIb/e32D/3V4gf93eoP/ -cHN9/2xvef9wc33/bG95/3V3ff9ucHf/dXd9/25wd/91eIH/bnB3/3l8hv93eX//c3V8/2psc/9zdXz/ -cHJ5/3N1fP9ucHf/c3V8/3N1fP92eHz/cHN9/3V3ff91d33/dXd9/3d5f/9qbHP/bnB3/3V3ff9zdXz/ -b3F1/25wd/91d33/cHJ5/25xe/93eX//bG51/2psc/9sbnX/eHl9/3Byef91d33/bnF7/2xudf91eIH/ -cHN9/3V4gf9kZ3H/bnB3/25xe/93eoP/c3V8/3N1fP9zdXz/eXuB/3N2f/9wcnn/eXuB/3t9g/9ucXv/ -cHJ5/3V4gf93eX//bnB3/3Byef9wcnn/d3l//3Bzff9zdn//c3V8/3Byef91d33/cHJ5/25wd/9zdXz/ -cHN9/3N1fP91d33/bG95/3N1fP9ucHf/c3V8/25wd/9wcnn/bnB3/3N2f/91eIH/c3Z//2xvef9ucXv/ -c3Z//3V4gf+DhYz/dXd9/3V3ff97fYP/f4GH/3t9g/9/gYf/hYeN/3t9g/95fIb/c3Z//36Biv9+gIb/ -foCG/31+gf+Bg4r/dnh8/3l7gf97fYP/dnh8/3t9g/97fYP/eXuB/3Bzff9ucXv/d3l//25wd/9qbHP/ -cHN9/3Bzff9qbHP/ZGdx/2ptd/9qbXf/Z2p0/2dqdP9nanH/Z2p0/2Zpc/9kZ3H/Z2p0/2psc/9nanT/ -bG95/2Nmbv9gY2z/Zmhu/2ptd/9oa3P/bG52/2lsdv9sb3j/bnF7/21vc/9tb3P/Z2px/3Byef9xdHv/ -b3F4/3Byef9oanD/b3F1/3N1fP9ucHf/dXd9/3V3ff9ucHf/bnB3/2psc/9wcnn/dnh8/2Zobv9sbnX/ -dXd9/3N1fP9wcnn/Zmhu/2xudf9sb3n/dXd9/2ptd/9wcnn/b3F1/21vc/9wc33/bG51/2Rncf9qbHP/ -Z2p0/2BjbP9kZ3H/aGt1/2tud/9nanP/bnB4/21vdv91d33/bG51/21vc/9zdn3/a254/21vd/9tcHr/ -am13/2ptd/9sbnX/cHJ5/2xvef9nanT/c3V8/2psc/91d33/bG51/2xvef93eX//Z2p0/25xe/9wc33/ -e32D/3d6g/9zdn//cHN9/3d6g/9zdXz/bnF7/3l8hv9zdn//cHN9/2ptd/9ucHf/f4KM/2xvef9zdn// -cHN9/3Bzff9zdXz/c3Z//25xe/9nanT/eHl9/2dqcf9zdXz/cHJ5/25wd/9sbnX/bG51/29xdf9vcXX/ -cHJ5/3Byef9sbnX/c3V8/3Byef9sb3n/cHN9/3V3ff9wc33/bW9z/2ptd/9ucXv/dXd9/3Z4fP9wcnn/ -cHN9/2ptd/9nanT/cHN9/2psc/9wc33/am13/3Bzff9qbXf/bG95/2xudf93eoP/dXd9/2xvef9qbHP/ -bG95/2xvef9wc33/bG51/2ptd/9ucXv/bnF7/3Bzff9zdXz/dXd9/2xvef93eX//Zmlz/2ptd/9wc33/ -bG95/2ptd/9sbnX/cHN9/3Byef9zdXz/eXuB/3N2f/9qbXf/bnB3/3l7gf9wc33/dnh8/3N1fP9ucHf/ -bnF7/25wd/9zdXz/ZGdx/25wd/9zdXz/c3Z//25xe/9ucXv/cHN9/3d6g/95fIb/c3Z//36Ahv97fof/ -cHN9/3V4gf95e4H/e36H/3V3ff93eX//c3Z//3l8hv9zdn//d3qD/3d6g/9zdn//d3qD/3N2f/9sb3n/ -c3Z//3N2f/91eIH/d3qD/3Bzff9wc33/cHN9/25xe/9ucXv/cHN9/3Bzff91eIH/c3Z//3N2f/9ucHf/ -bW9z/3N1fP91d33/fn+D/25wd/9sb3n/dXiB/3d5f/9ucXv/d3l//3d6g/9zdn//bnF7/2psc/9wc33/ -cHJ5/3V3ff9zdXz/eXuB/2xudf9wcnn/bG95/2xudf91d33/dXd9/25xe/9ucHf/bG95/3V3ff9ucHf/ -Z2p0/3Bzff91d33/bW9z/2dqcf9wcnn/bG95/2ptd/9sbnX/bG51/25xe/9sbnX/am13/2xvef9qbHP/ -bG95/21veP9pa3L/YmVu/2Zobv9sb3n/bG51/2lsdP9oa3X/am12/2hrdf9maG7/Zmhu/1lcZf9maXP/ -bXB6/21wef9tb3f/Z2p0/25xdf9ucXv/bnB3/3N2f/93eX//bnF7/3Bzff9qbXf/c3Z//3d5f/9nanT/ -cHJ5/3N2f/93eX//cHJ5/2psc/9sbnX/bG95/3V3ff9sbnX/bG95/2ptd/9nanT/cHN9/2xvef9maXP/ -bG51/25xe/9kZmz/bG51/2xudv9ucHj/aWx0/25xe/9sb3n/cHN9/2dqdP9qbXf/cHJ4/25wdf9sbnb/ -c3V9/25wd/9wcnn/bG51/3Byef9ucHf/bG51/3V3ff9sbnX/dXd9/2xudf9sbnX/d3l//2dqdP9qbHP/ -b3F1/3Z4fP9zdn//bG95/25wd/91d33/bG95/2xvef97fof/dXiB/3N2f/9ucHf/cHJ5/3+CjP9qbXf/ -bnF7/25wd/9ucXv/cHN9/3N2f/9wc33/am13/3d5f/9nanH/cHJ5/3Byef9sbnX/Z2p0/2dqdP9sbnX/ -amxz/2xudf9nanT/Zmlz/2xvef9qbXf/am13/2xvef9zdXz/cHJ5/21vc/9wcnn/cHJ5/3Z4fP91d33/ -am13/3N1fP9ucXv/bG51/3V3ff9qbHP/cHN9/2ptd/9zdXz/bnB3/3Bzff9sb3n/foCG/3d5f/9ucXv/ -bW9z/3N1fP9zdXz/dnh8/3Byef9sbnX/bG95/3Bzff9wc33/cHN9/3V3ff9wcnn/dXiB/2Rncf9nanT/ -cHN9/2ptd/9qbXf/am13/2dqdP9qbXf/bG95/3N2f/9qbHP/Zmlz/2psc/91d33/bnF7/3Bzff9qbXf/ -Zmlz/2dqdP9sbnX/bnF7/2Zpc/9sbnX/bW9z/3N1fP9wcnn/bnB3/3Byef93eX//c3Z//25wd/91d33/ -eXuB/3Byef9wcnn/dXiB/3t9g/9ucHf/cHJ5/3Byef9zdn//cHN9/3d6g/97fYP/dXiB/3t+h/9zdn// -c3Z//3t9g/95e4H/d3qD/3t9g/9wc33/dXiB/3l7gf9wc33/dXiB/3V4gf9zdXz/d3qD/3l7gf91eIH/ -bnB3/3Byef9wc33/cHN9/3t9g/9vcXX/bnB3/3d5f/9zdn//bnF7/3d5f/91eIH/bnF7/25xe/9qbXf/ -cHN9/25xe/91eIH/cHN9/3l8hv9wcnn/cHN9/3N2f/9ucHf/dXiB/3d5f/9zdn//c3Z//3V4gf95e4H/ -cHN9/3Byef93eX//dXd9/2xvef9qbXf/cHN9/25xe/9wcnn/bnF7/25wd/91d33/bnB3/3Byef9zdn// -bnB3/3Bzff9vcnv/b3F1/2dqdP9ucHf/cHN9/25xe/9vcnv/bXB6/29xev9ydX7/bnB3/25wd/9maG7/ -b3F1/3J0ev9tcHr/bW93/2Zpc/9sbnX/am13/2dqdP9ucXv/c3V8/2psc/9sb3n/amxz/2xvef9ucXv/ -ZGdx/2dqdP9ucXv/cHN9/2ptd/9iZW7/Zmlz/2xudf9ucXv/Z2p0/25xe/9sbnX/bG51/3N1fP9wcnn/ -Z2px/2xudf9ucXv/ZGZs/25wd/9vcXj/b3F4/25wd/9wcnn/cHJ5/3h5ff9nanT/bG51/29xeP9sbnX/ -bnB3/3F0fv9sb3n/bG51/2ptd/9ucHf/cHJ5/29xdf9zdXz/bG51/3l7gf9ucHf/bnB3/3d6g/9ucHf/ -bG51/2ptd/9zdn//c3Z//3Bzff9sb3n/c3Z//2dqdP9nanT/eXuB/3N2f/9wc33/am13/29xdf+Agob/ -bG51/25wd/9sbnX/cHJ5/2xvef9ucXv/b3F1/2xudf92eHz/Zmhu/3N1fP9sbnX/Z2p0/2Zpc/9nanT/ -bG51/2psc/9nanH/bG51/2Zpc/9wc33/am13/2ptd/9ucXv/cHN9/2xvef9tb3P/bnF7/25xe/9zdXz/ -dXd9/3Bzff9wc33/bnF7/2Zpc/93eX//bnB3/3V3ff9ucHf/bnF7/2xvef9zdn//cHN9/3+Bh/95e4H/ -c3Z//3Byef9zdn//dXiB/3d5f/9zdn//cHN9/25wd/9zdn//dXd9/3N1fP93eX//cHJ5/3d5f/9maXP/ -am13/3N1fP9sb3n/Z2px/2psc/9qbXf/Zmlz/2dqdP9wcnn/Zmlz/2BjbP9nanH/bG95/2ptd/9sb3n/ -bG95/2Jlbv9qbXf/amxz/2ptd/9iZW7/Zmlz/2Zobv9sb3n/am13/2ptd/9tb3P/dXd9/3N1fP9ucHf/ -dXd9/3Z4fP9tb3P/bW9z/3N1fP91d33/am13/2xudf9sbnX/bnF7/2ptd/9wc33/dXd9/3Byef93eX// -c3V8/2psc/94eX3/dnh8/3Z4fP91d33/bG51/25xe/9wc33/bG51/25xe/9sb3n/bG51/25xe/91d33/ -bG51/25wd/9vcXX/c3V8/3Byef97fYP/bnB3/21vc/9zdXz/c3V8/25wd/91d33/dXd9/3Byef9wcnn/ -amxz/2xudf9sb3n/cHN9/3Bzff91d33/bG51/2xvef9sbnX/bnB3/3N1fP9zdn//c3V8/25wd/9zdXz/ -dXd9/25xe/9sb3n/dXiB/3N2f/9sb3n/bG95/25xe/9wcnn/c3V8/2xudf9sbnX/dnh8/29xdf9ucHf/ -cHN9/3Byef9zdn//c3Z//3F0fv9sb3n/bG95/3V3ff9ucHj/b3F4/2ptdf9rbnf/cXR+/2ptd/9qbXf/ -YmVu/2xvef9wcnn/b3F6/3Bye/91eID/Z2px/3N1fP9vcXX/Z2px/2psc/97fYP/cHJ5/2psc/9zdXz/ -bG95/25xe/9wc33/c3V8/25xe/9ucXv/c3V8/25xe/9nanT/cHN9/2xudf9qbXf/bG51/2xvef9gY2z/ -c3V8/2xvef9qbHP/dXd9/2Zpc/9nanH/Zmly/2dqdP9pbHT/bG95/3J1fv93eX//bG95/3Byef9ucXv/ -bG50/21wev9kZ3D/Z2lz/2dqdP9gY2z/ZGdx/2Zobv9iZW7/Zmhu/2Jlbv9maXP/Zmhu/2Rncf9sbnX/ -bG95/2Zobv9qbXf/bnF7/2xvef9ucXv/amxz/25xe/9kZ3H/ZGdx/3V3ff9sb3n/bnF7/2Zpc/9tb3P/ -foCG/2psc/9sbnX/bG51/3Bzff9qbXf/bG95/2xudf9maXP/bG95/11gav9sb3n/amxz/2Rncf9kZ3H/ -Z2p0/2xudf9sbnX/bG51/2ptd/9maXP/c3V8/2ptd/9sb3n/bnF7/25xe/9sb3n/bG51/2xvef9ucXv/ -dnh8/3h5ff9zdn//dnh8/3V3ff9qbXf/eXuB/3Byef93eX//bG95/2xvef9ucHf/c3Z//25xe/9+gIb/ -eHl9/3N1fP9wcnn/c3Z//3V4gf93eX//cHN9/25xe/9sb3n/dXiB/3l7gf9ucXv/dXiB/25wd/93eoP/ -Zmlz/25wd/93eX//bnF7/2ptd/9sbnX/cHJ5/3Byef9ucXv/dXd9/3N1fP9nanH/bW9z/3N1fP9wc33/ -c3V8/25xe/9nanT/bnB3/25xe/9zdn//bG95/25wd/9sb3n/cHN9/25wd/9ucHf/am13/3h5ff9zdn// -bnF7/3l8hv95e4H/bnB3/25wd/93eX//eXuB/3Byef9ucHf/c3V8/3V4gf93eoP/d3qD/3V4gf91eIH/ -d3qD/3V4gf9wc33/e36H/3t9g/97fof/eXyG/3Bzff95e4H/d3qD/25wd/9wc33/bnF7/3Byef91eIH/ -d3qD/3Bzff9ucHf/bnB3/3Bzff9wc33/e32D/2xvef9tb3P/dXd9/3V3ff9wcnn/eXuB/3h5ff9wcnn/ -bnF7/2ptd/9ucHf/bnB3/3V4gf93eoP/e32D/3N1fP9zdn//c3Z//2ptd/9wc33/cHN9/3N2f/9ucXv/ -c3Z//3V3ff9sb3n/bnB3/3N2f/91d33/bnB3/2psc/9sbnX/cHJ5/2ptd/9sbnX/Zmlz/3Bzff9qbHP/ -Z2px/2dqcf9maXP/am13/2lrdP9oa3L/Z2p0/2psc/9wc33/bW9z/21vdv9sbnT/aWxz/3N1fv9ucXv/ -bG95/2dqdP9ydX//dHd//3Byef9wc3r/dnh+/2Zobv9wc33/cHJ5/2dqdP9nanT/d3qD/2xvef9qbXf/ -dnh8/25xe/9zdn//cHN9/3V3ff9wcnn/cHJ5/3N1fP9wcnn/amxz/3Bzff9qbXf/bnB3/25wd/91d33/ -Zmhu/3N1fP9zdXz/am13/3d6g/9nanT/Z2p0/2hrdP9oa3L/a212/2tueP9tcHn/dXd9/2xudf9vcXX/ -bnB3/25wdv90dn3/am12/2ptd/9wc33/bG51/2xudf9sbnX/bG51/2ptd/9qbHP/cHJ5/25wd/9ucHf/ -bG95/3Bzff9gY2z/bG51/25wd/9ucXv/bnF7/2ptd/9ucXv/am13/2Rncf91d33/c3V8/3N1fP9nanH/ -b3F1/36Ahv9ucHf/bG95/29xdf9zdXz/bnB3/2xudf9ucHf/bW9z/3N1fP9maG7/bnF7/25xe/9maXP/ -ZGdx/2xudf9sbnX/b3F1/3Byef9ucXv/bG51/3N1fP9wc33/cHN9/3Bzff9wc33/bnB3/2ptd/9ucXv/ -c3Z//3l7gf93eX//d3l//3V3ff91eIH/bG95/3l7gf9zdXz/d3qD/2ptd/9wc33/c3V8/3V4gf9wc33/ -f4GH/3d5f/9wc33/cHJ5/3Bzff9zdn//dXd9/25wd/9tb3P/am13/25xe/9zdXz/am13/3V3ff9ucHf/ -d3qD/2psc/9sb3n/eHl9/3Byef9ucHf/bnB3/3V3ff9wcnn/c3V8/3V3ff9wcnn/amxz/25wd/9wcnn/ -c3V8/3N1fP91d33/bG51/3Bzff9zdn//dXiB/2ptd/9zdXz/cHN9/3V4gf9zdn//c3Z//3Bzff97fYP/ -c3Z//2xvef95fIb/d3l//2xvef9wcnn/d3l//3d6g/9zdXz/c3V8/3N1fP9zdn//cHN9/3Bzff93eoP/ -dXiB/3t+h/95e4H/bnF7/3l8hv93eX//eXuB/3l7gf9ucHf/d3l//3d6g/9zdXz/eXuB/3d6g/9zdn// -eXyG/3d6g/91eIH/c3V8/3N1fP9zdn//dXiB/3l8hv9wc33/bG95/3V3ff91d33/cHJ5/3d5f/94eX3/ -cHJ5/25wd/9nanT/bG95/25xe/91d33/dnh8/3V3ff9sbnX/am13/25wd/9nanH/cHJ5/3Byef9wc33/ -bnF7/3Bzff91eIH/cHN9/2xvef9zdn//dXd9/25xe/9qbXf/bnF7/3N2f/9sb3n/bnB3/2dqdP91d33/ -b3F1/25wd/9ucHf/amxz/25wd/9ucHj/a254/2ptd/9tb3P/cHJ5/2ptd/9qbXf/Z2pz/2Vocf9sb3n/ -Zmhu/2dqdP9gY2z/Z2p0/2hrdf9oanD/aWx2/3BzfP9iZW7/bnF7/2ptd/9maXP/Zmlz/3V4gf9qbXf/ -Z2p0/25xe/9qbXf/bnF7/25xe/9ucXv/bnF7/25xe/91d33/cHJ5/2psc/9ucXv/Z2p0/2dqdP9sbnX/ -bnF7/2Jlbv9ucXv/am13/2psc/9zdXz/Zmlz/2Rncf9nanT/aGty/2xvd/9sbnb/c3V8/3V3ff9sbnX/ -bnB3/2tud/9tb3b/cXN6/21vdv9wcnn/dXd9/2xvef9sb3n/bG95/2xvef9sb3n/bG95/3N2f/9wcnn/ -cHJ5/3Bzff91eIH/Zmhu/25wd/9vcXX/c3V8/3N1fP9wcnn/c3V8/2psc/9qbHP/d3l//3V4gf9wc33/ -cHJ5/3Byef9/gYf/bG95/25wd/9vcXX/c3V8/2xudf9tb3P/am13/2ptd/9wc33/ZGdx/2xvef9ucXv/ -YmVu/2Zpc/9sbnX/Z2p0/21vc/9sbnX/am13/2dqdP9ucXv/bnF7/3Bzff9sb3n/bG95/2ptd/9nanT/ -bG95/2ptd/9zdXz/dnh8/3Z4fP9zdXz/cHJ5/2psc/93eX//am13/3N1fP9sbnX/b3F1/29xdf9wcnn/ -dXd9/36Ahv91d33/c3V8/21vc/9ucXv/cHN9/3N1fP9sb3n/Z2p0/2ptd/9sb3n/dnh8/29xdf94eX3/ -bnB3/3V3ff9nanH/bnB3/3h5ff9wcnn/bnB3/2xvef9zdXz/c3V8/3Byef92eHz/cHJ5/2psc/9sbnX/ -cHN9/3V4gf91eIH/dXiB/2ptd/9ucXv/bG95/3Bzff9qbXf/cHJ5/2xvef9zdXz/bG95/3Byef9ucHf/ -eHl9/3V3ff9qbXf/foCG/3V4gf9tb3P/bW9z/3V3ff91eIH/bW9z/2xudf9nanT/bnB3/2ptd/9sbnX/ -cHJ5/2xudf92eHz/dXd9/2dqdP91d33/bnF7/3N1fP9ucXv/Z2p0/3Bzff9wc33/bG51/2xvef9qbHP/ -Z2px/2dqdP9nanT/am13/2psc/9nanH/bG95/2dqdP9zdn//Zmlz/2Rncf9nanT/bG95/2psc/9wcnn/ -cHJ5/2Zpc/9sbnX/Z2p0/2psc/9qbXf/cHN9/3Bzff93eX//bG51/2ptd/9sbnX/amxz/3N1fP9ucHf/ -cHJ5/3Byef91eIH/dXiB/3V4gf9ucXv/eXuB/3V4gf9ucHf/ZGdx/2xvef9wc33/bnB3/21vc/9nanH/ -dXd9/21vc/9qbXf/am13/2dqdP9sb3n/bW94/2xudv9maXP/amxz/2ptd/9kZ3H/Zmlz/2Nmbv9jZm// -bG94/2dqcf9nanT/YGNs/2xvef9sb3n/amx0/2hrdf9oa3T/Wl1m/2dqdP9nanH/XWBq/2Rncf93eX// -am13/2ptd/9zdXz/bnB3/3Byef9zdXz/c3V8/3Byef9wcnn/dXd9/3Byef9ucHX/c3V8/25wd/9wc33/ -b3F7/3V3ff9naXP/d3l//3N2f/9sb3n/dnh//25wd/9vcXX/bW92/2xudf9sbnX/bnB3/29ye/9wc33/ -Z2px/2psc/9sbnX/amxz/29xev9sbnX/bW92/3V3ff9qbXf/am13/21vef9nanT/bW9z/2Rncf9ucHj/ -bG51/2tud/9rbnf/c3V7/2Zpc/9qbXf/bnB3/3V3ff9ucXv/c3Z//3N1fP9qbHP/Z2p0/3V3ff92eHz/ -cHJ5/25wd/9vcXX/fX6B/2ptd/9qbXf/bG95/3Bzff9sbnX/bG51/2dqdP9qbXf/bnF7/2Jlbv9sb3n/ -bG95/2Rncf9iZW7/amxz/2dqcf9qbXf/amxz/2ptd/9maXP/bnF7/2xvef9sb3n/bG95/3Bzff9sb3n/ -bG51/25wd/9sb3n/dXiB/3l7gf95e4H/c3Z//3V4gf9zdXz/eXyG/3V4gf97fYP/c3Z//3V4gf9wc33/ -e32D/3t9g/+Bg4r/fn+D/35/g/9zdn//e32D/3t9g/97fYP/c3Z//3Byef9wc33/dXiB/3N2f/9ucHf/ -d3l//3Bzff93eoP/am13/25wd/93eX//bG95/3Byef9wcnn/dXiB/3V4gf9ucXv/d3l//3N1fP9qbHP/ -bG51/3N1fP9zdXz/dXd9/3V3ff9qbXf/am13/2ptd/91d33/amxz/29xdf9ucHf/c3V8/2xudf9wcnn/ -bW9z/3V3ff91d33/bG51/3t9g/93eX//bG51/2xudf9zdXz/d3l//3Byef9sbnX/bG51/25wd/9wcnn/ -bnB3/3N1fP9vcXX/dXd9/3V3ff9nanH/d3l//25xe/92eHz/cHJ5/25wd/92eHz/c3V8/2xvef9ucXv/ -bG95/2psc/9ucXv/bnF7/2xudf9vcXX/bnB3/3N2f/9ucHf/e32D/3N1fP9ucHf/dXd9/3N2f/9ucXv/ -dXiB/3V3ff9wc33/bnB3/25wd/9vcXX/bG51/3Byef91d33/eHl9/25wd/9wc33/bnF7/2xvef91eIH/ -cHN9/3V4gf9ucHf/cHJ5/3Byef9wcnn/bG51/3N1fP9ucXv/am13/2Rncf9sb3n/cHN9/21vc/9tb3P/ -amxz/3Z4fP9ucHf/bG95/3Bzff9sb3n/bnF7/25weP9wc33/bG51/2xudf9wcnn/am13/2ttdf9ucHX/ -bG52/3J0e/9sb3n/cHJ5/2Zpc/91eID/bnF7/3BzfP9vcnv/dXd9/2dqcf9zdXz/b3F4/2ttdP9sbnX/ -dXd9/21wd/9rbXX/c3V8/2ptd/9vcnz/bXB6/21wev9tcHr/aWx2/21wev9wcnr/a21y/3Fzev9tb3T/ -cHJ5/3Byef91d33/a210/3d5gv9wc3z/bnF6/3V3ff9ucHf/bW92/25wd/9tb3T/bnB1/21wef9vcnv/ -bnF7/2dqdP9sbnX/amx0/2ttdP9wcnv/cHJ7/29xev96fIL/cHJ6/29xeP93eoL/b3J8/29xef9pbHb/ -b3J8/2ptdv9tcHr/bXB6/29ye/9iZW7/Z2p0/2xudf9sb3n/bG95/2xvef9sb3n/Zmlz/2ptd/9wc33/ -dXd9/2xvef9qbXf/Zmlz/3d6g/9sb3n/Z2p0/2ptd/91d33/bG51/2xvef9nanH/bnB3/3N2f/9qbHP/ -c3V8/3Bzff9qbXf/bnB3/25xe/9sb3n/bnF7/3Bzff9ucHf/bnB3/3Bzff91d33/c3V8/3V4gf9zdn// -cHN9/3Byef9ucXv/bnF7/3N2f/91eIH/e32D/3Bzff9zdn//bnB3/3d5f/9ucXv/dXd9/2ptd/9qbXf/ -bG51/3Byef91d33/d3l//3Bzff9ucHf/bnB3/3N1fP9wcnn/cHJ5/2xvef9qbXf/bG51/2xvef9sb3n/ -Zmlz/3Bzff9qbXf/dXd9/2Jlbv9nanT/d3l//2ptd/9tb3P/bG51/3Byef9zdXz/bG51/3Z4fP9wcnn/ -bG51/2psc/9sb3n/bG95/3V3ff91d33/am13/2ptd/9qbHP/am13/2Zpc/9sbnX/am13/2xvef9qbHP/ -cHJ5/29xdf95e4H/dnh8/2xudf95fIb/e32D/29xdf9sbnX/c3V8/3d5f/9wcnn/bnB3/25wd/9vcXX/ -c3V8/2psc/9ucHf/bW9z/3V3ff91d33/Z2p0/3V4gf9ucXv/c3V8/2dqdP9maXP/bnB3/2ptd/9nanT/ -Z2p0/2Zpc/9kZmz/Zmhu/2dqdP9maG7/ZGdx/2Zobv9maXP/ZGdx/3Bzff9maXP/ZGdx/2xvef9sb3n/ -amxz/3V3ff9wc33/bnF7/2ptd/9qbXf/amxz/2xudf9sb3n/dXd9/3N1fP9tb3P/b3F1/3Byef9qbXf/ -cHN9/25wd/91d33/bW9z/25wd/9sb3n/am13/2xudf92eHz/cHJ5/25wd/9qbHP/bnB3/3N1fP9tb3P/ -bG95/25wd/97fYP/cHN9/3d6g/9ucXv/bG95/3Byef9vcXj/cHJ5/2dqcf9sbnX/bnB3/25wd/9vcXj/ -bnB1/2xvdv9ydHv/bW9z/3Byef9nanH/cHJ5/21vdv9ydHv/b3F6/3V3ff9jZnD/a254/2ptd/9maXL/ -Z2ly/3F0e/9oa3X/Zmlz/25xev9pbHT/bG95/25xe/9pbHX/amx1/2hrc/9sb3f/am13/2Zobv9pbHb/ -Z2pz/2hrdf9tcHj/am12/2Nlbv9wc3r/aGt0/2xudP9sb3n/aGtz/2ZocP9sb3f/amxy/2tud/9ucHb/ -c3V8/3N1fP9qbXf/bnB3/3Byef9ucHf/cHJ5/3J0ev9vcXj/dnh+/3Bze/9rbXb/cXR+/25wd/9ucHf/ -am12/3BzfP9sb3f/cXN6/3Fzev9wcnn/Zmlz/2ptd/9qbXf/bG95/2Zpc/9maXP/Z2p0/2Rncf9iZW7/ -ZGdx/25wd/9kZ3H/Z2px/2Jlbv9zdXz/Zmhu/11gav9kZmz/bG95/2Rncf9maXP/XWBq/2Zobv9qbXf/ -XWBq/2dqdP9kZ3H/XWBq/2Jlbv9kZ3H/Z2px/2dqdP9sb3n/Z2p0/2psc/9ucXv/cHN9/25xe/9sb3n/ -bG95/25wd/9sbnX/bnB3/29xdf92eHz/cHN9/3d5f/9zdn//eXuB/25xe/95fIb/c3Z//3V4gf9ucXv/ -c3V8/3N1fP91eIH/eXuB/3l8hv9zdn//bnF7/25xe/91eIH/cHN9/3N2f/9wc33/bnB3/3N2f/91eIH/ -c3Z//3Byef95e4H/c3Z//3l8hv9ucHf/b3F1/3d5f/9vcXX/bnB3/3Byef9zdn//cHN9/25xe/93eX// -c3Z//2xvef9ucHf/bnF7/3Byef92eHz/eHl9/25wd/93eoP/c3Z//3l7gf9ucXv/cHJ5/3Byef9wc33/ -bG95/3Bzff9sb3n/d3qD/3V3ff9ucHf/fn+D/3l7gf9vcXX/bG95/3V3ff91eIH/cHN9/29xdf9qbHP/ -bG95/25xe/9qbHP/bnB3/25wd/91d33/dXd9/2xvef93eoP/dXiB/3t9g/9zdn//bG95/3V4gf9zdn// -c3Z//3N2f/91eIH/bG95/3Bzff91d33/bnB3/29xdf9wcnn/c3V8/2xudf97fYP/bnB3/2ptd/91d33/ -dXd9/21vc/91d33/bnF7/2xvef9maXP/ZGdx/2Zobv9qbHP/Z2p0/25wd/9qbXf/ZGZs/2Zobv9maXP/ -YmVu/2dqdP9nanH/Z2p0/2psc/9nanT/am13/2ptd/9nanT/dXd9/2xvef9nanT/Zmlz/25xe/9wcnn/ -bW9z/25wd/9sbnX/d3l//25wd/9wcnn/bnB3/2xudf9vcXX/cHJ5/3Bzff9qbHP/b3F1/3N1fP9ucHf/ -cHJ5/25wd/9tb3b/b3F4/25wd/9ucXv/Z2p0/3Bzff9vcXj/cnV+/29xef95e4H/Zmlz/3J1fv9qbXf/ -b3J8/25wd/9xdH7/cnR9/25xef93eYD/cHJ6/3R2fv90dn7/bG95/3F0ff9ucXr/bnB5/29yfP9nanL/ -bXB6/21wdv9tb3f/dnh9/3J1fv9tb3b/d3l+/29yfP9xdHv/cHN7/2ptd/9maXP/dHZ8/2xudP9ucHf/ -bnB0/3N1fP9zdXz/Z2p0/2xudf9sb3n/Zmlz/2tud/9xc3r/aGt1/3V3ff9ucHf/ZWhy/3Fze/9qbXf/ -bG94/21wd/9zdX3/amx0/21wev9ydHr/a254/2Zpc/9ucXv/bG95/3Byef9ucHf/bnB3/25wd/9sbnX/ -am13/2xvef92eHz/bnB3/25wd/9ucHf/e32D/3V3ff9sbnX/bG95/3V3ff9sbnX/bG95/2Zpc/9qbXf/ -cHN9/2Rncf9qbHP/bnF7/2psc/9ucHf/c3V8/25wd/9sbnX/c3V8/25wd/9ucHf/cHN9/3d5f/9ucXv/ -dXd9/3V3ff9wcnn/bG51/25wd/9tb3P/dXd9/3Bzff95e4H/c3Z//3N2f/9sb3n/eXyG/3l7gf9zdn// -bnB3/3N1fP9zdXz/c3Z//3t9g/9+gYr/dXiB/3N2f/9ucXv/bnF7/25xe/9ucXv/bG95/2xvef91eIH/ -c3Z//3N2f/9wcnn/eXyG/3d6g/9+gIb/c3V8/3N1fP95fIb/cHN9/3Bzff9zdXz/dXiB/3N2f/9ucXv/ -eXuB/3V4gf9ucHf/cHN9/3V4gf91eIH/e32D/36Ahv91d33/c3V8/25wd/91d33/bnB3/25wd/9ucHf/ -bnB3/2xudf9wc33/am13/3V3ff9wc33/Z2px/3d6g/9zdn//amxz/2xudf9zdXz/dXd9/3Bzff9qbXf/ -Z2p0/2xudf9wc33/Z2p0/2xudf9sbnX/c3V8/3Bzff9maXP/dXd9/2dqdP9wc33/bnF7/2dqdP9zdXz/ -bnF7/2xvef9ucXv/bnF7/2ptd/9sbnX/bnF7/2dqcf9maG7/Z2px/2dqdP9kZ3H/dXd9/2psc/9nanH/ -bnB3/2xvef9maG7/bnF7/2ptd/9ucXv/Zmlz/2psc/9qbHP/bG95/2xvef9wcnn/cHJ5/2dqdP9qbHP/ -Z2p0/2Zpc/9wc33/bG51/2ptd/9qbXf/am13/2xudf9sb3n/bG51/3Z4fP91d33/bnB3/2Zpc/9wcnn/ -cHJ5/21vc/9sbnX/b3F1/3h5ff9ucHf/cHJ5/2xudf9sbnX/bG95/25xe/9ucXv/Zmhu/21vc/9zdXz/ -bnB3/3N1fP9ucHf/b3F2/2ptd/9sbnX/bnB3/2Zobv9zdXz/bnB3/3N1fP9xc3r/eXuC/2hrcv9ydXz/ -a211/3R2ff9ucHf/cnV//3V3ff9vcXj/dnh9/3Bzff9xdH7/eHqD/3F0fv9wc3z/cHN8/3Byef90d4D/ -aWxz/3N2f/9ucXv/bXB6/3d5f/90d3//bG95/3V3ff9sb3n/c3Z//29yfP9wcnn/Z2pz/3h6gP9vcXX/ -cHJ5/25wd/92eHz/c3V8/21vc/9sbnX/bnF7/2psc/9sbnX/cnR8/2Zpc/9wcnn/Zmlz/2Nmb/90dn3/ -am13/25xev9vcnz/dnh+/21vc/90dnz/dHZ8/25wd/9maXP/bnF7/2ptd/9ucXv/bnF7/2xvef9ucHf/ -bG51/2psc/9sbnX/dnh8/25wd/9wcnn/bG51/3l8hv9zdn//Z2p0/2xvef9zdn//bnB3/3Byef9sb3n/ -bG95/25xe/9qbHP/bG95/3Bzff9sb3n/bnB3/3N2f/93eoP/dXiB/3d6g/9wc33/dXd9/3t9g/9+gIb/ -dXiB/3d6g/97fYP/c3V8/3Bzff9wc33/bnB3/3N2f/9zdn//eXuB/3Bzff9wcnn/am13/3V4gf91d33/ -cHJ5/25wd/9sb3n/cHJ5/2xvef91d33/d3l//2xvef9sb3n/am13/2xvef9sbnX/bnB3/25wd/9sb3n/ -d3qD/3d6g/9zdn//bnF7/3t+h/95e4H/foGK/3N2f/9wc33/eXyG/3N1fP91eIH/d3l//3d6g/97fYP/ -eXyG/3t9g/95e4H/c3V8/3Bzff91eIH/bnF7/3Bzff93eX//bnB3/3N1fP9wcnn/dXd9/2xudf9tb3P/ -bG51/2ptd/9nanT/cHN9/2ptd/93eX//d3l//2dqcf95e4H/dXd9/2Zpc/9maG7/bG95/2ptd/9nanT/ -Zmhu/2Jlbv9nanH/am13/2Jlbv9kZ3H/Zmhu/2ptd/9nanT/ZGdx/25wd/9maXP/Z2p0/2dqdP9kZ3H/ -bnB3/2Rncf9maG7/Z2p0/2ptd/9kZ3H/ZGdx/2dqdP9nanT/Z2px/2dqcf9nanT/YmVu/3Byef9qbHP/ -amxz/3N1fP9ucXv/bG51/3Z4fP9ucXv/bG95/2Zpc/9qbHP/amxz/25xe/9sb3n/dnh8/3V3ff9sb3n/ -am13/2xudf9nanT/bnF7/2psc/9wc33/bG95/2xvef9qbXf/am13/2dqdP91d33/bnF7/2xudf9sbnX/ -cHJ5/3Byef9sbnX/b3F1/29xdf94eX3/bnB3/3Byef9ucHf/amxz/2ptd/9wc33/c3Z//2ptd/9zdXz/ -dXiB/3N1fP93eoP/c3V8/3Bzff9zdn//cHN9/3V4gf9ucXv/dXiB/2xvef9wc33/cHN9/3d6g/9nanT/ -c3Z+/2xvef94eoD/cHN9/3N2f/94eoD/cHJ5/3V3ff9wc33/bnF7/3d5f/9ucXv/bG95/3N1fP9sbnX/ -dXd9/2RmbP9ucHf/am13/2psc/94eX3/dXd9/29xdf94eX3/b3F1/3N1fP9sb3n/bW9z/2Zobv94eX3/ -b3F1/3Byef9wcnn/eHl9/3V3ff9tb3P/bnB3/3N1fP9sbnX/bG95/3N1fP9sbnX/dXd9/3Byef9qbHP/ -d3l//2ptd/9ucXv/cHN9/3V3ff9nanH/c3V8/25wd/9nanH/YGNs/2dqdP9maXP/am13/25xe/9sb3n/ -bG51/2psc/9nanT/amxz/3N1fP9qbXf/bG51/2psc/93eoP/bnF7/2Rncf9sbnX/cHN9/2xvef9sb3n/ -am13/2dqdP9qbXf/Z2p0/2ptd/9sb3n/bG51/25wd/9ucHf/dXd9/2xudf9zdXz/b3F1/2xudf9ucHf/ -dXd9/2ptd/9zdXz/dXd9/2xudf9qbXf/bG95/2xudf9wc33/cHJ5/3l7gf9sb3n/cHN9/25wd/95e4H/ -dXiB/25xe/9vcXX/b3F1/25wd/9sbnX/c3Z//3t+h/9ucXv/bnF7/3Bzff9sb3n/bG95/2xudf9wcnn/ -bnB3/3N2f/9zdn//bnF7/2ptd/91eIH/cHN9/3l7gf9wcnn/bW9z/3V3ff9tb3P/bG95/25wd/9vcXX/ -dXd9/3N1fP9zdXz/c3V8/25wd/9ucHf/c3V8/29xdf9zdXz/d3l//25wd/9wcnn/cHJ5/3Byef9qbXf/ -bG51/2xudf9sb3n/am13/3N1fP9qbXf/eHl9/3d5f/9vcXX/f4GH/3d5f/9wcnn/b3F1/3Z4fP92eHz/ -c3V8/2xudf9nanT/bG51/3N1fP9nanT/am13/2xvef9zdXz/cHJ5/29xdf93eX//dXd9/3N1fP9wcnn/ -b3F1/3Z4fP9wcnn/bnB3/3Byef9wc33/bnB3/25wd/9zdXz/c3V8/21vc/9sbnX/bG95/2dqdP9zdXz/ -bG51/2xvef91d33/cHJ5/25wd/93eX//cHJ5/3N1fP9qbHP/bnB3/2xvef91d33/c3Z//3d5f/91d33/ -c3Z//2xvef9ucHf/bG51/3N1fP9tb3P/dXd9/25wd/9sb3n/cHN9/3Bzff9ucHf/eXuB/3N2f/9zdXz/ -bnB3/3N1fP9ucHf/bG51/2xudf9sbnX/d3l//2ptd/9sb3n/bG95/2dqdP9sbnX/bnB3/3Byef9nanH/ -b3F1/3N2f/9wcnn/cHN9/2xvef9vcXX/bnF7/29xdf9wcnn/Zmhu/3N1fP9ucHf/dXd9/3V3ff93eX// -Z2p0/3N1fP9qbXf/dXiB/2xvef9sb3n/dnh8/21vc/91d33/bG95/2xvef9wc33/bG51/2psc/9ucXv/ -Zmlz/25xe/9dYGr/Zmlz/3Byef9qbXf/d3l//3Bzff9ucHf/d3l//25wd/9ucXv/bG95/2xvef9nanT/ -eHl9/25wd/9ucHf/cHJ5/3Z4fP91d33/bnB3/29xdf9zdXz/am13/2xudf9wc33/amxz/3V3ff9sbnX/ -amxz/3N1fP9qbXf/bG95/3N1fP93eoP/bG51/3V3ff92eHz/bG51/2Zpc/9wc33/cHN9/2xvef9sb3n/ -bnF7/2ptd/9qbHP/Zmlz/2dqcf91d33/Z2p0/2xvef9maXP/dXiB/25xe/9maXP/bG95/3N1fP9sb3n/ -bnF7/2psc/9maXP/am13/2psc/9nanT/cHJ5/2dqdP9qbXf/cHJ5/3Z4fP9wc33/dXd9/29xdf9sb3n/ -cHN9/3l7gf9wc33/c3Z//3V3ff9sb3n/bG95/25xe/9sb3n/dXd9/3N1fP97fof/bnF7/3Bzff9sb3n/ -eXuB/3N2f/9ucXv/bnB3/3N1fP9ucXv/bnF7/3N1fP93eoP/bG95/25wd/9ucXv/am13/2ptd/9ucHf/ -bnB3/2xudf9wc33/cHJ5/25wd/9qbHP/dXd9/3Byef91eIH/am13/2psc/9ucXv/bG51/2psc/9qbHP/ -Zmlz/25xe/9maXP/bnF7/3N1fP9qbXf/bG51/3Byef9tb3P/c3V8/3l7gf9ucHf/c3Z//3N2f/9wc33/ -bnB3/3Byef9wcnn/c3Z//3Byef93eX//bG95/3Z4fP95e4H/bG51/3+Bh/91d33/bG51/2ptd/91d33/ -cHN9/3Bzff9sb3n/Z2p0/2xudf9wc33/bG51/3Byef9qbXf/cHJ5/3Byef9qbXf/dXiB/3Bzff9zdXz/ -bG95/2xudf9zdXz/cHJ5/3Byef9wcnn/dXd9/3Byef9ucHf/bnB3/2xvef9sb3n/am13/2dqdP9nanT/ -cHN9/2xudf9qbHP/c3Z//2xvef9nanT/bnF7/2ptd/9ucXv/Z2px/21vc/9sbnX/eHl9/3Bzff9zdn// -d3l//3Bzff9ucHf/bG95/25wd/9wc33/bG95/3Bzff9ucHf/cHN9/3N2f/9ucXv/bG51/3d5f/9wcnn/ -bW9z/21vc/9zdXz/bnB3/2xvef9sbnX/bG51/3V3ff9maXP/Zmlz/2Zpc/9dYGr/amxz/2ptd/9sb3n/ -Zmlz/2xudf9wcnn/bG51/25wd/9tb3P/am13/2xvef9qbXf/bnF7/2Rncf9wc33/bG51/3N1fP9zdXz/ -dnh8/2dqcf9zdXz/b3F1/3V3ff9sb3n/bG95/3V3ff9ucHf/dXiB/3Byef9wcnn/c3Z//25xe/9ucHf/ -c3V8/2ptd/9wc33/Z2p0/3V4gf9zdXz/am13/3t9g/91eIH/dXiB/3t9g/9zdXz/dXiB/3Byef9ucXv/ -c3V8/36Bif9zdn//dXiB/3N2f/95fIb/eXuB/3N1fP9ucHf/dXd9/2xvef9zdn//d3qD/3Bzff95e4H/ -bnF7/2xudf93eX//bG95/3N1fP93eX//e32D/29xdf92eHz/dnh8/3Byef9sbnX/dnh8/3N2f/9ucXv/ -c3V8/3V3ff9wc33/c3Z//3Byef9wcnn/eXyG/3Bzff9wc33/am13/3t9g/9wc33/Z2p0/25xe/91d33/ -bnF7/3N2f/9ucHf/bG51/25wd/9vcXX/bG51/3N1fP9nanT/Zmlz/2xvef9wc33/bG95/2ptd/9kZ3H/ -amxz/2psc/9ucHf/Z2px/25xe/9wc33/amxz/21vc/9ucHf/cHJ5/25wd/9zdn//d3qD/2xvef9wc33/ -bG95/3l7gf91eIH/c3Z//3Byef9wc33/d3qD/3V4gf95fIb/foGK/3V4gf9zdn//dXiB/3V4gf91eIH/ -c3Z//3V4gf9zdXz/eXuB/3N2f/9ucHf/bG51/3V3ff9zdXz/eXuB/2xudf9vcXX/dXd9/2xvef9sb3n/ -bG95/2xvef92eHz/bnF7/3d5f/97fYP/bnF7/2xvef9wc33/b3F1/25xe/93eoP/bG95/3Byef9wcnn/ -cHJ5/2xudf9ucHf/bW9z/3Byef9ucHf/dnh8/3Byef93eX//e36H/25xe/+Bg4r/d3l//25wd/9wcnn/ -c3V8/3Z4fP91d33/c3Z//2xvef9wcnn/c3Z//2xvef9zdn//bnF7/3V4gf9zdn//cHJ5/3+Bh/93eoP/ -eXuB/3N2f/9wc33/dXiB/3N2f/9zdn//e32D/3d6g/95e4H/dXiB/3N2f/91eIH/c3Z//2xvef9ucXv/ -bG95/3l7gf9wc33/c3Z//3l8hv9wc33/b3F1/3Bzff9sb3n/c3V8/2Zpc/9tb3P/cHJ5/3Z4fP92eHz/ -dXiB/3h5ff9zdXz/bG95/25wd/9vcXX/cHJ5/3Byef91eIH/c3V8/3Bzff9zdn//cHN9/2ptd/91eIH/ -c3Z//2xvef9wcnn/cHN9/2xvef9ucXv/bG95/2xvef93eX//bnB3/3Byef9zdXz/Zmhu/2psc/9qbXf/ -bnF7/2Zpc/9qbHP/am13/2Zobv9sbnX/Z2px/2Zpc/9nanT/bG51/2xudf9iZW7/dXd9/25wd/92eHz/ -c3V8/3V3ff9nanT/bnF7/3Byef90d4H/c3Z//3N2f/94eoD/cnR7/36Ahv90d4D/dHeA/3p8gv92eYL/ -c3Z+/3Z5gv9vcnz/eXuC/21wev91eIH/bG51/2Jlbv9vcnz/a211/2lrcv9xdHv/aWxz/29yfP9qbHP/ -aWx2/2Zpcv91d33/aWx2/2xveP9qbXf/d3l//3Byef9ucHf/b3F1/3V3ff9sbnX/bnF7/3N1fP9sbnX/ -dXd9/2xudf9sbnX/d3h9/3Byef9wcnj/dHd7/3h6gP9sbnX/cHN9/3N1fP9tb3b/bG51/3V3ff9zdXz/ -bnB3/3N1fP9sb3n/am13/2xudf9nanT/bG51/3Z4fP9sbnX/bnF7/2dqdP93eoP/bnF7/2Zpc/9sbnX/ -dnh8/2xudf91d33/b3F1/2xvef9ucXv/bnB3/29xdf9wcnn/bG51/2psc/9zdXz/dXd9/3Byef9zdXz/ -bG51/2xudf9qbXf/c3V8/2xvef9zdXz/dnh8/25wd/9ucHf/cHJ5/3Byef9ucXv/dXd9/3t+h/9sb3n/ -cHJ5/2ptd/93eX//c3Z//3Bzff9ucHf/bG95/25xe/9wc33/c3Z//3l8hv9zdn//cHN9/3Bzff9wc33/ -cHN9/3Byef9wcnn/bnB3/3N2f/9ucXv/cHN9/2dqdP91eIH/dXd9/3d5f/9sbnX/bG51/3Bzff9sb3n/ -am13/2xudf9ucHf/dXd9/3Byef9zdn//d3l//2xudf9vcXX/c3V8/29xdf9ucHf/eHl9/3Byef9ucXv/ -bnF7/2ptd/9nanT/bG95/2xudf9wcnn/bnB3/3V3ff9sbnX/dXd9/3l7gf9vcXX/gYSN/3d5f/9sb3n/ -cHJ5/3Z4fP91d33/dnh8/3Byef9maG7/bnB3/3Bzff9wcnn/dXiB/3Byef9wc33/c3Z//3N1fP9/gYf/ -bnF7/3l7gf9wc33/c3V8/3l8hv93eoP/cHN9/3d6g/9wc33/c3Z//25xe/9ucXv/cHN9/3Bzff9ucXv/ -cHN9/3Byef93eoP/cHN9/3Bzff93eoP/dXiB/3Bzff91eIH/dXiB/3V4gf9qbXf/cHN9/3Bzff95e4H/ -c3Z//3l7gf95e4H/d3qD/3Bzff9wc33/dXiB/3d6g/9zdn//d3qD/3N2f/91eIH/c3Z//3Byef9ucHf/ -d3l//3N2f/9sb3n/bG95/25xe/9sbnX/c3V8/2xudf9ucHf/d3l//2dqdP9zdn//c3Z//2Zpc/9vcXX/ -bnB3/2xvef9kZ3H/bG51/3N1fP9vcXX/bnB3/25wd/9zdn//cHN9/25xe/9wc33/Zmlz/3d5f/9sb3n/ -dHeA/3h6gf93eX//am13/3BzfP9sb3n/cnV+/3J0e/91d33/dXh9/29xdv94eoH/bXB3/25weP9xdH3/ -bnF7/25wd/9wcnr/aWx2/29ye/9laG//aWx1/3J0ff9rbnj/cnV+/21weP9sb3n/dnh//2xvef9ydHv/ -cXN6/2psdP9naXD/cXN5/2psdP9sbnX/bG95/3d6hP9tcHr/cHN9/2xvef9wc33/bG95/25xe/9ydX7/ -bXB6/3h6gP9vcXj/bG51/3Z3ff9ydHv/b3F4/3N1e/90dn3/bnB0/3N1e/90dn3/bnF6/25wd/92eHz/ -c3Z//3Byef9wcnn/c3V8/2xudf9zdXz/bnB3/2xudf94eX3/am13/3Bzff9maXP/c3Z//3Bzff9maXP/ -bG51/3N1fP9sbnX/dXd9/2xudf9ucHf/bnF7/25wd/9ucHf/cHN9/2xvef9sbnX/c3V8/3h5ff9wcnn/ -c3V8/21vc/9vcXX/bG51/3l7gf9wc33/d3l//3V4gf9wcnn/bnF7/3Bzff9ucXv/bG95/3h5ff93eX// -bW9z/2xudf9nanT/d3l//25xe/9sb3n/amxz/2psc/9qbXf/bG95/2xvef9zdXz/cHJ5/2xudf9sb3n/ -am13/2xudf9sbnX/am13/2dqdP9ucXv/bG95/2xudf9maXP/dXd9/25xe/95e4H/bG51/25wd/9zdXz/ -cHJ5/2xvef9qbXf/bG51/3Z4fP9ucHf/dXd9/3d5f/9sbnX/b3F1/3Bzff9tb3P/bnB3/3V3ff9ucXv/ -cHJ5/25xe/9sbnX/bW9z/2xvef9qbXf/amxz/2ptd/9zdXz/am13/3Z4fP91eIH/bG51/3+Bh/91d33/ -bW9z/2xudf9wc33/bnF7/3N1fP9wcnn/ZGdx/21vc/9zdXz/bW9z/3Z4fP9sbnX/cHJ5/25wd/9sbnX/ -eXuB/2ptd/91d33/bG51/2dqcf93eX//am13/2xvef9ucXv/am13/25xe/9qbHP/bG51/2ptd/9sb3n/ -cHJ5/25wd/9sbnX/dXd9/2xvef9ucHf/d3qD/3Bzff9ucXv/c3Z//25xe/9ucXv/Z2p0/2xvef9ucXv/ -eXuB/3V4gf93eoP/dnh8/3N1fP9sbnX/bW9z/2xudf9ucHf/bW9z/2xvef9sbnX/bG95/2xudf9maXP/ -YmVu/2xvef9nanT/Zmlz/2xudf9sb3n/am13/25xe/9qbHP/bG51/3V3ff9qbHP/bG95/3Bzff9maXP/ -am13/21vef9tcHr/amxz/2psc/9zdXz/bG51/2xudf9vcXX/c3V8/3V3ff9sb3n/bnF7/2dqdP91eIH/ -bG95/3R2e/92eHz/dHZ9/2ptdv9ucHn/bG93/3Bze/9ucXn/c3Z+/3Fzev9sbnb/dnmC/3Byev9ydX7/ -dnh+/3N1fv91d33/d3l//25wef91eID/a212/3Bzff9vcnz/bW94/3V3f/9xdHz/bnF7/3V3gP9wcnv/ -cXN6/3R2fP9tcHr/bnB5/3N1fv9tb3j/bnB5/3J0ef93eoH/bW94/3V3ff9sbnX/cHJ5/25wd/9wcnn/ -dHZ8/21wef93eX7/bnF5/2tueP9xdHz/b3J6/21vdv9ucXn/c3V9/2xvdv9tcHj/bnF7/29yev9sb3n/ -dXd9/3V3ff9ucXv/dXiB/3V4gf9sb3n/cHN9/2xvef9qbXf/dXd9/3N1fP91d33/Zmhu/3V3ff9ucXv/ -ZGdx/2psc/9wc33/bG51/25wd/9nanH/Z2p0/2psc/9maG7/Zmhu/2xvef9nanT/Zmlz/3Byef92eHz/ -c3V8/3Byef9sb3n/bnB3/25wd/95fIb/cHN9/3l7gf91eIH/cHJ5/3N2f/91eIH/eXyG/3V4gf9+gIb/ -foGK/3N1fP9wc33/cHN9/36Biv97fYP/c3Z//3Bzff9zdn//c3Z//3N2f/9zdXz/dnh8/25wd/9ucHf/ -cHJ5/21vc/9vcXX/b3F1/2xvef9sb3n/cHN9/3Bzff9ucHf/Z2p0/3d6g/91eIH/foGK/2ptd/9ucXv/ -dnh8/3V3ff9sb3n/bG95/3Byef91eIH/bnF7/3V4gf93eoP/bG95/3Bzff91eIH/bnF7/25xe/94eX3/ -cHJ5/3N2f/9wc33/cHJ5/3Byef9wc33/bnB3/3Byef9ucXv/eXuB/25wd/91eIH/dXiB/2xvef9/gYf/ -eHl9/29xdf9sbnX/cHN9/25xe/91d33/bnF7/2BjbP9qbHP/am13/2Zobv9qbXf/Zmhu/2Zpc/9nanH/ -Z2px/3V3ff9qbHP/bG95/2xudf9nanH/cHJ5/2xvef9sb3n/bG95/2xudf9ucHf/b3F1/29xdf9ucXv/ -bnF7/3V4gf9ucXv/bnB3/25xe/9wc33/cHJ5/3l7gf9wc33/c3Z//3V4gf9zdn//bnF7/2xvef9zdn// -d3qD/3t9g/93eoP/eXyG/3l7gf93eoP/dXiB/3N1fP9wcnn/c3Z//3Bzff91eIH/cHN9/3l7gf9wc33/ -c3V8/25xe/97fYP/eXuB/3Bzff9wc33/cHN9/25xe/9sb3n/am13/29xdf92eHz/am13/25xe/9zdn// -Zmlz/2xvef9vcnz/b3J7/2dqdP9qbXf/c3Z//25xe/9sb3n/bnF7/3V4gf91eIH/cHN9/3N2f/9sb3n/ -eXuB/29ye/93eYD/eXuB/3l7gf9wc3v/dHd+/3V3fv92eH//c3aA/3t9hP90dn3/bnF6/3V3gP9vcnz/ -dnmD/3d6hP90d3z/d3mA/3x9gv91eH//e3yA/25xe/91d4D/dHd//29yfP92eYL/cnV+/29yef93eoL/ -dXiB/3F0ff93eX//bG94/2xueP9vcXj/bG94/21wef9ydHv/dnh8/29xef9wcnn/bG51/3N1fP9qbHP/ -b3F3/3J0e/9rbnj/eHp//3Byef9sb3n/dXiB/3V4gf9ydHv/b3F5/29yfP9ucHj/cXN6/29yef9ydX3/ -bnB3/3d5f/91eIH/bnF7/3V3ff91d33/bnB3/3N1fP9ucHf/bG51/3V3ff9zdXz/dnh8/2dqcf92eHz/ -dXd9/2dqdP9sb3n/dXd9/21vc/91d33/am13/2xudf9tb3P/bW9z/2xudf9wcnn/bG51/2psc/9zdXz/ -c3V8/3N1fP9wcnn/bG51/2xudf9vcXX/eXyG/25xe/91eIH/bnF7/2xvef9ucXv/bnF7/25xe/9wcnn/ -dXd9/3V4gf9sb3n/cHJ5/2psc/91d33/c3V8/2xudf9ucHf/bG95/2ptd/94eX3/bnB3/3V3ff9ucHf/ -cHJ5/3Byef9qbXf/am13/2xudf9qbHP/bG51/2xvef9ucXv/bG51/2dqdP91d33/bG95/3V4gf9maXP/ -bG95/3V3ff9zdXz/bG51/2psc/9sbnX/bnF7/2ptd/9wc33/d3l//2xudf9wcnn/dXd9/25wd/9ucXv/ -dXd9/3V4gf91eIH/c3Z//3Byef9sb3n/bnB3/25wd/9sbnX/bG51/3V3ff9ucHf/d3qD/3V4gf9ucHf/ -f4GH/3V4gf9tb3P/b3F1/3V3ff9ucXv/dXiB/3Bzff9nanT/bG95/25xe/9ucHf/dXd9/21vc/91d33/ -bnB3/25wd/93eoP/bnB3/3N1fP9ucHf/bW9z/3Z4fP9ucHf/cHJ5/3Byef9ucHf/c3V8/25wd/9ucHf/ -bnB3/29xdf91d33/bnB3/21vc/9sbnX/am13/2psc/9wc33/bG95/2ptd/9ucXv/Z2p0/2psc/9iZW7/ -Zmlz/2ptd/9nanT/Zmhu/2ptd/9maXP/Zmlz/2dqcf9maG7/ZGdx/2Rncf9kZ3H/Zmlz/2Jlbv9nanT/ -YmVu/2BjbP9kZ3H/bG95/2xvef9gY2z/Zmhu/2RmbP9nanT/ZGdx/11gav9kZ3H/Z2p0/2Zpc/9nanT/ -am13/11gav9maXP/bG95/2xveP9oa3T/Zmlz/2ptd/9qbXf/bG51/21vdv9wc3z/bG95/2ptd/9qbXf/ -Zmlz/3N1fP9sbnb/cXN5/3F0ff90d3//bnB1/25wd/9vcXn/bXB6/25weP9wc33/bW92/2psc/9vcnv/ -am13/29yfP9ucXv/bG51/25wd/9ydHv/bnF6/3d6gv9ydHv/c3Z//3V4gf91eIH/e32D/3V4gf90dn3/ -e32D/3d6g/9xdH7/e32G/3d5ff91eIH/dnh9/3V4gf90dn3/eXuA/3x/h/94eoH/enyC/3l7gf99foH/ -c3Z//3N2f/94eoD/cXN5/3p7gP9xc3f/bG95/3V3ff91d33/bW92/21vdv9tb3f/aGt1/2ttdP9oa3X/ -bG95/2xvef91d33/c3Z//3Byef9wc33/dXd9/2ptd/9wc33/bG51/2xudf91d33/cHJ5/3Z4fP9nanH/ -dnh8/3N2f/9sbnX/bW9z/3N1fP9ucHf/d3l//25wd/9ucHf/b3F1/21vc/9sbnX/c3V8/21vc/9qbXf/ -cHN9/3V3ff9zdXz/c3V8/21vc/9sbnX/bG51/3N2f/9qbXf/bnF7/2dqdP9maXP/Z2px/2dqcf9maXP/ -ZGdx/2xvef9wcnn/amxz/2psc/9maXP/c3V8/25xe/9sbnX/am13/2psc/9sbnX/c3V8/2xudf9sb3n/ -bG51/2ptd/9qbXf/am13/2xvef9sbnX/bG51/2xudf9ucXv/cHN9/2ptd/9ucHf/d3l//25wd/93eX// -amxz/25wd/92eHz/dXd9/2xudf9qbXf/bG51/3V3ff9sb3n/bG95/3d5f/9qbXf/bG95/3Bzff9sbnX/ -cHJ5/3V3ff9zdn//c3Z//3Bzff9ucHf/bG95/25wd/9sb3n/bnB3/2xvef91d33/bnB3/3l8hv93eX// -bW9z/35/g/93eX//bnB3/2xudf9zdXz/bnB3/3V3ff9wcnn/Zmlz/29xdf9zdXz/bnB3/3Z4fP9tb3P/ -c3V8/3N1fP9vcXX/e32D/25wd/9wcnn/bnF7/2xudf9zdXz/am13/2xvef9qbXf/am13/2ptd/9tb3P/ -bG51/2xudf9vcXX/c3Z//25xe/9ucHf/bG95/2xvef9ucHf/dnh8/3Byef9ucHf/cHJ5/25wd/9ucHf/ -amxz/3Byef9zdn//dXiB/3Bzff97fYP/c3Z//3V4gf9sb3n/bnB3/29xdf9ucHf/bG51/3Byef9qbXf/ -c3V8/2dqdP9nanT/Z2p0/3Bzff9sb3n/ZGdx/2ptd/9sbnX/c3V8/2xudf9kZ3H/bG51/25xe/9nanT/ -bG95/2xvef9iZW7/am13/25xef9vcnr/am13/2dqdP9ucHf/bG51/21vc/9tb3T/cnV8/25xev9qbXf/ -bnB3/25wd/93eH3/bW92/3Byef9vcXr/bG95/2dqc/9naXP/Zmlz/2Nmb/9nanH/aGp0/2Vocf9maXP/ -bG95/2psc/9ucXv/bG95/2Rncf9qbXf/bG95/2ptd/9wc33/bW9z/2ptd/9ucXv/am13/25xe/9sb3n/ -bG51/3V3ff9sb3n/bG95/3N1fP9nanT/bG95/2ptd/9ucHf/bnB3/29xef91d33/bG50/2xveP9qbXf/ -cHN9/2psc/9sbnb/bG95/2xud/92eH7/bG95/2xudf9zdXz/bnF7/2ptd/9tb3P/bnB3/2xvef9sb3n/ -bnB3/3d5f/9sbnX/dXd9/3Byef9ucHf/c3V8/3V3ff9ucHf/dXd9/2xvef9qbXf/c3Z//25xe/91d33/ -am13/3l7gf93eX//cHJ5/3N1fP91eIH/cHJ5/3t+h/9wcnn/bG95/29xdf9ucHf/bG51/3V3ff9tb3P/ -bG51/3V3ff92eHz/c3V8/3Byef9sbnX/amxz/2xudf95e4H/bG51/3Z4fP9ucHf/bG51/3Byef9ucHf/ -cHJ5/25wd/91d33/eHl9/29xdf9sb3n/bG95/3V4gf93eX//bnF7/3d6g/9zdn//c3Z//3l7gf9zdn// -dXiB/3V3ff95e4H/e32D/3Z4fP95e4H/dXd9/3N2f/91eIH/dXiB/3d6g/9zdXz/bnF7/36Ahv93eoP/ -foGK/3V3ff9zdn//d3qD/3t9g/9wc33/bnB3/2xvef9zdXz/cHN9/3Bzff91eIH/bnB3/25wd/9zdXz/ -bG51/2xudf9zdXz/dXd9/3Bzff91eIH/cHJ5/25xe/9wcnn/bnB3/2xvef9ucHf/dnh8/25wd/95e4H/ -d3l//3Byef9+f4P/dXd9/25wd/9sbnX/c3V8/2xudf91d33/bG95/2Rncf9qbHP/am13/2dqcf9ucXv/ -am13/2ptd/9qbXf/Z2px/3N2f/9sbnX/bnF7/25xe/9sbnX/c3V8/2xvef9sb3n/bG51/29xdf9sb3n/ -bnB3/2xvef9ucXv/bnB3/3N2f/9sb3n/bnB3/25wd/9wcnn/b3F1/3Z4fP9ucXv/bG95/25xe/9wc33/ -bnF7/2xvef9zdn//c3Z//3V4gf9wc33/eXuB/3N2f/9zdn//bnB3/25wd/9tb3P/bnB3/25wd/9zdXz/ -bG51/3N1fP9qbXf/Z2px/25wd/92eHz/bnF7/2dqdP9sbnX/bnB3/3Bzff9ucHf/Z2px/21vc/9sb3n/ -Z2p0/2ptd/9sb3n/ZGZs/2xudf9ucXv/b3J6/2ptd/9qbXf/bG95/2xvef9qbHP/bW9z/3J1fP9wcnz/ -am13/25wd/9ucHf/dXd8/2xudf9vcnj/bnF7/29yfP9nanT/ZGdx/2ptd/9kZ3H/amxz/2ptd/9sbnX/ -am13/2xvef9sbnX/cHJ5/3N1fP9qbHP/bG51/25wd/9ucHf/dXd9/2xudf9sb3n/cHN9/2ptd/9wc33/ -bG95/2xudf9wc33/bnB3/3Byef91d33/bG51/3N1fP9ucHf/bnB3/2xudf9ydHv/dnh+/25wd/9vcXn/ -bnB3/3Z4fP9sbnX/bnB3/29xef9tb3X/dnh9/3Byef9vcXX/dnh8/3N1fP9ucHf/b3F1/2xudf9tb3P/ -bG51/2xudf9wc33/b3F1/3Z4fP91d33/bG51/25xe/9wc33/bG51/3V3ff9sbnX/amxz/3N1fP9ucHf/ -c3V8/2Zobv9wc33/cHN9/2ptd/9vcXX/c3V8/29xdf92eHz/bW9z/2ptd/9sbnX/bG95/2dqdP9wc33/ -bG51/2xudf9zdXz/dXd9/3Bzff9wcnn/bG51/21vc/9qbHP/c3Z//2xudf9zdXz/bnB3/2xudf9zdXz/ -bW9z/2ptd/9tb3P/bnF7/3Z4fP9ucHf/bnB3/2xvef91eIH/dXd9/2xvef9zdn//bnB3/2xvef91d33/ -bG95/25wd/9ucHf/c3Z//3N2f/9ucXv/cHJ5/25xe/9ucHf/bnF7/3N2f/9zdn//bnB3/2dqdP91eIH/ -bnF7/3d5f/9sb3n/b3F1/3Bzff93eX//b3F1/25wd/9qbXf/c3V8/3Byef9ucHf/eHl9/25wd/9wcnn/ -cHJ5/2xvef9wcnn/c3Z//3d5f/9qbHP/Z2p0/2dqcf9sbnX/Z2px/2dqdP9nanT/bG51/3N1fP9qbXf/ -dXiB/3V3ff9sb3n/e32D/3V3ff9qbXf/am13/3Bzff9qbXf/dnh8/2ptd/9kZ3H/bG51/3Z4fP9ucHf/ -dnh8/3Byef9wc33/dXiB/25xe/97fof/bnF7/3Bzff9wc33/bnF7/3d5f/9ucXv/cHJ5/25wd/9wcnn/ -bnF7/25wd/9ucHf/cHN9/25xe/9zdn//cHN9/3N1fP9ucXv/bG95/25wd/93eX//bG95/3Byef9qbXf/ -bG51/25xe/9tb3P/dXd9/25wd/9ucXv/bnB3/3h5ff9wcnn/dXd9/2xudf9qbXf/bG51/2ptd/9qbHP/ -bG95/2Rncf9ucXv/ZGdx/2Jlbv9kZ3H/c3V8/25xe/9qbXf/bG51/25wd/9zdXz/c3V8/2Zobv9tb3P/ -bnB3/2xudf9ucHf/bG95/2RmbP9qbXf/bW93/25xef9rbnf/am13/25wd/9zdXz/bnB3/25wd/91d3z/ -dXd7/25wd/9tb3P/bW9z/3N1e/9sb3n/cnR6/3J0e/9xc3r/bG51/2psc/9ucHf/bG95/3Bzff91d33/ -bnB3/25wd/9wcnn/bG51/3Byef9ucHf/bnB3/2xvef9zdn//bnF7/3V4gf9ucXv/cHN9/3V4gf9zdXz/ -dXiB/3Bzff9zdXz/dXiB/3Bzff93eoP/dXiB/25xe/9wc33/bnB3/2xvef9tb3n/dHZ8/3h6g/9tb3j/ -cHN8/25wd/94eX3/Z2px/25weP9sbnb/cHJ5/3h6gf91eIH/cHN9/3t9g/91eIH/c3V8/3Byef9ucXv/ -cHJ5/25xe/9ucHf/d3qD/3Byef91d33/cHN9/3Byef9wc33/dXd9/2xvef91d33/cHJ5/2dqdP93eX// -bnF7/3h5ff9nanH/dXd9/3V3ff9wcnn/b3F1/3N1fP9ucHf/d3l//21vc/9sbnX/bG51/25wd/9nanT/ -bnF7/2xudf9qbHP/dXd9/3V3ff9wc33/bnF7/2xudf9qbXf/am13/3V3ff9wcnn/dXd9/25wd/9qbXf/ -cHN9/25wd/9ucHf/bW9z/25xe/95e4H/bnB3/25xe/9ucHf/eXuB/3V4gf9ucXv/dXd9/25wd/9ucHf/ -c3Z//25wd/9ucHf/bG95/3Byef9ucXv/Z2px/25wd/9vcXX/b3F1/29xdf91d33/bnF7/2ptd/9kZmz/ -bnF7/2xudf91d33/Z2p0/2psc/9ucXv/c3V8/2dqdP9nanT/Z2p0/3Bzff9sb3n/bG51/3N1fP9maXP/ -bnF7/3Bzff9sbnX/amxz/2xvef9wc33/bnB3/3Byef9sb3n/c3Z//2xvef9sb3n/bG95/2xvef9zdn// -b3F1/3l7gf93eX//c3V8/36Ahv93eX//bG95/2xvef95e4H/bnF7/3V4gf9ucHf/Z2px/25xe/93eX// -bnF7/3d5f/9ucXv/c3V8/3Byef9tb3P/eXuB/2xudf9ucHf/cHJ5/25wd/9zdXz/bnB3/25wd/9sbnX/ -am13/2psc/9nanT/amxz/2ptd/9sbnX/c3V8/21vc/9qbHP/am13/2xvef9qbXf/d3l//2xudf9sb3n/ -am13/2ptd/9wc33/am13/3N1fP9wcnn/bnB3/25wd/9zdXz/bG95/3V3ff9vcXX/b3F1/21vc/9tb3P/ -am13/25xe/9maXP/bG95/2Zpc/9kZ3H/Z2p0/3N1fP9sb3n/Zmlz/2xvef9qbXf/c3V8/2xvef9maXP/ -bG51/25xe/9vcXX/bnB3/29xdf9nanH/bW9z/2ttdP9sb3n/bG92/2xudf9tb3P/c3V8/2xudf9ucHf/ -dHZ9/29xef9tb3P/bG51/2psc/9zdXz/a254/29xev9ydHv/b3J7/21vc/9nanH/bG51/2dqdP9qbXf/ -bnF7/2psc/9nanT/bG95/2psc/9qbXf/bG95/2Jlbv9qbHP/am13/2psc/9sb3n/bG51/2xvef9wc33/ -am13/3Z4fP9vcXX/bG51/3Byef9ucHf/c3V8/3Byef9sbnX/c3Z//25wd/9qbXf/Z2p0/29yfP94eoP/ -b3F4/3V3ff9ucHf/dXd9/2Zpc/9sb3n/am13/2xud/90dn3/cHJ6/2xudf94eX3/cHJ5/2xudf9qbXf/ -am13/2xudf9sbnX/am13/3N1fP9sbnX/dXd9/25wd/9tb3P/cHJ5/25xe/9qbHP/c3V8/21vc/9qbHP/ -dnh8/3Bzff91eIH/Z2px/25xe/9zdn//bnB3/25wd/9wc33/bG95/3d5f/9vcXX/bnF7/3N1fP9zdn// -am13/3N2f/9zdn//bnB3/3d5f/93eoP/dXiB/3Bzff9wc33/bG95/2xvef91eIH/cHJ5/3N2f/9ucXv/ -b3F1/3V3ff9sb3n/cHJ5/29xdf9wcnn/d3l//25wd/9vcXX/bG51/3V4gf91eIH/cHJ5/3V4gf9wcnn/ -cHN9/3d5f/9ucHf/cHJ5/25wd/9sb3n/cHJ5/2psc/9ucHf/cHJ5/29xdf9sbnX/dnh8/25wd/9sbnX/ -Zmhu/25wd/9tb3P/dXd9/2ptd/9sbnX/bnF7/2xvef9kZ3H/Z2p0/2Zpc/9sb3n/Z2p0/2dqdP9wc33/ -Z2p0/3Bzff9wc33/am13/2xudf9ucXv/c3V8/25xe/9zdXz/bG51/3Byef9ucHf/bnB3/25wd/9vcXX/ -dXd9/2xudf94eX3/dXd9/3Byef93eoP/c3V8/2xudf9sbnX/eHl9/3Byef91d33/amxz/2Jkav9sbnX/ -bnF7/2psc/9wcnn/Z2px/2Zpc/9maXP/ZGdx/3Bzff9qbHP/amxz/2xvef9qbXf/am13/2ptd/9qbXf/ -bG51/2psc/9sbnX/bG51/2dqdP9qbXf/am13/25xe/9qbHP/bG51/2ptd/9wc33/am13/3N2f/9qbXf/ -cHN9/2ptd/9ucHf/dXd9/25wd/91d33/bnB3/3Byef9wcnn/cHJ5/21vc/9ucXv/bG51/25wd/9qbXf/ -am13/2ptd/9wc33/Z2p0/25xe/9qbHP/Z2px/2xvef93eX//c3Z//2xvef9ucXv/bnB3/3Z4fP9wcnn/ -amxz/2xudf9zdn//bnB3/2xvef9ucXv/Zmlz/25xe/9rbXT/b3J6/29xdv9ucHf/bnB3/3Bzff9sb3n/ -bnB3/3Z4fv9ucXr/b3F1/25wd/9tb3P/dnh+/2xvdv9tcHr/c3V7/29yfP9qbHP/YmVu/2xudf9qbXf/ -bG95/3N1fP9sbnX/bG51/25xe/9ucXv/bnF7/3N1fP9qbHP/cHJ5/25xe/9wcnn/d3l//29xdf91eIH/ -dXiB/3V4gf95e4H/c3V8/25wd/91eIH/bnF7/3N2f/93eoP/cHN9/3V4gf9ucXv/bG95/2ptd/9wc3z/ -dnh//3Byef91eIH/c3Z//3t+h/9wc33/d3mC/3Z4f/9ydHn/dHZ+/3BzfP9sbnb/cHN9/3Byef9tb3P/ -bG95/2xudf9vcXX/bnB3/2xvef9zdn//d3l//3l7gf93eoP/cHN9/3d6g/93eoP/bnB3/3d5f/9zdXz/ -cHN9/3t9g/9zdn//dXiB/2Zobv9ucHf/dXd9/2xvef9ucHf/c3Z//2xvef93eX//b3F1/25wd/9tb3P/ -cHJ5/2dqcf9ucXv/c3V8/2xvef91d33/eXyG/3d6g/91eIH/c3Z//25wd/9qbXf/eXuB/3Bzff9zdn// -dXiB/3Bzff95fIb/dXd9/3l7gf91d33/eXuB/3+Bh/9zdn//dXiB/3Z4fP+Bg4r/f4GH/3d5f/99foH/ -dXd9/3d5f/9+f4P/eHl9/3h5ff93eX//d3l//3l8hv9ucXv/dXiB/3d6g/9zdXz/c3V8/3t9g/93eoP/ -c3Z//2xvef9zdn//dXiB/3l8hv9wc33/cHN9/25xe/93eX//bnB3/25wd/9sbnX/cHN9/25wd/9sb3n/ -cHN9/2xudf91d33/dXd9/3N1fP9vcXX/cHJ5/3h5ff9wcnn/dXd9/25xe/9zdn//cHN9/25wd/9wcnn/ -c3V8/3V4gf9zdn//e36H/3t+h/95fIb/f4GH/3t+h/9wc33/dXd9/3+Bh/97fYP/foGK/3d6g/9ucXv/ -dXiB/3l8hv9zdXz/eXuB/3Bzff9ucXv/bG95/25wd/95fIb/bnF7/25xe/9wc33/bnF7/3Bzff9wcnn/ -bnF7/3N1fP9wcnn/bnF7/2xvef9ucHf/bW9z/25wd/9zdXz/bnB3/2xvef9ucXv/d3l//25xe/93eoP/ -bnF7/3N2f/9wc33/bG95/3V3ff9sb3n/dnh8/25wd/9zdXz/bnB3/25xe/9ucHf/cHN9/2xudf9sbnX/ -bW9z/2ptd/9tb3P/cHN9/2ptd/9ucHf/Z2p0/2Zpc/9nanH/dXd9/3Byef9nanH/bG95/2xudf9wc33/ -am13/2dqdP9sbnX/bnF7/2ptd/9sb3n/bG95/2BjbP9nanT/amxz/2xvef9rbXX/bG51/2dqcf9nanT/ -ZGdx/2Zobv9qbXf/Zmlz/2Jlbv9nanH/ZGdx/25wd/9sb3j/bW92/3N1ef9tb3b/bnB3/2dqdP9ucHf/ -bnB3/25xe/9zdn//bnB3/2xvef9ucXv/bnF7/25xe/9zdn//am13/3Bzff9zdXz/cHN9/3l7gf9wcnn/ -c3Z//3Z4fP9zdXz/eHl9/2xudf9sbnX/cHJ5/25wd/9wcnn/c3V8/2psc/9wcnn/am13/2dqdP9qbHP/ -bnB3/3R3fv9rbnX/bnB3/21vdf91eIH/Z2p0/2xvef9sb3n/bG92/3R2ff9wc33/bG95/3Bzff9zdn// -cHJ5/3N2f/9wc33/cHN9/3V4gf9zdXz/eXuB/2xudf9zdn//c3Z//2xvef9zdXz/dXd9/2xvef95e4H/ -cHJ5/25wd/91eIH/bnF7/3d6g/9maG7/bG95/3V3ff9sb3n/bnF7/3d6g/9wc33/eXuB/25wd/9ucHf/ -bW9z/3N1fP9qbHP/bnF7/2xvef9nanT/c3V8/3V3ff9qbXf/bG51/2xvef9qbHP/ZGdx/3N1fP9qbXf/ -cHJ5/25wd/9tb3P/cHJ5/2xudf9qbXf/amxz/2xvef93eX//Z2px/21vc/9sbnX/d3l//3N1fP9ucHf/ -dnh8/2xvef9ucHf/eHl9/29xdf9qbXf/amxz/25wd/9wcnn/bnB3/29xdf9tb3P/am13/2xudf9zdXz/ -bnF7/2ptd/9nanH/cHN9/2psc/9wc33/bG51/2xudf9sb3n/c3V8/2Rncf9nanH/YmVu/25xe/9nanT/ -bG51/3Bzff9qbXf/bG95/3Bzff9sb3n/bG51/25xe/93eX//cHN9/3d5f/9ucXv/c3Z//3Bzff9ucHf/ -bnB3/2xvef91d33/b3F1/3Z4fP94eX3/c3V8/3l7gf91d33/bG51/2dqdP93eX//bnB3/3l7gf9wcnn/ -Z2px/29xdf94eX3/bnB3/3l7gf9ucHf/bG95/3Bzff9ucXv/d3qD/3N2f/93eoP/e32D/3d5f/9+f4P/ -d3l//3d5f/97fYP/ent//3t+h/95e4H/eXuB/3l7gf97fYP/e32D/3V4gf93eX//fX6B/3+Bh/93eX// -f4KM/3d6g/93eoP/cHN9/2xvef91d33/bnB3/3V3ff9qbXf/bG95/2ptd/9ucXv/amxz/2xvef9qbHP/ -amxz/2dqcf9nanH/Zmhu/2dqdP9nanH/bG51/2Rncf9dYGr/XWBq/2xvef9nanT/YGNs/2Zpc/9sb3n/ -bnF7/25xe/9qbXf/bG51/2xudf9ucHf/dXd9/3V3ff9maG7/bG51/3N1fP90dn7/cXN5/25wd/9vcXX/ -bnF7/2xvef9vcXX/dXd9/25xe/9qbXf/bG95/25wd/93eH3/c3V8/3N1e/93eX//c3Z//25xe/9nanT/ -bnB3/2xudf9ucHf/dnh8/25wd/9qbXf/bnF7/25xe/9wc33/bnF7/2xvef9ucXv/c3V8/25wd/9zdXz/ -bnB3/3V3ff92eHz/cHJ5/3V3ff9qbXf/bnB3/2xvef9ucHf/cHJ5/3Byef9nanT/cHJ5/25xe/9qbXf/ -bG51/25xe/90d37/cHN6/3V3gP9wc33/foGK/3N1fP91eIH/cXR9/21wev9ydX3/cHN8/2ptd/9sb3n/ -bG95/2xudf9nanT/Z2px/2Zpc/9maXP/Z2p0/25xe/9zdn//dXiB/3l7gf9wc33/c3Z//3d5f/9qbHP/ -d3l//29xdf9qbHP/c3V8/29xdf93eX//Z2px/25wd/94eX3/bnB3/3Byef91d33/cHJ5/3d5f/9sb3n/ -bG95/25wd/9ucHf/Z2p0/3Bzff9sb3n/bW9z/3N1fP91d33/bG95/2ptd/9ucXv/bW9z/2Zpc/91d33/ -bG95/3Bzff9qbXf/bG51/2xvef9qbHP/bG51/2psc/9qbXf/dXd9/2Rncf9qbHP/Zmlz/3Bzff9zdXz/ -Zmlz/3V3ff9qbHP/amxz/3V3ff9sbnX/am13/2dqdP9sb3n/bG95/2ptd/9qbXf/bW9z/29xdf9ucHf/ -eXuB/3Bzff9sb3n/am13/3Bzff9ucHf/eHl9/25xe/9wc33/d3qD/3t9g/9ucHf/bnB3/2ptd/93eoP/ -c3Z//3N1fP95e4H/c3V8/3N2f/91eIH/eXuB/3N1fP9zdn//d3qD/2ptd/9wc33/bG51/2ptd/9nanT/ -Zmlz/2Zpc/9iZW7/bG95/2psc/9wc33/dXd9/2xvef93eoP/bnF7/2ptd/9sbnX/dXd9/2ptd/95e4H/ -bnF7/2dqdP9sb3n/eHl9/29xdf93eX//bnB3/25xe/9ucXv/bnB3/3l7gf9ucXv/c3Z//3V4gf9zdXz/ -dXiB/3Bzff9wcnn/bnB3/3Byef91eIH/cHJ5/25wd/9sb3n/bG95/3Bzff9ucHf/bW9z/3V3ff94eX3/ -cHJ5/3l7gf9wcnn/bG95/25xe/9qbHP/c3V8/2ptd/9wc33/bW9z/3Byef9ucHf/c3V8/29xdf91d33/ -bG95/25xe/9ucHf/bG95/3Byef9wc33/bnB3/25xe/9zdXz/bG95/3N2f/97fof/e32D/25xe/93eoP/ -eXyG/3V4gf93eoP/cHJ5/25xe/9zdXz/c3V8/3Bzff9zdn//ZGdx/25wd/9tb3T/cXN6/3Fzev9ucXr/ -bnB3/2xvef9sb3n/b3F1/3d5f/9ucHf/bW9z/25wd/9ucHf/d3l//3J0ff9xdHv/cnR7/29xeP9ucHf/ -Z2px/25wd/9sbnX/bnB3/3N1fP9tb3P/Zmlz/2xvef9qbXf/cHJ5/3Byef9ucHf/bG51/21vc/9sbnX/ -bnF7/2xudf9wc33/c3V8/2xvef92eHz/bG51/2ptd/9sbnX/bnB3/3N1fP9ucHf/Z2p0/2xvef9ucHf/ -bG51/2psc/9vcXn/c3V7/25wdf9xc3r/bW9z/3d5f/9qbXf/am13/2ttdP9oa3X/c3Z9/3V3ff9sb3n/ -bnF7/3N1fP9sb3n/bnF7/2xvef9wcnn/c3V8/25wd/91eIH/am13/2xvef9sb3n/Z2px/2Zpc/9qbXf/ -XWBq/3Byef9maXP/XWBq/2xvef9maG7/c3V8/2Jlbv9qbXf/dXd9/2dqdP9ucXv/c3V8/2xudf9zdXz/ -bG51/2xudf9vcXX/cHJ5/29xdf9zdn//c3Z//3Bzff91eIH/eXyG/3V4gf9wc33/cHN9/25wd/9qbXf/ -d3l//25xe/9wcnn/bnB3/21vc/9zdXz/bG51/2ptd/9qbHP/bG95/3V3ff9iZW7/bG51/2Rncf9sb3n/ -cHJ5/2Jlbv9qbXf/Z2px/2Zobv9ucHf/Zmlz/2Rncf9kZ3H/Z2p0/2xudf9qbHP/bG51/2dqdP9sbnX/ -am13/3V3ff9ucXv/bnB3/2xvef9zdn//bG95/3h5ff9ucHf/cHJ5/3V3ff94eX3/bG51/2xudf9nanT/ -cHN9/25wd/9tb3P/bnF7/2ptd/9sb3n/bnF7/3Bzff9qbXf/bnF7/3d5f/9ucHf/c3Z//25wd/9ucXv/ -bnB3/2xvef9ucHf/am13/3d6g/9zdXz/eXuB/3t9g/91eIH/eXyG/3N2f/9ucHf/bG95/3l7gf9wcnn/ -d3qD/25xe/9nanT/bnB3/3l7gf9wcnn/eXyG/3Byef9ucXv/cHN9/25wd/93eoP/bnB3/25wd/9wc33/ -bnB3/3Z4fP9vcXX/bnB3/2xvef9ucHf/cHN9/2xvef9sb3n/bnB3/25wd/9zdXz/b3F1/29xdf91d33/ -dXd9/25wd/95e4H/cHJ5/2xvef9ucXv/Z2p0/3N1fP9qbXf/bG95/2psc/9sb3n/bG51/3Bzff9qbHP/ -cHN9/2ptd/9sb3n/amxz/2dqcf9qbHP/Z2p0/2Zobv9nanH/Z2px/2Rncf9maXP/c3V8/25xe/9maG7/ -c3V8/25wd/9sbnX/dnh8/2ptd/9sb3n/bnB3/25wd/9zdXz/dXd9/2dqcf9wcnn/bW9z/29xeP9sb3n/ -bXB6/2xvef9sb3n/bnB3/3Byef93eX//cHJ5/2xudf9ucHf/am13/3N1fP9sb3n/cXN6/3N1ff9vcXv/ -c3V8/2ptd/9ucHf/bnB3/25xe/9zdn//bnB3/2xudf9wcnn/cHN9/3N2f/9wc33/bnB3/25xe/9ucXv/ -cHJ5/3N2f/9wcnn/d3l//3V4gf9wc33/d3l//2ptd/9ucXv/bnB3/3Bzff9wc33/cHJ5/25wd/9wc33/ -cHJ5/2xudf9ucHf/b3F4/3N1ev9pbHP/a253/2Vocv9wcnn/ZGdx/2Vocv9laHL/YmVv/3J0fP9zdoD/ -am13/3Bzff9zdn//bnB3/25wd/9ucHf/cHJ5/3N1fP9ucHf/c3V8/2xvef9wc33/c3V8/21vc/91d33/ -dXd9/2psc/91eIH/bnB3/2Zobv91d33/bnB3/3d5f/9maXP/cHJ5/3h5ff9sbnX/c3V8/3Z4fP9sb3n/ -eHl9/25wd/9tb3P/bW9z/3Byef9qbHP/cHJ5/25wd/9sbnX/bG95/3N1fP9ucXv/bG95/2ptd/9sbnX/ -Z2p0/3d5f/9qbXf/cHJ5/3Byef9ucHf/c3V8/2ptd/9wcnn/b3F1/25wd/92eHz/Z2px/29xdf9sbnX/ -cHJ5/3Z4fP9sbnX/dXiB/25xe/9zdn//e36H/3Byef9wc33/c3V8/25xe/9ucXv/cHJ5/25xe/9sb3n/ -bnB3/2xvef93eX//c3V8/25xe/9wcnn/dXiB/2xvef93eX//bnB3/25xe/9ucXv/d3qD/25wd/9qbXf/ -am13/3N2f/9ucHf/bnB3/3Bzff9sb3n/c3Z//3N2f/93eX//bG95/3N1fP91eIH/bnF7/3V4gf9ucXv/ -cHN9/25xe/9wcnn/cHJ5/2ptd/9zdn//bnB3/3N2f/92eHz/cHN9/3t9g/9wcnn/bnB3/25wd/94eX3/ -bnB3/3d5f/9wcnn/Zmhu/25wd/92eHz/bnB3/3l8hv9wcnn/cHN9/3Bzff9zdXz/d3qD/3N2f/91eIH/ -dXiB/25wd/94eX3/bnB3/29xdf9sbnX/bnB3/3Byef9vcXX/bG51/21vc/9sbnX/cHJ5/2xudf9tb3P/ -cHN9/3Bzff9sbnX/bnB3/2ptd/9qbXf/bG95/2Rncf9qbXf/ZGdx/2xvef9qbXf/cHN9/2ptd/91d33/ -am13/3N1fP9ucXv/cHJ5/25wd/9ucHf/cHJ5/25xe/9qbXf/bnB3/25wd/9sb3n/bnB3/3V3ff91d33/ -Z2px/3N1fP9ucXv/bG95/3V4gf9wcnn/bnF7/2ptd/9ucXv/cHN9/3N2f/9nanT/cHN9/2hrcv9qbXf/ -bG52/3Fzev9sbnX/bnB3/21vc/9tb3P/eHqA/2xudf9sbnX/bnB3/25wd/92eHz/bXB6/3Byef9ydHr/ -cXN5/3N1fP9sb3n/cHJ5/25xe/9zdn//bnF7/2xvef9sb3n/cHN9/3Byef9wc33/c3Z//25xe/9ucHf/ -bnF7/3Bzff93eoP/c3V8/3t9g/97fYP/dXiB/3l7gf9zdn//d3qD/3V4gf93eoP/c3Z//3Bzff9wcnn/ -d3qD/3d6g/9wc33/c3V8/3N1fP93eoP/b3J6/3J0fP9rbnj/d3l//25wd/9wcnn/bW90/2xudf90dn3/ -dHd//2dqdP9sb3n/c3Z//2xvef9sb3n/bG95/25xe/9wc33/cHJ5/25xe/9ucXv/c3Z//3h5ff9ucHf/ -c3V8/3N1fP9qbXf/dXiB/3Byef9nanH/cHJ5/21vc/94eX3/Zmhu/25wd/94eX3/bG51/3N1fP91d33/ -am13/3d5f/9sbnX/bG51/2xudf9wcnn/bG51/3N1fP9wcnn/cHJ5/3Byef94eX3/c3V8/2xvef9sb3n/ -bW9z/2Zobv91d33/cHJ5/2xudf9ucHf/am13/3Byef9nanT/am13/2xudf9wcnn/eHl9/2psc/9tb3P/ -amxz/2xvef91d33/am13/3d5f/9qbXf/am13/3d5f/9sbnX/Z2p0/2xudf9ucHf/bG51/21vc/9nanT/ -Z2p0/2xudf9tb3P/dnh8/3Byef9ucHf/bW9z/25xe/9tb3P/c3V8/2xudf9ucHf/bnB3/3d6g/9ucHf/ -bG51/25wd/9zdn//bnB3/25wd/9wc33/bnF7/3N1fP91d33/d3l//3V4gf9zdn//eXuB/3N2f/93eoP/ -c3Z//3N2f/9sb3n/bnB3/25wd/9nanT/c3V8/21vc/9zdXz/c3V8/2xvef93eoP/bnF7/2ptd/9sbnX/ -c3V8/2dqdP91d33/Z2p0/11gav9kZ3H/bG95/2Zobv9wcnn/Zmhu/2ptd/9nanT/Z2px/3Byef9qbXf/ -am13/25xe/9sbnX/bnF7/2ptd/9qbXf/Zmlz/2xudf9wc33/bnB3/2xvef9vcXX/b3F1/3N1fP9ucHf/ -b3F1/3V3ff9ucHf/am13/3V3ff9wcnn/bG51/25xe/9qbXf/am13/2Zpc/9sb3n/bG95/25xe/9qbXf/ -cHN9/2xvef9wc33/bG95/2ptd/9nanH/amxz/2psc/9qbHP/Zmlz/2psc/9sbnX/amxz/2dqdP9ucXv/ -cHN9/2Zpc/9ucHf/bG95/2xudf93eX//bnB3/25xe/9sbnX/cHJ5/3N1fP9wc33/Z2p0/3Bzff9ydX7/ -cnV+/3F0fv9ydX7/cHN9/3Bzff9wcnn/cHJ5/3p9hv9wcnn/cHJ5/3V4gf9zdn//d3l//3J1fv9ydHz/ -dXZ8/3Fzef9zdXz/amxz/2ptd/9sbnX/am13/2ptd/9sbnX/ZGdx/2xudf9nanT/bG51/2xudf9sbnX/ -Z2p0/2xudf9sbnX/cHJ5/2psc/9zdXz/cHN9/2ptd/93eX//Z2p0/3Byef9ucHf/cHJ5/25xe/9qbXf/ -bnB3/3N1fP9zdn//Z2p0/29xdf9vcXb/dnh//3Bze/96fIL/cHN9/36Biv93eX//e32D/3J1fv9vcnv/ -c3aA/3N2gP9nanT/bG51/3Bzff9nanT/am13/2ptd/9sb3n/am13/2psc/9nanH/bnF7/3N2f/93eX// -bnF7/3Bzff91eIH/bnF7/3d5f/9ucHf/amxz/3Byef9tb3P/d3l//2Zobv9ucXv/dXd9/25wd/91eIH/ -dXd9/2xvef93eoP/cHN9/2ptd/9vcXX/cHN9/25wd/91d33/cHJ5/25wd/9sb3n/eHl9/3N1fP9ucHf/ -bnB3/2xudf9iZW7/dXd9/2xvef9qbXf/bnB3/2xudf9ucXv/amxz/2xudf9tb3P/bnB3/3V3ff9kZ3H/ -bG51/2Zpc/9qbXf/cHN9/2dqdP93eX//bG51/2ptd/91d33/ZGdx/2Jlbv9maG7/amxz/2xudf9qbHP/ -Zmlz/2Zobv9maXP/ZGdx/2xvef9maXP/Zmlz/2dqcf9maXP/amxz/2xvef9sbnX/bG51/2xudf91d33/ -am13/2Zpc/9nanT/cHN9/2xudf9sbnX/bnB3/3Byef9zdXz/dnh8/3V4gf9wc33/c3Z//3t9g/9wc33/ -dXd9/3N1fP9wcnn/bnB3/25wd/9zdXz/bG95/3V3ff9wcnn/d3l//3V4gf9zdn//e36H/3d6g/9wcnn/ -c3V8/3d5f/9sb3n/dXiB/3Byef9nanH/bnB3/3d5f/9wcnn/d3qD/25wd/9wc33/bG95/25wd/92eHz/ -cHJ5/25wd/9ucHf/bG51/3Byef9ucHf/cHJ5/2dqdP9sb3n/c3Z//29xdf9ucHf/bW9z/2xvef9zdn// -cHN9/3Byef91eIH/bnB3/21vc/94eX3/dXd9/25wd/9zdXz/b3F1/25wd/9qbHP/c3V8/3Byef9zdn// -bnF7/3N1fP9wcnn/dXd9/3N1fP9sb3n/amxz/2xudf9qbXf/Z2px/2Zpc/9maXP/Z2px/2xudf9maXP/ -bG95/25xe/9nanT/bnF7/2xvef9tb3P/c3V8/2ptd/9qbXf/ZGdx/2xvef9nanT/bG95/2Jlbv9nanT/ -b3F4/25weP9vcXr/bG94/2tud/9qbXf/amxz/2Rncf9zdn//Z2p0/2ptd/9ucHf/bnB3/3Byef9ucHf/ -b3J3/21wev9oa3X/ZGdx/11gav9gY2z/Zmhu/2Rncf9maXP/ZGZs/1xfaP9maXP/YmVu/2Rncf9kZ3H/ -Zmlz/2psc/9qbHP/bG95/2ptd/9maXP/cHN9/3Bzff9qbXf/dXd9/2Zpc/9ucXv/bG95/3N1fP9zdXz/ -bnB3/2xvef9wc33/c3Z//2xudf9sbnX/bW9z/3J0e/9ucXn/cnR7/29xeP95e4H/bnB3/2xudf9qbXf/ -aWt0/25wef9zdn//bG95/3Bzff91eIH/cHN9/3Bzff9zdn//c3V8/21vc/9ucHf/bG51/2xvef9wc33/ -dXd9/2xudf9zdXz/bnF7/2Zpc/9zdXz/Z2p0/2Jlbv9ucXv/bG51/3V3ff9iZW7/cHN9/3d5f/9qbXf/ -bnF7/25xe/9sbnX/c3V8/2Zpc/9gY2z/Zmhu/2Zpc/9maXP/bG95/2psc/9nanH/Z2px/2xvef9sb3n/ -Z2px/2psc/9maXP/YGNs/3V3ff9qbXf/bG51/2ptd/9nanH/am13/2Jlbv9qbHP/Z2px/2ptd/9ucXv/ -Zmlz/2psc/9kZ3H/bnF7/3V3ff9nanT/dXd9/2xudf9wcnn/d3l//2Zpc/9nanH/bW9z/21vc/9sbnX/ -bnB3/25wd/9ucHf/c3V8/25wd/94eX3/bnF7/25xe/9sb3n/c3V8/21vc/94eX3/bG95/25wd/9ucHf/ -d3l//2ptd/9maXP/amxz/3N1fP9sbnX/b3F1/3Byef9vcXX/c3V8/3Z4fP91d33/bnB3/3Byef94eX3/ -bnF7/3V3ff91d33/bnF7/25wd/9sb3n/bG95/2xvef93eX//cHN9/3t9g/91eIH/cHN9/3V4gf9wc33/ -am13/3Byef9zdn//am13/3d5f/9zdn//Z2p0/29xdf95e4H/bnB3/3d5f/9ucHf/c3V8/2xudf9vcXX/ -dnh8/3V3ff9wc33/bnF7/3V4gf9wc33/bnB3/3Bzff9qbXf/cHJ5/3V4gf9zdn//c3Z//3N1fP91d33/ -eXuB/3d5f/9zdn//e32D/3V4gf9zdXz/eXuB/3N2f/9zdn//eXyG/3V3ff93eX//dnh8/3t9g/97fYP/ -dXiB/3Bzff91eIH/c3Z//3d6g/9zdn//cHN9/3N1fP9zdn//c3Z//3N1fP9sb3n/bnB3/25wd/9ucXv/ -am13/3Bzff9wc33/Z2p0/3N1fP9zdXz/b3F1/3V3ff9sbnX/cHJ5/2dqdP91d33/bnF7/3N2f/9qbXf/ -c3Z//25xe/9tcHn/b3J8/29ye/9ucXv/bnF7/25xe/9ucXv/fH+I/3J1fv9zdn//d3l//3t9g/96fIL/ -d3qA/3Z4ff92eX7/cnN6/2xudf9sbnX/Zmlz/2psc/9nanT/am13/2xudf9maXP/bnF7/2dqdP9tb3P/ -cHJ5/2xudf9sbnX/bG51/2xudf9wcnn/amxz/3N1fP9zdXz/bG51/3Byef9iZW7/am13/2ptd/9sb3n/ -Z2p0/2xudf9nanT/bnF7/25xe/9maXP/Z2p0/2xudf9wc33/bnF7/3N2ff9ydHz/gYOK/3V4gf91eIH/ -b3J8/25xev9zdX7/cnV//2hrdf9sb3n/bnB3/25wd/9wcnn/cHJ5/3N1fP9sbnX/am13/2ptd/9wcnn/ -dnh8/3d5f/9sb3n/cHN9/25xe/9ucHf/dnh8/2xvef9kZ3H/c3V8/2xudf94eX3/Z2px/3N2f/93eoP/ -bG95/3N2f/95e4H/bG95/3V4gf9ucXv/am13/25xe/9wc33/bnB3/25xe/9sb3n/bG95/25wd/92eHz/ -dXd9/29xdf9tb3P/Z2px/2dqcf91d33/am13/21vc/9wcnn/am13/2xvef9kZ3H/Z2p0/2Zobv9maXP/ -am13/2Rncf9maG7/XWBq/2Rncf9wcnn/YmVu/3Byef9maXP/Zmlz/3Byef9iZW7/YmVu/2psc/9nanT/ -bG51/2xudf9qbHP/bG51/25xe/9sb3n/dXd9/3Byef9ucHf/bG51/3N2f/9vcXX/eHl9/25wd/9vcXX/ -bnB3/3d5f/9ucHf/bnB3/25wd/91d33/bnB3/29xdf9wcnn/bG51/3Byef9zdn//d3l//3Bzff9wc33/ -d3l//2xvef9zdXz/dnh8/25xe/9ucHf/bnB3/29xdf9ucHf/dnh8/3Byef94eX3/dnh8/3N1fP92eHz/ -bnB3/2xudf9vcXX/c3V8/2psc/91d33/dXd9/2psc/9vcXX/d3l//3Byef93eX//bnF7/3N2f/9ucHf/ -b3F1/3h5ff9wc33/c3V8/25xe/9wc33/c3Z//25wd/9ucHf/bG95/25wd/9zdn//c3V8/25xe/9wc33/ -cHN9/3l8hv9zdn//cHN9/3d6g/9ucXv/bnB3/3t9g/93eoP/dXiB/3d6g/9wc33/c3Z//3N1fP9wc33/ -bnF7/3Bzff9wcnn/c3Z//3N2f/95e4H/c3Z//25xe/9vcXX/bnB3/2xvef9vcXX/am13/2xudf9vcXX/ -bnB3/2xudf9zdn//cHJ5/2xudf9wc33/bnF7/29xdf93eX//bnB3/3V4gf9ucXv/eXuB/3V4gf95e4H/ -Z2p0/2xvef9wc3z/dHeA/3Z5gv9ydX//b3F4/25wd/9ucHf/am13/3d5f/9ucHf/bnB3/2xudf9wcnn/ -bnF7/2xvef9tcHr/dXd+/3V4gP9wc33/cHJ5/2xvef9wc33/c3Z//3d6g/91eIH/cHN9/3d6g/9wc33/ -bnF7/3V4gf9zdn//cHN9/3Bzff9zdn//d3qD/3Bzff95fIb/e36H/3N2f/97fYP/cHN9/3t9g/9zdn// -c3Z//3N2f/9sb3n/bG95/3N2f/9wc33/bG95/2xudf9ucHf/c3V8/2xud/9ucXr/a210/3d6g/9qbXf/ -bG51/2psc/9sbnX/b3J8/3BzfP9rbXT/bG51/25wd/9ucHf/bG95/3V4gf9zdn//cHN9/3N1fP9ucHf/ -bG95/3V3ff92eHz/bG51/3N1fP9ucHf/b3F1/3V3ff9sbnX/bG51/2xvef9qbXf/c3V8/2Rncf9zdXz/ -dnh8/2xudf9ucHf/dnh8/2xudf91d33/am13/2Rncf9qbHP/bnB3/2xudf9wc33/bG51/2xudf9qbXf/ -cHN9/3Byef9sbnX/bW9z/2psc/9qbHP/dXd9/2xvef9ucHf/c3V8/2xudf9ucHf/Zmhu/3Byef9tb3P/ -bnB3/25wd/9nanT/am13/2dqdP9ucXv/c3V8/2ptd/93eX//bnB3/25xe/94eX3/Zmhu/2dqdP9ucHf/ -bnB3/2xvef9ucHf/bnB3/25wd/9zdn//c3Z//3l7gf9ucXv/bnF7/3Bzff93eX//cHN9/3l7gf9zdXz/ -bnB3/3N2f/97fYP/cHJ5/25wd/9ucHf/c3Z//2xvef9wcnn/c3Z//2xvef9wcnn/c3V8/3Z4fP9ucXv/ -bG95/3d5f/9wc33/c3Z//3d5f/9ucXv/bnB3/3Byef9ucHf/bnB3/3d5f/9zdn//eXuB/3l7gf93eoP/ -d3l//25xe/9sbnX/b3F1/3N1fP9qbHP/c3V8/3N1fP9qbHP/bG51/3N1fP9tb3P/dXd9/2psc/9ucXv/ -bW9z/2xudf92eHz/c3V8/25wd/9wcnn/cHJ5/3N1fP9ucHf/bnB3/25wd/9vcXX/bnF7/2xvef9sb3n/ -bnF7/25xe/9zdn//c3Z//3Bzff95e4H/c3Z//3Bzff99foH/eXuB/36Ahv97fYP/d3l//3V3ff91d33/ -dXiB/3d6g/93eoP/c3Z//3d6g/93eoP/e36H/3l8hv93eoP/cHN9/3N1fP9zdn//cHN9/3Byef9sb3n/ -b3F1/25xe/9ucHf/bnF7/3Byef9qbHP/cHJ5/2xudf9tb3P/dnh8/2xudf9wc33/bG95/3N2f/9zdn// -c3Z//2dqdP9sb3n/cHJ5/29yfP92eYD/cnV+/29xeP9tb3P/b3F1/2xudf93eX//bG51/2xudf9ucHf/ -c3V8/3V3ff9wc33/cnR8/3V3ff9xdH3/cHJ5/2xvef9qbXf/cHN8/25xe/9ucXv/c3V8/2ptd/9zdn// -bnB3/2xudf90dn3/bnF7/2xudf9sbnX/cHJ5/25xe/9sbnX/cHJ5/3V3ff9tb3T/dHd9/2dqdP9zdXz/ -am13/2xvef9sb3n/am13/2Vocf9sb3n/am13/2Nmb/9qbHP/am13/3J0e/9ucHf/cXN6/2tud/93eoP/ -cHJ5/2xudf9sbnX/aGt0/21veP9xdH3/Z2p0/2ptd/9qbXf/am13/2ptd/9ucXv/dXd9/3Byef9vcXX/ -b3F1/25xe/9wc33/dXd9/2xudf9nanT/am13/2psc/91d33/bG51/2psc/9sbnX/Z2p0/3Byef9kZ3H/ -bG95/25xe/9sbnX/am13/3N1fP9qbHP/dXd9/2xvef9gY2z/Zmlz/2dqdP9nanH/bG95/2psc/9qbHP/ -Z2p0/2ptd/9qbXf/Z2px/2dqdP9kZ3H/ZGdx/3Byef9nanH/Z2px/2xvef9nanT/amxz/2BjbP9qbXf/ -amxz/2dqdP9qbXf/ZGdx/2dqcf9kZ3H/am13/25xe/9maXP/cHJ5/2ptd/9sb3n/dXd9/2Rncf9maXP/ -amxz/2xudf9sbnX/bG51/2ptd/9tb3P/bnF7/25xe/9zdXz/cHJ5/3Byef9sb3n/dXd9/2xudf9zdXz/ -am13/2ptd/9sbnX/cHJ5/2dqcf9kZ3H/Zmlz/2xvef9nanT/amxz/3N1fP9sbnX/bnB3/3V3ff94eX3/ -cHN9/29xdf94eX3/bG95/3N1fP91d33/bnB3/2xudf9tb3P/am13/2ptd/9zdXz/cHJ5/3N1fP91d33/ -c3V8/3h5ff9ucHf/bG95/21vc/9zdXz/Z2p0/3N1fP9zdXz/Zmlz/2dqdP9sb3n/bG51/3V3ff9vcXX/ -dXd9/2xudf9qbHP/dXd9/3N1fP9wcnn/cHN9/2xvef9ucXv/bnB3/25wd/9vcXX/bG51/2xudf9sbnX/ -b3F1/2xvef9ucXv/cHN9/25xe/9wcnn/dXiB/3N2f/9zdXz/dXiB/3N2f/93eoP/dXiB/3Bzff9wc33/ -cHJ5/3Bzff9zdn//c3Z//2xvef9ucXv/cHN9/3d5f/9zdn//bnF7/3N1fP9zdXz/c3Z//3N1fP9ucHf/ -cHJ5/3Bzff9zdn//cHN9/3V4gf9zdn//cHJ5/3Bzff9wcnn/cHJ5/3d6g/9ucHf/dXiB/3Byef95e4H/ -eXyG/36Ahv9zdn//c3Z//3Bzff9ydX//dnmA/3J1fv9zdn//bnB3/25wd/9sb3n/dXiB/2xvef9sbnX/ -cHJ5/3Z4fP92eHz/c3V7/3J0ff91d33/bnB3/21vd/9pbHb/Zmhx/2ttdf9sb3n/cXN6/3Fzev9tb3P/ -cHJ7/2ttdf9rbXT/cHN9/25xe/9tb3b/a254/25xev9ucXv/bG95/21wev9xdH7/b3F2/3Z4fv9qbXT/ -dXd9/3Bzff9xc3r/dXd9/3R2fv9sbnb/b3F5/29yfP9sb3b/bG52/2xudv9ydX//cXN7/3Z4fv9wcnn/ -foGK/3d6g/9ucHf/bnB3/25wdf9wc3v/dXd9/2ptdv9rbnf/bnB3/25wd/9ydHv/dHZ8/3N1fP9tcHn/ -bXB3/2tueP9ucXv/dXd9/3V3ff9sb3n/bnF7/25xe/9ucHf/eXuB/25xe/9vcXX/bG51/3N1fP92eHz/ -amxz/3V3ff91d33/bG51/2xudf94eX3/bnB3/3h5ff9zdXz/Z2p0/2xudf9ucHf/bW9z/3Byef9ucHf/ -bnB3/2xudf9zdXz/am13/2ptd/9qbXf/Z2p0/2Zpc/91d33/am13/2psc/9wcnn/amxz/2xudf9maG7/ -c3Z//2ptd/9ucXv/c3Z//2xvef9ucHf/b3F1/3V3ff92eHz/b3F1/3V3ff9ucHf/bnB3/3Z4fP9nanT/ -bnB3/3Byef9zdXz/bnB3/3Byef9ucHf/bnB3/3Byef9ucHf/c3V8/3Byef9ucXv/bG95/3V3ff9sbnX/ -bG95/2Zpc/9qbHP/am13/3N1fP9sbnX/amxz/2psc/9ucXv/bG51/2psc/9ucXv/am13/2psc/9ucXv/ -c3V8/2xvef9qbXf/dXd9/2xudf9ucXv/cHN9/2xvef9qbXf/bG51/2xudf9qbXf/cHN9/2xudf9zdXz/ -dXd9/3N2f/9zdn//bG95/3Byef9ucXv/c3V8/25wd/9zdn//d3l//2xvef9ucXv/cHN9/3Byef95e4H/ -cHN9/3l7gf9wc33/bG95/3l7gf9zdn//dXiB/3N2f/9wc33/c3V8/25wd/9wcnn/cHJ5/3Byef9wc33/ -cHJ5/2xvef9wc33/bnF7/3Byef9ucHf/bW9z/3Byef9wcnn/bG51/3N1fP9sbnX/bnF7/3Bzff9tb3P/ -b3F1/25wd/9ucHf/c3V8/3V3ff9sb3n/cHJ5/2xvef91d33/c3Z//3Byef9ucHf/c3Z//3V4gf93eX// -dXd9/3h5ff95e4H/dnh8/3l7gf9/gYf/eXyG/3l7gf97fof/eXuB/3d5f/9/gYf/dXd9/3t9g/91d33/ -foCG/3t9g/97fof/c3Z//3N2f/9xc3r/cHN6/3J1fP9xc3v/cHJ5/2ptd/9nanT/Z2p0/3V3ff9qbHP/ -Z2px/2ptd/9ucXv/cHJ5/2lsdv9rbnj/b3J5/2xudf9rbnb/a252/2hqcv9naXH/a211/25xef9tcHr/ -a21z/3J0fP9tcHj/bG93/3F0fv9ydX3/b3F5/29xev9ydX3/dHd//3Byef9xdHz/eHqC/3V3ff94e4H/ -cXN6/3l8gv91d3//dnmB/3l7g/96fIP/c3V+/3d4fv92eID/dXd+/3F0fv9xc3v/d3qC/3h6gP99f4b/ -dnh//4OFjP9+f4P/ent//3d5f/94eoD/enyC/3p8gP9ydHv/cHN9/25xe/9vcnv/cnV+/3Z4gP92eH// -cnV+/29yev9wc3v/cHJ5/3V3ff92eHz/bnB3/25xe/9wc33/bnF7/3l7gf9wc33/cHJ5/25xe/9wc33/ -c3Z//2dqdP91d33/dXd9/25xe/9wc33/e32D/3Byef97fof/d3qD/3N1fP9wc33/d3qD/3N2f/9zdn// -c3Z//3N2f/9ucXv/bnF7/25xe/9ucHf/bnF7/2xvef9qbXf/d3qD/3N1fP9wc33/cHN9/25xe/9ucHf/ -Zmlz/3V3ff9sbnX/c3V8/3N1fP9ucHf/bnB3/29xdf9wcnn/dnh8/29xdf95e4H/b3F1/25wd/92eHz/ -Z2p0/2dqdP9ucHf/bnB3/21vc/9sbnX/bG51/2xudf9ucHf/bnB3/2xvef9sb3n/bG95/2ptd/92eHz/ -am13/25xe/9maXP/am13/2xudf9wc33/bG51/2Rncf9qbHP/am13/2psc/9qbHP/bG95/2ptd/9nanT/ -bG95/3N1fP9ucXv/am13/3N1fP91eIH/eXyG/3t9g/9zdn//c3Z//3Bzff9zdXz/bnB3/3N2f/9wcnn/ -dXiB/3l7gf91eIH/dXiB/3Bzff9wcnn/cHN9/3N1fP9vcXX/cHN9/3V3ff9qbXf/bG51/3N2f/9wcnn/ -d3l//2xudf9zdXz/bW9z/2xudf94eX3/c3Z//3V3ff9sb3n/bG95/25xe/9vcXX/bG51/29xdf9vcXX/ -bW9z/21vc/9vcXX/c3V8/2xudf9sb3n/bW9z/25wd/9wc33/cHJ5/29xdf94eX3/bnB3/3N2f/91d33/ -bW9z/2xudf9qbXf/bG51/25xe/9ucXv/bW9z/2xudf9ucHf/dXd9/25xe/9ucHf/amxz/2xudf9sbnX/ -bnB3/2xvef9ucHf/b3F1/2xudf9qbXf/c3Z//3N1fP91d33/dXiB/3N1fP91eIH/foGK/3N1fP93eoP/ -c3Z//3t+h/93eoP/e36H/3N1fP9zdn//cXN7/3N2gP96fIP/eXuB/3p8gv91d33/c3V8/3V3ff97fof/ -dXiB/3Bzff9wc33/dXd9/3V3ff90dnz/dXd+/3J1ff9ucXv/bXB5/3Bze/9pa3P/aWx2/3FzfP90d37/ -c3Z//3F0fP92eH//cnR9/3Bze/90d4H/dHeA/29yfP9xdHz/bXB4/29yfP9vcXv/bG95/21weP9tb3b/ -cHJ5/2ttc/92eHz/bnF6/25wef9ydX3/bXB6/25wd/9tcHn/bW92/29xd/9tb3b/bG54/3Fzd/90dnz/ -dHZ8/2xvef95fIb/cHN9/2xvef9wcnn/bnF7/3R2fP90dn3/cHJ6/21veP9tb3j/bG95/25xe/91d33/ -dHeA/3F0fP9zdn3/bnF6/3Bzff91eIH/d3l//25wd/9ucXv/bnB3/25wd/92eHz/bnB3/2ptd/9qbXf/ -bG51/25wd/9nanH/cHN9/3Bzff9qbXf/bnF7/3V3ff9tb3P/d3l//2xvef9nanT/Zmlz/2xvef9qbXf/ -bG95/2xudf9ucHf/bnB3/3Byef9ucXv/bnB3/25xe/9ucHf/am13/3N2f/9ucHf/bnF7/25wd/9qbXf/ -bG95/2psc/91d33/bG51/3N1fP9wcnn/bnB3/2xudf9sbnX/c3V8/3Bzff9qbHP/dXiB/2psc/9qbHP/ -c3V8/2Jlbv9dYGr/Z2px/2Rncf9maG7/Z2px/2dqcf9qbHP/bG95/2xudf9ucXv/bnB3/3V3ff9sb3n/ -d3l//25xe/9zdn//am13/25xe/9wc33/eXuB/3V4gf9sb3n/c3V8/3V4gf9zdn//d3l//36Ahv95e4H/ -dnh8/3l8hv9+gYr/e32D/3N2f/97fYP/bnB3/3N2f/93eX//cHN9/3N2f/9zdn//c3V8/3N1fP91eIH/ -c3Z//3l8hv97fYP/e32D/3Bzff9ucXv/cHJ5/3Bzff9zdn//c3V8/3V4gf95e4H/cHJ5/2dqdP9zdn// -cHN9/3l7gf9sb3n/dXiB/25xe/9sbnX/dnh8/3Byef91d33/bG51/29xdf9ucHf/b3F1/2psc/9sbnX/ -bG51/21vc/9sbnX/bW9z/3Bzff9wcnn/cHJ5/3Byef9wcnn/dXiB/25xe/9sb3n/eXuB/25xe/9zdn// -bnF7/25wd/9wcnn/bnF7/25wd/9ucXv/cHN9/25wd/9wcnn/cHJ5/3Z4fP9zdXz/cHJ5/2psc/9vcXX/ -bnB3/2xudf9ucHf/am13/2ptd/9qbHP/amxz/3Byef9sbnX/bG51/2xudf9tb3P/bG51/3Z4fP9sbnX/ -bnB3/21vc/9zdXz/bnF7/3Z4fP9tb3P/bG51/25xeP9ydX//dXd9/3V4gf91d33/bnB3/2ptd/9sb3n/ -dXiB/29xdf9sb3n/bnF7/3V3ff9zdXz/cHJ5/3Z4fP9xc3n/cHJ5/25wd/9ucXr/Zmlz/2psc/9wcnn/ -dXd7/25wd/9tb3P/dHd9/2tueP9sb3n/a210/21wef9sbnX/amxz/2hrdf9qbXT/am13/2psc/9ydX// -cnV+/3N2f/9vcnz/eXuA/3J1f/91eIH/enyD/3x/hf95e4H/dnh+/3d5f/96fIH/cnV//3J1fv91eIH/ -eHuF/3p8g/91d33/foGK/3V4gf9wc33/cHN9/3N2f/91eIH/eXuB/3V4fv9wc33/c3Z//25xe/9zdn// -eHqB/3V4gf9ydX7/dHZ8/25wd/9ucXv/cHN9/3N2f/9vcXX/bG95/25wd/9zdXz/dXd9/2xudf9sbnX/ -cHJ5/29xdf9ucXv/am13/3Bzff93eX//bnF7/3V3ff92eHz/b3F1/3d5f/9wcnn/bG51/2xudf9wcnn/ -cHJ5/2ptd/9tb3P/bnF7/2xvef9ucHf/b3F1/25wd/9wcnn/bG95/2xudf9ucHf/am13/25xe/9sbnX/ -am13/2ptd/9nanH/c3V8/2xudf9zdXz/bnF7/2xvef9sbnX/am13/3N1fP94eX3/bG95/3d5f/9ucHf/ -bnB3/3V4gf9sb3n/Z2p0/3V4gf9zdn//cHJ5/3N2f/9zdn//dXiB/3V4gf91eIH/e32D/3d6g/95e4H/ -c3Z//3l8hv91eIH/eXyG/3Bzff91eIH/dXiB/3t9g/93eoP/bnF7/3V4gf95fIb/bnF7/3Byef9ucXv/ -cHJ5/25wd/9zdn//dXiB/3V4gf9wcnn/c3Z//2xvef9qbXf/c3V8/2xvef9nanT/Z2px/2Zpc/9maG7/ -Zmlz/2Zobv9maXP/am13/2xvef9qbHP/bG51/2Zpc/9nanT/bG51/2psc/9ucXv/cHN9/2psc/9nanH/ -bG95/2ptd/9zdn//Z2p0/25xe/9sb3n/am13/3N1fP9ucXv/cHN9/2ptd/9qbXf/bG95/29xdf9sbnX/ -bG51/2xudf9tb3P/bG51/25wd/9wcnn/bW9z/2xvef9qbXf/cHJ5/3N1fP9sb3n/am13/3N1fP9sb3n/ -c3V8/2xudf9ucHf/bnB3/2xvef9ucHf/bnF7/3N2f/9ucHf/cHJ5/3Byef9zdXz/cHJ5/25xe/9sb3n/ -bG95/25wd/9sb3n/bG95/2xvef9sbnX/bG51/2xudf9wc33/bnB3/3Byef9ucHf/bnB3/25xe/94eX3/ -bnB3/3Byef9ucHf/dXd9/3N2f/93eX//b3F1/29xdf9ucHf/dHZ9/3N1fP91d33/eHl9/3Byef9sbnX/ -bnB3/3d5f/9vcXX/bnB3/3Byef92eHz/bnB3/3Byef9wc33/am13/2xvef9qbXf/am13/2dqdP9maXP/ -amxz/3N1fP9nanT/Z2px/2xvef9kZ3H/Zmhu/2RmbP9nanT/Zmhu/2dqcf9kZ3H/Zmhu/2Zobv9kZ3H/ -d3qD/3V4gf93eoP/dXd9/31+gf93eoP/dXiB/3l7gf91eIH/cHN9/3N2f/91eIH/eXyG/3d5f/91d33/ -d3l//3+Bh/97fYP/c3V8/3+Bh/91eIH/c3V8/3N1fP9wc33/d3l//3l8hv97fYP/c3Z//3N2f/9sb3n/ -bnF7/3Bzff9wc33/cHN9/3V3ff9ucXv/bnF7/3Byef9zdXz/bnB3/25wd/9tb3P/cHJ5/25xe/9ucHf/ -bnF7/2xvef9ucXv/cHN9/3N1fP91eIH/d3l//2xvef9zdn//dXiB/25xe/97fYP/dXiB/3V3ff9zdn// -d3l//3l7gf95e4H/dnh8/3d6g/91d33/eXuB/3h5ff96e3//e32D/3d5f/91d33/fn+D/3V3ff97fYP/ -d3l//3d5f/91d33/cHN9/3d6g/9zdn//eXyG/3N2f/9wcnn/c3V8/3N1fP95e4H/e32D/3N1fP97fof/ -cHN9/3Bzff97fof/am13/2Zpc/9ucHf/bG95/29xdf9sbnX/bW9z/2ptd/9sbnX/bnB3/3N1fP91d33/ -eHl9/25wd/93eX//bnB3/25xe/9nanH/bG51/25wd/9zdXz/c3V8/2dqcf9ucHf/c3V8/2psc/9vcXX/ -bnB3/25wd/9qbXf/cHN9/3d5f/9zdXz/bnB3/25wd/9wcnn/cHN9/3h5ff91d33/b3F1/29xdf9ucHf/ -b3F1/3Byef9sbnX/cHJ5/3Byef91d33/bG51/3Byef9qbHP/bnB3/3Byef9vcXX/dXiB/3V4gf9wcnn/ -bnB3/3N2f/9sb3n/eXuB/25wd/9wc33/cHJ5/2xvef93eX//c3Z//3d5f/9ucXv/bG95/3Bzff9ucXv/ -bG95/25xe/9wcnn/c3V8/3V3ff9zdn//d3qD/3N1fP9wcnn/bnF7/3V4gf9+gIb/dXiB/3Bzff93eoP/ -c3Z//3l8hv9zdn//bG95/2xvef9ucXv/cHJ5/3Bzff91eIH/bnF7/25xe/9wcnn/c3Z//3Bzff9wcnn/ -Z2p0/25wd/9vcXX/bnB3/25wd/9ucHf/bG51/25wd/9qbXf/cHN9/29xdf9vcXX/bnF7/3Bzff9zdn// -eXuB/3N1fP91eIH/bnB3/3V4gf91d33/d3l//3Byef9wcnn/bG95/3N2f/9wc33/c3Z//3Z4fP9wcnn/ -bG51/2xudf92eHz/bG51/2ptd/9sb3n/cHN9/2xvef9nanT/Z2p0/2xvef9qbXf/Zmlz/2Zpc/9maXP/ -Zmlz/2xudf91d33/bnB3/3Byef9zdXz/bG95/3Bzff9sb3n/cHN9/3Byef9zdn//c3V8/3Bzff9zdXz/ -cHN9/3Byef9sbnX/bG95/2xudf9wcnn/bnB3/25wd/9zdXz/cHJ5/25xe/9qbXf/bG51/2ptd/9qbHP/ -am13/2psc/9zdn//bnF7/2psc/93eoP/bG95/2dqdP9sbnX/bG95/3N1fP91eIH/dnh8/3Byef9zdXz/ -b3F1/21vc/9ucXv/cHN9/25xe/92eHz/cHJ5/3Byef9wcnn/c3V8/2xudf9wcnn/bW9z/3Bzff9qbXf/ -amxz/2xvef9ucHf/bnB3/2xudf9tb3P/c3V8/3V3ff9sbnX/bG95/25xe/9sbnX/c3V8/2xvef9qbXf/ -Z2p0/2xudf9qbXf/am13/2xudf9sbnX/bG51/25wd/9ucHf/bG95/25xe/9sb3n/bnB3/3N1fP9tb3P/ -cHJ5/25wd/9sbnX/bW9z/2dqcf9ucXv/Z2p0/2ptd/9sbnX/amxz/2xudf9ucHf/eHl9/3d5f/9vcXX/ -dXd9/25wd/9ucHf/eXyG/2ptd/9qbHP/bG95/2xvef9wcnn/bnF7/3Byef9sb3n/bnB3/3Bzff9zdn// -d3qD/3t9g/9zdn//d3qD/3N1fP9zdXz/am13/3Bzff9ucXv/cHN9/3N2f/9nanT/cHN9/25xe/9nanH/ -amxz/2xudf9qbXf/bG51/25xe/93eX//c3V8/29xdf9ucXv/bnB3/3N1fP92eHz/c3V8/2xudf9sb3n/ -bG95/25xe/91eIH/c3Z//3N2f/9wc33/dXd9/2xudf9zdXz/amxz/21vc/9ucHf/b3F1/3V3ff9zdXz/ -b3F1/25wd/91d33/cHJ5/3l7gf9sbnX/dXd9/3Byef9ucHf/c3V8/25xe/9wc33/bG95/2xudf9wc33/ -bG51/2Rncf9qbXf/am13/2dqdP9maXP/am13/3Byef9sbnX/bW9z/25wd/9ucXv/dXd9/2xvef9sb3n/ -c3V8/29xdf92eHz/bnB3/2xudf9qbXf/bnB3/29xdf9vcXX/cHJ5/29xdf91d33/cHJ5/3V3ff9wc33/ -bnF7/3Byef9zdn//cHJ5/3N1fP9wcnn/bnB3/2ptd/9sb3n/am13/3N1fP9vcXX/bW9z/25wd/9ucXv/ -bnF7/3l7gf9vcXX/c3V8/21vc/93eX//c3V8/3V3ff9vcXX/bnB3/2xudf9wcnn/bnF7/3N1fP9ucXv/ -cHJ5/2dqdP9sbnX/eHl9/29xdf9zdXz/dXd9/3Z4fP9zdXz/bnB3/2xvef9sb3n/cHJ5/3Byef9ucHf/ -bnB3/2psc/9sbnX/d3l//25wd/9ucXv/bG95/2xvef9zdXz/bnB3/3Byef9sbnX/bnB3/2xudf9sbnX/ -bG51/2ptd/9ucHf/bnB3/3Byef9ucHf/cHN9/3Byef9zdXz/c3Z//3V4gf91eIH/c3Z//3N2f/91eIH/ -c3V8/3N2f/9zdXz/e36H/3N2f/9ucXv/eXyG/3Bzff9sb3n/bG95/3Bzff9zdn//e36H/3t9g/9zdn// -c3Z//25wd/9ucXv/cHN9/3Z4fP91d33/d3l//3V3ff9ucHf/cHN9/3V4gf9ucXv/c3Z//2xvef9zdn// -bnF7/25wd/9ucXv/bnB3/3N1fP9ucHf/b3F1/2xvef9zdXz/amxz/2xvef9wc33/am13/25xe/9wcnn/ -bG51/2dqcf9ucHf/bG51/25wd/9qbXf/cHJ5/25wd/9wcnn/bG51/25wd/9zdXz/bnB3/25wd/9zdXz/ -amxz/25wd/9sbnX/bG51/21vc/9maG7/bG95/2dqdP9qbHP/bG51/2dqcf9nanH/Zmhu/3Byef9wcnn/ -Z2px/25wd/9gY2z/ZGZs/3Byef9iZW7/XWBq/2BjbP9maG7/ZGdx/2Zobv9maG7/ZGdx/2Zpc/9nanT/ -bnF7/3Bzff9zdXz/bG95/3V3ff9qbXf/bG51/2dqdP9qbHP/am13/2xvef9wcnn/amxz/3Byef9ucXv/ -Z2p0/2ptd/9ucHf/bnB3/21vc/9sb3n/c3V8/3V3ff9sbnX/bG51/2dqdP9nanT/cHJ5/25xe/9qbXf/ -bnB3/2Zpc/9maXP/am13/2xvef9ucXv/bnF7/3Bzff9ucHf/bnF7/2ptd/9sbnX/bnB3/21vc/9ucXv/ -bnF7/2xudf9nanT/dXd9/2ptd/9zdn//amxz/2ptd/9nanT/amxz/2xvef9ucXv/bG95/25wd/9sbnX/ -bnB3/2xudf9qbHP/bnB3/29xdf9ucHf/am13/25wd/9ucXv/bG95/2xvef9wc33/bnF7/3l7gf9wc33/ -cHJ5/3V4gf9wc33/eXuB/3Bzff9sb3n/cHJ5/25wd/9ucHf/bW9z/3Byef9tb3P/cHJ5/25wd/9zdXz/ -bG51/25wd/9nanT/bG51/2psc/9sbnX/bnB3/21vc/9sbnX/bnB3/25wd/9zdXz/bnB3/29xdf9vcXX/ -cHJ5/3Bzff91eIH/bnB3/3Bzff9wcnn/e36H/3d6g/95e4H/cHN9/3N1fP9ydHz/enyC/3p8gv99f4X/ -fn+D/3t9g/92eHz/d3qD/3t+h/9wc33/d3qD/3t9g/97fYP/d3qD/3d6g/94e4X/dXiB/3Z5gv9ydX7/ -dHeA/3Fzev9rbnj/bnB3/3d4ff9vcnz/cnV+/25xe/9vcXn/bnB3/21vdv9tb3b/bG51/25wd/9ucHT/ -bnB4/21wef9sb3n/bnB3/2ttdP9pa3X/aGty/2tueP9pa3X/a210/2tueP9sb3b/c3V7/25wd/9tb3b/ -cHJ5/21vdv9ucHf/bG51/3h6gP9ucHf/am13/3N2f/9qbHP/YmVu/2Jlbv9maXP/Z2p0/3N1fP9tcHr/ -bG95/2ptd/9oanT/am13/2xvef9xc33/cHN8/3R2fP9sb3n/amxz/2dqdP9ucXv/bG95/3V3ff9tb3P/ -cHN9/2ptd/9sb3n/am13/2xudf9wcnn/bnB3/21vc/9wcnn/dXd9/2ptd/9ucXv/cHN9/2xudf9wcnn/ -c3V8/2xudf9kZ3H/am13/25wd/9wcnn/bG51/2xvef9sbnX/am13/2Zpc/9maXP/bG95/2ptd/9qbXf/ -am13/2dqdP9nanT/Zmlz/2Zpc/9nanT/YmVu/2xvef9maXP/Z2px/2xudf9qbHP/Z2p0/2psc/9zdXz/ -cHN9/2dqdP9wcnn/amxz/2psc/91d33/Z2p0/2Rncf9maXP/bG95/2dqdP9sbnX/Z2px/2dqcf9nanT/ -Z2p0/3Bzff9wc33/cHJ5/2dqdP9wcnn/Z2p0/2dqcf9maXP/Zmlz/2ptd/9nanT/am13/2Rncf9sbnX/ -bG95/2Jlbv9nanT/bG51/2xvef9nanH/Z2p0/25xe/9ucXv/amxz/2dqcf9sbnX/bG95/3d5f/9wcnn/ -bnB3/3Byef9sbnX/bG51/3V3ff9ucHf/bnB3/3Byef9ucXv/bG95/3Byef9qbXf/bG51/2xvef9sbnX/ -c3V8/3Byef9vcXX/bG51/3Z4fP9zdXz/eHl9/25wd/9wcnn/bnB3/2xudf9wcnn/cHN9/3Byef9ucHf/ -bnB3/3Byef9sbnX/ZGdx/2xudf9sbnX/Z2p0/2dqdP9sbnX/bnB3/25wd/9vcXX/cHN9/3Byef94eX3/ -cHJ5/2xvef9wc33/cHN9/3d5f/9sb3n/bG95/25xe/9sb3n/bnB3/29xdf9wcnn/bG51/25wd/9wcnn/ -c3Z//25xe/9wc33/bnB3/3N1fP9zdXz/dXiB/2ptd/9ucHf/bG51/2xudf9sbnX/bnF7/2ptd/9sbnX/ -bG51/2xvef9wc33/dXd9/21vc/9zdXz/bnB3/3h5ff9wc33/eXuB/25xe/9qbXf/b3F4/3Bzff9ydHz/ -dHZ9/3V3ff9qbXf/bG51/3N1fP94eX3/bnB3/3N2f/92eHz/dXd9/3Byef9ucXv/cXR9/29xeP9xc3r/ -bnB3/25wev9pa3T/Z2p0/2ttdf9xc3v/bXB6/2xveP9rbnj/am12/2ZpcP9oanH/amxz/2dqcv9kZ3H/ -ZWhy/2Zpc/9maXD/Z2lv/3Bzff9tb3f/b3F6/21vdv9vcnv/bnB3/25wd/9vcXj/cXN6/3J0ev9ucHj/ -bXB6/29yfP9vcXb/bG95/2ttdf90d3//bG52/2xudv91d33/am13/2Rncf9nanT/bG95/21wev90d4D/ -cnR8/3Bzff9rbnj/am13/21wev9vcnz/cXR+/29yfP9zdX3/bXB6/2ptd/9nanT/bG95/2ptd/9ucXv/ -amxz/25xe/9qbXf/bG51/2ptd/9qbXf/bG95/2xvef9qbHP/bnF7/3V3ff9qbHP/bG95/3N1fP9sb3n/ -bG95/3Byef9vcXX/Zmlz/25wd/9zdXz/c3Z//3Byef9zdn//cHN9/25xe/9qbXf/bnB3/3N2f/9wc33/ -bG95/3Byef9sbnX/cHN9/25wd/9wcnn/bG95/2dqdP9wcnn/am13/3Byef9wc33/bG95/2xvef9vcXX/ -d3l//3d5f/9zdXz/c3V8/2ptd/9sb3n/d3l//2xudf9sbnX/Z2p0/3Byef9ucHf/bG51/2xudf9tb3P/ -bG95/2ptd/9zdXz/cHN9/3N1fP9sb3n/bnF7/2Zpc/9nanH/ZGdx/2dqdP9sb3n/am13/3Byef9nanH/ -bG51/3N1fP9kZmz/amxz/25wd/9wcnn/bG51/3Bzff9wc33/d3l//2xvef9qbXf/Z2px/2ptd/9zdXz/ -Z2p0/2dqcf9qbXf/Zmlz/2psc/9qbXf/ZGdx/2Zobv9maXP/am13/2dqcf9nanT/amxz/2ptd/9ucXv/ -bG51/3Byef9ucHf/b3F1/2psc/92eHz/cHJ5/3Z4fP9ucHf/cHJ5/3Byef9ucHf/c3V8/3V4gf9wc33/ -c3V8/2xvef9wc33/bnB3/2dqdP9vcXX/b3F1/25wd/9sbnX/bG95/25wd/9sbnX/am13/25xe/9qbXf/ -dnh8/2xudf9tb3P/cHJ5/3Byef91d33/bG51/2dqdP9sb3n/am13/2dqdP9sbnX/bnF7/25wd/9wcnn/ -am13/3Bzff9ucHf/cHJ5/2xvef9ucHf/bG95/3Bzff9qbXf/cHJ5/2xvef9ucHf/bG95/3N2f/9sb3n/ -bG95/25wd/9wc33/dXiB/3l8hv9ucHf/dXiB/25xe/93eoP/c3Z//3d6g/9ucXv/am13/21weP9xc3v/ -b3F5/3R3fP90dnz/bnF7/21vc/9ucHf/dXd9/2ptd/9sb3n/bnF7/3N1fP9sbnX/bnB4/25xev9ucHj/ -bnF5/25wd/9tcHr/Z2p0/2xvd/9tcHj/cnV9/3Bze/9ydHv/cHN9/3BzfP9vcnz/dHZ8/3N1e/9xc3r/ -bnB5/3J0e/9wcnv/bnF5/21weP9ydHv/bG51/3Fze/9rbXb/bXB6/3Byef9sb3n/bG95/2xvef9rbXb/ -aWx0/21weP9pbHb/b3F6/2lsdv9rbnb/bnF6/2ptdv9qbXf/c3V8/2xvef9kZ3H/Zmlz/2xvef9qbXf/ -cHN7/2xvef9ucHn/am12/2tudv9tb3b/bW92/29yfP9ucHn/dXh//3Fzev91d33/dXd9/3V4gf9wc33/ -c3Z//3Byef91d33/bnB3/29xdf9wc33/bnF7/3N2f/9zdn//bnB3/3d5f/95e4H/cHJ5/3Bzff95e4H/ -dXiB/3d6g/9wc33/cHJ5/25xe/9wc33/dXiB/3l7gf9zdXz/c3Z//25xe/9wc33/bnB3/3Byef93eX// -cHN9/25wd/9ucHf/Z2px/3Byef9ucHf/bW9z/2dqdP9iZW7/am13/2Rncf9sbnX/c3V8/3N1fP9sbnX/ -b3F1/3h5ff93eX//dXiB/3N2f/9sb3n/cHN9/3l7gf9ucHf/cHN9/3V3ff97fYP/eXuB/3l7gf93eX// -dnh8/3t9g/95e4H/foGK/36Biv9/goz/f4GH/35/g/92eHz/dXiB/3Z4fP92eHz/e32D/3l7gf95fIb/ -c3Z//3V4gf93eoP/Zmlz/2ptd/9zdXz/cHJ5/2dqdP9ucXv/bnF7/3V3ff9sb3n/amxz/25wd/9wcnn/ -d3qD/3Bzff9ucXv/c3Z//2ptd/9ucHf/dXd9/25wd/9sb3n/cHJ5/3Bzff9wc33/c3Z//25wd/9sb3n/ -cHN9/25xe/91eIH/c3Z//25xe/9sb3n/e32D/3l8hv95fIb/c3Z//3V4gf9ucXv/bnF7/3V4gf95fIb/ -d3qD/3V4gf9zdn//d3qD/3Bzff9ucXv/bnB3/2xvef9sb3n/bG95/3N2f/91eIH/cHJ5/2xvef91d33/ -cHN9/3d5f/9ucHf/am13/3Byef9wcnn/dnh8/25wd/9sb3n/c3V8/29xdf9qbXf/bG95/3N1fP9wcnn/ -c3Z//3N2f/93eoP/cHN9/3V4gf9wc33/bnF7/25wd/9zdn//bG95/3Byef9ucHf/bG95/2xvef9zdn// -bG95/25wd/9ucHf/c3V8/3Byef91d33/amxz/25xe/9qbHP/c3V8/2xvef9ucHf/Zmlz/2Rncf9sb3f/ -b3J8/2ttdP9ucXr/cnR7/2xvef9tb3P/bnB3/3V3ff9sbnX/cHN9/3N2f/91d33/cHN9/29yfP9zdXz/ -bnF7/3F0fv90dn3/cXN7/2hrdf9vcXn/b3F5/3N2gP9wcnn/cXN8/3Bzff9ydHv/cnV+/3Z5gv92eYH/ -c3Z+/25xe/9zdn7/cnR9/3J1ff9tcHn/cXR9/3Fzev90d4D/bXB6/3N2gP9wc3z/b3J8/3F0ff9vcnz/ -b3F6/21wd/9ydX3/cHJ7/3J0e/9tb3f/a252/3N1fv9tcHj/cHJ5/3Z4f/9zdXz/Z2px/2psc/9wcnr/ -bW92/3J0e/9ucHn/bnF5/2xvd/9ucHT/cHJ5/21vdv9xc3r/b3F4/3N1e/9vcXn/bG95/25xe/91d33/ -c3V8/3N1fP9qbXf/c3V8/2xudf9sbnX/am13/2xudf9wcnn/cHJ5/21vc/92eHz/d3l//2ptd/9ucXv/ -dnh8/3Byef9wcnn/cHJ5/2xudf9maG7/bG51/3N1fP9wc33/bG51/2ptd/9sbnX/amxz/2ptd/9vcXX/ -dnh8/25xe/9ucHf/bG51/2dqdP9ucXv/cHJ5/25wd/9sbnX/Zmlz/3Bzff9nanT/bnF7/3N2f/9wc33/ -am13/25xe/93eoP/e32D/3V4gf95e4H/cHJ5/3Bzff97fYP/bnB3/3Byef9ucHf/cHN9/25xe/9wc33/ -bnB3/25wd/9ucHf/bW9z/3V3ff9wc33/dXiB/2xvef9wc33/bG51/3Byef9sb3n/bnB3/3N2f/9wcnn/ -c3V8/2psc/9zdXz/c3V8/2dqcf9sbnX/cHJ5/2xudf9sbnX/c3V8/3Byef91d33/dXd9/3Byef9wcnn/ -c3Z//3d6g/9ucXv/bnB3/3N2f/9ucHf/cHJ5/3d6g/9zdn//dXiB/3l8hv97fYP/fX6B/3t9g/91d33/ -d3qD/3l8hv93eX//fn+D/3t9g/97fYP/cHJ5/31+gf97fYP/fn+D/3l7gf9+gIb/d3l//3l7gf9zdn// -d3qD/3t9g/91eIH/dXiB/3N2f/9zdXz/c3V8/3N1fP9wc33/bG95/3N1fP93eoP/c3Z//3N1fP9sb3n/ -cHN9/3Bzff93eX//cHJ5/2ptd/9wcnn/bG95/3V3ff9sbnX/bnB3/3V3ff9ucHf/amxz/25wd/9zdXz/ -bG95/25wd/9sbnX/cHJ5/25wd/91d33/bnB3/25wd/9ucHf/dXd9/2xudf9sbnX/bW9z/2ptd/9qbXf/ -cHN9/2xudf9wcnn/bG51/2ptd/9qbXf/dXd9/2psc/9sb3n/Z2px/3N1fP9qbXf/bnB3/2Zpc/9dYGr/ -a210/29yfP9sbnX/bW92/3Fzev9sb3n/amxz/2xvef9ucXv/bG51/2xvef9zdXz/bnF7/2ptd/9rbnf/ -b3F4/21wev90dnv/dHd7/29xef9maW//bW93/3J0e/9zdXz/bnB4/3Byef9wc3z/dHd//3R3f/94eoP/ -dnmC/3V3gP9rbnf/c3V9/29yfP9vcnz/bnB2/21vdv9qbHL/b3J5/2xveP9sb3n/bXB6/21weP9tb3b/ -bG53/21weP9pa3P/cHJ6/29yev9ydHn/bnB3/25wdf91d33/bnF7/3J0fP93eX//c3V8/2Zobv9sbnX/ -c3V8/3BzfP91dnv/cnR5/3N1e/9xc3j/bW91/21veP9sbnT/bW92/29yev91d3//cHJ5/3Bzff91d33/ -d3l//3N1fP91d33/bG95/3l7gf9ucXv/bnB3/25xe/9sb3n/dXiB/3V4gf9ucXv/dXd9/3N2f/9nanT/ -bnF7/3l7gf9wc33/c3Z//3N2f/9sb3n/Z2p0/29xdf91eIH/c3Z//25wd/9ucHf/cHJ5/2xudf9ucHf/ -bG51/3Z4fP9wc33/cHJ5/3N2f/9nanT/cHN9/3Bzff9wcnn/bnF7/2ptd/95e4H/bG95/3N1fP95fIb/ -e32D/3N1fP9zdn//foGK/3l7gf91eIH/dXiB/3Byef9wc33/e36H/3V3ff91d33/dnh8/3t9g/95e4H/ -dXiB/3N2f/9zdXz/c3Z//3N1fP93eX//c3Z//3t+h/93eoP/eXuB/3N1fP9ucXv/bG95/2xvef9zdn// -cHN9/3Bzff9sb3n/cHN9/3N1fP9qbHP/bG51/3Byef9sbnX/amxz/3Bzff9wcnn/dXiB/3V3ff9wc33/ -bW9z/2xvef9ucXv/bnF7/2xudf9zdXz/bG51/2xudf9ucXv/am13/25wd/9wcnn/bG95/3N2f/9zdXz/ -bnB3/2xvef9wcnn/b3F1/3Z4fP9wcnn/cHJ5/2Zobv9ucXv/bnF7/3N1fP9qbXf/bnF7/21vc/9ucXv/ -bG51/2xvef9ucXv/bG51/2psc/9qbXf/ZGdx/2Zpc/9nanH/bG51/2Jlbv9nanT/bG95/2ptd/9qbHP/ -Z2p0/2xvef9ucXv/dXd9/3Byef9ucHf/cHN9/3Bzff97fYP/cHN9/25wd/93eoP/cHN9/2xvef91d33/ -eXyG/3N2f/93eoP/c3Z//3d6g/9wc33/e32D/3d5f/95e4H/dXd9/3t+h/9zdn//dXd9/3Bzff9wc33/ -bnB3/3V4gf9ucHf/bnF7/2xvef9wcnn/c3Z//3d6g/9ucHf/dXd9/25wd/95fIb/c3Z//3t9g/91eIH/ -am13/25xe/91eIH/b3J7/3F0fP92eH7/c3V8/25wd/9wc33/dXiB/3Byef9wc33/c3Z//3V4gf9zdn// -b3J8/3R2ff9xdH7/cnV+/3h6gP9wc3z/aGt0/21wd/90d3//c3Z//3Byef9vcXb/b3F4/25xe/9xdHz/ -cnR8/3N0ev9wcnv/bG95/3J0fP9vcnr/bnB5/21vdf9xdHv/b3F4/3N2fv9tb3j/cnR9/25xev9vcnv/ -bnB3/3R2fP9ydHv/bG52/21vd/9vcnz/b3F4/25xe/9tcHn/d3l//21wd/9ydHz/dnh8/3Byef9kZmz/ -Z2p0/3Byef9ucXv/dHd9/3N1fP9wc3z/dHd+/2xvef9sb3n/cHJ5/3Bzff90dn3/dnmD/3R2f/91eIH/ -eXyG/36Ahv95fIb/foCG/3V4gf95e4H/cHN9/3Byef9ucXv/c3V8/3V3ff9zdn//bnF7/3Z4fP9wc33/ -ZGdx/2ptd/9zdXz/Z2p0/2xvef9sb3n/Zmlz/2Jlbv9qbXf/c3V8/3N1fP9nanT/bG95/2xvef9qbXf/ -bG51/21vc/9zdXz/bnF7/2xudf9qbXf/YmVu/2xvef9sbnX/bG51/2Zpc/9kZ3H/cHN9/2Zpc/9ucHf/ -c3V8/3Byef9nanH/b3F1/3Z4fP9zdn//cHN9/3Bzff9ucHf/bnB3/3l7gf9wcnn/bnF7/25wd/9wc33/ -c3Z//3Bzff9ucXv/bG95/25xe/9ucHf/dXiB/3d6g/9+gYr/c3Z//3N2f/9vcXX/bnB3/25wd/9tb3P/ -cHN9/2ptd/9sb3n/Z2p0/25xe/9qbXf/ZGdx/2Zpc/9ucXv/am13/2Zpc/9wc33/cHJ5/3V3ff91d33/ -cHJ5/2psc/9qbXf/dXd9/3Bzff9tb3P/cHJ5/2xudf9qbHP/bG95/2psc/9qbXf/bG95/2xudf9wc33/ -bnF7/2ptd/9sb3n/bG95/2ptd/91d33/c3V8/25wd/9kZ3H/bG95/3V3ff91d33/bnB3/3Byef9sbnX/ -bG95/2psc/9qbXf/bG95/2xudf9nanT/bnF7/2dqdP9qbXf/bG51/2ptd/9maXP/am13/2xvef9sb3n/ -am13/2ptd/9zdXz/cHJ5/3Z4fP9wcnn/bnB3/2xvef9sb3n/c3V8/3Byef9sbnX/c3V8/2psc/9nanH/ -bG51/25wd/9tb3P/cHN9/2psc/9sbnX/bG51/3V3ff9ucHf/cHJ5/21vc/92eHz/am13/2dqdP9qbHP/ -bG51/2psc/9zdXz/am13/2xvef9qbXf/bG51/2xvef91d33/bnB3/3Z4fP9tb3P/eXuB/3N1fP93eX// -cHN9/2dqdP9ucHf/dXiB/29yfP9xdHz/dXh//25weP9sbnX/cHJ5/3N1fP9qbXf/bnF7/25xe/9sb3n/ -cHN8/3Byef9ydHv/bnB4/25xev9xc3r/am13/2dqdP9sb3j/bG95/3Bye/9rbnj/am12/2tueP9rbnj/ -bG95/29xeP9rbnf/bnF6/21wev9xdH3/cXR+/3F0ff9vcnv/cnR7/2hrdf9sbnb/bG94/25weP9sbnb/ -b3F5/2xvef9wc33/dHZ8/2ptd/9xc33/dnh8/21wev9ydX7/dHZ8/31+gv9ucHf/c3Z//3l7gf93eoP/ -Z2p0/2xvef9zdn//c3Z//3Z4fv92eH7/cHN9/3J1fv9sb3n/b3J8/2xvef9sb3n/dHd7/3Z4fv9tcHr/ -c3V8/3N1fP91d33/c3V8/3Z4fP9ucHf/dnh8/3N1fP9vcXX/bnB3/25xe/93eoP/c3Z//3Bzff95e4H/ -dXiB/2ptd/9zdn//d3qD/25xe/9zdn//dXd9/29xdf9maGz/b3F1/3V3ff91d33/bnB3/3Byef9ucHf/ -bG51/2xudf9sbnX/dXd9/25xe/9qbXf/bG51/1xfaP9qbHP/amxz/2psc/9iZW7/YmVu/2xvef9iZW7/ -Z2p0/25xe/9sb3n/am13/2psc/91d33/bnF7/3Byef9zdXz/bG95/3Byef91d33/bnB3/2xvef9ucHf/ -bnF7/3Byef9zdXz/cHJ5/25wd/9zdXz/bnB3/3Bzff9wc33/e36H/3Bzff91d33/bG95/3Bzff9wcnn/ -cHJ5/3N2f/9wc33/cHN9/25wd/91d33/bnB3/2dqcf9qbHP/c3V8/3Byef9nanH/bnF7/3N1fP93eX// -dXd9/25xe/9tb3P/cHJ5/3V3ff9zdn//bG95/25xe/9vcXX/b3F1/3N1fP9sbnX/bW9z/2xudf9ucHf/ -c3Z//3V4gf9ucHf/bnF7/25xe/9wcnn/d3qD/3V4gf9zdn//bG95/3N2f/93eoP/eXuB/3Bzff91eIH/ -cHN9/25xe/9ucHf/bnF7/3Bzff9ucXv/bnB3/3d5f/9sb3n/bnF7/3Bzff9wc33/bG95/3Byef9zdn// -cHN9/3Bzff9zdXz/d3qD/3V4gf97fYP/cHJ5/3N2f/9wc33/c3Z//3d5f/9zdn//cHJ5/3V4gf9wc33/ -cHN9/3N2f/93eoP/dXiB/3t9g/9zdXz/cHN9/3Bzff91d33/c3Z//3N2f/9sb3n/c3Z//2xudf9ucHf/ -bnB3/25wd/9qbHP/c3Z//3Bzff9zdn//bG95/3Byef9sbnX/d3l//2ptd/92eHz/bW9z/3d5f/9zdXz/ -d3l//3Bzff9maXP/bG95/3Bzff9sbnX/bnF7/3F0fv9xdH3/bnF7/3N2f/93eX//bG95/3Bzff91d33/ -dXd9/3Byef9ucHf/cXN6/21veP9sb3f/bXB4/2tudv9oa3X/am1z/2xud/9zdn3/am13/2tudv9oa3X/ -Zmlz/2hrdf9pbHP/aGt0/2hqcP9naW//Zmhu/2hrdf9oa3L/Z2p0/3N1fP9sbnX/bW9z/25wd/9sb3n/ -bG95/25xe/9sb3n/cHN9/3N2f/9qbXf/bnF7/3N2f/9ucHf/dXiB/3Z4fP99foH/b3F1/3N1fP94eX3/ -c3V8/2dqcf9qbHP/cHJ5/3N1fP91d33/dnh8/3Byef9zdn//bG51/3Byef9ucHf/bW9z/3V3ff91d33/ -bG51/3Byef9ucXv/c3V8/2xvef9zdXz/bG95/3d5f/9ucXv/bG51/3N1fP9ucHf/dnh8/3Byef9ucXv/ -d3l//3Bzff9nanT/c3Z//3d5f/9ucHf/cHJ5/3Z4fP9vcXX/ZWZq/29xdf9zdXz/dnh8/2ptd/9wc33/ -cHN9/25xe/9ucHf/bnB3/3N2f/9wc33/bnB3/3Byef9maG7/bG51/2xudf9qbXf/Zmlz/2Zpc/9sb3n/ -YmVu/2psc/9sb3n/am13/2dqdP9sbnX/bnF7/2xvef9ucXv/bnF7/2xudf9qbXf/bnF7/2xudf9qbXf/ -amxz/2xvef9sb3n/bnF7/2xudf9nanH/c3V8/2xudf9ucHf/bnF7/3d6g/9wcnn/dnh8/25wd/9wcnn/ -b3F1/29xdf9zdXz/bG95/3N1fP9sbnX/c3V8/2xvef9maXP/ZGdx/25xe/9qbXf/Zmlz/3Byef9zdXz/ -eHl9/3Z4fP9wcnn/bnB3/3Bzff91eIH/c3V8/29xdf9ucHf/bW9z/21vc/9wcnn/bG51/2xvef9sbnX/ -bG51/3Bzff9sb3n/ZGdx/2dqcf9maG7/Zmlz/2xvef9wc33/bnF7/2dqdP9ucHf/c3V8/3V3ff9sbnX/ -c3V8/2ptd/9ucXv/am13/2xvef9ucXv/bnB3/2xudf91d33/amxz/2xudf9ucHf/b3F1/2dqcf9ucHf/ -bnB3/25xe/9ucHf/bG95/3N1fP92eHz/dXd9/2xvef9wc33/cHJ5/25xe/9zdn//cHN9/3Byef91eIH/ -bnF7/25xe/9sb3n/dXiB/3V4gf9+gIb/dXd9/3V4gf91eIH/e32D/3N2f/93eoP/bnB3/3V3ff9sb3n/ -bnB3/25wd/9sb3n/bG51/3N2f/9wc33/dnh8/25wd/9zdXz/bG95/3d5f/9qbXf/dXd9/21vc/93eX// -cHN9/3Bzff9sb3n/ZGZs/3Byef9wc33/am13/29yfP9zdoD/c3Z+/3Byef93eoP/eXuB/3Byef93eoP/ -e32D/3l7gf91eID/dnmB/3t9gP92eIH/c3Z+/3R3f/9ydH3/cnV+/3J0ff9wcnn/eHqE/3N1fv9sb3n/ -bG95/25wd/9zdXz/bW9z/2xudf9ucHf/bG95/29xdf9zdXz/cHJ5/25xe/9qbXf/ZGdx/2psc/9qbXf/ -amxz/21vc/9wcnn/b3F1/3Byef9wc33/Z2p0/25xe/91eIH/bnB3/3d6g/95e4H/f4GH/3N1fP93eoP/ -e36H/3d6g/9wc33/bnF7/3t9g/95e4H/eXuB/36Ahv93eoP/eXuB/25xe/91eIH/c3Z//2xvef91d33/ -dXd9/2xudf9ucHf/cHJ5/3N1fP9zdXz/eHl9/3Bzff91eIH/cHN9/25xe/9zdXz/c3Z//3d5f/93eoP/ -dXiB/3d5f/9wc33/amxz/3Bzff93eX//bG95/3V4gf95e4H/cHJ5/2dqdP9ucHf/d3l//3l7gf9ucXv/ -cHN9/25xe/9sbnX/bG51/21vc/9ucXv/cHJ5/2xudf9ucXv/Zmlz/2ptd/9sbnX/am13/2dqdP9nanH/ -bnF7/2Zobv9ucHf/bnF7/25wd/9qbHP/am13/3Bzff9ucXv/bnB3/3Bzff9sbnX/bW9z/3N1fP9wcnn/ -bnB3/29xdf9ucHf/bG51/3Byef9qbXf/Zmlz/25xe/9nanH/bG95/25xe/91eIH/am13/3Bzff9nanT/ -am13/2Zpc/9nanT/cHN9/21vc/9zdXz/bW9z/3V3ff9ucXv/Zmlz/2dqdP91d33/bnF7/2ptd/9wc33/ -bG95/3V3ff93eX//cHN9/2psc/9qbHP/am13/2xvef9qbHP/bnF7/2dqcf9qbHP/bG95/2psc/9ucXv/ -bG51/21vc/91d33/cHJ5/2ptd/9sbnX/bG51/2psc/9ucHf/cHJ5/3Byef9qbHP/cHJ5/3N1fP94eX3/ -bnF7/3Bzff9ucXv/cHJ5/25wd/9wcnn/cHN9/25wd/9ucHf/dnh8/2dqdP9qbXf/bG51/21vc/9kZmz/ -b3F1/25wd/9zdXz/bnB3/25wd/9ucHf/c3V8/3V3ff9ucHf/c3Z//25wd/9ucHf/c3V8/3Bzff9wcnn/ -c3Z//2xvef9nanT/am13/3N2f/9ucXv/d3l//3Bzff9wc33/c3Z//3l7gf9wc33/c3Z//2xvef92eHz/ -bnB3/29xdf9ucHf/bnF7/2xvef91d33/c3Z//3V3ff9sb3n/cHJ5/29xdf91d33/bG51/3Z4fP9tb3P/ -d3l//3V3ff9wc33/cHN9/2Rncf91eIH/c3Z//2xveP9vcnz/c3aA/3V4gP9sb3n/dXiB/3V3ff9sbnX/ -c3V8/3Z4fP91d33/c3V8/29xdf9xc3n/cHJ5/3Fzev9vcXb/bG95/3Bzff9ucHf/bnB3/3V3ff9wcnn/ -bG95/2xudf9nanT/cHN9/2psc/9maXP/amxz/2psc/9qbHP/bG95/25xe/9sb3n/dXiB/3N1fP9wc33/ -d3qD/3N1fP9wc33/dXiB/3l7gf95e4H/d3qD/25xe/95e4H/d3qD/3N1fP91eIH/dXd9/3l8hv9sb3n/ -c3V8/3V3ff9wcnn/Z2p0/2Zpc/92eHz/dXd9/3V3ff91d33/bnB3/3Bzff9nanH/bnB3/2xvef9qbXf/ -bnF7/3Bzff9sbnX/cHJ5/3N1fP9wc33/c3Z//3t9g/91eIH/foGK/3d6g/93eoP/c3Z//3l7gf97fof/ -eXuB/3d6g/97fof/eXuB/3V3ff95fIb/e36H/3V4gf95e4H/eXyG/3Bzff9qbXf/cHJ5/3N2f/93eX// -bG51/3Byef9ucHf/bG51/25wd/9ucHf/c3V8/3V3ff9sbnX/bnF7/2Rncf9qbXf/Z2p0/2dqcf9nanH/ -YmVu/2xvef9iZGr/bG51/25xe/9sb3n/Z2p0/2xudf9wc33/bG95/2xvef9zdXz/bG51/2xudf9wc33/ -bG95/2dqdP9maXP/am13/2ptd/9sb3n/amxz/2Zpc/9zdXz/am13/2ptd/9ucXv/dXd9/2dqdP9qbXf/ -YmVu/2dqdP9iZW7/Z2px/2ptd/9maXP/bG95/2Zobv9qbXf/Zmlz/2BjbP9gY2z/bnF7/2ptd/9maXP/ -am13/2psc/9wc33/bnF7/2dqdP9ucXv/c3Z//3Bzff9wc33/bG95/3N2f/9ucHf/bG95/25xe/9sb3n/ -c3V8/25xe/9tb3P/dXd9/25wd/9ucHf/b3F1/25wd/9qbXf/am13/25wd/9sb3n/Zmlz/2ptd/9ucXv/ -c3V8/2ptd/9ucXv/bG51/2xvef9sb3n/bG95/2xvef9ucHf/am13/3Bzff9nanT/am13/2ptd/9sbnX/ -YmVu/2psc/9nanT/bG95/2psc/9qbHP/am13/25xe/9sb3n/amxz/25xe/9qbXf/bG51/25xe/9sb3n/ -bG51/2xudf9kZ3H/Z2p0/2Rncf9sb3n/cHJ5/3N1fP9sb3n/bW9z/25wd/91d33/c3V8/3V3ff9ucHf/ -eXuB/25wd/9wcnn/am13/2xvef9qbXf/c3Z//3V3ff91d33/b3F1/3Byef9ucXv/d3l//25xe/93eoP/ -cHJ5/3d6g/9ucXv/c3Z//3V4gf9maG7/dHeA/29ye/9rbnf/cHN8/3R2fP9vcnz/bG51/3Bzff91d33/ -bG51/3N1fP9zdXz/c3V8/3N1fP9tb3P/bnB3/3N1fP9ucXv/am13/2psc/9sb3n/am13/2psc/9zdXz/ -Z2p0/2xvef9nanH/amxz/3N1fP9sbnX/bG51/2xudf9tb3P/b3F1/3Byef91d33/cHJ5/3V4gP9zdXz/ -c3Z//3R3gP9ucXv/bnB3/2xvef9ucXv/cHJ5/3J0e/9rbXP/dHZ9/3V3ff9vcXj/cnR7/3R2fP91eIH/ -bW90/25xe/9zdXz/am13/2dqcf9maG7/dXd9/3Byef92eHz/dXiB/25xev90d4D/aGt1/3N2f/9xdH7/ -b3F4/3V4gf92eYH/c3V8/3d6g/95fIb/d3qD/3l8hv9+gYr/eXyG/4GDiv91eIH/dXiB/3V4gf91eIH/ -eXyG/3t9g/9ucXv/d3l//25xe/9ucHf/c3V8/3h5ff9ucXv/d3l//3V3ff9ucHf/Zmlz/29xdf92eHz/ -dnh8/2psc/9tb3P/cHJ5/2ptd/9sb3n/bG95/3N2f/91eIH/c3Z//3V4gf9qbXf/bnF7/25wd/9ucHf/ -bnF7/2Zpc/9zdn//Zmhu/29xdf9wc33/bG95/2dqdP9ucHf/d3qD/25xe/9wc33/cHN9/25wd/9ucHf/ -eHl9/3N1fP9ucHf/bnB3/25wd/9ucHf/bnF7/2xudf9qbHP/dXd9/2xudf9sb3n/cHN9/3V3ff9ucHf/ -cHJ5/2Zpc/9qbXf/Z2p0/21vc/9ucXv/am13/25wd/9vcXX/dnh8/25wd/9kZ3H/Zmlz/3V3ff9tb3P/ -bW9z/3Bzff9ucHf/dXiB/3l7gf9zdn//bG51/3N1fP9ucXv/cHN9/25wd/92eHz/bnB3/25xe/9wcnn/ -bnB3/3Bzff9ucHf/bnB3/3N1fP9wcnn/bG51/2xudf9qbXf/am13/2ptd/9qbXf/bnF7/2dqcf9sb3n/ -bnF7/3Bzff9sb3n/bG95/2xudf9sb3n/Zmlz/2dqdP9nanT/amxz/2dqcf9wc33/Zmlz/2ptd/9qbXf/ -am13/2Jlbv9sbnX/bG95/3V3ff9ucHf/bnB3/3N2f/93eoP/c3Z//3Byef91eIH/c3Z//3N1fP95fIb/ -dXiB/3V3ff91eIH/c3V8/3N2f/9ucXv/eXyG/31+gf9+gIb/dXiB/3V3ff91eIH/e32D/3d6g/93eoP/ -bnF7/3t9g/9sb3n/bG95/2dqdP9wcnn/am13/3V4gf93eX//dXd9/25wd/9wc33/cHN9/3d6g/9wc33/ -eXyG/25wd/94eX3/c3V8/3N1fP9zdXz/Zmhs/3V4f/9zdoD/bnB5/3R3gf92eH7/c3Z//25xe/93eoP/ -dXd9/29xdf9zdn//dXd9/3V3ff9wcnn/bG51/25xe/9zdXz/bnF7/21vc/9tb3P/cHJ5/2xvef9sbnX/ -dXd9/2xvef9wcnn/bG95/2dqdP91d33/bnB0/21vdv9tb3b/am13/2xudP9tcHr/c3V9/2xvef90d4D/ -b3J5/29xef9zdn3/cXN4/29xdv9tb3f/bXB6/2xvef9xdH3/Z2pz/3N1ff91d33/b3J5/3Fzev90dnv/ -dXd+/25wdf9wc33/dXd9/25xe/9qbXf/bnF7/3l7gf9zdn//eXuC/3Z5g/90d4D/d3mA/2xueP91d3// -dHeB/3N1e/95e4L/eXuB/3J0fP91eIH/cHN9/3Bzff9wc33/eXuB/3Bzff95fIb/cHN9/3N1fP9ucXv/ -bG95/3Byef9ucXv/Z2p0/25xe/9qbXf/Z2p0/2ptd/9zdXz/am13/3V3ff9zdXz/bG51/2Rncf9sbnX/ -dXd9/3Z4fP9nanT/bG51/25xe/9qbXf/am13/2ptd/9sb3n/cHN9/2xvef9ucXv/Zmlz/2ptd/9ucHf/ -bnB3/2xudf9kZmz/dnh8/2Zobv9ucHf/c3Z//2xvef9qbHP/bnB3/3d6g/9zdn//cHN9/3N2f/9wc33/ -cHN9/3l7gf9ucXv/bG95/2xvef9ucXv/cHN9/3N2f/9wcnn/bG95/3V3ff9ucHf/bnB3/3V3ff92eHz/ -am13/25xe/9kZ3H/bG51/2psc/9qbHP/bG95/2dqdP9qbXf/amxz/25xe/9qbXf/Zmhu/2Zobv9zdXz/ -bW9z/2psc/9ucXv/ZGdx/3N1fP91d33/c3V8/3Byef91d33/dXd9/3V3ff9ucHf/dXd9/25wd/9ucXv/ -bnF7/25wd/91d33/dXiB/25xe/91eIH/cHN9/2xvef9ucHf/cHN9/2xvef9ucXv/bnF7/3Bzff9ucHf/ -c3Z//3d6g/9zdn//cHN9/3Byef9tb3P/c3V8/25wd/9sb3n/am13/2psc/9qbHP/bG95/2Zpc/9nanT/ -am13/2ptd/9kZ3H/amxz/2ptd/91d33/bG51/21vc/9wcnn/c3V8/3Bzff9nanH/bnF7/2xudf9tb3P/ -cHJ5/2xudf9qbXf/bG51/25wd/9sbnX/Zmlz/25xe/91d33/c3V8/2xudf9sbnX/bnB3/3N1fP9zdXz/ -dXd9/2xudf91d33/Zmlz/2ptd/9maXP/am13/2psc/9wc33/cHN9/3Bzff9qbHP/bG95/2ptd/9sb3n/ -Zmlz/3V3ff9nanH/cHN9/2ptd/9ucXv/am13/2RmbP90dXv/cnR9/2ttdv9ucXn/cnV+/3N1fP9ucHf/ -c3Z//3V4gf9zdXz/dXiB/3N2f/95e4H/dXiB/3Bzff95fIb/eXyG/3t9g/9zdn//c3V8/3l8hv94e4H/ -dXd9/31/hf96fIL/eHuE/3Z5gf9zdXz/en2F/3R3f/9xc3r/cnR7/29xeP9wcnn/cXR8/3d5fv9wc3v/ -c3Z+/3Fzev9vcXj/cnR7/3J0ef9xc3r/b3F2/25wef9vcnr/cnR5/2ptc/9ydHz/dXd//3R2fP9vcnv/ -cHJ5/3R3gf9vcXj/c3Z//3p8gv9wcnn/Z2p0/2dqdP93eX//dnmC/3V3fv9ydX3/bXB6/29yeP9maXP/ -Z2py/2ptdf9nanT/bnF5/3J1ff9sb3b/cHN9/3Bzff9ucXv/cHN9/3l8hv91eIH/d3qD/3N2f/9zdn// -c3V8/3Bzff91eIH/cHN9/3N2f/93eX//c3Z//25wd/9wc33/c3Z//25wd/93eX//d3l//21vc/9iZW7/ -am13/3N1fP93eX//am13/2xudf9wcnn/bW9z/2xudf9sbnX/bG95/3N1fP9ucXv/cHN9/2dqdP9wc33/ -c3V8/3Bzff9ucHf/bG95/3d6g/9sb3n/cHN9/3l7gf9wc33/bnF7/3N2f/9+gIb/eXyG/3N2f/91eIH/ -c3Z//3Bzff91d33/cHJ5/25xe/9sb3n/bG95/25wd/9sb3n/Z2p0/2Rncf9ucXv/Zmlz/2dqdP9sb3n/ -c3V8/2psc/9wc33/am13/2xvef9qbHP/am13/25xe/9nanT/bG51/21vc/9zdXz/bG95/2Rncf9kZ3H/ -cHN9/2ptd/9nanT/bnF7/2dqdP9zdXz/dXd9/3V3ff9ucXv/cHN9/25xe/9wc33/amxz/2ptd/9nanT/ -amxz/2dqdP9qbHP/bnF7/2ptd/9qbHP/Zmlz/2Rncf9iZW7/Zmhu/2Rncf9iZW7/ZGdx/2Zobv9maXP/ -YmVu/2Rncf9maXP/Zmlz/2Zobv9kZ3H/Zmhu/2dqdP9maXP/Zmlz/2dqcf9kZ3H/Z2px/25xe/9qbXf/ -am13/2xvef9sb3n/Zmlz/2ptd/9ucHf/dXd9/3Byef9ucHf/bnF7/3N2f/9zdXz/bnB3/3Bzff9ucXv/ -bnB3/3V3ff9ucHf/bnB3/25wd/9ucHf/am13/2Zobv9zdXz/c3V8/3Byef9sbnX/bW9z/21vc/9wcnn/ -cHJ5/3Bzff9sbnX/dXd9/2dqdP9sbnX/Zmlz/2dqdP9nanT/bnF7/3N1fP91d33/bnB3/3V3ff9ucXv/ -cHJ5/25wd/92eHz/b3F1/3N1fP9zdXz/dnh8/25wd/9kZmz/bnB1/25xe/9tb3f/cHN9/3l7gf91eIH/ -c3Z//3t9g/9wc33/bnB3/3Bzff9zdn//d3l//3V3ff9sb3n/bnF7/3Byef90dn3/bXB3/2ptdv9vcnv/ -cnV+/21wdf9zdXz/bG93/25xev9tcHn/aGpz/3J0ev9wc3v/b3F6/3Bye/9pbHX/bnF5/2xvd/9xdH7/ -a254/2ptd/9zdXv/bG95/29yev9zdXv/bnB2/25wdv9vcXX/b3F4/25wdf9sb3b/cHJ5/3V3fP93eX// -bnB3/3ByeP91eIH/bW94/3V3fv93eX//bW95/2Zpc/9nanT/dXd9/3R2ff9wcnn/cHN7/2xvef9rbnT/ -Zmlz/2RncP9oa3P/Y2Zv/2Vocf9qbXb/a212/25xe/9qbXf/Z2p0/2dqdP9zdXz/bG95/3Byef9ucHf/ -bG95/2ptd/9wc33/c3V8/2ptd/9sb3n/cHN9/2xvef9qbXf/am13/3Bzff9tb3P/dnh8/3l8hv9vcXX/ -Zmhu/2xudf92eHz/d3qD/2xvef9ucXv/c3Z//3N1fP9wcnn/bG95/3Bzff93eX//c3Z//3V4gf9qbXf/ -c3Z//25wd/9wcnn/cHJ5/2ptd/95e4H/am13/3Byef9zdn//c3V8/2ptd/9zdn//foCG/3l8hv93eoP/ -eXuB/3V4gf95fIb/eXyG/3l7gf93eX//cHN9/3d6g/91eIH/d3qD/3N1fP9ucXv/e32D/3N1fP9zdn// -dXiB/3l7gf9wc33/cHN9/25wd/9wc33/cHJ5/25wd/91d33/amxz/2xudf9ucHf/dnh8/25wd/9kZ3H/ -ZGdx/3N1fP9qbXf/bG51/3Bzff9nanT/bnF7/3V3ff9zdXz/bG95/3Bzff9qbHP/bG95/2dqdP9sb3n/ -Z2p0/2xudf9qbHP/am13/3Bzff9ucXv/bG51/25wd/9qbXf/Z2p0/2xudf9qbXf/amxz/2ptd/9nanT/ -Z2p0/2Zpc/9qbXf/bG95/25xe/9ucXv/bG95/2xudf9ucXv/Z2p0/2xudf9qbHP/am13/2xudf9wcnn/ -bG51/2xudf9wcnn/bG95/2Rncf9sbnX/bnB3/3V3ff9wcnn/b3F1/25xe/91eIH/c3Z//25wd/9wc33/ -cHN9/3Byef9zdn//bnF7/2ptd/9ucXv/bG95/25wd/9kZ3H/bnF7/25xe/9sb3n/Z2p0/2ptd/9sbnX/ -bnF7/2xvef9qbXf/Z2p0/3N1fP9kZ3H/Z2px/2BjbP9iZW7/ZGdx/3N1fP9ucXv/am13/2xudf9wc33/ -bG95/2xvef9qbXf/dXd9/21vc/91d33/bnF7/3h5ff9ucHf/ZGZs/3Bydv9ucXv/bG95/25xe/9zdn// -d3qD/25xe/93eX//c3Z//25wd/9zdn//c3Z//3l7gf95e4H/cHJ5/3Bzff9vcnz/dXd+/3Byef9rbnj/ -cHN7/3Fze/9sbnb/cHJ4/2tueP9sb3j/bG95/2psc/9ydXz/cXN7/2lsdv9ydX7/aWtx/3Bye/9oa3T/ -bXB5/2RncP9laHL/bW93/2ptd/9sb3n/bnF6/2ptd/9qbXf/am13/2xvef9qbHT/a210/21vc/90dnz/ -dHZ8/25wd/9vcXb/c3Z//2xvd/9xdH3/cXR+/2tueP9maG7/Zmhu/3V3ff9zdX3/bnF7/3R3fv93eX7/ -c3V8/3J1fv9ucXr/bnF6/2tud/9vcXj/dXiA/3R2fv9wc33/bnF7/25xe/9sbnX/dXd9/3V3ff91eIH/ -dnh8/3N1fP9wcnn/bnF7/3d5f/9ucHf/cHJ5/3N1fP9zdXz/bnB3/3Byef9zdXz/b3F1/3Z4fP93eX// -bnB3/2dqcf9ucXv/dXd9/3l7gf9vcXX/bG95/3V4gf9zdXz/bnF7/2ptd/9wc33/d3l//3Bzff9zdn// -am13/3N2f/9wcnn/c3V8/25wd/9maXP/d3l//2dqcf9ucHf/bnB3/25xe/9nanT/cHJ5/3V3ff9wc33/ -cHN9/3N2f/91d33/cHJ5/3Byef9ucHf/bnB3/2dqcf9zdXz/bnB3/3Bzff9sb3n/Z2p0/3V3ff9ucHf/ -bnB3/3N2f/95e4H/cHN9/3N2f/9sb3n/cHJ5/2xudf9ucHf/dXd9/2xudf9ucHf/bnB3/3Z4fP9ucHf/ -Z2px/2ZobP9zdn//bnF7/25wd/9zdXz/amxz/3Byef91d33/bG95/2xvef9wc33/bG51/25xe/9ucXv/ -c3V8/2xudf9sbnX/Z2p0/2xudf9ucXv/bG95/2dqdP9sb3n/amxz/2Rncf9qbHP/bnF7/2dqcf9sb3n/ -am13/2ptd/9qbXf/bG95/25xe/9ucXv/bnF7/2xvef9qbHP/bnF7/25xe/9qbXf/Z2p0/21vc/9sbnX/ -bnF7/21vc/9ucHf/cHN9/3Byef9maG7/bnB3/3Byef9zdn//c3Z//2xvef9sb3n/cHN9/3N2f/9ucHf/ -cHN9/3N1fP9ucHf/dXiB/3Bzff9qbXf/cHN9/25wd/9ucHf/Zmlz/3V4gf93eoP/cHN9/2xvef9wcnn/ -bG95/25xe/91d33/bnF7/25xe/93eX//amxz/2xudf9qbHP/Zmlz/21vc/92eHz/dXd9/3Byef9tb3P/ -d3l//2xvef9ucXv/amxz/3N1fP9nanT/bG95/2dqdP9sb3n/Zmlz/2Jlbv9sbnX/am13/2psc/9sbnX/ -bnB3/3V3ff9sbnX/dXd9/3Byef9qbHP/bG51/2xvef9zdXz/c3V8/2ptd/9xdH3/bG54/25xe/9ucHf/ -am11/25wd/9tb3b/bG52/2tudP9rbnf/aGt0/2Zpc/9naW//cXN6/3R2fP9qbXf/cnR8/2Zob/9kZ3H/ -ZWhy/25wd/9laHH/aGt1/3Bzff9ucXv/cHN9/3Bzff9ucHf/amxz/29xdv9wcnr/b3F4/21vdv9ucHX/ -dnh8/3V3ff9xc3v/cHN4/3N1fP9ydHz/dHeA/3h6gP9wcnn/Zmlz/2Zobv9wc33/cXN5/3Fzev9ydHr/ -c3V8/29xef9tcHj/b3F3/2xudv9pa3T/bnF5/3N1fP9xc3n/c3V8/29xdf9ucXv/bG95/3d5f/91eIH/ -d3qD/3N2f/9zdn//cHN9/3N2f/95e4H/c3Z//3N2f/9zdn//cHN9/2xvef9ucHf/c3Z//25wd/93eX// -d3l//3N2f/9maXP/cHN9/3N2f/93eX//bnB3/3Byef91d33/b3F1/29xdf9sbnX/dXd9/3N1fP9ucHf/ -cHJ5/2Zobv9ucHf/am13/2ptd/9tb3P/Zmhu/3V3ff9iZW7/am13/2xvef9sbnX/Zmlz/2ptd/9zdXz/ -c3V8/3N1fP91d33/bnF7/2xvef9zdXz/bnB3/25wd/9nanT/dXiB/25xe/9zdn//bnB3/2dqdP9zdn// -am13/25xe/9zdn//dXiB/25wd/9zdn//am13/25xe/9vcXX/bnF7/3N1fP9sbnX/bnB3/3Byef92eHz/ -bnB3/2Zpc/9kZmz/cHJ5/2xvef9nanT/bnF7/2Zpc/9sb3n/c3Z//2xvef93eoP/dXiB/25wd/9zdn// -c3Z//3V3ff9ucHf/bnB3/2ptd/9ucHf/cHN9/3V4gf9wcnn/c3Z//25xe/9ucHf/bG95/3Bzff9wcnn/ -dXiB/25xe/9ucXv/bnB3/3Byef9wc33/cHN9/25xe/9ucXv/bnB3/3N2f/9sb3n/b3F1/2xvef9vcXX/ -bnB3/3N2f/9ucHf/bnB3/3Bzff9wc33/Zmlz/3Byef9zdXz/dXiB/3V4gf9ucHf/bG95/3N2f/91d33/ -bG95/3N2f/91eIH/bnF7/3d5f/9ucXv/am13/3Bzff9ucHf/bnB3/2ptd/93eX//dXiB/3N2f/9sb3n/ -cHJ5/2xudf9ucXv/c3Z//3N1fP9zdXz/dXiB/2xvef9wcnn/am13/2dqdP9ucHf/dXd9/3h5ff9zdXz/ -bnB3/3h5ff9zdXz/c3V8/29xdf92eHz/bnB3/25xe/9qbXf/bnF7/2xvef9kZ3H/amxz/2dqdP9iZW7/ -Z2p0/2xvef9ucXv/amxz/3N1fP9sb3n/ZGdx/2psc/9nanT/bG95/2xvef9oanH/cHN8/2tudv9sb3n/ -bW92/21vd/9vcXj/b3F2/3J0e/9vcXj/dHZ8/2ptd/9oa3L/bW9z/3d5f/94eoD/cHJ5/3p8gv9ucHf/ -cnR7/25wdP90dn3/bG52/3Bzev92eH//bnF7/3N2ff9xc3r/bnB4/2hrcv9tcHf/bXB6/2xudf9sbnX/ -am10/2xvef9ydHr/am10/2ttcv9ucXn/aWx0/3J0fP9vcnn/a213/2Rncf9kZmz/bnF7/3Byef9sb3n/ -dHZ8/3Bze/9sb3f/a212/2xvd/9rbnb/aGt1/25wef9sb3n/bG93/3Bzff9maXP/Z2p0/2psc/9ucXv/ -bG95/3N1fP9maXP/ZGdx/2Rncf9nanT/bG95/2Zpc/9kZ3H/Zmlz/2Zpc/9kZ3H/Zmlz/2Zpc/9iZW7/ -bG51/2xvef9kZ3H/XWBq/2Zpc/9sb3n/cHJ5/2Rncf9nanT/dXd9/2xudf9sbnX/am13/25xe/91d33/ -bG95/3N1fP9nanH/dXd9/25wd/9ucXv/bnB3/2dqcf94eX3/Zmlz/2xvef9ucXv/b3F1/2xudf9sbnX/ -c3V8/3N1fP91d33/dnh8/3N1fP9ucHf/cHJ5/2xudf9ucHf/Z2px/3N1fP9wcnn/bG95/2dqdP9iZW7/ -bnF7/2Zpc/9sb3n/cHN9/3d5f/9qbHP/c3V8/2psc/9wcnn/b3F1/3Bzff9zdXz/bnB3/2xudf9wcnn/ -c3V8/29xdf9qbHP/Zmhu/3Byef9ucHf/bnB3/3V4gf9wcnn/dXiB/3l8hv91eIH/c3Z//3V4gf9sb3n/ -d3qD/3V4gf95e4H/cHJ5/3N1fP9sb3n/bG95/3N2f/9wc33/cHJ5/3V3ff9ucHf/bnB3/25wd/9zdXz/ -bG51/3N1fP9sbnX/bnF7/21vc/9ucHf/c3V8/25xe/9sb3n/am13/2ptd/9sb3n/amxz/2psc/9nanT/ -Z2px/2xudf9ucXv/amxz/2Zpc/9sb3n/bG95/2BjbP9nanT/bW9z/25wd/9ucHf/amxz/2xudf9sb3n/ -c3V8/2ptd/9ucXv/dnh8/3Byef93eX//cHN9/2ptd/9zdXz/bG51/2xudf9qbHP/dXd9/3N1fP9zdXz/ -amxz/25wd/9ucHf/bnB3/3V3ff9wcnn/dXd9/3d5f/9ucHf/b3F1/2ptd/9nanT/bnB3/3V3ff92eHz/ -c3V8/2xudf92eHz/dXd9/3V3ff9wcnn/dnh8/3Byef9wc33/cHJ5/3Byef9zdXz/Zmhu/21vc/9qbXf/ -Zmlz/21vdv9xdH7/dXd9/21vc/9zdXz/bnF7/2Rncf9sbnX/bnF7/25xe/9ucXv/aWxz/3Bze/9ydHr/ -c3aA/3J1fv9ydXv/c3V8/3F0ff92eH//dnmC/3V4gf9sb3n/bXB6/29xef95e4H/eXuE/29yfP93eoT/ -bnF4/3J1f/9zdXz/cnV+/29xdv9zdXz/c3Z+/29yev92eH7/b3F4/2xvef9rbXT/cHJ5/29xeP9xc3f/ -bW9z/29xeP9xc3r/c3V9/3Bye/9zdXv/dXh//3Byef9xc3r/c3V8/29xdf9nanH/Zmhu/25wd/9sb3n/ -bG95/3R2fP9ucXr/bG94/2hrdf9ucXv/aGt1/2dqc/9rbnf/bG94/2lsc/9nanT/XWBq/2Zobv9maG7/ -bG95/2xvef9ucHf/Zmlz/2Zobv9maG7/Zmlz/2ptd/9maXP/ZGdx/2dqdP9nanT/Zmhu/2dqdP9nanT/ -YGNs/2xudf9ucHf/Zmhu/11gav9maXP/am13/3Byef9maXP/Z2p0/25wd/9maG7/Z2px/2Rncf9sb3n/ -bnF7/25xe/9wc33/Zmhu/3Bzff9nanT/bG95/2psc/9maXP/c3V8/2Jlbv9sbnX/bnB3/2xudf9maXP/ -Zmlz/3Bzff9ucXv/bG95/25xe/9ucXv/bnF7/2xvef9sbnX/bnF7/2dqdP9zdXz/c3V8/3Byef9tb3P/ -ZGZs/3Byef9sbnX/cHJ5/3V3ff93eX//b3F1/25wd/9nanH/bnF7/3Byef91eIH/dXiB/3N1fP9zdXz/ -c3Z//3d6g/9wc33/bnF7/2xvef9zdn//c3Z//3N1fP91eIH/bG95/25xe/91eIH/c3Z//2xvef9zdXz/ -amxz/3N1fP9qbXf/cHN9/2psc/9qbHP/amxz/2dqdP9ucXv/Z2p0/2psc/9sb3n/Z2p0/2Zpc/9qbXf/ -bnF7/2ptd/9sb3n/am13/2xvef9vcXX/cHJ5/3Z4fP9zdXz/c3V8/3Byef9wcnn/dnh8/25xe/9sb3n/ -bG95/2xvef9sb3n/dXiB/3N1fP9wcnn/dXiB/3Bzff9qbXf/bnF7/25wd/9sb3n/bnB3/29xdf9sbnX/ -c3V8/3V3ff9sbnX/cHN9/3N1fP9ucHf/c3V8/2xudf9nanH/bG95/29xdf9ucHf/ZGdx/3N1fP9sb3n/ -bG95/2Zpc/9sb3n/Zmlz/25wd/9wc33/bnF7/25xe/9zdXz/Z2p0/25wd/9qbHP/Z2px/2ptd/9zdXz/ -dXd9/2xvef9sbnX/dXd9/2xvef9ucXv/Zmhu/2ptd/9nanH/bG95/2psc/9qbXf/Zmlz/11gav9laHL/ -Z2lv/1xfaP9naW//am12/2xvef9sbnX/Z2p0/2Zpc/9iZW7/amxz/25xe/9ucXv/c3V8/2tud/9ydHv/ -cHJ4/25xev9tb3b/bG51/21wef9ucHf/cXN6/3R2fP9wcnj/bG51/21vdv9rbXb/dHZ+/3J1fP9rbnb/ -dHZ9/2xudf9tb3b/cXN5/2xvd/9ucHf/cHJ7/3Bzev9wcnn/c3V8/2xvef9ucHf/bG94/3J0ff9xc3v/ -dHZ+/29yev9xdHz/bXB5/3BzfP9ucHr/dXeA/3h6gP9ydX7/cHN9/3N2f/9ucHf/am13/2dqdP9wc33/ -cHN9/3N2f/95fIX/cXN9/25xe/9oa3X/c3V8/25wd/9sb3n/cHN9/3V3ff9wcnn/cHN9/2xvef9wc33/ -bG95/3V3ff91d33/d3l//3N1fP9ucHf/b3F1/3V3ff94eX3/dXd9/3Byef9zdXz/cHJ5/2dqdP9sb3n/ -bnF7/2xudf91d33/cHN9/2psc/9iZW7/am13/3Bzff9ucXv/amxz/2ptd/9zdXz/Z2px/2psc/9maXP/ -Z2p0/2dqdP9maXP/Z2p0/2BjbP9ucXv/Z2p0/2xvef9sbnX/amxz/3Z4fP9maG7/bnB3/2xvef9sb3n/ -bG95/2ptd/91d33/c3V8/3N1fP9zdXz/cHJ5/3N1fP9wc33/bnB3/3Bzff9qbXf/dXiB/3d5f/91d33/ -bnB3/2RmbP9ucHf/am13/2ptd/9ucXv/dXd9/2xudf9qbXf/YmVu/2xudf9sbnX/bG95/2xvef9sbnX/ -am13/3Bzff9zdXz/bG51/2Zpc/9kZ3H/bnF7/2xvef9qbHP/bG95/2psc/9sb3n/d3l//25xe/9kZ3H/ -Z2p0/2BjbP9kZ3H/Zmhu/2ptd/9kZ3H/Z2px/2Zobv9nanH/am13/2dqdP9qbXf/c3V8/25xe/9qbXf/ -bG51/25xe/9qbXf/cHJ5/29xdf9zdXz/b3F1/25xe/91d33/c3V8/3N1fP9ucXv/bnF7/3V3ff9wcnn/ -bnB3/25wd/9ucHf/bnB3/3Bzff9vcXX/b3F1/25wd/9sbnX/Zmhu/21vc/9tb3P/bG51/2xudf9qbXf/ -amxz/3Bzff9zdXz/bG51/3Bzff9wc33/bnF7/3Bzff9tb3P/bG51/3N1fP9vcXX/bnB3/2Zobv92eHz/ -cHJ5/3N1fP9nanH/cHJ5/25wd/9zdXz/dXd9/3Byef9wc33/d3l//25xe/91eIH/bG95/3N1fP9zdXz/ -dXiB/3l7gf9ucXv/cHJ5/3V4gf9zdXz/c3Z//25wd/9zdXz/bnF7/3V4gf9wc33/cHN9/3Bzff9qbHP/ -bW93/29ye/9pbHX/b3F6/29yfP9xdH7/bnF7/3Byef9wc33/bG95/2xvef9zdn//bnF7/3Bzff9sb3n/ -dHZ8/25xe/9xc3v/bnF7/21vdv9xc3r/cXN4/29yev9zdX3/cXN6/3F0fP9xdHz/b3J6/3d5gv9xdHv/ -bW93/3R2fv9qbXb/a254/3R2f/9tcHr/cHN8/21wev9tcHn/bnF4/3Bye/9vcnz/bnB3/2tueP9tcHr/ -bG51/25xev9qbXf/cHJ8/2xudf9qbXf/am13/3J0e/9ucXv/am13/2psc/9nanT/Z2px/2Jlbv9gY2z/ -am13/2dqdP9qbXf/c3Z//2ptd/9qbXf/ZGdx/25xe/9sb3n/bG51/3Byef9ucXv/cHJ5/3Byef9tb3P/ -cHJ5/25wd/93eX//d3qD/3d6g/91eIH/c3Z//25xe/93eoP/d3qD/3d6g/9zdn//dXiB/3d6g/9sb3n/ -cHN9/3Bzff9zdn//e32D/3l7gf9wc33/bG95/3N2f/95e4H/foCG/3N2f/93eoP/eXyG/3Bzff9wc33/ -dXd9/3d6g/95e4H/eXuB/3V4gf9wc33/e32D/3N1fP91eIH/c3Z//3Bzff95e4H/bG95/25wd/9ucXv/ -cHJ5/2ptd/9sb3n/cHN9/3V4gf9zdXz/cHJ5/3Byef9wcnn/c3V8/29xdf9ucHf/Z2p0/3Bzff91d33/ -cHN9/21vc/9kZ3H/bG95/2dqdP9sb3n/cHN9/3V3ff9qbXf/am13/2Rncf9nanT/amxz/2ptd/9nanT/ -Z2px/2Zpc/9ucXv/bnF7/2dqcf9ZXGX/XF9o/2Zpc/9maXP/Zmhu/2Rncf9kZ3H/Z2p0/2xvef9maXP/ -Z2p0/2xvef9maXP/bnF7/2xudf9wc33/amxz/2xvef9sbnX/bG51/3V3ff9ucHf/bnB3/3l7gf9ucXv/ -bnB3/25wd/9zdXz/am13/3V4gf9wcnn/cHJ5/3Byef9zdn//d3qD/3N2f/9zdn//cHJ5/3Bzff95e4H/ -cHN9/3Bzff9ucXv/cHN9/25xe/9wc33/bnB3/25wd/9wcnn/bW9z/2dqcf9vcXX/bnB3/25wd/9sbnX/ -am13/2xudf91d33/c3V8/2ptd/9wc33/cHJ5/3Byef9zdn//bG51/2xudf9zdn//am13/25wd/9kZ3H/ -c3Z//3N2f/9zdn//am13/3N2f/9wcnn/dXiB/36Ahv95fIb/eXyG/3t9g/9zdn//d3qD/25xe/9wcnn/ -cHJ5/3N2f/95fIb/cHN9/25xe/93eX//bnF7/3Byef9vcXX/c3V8/25xe/91eIH/cHN9/25xe/9sb3n/ -bG51/29xef9xdHz/aGtz/3Byef9ydHr/dHZ8/25xe/9ucXv/cHN9/25wd/9wcnn/dXiB/3Bzff9zdn// -bnF7/3Z4fv9xc3r/c3Z//21wev9tb3j/dHZ7/3J1ff9tcHr/cnV//29xef90dn//bXB6/3ByeP93eX// -cHF4/25wd/9zdXz/amxz/25wd/92eH7/bnB3/3N1fP9vcXj/aGt1/25wdP9vcXv/bnF7/2xudf9sb3n/ -cHN9/2xudf9zdXz/bG51/3N1fP9sbnX/amxz/2ptd/91d33/bnF7/2xvef9qbXf/bG95/2psc/9kZ3H/ -YGNs/2dqdP9nanH/Z2p0/3V3ff9qbXf/Z2p0/2BjbP9qbXf/Zmlz/2Zobv9nanT/Zmlz/2Zpc/9qbXf/ -Zmhu/2dqdP9maG7/dXd9/3V3ff9zdXz/bG95/3Bzff9qbXf/cHN9/3d5f/9wc33/cHJ5/3N1fP91d33/ -bG51/3Byef9wc33/c3Z//3d6g/93eoP/c3V8/25xe/9ucXv/dXd9/3V3ff9sb3n/bG95/3d5f/9sbnX/ -bW9z/2xudf9sbnX/bG95/2ptd/9qbXf/Zmlz/25xe/9nanT/bG95/2xvef9iZW7/am13/2BjbP9iZW7/ -Z2px/2Rncf9kZ3H/Zmlz/2ptd/9sb3n/bG95/2xudf9sb3n/bnF7/2xvef9sbnX/bnF7/2dqdP9ucXv/ -dXd9/3N2f/9ucHf/Z2p0/25wd/9ucHf/cHJ5/3N1fP92eHz/bG51/2xudf9kZ3H/am13/25wd/9sbnX/ -bG95/2xudf9nanT/cHN9/3Bzff9sbnX/YmVu/2Jlbv9ucXv/am13/2xudf9qbXf/Z2px/2xvef9wcnn/ -bG95/25wd/9sb3n/Z2p0/2xvef9qbXf/c3V8/2xudf9wcnn/bG95/3N1fP97fYP/cHN9/3Byef95fIb/ -dXiB/3Byef9zdXz/d3qD/25xe/97fYP/dXd9/3l7gf91eIH/eXyG/3l8hv91eIH/dXiB/3N2f/9wc33/ -d3qD/3Bzff9ucHf/Z2p0/25wd/9wcnn/cHJ5/25wd/9vcXX/cHN9/29xdf9nanH/bG51/2xudf9qbHP/ -am13/2dqdP9nanT/bnF7/2xvef9qbHP/am13/25xe/9qbXf/c3V8/2ptd/9nanT/bnF7/2dqdP9sbnX/ -ZGZs/3Byef9ucXv/bG95/2Rncf9sb3n/Z2px/25xe/9wc33/am13/2xvef9wc33/am13/2xvef9kZ3H/ -Z2p0/2psc/9qbXf/cHJ5/2dqcf9maXP/cHJ5/2psc/9sb3n/Z2px/2ptd/9nanT/Z2p0/2ptd/9nanH/ -amxz/2dqdP9sb3j/cnV8/2Zpc/9vcXf/a253/25xe/9qbHP/Z2p0/2dqdP9kZ3H/bG51/2xvef9qbXf/ -am13/2xudf9sb3n/aGt1/3V3ff9ucXj/bW92/3Z4fP91d33/bG92/3N1fP9sbnb/c3V8/25wd/9vcXX/ -eHl9/3N1fP9sbnX/bnB3/2psc/9sb3n/dXiB/25xe/9wcnn/bnF7/2ptd/9qbXf/c3V8/25xe/9qbHP/ -bG51/3N1fP9ucHf/cHJ5/25wd/9zdXz/bG51/21vc/9qbXf/d3l//2xvef9qbXf/am13/2psc/9qbXf/ -ZGdx/2BjbP9qbXf/amxz/2xvef91d33/bG95/3N1fP9naW//c3V8/3Byef9sb3n/cHN9/3V4gf9wc33/ -cHN9/25wd/9ucXv/bnF7/3d6g/91eIH/d3l//3V4gf9zdn//cHJ5/3N1fP93eX//c3V8/25wd/91d33/ -c3V8/21vc/9qbXf/bnB3/2xvef9ucXv/am13/2Zobv9maG7/Zmlz/3Bzff9zdXz/bG51/2ptd/91d33/ -bG51/21vc/9tb3P/bnB3/2xvef9sb3n/bG95/2Zpc/9ucXv/am13/3N1fP9ucHf/Z2px/3Z4fP9nanH/ -bnB3/25wd/9vcXX/bG95/2xvef9zdn//c3Z//3N2f/9ucHf/c3V8/3Bzff9ucXv/bG95/3N1fP9nanT/ -c3Z//3l7gf93eX//c3V8/3N1fP91eIH/cHJ5/3d6g/97fYP/f4GH/3d5f/9zdn//bnF7/3N2f/9zdn// -cHN9/3Bzff9ucHf/am13/3V3ff92eHz/bG95/2psc/9maXP/cHN9/25wd/9zdXz/cHJ5/2xvef9zdXz/ -dXd9/3N1fP9ucXv/bnB3/2xudf91d33/bnF7/3V3ff9wcnn/bnB3/2ptd/9sbnX/dXd9/2xudf9sbnX/ -eHl9/3N1fP9qbHP/bnB3/3V3ff9nanH/cHJ5/25wd/9ucHf/bG95/3N1fP9wcnn/cHJ5/3N2f/9ucXv/ -c3V8/3V4gf9ucXv/bnF7/25wd/9wc33/c3Z//3N2f/9wcnn/c3V8/3V4gf9wcnn/Zmlz/25xe/9ucHf/ -b3F1/25wd/9sb3n/cHN9/3V4gf9wc33/bnF7/25xe/9zdn//b3F1/3Z4fP9tb3P/amxz/3Byef9qbHP/ -bnB3/2dqcf9zdn//cHN9/25xe/9nanH/c3V8/2xudf9ucXv/eXuB/3V4gf9zdn//c3Z//2xudf9ucHf/ -bG51/25wd/9vcXX/c3V8/3d5f/9ucHf/cHJ5/3d5f/9ucHf/c3Z//3Byef9wcnn/c3V8/3Byef92eHz/ -bG51/2xudf9nanT/bG95/2xvef9maXP/a210/2Vocv9ucXv/am13/2xudf9sbnX/Z2p0/2ptd/9ucXv/ -bnB3/25xe/9qbXf/bG95/2Zpc/9zdXz/am13/2dqcf9wcnn/bnF7/2psc/9ucXv/am13/25xe/9qbXf/ -am13/3Bzff9sb3n/Z2p0/2ptd/9kZ3H/bG51/3V3ff9ucHf/c3V8/2xvef9sbnX/bG51/3Bzff9ucXv/ -Zmlz/2ptd/92eHz/bnB3/3N1fP9sb3n/dXiB/3Bzff9zdXz/c3V8/3h7hf91eIH/dXiB/3N2f/9zdn// -c3V8/2ptd/9ucXv/dXd9/3d6g/93eoP/fYCJ/3d6g/93eYD/bXB5/3N2f/9ucXv/bXB6/21wev9ydX7/ -c3V8/3V3ff9sbnX/cHJ5/3Byef93eoP/d3l//3h5ff9zdXz/bnF7/2psc/9sb3n/dXd9/2xvef9nanT/ -cHJ5/2ptd/9qbHP/am13/2xvef9sb3n/cHN9/25xe/9sbnX/bG51/2ptd/91d33/dXd9/2ptd/9qbXf/ -c3Z//2dqcf9nanT/amxz/2xudf9sbnX/am13/2xvef9maXP/bG95/2psc/9ucXv/bG51/2Jlbv9wcnn/ -YGNs/2Rncf9maXP/Z2px/2Zpc/9maXP/bG95/2dqdP9qbXf/Zmlz/2ptd/9qbXf/am13/2psc/9sb3n/ -ZGdx/2ptd/9zdXz/cHJ5/2dqcf9iZW7/bG95/2dqcf9sb3n/am13/3N1fP9qbHP/am13/2Zpc/9qbHP/ -am13/2xudf9ucHf/b3F1/2psc/9zdXz/dXd9/2psc/9maG7/Zmhu/3Z4fP9wcnn/cHJ5/25wd/9tb3P/ -c3V8/3V3ff9zdn//bG51/2xvef9qbXf/bnF7/2ptd/91d33/c3V8/29xdf9wcnn/b3F1/3V4gf9ucXv/ -bnB3/3l7gf9wc33/bG95/25xe/93eX//am13/3Bzff9wcnn/cHN9/3Bzff9wc33/bG95/2xvef92eHz/ -bnB3/29xdf9ucHf/bG95/2ptd/9maXP/bnF7/2ptd/9qbXf/Z2px/2Rncf9nanT/Zmhu/2BjbP9nanT/ -Zmlz/2Zpc/9qbHP/ZGdx/2ptd/9qbXf/Z2p0/2xvef9qbXf/cHN9/2xudf92eHz/b3F1/2psc/9wc33/ -cHJ5/3N2f/9maXP/cHN9/3Bzff9wc33/am13/3N2f/9ucHf/c3Z//3V4gf9ucXv/c3Z//3N2f/9ucXv/ -dXiB/3N2f/9zdXz/cHN9/3d6g/9+gYr/c3Z//3d6g/95fIb/c3V8/3l7gf9zdXz/d3qD/3d6g/93eoP/ -eXuB/3N2f/9zdn//c3V8/3l7gf91eIH/bG95/25xe/9qbXf/c3Z//3V3ff9ucHf/bG95/2dqdP9sb3n/ -cHN9/25xe/9zdn//bnB3/3Bzff9ucHf/d3qD/3Bzff9ucHf/dXiB/3V4gf9wcnn/c3Z//3Bzff9zdn// -bnF7/3Byef97fYP/d3qD/2xvef9zdn//Z2p0/25xe/91eIH/bnF7/3V3ff91eIH/cHN9/3V3ff97fYP/ -d3qD/3N1fP9ucXv/dnmC/3Bzff90d4D/bnB3/3R3gP9wc3z/cHJ5/3ByeP90d33/bnF7/3R3gP9vcXj/ -b3F3/3Byef9maXP/Z2px/21vc/9tb3P/bnB3/3V3fP9xc3v/cHN7/2lsdP9sbnb/bW92/2lrdP9tb3f/ -b3F4/3Byev9wc33/bnB3/3Byef9wc33/eXyG/3d6g/93eX//c3Z//3N2f/9ucHf/cHN9/3V4gf9zdn// -bnF7/3d5f/91eIH/bnB3/25xe/9ucXv/bnB3/3V3ff9zdXz/bnB3/29xdf9wcnn/dnh8/3l7gf9wcnn/ -cHJ5/3V4gf9qbXf/bnB3/21vc/9ucHf/am13/25wd/9sbnX/ZGZs/25wd/9tb3P/c3V8/2xudf9qbHP/ -dXd9/2dqdP9sbnX/cHJ5/21vc/9ucHf/bG95/25xe/91eIH/c3Z//25xe/9zdn//cHN9/25xe/9vcXX/ -cHN9/2dqdP9sb3n/dXd9/3Z4fP9tb3P/Z2px/3Byef9sbnX/bnF7/2ptd/91d33/bnB3/25wd/9nanH/ -bW9z/2xudf9sb3n/bG95/2psc/9kZ3H/cHN9/25xe/9maXP/YmVu/2Rncf9sb3n/am13/2xudf9qbHP/ -bG51/3Byef9zdXz/bnF7/3Byef9wcnn/b3F1/3Bzff9ucXv/d3l//3Bzff9ucHf/bnF7/25wd/95e4H/ -bG95/29xdf93eX//bnF7/2xvef9ucXv/c3Z//2dqdP9zdn//bnF7/3Bzff9wc33/cHN9/3V4gf91eIH/ -e32D/3N2f/9wc33/cHN9/25xe/9zdn//cHN9/3d6g/93eoP/dXiB/3N1fP9wc33/c3Z//2xvef9maXP/ -cHN9/25wd/9zdXz/c3Z//2xvef9sb3n/cHJ5/25xe/9wc33/bnB3/3Bzff9ucHf/eHl9/29xdf9qbHP/ -bnF7/29xdf9zdXz/Zmlz/3Bzff9zdXz/cHJ5/2xvef93eoP/cHJ5/3Bzff91eIH/c3Z//3Bzff9wc33/ -am13/25xe/9ucHf/bnB3/25wd/9wc33/dXd9/2xvef9zdXz/eHl9/29xdf92eHz/bG51/2ptd/9qbXf/ -bnF7/25xe/9qbXf/Z2px/2Zobv9sb3n/bnF7/2Jlbv9maXP/Zmlz/25xe/9ucXv/bG51/2xudf9qbHP/ -amxz/25xe/9zdn//c3Z//3Byef9zdn//bnF7/3l8hv9zdn//c3V8/3d6g/97fYP/dXiB/3Z5g/93eoP/ -dnmC/3V3gP9wc33/fYCJ/3p8g/9wc33/d3qD/2ptd/9wc33/dnh+/3Byef90dnz/a254/2tueP9oa3X/ -c3V8/29yfP9pbHX/am13/3N1fv9sb3n/bG95/2xudf9xc3r/bnB0/3Byd/9sbnT/cXN5/25wd/9vcnv/ -cHJ2/25wdf9vcXX/amxz/2dqcf9tb3P/bG51/25wd/9zdXz/cXN6/25wef9sbnb/bnB3/21vdv9tb3X/ -cnR7/3Fzev9ucXn/bG95/2ptd/9sb3n/bG51/3d5f/93eX//c3V8/3Bzff9sb3n/am13/2xvef91d33/ -dXd9/2xudf91d33/dXd9/2xvef9ucXv/cHN9/3N1fP9zdXz/bnB3/25wd/9vcXX/bnB3/3V3ff93eX// -cHN9/25xe/93eoP/Z2p0/2xvef9sbnX/cHJ5/25wd/9sb3n/bnB3/2RmbP9ucHf/bG95/3N2f/9ucXv/ -bG51/3d5f/9ucHf/bnB3/3Bzff9wcnn/bnB3/2xvef9ucXv/dXiB/3d6g/91eIH/d3qD/3N2f/9wc33/ -cHJ5/3Bzff9sb3n/bnF7/3N2f/91d33/cHJ5/2ptd/9zdn//bG51/3Byef9wcnn/bnF7/2ptd/9sb3n/ -Z2p0/21vc/9ucHf/bG95/3Byef9ucHf/amxz/3V3ff92eHz/bnB3/2dqcf9qbHP/dXd9/3Byef9sbnX/ -b3F1/29xdf9ucHf/c3V8/3N1fP9sbnX/am13/2psc/9sb3n/Z2px/25xe/9nanT/amxz/2dqcf9nanH/ -dXd9/2psc/9sbnX/dXd9/2xudf9maXP/amxz/25xe/9nanT/bG95/2xvef9qbXf/bnB3/2xudf9qbXf/ -am13/3N1fP9tb3P/bG51/2xvef9sb3n/am13/2Zpc/9ucXv/am13/2psc/9kZ3H/Z2px/2ptd/9nanT/ -Zmlz/2ptd/9sbnX/bG51/21vc/9sbnX/bnB3/2xvef9wcnn/c3V8/2xvef93eX//cHN9/3d5f/9sb3n/ -am13/25xe/9wcnn/c3Z//2ptd/93eoP/c3Z//3N2f/9ucHf/c3Z//25wd/9wcnn/cHJ5/25wd/9wcnn/ -c3V8/2xudf9wcnn/bG51/2xudf9sbnX/am13/3Bzff9sbnX/cHJ5/3h5ff9tb3P/dXd9/3Byef9zdXz/ -c3V8/3V3ff92eHz/cHJ5/25wd/9ucHf/cHN9/3N2f/9sb3n/cHN9/3Bzff93eoP/eXuB/3V4gf91eIH/ -bG95/3N1fP95e4H/fn+D/3t9g/95e4H/fX6B/3Bzff99gIr/cnV+/3J0e/90d4D/d3mA/3R3gP90dn// -dHeA/3V4gf90dn7/b3F4/3l8hP94eoD/bG95/3BzfP9pa3L/b3F6/3V3ff9ucXr/dHZ9/2ptdv9rbXb/ -a212/3R2fP9wc33/bG52/25weP90dnv/bnB3/21weP9pbHb/am11/2lsc/9sb3f/bG5z/21veP9vcXj/ -bG95/29xef9ucHf/bW90/2Zobv9nanH/bG51/2xudf9sbnX/dHZ7/25weP9rbnj/Zmly/2Zpc/9nanL/ -Y2Zw/2ptd/9qbXX/am13/2xvef9qbXf/bG95/2xudf9zdn//c3V8/3Bzff9wc33/am13/2psc/9nanT/ -dXd9/3N1fP9qbXf/dXd9/3Bzff9sbnX/bG95/25xe/9wcnn/dnh8/3N1fP9ucHf/bW9z/2xudf93eX// -dXiB/25xe/9ucHf/eXuB/2xudf9wcnn/bG51/2xvef9ucHf/bG51/2ptd/9kZ3H/am13/2dqdP9qbXf/ -am13/2Zpc/9zdXz/bG51/2dqdP9sb3n/Z2px/2dqcf9qbHP/bG51/25xe/9ucXv/bG95/2xvef9qbXf/ -bG51/2dqdP9qbXf/Zmlz/2xudf9sb3n/cHJ5/2psc/9kZ3H/Z2p0/2dqdP9sbnX/bG95/2ptd/9qbHP/ -bG51/2BjbP9qbHP/Z2px/2psc/9qbXf/bG51/2Zpc/9qbXf/bnF7/2dqdP9gY2z/YmVu/2ptd/9nanT/ -Z2p0/2dqcf9qbHP/am13/2xvef9ucXv/bnB3/25wd/9ucHf/c3Z//25wd/9zdn//cHN9/2xvef9sb3n/ -bW9z/3l7gf9vcXX/bnB3/3V3ff9ucXv/bG95/25wd/9wc33/bG51/3Byef9ucHf/bnB3/3N1fP9ucHf/ -bnB3/29xdf91d33/b3F1/21vc/9sbnX/bnB3/25wd/9ucHf/c3V8/25wd/9ucHf/bnB3/29xdf91d33/ -b3F1/2Zobv9wcnn/am13/2dqdP9qbHP/Zmlz/2xudf9sb3n/bG95/2ptd/9qbHP/cHJ5/2Zpc/9sb3n/ -Zmhu/11gav9iZW7/Zmhu/2Zpc/9dYGr/am13/2dqdP9maG7/YmVu/2dqdP9kZ3H/Zmhu/2Rncf9kZ3H/ -am13/2dqdP9iZW7/Z2px/2BjbP9iZW7/Zmhu/2Zpc/9nanT/ZGdx/2Zpc/9ucXv/Zmlz/3Byef9nanT/ -Z2p0/2xvef9ucXv/bG95/25xe/9sbnX/bG51/3J0e/9xdHv/aGt1/2tueP9pbHb/bG95/2xvef9sbnX/ -bnB3/2Zobv9maXP/am13/3Bzff9ucXv/am13/25xe/9qbXb/dHeA/25xe/9rbnb/bnF6/3Bzff9ucXr/ -bXB5/3Fzev9xc3v/b3F5/29xef91d3//d3l//3F0fP92eID/cHJ5/3R2fP93eYH/cHJ6/3d5gf95fIX/ -eHqC/3d5fv98foT/fH6F/3N1fP90dnz/eXuA/3d5gP9ydHz/c3V9/3Z4fv90dnz/dnh8/3F0ev9zdXv/ -dXd9/3h6gP90dn3/dHZ+/3Bzff9sb3n/bG95/3N1fP9wc33/c3Z//3d6hP90dn3/c3Z//2lsdv9tcHr/ -bW93/21vd/9zdXz/am13/29xeP9wc33/am13/3Byef9ucHf/eHl9/3Z4fP91d33/dXd9/25wd/9sb3n/ -bnB3/3V3ff91d33/bnB3/3V3ff92eHz/b3F1/3Byef9wcnn/dXd9/3V3ff9ucHf/am13/2xudf9qbXf/ -dXd9/3l7gf9ucHf/bG95/3V4gf9maXP/am13/2dqcf9qbHP/amxz/2dqdP9nanH/XWBq/2Zpc/9maG7/ -am13/2xvef9nanT/c3V8/2dqcf9qbHP/bG95/2dqdP9qbHP/bG51/2xudf9wc33/am13/25xe/9qbXf/ -am13/2ptd/9qbXf/bG95/2ptd/9qbHP/cHN9/3d5f/9sb3n/bnB3/3Byef9tb3P/bW9z/25wd/9zdXz/ -b3F1/2xudf9sbnX/bG95/2xudf9ucHf/bG95/2ptd/9qbXf/bnF7/3d5f/9nanT/amxz/2psc/9ucXv/ -bnF7/3N2f/9wcnn/bnF7/2xvef9zdXz/dnh8/3Byef9ucHf/am13/25xe/9tb3P/dXd9/3Bzff9sbnX/ -amxz/2xudf9zdn//am13/2xudf91d33/bG95/2ptd/9qbHP/bG95/2Rncf9nanT/Z2p0/2psc/9ucXv/ -amxz/2dqdP9sb3n/bnF7/2xudf9qbHP/am13/2ptd/9sbnX/am13/3Byef9sb3n/bnB3/25wd/9wcnn/ -dXd9/25wd/9maXP/dXiB/25wd/9ucHf/cHJ5/25wd/9zdXz/cHN9/3N2f/9wc33/cHN9/3d6g/9wc33/ -eXuB/3N2f/9ucXv/cHJ5/25wd/9ucXv/Z2p0/3V3ff9sbnX/bnB3/25wd/94eX3/bnB3/25wd/9sb3n/ -bG95/3N1fP9qbXf/Z2p0/2ptd/9sbnX/bW9z/25wd/9zdXz/dXd9/25wd/9zdn//d3l//2xvef93eX// -c3Z//3Bzff91eIH/d3l//3l7gf9zdn//c3Z//3V3ff93eoT/enyD/3V3ff94e4P/eHqB/3V4gv90d4D/ -bnF7/3V4gf9qbXf/Z2p0/2xvef9wc33/c3V8/25wd/9ydHz/bnF6/3R3f/9ucHn/bG93/29yfP9ydHv/ -b3F4/25wdf9wcnf/bW92/25wdP9vcnr/cnR8/3V3fv9ucHf/dXh//2xud/9ydHz/dHd//25xef9zdn// -c3V8/3J0ef9wc3z/c3V9/3R3gP9sb3f/bXB6/3V4gv9ucXv/b3J8/2xvef9vcXj/bnB4/3Bzev9vcXj/ -cXN6/25wd/9ydXz/cHJ4/21wef9tb3P/Zmhu/2dqcf9sbnX/bW9z/2ptd/91d33/bnB0/25xe/9maXP/ -bnB3/21vc/9tb3P/c3V8/2ptd/9qbXf/bnF7/2xudf9sb3n/amxz/3V3ff9zdXz/bnF7/3Bzff9nanT/ -amxz/2Zpc/9wcnn/bG95/2xudf9qbXf/bG95/2Zobv9maXP/Zmlz/2Zpc/9qbXf/Z2p0/2dqcf9maG7/ -amxz/25wd/9zdn//am13/2ptd/9zdn//am13/2xvef9qbXf/am13/2ptd/9zdXz/bnB3/2dqcf91d33/ -b3F1/3N2f/93eoP/c3V8/3t9g/9zdXz/c3V8/3Bzff9sb3n/bnB3/25xe/9sb3n/c3Z//25wd/9zdXz/ -bnB3/2xudf9sbnX/amxz/2xudf9qbXf/bG51/2xvef91eIH/am13/2dqcf9nanH/Zmhu/2Rncf9maXP/ -am13/2Zobv9qbHP/Zmlz/2psc/9nanH/amxz/2xudf9qbHP/amxz/2xvef93eX//am13/2dqdP9nanH/ -bnF7/25xe/9wc33/b3F1/29xdf9ucHf/cHJ5/3Z4fP91d33/bG51/21vc/9ucHf/bW9z/3N1fP9wc33/ -am13/3Byef9ucHf/d3l//3Byef9sbnX/dXd9/2xvef9nanT/Z2p0/2xvef9maXP/amxz/2ptd/9sbnX/ -c3V8/2xudf9nanT/bG95/25xe/9qbXf/bG51/2ptd/9qbHP/bG51/2ptd/9sb3n/bG51/2ptd/9sbnX/ -cHJ5/3V3ff9wcnn/Z2px/3N2f/9nanT/bnB3/25wd/9ucHf/cHJ5/3Byef9wc33/cHN9/3Byef93eoP/ -c3Z//3V4gf9sb3n/bG95/25wd/9vcXX/cHJ5/2dqcf9zdXz/bG95/2ptd/9maXP/d3l//2dqcf9qbXf/ -amxz/2Zpc/9qbXf/Zmhu/2Jlbv9maG7/Zmlz/2Rncf9nanH/am13/2xvef9maXP/am13/3V3ff9qbXf/ -dXd9/3N1fP9ucHf/dXd9/3N1fP93eX//cHN9/25wd/9sb3n/bG95/25xef9qbXX/b3J8/3N1e/9xc3z/ -c3Z//25xe/9zdn//am13/3Byef9wc33/d3qD/3l8hv90d4D/dHeB/29xev90d4H/cXN7/21wef9tcHr/ -dHZ8/29yev9wc3r/dXh//3N1fv9wc3v/cnV9/3Z4gf94en//c3V8/3p8gf9rbnf/b3F7/3V3ff9ucXv/ -dHeA/3V4gf9ydX//cnR7/3h7hP98foX/cnV+/3d6hP99gIr/dnmB/3R3gP9zdXz/dnmB/3R3gP9wc33/ -bnF7/3J1fv9tcHr/dnh8/21vdv9wc33/bnB3/2dqdP9qbXf/bnF7/25wd/9wcnn/d3l//3N1fP91eIH/ -cHN9/3V4gf9wc33/c3Z//36Ahv93eoP/c3Z//3V4gf9wcnn/bnF7/3Byef95e4H/dXiB/3l7gf95e4H/ -c3Z//25xe/9ucXv/d3qD/3Bzff9ucHf/bnF7/3V4gf9wcnn/cHJ5/25wd/9ucHf/c3V8/3Byef9vcXX/ -bG51/3N1fP92eHz/dnh8/25wd/9wcnn/dXd9/2xudf9ucHf/bnB3/29xdf9ucXv/c3Z//3N2f/9maXP/ -c3Z//3Byef9wc33/c3Z//2xvef91d33/cHJ5/25wd/9ucXv/am13/25wd/9wc33/cHJ5/3V3ff9ucHf/ -c3V8/25wd/9ucHf/cHJ5/29xdf9tb3P/bnB3/2ptd/9sb3n/d3l//25wd/9tb3P/bG95/25wd/9tb3P/ -cHJ5/3Byef9sbnX/bG51/2xudf9tb3P/am13/2xudf9ucHf/bG51/21vc/9zdXz/dXiB/2xvef9sb3n/ -am13/25xe/9wc33/c3Z//2xvef9vcXX/bG95/25xe/9zdn//dXiB/25xe/9ucHf/bnF7/2xvef9zdn// -dXd9/25wd/9ucHf/bnB3/3d5f/9zdXz/bnB3/3N1fP9sbnX/Zmlz/2psc/9qbXf/ZGdx/2dqcf9qbXf/ -Zmhu/2xvef9nanH/ZGdx/2dqdP9sb3n/amxz/2xudf9sb3n/bG51/2ptd/9sbnX/cHJ5/25xe/9sb3n/ -bnF7/25xe/93eX//cHN9/2ptd/93eoP/cHN9/3Byef9wcnn/dXd9/3V3ff94eX3/e32D/3l7gf93eX// -f4KM/3l8hv97fYP/d3qD/3N1fP91d33/c3Z//3V4gf9wc33/eXuB/3V4gf9wcnn/bnB3/3l8hv9ucHf/ -c3Z//3Bzff9wcnn/cHN9/3Byef9wcnn/cHJ5/25wd/9sbnX/bG95/3Bzff9ucXv/bnB3/25xe/93eX// -bnB3/3V3ff9zdXz/bnB3/3V3ff9zdXz/d3l//3Bzff9ucHf/bG95/3R3gP91dnz/bnB3/3J0fP92eHz/ -b3F4/3J0e/9ucHf/c3V8/2psc/9qbXf/bG51/3Bzff9ucXv/c3V8/3J0e/9rbnT/c3V8/21wef9ucHf/ -bW92/3V3fP9tb3b/a212/21wev9qbXf/b3F4/2ttdf92eH//cnR7/25xeP91d33/Z2py/2xvef91d33/ -bnB3/3N2fv9vcnv/a254/2hrdf90d33/cHN9/2dqcv9nanT/dXiB/2dqdP9maG7/ZGdx/2Zpc/9qbHP/ -ZGdx/2BjbP9maXP/XWBq/25wd/9gY2z/Zmlz/2Zobv9maXP/Z2p0/2xudf9sbnX/bnB3/3N1fP9vcXX/ -cHJ5/2Zobv9sbnX/bG51/25wd/9wcnn/bnB3/25wd/91d33/cHN9/25wd/9ucHf/dXd9/3V3ff91d33/ -c3Z//3N1fP9ucHf/cHJ5/3V3ff9qbXf/bG51/25wd/9wc33/am13/2xvef9sbnX/cHJ5/3Byef9ucHf/ -bG51/25wd/9zdXz/c3V8/3V3ff9ucXv/bnF7/3V3ff9qbXf/bG51/21vc/9sbnX/am13/3N1fP9wcnn/ -Zmlz/3N2f/9ucHf/cHN9/3V3ff9wcnn/cHN9/29xdf9sb3n/bG95/2ptd/9sb3n/bnF7/2xvef91eIH/ -cHN9/3N2f/9ucXv/bnF7/3N2f/9wcnn/bnF7/2xvef9ucHf/cHJ5/3Z4fP9ucHf/bW9z/2ptd/9sb3n/ -bG51/3Byef9ucHf/am13/2xudf9qbXf/am13/25wd/9tb3P/bG51/2dqdP9qbHP/bG95/3V3ff9qbXf/ -Zmlz/2xudf9ucHf/dXd9/3V3ff9ucXv/cHJ5/3Bzff9ucXv/c3Z//3Z4fP9sbnX/b3F1/2xvef9ucHf/ -d3l//3V4gf9ucHf/bnF7/2xvef93eoP/cHJ5/25wd/9wcnn/bnB3/2dqdP9sbnX/am13/2Zpc/9qbXf/ -am13/2dqdP9wc33/Z2p0/2dqdP9zdXz/bnF7/2psc/9sbnX/bG51/2xudf9sbnX/bG51/2ptd/9sbnX/ -Z2p0/2xvef9qbXf/dXd9/2xudf9nanH/cHJ5/2psc/9sbnX/bG51/2xudf9sbnX/bnB3/3Byef9ucHf/ -bnB3/3l7gf91d33/c3Z//3Byef9sbnX/am13/2xudf9sb3n/ZGdx/25xe/9qbXf/am13/2xudf95e4H/ -bnB3/2xudf9sbnX/bW9z/3Byef9sbnX/bnB3/25wd/9qbXf/bG51/25wd/91d33/cHJ5/2xudf9wcnn/ -d3l//2xvef93eoP/dXiB/3N2f/91eIH/c3Z//3l8hv91eIH/cHJ5/3N1fP9ydHz/cXN5/3Byef90d3// -dXd9/3BzfP9wc3z/bG95/3Bzff9nanT/bnB3/3Bzff9zdn//cHN9/3V4gf90d4D/aGt1/3Z5g/9ucXr/ -dHeA/3BzfP94e4T/cHN9/3BzfP9wc33/dXiA/3N1fv9sb3n/eXuB/3N2f/9wcnn/d3qD/2ptd/93eoP/ -eXyG/3V4gf95fIb/eXuB/3Byef9sb3n/e32D/3d5f/9ucHf/bnB3/3t9g/9ucHf/b3F1/2xudf9ucHf/ -bW9z/2dqcf9kZ3H/am13/2psc/91d33/amxz/25wd/9tb3P/bG51/29xdf9wcnn/b3F1/3N1fP91d33/ -bnB3/2xvef9kZ3H/bG95/3Bzff9ucXv/d3qD/3V4gf9wc33/d3qD/3V4gf9wc33/dnh8/35/g/9+gIb/ -fX6B/36Ahv97fYP/dXiB/3d6g/95e4H/c3Z//3Bzff91eIH/e32D/3d6g/93eoP/c3Z//3d6g/93eoP/ -dXiB/3N2f/9wc33/dXd9/3d5f/95e4H/dXiB/3V3ff94eX3/bnB3/25wd/9sbnX/bG51/2xudf9ucHf/ -bnF7/2ptd/9wc33/bnB3/25xe/9zdn//bG95/3Bzff9ucHf/cHJ5/25xe/9sbnX/bG51/3Byef9wcnn/ -dXd9/2xudf9zdXz/bG51/25wd/9zdXz/bnB3/25wd/9ucHf/bG95/3N1fP92eHz/bG51/21vc/9wcnn/ -c3V8/2xudf91d33/bG95/2xudf9sbnX/amxz/2ptd/9sb3n/am13/2psc/9qbHP/bG51/2xudf94eX3/ -am13/2dqdP9ucHf/bnF7/3V3ff92eHz/bnB3/29xdf9zdXz/cHJ5/25wd/9zdXz/bG51/2ptd/9qbXf/ -amxz/25xe/9wcnn/Z2p0/2xudf9ucHf/d3qD/2ptd/9ucXv/bnF7/2xudf9qbXf/am13/2xvef9maXP/ -bG51/2ptd/9sbnX/cHN9/2dqdP9maXP/c3V8/3Bzff9sbnX/bG51/2xudf9sbnX/bW9z/2ptd/9qbXf/ -amxz/2dqdP9sb3n/bG51/3N1fP9qbHP/ZGdx/2dqdP9maXP/amxz/2ptd/9nanH/am13/2dqdP9sb3n/ -bG51/25wd/95e4H/dnh8/3V3ff9zdXz/bnB3/25wd/9ucHf/bG95/2Zpc/9zdn//bnF7/2xvef9wcnn/ -foGK/3N1fP9wc33/c3Z//3Bzff9ucXv/am13/2xvef9vcXX/bG51/21vc/9vcXX/dXd9/3Bzff9nanT/ -bnF7/3V3ff9nanT/dXd9/3Byef9sb3n/dXd9/25wd/91d33/bG95/2dqdP9qbHP/c3Z//3N1ff9rbXT/ -cHJ5/25wd/9rbnj/bnF7/2ptd/9wc33/bG51/21vc/9ucHf/bnF7/2xvef9wc33/am13/2Vocv9zdn// -bG51/25xe/9maXP/bnB3/2dqcf9nanH/amxz/2ptd/9maXP/YmVu/25wd/9kZ3H/YmVu/2Zpc/9cX2j/ -Z2p0/2xvef9maXP/Z2p0/3V3ff9sb3n/bG95/3l7gf91eIH/bnB3/3Bzff9+gIb/bnF7/29xdf9sb3n/ -bnF7/25wd/9sb3n/Z2p0/25xe/9qbXf/d3l//2dqdP9ucXv/bnB3/2ptd/9ucHf/bnF7/2xvef9zdXz/ -dXd9/25wd/9sb3n/aGp0/2xvef9tb3f/bnB3/3J1fv9tcHr/bnF6/3V4gf9wc33/c3V8/25wd/9zdn// -c3Z//3N2f/9ucXv/dXiB/3Byef9wc33/c3Z//3Byef9ucHf/cHN9/3d5f/9wc33/cHN9/25wd/91eIH/ -c3Z//3Bzff9vcXX/bnB3/3d5f/91eIH/dnh8/3V3ff91d33/d3l//3Byef9ucXv/bG95/2xvef9ucHf/ -c3V8/3N1fP9sbnX/c3V8/29xdf9wcnn/dXd9/25wd/9zdXz/am13/2xudf9sb3n/Z2p0/2xvef9sb3n/ -amxz/25xe/9sbnX/cHN9/2psc/9sb3n/bnF7/2psc/9nanH/Zmlz/2Zpc/9nanT/bnB3/2Zobv9qbHP/ -Z2p0/25xe/9nanT/bnF7/2xudf9sbnX/cHJ5/21vc/9ucHf/bG95/2xvef9ucXv/am13/25wd/9ucHf/ -dnh8/2xudf9nanH/b3F1/25xe/91d33/c3Z//2xvef9wcnn/c3Z//3Byef9ucHf/dXiB/3Bzff9ucXv/ -bnF7/3N2f/91eIH/c3Z//2xvef9wc33/c3V8/36Ahv9ucHf/dXd9/3V3ff9tb3P/Z2p0/2xudf9qbXf/ -Z2p0/2xudf9vcXX/b3F1/3V3ff9ucHf/bnB3/3V3ff91eIH/bnB3/2xvef9ucXv/cHN9/25xe/9zdn// -d3qD/3d5f/9zdXz/e32D/3l7gf9+f4P/e32D/3l7gf9+gYr/d3qD/3l7gf9+gIb/d3l//3V3ff91d33/ -eXuB/3V3ff93eX//gYOK/36Biv97fYP/d3qD/3Byef9ucHf/bnF7/25wd/9maG7/cHN9/2xvef9kZ3H/ -Z2p0/3V4gf9nanH/Z2px/2psc/9nanH/Z2px/2Jlbv9kZ3H/Zmlz/2Zpc/9maG7/ZGdx/2Rncf9maXP/ -YGNs/2dqdP9wcnn/ZGdx/3V3ff9sb3n/bG51/3N1fP9sbnX/d3l//3Byef9vcXX/bG51/3V4f/90d37/ -bW90/3N1fP9ucHf/bnB3/3N2f/9sb3n/cHJ5/2dqdP9ucHf/cHN9/3Bzff9ucHf/c3V8/3Byef9maG7/ -d3qD/2xudf9wcnn/am13/3N1fP9sb3n/bW9z/25wd/9ucHf/bnB3/2xudf91d33/cHJ5/2xudf9wc33/ -ZGdx/2xvef9wcnn/bG95/2xudf91d33/c3V8/2xudf94eX3/d3qD/25wd/9ucXv/foCG/3Bzff9wcnn/ -bnF7/25xe/9ucHf/am13/2psc/9rbnj/a254/3d6hP9wcnn/dXiB/3N1fP9ucXv/cHN9/3Bzff9wc33/ -eXuB/3Z5gv91eIH/cHJ8/2lrdP9rbnj/bW93/29xef9xdH3/bnF7/21wev9zdn//c3Z//3Bzff9ucXv/ -d3qD/3N2f/91d33/bnB3/3N1fP9vcXX/bnB3/3Byef9ucHf/b3F1/3Byef92eHz/bnB3/3Byef9ucHf/ -dXd9/3Byef9wc33/bG95/3Bzff91d33/d3l//3N1fP9sb3n/bnF7/3Z4fP9tb3P/am13/2xudf9qbHP/ -am13/25wd/9sb3n/Z2p0/3Bzff9sbnX/bnF7/3Bzff9nanT/bnF7/2ptd/9qbHP/am13/2Zpc/9qbXf/ -bG95/2xudf9wc33/bG51/25xe/9qbXf/bnF7/3Bzff9qbXf/bG51/2dqdP9qbXf/bnF7/3N1fP9sbnX/ -am13/25wd/92eHz/bnB3/3N2f/9sb3n/bG95/3Bzff9ucHf/bG51/29xdf9wcnn/bnF7/3Byef9wc33/ -bG95/3d6g/9sb3n/bnF7/3N1fP9zdn//dXiB/3d6g/9ucXv/cHJ5/3d6g/91eIH/cHN9/3N1fP9qbXf/ -bW9z/25wd/9ucHf/cHN9/3Byef9nanT/bG95/3Byef93eoP/bG95/3N1fP9wcnn/bG51/2psc/9qbXf/ -bG51/2Zpc/9sbnX/amxz/2dqdP9ucXv/bG51/2dqdP9ucXv/bG95/2psc/9nanH/Z2px/2xudf9sbnX/ -am13/2psc/9maG7/YGNs/2Rncf9kZ3H/bG95/2Zpc/9maXP/Z2p0/2Zpc/9kZ3H/bG95/2psc/9nanT/ -Zmlz/2xvef9sb3n/Zmlz/3d5f/91d33/dXd9/3Byef9ucHf/bnB3/3Byef9wcnn/am13/3d6g/9zdXz/ -bG95/3Byef95fIb/bG95/25wd/9sb3n/bG95/2xvef9qbHP/bG51/2xudf9qbHP/bG51/2psc/9sb3n/ -am13/2Zpc/9sb3n/dXd9/2Rncf9sb3n/Zmlz/2dqcf9maXP/Zmlz/3N1fP9qbXf/Z2px/2dqdP9xdH3/ -c3V8/2psc/9ucXv/amxz/2psc/9sb3n/am13/2xvef9qbXf/bG51/3Bzff9ucXv/bG95/3N1fP9wcnn/ -amxz/36Ahv9zdXz/cHJ5/2xudf93eX//bG95/21vc/9ucHf/bG95/2xvef9nanT/dXd9/2xvef9qbXf/ -cHN9/2Rncf9ucXv/bG95/2ptd/9sbnX/b3J7/29ye/9oa3X/c3V8/3J0fP9nanT/bG52/3h6gP9rbXT/ -bG51/21vdv9sbnX/bG51/21vdf9pa3L/bG92/2hrdf9zdn3/bXB6/2xvef9tb3b/Z2px/21vc/9sbnX/ -bG51/3Z4fP90dnz/cHJ7/2xvef9pbHP/bW92/2ttdv9sb3f/dHZ8/25wef9sbnf/cHJ5/25wd/9qbXf/ -am13/3N1fP9ucXv/c3V8/2xudf9ucXv/amxz/2ptd/9qbXf/bG51/2psc/9qbXf/am13/2psc/9qbHP/ -bG51/2xvef9sb3n/am13/2ptd/9sb3n/c3V8/3N2f/9wc33/cHN9/3V3ff94eX3/bnB3/3Bzff9zdXz/ -bnF7/25xe/9zdn//c3Z//2xvef97fYP/c3Z//3t9g/97fYP/c3V8/36Ahv91eIH/c3Z//3d5f/94eX3/ -d3qD/3l8hv91eIH/e32D/3N2f/9zdn//cHJ5/3d6g/91d33/bG95/25wd/9sb3n/bnB3/3V4gf91d33/ -bnB3/2xvef9ucXv/dXiB/3Byef91eIH/bG95/25wd/9wcnn/bW9z/2psc/9vcXX/cHJ5/2xvef9sb3n/ -bnF7/25xe/91eIH/am13/2xvef9zdXz/bnF7/3V3ff91d33/b3F1/29xdf91d33/bnB3/2xudf9zdXz/ -bnB3/25wd/9zdXz/cHN9/3N2f/9zdXz/bG95/25xe/9wc33/eXuB/3N1fP91eIH/dXiB/3Byef9sb3n/ -bnF7/25xe/9ucHf/bnF7/25xe/9wcnn/c3Z//25xe/9sb3n/cHN9/3Bzff9vcXX/bG95/2xvef9vcXX/ -bnB3/3Bzff9wcnn/b3F1/25wd/9zdXz/bnB3/3d5f/9ucHf/bG95/3N2f/9ucHf/cHJ5/3Bzff9zdXz/ -bnB3/25wd/9wc33/cHN9/2dqdP93eX//dnh8/3Z4fP9zdXz/bG51/2xudf9ucHf/bW9z/2dqcf9zdXz/ -bW9z/2xudf9sbnX/eXyG/2xudf9nanT/Z2px/2Zpc/9sbnX/Zmlz/2Zpc/9nanH/ZGdx/2xudf9qbHP/ -bnF7/2xudf9kZ3H/bG95/3V3ff9maXP/c3V8/25wd/9sb3n/c3Z//25xe/93eoP/dXd9/25wd/9ucXv/ -b3J6/3J0fP9ucHf/dXd9/29xdf9ucHf/cHN9/25xe/9zdn//bG95/2xvef9wc33/cHN9/25wd/9zdn// -bnF7/2ptd/94e4X/dHZ8/3J0fP9sbnX/dHZ8/29xeP9sbnX/b3F4/29xeP9tcHr/bnB0/3V3e/9wcnn/ -aGt1/21wev9jZm//cHJ5/25xev9tb3P/bW92/3Z4fP9ydHv/cHJ3/3V3fP9ydHv/aGtz/21vdv96fIP/ -bW93/2xvef9tb3f/aWx2/2xudf9rbXb/aWx1/2hrcv9pa3T/dnh+/25wd/9tb3f/a254/2dqcf9tb3P/ -bG51/25wd/91d33/cnV+/3F0ff9vcXr/aWxy/21vd/9tb3b/b3F5/3BzfP9rbnj/bnB4/25wd/9wcnn/ -bG51/25wd/94eX3/cHJ5/3N2f/9wcnn/c3Z//3Byef9zdXz/d3qD/3N1fP9wcnn/cHN9/3N2f/9sb3n/ -bG95/3Byef9zdXz/c3V8/29xdf9ucHf/bnF7/3l7gf93eX//dXd9/3N1fP91d33/dXd9/25wd/9ucHf/ -b3F1/25wd/9ucHf/bnF7/2ptd/9kZ3H/dXd9/2ptd/9zdXz/dnh8/25wd/94eX3/cHJ5/29xdf9wcnn/ -bG51/3Bzff9ucXv/bG51/3N1fP9tb3P/c3V8/2xudf9zdXz/cHN9/2psc/9qbXf/Z2p0/2ptd/91d33/ -dXd9/25wd/9ucHf/bG51/3Bzff9sbnX/bG95/2ptd/9sbnX/cHN9/21vc/9qbHP/am13/2xvef9tb3P/ -bG51/21vc/9qbHP/c3Z//2dqcf9sbnX/bW9z/21vc/9zdXz/c3V8/2xudf9tb3P/cHN9/25wd/9ucHf/ -Zmlz/2Zobv9maG7/am13/2Zpc/9qbXf/bG95/2psc/9qbXf/am13/3N2f/9qbXf/cHN9/3Bzff9nanH/ -ZGdx/2dqdP9qbXf/am13/2xudf9sbnX/bG51/25xe/9sbnX/am13/3Byef9zdXz/b3F1/2xudf9sbnX/ -bG51/2xvef9ucXv/am13/21vc/9sbnX/dXd9/2xudf93eoP/cHN9/21vc/9wcnn/bG51/2dqdP9sbnX/ -amxz/2dqcf9maXP/Z2p0/2ptd/9maXP/c3Z//3d5f/9wcnn/Z2p0/2Rncf9kZ3H/bG51/2ptd/9maXP/ -bG95/2xudf9maXP/Z2p0/3d6g/9qbHP/bG51/2psc/9maXP/bG51/2Zpc/9kZ3H/bG51/2dqdP9qbHP/ -amxz/2ptd/9nanT/YGNs/2ptd/9zdXz/YmVu/25xe/9sbnX/Z2px/2ptd/9qbXf/dXd9/25xe/9maXP/ -am13/25xe/9xc3r/a254/3ByeP9sbnX/a210/2ptd/9sbnX/am13/2dqdP9qbHP/Zmlz/2dqdP9maXP/ -am13/2hrcv9iZW7/cnR6/25xev9ucXr/a253/3R2ev9ucHn/bG51/21veP9rbnj/bnF7/21weP9vcnz/ -b3J6/2tueP9vcnz/ZWhx/3F0fP9wcnn/am11/2ptd/90d4D/cnV9/21weP9xc3v/cXN6/2psc/9qbXX/ -dXd//2ttdP9tcHr/a254/2lsdP9tb3T/aWx1/2hrdP9tbnX/aGt0/3d4ff9xc3j/bXB6/21vdv9maXP/ -amxz/2dqdP9qbXf/bnF7/3N1fP9vcnv/bXB6/2Vocv9qbXf/am13/3N1ff9xc3v/bW92/25xev9sb3n/ -bG95/2dqdP9sbnX/c3V8/2ptd/9qbXf/Z2px/2Zpc/9nanH/Z2px/2ptd/9nanH/Zmhu/2Zpc/9qbXf/ -YmVu/2Jlbv9maG7/Zmlz/2ptd/9sbnX/YmVu/2Zpc/9sb3n/c3V8/3Bzff9zdXz/cHN9/3d5f/9qbXf/ -bW9z/2xudf9ucHf/bnB3/3V3ff9sbnX/Z2px/3V3ff9wcnn/dXd9/3V3ff9sbnX/c3Z//3Bzff9tb3P/ -b3F1/29xdf92eHz/c3V8/2xudf91d33/am13/2ptd/9nanT/bnF7/2ptd/9iZW7/Z2px/2Jlbv9iZW7/ -Z2p0/2dqdP9nanH/Z2p0/2psc/9zdXz/bG51/3Byef9sbnX/bnB3/3N1fP9sbnX/YmVu/2psc/9qbXf/ -bG51/2dqdP9qbHP/Z2p0/3d5f/9nanH/bG51/21vc/9sbnX/c3V8/3V3ff9wcnn/bW9z/3Bzff9sbnX/ -amxz/25xe/9sb3n/b3F1/3d5f/9sb3n/cHN9/3Bzff9ucHf/bnF7/2xvef97fof/bnF7/3d6g/95e4H/ -c3V8/2xvef91eIH/c3V8/25wd/9ucXv/bnF7/25wd/9wc33/cHJ5/2xvef9zdn//cHJ5/2xudf9sbnX/ -am13/2ptd/9ucXv/cHN9/25wd/9ucHf/Z2p0/3V3ff9ucHf/eXuB/3N1fP9vcXX/cHJ5/25wd/9vcXX/ -c3V8/2xudf9sbnX/bnB3/3Byef9sbnX/bG51/3l7gf93eX//d3l//3Byef9sb3n/am13/25xe/9ucXv/ -am13/3N2f/9vcXX/amxz/2ptd/9+f4P/bnF7/3Byef9ucHf/bnB3/25wd/9sb3n/am13/3Bzff9wcnn/ -cHJ5/3N1fP93eoP/c3Z//25xe/95e4H/e36H/2dqdP91eIH/d3qD/3N2f/93eoP/d3qD/3t+h/97fYP/ -c3Z//3V4gf9sb3j/bnB2/25xef9ydXz/cXR9/3Bzff9vcXj/bG95/25wd/9sb3n/bG95/3Byef9sb3n/ -bG51/3J1fP9ucHf/Z2px/3J1fv9zdXr/cHJ5/2tueP9ydHr/cHJ6/29xd/9wc33/b3J8/3F0ff9xc3z/ -cXR9/3N2fv9ucHn/c3Z+/2hrdP9zdn7/dXh//29xeP9ucHf/dXiA/3F0ff9tcHr/dHZ7/3R2e/9pbHT/ -bnF4/3V4f/9sbnb/bnB3/2xudf9sbnX/bW90/2hrc/9rbXT/a254/2dqdP9wc33/bnB0/21wef9tb3P/ -amxz/21vc/9nanT/bG51/2xvef9sb3n/am13/3Byef9nanT/Zmlz/2dqdP9ucXv/cHN9/2ptd/9ucHf/ -bG51/25wd/9qbXf/am13/3V3ff9wcnn/cHJ5/2xudf9ucHf/bG51/2xudf9ucXv/Z2p0/2psc/9qbXf/ -bnF7/2psc/9qbXf/bG95/3Bzff9sb3n/am13/2dqdP9ucXv/cHN9/3d5f/94eX3/dnh8/3V3ff93eX// -bG51/2xudf9sb3n/bG95/2xudf9wcnn/cHJ5/2xudf92eHz/bnB3/3N1fP91d33/am13/2xvef9sb3n/ -bG51/21vc/9sbnX/dXd9/3N1fP9ucHf/cHN9/2ptd/9qbXf/Z2p0/3V3ff9wcnn/Z2p0/2ptd/9nanT/ -bG51/3Bzff9ucXv/bnB3/2xudf9tb3P/dnh8/29xdf9ucXv/cHN9/25xe/91d33/bG51/2dqcf9tb3P/ -cHJ5/2xudf9tb3P/bW9z/2ptd/93eX//Z2p0/2psc/9sbnX/am13/3V3ff92eHz/cHN9/29xdf91d33/ -bnB3/25wd/9qbXf/ZGdx/2psc/9ucXv/am13/2psc/9nanT/Z2px/2xudf9qbXf/dXiB/2xudf9wc33/ -dXd9/2xudf9nanT/bnF7/21vc/9sbnX/bG51/2ptd/9nanT/am13/2dqcf9nanT/bnF7/2ptd/9qbXf/ -am13/2ptd/9qbXf/bG95/25xe/9sb3n/Zmlz/2BjbP9qbXf/Zmhu/25wd/9qbXf/Z2px/2dqdP9maXP/ -Zmhu/2dqdP9kZ3H/Zmlz/2Zpc/9sb3n/am13/2dqdP93eoP/c3V8/3V3ff9nanT/ZGdx/2Jlbv9nanH/ -Z2px/2dqdP9sb3n/Z2p0/2Jlbv9nanT/eXuB/2ptd/9qbXf/bG51/2xudf9ucHf/b3F1/2dqdP9ucHf/ -bG51/21vc/9sbnX/c3V8/2xudf9qbHP/dnh8/3V3ff9maG7/c3Z//3N2f/9sb3n/c3V8/3N1fP94eX3/ -dXd9/3Byef9zdXz/c3Z8/3J0e/9ucXv/cnV7/29xef9vcXj/bW93/3Byef9ucHf/b3F1/29xdf9sbnX/ -bW9z/25wd/9wcnn/bG95/2hqcf91d37/cnV6/21wef9tb3b/dXd9/3R2fv9ucHf/b3F6/3F0ff9ucXv/ -cXN6/3J0ff9zdn7/cnR7/3Z5gf9rbnf/c3Z//3R3f/9vcXb/b3F2/3N2f/9wc33/bnB3/3R3gP90dnv/ -am10/3J0e/90dn3/bG51/29xef9sbnX/am12/2xvc/9gY2z/Zmlz/2dqdP9kZ3H/bG95/2dqcf9qbXf/ -amxz/2ptd/9qbXf/bG51/2xudf9wcnn/bnB3/21vc/9ucXv/Z2p0/2Zpc/9nanT/bG95/25xe/9wcnn/ -cHJ5/25wd/9ucHf/bW9z/25wd/9zdXz/dXd9/3Bzff9ucHf/bG95/2xvef9sb3n/dXd9/29xdf9ucHf/ -bnF7/3Bzff9vcXX/bG95/3V4gf91eIH/bnF7/3N1fP9wc33/d3qD/3d6g/95fIb/e36H/36Ahv9+f4P/ -e36H/3Bzff9wc33/dXiB/3N2f/9wc33/cHN9/25xe/9qbXf/eHl9/3N2f/91d33/dXd9/2xvef9wcnn/ -cHJ5/29xdf9sb3n/bnB3/3N1fP9zdXz/cHJ5/25xe/9qbXf/am13/2dqdP91d33/c3V8/2xudf9sb3n/ -cHJ5/3Byef9zdn//dXiB/3V4gf9zdn//cHJ5/3t9g/9wc33/dXiB/3d6g/95fIb/e32D/3d6g/9wc33/ -dXd9/3N2f/9zdn//cHN9/3N1fP9zdXz/d3qD/2ptd/9sb3n/cHJ5/25wd/91d33/dnh8/3V3ff9ucHf/ -dXd9/25wd/9tb3P/bG95/2ptd/9wcnn/c3Z//3Bzff9ucXv/dXd9/2xudf9ucHf/bnB3/3t9g/9vcXX/ -c3V8/3Z4fP9ucHf/amxz/25xe/9qbXf/am13/2xudf9qbXf/bG51/2psc/9nanH/bG51/25xe/9qbXf/ -am13/2xudf9qbXf/ZGdx/2xvef9ucXv/bG95/2Zobv9kZ3H/am13/2dqdP9zdXz/am13/2dqdP9zdXz/ -bG51/2xudf9zdXz/b3F1/2xvef9sb3n/c3Z//25xe/9vcXX/e32D/3d5f/93eX//bnB3/2xudf9nanT/ -bnB3/25wd/9sb3n/dXiB/25wd/9ucHf/bnB3/31+gf9ucHf/bG95/2xudf9nanT/Z2p0/21vc/9nanT/ -bG51/2psc/9sbnX/Zmlz/2xvef9nanT/Z2p0/3Bzff9zdXz/ZGdx/3N1fP9ucXv/bG51/3N1fP9ucXv/ -cHN9/3Bzff9sb3n/bG95/3Fze/9ydHv/b3J5/3R2fP9vcXb/bW95/2hrdf9oa3X/am13/2psc/9qbHP/ -bG95/2Zpc/9maXP/Z2p0/2dqc/9gY2z/cXR9/29xef9sb3j/bG52/3J0e/9vcnv/b3F1/25weP9wcnn/ -cHJ2/25weP9wcnn/bnB3/25weP9ydX7/Z2p0/3N2f/9xc33/bnB3/3Bzff9wc33/bnF7/21vc/9zdXz/ -dnh8/2xudf9zdn//d3qD/29xdf9wcnn/bG95/2xvef9sb3n/Zmhu/25wd/9ucHf/amxz/3V3ff9sb3n/ -cHJ5/29xdf9sbnX/bnB3/2xudf9tb3P/c3V8/2xudf9sbnX/bnF7/2Zpc/9qbXf/Z2p0/2ptd/9wc33/ -bG95/3Bzff9sb3n/bG51/25wd/9ucHf/c3V8/3N2f/9zdXz/b3F1/25wd/9ucHf/bG51/3V3ff9vcXX/ -bG51/25wd/9wcnn/bG95/25wd/91eIH/e32D/3Bzff9wc33/c3V8/3N2f/91eIH/eXuB/3d5f/9zdn// -dnh8/3d5f/9nanT/b3F1/25xe/9wc33/cHN9/3Bzff9ucXv/bnB3/3V4gf9wc33/c3Z//3V4gf9ucHf/ -cHN9/25xe/9ucHf/bG95/2xvef91d33/c3Z//25xe/9wc33/bnB3/25wd/9nanT/c3V8/3N2f/9qbXf/ -bG95/25wd/9sb3n/c3Z//3Bzff9zdn//c3Z//3Bzff95fIb/cHJ5/25xe/9zdn//cHN9/3Bzff9wc33/ -Z2p0/25wd/9zdn//bnF7/3Byef9wcnn/cHJ5/3d6g/9ucHf/cHJ5/3Bzff9sb3n/d3l//3Z4fP91d33/ -bnB3/3N2f/9ucHf/bnB3/25wd/9ucHf/cHJ5/3d5f/91eIH/c3Z//3l7gf9ucXv/bnF7/3N2f/9+gYr/ -c3V8/3d6g/97fYP/cHN9/3Byef9ucXv/bG95/2xvef9sb3n/bG95/3Bzff9ucXv/bnB3/3Bzff97fYP/ -dXiB/3Bzff9ucXv/cHN9/25xe/93eoP/e32D/3l7gf9zdn//cHJ5/3N2f/9wcnn/eXuB/3Bzff9ucHf/ -d3qD/3N1fP9zdXz/eXyG/3V3ff91d33/c3V8/3d6g/91eIH/c3V8/3l8hv93eoP/d3l//3Bzff9sb3n/ -Zmlz/25wd/9sbnX/b3F1/3Byef9ucHf/bnB3/2xvef97fYP/bnF7/25xe/9ucHf/bG51/2ptd/9qbHP/ -amxz/2xudf9ucHf/bnB3/2dqdP91eIH/am13/2xvef93eoP/c3Z//2Zpc/91d33/c3Z//3Bzff93eX// -c3Z//3V3ff9wc33/bnF7/25wd/91d3v/dXd7/3Byef91d3z/bnB0/3Byef9qbXf/bG95/25wd/9tb3P/ -bG51/25xe/9maXP/YmVu/2dqdP9kZ3H/YGNs/3J1fv9sb3n/Zmhu/2RmbP9sb3n/Z2py/2dqcf9oa3L/ -Z2lz/2dpb/9laHH/bG95/2ptd/9sbnX/bG95/2Rncf9wc33/bG95/2xudf9qbXf/c3Z//3V4gf9vcXX/ -cHJ5/3V3ff9sbnX/dXd9/3d5f/9tb3P/bnB3/2xudf9ucHf/bnF7/2Zobv9sbnX/bnB3/2dqcf91d33/ -bG51/25wd/9ucHf/b3F1/25wd/9ucHf/am13/3Bzff9sbnX/am13/2xvef9maXP/Z2p0/2Vocv9tb3T/ -c3V8/25wd/9ydHv/c3Z//2xvef9ucHf/bG95/3Bzff9zdXz/c3V8/25wd/9ucHf/b3F1/21vc/9wcnn/ -bW9z/25wd/9ucXv/c3Z//3Bzff9wcnn/dXiB/3d5f/9sb3n/bG95/29xdf9ucHf/cHJ5/3Z4fP9ucXv/ -c3V8/3Bzff9zdXz/ZGdx/2psc/9qbXf/am13/2ptd/9sb3n/bnB3/2dqdP9zdXz/bnF7/25xe/9wc33/ -bG51/2xvef9sb3n/am13/2psc/9sbnX/c3V8/3Bzff9ucHf/cHJ5/2xudf9tb3P/Z2px/2xvef9wc33/ -bG51/25wd/9ucHf/b3F1/3N1fP9zdXz/bnB3/25xe/9tb3P/dXd9/2xudf9sb3n/bnF7/25xe/9ucXv/ -am13/2Zpc/9sbnX/c3V8/25wd/9sbnX/bW9z/2xudf94eX3/bnB3/25wd/9ucXv/bnB3/3Z4fP91d33/ -eHl9/25wd/9zdXz/bG51/29xdf9ucHf/bnB3/3Byef91eIH/c3Z//3Bzff93eoP/bnF7/3Bzff9ucXv/ -eXyG/25wd/9zdXz/dnh8/25wd/9ucHf/bnF7/3Byef9qbXf/bnB3/25wd/9ucXv/bnB3/25wd/9sbnX/ -dnh8/25wd/9tb3P/bnB3/25wd/9qbXf/cHN9/3V3ff92eHz/cHJ5/2xudf9wc33/cHJ5/3l7gf9wc33/ -bnF7/3V3ff9tb3P/bnB3/3Byef9ucHf/b3F1/25wd/9zdXz/cHJ5/29xdf95e4H/dXiB/3l7gf9ucHf/ -bnB3/2RmbP9sbnX/Z2p0/2psc/9sbnX/am13/2Zpc/9qbHP/c3Z//2ptd/9qbXf/am13/2dqdP9maXP/ -am13/2Zpc/9qbXf/bG51/2xvef9nanT/bG95/2Rncf9maXP/bG95/2ptd/9iZW7/bnF7/2xvef9sbnX/ -cHN9/25xe/9zdXz/bnF7/2xvef9qbHP/cHN9/3Byef9sb3n/dnh8/21vc/9ucHf/bG51/25wd/9qbXf/ -bG51/21vc/92eHz/bnB3/2dqcf9zdXz/bnB3/2dqdP97fof/c3Z//25xe/9ucXv/eXuB/2xvef9ucHf/ -bG95/25xe/9ucHf/bnB3/25xe/9qbXf/bG51/2xvef9kZ3H/c3V8/25xe/9qbXf/bG51/3N2f/93eoP/ -cHJ5/3Bzff91d33/bG51/3V3ff95e4H/bG51/3Byef9ucHf/b3F1/3Byef9maG//Z2p0/2dqc/9hZG3/ -cHN9/2ttdP9oa3X/a21z/2psc/9qbXf/bG51/2ptd/9wc33/bG95/25xe/9tcHr/Z2p0/2dqdP9oa3P/ -bXB3/3J1fv9ucXv/bG95/3Byef9qbHP/amxz/2psc/9sb3n/bG95/2xvef9sbnX/bnF7/2psc/9sbnX/ -bnF7/2psc/9maXP/Zmlz/2ptd/9maXP/Z2px/25xe/9ucXv/amxz/2Zobv9kZ3H/Zmlz/2dqdP9wcnn/ -bG95/25xe/9wc33/c3V8/2Rncf9sbnX/am13/2psc/9nanT/bG95/2dqcf9qbHP/c3V8/25xe/9ucXv/ -cHN9/2psc/9qbXf/bnF7/25wd/9tb3P/b3F1/3V3ff9zdXz/c3V8/3N1fP9sbnX/bnB3/2psc/9ucHf/ -eHl9/25wd/9sbnX/bG51/2xvef9zdn//bnF7/2xudf9ucHf/bnB3/3V4gf9ucHf/cHJ5/3N1fP9ucXv/ -bnF7/3N1fP9qbHP/amxz/3V3ff9ucHf/bnB3/25wd/9ucHf/dnh8/21vc/9ucHf/c3V8/25wd/92eHz/ -dXd9/3Z4fP9ucXv/dXiB/25xe/9zdXz/am13/2Zpc/9qbHP/cHN9/2xvef9sbnX/cHN9/2ptd/9sbnX/ -bnB3/3l7gf9wcnn/c3Z//3V4gf9ucXv/bnB3/25xe/9ucHf/am13/25wd/9sb3n/bnF7/25wd/9ucHf/ -bG51/3d5f/9wcnn/b3F1/2xudf9ucHf/Z2px/2xvef9wc33/bnF7/2xvef9qbHP/bG95/2Zobv9sb3n/ -Z2px/2dqcf9qbXf/Z2p0/2Zpc/9sb3n/am13/2ptd/9qbXf/bG51/3V3ff9sb3n/eXyG/3l7gf95e4H/ -cHN9/25wd/9qbXf/c3Z//3N1fP9zdXz/dXiB/3V3ff91eIH/d3l//4OFjP97fYP/eXuB/3V4gf9zdn// -cHN9/3N2f/9wc33/d3qD/3V3ff91eIH/cHN9/3l7gf9zdXz/bnF7/3V4gf9wc33/am13/3d6g/91eIH/ -cHN9/3N2f/93eoP/e32D/3N2f/9wcnn/b3F1/3V3ff91eIH/bnF7/3l7gf9ucHf/c3V8/29xdf9ucHf/ -bW9z/21vc/9vcXX/dXd9/25wd/9sb3n/bnF7/2dqdP9nanT/e32D/3V3ff9wcnn/bnB3/3Z4fP9tb3P/ -b3F1/25wd/9ucHf/bG51/2psc/9zdn//bnF7/25wd/9zdXz/Zmhu/3Z4fP9ucXv/b3F1/21vc/99f4X/ -e32D/3V3ff93eoP/fX6C/3V3ff98foX/f4GI/3N2f/92eYL/cnR7/29yfP9zdn//aGt1/25wd/9qbHP/ -ZWhy/29ye/9sbnX/bW92/21vdv9nanH/am13/2dqcf9maXP/bnB3/2Zpc/9nanT/bG92/2hrdP9lZ3D/ -ZWhw/2xudP9ucXr/a212/2hqc/9qbXf/bG51/2xudf9qbXf/bnF7/3Byef9wcnn/b3F1/3N1fP9wcnn/ -bG51/3N1fP9vcXX/bnB3/3Byef9zdXz/bnB3/3Byef9wc33/dXd9/25xe/9sb3n/bnB3/25xe/9zdXz/ -eHl9/3N1fP9zdXz/cHN9/3Z4fP9nanH/bG51/3Bzff9sbnX/bnB3/3V3ff9tb3P/bG51/3Z4fP9wcnn/ -cHJ5/3N1fP9sbnX/bG51/2xvef9zdXz/bG51/2xudf9wcnn/c3V8/3Bzff9zdXz/bnB3/25wd/9sb3n/ -bG95/3d5f/9ucHf/cHJ5/2xvef9vcXX/c3Z//3Bzff9sb3n/bG95/25xe/91eIH/bnB3/3N2f/9zdn// -c3Z//3N2f/93eX//bnB3/2xvef9wc33/bG95/2xudf9sbnX/bG51/3Z4fP9qbXf/am13/3Byef9sbnX/ -c3V8/3N1fP9ucXv/bG95/3N1fP9qbHP/bW9z/21vc/9sbnX/bnB3/3V3ff9wc33/bG95/3N2f/9ucHf/ -bnF7/25xe/93eoP/cHN9/3N2f/95fIb/d3qD/3V3ff91eIH/dXd9/3N2f/9zdn//c3V8/3V4gf9wcnn/ -cHJ5/3Bzff91eIH/cHN9/25xe/9ucHf/cHJ5/2psc/9zdn//eXuB/3N2f/9ucXv/bG95/3N1fP9vcXX/ -c3V8/2xudf9sbnX/dXd9/25xe/9ucHf/cHN9/3Byef9wcnn/bnF7/3N1fP91eIH/bnF7/3l8hv95e4H/ -eXuB/25xe/9qbXf/Zmlz/3Byef9ucHf/am13/3Bzff9sb3n/cHN9/25wd/93eoP/c3Z//3Byef9ucHf/ -b3F1/2psc/9vcXX/bG51/3Byef9vcXX/am13/2xudf9zdXz/bG51/2xudf9wc33/bG95/2Zobv9wcnn/ -cHJ5/25xe/9sb3n/c3V8/3V3ff9ucXv/bG95/21vc/91d33/eXuB/25wd/91eIH/bG51/3Byef9tb3P/ -bnB3/2xvef9ucXv/cHJ5/3V4gf9wcnn/bG95/25xe/9qbXf/Zmlz/3Z5gv9zdn//cHN9/21vef92eH7/ -bnB3/29xdf9sb3n/bnB3/29xdf9vcXb/dHZ9/3Byef9ucHf/bG94/2Nmb/91d3z/bG95/2lsc/9nanT/ -bnF7/3V4gf9xc3v/c3Z//3N2fv9tcHr/dXd+/3J1f/9rbnj/bnF7/2xveP9tb3j/cXN6/29xeP9tb3P/ -aWty/2ptdP9wc3v/b3F4/3Bze/9ucXr/Z2p0/2xvef9qbHP/Zmlz/25wd/9nanL/aGt0/25xef9sbnb/ -aGt1/21wef9ydX7/dHeB/29xef9sb3j/bnF7/2xudf9qbHP/amxz/25xe/9sb3n/bG95/21vc/9ucXv/ -bnF7/2xvef92eHz/bnB3/3Byef9zdXz/cHJ5/21vc/9qbHP/bnF7/3N1fP9sbnX/bG51/2dqdP9sb3n/ -bG95/3Bzff9sb3n/c3V8/25xe/9wc33/Z2p0/2ptd/9ucXv/amxz/2dqdP9sb3n/Zmlz/2dqcf9sb3n/ -am13/2xvef9zdXz/amxz/2xudf9qbXf/bnF7/2ptd/9tb3P/bnF7/3V3ff9zdn//cHN9/25wd/9ucHf/ -bnB3/25wd/91eIH/bnB3/3Byef9ucHf/cHJ5/3N2f/91eIH/c3V8/3Bzff9wc33/e32D/25wd/9wc33/ -dXiB/3l7gf91eIH/d3l//2xvef9qbXf/bnF7/25wd/9qbHP/bnB3/2xudf94eX3/bnB3/2xudf9sb3n/ -am13/3Byef9zdXz/c3V8/2ptd/9zdXz/amxz/2xvef9ucHf/am13/21vc/92eHz/c3V8/25wd/91d33/ -b3F1/29xdf9vcXX/dnh8/25wd/9ucHf/bnB3/25xe/9qbXf/bG95/2psc/9sbnX/bG51/2xudf9qbXf/ -Z2p0/2dqdP9nanH/dXd9/2dqdP9nanH/ZGdx/2Zpc/9dYGr/Z2p0/3N1fP9sb3n/bG51/2ptd/9qbXf/ -amxz/2xvef9sbnX/am13/25xe/9wcnn/amxz/25xe/9qbHP/Z2p0/2xudf9sbnX/c3V8/2ptd/93eoP/ -cHN9/3Bzff9sb3n/am13/2psc/9ucHf/bW9z/2xudf9ucHf/bG51/3Byef9tb3P/d3l//3Bzff9sb3n/ -cHJ5/2xudf9maXP/bG51/2dqdP9wc33/am13/2xudf9ucHf/c3Z//25wd/9ucHf/dXiB/3V4gf9kZ3H/ -dXd9/25wd/91d33/bG51/3Bzff95fIb/c3Z//2xvef9sb3n/cnV+/3Z5gv9sbnX/enyC/29ydv9vcnz/ -bnB3/3Bzff9wc33/bG95/2xvef9wcnn/b3F1/2dqcf9ucHf/bG92/2hrdf91eIH/dXd+/3R2fv9ydHv/ -dXd8/29yd/9wcnf/b3F3/3J0e/9ucHj/b3J5/3V3ff9wcnj/cHJ3/3Fzev9sbnX/dHZ8/29xd/9tcHn/ -bG51/25xef9ydX7/bnB5/2xvef9vcXj/bG93/29yev9wcnj/aWx1/3Bze/9tcHr/a254/3Byef9tcHr/ -bW92/2dqdP9rbnb/dHZ9/3R2ff9zdX3/c3V8/29yef92eYL/dXd9/3Z4fP9+gYr/cXR+/3N2f/92eID/ -bW93/2hrdP9sb3n/b3J8/3V3ff9oa3X/YmVu/35/g/93eX//c3V8/3N1fP93eoP/c3Z//3N2f/9ucXv/ -cHN9/3V4gf9zdn//eXyG/3N2f/9wc33/cHN9/3Bzff9ucHf/am13/3Bzff91d33/bnF7/3Byef9sbnX/ -cHJ5/25wd/9zdXz/cHJ5/3V3ff9zdXz/cHN9/2ptd/9ucHf/d3qD/3Bzff9wc33/cHN9/2xvef9ucHf/ -dXiB/3Bzff91eIH/e32D/3V3ff93eoP/eXuB/3t9g/93eX//d3l//3l8hv97fof/e32D/36Ahv97fYP/ -eXuB/3V3ff91d33/gYOK/3Z4fP93eX//eHl9/3h5ff97fYP/d3qD/3N1fP95fIb/d3qD/3t+h/9wcnn/ -c3Z//3d6g/91eIH/dXiB/3l7gf9zdXz/c3V8/3V4gf9zdXz/Z2p0/2xvef9nanT/d3l//25wd/9qbXf/ -bnB3/2ptd/9ucXv/dXd9/3Z4fP9wcnn/c3V8/2xudf9vcXX/YmVu/2Jlbv9maG7/bnB3/2dqdP9iZW7/ -ZGdx/2BjbP9kZ3H/ZGdx/25wd/9kZ3H/Zmhu/2Zpc/9maXP/Zmlz/2Zobv9dYGr/YGNs/2Zobv9maG7/ -Z2p0/2Zpc/9nanT/Zmlz/3V4gf9sb3n/am13/2psc/9qbXf/Zmhu/25wd/91d33/c3V8/3N1fP9sb3n/ -bnF7/3Byef91eIH/c3Z//3N2f/91eIH/d3qD/3N1fP93eoP/cHN9/3Byef9wc33/c3V8/3d5f/9ucXv/ -eXyG/3l7gf91eIH/c3Z//25wd/9qbXf/c3V8/3Bzff9wc33/c3Z//25wd/9ucXv/bG95/3l7gf91d33/ -bnB3/3Byef9ucHf/bnB3/25xe/9wcnn/cHN9/2xvef9sb3n/bG95/3Bzff9ucHf/bnB3/3N1fP9zdXz/ -Zmhu/3Bzff9qbXf/bnF7/2ptd/9sb3n/dXiB/3Bzff9ucHf/bG51/3V2e/92eYD/bG52/3R2fP9sbnX/ -cXN6/21vd/9vcXn/cHJ5/3Byef9ucHf/bnB3/25wd/9qbHP/bG51/2psdP9pbHT/cHJ4/25weP9sb3f/ -bnB5/21vd/9ucHf/aGt1/2hrdP9qbXf/aGt0/2xvd/9sb3n/aWx0/21weP9nanT/ZWhv/25xev9vcnr/ -a254/25xeP9ydHz/dHZ9/29xe/9vcnz/b3J8/3N1ev9xdH3/cnR9/3F0ff92eYH/dXiA/25xev9zdXz/ -c3Z//3Byef9rbnj/b3J8/3h6gP90dn//cnR7/29xef9pbHb/cHJ5/21vc/9vcXX/d3l//29xdf90dnz/ -dnh8/2tud/9maXP/c3V8/3N1fP93eX//bG51/2psc/9zdXz/b3F1/25wd/9sbnX/bnF7/2ptd/9qbXf/ -amxz/2xvef9ucXv/bG51/3d5f/9vcXX/bnF7/3N1fP91d33/bnB3/2ptd/9zdn//c3Z//25xe/9wc33/ -am13/3Bzff9wc33/dXd9/3N1fP91d33/bnB3/25wd/9sbnX/bG95/3N2f/9ucXv/c3Z//3V4gf9zdXz/ -cHJ5/3d5f/91d33/cHJ5/3V3ff9tb3P/bG95/2xvef9wc33/am13/25xe/9ucXv/c3V8/3Byef91d33/ -bnB3/25wd/9ucHf/cHJ5/3l8hv9sb3n/bnB3/25wd/9ucHf/cHJ5/25wd/9qbXf/cHJ5/3Byef94eX3/ -bnB3/25wd/9zdXz/bnF7/3V4gf91d33/am13/29xdf9wcnn/bW9z/2Zpc/9qbXf/Zmlz/3Bzff9sbnX/ -Z2p0/2xvef9qbHP/Z2p0/2xvef9ucHf/Z2px/2dqdP9iZW7/ZGZs/25wd/9sb3n/bnF7/3d5f/91d33/ -bG95/3V3ff9qbXf/bG95/29xdf93eX//cHJ5/25xe/9wcnn/bnF7/2psc/9sbnX/Zmlz/2ptd/9sbnX/ -bG95/2xudf9tb3P/bnB3/25wd/97fof/c3Z//3V4gf9zdXz/dXiB/25xe/91eIH/e36H/3V4gf93eoP/ -d3qD/3d6g/93eX//eXyG/3l8hv95fIb/eXuB/3t9g/9zdn//d3qD/3N2f/9wcnn/bnB3/2xvef92eHz/ -b3F1/3l7gf93eX//c3V8/3N2f/9ucHf/Z2px/21vc/9sbnX/bG51/2xvef9qbHP/am13/2dqcf9zdn// -bG95/2psc/9sb3n/bG51/2ptd/9qbXf/bG51/25xe/9sb3n/bG51/2xudf9ucHf/bG51/2dqdP9sb3n/ -bG95/11gav9qbXf/am13/3Bzff9sbnX/bnF7/3V4gf9ucXv/bG51/2xudf9ydHz/dHZ8/29xef9ucXv/ -bG50/25xef9nanT/am13/2dqdP9nanT/Z2px/2Zpc/9nanH/Zmlz/2ttdP9oa3T/bnB4/3V3ff9ydX// -c3aA/3J1fv9tcHn/cnV+/29ye/9tb3f/cXR+/3J1fv92eH7/c3aA/25xev91d33/cXR9/21wd/9vcnz/ -c3Z//3J1ff90dnz/cnR8/3N1fP9wcnj/bnB3/3Byef91d3v/cHJ5/25wd/9tcHf/c3V8/3J0fP9sbnX/ -bW9z/3N2f/9wcnn/amxz/25xe/93eX//dHeA/3J0fP9vcnv/a211/29yef9ucHf/bW9z/3d5f/9vcXb/ -c3V9/3V3fv9sb3j/Z2p0/3N2f/91d33/d3l//25wd/9sbnX/c3V8/2psc/9nanT/bG51/2ptd/9sbnX/ -bG51/2ptd/9sbnX/cHJ5/2xudf94eX3/bG95/25xe/9zdn//cHN9/2xvef9nanT/dXd9/3N2f/9sb3n/ -dXd9/2xvef9wc33/dXiB/3d5f/9zdXz/dXd9/25wd/9zdXz/amxz/2xudf9wcnn/am13/3Byef9sb3n/ -amxz/2Zpc/9wcnn/am13/2dqdP9wc33/amxz/2xvef9sb3n/bnF7/2xudf9zdXz/cHJ5/3Byef9wc33/ -bnF7/2ptd/9sbnX/bG51/2xudf93eX//bW9z/2xudf9sbnX/bG51/3Byef9wcnn/b3F1/2xvef9ucXv/ -dXiB/2xvef9ucHf/dXd9/3N1fP9zdn//dXd9/2xvef9ucHf/c3Z//25xe/9qbXf/cHN9/2ptd/95e4H/ -dXiB/3Bzff93eoP/c3Z//3t9g/9+f4P/eXyG/3d6g/91eIH/c3V8/3N2f/9qbXf/bW9z/25wd/93eX// -dXd9/3Byef93eX//cHJ5/3Byef9wcnn/e32D/3V4gf9wc33/bnF7/3Bzff9nanT/bG95/2ptd/9sbnX/ -bW9z/25wd/9ucHf/bG51/2dqdP9qbHP/dXiB/2xvef9ucXv/bG51/2ptd/9kZ3H/Z2p0/3Byef9maG7/ -am13/2dqdP9qbXf/Z2p0/2dqdP9sb3n/am13/3Bzff9ucXv/bG51/2xvef9sb3n/bG51/2dqdP9qbXf/ -dXd9/25wd/93eoP/dXiB/3V3ff91d33/b3F1/2Zobv9ucHf/bW9z/2xudf9ucXv/bG51/3Byef9tb3P/ -dXiB/3Bzff9qbHP/am13/2dqdP9sbnX/bG51/2ptd/9sb3n/bG95/2psc/9sbnX/Z2p0/2Zpc/9maXP/ -amxz/2xvef9iZW7/bG95/25xe/9wc33/amxz/2ptd/91eIH/bnF7/25wd/9sb3n/b3F4/3R2ff9wcnn/ -cXN4/21vc/9ydHv/bG51/25xev9wc33/cHN9/25wd/9wc33/cHN9/3Byef9wc33/bG94/25xef9xc3v/ -c3V8/29xeP91d33/bG95/3R3gP9ucXv/amx0/2xvef9ucXv/cHN8/3Bzff9wcnn/c3V8/3Byef9vcXj/ -cHN9/3Bzff9zdn//c3Z//3Bzff9wcnn/dXd9/3Byef9ucHf/d3l//25wd/9wcnn/bnB3/3V3ff91d33/ -bnF7/3Byef91eIH/bnF7/2ptd/9sb3n/c3Z//3Z4fP9xc3r/c3V8/21vdv93eoT/dXiB/3V3ff9/goz/ -cHJ8/3h6gf91d37/aWx2/2Vocv9ucXv/c3V8/3N1fP9qbXf/am13/3t9g/9wcnn/bnB3/3N1fP9ucXv/ -bG95/2xvef9wc33/bnF7/3N2f/9sb3n/d3l//2xvef9ucXv/bnF7/3V4gf9zdXz/Z2p0/3N2f/91d33/ -bG51/3V3ff9ucHf/cHJ5/3N2f/9zdn//c3Z//3N2f/9ucXv/c3Z//2ptd/9wcnn/cHN9/3Byef9wc33/ -c3V8/29xdf9ucHf/dnh8/3N1fP9wcnn/c3V8/21vc/9zdXz/bnB3/2xvef9ucHf/bnF7/2ptd/9ucHf/ -bnF7/25xe/9sbnX/bG51/2xudf9tb3P/dXiB/2psc/9qbHP/bG51/2dqdP9sb3n/bnF7/2ptd/9qbXf/ -am13/3V3ff9maXP/Zmhu/2ptd/9sb3n/bnF7/2xvef9maXP/Zmhu/2ptd/9maG7/XWBq/2Rncf9gY2z/ -bG95/2dqdP9qbHP/Z2p0/2psc/9qbXf/cHN9/3N1fP9ucXv/bnF7/2xudf9sbnX/am13/21vc/9ucHf/ -eXuB/3N1fP9wcnn/cHJ5/2xudf9qbHP/am13/3Bzff9sb3n/bG95/25wd/9wcnn/amxz/21vc/9sbnX/ -am13/2dqdP9qbXf/bG51/2xudf9sbnX/am13/3d5f/9sb3n/bnF7/2xvef9sb3n/bG51/3Byef92eHz/ -bG51/3N1fP9wc33/c3Z//3Bzff9zdXz/c3V8/3N1fP9wcnn/dXd9/2xudf9wcnn/bnB3/2ptd/9sbnX/ -am13/3Bzff9qbHP/d3l//3d5f/9zdXz/dXd9/25wd/9kZmz/bG95/2xvef9wc33/c3Z//29xdf9wc33/ -bnB3/3d6g/91eIH/bnF7/25xe/9sb3n/cHJ5/3Byef9wcnn/c3Z//3N1fP9wcnn/cHN9/3N2f/9wcnn/ -cHJ5/25xe/9zdn//Zmlz/3V4gf9wc33/d3l//2xudf9ucHf/d3l//25xe/9sb3n/bG95/3p8g/97fYP/ -dnmC/3V3ff91d3z/dHeA/3F0fP9zdXz/cXN6/3V3ff9ucHf/cHJ5/3Byef9sbnX/bnB0/29xeP9ucXr/ -b3F4/3N1fP9zdXz/bnB3/21vc/95e4H/dnh8/21vc/9sb3n/bnF7/3Bzff9wc33/c3V8/25xe/9ucXv/ -bG95/2xvef9sb3n/cHN9/3Bzff9ucXv/cHN9/25xe/9qbHP/bG51/3N1fP9nanT/amxz/2psc/9ucXv/ -cHJ5/2Zobv9kZ3H/Zmlz/2Zpc/9dYGr/Zmlz/2dqdP9sb3n/ZWhx/2Zpc/9jZnD/a254/2xudf9maXP/ -dXd9/2lrc/9wcnn/bXB4/2dpcP9laHL/am13/2xvef9zdXz/bG95/2xudf94eX3/bG95/25wd/9sb3n/ -bnF7/25xe/9ucXv/bnB3/3Byef9zdXz/bnB3/3h5ff9vcXX/bnF7/25wd/9zdn//cHJ5/2Zpc/9zdn// -cHN9/25xe/93eX//cHJ5/25xe/9zdn//c3Z//3Byef9zdXz/c3V8/3Byef9nanH/bG51/3Byef9sbnX/ -cHN9/3N1fP9ucHf/bG51/3V3ff9wc33/amxz/3V3ff9qbXf/bnB3/3Byef9ucHf/bG95/2ptd/9sbnX/ -bG95/25xe/9zdXz/am13/2xudf9qbXf/bG51/3V4gf9qbXf/bG51/25wd/9tb3P/bnF7/2xvef9sbnX/ -cHJ5/25wd/95e4H/bG51/2xudf9qbXf/bG95/2xvef9sb3n/Z2p0/2Zpc/9ucXv/am13/2Zpc/9sb3n/ -Zmlz/3N1fP9ucXv/bG51/2xvef9qbXf/dXd9/3Z4fP94eX3/c3V8/3Byef9sbnX/am13/3V3ff9zdn// -dXiB/3t+h/91eIH/cHN9/3N2f/9sb3n/bG51/25wd/95e4H/bG95/2xudf9sb3n/am13/2Rncf9nanH/ -YGNs/2Rncf9maXP/bG51/2ptd/9qbXf/am13/2ptd/91d33/bG95/3Bzff9sb3n/cHJ5/2xudf9sb3n/ -dXd9/2ptd/9sb3n/cHN9/3Bzff9ucXv/bG95/3Bzff9zdXz/bnF7/3N1fP9ucHf/dXd9/3Byef9tb3P/ -b3F1/2xudf9zdn//bnB3/3d5f/93eX//cHN9/3d6g/9ucXv/Zmlz/3Byef9ucHf/cHN9/3N2f/9sb3n/ -c3Z//25xe/91eIH/dXiB/3Bzff9zdn//cHJ5/25wd/9vcXX/bG51/3Byef9sbnX/am13/2xudf9sbnX/ -amxz/2psc/9qbHP/am13/2Jlbv9ucXv/bnF7/3N1fP9nanT/bnB3/3Z4fP9wcnn/bG51/2xudf95e4H/ -c3Z//25xe/9ucHf/bG95/25xev9vcXj/bXB6/21vef92eHz/cHJ5/25xe/9sb3n/bnB3/3Bydv9rbnf/ -bG94/29xeP9wcnn/dXiB/3Bzff9wcnn/eXyG/3l8hv9zdXz/bnF7/3V3ff9zdn//c3Z//3d5f/9wc33/ -cHN9/25xe/9wc33/cHN9/3h5ff91d33/c3V8/3N1fP9wcnn/am13/2psc/91d33/am13/2xudf9maXP/ -bG95/3N1fP9nanH/Z2px/2ptd/9qbXf/Zmlz/2xudf9zdXz/dnh8/3Byev9zdXz/cXR9/3R3gP9wc33/ -bnF7/3+CjP9zdn//dnmD/3h7hP9xc3r/c3V8/3t9g/9+gIb/e32D/3d6g/9wc33/e32D/3Bzff9zdXz/ -cHN9/25xe/9zdn//bnF7/2xvef9ucXv/dXd9/29xdf91eIH/bnB3/2xvef9ucHf/dXd9/2xvef9kZ3H/ -cHN9/3N2f/9ucXv/d3l//2xvef9ucXv/dXiB/3V4gf9zdn//c3Z//3V4gf9wc33/am13/2xvef91eIH/ -bnF7/3V4gf91eIH/bnF7/2xvef93eX//cHN9/3Byef91eIH/bnB3/25xe/9wc33/c3Z//3Bzff9wc33/ -cHN9/25xe/9wc33/dXd9/25wd/9ucHf/bG95/25wd/93eoP/bnB3/25xe/9wc33/cHJ5/3Bzff9vcXX/ -bnB3/3Byef9tb3P/d3l//2ptd/9sbnX/am13/25xe/9wcnn/cHJ5/2xudf9qbHP/cHJ5/2xvef9qbHP/ -cHN9/2dqdP91eIH/d3qD/3Bzff9zdn//cHJ5/3d6g/95e4H/e36H/3V4gf93eoP/cHN9/3V4gf9sb3n/ -bG95/3Byef91eIH/c3Z//25xe/9wcnn/bG51/2dqcf9ucHf/dnh8/21vc/9qbXf/bG95/3Byef9sbnX/ -b3F1/2RmbP9sbnX/bG51/2ptd/9sb3n/Z2p0/2dqdP9sbnX/dXd9/2xudf9ucXv/bnF7/2xvef9nanT/ -bG51/3N1fP9sbnX/cHJ5/3Bzff9ucXv/bnF7/25xe/9wc33/cHN9/2xvef91d33/bnB3/3V3ff9zdXz/ -b3F1/2xvef9sb3n/c3Z//3Byef93eoP/d3qD/3N2f/91eIH/cHN9/2dqdP9ucHf/bnF7/3N2f/9wc33/ -bnB3/3N2f/9wcnn/eHl9/3V3ff9sbnX/bG95/2xudf9sbnX/bG51/2Zpc/9sbnX/amxz/2Zpc/9maXP/ -Zmhu/2Zobv9maG7/amxz/2xvef9gY2z/Z2p0/2xvef9ucXv/Zmlz/2xudf91d33/bG95/2xudf9ucHf/ -bnF7/25xe/9ucHf/bG51/2xudf9sb3n/am13/3J0e/9zdn//d3l//3Bzff9wc33/cHN9/25xe/9xc33/ -bnB2/25weP9wcnn/cHJ5/3N1fP9sb3n/bG51/3d5f/91d33/am13/2xudf9ucXv/bG95/25xe/9wc33/ -bG51/2xvef9sbnX/Z2p0/2xvef9wcnn/bG95/2dqdP9wc33/bG95/2xvef9qbXf/dXd9/2ptd/9qbXf/ -am13/3Z4fP92eHz/bnB3/25xe/95e4H/cHN9/3Byef9zdn//d3qD/3l7gf93eoP/dXh//29yfP9vcnv/ -b3F1/2xudf93eoP/b3F4/3d5f/97fYb/dHZ//3V3ff97fYP/foCG/3t9g/9zdn//cHJ5/3l8hv9wc33/ -c3V8/3N2f/91eIH/d3qD/3d6g/9ucXv/cHN9/3N2f/9wcnn/d3qD/3N1fP9zdn//c3V8/3N2f/9sb3n/ -Zmlz/3N2f/91d33/bG95/3l7gf9sb3n/bnB3/25wd/9zdXz/bnB3/25wd/91d33/bnB3/2xudf9qbHP/ -cHJ5/21vc/92eHz/cHJ5/2xudf9sb3n/eHl9/3V3ff9wcnn/d3qD/25wd/9wc33/bnF7/3V4gf9wc33/ -bnF7/2xvef9sb3n/c3Z//3N2f/9wcnn/bG95/2xvef9sb3n/d3l//25wd/9vcXX/b3F1/29xdf9zdXz/ -bnB3/25wd/9ucHf/b3F1/3d5f/9qbXf/bG51/25wd/9wcnn/bnF7/3Byef9sbnX/amxz/3Byef9wcnn/ -amxz/3Byef9qbHP/cHN9/25xe/9tb3P/bnB3/21vc/91d33/dXiB/3V4gf9zdn//cHN9/25wd/9ucHf/ -c3V8/3Bzff91eIH/foGK/3t9g/93eoP/d3qD/3Byef9ucXv/dXiB/3d5f/9sb3n/bnB3/3Bzff9wc33/ -Z2p0/25wd/9maG7/bG51/2xudf9tb3P/bG51/2psc/9sb3n/bnB3/3l8hv9wc33/c3Z//3Bzff9wc33/ -am13/2xvef93eoP/cHJ5/3N1fP91d33/dXd9/3V3ff9zdXz/dXd9/3V3ff9wcnn/dXd9/29xdf91d33/ -dXd9/3Byef9sb3n/b3F1/3Byef9tb3P/dXd9/3d5f/9ucHf/cHJ5/3Byef9kZ3H/am13/2Zpc/9sb3n/ -bnF7/2ptd/9zdXz/bG51/3V3ff9zdXz/bnB3/3N1fP9sb3n/bG95/25wd/9ucHf/bG95/25wd/9wcnn/ -c3V8/29xdf9ucHf/bG51/29xdf9zdXz/Z2px/2xvef9zdn//eXuB/3Byef9wcnn/eXuB/25xe/9sb3n/ -bnB3/3Byef9ucHf/bnB3/29xdf9sbnX/bnB3/2xvd/9vcXn/am13/3Bzff9qbXf/am13/2psc/9ucHf/ -am13/2xudf9sbnb/bW92/3Byef9ucXv/bG95/2ptd/93eX//dXd9/3Byef9ucHf/c3V8/3N1fP91d33/ -c3V8/25wd/9wcnn/bnB3/3Bzff9zdn//eXuB/3N2f/9wc33/eXuB/3Bzff9wc33/cHJ5/3Z4fP9zdXz/ -bG51/2xvef91d33/c3V8/2xudf9qbHP/bG95/2ptd/9qbHP/bG95/2xvef9wcnn/am13/2tueP9maXD/ -Z2p0/2dqcf9iZW7/cHJ5/2hqcf9xc3r/bnB5/2xudf9qbXf/cHN9/3Z4fP9wcnn/bnB3/2xudf93eX// -Zmlz/2ptd/9ucHf/am13/25xe/9ucXv/bW9z/25wd/9sb3n/am13/3V3ff9qbXf/bG95/2ptd/9sb3n/ -ZGdx/11gav9qbXf/am13/2xvef9zdXz/Z2p0/2xudf9wcnn/bnB3/2xudf9ucHf/cHN9/25wd/9sbnX/ -am13/25xe/9sb3n/d3l//3Bzff9ucXv/bnF7/3l7gf91eIH/cHN9/3l8hv9zdXz/d3qD/25xe/91d33/ -c3V8/3N1fP9vcXX/bG51/3N1fP9wcnn/b3F1/21vc/9tb3P/bG51/3d5f/9sb3n/amxz/2xudf9sbnX/ -c3V8/2xudf9ucHf/bnB3/25wd/93eX//bnB3/2xudf9wcnn/c3V8/25xe/9wc33/bG95/25wd/91eIH/ -d3qD/3Bzff93eoP/cHN9/3l7gf91eIH/dXd9/3l7gf95e4H/e32D/4GDiv9/gYf/foCG/36Ahv9wc33/ -cHN9/2ptd/9sbnX/bG95/3N1fP9wc33/bnF7/25xe/9qbXf/Z2p0/25xe/9wc33/am13/2Zpc/9nanT/ -Z2p0/2Rncf9maXP/ZGdx/2dqdP9qbXf/amxz/2xudf9kZ3H/am13/2xudf97fYP/cHN9/3N1fP9ucXv/ -dXiB/2xvef9ucHf/d3l//25wd/9zdn//d3l//3V4gf91d33/cHN9/3l7gf95e4H/dXiB/3l8hv9wcnn/ -eXuB/3V4gf9wc33/cHN9/3N2f/91eIH/bnF7/3d5f/93eX//bnF7/3N1fP9tb3P/Z2px/25wd/9sbnX/ -dXd9/25wd/9qbXf/c3V8/2xudf9wc33/c3V8/2ptd/9wcnn/bG51/2xvef9tb3P/b3F1/2xvef9sb3n/ -bG95/25xe/9ucHf/bnF7/3N2f/9wcnn/d3l//2xvef9wc33/eXyG/3t+h/9zdn//d3qD/36Ahv93eoP/ -d3qD/3V4gf9ucXv/bnF7/25xe/9vcXX/amxz/3R2ff9wcnr/c3V6/25wd/92eHz/c3Z//25xe/9ucXv/ -bG95/29ye/9tb3f/bnB3/25wdP9sb3n/c3V8/25wd/9qbXf/dXd9/3V4gf9wc33/bG95/3N2f/91eIH/ -d3l//3N2f/9zdXz/dXiB/3V4gf95fIb/dXiB/3t+h/93eoP/dXiB/3t+h/9zdn//dXiB/25xe/97fYP/ -c3Z//2xvef9wc33/c3Z//3d5f/9vcXX/b3F1/3Bzff9wc33/bnB3/3Bzff9zdn//c3V8/29xeP9ucXn/ -bW90/2xveP9qbXf/Z2px/3d5f/9tb3T/c3V8/3N2fv9ucHj/cHJ5/3V4gf93eoP/c3Z//3N2f/9zdn// -c3Z//2Rncf9maXP/Z2p0/2Zobv9qbXf/bG95/2psc/9nanT/am13/2dqcf9ucHf/ZGdx/2Zobv9maG7/ -Z2p0/2Rncf9gY2z/Z2p0/2dqdP9qbXf/cHN9/2dqdP9sbnX/bnF7/2xvef9qbXf/bG95/25xe/9sbnX/ -bG51/25wd/9wcnn/b3F1/3l7gf93eoP/c3Z//3N1fP95e4H/eXuB/25xe/93eX//bnB3/25xe/9sb3n/ -dXd9/3Byef9zdXz/bG51/2xudf9wc33/bG95/2xudf9sbnX/bG51/2ptd/91eIH/bnF7/2dqdP9nanH/ -Z2px/2Zpc/9maG7/Zmhu/2dqcf9qbHP/c3V8/2Zpc/9kZ3H/am13/25xe/9qbXf/bG95/2dqdP9qbXf/ -cHN9/3Bzff9nanH/cHN9/2ptd/9zdn//cHJ5/29xdf9wcnn/cHJ5/3N1fP91d33/dXd9/3Bzff9ucXv/ -bW9z/21vc/9ucHf/bnF7/3N2f/93eX//d3l//3d6g/9zdn//c3Z//3Bzff93eoP/foCG/3l8hv91d33/ -dXiB/3N2f/9ucXv/cHJ5/2xvef9zdXz/bnB3/25wd/9sb3n/amxz/29xdf9wcnn/e36H/3V4gf9zdn// -cHN9/3N2f/9ucHf/bnB3/3Z4fP9tb3P/c3V8/3Z4fP9wc33/cHN9/25xe/93eX//d3l//3Bzff95fIb/ -bnF7/3d5f/91eIH/cHN9/3N1fP9wcnn/bnF7/2xvef92eHz/dXiB/25xe/9ucXv/bG95/2ptd/9qbXf/ -bG95/3V3ff9wcnn/b3F1/3Z4fP9ucHf/c3V8/3V3ff9ucHf/c3V8/2ptd/9sbnX/bW9z/21vc/9ucHf/ -bG95/2xudf9ucHf/bW9z/21vc/9ucXv/am13/3V3ff9maG7/am13/2xvef92eHz/bnB3/29xdf91d33/ -am13/3Bzff91d33/d3l//3t9g/93eX//d3l//3d5f/98fYL/dniA/3Z4gP9xc3r/d3l//3Bzff9ucXv/ -bnF7/3Bzff9tcHr/b3J8/3F0ff9zdXz/cHN9/3l7gf9wc33/bnF7/3V3ff91eIH/bnF7/25xe/91d33/ -bnF7/3N1fP9ucXv/am13/3Byef9ucHf/dnh8/29xdf94eX3/bnB3/25wd/93eX//cHJ5/3Byef9ucHf/ -eHl9/3Byef9ucHf/dXd9/3N1fP95e4H/b3F1/21vc/9wcnn/bG95/2xudf9ucXv/cHJ5/3J0e/9sbnb/ -bG52/2Vocv9maXP/Zmhu/2Rncf9zdn//Z2px/21wd/9rbXb/Zmhv/2Nmb/9qbXf/cHJ5/2xvef9ucXv/ -bG95/3V4gf9qbHP/bG95/25xe/9ucXv/dXd9/3N1fP9vcXX/cHJ5/3N1fP9sbnX/c3V8/2ptd/9qbXf/ -bG51/25wd/9nanT/Zmlz/2ptd/9sbnX/am13/3V3ff9qbXf/am13/3Bzff9qbXf/bG51/2ptd/9qbXf/ -amxz/2Zpc/9kZ3H/bG95/2psc/9zdXz/cHN9/2xvef9qbHP/bG95/3N1fP9qbXf/dnh8/2ptd/9ucHf/ -bG95/3N2f/9ucXv/dXd9/25wd/9wcnn/c3Z//3Bzff9wcnn/bnB3/3Byef9wc33/f4GH/3V4gf9zdn// -bnF7/3Bzff9zdn//cHJ5/3Byef9wc33/cHN9/3l7gf9sb3n/bG95/2xvef92eHz/bnB3/25wd/9ucHf/ -b3F1/3Z4fP9wcnn/Zmlz/25xe/9qbHP/bG95/2xvef9qbXf/cHJ5/25wd/9wc33/dnh8/3Z4fP9zdn// -c3Z//25wd/9sb3n/Z2p0/2ptd/9ucXv/c3V8/3N1fP9wcnn/bW9z/2psc/9maG7/bG51/3V3ff9sb3n/ -bG51/3Byef9ucHf/bG51/3Byef9sbnX/bnB3/25wd/9tb3P/cHJ5/2Rncf9sbnX/bG95/3V4gf9ucXv/ -bG95/25xe/92eHz/bnB3/25wd/92eHz/bG51/3N1fP92eHz/dXd9/3Bzff9ucXv/c3Z//3Z4fP9vcXX/ -d3l//25wd/9zdXz/cHJ5/3Byef9ucHf/cHJ5/3Bzff9ucXv/eXuB/3l8hv91eIH/cHN9/25xe/9qbXf/ -bnF7/25xe/97fYP/dXiB/3N1fP95e4H/bG95/25xe/9wc33/bnB3/3N2f/9sb3n/cHJ5/3Byef9zdXz/ -dXiB/3N2f/9zdXz/c3Z//3N1fP9zdXz/d3qD/3N2f/97fof/bnF7/3Bzff9wc33/eXuB/25wd/9ucXv/ -dXiB/3Bzff95e4H/e32D/3V4gf91eIH/cHN9/3Byef9qbXf/dnh8/3Fzev9zdXz/cHJ5/3N2f/9zdn// -bnF7/2xvef9wc33/bG51/2xudv9rbXb/aWxz/2dpb/9ucXv/am13/2Rncf9qbXf/am13/2Zpc/9nanH/ -am13/2dqdP9sb3n/cHN9/2ptd/9ucXv/bW9z/3Byef9ucHf/eHl9/25wd/9sbnX/dnh8/3N1fP9wcnn/ -cHJ5/3d5f/9wcnn/bnB3/3N2f/9wcnn/d3qD/25wd/9sb3n/bnF7/25wd/9vcXX/c3V8/3Byef9vcnz/ -b3F4/3N1ff9ucXv/dHeA/3N1fP9zdXz/foCG/25wd/91d33/c3V9/21vdP9sb3b/c3V8/3V3ff9wc33/ -bG95/3Byef91d33/Z2px/2xvef9ucXv/cHN9/3N2f/9zdn//bG95/25xe/9wc33/bnF7/3V4gf9ucXv/ -bnB3/2xudf9zdXz/bnB3/2psc/9ucHf/bG51/3N1fP92eHz/bnB3/2xvef91d33/bnB3/25wd/9wcnn/ -cHJ5/2xudf9sbnX/bnB3/3V3ff9tb3P/eHl9/2xvef9ucXv/amxz/2xvef9zdXz/bG51/3N1fP9sbnX/ -c3V8/2xudf9zdXz/cHJ5/25xe/9ucHf/bG95/3Bzff9wc33/b3F1/25wd/9vcXX/cHJ5/3t9g/9ucHf/ -c3V8/2xudf9ucHf/bnF7/25wd/9ucHf/cHJ5/3Bzff93eX//bnB3/2xvef9ucHf/c3V8/25wd/9sbnX/ -am13/2ptd/9wc33/bnF7/2Rncf9qbXf/Z2p0/2ptd/9qbXf/amxz/25wd/9sbnX/bG95/3V3ff9wc33/ -cHN9/25xe/9sbnX/amxz/25wd/9wc33/cHN9/3d5f/91eIH/d3qD/3N2f/92eHz/bnB3/36Ahv9/gYf/ -eXuB/3p7f/9+gIb/e36H/3d6g/97fof/d3l//3l7gf92eHz/c3Z//31+gf9zdXz/eHl9/3t9g/9/goz/ -e32D/3d6g/9zdn//eXuB/2xvef9vcXX/dnh8/2ptd/9ucXv/c3V8/3Bzff9qbXf/am13/25xe/9ucXv/ -Z2px/3Byef9maXP/bG95/2ptd/9sb3n/Zmlz/2Rncf9kZmz/Zmhu/25wd/9wcnn/Zmlz/2xudf9qbXf/ -Zmlz/2dqdP9sbnX/dXd9/3Byef9ucHf/eHl9/25wd/9sbnX/c3V8/2xudf91d33/bG51/29xdf9wcnn/ -bG95/3V3ff9ucXv/bG95/3Bzff9sb3n/b3F1/3Byef9ucHf/dnh8/2Rncf9ucHf/bG51/3d5f/9qbXf/ -am13/3N1fP9sbnX/dnh8/3Z4fP9tb3P/bG95/25xe/9ucHf/amxz/3R2fP9tb3f/c3V6/2xudf9wcnn/ -cHJ5/25xe/9qbXf/c3V8/29xeP9xdH7/cXR+/3F0ff9wc33/dXd9/25xe/9sb3n/eHl9/3d5f/9ucHf/ -bnB3/3V4gf9sb3n/c3Z//3V3ff9vcXX/c3V8/25wd/9zdXz/bG51/3l7gf9ucHf/bnB3/3Z4fP9ucXv/ -bnF7/2ptd/91d33/bG95/2psc/92eHz/cHJ5/3h5ff9vcXX/b3F1/3Byef9sbnX/bG51/25xe/9sbnX/ -cHJ5/25wd/9xc3r/bnB0/29xeP9ucHf/bG51/3t9g/9ucHX/dHd+/3N1e/9vcXX/b3F1/3N1fP91d33/ -cHN9/25xe/9wc33/d3l//2Rncf9sbnX/cHJ5/2xvef9wc33/am13/2xudf9ucHf/bnF7/25xe/9wc33/ -am13/2xvef9nanT/bG95/2psc/9kZ3H/am13/2xudf9ucXv/c3V8/2dqdP9qbHP/bG95/2ptd/9sb3n/ -bG95/2ptd/9sbnX/am13/2ptd/9wc33/bG95/3V3ff9wc33/bnF7/2xudf9zdXz/dnh8/25wd/93eoP/ -bG95/3V3ff9ucXv/c3Z//3Byef91d33/cHJ5/25xe/91eIH/dXiB/25wd/9ucXv/cHJ5/3V4gf97fof/ -c3Z//3V4gf9zdn//bnF7/3N2f/9wc33/cHJ5/3Byef9ucXv/d3qD/3Byef9sb3n/cHN9/3V4gf9wc33/ -bnF7/25wd/9sbnX/dnh8/3Byef9sbnX/cHJ5/2xudf9qbXf/bG51/2psc/9sb3n/bW9z/3Byef92eHz/ -dXd9/3V3ff9wcnn/bG95/25xe/9ucHf/dXd9/3Bzff93eX//dnh8/3N2f/9wcnn/bG95/2Rncf9zdn// -dnh8/25xe/9qbXf/cHN9/25xe/9ucHf/cHN9/2dqdP9wcnn/bG95/25wd/91d33/Z2p0/2xvef9wc33/ -eXyG/3Z4fP9wc33/c3V8/3d5f/9sb3n/bnB3/3Z4fP9sb3n/c3Z//3d6g/91eIH/cHN9/3N2f/95e4H/ -d3l//25wd/95e4H/bnF7/3V3ff9zdn//c3Z//3Bzff9wcnn/cHN9/25xe/93eX//d3l//3N2f/9ucXv/ -bnF7/2dqdP9sb3n/bnB3/3Z4fP9ucHf/bG95/3V4gf9ucHf/b3F1/3Bzff9ucHf/eXuB/2ptd/9ucHf/ -bnB3/29xdf91d33/cHJ5/25wd/9zdXz/bnB3/29xdf9wcnn/b3F1/3Z4fP9kZ3H/am13/2xvef91eIH/ -am13/2xudf9ucXv/Zmlz/3Bzff9zdXz/c3V8/3V4gf91eIH/bnF7/2ptd/9vcnz/bG95/3N1fP9naXD/ -Z2p0/2ptd/9sb3n/am13/25xe/9tb3b/cXN7/3F0fP9vcnv/cHN9/3V3ff9wc33/b3F1/3V3ff91eIH/ -bnF7/25wd/91d33/bG95/25xe/91eIH/bnB3/3N2f/9sb3n/c3V8/2xudf95e4H/bnB3/3N1fP93eX// -dXd9/3Byef9wcnn/dnh8/2xvef9qbXf/cHN9/2xvef91d33/am13/2Zpc/9nanT/bG51/2psc/9sb3n/ -bG51/2xvef9qbXb/am13/2lsdf9rbnj/am13/2dqdP91eIH/a211/3N1ff9sb3n/am12/2xudf9wcnn/ -dXd9/3N1fP9zdXz/dXd9/3Byef9dYGr/YmVu/2Zpc/9nanT/am13/2Rncf9maG7/ZGdx/2Zpc/9maXP/ -Z2p0/2Zobv9nanT/ZGdx/2Rncf9iZW7/XF9o/2Zobv9maG7/am13/25wd/9kZ3H/Zmlz/25xe/9sb3n/ -bnF7/2ptd/9sb3n/bnF7/2ptd/9tb3P/dXd9/3Byef95e4H/cHN9/3Bzff9vcXX/dXd9/3V3ff9ucXv/ -dXiB/25wd/92eHz/bnB3/3Z4fP9wcnn/c3Z//25wd/9ucHf/cHJ5/3Byef9tb3P/bG51/21vc/9zdXz/ -d3l//2xvef9sb3n/bG95/2xudf9qbXf/am13/2ptd/9nanT/bG51/3V3ff9ucHf/bnB3/25wd/9zdn// -cHJ5/25wd/9sbnX/bnB3/3N1fP9zdXz/bG51/3Byef9sbnX/bG51/25xe/9wcnn/cHN9/3Bzff9zdn// -e36H/3l7gf91eIH/cHN9/3Byef9ucXv/bG95/3Bzff91d33/d3qD/3d5f/93eoP/cHN9/25xe/9qbHP/ -eXuB/36Ahv95fIb/dXd9/3d6g/91eIH/c3Z//3V4gf9wc33/d3qD/3Bzff9zdn//eXyG/2xvef9ucHf/ -cHJ5/3l7gf9zdXz/cHJ5/3Byef92eHz/bnB3/3Byef9wc33/bG95/3N2f/91eIH/c3V8/2xvef9wcnn/ -e32D/3l7gf9sb3n/dXiB/3Byef9zdn//cHN9/3N2f/9zdn//bnB3/3V4gf9wc33/d3l//3V4gf91eIH/ -c3V8/3Bzff9qbXf/b3F1/21vc/91d33/bG95/2xudf91d33/am13/2xudf9qbXf/bG51/3V3ff9qbXf/ -bW9z/2xudf9tb3P/dXd9/2ptd/9tb3P/cHJ5/2ptd/9sbnX/bG95/2xudf91d33/Zmhu/25wd/9sbnX/ -dXd9/2xudf9vcXX/dnh8/2xudf92eHz/cHN9/21vc/9wcnn/c3V8/3Byef9nanT/bnF7/29ye/9wc33/ -bG51/2xvef9qbXf/am13/2xvef9zdXz/bnB0/3J0ev9xdHv/bnB6/25xe/91eIH/cHN9/25wd/95fIb/ -d3qD/3Bzff9wc33/d3qD/25xe/9wc33/eHl9/2xudf9ucHf/bG95/25wd/9qbHP/d3qD/2ptd/9sb3n/ -d3l//25xe/9qbXf/bnB3/3V3ff9ucHf/amxz/3Bzff9sbnX/dnh8/2xvef9qbXf/am13/2xudf9qbXf/ -c3V8/2xudf9wcnn/bW92/3ByeP9vcXX/bnB3/2dqcf9nanH/d3l//25xdf90dnz/bW94/2tueP9nanT/ -bnF7/3V3ff9sb3n/cHN9/25xe/92eHz/YmVu/29xdf9zdn//d3l//3V4gf9wc33/bG95/25xe/9zdn// -dXiB/3d6g/9ucXv/eXuB/3N2f/97fYP/cHN9/2xvef9zdn//cHJ5/3N2f/97fof/c3Z//3Bzff93eoP/ -c3Z//3d6g/9wc33/cHN9/3Bzff9sb3n/bnB3/3V4gf9zdn//foGK/3N2f/9wc33/bnB3/3V3ff9zdn// -bnB3/3V4gf9sbnX/dnh8/25wd/92eHz/cHN9/3Z4fP9ucHf/bG95/25xe/91d33/b3F1/3Byef9wc33/ -d3qD/36Biv91eIH/dXiB/25xe/9ucHf/cHN9/2xvef9ucXv/bG95/25wd/9wc33/bG95/2xvef9wcnn/ -dXd9/3Byef9tb3P/bW9z/2dqdP9wc33/bG95/2dqdP9sb3n/ZGdx/2Zpc/9sb3n/Zmlz/2dqcf9maXP/ -bG51/3V3ff9sb3n/c3V8/25wd/9ucHf/bG51/2tueP9vcnz/dXeA/3h7hf9ydX7/dXd9/25wd/9ucHf/ -Zmds/3Byef9wcnn/c3V8/2dqdP9wcnn/cHJ5/2xudf9qbXf/Zmlz/2psc/9maXP/aGty/25xe/9nanT/ -a210/2hrdf91eIH/bnF7/2xvef9qbXf/c3V8/2dqdP9qbXf/am13/2xudf9ydHv/dHZ8/2ptd/9sb3n/ -bW92/3N1fP9ydHv/am12/3d4ff9wcnn/dXiA/3J1fv91eIH/cnR8/2xudf9wcnn/cHJ5/3V3ff9wcnn/ -cHJ5/21vc/9ucHf/Z2px/25wd/9ucHf/dHZ8/29xeP9sb3b/dnh//29xdf9sb3n/bnF7/29xdf94eX3/ -amxz/29xdf9tb3P/cHJ2/3V3ff9wcnn/b3F4/3R2fv9ucXj/bW93/3Fze/9vcXX/dXd+/2dpb/9sbnX/ -bnB6/3d5f/9sb3b/a254/3V3e/9sbnT/dHZ6/3Bzff92eHz/e32D/36Ahv99foH/d3l//3l7gf91d3z/ -c3Z+/2tudf9sb3n/am13/2Zpc/9nanT/bnF6/2ptdv9zdX7/c3V9/3V4gP9wc33/e32D/3V4gf9ucXv/ -e36H/3d5f/9ucXv/bG95/3Bzff9vcXX/bnF7/3Z4fP9sbnX/am13/25wd/9wcnn/bG51/3l7gf9ucHf/ -c3V8/3h5ff9zdn//bG51/25wd/94eX3/bnB3/2psc/9zdXz/bnB3/3Z4fP9ucHf/bnB3/21vc/9tb3P/ -bG95/3Bzff9sbnX/cHJ5/25xeP9ucHn/bG52/2tudv9nanT/am12/3F0fv9pbHX/bXB6/2psdP9nanH/ -Y2Zv/2Zpc/9ucHf/am13/25xe/9ucXv/b3J7/2Zpcv9rbnf/bW94/29yfP9ucXr/b3J6/21vdv9vcXj/ -bG93/2lsdP9rbXb/bXB4/21wev9nanP/aGt0/2Fkbf9gY2z/amxz/2dqcf9oa3X/cnV8/2Zocf9qbXb/ -a212/2xudf9sbnf/bW92/3Byef9ucHn/b3F4/2psdf9ucXv/bnF6/29ye/9sb3n/bW94/25wdf9xc3r/ -bnF3/3F0e/9vcnv/bXB4/3J0fP9ucHf/cHJ5/21wev9ucXv/amx1/2ptc/9tcHj/b3F4/3J0ef9tb3b/ -bXB4/3Bze/91d33/dHZ+/3Bze/9wcnn/b3F4/3h6gv93eH3/dHZ7/3Z4f/92eYL/d3qB/3d5gv90d3// -eXyF/3t+h/99f4f/e32G/31/hf98foX/fYCI/3p9hv9+gIb/e32E/3V3fv95e4P/enyD/3d5f/95e4H/ -enyE/3l8g/97fYL/dnh//3V3fv92eYL/cnV9/3Fze/9sb3j/bnF5/3F0ff9zdXv/bXB5/3R2ff9rbXX/ -amx1/2Rmbf9pbHX/aWx2/25wev9fYmz/Zmlz/2dqdP9kZ3H/Zmlz/2BjbP9maG7/XmFr/2Vocv9qbXf/ -Y2Zw/2Zpc/9oa3T/b3F5/2dqdP9maXP/ZGdx/25wd/9kZ3H/Zmlz/2Zpc/9oa3T/cXN6/3N1fP9rbnj/ -bnF6/2xvef90dn3/cHN7/2ttdf90dn3/b3J6/3V3ff9vcnv/dHd//3Byef9ucHf/cnV+/25xe/93eX// -cHJ5/3N1fP9ucHf/cHJ5/2dqcf9ucHf/bnB3/3R2ev9sbnb/a211/3N1fP9tb3T/bG51/25wd/9ucHf/ -dXd9/2dqdP9sbnX/bW95/25weP9xdHz/bnF5/2xveP9xc3z/bnB3/2xudf9xdHz/bnB3/3F0ff9sbnf/ -bnB5/29xeP92eH7/b3F4/3J0eP9xc3r/bG93/3Fzev9vcXr/am13/3N1fP9sb3n/cHN9/2xudf9zdX3/ -dHZ9/3V4gP9ucXv/c3Z//3N2f/9sb3n/cHJ5/3R2fP9vcXr/dnh+/3FzfP9vcnz/bnF7/3N2f/9sb3n/ -bG51/3d5f/92eHz/bnB3/2ptd/9qbXf/amxz/25xe/93eX//amxz/2ptd/9sbnX/Z2p0/2Jlbv9wc33/ -ZGdx/2ptd/9ucHf/am13/2psc/9qbHP/bnF7/2psc/9kZ3H/bG95/2xudf9wc33/am13/2Zpc/9sb3n/ -am13/25wd/9zdn//bnB3/25xe/9ucHj/b3F5/2hrc/9qbHT/Zmlz/2lsdv9rbnf/Z2py/25weP9xdHz/ -bW90/2hrdf9sb3n/cHN9/2xvef9zdXz/c3V8/3Bzff9rbnf/b3J8/29yfP9ydX//dXd+/3R2ff9tb3b/ -cnR6/2xveP9tcHr/bnB4/3J1ff9vcnz/bG52/3Fzff9oa3X/ZGdx/21vc/9tb3P/c3Z//3Z4f/9vcnr/ -cXN7/3F0ff9wcnz/bnF6/3Bzff9ydX7/c3Z//3N2f/9sb3n/c3Z9/3J1fv9ydX//dnmC/3N2f/92eYH/ -dXiB/3J1fv98foX/dHeB/3F0ff9ydX7/cHN8/3R3f/91d33/cHN8/29xef9vcXX/cHJ5/3Fzd/91d33/ -bnB3/25xe/9ucXv/cnR6/3F0fP9xc3j/bG52/21wef90dn3/dXh+/21vd/90d3z/bnF4/29xef9wc3z/ -bG95/3Bzff9xdH7/cnV+/25xev9wc3z/cnV+/3N2f/9wc3z/d3qE/3BzfP9rbnf/bnF6/3Byef9vcXn/ -cnR7/29xef9ydHv/bW92/2hrcv9qbXf/am13/2xudf9tb3P/cnR8/3N1fP90dn7/c3V6/3N1fP91eH// -bXB4/3F0e/9rbXP/bXB6/2xvd/90dnz/aGt0/3J0e/9zdXz/bnB3/3N1fP9ucHf/bnB3/2ttdP9wc3n/ -c3V7/3ByeP9wcnj/cXN5/3V3gP9ydHv/cHJ5/3Byef95e4H/bG51/2tud/9rbXb/bG95/25xe/9xc3r/ -bG53/29xeP9zdXn/dHd+/3Fzef9sbnT/cnR9/3F0ff9ydHz/bW94/3V4f/9ucXn/bG94/21wev9wc33/ -d3l//3Byef9wcnn/bW9z/25wd/9maG7/bG51/21veP90dnv/b3F6/21wev94eoH/cnV//3Fzev9sb3n/ -cHJ5/3Z4fP9sbnX/bW92/25xe/9wc33/dnmA/3FzfP9wc3z/dnmD/3R2fv9vcnr/dniB/3Z4gf92eH3/ -cnV+/3R3gf9ydHz/fH6E/3d5gP94eoD/c3Z+/2xveP9ucXr/bnF4/2Zpc/9sb3n/am13/25xe/9kZ3H/ -cXN9/25xev91eID/bnF7/2xvef9zdXz/bW92/3Byef91d37/cXR9/3t9h/90d3//cXR9/3N2f/95e4H/ -c3Z//3V3ff9/goz/foCG/3d6g/9zdn//d3qD/3Bzff95fIb/f4GH/3d5f/93eoP/c3Z//3d6g/91d33/ -foGK/3Bzff91eIH/d3qD/3N2f/9ucHf/bG95/3N2f/9zdn//am13/25xe/9ucXv/c3Z//3Bzff9qbXf/ -c3V8/3Bzff9ucXv/dXd9/29xdf9ucHf/bXB3/3V3ff9tb3j/bnF6/25xe/90dn3/cXN7/29yfP9vcnz/ -cHN9/3Fzev9ucHf/cHJ5/3V3ff91d33/d3l//3Z4fP9tcHn/aWx2/2xvef9rbXT/am13/21wef9vcnz/ -am13/29yfP9nanT/bG95/2tueP9vcnv/bnF5/2tudv9ydHv/bG51/2Zpc/9vcXX/bnB3/3Bzff91eIH/ -bG95/25xe/9ucXv/bG95/21vdv9ucHf/c3Z//3N2f/90d4D/bnF7/21wev9zdn//b3F4/3N2f/9ucXv/ -c3V8/3N2f/9zdXz/eXuF/3Bzff9zdn//c3Z//3N2fv9zdn//eHqA/25xe/9tcHr/cnR8/3Byef9wcnn/ -cHN8/3Byef9ucHf/bnB3/21vdv9wcnn/b3F1/2dqcf9qbXf/cHN9/3Bzff9qbXf/dHZ8/25wd/9ucHf/ -cHJ5/21vd/9zdXz/bG95/3V4gf9ucXv/cHN8/3N2f/9ucXv/bnF7/3h7hf95fIX/dnh8/3x9gP99f4b/ -foCG/3x9gf9+gIf/foCG/3d6g/93eoP/eXyG/3t9g/95e4H/dnh8/25wd/9ucXj/b3J7/3Fzev9ydHv/ -eXt//3R2ff90dnz/bG94/3Byef9wcnr/dHd//3J0ff98foT/fX+F/3V3ff97fYP/dnh8/3Z4fv91dnv/ -d3l+/3F0fP90d37/cHJ6/3V4f/90d4H/cHN7/3Byef9zdXz/dXiB/2ptd/9tb3b/bW92/29yev9xdH7/ -b3F4/2lsdv9tb3f/c3V7/3N2f/9tcHr/bW92/3F0fv9ydX3/c3Z8/2xudf9ydX7/a210/2hrdf9maXP/ -bXB5/3N1fP9wc33/am13/2xudf9sbnX/Z2px/2xudf9vcXX/cHJ4/2ttdv9ucXr/dHd+/29yd/9sbnb/ -b3F1/3Bzff93eX//bnB4/2xvef9ucXr/cXN6/3Fzev9vcXj/bnB3/3h6gP9ydHv/bG51/29xeP9ydHv/ -bW92/2tudf9ucHf/amxz/3N1fP9ydHv/bnF6/2dqdP9nanT/aGt1/2xvef9nanT/bG95/2ptd/9ucXv/ -ZGdx/29xe/9xc3n/cnR9/2xvef9ucHf/c3V8/2xvef9tcHn/dHZ+/25xeP9zdn//a254/2ptdv9nanT/ -bG95/2Zpc/9kZ3H/dXd9/3Byef9qbXf/bG51/2xudf9qbHP/cHN9/3N2f/9qbHP/Z2p0/2dqcf9nanT/ -Zmlz/3V3ff9qbXf/bnF7/2xvef9sb3n/bG51/2xudf9sb3n/c3V8/2dqcf9ucHf/bnB3/25xe/9ucHf/ -Z2px/2xudf9ucHf/c3V8/3Z4fP9vcXX/cHJ5/25wd/91d33/aWx1/2xudf9sb3n/cHN8/2tueP9ucHf/ -bXB5/3J0fP9ucXb/b3F1/2xvef9zdXz/c3V8/3d5f/92eHz/cHN9/2ptd/9qbXf/Z2p0/2ptd/9sb3n/ -bnF7/2Zpc/9qbXf/YmVu/2dqdP9laHL/aGt0/2lsdf9oanH/bW95/2dqdP9iZW7/bG51/2ptd/9rbnj/ -bnF4/2Zpc/9naW//ZGdx/2Rncf9kZ3H/Zmhu/2ptd/9kZ3H/ZGdx/2BjbP9maG7/Z2p0/2Zpc/9nanT/ -Z2p0/2dqdP9ucXv/bG51/3d6g/9qbXf/am13/2xudf9sbnX/cHJ5/3V3ff9ucHf/bnB3/25xe/9wcnn/ -cHN9/3d6g/9zdXz/cHN9/3Byef9wc33/c3Z//3N1fP9sb3n/cHJ5/3d6g/91eIH/bnB3/3d5f/9ucXv/ -bnB3/25xe/9ucXv/cHN9/3N2f/93eoP/dXiB/3d6g/9wc33/cHN9/2xvef94eX3/c3V8/25wd/91d33/ -c3V8/3N2f/91eIH/c3Z//3Bzff9qbXf/Z2p0/2xvef9ucXv/bG95/25wd/9qbXf/bG51/2tud/9rbXT/ -bG95/3V3ff9wc33/dHZ8/2tueP9sbnb/Z2p0/2ttdf9oanP/amxz/2ptd/9maG7/bG95/2dqdP9sbnX/ -amx0/21weP9rbXb/bnF6/2xvef9zdXz/b3J8/25xe/9zdn//eXuB/36Biv9wcnn/cHN9/3F0fP9ydX3/ -bnF6/2ptd/9laHL/bW92/3N1fP9xdH3/b3F4/3Bydv9tcHr/dXd9/3h5ff9vcXj/eHqB/25xev9ucHf/ -am11/3Fzev91d33/cHJ5/29xdf9ucHf/bnF7/2dqdP9rbnj/b3F4/3Bze/9rbnf/b3J8/3Z5gv9xc3v/ -a253/25wd/9ucHf/d3qD/29xd/9sb3n/bXB6/3J0e/9tcHr/am13/2ptd/95e4H/cHJ5/2psc/9ucXv/ -cHJ5/25wd/9sbnX/bnB3/2dqcf9zdXz/c3V8/25xe/9qbXf/am13/2Zpc/9ucXv/YmVu/2Zpc/9kZ3H/ -am13/11gaP9rbnj/bG93/21wd/9tcHr/am13/2xvef9sbnX/a253/3R2fP9tb3P/dXd+/2lsdv9pbHX/ -Z2p0/25wd/9qbHP/Zmlz/3N1fP91d33/am13/25wd/9qbXf/bG51/2xvef9zdn//amxz/2xudf9qbHP/ -bnB3/21vc/93eX//am13/3N1fP9wc33/bG95/2ptd/9qbXf/bG95/25xe/9maXP/bG51/2xudf9ucXv/ -bG95/2psc/9sbnX/bnB3/3Byef91d33/bnB3/29xd/9zdXz/cnR7/2tudv9sb3n/bnF7/25xe/9qbXf/ -c3V8/3J0e/9wc3v/b3F4/3N1fP9wc33/e32D/3t9g/9+gYr/eXuB/3N1fP9sbnX/bnB3/2xudf9wcnn/ -bnF7/3Bzff9qbXf/bG95/2Zpc/9sb3n/bnF7/3R2e/9ucXn/bG51/3Fzev9ucHf/Z2p0/25xe/9zdn// -b3J8/3Byev9rbXT/aGtx/2dqcf9kZ3H/ZGdx/2Zobv9nanT/am13/2Zpc/9kZ3H/Zmhu/2xvef9nanT/ -bG51/2Zpc/9qbXf/bnF7/2ptd/93eoP/bnF7/2xudf9ucHf/c3V8/3N1fP9zdXz/bnF7/3N2f/9zdn// -c3Z//3N1fP93eoP/bnF7/25xe/9sb3n/bnF7/2xvef9sb3n/Z2px/2xudf9zdXz/cHJ5/2xudf9zdXz/ -bG51/2ptd/9sb3n/bG51/2ptd/9qbXf/am13/2dqdP9sb3n/ZGdx/2dqcf9nanH/bnB3/2ptd/9maXP/ -bG95/2ptd/9qbXf/bnF7/2ptd/9qbXf/Z2p0/2Zpc/9qbXf/bG95/2xudf9sb3n/bnB3/25wd/9ucXv/ -bnB3/3V3ff91eIH/dXd9/3Z4fP9ucHf/bG92/2hrcv9xc3r/a252/25wdv9ydX7/cHJ5/3Bzff9sb3n/ -b3J5/2tudv9xc3r/bG51/3V3e/9ydHv/c3V8/3N1fP9ucHf/bW92/3V3ff91eIH/amxz/2xudf9tb3b/ -b3F2/25weP9tb3b/amxz/29xdf91d33/c3V8/2xvef9wcnn/bnF7/3l7gf95e4H/cHJ5/3d5f/9ucHf/ -bnB1/2lsdf9ucHr/bG95/25xe/9qbXf/am13/3N1fP9sbnX/bW93/2xvef9vcXj/ZWhy/2ptd/90dnz/ -bnB1/2psc/9sbnX/bG51/3d5f/9tb3T/bW92/21vdv9rbnf/a254/2xudf9sbnX/eXyG/3Byef9sbnX/ -bnB3/25wd/9sbnX/bG95/2xvef9nanH/dXd9/3Z4fP91d33/cHJ5/3Byef9ucHf/c3Z//2psc/9zdXz/ -cHJ5/3N1fP9maG7/cHJ5/3Byev9wcnr/b3J7/2xudf9wcnn/bG51/2tud/9ydHv/bG52/3d5f/9tcHj/ -cHN8/3N2fv91d33/bnB3/2xvef93eX//dXiB/25wd/9sbnX/bG51/25wd/9zdXz/d3l//2ptd/9qbXf/ -bnB3/3Byef9vcXX/dnh8/21vc/9zdXz/cHN9/2xvef9qbXf/bG51/2xudf9qbXf/Zmlz/2xudf9qbXf/ -bG95/2xudf9maXP/bG51/2ptd/9ucHf/d3l//2ptd/9tb3b/cHN9/3F0fP9xc3r/cnV+/3d6g/9zdn// -cHN9/3R3gP90dn7/b3J6/25wd/9ucXv/cHJ5/3l7gf93eX//e36H/3d5f/91d33/bG51/25wd/9sb3n/ -cHN9/3N1fP9zdXz/bnB3/3V3ff9sbnX/cHJ5/3Byef9wc3r/aWx2/2VocP9kZ3H/ZGdx/11gav9kZ3H/ -Zmlz/2dqc/9rbXb/ZWhy/2ZpcP9nanH/bG95/2ptd/9sbnX/c3V8/3Byef9zdXz/bG51/2psc/9qbXf/ -Z2px/2psc/9maXP/Z2p0/2xvef9sbnX/eXuB/3Byef9ucHf/bG51/3Byef9wcnn/bnB3/2xudf9ucHf/ -bG95/2xudf9nanH/bG95/2dqcf9nanT/ZGdx/2Zpc/9sbnX/bG51/2Rncf9nanT/bnF7/2xvef9qbHP/ -dXd9/2ptd/9nanH/bG95/2dqcf9ucXv/bG95/25xe/9wcnn/bnF7/2xvef9qbXf/bnF7/3V3ff91d33/ -b3F1/3Byef9wcnn/bnB3/25xe/9sbnX/am13/2psc/9qbHP/bnB3/25wd/9sbnX/bG51/3N1fP9sbnX/ -bG95/21vc/9zdXz/dXd9/25xe/9wc33/am13/2dqdP9dYGn/aWx1/2ptdf9sbnP/b3F4/2xudf9ucXv/ -bG51/29xeP9rbXX/bnF5/21wef9ydHv/dHZ8/3R2ff9wcnn/bW92/2xvef9wc33/d3qD/2xudf9rbXX/ -a253/3Fzev9vcnv/b3F4/2xvef9vcXX/c3V8/3Byef9ucHf/bW9z/2xudf91d33/c3V8/21vc/94eX3/ -b3F1/25wdf9qbHL/cnR7/3N1fP9zdn//bnF7/25wd/9zdn//bG95/3Byef9vcnr/cXN5/21vdv9ydHv/ -dniB/3J0e/9wc3z/cHN9/3N1fP99gIn/b3F4/21wef9ucHf/bnB3/25wd/9nanT/bG51/3l7gf9ucXv/ -bG51/25wd/9ucHf/Z2p0/2ptd/9qbXf/ZGdx/2xvef9ucXv/Zmlz/2Zpc/9nanT/Zmlz/2xvef9qbXf/ -c3Z//3V3ff91d33/amxz/3Fze/93eX7/dXiC/3N2f/9wc33/eXuB/3J0e/9vcnz/cXR+/2ttd/91eH7/ -bG92/3Byef90dnz/dXd9/2xvef9nanT/cHJ5/3V3ff9sb3n/am13/2ptd/9wcnn/cHJ5/3l7gf9wcnn/ -bG51/21vc/9sb3n/b3F1/3h5ff9sbnX/c3V8/3V3ff9wcnn/bnB3/25wd/9ucHf/bnB3/2xudf9tb3P/ -bG51/25wd/9sbnX/Z2p0/2xudf9qbHP/am13/3N1fP9qbXf/aGty/2hrdf9tb3b/Z2py/2lrcv9sb3n/ -Z2p0/2Zobv9rbnj/bG95/2dqdP9jZm//ZWhy/2Rncf9sb3n/Zmlz/3Bzff9zdXz/dXiB/3Byef93eoP/ -cHN9/3l8hv97fYP/e32D/3V3ff99foH/dXd9/3l8hv95fIb/e3yB/3l8g/9ydH3/b3J7/25wd/9qbXf/ -bnB3/3Fzev92eH7/eXp//3p8gv92eH7/dXd9/3d6g/93eoP/dXd9/3d6g/9zdn//d3qD/3N1fP9wcnn/ -c3Z//3N1fP9zdn//c3V8/3Bzff91eIH/bnB3/3d6g/9wc33/bnF7/3Byef9wc33/dXd9/2ptd/9sb3n/ -bW9z/25wd/9ucHf/bnB3/3h5ff9ucHf/dXd9/2xvef9ucHf/bW9z/25wd/9nanH/bG51/3Z4fP91d33/ -b3F1/3Z4fP9vcXX/bW9z/3N1fP9qbXf/cHN9/2xvef9wcnn/dXd9/3Byef9sb3n/amxz/25xe/9wc33/ -bnF7/2psc/9qbXf/Z2p0/2Zobv9maXP/ZGdx/2dqcf9kZ3H/Zmlz/2psc/9qbXf/amxz/2psc/9zdXz/ -bnB3/2xudf9sbnX/bnF7/3N1fP9zdXz/dXd9/3N1fP9sbnX/ZWdt/2psdv9rbnj/a252/29yfP9sb3n/ -cHN9/2xvef9wcnn/aWxz/3Byef9tcHn/dHZ8/3R2fP9zdXz/cXN5/21wef9vcnv/dXiB/3t+h/9zdXz/ -b3F4/21wef9xc3r/am12/2hrdf9maXP/am13/25xe/9sb3n/bG51/2ptd/9qbHP/cHN9/3Bzff9sbnX/ -c3V8/21vdv9wcXf/c3V8/3t9g/97fYP/fX6B/3l7gf92eHz/foCG/3h5ff91d37/dHZ8/3Fzd/9ucHj/ -cXN6/3d6gv9vcnv/bG95/3Bzff9wc33/en2G/3N1fP9xdH3/cXN5/25xeP9xc3n/bG51/29xdf91eIH/ -bnF7/2dqdP9sbnX/bnB3/2psc/9sb3n/bnF7/2Zpc/9sb3n/c3V8/2xvef9wcnn/dXd9/2xudf9zdXz/ -Z2p0/3N2f/9wc33/cHN9/2ptd/9wc33/dHd//3N0e/9tcHT/bnB3/3N1fP9qbHP/bG95/3N1fv9rbXf/ -dXd9/21vdf9zdXz/dXd8/3N1fP9sb3n/Z2p0/3V3ff91d33/bnB3/2xvef9sbnX/bnB3/25wd/91d33/ -bW9z/2xudf9tb3P/bW9z/2ptd/91d33/bG51/3N1fP91d33/bnB3/25wd/9ucHf/bnF7/3Bzff9ucHf/ -bnB3/2xvef9wc33/bnB3/2dqdP9sb3n/bnB3/3N1fP91d33/bnB3/21vdP9wcnr/cXN5/21vdf9ucHf/ -c3Z//3N1fP9sb3n/cnR7/3N1e/9rbXT/aWx2/2xudf9nanT/c3V8/2xvef91d33/dXd9/2Rncf9kZ3H/ -Zmlz/2Jlbv9nanT/Z2p0/2Zpc/9kZ3H/Zmlz/2Rncf9qbXf/bG95/25wev9xdHz/bW93/29xef9sbnX/ -am13/25wd/9vcXn/cnR7/3ByeP9ydHv/bnB3/2xvef9zdn//bG95/25wd/9wcnn/cHJ5/3Bzff9qbXf/ -bW9z/25wd/9tb3P/bnB3/25wd/9sbnX/cHJ5/21vc/91eIH/cHN9/3N2f/93eoP/d3qD/3d5f/9wc33/ -cHJ5/21vc/9ucHf/cHJ5/21vc/91d33/b3F1/3V3ff9sbnX/bnB3/29xdf9sbnX/Zmhu/2xudf91d33/ -c3V8/29xdf93eX//b3F1/2xudf9ucXv/Z2p0/3Bzff9sb3n/bG95/25xe/9ucXv/bG95/2psc/9wc33/ -cHN9/3N1fP9sbnX/cHJ5/3N1fP9sb3n/bnF7/25wd/9ucHf/bnB3/2xudf9vcXX/bnB3/2xvef9sbnX/ -d3qD/3Bzff9zdn//c3Z//3d6g/95e4H/dXiB/3l7gf91eIH/am13/2ptd/9xc3r/bnB2/2xudf9ucHf/ -bW9z/3V3ff9ucHf/cHJ5/2lsc/9ucXv/b3F6/3V3ff90dnz/b3J7/3Byev9vcXj/b3F4/3V3ff93eX// -bG51/2hrdf9rbnj/bXB4/2Zpc/9rbXT/ZGdx/2dqdP9wcnn/am13/2dqcf9nanT/ZGdx/2Zpc/9maXP/ -Zmhu/2dqdP9jZm//aGpx/2hqcv9wcnr/cHJ5/3Byef9ucHf/bnB3/2xvef9ucHf/bW91/25xe/9qbXb/ -Zmlz/2lrdP9wcnr/bXB0/2dqcf9sbnX/bW9z/3Z5gv9tb3b/a254/21vd/9tb3b/c3V8/2xudf9vcXX/ -d3qD/3V3ff9ucHf/cHJ5/3Bzff9qbXf/bnF7/25wd/9qbHP/c3V8/3Z4fP9ucHf/cHN9/3Z4fP9ucHf/ -bnB3/2BjbP9qbXf/Z2p0/2ptd/9iZW7/am13/21wev9xdHr/bnB4/25wd/91d33/bXB3/29xef9ydX7/ -a213/3h6fv9vcXf/cnV9/3h6gP93eoP/c3Z//25xe/9+gIb/foGK/3l7gf97fYP/d3l//3t9g/93eoP/ -foGK/3V4gf93eoP/c3Z//3V4gf9zdn//eXyG/3N2f/95e4H/e32D/3N1fP9wcnn/cHJ5/25xe/9zdn// -c3V8/25wd/9ucHf/c3Z//3Byef9qbXf/b3F1/29xdf9wc33/dXiB/3Bzff9wcnn/bXB6/3Fze/9ucXr/ -bnB3/3N2f/9ucXv/bG95/3BzfP9xdH3/bnF5/2xvef9ucHf/cHJ5/3h5ff9wcnn/foCG/3t9g/9qbXf/ -am13/3Bzff9qbHP/bG95/2xvef9nanT/amxz/2xvef9maXP/bnF7/3Bzff9wc3z/cXR+/25xeP9vcnz/ -c3V8/2ptd/9qbXf/b3F5/3J0ev9vcXf/am13/2dpc/9nanT/cHN9/2xudf9sbnX/cHN9/25xe/9wc33/ -Zmlz/2xudf9qbXf/amxz/2dqcf9kZ3H/Zmhu/2dqcf9qbHP/cHJ5/2ptd/9qbHP/am13/2Zpc/9sb3n/ -amxz/2ptd/9nanT/amxz/25xe/9qbXf/c3V8/2psc/9sb3n/Zmlz/2psc/9qbHP/amxz/2Jlbv9maXP/ -bnF7/2xvef9sbnX/dXd9/2psc/9sbnX/cHJ5/2xudf91d33/bnB3/2xvef92eHz/bnB3/25wd/9tb3P/ -eHl9/3N1fP9zdXz/cHJ5/3N1fP9zdXz/bnF7/25xe/9sb3n/bW9z/2xudf9ucHf/bG95/25wd/9wcnn/ -b3F1/3Byef9qbXf/bG95/2ptd/9wc33/cHN9/2xvef9wc33/bG95/2Jlbv9hZG3/bG51/21wef9qbXf/ -bnB6/3Byef91eIH/bnB3/2xvef9naXP/cHJ5/29xef91d37/dHZ9/25xev9vcXr/bnF4/3Byef91d33/ -d3l//25wd/9vcXj/cHJ5/3F0e/9ucHf/b3F4/25wd/9wcnn/dXd9/25wd/9qbHP/bnF7/3Byef9sb3n/ -bnF7/2xudf9wc33/b3F1/21vdv9sb3b/dXd9/25wd/9zdXz/bnB3/2xudf9sbnX/bW9z/2hrdP9wc3v/ -bXB6/2ptdP9qbXT/c3V8/21vdf9iZW7/ZGdx/2dqcf9ydX7/a211/2tueP9rbnj/bXB3/3N1fP9sbnX/ -bnB3/3t9g/91d33/bnB3/25xe/9zdn//am13/3Bzff9sb3n/bG95/3Bzff91d33/cHJ5/3N1fP91d33/ -bG51/3Byef9qbXf/dXiB/3N1fP9zdn//bnB3/3N2f/9xdH7/dnh+/3F0fv9wcnn/dXd9/2xudf9vcXf/ -dHZ8/21veP91d37/bW92/21wev90dnz/c3V8/21vc/9ucHf/dXd9/3d5f/9ucHf/bnB3/2xudf9sb3n/ -bnB3/3V4gf9qbXf/bnF7/25wd/9sbnX/bnB3/3V3ff9vcXX/dXd9/3V3ff9ucHf/bnB3/2xvef9wc33/ -cHN9/3Byef9wcnn/cHN9/3V4gf9zdn//bnF7/3N2f/91d33/eXyG/36Biv91eIH/dHeA/3Fze/9wc3v/ -a252/2hrcv9maXP/YmVu/2Zobv9nanP/bG94/2xudv9pbHb/cHJ5/2ptd/91d33/bG95/36Ahv97fYP/ -am13/2xudf91d33/amxz/3V3ff9wc33/bG95/2xudf9zdn//Z2p0/3N2f/91d33/cnR7/3Byef9ucHf/ -cHJ5/2xvef9maXP/amxz/29xef9vcXj/cHJ3/25wev9qbXf/Zmlz/3Bzff9sbnX/am13/3Bzff9ucXv/ -cHN9/2ptd/9sbnX/bG51/2psc/9qbHP/Zmlz/2dqcf9nanH/bG51/3V3ff9wc33/bG51/3N1fP9sb3n/ -c3V8/2xudf9wcnn/am13/21vc/9zdn//cHN9/3d5f/9vcXX/dXd9/2psc/9ucXv/bnF7/25xe/9nanH/ -bG95/3V4gf97fYP/c3V8/3l8hv9wcnn/cHN9/3N2f/9ucHf/dXiB/3N2f/9wc33/eXuB/3Bzff9ucXv/ -bG95/3Z4fP9wcnn/c3V8/3Byef91d33/cHJ5/25wd/9qbXf/am13/21vc/9qbXf/am13/2xvef9sbnX/ -cHJ5/25wd/9wcnn/cHJ5/25wd/9wc33/dXd9/3l7gf91d33/dXd9/3Bzff9sb3n/am13/3Bydv9tb3b/ -am13/2ptd/9sbnX/dXd9/25wd/9wcnn/Z2px/3Byef9ucHn/dHd//3d4ff9vcXj/cXN5/2tud/9sb3n/ -c3V8/3V3ff9sbnX/aGt1/21wev9tb3j/Zmlz/2hrdf9maXP/cHN9/3Bzff9qbXf/Z2p0/2xvef9ucXv/ -bG51/25xe/9qbHP/bG95/2xudf9ucXr/aWx0/3J0e/9sbnX/cHN9/25xe/9nanT/bG95/2xudf9sbnX/ -c3V9/3R2fv9tcHr/cHJ3/3R2fP9wcnn/am13/2dqdP9ucHf/dnmC/25xe/9ucXv/bnF7/25xe/91d33/ -bnB3/29xdf93eX//cHN9/2ptd/9qbXf/cHN9/2Rncf9sbnX/Z2p0/2Rncf9nanT/bG95/2Zpc/9maXP/ -bG95/2dqcf9qbXf/YGNs/2xvef9sb3n/bG95/2psc/9sbnX/a212/3N1e/9zdXz/b3F1/3d5f/9tcHr/ -cXR8/3Z4gP9ucXr/dnh//25wdf9ucHf/dXd9/2xvef9qbXf/bG51/3V3ff93eX//bG95/3Byef9ucHf/ -bG95/25wd/97fYP/b3F1/3Byef9wcnn/bG51/2xudf93eX//am13/3Bzff9wc33/bW9z/2ptd/9nanT/ -am13/2xvef9sbnX/Z2p0/2xudf9nanT/amxz/11gav9sbnX/Z2px/2ptd/9zdXz/bG95/2xvef9sbnb/ -cHJ6/21wev9sb3n/bnF7/2xvef9ucXv/dHeA/3Z4f/9xdH3/am13/3Bzff9zdXz/e32D/3V4gf+Fh43/ -f4KM/25xe/9sb3n/d3l//2xvef93eX//cHN9/3Bzff9zdXz/dXiB/2xvef94eoH/dnh+/25xev9ucXr/ -aGp0/2dqcf9nanT/XWBq/2Rncf9qbXb/bG93/21vd/9ucXj/bG51/2psc/9zdXz/Z2p0/2xvef9sb3n/ -bnB3/25wd/9qbXf/am13/2psc/9sb3n/bG51/2ptd/9sbnX/am13/2xudf93eX//eHl9/3Byef91eIH/ -c3Z//3d5f/9ucHf/c3Z//25wd/9ucHf/c3Z//25wd/93eX//bnB3/3Z4fP9nanH/bnB3/29xdf9ucHf/ -Z2px/2psc/91d33/c3V8/2psc/91d33/amxz/2psc/9sb3n/ZGdx/2dqdP9maXP/Zmlz/25wd/9qbXf/ -Z2p0/2ptd/91d33/bnF7/25xe/9tb3P/dXd9/3Bzff9ucXv/cHJ5/25xe/9ucHf/bnB3/3Byef9zdn// -c3Z//3V4gf9wcnn/eXuB/3l8hv91eIH/e32D/3t+h/97fof/eXuB/3l7gf93eoP/bnF7/2ptd/9xc3r/ -cnR7/2xvd/9tb3f/bnB3/3N1fP9sb3n/cHN9/2dqdP9wc3v/cXN8/3V3ff92eHz/bnB6/3Bye/9tcHj/ -bnB3/3V3ff94eX3/b3F1/21vdv9tcHr/bnF5/2tueP9qbXf/Z2p0/3N1fP9sb3n/amxz/2dqdP9sb3n/ -bG95/2psc/9nanT/Z2px/2xvef9maG7/Zmly/2Rncf9ucXr/bG51/3Bzff9ucXv/Z2p0/25xe/9sbnX/ -Z2p0/2hrdf9oa3X/ZWhv/2Rmbv9maXP/a254/2dqdP9iZW7/Z2px/29xeP9maXP/aWx0/2ptd/9rbnj/ -cHN9/2ptd/9qbXf/d3qD/3N1fP9sbnX/bnB3/3Byef9sb3n/bnF7/3Byef9ucHf/bG95/3V3ff9sb3n/ -bnB3/3Z4fP9vcXX/dXd9/2BjbP9sb3n/cHN9/2xvef9tb3P/b3F4/21wev9xdH3/bnF7/2xvef93eX// -bG95/2xud/90dnz/bG94/3Bzff9rbnb/bG95/3V3fP9ucHf/bnB3/2psc/92eHz/dXd9/25xe/9ucXv/ -bnF7/3Byef9ucXv/f4GH/3Byef9wc33/c3Z//25xe/9ucXv/d3qD/2xvef9wc33/cHN9/25wd/9ucXv/ -bnF7/3V4gf91eIH/bnF7/25wd/9ucHf/cHJ5/21vc/9iZW7/amxz/2psc/9qbXf/cHN9/2dqdP9ucXv/ -bG51/29xev9rbnj/cnV+/3Bzff9ucXv/bG95/3J1fv91dnv/cHN6/2hrdf9oa3X/Z2p0/3V3ff9ucHf/ -fX6B/3d5f/9wcnn/bnF7/3Z4fP9ucHf/dnh8/2xvef9ucXv/Z2p0/2ptd/9kZ3H/bnF7/3Byef9pa3T/ -bG95/2dqc/9sbnX/am13/2dqcf9qbHP/bnB3/21weP9tb3f/cnR7/25wd/9nanT/cHN9/2Zpc/9qbHP/ -amxz/2ptd/9ucXv/Z2p0/2xvef9qbXf/bG95/2xudf9nanT/Z2p0/2xudf9maXP/bnB3/2xvef9maG7/ -am13/2xvef9ucXv/Zmlz/2dqdP9maG7/Zmhu/2ptd/9nanH/c3V8/2psc/9zdXz/ZGdx/2ptd/9qbHP/ -amxz/2Jlbv9maXP/bnF7/3N1fP9nanH/cHN9/2psc/9sbnX/bG95/2psc/9sb3n/am13/2xvef92eHz/ -cHJ5/3Byef9ucHf/dXd9/25wd/9wcnn/bG51/3N1fP9wcnn/cHJ5/29xdf9vcXX/bG51/25wd/9sb3n/ -bnF7/2xvef9ucHf/bG51/25wd/9zdXz/bG51/3Bzff93eX//d3l//3V4gf9wc33/c3Z//2dqdP9nanT/ -b3J7/21wef9sb3f/bW91/25wd/9zdXz/bG95/3N1fP9qbHP/cHJ5/3Bzff91d37/eHl+/3V3ff9ydHn/ -bnF6/3Byef91eIH/eXuB/3N1fP9xc3r/cnV+/25wef9ucHf/bG51/2xudf9wc33/dXd9/25wd/9sbnX/ -c3V8/3V3ff9tb3P/bnB3/21vc/9ucXv/am13/21vdf9qbHH/cXN6/21vc/92eHz/c3V8/29xdf9ucXv/ -am13/2xvef9xdHv/cHN8/21vdv9tb3j/b3J8/3R3gP9qbXf/am13/25wd/91d3v/cXN3/3Byd/9tb3j/ -bG95/3h5ff9ucHf/bnB3/3l7gf9zdXz/amxz/2ptd/9wc33/Z2p0/2ptd/9qbXf/Zmlz/2xudf9wc33/ -bG51/2psc/9wc33/amxz/25xe/9sb3n/dXiB/3t9g/91eIH/dXd9/3h6gP91eH//dnh+/25xev9qbXf/ -cHN9/2hrc/9sb3f/dnh9/21wev90doD/cnV9/3V4gf96fIL/d3qD/3Bzff9wcnn/eXyG/3t+h/9wc33/ -bnF7/25wd/9wc33/cHN9/3l8hv9vcXX/c3V8/25wd/9tb3P/bG51/3V3ff9sbnX/cHN9/3N2f/9ucHf/ -bnF7/2ptd/9wc33/cHN9/3Bzff9sb3n/bnF7/3Bzff9vcXX/ZGZs/29xdf9ucHf/cHJ5/3V3ff9ucHf/ -dHZ9/21vdv9xc3r/cXN7/3Byef9wc33/cHN9/29ye/9ydX7/cnR7/21vdv9sbnX/cHJ5/2dqcf94eX3/ -bG95/3t9g/91d33/cHJ5/25wd/92eH7/bnB3/3h5ff9wc33/cnV+/21wd/9rbnj/bG95/29yfP91d33/ -bnB4/21wef9rbXf/bG51/2ptd/9kZ3H/Z2p0/2xveP9tcHj/a253/3Fze/9sbnX/Z2px/3R2fP9qbHP/ -bG51/25wd/9wc33/cHN9/2xudf9wc33/bG51/2ptd/9sbnX/Z2px/2xudf9qbXf/bnB3/3Z4fP9wc33/ -bG95/3V3ff9zdn//c3Z//25wd/9ucXv/bnB3/25wd/9zdn//bG95/3V4gf9ucHf/dXd9/2ptd/9zdn// -bnB3/3Byef9nanT/bnB3/3V4gf93eoP/bG95/3V3ff9tb3P/bG51/3Byef9tb3P/bnF7/25xe/9ucHf/ -dnh8/3N1fP9qbXf/amxz/3Bzff9ucXv/c3V8/2xudf9zdXz/bG95/2xudf9qbHP/am13/2ptd/9qbXf/ -am13/25wd/9ucHf/c3V8/2xvef9sbnX/dXd9/25xe/91eIH/eXyG/3l8hv93eoP/c3Z//3V4gf9ucXv/ -bnF7/3V4gf9wcnr/cHJ3/3BzeP9vcXX/dXd9/25wd/9wcnn/bG51/25weP91d3//dnmA/3h7hf9zdoD/ -dnh+/29yfP9ucXv/c3Z//3d5f/9wcnn/bnB0/3Fze/9ucHj/bnB4/29xdf9vcXX/c3V8/3N1fP9ucHf/ -amxz/3N2f/91d33/bG51/3Byef9sb3n/bG95/2xudf9sbnX/ZGdv/3Fzff9qbHP/dXd9/25xe/9nanT/ -bG95/2ptd/9qbXf/bXB4/21wef9sb3j/am1z/25wd/9wc33/ZGdx/2dqcf9ucHf/dnd8/29xef9ucHn/ -bG94/25wd/94eX3/bnB3/3Bzff97fof/dXd9/2psc/9sbnX/dXd9/2xudf9sbnX/bnB3/2xudf9sbnX/ -dnh8/25wd/9ucHf/dXd9/25wd/9zdXz/YGNs/2xudf9sb3n/amxz/2psc/9rbnj/bG51/3Fzef9wcnn/ -bG95/3l7gf9ucHf/bnB5/3d5gf9vcXj/c3Z//2xvdP9pbHX/am13/2dqdP9maG7/Zmlz/3Byef9zdXz/ -bG95/2xvef9tb3P/am13/2ptd/9zdn//am13/2xvef9sb3n/bG51/21vc/91d33/am13/2xvef9zdXz/ -bG51/2xvef9maXP/bnF7/25xe/9ucXv/am13/2xudf9nanT/Zmhu/2BjbP9qbHP/am13/2ptd/9ucXv/ -bnB3/3V3ff9tb3b/b3F5/25weP9vcXj/bnB3/3ByeP9ucHb/cHJ5/29yfP9vcnz/bG54/29ye/9qbXf/ -dXiB/3N2f/9/gYf/eXyG/3h6gP93eX//fH6E/3J0e/95fIX/c3Z//3R3f/9wcnj/bXB5/25wd/9zdn// -dHeB/3F0fP9xdH7/bnB3/3Byef9zdXz/bG95/2xvef90dn//cnV//29yfP91d33/cHJ5/21vdv91d33/ -bnB3/3Byef9vcXv/dnh9/3V3ff9ucXr/dnl//3N1fP9ydX//bG95/2xveP9vcXj/cXR9/29ye/94eoH/ -d3qD/3N2f/96fIL/enyC/3t9g/91d3z/dnh//3Z4fv9zdn//enyC/3V3e/9+gIb/enyC/31+gv9zdXz/ -eXuB/3h5ff91d33/cHJ5/3d4ff96fIP/gIKJ/3V4gf94eoH/d3mC/3V3ff93eYL/cHJ5/3Z5gv91eID/ -cHN9/3p8gv91eID/cHN9/3N1fP93eoP/c3Z+/3Bzff9sb3n/c3Z//3Bzff9vcXX/bG51/25wd/9qbXf/ -Z2pz/2xudf9wcnn/bnB3/3N1fP9sbnX/bG51/3V3ff9sbnX/cHJ5/3V3ff93eX//c3Z//25xe/9wc33/ -bG95/2xudf9wcnn/b3F2/2xudf9rbnj/bG51/25xe/9qbXf/bG51/2Jlbv9pa3X/b3J6/3J1ev91d37/ -cnV+/3Byef9sb3n/bG92/3Bzff91d33/Z2p0/2lsdf9tcHr/bG93/21wef9ucHf/b3F1/3V3ff91d33/ -cHN9/2xvef91eIH/dXd9/25wd/9wcnn/cHJ5/3Byef9ucHf/cHJ5/2lrc/92eYD/bG95/3l7gf91d33/ -bnB3/25xe/9sb3n/bG95/3J0e/9xc3j/bnF5/2lsdP9sbnX/bnF7/2Jlbv9maXP/bG51/3J0e/9sbnf/ -a252/25wd/9ucHf/dnh8/2xudf9ucHf/dXiB/3Bzff9nanT/bnB3/3Z4fP9sbnX/bG51/25wd/9qbXf/ -am13/3Bzff9qbXf/am13/3V4gf9tb3P/cHJ5/2dqdP9sb3n/c3V8/3Byef9ucHf/dHeA/3Bzff91d3// -dHeB/2xvef95fIb/cHJ5/25xev93eYD/bW92/3R3f/9vcXj/bW92/3N1fP9wcnn/bnB3/2xvef91d33/ -dnh8/3V3ff9wcnn/bG95/3Bzff9zdn//eXyG/3Byef9ucHf/bnB3/25wd/9vcXX/dnh8/25wd/9zdXz/ -cHJ5/2xudf9wcnn/amxz/3Bzff9zdn//dXd9/25wd/9ucHf/cHJ5/2psc/9kZ3H/bG51/2xvef9nanT/ -cHN9/2dqdP9sb3n/aGt1/25weP9tcHf/cHN7/21vdv9ydXz/cHN7/3ByeP9ydHz/am12/2dqdP9rbXT/ -ZGdx/2xvef9qbXf/c3Z//3N1fP9xdHz/b3F4/3Z4fv9ucHf/dnh9/29xeP9wcnv/bG51/2lsdP9sbnT/ -bG93/3Byev9tb3b/cnR7/2xudf9ucHf/bG51/2dqcf9maG//bXB3/25wd/9tb3X/cnR6/29xev9rbnb/ -cnR5/3J0ev9wcnv/cHN8/3N1fP92eID/cHN9/3J1fP9ucHj/cXR9/29xeP9vcXj/bnB4/29yef9ucHj/ -d3h9/3BzfP9xc3r/dXd+/3J1fv91eID/bnF6/3N2gP9ucHf/b3F5/3J0e/9sbnb/dHZ7/2xvef9zdXz/ -am12/3F0ff9sb3j/bG94/2Zobf9rbXT/cXN6/3l7gf9vcXb/cnV+/3Bze/9tcHn/cXN9/25wd/9wcnz/ -cHJ5/2xvdv91d37/cHJ8/21vc/9ucHf/dHZ8/3J0e/9xdH3/bnB3/3J1fv9ydX3/bnB3/25wd/9ucHj/ -bW93/2ttdP9sbnX/bG95/2xudf9pbHb/Zmlz/25xe/95e4H/c3V8/3V4gf97fof/e36H/3d5f/9wc33/ -c3Z//25wd/9qbXf/dXd9/29xeP9sb3f/b3F3/25wd/91d33/bnF7/25xe/9sb3n/b3J7/3J1f/90d37/ -dnh//3N2f/9ydH3/b3J7/25wd/9wc33/dXiB/25wd/9tcHr/dXd+/25xef9sb3n/bnB3/25wd/93eX// -dnh8/2xvef9qbXf/dXd9/3N1fP9ucHf/c3Z//3Bzff9wc33/cnV+/3N2f/9pbHT/dniA/25wd/91d33/ -bnF7/21vc/9tb3P/bG51/2tueP9xdH7/cXN8/3Bze/9rbnj/a254/3N1fP9nanH/bG51/21vc/9zdnz/ -b3J6/29xdv9ucHT/bnB3/3d5f/9vcXX/cHJ5/3V4gf9wc33/bG95/2xvef91d33/bG95/3Byef9wcnn/ -bnB3/29xdf91d33/b3F1/25wd/97fYP/bnB3/3Byef9ucXv/c3Z//3d6g/9zdn//cHN9/3N2f/9wcnv/ -cXR8/25xe/9kZ3H/dXiB/2psc/9laHL/c3V8/2hrdP90dn3/bnF5/2xvef9vcnz/bnF7/25wd/9sbnX/ -bnF7/25xe/9zdXz/cHJ5/25wd/9wcnn/bnB3/3t+h/9sb3n/bnF7/3V4gf9sb3n/bnB3/3d5f/9ucHf/ -dXiB/3N2f/9ucXv/cHN9/2ptd/9ucXv/c3V8/3V3ff9ucHf/cHJ5/25wd/9ucHf/bG51/2ptd/9ucXv/ -cHJ5/3V3ff9sb3n/bW95/2hrdf9ucHf/bG52/21vd/9qbHP/bnB2/3J0e/9oanL/bG53/2hrcv9iZW7/ -a210/2BjbP9nanT/am13/3V3ff9zdXz/cHN9/21vd/9wc33/a254/3h6gP9rbnf/bW95/2hrdf9iZW// -aWxz/2lsdP9tb3X/aWx2/25xe/9qbXf/bG51/2Zpc/9iZW7/YmVu/2ptd/9ucHf/bW94/29xeP9tcHr/ -bnF7/25xef91d33/cnR7/3F0e/9wc3z/dHeB/3R3gP9ydHr/bnB2/3R2fP91d33/cXN7/3Fze/9zdn7/ -b3J6/3J1fP9ydX3/dHZ9/3V3ff9xdH7/cnV//21weP9ydHz/bW92/29xeP9sb3f/bG51/25xef9sb3f/ -cHN7/2ptdv9ucHn/a252/29xeP9kZ3H/aGt1/25xe/91eH//bG51/21wev9tb3b/bG53/29yfP9pbHb/ -aWx2/2xud/9rbXX/cXR7/21wev9oa3P/a212/29yfP9vcXr/c3aA/25xe/9xdH7/bnB5/2xvdv9wcnr/ -bnB4/2xvef9ucHj/bnB1/3Byef9vcXX/bnB4/2lsdf9wcnn/c3V8/2ptd/9sb3n/dXd9/3V3ff92eHz/ -dXd9/25xe/9ucHf/bG95/3V4gf9zdXz/bW94/25xe/9ucHX/c3V8/25wd/9sb3n/Zmlz/21wdP9zdn3/ -c3V7/3Z3fP9zdXz/cXN5/25wdv9sb3n/cHJ5/3V3ff9ucHf/b3F4/3R2e/9tb3b/a253/2hqdP9sbnX/ -bnF7/2ptd/9nanH/ZGdx/25xe/9maXP/YmVu/2Rncf9nanH/Zmlz/2ptd/9oanT/Y2Zu/29ye/9nanT/ -cHJ5/2dqdP9kZ3H/Zmhu/2Zobv9jZm//bG95/25xe/9sb3n/amxz/2ttdP9sb3n/ZGdx/2Zpc/9sbnX/ -dHZ8/3Fzd/9tb3f/b3F2/29xdf95e4H/b3F1/3N1fP94eX3/c3V8/25wd/9ucHf/dXd9/2xudf9ucXv/ -bnF7/25wd/9sb3n/c3V8/2xvef9wcnn/foCG/2xvef9wc3z/Zmhu/2xudf9wcnn/cHJ5/25wd/9wcnn/ -bnB3/3J0ev9ydHv/Z2px/3l7gf9ucHf/Z2p0/3l7gf9wcnn/eXuB/3J0ef9ydHv/cHJ5/25wd/9vcXX/ -bnB3/3Bzff9wc33/c3Z//3N2f/9ucXv/c3Z//3N2f/9+gYr/c3Z//3N2f/93eoP/d3l//3V3ff9/gYf/ -dXd9/36Ahv99foH/dXiB/36Ahv9ucXv/d3qD/3l7gf95e4H/dXiB/3d6g/9zdn//dXiB/25xe/9wc33/ -dXiB/3V4gf9zdn//bG95/3N1fP9ucHj/cnV9/25xev9vcnv/a253/3Byef93eX//aGpu/3BzfP9tb3b/ -aGt1/25wd/9nanT/cHN9/3N2f/91eIH/d3l//3R2fP9vcXj/d3mC/21wev93eoP/cnV+/25xe/9ydHv/ -aGt0/3J1fv9wc33/dXiB/3V3ff97fYP/dnh8/3V4gf91d33/cHN9/2xvef9zdn//c3Z//3R3gf90dn// -eHqA/3p8gP92eH3/foCH/3x9gf90d4D/c3Z//3Z4gP93eoT/dHZ8/25wd/93eX//eHqA/3V4gP9zdn7/ -dXeA/25wev9ucXr/cXR9/3R2ff9vcXr/bnF6/3J1ff9tb3b/cXN6/25wdv9ydHr/bnB3/21vdv9vcXf/ -aWx1/3R2fP9vcnz/dHd+/3J0ff91eID/bXB6/3Fzev90d4D/eHuE/29yfP9vcnv/cHN9/3R3fv93eoL/ -d3qC/3V4gP94eoD/d3l+/3l7gf93eX//cnV+/3N2gP93eYD/d3l+/3+Bh/93eYH/eHqA/3h6gv94e4L/ -dXh//3l8g/91eH//dnh//3Fze/9ydHr/b3J6/3F0fv9wcnr/d3qD/3t9g/91eIH/d3qD/3t+h/97fof/ -d3qD/3d6g/9wc33/bnF7/2xvef91d33/bG95/21wef9tcHr/bG51/3J1fP9ucHf/c3V8/25wd/9tb3f/ -bXB6/29yev9xdH3/a253/21weP9tb3b/bG95/3N1fP93eX//bnB3/29xeP9ydHv/bW92/2tud/9qbXf/ -bG95/3d5f/9wc33/am13/2Zpc/91d33/cHN9/2ptd/9ucXv/bG95/3Byef9ydHz/c3V7/2hqcv92eH// -am13/3V3ff9zdXz/bnB3/25wd/9ucXv/bW92/3Fze/9ydX3/cnR8/2xudv9vcXj/cHJ5/2dqcf9qbHP/ -bG51/3N2f/90dnz/dHeA/3R2ff9ucXv/d3l//25wd/9zdXz/d3l//2xudf9qbXf/Z2p0/25xe/9nanT/ -am13/2dqdP9qbHP/Z2p0/25xe/9qbXf/am13/3l7gf9tb3P/cHJ5/2BjbP9sbnX/cHJ5/2xudf9ucHf/ -cHJ5/21wev9ydHv/dHeA/2Zpc/93eX//bnB3/2ptd/92eHz/bnB3/3p7gP9ydHr/cnV//25xe/9vcXX/ -b3F1/2ptd/9wcnn/cHJ5/3V3ff91d33/b3F1/2xudf9qbXf/d3qD/2ptd/9sb3n/bnF7/21vc/9sbnX/ -bnF7/2psc/9sb3n/bnF7/2xudf9wc33/XWBq/2xvef9ucXv/bnF7/2Zpc/9qbXf/bG51/2xvef9kZ3H/ -amxz/2ptd/9sb3n/bnF7/25wd/90dn3/bG92/25xe/9sb3n/aGt0/2Rncf9qbHT/c3V8/2RmbP9wc33/ -cHN6/21wev9zdn//cHN9/3l8hv93eoP/f4KM/3+Bh/94eX3/bG95/3N2f/9wcnn/eXyG/3N2f/9wcnn/ -bnB3/2ptd/9ucXv/c3Z//3Bzff9zdXz/d3qD/3Byef9ucXv/bnF7/25xe/9sb3n/c3Z//3N2f/91eIH/ -bnF7/3N2f/96fIL/c3Z//32Aif95e4H/c3Z+/3Bzff9zdn//fYCJ/3d5f/92eH7/en2G/3p9hv92eYL/ -dXiB/3V4gf90d4H/c3Z//3V4gf96fIL/b3F4/3Bzff9ydX7/cHJ5/3Bzff9wcnn/dHeA/25weP9ucHf/ -bW92/2hrcf9xc3n/cHJ5/3Z4fP9ucXr/cHN8/2ptdv9qbXf/c3V8/3d5f/9qbXf/aGt1/2xudf9sb3n/ -bG95/21wev9tb3b/a254/2hqcf9maXP/a210/2Vocf9nanT/a210/2hrcv9ucXv/a210/2Nmb/9naXP/ -aGt0/2dqdP9maXL/Z2lw/2hrdf9kZ3D/ZGdw/2Zpc/9iZW//ZWhw/25xe/9wc33/bnB3/25wd/91d33/ -d3l//3N2f/91d33/bnF7/2xvef9sb3n/dXd9/25wd/9ucHj/cHJ7/2xveP90dnz/bnF7/2dqdP9zdXz/ -bG51/29xeP9ydH3/dHeA/3N1fv9maXP/a211/2xudv9qbXf/am13/3Bzff9vcnv/bXB6/2lsdP9sbnX/ -bW92/2ptd/91d33/bnF7/2dqdP9nanT/cHN9/3N1fP9qbHP/bG95/2ptd/9qbXf/bnF6/25xe/9laHL/ -bnF6/2Nmb/9qbXf/bG51/2Rncf9maXP/bG51/2xvef9qbXb/bG51/2ptdP9oa3P/c3V8/3Bzff91d33/ -ZGdx/2psc/9tb3X/cXN5/29xef9sb3n/bG51/3d5f/9sbnX/cHN9/3d5f/9qbXf/Z2p0/2Zpc/9zdXz/ -bW9z/29xdf9ucHf/amxz/21vc/9zdXz/cHJ5/3N1fP9+gIb/bnB3/3Bzff9kZ3H/bnB3/3N2f/9sb3n/ -bnB3/29xeP9wcnn/cXN7/2xudf92eHz/cHJ5/2xudf9ucHf/eHl9/21vc/91d37/b3F4/29xeP9ucHf/ -bnB3/3Byef9sb3n/dXiB/3N2f/93eoP/eXuB/3Bzff91eIH/c3Z//3+Bh/9zdn//d3qD/31+gf9zdn// -c3Z//3l8hv9zdn//e32D/3V4gf9zdXz/eXuB/2Zpc/93eX//c3Z//3Z4fP9ucHf/bnB3/25wd/9wcnn/ -am13/25wd/9wcnn/bG51/25xe/9qbXf/bXB6/2ttdP9oa3P/aGty/2ttdf9nanT/c3V8/2dqdP9rbnj/ -cXN7/2ttdP9kZ2//bW91/2dqdP9sb3n/cHJ5/3d5f/93eX//bG51/2xudf9wcnn/dXd9/2xudf9sbnX/ -c3V8/25wd/9wcnn/bnF7/3Bzff9ucXv/bnB3/2ptd/9ucHf/bnB3/3Bzff9ucXv/eXyG/3V3ff93eX// -c3Z//3N2f/9wcnn/dXiB/3l7gf91eIH/cHJ5/3t9g/97fYP/foCG/3t9g/9ucXv/c3Z//3l7gf9wcnn/ -eXuB/3Bzff9wc33/bG95/2Zpc/91d33/cHN9/2psc/9ucHf/bG95/3N1fP9vcXX/cHJ5/25wd/9zdXz/ -am13/3V3ff9wcnn/bG95/2ptd/9kZ3H/bG51/25wd/9tb3P/cHJ5/25xe/9zdn//cHJ5/25xe/9zdXz/ -c3V8/3d6g/9wc33/d3qD/3t9g/93eoP/d3qD/3t+h/97fYP/eHuF/31/hf96fIP/c3Z//3J1f/95e4H/ -am13/3N1fP9wcnn/bG95/3R2fP9ydHv/dXd7/2dqcf9ucHX/bnB3/21vd/9ucXv/dnh8/2xudf9ucHf/ -dXd9/3d5f/9zdXz/bnF7/2ptd/9qbXf/bG51/3N1fP9qbXf/bG95/2xvef9qbXf/dHZ8/2xvef9maXP/ -dXd9/2ptd/9sb3j/cnR7/3F0ff9xdHz/Z2lx/21vdv9wcnn/bnB3/3N1fP92eHz/cHJ5/3Byef9sbnP/ -am13/21vdv9wc33/dXd9/25xe/9qbXf/b3F1/3Z4fP9zdn//b3F1/3Byef9wc33/bnF7/3Bzff90dnz/ -bG93/3R3gP9nanT/bnF7/25xe/9sb3n/bG95/3V4gf92eYL/c3V9/3N2fv9vcnr/b3F4/3d5f/91d33/ -d3qD/2xvef9ucHf/b3F4/3J0ev9ucXv/cHN8/2xvef93eoP/bW9z/3Byef92eHz/am13/2dqdP9qbXf/ -cHN9/2xudf9ucHf/bG95/2xudf9ucHf/dXd9/3Byef91d33/fn+D/25wd/9ydHz/Z2p0/25wd/9wc33/ -bnB3/2xvef9sb3j/cXN5/21wev9nanT/bnF7/2psc/9nanT/bG51/3h5ff9vcXX/eXuB/3Byef9vcXn/ -bnB3/2ptd/9qbXf/Zmlz/2xvef9ucXv/am13/3N1fP9qbHP/Z2p0/2dqcf91eIH/am13/2ptd/9wcnn/ -bW9z/21vc/9wcnn/bW9z/3Byef9sbnX/bG51/3N1fP9iZW7/c3V8/25xe/9zdXz/bG51/2xvef9sbnX/ -cHJ5/2xudf9ucHf/c3V8/25wd/9wcnn/cHJ5/3N1fP9tb3P/bW92/2ptd/9sbnX/Z2p0/3N1fP9nanH/ -b3F5/3F0ff9sb3f/Zmhv/29xeP9sbnX/cHJ5/3V3ff97fYP/eHl9/21vc/9sb3n/c3Z//3N2f/9sb3n/ -bnB3/25xe/9ucHf/bnB3/3N1fP91d33/bnF7/25wd/9ucHf/bG95/25wd/9ucXv/bnB3/3l7gf9zdXz/ -eHl9/3N1fP9wc33/bG95/3N1fP9wcnn/cHJ5/2xudf9zdXz/dXd9/3V3ff9zdXz/Z2px/29xdf91d33/ -b3F1/3V3ff9ucHf/c3V8/21vc/9maG7/cHN9/2xudf9nanT/Z2p0/2xudf9sb3n/am13/2dqdP9nanH/ -am13/2Zobv9ucHf/Zmlz/2Zobv9gY2z/XWBq/2dqcf9nanT/YmVu/2Zpc/9kZ3H/ZGdx/2Jlbv9iZW7/ -ZGdx/2Jlbv9maXP/Z2px/2dqdP9wcnn/Z2p0/2Rncf9qbXf/Z2p0/2Zpc/9maXP/Z2p0/2Zobv9qbHP/ -am13/2Jlbv9maG7/ZGdx/2dqcf9sb3n/bG95/2xvef9nanT/bG95/2psc/9sbnX/bnF7/3N1fP9qbHP/ -am13/25xe/91d33/bG95/2ptd/9nanH/amxz/2Rncf9qbXf/amxz/2tueP9rbnj/am11/3V3e/9wcnn/ -amxz/3d5f/9sb3n/bnF6/3F0fv9xdH3/dHZ8/2dqcv9tb3b/cHJ5/2xudf9zdXz/dXd9/21wev9tcHr/ -aWx2/2xvef9tb3n/dXiB/3d6g/9wcnn/bnB3/21vc/91d33/dXd9/2psc/9sb3n/bG95/3Byef9qbXf/ -bnF6/2xudf9ydH3/am13/25wd/9ucHf/bG95/3Byef9zdn//dHeA/3J0fP9tcHj/bG53/3J0e/94eoH/ -c3Z//3t+h/9sb3n/bG95/25xe/90dn3/bnB4/25wd/9tb3P/dXiB/2dqdP9nanT/cHN9/2xudf9nanT/ -ZGdx/2xvef9qbHP/ZGdx/2dqcf9kZ3H/Z2p0/2xvef9sb3n/bG95/3t9g/9qbXf/c3V8/2Zpc/9sb3n/ -cHN9/25wd/9wc33/bnB3/3ByeP9zdXr/bG95/3N2f/9wcnn/bG95/2xvef91d37/b3F2/3l7f/9xc3n/ -bnB3/3N2f/9vcXX/bW9z/2psc/9wcnn/c3V8/3Byef92eHz/bnB3/2ptd/9sbnX/c3Z//2ptd/9sb3n/ -bnF7/2ptd/9qbHP/c3V8/21vc/9zdXz/bnB3/3Bzff91d33/Zmhu/3Bzff9wc33/eHl9/25wd/9wcnn/ -b3F1/3Byef9sbnX/bnB3/3Byef9ucHf/bnF7/25xe/94eoD/cXN7/29xef9vcnf/bG95/2xveP9ydX7/ -Z2p0/25xev9xdH3/a254/2RncP9rbnj/Z2p0/2xvef9wc33/c3Z//3N1fP9sb3n/cHJ5/3Fzff9ydX7/ -b3J8/3Byef9ydX7/cHJ5/3Bzff90d4D/cHN9/3V3ff9vcXX/bG51/2xudf9tb3P/bnB3/2xudf95e4H/ -cHN9/3R2fP91d3v/c3V8/2ptd/9sb3n/bG51/2xudf9qbXf/cnV8/3N1fP9wcnn/am13/2Fkbf9qbHP/ -c3V8/2xudf9ydXz/am13/25xe/9sbnX/ZWhx/3N1fP9sbnX/bG51/2xudf9sbnX/bG95/2ptd/9ucHf/ -b3F1/3N1fP9tb3P/dnh8/25xe/9sbnX/amxz/2Jlbv9qbHP/bG95/2Zpc/9qbXf/am13/2xudf9qbXf/ -am13/2xudf9qbXf/cHN9/2xvef9ucXv/d3l//3V3ff92eHz/dnh8/3Byef9sb3n/bnF7/3Bzff9sbnX/ -bW9z/3V3ff9qbHP/bnB3/2xudf9tb3P/c3V8/3Bzff9sb3n/Z2p0/2xvef9qbHP/bW9z/3N1fP92eHz/ -cHJ5/25wd/91d33/c3V8/25xe/9wcnn/am13/25xe/9qbXf/cHN9/2xvef9tcHr/bXB4/21veP9zdoD/ -bnF7/2xudf93eX//bG51/2tueP9wc3v/cnR7/3R2ev9naXD/bnB2/3N1fP9ucHf/dXd9/3V3ff9vcXj/ -b3F5/2xuc/9ucHf/cHJ2/3N2f/93eX//cHN9/2xvef9sb3n/dXiB/3h5ff9ucHf/c3V8/3N1fP9wcnn/ -bG95/3J1ff9sb3f/cnN5/2Vocv9qbHP/Z2p0/2BjbP9kZ3H/Zmlz/2dqc/9rbnT/aWtz/2Zob/9pa3L/ -cHN9/2xvef91eIH/Z2lz/2xudf9sb3f/cXR7/2ptd/9sbnX/am13/3V4gf9kZ3H/am13/3Byef9maG7/ -ZGdx/11gav9nanT/Zmhu/2Rncf9maG7/Zmhu/2Rncf9qbXf/ZGdx/2dqdP91eIH/YmVu/2dpc/9nanH/ -cHN9/3V4gf9wcnn/bnF7/25xev9wcnn/c3V8/2ptd/9ucXv/am13/2dqdP9sbnP/dnd8/2tueP90d37/ -cXN5/25xev9wc33/b3F1/25wd/9qbXf/c3V8/3V3ff9wcnn/eHl9/25wd/9ucHf/bW9z/3V4gf9ucXv/ -cHJ5/3N2f/9wcnn/c3V8/3V4gf9wcnn/c3Z//25xe/9wc33/dnh8/2ZobP9zdXz/c3V8/3Z4fP9vcXX/ -c3V8/2xudf9ucHf/bW9z/2xudf9wcnn/bG51/2xvef9qbXf/c3V8/2dqcP9sb3n/bW92/2xveP9sb3n/ -dXd+/2ptd/9wc33/cnV+/2xvef9maHL/bXB6/2dqdP9ucXv/bnF7/3V3ff94eX3/cHJ5/21vdv90dnz/ -bnF7/3F0fv9ydX7/cnV+/29xeP9vcnv/c3Z9/3N2gP91eIH/cHN9/3N1fP9zdn//d3qD/3d5f/91d33/ -gIKJ/3p8gv92eYP/dXiB/3d6g/9zdX3/eHqB/3h7hP91d37/dHZ9/3p7gP97fYH/enyC/3R3f/9ucXr/ -cnV+/3p8gv9ydHv/cnV9/3Byef90d4D/cnV9/29ye/94eoD/bnB3/29xeP9ucHf/bW92/21wev9rbnj/ -bnB6/2tueP9xdHv/b3F4/3d4ff9vcXj/bnB3/2xuc/9iZW//bW92/2xvef9rbnj/dHeA/3J1fv9xdH7/ -bW93/2xveP9ucHf/b3F4/3J1fv9vcnz/c3Z//3h7hf96fIL/eXyG/31+gv96fIL/enyC/3p8gv94e4X/ -d3qC/3V3ff97fYP/d3l//3Z4f/92eHz/d3l//31+gv99foL/enyD/3d5f/96fIP/dXd9/3N2f/91d33/ -eHl9/3Byef9wcnn/dXd9/3N1fP9wcnn/bnB3/2psc/9ucXv/bG51/2xvef9sb3n/aGt1/2lsdP9qbXX/ -cnV+/25wd/9nanT/d3l//2xveP9rbnj/cnV9/2xvef9ucHf/X2Jr/2ttc/9tcHr/bnB3/3N2f/92eH// -bnF7/21wev9qbHX/bXB3/2ttdP9ucXv/d3l//2ptd/9maXP/bG51/3V4gf93eX//bG51/3N1fP9wcnn/ -c3V8/2xvef9zdXz/am13/3J1ff9nanT/bG51/25xe/9kZmz/bG51/2xudf9ucHf/b3F1/21wd/9qbXX/ -a253/3V3ff9ucXv/d3l//25wdP9tcHf/c3V9/3R3f/9wc33/b3F1/2xudf97fYP/bG51/25wd/92eHz/ -b3F1/25wd/9qbHP/eHl9/3Byef9tb3P/b3F1/29xdf9sbnX/dXd9/3N1fP92eHz/f4GH/2dqdP9sb3n/ -am13/3Bzff95e4H/dXd9/3V4gf9vcnz/c3V+/3V3ff9tcHr/bnF7/21wef9sb3j/cHJ5/3d6gP9xc3v/ -dHd+/3R3gP9zdn//dnmC/3Bzff9zdn//c3V8/3N2f/91eIH/bnB3/3d5f/9sb3n/bnB3/25wd/93eX// -bG95/25wd/9wc33/bnB3/25wd/9wc33/bnB3/3Bzff9ucXv/dXiB/3V4gf9nanH/cHN9/3N2f/95e4H/ -cHJ5/3N2f/9wcnn/cHN9/3N1fP9wcnn/dXiB/25xe/93eoP/bnF7/3V4gP9ucHf/cHN8/29xeP9ucXn/ -a254/3V3ff9pbHb/cXR8/29yfP9wc3z/bG95/2xvef9qbXf/cHN9/3Byef91eIH/d3l//3Fze/9ucHj/ -dHd+/2ptd/92eYD/cHJ6/3V3f/9tcHr/cXR8/3V3fv92eYD/dXiB/29xeP9tcHn/bnF7/3Bzff9wc33/ -cHN9/3l8hf9ydX7/dHV7/3J0fP9ydX//cXN6/3Fzev9ydX3/b3J6/3Fzef9ydHz/dXiB/3Z4f/9vcnr/ -bW94/25xef92eHz/b3F2/3Bze/9wc3v/c3Z//25xe/9vcXr/d3l//21vdv9xc3r/b3J6/21weP9vcXv/ -bW94/25wef9rbnj/b3J8/21wef90dn3/cXN7/3Bze/9tb3X/ZWdu/2Zpc/9pa3P/Zmly/2tueP9rbnb/ -bG92/2Vocf9sbnX/aWxz/2dpb/9oanT/a210/21veP90dn3/b3J5/3R2fP9zdXr/bnF4/29ye/9ucXv/ -b3J8/3BzfP9xc3r/cXR9/3Bye/9ydHv/cXN9/3J1ff93eX//e32D/3R3f/9xdH3/c3Z//3F0ff9vcnz/ -dXd9/3d5f/9ucHf/cHJ5/3Byef9wcnn/cHJ5/3V3ff9sbnX/cHJ5/21vc/9ucXv/bnF7/2xvef9sb3j/ -bXB4/3V3fv9sb3n/Z2p0/3d5f/9sbnX/a210/29xd/9tcHr/cnR6/2Rmbv9sbnT/am13/2dqdP9ucXv/ -c3V8/2xudP9tcHr/a252/2xvef9ucXv/cHN9/3d5f/9ucXv/bG95/25xe/97fof/d3qD/25wd/91d33/ -cHJ5/3Byef9ucHf/cnR7/21vdv9ydXz/aGty/2xudf9ucXv/ZGZs/25wd/9ucHf/bW93/25weP9ucHf/ -bnB2/2xveP9zdXz/c3V8/3V4gf9sbnX/bG51/21wev9zdXz/am13/2xudf9qbXf/dXiB/2psc/9sbnX/ -dXd9/2xudf9tb3P/amxz/3Z4fP9vcXX/bnB3/2xvef9ucHf/am13/3d5f/91d33/c3V8/4GDiv9qbXf/ -cHN9/2dqcf9vcXX/c3V8/2ptd/9ucHf/bW92/3Bye/9ydX7/cnR7/3V4gf91d4D/cHJ7/3d5gP96fYf/ -eHqB/3R2fv9ydX3/bXB5/2xvef9sbnX/bG51/2ptd/9ucHf/c3V8/2xvef91d33/bnB3/3Byef9sb3n/ -dXiB/2xvef9sb3n/bnF7/25xe/9ucHf/cHJ5/25wd/9ucXv/bnF7/3V3ff93eoP/ZGdx/3N2f/93eoP/ -d3qD/25wd/9zdn//bnF7/25xe/9wcnn/bnB3/3Bzff9sbnX/c3V8/25wd/91d33/bG95/3F0ff9ydH3/ -dHd//3Bzff95e4H/c3Z+/3d6gP9wc3z/b3F5/2xudf9sbnX/Zmlz/2xvef9sb3n/dXd9/3N1fP9rbnj/ -bG52/3Z4f/9qbXb/dnh9/3Byd/9zdn3/bW93/25weP9ucXv/dHd//3V3f/90dnz/d3l//3d5f/9+gIb/ -d3l//3R3gP96fYb/dXd+/25xe/9wc33/c3V9/29yfP9xc3r/dHZ+/29yef9zdX3/c3V9/3N2f/9xdH7/ -bG95/3Bzev9ucHX/dHZ+/21vdv9qbXf/bG92/3Bze/9sb3f/bG94/3R2fP9tb3P/cnR5/3F0e/9ucHf/ -bG95/2xvef9ucHn/bnB3/3Bye/9vcXr/c3V9/3V3f/9xdHz/b3F4/2ttc/9rbXT/bnF5/2ptdf9sbnX/ -bG50/3F0fP9qbHP/bW92/2xvef9tb3b/cHJ3/2lsdv9wc3v/dXh//2tudv90dnv/cXN6/25xef9wcnn/ -dHZ+/25xe/9tcHr/bnB5/3F0ff9vcnv/bW94/3Byev9sb3j/a252/3J1fP9vcXn/a210/21wev9vcnz/ -bnB3/3N2f/93eoP/cHN9/3N2f/9zdn//c3Z//3V4gf91eIH/cHJ5/3d6g/9wc33/d3qD/3l8hv93eoP/ -dnmB/3Bzff90d4D/dXiB/3N2f/97fYP/d3l//21wev94e4P/dXd//3V4gv9vcnz/a251/3N1fP9vcXX/ -Z2px/2psc/97fYP/cXR7/2xudf9vcXj/bnF7/3N1fP93eX//bnF7/2dqdP9ucXv/d3qD/3d6g/9ucXv/ -cHN9/3V3ff9wc33/bnF7/3Z4fv9kZ3H/dniA/2xvef9qbHP/dXd9/2Zpc/9nanH/ZGdx/2Rncf9pbHL/ -a213/21wev9laHL/ZGdx/2Rncf9qbXf/Z2lv/2tud/9qbXb/c3V8/25wdf9sb3n/bnF7/3V4gf9qbXf/ -bnF7/3l7gf9sb3n/bG95/2dqdP91d33/bG95/2xvef9ucXv/bnF7/2dqdP93eX//c3Z//3N2f/+Bg4r/ -bG51/3Byef9maXP/bnB3/3Byef9sbnX/bnB3/25weP9ucHf/amxz/25wd/9vcXX/d3h9/3N1ev9tcHj/ -dXd7/3V3ff9wc3z/c3V9/3Byev9sb3n/bG51/2ptd/9maXP/am13/2xvef9ucXv/cHJ5/2dqcf9nanT/ -Z2px/3Byef9kZ3H/YGNs/2Zobv9kZ3H/Zmhu/2Zpc/9maG7/Zmlz/2Zobv9sb3n/c3V8/1lcZf9maXP/ -Zmlz/25wd/9kZ3H/am13/2dqcf9nanH/YmVu/2Jlbv9nanT/Zmhu/2Zpc/9kZ3H/cHJ5/2dqdP9qbXX/ -bnB4/29yfP9sbnX/c3V8/25xe/9xdHv/bXB5/3J1ff9pbHX/bW90/2ptd/9sb3n/am13/3Bzff9ucXv/ -cnR8/3J0e/94e4X/bG95/3l7gf9ucHf/dXiB/3Byef9ucXv/b3J8/3N1e/9wc33/cHJ6/2ttdP9zdXz/ -c3V8/21vc/9vcnz/bnF6/25xef9ucHf/cnR7/3R2fP9ydHv/bW92/3R3ff9vcXj/c3Z//25xe/9vcnz/ -c3V+/3F0ff94eoD/cHJ3/3R2e/9vcXX/a21z/25wd/90dnv/b3F5/3Fzev9xc3r/b3F1/3V3ff9ydX7/ -bnB1/2xudv9ucHf/bXB1/2tueP9tb3f/bG51/21wev9vcnz/b3J7/29ye/9qbXf/aWxz/29xef9nanH/ -bG92/2xveP91eIH/a21z/2lsdv9vcXX/b3F4/25wd/9tb3b/dHZ7/3N2ff9pbHb/d3mA/3J0e/91d33/ -cXR+/3R3gP9zdn7/dHeA/3R3gP97fof/d3qD/3d5gP91eH//cHN8/21wev9wc3z/dnmC/3N2f/9wc3v/ -eXuC/3V4gf9zdXz/dXd9/25wd/91d33/cHJ5/3Byef9wcnn/cHJ5/21vc/9wc33/am13/2xvef9qbXf/ -bnF7/2xueP9rbnX/bG52/29xef9ucHf/dXd9/3N1fP9rbnj/cXN6/3Byef9zdXr/bW5z/2hqcf9wc3z/ -cHJ5/2dqdP9nanT/d3qD/25xe/9sb3n/bnF6/25xe/9zdn//d3qD/25xe/9qbXf/bnF7/3l7gf95e4H/ -bW9z/3N1fP9zdXz/bG51/2xudf9zdXz/Zmhu/3R2fv9ydHv/am13/3d6g/9nanT/Z2p0/2dqdP9nanH/ -a254/21wef90dn3/bG51/2ptd/9qbXf/bnF7/2xvef9ydHv/am13/3Fze/9sbnb/am13/2xudf91d33/ -amxz/21vc/91d33/bnB3/25wd/9sbnX/cHN9/2xvef9ucHf/bG95/25wd/9qbHP/dnh8/3Bzff9wc33/ -f4KM/25wd/9wc33/am13/2xvef91d33/bG51/3N1fP9tb3n/bG51/2dqcf9nanT/bW92/3V3ff9zdX3/ -cXR8/3d6hP91eIH/cXR7/3J1ff9zdXz/am13/3Byef9wcnn/Z2p0/2xvef9wc33/c3V8/3V4gf9tb3P/ -bnB3/21vc/92eHz/bW9z/29xdf9sbnX/bnB3/25wd/9qbXf/am13/2ptd/9nanT/c3V8/3d6g/9kZ3H/ -bG95/2xvef93eoP/Z2p0/25xe/9qbXf/am13/2xudf9sbnX/cHJ5/29xdf9wc33/bnF7/3l8hv9ucXv/ -cHN9/3R3gP94eoD/cHN9/3l7gf9zdn//dHeA/3Bzff9xc3r/am13/25wd/9vcXX/cHJ5/25wd/9zdXz/ -c3V8/2ptd/9qbXf/d3l//25wd/94eX3/bnB3/3N1fP9qbXf/b3J8/29yfP90d37/d3mC/3Z4gf9zdn// -e32D/3l8hv9zdXz/dXd9/25xev9sb3j/aGt0/25xe/91d33/c3V8/2xudf9zdXz/bnB3/3V3ff9sbnX/ -bG95/25xe/9vcXj/dXd9/21vdv9zdXz/a213/2dqdP9rbnj/cXR9/3Byef9wcnn/dXd9/21vdv91d3z/ -c3Z//25wd/9sb3n/cHJ5/2xudv9sbnb/bnF4/25wd/9zdXz/c3V8/3Fzev9wc33/bG51/2dqdP9sb3n/ -Y2Zu/2ptd/9wcnn/enyC/2xvef9sbnX/bW92/2tud/9ucHf/aGt1/3V3ff92eHz/aGt1/3Z4f/9wcnn/ -bnB3/25xeP9zdn//bnB3/3Bzff9ucXv/eXuC/3Z5gv9ydHv/dnh//25xe/9sb3n/bG95/3Bzff9vcnv/ -Zmly/3J1fv9vcnv/dXd9/3d5f/9wcnn/c3V8/3Byef9zdXz/cHJ5/3V3ff9tb3P/dXd9/25wd/9wcnn/ -c3V8/25xe/9qbXf/a210/2tueP9qbXf/bG51/3d5f/9ucXv/bG51/29ye/9ucHf/cXR8/2ttdP9laG// -bnF6/2ptd/9maXP/Zmlz/3R3gf9tcHn/bG93/2xvdv9wcnn/c3V8/3d6g/9sbnX/amxz/25wd/93eX// -d3l//25wd/91d33/dXd9/25wd/9ucXv/dnh//2hrdP91d4D/a253/2psc/9zdXz/Zmlz/2Rncf9maXP/ -Z2px/21wev9sb3n/c3V8/25xe/9wcnn/cHJ5/3Z4fP9wcnn/dHZ6/2xudf92eH7/bW91/29xdf9ucHf/ -eHl9/2psc/9sbnX/dXd9/2xudf9qbXf/amxz/25xe/9sbnX/b3F1/29xdf9vcXX/Z2px/3V3ff91d33/ -c3V8/3+Bh/9nanT/bnB3/2dqdP9ucXv/cHN9/2ptd/91eIH/bG95/21veP9qbHP/ZWhy/2xudf9xdH3/ -cXN5/21vdv90dnz/c3V8/21wef9wcnr/bnB6/21wd/9ucHf/cHJ5/2psc/9sbnX/cHN9/3Bzff9zdn// -bG51/25xe/9nanH/cHN9/2Zpc/9nanH/Z2px/2xudf9sb3n/am13/2xudf9ucHf/bG51/3V3ff99foH/ -Zmhu/3N1fP9wcnn/eXuB/2ptd/91d33/bnF7/2ptd/9qbXf/am13/25xe/9ucHf/c3V8/3V3ff95e4H/ -bnB3/3Fze/9wc3v/dHeA/3N2f/93eX//c3Z//3Z5gv9zdn7/cHJ4/2hrdP9qbXf/bG51/3N1fP9ucHf/ -c3V8/3V3ff9qbXf/Z2p0/3d5f/9sbnX/eHl9/25wd/91d33/b3F1/3Byef9wcnr/cXR8/3R3f/91eIH/ -cHJ5/3N2f/9zdn//bnB3/3Z4f/9ucXr/bnB4/21vc/9wcnn/dXd9/3h5ff9ucHf/dXd9/25wd/92eHz/ -bG51/3Byef9zdXz/am13/3V3ff9sbnX/dnh8/29xdf9qbHP/bG95/3Bzff9ucXv/am13/3Bzff9qbXf/ -dXd9/3V3ff9ucHf/bnB3/3Byef9vcXX/bnB3/25xe/9ucHf/c3Z//3V4gf9zdn//c3Z//2xvef9qbXf/ -c3V8/2dqcf9sbnX/bnB3/3d5f/9ucHf/am13/3Byef9wcnn/bnB3/2ptd/91eIH/eXuB/2dqdP93eX// -bW9z/2xudf9sbnX/bG95/2ptd/9qbXf/bG95/3N1fP9ucXv/aGty/3Z4fP9qbHP/Z2px/2xudf9ucXv/ -cHN9/2Zpc/9zdn//b3F1/2xvef9sb3n/Zmlz/2ptd/9nanT/bnF7/2ptd/9qbXf/bG51/3Bzff9sbnX/ -bG95/2xvef9ucXv/b3F4/21vdv9sbnf/bG51/2dqcf9wcnn/am13/2hrcv9ucHr/bW91/3BzfP9oanP/ -X2Jq/2hrdf9nanH/XWBq/2Rncf93eX//bnF6/29xev9sb3j/c3Z+/3d6g/95fIb/cHJ5/2xvef9wc33/ -eXyG/3t+h/9wc33/e32D/3t9g/91d33/cHN9/3p8gv9pbHb/e32E/3N2f/9sb3n/d3l//25wd/9vcXX/ -bG51/2xudf9vcXj/cHJ6/3R2fv9ucXv/bG95/3N1fP91d33/bnB3/3J0e/9tcHn/dniB/25xe/9ucHf/ -bnB3/3Z4fP9sbnX/cHJ5/3h5ff9sbnX/bG95/2ptd/9ucXv/am13/2xudf9qbXf/bG51/2Zpc/9wc33/ -cHN9/3N1fP9/gYf/am13/25xe/9sbnX/bnB3/3Bzff9nanT/bnF7/3Byef9wc3v/a253/2dqc/9wcnn/ -cXR9/25xeP9pbHX/Z2pz/2dqdP9laHD/bnB2/2ptd/9rbXX/bG95/2xvef9nanT/am13/3N1fP9wc33/ -d3qD/2xudf9wc33/bG51/3V3ff9nanT/amxz/2xudf9qbHP/bG95/2ptd/9qbXf/bG95/2xudf91d33/ -e32D/2Jlbv9ucXv/bG95/3N2f/9qbHP/c3V8/3Bzff9nanH/amxz/2Jlbv9nanT/Z2px/2ptd/9sb3n/ -dHeA/2lsdP9sb3j/b3F3/3Byef9wcnn/cHJ5/3Byef91d3v/b3J7/3Z4fv9ucHf/bnB3/2xvef9wc33/ -bG95/25xe/95e4H/cHJ5/2ptd/91eIH/bnB3/3d5f/9ucHf/dXd9/2xvef9ucXv/cnR7/3Bze/9xdHv/ -cHN9/2tueP9zdXz/dXd9/29xdf92eH//bXB6/21vd/9rbXf/bnB3/3V3ff94eX3/bG95/3l7gf9zdXz/ -e32D/3Bzff91eIH/eXuB/3N2f/97fof/c3Z//3t9g/9wc33/c3Z//3d5f/95fIb/d3qD/3N2f/93eoP/ -c3Z//3t9g/91eIH/c3V8/2xvef9sb3n/bG95/25wd/9wcnn/bW9z/3Byef91d33/c3Z//3V3ff9ucHf/ -bG51/25xe/9iZW7/bG51/2xvef9zdn//Zmlz/2Rncf9nanH/Z2p0/2dqdP9kZ3H/bnF7/3N1fP9nanT/ -d3l//2ptd/9nanT/bG51/3Byef9sbnX/am13/2xvef9ucXv/am13/2Zpc/9wc33/Z2p0/2BjbP9nanT/ -cHN9/2xvef9iZGr/bnF7/2xudf91d33/dnh8/3N1fP9wcnn/bG95/25xe/9ucXv/am13/2psc/9ucXv/ -am13/2psc/9qbXf/cHN9/29yfP9rbXb/bG93/2tueP9sbnX/dXd9/3Byef9tb3P/cXN6/21wef9ydHz/ -a251/2dqcv9ydHv/cHJ5/2psc/9sbnX/dnh//3Byef9sbnX/aWx1/2xvef9ucXv/dXd9/2Zpc/9gY2z/ -Z2px/3Byef9wcnn/Z2px/25xe/9sb3n/amxz/2Zobv9rbnj/Y2Zu/3Z5gv9vcnv/bG95/3d5f/9ucHf/ -bnB3/2xudf9tb3P/bnB3/3Fzev90dnz/c3Z+/25xe/9wc33/d3qD/3J0fP9ydHr/a254/3N2f/9tb3b/ -am13/2xudf92eHz/bnB3/3Byef9zdXz/bW9z/21vc/9tb3P/bnB3/3Byef9ucHf/bnB3/29xdf9nanH/ -c3V8/3N2f/9zdn//f4GH/2xudf9xc3r/ZGdx/2ptd/9sb3n/Z2px/3Byef9vcXb/b3F4/2xudf9nanT/ -cHN9/3V4gP90dnz/dHZ9/3N1fP91d33/bnB3/3N0eP9ydHr/cHJ5/3Byef9wcnn/amxz/2xudf92eHz/ -cHJ5/3V4gf9sbnX/bnF7/2xudf9wcnn/Z2px/2Rncf9maXP/Z2px/2dqcf9maG7/YmVu/2Zobv9maG7/ -am13/3N2f/9ZXGX/Zmlz/2dqdP9wcnn/ZGdx/2xvef9sb3n/amxz/2ptd/9maXP/am13/2xudf9sb3n/ -cHN9/3R2ff9oa3X/bG95/3F0ff9vcnz/dXd9/3N1fP9wcnn/dHZ8/3N2f/91d37/b3J5/2xudv9sbnX/ -cHN9/2xudf9sbnX/dXd9/2xvef9qbXf/e32D/3N1fP93eoP/bG95/3Z4fP9qbXf/c3Z//3J0e/9ucHn/ -cXN6/3R2fP9tb3P/c3V8/3Bzff9ucHf/c3V8/29yfP9ucXv/bnB3/3Byef93eX//e32D/3Byef97fYP/ -cHJ5/3t9g/9ucXv/cHN9/3V3ff9wc33/eXuB/3Byef9zdn//bG95/2ptd/9sb3n/c3V8/3N1fP9ucHf/ -bnB3/25wd/9zdXz/bG95/2ptd/9qbHP/am13/2Rncf9nanH/am13/2dqcf9nanT/am13/25xe/9wc33/ -amxz/2xudf9zdXz/amxz/25wd/9wc33/eXyG/2xvef9ucHf/cHJ5/3N1fP9ucXv/bG95/3N2f/97fYP/ -c3Z//36Biv91eIH/c3Z//3Bzff93eoP/c3Z//3l8hv93eoP/e32D/3l7gf9wc33/d3qD/25wd/9maG7/ -bG51/25wd/9sbnX/ZWZq/3N1fP9zdXz/c3Z//3V4gf9wc33/dXd9/3V3ff91d33/cHN9/3Bzff9wc33/ -dnh8/3Bzff9wc33/c3Z//3Z5gv91eIH/bXB5/3Bze/9sb3n/bG51/3V3ff9sb3n/bG51/3F0ff9tcHn/ -c3Z+/21vd/9naXP/am13/2xvef9iZW7/ZGdx/3V3ff9qbXX/Z2p0/2hrdf9xc3r/cnV8/3Z4f/9sbnX/ -amxz/2tudf91eIH/dHZ8/25wdf9ydX7/cnV+/2xvef9ucHf/cXR9/2dqdP90dn7/Zmlz/2Zpb/9sb3n/ -YmVu/2Zobv9kZ3H/Zmhu/2lsc/9sbnj/dHZ9/2xvef9sbnX/bG95/3V4gf9tcHn/cHN7/2tud/92eYH/ -b3J7/25wd/9vcXX/d3l9/3Byef9wc33/dHZ8/25wd/9sb3n/b3F1/25wd/9ucHf/bW9z/2xudf9ucHf/ -aGt1/25xev92eH7/dXeA/36Ahv9ucHf/dXiB/2Zobv9qbXf/bG95/2Zpc/9wcnn/bW90/2tueP9sbnX/ -Z2pz/2xvef9vcnv/cHJ7/3N1e/92eYH/c3Z//29yfP9zdX3/cnV9/3J1fv91eIH/d3qD/3N2f/9zdn// -foGK/3l8hv+Bg4r/cHN9/3d6g/9zdXz/d3l//3Byef9wc33/cHN9/25xe/9ucXv/bnB3/29xdf9wcnn/ -bnF7/3l7gf9+gIb/Z2p0/3N2f/9wcnn/d3l//21vc/92eHz/dXd9/25wd/9ucXv/Z2p0/2xvef9ucHf/ -bnF7/3V4gf94e4X/bnB3/3Fze/90d4D/cHN8/3V3ff9wc33/bnF7/3N1fP9ydHr/cnR6/21wd/9sb3n/ -bnF7/3d6g/9ucXv/cHJ5/3N2f/9ucHf/amxz/3V3ff9vcXX/dXd9/2xvef9zdn//bXB6/3V3fv9ydX7/ -cHN9/3N2f/90dnz/bnB3/3N2f/9wc33/bG95/3Fze/9ucXv/bXB6/2xveP9ucXv/dHeA/3p8gv9ucHf/ -dHd9/2xudf92eHz/cHJ5/3Byef9zdXz/bG95/3N1fP9sbnX/bnF7/2dqdP9nanT/bG51/2xvef9sb3n/ -amxz/2xudf9sbnX/dXd9/3N1fP9ucHf/bW9z/2xvef9maXP/am13/2xvef9sbnX/c3V8/3N1fP9zdXz/ -c3V8/29xdf9vcXX/cHN9/2ptd/9wcnn/c3V8/3d6g/9sbnX/bnB3/29xdf9vcXX/bG51/2psc/9ucXv/ -cHN9/2ptd/93eX//am13/2psc/9qbXf/bnF7/2xudf9ucXv/am13/3Bzff9ucXv/ZGdx/25xe/9nanH/ -YGNs/2Rncf9qbXf/bG51/2RmbP9ucXv/bnF7/3Bzff91eIH/c3Z+/3R2fP9zdXz/c3V8/3Fzef9ucHf/ -cHJ5/3Z4fP9wcnn/bnB4/29xeP9ydHz/cnR7/2xudv9wc3r/dXiB/3N1fP91d33/bnF7/29xdf91d33/ -bnF6/3F0fv9zdXz/aGt1/25xe/9ucXv/am13/25wd/95fIX/cnR6/2xvef9rbnj/cnV8/3V3ff93eX// -bnB3/21vdv9wcnb/d3l9/3d5gP9tcHX/cnR7/3N1fP9sb3n/bG94/3R2ff9qbHP/eHl+/25xe/9tb3P/ -dnh8/2Zpc/9qbXf/bG51/21vc/9sbnX/cHJ5/3V3ff9ucHf/bW9z/25wd/97fYP/cXN6/3FzfP9rbnf/ -dHeA/25xev9qbXb/bG92/3N2f/9tb3b/cnR7/21wev9sb3n/bG95/21wdf9tb3b/bnB4/2xudf9rbXP/ -bnB3/2lsdf9sbnj/dXd+/3J0e/97fYL/bG90/3ByeP9gY2z/bG51/2xudf9kZ3H/bG95/2xudv9sb3j/ -bG95/2ptdv9wcnn/dHZ9/25weP9ucHj/bnB5/3N1fP9tb3b/cXN7/29ye/9ucHf/bG95/2ptd/9maXP/ -bG95/3V3ff9wc33/dXiB/21vc/9ucXv/bG51/3N1fP9tb3P/bG51/3Bzff9qbXf/am13/25xe/9qbXf/ -bG51/2xudf9wcnn/d3l//2Rncf9sb3n/bnF7/3V3ff9sbnX/dnh8/3V3ff9ucHf/bG51/2psc/9sb3n/ -b3F1/25wd/9wc33/dnmC/2tud/9sb3j/bXB6/2hrdf9xc3r/a254/21wef9vcnz/cnR9/3R2fP9vcnz/ -bnB3/25xe/91d33/b3F1/29xdf9zdXz/ZWhx/2Zpcv9wcnr/bW92/3d5gP9rbnj/cXR+/21wd/90dn3/ -c3Z9/3J1ff91eIH/enyC/3Byef9zdn//c3V8/2xvef9vcnv/cnR7/21wev9sb3j/bnB3/3BzfP92eH7/ -bXB6/3R2fP9rbXT/eHl9/25weP9ucHf/cnR7/3Fzev92eH3/bG94/3N1fP9ucXv/bG51/25wdf9vcXj/ -b3F4/21vdP9sbnb/bW92/3R3gP9ucXv/bG52/2xudf9wcnn/Z2p0/2xudf9tb3P/bG51/3Bzff9zdXz/ -dXh8/3Z5f/9ucHf/a254/25xe/9qbXf/b3J8/29yfP94eoD/bG95/25wd/9ucXv/bnF7/2ptd/9oa3T/ -c3Z//3V4gf9wcnn/eXuB/25xe/9sb3n/bnB3/3V4gf9ucXv/d3l//25wd/92eHz/c3V8/2ptdP9zdXz/ -am13/2Zobv9sbnX/bnB3/2ptd/9gY2z/cHN9/25xe/9vcnz/cHJ8/3J1fv9ydX7/cHN8/3Byef91d33/ -b3F4/25weP90d37/cHJ5/3Byev9xc3v/c3V8/3J0e/9wc3v/cHN8/3N2f/9wcnn/d3qD/3N2f/9ucHf/ -d3l//25xe/91d4D/dHeA/2ptd/9wc33/cHN9/25xe/9wcnn/en2G/3N2fv9vcnz/b3J6/29yfP92eH7/ -dnh//3BzfP9ydHv/cnR5/3p8gv94e4T/cHJ4/3J1fv9ucXv/cHN8/3Bze/92eH7/am13/3h6gP9ucXv/ -c3V8/3l7gf9sb3n/bnB3/3Byef9ucHf/b3F1/3Byef91d33/cHJ5/29xdf9ucHf/eXyG/25xe/9vcnv/ -am13/3J0ev9vcXr/aGt1/2tudv9ydHz/a252/21vdv9tb3f/bW92/2xudf9rbXT/bG51/25xef9rbXT/ -aWx2/2xvef9qbXf/amx0/3F0ev9tb3b/cnR6/2hrcf9sbnf/am13/3Byef9wc33/bG95/3Bzff9tb3X/ -a252/2dqc/9fYWv/ZGZt/2xveP9qbXb/bG95/3F0e/91d3//b3F3/3J1ff9zdXz/bG95/3N1fP9wcnn/ -bG51/3N1fP91d33/bnF7/3N1fP9qbHP/bnF7/2ptd/9zdXz/bG51/2xudf91d33/bnB3/3Byef9wcnn/ -bG95/25wd/9ucHf/dnh8/4CChv9ucHf/dXd9/3N1fP93eX//bnB3/3Z4fP92eHz/bnB3/2xudf9sbnX/ -bG51/2xudf9qbXf/bG95/3V4gP9nanT/bW95/3F0ff9vcnn/dXd9/3N1e/90dnz/c3V7/21vdv9sb3j/ -Zmlz/2FkbP9maXP/ZGdx/2Zobv9iZW7/am13/2lsdv9rbnb/dHZ7/3Byef9zdXv/bG51/2xvef9qbXf/ -bnF5/21wev9rbnf/b3J8/2xvef9nanH/bnF7/2xvef9oa3T/a253/25xef9tb3j/bG51/21vdv9tb3f/ -cHN6/2lsdv9qbXf/ZGdw/3N1fP9nanT/Zmlz/2ptdv9ucHf/b3J8/21vdv9vcnz/bXB6/2hrdf9tb3f/ -bG95/29yfP9qbHP/aGtz/2ttdP9zdX7/bnB5/21vdv9sbnX/b3J8/2hrdf9sbnX/bnB3/21vdv9xc3r/ -dHZ8/3V3fv91d37/bnB3/2ptd/9vcnv/am13/25wd/90dnz/dXd+/2xudf9tb3b/a254/29xeP9nanL/ -aWt1/2ptd/9sb3n/amx0/25xe/9qbHP/Y2Zv/2hrdf9ucXv/bG94/29yfP9nanH/b3F4/2tueP9oa3X/ -cnR7/2ptd/9jZm//Zmlz/2ptd/9qbXf/YGNs/25xe/9qbXf/bW94/25xe/9ydX//cnV//3N2gP91eIL/ -dXd//29xeP9xc3v/dHd//29ye/9tcHn/cnR6/21wev9ucHn/a253/21wev9rbnj/amxz/3V3ff9wcnn/ -bG51/3V3ff9qbXf/b3J8/3J1fv9maXP/bnB3/21vc/9qbXf/Z2p0/3R2ff9sbnX/bW91/3Fzev9rbnj/ -dHZ9/3F0ff9vcnz/dXd9/3F0fP90d3//dXiB/21vdv90d3//b3J7/3R3f/9wcnv/cXR9/2dqdP94eX3/ -cHJ5/29xdf94eX3/amxz/21vc/9tb3P/am13/2xudf9ucHf/dXd9/2xvef9sbnX/am13/3d6g/9nanT/ -a253/2VocP9rbnT/bG93/2RncP9laHD/bG93/2hqcP9pbHP/ZGdx/2hqcP9maXP/amx0/2lsc/9rbnf/ -a210/2ttdP9tcHr/bXB5/2hqc/9ucXn/bW95/3Fzef9rbXT/cHJ5/2xvef9wcnn/cHN9/2xvef9ucXv/ -bnF6/3Byd/9ucHf/bnB3/3Byef94eX3/c3V8/3Byev9ydHv/dXd9/3Byd/9ydXr/dHZ9/2xudv9wcnn/ -bG51/2psc/9zdXz/eHl9/3V3ff91eIH/bnB3/3Byef9wcnn/dnh8/2xvef9wc33/d3qD/3N2f/9zdn// -c3V8/25wd/9ucHf/c3V8/3h5ff9/gYf/bnB3/3Z4fP9wcnn/d3l//25wd/93eoP/eXuB/25wd/9wcnn/ -bG51/25wd/9qbHP/am13/2ptd/94e4X/Z2pz/25xef9ydHv/a254/3Bzff9rbnj/dHd+/3J0ff9tb3f/ -cnR8/21vd/9qbHP/cHN9/3Bzff9sbnX/Zmlz/3Bzff9nanT/am13/21vef9tcHr/bXB6/2ptdf9tb3f/ -b3F5/3Byev9sb3n/cXN6/3J0fP91d33/bG51/3N1fP9wc33/bG51/25wd/9xdHv/cnR6/25wd/9wcnr/ -a252/29xef9sb3n/bnB5/2ttdv91eH//a253/2ptd/9rbnb/b3F4/29yfP9wcnn/bnB5/21vdv9rbnX/ -cnR6/29xev9ydXz/b3F4/21vdv9ydHv/c3V9/2ptd/9vcXj/bW92/25wd/9tb3b/bW92/25wd/9xc3r/ -cHN6/3R2fP93eX7/dXd//3Bzff9tcHr/dHZ8/25wd/9vcXj/b3F6/3R1fP9xc3r/cnR6/3Bzff9wc3z/ -aWx0/2xvdv9tb3X/cHJ6/25wdv93eH3/b3F3/2ttdP9tb3f/c3V7/3R3fP90d37/b3F4/3Z3ff91d33/ -cXN6/3Z4f/9xdH3/bXB6/3Byev9vcnz/cXR+/2hrdf9ydX//cXR9/2lsdv9sb3n/cXN8/25wd/9sb3j/ -bnB6/21wef9nanT/am12/3N1fP9vcXn/c3V7/3N1ev9qbXf/a210/21vdv9vcXj/bnB3/29xdf9zdXz/ -cHJ5/25wd/9wcnn/bG51/3N2f/90d4D/am13/21vc/9ucHf/b3F1/2xvef93eX//b3F4/2xudf9wc33/ -bG94/3R2ff9xc3r/bW92/3V3fP90d33/dHZ9/3Z4fv9wcnb/b3F4/3Fzev9xc3r/c3V8/3N2f/9oa3H/ -eHl9/3Byef9sb3n/d3qD/25xe/9wcnn/bnB3/25wd/9wcnn/cHN9/3d6g/9zdn//cHN9/3N2f/9/gYf/ -cHN9/3N2f/9qbXf/cHJ2/3R2ff9ucHf/cHJ5/3N2f/9ucXv/b3F4/21wev9sb3n/bG95/29xeP9vcnb/ -cHJ5/2xudv9tb3P/dXd7/3R2fP9sbnX/cXR9/25xe/9tcHr/b3F1/25wd/9nanT/Z2p0/2ptd/9qbXf/ -bnB3/3Byef9vcXj/bG51/29xdf9ucHf/dXd9/3Byef9wcnn/cHJ5/3N1fP9ydHr/c3V6/3J0fP9tb3T/ -c3V8/21vc/9sbnX/c3Z//3d6g/91eIH/eXuB/25xe/9zdn//dXiB/3t9g/9wcnn/dXiB/3l7gf93eoP/ -d3qD/3d6g/9wc33/cHN9/25xe/91eIH/gYOK/2xvef91d33/cHN9/3l7gf9ucXv/e36H/3l7gf9zdXz/ -c3Z//2xvef91eIH/cHJ5/3d6g/91eIH/foCG/25xeP9zdn//dnh//25wd/9xc3n/a253/3Z4fv9zdXz/ -b3F4/3Z5gf91eIH/c3V+/3t9g/95e4H/c3Z//3N1fP93eoP/bnB3/3F0ff9wcnn/cnV+/3d6gv9ydX7/ -cHN9/3d5f/95fIL/dXiB/3h6gP95e4H/foCG/3V3ff97fYP/e32D/3N2f/92eYL/eHqA/3d5gP9ydX7/ -dHeA/2ttd/9ucXr/cHJ8/3Fzev9xc3v/eXuC/3J0e/9ucHj/b3F5/3R2fP9xc3r/dHZ8/21veP9sbnX/ -aGt1/3N2f/9sb3n/cXN7/2lsdv9qbXT/cnR7/25xe/9rbnj/b3J7/2xueP9tb3f/bXB6/29xev9tcHj/ -cXN6/3J0e/9zdXz/dHZ9/3BzfP9xc3r/aGt0/21wef9qbHT/a210/2hrdf9sbnf/bG52/25xev9tcHr/ -bW94/2hqc/9ucHf/aGty/2hrdf9pbHP/b3F6/2psdf9oanP/am13/25xe/9sb3f/bW94/2dqdP9ucXn/ -bXB3/3FzeP9vcnj/bnF7/2hrdf9sbnX/bnB4/3F0e/9laG//bnB4/2xvef9sbnX/bG51/3N1fP9sbnX/ -bG95/25xe/9wcnn/bW9z/2xudf9zdXz/bnF7/25xe/9wcnn/a253/2tud/9tb3P/c3V8/29xdf9sbnX/ -bG95/3Bzff9sbnX/bnB3/2psc/9zdn//eXuB/25wd/9ucHf/cHN9/25xe/9ucHf/eXuB/2xvef9qbXf/ -c3Z//25xe/91d33/cHN9/2xvef92eHz/c3Z//3Byef91d33/b3F1/3Byef91d33/cHJ5/25xe/9ucXv/ -Zmhu/3N1fP9qbXf/bG51/3V3ff9nanT/Z2p0/2psc/9qbHP/amxz/3Bzff93eX//am13/25wd/9qbXf/ -eXuB/2ptd/9wc33/am13/2xudf9ucXv/Z2p0/2dqcf9qbXf/amxz/2psc/9iZW7/bG51/2dqdP9sbnX/ -bG51/25xe/9qbXf/am13/3Bzff9zdXz/Zmlz/2xvef9ucXv/amxz/2xudf9sbnX/ZGdx/2Rncf9kZ3H/ -YmVu/2Zpc/9oanP/bG53/2ptd/9vcXj/c3Z//3N2f/9wc33/bnF7/25xe/9zdn//b3J7/3Fze/9tcHr/ -bW91/3Bzff9tb3P/amxz/3V3ff91d33/dXd9/3h5ff9ucHf/b3F1/25wd/92eHz/bnB3/3N2f/92eHz/ -dXd9/3Byef9zdXz/bnB3/25wd/9ucHf/dXd9/3+CjP9wcnn/c3Z//25xe/93eX//bG95/3t9g/94eX3/ -bnB3/3Bzff9qbXf/c3Z//2xvef9wc33/cHJ5/3t+h/9ucHf/cHN7/3R3gP9ucHf/dXiB/25xe/95fIb/ -cnV+/29ye/91eIH/cHN9/25wd/9zdn//c3Z//25wd/9sbnX/cHJ5/2xvef9ucHf/bG51/3Byef91d33/ -bnB3/29xdf9zdXz/c3V8/2xvef91d33/cHN9/3Bzff9qbXf/cHJ5/3N1fP9ucHf/cHJ5/3Byef9zdn// -c3Z//3N2f/9qbXf/bXB5/3N2f/9wc33/cnV+/3d6g/90d4D/c3V8/3N2f/96fIL/enyC/31/hf90d4D/ -cnV+/29yfP95fIX/dHeA/3h6gP9ydX7/cnV+/3Z4fv9tcHn/am13/3R2fP9ucHf/b3F1/3J1fv9zdX7/ -bG95/3J1fv90dnz/d3l9/3h5ff9xc3r/dHZ9/2xudf9wcnr/bnB3/21wev9rbnj/b3F5/3Bzev9zdX7/ -dnmC/3J1f/9sb3n/dnh+/3Byev91eIH/b3J8/3R3f/9ucXv/b3F5/3F0fv91eIH/cXN5/3J1fv9wcnr/ -cXR9/3J0e/90d4D/cXN7/3V3ff9wc3v/cHJ5/3N1ff92eH//am11/3N1ff9ydHz/bG51/2xudf91d33/ -bnB3/3Byef9ucXv/c3Z//25wd/9sb3n/dnh8/25xe/9wcnn/c3V8/2xudf9nanT/bW9z/3Byef9vcXX/ -b3F1/3Bzff91d33/bnB3/25xe/9qbXf/c3Z//3h5ff9sbnX/bG51/2ptd/9sb3n/am13/3N1fP9sbnX/ -Zmlz/2xvef9qbXf/bG95/2dqdP9kZ3H/bnB3/2ptd/9maXP/Z2p0/2Rncf9maXP/Z2p0/2Zpc/9nanT/ -ZGdx/1xfaP9kZ3H/ZGdx/2Rncf9ucHf/YmVu/2Jlbv9maG7/ZGdx/2psc/9nanT/bnB3/2Zobv9kZ3H/ -Z2px/3d6g/9nanT/cHN9/2psc/9qbXf/dXd9/2xudf9nanH/bG95/2xudf9tb3P/Z2px/25wd/9ucHf/ -bG95/25wd/9zdn//c3V8/3Bzff93eoP/eXuB/25xe/93eoP/d3qD/3Byef9wc33/cHN9/2xudf9vcXX/ -c3V8/21vc/9sbnX/cHJ5/29xeP9tb3b/cHJ5/3V4gf91eIH/c3Z//3N2f/9ucXv/d3l//3Bye/90dnz/ -cXN9/2xvef9zdn//bnF7/25wd/93eX//eXuB/3d5f/93eX//bG95/3Byef9vcXX/dnh8/25wd/9zdXz/ -dnh8/3V3ff9zdXz/cHJ5/29xdf9sbnX/cHN9/3V3ff+Agob/bW9z/25xe/9sbnX/dXd9/21vc/93eX// -dnh8/21vc/9sbnX/Z2px/3Bzff9sb3n/cHJ5/25wd/93eX//bW92/29yfP9xc3v/aGt1/2xvef9kZ3H/ -dXd9/2xvef9pbHP/cXR7/25xe/9ucHf/cHN9/3Z4fP9sbnX/amxz/25wd/9ucHf/bG51/2psc/9ucHf/ -c3V8/2xudf9qbXf/c3V8/3V3ff9sb3n/c3V8/3Bzff91d33/bG51/3V3ff9zdXz/b3F1/3N1fP9ucHf/ -c3V8/3N1fP9zdXz/Zmlz/2ptd/9ucHf/bG95/3Bzff93eX//bnF7/29xdf9sbnX/c3V8/3V3ff91d33/ -bnB3/25wd/9ucHf/dXd9/25wd/92eHz/bnB3/2xvef91d33/bW9z/2xudf92eHz/bG51/2xvef9ucXv/ -am13/2ptd/9ucXv/c3V8/3V3ff94eX3/c3V8/3d5f/9vcXX/cHJ5/25wd/9sb3n/am13/2ptd/9wcnn/ -cHN9/3J1fv9wc33/am13/3R2fP9vcXX/cHJ5/2xudf9ydHz/bnB3/2xvef9vcnz/dnmC/25xe/9zdn// -bnF6/3N2fv9qbXf/dnh8/21vdv90dnz/b3F4/2tueP9ucXr/cHN9/2Vocv9tcHr/cnR8/2Jlbv9nanH/ -bnF7/2ptd/9qbXf/amxz/2Zpc/9maG7/Zmhu/2dqdP9maG7/Z2p0/2xvef9maXP/ZGdx/2Rncf9qbXf/ -Z2p0/2dqdP9ucXv/cHN9/2ptd/9sb3n/Z2p0/3Bzff92eHz/bG51/29xdf9ucHf/bnB3/3Byef97fYP/ -c3Z//25xe/91eIH/c3Z//3V4gf9zdn//bG95/3N2f/9wc33/bnF7/3N1fP9tb3P/bnB3/25wd/9sb3n/ -bnF7/2xvef9nanT/bnF7/2xvef9sbnX/dXd9/2Rncf9maG7/ZGdx/2Rncf9maG7/am13/25wd/9nanH/ -Z2p0/2ptd/95e4H/bG95/3N1fP9sbnX/amxz/3V3ff9sbnX/bG51/3Bzff9ucHf/bnB3/2ptd/9ucHf/ -b3F1/29xdf9ucHf/c3V8/25wd/9tb3P/dXd9/3N1fP9nanT/dXd9/3N1fP9qbXf/am13/2psc/9nanT/ -amxz/3Byef9nanH/Zmhv/2tueP9nanT/ZWhy/2ttdf9qbXf/am13/2ptd/9nanT/Z2px/3Bzff9sb3j/ -b3J8/2xvef9sbnX/c3V8/2ptd/9nanT/bnF7/3N1fP91d33/dXd9/2xudf9ucXv/bG51/2xvef9qbXf/ -bnF7/25xe/91d33/dnh8/3Byef9sbnX/bW9z/3N1fP93eX//gIKG/21vc/9sb3n/bG95/3h5ff9sbnX/ -d3qD/3V3ff9qbXf/am13/2Zpc/9zdXz/cHJ5/3N2f/9wc33/en2G/21vd/9vcnz/cnV8/2hqdP9nanT/ -ZGdx/3Byef9ucXv/aWxz/3F0fv9vcnz/bG95/3Bzff9zdn//bW9z/2xudf9zdXz/cHJ5/25wd/9qbXf/ -cHN9/3l7gf9ucHf/bnB3/3l7gf97fof/c3Z//3t+h/97fYP/e32D/3N2f/95e4H/eXyG/3N2f/95fIb/ -eXuB/36Ahv97fYP/foCG/3V3ff91d33/cHN9/3Bzff91eIH/eXyG/25xe/9qbXf/bnB3/3N2f/93eX// -dXiB/2ptd/9sb3n/bG95/3l7gf9wc33/eXuB/3Bzff9ucXv/dXd9/29xdf9sbnX/dnh8/2xudf9wcnn/ -cHN9/25xe/9wc33/c3Z//3V3ff91eIH/eXuB/3V4gf93eX//bnB3/25xe/9ucHf/bnB3/2xudf9nanH/ -bG51/3N1fP9wc33/c3V8/2psc/9zdXz/bG51/2xudf9qbXf/cHN9/3Byef9nanT/bG95/3l7gf9sbnX/ -bW9z/2xudf9sb3n/Zmlz/3Bzff9qbHP/cHN9/2ptd/9sb3n/bnF7/3Bzff9kZ3H/bG95/2xvef9nanT/ -bnF7/3N2f/9wcnn/bnF7/3Bzff9ucXv/cHJ5/3Byef91eIH/cHJ5/3N2f/91d33/cHN9/2xvef9sb3n/ -dXiB/3Byef9wcnn/c3Z//3Bzff9ucHf/bG51/2xudf91d33/c3V8/2psc/9qbHP/am13/2xudf9nanH/ -c3V8/2psc/9maXP/bG95/2xudf9wc33/cHJ5/2xudf9wcnn/c3V8/2xudf9wc33/amxz/2xvef9sb3n/ -bG51/3N1fP9wcnn/Z2p0/3Bzff9zdXz/bnB3/3d5f/9qbXf/bnB3/25wd/9sbnX/bG51/3V3ff94eX3/ -b3F1/25wd/9zdXz/f4GH/2xvef9zdXz/bG95/2xudf92eHz/am13/2ptd/9ucXv/bG95/2psc/9maXP/ -bG51/2dqcf9kZ3H/Zmlz/2xvef9maXP/Z2p0/25xe/9zdXz/Z2p0/3N1fP9ucXv/am13/2ptd/9vcXX/ -b3F1/2xudf9zdXz/bG51/2tud/9ydHv/bXB6/29ye/9wc3z/d3qD/3l8hv95fIb/d3qD/3Bzff97fYP/ -dHeA/3h7gv95e4H/dHZ9/3t9g/91eIH/c3V8/3d6g/97fYP/foCG/36Biv9zdn//e32D/3V4gf93eoP/ -cHN9/3V4gf9zdn//dXiB/3N2f/9wc33/bnB3/25wd/9zdXz/dnh8/4CChv9sb3n/bnB3/25wd/92eHz/ -am13/3N2f/9zdXz/amxz/2ptd/9gY2z/bnF7/2dqdP9ucXv/cHN9/3V4gf9rbXX/bnF7/3R3gP9ydHv/ -c3Z//2ptd/93eX//cnV+/25weP9ydHz/bXB5/2dqcv9sb3n/bnF7/2psc/9maXP/bG95/2xvef9sb3n/ -am13/25wd/91d33/bG95/2xvef91eIH/d3qD/3Bzff93eX//dXiB/3Bzff9ucHf/c3V8/3N1fP9sbnX/ -bG95/2xvef9wc33/cHN9/3N1fP9qbHP/bW9z/2xudf9sbnX/c3V8/3d5f/9ucHf/am13/2xvef9zdn// -eXuB/3d6g/9ucXv/bnF7/3Byef95fIb/c3Z//3l8hv9wc33/dXiB/3l8hv91eIH/dXd9/3t+h/9ucXv/ -dXiB/3V4gf9wc33/bnF7/3N1fP91d33/d3qD/3d5f/9wcnn/dXd9/2dqdP9nanT/amxz/2Zpc/9iZW7/ -YmVu/2xudf9qbXf/cHN9/25xe/9nanT/cHN9/2ptd/9sbnX/am13/3N1fP9ucHf/Z2p0/25xe/93eoP/ -bG51/2ptd/9qbXf/bG95/2ptd/91d33/Z2p0/3Bzff9sb3n/cHJ5/3Byef91d33/Zmhu/3V3ff9zdXz/ -am13/25xe/9zdn//dXiB/3Bzff9ucHf/cHN9/25xe/9sb3n/dXd9/25wd/9wcnn/dnh8/3Byef9ucHf/ -bG95/3d5f/9wc33/cHJ5/25xe/91eIH/bnF7/3N1fP9sb3n/eXuB/3l7gf9wc33/dXd9/3l7gf93eX// -dXiB/36Ahv9zdXz/bnF7/3N2f/9wc33/eXyG/3l8hv92eHz/eXuB/35/g/95e4H/fX6B/3Bzff91eIH/ -dXiB/3Bzff93eoP/c3Z//25wd/93eoP/d3qD/3Bzff95e4H/am13/2xvef9ucHf/bG95/2xvef9zdn// -dXd9/2xvef9ucHf/c3V8/3+Bh/9sbnX/dXd9/2xudf9qbXf/eHl9/25wd/9sb3n/dXiB/3V4gf9zdXz/ -bnB3/2xvef9ucHf/cHJ5/25wd/9zdn//c3Z//3N1fP9+gIb/e36H/3V3ff9+f4P/fX6B/3Z4fP91eIH/ -c3Z//2xudf9sbnX/cHN9/2xvef9rbnj/dHZ8/3R2fP9ydHr/enyC/36Ahv97fYP/eXuB/3V4gf9wc33/ -enyD/3N2fv90dn7/cXN6/21vdv91d33/bG51/2dqdP9wcnn/cHN9/3Z4fP93eX//bnB3/3N2f/9sb3n/ -c3V8/2xvef9ucXv/bnB3/3N2f/9zdn//cHN9/25wd/9ucHf/c3Z//3l7gf+Bg4r/bnB3/25xe/9wc33/ -eXuB/3Bzff93eoP/d3qD/3Byef9zdn//Zmlz/3V3ff9wc33/dXd9/3N2f/95fIX/bG51/29xeP90d37/ -am13/3Bzff9sb3n/eHl9/3N1e/9rbnf/cXN7/25xe/9sb3n/dXiB/3V4gf9ucXv/bG95/3N2f/9ucXv/ -c3V8/2ptd/9sb3n/dXd9/25wd/9ucXv/dXiB/3l8hv9wc33/dXd9/3Bzff9zdXz/bnB3/3V3ff9wcnn/ -bG51/25wd/9ucHf/cHN9/3Bzff91d33/bW9z/2xudf9nanT/am13/25xe/9ucHf/Z2p0/2Rncf9qbHP/ -ZGdx/2dqdP9maG7/YmVu/2dqcf9maXP/cHJ5/2dqcf9sb3n/Z2px/2psc/9sb3n/amxz/2dqdP9zdXz/ -Z2p0/25xe/9zdXz/bG95/2xudf9ucHf/c3V8/3V3ff93eX//c3V8/3Z4fP9ucHf/cHJ5/3Byef9vcXX/ -am13/25wd/9ucHf/cHJ5/3Z4fP9wcnn/bG51/3N1fP9ucHf/bnB3/25wd/9zdn//bnF7/2psc/9ucXv/ -eXuB/29xdf9ucXv/bnB3/2xvef9qbXf/d3l//2xvef9zdn//dXiB/3Bzff9sb3n/cHN9/2Zpc/9zdn// -dXiB/2ptd/9wc33/dXiB/3N2f/9zdn//cHN9/3V4gf9zdn//c3Z//3t9g/95e4H/e32D/3t9g/95e4H/ -c3V8/3N1fP95e4H/cHJ5/2xvef9ucHf/cHN9/25wd/9sb3n/amxz/3N2f/9zdn//b3F1/25wd/9wcnn/ -bG95/25wd/9wc33/bG51/2psc/9ucXv/am13/3Bzff9ucXv/bG51/25wd/9zdXz/bnF7/3d6g/9zdXz/ -c3Z//3V4gf91eIH/e32D/3V4gf9zdXz/e32D/3d6g/9wc33/e36H/3Z4fP91eIH/dXd9/3V4gf9zdXz/ -eXuB/3t+h/9wc33/cHN9/3N2f/+Bg4r/bnB3/3V3ff9ucHf/bG51/3h5ff9vcXX/bG95/3V3ff91d33/ -bG51/2xudf9sbnX/Z2p0/2psc/9maXP/bG95/2dqcf9maXP/cHN9/3d5f/9nanT/cHN9/3N1fP9qbXf/ -bG51/2xudf9zdXz/c3V8/3l7gf9zdn//cHJ5/3Z4f/9wc3r/aGt1/2ptd/9wc33/amxz/2ptd/9qbXf/ -am13/3N1fP9rbnX/cHN8/3Fzev9wcnn/dXd9/3Byef9ucHf/c3V8/3Bzff9zdXz/dXd9/2xvef9zdXz/ -bnB3/3N1fP9ucHf/cHJ5/25wd/9zdn//dXiB/3N2f/9sb3n/bnF7/3N2f/91eIH/g4WM/3V3ff91d33/ -e32D/3+Bh/97fYP/f4GH/4WHjf97fYP/eXyG/3N2f/9+gYr/foCG/36Ahv99foH/gIKJ/3N1ev9zdX3/ -dXd+/2lrdf9ucXv/am13/3N1fP91d33/a254/3N1fP9xc3n/amxz/3Bzff9wc33/amxz/2Rncf9qbXf/ -bG51/2ptd/9qbHP/bnB3/3V3ff9sbnX/amxz/3V3ff93eX//cHJ5/3V3ff9ucXv/cHN9/2xudf9qbXf/ -bG95/2dqdP9sb3n/bG51/25xe/9wc33/cHN9/2dqdP9qbHP/am13/25wd/91d33/dXd9/3N1fP9ucHf/ -bG95/3Bzff9zdn//bnF7/2xvef9sb3n/bG95/3d5f/9sb3n/dXd9/25xe/9wc33/c3Z//29xdf9ucHf/ -dnh8/2psc/91d33/dXd9/25wd/9qbXf/bnB3/2xvef9wc33/bnF7/2dqdP9qbXf/Zmhu/2ptd/9sb3n/ -bG51/2dqdP9qbXf/bW9z/25wd/92eHz/cHJ5/2Zpc/9wc33/bG95/2xudf9nanT/bnF7/25wd/9qbHP/ -bnB3/3d5f/9tb3P/cHJ5/25wd/9ucHf/am13/3V3ff9qbXf/cHN9/3Bzff9ucHf/bnB3/3Bzff9maXP/ -c3Z//3N1fP9sbnX/cHJ5/3N2f/9wcnn/bnB3/25wd/9wcnn/cHJ5/3Byef91d33/bnB3/25wd/92eHz/ -c3V8/2xudf9qbXf/cHN9/2xudf9sbnX/bnB3/3Byef9qbXf/Z2p0/2Zpc/9ucXv/am13/2Zpc/9maXP/ -Zmlz/2Jlbv9nanH/Z2p0/2Rncf9maXP/bG95/2psc/9ucXv/bG95/2Rncf9qbXf/bG95/2ptd/9wc33/ -bW9z/2ptd/9ucXv/am13/25xe/9sb3n/bG51/3V3ff9sb3n/bG95/3N1fP9nanT/bG95/2ptd/9ucHf/ -bnB3/3Byef91d33/bW9z/21vc/9wcnn/f4GH/21vc/9wc33/am13/25wd/91d33/bG95/2xudf9zdXz/ -bnF7/2ptd/9tb3P/bnB3/2xvef9sb3n/bnB3/3d5f/9wcnn/bnB3/3h5ff93eX//bG51/3V3ff93eX// -bnB3/25wd/9ucHf/bnF7/3Bzff93eoP/eXyG/3N2f/97fYP/cnV//21wev9wc33/c3Z//2xvef9ucXv/ -bnB3/25wd/91d33/cHJ3/3V4gP91eIH/c3Z//3d6g/9zdn//bG95/3N2f/9zdn//dXiB/3d6g/9wc33/ -cHN9/3Bzff9ucXv/bnF7/3Bzff9wc33/dXiB/3N2f/9zdn//bnB3/21vc/9zdXz/dXd9/35/g/9ucHf/ -bG95/3V4gf93eX//bnF7/3d5f/93eoP/c3Z//25xe/9qbHP/cHN9/3Byef91d33/c3V8/3l7gf9sbnb/ -cXR8/3V4gv9wcnz/eXyG/3V3ff99foH/fH6F/3J1f/92eID/cXN6/2hrdf9wc33/dXd9/21vc/9nanH/ -cHJ5/3l7gf93eX//dXd9/3V4gf95e4H/c3V8/25xe/91eIH/eXyG/3N2f/95fIb/c3Z//3d6g/9wc33/ -cHN9/25xe/9sb3n/bG95/2xvef9zdn//c3Z//3d5f/9vcXX/bnB3/25wd/9wcnn/dXd9/3N1fP9ucXv/ -b3F1/2xvef9wc33/d3l//3N2f/9wcnn/cHJ5/2xvef91d33/bnF7/3d5f/9wcnn/d3qD/3d6g/9zdn// -c3Z//35/g/91d33/fX6B/31+gf91eIH/dXiB/3l7gf9+gIb/f4GH/36Ahv97fYP/fX6B/3d5f/95e4H/ -foCG/3d5f/93eX//dnh8/3N2f/91eIH/foCG/3t9g/9ucXv/d3qD/3N2f/9zdn//cHJ5/3V4gf9zdn// -cHN9/3V4gf95fIb/cHN9/25xe/9sb3n/bnF7/2ptd/92eHz/Z2p0/3Byef9ucXv/bG95/2xudf9zdXz/ -amxz/3V3ff9zdXz/am13/25xe/91eIH/c3Z//25xe/9ucXv/cHJ5/25xe/9ucXv/dXd9/2xvef9sb3n/ -c3V8/25wd/9sbnX/bG51/3Bzff9sbnX/bnB3/2psc/9wcnn/bW9z/2ptd/9nanT/cHN9/25xe/9nanT/ -ZGdx/2ptd/9kZ3H/amxz/2ptd/9sbnX/am13/2xvef9sbnX/cHJ5/3N1fP9qbHP/bG51/25wd/9ucHf/ -dXd9/2xudf9sb3n/cHN9/2ptd/9wc33/bG95/2xudf9wc33/bnB3/3Byef91d33/bG51/3N1fP9ucHf/ -bnB3/2xudf9zdXz/d3l//2psc/9qbXf/cHJ5/3+Bh/9sbnX/bnF7/2ptd/9vcXX/dnh8/3Byef9vcXX/ -dnh8/3N1fP9ucHf/b3F1/2xudf9tb3P/bG51/2xudf9wc33/bG51/21vc/94eX3/d3l//21vc/9zdXz/ -c3V8/2ptd/9sbnX/bG51/25wd/9wcnn/d3l//3N2f/9ucHf/c3V7/3N1fP9vcXj/bG95/3N2f/9ucXv/ -c3Z//2xvef9ucXv/c3Z//21wev92eYD/eHqB/3V3gP97fof/c3Z//3N2f/97fYP/eXuB/3d6g/97fYP/ -cHN9/3V4gf95e4H/cHN9/3V4gf91eIH/c3V8/3d6g/95e4H/dXiB/25wd/9wcnn/cHN9/3Bzff97fYP/ -b3F1/25wd/93eX//c3Z//25xe/93eX//dXiB/25xe/9ucXv/am13/3Bzff9ucXv/dXiB/3Bzff94e4X/ -b3F4/25xev91d33/aGt0/2xvef9sbnX/c3V8/3N1fP9tcHr/dXd9/3J0ff9wcnn/d3l//3V3ff9sb3n/ -am13/3Bzff9ucHf/bnF7/2xvef9ucXv/d3l//3Byef9sb3n/c3Z//3l8hv9wc33/eXyG/2xvef9wc33/ -bG95/3Bzff9ucXv/bG51/2xvef9sbnX/c3V8/3N1fP93eX//b3F1/29xdf9sbnX/bG95/3V3ff9zdXz/ -am13/2psc/9sbnX/bG95/25xe/9qbXf/Z2p0/2psc/9nanT/dXd9/2ptd/9zdXz/bG51/2xvef9qbXf/ -bG51/2xudf9zdXz/Z2p0/25xe/9qbXf/amxz/2Zpc/9qbXf/am13/25xe/9sb3n/am13/25xe/9sb3n/ -bG95/3Bzff9sbnX/bG51/2xudf9sbnX/bG95/3Bzff9sb3n/amxz/3Bzff9sbnX/bG51/2psc/9wc33/ -cHJ5/25wd/9ucXv/d3qD/3Byef91eIH/bG95/25xe/9qbXf/dXd9/2xvef9wc33/cHJ5/3N1fP9ucXv/ -cHN9/2xvef91eIH/dXiB/2psc/9sbnX/c3V8/2xvef9ucHf/cHJ5/25wd/9wcnn/bnB3/3V3ff9wcnn/ -bnF7/3N1fP9zdXz/am13/2xudf9wc33/am13/2psc/9maXP/bnF7/21vc/9ucHf/bnB3/3V3ff9wcnn/ -bG51/2psc/9ucHf/bG95/3Bzff91d33/bnB3/25wd/9wcnn/bG51/3Byef9ucHf/bnB3/2xvef9zdn// -bnF7/3V4gf9ucXv/cHN9/3V4gf9zdXz/dXiB/3Bzff9zdXz/dXiB/3Bzff93eoP/dXiB/25xe/9wc33/ -bnB3/2xvef9sb3n/dXd9/3l8hv9ucHf/bnB3/3N2f/+BhI3/c3V8/3N2f/9sb3n/c3V8/3l7gf91eIH/ -cHN9/3t9g/91eIH/c3V8/3Byef9ucXv/cHJ5/25xe/9ucHf/d3qD/3N2f/9wc33/e36H/36Biv9zdn// -eXyG/3l7gf9wc33/c3Z//25xe/9qbXf/bW9z/3V3ff9zdXz/bnB4/3N1fP9xc3j/bnB2/25wd/91d33/ -cHJ5/25xe/9ucHf/bnF7/25xe/9tb3f/cXR9/3N1fP9vcXn/d3l//3N1fP9qbHP/eHl9/3Z4fP92eHz/ -dXd9/2xudf9ucXv/cHN9/2xudf9ucXv/bG95/2xudf9ucXv/dXd9/2xudf9ucHf/b3F1/3N1fP9wcnn/ -e32D/25wd/9tb3P/c3V8/3N1fP9ucHf/dXd9/3V3ff9wcnn/cHJ5/2psc/9sbnX/bG95/3Bzff9wc33/ -dXd9/2xudf9tcHr/c3V8/2xvef9zdXz/b3F1/3Byef90dnz/bnB3/3J0ev9wc3v/bG95/3V4gf9zdn// -bG95/2xvef9ucXv/c3Z//25xe/9nanT/cHJ5/3d5f/9vcXX/Z2px/3V3ff94eX3/bnB3/3l7gf9sbnX/ -bG51/21vc/9zdXz/bnF7/25wd/9ucHf/bG95/3Byef9wcnn/dXd9/25wd/9vcXX/b3F1/25wd/91d33/ -bnF7/25xe/9sbnX/am13/25xe/9wc33/bG95/2dqdP9sbnX/amxz/3Z4fP9ucHf/bnF7/25wd/9wc33/ -bnB3/25wd/9vcXX/dnh8/25wd/92eHz/cHJ5/21vc/9ucHf/bnB3/3Byef9zdn//dXiB/3N2f/93eoP/ -cHN9/3Bzff9wc33/bG95/2xudf9sbnX/bG51/25wd/9wc33/bnF7/2Zpc/9sb3n/amxz/2dqdP9kZ3H/ -bG95/2ptd/9maXP/bnB3/3V3ff9sbnX/bG95/2xudf9ucXv/Z2p0/3N1fP9nanT/bG95/2xvef9ucXv/ -am13/2xvef9nanH/dXd9/3Byef9maXP/am13/25xe/9ucHf/am13/2xudf9tb3P/bG95/2psc/9ucXv/ -bnF7/2ptd/9wc33/cHN9/2Zpc/9sbnX/cHN9/2ptd/9qbXf/Zmlz/2ptd/9sbnX/Z2p0/2ptd/91d33/ -bnF7/21vc/9nanH/bG51/2dqdP9qbXf/bnF7/2psc/9nanT/bG95/2psc/9qbXf/bG95/2Jlbv9qbHP/ -am13/2psc/9sb3n/bG51/2xvef9wc33/am13/3Z4fP9vcXX/bG51/3Byef9ucHf/c3V8/3Byef9sbnX/ -c3Z//25wd/9qbXf/Z2p0/3Bzff95fIb/cHJ5/3N1fP9zdn//g4WM/3N1fP9wc33/am13/25wd/9zdXz/ -cHJ5/2xudf94eX3/cHJ5/2xudf9qbXf/am13/2xudf9sbnX/am13/3N1fP9ucXv/b3F1/3d5f/91d33/ -am13/3N1fP9wc33/Z2p0/2xvef9sbnX/bnB3/2ptd/94eX3/c3Z//25xe/92eYP/c3V8/21vdv9ucHf/ -cHN9/2xvef9sbnX/bG51/2xvef9rbnj/bXB6/3J1fv9ydX7/dHeA/3d6g/91eIH/cHN9/3t+h/97fYP/ -e36H/3l8hv9wc33/eXuB/3d6g/9ucHf/cHN9/25xe/9wcnn/dXiB/3d6g/9wc33/bnB3/25wd/9wc33/ -cHN9/3t9g/9sb3n/bW9z/3V3ff91d33/cHJ5/3l7gf94eX3/cHJ5/25xe/9qbXf/bnB3/25wd/91eIH/ -d3qD/3p8gv9xc3v/cHN9/3R3fv9ucHf/bnF7/25wd/9zdn//c3Z//25xe/9zdXv/bnF7/25wd/9zdn// -dXd9/25wd/9qbHP/bG51/3N2f/9sb3n/am13/2xvef93eX//bnB3/2ptd/9zdn//eXuB/3Byef95fIb/ -bnF7/25xe/9wcnn/c3Z//3Bzff9ucHf/bnB3/3Bzff9wcnn/cHJ5/3V4gf9ucXv/bnB3/29xdf9ucXv/ -dXd9/3N2f/9zdn//bnB3/2xvef9zdXz/dnh8/3V3ff9ucHf/cHJ5/25wd/92eHz/b3F1/3Byef9sbnX/ -am13/2ptd/9sbnX/am13/3N1fP9nanT/cHJ5/2psc/9nanT/Z2p0/2dqdP9qbXf/bG95/25xe/9qbHP/ -am13/2ptd/9nanT/Z2p0/2Zobv9kZ3H/Z2p0/2xudf9qbXf/cHN9/3N1fP9sbnX/bnB3/2xudf9ucHf/ -Z2p0/3N2f/91eIH/bnB3/3Byef93eX//bnB3/3Byef9sbnX/cHJ5/2ptd/93eX//bG95/2xvef91eIH/ -c3Z//29xdf9wcnn/amxz/3V3ff9ucXv/amxz/25wd/9ucXv/am13/3Byef9tb3P/bG51/2xvef9qbHP/ -bnF7/25xe/9sbnX/dXd9/3Bzff9nanT/bG51/25xe/9sbnX/amxz/2Rncf9nanT/Z2p0/2Zpc/9maXP/ -dXd9/25xe/9qbHP/YmVu/2xudf9qbXf/bG95/3N1fP9sbnX/bG51/25xe/9ucXv/bnF7/3N1fP9qbHP/ -cHJ5/25xe/9wcnn/d3l//29xdf91eIH/dXiB/3V4gf95e4H/c3V8/25wd/91eIH/bnF7/3N2f/93eoP/ -cHN9/3V4gf9ucXv/bG95/2ptd/9wc33/d3l//2xudf9ucHf/c3V8/35/g/9ucHf/bnB3/2dqdP9sbnX/ -cHJ5/25xe/9sbnX/cHN9/3Byef9tb3P/bG95/2xudf9vcXX/bnB3/2xvef9zdn//bnF7/2xvef95fIb/ -eXuB/25xe/95e4H/eXuB/3N1fP91eIH/d3qD/3N2f/9wc33/e32D/3N2f/9tcHn/d3qD/3N1ff9tcHr/ -cHN9/3d6g/9zdn//bG95/25wd/9ucHf/c3V8/3Byev9xdH7/dnmC/3R3gP97fof/eXuB/25xe/95fIb/ -d3l//3l7gf95e4H/bnB3/3d5f/93eoP/c3V8/3l7gf93eoP/c3Z//3l8hv93eoP/dXiB/3N1fP9zdXz/ -c3Z//3V4gf95fIb/cHN9/2xvef91d33/dXd9/3Byef93eX//eHl9/3Byef9ucHf/Z2p0/2xvef9ucXv/ -dXd9/3Z4fP91d33/a211/2ttdv9zdXv/a210/25xe/9tb3P/bnF7/25xe/9tb3f/cXR9/3J0ff9sb3n/ -c3Z//3V3ff9ucXv/am13/25xe/9sb3n/amxz/2Zpc/9sb3n/dXd9/2ptd/9kZ3H/bG95/3Byef9nanH/ -c3V8/2Zobv9sbnX/bG51/2ptd/9nanT/ZGdx/2Zpc/9maXP/ZGdx/2Zpc/9wcnn/Z2p0/2Jlbv9maXP/ -Z2p0/3Bzff9sb3n/bnF7/2psc/9qbXf/bnF7/3V3ff9wc33/am13/25wd/9qbHP/dnh8/25wd/9wcnn/ -bnF7/3Bzff9zdXz/cHN9/3N1fP95e4H/bnB3/3V3ff9ucXv/bG95/2xvef9ucXv/bG51/25wd/91d33/ -bnB3/25xe/9ucXv/am13/25xe/9sbnX/Z2p0/2xudf9nanT/Z2p0/2dqdP9sb3n/YmVu/2dqcf9nanH/ -ZGdx/2Jlbv9ucXv/Z2p0/2Zpc/9sbnX/c3V8/2xudf9sb3n/bG51/2xvef9kZ3H/c3V8/2xudf9sb3n/ -c3Z//2xvef9vcXX/bnB3/2psc/91d33/bnB3/2xudf9qbXf/cHJ5/2ptd/9wc33/bG51/2xudf9ucHf/ -bG51/25xe/9ucXv/am13/3N1fP9wc33/Zmlz/2dqcf9qbXf/Z2p0/2psc/9maXP/am13/2ptd/9sbnX/ -bG51/3Z4fP9sbnX/bnB3/2dqdP9ucHf/bnB3/25xe/9zdn//bnB3/2xvef9ucXv/bnF7/25xe/9zdn// -am13/3Bzff9zdXz/cHN9/3l7gf9wcnn/c3Z//3Z4fP9zdXz/eHl9/2xudf9sbnX/cHJ5/25wd/9wcnn/ -c3V8/2psc/9wcnn/am13/2dqdP9qbHP/bnB3/3d5f/9tb3P/bG51/3V3ff9+f4P/bnB3/3Byef9ucHf/ -b3F1/3V3ff9wc33/bG95/3Bzff9zdn//cHJ5/3N2f/9wc33/cHN9/3V4gf9zdXz/eXuB/3l7gf95e4H/ -g4WM/36Ahv97fYP/foCG/36Ahv9zdn//dXiB/3V4gf9wcnn/bnB3/3h5ff91d33/a254/3x+hf9ydX7/ -b3J6/3R3gP95e4H/cHN9/2xvef9vcXX/bnF7/3N2f/9tcHr/b3F4/3Fzev9sbnX/dnh8/3V3ff9nanT/ -dXd9/25xe/9zdXz/bnF7/2dqdP9wc33/cHN9/2xudf9sb3n/amxz/2dqcf9nanT/Z2p0/2ptd/9qbHP/ -Z2px/2xvef9nanT/c3Z//2Zpc/9kZ3H/Z2p0/2xvef9qbHP/cHJ5/3Byef9maXP/bG51/2dqdP9qbHP/ -am13/3Bzff9wc33/dnh//2ttdf9qbXX/cXN6/2ptd/9ucXv/Z2px/2ptd/9rbXf/bnF4/3J1fv91eID/ -bnF6/3l7gf91eIH/bnB3/2Rncf9sb3n/cHJ5/29xdf9qbHP/cHJ5/3Z4fP9nanT/Z2p0/2ptd/91d33/ -b3F1/3d5f/9tb3P/bG51/2xvef9wcnn/bnB3/2ptd/9sb3n/am13/2ptd/9nanT/cHJ5/2dqdP9nanT/ -Z2p0/25xe/91d33/bG95/2xvef9nanH/bG51/2xvef9zdXz/bnF7/2psc/9qbXf/Zmlz/3Bzff9qbXf/ -am13/2xvef9nanT/Z2px/2xudf9nanH/bG95/2dqdP91d33/bG51/2Zpc/9maXP/am13/2Zpc/9qbXf/ -cHJ5/2dqdP9sb3n/cHN9/2dqdP9qbXf/Z2px/2dqdP9qbXf/Zmlz/2dqdP9nanT/am13/2Rncf9qbHP/ -amxz/2psc/9kZ3H/cHN9/2ptd/9qbHP/am13/3Byef9qbHP/am13/2psc/9maXP/YGNs/25xe/9nanH/ -am13/3Bzff9sbnX/am13/2psc/9nanT/bnF7/2ptd/9zdn//c3Z//3l8hv93eX//fn+D/3N2f/9zdn// -eXyG/3V3ff93eoP/d3qD/25xe/95e4H/c3Z//2ptd/9ucHf/dXiB/3N2f/9wc33/bG95/25xe/9sb3n/ -bnB3/3Byef97fYP/c3Z//25xe/9nanT/bnB3/2xudf9ucHf/dnh8/25wd/9qbXf/bnF7/25xe/9wc33/ -bnF7/2xvef9ucXv/c3V8/25wd/9zdXz/bnB3/3V3ff92eHz/cHJ5/3V3ff9qbXf/bnB3/2xvef9ucHf/ -cHJ5/3Byef9nanT/cHJ5/25xe/9qbXf/bG51/25xe/91d33/bW9z/2xudf9wcnn/fX6B/2xvef9qbXf/ -Z2p0/2dqdP9ucXv/bnF7/2ptd/9sb3n/bG95/2xudf9nanT/Z2px/2Zpc/9maXP/Z2p0/25xe/9qbXf/ -Z2p0/3Byef9wcnn/ZGdx/25wd/9sb3n/Zmhu/2xvef9maXP/cHJ5/21vc/91d33/dXd9/2xudf93eYD/ -b3J5/2ptd/9sb3n/bnF7/2xvef9tb3P/bW9z/25wd/9zdXz/bnB3/3Bze/9zdn3/b3F1/3V3ff91d33/ -Z2px/3d5f/9ucXv/dnh8/3Byef9ucHf/dnh8/3N1fP9sb3n/bnF7/2xvef9qbHP/bnF7/25xe/9sbnX/ -b3F1/25wd/9zdn//bnB3/3t9g/9zdXz/bnB3/3V3ff9zdn//bnF7/3V4gf91d33/cHN9/25wd/9ucHf/ -b3F1/2xudf9wcnn/dXd9/3h5ff9ucHf/bnF6/3V2fP9tb3T/cHN9/25wd/9wc33/cHJ5/29xeP9xdHz/ -cnR6/2xudf9zdXz/bnF7/2ptd/9kZ3H/bG95/25xe/9ucHf/bG95/3Bzff95e4H/bnF7/25wd/9sb3n/ -dnh8/2xudf93eX//bG51/2xudf9qbXf/am13/2xudf9maXP/am13/2ptd/9qbXf/am13/3N1fP9qbXf/ -Zmlz/2psc/91d33/dnh8/3N1fP91d33/bG51/2dqcf9ucXv/cHN9/3Byef9sbnX/bnB3/2ptd/91d33/ -bnB3/3V3ff9sb3n/cHN9/25wd/9ucHf/am13/25wd/9ucHf/d3l//29xdf9sbnX/bG51/2ptd/9wc33/ -cHN9/3Bzff9sb3n/bG51/3Bzff9qbXf/bG95/2xudf9nanT/bG95/2xudf9nanH/Z2p0/2ptd/9nanT/ -Z2p0/2dqdP9sbnX/Z2p0/25xe/9qbXf/amxz/3Bzff93eX//bnB3/3Byef9sb3n/c3Z//2ptd/9zdn// -cHJ5/3Bzff97fYP/c3Z//3d6g/9zdn//dXd9/3d6g/9zdn//bnB3/3Byef9ucHf/cHJ5/3N1fP9ucHf/ -b3F1/3N1fP9tb3P/cHJ5/3N1fP9sbnX/bnF7/3N1fP9qbXf/bnB3/3V3ff9zdXz/c3V8/25wd/9vcXX/ -cHJ5/2xudf9qbXf/c3V8/25wd/9ucHf/Z2px/25wd/9sbnX/bnB3/3N1fP9tb3P/Zmlz/2xvef9qbXf/ -cHJ5/3Byef9ucHf/bG51/21vc/9sbnX/bnF7/2xudf9wc33/c3V8/2xvef92eHz/bG51/2ptd/9sbnX/ -bnB3/3N1fP9ucHf/Z2p0/2xvef9ucHf/bG51/2psc/9wcnn/dnh8/21vc/9sbnX/cHJ5/3l8hv9ucHf/ -dXd9/25wd/9sb3n/dXd9/3V3ff9sb3n/bnF7/3N1fP9sb3n/bnF7/2xvef9wcnn/c3V8/25wd/91eIH/ -d3qD/3V4gf93eoP/d3qD/3V4gf93eoP/eXuB/3Byef91eIH/c3Z//3Byef9vcXX/eXuB/3Z4fP9tb3b/ -d3qD/3N1fP9ucHf/bnF7/3N1fP9zdXz/b3F1/29xdf9vcXX/cHJ5/25wd/9tb3j/b3J5/21vc/91d33/ -dXd9/2dqdP91eIH/bnF7/3N1fP9nanT/Zmlz/25wd/9qbXf/Z2p0/2dqdP9maXP/ZGZs/2Zobv9nanT/ -Zmhu/2Rncf9maG7/Zmlz/2Rncf9wc33/Zmlz/2Rncf9sb3n/bG95/2psc/91d33/cHN9/25xe/9qbXf/ -am13/2psc/9sbnX/bG95/3V3ff9ydHz/bG5z/21vdP9wc3z/amx0/2xvef9qbXf/am13/2ptd/9rbXT/ -a252/21wef9sbnX/dnh8/3Byef9ucHf/amxz/25wd/9ucXv/bnB3/2xudf9ucHf/c3V8/2Zpc/9nanH/ -bG51/3N1fP9ucHf/d3l//2xudf9vcXX/bG51/2xvef9wc33/bnF7/3l7gf93eoP/cHN9/25xe/94eX3/ -bnB3/2xudf9qbHP/dXd9/3Z4fP91d33/eHl9/25wd/9vcXX/c3V8/3Byef9zdXz/bnB3/25wd/9sbnX/ -eHl9/29xdf91d33/bG95/2ptd/9qbXf/bG51/2dqdP9sb3n/ZGdx/3d5f/9qbXf/ZGdx/2Rncf9sb3n/ -cHJ5/3Byef9wcnn/cHJ5/25xe/9zdn//bnF7/3Bzff9ucHf/b3F1/3N1fP9sbnX/bG51/2xvef9zdXz/ -b3F1/3Byef9sbnX/b3F1/2xudf9zdXz/bnF7/3Bzff91eIH/e32D/3N2f/9zdn//c3V8/3d6g/9qbXf/ -cHN9/25wd/9ucHf/eHl9/3N1fP9ucHf/bnB3/25wd/9sb3n/cHJ5/2ptd/9sb3n/bG95/3Byef9zdXz/ -am13/2xudf9wcnn/bW9z/25wd/9sb3n/amxz/3V3ff9zdXz/bG51/2xudf9zdXz/cHJ5/2xvef9tb3P/ -am13/3N1fP9ucHf/bnB3/3V4gf9ucXv/c3V8/2ptd/9ucHf/bnB3/25xe/9zdn//bnB3/2xudf9wcnn/ -cHN9/3N2f/9wc33/bnB3/25xe/9ucXv/cHJ5/3N2f/9wcnn/d3l//3V4gf9wc33/d3l//2ptd/9ucXv/ -bnB3/3Bzff9wc33/cHJ5/25wd/9wc33/cHJ5/2xudf9ucHf/cHJ5/3h5ff9vcXX/bnB3/3Bzff97fof/ -c3Z//3V4gf9ucHf/bnF7/3l7gf91eIH/am13/3Bzff9zdn//bnB3/25wd/9ucHf/cHJ5/3N1fP9ucHf/ -c3V8/3N1fP9zdXz/dnh8/3Z4fP9zdXz/dXd9/3N1fP9sbnX/bnF7/2ptd/9wc33/bG95/3d6g/91d33/ -bnB3/3l6gP9wc3v/bW91/3Bzff9ucXv/bnF7/2dqdP9sb3n/am13/3Byef9ucHj/bW94/3Byef9ucHf/ -dXd9/3V3ff9sb3n/d3qD/3V4gf97fYP/c3Z//2xvef91eIH/c3Z//3N2f/9zdn//dXiB/2xvef9wc33/ -dXd9/25wd/9vcXX/cHJ5/3N1fP9sbnX/e32D/25wd/9qbXf/dXd9/3V3ff9tb3P/dXd9/25xe/9sb3n/ -Zmlz/2Rncf9maG7/amxz/2dqdP9ucHf/am13/2Zobv9pa3H/cHN5/21vdP9zdXz/bG51/3Byef9wcnn/ -a211/2tudv9ucHn/aGt0/3V3ff9sb3n/Z2p0/2Zpc/9ucXv/am13/2xudf9maXP/bG95/3Bzff9kZ3H/ -YmVu/2xudf9zdXz/bG51/3V3ff9ucHf/bnB3/25xe/9ucHf/bnB3/2psc/92eHz/cHJ5/25wd/9sb3n/ -d3l//3Byef9sbnX/bG51/3Byef92eHz/c3V8/3h5ff9ucXv/bnB3/3V4gf91eIH/dXiB/3Bzff9zdn// -cHJ5/3d5f/9sb3n/dXd9/3Bzff9wcnn/cHJ5/21vc/9ucHf/cHN9/2ptd/93eoP/bnB3/2psc/9nanH/ -b3F1/3N1fP9ucHf/cHJ5/3Byef9ucHf/dXd9/25xe/9ucXv/amxz/21vc/9wc33/bG51/29xdf9wcnn/ -cHJ5/25wd/9ucHf/bnB3/21vc/9qbXf/bG95/25wd/9ucHf/c3V8/3h5ff9sbnX/c3V8/2dqdP91d33/ -ZGdx/25xe/9qbXf/bnB3/3h5ff9wcnn/bG51/21vc/9qbXf/am13/2xudf9sbnX/bG95/2xvef9ucXv/ -c3V8/2dqdP9sbnX/am13/2dqcf9nanT/Z2p0/2Zobv9qbXf/am13/2Rncf9qbHP/am13/2xvef9sb3n/ -Z2px/2Zpc/9wc33/am13/2xudf91d33/cHJ5/3N1fP9sb3n/cHJ5/25xe/9zdn//bnF7/2xvef9sb3n/ -cHN9/3Byef9wc33/c3Z//25xe/9ucHf/bnF7/3Bzff93eoP/c3V8/3t9g/97fYP/dXiB/3l7gf9zdn// -d3qD/3V4gf93eoP/c3Z//3Bzff9wcnn/d3qD/3d6g/9wc33/c3V8/3N1fP95fIb/cHN9/3Bzff9zdn// -e36H/3Bzff9zdn//bG95/2xudf91d33/c3Z//2dqdP9sb3n/c3Z//2xvef9sb3n/bG95/25xe/9wc33/ -cHJ5/25xe/9zdn//dXiB/3d5f/95e4H/d3qD/3d6g/93eX//cHJ5/3N2f/93eoP/cHN9/2ptd/91d33/ -cHN9/2hrcv91eID/b3J7/2xueP9zdn7/cHN9/3Byef9ucHf/bnF7/2xvef9ucXv/cHJ6/21wef9tb3f/ -bG51/3N1fP9wc33/Zmlz/3V3ff9nanT/cHN9/25xe/9nanT/c3V8/25xe/9sb3n/bnF7/25xe/9qbXf/ -bG51/25xe/9nanH/Zmhu/2dqcf9nanT/ZGdx/3V3ff9qbHP/Z2px/25wd/9sb3n/Zmhu/25xe/9qbXf/ -bnF7/2Zpc/9qbHP/amxz/2xvef9sb3n/cHJ5/3Byef9oa3X/bG51/29ye/9tcHr/c3Z//25wd/9ucXv/ -dHZ9/21vd/9tb3b/b3F6/2xudf92eHz/dXd9/25wd/9maXP/cHJ5/2ptd/9sbnX/bG51/25wd/9zdXz/ -am13/2RmbP9tb3P/dXd9/2xudf92eHz/bW9z/2xudf9zdXz/bG51/2xudf9qbHP/dXd9/2xudf9ucHf/ -bnF7/3V4gf9wc33/am13/2dqdP9zdn//dXd9/3Bzff92eHz/bnF7/2ptd/9zdn//c3V8/3Byef9sbnX/ -cHJ5/2xudf91d33/am13/3Bzff9zdXz/cHJ5/3Byef9sbnX/amxz/25wd/9nanT/dXd9/2dqdP9kZ3H/ -ZGdx/2dqcf9qbXf/amxz/25xe/9qbHP/am13/3N1fP9sb3n/bnF7/21vc/9sbnX/bnF7/2xudf9sbnX/ -bG95/2xvef9qbXf/bG51/2xudf9vcXX/b3F1/25wd/9ucXv/bnF7/3V4gf95e4H/bnF7/3d5f/9wcnn/ -d3l//2dqdP9zdn//cHJ5/3Byef93eX//bnF7/2xvef9qbXf/b3F1/29xdf9vcXX/bG51/29xdf9sbnX/ -c3Z//3N2f/9ucXv/bnB3/3Bzff9zdn//c3Z//3N2f/9ucXv/dXiB/3V4gf9sb3n/bnB3/3Bzff9wc33/ -cHN9/3Byef9wcnn/d3qD/25xe/9sb3n/eHl9/3Byef9zdXz/amxz/2ptd/9sbnX/am13/2ptd/9sbnX/ -ZGdx/2xudf9nanT/bG51/2xudf9sbnX/Z2p0/2xudf9sbnX/cHJ5/2psc/9zdXz/cHN9/2ptd/93eX// -Z2p0/3Byef9ucHf/cHJ5/25xe/9qbXf/bnB3/3N1fP9zdn//Z2p0/29xdf9vcXX/dXd9/2xudf9ucHf/ -dXd9/3t9g/9ucHf/cHJ5/2ptd/9nanT/bnF7/3Bzff9maXP/bG51/3Bzff9nanT/am13/2ptd/9sb3n/ -am13/2psc/9nanH/am13/2xvef9wc33/cHJ5/2xvef9wc33/bnF7/2psc/9sb3n/bG95/3Bzff9qbXf/ -d3l//3d5f/9oa3L/d3l//3N1e/9sb3n/b3J8/3d6g/91eIH/cHN9/3d6g/9zdn//dnmC/3J1fP9rbnf/ -aWx2/2dpb/9qbXf/Z2p0/2Rncf9ucHf/Zmlz/2dqdP9nanT/ZGdx/25wd/9kZ3H/Zmhu/2dqdP9qbXf/ -ZGdx/2Rncf9nanT/Z2p0/2dqcf9nanH/Z2p0/2Jlbv9wcnn/amxz/2psc/9zdXz/bnF7/2xudf92eHz/ -bnF7/2xvef9maXP/amxz/2psc/9ucXv/bG95/3Z4fP91d33/bG95/2xveP9ydH3/cXN7/3V4gf9wcnn/ -c3Z//3R3gP9ucHf/bG93/21wef9oa3X/dXd9/25xe/9sbnX/bG51/3Byef9sb3n/bnF7/3N1fP9wc33/ -c3Z//2xvef9nanH/bnB3/3d5f/9sb3n/d3qD/2xvef9wc33/dXiB/25wd/9sb3n/bG51/3V3ff9ucHf/ -bG51/2xvef91d33/bnF7/2ptd/9maXP/c3V8/3N1fP9wcnn/dnh8/2xudf9sbnX/c3V8/25xe/9wc33/ -bnF7/3Bzff9zdXz/dXiB/25xe/91eIH/dXiB/3Bzff91eIH/dXiB/3Bzff97fYP/c3Z//36Biv91d33/ -am13/2xvef9ucXv/cHN9/2xvef9zdXz/bnB3/3Bzff91d33/cHJ5/3Bzff9qbHP/amxz/25xe/9qbHP/ -Z2px/2xvef9sb3n/bG51/2xudf9nanT/bG51/2psc/9sb3n/am13/2xvef91d33/dnh8/2ptd/9zdXz/ -bG51/25xe/9kZ3H/bG95/2xudf9sbnX/dXd9/2xvef9qbXf/am13/29xdf9ucHf/b3F1/2xudf9ucHf/ -b3F1/3N1fP9zdXz/cHJ5/3N1fP92eHz/cHJ5/3Byef9zdXz/bG51/3V3ff9zdXz/amxz/21vc/9ucXv/ -bG95/2xvef9nanT/Z2px/2ptd/9nanH/Z2px/25xe/9nanT/ZGdx/11gav9gY2z/Zmhu/2Rncf9maXP/ -ZGZs/1xfaP9maXP/YmVu/2Rncf9kZ3H/Zmlz/2psc/9qbHP/bG95/2ptd/9maXP/cHN9/3Bzff9qbXf/ -dXd9/2Zpc/9ucXv/bG95/3N1fP9zdXz/bnB3/2xvef9wc33/c3Z//2xudf9sbnX/bW9z/3N1fP9qbXf/ -bG51/3V3ff97fYP/b3F1/3N1fP9sbnX/bG51/25wd/9zdn//bG95/3Bzff91eIH/cHN9/3Bzff9zdn// -c3V8/21vc/9ucHf/bG51/3Byef9zdXz/dnh8/3Z4fP9zdXz/dnh8/3N1fP9ucHf/c3V8/3Byef9zdXz/ -am13/3h5ff93eX//b3F1/3p9g/9vcnr/bW92/25xe/9zdXz/cHN9/2xudf9sb3n/am13/2xudf9qbXb/ -a254/2tud/9sb3n/c3V8/3Byef9vcXX/d3l//3V3ff9zdXz/cHJ5/29xdf92eHz/cHJ5/25wd/9wcnn/ -cHN9/25wd/9ucHf/c3V8/3N1fP9tb3P/bG51/2xvef9nanT/c3V8/2xudf9sb3n/dXd9/3Byef9ucHf/ -d3l//3Byef9zdXz/amxz/25wd/9sb3n/dXd9/3N2f/93eX//dXd9/3J1fv9sb3j/bW94/2psc/9wc33/ -amxz/2ptd/9sb3n/aGtz/2ttdf9vcnz/bW92/3h6gP9zdn//c3V8/25wd/9zdXz/Zmlz/2Rncf9gY2z/ -Zmhu/2Zpc/9gY2z/XWBq/2Rncf9sb3n/ZGdx/3Byef9kZ3H/am13/2dqdP9iZW7/Zmhu/2Jlbv9nanT/ -amxz/2psc/9sbnX/c3V8/25xe/9qbXf/Z2p0/2xvef9ucXv/c3V8/3V3ff9sbnX/bnB3/3N1fP9sb3n/ -cHN9/25xe/9wc33/cHJ5/3V4gf9zdXz/c3Z//3V4gf9zdXz/c3Z//3N2f/9ucXv/d3qD/25wd/95e4H/ -am13/2ptd/9qbXf/bnF7/25xe/9sb3n/c3Z//3N2f/91eIH/eXyG/3N2f/91eIH/bnB3/25wd/92eHz/ -bnB3/29xdf91d33/c3Z//25xe/9wcnn/am13/2xvef9ucHf/bG95/2xvef9ucXv/dXd9/3Z4fP9vcXX/ -dnh8/2ptd/9ucXv/YGJo/2psc/9qbXf/bG51/3d5f/9tb3P/bW9z/2xudf9vcXX/bG51/2xudf9ucHf/ -bG51/29xdf91d33/dXd9/3N1fP9sbnX/dXd9/25xe/9qbXf/cHN9/2psc/9sb3n/Z2p0/2Rncf9maG7/ -ZGdx/2Zpc/9nanT/Zmhu/2dqcf9sb3n/am13/21vc/92eHz/cHJ5/2xudf9sbnX/Zmlz/2psc/9nanT/ -am13/2xudf9maXP/bnF7/2dqdP9tb3P/cHJ5/2xudf9sbnX/bG51/2xudf9wcnn/amxz/3N1fP9zdXz/ -bG51/3Byef9iZW7/am13/2ptd/9sb3n/Z2p0/2xudf9nanT/bnF7/25xe/9maXP/Z2p0/2xudf9wc33/ -Z2p0/2Zpc/9sb3n/c3Z//2ptd/9ucXv/am13/2psc/9ucXv/cHN9/2dqdP9sb3n/bnB3/25wd/9wcnn/ -cHJ5/3N1fP9sbnX/am13/2ptd/9ucXv/c3V8/3h5ff9zdXz/cHJ5/3Bzff9ucXv/bnB3/3N1fP9ucXv/ -d3l//2xvef92eHz/eXuB/2xudf96fIP/bnF5/2xudf9sb3n/c3V8/25xe/9nanT/Z2p0/2xudf9sbnX/ -bW93/21veP9vcXn/am13/3Byef9wcnn/am13/3V4gf9wc33/c3V8/2xvef9sbnX/c3V8/3Byef9wcnn/ -cHJ5/3V3ff9wcnn/bnB3/25wd/9sb3n/bG95/2ptd/9nanT/Z2p0/3Bzff9sbnX/amxz/3N2f/9sb3n/ -Z2p0/25xe/9qbXf/bnF7/2dqcf9tb3P/bG51/3h5ff9wc33/c3Z//3d5f/9ucXv/a251/2lsdv9nanT/ -bnF7/2psc/9qbXf/bnF7/21vd/9ucXv/cHN8/2xudf93eX//cHJ5/21vc/9tb3P/c3V8/3N1fP9wcnn/ -bG95/2xvef9zdn//am13/2dqdP9wc33/eXuB/3Bzff97fYP/c3V8/3N2f/9zdn//bG95/2xvef9sbnX/ -c3V8/25wd/9ucHf/bG51/3V3ff9ucXv/bG51/2psc/9wc33/cHN9/3N1fP93eoP/bnB3/29xdf9wc33/ -bG95/2ptd/9qbHP/amxz/2Zpc/9sb3n/bG51/2xvef9ucXv/am13/2xvef9qbXf/bG51/3V3ff9sbnX/ -d3l//2ptd/9maXP/Zmlz/2ptd/9qbXf/Zmlz/2psc/9maG7/Z2p0/3Byef9qbHP/bG95/2dqcf9nanT/ -bG95/2Jlbv9gY2z/Zmlz/2Zpc/9maG7/Zmhu/2dqdP9kZ3H/Z2px/2dqcf9qbXf/am13/3Bzff9wc33/ -bG51/3N1fP9sbnX/c3V8/2Vmav9ucHf/bG51/2xudf95e4H/b3F1/29xdf9qbHP/bW9z/21vc/9ucXv/ -bnB3/3Byef9ucHf/d3l//3V4gf95e4H/dXiB/3l7gf9wc33/dXiB/3d6g/9wc33/eXuB/3l7gf9ucXv/ -cHJ5/3Bzff9ucXv/cHN9/25wd/9ucHf/c3Z//25xe/9ucXv/eXuB/3V4gf9wc33/cHJ5/2xvef9wc33/ -c3Z//3d6g/91eIH/cHN9/3d6g/9wc33/bnF7/3V4gf9zdn//cHN9/3Bzff9zdn//d3qD/3Bzff95fIb/ -e36H/3N2f/97fYP/cHN9/3t9g/9zdn//c3Z//3N2f/9sb3n/bG95/3N2f/9wc33/bG95/2xudf9ucHf/ -dXd9/2xudf9ucHf/cHN9/3t9g/9ucXv/cHN9/25wd/9sbnX/bnF7/25xe/9qbHP/bG51/25wd/9ucHf/ -bG95/3V4gf9zdn//cHN9/3N1fP9ucHf/cHN9/3N2f/93eoP/c3Z//3V4gf91eIH/cHN9/25xe/9wc33/ -cHJ5/3Z4fP9wcnn/d3l//3t+h/9ucXv/fX+G/3Fze/9rbnf/cHJ5/3N1fP9zdXz/bG95/2ptd/9qbHP/ -aGpx/2ptdP9sb3n/cnV+/21wev91eIH/c3Z//3Byef9/gYf/d3qD/3l7gf9zdn//cHN9/3V4gf9zdn// -c3Z//3t9g/93eoP/eXuB/3V4gf9zdn//dXiB/3N2f/9sb3n/bnF7/2xvef95e4H/cHN9/3N2f/95fIb/ -cHN9/29xdf9wc33/bG95/3N1fP9maXP/bW9z/3Byef92eHz/dnh8/3V4gf94eX3/cnR7/21veP9vcXj/ -a21z/3Z4fP9sbnX/bnF7/2xvef9rbnX/b3J6/3F0ff9qbXf/dXiB/3N2f/9sb3n/cHJ5/3Bzff9zdn// -cHN9/2xvef9ucHf/dXd9/2psc/9qbHP/cHJ5/3N1fP9vcXX/dnh8/25wd/9wcnn/c3V8/2ptd/9wcnn/ -cHJ5/3d6g/9wc33/bnF7/2xvef91d33/c3V8/21vc/9tb3P/dXd9/3Bzff9zdXz/c3Z//2xudf9nanT/ -bnF7/2ptd/9qbXf/Z2p0/2psc/9qbHP/bG95/2xudf9wc33/bnF7/2ptd/9ucXv/bG51/2dqdP9ucXv/ -Zmlz/3V4gf9qbXf/Zmlz/2psc/9tb3P/bG51/2psc/9sbnX/am13/25xe/91d33/b3F1/3Byef9vcXX/ -cHJ5/3Z4fP9ucHf/am13/3Byef9wcnn/bG51/2ptd/9sbnX/am13/2ptd/9nanT/cHN9/25wd/91d33/ -dXd9/2xudf91d33/bG51/3V3ff9nanH/cHJ5/2xvef9sb3n/eXuB/25wd/9ucHf/Z2px/21vc/9tb3P/ -c3V8/2psc/9tb3P/bG51/3V3ff9wcnn/dnh8/3Bzff92eHz/cHJ5/25xe/91eIH/bnF7/3V4gf9wc33/ -am13/25wd/9wc33/bnF7/3Bzff9vcXX/bnB3/3V4gf9ucXv/cHN9/3d5f/9wc33/cHJ5/2xvef9qbXf/ -cHN9/25xe/9ucXv/c3V8/2ptd/9zdn//bnB3/2xudf91d33/bnF7/2xudf9sbnX/cHJ5/25xe/9sbnX/ -cHJ5/3V3ff9tb3P/dXd9/2dqdP9zdXz/am13/2xvef9sb3n/am13/2Rncf9sb3n/am13/2Jlbv9qbHP/ -am13/3N1fP9qbHP/bG51/3Byef9+gIb/cHJ5/3Byef9sbnX/bG51/25wd/9wc33/Zmlz/2ptd/9qbXf/ -am13/2ptd/9ucXv/dXd9/3Byef9vcXX/b3F1/3N1fP9zdXz/eXuB/25wd/9zdXz/cHJ5/2xvef9sb3n/ -cHJ5/2ptd/91d33/bG51/3V3ff95e4H/b3F1/36Bif9ydHv/bG52/3N1fP9zdXz/dnh8/3V3ff9ucHf/ -bG51/25wd/9rbnj/cXN6/3V3gP9wcnn/cHN9/3N2f/9zdXz/f4GH/25xe/95e4H/cHN9/3N1fP95fIb/ -d3qD/3Bzff93eoP/cHN9/3N2f/9ucXv/bnF7/3Bzff9wc33/bnF7/3Bzff9wcnn/d3qD/3Bzff9wc33/ -d3qD/3V4gf9wc33/dXiB/3V4gf91eIH/am13/3Bzff9wc33/eXuB/3N2f/95e4H/eXuB/3Z4gf9vcnz/ -b3J4/21wev91d33/bnB3/3Bzff91eIH/b3J5/3Bzff9xc3r/bnB3/3d5f/9zdn//bG95/2xvef9ucXv/ -dXd9/3Byef9qbXf/bW9z/3V3ff9nanH/bG51/25xe/9ucXv/bW9z/3Z4fP9sbnX/bG95/25xe/9nanT/ -bG51/2ptd/9wc33/bG51/25wd/9ucHf/cHJ5/25xe/9sbnX/bG51/3V3ff9zdXz/dXd9/3l7gf9wcnn/ -bnB3/3V4gf9wc33/cHN9/2xvef9ucHf/am13/25xe/9sb3n/c3Z//3N2f/9sb3n/bnB3/25wd/9sbnX/ -c3V8/2xudf97fYP/bnB3/2xudf9qbXf/am13/25wd/9nanT/am13/2dqdP9sb3n/dXd9/2psc/9qbXf/ -Z2p0/2xudf91d33/bG51/2dqdP9wcnn/cHN9/2xudf9qbHP/am13/2ptd/9sb3n/Z2p0/2xvef9nanT/ -bG95/2xvef9maXP/am13/2psc/9ucXv/YmVu/2xudf9nanT/am13/3V3ff9qbXf/am13/2Rncf9sbnX/ -am13/2ptd/9ucHf/bnB3/2ptd/91d33/c3Z//3V3ff9wc33/dXd9/3Bzff9wc33/c3Z//25xe/91eIH/ -cHN9/2xudf9ucHf/bnB3/25wd/9wcnn/bG51/2xudf9wcnn/bG51/3Byef94eX3/bG51/2xudf9nanT/ -ZGdx/2xudf9sb3n/cHJ5/3Byef9tb3P/bnF7/2psc/9qbHP/cHN9/25xe/9sbnX/am13/25xe/9ucXv/ -am13/2xvef9wc33/bW9z/3V3ff9nanH/c3V8/25xe/9wcnn/c3V8/3N1fP9qbHP/bnB3/25xe/9qbHP/ -amxz/2psc/9ucXv/Zmlz/2psc/9sb3n/dXiB/2ptd/9ucXv/am13/2xudf9sbnX/c3V8/2Zpc/9qbXf/ -bnB3/25wd/9zdXz/c3V8/3N1fP9sb3n/bG51/2ptd/9wcnn/cHJ5/3l7gf9ucHf/dXd9/25wd/9zdXz/ -bG51/25xe/9sbnX/c3V8/2ptd/92eHz/dXiB/2xudf97fYT/cXN6/2dqc/9qbXf/am13/3Bzff91d33/ -bnB3/2xvef9sb3n/bG94/21wd/91d3z/bG51/3Byef9ucHf/bG51/3l7gf9qbXf/dXd9/2xudf9nanH/ -d3l//2ptd/9sb3n/bnF7/2ptd/9ucXv/amxz/2xudf9qbXf/bG95/3Byef9ucHf/bG51/3V3ff9sb3n/ -bnB3/3d6g/9wc33/bnF7/3N2f/9ucXv/bnF7/2dqdP9sb3n/bnF7/3l7gf91eIH/d3qD/3Z4fP9ydHv/ -a252/2xudP9qbHP/c3V8/21vc/9wcnn/cHJ5/25wd/9sbnX/a212/2Nmb/9sb3n/Z2p0/2Zpc/9sbnX/ -bG95/3V3ff9ucXv/bG95/29xdf93eX//Zmlz/25wd/9wcnn/c3V8/3Byef97fYP/c3V8/3Bzff91eIH/ -bG95/25xe/9wcnn/dXiB/3Bzff9wcnn/bnB3/25xe/91d33/bnB3/2xudf91d33/dXd9/3N1fP94eX3/ -bnB3/29xdf92eHz/cHJ5/3Byef9qbHP/b3F1/2psc/9ucHf/bnB3/3N2f/91eIH/cHN9/3Bzff9ucHf/ -cHJ5/3Bzff9sb3n/dXiB/25wd/9ucHf/b3F1/25wd/9wcnn/bG51/3Byef9sbnX/bnB3/3Z4fP9tb3P/ -bG51/2psc/9qbXf/d3l//2xudf9kZ3H/am13/25xe/9qbXf/Z2px/2dqcf9maXP/bG95/2dqdP9ucXv/ -bnF7/25xe/9wc33/bG51/25xe/9tb3P/dnh8/2Zpc/9ucXv/am13/2ptd/93eX//bG95/2xvef9qbHP/ -bnB3/29xdf9zdXz/bG51/2ptd/9qbXf/cHN9/25wd/9wc33/bnF7/3N1fP9wcnn/bnB3/25xe/9qbXf/ -bG95/25xe/9nanT/am13/2ptd/9qbHP/Z2p0/2psc/9nanT/bG95/2Zpc/9sb3n/dnh8/21vc/9sbnX/ -bG51/2xudf9ucHf/bnB3/3Byef9wc33/bnB3/3V3ff9ucHf/bnB3/3V4gf91eIH/cHN9/25xe/91eIH/ -d3qD/3Byef91eIH/c3Z//25wd/92eHz/amxz/3Z4fP9wcnn/c3V8/3N1fP9zdXz/amxz/25wd/9wcnn/ -bG51/2ptd/9sbnX/c3V8/2psc/9vcXX/cHJ5/3V3ff9wcnn/cHJ5/25wd/9ucHf/bnB3/3V3ff9nanH/ -bG95/2xvef9qbXf/c3Z//3N2f/95e4H/dXiB/3Bzff9zdn//dXiB/3d6g/+Bg4r/d3l//35/g/97fYP/ -fn+D/3V3ff95fIb/c3Z//3l7gf9ucHf/dXiB/3V4gf9tcHr/fYCH/3V3fv9wc3v/dXeA/3Bzff97fYP/ -e32D/25xe/9ucHf/cnR7/21wev9tb3f/a254/2Zobv9maXP/Z2px/2dqcf91d33/amxz/2xvef9sbnX/ -Z2px/3Byef9sb3n/bG95/2xvef9sbnX/bnB3/29xdf9vcXX/bnF7/25xe/91eIH/bnF7/25wd/9ucXv/ -cHN9/3Byef95e4H/cHN9/3N2f/91eIH/c3Z//25xe/9sb3n/c3Z//3d6g/97fYP/d3qD/3l8hv95e4H/ -dXiB/3F0fv9ucHf/aGt0/2xvef9sbnX/bG95/2hrdf9rbXf/a254/3F0fP9ucXv/en2D/3l7gf9wc33/ -cHN9/3Bzff9wc33/bnB3/29xdf9vcXX/dXd9/2Zobv9tb3P/bnF7/25xe/9sbnX/dXd9/25wd/9wcnn/ -cHJ5/2dqdP9qbXf/bW9z/3Z4fP9sbnX/amxz/2dqdP9qbXf/bnF7/2Zpc/9maXP/cHN9/3N1fP9sb3n/ -dXd9/2psc/9maXP/bG95/2xudf9qbHP/Zmlz/2dqdP9maXP/bG51/2dqdP9ucXv/bnF7/2ptd/9qbXf/ -Zmlz/2dqcf9qbXf/Zmlz/3N1fP9nanT/amxz/2psc/9sbnX/am13/2dqdP9maXP/Zmlz/2psc/9zdXz/ -bG51/2xudf9iZW7/Z2p0/3N1fP9qbXf/Zmlz/2ptd/9sb3n/am13/2dqcf9kZ3H/Zmlz/25xe/9nanT/ -am13/2xvef9qbXf/cHN9/2Zpc/9nanT/Z2p0/25xe/9gY2z/Zmlz/2Rncf9iZW7/cHJ5/2xvef9nanT/ -Z2px/2ptd/9qbHP/am13/21vc/9sbnX/Zmlz/3Bzff9nanT/bnF7/2xvef9ucXv/bG95/2ptd/9ucXv/ -bG51/2xvef9sb3n/Zmlz/2dqdP9qbXf/Zmlz/2dqdP9maG7/Zmlz/2ptd/9nanH/am13/3Byef9kZ3H/ -Z2px/2Zobv9iZW7/Zmlz/2xudf9qbXf/am13/2xudf9ucXv/amxz/2psc/9ucXv/bG95/2dqdP9nanH/ -bG95/3Bzff9sbnX/Z2p0/2xvef9qbHP/c3V8/2dqdP91d33/bnB3/3Z4fP92eHz/bnF7/2psc/9sbnX/ -cHJ5/21vc/9wcnn/cHJ5/3V3ff9ucHf/bW9z/3V3ff93eX//bnF7/25xe/9sbnX/bG51/3Byef9wc33/ -Zmhu/25wd/9ucHf/Z2p0/2ptd/9wcnn/c3V8/2xudf9vcXX/bnB3/3Byef9zdXz/eXuB/2xudf91d33/ -dXd9/3V3ff9ucHf/c3V8/25wd/91d33/bnB3/3d6g/91eIH/bnB3/3t9hP9wc33/a212/3Bzff9wc33/ -dXiB/3l7gf9wc33/cHJ5/3N2f/9ucXv/b3F6/3V3ff9tb3P/dXd9/25wd/9ucHf/d3qD/25wd/9zdXz/ -bnB3/21vc/92eHz/bnB3/3Byef9wcnn/bnB3/3N1fP9ucHf/bnB3/25wd/9vcXX/dXd9/25wd/9tb3P/ -bG51/2ptd/9qbHP/cHN9/2xvef9qbXf/bnF7/2dqdP9qbHP/YmVu/2Zpc/9qbXf/Z2p0/2Zobv9qbXf/ -Z2pz/2dqc/9pbHP/a21y/2ttdP90dnz/bnB3/2xvef9tcHr/bnF7/2ptd/9maXH/ZWhy/2xvef9sb3n/ -YGNs/2Zobv9kZmz/d3l//3N2f/9ucXv/c3V8/3t+h/9sb3n/c3V8/3V4gf95fIb/eHl9/31+gf9zdXz/ -dXiB/3d6g/9ucXv/cHN9/3Bzff93eX//bnB3/2xvef9ucHf/bG95/3Z4fP9qbXf/bG95/3V3ff94eX3/ -cHJ5/3V3ff9wcnn/am13/3N1fP9tb3P/am13/2Zpc/9nanT/am13/21vc/9sbnX/c3V8/3V3ff9zdn// -c3Z//3Byef9zdXz/eXuB/3Bzff95fIb/c3V8/3N2f/9wc33/c3Z//3V4gf92eHz/e32D/3V3ff9zdn// -eXyG/3N2f/9zdn//bnF7/3V4gf93eoP/bnF7/2ptd/9zdXz/c3V8/3Byef9vcXX/bG51/2xvef91d33/ -bG51/3Byef9ucXv/am13/25xe/9qbHP/am13/2dqdP9ucXv/XWBq/2ptd/9nanT/Zmlz/3N1fP9sb3n/ -am13/2dqdP9sb3n/bG51/25wd/9tb3P/bW9z/2dqcf92eHz/cHJ5/3V3ff9zdXz/cHJ5/3Bzff9wc33/ -c3Z//3Bzff9zdn//c3Z//2xvef9qbHP/bnB3/25wd/9zdXz/bW9z/2xudf9zdXz/b3F1/3N1fP94eX3/ -bnB3/2xudf9vcXX/Z2px/2psc/9wcnn/bnB3/25wd/9ucHf/cHN9/2dqdP9sbnX/cHN9/3N1fP9sb3n/ -amxz/25xe/9ucXv/bG51/2ptd/9ucXv/bG51/3Z4fP9qbHP/dnh8/25xe/9zdn//c3Z//3Bzff9qbHP/ -bnB3/3N1fP9tb3P/bnF7/2ptd/91d33/bnB3/25wd/9wcnn/dnh8/3N1fP9wcnn/bnB3/25wd/9wc33/ -dXiB/2dqdP9wcnn/c3V8/2xvef9wc33/cHN9/3N2f/9ucHf/b3F1/29xdf9zdXz/cHJ5/3l8hv9sb3n/ -dXiB/3N1fP92eHz/bW9z/3Byef9ucHf/dXd9/25wd/95fIb/d3l//21vc/96e4H/b3F5/2Zpcv9sbnX/ -am13/3Byef94eX3/bnB3/25wd/9zdXz/cHJ3/3Fzev91d3v/bW9z/3N1fP9zdXz/b3F1/3t9g/9ucHf/ -cHJ5/25xe/9sbnX/c3V8/2ptd/9sb3n/am13/2ptd/9qbXf/bW9z/2xudf9sbnX/b3F1/3N2f/9ucXv/ -bnB3/2xvef9sb3n/bnB3/3Z4fP9wcnn/bnB3/3Byef9ucHf/bnB3/2psc/9wcnn/c3Z//3V4gf9wc33/ -e32D/3N2f/90d4D/bnF7/25xef9rbnf/c3Z//3Byef9wcnn/bnF7/3N2fv9xdHv/bG95/2hrdf9wc33/ -bG95/2Rncf9qbXf/bG51/3h5ff9zdXz/cHJ5/25wd/93eoP/am13/25xe/9ucXv/cHN9/2xvef9zdn// -bG95/25xe/9zdXz/bG51/25wd/9wcnn/d3l//2dqdP9iZW7/Zmlz/2ptd/9zdXz/am13/2xudf9wcnn/ -d3l//25wd/91d33/bnB3/2ptd/91d33/b3F1/2psc/9nanH/b3F1/2xudf9vcXX/b3F1/3Byef91d33/ -bnB3/25wd/9sbnX/bW9z/3N1fP9nanT/d3l//2xudf9qbXf/amxz/2psc/9nanH/Zmhu/2dqdP9kZ3H/ -YmVu/2xudf9gY2z/Zmhu/2BjbP9maXP/bG51/2Rncf9iZW7/Zmlz/2Rncf9maXP/Zmhu/2Rncf9nanT/ -bnF7/2dqdP9sb3n/bnF7/2xvef9ucXv/Z2p0/25xe/9ucXv/c3V8/2Zobv9wcnn/bnB3/2Zpc/91d33/ -bnF7/25wd/9qbHP/bnB3/2ptd/9sb3n/amxz/2dqdP9iZW7/bnF7/2dqdP9zdXz/bnF7/2xvef9wc33/ -bG95/2xvef9sbnX/am13/2ptd/9maXP/YmVu/2xvef9ucHf/c3V8/21vc/9sbnX/cHJ5/2ptd/9wc33/ -dXd9/25wd/9wcnn/bW9z/2Zobv9qbXf/dXiB/25xe/9sb3n/bG95/3N2f/9wcnn/cHN9/3V3ff91d33/ -bnF7/2xvef91d33/bnF7/2xudf9qbXf/am13/2xudf91d33/am13/3N1fP9ucXv/bG95/2xvef9qbXf/ -ZGdx/2dqcf9maXP/Z2p0/2xvef9qbXf/Z2p0/2dqcf9qbHP/bG95/3N1fP9wc33/bG95/2ptd/9tb3P/ -bnB3/3Bzff9maG7/bG51/2xudf9sbnX/bnF7/25xe/91eIH/cHJ5/3N1fP9ucHf/dXiB/3N2f/95e4H/ -c3Z//3d6g/9wc33/eXuB/25xe/9wcnn/c3Z//3Z4fP9ucHf/eXuB/3d5f/9wcnn/fH2C/3F0fP9wcnz/ -c3Z//3N2f/93eoP/eXyG/3Bzff91d33/eHuF/3N1e/9ydHn/cHN9/2tud/9qbXf/am13/2dqcf9zdn// -bG51/25xe/9ucXv/bG51/3N1fP9sb3n/bG95/2xudf9vcXX/bG95/25wd/9sb3n/bnF7/25wd/9zdn// -bG95/25wd/9ucHf/cHJ5/29xdf92eHz/bnF7/2xvef9ucXv/cHN9/25xe/9sb3n/c3Z//3N2f/91eIH/ -cHN9/3l7gf9zdn//c3Z//25weP9ucXn/bG51/3Byef9vcXX/bG95/25wd/9zdXz/cXN6/2lsdP9ucHf/ -dnh8/25xe/9nanT/bG51/25wd/92eHz/c3V8/3N1fP9sbnX/dnh8/2xudf9ucHf/bnF7/3N1fP9ucHf/ -dXd9/25wd/9wc33/dXiB/25xe/9sb3n/cHN9/3d6g/9ucHf/bG95/3Byef9wc33/eXuB/25xe/9wcnn/ -cHN9/3V4gf9ucHf/dXd9/25wd/9wcnn/dXiB/25xe/9sb3n/Z2p0/2xvef9qbXf/bnB3/29xdf9ucHf/ -dXd9/25wd/9ucHf/bnB3/25wd/9wc33/am13/3d5f/9ucHf/bnB3/25wd/9sb3n/cHJ5/3N1fP9wc33/ -bnB3/25wd/93eX//bnB3/25wd/9ucHf/dXd9/3h5ff9zdXz/bG51/3Byef9wcnn/cHN9/3Byef9ucHf/ -bnB3/3N1fP9sbnX/am13/2xvef9qbXf/c3V8/2Zpc/9ucXv/am13/2xvef9iZW7/am13/2dqdP9kZ3H/ -cHN9/2xvef9sbnX/amxz/3Bzff9sbnX/am13/3N2f/9zdXz/bnF7/3l8hv9zdn//eXyG/3V4gf9zdn// -c3Z//25xe/9wc33/bnB3/3Byef9zdXz/bG51/2dqcf9wcnn/c3V8/3N1fP9sbnX/bG51/2xvef9qbXf/ -c3V8/3V3ff9sb3n/bG95/2ptd/9iZW7/Zmlz/25xe/9qbXf/am13/2Zpc/9sb3n/amxz/2psc/9ucXv/ -bnF7/2dqdP9maXP/bG95/2Zpc/9maG7/ZGdx/2dqcf9kZ3H/bG95/2Jlbv9qbXf/am13/2Zpc/9nanT/ -Zmlz/2BjbP9kZmz/ZGdx/2Rncf9qbXf/Z2px/2Zpc/9kZ3H/Zmhu/2ptd/9wc33/c3V8/2xudf9nanT/ -bG51/3Bzff9sb3n/Zmhu/25wd/9ucHf/bG51/25xe/9wc33/dXd9/29xdf9ucHf/bnB3/3N2f/9ucHf/ -eHl9/3Byef91d33/b3F1/3V3ff9ucHf/bnB3/25wd/9zdXz/am13/3V4gf91d33/bG94/3d5gP9tcHj/ -aGt1/2ptd/9qbXf/bG95/3N1fP9sbnX/am13/25xe/9vcXf/cHJ5/3V3e/9wcnn/cHN9/3V4gf9ucXv/ -e36H/25xe/9wc33/cHN9/25xe/93eX//bnF7/3Byef9ucHf/cHJ5/25xe/9ucHf/bnB3/3Bzff9ucXv/ -c3Z//3Bzff9zdXz/bnF7/2xvef9ucHf/d3l//2xvef9wcnn/am13/2xudf9ucXv/bW9z/3V3ff9ucHf/ -bnF7/25wd/94eX3/cHJ5/3N1fP9qbXX/aGt1/2hrdP9ucXv/bG51/2ptd/9qbXf/bnF7/2tueP9kZ3D/ -ZWhx/3J1fP9ucXv/am13/2xudf9ucHf/c3V8/3N1fP9ucXv/bG95/3Z4fP9qbHP/cHJ5/25wd/9zdXz/ -bnB3/3d5f/9wcnn/bnF7/3Bzff9nanT/bnF7/25xe/93eoP/bnB3/2xvef9nanT/bnB3/3N1fP9qbHP/ -amxz/2ptd/91d33/bG95/25xe/9sbnX/bG51/25xe/9nanH/Z2px/2Zpc/9maXP/YmVu/2dqdP9qbHP/ -bG95/3N1fP9qbHP/am13/2dqdP9maXP/cHN9/2dqdP9zdXz/bG51/2xudf9wc33/bnB3/21vc/9tb3P/ -c3V8/2xvef9sb3n/e36H/25wd/9zdXz/bnB3/3V4gf97fYP/cHN9/3Byef9zdn//c3Z//3d6g/9wcnn/ -bnB3/3Byef95e4H/cHJ5/3V4gf95e4H/c3Z//3l7gf9zdXz/eXyG/3d6g/95fIb/bG95/3V4gf9zdXz/ -cHN9/3l8hv95e4H/dnh8/3N2f/9+gIb/dXiB/3V4gf9tb3P/bW9z/2dqcf92eHz/bnB3/3d6g/9zdXz/ -am13/2xvef9qbXf/Zmlz/2dqcf9nanH/am13/2dqdP9nanT/bG95/3Bzff9ucHf/bW9z/25wd/9tb3P/ -am13/3N1fP91d33/bG95/2ptd/9ucXv/ZWZq/2dqcf9wcnn/bnB3/25wd/9vcXX/c3V8/25wd/9ucXv/ -d3l//3V3ff9ucXv/bG95/3V3ff9wcnn/bnF7/2xvef9ucXv/cHJ5/3V3ff9sb3n/d3l//3d5f/91eIH/ -eXuB/3d6g/9ucXv/c3Z//3t9g/97fYP/fX6B/3Bzff9zdn//c3V8/3Bzff93eoP/dXiB/3V4gf9sb3n/ -Z2p0/25wd/9ucXv/cHJ5/2dqdP9ucXv/bnB3/25wd/9wcnn/cHN9/3Z4fP9sbnX/bG51/21vc/9wc33/ -bG95/3N1fP9ucXv/dXd9/2xudf92eHz/bnF7/3Byef91eIH/c3Z//29xdf95e4H/d3l//3N1fP97foX/ -dXd9/3J0e/9zdn//dXd9/31+gf97fof/dXiB/3V4gf91eIH/dHZ9/3J1f/92eH//bnF7/3N1fP9wcnn/ -bW9z/3l7gf9sbnX/bnB3/3Byef9ucHf/c3V8/25wd/9ucHf/bG51/2ptd/9qbHP/Z2p0/2psc/9qbXf/ -bG51/3N1fP9tb3P/amxz/2ptd/9sb3n/am13/3d5f/9sbnX/bG95/2ptd/9qbXf/cHN9/2ptd/9zdXz/ -cHJ5/25wd/9ucHf/c3V8/2xvef91d37/cHN4/3R2ff9ydX3/eHqA/3V4gf9zdn//b3J8/29yfP9vcnj/ -aGpy/2hrdP9zdXz/bG95/2Zpc/9sb3n/am13/3V3ff9wc33/cHN9/25xe/94eX3/am13/3Bzff91eIH/ -c3Z//2xvef91d33/b3F1/2xvef9ucXv/Z2p0/25xe/9wc33/eXyG/3Byef9ucHf/am13/3N2f/93eoP/ -bnF7/25wd/9wcnn/dnh8/25wd/9ucXv/bW9z/2xudf9zdXz/bG51/2psc/9qbXf/bG95/2ptd/9ucHf/ -bG51/25wd/93eX//am13/25wd/9sbnX/am13/25xe/9nanT/c3V8/2ptd/9sbnX/cHJ5/2xudf9sbnX/ -bG51/3N1fP9tb3P/bnB3/3V3ff9sbnX/am13/2dqdP9ucXv/dXd9/2xvef9nanT/am13/2xudf9wc33/ -amxz/2psc/9nanT/c3V8/2xudf9zdXz/dXd9/3Byef9zdn//bG95/3N2f/9ucXv/cHN9/2dqdP9ucXv/ -bnB3/2dqdP9wc33/bG95/25wd/9ucHf/d3l//3Byef9wcnn/Z2px/2xudf9iZW7/bnF7/2psc/91eIH/ -bG95/2psc/9maXP/Z2p0/2Zobv9maG7/ZGdx/2Zobv9iZW7/YGNs/2Rncf9nanT/ZGdx/2Rncf9kZ3H/ -YGNs/2Rncf9sb3n/bG95/2dqdP9maXP/Z2p0/11fZf9iZW7/bG95/2xvef9qbXf/bG51/2xvef9qbXf/ -bnF7/3Z4fP94eX3/cHJ5/2xudf9zdn//cHN9/3N1fP9ucHf/bnF7/3Bzff93eX//bnB3/3Z4fP92eHz/ -c3V8/3V3ff9wc33/b3F1/29xdf9zdXz/bnB3/3N1fP9tb3P/bG51/2xudf9sbnX/cHN9/2ptd/91d33/ -Z2p0/2Rncf9sbnX/bG95/2xvef9nanT/bG51/2xudf9sbnX/bnB3/3Bzff91d33/b3F1/25wd/9ucHf/ -c3V8/3Byef92eHz/cHJ5/3V3ff9qbHP/c3Z//3Bzff9wcnn/dXiB/3V3ff9sbnX/eHl9/3V3ff9wcnn/ -dXiB/3Byef9sb3j/b3F1/2xvef9zdn//eHl9/2xvef9wcnn/cHN8/21wev9tb3j/cHJ5/2dqcv9maXP/ -Zmlz/2Rncf9wc33/amxz/2psc/9sb3n/am13/2ptd/9qbXf/am13/2xudf9qbHP/bG51/2xudf9nanT/ -am13/2ptd/9ucXv/amxz/2xudf9qbXf/cHN9/2ptd/9zdn//am13/3Bzff9qbXf/bnB3/3V3ff9ucHf/ -dXd9/25wd/9wcnn/cHJ5/3Byef9tb3P/bnF7/21vd/9ucXn/bW93/3R2ff9sb3n/am13/2ptd/9ucXv/ -b3F4/2hrc/9sb3n/d3l//3N2f/9sb3n/bnF7/25wd/9ucXv/Z2p0/2dqdP9qbXf/bnF7/2Zpc/9nanT/ -Z2p0/2ptd/9nanT/bnF7/2xudf9qbXf/bG51/2psc/9tb3P/bnF7/3l7gf9tb3P/amxz/2psc/9ucXv/ -cHN9/25xe/9ucXv/c3Z//3l7gf9zdn//dXiB/25xe/9wc33/d3qD/3N1fP9zdXz/bnB3/25xe/9ucXv/ -c3Z//3N1fP9wc33/eXyG/3N2f/9wc33/c3V8/3N2f/93eoP/c3Z//3t9g/9zdn//cHJ5/3t9g/9zdn// -d3l//3V3ff93eoP/c3Z//3d6g/97fof/c3Z//3N1fP9zdn//eXuB/3l8hv9zdn//bG95/3N2f/9wcnn/ -d3l//3Byef9ucHf/bnB3/3h5ff9sbnX/cHJ5/3Z4fP9wcnn/bnB3/2ptd/9ucXv/bG51/2xvef9nanH/ -bnF7/2xudf9nanT/bnF7/2ptd/9qbXf/Z2p0/3N1fP9sbnX/Z2p0/2xudf9qbXf/Zmlz/3N1fP9qbXf/ -fn+D/3Z4fP9wcnn/c3V8/3N2f/9sb3n/bnF7/25wd/9wcnn/bnB3/2xvef9wc33/d3l//25xe/9wcnn/ -cHN9/25wd/9ucHf/d3l//3N2f/91d33/bnB3/3N1fP9lZmr/Zmlz/25xe/9sb3n/am13/2dqcf9qbXf/ -amxz/2dqdP9ucHf/cHJ5/2dqdP9kZ3H/bnF7/2ptd/9nanT/amxz/2ptd/9qbXf/cHJ5/2psc/9zdXz/ -c3V8/25wd/9zdXz/dXd9/29xdf9ucXv/dXiB/3Bzff91d33/bG95/25xe/9wcnn/bnF7/3Bzff9wcnn/ -eXuB/25wd/9qbXf/bnF7/3V4gf9wc33/bnF7/3V4gf9ucXv/cHN9/3Bzff93eoP/eXyG/3N2f/9zdn// -cHN9/3d6g/9zdn//e32D/3d6g/95fIb/cHN9/3l7gf91eIH/c3V8/3d6g/91eIH/c3Z//3t+h/97fob/ -d3qE/3p8g/90dn7/bXB6/25wd/9sb3n/cHN9/3d5f/9ucXv/bnB3/25xe/9xdH7/c3V9/3d5gP9wc33/ -bnF7/2xvef9ucHf/eXyG/25xe/9ucXv/cHN9/25xe/9wc33/cHJ5/25xe/9zdXz/cHJ5/25xe/9sb3n/ -bnB3/21vc/9ucHf/c3V8/25wd/9sb3n/bnF7/3d5f/9ucXv/d3qD/25xe/9zdn//cHN9/2xvef91d33/ -bG95/3Z4fP9ucHf/c3V8/25wd/9ucXv/bnB3/3Bzff9tb3f/bnB3/21vc/9ydHz/bnB3/25wd/9wcnn/ -cHJ5/3Fzef9oa3P/aGtx/3V3ff9wcnn/Z2px/2xvef9sbnX/dnh8/3N1fP91eIH/c3Z//3V4gf9sb3n/ -bG95/3Bzff9ucXv/bG95/3N2f/9sb3n/cHN9/25wd/9sb3n/bnB3/25xe/93eoP/bnB3/2xudf9qbHP/ -c3V8/3N1fP9ucHf/bnB3/3V3ff92eHz/c3V8/2xvef9qbXf/bnB3/3N1fP9sbnX/am13/2xudf9sbnX/ -amxz/25wd/9tb3P/bnB3/3V3ff9ucHf/bG95/2ptd/9tb3P/bnB3/2psc/9zdXz/bnB3/2ptd/91eIH/ -bnB3/25wd/9ucHf/bnF7/25wd/9zdXz/dXiB/25wd/9sb3n/bnB3/3N1fP91d33/bnB3/2psc/9tb3P/ -bG51/3V3ff9sbnX/bG51/25wd/91d33/bG51/3Byef9zdXz/am13/2ptd/9nanT/bG95/2psc/9qbXf/ -ZGdx/2ptd/9qbHP/Zmlz/2ptd/9qbXf/am13/2psc/9zdXz/bG51/2xudf9wcnn/bnF7/25xe/91eIH/ -cHN9/3+Bh/93eX//bG95/3Bzff9zdn//bG95/25xe/9ucHf/cHJ5/25wd/9qbXf/bnF7/3V4gf9ucXv/ -cHJ5/25xe/9ucHf/cHN9/3d5f/91eIH/c3V8/3Byef9ucXv/ZGdx/25wd/9wcnn/cHN9/2xvef9wcnn/ -bnF7/2xvef9wc33/d3l//3d5f/9zdXz/bG51/3Z4fP9zdXz/cHJ5/25wd/9wcnn/bG51/3V3ff9qbXf/ -cHN9/3N1fP9sb3n/bG95/2xvef9qbHP/Z2p0/25xe/9nanT/c3V8/2dqdP9qbXf/Z2px/2psc/9sb3n/ -amxz/3Byef9maG7/YmVu/2ptd/9sb3n/amxz/2Zpc/9ucHf/Z2px/2xudf9tb3P/bnB3/3Bzff9ucHf/ -dXiB/25wd/9zdXz/bnB3/3V3ff9zdXz/dXd9/2xudf91d33/bG95/25wd/9zdn//dXd9/29xdf92eHz/ -eHl9/3J0e/92eH7/bXB4/2hrdP9qbHP/Zmlz/3Byef91d33/am13/21vc/9sb3n/bm92/21weP92eH// -bnB3/2xvef9wc33/bnF7/3d6g/9zdn//d3qD/3t9g/93eX//fn+D/3d5f/93eX//e32D/3p7f/97fof/ -eXuB/3l7gf95e4H/e32D/3t9g/91eIH/d3l//31+gf9/gYf/d3l//3+CjP93eoP/d3qD/3Bzff9sb3n/ -dXd9/25wd/91d33/am13/2xvef9qbXf/bnF7/2psc/9rbnj/aGty/2hqc/9maG//am13/2dqcf9qbXf/ -bnF7/2xveP9tcHj/YmVu/19ibP9sb3n/Z2p0/2BjbP9maXP/bG95/3h5ff9wc33/c3Z//25wd/91d33/ -bG95/2xvef9sb3n/bnB3/25wd/92eHz/cHJ5/3Byef9sb3n/bnB3/25wd/9ucHf/dXd9/2xudf9qbHP/ -Z2px/3Byef9ucHf/am13/2xvef9wc33/c3V8/25xe/9ucXv/bG51/25xe/9wc33/bG51/25wd/9ucHf/ -bnB3/2ptd/9wcnn/b3F1/25wd/93eX//cHJ5/25wd/9vcXX/bG51/25wd/9sbnX/cHN9/2xvef9ucXv/ -eXuB/3Bzff9zdn//cHN9/3V4gf9ucXv/dXiB/3d6g/9ucHf/bG51/2xvef91d33/eHl9/3Bzff9sb3n/ -bnB3/25wd/95e4H/bG51/2xvef9ucHf/d3l//25xe/9wc33/dXd9/2xvef9zdXz/bnB3/25xe/9ucXv/ -bnF7/2dqdP9sb3n/bG95/2xudf9wc33/cHJ5/25wd/9sb3n/dXd9/25wd/9sb3n/bG51/2ptd/9nanT/ -bnF7/2xudf99foH/dXd9/21vc/9wcnn/c3Z//25wd/9ucHf/b3F1/2xudf9sbnX/Z2px/3N1fP9zdXz/ -bG51/21vc/9sb3n/am13/2xvef9zdXz/bG95/3Bzff91d33/cHJ5/2Rncf9ucHf/bnB3/3Bzff9ucHf/ -bnF7/25xe/9wcnn/cHN9/3d6g/93eoP/c3Z//2xvef91eIH/c3Z//3N2f/9ucXv/cHN9/3N1fP93eoP/ -bnF7/3d6g/91eIH/cHN9/3N2f/9wc33/bG95/2xvef91eIH/bnF7/3V3ff9sbnX/bG51/2xudf9sb3n/ -bnF7/2ptd/93eX//bW9z/2psc/9zdn//cHJ5/25wd/9sbnX/cHJ5/2psc/9vcXX/bnB3/25wd/9zdXz/ -bG51/3Byef9ucHf/dXd9/2xudf9zdXz/bnB3/3h5ff9sbnX/eHl9/25xe/9wcnn/c3Z//2xvef9qbHP/ -cHN9/3V3ff9sb3j/dHeB/25wef9sb3n/bnF7/25wd/9zdn//dXiB/2xvef9ucHf/bnF7/3R2fP9vcnn/ -dnh//25wd/9ucXv/bnF7/25wd/95e4H/bnF7/3N2f/91eIH/c3V8/3V4gf9wc33/cHJ5/25wd/9wcnn/ -dXiB/3Byef9ucHf/bG95/2xvef9wc33/bnB3/21vc/91d33/eHl9/3Byef95e4H/cHJ5/2xvef9ucXv/ -amxz/3N1fP9qbXf/cHN9/21vc/9wcnn/bnB3/3N1fP9vcXX/dHZ9/21wef9xc3z/bnB3/3N2f/9ucXv/ -c3Z//3V4gf9wc33/dXd+/2xvef9ydX7/e36H/3t9g/9ucXv/d3qD/3l8hv94eX3/cHJ5/3V3ff9tb3P/ -cHJ5/2xudf9ucHf/bG51/2ptd/9sbnX/dnh8/25wd/9qbXf/Z2p0/2dqdP9sbnX/bnF7/3V3ff9sbnX/ -bG51/2Zpc/9sb3n/am13/2ptd/9sb3n/c3V8/3Bzff9wc33/bG95/2ptd/9ucXv/cHN9/3Byef9ucHf/ -bG51/2xvef9nanT/bnB3/29xdf9zdXz/dnh8/25wd/9qbXf/amxz/2xudf9qbXf/Z2p0/2xvef9qbHP/ -Zmlz/3Bzff9sbnX/bG95/2ptd/9zdXz/bG51/25xe/91d33/bG51/2psc/9ucHf/dXd9/3h5ff9wcnn/ -Zmlz/2dqdP9sbnX/dnh8/2xudf9ucHf/b3F1/3d5f/9sbnX/cHJ5/3V3ff9qbXf/bG95/2xudf9sb3n/ -bnB3/3N1fP9qbHP/bnB3/2xudf9nanT/am13/2xvef9sbnX/bW9z/3N1fP9sbnX/bG95/2psc/9sb3n/ -Z2p0/25xe/9qbXf/eXuB/3d5f/9sbnX/bG51/3Bzff9sbnX/bW9z/2xudf9sbnX/bG51/2Zpc/9zdn// -cHN9/2xvef9vcXX/cHJ5/29xdf9wcnn/c3V8/25xe/92eHz/dnh8/3Byef9maG7/bnB3/3N1fP9zdXz/ -bnB3/3Byef9wc33/dXiB/3V4gf97fof/eXyG/3d6g/9qbXf/dXiB/3Bzff9wc33/bnB3/29xdf9sbnX/ -dXd9/25xe/9wc33/c3Z//3Byef9ucHf/bG51/25wd/9qbHP/dXd9/3Byef93eX//amxz/21vc/9sbnX/ -bnF7/2xvef9ucHf/dXd9/21vc/9ucHf/c3V8/3Byef9ucHf/bG51/3Byef9sbnX/bG51/2ptd/9sbnX/ -bnB3/2xudf9zdXz/bG51/3V3ff9qbXf/dXd9/25xe/91d33/Z2p0/3h5ff9ucHf/b3F1/3Byef93eoP/ -c3V8/3l7gf96fIP/c3Z//3Z5g/9ucXr/bG51/2xudf9qbXf/bnF7/3d5f/9tb3P/bW9z/2xudf9ucHf/ -b3F2/3d5gv9wcnn/bnF7/3Bzff9ucHf/d3qD/25wd/9ucHf/cHN9/25wd/92eHz/b3F1/25wd/9sb3n/ -bnB3/3Bzff9sb3n/bG95/25wd/9ucHf/c3V8/29xdf9vcXX/dXd9/3V3ff9ucHf/eXuB/3Byef9sb3n/ -bnF7/2dqdP9zdXz/am13/2xvef9qbHP/bG95/2xudf9wc33/amxz/3Bzff9qbXb/bG53/2hqdP9vcnz/ -am13/3Byef9wcnj/cXN6/3JzeP9oanP/Z2pz/3N1fP9ucXv/Zmhu/3N1fP9ucHf/dnh8/3Byef94eX3/ -bnB3/3V3ff9sbnX/bG51/25wd/9sbnX/bG51/3N1fP9wc33/am13/2dqdP9maXP/amxz/2ptd/9zdXz/ -Z2px/2Zpc/9iZW7/Zmlz/2RmbP9iZW7/Zmhu/2Zpc/9nanT/ZGdx/2Rncf9iZW7/Z2p0/2Zpc/9maG7/ -Zmlz/2Zpc/9qbXf/Zmlz/2xvef9sbnX/bnF7/3N1fP9qbXf/amxz/2psc/9qbXf/am13/2xudf91d33/ -b3F1/2xvef91d33/bG95/3Byef9sbnX/dXd9/2ptd/9wc33/dXd9/21vc/9nanH/cHJ5/3Z4fP92eHz/ -c3V8/2dqcf9sb3n/cHJ5/3t9g/9wc33/c3V8/25wd/93eoP/bnB3/3N1fP91d33/bG51/3Byef9sbnX/ -cHJ5/3Byef91d33/b3F1/3Byef9sbnX/bnB3/3N1fP9ucHf/bW9z/29xdf9zdXz/b3F1/2xvef9ucHf/ -cHN9/25wd/9wc33/bG95/3+Bh/93eX//bnB3/25xe/91eIH/cHN9/3N2f/9zdn//cHJ5/2ptd/9kZ3H/ -dXiB/3Bzff9sb3n/cHJ5/3Bzff9wcnn/c3Z//3l7gf9zdn//c3Z//3l7gf9wc33/Z2p0/25wd/91eIH/ -c3Z//3Byef9vcXX/bnB3/3Bzff9zdn//d3l//3h5ff9zdn//bG95/3d6g/9zdn//cHN9/25wd/9vcXX/ -cHJ5/3N1fP9ucHf/dXd9/3N1fP9ucHf/bnB3/3Byef9sbnX/Zmlz/25xe/9ucXv/d3l//2ptd/9qbHP/ -amxz/2ptd/9qbXf/am13/3N1fP9sbnX/Z2p0/2ptd/9sb3n/Z2px/2Zpc/9nanT/ZGdx/2Zpc/9kZ3H/ -amxz/2ptd/9nanT/cHN9/2xudf9wcnn/bG51/3Z4fP91d33/dXd9/2xvef95e4H/bnB3/25wd/9wcnn/ -c3Z//25wd/9zdn//dnh8/29yfP94eoH/bnB5/25wd/9ucXv/bnB3/3Byef93eX//bW9z/21vc/9sb3n/ -a252/2xudf92eYL/cHJ5/3Bzff9wc33/c3V8/3d6g/9zdn//dXiB/3V4gf9ucHf/eHl9/25wd/9vcXX/ -bG51/25wd/9wcnn/b3F1/2xudf9tb3P/bG51/3Byef9sbnX/bW9z/3Bzff9wc33/bG51/25wd/9qbXf/ -am13/2xvef9kZ3H/am13/2Rncf9sb3n/am13/3Bzff9qbXf/dXd9/2ptd/9xc3v/bG53/2ttc/9lZ3D/ -Z2p0/2Zpc/9maXP/ZGdx/2dqdP9tb3j/am13/21vdv90dn3/dXd9/2dqcf9zdXz/bnF7/3N1fP9qbXf/ -dXd9/2xvef9ucXv/bW9z/3Byef9wcnn/b3F1/2xvef9ucXv/dXd9/25wd/9ucHf/bG95/25xe/9zdXz/ -e32D/3Byef9vcXX/bnB3/25xe/9wcnn/b3F1/2xudf9wcnn/cHJ5/3Byef9wcnn/bG51/3Byef9ucXv/ -am13/2ptd/9sbnX/bnF7/2dqdP9qbXf/am13/2xvef91d33/cHJ5/29xdf9vcXX/bG95/3Byef9ucHf/ -c3V8/25wd/9sbnX/dnh8/3Byef9ucHf/bW9z/3V3ff9sb3n/d3l//3d6g/9zdXz/bG95/3d6g/97fYP/ -d3l//3Bzff9sb3n/cHJ5/2xvef92eHz/am13/2xvef9ucHf/eXyG/25xe/93eX//cHN9/25xe/9wcnn/ -bG95/2xvef9wc33/dXiB/25wd/9ucXv/am13/25wd/9wc33/bnF7/2xvef9sb3n/cHN9/25wd/9sb3n/ -Z2p0/25xe/9nanT/bnF7/21vc/+Agob/d3l//25wd/9ucHf/dXiB/3Bzff9zdn//c3Z//25xe/9ucXv/ -Zmlz/3N2f/9ucXv/bnB3/25wd/9ucXv/bW9z/25wd/91d33/bnB3/25xe/9zdXz/am13/2Rncf9qbXf/ -bG95/2ptd/9nanT/Z2px/2Zpc/9nanT/Z2p0/3Byef9ucHf/bnB3/2dqcf9zdXz/bG95/2ptd/9qbHP/ -bG51/2xvef9sb3n/bG51/3Bzff9ucXv/am13/2xudf9ucXv/bnB3/2dqdP91d33/c3V8/3d5f/9sbnX/ -b3F1/3Byef9wcnn/bG95/2ptd/91d33/bG51/2ptd/9sb3n/cHN9/2Zpc/9qbHP/bG95/2xudf9sb3n/ -Z2p0/2ptd/9qbXf/Z2p0/2ptd/9nanH/am13/2Zpc/9wcnn/c3V8/3V3ff9qbXf/cHN9/2dqdP9maXP/ -am13/3N1fP9tb3P/c3V8/3N1fP9sb3n/d3qC/25wef9ucHX/bnB3/25wd/9ucXv/d3qD/3Byef9ucHf/ -b3J8/29xef9sbnT/cHJ6/2dpb/9qbXf/Z2p0/2dqcf9wcnn/am13/2ptd/9ucXv/bG51/25xe/9qbXf/ -am13/2Zpc/9sbnX/cHN9/25wd/9sb3n/b3F1/29xdf9zdXz/bnB3/29xdf91d33/bnB3/2ptd/91d33/ -cHJ5/2xudf9ucXv/am13/2ptd/9maXP/bG95/2xvef9ucXv/am13/3Bzff9sb3n/cHN9/21wev9tcHr/ -bG95/3h6gP91eIH/foCG/3Z5gv93eoP/dXiA/25weP9pbHb/bnF7/3Bzff9maXP/bnB3/2xvef95fIb/ -dXiB/3t+h/93eoP/dXiB/3Byef9zdn//bG95/25xe/9sb3n/cHN9/3V4gf9wc33/bnB3/25wd/9wc33/ -c3Z//36Ahv91eIH/c3V8/25wd/9wc33/bnB3/2xudf9ucHf/c3V8/3V3ff9zdn//bnF7/2xvef9zdn// -cHN9/3Bzff9ucXv/c3V8/3Bzff9sbnX/bG95/25wd/9zdXz/dXd9/3Byef9sbnX/b3F1/2ptd/9ucHf/ -bG51/3N1fP9qbXf/bG51/3V3ff9ucXv/bnB3/2xudf9zdXz/bW9z/3Byef91d33/bG51/2ptd/9qbXf/ -cHN9/2xvef9qbXf/Zmlz/2xudf9qbXf/c3V8/2Zpc/9maXP/Z2px/3Bzff9nanH/bnF7/2xvef9qbHP/ -am13/2Zpc/9nanH/Zmhu/2Zpc/9kZ3H/Zmlz/2dqcf9kZ3H/Z2p0/2Zpc/9nanT/bG51/2xvef9sbnX/ -am13/2dqcf9sb3n/Zmlz/25xe/9sbnX/f4GH/3V3ff9sbnX/bG95/3Bzff9sbnX/bnF7/2xvef9qbHP/ -amxz/2RmbP9wc33/am13/2xudf9wcnn/cHJ5/2xudf9ucHf/c3V8/2ptd/9sb3n/bnF7/2xudf9iZW7/ -Z2p0/2xvef9sb3n/Z2p0/2ptd/9qbXf/bG95/3Bzff91d33/dXd9/3V3ff9vcXX/d3l//3V3ff9zdXz/ -bG51/2xudf9sb3n/bnF7/21vc/9zdXz/dXd9/25wd/9ucHf/bnB3/21vc/9nanH/c3V8/2xvef91d33/ -Z2p0/21vc/9zdXz/bnB3/2xudf9wcnn/d3l//2ptd/9nanT/am13/3V3ff9sbnX/bG51/2xvef9sbnX/ -am13/2Zpc/9sbnX/bG51/2xudf9ucHf/bW9z/3Byef9sb3n/dXd9/3V3ff93eX//bW9z/3V3ff9sbnX/ -bG51/2xudf91d33/cHJ5/3d5f/91eIH/cXR+/3Z5gv9wc3r/aGt1/25wd/9ucHf/bnF7/3d5f/9sbnX/ -bG95/2xvef9ydHv/bnF5/3V4gf9ucHf/cHN9/2xvef9ucHf/dnh8/3Byef9ucHf/bnB3/2xudf9wcnn/ -bnB3/3Byef9nanT/bG95/3N2f/9vcXX/bnB3/21vc/9sb3n/c3Z//3Bzff9wcnn/dXiB/25wd/9tb3P/ -eHl9/3V3ff9ucHf/c3V8/29xdf9ucHf/amxz/3N1fP9wcnn/c3Z//25xe/9zdXz/cHJ5/3V3ff9zdX3/ -bnF7/29xeP90d4D/cHN9/3Bzff9sb3n/cXN7/3Bze/9tb3f/aGp0/2xvef9ucXv/Z2p0/25xe/9sb3n/ -c3V8/25wd/94eX3/bnB3/3Bzff9wcnn/cHN9/25xe/9zdn//cHJ5/3N2f/91eIH/cHN9/3Byef9sb3n/ -c3V8/3N1fP97fYP/c3V8/29xdf9vcXX/dXd9/21vc/9ucHf/cHJ5/3Byef9wcnn/dXd9/2xvef9nanT/ -bG95/2ptd/9qbXf/amxz/2Zpc/9qbXf/Zmlz/2dqdP9sbnX/bG95/3N1fP9wc33/am13/2psc/9sbnX/ -bnF7/2xudf9zdXz/bG95/25wd/91d33/cHN9/25xe/9ucHf/dXd9/29xdf9zdXz/c3V8/25wd/9ucHf/ -bnF7/3V3ff9ucXv/d3qD/2xvef9ucHf/bG95/3d5f/9sb3n/bnB3/3Byef95fIb/bnB3/3N1fP9wcnn/ -bW9z/25wd/9wcnn/bG51/21vc/9wcnn/bG51/25wd/9ucHf/bG51/2xvef9sb3n/amxz/25wd/9ucXv/ -bW9z/2xudf9sb3n/bnF7/2xvef91eIH/bG95/4GDiv91d33/bW9z/3Byef9wc33/am13/25xe/9sb3n/ -amxz/2xudf9maXP/dnh8/2xvef9ucHf/cHJ5/25wd/9sbnX/b3F1/3Z4fP9zdXz/c3V8/3N1fP9ucHf/ -amxz/2xudf9wcnn/bnB3/29xdf9ucHf/bnB3/25xe/91eIH/d3l//3d6g/93eX//bG95/3d5f/9zdXz/ -cHN9/2psc/9ucHf/cHN9/3Bzff9ucXv/c3Z//3N2f/9wcnn/cHJ5/3Bzff9wcnn/cHJ5/3d6g/95fIb/ -eXyG/25xe/9zdn//c3Z//25xe/91eIH/e32D/3l8hv91eIH/c3V8/3d6g/97fYP/bnF7/25wd/9ucXv/ -cHJ5/3Bzff9sb3n/cHN9/3Byef9sb3n/cHJ5/25wd/9wc33/bnB3/25xe/9wcnn/eHl9/29xdf91d33/ -cHJ5/2xudf9vcXX/d3l//3Bzff97fYP/dXiB/29yfP91eIH/cHN9/21wev9wc33/cHJ5/2xvef93eX// -bnB3/2xvef9wcnn/cXR9/21weP91d33/bnB3/3N1fP9sbnX/b3F1/3Z4fP91d33/cHN9/25xe/91eIH/ -cHN9/25wd/9wc33/am13/3Byef91eIH/c3Z//3N2f/9zdXz/dXd9/3l7gf93eX//c3Z//3t9g/91eIH/ -c3V8/3l7gf9zdn//c3Z//3l8hv91d33/d3l//3Z4fP97fYP/e32D/3V4gf9wc33/dXiB/3N2f/92eYL/ -c3Z+/3Bye/9vcXj/c3V8/25wd/9ucXv/bG95/2xvef9xdHz/bG95/2ptd/9wc33/cHN9/2dqdP9zdXz/ -c3V8/25xe/9sb3n/c3V8/2xvef9qbXf/bG51/3V3ff9ucHf/c3V8/29xdf9wcnn/cHN9/2xvef9qbXf/ -bG51/3N1fP92eHz/eXuB/3N1fP9sbnX/bW9z/3Z4fP9sbnX/am13/2xvef9sb3n/cHJ5/3Byef9ucHf/ -amxz/3N1fP9ucXv/bG95/2ptd/9maXP/bnB3/2xudf9sb3n/bG51/2xvef9wc33/c3V8/2xvef9tb3P/ -bW9z/3Byef9qbHP/c3V8/25wd/9sb3n/dXd9/3V3ff9ucHf/bW9z/3Byef9ucHf/cHJ5/3Byef9sbnX/ -bG51/25xe/9wc33/am13/3Bzff9qbXf/bnB3/25wd/91d33/bG51/2psc/9ucHf/d3qD/2xvef9wc33/ -cHJ5/25wd/9ucXv/c3Z//25wd/9wcnn/cHN9/25wd/9wc33/bnF7/3Byef9zdn//d3qD/3Byef9zdn// -dXiB/25xe/9wc33/bnF7/3Bzff9wcnn/dXiB/2ptd/+BhI3/eXuB/25xe/91eIH/c3Z//2xvef9wc33/ -bnF7/2xudf9nanT/Z2p0/3V3ff9ucHf/bG95/3Byef9ucHf/bG51/25wd/91d33/c3V8/3V3ff9ucXv/ -cHJ5/2xvef9wcnn/c3Z//3N2f/9wc33/cHJ5/25xe/9ucXv/dXd9/3Z4fP93eX//eHl9/25wd/94eX3/ -cHJ5/3V3ff9qbHP/bW9z/25wd/9ucHf/bnB3/3N1fP9ucXv/bG51/2psc/9nanH/Z2px/2dqdP9sb3n/ -am13/3N1fP9maXP/amxz/2ptd/9qbXf/am13/3Bzff9zdXz/am13/2ptd/9zdXz/dnh8/2dqdP9wcnn/ -cHN9/2xvef9ucXv/Z2p0/25xe/9vcXX/amxz/3V3ff9vcXX/c3V8/2ptd/9wc33/cHN9/3l7gf9ucHf/ -c3Z//2xvef9sb3n/cHJ5/3Z4fP9wcnn/eHl9/3Z4fP9ydHv/dXd8/25wd/9qbHP/bG51/2xudf9sbnX/ -dnh8/2xudf9sbnX/bnB3/29xeP9tcHj/dHZ9/25xe/9zdn//bnB3/29xdf94eX3/cHN9/3N1fP9ucXv/ -cHN9/3N2f/9ucHf/bnB3/2xvef9ucHf/c3Z//3N1fP9ucXv/cHN9/3Bzff95fIb/c3Z//3Bzff93eoP/ -bnF7/25wd/97fYP/d3qD/3V4gf93eoP/cHN9/3N2f/9zdXz/cHN9/25xe/9wc33/cHJ5/3N2f/9zdn// -eHqA/3N2fv9vcnr/bnB3/3R2ff9wcnn/c3V8/3V3ff90dnz/c3Z9/29xef9tb3f/c3Z//3Byef9sbnX/ -cHN9/25xe/9zdn//cHN9/3d5f/9ucXv/cHJ5/29xdf9wcnn/cHJ5/3V4gf9ucHf/c3Z//3V3ff91d33/ -amxz/25wd/9wcnn/dnh8/3l7gf9zdXz/bW9z/2xudf9zdXz/bG51/2xudf9zdXz/bG95/3Byef9wcnn/ -c3V8/25wd/9zdXz/cHJ5/3N1fP9ucHf/Z2p0/2xvef9sbnX/bnB3/21vc/9ucHf/cHJ5/3V3ff9qbXf/ -bnB3/2ptd/9ucXv/Zmlz/3N1fP9vcXX/bnB3/3V3ff9wcnn/am13/2xudf9ucXv/am13/3Bzff9ucXv/ -bG51/21vc/9ucXv/cHN9/2xudf91d33/bW9z/2xudf9sbnX/dXd9/2psc/9qbHP/bW9z/3V3ff9tb3P/ -bG95/2xudf9qbXf/bG51/3V3ff9ucHf/bnB3/3Bzff9vcXX/bG95/2xvef9vcXX/cHN9/3V3ff9sb3n/ -dXd9/25wd/9ucXv/c3Z//2ptd/9sb3n/bG51/3N1fP9nanT/gIKG/3Z4fP9vcXX/dXiB/25xe/9qbXf/ -c3Z//3Bzff9sbnX/bG51/25wd/91eIH/c3V8/25xe/9sb3n/bnF7/2xvef9zdn//c3Z//3V4gf93eoP/ -cHN9/3Byef9ucHf/cHN9/3d6g/9wc33/cHN9/3N1fP9ucXv/bnF7/3l7gf93eX//eXuB/3l7gf9ucXv/ -dnh8/3Byef9zdXz/bnB3/25wd/9wcnn/bnF7/2xvef9wc33/bnF7/2xudf9ucHf/bnB3/25wd/9vcXX/ -cHJ5/3V3ff95e4H/bnB3/25wd/9wc33/bnF7/3Bzff95e4H/foCG/3d5f/92eHz/fn+D/36Ahv9zdXz/ -e32D/3+Bh/95fIb/e36H/3N2f/9+gIb/eHl9/3V3ff97fYP/d3l//3l7gf94eX3/e32D/3d6g/9+gIb/ -c3V8/3d6g/9ucXv/Z2p0/29xdf93eX//c3Z//3l7gf94eoD/dXiB/3R2fv9qbXf/aGty/2dqcf9qbHP/ -ZGdx/25wd/9nanH/Z2p0/2xvef9qbXT/aWty/3Fzev9qbHP/bnF7/21vc/9sbnX/dnh8/3N1fP9ucHf/ -cHJ5/3Byef9zdXz/bnB3/25wd/9ucHf/b3F1/25xe/9sb3n/bG95/25xe/9ucXv/c3Z//3N2f/9wc33/ -eXuB/3N2f/9wc33/fX6B/3l7gf9+gIb/e32D/3d5f/91d33/dXd9/3V4gf93eoP/d3qD/3N2f/93eoP/ -d3qD/3t+h/97fof/eHuC/3R3gP93eoL/eXuB/3l7gf93eX//dXh+/3R2fP9ucXv/bnB3/25xe/9wcnn/ -amxz/3Byef9sbnX/c3Z//3V4gf93eX//c3Z//3N2f/9ucXv/cHN9/25xe/93eX//bG95/3Byef9zdn// -dXiB/25xe/9wc33/dXiB/3t9g/9/gYf/d3qD/3Bzff91eIH/d3qD/3Bzff91eIH/d3qD/25xe/9sb3n/ -cHN9/3Bzff9ucHf/cHN9/3N2f/91eIH/c3Z//3N1fP9zdn//cHJ5/3Bzff9sb3n/bnB3/3N1fP9zdXz/ -b3F1/3Byef9wcnn/c3V8/2xudf91d33/cHJ5/25wd/93eX//c3V8/29xdf9ucHf/cHN9/2xvef91d33/ -c3V8/2ptd/9sbnX/bnF7/3V3ff9sbnX/bnF7/2xudf9qbXf/bG51/3N1fP9kZ3H/am13/2xudf93eX// -amxz/2xvef9qbXf/ZGdx/2xudf9sb3n/Z2p0/2psc/9qbXf/amxz/2ptd/9sbnX/amxz/2xvef9zdXz/ -amxz/25xe/9qbXf/am13/2xvef9wcnn/bnF7/25xe/93eX//cHJ5/4GEjf97fYP/d3qD/3l7gf91eIH/ -bG95/3l8hv97fYP/cHN9/25xe/9sb3n/d3qD/3N1fP9ucXv/dXiB/3N2f/9wc33/c3Z//3V4gf93eoP/ -eXuB/3Bzff9ucXv/bG95/2ptd/91d33/bnB3/3N1fP9ucHf/bG95/25xe/91eIH/d3l//3d5f/93eX// -bnF7/3d5f/9wc33/dXiB/2xvef9ucXv/dXiB/3N2f/91eIH/eXuB/3N2f/9ucXv/bnF7/3Bzff9zdXz/ -cHJ5/3N2f/95e4H/d3qD/25wd/9ucHf/bnF7/3Bzff9wc33/dXd9/3d5f/9wcnn/bnB3/25xe/9zdn// -bG95/2xvef9wc33/bG95/3Byef9nanT/bnF7/25wd/9sb3n/dXd9/3Bzff9wcnn/am13/3Bzff9zdXz/ -dnh8/29xdf9zdXz/am13/2Zpc/9qbXf/c3V8/3Byef9zdXz/dXd9/3J0e/92eH3/bW90/2xudv9tb3P/ -bG95/2xvef93eX//c3Z//3d6g/90d4D/bXB6/25wef90dn3/b3F2/3V3ff9sbnX/amxz/3V3ff9zdXz/ -cHJ5/3Bzff9sb3n/bnF7/25wd/9ucHf/b3F1/2xudf9sbnX/bG51/29xdf9sb3n/bnF7/3Bzff9ucXv/ -cHJ5/3V4gf9zdn//c3V8/3V4gf9zdn//d3qD/3V4gf9wc33/cHN9/3Byef9wc33/c3Z//3N2f/9sb3n/ -bnF7/3Bzff92eH7/c3Z//29yfP9ucXr/c3Z//3N2f/91d33/c3Z//3R2fP9zdoD/cHN9/3Bzff91eIH/ -c3Z//3Byef9wc33/cHJ5/3N1fP9wc33/c3V8/3V3ff9wcnn/bnB3/3Byef9ucHf/dXd9/2ptd/9ucXv/ -bG95/25xe/9maXP/amxz/2xvef9wc33/dXiB/2ptd/9sbnX/bG95/2xvef9sbnX/c3V8/3N1fP9sbnX/ -am13/2xvef9sbnX/Z2p0/25xe/9wc33/dXd9/25wd/9vcXX/bnB3/2xvef9ucXv/cHN9/25xe/9zdn// -dXiB/25wd/9wc33/cHN9/3N2f/9sb3n/d3qD/3Bzff9sb3n/eXyG/3Bzff9vcXX/b3F1/3N1fP9qbHP/ -cHN9/3Bzff9nanT/am13/2ptd/9wc33/amxz/2ptd/9nanH/Zmlz/2dqcf9maXP/YGNs/2Rncf9nanH/ -c3V8/2xudf9sb3n/amxz/2Zpc/9qbXf/bnF7/2xudf9tb3P/cHJ5/25wd/9ucXv/bnF7/3Byef9ucHf/ -cHN9/25wd/91eIH/bnF7/25xe/91eIH/dnh8/3N2f/91eIH/fn+D/3h5ff+Ji5H/fn+D/3l7gf9+f4P/ -e32D/3N1fP9+f4P/foCG/3d5f/91d33/cHN9/3l7gf91d33/cHN9/3N2f/9wc33/bnF7/3V4gf9zdn// -dXiB/3V4gf9zdn//c3Z//3Byef9ucXv/c3Z//25xe/9ucXv/bnB3/25wd/9qbXf/dXd9/3d5f/91d33/ -d3l//25wd/91d33/bnB3/3Z4fP9sbnX/c3V8/3V3ff9wcnn/cHJ5/3Z4fP9zdXz/b3F1/25wd/9wcnn/ -b3F1/21vc/9zdXz/dXd9/3d5f/9qbXf/bG51/25xe/9sbnX/dXd9/3V3ff93eX//am13/2psc/9ucXv/ -am13/2Jlbv9qbHP/am13/2dqcf9maXP/XWBq/2dqcf9kZ3H/Z2p0/3Bzff9qbXf/Z2px/2Rncf9sb3n/ -bG95/3Bzff9qbHP/c3V8/2xudf9maXP/Z2p0/3Bzff9sbnX/c3V8/3V3ff9xdH3/cnV+/2xudv9tb3b/ -bG51/2ptd/9ucHf/dnh8/25wd/9wcnn/bnB3/29xef9wcnn/dXh+/3Bzff95e4H/cHN9/2xvef95e4H/ -c3Z//3V4gf9zdn//cHN9/3N1fP9ucHf/cHJ5/3Byef9wcnn/cHN9/3Byef9sb3n/cHN9/25xe/9wcnn/ -bnB3/21vc/9wcnn/cHJ5/2xudf9zdXz/bG51/25xe/9wc33/bW9z/29xdf9ucHf/bnB3/3N1fP91d33/ -bG95/3Byef9sb3n/dHZ9/3R3f/9ucXn/bnB3/25xe/91d33/dXd9/3N2f/91eID/eHqA/3J0e/93eYD/ -foCG/3l8hv95e4H/e36H/3l7gf9zdn//c3Z//3V3ff93eX//bnF7/25xe/9wc33/dXiB/3V4gf9vcXX/ -cHN9/3Bzff9zdn//bG51/29xdf9wcnn/dnh8/3l7gf9wcnn/bnF7/3N2f/91eIH/cHJ5/3V4gf93eoP/ -bnF7/3N2f/9zdn//c3Z//3Bzff93eoP/eXyG/31+gf95e4H/c3Z//3V4gf9zdXz/c3Z//3N2f/9zdXz/ -dXiB/3t9g/92eHz/eXuB/3d5f/95e4H/dXd9/3t9g/93eoP/c3Z//36Biv91eIH/bnF7/3Byef93eoP/ -cHN9/3l7gf93eoP/bG95/2xvef9wc33/dXd9/2xvef9zdn//bG95/2xvef9zdXz/cHJ5/2dqcf9qbHP/ -bW9z/3V3ff9qbXf/c3V8/25wd/9sb3n/cHN9/3V4gf9sb3n/bnF7/2xvef9ucXv/bnF7/3Byef9ucXv/ -c3Z//3l7gf93eoP/eXyG/3d5f/93eX//fX6B/2ptd/9sbnX/am13/3Bzff9maXP/e32D/3Bzff9tb3P/ -c3V8/2xvef9nanT/bnF7/25xe/9qbHP/bW9z/2psc/9ucXv/bG51/2Zpc/9sb3n/am13/2Rncf9qbXf/ -am13/2dqdP9nanT/Z2px/2dqcf9nanH/ZGdx/2dqdP9maXP/Zmhu/2Jlbv9iZW7/ZGZs/25wd/9zdXz/ -cHN9/3N1fP9nanH/bnF7/2dqcf9wc33/Z2p0/2ptd/93eX//bnF7/3Byef91d33/bnB3/25wd/9vcXX/ -cHJ5/21vc/9ucHf/cHJ5/3Z4fP95e4H/bG51/25wd/9zdn//bG51/3h5ff91d33/d3l//3Byef9qbHP/ -c3V8/25xe/9kZ3H/am13/2xvef9nanH/Z2p0/2BjbP9nanH/YmVu/2Jlbv9nanT/am13/2dqcf9kZ3H/ -bnF7/3Byef94eX3/bW9z/3V3ff9ucHf/Zmlz/2Zpc/9zdn//cHJ5/3V4gf94eoD/c3Z//3J1f/9tcHj/ -bW92/2xudf9sbnX/bG51/3N1fP9wcnn/cHJ5/25wd/9vcnz/bnB3/3N1fP9sbnX/c3V8/21vc/9sbnX/ -eHl9/3N2f/91d33/bG95/2xvef9ucXv/b3F1/2xudf9vcXX/b3F1/21vc/9tb3P/b3F1/3N1fP9sbnX/ -bG95/21vc/9ucHf/cHN9/3Byef9vcXX/eHl9/25wd/9zdn//dXd9/21vc/9sbnX/am13/2xudf9ucXv/ -bnF7/21vc/9sbnX/bnB3/3V3ff9wc3v/bnB3/25wdP9sb3n/c3Z//3V4gf9ucXv/dHZ8/3V2ev9ucHf/ -a253/3N2f/9zdXz/dXd9/3V4gf9zdXz/c3Z//3d5f/91eIH/d3l//3N1fP9ucHf/cHJ5/3Bzff9sb3n/ -amxz/2ptd/9wcnn/bnF7/2Rncf9sbnX/bnF7/3Bzff91eIH/bG95/25xe/9wc33/bnF7/2ptd/9wc33/ -cHN9/2ptd/9sb3n/am13/2xudf9maXP/cHN9/25xe/9wc33/bG95/2xudf9sbnX/amxz/2xudf9sbnX/ -amxz/2ptd/9ucXv/Z2p0/2xudf9nanT/amxz/2BjbP9ucXv/am13/2xudf91d33/bnF7/2xudf9sbnX/ -cHN9/2xudf9zdXz/c3V8/25wd/9ucHf/dXd9/3Z4fP9wcnn/c3Z//2xvef9sb3n/cHN9/25xe/9sb3n/ -cHJ5/3N1fP97fYP/cHN9/3V4gf9wcnn/bG95/25xe/9zdXz/amxz/21vc/9ucHf/bnB3/2xudf9sbnX/ -bnF7/2xudf9wc33/bG95/3Byef9sbnX/cHJ5/3V3ff9ucHf/cHJ5/25xe/91d33/am13/3+Bh/91d33/ -bnB3/3Z4fP9ucHf/amxz/2xvef9wc33/Zmlz/2psc/9maXP/am13/2dqdP9nanT/am13/2Zobv9iZW7/ -Z2px/2ptd/9maXP/ZGdx/2Zobv9kZ3H/Zmhu/2Zobv9maXP/ZGZs/2Rncf9iZW7/ZGdx/2Zobv9ucHf/ -cHJ5/2Zpc/9wc33/Zmhu/25xe/9kZ3H/am13/2BjbP9kZ3H/bnB3/2ptd/9sb3n/bnF7/2ptd/9qbXf/ -am13/2xvef9qbHP/bG51/21vc/91d33/dXd9/25wd/9vcXX/c3Z//2xvef91eIH/d3qD/3l8hv9wc33/ -bnF7/3l7gf91eIH/bnF7/3N2f/97fYP/c3V8/3V4gf9sb3n/bnF7/2ptd/9ucHf/dXiB/3V4gf9ucXv/ -am13/3V4gf95e4H/e32D/3Bzff93eX//cHJ5/25wd/9ucHf/dXiB/3N2f/95fIb/e32D/3l7gf9ydX// -bnF7/25wd/9sb3n/bnB3/2xvef9wc33/bnF7/3Byef9vcXn/c3V9/29yev91eH7/bG95/3V4gf9ucXv/ -bG51/3Z4fP9wcnn/dXd9/2xudf9vcXX/bnB3/29xdf9qbHP/bG51/2xudf9tb3P/bG51/21vc/9wc33/ -cHJ5/3Byef9wcnn/cHJ5/3V4gf9ucXv/bG95/3l7gf9ucXv/c3Z//25xe/9ucHf/cHJ5/25xe/9ucHf/ -bnF7/3Bzff9ucHf/cHJ5/3Byef92eHz/c3V8/25wd/9sbnP/cHJ5/3Bzff9ucXv/am13/29yfP9xdHv/ -a211/2psdP9wcnn/bG51/2xudf9sbnX/bW9z/3Z4fP92eHz/bnB3/3Z4fP9wcnn/am13/25xe/9zdXz/ -bnF7/2xudf9qbXf/bnF7/3N1fP9nanH/cHJ5/3Byef91d33/e32D/3Byef91d33/c3V8/3Byef9tb3P/ -cHJ5/3N1fP9ucHf/bnB3/25wd/9vcXX/amxz/3Bzff9wc33/cHN9/2ptd/9sbnX/bG95/2dqcf9wcnn/ -bnB3/25xe/9wcnn/dXd9/2xudf9ucHf/c3Z//2xvef9sb3n/cHN9/25xe/9sb3n/d3qD/3Byef9ucHf/ -bW9z/3Byef9sbnX/c3V8/3Bzff9ucHf/bnF7/3V4gf95e4H/c3Z//3d6g/9ucXv/b3F1/3N1fP9ucHf/ -Zmhu/2ptd/9qbXf/d3l//2xudf9ucXv/bG51/2psc/9wcnn/c3V8/25wd/9ucHf/bG95/3Bzff9wcnn/ -bG95/3N1fP9ucHf/dXd9/25wd/9wcnn/am13/2xudf91d33/d3l//3t9g/9+f4P/fn+D/3l7gf+IipD/ -foGK/3l7gf9+gYr/foCG/3N1fP97fYP/e32D/3V3ff93eX//eHl9/3l7gf91d33/dXd9/3d6g/9zdXz/ -bG95/25wd/91d33/cHJ5/2xvef9sb3n/Z2p0/2psc/9qbHP/am13/2dqcf9qbXf/Zmlz/2Rncf9maG7/ -cHJ5/3V3ff9qbXf/c3V8/2Zobv9kZ3H/ZGdx/25wd/9kZ3H/Z2p0/3Bzff9ucXv/cHN9/3Bzff9ucHf/ -amxz/29xdf9wcnn/bnB3/2xudf9tb3P/dnh8/3V3ff9wcnn/b3F1/3Byef9wcnn/c3Z//3N1fP91eIH/ -bG95/2ptd/91d33/dXd9/2xudf9ucHf/dnh8/2xudf9wcnn/bG51/2xudf9maXP/am13/3N1fP9zdXz/ -bG51/2dqcf9wcnn/c3V8/3Z4fP9qbXf/dXd9/2ptd/9maXP/bG51/2Zpc/9maG7/Zmlz/2ptd/9sb3j/ -bW92/21vdv9tb3f/bnB3/2ptd/9nanT/cHN9/3Bzff9sb3n/b3F4/29yfP9rbnj/cXR9/2hrdf9ucXv/ -bG95/2ptd/9zdXz/bnF7/3Bzff9qbXf/am13/2xvef9vcXX/bG51/2xudf9sbnX/bW9z/2xudf9ucHf/ -cHJ5/21vc/9sb3n/am13/3Byef9zdXz/bG95/2ptd/9zdXz/bG95/3N1fP9sbnX/bnB3/25wd/9sb3n/ -bnB3/25xe/9zdn//bnB3/3Byef9wcnn/c3V8/3Fzev9ucXn/bG95/3Bzff9zdn//cHN9/25wd/9wc33/ -cXN6/2xud/9sbnX/cHN9/25wd/9wcnn/bnB3/25wd/91d33/c3V8/2xvef9zdXz/bnF7/25xe/9qbXf/ -bnF7/25xe/9qbHP/bG51/2ptd/9qbXf/Zmlz/2xvef9sb3n/bG95/3N2f/9sb3n/bnF7/25xe/9sb3n/ -bG95/25xe/9wc33/bG95/25xe/9sbnX/bG51/2dqdP9zdXz/dnh8/3Z4fP9wc33/bnB3/3Bzff9sb3n/ -bG95/29xdf9wcnn/dXiB/3d5f/9ucXv/c3V8/3N2f/9ucXv/bG95/3V4gf9zdn//cHN9/3l8hv91eIH/ -cHN9/3Byef93eoP/bnF7/3V4gf9zdn//cHJ5/3Byef91eIH/eXuB/3N2f/91eIH/c3Z//3Bzff92eHz/ -dXd9/2Zobv9ucHf/cHJ5/3V3ff9sbnX/bnF7/2xudf9nanT/cHJ5/3N1fP9sbnX/bnB3/25wd/9zdXz/ -bnB3/3Bzff9wc33/bnB3/3V4gf9wc33/dXiB/3N1fP91eIH/e32D/3l7gf95e4H/e32D/3t9g/91d33/ -g4WM/3d6g/9wcnn/dXiB/3V4gf9nanT/dXiB/3d6g/9wc33/c3V8/3N1fP9zdn//bG95/25wd/9ucXv/ -bG95/29xdf9sbnX/dXd9/3Bzff9sb3n/bnB3/25wd/9ucHf/b3F1/3N1fP9ucHf/dXd9/2ptd/9nanH/ -bW9z/3d5f/95e4H/cHJ5/3t9g/9ucHf/c3V8/21vc/91d33/bG51/3Byef93eX//bnF7/3N1fP9wcnn/ -bnB3/2dqcf9sbnX/bG95/2psc/9sbnX/Z2px/2xvef9zdXz/Z2px/2Zobv9qbXf/ZGdx/2xvef9sb3n/ -dXd9/2ptd/9qbHP/bnF7/25xe/9maXP/bG51/3N1fP9qbHP/cHJ5/2psc/9qbHP/ZGdx/2psc/9wc33/ -cHN9/2ptd/9nanT/bG95/25xe/91d33/bG51/3d5f/9ucHf/bG51/2psc/9wcnn/bG51/3Byef9wcnn/ -dHZ8/21vdv9tcHn/bG51/25wd/9sbnX/Zmlz/2xvef9sb3n/am13/25xe/9vcnn/bXB3/3V3fv9ucHf/ -cHN9/3Byef9sb3n/d3l//3N2f/93eX//bnF7/2xvef9wc33/bnF7/2xvef9ucXv/cHJ5/3N1fP91d33/ -c3Z//3d6g/9zdXz/cHJ5/25xe/91eIH/foCG/3V4gf9wc33/d3qD/3N2f/95fIb/c3Z//2xvef9sb3n/ -bnF7/3Byef9wc33/dXiB/25xe/9ucXv/cHJ5/3N2f/9ydX7/cHJ5/2xvef9ucXv/c3Z//3Bzff9wc33/ -cnV+/3J0ev9ucHn/a254/3Bzff9vcXX/b3F1/25xe/9wc33/dnh8/3N1fP9ucHf/d3l//3Byef92eHz/ -bnF7/3N2f/95e4H/cHJ5/25xe/9zdn//cHN9/25xe/91eIH/d3qD/3d6g/97fof/dXiB/3t9g/99foH/ -e32D/3d6g/93eoP/eXuB/3V4gf91eIH/dXiB/3V3ff92eHz/eXuB/3t9g/9+f4P/eXuB/3Bzff95e4H/ -cHN9/3Bzff9wcnn/bnF7/3V4gf95e4H/cHN9/3Bzff93eoP/bnB3/2ptd/9ucXv/bnB3/2xvef91eIH/ -cHN9/2xvef9vcXX/c3V8/25wd/9ucHf/c3V8/2xudf9sbnX/dXd9/3V3ff9wc33/dXiB/3V4gf9zdn// -eXuB/3N2f/9maXP/bnB3/3Bzff95e4H/dXiB/3l7gf9zdn//c3Z//3t9g/97fYP/c3V8/3Z4fP93eoP/ -eXyG/3d5f/97fYP/foCG/3h5ff9+f4P/e32D/35/g/91d33/eXuB/36Ahv9sb3n/am13/3Bzff92eHz/ -bnB3/3l8hv9wc33/bnB3/25xe/9ucXv/Zmlz/3V4gf97fYP/c3V8/3Byef9zdXz/d3qD/3V3ff93eX// -foCG/3Z4fP91d33/c3Z//3t9g/97fYP/d3qD/3V4gf91d33/dXd9/3N2f/95e4H/d3qD/3d6g/9sb3n/ -bG95/3Byef95e4H/e36H/3Bzff95fIb/cHJ5/3V4gf9zdXz/c3Z//29xdf9zdXz/dXiB/3Bzff93eX// -cHJ5/2xvef9qbHP/bnB3/25wd/9tb3P/bW9z/25wd/9zdXz/dXiB/2xvef9ucHf/c3Z//3Byef91d33/ -c3V8/3d5f/9wcnn/bW9z/3N1fP9zdXz/bG51/25wd/91d33/bW9z/3Bzff9sb3n/bnB3/2psc/9ucHf/ -dnh8/3N2f/9vcXX/amxz/2xvef9wc33/c3V8/2xudf93eX//bG51/2xudf9qbHP/dXiB/3N2f/9zdn// -cHN8/3N1fP9tb3b/cXN6/25wd/9ucHf/b3F1/25wd/9ucXv/c3Z//3Bzff92eYL/dHZ+/3Fzev93eX// -bW92/3V3ff9wcnn/bnB3/3N1fP9ucXv/cHN9/2xvef9sbnX/cHN9/2xudf9kZ3H/am13/2ptd/9nanT/ -Zmlz/2ptd/9wcnn/bG51/21vc/9ucHf/bnF7/3V3ff9sb3n/bG95/3N1fP9vcXX/dnh8/25wd/9sbnX/ -am13/25wd/9vcXX/b3F1/3Byef9vcXX/dXd9/3Byef90dn3/cXN9/25wd/9tcHn/bXB6/25xe/9ucHf/ -bnB3/3Byef9wc3r/bW94/2ptd/9zdXz/b3F1/21vc/9ucHf/bnF7/3V3ff9sb3n/bnB3/3V3ff9sb3n/ -c3V8/3Byef9zdXz/c3Z//25wd/9ucXv/bG95/25wd/9wcnn/cHN9/3N1fP9ucXv/d3l//25xe/9wc33/ -dXd9/3N2f/9wcnn/d3qD/3d5f/9zdn//c3Z//3Byef9wcnn/bnB3/25xe/9wc33/dXd9/2xudf9tb3P/ -c3V8/2dqdP9sbnX/bG51/21vc/9wcnn/c3V8/2Rncf9qbXf/bnF7/2xudf9tb3P/am13/2xudf9qbHP/ -dXd9/25xe/9qbXf/bG95/25xe/9sbnX/cHJ5/3V3ff9ucHf/cHJ5/3d5f/93eX//c3Z//3V4gf91eIH/ -bG95/3V3ff91d33/Zmhu/25wd/91d33/dnh8/3Byef9wcnn/b3F1/2xudf9wcnn/cHJ5/2Rncf9nanT/ -am13/2ptd/9nanT/bG51/2Zpc/9maG7/bG95/2dqdP9qbXf/Z2px/2dqcf9qbXf/c3V8/3Byef9wcnn/ -dnh8/2xudf93eoP/am13/21vc/9qbXf/bG51/2psc/9zdXz/d3l//25wd/9ucHf/b3F1/25wd/9qbXf/ -bG51/3V3ff9qbHP/amxz/29xdf9wcnn/c3V8/2xvef9ucHf/bG51/2ptd/9sbnX/c3V8/3N1fP9wcnn/ -amxz/2xudf9qbXf/c3V8/3V3ff9qbXf/d3l//2xudf9ucHf/bG51/2xvef9sbnX/cHJ5/3Z4fP9zdXz/ -c3V8/2ptd/9sbnX/amxz/2xudf9sbnX/bW9z/21vc/9sbnX/cHJ5/3V3ff9sbnX/bG51/3Z4fP9sb3n/ -dXd9/3Byef93eX//bnF7/29xdf91d33/cHN9/2xvef9wcnn/eHl9/3Byef95e4H/c3Z//25wd/9qbXf/ -bnB3/3d5f/91eIH/bnF7/25wd/9wc33/dXiB/3d5f/9ucHf/dXiB/25wd/9sb3n/Z2p0/2ptd/9sb3n/ -bnF7/25xe/9wc3z/bnB3/29yev9ucHf/b3F1/2xudf9qbXf/bnF7/3N2f/9wc33/bXB6/3F0ff9sbnf/ -cXR9/2ttdP9qbXf/Z2p0/2psc/9sb3n/bnF7/2xvef9ucHf/bG51/25wd/9sbnX/amxz/25wd/9vcXX/ -bnB3/2ptd/9ucHf/bnF7/2xvef9sb3n/cHN9/25xe/95e4H/cHN9/3Byef91eIH/cHN9/3l7gf9wc33/ -bG95/3Byef9ucHf/bnB3/21vc/9wcnn/bW9z/3Byef9ucHf/c3V8/2xudv9sbnX/a211/25xev9ucXv/ -bnB3/3Byef9ydHv/b3J7/25wef9ucHf/c3V8/25wd/9vcXX/b3F1/3Byef9zdXz/bG51/3N1fP94eX3/ -bnB3/3V3ff9ucHf/bnB3/3d5f/9wcnn/c3Z//3V4gf91eIH/bG95/3N2f/9wcnn/bnB3/3d5f/9sbnX/ -cHJ5/3V3ff91d33/b3F1/3N1fP92eHz/c3V8/3Byef9ucHf/bnB3/21vc/9sbnX/c3V8/3d5f/9ucHf/ -am13/25xe/9kZ3H/bG51/2ptd/9sbnX/bG95/3N1fP9maXP/bG51/2xvef9sb3n/bW9z/2xudf9ucHf/ -bnB3/3V4gf9ucXv/bnB3/25xe/9wcnn/bnB3/3Byef91d33/bG51/2xudf92eHz/d3l//3N1fP9zdXz/ -c3V8/25wd/91d33/c3Z//2dqcf9ucHf/dXiB/3t9g/91eIH/d3qD/3Bzff9ucHf/c3Z//3N2f/9sb3n/ -bnB3/3N1fP9ucHf/bnB3/3Bzff9ucXv/bnF7/3Z4fP91d33/c3V8/25wd/9tb3P/cHJ5/25wd/9sb3n/ -bnF7/3Z4fP9vcXX/e32D/25wd/9qbXf/am13/25wd/9nanH/cHJ5/3d6g/9sb3n/cHJ5/3Byef9wc33/ -bnB3/25xe/91eIH/am13/2xvef9ucHf/bnF7/3Bzff9sb3n/bnF7/29xdf9ucHf/bW9z/3N1fP9wcnn/ -c3V8/2xudf9ucHf/am13/3N1fP92eHz/am13/3V3ff9qbHP/am13/2xudf9qbXf/amxz/2xvef91d33/ -cHN9/3V3ff9sb3n/bG51/2dqdP9qbHP/bG51/2xudf9sbnX/bG51/2ptd/9wc33/amxz/2Rncf9ucXv/ -Z2p0/25xe/9sb3n/dXd9/2ptd/9qbXf/cHN9/25xe/9nanT/bG95/3V3ff9sbnX/cHN9/2ptd/9nanT/ -ZGdx/2xudf9zdXz/cHN9/25wd/9vcXX/bG95/3V3ff94eX3/bnB3/3l7gf9ucXv/bnB3/2dqdP91d33/ -bnB3/25wd/9wcnn/bnF7/21veP9wcnn/b3J8/3Byef9ucXv/am13/3Bzff9zdn//bG95/3Byef9ydH3/ -cHJ7/3V2e/9vcXf/cHJ5/25wd/9sbnX/cHJ5/3Bzff9wcnn/bnB3/25wd/9wcnn/bG51/2Rncf9sbnX/ -bG51/2dqdP9nanT/bG51/25wd/9ucHf/b3F1/3Bzff9wcnn/eHl9/3Byef9sb3n/cHN9/3Bzff93eX// -bG95/2xvef9ucXv/bG95/25wd/9vcXX/cHJ5/2xudf9ucHf/cHJ5/3N2f/9vcnz/b3J8/25xev9wc33/ -cHN9/3Byef9ucHf/bnB3/3Fzev9tb3b/bW91/25xe/9qbXf/bG51/2xudf9sb3n/c3V8/2ptd/9zdXz/ -dXd9/25wd/91d33/b3F1/25xe/93eX//bnB3/3Bzff9ucXv/c3Z//2xvef91eIH/bnF7/3Bzff95fIb/ -d3qD/3l8hv97fof/e32D/3V3ff95fIb/e32D/3N2f/9zdn//bnF7/3Bzff9wcnn/bG95/25xe/91eIH/ -bnB3/3Byef91d33/bG95/3Byef9sb3n/bnB3/3Bzff91d33/amxz/25wd/9wcnn/bnB3/25wd/9ucXv/ -bnF7/2ptd/95e4H/bnF7/25xe/9zdn//cHN9/3Byef9wc33/d3l//3N1fP9wcnn/dXd9/3V4gf9wcnn/ -cHN9/25xe/9ucXv/dXd9/3V4gf9maXP/am13/3Bzff94eX3/c3V8/3N1fP9vcXX/b3F1/3Byef91d33/ -bnB3/2ptd/9wcnn/cHJ5/21vc/9zdXz/bG95/2ptd/91d33/c3V8/3V3ff9qbXf/am13/2xudf91eIH/ -d3qD/3l8hv9+gIb/c3Z//4GDiv9zdn//c3Z//3Bzff9ucXv/am13/3N1fP95fIb/bnB3/25wd/9ucHf/ -cHJ5/2xudf9sbnX/c3V8/2dqcf9sbnX/bG95/25xe/9zdn//bG95/2xvef9ucHf/bnB3/25wd/9wc33/ -cHN9/3N2f/9ucHf/amxz/29xdf91d33/eHl9/2xudf92eHz/bW9z/25wd/9ucHf/bnF7/25wd/91d33/ -dXiB/3V3ff92eHz/bnB3/2xudf9nanH/bnB3/2xudf9vcXX/bG51/2xudf9qbXf/bnF7/2ptd/9qbXf/ -c3V8/2psc/92eHz/c3V8/3V3ff9wcnn/bnB3/3N2f/9wc33/am13/2xvef95e4H/bnB3/3Z4fP9ucHf/ -bG51/2psc/9vcXX/dXd9/3N1fP9sb3n/cHJ5/25xe/95e4H/eXuB/3Byef93eX//bnB3/29xdf9nanH/ -am13/2Rncf9maG7/Zmlz/2tueP9oa3P/am11/2ptd/9qbXf/bG51/2Rncf9qbXf/c3V8/2xudf9qbHP/ -b3F6/2xud/9zdXr/bnB3/3Byef9wcnn/bnB3/3N1fP91eIH/cHN9/3N1fP9sb3n/cHN9/25wd/9nanT/ -b3F1/29xdf9ucHf/bG51/2xvef9ucHf/bG51/2ptd/9ucXv/am13/3Z4fP9sbnX/bW9z/3Byef9wcnn/ -dXd9/2xudf9nanT/bG95/2ptd/9nanT/bG51/25xe/9ucHf/cHJ5/2ptd/9vcnz/bW92/2xvd/9sb3n/ -bG95/2dqdP9nanT/Z2p0/2ttdP9sb3n/bXB4/2xveP9zdn//bG95/2xvef9ucHf/cHN9/3N1fP9qbXf/ -dXd9/3d5f/9qbXf/c3V8/2xudf9tb3P/d3l//2ptd/9ucXv/bG95/3Bzff9qbXf/bnF7/2psc/9maXP/ -cHJ5/2ptd/9qbXf/cHN9/25xe/9sbnX/cHJ5/3N1fP9ucHf/bnB3/2xvef9wcnn/bG51/2xvef9wc33/ -dXiB/2xvef9ucXv/d3l//2xvef9ucXv/bnB3/3Bzff9zdn//dXiB/2xvef9wc33/c3Z//25wd/9ucHf/ -cHJ5/25wd/9nanH/dXd9/25wd/9tb3P/bG51/25wd/9tb3P/bG51/2xvef9sbnX/bW9z/3h5ff91d33/ -cHJ5/3N1fP9wcnn/cHJ5/3Z4fP9wcnn/Z2px/2xudf9zdn//dXd9/25xe/9zdn//cHN9/3Bzff91eIH/ -eXuB/3N1fP9ucXv/d3qD/3t9g/92eHz/fn+D/3l7gf97fYP/fX6B/3t9g/97fYP/c3V8/3Bzff91eIH/ -c3V8/3Byef9zdXz/dXd9/25wd/9+gYr/d3qD/3N1fP9zdXz/cHN9/2xvef95e4H/f4GH/3Bzff9zdXz/ -cHN9/3Bzff9ucHf/bG95/3N2f/9nanT/bnB3/3Byef91eIH/dXiB/3N2f/9zdn//c3V8/3Bzff9zdXz/ -c3Z//25xe/9zdn//bnB3/2xvef9ucXv/dnh8/3Z4fP9wcnn/dnh8/21vc/9zdXz/bG51/2xvef9tb3P/ -c3V8/3V3ff9ucXv/cHN9/2ptd/9nanT/XF9o/2Zpc/9qbXf/amxz/2dqcf9sbnX/bG51/3Bzff9nanH/ -Zmlz/25xe/9qbXf/c3V8/3V3ff91d33/bG51/2psc/9wc33/am13/2dqdP9qbXf/dXiB/25wd/92eHz/ -bnF7/25wd/9sb3n/b3F1/3N1fP9wcnn/bnB3/21vc/9sbnX/dXd9/3N1fP9tb3P/eHl9/29xdf9vcXX/ -Zmhu/3V3ff9ucHf/bG95/3Byef9xdH3/bnF7/3Fze/9ucHf/bnB3/29xdf9sbnX/c3V8/3N1fP9ucHf/ -b3F1/3J0ev9zdn//dnmD/3N2f/91eIH/bnF7/25xe/91eIH/eXyG/3d6g/91eIH/c3Z//3d6g/9wc33/ -bnF7/25wd/9sb3n/bG95/2xvef9zdn//dXiB/3Byef9sb3n/dXd9/3Bzff93eX//bnB3/2ptd/9wcnn/ -cHJ5/3Z4fP9ucHf/bG95/3N1fP9vcXX/am13/2xvef9zdXz/cHJ5/3N2f/9zdn//d3qD/3Bzff9xdH7/ -c3Z9/3J1fP9zdXz/bnB3/2xudf9sb3n/bnF6/21veP9tb3j/c3Z//2xvef9ucHf/bnB3/3N1fP94eX3/ -b3F1/3V3ff93eX//bnB3/3V3ff9ucHf/cHJ5/3V3ff9ucHf/bnF7/2xudf9ucXv/Z2p0/3Bzff9qbXf/ -am13/25xe/9sb3n/Z2p0/2xvef9qbXf/YmVu/2Rncf9maXP/Zmhu/2Zobv9maG7/Z2p0/2Rncf9maG7/ -Zmlz/25wd/9maG7/Zmhu/2xvef9gY2z/Zmlz/2Rncf9nanH/Zmlz/2Rncf9cX2j/Zmlz/2Zpc/9kZ3H/ -YmVu/2Zpc/9nanT/YmVu/3N1fP9nanH/Zmhu/2Zpc/9qbHP/Z2px/2xudf9sb3n/am13/2xudf9wc33/ -c3V8/25xe/9sb3n/am13/2ptd/9zdXz/bnB3/2Zobv9nanT/bnF7/3Bzff9sb3n/bG95/2ptd/9sbnX/ -bG95/2xvef9sbnX/Zmlz/2ptd/9ucXv/am13/3N1fP9sbnX/cHJ5/3Byef9zdXz/dXd9/2xudf9vcXX/ -c3V8/25xe/9wc33/bnF7/3Bzff9sbnX/e32D/3V3ff9ucHf/cHJ5/2xvef9nanT/dXd9/3l8hv9sb3n/ -b3F1/25wd/9ucHf/bnB3/25wd/9zdn//am13/25wd/9wcnn/c3Z//3N2f/9ucHf/cHN9/3Byef9wc33/ -bnF7/3V4gf9ucXv/dXd9/25wd/9qbHP/bnB3/3V3ff91d33/bnB3/3Z4fP9sbnX/c3V8/25wd/9sbnX/ -bG51/25xe/9zdXz/c3V8/3V3ff9zdXz/bG51/2RmbP9nanT/am13/2dqdP9sbnX/bG95/25wd/9ucXv/ -bG51/2dqdP9zdXz/bG95/3V3ff91d33/dXd9/2xudf9sbnX/dXd9/25wd/9vcXX/c3V8/3l7gf9sbnX/ -c3V8/2dqdP9nanT/Zmlz/2ptd/9ucXv/bG95/2xudf9qbXf/amxz/3Bzff9wc33/bG51/3N1fP9sbnX/ -bG51/2Jlbv93eoP/c3Z//3V4gf94e4X/eXuC/3V3ff9ydX3/a254/3Byef9tb3P/bnB3/3Byef9zdXz/ -bW9z/21vc/9xcnj/dHZ+/3l6f/94eoH/foCG/3d5f/95e4H/c3Z//3d6g/97fYP/dXiB/3V4gf9zdn// -c3V8/3N1fP9zdXz/cHN9/2xvef9zdXz/d3qD/3N2f/9zdXz/bG95/3Bzff9wc33/d3l//3Byef9qbXf/ -cHJ5/2xvef91d33/bG51/25wd/91d33/bnB3/2psc/9ucHf/c3V8/2xvef9ucHf/bG51/3Byef9ucHf/ -cnR6/3N1e/9wcnn/dXd9/2ptd/9sb3n/am13/2tudv9qbXf/am13/3Bzff9sbnX/cHJ5/2xudf9qbXf/ -dnh8/21vc/9sb3n/c3V8/2xudf9wcnn/bW9z/3Byef93eX//bnB3/2xvef9sbnX/cHN9/2xudf94eX3/ -bnB3/25wd/93eX//dXd9/25xe/91eIH/dnh8/25wd/9wc33/dXd9/3N1fP9ucHf/bnF7/3l7gf9wcnn/ -bnF7/3N2f/93eoP/bnF7/25xe/93eX//cHJ5/25xe/9ucHf/bnF7/2xvef9ucXv/bG51/2xvef9wc33/ -b3F1/25wd/9wc33/bnB3/2psc/94eX3/bnB3/29xdf9ucHf/bG51/25wd/9ucXv/cHN9/3Byef9ucXv/ -dXiB/3l7gf95e4H/cHN9/3Bzff9ucXv/eHl9/3V3ff9nanH/bG51/3Byef91d33/b3F1/25wd/9tb3P/ -bG51/25wd/9ucHf/bG51/2dqdP9sb3n/am13/2Rncf9qbXf/bG51/3Bzff9qbXf/bG95/2xvef9kZ3H/ -Z2p0/3Bzff9zdXz/c3V8/3N1fP91d33/bnB3/3t9g/9zdn//cHJ5/3N1fP9wcnn/am13/3d6g/95fIb/ -cHN9/3Bzff9zdn//cHN9/3Byef9wcnn/d3qD/2xvef9zdXz/cHJ5/3V4gf95e4H/c3V8/3Bzff91d33/ -d3qD/3d6g/91eIH/d3qD/3d6g/91eIH/dXd9/3t9g/97fYP/e32D/3l8hv97fof/cHN9/3d6g/9wc33/ -c3Z//3N2f/93eoP/eXuB/3V4gf95e4H/dXiB/2ptd/9qbXf/cHJ5/25wd/9sbnX/bG51/2xudf9ucHf/ -c3V8/21vc/9nanT/cHN9/25xe/93eX//dXd9/3Bzff9qbXf/bG51/3N1fP9sb3n/bG51/25xe/91eIH/ -am13/25xe/9kZ3H/amxz/2Rncf9nanT/cHJ5/2ptd/9nanH/Z2p0/2Rncf9maXP/Zmlz/2Zobv9nanT/ -YmVu/2Zobv9cX2j/bnF7/2ptd/9ucHf/b3F4/2tueP9tb3f/am12/2dpb/9maXP/Zmlz/2Rncf9maXP/ -Z2p0/2dqcf9sbnT/a254/2tueP9wc3r/a253/25xe/9tb3P/bnF7/2xudf9sb3n/bnF7/2xudf9qbHP/ -am13/2Rncf9maXP/Z2px/2xudf9iZW7/Z2p0/2xvef9qbXf/amxz/2dqdP9sb3n/bnF7/3V3ff9wcnn/ -bnB3/3Bzff9wc33/e32D/3Bzff9ucHf/d3qD/3Bzff9sb3n/dXd9/3l8hv9zdn//d3qD/3N2f/93eoP/ -cXR9/3Z4fv9ydHv/dHZ9/3Z4fP9ucHf/cHJ5/3Bydv9wcnr/b3F4/25wd/91eIH/bnB3/25xe/9sb3n/ -cHJ5/3Z4fP9tb3P/am13/3N1fP9qbXf/bnF7/2dqcf9ucXv/dXd9/2xvef9ucXv/bG51/2xvef9qbHP/ -dXd9/2ptd/9sbnX/dnh8/3N1fP9sb3n/dXd9/25xe/9nanT/Z2p0/25xe/9sb3n/amxz/2psc/9wc33/ -am13/2xudf9wc33/dXd9/2psc/9qbHP/bnF7/2dqcf9sbnX/bW9z/25wd/9sbnX/bnB3/2xudf9qbXf/ -bnF7/21vc/9vcXX/dXd9/21vc/9qbHP/eXuB/25xe/9wc33/cHN9/2xvef9ucHf/cHJ5/2xvef9ucHf/ -bG95/25xe/91d33/dnh8/25xe/9sbnX/am13/3N1fP9ucXv/YmVu/2ptd/9sb3n/bnF7/2psc/9qbHP/ -Z2px/2dqcf9nanH/Z2px/2dqdP9maXP/am13/2dqdP9kZ3H/bG95/2psc/9wc33/bG95/3Bzff9zdXz/ -Z2px/21vc/9zdn//cHN9/3Z4fP91d33/c3Z//25xe/95fIb/c3Z//25wd/9ucHf/bnB3/2ptd/9zdn// -e32D/25wd/9vcXX/cHN9/25xe/9ucHf/cHJ5/3V4gf9nanT/bnB3/25wd/93eoP/c3Z//2xvef9ucHf/ -bG95/3Bzff9wcnn/cHN9/2xvef9ucXv/bG51/2xudf9ucHf/bnF7/3N1fP9zdXz/dXd9/25wd/9wcnn/ -am13/2xvef9qbXf/cHN9/3Bzff9sb3n/cHN9/2xvef9iZW7/YGNs/2psc/9sb3n/Zmlz/2xudf9sbnX/ -bW9z/3N1fP9tb3P/amxz/3N1fP9ucHf/d3l//3V3ff9ucXv/am13/2ptd/9wc33/am13/2ptd/9ucHf/ -e32D/3Byef91d33/bG51/25wd/9ucHf/cHJ5/3V3ff9ucHf/amxz/25xe/9wcnn/bG95/25xe/9sbnX/ -cHN9/29xdf9sbnX/Z2px/2xvef9qbHP/am13/2xvef9tb3b/b3F5/29yev9tb3P/cHJ5/2xvef9sbnX/ -bG51/3N1fP9vcXX/a211/2xudv9vcXn/cnR7/25wd/9wcnn/bG51/2xvef9qbHP/am13/2xvef9sbnX/ -Z2p0/25xe/9nanT/am13/2xudf9qbXf/Zmlz/2ptd/9sb3n/bG95/2ptd/9qbXf/c3V8/3Byef92eHz/ -cHJ5/25wd/9sb3n/bG95/3N1fP9wcnn/bG51/3N1fP9qbHP/Z2px/2xudf9ucHf/bW9z/3Bzff9qbHP/ -bG51/25weP9xdHv/cXR8/25xe/91d33/b3F1/3N1fP9ucHX/bnB3/21vdf9rbXP/c3V8/2ptd/9sb3n/ -am13/2xudf91d33/bG51/2xvef91d33/bnB3/3Byef9sbnX/cHN9/3V4gf9wcnn/bG95/2ptd/9wcnn/ -b3F1/3h5ff9tb3P/bG51/3N1fP91d33/bnB3/3l7gf9zdn//bnF7/3Byef93eX//d3l//25xe/9wcnn/ -d3l//2xvef9sb3n/cHN9/3V3ff9ucHf/bnB3/3V3ff9ucHf/bG95/2xudf9wcnn/bnB3/3Byef9ucHf/ -bnB3/25xe/9qbXf/bW9z/3Bzff9qbHP/ZGdx/3N1fP9qbHP/am13/2xvef9nanT/amxz/2xudf9qbXf/ -bG51/2xudf9sb3n/dXd9/2xvef9ucXv/bG95/2xudf9zdXz/bG95/2BjbP9maXP/bG95/3Bzff9nanT/ -am13/2dqdP9qbHP/am13/2ptd/9qbXf/Z2p0/25xe/9sb3n/Zmlz/2xvef9sbnX/cHN9/2ptd/9zdXz/ -c3V8/2Rncf9sbnX/dXd9/3N2f/91d33/dXd9/3V4gf9ucXv/dXiB/3Bzff9ucHf/cHJ5/25wd/9sb3n/ -c3Z//3t9g/9sb3n/b3F1/25wd/9ucHf/b3F1/29xdf9zdXz/Zmhu/25wd/9sbnX/c3V8/3Bzff9qbXf/ -bnB3/2psc/9wcnn/am13/3Byef9sbnX/cHJ5/2xudf9tb3P/bG51/3Byef91d33/bnF7/3d5f/9ucHf/ -cHJ5/3Byef9ucHf/cHN9/3V3ff95e4H/dXd9/3V3ff9wc33/bG95/2ptd/9vcXX/bnB3/2ptd/9sb3n/ -bnB3/21vc/9zdXz/bW9z/2psc/91d33/am13/3V4gf94eX3/cHJ5/25wd/9ucHf/cHJ5/2xudf9qbXf/ -bG95/3N2f/9qbXf/bG95/2Rncf9nanT/Zmlz/3Bzff9wc33/am13/2dqdP9sb3n/bnF7/2xudf9ucXv/ -amxz/2xvef9sbnX/bnF7/2Rncf9zdXz/bG51/21vc/9sbnX/b3F4/3FzfP9vcnv/bnB3/3N2f/9zdn// -bnF7/3Byef9wc33/bnB3/25xe/9xc3v/cXR9/3d5gP9wc33/dXiB/3Bzff9ucXv/bnB3/25xe/9wc33/ -bnF7/25wd/93eX//bG95/25xe/9wc33/cHN9/2xvef9wcnn/c3Z//3Bzff9wc33/c3V8/3d6g/91eIH/ -e32D/3Byef9zdn//cHN9/3N2f/93eX//c3Z//3Byef91eIH/cHN9/3Bzff9zdn//d3qD/3V4gf97fYP/ -c3V8/3Bzff9xdH3/cnR7/3F0fv9wc3r/cHJ5/2xudf9wc33/am13/25xev9tb3b/a210/3N1fv9wc33/ -c3Z//2xvef9wcnn/dXd9/2xudf9zdXz/eHl9/3Bzff9zdXz/bnB3/3V3ff93eoP/c3Z//3N2f/91d33/ -eXuB/3N1fP97fof/c3Z//3N2f/9+gIb/e32D/3l8hv9/gYf/d3qD/3N1fP9zdXz/foCG/3t9g/93eoP/ -dXiB/36Ahv91d33/c3V8/3t9g/9+gIb/dXd9/3N1fP93eX//bG95/25wd/9vcXX/c3Z//25xe/91eIH/ -bnB3/3Byef9zdXz/bnF7/3Byef91eIH/cHN9/3V3ff95fIb/cHN9/3V4gf95fIb/dXd9/3N1fP9zdn// -cHN9/3Byef9ucXv/cHN9/3d6g/91eIH/c3Z//3V4gf9ucXv/dXiB/3V4gf9nanT/bG51/3N2f/93eX// -cHN9/25wd/9sbnX/bG51/25wd/9sbnX/c3V8/2xudf91d33/bnB3/2psc/9zdXz/bG51/3V3ff9ucHf/ -c3Z//3h5ff9qbHP/bnB3/3N2f/9wc33/c3V8/3N1fP9zdXz/cHN9/3h5ff9ucHf/bnB3/25wd/9nanT/ -bG95/3V4gf9/gYf/cHN9/3Byef9ucXv/cHN9/3Byef9zdXz/dXiB/2dqdP9wc33/bnB3/3Bzff93eoP/ -c3V8/3N2f/9ucXv/dXiB/3Bzff91eIH/c3V8/3t9g/91eIH/c3Z//3d6g/91eIH/e32D/3l8hv9+gYr/ -eXuB/3l7gf95fIb/dXiB/3t9g/97fof/e36H/3l7gf95e4H/d3qD/25xe/9qbXf/cHJ5/3N1fP9sb3n/ -bnF7/3Byef9wcnn/dXd9/29xdf9qbHP/dnh8/3N1fP93eX//dnh8/2xvef9qbXf/bG95/25xe/9sbnX/ -bG95/2xvef93eX//bG95/25xe/9qbXf/am13/2dqdP9zdXz/bG95/2psc/9nanT/bG95/2xvef9qbHP/ -Z2p0/2dqcf9sb3n/Zmhu/2Rncf9dYGr/cHJ5/2xudf9sb3n/a210/2ttdf9rbnj/aGpx/2Rncf9maXP/ -Zmlz/2Zobv9iZW7/ZGdx/2Jlbv9maXP/aGpw/2xvd/9xc3r/bG51/3N1fP9qbXf/bnF7/2ptd/9sb3n/ -bnF7/25wd/9sbnX/dXd9/2psc/9sbnX/bnB3/29xdf9nanH/bnB3/25wd/9ucXv/bnB3/2xvef9zdXz/ -dnh8/3V3ff9sb3n/cHN9/3Byef9ucXv/c3Z//3Bzff9wcnn/dXiB/25xe/9ucXv/bG95/3V4gf91eIH/ -foCG/3V3ff91eIH/dHeA/3R3fv90d4D/dHeA/3Bzff9ucXv/cHJ5/2xudf9vcXj/bW94/21vdv9zdn7/ -cHN9/3Z4fP9ucHf/c3V8/3V3ff9ucHf/dXiB/3d5f/91d33/cHJ5/2xudf9sb3n/dXd9/25xe/9sb3n/ -Zmlz/25xe/9qbHP/bnF7/2ptd/9qbHP/cHN9/2xvef9ucXv/dXiB/2xvef9tb3P/am13/3N1fP9ucXv/ -Z2p0/2psc/9wcnn/Zmlz/2Zpc/9sb3n/bnF7/2dqdP9sbnX/c3V8/2ptd/9qbXf/amxz/25xe/9sb3n/ -bG95/2dqdP9sbnX/bnB3/25wd/9tb3P/cHJ5/2xudf9qbXf/dXd9/3Byef9ucHf/bnB3/25wd/9ucHf/ -bnF7/3Bzff9ucHf/bnF7/2xvef95fIb/bnF7/25xe/9wc33/bG95/3V4gf9zdXz/ZGdx/2Zpc/9wc33/ -bnF7/2ptd/9sb3n/am13/2xvef9qbXf/amxz/2ptd/9maXP/bnF7/2Zpc/9gY2z/am13/2psc/91d33/ -bG95/2xvef91d33/ZGdx/2psc/9ucXv/dXiB/3Z4fP91eIH/d3l//3d6g/97fYP/d3qD/3N2f/9zdn// -cHN9/3V3ff97fYP/g4WM/3Bzff9ucXv/cHN9/3Byef9ucHf/cHJ5/3V4gf9qbHP/dXiB/25wd/9ucXv/ -dXiB/25wd/9wcnn/am13/3Bzff9ucXv/cHJ5/21vc/9zdXz/bnB3/21vc/9zdXz/bnB3/3h5ff9ucHf/ -dXd9/25wd/9ucHf/c3V8/2xudf9wc33/d3l//3d5f/91eIH/cHN9/3N2f/9nanT/Z2p0/25xe/9sb3n/ -bG95/2xvef9ucHf/bnF7/3V4gf9wcnn/Zmlz/3V3ff9wc33/d3l//3h5ff91d33/b3F1/25wd/9zdXz/ -bnB3/3Byef9ucHf/d3l//25xe/9sb3n/bG51/2xudf9sbnX/cHN9/3V3ff9ucHf/bG51/3N1fP91d33/ -bW9z/25wd/9tb3P/bnF7/2ptd/9sbnX/Zmhu/2xvef9qbHP/bnF7/2xudf9vcXb/cXN7/29xev9sb3n/ -c3Z//25xe/9ucHf/bG95/2xvef9ucHf/cHJ5/21vdv9wcnj/dXd7/29xe/9wc33/bnF7/3Byef9ucHf/ -cHJ5/3Bzff9ucHf/bnB3/3Z4fP9nanT/am13/2xudf9tb3P/ZGZs/29xdf9ucHf/c3V8/25wd/9ucHf/ -bnB3/3N1fP91d33/bnB3/3N2f/9ucHf/bnB3/3N1fP9wc33/cHJ5/3N2f/9sb3n/Z2p0/2ptd/9zdn// -bnF7/3d5f/9wc33/cXN9/3R3f/91eH//dXiB/3V4gf9wc33/bnF7/3Bzff9ucXr/cnR9/3Bzff9ucXv/ -dHZ9/3N2f/91d33/bG95/3Byef91d33/bG95/3Bzff91eIH/c3V8/2xvef9ucHf/c3V8/3V3ff9wcnn/ -bnB3/25wd/92eHz/bG95/3d5f/9ucXv/bnB3/3l7gf9zdXz/c3V8/3l7gf9ucHf/bW9z/2xudf92eHz/ -cHJ5/3Byef9sbnX/dnh8/2ptd/9qbXf/dXd9/3Z4fP9sbnX/bnB3/3d5f/9ucHf/amxz/2xudf9zdXz/ -bnF7/3Bzff9qbXf/bG51/21vc/9wcnn/bnB3/3N2f/9ucHf/bG51/3Bzff9ucHf/bnB3/3Bzff9ucHf/ -b3F1/29xdf9wc33/cHJ5/3N2f/91eIH/foGK/3V4gf95fIb/eXyG/3N2f/9+gYr/d3qD/3Bzff9wc33/ -e32D/3d6g/91eIH/eXyG/3N2f/95fIb/dXiB/3V4gf95fIb/cHN9/3t9g/95fIb/cHN9/3V4gf9wcnn/ -d3l//3V3ff92eHz/eXuB/2dqdP9ucHf/dXiB/2ptd/9ucXv/bG95/3Bzff9sb3n/dXd9/2xudf9qbXf/ -am13/2dqdP9nanT/bnF7/3l7gf9sbnX/bG51/25wd/9sbnX/am13/2xudf9ucXv/ZGZs/2ptd/9maXP/ -bG95/3N1fP9nanT/amxz/2Zpc/9qbXf/bG51/25wd/9tb3P/dXd9/3Byef9sbnX/dXd9/3Byef92eHz/ -c3V8/3h5ff9ucHf/bG51/3V3ff9ucXv/dXiB/3l8hv95fIb/d3qD/3N2f/91eIH/bnF7/25xe/91eIH/ -cHJ5/3Byef9zdn//bnB3/25wd/9wc33/bnF7/2dqdP91eIH/dXiB/3l7gf95fIb/dXiB/3N1fP9wc33/ -c3Z//2xvef9zdn//bnF7/3l7gf9zdn//bnF7/25wd/9vcXX/b3F1/3N1fP9zdXz/bnB3/2psc/9zdn// -dXd9/2xudf9wcnn/bG95/2xvef9sbnX/bG51/1xfaP9ucXv/bG95/3N1fP9tcHr/bW91/3ByeP9tb3j/ -aGp0/2xvef9qbXf/bG95/2dqdP9sbnX/bnB3/29xef9oa3X/bG93/3Byev9rbnj/bnF7/2xudf9sb3n/ -bG95/2xvef9sb3n/bnB3/2ptd/9wc33/Z2p0/2ptd/9qbXf/bG51/2Jlbv9qbHP/Z2p0/2xvef9qbHP/ -amxz/2ptd/9ucXv/bG95/2psc/9ucXv/am13/2xudf9ucXv/bG95/2xudf9sbnX/ZGdx/2dqdP9kZ3H/ -bG95/3Byef9zdXz/bG95/21vdP9ucHf/cnR6/3Fzev9vcXj/bG95/2xudf9ucHf/bG51/2ptd/9rbnj/ -a254/3J1fv91d33/dXd9/29xdf9wcnn/c3Z//25xe/91eIH/d3qD/3N2f/9ucHf/bnB3/3N1fP93eX// -bnF7/25xe/9qbXf/c3Z//3Bzff91d33/bnF7/2xudf94eX3/cHJ5/3V3ff91eIH/bnF7/25wd/9sb3n/ -dXd9/25wd/91d33/bG51/3Z4fP9qbHP/Z2p0/3Bzff92eHz/bG51/3Byef92eHz/bW9z/2xudf9vcXX/ -dnh8/3N1fP9zdXz/bnB3/29xdf9ucHf/cHJ5/29xdf91d33/bG51/2ptd/9ucXv/am13/2psc/9wc33/ -Zmlz/2ptd/9maXP/am13/2dqcf9maXP/Z2px/25wd/9kZ3H/Zmhu/2Zpc/9nanH/cHJ5/2Zpc/9gY2z/ -YmVu/2Zpc/9qbXf/Zmhu/2dqdP9iZW7/Z2p0/2Zobv9maG7/am13/2Rncf9maXP/Zmhu/2BjbP9maXP/ -ZGdx/2ptd/9nanT/bG95/3Byef9kZ3H/ZGdx/2ptd/91d33/dXd9/3V3ff94eX3/cHJ5/3N2f/9ucXv/ -c3V8/3V4gf9zdXz/bnB3/3N2f/9+gIb/bnB3/29xdf9ucHf/bG51/2xudf9ucHf/dXd9/2ZobP9ucHf/ -bG51/25wd/92eHz/bG51/2xudf9qbHP/bnB3/29xdf9ucHf/bG51/3Bzff9qbXf/bG51/25xe/9wc33/ -bG95/3Bzff9zdXz/am13/2xudf91d33/bG51/3Byef91d33/d3l//3N2f/9ucXv/cHN9/2xvef9sbnX/ -cHJ5/29xdf9sbnX/bG95/2ptd/9vcXX/c3V8/3Byef9maG7/c3V8/3N1fP92eHz/d3l//3V4gf9ucHf/ -cHN9/3Bzff9wcnn/d3qD/3Bzff95e4H/cHN9/2xvef9sb3n/bnB3/29xdf91d33/dXd9/3Bzff9sb3n/ -dXiB/3V3ff9ucHf/cHJ5/3Byef9wcnn/bnB3/3Byef9maG7/cHJ5/25wd/9wc33/bnB3/25weP9wcnn/ -bXB5/25wd/9wcnn/b3F1/3N1fP9sbnX/bnB3/3Byef9vcXj/bG52/2xvef9vcnv/bXB5/2xvef9sbnX/ -bG95/2Zpc/9nanT/Z2p0/2psc/9nanH/cHN9/2Zpc/9qbXf/am13/2ptd/9iZW7/bG51/2xvef91d33/ -bnB3/25wd/9zdn//d3qD/3N2f/9wcnn/dXiB/3N2f/9zdXz/eXyG/3V4gf91d33/dXiB/3N1fP9zdn// -bnF7/3l8hv99foH/foCG/3V4gf91d33/dXiB/3V3fv90d4D/cXR+/25xe/9wcnn/c3Z//3Byef9wcnr/ -cHJ5/2tueP90d4D/d3l//3V3ff9ucHf/cHN9/3V3ff9wc33/c3Z//3d6g/91d33/bG95/2xvef9zdn// -eXyG/25xe/9ucHf/bnB3/3Z4fP9wcnn/c3V8/2xudf9nanH/cHN9/2ptd/9ucXv/d3l//21vc/9tb3P/ -b3F1/3Z4fP9ucHf/cHJ5/2ptd/94eX3/bnB3/2dqcf9ucHf/c3V8/2psc/9wcnn/dnh8/29xdf9qbHP/ -bW9z/3N1fP9zdXz/cHJ5/2xudf9qbXf/am13/2xvef9qbHP/am13/2dqcf9kZ3H/am13/2psc/9maG7/ -Z2p0/1xfaP9gY2z/YmVu/2dqdP9kZ3H/ZGdx/2Zobv9ucHf/Zmlz/2Rncf9nanT/Z2px/25xe/9qbXf/ -ZGdx/2Zpc/9wc33/c3V8/2xudf9zdXz/bG51/2xvef9qbXf/am13/3N1fP9ucHf/cHJ5/25xe/9maXP/ -cHN9/25wd/92eHz/cHJ5/25xe/9zdXz/amxz/2xudf91d33/dXd9/3N1fP92eHz/d3l//3N1fP91d33/ -bG95/29xdf9wcnn/amxz/2xudf9wcnn/eXuB/3Byef9tb3P/bG51/2Zpc/9nanT/am13/3N1fP9gY2z/ -am13/2dqdP9qbXf/bnF7/2dqcf9ucHf/bnB3/29xdf9ucHf/cHJ5/29xdf91d33/cHJ5/21vc/9wcnn/ -dXd9/3Byef92eHz/dnh8/25xe/9ucXv/eXuB/3N1fP91eIH/e36H/3t+h/93eX//cHN9/3N2f/9ucHf/ -am13/3V3ff9ucHf/bG95/3Byef9sb3n/bnF7/3N2f/9ucXv/am13/3N1fP9ucXv/dXd9/3d5f/91eIH/ -bG95/25wd/9ucXv/bnB3/3N2f/9sb3n/d3l//3Bzff9ucXv/bG95/25wd/9ucHf/d3l//3Z4fP9sb3n/ -am13/3V3ff9zdXz/bnB3/3N2f/9wc33/cHN9/3N2f/91eIH/Z2p0/25xe/9ucHf/dXd9/3R3gP9wcnv/ -cnR8/3Bzff9ucXv/c3Z//25xe/9zdn//bG95/3Bzff9zdn//bnF7/3F0ff9zdn//cXR+/3F0ff9wcnn/ -bW9z/3N1fP9ucHf/bG95/2ptd/9qbHP/amxz/2xvef9maXP/Z2p0/2ptd/9qbXf/ZGdx/2psc/9qbXf/ -dXd9/2xudf9tb3P/cHJ5/3N1fP9wc33/Z2px/25xe/9sbnX/bW9z/3Byef9sbnX/am13/2xudf9ucHf/ -bG51/2Zpc/9ucXv/dXd9/3N1fP9sbnX/bG92/29xef9wc3v/dHd//3F0ff9wcnn/cHJ5/3Byef9ydHz/ -bnB4/21weP9tb3f/cHN9/3Bzff9wc33/amxz/2xvef95e4H/dXiB/3N2f/9+gYr/eXyG/3d5f/93eX// -foCG/4OFjP97fYP/dXiB/25xe/95fIb/c3Z//3t9g/9wc33/cHN9/3d5f/9wc33/c3Z//3d6g/9ucXv/ -cHN9/29xdf93eX//bnB3/3N1fP9ucHf/eHl9/2psc/9maXP/bG95/25xe/9maXP/bG51/3N1fP9sbnX/ -Zmlz/2xudf9zdXz/cHN9/25xe/9qbXf/am13/2Zpc/9ucXv/amxz/2dqdP9maXP/Zmlz/25xe/9qbHP/ -Z2px/2dqdP9iZW7/Zmhu/2Jlbv9nanT/Zmhu/2Zpc/9maG7/bnB3/2dqdP9kZ3H/Z2p0/2Rncf9nanT/ -ZGdx/11gav9gY2z/am13/2ptd/9maG7/am13/2dqcf9ucXv/bnF7/2ptd/9zdXz/am13/2ptd/9qbXf/ -Z2px/3N1fP9ucHf/eHl9/3Bzff9wc33/d3l//2xudf9ucHf/c3Z//3l7gf91eIH/eXuB/3l8hv91eIH/ -dXiB/3V4gf9wc33/dXiB/25xe/9ucHf/bnF7/3l8hv9zdn//cHJ5/3Bzff9ucXv/cHN9/3V4gf9+gIb/ -bG95/3V4gf9zdXz/dXiB/3d6g/9qbXf/cHJ5/2xvef9wcnn/bG95/2xvef9sb3n/c3V8/3N1fP9ucHf/ -c3V8/3N1fP9wc33/dXd9/3d5f/9sb3n/cHJ5/3N1fP9qbXf/bG95/3V3ff91d33/dnh8/3V3ff9ucXv/ -bnB3/2xvef91eIH/c3V8/2xvef9wc33/am13/3Byef93eoP/cHN9/2dqdP9wc33/cHN9/3V3ff94eX3/ -dXd9/2xudf9vcXX/bnB3/2dqcf9wcnn/bG51/3V3ff9wcnn/bG51/2ptd/9nanT/bG51/25xe/9qbXf/ -Z2px/2Rncf9ucXv/Zmlz/2Jlbv9kZ3H/Z2px/2Zpc/9qbXf/Z2p0/11gav9nanT/amxz/25xe/9qbXf/ -a211/2lrdP9oa3X/aWtz/2xvef9sb3n/cHN9/2psc/9wcnn/bnB3/2xuc/9sb3n/amx1/2hrdP9oam// -ZGdx/2Zobv9nanT/Zmlz/2Zpc/9nanH/ZGdx/2dqcf9ucXv/am13/2ptd/9sb3n/bG95/2Zpc/9qbXf/ -bnB3/3V3ff9wcnn/bnB3/25xe/9zdn//c3V8/25wd/9wc33/bnF7/25wd/91d33/bnB3/25wd/9ucHf/ -bnB3/2ptd/9maG7/c3V8/3N1fP9wcnn/bG51/21vc/9ucHT/bnB3/3Byef9wcnr/bG95/2xvef9ucHf/ -cnR7/2xudv9rbXb/aWx2/25xe/9zdXz/dXd9/25wd/91d33/c3V8/2xvef9qbXf/d3l//2xvef9qbHP/ -bG51/25xe/91eIH/bnF7/25wd/9kZ3H/dXd9/2ptd/9ucXv/am13/2xvef9sb3n/bG51/2xvef91d33/ -am13/2ptd/9sbnX/dXd9/25wd/91d33/bG51/3Z4fP9nanT/am13/25wd/9zdXz/bG51/29xdf9zdXz/ -b3F1/2psc/9ucHf/dXd9/3N1fP9ucXv/am13/2ptd/9qbXf/cHN9/2xudf9ucXv/bG51/25wd/92eHz/ -bG51/21vc/9zdXz/bG51/29xdf9qbXf/cHN9/25xe/9zdXz/bnB3/3h5ff9zdXz/bnB3/25wd/9vcXX/ -c3Z//25xe/9sb3n/bG95/3d5f/9zdn//cHN9/3d6g/9wcnn/dXiB/3V4gf9wcnn/e32D/3Bzff9zdn// -cHN9/2ptd/9ucXv/bG95/3d5f/9wc33/c3Z//3d6g/9sb3n/cHN9/3l7gf95e4H/cHN9/3V4gf91eIH/ -c3V8/25wd/9wc33/bG95/3V4gf9qbXf/cHJ5/25xe/93eoP/cHN9/29xdf9zdXz/bnB3/21vc/9qbXf/ -cHN9/2Rncf9ucXv/Z2p0/25wd/91d33/amxz/21vc/9tb3P/am13/25wd/9ucXv/bG95/3d5f/91eIH/ -dXiB/3V4gf9zdn//dXiB/3V4gf95e4H/c3Z//3d6g/97fYP/dXiB/3d6g/97fof/e36H/3d6g/93eoP/ -cHN9/25xe/9sb3n/dXd9/2xvef9ucXv/cHN9/2xudf9sb3n/bnF7/2dqdP9gY2z/Z2p0/2ptd/9wcnn/ -cHN9/2ptd/9nanT/bG51/2xvef9kZ3H/bnF7/2ptd/93eX//bnB3/21vc/9qbXf/am13/2xvef93eX// -cHN9/2ptd/9maXP/dXd9/3Bzff9qbXf/bnF7/2xvef9wcnn/c3V8/3V3ff9maG7/amxz/2ptd/9wc33/ -bnF7/25wd/9ucHb/bW93/3J0e/9zdn//cHN9/3V4gf9sb3n/dXiB/25xe/9sb3n/b3J8/21wev9tcHr/ -b3J7/2xvef9sbnX/bnF7/2dqdP9sbnX/amxz/2ptd/9sbnX/cHJ5/2xudf9sbnX/cHJ5/2xvef9kZ3H/ -bG51/25wd/91d33/cHJ5/29xdf9ucXv/dXiB/3N2f/9ucHf/cHN9/3Bzff9wcnn/c3Z//25xe/9qbXf/ -bnF7/2xvef9ucHf/ZGdx/25xe/9ucXv/bG95/2dqdP9qbXf/bW92/2tudv9sb3n/bG95/2dqdP9maXP/ -Zmlz/2xudf9laHH/Y2Zw/2Zpc/9ydHv/bnF7/2ptd/9sbnX/cHN9/25xe/9qbXf/am13/3Byef9qbXf/ -Z2p0/2xudf9zdXz/d3l//3V3ff9ucHf/amxz/3l7gf9wc33/cHN9/25wd/9ucHf/cHN9/3Byef91eIH/ -eXuB/3Byef9wc33/bnB3/3d6g/9wc33/dXiB/3N1fP95fIb/dXd9/3N1fP9zdn//c3Z//3Bzff9zdn// -d3qD/3Bzff9sb3n/c3Z//3l8hv97fYP/dXiB/3N2f/9zdn//c3V8/3t9g/9zdn//dXiB/25wd/9wcnn/ -c3Z//25wd/9ucHf/dXd9/2psc/9ucHf/Z2p0/3Bzff9ucXv/cHN9/2xvef93eX//c3Z//3Bzff9wc33/ -bnB3/3N2f/9wc33/cHJ5/2xvef95e4H/cHN9/3Byef93eX//cHJ5/3V4gf9zdn//bG95/3d5f/9zdXz/ -cHN9/2xvef9sb3n/bnB3/3Byef93eX//c3V8/25xe/95e4H/bG95/2xvef95e4H/dnh8/25wd/93eX// -d3l//25xe/9sb3n/cHN9/25wd/9zdn//bG95/25wd/9ucXv/eXyG/3N1fP9tb3P/c3V8/25wd/9vcXX/ -bG51/3Byef9maG7/cHJ5/25wd/9wc33/dXd9/2xudf9ucHf/bnB3/2xudf9ucHf/cHJ5/3Byef92eHz/ -cHJ5/3N1fP9wc33/bnF7/2xvef9sb3n/bnF7/2ptd/9ucXv/cHN9/25wd/9ucHf/dXd9/3d5f/9zdn// -dXd9/25xe/9sb3n/bG95/3V3ff9ucHf/bnB3/3N1fP9sbnX/bnB3/3Z4fP9ucHf/Z2px/2xvef91eIH/ -d3qD/3d6g/91eIH/am13/2xvef9ucXv/bnB3/3Byef9sbnX/dXd9/2xvef9sbnX/bG51/2xudf9qbXf/ -dXd9/25xe/9nanT/Z2p0/3Bzff9zdXz/amxz/2xvef9qbXf/am13/25xe/9wc33/YmVu/2dqdP9sbnX/ -bnF7/2xvef9pbHb/a254/2xuc/9rbnX/cHJ5/25wd/91d33/am13/3Bzff9wcnn/cHJ5/29xef9ucHn/ -bnF5/29ye/9sb3n/amxz/25xe/9ucXv/am13/2dqdP9tb3P/bG51/25xe/9tb3P/bnB3/3Bzff9wcnn/ -Zmhu/25wd/9wcnn/c3Z//3N2f/9sb3n/bG95/3Bzff9zdn//bnB3/3Bzff9zdXz/bnB3/3V4gf9wc33/ -am13/3Bzff9ucHf/bnB3/2Zpc/91eIH/d3qD/3Bzff9sb3n/cHJ5/2xvef9rbnj/cHJ3/2xudv9qbXf/ -Zmlz/2xudf9qbXf/aGp0/2dqdP9tb3X/dXd8/3V3ff9wcnn/bW9z/3d5f/9zdXz/bnF7/25wd/91d33/ -c3V8/2xudf9vcXX/d3l//3l7gf92eHz/bnB3/2dqdP93eX//cHN9/25xe/9wcnn/cHJ5/3N2f/9wcnn/ -d3qD/3l8hv9zdXz/cHN9/2xvef93eX//cHJ5/3N1fP9ucHf/dXd9/2xudf9tb3P/b3F1/25wd/9maG7/ -bG51/3Byef9qbHP/YmVu/25wd/93eX//dXd9/25wd/9sbnX/cHJ5/29xdf91d33/b3F1/3Byef9ucHf/ -b3F1/3N2f/9ucHf/bnB3/3V4gf9qbXf/c3Z//3Bzff95e4H/eXuB/3d6g/9zdn//foCG/31+gf97fYP/ -d3l//3h5ff97fYP/d3qD/3N2f/9wc33/e32D/3d6g/9wc33/e32D/3N2f/95fIb/d3qD/25xe/95e4H/ -dXiB/3V4gf9ucXv/bG95/25wd/9wcnn/d3qD/25xe/9wcnn/dnh8/2xudf9sbnX/dXd9/3N1fP9wcnn/ -eHl9/3Z4fP9ucHf/am13/2xvef9nanT/bG95/2dqdP9sbnX/bG51/3N2f/9wc33/amxz/2ptd/9nanT/ -am13/2xvef9sb3n/ZGdx/3Bzff9ucHf/c3V8/3N1fP9nanH/bG51/2ptd/9qbXf/am13/3N1fP9ucHf/ -dXd9/3N1fP91d33/c3V8/25wd/9wcnn/bG95/2ptd/9nanT/bnF7/3Z4fP9sbnX/bnB3/3V3ff93eX// -c3V8/25xe/9qbXf/am13/2xudf9zdXz/am13/2xvef9ucXv/Zmlz/2xudf9zdXz/bnB3/2Vmav9ucHf/ -c3V8/3l7gf9wc33/c3Z//2dqdP9wcnn/bG51/2psc/9zdXz/bG51/3V3ff9wcnn/bW9z/2ptd/9sbnX/ -cHN9/3V3ff9ucXv/am13/29xdf92eHz/c3Z//29xdf9wcnn/cHN9/25xe/9wc33/dXd9/2dqcf9qbXf/ -bnB3/3Bzff90d4D/cnR7/29yfP9sb3n/bnF7/3N2f/9zdn//eXuB/3N1fP91eIH/dXiB/3V4gP9ucXv/ -b3J8/3BzfP9vcnv/bnF7/25wd/9zdn//bG95/29xdf9sb3n/b3F1/25wd/9zdn//bnB3/25wd/9wc33/ -cHN9/2Zpc/9wcnn/c3V8/3V4gf91eIH/bnB3/2xvef9zdn//dXd9/2xvef9zdn//dXiB/25xe/93eX// -bnF7/2ptd/9wc33/bnB3/25wd/9qbXf/d3l//3V4gf9zdn//bG95/3Byef9tb3b/bW94/29ye/9wcnn/ -bnB3/2xvef9sb3n/c3V8/2xvef9qbXf/b3F5/3V3ff94eX3/c3V8/25wd/94eX3/d3l//3V3ff9ucHf/ -d3l//3V3ff9tb3P/bW9z/3V3ff95e4H/cHJ5/2ptd/9maXP/c3V8/2dqdP9nanT/Z2p0/2dqdP9qbXf/ -Zmlz/2xvef91d33/Z2p0/2xudf9nanT/dXd9/2ptd/9ucXv/am13/3d5f/9ucHf/bnB3/3Byef9ucXv/ -ZGdx/2xvef9wc33/bnB3/2psc/9wcnn/e32D/3V3ff9ucHf/bG95/25wd/9ucHf/eXuB/25wd/9ucXv/ -bG95/2xvef93eX//bnB3/25xe/91eIH/bG95/3Byef9sbnX/dXd9/3Byef9ucHf/bG51/3Z4fP9zdXz/ -am13/2xudf9sbnX/bnB3/25xe/9qbHP/Zmlz/3V3ff9ucXv/bG51/3V3ff9tb3P/am13/2ptd/9kZ3H/ -dXd9/2xvef9ucHf/am13/2ptd/9qbXf/bG51/3V4gf9sb3n/bnB3/3V3ff9sbnX/bG95/3V3ff9zdn// -bnF7/3d5f/95e4H/cHN9/3Bzff91eIH/bnB3/3Bzff9ucHf/bnF7/29xdf95e4H/c3Z//2xvef9wcnn/ -bG51/2xvef9ucXv/bnF7/2Zpc/9zdn//bnB3/3N1fP9zdXz/Zmhu/29xdf9ucHf/cHJ5/29xdf94eX3/ -c3V8/3N1fP9ucXv/bnF7/3Bzff9sb3n/bnF7/2xvef9sb3n/Z2px/25xe/9zdXz/amxz/2ptd/9ucXv/ -dXd9/2xvef9qbXf/Z2px/2psc/9kZ3H/am13/2psc/9qbXf/bG95/2Rncf9sbnX/cHJ5/2xudf9lZmr/ -bnB3/3V3ff93eoP/cHN9/3d5f/9qbXf/cHJ5/29xdf9qbHP/dXd9/2psc/93eX//cHN9/2xvef9sb3n/ -bG95/3V4gf93eoP/cHJ5/25wd/9tb3P/dXd9/3V3ff9qbHP/bG95/2xvef9wcnn/am13/25xe/9maG7/ -bG95/2xvef9zdn//b3J8/3Fzev9vcnr/a253/2xudf9ucXv/am13/3N1fP9sbnX/cHN9/25xe/9qbXf/ -bnF6/25xef9tcHr/bXB6/2ptd/9qbXf/bG95/2psc/9qbHP/Z2p0/2dqcf9sbnX/bnF7/2psc/9maXP/ -bG95/2xvef9gY2z/Z2p0/21vc/9ucHf/bnB3/2psc/9sbnX/bG95/3N1fP9qbXf/bnF7/3Z4fP9wcnn/ -d3l//3Bzff9qbXf/c3V8/2xudf9sbnX/amxz/3V3ff9zdXz/c3V8/2psc/9ucHf/b3F4/25wd/9xc3n/ -bnB3/2ptd/9sbnX/bnB3/2xvef9qbXf/aWx2/29xeP91d33/dnh8/3N1fP9sbnX/dnh8/3d5f/9zdXz/ -bnB3/3V3ff9zdXz/bW9z/2xudf92eHz/d3l//3Bzff9sb3n/Z2p0/3Bzff9ucXv/bG95/2ptd/9qbXf/ -am13/21vc/91d33/eHl9/29xdf9ucHf/bG51/3Z4fP9sbnX/dXd9/2xudf93eX//bnB3/21vc/9tb3P/ -c3V8/2Rncf9wcnn/dXiB/3Bzff9ucXv/dXiB/4GDiv91eIH/bnF7/25wd/9ucHf/bG95/3Z4fP9ucHf/ -bG95/25wd/9qbXf/d3l//25wd/9sb3n/c3Z//25wd/9wc33/Zmlz/3N2f/9zdn//bnF7/2xvef93eX// -dXd9/3Bzff9ucHf/am13/3Bzff9wc33/bnB3/2ptd/92eHz/cHN9/29xdf91d33/bnF7/25xe/9wcnn/ -Z2p0/3d6g/9zdn//c3Z//3Bzff9ucXv/cHJ5/3Byef91eIH/bnF7/2xvef91d33/bnB3/3N2f/95e4H/ -bnB3/2xvef91d33/cHN9/2ptd/9nanT/bG95/2Zpc/9nanT/Zmhu/2dqcf9kZ3H/c3V8/25xe/9maXP/ -am13/2Zpc/9qbHP/am13/2ptd/9kZ3H/cHN9/2dqdP9wcnn/bG95/2BjbP9qbHP/amxz/2ptd/9sbnX/ -cHN9/25xe/9wc33/bnF7/25xe/9ucXv/am13/3N1fP9zdXz/c3V8/2xudf9zdXz/dnh8/3Byef9ucHf/ -dXd9/3N1fP9ucXv/cHJ5/2ptd/9ucXv/am13/3Bzff9sb3n/bG95/25wd/9ucHf/bG95/3Bzff9ucXv/ -Z2p0/3Bzff9wc33/eXuB/3V3ff92eHz/Z2px/2xvef9wcnn/Z2p0/3N2f/9nanT/d3l//3Bzff9tb3P/ -bnB3/29xdf9zdn//d3l//3Bzff9sb3n/bG95/3V4gf94eX3/bnB3/3N1fP9zdXz/cHJ5/2xvef9zdn// -amxz/2psc/9nanT/bnF7/2hqdP9ucHb/bXB4/2xvdv9ucHf/dXd9/29xdf92eHz/b3F1/3Z4fP9zdXz/ -bnB3/3Byef9wcnn/cXN6/3N1fP9wcnn/cHJ5/3Z4fP9ucXv/bG95/2xvef9sb3n/bG95/3V4gf9zdXz/ -cHJ5/3V4gf9wc33/am13/25xe/9ucHf/bG95/25wd/9vcXX/bG51/3N1fP91d33/bG51/3Bzff9zdXz/ -bnB3/3N1fP9sbnX/Z2px/2xvef9vcXX/bnB3/2Rncf9zdXz/bG95/2xvef9maXP/bG95/2hrdf9wcnn/ -cHJ7/3J0fP9ucHf/Z2p0/25xe/9zdXz/b3J7/2ptdf9sb3n/c3V8/3V3ff9sb3n/bG51/3V3ff91eIH/ -bnF7/3Byef92eHz/dXd9/2xudf9sbnX/dnh8/3d6g/91d33/cHN9/2ptd/91eIH/d3qD/3d6g/9ucHf/ -bG95/25wd/9ucHf/dXiB/3l7gf9wc33/c3V8/3N2f/9+gYr/eXuB/35/g/92eHz/f4GH/3V3ff91eIH/ -dXd9/35/g/9wcnn/eHl9/31+gf93eX//eHl9/3d5f/+Fh43/fn+D/3l7gf92eHz/dXd9/3Bzff9+gYr/ -c3Z//3Bzff9sb3n/cHN9/3l7gf9wcnn/c3V8/3V4gf9zdXz/dXiB/2dqdP9zdn//c3Z//3Bzff9sb3n/ -dXd9/3Z4fP9wc33/bG51/2Zpc/9wc33/cHJ5/29xdf9ucHf/dXd9/3Byef9ucHf/eHl9/2xvef9ucHf/ -cHJ5/25wd/93eX//dXd9/3Byef9ucHf/bnB3/2xudf9vcXX/dXd9/2xudf9sbnX/c3V8/2ptd/9wcnn/ -eHl9/3Bzff91eIH/dXiB/3V3ff9wcnn/bnB3/3V3ff9qbHP/cHN9/3Byef9ucXv/bG95/3V4gf93eX// -Z2p0/25xe/9sb3n/bnB3/3N1fP9ucHf/bG51/3Bzff9nanT/am13/25xe/9maXP/am13/2xudf9sbnX/ -bG51/3V3ff9ucHf/cHJ5/3N1fP9ucXv/c3V8/25wd/9ucHf/cHJ5/3N1fP9vcXX/dXd9/3h5ff9wcnn/ -cHJ5/3V3ff9zdXz/cHJ5/25wd/9qbHP/bnF7/2xudf9sb3n/bG95/2dqdP9nanT/Zmhu/2Rncf9nanT/ -Z2px/1xfaP9maG7/ZGdx/3Byef9maXP/bnB3/1lcZf9iZW7/Zmhu/2Jlbv9nanT/XWBq/2xvef9nanT/ -amxz/2xudf9qbHP/bnF7/3d5f/9qbXf/Zmlz/2xudf91eIH/d3l//2xudf9zdXz/cHJ5/3N1fP9sb3n/ -dXd9/2Zpc/9maG7/Z2px/2ptd/9oanT/bnB5/29xeP9ucHj/bG51/3Z4fP9vcXX/dnh8/29xdf91d33/ -bnF7/3Bzff91eIH/dHZ+/3N1ff9zdn3/bnF7/25xe/91d33/cHJ5/25wd/9ucHf/bnB3/25wd/9wc33/ -b3F1/29xdf9ucHf/bG51/2Zobv9tb3P/bW9z/2xudf9sbnX/am13/2psc/9wc33/c3V8/2xudf9wc33/ -cHN9/25xe/9wc33/bW9z/2xudf9zdXz/b3F1/25wd/9maG7/dnh8/3Byef9zdXz/Z2px/3Byef9ucHj/ -cHJ6/25xef9tb3b/bG51/2RmbP9sbnX/bnF4/25wd/9sb3j/dHZ+/3V4gf95e4H/bnF7/3Byef91eIH/ -dnh8/3Byef9ucXv/c3V8/3N1fP9ucHf/b3F1/3d5f/97fYP/dXd9/3Bzff9sb3n/d3l//3Z4fP9zdXz/ -amxz/2xudf9qbXf/am13/2xvef9zdXz/amxz/2psc/9kZ3H/c3V8/2Zpc/9qbXf/ZGdx/3Byef9iZW7/ -ZGZs/2Rncf9maXP/XV9l/2Rncf9nanT/ZGZs/2BjbP9iZW7/cHN9/2ptd/9maG7/YmVu/2Jlbv9iZW7/ -cHJ5/2dqcf9kZ3H/YGNs/2Rncf9kZ3H/YmVu/2dqcf9qbXf/bG51/2ptd/9iZW7/bnF7/25xe/9qbXf/ -bG51/3N1fP91d33/c3V8/25wd/9qbHP/cHN9/3Bzff9wcnn/cHJ5/3d6g/91eIH/cHJ5/3t9g/9wc33/ -c3Z//3N2f/9wcnn/eXyG/3l7gf9ucXv/cHJ5/2xvef9wcnn/bnB3/3d6g/9ucXv/cHJ5/3t9g/9wc33/ -d3qD/3d6g/9wc33/d3qD/3t9g/9zdn//cHN9/3Byef91d33/Z2p0/2xvef9ucHf/c3Z//25xe/93eoP/ -eXuB/2xvef9zdn//cHJ5/25xe/9wc33/b3F1/2xudf9zdXz/am13/25wd/9wcnn/Zmlz/2ptd/9sbnX/ -bG95/2ptd/9zdXz/bW9z/25xe/9zdXz/c3V8/3Bzff9sbnX/bnB3/3Bzff9sb3n/bG51/3V3ff93eX// -bnB3/3Byef9wcnn/cHJ5/3Byef91d33/bG51/3Byef9tb3P/bnF7/25xe/9sb3n/am13/2xudf9nanT/ -am13/2dqdP9iZW7/am13/25xe/9zdn//bG95/3V3ff9kZmz/bW9z/21vc/9ucHf/dXd9/2dqdP95e4H/ -cHN9/2xvef9sb3n/bnF7/3Bzff93eX//bnF7/2xvef9ucXv/e36H/3d6g/9ucHf/dXd9/3Byef9wcnn/ -bnB3/3N1fP9qbHP/bG51/2xudf91d33/bW93/29xeP9tcHj/aGt1/2Vocf9ucXv/amxz/3d5f/9sbnX/ -bnF7/3Byef9wcnn/cXN6/3F0ev9wc33/c3Z//3Byef9wc33/eXuB/3Bzff9wc33/bnF7/3Bzff9ucXv/ -cHN9/25wd/9ucHf/cHJ5/21vc/9nanH/b3F1/25wd/9ucHf/bG51/2ptd/9sbnX/dXd9/3N1fP9qbXf/ -cHN9/3Byef9wcnn/c3Z//2xudf9sbnX/c3Z//2ptd/9ucHf/ZGdx/3N2f/9zdn//c3Z//2ptd/9zdn// -cXN7/3N2gP91eIH/cnV//3N1fP9qbXf/cHJ5/29xeP9ucHj/bW94/3J0e/90d3//eXyG/3Bzff9ucXv/ -d3l//3d5f/9ucXv/c3V8/25xe/9wcnn/bnB3/25wd/91d33/e36H/3Z4fP9wcnn/bnB3/3V4gf91d33/ -dnh8/25wd/9wcnn/c3V8/3Byef9zdn//e32D/2xvef9sb3n/Z2p0/3d6g/9zdn//dXiB/25wd/93eX// -Z2p0/2xvef9ucHf/c3V8/2ZobP9sbnX/c3V8/2psc/9nanT/amxz/3l7gf9ucXv/Zmlz/2Zobv9sbnX/ -ZGdx/3Bzff9maG7/amxz/2Zpc/9qbHP/bnB3/2xudf9ucHf/cHJ5/2xvef9wc33/Z2p0/3Bzff9wc33/ -dXiB/3N2f/93eoP/d3qD/3l7gf91d33/c3Z//3V4gf95fIb/cHN9/3N1fP95fIb/d3qD/3V3ff95fIb/ -cHN9/3V4gf9wc33/bnB3/3d5f/91d33/bnB3/2xudf9sbnX/bW9z/25wd/94eX3/bG95/2xvef93eX// -bnB3/3N1fP9zdn//bnF7/3d6g/93eX//cHN9/3Bzff9zdn//dXd9/2psc/9ucHf/bW9z/2xvef9qbXf/ -c3V8/3V3ff9kZ3H/bG51/2dqcf9maG7/Z2p0/2Rncf9kZ3H/bG95/2dqcf9qbHP/Z2p0/2Rncf9qbHP/ -Z2px/2psc/9qbHP/cHN9/2ptd/9zdXz/c3V8/3N1fP91d33/cHN9/3Bzff91eIH/bnF7/25wd/9zdn// -d3qD/3Bzff9zdn//c3Z//3N2f/91eIH/dXiB/3Byef93eoP/cHN9/3d6g/95fIb/d3qD/3d6g/9wc33/ -c3Z//3V4gf9wc33/am13/3N1fP93eoP/e32D/3l7gf95fIb/am13/3N2f/9zdXz/c3V8/3l7gf9sb3n/ -eXuB/3V4gf9ucHf/bnB3/25xe/9zdXz/d3l//25xe/9nanT/bnF7/3d6g/93eoP/bnF7/3Bzff91d33/ -cHN9/25xe/93eX//Zmlz/2xvef9zdXz/e32D/3Bzff9zdXv/dHZ//3F0fv9sb3n/d3qD/3N1fP93eoP/ -cHJ5/3N2f/9zdn//c3Z//3Bzff9zdX3/dHeA/3V4gf9zdn//cHN9/3d6g/9wc33/bnB3/2dqdP9ucHf/ -cHJ5/3Byef9ucHf/b3F1/3Bzff9vcXX/Z2px/2xudf9sbnX/amxz/2ptd/9nanT/Z2p0/25xe/9sb3n/ -amxz/2ptd/9ucXv/am13/3N1fP9qbXf/Z2p0/25xe/9nanT/bG51/2RmbP9wcnn/bnF7/2xvef9kZ3H/ -bG95/2lsc/9ucXr/b3F5/2xvef9ucHf/Z2p0/2xvef9ucHf/bG52/2dqdP9tcHf/bG94/3Byef9nanH/ -Zmlz/3Byef94eX3/bnB3/3N1fP9wcnn/c3V8/2xudf9ucHf/c3V8/3l7gf9zdXz/bG95/21vc/92eHz/ -c3V8/3Bzff9sbnX/bG51/21vc/9sbnX/bnB3/3V3ff9tb3P/bG51/2dqdP91eIH/c3V8/3Byef9tb3P/ -eHl9/2ptd/9sb3n/bnF7/3Bzff9kZ3H/am13/3V3ff9ucHf/bG51/25wd/9+gIb/cHN9/3Byef9tb3P/ -bG51/2psc/97fYP/bG51/2ptd/9qbXf/b3F1/3N1fP9ucHf/bG51/3N1fP9ucHf/cHN9/2Zpc/9qbXf/ -am13/2ptd/9qbHP/cHN9/2xvef9wc33/bG51/2Rncf9qbHP/am13/2ptd/9sbnX/c3V8/2ptd/9nanT/ -d3l//2xudf9sb3n/bG51/2xudf94eX3/dXd9/3Byef9vcXX/bG95/25wd/9sb3n/eXuB/3Bzff9wcnn/ -eXuB/3Byef9zdn//eXuB/3Bzff9ucXv/dXd9/3V3ff9wc33/c3Z//3N2f/9sb3n/cHJ5/3Byef9wc33/ -cHJ5/3d5f/97fYP/cHJ5/25xe/9ucHf/b3F1/3Byef9sbnX/am13/3N1fP9tb3P/am13/25xe/9kZ3H/ -am13/2ptd/9ucXv/bG51/3N1fP9ucHf/c3V8/3N1fP9ucHf/dXd9/25xe/9qbXf/cHN9/2xudf9sbnX/ -c3V8/3V3ff9ucHf/dXd9/3Byef9wcnn/cHJ5/3Byef9tb3P/cHN9/2ptd/9sb3n/am13/25xe/9sb3n/ -am13/2dqdP9qbXf/am13/2BjbP9qbHP/cHN9/3V3ff91d33/dnh8/2Vmav9ucHf/bnB3/2xvef91eIH/ -Z2p0/3N2f/9zdn//bnF7/2xvef9ucXv/c3Z//3d6g/9ucXv/am13/25xe/95e4H/eXuB/21vc/9zdXz/ -c3V8/2xudf9sbnX/c3V8/2Zobv9qbXf/bG51/3V3ff9rbXX/bG52/25vdf9sb3j/Zmlz/3Bzff9sbnX/ -d3l//21vc/9sbnX/c3V8/3V3ff9vcnv/bnB3/29xef9zdn//bnF7/3N1fP91eIH/bnF7/25xe/9ucHf/ -cHN9/3N2f/9zdn//cHJ5/3N1fP91eIH/cHJ5/2Zpc/9ucXv/bnB3/29xdf9ucHf/bG95/3Bzff91eIH/ -cHN9/25xe/9ucXv/c3Z//29xdf92eHz/bW9z/2psc/9wcnn/amxz/25wd/9nanH/c3Z//3Bzff9ucXv/ -Z2px/3N1fP9ucHf/cHJ7/3R2f/9xdH7/cHJ5/2dqdP9sb3n/cHJ5/29xeP9tb3j/cnR6/3R2ff93eX// -bnB3/3Byef93eX//dnh8/2ptd/9wcnn/cHJ5/3Byef9qbHP/cHJ5/3h5ff93eX//dXd9/25xe/9vcXX/ -eHl9/3d5f/91eIH/c3V8/3N1fP9wc33/cHJ5/2xvef9zdn//bG95/2xvef9sb3n/d3qD/25xe/9wc33/ -bG95/3d5f/9sbnX/b3F1/25wd/9ucHf/ZGZs/2Zpc/9wc33/amxz/2dqdP9sbnX/d3l//2dqdP9sb3n/ -Z2px/2Zobv9gY2z/eXuB/2Zpc/9sbnX/amxz/2xudf9zdXz/bW9z/2xvef91d33/bG95/3V4gf9sb3n/ -c3Z//3d6g/91eIH/cHN9/3l7gf93eoP/foCG/3N2f/9ucXv/c3V8/3N2f/91eIH/dXd9/36Ahv9zdn// -c3V8/36Biv9zdXz/cHN9/29xdf9vcXX/dnh8/3V3ff9wcnn/bW9z/25wd/9ucHf/am13/3d5f/9ucXv/ -am13/3h5ff9sb3n/c3Z//3t+h/9sbnX/bG95/3N1fP9ucXv/cHN9/25xe/9ucXv/Z2p0/2ptd/9sbnX/ -cHJ5/25wd/9zdn//dXd9/2xvef9vcXX/bW9z/2xudf9ucXv/am13/21vc/91d33/bnB3/25wd/91d33/ -Z2px/25wd/9wcnn/c3Z//25wd/95e4H/d3qD/3d6g/93eX//cHN9/3Z4fP9wcnn/bnB3/3N1fP9sbnX/ -bnB3/3V3ff93eX//cHJ5/3N1fP9wcnn/c3V8/3Byef91d33/bW9z/3V3ff9ucHf/cHJ5/3N1fP9ucXv/ -am13/2xudf9qbXf/bG95/2xudf9iZW7/am13/3N1fP9zdXz/c3V8/3d5f/9lZmr/bW9z/2xudf9ucHf/ -c3Z//2dqdP9wc33/c3Z//3Byef9sbnX/cHJ5/3N1fP93eoP/bG51/2psc/9ucHf/d3l//3d5f/9ucHf/ -dXd9/3V3ff9ucHf/bnF7/3d5f/9qbXf/cHJ5/29xdf91eIH/bnF7/3Fze/9ydHz/bnF7/2ptd/91d33/ -bnB3/3V3ff9vcXX/bnF7/3N2f/93eoP/cnV8/25wd/9tb3j/dnh8/25wd/9vcXX/bnB3/2xvef9qbXf/ -Zmlz/25xe/9qbXf/am13/2dqcf9kZ3H/Z2p0/2Zobv9gY2z/Z2p0/2Zpc/9maXP/amxz/2Rncf9qbXf/ -am13/2dqdP9sb3n/am13/3Bzff9sbnX/dnh8/29xdf9qbHP/cHN9/3Byef9zdn//Zmlz/3Bzff9wc33/ -cHN9/2ptd/9zdn//bnB3/3FzfP9wcnr/a211/25wd/9sbnX/bG95/25weP9xc3r/cHN7/3J1fv94eoP/ -fYCJ/3N2f/93eoP/eXyG/3d6g/9zdXz/dXiB/3d6g/9wc33/am13/25wd/93eoP/eXuB/3d5f/9zdn// -bnF7/3t9g/95e4H/c3Z//3Byef9wcnn/cHN9/2xvef9ucHf/dXd9/3Byef9qbHP/b3F1/3d6g/9wc33/ -c3Z//2xvef91d33/am13/25wd/9sb3n/bnF7/2dqcf9sbnX/dnh8/29xdf9qbXf/bG51/3t9g/9qbXf/ -bnF7/2xudf9sbnX/Z2px/3t9g/9qbHP/bnB3/2xudf9tb3P/bnF7/25wd/9ucHf/dXd9/3Byef91d33/ -amxz/25wd/91d33/dXd9/25wd/9zdXz/bG51/3N1fP9sbnX/ZGZs/2dqdP9qbXf/am13/2dqdP9sb3n/ -amxz/2Rncf9zdXz/Zmlz/2dqdP9kZ3H/ZGZs/2ptd/9sb3n/Z2p0/2Jlbv9kZmz/XWBq/2BjbP9qbXf/ -Zmlz/2Jlbv9sb3n/am13/2xvef9zdXz/Z2p0/2xudf9ucXv/bnF7/3Byef9zdXz/c3V8/2psc/9ucHf/ -bG95/2xvef9tb3P/c3V8/3h5ff9sbnX/bnB3/25wd/9wc33/cHN9/2xvef9ucHf/dXd9/3Bzff9ucHf/ -cHN9/2dqdP9sb3n/c3Z//3Z4fP9qbXf/c3V8/2ptd/9sbnX/cHN9/2xvef9zdXz/bnF7/2xudf9sb3n/ -amxz/2psc/9sb3n/bG95/2Zpc/9qbXf/Z2p0/25xe/9qbXf/am13/2xudf9wc33/bG51/2xvef9sb3n/ -bnF7/3Byef9ucHf/bnB3/3N1fP9tb3P/Zmhu/29xdf91d33/dXd9/3d5f/93eoP/amxz/25wd/9ucXv/ -c3Z//3d5f/9sb3n/c3Z//3l7gf9zdXz/am13/3N2f/93eoP/eXyG/3Byef9sb3n/cHN9/3l8hv97fof/ -cHN9/3t9g/97fYP/dXd9/3Bzff97fYP/am13/25xe/9ucHf/eXuB/21wef90dnz/dXd//3R3gP9zdXz/ -eXuB/3Bzff95fIb/c3Z//3Bzff91eIH/eXuB/3Z5gv9ydHz/c3aA/3p9g/9zdn//cHN9/3Bzff9ucXv/ -c3Z//3Bzff93eoP/d3qD/3V4gf9zdXz/cHN9/3N2f/9sb3n/Zmlz/3Bzff9ucHf/c3V8/3N2f/9sb3n/ -bG95/3Byef9ucXv/cHN9/25wd/9wc33/bnB3/3h5ff9vcXX/amxz/25xe/9vcXX/c3V8/2Zpc/9wc33/ -c3V8/3Byef9sb3n/d3qD/3Byef9vcnv/cHJ6/29xef9ucHf/amxz/21vc/9sbnX/b3F1/25wd/9wcnr/ -cXR9/3V3ff9sb3n/c3V8/3h5ff93eoP/cHN9/25xe/9zdn//cHN9/2dqdP9wc33/e32D/3l8hv93eoP/ -c3Z//3Bzff93eX//dXd9/3Byef9ucHf/b3F1/3Bzff9ucXv/bnF7/3N2f/9ucHf/Z2p0/2ptd/93eX// -bnB3/25wd/9qbHP/dXd9/2xudf9vcXX/bnB3/2xvef9maXP/bG95/3Z4fP9vcXX/bG51/25xe/9/goz/ -dXiB/3N2f/9ucHf/b3F1/2psc/9+f4P/bG51/29xdf9ucHf/b3F1/3Byef9sbnX/bnB3/3V3ff9wc33/ -c3Z//2psc/9vcXX/dXd9/3N1fP9qbXf/bnF7/2xudf9wc33/amxz/2BjbP9kZ3H/amxz/2ptd/9maXP/ -cHN9/2xudf9maXP/d3l//2xudf91d33/bG51/2ptd/91d33/bnF7/2ptd/9nanH/Zmlz/2Rncf9kZ3H/ -cHN9/2xvef9nanT/dXd9/25xe/9ucXv/c3V8/25wd/9sb3n/dnh8/3Byef9ucXv/c3V8/3Bzff9maXP/ -bnB3/3Byef9wcnn/bnB3/3N2f/95e4H/cHN9/3Byef9wc33/dXiB/3N2f/9wc33/cHN9/3t9g/93eoP/ -dXiB/3t9g/9zdn//d3qD/3l8hv95fIb/cHN9/3l8hv9zdn//cHN9/3l7gf9ucXv/c3Z//3V3ff9vcXX/ -c3V8/25wd/9wcnn/dXd9/3Z4fP9zdXz/cHJ5/2xvef9ucXv/bnF7/2ptd/9qbHP/bnF7/2ptd/9qbHP/ -am13/3Bzff9wc33/am13/2xudf9ucXv/bG51/2Rncf9sbnX/c3V8/3V3ff9zdXz/c3V8/2BjbP9maXP/ -am13/2xudf9wc33/Zmlz/25xe/91d33/bG51/2Zpc/9sb3n/bnF7/3V3ff9maXP/YGNs/2dqcf9wcnn/ -cHJ5/2dqcf9ucXv/bG95/2psc/9maG7/am13/2BjbP9nanH/Z2px/3V3ff9qbHP/bnB3/29xd/9sbnX/ -amxz/2xvef9maXP/cHJ5/2psc/9nanH/bG95/3Bzff9ucXr/aGtz/2ptd/9zdXz/bW9z/2xudf9sb3n/ -bG95/2ptd/9maXP/bnF7/2ptd/9qbHP/ZGdx/2dqcf9qbXf/Z2p0/2Zpc/9qbXf/bG51/2xudf9tb3P/ -bG51/25wd/9sb3n/cHJ5/3N1fP9sb3n/d3l//3Bzff93eX//bG95/2ptd/9ucXv/cHJ5/3N2f/9qbXf/ -d3qD/3N2f/9zdn//bnB3/3N2f/9ucHf/bnB4/2ptdv9rbnf/bG51/2Rncf9sbnX/am13/2psc/9pbHT/ -bXB4/2xueP9wc33/bG51/3Byef94eX3/cHN9/3Bzff9sb3n/c3Z//25xe/9nanT/bnF7/3d5f/91eIH/ -c3Z//25xe/9zdn//eXuB/3Z4fP91d33/bG51/21vc/9ucHf/bG51/2xudf9zdXz/bG51/2Rncf9maXP/ -cHJ5/2dqcf9maXP/YmVu/25xe/9nanT/bG51/2xudf9qbXf/Zmhu/21vc/9zdXz/bW9z/2ptd/9sb3n/ -f4GH/25xe/9sb3n/bG51/2xudf9qbHP/fX6B/2psc/9sbnX/b3F1/29xdf9zdXz/bG95/2xvef9wc33/ -cHN9/3Bzff9qbHP/cHJ5/3V3ff9zdn//bnF7/3V3ff9ucHf/dXiB/3Byef9nanH/bnF7/3Bzff93eoP/ -bG95/3l7gf93eoP/d3l//3+Bh/9zdXz/d3qD/3Bzff9wc33/eXyG/3d6g/9ucXv/bnB3/2xvef9sbnX/ -am13/3V3ff9wc33/Z2p0/3h5ff9zdXz/c3V8/3d5f/9sb3n/bG95/3h5ff9ucHf/c3V8/3V3ff91d33/ -Z2px/25wd/9wc33/bG95/2xudf9sbnX/c3V8/2ptd/9maXP/amxz/2ptd/9ucXv/am13/2ptd/9zdXz/ -cHN9/2ptd/9ucXv/ZGdx/2ptd/9nanT/cHJ5/2Rncf9zdXz/am13/2ptd/9ucXv/am13/3Bzff9wc33/ -bG95/3V3ff9qbXf/bnB3/3N2f/91eIH/cHN9/3V3ff91d33/dXd9/3Bzff9wc33/cHN9/3Z4fP9wc33/ -cHN9/3N2f/93eoP/d3qD/25xe/9zdXz/dXiB/3Byef9sb3n/cHN9/3l7gf91eIH/dXd9/3d5f/9kZ3H/ -bnB3/2xudf9zdXz/eHl9/25wd/91d33/dnh8/2ptd/9maXP/c3V8/3N1fP93eX//bG51/2psc/9sbnX/ -dXiB/3V3ff9vcXX/c3Z//3N2f/9sb3n/bnB3/3N2f/9sb3n/bG95/21vc/95e4H/b3F2/3J0ev90dn7/ -dnmC/3V3ff95fIb/dXd9/3t+h/9wc33/c3V8/3V4gf93eoP/dnmB/3Fzev9vcXf/dXh+/29xdf9tb3P/ -bG51/25wd/9ucHf/bnB3/3N1fP9ucHf/bnB3/25wd/9vcXX/dXd9/29xdf9maG7/cHJ5/2ptd/9nanT/ -amxz/2Zpc/9sbnX/bG95/2xvef9qbXf/amxz/3Byef9maXP/bG95/2Zobv9dYGr/YmVu/2Zobv9maXP/ -XWBq/2ptd/9nanT/Zmhu/2Jlbv9nanT/Zmhy/2hqcf9oa3P/aWtz/2ptd/9qbHP/bG51/25wd/9rbXL/ -aGty/2ttc/9pbHX/Z2p0/2Vocv9maXP/bnF7/3Bzff9ucHf/bG51/3N1fP9sbnX/Zmlz/2xvef9zdXz/ -c3V8/3N1fP9qbHP/bnF7/3N1fP9wc33/bnF7/2Zpc/9nanH/Zmlz/2Rncf9sbnX/cHN9/2psc/9kZ3H/ -ZGdx/25wd/9iZW7/ZGdx/11gav9nanT/ZGdx/2Zobv9qbHP/Z2px/2Jlbv9nanT/cHN9/2dqdP9qbXf/ -bG95/36Biv9ucXv/bG95/21vc/9tb3P/b3F1/4CChv9ucHf/cHJ5/3Byef9zdXz/c3Z//3Byef9wc33/ -cHN9/3N2f/9wc33/am13/25wd/9wc33/dXd9/25wd/9ucHf/bG51/3Bzff9nanT/YmRq/2dqdP9qbXf/ -bG95/2Zpc/9ucXv/Z2p0/2Jlbv9ucHf/YmVu/2dqdP9nanH/Z2px/3Byef9zdXz/amxz/2dqcf9nanT/ -Zmlz/2dqdP9sb3n/am13/2Zpc/91d33/bG95/3Byef93eX//dXiB/3V4gf97fof/d3qD/3t9g/93eoP/ -c3Z//2Zpc/9zdXz/c3V8/3V4gf9sb3n/cHJ5/3d5f/9ucXv/bG51/25xe/9wc33/dXiB/3N1fP91d33/ -eXuB/3t9g/91eIH/foCG/3V3ff93eoP/dXiB/3V4gf9sb3n/d3qD/3N2f/9wcnn/dXiB/3V4gf95e4H/ -dXiB/3Bzff93eX//c3Z//3Byef9wc33/dXiB/3N2f/91d33/c3V8/3N1fP9wcnn/bnB3/3Byef92eHz/ -cHJ5/25wd/9ucHf/c3V8/3N1fP9sbnX/bW9z/3N2f/9wcnn/amxz/25xe/93eX//dXiB/3N2f/9zdn// -Z2p0/2ptd/9ucXv/cHN9/3V4gf9wcnn/c3Z//3d5f/9sb3n/Z2p0/3N2f/91d33/d3l//25wd/9sbnX/ -b3F1/3h5ff95e4H/b3F1/3N1fP91d33/bG95/2ptd/91d33/amxz/2ttdP9sbnX/c3Z//2ptd/9vcXj/ -cHJ3/25wd/9tb3P/cHJ5/2xudf93eX//am13/21vc/9zdXz/dXd9/3J0e/9sb3n/bXB6/3Bzff9sbnb/ -amxz/2ptd/9rbnj/bG51/2tud/9wcnn/bG95/25wd/9ucHf/cHJ5/3V3ff9ucHf/Zmlz/3R3gP9tcHf/ -bnB3/3Fzef9ucHf/cnR7/3Bzff9ydX7/cHJ8/3Bzff93eoP/cHN9/3h6gP9zdn7/bnF7/3Byef9vcXj/ -bnF7/2hrdf91d33/bW92/25wd/9vcXj/eHl9/29xef9wcnn/cHN8/3Z3fP95e4H/dXd9/3d5f/96fIP/ -cnV+/3F0e/91d37/dniA/3V3ff9wcnn/c3Z//3Z4f/93eoP/dXiB/3Bzff91eIH/bnF7/2ptd/91eIH/ -e32D/3d5f/93eX//c3V8/3d6g/9zdn//dnh8/3N1fP9ucHf/bnF7/25xe/9vcXX/bG95/3V3ff9vcXX/ -amxz/2xudf92eHz/bnB3/3Byef9nanT/cHN9/2ptd/9ucHf/c3Z//3Byef9qbHP/b3F1/3Z4fP9qbHP/ -bG51/25wd/9/gYf/cHJ5/2ptd/9tb3P/bnB3/2ptd/9/gYf/bnB3/29xdf9ucHf/bG95/3Byef9tb3P/ -am13/2ptd/9wc33/bnF7/2dqdP9sbnX/c3V8/3h5ff9wcnn/bnF7/2xvef9wcnn/am13/2Vmav9sbnX/ -bnF7/3Byef9sbnX/dnh8/3Bzff9ucHf/eXuB/3V3ff93eoP/cHN9/3N2f/97fof/e36H/3V4gf91d33/ -dXd9/25xe/9zdXz/dXiB/3V4gf9wc33/e32D/3d6g/95fIb/e36H/2xvef9ucXv/d3l//25xe/9zdn// -c3Z//3N2f/9maG7/bnB3/3N1fP9wcnn/b3F1/21vc/9zdXz/bG51/2dqcf9wcnn/bnF7/3N1fP9ucHf/ -bG95/3V3ff9zdXz/bG51/3Byef9ucHf/c3V8/25wd/91d33/am13/3V4gf9ucXv/amxz/2xvef9ucXv/ -cHN9/3Bzff9wcnn/c3V8/3Byef9wcnn/cHN9/3Bzff9zdn//c3Z//3Bzff9wcnn/dXd9/3Byef9ucHf/ -d3l//25wd/9wcnn/bnB3/3V3ff91d33/bnF7/3Byef91eIH/bnF7/2ptd/9sb3n/c3Z//3Z4fP9wcnn/ -c3V8/2Zobv9nanT/bnF7/2xvef91d33/bG51/2ptd/9zdXz/Z2p0/2Rncf9ucXv/c3V8/3N1fP9qbXf/ -am13/2psc/93eX//d3qD/2xudf9ucXv/bG95/2ptd/9qbXf/c3V8/2ptd/9xc3r/bnB3/3d5f/9ucHf/ -cHJ5/29xd/9ucXv/amxz/25wd/9ucHf/d3l//25wd/9vcXX/dXd9/3d5f/9wcnn/bG52/25xe/9xdHz/ -am13/2ttdf9qbXf/bG51/2xudf9rbnf/bXB6/2xudf9qbXf/bG51/3Byef90dnz/cHJ5/2hrc/9ydX7/ -aGt1/25wd/9wcnn/bnB4/25weP9ydHv/b3J7/29ye/9vcXj/dXiB/3F0ff9zdn//bG95/2xvef9ucHf/ -cXN3/3Byef9oa3P/cnR8/2xveP9qbXf/aWx1/3R2ff9pbHP/am13/2dqc/9pbHb/bG51/2Rncf9maG7/ -bG95/2psc/9maXP/bG94/29xef9sb3f/am12/2ttdv9ydHr/c3V8/3Bzff9vcXX/cHJ5/2xvef9qbXf/ -cHN9/3d5f/93eX//d3l//3Byef91eIH/c3Z//3d6g/93eoP/cHN9/3N2f/9wc33/bG95/29xdf91d33/ -b3F1/2psc/9sbnX/dnh8/25wd/9sbnX/bG51/25wd/9qbHP/bG51/2xvef9wcnn/amxz/2xudf92eHz/ -Z2px/25wd/9ucHf/f4GH/3Z4fP9zdXz/cHJ5/25wd/9qbXf/gYOK/2xvef9ucXv/bnB3/3V4gf9zdn// -c3Z//3N2f/91eIH/e32D/3t9g/92eHz/eXuB/31+gf9/gYf/eXuB/3V4gf9zdn//dXiB/3Bzff9qbXf/ -c3V8/3d6g/93eoP/c3Z//3t9g/93eoP/bnF7/3t9g/9ucXv/dXiB/25xe/9vcXX/eXuB/3d6g/9sb3n/ -bnB3/25wd/9nanH/bW9z/25wd/9sbnX/Z2px/3N2f/9ucXv/c3Z//3V3ff91d33/d3qD/36Ahv91eIH/ -eXuB/3d6g/93eoP/bG95/3t9g/97fYP/d3qD/3V3ff91d33/dXiB/3V4gf9ucXv/d3qD/3V4gf9zdn// -bnB3/3Byef95e4H/dXiB/3Byef9zdn//bnB3/3N1fP9zdXz/bnB3/21vc/95e4H/dnh8/21vc/9sb3n/ -bnF7/3Bzff9wc33/c3V8/25xe/9ucXv/bG95/2xvef9sb3n/cHN9/3Bzff9ucXv/cHN9/25xe/9qbHP/ -bG51/3N1fP9nanT/amxz/2psc/9ucXv/cHJ5/2Zobv9kZ3H/Zmlz/2Zpc/9dYGr/Zmlz/2dqdP9sb3n/ -ZGdx/2dqdP9cX2j/YGNs/2Zpc/9maXP/bG95/2Rncf9kZ3H/cHJ5/2Zobv9kZ3H/am13/2xvef9zdXz/ -bG95/2xudf9sbnX/d3l//3l8hv9sbnX/c3V8/3N1fP9zdXz/b3F1/3V3ff9sb3n/cnR6/3Fzev90dn7/ -bnF5/3J0e/9wcnf/cHJ5/2xudf9ucHf/bnB3/3d5f/9sbnX/b3F1/3V3ff91d33/cnR7/2xudv9sbnb/ -cXN7/2ttc/9qbHX/bG93/3Fzef9rbXb/bG53/29yev9tcHj/a254/2xvef9ucXn/c3V7/29yev9rbXb/ -cnV//25xef9wcnn/c3V8/3V3ff9ydHn/eXuA/3V3fv90dn3/c3V9/3h7hf91eID/dXd+/3N1fP90dnz/ -cHJ5/3R2fv9xdH3/b3J8/3J1fP9wc3v/a252/29xeP9ydX//bW94/2xveP9nanT/a253/2xudf9qbXf/ -bW9z/3Bzff9qbXf/aGt0/2xvef9zdn3/am11/21veP9sbnb/bW94/2xvef9qbXf/am13/3Bzff9sbnX/ -Z2p0/2xvef9ucXv/c3V8/2xvef9sbnX/c3V8/3N1fP9zdXz/cHJ5/21vc/9qbXf/bnF7/21vc/9ucHf/ -dnh8/21vc/9qbHP/cHJ5/3l7gf9wcnn/bG95/2xvef9ucXv/bnB3/2xvef9zdn//cHN9/2xvef9qbXf/ -eHl9/2dqdP9nanT/bG51/3t9g/9sb3n/cHN9/2xvef9qbXf/Z2p0/3t9g/9qbHP/Z2px/2dqcf9maXP/ -Z2px/2dqcf9qbHP/am13/25xe/9qbXf/Z2p0/2xudf9wc33/c3V8/2xvef9qbXf/bW9z/25wd/9ucHf/ -Zmhu/2xudf9sbnX/c3V8/2dqdP9zdn//c3Z//25wd/95e4H/am13/3V4gf9zdn//cHJ5/3l7gf97fYP/ -cHJ5/3N2f/9wcnn/bG95/3Byef9zdn//dXiB/2xvef91eIH/c3Z//3d6g/91eIH/c3V8/3N2f/97fYP/ -bnF7/3N2f/9zdn//c3Z//2dqdP95e4H/c3Z//25xe/9ucHf/bG95/25xe/9zdXz/Zmlz/3N1fP9zdXz/ -c3V8/25wd/9wcnn/dnh8/3Z4fP9ucHf/cHN9/25wd/9wcnn/dXiB/3Bzff9wcnn/eXyG/3l8hv9zdXz/ -bnF7/3V3ff9zdn//c3Z//3d5f/9wc33/cHN9/25xe/9wc33/cHN9/3h5ff91d33/c3V8/3N1fP9wcnn/ -am13/2psc/91d33/am13/2xudf9maXP/bG95/3N1fP9nanH/Z2px/2ptd/9qbXf/Zmlz/2xudf9zdXz/ -dnh8/3Byef9zdXz/Zmlz/2xvef9wc33/dXiB/3d5f/9wc33/cHN9/36Biv9wcnn/c3V8/3t9g/9+gIb/ -e32D/3d6g/9wc33/cHN9/3l8hv+Bg4r/dXiB/3t9g/93eoP/eXuB/3N2f/91d33/b3F1/3R2fP9vcXn/ -cnR8/21vdv90dnv/bnB3/3Byef9qbXf/bG95/2xvef93eX//bG51/25wd/93eX//e36H/3Z5gv9tcHr/ -b3J7/3Z3ff9rbnf/bG94/2xveP90dn//bW92/3J1ff9wc33/bW92/21wev9ydX//cHN9/3F0ff9tcHn/ -aWty/21vdv9qbHP/bG94/3V3fv9tcHn/a210/3Z4fv9tb3b/bW92/21veP9ucXr/b3F6/21wef9tb3b/ -cXN6/2xudP9ydHv/b3F5/2xvd/9ydHz/bW93/2tueP90dnz/cXN6/29xeP9sbnX/amxz/2xudf9qbHP/ -bG51/2xudf9wc33/bG51/2ptd/9wc3z/c3V8/21vdv9zdXz/bnB3/25xev9ucHf/cHJ5/25xe/9zdn// -cHJ5/2ptd/9zdXz/cHN9/3V3ff93eX//cHJ5/3V4gf9zdn//dXd9/3Bzff9ucHf/c3V8/3Bzff9zdXz/ -cHN9/3l7gf9wc33/am13/3Byef93eX//am13/2xvef9sb3n/bG95/2ptd/9sbnX/dXd9/3Byef9qbXf/ -Z2p0/3V3ff9nanT/bG51/29xdf9+gIb/dXd9/3V3ff9ucHf/bnB3/25wd/+Bg4r/bnB3/29xdf9vcXX/ -bG51/2xudf9ucHf/bnB3/21vc/91d33/bnB3/25wd/9vcXX/dnh8/3l7gf9zdn//cHN9/25wd/9ucXv/ -bnB3/2dqcf9vcXX/bG51/3N1fP9qbXf/dXiB/3N2f/9ucHf/d3l//2dqdP91eIH/c3Z//3N1fP9zdn// -eXyG/3N1fP93eoP/cHN9/3Bzff9zdXz/bnF7/3V4gf9wc33/eXyG/3V4gf95e4H/d3qD/2xudf9sbnX/ -dnh8/3Byef9zdXz/bnB3/25xe/9gY2z/bnF7/25xe/9ucHf/bG51/2xudf9sb3n/bG95/2dqcf9zdXz/ -bG95/3N2f/9ucHf/bnB3/3N1fP92eHz/b3F1/3Byef9ucHf/cHJ5/3N1fP9sb3n/bG51/3d5f/91d33/ -am13/2xudf9ucXv/bG95/25xe/9wc33/bG51/2xvef9sbnX/Z2p0/2xvef9wcnn/bG95/2dqdP9wc33/ -bG95/2xvef9qbXf/dXd9/2ptd/9qbXf/am13/3Z4fP92eHz/bnB3/25xe/95e4H/cHN9/3Byef9zdn// -d3qD/3l7gf93eoP/e32D/3Bzff9zdn//d3qD/36Ahv97fof/dXiB/3d5f/+DhYz/dXiB/3V3ff97fYP/ -foCG/3t9g/9zdn//cHJ5/3N1fP93eX//d3qD/2xvef93eX//c3Z//3N2f/9ucXv/dXd9/25wd/94eoD/ -dHeA/3N2f/9ucXv/dnh//2xvef9wcnn/bG51/2xudf9qbHP/eHl9/2xvef9sb3n/d3l//3d6g/91d33/ -bnF7/3Bzff96fIP/bnB3/29xdf9ucXr/d3h8/2xudf9ydHv/bnB3/2ptd/9vcXj/bnF7/2xudf9wcnn/ -b3F4/2Zpc/9rbnX/am13/29yfP93eoD/b3J8/2xvef95e4H/b3F1/2xvef9ucXv/b3J8/3F0ff9vcnv/ -bnF7/3Z4fv9wcnn/dnh+/3J0fP9ydHv/dXd9/2xudv9nanT/dnh+/25xe/9ucXv/am13/2ptdP9qbHP/ -bW9z/2xudf9qbHP/cHN9/2xudf9sb3n/dXd9/3d5f/9wc33/eHqA/3N2f/9sb3n/c3Z//3d6g/91eIH/ -e32D/3N2f/9wc33/e32D/3l8hv9+gIb/e32D/3Bzff95e4H/d3l//3d5f/9ucXv/bnB3/25wd/9ucXv/ -bG95/2xudf9wc33/amxz/2BjbP9nanH/bG95/2Zpc/9nanH/Zmlz/2ptd/9nanT/am13/3V3ff9ucXv/ -am13/2ptd/9zdXz/bG51/2xudf9qbXf/e32D/25xe/9wc33/am13/2ptd/9qbXf/f4GH/2ptd/9qbXf/ -bG95/2ptd/9wcnn/bnB3/25wd/9sbnX/dnh8/25wd/9sb3n/bG95/3V3ff93eX//cHN9/3N2f/9wcnn/ -cHN9/3Byef9nanT/cHJ5/3Byef9wc33/am13/3N2f/9zdn//cHJ5/3l8hv9ucXv/dXiB/3Bzff9vcXX/ -bnB3/3h5ff9tb3P/bG95/2psc/9qbHP/Z2p0/2ptd/9ucXv/Zmlz/2xvef9sbnX/am13/25xe/9sbnX/ -bW9z/3h5ff9wc33/c3V8/3N1fP9wc33/amxz/3Byef9ucHf/bnB3/29xdf9sbnX/bnB3/3Byef9maXP/ -bnF7/2xudf9ucXv/am13/2xvef9zdXz/cHN9/2xudf9wcnn/bG51/3Byef9ucXv/bG95/2ptd/93eX// -dXd9/3Byef9ucHf/c3V8/3N1fP91d33/c3V8/25wd/9wcnn/bnB3/3Bzff9zdn//eXuB/3N2f/9wc33/ -eXuB/3Bzff9wc33/cHJ5/3Z4fP9zdXz/bG51/2xvef91d33/c3V8/2xudf9qbHP/bG95/2ptd/9qbHP/ -bG95/2xvef9wcnn/am13/3Bzff9nanT/Z2p0/25xe/9zdXz/dXd9/2xudf9sbnX/c3V8/2xudf9qbXf/ -cHN9/3Z4fP9wcnn/bnB3/2xudf9tb3P/dXd9/3V4gf9sbnX/dXd9/3V3ff91d33/c3V8/3Z4fP9vcXX/ -c3Z//3V3ff9sbnX/Z2p0/3V3ff9qbXf/bnF7/2dqdP9qbHP/Z2p0/3V3ff9ucHf/bnB3/3N1fP92eHz/ -dXd9/3Byef9wcnn/eXuB/25wd/9sb3n/c3V8/3Z4fP9ucHf/cHJ5/21vc/9sbnX/cHJ5/3N2f/9wcnn/ -c3Z//3N2f/9qbXf/c3V8/3N1fP93eoP/eXyG/25xe/9qbXf/fX6B/21vc/9nanT/bnF7/2xvef9sb3n/ -bG95/2xvef9wc33/amxz/2xvef9sb3n/bG95/25xe/9nanT/ZGdx/3V3ff9wcnn/bnB3/21vc/9vcXX/ -am13/29xdf9ucHf/bG95/3N2f/9sb3n/bG95/3N2f/93eX//bnF7/3d5f/9wc33/cHJ5/3N2f/91eIH/ -c3Z//3l7gf9sb3n/bnB3/3N1fP91d33/dXd9/3N1fP9sbnX/dnh8/3Z4fP91d33/bnB3/21vc/9qbHP/ -am13/2xudf9tb3P/cHJ5/2xudf9kZmz/bnB3/3V3ff9sbnX/b3F1/2psc/9wcnn/bG51/2xvef91d33/ -c3Z//3Byef9ucHf/e32D/3N1fP9zdXz/c3V8/4OFjP91eIH/fX6B/3d5f/97fYP/dXd9/4mLkf93eX// -dXiB/3d6g/9zdn//dXiB/3Bzff9zdn//dXd9/3t+h/97fYP/dXd9/3Bzff95e4H/f4GH/3d6g/9ucXv/ -bnB3/3Byef9wcnn/Z2p0/25wd/9vcXX/cHJ5/2psc/9ucHf/bnB3/2xudf93eX//am13/3N2f/9sb3n/ -bnB3/25xe/91eIH/am13/3Bzff9ucHf/bG95/3Byef9wcnn/c3V8/2xudf9wcnn/bnB3/25wd/9zdXz/ -cHN9/3N1fP91eIH/c3Z//3N2f/95e4H/dXiB/25wd/9ucXv/bnF7/25xe/9vcXX/amxz/3V3ff9zdXz/ -amxz/3N1fP9tb3P/cHN9/2ptd/9ucHf/c3V8/3d5f/9qbXf/cHJ5/21vc/9sb3n/c3V8/25wd/9qbXf/ -dXd9/3V4gf9wc33/bG95/3N2f/91eIH/d3l//3N2f/9zdXz/dXiB/3V4gf95fIb/dXiB/3t+h/93eoP/ -dXiB/3t+h/9zdn//dXiB/25xe/97fYP/c3Z//2xvef9wc33/c3Z//3d5f/9vcXX/b3F1/3Bzff9wc33/ -bnB3/3Bzff9zdn//c3V8/3Byef91d33/bG51/21vc/91d33/dXd9/3d5f/9sb3n/bnF7/3l7gf9wcnn/ -cHJ5/3V4gf93eoP/c3Z//3N2f/9zdn//cHJ5/3d5f/95fIb/bnB3/3N2f/91d33/dXd9/25xe/95e4H/ -am13/3V4gf9wc33/bnB3/25wd/94eX3/b3F1/3V3ff9vcXX/b3F1/2xudf9ucXv/bG51/25wd/91d33/ -dnh8/3N1fP9sb3n/bnB3/3Z4fP9tb3P/bG51/25xe/91d33/amxz/2xvef9qbXf/bW9z/3Byef91d33/ -bW9z/25xe/9ucXv/Z2px/21vc/9sbnX/c3Z//36Ahv9sb3n/ZGdx/3d6g/9kZ3H/YGNs/2Zpc/9kZ3H/ -ZGdx/2Zpc/9nanT/bG95/2psc/9qbXf/bnF7/25xe/9ucXv/Z2p0/2Zpc/91d33/cHN9/25xe/9sbnX/ -amxz/2psc/9ucHf/bnB3/2xudf91eIH/bnF7/3Bzff93eoP/eXuB/3Bzff91eIH/cHN9/2ptd/9ucXv/ -cHN9/25wd/91d33/bW9z/2xudf9ucHf/cHN9/3N1fP9wc33/bG95/3V3ff9ucXv/cHN9/2ptd/9nanH/ -ZGdx/2Zpc/9iZW7/ZGdx/2Zpc/9nanH/XWBq/2psc/9ucXv/ZGdx/2xudf9kZ3H/bG95/2Zpc/9qbXf/ -cHN9/3Bzff9sbnX/bW9z/3N2f/9sb3n/bnB3/29xdf9+gIb/cHJ5/3Byef9ucHf/cHJ5/21vc/9+gIb/ -bG95/2xudf9wcnn/bG51/25xe/9qbHP/amxz/2dqdP93eX//cHN9/2ptd/9sbnX/c3V8/3N2f/9ucXv/ -Z2px/2dqcf9nanT/Z2px/2BjbP9nanT/bG51/2xvef9qbHP/am13/2ptd/9qbXf/dXiB/2psc/9ucXv/ -bW9z/2xvef9ucXv/d3qD/25wd/9wcnn/bnB3/2ptd/9wcnn/c3Z//3V3ff9sb3n/cHN9/3N1fP9wc33/ -eXuB/3d5f/91d33/e32D/3t9g/97fYP/f4GH/36Ahv9zdXz/d3l//3t9g/93eX//d3l//3d5f/9+f4P/ -e32D/3Bzff93eoP/c3Z//36Ahv9zdn//dXiB/3t9g/97fof/c3Z//3V4gf9zdXz/cHN9/3l7gf9wc33/ -bnF7/3V3ff91eIH/bnF7/25xe/91d33/bnF7/3N1fP9ucXv/am13/3Byef9ucHf/dnh8/29xdf94eX3/ -bnB3/25wd/93eX//cHJ5/3Byef9ucHf/eHl9/3Byef9ucHf/dXd9/3N1fP95e4H/b3F1/21vc/9wcnn/ -bG95/2xudf9ucXv/cHJ5/3N1fP9ucHf/c3V8/2dqdP9maXP/bnF7/25xe/9ucXv/ZGdx/2dqcf9ucHf/ -Zmhu/2Jlbv9qbXf/cHJ5/2xvef9ucXv/bG95/2dqdP9wc33/c3Z//2xudf9wc33/cHN9/3Byef9sbnX/ -cHN9/2dqdP9qbXf/bG95/2xvef9qbXf/c3V8/2xudf9wc33/am13/2ptd/9qbXf/cHJ5/25wd/9ucHf/ -dXd9/3V3ff9zdXz/bnB3/25wd/92eHz/bG95/2dqdP91d33/dXd9/2xudf9qbXf/bG51/2xudf9qbXf/ -c3V8/25wd/9sb3n/cHN9/2ptd/9wcnn/bnB3/3Bzff9+gIb/bnB3/2psc/9/gYf/b3F1/2psc/9zdXz/ -bnB3/3Byef9wcnn/bnF7/3Z4fP9wcnn/c3V8/3Byef91d33/cHJ5/2xudf9maG7/d3l//3l7gf9zdn// -bnB3/2xudf9nanT/bnB3/25wd/9qbXf/c3Z//2ptd/9sb3n/c3Z//3d5f/9ucXv/dHeA/3N2f/9rbnf/ -bnF7/25xe/9ucHf/eXuB/2xvef9sb3n/cHN9/3d5f/95e4H/dXd9/3Bzff91d33/cHN9/3Z4fP9ucHf/ -bG51/29xdf9ucHf/bnB3/2xvef9zdn//c3Z//2Zpc/9zdn//d3qD/25wd/9wc33/am13/3V4gf9wc33/ -dXiB/36Ahv9+f4P/dXd9/3V3ff97fYP/c3Z//3N1fP9wc33/foGK/3V4gf91eIH/eXuB/3t9g/91d33/ -g4WM/3t9g/9zdn//eXuB/3Bzff91eIH/cHJ5/25xe/9ucHf/eXyG/3l7gf9wc33/cHN9/3N2f/93eX// -c3Z//25wd/9sb3n/bnF7/25wd/9nanT/b3F1/25wd/9wcnn/bW9z/2xudf9ucHf/am13/3l7gf9nanT/ -bnF7/25xe/9wc33/cHN9/3t+h/9qbXf/bnF7/3Byef9ucHf/bnF7/3V4gf91eIH/dXd9/3l8hv91d33/ -d3l//36Ahv95e4H/d3l//3l8hv95e4H/d3l//36Ahv97fYP/cHN9/3V4gf91eIH/cHN9/3Byef9qbXf/ -dnh8/3Byef9nanT/bnF7/2psc/9zdXz/bG51/2ptd/9ucXv/c3V8/2dqdP9qbXf/Z2px/2Zobv9ucXv/ -am13/2Rncf9qbXf/am13/2Zpc/9nanH/am13/2dqdP9sb3n/cHN9/2ptd/9ucXv/bW9z/3Byef9ucHf/ -eHl9/25wd/9sbnX/dnh8/3N1fP9wcnn/cHJ5/3d5f/9wcnn/bnB3/3N2f/9wcnn/d3qD/25wd/9sb3n/ -bnF7/25wd/9vcXX/c3V8/3Byef9ucXv/bnB3/3N1fP9qbXf/Z2p0/3Bzff92eHz/dXd9/2psc/9wcnn/ -dXd9/21vc/9sbnX/c3V8/3V3ff9wc33/bG95/3Byef9sb3n/c3V8/3l7gf9sb3n/cHN9/3V3ff9zdXz/ -cHN9/3V4gf9sb3n/bnB3/29yfP9wc33/bG95/3d5ff9sb3n/dXd9/2ptd/9sb3n/am13/25xe/9wcnn/ -c3Z//3V4gf95e4H/d3l//25xe/9ucXv/d3l//25xev9qbXf/cHJ5/3J0e/9sbnX/bG52/2xudf9sbnX/ -bnB3/3N1fP9tb3P/a254/2tueP9oa3T/a253/2xudf9vcXn/eXuC/29xeP9qbHP/fH6F/25wdf9nanL/ -cnR7/29xeP9xc3r/cHJ5/21vd/9zdXz/b3F4/25xev9ucXv/b3J8/25xe/9sbnX/Zmlz/3N2fP9xdH7/ -cnR7/21vc/9nanT/ZGdx/2xudf9sbnX/amxz/25xe/9qbXf/am13/25xev90dnz/a211/2ptd/9sb3n/ -Z2pz/2xvef9sbnX/amxz/3N1fP9nanT/Z2p0/2xvef9zdXz/c3V8/3Bzff9sb3n/cHN9/2xvef9zdXz/ -bG95/2xudf9qbXf/bG95/2xudf9qbXf/cHJ5/25wd/9nanH/cHN9/3N2f/9sb3n/cHJ5/2Zpc/9wcnn/ -bG51/3Bzff93eX//d3qD/3Byef9qbXf/dXiB/25xe/9zdXz/cHN9/36Biv9zdn//c3Z//25xe/9zdn// -c3Z//4GDiv9zdn//cHJ5/3l7gf9wcnn/c3Z//3N1fP9wc33/bG95/3d6g/91eIH/b3F1/29xdf9zdXz/ -eHl9/3h5ff9tb3P/bG51/2xudf9qbHP/Z2p0/21vc/9wcnn/cHJ5/25wd/9wcnn/cHJ5/25wd/95fIb/ -Z2p0/25xe/9wc33/bnF7/25xe/97fof/c3Z//3d5f/91d33/eHl9/3d5f/95e4H/e32D/3l7gf9+gYr/ -eXyG/3l8hv+Agob/cHJ5/25wd/9wc33/bG95/2xvef92eHz/dXd9/2xudf9tb3P/bG95/25xe/9ucHf/ -amxz/3V3ff9wcnn/bnB3/3Byef9vcXX/d3l//25xe/9zdn//eXuB/3l8hv9zdn//dXiB/3Bzff9wc33/ -dXd9/25xe/9sb3n/eHl9/3d5f/9ucHf/bnB3/3V4gf9sb3n/c3Z//3V3ff9vcXX/c3V8/25wd/9zdXz/ -bG51/3l7gf9ucHf/bnB3/3Z4fP9ucXv/bnF7/2ptd/91d33/bG95/2psc/92eHz/cHJ5/3h5ff9vcXX/ -b3F1/3Byef9sbnX/bG51/25xe/9sbnX/cHJ5/25wd/9zdXz/bW9z/2psc/9wc33/dXd9/3N1fP9nanT/ -bnF7/3Z4fP9vcXX/b3F1/3N1fP91d33/cHN9/25xe/9wc33/bG95/3Bzff93eoP/bG51/3Byef9ucXv/ -bnF7/3Byef91d33/bG51/21vd/9tcHr/c3V9/2xvdv92eH3/b3F4/3Byef9sbnX/bG51/2xudf9qbXf/ -bW9z/3N1fP91d33/dXiB/3V3ff9ucHf/bXB6/3J1fv9vcXj/a212/25xe/9ucXv/bnB4/29yd/9ucXr/ -cnR7/3F0ff92eH7/b3F4/3N1fv9xdH3/bnB2/3BzfP9vcXj/cnV8/3x+hP9tb3b/a210/3p8gv9vcXb/ -aGp0/2xveP9vcXf/bnF5/25xef9tb3b/bXB6/25weP9tb3f/bnB4/3Bzev9ucHj/bW91/2dqc/9ydXr/ -eHl//3N1fP9tb3b/bnB3/2xudf9vcXX/b3F1/2xudf9wcnn/bG51/2xudf9xc3r/d3mA/29xd/9ucXv/ -c3V+/3BzfP9sb3n/amxz/2psc/9ucHf/YmVu/2Zpc/9nanT/Z2p0/2dqdP9maXP/Zmlz/25wd/9maXP/ -Z2p0/2Zobv9kZ3H/YmVu/2Rncf9kZ3H/Zmhu/2ptd/9sbnX/ZGdx/2xudf9wc33/am13/2ptd/9iZW7/ -bG51/2Zpc/9ucXv/dXd9/3N1fP9ucHf/bnB3/3N2f/9sb3n/bnB3/25wd/95e4H/bnB3/2xvef9qbXf/ -bnB3/2xudf99foH/cHJ5/25wd/9zdXz/bnB3/3Byef9ucHf/cHN9/3Byef97fof/eXuB/25xe/9wcnn/ -eHl9/3Z4fP94eX3/bW9z/2xudf9sbnX/b3F1/25wd/9vcXX/cHJ5/3Byef9sbnX/cHJ5/25wd/9tb3P/ -d3l//2dqcf9ucHf/c3V8/2ptd/9sbnX/dXd9/2ptd/9sb3n/bG51/2dqdP9qbXf/am13/2ptd/9maXP/ -bnF7/2xudf9sbnX/cHJ5/25xe/9sb3n/c3V8/25wd/9ucXv/eXuB/3V4gf9ucXv/c3V8/3V4gf91eIH/ -bnF7/2ptd/9wc33/cHN9/3Byef9wc33/bnB3/3d5f/9wcnn/cHN9/3d6g/95e4H/c3Z//3V4gf9ucXv/ -cHN9/3V3ff9wc33/b3F1/3V3ff91eIH/bnF7/25wd/91d33/bG95/25xe/91eIH/bnB3/3N2f/9sb3n/ -c3V8/2xudf95e4H/bnB3/3N1fP93eX//dXd9/3Byef9wcnn/dnh8/2xvef9qbXf/cHN9/2xvef91d33/ -am13/2Zpc/9nanT/bG51/2psc/9sb3n/bG51/2xvef9qbXf/bG95/2dqcf9maXP/bnF7/3Byef9sb3n/ -Zmlz/2ptd/9ucXv/am13/2xudf9wcnn/dXd9/3N1fP9zdXz/dXd9/25xe/9zdn//e36H/2xvef9zdXz/ -cHJ5/3V3ff91d33/dXd9/25wd/9sbnf/b3J6/3N2f/9sb3f/dniA/3F0ff90dnz/bnB3/21vc/9sbnX/ -am13/2psc/9ucXv/bnF7/3V3ff9wc33/Z2p0/3Byef9ucXv/a252/2lsdv9sb3n/a254/2tueP9tcHj/ -bG95/2hrdf9maXP/bnF5/2lrcf9tcHj/am13/2dqcv9pbHb/aWt0/2psdP9wcnv/ZWhy/2Zpc/9vcnr/ -a252/2dqc/9nanT/cXR8/25wef9ucHj/ZWhx/2Vocv9kZ3H/Zmlx/2dpcP9nanT/aWx0/2Vocf9gY2z/ -Z2p0/3N1ff9qbXf/Zmly/2Zocf9jZm7/ZWhy/2dqcf9kZ3H/Z2p0/2Rncf9nanP/b3J7/3R3f/9rbnb/ -a211/3R2fP9ydHv/bnF7/21vc/9ucHf/d3l//2psc/9ucHf/cHN9/3N1fP9zdXz/c3Z//2xvef91eIH/ -c3V8/3Z4fP9zdXz/cHJ5/25wd/9ucXv/b3F1/25wd/9ucHf/bnB3/2xudf9sbnX/c3V8/2xudf9sbnX/ -Zmlz/2psc/9qbXf/bnF7/3N1fP9wc33/am13/2ptd/9ucXv/bG51/25wd/9ucHf/foCG/25xe/9wcnn/ -b3F1/2xudf9zdXz/e32D/3N1fP9ucHf/c3V8/25wd/9zdXz/bnF7/3N2f/9wcnn/eXyG/3d6g/9zdn// -c3Z//3d5f/93eX//eXuB/25xe/9ucXv/bnB3/2xvef9sb3n/bnB3/25xe/9zdn//bnB3/2xvef9ucXv/ -cHJ5/3d5f/9kZ3H/bnF7/3Bzff9sb3n/bnF7/3V4gf9ucHf/bG95/25xe/9ucHf/cHN9/25wd/9ucXv/ -bG95/3N1fP9ucHf/bnB3/25xe/91eIH/dXiB/3N2f/9sb3n/bnB3/3h5ff9ucHf/bG51/21vc/9wcnn/ -c3V8/3Byef9nanT/bnF7/3N2f/9sb3n/cHJ5/2xvef95e4H/cHN9/3Bzff91eIH/dXiB/3Z4fP9zdn// -bG95/25xe/91eIH/cHN9/25wd/95fIb/d3qD/3Bzff9wc33/d3qD/25xe/9wc33/eHl9/2xudf9ucHf/ -bG95/25wd/9qbHP/d3qD/2ptd/9sb3n/d3l//25xe/9qbXf/bnB3/3V3ff9ucHf/amxz/3Bzff9sbnX/ -dnh8/2xvef9qbXf/am13/2xudf9qbXf/c3V8/2xudf9wcnn/bnB3/3N1fP9vcXX/bG51/3V3ff91d33/ -dXd9/2ptd/9sb3n/am13/2ptd/9maXP/bnF7/3V3ff9sb3n/cHN9/25xe/9qbXf/cHN9/3V4gf9sbnX/ -cHJ5/2xudf92eHz/cHN9/3d5f/9wc33/bnB4/29xef95e4L/bnB2/3N2fv9ucXr/c3V+/2xvef9ucHf/ -cHJ5/25xe/9ucHf/dXd9/3Byef91d33/c3V8/21vc/9ydHz/b3F6/2ttdv9rbXX/am13/2Zpc/9rbnf/ -bG94/2tueP9naXD/Zmlz/2xveP9oa3X/cnR7/2ptd/9oa3T/cnR7/2xudf9sb3b/dHZ+/3Bydv9sb3n/ -cHN8/3J1ff9tcHn/b3F1/3l7gf92eH7/dXd9/25wd/9tb3f/aGt1/25wd/9ucHf/bG95/3R2f/9ucHf/ -bW92/25wd/97fIH/cHJ5/21wef9ucHf/am13/21wev9ucXv/bnB3/3N2f/9ucHf/b3F4/3F0fv90d4H/ -a254/2lsdv9xdH7/c3V8/3N2f/9wc33/d3qD/3t+h/9ucXv/cHN9/3d6g/91eIH/dXiB/25xe/9ucHf/ -e36H/3Bzff95fIb/d3qD/3Bzff9nanT/bnB3/2xvef9sb3n/c3V8/2ptd/9nanH/cHJ5/3Byef9vcXX/ -bG95/2xudf9ucHf/bG95/3Bzff94eX3/dXd9/3Byef9wcnn/eXuB/3N2f/9zdXz/c3Z//3l8hv9ucXv/ -bnF7/25wd/9ucXv/cHN9/3l8hv9wc33/bG95/3V3ff9wcnn/cHJ5/3Byef9wcnn/bG51/3N1fP9sb3n/ -bG51/2xudf9wc33/bG95/25wd/9qbHP/Z2px/2dqcf9kZ3H/Z2p0/2xudf9sb3n/bnB3/2xudf9vcXX/ -bnB3/25xe/93eX//ZGdx/25xe/9wc33/c3Z//3N2f/95fIb/cHJ5/3V4gf93eoP/c3Z//3t9g/91d33/ -dXiB/3Bzff93eoP/c3Z//3N2f/93eoP/eXuB/3l7gf93eoP/dXiB/3d5f/9/gYf/foCG/3d5f/92eHz/ -e32D/36Ahv99foH/d3l//3t9g/9+f4P/eXuB/3d6g/9wc33/foGK/3N2f/9zdn//eXyG/3l8hv97fYP/ -d3qD/3V4gf9wc33/e32D/3V4gf9ucXv/e36H/3d5f/9ucXv/bG95/3Bzff9vcXX/bnF7/3Z4fP9sbnX/ -am13/25wd/9wcnn/bG51/3l7gf9ucHf/c3V8/3h5ff9zdn//bG51/25wd/94eX3/bnB3/2psc/9zdXz/ -bnB3/3Z4fP9ucHf/bnB3/21vc/9tb3P/bG95/3Bzff9sbnX/cHJ5/3Byef9ucHf/am13/2psc/91d33/ -dXd9/3Byef9maXP/am13/2dqdP9nanH/YmVu/2Zpc/9ucHf/am13/25xe/9ucXv/am13/25xe/91d33/ -amxz/25xe/9qbXf/bnF7/25wd/9zdXz/am13/25xe/9zdn//fH+I/3Byev90d4D/b3J6/3Bzff9nanT/ -bG51/2ptd/9qbXf/bnB3/3N1fP9wcnn/dXd9/3N1fP9sbnb/dXd+/3R3f/9vcnr/bnF6/3Bzff9vcXv/ -dnmC/3p8gv94eoD/cnV//3Byef9zdn//cHJ5/3h6gP9wc33/bnB3/3Z5gv9zdXz/c3V8/3l8hv91d33/ -dHZ8/3R2ff92eYL/dHeA/3N1fP95fIX/d3qD/3Z4f/9wc33/bG95/2dpc/9ucHf/bG51/29xdf9wcnn/ -bnB3/25wd/9sb3n/e32D/29ye/9ucXr/bnB3/21vdv9tcHr/bnB3/29xdf9ucXv/cHJ5/25wd/9tcHr/ -dnmC/2tueP9sb3n/d3qD/3N2f/9ucXv/bnB3/25xe/93eX//bG95/25wd/9wc33/cHN9/3N2f/9wc33/ -bnB3/3t+h/9ucHf/dXiB/3N1fP9wcnn/Z2px/3Byef9sbnX/bnB3/25xe/9ucXv/bnF7/3N2f/9wc33/ -c3V8/2ptd/9sb3n/cHJ5/3N1fP93eoP/eXyG/36Ahv91d33/dnh8/36Ahv95fIb/cHN9/3N1fP9/gYf/ -c3Z//3V4gf93eoP/d3l//3d5f/+Cg4f/e32D/3Z4fP95fIb/c3Z//3V4gf9zdn//c3Z//25wd/95e4H/ -d3qD/3N2f/9zdn//d3qD/3N2f/93eX//bnB3/2xvef9sb3n/bG95/25wd/9ucHf/dnh8/3Byef9vcXX/ -bG51/25wd/9wcnn/dXd9/2Zobv9sb3n/bnF7/3Bzff91eIH/e32D/25wd/9ucXv/bG95/3Byef9zdn// -bnB3/3V4gf9wc33/eXyG/3V3ff93eX//e32D/2Zpc/9nanT/Z2p0/2xudf9sbnX/c3V8/2ptd/9sbnX/ -am13/3N1fP9sb3n/cHN9/2xudf9zdXz/dXd9/25wd/9wcnn/bnF7/36Biv9zdXz/c3V8/3t9g/95fIb/ -d3l//3Bzff9ucXv/bnF7/3N2f/9sb3n/bG51/3d5f/92eHz/bnB3/2ptd/9qbXf/amxz/25xe/93eX// -amxz/2ptd/9sbnX/Z2p0/2Jlbv9wc33/ZGdx/2ptd/9ucHf/am13/2psc/9qbHP/bnF7/2psc/9kZ3H/ -bG95/2xudf9wc33/am13/2Zpc/9sb3n/am13/25wd/9zdn//bnB3/25xe/9wcnn/c3V8/25wd/9ucHf/ -d3l//3Z4fP92eHz/am13/25xe/9wcnn/bW9z/2dqdP9sb3n/cHN9/2xvef9zdXz/c3V8/2xvef9wc33/ -dXd9/2xudf9sb3n/bG51/2xvef9qbXf/bnF7/2ptd/9wc33/bnF7/3h7hf9sb3b/cHJ7/25wdv9ucXv/ -am13/2xudf9sbnX/bG95/2xudf9ucXv/dXiB/3V4gf9zdXz/b3F1/3R2fP9xc3v/bnB1/25wd/9ucHf/ -am13/3Bzff91d33/dnh8/3Byef9sbnX/cHN9/3Byef95e4H/cHN9/25xe/91d33/bW9z/25wd/9wcnn/ -bnB3/29xdf9ucHf/c3V8/3Byef9vcXX/eXuB/3V4gf95e4H/bnB3/25wd/9kZmz/bG51/2dqdP9qbHP/ -bG51/2ptd/9maXP/amxz/3N2f/9qbXf/am13/2ttdv9rbnX/cHJ6/2xvef9wcnn/cHN9/3Byef9vcnn/ -bXB6/3N2gP9oa3X/Z2p0/2xvef9qbXf/dXiB/3N1fP93eoP/eXyG/3N2f/93eX//fn+D/3l8hv95fIb/ -dXiB/3d6g/9+gYr/cHN9/3d6g/91eIH/bnF7/2dqdP9sb3n/bnF7/25wd/9wc33/bG95/2ptd/9wc33/ -bnF7/3Byef9sb3n/bnF7/2xvef9sb3n/c3V8/3V3ff9zdXz/bnB3/25wd/93eX//bnF7/3Byef9ucHf/ -e32D/25wd/9wc33/c3V8/25xe/9ucHf/eXyG/3N1fP9ucHf/dnh8/21vc/9sb3n/cHJ5/25xe/9sbnX/ -dXd9/3V3ff9ucXv/bG51/3N1fP9ucXv/dnh8/2xudf9qbXf/bG51/21vc/9tb3P/bW9z/3N1fP9sbnX/ -amxz/2dqdP9sbnX/bnF7/3N1fP9kZ3H/bG51/2xvef9nanT/am13/2xvef9maG7/bG51/2xudf9qbHP/ -Z2p0/2Rncf9maXP/Zmhu/2Zpc/9iZW7/ZGdx/2dqdP9qbXf/am13/2xvef9qbXf/amxz/3N1fP9maXP/ -Z2px/2Zpc/9sb3n/am13/25xe/9kZ3H/cHN9/25xe/9sbnX/bG95/2xvef91eIH/bnB3/29xdf93eX// -eXyG/3d6g/9wc33/cHN9/3N2f/95e4H/c3Z//3V3ff9/goz/foCG/3d6g/9zdn//d3qD/3Bzff95fIb/ -f4GH/3d5f/93eoP/c3Z//3d6g/91d33/foGK/3Bzff91eIH/d3qD/3N2f/9ucHf/bG95/3N2f/9zdn// -am13/25xe/9ucXv/c3Z//3Bzff9qbXf/c3V8/3Bzff9ucXv/dXd9/29xdf9ucHf/bnB3/3V3ff9ucHf/ -am13/3V4gf95e4H/eXuB/2xvef9wc33/cHN9/3N1fP9ucHf/cHJ5/3V3ff91d33/d3l//3Z4fP9sbnX/ -cHN9/3d5f/9qbXf/bnB3/21vc/9wcnn/bnF7/3V3ff9ucXv/bG51/25wd/94eoH/bnB4/3J0fP9vcXn/ -dHZ9/2xudf9qbXf/Z2p0/2ptd/9nanP/bG95/2xvef93eX//bnF7/2psc/9tcHn/bnB5/21vdP9rbXT/ -bnB3/2dqcf9sb3n/cHN9/25xe/9sb3n/amxz/2xvef9maG7/bG95/2dqcf9nanH/am13/2dqdP9maXP/ -bG95/2ptd/9qbXf/am13/2xudf91d33/bG95/3l8hv95e4H/eXuB/3Bzff9ucHf/am13/3N2f/9zdXz/ -c3V8/3V4gf91d33/dXiB/3d5f/+DhYz/e32D/3h6gP9zdn7/b3F5/2xvef9rbnj/Z2px/2dqdP9qbHP/ -a210/2xvef93eX//c3V8/25xev91eIH/cHN9/2xudf9sbnX/cHJ5/3Bzff9kZ3H/bnF7/3N1fP9sb3n/ -bG95/2xvef9ucXv/dXiB/2xvef91d33/bnF7/3N1fP9sbnX/bnB3/2xudf9ucHf/bG51/25wd/9qbXf/ -c3Z//25wd/9sb3n/bnF7/2ptd/9sb3n/bnB3/3Bzff93eoP/c3Z//25xe/9sb3n/dXiB/25xe/9wc33/ -cHJ5/3t+h/9ucXv/bG95/29xdf9sbnX/cHJ5/3t9g/9ucXv/amxz/3V3ff9qbHP/am13/2ptd/9sb3n/ -Z2p0/3V3ff9sb3n/am13/2psc/9zdXz/cHJ5/3d5f/9tb3P/bW9z/2xudf9nanH/bG51/2xudf91d33/ -bG51/21vc/9sbnX/bG51/3Z4fP92eHz/Z2p0/2xvef91d33/c3V8/25xe/9zdXz/b3F1/25wd/9ucHf/ -bnB3/25wd/9nanT/bG95/2ptd/9ucXv/am13/2xudf9sbnX/bG95/25wd/9wcnn/bG95/2xudf9zdXz/ -Z2p0/2dqcf9nanT/bG95/2ptd/9ucXv/ZGdx/25xe/9zdXz/bG51/2xvef9qbXf/cHJ5/2dqcf9nanH/ -bG95/3Bzff9ucXv/Z2p0/2dqdP9nanT/bG95/2Zpc/9kZ3H/dXd9/3Byef9qbXf/bG51/2xudf9qbHP/ -cHN9/3N2f/9qbHP/Z2p0/2dqcf9nanT/Zmlz/3V3ff9qbXf/bnF7/2xvef9sb3n/bG51/2xudf9sb3n/ -c3V8/2dqcf9ucHf/bnB3/25xe/9ucHf/Z2px/2xudf9ucHf/c3V8/3Z4fP9vcXX/cHJ5/25wd/91d33/ -bnB3/2xvef91eIH/dnh8/3V3ff9ucHf/cHN9/3N1fP9vcXX/b3F1/2xvef9zdXz/c3V8/3d5f/92eHz/ -bnB3/3Z4fP93eX//bG51/3N1fP9sbnX/cHJ5/3V3ff93eX//c3Z//25xe/9ucXv/d3qD/29yfP9zdn// -c3V9/3l7gf9qbXf/bnF7/3Byef9zdn//a254/3N2f/91eIH/e32D/3d6g/9wcnn/cXR+/3J1fv9ucXn/ -bnB3/3Byef9qbHT/c3Z//3h6gP9zdn//bnF7/2xvef9zdXz/b3F1/3N1e/9sbnX/bG51/3R2fP9ucXv/ -bnB3/3F0ff9vcXj/b3F4/25xe/9zdXz/dXiB/25xe/95fIb/eXuB/3l7gf9ucXv/am13/2Zpc/9wcnn/ -bnB3/2ptd/9wc33/bG95/3Bzff9ucHf/d3qD/3N2f/9wcnn/bnB3/29xdv9ucHf/cHJ5/25wd/9ucXv/ -bG95/25wd/9sb3j/dXd8/29xd/9sbnX/cHN9/2xvef9ucHf/bG95/3d5f/91eIH/Zmlz/3V4gf95e4H/ -cHN9/3N1fP91eIH/d3qD/4GDiv95e4H/eXyG/3V4gf93eoP/bnF7/3N1fP9ucXv/bG95/2xvef9ucHf/ -bnB3/3N2f/9wcnn/bnB3/2ptd/9ucHf/bG51/25wd/9ucXv/d3l//25xe/9ucHf/amxz/3d5f/9ucXv/ -am13/2ptd/91d33/bG51/3Byef9ucHf/cHN9/3V4gf9+gYr/d3qD/3Bzff97fof/cHN9/3N2f/93eoP/ -dXiB/3N2f/97fof/e32D/3d6g/91d33/e32D/3d6g/9+gYr/cHN9/3N1fP9zdXz/cHJ5/2xvef9ucHf/ -dXd9/25wd/9tb3P/bnB3/25wd/9zdn//dXd9/25wd/9tb3P/c3V8/2xvef9sb3n/cHN9/2dqcf9qbHP/ -amxz/2ptd/9qbXf/Z2p0/2ptd/9sb3n/cHN9/2xudf9nanT/am13/2dqdP9maXP/Z2p0/2dqdP9kZ3H/ -am13/2Rncf9maG7/YmVu/2Zpc/9kZ3H/am13/1xfaP9qbXf/bG95/2BjbP9kZ3H/Z2px/2xvef9maG7/ -Zmhu/25wd/9zdXz/bnF7/2dqdP9maXP/Z2p0/25wd/9qbHP/Zmlz/3N1fP91d33/am13/25wd/9qbXf/ -bG51/2xvef9zdn//amxz/2xudf9qbHP/bnB3/21vc/93eX//am13/3N1fP9wc33/bG95/2ptd/9qbXf/ -bG95/25xe/9maXP/bG51/2xudf9ucXv/bG95/2psc/9sbnX/bnB3/3Byef91d33/bnB3/25wd/9zdXz/ -cHJ5/29xdf9sbnX/dXd9/3V4gf95e4H/cHN9/3V4gf9zdn//cHJ5/3N1fP9wc33/e32D/3t9g/9+gYr/ -eXuB/3Bzff95e4H/eXuB/25wd/9zdn//bG95/3N2f/91eIH/eXyG/3d5f/9wcnb/b3F2/3Z4ff9vcXj/ -cHN7/21veP90dn3/am13/3Byef9wcnn/cHN8/2psc/9ucHf/bnB3/3V3ff9wcnn/bW9z/29xeP9sb3n/ -amxy/2Zpcv9oa3T/X2Js/2hrdf9xc3v/bG95/2xudf9pbHb/bXB6/2ttdf9rbnf/a252/2lsdv9tb3j/ -bW93/2psdP9vcnz/amx0/2dqdP9tb3b/bG51/3N1fP9qbXf/d3qD/3Bzff9wc33/bG95/2ptd/9qbHP/ -bnB3/21vc/9sbnX/bnB3/2xudf9wcnn/bW9z/3d5f/9wc33/bG95/29xef9sbnX/aWx2/2ptd/9nanT/ -am13/2xudf9nanT/a210/3N1ff9vcXn/bW93/3V4gf91eIH/am13/2ptd/9wc33/cHN9/2Jlbv9ucXv/ -dXd9/25wd/9sbnX/bG51/25wd/91d33/cHJ5/3V3ff9sbnX/cHN9/2dqdP9vcXX/bG51/2xudf9qbXf/ -am13/2xudf9zdXz/bnB3/29xdf9maXP/bG95/2xvef9sb3n/c3Z//3V4gf9wcnn/c3V8/2psc/91d33/ -cHN9/25xe/9sb3n/d3l//2xvef9ucXv/bnB3/2xudf9zdXz/foCG/3N2f/9sb3n/d3qD/2xvef9sb3n/ -c3Z//3N1fP9ucHf/dnh8/3Byef9ucHf/bG95/3V3ff9wcnn/e32D/29xdf9tb3P/bG51/29xdf9ucHf/ -b3F1/3Z4fP9ucHf/bnB3/3Byef9zdXz/dXd9/3V3ff9nanH/bG51/3d5f/9sb3n/am13/2xvef9sbnX/ -bnF7/2xvef9nanT/am13/2Rncf9maXP/Zmlz/2dqdP9iZW7/XF9o/2Rncf9ucXv/am13/3Byef9zdXz/ -bG51/3V3ff9ucHf/bG51/2psc/9zdXz/cHJ5/3N1fP9maG7/cHJ5/3N1fP9nanT/dXd9/2xudf92eHz/ -b3F1/2xvef91eIH/d3qD/3V4gf9sb3n/bnF7/3N2f/91d33/bnB3/2xvef93eX//dXiB/25wd/9sbnX/ -bG51/25wd/9zdXz/d3l//2ptd/9qbXf/bnB3/3Byef9vcXX/dnh8/21vc/9zdXz/cHN9/2xvef9qbXf/ -bG51/2xudf9qbXf/Zmlz/2xudf9qbXf/bG95/2xudf9maXP/bG51/2ptd/9ucHf/d3l//2ptd/9sbnX/ -bnF7/2ptd/9sbnX/am13/3d5f/93eX//eHl9/25wd/91d33/cHN9/25wd/9ucXv/cHJ5/3l7gf93eX// -e36H/3d5f/9ucHf/dXiB/3d5f/9wcnn/c3Z//2xvef9ucXv/c3Z//3l7gf92eHz/Z2pz/2Zpcv9ucHj/ -Zmlz/2hrc/9pbHb/bXB6/2dqdP9maXP/Zmlz/2dqdP9hZGz/Z2px/2dqcf9zdXz/am13/2dqdP9oa3X/ -a254/2hrdP9oa3P/am13/2hqcf9tcHj/cHJ5/3Byef90dnz/bnB5/3V4gf9ydHz/cXR+/29ye/9vcnv/ -b3J8/3N2f/9xc3r/eXyF/29ye/9tb3f/cnR+/3N1fP93eX//bnF7/3l8hv95e4H/dXiB/3N2f/9ucHf/ -am13/3N1fP9wc33/cHN9/3N2f/9ucHf/bnF7/2xvef95e4H/dXd9/25wd/9wc3r/cHN6/29ye/9ydX7/ -c3Z//3V4gf9zdXz/c3Z//3J1fv94eoL/cXN6/25weP9zdXz/c3V8/3V4gf91d33/foCG/3t9g/9wc33/ -d3qD/3l7gf93eoP/c3Z//3N2f/9zdn//d3qD/3N2f/93eX//bnB3/3V4gf9nanT/cHJ5/3Byef9wcnn/ -cHJ5/2xvef9wcnn/d3qD/3N2f/91d33/am13/3N1fP9wc33/cHN9/3l8hv97fYP/d3qD/3N2f/9ucHf/ -eXuB/3N2f/9ucXv/cHN9/3l7gf9wc33/c3Z//25wd/9wcnn/dXiB/36Ahv9zdn//bnB3/3d6g/9vcXX/ -bnB3/3N1fP9wcnn/bG51/3h5ff9wcnn/cHJ5/2xudf9zdXz/cHJ5/3d5f/9tb3P/bG51/2dqdP9ucHf/ -bnB3/3Byef93eX//bnF7/25wd/9ucXv/c3Z//3V3ff91d33/Z2p0/25xe/95e4H/c3Z//3N2f/9wc33/ -bnB3/3N2f/9ucHf/bnB3/3V3ff9sbnX/cHJ5/3V3ff91d33/b3F1/2dqcf9wcnn/c3Z//3Byef9zdn// -dXiB/3Bzff95e4H/c3Z//25xe/9qbXf/c3Z//3V3ff91d33/amxz/3Byef94eX3/bG95/3N2f/9ucXv/ -dXd9/25wd/9ucXv/d3qD/3V4gf93eoP/b3F1/3Byef91d33/dXd9/2xvef9nanT/cHJ5/3V3ff9sb3n/ -am13/2ptd/9wcnn/cHJ5/3l7gf9wcnn/bG51/21vc/9sb3n/b3F1/3h5ff9sbnX/c3V8/3V3ff9wcnn/ -bnB3/25wd/9ucHf/bnB3/2xudf9tb3P/bG51/25wd/9sbnX/Z2p0/2xudf9qbHP/am13/3N1fP9qbXf/ -Z2px/2dqdP9qbHP/Zmlz/2Jlbv9qbXf/am13/2xvef9maG7/Z2p0/2Rncf9gY2z/ZGdx/2Rncf9sb3n/ -Zmlz/3Bzff9zdXz/amxz/2ptd/9zdXz/bG51/25xe/9qbXf/am13/2xvef91d33/c3V8/21wev9vcXb/ -dHZ8/25wd/9vcnz/bXB5/3N2f/9sbnX/bG51/25wd/9ucXv/Zmlz/21vc/9sbnX/dXd9/25wd/9ucHf/ -cXN6/29xeP9ucHj/bnF6/3Bzff9vcnz/dHeA/3J1f/9wc33/dnmC/3J0fP93eYD/dHZ9/29xeP9wcnr/ -bnB4/3Byef9ydHv/b3F5/3h7gv9vcnz/bG93/3Fzev9sb3n/dnh8/29xdf95e4H/d3l//3N1fP9zdn// -bnB3/2dqcf9tb3P/bG51/2xudf9sb3n/amxz/2ptd/9nanH/c3Z//2xvef9qbHP/bG94/21vdv9rbnb/ -bG95/2ptd/9qbXf/Z2p0/2xudf9sbnX/cnR7/29xeP9oa3T/bG95/2xvef9ucXv/bG95/3V4gf9zdn// -amxz/25xe/91d33/bnB3/21vc/9qbXf/cHJ5/3d5f/9wcnn/d3l//2xvef91d33/Z2p0/25xe/9sb3n/ -bG95/3Byef9tb3P/bW9z/3Bzff9sbnX/Z2p0/2BjbP9nanT/Z2p0/2Zpc/9sb3n/bnF7/2dqdP9nanT/ -YmVu/25wd/9maXP/ZGZs/2Rncf9sb3n/Zmhu/2ptd/9kZ3H/YmVu/2Zpc/9ucHf/Z2p0/2BjbP9sb3n/ -YmVu/2Rncf9qbXf/Zmlz/2psc/9qbXf/Zmlz/2Rncf9iZW7/am13/2dqdP9zdn//amxz/2psc/9nanT/ -am13/2xudf9nanH/dXd9/2xudf9tb3P/bnB3/3Byef94eX3/d3l//2ptd/9ucXv/eXuB/3V4gf93eoP/ -dXiB/3N1fP95e4H/cHN9/3Bzff93eoP/cHJ5/3V4gf91eIH/c3Z//25wd/9qbXf/cHN9/3V3ff9vcXX/ -c3Z//3V4gf9ucHf/c3Z//25wd/9wc33/Z2p0/3N2f/9wc33/cHN9/2ptd/9wc33/dXiB/2ptd/9wc33/ -bnF7/3Z4fP9wcnn/cHJ5/3l7gf93eX//e32D/29xdf91d33/dXd9/3N1fP9sb3n/Z2p0/3V3ff91d33/ -bnB3/2xvef9sbnX/bnB3/25wd/91d33/bW9z/2xudf9tb3P/bW9z/2ptd/91d33/bG51/3N1fP91d33/ -bnB3/25wd/9ucHf/bnF7/3Bzff9ucHf/bnB3/2xvef9wc33/bnB3/2dqdP9sb3n/bnB3/3N1fP91d33/ -bnB3/21vc/9wcnn/bG51/2xvef9qbXf/dnh8/3h5ff91d33/bG51/25wd/9ucHf/am13/2xudf9nanT/ -c3V8/2xvef91d33/dXd9/2xudf9sb3n/c3V8/2dqdP9ucXv/Zmlz/2xvef9wcnn/d3l//3Bzff9wc3v/ -bXB5/3J1fv9qbXf/bnF7/2ptd/9zdXz/bG51/25wd/9zdXz/bnF7/2ptd/9ucXv/cHJ5/3d5f/9ucXv/ -cHN9/3V4gf9ucXv/bnF7/25wd/9vcnz/bXB6/21wev9oa3X/bXB6/3R2fP9ucHX/eHqA/29xef9sb3n/ -bG95/2dqdP9qbXf/Z2p0/2Zpc/9ydHz/bXB4/2lsc/9tb3j/a253/3V3ff9ucHf/d3qD/3V4gf91d33/ -dXd9/29xdf9maG7/bnB3/21vc/9sbnX/bnF7/2xudf9wcnn/bW9z/3V4gf9wc33/amxz/2ptd/9qbXb/ -bnB3/29xeP9qbXf/bnB3/2dqcf9sbnX/bG51/21wev9rbnf/Z2p0/2psc/9sb3n/cHJ5/2psc/91d33/ -dXd9/2psc/9sb3n/c3V8/3Byef9sb3n/bnB3/3V3ff94eX3/bnF7/3l8hv9zdXz/e32D/2xvef9zdn// -d3qD/3N2f/93eoP/dXd9/3N2f/9+gIb/cHN9/3N1fP9sb3n/cHN9/3N2f/9zdn//d3qD/3t9g/95fIb/ -d3qD/3Bzff97fof/eXyG/3V4gf9zdXz/dXiB/25wd/9wcnn/bnB3/3Byef91d33/d3qD/3d5f/9sb3n/ -d3l//25wd/9ucXv/d3qD/3V4gf91eIH/d3qD/3V4gf91eIH/dXd9/3t9g/93eoP/foGK/3Byef9ucXv/ -bnB3/25xe/9wcnn/c3V8/3t+h/9wc33/cHJ5/25xe/9wc33/d3l//3h5ff9qbXf/cHJ5/3d6g/9wcnn/ -dnh8/3N1fP9sbnX/dnh8/29xdf9ucHf/cHJ5/21vc/9zdXz/c3V8/3N1fP9tb3P/bG51/3N2f/9ucXv/ -bG51/2xvef9wc33/Zmlz/2xvef9nanH/Zmlz/2BjbP9qbXf/Z2p0/2ptd/9iZW7/am13/25xe/9qbXf/ -bnF7/25wd/91d33/bnF7/2xvef93eoP/eXuB/36Ahv9wcnn/c3Z//3l7gf93eoP/c3Z//25xe/9+gIb/ -foGK/3l7gf97fYP/d3l//3t9g/93eoP/foGK/3V4gf93eoP/c3Z//3V4gf9zdn//eXyG/3N2f/95e4H/ -e32D/3N1fP9wcnn/cHJ5/25xe/9zdn//c3V8/25wd/9ucHf/c3Z//3Byef9qbXf/b3F1/29xdf9wc33/ -dXiB/3Bzff9wcnn/bG95/25wd/9zdXz/bG51/3V3ff92eHz/dXd9/25wd/9sb3n/bnF7/2xvef9ucHf/ -cHJ5/3h5ff9wcnn/foCG/3t9g/9tb3P/cHJ5/3Z4fP9ucHf/dXd9/2ptd/9ucHf/c3Z//3V4gf92eHz/ -c3V7/21wd/9wcnr/am13/3N1fP9sbnX/bnF7/2ptd/9sbnX/cHN9/25xe/9qbHP/bnB3/29xdf91d33/ -bG95/25xe/9wcnn/bG95/21vc/9ucHf/bG95/25wd/91d33/amxz/25xe/9zdn//c3V8/36Biv93eoP/ -c3Z//3d6g/91d33/cHN9/3d6g/91d33/foCJ/2Zpcv9jZnD/bnB3/2ptdv9vcnz/amxz/3d5f/93eX// -c3V8/3V3ff9ucHf/ZGZs/2xvef9sb3n/cHN9/3N2f/9vcXX/cHN9/25wd/93eoP/dXiB/25xe/9ucXv/ -bXB6/3Byef9vcXr/bnB3/2xvef9nanT/cHJ5/25weP90d37/c3V6/25weP9ucXr/c3Z//25xe/9maXP/ -c3V8/3V3ff9nanH/bnB3/3N1fP9zdXz/bnB3/21vc/9zdXz/d3l//25xe/9zdn//bG51/3Bzff9kZmz/ -bG51/2xvef9sbnX/c3V8/29xdf9sb3n/c3Z//25wd/9qbXf/Z2p0/3Byef9ucHf/bG51/3Bzff9zdn// -cHN9/2xvef9sb3n/dXd9/3V4gf9zdn//cHJ5/3V4gf9ucXv/cHN9/3Bzff9ucHf/c3Z//3d5f/91d33/ -Z2px/3Z4fP9sbnX/bG51/3Bzff9ucHf/bW9z/25wd/9sbnX/bnF7/2xudf9wc33/cHJ5/3V3ff9nanT/ -bG51/2dqdP9nanT/am13/2xudf93eoP/bG51/2xudf9wcnn/cHJ5/3d6g/93eX//bnB3/25wd/93eoP/ -cHN9/3d5f/9zdn//am13/3V3ff9ucHf/c3V8/3V3ff9tb3P/cHJ5/3N1fP91d33/bG51/2xudf9ucHf/ -dnh8/2xvef91eIH/cHN9/25wd/9zdXz/bnB3/2xvef9qbXf/dXiB/3N1fP9zdn//bnB3/3N2f/9zdn// -cHJ5/3V4gf93eoP/c3Z//3N2f/9zdn//e36H/3l7gf9/gYf/bnB3/25xe/91d33/c3V8/21vc/9ucHf/ -dXd9/3d5f/9ucHf/bnB3/2xudf9sb3n/bnB3/3V4gf9qbXf/bnF7/25wd/9sbnX/bnB3/3V3ff9vcXX/ -dXd9/3V3ff9ucHf/bnB3/2xvef9wc33/cHN9/3Byef9wcnn/cHN9/3V4gf9zdn//bnF7/3N2f/91d33/ -eXyG/36Biv91eIH/dXiB/3N1fP9wc33/dXiB/25xe/9zdn//dXd9/3Bzff9ucHf/cHJ5/3Byef9qbXf/ -cHJ5/2ptd/91d33/bG95/36Ahv97fYP/bW9z/3Byef91d33/b3F1/3Bzff9sb3n/bG95/3V4gf95e4H/ -d3l//3d5gv9ucXv/cHN9/25wd/9zdn//c3V8/3Bzff9sb3n/bnB3/3Z4fP9zdn//am13/25xe/9ucHf/ -dXiB/25wd/9wc33/cHN9/3Byef9vcXX/bG51/25wd/9zdXz/dXd9/2psc/9wcnn/bnF7/2xudf91d33/ -c3V8/25wd/9ucXv/am13/2psc/9sbnX/bW9z/3V3ff9ucHf/aWxz/3Fzef9sbnX/c3V+/25wd/93eX// -d3l//3Bzff93eoP/bnF7/2Zpc/9wcnn/bnB3/3Bzff9zdn//bG95/3N2f/9ucXv/dXiB/3V4gf9wc33/ -cnV+/25weP9rbXX/bXB4/2hqcf9maXP/YGNs/2ptd/9qbXf/b3J7/25wd/9pa3P/amxz/2ptd/9wc33/ -Zmlz/3V3ff91d33/amxz/3Byef9zdXz/cHN9/3N2f/9wc33/eXyG/3l8hv91eIH/d3qD/25xe/9zdn// -ZGdx/25wd/9ucXv/bW9z/3Byef9sbnX/bG51/3N1fP9qbHP/Zmlz/2dqdP9sbnX/amxz/2Rncf9ucXv/ -am13/2xvef9nanH/YmVu/2ptd/9qbXf/Z2px/2Zpc/9nanT/amxz/2psc/9sb3n/Z2p0/25xe/9wc33/ -cHN9/2Zpc/93eX//Z2p0/2xudf9zdn//c3Z//2ptd/9wcnn/b3F1/3Byef9vcXX/cHJ5/25wd/91d33/ -Z2p0/2ptd/9qbHP/bG51/2xvef9sbnX/d3qD/2dqdP9sbnX/bnF7/2xvef93eX//bnF7/2xudf9nanT/ -c3V8/2ptd/9qbXf/bG95/2Zpc/9wcnn/am13/2xvef9wc33/amxz/2ptd/9sb3n/cHN9/2ptd/9tb3P/ -bG95/3Z4fP9ucHf/c3V8/25xe/9qbHP/bnF7/2xudf9sbnX/YGNs/2xvef9sb3n/bG95/2psc/9sbnX/ -am13/2xudf9zdXz/cHJ5/3Byef9wcnn/am13/3N1fP9wc33/eXyG/21vc/9ucHf/dXd9/2xvef9qbXf/ -bG51/3V3ff93eX//bG95/3Byef9ucHf/bG95/25wd/97fYP/b3F1/3Byef9wcnn/bG51/2xudf93eX// -am13/3Bzff9wc33/bW9z/2ptd/9nanT/am13/2xvef9sbnX/Z2p0/2xudf9nanT/amxz/11gav9sbnX/ -Z2px/2ptd/9zdXz/bG95/2xvef9qbHP/bG51/25xe/9nanT/dnh8/3N1fP9wc33/bnF7/3N2f/9zdn// -am13/3Bzff9zdXz/e32D/3V4gf+Fh43/f4KM/3N2f/93eoP/foCG/3N1fP95fIb/dnh8/3l7gf9+gIb/ -e36H/36Ahv95fIb/c3Z//3N2f/9sb3n/dXiB/2xvef9ucXv/bG95/3Byef91eIH/eXuB/2ptd/9ucXv/ -bnB3/3Bzff9wcnn/c3Z//3V4gf9sb3n/bG95/2xudf9sbnX/cHJ5/3V3ff9nanH/bnF7/3Bzff9ucXv/ -d3qD/3N2f/9ucXv/dXiB/3Byef9qbXf/b3F4/25wd/92eHz/cXR9/25wd/9vcnv/bG95/3N2f/9wcnn/ -d3qD/3d6g/9zdn//dXiB/3Bzff9nanT/bnB3/25xe/9zdn//cHN9/25wd/9zdn//cHJ5/3h5ff91d33/ -bG51/2xvef9tb3f/bnB4/29xev9rbnj/bnB3/2psc/9ucHf/b3F5/3J0ev9ucHb/Zmhv/2ptdP9sb3n/ -cHJ5/2dqcf93eX//c3V8/2dqcf9qbXf/cHJ5/25xe/9ucXv/cHN9/3t9g/95fIb/c3Z//3d6g/9zdn// -d3qD/2ptd/9zdXz/dXiB/3Bzff95fIb/dXd9/3V4gf9+gIb/cHN9/25xe/9qbXf/cHJ5/25wd/9sbnX/ -c3Z//3Bzff9wc33/bW9z/2ptd/9ucXv/bG95/2psc/9nanH/Z2px/2psc/9sbnX/bG95/2xudf9zdXz/ -dXd9/3N1fP9qbXf/dXiB/2dqdP9wcnn/c3V8/3N1fP9sbnX/am13/2xudf9sb3n/am13/2xvef9sb3n/ -dXd9/2ptd/9qbXf/Z2p0/2xudf9wcnn/b3F1/31+gf9vcXX/bW9z/3N2f/9wc33/dXiB/3N1fP9ucHf/ -cHN9/3d6g/9zdn//c3Z//3N2f/9sb3n/eXuB/25wd/9zdn//dXd9/25wd/9ucXv/dXiB/3l7gf9sb3n/ -bnB3/3N1fP9wcnn/Z2p0/2xvef9sb3n/bG51/25xe/9qbXf/bG95/2BjbP9sb3n/cHN9/2xvef9tb3P/ -bnB3/2xvef9qbXf/cHN9/25xe/9ucXv/bG95/25xe/91d33/c3V8/3t9g/9qbXf/bG95/3Z4fP9ucHf/ -bnB3/2psc/92eHz/dXd9/25xe/9ucXv/bnF7/3Byef9ucXv/f4GH/3Byef9wc33/c3Z//25xe/9ucXv/ -d3qD/2xvef9wc33/cHN9/25wd/9ucXv/bnF7/3V4gf91eIH/bnF7/25wd/9ucHf/cHJ5/21vc/9iZW7/ -amxz/2psc/9qbXf/cHN9/2dqdP9ucXv/amxz/2ptd/9qbXf/Z2p0/3Bzff9ucHf/cHJ5/21vc/9ucHf/ -bnB3/2Zpc/9nanT/Z2p0/3V3ff9ucHf/fX6B/3d5f/9sbnX/bG95/3h5ff9ucHf/cHN9/2xvef9ucHf/ -dnh8/3V3ff91d33/dXd9/29xdf9ucHf/bG51/3Byef9sbnX/bG95/2ptd/9sbnX/cHN9/3V3ff9maXP/ -bG95/2xudf9qbXf/amxz/2ptd/9sb3n/Zmhu/2psc/9maXP/amx0/2ptd/9sb3n/YmVu/2xvef9tcHn/ -bW92/3V3ff9xdH3/bXB6/3V3ff9vcXj/bXB5/3Fzev9ydHr/dXh//3J0fP9vcXn/b3J7/29xdv9wcnn/ -bW9z/3V3ff93eX//bnB3/3Byef9wcnn/ZGdx/2ptd/9maXP/bG95/25xe/9qbXf/c3V8/2xudf91d33/ -c3V8/25wd/9zdXz/bXB6/21wev9ucXn/bG95/2xvef9sbnX/bnB3/25xe/92eH3/c3V8/2ptdf9vcXb/ -c3V8/3N2f/9maXP/e36H/3N2f/9sb3n/bG95/25xe/9zdn//cHN9/3N2f/93eX//eXuB/3Bzff93eoP/ -cHN9/3d6g/9nanT/bnB3/3N2f/9wcnn/c3Z//25wd/9ucXv/d3l//25wd/9sbnX/Z2p0/3Byef9ucHf/ -am13/3V4gf91eIH/c3Z//25wd/9sb3n/c3V8/3N2f/9ucHf/bnB3/25xe/9ucHf/bnB3/3V4gf9wc33/ -c3Z//3V3ff91d33/bnB3/3l7gf9nanT/bnF7/3Bzff9zdXz/bG51/2xudf9sbnX/bnB3/2xudf9sbnX/ -bG95/3Z4fP9qbXf/bG95/2xvef9wcnn/d3qD/3N1fP9+gIb/c3V8/3N1fP93eoP/dXiB/3t+h/93eoP/ -c3Z//3N2f/9+gYr/eXyG/3N2f/91eIH/bG95/3V4gf9ucHf/dXd9/3V3ff9wcnn/bG95/3N1fP9wc33/ -Zmlz/2dqcf9qbXf/eHl9/2xvef9wc33/c3Z//25xe/9zdn//cHN9/3V4gf9sb3n/dXiB/3t9g/91eIH/ -dXd9/3l7gf95e4H/d3l//35/g/95e4H/d3qD/3d6g/95e4H/eXyG/3d6g/+DhYz/dXiB/3d6g/97fYP/ -d3qD/3Bzff9wcnn/eXyG/3t+h/9wc33/bnF7/25wd/9wc33/cHN9/3l8hv9vcXX/c3V8/25wd/9tb3P/ -bG51/3V3ff9sbnX/cHN9/3N2f/9ucHf/bnF7/2ptd/9wc33/cHN9/3Bzff9sb3n/bnF7/3Bzff9vcXX/ -ZGZs/29xdf9ucHf/cHJ5/3V3ff9ucHf/dXd9/2xudf9ucHf/bG95/2xudf9zdXz/bnF7/3Byef9sbnX/ -bG51/21vc/9sbnX/cHJ5/2dqcf94eX3/bG95/3t9g/91d33/am13/25xe/91d33/am13/2ptd/9sbnX/ -bW9z/3V3ff94eX3/dXd9/29yfP9ucHf/bnB3/2ptd/9ydHz/b3F1/3V3ff9ucHf/bnB3/3V3ff9zdXz/ -Z2px/3Byef9ucXv/dXiB/3Byef9zdn//dXiB/3Byef9sb3n/a254/3Byd/9vcXn/cHJ5/2ttc/9tb3j/ -bnF7/25xev91d37/cHN8/25weP90dn//cXN5/29yev9ydH3/bnB3/3V3fv9ydX7/b3J8/3F0fv9zdn// -dXiB/25xe/93eX//d3l//25xe/9zdXz/bW9z/2dqcf9ucHf/bG51/3V3ff9ucHf/am13/3N1fP9sbnX/ -cHN9/3N1fP9qbXf/cHJ5/2xudf9rbnf/amx0/2ttc/9kZ3H/Zmlz/2psc/9qbXf/bnF6/3F0fP9rbnf/ -bXB4/3R2fP9wc33/YGNs/3d6g/9ucXv/Zmlz/2psc/9qbHP/Z2p0/2dqdP9nanT/c3V8/25wd/9sb3n/ -cHJ5/2dqcf9wc33/Zmlz/2xudf9qbXf/amxz/2ptd/9qbXf/bG95/3N1fP9sbnX/bG51/2Zpc/9qbXf/ -bG51/2psc/91d33/cHN9/25xe/9qbXf/am13/3Bzff9zdXz/amxz/2psc/9nanH/Z2px/2Zpc/9ucXv/ -am13/3Bzff9zdXz/cHJ5/2psc/91d33/bnB3/25xe/91d33/dXd9/2xvef9sb3n/bG95/25xe/9qbXf/ -cHN9/3N2f/95e4H/bG95/3N2f/9wcnn/cHJ5/3d6g/9wc33/foCG/25wd/9vcXX/c3V8/2xudf92eHz/ -cHJ5/29xdf9sbnX/dXd9/25wd/9wcnn/bG95/2Zpc/9zdXz/bW9z/3Z4fP91d33/bW9z/25wd/91d33/ -dXd9/2xudf9ucHf/cHJ5/25wd/9qbHP/bG95/25xe/9sbnX/bnF7/2dqcf9nanT/YGNs/2xudf9sb3n/ -amxz/2psc/9qbXf/amxz/2psc/9sb3n/am13/2xvef9qbHP/cHN9/3N1fP9sb3n/eXuB/2dqcf9nanT/ -am13/2dqdP9maG7/Zmlz/3Byef9zdXz/bG95/2xvef9tb3P/am13/2ptd/9zdn//am13/2xvef9sb3n/ -bG51/21vc/91d33/am13/2xvef9zdXz/bG51/2xvef9maXP/bnF7/25xe/9ucXv/am13/2xudf9nanT/ -Zmhu/2BjbP9qbHP/am13/2ptd/9ucXv/bnB3/3V3ff9sbnX/bG51/25wd/9qbXf/c3V8/25wd/9ucXv/ -am13/2xvef9sb3n/am13/25xe/9qbXf/dXiB/3N2f/9/gYf/eXyG/3Bzff91eIH/d3l//25wd/9zdXz/ -bnB3/29xdf9zdXz/dnh8/3V3ff9wcnr/b3F4/3J0ev9tb3f/cXN6/2ttdP9ucXv/bG51/25wd/94eX3/ -cHJ5/2dqcf9zdXz/c3V8/3N1fP9ucHf/bnB3/3Z4fP9vcXb/bXB6/2xvef9wc3z/cXN7/3Fze/9xdHv/ -cHJ5/3R2fv92eH7/dHeB/3R3f/9xdHz/eXuA/3d5f/9ydX3/eXyF/3BzfP93eYD/dHd//3Bzff90dn3/ -cHJ5/25xe/9tcHn/dnh8/3V3gP9ucXr/bnF6/2xvef9rbnj/aWx2/2tueP90dnz/b3F4/25wdP90dnv/ -bW93/3J0fP9zdXz/bW92/3J0fP9qbXf/bG51/25wdf9ucHb/bG51/2psc/9sbnX/am13/2ptd/9ydHr/ -Z2pz/2ptd/9xc3n/bG95/2Jlbv99foH/c3V8/2xudf9tb3P/bG51/25wd/9ucHf/bnB3/3V3ff91d33/ -cHN9/3Byef9maG7/bG95/2Rncf9iZW7/Z2p0/2xudf9qbXf/Z2p0/2xudf9ucXv/amxz/2dqdP9nanT/ -am13/2dqcf9nanH/cHJ5/25xe/9sb3n/am13/2xudf9ucXv/c3V8/2xvef9qbXf/bnB3/29xdf9ucHf/ -c3V8/3Byef91d33/bG95/2xvef9nanT/dXd9/29xdf9wcnn/dXd9/3Bzff9qbXf/bG51/2xudf9sb3n/ -Zmlz/2ptd/9qbXf/cHJ5/2Rncf9qbHP/Z2p0/2ptd/9sb3n/bG95/3d6g/9nanH/Z2px/25xe/9qbHP/ -d3l//2xvef9qbHP/bG51/3N1fP9sb3n/bG95/25xe/9maXP/bG95/2dqcf9ucXv/bG95/2dqcf9nanT/ -bnF7/25xe/9maXP/bG51/2ptd/95e4H/cHJ5/3V4gf93eoP/cHJ5/3l7gf9wc33/bnF7/2dqdP9sb3n/ -c3V8/3Byef9ucHf/c3Z//25xe/9ucXv/cHN9/25xe/9ucXv/bG95/3h5ff94eX3/cHJ5/4CChv9sbnX/ -bG51/3N1fP9wcnn/bnB3/2xvef91d33/dnh8/3V3ff9wcnn/bG95/3Bzff9zdn//eXyG/3Byef9ucHf/ -bnB3/25wd/9vcXX/dnh8/25wd/9zdXz/cHJ5/2xudf9wcnn/amxz/3Bzff9zdn//dXd9/25wd/9ucHf/ -cHJ5/2psc/9kZ3H/bG51/2xvef9nanT/cHN9/2dqdP9sb3n/Z2p0/2xudf9qbHP/Z2p0/25xe/9qbXf/ -bnF7/2dqcf9qbXf/am13/2Zpc/9qbHP/ZGdx/2xvef9qbXf/c3Z//3N1fP9qbXf/am13/3N1fP9qbXf/ -bnF7/2ptd/9sbnX/bnF7/3Bzff9ucXv/am11/2xudf9xc3j/a211/3Fzev9tb3T/cHN9/2Zpc/9ucHf/ -dnh8/3Byef9rbXT/dHZ7/3Bzff90d4D/cHN9/2xvef9zdn//bnB3/25wd/9tcHr/cnV8/29xef9wcnr/ -cnR6/21vdv9wc3v/c3V7/3V3ff9wc33/bXB6/3N2fv90dnr/bnB1/3V3ff9tb3b/cXN6/3Byef9vcXn/ -cHJ5/3Byef9xc33/cHN8/3d5f/93eoL/cnV+/3BzfP9ucXr/bXB5/2tueP9tcHn/dnh+/3J0ff9vcnn/ -dHZ+/21wef9vcXr/b3J8/21vdv9ydX7/bG95/25wd/9tcHn/bW92/2dqdP9nanT/bnB3/25wd/9ucXv/ -dXd9/2ptdv9rbnf/bnF5/2xvef9iZW7/d3qD/2ptd/9qbXf/am13/2ptd/9qbXf/bG95/2ptd/9wcnn/ -bG95/2xvef9ucHf/Zmhu/2xvef9iZW7/ZGdx/2psc/9nanH/Zmlz/2Rncf9qbHP/bG95/2psc/9qbHP/ -Zmlz/2ptd/9qbHP/amxz/3Byef9qbHP/Z2p0/2psc/9iZW7/bG95/3Bzff9qbHP/amxz/2ptd/9sbnX/ -amxz/25xe/9ucHf/dXd9/29xdf9wcnn/Zmlz/3V3ff9sbnX/bnB3/3N1fP91d33/bnB3/3Byef9vcXX/ -bnB3/2psc/9sb3n/bnB3/3V4gf9qbHP/bG51/29xdf9sb3n/cHJ5/3Byef+Agob/bG51/2xudf9zdXz/ -bW9z/3Z4fP9zdXz/bnB3/25wd/94eX3/dXd9/3Byef9zdXz/bnB3/3V3ff9ucHf/dXd9/3Z4fP9vcXX/ -bG95/3V4gf93eoP/bnF7/2xvef91eIH/eXyG/25xe/93eoP/d3qD/3N1fP97fof/dXiB/3V4gf9ucXv/ -c3Z//3d6g/9zdn//cHN9/3N2f/9ucXv/bnF7/25xe/9sb3n/cHN9/25wd/94eX3/eHl9/3V3ff9/gYf/ -bG95/2xvef9wc33/bnF7/25wd/9sbnX/bnF7/25xe/9zdXz/cHJ5/25wd/9wcnn/bnB3/3t+h/9sb3n/ -bnF7/3V4gf9sb3n/bnB3/3d5f/9ucHf/dXiB/3N2f/9ucXv/cHN9/2ptd/9ucXv/c3V8/3V3ff9ucHf/ -cHJ5/25wd/9ucHf/bG51/2ptd/9ucXv/cHJ5/3V3ff9sb3n/bG95/2dqdP9qbHP/Zmhu/2Rncf9nanT/ -amxz/2Zpc/9cX2j/ZGZs/2Zobv9gY2z/amxz/2BjbP9nanT/am13/3V3ff9zdXz/am13/2xudf9sb3n/ -bG51/2xvef9sbnX/am13/3N1fP9zdXz/c3V8/3Byef94eoD/eHuC/3N1fP93eX7/cnR5/3R2ff9sbnX/ -dXd9/3d6g/9zdXz/bnB2/3N1ff91d33/dXd9/3N1fP9sbnX/cHJ5/21wev9wc33/b3J7/3R3fv9ucXr/ -b3J3/3N1ef9rbnf/bnF7/3J0fP9ydX7/bnF6/2tueP9wc3z/b3F6/2lsdP9wcnn/aWx2/21veP9rbnj/ -bG95/21veP9pa3T/amxz/25wdv9ucHf/b3F2/2hqc/9tb3b/bG92/29xef9nanT/bnB3/3J1ff9vcXr/ -b3F4/3J0fP9ydHv/c3V7/3N1fP9tb3T/dHZ8/2ttdv9tb3X/a253/2xudf9laHL/ZGdx/2xudf9qbXf/ -bG95/3V3ff9qbHP/a213/2xudP9ucXv/ZGdx/3t9g/9ucXv/Z2p0/2xudf9qbHP/bnF7/2ptd/9ucXv/ -d3l//3N1fP91d33/dnh8/2xudf9wcnn/Zmlz/2dqdP9sbnX/bnB3/3Byef9vcXX/cHJ5/3Z4fP9vcXX/ -bnB3/2xudf9ucHf/am13/2ptd/9zdXz/bG51/2ptd/9qbXf/Z2p0/3Byef94eX3/b3F1/2xudf9sbnX/ -bW9z/2xudf9wcnn/bnF7/3V3ff9sb3n/cHJ5/2psc/93eX//bW9z/25wd/9wcnn/dXd9/25wd/9wc33/ -bnF7/25xe/9qbXf/c3V8/3N2f/95fIb/bG95/3Bzff9zdXz/bnF7/3N2f/9zdn//gYSN/3N1fP9ucHf/ -c3Z//25wd/91eIH/cHN9/25xe/9ucHf/d3l//3d6g/93eoP/eXuB/3Byef9zdn//c3V8/3l7gf95e4H/ -c3Z//3Bzff95e4H/eXuB/25wd/9ucXv/d3l//3t+h/9zdXz/e32D/3N2f/9sb3n/dnh8/25wd/9zdXz/ -Zmhu/2xudf9wcnn/cHJ5/25wd/9wcnn/bG51/2xudf9qbXf/bG51/3Byef9ucHf/dXd9/3V3ff9zdXz/ -f4GH/29xdf9zdXz/cHJ5/25wd/9vcXX/bnB3/3Bzff9wc33/c3Z//3N2f/9ucXv/c3Z//3N2f/9+gYr/ -c3Z//3N2f/93eoP/d3l//3V3ff9/gYf/dXd9/36Ahv99foH/dXiB/36Ahv9ucXv/d3qD/3l7gf95e4H/ -dXiB/3d6g/9zdn//dXiB/25xe/9wc33/dXiB/3V4gf9zdn//bG95/3N1fP9ucHf/bnF7/2xvef9ucHf/ -cHJ5/2xudf9wcnn/Z2px/25wd/9tb3P/Z2p0/25wd/9nanT/cHN9/3N2f/91eIH/d3l//25xe/9sb3n/ -c3Z//25xe/91d33/bG51/29xdf91d33/dXd9/3N1fP9oa3T/cXR8/3N1ev9tcHn/b3J8/29xd/9zdXz/ -am13/3V3ff91d33/cHJ5/2xudv9ydHv/cXN6/3J0e/9wcnn/am13/25xe/9rbXP/bW92/21veP9vcnr/ -bXB6/21weP9ucHX/bG93/3Fze/9zdn7/dnmA/3N2f/9xdH7/d3l//3FzfP9tb3b/c3V6/25wef9xc3j/ -b3J3/25xef9zdn3/bG94/29xef91d3z/cXN4/3Bydv9qbXb/bXB6/21vd/9ydHv/Z2p0/2ttdP9ucHb/ -bG51/2hrc/9qbXb/a253/3J1ff9wc33/a210/3R2ff9nanT/aGty/2psc/9sbnX/ZGdx/2Zpc/9sbnX/ -Z2p0/2xvef9wc33/Zmlz/2xvef9qbXf/bnF7/2Jlbv93eoP/bnF7/2Zpc/9nanH/amxz/3Bzff9sbnX/ -bnF7/3V3ff9ucXv/bG95/3Byef9qbHP/am13/2Zpc/9kZ3H/Z2px/2dqcf9qbHP/bG51/2dqdP9ucXv/ -Z2px/2dqcf9maXP/Z2p0/2psc/9nanT/c3V8/2dqdP9qbXf/am13/2Zpc/9qbHP/am13/2dqcf9nanT/ -Z2p0/2Zobv9maXP/Z2p0/2ptd/9wc33/am13/2xudf9iZW7/c3V8/2Zpc/9ucXv/bnF7/3Bzff9sbnX/ -cHJ5/2xvef9qbXf/am13/2xudf9sbnX/d3l//2dqdP9sbnX/bG51/2dqdP9qbXf/am13/3t9g/9kZ3H/ -Zmlz/3Byef9qbHP/c3Z//2xvef9ucHf/bG51/3Z4fP9zdXz/dXd9/3V3ff9vcXX/cHJ5/2xvef9zdn// -c3Z//2xvef9qbXf/dXiB/3d5f/9ucHf/cHJ5/3l7gf91eIH/amxz/2xvef9sb3n/amxz/3Bzff9qbHP/ -bG95/2BjbP9sbnX/cHJ5/2xudf9ucHf/cHJ5/2ptd/9qbHP/am13/2ptd/9ucHf/bnB3/3N1fP9wc33/ -cHN9/4GDiv9ucHf/c3Z//25xe/9vcXX/b3F1/2ptd/9wcnn/cHJ5/3V3ff91d33/b3F1/2xudf9qbXf/ -d3qD/2ptd/9sb3n/bnF7/21vc/9sbnX/bnF7/2psc/9sb3n/bnF7/2xudf9wc33/XWBq/2xvef9ucXv/ -bnF7/2Zpc/9qbXf/bG51/2xvef9kZ3H/amxz/2ptd/9sb3n/bnF7/25wd/91d33/bnB3/25xe/9wc33/ -bnB3/3Bzff9zdn//d3qD/2xvef95fIb/dXd9/25xe/9zdn//cHN9/3l8hv93eoP/f4KM/3+Bh/97fYP/ -dXiB/3l8hv93eoP/eXyG/3N2f/9wcnn/dXiB/3l7gf9wc33/bnB3/3R2fv93eYH/c3V+/3R2fv9vcnn/ -cHN9/2ptd/91eIH/d3qD/3V4gf9wcnn/b3J8/29yfP9wcnn/cHJ5/21vc/9zdXz/b3F1/2xvef9tb3n/ -cHN7/3J0ff9wc3z/Z2p0/29xef9zdn//bnF7/3d4ff9zdn//cHJ5/3Z4fv9xc3f/am10/2xvef9ucHf/ -a254/21wev9wcnb/dXd9/25xev9vcnz/dnh//3Fzev9zdX3/Z2p0/25xe/9sb3n/dnh+/2hrdP9ucHf/ -bXB5/25xe/9sb3n/cHN9/3N2f/94e4X/c3Z//29xdf91d33/c3V8/2xudf9qbXf/bG95/2Zpc/9maXP/ -bG51/25wd/9wcnn/dXd9/2psc/9ucHf/bG95/3V3ff9maXP/f4GH/3V4gf9wcnn/cHN9/3Bzff93eX// -c3Z//3V4gf97fof/eXuB/3t9g/97fYP/d3qD/3l8hv9zdn//cHN9/3N1fP9zdXz/bnF7/25xe/9ucXv/ -dnh8/25wd/9wcnn/bG95/3N1fP9sbnX/Z2p0/3N1fP9kZ3H/Z2p0/2psc/9kZ3H/am13/2xvef9sbnX/ -bnF7/3Bzff9sbnX/Z2p0/2ptd/9ucXv/c3V8/25wd/9qbXf/ZGdx/3N1fP9nanT/bG95/25xe/9wc33/ -bG95/25xe/9qbXf/bnF7/2ptd/9ucHf/b3F1/3d5f/9maG7/b3F1/2xudf9nanT/bnB3/2xvef9/gYf/ -bG95/25xe/93eoP/cHJ5/3t+h/9wc33/cHN9/25wd/91eIH/dXd9/3N2f/9wc33/cHJ5/3V4gf9zdn// -d3l//3V3ff9vcXX/bG51/3V3ff9zdXz/bG51/2psc/9wc33/foGK/3N1fP93eoP/c3Z//25wd/91d33/ -bnB3/25wd/9kZ3H/bnB3/3N2f/9sb3n/bnB3/3Byef9ucHf/bG95/25wd/9sb3n/bnB3/25wd/9sb3n/ -cHN9/2xvef9/gYf/cHJ5/3Byef9ucHf/bnB3/3Byef9sb3n/dXiB/3N2f/93eoP/eXuB/3Bzff91eIH/ -c3Z//3+Bh/9zdn//d3qD/31+gf9zdn//c3Z//3l8hv9zdn//e32D/3V4gf9zdXz/eXuB/2Zpc/93eX// -c3Z//3Z4fP9ucHf/bnB3/25wd/9wcnn/am13/25wd/9wcnn/bG51/25xe/9qbXf/bnF7/2xudf9qbXf/ -amxz/2Zpc/9sb3n/am13/25xe/9maXP/bG95/2xudf9iZW7/bG51/2dqdP9sb3n/cHJ5/3d5f/93eX// -am13/2ptd/9qbXf/am13/25xe/9sbnX/Z2p0/25xe/9wc33/cHN9/25vdf9qbHX/bG51/2ptdv9rbnj/ -Z2pz/2dqdP9kZ3H/am13/3N1fP9sb3n/Zmlz/2psc/9maXP/am13/2Zpc/9qbHP/am13/2psc/9sbnX/ -Z2p0/21vdv9tcHr/bG95/15ha/9nanH/a210/2ttdP9wcnn/dHZ9/2ptd/9sb3n/aGty/2dqdP9oa3T/ -amxz/2ptd/9wcnn/bW9z/3Z4fP9qbXf/bnB3/3Z4fP9sbnX/am13/2Rncf9qbXf/am13/3d5f/9nanH/ -bG51/2xudf9ucHf/bG95/25wd/9ucHf/dXiB/25xe/9sbnX/dXd9/25xe/9tb3P/cHJ5/25wd/9nanH/ -amxz/29xdf9ucHf/cHJ5/3N1fP9qbXf/am13/2ptd/9sb3n/YmVu/36Ahv9sb3n/Z2p0/2dqdP9qbXf/ -cHN9/2ptd/9sb3n/dXd9/3V3ff9wcnn/c3V8/3Byef9ucXv/bG95/2ptd/9ucHf/bG95/25xe/9sb3n/ -bG95/3V3ff9ucHf/bG95/25wd/93eX//bnB3/25wd/97fYP/amxz/25wd/9ucHf/bG51/25wd/9sb3n/ -bW9z/2xvef9ucXv/Z2p0/2Jlbv9nanH/am13/3Bzff9qbXf/am13/2Rncf9wc33/amxz/2xudf9ucHf/ -c3V8/2xvef9ucXv/am13/3Bzff9nanT/bG51/21vc/92eHz/Zmhu/2xudf9tb3P/bG51/29xdf9zdXz/ -f4KM/25xe/9nanT/d3qD/2xvef93eX//cHJ5/2xvef9ucHf/dXiB/3h5ff9zdn//c3Z//3Byef9zdn// -dXiB/3t9g/95fIb/cHJ5/3Bzff97fYP/fn+D/3Z4fP9wc33/e32D/3t+h/9wc33/dXiB/3Bzff9ucXv/ -dXiB/25wd/9wc33/Z2p0/25wd/9wc33/bnB3/2xvef9sb3n/bnB3/2ptd/9qbXf/bnF7/25wd/9sbnX/ -bG51/3N1fP9wcnn/f4GH/3Byef9wcnn/bnB3/2ptd/9qbXf/Zmlz/2xvef9ucXv/am13/3N1fP9qbHP/ -Z2p0/2dqcf91eIH/am13/2ptd/9wcnn/bW9z/21vc/9wcnn/bW9z/3Byef9sbnX/bG51/3N1fP9iZW7/ -c3V8/25xe/9zdXz/bG51/2xvef9sbnX/cHJ5/2xudf9ucHf/c3V8/25wd/9wcnn/cHJ5/3N1fP9tb3P/ -bnB3/2ptd/9qbXf/c3V8/25xe/9ucXv/am13/2xvef9ucHf/ZGZs/25wd/9sbnX/cHJ5/3V3ff97fYP/ -eHl9/25wd/9ucHf/bnB3/3Byef9wc33/bW9z/2psc/9zdXz/dXd9/3N1fP9ydHr/Zmlz/2ptd/9oa3X/ -b3J8/2xvef9ucHf/bnB3/3V3ff93eX//dXd9/25wd/9ucHf/bnF7/3N2f/9ucXv/bnF7/3N2f/9ucHf/ -bG95/2xvef9vcXX/dXd9/3Byef9kZmz/bW9z/25wd/9ucXv/d3l//3d6g/9wc33/dXiB/3N1fP9wcnn/ -bG95/3Byef9sbnX/cHJ5/25wd/9zdn//bnB3/25xe/95e4H/bG95/25wd/9qbXf/b3F1/29xdf94eX3/ -bnB3/25wd/9ucHf/b3F1/3Byef9sb3n/cHJ5/3d5f/9zdXz/bG51/3N1fP9ucXv/bG51/3N1fP9sbnX/ -Z2p0/2dqdP9sb3n/bnB3/25xe/9wc33/amxz/29xdf9wcnn/c3V8/2Jlbv9/gYf/bnB3/21vc/9sbnX/ -bG95/3d5f/9wc33/dXiB/3l7gf93eX//c3Z//3V4gf9ucXv/bnF7/25wd/9maXP/bnB3/25xe/9ucXv/ -cHJ5/2xvef91d33/b3F1/2xudf9ucHf/dnh8/25wd/9sbnX/dXiB/2psc/9sb3n/bG51/2dqdP9qbXf/ -am13/2psc/9sb3n/bnF7/2ptd/9qbXf/bnF7/25xe/91d33/am13/2ptd/9kZ3H/c3V8/2ptd/9qbHP/ -am13/25xe/9qbXf/am13/2psc/9sb3n/ZGdx/2xudf9nanT/cHN9/2Rncf9nanT/bG51/2dqdP9qbXf/ -bnF7/36Ahv9qbXf/Z2p0/3N2f/9sbnX/dXd9/2xvef9qbXf/bW9z/3d5f/93eX//dXd9/3Byef9ucHf/ -cHN9/3N2f/93eX//dXd9/2xvef9qbXf/dXd9/3V3ff9sb3n/b3F1/3Z4fP93eX//bnB3/3N2f/9ucXv/ -bnB3/3Bzff9sb3n/bnF7/2Zpc/9sb3n/cHN9/25wd/9wc33/bnB3/2xudf9ucHf/bnB3/3V3ff9wcnn/ -bW9z/25wd/9zdXz/c3V8/3+Bh/91d33/cHJ5/3N2f/9vcXX/bW9z/2psc/9wcnn/c3V8/3Byef92eHz/ -bnB3/2ptd/9sbnX/c3Z//2ptd/9sb3n/bnF7/2ptd/9qbHP/c3V8/21vc/9zdXz/bnB3/3Bzff91d33/ -Zmhu/3Bzff9wc33/eHl9/25wd/9wcnn/b3F1/3Byef9sbnX/bnB3/3Byef9ucHf/bnF7/25xe/95e4H/ -c3V8/3Bzff9wc33/Z2p0/3Bzff9zdXz/cHJ5/2xudf9wcnn/am13/2Jlbv9qbXf/Z2p0/2xvef9wc33/ -c3Z//3N1fP9sbnX/bG95/21vc/9ucXv/bnF7/2dqdP9kZ3H/bnF7/3Bzff9ucXv/cnR7/2Rncf9qbHP/ -am13/3Bzff9sb3n/bnB3/2psc/9zdXz/dXd9/3N1fP9qbXf/bG51/25wd/92eHz/cHJ5/3Byef9zdXz/ -b3F1/25wd/9nanT/bW9z/25wd/9sb3n/ZGdx/2ptd/9qbXf/am13/25xe/93eX//cHJ5/3N1fP9wcnn/ -bW9z/21vc/9ucHf/bG51/2Zpc/9nanH/bG95/2dqcf9maXP/bnF7/2psc/9maXP/am13/2xudf9sbnX/ -c3V8/2psc/9nanT/a253/2xudf9wc33/a254/3Byef91eID/bG95/2xvef91d33/cHJ5/2ptd/9ucXv/ -bG95/2hrdf9qbXf/bG51/2xudf9qbXf/Z2p0/2Rncf9nanH/a254/2xvef9gY2z/gIKG/2xudf9tb3P/ -bG51/29xdf91d33/cHJ5/3V3ff91d33/c3Z//3Bzff91d33/cHN9/3Bzff9wcnn/am13/25wd/9zdn// -cHN9/3V4gf93eoP/d3l//2ptd/9ucHf/bnB3/3Z4fP9qbHP/bW9z/3Z4fP9sbnX/bnB3/3Byef9qbHP/ -bnB3/2ptd/9sbnX/bnB3/3N1fP9ucHf/bG51/3N1fP9wcnn/dnh8/3Byef9ucHf/bG51/3N1fP9ucHf/ -bnB3/25xe/9zdn//c3Z//3Bzff9wc33/d3qD/25xe/91eIH/cHN9/3l8hv9zdXz/dXd9/3l7gf92eHz/ -eXuB/3t9g/+FiJH/d3qD/3Bzff9/gYf/dXiB/3t+h/91eIH/d3qD/3V4gf9+gYr/e32D/3d6g/9zdn// -c3V8/3N2f/9zdn//dnh8/3V4gf9sb3n/bG95/3Z4fP91d33/bG51/21vc/9wcnn/d3l//25xe/91d33/ -cHJ5/25wd/9ucXv/bnB3/3Byef9nanH/cHN9/3V4gf9wcnn/bnF7/25xe/9ucHf/cHJ5/25xe/91eIH/ -cHN9/3Byef9ucXv/c3Z//3N2f/9+gIb/dnh8/3Bzff9wc33/b3F1/25wd/9qbXf/c3V8/3V3ff9wcnn/ -eHl9/25wd/9ucHf/bW9z/3V4gf9ucXv/cHJ5/3N2f/9wcnn/c3V8/3V4gf9wcnn/c3Z//25xe/9wc33/ -dnh8/2ZobP9zdXz/c3V8/3Z4fP9vcXX/c3V8/2xudf9ucHf/bW9z/2xudf9wcnn/bG51/2xvef9qbXf/ -c3V8/2Zobv9sb3n/bG51/2Zpc/9qbXf/am13/2ptd/9nanT/am13/2xvef9kZ3H/bG95/2dqdP9ucXv/ -bnF7/3V3ff94eX3/bG95/3N2f/9sb3n/cHN9/3Bzff9ucHf/Z2p0/3V3ff91d33/dXd9/3h5ff9sbnX/ -bnB3/2xvef91d33/c3Z//2xvef9qbXf/c3Z//3l7gf91eIH/bnB3/3Byef9wc33/d3l//3Byef9wcnn/ -cHJ5/21vc/9sbnX/amxz/2xudf9sbnX/bG51/2Zobv9wcnn/bG51/25xe/9ucXv/c3V8/3J0e/9sb3n/ -bnB3/2xudf9ucHT/bG51/2Zpc/9vcXj/bG51/21vdv9tb3b/bW93/3R2ff9rbnf/aGt1/2dqdP9sbnX/ -am13/3Fzev9qbHP/a253/2xveP9qbHP/bG95/2xveP9wcnj/dHZ7/21vdf9ydXz/dXd9/3J0ff9sb3n/ -b3J8/3N1fP9vcXj/b3F4/21vc/9qbXf/bG95/3Byef9ucHf/b3F1/29xeP9zdXz/Z2px/4GDiv9sb3n/ -bnF7/3Byef9wcnn/dXiB/3N2f/93eoP/e32D/3V4gf9wc33/c3Z//3V3ff9ucHf/b3F1/2psc/9ucHf/ -bnF7/25wd/9zdn//c3V8/3Z4fP9qbHP/bG51/21vc/92eHz/bG51/29xdf92eHz/amxz/2xudf9wc33/ -Zmlz/3Byef9qbXf/bnB3/25wd/92eHz/b3F1/25wd/9zdXz/c3V8/3V3ff9wc33/am13/2dqcf9wcnn/ -bW9z/29xdf9sbnX/cHJ5/2xvef9wcnn/bG51/2xvef9maXP/cHJ5/25wd/94eX3/Zmhu/2xudf9sb3n/ -Z2p0/2ptd/9sb3n/foCG/25xe/9sbnX/eXuB/2xvef93eX//bG51/25wd/9tb3P/dXd9/3N1fP91d33/ -bG51/2psc/9zdXz/c3V8/3N1fP9sb3n/amxz/2ptd/92eHz/c3V8/29xdf9ucHf/cHN9/3d6g/9ucXv/ -d3l//3Bzff9zdXz/cHN9/3Byef9wc33/am13/3Bzff95e4H/dXd9/3V4gf9wc33/cHN9/3V3ff91eIH/ -eXuB/3N1fP9zdXz/cHN9/3d6g/95e4H/g4WM/3l8hv91eIH/d3qD/3Bzff9zdn//c3V8/3N2f/91eIH/ -bnB3/3d5f/9sb3n/bnB3/25wd/93eX//bG95/25wd/9wc33/bnB3/25wd/9wc33/bnB3/3Bzff9ucXv/ -dXiB/3V4gf9nanH/cHN9/3N2f/95e4H/cHJ5/3N2f/9wcnn/cHN9/3N1fP9wcnn/dXiB/25xe/93eoP/ -bnF7/3V4gf9ucHf/c3Z//3Bzff9qbXf/c3V8/3Bzff91eIH/bG95/2xvef9zdn//bG95/2xvef9qbXf/ -cHN9/3Byef91eIH/d3l//2xvef9zdn//bnB3/3N2f/9wc33/cHJ5/2ptd/9zdXz/cHJ5/3V3ff92eHz/ -Z2p0/2ptd/9qbXf/cHN9/2ptd/9sbnX/amxz/3Byef91d33/c3V8/2dqdP9tb3P/bnF7/3V4gf9wc33/ -cHN9/3d6g/9zdXz/bnF7/25xe/9xc3r/dXiA/3N1fP9tcHr/c3Z//3Z4fv94e4T/enyC/31/hv94eoD/ -dHeA/3Bzff9ucXv/cHN6/29xef9tcHn/cnR7/25wd/9vcXX/aWx1/2ttdv9wcnn/b3F3/21vdv9sbnb/ -bW92/21wdv9xc3n/bG50/21vdP9wcnj/bW91/25xef9xdHz/cXR9/3Fzev9vcXj/b3F4/3Z4gP9wc3v/ -bG95/29yfP9ydHz/cXN7/21wev9ucHf/bnF7/3Byef9wc33/bnB3/25wd/9xc3r/cHJ5/2Zobv+Agob/ -bG51/2xudf9sbnX/bG51/3N1fP9wcnn/eHl9/3V3ff91d33/c3V8/3Bzff9zdXz/amxz/2psc/9nanT/ -Z2px/2xudf9sbnX/cHN9/2xudf9wc33/Z2p0/2psc/9sbnX/dXd9/2ptd/9qbHP/c3V8/2ptd/9qbXf/ -cHN9/2dqdP9ucXv/bnB3/3N1fP9ucHf/dXd9/25wd/9sb3n/c3Z//3N2f/93eX//dXiB/25xe/9sb3n/ -c3Z//25wd/9wcnn/c3V8/3N2f/9ucXv/c3Z//2xvef9zdXz/Z2px/3Byef9sbnX/cHN9/2Rncf9qbHP/ -bnF7/2dqcf9qbXf/am13/3V4gf9maXP/ZGdx/3N1fP9nanT/cHJ5/2psc/9nanT/Z2px/3V3ff9zdXz/ -bnF7/2ptd/9qbXf/cHN9/3N1fP9zdXz/c3V8/25wd/9ucHf/d3qD/3N2f/9ucHf/bG95/3Bzff95e4H/ -bG95/3V3ff9sb3n/bnB3/25xe/9sb3n/bnB3/2dqcf9vcXX/c3V8/2ptd/9ucHf/bG51/2ptd/9nanT/ -bG51/3N1fP9sbnX/bW9z/2xudf9zdXz/dXd9/31+gf9zdXz/bG95/2xvef9sbnX/bG51/2ptd/9ucHf/ -c3V8/2xvef91d33/bnB3/3Byef9sb3n/dXiB/2xvef9sb3n/bnF7/25xe/9ucHf/cHJ5/25wd/9ucXv/ -bnF7/3V3ff93eoP/ZGdx/3N2f/93eoP/d3qD/25wd/9zdn//bnF7/25xe/9wcnn/bnB3/3Bzff9sbnX/ -c3V8/25wd/91d33/am13/3Bzff9sbnX/amxz/25wd/9sb3n/bnF7/2ptd/9qbXf/dXd9/2xudf9sbnX/ -Zmlz/2xvef9sb3n/dXd9/3N1fP9qbXf/bnF7/21vc/9zdXz/cHJ5/25xe/9sb3n/c3Z//3Bzff93eX// -eHqA/2hrdf9ucHf/a254/3N2f/9ucHf/bnB3/25wd/9wcnn/eXuB/3V3ff9sbnX/bG51/21vdv91d3z/ -am13/2psc/9ucXv/amxz/2dqcf9nanT/Z2pz/2dqc/9maHL/YmRt/2Zobv9pbHb/bG53/25wef9wcnr/ -cHJ5/2tueP9tb3f/bG51/3Fzev9sb3f/bG95/21wev9vcnr/bG53/2xudf9rbnX/b3J6/25wef9ucXn/ -am13/2tueP9ydHv/cHJ6/25wd/9ucXn/dHZ9/29xdv9wcnr/dHZ9/3BzeP9ucHf/bnB4/29xef93eYD/ -bnF2/25wd/9xc3v/cXN4/3N1e/9xc3r/cXN6/3N2f/9wc33/d3qD/3Byef9wcnn/cXR9/3Bzff9nanT/ -f4KM/3Bzff9ucHf/b3F1/21vc/9zdXz/bnB3/3V3ff93eX//cHN9/25xe/9wc33/dXd9/29xdf9ucHf/ -bnB3/25wd/9vcXX/cHN9/3N2f/9ucXv/dXiB/2xvef9ucXv/bnF7/3l7gf91d33/d3l//35/g/94eX3/ -eXuB/36Ahv96e3//f4GH/3l8hv9+gYr/eXyG/4CChv97fYP/dXd9/3l8hv99foH/fn+D/35/g/93eX// -cHN9/3t9g/9wc33/c3V8/3Byef9wc33/b3F1/3Z4fP9qbXf/bG95/2Jlbv9qbXf/am13/2ptd/9gY2z/ -Zmlz/2xvef9kZ3H/Zmlz/2xvef93eoP/am13/2Rncf9wc33/ZGdx/2ptd/9maG7/Z2px/2Zobv9zdXz/ -d3qD/3Bzff9sb3n/amxz/3Byef9zdXz/dnh8/3N1fP9sbnX/bG51/3h5ff9wcnn/bnB3/25wd/9zdXz/ -d3l//25wd/91d33/bnB3/21vc/9wcnn/bnB3/2xvef9maXP/bnB3/3Byef9sbnX/bnB3/25wd/9wcnn/ -amxz/25wd/92eHz/bnB3/29xdf9wcnn/cHJ5/3Z4fP9+gIb/c3V8/3Byef9sb3n/bG51/2ptd/9maXP/ -am13/2xvef9ucXv/cHJ5/2dqcf9nanT/Z2px/3Byef9kZ3H/YGNs/2Zobv9kZ3H/Zmhu/2Zpc/9maG7/ -Zmlz/2Zobv9sb3n/c3V8/1lcZf9maXP/Zmlz/25wd/9kZ3H/am13/2dqcf9nanH/YmVu/2Jlbv9nanT/ -Zmhu/2Zpc/9kZ3H/cHJ5/2Zpc/9qbXf/am13/2Rncf9maXP/Z2p0/2xvef9maXP/bG51/3Bzff9maXP/ -bW9z/2ptd/9sb3n/am13/3Bzff9ucXv/amxz/25xe/9sbnX/cHJ5/2xvef9qbXf/ZGdx/2ptd/9qbXf/ -c3V8/3F0e/9laHH/bG51/2dqc/9tcHr/amxz/2ptd/9nanT/cHJ5/3l7gf91d33/amxz/2xudf9vcXj/ -d3h8/3Byef9vcXX/dXd9/21vc/9sbnX/bG95/29yfP9wc3v/bW92/2ptd/9sb3j/c3V7/3V4f/90dnr/ -c3V8/3Byev9xc3v/c3Z9/29xeP91d4D/bnB4/21wev91d37/dnh//3Fze/9tb3b/bW93/3J0e/9zdn3/ -cnV+/25xe/9vcnn/cnV//25xe/9wcnr/cHN8/3Z4gf9wcnn/cHJ6/3d6hP9zdXz/cXN9/3Bzff9zdXz/ -fYCJ/25wd/9sb3n/bG95/29xeP90dnv/b3J7/25wd/9ucHf/bW92/3N1fP9ucHf/bnB3/29yef9wcnn/ -Z2px/35/g/9ucHf/bG51/21vc/9qbXf/bnF7/2xvef93eX//d3l//3N1fP9ucXv/bnF7/25xe/9nanT/ -amxz/2Zpc/9nanT/ZGdx/2dqdP9nanT/ZGdx/3Byef9kZ3H/bG51/2xudf9sb3n/Zmlz/2psc/9wc33/ -amxz/2xudf9zdXz/amxz/2xvef9qbXf/bnF7/2ptd/9sb3n/am13/2xudf9ucXv/cHN9/3Bzff9wc33/ -am13/2ptd/91d33/bnB3/2xudf9sbnX/bnB3/2xudf92eHz/bG51/25wd/9kZ3H/bG95/3N1fP9sb3n/ -ZGZs/2ptd/9ucXv/bG51/2ptd/9zdXz/fn+D/2xvef9sb3n/foCG/25xe/91eIH/bnF7/25wd/9vcXX/ -dXd9/3d5f/9wc33/c3Z//25wd/9zdn//bnF7/3V3ff9ucXv/bG51/29xdf94eX3/c3Z//25wd/9ucXv/ -c3Z//3l7gf9wcnn/d3l//25xe/9wcnn/cHN9/3N2f/9zdXz/am13/2xvef91d33/bG51/3N1fP9sb3n/ -bG51/2dqcf9sb3n/dXd9/2psc/9qbXf/bG95/2xvef9wcnn/d3qD/3V3ff91d33/am13/3Byef9wcnn/ -Z2p0/2xvef9wc33/c3V8/3V4gf9tb3P/bnB3/21vc/92eHz/bW9z/29xdf9sbnX/bnB3/25wd/9qbXf/ -am13/2ptd/9nanT/c3V8/3d6g/9kZ3H/bG95/2xvef93eoP/Z2p0/25xe/9qbXf/am13/2xudf9sbnX/ -cHJ5/29xdf9wc33/bnF7/3l8hv9sb3n/cHN9/3N2f/9sb3n/bG95/3N2f/9wc33/bG95/3Bzff93eX// -am13/25wd/9vcXX/cHJ5/25wd/9zdXz/c3V8/2xudf9sb3n/bnB3/2xvef9sbnX/amxz/1xfaP9nanH/ -Z2px/3Bzff9ucXv/a253/2xud/9tb3j/cXR7/21vc/9ucHf/amxz/25xe/93eX//c3V8/2hqdP9rbnf/ -bXB5/3R2ev9sbnX/bW9z/25wd/9qbHP/cHJ5/29xef9zdX3/cHJ7/21weP9sb3n/bnB3/3N2f/94eoD/ -b3J7/3N2f/9zdn//eHuF/3l7gf92eH7/fX+F/3R2ff91eH7/enyC/3p8gv94eoH/d3h9/31/hv97fYP/ -e32D/3x9gf94eoD/dnh8/31/hf94eX7/d3l//3d5f/97fYP/cHN9/3V3ff97fof/cHN9/2xvef9wc33/ -cHN9/3t+h/9zdXz/c3Z//3d6g/9wc33/d3mA/3J1f/9ucHb/bXB5/21vdv9ucHf/bnB3/25wd/9vcnv/ -cHJ5/2dqcf9+gIb/bnF7/3N1fP9vcXX/bnF7/3d6g/9wc33/e36H/3l8hv9zdn//cHN9/25xe/91d33/ -bnB3/25xe/9sb3n/bnF7/2xvef9ucXv/cHN9/3Byef93eX//bG51/2xudf9sbnX/bG95/2dqdP9qbHP/ -bnF7/2psc/9nanH/am13/2Zpc/9nanT/Z2px/2ptd/9sbnX/bnF7/2xudf9tb3P/cHJ5/3V3ff91d33/ -dXd9/2xvef9sb3n/dXiB/25wd/9wc33/c3V8/3V4gf9zdn//d3qD/3N2f/95fIb/cHN9/3l8hv97fYP/ -eXuB/2dqdP9zdn//eXyG/3Bzff91eIH/eXuB/3+Bh/9ucXv/bnB3/35/g/9tb3P/dXd9/3Byef9wcnn/ -b3F1/3d5f/93eX//bnF7/3Bzff9sb3n/cHJ5/25xe/93eX//c3Z//3Byef9ucHf/dXd9/3N1fP9sb3n/ -bG95/3N2f/93eX//bnB3/3V3ff9vcXX/bnF7/3Bzff9ucXv/bnB3/2dqdP9ucXv/cHN9/2ptd/91eIH/ -bG95/2xvef9qbHP/bG95/3V3ff9vcXX/bG51/2xvef9qbXf/cHJ5/3l7gf91d33/bnF7/25wd/9ucHf/ -cHJ5/2psc/9sbnX/cHN9/3Bzff9zdn//bG51/25xe/9nanH/cHN9/2Zpc/9nanH/Z2px/2xudf9sb3n/ -am13/2xudf9ucHf/bG51/3V3ff99foH/Zmhu/3N1fP9wcnn/eXuB/2ptd/91d33/bnF7/2ptd/9qbXf/ -am13/25xe/9ucHf/c3V8/3V3ff95e4H/bnB3/3V3ff92eHz/amxz/2xudf92eHz/bnF7/2xudf9ucHf/ -c3V8/2dqdP9qbXf/bG51/3N1fP9ucHf/c3V8/3V3ff9ucHf/cHJ5/3Byef9zdXz/bW9z/21vc/9kZmz/ -bG51/2xvef91d33/bG50/3Byef9vcXb/cXN5/3Fzef9qbXf/bG95/2Zpc/9sb3n/d3l//3N1fP9rbXT/ -bXB4/29yev9zdXz/bnB3/25wd/9zdn//am13/25xe/9ucHr/cHN7/2xudv9oa3X/a254/2xudf9wc33/ -dXd9/2xudf9ucHf/bnB3/3Byef91d33/bnB3/3d5f/9ucHf/bG95/3N2f/92eHz/cHJ5/25wd/9wcnn/ -cHJ5/3Byef9wcnn/bnB3/25wd/9sb3n/bnB3/25wd/91eIH/c3Z//3Byef9ucHf/d3l//29xdf9nanH/ -bG51/21vc/93eoP/bG51/2ptd/9ucXv/amxz/3N1fP9qbXb/aWt0/29xeP9sb3j/bG51/2xvef9ucHf/ -bG95/2xvef9nanH/fn+D/25wd/9ucHf/am13/2xudf91d33/bG51/3l7gf91eIH/cHN9/3N2f/9wc33/ -d3l//2xvef9wc33/bnB3/2xvef9sb3n/bnF7/3Bzff9ucXv/d3l//2ptd/9ucHf/bG95/3Byef9vcXX/ -b3F1/3N1fP9vcXX/b3F1/3Bzff9nanT/bG51/2ptd/9ucXv/bG51/2xvef9sb3n/bG51/2xudf9sb3n/ -dXd9/3Bzff9qbXf/am13/3Byef9qbXf/am13/2Zpc/9ucXv/bG95/2xvef9nanT/bnF7/2Rncf9sb3n/ -bnF7/25xe/9gY2z/Z2p0/2xvef9qbXf/am13/3Bzff93eoP/am13/2ptd/97fYP/bG51/2xvef9ucXv/ -bG95/2psc/91d33/dXd9/2ptd/9zdXz/bnB3/3Bzff9ucHf/dnh8/25xe/9wcnn/cHJ5/3d6g/9ucXv/ -cHN9/2xvef9wc33/AA0BAAADAAAAAQEAAAABAQADAAAAAQEAAAABAgADAAAABAAEAKoBAwADAAAAAQAB -AAABBgADAAAAAQACAAABEQAEAAAAAgAEALIBEgADAAAAAQABAAABFQADAAAAAQAEAAABFgADAAAAAQCA -AAABFwAEAAAAAgAEALoBHAADAAAAAQABAAABUgADAAAAAQABAAABUwADAAAABAAEAMIAAAAAAAgACAAI -AAgAAAAIAAIACAACAAAAAgAAAAEAAQABAAE</bytes> - </object> - </object> - </object> - </object> - <object class="NSColor" key="NSColor" id="715287796"> - <int key="NSColorSpace">3</int> - <bytes key="NSWhite">MCAwAA</bytes> - </object> - </object> - <string key="IBUIColorCocoaTouchKeyPath">scrollViewTexturedBackgroundColor</string> - </object> - <float key="IBUIAlpha">0.80000001192092896</float> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <object class="NSMutableArray" key="IBUIItems"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBUITabBarItem" id="49074654"> - <int key="IBUITag">1</int> - <string key="IBUITitle">Ticks</string> - <object class="NSCustomResource" key="IBUIImage"> - <string key="NSClassName">NSImage</string> - <string key="NSResourceName">ticks_tab.png</string> - </object> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <reference key="IBUITabBar" ref="943058069"/> - </object> - <object class="IBUITabBarItem" id="363640538"> - <int key="IBUITag">2</int> - <string key="IBUITitle">Title</string> - <object class="NSCustomResource" key="IBUIImage"> - <string key="NSClassName">NSImage</string> - <string key="NSResourceName">title_tab.png</string> - </object> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <reference key="IBUITabBar" ref="943058069"/> - </object> - <object class="IBUITabBarItem" id="449754452"> - <int key="IBUITag">3</int> - <string key="IBUITitle">Labels</string> - <object class="NSCustomResource" key="IBUIImage"> - <string key="NSClassName">NSImage</string> - <string key="NSResourceName">label_tab.png</string> - </object> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <reference key="IBUITabBar" ref="943058069"/> - </object> - </object> - </object> - </object> - <string key="NSFrameSize">{250, 400}</string> - <reference key="NSSuperview"/> - <reference key="NSNextKeyView"/> - <string key="NSReuseIdentifierKey">_NS:195</string> - <reference key="IBUIBackgroundColor" ref="715287796"/> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - </object> - <object class="IBObjectContainer" key="IBDocument.Objects"> - <object class="NSMutableArray" key="connectionRecords"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">view</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="13398906"/> - </object> - <int key="connectionID">7</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">tabBar</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="943058069"/> - </object> - <int key="connectionID">18</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">delegate</string> - <reference key="source" ref="943058069"/> - <reference key="destination" ref="841351856"/> - </object> - <int key="connectionID">19</int> - </object> - </object> - <object class="IBMutableOrderedSet" key="objectRecords"> - <object class="NSArray" key="orderedObjects"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBObjectRecord"> - <int key="objectID">0</int> - <reference key="object" ref="0"/> - <reference key="children" ref="1000"/> - <nil key="parent"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">-1</int> - <reference key="object" ref="841351856"/> - <reference key="parent" ref="0"/> - <string key="objectName">File's Owner</string> - </object> - <object class="IBObjectRecord"> - <int key="objectID">-2</int> - <reference key="object" ref="606714003"/> - <reference key="parent" ref="0"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">4</int> - <reference key="object" ref="13398906"/> - <object class="NSMutableArray" key="children"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="943058069"/> - </object> - <reference key="parent" ref="0"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">14</int> - <reference key="object" ref="943058069"/> - <object class="NSMutableArray" key="children"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="49074654"/> - <reference ref="449754452"/> - <reference ref="363640538"/> - </object> - <reference key="parent" ref="13398906"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">15</int> - <reference key="object" ref="49074654"/> - <reference key="parent" ref="943058069"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">16</int> - <reference key="object" ref="363640538"/> - <reference key="parent" ref="943058069"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">17</int> - <reference key="object" ref="449754452"/> - <reference key="parent" ref="943058069"/> - </object> - </object> - </object> - <object class="NSMutableDictionary" key="flattenedProperties"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>-1.CustomClassName</string> - <string>-1.IBPluginDependency</string> - <string>-2.CustomClassName</string> - <string>-2.IBPluginDependency</string> - <string>14.IBPluginDependency</string> - <string>15.IBPluginDependency</string> - <string>16.IBPluginDependency</string> - <string>17.IBPluginDependency</string> - <string>4.IBPluginDependency</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>AxisInspector</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>UIResponder</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - </object> - </object> - <object class="NSMutableDictionary" key="unlocalizedProperties"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference key="dict.sortedKeys" ref="0"/> - <reference key="dict.values" ref="0"/> - </object> - <nil key="activeLocalization"/> - <object class="NSMutableDictionary" key="localizations"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference key="dict.sortedKeys" ref="0"/> - <reference key="dict.values" ref="0"/> - </object> - <nil key="sourceID"/> - <int key="maxID">19</int> - </object> - <object class="IBClassDescriber" key="IBDocument.Classes"/> - <int key="IBDocument.localizationMode">0</int> - <string key="IBDocument.TargetRuntimeIdentifier">IBIPadFramework</string> - <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies"> - <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string> - <integer value="3100" key="NS.object.0"/> - </object> - <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> - <int key="IBDocument.defaultPropertyAccessControl">3</int> - <object class="NSMutableDictionary" key="IBDocument.LastKnownImageSizes"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>label_tab.png</string> - <string>ticks_tab.png</string> - <string>title_tab.png</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>{30, 30}</string> - <string>{30, 30}</string> - <string>{30, 30}</string> - </object> - </object> - <string key="IBCocoaTouchPluginVersion">534</string> - </data> -</archive> diff --git a/test/ios/RootBrowser/AxisLabelsInspector.h b/test/ios/RootBrowser/AxisLabelsInspector.h deleted file mode 100644 index 61204a78c481b..0000000000000 --- a/test/ios/RootBrowser/AxisLabelsInspector.h +++ /dev/null @@ -1,33 +0,0 @@ -#import "ObjectInspectorComponent.h" - -@class ROOTObjectController; - - -class TObject; -class TAxis; - -@interface AxisLabelsInspector : UIViewController <ObjectInspectorComponent> { -@private - __weak IBOutlet UIButton *plusSize; - __weak IBOutlet UIButton *minusSize; - __weak IBOutlet UILabel *sizeLabel; - - __weak IBOutlet UIButton *plusOffset; - __weak IBOutlet UIButton *minusOffset; - __weak IBOutlet UILabel *offsetLabel; - - __weak IBOutlet UISwitch *noExp; -} - -+ (CGRect) inspectorFrame; - -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)o; - -- (IBAction) showLabelFontInspector; - -- (IBAction) plusBtn : (UIButton *)sender; -- (IBAction) minusBtn : (UIButton *)sender; -- (IBAction) noExpPressed; - -@end diff --git a/test/ios/RootBrowser/AxisTicksInspector.h b/test/ios/RootBrowser/AxisTicksInspector.h deleted file mode 100644 index ef8c79822696b..0000000000000 --- a/test/ios/RootBrowser/AxisTicksInspector.h +++ /dev/null @@ -1,33 +0,0 @@ -#import <UIKit/UIKit.h> - -#import "ObjectInspectorComponent.h" - -@interface AxisTicksInspector : UIViewController <ObjectInspectorComponent> { -@private - __weak IBOutlet UILabel *tickLengthLabel; - __weak IBOutlet UIButton *plusLengthBtn; - __weak IBOutlet UIButton *minusLengthBtn; - - __weak IBOutlet UIButton *plusPrim; - __weak IBOutlet UIButton *minusPrim; - __weak IBOutlet UILabel *primLabel; - - __weak IBOutlet UIButton *plusSec; - __weak IBOutlet UIButton *minusSec; - __weak IBOutlet UILabel *secLabel; - - __weak IBOutlet UIButton *plusTer; - __weak IBOutlet UIButton *minusTer; - __weak IBOutlet UILabel *terLabel; - - __weak IBOutlet UISegmentedControl *ticksNegPos; -} - -- (void) setROOTObject : (TObject *)object; -- (void) setROOTObjectController : (ROOTObjectController *)c; - -- (IBAction) plusTick : (UIButton *)sender; -- (IBAction) minusTick :(UIButton *)sender; -- (IBAction) ticksNegPosPressed; - -@end diff --git a/test/ios/RootBrowser/AxisTitleInspector.h b/test/ios/RootBrowser/AxisTitleInspector.h deleted file mode 100644 index 1afc7f7874818..0000000000000 --- a/test/ios/RootBrowser/AxisTitleInspector.h +++ /dev/null @@ -1,31 +0,0 @@ -#import <UIKit/UIKit.h> - -#import "ObjectInspectorComponent.h" - -@interface AxisTitleInspector : UIViewController <ObjectInspectorComponent> { -@private - __weak IBOutlet UITextField *titleField; - __weak IBOutlet UISwitch *centered; - __weak IBOutlet UISwitch *rotated; - __weak IBOutlet UILabel *offsetLabel; - __weak IBOutlet UILabel *sizeLabel; - __weak IBOutlet UIButton *plusSizeBtn; - __weak IBOutlet UIButton *minusSizeBtn; -} - -+ (CGRect) inspectorFrame; - -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)o; - -- (IBAction) showTitleFontInspector; -- (IBAction) textFieldDidEndOnExit : (id) sender; -- (IBAction) textFieldEditingDidEnd : (id) sender; -- (IBAction) centerTitle; -- (IBAction) rotateTitle; -- (IBAction) plusOffset; -- (IBAction) minusOffset; -- (IBAction) plusSize; -- (IBAction) minusSize; - -@end diff --git a/test/ios/RootBrowser/EditorPlateView.h b/test/ios/RootBrowser/EditorPlateView.h deleted file mode 100644 index 6d288e9ae714e..0000000000000 --- a/test/ios/RootBrowser/EditorPlateView.h +++ /dev/null @@ -1,13 +0,0 @@ -#import <UIKit/UIKit.h> - -@class EditorView; - -@interface EditorPlateView : UIView - -@property (nonatomic, retain) NSString *editorName; -@property (nonatomic, retain) UIImageView *arrowImageView; - -+ (CGFloat) plateHeight; -- (id) initWithFrame : (CGRect)frame editorName : (NSString *) name topView : (EditorView *) tv; - -@end diff --git a/test/ios/RootBrowser/FileContainerElement.h b/test/ios/RootBrowser/FileContainerElement.h deleted file mode 100644 index 311abb71885c9..0000000000000 --- a/test/ios/RootBrowser/FileContainerElement.h +++ /dev/null @@ -1,6 +0,0 @@ -@interface FileContainerElement : NSObject - -@property (nonatomic, retain) NSString *elementName; -@property (nonatomic, assign) unsigned elementIndex; - -@end diff --git a/test/ios/RootBrowser/FileContentController.h b/test/ios/RootBrowser/FileContentController.h deleted file mode 100644 index 2e65cf761860f..0000000000000 --- a/test/ios/RootBrowser/FileContentController.h +++ /dev/null @@ -1,32 +0,0 @@ -#import <UIKit/UIKit.h> - -#import "SearchController.h" - -@class FileContainerElement; -@class ObjectShortcut; - -namespace ROOT { -namespace iOS { -namespace Browser { - -class FileContainer; - -} -} -} - -@interface FileContentController : UIViewController <UISearchBarDelegate, UIPopoverControllerDelegate, SearchDelegate> { -@private - ROOT::iOS::Browser::FileContainer *fileContainer; - __weak IBOutlet UIScrollView *scrollView; -} - -//@property (nonatomic, assign) id<UITableViewDataSource> * -@property (nonatomic, readonly) ROOT::iOS::Browser::FileContainer *fileContainer; - -- (void) activateForFile : (ROOT::iOS::Browser::FileContainer *)container; -- (void) selectObjectFromFile : (ObjectShortcut *)obj; - -- (void) searchesController : (SearchController *)controller didSelectKey:(FileContainerElement *)key; - -@end diff --git a/test/ios/RootBrowser/FileContentController.xib b/test/ios/RootBrowser/FileContentController.xib deleted file mode 100644 index e618ec66a6edd..0000000000000 --- a/test/ios/RootBrowser/FileContentController.xib +++ /dev/null @@ -1,201 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<archive type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="7.10"> - <data> - <int key="IBDocument.SystemTarget">1280</int> - <string key="IBDocument.SystemVersion">11C74</string> - <string key="IBDocument.InterfaceBuilderVersion">1938</string> - <string key="IBDocument.AppKitVersion">1138.23</string> - <string key="IBDocument.HIToolboxVersion">567.00</string> - <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> - <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string key="NS.object.0">933</string> - </object> - <object class="NSArray" key="IBDocument.IntegratedClassDependencies"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>IBProxyObject</string> - <string>IBUIView</string> - <string>IBUIScrollView</string> - </object> - <object class="NSArray" key="IBDocument.PluginDependencies"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - </object> - <object class="NSMutableDictionary" key="IBDocument.Metadata"> - <string key="NS.key.0">PluginDependencyRecalculationVersion</string> - <integer value="1" key="NS.object.0"/> - </object> - <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBProxyObject" id="841351856"> - <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBProxyObject" id="606714003"> - <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBUIView" id="766721923"> - <reference key="NSNextResponder"/> - <int key="NSvFlags">292</int> - <object class="NSMutableArray" key="NSSubviews"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBUIScrollView" id="479250779"> - <reference key="NSNextResponder" ref="766721923"/> - <int key="NSvFlags">274</int> - <string key="NSFrameSize">{1024, 748}</string> - <reference key="NSSuperview" ref="766721923"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView"/> - <object class="NSColor" key="IBUIBackgroundColor" id="18600012"> - <int key="NSColorSpace">3</int> - <bytes key="NSWhite">MCAwAA</bytes> - </object> - <bool key="IBUIClipsSubviews">YES</bool> - <bool key="IBUIMultipleTouchEnabled">YES</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - </object> - <string key="NSFrame">{{0, 20}, {1024, 748}}</string> - <reference key="NSSuperview"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView"/> - <reference key="IBUIBackgroundColor" ref="18600012"/> - <bool key="IBUIClearsContextBeforeDrawing">NO</bool> - <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"> - <int key="IBUIStatusBarStyle">2</int> - </object> - <object class="IBUISimulatedOrientationMetrics" key="IBUISimulatedOrientationMetrics"> - <int key="IBUIInterfaceOrientation">3</int> - <int key="interfaceOrientation">3</int> - </object> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - </object> - <object class="IBObjectContainer" key="IBDocument.Objects"> - <object class="NSMutableArray" key="connectionRecords"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">view</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="766721923"/> - </object> - <int key="connectionID">7</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">scrollView</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="479250779"/> - </object> - <int key="connectionID">8</int> - </object> - </object> - <object class="IBMutableOrderedSet" key="objectRecords"> - <object class="NSArray" key="orderedObjects"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBObjectRecord"> - <int key="objectID">0</int> - <object class="NSArray" key="object" id="0"> - <bool key="EncodedWithXMLCoder">YES</bool> - </object> - <reference key="children" ref="1000"/> - <nil key="parent"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">-1</int> - <reference key="object" ref="841351856"/> - <reference key="parent" ref="0"/> - <string key="objectName">File's Owner</string> - </object> - <object class="IBObjectRecord"> - <int key="objectID">-2</int> - <reference key="object" ref="606714003"/> - <reference key="parent" ref="0"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">2</int> - <reference key="object" ref="766721923"/> - <object class="NSMutableArray" key="children"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="479250779"/> - </object> - <reference key="parent" ref="0"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">5</int> - <reference key="object" ref="479250779"/> - <reference key="parent" ref="766721923"/> - </object> - </object> - </object> - <object class="NSMutableDictionary" key="flattenedProperties"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>-1.CustomClassName</string> - <string>-1.IBPluginDependency</string> - <string>-2.CustomClassName</string> - <string>-2.IBPluginDependency</string> - <string>2.IBPluginDependency</string> - <string>5.IBPluginDependency</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>FileContentController</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>UIResponder</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - </object> - </object> - <object class="NSMutableDictionary" key="unlocalizedProperties"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference key="dict.sortedKeys" ref="0"/> - <reference key="dict.values" ref="0"/> - </object> - <nil key="activeLocalization"/> - <object class="NSMutableDictionary" key="localizations"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference key="dict.sortedKeys" ref="0"/> - <reference key="dict.values" ref="0"/> - </object> - <nil key="sourceID"/> - <int key="maxID">10</int> - </object> - <object class="IBClassDescriber" key="IBDocument.Classes"> - <object class="NSMutableArray" key="referencedPartialClassDescriptions"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBPartialClassDescription"> - <string key="className">FileContentController</string> - <string key="superclassName">UIViewController</string> - <object class="NSMutableDictionary" key="outlets"> - <string key="NS.key.0">scrollView</string> - <string key="NS.object.0">UIScrollView</string> - </object> - <object class="NSMutableDictionary" key="toOneOutletInfosByName"> - <string key="NS.key.0">scrollView</string> - <object class="IBToOneOutletInfo" key="NS.object.0"> - <string key="name">scrollView</string> - <string key="candidateClassName">UIScrollView</string> - </object> - </object> - <object class="IBClassDescriptionSource" key="sourceIdentifier"> - <string key="majorKey">IBProjectSource</string> - <string key="minorKey">./Classes/FileContentController.h</string> - </object> - </object> - </object> - </object> - <int key="IBDocument.localizationMode">0</int> - <string key="IBDocument.TargetRuntimeIdentifier">IBIPadFramework</string> - <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies"> - <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string> - <integer value="3100" key="NS.object.0"/> - </object> - <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> - <int key="IBDocument.defaultPropertyAccessControl">3</int> - <string key="IBCocoaTouchPluginVersion">933</string> - </data> -</archive> diff --git a/test/ios/RootBrowser/FileShortcut.h b/test/ios/RootBrowser/FileShortcut.h deleted file mode 100644 index 410a6a031a253..0000000000000 --- a/test/ios/RootBrowser/FileShortcut.h +++ /dev/null @@ -1,24 +0,0 @@ -#import <UIKit/UIKit.h> - - -namespace ROOT { -namespace iOS { -namespace Browser { - -class FileContainer; - -} -} -} - -@interface FileShortcut : UIView - -@property (nonatomic, retain) NSString *fileName; - -+ (CGFloat) iconWidth; -+ (CGFloat) iconHeight; - -- (id) initWithFrame : (CGRect)frame controller : (UIViewController *)controller fileContainer : (ROOT::iOS::Browser::FileContainer *)container; -- (ROOT::iOS::Browser::FileContainer *) getFileContainer; - -@end diff --git a/test/ios/RootBrowser/FileShortcut.mm b/test/ios/RootBrowser/FileShortcut.mm deleted file mode 100644 index 22874e2de2214..0000000000000 --- a/test/ios/RootBrowser/FileShortcut.mm +++ /dev/null @@ -1,106 +0,0 @@ -#import <CoreGraphics/CGContext.h> -#import <QuartzCore/QuartzCore.h> - -#import "RootFileController.h" -#import "FileShortcut.h" - -//C++ imports. -#import "FileUtils.h" - -@implementation FileShortcut { - __weak UIViewController *controller; - - UIImage *filePictogram; - - ROOT::iOS::Browser::FileContainer *fileContainer; -} - -@synthesize fileName; - -//____________________________________________________________________________________________________ -+ (CGFloat) iconWidth -{ - return 150.f; -} - -//____________________________________________________________________________________________________ -+ (CGFloat) textHeight -{ - return 50.f; -} - -//____________________________________________________________________________________________________ -+ (CGFloat) iconHeight -{ - return [FileShortcut iconWidth] + [FileShortcut textHeight]; -} - -//____________________________________________________________________________________________________ -- (id) initWithFrame : (CGRect)frame controller : (UIViewController *)viewController fileContainer : (ROOT::iOS::Browser::FileContainer *)container; -{ - self = [super initWithFrame : frame]; - - if (self) { - controller = viewController; - fileContainer = container; - - self.fileName = [NSString stringWithFormat : @"%s", fileContainer->GetFileName()]; - filePictogram = [UIImage imageNamed : @"file_icon.png"]; - UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget : self action : @selector(handleTap)]; - [self addGestureRecognizer : tap]; - UILongPressGestureRecognizer *longPress = [[UILongPressGestureRecognizer alloc] initWithTarget: self action:@selector(handleLongPress:)]; - [self addGestureRecognizer : longPress]; - - self.opaque = NO; - } - - return self; -} - -//____________________________________________________________________________________________________ -- (void) drawRect : (CGRect)rect -{ - // Drawing code - CGContextRef ctx = UIGraphicsGetCurrentContext(); - - //Draw the pictogram for ROOT's file. - const CGPoint topLeftPicCorner = CGPointMake(rect.size.width / 2 - filePictogram.size.width / 2, - (rect.size.height - [FileShortcut textHeight]) / 2 - filePictogram.size.height / 2); - [filePictogram drawAtPoint:topLeftPicCorner]; - - //Draw the file name. - CGContextSetRGBFillColor(ctx, 1.f, 1.f, 1.f, 1.f); - const CGRect textRect = CGRectMake(0.f, [FileShortcut iconHeight] - [FileShortcut textHeight], [FileShortcut iconWidth], [FileShortcut textHeight]); - [fileName drawInRect : textRect withFont : [UIFont systemFontOfSize : 16] lineBreakMode : UILineBreakModeWordWrap alignment : UITextAlignmentCenter]; -} - -//____________________________________________________________________________________________________ -- (void)dealloc -{ - //Crazy name qualification :( - ROOT::iOS::Browser::FileContainer::DeleteFileContainer(fileContainer); -} - -//____________________________________________________________________________________________________ -- (void) handleTap -{ - RootFileController *parentController = (RootFileController *)controller; - [parentController fileWasSelected : self]; -} - -//____________________________________________________________________________________________________ -- (void) handleLongPress : (UILongPressGestureRecognizer *)longPress -{ - if (longPress.state == UIGestureRecognizerStateBegan) { - RootFileController *parentController = (RootFileController *)controller; - [parentController tryToDelete : self]; - } -} - -//____________________________________________________________________________________________________ -- (ROOT::iOS::Browser::FileContainer *) getFileContainer -{ - return fileContainer; -} - -@end diff --git a/test/ios/RootBrowser/H1BinsInspector.h b/test/ios/RootBrowser/H1BinsInspector.h deleted file mode 100644 index 2b5cdfaac844e..0000000000000 --- a/test/ios/RootBrowser/H1BinsInspector.h +++ /dev/null @@ -1,19 +0,0 @@ -#import "ObjectInspectorComponent.h" - -@interface H1BinsInspector : UIViewController <ObjectInspectorComponent> { -@private - __weak IBOutlet UITextField *titleField; - __weak IBOutlet UILabel *minLabel; - __weak IBOutlet UILabel *maxLabel; - __weak IBOutlet UISwitch *showMarkers; -} - -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)o; - -- (IBAction) textFieldDidEndOnExit : (id) sender; -- (IBAction) textFieldEditingDidEnd : (id) sender; -- (IBAction) toggleMarkers; - - -@end diff --git a/test/ios/RootBrowser/H1ErrorsInspector.h b/test/ios/RootBrowser/H1ErrorsInspector.h deleted file mode 100644 index ce9e7f5fd89ec..0000000000000 --- a/test/ios/RootBrowser/H1ErrorsInspector.h +++ /dev/null @@ -1,13 +0,0 @@ -#import "ObjectInspectorComponent.h" - -@interface H1ErrorsInspector : UIViewController <UIPickerViewDelegate, UIPickerViewDataSource, ObjectInspectorComponent> { -@private - __weak IBOutlet UIPickerView *errorTypePicker; -} - -//@property (nonatomic, retain) UIPickerView *errorTypePicker; - -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)o; - -@end diff --git a/test/ios/RootBrowser/H1Inspector.h b/test/ios/RootBrowser/H1Inspector.h deleted file mode 100644 index cf09a1ca8f65c..0000000000000 --- a/test/ios/RootBrowser/H1Inspector.h +++ /dev/null @@ -1,14 +0,0 @@ -#import "ObjectInspectorComponent.h" - -@interface H1Inspector : UIViewController <ObjectInspectorComponent> { -@private - __weak IBOutlet UITabBar *tabBar; -} - -- (void) setROOTObject : (TObject *)o; -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (NSString *) getComponentName; -- (void) resetInspector; - - -@end diff --git a/test/ios/RootBrowser/directory.png b/test/ios/RootBrowser/Images/Browser/directory.png similarity index 100% rename from test/ios/RootBrowser/directory.png rename to test/ios/RootBrowser/Images/Browser/directory.png diff --git a/test/ios/RootBrowser/file_icon.png b/test/ios/RootBrowser/Images/Browser/file_icon.png similarity index 100% rename from test/ios/RootBrowser/file_icon.png rename to test/ios/RootBrowser/Images/Browser/file_icon.png diff --git a/test/ios/RootBrowser/file_shortcut_background.png b/test/ios/RootBrowser/Images/Browser/file_shortcut_background.png similarity index 100% rename from test/ios/RootBrowser/file_shortcut_background.png rename to test/ios/RootBrowser/Images/Browser/file_shortcut_background.png diff --git a/test/ios/RootBrowser/Default-Landscape.png b/test/ios/RootBrowser/Images/Core/Default-Landscape.png similarity index 100% rename from test/ios/RootBrowser/Default-Landscape.png rename to test/ios/RootBrowser/Images/Core/Default-Landscape.png diff --git a/test/ios/RootBrowser/Default-LandscapeLeft.png b/test/ios/RootBrowser/Images/Core/Default-LandscapeLeft.png similarity index 100% rename from test/ios/RootBrowser/Default-LandscapeLeft.png rename to test/ios/RootBrowser/Images/Core/Default-LandscapeLeft.png diff --git a/test/ios/RootBrowser/Default-LandscapeRight.png b/test/ios/RootBrowser/Images/Core/Default-LandscapeRight.png similarity index 100% rename from test/ios/RootBrowser/Default-LandscapeRight.png rename to test/ios/RootBrowser/Images/Core/Default-LandscapeRight.png diff --git a/test/ios/RootBrowser/Default-Portrait.png b/test/ios/RootBrowser/Images/Core/Default-Portrait.png similarity index 100% rename from test/ios/RootBrowser/Default-Portrait.png rename to test/ios/RootBrowser/Images/Core/Default-Portrait.png diff --git a/test/ios/RootBrowser/Default-PortraitUpsideDown.png b/test/ios/RootBrowser/Images/Core/Default-PortraitUpsideDown.png similarity index 100% rename from test/ios/RootBrowser/Default-PortraitUpsideDown.png rename to test/ios/RootBrowser/Images/Core/Default-PortraitUpsideDown.png diff --git a/test/ios/RootBrowser/app_icon.png b/test/ios/RootBrowser/Images/Core/app_icon.png similarity index 100% rename from test/ios/RootBrowser/app_icon.png rename to test/ios/RootBrowser/Images/Core/app_icon.png diff --git a/test/ios/RootBrowser/bar-background.png b/test/ios/RootBrowser/Images/CustomUI/bar-background.png similarity index 100% rename from test/ios/RootBrowser/bar-background.png rename to test/ios/RootBrowser/Images/CustomUI/bar-background.png diff --git a/test/ios/RootBrowser/bar-highlight.png b/test/ios/RootBrowser/Images/CustomUI/bar-highlight.png similarity index 100% rename from test/ios/RootBrowser/bar-highlight.png rename to test/ios/RootBrowser/Images/CustomUI/bar-highlight.png diff --git a/test/ios/RootBrowser/handle-hover.png b/test/ios/RootBrowser/Images/CustomUI/handle-hover.png similarity index 100% rename from test/ios/RootBrowser/handle-hover.png rename to test/ios/RootBrowser/Images/CustomUI/handle-hover.png diff --git a/test/ios/RootBrowser/handle.png b/test/ios/RootBrowser/Images/CustomUI/handle.png similarity index 100% rename from test/ios/RootBrowser/handle.png rename to test/ios/RootBrowser/Images/CustomUI/handle.png diff --git a/test/ios/RootBrowser/picker_arrow.png b/test/ios/RootBrowser/Images/CustomUI/picker_arrow.png similarity index 100% rename from test/ios/RootBrowser/picker_arrow.png rename to test/ios/RootBrowser/Images/CustomUI/picker_arrow.png diff --git a/test/ios/RootBrowser/picker_bkn.png b/test/ios/RootBrowser/Images/CustomUI/picker_bkn.png similarity index 100% rename from test/ios/RootBrowser/picker_bkn.png rename to test/ios/RootBrowser/Images/CustomUI/picker_bkn.png diff --git a/test/ios/RootBrowser/picker_frame_bkn.png b/test/ios/RootBrowser/Images/CustomUI/picker_frame_bkn.png similarity index 100% rename from test/ios/RootBrowser/picker_frame_bkn.png rename to test/ios/RootBrowser/Images/CustomUI/picker_frame_bkn.png diff --git a/test/ios/RootBrowser/back_btn.png b/test/ios/RootBrowser/Images/ObjectInspector/back_btn.png similarity index 100% rename from test/ios/RootBrowser/back_btn.png rename to test/ios/RootBrowser/Images/ObjectInspector/back_btn.png diff --git a/test/ios/RootBrowser/brush_tab.png b/test/ios/RootBrowser/Images/ObjectInspector/brush_tab.png similarity index 100% rename from test/ios/RootBrowser/brush_tab.png rename to test/ios/RootBrowser/Images/ObjectInspector/brush_tab.png diff --git a/test/ios/RootBrowser/dec_line_width.png b/test/ios/RootBrowser/Images/ObjectInspector/dec_line_width.png similarity index 100% rename from test/ios/RootBrowser/dec_line_width.png rename to test/ios/RootBrowser/Images/ObjectInspector/dec_line_width.png diff --git a/test/ios/RootBrowser/editor_plate.png b/test/ios/RootBrowser/Images/ObjectInspector/editor_plate.png similarity index 100% rename from test/ios/RootBrowser/editor_plate.png rename to test/ios/RootBrowser/Images/ObjectInspector/editor_plate.png diff --git a/test/ios/RootBrowser/editor_state_arrow.png b/test/ios/RootBrowser/Images/ObjectInspector/editor_state_arrow.png similarity index 100% rename from test/ios/RootBrowser/editor_state_arrow.png rename to test/ios/RootBrowser/Images/ObjectInspector/editor_state_arrow.png diff --git a/test/ios/RootBrowser/forward_btn.png b/test/ios/RootBrowser/Images/ObjectInspector/forward_btn.png similarity index 100% rename from test/ios/RootBrowser/forward_btn.png rename to test/ios/RootBrowser/Images/ObjectInspector/forward_btn.png diff --git a/test/ios/RootBrowser/h1_errors_tab.png b/test/ios/RootBrowser/Images/ObjectInspector/h1_errors_tab.png similarity index 100% rename from test/ios/RootBrowser/h1_errors_tab.png rename to test/ios/RootBrowser/Images/ObjectInspector/h1_errors_tab.png diff --git a/test/ios/RootBrowser/h1_tab.png b/test/ios/RootBrowser/Images/ObjectInspector/h1_tab.png similarity index 100% rename from test/ios/RootBrowser/h1_tab.png rename to test/ios/RootBrowser/Images/ObjectInspector/h1_tab.png diff --git a/test/ios/RootBrowser/inc_line_width.png b/test/ios/RootBrowser/Images/ObjectInspector/inc_line_width.png similarity index 100% rename from test/ios/RootBrowser/inc_line_width.png rename to test/ios/RootBrowser/Images/ObjectInspector/inc_line_width.png diff --git a/test/ios/RootBrowser/label_tab.png b/test/ios/RootBrowser/Images/ObjectInspector/label_tab.png similarity index 100% rename from test/ios/RootBrowser/label_tab.png rename to test/ios/RootBrowser/Images/ObjectInspector/label_tab.png diff --git a/test/ios/RootBrowser/lg_tab.png b/test/ios/RootBrowser/Images/ObjectInspector/lg_tab.png similarity index 100% rename from test/ios/RootBrowser/lg_tab.png rename to test/ios/RootBrowser/Images/ObjectInspector/lg_tab.png diff --git a/test/ios/RootBrowser/line_cell.png b/test/ios/RootBrowser/Images/ObjectInspector/line_cell.png similarity index 100% rename from test/ios/RootBrowser/line_cell.png rename to test/ios/RootBrowser/Images/ObjectInspector/line_cell.png diff --git a/test/ios/RootBrowser/line_style_tab.png b/test/ios/RootBrowser/Images/ObjectInspector/line_style_tab.png similarity index 100% rename from test/ios/RootBrowser/line_style_tab.png rename to test/ios/RootBrowser/Images/ObjectInspector/line_style_tab.png diff --git a/test/ios/RootBrowser/line_width_bkn.png b/test/ios/RootBrowser/Images/ObjectInspector/line_width_bkn.png similarity index 100% rename from test/ios/RootBrowser/line_width_bkn.png rename to test/ios/RootBrowser/Images/ObjectInspector/line_width_bkn.png diff --git a/test/ios/RootBrowser/minus_btn.png b/test/ios/RootBrowser/Images/ObjectInspector/minus_btn.png similarity index 100% rename from test/ios/RootBrowser/minus_btn.png rename to test/ios/RootBrowser/Images/ObjectInspector/minus_btn.png diff --git a/test/ios/RootBrowser/plus_btn.png b/test/ios/RootBrowser/Images/ObjectInspector/plus_btn.png similarity index 100% rename from test/ios/RootBrowser/plus_btn.png rename to test/ios/RootBrowser/Images/ObjectInspector/plus_btn.png diff --git a/test/ios/RootBrowser/separator.png b/test/ios/RootBrowser/Images/ObjectInspector/separator.png similarity index 100% rename from test/ios/RootBrowser/separator.png rename to test/ios/RootBrowser/Images/ObjectInspector/separator.png diff --git a/test/ios/RootBrowser/text_cell_bkn.png b/test/ios/RootBrowser/Images/ObjectInspector/text_cell_bkn.png similarity index 100% rename from test/ios/RootBrowser/text_cell_bkn.png rename to test/ios/RootBrowser/Images/ObjectInspector/text_cell_bkn.png diff --git a/test/ios/RootBrowser/ticks_tab.png b/test/ios/RootBrowser/Images/ObjectInspector/ticks_tab.png similarity index 100% rename from test/ios/RootBrowser/ticks_tab.png rename to test/ios/RootBrowser/Images/ObjectInspector/ticks_tab.png diff --git a/test/ios/RootBrowser/title_tab.png b/test/ios/RootBrowser/Images/ObjectInspector/title_tab.png similarity index 100% rename from test/ios/RootBrowser/title_tab.png rename to test/ios/RootBrowser/Images/ObjectInspector/title_tab.png diff --git a/test/ios/RootBrowser/InspectorWithNavigation.h b/test/ios/RootBrowser/InspectorWithNavigation.h deleted file mode 100644 index 6f945898a529e..0000000000000 --- a/test/ios/RootBrowser/InspectorWithNavigation.h +++ /dev/null @@ -1,12 +0,0 @@ -#import <UIKit/UIKit.h> - -#import "ObjectInspectorComponent.h" - -@interface InspectorWithNavigation : UINavigationController <ObjectInspectorComponent> - -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)obj; -- (NSString *) getComponentName; -- (void) resetInspector; - -@end diff --git a/test/ios/RootBrowser/InspectorWithNavigation.mm b/test/ios/RootBrowser/InspectorWithNavigation.mm deleted file mode 100644 index 2fc83a52d12a9..0000000000000 --- a/test/ios/RootBrowser/InspectorWithNavigation.mm +++ /dev/null @@ -1,85 +0,0 @@ -#import "InspectorWithNavigation.h" - -@implementation InspectorWithNavigation - -//____________________________________________________________________________________________________ -- (id) initWithRootViewController : (UIViewController<ObjectInspectorComponent> *) rootController -{ - self = [super initWithRootViewController : (UIViewController *)rootController]; - if (self) { - self.navigationBar.hidden = YES; - } - - return self; -} - -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle - -/* -// Implement loadView to create a view hierarchy programmatically, without using a nib. -- (void)loadView -{ -} -*/ - -/* -// Implement viewDidLoad to do additional setup after loading the view, typically from a nib. -- (void)viewDidLoad -{ - [super viewDidLoad]; -} -*/ - -//____________________________________________________________________________________________________ -- (void)viewDidUnload -{ - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} - -//____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations - return YES; -} - -//____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c -{ - UIViewController<ObjectInspectorComponent> *rootController = (UIViewController<ObjectInspectorComponent> *)[self.viewControllers objectAtIndex : 0]; - [rootController setROOTObjectController : c]; -} - -//____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)obj -{ - UIViewController<ObjectInspectorComponent> *rootController = (UIViewController<ObjectInspectorComponent> *)[self.viewControllers objectAtIndex : 0]; - [rootController setROOTObject : obj]; -} - -//____________________________________________________________________________________________________ -- (NSString *) getComponentName -{ - UIViewController<ObjectInspectorComponent> *rootController = (UIViewController<ObjectInspectorComponent> *)[self.viewControllers objectAtIndex : 0]; - return [rootController getComponentName]; -} - -//____________________________________________________________________________________________________ -- (void) resetInspector -{ - //Pop all controllers from a stack except a top level root controller. - while ([self.viewControllers count] > 1) - [self popViewControllerAnimated : NO]; -} - -@end diff --git a/test/ios/RootBrowser/LineInspector.h b/test/ios/RootBrowser/LineInspector.h deleted file mode 100644 index 66a88b77dd3b1..0000000000000 --- a/test/ios/RootBrowser/LineInspector.h +++ /dev/null @@ -1,27 +0,0 @@ -#import <UIKit/UIKit.h> - -#import "ObjectInspectorComponent.h" -#import "HorizontalPickerDelegate.h" - - -@class HorizontalPickerView; -@class LineWidthPicker; - -//Line inspector is a composition of two sub-inspectors: line color and width inspector + -//line style inspector. - -@interface LineInspector : UIViewController <ObjectInspectorComponent, HorizontalPickerDelegate> { -@private - __weak IBOutlet LineWidthPicker *lineWidthPicker; -} - -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)o; -- (NSString *) getComponentName; - -- (void) item : (unsigned int)item wasSelectedInPicker : (HorizontalPickerView *)picker; - -- (IBAction) decLineWidth; -- (IBAction) incLineWidth; - -@end diff --git a/test/ios/RootBrowser/MarkerInspector.h b/test/ios/RootBrowser/MarkerInspector.h deleted file mode 100644 index cce894c05d5c7..0000000000000 --- a/test/ios/RootBrowser/MarkerInspector.h +++ /dev/null @@ -1,20 +0,0 @@ -#import <UIKit/UIKit.h> - -#import "ObjectInspectorComponent.h" -#import "HorizontalPickerDelegate.h" - -@interface MarkerInspector : UIViewController <ObjectInspectorComponent, HorizontalPickerDelegate> { -@private - __weak IBOutlet UIButton *plusBtn; - __weak IBOutlet UIButton *minusBtn; - __weak IBOutlet UILabel *sizeLabel; -} - -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)o; -- (NSString *) getComponentName; - -- (IBAction) plusPressed; -- (IBAction) minusPressed; - -@end diff --git a/test/ios/RootBrowser/ObjectShortcut.h b/test/ios/RootBrowser/ObjectShortcut.h deleted file mode 100644 index c7e5456f7d3e2..0000000000000 --- a/test/ios/RootBrowser/ObjectShortcut.h +++ /dev/null @@ -1,23 +0,0 @@ -#import <UIKit/UIKit.h> - -@class FileContentController; -@class SpotView; - -@interface ObjectShortcut : UIView - -@property (nonatomic, retain) SpotView *spot; -@property (nonatomic, assign) BOOL isDirectory; -@property (nonatomic, retain) UIImage *icon; -@property (nonatomic, readonly) unsigned objectIndex; -@property (nonatomic, retain) NSString *objectName; - -+ (CGFloat) iconWidth; -+ (CGFloat) iconHeight; -+ (CGFloat) textHeight; -+ (CGRect) defaultRect; - - -- (id) initWithFrame : (CGRect)frame controller : (FileContentController*) c forObjectAtIndex : (unsigned)objIndex withThumbnail : (UIImage *)thumbnail; -- (id) initWithFrame : (CGRect)frame controller : (FileContentController*) c forFolderAtIndex : (unsigned)index; - -@end diff --git a/test/ios/RootBrowser/ObjectShortcut.mm b/test/ios/RootBrowser/ObjectShortcut.mm deleted file mode 100644 index 0df9fec99a0f2..0000000000000 --- a/test/ios/RootBrowser/ObjectShortcut.mm +++ /dev/null @@ -1,135 +0,0 @@ -#import <CoreGraphics/CGContext.h> -#import <QuartzCore/QuartzCore.h> - -#import "FileContentController.h" -#import "ObjectShortcut.h" -#import "SpotView.h" - -//C++ (ROOT) imports. -#import "FileUtils.h" -#import "TObject.h" - -const CGSize folderIconSize = CGSizeMake(128.f, 128.f); - -@implementation ObjectShortcut { - __weak FileContentController *controller; - - unsigned objectIndex; - NSString *objectName; -} - -@synthesize isDirectory; -@synthesize icon; -@synthesize objectIndex; -@synthesize objectName; -@synthesize spot; - -//____________________________________________________________________________________________________ -+ (CGFloat) iconWidth -{ - return 150.f; -} - -//____________________________________________________________________________________________________ -+ (CGFloat) iconHeight -{ - return 150.f; -} - -//____________________________________________________________________________________________________ -+ (CGFloat) textHeight -{ - return 100.f; -} - -//____________________________________________________________________________________________________ -+ (CGRect) defaultRect -{ - return CGRectMake(0.f, 0.f, [ObjectShortcut iconWidth], [ObjectShortcut iconHeight] + [ObjectShortcut textHeight]); -} - -//____________________________________________________________________________________________________ -- (id) initWithFrame : (CGRect)frame controller : (FileContentController*) c forFolderAtIndex : (unsigned)index -{ - using namespace ROOT::iOS::Browser; - - if (self = [super initWithFrame : frame]) { - frame.origin = CGPointZero; - frame.size.height = [ObjectShortcut iconHeight]; - - spot = [[SpotView alloc] initWithFrame : frame]; - [self addSubview : spot]; - - controller = c; - objectIndex = index; - - const FileContainer *cont = controller.fileContainer->GetDirectory(index); - isDirectory = YES; - self.objectName = [NSString stringWithFormat : @"%s", cont->GetFileName()]; - self.icon = [UIImage imageNamed : @"directory.png"]; - self.opaque = NO; - - //Tap gesture to select a directory. - UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(handleTap)]; - [self addGestureRecognizer : tap]; - } - - return self; -} - -//____________________________________________________________________________________________________ -- (id) initWithFrame : (CGRect)frame controller : (FileContentController*) c forObjectAtIndex : (unsigned)objIndex withThumbnail : (UIImage *)thumbnail -{ - using namespace ROOT::iOS::Browser; - - self = [super initWithFrame:frame]; - - if (self) { - frame.origin = CGPointZero; - frame.size.height = [ObjectShortcut iconHeight]; - - spot = [[SpotView alloc] initWithFrame : frame]; - [self addSubview : spot]; - - //ROOT's staff. - controller = c; - objectIndex = objIndex; - - const TObject *obj = controller.fileContainer->GetObject(objIndex); - self.objectName = [NSString stringWithFormat : @"%s", obj->GetName()]; - self.icon = thumbnail; - - self.opaque = NO; - - //Tap gesture to select an object. - UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(handleTap)]; - [self addGestureRecognizer : tap]; - } - - return self; -} - -//____________________________________________________________________________________________________ -- (void) drawRect : (CGRect)rect -{ - CGContextRef ctx = UIGraphicsGetCurrentContext(); - - if (isDirectory) { - //Directory's icon is 128 x 128 < than thumbnail. - CGPoint topLeft = CGPointMake([ObjectShortcut iconWidth] / 2 - folderIconSize.width / 2, [ObjectShortcut iconHeight] / 2 - folderIconSize.height / 2); - [icon drawAtPoint : topLeft]; - } else - [icon drawAtPoint : CGPointZero]; - - CGContextSetRGBFillColor(ctx, 1.f, 1.f, 1.f, 1.f); - const CGRect textRect = CGRectMake(0.f, [ObjectShortcut iconHeight], [ObjectShortcut iconWidth], [ObjectShortcut textHeight]); - [objectName drawInRect : textRect withFont : [UIFont systemFontOfSize : 16] lineBreakMode : UILineBreakModeWordWrap alignment : UITextAlignmentCenter]; -} - -//____________________________________________________________________________________________________ -- (void) handleTap -{ - [controller selectObjectFromFile : self]; -} - -@end diff --git a/test/ios/RootBrowser/PadImageScrollView.h b/test/ios/RootBrowser/PadImageScrollView.h deleted file mode 100644 index d8990e81f549d..0000000000000 --- a/test/ios/RootBrowser/PadImageScrollView.h +++ /dev/null @@ -1,20 +0,0 @@ -#import <UIKit/UIKit.h> - -namespace ROOT { -namespace iOS { - -class Pad; - -} -} - -@interface PadImageScrollView : UIScrollView <UIScrollViewDelegate> - -+ (CGRect) defaultImageFrame; - -- (id) initWithFrame : (CGRect)frame; - -- (void) setPad : (ROOT::iOS::Pad *)pad; -- (void) resetToFrame : (CGRect)frame; - -@end diff --git a/test/ios/RootBrowser/PadInspector.h b/test/ios/RootBrowser/PadInspector.h deleted file mode 100644 index 8271ee752e0d4..0000000000000 --- a/test/ios/RootBrowser/PadInspector.h +++ /dev/null @@ -1,17 +0,0 @@ -#import <UIKit/UIKit.h> - -#import "ObjectInspectorComponent.h" - -@interface PadInspector : UIViewController <ObjectInspectorComponent, UITabBarDelegate> { -@private - __weak IBOutlet UITabBar *tabBar; -} - -+ (CGRect) inspectorFrame; - -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)o; -- (NSString *) getComponentName; -- (void) resetInspector; - -@end diff --git a/test/ios/RootBrowser/PadLogScaleInspector.h b/test/ios/RootBrowser/PadLogScaleInspector.h deleted file mode 100644 index 5518ea30ffb37..0000000000000 --- a/test/ios/RootBrowser/PadLogScaleInspector.h +++ /dev/null @@ -1,17 +0,0 @@ -#import <UIKit/UIKit.h> - -#import "ObjectInspectorComponent.h" - -@interface PadLogScaleInspector : UIViewController <ObjectInspectorComponent> { -@private - __weak IBOutlet UISwitch *logX; - __weak IBOutlet UISwitch *logY; - __weak IBOutlet UISwitch *logZ; -} - -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)o; - -- (IBAction) logActivated : (UISwitch *) log; - -@end diff --git a/test/ios/RootBrowser/PadTicksGridInspector.h b/test/ios/RootBrowser/PadTicksGridInspector.h deleted file mode 100644 index 39178a9c8a6e7..0000000000000 --- a/test/ios/RootBrowser/PadTicksGridInspector.h +++ /dev/null @@ -1,19 +0,0 @@ -#import <UIKit/UIKit.h> - -#import "ObjectInspectorComponent.h" - -@interface PadTicksGridInspector : UIViewController <ObjectInspectorComponent> { -@private - __weak IBOutlet UISwitch *gridX; - __weak IBOutlet UISwitch *gridY; - __weak IBOutlet UISwitch *ticksX; - __weak IBOutlet UISwitch *ticksY; -} - -- (void) setROOTObjectController : (ROOTObjectController *) c; -- (void) setROOTObject : (TObject *) obj; - -- (IBAction) gridActivated : (UISwitch *) g; -- (IBAction) ticksActivated : (UISwitch *) t; - -@end diff --git a/test/ios/RootBrowser/ROOTObjectController.h b/test/ios/RootBrowser/ROOTObjectController.h deleted file mode 100644 index 3ff55b323f25e..0000000000000 --- a/test/ios/RootBrowser/ROOTObjectController.h +++ /dev/null @@ -1,28 +0,0 @@ -#import <MessageUI/MessageUI.h> -#import <UIKit/UIKit.h> - -#import "FileUtils.h" - -@class ScrollViewWithPadView; - -class TObject; - -@interface ROOTObjectController : UIViewController <UIScrollViewDelegate, MFMailComposeViewControllerDelegate> { -@private - __weak IBOutlet ScrollViewWithPadView *padScrollView; - __weak IBOutlet UIScrollView *navigationScrollView; -} - -- (void) setNavigationForObjectWithIndex : (unsigned) index fromContainer : (ROOT::iOS::Browser::FileContainer *)fileContainer; -- (void) handleDoubleTapOnPad : (CGPoint)tapPt; -- (void) objectWasSelected : (TObject *)object; -- (void) objectWasModifiedUpdateSelection : (BOOL)needUpdate; -- (void) setupObjectInspector; - -- (ROOT::iOS::Browser::EHistogramErrorOption) getErrorOption; -- (void) setErrorOption : (ROOT::iOS::Browser::EHistogramErrorOption) errorOption; - -- (BOOL) markerIsOn; -- (void) setMarker : (BOOL)on; - -@end diff --git a/test/ios/RootBrowser/ROOTObjectController.xib b/test/ios/RootBrowser/ROOTObjectController.xib deleted file mode 100644 index b8c63a5534381..0000000000000 --- a/test/ios/RootBrowser/ROOTObjectController.xib +++ /dev/null @@ -1,271 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<archive type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="7.10"> - <data> - <int key="IBDocument.SystemTarget">1056</int> - <string key="IBDocument.SystemVersion">11B26</string> - <string key="IBDocument.InterfaceBuilderVersion">1617</string> - <string key="IBDocument.AppKitVersion">1138</string> - <string key="IBDocument.HIToolboxVersion">566.00</string> - <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> - <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string key="NS.object.0">534</string> - </object> - <object class="NSArray" key="IBDocument.IntegratedClassDependencies"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>IBProxyObject</string> - <string>IBUIView</string> - <string>IBUIScrollView</string> - </object> - <object class="NSArray" key="IBDocument.PluginDependencies"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - </object> - <object class="NSMutableDictionary" key="IBDocument.Metadata"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys" id="0"> - <bool key="EncodedWithXMLCoder">YES</bool> - </object> - <reference key="dict.values" ref="0"/> - </object> - <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBProxyObject" id="841351856"> - <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBProxyObject" id="606714003"> - <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBUIView" id="766721923"> - <reference key="NSNextResponder"/> - <int key="NSvFlags">256</int> - <object class="NSMutableArray" key="NSSubviews"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBUIScrollView" id="245540603"> - <reference key="NSNextResponder" ref="766721923"/> - <int key="NSvFlags">274</int> - <string key="NSFrameSize">{1024, 748}</string> - <reference key="NSSuperview" ref="766721923"/> - <reference key="NSWindow"/> - <string key="NSReuseIdentifierKey">_NS:189</string> - <object class="NSColor" key="IBUIBackgroundColor" id="285997021"> - <int key="NSColorSpace">3</int> - <bytes key="NSWhite">MCAwAA</bytes> - </object> - <bool key="IBUIClipsSubviews">YES</bool> - <bool key="IBUIMultipleTouchEnabled">YES</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <bool key="IBUIPagingEnabled">YES</bool> - <bool key="IBUIShowsHorizontalScrollIndicator">NO</bool> - <bool key="IBUIShowsVerticalScrollIndicator">NO</bool> - <bool key="IBUIDelaysContentTouches">NO</bool> - <bool key="IBUICanCancelContentTouches">NO</bool> - </object> - <object class="IBUIScrollView" id="839725682"> - <reference key="NSNextResponder" ref="766721923"/> - <int key="NSvFlags">274</int> - <string key="NSFrame">{{0, 31}, {1024, 687}}</string> - <reference key="NSSuperview" ref="766721923"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="245540603"/> - <reference key="IBUIBackgroundColor" ref="285997021"/> - <bool key="IBUIClipsSubviews">YES</bool> - <bool key="IBUIMultipleTouchEnabled">YES</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <bool key="IBUIBounces">NO</bool> - </object> - </object> - <string key="NSFrame">{{0, 20}, {1024, 748}}</string> - <reference key="NSSuperview"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="839725682"/> - <reference key="IBUIBackgroundColor" ref="285997021"/> - <bool key="IBUIClearsContextBeforeDrawing">NO</bool> - <int key="IBUIContentMode">2</int> - <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"> - <int key="IBUIStatusBarStyle">2</int> - </object> - <object class="IBUISimulatedOrientationMetrics" key="IBUISimulatedOrientationMetrics"> - <int key="IBUIInterfaceOrientation">3</int> - <int key="interfaceOrientation">3</int> - </object> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - </object> - <object class="IBObjectContainer" key="IBDocument.Objects"> - <object class="NSMutableArray" key="connectionRecords"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">view</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="766721923"/> - </object> - <int key="connectionID">11</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">navigationScrollView</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="245540603"/> - </object> - <int key="connectionID">14</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">padScrollView</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="839725682"/> - </object> - <int key="connectionID">15</int> - </object> - </object> - <object class="IBMutableOrderedSet" key="objectRecords"> - <object class="NSArray" key="orderedObjects"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBObjectRecord"> - <int key="objectID">0</int> - <reference key="object" ref="0"/> - <reference key="children" ref="1000"/> - <nil key="parent"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">-1</int> - <reference key="object" ref="841351856"/> - <reference key="parent" ref="0"/> - <string key="objectName">File's Owner</string> - </object> - <object class="IBObjectRecord"> - <int key="objectID">-2</int> - <reference key="object" ref="606714003"/> - <reference key="parent" ref="0"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">2</int> - <reference key="object" ref="766721923"/> - <object class="NSMutableArray" key="children"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="839725682"/> - <reference ref="245540603"/> - </object> - <reference key="parent" ref="0"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">8</int> - <reference key="object" ref="839725682"/> - <object class="NSMutableArray" key="children"> - <bool key="EncodedWithXMLCoder">YES</bool> - </object> - <reference key="parent" ref="766721923"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">13</int> - <reference key="object" ref="245540603"/> - <reference key="parent" ref="766721923"/> - </object> - </object> - </object> - <object class="NSMutableDictionary" key="flattenedProperties"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>-1.CustomClassName</string> - <string>-1.IBPluginDependency</string> - <string>-2.CustomClassName</string> - <string>-2.IBPluginDependency</string> - <string>13.IBPluginDependency</string> - <string>2.IBPluginDependency</string> - <string>8.CustomClassName</string> - <string>8.IBPluginDependency</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>ROOTObjectController</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>UIResponder</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>ScrollViewWithPadView</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - </object> - </object> - <object class="NSMutableDictionary" key="unlocalizedProperties"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference key="dict.sortedKeys" ref="0"/> - <reference key="dict.values" ref="0"/> - </object> - <nil key="activeLocalization"/> - <object class="NSMutableDictionary" key="localizations"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference key="dict.sortedKeys" ref="0"/> - <reference key="dict.values" ref="0"/> - </object> - <nil key="sourceID"/> - <int key="maxID">15</int> - </object> - <object class="IBClassDescriber" key="IBDocument.Classes"> - <object class="NSMutableArray" key="referencedPartialClassDescriptions"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBPartialClassDescription"> - <string key="className">ROOTObjectController</string> - <string key="superclassName">UIViewController</string> - <object class="NSMutableDictionary" key="outlets"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>navigationScrollView</string> - <string>padScrollView</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>UIScrollView</string> - <string>ScrollViewWithPadView</string> - </object> - </object> - <object class="NSMutableDictionary" key="toOneOutletInfosByName"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>navigationScrollView</string> - <string>padScrollView</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBToOneOutletInfo"> - <string key="name">navigationScrollView</string> - <string key="candidateClassName">UIScrollView</string> - </object> - <object class="IBToOneOutletInfo"> - <string key="name">padScrollView</string> - <string key="candidateClassName">ScrollViewWithPadView</string> - </object> - </object> - </object> - <object class="IBClassDescriptionSource" key="sourceIdentifier"> - <string key="majorKey">IBProjectSource</string> - <string key="minorKey">./Classes/ROOTObjectController.h</string> - </object> - </object> - <object class="IBPartialClassDescription"> - <string key="className">ScrollViewWithPadView</string> - <string key="superclassName">UIScrollView</string> - <object class="IBClassDescriptionSource" key="sourceIdentifier"> - <string key="majorKey">IBProjectSource</string> - <string key="minorKey">./Classes/ScrollViewWithPadView.h</string> - </object> - </object> - </object> - </object> - <int key="IBDocument.localizationMode">0</int> - <string key="IBDocument.TargetRuntimeIdentifier">IBIPadFramework</string> - <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies"> - <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string> - <integer value="3100" key="NS.object.0"/> - </object> - <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> - <int key="IBDocument.defaultPropertyAccessControl">3</int> - <string key="IBCocoaTouchPluginVersion">534</string> - </data> -</archive> diff --git a/test/ios/RootBrowser/RootBrowser.xcodeproj/project.pbxproj b/test/ios/RootBrowser/RootBrowser.xcodeproj/project.pbxproj index a1b155cdfa74f..1cd0bf83ca341 100644 --- a/test/ios/RootBrowser/RootBrowser.xcodeproj/project.pbxproj +++ b/test/ios/RootBrowser/RootBrowser.xcodeproj/project.pbxproj @@ -7,103 +7,110 @@ objects = { /* Begin PBXBuildFile section */ - 70078C2D146AC4C400C19F4D /* FileUtils.cxx in Sources */ = {isa = PBXBuildFile; fileRef = 70078C2C146AC4C400C19F4D /* FileUtils.cxx */; }; - 700ED6CB146BCDF200526D1C /* directory.png in Resources */ = {isa = PBXBuildFile; fileRef = 700ED6CA146BCDF100526D1C /* directory.png */; }; - 7014410F140E18390070459F /* SelectionView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7014410E140E18390070459F /* SelectionView.mm */; }; - 70144120140E3F1D0070459F /* LineStyleCell.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7014411F140E3F1D0070459F /* LineStyleCell.mm */; }; - 70144129140E553C0070459F /* line_cell.png in Resources */ = {isa = PBXBuildFile; fileRef = 70144128140E553C0070459F /* line_cell.png */; }; - 702357DB14345C0A00A95000 /* H1ErrorsInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 702357D914345C0A00A95000 /* H1ErrorsInspector.mm */; }; - 702357DC14345C0A00A95000 /* H1ErrorsInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 702357DA14345C0A00A95000 /* H1ErrorsInspector.xib */; }; - 702357E11434658900A95000 /* H1Inspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 702357DF1434658900A95000 /* H1Inspector.mm */; }; - 702357E21434658900A95000 /* H1Inspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 702357E01434658900A95000 /* H1Inspector.xib */; }; - 70235803143494F400A95000 /* MarkerInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70235801143494F400A95000 /* MarkerInspector.mm */; }; - 70235804143494F400A95000 /* MarkerInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 70235802143494F400A95000 /* MarkerInspector.xib */; }; - 702358081434A93C00A95000 /* H1BinsInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 702358061434A93B00A95000 /* H1BinsInspector.mm */; }; - 702358091434A93C00A95000 /* H1BinsInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 702358071434A93C00A95000 /* H1BinsInspector.xib */; }; - 7023580B1434ACC700A95000 /* h1_errors_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 7023580A1434ACC700A95000 /* h1_errors_tab.png */; }; - 7023580D1434B48C00A95000 /* h1_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 7023580C1434B48C00A95000 /* h1_tab.png */; }; - 7023805E140514C8002A5331 /* file_icon.png in Resources */ = {isa = PBXBuildFile; fileRef = 7023805D140514C8002A5331 /* file_icon.png */; }; - 70249BDC1403D644006A19E6 /* PadView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70249BDA1403D644006A19E6 /* PadView.mm */; }; - 70252F7C140CDD8D00F3660F /* Constants.cxx in Sources */ = {isa = PBXBuildFile; fileRef = 70252F7A140CDD8D00F3660F /* Constants.cxx */; }; - 702BB9D714482E2200D3842F /* picker_arrow.png in Resources */ = {isa = PBXBuildFile; fileRef = 702BB9D514482E2200D3842F /* picker_arrow.png */; }; - 702BB9D814482E2200D3842F /* picker_frame_bkn.png in Resources */ = {isa = PBXBuildFile; fileRef = 702BB9D614482E2200D3842F /* picker_frame_bkn.png */; }; - 702BB9DC14482E3C00D3842F /* HorizontalPickerView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 702BB9DA14482E3C00D3842F /* HorizontalPickerView.mm */; }; - 702BB9E01448559A00D3842F /* line_width_bkn.png in Resources */ = {isa = PBXBuildFile; fileRef = 702BB9DF1448559A00D3842F /* line_width_bkn.png */; }; - 702BB9E21448584E00D3842F /* dec_line_width.png in Resources */ = {isa = PBXBuildFile; fileRef = 702BB9E11448584E00D3842F /* dec_line_width.png */; }; - 702BB9E414485E4200D3842F /* inc_line_width.png in Resources */ = {isa = PBXBuildFile; fileRef = 702BB9E314485E4200D3842F /* inc_line_width.png */; }; - 702BB9E71448680200D3842F /* LineWidthPicker.mm in Sources */ = {isa = PBXBuildFile; fileRef = 702BB9E61448680200D3842F /* LineWidthPicker.mm */; }; - 702DDD1B1415FEA1009FC6F3 /* LineInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 702DDD191415FEA1009FC6F3 /* LineInspector.mm */; }; - 702DDD1C1415FEA1009FC6F3 /* LineInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 702DDD1A1415FEA1009FC6F3 /* LineInspector.xib */; }; - 702DDD2914161789009FC6F3 /* InspectorWithNavigation.mm in Sources */ = {isa = PBXBuildFile; fileRef = 702DDD2814161789009FC6F3 /* InspectorWithNavigation.mm */; }; + 7025582F1856060E00403763 /* Browser_iPad.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 7025582E1856060E00403763 /* Browser_iPad.storyboard */; }; 70360B1A142C7AC6001F77E1 /* MessageUI.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 70360B19142C7AC6001F77E1 /* MessageUI.framework */; }; - 7044980D1429D13D00E83799 /* PadImageScrollView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7044980C1429D13D00E83799 /* PadImageScrollView.mm */; }; - 7053E8B6143B076F001C364D /* MarkerStyleCell.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7053E8B5143B076F001C364D /* MarkerStyleCell.mm */; }; - 705A503614066421004C1C8B /* ScrollViewWithPadView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 705A503514066421004C1C8B /* ScrollViewWithPadView.mm */; }; - 706241D01435F86700202121 /* RangeSlider.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706241CE1435F86700202121 /* RangeSlider.mm */; }; - 706241D51435F94500202121 /* bar-background.png in Resources */ = {isa = PBXBuildFile; fileRef = 706241D11435F94500202121 /* bar-background.png */; }; - 706241D61435F94500202121 /* bar-highlight.png in Resources */ = {isa = PBXBuildFile; fileRef = 706241D21435F94500202121 /* bar-highlight.png */; }; - 706241D71435F94500202121 /* handle-hover.png in Resources */ = {isa = PBXBuildFile; fileRef = 706241D31435F94500202121 /* handle-hover.png */; }; - 706241D81435F94500202121 /* handle.png in Resources */ = {isa = PBXBuildFile; fileRef = 706241D41435F94500202121 /* handle.png */; }; - 7066FB31143338AF00F88A2C /* brush_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 7066FB30143338AF00F88A2C /* brush_tab.png */; }; - 7066FB3414333E7300F88A2C /* line_style_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 7066FB3314333E7300F88A2C /* line_style_tab.png */; }; - 7066FB36143341A900F88A2C /* ticks_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 7066FB35143341A900F88A2C /* ticks_tab.png */; }; - 7066FB38143342C700F88A2C /* lg_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 7066FB37143342C700F88A2C /* lg_tab.png */; }; - 7066FB3A1433459200F88A2C /* title_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 7066FB391433459200F88A2C /* title_tab.png */; }; - 7066FB3C1433470F00F88A2C /* label_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 7066FB3B1433470F00F88A2C /* label_tab.png */; }; - 70681C0D1416365900F8338A /* PadInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70681C0B1416365900F8338A /* PadInspector.mm */; }; - 70681C0E1416365900F8338A /* PadInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 70681C0C1416365900F8338A /* PadInspector.xib */; }; - 70681C1314163A2300F8338A /* PadTicksGridInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 70681C1114163A2300F8338A /* PadTicksGridInspector.xib */; }; - 70681C1514163D3F00F8338A /* PadTicksGridInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70681C1414163D3F00F8338A /* PadTicksGridInspector.mm */; }; - 70681C1914163F0C00F8338A /* PadLogScaleInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70681C1714163F0C00F8338A /* PadLogScaleInspector.mm */; }; - 70681C1A14163F0C00F8338A /* PadLogScaleInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 70681C1814163F0C00F8338A /* PadLogScaleInspector.xib */; }; - 70681C1E1416474000F8338A /* FilledAreaInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70681C1C1416474000F8338A /* FilledAreaInspector.mm */; }; - 70681C1F1416474000F8338A /* FilledAreaInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 70681C1D1416474000F8338A /* FilledAreaInspector.xib */; }; - 70681C221416586D00F8338A /* ObjectInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70681C211416586D00F8338A /* ObjectInspector.mm */; }; - 7068963F1446F9FD00C2E3E7 /* picker_bkn.png in Resources */ = {isa = PBXBuildFile; fileRef = 7068963E1446F9FD00C2E3E7 /* picker_bkn.png */; }; - 7068FF1F1419FCBC003560A1 /* separator.png in Resources */ = {isa = PBXBuildFile; fileRef = 7068FF1E1419FCBC003560A1 /* separator.png */; }; - 7068FF24141A0EAF003560A1 /* AxisFontInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7068FF22141A0EAF003560A1 /* AxisFontInspector.mm */; }; - 7068FF25141A0EAF003560A1 /* AxisFontInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 7068FF23141A0EAF003560A1 /* AxisFontInspector.xib */; }; - 7068FF2B141A2F6A003560A1 /* text_cell_bkn.png in Resources */ = {isa = PBXBuildFile; fileRef = 7068FF2A141A2F6A003560A1 /* text_cell_bkn.png */; }; - 7068FF31141A3944003560A1 /* AxisLabelsInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7068FF2F141A3943003560A1 /* AxisLabelsInspector.mm */; }; - 7068FF32141A3944003560A1 /* AxisLabelsInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 7068FF30141A3944003560A1 /* AxisLabelsInspector.xib */; }; - 7073A275141757BC001A0FE2 /* AxisTicksInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7073A273141757BB001A0FE2 /* AxisTicksInspector.mm */; }; - 7073A276141757BC001A0FE2 /* AxisTicksInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 7073A274141757BB001A0FE2 /* AxisTicksInspector.xib */; }; - 7073A27E14177A03001A0FE2 /* AxisInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7073A27C14177A03001A0FE2 /* AxisInspector.mm */; }; - 7073A27F14177A03001A0FE2 /* AxisInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 7073A27D14177A03001A0FE2 /* AxisInspector.xib */; }; - 7073A28214179A6D001A0FE2 /* minus_btn.png in Resources */ = {isa = PBXBuildFile; fileRef = 7073A28014179A6C001A0FE2 /* minus_btn.png */; }; - 7073A28314179A6D001A0FE2 /* plus_btn.png in Resources */ = {isa = PBXBuildFile; fileRef = 7073A28114179A6D001A0FE2 /* plus_btn.png */; }; - 7073A2871417AA10001A0FE2 /* AxisTitleInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7073A2851417AA0F001A0FE2 /* AxisTitleInspector.mm */; }; - 7073A2881417AA10001A0FE2 /* AxisTitleInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 7073A2861417AA10001A0FE2 /* AxisTitleInspector.xib */; }; - 7073A9AE14277D1B006F6D67 /* Default-Portrait.png in Resources */ = {isa = PBXBuildFile; fileRef = 7073A9A914277D16006F6D67 /* Default-Portrait.png */; }; - 7073A9AF14277D1B006F6D67 /* Default-PortraitUpsideDown.png in Resources */ = {isa = PBXBuildFile; fileRef = 7073A9AA14277D17006F6D67 /* Default-PortraitUpsideDown.png */; }; - 7073A9B014277D1B006F6D67 /* Default-Landscape.png in Resources */ = {isa = PBXBuildFile; fileRef = 7073A9AB14277D18006F6D67 /* Default-Landscape.png */; }; - 7073A9B114277D1B006F6D67 /* Default-LandscapeLeft.png in Resources */ = {isa = PBXBuildFile; fileRef = 7073A9AC14277D19006F6D67 /* Default-LandscapeLeft.png */; }; - 7073A9B214277D1B006F6D67 /* Default-LandscapeRight.png in Resources */ = {isa = PBXBuildFile; fileRef = 7073A9AD14277D1A006F6D67 /* Default-LandscapeRight.png */; }; - 7077853214139EBF00450A1B /* editor_plate.png in Resources */ = {isa = PBXBuildFile; fileRef = 7077853114139EBF00450A1B /* editor_plate.png */; }; + 706EA5431855F5290043AAA6 /* main.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5401855F5290043AAA6 /* main.mm */; }; + 706EA5441855F5290043AAA6 /* root_browserAppDelegate.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5421855F5290043AAA6 /* root_browserAppDelegate.mm */; }; + 706EA55D1855F6DA0043AAA6 /* HorizontalPickerView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5561855F6DA0043AAA6 /* HorizontalPickerView.mm */; }; + 706EA55E1855F6DA0043AAA6 /* RangeSlider.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5581855F6DA0043AAA6 /* RangeSlider.mm */; }; + 706EA55F1855F6DA0043AAA6 /* ScrollViewWithPickers.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA55A1855F6DA0043AAA6 /* ScrollViewWithPickers.mm */; }; + 706EA5601855F6DA0043AAA6 /* TransparentToolbar.m in Sources */ = {isa = PBXBuildFile; fileRef = 706EA55C1855F6DA0043AAA6 /* TransparentToolbar.m */; }; + 706EA5741855F7E50043AAA6 /* FileShortcutView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5651855F7E50043AAA6 /* FileShortcutView.mm */; }; + 706EA5751855F7E50043AAA6 /* ObjectShortcutView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5671855F7E50043AAA6 /* ObjectShortcutView.mm */; }; + 706EA5761855F7E50043AAA6 /* PadEditorScrollView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5691855F7E50043AAA6 /* PadEditorScrollView.mm */; }; + 706EA5771855F7E50043AAA6 /* PadScrollView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA56B1855F7E50043AAA6 /* PadScrollView.mm */; }; + 706EA5781855F7E50043AAA6 /* PadSelectionView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA56D1855F7E50043AAA6 /* PadSelectionView.mm */; }; + 706EA5791855F7E50043AAA6 /* PadSlideView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA56F1855F7E50043AAA6 /* PadSlideView.mm */; }; + 706EA57A1855F7E50043AAA6 /* PadView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5711855F7E50043AAA6 /* PadView.mm */; }; + 706EA57B1855F7E50043AAA6 /* SpotObjectView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5731855F7E50043AAA6 /* SpotObjectView.mm */; }; + 706EA57E1855F8570043AAA6 /* FileContainerElement.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA57D1855F8570043AAA6 /* FileContainerElement.mm */; }; + 706EA5891855F8CC0043AAA6 /* FileCollectionViewController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA57F1855F8CC0043AAA6 /* FileCollectionViewController.mm */; }; + 706EA58A1855F8CC0043AAA6 /* FileContentViewController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5811855F8CC0043AAA6 /* FileContentViewController.mm */; }; + 706EA58B1855F8CC0043AAA6 /* ObjectViewController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5821855F8CC0043AAA6 /* ObjectViewController.mm */; }; + 706EA58C1855F8CC0043AAA6 /* SlideshowViewController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5841855F8CC0043AAA6 /* SlideshowViewController.mm */; }; + 706EA58D1855F8CC0043AAA6 /* SearchViewController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5861855F8CC0043AAA6 /* SearchViewController.mm */; }; + 706EA59A1855FA310043AAA6 /* MainWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5991855FA310043AAA6 /* MainWindow.xib */; }; + 706EA5BF1855FBA30043AAA6 /* AxisFontInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA59E1855FBA30043AAA6 /* AxisFontInspector.mm */; }; + 706EA5C01855FBA30043AAA6 /* AxisInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5A01855FBA30043AAA6 /* AxisInspector.mm */; }; + 706EA5C11855FBA30043AAA6 /* AxisLabelsInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5A21855FBA30043AAA6 /* AxisLabelsInspector.mm */; }; + 706EA5C21855FBA30043AAA6 /* AxisTicksInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5A41855FBA30043AAA6 /* AxisTicksInspector.mm */; }; + 706EA5C31855FBA30043AAA6 /* AxisTitleInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5A61855FBA30043AAA6 /* AxisTitleInspector.mm */; }; + 706EA5C41855FBA30043AAA6 /* FilledAreaInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5A81855FBA30043AAA6 /* FilledAreaInspector.mm */; }; + 706EA5C51855FBA30043AAA6 /* H1BinsInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5AA1855FBA30043AAA6 /* H1BinsInspector.mm */; }; + 706EA5C61855FBA30043AAA6 /* H1ErrorsInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5AC1855FBA30043AAA6 /* H1ErrorsInspector.mm */; }; + 706EA5C71855FBA30043AAA6 /* H1Inspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5AE1855FBA30043AAA6 /* H1Inspector.mm */; }; + 706EA5C81855FBA30043AAA6 /* InspectorWithNavigation.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5B01855FBA30043AAA6 /* InspectorWithNavigation.mm */; }; + 706EA5C91855FBA30043AAA6 /* LineInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5B21855FBA30043AAA6 /* LineInspector.mm */; }; + 706EA5CA1855FBA30043AAA6 /* MarkerInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5B41855FBA30043AAA6 /* MarkerInspector.mm */; }; + 706EA5CB1855FBA30043AAA6 /* ObjectInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5B61855FBA30043AAA6 /* ObjectInspector.mm */; }; + 706EA5CC1855FBA30043AAA6 /* PadInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5B91855FBA30043AAA6 /* PadInspector.mm */; }; + 706EA5CD1855FBA30043AAA6 /* PadLogScaleInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5BB1855FBA30043AAA6 /* PadLogScaleInspector.mm */; }; + 706EA5CE1855FBA30043AAA6 /* PadTicksGridInspector.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5BD1855FBA30043AAA6 /* PadTicksGridInspector.mm */; }; + 706EA5E01855FC5B0043AAA6 /* ColorCell.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5D11855FC5B0043AAA6 /* ColorCell.mm */; }; + 706EA5E11855FC5B0043AAA6 /* EditorPlateView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5D31855FC5B0043AAA6 /* EditorPlateView.mm */; }; + 706EA5E21855FC5B0043AAA6 /* EditorView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5D51855FC5B0043AAA6 /* EditorView.mm */; }; + 706EA5E31855FC5B0043AAA6 /* LineStyleCell.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5D71855FC5B0043AAA6 /* LineStyleCell.mm */; }; + 706EA5E41855FC5B0043AAA6 /* LineWidthCell.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5D91855FC5B0043AAA6 /* LineWidthCell.mm */; }; + 706EA5E51855FC5B0043AAA6 /* LineWidthPicker.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5DB1855FC5B0043AAA6 /* LineWidthPicker.mm */; }; + 706EA5E61855FC5B0043AAA6 /* MarkerStyleCell.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5DD1855FC5B0043AAA6 /* MarkerStyleCell.mm */; }; + 706EA5E71855FC5B0043AAA6 /* PatternCell.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA5DF1855FC5B0043AAA6 /* PatternCell.mm */; }; + 706EA5F71855FD320043AAA6 /* AxisFontInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5E91855FD320043AAA6 /* AxisFontInspector.xib */; }; + 706EA5F81855FD320043AAA6 /* AxisInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5EA1855FD320043AAA6 /* AxisInspector.xib */; }; + 706EA5F91855FD320043AAA6 /* AxisLabelsInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5EB1855FD320043AAA6 /* AxisLabelsInspector.xib */; }; + 706EA5FA1855FD320043AAA6 /* AxisTicksInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5EC1855FD320043AAA6 /* AxisTicksInspector.xib */; }; + 706EA5FB1855FD320043AAA6 /* AxisTitleInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5ED1855FD320043AAA6 /* AxisTitleInspector.xib */; }; + 706EA5FC1855FD320043AAA6 /* FilledAreaInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5EE1855FD320043AAA6 /* FilledAreaInspector.xib */; }; + 706EA5FD1855FD320043AAA6 /* H1BinsInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5EF1855FD320043AAA6 /* H1BinsInspector.xib */; }; + 706EA5FE1855FD320043AAA6 /* H1ErrorsInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5F01855FD320043AAA6 /* H1ErrorsInspector.xib */; }; + 706EA5FF1855FD320043AAA6 /* H1Inspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5F11855FD320043AAA6 /* H1Inspector.xib */; }; + 706EA6001855FD320043AAA6 /* LineInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5F21855FD320043AAA6 /* LineInspector.xib */; }; + 706EA6011855FD320043AAA6 /* MarkerInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5F31855FD320043AAA6 /* MarkerInspector.xib */; }; + 706EA6021855FD320043AAA6 /* PadInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5F41855FD320043AAA6 /* PadInspector.xib */; }; + 706EA6031855FD320043AAA6 /* PadLogScaleInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5F51855FD320043AAA6 /* PadLogScaleInspector.xib */; }; + 706EA6041855FD320043AAA6 /* PadTicksGridInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = 706EA5F61855FD320043AAA6 /* PadTicksGridInspector.xib */; }; + 706EA60C1855FDEB0043AAA6 /* Constants.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA6071855FDEB0043AAA6 /* Constants.mm */; }; + 706EA60D1855FDEB0043AAA6 /* FileUtils.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA6091855FDEB0043AAA6 /* FileUtils.mm */; }; + 706EA60E1855FDEB0043AAA6 /* Shortcuts.mm in Sources */ = {isa = PBXBuildFile; fileRef = 706EA60B1855FDEB0043AAA6 /* Shortcuts.mm */; }; + 706EA6171855FE610043AAA6 /* app_icon.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA6111855FE610043AAA6 /* app_icon.png */; }; + 706EA6181855FE610043AAA6 /* Default-Landscape.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA6121855FE610043AAA6 /* Default-Landscape.png */; }; + 706EA6191855FE610043AAA6 /* Default-LandscapeLeft.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA6131855FE610043AAA6 /* Default-LandscapeLeft.png */; }; + 706EA61A1855FE610043AAA6 /* Default-LandscapeRight.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA6141855FE610043AAA6 /* Default-LandscapeRight.png */; }; + 706EA61B1855FE610043AAA6 /* Default-Portrait.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA6151855FE610043AAA6 /* Default-Portrait.png */; }; + 706EA61C1855FE610043AAA6 /* Default-PortraitUpsideDown.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA6161855FE610043AAA6 /* Default-PortraitUpsideDown.png */; }; + 706EA6211855FEEF0043AAA6 /* directory.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA61E1855FEEF0043AAA6 /* directory.png */; }; + 706EA6221855FEEF0043AAA6 /* file_icon.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA61F1855FEEF0043AAA6 /* file_icon.png */; }; + 706EA6231855FEEF0043AAA6 /* file_shortcut_background.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA6201855FEEF0043AAA6 /* file_shortcut_background.png */; }; + 706EA641185601F30043AAA6 /* back_btn.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA625185601F30043AAA6 /* back_btn.png */; }; + 706EA642185601F30043AAA6 /* brush_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA626185601F30043AAA6 /* brush_tab.png */; }; + 706EA643185601F30043AAA6 /* dec_line_width.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA627185601F30043AAA6 /* dec_line_width.png */; }; + 706EA644185601F30043AAA6 /* editor_plate.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA628185601F30043AAA6 /* editor_plate.png */; }; + 706EA645185601F30043AAA6 /* editor_state_arrow.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA629185601F30043AAA6 /* editor_state_arrow.png */; }; + 706EA646185601F30043AAA6 /* forward_btn.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA62A185601F30043AAA6 /* forward_btn.png */; }; + 706EA647185601F30043AAA6 /* h1_errors_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA62B185601F30043AAA6 /* h1_errors_tab.png */; }; + 706EA648185601F30043AAA6 /* h1_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA62C185601F30043AAA6 /* h1_tab.png */; }; + 706EA649185601F30043AAA6 /* inc_line_width.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA62D185601F30043AAA6 /* inc_line_width.png */; }; + 706EA64A185601F30043AAA6 /* label_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA62E185601F30043AAA6 /* label_tab.png */; }; + 706EA64B185601F30043AAA6 /* lg_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA62F185601F30043AAA6 /* lg_tab.png */; }; + 706EA64C185601F30043AAA6 /* line_cell.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA630185601F30043AAA6 /* line_cell.png */; }; + 706EA64D185601F30043AAA6 /* line_style_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA631185601F30043AAA6 /* line_style_tab.png */; }; + 706EA64E185601F30043AAA6 /* line_width_bkn.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA632185601F30043AAA6 /* line_width_bkn.png */; }; + 706EA64F185601F30043AAA6 /* minus_btn.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA633185601F30043AAA6 /* minus_btn.png */; }; + 706EA650185601F30043AAA6 /* plus_btn.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA634185601F30043AAA6 /* plus_btn.png */; }; + 706EA651185601F30043AAA6 /* separator.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA635185601F30043AAA6 /* separator.png */; }; + 706EA652185601F30043AAA6 /* text_cell_bkn.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA636185601F30043AAA6 /* text_cell_bkn.png */; }; + 706EA653185601F30043AAA6 /* ticks_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA637185601F30043AAA6 /* ticks_tab.png */; }; + 706EA654185601F30043AAA6 /* title_tab.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA638185601F30043AAA6 /* title_tab.png */; }; + 706EA655185601F30043AAA6 /* bar-background.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA63A185601F30043AAA6 /* bar-background.png */; }; + 706EA656185601F30043AAA6 /* bar-highlight.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA63B185601F30043AAA6 /* bar-highlight.png */; }; + 706EA657185601F30043AAA6 /* handle-hover.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA63C185601F30043AAA6 /* handle-hover.png */; }; + 706EA658185601F30043AAA6 /* handle.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA63D185601F30043AAA6 /* handle.png */; }; + 706EA659185601F30043AAA6 /* picker_arrow.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA63E185601F30043AAA6 /* picker_arrow.png */; }; + 706EA65A185601F30043AAA6 /* picker_bkn.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA63F185601F30043AAA6 /* picker_bkn.png */; }; + 706EA65B185601F30043AAA6 /* picker_frame_bkn.png in Resources */ = {isa = PBXBuildFile; fileRef = 706EA640185601F30043AAA6 /* picker_frame_bkn.png */; }; 7077901E13FE50EB00C0FFA1 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7077901D13FE50EB00C0FFA1 /* UIKit.framework */; }; 7077902013FE50EB00C0FFA1 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7077901F13FE50EB00C0FFA1 /* Foundation.framework */; }; 7077902213FE50EB00C0FFA1 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7077902113FE50EB00C0FFA1 /* CoreGraphics.framework */; }; 7077902813FE50EB00C0FFA1 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 7077902613FE50EB00C0FFA1 /* InfoPlist.strings */; }; - 7077902B13FE50EB00C0FFA1 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 7077902A13FE50EB00C0FFA1 /* main.m */; }; - 7077902E13FE50EB00C0FFA1 /* root_browserAppDelegate.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7077902D13FE50EB00C0FFA1 /* root_browserAppDelegate.mm */; }; - 7077903113FE50EB00C0FFA1 /* MainWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 7077902F13FE50EB00C0FFA1 /* MainWindow.xib */; }; - 7077903A13FE51B400C0FFA1 /* RootFileController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7077903813FE51B400C0FFA1 /* RootFileController.mm */; }; - 7077903B13FE51B400C0FFA1 /* RootFileController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 7077903913FE51B400C0FFA1 /* RootFileController.xib */; }; - 7077903F13FE549300C0FFA1 /* FileContentController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7077903D13FE549300C0FFA1 /* FileContentController.mm */; }; - 7077904013FE549300C0FFA1 /* FileContentController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 7077903E13FE549300C0FFA1 /* FileContentController.xib */; }; - 7077904313FE554E00C0FFA1 /* FileShortcut.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7077904213FE554E00C0FFA1 /* FileShortcut.mm */; }; - 7077905113FE6B8F00C0FFA1 /* file_shortcut_background.png in Resources */ = {isa = PBXBuildFile; fileRef = 7077905013FE6B8F00C0FFA1 /* file_shortcut_background.png */; }; - 7077905D13FE840000C0FFA1 /* SlideshowController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7077905B13FE840000C0FFA1 /* SlideshowController.mm */; }; - 7077905E13FE840000C0FFA1 /* SlideshowController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 7077905C13FE840000C0FFA1 /* SlideshowController.xib */; }; - 7077906213FE847600C0FFA1 /* ROOTObjectController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7077906013FE847600C0FFA1 /* ROOTObjectController.mm */; }; - 7077906313FE847600C0FFA1 /* ROOTObjectController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 7077906113FE847600C0FFA1 /* ROOTObjectController.xib */; }; - 7077906613FE87D000C0FFA1 /* ObjectShortcut.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7077906513FE87D000C0FFA1 /* ObjectShortcut.mm */; }; - 7077907E13FE96C300C0FFA1 /* EditorView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7077906B13FE96C200C0FFA1 /* EditorView.mm */; }; - 7077908013FE96C300C0FFA1 /* ScrollViewWithPickers.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7077906E13FE96C200C0FFA1 /* ScrollViewWithPickers.mm */; }; - 7077908113FE96C300C0FFA1 /* EditorPlateView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7077906F13FE96C200C0FFA1 /* EditorPlateView.mm */; }; - 7077908713FE96C300C0FFA1 /* PatternCell.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7077907913FE96C300C0FFA1 /* PatternCell.mm */; }; - 7077908813FE96C300C0FFA1 /* ColorCell.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7077907B13FE96C300C0FFA1 /* ColorCell.mm */; }; - 7077908B13FE96DC00C0FFA1 /* editor_state_arrow.png in Resources */ = {isa = PBXBuildFile; fileRef = 7077908913FE96DC00C0FFA1 /* editor_state_arrow.png */; }; 7077908E13FE972D00C0FFA1 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7077908D13FE972D00C0FFA1 /* QuartzCore.framework */; }; 7077909013FE973A00C0FFA1 /* CoreText.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7077908F13FE973A00C0FFA1 /* CoreText.framework */; }; 7095949C13FE978400B9E8B6 /* libRoot.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7095949813FE978400B9E8B6 /* libRoot.a */; }; @@ -113,124 +120,158 @@ 709594A213FE978C00B9E8B6 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 709594A113FE978C00B9E8B6 /* libz.dylib */; }; 709594A513FE97AF00B9E8B6 /* system.rootrc in Resources */ = {isa = PBXBuildFile; fileRef = 709594A313FE97AF00B9E8B6 /* system.rootrc */; }; 709594A613FE97AF00B9E8B6 /* system.plugins-ios in Resources */ = {isa = PBXBuildFile; fileRef = 709594A413FE97AF00B9E8B6 /* system.plugins-ios */; }; - 70989EFD1473E73200515FC5 /* SpotView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70989EFC1473E73200515FC5 /* SpotView.mm */; }; 709CD05314025148005B2AF4 /* demos.root in Resources */ = {isa = PBXBuildFile; fileRef = 709CD05214025148005B2AF4 /* demos.root */; }; - 709CD0981402768B005B2AF4 /* Shortcuts.mm in Sources */ = {isa = PBXBuildFile; fileRef = 709CD0971402768B005B2AF4 /* Shortcuts.mm */; }; - 70AC541E146966E7009A0942 /* ThumbnailView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70AC541C146966E7009A0942 /* ThumbnailView.mm */; }; - 70C1D67B1468162600514DC0 /* LineWidthCell.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70C1D67A1468162600514DC0 /* LineWidthCell.mm */; }; - 70C1D67D1468166100514DC0 /* SlideView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70C1D67C1468166100514DC0 /* SlideView.mm */; }; - 70E0B62114150F630077E4A8 /* back_btn.png in Resources */ = {isa = PBXBuildFile; fileRef = 70E0B62014150F630077E4A8 /* back_btn.png */; }; - 70E0B624141510880077E4A8 /* forward_btn.png in Resources */ = {isa = PBXBuildFile; fileRef = 70E0B623141510880077E4A8 /* forward_btn.png */; }; - 70E16B091455CBC00050C281 /* app_icon.png in Resources */ = {isa = PBXBuildFile; fileRef = 70E16B081455CBC00050C281 /* app_icon.png */; }; - 70E36B571472965E004AEB6A /* FileContainerElement.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70E36B561472965E004AEB6A /* FileContainerElement.mm */; }; - 70E4FE5214715ABD00296BFF /* TransparentToolbar.m in Sources */ = {isa = PBXBuildFile; fileRef = 70E4FE5114715ABD00296BFF /* TransparentToolbar.m */; }; - 70E4FE5B1471685700296BFF /* SearchController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70E4FE5A1471685700296BFF /* SearchController.mm */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ - 70078C2B146AC4C400C19F4D /* FileUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileUtils.h; sourceTree = "<group>"; }; - 70078C2C146AC4C400C19F4D /* FileUtils.cxx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = FileUtils.cxx; sourceTree = "<group>"; }; - 700ED6CA146BCDF100526D1C /* directory.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = directory.png; sourceTree = "<group>"; }; - 7014410D140E18390070459F /* SelectionView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SelectionView.h; sourceTree = "<group>"; }; - 7014410E140E18390070459F /* SelectionView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = SelectionView.mm; sourceTree = "<group>"; }; - 7014411E140E3F1D0070459F /* LineStyleCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LineStyleCell.h; sourceTree = "<group>"; }; - 7014411F140E3F1D0070459F /* LineStyleCell.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = LineStyleCell.mm; sourceTree = "<group>"; }; - 70144121140E3F320070459F /* LineWidthCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LineWidthCell.h; sourceTree = "<group>"; }; - 70144128140E553C0070459F /* line_cell.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = line_cell.png; sourceTree = "<group>"; }; - 702357D814345C0A00A95000 /* H1ErrorsInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = H1ErrorsInspector.h; sourceTree = "<group>"; }; - 702357D914345C0A00A95000 /* H1ErrorsInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = H1ErrorsInspector.mm; sourceTree = "<group>"; }; - 702357DA14345C0A00A95000 /* H1ErrorsInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = H1ErrorsInspector.xib; sourceTree = "<group>"; }; - 702357DE1434658900A95000 /* H1Inspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = H1Inspector.h; sourceTree = "<group>"; }; - 702357DF1434658900A95000 /* H1Inspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = H1Inspector.mm; sourceTree = "<group>"; }; - 702357E01434658900A95000 /* H1Inspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = H1Inspector.xib; sourceTree = "<group>"; }; - 70235800143494F400A95000 /* MarkerInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MarkerInspector.h; sourceTree = "<group>"; }; - 70235801143494F400A95000 /* MarkerInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MarkerInspector.mm; sourceTree = "<group>"; }; - 70235802143494F400A95000 /* MarkerInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = MarkerInspector.xib; sourceTree = "<group>"; }; - 702358051434A93B00A95000 /* H1BinsInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = H1BinsInspector.h; sourceTree = "<group>"; }; - 702358061434A93B00A95000 /* H1BinsInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = H1BinsInspector.mm; sourceTree = "<group>"; }; - 702358071434A93C00A95000 /* H1BinsInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = H1BinsInspector.xib; sourceTree = "<group>"; }; - 7023580A1434ACC700A95000 /* h1_errors_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = h1_errors_tab.png; sourceTree = "<group>"; }; - 7023580C1434B48C00A95000 /* h1_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = h1_tab.png; sourceTree = "<group>"; }; - 7023805D140514C8002A5331 /* file_icon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = file_icon.png; sourceTree = "<group>"; }; - 70249BDA1403D644006A19E6 /* PadView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadView.mm; sourceTree = "<group>"; }; - 70252F7A140CDD8D00F3660F /* Constants.cxx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Constants.cxx; sourceTree = "<group>"; }; - 70252F7B140CDD8D00F3660F /* Constants.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Constants.h; sourceTree = "<group>"; }; - 702BB9D514482E2200D3842F /* picker_arrow.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = picker_arrow.png; sourceTree = "<group>"; }; - 702BB9D614482E2200D3842F /* picker_frame_bkn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = picker_frame_bkn.png; sourceTree = "<group>"; }; - 702BB9DA14482E3C00D3842F /* HorizontalPickerView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = HorizontalPickerView.mm; sourceTree = "<group>"; }; - 702BB9DB14482E3C00D3842F /* HorizontalPickerView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HorizontalPickerView.h; sourceTree = "<group>"; }; - 702BB9DF1448559A00D3842F /* line_width_bkn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = line_width_bkn.png; sourceTree = "<group>"; }; - 702BB9E11448584E00D3842F /* dec_line_width.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = dec_line_width.png; sourceTree = "<group>"; }; - 702BB9E314485E4200D3842F /* inc_line_width.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = inc_line_width.png; sourceTree = "<group>"; }; - 702BB9E51448680100D3842F /* LineWidthPicker.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LineWidthPicker.h; sourceTree = "<group>"; }; - 702BB9E61448680200D3842F /* LineWidthPicker.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = LineWidthPicker.mm; sourceTree = "<group>"; }; - 702DDD161415FDDB009FC6F3 /* ObjectInspectorComponent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ObjectInspectorComponent.h; sourceTree = "<group>"; }; - 702DDD181415FEA1009FC6F3 /* LineInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LineInspector.h; sourceTree = "<group>"; }; - 702DDD191415FEA1009FC6F3 /* LineInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = LineInspector.mm; sourceTree = "<group>"; }; - 702DDD1A1415FEA1009FC6F3 /* LineInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = LineInspector.xib; sourceTree = "<group>"; }; - 702DDD2714161789009FC6F3 /* InspectorWithNavigation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorWithNavigation.h; sourceTree = "<group>"; }; - 702DDD2814161789009FC6F3 /* InspectorWithNavigation.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = InspectorWithNavigation.mm; sourceTree = "<group>"; }; + 7025582E1856060E00403763 /* Browser_iPad.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = Browser_iPad.storyboard; sourceTree = "<group>"; }; 70360B19142C7AC6001F77E1 /* MessageUI.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MessageUI.framework; path = System/Library/Frameworks/MessageUI.framework; sourceTree = SDKROOT; }; - 7044980B1429D13D00E83799 /* PadImageScrollView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadImageScrollView.h; sourceTree = "<group>"; }; - 7044980C1429D13D00E83799 /* PadImageScrollView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadImageScrollView.mm; sourceTree = "<group>"; }; - 704B5A211520CC8D00FEF9C8 /* PadView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadView.h; sourceTree = "<group>"; }; - 7053E8B4143B076F001C364D /* MarkerStyleCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MarkerStyleCell.h; sourceTree = "<group>"; }; - 7053E8B5143B076F001C364D /* MarkerStyleCell.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MarkerStyleCell.mm; sourceTree = "<group>"; }; - 705A503414066421004C1C8B /* ScrollViewWithPadView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScrollViewWithPadView.h; sourceTree = "<group>"; }; - 705A503514066421004C1C8B /* ScrollViewWithPadView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ScrollViewWithPadView.mm; sourceTree = "<group>"; }; - 705F1A66142347CA003045D9 /* SlideView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SlideView.h; sourceTree = "<group>"; }; - 706241CE1435F86700202121 /* RangeSlider.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = RangeSlider.mm; sourceTree = "<group>"; }; - 706241CF1435F86700202121 /* RangeSlider.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RangeSlider.h; sourceTree = "<group>"; }; - 706241D11435F94500202121 /* bar-background.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "bar-background.png"; sourceTree = "<group>"; }; - 706241D21435F94500202121 /* bar-highlight.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "bar-highlight.png"; sourceTree = "<group>"; }; - 706241D31435F94500202121 /* handle-hover.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "handle-hover.png"; sourceTree = "<group>"; }; - 706241D41435F94500202121 /* handle.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = handle.png; sourceTree = "<group>"; }; - 7066FB30143338AF00F88A2C /* brush_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = brush_tab.png; sourceTree = "<group>"; }; - 7066FB3314333E7300F88A2C /* line_style_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = line_style_tab.png; sourceTree = "<group>"; }; - 7066FB35143341A900F88A2C /* ticks_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = ticks_tab.png; sourceTree = "<group>"; }; - 7066FB37143342C700F88A2C /* lg_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = lg_tab.png; sourceTree = "<group>"; }; - 7066FB391433459200F88A2C /* title_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = title_tab.png; sourceTree = "<group>"; }; - 7066FB3B1433470F00F88A2C /* label_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = label_tab.png; sourceTree = "<group>"; }; - 70681C0A1416365900F8338A /* PadInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadInspector.h; sourceTree = "<group>"; }; - 70681C0B1416365900F8338A /* PadInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadInspector.mm; sourceTree = "<group>"; }; - 70681C0C1416365900F8338A /* PadInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = PadInspector.xib; sourceTree = "<group>"; }; - 70681C0F14163A2300F8338A /* PadTicksGridInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadTicksGridInspector.h; sourceTree = "<group>"; }; - 70681C1114163A2300F8338A /* PadTicksGridInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = PadTicksGridInspector.xib; sourceTree = "<group>"; }; - 70681C1414163D3F00F8338A /* PadTicksGridInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadTicksGridInspector.mm; sourceTree = "<group>"; }; - 70681C1614163F0C00F8338A /* PadLogScaleInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadLogScaleInspector.h; sourceTree = "<group>"; }; - 70681C1714163F0C00F8338A /* PadLogScaleInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadLogScaleInspector.mm; sourceTree = "<group>"; }; - 70681C1814163F0C00F8338A /* PadLogScaleInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = PadLogScaleInspector.xib; sourceTree = "<group>"; }; - 70681C1B1416474000F8338A /* FilledAreaInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FilledAreaInspector.h; sourceTree = "<group>"; }; - 70681C1C1416474000F8338A /* FilledAreaInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FilledAreaInspector.mm; sourceTree = "<group>"; }; - 70681C1D1416474000F8338A /* FilledAreaInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = FilledAreaInspector.xib; sourceTree = "<group>"; }; - 70681C201416586D00F8338A /* ObjectInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ObjectInspector.h; sourceTree = "<group>"; }; - 70681C211416586D00F8338A /* ObjectInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ObjectInspector.mm; sourceTree = "<group>"; }; - 7068963E1446F9FD00C2E3E7 /* picker_bkn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = picker_bkn.png; sourceTree = "<group>"; }; - 7068FF1E1419FCBC003560A1 /* separator.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = separator.png; sourceTree = "<group>"; }; - 7068FF21141A0EAF003560A1 /* AxisFontInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AxisFontInspector.h; sourceTree = "<group>"; }; - 7068FF22141A0EAF003560A1 /* AxisFontInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AxisFontInspector.mm; sourceTree = "<group>"; }; - 7068FF23141A0EAF003560A1 /* AxisFontInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = AxisFontInspector.xib; sourceTree = "<group>"; }; - 7068FF2A141A2F6A003560A1 /* text_cell_bkn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = text_cell_bkn.png; sourceTree = "<group>"; }; - 7068FF2E141A3943003560A1 /* AxisLabelsInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AxisLabelsInspector.h; sourceTree = "<group>"; }; - 7068FF2F141A3943003560A1 /* AxisLabelsInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AxisLabelsInspector.mm; sourceTree = "<group>"; }; - 7068FF30141A3944003560A1 /* AxisLabelsInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = AxisLabelsInspector.xib; sourceTree = "<group>"; }; - 7073A272141757BB001A0FE2 /* AxisTicksInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AxisTicksInspector.h; sourceTree = "<group>"; }; - 7073A273141757BB001A0FE2 /* AxisTicksInspector.mm */ = {isa = PBXFileReference; explicitFileType = sourcecode.cpp.objcpp; fileEncoding = 4; path = AxisTicksInspector.mm; sourceTree = "<group>"; }; - 7073A274141757BB001A0FE2 /* AxisTicksInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = AxisTicksInspector.xib; sourceTree = "<group>"; }; - 7073A27B14177A03001A0FE2 /* AxisInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AxisInspector.h; sourceTree = "<group>"; }; - 7073A27C14177A03001A0FE2 /* AxisInspector.mm */ = {isa = PBXFileReference; explicitFileType = sourcecode.cpp.objcpp; fileEncoding = 4; path = AxisInspector.mm; sourceTree = "<group>"; }; - 7073A27D14177A03001A0FE2 /* AxisInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = AxisInspector.xib; sourceTree = "<group>"; }; - 7073A28014179A6C001A0FE2 /* minus_btn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = minus_btn.png; sourceTree = "<group>"; }; - 7073A28114179A6D001A0FE2 /* plus_btn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = plus_btn.png; sourceTree = "<group>"; }; - 7073A2841417AA0F001A0FE2 /* AxisTitleInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AxisTitleInspector.h; sourceTree = "<group>"; }; - 7073A2851417AA0F001A0FE2 /* AxisTitleInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AxisTitleInspector.mm; sourceTree = "<group>"; }; - 7073A2861417AA10001A0FE2 /* AxisTitleInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = AxisTitleInspector.xib; sourceTree = "<group>"; }; - 7073A9A914277D16006F6D67 /* Default-Portrait.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-Portrait.png"; sourceTree = "<group>"; }; - 7073A9AA14277D17006F6D67 /* Default-PortraitUpsideDown.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-PortraitUpsideDown.png"; sourceTree = "<group>"; }; - 7073A9AB14277D18006F6D67 /* Default-Landscape.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-Landscape.png"; sourceTree = "<group>"; }; - 7073A9AC14277D19006F6D67 /* Default-LandscapeLeft.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-LandscapeLeft.png"; sourceTree = "<group>"; }; - 7073A9AD14277D1A006F6D67 /* Default-LandscapeRight.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-LandscapeRight.png"; sourceTree = "<group>"; }; - 7077853114139EBF00450A1B /* editor_plate.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = editor_plate.png; sourceTree = "<group>"; }; + 706EA5401855F5290043AAA6 /* main.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = main.mm; sourceTree = "<group>"; }; + 706EA5411855F5290043AAA6 /* root_browserAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = root_browserAppDelegate.h; sourceTree = "<group>"; }; + 706EA5421855F5290043AAA6 /* root_browserAppDelegate.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = root_browserAppDelegate.mm; sourceTree = "<group>"; }; + 706EA5541855F6DA0043AAA6 /* HorizontalPickerDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HorizontalPickerDelegate.h; sourceTree = "<group>"; }; + 706EA5551855F6DA0043AAA6 /* HorizontalPickerView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HorizontalPickerView.h; sourceTree = "<group>"; }; + 706EA5561855F6DA0043AAA6 /* HorizontalPickerView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = HorizontalPickerView.mm; sourceTree = "<group>"; }; + 706EA5571855F6DA0043AAA6 /* RangeSlider.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RangeSlider.h; sourceTree = "<group>"; }; + 706EA5581855F6DA0043AAA6 /* RangeSlider.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = RangeSlider.mm; sourceTree = "<group>"; }; + 706EA5591855F6DA0043AAA6 /* ScrollViewWithPickers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScrollViewWithPickers.h; sourceTree = "<group>"; }; + 706EA55A1855F6DA0043AAA6 /* ScrollViewWithPickers.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ScrollViewWithPickers.mm; sourceTree = "<group>"; }; + 706EA55B1855F6DA0043AAA6 /* TransparentToolbar.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TransparentToolbar.h; sourceTree = "<group>"; }; + 706EA55C1855F6DA0043AAA6 /* TransparentToolbar.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TransparentToolbar.m; sourceTree = "<group>"; }; + 706EA5641855F7E50043AAA6 /* FileShortcutView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileShortcutView.h; sourceTree = "<group>"; }; + 706EA5651855F7E50043AAA6 /* FileShortcutView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileShortcutView.mm; sourceTree = "<group>"; }; + 706EA5661855F7E50043AAA6 /* ObjectShortcutView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ObjectShortcutView.h; sourceTree = "<group>"; }; + 706EA5671855F7E50043AAA6 /* ObjectShortcutView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ObjectShortcutView.mm; sourceTree = "<group>"; }; + 706EA5681855F7E50043AAA6 /* PadEditorScrollView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadEditorScrollView.h; sourceTree = "<group>"; }; + 706EA5691855F7E50043AAA6 /* PadEditorScrollView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadEditorScrollView.mm; sourceTree = "<group>"; }; + 706EA56A1855F7E50043AAA6 /* PadScrollView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadScrollView.h; sourceTree = "<group>"; }; + 706EA56B1855F7E50043AAA6 /* PadScrollView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadScrollView.mm; sourceTree = "<group>"; }; + 706EA56C1855F7E50043AAA6 /* PadSelectionView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadSelectionView.h; sourceTree = "<group>"; }; + 706EA56D1855F7E50043AAA6 /* PadSelectionView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadSelectionView.mm; sourceTree = "<group>"; }; + 706EA56E1855F7E50043AAA6 /* PadSlideView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadSlideView.h; sourceTree = "<group>"; }; + 706EA56F1855F7E50043AAA6 /* PadSlideView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadSlideView.mm; sourceTree = "<group>"; }; + 706EA5701855F7E50043AAA6 /* PadView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadView.h; sourceTree = "<group>"; }; + 706EA5711855F7E50043AAA6 /* PadView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadView.mm; sourceTree = "<group>"; }; + 706EA5721855F7E50043AAA6 /* SpotObjectView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SpotObjectView.h; sourceTree = "<group>"; }; + 706EA5731855F7E50043AAA6 /* SpotObjectView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = SpotObjectView.mm; sourceTree = "<group>"; }; + 706EA57C1855F8570043AAA6 /* FileContainerElement.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileContainerElement.h; sourceTree = "<group>"; }; + 706EA57D1855F8570043AAA6 /* FileContainerElement.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileContainerElement.mm; sourceTree = "<group>"; }; + 706EA57F1855F8CC0043AAA6 /* FileCollectionViewController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileCollectionViewController.mm; sourceTree = "<group>"; }; + 706EA5801855F8CC0043AAA6 /* FileCollectionViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileCollectionViewController.h; sourceTree = "<group>"; }; + 706EA5811855F8CC0043AAA6 /* FileContentViewController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileContentViewController.mm; sourceTree = "<group>"; }; + 706EA5821855F8CC0043AAA6 /* ObjectViewController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ObjectViewController.mm; sourceTree = "<group>"; }; + 706EA5831855F8CC0043AAA6 /* FileContentViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileContentViewController.h; sourceTree = "<group>"; }; + 706EA5841855F8CC0043AAA6 /* SlideshowViewController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = SlideshowViewController.mm; sourceTree = "<group>"; }; + 706EA5851855F8CC0043AAA6 /* SearchViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SearchViewController.h; sourceTree = "<group>"; }; + 706EA5861855F8CC0043AAA6 /* SearchViewController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = SearchViewController.mm; sourceTree = "<group>"; }; + 706EA5871855F8CC0043AAA6 /* SlideshowViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SlideshowViewController.h; sourceTree = "<group>"; }; + 706EA5881855F8CC0043AAA6 /* ObjectViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ObjectViewController.h; sourceTree = "<group>"; }; + 706EA5991855FA310043AAA6 /* MainWindow.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = MainWindow.xib; sourceTree = "<group>"; }; + 706EA59D1855FBA30043AAA6 /* AxisFontInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AxisFontInspector.h; sourceTree = "<group>"; }; + 706EA59E1855FBA30043AAA6 /* AxisFontInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AxisFontInspector.mm; sourceTree = "<group>"; }; + 706EA59F1855FBA30043AAA6 /* AxisInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AxisInspector.h; sourceTree = "<group>"; }; + 706EA5A01855FBA30043AAA6 /* AxisInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AxisInspector.mm; sourceTree = "<group>"; }; + 706EA5A11855FBA30043AAA6 /* AxisLabelsInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AxisLabelsInspector.h; sourceTree = "<group>"; }; + 706EA5A21855FBA30043AAA6 /* AxisLabelsInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AxisLabelsInspector.mm; sourceTree = "<group>"; }; + 706EA5A31855FBA30043AAA6 /* AxisTicksInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AxisTicksInspector.h; sourceTree = "<group>"; }; + 706EA5A41855FBA30043AAA6 /* AxisTicksInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AxisTicksInspector.mm; sourceTree = "<group>"; }; + 706EA5A51855FBA30043AAA6 /* AxisTitleInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AxisTitleInspector.h; sourceTree = "<group>"; }; + 706EA5A61855FBA30043AAA6 /* AxisTitleInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = AxisTitleInspector.mm; sourceTree = "<group>"; }; + 706EA5A71855FBA30043AAA6 /* FilledAreaInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FilledAreaInspector.h; sourceTree = "<group>"; }; + 706EA5A81855FBA30043AAA6 /* FilledAreaInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FilledAreaInspector.mm; sourceTree = "<group>"; }; + 706EA5A91855FBA30043AAA6 /* H1BinsInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = H1BinsInspector.h; sourceTree = "<group>"; }; + 706EA5AA1855FBA30043AAA6 /* H1BinsInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = H1BinsInspector.mm; sourceTree = "<group>"; }; + 706EA5AB1855FBA30043AAA6 /* H1ErrorsInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = H1ErrorsInspector.h; sourceTree = "<group>"; }; + 706EA5AC1855FBA30043AAA6 /* H1ErrorsInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = H1ErrorsInspector.mm; sourceTree = "<group>"; }; + 706EA5AD1855FBA30043AAA6 /* H1Inspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = H1Inspector.h; sourceTree = "<group>"; }; + 706EA5AE1855FBA30043AAA6 /* H1Inspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = H1Inspector.mm; sourceTree = "<group>"; }; + 706EA5AF1855FBA30043AAA6 /* InspectorWithNavigation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorWithNavigation.h; sourceTree = "<group>"; }; + 706EA5B01855FBA30043AAA6 /* InspectorWithNavigation.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = InspectorWithNavigation.mm; sourceTree = "<group>"; }; + 706EA5B11855FBA30043AAA6 /* LineInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LineInspector.h; sourceTree = "<group>"; }; + 706EA5B21855FBA30043AAA6 /* LineInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = LineInspector.mm; sourceTree = "<group>"; }; + 706EA5B31855FBA30043AAA6 /* MarkerInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MarkerInspector.h; sourceTree = "<group>"; }; + 706EA5B41855FBA30043AAA6 /* MarkerInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MarkerInspector.mm; sourceTree = "<group>"; }; + 706EA5B51855FBA30043AAA6 /* ObjectInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ObjectInspector.h; sourceTree = "<group>"; }; + 706EA5B61855FBA30043AAA6 /* ObjectInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ObjectInspector.mm; sourceTree = "<group>"; }; + 706EA5B71855FBA30043AAA6 /* ObjectInspectorComponent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ObjectInspectorComponent.h; sourceTree = "<group>"; }; + 706EA5B81855FBA30043AAA6 /* PadInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadInspector.h; sourceTree = "<group>"; }; + 706EA5B91855FBA30043AAA6 /* PadInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadInspector.mm; sourceTree = "<group>"; }; + 706EA5BA1855FBA30043AAA6 /* PadLogScaleInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadLogScaleInspector.h; sourceTree = "<group>"; }; + 706EA5BB1855FBA30043AAA6 /* PadLogScaleInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadLogScaleInspector.mm; sourceTree = "<group>"; }; + 706EA5BC1855FBA30043AAA6 /* PadTicksGridInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PadTicksGridInspector.h; sourceTree = "<group>"; }; + 706EA5BD1855FBA30043AAA6 /* PadTicksGridInspector.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PadTicksGridInspector.mm; sourceTree = "<group>"; }; + 706EA5D01855FC5B0043AAA6 /* ColorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ColorCell.h; sourceTree = "<group>"; }; + 706EA5D11855FC5B0043AAA6 /* ColorCell.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ColorCell.mm; sourceTree = "<group>"; }; + 706EA5D21855FC5B0043AAA6 /* EditorPlateView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EditorPlateView.h; sourceTree = "<group>"; }; + 706EA5D31855FC5B0043AAA6 /* EditorPlateView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = EditorPlateView.mm; sourceTree = "<group>"; }; + 706EA5D41855FC5B0043AAA6 /* EditorView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EditorView.h; sourceTree = "<group>"; }; + 706EA5D51855FC5B0043AAA6 /* EditorView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = EditorView.mm; sourceTree = "<group>"; }; + 706EA5D61855FC5B0043AAA6 /* LineStyleCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LineStyleCell.h; sourceTree = "<group>"; }; + 706EA5D71855FC5B0043AAA6 /* LineStyleCell.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = LineStyleCell.mm; sourceTree = "<group>"; }; + 706EA5D81855FC5B0043AAA6 /* LineWidthCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LineWidthCell.h; sourceTree = "<group>"; }; + 706EA5D91855FC5B0043AAA6 /* LineWidthCell.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = LineWidthCell.mm; sourceTree = "<group>"; }; + 706EA5DA1855FC5B0043AAA6 /* LineWidthPicker.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LineWidthPicker.h; sourceTree = "<group>"; }; + 706EA5DB1855FC5B0043AAA6 /* LineWidthPicker.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = LineWidthPicker.mm; sourceTree = "<group>"; }; + 706EA5DC1855FC5B0043AAA6 /* MarkerStyleCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MarkerStyleCell.h; sourceTree = "<group>"; }; + 706EA5DD1855FC5B0043AAA6 /* MarkerStyleCell.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = MarkerStyleCell.mm; sourceTree = "<group>"; }; + 706EA5DE1855FC5B0043AAA6 /* PatternCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PatternCell.h; sourceTree = "<group>"; }; + 706EA5DF1855FC5B0043AAA6 /* PatternCell.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PatternCell.mm; sourceTree = "<group>"; }; + 706EA5E91855FD320043AAA6 /* AxisFontInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = AxisFontInspector.xib; sourceTree = "<group>"; }; + 706EA5EA1855FD320043AAA6 /* AxisInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = AxisInspector.xib; sourceTree = "<group>"; }; + 706EA5EB1855FD320043AAA6 /* AxisLabelsInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = AxisLabelsInspector.xib; sourceTree = "<group>"; }; + 706EA5EC1855FD320043AAA6 /* AxisTicksInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = AxisTicksInspector.xib; sourceTree = "<group>"; }; + 706EA5ED1855FD320043AAA6 /* AxisTitleInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = AxisTitleInspector.xib; sourceTree = "<group>"; }; + 706EA5EE1855FD320043AAA6 /* FilledAreaInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = FilledAreaInspector.xib; sourceTree = "<group>"; }; + 706EA5EF1855FD320043AAA6 /* H1BinsInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = H1BinsInspector.xib; sourceTree = "<group>"; }; + 706EA5F01855FD320043AAA6 /* H1ErrorsInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = H1ErrorsInspector.xib; sourceTree = "<group>"; }; + 706EA5F11855FD320043AAA6 /* H1Inspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = H1Inspector.xib; sourceTree = "<group>"; }; + 706EA5F21855FD320043AAA6 /* LineInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = LineInspector.xib; sourceTree = "<group>"; }; + 706EA5F31855FD320043AAA6 /* MarkerInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = MarkerInspector.xib; sourceTree = "<group>"; }; + 706EA5F41855FD320043AAA6 /* PadInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = PadInspector.xib; sourceTree = "<group>"; }; + 706EA5F51855FD320043AAA6 /* PadLogScaleInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = PadLogScaleInspector.xib; sourceTree = "<group>"; }; + 706EA5F61855FD320043AAA6 /* PadTicksGridInspector.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = PadTicksGridInspector.xib; sourceTree = "<group>"; }; + 706EA6061855FDEB0043AAA6 /* Constants.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Constants.h; sourceTree = "<group>"; }; + 706EA6071855FDEB0043AAA6 /* Constants.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = Constants.mm; sourceTree = "<group>"; }; + 706EA6081855FDEB0043AAA6 /* FileUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileUtils.h; sourceTree = "<group>"; }; + 706EA6091855FDEB0043AAA6 /* FileUtils.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileUtils.mm; sourceTree = "<group>"; }; + 706EA60A1855FDEB0043AAA6 /* Shortcuts.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Shortcuts.h; sourceTree = "<group>"; }; + 706EA60B1855FDEB0043AAA6 /* Shortcuts.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = Shortcuts.mm; sourceTree = "<group>"; }; + 706EA6111855FE610043AAA6 /* app_icon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = app_icon.png; sourceTree = "<group>"; }; + 706EA6121855FE610043AAA6 /* Default-Landscape.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-Landscape.png"; sourceTree = "<group>"; }; + 706EA6131855FE610043AAA6 /* Default-LandscapeLeft.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-LandscapeLeft.png"; sourceTree = "<group>"; }; + 706EA6141855FE610043AAA6 /* Default-LandscapeRight.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-LandscapeRight.png"; sourceTree = "<group>"; }; + 706EA6151855FE610043AAA6 /* Default-Portrait.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-Portrait.png"; sourceTree = "<group>"; }; + 706EA6161855FE610043AAA6 /* Default-PortraitUpsideDown.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-PortraitUpsideDown.png"; sourceTree = "<group>"; }; + 706EA61E1855FEEF0043AAA6 /* directory.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = directory.png; sourceTree = "<group>"; }; + 706EA61F1855FEEF0043AAA6 /* file_icon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = file_icon.png; sourceTree = "<group>"; }; + 706EA6201855FEEF0043AAA6 /* file_shortcut_background.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = file_shortcut_background.png; sourceTree = "<group>"; }; + 706EA625185601F30043AAA6 /* back_btn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = back_btn.png; sourceTree = "<group>"; }; + 706EA626185601F30043AAA6 /* brush_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = brush_tab.png; sourceTree = "<group>"; }; + 706EA627185601F30043AAA6 /* dec_line_width.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = dec_line_width.png; sourceTree = "<group>"; }; + 706EA628185601F30043AAA6 /* editor_plate.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = editor_plate.png; sourceTree = "<group>"; }; + 706EA629185601F30043AAA6 /* editor_state_arrow.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = editor_state_arrow.png; sourceTree = "<group>"; }; + 706EA62A185601F30043AAA6 /* forward_btn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = forward_btn.png; sourceTree = "<group>"; }; + 706EA62B185601F30043AAA6 /* h1_errors_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = h1_errors_tab.png; sourceTree = "<group>"; }; + 706EA62C185601F30043AAA6 /* h1_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = h1_tab.png; sourceTree = "<group>"; }; + 706EA62D185601F30043AAA6 /* inc_line_width.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = inc_line_width.png; sourceTree = "<group>"; }; + 706EA62E185601F30043AAA6 /* label_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = label_tab.png; sourceTree = "<group>"; }; + 706EA62F185601F30043AAA6 /* lg_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = lg_tab.png; sourceTree = "<group>"; }; + 706EA630185601F30043AAA6 /* line_cell.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = line_cell.png; sourceTree = "<group>"; }; + 706EA631185601F30043AAA6 /* line_style_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = line_style_tab.png; sourceTree = "<group>"; }; + 706EA632185601F30043AAA6 /* line_width_bkn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = line_width_bkn.png; sourceTree = "<group>"; }; + 706EA633185601F30043AAA6 /* minus_btn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = minus_btn.png; sourceTree = "<group>"; }; + 706EA634185601F30043AAA6 /* plus_btn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = plus_btn.png; sourceTree = "<group>"; }; + 706EA635185601F30043AAA6 /* separator.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = separator.png; sourceTree = "<group>"; }; + 706EA636185601F30043AAA6 /* text_cell_bkn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = text_cell_bkn.png; sourceTree = "<group>"; }; + 706EA637185601F30043AAA6 /* ticks_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = ticks_tab.png; sourceTree = "<group>"; }; + 706EA638185601F30043AAA6 /* title_tab.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = title_tab.png; sourceTree = "<group>"; }; + 706EA63A185601F30043AAA6 /* bar-background.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "bar-background.png"; sourceTree = "<group>"; }; + 706EA63B185601F30043AAA6 /* bar-highlight.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "bar-highlight.png"; sourceTree = "<group>"; }; + 706EA63C185601F30043AAA6 /* handle-hover.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "handle-hover.png"; sourceTree = "<group>"; }; + 706EA63D185601F30043AAA6 /* handle.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = handle.png; sourceTree = "<group>"; }; + 706EA63E185601F30043AAA6 /* picker_arrow.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = picker_arrow.png; sourceTree = "<group>"; }; + 706EA63F185601F30043AAA6 /* picker_bkn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = picker_bkn.png; sourceTree = "<group>"; }; + 706EA640185601F30043AAA6 /* picker_frame_bkn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = picker_frame_bkn.png; sourceTree = "<group>"; }; 7077901913FE50EB00C0FFA1 /* RootBrowser.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = RootBrowser.app; sourceTree = BUILT_PRODUCTS_DIR; }; 7077901D13FE50EB00C0FFA1 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; 7077901F13FE50EB00C0FFA1 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; @@ -238,38 +279,6 @@ 7077902513FE50EB00C0FFA1 /* root_browser-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "root_browser-Info.plist"; sourceTree = "<group>"; }; 7077902713FE50EB00C0FFA1 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; }; 7077902913FE50EB00C0FFA1 /* RootBrowser-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "RootBrowser-Prefix.pch"; sourceTree = "<group>"; }; - 7077902A13FE50EB00C0FFA1 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; }; - 7077902C13FE50EB00C0FFA1 /* root_browserAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = root_browserAppDelegate.h; sourceTree = "<group>"; }; - 7077902D13FE50EB00C0FFA1 /* root_browserAppDelegate.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = root_browserAppDelegate.mm; sourceTree = "<group>"; }; - 7077903013FE50EB00C0FFA1 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/MainWindow.xib; sourceTree = "<group>"; }; - 7077903713FE51B400C0FFA1 /* RootFileController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RootFileController.h; sourceTree = "<group>"; }; - 7077903813FE51B400C0FFA1 /* RootFileController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = RootFileController.mm; sourceTree = "<group>"; }; - 7077903913FE51B400C0FFA1 /* RootFileController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = RootFileController.xib; sourceTree = "<group>"; }; - 7077903C13FE549300C0FFA1 /* FileContentController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileContentController.h; sourceTree = "<group>"; }; - 7077903D13FE549300C0FFA1 /* FileContentController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileContentController.mm; sourceTree = "<group>"; }; - 7077903E13FE549300C0FFA1 /* FileContentController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = FileContentController.xib; sourceTree = "<group>"; }; - 7077904113FE554E00C0FFA1 /* FileShortcut.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileShortcut.h; sourceTree = "<group>"; }; - 7077904213FE554E00C0FFA1 /* FileShortcut.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileShortcut.mm; sourceTree = "<group>"; }; - 7077905013FE6B8F00C0FFA1 /* file_shortcut_background.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = file_shortcut_background.png; sourceTree = "<group>"; }; - 7077905A13FE840000C0FFA1 /* SlideshowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SlideshowController.h; sourceTree = "<group>"; }; - 7077905B13FE840000C0FFA1 /* SlideshowController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = SlideshowController.mm; sourceTree = "<group>"; }; - 7077905C13FE840000C0FFA1 /* SlideshowController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = SlideshowController.xib; sourceTree = "<group>"; }; - 7077905F13FE847600C0FFA1 /* ROOTObjectController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ROOTObjectController.h; sourceTree = "<group>"; }; - 7077906013FE847600C0FFA1 /* ROOTObjectController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ROOTObjectController.mm; sourceTree = "<group>"; }; - 7077906113FE847600C0FFA1 /* ROOTObjectController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = ROOTObjectController.xib; sourceTree = "<group>"; }; - 7077906413FE87D000C0FFA1 /* ObjectShortcut.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ObjectShortcut.h; sourceTree = "<group>"; }; - 7077906513FE87D000C0FFA1 /* ObjectShortcut.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ObjectShortcut.mm; sourceTree = "<group>"; }; - 7077906B13FE96C200C0FFA1 /* EditorView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = EditorView.mm; sourceTree = "<group>"; }; - 7077906C13FE96C200C0FFA1 /* EditorView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EditorView.h; sourceTree = "<group>"; }; - 7077906E13FE96C200C0FFA1 /* ScrollViewWithPickers.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ScrollViewWithPickers.mm; sourceTree = "<group>"; }; - 7077906F13FE96C200C0FFA1 /* EditorPlateView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = EditorPlateView.mm; sourceTree = "<group>"; }; - 7077907013FE96C200C0FFA1 /* ScrollViewWithPickers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScrollViewWithPickers.h; sourceTree = "<group>"; }; - 7077907713FE96C200C0FFA1 /* EditorPlateView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EditorPlateView.h; sourceTree = "<group>"; }; - 7077907913FE96C300C0FFA1 /* PatternCell.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PatternCell.mm; sourceTree = "<group>"; }; - 7077907A13FE96C300C0FFA1 /* PatternCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PatternCell.h; sourceTree = "<group>"; }; - 7077907B13FE96C300C0FFA1 /* ColorCell.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ColorCell.mm; sourceTree = "<group>"; }; - 7077907C13FE96C300C0FFA1 /* ColorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ColorCell.h; sourceTree = "<group>"; }; - 7077908913FE96DC00C0FFA1 /* editor_state_arrow.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = editor_state_arrow.png; sourceTree = "<group>"; }; 7077908D13FE972D00C0FFA1 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; 7077908F13FE973A00C0FFA1 /* CoreText.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreText.framework; path = System/Library/Frameworks/CoreText.framework; sourceTree = SDKROOT; }; 7095949813FE978400B9E8B6 /* libRoot.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libRoot.a; path = ../../../lib/libRoot.a; sourceTree = "<group>"; }; @@ -279,25 +288,7 @@ 709594A113FE978C00B9E8B6 /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libz.dylib; path = usr/lib/libz.dylib; sourceTree = SDKROOT; }; 709594A313FE97AF00B9E8B6 /* system.rootrc */ = {isa = PBXFileReference; lastKnownFileType = text; name = system.rootrc; path = ../../../etc/system.rootrc; sourceTree = "<group>"; }; 709594A413FE97AF00B9E8B6 /* system.plugins-ios */ = {isa = PBXFileReference; lastKnownFileType = text; name = "system.plugins-ios"; path = "../../../etc/system.plugins-ios"; sourceTree = "<group>"; }; - 70989EFB1473E73200515FC5 /* SpotView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SpotView.h; sourceTree = "<group>"; }; - 70989EFC1473E73200515FC5 /* SpotView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = SpotView.mm; sourceTree = "<group>"; }; 709CD05214025148005B2AF4 /* demos.root */ = {isa = PBXFileReference; lastKnownFileType = file; path = demos.root; sourceTree = "<group>"; }; - 709CD0961402768B005B2AF4 /* Shortcuts.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Shortcuts.h; sourceTree = "<group>"; }; - 709CD0971402768B005B2AF4 /* Shortcuts.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = Shortcuts.mm; sourceTree = "<group>"; }; - 70AC541C146966E7009A0942 /* ThumbnailView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = ThumbnailView.mm; sourceTree = "<group>"; }; - 70AC541D146966E7009A0942 /* ThumbnailView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ThumbnailView.h; sourceTree = "<group>"; }; - 70B2B408144C274800FAE3DD /* HorizontalPickerDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HorizontalPickerDelegate.h; sourceTree = "<group>"; }; - 70C1D67A1468162600514DC0 /* LineWidthCell.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = LineWidthCell.mm; sourceTree = "<group>"; }; - 70C1D67C1468166100514DC0 /* SlideView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = SlideView.mm; sourceTree = "<group>"; }; - 70E0B62014150F630077E4A8 /* back_btn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = back_btn.png; sourceTree = "<group>"; }; - 70E0B623141510880077E4A8 /* forward_btn.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = forward_btn.png; sourceTree = "<group>"; }; - 70E16B081455CBC00050C281 /* app_icon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = app_icon.png; sourceTree = "<group>"; }; - 70E36B551472965E004AEB6A /* FileContainerElement.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileContainerElement.h; sourceTree = "<group>"; }; - 70E36B561472965E004AEB6A /* FileContainerElement.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileContainerElement.mm; sourceTree = "<group>"; }; - 70E4FE5014715ABD00296BFF /* TransparentToolbar.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TransparentToolbar.h; sourceTree = "<group>"; }; - 70E4FE5114715ABD00296BFF /* TransparentToolbar.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TransparentToolbar.m; sourceTree = "<group>"; }; - 70E4FE591471685700296BFF /* SearchController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SearchController.h; sourceTree = "<group>"; }; - 70E4FE5A1471685700296BFF /* SearchController.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = SearchController.mm; sourceTree = "<group>"; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -322,318 +313,353 @@ /* End PBXFrameworksBuildPhase section */ /* Begin PBXGroup section */ - 706241CC1435F84400202121 /* Custom controls */ = { + 706EA53E1855F5290043AAA6 /* Src */ = { isa = PBXGroup; children = ( - 706241CE1435F86700202121 /* RangeSlider.mm */, - 706241CF1435F86700202121 /* RangeSlider.h */, - 70E4FE5014715ABD00296BFF /* TransparentToolbar.h */, - 70E4FE5114715ABD00296BFF /* TransparentToolbar.m */, + 706EA6051855FDEB0043AAA6 /* Utils */, + 706EA59B1855FBA30043AAA6 /* ObjectInspector */, + 706EA5611855F7E50043AAA6 /* Browser */, + 706EA5531855F6DA0043AAA6 /* CustomUI */, + 706EA53F1855F5290043AAA6 /* Core */, ); - name = "Custom controls"; + path = Src; sourceTree = "<group>"; }; - 7077900E13FE50EB00C0FFA1 = { + 706EA53F1855F5290043AAA6 /* Core */ = { isa = PBXGroup; children = ( - 706241CC1435F84400202121 /* Custom controls */, - 70360B19142C7AC6001F77E1 /* MessageUI.framework */, - 70E0B5E31414E4B80077E4A8 /* General */, - 70E0B5D81414E2B50077E4A8 /* Top level view controllers */, - 70E0B5D41414E0F10077E4A8 /* Object Inspector */, - 7077902313FE50EB00C0FFA1 /* root_browser */, - 7077901C13FE50EB00C0FFA1 /* Frameworks */, - 7077901A13FE50EB00C0FFA1 /* Products */, + 706EA5401855F5290043AAA6 /* main.mm */, + 706EA5411855F5290043AAA6 /* root_browserAppDelegate.h */, + 706EA5421855F5290043AAA6 /* root_browserAppDelegate.mm */, ); + path = Core; sourceTree = "<group>"; }; - 7077901A13FE50EB00C0FFA1 /* Products */ = { + 706EA5531855F6DA0043AAA6 /* CustomUI */ = { isa = PBXGroup; children = ( - 7077901913FE50EB00C0FFA1 /* RootBrowser.app */, + 706EA5541855F6DA0043AAA6 /* HorizontalPickerDelegate.h */, + 706EA5551855F6DA0043AAA6 /* HorizontalPickerView.h */, + 706EA5561855F6DA0043AAA6 /* HorizontalPickerView.mm */, + 706EA5571855F6DA0043AAA6 /* RangeSlider.h */, + 706EA5581855F6DA0043AAA6 /* RangeSlider.mm */, + 706EA5591855F6DA0043AAA6 /* ScrollViewWithPickers.h */, + 706EA55A1855F6DA0043AAA6 /* ScrollViewWithPickers.mm */, + 706EA55B1855F6DA0043AAA6 /* TransparentToolbar.h */, + 706EA55C1855F6DA0043AAA6 /* TransparentToolbar.m */, + ); + path = CustomUI; + sourceTree = "<group>"; + }; + 706EA5611855F7E50043AAA6 /* Browser */ = { + isa = PBXGroup; + children = ( + 706EA57C1855F8570043AAA6 /* FileContainerElement.h */, + 706EA57D1855F8570043AAA6 /* FileContainerElement.mm */, + 706EA5621855F7E50043AAA6 /* Controllers */, + 706EA5631855F7E50043AAA6 /* Views */, ); - name = Products; + path = Browser; sourceTree = "<group>"; }; - 7077901C13FE50EB00C0FFA1 /* Frameworks */ = { + 706EA5621855F7E50043AAA6 /* Controllers */ = { isa = PBXGroup; children = ( - 7077908F13FE973A00C0FFA1 /* CoreText.framework */, - 7077908D13FE972D00C0FFA1 /* QuartzCore.framework */, - 7077901D13FE50EB00C0FFA1 /* UIKit.framework */, - 7077901F13FE50EB00C0FFA1 /* Foundation.framework */, - 7077902113FE50EB00C0FFA1 /* CoreGraphics.framework */, + 706EA57F1855F8CC0043AAA6 /* FileCollectionViewController.mm */, + 706EA5801855F8CC0043AAA6 /* FileCollectionViewController.h */, + 706EA5811855F8CC0043AAA6 /* FileContentViewController.mm */, + 706EA5831855F8CC0043AAA6 /* FileContentViewController.h */, + 706EA5821855F8CC0043AAA6 /* ObjectViewController.mm */, + 706EA5881855F8CC0043AAA6 /* ObjectViewController.h */, + 706EA5841855F8CC0043AAA6 /* SlideshowViewController.mm */, + 706EA5871855F8CC0043AAA6 /* SlideshowViewController.h */, + 706EA5851855F8CC0043AAA6 /* SearchViewController.h */, + 706EA5861855F8CC0043AAA6 /* SearchViewController.mm */, + ); + path = Controllers; + sourceTree = "<group>"; + }; + 706EA5631855F7E50043AAA6 /* Views */ = { + isa = PBXGroup; + children = ( + 706EA5641855F7E50043AAA6 /* FileShortcutView.h */, + 706EA5651855F7E50043AAA6 /* FileShortcutView.mm */, + 706EA5661855F7E50043AAA6 /* ObjectShortcutView.h */, + 706EA5671855F7E50043AAA6 /* ObjectShortcutView.mm */, + 706EA5681855F7E50043AAA6 /* PadEditorScrollView.h */, + 706EA5691855F7E50043AAA6 /* PadEditorScrollView.mm */, + 706EA56A1855F7E50043AAA6 /* PadScrollView.h */, + 706EA56B1855F7E50043AAA6 /* PadScrollView.mm */, + 706EA56C1855F7E50043AAA6 /* PadSelectionView.h */, + 706EA56D1855F7E50043AAA6 /* PadSelectionView.mm */, + 706EA56E1855F7E50043AAA6 /* PadSlideView.h */, + 706EA56F1855F7E50043AAA6 /* PadSlideView.mm */, + 706EA5701855F7E50043AAA6 /* PadView.h */, + 706EA5711855F7E50043AAA6 /* PadView.mm */, + 706EA5721855F7E50043AAA6 /* SpotObjectView.h */, + 706EA5731855F7E50043AAA6 /* SpotObjectView.mm */, + ); + path = Views; + sourceTree = "<group>"; + }; + 706EA58E1855F9AB0043AAA6 /* UI */ = { + isa = PBXGroup; + children = ( + 706EA5E81855FD320043AAA6 /* ObjectInspector */, + 706EA5981855FA310043AAA6 /* Core */, + 706EA58F1855F9AB0043AAA6 /* Browser */, ); - name = Frameworks; + path = UI; sourceTree = "<group>"; }; - 7077902313FE50EB00C0FFA1 /* root_browser */ = { + 706EA58F1855F9AB0043AAA6 /* Browser */ = { isa = PBXGroup; children = ( - 7077902C13FE50EB00C0FFA1 /* root_browserAppDelegate.h */, - 7077902D13FE50EB00C0FFA1 /* root_browserAppDelegate.mm */, - 7077902F13FE50EB00C0FFA1 /* MainWindow.xib */, - 7077902413FE50EB00C0FFA1 /* Supporting Files */, + 7025582E1856060E00403763 /* Browser_iPad.storyboard */, ); - path = root_browser; + path = Browser; sourceTree = "<group>"; }; - 7077902413FE50EB00C0FFA1 /* Supporting Files */ = { + 706EA5981855FA310043AAA6 /* Core */ = { isa = PBXGroup; children = ( - 7077902513FE50EB00C0FFA1 /* root_browser-Info.plist */, - 7077902613FE50EB00C0FFA1 /* InfoPlist.strings */, - 7077902913FE50EB00C0FFA1 /* RootBrowser-Prefix.pch */, - 7077902A13FE50EB00C0FFA1 /* main.m */, + 706EA5991855FA310043AAA6 /* MainWindow.xib */, ); - name = "Supporting Files"; + path = Core; sourceTree = "<group>"; }; - 70E0B5D41414E0F10077E4A8 /* Object Inspector */ = { + 706EA59B1855FBA30043AAA6 /* ObjectInspector */ = { isa = PBXGroup; children = ( - 70E0B5E11414E4710077E4A8 /* Views */, - 70E0B5D71414E1510077E4A8 /* xibs */, - 70E0B5D61414E11C0077E4A8 /* Classes and protocols */, - 70E0B5D51414E1110077E4A8 /* Icons and pictures */, + 706EA5CF1855FC5B0043AAA6 /* Views */, + 706EA59C1855FBA30043AAA6 /* Controllers */, ); - name = "Object Inspector"; + path = ObjectInspector; sourceTree = "<group>"; }; - 70E0B5D51414E1110077E4A8 /* Icons and pictures */ = { + 706EA59C1855FBA30043AAA6 /* Controllers */ = { isa = PBXGroup; children = ( - 7068FF2A141A2F6A003560A1 /* text_cell_bkn.png */, - 7068FF1E1419FCBC003560A1 /* separator.png */, - 7073A28014179A6C001A0FE2 /* minus_btn.png */, - 7073A28114179A6D001A0FE2 /* plus_btn.png */, - 7023580C1434B48C00A95000 /* h1_tab.png */, - 7023580A1434ACC700A95000 /* h1_errors_tab.png */, - 7066FB3B1433470F00F88A2C /* label_tab.png */, - 7066FB391433459200F88A2C /* title_tab.png */, - 7066FB37143342C700F88A2C /* lg_tab.png */, - 7066FB35143341A900F88A2C /* ticks_tab.png */, - 7066FB3314333E7300F88A2C /* line_style_tab.png */, - 7066FB30143338AF00F88A2C /* brush_tab.png */, - 702BB9E314485E4200D3842F /* inc_line_width.png */, - 702BB9E11448584E00D3842F /* dec_line_width.png */, - 702BB9DF1448559A00D3842F /* line_width_bkn.png */, - 702BB9D514482E2200D3842F /* picker_arrow.png */, - 702BB9D614482E2200D3842F /* picker_frame_bkn.png */, - 7068963E1446F9FD00C2E3E7 /* picker_bkn.png */, - 706241D11435F94500202121 /* bar-background.png */, - 706241D21435F94500202121 /* bar-highlight.png */, - 706241D31435F94500202121 /* handle-hover.png */, - 706241D41435F94500202121 /* handle.png */, - 70E0B623141510880077E4A8 /* forward_btn.png */, - 70E0B62014150F630077E4A8 /* back_btn.png */, - 7077908913FE96DC00C0FFA1 /* editor_state_arrow.png */, - 70144128140E553C0070459F /* line_cell.png */, - 7077853114139EBF00450A1B /* editor_plate.png */, - ); - name = "Icons and pictures"; + 706EA59D1855FBA30043AAA6 /* AxisFontInspector.h */, + 706EA59E1855FBA30043AAA6 /* AxisFontInspector.mm */, + 706EA59F1855FBA30043AAA6 /* AxisInspector.h */, + 706EA5A01855FBA30043AAA6 /* AxisInspector.mm */, + 706EA5A11855FBA30043AAA6 /* AxisLabelsInspector.h */, + 706EA5A21855FBA30043AAA6 /* AxisLabelsInspector.mm */, + 706EA5A31855FBA30043AAA6 /* AxisTicksInspector.h */, + 706EA5A41855FBA30043AAA6 /* AxisTicksInspector.mm */, + 706EA5A51855FBA30043AAA6 /* AxisTitleInspector.h */, + 706EA5A61855FBA30043AAA6 /* AxisTitleInspector.mm */, + 706EA5A71855FBA30043AAA6 /* FilledAreaInspector.h */, + 706EA5A81855FBA30043AAA6 /* FilledAreaInspector.mm */, + 706EA5A91855FBA30043AAA6 /* H1BinsInspector.h */, + 706EA5AA1855FBA30043AAA6 /* H1BinsInspector.mm */, + 706EA5AB1855FBA30043AAA6 /* H1ErrorsInspector.h */, + 706EA5AC1855FBA30043AAA6 /* H1ErrorsInspector.mm */, + 706EA5AD1855FBA30043AAA6 /* H1Inspector.h */, + 706EA5AE1855FBA30043AAA6 /* H1Inspector.mm */, + 706EA5AF1855FBA30043AAA6 /* InspectorWithNavigation.h */, + 706EA5B01855FBA30043AAA6 /* InspectorWithNavigation.mm */, + 706EA5B11855FBA30043AAA6 /* LineInspector.h */, + 706EA5B21855FBA30043AAA6 /* LineInspector.mm */, + 706EA5B31855FBA30043AAA6 /* MarkerInspector.h */, + 706EA5B41855FBA30043AAA6 /* MarkerInspector.mm */, + 706EA5B51855FBA30043AAA6 /* ObjectInspector.h */, + 706EA5B61855FBA30043AAA6 /* ObjectInspector.mm */, + 706EA5B71855FBA30043AAA6 /* ObjectInspectorComponent.h */, + 706EA5B81855FBA30043AAA6 /* PadInspector.h */, + 706EA5B91855FBA30043AAA6 /* PadInspector.mm */, + 706EA5BA1855FBA30043AAA6 /* PadLogScaleInspector.h */, + 706EA5BB1855FBA30043AAA6 /* PadLogScaleInspector.mm */, + 706EA5BC1855FBA30043AAA6 /* PadTicksGridInspector.h */, + 706EA5BD1855FBA30043AAA6 /* PadTicksGridInspector.mm */, + ); + path = Controllers; sourceTree = "<group>"; }; - 70E0B5D61414E11C0077E4A8 /* Classes and protocols */ = { + 706EA5CF1855FC5B0043AAA6 /* Views */ = { isa = PBXGroup; children = ( - 702DDD161415FDDB009FC6F3 /* ObjectInspectorComponent.h */, - 702DDD181415FEA1009FC6F3 /* LineInspector.h */, - 702DDD191415FEA1009FC6F3 /* LineInspector.mm */, - 702DDD2714161789009FC6F3 /* InspectorWithNavigation.h */, - 702DDD2814161789009FC6F3 /* InspectorWithNavigation.mm */, - 70681C0A1416365900F8338A /* PadInspector.h */, - 70681C0B1416365900F8338A /* PadInspector.mm */, - 70681C0F14163A2300F8338A /* PadTicksGridInspector.h */, - 70681C1414163D3F00F8338A /* PadTicksGridInspector.mm */, - 70681C1614163F0C00F8338A /* PadLogScaleInspector.h */, - 70681C1714163F0C00F8338A /* PadLogScaleInspector.mm */, - 70681C1B1416474000F8338A /* FilledAreaInspector.h */, - 70681C1C1416474000F8338A /* FilledAreaInspector.mm */, - 70681C201416586D00F8338A /* ObjectInspector.h */, - 70681C211416586D00F8338A /* ObjectInspector.mm */, - 7073A272141757BB001A0FE2 /* AxisTicksInspector.h */, - 7073A273141757BB001A0FE2 /* AxisTicksInspector.mm */, - 7073A27B14177A03001A0FE2 /* AxisInspector.h */, - 7073A27C14177A03001A0FE2 /* AxisInspector.mm */, - 7073A2841417AA0F001A0FE2 /* AxisTitleInspector.h */, - 7073A2851417AA0F001A0FE2 /* AxisTitleInspector.mm */, - 7068FF21141A0EAF003560A1 /* AxisFontInspector.h */, - 7068FF22141A0EAF003560A1 /* AxisFontInspector.mm */, - 7068FF2E141A3943003560A1 /* AxisLabelsInspector.h */, - 7068FF2F141A3943003560A1 /* AxisLabelsInspector.mm */, - 702357DE1434658900A95000 /* H1Inspector.h */, - 702357DF1434658900A95000 /* H1Inspector.mm */, - 702357D814345C0A00A95000 /* H1ErrorsInspector.h */, - 702357D914345C0A00A95000 /* H1ErrorsInspector.mm */, - 70235800143494F400A95000 /* MarkerInspector.h */, - 70235801143494F400A95000 /* MarkerInspector.mm */, - 702358051434A93B00A95000 /* H1BinsInspector.h */, - 702358061434A93B00A95000 /* H1BinsInspector.mm */, - 70B2B408144C274800FAE3DD /* HorizontalPickerDelegate.h */, - ); - name = "Classes and protocols"; + 706EA5D01855FC5B0043AAA6 /* ColorCell.h */, + 706EA5D11855FC5B0043AAA6 /* ColorCell.mm */, + 706EA5D21855FC5B0043AAA6 /* EditorPlateView.h */, + 706EA5D31855FC5B0043AAA6 /* EditorPlateView.mm */, + 706EA5D41855FC5B0043AAA6 /* EditorView.h */, + 706EA5D51855FC5B0043AAA6 /* EditorView.mm */, + 706EA5D61855FC5B0043AAA6 /* LineStyleCell.h */, + 706EA5D71855FC5B0043AAA6 /* LineStyleCell.mm */, + 706EA5D81855FC5B0043AAA6 /* LineWidthCell.h */, + 706EA5D91855FC5B0043AAA6 /* LineWidthCell.mm */, + 706EA5DA1855FC5B0043AAA6 /* LineWidthPicker.h */, + 706EA5DB1855FC5B0043AAA6 /* LineWidthPicker.mm */, + 706EA5DC1855FC5B0043AAA6 /* MarkerStyleCell.h */, + 706EA5DD1855FC5B0043AAA6 /* MarkerStyleCell.mm */, + 706EA5DE1855FC5B0043AAA6 /* PatternCell.h */, + 706EA5DF1855FC5B0043AAA6 /* PatternCell.mm */, + ); + path = Views; sourceTree = "<group>"; }; - 70E0B5D71414E1510077E4A8 /* xibs */ = { + 706EA5E81855FD320043AAA6 /* ObjectInspector */ = { isa = PBXGroup; children = ( - 702DDD1A1415FEA1009FC6F3 /* LineInspector.xib */, - 70681C1D1416474000F8338A /* FilledAreaInspector.xib */, - 70681C0C1416365900F8338A /* PadInspector.xib */, - 70681C1814163F0C00F8338A /* PadLogScaleInspector.xib */, - 70681C1114163A2300F8338A /* PadTicksGridInspector.xib */, - 7073A274141757BB001A0FE2 /* AxisTicksInspector.xib */, - 7073A27D14177A03001A0FE2 /* AxisInspector.xib */, - 7073A2861417AA10001A0FE2 /* AxisTitleInspector.xib */, - 7068FF23141A0EAF003560A1 /* AxisFontInspector.xib */, - 7068FF30141A3944003560A1 /* AxisLabelsInspector.xib */, - 702357DA14345C0A00A95000 /* H1ErrorsInspector.xib */, - 702357E01434658900A95000 /* H1Inspector.xib */, - 702358071434A93C00A95000 /* H1BinsInspector.xib */, - 70235802143494F400A95000 /* MarkerInspector.xib */, - ); - name = xibs; + 706EA5E91855FD320043AAA6 /* AxisFontInspector.xib */, + 706EA5EA1855FD320043AAA6 /* AxisInspector.xib */, + 706EA5EB1855FD320043AAA6 /* AxisLabelsInspector.xib */, + 706EA5EC1855FD320043AAA6 /* AxisTicksInspector.xib */, + 706EA5ED1855FD320043AAA6 /* AxisTitleInspector.xib */, + 706EA5EE1855FD320043AAA6 /* FilledAreaInspector.xib */, + 706EA5EF1855FD320043AAA6 /* H1BinsInspector.xib */, + 706EA5F01855FD320043AAA6 /* H1ErrorsInspector.xib */, + 706EA5F11855FD320043AAA6 /* H1Inspector.xib */, + 706EA5F21855FD320043AAA6 /* LineInspector.xib */, + 706EA5F31855FD320043AAA6 /* MarkerInspector.xib */, + 706EA5F41855FD320043AAA6 /* PadInspector.xib */, + 706EA5F51855FD320043AAA6 /* PadLogScaleInspector.xib */, + 706EA5F61855FD320043AAA6 /* PadTicksGridInspector.xib */, + ); + path = ObjectInspector; sourceTree = "<group>"; }; - 70E0B5D81414E2B50077E4A8 /* Top level view controllers */ = { + 706EA6051855FDEB0043AAA6 /* Utils */ = { isa = PBXGroup; children = ( - 70E0B5DE1414E3FC0077E4A8 /* Views */, - 70E0B5DB1414E2FD0077E4A8 /* Classes */, - 70E0B5DA1414E2F00077E4A8 /* xibs */, - 70E0B5D91414E2E00077E4A8 /* Icons and pictures */, - ); - name = "Top level view controllers"; + 706EA6061855FDEB0043AAA6 /* Constants.h */, + 706EA6071855FDEB0043AAA6 /* Constants.mm */, + 706EA6081855FDEB0043AAA6 /* FileUtils.h */, + 706EA6091855FDEB0043AAA6 /* FileUtils.mm */, + 706EA60A1855FDEB0043AAA6 /* Shortcuts.h */, + 706EA60B1855FDEB0043AAA6 /* Shortcuts.mm */, + ); + path = Utils; sourceTree = "<group>"; }; - 70E0B5D91414E2E00077E4A8 /* Icons and pictures */ = { + 706EA60F1855FE610043AAA6 /* Images */ = { isa = PBXGroup; children = ( - 7077905013FE6B8F00C0FFA1 /* file_shortcut_background.png */, - 700ED6CA146BCDF100526D1C /* directory.png */, - 7023805D140514C8002A5331 /* file_icon.png */, + 706EA624185601F30043AAA6 /* ObjectInspector */, + 706EA639185601F30043AAA6 /* CustomUI */, + 706EA61D1855FEEF0043AAA6 /* Browser */, + 706EA6101855FE610043AAA6 /* Core */, ); - name = "Icons and pictures"; + path = Images; sourceTree = "<group>"; }; - 70E0B5DA1414E2F00077E4A8 /* xibs */ = { + 706EA6101855FE610043AAA6 /* Core */ = { isa = PBXGroup; children = ( - 7077905C13FE840000C0FFA1 /* SlideshowController.xib */, - 7077903913FE51B400C0FFA1 /* RootFileController.xib */, - 7077903E13FE549300C0FFA1 /* FileContentController.xib */, - 7077906113FE847600C0FFA1 /* ROOTObjectController.xib */, - ); - name = xibs; + 706EA6111855FE610043AAA6 /* app_icon.png */, + 706EA6121855FE610043AAA6 /* Default-Landscape.png */, + 706EA6131855FE610043AAA6 /* Default-LandscapeLeft.png */, + 706EA6141855FE610043AAA6 /* Default-LandscapeRight.png */, + 706EA6151855FE610043AAA6 /* Default-Portrait.png */, + 706EA6161855FE610043AAA6 /* Default-PortraitUpsideDown.png */, + ); + path = Core; sourceTree = "<group>"; }; - 70E0B5DB1414E2FD0077E4A8 /* Classes */ = { + 706EA61D1855FEEF0043AAA6 /* Browser */ = { isa = PBXGroup; children = ( - 7077905F13FE847600C0FFA1 /* ROOTObjectController.h */, - 7077906013FE847600C0FFA1 /* ROOTObjectController.mm */, - 7077903713FE51B400C0FFA1 /* RootFileController.h */, - 7077903813FE51B400C0FFA1 /* RootFileController.mm */, - 7077903C13FE549300C0FFA1 /* FileContentController.h */, - 7077903D13FE549300C0FFA1 /* FileContentController.mm */, - 7077905A13FE840000C0FFA1 /* SlideshowController.h */, - 7077905B13FE840000C0FFA1 /* SlideshowController.mm */, - ); - name = Classes; + 706EA61E1855FEEF0043AAA6 /* directory.png */, + 706EA61F1855FEEF0043AAA6 /* file_icon.png */, + 706EA6201855FEEF0043AAA6 /* file_shortcut_background.png */, + ); + path = Browser; sourceTree = "<group>"; }; - 70E0B5DE1414E3FC0077E4A8 /* Views */ = { + 706EA624185601F30043AAA6 /* ObjectInspector */ = { isa = PBXGroup; children = ( - 70AC541C146966E7009A0942 /* ThumbnailView.mm */, - 70AC541D146966E7009A0942 /* ThumbnailView.h */, - 7077904113FE554E00C0FFA1 /* FileShortcut.h */, - 7077904213FE554E00C0FFA1 /* FileShortcut.mm */, - 7077906413FE87D000C0FFA1 /* ObjectShortcut.h */, - 7077906513FE87D000C0FFA1 /* ObjectShortcut.mm */, - 7014410D140E18390070459F /* SelectionView.h */, - 7014410E140E18390070459F /* SelectionView.mm */, - 704B5A211520CC8D00FEF9C8 /* PadView.h */, - 70249BDA1403D644006A19E6 /* PadView.mm */, - 705A503414066421004C1C8B /* ScrollViewWithPadView.h */, - 705A503514066421004C1C8B /* ScrollViewWithPadView.mm */, - 705F1A66142347CA003045D9 /* SlideView.h */, - 70C1D67C1468166100514DC0 /* SlideView.mm */, - 7044980B1429D13D00E83799 /* PadImageScrollView.h */, - 7044980C1429D13D00E83799 /* PadImageScrollView.mm */, - 70E4FE591471685700296BFF /* SearchController.h */, - 70E4FE5A1471685700296BFF /* SearchController.mm */, - 70E36B551472965E004AEB6A /* FileContainerElement.h */, - 70E36B561472965E004AEB6A /* FileContainerElement.mm */, - 70989EFB1473E73200515FC5 /* SpotView.h */, - 70989EFC1473E73200515FC5 /* SpotView.mm */, - ); - name = Views; + 706EA625185601F30043AAA6 /* back_btn.png */, + 706EA626185601F30043AAA6 /* brush_tab.png */, + 706EA627185601F30043AAA6 /* dec_line_width.png */, + 706EA628185601F30043AAA6 /* editor_plate.png */, + 706EA629185601F30043AAA6 /* editor_state_arrow.png */, + 706EA62A185601F30043AAA6 /* forward_btn.png */, + 706EA62B185601F30043AAA6 /* h1_errors_tab.png */, + 706EA62C185601F30043AAA6 /* h1_tab.png */, + 706EA62D185601F30043AAA6 /* inc_line_width.png */, + 706EA62E185601F30043AAA6 /* label_tab.png */, + 706EA62F185601F30043AAA6 /* lg_tab.png */, + 706EA630185601F30043AAA6 /* line_cell.png */, + 706EA631185601F30043AAA6 /* line_style_tab.png */, + 706EA632185601F30043AAA6 /* line_width_bkn.png */, + 706EA633185601F30043AAA6 /* minus_btn.png */, + 706EA634185601F30043AAA6 /* plus_btn.png */, + 706EA635185601F30043AAA6 /* separator.png */, + 706EA636185601F30043AAA6 /* text_cell_bkn.png */, + 706EA637185601F30043AAA6 /* ticks_tab.png */, + 706EA638185601F30043AAA6 /* title_tab.png */, + ); + path = ObjectInspector; sourceTree = "<group>"; }; - 70E0B5E11414E4710077E4A8 /* Views */ = { + 706EA639185601F30043AAA6 /* CustomUI */ = { isa = PBXGroup; children = ( - 702BB9DA14482E3C00D3842F /* HorizontalPickerView.mm */, - 702BB9DB14482E3C00D3842F /* HorizontalPickerView.h */, - 7077906E13FE96C200C0FFA1 /* ScrollViewWithPickers.mm */, - 7077907013FE96C200C0FFA1 /* ScrollViewWithPickers.h */, - 7077906B13FE96C200C0FFA1 /* EditorView.mm */, - 7077906C13FE96C200C0FFA1 /* EditorView.h */, - 70144121140E3F320070459F /* LineWidthCell.h */, - 70C1D67A1468162600514DC0 /* LineWidthCell.mm */, - 7014411E140E3F1D0070459F /* LineStyleCell.h */, - 7014411F140E3F1D0070459F /* LineStyleCell.mm */, - 7077906F13FE96C200C0FFA1 /* EditorPlateView.mm */, - 7077907713FE96C200C0FFA1 /* EditorPlateView.h */, - 7077907913FE96C300C0FFA1 /* PatternCell.mm */, - 7077907A13FE96C300C0FFA1 /* PatternCell.h */, - 7077907B13FE96C300C0FFA1 /* ColorCell.mm */, - 7077907C13FE96C300C0FFA1 /* ColorCell.h */, - 702BB9E51448680100D3842F /* LineWidthPicker.h */, - 702BB9E61448680200D3842F /* LineWidthPicker.mm */, - 7053E8B4143B076F001C364D /* MarkerStyleCell.h */, - 7053E8B5143B076F001C364D /* MarkerStyleCell.mm */, - ); - name = Views; + 706EA63A185601F30043AAA6 /* bar-background.png */, + 706EA63B185601F30043AAA6 /* bar-highlight.png */, + 706EA63C185601F30043AAA6 /* handle-hover.png */, + 706EA63D185601F30043AAA6 /* handle.png */, + 706EA63E185601F30043AAA6 /* picker_arrow.png */, + 706EA63F185601F30043AAA6 /* picker_bkn.png */, + 706EA640185601F30043AAA6 /* picker_frame_bkn.png */, + ); + path = CustomUI; sourceTree = "<group>"; }; - 70E0B5E31414E4B80077E4A8 /* General */ = { + 7077900E13FE50EB00C0FFA1 = { isa = PBXGroup; children = ( - 70E0B5E71414E5200077E4A8 /* ROOT libs */, 70E0B5E61414E5080077E4A8 /* ROOT-related files */, - 70E0B5E51414E4ED0077E4A8 /* Icons and images */, - 70E0B5E41414E4C80077E4A8 /* Code */, + 70E0B5E71414E5200077E4A8 /* ROOT libs */, + 706EA60F1855FE610043AAA6 /* Images */, + 706EA58E1855F9AB0043AAA6 /* UI */, + 706EA53E1855F5290043AAA6 /* Src */, + 7077902313FE50EB00C0FFA1 /* root_browser */, + 7077901C13FE50EB00C0FFA1 /* Frameworks */, + 7077901A13FE50EB00C0FFA1 /* Products */, + ); + sourceTree = "<group>"; + }; + 7077901A13FE50EB00C0FFA1 /* Products */ = { + isa = PBXGroup; + children = ( + 7077901913FE50EB00C0FFA1 /* RootBrowser.app */, + ); + name = Products; + sourceTree = "<group>"; + }; + 7077901C13FE50EB00C0FFA1 /* Frameworks */ = { + isa = PBXGroup; + children = ( + 70360B19142C7AC6001F77E1 /* MessageUI.framework */, + 7077908F13FE973A00C0FFA1 /* CoreText.framework */, + 7077908D13FE972D00C0FFA1 /* QuartzCore.framework */, + 7077901D13FE50EB00C0FFA1 /* UIKit.framework */, + 7077901F13FE50EB00C0FFA1 /* Foundation.framework */, + 7077902113FE50EB00C0FFA1 /* CoreGraphics.framework */, ); - name = General; + name = Frameworks; sourceTree = "<group>"; }; - 70E0B5E41414E4C80077E4A8 /* Code */ = { + 7077902313FE50EB00C0FFA1 /* root_browser */ = { isa = PBXGroup; children = ( - 70078C2B146AC4C400C19F4D /* FileUtils.h */, - 70078C2C146AC4C400C19F4D /* FileUtils.cxx */, - 70252F7A140CDD8D00F3660F /* Constants.cxx */, - 70252F7B140CDD8D00F3660F /* Constants.h */, - 709CD0961402768B005B2AF4 /* Shortcuts.h */, - 709CD0971402768B005B2AF4 /* Shortcuts.mm */, - ); - name = Code; + 7077902413FE50EB00C0FFA1 /* Supporting Files */, + ); + path = root_browser; sourceTree = "<group>"; }; - 70E0B5E51414E4ED0077E4A8 /* Icons and images */ = { + 7077902413FE50EB00C0FFA1 /* Supporting Files */ = { isa = PBXGroup; children = ( - 70E16B081455CBC00050C281 /* app_icon.png */, - 7073A9A914277D16006F6D67 /* Default-Portrait.png */, - 7073A9AA14277D17006F6D67 /* Default-PortraitUpsideDown.png */, - 7073A9AB14277D18006F6D67 /* Default-Landscape.png */, - 7073A9AC14277D19006F6D67 /* Default-LandscapeLeft.png */, - 7073A9AD14277D1A006F6D67 /* Default-LandscapeRight.png */, - ); - name = "Icons and images"; + 7077902513FE50EB00C0FFA1 /* root_browser-Info.plist */, + 7077902613FE50EB00C0FFA1 /* InfoPlist.strings */, + 7077902913FE50EB00C0FFA1 /* RootBrowser-Prefix.pch */, + ); + name = "Supporting Files"; sourceTree = "<group>"; }; 70E0B5E61414E5080077E4A8 /* ROOT-related files */ = { @@ -684,7 +710,13 @@ 7077901013FE50EB00C0FFA1 /* Project object */ = { isa = PBXProject; attributes = { - LastUpgradeCheck = 0420; + LastUpgradeCheck = 0500; + ORGANIZATIONNAME = CERN; + TargetAttributes = { + 7077901813FE50EB00C0FFA1 = { + DevelopmentTeam = V5WJKFTQN5; + }; + }; }; buildConfigurationList = 7077901313FE50EB00C0FFA1 /* Build configuration list for PBXProject "RootBrowser" */; compatibilityVersion = "Xcode 3.2"; @@ -708,65 +740,62 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( - 70E16B091455CBC00050C281 /* app_icon.png in Resources */, - 702BB9E414485E4200D3842F /* inc_line_width.png in Resources */, - 702BB9E21448584E00D3842F /* dec_line_width.png in Resources */, - 702BB9E01448559A00D3842F /* line_width_bkn.png in Resources */, - 702BB9D714482E2200D3842F /* picker_arrow.png in Resources */, - 702BB9D814482E2200D3842F /* picker_frame_bkn.png in Resources */, - 7068963F1446F9FD00C2E3E7 /* picker_bkn.png in Resources */, - 706241D51435F94500202121 /* bar-background.png in Resources */, - 706241D61435F94500202121 /* bar-highlight.png in Resources */, - 706241D71435F94500202121 /* handle-hover.png in Resources */, - 706241D81435F94500202121 /* handle.png in Resources */, - 7023580D1434B48C00A95000 /* h1_tab.png in Resources */, - 7023580B1434ACC700A95000 /* h1_errors_tab.png in Resources */, - 7066FB3C1433470F00F88A2C /* label_tab.png in Resources */, - 7066FB3A1433459200F88A2C /* title_tab.png in Resources */, - 7066FB38143342C700F88A2C /* lg_tab.png in Resources */, - 7066FB36143341A900F88A2C /* ticks_tab.png in Resources */, - 7066FB3414333E7300F88A2C /* line_style_tab.png in Resources */, - 7066FB31143338AF00F88A2C /* brush_tab.png in Resources */, - 7073A9AE14277D1B006F6D67 /* Default-Portrait.png in Resources */, - 7073A9AF14277D1B006F6D67 /* Default-PortraitUpsideDown.png in Resources */, - 7073A9B014277D1B006F6D67 /* Default-Landscape.png in Resources */, - 7073A9B114277D1B006F6D67 /* Default-LandscapeLeft.png in Resources */, - 7073A9B214277D1B006F6D67 /* Default-LandscapeRight.png in Resources */, - 7068FF2B141A2F6A003560A1 /* text_cell_bkn.png in Resources */, - 7068FF1F1419FCBC003560A1 /* separator.png in Resources */, - 7073A28214179A6D001A0FE2 /* minus_btn.png in Resources */, - 7073A28314179A6D001A0FE2 /* plus_btn.png in Resources */, - 70E0B624141510880077E4A8 /* forward_btn.png in Resources */, - 70E0B62114150F630077E4A8 /* back_btn.png in Resources */, - 7077853214139EBF00450A1B /* editor_plate.png in Resources */, - 70144129140E553C0070459F /* line_cell.png in Resources */, - 7023805E140514C8002A5331 /* file_icon.png in Resources */, + 706EA64B185601F30043AAA6 /* lg_tab.png in Resources */, + 706EA65A185601F30043AAA6 /* picker_bkn.png in Resources */, + 706EA65B185601F30043AAA6 /* picker_frame_bkn.png in Resources */, + 706EA6221855FEEF0043AAA6 /* file_icon.png in Resources */, + 706EA645185601F30043AAA6 /* editor_state_arrow.png in Resources */, + 706EA5FD1855FD320043AAA6 /* H1BinsInspector.xib in Resources */, + 706EA652185601F30043AAA6 /* text_cell_bkn.png in Resources */, + 706EA6011855FD320043AAA6 /* MarkerInspector.xib in Resources */, + 706EA656185601F30043AAA6 /* bar-highlight.png in Resources */, + 706EA657185601F30043AAA6 /* handle-hover.png in Resources */, + 706EA64D185601F30043AAA6 /* line_style_tab.png in Resources */, + 706EA648185601F30043AAA6 /* h1_tab.png in Resources */, + 706EA644185601F30043AAA6 /* editor_plate.png in Resources */, + 706EA653185601F30043AAA6 /* ticks_tab.png in Resources */, + 706EA64C185601F30043AAA6 /* line_cell.png in Resources */, + 7025582F1856060E00403763 /* Browser_iPad.storyboard in Resources */, + 706EA6171855FE610043AAA6 /* app_icon.png in Resources */, + 706EA646185601F30043AAA6 /* forward_btn.png in Resources */, + 706EA64E185601F30043AAA6 /* line_width_bkn.png in Resources */, + 706EA647185601F30043AAA6 /* h1_errors_tab.png in Resources */, + 706EA654185601F30043AAA6 /* title_tab.png in Resources */, + 706EA5FB1855FD320043AAA6 /* AxisTitleInspector.xib in Resources */, + 706EA61C1855FE610043AAA6 /* Default-PortraitUpsideDown.png in Resources */, + 706EA655185601F30043AAA6 /* bar-background.png in Resources */, + 706EA5F71855FD320043AAA6 /* AxisFontInspector.xib in Resources */, + 706EA658185601F30043AAA6 /* handle.png in Resources */, + 706EA649185601F30043AAA6 /* inc_line_width.png in Resources */, + 706EA5FA1855FD320043AAA6 /* AxisTicksInspector.xib in Resources */, + 706EA5FC1855FD320043AAA6 /* FilledAreaInspector.xib in Resources */, + 706EA650185601F30043AAA6 /* plus_btn.png in Resources */, + 706EA642185601F30043AAA6 /* brush_tab.png in Resources */, + 706EA6211855FEEF0043AAA6 /* directory.png in Resources */, + 706EA64A185601F30043AAA6 /* label_tab.png in Resources */, + 706EA6031855FD320043AAA6 /* PadLogScaleInspector.xib in Resources */, + 706EA61B1855FE610043AAA6 /* Default-Portrait.png in Resources */, + 706EA6191855FE610043AAA6 /* Default-LandscapeLeft.png in Resources */, + 706EA61A1855FE610043AAA6 /* Default-LandscapeRight.png in Resources */, + 706EA5F91855FD320043AAA6 /* AxisLabelsInspector.xib in Resources */, + 706EA651185601F30043AAA6 /* separator.png in Resources */, + 706EA6021855FD320043AAA6 /* PadInspector.xib in Resources */, + 706EA643185601F30043AAA6 /* dec_line_width.png in Resources */, + 706EA5F81855FD320043AAA6 /* AxisInspector.xib in Resources */, + 706EA59A1855FA310043AAA6 /* MainWindow.xib in Resources */, + 706EA6231855FEEF0043AAA6 /* file_shortcut_background.png in Resources */, + 706EA641185601F30043AAA6 /* back_btn.png in Resources */, + 706EA6041855FD320043AAA6 /* PadTicksGridInspector.xib in Resources */, + 706EA5FF1855FD320043AAA6 /* H1Inspector.xib in Resources */, 709CD05314025148005B2AF4 /* demos.root in Resources */, + 706EA5FE1855FD320043AAA6 /* H1ErrorsInspector.xib in Resources */, + 706EA659185601F30043AAA6 /* picker_arrow.png in Resources */, 709594A513FE97AF00B9E8B6 /* system.rootrc in Resources */, 709594A613FE97AF00B9E8B6 /* system.plugins-ios in Resources */, - 7077908B13FE96DC00C0FFA1 /* editor_state_arrow.png in Resources */, - 7077905113FE6B8F00C0FFA1 /* file_shortcut_background.png in Resources */, + 706EA6001855FD320043AAA6 /* LineInspector.xib in Resources */, 7077902813FE50EB00C0FFA1 /* InfoPlist.strings in Resources */, - 7077903113FE50EB00C0FFA1 /* MainWindow.xib in Resources */, - 7077903B13FE51B400C0FFA1 /* RootFileController.xib in Resources */, - 7077904013FE549300C0FFA1 /* FileContentController.xib in Resources */, - 7077905E13FE840000C0FFA1 /* SlideshowController.xib in Resources */, - 7077906313FE847600C0FFA1 /* ROOTObjectController.xib in Resources */, - 702DDD1C1415FEA1009FC6F3 /* LineInspector.xib in Resources */, - 70681C0E1416365900F8338A /* PadInspector.xib in Resources */, - 70681C1314163A2300F8338A /* PadTicksGridInspector.xib in Resources */, - 70681C1A14163F0C00F8338A /* PadLogScaleInspector.xib in Resources */, - 70681C1F1416474000F8338A /* FilledAreaInspector.xib in Resources */, - 7073A276141757BC001A0FE2 /* AxisTicksInspector.xib in Resources */, - 7073A27F14177A03001A0FE2 /* AxisInspector.xib in Resources */, - 7073A2881417AA10001A0FE2 /* AxisTitleInspector.xib in Resources */, - 7068FF25141A0EAF003560A1 /* AxisFontInspector.xib in Resources */, - 7068FF32141A3944003560A1 /* AxisLabelsInspector.xib in Resources */, - 702357DC14345C0A00A95000 /* H1ErrorsInspector.xib in Resources */, - 702357E21434658900A95000 /* H1Inspector.xib in Resources */, - 70235804143494F400A95000 /* MarkerInspector.xib in Resources */, - 702358091434A93C00A95000 /* H1BinsInspector.xib in Resources */, - 700ED6CB146BCDF200526D1C /* directory.png in Resources */, + 706EA64F185601F30043AAA6 /* minus_btn.png in Resources */, + 706EA6181855FE610043AAA6 /* Default-Landscape.png in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -777,54 +806,53 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( - 7077902B13FE50EB00C0FFA1 /* main.m in Sources */, - 7077902E13FE50EB00C0FFA1 /* root_browserAppDelegate.mm in Sources */, - 7077903A13FE51B400C0FFA1 /* RootFileController.mm in Sources */, - 7077903F13FE549300C0FFA1 /* FileContentController.mm in Sources */, - 7077904313FE554E00C0FFA1 /* FileShortcut.mm in Sources */, - 7077905D13FE840000C0FFA1 /* SlideshowController.mm in Sources */, - 7077906213FE847600C0FFA1 /* ROOTObjectController.mm in Sources */, - 7077906613FE87D000C0FFA1 /* ObjectShortcut.mm in Sources */, - 7077907E13FE96C300C0FFA1 /* EditorView.mm in Sources */, - 7077908013FE96C300C0FFA1 /* ScrollViewWithPickers.mm in Sources */, - 7077908113FE96C300C0FFA1 /* EditorPlateView.mm in Sources */, - 7077908713FE96C300C0FFA1 /* PatternCell.mm in Sources */, - 7077908813FE96C300C0FFA1 /* ColorCell.mm in Sources */, - 709CD0981402768B005B2AF4 /* Shortcuts.mm in Sources */, - 70249BDC1403D644006A19E6 /* PadView.mm in Sources */, - 705A503614066421004C1C8B /* ScrollViewWithPadView.mm in Sources */, - 70252F7C140CDD8D00F3660F /* Constants.cxx in Sources */, - 7014410F140E18390070459F /* SelectionView.mm in Sources */, - 70144120140E3F1D0070459F /* LineStyleCell.mm in Sources */, - 702DDD1B1415FEA1009FC6F3 /* LineInspector.mm in Sources */, - 702DDD2914161789009FC6F3 /* InspectorWithNavigation.mm in Sources */, - 70681C0D1416365900F8338A /* PadInspector.mm in Sources */, - 70681C1514163D3F00F8338A /* PadTicksGridInspector.mm in Sources */, - 70681C1914163F0C00F8338A /* PadLogScaleInspector.mm in Sources */, - 70681C1E1416474000F8338A /* FilledAreaInspector.mm in Sources */, - 70681C221416586D00F8338A /* ObjectInspector.mm in Sources */, - 7073A275141757BC001A0FE2 /* AxisTicksInspector.mm in Sources */, - 7073A27E14177A03001A0FE2 /* AxisInspector.mm in Sources */, - 7073A2871417AA10001A0FE2 /* AxisTitleInspector.mm in Sources */, - 7068FF24141A0EAF003560A1 /* AxisFontInspector.mm in Sources */, - 7068FF31141A3944003560A1 /* AxisLabelsInspector.mm in Sources */, - 7044980D1429D13D00E83799 /* PadImageScrollView.mm in Sources */, - 702357DB14345C0A00A95000 /* H1ErrorsInspector.mm in Sources */, - 702357E11434658900A95000 /* H1Inspector.mm in Sources */, - 70235803143494F400A95000 /* MarkerInspector.mm in Sources */, - 702358081434A93C00A95000 /* H1BinsInspector.mm in Sources */, - 706241D01435F86700202121 /* RangeSlider.mm in Sources */, - 7053E8B6143B076F001C364D /* MarkerStyleCell.mm in Sources */, - 702BB9DC14482E3C00D3842F /* HorizontalPickerView.mm in Sources */, - 702BB9E71448680200D3842F /* LineWidthPicker.mm in Sources */, - 70C1D67B1468162600514DC0 /* LineWidthCell.mm in Sources */, - 70C1D67D1468166100514DC0 /* SlideView.mm in Sources */, - 70AC541E146966E7009A0942 /* ThumbnailView.mm in Sources */, - 70078C2D146AC4C400C19F4D /* FileUtils.cxx in Sources */, - 70E4FE5214715ABD00296BFF /* TransparentToolbar.m in Sources */, - 70E4FE5B1471685700296BFF /* SearchController.mm in Sources */, - 70E36B571472965E004AEB6A /* FileContainerElement.mm in Sources */, - 70989EFD1473E73200515FC5 /* SpotView.mm in Sources */, + 706EA5761855F7E50043AAA6 /* PadEditorScrollView.mm in Sources */, + 706EA55D1855F6DA0043AAA6 /* HorizontalPickerView.mm in Sources */, + 706EA58A1855F8CC0043AAA6 /* FileContentViewController.mm in Sources */, + 706EA5C31855FBA30043AAA6 /* AxisTitleInspector.mm in Sources */, + 706EA5CB1855FBA30043AAA6 /* ObjectInspector.mm in Sources */, + 706EA55F1855F6DA0043AAA6 /* ScrollViewWithPickers.mm in Sources */, + 706EA5431855F5290043AAA6 /* main.mm in Sources */, + 706EA5E51855FC5B0043AAA6 /* LineWidthPicker.mm in Sources */, + 706EA5741855F7E50043AAA6 /* FileShortcutView.mm in Sources */, + 706EA5C11855FBA30043AAA6 /* AxisLabelsInspector.mm in Sources */, + 706EA5C61855FBA30043AAA6 /* H1ErrorsInspector.mm in Sources */, + 706EA5CD1855FBA30043AAA6 /* PadLogScaleInspector.mm in Sources */, + 706EA58C1855F8CC0043AAA6 /* SlideshowViewController.mm in Sources */, + 706EA5771855F7E50043AAA6 /* PadScrollView.mm in Sources */, + 706EA57E1855F8570043AAA6 /* FileContainerElement.mm in Sources */, + 706EA55E1855F6DA0043AAA6 /* RangeSlider.mm in Sources */, + 706EA5601855F6DA0043AAA6 /* TransparentToolbar.m in Sources */, + 706EA60D1855FDEB0043AAA6 /* FileUtils.mm in Sources */, + 706EA5791855F7E50043AAA6 /* PadSlideView.mm in Sources */, + 706EA5C81855FBA30043AAA6 /* InspectorWithNavigation.mm in Sources */, + 706EA60C1855FDEB0043AAA6 /* Constants.mm in Sources */, + 706EA5C71855FBA30043AAA6 /* H1Inspector.mm in Sources */, + 706EA5891855F8CC0043AAA6 /* FileCollectionViewController.mm in Sources */, + 706EA5CE1855FBA30043AAA6 /* PadTicksGridInspector.mm in Sources */, + 706EA5CA1855FBA30043AAA6 /* MarkerInspector.mm in Sources */, + 706EA5C21855FBA30043AAA6 /* AxisTicksInspector.mm in Sources */, + 706EA5E71855FC5B0043AAA6 /* PatternCell.mm in Sources */, + 706EA58D1855F8CC0043AAA6 /* SearchViewController.mm in Sources */, + 706EA5C91855FBA30043AAA6 /* LineInspector.mm in Sources */, + 706EA5E01855FC5B0043AAA6 /* ColorCell.mm in Sources */, + 706EA5C41855FBA30043AAA6 /* FilledAreaInspector.mm in Sources */, + 706EA58B1855F8CC0043AAA6 /* ObjectViewController.mm in Sources */, + 706EA57A1855F7E50043AAA6 /* PadView.mm in Sources */, + 706EA5E31855FC5B0043AAA6 /* LineStyleCell.mm in Sources */, + 706EA5781855F7E50043AAA6 /* PadSelectionView.mm in Sources */, + 706EA5C51855FBA30043AAA6 /* H1BinsInspector.mm in Sources */, + 706EA5C01855FBA30043AAA6 /* AxisInspector.mm in Sources */, + 706EA5CC1855FBA30043AAA6 /* PadInspector.mm in Sources */, + 706EA5E21855FC5B0043AAA6 /* EditorView.mm in Sources */, + 706EA5751855F7E50043AAA6 /* ObjectShortcutView.mm in Sources */, + 706EA5E11855FC5B0043AAA6 /* EditorPlateView.mm in Sources */, + 706EA5441855F5290043AAA6 /* root_browserAppDelegate.mm in Sources */, + 706EA5E41855FC5B0043AAA6 /* LineWidthCell.mm in Sources */, + 706EA5E61855FC5B0043AAA6 /* MarkerStyleCell.mm in Sources */, + 706EA60E1855FDEB0043AAA6 /* Shortcuts.mm in Sources */, + 706EA57B1855F7E50043AAA6 /* SpotObjectView.mm in Sources */, + 706EA5BF1855FBA30043AAA6 /* AxisFontInspector.mm in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -839,33 +867,39 @@ name = InfoPlist.strings; sourceTree = "<group>"; }; - 7077902F13FE50EB00C0FFA1 /* MainWindow.xib */ = { - isa = PBXVariantGroup; - children = ( - 7077903013FE50EB00C0FFA1 /* en */, - ); - name = MainWindow.xib; - sourceTree = "<group>"; - }; /* End PBXVariantGroup section */ /* Begin XCBuildConfiguration section */ 7077903213FE50EB00C0FFA1 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_UNIVERSAL_IPHONE_OS)"; CLANG_CXX_LANGUAGE_STANDARD = "c++0x"; CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; - GCC_C_LANGUAGE_STANDARD = gnu99; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + GCC_C_LANGUAGE_STANDARD = "compiler-default"; GCC_OPTIMIZATION_LEVEL = 0; GCC_PREPROCESSOR_DEFINITIONS = DEBUG; GCC_SYMBOLS_PRIVATE_EXTERN = NO; - GCC_VERSION = com.apple.compilers.llvm.clang.1_0; + GCC_VERSION = ""; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_RETURN_TYPE = YES; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES; + GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 5.0; - OTHER_LDFLAGS = ../../../hist/hist/src/G__Hist.o; + IPHONEOS_DEPLOYMENT_TARGET = 7.0; + ONLY_ACTIVE_ARCH = YES; + OTHER_LDFLAGS = ""; + PROVISIONING_PROFILE = ""; SDKROOT = iphoneos; TARGETED_DEVICE_FAMILY = 2; }; @@ -874,19 +908,31 @@ 7077903313FE50EB00C0FFA1 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_UNIVERSAL_IPHONE_OS)"; CLANG_CXX_LANGUAGE_STANDARD = "c++0x"; CLANG_ENABLE_OBJC_ARC = YES; - "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; - GCC_C_LANGUAGE_STANDARD = gnu99; - GCC_VERSION = com.apple.compilers.llvm.clang.1_0; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Distribution"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; + GCC_C_LANGUAGE_STANDARD = "compiler-default"; + GCC_VERSION = ""; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_RETURN_TYPE = YES; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES; + GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 5.0; + IPHONEOS_DEPLOYMENT_TARGET = 7.0; OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1"; - OTHER_LDFLAGS = ../../../hist/hist/src/G__Hist.o; + OTHER_LDFLAGS = ""; + PROVISIONING_PROFILE = ""; SDKROOT = iphoneos; TARGETED_DEVICE_FAMILY = 2; + VALIDATE_PRODUCT = YES; }; name = Release; }; @@ -896,13 +942,15 @@ ALWAYS_SEARCH_USER_PATHS = NO; CLANG_CXX_LANGUAGE_STANDARD = "c++0x"; CLANG_ENABLE_OBJC_ARC = YES; + CODE_SIGN_IDENTITY = "iPhone Developer: Timur Pocheptsov (9HWLS7R4VJ)"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; COPY_PHASE_STRIP = NO; GCC_DYNAMIC_NO_PIC = NO; GCC_PRECOMPILE_PREFIX_HEADER = NO; GCC_PREFIX_HEADER = "root_browser/RootBrowser-Prefix.pch"; HEADER_SEARCH_PATHS = ../../../include; INFOPLIST_FILE = "root_browser/root_browser-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 5.0; + IPHONEOS_DEPLOYMENT_TARGET = 7.0; LIBRARY_SEARCH_PATHS = ../../../lib; OTHER_LDFLAGS = ( ../../../hist/hist/src/G__Hist.o, @@ -912,6 +960,7 @@ ../../../io/io/src/G__IO.o, ); PRODUCT_NAME = RootBrowser; + PROVISIONING_PROFILE = ""; WRAPPER_EXTENSION = app; }; name = Debug; @@ -922,12 +971,15 @@ ALWAYS_SEARCH_USER_PATHS = NO; CLANG_CXX_LANGUAGE_STANDARD = "c++0x"; CLANG_ENABLE_OBJC_ARC = YES; + CODE_SIGN_IDENTITY = "iPhone Developer: Timur Pocheptsov (9HWLS7R4VJ)"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; COPY_PHASE_STRIP = YES; + GCC_INLINES_ARE_PRIVATE_EXTERN = YES; GCC_PRECOMPILE_PREFIX_HEADER = NO; GCC_PREFIX_HEADER = "root_browser/RootBrowser-Prefix.pch"; HEADER_SEARCH_PATHS = ../../../include; INFOPLIST_FILE = "root_browser/root_browser-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 5.0; + IPHONEOS_DEPLOYMENT_TARGET = 7.0; LIBRARY_SEARCH_PATHS = ../../../lib; OTHER_LDFLAGS = ( ../../../hist/hist/src/G__Hist.o, @@ -937,6 +989,7 @@ ../../../io/io/src/G__IO.o, ); PRODUCT_NAME = RootBrowser; + PROVISIONING_PROFILE = ""; VALIDATE_PRODUCT = YES; WRAPPER_EXTENSION = app; }; diff --git a/test/ios/RootBrowser/RootFileController.h b/test/ios/RootBrowser/RootFileController.h deleted file mode 100644 index 0640fc430d648..0000000000000 --- a/test/ios/RootBrowser/RootFileController.h +++ /dev/null @@ -1,19 +0,0 @@ -#import <UIKit/UIKit.h> - -@class FileShortcut; - -@interface RootFileController : UIViewController <UINavigationControllerDelegate, UINavigationBarDelegate> { -@private - __weak IBOutlet UIScrollView *scrollView; - __weak IBOutlet UIView *fileOpenView; - __weak IBOutlet UITextField *fileNameField; -} - -- (void) fileWasSelected : (FileShortcut*)shortcut; -- (void) tryToDelete : (FileShortcut*)shortcut; -- (void) addRootFile : (NSString *)fileName; - -- (IBAction) textFieldDidEndOnExit : (id) sender; -- (IBAction) textFieldEditingDidEnd : (id) sender; - -@end diff --git a/test/ios/RootBrowser/RootFileController.mm b/test/ios/RootBrowser/RootFileController.mm deleted file mode 100644 index b0cb6774158bb..0000000000000 --- a/test/ios/RootBrowser/RootFileController.mm +++ /dev/null @@ -1,247 +0,0 @@ -#import <QuartzCore/QuartzCore.h> - -#import "FileContentController.h" -#import "RootFileController.h" -#import "FileShortcut.h" -#import "Shortcuts.h" - -//C++ imports. -#import "FileUtils.h" - -@interface RootFileController () <UIActionSheetDelegate> { -@private - NSMutableArray *fileContainers; - __weak FileShortcut *fileToDelete; -} - -- (void) hideFileOpenView; - -@end - -@implementation RootFileController - -//____________________________________________________________________________________________________ -- (id) initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil -{ - self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; - - if (self) { - [self view]; - - fileContainers = [[NSMutableArray alloc] init]; - - self.navigationItem.title = @"ROOT files"; - self.navigationItem.backBarButtonItem = [[UIBarButtonItem alloc] initWithTitle : @"Back to ROOT files" style:UIBarButtonItemStylePlain target : nil action : nil]; - self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc] initWithTitle : @"Open file" style:UIBarButtonItemStylePlain target : self action : @selector(showFileOpenView)]; - - scrollView.bounces = NO; - - [self.view bringSubviewToFront : fileOpenView]; - - fileNameField.clearButtonMode = UITextFieldViewModeAlways; - - UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(hideFileOpenView)]; - [self.view addGestureRecognizer : tap]; - } - - return self; -} - -//____________________________________________________________________________________________________ -- (void) didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle - -//____________________________________________________________________________________________________ -- (void) placeFileShortcuts -{ - if ([scrollView.subviews count]) - [ShorcutUtil placeShortcuts : fileContainers inScrollView : scrollView withSize : CGSizeMake([FileShortcut iconWidth], [FileShortcut iconHeight]) andSpace : 25.f]; -} - -//____________________________________________________________________________________________________ -- (void) correctFramesForOrientation : (UIInterfaceOrientation) orientation -{ - CGRect mainFrame; - CGRect scrollFrame; - CGRect fileViewFrame; - - if (UIInterfaceOrientationIsPortrait(orientation)) { - mainFrame = CGRectMake(0.f, 0.f, 768.f, 1004.f); - scrollFrame = CGRectMake(0.f, 44.f, 768.f, 960.f); - fileViewFrame = CGRectMake(0.f, 44.f, 768.f, 120.f); - } else { - mainFrame = CGRectMake(0.f, 0.f, 1024.f, 748.f); - scrollFrame = CGRectMake(0.f, 44.f, 1024.f, 704.f); - fileViewFrame = CGRectMake(0.f, 44.f, 1024.f, 120.f); - } - - self.view.frame = mainFrame; - scrollView.frame = scrollFrame; - - fileOpenView.frame = fileViewFrame; - - [self placeFileShortcuts]; -} - -//____________________________________________________________________________________________________ -- (void) viewWillAppear : (BOOL)animated -{ - [self correctFramesForOrientation : self.interfaceOrientation]; - [fileNameField resignFirstResponder]; - //Check if I have to call [super viewWillAppear]; -} - -//____________________________________________________________________________________________________ -- (void) viewDidLoad -{ - [super viewDidLoad]; -} - -//____________________________________________________________________________________________________ -- (void) viewDidUnload -{ - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} - -//____________________________________________________________________________________________________ -- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations - return YES; -} - -//____________________________________________________________________________________________________ -- (void)willAnimateRotationToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation duration : (NSTimeInterval) duration -{ - [self correctFramesForOrientation : interfaceOrientation]; -} - -#pragma mark - View management. - -//____________________________________________________________________________________________________ -- (void) addRootFile : (NSString *) fileName -{ - //Open the file and read its contents. - using namespace ROOT::iOS::Browser; - - FileContainer *fileContainer = FileContainer::CreateFileContainer([fileName cStringUsingEncoding : [NSString defaultCStringEncoding]]); - - if (!fileContainer) { - UIAlertView *alert = [[UIAlertView alloc] initWithTitle : @"File Open Error:" - message : [NSString stringWithFormat:@"Could not open %@", fileName] - delegate : nil - cancelButtonTitle : @"Close" - otherButtonTitles : nil]; - [alert show]; - return; - } - - const CGRect shortcutFrame = CGRectMake(0.f, 0.f, [FileShortcut iconWidth], [FileShortcut iconHeight]); - FileShortcut *newShortcut = [[FileShortcut alloc] initWithFrame : shortcutFrame controller : self fileContainer : fileContainer]; - if (newShortcut) {//What if alloc returned nil? - [fileContainers addObject : newShortcut]; - [scrollView addSubview : newShortcut]; - [self placeFileShortcuts]; - } else - FileContainer::DeleteFileContainer(fileContainer); -} - -//____________________________________________________________________________________________________ -- (void) fileWasSelected : (FileShortcut*) shortcut -{ - FileContentController *contentController = [[FileContentController alloc] initWithNibName : @"FileContentController" bundle : nil]; - [contentController activateForFile : [shortcut getFileContainer]]; - [self.navigationController pushViewController : contentController animated : YES]; -} - -//____________________________________________________________________________________________________ -- (void) tryToDelete : (FileShortcut*)shortcut -{ - NSString *message = [NSString stringWithFormat : @"Do you really want to close %@?", shortcut.fileName]; - UIActionSheet *dialog = [[UIActionSheet alloc] initWithTitle : message delegate : self cancelButtonTitle : @"Cancel" destructiveButtonTitle : @"Yes" otherButtonTitles : nil]; - fileToDelete = shortcut; - [dialog showInView : self.view]; -} - -#pragma mark - Action sheet delegate, delete the file. - -//____________________________________________________________________________________________________ -- (void)actionSheet : (UIActionSheet *)actionSheet didDismissWithButtonIndex : (NSInteger)buttonIndex -{ - if (!buttonIndex) { - [fileContainers removeObject:fileToDelete]; - [fileToDelete removeFromSuperview]; - [self correctFramesForOrientation : self.interfaceOrientation]; - } -} - -#pragma mark - File open operations. - -//____________________________________________________________________________________________________ -- (void) animateFileOpenView -{ - //Do animation. - // First create a CATransition object to describe the transition - CATransition *transition = [CATransition animation]; - transition.duration = 0.15; - // using the ease in/out timing function - transition.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseInEaseOut]; - // Now to set the type of transition. - transition.type = kCATransitionPush; - - if (!fileOpenView.hidden) - transition.subtype = kCATransitionFromBottom; - else - transition.subtype = kCATransitionFromTop; - transition.delegate = self; - // Next add it to the containerView's layer. This will perform the transition based on how we change its contents. - [fileOpenView.layer addAnimation : transition forKey : nil]; -} - -//____________________________________________________________________________________________________ -- (void) showFileOpenView -{ - fileOpenView.hidden = !fileOpenView.hidden; - // - [self animateFileOpenView]; - - if (!fileOpenView.hidden) - [fileNameField becomeFirstResponder]; - else - [fileNameField resignFirstResponder]; -} - -//____________________________________________________________________________________________________ -- (IBAction) textFieldDidEndOnExit : (id) sender -{ - NSString *filePath = fileNameField.text; - if (filePath) {//TODO - do I need this check? - [self addRootFile : filePath]; - } -} - -//____________________________________________________________________________________________________ -- (IBAction) textFieldEditingDidEnd : (id) sender -{ - [sender resignFirstResponder]; - fileOpenView.hidden = YES; - [self animateFileOpenView]; -} - -//____________________________________________________________________________________________________ -- (void) hideFileOpenView -{ - [fileNameField resignFirstResponder]; - fileOpenView.hidden = YES; - [self animateFileOpenView]; -} - -@end diff --git a/test/ios/RootBrowser/RootFileController.xib b/test/ios/RootBrowser/RootFileController.xib deleted file mode 100644 index 5f592103b7abf..0000000000000 --- a/test/ios/RootBrowser/RootFileController.xib +++ /dev/null @@ -1,398 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<archive type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="7.10"> - <data> - <int key="IBDocument.SystemTarget">1056</int> - <string key="IBDocument.SystemVersion">10K549</string> - <string key="IBDocument.InterfaceBuilderVersion">1305</string> - <string key="IBDocument.AppKitVersion">1038.36</string> - <string key="IBDocument.HIToolboxVersion">461.00</string> - <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> - <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string key="NS.object.0">300</string> - </object> - <object class="NSArray" key="IBDocument.IntegratedClassDependencies"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>IBUITextField</string> - <string>IBUIScrollView</string> - <string>IBUIView</string> - <string>IBUILabel</string> - <string>IBProxyObject</string> - </object> - <object class="NSArray" key="IBDocument.PluginDependencies"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - </object> - <object class="NSMutableDictionary" key="IBDocument.Metadata"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys" id="0"> - <bool key="EncodedWithXMLCoder">YES</bool> - </object> - <reference key="dict.values" ref="0"/> - </object> - <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBProxyObject" id="841351856"> - <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBProxyObject" id="606714003"> - <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBUIView" id="766721923"> - <reference key="NSNextResponder"/> - <int key="NSvFlags">256</int> - <object class="NSMutableArray" key="NSSubviews"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBUIScrollView" id="58112094"> - <reference key="NSNextResponder" ref="766721923"/> - <int key="NSvFlags">274</int> - <string key="NSFrame">{{0, 22}, {1024, 704}}</string> - <reference key="NSSuperview" ref="766721923"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="896283686"/> - <object class="NSColor" key="IBUIBackgroundColor"> - <int key="NSColorSpace">3</int> - <bytes key="NSWhite">MCAwAA</bytes> - </object> - <bool key="IBUIOpaque">NO</bool> - <bool key="IBUIClipsSubviews">YES</bool> - <bool key="IBUIMultipleTouchEnabled">YES</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBUIView" id="896283686"> - <reference key="NSNextResponder" ref="766721923"/> - <int key="NSvFlags">-2147483374</int> - <object class="NSMutableArray" key="NSSubviews"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBUITextField" id="523457554"> - <reference key="NSNextResponder" ref="896283686"/> - <int key="NSvFlags">258</int> - <string key="NSFrame">{{20, 69}, {360, 31}}</string> - <reference key="NSSuperview" ref="896283686"/> - <reference key="NSWindow"/> - <bool key="IBUIOpaque">NO</bool> - <bool key="IBUIClipsSubviews">YES</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <int key="IBUIContentVerticalAlignment">0</int> - <string key="IBUIText"/> - <int key="IBUIBorderStyle">3</int> - <object class="NSColor" key="IBUITextColor"> - <int key="NSColorSpace">3</int> - <bytes key="NSWhite">MAA</bytes> - <object class="NSColorSpace" key="NSCustomColorSpace"> - <int key="NSID">2</int> - </object> - </object> - <bool key="IBUIAdjustsFontSizeToFit">YES</bool> - <float key="IBUIMinimumFontSize">17</float> - <object class="IBUITextInputTraits" key="IBUITextInputTraits"> - <int key="IBUIKeyboardType">3</int> - <int key="IBUIReturnKeyType">1</int> - <bool key="IBUIEnablesReturnKeyAutomatically">YES</bool> - <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> - </object> - </object> - <object class="IBUILabel" id="273798198"> - <reference key="NSNextResponder" ref="896283686"/> - <int key="NSvFlags">256</int> - <string key="NSFrame">{{114, 28}, {172, 21}}</string> - <reference key="NSSuperview" ref="896283686"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="523457554"/> - <bool key="IBUIOpaque">NO</bool> - <bool key="IBUIClipsSubviews">YES</bool> - <int key="IBUIContentMode">7</int> - <bool key="IBUIUserInteractionEnabled">NO</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <string key="IBUIText">Enter the file name:</string> - <object class="NSColor" key="IBUITextColor"> - <int key="NSColorSpace">1</int> - <bytes key="NSRGB">MSAxIDEAA</bytes> - <object class="NSColorSpace" key="NSCustomColorSpace"> - <int key="NSID">1</int> - </object> - </object> - <nil key="IBUIHighlightedColor"/> - <int key="IBUIBaselineAdjustment">1</int> - <float key="IBUIMinimumFontSize">10</float> - <int key="IBUITextAlignment">1</int> - </object> - </object> - <string key="NSFrame">{{312, 314}, {400, 120}}</string> - <reference key="NSSuperview" ref="766721923"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="273798198"/> - <object class="NSColor" key="IBUIBackgroundColor"> - <int key="NSColorSpace">1</int> - <bytes key="NSRGB">MCAwIDAAA</bytes> - </object> - <bool key="IBUIOpaque">NO</bool> - <float key="IBUIAlpha">0.89999997615814209</float> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - </object> - <string key="NSFrame">{{0, 20}, {1024, 748}}</string> - <reference key="NSSuperview"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="58112094"/> - <object class="NSColor" key="IBUIBackgroundColor"> - <int key="NSColorSpace">3</int> - <bytes key="NSWhite">MC4zMzMzMzMzMzMzAA</bytes> - </object> - <bool key="IBUIClearsContextBeforeDrawing">NO</bool> - <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"> - <int key="IBUIStatusBarStyle">2</int> - </object> - <object class="IBUISimulatedOrientationMetrics" key="IBUISimulatedOrientationMetrics"> - <int key="IBUIInterfaceOrientation">3</int> - <int key="interfaceOrientation">3</int> - </object> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - </object> - <object class="IBObjectContainer" key="IBDocument.Objects"> - <object class="NSMutableArray" key="connectionRecords"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">scrollView</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="58112094"/> - </object> - <int key="connectionID">22</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">view</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="766721923"/> - </object> - <int key="connectionID">26</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">fileOpenView</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="896283686"/> - </object> - <int key="connectionID">31</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">fileNameField</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="523457554"/> - </object> - <int key="connectionID">32</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchEventConnection" key="connection"> - <string key="label">textFieldDidEndOnExit:</string> - <reference key="source" ref="523457554"/> - <reference key="destination" ref="841351856"/> - <int key="IBEventType">20</int> - </object> - <int key="connectionID">40</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchEventConnection" key="connection"> - <string key="label">textFieldEditingDidEnd:</string> - <reference key="source" ref="523457554"/> - <reference key="destination" ref="841351856"/> - <int key="IBEventType">19</int> - </object> - <int key="connectionID">41</int> - </object> - </object> - <object class="IBMutableOrderedSet" key="objectRecords"> - <object class="NSArray" key="orderedObjects"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBObjectRecord"> - <int key="objectID">0</int> - <reference key="object" ref="0"/> - <reference key="children" ref="1000"/> - <nil key="parent"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">-1</int> - <reference key="object" ref="841351856"/> - <reference key="parent" ref="0"/> - <string key="objectName">File's Owner</string> - </object> - <object class="IBObjectRecord"> - <int key="objectID">-2</int> - <reference key="object" ref="606714003"/> - <reference key="parent" ref="0"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">2</int> - <reference key="object" ref="766721923"/> - <object class="NSMutableArray" key="children"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="896283686"/> - <reference ref="58112094"/> - </object> - <reference key="parent" ref="0"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">27</int> - <reference key="object" ref="896283686"/> - <object class="NSMutableArray" key="children"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="523457554"/> - <reference ref="273798198"/> - </object> - <reference key="parent" ref="766721923"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">29</int> - <reference key="object" ref="273798198"/> - <reference key="parent" ref="896283686"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">28</int> - <reference key="object" ref="523457554"/> - <reference key="parent" ref="896283686"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">18</int> - <reference key="object" ref="58112094"/> - <reference key="parent" ref="766721923"/> - </object> - </object> - </object> - <object class="NSMutableDictionary" key="flattenedProperties"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>-1.CustomClassName</string> - <string>-2.CustomClassName</string> - <string>18.IBPluginDependency</string> - <string>2.IBEditorWindowLastContentRect</string> - <string>2.IBPluginDependency</string> - <string>27.IBPluginDependency</string> - <string>28.IBPluginDependency</string> - <string>29.IBPluginDependency</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>RootFileController</string> - <string>UIResponder</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>{{353, 156}, {1024, 768}}</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - </object> - </object> - <object class="NSMutableDictionary" key="unlocalizedProperties"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference key="dict.sortedKeys" ref="0"/> - <reference key="dict.values" ref="0"/> - </object> - <nil key="activeLocalization"/> - <object class="NSMutableDictionary" key="localizations"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference key="dict.sortedKeys" ref="0"/> - <reference key="dict.values" ref="0"/> - </object> - <nil key="sourceID"/> - <int key="maxID">41</int> - </object> - <object class="IBClassDescriber" key="IBDocument.Classes"> - <object class="NSMutableArray" key="referencedPartialClassDescriptions"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBPartialClassDescription"> - <string key="className">RootFileController</string> - <string key="superclassName">UIViewController</string> - <object class="NSMutableDictionary" key="actions"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>textFieldDidEndOnExit:</string> - <string>textFieldEditingDidDone:</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>id</string> - <string>id</string> - </object> - </object> - <object class="NSMutableDictionary" key="actionInfosByName"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>textFieldDidEndOnExit:</string> - <string>textFieldEditingDidDone:</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBActionInfo"> - <string key="name">textFieldDidEndOnExit:</string> - <string key="candidateClassName">id</string> - </object> - <object class="IBActionInfo"> - <string key="name">textFieldEditingDidDone:</string> - <string key="candidateClassName">id</string> - </object> - </object> - </object> - <object class="NSMutableDictionary" key="outlets"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>fileNameField</string> - <string>fileOpenView</string> - <string>scrollView</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>UITextField</string> - <string>UIView</string> - <string>UIScrollView</string> - </object> - </object> - <object class="NSMutableDictionary" key="toOneOutletInfosByName"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>fileNameField</string> - <string>fileOpenView</string> - <string>scrollView</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBToOneOutletInfo"> - <string key="name">fileNameField</string> - <string key="candidateClassName">UITextField</string> - </object> - <object class="IBToOneOutletInfo"> - <string key="name">fileOpenView</string> - <string key="candidateClassName">UIView</string> - </object> - <object class="IBToOneOutletInfo"> - <string key="name">scrollView</string> - <string key="candidateClassName">UIScrollView</string> - </object> - </object> - </object> - <object class="IBClassDescriptionSource" key="sourceIdentifier"> - <string key="majorKey">IBProjectSource</string> - <string key="minorKey">./Classes/RootFileController.h</string> - </object> - </object> - </object> - </object> - <int key="IBDocument.localizationMode">0</int> - <string key="IBDocument.TargetRuntimeIdentifier">IBIPadFramework</string> - <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies"> - <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string> - <integer value="3100" key="NS.object.0"/> - </object> - <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> - <int key="IBDocument.defaultPropertyAccessControl">3</int> - <string key="IBCocoaTouchPluginVersion">300</string> - </data> -</archive> diff --git a/test/ios/RootBrowser/ScrollViewWithPadView.h b/test/ios/RootBrowser/ScrollViewWithPadView.h deleted file mode 100644 index 2a546bf69a121..0000000000000 --- a/test/ios/RootBrowser/ScrollViewWithPadView.h +++ /dev/null @@ -1,8 +0,0 @@ -/* -This is scroll-view for pad in editable mode. -TODO: Find better class name. -*/ -#import <UIKit/UIKit.h> - -@interface ScrollViewWithPadView : UIScrollView -@end diff --git a/test/ios/RootBrowser/SearchController.h b/test/ios/RootBrowser/SearchController.h deleted file mode 100644 index 3de47b9a77a40..0000000000000 --- a/test/ios/RootBrowser/SearchController.h +++ /dev/null @@ -1,19 +0,0 @@ -#import <UIKit/UIKit.h> - -@class FileContainerElement; -@class SearchController; - -@protocol SearchDelegate -- (void) searchesController : (SearchController *)controller didSelectKey : (FileContainerElement *)key; -@end - - -@interface SearchController : UITableViewController - -@property (nonatomic, weak) id<SearchDelegate> delegate; -@property (nonatomic, retain) NSMutableArray *keys; - -- (void) filterResultsUsingString : (NSString *)filterString; - - -@end diff --git a/test/ios/RootBrowser/SelectionView.h b/test/ios/RootBrowser/SelectionView.h deleted file mode 100644 index 9e79ef5567695..0000000000000 --- a/test/ios/RootBrowser/SelectionView.h +++ /dev/null @@ -1,21 +0,0 @@ -#import <UIKit/UIKit.h> - -namespace ROOT { -namespace iOS { - -class Pad; - -} -} - -@interface SelectionView : UIView - -@property (nonatomic, assign) BOOL panActive; -@property (nonatomic, assign) CGPoint panStart; -@property (nonatomic, assign) CGPoint currentPanPoint; -@property (nonatomic, assign) BOOL verticalPanDirection; - -- (id)initWithFrame : (CGRect)frame withPad : (ROOT::iOS::Pad *)p; -- (void) setPad : (ROOT::iOS::Pad *)p; - -@end diff --git a/test/ios/RootBrowser/Shortcuts.h b/test/ios/RootBrowser/Shortcuts.h deleted file mode 100644 index 02c02ea7d10e3..0000000000000 --- a/test/ios/RootBrowser/Shortcuts.h +++ /dev/null @@ -1,19 +0,0 @@ -// -// Shortcuts.h -// root_browser -// -// Created by Timur Pocheptsov on 8/22/11. -// Copyright 2011 __MyCompanyName__. All rights reserved. -// - -#import <UIKit/UIKit.h> - - -@interface ShorcutUtil : NSObject { -} - -+(void) placeShortcuts :(NSMutableArray *)shortcuts inScrollView : (UIScrollView *) scrollView withSize : (CGSize) size andSpace : (CGFloat) space; - -@end - - diff --git a/test/ios/RootBrowser/SlideView.h b/test/ios/RootBrowser/SlideView.h deleted file mode 100644 index 7bf9139fad6b7..0000000000000 --- a/test/ios/RootBrowser/SlideView.h +++ /dev/null @@ -1,19 +0,0 @@ -#import <UIKit/UIKit.h> - -namespace ROOT { -namespace iOS { - -class Pad; - -} -} - -@interface SlideView : UIView - -+ (CGSize) slideSize; -+ (CGRect) slideFrame; - -- (id) initWithFrame : (CGRect)rect; -- (void) setPad : (ROOT::iOS::Pad *)pad; - -@end diff --git a/test/ios/RootBrowser/SlideshowController.h b/test/ios/RootBrowser/SlideshowController.h deleted file mode 100644 index 4a4b917c59d12..0000000000000 --- a/test/ios/RootBrowser/SlideshowController.h +++ /dev/null @@ -1,21 +0,0 @@ -#import <UIKit/UIKit.h> - -namespace ROOT { -namespace iOS { -namespace Browser { - -class FileContainer; - -} -} -} - -@interface SlideshowController : UIViewController <UIScrollViewDelegate> { -@private - __weak IBOutlet UIView *parentView; - __weak IBOutlet UIView *padParentView; -} - -- (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil fileContainer : (ROOT::iOS::Browser::FileContainer *)container; - -@end diff --git a/test/ios/RootBrowser/SlideshowController.xib b/test/ios/RootBrowser/SlideshowController.xib deleted file mode 100644 index 75c14bdad7dc9..0000000000000 --- a/test/ios/RootBrowser/SlideshowController.xib +++ /dev/null @@ -1,261 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<archive type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="7.10"> - <data> - <int key="IBDocument.SystemTarget">1056</int> - <string key="IBDocument.SystemVersion">11B26</string> - <string key="IBDocument.InterfaceBuilderVersion">1617</string> - <string key="IBDocument.AppKitVersion">1138</string> - <string key="IBDocument.HIToolboxVersion">566.00</string> - <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> - <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string key="NS.object.0">534</string> - </object> - <object class="NSArray" key="IBDocument.IntegratedClassDependencies"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>IBProxyObject</string> - <string>IBUIView</string> - </object> - <object class="NSArray" key="IBDocument.PluginDependencies"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - </object> - <object class="NSMutableDictionary" key="IBDocument.Metadata"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys" id="0"> - <bool key="EncodedWithXMLCoder">YES</bool> - </object> - <reference key="dict.values" ref="0"/> - </object> - <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBProxyObject" id="841351856"> - <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBProxyObject" id="606714003"> - <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBUIView" id="766721923"> - <reference key="NSNextResponder"/> - <int key="NSvFlags">256</int> - <object class="NSMutableArray" key="NSSubviews"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBUIView" id="117742838"> - <reference key="NSNextResponder" ref="766721923"/> - <int key="NSvFlags">274</int> - <object class="NSMutableArray" key="NSSubviews"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBUIView" id="1059278677"> - <reference key="NSNextResponder" ref="117742838"/> - <int key="NSvFlags">274</int> - <string key="NSFrame">{{46, -37}, {1024, 709}}</string> - <reference key="NSSuperview" ref="117742838"/> - <reference key="NSWindow"/> - <string key="NSReuseIdentifierKey">_NS:195</string> - <object class="NSColor" key="IBUIBackgroundColor"> - <int key="NSColorSpace">3</int> - <bytes key="NSWhite">MQA</bytes> - <object class="NSColorSpace" key="NSCustomColorSpace"> - <int key="NSID">2</int> - </object> - </object> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - </object> - <string key="NSFrame">{{0, 28}, {1024, 709}}</string> - <reference key="NSSuperview" ref="766721923"/> - <reference key="NSWindow"/> - <string key="NSReuseIdentifierKey">_NS:195</string> - <object class="NSColor" key="IBUIBackgroundColor" id="2031227"> - <int key="NSColorSpace">3</int> - <bytes key="NSWhite">MC4zMzMzMzMzMzMzAA</bytes> - </object> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - </object> - <string key="NSFrame">{{0, 20}, {1024, 748}}</string> - <reference key="NSSuperview"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="117742838"/> - <reference key="IBUIBackgroundColor" ref="2031227"/> - <bool key="IBUIClearsContextBeforeDrawing">NO</bool> - <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"> - <int key="IBUIStatusBarStyle">2</int> - </object> - <object class="IBUISimulatedOrientationMetrics" key="IBUISimulatedOrientationMetrics"> - <int key="IBUIInterfaceOrientation">3</int> - <int key="interfaceOrientation">3</int> - </object> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - </object> - <object class="IBObjectContainer" key="IBDocument.Objects"> - <object class="NSMutableArray" key="connectionRecords"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">parentView</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="117742838"/> - </object> - <int key="connectionID">20</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">view</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="766721923"/> - </object> - <int key="connectionID">21</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">padParentView</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="1059278677"/> - </object> - <int key="connectionID">23</int> - </object> - </object> - <object class="IBMutableOrderedSet" key="objectRecords"> - <object class="NSArray" key="orderedObjects"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBObjectRecord"> - <int key="objectID">0</int> - <reference key="object" ref="0"/> - <reference key="children" ref="1000"/> - <nil key="parent"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">-1</int> - <reference key="object" ref="841351856"/> - <reference key="parent" ref="0"/> - <string key="objectName">File's Owner</string> - </object> - <object class="IBObjectRecord"> - <int key="objectID">-2</int> - <reference key="object" ref="606714003"/> - <reference key="parent" ref="0"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">2</int> - <reference key="object" ref="766721923"/> - <object class="NSMutableArray" key="children"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="117742838"/> - </object> - <reference key="parent" ref="0"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">18</int> - <reference key="object" ref="117742838"/> - <object class="NSMutableArray" key="children"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="1059278677"/> - </object> - <reference key="parent" ref="766721923"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">22</int> - <reference key="object" ref="1059278677"/> - <object class="NSMutableArray" key="children"> - <bool key="EncodedWithXMLCoder">YES</bool> - </object> - <reference key="parent" ref="117742838"/> - </object> - </object> - </object> - <object class="NSMutableDictionary" key="flattenedProperties"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>-1.CustomClassName</string> - <string>-1.IBPluginDependency</string> - <string>-2.CustomClassName</string> - <string>-2.IBPluginDependency</string> - <string>18.IBPluginDependency</string> - <string>2.IBPluginDependency</string> - <string>22.IBPluginDependency</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>SlideshowController</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>UIResponder</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - </object> - </object> - <object class="NSMutableDictionary" key="unlocalizedProperties"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference key="dict.sortedKeys" ref="0"/> - <reference key="dict.values" ref="0"/> - </object> - <nil key="activeLocalization"/> - <object class="NSMutableDictionary" key="localizations"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference key="dict.sortedKeys" ref="0"/> - <reference key="dict.values" ref="0"/> - </object> - <nil key="sourceID"/> - <int key="maxID">25</int> - </object> - <object class="IBClassDescriber" key="IBDocument.Classes"> - <object class="NSMutableArray" key="referencedPartialClassDescriptions"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBPartialClassDescription"> - <string key="className">SlideshowController</string> - <string key="superclassName">UIViewController</string> - <object class="NSMutableDictionary" key="outlets"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>padParentView</string> - <string>parentView</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>UIView</string> - <string>UIView</string> - </object> - </object> - <object class="NSMutableDictionary" key="toOneOutletInfosByName"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>padParentView</string> - <string>parentView</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBToOneOutletInfo"> - <string key="name">padParentView</string> - <string key="candidateClassName">UIView</string> - </object> - <object class="IBToOneOutletInfo"> - <string key="name">parentView</string> - <string key="candidateClassName">UIView</string> - </object> - </object> - </object> - <object class="IBClassDescriptionSource" key="sourceIdentifier"> - <string key="majorKey">IBProjectSource</string> - <string key="minorKey">./Classes/SlideshowController.h</string> - </object> - </object> - </object> - </object> - <int key="IBDocument.localizationMode">0</int> - <string key="IBDocument.TargetRuntimeIdentifier">IBIPadFramework</string> - <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies"> - <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string> - <integer value="3100" key="NS.object.0"/> - </object> - <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> - <int key="IBDocument.defaultPropertyAccessControl">3</int> - <string key="IBCocoaTouchPluginVersion">534</string> - </data> -</archive> diff --git a/test/ios/RootBrowser/SpotView.h b/test/ios/RootBrowser/SpotView.h deleted file mode 100644 index dacf3342dd635..0000000000000 --- a/test/ios/RootBrowser/SpotView.h +++ /dev/null @@ -1,5 +0,0 @@ -#import <UIKit/UIKit.h> - -@interface SpotView : UIView - -@end diff --git a/test/ios/RootBrowser/SpotView.mm b/test/ios/RootBrowser/SpotView.mm deleted file mode 100644 index 6a4ff24be6cff..0000000000000 --- a/test/ios/RootBrowser/SpotView.mm +++ /dev/null @@ -1,18 +0,0 @@ -#import <CoreGraphics/CGContext.h> - -#import "SpotView.h" - -@implementation SpotView - -- (id)initWithFrame:(CGRect)frame -{ - if ([super initWithFrame : frame]) { - self.alpha = 0.f; - self.multipleTouchEnabled = NO; - self.backgroundColor = [UIColor orangeColor]; - } - - return self; -} - -@end diff --git a/test/ios/RootBrowser/Src/Browser/Controllers/FileCollectionViewController.h b/test/ios/RootBrowser/Src/Browser/Controllers/FileCollectionViewController.h new file mode 100644 index 0000000000000..121db78fb57b1 --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Controllers/FileCollectionViewController.h @@ -0,0 +1,16 @@ +#import <UIKit/UIKit.h> + +//Starting from iOS 6 we have a nice UICollectionView/UICollectionViewController. +//This class was born in iOS 4 times, so it's a kind of ugly and primitive collection view. +//Still I do not see any need in replacing it with a UICollectionViewController - it works as it is. + +@class FileShortcutView; + +@interface FileCollectionViewController : UIViewController <UINavigationControllerDelegate, UINavigationBarDelegate, + UIActionSheetDelegate, UIGestureRecognizerDelegate> + +- (void) fileWasSelected : (FileShortcutView*) shortcut; +- (void) tryToDelete : (FileShortcutView*) shortcut; +- (void) addRootFile : (NSString *) fileName; + +@end diff --git a/test/ios/RootBrowser/Src/Browser/Controllers/FileCollectionViewController.mm b/test/ios/RootBrowser/Src/Browser/Controllers/FileCollectionViewController.mm new file mode 100644 index 0000000000000..eb03b0e12007e --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Controllers/FileCollectionViewController.mm @@ -0,0 +1,316 @@ +#import <cassert> + +#import "FileCollectionViewController.h" +#import "FileContentViewController.h" +#import "FileShortcutView.h" +#import "Shortcuts.h" +#import "Constants.h" + +//C++ imports. +#import "FileUtils.h" + + +@implementation FileCollectionViewController { + __weak IBOutlet UIScrollView *scrollView; + __weak IBOutlet UIView *fileOpenView; + __weak IBOutlet UITextField *fileNameField; + + NSMutableArray *fileContainers; + BOOL viewDidAppear; + __weak FileShortcutView *fileToDelete; + + BOOL locked; +} + +//____________________________________________________________________________________________________ +- (id) initWithCoder : (NSCoder *) aDecoder +{ + if (self = [super initWithCoder : aDecoder]) { + fileContainers = [[NSMutableArray alloc] init]; + viewDidAppear = NO; + locked = NO; + } + + return self; +} + +#pragma mark - View lifecycle + +//____________________________________________________________________________________________________ +- (void) viewDidLoad +{ + [super viewDidLoad]; + + //Setup additional views here. + self.navigationItem.title = @"ROOT files"; + self.navigationItem.backBarButtonItem = [[UIBarButtonItem alloc] initWithTitle : @"Back to ROOT files" + style : UIBarButtonItemStylePlain target : nil action : nil]; + self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc] initWithTitle : @"Open file" style : UIBarButtonItemStylePlain target : self action : @selector(showFileOpenView)]; + + scrollView.bounces = NO; + + [self.view bringSubviewToFront : fileOpenView];//it's still hidden. + + fileNameField.clearButtonMode = UITextFieldViewModeAlways; + + UITapGestureRecognizer * const tap = [[UITapGestureRecognizer alloc] initWithTarget : self action : @selector(hideFileOpenView)]; + //Usual Apple's fu..up with gestures. + tap.delegate = self; + [self.view addGestureRecognizer : tap]; +} + +//____________________________________________________________________________________________________ +- (void) viewWillAppear : (BOOL)animated +{ + [super viewWillAppear : animated]; + + [fileNameField resignFirstResponder];//? TODO: check why do I have this here at all. +} + +//____________________________________________________________________________________________________ +- (void) viewDidLayoutSubviews +{ + //I only have to set correct positions for the shortcuts. + [self correctFramesForOrientation : self.interfaceOrientation]; +} + +//____________________________________________________________________________________________________ +- (void) viewDidAppear : (BOOL) animated +{ + [super viewDidAppear : animated]; + + if (!viewDidAppear) { + //The first time this method is called, add the 'demos.root'. + if (fileContainers.count) { + for (UIView *shortcut in fileContainers) + if (!shortcut.superview) + [scrollView addSubview : shortcut]; + + [self correctFramesForOrientation : self.interfaceOrientation]; + } + + viewDidAppear = YES; + } +} + +#pragma mark - View's geometry, interface orientation, etc. + +//____________________________________________________________________________________________________ +- (void) placeFileShortcuts +{ + using ROOT::iOS::Browser::PlaceShortcutsInScrollView; + + if ([scrollView.subviews count]) + //25.f - is an additional 'pad' space between shortcuts. + PlaceShortcutsInScrollView(fileContainers, scrollView, CGSizeMake([FileShortcutView iconWidth], [FileShortcutView iconHeight]), 25.f); +} + +//____________________________________________________________________________________________________ +- (void) correctFramesForOrientation : (UIInterfaceOrientation) orientation +{ +#pragma unused(orientation) + + //This is the legacy code: before I was resetting views geometry manually, now no + //need in this nightmare anymore, just place shortcuts in correct places. + + [self placeFileShortcuts]; +} + + +//____________________________________________________________________________________________________ +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation +{ +#pragma unused(interfaceOrientation) + + return YES; +} + +//____________________________________________________________________________________________________ +- (void) willAnimateRotationToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation duration : (NSTimeInterval) duration +{ +#pragma unused(duration) + + [self correctFramesForOrientation : interfaceOrientation]; +} + +#pragma mark - File shortcuts. + +//____________________________________________________________________________________________________ +- (void) addRootFile : (NSString *) fileName +{ + //Open the file and read its contents. + assert(fileName != nil && "addRootFile:, parameter 'fileName' is nil"); + + using namespace ROOT::iOS::Browser; + + FileContainer * const fileContainer = FileContainer::CreateFileContainer([fileName cStringUsingEncoding : [NSString defaultCStringEncoding]]); + + if (!fileContainer) { + UIAlertView *alert = [[UIAlertView alloc] initWithTitle : @"File Open Error:" + message : [NSString stringWithFormat:@"Could not open %@", fileName] + delegate : nil + cancelButtonTitle : @"Close" + otherButtonTitles : nil]; + [alert show]; + return; + } + + const CGRect shortcutFrame = CGRectMake(0.f, 0.f, [FileShortcutView iconWidth], [FileShortcutView iconHeight]); + FileShortcutView * const newShortcut = [[FileShortcutView alloc] initWithFrame : shortcutFrame controller : self fileContainer : fileContainer]; + if (newShortcut) { + [fileContainers addObject : newShortcut]; + + if ([self isViewLoaded]) { + [scrollView addSubview : newShortcut]; + [self placeFileShortcuts]; + }//else we'll do it later. + } else + FileContainer::DeleteFileContainer(fileContainer); +} + +//____________________________________________________________________________________________________ +- (void) fileWasSelected : (FileShortcutView *) shortcut +{ + assert(shortcut != nil && "fileWasSelected:, parameter 'shortcut' is nil"); + + if (locked || fileNameField.isFirstResponder) + return; + + assert(self.storyboard != nil && "fileWasSelected:, self.storyboard is nil"); + + UIViewController * const c = (UIViewController *)[self.storyboard instantiateViewControllerWithIdentifier : ROOT::iOS::Browser::FileContentViewControllerID]; + assert([c isKindOfClass : [FileContentViewController class]] && + "fileWasSelected:, file content view controller has a wrong type"); + + FileContentViewController * const contentController = (FileContentViewController *)c; + [contentController activateForFile : [shortcut getFileContainer]]; + [self.navigationController pushViewController : contentController animated : YES]; +} + +//____________________________________________________________________________________________________ +- (void) tryToDelete : (FileShortcutView *) shortcut +{ + assert(shortcut != nil && "tryToDelete:, parameter 'shortcut' is nil"); + + if (locked || fileNameField.isFirstResponder) + return; + + NSString * const message = [NSString stringWithFormat : @"Do you really want to close %@?", shortcut.fileName]; + UIActionSheet * const dialog = [[UIActionSheet alloc] initWithTitle : message delegate : self + cancelButtonTitle : @"Cancel" destructiveButtonTitle : @"Yes" otherButtonTitles : nil]; + fileToDelete = shortcut; + [dialog showInView : self.view]; +} + +#pragma mark - Action sheet delegate, delete the file. + +//____________________________________________________________________________________________________ +- (void) actionSheet : (UIActionSheet *) actionSheet didDismissWithButtonIndex : (NSInteger) buttonIndex +{ +#pragma unused(actionSheet) + + if (!buttonIndex) { + [fileContainers removeObject:fileToDelete]; + [fileToDelete removeFromSuperview]; + [self correctFramesForOrientation : self.interfaceOrientation]; + } +} + +#pragma mark - File open operations + text filed handling. + +//____________________________________________________________________________________________________ +- (void) animateFileOpenView +{ + assert(locked == NO && "animateFileOpenView, called while an animation is still active"); + //Do animation. + // First create a CATransition object to describe the transition + CATransition * const transition = [CATransition animation]; + transition.duration = 0.15; + // using the ease in/out timing function + transition.timingFunction = [CAMediaTimingFunction functionWithName : kCAMediaTimingFunctionEaseInEaseOut]; + // Now to set the type of transition. + transition.type = kCATransitionPush; + + if (!fileOpenView.hidden) + transition.subtype = kCATransitionFromBottom; + else + transition.subtype = kCATransitionFromTop; + transition.delegate = self; + // Next add it to the containerView's layer. This will perform the transition based on how we change its contents. + [fileOpenView.layer addAnimation : transition forKey : nil]; +} + +//____________________________________________________________________________________________________ +- (void) showFileOpenView +{ + if (locked)//We're animating this view already. + return; + + fileOpenView.hidden = !fileOpenView.hidden; + [self animateFileOpenView]; + + if (!fileOpenView.hidden) + [fileNameField becomeFirstResponder]; + else + [fileNameField resignFirstResponder]; +} + +//____________________________________________________________________________________________________ +- (IBAction) textFieldDidEndOnExit : (id) sender +{ +#pragma unused(sender) + NSString * const filePath = fileNameField.text; + if (filePath) + [self addRootFile : filePath]; +} + +//____________________________________________________________________________________________________ +- (IBAction) textFieldEditingDidEnd : (id) sender +{ +#pragma unused(sender) + [sender resignFirstResponder]; + fileOpenView.hidden = YES; + [self animateFileOpenView]; +} + +//____________________________________________________________________________________________________ +- (void) hideFileOpenView +{ + [fileNameField resignFirstResponder]; + fileOpenView.hidden = YES; + [self animateFileOpenView]; +} + +#pragma mark - CAAnimationDelegate. + +//____________________________________________________________________________________________________ +- (void) animationDidStart : (CAAnimation *) anim +{ +#pragma unused(anim) + locked = YES; +} + +//____________________________________________________________________________________________________ +- (void) animationDidStop : (CAAnimation *) anim finished : (BOOL) flag +{ +#pragma unused(anim) + if (flag) + locked = NO; +} + +#pragma mark - Standard f..p with gestures. + +//____________________________________________________________________________________________________ +- (BOOL) gestureRecognizer : (UIGestureRecognizer *) gestureRecognizer shouldReceiveTouch : (UITouch *) touch +{ +#pragma unused(gestureRecognizer) + if (locked) + return NO; + + if ([touch.view isKindOfClass : [FileShortcutView class]]) + return NO; + + return YES; +} + +@end diff --git a/test/ios/RootBrowser/Src/Browser/Controllers/FileContentViewController.h b/test/ios/RootBrowser/Src/Browser/Controllers/FileContentViewController.h new file mode 100644 index 0000000000000..4a443fbc73b22 --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Controllers/FileContentViewController.h @@ -0,0 +1,35 @@ +#import <UIKit/UIKit.h> + +#import "SearchViewController.h" + +// +//These view/controller classes are a legacy code and implement +//what is essentially UICollectionView/UICollectionViewController today +//with some additional features. +//As soon as it works as I want, I do not see any reason +//to get rid of it. +// + +@class FileContainerElement; +@class ObjectShortcutView; + +namespace ROOT { +namespace iOS { +namespace Browser { + +class FileContainer; + +} +} +} + +@interface FileContentViewController : UIViewController <UISearchBarDelegate, UIPopoverControllerDelegate, SearchViewDelegate> + +@property (nonatomic, readonly) ROOT::iOS::Browser::FileContainer *fileContainer; + +- (void) activateForFile : (ROOT::iOS::Browser::FileContainer *) container; + +- (void) selectObjectFromFile : (ObjectShortcutView *) obj; +- (void) searchController : (SearchViewController *) controller didSelectKey : (FileContainerElement *) key; + +@end diff --git a/test/ios/RootBrowser/FileContentController.mm b/test/ios/RootBrowser/Src/Browser/Controllers/FileContentViewController.mm similarity index 65% rename from test/ios/RootBrowser/FileContentController.mm rename to test/ios/RootBrowser/Src/Browser/Controllers/FileContentViewController.mm index feb86db675898..c5ad1bb80f5d1 100644 --- a/test/ios/RootBrowser/FileContentController.mm +++ b/test/ios/RootBrowser/Src/Browser/Controllers/FileContentViewController.mm @@ -1,44 +1,46 @@ -#import <stdlib.h> +#import <cassert> +#import <cmath> -#import <CoreGraphics/CGGeometry.h> #import <QuartzCore/QuartzCore.h> -#import "FileContentController.h" -#import "ROOTObjectController.h" +#import "FileContentViewController.h" +#import "SlideshowViewController.h" +#import "ObjectViewController.h" #import "FileContainerElement.h" -#import "SlideshowController.h" #import "TransparentToolbar.h" -#import "SearchController.h" -#import "ObjectShortcut.h" +#import "ObjectShortcutView.h" +#import "SpotObjectView.h" #import "Shortcuts.h" -#import "SpotView.h" - +#import "Constants.h" //C++ imports. #import "IOSPad.h" #import "FileUtils.h" -@interface FileContentController () { +@implementation FileContentViewController { + ROOT::iOS::Browser::FileContainer *fileContainer; + + __weak IBOutlet UIScrollView *scrollView; + NSMutableArray *objectShortcuts; + UISearchBar *searchBar; UIPopoverController *searchPopover; - SearchController *searchController; + SearchViewController *searchController; + UIBarButtonItem *slideShowBtn; BOOL animateDirAfterLoad; BOOL animateObjAfterLoad; + unsigned spotElement; + + BOOL viewDidAppear; + + BOOL animating; } -- (void) highlightDirectory : (unsigned)tag; -- (void) highlightObject : (unsigned)tag; - -@end - - -@implementation FileContentController - @synthesize fileContainer; @@ -64,80 +66,50 @@ - (void) initToolbarItems UIBarButtonItem *rightItem = [[UIBarButtonItem alloc] initWithCustomView : toolbar]; rightItem.style = UIBarButtonItemStylePlain; self.navigationItem.rightBarButtonItem = rightItem; - - } //____________________________________________________________________________________________________ -- (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil +- (id) initWithCoder : (NSCoder *) aDecoder { - self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; - - if (self) { - [self view]; - [self initToolbarItems]; - searchController = [[SearchController alloc] initWithStyle : UITableViewStylePlain]; - searchController.delegate = self; + if (self = [super initWithCoder : aDecoder]) { + // + viewDidAppear = NO; + animating = NO; } - + return self; } -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - - // Release any cached data, images, etc that aren't in use. -} - #pragma mark - View lifecycle - //____________________________________________________________________________________________________ -- (void) correctFramesForOrientation : (UIInterfaceOrientation) orientation +- (void) viewWillAppear : (BOOL) animated { - //TODO: all this staff with manual geometry management should be deleted, as soon as I switch to - //ThumbnailView class. - CGRect mainFrame; - CGRect scrollFrame; - - if (orientation == UIInterfaceOrientationPortrait || orientation == UIInterfaceOrientationPortraitUpsideDown) { - mainFrame = CGRectMake(0.f, 0.f, 768.f, 1004.f); - scrollFrame = CGRectMake(0.f, 44.f, 768.f, 960.f); - } else { - mainFrame = CGRectMake(0.f, 0.f, 1024.f, 748.f); - scrollFrame = CGRectMake(0.f, 44.f, 1024.f, 704.f); - } - - self.view.frame = mainFrame; - scrollView.frame = scrollFrame; - - if ([[scrollView subviews] count]) - [ShorcutUtil placeShortcuts : objectShortcuts inScrollView : scrollView withSize : CGSizeMake([ObjectShortcut iconWidth], [ObjectShortcut iconHeight] + [ObjectShortcut textHeight]) andSpace : 100.f]; -} - -//____________________________________________________________________________________________________ -- (void) viewWillAppear:(BOOL)animated -{ - //TODO: all this staff with manual geometry management should be deleted, as soon as I switch to - //ThumbnailView class. - //self.interfaceOrientation ? - [self correctFramesForOrientation : [UIApplication sharedApplication].statusBarOrientation]; + [super viewWillAppear : animated]; + [self correctFramesForOrientation : self.interfaceOrientation]; } //____________________________________________________________________________________________________ - (void) viewDidLoad { [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. + // + [self initToolbarItems]; + searchController = [[SearchViewController alloc] initWithStyle : UITableViewStylePlain]; + searchController.delegate = self; + // + assert(fileContainer != nil && "viewDidLoad, fileContainer is nil"); + //Create object shortcuts. + self.navigationItem.title = [NSString stringWithFormat : @"Contents of %s", fileContainer->GetFileName()]; + slideShowBtn.enabled = fileContainer->GetNumberOfObjects() > 1 ? YES : NO; + [self addObjectsIntoScrollview]; } //____________________________________________________________________________________________________ -- (void) viewDidAppear:(BOOL)animated +- (void) viewDidAppear : (BOOL)animated { [super viewDidAppear : animated]; + if (animateDirAfterLoad) { [self highlightDirectory : spotElement]; animateDirAfterLoad = NO; @@ -148,32 +120,49 @@ - (void) viewDidAppear:(BOOL)animated } //____________________________________________________________________________________________________ -- (void) viewDidUnload +- (void) viewDidLayoutSubviews { - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; + [self correctFramesForOrientation : self.interfaceOrientation]; } +#pragma mark - Views' geometry + interface orientation. + //____________________________________________________________________________________________________ -- (BOOL) shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation +- (void) correctFramesForOrientation : (UIInterfaceOrientation) orientation { - // Return YES for supported orientations - return YES; +#pragma unused(orientation) + + //It's a legacy code - in the past I was resetting view's geometry manually. + //Now it's done with automatic layout + I'm setting shortcuts myself. + + using ROOT::iOS::Browser::PlaceShortcutsInScrollView; + + if ([[scrollView subviews] count]) { + PlaceShortcutsInScrollView(objectShortcuts, scrollView, + CGSizeMake([ObjectShortcutView iconWidth], [ObjectShortcutView iconHeight] + [ObjectShortcutView textHeight]), + 100.f); + } } + //____________________________________________________________________________________________________ -- (void) willAnimateRotationToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation duration:(NSTimeInterval)duration +- (BOOL) shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation) interfaceOrientation { - //TODO: all this staff with manual geometry management should be deleted, as soon as I switch to - //ThumbnailView class. +#pragma unused(interfaceOrientation) + return YES; +} +//____________________________________________________________________________________________________ +- (void) willAnimateRotationToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation duration : (NSTimeInterval) duration +{ +#pragma unused(duration) [self correctFramesForOrientation : interfaceOrientation]; } //____________________________________________________________________________________________________ -- (void) didRotateFromInterfaceOrientation : (UIInterfaceOrientation)fromInterfaceOrientation +- (void) didRotateFromInterfaceOrientation : (UIInterfaceOrientation) fromInterfaceOrientation { +#pragma unused(fromInterfaceOrientation) //Bring back the popover after rotating. if (searchPopover) { [searchPopover presentPopoverFromRect : searchBar.bounds inView : searchBar @@ -181,19 +170,20 @@ - (void) didRotateFromInterfaceOrientation : (UIInterfaceOrientation)fromInterfa } } +#pragma mark - objects and folders (shortcut views). + //____________________________________________________________________________________________________ - (void) clearScrollview { - NSArray *viewsToRemove = [scrollView subviews]; + NSArray * const viewsToRemove = [scrollView subviews]; for (UIView *v in viewsToRemove) [v removeFromSuperview]; - } //____________________________________________________________________________________________________ - (void) addShortcutForObjectAtIndex : (unsigned) objIndex { - const CGRect rect = CGRectMake(0.f, 0.f, [ObjectShortcut iconWidth], [ObjectShortcut iconHeight]); + const CGRect rect = CGRectMake(0.f, 0.f, [ObjectShortcutView iconWidth], [ObjectShortcutView iconHeight]); UIGraphicsBeginImageContext(rect.size); CGContextRef ctx = UIGraphicsGetCurrentContext(); if (!ctx) { @@ -218,7 +208,8 @@ - (void) addShortcutForObjectAtIndex : (unsigned) objIndex UIImage *thumbnailImage = UIGraphicsGetImageFromCurrentImageContext();//autoreleased UIImage. UIGraphicsEndImageContext(); - ObjectShortcut *shortcut = [[ObjectShortcut alloc] initWithFrame : [ObjectShortcut defaultRect] controller : self forObjectAtIndex:objIndex withThumbnail : thumbnailImage]; + ObjectShortcutView * const shortcut = [[ObjectShortcutView alloc] initWithFrame : [ObjectShortcutView defaultRect] + controller : self forObjectAtIndex : objIndex withThumbnail : thumbnailImage]; shortcut.layer.shadowColor = [UIColor blackColor].CGColor; shortcut.layer.shadowOffset = CGSizeMake(20.f, 20.f); shortcut.layer.shadowOpacity = 0.3f; @@ -233,7 +224,8 @@ - (void) addShortcutForObjectAtIndex : (unsigned) objIndex //____________________________________________________________________________________________________ - (void) addShortcutForFolderAtIndex : (unsigned) index { - ObjectShortcut *shortcut = [[ObjectShortcut alloc] initWithFrame : [ObjectShortcut defaultRect] controller : self forFolderAtIndex : index]; + ObjectShortcutView * const shortcut = [[ObjectShortcutView alloc] initWithFrame : [ObjectShortcutView defaultRect] + controller : self forFolderAtIndex : index]; [scrollView addSubview : shortcut]; [objectShortcuts addObject : shortcut]; } @@ -256,21 +248,24 @@ - (void) addObjectsIntoScrollview } //____________________________________________________________________________________________________ -- (void) activateForFile : (ROOT::iOS::Browser::FileContainer *)container +- (void) activateForFile : (ROOT::iOS::Browser::FileContainer *) container { + assert(container != nullptr && "activateForFile:, parameter 'container' is null"); + fileContainer = container; - self.navigationItem.title = [NSString stringWithFormat : @"Contents of %s", container->GetFileName()]; - slideShowBtn.enabled = fileContainer->GetNumberOfObjects() > 1 ? YES : NO; - - //Prepare objects' thymbnails. - [self addObjectsIntoScrollview]; - [self correctFramesForOrientation : [UIApplication sharedApplication].statusBarOrientation]; } //____________________________________________________________________________________________________ - (void) startSlideshow { - SlideshowController *slideshowController = [[SlideshowController alloc] initWithNibName : @"SlideshowController" bundle : nil fileContainer : fileContainer]; + if (animating) + return; + + assert(self.storyboard != nil && "startSlideshow, self.storyboard is nil"); + assert(fileContainer != nullptr && "startSlideshow, fileContainer is null"); + + SlideshowViewController * const slideshowController = [self.storyboard instantiateViewControllerWithIdentifier:ROOT::iOS::Browser::SlideshowViewControllerID]; + [slideshowController setFileContainer : fileContainer]; [self.navigationController pushViewController : slideshowController animated : YES]; } @@ -278,21 +273,33 @@ - (void) startSlideshow - (void) doTest { const unsigned testIndex = 1 + rand() % (fileContainer->GetNumberOfObjects() - 1); - ROOTObjectController *objectController = [[ROOTObjectController alloc] initWithNibName:@"ROOTObjectController" bundle : nil]; + ObjectViewController *objectController = [[ObjectViewController alloc] initWithNibName : @"ROOTObjectController" bundle : nil]; [objectController setNavigationForObjectWithIndex : testIndex fromContainer : fileContainer]; [self.navigationController pushViewController : objectController animated : YES]; } //____________________________________________________________________________________________________ -- (void) selectObjectFromFile : (ObjectShortcut *) shortcut +- (void) selectObjectFromFile : (ObjectShortcutView *) shortcut { + if (animating) + return; + + assert(shortcut != nil && "selectObjectFromFile:, parameter shortcut is nil"); + assert(fileContainer != nullptr && "selectObjectFromFile:, fileContainer is null"); + assert(self.storyboard != nil && "selectObjectFromFile:, self.storyboard is nil"); + if (shortcut.isDirectory) { //Create another FileContentController and push it on stack. - FileContentController *contentController = [[FileContentController alloc] initWithNibName : @"FileContentController" bundle : nil]; + UIViewController * const c = (UIViewController *)[self.storyboard instantiateViewControllerWithIdentifier : ROOT::iOS::Browser::FileContentViewControllerID]; + assert([c isKindOfClass : [FileContentViewController class]] && "file content controller has a wrong type"); + FileContentViewController * const contentController = (FileContentViewController *)c; [contentController activateForFile : fileContainer->GetDirectory(shortcut.objectIndex)]; [self.navigationController pushViewController : contentController animated : YES]; } else { - ROOTObjectController *objectController = [[ROOTObjectController alloc] initWithNibName : @"ROOTObjectController" bundle : nil]; + UIViewController * const c = (UIViewController *)[self.storyboard instantiateViewControllerWithIdentifier : ROOT::iOS::Browser::ObjectViewControllerID]; + assert([c isKindOfClass : [ObjectViewController class]] && + "object view controller has a wrong type"); + ObjectViewController * const objectController = (ObjectViewController *)c; [objectController setNavigationForObjectWithIndex : shortcut.objectIndex fromContainer : fileContainer]; [self.navigationController pushViewController : objectController animated : YES]; } @@ -301,8 +308,10 @@ - (void) selectObjectFromFile : (ObjectShortcut *) shortcut #pragma mark - Search delegate. //____________________________________________________________________________________________________ -- (void) searchBarTextDidBeginEditing : (UISearchBar *)aSearchBar +- (void) searchBarTextDidBeginEditing : (UISearchBar *) aSearchBar { +#pragma unused(aSearchBar) + typedef ROOT::iOS::Browser::FileContainer::size_type size_type; if (auto nEntities = fileContainer->GetNumberOfDescriptors()) { @@ -329,10 +338,10 @@ - (void) searchBarTextDidBeginEditing : (UISearchBar *)aSearchBar } //____________________________________________________________________________________________________ -- (void) searchBarTextDidEndEditing : (UISearchBar *)aSearchBar +- (void) searchBarTextDidEndEditing : (UISearchBar *) aSearchBar { if (searchPopover) { - [searchPopover dismissPopoverAnimated:YES]; + [searchPopover dismissPopoverAnimated : YES]; searchPopover = nil; } @@ -340,16 +349,18 @@ - (void) searchBarTextDidEndEditing : (UISearchBar *)aSearchBar } //____________________________________________________________________________________________________ -- (void) searchBar : (UISearchBar *)searchBar textDidChange : (NSString *)searchText +- (void) searchBar : (UISearchBar *) searchBar textDidChange : (NSString *) searchText { +#pragma unused(searchBar) // When the search string changes, filter the recents list accordingly. [searchController filterResultsUsingString : searchText]; } //____________________________________________________________________________________________________ -- (void) searchBarSearchButtonClicked : (UISearchBar *)aSearchBar +- (void) searchBarSearchButtonClicked : (UISearchBar *) aSearchBar { - //NSLog(@"search clicked"); +#pragma unused(aSearchBar) + [searchPopover dismissPopoverAnimated : YES]; [searchBar resignFirstResponder]; } @@ -357,19 +368,22 @@ - (void) searchBarSearchButtonClicked : (UISearchBar *)aSearchBar #pragma mark - Popover controller delegate. //____________________________________________________________________________________________________ -- (void) popoverControllerDidDismissPopover : (UIPopoverController *)popoverController +- (void) popoverControllerDidDismissPopover : (UIPopoverController *) popoverController { - //NSLog(@"popover dismiss"); +#pragma unused(popoverController) [searchBar resignFirstResponder]; } #pragma mark - Search delegate. //____________________________________________________________________________________________________ -- (void) searchesController : (SearchController *)controller didSelectKey : (FileContainerElement *)key +- (void) searchController : (SearchViewController *) controller didSelectKey : (FileContainerElement *) key { - //NSLog(@"selected %@ with index %d", key.elementName, key.elementIndex); - assert(key.elementIndex < fileContainer->GetNumberOfDescriptors()); +#pragma unused(controller) + + assert(key != nil && "searcheController:didSelectKey:, parameter 'key' is nil"); + assert(key.elementIndex < fileContainer->GetNumberOfDescriptors() && + "searcheController:didSelectKey:, key.elementIndex is out of bounds"); [searchPopover dismissPopoverAnimated : YES]; searchPopover = nil; @@ -380,7 +394,11 @@ - (void) searchesController : (SearchController *)controller didSelectKey : (Fil descriptor.fIsDir ? [self highlightDirectory : descriptor.fIndex] : [self highlightObject : descriptor.fIndex]; } else { //Create another FileContentController and push it on stack. - FileContentController *contentController = [[FileContentController alloc] initWithNibName : @"FileContentController" bundle : nil]; + assert(self.storyboard != nil && "searcheController:didSelectKey:, self.storyboard is nil"); + UIViewController * const c = (UIViewController *)[self.storyboard instantiateViewControllerWithIdentifier : ROOT::iOS::Browser::FileContentViewControllerID]; + assert([c isKindOfClass : [FileContentViewController class]] && + "searcheController:didSelectKey, file content controller has a wrong type"); + FileContentViewController * const contentController = (FileContentViewController *)c; [contentController activateForFile : descriptor.fOwner]; if (descriptor.fIsDir) @@ -397,32 +415,46 @@ - (void) searchesController : (SearchController *)controller didSelectKey : (Fil #pragma mark - adjust file container to show search result //____________________________________________________________________________________________________ -- (void) animateShortcut : (ObjectShortcut *) sh +- (void) animateShortcut : (ObjectShortcutView *) sh { - CGAffineTransform originalTransform = sh.transform; - CGAffineTransform newTransform = CGAffineTransformScale(originalTransform, 1.2f, 1.2f); + assert(sh != nil && "animateShortcut:, parameter 'sh' is nil"); + + const CGRect oldFrame = sh.frame; + const CGAffineTransform originalTransform = sh.transform; + const CGAffineTransform newTransform = CGAffineTransformScale(originalTransform, 1.2f, 1.2f); - [UIView beginAnimations : @"hide_object" context : nil]; - [UIView setAnimationDuration : 1.5f]; - [UIView setAnimationCurve : UIViewAnimationCurveLinear]; - [UIView setAnimationTransition : UIViewAnimationTransitionNone forView : sh cache : YES]; sh.transform = newTransform; sh.spot.alpha = 0.8f; - [UIView commitAnimations]; + + animating = YES; [UIView beginAnimations : @"show_object" context : nil]; - [UIView setAnimationDuration : 1.f]; + [UIView setAnimationDuration : 0.5f]; [UIView setAnimationCurve : UIViewAnimationCurveLinear]; [UIView setAnimationTransition : UIViewAnimationTransitionNone forView : sh cache : YES]; + [UIView setAnimationDelegate : self]; + [UIView setAnimationDidStopSelector : @selector(animationDidStop:finished:context:)]; sh.transform = originalTransform; sh.spot.alpha = 0.f; + sh.frame = oldFrame; [UIView commitAnimations]; } //____________________________________________________________________________________________________ -- (void) highlightDirectory : (unsigned)tag +- (void) animationDidStop : (NSString *) animationID finished : (NSNumber *) finished context : (void *) context +{ +#pragma unused(animationID, context) + if ([finished boolValue]) + animating = NO; +} + +//____________________________________________________________________________________________________ +- (void) highlightDirectory : (unsigned) tag { - for (ObjectShortcut *sh in objectShortcuts) { + if (animating) + return; + + for (ObjectShortcutView *sh in objectShortcuts) { if (sh.objectIndex == tag && sh.isDirectory) { const CGRect thumbFrame = sh.frame; const CGRect scrollBounds = scrollView.bounds; @@ -443,9 +475,12 @@ - (void) highlightDirectory : (unsigned)tag } //____________________________________________________________________________________________________ -- (void) highlightObject : (unsigned)tag +- (void) highlightObject : (unsigned) tag { - for (ObjectShortcut *sh in objectShortcuts) { + if (animating) + return; + + for (ObjectShortcutView *sh in objectShortcuts) { if (sh.objectIndex == tag && !sh.isDirectory) { CGRect thumbFrame = sh.frame; const CGRect scrollBounds = scrollView.bounds; diff --git a/test/ios/RootBrowser/Src/Browser/Controllers/ObjectViewController.h b/test/ios/RootBrowser/Src/Browser/Controllers/ObjectViewController.h new file mode 100644 index 0000000000000..5b418ad5c78ff --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Controllers/ObjectViewController.h @@ -0,0 +1,24 @@ +#import <MessageUI/MessageUI.h> +#import <UIKit/UIKit.h> + +#import "FileUtils.h" + +@class ScrollViewWithPadView; + +class TObject; + +@interface ObjectViewController : UIViewController <UIScrollViewDelegate, MFMailComposeViewControllerDelegate> + +- (void) setNavigationForObjectWithIndex : (unsigned) index fromContainer : (ROOT::iOS::Browser::FileContainer *) fileContainer; +- (void) handleDoubleTapOnPad : (CGPoint) tapPt; +- (void) objectWasSelected : (TObject *) object; +- (void) objectWasModifiedUpdateSelection : (BOOL) needUpdate; +- (void) setupObjectInspector; + +- (ROOT::iOS::Browser::EHistogramErrorOption) getErrorOption; +- (void) setErrorOption : (ROOT::iOS::Browser::EHistogramErrorOption) errorOption; + +- (BOOL) markerIsOn; +- (void) setMarker : (BOOL)on; + +@end diff --git a/test/ios/RootBrowser/ROOTObjectController.mm b/test/ios/RootBrowser/Src/Browser/Controllers/ObjectViewController.mm similarity index 81% rename from test/ios/RootBrowser/ROOTObjectController.mm rename to test/ios/RootBrowser/Src/Browser/Controllers/ObjectViewController.mm index eb3c758c67d2e..0607ec0ba1396 100644 --- a/test/ios/RootBrowser/ROOTObjectController.mm +++ b/test/ios/RootBrowser/Src/Browser/Controllers/ObjectViewController.mm @@ -1,14 +1,16 @@ -#import <stdlib.h> +#import <cassert> +#import <cmath> #import <QuartzCore/QuartzCore.h> -#import "ScrollViewWithPadView.h" -#import "ROOTObjectController.h" -#import "PadImageScrollView.h" + +#import "ObjectViewController.h" +#import "PadEditorScrollView.h" +#import "ObjectShortcutView.h" #import "TransparentToolbar.h" +#import "PadSelectionView.h" #import "ObjectInspector.h" -#import "ObjectShortcut.h" -#import "SelectionView.h" +#import "PadScrollView.h" #import "EditorView.h" #import "Constants.h" #import "PadView.h" @@ -21,7 +23,6 @@ #import "FileUtils.h" namespace { -//Ugly Obj-C, implementation block is not a scope, so either static or unnamed namespace :( //This constant is used to check, if pad was //scaled to possible maximum or still can be zoomed in. @@ -35,7 +36,10 @@ } -@implementation ROOTObjectController { +@implementation ObjectViewController { + __weak IBOutlet PadEditorScrollView *padScrollView; + __weak IBOutlet UIScrollView *navigationScrollView; + Mode mode; __weak EditorView *editorView; @@ -49,13 +53,14 @@ @implementation ROOTObjectController { BOOL zoomed; - PadImageScrollView *navScrolls[3]; + PadScrollView *navScrolls[3]; unsigned currentObject; unsigned nextObject; unsigned previousObject; - UIBarButtonItem *editBtn; + UIBarButtonItem *editBtn; + BOOL viewDidAppear; } @@ -64,12 +69,16 @@ @implementation ROOTObjectController { //____________________________________________________________________________________________________ - (ROOT::iOS::Browser::EHistogramErrorOption) getErrorOption { + assert(fileContainer != nullptr && "getErrorOption, fileContainer is null"); + return fileContainer->GetErrorDrawOption(currentObject); } //____________________________________________________________________________________________________ - (void) setErrorOption : (ROOT::iOS::Browser::EHistogramErrorOption) errorOption { + assert(fileContainer != nullptr && "setErrorOption:, fileContainer is null"); + fileContainer->SetErrorDrawOption(currentObject, errorOption); //Ugly as hell :(( But ROOT holds draw options inside TObjLink in a pad. fileContainer->GetPadAttached(currentObject)->cd(); @@ -79,28 +88,34 @@ - (void) setErrorOption : (ROOT::iOS::Browser::EHistogramErrorOption) errorOptio //____________________________________________________________________________________________________ - (BOOL) markerIsOn { + assert(fileContainer != nullptr && "markerIsOn, fileContainer is null"); + return fileContainer->GetMarkerDrawOption(currentObject); } //____________________________________________________________________________________________________ -- (void) setMarker : (BOOL)on +- (void) setMarker : (BOOL) on { + assert(fileContainer != nullptr && "setMarker:, fileContainer is null"); + fileContainer->SetMarkerDrawOption(currentObject, bool(on)); //Ugly as hell :(( But ROOT holds draw options inside TObjLink in a pad. fileContainer->GetPadAttached(currentObject)->cd(); fileContainer->GetObject(currentObject)->SetDrawOption(fileContainer->GetDrawOption(currentObject)); } +#pragma mark - View lifecycle. + //____________________________________________________________________________________________________ - (void) initToolbarItems { - UIToolbar *toolbar = [[TransparentToolbar alloc] initWithFrame : CGRectMake(0.f, 0.f, 180.f, 44.f)]; + UIToolbar * const toolbar = [[TransparentToolbar alloc] initWithFrame : CGRectMake(0.f, 0.f, 180.f, 44.f)]; toolbar.barStyle = UIBarStyleBlackTranslucent; - NSMutableArray *buttons = [[NSMutableArray alloc] initWithCapacity : 2]; + NSMutableArray * const buttons = [[NSMutableArray alloc] initWithCapacity : 2]; - UIBarButtonItem *saveBtn = [[UIBarButtonItem alloc] initWithTitle:@"Save and send" style : UIBarButtonItemStyleBordered target : self action : @selector(sendEmail)]; + UIBarButtonItem * const saveBtn = [[UIBarButtonItem alloc] initWithTitle : @"Save and send" style : UIBarButtonItemStyleBordered target : self action : @selector(sendEmail)]; [buttons addObject : saveBtn]; editBtn = [[UIBarButtonItem alloc] initWithTitle:@"Edit" style : UIBarButtonItemStyleBordered target:self action:@selector(toggleEditor)]; @@ -116,8 +131,39 @@ - (void) initToolbarItems //____________________________________________________________________________________________________ - (void) viewDidLoad { - [self initToolbarItems]; [super viewDidLoad]; + + [self initToolbarItems]; + [self loadObjectInspector]; + + assert(fileContainer != nullptr && "viewDidLoad, fileContainer is null"); + self.navigationItem.title = [NSString stringWithFormat : @"%s", fileContainer->GetObject(currentObject)->GetName()]; +} + +//____________________________________________________________________________________________________ +- (void) viewWillAppear : (BOOL) animated +{ + [super viewWillAppear : animated]; + + //This is done intentionally: unfortunately, + //it takes quite a long time to render several (max. 3) + //objects into pad views. If this code is in viewDidAppear, + //you can see an empty view for a couple of seconds. + //Instead, I place this code here and now after you selected and object, + //you have to wait. + if (!viewDidAppear) { + viewDidAppear = YES; + [self setupScrollForEditablePadView]; + [self setupNavigationScrollView]; + [self initPadViews]; + [self correctFramesForOrientation : self.interfaceOrientation]; + } +} + +//____________________________________________________________________________________________________ +- (void) viewDidLayoutSubviews +{ + [self correctFramesForOrientation : self.interfaceOrientation]; } //____________________________________________________________________________________________________ @@ -127,7 +173,7 @@ - (void) resetEditorButton editBtn.title = mode == ocmEdit ? @"Done" : @"Edit"; } -#pragma mark - Initialization code, called from initWithNibname +#pragma mark - Initialization code, called from viewDidLoad/viewWillAppear. //____________________________________________________________________________________________________ - (void) loadObjectInspector @@ -154,8 +200,6 @@ - (void) setupNavigationScrollView { navigationScrollView.delegate = self; -// navigationScrollView.canCancelContentTouches = NO; -// navigationScrollView.delaysContentTouches = NO; navigationScrollView.decelerationRate = UIScrollViewDecelerationRateFast; navigationScrollView.bounces = NO; navigationScrollView.bouncesZoom = NO; @@ -250,26 +294,17 @@ - (void) correctFramesForOrientation : (UIInterfaceOrientation) orientation { using namespace ROOT::iOS::Browser; - CGRect mainFrame; - CGRect scrollFrame; + const CGRect mainFrame = self.view.frame; + CGRect scrollFrame = mainFrame; + scrollFrame.origin = CGPoint(); - if (UIInterfaceOrientationIsPortrait(orientation)) { - mainFrame = CGRectMake(viewX, viewY, viewWP, viewHP); - scrollFrame = CGRectMake(scrollX, scrollY, scrollWP, scrollHP); - } else { - mainFrame = CGRectMake(viewX, viewY, viewWL, viewHL); - scrollFrame = CGRectMake(scrollX, scrollY, scrollWL, scrollHL); - } - - self.view.frame = mainFrame; padScrollView.frame = scrollFrame; - navigationScrollView.frame = scrollFrame; - - scrollFrame.origin = CGPointZero; + for (unsigned i = 0; i < 3; ++i) { scrollFrame.origin.x = i * scrollFrame.size.width; [navScrolls[i] resetToFrame : scrollFrame]; } + scrollFrame.origin = CGPointZero; if (fileContainer && fileContainer->GetNumberOfObjects() > 1) { @@ -291,65 +326,32 @@ - (void) correctFramesForOrientation : (UIInterfaceOrientation) orientation #pragma mark - Controller's lifecycle. //____________________________________________________________________________________________________ -- (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil +- (id) initWithCoder : (NSCoder *) aDecoder { - self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; - - if (self) { - [self view];//force view loading. - + if (self = [super initWithCoder : aDecoder]) mode = ocmNavigation; - - [self loadObjectInspector]; - [self setupScrollForEditablePadView]; - [self setupNavigationScrollView]; - //[self createEditablePad]; - } return self; } -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle +#pragma mark - Interface orientation. //____________________________________________________________________________________________________ -- (void)willAnimateRotationToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation duration : (NSTimeInterval) duration +- (void) willAnimateRotationToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation duration : (NSTimeInterval) duration { +#pragma unused(duration) [self correctFramesForOrientation : interfaceOrientation]; } //____________________________________________________________________________________________________ -- (void) didRotateFromInterfaceOrientation:(UIInterfaceOrientation)fromInterfaceOrientation +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - //Now, after rotation is finished we can show the shadow again. -} - -//____________________________________________________________________________________________________ -- (void) viewWillAppear : (BOOL)animated -{ - [self correctFramesForOrientation : self.interfaceOrientation]; -} - -//____________________________________________________________________________________________________ -- (void)viewDidUnload -{ - [super viewDidUnload]; -} - -//____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations +#pragma unused(interfaceOrientation) return YES; } +#pragma mark - editor (object inspector) related methods. + //____________________________________________________________________________________________________ - (void) animateEditor { @@ -450,23 +452,13 @@ - (void) adjustPrevNextIndices } //____________________________________________________________________________________________________ -- (void) setNavigationForObjectWithIndex : (unsigned) index fromContainer : (ROOT::iOS::Browser::FileContainer *)container; +- (void) initPadViews { - //This method is called after initWithNibName was called, so it's the second step - //of controller's construction. The default mode is ocmNavigation, so setup navigation - //views/pad etc. - mode = ocmNavigation; - - - fileContainer = container; - self.navigationItem.title = [NSString stringWithFormat : @"%s", fileContainer->GetObject(index)->GetName()]; - - currentObject = index; - [self adjustPrevNextIndices]; - + assert(fileContainer != nullptr && "initPadViews, fileContainer is null"); + // CGRect scrollFrame = navigationScrollView.frame; scrollFrame.origin = CGPointZero; - navScrolls[0] = [[PadImageScrollView alloc] initWithFrame : scrollFrame]; + navScrolls[0] = [[PadScrollView alloc] initWithFrame : scrollFrame]; if (fileContainer->GetNumberOfObjects() == 1) { [navScrolls[0] setPad : fileContainer->GetPadAttached(currentObject)]; } else { @@ -478,13 +470,13 @@ - (void) setNavigationForObjectWithIndex : (unsigned) index fromContainer : (ROO if (fileContainer->GetNumberOfObjects() > 1) { //The [1] contains the current object. scrollFrame.origin.x = scrollFrame.size.width; - navScrolls[1] = [[PadImageScrollView alloc] initWithFrame : scrollFrame]; + navScrolls[1] = [[PadScrollView alloc] initWithFrame : scrollFrame]; [navScrolls[1] setPad : fileContainer->GetPadAttached(currentObject)]; [navigationScrollView addSubview : navScrolls[1]]; //The [2] contains the next object (can be the same as previous). scrollFrame.origin.x = scrollFrame.size.width * 2; - navScrolls[2] = [[PadImageScrollView alloc] initWithFrame : scrollFrame]; + navScrolls[2] = [[PadScrollView alloc] initWithFrame : scrollFrame]; [navScrolls[2] setPad : fileContainer->GetPadAttached(nextObject)]; [navigationScrollView addSubview : navScrolls[2]]; @@ -497,24 +489,38 @@ - (void) setNavigationForObjectWithIndex : (unsigned) index fromContainer : (ROO [self createEditablePad]; } +//____________________________________________________________________________________________________ +- (void) setNavigationForObjectWithIndex : (unsigned) index fromContainer : (ROOT::iOS::Browser::FileContainer *) container; +{ + //This method is called after initWithNibName was called, so it's the second step + //of controller's construction. The default mode is ocmNavigation, so setup navigation + //views/pad etc. + mode = ocmNavigation; + + fileContainer = container; + currentObject = index; + + [self adjustPrevNextIndices]; +} + #pragma mark - delegate for editable pad's scroll-view. //____________________________________________________________________________________________________ -- (UIView *)viewForZoomingInScrollView : (UIScrollView *)scrollView +- (UIView *) viewForZoomingInScrollView : (UIScrollView *) scrollView { //For ocmEdit mode. return editablePadView; } //____________________________________________________________________________________________________ -- (void)scrollViewDidZoom:(UIScrollView *)scroll +- (void) scrollViewDidZoom : (UIScrollView *) scroll { //For ocmEdit mode. editablePadView.frame = [self centeredFrameForScrollView : scroll andUIView : editablePadView]; } //____________________________________________________________________________________________________ -- (void)scrollViewDidEndZooming:(UIScrollView *)scroll withView:(UIView *)view atScale:(float)scale +- (void) scrollViewDidEndZooming : (UIScrollView *) scroll withView : (UIView *) view atScale : (float) scale { //For ocmEdit mode. using namespace ROOT::iOS::Browser; @@ -544,10 +550,9 @@ - (void)scrollViewDidEndZooming:(UIScrollView *)scroll withView:(UIView *)view a } //____________________________________________________________________________________________________ -- (CGRect)zoomRectForScale:(float)scale withCenter:(CGPoint)center { - - CGRect zoomRect; - +- (CGRect) zoomRectForScale : (float) scale withCenter : (CGPoint) center +{ + CGRect zoomRect = {}; // the zoom rect is in the content view's coordinates. // At a zoom scale of 1.0, it would be the size of the imageScrollView's bounds. // As the zoom scale decreases, so more content is visible, the size of the rect grows. @@ -569,7 +574,7 @@ - (void) handleDoubleTapOnPad : (CGPoint) tapPt BOOL scaleToMax = YES; - if (fabs(editablePadView.frame.size.width - padW * maximumZoom) < scaledToMaxEpsilon) + if (std::abs(editablePadView.frame.size.width - padW * maximumZoom) < scaledToMaxEpsilon) scaleToMax = NO; if (scaleToMax) { @@ -578,7 +583,6 @@ - (void) handleDoubleTapOnPad : (CGPoint) tapPt const CGFloat newScale = padW * maximumZoom / editablePadView.frame.size.width; CGRect zoomRect = [self zoomRectForScale : newScale withCenter : tapPt]; [padScrollView zoomToRect : zoomRect animated : YES]; -// [self scrollViewDidEndZooming : scrollView withView : padView atScale : maximumZoom]; } else { zoomed = NO; editablePadView.frame = CGRectMake(0.f, 0.f, padW, padH); @@ -591,8 +595,7 @@ - (void) handleDoubleTapOnPad : (CGPoint) tapPt padScrollView.minimumZoomScale = 1.f; padScrollView.contentOffset = CGPointZero; padScrollView.contentSize = editablePadView.frame.size; - //[scrollView addSubview : padView]; - //[padView release]; + [editablePadView setNeedsDisplay]; [self correctFramesForOrientation : self.interfaceOrientation]; } @@ -601,10 +604,10 @@ - (void) handleDoubleTapOnPad : (CGPoint) tapPt #pragma mark - picking and editing. //____________________________________________________________________________________________________ -- (void) objectWasSelected : (TObject *)object +- (void) objectWasSelected : (TObject *) object { if (object != selectedObject) {//New object was selected. - object ? selectedObject = object : (selectedObject = fileContainer->GetPadAttached(currentObject)); + object ? selectedObject = object : selectedObject = fileContainer->GetPadAttached(currentObject); [self setupObjectInspector]; [objectInspector resetInspector]; } @@ -619,12 +622,12 @@ - (void) objectWasSelected : (TObject *)object //____________________________________________________________________________________________________ - (void) setupObjectInspector { - [objectInspector setROOTObject : selectedObject]; - [objectInspector setROOTObjectController : self]; + [objectInspector setObject : selectedObject]; + [objectInspector setObjectController : self]; } //____________________________________________________________________________________________________ -- (void) objectWasModifiedUpdateSelection : (BOOL)needUpdate +- (void) objectWasModifiedUpdateSelection : (BOOL) needUpdate { if (needUpdate) fileContainer->GetPadAttached(currentObject)->InvalidateSelection(kTRUE);//invalidate selection buffer only. the selected object is the same. @@ -638,11 +641,12 @@ - (void) objectWasModifiedUpdateSelection : (BOOL)needUpdate - (void) scrollToLeft { currentObject + 1 < fileContainer->GetNumberOfObjects() ? ++currentObject : currentObject = 0; + [self adjustPrevNextIndices]; //Current is becoming prev, next is becoming current, load new into prev, which is becoming next. - PadImageScrollView *prevView = navScrolls[1]; - PadImageScrollView *currentView = navScrolls[2]; - PadImageScrollView *nextView = navScrolls[0]; + PadScrollView *prevView = navScrolls[1]; + PadScrollView *currentView = navScrolls[2]; + PadScrollView *nextView = navScrolls[0]; CGRect prevFrame = prevView.frame; prevFrame.origin = CGPointZero; @@ -674,9 +678,9 @@ - (void) scrollToRight [self adjustPrevNextIndices]; //Current is becoming next, prev - current, prev must be loaded. - PadImageScrollView *nextView = navScrolls[1]; - PadImageScrollView *currView = navScrolls[0]; - PadImageScrollView *prevView = navScrolls[2]; + PadScrollView *nextView = navScrolls[1]; + PadScrollView *currView = navScrolls[0]; + PadScrollView *prevView = navScrolls[2]; CGRect currFrame = currView.frame; currFrame.origin.x = navigationScrollView.frame.size.width; @@ -714,8 +718,10 @@ - (void) scrollViewDidEndDecelerating : (UIScrollView *) sender #pragma mark - Save modified object as pdf and root files. //___________________________________________________________ -- (void) createPDFFileWithPage :(CGRect)pageRect fileName : (const char*)filename -{ +- (void) createPDFFileWithPage :(CGRect) pageRect fileName : (const char*) filename +{ + assert(filename != nullptr && "createPDFFileWithPage:fileName, parameter 'filename' is null"); + CFStringRef path = CFStringCreateWithCString (NULL, filename, kCFStringEncodingUTF8); CFURLRef url = CFURLCreateWithFileSystemPath (NULL, path, kCFURLPOSIXPathStyle, 0); CFRelease(path); @@ -737,7 +743,9 @@ - (void) createPDFFileWithPage :(CGRect)pageRect fileName : (const char*)filenam CGContextSetRGBFillColor(ctx, 1.f, 0.4f, 0.f, 1.f); CGContextFillRect(ctx, pageRect); - ROOT::iOS::Pad *padToSave = fileContainer->GetPadAttached(currentObject);//mode == ROOT_IOSObjectController::ocmEdit ? pad : navPad; + ROOT::iOS::Pad * const padToSave = fileContainer->GetPadAttached(currentObject); + + assert(padToSave != nullptr && "createPDFFileWithPage:fileName:, pad to save is null"); padToSave->cd(); padToSave->SetContext(ctx); @@ -754,43 +762,35 @@ - (void) createPDFFileWithPage :(CGRect)pageRect fileName : (const char*)filenam //___________________________________________________________ - (void) sendEmail { - NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); - NSString *saveDirectory = [paths objectAtIndex : 0]; - NSString *saveFileName = [NSString stringWithFormat:@"%s.pdf", fileContainer->GetObject(currentObject)->GetName()]; - NSString *newFilePath = [saveDirectory stringByAppendingPathComponent : saveFileName]; + NSArray * const paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); + NSString * const saveDirectory = [paths objectAtIndex : 0]; + NSString * const saveFileName = [NSString stringWithFormat:@"%s.pdf", fileContainer->GetObject(currentObject)->GetName()]; + NSString * const newFilePath = [saveDirectory stringByAppendingPathComponent : saveFileName]; const char *filename = [newFilePath UTF8String]; [self createPDFFileWithPage: CGRectMake(0, 0, 600, 600) fileName : filename]; -// -/* - NSString *rootFileName = [NSString stringWithFormat:@"%s.root", fileContainer->GetObject(currentObject)->GetName()]; - NSString *rootFilePath = [saveDirectory stringByAppendingPathComponent : rootFileName]; - const char *cFileName = [rootFilePath UTF8String]; - TFile f(cFileName, "recreate"); - f.cd(); - fileContainer->GetObject(currentObject)->Write(); -*/ -// - - MFMailComposeViewController * mailComposer = [[MFMailComposeViewController alloc] init]; + + MFMailComposeViewController * const mailComposer = [[MFMailComposeViewController alloc] init]; [mailComposer setSubject:@"E-mail from ROOT's iPad"]; [mailComposer setMessageBody : @"This is a test message sent to you by ROOT browser for iPad" isHTML : NO]; mailComposer.mailComposeDelegate = self; - NSString *path = [NSString stringWithFormat : @"%s", filename]; + NSString * const path = [NSString stringWithFormat : @"%s", filename]; if ([[NSFileManager defaultManager] fileExistsAtPath : path]) { - NSData *myData = [NSData dataWithContentsOfFile : path]; + NSData * const myData = [NSData dataWithContentsOfFile : path]; [mailComposer addAttachmentData : myData mimeType : @"application/octet-stream" fileName : saveFileName]; } - [self presentModalViewController : mailComposer animated : YES]; + [self presentViewController : mailComposer animated : YES completion : nil]; } //___________________________________________________________ -- (void) mailComposeController : (MFMailComposeViewController *)controller didFinishWithResult : (MFMailComposeResult)result error : (NSError *)error +- (void) mailComposeController : (MFMailComposeViewController *) controller didFinishWithResult : (MFMailComposeResult)result error : (NSError *) error { +#pragma unused(controller, result, error) + [self becomeFirstResponder]; - [self dismissModalViewControllerAnimated : YES]; + [self dismissViewControllerAnimated : YES completion : nil]; } @end diff --git a/test/ios/RootBrowser/Src/Browser/Controllers/SearchViewController.h b/test/ios/RootBrowser/Src/Browser/Controllers/SearchViewController.h new file mode 100644 index 0000000000000..baf35a269df52 --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Controllers/SearchViewController.h @@ -0,0 +1,20 @@ +#import <UIKit/UIKit.h> + +@class FileContainerElement; +@class SearchViewController; + +@protocol SearchViewDelegate +- (void) searchController : (SearchViewController *) controller didSelectKey : (FileContainerElement *) key; +@end + + +@interface SearchViewController : UITableViewController + +@property (nonatomic, weak) id<SearchViewDelegate> delegate; +@property (nonatomic) NSMutableArray *keys; + +- (void) filterResultsUsingString : (NSString *) filterString; + +@end + + diff --git a/test/ios/RootBrowser/SearchController.mm b/test/ios/RootBrowser/Src/Browser/Controllers/SearchViewController.mm similarity index 63% rename from test/ios/RootBrowser/SearchController.mm rename to test/ios/RootBrowser/Src/Browser/Controllers/SearchViewController.mm index ed78628c80d4a..4ec3bf1ced278 100644 --- a/test/ios/RootBrowser/SearchController.mm +++ b/test/ios/RootBrowser/Src/Browser/Controllers/SearchViewController.mm @@ -1,13 +1,14 @@ #import "FileContainerElement.h" -#import "SearchController.h" +#import "SearchViewController.h" -@implementation SearchController { +@implementation SearchViewController { NSArray *visibleKeys; } @synthesize delegate; @synthesize keys; +//____________________________________________________________________________________________________ - (void) setKeys : (NSMutableArray *)k { keys = k; @@ -16,15 +17,16 @@ - (void) setKeys : (NSMutableArray *)k [self.tableView reloadData]; } +//____________________________________________________________________________________________________ - (void) viewDidLoad { [super viewDidLoad]; self.title = @"Objects and directories"; - self.contentSizeForViewInPopover = CGSizeMake(600.f, 280.f); + self.preferredContentSize = CGSizeMake(600.f, 280.f); } - +//____________________________________________________________________________________________________ - (void) viewWillAppear : (BOOL)animated { @@ -32,19 +34,13 @@ - (void) viewWillAppear : (BOOL)animated [super viewWillAppear : animated]; } - -- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation +//____________________________________________________________________________________________________ +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { return YES; } - -- (void)viewDidUnload -{ - [super viewDidUnload]; -} - - +//____________________________________________________________________________________________________ - (void) filterResultsUsingString : (NSString *) filterString { // If the search string is zero-length, then restore the full list @@ -62,11 +58,13 @@ - (void) filterResultsUsingString : (NSString *) filterString #pragma mark Table view methods +//____________________________________________________________________________________________________ - (NSInteger) tableView : (UITableView *)tableView numberOfRowsInSection : (NSInteger)section { return [visibleKeys count]; } +//____________________________________________________________________________________________________ - (UITableViewCell *) tableView : (UITableView *)tableView cellForRowAtIndexPath : (NSIndexPath *)indexPath { UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier : @"Cell"]; @@ -78,11 +76,11 @@ - (UITableViewCell *) tableView : (UITableView *)tableView cellForRowAtIndexPath return cell; } - +//____________________________________________________________________________________________________ - (void) tableView : (UITableView *)tableView didSelectRowAtIndexPath : (NSIndexPath *)indexPath { // Notify the delegate if a row is selected. - [delegate searchesController : self didSelectKey : (FileContainerElement *)[visibleKeys objectAtIndex : indexPath.row]]; + [delegate searchController : self didSelectKey : (FileContainerElement *)[visibleKeys objectAtIndex : indexPath.row]]; } @end diff --git a/test/ios/RootBrowser/Src/Browser/Controllers/SlideshowViewController.h b/test/ios/RootBrowser/Src/Browser/Controllers/SlideshowViewController.h new file mode 100644 index 0000000000000..4f838c0a80959 --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Controllers/SlideshowViewController.h @@ -0,0 +1,17 @@ +#import <UIKit/UIKit.h> + +namespace ROOT { +namespace iOS { +namespace Browser { + +class FileContainer; + +} +} +} + +@interface SlideshowViewController : UIViewController <UIScrollViewDelegate> + +- (void) setFileContainer : (ROOT::iOS::Browser::FileContainer *) container; + +@end diff --git a/test/ios/RootBrowser/SlideshowController.mm b/test/ios/RootBrowser/Src/Browser/Controllers/SlideshowViewController.mm similarity index 64% rename from test/ios/RootBrowser/SlideshowController.mm rename to test/ios/RootBrowser/Src/Browser/Controllers/SlideshowViewController.mm index c41eba9f6b5f4..96781b8c986b3 100644 --- a/test/ios/RootBrowser/SlideshowController.mm +++ b/test/ios/RootBrowser/Src/Browser/Controllers/SlideshowViewController.mm @@ -1,17 +1,20 @@ -#import <stdlib.h> +#import <cassert> #import <QuartzCore/QuartzCore.h> -#import "SlideshowController.h" -#import "SlideView.h" +#import "SlideshowViewController.h" +#import "PadSlideView.h" //C++ imports. #import "IOSPad.h" #import "FileUtils.h" -@implementation SlideshowController { - SlideView *padViews[2];//The current and the next in a slide show. +@implementation SlideshowViewController { + __weak IBOutlet UIView *parentView; + __weak IBOutlet UIView *padParentView; + + PadSlideView *padViews[2];//The current and the next in a slide show. unsigned visiblePad; unsigned nCurrentObject; @@ -19,19 +22,19 @@ @implementation SlideshowController { ROOT::iOS::Browser::FileContainer *fileContainer; NSTimer *timer; + + BOOL viewDidAppear; } +#pragma mark - Geometry/views/subviews. + //____________________________________________________________________________________________________ - (void) correctFramesForOrientation : (UIInterfaceOrientation) orientation { - CGRect mainFrame; - UIInterfaceOrientationIsPortrait(orientation) ? mainFrame = CGRectMake(0.f, 44.f, 768.f, 960.f) - : (mainFrame = CGRectMake(0.f, 44.f, 1024.f, 704.f)); +#pragma unused(orientation) - - parentView.frame = mainFrame; - - CGRect padFrame = [SlideView slideFrame]; + const CGRect mainFrame = self.view.frame; + CGRect padFrame = [PadSlideView slideFrame]; padFrame.origin = CGPointMake(mainFrame.size.width / 2 - padFrame.size.width / 2, mainFrame.size.height / 2 - padFrame.size.height / 2); padParentView.frame = padFrame; @@ -46,100 +49,96 @@ - (void) correctFramesForOrientation : (UIInterfaceOrientation) orientation //____________________________________________________________________________________________________ - (void) initPadViews { - const CGRect padFrame = [SlideView slideFrame]; + const CGRect padFrame = [PadSlideView slideFrame]; unsigned nObjects = fileContainer->GetNumberOfObjects(); if (nObjects > 2) nObjects = 2; for (unsigned i = 0; i < nObjects; ++i) { - padViews[i] = [[SlideView alloc] initWithFrame : padFrame]; + padViews[i] = [[PadSlideView alloc] initWithFrame : padFrame]; [padParentView addSubview : padViews[i]]; padViews[i].hidden = YES; } } +#pragma mark - Fugly two-phase initialization. + //____________________________________________________________________________________________________ -- (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil fileContainer : (ROOT::iOS::Browser::FileContainer *)container +- (id) initWithCoder : (NSCoder *) aDecoder { - self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; - - if (self) { - [self view]; - - fileContainer = container; - - if (fileContainer->GetNumberOfObjects()) { - [self initPadViews]; - - nCurrentObject = 0; - visiblePad = 0; - - [padViews[0] setPad : fileContainer->GetPadAttached(0)]; - [padViews[0] setNeedsDisplay]; - - if (fileContainer->GetNumberOfObjects() > 1) { - [padViews[1] setPad:fileContainer->GetPadAttached(1)]; - [padParentView addSubview : padViews[1]]; - } - - //Ready for show now. - } + if (self = [super initWithCoder : aDecoder]) { + fileContainer = nullptr; + viewDidAppear = NO; } - + return self; } //____________________________________________________________________________________________________ -- (void) dealloc -{ - if (timer) - [timer invalidate]; -} - -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning +- (void) setFileContainer : (ROOT::iOS::Browser::FileContainer *) container { - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. + assert(container != nullptr && "setFileContainer:, parameter 'container' is null"); + + fileContainer = container; } #pragma mark - View lifecycle //____________________________________________________________________________________________________ -- (void)viewDidLoad +- (void) dealloc { - [super viewDidLoad]; - - [self correctFramesForOrientation : self.interfaceOrientation]; + if (timer) + [timer invalidate]; } //____________________________________________________________________________________________________ -- (void)viewDidUnload +- (void) viewDidLoad { - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; + assert(fileContainer != nullptr && "viewDidLoad, fileContainer is null"); + + [super viewDidLoad]; + [self initPadViews]; } //____________________________________________________________________________________________________ -- (void) viewWillAppear : (BOOL)animated +- (void) viewDidAppear : (BOOL) animated { - [self correctFramesForOrientation : self.interfaceOrientation]; - padViews[0].hidden = NO; + [super viewDidAppear : animated]; + + assert(fileContainer != nullptr && "viewDidAppera:, fileContainer is null"); + + if (!viewDidAppear) { + if (fileContainer->GetNumberOfObjects()) { + nCurrentObject = 0; + visiblePad = 0; + + [padViews[0] setPad : fileContainer->GetPadAttached(0)]; + [padViews[0] setNeedsDisplay]; + + if (fileContainer->GetNumberOfObjects() > 1) { + [padViews[1] setPad : fileContainer->GetPadAttached(1)]; + [padViews[1] setNeedsDisplay]; + } + + padViews[0].hidden = NO; + } + + if (fileContainer->GetNumberOfObjects() > 1) + timer = [NSTimer scheduledTimerWithTimeInterval : 2.f target : self selector : @selector(changeViews) userInfo : nil repeats : YES]; + + viewDidAppear = YES; + } } //____________________________________________________________________________________________________ -- (void) viewDidAppear : (BOOL)animated +- (void) viewDidLayoutSubviews { - if (fileContainer->GetNumberOfObjects() > 1) - timer = [NSTimer scheduledTimerWithTimeInterval : 2.f target : self selector : @selector(changeViews) userInfo : nil repeats : YES]; + [self correctFramesForOrientation : self.interfaceOrientation]; } - //____________________________________________________________________________________________________ -- (void) viewDidDisappear:(BOOL)animated +- (void) viewDidDisappear : (BOOL)animated { if (timer) { [timer invalidate]; @@ -148,15 +147,16 @@ - (void) viewDidDisappear:(BOOL)animated } //____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - // Return YES for supported orientations - +#pragma unused(interfaceOrientation) return YES; } //____________________________________________________________________________________________________ -- (void)willAnimateRotationToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation duration : (NSTimeInterval)duration { +- (void) willAnimateRotationToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation duration : (NSTimeInterval) duration +{ +#pragma unused(duration) [self correctFramesForOrientation : interfaceOrientation]; } diff --git a/test/ios/RootBrowser/Src/Browser/FileContainerElement.h b/test/ios/RootBrowser/Src/Browser/FileContainerElement.h new file mode 100644 index 0000000000000..60b8803089a7c --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/FileContainerElement.h @@ -0,0 +1,6 @@ +@interface FileContainerElement : NSObject + +@property (nonatomic) NSString *elementName; +@property (nonatomic) unsigned elementIndex; + +@end diff --git a/test/ios/RootBrowser/FileContainerElement.mm b/test/ios/RootBrowser/Src/Browser/FileContainerElement.mm similarity index 100% rename from test/ios/RootBrowser/FileContainerElement.mm rename to test/ios/RootBrowser/Src/Browser/FileContainerElement.mm diff --git a/test/ios/RootBrowser/Src/Browser/Views/FileShortcutView.h b/test/ios/RootBrowser/Src/Browser/Views/FileShortcutView.h new file mode 100644 index 0000000000000..240e3d706c1f3 --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Views/FileShortcutView.h @@ -0,0 +1,24 @@ +#import <UIKit/UIKit.h> + + +namespace ROOT { +namespace iOS { +namespace Browser { + +class FileContainer; + +} +} +} + +@interface FileShortcutView : UIView + +@property (nonatomic, readonly) NSString *fileName; + ++ (CGFloat) iconWidth; ++ (CGFloat) iconHeight; + +- (id) initWithFrame : (CGRect) frame controller : (UIViewController *) controller fileContainer : (ROOT::iOS::Browser::FileContainer *) container; +- (ROOT::iOS::Browser::FileContainer *) getFileContainer; + +@end diff --git a/test/ios/RootBrowser/Src/Browser/Views/FileShortcutView.mm b/test/ios/RootBrowser/Src/Browser/Views/FileShortcutView.mm new file mode 100644 index 0000000000000..41ddcf93e4807 --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Views/FileShortcutView.mm @@ -0,0 +1,111 @@ +#import <cassert> + +#import "FileCollectionViewController.h" +#import "FileShortcutView.h" + +//C++ imports. +#import "FileUtils.h" + +@implementation FileShortcutView { + __weak UIViewController *controller; + + UIImage *filePictogram; + + ROOT::iOS::Browser::FileContainer *fileContainer; +} + +@synthesize fileName; + +//____________________________________________________________________________________________________ ++ (CGFloat) iconWidth +{ + return 150.f; +} + +//____________________________________________________________________________________________________ ++ (CGFloat) textHeight +{ + return 50.f; +} + +//____________________________________________________________________________________________________ ++ (CGFloat) iconHeight +{ + return [FileShortcutView iconWidth] + [FileShortcutView textHeight]; +} + +//____________________________________________________________________________________________________ +- (id) initWithFrame : (CGRect) frame controller : (UIViewController *) viewController + fileContainer : (ROOT::iOS::Browser::FileContainer *) container; +{ + assert(viewController != nil && "initWithFrame:controller:fileContainer:, parameter 'viewController' is nil"); + assert(container != nullptr && "initWithFrame:controller:fileContainer:, parameter 'container' is nil"); + + if (self = [super initWithFrame : frame]) { + // + controller = viewController; + fileContainer = container; + // + fileName = [NSString stringWithFormat : @"%s", fileContainer->GetFileName()]; + // + filePictogram = [UIImage imageNamed : @"file_icon.png"]; + UITapGestureRecognizer * const tap = [[UITapGestureRecognizer alloc] initWithTarget : self action : @selector(handleTap)]; + [self addGestureRecognizer : tap]; + UILongPressGestureRecognizer * const longPress = [[UILongPressGestureRecognizer alloc] initWithTarget : self action : @selector(handleLongPress:)]; + [self addGestureRecognizer : longPress]; + + self.opaque = NO; + } + + return self; +} + +//____________________________________________________________________________________________________ +- (void) dealloc +{ + //Crazy name qualification :( + ROOT::iOS::Browser::FileContainer::DeleteFileContainer(fileContainer); +} + +//____________________________________________________________________________________________________ +- (void) drawRect : (CGRect) rect +{ + //Draw the pictogram for ROOT's file. + const CGPoint topLeftPicCorner = CGPointMake(rect.size.width / 2 - filePictogram.size.width / 2, + (rect.size.height - [FileShortcutView textHeight]) / 2 - filePictogram.size.height / 2); + [filePictogram drawAtPoint : topLeftPicCorner]; + + UIFont * const font = [UIFont systemFontOfSize : 16]; + NSMutableParagraphStyle * const paragraphStyle = [[NSParagraphStyle defaultParagraphStyle] mutableCopy]; + paragraphStyle.lineBreakMode = NSLineBreakByWordWrapping; + paragraphStyle.alignment = NSTextAlignmentCenter; + NSDictionary * const attributes = @{NSFontAttributeName : font, NSParagraphStyleAttributeName : paragraphStyle, + NSForegroundColorAttributeName : [UIColor whiteColor]}; + const CGRect textRect = CGRectMake(0.f, [FileShortcutView iconHeight] - [FileShortcutView textHeight], [FileShortcutView iconWidth], [FileShortcutView textHeight]); + [fileName drawInRect : textRect withAttributes : attributes]; +} + +//____________________________________________________________________________________________________ +- (void) handleTap +{ + assert(controller != nil && "handleTap, controller is nil"); + [(FileCollectionViewController *)controller fileWasSelected : self]; +} + +//____________________________________________________________________________________________________ +- (void) handleLongPress : (UILongPressGestureRecognizer *) longPress +{ + assert(longPress != nil && "handleLongPress:, parameter 'longPress' is nil"); + assert(controller != nil && "handleLongPress:, controller is nil"); + + if (longPress.state == UIGestureRecognizerStateBegan) + [(FileCollectionViewController *)controller tryToDelete : self]; +} + +//____________________________________________________________________________________________________ +- (ROOT::iOS::Browser::FileContainer *) getFileContainer +{ + return fileContainer; +} + +@end diff --git a/test/ios/RootBrowser/Src/Browser/Views/ObjectShortcutView.h b/test/ios/RootBrowser/Src/Browser/Views/ObjectShortcutView.h new file mode 100644 index 0000000000000..ceebd408037bf --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Views/ObjectShortcutView.h @@ -0,0 +1,20 @@ +#import <UIKit/UIKit.h> + +@class FileContentViewController; +@class SpotObjectView; + +@interface ObjectShortcutView : UIView + +@property (nonatomic, readonly) SpotObjectView *spot; +@property (nonatomic, readonly) BOOL isDirectory; +@property (nonatomic, readonly) unsigned objectIndex; + ++ (CGFloat) iconWidth; ++ (CGFloat) iconHeight; ++ (CGFloat) textHeight; ++ (CGRect) defaultRect; + +- (id) initWithFrame : (CGRect) frame controller : (FileContentViewController *) c forObjectAtIndex : (unsigned) objIndex withThumbnail : (UIImage *) thumbnail; +- (id) initWithFrame : (CGRect) frame controller : (FileContentViewController *) c forFolderAtIndex : (unsigned) index; + +@end diff --git a/test/ios/RootBrowser/Src/Browser/Views/ObjectShortcutView.mm b/test/ios/RootBrowser/Src/Browser/Views/ObjectShortcutView.mm new file mode 100644 index 0000000000000..ef508b56633ce --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Views/ObjectShortcutView.mm @@ -0,0 +1,142 @@ +#import <cassert> + +#import "FileContentViewController.h" +#import "ObjectShortcutView.h" +#import "SpotObjectView.h" + +//C++ (ROOT) imports. +#import "FileUtils.h" +#import "TObject.h" + +const CGSize folderIconSize = CGSizeMake(128.f, 128.f); + +@implementation ObjectShortcutView { + __weak FileContentViewController *controller; + + NSString *objectName; + UIImage *icon; +} + +@synthesize isDirectory; +@synthesize objectIndex; +@synthesize spot; + +//____________________________________________________________________________________________________ ++ (CGFloat) iconWidth +{ + return 150.f; +} + +//____________________________________________________________________________________________________ ++ (CGFloat) iconHeight +{ + return 150.f; +} + +//____________________________________________________________________________________________________ ++ (CGFloat) textHeight +{ + return 100.f; +} + +//____________________________________________________________________________________________________ ++ (CGRect) defaultRect +{ + return CGRectMake(0.f, 0.f, [ObjectShortcutView iconWidth], [ObjectShortcutView iconHeight] + [ObjectShortcutView textHeight]); +} + +//____________________________________________________________________________________________________ +- (id) initWithFrame : (CGRect) frame controller : (FileContentViewController*) c forFolderAtIndex : (unsigned) index +{ + assert(c != nil && "initWithFrame:controller:forFolderAtIndex:, parameter 'c' is nil"); + assert(c.fileContainer != nullptr && "initWithFrame:controller:forFolderAtIndex:, fileContainer is null"); + + using namespace ROOT::iOS::Browser; + + if (self = [super initWithFrame : frame]) { + frame.origin = CGPointZero; + frame.size.height = [ObjectShortcutView iconHeight]; + + spot = [[SpotObjectView alloc] initWithFrame : frame]; + [self addSubview : spot]; + + controller = c; + objectIndex = index; + + const FileContainer *cont = controller.fileContainer->GetDirectory(index); + isDirectory = YES; + objectName = [NSString stringWithFormat : @"%s", cont->GetFileName()]; + icon = [UIImage imageNamed : @"directory.png"]; + self.opaque = NO; + + //Tap gesture to select a directory. + UITapGestureRecognizer * const tap = [[UITapGestureRecognizer alloc] initWithTarget : self action : @selector(handleTap)]; + [self addGestureRecognizer : tap]; + } + + return self; +} + +//____________________________________________________________________________________________________ +- (id) initWithFrame : (CGRect) frame controller : (FileContentViewController*) c forObjectAtIndex : (unsigned) objIndex withThumbnail : (UIImage *) thumbnail +{ + assert(c != nil && "initWithFrame:controller:forObjectAtIndex:withThumbnail:, parameter 'c' is nil"); + assert(c.fileContainer != nullptr && "initWithFrame:controller:forObjectAtIndex:withThumbnail:, fileContainer is null"); + + using namespace ROOT::iOS::Browser; + + if (self = [super initWithFrame : frame]) { + frame.origin = CGPointZero; + frame.size.height = [ObjectShortcutView iconHeight]; + + spot = [[SpotObjectView alloc] initWithFrame : frame]; + [self addSubview : spot]; + + //ROOT's staff. + controller = c; + objectIndex = objIndex; + + const TObject *obj = controller.fileContainer->GetObject(objIndex); + isDirectory = NO; + objectName = [NSString stringWithFormat : @"%s", obj->GetName()]; + icon = thumbnail; + + self.opaque = NO; + + //Tap gesture to select an object. + UITapGestureRecognizer * const tap = [[UITapGestureRecognizer alloc] initWithTarget : self action : @selector(handleTap)]; + [self addGestureRecognizer : tap]; + } + + return self; +} + +//____________________________________________________________________________________________________ +- (void) drawRect : (CGRect) rect +{ + if (isDirectory) { + //Directory's icon is 128 x 128 < than thumbnail. + CGPoint topLeft = CGPointMake([ObjectShortcutView iconWidth] / 2 - folderIconSize.width / 2, [ObjectShortcutView iconHeight] / 2 - folderIconSize.height / 2); + [icon drawAtPoint : topLeft]; + } else + [icon drawAtPoint : CGPoint()]; + + // + UIFont * const font = [UIFont systemFontOfSize : 16]; + NSMutableParagraphStyle * const paragraphStyle = [[NSParagraphStyle defaultParagraphStyle] mutableCopy]; + paragraphStyle.lineBreakMode = NSLineBreakByWordWrapping; + paragraphStyle.alignment = NSTextAlignmentCenter; + NSDictionary * const attributes = @{NSFontAttributeName : font, NSParagraphStyleAttributeName : paragraphStyle, + NSForegroundColorAttributeName : [UIColor whiteColor]}; + // + const CGRect textRect = CGRectMake(0.f, [ObjectShortcutView iconHeight], [ObjectShortcutView iconWidth], [ObjectShortcutView textHeight]); + [objectName drawInRect : textRect withAttributes : attributes]; +} + +//____________________________________________________________________________________________________ +- (void) handleTap +{ + [controller selectObjectFromFile : self]; +} + +@end diff --git a/test/ios/RootBrowser/Src/Browser/Views/PadEditorScrollView.h b/test/ios/RootBrowser/Src/Browser/Views/PadEditorScrollView.h new file mode 100644 index 0000000000000..ffc44fec46ada --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Views/PadEditorScrollView.h @@ -0,0 +1,13 @@ +// +//This is scroll-view for pad in editable mode. +// +//The problem - we are processing too many gestures: +//scroll view itself supports several gestures like +//double taps, pans, pinches. Pad view which is inside +//this scroll view, also supports gestures like: tap (to select an object), +//pan (to zoom/unzoom plot's axes). + +#import <UIKit/UIKit.h> + +@interface PadEditorScrollView : UIScrollView +@end diff --git a/test/ios/RootBrowser/ScrollViewWithPadView.mm b/test/ios/RootBrowser/Src/Browser/Views/PadEditorScrollView.mm similarity index 59% rename from test/ios/RootBrowser/ScrollViewWithPadView.mm rename to test/ios/RootBrowser/Src/Browser/Views/PadEditorScrollView.mm index 4b916e2d9bb63..1cc721930b7e3 100644 --- a/test/ios/RootBrowser/ScrollViewWithPadView.mm +++ b/test/ios/RootBrowser/Src/Browser/Views/PadEditorScrollView.mm @@ -1,17 +1,19 @@ -#import "ScrollViewWithPadView.h" +#import "PadEditorScrollView.h" #import "PadView.h" -@implementation ScrollViewWithPadView +@implementation PadEditorScrollView //____________________________________________________________________________________________________ -- (UIView *) hitTest : (CGPoint)point withEvent : (UIEvent *)event +- (UIView *) hitTest : (CGPoint) point withEvent : (UIEvent *) event { - UIView * v = [super hitTest : point withEvent : event]; + UIView * const v = [super hitTest : point withEvent : event]; if ([v isKindOfClass : [PadView class]]) { - PadView *padView = (PadView *)v; + PadView * const padView = (PadView *)v; if ([padView pointOnSelectedObject : [self convertPoint : point toView : padView]]) { + //If we have some object in this point, we can probably pan (zoom/unzoom an axis) + //or just tap on object, selecting it. self.canCancelContentTouches = NO; self.delaysContentTouches = NO; [padView addPanRecognizer]; diff --git a/test/ios/RootBrowser/Src/Browser/Views/PadScrollView.h b/test/ios/RootBrowser/Src/Browser/Views/PadScrollView.h new file mode 100644 index 0000000000000..651d8d057a0d2 --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Views/PadScrollView.h @@ -0,0 +1,26 @@ +#import <UIKit/UIKit.h> + +// +//This is a special scroll view, containing +//a pad view, which can be zoomed and scrolled (if zoomed). +// +// + +namespace ROOT { +namespace iOS { + +class Pad; + +} +} + +@interface PadScrollView : UIScrollView <UIScrollViewDelegate> + ++ (CGRect) defaultImageFrame; + +- (id) initWithFrame : (CGRect)frame; + +- (void) setPad : (ROOT::iOS::Pad *) pad; +- (void) resetToFrame : (CGRect) frame; + +@end diff --git a/test/ios/RootBrowser/PadImageScrollView.mm b/test/ios/RootBrowser/Src/Browser/Views/PadScrollView.mm similarity index 85% rename from test/ios/RootBrowser/PadImageScrollView.mm rename to test/ios/RootBrowser/Src/Browser/Views/PadScrollView.mm index a99131a2c7542..6f3e82abed677 100644 --- a/test/ios/RootBrowser/PadImageScrollView.mm +++ b/test/ios/RootBrowser/Src/Browser/Views/PadScrollView.mm @@ -1,8 +1,8 @@ -#import <stdlib.h> +#import <cmath> #import <QuartzCore/QuartzCore.h> -#import "PadImageScrollView.h" +#import "PadScrollView.h" #import "PadView.h" //C++ (ROOT) imports. @@ -14,7 +14,7 @@ static const CGFloat maxZoom = 2.f; static const CGFloat minZoom = 1.f; -@implementation PadImageScrollView { +@implementation PadScrollView { ROOT::iOS::Pad *pad; PadView *nestedView; @@ -33,9 +33,9 @@ - (CGPoint) adjustOriginForFrame : (CGRect)frame withSize : (CGSize) sz } //____________________________________________________________________________________________________ -- (void) initPadView : (CGRect)frame +- (void) initPadView : (CGRect) frame { - CGRect padFrame = [PadImageScrollView defaultImageFrame]; + CGRect padFrame = [PadScrollView defaultImageFrame]; padFrame.origin = [self adjustOriginForFrame : frame withSize : padFrame.size]; nestedView = [[PadView alloc] initImmutableViewWithFrame : padFrame]; @@ -46,7 +46,7 @@ - (void) initPadView : (CGRect)frame //____________________________________________________________________________________________________ -- (void) setContentSize : (CGSize) size contentOffset : (CGPoint)offset minScale : (CGFloat)min maxScale : (CGFloat)max scale : (CGFloat)scale +- (void) setContentSize : (CGSize) size contentOffset : (CGPoint) offset minScale : (CGFloat) min maxScale : (CGFloat) max scale : (CGFloat) scale { self.maximumZoomScale = max; self.minimumZoomScale = min; @@ -56,7 +56,7 @@ - (void) setContentSize : (CGSize) size contentOffset : (CGPoint)offset minScale } //____________________________________________________________________________________________________ -- (id) initWithFrame : (CGRect)frame +- (id) initWithFrame : (CGRect) frame { if (self = [super initWithFrame : frame]) { self.delegate = self; //hehehehe @@ -79,7 +79,7 @@ - (id) initWithFrame : (CGRect)frame //____________________________________________________________________________________________________ - (void) clearScroll { - [self setContentSize : [PadImageScrollView defaultImageFrame].size contentOffset : CGPointZero minScale : minZoom maxScale : maxZoom scale : 1]; + [self setContentSize : [PadScrollView defaultImageFrame].size contentOffset : CGPointZero minScale : minZoom maxScale : maxZoom scale : 1]; [nestedView removeFromSuperview]; nestedView = nil; } @@ -87,7 +87,7 @@ - (void) clearScroll #pragma mark - Image/pad/geometry management. //____________________________________________________________________________________________________ -- (void) setPad : (ROOT::iOS::Pad *)p +- (void) setPad : (ROOT::iOS::Pad *) p { pad = p; pad->SetViewWH(defaultImageW, defaultImageH); @@ -118,7 +118,7 @@ - (void) resetToFrame : (CGRect) newFrame } //_________________________________________________________________ -- (CGRect)centeredFrameForScrollView:(UIScrollView *)scroll andUIView:(UIView *)rView +- (CGRect) centeredFrameForScrollView : (UIScrollView *) scroll andUIView : (UIView *) rView { CGSize boundsSize = scroll.bounds.size; CGRect frameToCenter = rView.frame; @@ -141,20 +141,20 @@ - (CGRect)centeredFrameForScrollView:(UIScrollView *)scroll andUIView:(UIView *) } //____________________________________________________________________________________________________ -- (void)scrollViewDidZoom:(UIScrollView *)scroll +- (void) scrollViewDidZoom : (UIScrollView *) scroll { nestedView.frame = [self centeredFrameForScrollView : scroll andUIView : nestedView]; } //____________________________________________________________________________________________________ -- (void)scrollViewDidEndZooming : (UIScrollView *)scroll withView : (UIView *)view atScale : (float)scale +- (void) scrollViewDidEndZooming : (UIScrollView *) scroll withView : (UIView *) view atScale : (float) scale { const CGPoint offset = [scroll contentOffset]; const CGRect newFrame = nestedView.frame; [scroll setZoomScale : 1.f]; - const unsigned base = [PadImageScrollView defaultImageFrame].size.width; + const unsigned base = [PadScrollView defaultImageFrame].size.width; scroll.minimumZoomScale = base / newFrame.size.width; scroll.maximumZoomScale = maxZoom * base / newFrame.size.width; @@ -173,13 +173,14 @@ - (void)scrollViewDidEndZooming : (UIScrollView *)scroll withView : (UIView *)vi } //____________________________________________________________________________________________________ -- (UIView *) viewForZoomingInScrollView:(UIScrollView *)scrollView +- (UIView *) viewForZoomingInScrollView : (UIScrollView *) scrollView { return nestedView; } //____________________________________________________________________________________________________ -- (CGRect)zoomRectForScale:(float)scale withCenter:(CGPoint)center { +- (CGRect) zoomRectForScale : (float) scale withCenter : (CGPoint) center +{ CGRect zoomRect; @@ -197,10 +198,10 @@ - (CGRect)zoomRectForScale:(float)scale withCenter:(CGPoint)center { } //____________________________________________________________________________________________________ -- (void) handleDoubleTap : (UITapGestureRecognizer *)tap +- (void) handleDoubleTap : (UITapGestureRecognizer *) tap { //Identify, if we should unzoom. - if (fabs(nestedView.frame.size.width - maxZoom * defaultImageW) < 10) { + if (std::abs(nestedView.frame.size.width - maxZoom * defaultImageW) < 10) { [self resetToFrame : self.frame]; } else { //Zoom in. diff --git a/test/ios/RootBrowser/Src/Browser/Views/PadSelectionView.h b/test/ios/RootBrowser/Src/Browser/Views/PadSelectionView.h new file mode 100644 index 0000000000000..118f349830c23 --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Views/PadSelectionView.h @@ -0,0 +1,26 @@ +#import <UIKit/UIKit.h> + +// +//PadSelectionView is a special transparent view on top of a pad view, +//rendering the picked object in a special way. +// + +namespace ROOT { +namespace iOS { + +class Pad; + +} +} + +@interface PadSelectionView : UIView + +@property (nonatomic) BOOL panActive; +@property (nonatomic) CGPoint panStart; +@property (nonatomic) CGPoint currentPanPoint; +@property (nonatomic) BOOL verticalPanDirection; + +- (id) initWithFrame : (CGRect) frame withPad : (ROOT::iOS::Pad *) p; +- (void) setPad : (ROOT::iOS::Pad *) p; + +@end diff --git a/test/ios/RootBrowser/SelectionView.mm b/test/ios/RootBrowser/Src/Browser/Views/PadSelectionView.mm similarity index 67% rename from test/ios/RootBrowser/SelectionView.mm rename to test/ios/RootBrowser/Src/Browser/Views/PadSelectionView.mm index cf89d4f1ede91..42b6a9a037ff5 100644 --- a/test/ios/RootBrowser/SelectionView.mm +++ b/test/ios/RootBrowser/Src/Browser/Views/PadSelectionView.mm @@ -1,7 +1,8 @@ -#import <CoreGraphics/CGContext.h> +#import <cassert> +#import <cstring> #import "IOSSelectionMarkers.h" -#import "SelectionView.h" +#import "PadSelectionView.h" #import "Constants.h" #import "PadView.h" #import "TAxis.h" @@ -9,7 +10,19 @@ //C++ (ROOT) imports. #import "IOSPad.h" -@implementation SelectionView { +namespace { + +//____________________________________________________________________________________________________ +void SetShadowColor(CGContextRef ctx) +{ + assert(ctx != nullptr && "SetShadowColor, parameter 'ctx' is null"); + UIColor * const shadowColor = [UIColor colorWithRed : 0.f green : 0.f blue : 0.f alpha : 0.7f]; + CGContextSetShadowWithColor(ctx, CGSizeMake(3.f, 3.f), 4.f, shadowColor.CGColor); +} + +} + +@implementation PadSelectionView { ROOT::iOS::Pad *pad; } @@ -19,18 +32,11 @@ @implementation SelectionView { @synthesize verticalPanDirection; //____________________________________________________________________________________________________ -+ (void) setShadowColor : (CGContextRef) ctx +- (id) initWithFrame : (CGRect) frame withPad : (ROOT::iOS::Pad *) p { - UIColor *shadowColor = [UIColor colorWithRed : 0.f green : 0.f blue : 0.f alpha : 0.7f]; - CGContextSetShadowWithColor(ctx, CGSizeMake(3.f, 3.f), 4.f, shadowColor.CGColor); -} - -//____________________________________________________________________________________________________ -- (id) initWithFrame : (CGRect)frame withPad : (ROOT::iOS::Pad *) p -{ - self = [super initWithFrame:frame]; + assert(p != nullptr && "initWithFrame:withPad:, parameter 'p' is null"); - if (self) { + if (self = [super initWithFrame : frame]) { pad = p; self.opaque = NO; } @@ -39,29 +45,37 @@ - (id) initWithFrame : (CGRect)frame withPad : (ROOT::iOS::Pad *) p } //____________________________________________________________________________________________________ -- (void) showSelectedAxis : (CGContextRef)ctx withRect : (CGRect)rect +- (void) showSelectedAxis : (CGContextRef) ctx withRect : (CGRect) rect { //"Special case" function to show axis selection. using namespace ROOT::iOS; - const CGFloat xMin = pad->GetUxmin(); - const CGFloat xMax = pad->GetUxmax(); - const CGFloat yMin = pad->GetUymin(); - const CGFloat yMax = pad->GetUymax(); - ROOT::iOS::SpaceConverter converter(rect.size.width, pad->GetX1(), pad->GetX2(), rect.size.height, pad->GetY1(), pad->GetY2()); + assert(ctx != nullptr && "showSelectedAxis:withRect:, parameter 'ctx' is null"); + assert(pad != nullptr && "showSelectedAxis:withRect:, pad is null"); + + const CGFloat xMin = CGFloat(pad->GetUxmin()); + const CGFloat xMax = CGFloat(pad->GetUxmax()); + const CGFloat yMin = CGFloat(pad->GetUymin()); + const CGFloat yMax = CGFloat(pad->GetUymax()); + + const SpaceConverter converter(rect.size.width, pad->GetX1(), pad->GetX2(), + rect.size.height, pad->GetY1(), pad->GetY2()); + GraphicUtils::DrawSelectionMarker(ctx, CGPointMake(converter.XToView(xMin), converter.YToView(yMin))); const TAxis *axis = static_cast<TAxis *>(pad->GetSelected()); - if (!strcmp(axis->GetName(), "xaxis")) { + if (!std::strcmp(axis->GetName(), "xaxis")) { GraphicUtils::DrawSelectionMarker(ctx, CGPointMake(converter.XToView(xMax), converter.YToView(yMin))); - } else if (!strcmp(axis->GetName(), "yaxis")){ + } else if (!std::strcmp(axis->GetName(), "yaxis")){ GraphicUtils::DrawSelectionMarker(ctx, CGPointMake(converter.XToView(xMin), converter.YToView(yMax))); }//else is "Z" but we do not care. } //____________________________________________________________________________________________________ -- (void)drawRect : (CGRect)rect +- (void) drawRect : (CGRect) rect { + assert(pad != nullptr && "drawRect:, pad is null"); + CGContextRef ctx = UIGraphicsGetCurrentContext(); CGContextSaveGState(ctx); @@ -75,9 +89,8 @@ - (void)drawRect : (CGRect)rect pad->SetContext(ctx); //Selected object will cast a shadow. - //if (useShadows) - if (!ROOT::iOS::Browser::deviceIsiPad3) { - [SelectionView setShadowColor : ctx]; + if (!ROOT::iOS::Browser::deviceHasRetina) { + SetShadowColor(ctx); pad->PaintSelected(); } else { CGContextTranslateCTM(ctx, 2.5f, 2.5f); @@ -105,7 +118,7 @@ - (void)drawRect : (CGRect)rect } //____________________________________________________________________________________________________ -- (BOOL)pointInside:(CGPoint)point withEvent:(UIEvent *) event +- (BOOL) pointInside : (CGPoint) point withEvent : (UIEvent *) event { //Thanks to gyim, //http://stackoverflow.com/questions/1694529/allowing-interaction-with-a-uiview-under-another-uiview @@ -113,7 +126,7 @@ - (BOOL)pointInside:(CGPoint)point withEvent:(UIEvent *) event } //____________________________________________________________________________________________________ -- (void) setPad : (ROOT::iOS::Pad *)p +- (void) setPad : (ROOT::iOS::Pad *) p { pad = p; } diff --git a/test/ios/RootBrowser/Src/Browser/Views/PadSlideView.h b/test/ios/RootBrowser/Src/Browser/Views/PadSlideView.h new file mode 100644 index 0000000000000..e195857b5c2cc --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Views/PadSlideView.h @@ -0,0 +1,25 @@ +#import <UIKit/UIKit.h> + +// +//PadSlideView is a small special pad view to use in a "slideshow" animation. +//Does not support any object picking/editing, just a surface to render and +//a view to animate a transition. +// + +namespace ROOT { +namespace iOS { + +class Pad; + +} +} + +@interface PadSlideView : UIView + ++ (CGSize) slideSize; ++ (CGRect) slideFrame; + +- (id) initWithFrame : (CGRect) rect; +- (void) setPad : (ROOT::iOS::Pad *) pad; + +@end diff --git a/test/ios/RootBrowser/SlideView.mm b/test/ios/RootBrowser/Src/Browser/Views/PadSlideView.mm similarity index 76% rename from test/ios/RootBrowser/SlideView.mm rename to test/ios/RootBrowser/Src/Browser/Views/PadSlideView.mm index 45229b74ca0e9..5cf5f4f208d49 100644 --- a/test/ios/RootBrowser/SlideView.mm +++ b/test/ios/RootBrowser/Src/Browser/Views/PadSlideView.mm @@ -1,14 +1,15 @@ +#import <cassert> + #import <QuartzCore/QuartzCore.h> -#import <CoreGraphics/CGContext.h> -#import "SlideView.h" +#import "PadSlideView.h" //C++ (ROOT) imports. #import "IOSPad.h" const CGRect slideFrame = CGRectMake(0.f, 0.f, 650.f, 650.f); -@implementation SlideView { +@implementation PadSlideView { ROOT::iOS::Pad *pad; } @@ -25,11 +26,9 @@ + (CGRect) slideFrame } //____________________________________________________________________________________________________ -- (id) initWithFrame : (CGRect)frame +- (id) initWithFrame : (CGRect) frame { - self = [super initWithFrame : frame]; - - if (self) { + if (self = [super initWithFrame : frame]) { self.layer.shadowOpacity = 0.3f; self.layer.shadowColor = [UIColor blackColor].CGColor; self.layer.shadowOffset = CGSizeMake(10.f, 10.f); @@ -39,13 +38,16 @@ - (id) initWithFrame : (CGRect)frame return self; } -- (void) setPad : (ROOT::iOS::Pad *)newPad +//____________________________________________________________________________________________________ +- (void) setPad : (ROOT::iOS::Pad *) newPad { + assert(newPad != nullptr && "setPad:, parameter 'newPad' is null"); + pad = newPad; } //____________________________________________________________________________________________________ -- (void) drawRect : (CGRect)rect +- (void) drawRect : (CGRect) rect { CGContextRef ctx = UIGraphicsGetCurrentContext(); diff --git a/test/ios/RootBrowser/PadView.h b/test/ios/RootBrowser/Src/Browser/Views/PadView.h similarity index 59% rename from test/ios/RootBrowser/PadView.h rename to test/ios/RootBrowser/Src/Browser/Views/PadView.h index fdb4a9bbd73d4..92a56feb9f53c 100644 --- a/test/ios/RootBrowser/PadView.h +++ b/test/ios/RootBrowser/Src/Browser/Views/PadView.h @@ -15,18 +15,18 @@ class Pad; } } -@class ROOTObjectController; -@class SelectionView; +@class ObjectViewController; +@class PadSelectionView; @interface PadView : UIView -@property (nonatomic, retain) SelectionView *selectionView; -@property (assign) BOOL zoomed; +@property (nonatomic, readonly) PadSelectionView *selectionView; +@property (nonatomic) BOOL zoomed; -- (id) initWithFrame : (CGRect)frame controller : (ROOTObjectController *)c forPad : (ROOT::iOS::Pad*)pad; -- (id) initImmutableViewWithFrame : (CGRect)frame; +- (id) initWithFrame : (CGRect) frame controller : (ObjectViewController *) c forPad : (ROOT::iOS::Pad*) pad; +- (id) initImmutableViewWithFrame : (CGRect) frame; -- (void) setPad : (ROOT::iOS::Pad *)newPad; +- (void) setPad : (ROOT::iOS::Pad *) newPad; - (void) clearPad; - (BOOL) pointOnSelectedObject : (CGPoint) pt; diff --git a/test/ios/RootBrowser/PadView.mm b/test/ios/RootBrowser/Src/Browser/Views/PadView.mm similarity index 64% rename from test/ios/RootBrowser/PadView.mm rename to test/ios/RootBrowser/Src/Browser/Views/PadView.mm index 214c75ee6fb96..0d252ec955769 100644 --- a/test/ios/RootBrowser/PadView.mm +++ b/test/ios/RootBrowser/Src/Browser/Views/PadView.mm @@ -1,13 +1,9 @@ -#import <stddef.h> -#import <string.h> -#import <stdlib.h> -#import <math.h> +#import <cstddef> +#import <cstring> +#import <vector> -#import <CoreGraphics/CoreGraphics.h> -#import <CoreGraphics/CGContext.h> - -#import "ROOTObjectController.h" -#import "SelectionView.h" +#import "ObjectViewController.h" +#import "PadSelectionView.h" #import "Constants.h" #import "PadView.h" @@ -18,12 +14,10 @@ const CGFloat tapInterval = 0.15f; -@interface PadView () { +@implementation PadView { + __weak ObjectViewController *controller; + ROOT::iOS::Pad *pad; - - __weak ROOTObjectController *controller; - - CGFloat currentScale; BOOL panActive; @@ -33,30 +27,25 @@ @interface PadView () { BOOL isMutable; } -- (void) handleSingleTap; -- (void) handleDoubleTap; - -@end - -@implementation PadView - @synthesize selectionView; @synthesize zoomed; //____________________________________________________________________________________________________ -- (id) initWithFrame : (CGRect)frame controller : (ROOTObjectController *)c forPad : (ROOT::iOS::Pad*)pd +- (id) initWithFrame : (CGRect) frame controller : (ObjectViewController *) c forPad : (ROOT::iOS::Pad*) pd { - self = [super initWithFrame : frame]; + assert(c != nil && "initWithFrame:forPad:, parameter 'c' is nil"); + assert(pd != nullptr && "initWithFrame:forPad:, parameter 'pd' is null"); - if (self) { + if (self = [super initWithFrame : frame]) { controller = c; pad = pd; isMutable = YES; frame.origin = CGPointZero; - selectionView = [[SelectionView alloc] initWithFrame : frame withPad : pad]; - selectionView.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; + selectionView = [[PadSelectionView alloc] initWithFrame : frame withPad : pad]; + selectionView.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | + UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; selectionView.hidden = YES; [self addSubview : selectionView]; } @@ -65,13 +54,13 @@ - (id) initWithFrame : (CGRect)frame controller : (ROOTObjectController *)c forP } //____________________________________________________________________________________________________ -- (id) initImmutableViewWithFrame : (CGRect)frame +- (id) initImmutableViewWithFrame : (CGRect) frame { if (self = [super initWithFrame : frame]) { controller = nil; pad = nullptr; selectionView = nil; - + isMutable = NO; self.multipleTouchEnabled = NO; @@ -81,18 +70,20 @@ - (id) initImmutableViewWithFrame : (CGRect)frame } //____________________________________________________________________________________________________ -- (void) setPad : (ROOT::iOS::Pad *)newPad +- (void) setPad : (ROOT::iOS::Pad *) newPad { + assert(newPad != nullptr && "setPad:, parameter 'newPad' is null"); + pad = newPad; if (isMutable) [selectionView setPad : newPad]; } //____________________________________________________________________________________________________ -- (void)drawRect : (CGRect)rect +- (void) drawRect : (CGRect) rect { // Drawing code - if (!pad) + if (!pad)//assert instead??? return; CGContextRef ctx = UIGraphicsGetCurrentContext(); @@ -101,6 +92,7 @@ - (void)drawRect : (CGRect)rect pad->SetViewWH(rect.size.width, rect.size.height); CGContextTranslateCTM(ctx, 0.f, rect.size.height); CGContextScaleCTM(ctx, 1.f, -1.f); + pad->cd(); pad->SetContext(ctx); pad->Paint(); @@ -112,6 +104,7 @@ - (void)drawRect : (CGRect)rect //____________________________________________________________________________________________________ - (void) clearPad { + assert(pad != nullptr && "clearPad, pad is null"); pad->Clear(); } @@ -127,13 +120,15 @@ - (void) removePanRecognizer panActive = NO; } -#pragma mark - Picking related stuff here. +#pragma mark - Picking/gesture handling and related stuff here. //____________________________________________________________________________________________________ -- (CGImageRef) initCGImageForPicking +- (UIImage *) createImageForPicking { + assert(pad != nullptr && "createImageForPicking, pad is null"); + if (!isMutable) - return nullptr; + return nil; using namespace ROOT::iOS::Browser; const CGRect rect = CGRectMake(0.f, 0.f, padW, padH); @@ -159,24 +154,27 @@ - (CGImageRef) initCGImageForPicking pad->SetContext(ctx); pad->PaintForSelection(); - UIImage *uiImageForPicking = UIGraphicsGetImageFromCurrentImageContext();//autoreleased UIImage. - CGImageRef cgImageForPicking = uiImageForPicking.CGImage; - CGImageRetain(cgImageForPicking);//It must live as long, as I need :) + UIImage * const uiImageForPicking = UIGraphicsGetImageFromCurrentImageContext();//autoreleased UIImage. UIGraphicsEndImageContext(); - return cgImageForPicking; - + return uiImageForPicking; } //____________________________________________________________________________________________________ -- (BOOL) fillPickingBufferFromCGImage : (CGImageRef) cgImage +- (BOOL) fillPickingBufferFromImage : (UIImage *) image { + assert(image != nil && "fillPickingBufferFromImage:, parameter 'image' is nil"); + assert(pad != nullptr && "fillPickingBufferFromImage:, pad is null"); + if (!isMutable) return NO; + CGImageRef cgImage = image.CGImage; + const size_t pixelsW = CGImageGetWidth(cgImage); const size_t pixelsH = CGImageGetHeight(cgImage); + //Declare the number of bytes per row. Each pixel in the bitmap //is represented by 4 bytes; 8 bits each of red, green, blue, and //alpha. @@ -190,41 +188,36 @@ - (BOOL) fillPickingBufferFromCGImage : (CGImageRef) cgImage return NO; } - unsigned char *buffer = (unsigned char*)malloc(bitmapByteCount); - if (!buffer) { - //Log error: memory allocation failed. + try { + std::vector<unsigned char> buffer(bitmapByteCount); + // Create the bitmap context. We want pre-multiplied ARGB, 8-bits + // per component. Regardless of what the source image format is + // (CMYK, Grayscale, and so on) it will be converted over to the format + // specified here by CGBitmapContextCreate. + CGContextRef ctx = CGBitmapContextCreate(&buffer[0], pixelsW, pixelsH, 8, bitmapBytesPerRow, colorSpace, kCGImageAlphaPremultipliedFirst); CGColorSpaceRelease(colorSpace); - return NO; - } - // Create the bitmap context. We want pre-multiplied ARGB, 8-bits - // per component. Regardless of what the source image format is - // (CMYK, Grayscale, and so on) it will be converted over to the format - // specified here by CGBitmapContextCreate. - CGContextRef ctx = CGBitmapContextCreate(buffer, pixelsW, pixelsH, 8, bitmapBytesPerRow, colorSpace, kCGImageAlphaPremultipliedFirst); + if (!ctx) + return NO; - CGColorSpaceRelease(colorSpace); + const CGRect rect = CGRectMake(0.f, 0.f, pixelsW, pixelsH); + //Draw the image to the bitmap context. Once we draw, the memory + //allocated for the context for rendering will then contain the + //raw image data in the specified color space. + + CGContextSetAllowsAntialiasing(ctx, 0);//Check, if I need this for a bitmap. + CGContextDrawImage(ctx, rect, cgImage); - if (!ctx) { - //Log error: bitmap context creation failed. - free(buffer); - return NO; - } - - const CGRect rect = CGRectMake(0.f, 0.f, pixelsW, pixelsH); - //Draw the image to the bitmap context. Once we draw, the memory - //allocated for the context for rendering will then contain the - //raw image data in the specified color space. - - CGContextSetAllowsAntialiasing(ctx, 0);//Check, if I need this for a bitmap. - CGContextDrawImage(ctx, rect, cgImage); + pad->SetSelectionBuffer(pixelsW, pixelsH, &buffer[0]); + // When finished, release the context + CGContextRelease(ctx); - pad->SetSelectionBuffer(pixelsW, pixelsH, buffer); - // When finished, release the context - CGContextRelease(ctx); - free(buffer); + return YES; + } catch (const std::bad_alloc &e) { + CGColorSpaceRelease(colorSpace); + } - return YES; + return NO; } //____________________________________________________________________________________________________ @@ -233,18 +226,15 @@ - (BOOL) initPadPicking if (!isMutable) return NO; - CGImageRef cgImage = [self initCGImageForPicking]; - if (!cgImage) + UIImage * const image = [self createImageForPicking]; + if (!image) return NO; - const BOOL res = [self fillPickingBufferFromCGImage : cgImage]; - CGImageRelease(cgImage); - - return res; + return [self fillPickingBufferFromImage : image]; } //____________________________________________________________________________________________________ -- (CGPoint) scaledPoint : (CGPoint)pt +- (CGPoint) scaledPoint : (CGPoint) pt { const CGFloat scale = ROOT::iOS::Browser::padW / self.frame.size.width; return CGPointMake(pt.x * scale, pt.y * scale); @@ -254,6 +244,7 @@ - (CGPoint) scaledPoint : (CGPoint)pt - (BOOL) pointOnSelectedObject : (CGPoint) pt { //check if there is any object in pt. + assert(pad != nullptr && "pointOnSelectedObject:, pad is null"); if (!isMutable) return NO; @@ -262,39 +253,45 @@ - (BOOL) pointOnSelectedObject : (CGPoint) pt return NO; const CGPoint newPt = [self scaledPoint : pt]; - if (pad->GetSelected() == pad->ObjectInPoint(newPt.x, newPt.y)) - return YES; - - return NO; + return pad->GetSelected() == pad->ObjectInPoint(newPt.x, newPt.y); } +//Touch events processing. + //____________________________________________________________________________________________________ - (void) handleSingleTap { //Make a selection, fill the editor, disable double tap. + assert(pad != nullptr && "handleSingleTap, pad is null"); if (!isMutable) return; - - const CGPoint scaledTapPt = [self scaledPoint : tapPt]; + if (!pad->SelectionIsValid() && ![self initPadPicking]) return; - + + const CGPoint scaledTapPt = [self scaledPoint : tapPt]; pad->Pick(scaledTapPt.x, scaledTapPt.y); //Tell controller that selection has probably changed. [controller objectWasSelected : pad->GetSelected()]; + + //There were no second tap withing tapInterval, ignore the subsequent tap. processSecondTap = NO; } //____________________________________________________________________________________________________ -- (void) touchesBegan : (NSSet *)touches withEvent : (UIEvent *)event +- (void) touchesBegan : (NSSet *) touches withEvent : (UIEvent *) event { +#pragma unused(event) + + assert(touches != nil && "touchesBegan:withEvent:, parameter 'touches' is nil"); + if (!isMutable) return; - UITouch *touch = [touches anyObject]; + UITouch * const touch = [touches anyObject]; if (touch.tapCount == 1) { - //Interaction has started. + //The first tap - interaction has started. tapPt = [touch locationInView : self]; //Gesture can be any of them: processSecondTap = YES; @@ -302,8 +299,13 @@ - (void) touchesBegan : (NSSet *)touches withEvent : (UIEvent *)event } //____________________________________________________________________________________________________ -- (void) touchesMoved : (NSSet *)touches withEvent : (UIEvent *)event +- (void) touchesMoved : (NSSet *) touches withEvent : (UIEvent *) event { +#pragma unused(event) + + assert(touches != nil && "touchesMoved:withEvent:, parameter 'touches' is nil"); + assert(pad != nullptr && "touchesMoved:withEvent:, pad is null"); + if (!isMutable) return; @@ -313,7 +315,7 @@ - (void) touchesMoved : (NSSet *)touches withEvent : (UIEvent *)event if (TAxis *axis = dynamic_cast<TAxis *>(selected)) { if (!selectionView.panActive) { selectionView.panActive = YES; - if (!strcmp(axis->GetName(), "xaxis")) + if (!std::strcmp(axis->GetName(), "xaxis")) selectionView.verticalPanDirection = NO; else selectionView.verticalPanDirection = YES; @@ -333,19 +335,28 @@ - (void) touchesMoved : (NSSet *)touches withEvent : (UIEvent *)event } //____________________________________________________________________________________________________ -- (void) touchesEnded : (NSSet *)touches withEvent : (UIEvent *)event +- (void) touchesEnded : (NSSet *) touches withEvent : (UIEvent *) event { +#pragma unused(event) + + assert(touches != nil && "touchesEnded:withEvent:, parameter 'touches' is nil"); + assert(pad != nullptr && "touchesEnded:withEvent:, pad is null"); + if (!isMutable) return; - UITouch *touch = [touches anyObject]; + UITouch * const touch = [touches anyObject]; if (touch.tapCount == 1 && !panActive) { [self performSelector : @selector(handleSingleTap) withObject : nil afterDelay : tapInterval]; } else if (touch.tapCount == 2 && processSecondTap) { + //The second tap was done withing tapInterval, thus we + //should process the gesture as a double tap. + //Cancel handleSingleTap: [NSObject cancelPreviousPerformRequestsWithTarget : self]; + // [self handleDoubleTap]; } - + if (selectionView.panActive) { panActive = NO; selectionView.panActive = NO; @@ -354,7 +365,7 @@ - (void) touchesEnded : (NSSet *)touches withEvent : (UIEvent *)event pad->InvalidateSelection(kTRUE); [self setNeedsDisplay]; - UIScrollView *parent = (UIScrollView *)[self superview]; + UIScrollView * const parent = (UIScrollView *)[self superview]; parent.canCancelContentTouches = YES; parent.delaysContentTouches = YES; } @@ -364,11 +375,14 @@ - (void) touchesEnded : (NSSet *)touches withEvent : (UIEvent *)event - (void) handleDoubleTap { //This is zoom/unzoom action or axis unzoom. + + assert(pad != nullptr && "handleDoubleTap, pad is null"); + if (!isMutable) return; const CGPoint scaledTapPt = [self scaledPoint : tapPt]; - TAxis *axis = dynamic_cast<TAxis *>(pad->GetSelected()); + TAxis * const axis = dynamic_cast<TAxis *>(pad->GetSelected()); if (!pad->SelectionIsValid() && ![self initPadPicking]) return; @@ -381,7 +395,7 @@ - (void) handleDoubleTap [controller handleDoubleTapOnPad : tapPt]; } - UIScrollView *parent = (UIScrollView *)[self superview]; + UIScrollView * const parent = (UIScrollView *)[self superview]; parent.canCancelContentTouches = YES; parent.delaysContentTouches = YES; } diff --git a/test/ios/RootBrowser/Src/Browser/Views/SpotObjectView.h b/test/ios/RootBrowser/Src/Browser/Views/SpotObjectView.h new file mode 100644 index 0000000000000..4fdb2e35a8263 --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Views/SpotObjectView.h @@ -0,0 +1,5 @@ +#import <UIKit/UIKit.h> + +@interface SpotObjectView : UIView + +@end diff --git a/test/ios/RootBrowser/Src/Browser/Views/SpotObjectView.mm b/test/ios/RootBrowser/Src/Browser/Views/SpotObjectView.mm new file mode 100644 index 0000000000000..f380e8c593ead --- /dev/null +++ b/test/ios/RootBrowser/Src/Browser/Views/SpotObjectView.mm @@ -0,0 +1,17 @@ +#import "SpotObjectView.h" + +@implementation SpotObjectView + +//____________________________________________________________________________________________________ +- (id) initWithFrame : (CGRect) frame +{ + if (self = [super initWithFrame : frame]) { + self.alpha = 0.f; + self.multipleTouchEnabled = NO; + self.backgroundColor = [UIColor orangeColor]; + } + + return self; +} + +@end diff --git a/test/ios/RootBrowser/root_browser/main.m b/test/ios/RootBrowser/Src/Core/main.mm similarity index 100% rename from test/ios/RootBrowser/root_browser/main.m rename to test/ios/RootBrowser/Src/Core/main.mm diff --git a/test/ios/RootBrowser/root_browser/root_browserAppDelegate.h b/test/ios/RootBrowser/Src/Core/root_browserAppDelegate.h similarity index 100% rename from test/ios/RootBrowser/root_browser/root_browserAppDelegate.h rename to test/ios/RootBrowser/Src/Core/root_browserAppDelegate.h diff --git a/test/ios/RootBrowser/root_browser/root_browserAppDelegate.mm b/test/ios/RootBrowser/Src/Core/root_browserAppDelegate.mm similarity index 62% rename from test/ios/RootBrowser/root_browser/root_browserAppDelegate.mm rename to test/ios/RootBrowser/Src/Core/root_browserAppDelegate.mm index 5f689a02354e0..5f40c71423fb6 100644 --- a/test/ios/RootBrowser/root_browser/root_browserAppDelegate.mm +++ b/test/ios/RootBrowser/Src/Core/root_browserAppDelegate.mm @@ -1,4 +1,5 @@ #import <cstddef> +#import <cassert> #import <vector> #import <sys/sysctl.h> @@ -6,24 +7,15 @@ #import "TApplication.h" +#import "FileCollectionViewController.h" #import "root_browserAppDelegate.h" -#import "RootFileController.h" #import "Constants.h" - -namespace ROOT { -namespace iOS { - -bool deviceIsiPad3 = false; - -} -} - @implementation root_browserAppDelegate { TApplication *rootApp; UINavigationController *navigationController; - __weak RootFileController *rc; + __weak FileCollectionViewController *rc; } @synthesize window=_window; @@ -31,45 +23,38 @@ @implementation root_browserAppDelegate { //____________________________________________________________________________________________________ - (void) initRootController { - RootFileController *rootController = [[RootFileController alloc] initWithNibName : @"RootFileController" bundle : nil]; - rc = rootController; + UIStoryboard * const storyboard = [UIStoryboard storyboardWithName : @"Browser_iPad" bundle : nil]; + navigationController = (UINavigationController *)[storyboard instantiateViewControllerWithIdentifier : ROOT::iOS::Browser::ROOTBrowserViewControllerID]; + assert([navigationController.topViewController isKindOfClass : [FileCollectionViewController class]] && + "initRootController, top view controller is either nil or has a wrong type"); + + rc = (FileCollectionViewController *)navigationController.topViewController; - NSString *demosPath = [[NSBundle mainBundle] pathForResource : @"demos" ofType : @"root"]; + NSString * const demosPath = [[NSBundle mainBundle] pathForResource : @"demos" ofType : @"root"]; if (demosPath) - [rootController addRootFile : demosPath]; + [rc addRootFile : demosPath]; - navigationController = [[UINavigationController alloc] initWithRootViewController : rootController]; - - navigationController.navigationBar.barStyle = UIBarStyleBlackTranslucent; - navigationController.delegate = rootController; - - [self.window addSubview : navigationController.view]; + [self.window setRootViewController : navigationController]; [self.window makeKeyAndVisible]; } //____________________________________________________________________________________________________ -- (BOOL) application : (UIApplication *)application didFinishLaunchingWithOptions : (NSDictionary *)launchOptions +- (BOOL) application : (UIApplication *) application didFinishLaunchingWithOptions : (NSDictionary *) launchOptions { - // Override point for customization after application launch. +#pragma unused(application, launchOptions) + rootApp = new TApplication("iosApp", 0, 0); [self initRootController]; - std::size_t dataSize = 0; - sysctlbyname("hw.machine", nullptr, &dataSize, nullptr, 0); - if (dataSize) { - std::vector<char> line(dataSize); - sysctlbyname("hw.machine", &line[0], &dataSize, nullptr, 0); - NSString *machineName = [NSString stringWithCString : &line[0] encoding : NSASCIIStringEncoding]; - if ([machineName hasPrefix : @"iPad3,"]) - ROOT::iOS::Browser::deviceIsiPad3 = true; - } + ROOT::iOS::Browser::deviceHasRetina = [UIScreen mainScreen].scale > 1.f ? true : false; return YES; } //____________________________________________________________________________________________________ -- (void) applicationWillResignActive : (UIApplication *)application +- (void) applicationWillResignActive : (UIApplication *) application { +#pragma unused(application) /* Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user @@ -80,8 +65,9 @@ types of temporary interruptions (such as an incoming phone call or SMS message) } //____________________________________________________________________________________________________ -- (void) applicationDidEnterBackground : (UIApplication *)application +- (void) applicationDidEnterBackground : (UIApplication *) application { +#pragma unused(application) /* Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. @@ -91,8 +77,9 @@ - (void) applicationDidEnterBackground : (UIApplication *)application } //____________________________________________________________________________________________________ -- (void) applicationWillEnterForeground : (UIApplication *)application +- (void) applicationWillEnterForeground : (UIApplication *) application { +#pragma unused(application) /* Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. @@ -100,8 +87,9 @@ - (void) applicationWillEnterForeground : (UIApplication *)application } //____________________________________________________________________________________________________ -- (void) applicationDidBecomeActive : (UIApplication *)application +- (void) applicationDidBecomeActive : (UIApplication *) application { +#pragma unused(application) /* Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. @@ -109,8 +97,9 @@ Restart any tasks that were paused (or not yet started) while the application wa } //____________________________________________________________________________________________________ -- (void) applicationWillTerminate : (UIApplication *)application +- (void) applicationWillTerminate : (UIApplication *) application { +#pragma unused(application) /* Called when the application is about to terminate. Save data if appropriate. @@ -119,12 +108,16 @@ - (void) applicationWillTerminate : (UIApplication *)application } //____________________________________________________________________________________________________ -- (BOOL)application:(UIApplication *)application openURL:(NSURL *)url sourceApplication:(NSString *)sourceApplication annotation:(id)annotation +- (BOOL) application : (UIApplication *) application openURL : (NSURL *) url + sourceApplication : (NSString *) sourceApplication annotation : (id) annotation { +#pragma unused(application, sourceApplication, annotation) + while ([navigationController.viewControllers count] > 1) [navigationController popViewControllerAnimated : NO]; [rc addRootFile : [url path]]; + return YES; } diff --git a/test/ios/RootBrowser/HorizontalPickerDelegate.h b/test/ios/RootBrowser/Src/CustomUI/HorizontalPickerDelegate.h similarity index 57% rename from test/ios/RootBrowser/HorizontalPickerDelegate.h rename to test/ios/RootBrowser/Src/CustomUI/HorizontalPickerDelegate.h index 39185d6ef5d07..469c548e00307 100644 --- a/test/ios/RootBrowser/HorizontalPickerDelegate.h +++ b/test/ios/RootBrowser/Src/CustomUI/HorizontalPickerDelegate.h @@ -4,6 +4,6 @@ @protocol HorizontalPickerDelegate <NSObject> -- (void) item : (unsigned)item wasSelectedInPicker : (HorizontalPickerView *)picker; +- (void) item : (unsigned) item wasSelectedInPicker : (HorizontalPickerView *) picker; @end diff --git a/test/ios/RootBrowser/HorizontalPickerView.h b/test/ios/RootBrowser/Src/CustomUI/HorizontalPickerView.h similarity index 100% rename from test/ios/RootBrowser/HorizontalPickerView.h rename to test/ios/RootBrowser/Src/CustomUI/HorizontalPickerView.h diff --git a/test/ios/RootBrowser/HorizontalPickerView.mm b/test/ios/RootBrowser/Src/CustomUI/HorizontalPickerView.mm similarity index 100% rename from test/ios/RootBrowser/HorizontalPickerView.mm rename to test/ios/RootBrowser/Src/CustomUI/HorizontalPickerView.mm diff --git a/test/ios/RootBrowser/RangeSlider.h b/test/ios/RootBrowser/Src/CustomUI/RangeSlider.h similarity index 100% rename from test/ios/RootBrowser/RangeSlider.h rename to test/ios/RootBrowser/Src/CustomUI/RangeSlider.h diff --git a/test/ios/RootBrowser/RangeSlider.mm b/test/ios/RootBrowser/Src/CustomUI/RangeSlider.mm similarity index 100% rename from test/ios/RootBrowser/RangeSlider.mm rename to test/ios/RootBrowser/Src/CustomUI/RangeSlider.mm diff --git a/test/ios/RootBrowser/ScrollViewWithPickers.h b/test/ios/RootBrowser/Src/CustomUI/ScrollViewWithPickers.h similarity index 100% rename from test/ios/RootBrowser/ScrollViewWithPickers.h rename to test/ios/RootBrowser/Src/CustomUI/ScrollViewWithPickers.h diff --git a/test/ios/RootBrowser/ScrollViewWithPickers.mm b/test/ios/RootBrowser/Src/CustomUI/ScrollViewWithPickers.mm similarity index 100% rename from test/ios/RootBrowser/ScrollViewWithPickers.mm rename to test/ios/RootBrowser/Src/CustomUI/ScrollViewWithPickers.mm diff --git a/test/ios/RootBrowser/TransparentToolbar.h b/test/ios/RootBrowser/Src/CustomUI/TransparentToolbar.h similarity index 100% rename from test/ios/RootBrowser/TransparentToolbar.h rename to test/ios/RootBrowser/Src/CustomUI/TransparentToolbar.h diff --git a/test/ios/RootBrowser/TransparentToolbar.m b/test/ios/RootBrowser/Src/CustomUI/TransparentToolbar.m similarity index 77% rename from test/ios/RootBrowser/TransparentToolbar.m rename to test/ios/RootBrowser/Src/CustomUI/TransparentToolbar.m index 731649c01a35f..ea91955e0b440 100644 --- a/test/ios/RootBrowser/TransparentToolbar.m +++ b/test/ios/RootBrowser/Src/CustomUI/TransparentToolbar.m @@ -2,7 +2,7 @@ @implementation TransparentToolbar -- (void) drawRect:(CGRect)rect +- (void) drawRect : (CGRect)rect { //Ask apple, why I need this. } diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisFontInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisFontInspector.h new file mode 100644 index 0000000000000..73195f1e4d2ee --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisFontInspector.h @@ -0,0 +1,17 @@ +#import "ObjectInspectorComponent.h" + +//A simple view/controller. +//AxisFontInspector's view contains a picker with font names and a 'back' button. +//New font is set for either axis title or axis labels. + +@interface AxisFontInspector : UIViewController <UIPickerViewDelegate, UIPickerViewDataSource, ObjectInspectorComponent> + +//For for axis title or labels. +- (instancetype) initWithNibName : (NSString *) nibName isTitle : (BOOL) isTitle; + +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) o; + +- (IBAction) back; + +@end diff --git a/test/ios/RootBrowser/AxisFontInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisFontInspector.mm similarity index 60% rename from test/ios/RootBrowser/AxisFontInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisFontInspector.mm index 9d356f6848b97..723442622478b 100644 --- a/test/ios/RootBrowser/AxisFontInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisFontInspector.mm @@ -1,4 +1,6 @@ -#import "ROOTObjectController.h" +#import <cassert> + +#import "ObjectViewController.h" #import "AxisFontInspector.h" //C++ (ROOT) imports. @@ -10,7 +12,7 @@ const CGFloat defaultCellW = 180.f; const CGFloat defaultCellH = 44.f; -NSString *fixedFonts[] = //These are the strings with font names to use with UILabel. +NSString * const fixedFonts[] = //These are the strings with font names to use with UILabel. { @"TimesNewRomanPS-ItalicMT", @"TimesNewRomanPS-BoldMT", @@ -27,7 +29,7 @@ @"TimesNewRomanPSMT" }; -NSString *fixedFontNames[] = //these are the strings to show in a picker view. +NSString * const fixedFontNames[] = //these are the strings to show in a picker view. { @"Times New Roman", @"Times New Roman", @@ -49,81 +51,64 @@ } @implementation AxisFontInspector { - ROOT_IOSObjectInspector::AxisFontInspectorMode mode; - __weak ROOTObjectController *controller; + __weak IBOutlet UILabel *titleLabel; + __weak IBOutlet UIPickerView *fontPicker; + + BOOL isTitleFont; + __weak ObjectViewController *controller; TAxis *object; } //____________________________________________________________________________________________________ -- (id)initWithNibName : (NSString *)nibName mode : (ROOT_IOSObjectInspector::AxisFontInspectorMode)m +- (instancetype) initWithNibName : (NSString *) nibName isTitle : (BOOL) isTitle { - using namespace ROOT_IOSObjectInspector; - - self = [super initWithNibName : nibName bundle : nil]; - - [self view]; - - if (self) { + if (self = [super initWithNibName : nibName bundle : nil]) { + [self view]; // Custom initialization - mode = m; - if (mode == afimTitleFont) + isTitleFont = isTitle; + + if (isTitleFont) titleLabel.text = @"Title font:"; - else if (mode == afimLabelFont) + else titleLabel.text = @"Label font:"; } return self; } -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. -} +#pragma mark - Interface orientation. -#pragma mark - View lifecycle //____________________________________________________________________________________________________ -- (void)viewDidLoad +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. -} +#pragma unused(interfaceOrientation) -//____________________________________________________________________________________________________ -- (void)viewDidUnload -{ - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} - -//____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations return YES; } +#pragma mark - ObjectInspectorComponent. + //____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c +- (void) setObjectController : (ObjectViewController *) c { + assert(c != nil && "setObjectController:, parameter 'c' is nil"); + controller = c; } //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (void) setObject : (TObject *) o { - using namespace ROOT_IOSObjectInspector; + assert(o != nullptr && "setObject:, parameter 'o' is null"); object = dynamic_cast<TAxis *>(o); + //The result of cast is checked one level up. Font_t fontIndex = 0; - if (mode == afimTitleFont) + if (isTitleFont) fontIndex = object->GetTitleFont() / 10 - 1; - else if (mode == afimLabelFont) + else fontIndex = object->GetLabelFont() / 10 - 1; if (fontIndex < 0 || fontIndex > nFixedFonts) @@ -132,54 +117,62 @@ - (void) setROOTObject : (TObject *)o [fontPicker selectRow : fontIndex inComponent : 0 animated : NO]; } -#pragma mark - color/pattern picker's dataSource. +#pragma mark - font name picker's dataSource. //____________________________________________________________________________________________________ -- (CGFloat)pickerView : (UIPickerView *)pickerView widthForComponent : (NSInteger)component +- (CGFloat) pickerView : (UIPickerView *) pickerView widthForComponent : (NSInteger) component { +#pragma unused(pickerView, component) return defaultCellW; } //____________________________________________________________________________________________________ -- (CGFloat)pickerView : (UIPickerView *)pickerView rowHeightForComponent : (NSInteger)component +- (CGFloat) pickerView : (UIPickerView *) pickerView rowHeightForComponent : (NSInteger) component { +#pragma unused(pickerView, component) return defaultCellH; } //____________________________________________________________________________________________________ -- (NSInteger)pickerView : (UIPickerView *)pickerView numberOfRowsInComponent : (NSInteger)component +- (NSInteger) pickerView : (UIPickerView *) pickerView numberOfRowsInComponent : (NSInteger) component { +#pragma unused(pickerView, component) return nFixedFonts; } //____________________________________________________________________________________________________ -- (NSInteger)numberOfComponentsInPickerView:(UIPickerView *)pickerView +- (NSInteger) numberOfComponentsInPickerView : (UIPickerView *) pickerView { +#pragma unused(pickerView) return 1; } -#pragma mark color/pattern picker's delegate. +#pragma mark font name picker's delegate. //____________________________________________________________________________________________________ -- (UIView *) pickerView : (UIPickerView *)pickerView viewForRow : (NSInteger)row forComponent : (NSInteger)component reusingView : (UIView *)view +- (UIView *) pickerView : (UIPickerView *) pickerView viewForRow : (NSInteger)row forComponent : (NSInteger) component reusingView : (UIView *) view { - UILabel *label = [[UILabel alloc] initWithFrame : CGRectMake(0.f, 0.f, defaultCellW, defaultCellH)]; +#pragma unused(pickerView, component, view) + + UILabel * const label = [[UILabel alloc] initWithFrame : CGRectMake(0.f, 0.f, defaultCellW, defaultCellH)]; label.text = fixedFontNames[row]; label.font = [UIFont fontWithName : fixedFonts[row] size : 14.f]; - label.textAlignment = UITextAlignmentCenter; + label.textAlignment = NSTextAlignmentCenter; label.backgroundColor = [UIColor colorWithPatternImage : [UIImage imageNamed : @"text_cell_bkn.png"]]; return label; } //____________________________________________________________________________________________________ -- (void) pickerView : (UIPickerView *)thePickerView didSelectRow : (NSInteger)row inComponent : (NSInteger)component +- (void) pickerView : (UIPickerView *) pickerView didSelectRow : (NSInteger) row inComponent : (NSInteger) component { - using namespace ROOT_IOSObjectInspector; +#pragma unused(pickerView, component) + + assert(object != nullptr && "pickerView:didSelectRow:component:, object is null"); const Font_t fontIndex = (row + 1) * 10; - if (mode == afimTitleFont) + if (isTitleFont) object->SetTitleFont(fontIndex); - else if (mode == afimLabelFont) + else object->SetLabelFont(fontIndex); [controller objectWasModifiedUpdateSelection : NO]; diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisInspector.h new file mode 100644 index 0000000000000..2723be729f0a5 --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisInspector.h @@ -0,0 +1,22 @@ +#import <UIKit/UIKit.h> + +#import "ObjectInspectorComponent.h" + +// +//AxisInspector contains a tab-bar interface with nested sub-inspectors: +//AxisTicksInspector, AxisTitleInspector, AxisLabelsInspector. +// + +@interface AxisInspector : UIViewController <ObjectInspectorComponent, UITabBarDelegate> + ++ (CGRect) inspectorFrame; + +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) o; + +- (NSString *) getComponentName; +- (void) resetInspector; + + + +@end diff --git a/test/ios/RootBrowser/AxisInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisInspector.mm similarity index 70% rename from test/ios/RootBrowser/AxisInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisInspector.mm index 86d731b4115a0..986adacb4f606 100644 --- a/test/ios/RootBrowser/AxisInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisInspector.mm @@ -1,28 +1,23 @@ +#import <cassert> + #import "InspectorWithNavigation.h" #import "AxisLabelsInspector.h" #import "AxisTitleInspector.h" #import "AxisTicksInspector.h" #import "AxisInspector.h" -@interface AxisInspector () { +@implementation AxisInspector { + __weak IBOutlet UITabBar *tabBar; + AxisTicksInspector *ticksInspector; InspectorWithNavigation *titleInspector; InspectorWithNavigation *labelInspector; - __weak ROOTObjectController *controller; + __weak ObjectViewController *controller; TObject *object; } -- (void) showTicksInspector; -- (void) showAxisTitleInspector; -- (void) showAxisLabelsInspector; - -@end - - -@implementation AxisInspector - //____________________________________________________________________________________________________ + (CGRect) inspectorFrame { @@ -30,18 +25,19 @@ + (CGRect) inspectorFrame } //____________________________________________________________________________________________________ -- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { self = [super initWithNibName : nibNameOrNil bundle:nibBundleOrNil]; if (self) { - [self view]; + [self view];//Force load. Do not want to wait. ticksInspector = [[AxisTicksInspector alloc] initWithNibName : @"AxisTicksInspector" bundle : nil]; [self.view addSubview : ticksInspector.view]; // AxisTitleInspector *titleInspectorCompositor = [[AxisTitleInspector alloc] initWithNibName : @"AxisTitleInspector" bundle : nil]; + //Title inspector is the first in the nested navigation stack. titleInspector = [[InspectorWithNavigation alloc] initWithRootViewController : titleInspectorCompositor]; titleInspector.view.frame = [AxisTitleInspector inspectorFrame]; [self.view addSubview : titleInspector.view]; @@ -49,6 +45,7 @@ - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil // AxisLabelsInspector *labelInspectorCompositor = [[AxisLabelsInspector alloc] initWithNibName : @"AxisLabelsInspector" bundle : nil]; + //Label inspector is the first in the nested navigation stack. labelInspector = [[InspectorWithNavigation alloc] initWithRootViewController : labelInspectorCompositor]; labelInspector.view.frame = [AxisLabelsInspector inspectorFrame]; [self.view addSubview : labelInspector.view]; @@ -60,55 +57,37 @@ - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil return self; } -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle +#pragma mark - Interface orientation. //____________________________________________________________________________________________________ -- (void)viewDidLoad +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. -} - -//____________________________________________________________________________________________________ -- (void)viewDidUnload -{ - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} +#pragma unused(interfaceOrientation) -//____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations return YES; } #pragma mark - ObjectInspectorComponent's protocol. //____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c +- (void) setObjectController : (ObjectViewController *) c { + assert(c != nil && "setObjectController:, parameter 'c' is nil"); + controller = c; - [ticksInspector setROOTObjectController : c]; - [titleInspector setROOTObjectController : c]; - [labelInspector setROOTObjectController : c]; + [ticksInspector setObjectController : c]; + [titleInspector setObjectController : c]; + [labelInspector setObjectController : c]; } //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (void) setObject : (TObject *) o { + assert(o != nullptr && "setObject:, parameter 'o' is null"); + object = o; - [ticksInspector setROOTObject : o]; - [titleInspector setROOTObject : o]; - [labelInspector setROOTObject : o]; + [ticksInspector setObject : o]; + [titleInspector setObject : o]; + [labelInspector setObject : o]; } //____________________________________________________________________________________________________ @@ -154,8 +133,10 @@ - (void) showAxisLabelsInspector #pragma mark - Tabbar delegate. //____________________________________________________________________________________________________ -- (void) tabBar : (UITabBar *) tb didSelectItem : (UITabBarItem *)item +- (void) tabBar : (UITabBar *) tb didSelectItem : (UITabBarItem *) item { +#pragma unused(tb) + if (item.tag == 1) [self showTicksInspector]; else if (item.tag == 2) diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisLabelsInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisLabelsInspector.h new file mode 100644 index 0000000000000..cc1affdcd1ae1 --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisLabelsInspector.h @@ -0,0 +1,21 @@ +#import "ObjectInspectorComponent.h" + +// +//AxisLabelInspector, placed in a tab inside an AxisInspector's view. +//Has several controlls and is a part of a nested navigation stack - +//label font (AxisFontInspector) is pushed into the navigation stack. +// + +@class ROOTObjectController; + +class TObject; +class TAxis; + +@interface AxisLabelsInspector : UIViewController <ObjectInspectorComponent> + ++ (CGRect) inspectorFrame; + +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) o; + +@end diff --git a/test/ios/RootBrowser/AxisLabelsInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisLabelsInspector.mm similarity index 67% rename from test/ios/RootBrowser/AxisLabelsInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisLabelsInspector.mm index 3976a7517008a..b2544be68ad8c 100644 --- a/test/ios/RootBrowser/AxisLabelsInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisLabelsInspector.mm @@ -1,4 +1,6 @@ -#import "ROOTObjectController.h" +#import <cassert> + +#import "ObjectViewController.h" #import "AxisLabelsInspector.h" #import "AxisFontInspector.h" @@ -19,7 +21,17 @@ const CGRect componentFrame = CGRectMake(0.f, tabBarHeight, 250.f, totalHeight - tabBarHeight); @implementation AxisLabelsInspector { - __weak ROOTObjectController *controller; + __weak IBOutlet UIButton *plusSize; + __weak IBOutlet UIButton *minusSize; + __weak IBOutlet UILabel *sizeLabel; + + __weak IBOutlet UIButton *plusOffset; + __weak IBOutlet UIButton *minusOffset; + __weak IBOutlet UILabel *offsetLabel; + + __weak IBOutlet UISwitch *noExp; + + __weak ObjectViewController *controller; TAxis *object; } @@ -30,61 +42,42 @@ + (CGRect) inspectorFrame } //____________________________________________________________________________________________________ -- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { - self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; - - [self view]; - - if (self) + if (self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]) { + //Force loading self.view and subviews. [self view]; + } return self; } -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle - -//____________________________________________________________________________________________________ -- (void)viewDidLoad -{ - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. -} +#pragma mark - Interface orientation. //____________________________________________________________________________________________________ -- (void)viewDidUnload +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} +#pragma unused(interfaceOrientation) -//____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations return YES; } +#pragma mark - ObjectInspectorComponent. + //____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c +- (void) setObjectController : (ObjectViewController *) c { + assert(c != nil && "setObjectController:, parameter 'c' is nil"); controller = c; } //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (void) setObject : (TObject *) o { + assert(o != nullptr && "setObject:, parameter 'o' is null"); + object = dynamic_cast<TAxis *>(o); + //The result of a cast is checked one level up. sizeLabel.text = [NSString stringWithFormat : @"%.2f", object->GetLabelSize()]; offsetLabel.text = [NSString stringWithFormat : @"%.3f", object->GetLabelOffset()]; @@ -92,20 +85,24 @@ - (void) setROOTObject : (TObject *)o noExp.on = object->GetNoExponent(); } +#pragma mark - UI interactions. + //____________________________________________________________________________________________________ -- (void) showLabelFontInspector +- (IBAction) showLabelFontInspector { - AxisFontInspector *fontInspector = [[AxisFontInspector alloc] initWithNibName : @"AxisFontInspector" mode : ROOT_IOSObjectInspector::afimLabelFont]; + AxisFontInspector * const fontInspector = [[AxisFontInspector alloc] initWithNibName : @"AxisFontInspector" isTitle : NO]; - [fontInspector setROOTObjectController : controller]; - [fontInspector setROOTObject : object]; + [fontInspector setObjectController : controller]; + [fontInspector setObject : object]; [self.navigationController pushViewController : fontInspector animated : YES]; } //____________________________________________________________________________________________________ -- (IBAction) plusBtn : (UIButton *)sender +- (IBAction) plusBtn : (UIButton *) sender { + assert(object != nullptr && "plusBtn:, object is null"); + if (sender == plusSize) { if (object->GetLabelSize() + sizeStep > maxSize) return; @@ -124,8 +121,10 @@ - (IBAction) plusBtn : (UIButton *)sender } //____________________________________________________________________________________________________ -- (IBAction) minusBtn : (UIButton *)sender +- (IBAction) minusBtn : (UIButton *) sender { + assert(object != nullptr && "minusBtn:, object is null"); + if (sender == minusSize) { if (object->GetLabelSize() - sizeStep < minSize) return; @@ -146,6 +145,8 @@ - (IBAction) minusBtn : (UIButton *)sender //____________________________________________________________________________________________________ - (IBAction) noExpPressed { + assert(object != nullptr && "noExpPressed, object is null"); + object->SetNoExponent(noExp.on); [controller objectWasModifiedUpdateSelection : NO]; } diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisTicksInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisTicksInspector.h new file mode 100644 index 0000000000000..6d4863e3c17e7 --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisTicksInspector.h @@ -0,0 +1,12 @@ +#import <UIKit/UIKit.h> + +#import "ObjectInspectorComponent.h" + +//AxisTicksInspector: its view is nested inside an AxisInspector's view (as a tab). + +@interface AxisTicksInspector : UIViewController <ObjectInspectorComponent> + +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) object; + +@end diff --git a/test/ios/RootBrowser/AxisTicksInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisTicksInspector.mm similarity index 72% rename from test/ios/RootBrowser/AxisTicksInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisTicksInspector.mm index f4b5f8340b8df..aad51dfc705af 100644 --- a/test/ios/RootBrowser/AxisTicksInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisTicksInspector.mm @@ -1,6 +1,7 @@ -#import <string.h> +#import <cassert> +#import <cstring> -#import "ROOTObjectController.h" +#import "ObjectViewController.h" #import "AxisTicksInspector.h" #import "TObject.h" @@ -17,24 +18,41 @@ const CGRect componentFrame = CGRectMake(0.f, tabBarHeight, 250.f, totalHeight - tabBarHeight); @implementation AxisTicksInspector { + __weak IBOutlet UILabel *tickLengthLabel; + __weak IBOutlet UIButton *plusLengthBtn; + __weak IBOutlet UIButton *minusLengthBtn; + + __weak IBOutlet UIButton *plusPrim; + __weak IBOutlet UIButton *minusPrim; + __weak IBOutlet UILabel *primLabel; + + __weak IBOutlet UIButton *plusSec; + __weak IBOutlet UIButton *minusSec; + __weak IBOutlet UILabel *secLabel; + + __weak IBOutlet UIButton *plusTer; + __weak IBOutlet UIButton *minusTer; + __weak IBOutlet UILabel *terLabel; + + __weak IBOutlet UISegmentedControl *ticksNegPos; + + float tickLength; unsigned primaryTicks; unsigned secondaryTicks; unsigned tertiaryTicks; - __weak ROOTObjectController *controller; + __weak ObjectViewController *controller; TAxis *object; } //____________________________________________________________________________________________________ -- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString * ) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { - self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; - - [self view]; - - if (self) { + if (self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]) { + //Force view/subviews load. + [self view]; // Custom initialization self.view.frame = componentFrame; } @@ -42,35 +60,13 @@ - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil return self; } -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle +#pragma mark - Interface orientation. //____________________________________________________________________________________________________ -- (void)viewDidLoad +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. -} +#pragma unused(interfaceOrientation) -//____________________________________________________________________________________________________ -- (void)viewDidUnload -{ - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} - -//____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations return YES; } @@ -79,8 +75,7 @@ - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interface //____________________________________________________________________________________________________ - (void) setTicksWidgets { -// object->SetNdivisions(int(primaryTicks.value), int(secondaryTicks.value), int(tertiaryTicks.value), 1); -// [controller objectWasModifiedByEditor]; + assert(object != nullptr && "setTicksWidgets, object is null"); const int nDivisions = object->GetNdivisions(); //Hardcoded constants from TAttAxis, never defined as named values in ROOT. @@ -100,9 +95,11 @@ - (void) setTicksWidgets //____________________________________________________________________________________________________ - (void) setupInspector { + assert(object != nullptr && "setupInspector, object is null"); + const char *option = object->GetTicks(); - if (!strcmp("+-", option)) + if (!std::strcmp("+-", option)) [ticksNegPos setSelectedSegmentIndex : 1]; else [ticksNegPos setSelectedSegmentIndex : 0]; @@ -110,25 +107,32 @@ - (void) setupInspector [self setTicksWidgets]; } +//____________________________________________________________________________________________________ +- (void) setObjectController : (ObjectViewController *) c +{ + assert(c != nil && "setObjectController:, parameter 'c' is nil"); + + controller = c; +} //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (void) setObject : (TObject *) o { + assert(o != nullptr && "setObject:, parameter 'o' is null"); + //The result of a cast is not checked here, it's done on top level. object = dynamic_cast<TAxis *>(o); [self setupInspector]; } -//____________________________________________________________________________________________________ -- (void) setROOTObjectController:(ROOTObjectController *)c -{ - controller = c; -} +#pragma mark - UI interactions. //____________________________________________________________________________________________________ - (IBAction) ticksNegPosPressed { + assert(object != nullptr && "ticksNegPosPressed, object is null"); + if (ticksNegPos.selectedSegmentIndex == 0) object->SetTicks(""); else @@ -140,19 +144,24 @@ - (IBAction) ticksNegPosPressed //____________________________________________________________________________________________________ - (void) setTicks { + assert(object != nullptr && "setTicks, object is null"); + object->SetNdivisions(primaryTicks, secondaryTicks, tertiaryTicks); } //____________________________________________________________________________________________________ -- (IBAction) plusTick : (UIButton *)sender +- (IBAction) plusTick : (UIButton *) sender { + assert(object != nullptr && "plusTick:, object is null"); + if (sender == plusLengthBtn) { if (tickLength + tickLengthStep < maxTickLength) { tickLength += tickLengthStep; - tickLengthLabel.text = [NSString stringWithFormat:@"%.2f", tickLength]; + tickLengthLabel.text = [NSString stringWithFormat : @"%.2f", tickLength]; object->SetTickLength(tickLength); [controller objectWasModifiedUpdateSelection : NO]; } + return; } @@ -185,8 +194,10 @@ - (IBAction) plusTick : (UIButton *)sender } //____________________________________________________________________________________________________ -- (IBAction) minusTick :(UIButton *)sender +- (IBAction) minusTick : (UIButton *) sender { + assert(object != nullptr && "minusTick:, object is null"); + if (sender == minusLengthBtn) { if (tickLength - tickLengthStep > minTickLength) { tickLength -= tickLengthStep; diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisTitleInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisTitleInspector.h new file mode 100644 index 0000000000000..7179f2297c0a9 --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisTitleInspector.h @@ -0,0 +1,17 @@ +#import <UIKit/UIKit.h> + +#import "ObjectInspectorComponent.h" + +// +//Title inspect is one of tabs inside an AxisInspector's tab view. +//It has several controls and is a part of a nested navigation stack. +// + +@interface AxisTitleInspector : UIViewController <ObjectInspectorComponent> + ++ (CGRect) inspectorFrame; + +- (void) setObjectController : (ObjectViewController *)c; +- (void) setObject : (TObject *)o; + +@end diff --git a/test/ios/RootBrowser/AxisTitleInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisTitleInspector.mm similarity index 73% rename from test/ios/RootBrowser/AxisTitleInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisTitleInspector.mm index 53b26ad9d2249..db92b82983f12 100644 --- a/test/ios/RootBrowser/AxisTitleInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/AxisTitleInspector.mm @@ -1,4 +1,6 @@ -#import "ROOTObjectController.h" +#import <cassert> + +#import "ObjectViewController.h" #import "AxisTitleInspector.h" #import "AxisFontInspector.h" @@ -19,8 +21,16 @@ const float tabBarHeight = 49.f; @implementation AxisTitleInspector { - - ROOTObjectController *controller; + __weak IBOutlet UITextField *titleField; + __weak IBOutlet UISwitch *centered; + __weak IBOutlet UISwitch *rotated; + __weak IBOutlet UILabel *offsetLabel; + __weak IBOutlet UILabel *sizeLabel; + __weak IBOutlet UIButton *plusSizeBtn; + __weak IBOutlet UIButton *minusSizeBtn; + + __weak ObjectViewController *controller; + TAxis *object; float offset; float titleSize; @@ -34,7 +44,7 @@ + (CGRect) inspectorFrame } //____________________________________________________________________________________________________ -- (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; @@ -45,49 +55,32 @@ - (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleO return self; } -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle +#pragma mark - Interface orientation. //____________________________________________________________________________________________________ -- (void)viewDidLoad +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. -} - -//____________________________________________________________________________________________________ -- (void)viewDidUnload -{ - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} +#pragma unused(interfaceOrientation) -//____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations return YES; } +#pragma mark - ObjectInspectorComponent. + //____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c +- (void) setObjectController : (ObjectViewController *) c { + assert(c != nil && "setObjectController:, parameter 'c' is nil"); controller = c; } //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (void) setObject : (TObject *) o { + assert(o != nullptr && "setObject:, parameter 'o' is null"); + object = dynamic_cast<TAxis *>(o); + //I do not test the result of cast, it's done one level up. const char *axisTitle = object->GetTitle(); if (!axisTitle || !*axisTitle) @@ -111,13 +104,15 @@ - (void) setROOTObject : (TObject *)o sizeLabel.text = [NSString stringWithFormat:@"%.2f", titleSize]; } +#pragma mark - UI interactions. + //____________________________________________________________________________________________________ - (IBAction) showTitleFontInspector { - AxisFontInspector *fontInspector = [[AxisFontInspector alloc] initWithNibName : @"AxisFontInspector" mode : ROOT_IOSObjectInspector::afimTitleFont]; + AxisFontInspector * const fontInspector = [[AxisFontInspector alloc] initWithNibName : @"AxisFontInspector" isTitle : YES]; - [fontInspector setROOTObjectController : controller]; - [fontInspector setROOTObject : object]; + [fontInspector setObjectController : controller]; + [fontInspector setObject : object]; [self.navigationController pushViewController : fontInspector animated : YES]; } @@ -125,6 +120,10 @@ - (IBAction) showTitleFontInspector //____________________________________________________________________________________________________ - (IBAction) textFieldDidEndOnExit : (id) sender { +#pragma unused(sender) + + assert(object != nullptr && "textFieldDidEndOnExits:, object is null"); + object->SetTitle([titleField.text cStringUsingEncoding : [NSString defaultCStringEncoding]]); [controller objectWasModifiedUpdateSelection : NO]; } @@ -132,12 +131,15 @@ - (IBAction) textFieldDidEndOnExit : (id) sender //____________________________________________________________________________________________________ - (IBAction) textFieldEditingDidEnd : (id) sender { +#pragma unused(sender) [sender resignFirstResponder]; } //____________________________________________________________________________________________________ - (IBAction) centerTitle { + assert(object != nullptr && "centerTitle, object is null"); + object->CenterTitle(centered.on); [controller objectWasModifiedUpdateSelection : NO]; } @@ -145,6 +147,8 @@ - (IBAction) centerTitle //____________________________________________________________________________________________________ - (IBAction) rotateTitle { + assert(object != nullptr && "rotateTitle, object is null"); + object->RotateTitle(rotated.on); [controller objectWasModifiedUpdateSelection : NO]; } @@ -152,6 +156,8 @@ - (IBAction) rotateTitle //____________________________________________________________________________________________________ - (IBAction) plusOffset { + assert(object != nullptr && "plusOffset, object is null"); + if (offset + titleOffsetStep > maxTitleOffset) return; @@ -165,6 +171,8 @@ - (IBAction) plusOffset //____________________________________________________________________________________________________ - (IBAction) minusOffset { + assert(object != nullptr && "minusOffset, object is null"); + if (offset - titleOffsetStep < minTitleOffset) return; @@ -178,6 +186,8 @@ - (IBAction) minusOffset //____________________________________________________________________________________________________ - (IBAction) plusSize { + assert(object != nullptr && "plusSize, object is null"); + if (titleSize + titleSizeStep > maxTitleSize) return; @@ -191,6 +201,8 @@ - (IBAction) plusSize //____________________________________________________________________________________________________ - (IBAction) minusSize { + assert(object != nullptr && "minusSize, object is null"); + if (titleSize - titleSizeStep < minTitleSize) return; diff --git a/test/ios/RootBrowser/FilledAreaInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/FilledAreaInspector.h similarity index 53% rename from test/ios/RootBrowser/FilledAreaInspector.h rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/FilledAreaInspector.h index 2353df84622b1..de73fbe6af1d6 100644 --- a/test/ios/RootBrowser/FilledAreaInspector.h +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/FilledAreaInspector.h @@ -3,10 +3,12 @@ #import "ObjectInspectorComponent.h" #import "HorizontalPickerDelegate.h" +//ObjectInspector to work with a TAttFill object, view contains two horizontal pickers - color/pattern selectors. + @interface FilledAreaInspector : UIViewController <HorizontalPickerDelegate, ObjectInspectorComponent> -- (void) setROOTObjectController : (ROOTObjectController *) p; -- (void) setROOTObject : (TObject*) obj; +- (void) setObjectController : (ObjectViewController *) p; +- (void) setObject : (TObject*) obj; - (NSString *) getComponentName; @end diff --git a/test/ios/RootBrowser/FilledAreaInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/FilledAreaInspector.mm similarity index 80% rename from test/ios/RootBrowser/FilledAreaInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/FilledAreaInspector.mm index 4b2a4ad5165a4..2025d05c05909 100644 --- a/test/ios/RootBrowser/FilledAreaInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/FilledAreaInspector.mm @@ -1,4 +1,6 @@ -#import "ROOTObjectController.h" +#import <cassert> + +#import "ObjectViewController.h" #import "HorizontalPickerView.h" #import "FilledAreaInspector.h" #import "PatternCell.h" @@ -23,24 +25,25 @@ @implementation FilledAreaInspector { TAttFill *filledObject; - __weak ROOTObjectController *parentController; + __weak ObjectViewController *parentController; } //____________________________________________________________________________________________________ -- (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { using namespace ROOT::iOS::Browser; self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; - - [self view]; if (self) { + //Force view/subviews load. + [self view]; + const CGRect cellRect = CGRectMake(0.f, 0.f, defaultCellW, defaultCellH); colorCells = [[NSMutableArray alloc] init]; for (unsigned i = 0; i < nROOTDefaultColors; ++i) { - ColorCell * newCell = [[ColorCell alloc] initWithFrame : cellRect]; + ColorCell * const newCell = [[ColorCell alloc] initWithFrame : cellRect]; [newCell setRGB : predefinedFillColors[i]]; [colorCells addObject : newCell]; } @@ -51,15 +54,15 @@ - (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleO colorPicker.pickerDelegate = self; patternCells = [[NSMutableArray alloc] init]; - PatternCell *solidFill = [[PatternCell alloc] initWithFrame : cellRect andPattern : 0]; + PatternCell * const solidFill = [[PatternCell alloc] initWithFrame : cellRect andPattern : 0]; [solidFill setAsSolid]; [patternCells addObject : solidFill]; for (unsigned i = 0; i < ROOT::iOS::GraphicUtils::kPredefinedFillPatterns; ++i) { - PatternCell *newCell = [[PatternCell alloc] initWithFrame : cellRect andPattern : i]; + PatternCell * const newCell = [[PatternCell alloc] initWithFrame : cellRect andPattern : i]; [patternCells addObject : newCell]; } - + patternPicker = [[HorizontalPickerView alloc] initWithFrame:CGRectMake(15.f, 90.f, 220.f, 70.f)]; [patternPicker addItems : patternCells]; [self.view addSubview : patternPicker]; @@ -69,20 +72,27 @@ - (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleO return self; } +#pragma mark - Interface orientation. + //____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - [super didReceiveMemoryWarning]; +#pragma unused(interfaceOrientation) + return YES; } +#pragma mark - ObjectInspectorComponent. + //____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *) p +- (void) setObjectController : (ObjectViewController *) p { + assert(p != nil && "setObjectController:, parameter 'p' is nil"); + parentController = p; } //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)obj +- (void) setObject : (TObject *) obj { //ROOT's standard color pick has 16 colors, //I have 16 rows in a color picker. @@ -94,6 +104,9 @@ - (void) setROOTObject : (TObject *)obj //If the object color is one of 16 standard colors, //I find the correct row in a picker and rotate picker //to this row. If not - it's on zero. + + assert(obj != nullptr && "setObject:, parameter 'obj' is null"); + using namespace ROOT::iOS::Browser; //I do not check the result of dynamic_cast here. This is done at upper level. @@ -164,32 +177,13 @@ - (void) setNewPattern : (NSInteger) cellIndex } } -#pragma mark - View lifecycle - -//____________________________________________________________________________________________________ -- (void)viewDidLoad -{ - [super viewDidLoad]; -} - -//____________________________________________________________________________________________________ -- (void)viewDidUnload -{ - [super viewDidUnload]; -} - -//____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations - return YES; -} - #pragma mark - Color/pattern picker's delegate. //____________________________________________________________________________________________________ -- (void) item : (unsigned int)item wasSelectedInPicker : (HorizontalPickerView *)picker +- (void) item : (unsigned int) item wasSelectedInPicker : (HorizontalPickerView *) picker { + assert(picker != nil && "item:wasSelectedInPicker:, parameter 'picker' is nil"); + if (picker == colorPicker) { [self setNewColor : item]; } else { diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1BinsInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1BinsInspector.h new file mode 100644 index 0000000000000..4caeaae198b4f --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1BinsInspector.h @@ -0,0 +1,16 @@ +#import "ObjectInspectorComponent.h" + +// +//The name is not really good: this inspector's view contains: +//range slider to change X-axis range; text field for H1's title; +//switch control (show or hide markers). +//I think the name is a legacy (at the beginning inspector was quite different). +//It's one of two tabs in the 'Hist attributes' inspector. +// + +@interface H1BinsInspector : UIViewController <ObjectInspectorComponent> + +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) o; + +@end diff --git a/test/ios/RootBrowser/H1BinsInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1BinsInspector.mm similarity index 75% rename from test/ios/RootBrowser/H1BinsInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1BinsInspector.mm index bdd3b4d7ac683..19d6bd6bafeed 100644 --- a/test/ios/RootBrowser/H1BinsInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1BinsInspector.mm @@ -1,4 +1,6 @@ -#import "ROOTObjectController.h" +#import <cassert> + +#import "ObjectViewController.h" #import "H1BinsInspector.h" #import "RangeSlider.h" @@ -6,30 +8,26 @@ #import "TH1.h" @implementation H1BinsInspector { + __weak IBOutlet UITextField *titleField; + __weak IBOutlet UILabel *minLabel; + __weak IBOutlet UILabel *maxLabel; + __weak IBOutlet UISwitch *showMarkers; + RangeSlider *axisRangeSlider; - __weak ROOTObjectController *controller; + __weak ObjectViewController *controller; TH1 *object; } //____________________________________________________________________________________________________ -- (id) initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; - if (self) { + if (self)//Force views load (not necessary??). [self view]; - } return self; } -//____________________________________________________________________________________________________ -- (void) didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. -} - #pragma mark - View lifecycle //____________________________________________________________________________________________________ @@ -43,46 +41,47 @@ - (void) viewDidLoad [axisRangeSlider addTarget:self action:@selector(axisRangeChanged) forControlEvents : UIControlEventValueChanged]; } -//____________________________________________________________________________________________________ -- (void) viewDidUnload -{ - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} +#pragma mark - interface orientation. //____________________________________________________________________________________________________ -- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - // Return YES for supported orientations +#pragma unused(interfaceOrientation) return YES; } +#pragma mark - ObjectInspectorComponent protocol. + + //____________________________________________________________________________________________________ -(void) axisRangeChanged { + assert(object != nullptr && "axisRangeChanged, object is null"); + minLabel.center = CGPointMake([axisRangeSlider getMinThumbX], minLabel.center.y); - minLabel.text = [NSString stringWithFormat:@"%.3g", axisRangeSlider.selectedMinimumValue]; + minLabel.text = [NSString stringWithFormat : @"%.3g", axisRangeSlider.selectedMinimumValue]; maxLabel.center = CGPointMake([axisRangeSlider getMaxThumbX], maxLabel.center.y); - maxLabel.text = [NSString stringWithFormat:@"%.3g", axisRangeSlider.selectedMaximumValue]; + maxLabel.text = [NSString stringWithFormat : @"%.3g", axisRangeSlider.selectedMaximumValue]; //Update the histogram. object->GetXaxis()->SetRangeUser(axisRangeSlider.selectedMinimumValue, axisRangeSlider.selectedMaximumValue); [controller objectWasModifiedUpdateSelection : YES]; } -#pragma mark - ObjectInspectorComponent protocol. //____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c +- (void) setObjectController : (ObjectViewController *) c { + assert(c != nil && "setObjectController:, parameter 'c' is nil"); controller = c; } //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (void) setObject : (TObject *) o { + assert(o != nullptr && "setObject:, parameter 'o' is null"); + object = static_cast<TH1 *>(o); - // + //I do not use dynamic cast. const char *histTitle = object->GetTitle(); if (!histTitle || !*histTitle) titleField.text = @""; @@ -109,6 +108,8 @@ - (void) setROOTObject : (TObject *)o //____________________________________________________________________________________________________ - (IBAction) textFieldDidEndOnExit : (id) sender { + assert(object != nullptr && "textFieldDidEndOnExit:, object is null"); + object->SetTitle([titleField.text cStringUsingEncoding : [NSString defaultCStringEncoding]]); [controller objectWasModifiedUpdateSelection : NO]; } @@ -122,7 +123,6 @@ - (IBAction) textFieldEditingDidEnd : (id) sender //____________________________________________________________________________________________________ - (IBAction) toggleMarkers { -// showMarkers.on ? controller.markerDrawOption = @"P" : controller.markerDrawOption = @""; [controller setMarker : showMarkers.on]; [controller objectWasModifiedUpdateSelection : YES]; } diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1ErrorsInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1ErrorsInspector.h new file mode 100644 index 0000000000000..be4775abe2225 --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1ErrorsInspector.h @@ -0,0 +1,13 @@ +#import "ObjectInspectorComponent.h" + +// +//A very simple object inspector with a picker view to select an error type. +//One of two tabs inside an H1Inspector's view. +// + +@interface H1ErrorsInspector : UIViewController <UIPickerViewDelegate, UIPickerViewDataSource, ObjectInspectorComponent> + +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) o; + +@end diff --git a/test/ios/RootBrowser/H1ErrorsInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1ErrorsInspector.mm similarity index 52% rename from test/ios/RootBrowser/H1ErrorsInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1ErrorsInspector.mm index 039d5de4730ff..e95f16fdcdd47 100644 --- a/test/ios/RootBrowser/H1ErrorsInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1ErrorsInspector.mm @@ -1,4 +1,6 @@ -#import "ROOTObjectController.h" +#import <cassert> + +#import "ObjectViewController.h" #import "H1ErrorsInspector.h" //C++ imports. @@ -23,7 +25,7 @@ kTotalNumOfTypes }; -NSString *errorTypesStrings[] = {@"No error", @"Simple", @"Edges", @"Rectangles", @"Fill", @"Contour"}; +NSString * const errorTypesStrings[] = {@"No error", @"Simple", @"Edges", @"Rectangles", @"Fill", @"Contour"}; namespace RIB = ROOT::iOS::Browser; RIB::EHistogramErrorOption histErrorTypes[] = {RIB::hetNoError, RIB::hetE, RIB::hetE1, RIB::hetE2, RIB::hetE3, RIB::hetE4}; @@ -31,97 +33,81 @@ } @implementation H1ErrorsInspector { - __weak ROOTObjectController *controller; + __weak IBOutlet UIPickerView *errorTypePicker; + __weak ObjectViewController *controller; TH1 *object; } //____________________________________________________________________________________________________ -- (id) initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil +- (id) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; - if (self) { - [self view]; - } + if (self) + [self view];//Force a view load. return self; } -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle - -//____________________________________________________________________________________________________ -- (void)viewDidLoad -{ - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. -} - -//____________________________________________________________________________________________________ -- (void)viewDidUnload -{ - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} +#pragma mark - Interface orientation. //____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - // Return YES for supported orientations +#pragma unused(interfaceOrientation) return YES; } #pragma mark - Pickerview delegate/data source. //____________________________________________________________________________________________________ -- (CGFloat)pickerView : (UIPickerView *)pickerView widthForComponent : (NSInteger)component +- (CGFloat) pickerView : (UIPickerView *) pickerView widthForComponent : (NSInteger) component { +#pragma unused(pickerView, component) return defaultCellW; } //____________________________________________________________________________________________________ -- (CGFloat)pickerView : (UIPickerView *)pickerView rowHeightForComponent : (NSInteger)component +- (CGFloat) pickerView : (UIPickerView *) pickerView rowHeightForComponent : (NSInteger) component { +#pragma unused(pickerView, component) return defaultCellH; } //____________________________________________________________________________________________________ -- (NSInteger)pickerView : (UIPickerView *)pickerView numberOfRowsInComponent : (NSInteger)component +- (NSInteger) pickerView : (UIPickerView *) pickerView numberOfRowsInComponent : (NSInteger)component { +#pragma unused(pickerView, component) return kTotalNumOfTypes; } //____________________________________________________________________________________________________ -- (NSInteger)numberOfComponentsInPickerView:(UIPickerView *)pickerView +- (NSInteger) numberOfComponentsInPickerView : (UIPickerView *) pickerView { +#pragma unused(pickerView) return 1; } //____________________________________________________________________________________________________ -- (UIView *)pickerView : (UIPickerView *)pickerView viewForRow : (NSInteger)row forComponent : (NSInteger)component reusingView : (UIView *)view +- (UIView *) pickerView : (UIPickerView *) pickerView viewForRow : (NSInteger) row forComponent : (NSInteger) component reusingView : (UIView *) view { - UILabel *label = [[UILabel alloc] initWithFrame : CGRectMake(0.f, 0.f, defaultCellW, defaultCellH)]; +#pragma unused(pickerView, component, view) + + UILabel * const label = [[UILabel alloc] initWithFrame : CGRectMake(0.f, 0.f, defaultCellW, defaultCellH)]; label.text = errorTypesStrings[row]; label.font = [UIFont fontWithName : @"TimesNewRomanPS-BoldMT" size : 14.f]; - label.textAlignment = UITextAlignmentCenter; + label.textAlignment = NSTextAlignmentCenter; label.backgroundColor = [UIColor colorWithPatternImage : [UIImage imageNamed : @"text_cell_bkn.png"]]; return label; } //____________________________________________________________________________________________________ -- (void)pickerView : (UIPickerView *)thePickerView didSelectRow : (NSInteger)row inComponent : (NSInteger)component +- (void)pickerView : (UIPickerView *) pickerView didSelectRow : (NSInteger) row inComponent : (NSInteger) component { +#pragma unused(pickerView, component) + if (row >= 0) { [controller setErrorOption : histErrorTypes[row]]; [controller objectWasModifiedUpdateSelection : YES]; @@ -129,17 +115,22 @@ - (void)pickerView : (UIPickerView *)thePickerView didSelectRow : (NSInteger)row } #pragma mark ObjectInspectorComponent protocol. + //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (void) setObjectController : (ObjectViewController *) c { - object = static_cast<TH1*>(o); - //Read error type from hist. + assert(c != nil && "setObjectController:, parameter 'c' is nil"); + controller = c; } //____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c +- (void) setObject : (TObject *) o { - controller = c; + assert(o != nullptr && "setObject:, parameter 'o' is null"); + + //The type was checked on one level up. + object = static_cast<TH1*>(o); + //Read error type from hist. } @end diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1Inspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1Inspector.h new file mode 100644 index 0000000000000..7cddffd01070c --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1Inspector.h @@ -0,0 +1,15 @@ +#import "ObjectInspectorComponent.h" + +// +//Object inspector with nested object inspectors (inside tab bar). +// + +@interface H1Inspector : UIViewController <ObjectInspectorComponent, UITabBarDelegate> + +- (void) setObject : (TObject *) o; +- (void) setObjectController : (ObjectViewController *) c; +- (NSString *) getComponentName; +- (void) resetInspector; + + +@end diff --git a/test/ios/RootBrowser/H1Inspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1Inspector.mm similarity index 64% rename from test/ios/RootBrowser/H1Inspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1Inspector.mm index cd01e36e9ead8..d64ac40b15573 100644 --- a/test/ios/RootBrowser/H1Inspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/H1Inspector.mm @@ -1,3 +1,5 @@ +#import <cassert> + #import "H1ErrorsInspector.h" #import "H1BinsInspector.h" #import "H1Inspector.h" @@ -7,25 +9,21 @@ const CGFloat tabBarHeight = 49.f; const CGRect nestedComponentFrame = CGRectMake(0.f, tabBarHeight, 250.f, totalHeight - tabBarHeight); -@interface H1Inspector () { +@implementation H1Inspector { + __weak IBOutlet UITabBar *tabBar; + H1ErrorsInspector *errorInspector; H1BinsInspector *binsInspector; TObject *object; - __weak ROOTObjectController *controller; -} - -- (void) showBinsInspector; -- (void) showErrorInspector; + __weak ObjectViewController *controller; -@end - -@implementation H1Inspector +} //____________________________________________________________________________________________________ -- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { - self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; + self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; if (self) { [self view]; @@ -46,55 +44,36 @@ - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil return self; } -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle - -//____________________________________________________________________________________________________ -- (void)viewDidLoad -{ - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. -} +#pragma mark - Interface orientation. //____________________________________________________________________________________________________ -- (void)viewDidUnload +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} +#pragma unused(interfaceOrientation) -//____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations return YES; } #pragma mark - ObjectInspectorComponent protocol. //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (void) setObjectController : (ObjectViewController *) c { - object = o; - [errorInspector setROOTObject : o]; - [binsInspector setROOTObject : o]; + assert(c != nil && "setObjectController:, parameter 'c' is nil"); + + controller = c; + [errorInspector setObjectController : c]; + [binsInspector setObjectController : c]; } //____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c +- (void) setObject : (TObject *) o { - controller = c; - [errorInspector setROOTObjectController : c]; - [binsInspector setROOTObjectController : c]; + assert(o != nullptr && "setObject:, parameter 'o' is null"); + + object = o; + [errorInspector setObject : o]; + [binsInspector setObject : o]; } //____________________________________________________________________________________________________ @@ -128,9 +107,12 @@ - (void) showErrorInspector } #pragma mark - UITabBar's delegate. + //____________________________________________________________________________________________________ -- (void) tabBar : (UITabBar *) tb didSelectItem : (UITabBarItem *)item +- (void) tabBar : (UITabBar *) tb didSelectItem : (UITabBarItem *) item { +#pragma unused(tb) + if (item.tag == 1) [self showBinsInspector]; else if (item.tag == 2) diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/InspectorWithNavigation.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/InspectorWithNavigation.h new file mode 100644 index 0000000000000..4bbd8626dc137 --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/InspectorWithNavigation.h @@ -0,0 +1,19 @@ +#import <UIKit/UIKit.h> + +#import "ObjectInspectorComponent.h" + +// +//We have a "3D" navigation inside the Object Inspector: +//shrinking/extending views + tabs in some inspectors + +//a navigation controllers in some inspectors. +//InspectorWithNavigation is a UINavigationController's subcluss supporting ObjectInspectorComponent's +//protocol. + +@interface InspectorWithNavigation : UINavigationController <ObjectInspectorComponent> + +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) obj; +- (NSString *) getComponentName; +- (void) resetInspector; + +@end diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/InspectorWithNavigation.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/InspectorWithNavigation.mm new file mode 100644 index 0000000000000..cc94fa5c9f078 --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/InspectorWithNavigation.mm @@ -0,0 +1,62 @@ +#import <cassert> + +#import "InspectorWithNavigation.h" + +@implementation InspectorWithNavigation + +//____________________________________________________________________________________________________ +- (instancetype) initWithRootViewController : (UIViewController<ObjectInspectorComponent> *) rootController +{ + self = [super initWithRootViewController : rootController]; + + if (self) + self.navigationBar.hidden = YES; + + return self; +} + +#pragma mark - Interface orientation. + +//____________________________________________________________________________________________________ +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation +{ +#pragma unused(interfaceOrientation) + return YES; +} + +#pragma mark - Object inspector component's protocol. + +//____________________________________________________________________________________________________ +- (void) setObjectController : (ObjectViewController *) c +{ + assert(c != nil && "setObjectController:, parameter 'c' is nil"); + + UIViewController<ObjectInspectorComponent> * const rootController = (UIViewController<ObjectInspectorComponent> *)[self.viewControllers objectAtIndex : 0]; + [rootController setObjectController : c]; +} + +//____________________________________________________________________________________________________ +- (void) setObject : (TObject *) obj +{ + assert(obj != nullptr && "setObject:, parameter 'obj' is null"); + + UIViewController<ObjectInspectorComponent> * const rootController = (UIViewController<ObjectInspectorComponent> *)[self.viewControllers objectAtIndex : 0]; + [rootController setObject : obj]; +} + +//____________________________________________________________________________________________________ +- (NSString *) getComponentName +{ + UIViewController<ObjectInspectorComponent> * const rootController = (UIViewController<ObjectInspectorComponent> *)[self.viewControllers objectAtIndex : 0]; + return [rootController getComponentName]; +} + +//____________________________________________________________________________________________________ +- (void) resetInspector +{ + //Pop all controllers from a stack except a top level root controller. + while ([self.viewControllers count] > 1) + [self popViewControllerAnimated : NO]; +} + +@end diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/LineInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/LineInspector.h new file mode 100644 index 0000000000000..6747d84d3d8d8 --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/LineInspector.h @@ -0,0 +1,23 @@ +#import <UIKit/UIKit.h> + +#import "ObjectInspectorComponent.h" +#import "HorizontalPickerDelegate.h" + + +@class HorizontalPickerView; +@class LineWidthPicker; + +// +//LineInspector: object inspector for a TAttLine, contains 2 horizontal pickers (color and dash style) + +//line width control. +// + +@interface LineInspector : UIViewController <ObjectInspectorComponent, HorizontalPickerDelegate> + +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) o; +- (NSString *) getComponentName; + +- (void) item : (unsigned int)item wasSelectedInPicker : (HorizontalPickerView *) picker; + +@end diff --git a/test/ios/RootBrowser/LineInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/LineInspector.mm similarity index 74% rename from test/ios/RootBrowser/LineInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/LineInspector.mm index cb8b0731f7969..7d659afc33e76 100644 --- a/test/ios/RootBrowser/LineInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/LineInspector.mm @@ -1,5 +1,7 @@ +#import <cassert> + #import "HorizontalPickerView.h" -#import "ROOTObjectController.h" +#import "ObjectViewController.h" #import "LineWidthPicker.h" #import "LineInspector.h" #import "LineStyleCell.h" @@ -16,7 +18,8 @@ const int maxLineWidth = 15; const CGRect cellFrame = CGRectMake(0.f, 0.f, 50.f, 50.f); -@interface LineInspector () { +@implementation LineInspector { + __weak IBOutlet LineWidthPicker *lineWidthPicker; NSMutableArray *lineStyles; NSMutableArray *lineColors; @@ -25,22 +28,19 @@ @interface LineInspector () { int lineWidth; - __weak ROOTObjectController *controller; + __weak ObjectViewController *controller; TAttLine *object; } -@end - -@implementation LineInspector - //____________________________________________________________________________________________________ -- (id)initWithNibName : (NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { using namespace ROOT::iOS::Browser; self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; if (self) { + //Force views load. [self view]; //Array with cells for "Line style" picker. lineStyles = [[NSMutableArray alloc] init]; @@ -72,50 +72,31 @@ - (id)initWithNibName : (NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrN return self; } -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle +#pragma mark - Interface orientation. //____________________________________________________________________________________________________ -- (void)viewDidLoad +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. -} - -//____________________________________________________________________________________________________ -- (void)viewDidUnload -{ - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} - -//____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations +#pragma unused(interfaceOrientation) return YES; } //____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c +- (void) setObjectController : (ObjectViewController *) c { + assert(c != nil && "setObjectController:, parameter 'c' is nil"); controller = c; } //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (void) setObject : (TObject *) o { + assert(o != nullptr && "setObject:, parameter 'o' is null"); + using namespace ROOT::iOS::Browser; object = dynamic_cast<TAttLine *>(o); + assert("setObject:, object has a wrong type, TAttLine expected"); unsigned item = 0; const Style_t lineStyle = object->GetLineStyle(); @@ -164,21 +145,21 @@ - (NSString *) getComponentName #pragma mark - Horizontal picker delegate. //____________________________________________________________________________________________________ -- (void) item : (unsigned int)item wasSelectedInPicker : (HorizontalPickerView *)picker +- (void) item : (unsigned int) item wasSelectedInPicker : (HorizontalPickerView *) picker { + assert(picker != nil && "item:wasSelectedInPicker:, parameter 'picker' is nil"); + assert(object != nullptr && "item:wasSelectedInPicker:, object is null"); + using namespace ROOT::iOS::Browser; if (picker == lineColorPicker) { - if (item < nROOTDefaultColors) { - const unsigned colorIndex = colorIndices[item]; - object->SetLineColor(colorIndex); - } else - NSLog(@"check the code, bad item index from horizontal picker: %u, must be < %u", item, nROOTDefaultColors); + assert(item < nROOTDefaultColors && "item:wasSelectedInPicker:, parameter 'item' is out of bounds"); + const unsigned colorIndex = colorIndices[item]; + object->SetLineColor(colorIndex); } else { - if (item < 10) - object->SetLineStyle(item + 1); - else - NSLog(@"check the code, bad item index from horizontal picker: %u must be < 11", item); + //why 10 is hardcoded? + assert(item < 10 && "item:wasSelectedInPicker:, parameter 'item' is out of bounds"); + object->SetLineStyle(item + 1); } [controller objectWasModifiedUpdateSelection : NO]; @@ -189,6 +170,8 @@ - (void) item : (unsigned int)item wasSelectedInPicker : (HorizontalPickerView * //____________________________________________________________________________________________________ - (void) updateROOTLineWidth { + assert(object != nullptr && "updateROOTLineWidth, object is null"); + if (dynamic_cast<TGraph *>(object)) { const int fakeLineWidth = int(object->GetLineWidth()) / 100 * 100; if (fakeLineWidth >= 0) diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/MarkerInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/MarkerInspector.h new file mode 100644 index 0000000000000..99acfd3509c0c --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/MarkerInspector.h @@ -0,0 +1,17 @@ +#import <UIKit/UIKit.h> + +#import "ObjectInspectorComponent.h" +#import "HorizontalPickerDelegate.h" + +// +//Object inspector to work with a TAttMarker, has: +//two horizontal pickers (marker type and color) + marker size. +// + +@interface MarkerInspector : UIViewController <ObjectInspectorComponent, HorizontalPickerDelegate> + +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) o; +- (NSString *) getComponentName; + +@end diff --git a/test/ios/RootBrowser/MarkerInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/MarkerInspector.mm similarity index 70% rename from test/ios/RootBrowser/MarkerInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/MarkerInspector.mm index 1010b7f8faea2..d23f1498f0170 100644 --- a/test/ios/RootBrowser/MarkerInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/MarkerInspector.mm @@ -1,5 +1,7 @@ +#import <cassert> + #import "HorizontalPickerView.h" -#import "ROOTObjectController.h" +#import "ObjectViewController.h" #import "MarkerInspector.h" #import "MarkerStyleCell.h" #import "ColorCell.h" @@ -16,66 +18,69 @@ const CGFloat maxMarkerSize = 5.f; const CGFloat sizeStep = 0.1f; -EMarkerStyle markerStyles[] = {kDot, kPlus, kStar, kCircle, kMultiply, - kFullDotSmall, kFullDotMedium, kFullDotLarge, - kFullCircle, kFullSquare, kFullTriangleUp, - kFullTriangleDown, kOpenCircle, kOpenSquare, - kOpenTriangleUp, kOpenDiamond, kOpenCross, - kFullStar, kOpenStar, kOpenTriangleDown, - kFullDiamond, kFullCross}; +EMarkerStyle const markerStyles[] = {kDot, kPlus, kStar, kCircle, kMultiply, + kFullDotSmall, kFullDotMedium, kFullDotLarge, + kFullCircle, kFullSquare, kFullTriangleUp, + kFullTriangleDown, kOpenCircle, kOpenSquare, + kOpenTriangleUp, kOpenDiamond, kOpenCross, + kFullStar, kOpenStar, kOpenTriangleDown, + kFullDiamond, kFullCross}; const unsigned nMarkers = sizeof markerStyles / sizeof markerStyles[0]; //____________________________________________________________________________________________________ -BOOL canScaleMarker(Style_t style) +bool CanScaleMarker(Style_t style) { - if (style == kDot || style == kFullDotSmall || style == kFullDotMedium) - return NO; - return YES; + return !(style == kDot || style == kFullDotSmall || style == kFullDotMedium); } } @implementation MarkerInspector { + __weak IBOutlet UIButton *plusBtn; + __weak IBOutlet UIButton *minusBtn; + __weak IBOutlet UILabel *sizeLabel; + HorizontalPickerView *markerStylePicker; HorizontalPickerView *markerColorPicker; NSMutableArray *styleCells; NSMutableArray *colorCells; - __weak ROOTObjectController *controller; + __weak ObjectViewController *controller; TAttMarker *object; } //____________________________________________________________________________________________________ -- (id) initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { using namespace ROOT::iOS::Browser; self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; if (self) { + //Force views load. [self view]; styleCells = [[NSMutableArray alloc] init];//]WithCapacity : nMarkers]; for (unsigned i = 0; i < nMarkers; ++i) { - MarkerStyleCell *newCell = [[MarkerStyleCell alloc] initWithFrame : cellRect andMarkerStyle : markerStyles[i]]; + MarkerStyleCell * const newCell = [[MarkerStyleCell alloc] initWithFrame : cellRect andMarkerStyle : markerStyles[i]]; [styleCells addObject : newCell]; } - markerStylePicker = [[HorizontalPickerView alloc] initWithFrame:CGRectMake(15.f, 15.f, 220.f, 70.f)]; + markerStylePicker = [[HorizontalPickerView alloc] initWithFrame : CGRectMake(15.f, 15.f, 220.f, 70.f)]; [markerStylePicker addItems : styleCells]; [self.view addSubview : markerStylePicker]; markerStylePicker.pickerDelegate = self; colorCells = [[NSMutableArray alloc] init]; for (unsigned i = 0; i < nROOTDefaultColors; ++i) { - ColorCell *newCell = [[ColorCell alloc] initWithFrame : cellRect]; + ColorCell * const newCell = [[ColorCell alloc] initWithFrame : cellRect]; [newCell setRGB : predefinedFillColors[i]]; [colorCells addObject : newCell]; } - markerColorPicker = [[HorizontalPickerView alloc] initWithFrame:CGRectMake(15.f, 110.f, 220.f, 70.f)]; + markerColorPicker = [[HorizontalPickerView alloc] initWithFrame : CGRectMake(15.f, 110.f, 220.f, 70.f)]; [markerColorPicker addItems : colorCells]; [self.view addSubview : markerColorPicker]; markerColorPicker.pickerDelegate = self; @@ -84,41 +89,23 @@ - (id) initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundle return self; } -//____________________________________________________________________________________________________ -- (void) didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle +#pragma mark - Interface orientation. //____________________________________________________________________________________________________ -- (void) viewDidLoad +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. +#pragma unused(interfaceOrientation) + return YES; } -//____________________________________________________________________________________________________ -- (void) viewDidUnload -{ - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} +#pragma mark - Horizontal picker delegate. //____________________________________________________________________________________________________ -- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation +- (void) item : (unsigned int) item wasSelectedInPicker : (HorizontalPickerView *) picker { - // Return YES for supported orientations - return YES; -} + assert(picker != nil && "item:wasSelectedInPicker:, parameter 'picker' is nil"); + assert(object != nullptr && "item:wasSelectedInPicker:, object is null"); -//____________________________________________________________________________________________________ -- (void) item : (unsigned int)item wasSelectedInPicker : (HorizontalPickerView *)picker -{ if (picker == markerColorPicker) { const unsigned colorIndex = ROOT::iOS::Browser::colorIndices[item]; object->SetMarkerColor(colorIndex); @@ -126,7 +113,7 @@ - (void) item : (unsigned int)item wasSelectedInPicker : (HorizontalPickerView * } else if (picker == markerStylePicker) { if (item < nMarkers) { EMarkerStyle style = markerStyles[item]; - if (canScaleMarker(style)) { + if (CanScaleMarker(style)) { plusBtn.enabled = YES; minusBtn.enabled = YES; sizeLabel.text = [NSString stringWithFormat : @"%.2g", object->GetMarkerSize()]; @@ -148,17 +135,22 @@ - (void) item : (unsigned int)item wasSelectedInPicker : (HorizontalPickerView * #pragma mark ObjectInspectorComponent protocol. //____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c +- (void) setObjectController : (ObjectViewController *) c { + assert(c != nil && "setObjectController:, parameter 'c' is nil"); + controller = c; } //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (void) setObject : (TObject *) o { using namespace ROOT::iOS::Browser; + + assert(o != nullptr && "setObject:, parameter 'o' is null"); object = dynamic_cast<TAttMarker *>(o); + //The result is tested one level up, no check here. unsigned item = 0; const EMarkerStyle style = EMarkerStyle(object->GetMarkerStyle());//Mess with all these styles and EMarkerStyles. @@ -185,7 +177,7 @@ - (void) setROOTObject : (TObject *)o [markerColorPicker setSelectedItem : item]; - if (!canScaleMarker(object->GetMarkerStyle())) { + if (!CanScaleMarker(object->GetMarkerStyle())) { plusBtn.enabled = NO; minusBtn.enabled = NO; sizeLabel.text = @"1"; @@ -202,9 +194,12 @@ - (NSString *) getComponentName return @"Marker attributes"; } +#pragma mark - UI interactions. + //____________________________________________________________________________________________________ - (IBAction) plusPressed { + assert(object != nullptr && "plusPressed, object is null"); if (object->GetMarkerSize() + sizeStep > maxMarkerSize) return; @@ -217,6 +212,8 @@ - (IBAction) plusPressed //____________________________________________________________________________________________________ - (IBAction) minusPressed { + assert(object != nullptr && "minusPressed, object is null"); + if (object->GetMarkerSize() - sizeStep < 1.) return; diff --git a/test/ios/RootBrowser/ObjectInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/ObjectInspector.h similarity index 68% rename from test/ios/RootBrowser/ObjectInspector.h rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/ObjectInspector.h index 62795beadfd3a..5106fbadb13e9 100644 --- a/test/ios/RootBrowser/ObjectInspector.h +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/ObjectInspector.h @@ -6,8 +6,8 @@ @interface ObjectInspector : UIViewController <ObjectInspectorComponent> -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)o; +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) o; - (void) resetInspector; - (EditorView *) getEditorView; diff --git a/test/ios/RootBrowser/ObjectInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/ObjectInspector.mm similarity index 78% rename from test/ios/RootBrowser/ObjectInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/ObjectInspector.mm index 3740f62cf81b7..761196e18cdc4 100644 --- a/test/ios/RootBrowser/ObjectInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/ObjectInspector.mm @@ -1,3 +1,5 @@ +#import <cassert> + #import "InspectorWithNavigation.h" #import "FilledAreaInspector.h" #import "ObjectInspector.h" @@ -69,66 +71,64 @@ - (void) cacheEditors } //____________________________________________________________________________________________________ -- (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { - self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; + self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; + if (self) { [self initObjectInspectorView]; [self cacheEditors]; } - return self; -} -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. + return self; } -#pragma mark - View lifecycle +#pragma mark - Interface orientation. -/* -// Implement loadView to create a view hierarchy programmatically, without using a nib. -- (void)loadView +//____________________________________________________________________________________________________ +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { -} -*/ +#pragma unused(interfaceOrientation) -/* -// Implement viewDidLoad to do additional setup after loading the view, typically from a nib. -- (void)viewDidLoad -{ - [super viewDidLoad]; + return YES; } -*/ //____________________________________________________________________________________________________ -- (void)viewDidUnload +- (void) setObjectController : (ObjectViewController *) c { - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; + assert(c != nil && "setObjectController:, parameter 'c' is nil"); + + for (unsigned i = 0; i < nActiveEditors; ++i) + [activeEditors[i] setObjectController : c]; } //____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation +- (void) setObject : (TObject *) o { - // Return YES for supported orientations - return YES; -} + assert(o != nullptr && "setObject:, parameter 'o' is null"); -//____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c -{ - for (unsigned i = 0; i < nActiveEditors; ++i) - [activeEditors[i] setROOTObjectController : c]; + if (o != object) { + //Initialize. + object = o; + + [self setTitle]; + [self setActiveEditors]; + + for (unsigned i = 0; i < nActiveEditors; ++i) + [activeEditors[i] setObject : o]; + + [editorView removeAllEditors]; + + for (unsigned i = 0; i < nActiveEditors; ++i) + [editorView addSubEditor : activeEditors[i].view withName : [activeEditors[i] getComponentName]]; + } } //____________________________________________________________________________________________________ - (void) setTitle { + assert(object != nullptr && "setTitle, object is null"); + if (dynamic_cast<TAttPad *>(object)) { //This is special case, as soon as ROOT::iOS::Pad does not have //ClassDef, the IsA() will be for TVirtualPad, but I want to @@ -163,26 +163,6 @@ - (void) setActiveEditors activeEditors[nActiveEditors++] = cachedEditors[kAttH1]; } -//____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o -{ - if (o != object) { - //Initialize. - object = o; - - [self setTitle]; - [self setActiveEditors]; - - for (unsigned i = 0; i < nActiveEditors; ++i) - [activeEditors[i] setROOTObject : o]; - - [editorView removeAllEditors]; - - for (unsigned i = 0; i < nActiveEditors; ++i) - [editorView addSubEditor : activeEditors[i].view withName : [activeEditors[i] getComponentName]]; - } -} - //____________________________________________________________________________________________________ - (void) resetInspector { diff --git a/test/ios/RootBrowser/ObjectInspectorComponent.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/ObjectInspectorComponent.h similarity index 66% rename from test/ios/RootBrowser/ObjectInspectorComponent.h rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/ObjectInspectorComponent.h index d8f88bdf936a1..898a0c3bb3fd2 100644 --- a/test/ios/RootBrowser/ObjectInspectorComponent.h +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/ObjectInspectorComponent.h @@ -5,14 +5,15 @@ //"object-inspector". // -@class ROOTObjectController; +@class ObjectViewController; class TObject; @protocol ObjectInspectorComponent <NSObject> +@required -- (void) setROOTObjectController : (ROOTObjectController *)c; -- (void) setROOTObject : (TObject *)o; +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) o; @optional diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadInspector.h new file mode 100644 index 0000000000000..6d5bb6b141787 --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadInspector.h @@ -0,0 +1,19 @@ +#import <UIKit/UIKit.h> + +#import "ObjectInspectorComponent.h" + +// +//Object inspector for a TAttPad, contains two tabs for: 1) axis ticks and grids and +//2) log scales. +// + +@interface PadInspector : UIViewController <ObjectInspectorComponent, UITabBarDelegate> + ++ (CGRect) inspectorFrame; + +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) o; +- (NSString *) getComponentName; +- (void) resetInspector; + +@end diff --git a/test/ios/RootBrowser/PadInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadInspector.mm similarity index 64% rename from test/ios/RootBrowser/PadInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadInspector.mm index f634c982260b9..5993c08765ed5 100644 --- a/test/ios/RootBrowser/PadInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadInspector.mm @@ -1,27 +1,22 @@ +#import <cassert> + #import "PadTicksGridInspector.h" #import "PadLogScaleInspector.h" #import "PadInspector.h" -//It's mm file == C++, consts have internal linkage. const CGFloat totalHeight = 250.f; const CGFloat tabBarHeight = 49.f; const CGRect nestedComponentFrame = CGRectMake(0.f, tabBarHeight, 250.f, totalHeight - tabBarHeight); -@interface PadInspector () { +@implementation PadInspector { + __weak IBOutlet UITabBar *tabBar; PadTicksGridInspector *gridInspector; PadLogScaleInspector *logScaleInspector; - __weak ROOTObjectController *controller; + __weak ObjectViewController *controller; TObject *object; } -- (void) showTicksAndGridInspector; -- (void) showLogScaleInspector; - -@end - -@implementation PadInspector - //____________________________________________________________________________________________________ + (CGRect) inspectorFrame { @@ -29,13 +24,15 @@ + (CGRect) inspectorFrame } //____________________________________________________________________________________________________ -- (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { - self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; + self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; - [self view]; + if (self) { + //Force views load. + [self view]; //Load inspectors from nib files. gridInspector = [[PadTicksGridInspector alloc] initWithNibName : @"PadTicksGridInspector" bundle : nil]; gridInspector.view.frame = nestedComponentFrame; @@ -54,52 +51,35 @@ - (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleO return self; } -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle +#pragma mark - Interface orientation. //____________________________________________________________________________________________________ -- (void)viewDidLoad +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. +#pragma unused(interfaceOrientation) + return YES; } -//____________________________________________________________________________________________________ -- (void)viewDidUnload -{ - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} +#pragma mark - ObjectInspectorComponent. //____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation +- (void) setObjectController : (ObjectViewController *) c { - // Return YES for supported orientations - return YES; -} + assert(c != nil && "setObjectController:, parameter 'c' is nil"); -//____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c -{ controller = c; - [gridInspector setROOTObjectController : c]; - [logScaleInspector setROOTObjectController : c]; + [gridInspector setObjectController : c]; + [logScaleInspector setObjectController : c]; } //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (void) setObject : (TObject *) o { + assert(o != nullptr && "setObject:, parameter 'o' is null"); + object = o; - [gridInspector setROOTObject : o]; - [logScaleInspector setROOTObject : o]; + [gridInspector setObject : o]; + [logScaleInspector setObject : o]; } //____________________________________________________________________________________________________ @@ -130,9 +110,12 @@ - (void) showLogScaleInspector } #pragma mark - Tabbar delegate. + //____________________________________________________________________________________________________ -- (void) tabBar : (UITabBar *) tb didSelectItem : (UITabBarItem *)item +- (void) tabBar : (UITabBar *) tb didSelectItem : (UITabBarItem *) item { +#pragma unused(tb) + if (item.tag == 1) [self showTicksAndGridInspector]; else if (item.tag == 2) diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadLogScaleInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadLogScaleInspector.h new file mode 100644 index 0000000000000..82d365f0c61dd --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadLogScaleInspector.h @@ -0,0 +1,14 @@ +#import <UIKit/UIKit.h> + +#import "ObjectInspectorComponent.h" + +// +//Object inspector (one of two tabs) for a pad's log scales. +// + +@interface PadLogScaleInspector : UIViewController <ObjectInspectorComponent> + +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) o; + +@end diff --git a/test/ios/RootBrowser/PadLogScaleInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadLogScaleInspector.mm similarity index 53% rename from test/ios/RootBrowser/PadLogScaleInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadLogScaleInspector.mm index 1880ee8eaeb94..934ffe09535eb 100644 --- a/test/ios/RootBrowser/PadLogScaleInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadLogScaleInspector.mm @@ -1,4 +1,6 @@ -#import "ROOTObjectController.h" +#import <cassert> + +#import "ObjectViewController.h" #import "PadLogScaleInspector.h" //C++ (ROOT) imports. @@ -6,69 +8,64 @@ #import "TObject.h" @implementation PadLogScaleInspector { - __weak ROOTObjectController *controller; + __weak IBOutlet UISwitch *logX; + __weak IBOutlet UISwitch *logY; + __weak IBOutlet UISwitch *logZ; + + __weak ObjectViewController *controller; TVirtualPad *object; } //____________________________________________________________________________________________________ -- (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; - [self view]; + if (self) { + //Force a view load. + [self view]; + } + return self; } -//____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c -{ - controller = c; -} +#pragma mark - Interface orientation. //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - object = static_cast<TVirtualPad *>(o); - //Result of cast is not checked here, it's done at the upper level. - logX.on = object->GetLogx(); - logY.on = object->GetLogy(); - logZ.on = object->GetLogz(); -} +#pragma unused(interfaceOrientation) -//____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. + return YES; } -#pragma mark - View lifecycle -//____________________________________________________________________________________________________ -- (void)viewDidLoad -{ - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. -} +#pragma mark - ObjectInspectorComponent. //____________________________________________________________________________________________________ -- (void)viewDidUnload +- (void) setObjectController : (ObjectViewController *) c { - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; + assert(c != nil && "setObjectController:, parameter 'c' is nil"); + + controller = c; } //____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation +- (void) setObject : (TObject *) o { - // Return YES for supported orientations - return YES; + assert(o != nullptr && "setObject:, parameter 'o' is null"); + + object = static_cast<TVirtualPad *>(o); + //Result of cast is not checked here, it's done at the upper level. + logX.on = object->GetLogx(); + logY.on = object->GetLogy(); + logZ.on = object->GetLogz(); } //____________________________________________________________________________________________________ - (IBAction) logActivated : (UISwitch *) log { + assert(object != nullptr && "logActivated:, object is null"); + if (log == logX) object->SetLogx(log.on); if (log == logY) diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadTicksGridInspector.h b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadTicksGridInspector.h new file mode 100644 index 0000000000000..ffd3fa8e9130d --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadTicksGridInspector.h @@ -0,0 +1,10 @@ +#import <UIKit/UIKit.h> + +#import "ObjectInspectorComponent.h" + +@interface PadTicksGridInspector : UIViewController <ObjectInspectorComponent> + +- (void) setObjectController : (ObjectViewController *) c; +- (void) setObject : (TObject *) obj; + +@end diff --git a/test/ios/RootBrowser/PadTicksGridInspector.mm b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadTicksGridInspector.mm similarity index 57% rename from test/ios/RootBrowser/PadTicksGridInspector.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadTicksGridInspector.mm index 34f5356681bbb..ecd680f691c97 100644 --- a/test/ios/RootBrowser/PadTicksGridInspector.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Controllers/PadTicksGridInspector.mm @@ -1,30 +1,47 @@ +#import <cassert> + #import "PadTicksGridInspector.h" -#import "ROOTObjectController.h" +#import "ObjectViewController.h" #import "TVirtualPad.h" #import "TObject.h" @implementation PadTicksGridInspector { - __weak ROOTObjectController *controller; + __weak IBOutlet UISwitch *gridX; + __weak IBOutlet UISwitch *gridY; + __weak IBOutlet UISwitch *ticksX; + __weak IBOutlet UISwitch *ticksY; + + __weak ObjectViewController *controller; TVirtualPad *object; } //____________________________________________________________________________________________________ -- (id)initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil +- (instancetype) initWithNibName : (NSString *) nibNameOrNil bundle : (NSBundle *) nibBundleOrNil { self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; - [self view]; - - if (self) { - } + if (self) + [self view]; return self; } +#pragma mark - ObjectInspectorComponent. + //____________________________________________________________________________________________________ -- (void) setROOTObject : (TObject *)o +- (void) setObjectController : (ObjectViewController *) c { + assert(c != nil && "setObjectController:, parameter 'c' is nil"); + + controller = c; +} + +//____________________________________________________________________________________________________ +- (void) setObject : (TObject *) o +{ + assert(o != nullptr && "setObject:, parameter 'o' is null"); + object = static_cast<TVirtualPad *>(o); //I do not check the result of cast here, it's done on upper level. @@ -34,41 +51,13 @@ - (void) setROOTObject : (TObject *)o ticksY.on = object->GetTicky(); } -//____________________________________________________________________________________________________ -- (void) setROOTObjectController : (ROOTObjectController *)c -{ - controller = c; -} +#pragma mark - Interface orientation. //____________________________________________________________________________________________________ -- (void)didReceiveMemoryWarning +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. -} - -#pragma mark - View lifecycle - -//____________________________________________________________________________________________________ -- (void)viewDidLoad -{ - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. -} - -//____________________________________________________________________________________________________ -- (void)viewDidUnload -{ - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} +#pragma unused(interfaceOrientation) -//____________________________________________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations return YES; } @@ -77,6 +66,8 @@ - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interface //____________________________________________________________________________________________________ - (IBAction) gridActivated : (UISwitch *) g { + assert(object != nullptr && "gridActivated:, object is null"); + if (g == gridX) object->SetGridx(g.on); else if (g == gridY) @@ -88,6 +79,8 @@ - (IBAction) gridActivated : (UISwitch *) g //____________________________________________________________________________________________________ - (IBAction) ticksActivated : (UISwitch *) t { + assert(object != nullptr && "ticksActivated:, object is null"); + if (t == ticksX) object->SetTickx(t.on); else if (t == ticksY) diff --git a/test/ios/RootBrowser/ColorCell.h b/test/ios/RootBrowser/Src/ObjectInspector/Views/ColorCell.h similarity index 100% rename from test/ios/RootBrowser/ColorCell.h rename to test/ios/RootBrowser/Src/ObjectInspector/Views/ColorCell.h diff --git a/test/ios/RootBrowser/ColorCell.mm b/test/ios/RootBrowser/Src/ObjectInspector/Views/ColorCell.mm similarity index 86% rename from test/ios/RootBrowser/ColorCell.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Views/ColorCell.mm index 8cbe562af7017..948a91164602e 100644 --- a/test/ios/RootBrowser/ColorCell.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/ColorCell.mm @@ -1,3 +1,5 @@ +#import <cassert> + #import <QuartzCore/QuartzCore.h> #import "ColorCell.h" @@ -7,11 +9,9 @@ @implementation ColorCell { } //____________________________________________________________________________________________________ -- (id)initWithFrame:(CGRect)frame +- (id) initWithFrame : (CGRect) frame { - self = [super initWithFrame:frame]; - - if (self) { + if (self = [super initWithFrame : frame]) { self.backgroundColor = [UIColor clearColor]; self.layer.shadowColor = [UIColor darkGrayColor].CGColor; self.layer.shadowOffset = CGSizeMake(4.f, 4.f); @@ -30,13 +30,15 @@ - (id)initWithFrame:(CGRect)frame //____________________________________________________________________________________________________ - (void) setRGB : (const double *) newRgb { + assert(newRgb != nullptr && "setRGN:, parameter 'newRgb' is null"); + rgb[0] = newRgb[0]; rgb[1] = newRgb[1]; rgb[2] = newRgb[2]; } //____________________________________________________________________________________________________ -- (void)drawRect:(CGRect)rect +- (void) drawRect : (CGRect) rect { CGContextRef ctx = UIGraphicsGetCurrentContext(); if (!ctx) { diff --git a/test/ios/RootBrowser/Src/ObjectInspector/Views/EditorPlateView.h b/test/ios/RootBrowser/Src/ObjectInspector/Views/EditorPlateView.h new file mode 100644 index 0000000000000..85bc51681f3c2 --- /dev/null +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/EditorPlateView.h @@ -0,0 +1,13 @@ +#import <UIKit/UIKit.h> + +@class EditorView; + +@interface EditorPlateView : UIView + +@property (nonatomic) NSString *editorName; +@property (nonatomic) UIImageView *arrowImageView; + ++ (CGFloat) plateHeight; +- (id) initWithFrame : (CGRect) frame editorName : (NSString *) name topView : (EditorView *) tv; + +@end diff --git a/test/ios/RootBrowser/EditorPlateView.mm b/test/ios/RootBrowser/Src/ObjectInspector/Views/EditorPlateView.mm similarity index 91% rename from test/ios/RootBrowser/EditorPlateView.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Views/EditorPlateView.mm index 91f501c1e9754..a631dffa4cf70 100644 --- a/test/ios/RootBrowser/EditorPlateView.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/EditorPlateView.mm @@ -25,7 +25,7 @@ + (CGFloat) plateHeight } //____________________________________________________________________________________________________ -- (id)initWithFrame:(CGRect)frame editorName : (NSString *)name topView : (EditorView *) tv +- (id)initWithFrame : (CGRect) frame editorName : (NSString *) name topView : (EditorView *) tv { self = [super initWithFrame:frame]; @@ -33,7 +33,7 @@ - (id)initWithFrame:(CGRect)frame editorName : (NSString *)name topView : (Edito editorLabel = [[UILabel alloc] initWithFrame : CGRectMake(frame.size.width / 2 - 60.f, 10.f, 120.f, 30.f)]; editorLabel.backgroundColor = [UIColor clearColor]; editorLabel.font = [UIFont systemFontOfSize : 14]; - editorLabel.textAlignment = UITextAlignmentCenter; + editorLabel.textAlignment = NSTextAlignmentCenter; editorLabel.textColor = [UIColor whiteColor]; [self addSubview : editorLabel]; editorLabel.text = name; @@ -59,7 +59,7 @@ - (id)initWithFrame:(CGRect)frame editorName : (NSString *)name topView : (Edito } //____________________________________________________________________________________________________ -- (void)drawRect : (CGRect)rect +- (void) drawRect : (CGRect) rect { [plateImage drawAtPoint : CGPointZero]; //Draw the triangle. diff --git a/test/ios/RootBrowser/EditorView.h b/test/ios/RootBrowser/Src/ObjectInspector/Views/EditorView.h similarity index 82% rename from test/ios/RootBrowser/EditorView.h rename to test/ios/RootBrowser/Src/ObjectInspector/Views/EditorView.h index 7a518b292b238..b340db74e2e49 100644 --- a/test/ios/RootBrowser/EditorView.h +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/EditorView.h @@ -22,9 +22,9 @@ - (void) removeAllEditors; - (void) propertyUpdated; -- (void) addSubEditor : (UIView *)element withName : (NSString *)editorName; +- (void) addSubEditor : (UIView *) element withName : (NSString *) editorName; - (void) correctFrames; - (void) plateTapped : (EditorPlateView *) plate; -- (void) setEditorTitle : (const char*)title; +- (void) setEditorTitle : (const char*) title; @end diff --git a/test/ios/RootBrowser/EditorView.mm b/test/ios/RootBrowser/Src/ObjectInspector/Views/EditorView.mm similarity index 92% rename from test/ios/RootBrowser/EditorView.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Views/EditorView.mm index fdcfe15cc90bd..fc486d6d04789 100644 --- a/test/ios/RootBrowser/EditorView.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/EditorView.mm @@ -1,13 +1,16 @@ -#import <math.h> - -#import <CoreGraphics/CGContext.h> +#import <cassert> +#import <cmath> #import "ScrollViewWithPickers.h" #import "EditorPlateView.h" #import "EditorView.h" - -//Hoho! As soon as I use Objective-C++, I can use namespaces! "Yeaaahhh, that's good!" (c) Duke Nukem. +// +//This implementation of shrinking/extending views is quite a strange +//(for me today) - instead of some recursive structure [item [subitems:[item ..... +//I have ... this. It work ok though, so let it be :) +//CERN.app has a better implementation :) +// namespace { @@ -82,16 +85,14 @@ + (CGFloat) ncHeight } //____________________________________________________________________________________________________ -- (id)initWithFrame : (CGRect)frame +- (id) initWithFrame : (CGRect) frame { - self = [super initWithFrame : frame]; - - if (self) { + if (self = [super initWithFrame : frame]) { //Scroll view is a container for all sub-editors. //It's completely transparent. const CGRect titleRect = CGRectMake(10.f, 10.f, 250.f, 35.f); editorTitle = [[UILabel alloc] initWithFrame : titleRect]; - editorTitle.textAlignment = UITextAlignmentCenter; + editorTitle.textAlignment = NSTextAlignmentCenter; editorTitle.textColor = [UIColor blackColor]; editorTitle.backgroundColor = [UIColor clearColor]; [self addSubview : editorTitle]; @@ -109,10 +110,17 @@ - (id)initWithFrame : (CGRect)frame } //____________________________________________________________________________________________________ -- (void) drawRect : (CGRect)rect +- (void) drawRect : (CGRect) rect { //Draw main editor's view as a semi-transparent //gray view with rounded corners. + + //I can have round corner by using self.layer.cornerRadius ... + //but I do not want all 4 corners rounded, only top left and bottom left. + //I can use self.layer.mask and create a bezier path for this ... + //but I'll have later to reset it manually and ... geometry starts + //jumping during a device rotation. So ... ugly but the + //best solution is to implement this drawRect: with non-opaque view! CGContextRef ctx = UIGraphicsGetCurrentContext(); if (!ctx) { @@ -120,8 +128,7 @@ - (void) drawRect : (CGRect)rect return; } - UIColor *background = [[UIColor scrollViewTexturedBackgroundColor] colorWithAlphaComponent : [EditorView editorAlpha]]; -// UIColor *background = [[UIColor colorWithPatternImage:[UIImage imageNamed:@"inspector_bkn.png"]] colorWithAlphaComponent : [EditorView editorAlpha]]; + UIColor * const background = [UIColor colorWithRed : 102 / 255.f green : 140 / 255.f blue : 189 / 255.f alpha : [EditorView editorAlpha]]; CGContextSetFillColorWithColor(ctx, background.CGColor); CGContextSetPatternPhase(ctx, CGSizeMake(-8.f, 0.f)); @@ -215,8 +222,10 @@ - (void) setPlatesYs } //____________________________________________________________________________________________________ -- (void) addSubEditor:(UIView *)element withName : (NSString *)name +- (void) addSubEditor : (UIView *) element withName : (NSString *) name { + assert(element != nil && "addSubEditor:withName:, parameter 'element' is nil"); + if (nEditors == evMaxComponents) { NSLog(@"Could not add more editors"); return; diff --git a/test/ios/RootBrowser/LineStyleCell.h b/test/ios/RootBrowser/Src/ObjectInspector/Views/LineStyleCell.h similarity index 100% rename from test/ios/RootBrowser/LineStyleCell.h rename to test/ios/RootBrowser/Src/ObjectInspector/Views/LineStyleCell.h diff --git a/test/ios/RootBrowser/LineStyleCell.mm b/test/ios/RootBrowser/Src/ObjectInspector/Views/LineStyleCell.mm similarity index 95% rename from test/ios/RootBrowser/LineStyleCell.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Views/LineStyleCell.mm index 485d46a83f542..fed5f765345dd 100644 --- a/test/ios/RootBrowser/LineStyleCell.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/LineStyleCell.mm @@ -1,5 +1,4 @@ #import <QuartzCore/QuartzCore.h> -#import <CoreGraphics/CGContext.h> #import "LineStyleCell.h" @@ -29,7 +28,7 @@ - (id) initWithFrame : (CGRect)frame lineStyle : (unsigned) style } //____________________________________________________________________________________________________ -- (void)drawRect:(CGRect)rect +- (void) drawRect : (CGRect) rect { CGContextRef ctx = UIGraphicsGetCurrentContext(); diff --git a/test/ios/RootBrowser/LineWidthCell.h b/test/ios/RootBrowser/Src/ObjectInspector/Views/LineWidthCell.h similarity index 76% rename from test/ios/RootBrowser/LineWidthCell.h rename to test/ios/RootBrowser/Src/ObjectInspector/Views/LineWidthCell.h index 33e17e952ffe5..be59cca88e4a4 100644 --- a/test/ios/RootBrowser/LineWidthCell.h +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/LineWidthCell.h @@ -3,6 +3,6 @@ @interface LineWidthCell : UIView - (id) initWithFrame : (CGRect) frame width : (CGFloat) lineWidth; -- (void) setLineWidth : (CGFloat)width; +- (void) setLineWidth : (CGFloat) width; @end diff --git a/test/ios/RootBrowser/LineWidthCell.mm b/test/ios/RootBrowser/Src/ObjectInspector/Views/LineWidthCell.mm similarity index 59% rename from test/ios/RootBrowser/LineWidthCell.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Views/LineWidthCell.mm index 1e27d6e8bae91..c7bec58f69107 100644 --- a/test/ios/RootBrowser/LineWidthCell.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/LineWidthCell.mm @@ -1,19 +1,19 @@ -#import <CoreGraphics/CGContext.h> +#import <cassert> + #import <QuartzCore/QuartzCore.h> #import "LineWidthCell.h" - @implementation LineWidthCell { CGFloat lineWidth; } //____________________________________________________________________________________________________ -- (id)initWithFrame:(CGRect)frame width : (CGFloat)w +- (id) initWithFrame : (CGRect) frame width : (CGFloat) w { - self = [super initWithFrame:frame]; + assert(w >= 0.f && "initWithFrame:width:, parameter 'w' is negative"); - if (self) { + if (self = [super initWithFrame : frame]) { lineWidth = w; self.layer.shadowOpacity = 0.4f; @@ -27,7 +27,7 @@ - (id)initWithFrame:(CGRect)frame width : (CGFloat)w } //____________________________________________________________________________________________________ -- (void)drawRect:(CGRect)rect +- (void) drawRect : (CGRect) rect { CGContextRef ctx = UIGraphicsGetCurrentContext(); @@ -40,14 +40,17 @@ - (void)drawRect:(CGRect)rect CGContextAddLineToPoint(ctx, rect.size.width - 10, rect.size.height / 2); CGContextStrokePath(ctx); - NSString *label = [NSString stringWithFormat:@"(%d)", (int)lineWidth]; - CGContextSetRGBFillColor(ctx, 0.f, 0.f, 1.f, 1.f); - [label drawInRect:CGRectMake(rect.size.width / 2 - 10.f, rect.size.height / 2 - 15.f, 40.f, 60.f) withFont : [UIFont systemFontOfSize : 10]]; + NSString * const label = [NSString stringWithFormat : @"(%d)", (int)lineWidth]; + NSDictionary * const attributes = @{NSFontAttributeName : [UIFont systemFontOfSize : 10], + NSForegroundColorAttributeName : [UIColor blackColor]}; + [label drawInRect : CGRectMake(rect.size.width / 2 - 10.f, rect.size.height / 2 - 15.f, 40.f, 60.f) withAttributes : attributes]; } //____________________________________________________________________________________________________ -- (void) setLineWidth : (CGFloat)width +- (void) setLineWidth : (CGFloat) width { + assert(lineWidth > 0.f && "setLineWidth:, parameter 'width' must be a positive number"); + lineWidth = width; } diff --git a/test/ios/RootBrowser/LineWidthPicker.h b/test/ios/RootBrowser/Src/ObjectInspector/Views/LineWidthPicker.h similarity index 63% rename from test/ios/RootBrowser/LineWidthPicker.h rename to test/ios/RootBrowser/Src/ObjectInspector/Views/LineWidthPicker.h index 20e4581f8a993..9c9838953e404 100644 --- a/test/ios/RootBrowser/LineWidthPicker.h +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/LineWidthPicker.h @@ -2,6 +2,6 @@ @interface LineWidthPicker : UIView -- (void) setLineWidth : (float)width; +- (void) setLineWidth : (float) width; @end diff --git a/test/ios/RootBrowser/LineWidthPicker.mm b/test/ios/RootBrowser/Src/ObjectInspector/Views/LineWidthPicker.mm similarity index 75% rename from test/ios/RootBrowser/LineWidthPicker.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Views/LineWidthPicker.mm index 4412ca47e40f7..96d94be22c6ba 100644 --- a/test/ios/RootBrowser/LineWidthPicker.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/LineWidthPicker.mm @@ -1,3 +1,5 @@ +#import <cassert> + #import "LineWidthPicker.h" #import "LineWidthCell.h" @@ -13,21 +15,20 @@ - (void) lateInit lineWidthView = [[LineWidthCell alloc] initWithFrame : CGRectMake(10.f, 10.f, 120.f, 50.f) width : 1.f]; [self addSubview : lineWidthView]; - backgroundImage = [UIImage imageNamed:@"line_width_bkn.png"]; + backgroundImage = [UIImage imageNamed : @"line_width_bkn.png"]; } //____________________________________________________________________________________________________ -- (id)initWithFrame:(CGRect)frame +- (id) initWithFrame : (CGRect) frame { - self = [super initWithFrame:frame]; - if (self) { + if (self = [super initWithFrame : frame]) [self lateInit]; - } + return self; } //____________________________________________________________________________________________________ -- (void) drawRect : (CGRect)rect +- (void) drawRect : (CGRect) rect { if (!backgroundImage) [self lateInit]; @@ -36,8 +37,10 @@ - (void) drawRect : (CGRect)rect } //____________________________________________________________________________________________________ -- (void) setLineWidth : (float)width +- (void) setLineWidth : (float) width { + assert(width > 0.f && "setLineWidth:, parameter 'width' must be a positive number"); + [lineWidthView setLineWidth : width]; [lineWidthView setNeedsDisplay]; } diff --git a/test/ios/RootBrowser/MarkerStyleCell.h b/test/ios/RootBrowser/Src/ObjectInspector/Views/MarkerStyleCell.h similarity index 54% rename from test/ios/RootBrowser/MarkerStyleCell.h rename to test/ios/RootBrowser/Src/ObjectInspector/Views/MarkerStyleCell.h index c37662ca0ce8f..4b2eb0bb1db9c 100644 --- a/test/ios/RootBrowser/MarkerStyleCell.h +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/MarkerStyleCell.h @@ -4,6 +4,6 @@ @interface MarkerStyleCell : UIView -- (id) initWithFrame : (CGRect)frame andMarkerStyle : (EMarkerStyle)style; +- (id) initWithFrame : (CGRect) frame andMarkerStyle : (EMarkerStyle) style; @end diff --git a/test/ios/RootBrowser/MarkerStyleCell.mm b/test/ios/RootBrowser/Src/ObjectInspector/Views/MarkerStyleCell.mm similarity index 87% rename from test/ios/RootBrowser/MarkerStyleCell.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Views/MarkerStyleCell.mm index e235a4f028b71..66592fc49b5f4 100644 --- a/test/ios/RootBrowser/MarkerStyleCell.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/MarkerStyleCell.mm @@ -1,5 +1,3 @@ -#import <CoreGraphics/CGContext.h> - #import "MarkerStyleCell.h" #import "IOSMarkers.h" @@ -10,7 +8,7 @@ @implementation MarkerStyleCell { } //____________________________________________________________________________________________________ -- (id) initWithFrame : (CGRect)frame andMarkerStyle : (EMarkerStyle)style +- (id) initWithFrame : (CGRect) frame andMarkerStyle : (EMarkerStyle) style { self = [super initWithFrame : frame]; if (self) { @@ -22,7 +20,7 @@ - (id) initWithFrame : (CGRect)frame andMarkerStyle : (EMarkerStyle)style } //____________________________________________________________________________________________________ -- (void)drawRect : (CGRect)rect +- (void) drawRect : (CGRect) rect { CGContextRef ctx = UIGraphicsGetCurrentContext(); diff --git a/test/ios/RootBrowser/PatternCell.h b/test/ios/RootBrowser/Src/ObjectInspector/Views/PatternCell.h similarity index 100% rename from test/ios/RootBrowser/PatternCell.h rename to test/ios/RootBrowser/Src/ObjectInspector/Views/PatternCell.h diff --git a/test/ios/RootBrowser/PatternCell.mm b/test/ios/RootBrowser/Src/ObjectInspector/Views/PatternCell.mm similarity index 85% rename from test/ios/RootBrowser/PatternCell.mm rename to test/ios/RootBrowser/Src/ObjectInspector/Views/PatternCell.mm index e98a0dc38eab3..82d516ef7af1c 100644 --- a/test/ios/RootBrowser/PatternCell.mm +++ b/test/ios/RootBrowser/Src/ObjectInspector/Views/PatternCell.mm @@ -1,4 +1,5 @@ -#import <CoreGraphics/CGContext.h> +#import <cassert> + #import <QuartzCore/QuartzCore.h> //C++ (ROOT) imports. @@ -12,7 +13,7 @@ @implementation PatternCell { } //____________________________________________________________________________________________________ -- (id) initWithFrame : (CGRect)frame andPattern : (unsigned) index +- (id) initWithFrame : (CGRect) frame andPattern : (unsigned) index { self = [super initWithFrame : frame]; @@ -39,7 +40,7 @@ - (void) setAsSolid } //____________________________________________________________________________________________________ -- (void)drawRect:(CGRect)rect +- (void) drawRect : (CGRect) rect { rect.origin.x = 10.f; rect.origin.y = 10.f; @@ -53,6 +54,10 @@ - (void)drawRect:(CGRect)rect CGContextFillRect(ctx, rect); if (!solid) { //Solid fill - no pattern. + //TODO: check results (CG API calls)??? + assert(patternIndex < ROOT::iOS::GraphicUtils::kPredefinedFillPatterns && + "drawRect:, patternIndex is out of bounds"); + float rgb[] = {0.f, 0.f, 0.f}; CGPatternRef pattern = ROOT::iOS::GraphicUtils::gPatternGenerators[patternIndex](rgb); diff --git a/test/ios/RootBrowser/Constants.h b/test/ios/RootBrowser/Src/Utils/Constants.h similarity index 91% rename from test/ios/RootBrowser/Constants.h rename to test/ios/RootBrowser/Src/Utils/Constants.h index f59873a69a598..5ec9813f434dc 100644 --- a/test/ios/RootBrowser/Constants.h +++ b/test/ios/RootBrowser/Src/Utils/Constants.h @@ -80,7 +80,13 @@ extern const unsigned colorIndices[nROOTDefaultColors]; extern const unsigned stippleBase; //This does not have const qualifier, but set only once during startup (by application delegate). -extern bool deviceIsiPad3; +extern bool deviceHasRetina; + + +extern NSString * const ROOTBrowserViewControllerID; +extern NSString * const FileContentViewControllerID; +extern NSString * const SlideshowViewControllerID; +extern NSString * const ObjectViewControllerID; }//namespace Browser }//namespace iOS diff --git a/test/ios/RootBrowser/Constants.cxx b/test/ios/RootBrowser/Src/Utils/Constants.mm similarity index 89% rename from test/ios/RootBrowser/Constants.cxx rename to test/ios/RootBrowser/Src/Utils/Constants.mm index bcc000285b2a3..85942b624edab 100644 --- a/test/ios/RootBrowser/Constants.cxx +++ b/test/ios/RootBrowser/Src/Utils/Constants.mm @@ -83,7 +83,12 @@ const unsigned colorIndices[nROOTDefaultColors] = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, const unsigned stippleBase = 3000; -bool deviceIsiPad3 = false; +bool deviceHasRetina = false; + +NSString * const ROOTBrowserViewControllerID = @"ROOTBrowserViewControllerID"; +NSString * const FileContentViewControllerID = @"FileContentViewControllerID"; +NSString * const SlideshowViewControllerID = @"SlideshowViewControllerID"; +NSString * const ObjectViewControllerID = @"ObjectViewControllerID"; }//namespace Browser }//namespace iOS diff --git a/test/ios/RootBrowser/FileUtils.h b/test/ios/RootBrowser/Src/Utils/FileUtils.h similarity index 100% rename from test/ios/RootBrowser/FileUtils.h rename to test/ios/RootBrowser/Src/Utils/FileUtils.h diff --git a/test/ios/RootBrowser/FileUtils.cxx b/test/ios/RootBrowser/Src/Utils/FileUtils.mm similarity index 99% rename from test/ios/RootBrowser/FileUtils.cxx rename to test/ios/RootBrowser/Src/Utils/FileUtils.mm index 406e5a3978b47..b64c1dc0623a2 100644 --- a/test/ios/RootBrowser/FileUtils.cxx +++ b/test/ios/RootBrowser/Src/Utils/FileUtils.mm @@ -314,7 +314,7 @@ FileContainer *FileContainer::CreateFileContainer(const char *fullPath) try { std::set<TString> visibleTypes; FillVisibleTypes(visibleTypes); - + std::auto_ptr<TFile> inputFile(TFile::Open(fullPath, "read")); if (!inputFile.get()) return 0; diff --git a/test/ios/RootBrowser/Src/Utils/Shortcuts.h b/test/ios/RootBrowser/Src/Utils/Shortcuts.h new file mode 100644 index 0000000000000..4c0a422eb2999 --- /dev/null +++ b/test/ios/RootBrowser/Src/Utils/Shortcuts.h @@ -0,0 +1,20 @@ +// +// Shortcuts.h +// root_browser +// +// Created by Timur Pocheptsov on 8/22/11. +// Copyright 2011 __MyCompanyName__. All rights reserved. +// + +#import <UIKit/UIKit.h> + +namespace ROOT { +namespace iOS { +namespace Browser { + +//We assume, that 'shortcuts' (some views) are already subviews of a scrollview, I do not check it. +void PlaceShortcutsInScrollView(NSMutableArray *shortcuts, UIScrollView *scrollView, const CGSize &shortCutSize, CGFloat padSpace); + +} +} +} \ No newline at end of file diff --git a/test/ios/RootBrowser/Shortcuts.mm b/test/ios/RootBrowser/Src/Utils/Shortcuts.mm similarity index 68% rename from test/ios/RootBrowser/Shortcuts.mm rename to test/ios/RootBrowser/Src/Utils/Shortcuts.mm index 1bfb1f018dacb..730c3949fa8b7 100644 --- a/test/ios/RootBrowser/Shortcuts.mm +++ b/test/ios/RootBrowser/Src/Utils/Shortcuts.mm @@ -1,17 +1,18 @@ -// -// Shortcuts.m -// root_browser -// -// Created by Timur Pocheptsov on 8/22/11. -// Copyright 2011 __MyCompanyName__. All rights reserved. -// +#import <cassert> #import "Shortcuts.h" -@implementation ShorcutUtil +namespace ROOT { +namespace iOS { +namespace Browser { -+(void) placeShortcuts :(NSMutableArray *)shortcuts inScrollView : (UIScrollView *) scrollView withSize : (CGSize) size andSpace : (CGFloat) addSpace +void PlaceShortcutsInScrollView(NSMutableArray *shortcuts, UIScrollView *scrollView, const CGSize &size, CGFloat addSpace) { + //We assume, that 'shortcuts' (views) are already subviews of a scrollview, I do not check it. + + assert(shortcuts != nil && "PlaceShortcutsInScrollView, parameter 'shortcuts' is nil"); + assert(scrollView != nil && "PlaceShortcutsInScrollView, parameter 'scrollView' is nil"); + const CGRect scrollFrame = scrollView.frame; const CGFloat shortcutWidth = size.width; const CGFloat shortcutHeight = size.height; @@ -36,4 +37,6 @@ +(void) placeShortcuts :(NSMutableArray *)shortcuts inScrollView : (UIScrollView scrollView.contentOffset = CGPointZero; } -@end +} +} +} diff --git a/test/ios/RootBrowser/ThumbnailView.h b/test/ios/RootBrowser/ThumbnailView.h deleted file mode 100644 index 6cd44bac22c82..0000000000000 --- a/test/ios/RootBrowser/ThumbnailView.h +++ /dev/null @@ -1,49 +0,0 @@ -#import <UIKit/UIKit.h> - -@class ThumbnailView; - -@protocol ThumbnailViewDelegate <NSObject> -@required -- (unsigned) numberOfThumbnailsInView : (ThumbnailView *)view; -- (UIView *) thumbnailAtIndex : (unsigned)index; -@optional -- (void) cacheDataForThumbnail : (UIView *)view; -- (void) loadDataForVisibleRange; -@end - -/* - -View with nested scroll-view with thumbnails. -Thumbnails are created by delegate. -Real data for thumbnail is loaded by delegate. -View places these thumbnails in a grid, -durign scrolling thumbnails, which became invisible, -are recycled - used for thumbnails, which became visible. -Thumbnails can contain some generic images, when scroll stopped, -delegate can load real data and create real images. -Delegate can cache images for previously shown thumbnails, -if view scrolls back, such cached images can be used instead -of loading. - -ThumbnailView must be created with initWithFrame method. -Thumbnail's size (width) + addW must be < scroll.width - 2 * addSide. - -This class was inspired by ATArrayView (Andrey Tarantsov, http://tarantsov.com/) -*/ - -@interface ThumbnailView : UIView - -@property (nonatomic, weak) id<ThumbnailViewDelegate> delegate; -@property (nonatomic, assign) CGFloat addSide; -@property (nonatomic, assign) CGFloat addTop; -@property (nonatomic, assign) CGFloat addW; -@property (nonatomic, assign) CGFloat addH; -@property (nonatomic, assign) CGSize itemSize; - -@property (nonatomic, readonly) unsigned firstVisibleThumbnail; -@property (nonatomic, readonly) unsigned lastVisibleThumbnail; - -- (void) loadData; -- (UIView *) getThumbnailFromCache; - -@end diff --git a/test/ios/RootBrowser/ThumbnailView.mm b/test/ios/RootBrowser/ThumbnailView.mm deleted file mode 100644 index dbc18f7fc5d95..0000000000000 --- a/test/ios/RootBrowser/ThumbnailView.mm +++ /dev/null @@ -1,287 +0,0 @@ -#import "ThumbnailView.h" - - -const int preloadRows = 2; - -@interface ThumbnailView () <UIScrollViewDelegate> { - UIScrollView *scroll; - - NSMutableSet *visibleThumbnails; - NSMutableSet *cachedThumbnails; - - //Grid parameters. - unsigned nItems; - unsigned nCols; - unsigned nRows; - - CGFloat addX;//addSide + remaining width. -} - -- (void) calculateGridParameters; -- (void) placeThumbnail : (UIView *)thumbnail; -- (void) placeThumbnails : (BOOL)fixPositions; - -- (CGRect) frameForThumbnailAtIndex : (unsigned)index; -- (UIView *) thumbnailWithTag : (unsigned)tag; -- (void) cacheThumbnail : (UIView *)thumbnail; - -@end - -@implementation ThumbnailView - -@synthesize delegate; -@synthesize addSide; -@synthesize addTop; -@synthesize addW; -@synthesize addH; -@synthesize itemSize; - -#pragma mark - Initialization. - -//____________________________________________________________________________________________________ -- (id) initWithFrame : (CGRect)frame -{ - //View MUST be initialized using this method. - if (self = [super initWithFrame : frame]) { - //Grid. No data load yet. - nItems = 0; - nRows = 0; - nCols = 0; - //Some "default" values for grid's geometry, - //can be modified using properties. - addTop = 50.f; - addSide = 50.f; - addW = 50.f; - addH = 50.f; - itemSize = CGSizeMake(150.f, 150.f); - - visibleThumbnails = [[NSMutableSet alloc] init]; - cachedThumbnails = [[NSMutableSet alloc] init]; - - //Setup nested scrollview. - frame.origin = CGPointZero; - - scroll = [[UIScrollView alloc] initWithFrame : frame]; - scroll.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight | UIViewAutoresizingFlexibleLeftMargin | - UIViewAutoresizingFlexibleRightMargin | UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleBottomMargin; - scroll.contentMode = UIViewContentModeScaleToFill; - scroll.showsVerticalScrollIndicator = YES; - scroll.showsHorizontalScrollIndicator = NO; - scroll.delegate = self; - [self addSubview : scroll]; - } - - return self; -} - -//____________________________________________________________________________________________________ -- (void) loadData -{ - nItems = [delegate numberOfThumbnailsInView : self]; - - for (UIView *v in visibleThumbnails) - [self cacheThumbnail : v]; - - [visibleThumbnails removeAllObjects]; - - if (nItems) { - [self calculateGridParameters]; - [self placeThumbnails : YES]; - } -} - -#pragma mark - Geometry management. - -//____________________________________________________________________________________________________ -- (void) layoutSubviews -{ - if (nItems) { - [self calculateGridParameters]; - [self placeThumbnails : YES]; - } -} - -#pragma mark - Grid's management. - -//____________________________________________________________________________________________________ -- (void) showFirstLast -{ - NSLog(@"first %d last %d", self.firstVisibleThumbnail, self.lastVisibleThumbnail); -} - -//____________________________________________________________________________________________________ -- (void) setItemSize : (CGSize)newItemSize -{ - if (newItemSize.width + addW > scroll.bounds.size.width - 2 * addSide) { - NSLog(@"ThumbnailView -setItemSize, item size is too big"); - exit(1);//Must be an exception. Check this later. - } - - itemSize = newItemSize; -} - -//____________________________________________________________________________________________________ -- (unsigned) firstVisibleThumbnail -{ - const int firstRow = (scroll.bounds.origin.y - addTop) / (itemSize.height + addH) - preloadRows; - if (firstRow < 0) - return 0; - - return firstRow * nCols; -} - -//____________________________________________________________________________________________________ -- (unsigned) lastVisibleThumbnail -{ - //Pre-condition: nItems > 0, nCols > 0. - const int lastRow = (CGRectGetMaxY(scroll.bounds) - addTop) / (itemSize.height + addH) + 1 + preloadRows; - if (lastRow < 0) - return 0; - - if (lastRow * nCols > nItems) - return nItems - 1; - - return lastRow * nCols - 1; -} - -//____________________________________________________________________________________________________ -- (void) calculateGridParameters -{ - //Pre-condition: scroll width must be big enough to - //position at least 1 thumbnail + additional spaces. - const CGSize scrollSize = scroll.bounds.size; - - if (scrollSize.width - addSide * 2 < itemSize.width + addW) { - //I do not know, if Apple's code can somehow set the bounds to - //be so small. - NSLog(@"scroll is to small to place any thumbnail of required size"); - exit(1); - } - - nCols = (scrollSize.width - addSide * 2) / (itemSize.width + addW); - nRows = (nItems + nCols - 1) / nCols; - addX = (scrollSize.width - nCols * (itemSize.width + addW)) / 2; -} - -//____________________________________________________________________________________________________ -- (void) placeThumbnail : (UIView *)thumbnail -{ - thumbnail.frame = [self frameForThumbnailAtIndex : thumbnail.tag]; - [thumbnail setNeedsDisplay]; -} - -//____________________________________________________________________________________________________ -- (void) placeThumbnails : (BOOL) fixPos -{ - scroll.contentSize = CGSizeMake(scroll.frame.size.width, addTop * 2 + (itemSize.height + addH) * nRows - addH); - - const unsigned first = self.firstVisibleThumbnail; - const unsigned last = self.lastVisibleThumbnail; - - for (UIView *thumbnail in visibleThumbnails) { - if (thumbnail.tag < first || thumbnail.tag > last) { - //Thumbnail became invisible, remove it from scroll, - //move it into cache, cache image data. - [self cacheThumbnail : thumbnail]; - } - } - - //Remove now invisible thumbnails. - [visibleThumbnails minusSet : cachedThumbnails]; - - //Position visible thumbnails. - for (unsigned tag = first; tag <= last; ++tag) { - UIView *thumbnail = [self thumbnailWithTag : tag]; - if (!thumbnail) { - thumbnail = [delegate thumbnailAtIndex : tag]; - thumbnail.tag = tag; - [scroll addSubview : thumbnail]; - [visibleThumbnails addObject : thumbnail]; - } else if (!fixPos)//For example, during scroll, no need to update anything. - continue; - - [self placeThumbnail : thumbnail]; - } -} - -//____________________________________________________________________________________________________ -- (CGRect) frameForThumbnailAtIndex : (unsigned)index -{ - const unsigned row = index / nCols; - const unsigned col = index % nCols; - - CGRect frame = CGRectZero; - frame.origin.x = addX + (itemSize.width + addW) * col + 0.5 * addW; - frame.origin.y = addTop + (itemSize.height + addH) * row; - frame.size = itemSize; - - return frame; -} - -#pragma mark - Thumbnails caching. - -//____________________________________________________________________________________________________ -- (UIView *) getThumbnailFromCache -{ - UIView *thumbnail = (UIView *)[cachedThumbnails anyObject]; - if (thumbnail) - [cachedThumbnails removeObject : thumbnail]; - - return thumbnail; -} - -//____________________________________________________________________________________________________ -- (UIView *) thumbnailWithTag : (unsigned)tag -{ - for (UIView * view in visibleThumbnails) { - if (view.tag == tag) - return view; - } - - return nil; -} - -//____________________________________________________________________________________________________ -- (void) cacheThumbnail : (UIView *)thumbnail -{ - [cachedThumbnails addObject : thumbnail]; - - if ([delegate respondsToSelector : @selector(cacheDataForThumbnail:)]) - [delegate cacheDataForThumbnail : thumbnail];//Save icon in a cache. - - [thumbnail removeFromSuperview]; -} - -#pragma mark - Scrollview delegate. - -//____________________________________________________________________________________________________ -- (void) loadDataForVisibleRange -{ - if ([delegate respondsToSelector : @selector(loadDataForVisibleRange)]) - [delegate loadDataForVisibleRange]; -} - -//____________________________________________________________________________________________________ -- (void) scrollViewDidScroll : (UIScrollView *)scrollView -{ - [self placeThumbnails : NO]; - [self showFirstLast]; -} - -//____________________________________________________________________________________________________ -- (void) scrollViewDidEndDecelerating:(UIScrollView *)scrollView -{ - //Now, ask delegate to really load objects. - [self loadDataForVisibleRange]; -} - -//____________________________________________________________________________________________________ -- (void) scrollViewDidEndDragging : (UIScrollView *)scrollView willDecelerate : (BOOL)decelerate -{ - if (!decelerate) { - //Load objects. - [self loadDataForVisibleRange]; - } -} - -@end diff --git a/test/ios/RootBrowser/UI/Browser/Browser_iPad.storyboard b/test/ios/RootBrowser/UI/Browser/Browser_iPad.storyboard new file mode 100644 index 0000000000000..2262726e19704 --- /dev/null +++ b/test/ios/RootBrowser/UI/Browser/Browser_iPad.storyboard @@ -0,0 +1,230 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="4514" systemVersion="13A598" targetRuntime="iOS.CocoaTouch.iPad" propertyAccessControl="none" useAutolayout="YES" initialViewController="D3a-KN-BfX"> + <dependencies> + <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="3747"/> + </dependencies> + <scenes> + <!--Navigation Controller--> + <scene sceneID="Ksh-qd-IUf"> + <objects> + <navigationController storyboardIdentifier="ROOTBrowserViewControllerID" definesPresentationContext="YES" id="D3a-KN-BfX" sceneMemberID="viewController"> + <extendedEdge key="edgesForExtendedLayout" bottom="YES"/> + <simulatedNavigationBarMetrics key="simulatedTopBarMetrics" barStyle="black" translucent="NO" prompted="NO"/> + <navigationBar key="navigationBar" contentMode="scaleToFill" barStyle="black" translucent="NO" id="cb2-5A-hfW"> + <rect key="frame" x="0.0" y="0.0" width="0.0" height="44"/> + <autoresizingMask key="autoresizingMask"/> + </navigationBar> + <connections> + <segue destination="dqz-jH-zJZ" kind="relationship" relationship="rootViewController" id="W0R-cI-hHV"/> + </connections> + </navigationController> + <placeholder placeholderIdentifier="IBFirstResponder" id="dvm-Us-BIV" userLabel="First Responder" sceneMemberID="firstResponder"/> + </objects> + <point key="canvasLocation" x="73" y="69"/> + </scene> + <!--File Collection View Controller--> + <scene sceneID="GWb-Xy-erb"> + <objects> + <viewController id="dqz-jH-zJZ" customClass="FileCollectionViewController" sceneMemberID="viewController"> + <layoutGuides> + <viewControllerLayoutGuide type="top" id="bK7-hq-q0B"/> + <viewControllerLayoutGuide type="bottom" id="Gb7-C5-cRz"/> + </layoutGuides> + <view key="view" contentMode="scaleToFill" id="1kY-e5-3bZ"> + <rect key="frame" x="0.0" y="64" width="768" height="960"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <subviews> + <view hidden="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Wbb-F6-9Wc"> + <rect key="frame" x="0.0" y="0.0" width="768" height="146"/> + <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> + <subviews> + <label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Enter the file name:" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="7bq-85-g5B"> + <rect key="frame" x="253" y="22" width="262" height="21"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <constraints> + <constraint firstAttribute="width" constant="262" id="mTf-xL-9Rf"/> + </constraints> + <fontDescription key="fontDescription" type="system" pointSize="17"/> + <color key="textColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="calibratedRGB"/> + <nil key="highlightedColor"/> + </label> + <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="roundedRect" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="kQR-XR-yFP"> + <rect key="frame" x="43" y="74" width="682" height="30"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <fontDescription key="fontDescription" type="system" pointSize="14"/> + <textInputTraits key="textInputTraits" keyboardType="URL" returnKeyType="go" enablesReturnKeyAutomatically="YES"/> + <connections> + <action selector="textFieldDidEndOnExit:" destination="dqz-jH-zJZ" eventType="editingDidEndOnExit" id="WX1-Mk-WHT"/> + <action selector="textFieldEditingDidEnd:" destination="dqz-jH-zJZ" eventType="editingDidEnd" id="JQE-ss-h1z"/> + </connections> + </textField> + </subviews> + <color key="backgroundColor" white="0.0" alpha="1" colorSpace="calibratedWhite"/> + <constraints> + <constraint firstAttribute="trailing" secondItem="kQR-XR-yFP" secondAttribute="trailing" constant="43" id="Au4-VA-6St"/> + <constraint firstAttribute="height" constant="146" id="HSO-Ge-p63"/> + <constraint firstItem="7bq-85-g5B" firstAttribute="top" secondItem="Wbb-F6-9Wc" secondAttribute="top" constant="22" id="OJc-PJ-Ygm"/> + <constraint firstItem="kQR-XR-yFP" firstAttribute="top" secondItem="Wbb-F6-9Wc" secondAttribute="top" constant="74" id="YGC-Dc-nVU"/> + <constraint firstItem="7bq-85-g5B" firstAttribute="centerX" secondItem="Wbb-F6-9Wc" secondAttribute="centerX" id="ii6-cx-4CO"/> + <constraint firstItem="kQR-XR-yFP" firstAttribute="leading" secondItem="Wbb-F6-9Wc" secondAttribute="leading" constant="43" id="sD4-h9-wag"/> + <constraint firstAttribute="bottom" secondItem="kQR-XR-yFP" secondAttribute="bottom" constant="42" id="vBw-Ej-tyG"/> + </constraints> + </view> + <scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" showsHorizontalScrollIndicator="NO" translatesAutoresizingMaskIntoConstraints="NO" id="VQe-h5-t1L"> + <rect key="frame" x="-1" y="0.0" width="768" height="960"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/> + <color key="backgroundColor" white="0.66666666666666663" alpha="1" colorSpace="calibratedWhite"/> + </scrollView> + </subviews> + <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/> + <constraints> + <constraint firstItem="Wbb-F6-9Wc" firstAttribute="leading" secondItem="1kY-e5-3bZ" secondAttribute="leading" id="0qu-o6-73X"/> + <constraint firstAttribute="trailing" secondItem="VQe-h5-t1L" secondAttribute="trailing" constant="1" id="ILB-do-5Yv"/> + <constraint firstAttribute="trailing" secondItem="Wbb-F6-9Wc" secondAttribute="trailing" id="IXU-ZN-3g7"/> + <constraint firstItem="VQe-h5-t1L" firstAttribute="top" secondItem="1kY-e5-3bZ" secondAttribute="top" id="JFJ-c1-UXo"/> + <constraint firstItem="VQe-h5-t1L" firstAttribute="leading" secondItem="1kY-e5-3bZ" secondAttribute="leading" constant="-1" id="Jj0-8I-wyn"/> + <constraint firstAttribute="bottom" secondItem="VQe-h5-t1L" secondAttribute="bottom" id="hjP-hV-AeU"/> + <constraint firstItem="Wbb-F6-9Wc" firstAttribute="top" secondItem="1kY-e5-3bZ" secondAttribute="top" id="kWo-yK-0pj"/> + </constraints> + </view> + <extendedEdge key="edgesForExtendedLayout" bottom="YES"/> + <navigationItem key="navigationItem" id="LDB-bR-MXC"/> + <connections> + <outlet property="fileNameField" destination="kQR-XR-yFP" id="9xS-0o-Iox"/> + <outlet property="fileOpenView" destination="Wbb-F6-9Wc" id="gFo-ZO-ve6"/> + <outlet property="scrollView" destination="VQe-h5-t1L" id="Sby-eC-aOv"/> + </connections> + </viewController> + <placeholder placeholderIdentifier="IBFirstResponder" id="DUY-qO-KGi" userLabel="First Responder" sceneMemberID="firstResponder"/> + </objects> + <point key="canvasLocation" x="1015" y="69"/> + </scene> + <!--Slideshow View Controller--> + <scene sceneID="S8h-ph-5Rl"> + <objects> + <viewController storyboardIdentifier="SlideshowViewControllerID" id="Xaz-dL-Ftk" customClass="SlideshowViewController" sceneMemberID="viewController"> + <layoutGuides> + <viewControllerLayoutGuide type="top" id="xaV-YV-Rv5"/> + <viewControllerLayoutGuide type="bottom" id="iB5-We-sni"/> + </layoutGuides> + <view key="view" contentMode="scaleToFill" id="F18-J4-uVw"> + <rect key="frame" x="0.0" y="64" width="768" height="960"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <subviews> + <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="QaI-T0-MFv"> + <rect key="frame" x="0.0" y="0.0" width="768" height="960"/> + <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> + <subviews> + <view contentMode="scaleToFill" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="PVs-3Y-1Tg"> + <rect key="frame" x="0.0" y="0.0" width="768" height="960"/> + <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> + <color key="backgroundColor" white="0.66666666666666663" alpha="1" colorSpace="calibratedWhite"/> + </view> + </subviews> + <color key="backgroundColor" white="0.66666666666666663" alpha="1" colorSpace="calibratedWhite"/> + </view> + </subviews> + <color key="backgroundColor" white="0.66666666666666663" alpha="1" colorSpace="calibratedWhite"/> + <constraints> + <constraint firstAttribute="trailing" secondItem="QaI-T0-MFv" secondAttribute="trailing" id="EkC-hg-afg"/> + <constraint firstItem="QaI-T0-MFv" firstAttribute="leading" secondItem="F18-J4-uVw" secondAttribute="leading" id="fYW-X0-4CW"/> + <constraint firstAttribute="bottom" secondItem="QaI-T0-MFv" secondAttribute="bottom" id="lw3-Ca-1F9"/> + <constraint firstItem="QaI-T0-MFv" firstAttribute="top" secondItem="F18-J4-uVw" secondAttribute="top" id="yJ1-Ly-gQY"/> + </constraints> + </view> + <extendedEdge key="edgesForExtendedLayout" bottom="YES"/> + <simulatedNavigationBarMetrics key="simulatedTopBarMetrics" barStyle="black" translucent="NO" prompted="NO"/> + <connections> + <outlet property="padParentView" destination="PVs-3Y-1Tg" id="NbA-y4-hLM"/> + <outlet property="parentView" destination="QaI-T0-MFv" id="jYe-wj-cra"/> + </connections> + </viewController> + <placeholder placeholderIdentifier="IBFirstResponder" id="Vgd-aM-r7p" userLabel="First Responder" sceneMemberID="firstResponder"/> + </objects> + <point key="canvasLocation" x="1914" y="575"/> + </scene> + <!--Object View Controller--> + <scene sceneID="4HE-ht-8z5"> + <objects> + <viewController storyboardIdentifier="ObjectViewControllerID" id="G3D-MN-xnE" customClass="ObjectViewController" sceneMemberID="viewController"> + <layoutGuides> + <viewControllerLayoutGuide type="top" id="Fte-7l-ykP"/> + <viewControllerLayoutGuide type="bottom" id="Ln1-pP-yz2"/> + </layoutGuides> + <view key="view" contentMode="scaleToFill" id="7AV-HU-M2v"> + <rect key="frame" x="0.0" y="64" width="768" height="960"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <subviews> + <scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" pagingEnabled="YES" showsHorizontalScrollIndicator="NO" showsVerticalScrollIndicator="NO" delaysContentTouches="NO" canCancelContentTouches="NO" translatesAutoresizingMaskIntoConstraints="NO" id="GmB-A2-zyh"> + <rect key="frame" x="0.0" y="0.0" width="768" height="960"/> + <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> + <color key="backgroundColor" white="0.66666666666666663" alpha="1" colorSpace="calibratedWhite"/> + </scrollView> + <scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" fixedFrame="YES" bounces="NO" translatesAutoresizingMaskIntoConstraints="NO" id="tdX-Bl-hSf" customClass="PadEditorScrollView"> + <rect key="frame" x="0.0" y="0.0" width="768" height="960"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/> + <color key="backgroundColor" white="0.66666666666666663" alpha="1" colorSpace="calibratedWhite"/> + </scrollView> + </subviews> + <color key="backgroundColor" white="0.66666666666666663" alpha="1" colorSpace="calibratedWhite"/> + <constraints> + <constraint firstItem="GmB-A2-zyh" firstAttribute="top" secondItem="7AV-HU-M2v" secondAttribute="top" id="BOJ-LD-GLr"/> + <constraint firstAttribute="bottom" secondItem="GmB-A2-zyh" secondAttribute="bottom" id="EvP-YY-Her"/> + <constraint firstAttribute="trailing" secondItem="GmB-A2-zyh" secondAttribute="trailing" id="gxE-LT-Bsl"/> + <constraint firstItem="GmB-A2-zyh" firstAttribute="leading" secondItem="7AV-HU-M2v" secondAttribute="leading" id="hjK-ZH-4TC"/> + </constraints> + </view> + <extendedEdge key="edgesForExtendedLayout" bottom="YES"/> + <simulatedNavigationBarMetrics key="simulatedTopBarMetrics" barStyle="black" translucent="NO" prompted="NO"/> + <connections> + <outlet property="navigationScrollView" destination="GmB-A2-zyh" id="J9F-fL-hXm"/> + <outlet property="padScrollView" destination="tdX-Bl-hSf" id="nGI-jB-CAh"/> + </connections> + </viewController> + <placeholder placeholderIdentifier="IBFirstResponder" id="cCl-us-tRS" userLabel="First Responder" sceneMemberID="firstResponder"/> + </objects> + <point key="canvasLocation" x="1908" y="1802"/> + </scene> + <!--File Content View Controller--> + <scene sceneID="RZv-bU-X66"> + <objects> + <viewController storyboardIdentifier="FileContentViewControllerID" id="Njf-pO-o0x" customClass="FileContentViewController" sceneMemberID="viewController"> + <layoutGuides> + <viewControllerLayoutGuide type="top" id="RFt-Vy-am8"/> + <viewControllerLayoutGuide type="bottom" id="ob3-F0-rfy"/> + </layoutGuides> + <view key="view" contentMode="scaleToFill" id="hq3-JD-UzQ"> + <rect key="frame" x="0.0" y="64" width="768" height="960"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <subviews> + <scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="HmI-Cn-O1u"> + <rect key="frame" x="0.0" y="0.0" width="768" height="960"/> + <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> + <color key="backgroundColor" white="0.66666666666666663" alpha="1" colorSpace="calibratedWhite"/> + </scrollView> + </subviews> + <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/> + <constraints> + <constraint firstItem="HmI-Cn-O1u" firstAttribute="top" secondItem="hq3-JD-UzQ" secondAttribute="top" id="8XF-yV-I57"/> + <constraint firstAttribute="bottom" secondItem="HmI-Cn-O1u" secondAttribute="bottom" id="HDc-Ez-nMz"/> + <constraint firstAttribute="trailing" secondItem="HmI-Cn-O1u" secondAttribute="trailing" id="mru-DY-Ope"/> + <constraint firstItem="HmI-Cn-O1u" firstAttribute="leading" secondItem="hq3-JD-UzQ" secondAttribute="leading" id="ngp-qi-2QU"/> + </constraints> + </view> + <extendedEdge key="edgesForExtendedLayout" bottom="YES"/> + <simulatedNavigationBarMetrics key="simulatedTopBarMetrics" barStyle="black" translucent="NO" prompted="NO"/> + <connections> + <outlet property="scrollView" destination="HmI-Cn-O1u" id="Sky-a8-6Ty"/> + </connections> + </viewController> + <placeholder placeholderIdentifier="IBFirstResponder" id="6Yy-Nm-GSY" userLabel="First Responder" sceneMemberID="firstResponder"/> + </objects> + <point key="canvasLocation" x="1838" y="-580"/> + </scene> + </scenes> + <simulatedMetricsContainer key="defaultSimulatedMetrics"> + <simulatedStatusBarMetrics key="statusBar" statusBarStyle="lightContent"/> + <simulatedOrientationMetrics key="orientation"/> + <simulatedScreenMetrics key="destination"/> + </simulatedMetricsContainer> +</document> \ No newline at end of file diff --git a/test/ios/RootBrowser/root_browser/en.lproj/MainWindow.xib b/test/ios/RootBrowser/UI/Core/MainWindow.xib similarity index 100% rename from test/ios/RootBrowser/root_browser/en.lproj/MainWindow.xib rename to test/ios/RootBrowser/UI/Core/MainWindow.xib diff --git a/test/ios/RootBrowser/AxisFontInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/AxisFontInspector.xib similarity index 100% rename from test/ios/RootBrowser/AxisFontInspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/AxisFontInspector.xib diff --git a/test/ios/RootBrowser/UI/ObjectInspector/AxisInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/AxisInspector.xib new file mode 100644 index 0000000000000..b7fb29d5e88aa --- /dev/null +++ b/test/ios/RootBrowser/UI/ObjectInspector/AxisInspector.xib @@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<document type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="3.0" toolsVersion="4514" systemVersion="13A598" targetRuntime="iOS.CocoaTouch.iPad" propertyAccessControl="none"> + <dependencies> + <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="3747"/> + </dependencies> + <objects> + <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="AxisInspector"> + <connections> + <outlet property="tabBar" destination="14" id="18"/> + <outlet property="view" destination="4" id="7"/> + </connections> + </placeholder> + <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/> + <view contentMode="scaleToFill" id="4"> + <rect key="frame" x="0.0" y="0.0" width="250" height="400"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <subviews> + <tabBar alpha="0.80000001192092896" contentMode="scaleToFill" id="14"> + <rect key="frame" x="0.0" y="0.0" width="250" height="49"/> + <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMinY="YES"/> + <color key="backgroundColor" cocoaTouchSystemColor="scrollViewTexturedBackgroundColor"/> + <items> + <tabBarItem tag="1" title="Ticks" image="ticks_tab.png" id="15"/> + <tabBarItem tag="2" title="Title" image="title_tab.png" id="16"/> + <tabBarItem tag="3" title="Labels" image="label_tab.png" id="17"/> + </items> + <connections> + <outlet property="delegate" destination="-1" id="19"/> + </connections> + </tabBar> + </subviews> + <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/> + </view> + </objects> + <resources> + <image name="label_tab.png" width="30" height="30"/> + <image name="ticks_tab.png" width="30" height="30"/> + <image name="title_tab.png" width="30" height="30"/> + </resources> +</document> \ No newline at end of file diff --git a/test/ios/RootBrowser/AxisLabelsInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/AxisLabelsInspector.xib similarity index 100% rename from test/ios/RootBrowser/AxisLabelsInspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/AxisLabelsInspector.xib diff --git a/test/ios/RootBrowser/AxisTicksInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/AxisTicksInspector.xib similarity index 100% rename from test/ios/RootBrowser/AxisTicksInspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/AxisTicksInspector.xib diff --git a/test/ios/RootBrowser/AxisTitleInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/AxisTitleInspector.xib similarity index 100% rename from test/ios/RootBrowser/AxisTitleInspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/AxisTitleInspector.xib diff --git a/test/ios/RootBrowser/FilledAreaInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/FilledAreaInspector.xib similarity index 100% rename from test/ios/RootBrowser/FilledAreaInspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/FilledAreaInspector.xib diff --git a/test/ios/RootBrowser/H1BinsInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/H1BinsInspector.xib similarity index 100% rename from test/ios/RootBrowser/H1BinsInspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/H1BinsInspector.xib diff --git a/test/ios/RootBrowser/H1ErrorsInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/H1ErrorsInspector.xib similarity index 100% rename from test/ios/RootBrowser/H1ErrorsInspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/H1ErrorsInspector.xib diff --git a/test/ios/RootBrowser/H1Inspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/H1Inspector.xib similarity index 100% rename from test/ios/RootBrowser/H1Inspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/H1Inspector.xib diff --git a/test/ios/RootBrowser/LineInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/LineInspector.xib similarity index 100% rename from test/ios/RootBrowser/LineInspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/LineInspector.xib diff --git a/test/ios/RootBrowser/MarkerInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/MarkerInspector.xib similarity index 100% rename from test/ios/RootBrowser/MarkerInspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/MarkerInspector.xib diff --git a/test/ios/RootBrowser/PadInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/PadInspector.xib similarity index 100% rename from test/ios/RootBrowser/PadInspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/PadInspector.xib diff --git a/test/ios/RootBrowser/PadLogScaleInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/PadLogScaleInspector.xib similarity index 100% rename from test/ios/RootBrowser/PadLogScaleInspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/PadLogScaleInspector.xib diff --git a/test/ios/RootBrowser/PadTicksGridInspector.xib b/test/ios/RootBrowser/UI/ObjectInspector/PadTicksGridInspector.xib similarity index 100% rename from test/ios/RootBrowser/PadTicksGridInspector.xib rename to test/ios/RootBrowser/UI/ObjectInspector/PadTicksGridInspector.xib diff --git a/test/ios/RootBrowser/root_browser/root_browser-Info.plist b/test/ios/RootBrowser/root_browser/root_browser-Info.plist index 192990744f9cd..e11d768874080 100644 --- a/test/ios/RootBrowser/root_browser/root_browser-Info.plist +++ b/test/ios/RootBrowser/root_browser/root_browser-Info.plist @@ -6,12 +6,29 @@ <string>en</string> <key>CFBundleDisplayName</key> <string>${PRODUCT_NAME}</string> + <key>CFBundleDocumentTypes</key> + <array> + <dict> + <key>CFBundleTypeIconFiles</key> + <array/> + <key>CFBundleTypeName</key> + <string>ROOT</string> + <key>CFBundleTypeRole</key> + <string>Viewer</string> + <key>LSHandlerRank</key> + <string>Owner</string> + <key>LSItemContentTypes</key> + <array> + <string>ch.cern.root</string> + </array> + </dict> + </array> <key>CFBundleExecutable</key> <string>${EXECUTABLE_NAME}</string> <key>CFBundleIconFile</key> <string>app_icon.png</string> <key>CFBundleIdentifier</key> - <string>ROOT.${PRODUCT_NAME:rfc1034identifier}</string> + <string>ch.cern.ROOT.RootBrowser</string> <key>CFBundleInfoDictionaryVersion</key> <string>6.0</string> <key>CFBundleName</key> @@ -37,21 +54,6 @@ <string>UIInterfaceOrientationLandscapeLeft</string> <string>UIInterfaceOrientationLandscapeRight</string> </array> - <key>CFBundleDocumentTypes</key> - <array> - <dict> - <key>CFBundleTypeName</key> - <string>Root</string> - <key>LSHandlerRank</key> - <string>Owner</string> - <key>CFBundleTypeRole</key> - <string>Viewer</string> - <key>LSItemContentTypes</key> - <array> - <string>ch.cern.root</string> - </array> - </dict> - </array> <key>UTExportedTypeDeclarations</key> <array> <dict> diff --git a/test/ios/Tutorials/DemoHelper.cxx b/test/ios/Tutorials/DemoHelper.cxx index e112234f7f4cd..17d6d8e8653d2 100644 --- a/test/ios/Tutorials/DemoHelper.cxx +++ b/test/ios/Tutorials/DemoHelper.cxx @@ -16,12 +16,12 @@ namespace Demos { bool CreateTutorials(DemoBase **demos, const char *filePath) { try { - std::auto_ptr<HsimpleDemo> demo0(new HsimpleDemo); - std::auto_ptr<SurfaceDemo> demo1(new SurfaceDemo); - std::auto_ptr<PolarGraphDemo> demo2(new PolarGraphDemo); - std::auto_ptr<LegoDemo> demo3(new LegoDemo); - std::auto_ptr<ExclusionGraphDemo> demo4(new ExclusionGraphDemo); - std::auto_ptr<H2PolyDemo> demo5(new H2PolyDemo(filePath)); + std::unique_ptr<HsimpleDemo> demo0(new HsimpleDemo); + std::unique_ptr<SurfaceDemo> demo1(new SurfaceDemo); + std::unique_ptr<PolarGraphDemo> demo2(new PolarGraphDemo); + std::unique_ptr<LegoDemo> demo3(new LegoDemo); + std::unique_ptr<ExclusionGraphDemo> demo4(new ExclusionGraphDemo); + std::unique_ptr<H2PolyDemo> demo5(new H2PolyDemo(filePath)); demos[0] = demo0.release(); demos[1] = demo1.release(); diff --git a/test/ios/Tutorials/ExclusionGraphDemo.cxx b/test/ios/Tutorials/ExclusionGraphDemo.cxx index 3a0cedafec099..6d51097bc110a 100644 --- a/test/ios/Tutorials/ExclusionGraphDemo.cxx +++ b/test/ios/Tutorials/ExclusionGraphDemo.cxx @@ -27,36 +27,35 @@ ExclusionGraphDemo::ExclusionGraphDemo() y3[i] = 10 * TMath::Sin(x1[i]) - 2; } - std::auto_ptr<TGraph> graph1(new TGraph(kNPoints, x1, y1)); + std::unique_ptr<TGraph> graph1(new TGraph(kNPoints, x1, y1)); graph1->SetLineColor(2); graph1->SetLineWidth(1504); graph1->SetFillStyle(3005); - std::auto_ptr<TGraph> graph2(new TGraph(kNPoints, x2, y2)); + std::unique_ptr<TGraph> graph2(new TGraph(kNPoints, x2, y2)); graph2->SetLineColor(4); graph2->SetLineWidth(-2002); graph2->SetFillStyle(3004); graph2->SetFillColor(9); - std::auto_ptr<TGraph> graph3(new TGraph(kNPoints, x3, y3)); + std::unique_ptr<TGraph> graph3(new TGraph(kNPoints, x3, y3)); graph3->SetLineColor(5); graph3->SetLineWidth(-802); graph3->SetFillStyle(3002); graph3->SetFillColor(2); fMultiGraph->Add(graph1.get()); - fMultiGraph->Add(graph2.get()); - fMultiGraph->Add(graph3.get()); - graph1.release(); + fMultiGraph->Add(graph2.get()); graph2.release(); + fMultiGraph->Add(graph3.get()); graph3.release(); } //______________________________________________________________________________ ExclusionGraphDemo::~ExclusionGraphDemo() { - //Just for auto_ptr's dtor. + //Just for unique_ptr's dtor. } //______________________________________________________________________________ diff --git a/test/ios/Tutorials/ExclusionGraphDemo.h b/test/ios/Tutorials/ExclusionGraphDemo.h index adaa6a5288552..84fd593e15cef 100644 --- a/test/ios/Tutorials/ExclusionGraphDemo.h +++ b/test/ios/Tutorials/ExclusionGraphDemo.h @@ -22,13 +22,13 @@ class ExclusionGraphDemo : public DemoBase { //overriders. void ResetDemo() {} - bool IsAnimated()const {return false;} - unsigned NumOfFrames()const {return 1;} - double AnimationTime()const {return 0.;} + bool IsAnimated() const {return false;} + unsigned NumOfFrames() const {return 1;} + double AnimationTime() const {return 0.;} - void StartAnimation(){} - void NextStep(){} - void StopAnimation(){} + void StartAnimation() {} + void NextStep() {} + void StopAnimation() {} void AdjustPad(Pad *); @@ -36,10 +36,10 @@ class ExclusionGraphDemo : public DemoBase { bool Supports3DRotation() const {return false;} private: - std::auto_ptr<TMultiGraph> fMultiGraph; + std::unique_ptr<TMultiGraph> fMultiGraph; - ExclusionGraphDemo(const ExclusionGraphDemo &rhs); - ExclusionGraphDemo &operator = (const ExclusionGraphDemo &rhs); + ExclusionGraphDemo(const ExclusionGraphDemo &rhs) = delete; + ExclusionGraphDemo &operator = (const ExclusionGraphDemo &rhs) = delete; }; } diff --git a/test/ios/Tutorials/H2PolyDemo.cxx b/test/ios/Tutorials/H2PolyDemo.cxx index ab38de7abce28..573500a9ace6d 100644 --- a/test/ios/Tutorials/H2PolyDemo.cxx +++ b/test/ios/Tutorials/H2PolyDemo.cxx @@ -13,7 +13,7 @@ namespace Demos { //______________________________________________________________________________ H2PolyDemo::H2PolyDemo(const char *fileName) { - std::auto_ptr<TFile> inputFile(TFile::Open(fileName, "read")); + std::unique_ptr<TFile> inputFile(TFile::Open(fileName, "read")); if (!inputFile.get()) return; @@ -25,7 +25,7 @@ H2PolyDemo::H2PolyDemo(const char *fileName) //______________________________________________________________________________ H2PolyDemo::~H2PolyDemo() { - //For auto_ptr's dtor only. + //For unique_ptr's dtor only. } //______________________________________________________________________________ diff --git a/test/ios/Tutorials/H2PolyDemo.h b/test/ios/Tutorials/H2PolyDemo.h index 75acb328357ad..0e8cb77a954c3 100644 --- a/test/ios/Tutorials/H2PolyDemo.h +++ b/test/ios/Tutorials/H2PolyDemo.h @@ -18,13 +18,13 @@ class H2PolyDemo : public DemoBase { //overriders. void ResetDemo() {} - bool IsAnimated()const {return false;} - unsigned NumOfFrames()const {return 1;} - double AnimationTime()const {return 0.;} + bool IsAnimated() const {return false;} + unsigned NumOfFrames() const {return 1;} + double AnimationTime() const {return 0.;} - void StartAnimation(){} - void NextStep(){} - void StopAnimation(){} + void StartAnimation() {} + void NextStep() {} + void StopAnimation() {} void AdjustPad(Pad * /*pad*/) {} @@ -32,10 +32,10 @@ class H2PolyDemo : public DemoBase { bool Supports3DRotation() const {return false;} private: - std::auto_ptr<TH2Poly> fPoly; + std::unique_ptr<TH2Poly> fPoly; - H2PolyDemo(const H2PolyDemo &rhs); - H2PolyDemo &operator = (const H2PolyDemo &rhs); + H2PolyDemo(const H2PolyDemo &rhs) = delete; + H2PolyDemo &operator = (const H2PolyDemo &rhs) = delete; }; } diff --git a/test/ios/Tutorials/HintView.h b/test/ios/Tutorials/HintView.h index 6cce7b032a402..3be1b46faac6c 100644 --- a/test/ios/Tutorials/HintView.h +++ b/test/ios/Tutorials/HintView.h @@ -3,5 +3,8 @@ //View which contains hint's pictogram and textual description. @interface HintView : UIView + - (void) setHintIcon : (NSString*) iconName hintText : (NSString*)text; +- (void) handleTap : (UITapGestureRecognizer *) tap; + @end diff --git a/test/ios/Tutorials/HintView.mm b/test/ios/Tutorials/HintView.mm index d79c5ba4422b0..bab8b5549ff86 100644 --- a/test/ios/Tutorials/HintView.mm +++ b/test/ios/Tutorials/HintView.mm @@ -35,18 +35,24 @@ - (void) drawRect : (CGRect)rect CGContextFillRect(ctx, rect); - //Draw the hint's text. - CGContextSetRGBFillColor(ctx, 1.f, 1.f, 1.f, 1.f); - [hintText drawInRect:CGRectMake(0.f, 350.f, rect.size.width, rect.size.height) withFont:[UIFont systemFontOfSize:32] lineBreakMode:UILineBreakModeWordWrap alignment:UITextAlignmentCenter]; + const CGRect textRect = CGRectMake(0.f, 350.f, rect.size.width, rect.size.height); + UIFont * const font = [UIFont systemFontOfSize : 32.f]; + NSMutableParagraphStyle * const paragraphStyle = [[NSParagraphStyle defaultParagraphStyle] mutableCopy]; + paragraphStyle.lineBreakMode = NSLineBreakByWordWrapping; + paragraphStyle.alignment = NSTextAlignmentCenter; + NSDictionary * const attributes = @{NSFontAttributeName : font, NSParagraphStyleAttributeName : paragraphStyle, + NSForegroundColorAttributeName : [UIColor whiteColor]}; + + [hintText drawInRect : textRect withAttributes : attributes]; const CGPoint iconPlace = CGPointMake(rect.size.width / 2.f - 40.f, rect.size.height / 2.f - 40.f); CGContextSetRGBFillColor(ctx, 1.f, 1.f, 1.f, 1.f); CGContextFillRect(ctx, CGRectMake(iconPlace.x, iconPlace.y, 80.f, 80.f)); - [iconImage drawAtPoint:iconPlace]; + [iconImage drawAtPoint : iconPlace]; } //_________________________________________________________________ -- (void) handleTap : (UITapGestureRecognizer *)tap +- (void) handleTap : (UITapGestureRecognizer *) tap { self.hidden = YES; } diff --git a/test/ios/Tutorials/HsimpleDemo.cxx b/test/ios/Tutorials/HsimpleDemo.cxx index 9b13bf68785bb..8af6e7bf6af2b 100644 --- a/test/ios/Tutorials/HsimpleDemo.cxx +++ b/test/ios/Tutorials/HsimpleDemo.cxx @@ -25,7 +25,7 @@ HsimpleDemo::HsimpleDemo() //______________________________________________________________________________ HsimpleDemo::~HsimpleDemo() { - //For auto-ptr dtor only. + //For unique_ptr dtor only. } //______________________________________________________________________________ diff --git a/test/ios/Tutorials/HsimpleDemo.h b/test/ios/Tutorials/HsimpleDemo.h index 5875bbf345d4d..8fa1acdf67888 100644 --- a/test/ios/Tutorials/HsimpleDemo.h +++ b/test/ios/Tutorials/HsimpleDemo.h @@ -18,7 +18,7 @@ class HsimpleDemo : public DemoBase { //Overriders. void ResetDemo(); - bool IsAnimated()const; + bool IsAnimated() const; unsigned NumOfFrames() const; double AnimationTime() const; @@ -34,10 +34,10 @@ class HsimpleDemo : public DemoBase { bool Supports3DRotation() const {return false;} private: - std::auto_ptr<TH1F> fHist; + std::unique_ptr<TH1F> fHist; - HsimpleDemo(const HsimpleDemo &rhs); - HsimpleDemo &operator = (const HsimpleDemo &rhs); + HsimpleDemo(const HsimpleDemo &rhs) = delete; + HsimpleDemo &operator = (const HsimpleDemo &rhs) = delete; }; } diff --git a/test/ios/Tutorials/LegoDemo.cxx b/test/ios/Tutorials/LegoDemo.cxx index 65375458e682a..a2e8e1a50e018 100644 --- a/test/ios/Tutorials/LegoDemo.cxx +++ b/test/ios/Tutorials/LegoDemo.cxx @@ -19,7 +19,7 @@ LegoDemo::LegoDemo() //______________________________________________________________________________ LegoDemo::~LegoDemo() { - //Just for std::auto_ptr's dtor. + //Just for unique_ptr's dtor. } //______________________________________________________________________________ diff --git a/test/ios/Tutorials/LegoDemo.h b/test/ios/Tutorials/LegoDemo.h index 20db96b359c4d..4f009a7d0f5fb 100644 --- a/test/ios/Tutorials/LegoDemo.h +++ b/test/ios/Tutorials/LegoDemo.h @@ -18,13 +18,13 @@ class LegoDemo : public DemoBase { //overriders. void ResetDemo() {} - bool IsAnimated()const {return false;} - unsigned NumOfFrames()const {return 1;} - double AnimationTime()const {return 0.;} + bool IsAnimated() const {return false;} + unsigned NumOfFrames() const {return 1;} + double AnimationTime() const {return 0.;} - void StartAnimation(){} - void NextStep(){} - void StopAnimation(){} + void StartAnimation() {} + void NextStep() {} + void StopAnimation() {} void AdjustPad(Pad *pad); @@ -32,10 +32,10 @@ class LegoDemo : public DemoBase { bool Supports3DRotation() const {return true;} private: - std::auto_ptr<TF2> fLego; + std::unique_ptr<TF2> fLego; - LegoDemo(const LegoDemo &rhs); - LegoDemo &operator = (const LegoDemo &rhs); + LegoDemo(const LegoDemo &rhs) = delete; + LegoDemo &operator = (const LegoDemo &rhs) = delete; }; diff --git a/test/ios/Tutorials/PadOptionsController.h b/test/ios/Tutorials/PadOptionsController.h index dfaec6c358746..0882570ecbe99 100644 --- a/test/ios/Tutorials/PadOptionsController.h +++ b/test/ios/Tutorials/PadOptionsController.h @@ -12,26 +12,8 @@ class Pad; } -@interface PadOptionsController : UIViewController { - __weak IBOutlet UISwitch *tickX_; - __weak IBOutlet UISwitch *tickY_; - - __weak IBOutlet UISwitch *gridX_; - __weak IBOutlet UISwitch *gridY_; - - __weak IBOutlet UISwitch *logX_; - __weak IBOutlet UISwitch *logY_; - __weak IBOutlet UISwitch *logZ_; - - __weak IBOutlet UIPickerView *colorPicker_; - __weak IBOutlet UIPickerView *patternPicker_; -} +@interface PadOptionsController : UIViewController - (void) setView : (PadView *) view andPad : (ROOT::iOS::Pad *) pad; - -- (IBAction) tickActivated : (id) control; -- (IBAction) gridActivated : (id) control; -- (IBAction) logActivated : (id) control; - @end diff --git a/test/ios/Tutorials/PadOptionsController.mm b/test/ios/Tutorials/PadOptionsController.mm index ca3b374559bae..60d2a01c2878c 100644 --- a/test/ios/Tutorials/PadOptionsController.mm +++ b/test/ios/Tutorials/PadOptionsController.mm @@ -1,13 +1,19 @@ +#import <cassert> + #import "PadOptionsController.h" #import "PatternCell.h" -#import "ColorCell.h" #import "PadView.h" //C++ code (ROOT) #import "IOSFillPatterns.h" #import "IOSPad.h" -const double predefinedFillColors[16][3] = { +const CGFloat defaultCellWidth = 80.f; +const CGFloat defaultCellHeight = 44.f; +const CGRect defaultCellFrame = CGRectMake(0.f, 0.f, defaultCellWidth, defaultCellHeight); + +const NSInteger nPredefinedColors = 16; +const CGFloat predefinedFillColors[nPredefinedColors][3] = { {1., 1., 1.}, {0., 0., 0.}, {251 / 255., 0., 24 / 255.}, @@ -36,75 +42,33 @@ @implementation PadOptionsController { - NSMutableArray *colors_; - NSMutableArray *patterns_; - - ROOT::iOS::Pad *pad; - PadView *padView; -} + //UI: + __weak IBOutlet UISwitch *tickX_; + __weak IBOutlet UISwitch *tickY_; -//_________________________________________________________________ -- (id) initWithNibName : (NSString *)nibNameOrNil bundle : (NSBundle *)nibBundleOrNil -{ - self = [super initWithNibName : nibNameOrNil bundle : nibBundleOrNil]; - - if (self) { - //Color views. - colors_ = [[NSMutableArray alloc] init]; - for (unsigned i = 0; i < 16; ++i) { - ColorCell *newCell = [[ColorCell alloc] initWithFrame : CGRectMake(0.f, 0.f, 80.f, 44.f)]; - [newCell setRGB : predefinedFillColors[i]]; - [colors_ addObject : newCell]; - } - - //Patterns. - patterns_ = [[NSMutableArray alloc] init]; - //The first pattern - solid fill. - PatternCell *solidFill = [[PatternCell alloc] initWithFrame : CGRectMake(0.f, 0.f, 80.f, 44.f) andPattern : 0]; - [solidFill setAsSolid]; - [patterns_ addObject : solidFill]; - - for (unsigned i = 0; i < ROOT::iOS::GraphicUtils::kPredefinedFillPatterns; ++i) { - PatternCell *newCell = [[PatternCell alloc] initWithFrame : CGRectMake(0.f, 0.f, 80.f, 44.f) andPattern : i]; - [patterns_ addObject : newCell]; - } + __weak IBOutlet UISwitch *gridX_; + __weak IBOutlet UISwitch *gridY_; - //Pattern views. - } + __weak IBOutlet UISwitch *logX_; + __weak IBOutlet UISwitch *logY_; + __weak IBOutlet UISwitch *logZ_; - return self; -} + __weak IBOutlet UIPickerView *colorPicker_; + __weak IBOutlet UIPickerView *patternPicker_; -//_________________________________________________________________ -- (void)didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Release any cached data, images, etc that aren't in use. + //Controlled objects: + ROOT::iOS::Pad *pad; + PadView *padView; } #pragma mark - View lifecycle //_________________________________________________________________ -- (void)viewDidLoad -{ - [super viewDidLoad]; - // Do any additional setup after loading the view from its nib. -} - -//_________________________________________________________________ -- (void)viewDidUnload +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - [super viewDidUnload]; - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; -} +#pragma unused(interfaceOrientation) -//_________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation -{ - // Return YES for supported orientations - return YES; + return YES; } #pragma mark - editing. @@ -112,6 +76,9 @@ - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interface //_________________________________________________________________ - (void) setView : (PadView *) view andPad : (ROOT::iOS::Pad *) newPad { + assert(view != nil && "setView:andPad:, parameter 'view' is nil"); + assert(newPad != nullptr && "setView:andPad:, parameter 'newPad' is null"); + padView = view; pad = newPad; @@ -128,12 +95,15 @@ - (void) setView : (PadView *) view andPad : (ROOT::iOS::Pad *) newPad //_________________________________________________________________ - (IBAction) tickActivated : (id) control { - const unsigned on = [control isOn]; - if (control == tickX_) { + assert([control isKindOfClass : [UISwitch class]] && + "tickActivated:, parameter 'control' has a wrong type"); + + const unsigned on = [(UISwitch *)control isOn]; + if (control == tickX_) pad->SetTickx(on); - } else if (control == tickY_) { + else if (control == tickY_) pad->SetTicky(on); - } + //else assert. [padView setNeedsDisplay]; } @@ -141,59 +111,75 @@ - (IBAction) tickActivated : (id) control //_________________________________________________________________ - (IBAction) gridActivated : (id) control { - const unsigned on = [control isOn]; - if (control == gridX_) { + assert([control isKindOfClass : [UISwitch class]] && + "gridActivated:, parameter 'control' has a wrong type"); + + const unsigned on = [(UISwitch *)control isOn]; + if (control == gridX_) pad->SetGridx(on); - } else if (control == gridY_) { + else if (control == gridY_) pad->SetGridy(on); - } - + //else assert. + [padView setNeedsDisplay]; } //_________________________________________________________________ - (IBAction) logActivated : (id) control { - const unsigned on = [control isOn]; - + assert([control isKindOfClass : [UISwitch class]] && + "logActivated:, parameter 'control' has a wrong type"); + + const unsigned on = [(UISwitch *)control isOn]; if (control == logX_) pad->SetLogx(on); - if (control == logY_) pad->SetLogy(on); - if (control == logZ_) pad->SetLogz(on); + + //Else of all ifs must be an assert. + [padView setNeedsDisplay]; } #pragma mark - color/pattern picker dataSource. //_________________________________________________________________ -- (CGFloat)pickerView:(UIPickerView *)pickerView widthForComponent:(NSInteger)component +- (CGFloat) pickerView : (UIPickerView *) pickerView widthForComponent : (NSInteger) component { - return 80.; +#pragma unused(pickerView, component) + + return defaultCellWidth; } //_________________________________________________________________ -- (CGFloat)pickerView:(UIPickerView *)pickerView rowHeightForComponent:(NSInteger)component +- (CGFloat) pickerView : (UIPickerView *) pickerView rowHeightForComponent : (NSInteger) component { - return 44.; +#pragma unused(pickerView, component) + + return defaultCellHeight; } //_________________________________________________________________ -- (NSInteger)pickerView:(UIPickerView *)pickerView numberOfRowsInComponent:(NSInteger)component +- (NSInteger) pickerView : (UIPickerView *) pickerView numberOfRowsInComponent : (NSInteger) component { +#pragma unused(component) + if (pickerView == colorPicker_) - return [colors_ count]; + return nPredefinedColors; else if (pickerView == patternPicker_) - return [patterns_ count]; + return ROOT::iOS::GraphicUtils::kPredefinedFillPatterns + 1;//+ 1 for a 'solid'. + + assert(0 && "pickerView:numberOfRowsInComponent:, parameter 'pickerView' is invalid"); + return 0; } //_________________________________________________________________ -- (NSInteger)numberOfComponentsInPickerView:(UIPickerView *)pickerView +- (NSInteger) numberOfComponentsInPickerView : (UIPickerView *) pickerView { + //We have two pickers, each with exactly one 'wheel'. return 1; } @@ -201,36 +187,70 @@ - (NSInteger)numberOfComponentsInPickerView:(UIPickerView *)pickerView // tell the picker which view to use for a given component and row, we have an array of views to show //_________________________________________________________________ -- (UIView *)pickerView:(UIPickerView *)pickerView viewForRow:(NSInteger)row - forComponent:(NSInteger)component reusingView:(UIView *)view +- (UIView *) pickerView : (UIPickerView *) pickerView viewForRow : (NSInteger) row + forComponent : (NSInteger) component reusingView : (UIView *) view { - if (pickerView == colorPicker_) - return [colors_ objectAtIndex : row]; - else if (pickerView == patternPicker_) - return [patterns_ objectAtIndex : row]; +#pragma unused(component) - return 0; + if (pickerView == colorPicker_) { + assert(row < nPredefinedColors && row >= 0 && + "pickerView:viewForRow:forComponent:reusingView:, row is out of bounds"); + const CGFloat * const rgb = predefinedFillColors[row]; + UIView * newCell = view; + if (!newCell) + newCell = [[UIView alloc] initWithFrame:defaultCellFrame]; + newCell.backgroundColor = [UIColor colorWithRed : rgb[0] green : rgb[1] blue : rgb[2] alpha : 1.f]; + + return newCell; + } else if (pickerView == patternPicker_) { + //Row 0 is a special case - I have to call the setAsSolid method. + assert(row >= 0 && row <= ROOT::iOS::GraphicUtils::kPredefinedFillPatterns && + "pickerView:viewForRow:forCoponent:reusingView:, row is out of bounds");//<= -> +1 for 'solid'. + + if (view && [view isKindOfClass : [PatternCell class]]) { + PatternCell * const reuseCell = (PatternCell *)view; + if (!row) + [reuseCell setAsSolid]; + else + [reuseCell setPattern : row - 1]; + + return reuseCell; + } else { + PatternCell * const newCell = [[PatternCell alloc] initWithFrame : defaultCellFrame andPattern : row ? row - 1 : 0]; + if (!row) + [newCell setAsSolid]; + return newCell; + } + } + + assert(0 && "pickerView:viewForRow:forCoponent:reusingView:, parameter 'pickerView' is invalid"); + + return nil; } //_________________________________________________________________ -- (void)pickerView:(UIPickerView *)thePickerView didSelectRow:(NSInteger)row inComponent:(NSInteger)component { - - if (thePickerView == colorPicker_) { +- (void) pickerView : (UIPickerView *) pickerView didSelectRow : (NSInteger) row inComponent : (NSInteger) component +{ +#pragma unused(component) + + assert(pad != nullptr && "pickerView:didSelectRow:inComponent:, pad is null"); + assert(padView != nil && "pickerView:didSelectRow:inComponent:, padView is nil"); + + if (pickerView == colorPicker_) { if (row >= 0 && row < 16) { pad->SetFillColor(colorIndices[row]); [padView setNeedsDisplay]; } - } else if (thePickerView == patternPicker_) { + } else if (pickerView == patternPicker_) { //<= because of solid fill pattern. if (row > 0 && row <= ROOT::iOS::GraphicUtils::kPredefinedFillPatterns) { - // NSLog(@"%p", pad); pad->SetFillStyle(3000 + row); [padView setNeedsDisplay]; } else if (!row) { pad->SetFillStyle(1001); [padView setNeedsDisplay]; } - } + } //else must be an assert. } @end diff --git a/test/ios/Tutorials/PadView.h b/test/ios/Tutorials/PadView.h index 40cfd715c2286..b3e77c406773a 100644 --- a/test/ios/Tutorials/PadView.h +++ b/test/ios/Tutorials/PadView.h @@ -17,12 +17,15 @@ class Pad; @interface PadView : UIView -- (id) initWithFrame : (CGRect)frame forPad : (ROOT::iOS::Pad*)pad; +- (id) initWithFrame : (CGRect)frame forPad : (ROOT::iOS::Pad*) pad; - (void) clearPad; - (void) setSelectionView : (SelectionView *) sv; -- (void) setProcessPan : (BOOL)p; -- (void) setProcessTap : (BOOL)t; +- (void) setProcessPan : (BOOL) p; +- (void) setProcessTap : (BOOL) t; +- (void) handlePanGesture : (UIPanGestureRecognizer *) panGesture; +- (void) handleTapGesture : (UITapGestureRecognizer *) tapGesture; + @end diff --git a/test/ios/Tutorials/PadView.mm b/test/ios/Tutorials/PadView.mm index 8ad4e43a3585b..a020105662e23 100644 --- a/test/ios/Tutorials/PadView.mm +++ b/test/ios/Tutorials/PadView.mm @@ -1,6 +1,7 @@ -#import <stddef.h> -#import <stdlib.h> -#import <math.h> +#import <cstddef> +#import <vector> +#import <cmath> +#import <new> #import <CoreGraphics/CoreGraphics.h> #import <CoreGraphics/CGContext.h> @@ -21,19 +22,16 @@ @interface PadView () { BOOL processTap; } -- (void) handlePanGesture : (UIPanGestureRecognizer *)panGesture; -- (void) handleTapGesture : (UITapGestureRecognizer *)tapGesture; - @end @implementation PadView //_________________________________________________________________ -- (id) initWithFrame:(CGRect)frame forPad : (ROOT::iOS::Pad*)pd +- (id) initWithFrame : (CGRect) frame forPad : (ROOT::iOS::Pad*) pd { self = [super initWithFrame : frame]; - if (self) { + assert(pd != nullptr && "initWithFrame:forPad:, parameter 'pd' is null"); //Initialize C++ objects here. pad = pd; @@ -44,9 +42,11 @@ - (id) initWithFrame:(CGRect)frame forPad : (ROOT::iOS::Pad*)pd } //_________________________________________________________________ -- (void)drawRect : (CGRect)rect +- (void) drawRect : (CGRect)rect { // Drawing code + assert(pad != nullptr && "drawRect:, pad is null"); + CGContextRef ctx = UIGraphicsGetCurrentContext(); CGContextClearRect(ctx, rect); @@ -64,16 +64,20 @@ - (void)drawRect : (CGRect)rect //_________________________________________________________________ - (void) clearPad { + assert(pad != nullptr && "clearPad, pad is null"); + pad->Clear(); } //_________________________________________________________________ -- (void) handlePanGesture : (UIPanGestureRecognizer *)panGesture +- (void) handlePanGesture : (UIPanGestureRecognizer *) panGesture { if (!processPan) return; - const CGPoint p = [panGesture locationInView:self]; + assert(pad != nullptr && "handlePanGesture:, pad is null"); + + const CGPoint p = [panGesture locationInView : self]; [selectionView setPad : pad]; [selectionView setShowRotation : YES]; @@ -93,8 +97,10 @@ - (void) handlePanGesture : (UIPanGestureRecognizer *)panGesture } //_________________________________________________________________ -- (CGImageRef) initCGImageForPicking +- (UIImage *) createImageForPicking { + assert(pad != nullptr && "initCGImageForPicking, pad is null"); + const CGRect rect = CGRectMake(0.f, 0.f, 640.f, 640.f); //Create bitmap context. UIGraphicsBeginImageContext(rect.size); @@ -114,19 +120,20 @@ - (CGImageRef) initCGImageForPicking pad->SetContext(ctx); pad->PaintForSelection(); - UIImage *uiImageForPicking = UIGraphicsGetImageFromCurrentImageContext();//autoreleased UIImage. - CGImageRef cgImageForPicking = uiImageForPicking.CGImage; - CGImageRetain(cgImageForPicking);//It must live as long, as I need :) - + UIImage * const uiImageForPicking = UIGraphicsGetImageFromCurrentImageContext();//autoreleased UIImage. UIGraphicsEndImageContext(); - return cgImageForPicking; - + return uiImageForPicking; } //_________________________________________________________________ -- (BOOL) fillPickingBufferFromCGImage : (CGImageRef) cgImage +- (BOOL) fillPickingBufferFromImage : (UIImage *) image { + assert(image != nil && "fillPickingBufferFromImage:, parameter 'image' is nil"); + assert(pad != nullptr && "fillPickingBufferFromImage:, pad is null"); + + CGImageRef cgImage = image.CGImage; + const size_t pixelsW = CGImageGetWidth(cgImage); const size_t pixelsH = CGImageGetHeight(cgImage); //Declare the number of bytes per row. Each pixel in the bitmap @@ -141,61 +148,53 @@ - (BOOL) fillPickingBufferFromCGImage : (CGImageRef) cgImage //Log error: color space allocation failed. return NO; } - - unsigned char *buffer = (unsigned char*)malloc(bitmapByteCount); - if (!buffer) { - //Log error: memory allocation failed. + + try { + std::vector<unsigned char> buffer(bitmapByteCount); + CGContextRef ctx = CGBitmapContextCreate(&buffer[0], pixelsW, pixelsH, 8, bitmapBytesPerRow, colorSpace, kCGImageAlphaPremultipliedFirst); CGColorSpaceRelease(colorSpace); - return NO; - } + + if (!ctx) + return NO; - // Create the bitmap context. We want pre-multiplied ARGB, 8-bits - // per component. Regardless of what the source image format is - // (CMYK, Grayscale, and so on) it will be converted over to the format - // specified here by CGBitmapContextCreate. - CGContextRef ctx = CGBitmapContextCreate(buffer, pixelsW, pixelsH, 8, bitmapBytesPerRow, colorSpace, kCGImageAlphaPremultipliedFirst); + const CGRect rect = CGRectMake(0.f, 0.f, pixelsW, pixelsH); + //Draw the image to the bitmap context. Once we draw, the memory + //allocated for the context for rendering will then contain the + //raw image data in the specified color space. + + CGContextSetAllowsAntialiasing(ctx, false);//Check, if I need this for a bitmap. + CGContextDrawImage(ctx, rect, cgImage); - CGColorSpaceRelease(colorSpace); + pad->SetSelectionBuffer(pixelsW, pixelsH, &buffer[0]); + // When finished, release the context + CGContextRelease(ctx); - if (!ctx) { - //Log error: bitmap context creation failed. - free(buffer); - return NO; + return YES; + } catch (const std::bad_alloc &e) { + CGColorSpaceRelease(colorSpace); } - - const CGRect rect = CGRectMake(0.f, 0.f, pixelsW, pixelsH); - //Draw the image to the bitmap context. Once we draw, the memory - //allocated for the context for rendering will then contain the - //raw image data in the specified color space. - - CGContextSetAllowsAntialiasing(ctx, 0);//Check, if I need this for a bitmap. - CGContextDrawImage(ctx, rect, cgImage); - - pad->SetSelectionBuffer(pixelsW, pixelsH, buffer); - // When finished, release the context - CGContextRelease(ctx); - free(buffer); - return YES; + return NO; } //_________________________________________________________________ - (BOOL) initPadPicking { - CGImageRef cgImage = [self initCGImageForPicking]; - if (!cgImage) + UIImage * const pickImage = [self createImageForPicking]; + if (!pickImage) return NO; - - const BOOL res = [self fillPickingBufferFromCGImage : cgImage]; - CGImageRelease(cgImage); - return res; + return [self fillPickingBufferFromImage : pickImage]; } //_________________________________________________________________ - (void) handleTapGesture : (UITapGestureRecognizer *) tapGesture { + assert(tapGesture != nil && "handleTapGesture:, parameter 'tapGesture' is nil"); + if (processTap) { + assert(pad != nullptr && "handleTapGesture:, pad is null"); + const CGPoint tapPt = [tapGesture locationInView : self]; if (!pad->SelectionIsValid() && ![self initPadPicking]) @@ -215,7 +214,7 @@ - (void) handleTapGesture : (UITapGestureRecognizer *) tapGesture } //_________________________________________________________________ -- (void) setSelectionView:(SelectionView *)sv +- (void) setSelectionView : (SelectionView *) sv { selectionView = sv; } diff --git a/test/ios/Tutorials/PatternCell.h b/test/ios/Tutorials/PatternCell.h index 8aac56416b44c..05a0b10bce21e 100644 --- a/test/ios/Tutorials/PatternCell.h +++ b/test/ios/Tutorials/PatternCell.h @@ -4,6 +4,9 @@ @interface PatternCell : UIView - (id) initWithFrame : (CGRect) frame andPattern : (unsigned) index; + +- (void) setPattern : (unsigned) index; - (void) setAsSolid; + @end diff --git a/test/ios/Tutorials/PatternCell.mm b/test/ios/Tutorials/PatternCell.mm index 335d9a9a554db..5a4927656ea81 100644 --- a/test/ios/Tutorials/PatternCell.mm +++ b/test/ios/Tutorials/PatternCell.mm @@ -1,7 +1,6 @@ -#import <CoreGraphics/CGContext.h> +#import <cassert> #import "IOSFillPatterns.h" - #import "PatternCell.h" @implementation PatternCell { @@ -9,10 +8,16 @@ @implementation PatternCell { BOOL solid; } +//Pattern index must be in [0, kPredefinedFillPatterns) range +, probably, +//index is ignored if it's a 'solid' fill pattern. + //______________________________________________________________________________ -- (id)initWithFrame:(CGRect)frame andPattern : (unsigned) index +- (id) initWithFrame : (CGRect) frame andPattern : (unsigned) index { if (self = [super initWithFrame : frame]) { + assert(index < ROOT::iOS::GraphicUtils::kPredefinedFillPatterns && + "initWithFrame:andPattern:, parameter 'index' is out of bounds"); + // Initialization code patternIndex = index; solid = NO; @@ -21,6 +26,16 @@ - (id)initWithFrame:(CGRect)frame andPattern : (unsigned) index return self; } +//______________________________________________________________________________ +- (void) setPattern : (unsigned) index +{ + assert(index < ROOT::iOS::GraphicUtils::kPredefinedFillPatterns && + "setPattern:, parameter 'index' is out of bounds"); + + patternIndex = index; + solid = NO; +} + //______________________________________________________________________________ - (void) setAsSolid { @@ -28,7 +43,7 @@ - (void) setAsSolid } //______________________________________________________________________________ -- (void)drawRect:(CGRect)rect +- (void) drawRect : (CGRect) rect { CGContextRef ctx = UIGraphicsGetCurrentContext(); diff --git a/test/ios/Tutorials/PictView.h b/test/ios/Tutorials/PictView.h index f47e48f774f83..53ff27c9958e5 100644 --- a/test/ios/Tutorials/PictView.h +++ b/test/ios/Tutorials/PictView.h @@ -5,5 +5,7 @@ */ @interface PictView : UIImageView -- (id) initWithFrame : (CGRect)frame andIcon:(NSString *)iconName; + +- (id) initWithFrame : (CGRect) frame andIcon : (NSString *) iconName; + @end diff --git a/test/ios/Tutorials/PictView.m b/test/ios/Tutorials/PictView.mm similarity index 78% rename from test/ios/Tutorials/PictView.m rename to test/ios/Tutorials/PictView.mm index f2e8985af668c..a10cb882db4a4 100644 --- a/test/ios/Tutorials/PictView.m +++ b/test/ios/Tutorials/PictView.mm @@ -1,3 +1,5 @@ +#import <cassert> + #import <QuartzCore/QuartzCore.h> #import "PictView.h" @@ -5,10 +7,10 @@ @implementation PictView //_________________________________________________________________ -- (id) initWithFrame : (CGRect)frame andIcon : (NSString *)iconName +- (id) initWithFrame : (CGRect) frame andIcon : (NSString *) iconName { - //self = [super initWithFrame:frame]; - + assert(iconName != nil && "initWithFrame:andIcon:, parameter 'iconName' is nil"); + self = [super initWithImage : [UIImage imageNamed : iconName]]; if (self) { diff --git a/test/ios/Tutorials/PolarGraphDemo.cxx b/test/ios/Tutorials/PolarGraphDemo.cxx index 59555116f01ec..11da23b2fc118 100644 --- a/test/ios/Tutorials/PolarGraphDemo.cxx +++ b/test/ios/Tutorials/PolarGraphDemo.cxx @@ -59,7 +59,7 @@ PolarGraphDemo::PolarGraphDemo() //______________________________________________________________________________ PolarGraphDemo::~PolarGraphDemo() { - //Just for std::auto_ptr's dtor. + //Just for unique_ptr's dtor. } //______________________________________________________________________________ diff --git a/test/ios/Tutorials/PolarGraphDemo.h b/test/ios/Tutorials/PolarGraphDemo.h index 15b1156c668a9..cae0f38559a93 100644 --- a/test/ios/Tutorials/PolarGraphDemo.h +++ b/test/ios/Tutorials/PolarGraphDemo.h @@ -23,7 +23,7 @@ class PolarGraphDemo : public DemoBase { //overriders. void ResetDemo() {} - bool IsAnimated()const {return false;} + bool IsAnimated() const {return false;} unsigned NumOfFrames() const {return 1;} double AnimationTime() const {return 0.;} @@ -37,11 +37,11 @@ class PolarGraphDemo : public DemoBase { bool Supports3DRotation() const {return false;} private: - std::auto_ptr<TGraphPolar> fPolarAFL; //polar graph with draw option "AFL" - std::auto_ptr<TGraphPolar> fPolarCP; //polar graph with draw option "CP" - - PolarGraphDemo(const PolarGraphDemo &rhs); - PolarGraphDemo &operator = (const PolarGraphDemo &rhs); + std::unique_ptr<TGraphPolar> fPolarAFL; //polar graph with draw option "AFL" + std::unique_ptr<TGraphPolar> fPolarCP; //polar graph with draw option "CP" + + PolarGraphDemo(const PolarGraphDemo &rhs) = delete; + PolarGraphDemo &operator = (const PolarGraphDemo &rhs) = delete; }; } diff --git a/test/ios/Tutorials/SelectionView.mm b/test/ios/Tutorials/SelectionView.mm index f9704f7176b0e..539430e6501c2 100644 --- a/test/ios/Tutorials/SelectionView.mm +++ b/test/ios/Tutorials/SelectionView.mm @@ -10,12 +10,10 @@ @implementation SelectionView { int px; int py; ROOT::iOS::Pad *pad; - - PadView *view; } //______________________________________________________________________________ -- (id)initWithFrame:(CGRect)frame +- (id) initWithFrame : (CGRect) frame { if (self = [super initWithFrame : frame]) { // Initialization code @@ -26,7 +24,7 @@ - (id)initWithFrame:(CGRect)frame } //______________________________________________________________________________ -- (void) setPad : (ROOT::iOS::Pad *)newPad +- (void) setPad : (ROOT::iOS::Pad *) newPad { pad = newPad; } @@ -40,7 +38,7 @@ - (void) setEvent : (int) e atX : (int) x andY : (int) y } //______________________________________________________________________________ -- (void) drawRect:(CGRect)rect +- (void) drawRect : (CGRect) rect { if (!pad) return; @@ -70,8 +68,9 @@ - (void) setShowRotation : (BOOL) show } //______________________________________________________________________________ -- (BOOL)pointInside:(CGPoint)point withEvent:(UIEvent *) event +- (BOOL) pointInside : (CGPoint) point withEvent : (UIEvent *) event { +#pragma unused(point, event) //Thanks to gyim, //http://stackoverflow.com/questions/1694529/allowing-interaction-with-a-uiview-under-another-uiview return NO; diff --git a/test/ios/Tutorials/SurfaceDemo.cxx b/test/ios/Tutorials/SurfaceDemo.cxx index 165de00e6cf1b..1ab7183b33530 100644 --- a/test/ios/Tutorials/SurfaceDemo.cxx +++ b/test/ios/Tutorials/SurfaceDemo.cxx @@ -17,7 +17,7 @@ SurfaceDemo::SurfaceDemo() //______________________________________________________________________________ SurfaceDemo::~SurfaceDemo() { - //For auto_ptr dtor only. + //For unique_ptr's dtor only. } //______________________________________________________________________________ diff --git a/test/ios/Tutorials/SurfaceDemo.h b/test/ios/Tutorials/SurfaceDemo.h index 3bab36285e76d..18d16af2723cd 100644 --- a/test/ios/Tutorials/SurfaceDemo.h +++ b/test/ios/Tutorials/SurfaceDemo.h @@ -32,10 +32,10 @@ class SurfaceDemo : public DemoBase { bool Supports3DRotation() const {return true;} private: - std::auto_ptr<TF2> fSurface; + std::unique_ptr<TF2> fSurface; - SurfaceDemo(const SurfaceDemo &rhs); - SurfaceDemo &operator = (const SurfaceDemo &rhs); + SurfaceDemo(const SurfaceDemo &rhs) = delete; + SurfaceDemo &operator = (const SurfaceDemo &rhs) = delete; }; } diff --git a/test/ios/Tutorials/Tutorials.xcodeproj/ColorCell.h b/test/ios/Tutorials/Tutorials.xcodeproj/ColorCell.h deleted file mode 100644 index 7d5fc0721f1af..0000000000000 --- a/test/ios/Tutorials/Tutorials.xcodeproj/ColorCell.h +++ /dev/null @@ -1,11 +0,0 @@ -#import <UIKit/UIKit.h> - -// -//This is a small and simple custom view, used inside color picker (UIPickerView). -// - -@interface ColorCell : UIView - -- (void) setRGB : (const double *) rgb; - -@end diff --git a/test/ios/Tutorials/Tutorials.xcodeproj/ColorCell.m b/test/ios/Tutorials/Tutorials.xcodeproj/ColorCell.m deleted file mode 100644 index d7d51cfb31be2..0000000000000 --- a/test/ios/Tutorials/Tutorials.xcodeproj/ColorCell.m +++ /dev/null @@ -1,36 +0,0 @@ -#import <CoreGraphics/CoreGraphics.h> - -#import "ColorCell.h" - -@implementation ColorCell { - double rgb[3]; -} - -//______________________________________________________________________________ -- (id) initWithFrame : (CGRect)frame -{ - if (self = [super initWithFrame : frame]) { - // Initialization code - self.backgroundColor = [UIColor clearColor]; - } - - return self; -} - -//______________________________________________________________________________ -- (void) setRGB : (const double *) newRgb -{ - rgb[0] = newRgb[0]; - rgb[1] = newRgb[1]; - rgb[2] = newRgb[2]; -} - -//______________________________________________________________________________ -- (void)drawRect:(CGRect)rect -{ - CGContextRef ctx = UIGraphicsGetCurrentContext(); - CGContextSetRGBFillColor(ctx, (CGFloat)rgb[0], (CGFloat)rgb[1], (CGFloat)rgb[2], 1.f); - CGContextFillRect(ctx, rect); -} - -@end diff --git a/test/ios/Tutorials/Tutorials.xcodeproj/project.pbxproj b/test/ios/Tutorials/Tutorials.xcodeproj/project.pbxproj index 0cec8766b96f4..80e09164d342e 100644 --- a/test/ios/Tutorials/Tutorials.xcodeproj/project.pbxproj +++ b/test/ios/Tutorials/Tutorials.xcodeproj/project.pbxproj @@ -10,7 +10,6 @@ 700542EE13E5B2F40093B598 /* zoom_mode_icon.png in Resources */ = {isa = PBXBuildFile; fileRef = 700542ED13E5B2F40093B598 /* zoom_mode_icon.png */; }; 700B010F13F3D40A00F84650 /* PadOptionsController.mm in Sources */ = {isa = PBXBuildFile; fileRef = 700B010D13F3D40A00F84650 /* PadOptionsController.mm */; }; 700B011013F3D40A00F84650 /* PadOptionsController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 700B010E13F3D40A00F84650 /* PadOptionsController.xib */; }; - 700B013013F3FD6700F84650 /* ColorCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 700B012F13F3FD6600F84650 /* ColorCell.m */; }; 700B013313F4051000F84650 /* PatternCell.mm in Sources */ = {isa = PBXBuildFile; fileRef = 700B013213F4051000F84650 /* PatternCell.mm */; }; 7010C3691455B64100018E6D /* tutorials_app_icon.png in Resources */ = {isa = PBXBuildFile; fileRef = 7010C3681455B64100018E6D /* tutorials_app_icon.png */; }; 701EC32513D9762200FE395E /* SelectionView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 701EC32413D9762200FE395E /* SelectionView.mm */; }; @@ -51,7 +50,7 @@ 70D3FB5213E7F605005BADA3 /* single_tap_icon_small.png in Resources */ = {isa = PBXBuildFile; fileRef = 70D3FB5013E7F605005BADA3 /* single_tap_icon_small.png */; }; 70D3FB5313E7F605005BADA3 /* single_tap_icon.png in Resources */ = {isa = PBXBuildFile; fileRef = 70D3FB5113E7F605005BADA3 /* single_tap_icon.png */; }; 70D4848013F057430043110B /* system.plugins-ios in Resources */ = {isa = PBXBuildFile; fileRef = 70D4847F13F057430043110B /* system.plugins-ios */; }; - 70D645FD13D3243A00CE9FB1 /* PictView.m in Sources */ = {isa = PBXBuildFile; fileRef = 70D645FC13D3243A00CE9FB1 /* PictView.m */; }; + 70D645FD13D3243A00CE9FB1 /* PictView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 70D645FC13D3243A00CE9FB1 /* PictView.mm */; }; 70DF816013DDBA6400AD2F4D /* DemoBase.cxx in Sources */ = {isa = PBXBuildFile; fileRef = 70DF815A13DDBA6400AD2F4D /* DemoBase.cxx */; }; 70DF816113DDBA6400AD2F4D /* ExclusionGraphDemo.cxx in Sources */ = {isa = PBXBuildFile; fileRef = 70DF815B13DDBA6400AD2F4D /* ExclusionGraphDemo.cxx */; }; 70DF816213DDBA6400AD2F4D /* HsimpleDemo.cxx in Sources */ = {isa = PBXBuildFile; fileRef = 70DF815C13DDBA6400AD2F4D /* HsimpleDemo.cxx */; }; @@ -79,8 +78,6 @@ 700B010C13F3D40A00F84650 /* PadOptionsController.h */ = {isa = PBXFileReference; explicitFileType = sourcecode.cpp.objcpp; fileEncoding = 4; path = PadOptionsController.h; sourceTree = "<group>"; }; 700B010D13F3D40A00F84650 /* PadOptionsController.mm */ = {isa = PBXFileReference; explicitFileType = sourcecode.cpp.objcpp; fileEncoding = 4; path = PadOptionsController.mm; sourceTree = "<group>"; }; 700B010E13F3D40A00F84650 /* PadOptionsController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; name = PadOptionsController.xib; path = ../PadOptionsController.xib; sourceTree = "<group>"; }; - 700B012E13F3FD6600F84650 /* ColorCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ColorCell.h; path = Tutorials.xcodeproj/ColorCell.h; sourceTree = "<group>"; }; - 700B012F13F3FD6600F84650 /* ColorCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ColorCell.m; path = Tutorials.xcodeproj/ColorCell.m; sourceTree = "<group>"; }; 700B013113F4051000F84650 /* PatternCell.h */ = {isa = PBXFileReference; explicitFileType = sourcecode.cpp.objcpp; fileEncoding = 4; path = PatternCell.h; sourceTree = "<group>"; }; 700B013213F4051000F84650 /* PatternCell.mm */ = {isa = PBXFileReference; explicitFileType = sourcecode.cpp.objcpp; fileEncoding = 4; path = PatternCell.mm; sourceTree = "<group>"; }; 7010C3681455B64100018E6D /* tutorials_app_icon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = tutorials_app_icon.png; path = Pictures/tutorials_app_icon.png; sourceTree = "<group>"; }; @@ -136,7 +133,7 @@ 70D3FB5113E7F605005BADA3 /* single_tap_icon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = single_tap_icon.png; path = Pictures/single_tap_icon.png; sourceTree = "<group>"; }; 70D4847F13F057430043110B /* system.plugins-ios */ = {isa = PBXFileReference; lastKnownFileType = text; name = "system.plugins-ios"; path = "../../../etc/system.plugins-ios"; sourceTree = "<group>"; }; 70D645FB13D3243A00CE9FB1 /* PictView.h */ = {isa = PBXFileReference; explicitFileType = sourcecode.cpp.objcpp; fileEncoding = 4; path = PictView.h; sourceTree = "<group>"; }; - 70D645FC13D3243A00CE9FB1 /* PictView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PictView.m; sourceTree = "<group>"; }; + 70D645FC13D3243A00CE9FB1 /* PictView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PictView.mm; sourceTree = "<group>"; }; 70DF815A13DDBA6400AD2F4D /* DemoBase.cxx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DemoBase.cxx; sourceTree = "<group>"; }; 70DF815B13DDBA6400AD2F4D /* ExclusionGraphDemo.cxx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ExclusionGraphDemo.cxx; sourceTree = "<group>"; }; 70DF815C13DDBA6400AD2F4D /* HsimpleDemo.cxx */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = HsimpleDemo.cxx; sourceTree = "<group>"; }; @@ -232,14 +229,12 @@ 7099E64713CB2BF000D31765 /* Classes */ = { isa = PBXGroup; children = ( - 700B012E13F3FD6600F84650 /* ColorCell.h */, - 700B012F13F3FD6600F84650 /* ColorCell.m */, 700B013113F4051000F84650 /* PatternCell.h */, 700B013213F4051000F84650 /* PatternCell.mm */, 700B010C13F3D40A00F84650 /* PadOptionsController.h */, 700B010D13F3D40A00F84650 /* PadOptionsController.mm */, 70D645FB13D3243A00CE9FB1 /* PictView.h */, - 70D645FC13D3243A00CE9FB1 /* PictView.m */, + 70D645FC13D3243A00CE9FB1 /* PictView.mm */, 7085571F13C73AD900022713 /* PadView.mm */, 7085571E13C73AD900022713 /* PadView.h */, 70BA9B5213C5F89100102BC9 /* TutorialsAppDelegate.h */, @@ -367,7 +362,13 @@ 70BA9B3613C5F89100102BC9 /* Project object */ = { isa = PBXProject; attributes = { - LastUpgradeCheck = 0420; + LastUpgradeCheck = 0500; + ORGANIZATIONNAME = CERN; + TargetAttributes = { + 70BA9B3E13C5F89100102BC9 = { + DevelopmentTeam = V5WJKFTQN5; + }; + }; }; buildConfigurationList = 70BA9B3913C5F89100102BC9 /* Build configuration list for PBXProject "Tutorials" */; compatibilityVersion = "Xcode 3.2"; @@ -443,7 +444,7 @@ 70BA9B6013C5F89100102BC9 /* RootViewController.mm in Sources */, 7085572013C73AD900022713 /* PadView.mm in Sources */, 70C8237C13CF790E00F884FF /* HintView.mm in Sources */, - 70D645FD13D3243A00CE9FB1 /* PictView.m in Sources */, + 70D645FD13D3243A00CE9FB1 /* PictView.mm in Sources */, 701EC32513D9762200FE395E /* SelectionView.mm in Sources */, 70DF816013DDBA6400AD2F4D /* DemoBase.cxx in Sources */, 70DF816113DDBA6400AD2F4D /* ExclusionGraphDemo.cxx in Sources */, @@ -453,7 +454,6 @@ 70DF816513DDBA6400AD2F4D /* SurfaceDemo.cxx in Sources */, 707644B113EFC6AA00C302F9 /* H2PolyDemo.cxx in Sources */, 700B010F13F3D40A00F84650 /* PadOptionsController.mm in Sources */, - 700B013013F3FD6700F84650 /* ColorCell.m in Sources */, 700B013313F4051000F84650 /* PatternCell.mm in Sources */, 70CC7E4A1456A7050036FF4C /* DemoHelper.cxx in Sources */, ); @@ -492,18 +492,28 @@ 70BA9B6113C5F89100102BC9 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_UNIVERSAL_IPHONE_OS)"; CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; GCC_C_LANGUAGE_STANDARD = c99; GCC_OPTIMIZATION_LEVEL = 0; GCC_PREPROCESSOR_DEFINITIONS = DEBUG; GCC_SYMBOLS_PRIVATE_EXTERN = NO; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_RETURN_TYPE = YES; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES; + GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; IPHONEOS_DEPLOYMENT_TARGET = 5.0; LIBRARY_SEARCH_PATHS = ../../../lib; + ONLY_ACTIVE_ARCH = YES; OTHER_LDFLAGS = ../../../io/io/src/G__IO.o; SDKROOT = iphoneos; TARGETED_DEVICE_FAMILY = 2; @@ -513,12 +523,21 @@ 70BA9B6213C5F89100102BC9 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_UNIVERSAL_IPHONE_OS)"; CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; GCC_C_LANGUAGE_STANDARD = c99; GCC_VERSION = com.apple.compilers.llvm.clang.1_0; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_RETURN_TYPE = YES; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES; + GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; IPHONEOS_DEPLOYMENT_TARGET = 5.0; LIBRARY_SEARCH_PATHS = ../../../lib; @@ -533,18 +552,24 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; + ARCHS = armv7; CLANG_CXX_LANGUAGE_STANDARD = "c++0x"; CLANG_CXX_LIBRARY = "compiler-default"; CLANG_ENABLE_OBJC_ARC = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; GCC_DYNAMIC_NO_PIC = NO; GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = "Tutorials/Tutorials-Prefix.pch"; + GCC_VERSION = ""; "HEADER_SEARCH_PATHS[arch=*]" = ../../../include; INFOPLIST_FILE = "Tutorials/Tutorials-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 5.0; + IPHONEOS_DEPLOYMENT_TARGET = 7.0; LIBRARY_SEARCH_PATHS = ../../../lib; "LIBRARY_SEARCH_PATHS[arch=*]" = "$(inherited)"; + ONLY_ACTIVE_ARCH = YES; OTHER_LDFLAGS = ( ../../../io/io/src/G__IO.o, ../../../net/net/src/G__Net.o, @@ -553,6 +578,7 @@ ../../../graf3d/g3d/src/G__G3D.o, ); PRODUCT_NAME = "$(TARGET_NAME)"; + STRIP_INSTALLED_PRODUCT = YES; USER_HEADER_SEARCH_PATHS = ../../../lib; WRAPPER_EXTENSION = app; }; @@ -562,15 +588,19 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; + ARCHS = armv7; CLANG_CXX_LANGUAGE_STANDARD = "c++0x"; CLANG_CXX_LIBRARY = "compiler-default"; CLANG_ENABLE_OBJC_ARC = YES; + CODE_SIGN_IDENTITY = "iPhone Distribution"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; COPY_PHASE_STRIP = YES; GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = "Tutorials/Tutorials-Prefix.pch"; + GCC_VERSION = ""; "HEADER_SEARCH_PATHS[arch=*]" = ../../../include; INFOPLIST_FILE = "Tutorials/Tutorials-Info.plist"; - IPHONEOS_DEPLOYMENT_TARGET = 5.0; + IPHONEOS_DEPLOYMENT_TARGET = 7.0; LIBRARY_SEARCH_PATHS = ../../../lib; "LIBRARY_SEARCH_PATHS[arch=*]" = "$(inherited)"; OTHER_LDFLAGS = ( @@ -581,6 +611,7 @@ ../../../graf3d/g3d/src/G__G3D.o, ); PRODUCT_NAME = "$(TARGET_NAME)"; + STRIP_INSTALLED_PRODUCT = YES; USER_HEADER_SEARCH_PATHS = ../../../lib; VALIDATE_PRODUCT = YES; WRAPPER_EXTENSION = app; diff --git a/test/ios/Tutorials/Tutorials/DetailViewController.h b/test/ios/Tutorials/Tutorials/DetailViewController.h index fb9dca5de0804..f79031af2aa46 100644 --- a/test/ios/Tutorials/Tutorials/DetailViewController.h +++ b/test/ios/Tutorials/Tutorials/DetailViewController.h @@ -19,9 +19,7 @@ class DemoBase; - (void) setActiveDemo : (ROOT::iOS::Demos::DemoBase *)demo; - (void) dismissPopover; -- (IBAction) zoomButtonPressed; - (IBAction) editButtonPressed : (id) sender; -- (IBAction) selectButtonPressed; - (IBAction) showHelp; @end diff --git a/test/ios/Tutorials/Tutorials/DetailViewController.mm b/test/ios/Tutorials/Tutorials/DetailViewController.mm index 9e91427de301e..5da8e7656e8a5 100644 --- a/test/ios/Tutorials/Tutorials/DetailViewController.mm +++ b/test/ios/Tutorials/Tutorials/DetailViewController.mm @@ -1,3 +1,8 @@ +#import <stdexcept> +#import <cstdlib> +#import <cassert> +#import <cmath> + #import <QuartzCore/QuartzCore.h> #import "PadOptionsController.h" @@ -23,15 +28,13 @@ modify this code already. This was a testbed. */ -namespace { +const unsigned nPadViews = 2; -enum ETutorialsMode { - kTAZoom, - kTASelect -}; +namespace { -enum ETutorialsDefaults { - kTDNOfPads = 2 +enum class AppMode { + zoom, + select }; } @@ -40,7 +43,7 @@ @interface DetailViewController () { //"Editor" - PadOptionsController * padController; + PadOptionsController *padController; UIPopoverController *editorPopover; //Transparent view with a text @@ -59,17 +62,15 @@ @interface DetailViewController () { ROOT::iOS::Pad *pad; - //Depending on more, either parentView of - //scrollViews is/are parent(s) of padViews. UIView *parentView; - UIScrollView *scrollViews[kTDNOfPads]; - PadView *padViews[kTDNOfPads]; + UIScrollView *scrollViews[nPadViews]; + PadView *padViews[nPadViews]; //Transparent view with selected object. - SelectionView *selectionViews[kTDNOfPads]; + SelectionView *selectionViews[nPadViews]; - UIPanGestureRecognizer *padPanGestures[kTDNOfPads]; - UITapGestureRecognizer *padTapGestures[kTDNOfPads]; + UIPanGestureRecognizer *padPanGestures[nPadViews]; + UITapGestureRecognizer *padTapGestures[nPadViews]; unsigned activeView; @@ -78,9 +79,11 @@ @interface DetailViewController () { ROOT::iOS::Demos::DemoBase *activeDemo; //Either zoom or selection. - ETutorialsMode appMode; + AppMode appMode; BOOL activeAnimation; + + BOOL inTransition; } @property (nonatomic, retain) UIPopoverController *popoverController; @@ -106,12 +109,23 @@ @implementation DetailViewController @synthesize help; @synthesize tabBar; -#pragma mark - Managing the detail item +//_________________________________________________________________ +- (void)dealloc +{ + delete pad; +} + +#pragma mark - initialization. //_________________________________________________________________ - (void) initCPPObjects { - pad = new ROOT::iOS::Pad(640, 640); + //Translate C++ exception into the bad C exit. + try { + pad = new ROOT::iOS::Pad(640, 640); + } catch (const std::exception &e) { + std::exit(1);//WOW??? + } } //_________________________________________________________________ @@ -123,10 +137,11 @@ - (void) initMainViews oldSizes.width = 640.f; oldSizes.height = 640.f; - parentView = [[UIView alloc] initWithFrame:padRect]; - parentView.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; + parentView = [[UIView alloc] initWithFrame : padRect]; + parentView.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | + UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; - [self.view addSubview:parentView]; + [self.view addSubview : parentView]; //Trick with shadow and shadow path: //http://nachbaur.com/blog/fun-shadow-effects-using-custom-calayer-shadowpaths @@ -134,22 +149,23 @@ - (void) initMainViews parentView.layer.shadowColor = [UIColor blackColor].CGColor; parentView.layer.shadowOpacity = 0.7f; parentView.layer.shadowOffset = CGSizeMake(10.f, 10.f); - UIBezierPath *path = [UIBezierPath bezierPathWithRect:parentView.bounds]; + UIBezierPath *path = [UIBezierPath bezierPathWithRect : parentView.bounds]; parentView.layer.shadowPath = path.CGPath; /// padRect.origin.x = 0.f, padRect.origin.y = 0.f; - for (unsigned i = 0; i < 2; ++i) {// < kTDNOfPads - scrollViews[i] = [[UIScrollView alloc] initWithFrame:padRect]; + for (unsigned i = 0; i < nPadViews; ++i) { + scrollViews[i] = [[UIScrollView alloc] initWithFrame : padRect]; scrollViews[i].backgroundColor = [UIColor darkGrayColor]; scrollViews[i].delegate = self; + padViews[i] = [[PadView alloc] initWithFrame : padRect forPad : pad]; scrollViews[i].contentSize = padViews[i].frame.size; - [scrollViews[i] addSubview:padViews[i]]; + [scrollViews[i] addSubview : padViews[i]]; // scrollViews[i].minimumZoomScale = 1.f; scrollViews[i].maximumZoomScale = 1280.f / 640.f; - [scrollViews[i] setZoomScale:1.f]; - [parentView addSubview:scrollViews[i]]; + [scrollViews[i] setZoomScale : 1.f]; + [parentView addSubview : scrollViews[i]]; } parentView.hidden = YES; @@ -158,10 +174,11 @@ - (void) initMainViews padRect = CGRectMake(padCenter.x - 320.f, padCenter.y - 310.f, 640.f, 640.f); - for (unsigned i = 0; i < 2; ++i) { // < kTDNOfPads - selectionViews[i] = [[SelectionView alloc] initWithFrame:padRect]; - selectionViews[i].autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; - [self.view addSubview:selectionViews[i]]; + for (unsigned i = 0; i < nPadViews; ++i) { + selectionViews[i] = [[SelectionView alloc] initWithFrame : padRect]; + selectionViews[i].autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | + UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; + [self.view addSubview : selectionViews[i]]; selectionViews[i].hidden = YES; selectionViews[i].opaque = NO; } @@ -174,106 +191,62 @@ - (void) initHints //Pictogramms. CGRect pictRect = CGRectMake(670.f, 450.f, 50.f, 50.f); pinchPic = [[PictView alloc] initWithFrame:pictRect andIcon:@"pinch_gesture_icon_small.png"]; - pinchPic.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; - [self.view addSubview:pinchPic]; - UITapGestureRecognizer *pinchTap = [[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(showPinchHint)]; - [pinchPic addGestureRecognizer:pinchTap]; + pinchPic.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | + UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; + [self.view addSubview : pinchPic]; + UITapGestureRecognizer * const pinchTap = [[UITapGestureRecognizer alloc] initWithTarget : self action : @selector(showPinchHint)]; + [pinchPic addGestureRecognizer : pinchTap]; pinchPic.hidden = YES; pictRect.origin.y = 520; - panPic = [[PictView alloc] initWithFrame:pictRect andIcon:@"pan_gesture_icon_small.png"]; - panPic.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; - [self.view addSubview:panPic]; - UITapGestureRecognizer *panTap = [[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(showPanHint)]; - [panPic addGestureRecognizer:panTap]; + panPic = [[PictView alloc] initWithFrame:pictRect andIcon : @"pan_gesture_icon_small.png"]; + panPic.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | + UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; + [self.view addSubview : panPic]; + UITapGestureRecognizer * const panTap = [[UITapGestureRecognizer alloc]initWithTarget : self action : @selector(showPanHint)]; + [panPic addGestureRecognizer : panTap]; panPic.hidden = YES; pictRect.origin.y = 590; - doubleTapPic = [[PictView alloc] initWithFrame:pictRect andIcon:@"double_tap_gesture_icon_small.png"]; - doubleTapPic.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; - [self.view addSubview:doubleTapPic]; - UITapGestureRecognizer *dtapTap = [[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(showDoubleTapHint)]; - [doubleTapPic addGestureRecognizer:dtapTap]; + doubleTapPic = [[PictView alloc] initWithFrame : pictRect andIcon : @"double_tap_gesture_icon_small.png"]; + doubleTapPic.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | + UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; + [self.view addSubview : doubleTapPic]; + UITapGestureRecognizer * const dtapTap = [[UITapGestureRecognizer alloc] initWithTarget : self action : @selector(showDoubleTapHint)]; + [doubleTapPic addGestureRecognizer : dtapTap]; doubleTapPic.hidden = YES; - rotatePic = [[PictView alloc] initWithFrame:pictRect andIcon:@"rotate_icon_small.png"]; - rotatePic.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; - [self.view addSubview:rotatePic]; - UITapGestureRecognizer *rotTap = [[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(showRotationHint)]; - [rotatePic addGestureRecognizer:rotTap]; + rotatePic = [[PictView alloc] initWithFrame : pictRect andIcon : @"rotate_icon_small.png"]; + rotatePic.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | + UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; + [self.view addSubview : rotatePic]; + UITapGestureRecognizer * const rotTap = [[UITapGestureRecognizer alloc] initWithTarget : self action : @selector(showRotationHint)]; + [rotatePic addGestureRecognizer : rotTap]; rotatePic.hidden = YES; - singleTapPic = [[PictView alloc] initWithFrame:pictRect andIcon:@"single_tap_icon_small.png"]; - singleTapPic.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; - [self.view addSubview:singleTapPic]; - UITapGestureRecognizer *singleTapTap = [[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(showSingleTapHint)]; - [singleTapPic addGestureRecognizer:singleTapTap]; + singleTapPic = [[PictView alloc] initWithFrame : pictRect andIcon : @"single_tap_icon_small.png"]; + singleTapPic.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | + UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; + [self.view addSubview : singleTapPic]; + UITapGestureRecognizer *singleTapTap = [[UITapGestureRecognizer alloc] initWithTarget : self action : @selector(showSingleTapHint)]; + [singleTapPic addGestureRecognizer : singleTapTap]; singleTapPic.hidden = YES; const CGPoint center = self.view.center; CGRect rect = CGRectMake(center.x - 300.f, center.y - 290.f, 600.f, 600.f); - hintView = [[HintView alloc] initWithFrame:rect]; - hintView.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; - [self.view addSubview:hintView]; - UITapGestureRecognizer *hintTap = [[UITapGestureRecognizer alloc] initWithTarget:hintView action:@selector(handleTap:)]; - [hintView addGestureRecognizer:hintTap]; + hintView = [[HintView alloc] initWithFrame : rect]; + hintView.autoresizingMask = UIViewAutoresizingFlexibleBottomMargin | UIViewAutoresizingFlexibleTopMargin | + UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleRightMargin; + [self.view addSubview : hintView]; + UITapGestureRecognizer *hintTap = [[UITapGestureRecognizer alloc] initWithTarget : hintView action : @selector(handleTap:)]; + [hintView addGestureRecognizer : hintTap]; hintView.hidden = YES; } -//_________________________________________________________________ -- (void)viewWillAppear:(BOOL)animated -{ - [super viewWillAppear:animated]; -} - -//_________________________________________________________________ -- (void)viewDidAppear:(BOOL)animated -{ - [super viewDidAppear:animated]; -} - -//_________________________________________________________________ -- (void)viewWillDisappear:(BOOL)animated -{ - [super viewWillDisappear:animated]; -} - -//_________________________________________________________________ -- (void)viewDidDisappear:(BOOL)animated -{ - [super viewDidDisappear:animated]; -} - -//_________________________________________________________________ -- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation -{ - return YES; -} - -#pragma mark - Split view support +#pragma mark - view lifecycle. //_________________________________________________________________ -- (void)splitViewController:(UISplitViewController *)svc willHideViewController:(UIViewController *)aViewController withBarButtonItem:(UIBarButtonItem *)barButtonItem forPopoverController: (UIPopoverController *)pc -{ - barButtonItem.title = @"Tutorials"; - NSMutableArray *items = [[self.toolbar items] mutableCopy]; - [items insertObject:barButtonItem atIndex:0]; - [self.toolbar setItems:items animated:YES]; - self.popoverController = pc; -} - -//_________________________________________________________________ -- (void)splitViewController:(UISplitViewController *)svc willShowViewController:(UIViewController *)aViewController invalidatingBarButtonItem:(UIBarButtonItem *)barButtonItem -{ - // Called when the view is shown again in the split view, invalidating the button and popover controller. - NSMutableArray *items = [[self.toolbar items] mutableCopy]; - [items removeObjectAtIndex:0]; - [self.toolbar setItems:items animated:YES]; - self.popoverController = nil; -} - -//_________________________________________________________________ -- (void)viewDidLoad +- (void) viewDidLoad { self.view.backgroundColor = [UIColor lightGrayColor]; @@ -281,7 +254,9 @@ - (void)viewDidLoad [self initMainViews]; [self initHints]; - appMode = kTAZoom; + inTransition = NO; + + appMode = AppMode::zoom; UITapGestureRecognizer *tapGesture = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(handleDoubleTapPad:)]; [parentView addGestureRecognizer:tapGesture]; @@ -305,67 +280,69 @@ - (void)viewDidLoad [super viewDidLoad]; } -//_________________________________________________________________ -- (void)viewDidUnload -{ - [super viewDidUnload]; - - // Release any retained subviews of the main view. - // e.g. self.myOutlet = nil; - self.popoverController = nil; -} - -#pragma mark - Memory management +#pragma mark - Split view support //_________________________________________________________________ -- (void)didReceiveMemoryWarning +- (void) splitViewController : (UISplitViewController *) svc willHideViewController : (UIViewController *) aViewController + withBarButtonItem : (UIBarButtonItem *) barButtonItem forPopoverController : (UIPopoverController *) pc { - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - - // Release any cached data, images, etc that aren't in use. + barButtonItem.title = @"Tutorials"; + NSMutableArray * const items = [[self.toolbar items] mutableCopy]; + [items insertObject : barButtonItem atIndex : 0]; + [self.toolbar setItems : items animated : YES]; + self.popoverController = pc; } //_________________________________________________________________ -- (void)dealloc +- (void) splitViewController : (UISplitViewController *) svc willShowViewController : (UIViewController *) aViewController + invalidatingBarButtonItem : (UIBarButtonItem *) barButtonItem { - // - delete pad; - // + // Called when the view is shown again in the split view, invalidating the button and popover controller. + NSMutableArray * const items = [[self.toolbar items] mutableCopy]; + [items removeObjectAtIndex : 0]; + [self.toolbar setItems : items animated:YES]; + self.popoverController = nil; } +#pragma mark - App's logic. + //_________________________________________________________________ - (void) prepareHints { - if (appMode == kTAZoom) { + if (appMode == AppMode::zoom) { + //In 'zoom' mode, pinch, double tap, + //pan gestures are activated and + //we show the corresponding hints. panPic.hidden = NO; pinchPic.hidden = NO; doubleTapPic.hidden = NO; - + singleTapPic.hidden = YES; rotatePic.hidden = YES; -// emptyPic.hidden = YES; - //Hide selection pictograms. } else { - //Show selection or rotate pictogram. - //Hide zoom mode's pictograms. panPic.hidden = YES; pinchPic.hidden = YES; doubleTapPic.hidden = YES; + //Show selection or rotation pictogram. rotatePic.hidden = !activeDemo->Supports3DRotation(); singleTapPic.hidden = !rotatePic.hidden; } } //_________________________________________________________________ -- (void) setActiveDemo:(ROOT::iOS::Demos::DemoBase *)demo +- (void) setActiveDemo : (ROOT::iOS::Demos::DemoBase *) demo { - help.hidden = YES; + assert(demo != nullptr && "setActiveDemo:, parameter 'demo' is null"); + if (inTransition) + return; + + help.hidden = YES; + hintView.hidden = YES; + if (demo != activeDemo) { - selectionViews[0].hidden = YES; selectionViews[1].hidden = YES; @@ -373,8 +350,9 @@ - (void) setActiveDemo:(ROOT::iOS::Demos::DemoBase *)demo //Stop any animated demo (previously active). if (animationTimer) { [animationTimer invalidate]; - animationTimer = 0; + animationTimer = nil; } + currentFrame = 0; // @@ -389,7 +367,9 @@ - (void) setActiveDemo:(ROOT::iOS::Demos::DemoBase *)demo const unsigned show = !hide; activeView = show; - if (appMode == kTAZoom) { + //Pad's parent is different in 'zoom' and 'select' mode. + + if (appMode == AppMode::zoom) { showView = scrollViews[show]; hideView = scrollViews[hide]; } else { @@ -398,8 +378,8 @@ - (void) setActiveDemo:(ROOT::iOS::Demos::DemoBase *)demo } //This is temporary hack. - [padViews[activeView] setProcessPan:activeDemo->Supports3DRotation()]; - [padViews[activeView] setProcessTap:!activeDemo->Supports3DRotation()]; + [padViews[activeView] setProcessPan : activeDemo->Supports3DRotation()]; + [padViews[activeView] setProcessTap : !activeDemo->Supports3DRotation()]; //Remove old contents of pad, //set pad's parameters (if required by demo) @@ -411,11 +391,11 @@ - (void) setActiveDemo:(ROOT::iOS::Demos::DemoBase *)demo //Repaint active view's content. [padViews[activeView] setNeedsDisplay]; - + if (activeDemo->IsAnimated()) { //Start timer for animated demo. activeDemo->StartAnimation(); - animationTimer = [NSTimer scheduledTimerWithTimeInterval:0.5 / 25 target:self selector:@selector(onTimer) userInfo:nil repeats:YES]; + animationTimer = [NSTimer scheduledTimerWithTimeInterval : 0.5 / 25 target : self selector : @selector(onTimer) userInfo : nil repeats : YES]; } //Make an animation: hide one view (demo), show another one. @@ -426,16 +406,16 @@ - (void) setActiveDemo:(ROOT::iOS::Demos::DemoBase *)demo // Animate over 3/4 of a second transition.duration = 0.75; // using the ease in/out timing function - transition.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseInEaseOut]; + transition.timingFunction = [CAMediaTimingFunction functionWithName : kCAMediaTimingFunctionEaseInEaseOut]; // Now to set the type of transition. transition.type = kCATransitionReveal; transition.subtype = kCATransitionFromLeft; // Finally, to avoid overlapping transitions we assign ourselves as the delegate for the animation and wait for the // -animationDidStop:finished: message. When it comes in, we will flag that we are no longer transitioning. - //transitioning = YES; + inTransition = YES; transition.delegate = self; // Next add it to the containerView's layer. This will perform the transition based on how we change its contents. - [parentView.layer addAnimation : transition forKey:nil]; + [parentView.layer addAnimation : transition forKey : nil]; } } @@ -448,9 +428,12 @@ - (void) dismissPopover //_________________________________________________________________ - (void) onTimer { + assert(activeDemo != nullptr && "onTimer, activeDemo is null"); + assert(animationTimer != nil && "onTimer, animationTimer is nil"); + if (currentFrame == activeDemo->NumOfFrames()) { [animationTimer invalidate]; - animationTimer = 0; + animationTimer = nil; } else { ++currentFrame; activeDemo->NextStep(); @@ -459,57 +442,68 @@ - (void) onTimer } //_________________________________________________________________ -- (void) resizePadView:(unsigned)view +- (void) resetPadView : (unsigned) view { - UIScrollView *scroll = (UIScrollView *)padViews[view].superview; - CGRect oldRect = padViews[view].frame; + //Reset the pad view to its original dimensions (640x640) to + //avoid different ugly donwscaling effects. + + UIScrollView * const scroll = (UIScrollView *)padViews[view].superview; + const CGRect oldRect = padViews[view].frame; - if (abs(640.f - oldRect.size.width) < 0.01 && (abs(640.f - oldRect.size.height) < 0.01)) + if (std::abs(640.f - oldRect.size.width) < 0.01 && std::abs(640.f - oldRect.size.height) < 0.01) return; - CGRect padRect = CGRectMake(0.f, 0.f, 640.f, 640.f); + const CGRect padRect = CGRectMake(0.f, 0.f, 640.f, 640.f); [padViews[view] removeFromSuperview]; padViews[view] = [[PadView alloc] initWithFrame : padRect forPad : pad]; - [scroll addSubview:padViews[view]]; + [scroll addSubview : padViews[view]]; scroll.minimumZoomScale = 1.f; scroll.maximumZoomScale = 2.f; - [scroll setZoomScale:1.f]; + [scroll setZoomScale : 1.f]; scroll.contentSize = padRect.size; scroll.contentOffset = CGPointMake(0.f, 0.f); - + oldSizes.width = 640.f; oldSizes.height = 640.f; } +#pragma mark - delegate for a transition animation. + //_________________________________________________________________ --(void)animationDidStop:(CAAnimation *)theAnimation finished:(BOOL)flag +-(void) animationDidStop : (CAAnimation *) animation finished : (BOOL) flag { +#pragma unused(animation) + //After one view was hidden, resize it's scale to 1 and //view itself to original size. - if (appMode == kTAZoom) { - unsigned inactiveView = activeView ? 0 : 1; - [self resizePadView : inactiveView]; + if (flag) { + inTransition = NO; + if (appMode == AppMode::zoom) + [self resetPadView : activeView ? 0 : 1]; } } #pragma mark - That's what I call action :) +//zoomButtonPressed/selectButtonPressed - legacy code (before I really had buttons), now they are +//simply called from tabs' tap gestures. //_________________________________________________________________ -- (IBAction)zoomButtonPressed +- (void) zoomButtonPressed { - if (appMode == kTAZoom) + if (appMode == AppMode::zoom) return; //Zoom mode was selected. - appMode = kTAZoom; - //The mode was kTASelect previously. + appMode = AppMode::zoom; + //The mode was 'select' previously. //Reparent pad views, now scrollview is a parent for a pad view. - for (unsigned i = 0; i < 2; ++i) { // < kTDNOfPads. + + for (unsigned i = 0; i < nPadViews; ++i) { selectionViews[i].hidden = YES; [padViews[i] removeGestureRecognizer : padPanGestures[i]]; [padViews[i] removeGestureRecognizer : padTapGestures[i]]; - + padViews[i].hidden = NO; [padViews[i] removeFromSuperview]; [scrollViews[i] addSubview : padViews[i]]; @@ -522,18 +516,18 @@ - (IBAction)zoomButtonPressed } //_________________________________________________________________ -- (IBAction) selectButtonPressed +- (void) selectButtonPressed { - if (appMode == kTASelect)// || !activeDemo) + if (appMode == AppMode::select) return; - appMode = kTASelect; + appMode = AppMode::select; //hide both scroll views, re-parent pad-views. - for (unsigned i = 0; i < 2; ++i) { // < kTDNOfPads + for (unsigned i = 0; i < nPadViews; ++i) { scrollViews[i].hidden = YES; - //1. Check, if views must be resized (unscaled). - [self resizePadView : i]; + //1. Check, if views must be reset (unzoom). + [self resetPadView : i]; [padViews[i] removeFromSuperview]; @@ -541,19 +535,19 @@ - (IBAction) selectButtonPressed [padViews[i] addGestureRecognizer:padPanGestures[i]]; padTapGestures[i] = [[UITapGestureRecognizer alloc] initWithTarget:padViews[i] action:@selector(handleTapGesture:)]; - [padViews[i] addGestureRecognizer:padTapGestures[i]]; + [padViews[i] addGestureRecognizer : padTapGestures[i]]; - [padViews[i] setSelectionView:selectionViews[i]]; + [padViews[i] setSelectionView : selectionViews[i]]; - [parentView addSubview:padViews[i]]; + [parentView addSubview : padViews[i]]; if (activeDemo) //In case no demo was selected - nothing to show yet. padViews[i].hidden = i == activeView ? NO : YES; } if (activeDemo) { - [padViews[activeView] setProcessPan:activeDemo->Supports3DRotation()]; - [padViews[activeView] setProcessTap:!activeDemo->Supports3DRotation()]; + [padViews[activeView] setProcessPan : activeDemo->Supports3DRotation()]; + [padViews[activeView] setProcessTap : !activeDemo->Supports3DRotation()]; [self prepareHints]; } } @@ -561,13 +555,14 @@ - (IBAction) selectButtonPressed //_________________________________________________________________ - (IBAction) editButtonPressed : (id) sender { +#pragma unsued(sender) + if (editorPopover && editorPopover.popoverVisible) { [editorPopover dismissPopoverAnimated : YES]; - return; } else { if (!padController) { padController = [[PadOptionsController alloc] initWithNibName : @"PadOptionsController" bundle : nil]; - padController.contentSizeForViewInPopover = CGSizeMake(250.f, 650.f); + padController.preferredContentSize = CGSizeMake(250.f, 650.f); } if (!editorPopover) { @@ -575,7 +570,8 @@ - (IBAction) editButtonPressed : (id) sender editorPopover.popoverContentSize = CGSizeMake(250.f, 650.f); } - [editorPopover presentPopoverFromBarButtonItem : sender permittedArrowDirections:UIPopoverArrowDirectionAny animated : YES]; + assert(pad != nullptr && "editButtonPressed:, pad is null"); + [editorPopover presentPopoverFromBarButtonItem : sender permittedArrowDirections : UIPopoverArrowDirectionAny animated : YES]; [padController setView : padViews[activeView] andPad : pad]; } } @@ -583,19 +579,31 @@ - (IBAction) editButtonPressed : (id) sender //_________________________________________________________________ - (IBAction) showHelp { - CATransition *transition = [CATransition animation]; + CATransition * const transition = [CATransition animation]; transition.duration = 0.25; - transition.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseInEaseOut]; + transition.timingFunction = [CAMediaTimingFunction functionWithName : kCAMediaTimingFunctionEaseInEaseOut]; transition.type = kCATransitionReveal; transition.subtype = kCATransitionFade; help.hidden = !help.hidden; - [help.layer addAnimation:transition forKey:nil]; + [help.layer addAnimation : transition forKey : nil]; +} + + +#pragma mark - Tab bar delegate. + +//_________________________________________________________________ +- (void) tabBar : (UITabBar *) tb didSelectItem : (UITabBarItem *) item +{ + if (item.tag == 1) + [self zoomButtonPressed]; + else + [self selectButtonPressed]; } #pragma mark - UIScrollView's delegate. //_________________________________________________________________ -- (UIView *) viewForZoomingInScrollView : (UIScrollView *)scrollView +- (UIView *) viewForZoomingInScrollView : (UIScrollView *) scrollView { if (scrollView == scrollViews[0]) return padViews[0]; @@ -604,27 +612,31 @@ - (UIView *) viewForZoomingInScrollView : (UIScrollView *)scrollView } //_________________________________________________________________ -- (CGRect) centeredFrameForScrollView : (UIScrollView *)scroll andUIView : (UIView *)rView +- (CGRect) centeredFrameForScrollView : (UIScrollView *)scroll andUIView : (UIView *) rView { - CGSize boundsSize = scroll.bounds.size; + const CGSize boundsSize = scroll.bounds.size; CGRect frameToCenter = rView.frame; // center horizontally if (frameToCenter.size.width < boundsSize.width) frameToCenter.origin.x = (boundsSize.width - frameToCenter.size.width) / 2; else - frameToCenter.origin.x = 0; + frameToCenter.origin.x = 0.f; // center vertically if (frameToCenter.size.height < boundsSize.height) frameToCenter.origin.y = (boundsSize.height - frameToCenter.size.height) / 2; else - frameToCenter.origin.y = 0; + frameToCenter.origin.y = 0.f; return frameToCenter; } //_________________________________________________________________ -- (void)scrollViewDidEndZooming:(UIScrollView *)scrollView withView:(UIView *)view atScale:(float)scale +- (void) scrollViewDidEndZooming : (UIScrollView *) scrollView withView : (UIView *) view atScale : (float) scale { + //The problem with a scrollview: it scales the original 'image', making it look badly. + //At the end of zoom I'm recreating the pad view and it must be re-rendered, creating + //a new nice image. + const CGPoint off = [scrollView contentOffset]; CGRect oldRect = padViews[activeView].frame; oldRect.origin.x = 0.f; @@ -637,9 +649,9 @@ - (void)scrollViewDidEndZooming:(UIScrollView *)scrollView withView:(UIView *)vi [padViews[activeView] removeFromSuperview]; padViews[activeView] = [[PadView alloc] initWithFrame : oldRect forPad : pad]; - [scrollView addSubview:padViews[activeView]]; + [scrollView addSubview : padViews[activeView]]; - [scrollView setZoomScale:1.f]; + [scrollView setZoomScale : 1.f]; scrollView.contentSize = oldRect.size; scrollView.contentOffset = off; @@ -648,43 +660,32 @@ - (void)scrollViewDidEndZooming:(UIScrollView *)scrollView withView:(UIView *)vi } //_________________________________________________________________ -- (void)scrollViewDidZoom:(UIScrollView *)scrollView +- (void) scrollViewDidZoom : (UIScrollView *) scrollView { - padViews[activeView].frame = [self centeredFrameForScrollView:scrollView andUIView:padViews[activeView]]; -} - -#pragma mark - Tab bar delegate. - -//_________________________________________________________________ -- (void) tabBar : (UITabBar *) tb didSelectItem:(UITabBarItem *)item -{ - if (item.tag == 1) - [self zoomButtonPressed]; - else - [self selectButtonPressed]; + padViews[activeView].frame = [self centeredFrameForScrollView : scrollView andUIView : padViews[activeView]]; } #pragma mark - Tap gesture handler. //_________________________________________________________________ -- (void) handleDoubleTapPad:(UITapGestureRecognizer *)tap +- (void) handleDoubleTapPad : (UITapGestureRecognizer *) tap { - if (appMode != kTAZoom || !activeDemo) + if (appMode != AppMode::zoom || !activeDemo) return; if (oldSizes.width > 640.f) - [self resizePadView : activeView]; + [self resetPadView : activeView]; else { //Zoom to maximum. oldSizes = CGSizeMake(1280.f, 1280.f); - CGRect newRect = CGRectMake(0.f, 0.f, 1280.f, 1280.f); + const CGRect newRect = CGRectMake(0.f, 0.f, 1280.f, 1280.f); [padViews[activeView] removeFromSuperview]; padViews[activeView] = [[PadView alloc] initWithFrame : newRect forPad : pad]; - [scrollViews[activeView] addSubview:padViews[activeView]]; + [scrollViews[activeView] addSubview : padViews[activeView]]; - [scrollViews[activeView] setZoomScale:1.f]; + [scrollViews[activeView] setZoomScale : 1.f]; scrollViews[activeView].contentSize = newRect.size; scrollViews[activeView].minimumZoomScale = 1.f; @@ -737,4 +738,15 @@ - (void) showSingleTapHint hintView.hidden = NO; } +#pragma mark - Interface orientation. + +//_________________________________________________________________ +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation +{ +#pragma unused(interfaceOrientation) + + return YES; +} + + @end diff --git a/test/ios/Tutorials/Tutorials/HelpView.xib b/test/ios/Tutorials/Tutorials/HelpView.xib index 99955b0e2c3a8..7a2f0bb550faa 100644 --- a/test/ios/Tutorials/Tutorials/HelpView.xib +++ b/test/ios/Tutorials/Tutorials/HelpView.xib @@ -1,548 +1,86 @@ -<?xml version="1.0" encoding="UTF-8"?> -<archive type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="7.10"> - <data> - <int key="IBDocument.SystemTarget">1280</int> - <string key="IBDocument.SystemVersion">11C74</string> - <string key="IBDocument.InterfaceBuilderVersion">1938</string> - <string key="IBDocument.AppKitVersion">1138.23</string> - <string key="IBDocument.HIToolboxVersion">567.00</string> - <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> - <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string key="NS.object.0">933</string> - </object> - <object class="NSArray" key="IBDocument.IntegratedClassDependencies"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>IBUITextView</string> - <string>IBUIButton</string> - <string>IBUIImageView</string> - <string>IBUIView</string> - <string>IBProxyObject</string> - </object> - <object class="NSArray" key="IBDocument.PluginDependencies"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - </object> - <object class="NSMutableDictionary" key="IBDocument.Metadata"> - <string key="NS.key.0">PluginDependencyRecalculationVersion</string> - <integer value="1" key="NS.object.0"/> - </object> - <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBProxyObject" id="841351856"> - <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBProxyObject" id="371349661"> - <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - <object class="IBUIView" id="265583844"> - <reference key="NSNextResponder"/> - <int key="NSvFlags">256</int> - <object class="NSMutableArray" key="NSSubviews"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBUITextView" id="335724704"> - <reference key="NSNextResponder" ref="265583844"/> - <int key="NSvFlags">256</int> - <string key="NSFrame">{{0, 13}, {529, 93}}</string> - <reference key="NSSuperview" ref="265583844"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="769408932"/> - <object class="NSColor" key="IBUIBackgroundColor" id="818660103"> - <int key="NSColorSpace">3</int> - <bytes key="NSWhite">MCAwAA</bytes> - </object> - <bool key="IBUIClipsSubviews">YES</bool> - <bool key="IBUIUserInteractionEnabled">NO</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <bool key="IBUIShowsHorizontalScrollIndicator">NO</bool> - <bool key="IBUIEditable">NO</bool> - <string key="IBUIText">This is the very first ROOT's graphics demo program for iOS (iPad only at the moment). It shows several demos ("tutorials") and has some options.</string> - <int key="IBUITextAlignment">2</int> - <object class="IBUITextInputTraits" key="IBUITextInputTraits"> - <int key="IBUIAutocapitalizationType">2</int> - <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> - </object> - <object class="IBUIFontDescription" key="IBUIFontDescription" id="5475772"> - <string key="name">Helvetica</string> - <string key="family">Helvetica</string> - <int key="traits">0</int> - <double key="pointSize">18</double> - </object> - <object class="NSFont" key="IBUIFont" id="964393748"> - <string key="NSName">Helvetica</string> - <double key="NSSize">18</double> - <int key="NSfFlags">16</int> - </object> - </object> - <object class="IBUITextView" id="135727904"> - <reference key="NSNextResponder" ref="265583844"/> - <int key="NSvFlags">292</int> - <string key="NSFrame">{{83, 103}, {446, 60}}</string> - <reference key="NSSuperview" ref="265583844"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="20877331"/> - <object class="NSColor" key="IBUIBackgroundColor"> - <int key="NSColorSpace">1</int> - <bytes key="NSRGB">MSAxIDEgMAA</bytes> - </object> - <bool key="IBUIClipsSubviews">YES</bool> - <float key="IBUIAlpha">0.89999997615814209</float> - <bool key="IBUIUserInteractionEnabled">NO</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <bool key="IBUIShowsHorizontalScrollIndicator">NO</bool> - <bool key="IBUIEditable">NO</bool> - <string key="IBUIText">In "zoom" mode you can zoom/unzoom, scroll pad's contents, using pinch gesture or double tap gesture.</string> - <int key="IBUITextAlignment">2</int> - <object class="IBUITextInputTraits" key="IBUITextInputTraits"> - <int key="IBUIAutocapitalizationType">2</int> - <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> - </object> - <reference key="IBUIFontDescription" ref="5475772"/> - <reference key="IBUIFont" ref="964393748"/> - </object> - <object class="IBUIImageView" id="769408932"> - <reference key="NSNextResponder" ref="265583844"/> - <int key="NSvFlags">292</int> - <string key="NSFrame">{{15, 109}, {65, 48}}</string> - <reference key="NSSuperview" ref="265583844"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="135727904"/> - <object class="NSColor" key="IBUIBackgroundColor" id="172928706"> - <int key="NSColorSpace">3</int> - <bytes key="NSWhite">MQA</bytes> - </object> - <bool key="IBUIUserInteractionEnabled">NO</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <object class="NSCustomResource" key="IBUIImage"> - <string key="NSClassName">NSImage</string> - <string key="NSResourceName">zoom_mode_icon.png</string> - </object> - </object> - <object class="IBUITextView" id="20877331"> - <reference key="NSNextResponder" ref="265583844"/> - <int key="NSvFlags">292</int> - <string key="NSFrame">{{20, 179}, {340, 98}}</string> - <reference key="NSSuperview" ref="265583844"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="91634601"/> - <reference key="IBUIBackgroundColor" ref="818660103"/> - <bool key="IBUIClipsSubviews">YES</bool> - <bool key="IBUIUserInteractionEnabled">NO</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <bool key="IBUIShowsHorizontalScrollIndicator">NO</bool> - <bool key="IBUIEditable">NO</bool> - <string key="IBUIText">Gestures, which you can use in the current mode, are shown by pictograms. You can tap on a pictogram to read a hint.</string> - <object class="IBUITextInputTraits" key="IBUITextInputTraits"> - <int key="IBUIAutocapitalizationType">2</int> - <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> - </object> - <reference key="IBUIFontDescription" ref="5475772"/> - <reference key="IBUIFont" ref="964393748"/> - </object> - <object class="IBUIImageView" id="91634601"> - <reference key="NSNextResponder" ref="265583844"/> - <int key="NSvFlags">292</int> - <string key="NSFrame">{{346, 179}, {80, 80}}</string> - <reference key="NSSuperview" ref="265583844"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="134930563"/> - <bool key="IBUIUserInteractionEnabled">NO</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <object class="NSCustomResource" key="IBUIImage"> - <string key="NSClassName">NSImage</string> - <string key="NSResourceName">pinch_gesture_icon.png</string> - </object> - </object> - <object class="IBUIImageView" id="134930563"> - <reference key="NSNextResponder" ref="265583844"/> - <int key="NSvFlags">292</int> - <string key="NSFrame">{{449, 179}, {80, 80}}</string> - <reference key="NSSuperview" ref="265583844"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="535908415"/> - <bool key="IBUIUserInteractionEnabled">NO</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <object class="NSCustomResource" key="IBUIImage"> - <string key="NSClassName">NSImage</string> - <string key="NSResourceName">pan_gesture_icon.png</string> - </object> - </object> - <object class="IBUIImageView" id="535908415"> - <reference key="NSNextResponder" ref="265583844"/> - <int key="NSvFlags">292</int> - <string key="NSFrame">{{15, 293}, {71, 44}}</string> - <reference key="NSSuperview" ref="265583844"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="1072990326"/> - <reference key="IBUIBackgroundColor" ref="172928706"/> - <bool key="IBUIUserInteractionEnabled">NO</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <object class="NSCustomResource" key="IBUIImage"> - <string key="NSClassName">NSImage</string> - <string key="NSResourceName">select_mode.png</string> - </object> - </object> - <object class="IBUITextView" id="1072990326"> - <reference key="NSNextResponder" ref="265583844"/> - <int key="NSvFlags">292</int> - <string key="NSFrame">{{94, 285}, {435, 100}}</string> - <reference key="NSSuperview" ref="265583844"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="515517516"/> - <reference key="IBUIBackgroundColor" ref="818660103"/> - <bool key="IBUIClipsSubviews">YES</bool> - <bool key="IBUIUserInteractionEnabled">NO</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <bool key="IBUIShowsHorizontalScrollIndicator">NO</bool> - <bool key="IBUIEditable">NO</bool> - <string key="IBUIText">In selection mode, you can rotate 3D objects like lego or surface or pick axis/histograms (no editor in this demo).</string> - <int key="IBUITextAlignment">1</int> - <object class="IBUITextInputTraits" key="IBUITextInputTraits"> - <int key="IBUIAutocapitalizationType">2</int> - <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> - </object> - <reference key="IBUIFontDescription" ref="5475772"/> - <reference key="IBUIFont" ref="964393748"/> - </object> - <object class="IBUIButton" id="515517516"> - <reference key="NSNextResponder" ref="265583844"/> - <int key="NSvFlags">292</int> - <string key="NSFrame">{{201, 393}, {158, 58}}</string> - <reference key="NSSuperview" ref="265583844"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView"/> - <bool key="IBUIOpaque">NO</bool> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - <int key="IBUIContentHorizontalAlignment">0</int> - <int key="IBUIContentVerticalAlignment">0</int> - <int key="IBUIButtonType">1</int> - <string key="IBUINormalTitle">Hide</string> - <reference key="IBUIHighlightedTitleColor" ref="172928706"/> - <object class="NSColor" key="IBUINormalTitleColor"> - <int key="NSColorSpace">1</int> - <bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes> - </object> - <object class="NSColor" key="IBUINormalTitleShadowColor" id="794686228"> - <int key="NSColorSpace">3</int> - <bytes key="NSWhite">MC41AA</bytes> - </object> - <object class="IBUIFontDescription" key="IBUIFontDescription"> - <string key="name">Helvetica-Bold</string> - <string key="family">Helvetica</string> - <int key="traits">2</int> - <double key="pointSize">15</double> - </object> - <object class="NSFont" key="IBUIFont"> - <string key="NSName">Helvetica-Bold</string> - <double key="NSSize">15</double> - <int key="NSfFlags">16</int> - </object> - </object> - </object> - <string key="NSFrameSize">{561, 471}</string> - <reference key="NSSuperview"/> - <reference key="NSWindow"/> - <reference key="NSNextKeyView" ref="335724704"/> - <reference key="IBUIBackgroundColor" ref="794686228"/> - <float key="IBUIAlpha">0.89999997615814209</float> - <int key="IBUIContentMode">2</int> - <object class="IBUISimulatedOrientationMetrics" key="IBUISimulatedOrientationMetrics"> - <int key="IBUIInterfaceOrientation">3</int> - <int key="interfaceOrientation">3</int> - </object> - <string key="targetRuntimeIdentifier">IBIPadFramework</string> - </object> - </object> - <object class="IBObjectContainer" key="IBDocument.Objects"> - <object class="NSMutableArray" key="connectionRecords"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchOutletConnection" key="connection"> - <string key="label">help</string> - <reference key="source" ref="841351856"/> - <reference key="destination" ref="265583844"/> - </object> - <int key="connectionID">13</int> - </object> - <object class="IBConnectionRecord"> - <object class="IBCocoaTouchEventConnection" key="connection"> - <string key="label">showHelp</string> - <reference key="source" ref="515517516"/> - <reference key="destination" ref="841351856"/> - <int key="IBEventType">7</int> - </object> - <int key="connectionID">14</int> - </object> - </object> - <object class="IBMutableOrderedSet" key="objectRecords"> - <object class="NSArray" key="orderedObjects"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBObjectRecord"> - <int key="objectID">0</int> - <object class="NSArray" key="object" id="0"> - <bool key="EncodedWithXMLCoder">YES</bool> - </object> - <reference key="children" ref="1000"/> - <nil key="parent"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">-1</int> - <reference key="object" ref="841351856"/> - <reference key="parent" ref="0"/> - <string key="objectName">File's Owner</string> - </object> - <object class="IBObjectRecord"> - <int key="objectID">-2</int> - <reference key="object" ref="371349661"/> - <reference key="parent" ref="0"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">3</int> - <reference key="object" ref="265583844"/> - <object class="NSMutableArray" key="children"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference ref="20877331"/> - <reference ref="135727904"/> - <reference ref="769408932"/> - <reference ref="335724704"/> - <reference ref="535908415"/> - <reference ref="1072990326"/> - <reference ref="91634601"/> - <reference ref="134930563"/> - <reference ref="515517516"/> - </object> - <reference key="parent" ref="0"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">4</int> - <reference key="object" ref="515517516"/> - <reference key="parent" ref="265583844"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">6</int> - <reference key="object" ref="535908415"/> - <reference key="parent" ref="265583844"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">5</int> - <reference key="object" ref="1072990326"/> - <reference key="parent" ref="265583844"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">7</int> - <reference key="object" ref="134930563"/> - <reference key="parent" ref="265583844"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">8</int> - <reference key="object" ref="91634601"/> - <reference key="parent" ref="265583844"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">12</int> - <reference key="object" ref="20877331"/> - <reference key="parent" ref="265583844"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">10</int> - <reference key="object" ref="769408932"/> - <reference key="parent" ref="265583844"/> - <string key="objectName">Image View</string> - </object> - <object class="IBObjectRecord"> - <int key="objectID">11</int> - <reference key="object" ref="135727904"/> - <reference key="parent" ref="265583844"/> - </object> - <object class="IBObjectRecord"> - <int key="objectID">9</int> - <reference key="object" ref="335724704"/> - <reference key="parent" ref="265583844"/> - </object> - </object> - </object> - <object class="NSMutableDictionary" key="flattenedProperties"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>-1.CustomClassName</string> - <string>-1.IBPluginDependency</string> - <string>-2.CustomClassName</string> - <string>-2.IBPluginDependency</string> - <string>10.IBPluginDependency</string> - <string>11.IBPluginDependency</string> - <string>12.IBPluginDependency</string> - <string>3.IBPluginDependency</string> - <string>4.IBPluginDependency</string> - <string>5.IBPluginDependency</string> - <string>6.IBPluginDependency</string> - <string>7.IBPluginDependency</string> - <string>8.IBPluginDependency</string> - <string>9.IBPluginDependency</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>DetailViewController</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>UIResponder</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> - </object> - </object> - <object class="NSMutableDictionary" key="unlocalizedProperties"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference key="dict.sortedKeys" ref="0"/> - <reference key="dict.values" ref="0"/> - </object> - <nil key="activeLocalization"/> - <object class="NSMutableDictionary" key="localizations"> - <bool key="EncodedWithXMLCoder">YES</bool> - <reference key="dict.sortedKeys" ref="0"/> - <reference key="dict.values" ref="0"/> - </object> - <nil key="sourceID"/> - <int key="maxID">14</int> - </object> - <object class="IBClassDescriber" key="IBDocument.Classes"> - <object class="NSMutableArray" key="referencedPartialClassDescriptions"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBPartialClassDescription"> - <string key="className">DetailViewController</string> - <string key="superclassName">UIViewController</string> - <object class="NSMutableDictionary" key="actions"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>editButtonPressed:</string> - <string>selectButtonPressed</string> - <string>showHelp</string> - <string>zoomButtonPressed</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>id</string> - <string>id</string> - <string>id</string> - <string>id</string> - </object> - </object> - <object class="NSMutableDictionary" key="actionInfosByName"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>editButtonPressed:</string> - <string>selectButtonPressed</string> - <string>showHelp</string> - <string>zoomButtonPressed</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBActionInfo"> - <string key="name">editButtonPressed:</string> - <string key="candidateClassName">id</string> - </object> - <object class="IBActionInfo"> - <string key="name">selectButtonPressed</string> - <string key="candidateClassName">id</string> - </object> - <object class="IBActionInfo"> - <string key="name">showHelp</string> - <string key="candidateClassName">id</string> - </object> - <object class="IBActionInfo"> - <string key="name">zoomButtonPressed</string> - <string key="candidateClassName">id</string> - </object> - </object> - </object> - <object class="NSMutableDictionary" key="outlets"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>detailDescriptionLabel</string> - <string>help</string> - <string>tb</string> - <string>toolbar</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>UILabel</string> - <string>UIView</string> - <string>UITabBar</string> - <string>UIToolbar</string> - </object> - </object> - <object class="NSMutableDictionary" key="toOneOutletInfosByName"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>detailDescriptionLabel</string> - <string>help</string> - <string>tb</string> - <string>toolbar</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="IBToOneOutletInfo"> - <string key="name">detailDescriptionLabel</string> - <string key="candidateClassName">UILabel</string> - </object> - <object class="IBToOneOutletInfo"> - <string key="name">help</string> - <string key="candidateClassName">UIView</string> - </object> - <object class="IBToOneOutletInfo"> - <string key="name">tb</string> - <string key="candidateClassName">UITabBar</string> - </object> - <object class="IBToOneOutletInfo"> - <string key="name">toolbar</string> - <string key="candidateClassName">UIToolbar</string> - </object> - </object> - </object> - <object class="IBClassDescriptionSource" key="sourceIdentifier"> - <string key="majorKey">IBProjectSource</string> - <string key="minorKey">./Classes/DetailViewController.h</string> - </object> - </object> - </object> - </object> - <int key="IBDocument.localizationMode">0</int> - <string key="IBDocument.TargetRuntimeIdentifier">IBIPadFramework</string> - <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies"> - <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string> - <integer value="3100" key="NS.object.0"/> - </object> - <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> - <int key="IBDocument.defaultPropertyAccessControl">3</int> - <object class="NSMutableDictionary" key="IBDocument.LastKnownImageSizes"> - <bool key="EncodedWithXMLCoder">YES</bool> - <object class="NSArray" key="dict.sortedKeys"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>pan_gesture_icon.png</string> - <string>pinch_gesture_icon.png</string> - <string>select_mode.png</string> - <string>zoom_mode_icon.png</string> - </object> - <object class="NSMutableArray" key="dict.values"> - <bool key="EncodedWithXMLCoder">YES</bool> - <string>{80, 80}</string> - <string>{80, 80}</string> - <string>{43, 30}</string> - <string>{41, 30}</string> - </object> - </object> - <string key="IBCocoaTouchPluginVersion">933</string> - </data> -</archive> +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<document type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="3.0" toolsVersion="4514" systemVersion="13A598" targetRuntime="iOS.CocoaTouch.iPad" propertyAccessControl="none"> + <dependencies> + <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="3747"/> + </dependencies> + <objects> + <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="DetailViewController"> + <connections> + <outlet property="help" destination="3" id="13"/> + </connections> + </placeholder> + <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/> + <view alpha="0.89999997615814209" contentMode="scaleAspectFill" id="3"> + <rect key="frame" x="0.0" y="0.0" width="561" height="471"/> + <autoresizingMask key="autoresizingMask"/> + <subviews> + <textView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleToFill" showsHorizontalScrollIndicator="NO" editable="NO" textAlignment="right" id="9"> + <rect key="frame" x="0.0" y="13" width="529" height="93"/> + <autoresizingMask key="autoresizingMask"/> + <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/> + <string key="text">This is the very first ROOT's graphics demo program for iOS (iPad only at the moment). It shows several demos ("tutorials") and has some options.</string> + <fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="18"/> + <textInputTraits key="textInputTraits" autocapitalizationType="sentences"/> + </textView> + <textView clipsSubviews="YES" userInteractionEnabled="NO" alpha="0.89999997615814209" contentMode="scaleToFill" showsHorizontalScrollIndicator="NO" editable="NO" text="In "zoom" mode you can zoom/unzoom, scroll pad's contents, using pinch gesture or double tap gesture." textAlignment="right" id="11"> + <rect key="frame" x="83" y="103" width="446" height="60"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <color key="backgroundColor" red="1" green="1" blue="1" alpha="0.0" colorSpace="calibratedRGB"/> + <fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="18"/> + <textInputTraits key="textInputTraits" autocapitalizationType="sentences"/> + </textView> + <imageView userInteractionEnabled="NO" contentMode="scaleToFill" image="zoom_mode_icon.png" id="10" userLabel="Image View"> + <rect key="frame" x="15" y="109" width="65" height="48"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/> + </imageView> + <textView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleToFill" showsHorizontalScrollIndicator="NO" editable="NO" text="Gestures, which you can use in the current mode, are shown by pictograms. You can tap on a pictogram to read a hint." id="12"> + <rect key="frame" x="20" y="179" width="340" height="98"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/> + <fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="18"/> + <textInputTraits key="textInputTraits" autocapitalizationType="sentences"/> + </textView> + <imageView userInteractionEnabled="NO" contentMode="scaleToFill" image="pinch_gesture_icon.png" id="8"> + <rect key="frame" x="346" y="179" width="80" height="80"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + </imageView> + <imageView userInteractionEnabled="NO" contentMode="scaleToFill" image="pan_gesture_icon.png" id="7"> + <rect key="frame" x="449" y="179" width="80" height="80"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + </imageView> + <imageView userInteractionEnabled="NO" contentMode="scaleToFill" image="select_mode.png" id="6"> + <rect key="frame" x="15" y="293" width="71" height="44"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/> + </imageView> + <textView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleToFill" showsHorizontalScrollIndicator="NO" editable="NO" text="In selection mode, you can rotate 3D objects like lego or surface or pick axis/histograms (no editor in this demo)." textAlignment="center" id="5"> + <rect key="frame" x="94" y="285" width="435" height="100"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/> + <fontDescription key="fontDescription" name="Helvetica" family="Helvetica" pointSize="18"/> + <textInputTraits key="textInputTraits" autocapitalizationType="sentences"/> + </textView> + <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" id="4"> + <rect key="frame" x="201" y="393" width="158" height="58"/> + <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> + <fontDescription key="fontDescription" name="Helvetica-Bold" family="Helvetica" pointSize="15"/> + <state key="normal" title="Hide"> + <color key="titleShadowColor" white="0.5" alpha="1" colorSpace="calibratedWhite"/> + </state> + <connections> + <action selector="showHelp" destination="-1" eventType="touchUpInside" id="14"/> + </connections> + </button> + </subviews> + <color key="backgroundColor" white="0.5" alpha="1" colorSpace="calibratedWhite"/> + <simulatedOrientationMetrics key="simulatedOrientationMetrics" orientation="landscapeRight"/> + </view> + </objects> + <resources> + <image name="pan_gesture_icon.png" width="80" height="80"/> + <image name="pinch_gesture_icon.png" width="80" height="80"/> + <image name="select_mode.png" width="43" height="30"/> + <image name="zoom_mode_icon.png" width="41" height="30"/> + </resources> +</document> \ No newline at end of file diff --git a/test/ios/Tutorials/Tutorials/RootViewController.mm b/test/ios/Tutorials/Tutorials/RootViewController.mm index e4b400d642479..06c0db1d20396 100644 --- a/test/ios/Tutorials/Tutorials/RootViewController.mm +++ b/test/ios/Tutorials/Tutorials/RootViewController.mm @@ -1,4 +1,4 @@ -#import <stdlib.h> +#import <cstdlib> #import "DetailViewController.h" #import "RootViewController.h" @@ -6,163 +6,142 @@ #import "DemoHelper.h" #import "DemoBase.h" -namespace { - -enum { - nROOTDemos = 6 -}; - -} +const NSInteger nROOTDemos = 6; @implementation RootViewController { NSMutableArray *tutorialNames; NSMutableArray *tutorialIcons; + NSString * cellReuseIdentifier; + ROOT::iOS::Demos::DemoBase *demos[nROOTDemos]; } @synthesize detailViewController; //_________________________________________________________________ -- (void)viewDidLoad +- (void) dealloc { - NSString *filePath = [[NSBundle mainBundle] pathForResource : @"h2poly" ofType : @"root"]; + for (unsigned i = 0; i < nROOTDemos; ++i) + delete demos[i]; +} + +#pragma mark - view lifecycle. + +//_________________________________________________________________ +- (void) viewDidLoad +{ + NSString * const filePath = [[NSBundle mainBundle] pathForResource : @"h2poly" ofType : @"root"]; if (!ROOT::iOS::Demos::CreateTutorials(demos, [filePath cStringUsingEncoding : [NSString defaultCStringEncoding]])) { NSLog(@"Failed to create demos"); - exit(1); + std::exit(1);//WOW??? } tutorialNames = [[NSMutableArray alloc] init]; - [tutorialNames addObject:@"Hsimple"]; - [tutorialNames addObject:@"Surface"]; - [tutorialNames addObject:@"Polar graph"]; - [tutorialNames addObject:@"Lego"]; - [tutorialNames addObject:@"Exclusion graph"]; - [tutorialNames addObject:@"TH2Poly from file"]; + [tutorialNames addObject : @"Hsimple"]; + [tutorialNames addObject : @"Surface"]; + [tutorialNames addObject : @"Polar graph"]; + [tutorialNames addObject : @"Lego"]; + [tutorialNames addObject : @"Exclusion graph"]; + [tutorialNames addObject : @"TH2Poly from file"]; tutorialIcons = [[NSMutableArray alloc] init]; - [tutorialIcons addObject:@"hsimple_icon_n.png"]; - [tutorialIcons addObject:@"surface_icon_n.png"]; - [tutorialIcons addObject:@"polar_icon_n.png"]; - [tutorialIcons addObject:@"lego_icon_n.png"]; - [tutorialIcons addObject:@"exclusion_icon_n.png"]; - [tutorialIcons addObject:@"h2poly_icon.png"]; + [tutorialIcons addObject : @"hsimple_icon_n.png"]; + [tutorialIcons addObject : @"surface_icon_n.png"]; + [tutorialIcons addObject : @"polar_icon_n.png"]; + [tutorialIcons addObject : @"lego_icon_n.png"]; + [tutorialIcons addObject : @"exclusion_icon_n.png"]; + [tutorialIcons addObject : @"h2poly_icon.png"]; + + cellReuseIdentifier = @"Cell"; //Set table view's color, row height, separator's color //(I want separator to be invisible). self.tableView.rowHeight = 72.f; self.tableView.backgroundColor = [UIColor lightGrayColor]; - self.tableView.separatorColor = [UIColor lightGrayColor]; + self.tableView.separatorColor = [UIColor clearColor]; //This code was generated by ide. [super viewDidLoad]; - self.clearsSelectionOnViewWillAppear = NO; - self.contentSizeForViewInPopover = CGSizeMake(320.0, 500.0);//Default height was 600., I've changed it to 500. + self.preferredContentSize = CGSizeMake(320.0, 500.0); } -//_________________________________________________________________ -- (void) viewWillAppear : (BOOL)animated -{ - [super viewWillAppear : animated]; -} +#pragma mark - Table view delegate and data source. //_________________________________________________________________ -- (void) viewDidAppear : (BOOL)animated +- (NSInteger) numberOfSectionsInTableView : (UITableView *) tableView { - [super viewDidAppear : animated]; -} +#pragma unused(tableView) -//_________________________________________________________________ -- (void) viewWillDisappear : (BOOL)animated -{ - [super viewWillDisappear : animated]; + return 1; } //_________________________________________________________________ -- (void) viewDidDisappear : (BOOL)animated +- (NSInteger) tableView : (UITableView *) tableView numberOfRowsInSection : (NSInteger) section { - [super viewDidDisappear : animated]; -} +#pragma unused(tableView, section) -//_________________________________________________________________ -- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation)interfaceOrientation -{ - return YES; + return nROOTDemos; } //_________________________________________________________________ -- (NSInteger) numberOfSectionsInTableView : (UITableView *)tableView +- (UITableViewCell *) tableView : (UITableView *)tableView cellForRowAtIndexPath : (NSIndexPath *) indexPath { - return 1; - -} + assert(tableView != nil && "tableView:cellForRowAtIndexPath:, parameter 'tableView' is nil"); + assert(indexPath != nil && "tableView:cellForRowAtIndexPath:, parameter 'indexPath' is nil"); + assert(indexPath.row >= 0 && indexPath.row < nROOTDemos && + "tableView:cellForRowAtIndexPath:, row is out of bounds"); -//_________________________________________________________________ -- (NSInteger) tableView : (UITableView *)tableView numberOfRowsInSection : (NSInteger)section -{ - return [tutorialNames count]; -} - -//_________________________________________________________________ -- (UITableViewCell *) tableView : (UITableView *)tableView cellForRowAtIndexPath : (NSIndexPath *)indexPath -{ - static NSString *CellIdentifier = @"Cell"; - - UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier : CellIdentifier]; - if (cell == nil) - cell = [[UITableViewCell alloc] initWithStyle : UITableViewCellStyleDefault reuseIdentifier : CellIdentifier]; + UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier : cellReuseIdentifier]; + if (!cell) + cell = [[UITableViewCell alloc] initWithStyle : UITableViewCellStyleDefault reuseIdentifier : cellReuseIdentifier]; // Configure the cell. - const BOOL useDarkBackground = indexPath.row % 2; - NSString *backgroundImagePath = [[NSBundle mainBundle] pathForResource : useDarkBackground ? @"DarkBackground" : @"LightBackground" ofType : @"png"]; + const bool useDarkBackground = indexPath.row % 2; + NSString * const backgroundImagePath = [[NSBundle mainBundle] pathForResource : useDarkBackground ? @"DarkBackground" : @"LightBackground" ofType : @"png"]; - UIImage *backgroundImage = [[UIImage imageWithContentsOfFile : backgroundImagePath] stretchableImageWithLeftCapWidth : 0.f topCapHeight : 1.f]; + UIImage * const backgroundImage = [[UIImage imageWithContentsOfFile : backgroundImagePath] stretchableImageWithLeftCapWidth : 0.f topCapHeight : 1.f]; cell.backgroundView = [[UIImageView alloc] initWithImage : backgroundImage]; cell.backgroundView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight; cell.backgroundView.frame = cell.bounds; - + cell.textLabel.text = [tutorialNames objectAtIndex : indexPath.row]; + cell.textLabel.backgroundColor = [UIColor clearColor]; cell.imageView.image = [UIImage imageNamed : [tutorialIcons objectAtIndex : indexPath.row]]; + cell.imageView.clipsToBounds = YES; + + cell.imageView.layer.borderColor = [UIColor blackColor].CGColor; + cell.imageView.layer.borderWidth = 1.; return cell; } //_________________________________________________________________ -- (void) tableView : (UITableView *)tableView didSelectRowAtIndexPath : (NSIndexPath *)indexPath +- (void) tableView : (UITableView *) tableView didSelectRowAtIndexPath : (NSIndexPath *) indexPath { +#pragma unused(tableView) + + assert(indexPath != nil && "tableView:didSelectRowAtIndexPath:, parameter 'indexPath' is nil"); + assert(indexPath.row >= 0 && indexPath.row < nROOTDemos && + "tableView:didSelectRowAtIndexPath:, row is out of bounds"); [self.detailViewController dismissPopover]; [self.detailViewController setActiveDemo : demos[indexPath.row]]; -} -//_________________________________________________________________ -- (void) didReceiveMemoryWarning -{ - // Releases the view if it doesn't have a superview. - [super didReceiveMemoryWarning]; - // Relinquish ownership any cached data, images, etc that aren't in use. +// + [self.tableView deselectRowAtIndexPath:indexPath animated : NO]; } -//_________________________________________________________________ -- (void) viewDidUnload -{ - // Relinquish ownership of anything that can be recreated in viewDidLoad or on demand. - // For example: self.myOutlet = nil; -} +#pragma mark - Interface rotation. //_________________________________________________________________ -- (void) dealloc +- (BOOL) shouldAutorotateToInterfaceOrientation : (UIInterfaceOrientation) interfaceOrientation { - for (unsigned i = 0; i < nROOTDemos; ++i) - delete demos[i]; -} +#pragma unused(interfaceOrientation) -//_________________________________________________________________ -- (void) tableView : (UITableView *)tableView willDisplayCell : (UITableViewCell *)cell forRowAtIndexPath : (NSIndexPath *)indexPath -{ - [[cell textLabel] setBackgroundColor : [UIColor clearColor]]; - [[cell detailTextLabel] setBackgroundColor : [UIColor clearColor]]; + return YES; } + @end diff --git a/test/ios/Tutorials/Tutorials/TutorialsAppDelegate.mm b/test/ios/Tutorials/Tutorials/TutorialsAppDelegate.mm index a8cd3cfe15b5a..862a412af15fd 100644 --- a/test/ios/Tutorials/Tutorials/TutorialsAppDelegate.mm +++ b/test/ios/Tutorials/Tutorials/TutorialsAppDelegate.mm @@ -13,12 +13,23 @@ @implementation TutorialsAppDelegate { @synthesize detailViewController; //_________________________________________________________________ -- (BOOL) application : (UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions +- (void) dealloc { + delete rootApp; +} + +//_________________________________________________________________ +- (BOOL) application : (UIApplication *) application didFinishLaunchingWithOptions : (NSDictionary *) launchOptions +{ +#pragma unused(application, launchOptions) + // Override point for customization after application launch. // Add the split view controller's view to the window and display. rootApp = new TApplication("iosApp", 0, 0); + // + self.splitViewController.presentsWithGesture = NO; + // self.window.rootViewController = self.splitViewController; [self.window makeKeyAndVisible]; @@ -26,42 +37,57 @@ - (BOOL) application : (UIApplication *)application didFinishLaunchingWithOption } //_________________________________________________________________ -- (void)applicationWillResignActive:(UIApplication *)application +- (void) applicationWillResignActive : (UIApplication *) application { +#pragma unused(application) + /* - Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + Sent when the application is about to move from active to inactive state. This can occur for certain types of + temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application + and it begins the transition to the background state. Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. */ } //_________________________________________________________________ -- (void)applicationDidEnterBackground:(UIApplication *)application +- (void) applicationDidEnterBackground : (UIApplication *) application { +#pragma unused(application) + /* - Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + Use this method to release shared resources, save user data, invalidate timers, and store enough application + state information to restore your application to its current state in case it is terminated later. If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. */ } //_________________________________________________________________ -- (void)applicationWillEnterForeground:(UIApplication *)application +- (void) applicationWillEnterForeground : (UIApplication *) application { +#pragma unused(application) + /* - Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. + Called as part of the transition from the background to the inactive state; here + you can undo many of the changes made on entering the background. */ } //_________________________________________________________________ -- (void)applicationDidBecomeActive:(UIApplication *)application +- (void) applicationDidBecomeActive : (UIApplication *) application { +#pragma unused(application) + /* - Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + Restart any tasks that were paused (or not yet started) while the application was inactive. If the + application was previously in the background, optionally refresh the user interface. */ } //_________________________________________________________________ -- (void)applicationWillTerminate:(UIApplication *)application +- (void) applicationWillTerminate : (UIApplication *) application { +#pragma unused(application) + /* Called when the application is about to terminate. Save data if appropriate. @@ -69,10 +95,4 @@ - (void)applicationWillTerminate:(UIApplication *)application */ } -//_________________________________________________________________ -- (void)dealloc -{ - delete rootApp; -} - @end diff --git a/test/periodic/XSGui.cxx b/test/periodic/XSGui.cxx index 440aed0d52a2b..adee1839f5424 100644 --- a/test/periodic/XSGui.cxx +++ b/test/periodic/XSGui.cxx @@ -240,7 +240,7 @@ XSGui::ProcessMessage(Long_t msg, Long_t param1, Long_t) //---- Main program ---------------------------------------------------------- -TROOT root("GUI", "GUI test environement"); +TROOT root("GUI", "GUI test environment"); /* ----- main ----- */ int main(int ac, char *av[]) diff --git a/test/rootDownloadData.cmake b/test/rootDownloadData.cmake new file mode 100644 index 0000000000000..3b13b1d97cfa9 --- /dev/null +++ b/test/rootDownloadData.cmake @@ -0,0 +1,28 @@ +#--------------------------------------------------------------------------------------------------- +# ROOT download test data files +# Script arguments: +# DST destination directory + +if(NOT DST) + set(DST .) +endif() + +set(rootsite http://root.cern.ch/files) +set(timeout 100) + +if(NOT EXISTS ${DST}/h1) + foreach(f dstarmb.root dstarp1a.root dstarp1b.root dstarp2.root) + file(DOWNLOAD ${rootsite}/h1/${f} ${DST}/h1/${f} TIMEOUT ${timeout} SHOW_PROGRESS) + endforeach() +else() + message(STATUS "Already existing files in ${DST}/h1") +endif() + +if(NOT EXISTS ${DST}/event) + foreach(n 1 2 3 4 5 6 7 8 9 10) + file(DOWNLOAD ${rootsite}/data/event_${n}.root ${DST}/event/event_${n}.root TIMEOUT ${timeout} SHOW_PROGRESS) + endforeach() +else() + message(STATUS "Already existing files in ${DST}/event") +endif() + diff --git a/test/sqlitetest.cxx b/test/sqlitetest.cxx new file mode 100644 index 0000000000000..95744622b0bca --- /dev/null +++ b/test/sqlitetest.cxx @@ -0,0 +1,215 @@ +#include <iostream> +#include <iomanip> +#include <unistd.h> + +#include "TSQLServer.h" +#include "TSQLResult.h" +#include "TSQLRow.h" +#include "TSQLStatement.h" +#include "TSQLTableInfo.h" +#include "TTimeStamp.h" +#include "TList.h" + +int main() { + + // Create a new DB called testdb: + TSQLServer *serv=TSQLServer::Connect("sqlite://testdb.sqlite", "", ""); + if (serv == NULL) { + std::cerr << "Connection failed!" << std::endl; + _exit(1); + } + + // First, some debug-checks: + std::cout << "DB: " << serv->GetDB() << std::endl; + std::cout << "DBMS: " << serv->GetDBMS() << std::endl; + std::cout << "HOST: " << serv->GetHost() << std::endl; + std::cout << "PORT: " << serv->GetPort() << std::endl; + std::cout << "Info: " << serv->ServerInfo() << std::endl; + + // Create table: + if ((serv!=0) && serv->IsConnected()) { + // create statement instance + TSQLStatement* stmt = serv->Statement("CREATE TABLE TESTTABLE (ID1 FOO, ID2 FOO, ID3 FOO, ID4 FOO, ID5 FOO, ID6 FOO, ID7 FOO, ID8 FOO, ID9 FOO, ID10 FOO)"); + // process statement + stmt->Process(); + // destroy object + delete stmt; + } + + serv->StartTransaction();//Exec("BEGIN TRANSACTION;"); + + // Fill with data: + TSQLStatement* stmt = serv->Statement("INSERT INTO TESTTABLE (ID1, ID2, ID3, ID4, ID5, ID6, ID7, ID8, ID9, ID10) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?);", 100); + std::cout << "statement pars: " << stmt->GetNumParameters() << std::endl; + + + for (int n=0;n<10;n++) { + if (stmt->NextIteration()) { + stmt->SetInt(0, n); + stmt->SetUInt(1, n); + stmt->SetLong(2, n); + stmt->SetULong64(3, n); + stmt->SetDate(4, 2013,1,n); + stmt->SetTime(5, 1,1,n); + stmt->SetDatime(6, 2013,1,n,1,1,n); + stmt->SetTimestamp(7, 2013,1,1,1,1,n,102+n); + TString foo; + foo.Form("testbinary %d", n); + void *binary=const_cast<char*>(foo.Data()); + stmt->SetBinary(8, binary, foo.Length()); + stmt->SetString(9, Form("%d", n), 200); + } + } + + stmt->Process(); + delete stmt; + + serv->Commit(); + + delete serv; + + std::cout << "Testing tool created DB with sample data. Now reopening and selecting all." << std::endl; + + serv=TSQLServer::Connect("sqlite://testdb.sqlite", "", ""); + if (serv == NULL) { + std::cerr << "Connection failed!" << std::endl; + _exit(1); + } + + std::cout << "Select table names:" << std::endl; + TSQLResult *res=serv->GetTables(NULL, NULL); + + int fields=res->GetFieldCount(); + std::cout << "Table list has field count: " << fields << std::endl; + + int rowcount=res->GetRowCount(); + std::cout << "Table list has row count: " << rowcount << std::endl; + + TSQLRow *row=NULL; + while ((row=res->Next()) != NULL) { + for (int i=0; i<fields; i++) { + std::cout << row->GetField(i); + TSQLResult *res2=serv->GetColumns(NULL, row->GetField(i), NULL); + if (res2 == NULL) continue; + std::cout << "|"; + int fields2=res2->GetFieldCount(); + std::cout << "Cols: " << fields2 << " "; + TSQLRow *row2=NULL; + while ((row2=res2->Next()) != NULL) { + std::cout << "("; + for (int ii=0; ii<fields2; ii++) { + if (row2->GetField(ii) == NULL) continue; + std::cout << row2->GetField(ii) << "|"; + } + std::cout << ")"; + delete row2; + } + } + std::cout << std::endl; + delete row; + } + delete res; + std::cout << std::endl; + + std::cout << "Alternate way using GetTablesList:" << std::endl; + serv->GetTablesList()->Print(); + + std::cout << "Completed listing tables. Now selecting * from testtable, first using Query() and string output:" << std::endl; + row=NULL; + res=serv->Query("SELECT * from TESTTABLE;"); + fields=res->GetFieldCount(); + for (int i=0; i<fields; i++) { + std::cout << "|" << std::setw(19) << res->GetFieldName(i) << "|"; + } + std::cout << std::endl; + while ((row=res->Next()) != NULL) { + for (int i=0; i<fields; i++) { + std::cout << "|" << std::setw(19) << row->GetField(i) << "|"; + } + std::cout << std::endl; + delete row; + } + delete res; + std::cout << std::endl; + + std::cout << "Now using TSQLStatement-methods with appropriate types:" << std::endl; + + stmt = serv->Statement("SELECT * FROM TESTTABLE;", 100); + // process statement + if (stmt->Process()) { + std::cout << "iteration..." << std::endl; + // store result of statement in buffer + stmt->StoreResult(); + + // display info about selected field + std::cout << "NumFields = " << stmt->GetNumFields() << std::endl; + for (int n=0;n<stmt->GetNumFields();n++) { + std::cout << "|" << std::setw(19) << stmt->GetFieldName(n) << "|"; + } + std::cout << std::endl; + + // extract rows one after another + while (stmt->NextResultRow()) { + Int_t id1 = stmt->GetInt(0); + std::cout << "|" << std::setw(19) << id1 << "|"; + + UInt_t id2 = stmt->GetUInt(1); + std::cout << "|" << std::setw(19) << id2 << "|"; + + Long_t id3 = stmt->GetLong(2); + std::cout << "|" << std::setw(19) << id3 << "|"; + + ULong64_t id4 = stmt->GetULong64(3); + std::cout << "|" << std::setw(19) << id4 << "|"; + + Int_t year=0, month=0, day=0, hour=0, minute=0, second=0, frac=0; + + stmt->GetDate(4, year, month, day); + TString id5; + id5.Form("%04d-%02d-%02d %02d:%02d:%02d", year, month, day, 0, 0, 0); + std::cout << "|" << std::setw(19) << id5 << "|"; + + stmt->GetTime(5, hour, minute, second); + TString id6; + id6.Form("%04d-%02d-%02d %02d:%02d:%02d", 2000, 01, 01, hour, minute, second); + std::cout << "|" << std::setw(19) << id6 << "|"; + + stmt->GetDatime(6, year, month, day, hour, minute, second); + TString id7; + id7.Form("%04d-%02d-%02d %02d:%02d:%02d", year, month, day, hour, minute, second); + std::cout << "|" << std::setw(19) << id7 << "|"; + + stmt->GetTimestamp(7, year, month, day, hour, minute, second, frac); + TTimeStamp ts(year,month,day,hour,minute,second); + TString id8; + // Frac is in milliseconds for SQLite, thus use %3d here. + id8.Form("%04d-%02d-%02d %02d:%02d:%02d.%3d", year, month, day, hour, minute, second, frac); + std::cout << "|" << std::setw(23) << id8 << "|"; + + void* id9 = new unsigned char[1]; + Long_t binSize=1; + stmt->GetBinary(8, id9, binSize); + char* id9str = new char[binSize+1]; + memcpy(id9str, id9, binSize); + id9str[binSize]='\0'; + std::cout << "|" << std::setw(19) << id9str << "|"; + delete [] (unsigned char*) id9; + delete [] id9str; + + TString id10 = stmt->GetString(9); + std::cout << "|" << std::setw(19) << id10 << "|"; + + std::cout << std::endl; + } + } + delete stmt; + + // Test tableinfo: + std::cout << "Tableinfo:" << std::endl; + TSQLTableInfo *ti=serv->GetTableInfo("TESTTABLE"); + ti->Print(); + + delete serv; + + return 0; +} diff --git a/test/stress.cxx b/test/stress.cxx index 52adc1209e8a5..f2eef8424e5a8 100644 --- a/test/stress.cxx +++ b/test/stress.cxx @@ -419,18 +419,21 @@ void stress4() ntotout += f.GetBytesWritten(); //Compare results of fit with expected parameters - Double_t th0=395.085, th5=620.957, th10=151.308; - Double_t dp0 = TMath::Abs((f2form->GetParameter(0) -th0)/th0); - Double_t dp5 = TMath::Abs((f2form->GetParameter(5) -th5)/th5); - Double_t dp10 = TMath::Abs((f2form->GetParameter(10)-th10)/th10); Bool_t OK = kTRUE; - if (dp0 > 1.e-2 || dp5 > 1.e-2 || dp10 > 1.e-2) OK = kFALSE; - if (OK) printf("OK\n"); - else { - printf("failed\n"); - printf("%-8s dp0=%g, dp5=%g, dp10=%g\n"," ",dp0,dp5,dp10); - printf("%-8s p0=%g, p5=%g, p10=%g\n"," ",f2form->GetParameter(0),f2form->GetParameter(5),f2form->GetParameter(10)); + for (int k = 0; k < 3; ++k) { + for (int l = 1; l < 5; ++l) { + int idx = k*5+l; + Double_t dp0 = TMath::Abs((f2form->GetParameter(idx) -f2params[idx])); + if (f2params[idx] != 0.) dp0 /= f2params[idx]; + bool testok = (dp0 < 5.e-2); + if (!testok) { + printf("\nfailed: ipar=%d delta=%g, par=%g, nom=%g",idx,dp0,f2form->GetParameter(idx),f2params[idx]); + } + OK &= testok; + } } + if (OK) printf("OK\n"); + else printf("\ntest failed !\n"); if (gPrintSubBench) { printf("Test 4 : "); gBenchmark->Show("stress");gBenchmark->Start("stress"); } } @@ -656,7 +659,7 @@ void stress7() helist->Write(); hcut->Write(); - // now loop on eventlist explicitely and fill helist again + // now loop on eventlist explicitly and fill helist again Float_t pxr; ntuple->SetBranchAddress("px",&pxr); TH1F *helistc = (TH1F*)helist->Clone(); diff --git a/test/stressGraphics.cxx b/test/stressGraphics.cxx index 4c50547e91ed7..fe156b1232ca2 100644 --- a/test/stressGraphics.cxx +++ b/test/stressGraphics.cxx @@ -42,6 +42,7 @@ #include <TH2.h> #include <TNtuple.h> #include <TProfile.h> +#include "TString.h" #include <TStyle.h> #include <TCanvas.h> @@ -53,6 +54,8 @@ #include <TMarker.h> #include <TPolyLine.h> #include <TLatex.h> +#include <TMathText.h> +#include <TLegend.h> #include <TEllipse.h> #include <TCurlyArc.h> #include <TArc.h> @@ -77,55 +80,60 @@ Int_t StatusPrint (TString &filename, Int_t id, const TString &title, Int_ Int_t AnalysePS (const TString &filename); Int_t FileSize (char *filename); TCanvas *StartTest (Int_t w, Int_t h); -void TestReport1 (TCanvas *C, const TString &title); -void TestReport2 (); +void TestReport1 (TCanvas *C, const TString &title, Int_t IPS=0); +void TestReport2 (Int_t IPS=0); void DoCcode (TCanvas *C); +TString stime(time_t* t, bool utc = false, bool display_time_zone = true); + // Tests functions. -void tline (); -void tmarker (); -void tpolyline (); -void patterns (); -void ttext1 (); -void ttext2 (); -void tlatex1 (); -void tlatex2 (); -void tlatex3 (); -void tlatex4 (); -void tlatex5 (); -void kerning (); +void clonepad (); +void earth (); +void feynman (); +void hbars (); void itbf (); -void transpad (); +void kerning (); +void labels1 (); +void ntuple1 (); +void options2d1 (); +void options2d2 (); +void options2d3 (); +void options2d4 (); +void options2d5 (); +void parallelcoord (); +void patterns (); +void quarks (); void statfitparam (); +void tellipse (); void tgaxis1 (); void tgaxis2 (); void tgaxis3 (); void tgaxis4 (); -void labels1 (); -void tellipse (); -void feynman (); +void tgaxis5 (); void tgraph1 (); void tgraph2 (); -void tgraph3 (); -void tmultigraph1 (); -void tmultigraph2 (); -void options2d1 (); -void options2d2 (); -void options2d3 (); -void options2d4 (); -void options2d5 (); -void earth (); void tgraph2d1 (); void tgraph2d2 (); void tgraph2d3 (); -void ntuple1 (); -void quarks (); +void tgraph3 (); void timage (); -void zoomtf1 (); -void zoomfit (); -void parallelcoord (); -void clonepad (); +void tlatex1 (); +void tlatex2 (); +void tlatex3 (); +void tlatex4 (); +void tlatex5 (); +void tline (); +void tmarker (); +void tmathtext (); +void tmultigraph1 (); +void tmultigraph2 (); +void tpolyline (); +void transpad (); +void ttext1 (); +void ttext2 (); void waves (); +void zoomfit (); +void zoomtf1 (); // Auxiliary functions void patterns_box (Int_t pat, Double_t x1, Double_t y1, Double_t x2, Double_t y2); @@ -138,6 +146,7 @@ void cleanup (); // Global variables. Int_t gVerbose; Int_t gTestNum; +Int_t gTestsFailed; Int_t gPS1RefNb[50]; Int_t gPS1ErrNb[50]; Int_t gPDFRefNb[50]; @@ -153,7 +162,8 @@ Int_t gPS2ErrNb[50]; Bool_t gOptionR; Bool_t gOptionK; TH2F *gH2; -TFile *gLocalFile; +TFile *gHsimple; +TFile *gCernstaff; char gCfile[16]; char outfile[16]; char gLine[80]; @@ -215,22 +225,41 @@ void stressGraphics(Int_t verbose = 0) gROOT->SetStyle("Classic"); // Check if $ROOTSYS/tutorials/hsimple.root exists - gLocalFile = new TFile("$(ROOTSYS)/tutorials/hsimple.root"); - if (gLocalFile->IsZombie()) { - delete gLocalFile; - gLocalFile = new TFile("hsimple.root"); - if (gLocalFile->IsZombie()) { - delete gLocalFile; + gHsimple = new TFile("$(ROOTSYS)/tutorials/hsimple.root"); + if (gHsimple->IsZombie()) { + delete gHsimple; + gHsimple = new TFile("hsimple.root"); + if (gHsimple->IsZombie()) { + delete gHsimple; printf("Create $(ROOTSYS)/tutorials/hsimple.root\n"); gROOT->Macro("$(ROOTSYS)/tutorials/hsimple.C"); - gLocalFile = new TFile("$(ROOTSYS)/tutorials/hsimple.root"); - if (gLocalFile->IsZombie()) { - delete gLocalFile; + gHsimple = new TFile("$(ROOTSYS)/tutorials/hsimple.root"); + if (gHsimple->IsZombie()) { + delete gHsimple; printf("Could not create $(ROOTSYS)/tutorials/hsimple.root\n"); return; } } } + + // Check if $ROOTSYS/tutorials/tree/cernstaff.root exists + gCernstaff = new TFile("$(ROOTSYS)/tutorials/tree/cernstaff.root"); + if (gCernstaff->IsZombie()) { + delete gCernstaff; + gCernstaff = new TFile("cernstaff.root"); + if (gCernstaff->IsZombie()) { + delete gCernstaff; + printf("Create $(ROOTSYS)/tutorials/tree/cernstaff.root\n"); + gROOT->Macro("$(ROOTSYS)/tutorials/tree/cernbuild.C(0,0)"); + gCernstaff = new TFile("$(ROOTSYS)/tutorials/tree/cernstaff.root"); + if (gCernstaff->IsZombie()) { + delete gCernstaff; + printf("Could not create $(ROOTSYS)/tutorials/tree/cernstaff.root\n"); + return; + } + } + } + gErrorIgnoreLevel = 0; // Read the reference file "stressGraphics.ref" @@ -239,7 +268,7 @@ void stressGraphics(Int_t verbose = 0) Int_t i = -1; while (fgets(line,160,sg)) { if (i>=0) { - sscanf(&line[8] ,"%d",&gPS1RefNb[i]); + sscanf(&line[7] ,"%d",&gPS1RefNb[i]); sscanf(&line[18] ,"%d",&gPS1ErrNb[i]); sscanf(&line[28] ,"%d",&gPDFRefNb[i]); sscanf(&line[38] ,"%d",&gPDFErrNb[i]); @@ -249,7 +278,7 @@ void stressGraphics(Int_t verbose = 0) sscanf(&line[78] ,"%d",&gJPGErrNb[i]); sscanf(&line[88] ,"%d",&gPNGRefNb[i]); sscanf(&line[98] ,"%d",&gPNGErrNb[i]); - sscanf(&line[108],"%d",&gPS2RefNb[i]); + sscanf(&line[107],"%d",&gPS2RefNb[i]); sscanf(&line[118],"%d",&gPS2ErrNb[i]); } i++; @@ -259,21 +288,22 @@ void stressGraphics(Int_t verbose = 0) gRandom->SetSeed(65539); if (gOptionR) { - cout << "Test# PS1Ref# PS1Err# PDFRef# PDFErr# GIFRef# GIFErr# JPGRef# JPGErr# PNGRef# PNGErr# PS2Ref# PS2Err#" <<endl; + std::cout << "Test# PS1Ref# PS1Err# PDFRef# PDFErr# GIFRef# GIFErr# JPGRef# JPGErr# PNGRef# PNGErr# PS2Ref# PS2Err#" <<std::endl; } else { - cout << "**********************************************************************" <<endl; - cout << "* Starting Graphics - S T R E S S suite *" <<endl; - cout << "**********************************************************************" <<endl; + std::cout << "**********************************************************************" <<std::endl; + std::cout << "* Starting Graphics - S T R E S S suite *" <<std::endl; + std::cout << "**********************************************************************" <<std::endl; } - gVerbose = verbose; - gTestNum = 0; + gVerbose = verbose; + gTestNum = 0; + gTestsFailed = 0; gBenchmark->Start("stressGraphics"); if (!gOptionR) { - cout << "* Starting Basic Graphics - S T R E S S *" <<endl; - cout << "**********************************************************************" <<endl; + std::cout << "* Starting Basic Graphics - S T R E S S *" <<std::endl; + std::cout << "**********************************************************************" <<std::endl; } tline (); tmarker (); @@ -288,17 +318,19 @@ void stressGraphics(Int_t verbose = 0) tlatex5 (); kerning (); itbf (); + tmathtext (); transpad (); statfitparam (); if (!gOptionR) { - cout << "**********************************************************************" <<endl; - cout << "* Starting High Level 2D Primitives - S T R E S S *" <<endl; - cout << "**********************************************************************" <<endl; + std::cout << "**********************************************************************" <<std::endl; + std::cout << "* Starting High Level 2D Primitives - S T R E S S *" <<std::endl; + std::cout << "**********************************************************************" <<std::endl; } tgaxis1 (); tgaxis2 (); tgaxis3 (); tgaxis4 (); + tgaxis5 (); labels1 (); tellipse (); feynman (); @@ -309,9 +341,9 @@ void stressGraphics(Int_t verbose = 0) tmultigraph2 (); waves (); if (!gOptionR) { - cout << "**********************************************************************" <<endl; - cout << "* Starting High Level 3D Primitives - S T R E S S *" <<endl; - cout << "**********************************************************************" <<endl; + std::cout << "**********************************************************************" <<std::endl; + std::cout << "* Starting High Level 3D Primitives - S T R E S S *" <<std::endl; + std::cout << "**********************************************************************" <<std::endl; } options2d1 (); options2d2 (); @@ -323,9 +355,9 @@ void stressGraphics(Int_t verbose = 0) tgraph2d2 (); tgraph2d3 (); if (!gOptionR) { - cout << "**********************************************************************" <<endl; - cout << "* Starting complex drawing and TPad - S T R E S S *" <<endl; - cout << "**********************************************************************" <<endl; + std::cout << "**********************************************************************" <<std::endl; + std::cout << "* Starting complex drawing and TPad - S T R E S S *" <<std::endl; + std::cout << "**********************************************************************" <<std::endl; } ntuple1 (); quarks (); @@ -333,9 +365,17 @@ void stressGraphics(Int_t verbose = 0) zoomtf1 (); zoomfit (); parallelcoord(); -///clonepad (); + clonepad (); + hbars (); if (!gOptionR) { - cout << "**********************************************************************" <<endl; + std::cout << "**********************************************************************" <<std::endl; + if (!gTestsFailed) { + std::cout << "* All the tests passed. :-)" <<std::endl; + } else { + if (gTestsFailed>1) std::cout << "* " << gTestsFailed <<" tests failed. :-(" <<std::endl; + else std::cout << "* " << gTestsFailed <<" test failed. :-(" <<std::endl; + } + std::cout << "**********************************************************************" <<std::endl; gBenchmark->Stop("stressGraphics"); @@ -391,21 +431,22 @@ Int_t StatusPrint(TString &filename, Int_t id, const TString &title, const Int_t nch = strlen(gLine); if (TMath::Abs(res-ref)<=err) { - cout << gLine; - for (Int_t i = nch; i < 67; i++) cout << "."; - cout << " OK" << endl; + std::cout << gLine; + for (Int_t i = nch; i < 67; i++) std::cout << "."; + std::cout << " OK" << std::endl; if (!gOptionK) gSystem->Unlink(filename.Data()); } else { - cout << gLine; + std::cout << gLine; Int_t ndots = 60; Int_t w = 3; if (gTestNum < 10) { ndots++; w--;} - for (Int_t i = nch; i < ndots; i++) cout << "."; - cout << setw(w) << gTestNum << " FAILED" << endl; - cout << " Result = " << res << endl; - cout << " Reference = " << ref << endl; - cout << " Error = " << TMath::Abs(res-ref) - << " (was " << err << ")"<< endl; + for (Int_t i = nch; i < ndots; i++) std::cout << "."; + std::cout << std::setw(w) << gTestNum << " FAILED" << std::endl; + std::cout << " Result = " << res << std::endl; + std::cout << " Reference = " << ref << std::endl; + std::cout << " Error = " << TMath::Abs(res-ref) + << " (was " << err << ")"<< std::endl; + gTestsFailed++; return 1; } } else { @@ -476,7 +517,7 @@ TCanvas *StartTest(Int_t w, Int_t h) //______________________________________________________________________________ -void TestReport1(TCanvas *C, const TString &title) +void TestReport1(TCanvas *C, const TString &title, Int_t IPS) { // Report 1: // Draw the canvas generate as PostScript, count the number of characters in @@ -489,9 +530,15 @@ void TestReport1(TCanvas *C, const TString &title) C->Draw(); ps1->Close(); TString psfile = outfile; - StatusPrint(psfile, gTestNum, title, AnalysePS(outfile) , - gPS1RefNb[gTestNum-1], - gPS1ErrNb[gTestNum-1]); + if (IPS) { + StatusPrint(psfile, gTestNum, title, FileSize(outfile) , + gPS1RefNb[gTestNum-1], + gPS1ErrNb[gTestNum-1]); + } else { + StatusPrint(psfile, gTestNum, title, AnalysePS(outfile) , + gPS1RefNb[gTestNum-1], + gPS1ErrNb[gTestNum-1]); + } sprintf(outfile,"sg%2.2d.pdf",gTestNum); C->cd(0); @@ -550,7 +597,7 @@ void DoCcode(TCanvas *C) //______________________________________________________________________________ -void TestReport2() +void TestReport2(Int_t IPS) { // Report 2: // Draw the canvas generate as .C, generate the corresponding PostScript @@ -564,11 +611,18 @@ void TestReport2() gROOT->ProcessLine(gCfile); gPad->SaveAs(outfile); gErrorIgnoreLevel = 0; + Int_t i; TString psfile = outfile; - Int_t i = StatusPrint(psfile,-1, " C file result", AnalysePS(outfile), - gPS2RefNb[gTestNum-1], - gPS2ErrNb[gTestNum-1]); + if (IPS) { + i = StatusPrint(psfile,-1, " C file result", FileSize(outfile), + gPS2RefNb[gTestNum-1], + gPS2ErrNb[gTestNum-1]); + } else { + i = StatusPrint(psfile,-1, " C file result", AnalysePS(outfile), + gPS2RefNb[gTestNum-1], + gPS2ErrNb[gTestNum-1]); + } sprintf(gCfile,"sg%2.2d.C",gTestNum); if (!gOptionK && !i) gSystem->Unlink(gCfile); @@ -894,14 +948,14 @@ void tlatex3() TCanvas *C = StartTest(700,500); TPaveText pt(.05,.1,.95,.8); - pt.AddText("#frac{2s}{#pi#alpha^{2}} #frac{d#sigma}{dcos#theta} (e^{+}e^{-} #rightarrow f#bar{f} ) = \ - #left| #frac{1}{1 - #Delta#alpha} #right|^{2} (1+cos^{2}#theta)"); + pt.AddText("#frac{2s}{#pi#alpha^{2}} #frac{d#sigma}{dcos#theta} (e^{+}e^{-}#rightarrowf#bar{f} ) = \ +#left| #frac{1}{1 - #Delta#alpha} #right|^{2} (1+cos^{2}#theta)"); pt.AddText("+ 4 Re #left{ #frac{2}{1 - #Delta#alpha} #chi(s) #[]{#hat{g}_{#nu}^{e}#hat{g}_{#nu}^{f} \ - (1 + cos^{2}#theta) + 2 #hat{g}_{a}^{e}#hat{g}_{a}^{f} cos#theta) } #right}"); +(1 + cos^{2}#theta) + 2 #hat{g}_{a}^{e}#hat{g}_{a}^{f} cos#theta) } #right}"); pt.AddText("+ 16#left|#chi(s)#right|^{2}\ - #left[(#hat{g}_{a}^{e}^{2} + #hat{g}_{v}^{e}^{2})\ - (#hat{g}_{a}^{f}^{2} + #hat{g}_{v}^{f}^{2})(1+cos^{2}#theta)\ - + 8 #hat{g}_{a}^{e} #hat{g}_{a}^{f} #hat{g}_{v}^{e} #hat{g}_{v}^{f}cos#theta#right] "); +#left[(#hat{g}_{a}^{e}^{2}+#hat{g}_{v}^{e}^{2})\ +(#hat{g}_{a}^{f}^{2} + #hat{g}_{v}^{f}^{2})(1+cos^{2}#theta) \ ++ 8 #hat{g}_{a}^{e} #hat{g}_{a}^{f} #hat{g}_{v}^{e} #hat{g}_{v}^{f}cos#theta#right] "); pt.SetLabel("Born equation"); pt.Draw(); @@ -1140,6 +1194,29 @@ void itbf() } +//______________________________________________________________________________ +void tmathtext() +{ + TCanvas *C = StartTest(700, 500); + + TMathText l; + l.SetTextAlign(23); + l.SetTextSize(0.06); + l.DrawMathText(0.50, 1.000, "\\prod_{j\\ge0} \\left(\\sum_{k\\ge0} a_{jk}z^k\\right) = \\sum_{n\\ge0} z^n \\left(\\sum_{k_0,k_1,\\ldots\\ge0\\atop k_0+k_1+\\cdots=n} a_{0k_0}a_{1k_1} \\cdots \\right)"); + l.DrawMathText(0.50, 0.800, "W_{\\delta_1\\rho_1\\sigma_2}^{3\\beta} = U_{\\delta_1\\rho_1\\sigma_2}^{3\\beta} + {1\\over 8\\pi^2} \\int_{\\alpha_1}^{\\alpha_2} d\\alpha_2^\\prime \\left[ {U_{\\delta_1\\rho_1}^{2\\beta} - \\alpha_2^\\prime U_{\\rho_1\\sigma_2}^{1\\beta} \\over U_{\\rho_1\\sigma_2}^{0\\beta}} \\right]"); + l.DrawMathText(0.50, 0.600, "d\\Gamma = {1\\over 2m_A} \\left( \\prod_f {d^3p_f\\over (2\\pi)^3} {1\\over 2E_f} \\right) \\left| \\mathscr{M} \\left(m_A - \\left\\{p_f\\right\\} \\right) \\right|^2 (2\\pi)^4 \\delta^{(4)} \\left(p_A - \\sum p_f \\right)"); + l.DrawMathText(0.50, 0.425, "4\\mathrm{Re}\\left\\{{2\\over 1-\\Delta\\alpha} \\chi(s) \\left[ \\^{g}_\\nu^e \\^{g}_\\nu^f (1 + \\cos^2\\theta) + \\^{g}_a^e \\^{g}_a^f \\cos\\theta \\right] \\right\\}"); + l.DrawMathText(0.50, 0.330, "p(n) = {1\\over\\pi\\sqrt{2}} \\sum_{k = 1}^\\infty \\sqrt{k} A_k(n) {d\\over dn} {\\sinh \\left\\{ {\\pi\\over k} \\sqrt{2\\over 3} \\sqrt{n - {1\\over 24}} \\right\\} \\over \\sqrt{n - {1\\over 24}}}"); + l.DrawMathText(0.13, 0.150, "{(\\ell+1)C_{\\ell}^{TE} \\over 2\\pi}"); + l.DrawMathText(0.27, 0.110, "\\mathbb{N} \\subset \\mathbb{R}"); + l.DrawMathText(0.63, 0.100, "\\hbox{RHIC スピン物理 Нью-Йорк}"); + + TestReport1(C, "TMathText",1); + DoCcode(C); + TestReport2(1); +} + + //______________________________________________________________________________ void transpad() { @@ -1246,7 +1323,7 @@ void statfitparam () pt->SetFillColor(18); pt->SetTextAlign(12); pt->AddText("This example test all the possible cases"); - pt->AddText("handled by ThistPainter::GetBestFormat."); + pt->AddText("handled by THistPainter::GetBestFormat."); pt->AddText("This method returns the best format to"); pt->AddText("paint the fit parameters errors."); pt->Draw(); @@ -1442,6 +1519,108 @@ void tgaxis4() } +//______________________________________________________________________________ +void tgaxis5() +{ + // 5th TGaxis test. + + TCanvas *C = StartTest(800,570); + + double f = 1.8; + + TLatex* tex1 = new TLatex; + tex1->SetNDC(); + tex1->SetTextFont(102); + tex1->SetTextSize(0.07*f); + + TLatex* tex3 = new TLatex; + tex3->SetNDC(); + tex3->SetTextFont(102); + tex3->SetTextSize(0.07*f); + tex3->SetTextColor(kBlue+2); + + TLatex* tex2 = new TLatex; + tex2->SetNDC(); + tex2->SetTextFont(102); + tex2->SetTextSize(0.07*f); + tex2->SetTextColor(kOrange+3); + + time_t offset[] = {0, 0, 1325376000, 1341100800}; + time_t t[] = {1331150400, 1336417200, 0, 36000}; + + C->SetTopMargin(0); C->SetBottomMargin(0); + C->SetLeftMargin(0); C->SetRightMargin(0); + C->Divide(2, 4, -1, -1); + TLine l; + l.DrawLine(0.5, 0, 0.5, 1.); + + for(int i = 0; i < 4; ++i){ + for(int gmt = 0; gmt < 2; ++gmt){ + const char* opt = (gmt ? "gmt" : "local"); + TVirtualPad* p = C->cd(2*i + gmt + 1); + p->SetTopMargin(0); p->SetBottomMargin(0); + p->SetLeftMargin(0); p->SetRightMargin(0); + p->SetFillStyle(4000); + + TGaxis* ga = new TGaxis (.4, .25, 5., .25, t[i], t[i] + 1, 1, "t"); + ga->SetTimeFormat("TGaxis label: #color[2]{%Y-%m-%d %H:%M:%S}"); + ga->SetLabelFont(102); + ga->SetLabelColor(kBlue+2); + + ga->SetTimeOffset(offset[i], opt); + ga->SetLabelOffset(0.04*f); + ga->SetLabelSize(0.07*f); + ga->SetLineColor(0); + ga->Draw(); + + // Get offset string of axis time format: there is not acccessor + // to time format in TGaxis. + // Assumes TAxis use the same format. + TAxis a(10, 0, 1600000000); + a.SetTimeOffset(offset[i], opt); + const char* offsettimeformat = a.GetTimeFormat(); + + char buf[256]; + if (offset[i] < t[i]) { + sprintf(buf, "#splitline{%s, %s}{offset: %ld, option %s}", + stime(t+i).Data(), stime(t+i, true).Data(), offset[i], opt); + } else { + int h = t[i] / 3600; + int m = (t[i] - 3600 * h) / 60 ; + int s = (t[i] - h * 3600 - m * 60); + sprintf(buf, "#splitline{%d h %d m %d s}{offset: %s, option %s}", + h, m, s, stime(offset + i, gmt).Data(), opt); + } + tex1->DrawLatex(.01, .75, buf); + tex2->DrawLatex(.01, .50, offsettimeformat); + time_t t_ = t[i] + offset[i]; + sprintf(buf, "Expecting: #color[2]{%s}", stime(&t_, gmt, false).Data()); + tex3->DrawLatex(.01, .24, buf); + if(i > 0) l.DrawLine(0, 0.95, 1, 0.95); + } + } + + TestReport1(C, "TGaxis 5 (Time on axis: reference test)"); + DoCcode(C); + TestReport2(); +} + + +//______________________________________________________________________________ +TString stime(time_t* t, bool utc, bool display_time_zone) +{ + // function used by tgaxis5 + + struct tm* tt; + if (utc) tt = gmtime(t); + else tt = localtime(t); + char buf[256]; + if (display_time_zone) strftime(buf, sizeof(buf), "%H:%M:%S %Z", tt); + else strftime(buf, sizeof(buf), "%Y-%m-%d %H:%M:%S", tt); + return TString(buf); +} + + //______________________________________________________________________________ void labels1() { @@ -2030,7 +2209,7 @@ void earth() TH2F *h2 = new TH2F("h02","Mercator", 50, -180, 180, 50, -80.5, 80.5); TH2F *h3 = new TH2F("h03","Sinusoidal",50, -180, 180, 50, -90.5, 90.5); TH2F *h4 = new TH2F("h04","Parabolic", 50, -180, 180, 50, -90.5, 90.5); - ifstream in; + std::ifstream in; in.open("../tutorials/graphics/earth.dat"); if (!in) { in.clear(); @@ -2214,7 +2393,7 @@ void ntuple1() pad1->SetGrid(); pad1->SetLogy(); pad1->GetFrame()->SetFillColor(15); - TNtuple *ntuple = (TNtuple*)gLocalFile->Get("ntuple"); + TNtuple *ntuple = (TNtuple*)gHsimple->Get("ntuple"); ntuple->SetLineColor(1); ntuple->SetFillStyle(1001); ntuple->SetFillColor(45); @@ -2413,10 +2592,7 @@ void zoomtf1() gPad->Modified(); TestReport1(C, "Zoom/UnZoom a collection of TF1"); - if (gOptionR) { - DoCcode(C); - TestReport2(); - } + if (gOptionR) printf("%10d%10d\n",0,0); } @@ -2427,7 +2603,7 @@ void zoomfit() TCanvas *C = StartTest(800,800); - TH1 *hpx = (TH1*)gLocalFile->Get("hpx"); + TH1 *hpx = (TH1*)gHsimple->Get("hpx"); hpx->Fit("gaus","q"); hpx->GetXaxis()->SetRangeUser(.1,.3); gPad->Modified(); @@ -2442,6 +2618,52 @@ void zoomfit() } +//______________________________________________________________________________ +void hbars() +{ + // Ntuple drawing with alphanumeric variables + + TCanvas *C = StartTest(700,800); + + TTree *T = (TTree*)gCernstaff->Get("T"); + T->SetFillColor(45); + C->SetFillColor(42); + C->Divide(1,2); + + //horizontal bar chart + C->cd(1); gPad->SetGrid(); gPad->SetLogx(); gPad->SetFrameFillColor(33); + T->Draw("Nation","","hbar2"); + + //vertical bar chart + C->cd(2); gPad->SetGrid(); gPad->SetFrameFillColor(33); + T->Draw("Division>>hDiv","","goff"); + TH1F *hDiv = (TH1F*)gDirectory->Get("hDiv"); + hDiv->SetStats(0); + TH1F *hDivFR = (TH1F*)hDiv->Clone("hDivFR"); + T->Draw("Division>>hDivFR","Nation==\"FR\"","goff"); + hDiv->SetBarWidth(0.45); + hDiv->SetBarOffset(0.1); + hDiv->SetFillColor(49); + TH1 *h1 = hDiv->DrawCopy("bar2"); + hDivFR->SetBarWidth(0.4); + hDivFR->SetBarOffset(0.55); + hDivFR->SetFillColor(50); + TH1 *h2 = hDivFR->DrawCopy("bar2,same"); + + TLegend *legend = new TLegend(0.55,0.65,0.76,0.82); + legend->AddEntry(h1,"All nations","f"); + legend->AddEntry(h2,"French only","f"); + legend->Draw(); + + gPad->Modified(); + gPad->Update(); + + TestReport1(C, "Ntuple drawing with alphanumeric variables"); + DoCcode(C); + TestReport2(); +} + + //______________________________________________________________________________ void parallelcoord() { @@ -2449,7 +2671,7 @@ void parallelcoord() TCanvas *C = StartTest(800,700); - TNtuple *ntuple = (TNtuple*)gLocalFile->Get("ntuple"); + TNtuple *ntuple = (TNtuple*)gHsimple->Get("ntuple"); C->Divide(1,2); @@ -2463,10 +2685,7 @@ void parallelcoord() ntuple->Draw("px:py:pz:random:px*py*pz","","candle"); TestReport1(C, "Parallel Coordinates"); - if (gOptionR) { - DoCcode(C); - TestReport2(); - } + if (gOptionR) printf("%10d%10d\n",0,0); } @@ -2477,11 +2696,13 @@ void clonepad() TCanvas *C = StartTest(700,500); - TH1 *hpxpy = (TH1*)gLocalFile->Get("hpxpy"); + TH1 *hpxpy = (TH1*)gHsimple->Get("hpxpy"); hpxpy->Draw(); TCanvas *C2 = (TCanvas*)C->DrawClone(); TestReport1(C2, "Draw a pad and clone it"); + DoCcode(C2); + TestReport2(); } @@ -2622,9 +2843,7 @@ void waves() line->SetLineWidth(10); line->SetLineColor(0); line->Draw(); TestReport1(C, "TGraph, TArc, TPalette and TColor"); -///DoCcode(C); -///TestReport2(); - if (gOptionR) printf("\n"); + if (gOptionR) printf("%10d%10d\n",0,0); } diff --git a/test/stressGraphics.ref b/test/stressGraphics.ref index 46a5079ce0b23..77c36ed183f12 100644 --- a/test/stressGraphics.ref +++ b/test/stressGraphics.ref @@ -1,44 +1,48 @@ Test# PS1Ref# PS1Err# PDFRef# PDFErr# GIFRef# GIFErr# JPGRef# JPGErr# PNGRef# PNGErr# PS2Ref# PS2Err# - 1 529 50 12709 50 6351 100 23848 3700 3937 100 569 60 - 2 3940 600 14009 100 5437 1500 15379 7900 9282 3000 3778 600 - 3 452 50 12632 50 4797 350 11232 4200 3796 10700 492 50 - 4 23617 1500 19255 100 43077 12000 143320 123000 45665 11000 24908 1500 - 5 1029 50 12802 50 19715 2900 33468 9900 30846 5000 1057 50 - 6 430 50 12616 50 3976 100 9404 50 5072 100 471 50 - 7 4980 50 13821 50 8215 310 16143 1300 12230 500 5011 70 - 8 5442 80 13415 50 9750 150 18430 400 12642 200 5469 80 - 9 9441 100 14310 50 9092 400 19851 2400 11842 300 9449 100 - 10 8863 70 13539 100 13362 200 23884 50 22842 100 8894 70 - 11 12971 100 14377 50 20508 700 33343 300 33265 300 12864 150 - 12 9958 100 14005 50 32491 700 79674 300 51923 300 10039 150 - 13 5601 100 13277 100 9840 100 16427 100 15369 100 5612 100 - 14 15690 5000 17179 100 12037 800 23076 9500 15202 900 10437 5000 - 15 27201 400 22976 200 25908 800 44462 11000 30573 1500 36287 400 - 16 19623 400 21387 100 12050 800 27511 11000 16794 500 19901 400 - 17 15205 100 19204 100 12364 550 27187 10300 15179 350 15236 100 - 18 22521 300 42774 150 21207 6800 43868 17000 19232 11000 22729 300 - 19 3664 600 14437 100 9623 900 19824 6300 10396 900 4220 600 - 20 4866 600 14162 100 14490 2010 30889 10050 21311 1800 4845 600 - 21 4131 40 15221 50 13456 500 34038 2500 12258 1400 4162 40 - 22 7813 300 23739 100 4662 2300 11085 6000 6973 3100 8081 300 - 23 4545 150 14541 100 11094 1400 27602 14800 13094 2800 4467 150 - 24 6141 200 15967 100 14776 4200 39594 21600 19331 7000 6126 200 - 25 8485 500 16737 100 9738 4200 21346 21600 10645 7000 8282 500 - 26 17016 5500 18094 100 13764 3400 32434 17400 22157 5000 20823 5500 - 27 30615 8200 27299 100 29010 5900 50520 18200 35724 5400 36690 8200 - 28 3304592 100 697155 100 155478 32000 62688 19000 123056 7000 8282 500 - 29 315620 5500 433372 1000 34942 8300 65532 27800 37314 12000 325256 5500 - 30 35526 300 16815 100 23074 2200 47408 12700 33739 3700 35478 300 - 31 92810 750 59119 100 41853 6200 76094 38000 54717 11000 93584 800 - 32 239856 6500 116429 300 38898 10400 62719 34100 45592 14000 246031 6500 - 33 297200 5000 154995 750 43638 6300 65828 31800 53934 6500 301968 5000 - 34 1479662 35000 757137 200 79412 3400 71417 9900 102567 3500 1507071 35000 - 35 298263 2000 170884 4000 38621 8600 38425 13500 65177 18100 300165 2000 - 36 23594 200 49391 100 47205 3900 36524 11800 103480 8000 23426 200 - 37 15025 1500 29289 500 34091 1500 42525 11300 33336 3900 14787 1500 - 38 254604 5000 376027 7000 34608 5000 55666 30400 46534 6500 259594 5000 - 39 4832 50 14075 100 24153 100 32744 90 25176 100 4832 50 - 40 1435879 150000 12837 100 96029 4000 25972 100 359846 15000 1085792 250000 - 41 5412 200 16343 200 25899 3500 40706 14000 20980 4000 5130 200 - 42 5723 700 15762 200 13799 2600 31626 11000 16916 3200 5670 800 - 43 1585707 160000 534485 15000 16983 87800 30171 8100 27359 125700 1590373 160000 + 1 529 50 12709 50 6368 100 23758 3700 3937 100 569 60 + 2 3942 600 14017 100 5552 1500 15383 7900 9348 3000 3973 600 + 3 452 50 12632 50 4797 350 11280 4200 3796 10700 492 50 + 4 23696 1500 19251 100 44236 12000 143811 123000 47117 11000 24987 1500 + 5 1025 50 12806 50 19973 2900 32761 9900 30773 5000 1072 50 + 6 432 50 12621 50 4071 100 9533 50 5278 100 473 50 + 7 5018 50 13845 50 8421 310 16554 1300 12360 500 5049 70 + 8 5488 80 13426 50 9578 150 18583 400 12426 200 5502 80 + 9 9257 100 14323 50 9631 400 20434 2400 12167 300 9377 100 + 10 8831 70 13581 100 14672 200 25662 150 25203 200 8862 70 + 11 12970 100 14394 50 20491 700 34089 300 32120 300 12973 150 + 12 7675 100 13482 50 27833 700 83653 300 38469 300 7722 150 + 13 5600 100 13257 100 9869 250 16883 100 15110 200 5638 100 + 14 21117526 500000 12929 100 16288 800 27656 9500 26000 900 21117691 500000 + 15 15715 5000 17192 100 12110 800 23330 9500 14813 900 10762 5000 + 16 27117 400 23132 200 26366 800 44876 11000 30606 1500 36294 400 + 17 19711 400 21436 100 12279 800 28182 11000 16280 500 19988 400 + 18 15224 100 19238 100 12971 550 27745 10300 16127 350 15255 100 + 19 22491 300 42774 150 22144 6800 44413 17000 21073 11000 22673 300 + 20 3668 600 14408 100 9853 900 20190 6300 10747 900 4223 600 + 21 17608 600 13855 100 33628 5500 49423 6300 37116 9000 5986 600 + 22 4874 600 14150 100 15101 2010 31372 10050 21934 1800 4848 600 + 23 4130 40 15218 50 13554 500 34864 2500 12238 1400 4161 40 + 24 7825 300 23758 100 4674 2300 11084 6000 7039 3100 8097 300 + 25 4565 150 14517 100 11178 1400 27933 14800 13287 2800 4452 150 + 26 6160 200 15979 100 14907 4200 39737 21600 19477 7000 6128 200 + 27 8544 500 16731 100 9936 4200 21573 21600 10783 7000 8309 500 + 28 16981 5500 18077 100 13963 3400 32560 17400 22359 5000 17001 5500 + 29 30528 8200 27367 100 29282 5900 50508 18200 36048 5400 30638 8200 + 30 3304531 100 697103 100 155639 32000 62792 19000 122854 7000 0 0 + 31 315987 5500 434067 1000 35613 8300 66252 27800 38495 12000 325461 5500 + 32 35976 300 16855 200 25527 2200 50500 12700 36290 3700 35862 300 + 33 93106 750 59282 100 42783 6200 76443 38000 56178 11000 93864 800 + 34 268319 6500 122049 300 39199 10400 62124 34100 46643 14000 275970 6500 + 35 294619 5000 154479 750 44280 6300 65745 31800 54773 6500 299361 5000 + 36 1479328 35000 757176 200 79872 3400 72403 9900 103048 3500 1506726 35000 + 37 298968 2000 170867 4000 38848 8600 38615 13500 65004 18100 300230 2000 + 38 23610 200 49402 100 47095 3900 36674 11800 103939 8000 23458 200 + 39 15018 1500 29454 500 34162 1500 42904 11300 33564 3900 14785 1500 + 40 254943 5000 379094 7000 33786 5000 54388 30400 45625 6500 259554 5000 + 41 4846 50 14072 100 24326 100 33253 150 25605 100 4877 50 + 42 1442690 150000 12837 100 99799 4000 26058 100 374206 15000 1102303 250000 + 43 5230 200 16245 200 26153 3500 41287 14000 21356 4000 0 0 + 44 5785 700 15734 200 14171 2600 32424 11000 17698 3200 5716 800 + 45 1666331 160000 529486 50000 39232 3000 29937 3000 72296 7000 0 0 + 46 176455 17000 266239 25000 15666 1500 40992 4000 31561 3000 193642 19000 + 47 13593 1300 16662 1600 24929 2400 53275 5200 23314 2200 13986 1300 diff --git a/test/stressHepix.cxx b/test/stressHepix.cxx index a9c4477cb7c0b..d8d2a65a6438d 100644 --- a/test/stressHepix.cxx +++ b/test/stressHepix.cxx @@ -26,7 +26,7 @@ // make // // The default configuration of ROOT is enough. -// The ouput of this benchmark looks like: +// The output of this benchmark looks like: // /// stressHepix /// @@ -58,7 +58,7 @@ ///**************************************************************************** // // If you run this benchmark on a new platform, please report the results -// at rootdev@root.cern.ch. Send the output shown above and also the +// at rootdev@cern.ch. Send the output shown above and also the // log file stressHepix.log that contains more details about the individual // tests. Your results will be shown at http://root.cern.ch/root/Benchmark.html // diff --git a/test/stressHistoFit.cxx b/test/stressHistoFit.cxx index 091285e0fed99..819964f22182a 100644 --- a/test/stressHistoFit.cxx +++ b/test/stressHistoFit.cxx @@ -485,7 +485,7 @@ void printSeparator() fflush(stdout); } -// Sets the color of the ouput to red or normal +// Sets the color of the output to red or normal void setColor(int red = 0) { char command[13]; diff --git a/test/stressProof.cxx b/test/stressProof.cxx index d0b9d66a6a88e..1c7994cddfd8b 100644 --- a/test/stressProof.cxx +++ b/test/stressProof.cxx @@ -16,8 +16,8 @@ // * $ root * // // * root[] .include $ROOTSYS/tutorials * // // * root[] .L stressProof.cxx+ * // -// * root[] stressProof(master, wrks, verbose, logfile, dyn, \ * // -// * skipds, tests, h1src, eventsrc, dryrun) * // +// * root[] stressProof(master, tests, wrks, verbose, logfile, dyn, \ * // +// * dyn, skipds, h1src, eventsrc, dryrun) * // // * * // // * The arguments have the same meaning as above except for * // // * verbose [Int_t] increasing verbosity (0 == minimal) * // @@ -58,10 +58,12 @@ // * Test 20 : File-resident output: merge ...................... OK * * // // * Test 21 : File-resident output: merge w/ submergers ........ OK * * // // * Test 22 : File-resident output: create dataset ............. OK * * // -// * Test 23 : TTree friends (and TPacketizerFile) .............. OK * * // -// * Test 24 : TTree friends, same file ......................... OK * * // -// * Test 25 : Simple: selector by object ....................... OK * * // -// * Test 26 : H1 dataset: selector by object ................... OK * * // +// * Test 23 : File-resident output: multi trees ................ OK * * // +// * Test 24 : TTree friends (and TPacketizerFile) .............. OK * * // +// * Test 25 : TTree friends, same file ......................... OK * * // +// * Test 26 : Handling output via file ......................... OK * * // +// * Test 27 : Simple: selector by object ....................... OK * * // +// * Test 28 : H1 dataset: selector by object ................... OK * * // // * * All registered tests have been passed :-) * * // // * ****************************************************************** * // // * * // @@ -130,6 +132,8 @@ #include "proof/getProof.C" +#define PT_NUMTEST 28 + static const char *urldef = "proof://localhost:40000"; static TString gtutdir; static TString gsandbox; @@ -192,13 +196,14 @@ static TString gPackEvent("/proof/event.par"); static TString gPack1("/proof/packtest1.par"); static TString gPack2("/proof/packtest2.par"); -int stressProof(const char *url = "proof://localhost:40000", - Int_t nwrks = -1, const char *verbose = "1", - const char *logfile = 0, Bool_t dyn = kFALSE, - Bool_t skipds = kTRUE, const char *tests = 0, +int stressProof(const char *url = 0, + const char *tests = 0, Int_t nwrks = -1, + const char *verbose = "1", const char *logfile = 0, + Bool_t dyn = kFALSE, Bool_t skipds = kTRUE, const char *h1src = 0, const char *eventsrc = 0, Bool_t dryrun = kFALSE, Bool_t showcpu = kFALSE, - Bool_t clearcache = kFALSE, Bool_t useprogress = kTRUE, const char *tutdir = 0); + Bool_t clearcache = kFALSE, Bool_t useprogress = kTRUE, + const char *tutdir = 0, Bool_t cleanlog = kFALSE, Bool_t keeplog = kTRUE); //_____________________________batch only_____________________ #ifndef __CINT__ @@ -228,7 +233,20 @@ int main(int argc,const char *argv[]) printf(" options (see TProofDebug.h) and is enabled only is level > 1 (default kAll).\n"); printf(" -l logfile file where to redirect the processing logs; must be writable;\n"); printf(" default is a temporary file deleted at the end of the test\n"); - printf(" in case of success; can be also passed via the env STRESSPROOF_LOGFILE\n"); + printf(" in case of success. Some format specifiers can be used in the file name:\n"); + printf(" - %%p is replaced by the current process ID; \n"); + printf(" - %%tmp is replaced by the temporary directory; \n"); + printf(" - %%d is replaced by date and time at test startup in the form YYYYMMDD-HHMM, \n"); + printf(" e.g. 20120904-1138. \n"); + printf(" The log file path can be also passed via the env STRESSPROOF_LOGFILE.\n"); + printf(" In case of failure, the log files of the nodes (master and workers) are saved into\n"); + printf(" a file called <logfile>.nodes .\n"); + printf(" -c,-cleanlog Delete the logfile specified via '-l' in case of a successful run; by default\n"); + printf(" the file specified by '-l' is kept in all cases (default log files are deleted\n"); + printf(" on success); adding this switch allows to keep a user-defined log file only\n"); + printf(" in case of error.\n"); + printf(" -k,-keeplog Keep all logfiles, including the ones fro the PROOF nodes (in one single file).\n"); + printf(" The paths are printed on the screen.\n"); printf(" -dyn run the test in dynamicStartup mode\n"); printf(" -ds force the dataset test if skipped by default\n"); printf(" -t tests run only tests in the comma-separated list and those from which they\n"); @@ -252,7 +270,7 @@ int main(int argc,const char *argv[]) printf(" -g enable graphics; default is to run in text mode.\n"); printf(" -cpu show CPU times used by each successful test; used for calibration.\n"); printf(" -clearcache clear memory cache associated with the files processed when local.\n"); - printf(" -noprogress do not show progress whose escaped chars may confuse some wrapper applications.\n"); + printf(" -noprogress do not show progress (escaped chars may confuse some wrapper applications)\n"); printf(" -tut tutdir specify alternative location for the ROOT tutorials; allows to run multiple\n"); printf(" concurrent instances of stressProof, for tests, for example.\n"); printf(" Can be also passed via the env STRESSPROOF_TUTORIALDIR.\n"); @@ -269,6 +287,8 @@ int main(int argc,const char *argv[]) Bool_t showcpu = kFALSE; Bool_t clearcache = kFALSE; Bool_t useprogress = kTRUE; + Bool_t cleanlog = kFALSE; + Bool_t keeplog = kFALSE; const char *logfile = 0; const char *h1src = 0; const char *eventsrc = 0; @@ -303,6 +323,12 @@ int main(int argc,const char *argv[]) logfile = argv[i+1]; i += 2; } + } else if (!strncmp(argv[i],"-c",2) || !strncmp(argv[i],"-cleanlog",11)) { + cleanlog = kTRUE; + i++; + } else if (!strncmp(argv[i],"-k",2) || !strncmp(argv[i],"-keeplog",10)) { + keeplog = kTRUE; + i++; } else if (!strncmp(argv[i],"-v",2)) { // For backward compatibility if (!strncmp(argv[i],"-vv",3)) verbose = "2"; @@ -377,8 +403,8 @@ int main(int argc,const char *argv[]) gROOT->SetBatch(kTRUE); } - int rc = stressProof(url, nWrks, verbose, logfile, gDynamicStartup, gSkipDataSetTest, - tests, h1src, eventsrc, dryrun, showcpu, clearcache, useprogress, tutdir); + int rc = stressProof(url, tests, nWrks, verbose, logfile, gDynamicStartup, gSkipDataSetTest, + h1src, eventsrc, dryrun, showcpu, clearcache, useprogress, tutdir, cleanlog, keeplog); gSystem->Exit(rc); } @@ -528,7 +554,7 @@ class ProofTest : public TNamed { Double_t fProofMarks; // PROOF marks Bool_t fUseForMarks; // Use in the calculation of the average PROOF marks - static Double_t gRefReal[26]; // Reference Cpu times + static Double_t gRefReal[PT_NUMTEST]; // Reference Cpu times public: ProofTest(const char *n, Int_t seq, ProofTestFun_t f, void *a = 0, @@ -555,10 +581,10 @@ class ProofTest : public TNamed { // Reference time measured on a HP DL580 24 core (4 x Intel(R) Xeon(R) CPU X7460 // @ 2.132 GHz, 48GB RAM, 1 Gb/s NIC) with 4 workers. -Double_t ProofTest::gRefReal[26] = { +Double_t ProofTest::gRefReal[PT_NUMTEST] = { 3.047808, // #1: Open a session 0.021979, // #2: Get session logs - 3.148925, // #3: Simple random number generation + 4.779971, // #3: Simple random number generation 0.276155, // #4: Dataset handling with H1 files 5.355514, // #5: H1: chain processing 2.414207, // #6: H1: file collection processing @@ -578,10 +604,12 @@ Double_t ProofTest::gRefReal[26] = { 2.489555, // #20: File-resident output: merge 0.180897, // #21: File-resident output: merge w/ submergers 1.417233, // #22: File-resident output: create dataset - 7.452465, // #23: TTree friends (and TPacketizerFile) - 0.259239, // #24: TTree friends, same file - 0.000000, // #25: Simple random number generation by TSelector object - 0.000000 // #26: H1: by-object processing + 0.000000, // #23: File-resident output: multi trees + 7.452465, // #24: TTree friends (and TPacketizerFile) + 0.259239, // #25: TTree friends, same file + 6.868858, // #26: Simple generation: merge-via-file + 6.362017, // #27: Simple random number generation by TSelector object + 5.519631 // #28: H1: by-object processing }; // @@ -715,6 +743,8 @@ Int_t PT_Friends(void *, RunTimes &); Int_t PT_SimpleByObj(void *, RunTimes &); Int_t PT_H1ChainByObj(void *, RunTimes &); Int_t PT_AssertTutorialDir(const char *tutdir); +Int_t PT_MultiTrees(void *, RunTimes &); +Int_t PT_OutputHandlingViaFile(void *, RunTimes &); // Auxilliary functions void PT_GetLastTimes(RunTimes &tt) @@ -741,25 +771,31 @@ void PT_GetLastProofTimes(RunTimes &tt) } // Arguments structures -typedef struct { // Open +typedef struct ptopenargs { // Open const char *url; Int_t nwrks; } PT_Open_Args_t; // Packetizer parameters -typedef struct { +typedef struct ptpacketizer { const char *fName; Int_t fType; } PT_Packetizer_t; +// Options +typedef struct ptoption { + Int_t fOne; + Int_t fTwo; +} PT_Option_t; + static PT_Packetizer_t gStd_Old = { "TPacketizer", 0 }; //_____________________________________________________________________________ -int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *logfile, - Bool_t dyn, Bool_t skipds, const char *tests, +int stressProof(const char *url, const char *tests, Int_t nwrks, + const char *verbose, const char *logfile, Bool_t dyn, Bool_t skipds, const char *h1src, const char *eventsrc, Bool_t dryrun, Bool_t showcpu, Bool_t clearcache, Bool_t useprogress, - const char *tutdir) + const char *tutdir, Bool_t cleanlog, Bool_t keeplog) { printf("******************************************************************\n"); printf("* Starting P R O O F - S T R E S S suite *\n"); @@ -807,12 +843,13 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l printf("* WARNING: request to run a test with per-job scheduling on *\n"); printf("* an external cluster: %s .\n", url); printf("* Make sure the dynamic option is set. *\n"); - printf("******************************************************************\n"); + printf("* *\n"); gDynamicStartup = kFALSE; } else { printf("* Runnning in dynamic mode (per-job scheduling) *\n"); - printf("******************************************************************\n"); } + printf("* Tests #15, #22, #23, #26 skipped in dynamic mode **\n"); + printf("******************************************************************\n"); } if (dryrun) { @@ -840,10 +877,22 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l if (logfile && strlen(logfile) > 0 && !dryrun) { usedeflog = kFALSE; glogfile = logfile; - if (glogfile.Contains("<tmpdir>")) - glogfile.ReplaceAll("<tmpdir>", gSystem->TempDirectory()); + if (glogfile.Contains("%tmp")) + glogfile.ReplaceAll("%tmp", gSystem->TempDirectory()); + if (glogfile.Contains("%p")) { + TString apid = TString::Format("%d", gSystem->GetPid()); + glogfile.ReplaceAll("%p", apid); + } + if (glogfile.Contains("%d")) { + TString d(TDatime().AsSQLString()); + d.Remove(d.Last(':')); + d.ReplaceAll("-", ""); + d.ReplaceAll(":", ""); + d.ReplaceAll(" ", "-"); + glogfile.ReplaceAll("%d", d); + } if (!gSystem->AccessPathName(glogfile, kFileExists)) { - if (!gSystem->AccessPathName(glogfile, kWritePermission)) { + if (gSystem->AccessPathName(glogfile, kWritePermission)) { printf(" >>> Cannot write to log file %s - ignore file request\n", logfile); usedeflog = kTRUE; } @@ -862,10 +911,12 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l return 1; } fclose(flog); - if (gverbose > 0) { - printf("* Log file: %s\n", glogfile.Data()); - printf("******************************************************************\n"); - } + } + if (gverbose > 0) { + printf("* Log file: %s\n", glogfile.Data()); + if (cleanlog) + printf("* (NB: file will be removed if test is successful) *\n"); + printf("******************************************************************\n"); } if (gSkipDataSetTest && gverbose > 0) { @@ -889,7 +940,7 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l } } else if (!gh1src.BeginsWith(h1src)) { if (gverbose > 0) { - printf("* Taking H1 files from: %s\n", h1src); + printf("* Taking 'h1' files from: %s\n", h1src); printf("******************************************************************\n"); } gh1src = h1src; @@ -926,6 +977,10 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l printf("* Clearing cache associated to files, if possible ... **\n"); printf("******************************************************************\n"); } + if (keeplog && gverbose > 0) { + printf("* Keeping logfiles (paths specified at the end) **\n"); + printf("******************************************************************\n"); + } // // Reset dataset settings gEnv->SetValue("Proof.DataSetManager",""); @@ -952,7 +1007,7 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l &PT_H1FileCollection, (void *)&gStd_Old, "1", "h1analysis", kTRUE)); // H1 analysis over HTTP by dataset name testList->Add(new ProofTest("H1: by-name processing", 8, &PT_H1DataSet, 0, "1,4", "h1analysis", kTRUE)); - // H1 analysis over HTTP by dataset name splitted in two + // H1 analysis over HTTP by dataset name split in two testList->Add(new ProofTest("H1: multi dataset processing", 9, &PT_H1MultiDataSet, 0, "1,4", "h1analysis", kTRUE)); // H1 analysis over HTTP by dataset name testList->Add(new ProofTest("H1: multi dataset and entry list", 10, &PT_H1MultiDSetEntryList, 0, "1,4", "h1analysis", kTRUE)); @@ -969,9 +1024,9 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l // Test admin functionality testList->Add(new ProofTest("Admin functionality", 16, &PT_AdminFunc, 0, "1")); // Test merging via submergers - Bool_t useMergers = kTRUE; + PT_Option_t pfoptm = {1, 0}; testList->Add(new ProofTest("Dynamic sub-mergers functionality", 17, - &PT_Simple, (void *)&useMergers, "1", "ProofSimple", kTRUE)); + &PT_Simple, (void *)&pfoptm, "1", "ProofSimple", kTRUE)); // Test range chain and dataset processing EventProc testList->Add(new ProofTest("Event range processing", 18, &PT_EventRange, 0, "1,11", "ProofEventProc,ProcFileElements", kTRUE)); @@ -982,20 +1037,25 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l testList->Add(new ProofTest("File-resident output: merge", 20, &PT_POFNtuple, 0, "1", "ProofNtuple", kTRUE)); // Test TProofOutputFile technology for ntuple creation using submergers testList->Add(new ProofTest("File-resident output: merge w/ submergers", 21, - &PT_POFNtuple, (void *)&useMergers, "1", "ProofNtuple", kTRUE)); + &PT_POFNtuple, (void *)&pfoptm, "1", "ProofNtuple", kTRUE)); // Test TProofOutputFile technology for dataset creation (tests TProofDraw too) testList->Add(new ProofTest("File-resident output: create dataset", 22, &PT_POFDataset, 0, "1", "ProofNtuple", kTRUE)); + // Test selecting different TTrees in same files + testList->Add(new ProofTest("File-resident output: multi trees", 23, &PT_MultiTrees, 0, "1,22", "ProofNtuple", kTRUE)); // Test TPacketizerFile and TTree friends in separate files - testList->Add(new ProofTest("TTree friends (and TPacketizerFile)", 23, &PT_Friends, 0, "1", "ProofFriends,ProofAux", kTRUE)); + testList->Add(new ProofTest("TTree friends (and TPacketizerFile)", 24, &PT_Friends, 0, "1", "ProofFriends,ProofAux", kTRUE)); // Test TPacketizerFile and TTree friends in same file Bool_t sameFile = kTRUE; - testList->Add(new ProofTest("TTree friends, same file", 24, + testList->Add(new ProofTest("TTree friends, same file", 25, &PT_Friends, (void *)&sameFile, "1", "ProofFriends,ProofAux", kTRUE)); + // Test handling output via file + testList->Add(new ProofTest("Handling output via file", 26, + &PT_OutputHandlingViaFile, 0, "1", "ProofSimple", kTRUE)); // Simple histogram generation by TSelector object - testList->Add(new ProofTest("Simple: selector by object", 25, &PT_SimpleByObj, 0, "1", "ProofSimple", kTRUE)); + testList->Add(new ProofTest("Simple: selector by object", 27, &PT_SimpleByObj, 0, "1", "ProofSimple", kTRUE)); // H1 analysis over HTTP by TSeletor object - testList->Add(new ProofTest("H1 chain: selector by object", 26, &PT_H1ChainByObj, 0, "1", "h1analysis", kTRUE)); + testList->Add(new ProofTest("H1 chain: selector by object", 28, &PT_H1ChainByObj, 0, "1", "h1analysis", kTRUE)); // The selectors if (PT_AssertTutorialDir(gTutDir) != 0) { printf("* Some of the tutorial files are missing! Stop\n"); @@ -1051,7 +1111,7 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l printf("* Non-positive test number: %d\n", test); continue; } - const int tmx = 26; + const int tmx = PT_NUMTEST; if (test > tmx) { printf("* **\r"); printf("* Unknown test number: %d\n", test); @@ -1118,7 +1178,7 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l if (!all && !dryrun) { // Notify the enabled tests printf("* **\r"); - printf("* Running only tests %s (and related)\n", ten.Data()); + printf("* Running only test(s) %s (and related)\n", ten.Data()); printf("******************************************************************\n"); } } @@ -1171,9 +1231,10 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l } // Done + Bool_t kept = ((usedeflog || cleanlog) && !keeplog) ? kFALSE : kTRUE; if (failed) { - Bool_t kept = kTRUE; - if (usedeflog && !gROOT->IsBatch()) { + kept = kTRUE; + if (usedeflog && !gROOT->IsBatch() && !keeplog) { const char *answer = Getline(" Some tests failed: would you like to keep the log file (N,Y)? [Y] "); if (answer && (answer[0] == 'N' || answer[0] == 'n')) { // Remove log file @@ -1181,13 +1242,34 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l kept = kFALSE; } } - if (kept) - printf("* Log file kept at %s\n", glogfile.Data()); } else { printf("* All registered tests have been passed :-) *\n"); + } + + if (kept) { + TString logfiles(glogfile); + // Save also the logs from the workers + TProofMgr *mgr = gProof ? gProof->GetManager() : 0; + if (mgr) { + gSystem->RedirectOutput(glogfile, "a", &gRH); + TProofLog *pl = mgr->GetSessionLogs(); + if (pl) { + logfiles += ".nodes"; + pl->Retrieve("*", TProofLog::kAll, logfiles); + gSystem->RedirectOutput(0, 0, &gRH); + SafeDelete(pl); + } else { + gSystem->RedirectOutput(0, 0, &gRH); + printf("+++ Warning: could not get the session logs\n"); + } + } else { + printf("+++ Warning: could not attach to manager to get the session logs\n"); + } + printf("******************************************************************\n"); + printf(" Main log file kept at %s (Proof logs in %s)\n", glogfile.Data(), logfiles.Data()); + } else { // Remove log file if not passed by the user - if (usedeflog) - gSystem->Unlink(glogfile); + gSystem->Unlink(glogfile); } printf("******************************************************************\n"); @@ -1207,14 +1289,14 @@ int stressProof(const char *url, Int_t nwrks, const char *verbose, const char *l } if (navg > 0) avgmarks /= navg; - gProof->GetStatistics((verbose > 0)); + gProof->GetStatistics((gverbose > 0)); // Reference time measured on a HP DL580 24 core (4 x Intel(R) Xeon(R) CPU X7460 // @ 2.132 GHz, 48GB RAM, 1 Gb/s NIC) with 4 workers. const double reftime = 70.169; double glbmarks = (gProof->GetRealTime() > 0) ? 1000 * reftime / gProof->GetRealTime() : -1; - printf(" ROOTMARKS = %.2f (overall: %.2f) ROOT version: %s\t%s@%d\n", + printf(" ROOTMARKS = %.2f (overall: %.2f) ROOT version: %s\t%s@%s\n", avgmarks, glbmarks, gROOT->GetVersion(), - gROOT->GetSvnBranch(), gROOT->GetSvnRevision()); + gROOT->GetGitBranch(), gROOT->GetGitCommit()); // Average from the single tests printf("******************************************************************\n"); } @@ -1329,9 +1411,11 @@ Int_t PT_H1AssertFiles(const char *h1src) printf("\n >>> Test failure: file %s not found in archive %s\n", src.Data(), h1src); return -1; } - gSystem->RedirectOutput(0, 0, &gRH); - printf("%d\b", i); - gSystem->RedirectOutput(glogfile, "a", &gRH); + if (guseprogress) { + gSystem->RedirectOutput(0, 0, &gRH); + printf("%d\b", i); + gSystem->RedirectOutput(glogfile, "a", &gRH); + } } gh1sep = '#'; } else { @@ -1344,9 +1428,11 @@ Int_t PT_H1AssertFiles(const char *h1src) printf("\n >>> Test failure: file %s does not exist\n", src.Data()); return -1; } - gSystem->RedirectOutput(0, 0, &gRH); - printf("%d\b", i); - gSystem->RedirectOutput(glogfile, "a", &gRH); + if (guseprogress) { + gSystem->RedirectOutput(0, 0, &gRH); + printf("%d\b", i); + gSystem->RedirectOutput(glogfile, "a", &gRH); + } } } gh1src = h1src; @@ -1430,9 +1516,11 @@ Int_t PT_EventAssertFiles(const char *eventsrc, Int_t nf = 10) printf("\n >>> Test failure: problems retrieving %s\n", src.Data()); return -1; } - gSystem->RedirectOutput(0, 0, &gRH); - printf("%d\b", i); - gSystem->RedirectOutput(glogfile, "a", &gRH); + if (guseprogress) { + gSystem->RedirectOutput(0, 0, &gRH); + printf("%d\b", i); + gSystem->RedirectOutput(glogfile, "a", &gRH); + } } geventlocal = kTRUE; // Done @@ -1448,9 +1536,11 @@ Int_t PT_EventAssertFiles(const char *eventsrc, Int_t nf = 10) printf("\n >>> Test failure: file %s does not exist\n", src.Data()); return -1; } - gSystem->RedirectOutput(0, 0, &gRH); - printf("%d\b", i); - gSystem->RedirectOutput(glogfile, "a", &gRH); + if (guseprogress) { + gSystem->RedirectOutput(0, 0, &gRH); + printf("%d\b", i); + gSystem->RedirectOutput(glogfile, "a", &gRH); + } } geventsrc = eventsrc; @@ -1565,7 +1655,7 @@ Int_t PT_CheckSimple(TQueryResult *qr, Long64_t nevt, Int_t nhist) PutPoint(); TH1F **hist = new TH1F*[nhist]; for (Int_t i=0; i < nhist; i++) { - hist[i] = dynamic_cast<TH1F *>(out->FindObject(Form("h%d",i))); + hist[i] = dynamic_cast<TH1F *>(TProof::GetOutput(Form("h%d",i), out)); if (!hist[i]) { printf("\n >>> Test failure: 'h%d' histo not found\n", i); return -1; @@ -1588,6 +1678,92 @@ Int_t PT_CheckSimple(TQueryResult *qr, Long64_t nevt, Int_t nhist) return 0; } +//_____________________________________________________________________________ +Int_t PT_CheckSimpleNtuple(TQueryResult *qr, Long64_t nevt, const char *dsname) +{ + // Check the ntuple created by the ProofSimple analysis + + if (!qr) { + printf("\n >>> Test failure: query result not found\n"); + return -1; + } + + // Make sure the output list is there + PutPoint(); + TList *out = qr->GetOutputList(); + if (!out) { + printf("\n >>> Test failure: output list not found\n"); + return -1; + } + + // Get the file collection + PutPoint(); + TFileCollection *fc = dynamic_cast<TFileCollection *>(out->FindObject(dsname)); + if (!fc) { + printf("\n >>> Test failure: TFileCollection for dataset '%s' not" + " found in the output list\n", dsname); + return -1; + } + + // Check the default tree name + const char *tname = "/ntuple"; + PutPoint(); + if (!fc->GetDefaultTreeName() || strcmp(fc->GetDefaultTreeName(), tname)) { + printf("\n >>> Test failure: default tree name does not match (%s != %s)\n", + fc->GetDefaultTreeName(), tname); + return -1; + } + + // Check the number of entries + PutPoint(); + if (fc->GetTotalEntries(tname) != nevt) { + printf("\n >>> Test failure: number of entries does not match (%lld != %lld)\n", + fc->GetTotalEntries(tname), nevt); + return -1; + } + + // Check 'pz' histo + TH1F *hpx = new TH1F("PT_px", "PT_px", 20, -5., 5.); + PutPoint(); + gProof->DrawSelect(dsname, "px >> PT_px"); + if (TMath::Abs(hpx->GetMean()) > 5 * hpx->GetRMS() / TMath::Sqrt(hpx->GetEntries())) { + printf("\n >>> Test failure: 'hpx' histo: mean > 5 * RMS/Sqrt(N) (%f,%f)\n", + hpx->GetMean(), hpx->GetRMS()); + return -1; + } + + // Check 'pz' histo + TH1F *hpz = new TH1F("PT_pz", "PT_pz", 20, 0., 20.); + PutPoint(); + gProof->DrawSelect(dsname, "pz >> PT_pz"); + if (TMath::Abs(hpz->GetMean() - 2.) > 5 * 2. / TMath::Sqrt(hpz->GetEntries())) { + printf("\n >>> Test failure: 'hpz' histo: (mean - 2) > 5 * RMS/Sqrt(N) (%f,%f)\n", + hpz->GetMean(), hpz->GetRMS()); + return -1; + } + + // Check 'random' histo + TH1F *hpr = new TH1F("PT_rndm", "PT_rndm", 20, 0., 20.); + PutPoint(); + gProof->DrawSelect(dsname, "random >> PT_rndm"); + if (TMath::Abs(hpr->GetMean() - .5) > 5 * .5 / TMath::Sqrt(hpr->GetEntries())) { + printf("\n >>> Test failure: 'hpr' histo: (mean - .5) > 5 * RMS/Sqrt(N) (%f,%f)\n", + hpr->GetMean(), hpr->GetRMS()); + return -1; + } + + SafeDelete(hpx); + SafeDelete(hpz); + SafeDelete(hpr); + + // Clear dsname + gProof->ClearData(TProof::kDataset |TProof::kForceClear, dsname); + + // Done + PutPoint(); + return 0; +} + //_____________________________________________________________________________ Int_t PT_CheckH1(TQueryResult *qr, Int_t irun = 0) { @@ -1826,6 +2002,8 @@ Int_t PT_CheckDataset(TQueryResult *qr, Long64_t nevt) printf("\n >>> Test failure: dataset '%s' not found in the repository\n", dsname); return -1; } + // ... and that the default tree is 'ntuple' + gProof->SetDataSetTreeName(dsname, "ntuple"); // Create the histos TH1F *h1s[3] = {0}; @@ -1846,8 +2024,8 @@ Int_t PT_CheckDataset(TQueryResult *qr, Long64_t nevt) Int_t rch1s = 0; TString emsg; // Check the histogram entries and mean values - Float_t hent[3] = { .607275, .367860, .067741}; - Double_t hmea[3] = { 2.003304, 1.995983 , 3.044178}; + Float_t hent[3] = { .607700, .364900, .065100}; + Double_t hmea[3] = { 2.022, 2.046 , 3.043}; Double_t prec = 10. / TMath::Sqrt(nevt); // ~10 sigma ... conservative for (Int_t i = 0; i < 3; i++) { Double_t ent = h1s[i]->GetEntries(); @@ -1869,7 +2047,6 @@ Int_t PT_CheckDataset(TQueryResult *qr, Long64_t nevt) // Cleanup for (Int_t i = 0; i < 3; i++) delete h1s[i]; - gProof->RemoveDataSet(dsname); // Check the result if (rch1s != 0) { @@ -2012,6 +2189,21 @@ Int_t PT_Open(void *args, RunTimes &tt) printf("\n >>> Test failure: could not start the session\n"); return -1; } + + // Re-check locality: if the logged user name is different from the local one, we may + // not have all the rights we need, so we go no-local + if (gLocalCluster) { + UserGroup_t *pw = gSystem->GetUserInfo(); + if (pw) { + if (strcmp(pw->fUser, p->GetUser())) gLocalCluster = kFALSE; + delete pw; + } + } + + // Check if it is in dynamic startup mode + Int_t dyn = 0; + p->GetRC("Proof.DynamicStartup", dyn); + if (dyn != 0) gDynamicStartup = kTRUE; // Set debug level, if required if (gverbose > 1) { @@ -2096,7 +2288,7 @@ Int_t PT_GetLogs(void *args, RunTimes &tt) } //_____________________________________________________________________________ -Int_t PT_Simple(void *submergers, RunTimes &tt) +Int_t PT_Simple(void *opts, RunTimes &tt) { // Test run for the ProofSimple analysis (see tutorials) @@ -2107,10 +2299,14 @@ Int_t PT_Simple(void *submergers, RunTimes &tt) return -1; } + PT_Option_t *ptopt = (PT_Option_t *) opts; + // Setup submergers if required - if (submergers) { + if (ptopt && ptopt->fOne > 0) { gProof->SetParameter("PROOF_UseMergers", 0); } + // Setup save-to-file, if required + TString opt = (ptopt && ptopt->fTwo > 0) ? "stf" : "" ; // Define the number of events and histos Long64_t nevt = 1000000; @@ -2125,7 +2321,7 @@ Int_t PT_Simple(void *submergers, RunTimes &tt) PutPoint(); { SwitchProgressGuard spg; gTimer.Start(); - gProof->Process(gSimpleSel.Data(), nevt); + gProof->Process(gSimpleSel.Data(), nevt, opt); gTimer.Stop(); } @@ -2144,6 +2340,95 @@ Int_t PT_Simple(void *submergers, RunTimes &tt) return PT_CheckSimple(gProof->GetQueryResult(), nevt, nhist); } +//_____________________________________________________________________________ +Int_t PT_OutputHandlingViaFile(void *opts, RunTimes &tt) +{ + // Test output handling via file using ProofSimple (see tutorials) + + // Checking arguments + PutPoint(); + if (!gProof) { + printf("\n >>> Test failure: no PROOF session found\n"); + return -1; + } + // Not yet supported in dynamic mode + if (gDynamicStartup) { + return 1; + } + PutPoint(); + + PT_Option_t *ptopt = (PT_Option_t *) opts; + + // Setup submergers if required + if (ptopt && ptopt->fOne > 0) { + gProof->SetParameter("PROOF_UseMergers", 0); + } + // Setup save-to-file, if required + TString opt = (ptopt && ptopt->fTwo > 0) ? "stf" : "" ; + + // Define the number of events and histos + Long64_t nevt = 1000000 * gProof->GetParallel(); + Int_t nhist = 16; + // The number of histograms is added as parameter in the input list + gProof->SetParameter("ProofSimple_NHist", (Long_t)nhist); + + // Merged file pptions to be tested + const char *testopt[4] = { "stf", "of=proofsimple.root", "of=proofsimple.root;stf", + "of=master:proofsimple.root" }; + + for (Int_t i = 0; i < 4; i++) { + // Clear the list of query results + if (gProof->GetQueryResults()) gProof->GetQueryResults()->Clear(); + + // Save results to file 'proofsimple.root' + PutPoint(); + { SwitchProgressGuard spg; + gTimer.Start(); + gProof->Process(gSimpleSel.Data(), nevt, testopt[i]); + gTimer.Stop(); + } + if (PT_CheckSimple(gProof->GetQueryResult(), nevt, nhist) != 0) { + printf("\n >>> Test failure: output handling via file: option '%s'\n", testopt[i]); + return -1; + } + // Count + gSimpleCnt++; + gSimpleTime += gTimer.RealTime(); + // Remove file + gSystem->Unlink("proofsimple.root"); + } + + // Test dataset creationg with a ntuple + const char *dsname = "PT_ds_proofsimple"; + if (gProof->GetQueryResults()) gProof->GetQueryResults()->Clear(); + if (gProof->ExistsDataSet(dsname)) gProof->RemoveDataSet(dsname); + + // We want the ntuple + gProof->SetParameter("ProofSimple_Ntuple", ""); + + // Save results to file 'proofsimple.root' + PutPoint(); + { SwitchProgressGuard spg; + gTimer.Start(); + gProof->Process(gSimpleSel.Data(), nevt, TString::Format("ds=%s|V", dsname)); + gTimer.Stop(); + } + if (!gProof->ExistsDataSet(dsname)) { + printf("\n >>> Test failure: output handling via file: dataset '%s' not created\n", dsname); + return -1; + } + + // Remove any setting related to submergers + gProof->DeleteParameters("PROOF_UseMergers"); + + // The runtimes + PT_GetLastProofTimes(tt); + + // Check the results + PutPoint(); + return PT_CheckSimpleNtuple(gProof->GetQueryResult(), nevt, dsname); +} + //_____________________________________________________________________________ Int_t PT_H1Http(void *, RunTimes &tt) { @@ -2462,6 +2747,7 @@ Int_t PT_H1MultiDSetEntryList(void *, RunTimes &tt) // Unlink the entry list file gSystem->Unlink("elist.root"); + // Cleanup entry-list from the input list nxi.Reset(); while ((o = nxi())) { @@ -3092,6 +3378,10 @@ Int_t PT_H1SimpleAsync(void *arg, RunTimes &tt) if (gProof->IsLite()) { return 1; } + // Not supported in dynamic mode + if (gDynamicStartup) { + return 1; + } PutPoint(); // Set/unset the parallel unzip flag @@ -3557,7 +3847,7 @@ Int_t PT_EventRange(void *arg, RunTimes &tt) } //_____________________________________________________________________________ -Int_t PT_POFNtuple(void *submergers, RunTimes &tt) +Int_t PT_POFNtuple(void *opts, RunTimes &tt) { // Test TProofOutputFile technology to create a ntuple, with or without // submergers @@ -3569,37 +3859,15 @@ Int_t PT_POFNtuple(void *submergers, RunTimes &tt) return -1; } + PT_Option_t *ptopt = (PT_Option_t *) opts; + // Setup submergers if required - if (submergers) { + if (ptopt && ptopt->fTwo > 0) { gProof->SetParameter("PROOF_UseMergers", 0); } // Output file - TString fout = TString::Format("%s/ProofNtuple.root", gSystem->WorkingDirectory()); - // Cleanup any existing instance of the output file - gSystem->Unlink(fout); - - if (!gLocalCluster) { - // Setup a local basic xrootd to receive the file - Bool_t xrdok = kFALSE; - Int_t port = 9000; - while (port < 9010) { - if (checkXrootdAt(port) != 1) { - if (startXrootdAt(port, gSystem->WorkingDirectory(), kTRUE) == 0) { - xrdok = kTRUE; - break; - } - } - port++; - } - if (!xrdok) { - printf(" >>> PT_POFNtuple: could not start basic xrootd on ports 9000-9009 - skip this test"); - return 1; - } - fout.Insert(0, TString::Format("root://%s:%d/", TUrl(gSystem->HostName()).GetHostFQDN(), port)); - // Make a copy of the files on the master before merging - gProof->AddInput(new TNamed("PROOF_OUTPUTFILE_LOCATION", "LOCAL")); - } + TString fout("<datadir>/ProofNtuple.root"); gProof->AddInput(new TNamed("PROOF_OUTPUTFILE", fout.Data())); // We use the 'NtpRndm' for a fixed values of randoms; we need to send over the file @@ -3649,10 +3917,19 @@ Int_t PT_POFDataset(void *, RunTimes &tt) printf("\n >>> Test failure: no PROOF session found\n"); return -1; } + + const char *dsname = "testNtuple"; + // Clean-up any existing dataset with that name + if (gProof->ExistsDataSet(dsname)) gProof->RemoveDataSet(dsname); // Ask for registration of the dataset (the default is the the TFileCollection is return // without registration; the name of the TFileCollection is the name of the dataset - gProof->SetParameter("SimpleNtuple.root","testNtuple"); + gProof->SetParameter("SimpleNtuple.root", dsname); + + // We use the 'NtpRndm' for a fixed values of randoms; we need to send over the file + gProof->SetInputDataFile(gNtpRndm); + // Set the related parameter + gProof->SetParameter("PROOF_USE_NTP_RNDM","yes"); // Define the number of events and histos Long64_t nevt = 1000000; @@ -3674,6 +3951,8 @@ Int_t PT_POFDataset(void *, RunTimes &tt) // Remove any setting related to submergers gProof->DeleteParameters("PROOF_NTUPLE_DONT_PLOT"); gProof->DeleteParameters("SimpleNtuple.root"); + gProof->DeleteParameters("PROOF_USE_NTP_RNDM"); + gProof->SetInputDataFile(0); // The runtimes PT_GetLastProofTimes(tt); @@ -3683,6 +3962,128 @@ Int_t PT_POFDataset(void *, RunTimes &tt) return PT_CheckDataset(gProof->GetQueryResult(), nevt); } +//_____________________________________________________________________________ +Int_t PT_MultiTrees(void *, RunTimes &tt) +{ + // Test processing of multiple trees in the same files + + // Checking arguments + PutPoint(); + if (!gProof) { + printf("\n >>> Test failure: no PROOF session found\n"); + return -1; + } + + const char *dsname = "testNtuple"; + // There must be a dataset 'testNtuple' already registered and validated + if (!gProof->ExistsDataSet(dsname)) { + printf("\n >>> Test failure: dataset '%s' does not exist\n", dsname); + return -1; + } + + // Get the associated TFileCollection + TFileCollection *fc = gProof->GetDataSet(dsname); + if (!fc) { + printf("\n >>> Test failure: unable to get TFileCollection for dataset '%s'\n", dsname); + return -1; + } + + // Now create a TDSet out of the TFileCollection + TDSet *dset = new TDSet("testntps", "ntuple", "/", "TTree"); + TChain *ch1 = new TChain("ntuple"); + TChain *ch2 = new TChain("ntuple2"); + TIter nxf(fc->GetList()); + TFileInfo *fi = 0; + while ((fi = (TFileInfo *) nxf())) { + dset->Add(fi->GetCurrentUrl()->GetUrl()); + ch1->Add(fi->GetCurrentUrl()->GetUrl()); + ch2->Add(fi->GetCurrentUrl()->GetUrl()); + } + + // Check the ntuple content by filling some histos + TH1F *h1s[2] = {0}; + h1s[0] = new TH1F("h1_1", "3*px+2 with px**2+py**2>1", 50, -15., 15.); + h1s[1] = new TH1F("h1_2", "vx**2+vy**2 with abs(vz)<.1", 50, 0., 10.); + + Int_t rch1s = 0; + TString emsg; + const char *type[3] = { "dsname", "TDSet", "TChain" }; + for (Int_t j = 0; j < 3; j++) { + + PutPoint(); + + if (j == 0) { + // Fill the first histo from the first ntuple + gProof->SetDataSetTreeName(dsname, "ntuple"); + { SwitchProgressGuard spg; + gProof->DrawSelect(dsname, "3*px+2>>h1_1", "px*px+py*py>1"); + } + // Fill the second histo from the second ntuple + gProof->SetDataSetTreeName(dsname, "ntuple2"); + { SwitchProgressGuard spg; + gProof->DrawSelect(dsname, "vx*vx+vy*vy>>h1_2", "vz>-0.1&&vz<0.1"); + } + } else if (j == 1) { + // Fill the first histo from the first ntuple + { SwitchProgressGuard spg; + gProof->DrawSelect(dset, "3*px+2>>h1_1", "px*px+py*py>1"); + } + // Fill the second histo from the second ntuple + dset->SetObjName("ntuple2"); + { SwitchProgressGuard spg; + gProof->DrawSelect(dset, "vx*vx+vy*vy>>h1_2", "vz>-0.1&&vz<0.1"); + } + } else { + // Fill the first histo from the first ntuple + { SwitchProgressGuard spg; + ch1->Draw("3*px+2>>h1_1", "px*px+py*py>1"); + } + // Fill the second histo from the second ntuple + { SwitchProgressGuard spg; + ch2->Draw("vx*vx+vy*vy>>h1_2", "vz>-0.1&&vz<0.1"); + } + } + + rch1s = 0; + // Check the histogram entries and mean values + Int_t hent[2] = { 607700, 96100}; + Double_t hmea[2] = { 2.022, 1.859}; + for (Int_t i = 0; i < 2; i++) { + if ((Int_t)(h1s[i]->GetEntries()) != hent[i]) { + emsg.Form("%s: '%s' histo: wrong number of entries (%d: expected %d)", + type[j], h1s[i]->GetName(), (Int_t)(h1s[i]->GetEntries()), hent[i]); + rch1s = -1; + break; + } + if (TMath::Abs((h1s[i]->GetMean() - hmea[i]) / hmea[i]) > 0.001) { + emsg.Form("%s: '%s' histo: wrong mean (%f: expected %f)", + type[j], h1s[i]->GetName(), h1s[i]->GetMean(), hmea[i]); + rch1s = -1; + break; + } + } + } + + // Cleanup + for (Int_t i = 0; i < 2; i++) delete h1s[i]; + + // Check the result + if (rch1s != 0) { + printf("\n >>> Test failure: %s\n", emsg.Data()); + return -1; + } + + // Clean-up + gProof->RemoveDataSet(dsname); + + // The runtimes + PT_GetLastProofTimes(tt); + + // Check the results + PutPoint(); + return rch1s; +} + //_____________________________________________________________________________ Int_t PT_Friends(void *sf, RunTimes &tt) { @@ -3695,6 +4096,12 @@ Int_t PT_Friends(void *sf, RunTimes &tt) return -1; } + // Not supported in dynamic mode + if (gDynamicStartup) { + return 1; + } + PutPoint(); + // Separate or same file ? Bool_t sameFile = (sf) ? kTRUE : kFALSE; @@ -3801,6 +4208,9 @@ Int_t PT_Friends(void *sf, RunTimes &tt) // Remove any setting gProof->DeleteParameters("PROOF_DONT_PLOT"); + gProof->GetInputList()->Remove(files); + files->SetOwner(kTRUE); + SafeDelete(files); // Clear the files created by this run gProof->ClearData(TProof::kUnregistered | TProof::kForceClear); diff --git a/test/stressRooFit.cxx b/test/stressRooFit.cxx index 766b606a60b75..d454b73128f09 100644 --- a/test/stressRooFit.cxx +++ b/test/stressRooFit.cxx @@ -61,6 +61,7 @@ void StatusPrint(Int_t id,const TString &title,Int_t status) //______________________________________________________________________________ Int_t stressRooFit(const char* refFile, Bool_t writeRef, Int_t doVerbose, Int_t oneTest, Bool_t dryRun, Bool_t doDump, Bool_t doTreeStore) { + Int_t retVal = 0; // Save memory directory location RooUnitTest::setMemDir(gDirectory) ; @@ -73,7 +74,7 @@ Int_t stressRooFit(const char* refFile, Bool_t writeRef, Int_t doVerbose, Int_t if (TString(refFile).Contains("http:")) { if (writeRef) { cout << "stressRooFit ERROR: reference file must be local file in writing mode" << endl ; - return kFALSE ; + return 1; } fref = new TWebFile(refFile) ; } else { @@ -81,7 +82,7 @@ Int_t stressRooFit(const char* refFile, Bool_t writeRef, Int_t doVerbose, Int_t } if (fref->IsZombie()) { cout << "stressRooFit ERROR: cannot open reference file " << refFile << endl ; - return kFALSE ; + return 1; } } @@ -177,7 +178,10 @@ Int_t stressRooFit(const char* refFile, Bool_t writeRef, Int_t doVerbose, Int_t if (doDump) { (*iter)->setDebug(kTRUE) ; } - StatusPrint( i,(*iter)->GetName(),(*iter)->isTestAvailable()?(*iter)->runTest():-1); + Int_t status = (*iter)->isTestAvailable()?(*iter)->runTest():-1; + StatusPrint( i,(*iter)->GetName(), status); + // increment retVal for every failed test + if (!status) ++retVal; } delete (*iter) ; i++ ; @@ -236,7 +240,7 @@ Int_t stressRooFit(const char* refFile, Bool_t writeRef, Int_t doVerbose, Int_t delete gBenchmark ; gBenchmark = 0 ; - return 0; + return retVal; } //_____________________________batch only_____________________ @@ -251,7 +255,7 @@ int main(int argc,const char *argv[]) Bool_t doDump = kFALSE ; Bool_t doTreeStore = kFALSE ; - string refFileName = "http://root.cern.ch/files/stressRooFit_v530_ref.root" ; + string refFileName = "http://root.cern.ch/files/stressRooFit_v534_ref.root" ; // Parse command line arguments for (Int_t i=1 ; i<argc ; i++) { @@ -335,13 +339,9 @@ int main(int argc,const char *argv[]) cout << "stressRooFit: WARNING running in write mode, but reference file is web file, writing local file instead: " << refFileName << endl ; } - // Disable caching of complex error function calculation, as we don't - // want to write out the cache file as part of the validation procedure - RooMath::cacheCERF(kFALSE) ; - gBenchmark = new TBenchmark(); - stressRooFit(refFileName.c_str(),doWrite,doVerbose,oneTest,dryRun,doDump,doTreeStore); - return 0; + Int_t retVal = stressRooFit(refFileName.c_str(),doWrite,doVerbose,oneTest,dryRun,doDump,doTreeStore); + return retVal; } #endif diff --git a/test/stressRooFit_tests.cxx b/test/stressRooFit_tests.cxx index 29170d8c8edeb..131bb912e2b50 100644 --- a/test/stressRooFit_tests.cxx +++ b/test/stressRooFit_tests.cxx @@ -928,7 +928,7 @@ class TestBasic201 : public RooUnitTest // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; @@ -1055,7 +1055,7 @@ class TestBasic202 : public RooUnitTest // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; @@ -1263,7 +1263,7 @@ class TestBasic204 : public RooUnitTest // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; @@ -1356,7 +1356,7 @@ class TestBasic205 : public RooUnitTest // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; @@ -1493,7 +1493,7 @@ class TestBasic208 : public RooUnitTest return kFALSE ; } - Double_t ctol() { return 5e-3 ; } // Account for difficult shape of Landau distribution + Double_t ctol() { return 1e-2 ; } // Account for difficult shape of Landau distribution Bool_t testCode() { @@ -3484,7 +3484,7 @@ class TestBasic403 : public RooUnitTest // NB: Within the usual approximations of a chi2 fit, a chi2 fit to weighted // data using sum-of-weights-squared errors does give correct error // estimates - RooChi2Var chi2("chi2","chi2",p2,*binnedData,DataError(RooAbsData::SumW2)) ; + RooChi2Var chi2("chi2","chi2",p2,*binnedData) ; RooMinuit m(chi2) ; m.migrad() ; m.hesse() ; @@ -4404,7 +4404,7 @@ class TestBasic602 : public RooUnitTest // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; @@ -4809,7 +4809,7 @@ class TestBasic607 : public RooUnitTest // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5,-10,10) ; RooRealVar sigma1("sigma1","width of gaussians",0.5,0.1,10) ; RooRealVar sigma2("sigma2","width of gaussians",1,0.1,10) ; @@ -6027,7 +6027,7 @@ class TestBasic801 : public RooUnitTest RooRealVar x("x","x",0,10) ; x.setBins(40) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5,0,10) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/test/stressRooStats.cxx b/test/stressRooStats.cxx index 4cc11f1847068..6460bb52d5a0f 100644 --- a/test/stressRooStats.cxx +++ b/test/stressRooStats.cxx @@ -5,6 +5,7 @@ #include <string> #include <list> #include <iostream> +#include <iomanip> #include <cmath> // ROOT headers @@ -46,10 +47,10 @@ using namespace RooFit ; //*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*// // // -// RooStats Examples, Wouter Verkerke, Lorenzo Moneta, Ioan Gabriel Bucur // +// RooStats Unit Test S.T.R.E.S.S. Suite // +// Authors: Ioan Gabriel Bucur, Lorenzo Moneta, Wouter Verkerke // // // -// // -//*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*_*// +//*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*// //------------------------------------------------------------------------ @@ -61,10 +62,10 @@ void StatusPrint(const Int_t id, const TString &title, const Int_t status, const } //______________________________________________________________________________ -Int_t stressRooStats(const char* refFile, Bool_t writeRef, Int_t verbose, Int_t oneTest, Bool_t dryRun, Bool_t doDump, Bool_t doTreeStore) +Int_t stressRooStats(const char* refFile, Bool_t writeRef, Int_t verbose, Bool_t allTests, Bool_t oneTest, Int_t testNumber, Bool_t dryRun, Bool_t doDump, Bool_t doTreeStore) { // width of lines when printing test results - const Int_t lineWidth = 80; + const Int_t lineWidth = 120; // Save memory directory location RooUnitTest::setMemDir(gDirectory) ; @@ -111,88 +112,123 @@ Int_t stressRooStats(const char* refFile, Bool_t writeRef, Int_t verbose, Int_t TStopwatch timer; timer.Start(); - list<RooUnitTest*> testList ; + list<RooUnitTest*> testList; - // TEST PLC CONFINT SIMPLE GAUSSIAN : Confidence Level range is (0,1) + + // 1-5 TEST PLC CONFINT SIMPLE GAUSSIAN : Confidence Level range is (0,1) testList.push_back(new TestProfileLikelihoodCalculator1(fref, writeRef, verbose, 0.99999)); // boundary case CL -> 1 testList.push_back(new TestProfileLikelihoodCalculator1(fref, writeRef, verbose, 2 * ROOT::Math::normal_cdf(3) - 1)); // 3 sigma testList.push_back(new TestProfileLikelihoodCalculator1(fref, writeRef, verbose, 2 * ROOT::Math::normal_cdf(2) - 1)); // 2 sigma testList.push_back(new TestProfileLikelihoodCalculator1(fref, writeRef, verbose, 2 * ROOT::Math::normal_cdf(1) - 1)); // 1 sigma testList.push_back(new TestProfileLikelihoodCalculator1(fref, writeRef, verbose, 0.00001)); // boundary case CL -> 0 - // TEST PLC CONFINT SIMPLE POISSON : Observed value range is [0,1000] + // 6-10 TEST PLC CONFINT SIMPLE POISSON : Observed value range is [0,1000] testList.push_back(new TestProfileLikelihoodCalculator2(fref, writeRef, verbose, 0)); // boundary Poisson value (0) testList.push_back(new TestProfileLikelihoodCalculator2(fref, writeRef, verbose, 1)); testList.push_back(new TestProfileLikelihoodCalculator2(fref, writeRef, verbose, 5)); testList.push_back(new TestProfileLikelihoodCalculator2(fref, writeRef, verbose, 100)); testList.push_back(new TestProfileLikelihoodCalculator2(fref, writeRef, verbose, 800)); // boundary Poisson value - // TEST PLC CONFINT PRODUCT POISSON : Observed value range is [0,40] for x=s+b and [0,120] for y=2*s*1.2^beta + // 11-13 TEST PLC CONFINT PRODUCT POISSON : Observed value range is [0,30] for x=s+b and [0,80] for y=2*s*1.2^beta testList.push_back(new TestProfileLikelihoodCalculator3(fref, writeRef, verbose, 10, 30)); testList.push_back(new TestProfileLikelihoodCalculator3(fref, writeRef, verbose, 20, 25)); testList.push_back(new TestProfileLikelihoodCalculator3(fref, writeRef, verbose, 15, 20, 2 * ROOT::Math::normal_cdf(2) - 1)); - // TEST PLC HYPOTEST ON/OFF MODEL + // 14 TEST PLC HYPOTEST ON/OFF MODEL testList.push_back(new TestProfileLikelihoodCalculator4(fref, writeRef, verbose)); - // TEST BC CONFINT CENTRAL SIMPLE POISSON : Observed value range is [0,100] + // 15-18 TEST BC CONFINT CENTRAL SIMPLE POISSON : Observed value range is [0,100] testList.push_back(new TestBayesianCalculator1(fref, writeRef, verbose, 1)); testList.push_back(new TestBayesianCalculator1(fref, writeRef, verbose, 3)); testList.push_back(new TestBayesianCalculator1(fref, writeRef, verbose, 10)); testList.push_back(new TestBayesianCalculator1(fref, writeRef, verbose, 50)); - // TEST BC CONFINT SHORTEST SIMPLE POISSON + // 19 TEST BC CONFINT SHORTEST SIMPLE POISSON testList.push_back(new TestBayesianCalculator2(fref, writeRef, verbose)); - // TEST BC CONFINT CENTRAL PRODUCT POISSON : Observed value range is [0,40] for x=s+b and [0,120] for y=2*s*1.2^beta + // 20-22 TEST BC CONFINT CENTRAL PRODUCT POISSON : Observed value range is [0,30] for x=s+b and [0,80] for y=2*s*1.2^beta testList.push_back(new TestBayesianCalculator3(fref, writeRef, verbose, 10, 30)); testList.push_back(new TestBayesianCalculator3(fref, writeRef, verbose, 20, 25)); testList.push_back(new TestBayesianCalculator3(fref, writeRef, verbose, 15, 20, 2 * ROOT::Math::normal_cdf(2) - 1)); - // TEST MCMCC CONFINT PRODUCT POISSON : Observed value range is [0,40] for x=s+b and [0,120] for y=2*s*1.2^beta - // this is failing . t.b.investigate - //testList.push_back(new TestMCMCCalculator(fref, writeRef, verbose, 10, 30)); + // 23-25 TEST MCMCC CONFINT PRODUCT POISSON : Observed value range is [0,30] for x=s+b and [0,80] for y=2*s*1.2^beta + testList.push_back(new TestMCMCCalculator(fref, writeRef, verbose, 10, 30)); testList.push_back(new TestMCMCCalculator(fref, writeRef, verbose, 20, 25)); testList.push_back(new TestMCMCCalculator(fref, writeRef, verbose, 15, 20, 2 * ROOT::Math::normal_cdf(2) - 1)); - // TEST HYPOTEST INVERTER PRODUCT POISSON : Observed value range is [0,40] for x=s+b and [0,120] for y=2*s*1.2^beta - testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, HypoTestInverter::kAsymptotic, kProfileLR, 10, 30)); - testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, HypoTestInverter::kAsymptotic, kProfileLR, 20, 25)); - testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, HypoTestInverter::kAsymptotic, kProfileLR, 15, 20, 2 * normal_cdf(2) - 1)); - testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, HypoTestInverter::kFrequentist, kProfileLR, 10, 30)); - testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, HypoTestInverter::kFrequentist, kProfileLR, 20, 25)); - testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, HypoTestInverter::kFrequentist, kProfileLR, 15, 20, 2 * normal_cdf(2) - 1)); - testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, HypoTestInverter::kHybrid, kProfileLR, 10, 30)); - testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, HypoTestInverter::kHybrid, kProfileLR, 20, 25)); - testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, HypoTestInverter::kHybrid, kProfileLR, 15, 20, 2 * normal_cdf(2) - 1)); - - - cout << "*" << setw(lineWidth - 2) << setfill(' ') << " Starting S.T.R.E.S.S. basic suite " << "*" << endl; + // 26 TEST ZBI SIGNIFICANCE + testList.push_back(new TestZBi(fref, writeRef, verbose)); + + // 27-31 TEST PLC VS AC SIGNIFICANCE : Observed value range is [0,300] for on source and [0,1100] for off-source; tau has the range [0.1,5.0] + testList.push_back(new TestHypoTestCalculator1(fref, writeRef, verbose, 150, 100, 1.0)); + testList.push_back(new TestHypoTestCalculator1(fref, writeRef, verbose, 200, 100, 1.0)); + testList.push_back(new TestHypoTestCalculator1(fref, writeRef, verbose, 105, 100, 1.0)); + testList.push_back(new TestHypoTestCalculator1(fref, writeRef, verbose, 150, 10, 0.1)); + testList.push_back(new TestHypoTestCalculator1(fref, writeRef, verbose, 150, 400, 4.0)); + + // 32-36 TEST HTC SIGNIFICANCE + testList.push_back(new TestHypoTestCalculator2(fref, writeRef, verbose, kAsymptotic)); + testList.push_back(new TestHypoTestCalculator2(fref, writeRef, verbose, kFrequentist, kSimpleLR)); + testList.push_back(new TestHypoTestCalculator2(fref, writeRef, verbose, kFrequentist, kRatioLR)); + testList.push_back(new TestHypoTestCalculator2(fref, writeRef, verbose, kFrequentist, kProfileLROneSidedDiscovery)); + testList.push_back(new TestHypoTestCalculator2(fref, writeRef, verbose, kHybrid, kProfileLROneSidedDiscovery)); + + // 37-43 TEST HTI PRODUCT POISSON : Observed value range is [0,30] for x=s+b and [0,80] for y=2*s*1.2^beta + testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, kAsymptotic, kProfileLR, 10, 30)); + testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, kAsymptotic, kProfileLR, 20, 25)); + testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, kAsymptotic, kProfileLR, 15, 20, 2 * normal_cdf(2) - 1)); + testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, kFrequentist, kProfileLR, 10, 30)); + testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, kFrequentist, kProfileLR, 20, 25)); + testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, kFrequentist, kProfileLR, 15, 20, 2 * normal_cdf(2) - 1)); + testList.push_back(new TestHypoTestInverter1(fref, writeRef, verbose, kHybrid, kProfileLR, 10, 30)); + + // 44-48 TEST HTI S+B+E POISSON : Observed value range is [0,50] for x = e*s+b + testList.push_back(new TestHypoTestInverter2(fref, writeRef, verbose, kAsymptotic, kProfileLROneSided, 10)); + testList.push_back(new TestHypoTestInverter2(fref, writeRef, verbose, kAsymptotic, kProfileLROneSided, 20)); +// testList.push_back(new TestHypoTestInverter2(fref, writeRef, verbose, kFrequentist, kSimpleLR, 10)); +// testList.push_back(new TestHypoTestInverter2(fref, writeRef, verbose, kFrequentist, kSimpleLR, 20)); + testList.push_back(new TestHypoTestInverter2(fref, writeRef, verbose, kFrequentist, kRatioLR)); + testList.push_back(new TestHypoTestInverter2(fref, writeRef, verbose, kFrequentist, kProfileLROneSided)); + testList.push_back(new TestHypoTestInverter2(fref, writeRef, verbose, kHybrid, kSimpleLR)); + + + TString suiteType = TString::Format(" Starting S.T.R.E.S.S. %s", + allTests ? "full suite" : (oneTest ? TString::Format("test %d", testNumber).Data() : "basic suite") + ); + + cout << "*" << setw(lineWidth - 3) << setfill(' ') << suiteType << " *" << endl; cout << setw(lineWidth) << setfill('*') << "" << endl; if (doDump) { TFile fdbg("stressRooStats_DEBUG.root", "RECREATE") ; } - gBenchmark->Start("StressRooStats"); + gBenchmark->Start("stressRooStats"); + + { + Int_t i; + list<RooUnitTest*>::iterator iter; - Int_t i(1) ; - for (list<RooUnitTest*>::iterator iter = testList.begin() ; iter != testList.end() ; ++iter) { - if (oneTest < 0 || oneTest == i) { - if (doDump) { - (*iter)->setDebug(kTRUE); + if (oneTest && (testNumber <= 0 || (UInt_t) testNumber > testList.size())) { + cout << "Tests are numbered from 1 to " << testList.size() << endl; + } else { + for (iter = testList.begin(), i = 1; iter != testList.end(); iter++, i++) { + if (!oneTest || testNumber == i) { + if (doDump) { + (*iter)->setDebug(kTRUE); + } + StatusPrint(i, (*iter)->GetName(), (*iter)->isTestAvailable() ? (*iter)->runTest() : -1, lineWidth); + } + delete *iter; } - StatusPrint(i, (*iter)->GetName(), (*iter)->isTestAvailable() ? (*iter)->runTest() : -1, lineWidth); } - delete *iter; - i++; } if (dryRun) { RooTrace::dump(); } - gBenchmark->Stop("StressRooStats"); + gBenchmark->Stop("stressRooStats"); //Print table with results @@ -217,16 +253,16 @@ Int_t stressRooStats(const char* refFile, Bool_t writeRef, Int_t verbose, Int_t } cout << setw(lineWidth) << setfill('*') << "" << endl; - gBenchmark->Print("StressFit"); + gBenchmark->Print("stressRooStats"); #ifdef __CINT__ Double_t reftime = 186.34; //pcbrun4 interpreted #else Double_t reftime = 93.59; //pcbrun4 compiled #endif - const Double_t rootmarks = 860 * reftime / gBenchmark->GetCpuTime("StressRooStats"); + const Double_t rootmarks = 860 * reftime / gBenchmark->GetCpuTime("stressRooStats"); cout << setw(lineWidth) << setfill('*') << "" << endl; - cout << TString::Format("* ROOTMARKS = %6.1f * Root%-8s %d/%d", rootmarks, gROOT->GetVersion(), + cout << TString::Format("* ROOTMARKS = %6.1f * Root %-8s %d/%d", rootmarks, gROOT->GetVersion(), gROOT->GetVersionDate(), gROOT->GetVersionTime()) << endl; cout << setw(lineWidth) << setfill('*') << "" << endl; @@ -249,14 +285,17 @@ Int_t stressRooStats(const char* refFile, Bool_t writeRef, Int_t verbose, Int_t int main(int argc, const char *argv[]) { - Bool_t doWrite = kFALSE ; - Int_t verbose = 0 ; - Int_t oneTest = -1 ; - Bool_t dryRun = kFALSE ; - Bool_t doDump = kFALSE ; - Bool_t doTreeStore = kFALSE ; - - string refFileName = "http://root.cern.ch/files/stressRooStats_v534_ref.root" ; + Bool_t doWrite = kFALSE; + Int_t verbose = 0; + Bool_t allTests = kFALSE; + Bool_t oneTest = kFALSE; + Int_t testNumber = 0; + Bool_t dryRun = kFALSE; + Bool_t doDump = kFALSE; + Bool_t doTreeStore = kFALSE; + + //string refFileName = "http://root.cern.ch/files/stressRooStats_v534_ref.root" ; + string refFileName = "$ROOTSYS/test/stressRooStats_ref.root" ; // Parse command line arguments for (Int_t i = 1 ; i < argc ; i++) { @@ -265,59 +304,45 @@ int main(int argc, const char *argv[]) if (arg == "-f") { cout << "stressRooStats: using reference file " << argv[i + 1] << endl ; refFileName = argv[++i] ; - } - - if (arg == "-w") { + } else if (arg == "-w") { cout << "stressRooStats: running in writing mode to update reference file" << endl ; doWrite = kTRUE ; - } - - if (arg == "-mc") { - cout << "stressRooStats: running in memcheck mode, no regression tests are performed" << endl ; - dryRun = kTRUE ; - } - - if (arg == "-ts") { - cout << "stressRooStats: setting tree-based storage for datasets" << endl ; - doTreeStore = kTRUE ; - } - - if (arg == "-v") { - cout << "stressRooStats: running in verbose mode" << endl ; - verbose = 1 ; - } - - if (arg == "-vv") { - cout << "stressRooStats: running in very verbose mode" << endl ; - verbose = 2 ; - } - - if (arg == "-n") { - cout << "stressRooStats: running single test " << argv[i + 1] << endl ; - oneTest = atoi(argv[++i]) ; - } - - if (arg == "-d") { - cout << "stressRooStats: setting gDebug to " << argv[i + 1] << endl ; - gDebug = atoi(argv[++i]) ; - } - - if (arg == "-c") { - cout << "stressRooStats: dumping comparison file for failed tests " << endl ; - doDump = kTRUE ; - } - - if (arg == "-h") { - cout << "usage: stressRooStats [ options ] " << endl ; - cout << "" << endl ; - cout << " -f <file> : use given reference file instead of default (" << refFileName << ")" << endl ; - cout << " -w : write reference file, instead of reading file and running comparison tests" << endl ; - cout << " " << endl ; - cout << " -n N : Only run test with sequential number N instead of full suite of tests" << endl ; - cout << " -c : dump file stressRooStats_DEBUG.root to which results of both current result and reference for each failed test are written" << endl ; - cout << " -mc : memory check mode, no regression test are performed. Set this flag when running with valgrind" << endl ; - cout << " -vs : Use vector-based storage for all datasets (default is tree-based storage)" << endl ; - cout << " -v/-vv : set verbose mode (show result of each regression test) or very verbose mode (show all roofit output as well)" << endl ; + } else if (arg == "-mc") { + cout << "stressRooStats: running in memcheck mode, no regression tests are performed" << endl; + dryRun = kTRUE; + } else if (arg == "-ts") { + cout << "stressRooStats: setting tree-based storage for datasets" << endl; + doTreeStore = kTRUE; + } else if (arg == "-v") { + cout << "stressRooStats: running in verbose mode" << endl; + verbose = 1; + } else if (arg == "-vv") { + cout << "stressRooStats: running in very verbose mode" << endl; + verbose = 2; + } else if (arg == "-a") { + cout << "stressRooStats: deploying full suite of tests" << endl; + allTests = kTRUE; + } else if (arg == "-n") { + cout << "stressRooStats: running single test" << endl; + oneTest = kTRUE; + testNumber = atoi(argv[++i]); + } else if (arg == "-d") { + cout << "stressRooStats: setting gDebug to " << argv[i + 1] << endl; + gDebug = atoi(argv[++i]); + } else if (arg == "-c") { + cout << "stressRooStats: dumping comparison file for failed tests " << endl; + doDump = kTRUE; + } else if (arg == "-h") { + cout << "usage: stressRooStats [ options ] " << endl; + cout << "" << endl; + cout << " -f <file> : use given reference file instead of default (" << refFileName << ")" << endl; + cout << " -w : write reference file, instead of reading file and running comparison tests" << endl; + cout << " -n N : only run test with sequential number N" << endl; + cout << " -a : run full suite of tests (default is basic suite); this overrides the -n single test option" << endl; + cout << " -c : dump file stressRooStats_DEBUG.root to which results of both current result and reference for each failed test are written" << endl; + cout << " -mc : memory check mode, no regression test are performed. Set this flag when running with valgrind" << endl; + cout << " -vs : use vector-based storage for all datasets (default is tree-based storage)" << endl; + cout << " -v/-vv : set verbose mode (show result of each regression test) or very verbose mode (show all roofit output as well)" << endl; cout << " -d N : set ROOT gDebug flag to N" << endl ; cout << " " << endl ; return 0 ; @@ -325,27 +350,26 @@ int main(int argc, const char *argv[]) } - if (doWrite && refFileName.find("http:") == 0) { +// if (doWrite && refFileName.find("http:") == 0) { - // Locate file name part in URL and update refFileName accordingly - char* buf = new char[refFileName.size() + 1]; - strcpy(buf, refFileName.c_str()); - char *ptr = strrchr(buf, '/'); - if (!ptr) { - ptr = strrchr(buf, ':'); - } - refFileName = ptr + 1; - delete[] buf; +// // Locate file name part in URL and update refFileName accordingly +// char* buf = new char[refFileName.size() + 1]; +// strcpy(buf, refFileName.c_str()); +// char *ptr = strrchr(buf, '/'); +// if (!ptr) ptr = strrchr(buf, ':'); +// refFileName = ptr + 1; +// delete[] buf; - cout << "stressRooStats: WARNING running in write mode, but reference file is web file, writing local file instead: " << refFileName << endl; - } +// cout << "stressRooStats: WARNING running in write mode, but reference file is web file, writing local file instead: " +// << refFileName << endl; +// } // Disable caching of complex error function calculation, as we don't // want to write out the cache file as part of the validation procedure RooMath::cacheCERF(kFALSE) ; gBenchmark = new TBenchmark(); - stressRooStats(refFileName.c_str(), doWrite, verbose, oneTest, dryRun, doDump, doTreeStore); + stressRooStats(refFileName.c_str(), doWrite, verbose, allTests, oneTest, testNumber, dryRun, doDump, doTreeStore); return 0; } diff --git a/test/stressRooStats_models.cxx b/test/stressRooStats_models.cxx index 7a52f2d94e712..ba0fe8080a597 100644 --- a/test/stressRooStats_models.cxx +++ b/test/stressRooStats_models.cxx @@ -6,15 +6,51 @@ // RooStats headers #include "RooStats/ModelConfig.h" +using namespace RooFit; using namespace RooStats; + +//__________________________________________________________________________________ +void buildSimultaneousModel(RooWorkspace *w) +{ + // Build model + w->factory("sig[8,0,50]"); + w->factory("Uniform::u1(x1[0,1])"); + w->factory("Uniform::u2(x2[0,1])"); + w->factory("Gaussian::constr1(gbkg1[50,0,100], bkg1[50,0,100], 3)"); + w->factory("Gaussian::constr2(gbkg2[50,0,100], bkg2[50,0,100], 2)"); + + w->factory("ExtendPdf::ext_pdf1(PROD::p1(u1,constr1), expr::n1('sig+bkg1', sig, bkg1))"); + w->factory("ExtendPdf::ext_pdf2(PROD::p2(u2,constr2), expr::n2('sig+bkg2', sig, bkg2))"); + w->factory("SIMUL::sim_pdf(index[cat1,cat2],cat1=ext_pdf1,cat2=ext_pdf2)"); + + // create combined signal + background model configuration + ModelConfig *sbModel = new ModelConfig("S+B", w); + sbModel->SetObservables("x1,x2,index"); + sbModel->SetParametersOfInterest("sig"); + sbModel->SetGlobalObservables("gbkg1,gbkg2"); + sbModel->SetNuisanceParameters("bkg1,bkg2"); + sbModel->SetPdf("sim_pdf"); + w->import(*sbModel); + + // create combined background model configuration + ModelConfig *bModel = new ModelConfig(*sbModel); + bModel->SetName("B"); + w->import(*bModel); + + // define data set + RooRandom::randomGenerator()->Rndm(); //wast a number to get a better dataset (not too high significance) and closer to expected + RooDataSet *data = w->pdf("sim_pdf")->generate(*sbModel->GetObservables(), Extended(), Name("data")); + w->import(*data); +} + //__________________________________________________________________________________ void buildPoissonProductModel(RooWorkspace *w) { // Build product model - w->factory("expr::compsig('2*sig*pow(1.2, beta)', sig[0,20], beta[-3,3])"); + w->factory("expr::comp_sig('2*sig*pow(1.2, beta)', sig[0,20], beta[-3,3])"); w->factory("Poisson::poiss1(x[0,40], sum::splusb1(sig, bkg1[0,10]))"); - w->factory("Poisson::poiss2(y[0,120], sum::splusb2(compsig, bkg2[0,10]))"); + w->factory("Poisson::poiss2(y[0,120], sum::splusb2(comp_sig, bkg2[0,10]))"); w->factory("Poisson::constr1(gbkg1[5,0,10], bkg1)"); w->factory("Poisson::constr2(gbkg2[5,0,10], bkg2)"); w->factory("Gaussian::constr3(beta0[0,-3,3], beta, 1)"); @@ -25,46 +61,35 @@ void buildPoissonProductModel(RooWorkspace *w) // Nuisance parameters Pdf (for HybridCalculator) w->factory("PROD::prior_nuis(constr1,constr2,constr3)"); - // build argument sets - w->defineSet("obs", "x,y"); - w->defineSet("poi", "sig"); - w->defineSet("nuis", "bkg1,bkg2,beta"); - w->defineSet("globObs", "beta0,gbkg1,gbkg2"); - - // set global observables to constant values - RooFIter iter = w->set("globObs")->fwdIterator(); - RooRealVar *var; - while ((var = (RooRealVar *)iter.next()) != NULL) var->setConstant(); - - // build data set and import it into the workspace sets - RooDataSet *data = new RooDataSet("data", "data", *w->set("obs")); - w->import(*data); - // create signal + background model configuration ModelConfig *sbModel = new ModelConfig("S+B", w); - sbModel->SetObservables(*w->set("obs")); - sbModel->SetGlobalObservables(*w->set("globObs")); - sbModel->SetParametersOfInterest(*w->set("poi")); - sbModel->SetNuisanceParameters(*w->set("nuis")); + sbModel->SetObservables("x,y"); + sbModel->SetGlobalObservables("beta0,gbkg1,gbkg2"); + sbModel->SetParametersOfInterest("sig"); + sbModel->SetNuisanceParameters("beta,bkg1,bkg2"); sbModel->SetPdf("pdf"); - // sbModel->SetPriorPdf("prior"); + w->import(*sbModel); // create background model configuration ModelConfig *bModel = new ModelConfig(*sbModel); bModel->SetName("B"); - // bModel->SetPriorPdf("prior_nuis"); - - w->import(*sbModel); w->import(*bModel); + + // define data set + RooDataSet *data = new RooDataSet("data", "data", *sbModel->GetObservables()); + w->import(*data); } +//__________________________________________________________________________________ +// Insightful comments on model courtesy of Kyle Cranmer, Wouter Verkerke, Sven Kreiss +// from $ROOTSYS/tutorials/roostats/HybridInstructional.C void buildOnOffModel(RooWorkspace *w) { // Build model for prototype on/off problem // Poiss(x | s+b) * Poiss(y | tau b ) - w->factory("Poisson::on_pdf(n_on[0,500],sum::splusb(sig[0,500],bkg[0,500]))"); - w->factory("Poisson::off_pdf(n_off[0,500],prod::taub(tau[0.1,5.0],bkg))"); + w->factory("Poisson::on_pdf(n_on[0,300],sum::splusb(sig[0,100],bkg[0,200]))"); + w->factory("Poisson::off_pdf(n_off[0,1100],prod::taub(tau[0.1,5.0],bkg))"); w->factory("PROD::prod_pdf(on_pdf, off_pdf)"); // construct the Bayesian-averaged model (eg. a projection pdf) @@ -72,81 +97,57 @@ void buildOnOffModel(RooWorkspace *w) w->factory("Uniform::prior(bkg)"); w->factory("PROJ::averagedModel(PROD::foo(on_pdf|bkg,off_pdf,prior),bkg)") ; - // define sets of variables obs={x} and poi={sig} - // x is the only observable in the main measurement and y is treated as a separate measurement, - // which is used to produce the prior that will be used in the calculation to randomize the nuisance parameters - w->defineSet("obs", "n_on,n_off,tau"); - w->defineSet("poi", "sig"); - w->defineSet("nuis", "bkg"); - - // define data set and import it into workspace - RooDataSet *data = new RooDataSet("data", "data", *w->set("obs")); - w->import(*data); - // create signal + background model configuration ModelConfig *sbModel = new ModelConfig("S+B", w); - sbModel->SetPdf(*w->pdf("prod_pdf")); - sbModel->SetObservables(*w->set("obs")); - sbModel->SetParametersOfInterest(*w->set("poi")); - sbModel->SetNuisanceParameters(*w->set("nuis")); + sbModel->SetPdf("prod_pdf"); + sbModel->SetObservables("n_on,n_off"); + sbModel->SetParametersOfInterest("sig"); + sbModel->SetNuisanceParameters("bkg"); + w->import(*sbModel); // create background model configuration ModelConfig *bModel = new ModelConfig(*sbModel); bModel->SetName("B"); + w->import(*bModel); // alternate priors w->factory("Gaussian::gauss_prior(bkg, n_off, expr::sqrty('sqrt(n_off)', n_off))"); w->factory("Lognormal::lognorm_prior(bkg, n_off, expr::kappa('1+1./sqrt(n_off)',n_off))"); - w->import(*sbModel); - w->import(*bModel); + // define data set + RooDataSet *data = new RooDataSet("data", "data", *sbModel->GetObservables()); + w->import(*data); } -void createPoissonEfficiencyModel(RooWorkspace *w) +void buildPoissonEfficiencyModel(RooWorkspace *w) { // build models w->factory("Gaussian::constrb(b0[-5,5], b1[-5,5], 1)"); w->factory("Gaussian::constre(e0[-5,5], e1[-5,5], 1)"); - w->factory("expr::bkg('5 * pow(1.3, b1)', b1)"); // background model - w->factory("expr::eff('0.5 * pow(1.2, e1)', e1)"); // efficiency model - w->factory("expr::splusb('eff * sig + bkg', eff, bkg, sig[0,20])"); - w->factory("Poisson::sb_poiss(x[0,40], splusb)"); - w->factory("Poisson::b_poiss(x, bkg)"); - w->factory("PROD::sb_pdf(sb_poiss, constrb, constre)"); - w->factory("PROD::b_pdf(b_poiss, constrb)"); - w->factory("PROD::priorbkg(constr1, constr2)"); - - w->var("b0")->setConstant(kTRUE); - w->var("e0")->setConstant(kTRUE); - - // build argument sets - w->defineSet("obs", "x"); - w->defineSet("poi", "sig"); - w->defineSet("nuis", "b1,e1"); - w->defineSet("globObs", "b0,e0"); - - // define data set and import it into workspace - RooDataSet *data = new RooDataSet("data", "data", *w->set("obs")); - w->import(*data); + w->factory("expr::bkg('5 * pow(1.3, b1)', b1)"); // background + w->factory("expr::eff('0.5 * pow(1.2, e1)', e1)"); // efficiency + w->factory("expr::esb('eff * sig + bkg', eff, bkg, sig[0,50])"); + w->factory("Poisson::poiss(x[0,50], esb)"); + w->factory("PROD::pdf(poiss, constrb, constre)"); // create model configuration ModelConfig *sbModel = new ModelConfig("S+B", w); - sbModel->SetObservables(*w->set("obs")); - sbModel->SetParametersOfInterest(*w->set("poi")); - sbModel->SetNuisanceParameters(*w->set("nuis")); - sbModel->SetPdf("sb_pdf"); - //sbModel->SetPriorPdf("prior"); - sbModel->SetSnapshot(*w->set("poi")); - sbModel->SetGlobalObservables(*w->set("globObs")); + sbModel->SetObservables("x"); + sbModel->SetParametersOfInterest("sig"); + sbModel->SetNuisanceParameters("b1,e1"); + sbModel->SetGlobalObservables("b0,e0"); + sbModel->SetPdf("pdf"); + w->import(*sbModel); ModelConfig *bModel = new ModelConfig(*sbModel); bModel->SetName("B"); - bModel->SetPdf("b_pdf"); - - w->import(*sbModel); w->import(*bModel); + + // define data set and import it into workspace + RooDataSet *data = new RooDataSet("data", "data", *sbModel->GetObservables()); + w->import(*data); } diff --git a/test/stressRooStats_ref.root b/test/stressRooStats_ref.root new file mode 100644 index 0000000000000..23003bf99d9e6 Binary files /dev/null and b/test/stressRooStats_ref.root differ diff --git a/test/stressRooStats_tests.cxx b/test/stressRooStats_tests.cxx index cfaccb50f05ee..1bb3db39eac66 100644 --- a/test/stressRooStats_tests.cxx +++ b/test/stressRooStats_tests.cxx @@ -15,6 +15,7 @@ #include "RooStats/NumberCountingUtils.h" #include "RooStats/RooStatsUtils.h" #include "RooStats/TestStatistic.h" +#include "RooStats/HypoTestCalculatorGeneric.h" #include "stressRooStats_models.cxx" // Global functions that build complex RooStats models @@ -29,9 +30,15 @@ using namespace RooStats; // = 4 Profile Likelihood Signed (pll = -pll if mu < mu_hat) // = 5 Max Likelihood Estimate as test statistic // = 6 Number of Observed Events as test statistic -enum ETestStatType { kSimpleLR = 0, kRatioLR = 1, kProfileLR = 2, kProfileLROneSided = 3, kProfileLRSigned = 4, kMLE = 5, kNObs = 6 }; -static const char *kECalculatorTypeString[] = { "Undefined", "Hybrid", "Frequentist", "Asymptotic" }; -static const char *kETestStatTypeString[] = { "Simple Likelihood Ratio", "Ratio Likelihood Ratio", "Profile Likelihood Ratio", "Profile Likelihood One Sided", "Profile Likelihood Signed", "Max Likelihood Estimate", "Number of Observed Events" }; +enum ECalculatorType { kAsymptotic = 0, kFrequentist = 1, kHybrid = 2 }; +enum ETestStatType { kSimpleLR = 0, kRatioLR = 1, kProfileLR = 2, kProfileLROneSided = 3, + kProfileLROneSidedDiscovery = 4, kProfileLRSigned = 5, kMLE = 6, kNObs = 7 }; +static const char * const kECalculatorTypeString[] = { "Asymptotic", "Frequentist", "Hybrid" }; +static const char * const kETestStatTypeString[] = { "Simple Likelihood Ratio", "Ratio Of Profiled Likelihoods", + "Profile Likelihood Ratio", "Profile Likelihood One-Sided", "Profile Likelihood One-Sided Discovery", + "Profile Likelihood Signed", "Max Likelihood Estimate", "Number Of Observed Events" }; +static HypoTestCalculatorGeneric * buildHypoTestCalculator(const ECalculatorType calculatorType, RooAbsData &data, + const ModelConfig &nullModel, const ModelConfig &altModel, const UInt_t toysNull, const UInt_t toysAlt); static TestStatistic *buildTestStatistic(const ETestStatType testStatType, const ModelConfig &sbModel, const ModelConfig &bModel); @@ -115,7 +122,7 @@ class TestProfileLikelihoodCalculator1 : public RooUnitTest { // Calculate likelihood interval from data via analytic methods Double_t estMean = data->mean(*w->var("x")); Double_t intervalHalfWidth = - normal_quantile_c((1.0 - fConfidenceLevel) / 2.0, w->var("sigma")->getValV() / sqrt(N)); + normal_quantile_c((1.0 - fConfidenceLevel) / 2.0, w->var("sigma")->getValV() / sqrt((double)N)); Double_t lowerLimit = estMean - intervalHalfWidth; Double_t upperLimit = estMean + intervalHalfWidth; @@ -254,7 +261,7 @@ class TestProfileLikelihoodCalculator2 : public RooUnitTest { /////////////////////////////////////////////////////////////////////////////// // -// PROFILE LIKELIHOOD CALCULATOR - LIKELIHOOD INTERVAL - POISSON COMPLEX MODEL +// PROFILE LIKELIHOOD CALCULATOR - LIKELIHOOD INTERVAL - POISSON PRODUCT MODEL // // Test the 68% likelihood interval computed by the ProfileLikelihoodCalculator // on a complex model. Reference values and test values are both computed with @@ -298,12 +305,12 @@ class TestProfileLikelihoodCalculator3 : public RooUnitTest { // Basic checks for the parameters passed to the test // In case of invalid parameters, a warning is printed and the test is skipped Bool_t isTestAvailable() { - if (fObsValueX < 0 || fObsValueX > 40) { - Warning("isTestAvailable", "Observed value X=s+b must be in the range [0,40]. Skipping test..."); + if (fObsValueX < 0 || fObsValueX > 30) { + Warning("isTestAvailable", "Observed value X=s+b must be in the range [0,30]. Skipping test..."); return kFALSE; } - if (fObsValueY < 0 || fObsValueY > 120) { - Warning("isTestAvailable", "Observed value Y=2*s*1.2^beta+b must be in the range [0,120]. Skipping test..."); + if (fObsValueY < 0 || fObsValueY > 80) { + Warning("isTestAvailable", "Observed value Y=2*s*1.2^beta+b must be in the range [0,80]. Skipping test..."); return kFALSE; } if (fConfidenceLevel <= 0.0 || fConfidenceLevel >= 1.0) { @@ -323,7 +330,7 @@ class TestProfileLikelihoodCalculator3 : public RooUnitTest { // add observed values to data set w->var("x")->setVal(fObsValueX); w->var("y")->setVal(fObsValueY); - w->data("data")->add(*w->set("obs")); + w->data("data")->add(*model->GetObservables()); // build likelihood interval with ProfileLikelihoodCalculator ProfileLikelihoodCalculator *plc = new ProfileLikelihoodCalculator(*w->data("data"), *model); @@ -351,12 +358,13 @@ class TestProfileLikelihoodCalculator3 : public RooUnitTest { /////////////////////////////////////////////////////////////////////////////// // -// PROFILE LIKELIHOOD CALCULATOR - HYPOTHESIS TEST +// PROFILE LIKELIHOOD CALCULATOR HYPOTHESIS TEST - ON / OFF MODEL // // Perform a hypothesis test using the ProfileLikelihoodCalculator on the // on/off model. Reference values and test values are both computed with the // ProfileLikelihoodCalculator. As such, this test can only confirm if the -// ProfileLikelihoodCalculator has the same behaviour on a different machine. +// ProfileLikelihoodCalculator has the same behaviour accross different +// computing platforms or RooStats revisions. // // ModelConfig (explicit) : Poisson On / Off Model // built in stressRooStats_models.cxx @@ -398,7 +406,7 @@ class TestProfileLikelihoodCalculator4 : public RooUnitTest { const Double_t tau[numberTestSets] = {5.0, 2.0, 0.5}; const Double_t significance[numberTestSets] = {1.95, 3.02, 3.04}; - for (Int_t i = 0; i < numberTestSets; i++) { + for (Int_t i = 0; i < numberTestSets; ++i) { TString stringSignificance = TString::Format("tplc4_significance_%d_%d_%lf", numberOnEvents[i], numberOffEvents[i], tau[i]); @@ -420,24 +428,26 @@ class TestProfileLikelihoodCalculator4 : public RooUnitTest { w->var("n_off")->setVal(numberOffEvents[i]); w->var("tau")->setVal(tau[i]); w->var("tau")->setConstant(); - w->data("data")->add(*w->set("obs")); + w->data("data")->add(*sbModel->GetObservables()); // set snapshots w->var("sig")->setVal(numberOnEvents[i] - numberOffEvents[i] / tau[i]); - sbModel->SetSnapshot(*w->set("poi")); + sbModel->SetSnapshot(*sbModel->GetParametersOfInterest()); w->var("sig")->setVal(0); - bModel->SetSnapshot(*w->set("poi")); + bModel->SetSnapshot(*bModel->GetParametersOfInterest()); + + // has as initial value a non-zero value for sig (i.e start with the S+B value) + sbModel->LoadSnapshot(); + // get significance using the ProfileLikelihoodCalculator ProfileLikelihoodCalculator *plc = new ProfileLikelihoodCalculator(*w->data("data"), *sbModel); plc->SetNullParameters(*bModel->GetSnapshot()); - plc->SetAlternateParameters(*sbModel->GetSnapshot()); - HypoTestResult *htr = plc->GetHypoTest(); + //plc->SetAlternateParameters(*sbModel->GetSnapshot()); // not needed for PLC - regValue(htr->Significance(), stringSignificance); + regValue(plc->GetHypoTest()->Significance(), stringSignificance); // cleanup delete plc; - delete htr; delete w; } } @@ -766,7 +776,7 @@ class TestBayesianCalculator2 : public RooUnitTest { // on a complex Poisson model distribution. Reference values and test values // are both computed with the BayesianCalculator. As such, this test can only // confirm if the BayesianCalculator has the same behaviour across different -// computer platforms or RooStats revisions. A uniform prior PDF is used for the +// computing platforms or RooStats revisions. A uniform prior PDF is used for the // parameter of interest ("sig"). // // ModelConfig (explicit) : Poisson Product Model @@ -805,12 +815,12 @@ class TestBayesianCalculator3 : public RooUnitTest { // Basic checks for the parameters passed to the test // In case of invalid parameters, a warning is printed and the test is skipped Bool_t isTestAvailable() { - if (fObsValueX < 0 || fObsValueX > 40) { - Warning("isTestAvailable", "Observed value X=s+b must be in the range [0,40]. Skipping test..."); + if (fObsValueX < 0 || fObsValueX > 30) { + Warning("isTestAvailable", "Observed value X=s+b must be in the range [0,30]. Skipping test..."); return kFALSE; } - if (fObsValueY < 0 || fObsValueY > 120) { - Warning("isTestAvailable", "Observed value Y=2*s*1.2^beta+b must be in the range [0,120]. Skipping test..."); + if (fObsValueY < 0 || fObsValueY > 80) { + Warning("isTestAvailable", "Observed value Y=2*s*1.2^beta+b must be in the range [0,80]. Skipping test..."); return kFALSE; } if (fConfidenceLevel <= 0.0 || fConfidenceLevel >= 1.0) { @@ -832,7 +842,7 @@ class TestBayesianCalculator3 : public RooUnitTest { // add observed values to data set w->var("x")->setVal(fObsValueX); w->var("y")->setVal(fObsValueY); - w->data("data")->add(*w->set("obs")); + w->data("data")->add(*model->GetObservables()); // NOTE: Roo1DIntegrator is too slow and gives poor results RooAbsReal::defaultIntegratorConfig()->method1D().setLabel("RooAdaptiveGaussKronrodIntegrator1D"); @@ -892,8 +902,8 @@ class TestBayesianCalculator3 : public RooUnitTest { // Test the validity of the confidence interval computed by the MCMCCalculator // on a complex Poisson model distribution. Reference values and test values // are both computed with the MCMCCalculator. As such, this test can only -// confirm if the BayesianCalculator has the same behaviour across different -// computer platforms or RooStats revisions. +// confirm if the MCMCCalculator has the same behaviour across different +// computing platforms or RooStats revisions. // // ModelConfig (explicit) : Poisson Product Model // built in stressRooStats_models.cxx @@ -931,12 +941,12 @@ class TestMCMCCalculator : public RooUnitTest { // Basic checks for the parameters passed to the test // In case of invalid parameters, a warning is printed and the test is skipped Bool_t isTestAvailable() { - if (fObsValueX < 0 || fObsValueX > 40) { - Warning("isTestAvailable", "Observed value X=s+b must be in the range [0,40]. Skipping test..."); + if (fObsValueX < 0 || fObsValueX > 30) { + Warning("isTestAvailable", "Observed value X=s+b must be in the range [0,30]. Skipping test..."); return kFALSE; } - if (fObsValueY < 0 || fObsValueY > 120) { - Warning("isTestAvailable", "Observed value Y=2*s*1.2^beta+b must be in the range [0,120]. Skipping test..."); + if (fObsValueY < 0 || fObsValueY > 80) { + Warning("isTestAvailable", "Observed value Y=2*s*1.2^beta+b must be in the range [0,80]. Skipping test..."); return kFALSE; } if (fConfidenceLevel <= 0.0 || fConfidenceLevel >= 1.0) { @@ -948,7 +958,6 @@ class TestMCMCCalculator : public RooUnitTest { Bool_t testCode() { - // Create workspace and model RooWorkspace *w = new RooWorkspace("w", kTRUE); buildPoissonProductModel(w); @@ -957,8 +966,7 @@ class TestMCMCCalculator : public RooUnitTest { // add observed values to data set w->var("x")->setVal(fObsValueX); w->var("y")->setVal(fObsValueY); - w->data("data")->add(*w->set("obs")); - + w->data("data")->add(*model->GetObservables()); // NOTE: Roo1DIntegrator is too slow and gives poor results RooAbsReal::defaultIntegratorConfig()->method1D().setLabel("RooAdaptiveGaussKronrodIntegrator1D"); @@ -1009,35 +1017,377 @@ class TestMCMCCalculator : public RooUnitTest { /////////////////////////////////////////////////////////////////////////////// // // PART FOUR: -// HYPOTHESIS TEST INVERTER UNIT TESTS +// HYPOTHESIS TEST CALCULATOR UNIT TESTS // -#include "RooStats/HypoTestInverter.h" -#include "RooStats/HypoTestInverterResult.h" +// Hypo Test Calculators #include "RooStats/HypoTestCalculatorGeneric.h" -#include "RooStats/ToyMCSampler.h" #include "RooStats/FrequentistCalculator.h" #include "RooStats/HybridCalculator.h" -#include "RooStats/ProfileLikelihoodTestStat.h" #include "RooStats/AsymptoticCalculator.h" +#include "RooStats/HypoTestPlot.h" +// Test Statistics +#include "RooStats/ProfileLikelihoodTestStat.h" +#include "RooStats/RatioOfProfiledLikelihoodsTestStat.h" +#include "RooStats/SimpleLikelihoodRatioTestStat.h" +#include "RooStats/ProfileLikelihoodCalculator.h" +#include "RooStats/MaxLikelihoodEstimateTestStat.h" +#include "RooStats/NumEventsTestStat.h" + +///////////////////////////////////////////////////////////////////////// +// +// ZBI - ON / OFF MODEL +// +// Evaluate the functionality of the top level functions in RooStats +// called NumberCountingUtils::BinomialWithTauObsZ. This function +// computes the significance of a hypothesis test via a frequentist +// solution. This significance, called ZBi, is detailed in the article +// "Evaluation of three methods for calculating statistical significance +// when incorporating a systematic uncertainty into a test of the +// background-only hypothesis for a Poisson process" by Robert D. Cousins, +// James T. Linnemann, Jordan Tucker. The reference values are taken +// from the paper, as well as the On / Off model on which the test is +// evaluated. +// +// ModelConfig (implicit) : Poisson On / Off Model +// built in stressRooStats_models.cxx +// implicit in NumberCountingUtils::BinomialWithTauObsZ +// +// 05/2012 - Wouter Verkerke, Lorenzo Moneta, Ioan Gabriel Bucur +// +///////////////////////////////////////////////////////////////////////// + + +class TestZBi : public RooUnitTest { +public: + + TestZBi( + TFile* refFile, + Bool_t writeRef, + Int_t verbose + ) : + RooUnitTest("ZBi Significance - On / Off Model", refFile, writeRef, verbose) + {}; + + // Override test value tolerance + // A larger tolerance is needed since the values in the Cousins paper are given with 1e-2 precision + Double_t vtol() { + return 1e-2; + } + + Bool_t testCode() { + + // For testing purposes, we consider four special cases for which the values are known from + // the Cousins et al. paper mentioned above. The inputs for each of these cases are (using + // the notations from the paper): n_on, n_off and Z_PL. We provide a certain fixed input set + // for each case. + const Int_t numberTestSets = 4; + const Int_t numberOnEvents[numberTestSets] = {4, 50, 67, 200}; + const Int_t numberOffEvents[numberTestSets] = {5, 55, 15, 10}; + const Double_t tau[numberTestSets] = {5.0, 2.0, 0.5, 0.1}; + const Double_t significance[numberTestSets] = {1.66, 2.93, 2.89, 2.2}; + + for (Int_t i = 0; i < numberTestSets; ++i) { + + TString stringSignificance = TString::Format("tzbi_significance_%d_%d_%lf", numberOnEvents[i], numberOffEvents[i], tau[i]); + + if (_write == kTRUE) { + + // register reference values from Cousins et al. paper + regValue(significance[i], stringSignificance); + + } else { + + // call top level function + regValue( + NumberCountingUtils::BinomialWithTauObsZ(numberOnEvents[i], numberOffEvents[i], tau[i]), + stringSignificance + ); + + } + } + + return kTRUE ; + } +}; + + +/////////////////////////////////////////////////////////////////////////////// +// +// ASYMPTOTIC CALCULATOR VS PROFILE LIKELIHOOD CALCULATOR HYPOTHESIS TEST +// +// This test evaluates the functionality of the AsymptoticCalculator by +// comparing the significance given from a hypothesis test on the on/off model +// with the significance given by the ProfileLikelihoodCalculator. The validity +// of the PLC hypothesis test is evaluated in TestProfileLikelihoodCalculator4. +// If working properly, the two methods should yield identical results. +// +// ModelConfig (explicit) : Poisson On / Off Model +// built in stressRooStats_models.cxx +// +// Input Parameters: +// obsValueOn -> observed value "n_on" of sig + bkg +// obsValueOff -> observed value "n_off" of tau * bkg +// tau -> parameter of the model (constant with regard to integration) +// +// 05/2012 - Ioan Gabriel Bucur +// +/////////////////////////////////////////////////////////////////////////////// + +class TestHypoTestCalculator1 : public RooUnitTest { +private: + Int_t fObsValueOn; + Int_t fObsValueOff; + Double_t fTau; + +public: + TestHypoTestCalculator1( + TFile* refFile, + Bool_t writeRef, + Int_t verbose, + Int_t obsValueOn = 150, + Int_t obsValueOff = 100, + Double_t tau = 1.0 + ) : + RooUnitTest("AsymptoticCalculator vs ProfileLikelihoodCalculator Significance - On / Off Model", refFile, writeRef, verbose), + fObsValueOn(obsValueOn), + fObsValueOff(obsValueOff), + fTau(tau) + {}; + + // Basic checks for the parameters passed to the test + // In case of invalid parameters, a warning is printed and the test is skipped + Bool_t isTestAvailable() { + if (fObsValueOn < 0 || fObsValueOn > 300) { + Warning("isTestAvailable", "Observed value on_source=s+b must be in the range [0,300]. Skipping test..."); + return kFALSE; + } + if (fObsValueOff < 0 || fObsValueOff > 1100) { + Warning("isTestAvailable", "Observed value off_source=tau*b must be in the range [0,1100]. Skipping test..."); + return kFALSE; + } + if (fTau < 0.1 || fTau > 5.0) { + Warning("isTestAvailable", "On/Off model parameter 'tau' must be in the range [0.1,5.0]. Skipping test..."); + return kFALSE; + } + return kTRUE; + } + + Bool_t testCode() { + + // names of tested variables must be the same in write / comparison modes + TString significanceString = TString::Format("thtc1_significance_%d_%d_%lf", fObsValueOn, fObsValueOff, fTau); + + // build workspace and model + RooWorkspace* w = new RooWorkspace("w", kTRUE); + buildOnOffModel(w); + ModelConfig *sbModel = (ModelConfig *)w->obj("S+B"); + ModelConfig *bModel = (ModelConfig *)w->obj("B"); + + // add observable values to data set and fix other parameters + w->var("n_on")->setVal(fObsValueOn); + w->var("n_off")->setVal(fObsValueOff); + w->var("tau")->setVal(fTau); + w->var("tau")->setConstant(); + w->data("data")->add(*sbModel->GetObservables()); + w->var("bkg")->setVal(fObsValueOff / fTau); + + // Make snapshots + w->var("sig")->setVal(fObsValueOn - fObsValueOff / fTau); + sbModel->SetSnapshot(*sbModel->GetParametersOfInterest()); + w->var("sig")->setVal(0.0); + bModel->SetSnapshot(*bModel->GetParametersOfInterest()); + + // Do hypothesis test with ProfileLikelihoodCalculator + if (_write == kTRUE) { + + ProfileLikelihoodCalculator *plc = new ProfileLikelihoodCalculator(*w->data("data"), *sbModel); + plc->SetNullParameters(*bModel->GetSnapshot()); + plc->SetAlternateParameters(*sbModel->GetSnapshot()); + regValue(plc->GetHypoTest()->Significance(), significanceString); + + // cleanup branch + delete plc; + + } else { // Do hypothesis test with AsymptoticCalculator + + AsymptoticCalculator::SetPrintLevel(0); // disable superfluous messaging + AsymptoticCalculator *atc = new AsymptoticCalculator(*w->data("data"), *sbModel, *bModel); + atc->SetOneSidedDiscovery(kTRUE); + regValue(atc->GetHypoTest()->Significance(), significanceString); + + // cleanup branch + delete atc; + } + + // cleanup + delete w; + + return kTRUE ; + } +} ; + + +/////////////////////////////////////////////////////////////////////////////// +// +// HYPOTHESIS TEST CALCULATOR TEST - SIMULTANEOUS PDF MODEL +// +// This test evaluates the functionality of the HypoTestCalculator by +// calculating the significance of the signal on a simple Simultaneous Pdf +// model with two channels. Reference values and test values are both computed +// with the HypoTestCalculator. As such, this test can only confirm if the +// HypoTestCalculator has the same behaviour across different computing +// platforms or RooStats revisions. +// +// ModelConfig (explicit) : Simultaneous Model +// built in stressRooStats_models.cxx +// +// Input Parameters: +// calculatorType -> Frequentist, Hybrid or Asymptotic +// testStatType -> Profile Likelihood Ratio, Simple Likelihood Ratio, etc... +// +// 06/2012 - Ioan Gabriel Bucur +// +/////////////////////////////////////////////////////////////////////////////// + +class TestHypoTestCalculator2 : public RooUnitTest { +private: + ECalculatorType fCalculatorType; + ETestStatType fTestStatType; + +public: + TestHypoTestCalculator2( + TFile* refFile, + Bool_t writeRef, + Int_t verbose, + ECalculatorType calculatorType = kAsymptotic, + ETestStatType testStatType = kProfileLROneSidedDiscovery + ) : + RooUnitTest(TString::Format("HypoTestCalculator Significance - Simultaneous Pdf - %s - %s", + kECalculatorTypeString[calculatorType], kETestStatTypeString[testStatType]), refFile, writeRef, verbose), + fCalculatorType(calculatorType), + fTestStatType(testStatType) + {}; + + Bool_t testCode() { + + // Build workspace and models + RooWorkspace* w = new RooWorkspace("w", kTRUE); + buildSimultaneousModel(w); + ModelConfig *sbModel = (ModelConfig *)w->obj("S+B"); + ModelConfig *bModel = (ModelConfig *)w->obj("B"); + + // set snapshots + sbModel->SetSnapshot(*sbModel->GetParametersOfInterest()); // value set in model + w->var("sig")->setVal(0); + bModel->SetSnapshot(*bModel->GetParametersOfInterest()); + + HypoTestCalculatorGeneric *calc = + buildHypoTestCalculator(fCalculatorType, *w->data("data"), *bModel, *sbModel, 500, 50); + if(fCalculatorType == kAsymptotic) { ((AsymptoticCalculator *)calc)->SetOneSidedDiscovery(kTRUE); } + + // ToyMCSampler configuration + ToyMCSampler *tmcs = (ToyMCSampler *)calc->GetTestStatSampler(); + tmcs->SetTestStatistic(buildTestStatistic(fTestStatType, *bModel, *sbModel)); + tmcs->SetUseMultiGen(kTRUE); // speedup + + // Register result (test significance) + HypoTestResult *htr = calc->GetHypoTest(); + regValue(htr->Significance(), TString::Format("thtc2_significance_%s_%s", + kECalculatorTypeString[fCalculatorType], + kETestStatTypeString[fTestStatType])); + + // corresponding visual plots (in verbose mode) - from tutorials/roostats/StandardHypoTestDemo.C + if (_verb >= 1) { + if(fCalculatorType != kAsymptotic) { + TCanvas *c = new TCanvas("thtc2_canvas", "THTC2 Canvas"); + + c->cd(1); + HypoTestPlot *plot = new HypoTestPlot(*htr,100); + plot->SetLogYaxis(kTRUE); + plot->Draw(); + + SamplingDistribution *altDist = htr->GetAltDistribution(); + HypoTestResult htExp("Expected result"); + htExp.Append(htr); + // find quantiles in alt (S+B) distribution + Double_t p[5], q[5]; + for(Int_t i = 0; i < 5; ++i) { + Double_t sig = -2 + i; + p[i] = ROOT::Math::normal_cdf(sig,1); + } + std::vector<Double_t> values = altDist->GetSamplingDistribution(); + TMath::Quantiles( values.size(), 5, &values[0], q, p, kFALSE); + + for(Int_t i = 0; i < 5; ++i) { + htExp.SetTestStatisticData( q[i] ); + Double_t sig = -2 + i; + std::cout << "Expected p-value and significance at " << sig << " sigma = " + << htExp.NullPValue() << " significance " << htExp.Significance() << " sigma " << std::endl; + } + c->SaveAs(TString::Format("thtc2_scan_%s_%s.pdf", + kECalculatorTypeString[fCalculatorType], + kETestStatTypeString[fTestStatType])); + } else { + for(Int_t i = 0; i < 5; ++i) { + Double_t sig = -2 + i; + Double_t pval = AsymptoticCalculator::GetExpectedPValues(htr->NullPValue(), htr->AlternatePValue(), -sig, kFALSE); + std::cout << "Expected p-value and significance at " << sig << " sigma = " + << pval << " significance " << ROOT::Math::normal_quantile_c(pval,1) << " sigma " << std::endl; + } + } + } + + delete calc; + delete htr; + delete w; + + return kTRUE ; + } +} ; + + +// +// END OF PART FOUR +// +/////////////////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////////////////// +//_____________________________________________________________________________ + + + + + +//_____________________________________________________________________________ +/////////////////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////////////////// +// +// PART FIVE: +// HYPOTHESIS TEST INVERTER UNIT TESTS +// + +#include "RooStats/HypoTestInverter.h" +#include "RooStats/HypoTestInverterResult.h" +#include "RooStats/ToyMCSampler.h" #include "RooStats/HypoTestInverterPlot.h" #include "RooStats/SamplingDistPlot.h" - /////////////////////////////////////////////////////////////////////////////// // // HYPOTESTINVERTER INTERVAL - POISSON PRODUCT MODEL // // Test the validity of the confidence interval computed by the HypoTestInverter // on a complex Poisson model distribution. Reference values and test values -// are both computed with the MCMCCalculator. As such, this test can only -// confirm if the BayesianCalculator has the same behaviour across different -// computer platforms or RooStats revisions. +// are both computed with the HypoTestInverter. As such, this test can only +// confirm if the HypoTestInverter has the same behaviour across different +// computing platforms or RooStats revisions. // // ModelConfig (explicit) : Poisson Product Model // built in stressRooStats_models.cxx // // Input Parameters: +// calculatorType -> Frequentist, Hybrid or Asymptotic +// testStatType -> Profile Likelihood Ratio, Simple Likelihood Ratio, etc... // obsValueX -> observed value "x" when measuring sig + bkg1 // obsValueY -> observed value "y" when measuring 2*sig*1.2^beta + bkg2 // confidenceLevel -> Confidence Level of the interval we are calculating @@ -1049,7 +1399,7 @@ class TestMCMCCalculator : public RooUnitTest { class TestHypoTestInverter1 : public RooUnitTest { private: - HypoTestInverter::ECalculatorType fCalculatorType; + ECalculatorType fCalculatorType; ETestStatType fTestStatType; Int_t fObsValueX; Int_t fObsValueY; @@ -1060,13 +1410,13 @@ class TestHypoTestInverter1 : public RooUnitTest { TFile* refFile, Bool_t writeRef, Int_t verbose, - HypoTestInverter::ECalculatorType calculatorType, - ETestStatType testStatType, + ECalculatorType calculatorType = kAsymptotic, + ETestStatType testStatType = kProfileLR, Int_t obsValueX = 15, Int_t obsValueY = 30, Double_t confidenceLevel = 2 * normal_cdf(1) - 1 ) : - RooUnitTest(TString::Format("HypoTestInverter Interval - Poisson Product Model - %s %s", + RooUnitTest(TString::Format("HypoTestInverter Interval - Poisson Product Model - %s - %s", kECalculatorTypeString[calculatorType], kETestStatTypeString[testStatType]), refFile, writeRef, verbose), fCalculatorType(calculatorType), fTestStatType(testStatType), @@ -1078,12 +1428,12 @@ class TestHypoTestInverter1 : public RooUnitTest { // Basic checks for the parameters passed to the test // In case of invalid parameters, a warning is printed and the test is skipped Bool_t isTestAvailable() { - if (fObsValueX < 0 || fObsValueX > 40) { - Warning("isTestAvailable", "Observed value X=s+b must be in the range [0,40]. Skipping test..."); + if (fObsValueX < 0 || fObsValueX > 30) { + Warning("isTestAvailable", "Observed value X=s+b must be in the range [0,30]. Skipping test..."); return kFALSE; } - if (fObsValueY < 0 || fObsValueY > 120) { - Warning("isTestAvailable", "Observed value Y=2*s*1.2^beta+b must be in the range [0,120]. Skipping test..."); + if (fObsValueY < 0 || fObsValueY > 80) { + Warning("isTestAvailable", "Observed value Y=2*s*1.2^beta+b must be in the range [0,80]. Skipping test..."); return kFALSE; } if (fConfidenceLevel <= 0.0 || fConfidenceLevel >= 1.0) { @@ -1104,40 +1454,22 @@ class TestHypoTestInverter1 : public RooUnitTest { // add observed values to data set w->var("x")->setVal(fObsValueX); w->var("y")->setVal(fObsValueY); - w->data("data")->add(*w->set("obs")); + w->data("data")->add(*sbModel->GetObservables()); // set snapshots w->var("sig")->setVal(fObsValueX - w->var("bkg1")->getValV()); - sbModel->SetSnapshot(*w->set("poi")); + sbModel->SetSnapshot(*sbModel->GetParametersOfInterest()); w->var("sig")->setVal(0); - bModel->SetSnapshot(*w->set("poi")); - - //TODO: check how to eliminate this code, maybe 0 should be default print level for AsymptoticCalculator - if (fCalculatorType == HypoTestInverter::kAsymptotic) { - AsymptoticCalculator::SetPrintLevel(0); // print only minimal output - } + bModel->SetSnapshot(*bModel->GetParametersOfInterest()); - // configure HypoTestInverter - HypoTestInverter *hti = - new HypoTestInverter(*w->data("data"), *sbModel, *bModel, NULL, fCalculatorType, 1.0 - fConfidenceLevel); + // build and configure HypoTestInverter + HypoTestCalculatorGeneric *calc = + buildHypoTestCalculator(fCalculatorType, *w->data("data"), *sbModel, *bModel, 100, 1); + HypoTestInverter *hti = new HypoTestInverter(*calc, NULL, 1.0 - fConfidenceLevel); hti->SetTestStatistic(*buildTestStatistic(fTestStatType, *sbModel, *bModel)); hti->SetFixedScan(10, w->var("sig")->getMin(), w->var("sig")->getMax()); // significant speedup - - //TODO: check how to eliminate this code, calculator should autoconfigure itself - if (fCalculatorType == HypoTestInverter::kHybrid) { - // force prior nuisance pdf and set toys for speedup - HybridCalculator *hc = (HybridCalculator *)hti->GetHypoTestCalculator(); - hc->ForcePriorNuisanceNull(*MakeNuisancePdf(*sbModel, "nuis_prior_null")); - hc->ForcePriorNuisanceAlt(*MakeNuisancePdf(*bModel, "nuis_prior_alt")); - hc->SetToys(100,1); - } - //TODO: check how to eliminate this code - if (fCalculatorType == HypoTestInverter::kFrequentist) { - // set toys for speedup - FrequentistCalculator *fc = (FrequentistCalculator *)hti->GetHypoTestCalculator(); - fc->SetToys(100,1); - } + if(fCalculatorType == kAsymptotic) ((AsymptoticCalculator *)calc)->SetTwoSided(); // ToyMCSampler configuration ToyMCSampler *tmcs = (ToyMCSampler *)hti->GetHypoTestCalculator()->GetTestStatSampler(); @@ -1145,21 +1477,21 @@ class TestHypoTestInverter1 : public RooUnitTest { tmcs->SetUseMultiGen(kTRUE); // speedup HypoTestInverterResult *interval = hti->GetInterval(); - regValue(interval->LowerLimit(), TString::Format("hti1_lower_limit_sig1_calc_%s_%s_%d_%d_%lf", + regValue(interval->LowerLimit(), TString::Format("thti1_lower_limit_sig_%s_%s_%d_%d_%lf", kECalculatorTypeString[fCalculatorType], kETestStatTypeString[fTestStatType], fObsValueX, fObsValueY, fConfidenceLevel)); - regValue(interval->UpperLimit(), TString::Format("hti1_upper_limit_sig1_calc_%s_%s_%d_%d_%lf", + regValue(interval->UpperLimit(), TString::Format("thti1_upper_limit_sig_%s_%s_%d_%d_%lf", kECalculatorTypeString[fCalculatorType], kETestStatTypeString[fTestStatType], fObsValueX, fObsValueY, fConfidenceLevel)); if (_verb >= 1) { - HypoTestInverterPlot *plot = new HypoTestInverterPlot("hti1_scan", "Two-Sided Scan", interval); - TCanvas *c1 = new TCanvas("hti1_scan", "HTI Scan"); + HypoTestInverterPlot *plot = new HypoTestInverterPlot("thti1_scan", "Two-Sided Scan", interval); + TCanvas *c1 = new TCanvas("thti1_canvas", "THTI Canvas"); c1->SetLogy(false); - plot->Draw(""); - c1->SaveAs(TString::Format("hti1_scan_%s_%s_%d_%d_%lf.pdf", + plot->Draw("2CL CLB"); + c1->SaveAs(TString::Format("thti1_scan_%s_%s_%d_%d_%lf.pdf", kECalculatorTypeString[fCalculatorType], kETestStatTypeString[fTestStatType], fObsValueX, fObsValueY, fConfidenceLevel)); @@ -1167,20 +1499,20 @@ class TestHypoTestInverter1 : public RooUnitTest { if (_verb == 2) { const int n = interval->ArraySize(); if (n > 0 && interval->GetResult(0)->GetNullDistribution()) { - TCanvas *c2 = new TCanvas("HTI_TestStatistic_Distribution", "HTI Test Statistic Distributions", 2); + TCanvas *c2 = new TCanvas("thti1_teststat_dist", "HTI Test Statistic Distributions", 2); if (n > 1) { - int ny = TMath::CeilNint(sqrt(n)); + int ny = TMath::CeilNint(sqrt((double)n)); int nx = TMath::CeilNint(double(n) / ny); c2->Divide(nx, ny); } - for (int i = 0; i < n; i++) { + for (int i = 0; i < n; ++i) { if (n > 1) c2->cd(i + 1); SamplingDistPlot *pl = plot->MakeTestStatPlot(i); if (pl == NULL) return kTRUE; pl->SetLogYaxis(kTRUE); pl->Draw(); } - c2->SaveAs(TString::Format("hti1_teststat_distrib_%s_%s_%d_%d_%lf.pdf", + c2->SaveAs(TString::Format("thti1_teststat_distrib_%s_%s_%d_%d_%lf.pdf", kECalculatorTypeString[fCalculatorType], kETestStatTypeString[fTestStatType], fObsValueX, fObsValueY, fConfidenceLevel)); @@ -1198,111 +1530,188 @@ class TestHypoTestInverter1 : public RooUnitTest { }; -// -// END OF PART THREE -// /////////////////////////////////////////////////////////////////////////////// -/////////////////////////////////////////////////////////////////////////////// -//_____________________________________________________________________________ - - - - - -// OTHER TESTS FOLLOW - -///////////////////////////////////////////////////////////////////////// // -// 'BASIC FUNCTIONALITY' RooFit tutorial macro #101 +// HYPOTESTINVERTER UPPER LIMIT - SIGNAL + BACKGROUND + EFFICIENCY MODEL // -// Fitting, plotting, toy data generation on one-dimensional p.d.f +// Test the validity of the upper limit computed by the HypoTestInverter +// on a complex model distribution with signal, background and efficiency. +// Reference values and test values are both computed with the HypoTestInverter. +// As such, this test can only confirm if the HypoTestInverter has the same +// behaviour across different computing platforms or RooStats revisions. // -// pdf = gauss(x,m,s) +// ModelConfig (explicit) : Poisson Signal + Background + Efficiency +// built in stressRooStats_models.cxx // +/// Input Parameters: +// calculatorType -> Frequentist, Hybrid or Asymptotic +// testStatType -> Profile Likelihood Ratio, Simple Likelihood Ratio, etc... +// obsValueX -> observed value "x" when measuring sig * eff + bkg +// confidenceLevel -> Confidence Level of the upper limit we are calculating // -// 07/2008 - Wouter Verkerke +// 04/2012 - Ioan Gabriel Bucur // -///////////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////////////////// +class TestHypoTestInverter2 : public RooUnitTest { +private: + ECalculatorType fCalculatorType; + ETestStatType fTestStatType; + Int_t fObsValueX; + Double_t fConfidenceLevel; -class TestBasic101 : public RooUnitTest { public: - TestBasic101(TFile* refFile, Bool_t writeRef, Int_t verbose) : RooUnitTest("Zbi and Zgamma", refFile, writeRef, verbose) {}; + TestHypoTestInverter2( + TFile* refFile, + Bool_t writeRef, + Int_t verbose, + ECalculatorType calculatorType = kAsymptotic, + ETestStatType testStatType = kProfileLROneSided, + Int_t obsValueX = 10, + Double_t confidenceLevel = 2 * normal_cdf(1) - 1 + ) : + RooUnitTest(TString::Format("HypoTestInverter Upper Limit - Poisson Efficiency Model - %s - %s", + kECalculatorTypeString[calculatorType], kETestStatTypeString[testStatType]), refFile, writeRef, verbose), + fCalculatorType(calculatorType), + fTestStatType(testStatType), + fObsValueX(obsValueX), + fConfidenceLevel(confidenceLevel) + {}; - Bool_t testCode() { + Double_t vtol() { return 2e-2 ; } // set value test tolerance to 2e-2 (inherited default is 1e-3) - // Make model for prototype on/off problem - // Pois(x | s+b) * Pois(y | tau b ) - // for Z_Gamma, use uniform prior on b. - RooWorkspace* w = new RooWorkspace("w", kTRUE); - w->factory("Poisson::px(x[150,0,500],sum::splusb(s[0,0,100],b[100,0,300]))"); - w->factory("Poisson::py(y[100,0,500],prod::taub(tau[1.],b))"); - w->factory("Uniform::prior_b(b)"); + // Basic checks for the parameters passed to the test + // In case of invalid parameters, a warning is printed and the test is skipped + Bool_t isTestAvailable() { + if (fObsValueX < 0 || fObsValueX > 50) { + Warning("isTestAvailable", "Observed value X=s*e+b must be in the range [0,70]. Skipping test..."); + return kFALSE; + } + if (fConfidenceLevel <= 0.0 || fConfidenceLevel >= 1.0) { + Warning("isTestAvailable", "Confidence level must be in the range (0,1). Skipping test..."); + return kFALSE; + } + return kTRUE; + } - // construct the Bayesian-averaged model (eg. a projection pdf) - // p'(x|s) = \int db p(x|s+b) * [ p(y|b) * prior(b) ] - w->factory("PROJ::averagedModel(PROD::foo(px|b,py,prior_b),b)") ; + Bool_t testCode() { - // plot it, blue is averaged model, red is b known exactly - RooPlot* frame = w->var("x")->frame(); - w->pdf("averagedModel")->plotOn(frame); - w->pdf("px")->plotOn(frame, LineColor(kRed)); + // Create workspace and model + RooWorkspace *w = new RooWorkspace("w", kTRUE); + buildPoissonEfficiencyModel(w); + ModelConfig *sbModel = (ModelConfig *)w->obj("S+B"); + ModelConfig *bModel = (ModelConfig *)w->obj("B"); - // compare analytic calculation of Z_Bi - // with the numerical RooFit implementation of Z_Gamma - // for an example with x = 150, y = 100 + // add observed values to data set + w->var("x")->setVal(fObsValueX); + w->data("data")->add(*sbModel->GetObservables()); - // numeric RooFit Z_Gamma - w->var("y")->setVal(100); - w->var("x")->setVal(150); - RooAbsReal* cdf = w->pdf("averagedModel")->createCdf(*w->var("x")); - cdf->getVal(); // get ugly print messages out of the way + // set snapshots + sbModel->SetSnapshot(*sbModel->GetParametersOfInterest()); + w->var("sig")->setVal(0); + bModel->SetSnapshot(*bModel->GetParametersOfInterest()); - Double_t hybrid_p_value = cdf->getVal() ; - Double_t zgamma_signif = PValueToSignificance(1 - cdf->getVal()) ; + // calculate upper limit with HypoTestInverter + HypoTestCalculatorGeneric *calc = + buildHypoTestCalculator(fCalculatorType, *w->data("data"), *sbModel, *bModel, 100, 100); + HypoTestInverter *hti = new HypoTestInverter(*calc, NULL, 1.0 - fConfidenceLevel); + hti->SetTestStatistic(*buildTestStatistic(fTestStatType, *sbModel, *bModel)); + hti->SetFixedScan(10, w->var("sig")->getMin(), w->var("sig")->getMax()); // significant speedup - // analytic Z_Bi - Double_t Z_Bi = NumberCountingUtils::BinomialWithTauObsZ(150, 100, 1); + if(fCalculatorType == kAsymptotic) ((AsymptoticCalculator *)calc)->SetOneSided(kTRUE); + + // needed because we have no extended pdf and the ToyMC Sampler evaluation returns an error + ToyMCSampler *tmcs = (ToyMCSampler *)hti->GetHypoTestCalculator()->GetTestStatSampler(); + tmcs->SetNEventsPerToy(1); + tmcs->SetUseMultiGen(kTRUE); // make ToyMCSampler faster - // Register output quantities for regression test - regPlot(frame, "rs101_zbi_zgamma") ; - regValue(hybrid_p_value, "rs101_hybrid_p_value") ; - regValue(zgamma_signif, "rs101_zgamma_signif") ; - regValue(Z_Bi, "rs101_Z_Bi") ; + // calculate interval and extract observed upper limit and expected upper limit (+- sigma) + HypoTestInverterResult *interval = hti->GetInterval(); + regValue(interval->UpperLimit(), TString::Format("thti2_upper_limit_sig_%s_%s_%d_%lf", + kECalculatorTypeString[fCalculatorType], + kETestStatTypeString[fTestStatType], + fObsValueX, fConfidenceLevel)); + regValue(interval->GetExpectedUpperLimit( 0), TString::Format("thti2_exp_upper_limit_sig_%s_%s_%d_%lf", + kECalculatorTypeString[fCalculatorType], + kETestStatTypeString[fTestStatType], + fObsValueX, fConfidenceLevel)); + regValue(interval->GetExpectedUpperLimit(-2), TString::Format("thti2_exp_upper_limit_-2_sig_%s_%s_%d_%lf", + kECalculatorTypeString[fCalculatorType], + kETestStatTypeString[fTestStatType], + fObsValueX, fConfidenceLevel)); + regValue(interval->GetExpectedUpperLimit(-1), TString::Format("thti2_exp_upper_limit_-1_sig_%s_%s_%d_%lf", + kECalculatorTypeString[fCalculatorType], + kETestStatTypeString[fTestStatType], + fObsValueX, fConfidenceLevel)); + regValue(interval->GetExpectedUpperLimit( 1), TString::Format("thti2_exp_upper_limit_+1_sig_%s_%s_%d_%lf", + kECalculatorTypeString[fCalculatorType], + kETestStatTypeString[fTestStatType], + fObsValueX, fConfidenceLevel)); + regValue(interval->GetExpectedUpperLimit( 2), TString::Format("thti2_exp_upper_limit_+2_sig_%s_%s_%d_%lf", + kECalculatorTypeString[fCalculatorType], + kETestStatTypeString[fTestStatType], + fObsValueX, fConfidenceLevel)); + + if (_verb >= 1) { + HypoTestInverterPlot *plot = new HypoTestInverterPlot("thti2_scan", "HTI Upper Limit Scan", interval); + TCanvas *c1 = new TCanvas("HypoTestInverter Scan"); + c1->SetLogy(false); + plot->Draw("2CL CLB"); + c1->SaveAs(TString::Format("thti2_scan_%s_%s_%d_%lf.pdf", + kECalculatorTypeString[fCalculatorType], + kETestStatTypeString[fTestStatType], + fObsValueX, fConfidenceLevel)); + + if (_verb == 2) { + const int n = interval->ArraySize(); + if (n > 0 && interval->GetResult(0)->GetNullDistribution()) { + TCanvas *c2 = new TCanvas("thti2_teststat_dist", "HTI Test Statistic Distributions", 2); + if (n > 1) { + int ny = TMath::CeilNint(sqrt((double)n)); + int nx = TMath::CeilNint(double(n) / ny); + c2->Divide(nx, ny); + } + for (int i = 0; i < n; ++i) { + if (n > 1) c2->cd(i + 1); + SamplingDistPlot *pl = plot->MakeTestStatPlot(i); + if (pl == NULL) return kTRUE; + pl->SetLogYaxis(kTRUE); + pl->Draw(); + } + c2->SaveAs(TString::Format("thti2_teststat_distrib_%s_%s_%d_%lf.pdf", + kECalculatorTypeString[fCalculatorType], + kETestStatTypeString[fTestStatType], + fObsValueX, fConfidenceLevel)); + } + } + } -// delete w; // interesting why it doesn't work + // cleanup + delete interval; + delete hti; + delete w; return kTRUE ; } -} ; - +}; -/////////////////////////////////////////////////////////////////////////////// // -// 'HYPOTESTCALCULATOR' -// -// This test evaluetes the functionality of the HypoTestCalculators. -// -// 04/2012 - Ioan Gabriel Bucur -// Insightful comments courtesy of Kyle Cranmer, Wouter Verkerke, Sven Kreiss -// from $ROOTSYS/tutorials/roostats/HybridInstructional.C +// END OF PART FIVE // /////////////////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////////////////// +//_____________________________________________________________________________ -#include "RooStats/ProfileLikelihoodTestStat.h" -#include "RooStats/SimpleLikelihoodRatioTestStat.h" -#include "RooStats/HypoTestCalculatorGeneric.h" -#include "RooStats/FrequentistCalculator.h" -#include "RooStats/HybridCalculator.h" -#include "RooStats/AsymptoticCalculator.h" -#include "RooStats/ProfileLikelihoodCalculator.h" -#include "RooStats/MaxLikelihoodEstimateTestStat.h" -#include "RooStats/NumEventsTestStat.h" -#include "RooStats/RatioOfProfiledLikelihoodsTestStat.h" + + + + +// Other tests currently not included in any suite + class TestHypoTestCalculator : public RooUnitTest { public: TestHypoTestCalculator(TFile* refFile, Bool_t writeRef, Int_t verbose) : RooUnitTest("HypoTestCalculator - On / Off Problem", refFile, writeRef, verbose) {}; @@ -1311,7 +1720,7 @@ class TestHypoTestCalculator : public RooUnitTest { const Int_t xValue = 150; const Int_t yValue = 100; - const Double_t tauValue = 1; + const Double_t tauValue = 1.0; if (_write == kTRUE) { @@ -1379,17 +1788,12 @@ class TestHypoTestCalculator : public RooUnitTest { ProfileLikelihoodTestStat *pllts = new ProfileLikelihoodTestStat(*bModel->GetPdf()); pllts->SetAlwaysReuseNLL(kTRUE); - pllts->SetOneSidedDiscovery(kTRUE); MaxLikelihoodEstimateTestStat *mlets = new MaxLikelihoodEstimateTestStat(*sbModel->GetPdf(), *((RooRealVar *)sbModel->GetParametersOfInterest()->first())); NumEventsTestStat *nevts = new NumEventsTestStat(*sbModel->GetPdf()); - // ProfileLikelihoodCalculator *plc = new ProfileLikelihoodCalculator(*data, *sbModel); - // plc->SetNullParameters(*bModel->GetSnapshot()); - // HypoTestResult *htr0 = plc->GetHypoTest(); - // htr0->Print(); @@ -1403,23 +1807,23 @@ class TestHypoTestCalculator : public RooUnitTest { tmcs->SetTestStatistic(pllts); HypoTestResult *htr = htc->GetHypoTest(); htr->Print(); - cout << "PLLTS " << htr->Significance() << endl; + std::cout<< "PLLTS " << htr->Significance() << std::endl; tmcs->SetTestStatistic(mlets); htr = htc->GetHypoTest(); htr->Print(); - cout << "MLETS " << htr->Significance() << endl; + std::cout<< "MLETS " << htr->Significance() << std::endl; tmcs->SetTestStatistic(nevts); htr = htc->GetHypoTest(); htr->Print(); - cout << "NEVTS " << htr->Significance() << endl; + std::cout<< "NEVTS " << htr->Significance() << std::endl; tmcs->SetTestStatistic(slrts); htr = htc->GetHypoTest(); htr->Print(); - cout << "SLRTS " << htr->Significance() << endl; + std::cout<< "SLRTS " << htr->Significance() << std::endl; tmcs->SetTestStatistic(roplts); htr = htc->GetHypoTest(); htr->Print(); - cout << "ROPLTS " << htr->Significance() << endl; + std::cout<< "ROPLTS " << htr->Significance() << std::endl; regValue(htr->Significance(), "thtc_significance_hybrid"); @@ -1434,373 +1838,77 @@ class TestHypoTestCalculator : public RooUnitTest { } } ; - -class TestHypoTestCalculator2 : public RooUnitTest { -public: - TestHypoTestCalculator2(TFile* refFile, Bool_t writeRef, Int_t verbose) : RooUnitTest("HypoTestCalculator Frequentist - On / Off Problem", refFile, writeRef, verbose) {}; - - Bool_t testCode() { - - const Int_t xValue = 150; - const Int_t yValue = 100; - const Double_t tauValue = 1; - - if (_write == kTRUE) { - - // register analytical Z_Bi value - Double_t Z_Bi = NumberCountingUtils::BinomialWithTauObsZ(xValue, yValue, tauValue); - regValue(Z_Bi, "thtc_significance_frequentist"); - - } else { - - // Make model for prototype on/off problem - // Pois(x | s+b) * Pois(y | tau b ) - RooWorkspace* w = new RooWorkspace("w", kTRUE); - w->factory("Poisson::on_pdf(x[150,0,500],sum::splusb(sig[0,0,100],bkg[100,0,300]))"); - w->factory("Poisson::off_pdf(y[100,0,500],prod::taub(tau[1],bkg))"); - w->factory("PROD::prod_pdf(on_pdf, off_pdf)"); - - w->var("x")->setVal(xValue); - w->var("y")->setVal(yValue); - w->var("y")->setConstant(); - w->var("tau")->setVal(tauValue); - w->var("tau")->setConstant(); - // construct the Bayesian-averaged model (eg. a projection pdf) - // p'(x|s) = \int db p(x|s+b) * [ p(y|b) * prior(b) ] - //w->factory("PROJ::averagedModel(PROD::foo(on_pdf|bkg,off_pdf,prior),bkg)") ; - - // define sets of variables obs={x} and poi={sig} - // x is the only observable in the main measurement and y is treated as a separate measurement, - // which is used to produce the prior that will be used in the calculation to randomize the nuisance parameters - w->defineSet("obs", "x"); - w->defineSet("poi", "sig"); - w->defineSet("nuis", "bkg"); - w->defineSet("globObs", "y"); - - // Add observable value to a data set - RooDataSet *data = new RooDataSet("data", "data", *w->set("obs")); - data->add(*w->set("obs")); - - - // Build S+B and B models - ModelConfig *sbModel = new ModelConfig("SB_ModelConfig", w); - sbModel->SetPdf(*w->pdf("prod_pdf")); - sbModel->SetObservables(*w->set("obs")); - sbModel->SetGlobalObservables(*w->set("globObs")); - sbModel->SetParametersOfInterest(*w->set("poi")); - sbModel->SetNuisanceParameters(*w->set("nuis")); - w->var("sig")->setVal(xValue - yValue / tauValue); // important ! - sbModel->SetSnapshot(*w->set("poi")); - - ModelConfig *bModel = new ModelConfig("B_ModelConfig", w); - bModel->SetPdf(*w->pdf("prod_pdf")); - bModel->SetObservables(*w->set("obs")); - bModel->SetGlobalObservables(*w->set("globObs")); - bModel->SetParametersOfInterest(*w->set("poi")); - bModel->SetNuisanceParameters(*w->set("nuis")); - w->var("sig")->setVal(0.0); // important ! - bModel->SetSnapshot(*w->set("poi")); - - w->import(*sbModel); - w->import(*bModel); - w->import(*data); - - - w->writeToFile("htc_ws.root"); - - // alternate priors - w->factory("Gaussian::gauss_prior(bkg, y, expr::sqrty('sqrt(y)', y))"); - w->factory("Lognormal::lognorm_prior(bkg, y, expr::kappa('1+1./sqrt(y)',y))"); - - // build test statistic - SimpleLikelihoodRatioTestStat *slrts = new SimpleLikelihoodRatioTestStat(*bModel->GetPdf(), *sbModel->GetPdf()); - slrts->SetNullParameters(*bModel->GetSnapshot()); - slrts->SetAltParameters(*sbModel->GetSnapshot()); - slrts->SetAlwaysReuseNLL(kTRUE); - - RatioOfProfiledLikelihoodsTestStat *roplts = new RatioOfProfiledLikelihoodsTestStat(*bModel->GetPdf(), *sbModel->GetPdf()); - roplts->SetAlwaysReuseNLL(kTRUE); - - ProfileLikelihoodTestStat *pllts = new ProfileLikelihoodTestStat(*bModel->GetPdf()); - pllts->SetAlwaysReuseNLL(kTRUE); - pllts->SetOneSidedDiscovery(kTRUE); - - MaxLikelihoodEstimateTestStat *mlets = - new MaxLikelihoodEstimateTestStat(*sbModel->GetPdf(), *((RooRealVar *)sbModel->GetParametersOfInterest()->first())); - - NumEventsTestStat *nevts = new NumEventsTestStat(*sbModel->GetPdf()); - - /* ProfileLikelihoodCalculator *plc = new ProfileLikelihoodCalculator(*data, *sbModel); - plc->SetNullParameters(*bModel->GetSnapshot()); - plc->SetAlternateParameters(*sbModel->GetSnapshot()); - HypoTestResult *htr0 = plc->GetHypoTest(); - cout << "PLC " << htr0->Significance() << endl; - */ - - FrequentistCalculator *ftc = new FrequentistCalculator(*data, *sbModel, *bModel); - ftc->SetToys(5000, 1000); - ftc->SetConditionalMLEsNull(w->set("nuis")); - ftc->SetConditionalMLEsAlt(w->set("nuis")); - ToyMCSampler *tmcs = (ToyMCSampler *)ftc->GetTestStatSampler(); - tmcs->SetNEventsPerToy(1); // because the model is in number counting form - tmcs->SetUseMultiGen(kTRUE); - tmcs->SetAlwaysUseMultiGen(kTRUE); - - tmcs->SetTestStatistic(slrts); - HypoTestResult *htr = ftc->GetHypoTest(); - htr->Print(); - cout << "SLRTS " << htr->Significance() << endl; - tmcs->SetTestStatistic(pllts); - htr = ftc->GetHypoTest(); - htr->Print(); - cout << "PLLTS " << htr->Significance() << endl; - tmcs->SetTestStatistic(mlets); - htr = ftc->GetHypoTest(); - htr->Print(); - cout << "MLETS " << htr->Significance() << endl; - tmcs->SetTestStatistic(nevts); - htr = ftc->GetHypoTest(); - htr->Print(); - cout << "NEVTS " << htr->Significance() << endl; - tmcs->SetTestStatistic(roplts); - htr = ftc->GetHypoTest(); - htr->Print(); - cout << "ROPLTS " << htr->Significance() << endl; - - regValue(htr->Significance(), "thtc_significance_frequentist"); - - delete ftc; - delete htr; - delete w; // interesting why it doesn't work - delete data; - } - return kTRUE ; - } -} ; - - -class TestHypoTestCalculator3 : public RooUnitTest { -public: - TestHypoTestCalculator3(TFile* refFile, Bool_t writeRef, Int_t verbose) : RooUnitTest("HypoTestCalculator Asymptotic - On / Off Problem", refFile, writeRef, verbose) {}; - -// Double_t vtol() { return 0.2; } // tolerance may be too big - - Bool_t testCode() { - - const Int_t xValue = 150; - const Int_t yValue = 100; - const Double_t tauValue = 1; - - if (_write == kTRUE) { - - // register analytical Z_Bi value - Double_t Z_Bi = NumberCountingUtils::BinomialWithTauObsZ(xValue, yValue, tauValue); - regValue(Z_Bi, "thtc_significance_asymptotic"); - - } else { - - // Make model for prototype on/off problem - // Pois(x | s+b) * Pois(y | tau b ) - RooWorkspace* w = new RooWorkspace("w", kTRUE); - w->factory("Poisson::on_pdf(x[150,0,500],sum::splusb(sig[0,0,100],bkg[100,0,300]))"); - w->factory("Poisson::off_pdf(y[100,0,500],prod::taub(tau[1],bkg))"); - w->factory("PROD::prod_pdf(on_pdf, off_pdf)"); - - w->var("x")->setVal(xValue); - w->var("y")->setVal(yValue); - w->var("y")->setConstant(); - w->var("tau")->setVal(tauValue); - w->var("tau")->setConstant(); - // construct the Bayesian-averaged model (eg. a projection pdf) - // p'(x|s) = \int db p(x|s+b) * [ p(y|b) * prior(b) ] - //w->factory("PROJ::averagedModel(PROD::foo(on_pdf|bkg,off_pdf,prior),bkg)") ; - - // define sets of variables obs={x} and poi={sig} - // x is the only observable in the main measurement and y is treated as a separate measurement, - // which is used to produce the prior that will be used in the calculation to randomize the nuisance parameters - w->defineSet("obs", "x"); - w->defineSet("poi", "sig"); - w->defineSet("globObs", "y"); - - // Add observable value to a data set - RooDataSet *data = new RooDataSet("data", "data", *w->set("obs")); - data->add(*w->set("obs")); - - // Build S+B and B models - ModelConfig *sbModel = new ModelConfig("SB_ModelConfig", w); - sbModel->SetPdf(*w->pdf("prod_pdf")); - sbModel->SetObservables(*w->set("obs")); - // sbModel->SetGlobalObservables(*w->set("globObs")); - sbModel->SetParametersOfInterest(*w->set("poi")); - w->var("sig")->setVal(xValue - yValue / tauValue); // important ! - sbModel->SetSnapshot(*w->set("poi")); - - ModelConfig *bModel = new ModelConfig("B_ModelConfig", w); - bModel->SetPdf(*w->pdf("prod_pdf")); - bModel->SetObservables(*w->set("obs")); - // bModel->SetGlobalObservables(*w->set("globObs")); - bModel->SetParametersOfInterest(*w->set("poi")); - w->var("sig")->setVal(0.0); // important ! - bModel->SetSnapshot(*w->set("poi")); - - - // alternate priors - w->factory("Gaussian::gauss_prior(bkg, y, expr::sqrty('sqrt(y)', y))"); - w->factory("Lognormal::lognorm_prior(bkg, y, expr::kappa('1+1./sqrt(y)',y))"); - - AsymptoticCalculator *atc = new AsymptoticCalculator(*data, *sbModel, *bModel); - - HypoTestResult *htr = atc->GetHypoTest(); - htr->Print(); - - regValue(htr->Significance(), "thtc_significance_asymptotic"); - - delete atc; - delete htr; - delete w; // interesting why it doesn't work - delete data; - } - return kTRUE ; - } -} ; - - - - - - -class TestHypoTestInverter2 : public RooUnitTest { -private: - HypoTestInverter::ECalculatorType fCalculatorType; - -public: - TestHypoTestInverter2(TFile* refFile, Bool_t writeRef, Int_t verbose, HypoTestInverter::ECalculatorType calculatorType, ETestStatType /* testStatType */) : RooUnitTest(TString::Format("HypoTestInverter Upper Limit - Poisson Model with Signal, Background and Efficiency - Calculator Type %d", calculatorType), refFile, writeRef, verbose) { - fCalculatorType = calculatorType; - }; - - Bool_t testCode() { - - const Double_t testSize = normal_cdf_c(1) * 2; - - // Create workspace and model - RooWorkspace *w = new RooWorkspace("w", kTRUE); - createPoissonEfficiencyModel(w); - ModelConfig *sbModel = (ModelConfig *)w->obj("S+B"); - ModelConfig *bModel = (ModelConfig *)w->obj("B"); - - // calculate upper limit with HypoTestInverter - HypoTestInverter *hti = new HypoTestInverter(*w->data("data"), *sbModel, *bModel, w->var("x"), fCalculatorType, testSize); - hti->SetFixedScan(10, 0, 20); - hti->UseCLs(kTRUE); - - if (fCalculatorType == HypoTestInverter::kAsymptotic && _verb == 0) { - AsymptoticCalculator::SetPrintLevel(0); // print only minimal output - } - - if (fCalculatorType == HypoTestInverter::kHybrid) { - // force prior nuisance pdf - HybridCalculator *hc = (HybridCalculator *)hti->GetHypoTestCalculator(); - w->factory("PROD::priorbkg(constrb, constre)"); - hc->ForcePriorNuisanceNull(*w->pdf("priorbkg")); - hc->ForcePriorNuisanceAlt(*w->pdf("priorbkg")); - } - - // Set up the test statistic - ProfileLikelihoodTestStat *profll = new ProfileLikelihoodTestStat(*sbModel->GetPdf()); - profll->SetOneSided(kTRUE); - - // needed because we have no extended pdf and the ToyMC Sampler evaluation returns an error - ToyMCSampler *tmcs = (ToyMCSampler *)hti->GetHypoTestCalculator()->GetTestStatSampler(); - tmcs->SetMaxToys(300); - tmcs->SetNEventsPerToy(1); - tmcs->SetTestStatistic(profll); -// tmcs->SetUseMultiGen(kTRUE); // make ToyMCSampler faster - - // calculate interval and extract observed upper limit and expected upper limit (+- sigma) - HypoTestInverterResult *interval = hti->GetInterval(); - regValue(interval->UpperLimit(), TString::Format("hti2_upper_limit_sig1_calc_%d", fCalculatorType)); - regValue(interval->GetExpectedUpperLimit(0), TString::Format("hti2_exp_upper_limit_sig_calc_%d", fCalculatorType)); - regValue(interval->GetExpectedUpperLimit(-1), TString::Format("hti2_exp_upper_limit-sigma_sig_calc_%d", fCalculatorType)); - regValue(interval->GetExpectedUpperLimit(1), TString::Format("hti2_exp_upper_limit+sigma_sig_calc_%d", fCalculatorType)); - - - if (_verb >= 1) { - cout << "[" << interval->LowerLimit() << "," << interval->UpperLimit() << "]" << endl; - HypoTestInverterPlot *plot = new HypoTestInverterPlot("HTI_Result_Plot", "HTI Upper Limit Scan", interval); - TCanvas *c1 = new TCanvas("HypoTestInverter Scan"); - c1->SetLogy(false); - plot->Draw("2CL CLb"); - c1->SaveAs(TString::Format("hti2 Upper Limit Scan - Calc %d.pdf", fCalculatorType)); - - - if (_verb == 2) { - const int n = interval->ArraySize(); - if (n > 0 && interval->GetResult(0)->GetNullDistribution()) { - TCanvas *c2 = new TCanvas("Test Statistic Distributions", "", 2); - if (n > 1) { - int ny = TMath::CeilNint(sqrt(n)); - int nx = TMath::CeilNint(double(n) / ny); - c2->Divide(nx, ny); - } - for (int i = 0; i < n; i++) { - if (n > 1) c2->cd(i + 1); - SamplingDistPlot *pl = plot->MakeTestStatPlot(i); - if (pl == NULL) return kTRUE; - pl->SetLogYaxis(kTRUE); - pl->Draw(); - } - c2->SaveAs(TString::Format("hti2 TestStat Distributions - Calc %d.pdf", fCalculatorType)); - } - } - } - - // cleanup - delete interval; - delete hti; - delete w; - - return kTRUE ; - } -}; - #include "RooStats/RatioOfProfiledLikelihoodsTestStat.h" #include "RooStats/MaxLikelihoodEstimateTestStat.h" #include "RooStats/NumEventsTestStat.h" -static TestStatistic *buildTestStatistic(const ETestStatType testStatType, const ModelConfig &sbModel, const ModelConfig &bModel) +static HypoTestCalculatorGeneric * buildHypoTestCalculator(const ECalculatorType calculatorType, RooAbsData &data, const ModelConfig &nullModel, const ModelConfig &altModel, const UInt_t toysNull, const UInt_t toysAlt) +{ + HypoTestCalculatorGeneric *calc = NULL; + + if(calculatorType == kAsymptotic) { + AsymptoticCalculator::SetPrintLevel(0); // TODO: set this by default + AsymptoticCalculator *ac = new AsymptoticCalculator(data, altModel, nullModel); + calc = ac; + } else if(calculatorType == kFrequentist) { + FrequentistCalculator *fc = + new FrequentistCalculator(data, altModel, nullModel); + // set toys for speedup + fc->SetToys(toysNull, toysAlt); + calc = fc; + } else { // kHybrid + HybridCalculator *hc = new HybridCalculator(data, altModel, nullModel); + // set toys for speedup + hc->SetToys(toysNull, toysAlt); + calc = hc; + } + + assert(calc != NULL); // sanity check - should never happen + + return calc; +} + +static TestStatistic *buildTestStatistic(const ETestStatType testStatType, const ModelConfig &nullModel, const ModelConfig &altModel) { TestStatistic *testStat = NULL; if (testStatType == kSimpleLR) { - SimpleLikelihoodRatioTestStat *slrts = new SimpleLikelihoodRatioTestStat(*sbModel.GetPdf(), *bModel.GetPdf()); - slrts->SetNullParameters(*sbModel.GetSnapshot()); - slrts->SetAltParameters(*bModel.GetSnapshot()); - slrts->SetReuseNLL(kTRUE); + SimpleLikelihoodRatioTestStat *slrts = new SimpleLikelihoodRatioTestStat(*nullModel.GetPdf(), *altModel.GetPdf()); + // TODO - different for HypoTestInverter and HypoTestCalculator + RooArgSet nullParams(*nullModel.GetSnapshot()); + if(nullModel.GetNuisanceParameters()) nullParams.add(*nullModel.GetNuisanceParameters()); + if(nullModel.GetSnapshot()) slrts->SetNullParameters(nullParams); + RooArgSet altParams(*altModel.GetSnapshot()); + if(altModel.GetNuisanceParameters()) altParams.add(*altModel.GetNuisanceParameters()); + if(altModel.GetSnapshot()) slrts->SetAltParameters(altParams); + slrts->SetAlwaysReuseNLL(kTRUE); testStat = slrts; } else if (testStatType == kRatioLR) { RatioOfProfiledLikelihoodsTestStat *roplts = - new RatioOfProfiledLikelihoodsTestStat(*sbModel.GetPdf(), *bModel.GetPdf(), bModel.GetSnapshot()); - roplts->SetReuseNLL(kTRUE); + new RatioOfProfiledLikelihoodsTestStat(*nullModel.GetPdf(), *altModel.GetPdf(), altModel.GetSnapshot()); + roplts->SetSubtractMLE(kFALSE); + roplts->SetAlwaysReuseNLL(kTRUE); testStat = roplts; } else if (testStatType == kMLE) { MaxLikelihoodEstimateTestStat *mlets = - new MaxLikelihoodEstimateTestStat(*sbModel.GetPdf(), *((RooRealVar *)sbModel.GetParametersOfInterest()->first())); + new MaxLikelihoodEstimateTestStat(*nullModel.GetPdf(), *((RooRealVar *)nullModel.GetParametersOfInterest()->first())); testStat = mlets; } else if (testStatType == kNObs) { - NumEventsTestStat *nevtts = new NumEventsTestStat(*sbModel.GetPdf()); + NumEventsTestStat *nevtts = new NumEventsTestStat(*nullModel.GetPdf()); testStat = nevtts; } else { // kProfileLR, kProfileLROneSided and kProfileLRSigned - ProfileLikelihoodTestStat *plts = new ProfileLikelihoodTestStat(*sbModel.GetPdf()); + ProfileLikelihoodTestStat *plts = new ProfileLikelihoodTestStat(*nullModel.GetPdf()); if (testStatType == kProfileLROneSided) plts->SetOneSided(kTRUE); - if (testStatType == kProfileLRSigned) plts->SetSigned(kTRUE); - plts->SetReuseNLL(kTRUE); + else if (testStatType == kProfileLROneSidedDiscovery) plts->SetOneSidedDiscovery(kTRUE); + else if (testStatType == kProfileLRSigned) plts->SetSigned(kTRUE); + plts->SetAlwaysReuseNLL(kTRUE); testStat = plts; } assert(testStat != NULL); // sanity check - should never happen - return testStat; // fgNToys seems like a good choice for now + return testStat; } diff --git a/test/stressTMVA.cxx b/test/stressTMVA.cxx index a460276df5865..b75d9dc7855df 100644 --- a/test/stressTMVA.cxx +++ b/test/stressTMVA.cxx @@ -471,7 +471,7 @@ class utDataSetInfo : public UnitTesting::UnitTest TString weightexpr; TMVA::Event* event; - TMVA::ClassInfo* classinfo; + // TMVA::ClassInfo* classinfo; TMVA::VariableInfo varinfo; std::vector<TMVA::VariableInfo> vecvarinfo; }; @@ -661,7 +661,7 @@ class utDataSet : public UnitTesting::UnitTest TMVA::Event* event2; TMVA::Event* event3; TMVA::Event* event4; - std::vector<TMVA::Event>* vecevent; + // std::vector<TMVA::Event>* vecevent; // TMVA::Results* result; }; #endif // UTDATASET_H @@ -1115,8 +1115,9 @@ void utEvent::_testMutators() _eventC1->SetWeight(_testWeight); test_(_eventC1->GetWeight() == _testWeight); - _eventC1->ScaleWeight(_testScale); - test_(floatCompare((float) _eventC1->GetWeight(), _testWeight*_testScale)); + //_eventC1->ScaleWeight(_testScale); + //test_(floatCompare((float) _eventC1->GetWeight(), _testWeight*_testScale)); + test_(true); _eventC1->SetBoostWeight(_testBoostWeight); test_(floatCompare( _eventC1->GetBoostWeight() , _testBoostWeight)); @@ -2123,7 +2124,6 @@ void MethodUnitTestWithROCLimits::run() if (_methodType==Types::kCuts // non-implemented makeclass methods BayesClassifier CFMlpANN Committee Cuts KNN PDERS RuleFit SVM || _methodType==Types::kBayesClassifier || _methodType==Types::kCFMlpANN - || _methodType==Types::kCommittee || _methodType==Types::kCuts || _methodType==Types::kKNN || _methodType==Types::kPDERS @@ -2774,7 +2774,7 @@ void addClassificationTests( UnitTestSuite& TMVA_test, bool full=true) if (full) TMVA_test.addTest(new MethodUnitTestWithROCLimits( TMVA::Types::kTMlpANN, "TMlpANN", "!H:!V:NCycles=200:HiddenLayers=N+1,N:LearningMethod=BFGS:ValidationFraction=0.3" , 0.7, 0.98) ); // n_cycles:#nodes:#nodes:... TMVA_test.addTest(new MethodUnitTestWithROCLimits( TMVA::Types::kSVM, "SVM", "Gamma=0.25:Tol=0.001:VarTransform=Norm" , 0.88, 0.98) ); TMVA_test.addTest(new MethodUnitTestWithROCLimits( TMVA::Types::kBDT, "BDTG", - "!H:!V:NTrees=400:BoostType=Grad:Shrinkage=0.30:UseBaggedGrad:GradBaggingFraction=0.6:SeparationType=GiniIndex:nCuts=20:NNodesMax=7" , 0.88, 0.98) ); + "!H:!V:NTrees=400:BoostType=Grad:Shrinkage=0.30:UseBaggedBoost:GradBaggingFraction=0.6:SeparationType=GiniIndex:nCuts=20:MaxDepth=2" , 0.88, 0.98) ); TMVA_test.addTest(new MethodUnitTestWithROCLimits( TMVA::Types::kBDT, "BDT", "!H:!V:NTrees=400:nEventsMin=100:MaxDepth=3:BoostType=AdaBoost:SeparationType=GiniIndex:nCuts=10:PruneMethod=NoPruning" , 0.88, 0.98) ); if (full) TMVA_test.addTest(new MethodUnitTestWithROCLimits( TMVA::Types::kBDT, "BDTB", @@ -2790,8 +2790,8 @@ void addRegressionTests( UnitTestSuite& TMVA_test, bool full=true) TMVA_test.addTest(new RegressionUnitTestWithDeviation( TMVA::Types::kLD, "LD", "!H:!V:VarTransform=None", 15., 25., 10., 20. )); // full low/high , 90 low/high TMVA_test.addTest(new RegressionUnitTestWithDeviation( TMVA::Types::kMLP, "MLPBFGSN", "!H:!V:VarTransform=Norm:NeuronType=tanh:NCycles=300:HiddenLayers=N+20:TestRate=6:TrainingMethod=BFGS:Sampling=0.3:SamplingEpoch=0.8:ConvergenceImprove=1e-7:ConvergenceTests=15:!UseRegulator:VarTransform=N" , 0.4, 0.85, 0.3, 0.55 )); - if (full) TMVA_test.addTest(new RegressionUnitTestWithDeviation( TMVA::Types::kBDT, "BDTG","!H:!V:NTrees=1000::BoostType=Grad:Shrinkage=0.3:!UseBaggedGrad:SeparationType=GiniIndex:nCuts=20:nEventsMin=20:NNodesMax=7" , 5., 8., 3., 5. )); - TMVA_test.addTest(new RegressionUnitTestWithDeviation( TMVA::Types::kBDT, "BDTG2","!H:!V:NTrees=2000::BoostType=Grad:Shrinkage=0.1:UseBaggedGrad:GradBaggingFraction=0.5:nCuts=20:MaxDepth=3:NNodesMax=15" , 2., 5., 1., 3. )); + if (full) TMVA_test.addTest(new RegressionUnitTestWithDeviation( TMVA::Types::kBDT, "BDTG","!H:!V:NTrees=1000::BoostType=Grad:Shrinkage=0.3:!UseBaggedBoost:SeparationType=GiniIndex:nCuts=20:MinNodeSize=.2:MaxDepth=3" , 5., 8., 3., 5. )); + TMVA_test.addTest(new RegressionUnitTestWithDeviation( TMVA::Types::kBDT, "BDTG2","!H:!V:NTrees=2000::BoostType=Grad:Shrinkage=0.1:UseBaggedBoost:GradBaggingFraction=0.5:nCuts=20:MaxDepth=3" , 2., 5., 1., 3. )); if (!full) return; @@ -2833,7 +2833,7 @@ void addDataInputTests( UnitTestSuite& TMVA_test, bool full=true) TMVA_test.addTest(new MethodUnitTestWithComplexData(TString("sig1_sig2_bgd1_bgd2"), TString("SplitMode=random:NormMode=NumEvents:!V"), TMVA::Types::kLikelihood, "LikelihoodD", lhstring , 0.9, 0.95) ); TMVA_test.addTest(new MethodUnitTestWithComplexData(TString("sig1_sig2_bgd1_bgd2"), TString("SplitMode=alternate:NormMode=NumEvents:!V"), TMVA::Types::kLikelihood, "LikelihoodD", lhstring , 0.9, 0.95) ); - TMVA_test.addTest(new MethodUnitTestWithComplexData(TString("sig1_sig2_bgd1_bgd2"), TString("SplitMode=block:NormMode=NumEvents:!V"), TMVA::Types::kLikelihood, "LikelihoodD", lhstring , 0.9, 0.99) ); + TMVA_test.addTest(new MethodUnitTestWithComplexData(TString("sig1_sig2_bgd1_bgd2"), TString("SplitMode=block:NormMode=NumEvents:!V"), TMVA::Types::kLikelihood, "LikelihoodD", lhstring , 0.9, 0.994) ); } void addComplexClassificationTests( UnitTestSuite& TMVA_test, bool full=true ) @@ -2847,7 +2847,7 @@ void addComplexClassificationTests( UnitTestSuite& TMVA_test, bool full=true ) TMVA_test.addTest(new MethodUnitTestWithComplexData(trees, prep, TMVA::Types::kMLP, "MLP", "H:!V:RandomSeed=9:NeuronType=tanh:VarTransform=N:NCycles=50:HiddenLayers=N+10:TestRate=5:TrainingMethod=BFGS:!UseRegulator" , 0.955, 0.975) ); TMVA_test.addTest(new MethodUnitTestWithComplexData(trees, prep, TMVA::Types::kMLP, "MLP", "H:!V:RandomSeed=9:NeuronType=tanh:VarTransform=N:NCycles=50:HiddenLayers=N+10:TestRate=5:TrainingMethod=BP:!UseRegulator" , 0.955, 0.975) ); // BDT - TMVA_test.addTest(new MethodUnitTestWithComplexData(trees, prep, TMVA::Types::kBDT, "BDTG8_50", "!H:!V:NTrees=50:BoostType=Grad:Shrinkage=0.30:UseBaggedGrad:GradBaggingFraction=0.6:nCuts=20:NNodesMax=8:SeparationType=GiniIndex" , 0.955, 0.975) ); + TMVA_test.addTest(new MethodUnitTestWithComplexData(trees, prep, TMVA::Types::kBDT, "BDTG8_50", "!H:!V:NTrees=50:BoostType=Grad:Shrinkage=0.30:UseBaggedBoost:BaggedSampleFraction=0.6:nCuts=20:MaxDepth=3:SeparationType=GiniIndex" , 0.950, 0.975) ); // SVM TMVA_test.addTest(new MethodUnitTestWithComplexData(trees, prep, TMVA::Types::kSVM, "SVM", "Gamma=0.4:Tol=0.001" , 0.955, 0.975) ); } diff --git a/test/threads.cxx b/test/threads.cxx index 94ef5f971b45e..3df42dcb12bbd 100644 --- a/test/threads.cxx +++ b/test/threads.cxx @@ -35,7 +35,7 @@ void *mhs(void *) c1->SetGrid(); pad1->Draw(); - // creating a histogram is explicitely locked by a global mutex + // creating a histogram is explicitly locked by a global mutex TThread::Lock(); TH1F *main = new TH1F("main","Main contributor",100,-4,4); TThread::UnLock(); diff --git a/tmva/CMakeLists.txt b/tmva/CMakeLists.txt index af43e704baf45..8183c7eb8e74b 100644 --- a/tmva/CMakeLists.txt +++ b/tmva/CMakeLists.txt @@ -20,15 +20,15 @@ set(headers1 Configurable.h Event.h Factory.h MethodBase.h MethodCompositeBase.h MethodANNBase.h MethodTMlpANN.h MethodRuleFit.h MethodCuts.h MethodFisher.h MethodKNN.h MethodCFMlpANN.h MethodCFMlpANN_Utils.h MethodLikelihood.h MethodHMatrix.h MethodPDERS.h MethodBDT.h MethodDT.h MethodSVM.h MethodBayesClassifier.h - MethodFDA.h MethodMLP.h MethodCommittee.h MethodBoost.h + MethodFDA.h MethodMLP.h MethodBoost.h MethodPDEFoam.h MethodLD.h MethodCategory.h) set(headers2 TSpline2.h TSpline1.h PDF.h BinaryTree.h BinarySearchTreeNode.h BinarySearchTree.h Timer.h RootFinder.h CrossEntropy.h DecisionTree.h DecisionTreeNode.h MisClassificationError.h Node.h SdivSqrtSplusB.h SeparationBase.h RegressionVariance.h Tools.h Reader.h GeneticAlgorithm.h GeneticGenes.h GeneticPopulation.h GeneticRange.h GiniIndex.h - GiniIndexWithLaplace.h SimulatedAnnealing.h) -set(headers3 Config.h KDEKernel.h Interval.h FitterBase.h MCFitter.h GeneticFitter.h SimulatedAnnealingFitter.h - MinuitFitter.h MinuitWrapper.h IFitterTarget.h + GiniIndexWithLaplace.h SimulatedAnnealing.h QuickMVAProbEstimator.h) +set(headers3 Config.h KDEKernel.h Interval.h LogInterval.h FitterBase.h MCFitter.h GeneticFitter.h + SimulatedAnnealingFitter.h MinuitFitter.h MinuitWrapper.h IFitterTarget.h PDEFoam.h PDEFoamDecisionTree.h PDEFoamDensityBase.h PDEFoamDiscriminantDensity.h PDEFoamEventDensity.h PDEFoamTargetDensity.h PDEFoamDecisionTreeDensity.h PDEFoamMultiTarget.h PDEFoamVect.h PDEFoamCell.h PDEFoamDiscriminant.h PDEFoamEvent.h PDEFoamTarget.h @@ -59,11 +59,11 @@ ROOT_GENERATE_ROOTMAP(TMVA LINKDEF LinkDef1.h LinkDef2.h LinkDef3.h LinkDef4.h ROOT_LINKER_LIBRARY(TMVA *.cxx G__TMVA1.cxx G__TMVA2.cxx G__TMVA3.cxx G__TMVA4.cxx LIBRARIES Core Cint DEPENDENCIES RIO Hist Tree MLP Minuit XMLIO) -install(DIRECTORY inc/TMVA/ DESTINATION include/TMVA +install(DIRECTORY inc/TMVA/ DESTINATION ${CMAKE_INSTALL_INCDIR}/TMVA PATTERN ".svn" EXCLUDE REGEX "LinkDef" EXCLUDE ) -if(NOT CMAKE_SOURCE_DIR STREQUAL CMAKE_INSTALL_PREFIX) - install(DIRECTORY test DESTINATION tmva PATTERN ".svn" EXCLUDE) -endif() +#if(NOT CMAKE_SOURCE_DIR STREQUAL CMAKE_INSTALL_PREFIX) +# install(DIRECTORY test DESTINATION ${CMAKE_INSTALL_DOCDIR}/tmva PATTERN ".svn" EXCLUDE) +#endif() diff --git a/tmva/Makefile b/tmva/Makefile index 559bf57649c77..3cc648f37490f 100644 --- a/tmva/Makefile +++ b/tmva/Makefile @@ -37,15 +37,15 @@ DICTH1 := Configurable.h Event.h Factory.h MethodBase.h MethodCompositeBas MethodANNBase.h MethodTMlpANN.h MethodRuleFit.h MethodCuts.h MethodFisher.h \ MethodKNN.h MethodCFMlpANN.h MethodCFMlpANN_Utils.h MethodLikelihood.h \ MethodHMatrix.h MethodPDERS.h MethodBDT.h MethodDT.h MethodSVM.h MethodBayesClassifier.h \ - MethodFDA.h MethodMLP.h MethodCommittee.h MethodBoost.h \ + MethodFDA.h MethodMLP.h MethodBoost.h \ MethodPDEFoam.h MethodLD.h MethodCategory.h DICTH2 := TSpline2.h TSpline1.h PDF.h BinaryTree.h BinarySearchTreeNode.h BinarySearchTree.h \ Timer.h RootFinder.h CrossEntropy.h DecisionTree.h DecisionTreeNode.h MisClassificationError.h \ Node.h SdivSqrtSplusB.h SeparationBase.h RegressionVariance.h Tools.h Reader.h \ GeneticAlgorithm.h GeneticGenes.h GeneticPopulation.h GeneticRange.h GiniIndex.h \ - GiniIndexWithLaplace.h SimulatedAnnealing.h -DICTH3 := Config.h KDEKernel.h Interval.h FitterBase.h MCFitter.h GeneticFitter.h SimulatedAnnealingFitter.h \ - MinuitFitter.h MinuitWrapper.h IFitterTarget.h \ + GiniIndexWithLaplace.h SimulatedAnnealing.h QuickMVAProbEstimator.h +DICTH3 := Config.h KDEKernel.h Interval.h LogInterval.h FitterBase.h MCFitter.h GeneticFitter.h \ + SimulatedAnnealingFitter.h MinuitFitter.h MinuitWrapper.h IFitterTarget.h \ PDEFoam.h PDEFoamDecisionTree.h PDEFoamDensityBase.h PDEFoamDiscriminantDensity.h \ PDEFoamEventDensity.h PDEFoamTargetDensity.h PDEFoamDecisionTreeDensity.h PDEFoamMultiTarget.h \ PDEFoamVect.h PDEFoamCell.h PDEFoamDiscriminant.h PDEFoamEvent.h PDEFoamTarget.h \ diff --git a/tmva/Module.mk b/tmva/Module.mk index 50042f601e47f..826b1b84995a3 100644 --- a/tmva/Module.mk +++ b/tmva/Module.mk @@ -35,14 +35,14 @@ TMVAH1 := Configurable.h Event.h Factory.h MethodBase.h MethodCompositeBas MethodANNBase.h MethodTMlpANN.h MethodRuleFit.h MethodCuts.h MethodFisher.h \ MethodKNN.h MethodCFMlpANN.h MethodCFMlpANN_Utils.h MethodLikelihood.h \ MethodHMatrix.h MethodPDERS.h MethodBDT.h MethodDT.h MethodSVM.h MethodBayesClassifier.h \ - MethodFDA.h MethodMLP.h MethodCommittee.h MethodBoost.h \ + MethodFDA.h MethodMLP.h MethodBoost.h \ MethodPDEFoam.h MethodLD.h MethodCategory.h TMVAH2 := TSpline2.h TSpline1.h PDF.h BinaryTree.h BinarySearchTreeNode.h BinarySearchTree.h \ Timer.h RootFinder.h CrossEntropy.h DecisionTree.h DecisionTreeNode.h MisClassificationError.h \ Node.h SdivSqrtSplusB.h SeparationBase.h RegressionVariance.h Tools.h Reader.h \ GeneticAlgorithm.h GeneticGenes.h GeneticPopulation.h GeneticRange.h GiniIndex.h \ - GiniIndexWithLaplace.h SimulatedAnnealing.h -TMVAH3 := Config.h KDEKernel.h Interval.h FitterBase.h MCFitter.h GeneticFitter.h SimulatedAnnealingFitter.h \ + GiniIndexWithLaplace.h SimulatedAnnealing.h QuickMVAProbEstimator.h +TMVAH3 := Config.h KDEKernel.h Interval.h LogInterval.h FitterBase.h MCFitter.h GeneticFitter.h SimulatedAnnealingFitter.h \ MinuitFitter.h MinuitWrapper.h IFitterTarget.h \ PDEFoam.h PDEFoamDecisionTree.h PDEFoamDensityBase.h PDEFoamDiscriminantDensity.h \ PDEFoamEventDensity.h PDEFoamTargetDensity.h PDEFoamDecisionTreeDensity.h PDEFoamMultiTarget.h \ diff --git a/tmva/doc/README b/tmva/doc/README index 68c92e81a1027..877d51000d6a6 100644 --- a/tmva/doc/README +++ b/tmva/doc/README @@ -23,15 +23,30 @@ System requirements: Getting Started: ---------------- - How to compile the code: - ------------------------ + How to compile the code (as standalone TMVA, outside the general ROOT built) : + ------------------------------------------------------------------------------- /home> cd TMVA /home/TMVA> make # compile and build the library lib/libTMVA.1.so + then, in order to pick up THIS TMVA libraries, and not those that are probably + included in your ROOT distribution, you have to go into your working directory and + do: + + /home/YOURWORKDIR> cp /home/TMVA/test/setup.(c)sh . + /home/YOURWORKDIR> source setup.(c)sh /home/TMVA (or whatever the path of your TMVA installation is) + + (where /home/TMVA shuld be replaced by whatever directory your TMVA installation might be in) How to run the code as ROOT macro: # training/testing of an academic example - ---------------------------------- - /home/TMVA> cd test - /home/TMVA/test> source setup.sh # setup script must be exectuted before running macros (use setup.csh for c-shell) + In the directory /home/TMVA/test + you find a number of example macros AND utility macros that are used by TMVA + (like the TMVAGui.C etc) As these macros are needed for everything including + the 'evaluation macros' called by the TMVAGui.C, make sure the path to this + directory is included in your ROOT macro paths: + i.e. you find a line in the .rootrc like: + Unix.*.Root.MacroPath: .:$TMVASYS/test + (this will be done by running the 'setup.sh' .. unless you already have a + different .rootrc in your workig directory) + ---------------------------------------------------------------------------- --- For classification: /home/TMVA/test> root -l TMVAClassification.C # run all standard classifiers (takes a while) diff --git a/tmva/doc/v534/index.html b/tmva/doc/v534/index.html index 48347dbca0ccc..7c2d0e06f2f34 100644 --- a/tmva/doc/v534/index.html +++ b/tmva/doc/v534/index.html @@ -2,3 +2,99 @@ <hr/> <a name="tmva"></a> <h3>TMVA Package</h3> + + +<h3>Factory</h3> + +<ul> +<li> <tt>NormMode</tt>: as called in PrepareTrainingAndTestTree <br> + +The default has changed and is now "<tt>EqualNumEvents</tt>" (with fixed meaning) + +While previously <tt>NumEvents</tt> and <tt>EqualNumEvents</tt> (by mistake/miscommunication) +took into account training+test events, they are now correctly +normalising only "Training Events" (note the reason for these +normalisations was to have the possibility to easily force the +effective (weighted) number of training events used for Signal (class +0) to equal the number of training events in the Backgr. (sum of all +remaining classes in multiclass mode) + +<dl> + <dt> <tt>NumEvents:</tt></dt> + <dd> - the weighted number of events is scaled, independently for signal and +backgroundm, such that the sum of weights equals the number of events given in the +Factory::PrepareTrainingAndTestTree("",nTrain_Signal=3000,nTrain_Background=6000) call. +This example call will give hence end up in having 2x more background +events in the training compared to the signal, no matter what the +individual event weights have been. (watch out! if you specify +nTrain_Signal=0,nTrain_Background=0), then the ratio will be according +to total numbers of MC events in the signal and background +respectively, which could be very different from the usually good +ratio of having about the same weighted number signal and background +events in the training. In that case it is better to use: </dd> + +<dt> <tt>EqualNumEvents:</tt></dt> +<dd> - for the signal events, the same is done as for <tt>NumEvents</tt>. + The background events however are reweighted such, that their sum of weights + equals that for the signal events. This results in the same effective (weighted) + number of signal and background events to be seen in the training. + +</dl> + +</li> + +<li> <tt>Transformations=I</tt> is default again in Factory (this defines which +variables distribution plots are added to the TMVA output file - and +hence displayable via the TMVAGui) </li> + +</ul> + +<h3>Boosted Decision Trees</h3> + +some changes to the training options: + + +<dl> + <dt> <tt>nEventsMin</tt> (deprecated) please replace by --> <tt>MinNodeSize</tt> </dt> + <dd>The option nEventsMin which specified the minimum number of training event +in a leaf node as an absolute number has been replaced by "MinNodeSize" +which is given in "percentage of the trainin sample". Like this the training +options become less dependent on the actual number of training sample size</dd> + + <dt> <tt>NNodesMax</tt> (deprecated) please replace by --> MaxDepth </dt> + + <dt> <tt>GradBaggingFraction</tt> and <tt>UseNTrainEvents</tt> replaced by <tt>BaggedSampleFraction</tt> </dt> + <dd> - they both meant the same thing and are now +deprecated --> use <tt>BaggedSampleFraction</tt> instead </dd> + <dt> <tt>UsedBaggedGrad</tt> replaced by <tt>UseBaggedBoost</tt> </dt> + <dd> - like this, the use of a bagged sample in Grad-Boost or AdaBoost has the same option name</dd> + + <dt> <tt>UseWeightedTrees</tt> --> removed<dt> + <dd> - it was default anyway and the only reasonable choice there is</dt> + <dt> <tt>PruneBeforeBoost</tt> --> removed<dt> + <dd> - it has been mostly a debug/trial option</dt> + + <dt> <tt>NegWeightTreatment=IgnoreNegWeights</tt> --> replaced by NegWeightTreatment=IgnoreNegWeightsInTraining </dt> + + <dd> - Unfortunatly the default "IgnoreNegWeights" to the BDT option "NegWeightTreatment" +collided with the a global option and had to be replaced. + + + + +<h3>MethodBoost</h3> +<ui> +<li> some cleanup (removed strange experimental boosting option <tt>HighEdgeGaus, + HighEdgeCoPara .....</tt> )</li> + +<li>remove options <tt>MethodWeightType</tt>... have it defined by the Boost Method + (these have been trial options.. but for clarity it is much better to stick + to the "standard" ones (i.e log(alpha) for AdaBoost etc)</li> + + +<li>up to now, the first classifier was trained with + the full sample, I think however, it should also be a bagged + sample (i.e. particularily if smaller sample sizes for the bagged + samples were demanded) .. it's changed now, accordingly</li> +</ui> + diff --git a/tmva/inc/LinkDef.h b/tmva/inc/LinkDef.h new file mode 100644 index 0000000000000..7a03a0306d195 --- /dev/null +++ b/tmva/inc/LinkDef.h @@ -0,0 +1,4 @@ +#include "tmva/inc/LinkDef1.h" +#include "tmva/inc/LinkDef2.h" +#include "tmva/inc/LinkDef3.h" +#include "tmva/inc/LinkDef4.h" diff --git a/tmva/inc/LinkDef1.h b/tmva/inc/LinkDef1.h index 3574eecf86bad..08df48a37085d 100644 --- a/tmva/inc/LinkDef1.h +++ b/tmva/inc/LinkDef1.h @@ -34,7 +34,6 @@ #pragma link C++ class TMVA::MethodBayesClassifier+; #pragma link C++ class TMVA::MethodFDA+; #pragma link C++ class TMVA::MethodMLP+; -#pragma link C++ class TMVA::MethodCommittee+; #pragma link C++ class TMVA::MethodBoost+; #pragma link C++ class TMVA::MethodPDEFoam+; #pragma link C++ class TMVA::MethodLD+; diff --git a/tmva/inc/LinkDef2.h b/tmva/inc/LinkDef2.h index ce4a11538438a..650e9af79b1af 100644 --- a/tmva/inc/LinkDef2.h +++ b/tmva/inc/LinkDef2.h @@ -35,5 +35,6 @@ #pragma link C++ class TMVA::GiniIndex+; #pragma link C++ class TMVA::GiniIndexWithLaplace+; #pragma link C++ class TMVA::SimulatedAnnealing+; +#pragma link C++ class TMVA::QuickMVAProbEstimator+; #endif diff --git a/tmva/inc/LinkDef3.h b/tmva/inc/LinkDef3.h index 91b6162e5ca6b..bb7f4a5f01b71 100644 --- a/tmva/inc/LinkDef3.h +++ b/tmva/inc/LinkDef3.h @@ -15,6 +15,7 @@ #pragma link C++ class TMVA::Config::IONames+; #pragma link C++ class TMVA::KDEKernel+; #pragma link C++ class TMVA::Interval+; +#pragma link C++ class TMVA::LogInterval+; #pragma link C++ class TMVA::FitterBase+; #pragma link C++ class TMVA::MCFitter+; #pragma link C++ class TMVA::GeneticFitter+; diff --git a/tmva/inc/TMVA/BinarySearchTree.h b/tmva/inc/TMVA/BinarySearchTree.h index dda1785242457..b722ac041f011 100644 --- a/tmva/inc/TMVA/BinarySearchTree.h +++ b/tmva/inc/TMVA/BinarySearchTree.h @@ -65,7 +65,6 @@ class TTree; namespace TMVA { - class DataSet; class Event; // class MethodBase; diff --git a/tmva/inc/TMVA/BinaryTree.h b/tmva/inc/TMVA/BinaryTree.h index f2d26de9c23df..81fe591789c4c 100644 --- a/tmva/inc/TMVA/BinaryTree.h +++ b/tmva/inc/TMVA/BinaryTree.h @@ -62,13 +62,13 @@ namespace TMVA { class BinaryTree; class MsgLogger; - ostream& operator<< ( ostream& os, const BinaryTree& tree ); - istream& operator>> ( istream& istr, BinaryTree& tree ); + std::ostream& operator<< ( std::ostream& os, const BinaryTree& tree ); + std::istream& operator>> ( std::istream& istr, BinaryTree& tree ); class BinaryTree { - friend ostream& operator<< ( ostream& os, const BinaryTree& tree ); - friend istream& operator>> ( istream& istr, BinaryTree& tree ); + friend std::ostream& operator<< ( std::ostream& os, const BinaryTree& tree ); + friend std::istream& operator>> ( std::istream& istr, BinaryTree& tree ); public: @@ -104,8 +104,8 @@ namespace TMVA { Node* GetLeftDaughter ( Node* n); Node* GetRightDaughter( Node* n); - virtual void Print( ostream& os ) const; - virtual void Read ( istream& istr, UInt_t tmva_Version_Code = TMVA_VERSION_CODE ); + virtual void Print( std::ostream& os ) const; + virtual void Read ( std::istream& istr, UInt_t tmva_Version_Code = TMVA_VERSION_CODE ); virtual void* AddXMLTo(void* parent) const; virtual void ReadXML(void* node, UInt_t tmva_Version_Code = TMVA_VERSION_CODE ); diff --git a/tmva/inc/TMVA/CCPruner.h b/tmva/inc/TMVA/CCPruner.h index d9baf3c7e19b2..9368dc56caaea 100644 --- a/tmva/inc/TMVA/CCPruner.h +++ b/tmva/inc/TMVA/CCPruner.h @@ -58,6 +58,7 @@ #endif namespace TMVA { + class DataSet; class DecisionTreeNode; class SeparationBase; diff --git a/tmva/inc/TMVA/CCTreeWrapper.h b/tmva/inc/TMVA/CCTreeWrapper.h index e97a6104ff055..2d0351a5e05d4 100644 --- a/tmva/inc/TMVA/CCTreeWrapper.h +++ b/tmva/inc/TMVA/CCTreeWrapper.h @@ -107,10 +107,10 @@ namespace TMVA { inline CCTreeNode* GetMother( ) { return dynamic_cast<CCTreeNode*>(GetParent()); } // printout of the node (can be read in with ReadDataRecord) - virtual void Print( ostream& os ) const; + virtual void Print( std::ostream& os ) const; // recursive printout of the node and its daughters - virtual void PrintRec ( ostream& os ) const; + virtual void PrintRec ( std::ostream& os ) const; virtual void AddAttributesToNode(void* node) const; virtual void AddContentToNode(std::stringstream& s) const; diff --git a/tmva/inc/TMVA/Configurable.h b/tmva/inc/TMVA/Configurable.h index 53c963d863552..18eabd6e689f3 100644 --- a/tmva/inc/TMVA/Configurable.h +++ b/tmva/inc/TMVA/Configurable.h @@ -80,6 +80,11 @@ namespace TMVA { // Add a predefined value to the last declared option template<class T> void AddPreDefVal(const T&); + + // Add a predefined value to the option named optname + template<class T> + void AddPreDefVal(const TString&optname ,const T&); + void CheckForUnusedOptions() const; @@ -87,7 +92,7 @@ namespace TMVA { void SetOptions(const TString& s) { fOptions = s; } void WriteOptionsToStream ( std::ostream& o, const TString& prefix ) const; - void ReadOptionsFromStream( istream& istr ); + void ReadOptionsFromStream( std::istream& istr ); void AddOptionsXMLTo( void* parent ) const; void ReadOptionsFromXML( void* node ); @@ -171,11 +176,38 @@ TMVA::OptionBase* TMVA::Configurable::DeclareOptionRef( T*& ref, Int_t size, con template<class T> void TMVA::Configurable::AddPreDefVal(const T& val) { - // add predefined option value + // add predefined option value to the last declared option Option<T>* oc = dynamic_cast<Option<T>*>(fLastDeclaredOption); if(oc!=0) oc->AddPreDefVal(val); } +//______________________________________________________________________ +template<class T> +void TMVA::Configurable::AddPreDefVal(const TString &optname, const T& val) +{ + // add predefined option value to the option named optname + + TListIter optIt( &fListOfOptions ); + while (OptionBase * op = (OptionBase *) optIt()) { + if (optname == TString(op->TheName())){ + Option<T>* oc = dynamic_cast<Option<T>*>(op); + if(oc!=0){ + oc->AddPreDefVal(val); + return; + } + else{ + Log() << kFATAL << "Option \"" << optname + << "\" was found, but somehow I could not convert the pointer propperly.. please check the syntax of your option declaration" << Endl; + return; + } + + } + } + Log() << kFATAL << "Option \"" << optname + << "\" is not declared, hence cannot add predefined value, please check the syntax of your option declaration" << Endl; + +} + //______________________________________________________________________ template <class T> void TMVA::Configurable::AssignOpt(const TString& name, T& valAssign) const diff --git a/tmva/inc/TMVA/DataSet.h b/tmva/inc/TMVA/DataSet.h index 534a642e892ee..45de19dca98f2 100644 --- a/tmva/inc/TMVA/DataSet.h +++ b/tmva/inc/TMVA/DataSet.h @@ -50,15 +50,15 @@ #ifndef ROOT_TTree #include "TTree.h" #endif -#ifndef ROOT_TCut -#include "TCut.h" -#endif -#ifndef ROOT_TMatrixDfwd -#include "TMatrixDfwd.h" -#endif -#ifndef ROOT_TPrincipal -#include "TPrincipal.h" -#endif +//#ifndef ROOT_TCut +//#include "TCut.h" +//#endif +//#ifndef ROOT_TMatrixDfwd +//#include "TMatrixDfwd.h" +//#endif +//#ifndef ROOT_TPrincipal +//#include "TPrincipal.h" +//#endif #ifndef ROOT_TRandom3 #include "TRandom3.h" #endif @@ -89,16 +89,22 @@ namespace TMVA { Long64_t GetNEvents( Types::ETreeType type = Types::kMaxTreeType ) const; Long64_t GetNTrainingEvents() const { return GetNEvents(Types::kTraining); } Long64_t GetNTestEvents() const { return GetNEvents(Types::kTesting); } - Event* GetEvent() const; // returns event without transformations - Event* GetEvent ( Long64_t ievt ) const { fCurrentEventIdx = ievt; return GetEvent(); } // returns event without transformations - Event* GetTrainingEvent( Long64_t ievt ) const { return GetEvent(ievt, Types::kTraining); } - Event* GetTestEvent ( Long64_t ievt ) const { return GetEvent(ievt, Types::kTesting); } - Event* GetEvent ( Long64_t ievt, Types::ETreeType type ) const { + + // const getters + const Event* GetEvent() const; // returns event without transformations + const Event* GetEvent ( Long64_t ievt ) const { fCurrentEventIdx = ievt; return GetEvent(); } // returns event without transformations + const Event* GetTrainingEvent( Long64_t ievt ) const { return GetEvent(ievt, Types::kTraining); } + const Event* GetTestEvent ( Long64_t ievt ) const { return GetEvent(ievt, Types::kTesting); } + const Event* GetEvent ( Long64_t ievt, Types::ETreeType type ) const + { fCurrentTreeIdx = TreeIndex(type); fCurrentEventIdx = ievt; return GetEvent(); } - UInt_t GetNVariables() const; - UInt_t GetNTargets() const; + + + + UInt_t GetNVariables() const; + UInt_t GetNTargets() const; UInt_t GetNSpectators() const; void SetCurrentEvent( Long64_t ievt ) const { fCurrentEventIdx = ievt; } @@ -162,7 +168,7 @@ namespace TMVA { mutable Long64_t fCurrentEventIdx; // event sampling - std::vector<Char_t> fSampling; // random or importance sampling (not all events are taken) !! Bool_t are stored ( no vector<bool> taken for speed (performance) issues ) + std::vector<Char_t> fSampling; // random or importance sampling (not all events are taken) !! Bool_t are stored ( no std::vector<bool> taken for speed (performance) issues ) std::vector<Int_t> fSamplingNEvents; // number of events which should be sampled std::vector<Float_t> fSamplingWeight; // weight change factor [weight is indicating if sampling is random (1.0) or importance (<1.0)] mutable std::vector< std::vector< std::pair< Float_t, Long64_t >* > > fSamplingEventList; // weights and indices for sampling @@ -181,7 +187,7 @@ namespace TMVA { std::vector<Char_t> fBlockBelongToTraining; // when dividing the dataset to blocks, sets whether // the certain block is in the Training set or else // in the validation set - // boolean are stored, taken vector<Char_t> for performance reasons (instead of vector<Bool_t>) + // boolean are stored, taken std::vector<Char_t> for performance reasons (instead of std::vector<Bool_t>) Long64_t fTrainingBlockSize; // block size into which the training dataset is divided void ApplyTrainingBlockDivision(); diff --git a/tmva/inc/TMVA/DataSetFactory.h b/tmva/inc/TMVA/DataSetFactory.h index bc92730269ff7..bfd54f04830a1 100644 --- a/tmva/inc/TMVA/DataSetFactory.h +++ b/tmva/inc/TMVA/DataSetFactory.h @@ -102,16 +102,16 @@ namespace TMVA { template<class T> struct DeleteFunctor_t { - DeleteFunctor_t& operator()(T* p) { + DeleteFunctor_t& operator()(const T* p) { delete p; return *this; } }; template<class T> - DeleteFunctor_t<T> DeleteFunctor() + DeleteFunctor_t<const T> DeleteFunctor() { - return DeleteFunctor_t<T>(); + return DeleteFunctor_t<const T>(); } @@ -207,7 +207,7 @@ namespace TMVA { class DataSetFactory { - typedef std::vector< Event* > EventVector; + typedef std::vector<Event* > EventVector; typedef std::vector< EventVector > EventVectorOfClasses; typedef std::map<Types::ETreeType, EventVectorOfClasses > EventVectorOfClassesOfTreeType; typedef std::map<Types::ETreeType, EventVector > EventVectorOfTreeType; @@ -311,6 +311,8 @@ namespace TMVA { Bool_t fVerbose; //! Verbosity TString fVerboseLevel; //! VerboseLevel + Bool_t fScaleWithPreselEff; //! how to deal with requested #events in connection with preselection cuts + // the event mutable TTree* fCurrentTree; //! the tree, events are currently read from mutable UInt_t fCurrentEvtIdx; //! the current event (to avoid reading of the same event) diff --git a/tmva/inc/TMVA/DataSetInfo.h b/tmva/inc/TMVA/DataSetInfo.h index 2d4038c348034..8553386960bc3 100644 --- a/tmva/inc/TMVA/DataSetInfo.h +++ b/tmva/inc/TMVA/DataSetInfo.h @@ -132,6 +132,18 @@ namespace TMVA { const TString& GetNormalization() const { return fNormalization; } void SetNormalization( const TString& norm ) { fNormalization = norm; } + void SetTrainingSumSignalWeights(Double_t trainingSumSignalWeights){fTrainingSumSignalWeights = trainingSumSignalWeights;} + void SetTrainingSumBackgrWeights(Double_t trainingSumBackgrWeights){fTrainingSumBackgrWeights = trainingSumBackgrWeights;} + void SetTestingSumSignalWeights (Double_t testingSumSignalWeights ){fTestingSumSignalWeights = testingSumSignalWeights ;} + void SetTestingSumBackgrWeights (Double_t testingSumBackgrWeights ){fTestingSumBackgrWeights = testingSumBackgrWeights ;} + + Double_t GetTrainingSumSignalWeights(); + Double_t GetTrainingSumBackgrWeights(); + Double_t GetTestingSumSignalWeights (); + Double_t GetTestingSumBackgrWeights (); + + + // classification information Int_t GetClassNameMaxLength() const; ClassInfo* GetClassInfo( Int_t clNum ) const; @@ -140,6 +152,7 @@ namespace TMVA { UInt_t GetNClasses() const { return fClasses.size(); } Bool_t IsSignal( const Event* ev ) const; std::vector<Float_t>* GetTargetsForMulticlass( const Event* ev ); + UInt_t GetSignalClassIndex(){return fSignalClass;} // by variable Int_t FindVarIndex( const TString& ) const; @@ -200,6 +213,13 @@ namespace TMVA { TString fNormalization; //! TString fSplitOptions; //! + + Double_t fTrainingSumSignalWeights; + Double_t fTrainingSumBackgrWeights; + Double_t fTestingSumSignalWeights ; + Double_t fTestingSumBackgrWeights ; + + TDirectory* fOwnRootDir; //! ROOT output dir Bool_t fVerbose; //! Verbosity diff --git a/tmva/inc/TMVA/DecisionTree.h b/tmva/inc/TMVA/DecisionTree.h index 5b9dba60c668a..95aa7ba06c065 100644 --- a/tmva/inc/TMVA/DecisionTree.h +++ b/tmva/inc/TMVA/DecisionTree.h @@ -78,16 +78,17 @@ namespace TMVA { public: typedef std::vector<TMVA::Event*> EventList; + typedef std::vector<const TMVA::Event*> EventConstList; // the constructur needed for the "reading" of the decision tree from weight files DecisionTree( void ); // the constructur needed for constructing the decision tree via training with events - DecisionTree( SeparationBase *sepType, Int_t minSize, + DecisionTree( SeparationBase *sepType, Float_t minSize, Int_t nCuts, UInt_t cls =0, Bool_t randomisedTree=kFALSE, Int_t useNvars=0, Bool_t usePoissonNvars=kFALSE, - UInt_t nNodesMax=999999, UInt_t nMaxDepth=9999999, + UInt_t nMaxDepth=9999999, Int_t iSeed=fgRandomSeed, Float_t purityLimit=0.5, Int_t treeID = 0); @@ -105,29 +106,31 @@ namespace TMVA { // building of a tree by recursivly splitting the nodes - UInt_t BuildTree( const EventList & eventSample, +// UInt_t BuildTree( const EventList & eventSample, +// DecisionTreeNode *node = NULL); + UInt_t BuildTree( const EventConstList & eventSample, DecisionTreeNode *node = NULL); // determine the way how a node is split (which variable, which cut value) - Double_t TrainNode( const EventList & eventSample, DecisionTreeNode *node ) { return TrainNodeFast( eventSample, node ); } - Double_t TrainNodeFast( const EventList & eventSample, DecisionTreeNode *node ); - Double_t TrainNodeFull( const EventList & eventSample, DecisionTreeNode *node ); + Double_t TrainNode( const EventConstList & eventSample, DecisionTreeNode *node ) { return TrainNodeFast( eventSample, node ); } + Double_t TrainNodeFast( const EventConstList & eventSample, DecisionTreeNode *node ); + Double_t TrainNodeFull( const EventConstList & eventSample, DecisionTreeNode *node ); void GetRandomisedVariables(Bool_t *useVariable, UInt_t *variableMap, UInt_t & nVars); - std::vector<Double_t> GetFisherCoefficients(const EventList &eventSample, UInt_t nFisherVars, UInt_t *mapVarInFisher); + std::vector<Double_t> GetFisherCoefficients(const EventConstList &eventSample, UInt_t nFisherVars, UInt_t *mapVarInFisher); // fill at tree with a given structure already (just see how many signa/bkgr // events end up in each node - void FillTree( EventList & eventSample); + void FillTree( const EventList & eventSample); // fill the existing the decision tree structure by filling event // in from the top node and see where they happen to end up - void FillEvent( TMVA::Event & event, + void FillEvent( const TMVA::Event & event, TMVA::DecisionTreeNode *node ); // returns: 1 = Signal (right), -1 = Bkg (left) - Double_t CheckEvent( const TMVA::Event & , Bool_t UseYesNoLeaf = kFALSE ) const; + Double_t CheckEvent( const TMVA::Event * , Bool_t UseYesNoLeaf = kFALSE ) const; TMVA::DecisionTreeNode* GetEventNode(const TMVA::Event & e) const; // return the individual relative variable importance @@ -144,23 +147,23 @@ namespace TMVA { void SetPruneMethod( EPruneMethod m = kCostComplexityPruning ) { fPruneMethod = m; } // recursive pruning of the tree, validation sample required for automatic pruning - Double_t PruneTree( EventList* validationSample = NULL ); + Double_t PruneTree( const EventConstList* validationSample = NULL ); // manage the pruning strength parameter (iff < 0 -> automate the pruning process) void SetPruneStrength( Double_t p ) { fPruneStrength = p; } Double_t GetPruneStrength( ) const { return fPruneStrength; } // apply pruning validation sample to a decision tree - void ApplyValidationSample( const EventList* validationSample ) const; + void ApplyValidationSample( const EventConstList* validationSample ) const; // return the misclassification rate of a pruned tree Double_t TestPrunedTreeQuality( const DecisionTreeNode* dt = NULL, Int_t mode=0 ) const; // pass a single validation event throught a pruned decision tree - void CheckEventWithPrunedTree( const TMVA::Event& ) const; + void CheckEventWithPrunedTree( const TMVA::Event* ) const; // calculate the normalization factor for a pruning validation sample - Double_t GetSumWeights( const EventList* validationSample ) const; + Double_t GetSumWeights( const EventConstList* validationSample ) const; void SetNodePurityLimit( Double_t p ) { fNodePurityLimit = p; } Double_t GetNodePurityLimit( ) const { return fNodePurityLimit; } @@ -180,7 +183,9 @@ namespace TMVA { // prune a node from the tree without deleting its descendants; allows one to // effectively prune a tree many times without making deep copies void PruneNodeInPlace( TMVA::DecisionTreeNode* node ); - + + Int_t GetNNodesBeforePruning(){return (fNNodesBeforePruning)?fNNodesBeforePruning:fNNodesBeforePruning=GetNNodes();} + UInt_t CountLeafNodes(TMVA::Node *n = NULL); @@ -193,7 +198,8 @@ namespace TMVA { inline void SetUseFisherCuts(Bool_t t=kTRUE) { fUseFisherCuts = t;} inline void SetMinLinCorrForFisher(Double_t min){fMinLinCorrForFisher = min;} inline void SetUseExclusiveVars(Bool_t t=kTRUE){fUseExclusiveVars = t;} - inline void SetPairNegWeightsInNode(){fPairNegWeightsInNode=kTRUE;} + inline void SetNVars(Int_t n){fNvars = n;} + private: // utility functions @@ -214,13 +220,15 @@ namespace TMVA { RegressionVariance *fRegType; // the separation crition used in Regression Double_t fMinSize; // min number of events in node + Double_t fMinNodeSize; // min fraction of training events in node Double_t fMinSepGain; // min number of separation gain to perform node splitting Bool_t fUseSearchTree; // cut scan done with binary trees or simple event loop. Double_t fPruneStrength; // a parameter to set the "amount" of pruning..needs to be adjusted EPruneMethod fPruneMethod; // method used for prunig - + Int_t fNNodesBeforePruning; //remember this one (in case of pruning, it allows to monitor the before/after + Double_t fNodePurityLimit;// purity limit to decide whether a node is signal Bool_t fRandomisedTree; // choose at each node splitting a random set of variables @@ -231,10 +239,8 @@ namespace TMVA { std::vector< Double_t > fVariableImportance; // the relative importance of the different variables - UInt_t fNNodesMax; // max # of nodes UInt_t fMaxDepth; // max depth UInt_t fSigClass; // class which is treated as signal when building the tree - Bool_t fPairNegWeightsInNode; // randomly pair miscl. ev. with neg. and pos. weights in node and don't boost them static const Int_t fgDebugLevel = 0; // debug level determining some printout/control plots etc. Int_t fTreeID; // just an ID number given to the tree.. makes debugging easier as tree knows who he is. diff --git a/tmva/inc/TMVA/DecisionTreeNode.h b/tmva/inc/TMVA/DecisionTreeNode.h index 1eed1b99da8dd..30a7922a1adf8 100644 --- a/tmva/inc/TMVA/DecisionTreeNode.h +++ b/tmva/inc/TMVA/DecisionTreeNode.h @@ -63,6 +63,9 @@ namespace TMVA { fNSigEvents_unweighted ( 0 ), fNBkgEvents_unweighted ( 0 ), fNEvents_unweighted ( 0 ), + fNSigEvents_unboosted ( 0 ), + fNBkgEvents_unboosted ( 0 ), + fNEvents_unboosted ( 0 ), fSeparationIndex (-1 ), fSeparationGain ( -1 ) { @@ -86,6 +89,9 @@ namespace TMVA { Float_t fNSigEvents_unweighted; // sum of signal event in the node Float_t fNBkgEvents_unweighted; // sum of backgr event in the node Float_t fNEvents_unweighted; // number of events in that entered the node (during training) + Float_t fNSigEvents_unboosted; // sum of signal event in the node + Float_t fNBkgEvents_unboosted; // sum of backgr event in the node + Float_t fNEvents_unboosted; // number of events in that entered the node (during training) Float_t fSeparationIndex; // measure of "purity" (separation between S and B) AT this node Float_t fSeparationGain; // measure of "purity", separation, or information gained BY this nodes selection @@ -196,6 +202,15 @@ namespace TMVA { // set the number of unweighted events that entered the node (during training) void SetNEvents_unweighted( Float_t nev ){ fTrainInfo->fNEvents_unweighted =nev ; } + // set the sum of the unboosted signal events in the node + void SetNSigEvents_unboosted( Float_t s ) { fTrainInfo->fNSigEvents_unboosted = s; } + + // set the sum of the unboosted backgr events in the node + void SetNBkgEvents_unboosted( Float_t b ) { fTrainInfo->fNBkgEvents_unboosted = b; } + + // set the number of unboosted events that entered the node (during training) + void SetNEvents_unboosted( Float_t nev ){ fTrainInfo->fNEvents_unboosted =nev ; } + // increment the sum of the signal weights in the node void IncrementNSigEvents( Float_t s ) { fTrainInfo->fNSigEvents += s; } @@ -232,6 +247,15 @@ namespace TMVA { // return the number of unweighted events that entered the node (during training) Float_t GetNEvents_unweighted( void ) const { return fTrainInfo->fNEvents_unweighted; } + // return the sum of unboosted signal weights in the node + Float_t GetNSigEvents_unboosted( void ) const { return fTrainInfo->fNSigEvents_unboosted; } + + // return the sum of unboosted backgr weights in the node + Float_t GetNBkgEvents_unboosted( void ) const { return fTrainInfo->fNBkgEvents_unboosted; } + + // return the number of unboosted events that entered the node (during training) + Float_t GetNEvents_unboosted( void ) const { return fTrainInfo->fNEvents_unboosted; } + // set the choosen index, measure of "purity" (separation between S and B) AT this node void SetSeparationIndex( Float_t sep ){ fTrainInfo->fSeparationIndex =sep ; } @@ -244,10 +268,10 @@ namespace TMVA { Float_t GetSeparationGain( void ) const { return fTrainInfo->fSeparationGain; } // printout of the node - virtual void Print( ostream& os ) const; + virtual void Print( std::ostream& os ) const; // recursively print the node and its daughters (--> print the 'tree') - virtual void PrintRec( ostream& os ) const; + virtual void PrintRec( std::ostream& os ) const; virtual void AddAttributesToNode(void* node) const; virtual void AddContentToNode(std::stringstream& s) const; @@ -315,8 +339,8 @@ namespace TMVA { // flag indicates whether this node is terminal inline Bool_t IsTerminal() const { return fIsTerminalNode; } inline void SetTerminal( Bool_t s = kTRUE ) { fIsTerminalNode = s; } - void PrintPrune( ostream& os ) const ; - void PrintRecPrune( ostream& os ) const; + void PrintPrune( std::ostream& os ) const ; + void PrintRecPrune( std::ostream& os ) const; void SetCC(Double_t cc); Double_t GetCC() const {return (fTrainInfo? fTrainInfo->fCC : -1.);} @@ -350,7 +374,7 @@ namespace TMVA { private: virtual void ReadAttributes(void* node, UInt_t tmva_Version_Code = TMVA_VERSION_CODE ); - virtual Bool_t ReadDataRecord( istream& is, UInt_t tmva_Version_Code = TMVA_VERSION_CODE ); + virtual Bool_t ReadDataRecord( std::istream& is, UInt_t tmva_Version_Code = TMVA_VERSION_CODE ); virtual void ReadContent(std::stringstream& s); ClassDef(DecisionTreeNode,0) // Node for the Decision Tree diff --git a/tmva/inc/TMVA/Event.h b/tmva/inc/TMVA/Event.h index 543f8ac4f2370..6ae43725af0e4 100644 --- a/tmva/inc/TMVA/Event.h +++ b/tmva/inc/TMVA/Event.h @@ -74,7 +74,8 @@ namespace TMVA { // accessors Bool_t IsDynamic() const {return fDynamic; } - Double_t GetWeight() const { return fWeight*fBoostWeight; } + // Double_t GetWeight() const { return fWeight*fBoostWeight; } + Double_t GetWeight() const; Double_t GetOriginalWeight() const { return fWeight; } Double_t GetBoostWeight() const { return TMath::Max(Double_t(0.0001),fBoostWeight); } UInt_t GetClass() const { return fClass; } @@ -84,41 +85,54 @@ namespace TMVA { UInt_t GetNSpectators() const; Float_t GetValue( UInt_t ivar) const; + std::vector<Float_t>& GetValues() + { + //For a detailed explanation, please see the heading "Avoid Duplication in const and Non-const Member Function," on p. 23, in Item 3 "Use const whenever possible," in Effective C++, 3d ed by Scott Meyers, ISBN-13: 9780321334879. + // http://stackoverflow.com/questions/123758/how-do-i-remove-code-duplication-between-similar-const-and-non-const-member-func + return const_cast<std::vector<Float_t>&>( static_cast<const Event&>(*this).GetValues() ); + } const std::vector<Float_t>& GetValues() const; Float_t GetTarget( UInt_t itgt ) const { return fTargets.at(itgt); } - std::vector<Float_t>& GetTargets() const { return fTargets; } + std::vector<Float_t>& GetTargets() { return fTargets; } + const std::vector<Float_t>& GetTargets() const { return fTargets; } Float_t GetSpectator( UInt_t ivar) const; - std::vector<Float_t>& GetSpectators() const { return fSpectators; } + std::vector<Float_t>& GetSpectators() { return fSpectators; } + const std::vector<Float_t>& GetSpectators() const { return fSpectators; } - void ScaleWeight ( Double_t s ) { fWeight*=s; } void SetWeight ( Double_t w ) { fWeight=w; } - void SetBoostWeight ( Double_t w ) { fDoNotBoost ? fDoNotBoost = kFALSE : fBoostWeight=w; } - void ScaleBoostWeight ( Double_t s ) { fDoNotBoost ? fDoNotBoost = kFALSE : fBoostWeight *= s; } + void SetBoostWeight ( Double_t w ) const { fDoNotBoost ? fDoNotBoost = kFALSE : fBoostWeight=w; } + void ScaleBoostWeight ( Double_t s ) const { fDoNotBoost ? fDoNotBoost = kFALSE : fBoostWeight *= s; } void SetClass ( UInt_t t ) { fClass=t; } void SetVal ( UInt_t ivar, Float_t val ); void SetTarget ( UInt_t itgt, Float_t value ); void SetSpectator ( UInt_t ivar, Float_t value ); - void SetDoNotBoost () { fDoNotBoost = kTRUE; } + void SetDoNotBoost () const { fDoNotBoost = kTRUE; } static void ClearDynamicVariables() {} void CopyVarValues( const Event& other ); void Print ( std::ostream & o ) const; + static void SetIsTraining(Bool_t); + static void SetIgnoreNegWeightsInTraining(Bool_t); private: - mutable std::vector<Float_t> fValues; // the event values + static Bool_t fgIsTraining; // mark if we are in an actual training or "evaluation/testing" phase --> ignoreNegWeights only in actual training ! + static Bool_t fgIgnoreNegWeightsInTraining; + + + mutable std::vector<Float_t> fValues; // the event values ; mutable, to be able to copy the dynamic values in there mutable std::vector<Float_t*>* fValuesDynamic; // the event values - mutable std::vector<Float_t> fTargets; // target values for regression - mutable std::vector<Float_t> fSpectators; // "visisting" variables not used in MVAs + std::vector<Float_t> fTargets; // target values for regression + mutable std::vector<Float_t> fSpectators; // "visisting" variables not used in MVAs ; mutable, to be able to copy the dynamic values in there UInt_t fClass; // class number Double_t fWeight; // event weight (product of global and individual weights) - Double_t fBoostWeight; // internal weight to be set by boosting algorithm + mutable Double_t fBoostWeight; // internal weight to be set by boosting algorithm Bool_t fDynamic; // is set when the dynamic values are taken - Bool_t fDoNotBoost; // mark event as not to be boosted (used to compensate for events with negative event weights + mutable Bool_t fDoNotBoost; // mark event as not to be boosted (used to compensate for events with negative event weights }; } diff --git a/tmva/inc/TMVA/Factory.h b/tmva/inc/TMVA/Factory.h index d142030c86ceb..8e180cc9a088b 100644 --- a/tmva/inc/TMVA/Factory.h +++ b/tmva/inc/TMVA/Factory.h @@ -184,8 +184,8 @@ namespace TMVA { MethodBase* BookMethod( TMVA::Types::EMVA /*theMethod*/, TString /*methodTitle*/, TString /*methodOption*/, - TMVA::Types::EMVA /*theCommittee*/, - TString /*committeeOption = ""*/ ) { return 0; } + TMVA::Types::EMVA /*theComposite*/, + TString /*compositeOption = ""*/ ) { return 0; } // optimize all booked methods (well, if desired by the method) void OptimizeAllMethods (TString fomType="ROCIntegral", TString fitType="FitGA"); diff --git a/tmva/inc/TMVA/GeneticPopulation.h b/tmva/inc/TMVA/GeneticPopulation.h index 5f4da2384827c..9d60224c0f24f 100644 --- a/tmva/inc/TMVA/GeneticPopulation.h +++ b/tmva/inc/TMVA/GeneticPopulation.h @@ -79,7 +79,7 @@ namespace TMVA { std::vector<TMVA::GeneticRange*>& GetRanges() { return fRanges; } void Print( Int_t untilIndex = -1 ); - void Print( ostream & out, Int_t utilIndex = -1 ); + void Print( std::ostream & out, Int_t utilIndex = -1 ); TH1F* VariableDistribution( Int_t varNumber, Int_t bins, Int_t min, Int_t max ); std::vector< Double_t > VariableDistribution( Int_t varNumber ); diff --git a/tmva/inc/TMVA/IMethod.h b/tmva/inc/TMVA/IMethod.h index ec671c9d1ef09..1b5c3e2927e47 100644 --- a/tmva/inc/TMVA/IMethod.h +++ b/tmva/inc/TMVA/IMethod.h @@ -94,9 +94,6 @@ namespace TMVA { // print help message virtual void PrintHelpMessage() const = 0; - // perfrom extra actions during the boosting at different stages - virtual Bool_t MonitorBoost( MethodBoost* boost) = 0; - virtual void Init() = 0; virtual void DeclareOptions() = 0; virtual void ProcessOptions() = 0; diff --git a/tmva/inc/TMVA/IPruneTool.h b/tmva/inc/TMVA/IPruneTool.h index 158559593b58a..205e362f4c964 100644 --- a/tmva/inc/TMVA/IPruneTool.h +++ b/tmva/inc/TMVA/IPruneTool.h @@ -73,7 +73,7 @@ namespace TMVA { public: - typedef std::vector<Event*> EventSample; + typedef std::vector<const Event*> EventSample; IPruneTool( ); virtual ~IPruneTool(); diff --git a/tmva/inc/TMVA/Interval.h b/tmva/inc/TMVA/Interval.h index 92f1c446774f0..c057bb883dc6e 100644 --- a/tmva/inc/TMVA/Interval.h +++ b/tmva/inc/TMVA/Interval.h @@ -69,23 +69,27 @@ namespace TMVA { virtual ~Interval(); // accessors - Double_t GetMin() const { return fMin; } - Double_t GetMax() const { return fMax; } - Double_t GetWidth() const { return fMax - fMin; } - Int_t GetNbins() const { return fNbins; } - Double_t GetMean() const { return (fMax + fMin)/2; } - Double_t GetRndm( TRandom3& ) const; - Double_t GetElement( Int_t position ) const; - Double_t GetStepSize() const; + // accessors + virtual Double_t GetMin() const { return fMin; } + virtual Double_t GetMax() const { return fMax; } + virtual Double_t GetWidth() const; + virtual Int_t GetNbins() const { return fNbins; } + virtual Double_t GetMean() const; + virtual Double_t GetRndm( TRandom3& ) const; + virtual Double_t GetElement( Int_t position ) const; + virtual Double_t GetStepSize(Int_t iBin=0) const; void SetMax( Double_t m ) { fMax = m; } void SetMin( Double_t m ) { fMin = m; } - private: + virtual void Print( std::ostream& os ) const; + + protected: Double_t fMin, fMax; // the constraints of the Interval Int_t fNbins; // when >0 : number of bins (discrete interval); when ==0 continuous interval + private: static MsgLogger* fgLogger; // message logger MsgLogger& Log() const { return *fgLogger; } diff --git a/tmva/inc/TMVA/LogInterval.h b/tmva/inc/TMVA/LogInterval.h new file mode 100644 index 0000000000000..f251e81cd1c67 --- /dev/null +++ b/tmva/inc/TMVA/LogInterval.h @@ -0,0 +1,116 @@ +/********************************************************************************** + * Project: TMVA - a Root-integrated toolkit for multivariate data analysis * + * Package: TMVA * + * Class : Interval * + * Web : http://tmva.sourceforge.net * + * * + * Description: * + * Extension of the Interval to "logarithmic" invarvals * + * * + * * + * * + * Authors (alphabetical): * + * Helge Voss <helge.voss@cern.ch> - MPI-K Heidelberg, Germany * + * * + * Copyright (c) 2005: * + * CERN, Switzerland * + * MPI-K Heidelberg, Germany * + * * + * Redistribution and use in source and binary forms, with or without * + * modification, are permitted according to the terms listed in LICENSE * + * (http://tmva.sourceforge.net/LICENSE) * + **********************************************************************************/ + +#ifndef ROOT_TMVA_LogInterval +#define ROOT_TMVA_LogInterval + +////////////////////////////////////////////////////////////////////////////// +// // +// Interval with non-equi distant bins // +// that are equi-distant in a logarithmic scale) // +// // +// Interval definition, continuous and discrete // +// // +// Note: **bin** counting starts from ZERO unlike in ROOT histograms // +// // +// ---------------- // +// LogInterval(1,10000,5) // +// i=0 --> 1 note: StepSize(ibin=0) = not defined !! // +// i=1 --> 10 StepSize(ibin=1) = 9 // +// i=2 --> 100 StepSize(ibin=2) = 99 // +// i=3 --> 1000 StepSize(ibin=3) = 999 // +// i=4 --> 10000 StepSize(ibin=4) = 9999 // +// // +// LogInterval(1,1000,11) // +// i=0 --> 1 // +// i=1 --> 1.99526 // +// i=2 --> 3.98107 // +// i=3 --> 7.94328 // +// i=4 --> 15.8489 // +// i=5 --> 31.6228 // +// i=6 --> 63.0957 // +// i=7 --> 125.893 // +// i=8 --> 251.189 // +// i=9 --> 501.187 // +// i=10 --> 1000 // +// // +// LogInterval(1,1024,11) // +// i=0 --> 1 // +// i=1 --> 2 // +// i=2 --> 4 // +// i=3 --> 8 // +// i=4 --> 16 // +// i=5 --> 32 // +// i=6 --> 64 // +// i=7 --> 128 // +// i=8 --> 256 // +// i=9 --> 512 // +// i=10 --> 1024 // +// // +////////////////////////////////////////////////////////////////////////////// +#ifndef ROOT_Rtypes +#include "Rtypes.h" +#endif + +#ifndef TMVA_Interval +#include "Interval.h" +#endif + + + +class TRandom3; + +namespace TMVA { + + class MsgLogger; + + class LogInterval : public Interval { + + public: + + LogInterval( Double_t min, Double_t max, Int_t nbins = 0 ); + LogInterval( const LogInterval& other ); + virtual ~LogInterval(); + + // accessors + virtual Double_t GetMin() const { return fMin; } + virtual Double_t GetMax() const { return fMax; } + virtual Double_t GetWidth() const; + virtual Int_t GetNbins() const { return fNbins; } + virtual Double_t GetMean() const; + virtual Double_t GetRndm( TRandom3& ) const; + virtual Double_t GetElement( Int_t position ) const; + virtual Double_t GetStepSize(Int_t iBin=0) const; + + void SetMax( Double_t m ) { fMax = m; } + void SetMin( Double_t m ) { fMin = m; } + + static MsgLogger* fgLogger; // message logger + MsgLogger& Log() const { return *fgLogger; } + + ClassDef(Interval,0) // Interval definition, continous and discrete + }; + +} // namespace TMVA + +#endif diff --git a/tmva/inc/TMVA/MethodANNBase.h b/tmva/inc/TMVA/MethodANNBase.h index b0fd992dfe35a..16c76adb4f52a 100644 --- a/tmva/inc/TMVA/MethodANNBase.h +++ b/tmva/inc/TMVA/MethodANNBase.h @@ -55,6 +55,9 @@ #ifndef ROOT_TRandom3 #include "TRandom3.h" #endif +#ifndef ROOT_TMatrix +#include "TMatrix.h" +#endif #ifndef ROOT_TMVA_MethodBase #include "TMVA/MethodBase.h" @@ -108,9 +111,20 @@ namespace TMVA { // this will have to be overridden by every subclass virtual void Train() = 0; - // print network, for debugging + // print network, for debugging virtual void PrintNetwork() const; - + + + // call this function like that: + // ... + // MethodMLP* mlp = dynamic_cast<MethodMLP*>(method); + // std::vector<float> layerValues; + // mlp->GetLayerActivation (2, std::back_inserter(layerValues)); + // ... do now something with the layerValues + // + template <typename WriteIterator> + void GetLayerActivation (size_t layer, WriteIterator writeIterator); + using MethodBase::ReadWeightsFromStream; // write weights to file @@ -118,7 +132,7 @@ namespace TMVA { void ReadWeightsFromXML( void* wghtnode ); // read weights from file - virtual void ReadWeightsFromStream( istream& istr ); + virtual void ReadWeightsFromStream( std::istream& istr ); // calculate the MVA value virtual Double_t GetMvaValue( Double_t* err = 0, Double_t* errUpper = 0 ); @@ -141,6 +155,7 @@ namespace TMVA { enum EEstimator { kMSE=0,kCE}; + protected: virtual void MakeClassSpecific( std::ostream&, const TString& ) const; @@ -158,8 +173,8 @@ namespace TMVA { // accessors Int_t NumCycles() { return fNcycles; } - TNeuron* GetInputNeuron(Int_t index) { return (TNeuron*)fInputLayer->At(index); } - TNeuron* GetOutputNeuron( Int_t index = 0) { return fOutputNeurons.at(index); } + TNeuron* GetInputNeuron (Int_t index) { return (TNeuron*)fInputLayer->At(index); } + TNeuron* GetOutputNeuron(Int_t index = 0) { return fOutputNeurons.at(index); } // protected variables TObjArray* fNetwork; // TObjArray of TObjArrays representing network @@ -193,6 +208,12 @@ namespace TMVA { protected: Int_t fRandomSeed; // random seed for initial synapse weights + Int_t fNcycles; // number of epochs to train + + TString fNeuronType; // name of neuron activation function class + TString fNeuronInputType; // name of neuron input calculator class + + private: // helper functions for building network @@ -214,9 +235,6 @@ namespace TMVA { void PrintNeuron(TNeuron* neuron) const; // private variables - Int_t fNcycles; // number of epochs to train - TString fNeuronType; // name of neuron activation function class - TString fNeuronInputType; // name of neuron input calculator class TObjArray* fInputLayer; // cache this for fast access std::vector<TNeuron*> fOutputNeurons; // cache this for fast access TString fLayerSpec; // layout specification option @@ -226,6 +244,29 @@ namespace TMVA { ClassDef(MethodANNBase,0) // Base class for TMVA ANNs }; + + + + template <typename WriteIterator> + inline void MethodANNBase::GetLayerActivation (size_t layerNumber, WriteIterator writeIterator) + { + // get the activation values of the nodes in layer "layer" + // write the node activation values into the writeIterator + // assumes, that the network has been computed already (by calling + // "GetRegressionValues") + + if (layerNumber >= (size_t)fNetwork->GetEntriesFast()) + return; + + TObjArray* layer = (TObjArray*)fNetwork->At(layerNumber); + UInt_t nNodes = layer->GetEntriesFast(); + for (UInt_t iNode = 0; iNode < nNodes; iNode++) + { + (*writeIterator) = ((TNeuron*)layer->At(iNode))->GetActivationValue(); + ++writeIterator; + } + } + } // namespace TMVA diff --git a/tmva/inc/TMVA/MethodBDT.h b/tmva/inc/TMVA/MethodBDT.h index fa9594507c29b..e8e08891997cd 100644 --- a/tmva/inc/TMVA/MethodBDT.h +++ b/tmva/inc/TMVA/MethodBDT.h @@ -100,7 +100,7 @@ namespace TMVA { void AddWeightsXMLTo( void* parent ) const; // read weights from file - void ReadWeightsFromStream( istream& istr ); + void ReadWeightsFromStream( std::istream& istr ); void ReadWeightsFromXML(void* parent); // write method specific histos to target file @@ -109,9 +109,11 @@ namespace TMVA { // calculate the MVA value Double_t GetMvaValue( Double_t* err = 0, Double_t* errUpper = 0); + // get the actual forest size (might be less than fNTrees, the requested one, if boosting is stopped early + UInt_t GetNTrees() const {return fForest.size();} private: Double_t GetMvaValue( Double_t* err, Double_t* errUpper, UInt_t useNTrees ); - Double_t PrivateGetMvaValue( TMVA::Event& ev, Double_t* err=0, Double_t* errUpper=0, UInt_t useNTrees=0 ); + Double_t PrivateGetMvaValue( const TMVA::Event *ev, Double_t* err=0, Double_t* errUpper=0, UInt_t useNTrees=0 ); void BoostMonitor(Int_t iTree); public: @@ -121,7 +123,7 @@ namespace TMVA { const std::vector<Float_t>& GetRegressionValues(); // apply the boost algorithm to a tree in the collection - Double_t Boost( std::vector<TMVA::Event*>, DecisionTree *dt, Int_t iTree, UInt_t cls = 0); + Double_t Boost( std::vector<const TMVA::Event*>&, DecisionTree *dt, UInt_t cls = 0); // ranking of input variables const Ranking* CreateRanking(); @@ -130,17 +132,22 @@ namespace TMVA { void DeclareOptions(); void ProcessOptions(); void SetMaxDepth(Int_t d){fMaxDepth = d;} - void SetNodeMinEvents(Int_t d){fNodeMinEvents = d;} + void SetMinNodeSize(Double_t sizeInPercent); + void SetMinNodeSize(TString sizeInPercent); + void SetNTrees(Int_t d){fNTrees = d;} void SetAdaBoostBeta(Double_t b){fAdaBoostBeta = b;} - void SetNodePurityLimit(Double_t l){fNodePurityLimit = l;} + void SetNodePurityLimit(Double_t l){fNodePurityLimit = l;} + void SetShrinkage(Double_t s){fShrinkage = s;} + void SetUseNvars(Int_t n){fUseNvars = n;} + void SetBaggedSampleFraction(Double_t f){fBaggedSampleFraction = f;} // get the forest inline const std::vector<TMVA::DecisionTree*> & GetForest() const; // get the forest - inline const std::vector<TMVA::Event*> & GetTrainingEvents() const; + inline const std::vector<const TMVA::Event*> & GetTrainingEvents() const; inline const std::vector<double> & GetBoostWeights() const; @@ -171,51 +178,58 @@ namespace TMVA { void PreProcessNegativeEventWeights(); // boosting algorithm (adaptive boosting) - Double_t AdaBoost( std::vector<TMVA::Event*>, DecisionTree *dt ); + Double_t AdaBoost( std::vector<const TMVA::Event*>&, DecisionTree *dt ); + + // boosting algorithm (adaptive boosting with cost matrix) + Double_t AdaCost( std::vector<const TMVA::Event*>&, DecisionTree *dt ); // boosting as a random re-weighting - Double_t Bagging( std::vector<TMVA::Event*>, Int_t iTree ); + Double_t Bagging( ); // boosting special for regression - Double_t RegBoost( std::vector<TMVA::Event*>, DecisionTree *dt ); + Double_t RegBoost( std::vector<const TMVA::Event*>&, DecisionTree *dt ); // adaboost adapted to regression - Double_t AdaBoostR2( std::vector<TMVA::Event*>, DecisionTree *dt ); + Double_t AdaBoostR2( std::vector<const TMVA::Event*>&, DecisionTree *dt ); // binomial likelihood gradient boost for classification // (see Friedman: "Greedy Function Approximation: a Gradient Boosting Machine" // Technical report, Dept. of Statistics, Stanford University) - Double_t GradBoost( std::vector<TMVA::Event*>, DecisionTree *dt, UInt_t cls = 0); - Double_t GradBoostRegression(std::vector<TMVA::Event*>, DecisionTree *dt ); - void InitGradBoost( std::vector<TMVA::Event*>); - void UpdateTargets( std::vector<TMVA::Event*>, UInt_t cls = 0); - void UpdateTargetsRegression( std::vector<TMVA::Event*>,Bool_t first=kFALSE); - Double_t GetGradBoostMVA(TMVA::Event& e, UInt_t nTrees); - void GetRandomSubSample(); + Double_t GradBoost( std::vector<const TMVA::Event*>&, DecisionTree *dt, UInt_t cls = 0); + Double_t GradBoostRegression(std::vector<const TMVA::Event*>&, DecisionTree *dt ); + void InitGradBoost( std::vector<const TMVA::Event*>&); + void UpdateTargets( std::vector<const TMVA::Event*>&, UInt_t cls = 0); + void UpdateTargetsRegression( std::vector<const TMVA::Event*>&,Bool_t first=kFALSE); + Double_t GetGradBoostMVA(const TMVA::Event *e, UInt_t nTrees); + void GetBaggedSubSample(std::vector<const TMVA::Event*>&); Double_t GetWeightedQuantile(std::vector<std::pair<Double_t, Double_t> > vec, const Double_t quantile, const Double_t SumOfWeights = 0.0); - std::vector<TMVA::Event*> fEventSample; // the training events - std::vector<TMVA::Event*> fValidationSample;// the Validation events - std::vector<TMVA::Event*> fSubSample; // subsample for bagged grad boost + std::vector<const TMVA::Event*> fEventSample; // the training events + std::vector<const TMVA::Event*> fValidationSample;// the Validation events + std::vector<const TMVA::Event*> fSubSample; // subsample for bagged grad boost + std::vector<const TMVA::Event*> *fTrainSample; // pointer to sample actually used in training (fEventSample or fSubSample) for example + Int_t fNTrees; // number of decision trees requested std::vector<DecisionTree*> fForest; // the collection of decision trees std::vector<double> fBoostWeights; // the weights applied in the individual boosts - Bool_t fRenormByClass; // individually re-normalize each event class to the original size after boosting + Double_t fSigToBkgFraction;// Signal to Background fraction assumed during training TString fBoostType; // string specifying the boost type Double_t fAdaBoostBeta; // beta parameter for AdaBoost algorithm TString fAdaBoostR2Loss; // loss type used in AdaBoostR2 (Linear,Quadratic or Exponential) Double_t fTransitionPoint; // break-down point for gradient regression Double_t fShrinkage; // learning rate for gradient boost; + Bool_t fBaggedBoost; // turn bagging in combination with boost on/off Bool_t fBaggedGradBoost; // turn bagging in combination with grad boost on/off - Double_t fSampleFraction; // fraction of events used for bagged grad boost Double_t fSumOfWeights; // sum of all event weights - std::map< TMVA::Event*, std::pair<Double_t, Double_t> > fWeightedResiduals; // weighted regression residuals - std::map< TMVA::Event*,std::vector<double> > fResiduals; // individual event residuals for gradient boost + std::map< const TMVA::Event*, std::pair<Double_t, Double_t> > fWeightedResiduals; // weighted regression residuals + std::map< const TMVA::Event*,std::vector<double> > fResiduals; // individual event residuals for gradient boost //options for the decision Tree SeparationBase *fSepType; // the separation used in node splitting TString fSepTypeS; // the separation (option string) used in node splitting - Int_t fNodeMinEvents; // min number of events in node + Int_t fMinNodeEvents; // min number of events in node + Float_t fMinNodeSize; // min percentage of training events in node + TString fMinNodeSizeS; // string containing min percentage of training events in node Int_t fNCuts; // grid used in cut applied in node splitting Bool_t fUseFisherCuts; // use multivariate splits using the Fisher criterium @@ -223,14 +237,12 @@ namespace TMVA { Bool_t fUseExclusiveVars; // individual variables already used in fisher criterium are not anymore analysed individually for node splitting Bool_t fUseYesNoLeaf; // use sig or bkg classification in leave nodes or sig/bkg Double_t fNodePurityLimit; // purity limit for sig/bkg nodes - Bool_t fUseWeightedTrees;// use average classification from the trees, or have the individual trees trees in the forest weighted (e.g. log(boostweight) from AdaBoost UInt_t fNNodesMax; // max # of nodes UInt_t fMaxDepth; // max depth DecisionTree::EPruneMethod fPruneMethod; // method used for prunig TString fPruneMethodS; // prune method option String Double_t fPruneStrength; // a parameter to set the "amount" of pruning..needs to be adjusted - Bool_t fPruneBeforeBoost;// flag to prune before boosting Double_t fFValidationEvents; // fraction of events to use for pruning Bool_t fAutomatic; // use user given prune strength or automatically determined one using a validation sample Bool_t fRandomisedTrees; // choose a random subset of possible cut variables at each node during training @@ -238,12 +250,11 @@ namespace TMVA { Bool_t fUsePoissonNvars; // use "fUseNvars" not as fixed number but as mean of a possion distr. in each split UInt_t fUseNTrainEvents; // number of randomly picked training events used in randomised (and bagged) trees - Double_t fSampleSizeFraction; // relative size of bagged event sample to original sample size + Double_t fBaggedSampleFraction; // relative size of bagged event sample to original sample size TString fNegWeightTreatment; // variable that holds the option of how to treat negative event weights in training Bool_t fNoNegWeightsInTraining; // ignore negative event weights in the training Bool_t fInverseBoostNegWeights; // boost ev. with neg. weights with 1/boostweight rathre than boostweight Bool_t fPairNegWeightsGlobal; // pair ev. with neg. and pos. weights in traning sample and "annihilate" them - Bool_t fPairNegWeightsInNode; // randomly pair miscl. ev. with neg. and pos. weights in node and don't boost them Bool_t fTrainWithNegWeights; // yes there are negative event weights and we don't ignore them Bool_t fDoBoostMonitor; //create control plot with ROC integral vs tree number @@ -254,8 +265,32 @@ namespace TMVA { Double_t fBoostWeight; // ntuple var: boost weight Double_t fErrorFraction; // ntuple var: misclassification error fraction + Double_t fCss; // Cost factor + Double_t fCts_sb; // Cost factor + Double_t fCtb_ss; // Cost factor + Double_t fCbb; // Cost factor + + Bool_t fDoPreselection; // do or do not perform automatic pre-selection of 100% eff. cuts + std::vector<Double_t> fVariableImportance; // the relative importance of the different variables + + void DeterminePreselectionCuts(const std::vector<const TMVA::Event*>& eventSample); + Double_t ApplyPreselectionCuts(const Event* ev); + + std::vector<Double_t> fLowSigCut; + std::vector<Double_t> fLowBkgCut; + std::vector<Double_t> fHighSigCut; + std::vector<Double_t> fHighBkgCut; + + std::vector<Bool_t> fIsLowSigCut; + std::vector<Bool_t> fIsLowBkgCut; + std::vector<Bool_t> fIsHighSigCut; + std::vector<Bool_t> fIsHighBkgCut; + + Bool_t fHistoricBool; //historic variable, only needed for "CompatibilityOptions" + + // debugging flags static const Int_t fgDebugLevel; // debug level determining some printout/control plots etc. @@ -267,7 +302,7 @@ namespace TMVA { } // namespace TMVA const std::vector<TMVA::DecisionTree*>& TMVA::MethodBDT::GetForest() const { return fForest; } -const std::vector<TMVA::Event*>& TMVA::MethodBDT::GetTrainingEvents() const { return fEventSample; } +const std::vector<const TMVA::Event*> & TMVA::MethodBDT::GetTrainingEvents() const { return fEventSample; } const std::vector<double>& TMVA::MethodBDT::GetBoostWeights() const { return fBoostWeights; } #endif diff --git a/tmva/inc/TMVA/MethodBase.h b/tmva/inc/TMVA/MethodBase.h index eb46537c7e3aa..550e3eb0060a6 100644 --- a/tmva/inc/TMVA/MethodBase.h +++ b/tmva/inc/TMVA/MethodBase.h @@ -201,6 +201,7 @@ namespace TMVA { } // probability of classifier response (mvaval) to be signal (requires "CreateMvaPdf" option set) + virtual Double_t GetProba( const Event *ev); // the simple one, automatically calcualtes the mvaVal and uses the SAME sig/bkg ratio as given in the training sample (typically 50/50 .. (NormMode=EqualNumEvents) but can be different) virtual Double_t GetProba( Double_t mvaVal, Double_t ap_sig ); // Rarity of classifier response (signal or background (default) is uniform in [0,1]) @@ -209,9 +210,6 @@ namespace TMVA { // create ranking virtual const Ranking* CreateRanking() = 0; - // perfrom extra actions during the boosting at different stages - virtual Bool_t MonitorBoost(MethodBoost* /*booster*/) {return kFALSE;}; - // make ROOT-independent C++ class virtual void MakeClass( const TString& classFileName = TString("") ) const; @@ -234,7 +232,6 @@ namespace TMVA { private: friend class MethodCategory; - friend class MethodCommittee; friend class MethodCompositeBase; void WriteStateToXML ( void* parent ) const; void ReadStateFromXML ( void* parent ); @@ -361,11 +358,15 @@ namespace TMVA { // ---------- event accessors ------------------------------------------------ // returns reference to data set + // NOTE: this DataSet is the "original" dataset, i.e. the one seen by ALL Classifiers WITHOUT transformation + DataSet* Data() const { return DataInfo().GetDataSet(); } DataSetInfo& DataInfo() const { return fDataSetInfo; } mutable const Event* fTmpEvent; //! temporary event when testing on a different DataSet than the own one // event reference and update + // NOTE: these Event accessors make sure that you get the events transformed according to the + // particular clasifiers transformation chosen UInt_t GetNEvents () const { return Data()->GetNEvents(); } const Event* GetEvent () const; const Event* GetEvent ( const TMVA::Event* ev ) const; @@ -383,7 +384,6 @@ namespace TMVA { virtual Bool_t IsSignalLike(); virtual Bool_t IsSignalLike(Double_t mvaVal); - DataSet* Data() const { return DataInfo().GetDataSet(); } Bool_t HasMVAPdfs() const { return fHasMVAPdfs; } virtual void SetAnalysisType( Types::EAnalysisType type ) { fAnalysisType = type; } @@ -451,17 +451,8 @@ namespace TMVA { // access to event information that needs method-specific information - Float_t GetTWeight( const Event* ev ) const { - return (fIgnoreNegWeightsInTraining && (ev->GetWeight() < 0)) ? 0. : ev->GetWeight(); - } - Bool_t IsConstructedFromWeightFile() const { return fConstructedFromWeightFile; } - public: - virtual void SetCurrentEvent( Long64_t ievt ) const { - Data()->SetCurrentEvent(ievt); - } - private: diff --git a/tmva/inc/TMVA/MethodBayesClassifier.h b/tmva/inc/TMVA/MethodBayesClassifier.h index e252c0b59048a..7f98c1e6b17ff 100644 --- a/tmva/inc/TMVA/MethodBayesClassifier.h +++ b/tmva/inc/TMVA/MethodBayesClassifier.h @@ -72,7 +72,7 @@ namespace TMVA { void AddWeightsXMLTo( void* parent ) const; // read weights from file - void ReadWeightsFromStream( istream& istr ); + void ReadWeightsFromStream( std::istream& istr ); void ReadWeightsFromXML ( void* /*wghtnode*/ ) {} // calculate the MVA value diff --git a/tmva/inc/TMVA/MethodBoost.h b/tmva/inc/TMVA/MethodBoost.h index 825440b4fefef..1e62142b6e434 100644 --- a/tmva/inc/TMVA/MethodBoost.h +++ b/tmva/inc/TMVA/MethodBoost.h @@ -88,14 +88,6 @@ namespace TMVA { Int_t GetBoostNum() { return fBoostNum; } - // gives the monitoring historgram from the vector according to index of the - // histrogram added in the MonitorBoost function - TH1* GetMonitoringHist( Int_t histInd ) { return (*fMonitorHist)[fDefaultHistNum+histInd]; } - - void AddMonitoringHist( TH1* hist ) { return fMonitorHist->push_back(hist); } - - Types::EBoostStage GetBoostStage() { return fBoostStage; } - void CleanBoostOptions(); Double_t GetMvaValue( Double_t* err=0, Double_t* errUpper = 0 ); @@ -112,20 +104,27 @@ namespace TMVA { void InitHistos(); void CheckSetup(); + void MonitorBoost( Types::EBoostStage stage, UInt_t methodIdx=0); + // the option handling methods void DeclareOptions(); + void DeclareCompatibilityOptions(); void ProcessOptions(); - MethodBoost* SetStage( Types::EBoostStage stage ) { fBoostStage = stage; return this; } + MethodBase* CurrentMethod(){return fCurrentMethod;} + UInt_t CurrentMethodIdx(){return fCurrentMethodIdx;} // training a single classifier void SingleTrain(); // calculating a boosting weight from the classifier, storing it in the next one - void SingleBoost(); + Double_t SingleBoost(MethodBase* method); + Double_t AdaBoost(MethodBase* method, Bool_t useYesNoLeaf ); + Double_t Bagging(); + // calculate weight of single method - void CalcMethodWeight(); + Double_t CalcMethodWeight(); // return ROC integral on training/testing sample Double_t GetBoostROCIntegral(Bool_t, Types::ETreeType, Bool_t CalcOverlapIntergral=kFALSE); @@ -140,7 +139,7 @@ namespace TMVA { virtual void TestClassification(); // finding the MVA to cut between sig and bgd according to fMVACutPerc,fMVACutType - void FindMVACut(); + void FindMVACut(MethodBase* method); // setting all the boost weights to 1 void ResetBoostWeights(); @@ -152,26 +151,21 @@ namespace TMVA { // sample void CalcMVAValues(); - Int_t fBoostNum; // Number of times the classifier is boosted - TString fBoostType; // string specifying the boost type - TString fMethodWeightType; // string specifying the boost type - Double_t fMethodError; // estimation of the level error of the classifier - // analysing the train dataset - Double_t fOrigMethodError; // estimation of the level error of the classifier - // analysing the train dataset (with unboosted weights) - Double_t fBoostWeight; // the weight used to boost the next classifier - TString fTransformString; // min and max values for the classifier response - Bool_t fDetailedMonitoring; // produce detailed monitoring histograms (boost-wise) + UInt_t fBoostNum; // Number of times the classifier is boosted + TString fBoostType; // string specifying the boost type + + TString fTransformString; // min and max values for the classifier response + Bool_t fDetailedMonitoring; // produce detailed monitoring histograms (boost-wise) - Double_t fADABoostBeta; // ADA boost parameter, default is 1 - UInt_t fRandomSeed; // seed for random number generator used for bagging + Double_t fAdaBoostBeta; // ADA boost parameter, default is 1 + UInt_t fRandomSeed; // seed for random number generator used for bagging + Double_t fBaggedSampleFraction;// rel.Size of bagged sample - TString fBoostedMethodName; // details of the boosted classifier - TString fBoostedMethodTitle; // title - TString fBoostedMethodOptions; // options + TString fBoostedMethodName; // details of the boosted classifier + TString fBoostedMethodTitle; // title + TString fBoostedMethodOptions; // options - std::vector<TH1*>* fMonitorHist; // histograms to monitor values during the boosting - Bool_t fMonitorBoostedMethod; // monitor the MVA response of every classifier + Bool_t fMonitorBoostedMethod; // monitor the MVA response of every classifier // MVA output from each classifier over the training hist, using orignal events weights std::vector< TH1* > fTrainSigMVAHist; @@ -181,12 +175,14 @@ namespace TMVA { std::vector< TH1* > fBTrainBgdMVAHist; // MVA output from each classifier over the testing hist std::vector< TH1* > fTestSigMVAHist; - std::vector< TH1* > fTestBgdMVAHist; + std::vector +< TH1* > fTestBgdMVAHist; - TTree* fMonitorTree; // tree to monitor values during the boosting - Types::EBoostStage fBoostStage; // stage of the boosting - Int_t fDefaultHistNum; // number of histogram filled for every type of boosted classifier - Bool_t fRecalculateMVACut; // whether to recalculate the MVA cut at every boosting step + //monitoring tree/ntuple and it's variables + TTree* fMonitorTree; // tree to monitor values during the boosting + Double_t fBoostWeight; // the weight used to boost the next classifier + Double_t fMethodError; // estimation of the level error of the classifier + // analysing the train dataset Double_t fROC_training; // roc integral of last trained method (on training sample) // overlap integral of mva distributions for signal and @@ -199,6 +195,9 @@ namespace TMVA { friend class Factory; // DSMTEST friend class Reader; // DSMTEST + TString fHistoricOption; //historic variable, only needed for "CompatibilityOptions" + Bool_t fHistoricBoolOption; //historic variable, only needed for "CompatibilityOptions" + protected: // get help message text diff --git a/tmva/inc/TMVA/MethodCFMlpANN.h b/tmva/inc/TMVA/MethodCFMlpANN.h index 01958146ee6d9..b73fe73006e59 100644 --- a/tmva/inc/TMVA/MethodCFMlpANN.h +++ b/tmva/inc/TMVA/MethodCFMlpANN.h @@ -91,10 +91,8 @@ #ifndef ROOT_TMVA_MethodCFMlpANN_Utils #include "TMVA/MethodCFMlpANN_Utils.h" #endif -#ifndef ROOT_TMVA_TMatrixFfwd -#ifndef ROOT_TMatrixFfwd -#include "TMatrixFfwd.h" -#endif +#ifndef ROOT_TMatrixF +#include "TMatrixF.h" #endif namespace TMVA { @@ -126,7 +124,7 @@ namespace TMVA { void AddWeightsXMLTo( void* parent ) const; // read weights from file - void ReadWeightsFromStream( istream& istr ); + void ReadWeightsFromStream( std::istream& istr ); void ReadWeightsFromXML( void* wghtnode ); // calculate the MVA value Double_t GetMvaValue( Double_t* err = 0, Double_t* errUpper = 0 ); diff --git a/tmva/inc/TMVA/MethodCFMlpANN_Utils.h b/tmva/inc/TMVA/MethodCFMlpANN_Utils.h index 5b5ba4dfef4e0..3d1fa1a1ae62c 100644 --- a/tmva/inc/TMVA/MethodCFMlpANN_Utils.h +++ b/tmva/inc/TMVA/MethodCFMlpANN_Utils.h @@ -46,6 +46,7 @@ #include "Rtypes.h" #endif +#include <cstdlib> ////////////////////////////////////////////////////////////////////////// // // // MethodCFMlpANN_Utils // diff --git a/tmva/inc/TMVA/MethodCommittee.h b/tmva/inc/TMVA/MethodCommittee.h deleted file mode 100644 index f591e1901a5fe..0000000000000 --- a/tmva/inc/TMVA/MethodCommittee.h +++ /dev/null @@ -1,168 +0,0 @@ -// @(#)root/tmva $Id$ -// Author: Andreas Hoecker, Joerg Stelzer, Helge Voss - -/********************************************************************************** - * Project: TMVA - a Root-integrated toolkit for multivariate data analysis * - * Package: TMVA * - * Class : MethodCommittee * - * Web : http://tmva.sourceforge.net * - * * - * Description: * - * Boosting * - * * - * Authors (alphabetical): * - * Andreas Hoecker <Andreas.Hocker@cern.ch> - CERN, Switzerland * - * Joerg Stelzer <Joerg.Stelzer@cern.ch> - CERN, Switzerland * - * Helge Voss <Helge.Voss@cern.ch> - MPI-K Heidelberg, Germany * - * * - * Copyright (c) 2005: * - * CERN, Switzerland * - * U. of Victoria, Canada * - * MPI-K Heidelberg, Germany * - * LAPP, Annecy, France * - * * - * Redistribution and use in source and binary forms, with or without * - * modification, are permitted according to the terms listed in LICENSE * - * (http://tmva.sourceforge.net/LICENSE) * - **********************************************************************************/ - -#ifndef ROOT_TMVA_MethodCommittee -#define ROOT_TMVA_MethodCommittee - -////////////////////////////////////////////////////////////////////////// -// // -// MethodCommittee // -// // -// Committee method // -// // -////////////////////////////////////////////////////////////////////////// - -#include <vector> -#include <iosfwd> -#ifndef ROOT_TH2 -#include "TH2.h" -#endif -#ifndef ROOT_TTree -#include "TTree.h" -#endif - -#ifndef ROOT_TMVA_MethodBase -#include "TMVA/MethodBase.h" -#endif - -namespace TMVA { - - class MethodCommittee : public MethodBase { - - public: - - // constructor for training and reading - MethodCommittee( const TString& jobName, - const TString& methodTitle, - DataSetInfo& dsi, - const TString& theOption, - TDirectory* theTargetDir = 0 ); - - // constructor for calculating Committee-MVA using previously generatad members - MethodCommittee( DataSetInfo& theData, - const TString& theWeightFile, - TDirectory* theTargetDir = 0 ); - - virtual ~MethodCommittee( void ); - - virtual Bool_t HasAnalysisType( Types::EAnalysisType type, UInt_t numberClasses, UInt_t numberTargets ); - - // overloaded members from MethodBase - void WriteStateToFile() const; - - // the training - void Train(); - - using MethodBase::ReadWeightsFromStream; - - // write weights to file - void AddWeightsXMLTo( void* parent ) const; - - // read weights from file - void ReadWeightsFromStream( istream& istr ); - void ReadWeightsFromXML ( void* /*wghtnode*/ ) {} - - // write method specific histos to target file - void WriteMonitoringHistosToFile( void ) const; - - // calculate the MVA value - Double_t GetMvaValue( Double_t* err = 0, Double_t* errUpper = 0 ); - - // apply the boost algorithm to a member in the committee - Double_t Boost( TMVA::MethodBase*, UInt_t imember ); - - // ranking of input variables - const Ranking* CreateRanking(); - - // the option handling methods - void DeclareOptions(); - void ProcessOptions(); - - // accessors - const std::vector<TMVA::IMethod*>& GetCommittee() const { return fCommittee; } - const std::vector<Double_t>& GetBoostWeights() const { return fBoostWeights; } - - //return the individual relative variable importance - std::vector<Double_t> GetVariableImportance(); - Double_t GetVariableImportance( UInt_t ivar ); - - protected: - - // make ROOT-independent C++ class for classifier response (classifier-specific implementation) - void MakeClassSpecific( std::ostream&, const TString& ) const; - - // get help message text - void GetHelpMessage() const; - - private: - - // accessors - std::vector<IMethod*>& GetCommittee() { return fCommittee; } - std::vector<Double_t>& GetBoostWeights() { return fBoostWeights; } - - // boosting algorithm (adaptive boosting) - Double_t AdaBoost( MethodBase* ); - - // boosting as a random re-weighting - Double_t Bagging( UInt_t imember); - - UInt_t fNMembers; // number of members requested - std::vector<IMethod*> fCommittee; // the collection of members - std::vector<Double_t> fBoostWeights; // the weights applied in the individual boosts - TString fBoostType; // string specifying the boost type - - // options for the MVA method - Types::EMVA fMemberType; // the MVA method to be boosted - TString fMemberOption; // the options for that method - - Bool_t fUseMemberDecision; // use binary information from IsSignal - // use average classification from the members, or have the individual members - - Bool_t fUseWeightedMembers; // in the committee weighted from AdaBoost - - - // Init used in the various constructors - void Init( void ); - - //some histograms for monitoring - TH1F* fBoostFactorHist; // weights applied in boosting - TH2F* fErrFractHist; // error fraction vs member number - TTree* fMonitorNtuple; // monitoring ntuple - Int_t fITree ; // ntuple var: ith member - Double_t fBoostFactor; // ntuple var: boost weight - Double_t fErrorFraction; // ntuple var: misclassification error fraction - Int_t fNnodes; // ntuple var: nNodes - - std::vector< Double_t > fVariableImportance; // the relative importance of the different variables - - ClassDef(MethodCommittee,0) // Analysis of Boosted MVA methods - }; - -} // namespace TMVA - -#endif diff --git a/tmva/inc/TMVA/MethodCompositeBase.h b/tmva/inc/TMVA/MethodCompositeBase.h index c12427f2fe7fe..20e2e6fb669a9 100644 --- a/tmva/inc/TMVA/MethodCompositeBase.h +++ b/tmva/inc/TMVA/MethodCompositeBase.h @@ -77,7 +77,7 @@ namespace TMVA { using MethodBase::GetMvaValue; // read weights from file - void ReadWeightsFromStream( istream& istr ); + void ReadWeightsFromStream( std::istream& istr ); // performs classifier training virtual void Train() = 0; @@ -87,15 +87,6 @@ namespace TMVA { virtual ~MethodCompositeBase( void ); - UInt_t GetMethodIndex() { return fMethodIndex; } - - IMethod* GetLastMethod() { return fMethods.back(); } - - IMethod* GetPreviousMethod() { return (fMethodIndex>0)?fMethods[fMethodIndex-1]:0; } - - IMethod* GetCurrentMethod() - { return (fMethodIndex>0)?fMethods[fMethodIndex]:0; } - protected: void DeclareOptions() = 0; @@ -106,7 +97,18 @@ namespace TMVA { IMethod* GetMethod( const Int_t index ) const; // accessor by index in vector //the index of the classifier currently boosted - Int_t fMethodIndex; + UInt_t fCurrentMethodIdx; + MethodBase* fCurrentMethod; + UInt_t GetCurrentMethodIndex() { return fCurrentMethodIdx; } + + IMethod* GetLastMethod() { return fMethods.back(); } + + IMethod* GetPreviousMethod() { return (fCurrentMethodIdx>0)?fMethods[fCurrentMethodIdx-1]:0; } + + MethodBase* GetCurrentMethod(){ return fCurrentMethod;} + MethodBase* GetCurrentMethod(UInt_t idx){return dynamic_cast<MethodBase*>(fMethods.at(idx)); } + + std::vector<IMethod*> fMethods; // vector of all classifiers diff --git a/tmva/inc/TMVA/MethodDT.h b/tmva/inc/TMVA/MethodDT.h index 4482d765707bc..1263bc893add1 100644 --- a/tmva/inc/TMVA/MethodDT.h +++ b/tmva/inc/TMVA/MethodDT.h @@ -82,7 +82,7 @@ namespace TMVA { void AddWeightsXMLTo( void* parent ) const; // read weights from file - void ReadWeightsFromStream( istream& istr ); + void ReadWeightsFromStream( std::istream& istr ); void ReadWeightsFromXML ( void* wghtnode ); // calculate the MVA value @@ -91,19 +91,24 @@ namespace TMVA { // the option handling methods void DeclareOptions(); void ProcessOptions(); + void DeclareCompatibilityOptions(); void GetHelpMessage() const; // ranking of input variables const Ranking* CreateRanking(); - Double_t PruneTree(const Int_t methodIndex); + Double_t PruneTree( ); Double_t TestTreeQuality( DecisionTree *dt ); Double_t GetPruneStrength () { return fPruneStrength; } - Bool_t MonitorBoost( MethodBoost* booster); + void SetMinNodeSize(Double_t sizeInPercent); + void SetMinNodeSize(TString sizeInPercent); + + Int_t GetNNodesBeforePruning(){return fTree->GetNNodesBeforePruning();} + Int_t GetNNodes(){return fTree->GetNNodes();} private: // Init used in the various constructors @@ -111,18 +116,20 @@ namespace TMVA { private: + std::vector<Event*> fEventSample; // the training events DecisionTree* fTree; // the decision tree //options for the decision Tree SeparationBase *fSepType; // the separation used in node splitting TString fSepTypeS; // the separation (option string) used in node splitting - Int_t fNodeMinEvents; // min number of events in node + Int_t fMinNodeEvents; // min number of events in node + Float_t fMinNodeSize; // min percentage of training events in node + TString fMinNodeSizeS; // string containing min percentage of training events in node Int_t fNCuts; // grid used in cut applied in node splitting Bool_t fUseYesNoLeaf; // use sig or bkg classification in leave nodes or sig/bkg Double_t fNodePurityLimit; // purity limit for sig/bkg nodes - UInt_t fNNodesMax; // max # of nodes UInt_t fMaxDepth; // max depth @@ -133,14 +140,16 @@ namespace TMVA { Bool_t fAutomatic; // use user given prune strength or automatically determined one using a validation sample Bool_t fRandomisedTrees; // choose a random subset of possible cut variables at each node during training Int_t fUseNvars; // the number of variables used in the randomised tree splitting - Bool_t fPruneBeforeBoost; //whether to prune right after the training (before the boosting) - + Bool_t fUsePoissonNvars; // fUseNvars is used as a poisson mean, and the actual value of useNvars is at each step drawn form that distribution std::vector<Double_t> fVariableImportance; // the relative importance of the different variables Double_t fDeltaPruneStrength; // step size in pruning, is adjusted according to experience of previous trees // debugging flags static const Int_t fgDebugLevel = 0; // debug level determining some printout/control plots etc. + + Bool_t fPruneBeforeBoost; //aincient variable, only needed for "CompatibilityOptions" + ClassDef(MethodDT,0) // Analysis of Decision Trees }; diff --git a/tmva/inc/TMVA/MethodFisher.h b/tmva/inc/TMVA/MethodFisher.h index f596ff1c97e71..1a34b35f78446 100644 --- a/tmva/inc/TMVA/MethodFisher.h +++ b/tmva/inc/TMVA/MethodFisher.h @@ -95,6 +95,10 @@ namespace TMVA { // ranking of input variables const Ranking* CreateRanking(); + // nice output + void PrintCoefficients( void ); + + protected: // make ROOT-independent C++ class for classifier response (classifier-specific implementation) @@ -127,9 +131,6 @@ namespace TMVA { // get discriminating power void GetDiscrimPower( void ); - // nice output - void PrintCoefficients( void ); - // get Fisher coefficients void GetFisherCoeff( void ); diff --git a/tmva/inc/TMVA/MethodHMatrix.h b/tmva/inc/TMVA/MethodHMatrix.h index 7f25284236b84..c066efb34c47d 100644 --- a/tmva/inc/TMVA/MethodHMatrix.h +++ b/tmva/inc/TMVA/MethodHMatrix.h @@ -86,7 +86,7 @@ namespace TMVA { void AddWeightsXMLTo( void* parent ) const; // read weights from file - void ReadWeightsFromStream( istream& istr ); + void ReadWeightsFromStream( std::istream& istr ); void ReadWeightsFromXML( void* wghtnode ); // calculate the MVA value Double_t GetMvaValue( Double_t* err = 0, Double_t* errUpper = 0 ); diff --git a/tmva/inc/TMVA/MethodLikelihood.h b/tmva/inc/TMVA/MethodLikelihood.h index decb1a4129a8f..470c80189a4cb 100644 --- a/tmva/inc/TMVA/MethodLikelihood.h +++ b/tmva/inc/TMVA/MethodLikelihood.h @@ -88,7 +88,7 @@ namespace TMVA { void AddWeightsXMLTo( void* parent ) const; // read weights from file - void ReadWeightsFromStream( istream& istr ); + void ReadWeightsFromStream( std::istream& istr ); void ReadWeightsFromStream( TFile& istr ); void ReadWeightsFromXML( void* wghtnode ); // calculate the MVA value @@ -101,7 +101,7 @@ namespace TMVA { // ranking of input variables const Ranking* CreateRanking(); - virtual void WriteOptionsToStream ( ostream& o, const TString& prefix ) const; + virtual void WriteOptionsToStream ( std::ostream& o, const TString& prefix ) const; protected: diff --git a/tmva/inc/TMVA/MethodMLP.h b/tmva/inc/TMVA/MethodMLP.h index 4752e1d09d853..5cfffb76de325 100644 --- a/tmva/inc/TMVA/MethodMLP.h +++ b/tmva/inc/TMVA/MethodMLP.h @@ -167,7 +167,7 @@ namespace TMVA { void TrainOneEvent( Int_t ievt); Double_t GetDesiredOutput( const Event* ev ); void UpdateNetwork( Double_t desired, Double_t eventWeight=1.0 ); - void UpdateNetwork(std::vector<Float_t>& desired, Double_t eventWeight=1.0); + void UpdateNetwork(const std::vector<Float_t>& desired, Double_t eventWeight=1.0); void CalculateNeuronDeltas(); void UpdateSynapses(); void AdjustSynapseWeights(); diff --git a/tmva/inc/TMVA/MethodPDERS.h b/tmva/inc/TMVA/MethodPDERS.h index ec7731eeff507..3ae5d497451eb 100644 --- a/tmva/inc/TMVA/MethodPDERS.h +++ b/tmva/inc/TMVA/MethodPDERS.h @@ -91,7 +91,7 @@ namespace TMVA { void AddWeightsXMLTo( void* parent ) const; // read weights from file - void ReadWeightsFromStream( istream& istr ); + void ReadWeightsFromStream( std::istream& istr ); void ReadWeightsFromStream( TFile& istr ); void ReadWeightsFromXML( void* wghtnode ); diff --git a/tmva/inc/TMVA/MethodRuleFit.h b/tmva/inc/TMVA/MethodRuleFit.h index 052df6dae2811..56a2897bd570f 100644 --- a/tmva/inc/TMVA/MethodRuleFit.h +++ b/tmva/inc/TMVA/MethodRuleFit.h @@ -81,7 +81,7 @@ namespace TMVA { void AddWeightsXMLTo ( void* parent ) const; // read weights from file - void ReadWeightsFromStream( istream& istr ); + void ReadWeightsFromStream( std::istream& istr ); void ReadWeightsFromXML ( void* wghtnode ); // calculate the MVA value diff --git a/tmva/inc/TMVA/MethodTMlpANN.h b/tmva/inc/TMVA/MethodTMlpANN.h index 4aa7454dca913..7418aac47cb03 100644 --- a/tmva/inc/TMVA/MethodTMlpANN.h +++ b/tmva/inc/TMVA/MethodTMlpANN.h @@ -75,7 +75,7 @@ namespace TMVA { void AddWeightsXMLTo( void* parent ) const; // read weights from file - void ReadWeightsFromStream( istream& istr ); + void ReadWeightsFromStream( std::istream& istr ); void ReadWeightsFromXML(void* wghtnode); // calculate the MVA value ... diff --git a/tmva/inc/TMVA/OptimizeConfigParameters.h b/tmva/inc/TMVA/OptimizeConfigParameters.h index 40d57a6797302..03a4b268a8e67 100644 --- a/tmva/inc/TMVA/OptimizeConfigParameters.h +++ b/tmva/inc/TMVA/OptimizeConfigParameters.h @@ -65,7 +65,7 @@ namespace TMVA { public: //default constructor - OptimizeConfigParameters(MethodBase * const method, std::map<TString,TMVA::Interval> tuneParameters, TString fomType="Separation", TString optimizationType = "GA"); + OptimizeConfigParameters(MethodBase * const method, std::map<TString,TMVA::Interval*> tuneParameters, TString fomType="Separation", TString optimizationType = "GA"); // destructor virtual ~OptimizeConfigParameters(); @@ -94,7 +94,7 @@ namespace TMVA { MethodBase* const fMethod; // The MVA method to be evaluated std::vector<Float_t> fFOMvsIter; // graph showing the develompment of the Figure Of Merit values during the fit - std::map<TString,TMVA::Interval> fTuneParameters; // parameters included in the tuning + std::map<TString,TMVA::Interval*> fTuneParameters; // parameters included in the tuning std::map<TString,Double_t> fTunedParameters; // parameters included in the tuning std::map< std::vector<Double_t> , Double_t> fAlreadyTrainedParCombination; // save parameters for which the FOM is already known (GA seems to evaluate the same parameters several times) TString fFOMType; // the FOM type (Separation, ROC integra.. whaeter you implemented.. @@ -105,6 +105,7 @@ namespace TMVA { TH1D *fMvaSigFineBin; // MVA distrituion for signal events TH1D *fMvaBkgFineBin; // MVA distrituion for bakgr. events + Bool_t fNotDoneYet; // flat to indicate of Method Transformations have been optained yet or not (normally done in MethodBase::TrainMethod) mutable MsgLogger* fLogger; // message logger MsgLogger& Log() const { return *fLogger; } diff --git a/tmva/inc/TMVA/Option.h b/tmva/inc/TMVA/Option.h index 25b7c18e2c9cf..458b3acb8ac1a 100644 --- a/tmva/inc/TMVA/Option.h +++ b/tmva/inc/TMVA/Option.h @@ -33,7 +33,7 @@ // // // Option // // // -// Class for MVA-option handling // +// Class for TMVA-option handling // // // ////////////////////////////////////////////////////////////////////////// @@ -80,7 +80,7 @@ namespace TMVA { virtual Bool_t SetValue( const TString& vs, Int_t i=-1 ); using TObject::Print; - virtual void Print( ostream&, Int_t levelofdetail=0 ) const = 0; + virtual void Print( std::ostream&, Int_t levelofdetail=0 ) const = 0; private: @@ -120,8 +120,8 @@ namespace TMVA { // setters virtual void AddPreDefVal(const T&); using OptionBase::Print; - virtual void Print ( ostream&, Int_t levelofdetail=0 ) const; - virtual void PrintPreDefs( ostream&, Int_t levelofdetail=0 ) const; + virtual void Print ( std::ostream&, Int_t levelofdetail=0 ) const; + virtual void PrintPreDefs( std::ostream&, Int_t levelofdetail=0 ) const; protected: @@ -153,7 +153,7 @@ namespace TMVA { virtual Int_t GetArraySize() const { return fSize; } using Option<T>::Print; - virtual void Print( ostream&, Int_t levelofdetail=0 ) const; + virtual void Print( std::ostream&, Int_t levelofdetail=0 ) const; virtual Bool_t SetValue( const TString& val, Int_t i=0 ); @@ -262,7 +262,7 @@ namespace TMVA { } template<class T> - inline void TMVA::Option<T>::Print( ostream& os, Int_t levelofdetail ) const + inline void TMVA::Option<T>::Print( std::ostream& os, Int_t levelofdetail ) const { // template specialization for TString printing os << TheName() << ": " << "\"" << GetValue() << "\"" << " [" << Description() << "]"; @@ -270,7 +270,7 @@ namespace TMVA { } template<class T> - inline void TMVA::Option<T*>::Print( ostream& os, Int_t levelofdetail ) const + inline void TMVA::Option<T*>::Print( std::ostream& os, Int_t levelofdetail ) const { // template specialization for TString printing for (Int_t i=0; i<fSize; i++) { @@ -285,7 +285,7 @@ namespace TMVA { //______________________________________________________________________ template<class T> - inline void TMVA::Option<T>::PrintPreDefs( ostream& os, Int_t levelofdetail ) const + inline void TMVA::Option<T>::PrintPreDefs( std::ostream& os, Int_t levelofdetail ) const { // template specialization for TString printing if (HasPreDefinedVal() && levelofdetail>0) { diff --git a/tmva/inc/TMVA/PDEFoam.h b/tmva/inc/TMVA/PDEFoam.h index 70afc01857917..7c414c32f5d2d 100644 --- a/tmva/inc/TMVA/PDEFoam.h +++ b/tmva/inc/TMVA/PDEFoam.h @@ -67,7 +67,7 @@ namespace TMVA { class PDEFoam; // separation types - enum EDTSeparation { kFoam, kGiniIndex, kMisClassificationError, + enum EDTSeparation { kFoam, kGiniIndex, kMisClassificationError, kCrossEntropy, kGiniIndexWithLaplace, kSdivSqrtSplusB }; // foam types @@ -76,12 +76,13 @@ namespace TMVA { // enum type for possible foam cell values // kValue : cell value who's rms is minimized // kValueError : error on kValue - // kValueDensity : volume density of kValue + // kValueDensity : kValue / cell volume // kMeanValue : mean sampling value (saved in fIntegral) // kRms : rms of sampling distribution (saved in fDriver) // kRmsOvMean : rms/mean of sampling distribution (saved in // fDriver and fIntegral) - enum ECellValue { kValue, kValueError, kValueDensity, kMeanValue, + // kCellVolume : volume of cell + enum ECellValue { kValue, kValueError, kValueDensity, kMeanValue, kRms, kRmsOvMean, kCellVolume }; } @@ -183,7 +184,7 @@ namespace TMVA { // Square function (fastest implementation) template<typename T> T Sqr(T x) const { return x*x; } - + PDEFoam(const PDEFoam&); // Copy Constructor NOT USED // ---------- Public functions ---------------------------------- @@ -194,7 +195,7 @@ namespace TMVA { // ---------- Foam creation functions - void Initialize(){}; // initialize the PDEFoam + void Initialize() {} // initialize the PDEFoam void FillBinarySearchTree( const Event* ev ); // fill event into BST void Create(); // build-up foam @@ -205,7 +206,7 @@ namespace TMVA { void ResetCellElements(); // function to call after foam is grown - virtual void Finalize(){}; + virtual void Finalize() {} // ---------- Getters and Setters @@ -220,10 +221,10 @@ namespace TMVA { // coverity[ -tainted_data_return ] Int_t GetTotDim() const {return fDim; } // Get total dimension TString GetFoamName() const {return fName; } // Get name of foam - UInt_t GetNActiveCells() const {return fNoAct;}; // returns number of active cells - UInt_t GetNInActiveCells() const {return GetNCells()-GetNActiveCells();}; // returns number of not active cells - UInt_t GetNCells() const {return fNCells;}; // returns number of cells - PDEFoamCell* GetRootCell() const {return fCells[0];}; // get pointer to root cell + UInt_t GetNActiveCells() const {return fNoAct;} // returns number of active cells + UInt_t GetNInActiveCells() const {return GetNCells()-GetNActiveCells();} // returns number of not active cells + UInt_t GetNCells() const {return fNCells;} // returns number of cells + PDEFoamCell* GetRootCell() const {return fCells[0];} // get pointer to root cell // Getters and Setters for user cut options void SetNmin(UInt_t val) { fNmin=val; } @@ -266,7 +267,7 @@ namespace TMVA { // ---------- Foam projection methods // project foam to two-dimensional histogram - virtual TH2D* Project2(Int_t idim1, Int_t idim2, ECellValue cell_value=kValue, + virtual TH2D* Project2(Int_t idim1, Int_t idim2, ECellValue cell_value=kValue, PDEFoamKernelBase *kernel=NULL, UInt_t nbin=50); // Project one-dimensional foam to a 1-dim histogram diff --git a/tmva/inc/TMVA/PDEFoamDecisionTreeDensity.h b/tmva/inc/TMVA/PDEFoamDecisionTreeDensity.h index 07b4d473dffb6..a3b3806149e29 100644 --- a/tmva/inc/TMVA/PDEFoamDecisionTreeDensity.h +++ b/tmva/inc/TMVA/PDEFoamDecisionTreeDensity.h @@ -59,7 +59,7 @@ namespace TMVA PDEFoamDecisionTreeDensity(); PDEFoamDecisionTreeDensity(std::vector<Double_t> box, UInt_t cls); PDEFoamDecisionTreeDensity(const PDEFoamDecisionTreeDensity&); - virtual ~PDEFoamDecisionTreeDensity() {}; + virtual ~PDEFoamDecisionTreeDensity() {} // returns allways 0 virtual Double_t Density(std::vector<Double_t> &Xarg, Double_t &event_density); diff --git a/tmva/inc/TMVA/PDEFoamDiscriminant.h b/tmva/inc/TMVA/PDEFoamDiscriminant.h index 613cb82bd0100..992ab8dbafb15 100644 --- a/tmva/inc/TMVA/PDEFoamDiscriminant.h +++ b/tmva/inc/TMVA/PDEFoamDiscriminant.h @@ -49,7 +49,7 @@ namespace TMVA public: PDEFoamDiscriminant(); // Default constructor (used only by ROOT streamer) PDEFoamDiscriminant(const TString&, UInt_t); // Principal user-defined constructor - virtual ~PDEFoamDiscriminant() {}; // Default destructor + virtual ~PDEFoamDiscriminant() {} // Default destructor // function to fill created cell with given value virtual void FillFoamCells(const Event* ev, Float_t wt); diff --git a/tmva/inc/TMVA/PDEFoamDiscriminantDensity.h b/tmva/inc/TMVA/PDEFoamDiscriminantDensity.h index 4551475663d7b..ddfa11b9d2e94 100644 --- a/tmva/inc/TMVA/PDEFoamDiscriminantDensity.h +++ b/tmva/inc/TMVA/PDEFoamDiscriminantDensity.h @@ -50,7 +50,7 @@ namespace TMVA PDEFoamDiscriminantDensity(); PDEFoamDiscriminantDensity(std::vector<Double_t> box, UInt_t cls); PDEFoamDiscriminantDensity(const PDEFoamDiscriminantDensity&); - virtual ~PDEFoamDiscriminantDensity() {}; + virtual ~PDEFoamDiscriminantDensity() {} // main function used by PDEFoam // returns discriminant density N_class/N_total at a given point diff --git a/tmva/inc/TMVA/PDEFoamEvent.h b/tmva/inc/TMVA/PDEFoamEvent.h index c5f3f9110e7b2..4e4f7ed59f338 100644 --- a/tmva/inc/TMVA/PDEFoamEvent.h +++ b/tmva/inc/TMVA/PDEFoamEvent.h @@ -48,7 +48,7 @@ namespace TMVA public: PDEFoamEvent(); // Default constructor (used only by ROOT streamer) PDEFoamEvent(const TString&); // Principal user-defined constructor - virtual ~PDEFoamEvent() {}; // Default destructor + virtual ~PDEFoamEvent() {} // Default destructor // function to fill created cell with given value virtual void FillFoamCells(const Event* ev, Float_t wt); diff --git a/tmva/inc/TMVA/PDEFoamEventDensity.h b/tmva/inc/TMVA/PDEFoamEventDensity.h index 5edb6e8dc68b8..5c0e950e48ff4 100644 --- a/tmva/inc/TMVA/PDEFoamEventDensity.h +++ b/tmva/inc/TMVA/PDEFoamEventDensity.h @@ -47,7 +47,7 @@ namespace TMVA PDEFoamEventDensity(); PDEFoamEventDensity(std::vector<Double_t> box); PDEFoamEventDensity(const PDEFoamEventDensity&); - virtual ~PDEFoamEventDensity() {}; + virtual ~PDEFoamEventDensity() {} // main function used by PDEFoam // returns event density at a given point by range searching in BST diff --git a/tmva/inc/TMVA/PDEFoamKernelGauss.h b/tmva/inc/TMVA/PDEFoamKernelGauss.h index e97698999982c..cde4f70a12da5 100644 --- a/tmva/inc/TMVA/PDEFoamKernelGauss.h +++ b/tmva/inc/TMVA/PDEFoamKernelGauss.h @@ -56,7 +56,7 @@ namespace TMVA public: PDEFoamKernelGauss(Float_t sigma); // Constructor PDEFoamKernelGauss(const PDEFoamKernelGauss&); // Copy Constructor - virtual ~PDEFoamKernelGauss() {}; // Destructor + virtual ~PDEFoamKernelGauss() {} // Destructor // kernel estimator virtual Float_t Estimate(PDEFoam*, std::vector<Float_t>&, ECellValue); diff --git a/tmva/inc/TMVA/PDEFoamKernelLinN.h b/tmva/inc/TMVA/PDEFoamKernelLinN.h index 5ea9c3404e6f5..174b2f8f930cb 100644 --- a/tmva/inc/TMVA/PDEFoamKernelLinN.h +++ b/tmva/inc/TMVA/PDEFoamKernelLinN.h @@ -51,7 +51,7 @@ namespace TMVA public: PDEFoamKernelLinN(); // Constructor PDEFoamKernelLinN(const PDEFoamKernelLinN&); // Copy Constructor - virtual ~PDEFoamKernelLinN() {}; // Destructor + virtual ~PDEFoamKernelLinN() {} // Destructor // kernel estimator virtual Float_t Estimate(PDEFoam*, std::vector<Float_t>&, ECellValue); diff --git a/tmva/inc/TMVA/PDEFoamKernelTrivial.h b/tmva/inc/TMVA/PDEFoamKernelTrivial.h index 398f7d835bf93..14c30a5cf425d 100644 --- a/tmva/inc/TMVA/PDEFoamKernelTrivial.h +++ b/tmva/inc/TMVA/PDEFoamKernelTrivial.h @@ -44,7 +44,7 @@ namespace TMVA public: PDEFoamKernelTrivial(); // Constructor PDEFoamKernelTrivial(const PDEFoamKernelTrivial&); // Copy Constructor - virtual ~PDEFoamKernelTrivial() {}; // Destructor + virtual ~PDEFoamKernelTrivial() {} // Destructor // kernel estimator virtual Float_t Estimate(PDEFoam*, std::vector<Float_t>&, ECellValue); diff --git a/tmva/inc/TMVA/PDEFoamMultiTarget.h b/tmva/inc/TMVA/PDEFoamMultiTarget.h index 937af102e6e32..d707bd90219f3 100644 --- a/tmva/inc/TMVA/PDEFoamMultiTarget.h +++ b/tmva/inc/TMVA/PDEFoamMultiTarget.h @@ -56,7 +56,7 @@ namespace TMVA public: PDEFoamMultiTarget(); // Default constructor (used only by ROOT streamer) PDEFoamMultiTarget(const TString&, ETargetSelection); // Principal user-defined constructor - virtual ~PDEFoamMultiTarget() {}; // Default destructor + virtual ~PDEFoamMultiTarget() {} // Default destructor // overridden from PDEFoam: extract the targets from the foam virtual std::vector<Float_t> GetCellValue(const std::map<Int_t, Float_t>&, ECellValue); diff --git a/tmva/inc/TMVA/PDEFoamTarget.h b/tmva/inc/TMVA/PDEFoamTarget.h index d6cf31ac01a7a..36968fa43b6d3 100644 --- a/tmva/inc/TMVA/PDEFoamTarget.h +++ b/tmva/inc/TMVA/PDEFoamTarget.h @@ -56,7 +56,7 @@ namespace TMVA public: PDEFoamTarget(); // Default constructor (used only by ROOT streamer) PDEFoamTarget(const TString&, UInt_t); // Principal user-defined constructor - virtual ~PDEFoamTarget() {}; // Default destructor + virtual ~PDEFoamTarget() {} // Default destructor // function to fill created cell with given value virtual void FillFoamCells(const Event* ev, Float_t wt); diff --git a/tmva/inc/TMVA/PDEFoamTargetDensity.h b/tmva/inc/TMVA/PDEFoamTargetDensity.h index 6a985cf87865f..44a23b36902e2 100644 --- a/tmva/inc/TMVA/PDEFoamTargetDensity.h +++ b/tmva/inc/TMVA/PDEFoamTargetDensity.h @@ -50,7 +50,7 @@ namespace TMVA PDEFoamTargetDensity(); PDEFoamTargetDensity(std::vector<Double_t> box, UInt_t target); PDEFoamTargetDensity(const PDEFoamTargetDensity&); - virtual ~PDEFoamTargetDensity() {}; + virtual ~PDEFoamTargetDensity() {} // main function used by PDEFoam // returns event density at a given point by range searching in BST diff --git a/tmva/inc/TMVA/PDF.h b/tmva/inc/TMVA/PDF.h index be6dff09c6298..9962198ec37d8 100644 --- a/tmva/inc/TMVA/PDF.h +++ b/tmva/inc/TMVA/PDF.h @@ -62,13 +62,13 @@ namespace TMVA { class MsgLogger; class PDF; - ostream& operator<< ( ostream& os, const PDF& tree ); - istream& operator>> ( istream& istr, PDF& tree); + std::ostream& operator<< ( std::ostream& os, const PDF& tree ); + std::istream& operator>> ( std::istream& istr, PDF& tree); class PDF : public Configurable { - friend ostream& operator<< ( ostream& os, const PDF& tree ); - friend istream& operator>> ( istream& istr, PDF& tree); + friend std::ostream& operator<< ( std::ostream& os, const PDF& tree ); + friend std::istream& operator>> ( std::istream& istr, PDF& tree); public: @@ -95,6 +95,7 @@ namespace TMVA { // histogram underlying the PDF TH1* GetPDFHist() const { return fPDFHist; } + TGraph* GetGraph() const { return fGraph; } TH1* GetOriginalHist() const { return fHistOriginal; } TH1* GetSmoothedHist() const { return fHist; } TH1* GetNSmoothHist() const { return fNSmoothHist; } @@ -123,7 +124,7 @@ namespace TMVA { void SetReadingVersion( UInt_t rv ) { fReadingVersion = rv; } UInt_t GetReadingVersion() const { return fReadingVersion; } - //void WriteOptionsToStream ( ostream& o, const TString& prefix ) const; + //void WriteOptionsToStream ( std::ostream& o, const TString& prefix ) const; void ProcessOptions(); // reads from and option string the definitions for pdf returns it diff --git a/tmva/inc/TMVA/QuickMVAProbEstimator.h b/tmva/inc/TMVA/QuickMVAProbEstimator.h new file mode 100644 index 0000000000000..0bc30775f30f8 --- /dev/null +++ b/tmva/inc/TMVA/QuickMVAProbEstimator.h @@ -0,0 +1,48 @@ +#ifndef ROOT_TMVA_QUICKMVAPROBESTIMATOR +#define ROOT_TMVA_QUICKMVAPROBESTIMATOR + +#include <iostream> +#include <vector> +#include <algorithm> + +#include "TMVA/MsgLogger.h" + +namespace TMVA { + + class QuickMVAProbEstimator { + public: + + struct EventInfo{ + Double_t eventValue; + Double_t eventWeight; + Int_t eventType; //signal or background + }; + static bool compare(EventInfo e1, EventInfo e2){return e1.eventValue < e2.eventValue;} + + QuickMVAProbEstimator(Int_t nMin=40, Int_t nMax=5000):fIsSorted(false),fNMin(nMin),fNMax(nMax){ fLogger = new MsgLogger("QuickMVAProbEstimator");} + + + virtual ~QuickMVAProbEstimator(){delete fLogger;} + void AddEvent(Double_t val, Double_t weight, Int_t type); + + + Double_t GetMVAProbAt(Double_t value); + + + private: + std::vector<EventInfo> fEvtVector; + Bool_t fIsSorted; + UInt_t fNMin; + UInt_t fNMax; + + mutable MsgLogger* fLogger; + MsgLogger& Log() const { return *fLogger; } + + ClassDef(QuickMVAProbEstimator,0) // Interface to different separation critiera used in training algorithms + + + }; +} + + +#endif diff --git a/tmva/inc/TMVA/Results.h b/tmva/inc/TMVA/Results.h index 07e189142b259..2ee90c28486df 100644 --- a/tmva/inc/TMVA/Results.h +++ b/tmva/inc/TMVA/Results.h @@ -52,6 +52,7 @@ #endif class TH1; +class TH2; class TGraph; namespace TMVA { @@ -63,7 +64,7 @@ namespace TMVA { public: - Results( const DataSetInfo* dsi ); + Results( const DataSetInfo* dsi, TString resultsName ); virtual ~Results(); // setters @@ -77,8 +78,11 @@ namespace TMVA { TList* GetStorage() const { return fStorage; } TObject* GetObject(const TString & alias) const; TH1* GetHist(const TString & alias) const; + TH2* GetHist2D(const TString & alias) const; TGraph* GetGraph(const TString & alias) const; virtual Types::EAnalysisType GetAnalysisType() { return Types::kNoAnalysisType; } + //test + Bool_t DoesExist(const TString & alias) const; // delete all stored data void Delete(); diff --git a/tmva/inc/TMVA/ResultsClassification.h b/tmva/inc/TMVA/ResultsClassification.h index 94e90d54d3ad0..49d4e1cdc34a5 100644 --- a/tmva/inc/TMVA/ResultsClassification.h +++ b/tmva/inc/TMVA/ResultsClassification.h @@ -51,7 +51,7 @@ namespace TMVA { public: - ResultsClassification( const DataSetInfo* dsi ); + ResultsClassification( const DataSetInfo* dsi, TString resultsName ); ~ResultsClassification(); // setters diff --git a/tmva/inc/TMVA/ResultsMulticlass.h b/tmva/inc/TMVA/ResultsMulticlass.h index 2061c6b311dd6..a2364488c0d03 100644 --- a/tmva/inc/TMVA/ResultsMulticlass.h +++ b/tmva/inc/TMVA/ResultsMulticlass.h @@ -66,7 +66,7 @@ namespace TMVA { public: - ResultsMulticlass( const DataSetInfo* dsi ); + ResultsMulticlass( const DataSetInfo* dsi, TString resultsName ); ~ResultsMulticlass(); // setters diff --git a/tmva/inc/TMVA/ResultsRegression.h b/tmva/inc/TMVA/ResultsRegression.h index 40aabdb8c8d1f..a8b9495790f4a 100644 --- a/tmva/inc/TMVA/ResultsRegression.h +++ b/tmva/inc/TMVA/ResultsRegression.h @@ -61,7 +61,7 @@ namespace TMVA { public: - ResultsRegression( const DataSetInfo* dsi ); + ResultsRegression( const DataSetInfo* dsi, TString resultsName ); ~ResultsRegression(); // setters diff --git a/tmva/inc/TMVA/Rule.h b/tmva/inc/TMVA/Rule.h index 82685db2604c6..89e8ffb9d89db 100644 --- a/tmva/inc/TMVA/Rule.h +++ b/tmva/inc/TMVA/Rule.h @@ -51,12 +51,12 @@ namespace TMVA { class MsgLogger; class Rule; - ostream& operator<<( ostream& os, const Rule & rule ); + std::ostream& operator<<( std::ostream& os, const Rule & rule ); class Rule { // ouput operator for a Rule - friend ostream& operator<< ( ostream& os, const Rule & rule ); + friend std::ostream& operator<< ( std::ostream& os, const Rule & rule ); public: @@ -155,10 +155,10 @@ namespace TMVA { void PrintLogger( const char *title=0 ) const; // print just the raw info, used for weight file generation - void PrintRaw ( ostream& os ) const; // obsolete + void PrintRaw ( std::ostream& os ) const; // obsolete void* AddXMLTo ( void* parent ) const; - void ReadRaw ( istream& os ); // obsolete + void ReadRaw ( std::istream& os ); // obsolete void ReadFromXML( void* wghtnode ); private: @@ -167,7 +167,7 @@ namespace TMVA { void SetSigma(Double_t v) { fSigma=v; } // print info about the Rule - void Print( ostream& os ) const; + void Print( std::ostream& os ) const; // copy from another rule void Copy( const Rule & other ); diff --git a/tmva/inc/TMVA/RuleEnsemble.h b/tmva/inc/TMVA/RuleEnsemble.h index ccc038208c0e7..8f7af265e4b8b 100644 --- a/tmva/inc/TMVA/RuleEnsemble.h +++ b/tmva/inc/TMVA/RuleEnsemble.h @@ -63,12 +63,12 @@ namespace TMVA { class RuleEnsemble; class MsgLogger; - ostream& operator<<( ostream& os, const RuleEnsemble& event ); + std::ostream& operator<<( std::ostream& os, const RuleEnsemble& event ); class RuleEnsemble { // output operator for a RuleEnsemble - friend ostream& operator<< ( ostream& os, const RuleEnsemble& rules ); + friend std::ostream& operator<< ( std::ostream& os, const RuleEnsemble& rules ); public: @@ -159,7 +159,7 @@ namespace TMVA { void UpdateEventVal(); // fill binary rule respons for all events (or selected subset) - void MakeRuleMap(const std::vector<TMVA::Event *> *events=0, UInt_t ifirst=0, UInt_t ilast=0); + void MakeRuleMap(const std::vector<const TMVA::Event *> *events=0, UInt_t ifirst=0, UInt_t ilast=0); // clear rule map void ClearRuleMap() { fRuleMap.clear(); fRuleMapEvents=0; } @@ -261,7 +261,7 @@ namespace TMVA { const MethodBase* GetMethodBase() const; const RuleFit* GetRuleFit() const { return fRuleFit; } // - const std::vector<TMVA::Event *>* GetTrainingEvents() const; + const std::vector<const TMVA::Event *>* GetTrainingEvents() const; const Event* GetTrainingEvent(UInt_t i) const; const Event* GetEvent() const { return fEvent; } // @@ -320,11 +320,11 @@ namespace TMVA { void Print() const; // print the model in a cryptic way - void PrintRaw ( ostream& os ) const; // obsolete + void PrintRaw ( std::ostream& os ) const; // obsolete void* AddXMLTo ( void* parent ) const; // read the model from input stream - void ReadRaw ( istream& istr ); // obsolete + void ReadRaw ( std::istream& istr ); // obsolete void ReadFromXML( void* wghtnode ); @@ -389,7 +389,7 @@ namespace TMVA { std::vector< std::vector<UInt_t> > fRuleMap; // map of rule responses UInt_t fRuleMapInd0; // start index UInt_t fRuleMapInd1; // last index - const std::vector<TMVA::Event *> *fRuleMapEvents; // pointer to vector of events used + const std::vector<const TMVA::Event *> *fRuleMapEvents; // pointer to vector of events used // const RuleFit* fRuleFit; // pointer to rule fit object diff --git a/tmva/inc/TMVA/RuleFit.h b/tmva/inc/TMVA/RuleFit.h index 7d6f84a3d14ba..a43c93dde9b33 100644 --- a/tmva/inc/TMVA/RuleFit.h +++ b/tmva/inc/TMVA/RuleFit.h @@ -67,7 +67,7 @@ namespace TMVA { void SetMsgType( EMsgType t ); - void SetTrainingEvents( const std::vector<TMVA::Event *> & el ); + void SetTrainingEvents( const std::vector<const TMVA::Event *> & el ); void ReshuffleEvents() { std::random_shuffle(fTrainingEventsRndm.begin(),fTrainingEventsRndm.end()); } @@ -95,7 +95,7 @@ namespace TMVA { Double_t EvalEvent( const Event& e ); // calculate sum of - Double_t CalcWeightSum( const std::vector<TMVA::Event *> *events, UInt_t neve=0 ); + Double_t CalcWeightSum( const std::vector<const TMVA::Event *> *events, UInt_t neve=0 ); // do the fitting of the coefficients void FitCoefficients(); @@ -138,7 +138,7 @@ namespace TMVA { // const Event* GetTrainingEvent(UInt_t i, UInt_t isub) const { return &(fTrainingEvents[fSubsampleEvents[isub]])[i]; } - const std::vector< TMVA::Event * > & GetTrainingEvents() const { return fTrainingEvents; } + const std::vector< const TMVA::Event * > & GetTrainingEvents() const { return fTrainingEvents; } // const std::vector< Int_t > & GetSubsampleEvents() const { return fSubsampleEvents; } // void GetSubsampleEvents(Int_t sub, UInt_t & ibeg, UInt_t & iend) const; @@ -160,8 +160,8 @@ namespace TMVA { // copy method void Copy( const RuleFit & other ); - std::vector<TMVA::Event *> fTrainingEvents; // all training events - std::vector<TMVA::Event *> fTrainingEventsRndm; // idem, but randomly shuffled + std::vector<const TMVA::Event *> fTrainingEvents; // all training events + std::vector<const TMVA::Event *> fTrainingEventsRndm; // idem, but randomly shuffled std::vector<Double_t> fEventWeights; // original weights of the events - follows fTrainingEvents UInt_t fNTreeSample; // number of events in sub sample = frac*neve diff --git a/tmva/inc/TMVA/RuleFitAPI.h b/tmva/inc/TMVA/RuleFitAPI.h index ab2b39ba9e96a..d35266b0fce94 100644 --- a/tmva/inc/TMVA/RuleFitAPI.h +++ b/tmva/inc/TMVA/RuleFitAPI.h @@ -45,6 +45,7 @@ namespace TMVA { class MethodRuleFit; + class RuleFit; class RuleFitAPI { @@ -133,10 +134,10 @@ namespace TMVA { inline Bool_t OpenRFile(TString name, std::ifstream & f); // read/write binary files - inline Bool_t WriteInt(ofstream & f, const Int_t *v, Int_t n=1); - inline Bool_t WriteFloat(ofstream & f, const Float_t *v, Int_t n=1); - inline Int_t ReadInt(ifstream & f, Int_t *v, Int_t n=1) const; - inline Int_t ReadFloat(ifstream & f, Float_t *v, Int_t n=1) const; + inline Bool_t WriteInt(std::ofstream & f, const Int_t *v, Int_t n=1); + inline Bool_t WriteFloat(std::ofstream & f, const Float_t *v, Int_t n=1); + inline Int_t ReadInt(std::ifstream & f, Int_t *v, Int_t n=1) const; + inline Int_t ReadFloat(std::ifstream & f, Float_t *v, Int_t n=1) const; // write rf_go.exe i/o files Bool_t WriteAll(); @@ -261,23 +262,23 @@ Bool_t TMVA::RuleFitAPI::OpenRFile(TString name, std::ifstream & f) } //_______________________________________________________________________ -Bool_t TMVA::RuleFitAPI::WriteInt(ofstream & f, const Int_t *v, Int_t n) +Bool_t TMVA::RuleFitAPI::WriteInt(std::ofstream & f, const Int_t *v, Int_t n) { // write an int if (!f.is_open()) return kFALSE; - return f.write(reinterpret_cast<char const *>(v), n*sizeof(Int_t)); + return (Bool_t)f.write(reinterpret_cast<char const *>(v), n*sizeof(Int_t)); } //_______________________________________________________________________ -Bool_t TMVA::RuleFitAPI::WriteFloat(ofstream & f, const Float_t *v, Int_t n) +Bool_t TMVA::RuleFitAPI::WriteFloat(std::ofstream & f, const Float_t *v, Int_t n) { // write a float if (!f.is_open()) return kFALSE; - return f.write(reinterpret_cast<char const *>(v), n*sizeof(Float_t)); + return (Bool_t)f.write(reinterpret_cast<char const *>(v), n*sizeof(Float_t)); } //_______________________________________________________________________ -Int_t TMVA::RuleFitAPI::ReadInt(ifstream & f, Int_t *v, Int_t n) const +Int_t TMVA::RuleFitAPI::ReadInt(std::ifstream & f, Int_t *v, Int_t n) const { // read an int if (!f.is_open()) return 0; @@ -286,7 +287,7 @@ Int_t TMVA::RuleFitAPI::ReadInt(ifstream & f, Int_t *v, Int_t n) const } //_______________________________________________________________________ -Int_t TMVA::RuleFitAPI::ReadFloat(ifstream & f, Float_t *v, Int_t n) const +Int_t TMVA::RuleFitAPI::ReadFloat(std::ifstream & f, Float_t *v, Int_t n) const { // read a float if (!f.is_open()) return 0; diff --git a/tmva/inc/TMVA/RuleFitParams.h b/tmva/inc/TMVA/RuleFitParams.h index b60c82cf4f8f9..8c2c8de7fd20f 100644 --- a/tmva/inc/TMVA/RuleFitParams.h +++ b/tmva/inc/TMVA/RuleFitParams.h @@ -135,7 +135,7 @@ namespace TMVA { protected: // typedef of an Event const iterator - typedef std::vector<TMVA::Event *>::const_iterator EventItr; + typedef std::vector<const TMVA::Event *>::const_iterator EventItr; // init ntuple void InitNtuple(); diff --git a/tmva/inc/TMVA/SdivSqrtSplusB.h b/tmva/inc/TMVA/SdivSqrtSplusB.h index 94acf7fb2860e..1707619cb96a5 100644 --- a/tmva/inc/TMVA/SdivSqrtSplusB.h +++ b/tmva/inc/TMVA/SdivSqrtSplusB.h @@ -56,6 +56,10 @@ namespace TMVA { //destructor virtual ~SdivSqrtSplusB() {} + // Return the gain in separation of the original sample is splitted in two sub-samples + // (N * Index_parent) - (N_left * Index_left) - (N_right * Index_right) + virtual Double_t GetSeparationGain( const Double_t& nSelS, const Double_t& nSelB, + const Double_t& nTotS, const Double_t& nTotB ); // return the Index (S/sqrt(S+B)) virtual Double_t GetSeparationIndex( const Double_t &s, const Double_t &b ); diff --git a/tmva/inc/TMVA/SeparationBase.h b/tmva/inc/TMVA/SeparationBase.h index deacd3570b062..b7e07717d7c88 100644 --- a/tmva/inc/TMVA/SeparationBase.h +++ b/tmva/inc/TMVA/SeparationBase.h @@ -100,7 +100,7 @@ namespace TMVA { // Return the gain in separation of the original sample is splitted in two sub-samples // (N * Index_parent) - (N_left * Index_left) - (N_right * Index_right) - Double_t GetSeparationGain( const Double_t& nSelS, const Double_t& nSelB, + virtual Double_t GetSeparationGain( const Double_t& nSelS, const Double_t& nSelB, const Double_t& nTotS, const Double_t& nTotB ); // Return the separation index (a measure for "purity" of the sample") diff --git a/tmva/inc/TMVA/Tools.h b/tmva/inc/TMVA/Tools.h index 6a44e33c35eca..08f246860981e 100644 --- a/tmva/inc/TMVA/Tools.h +++ b/tmva/inc/TMVA/Tools.h @@ -100,6 +100,14 @@ namespace TMVA { static Tools& Instance(); static void DestroyInstance(); + + template <typename T> Double_t Mean(Long64_t n, const T *a, const Double_t *w=0); + template <typename Iterator, typename WeightIterator> Double_t Mean ( Iterator first, Iterator last, WeightIterator w); + + template <typename T> Double_t RMS(Long64_t n, const T *a, const Double_t *w=0); + template <typename Iterator, typename WeightIterator> Double_t RMS(Iterator first, Iterator last, WeightIterator w); + + // simple statistics operations on tree entries void ComputeStat( const std::vector<TMVA::Event*>&, std::vector<Float_t>*, @@ -131,6 +139,7 @@ namespace TMVA { // returns the covariance matrix of of the different classes (and the sum) // given the event sample std::vector<TMatrixDSym*>* CalcCovarianceMatrices( const std::vector<Event*>& events, Int_t maxCls, VariableTransformBase* transformBase=0 ); + std::vector<TMatrixDSym*>* CalcCovarianceMatrices( const std::vector<const Event*>& events, Int_t maxCls, VariableTransformBase* transformBase=0 ); // turns covariance into correlation matrix @@ -174,8 +183,8 @@ namespace TMVA { void FormattedOutput( const TMatrixD&, const std::vector<TString>& vert, const std::vector<TString>& horiz, MsgLogger& logger ); - void WriteFloatArbitraryPrecision( Float_t val, ostream& os ); - void ReadFloatArbitraryPrecision ( Float_t& val, istream& is ); + void WriteFloatArbitraryPrecision( Float_t val, std::ostream& os ); + void ReadFloatArbitraryPrecision ( Float_t& val, std::istream& is ); // for histogramming TString GetXTitleWithUnit( const TString& title, const TString& unit ); @@ -259,6 +268,7 @@ namespace TMVA { const char* GetName ( void* node ); TXMLEngine& xmlengine() { return *fXMLEngine; } + int xmlenginebuffersize() { return 10000000; } TXMLEngine* fXMLEngine; private: @@ -304,5 +314,6 @@ inline Double_t TMVA::Tools::ComputeVariance( Double_t sumx2, Double_t sumx, Int } + #endif diff --git a/tmva/inc/TMVA/TransformationHandler.h b/tmva/inc/TMVA/TransformationHandler.h index 3239fc955d7d1..09d84e1b794b5 100644 --- a/tmva/inc/TMVA/TransformationHandler.h +++ b/tmva/inc/TMVA/TransformationHandler.h @@ -83,7 +83,7 @@ namespace TMVA { VariableTransformBase* AddTransformation(VariableTransformBase*, Int_t cls ); const TList& GetTransformationList() const { return fTransformations; } Int_t GetNumOfTransformations() const { return fTransformations.GetSize(); } - std::vector<Event*>* CalcTransformations( const std::vector<Event*>&, Bool_t createNewVector = kFALSE ); + const std::vector<Event*>* CalcTransformations( const std::vector<Event*>&, Bool_t createNewVector = kFALSE ); void CalcStats( const std::vector<Event*>& events ); void AddStats ( Int_t k, UInt_t ivar, Double_t mean, Double_t rms, Double_t min, Double_t max ); diff --git a/tmva/inc/TMVA/Types.h b/tmva/inc/TMVA/Types.h index 6c6aa348bb8a3..cb5f45ce67039 100644 --- a/tmva/inc/TMVA/Types.h +++ b/tmva/inc/TMVA/Types.h @@ -87,7 +87,6 @@ namespace TMVA { kMLP , kBayesClassifier, kFDA , - kCommittee , kBoost , kPDEFoam , kLD , @@ -128,9 +127,9 @@ namespace TMVA { enum ETreeType { kTraining = 0, kTesting, - kMaxTreeType, - kValidation, - kTrainingOriginal + kMaxTreeType, // also used as temporary storage for trees not yet assigned for testing;training... + kValidation, // these are placeholders... currently not used, but could be moved "forward" if + kTrainingOriginal // ever needed }; enum EBoostStage { @@ -138,7 +137,6 @@ namespace TMVA { kBeforeTraining, kBeforeBoosting, kAfterBoosting, - kBoostValidation, kBoostProcEnd }; diff --git a/tmva/inc/TMVA/VariableDecorrTransform.h b/tmva/inc/TMVA/VariableDecorrTransform.h index c7bebe3b68410..60bed3cd9dfa2 100644 --- a/tmva/inc/TMVA/VariableDecorrTransform.h +++ b/tmva/inc/TMVA/VariableDecorrTransform.h @@ -58,7 +58,7 @@ namespace TMVA { virtual ~VariableDecorrTransform( void ); void Initialize(); - Bool_t PrepareTransformation( const std::vector<Event*>& ); + Bool_t PrepareTransformation (const std::vector<Event*>&); // virtual const Event* Transform(const Event* const, Types::ESBType type = Types::kMaxSBType) const; virtual const Event* Transform(const Event* const, Int_t cls ) const; @@ -70,7 +70,7 @@ namespace TMVA { virtual void AttachXMLTo(void* parent); virtual void ReadFromXML( void* trfnode ); - virtual void PrintTransformation( ostream & o ); + virtual void PrintTransformation( std::ostream & o ); // writer of function code virtual void MakeFunction( std::ostream& fout, const TString& fncName, Int_t part, UInt_t trCounter, Int_t cls ); @@ -83,8 +83,8 @@ namespace TMVA { // mutable Event* fTransformedEvent; //! local event copy std::vector<TMatrixD*> fDecorrMatrices; //! Decorrelation matrix [class0/class1/.../all classes] - void CalcSQRMats( const std::vector<Event*>&, Int_t maxCls ); - std::vector<TMatrixDSym*>* CalcCovarianceMatrices( const std::vector<Event*>& events, Int_t maxCls ); + void CalcSQRMats( const std::vector< Event*>&, Int_t maxCls ); + std::vector<TMatrixDSym*>* CalcCovarianceMatrices( const std::vector<const Event*>& events, Int_t maxCls ); ClassDef(VariableDecorrTransform,0) // Variable transformation: decorrelation }; diff --git a/tmva/inc/TMVA/VariableGaussTransform.h b/tmva/inc/TMVA/VariableGaussTransform.h index 2c70a561c588a..c4e4e9028ad96 100644 --- a/tmva/inc/TMVA/VariableGaussTransform.h +++ b/tmva/inc/TMVA/VariableGaussTransform.h @@ -91,7 +91,7 @@ namespace TMVA { virtual ~VariableGaussTransform( void ); void Initialize(); - Bool_t PrepareTransformation( const std::vector<Event*>& ); + Bool_t PrepareTransformation (const std::vector<Event*>&); virtual const Event* Transform(const Event* const, Int_t cls ) const; virtual const Event* InverseTransform(const Event* const, Int_t cls ) const; @@ -102,7 +102,7 @@ namespace TMVA { virtual void AttachXMLTo(void* parent); virtual void ReadFromXML( void* trfnode ); - virtual void PrintTransformation( ostream & o ); + virtual void PrintTransformation( std::ostream & o ); // writer of function code virtual void MakeFunction( std::ostream& fout, const TString& fncName, Int_t part, UInt_t trCounter, Int_t cls ); diff --git a/tmva/inc/TMVA/VariableIdentityTransform.h b/tmva/inc/TMVA/VariableIdentityTransform.h index 1d86347c9ae07..7ccd7a2829869 100644 --- a/tmva/inc/TMVA/VariableIdentityTransform.h +++ b/tmva/inc/TMVA/VariableIdentityTransform.h @@ -50,7 +50,7 @@ namespace TMVA { virtual ~VariableIdentityTransform( void ) {} void Initialize(); - Bool_t PrepareTransformation( const std::vector<Event*>& ); + Bool_t PrepareTransformation (const std::vector<Event*>& ); void WriteTransformationToStream ( std::ostream& ) const {} void ReadTransformationFromStream( std::istream&, const TString& ) { SetCreated(); } diff --git a/tmva/inc/TMVA/VariableNormalizeTransform.h b/tmva/inc/TMVA/VariableNormalizeTransform.h index ea0d6eb42d740..8289a4e043e2a 100644 --- a/tmva/inc/TMVA/VariableNormalizeTransform.h +++ b/tmva/inc/TMVA/VariableNormalizeTransform.h @@ -57,7 +57,7 @@ namespace TMVA { virtual ~VariableNormalizeTransform( void ); void Initialize(); - Bool_t PrepareTransformation( const std::vector<Event*>& ); + Bool_t PrepareTransformation (const std::vector<Event*>&); virtual const Event* Transform(const Event* const, Int_t cls ) const; virtual const Event* InverseTransform( const Event* const, Int_t cls ) const; @@ -69,7 +69,7 @@ namespace TMVA { virtual void AttachXMLTo(void* parent); virtual void ReadFromXML( void* trfnode ); - virtual void PrintTransformation( ostream & o ); + virtual void PrintTransformation( std::ostream & o ); // writer of function code virtual void MakeFunction( std::ostream& fout, const TString& fncName, Int_t part, UInt_t trCounter, Int_t cls ); @@ -79,7 +79,7 @@ namespace TMVA { private: - void CalcNormalizationParams( const std::vector<Event*>& events); + void CalcNormalizationParams( const std::vector< Event*>& events); // mutable Event* fTransformedEvent; diff --git a/tmva/inc/TMVA/VariablePCATransform.h b/tmva/inc/TMVA/VariablePCATransform.h index 76e7a7d6a5dce..204a7411122aa 100644 --- a/tmva/inc/TMVA/VariablePCATransform.h +++ b/tmva/inc/TMVA/VariablePCATransform.h @@ -55,7 +55,7 @@ namespace TMVA { virtual ~VariablePCATransform( void ); void Initialize(); - Bool_t PrepareTransformation( const std::vector<Event*>& ); + Bool_t PrepareTransformation (const std::vector<Event*>&); virtual const Event* Transform(const Event* const, Int_t cls ) const; virtual const Event* InverseTransform(const Event* const, Int_t cls ) const; @@ -71,7 +71,7 @@ namespace TMVA { private: - void CalculatePrincipalComponents( const std::vector<Event*>& ); + void CalculatePrincipalComponents( const std::vector< Event*>& ); void X2P( std::vector<Float_t>&, const std::vector<Float_t>&, Int_t cls ) const; void P2X( std::vector<Float_t>&, const std::vector<Float_t>&, Int_t cls ) const; diff --git a/tmva/inc/TMVA/VariableRearrangeTransform.h b/tmva/inc/TMVA/VariableRearrangeTransform.h index 12b65d8bf7678..04c484e6c2cdf 100644 --- a/tmva/inc/TMVA/VariableRearrangeTransform.h +++ b/tmva/inc/TMVA/VariableRearrangeTransform.h @@ -50,7 +50,7 @@ namespace TMVA { virtual ~VariableRearrangeTransform( void ); void Initialize(); - Bool_t PrepareTransformation( const std::vector<Event*>& ); + Bool_t PrepareTransformation (const std::vector<Event*>&); virtual const Event* Transform(const Event* const, Int_t cls ) const; virtual const Event* InverseTransform( const Event* const, Int_t cls ) const; @@ -61,7 +61,7 @@ namespace TMVA { virtual void AttachXMLTo(void* parent); virtual void ReadFromXML( void* trfnode ); - virtual void PrintTransformation( ostream & o ); + virtual void PrintTransformation( std::ostream & o ); // writer of function code virtual void MakeFunction( std::ostream& fout, const TString& fncName, Int_t part, UInt_t trCounter, Int_t cls ); diff --git a/tmva/inc/TMVA/VariableTransformBase.h b/tmva/inc/TMVA/VariableTransformBase.h index 8c5c0fc00f587..c0a44bea75295 100644 --- a/tmva/inc/TMVA/VariableTransformBase.h +++ b/tmva/inc/TMVA/VariableTransformBase.h @@ -76,7 +76,7 @@ namespace TMVA { virtual ~VariableTransformBase( void ); virtual void Initialize() = 0; - virtual Bool_t PrepareTransformation( const std::vector<Event*>& ) = 0; + virtual Bool_t PrepareTransformation (const std::vector<Event*>& ) = 0; virtual const Event* Transform ( const Event* const, Int_t cls ) const = 0; virtual const Event* InverseTransform( const Event* const, Int_t cls ) const = 0; @@ -118,7 +118,7 @@ namespace TMVA { // provides string vector giving explicit transformation virtual std::vector<TString>* GetTransformationStrings( Int_t cls ) const; - virtual void PrintTransformation( ostream & ) {} + virtual void PrintTransformation( std::ostream & ) {} const std::vector<TMVA::VariableInfo>& Variables() const { return fVariables; } const std::vector<TMVA::VariableInfo>& Targets() const { return fTargets; } @@ -130,7 +130,7 @@ namespace TMVA { protected: - void CalcNorm( const std::vector<Event*>& ); + void CalcNorm( const std::vector<const Event*>& ); void SetCreated( Bool_t c = kTRUE ) { fCreated = c; } void SetNVariables( UInt_t i ) { fNVars = i; } diff --git a/tmva/inc/TMVA/Version.h b/tmva/inc/TMVA/Version.h index aec77111fdca0..cb3ab64d7c999 100644 --- a/tmva/inc/TMVA/Version.h +++ b/tmva/inc/TMVA/Version.h @@ -41,10 +41,10 @@ // // ////////////////////////////////////////////////////////////////////////// -#define TMVA_RELEASE "4.1.3" -#define TMVA_RELEASE_DATE "May 04, 2012" -#define TMVA_RELEASE_TIME "15:00:00" -#define TMVA_VERSION_CODE 262403 +#define TMVA_RELEASE "4.2.0" +#define TMVA_RELEASE_DATE "Sep 19, 2013" +#define TMVA_RELEASE_TIME "14:25:28" +#define TMVA_VERSION_CODE 262656 #define TMVA_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c)) #endif diff --git a/tmva/src/BinarySearchTree.cxx b/tmva/src/BinarySearchTree.cxx index 5c831dcc1091a..de214491444ff 100644 --- a/tmva/src/BinarySearchTree.cxx +++ b/tmva/src/BinarySearchTree.cxx @@ -63,9 +63,6 @@ #ifndef ROOT_TMVA_Tools #include "TMVA/Tools.h" #endif -#ifndef ROOT_TMVA_DataSet -#include "TMVA/DataSet.h" -#endif #ifndef ROOT_TMVA_Event #include "TMVA/Event.h" #endif @@ -332,13 +329,13 @@ void TMVA::BinarySearchTree::NormalizeTree ( std::vector< std::pair<Double_t, co Insert( mid->second ); - // Print(cout); - // cout << endl << endl; + // Print(std::cout); + // std::cout << std::endl << std::endl; NormalizeTree( leftBound, mid, actDim+1 ); mid++; - // Print(cout); - // cout << endl << endl; + // Print(std::cout); + // std::cout << std::endl << std::endl; NormalizeTree( mid, rightBound, actDim+1 ); diff --git a/tmva/src/BinarySearchTreeNode.cxx b/tmva/src/BinarySearchTreeNode.cxx index 18a6418033620..8070dd9249c8e 100644 --- a/tmva/src/BinarySearchTreeNode.cxx +++ b/tmva/src/BinarySearchTreeNode.cxx @@ -135,7 +135,7 @@ Bool_t TMVA::BinarySearchTreeNode::EqualsMe(const TMVA::Event& e) const } //_______________________________________________________________________ -void TMVA::BinarySearchTreeNode::Print( ostream& os ) const +void TMVA::BinarySearchTreeNode::Print( std::ostream& os ) const { // print the node os << "< *** " << std::endl << " node.Data: "; @@ -155,7 +155,7 @@ void TMVA::BinarySearchTreeNode::Print( ostream& os ) const } //_______________________________________________________________________ -void TMVA::BinarySearchTreeNode::PrintRec( ostream& os ) const +void TMVA::BinarySearchTreeNode::PrintRec( std::ostream& os ) const { // recursively print the node and its daughters (--> print the 'tree') os << this->GetDepth() << " " << this->GetPos() << " " << this->GetSelector() @@ -171,7 +171,7 @@ void TMVA::BinarySearchTreeNode::PrintRec( ostream& os ) const } //_______________________________________________________________________ -Bool_t TMVA::BinarySearchTreeNode::ReadDataRecord( istream& is, UInt_t /* Tmva_Version_Code */ ) +Bool_t TMVA::BinarySearchTreeNode::ReadDataRecord( std::istream& is, UInt_t /* Tmva_Version_Code */ ) { // Read the data block Int_t itmp; diff --git a/tmva/src/BinaryTree.cxx b/tmva/src/BinaryTree.cxx index f48df664ad2fd..4b3b7d2d5e27b 100644 --- a/tmva/src/BinaryTree.cxx +++ b/tmva/src/BinaryTree.cxx @@ -115,7 +115,7 @@ UInt_t TMVA::BinaryTree::CountNodes(TMVA::Node *n) } //_______________________________________________________________________ -void TMVA::BinaryTree::Print(ostream & os) const +void TMVA::BinaryTree::Print(std::ostream & os) const { // recursively print the tree this->GetRoot()->PrintRec(os); @@ -147,7 +147,7 @@ void TMVA::BinaryTree::ReadXML(void* node, UInt_t tmva_Version_Code ) { //_______________________________________________________________________ -ostream& TMVA::operator<< (ostream& os, const TMVA::BinaryTree& tree) +std::ostream& TMVA::operator<< (std::ostream& os, const TMVA::BinaryTree& tree) { // print the tree recursinvely using the << operator tree.Print(os); @@ -155,7 +155,7 @@ ostream& TMVA::operator<< (ostream& os, const TMVA::BinaryTree& tree) } //_______________________________________________________________________ -void TMVA::BinaryTree::Read(istream & istr, UInt_t tmva_Version_Code ) +void TMVA::BinaryTree::Read(std::istream & istr, UInt_t tmva_Version_Code ) { // Read the binary tree from an input stream. // The input stream format depends on the tree type, @@ -192,9 +192,9 @@ void TMVA::BinaryTree::Read(istream & istr, UInt_t tmva_Version_Code ) } //_______________________________________________________________________ -istream& TMVA::operator>> (istream& istr, TMVA::BinaryTree& tree) +std::istream& TMVA::operator>> (std::istream& istr, TMVA::BinaryTree& tree) { - // read the tree from an istream + // read the tree from an std::istream tree.Read(istr); return istr; } diff --git a/tmva/src/CCPruner.cxx b/tmva/src/CCPruner.cxx index 4a857a00b171d..0948d954968de 100644 --- a/tmva/src/CCPruner.cxx +++ b/tmva/src/CCPruner.cxx @@ -24,6 +24,7 @@ #include "TMVA/GiniIndex.h" #include "TMVA/MisClassificationError.h" #include "TMVA/CCTreeWrapper.h" +#include "TMVA/DataSet.h" #include <iostream> #include <fstream> @@ -98,7 +99,7 @@ void CCPruner::Optimize( ) Double_t epsilon = std::numeric_limits<double>::epsilon(); Double_t alpha = -1.0e10; - ofstream outfile; + std::ofstream outfile; if (fDebug) outfile.open("costcomplexity.log"); if(!HaveStopCondition && (fValidationSample == NULL && fValidationDataSet == NULL) ) { if (fDebug) outfile << "ERROR: no validation sample, so cannot optimize pruning!" << std::endl; diff --git a/tmva/src/CCTreeWrapper.cxx b/tmva/src/CCTreeWrapper.cxx index c712a03bdf26f..dd2ee4d3b7e60 100644 --- a/tmva/src/CCTreeWrapper.cxx +++ b/tmva/src/CCTreeWrapper.cxx @@ -69,7 +69,7 @@ Bool_t TMVA::CCTreeWrapper::CCTreeNode::ReadDataRecord( std::istream& in, UInt_t } //_______________________________________________________________________ -void TMVA::CCTreeWrapper::CCTreeNode::Print( ostream& os ) const { +void TMVA::CCTreeWrapper::CCTreeNode::Print( std::ostream& os ) const { // printout of the node (can be read in with ReadDataRecord) os << "----------------------" << std::endl @@ -81,7 +81,7 @@ void TMVA::CCTreeWrapper::CCTreeNode::Print( ostream& os ) const { } //_______________________________________________________________________ -void TMVA::CCTreeWrapper::CCTreeNode::PrintRec( ostream& os ) const { +void TMVA::CCTreeWrapper::CCTreeNode::PrintRec( std::ostream& os ) const { // recursive printout of the node and its daughters this->Print(os); @@ -198,7 +198,7 @@ Double_t TMVA::CCTreeWrapper::TestTreeQuality( const DataSet* validationSample ) // test the tree quality.. in terms of Miscalssification Double_t ncorrect=0, nfalse=0; for (Long64_t ievt=0; ievt<validationSample->GetNEvents(); ievt++){ - Event *ev = validationSample->GetEvent(ievt); + const Event *ev = validationSample->GetEvent(ievt); Bool_t isSignalType = (CheckEvent(*ev) > fDTParent->GetNodePurityLimit() ) ? 1 : 0; diff --git a/tmva/src/Configurable.cxx b/tmva/src/Configurable.cxx index 81b59e017ff62..c53a7041b4206 100644 --- a/tmva/src/Configurable.cxx +++ b/tmva/src/Configurable.cxx @@ -315,7 +315,7 @@ void TMVA::Configurable::PrintOptions() const } //______________________________________________________________________ -void TMVA::Configurable::WriteOptionsToStream( ostream& o, const TString& prefix ) const +void TMVA::Configurable::WriteOptionsToStream( std::ostream& o, const TString& prefix ) const { // write options to output stream (e.g. in writing the MVA weight files @@ -415,7 +415,7 @@ void TMVA::Configurable::WriteOptionsReferenceToFile() } //______________________________________________________________________ -void TMVA::Configurable::ReadOptionsFromStream(istream& istr) +void TMVA::Configurable::ReadOptionsFromStream(std::istream& istr) { // read option back from the weight file @@ -444,3 +444,4 @@ void TMVA::Configurable::ReadOptionsFromStream(istream& istr) istr.getline(buf,512); // reading the next line } } + diff --git a/tmva/src/DataInputHandler.cxx b/tmva/src/DataInputHandler.cxx index 384ed942516dc..80c0105ff6dad 100644 --- a/tmva/src/DataInputHandler.cxx +++ b/tmva/src/DataInputHandler.cxx @@ -60,7 +60,7 @@ void TMVA::DataInputHandler::AddTree( const TString& fn, const TCut& cut, Types::ETreeType tt ) { - // add a signal tree to the dataset to be used as input + // add a *className* tree to the dataset to be used as input TTree * tr = ReadInputTree(fn); tr->SetName( TString("Tree")+className ); AddTree( tr, className, weight, cut, tt ); @@ -73,6 +73,8 @@ void TMVA::DataInputHandler::AddTree( TTree* tree, const TCut& cut, Types::ETreeType tt ) { + // add tree of *className* events for tt (Training;Testing..) type as input .. + if (!tree) Log() << kFATAL << "Zero pointer for tree of class " << className.Data() << Endl; if (tree->GetEntries()==0) Log() << kFATAL << "Encountered empty TTree or TChain of class " << className.Data() << Endl; if (fInputTrees[className.Data()].empty()) { @@ -101,12 +103,14 @@ void TMVA::DataInputHandler::AddTree( TTree* tree, //_______________________________________________________________________ void TMVA::DataInputHandler::AddSignalTree( TTree* tr, Double_t weight, Types::ETreeType tt ) { + // add a signal tree to the dataset to be used as input AddTree( tr, "Signal", weight, "", tt ); } //_______________________________________________________________________ void TMVA::DataInputHandler::AddBackgroundTree( TTree* tr, Double_t weight, Types::ETreeType tt ) { + // add a background tree to the dataset to be used as input AddTree( tr, "Background", weight, "", tt ); } @@ -133,8 +137,8 @@ TTree* TMVA::DataInputHandler::ReadInputTree( const TString& dataFile ) { // create trees from these ascii files TTree* tr = new TTree( "tmp", dataFile ); - - ifstream in(dataFile); + std::ifstream in(dataFile); + tr->SetDirectory(0); Log() << kWARNING << "Watch out, I (Helge) made the Tree not associated to the current directory .. Hopefully that does not have unwanted consequences" << Endl; if (!in.good()) Log() << kFATAL << "Could not open file: " << dataFile << Endl; in.close(); diff --git a/tmva/src/DataSet.cxx b/tmva/src/DataSet.cxx index 7dcb046827810..ea1aced165c09 100644 --- a/tmva/src/DataSet.cxx +++ b/tmva/src/DataSet.cxx @@ -66,7 +66,7 @@ TMVA::DataSet::DataSet(const DataSetInfo& dsi) fTrainingBlockSize(0) { // constructor - for (UInt_t i=0; i<4; i++) fEventCollection[i] = new std::vector<Event*>(); + for (UInt_t i=0; i<4; i++) fEventCollection[i] = new std::vector<Event*>; fClassEvents.resize(4); fBlockBelongToTraining.reserve(10); @@ -171,7 +171,7 @@ void TMVA::DataSet::DestroyCollection(Types::ETreeType type, Bool_t deleteEvents } //_______________________________________________________________________ -TMVA::Event* TMVA::DataSet::GetEvent() const +const TMVA::Event* TMVA::DataSet::GetEvent() const { if (fSampling.size() > UInt_t(fCurrentTreeIdx) && fSampling.at(fCurrentTreeIdx)) { Long64_t iEvt = fSamplingSelected.at(fCurrentTreeIdx).at( fCurrentEventIdx )->second; @@ -265,16 +265,16 @@ TMVA::Results* TMVA::DataSet::GetResults( const TString & resultsName, Results * newresults = 0; switch(analysistype) { case Types::kClassification: - newresults = new ResultsClassification(&fdsi); + newresults = new ResultsClassification(&fdsi,resultsName); break; case Types::kRegression: - newresults = new ResultsRegression(&fdsi); + newresults = new ResultsRegression(&fdsi,resultsName); break; case Types::kMulticlass: - newresults = new ResultsMulticlass(&fdsi); + newresults = new ResultsMulticlass(&fdsi,resultsName); break; case Types::kNoAnalysisType: - newresults = new ResultsClassification(&fdsi); + newresults = new ResultsClassification(&fdsi,resultsName); break; case Types::kMaxAnalysisType: //Log() << kINFO << " GetResults("<<info<<") can't create new one." << Endl; @@ -670,7 +670,6 @@ TTree* TMVA::DataSet::GetTree( Types::ETreeType type ) for (Long64_t iEvt = 0; iEvt < GetNEvents( type ); iEvt++) { // write the event-variables const Event* ev = GetEvent( iEvt ); - // write the classnumber and the classname cls = ev->GetClass(); weight = ev->GetWeight(); @@ -690,8 +689,8 @@ TTree* TMVA::DataSet::GetTree( Types::ETreeType type ) n=0; for (std::map<TString, Results*>::iterator itMethod = fResults.at(t).begin(); itMethod != fResults.at(t).end(); itMethod++) { - Results* results = itMethod->second; + const std::vector< Float_t >& vals = results->operator[](iEvt); if (itMethod->second->GetAnalysisType() == Types::kClassification) { diff --git a/tmva/src/DataSetFactory.cxx b/tmva/src/DataSetFactory.cxx index 2dfdaf7844ef0..3de8b86fe7496 100644 --- a/tmva/src/DataSetFactory.cxx +++ b/tmva/src/DataSetFactory.cxx @@ -98,6 +98,7 @@ namespace TMVA { TMVA::DataSetFactory::DataSetFactory() : fVerbose(kFALSE), fVerboseLevel(TString("Info")), + fScaleWithPreselEff(0), fCurrentTree(0), fCurrentEvtIdx(0), fInputFormulas(0), @@ -140,7 +141,8 @@ TMVA::DataSet* TMVA::DataSetFactory::CreateDataSet( TMVA::DataSetInfo& dsi, dsi.PrintCorrelationMatrix( className ); } Log() << kINFO << " " << Endl; - } + } + return ds; } @@ -259,10 +261,21 @@ Bool_t TMVA::DataSetFactory::CheckTTreeFormula( TTreeFormula* ttf, << " 0 is taken as an alternative." << Endl; worked = kFALSE; } - if( expression.Contains("$") ) hasDollar = kTRUE; + if( expression.Contains("$") ) + hasDollar = kTRUE; + else + { + for (int i = 0, iEnd = ttf->GetNcodes (); i < iEnd; ++i) + { + TLeaf* leaf = ttf->GetLeaf (i); + if (!leaf->IsOnTerminalBranch()) + hasDollar = kTRUE; + } + } return worked; } + //_______________________________________________________________________ void TMVA::DataSetFactory::ChangeToNewTree( TreeInfo& tinfo, const DataSetInfo & dsi ) { @@ -437,7 +450,7 @@ void TMVA::DataSetFactory::CalcMinMax( DataSet* ds, TMVA::DataSetInfo& dsi ) // perform event loop for (Int_t i=0; i<ds->GetNEvents(); i++) { - Event * ev = ds->GetEvent(i); + const Event * ev = ds->GetEvent(i); for (UInt_t ivar=0; ivar<nvar; ivar++) { Double_t v = ev->GetValue(ivar); if (v<min[ivar]) min[ivar] = v; @@ -536,7 +549,7 @@ TMatrixD* TMVA::DataSetFactory::CalcCovarianceMatrix( DataSet * ds, const UInt_t Double_t ic = 0; for (Int_t i=0; i<ds->GetNEvents(); i++) { - Event * ev = ds->GetEvent(i); + const Event * ev = ds->GetEvent(i); if (ev->GetClass() != classNumber ) continue; Double_t weight = ev->GetWeight(); @@ -606,13 +619,15 @@ TMVA::DataSetFactory::InitOptions( TMVA::DataSetInfo& dsi, splitSpecs.DeclareOptionRef( splitSeed, "SplitSeed", "Seed for random event shuffling" ); - normMode = "NumEvents"; // the weight normalisation modes + normMode = "EqualNumEvents"; // the weight normalisation modes splitSpecs.DeclareOptionRef( normMode, "NormMode", - "Overall renormalisation of event-by-event weights (NumEvents: average weight of 1 per event, independently for signal and background; EqualNumEvents: average weight of 1 per event for signal, and sum of weights for background equal to sum of weights for signal)" ); + "Overall renormalisation of event-by-event weights used in the training (NumEvents: average weight of 1 per event, independently for signal and background; EqualNumEvents: average weight of 1 per event for signal, and sum of weights for background equal to sum of weights for signal)" ); splitSpecs.AddPreDefVal(TString("None")); splitSpecs.AddPreDefVal(TString("NumEvents")); splitSpecs.AddPreDefVal(TString("EqualNumEvents")); + splitSpecs.DeclareOptionRef(fScaleWithPreselEff=kFALSE,"ScaleWithPreselEff","Scale the number of requested events by the eff. of the preselection cuts (or not)" ); + // the number of events // fill in the numbers @@ -893,7 +908,11 @@ TMVA::DataSetFactory::BuildEventVector( TMVA::DataSetInfo& dsi, << std::setw(5) << dataInput.GetEntries(dsi.GetClassInfo(cl)->GetName()) << Endl; } - Log() << kINFO << "Preselection: (will effect number of requested training and testing events)" << Endl; + if (fScaleWithPreselEff) + Log() << kINFO << "Preselection: (will affect number of requested training and testing events)" << Endl; + else + Log() << kINFO << "Preselection: (will NOT affect number of requested training and testing events)" << Endl; + if (dsi.HasCuts()) { for (UInt_t cl = 0; cl< dsi.GetNClasses(); cl++) { Log() << kINFO << " " << setiosflags(ios::left) << std::setw(maxL) << dsi.GetClassInfo(cl)->GetName() @@ -969,8 +988,17 @@ TMVA::DataSetFactory::MixEvents( DataSetInfo& dsi, Int_t availableTesting = eventVectorTesting.size(); Int_t availableUndefined = eventVectorUndefined.size(); - Float_t presel_scale = eventCounts[cls].cutScaling(); + Float_t presel_scale; + if (fScaleWithPreselEff) { + presel_scale = eventCounts[cls].cutScaling(); + if (presel_scale < 1) + Log() << kINFO << " you have opted for scaling the number of requested training/testing events\n to be scaled by the preselection efficiency"<< Endl; + }else{ + presel_scale = 1.; // this scaling was tooo confusing to most people, including me! Sorry... (Helge) + if (eventCounts[cls].cutScaling() < 1) + Log() << kINFO << " you have opted for interpreting the requested number of training/testing events\n to be the number of events AFTER your preselection cuts" << Endl; + } Int_t requestedTraining = Int_t(eventCounts[cls].nTrainingEventsRequested * presel_scale); Int_t requestedTesting = Int_t(eventCounts[cls].nTestingEventsRequested * presel_scale); @@ -978,6 +1006,7 @@ TMVA::DataSetFactory::MixEvents( DataSetInfo& dsi, Log() << kDEBUG << "events in testing trees : " << availableTesting << Endl; Log() << kDEBUG << "events in unspecified trees : " << availableUndefined << Endl; Log() << kDEBUG << "requested for training : " << requestedTraining; + if(presel_scale<1) Log() << " ( " << eventCounts[cls].nTrainingEventsRequested << " * " << presel_scale << " preselection efficiency)" << Endl; @@ -1103,9 +1132,6 @@ TMVA::DataSetFactory::MixEvents( DataSetInfo& dsi, - - - // associate undefined events if( splitMode == "ALTERNATE" ){ Log() << kDEBUG << "split 'ALTERNATE'" << Endl; @@ -1149,6 +1175,7 @@ TMVA::DataSetFactory::MixEvents( DataSetInfo& dsi, } } eventVectorUndefined.clear(); + // finally shorten the event vectors to the requested size by removing random events if (splitMode.Contains( "RANDOM" )){ UInt_t sizeTraining = eventVectorTraining.size(); @@ -1328,6 +1355,15 @@ TMVA::DataSetFactory::MixEvents( DataSetInfo& dsi, Log() << kINFO << "Create internal testing tree" << Endl; ds->SetEventCollection(testingEventVector, Types::kTesting ); + + if (ds->GetNTrainingEvents() < 1){ + Log() << kFATAL << "Dataset " << std::string(dsi.GetName()) << " does not have any training events, I better stop here and let you fix that one first " << Endl; + } + + if (ds->GetNTestEvents() < 1) { + Log() << kERROR << "Dataset " << std::string(dsi.GetName()) << " does not have any testing events, guess that will cause problems later..but for now, I continue " << Endl; + } + return ds; @@ -1340,18 +1376,18 @@ TMVA::DataSetFactory::RenormEvents( TMVA::DataSetInfo& dsi, const EvtStatsPerClass& eventCounts, const TString& normMode ) { - // ============================================================ - // renormalisation - // ============================================================ + // ============================================================================= + // renormalisation of the TRAINING event weights + // -none (kind of obvious) .. use the weights as supplied by the + // user.. (we store however the relative weight for later use) + // -numEvents + // -equalNumEvents reweight the training events such that the sum of all + // backgr. (class > 0) weights equal that of the signal (class 0) + // ============================================================================= // print rescaling info - if (normMode == "NONE") { - Log() << kINFO << "No weight renormalisation applied: use original event weights" << Endl; - return; - } - // --------------------------------- // compute sizes and sums of weights Int_t trainingSize = 0; @@ -1363,8 +1399,12 @@ TMVA::DataSetFactory::RenormEvents( TMVA::DataSetInfo& dsi, NumberPerClass trainingSizePerClass( dsi.GetNClasses() ); NumberPerClass testingSizePerClass( dsi.GetNClasses() ); - Double_t trainingSumWeights = 0; - Double_t testingSumWeights = 0; + Double_t trainingSumSignalWeights = 0; + Double_t trainingSumBackgrWeights = 0; // Backgr. includes all clasess that are not signal + Double_t testingSumSignalWeights = 0; + Double_t testingSumBackgrWeights = 0; // Backgr. includes all clasess that are not signal + + for( UInt_t cls = 0, clsEnd = dsi.GetNClasses(); cls < clsEnd; ++cls ){ trainingSizePerClass.at(cls) = tmpEventVector[Types::kTraining].at(cls).size(); @@ -1399,9 +1439,13 @@ TMVA::DataSetFactory::RenormEvents( TMVA::DataSetInfo& dsi, null<Double_t>(), std::mem_fun(&TMVA::Event::GetOriginalWeight) ) ); - - trainingSumWeights += trainingSumWeightsPerClass.at(cls); - testingSumWeights += testingSumWeightsPerClass.at(cls); + if ( cls == dsi.GetSignalClassIndex()){ + trainingSumSignalWeights += trainingSumWeightsPerClass.at(cls); + testingSumSignalWeights += testingSumWeightsPerClass.at(cls); + }else{ + trainingSumBackgrWeights += trainingSumWeightsPerClass.at(cls); + testingSumBackgrWeights += testingSumWeightsPerClass.at(cls); + } } // --------------------------------- @@ -1409,87 +1453,117 @@ TMVA::DataSetFactory::RenormEvents( TMVA::DataSetInfo& dsi, ValuePerClass renormFactor( dsi.GetNClasses() ); - if (normMode == "NUMEVENTS") { - Log() << kINFO << "Weight renormalisation mode: \"NumEvents\": renormalise independently the ..." << Endl; - Log() << kINFO << "... class weights so that Sum[i=1..N_j]{w_i} = N_j, j=0,1,2..." << Endl; - Log() << kINFO << "... (note that N_j is the sum of training and test events)" << Endl; + // for information purposes + dsi.SetNormalization( normMode ); + // !! these will be overwritten later by the 'rescaled' ones if + // NormMode != None !!! + dsi.SetTrainingSumSignalWeights(trainingSumSignalWeights); + dsi.SetTrainingSumBackgrWeights(trainingSumBackgrWeights); + dsi.SetTestingSumSignalWeights(testingSumSignalWeights); + dsi.SetTestingSumBackgrWeights(testingSumBackgrWeights); + + + if (normMode == "NONE") { + Log() << kINFO << "No weight renormalisation applied: use original global and event weights" << Endl; + return; + } + //changed by Helge 27.5.2013 What on earth was done here before? I still remember the idea behind this which apparently was + //NOT understood by the 'programmer' :) .. the idea was to have SAME amount of effective TRAINING data for signal and background. + // Testing events are totally irrelevant for this and might actually skew the whole normalisation!! + else if (normMode == "NUMEVENTS") { + Log() << kINFO << "Weight renormalisation mode: \"NumEvents\": renormalises all event classes " << Endl; + Log() << kINFO << " such that the effective (weighted) number of events in each class equals the respective " << Endl; + Log() << kINFO << " number of events (entries) that you demanded in PrepareTrainingAndTestTree(\"\",\"nTrain_Signal=.. )" << Endl; + Log() << kINFO << " ... i.e. such that Sum[i=1..N_j]{w_i} = N_j, j=0,1,2..." << Endl; + Log() << kINFO << " ... (note that N_j is the sum of TRAINING events (nTrain_j...with j=Signal,Background.." << Endl; + Log() << kINFO << " ..... Testing events are not renormalised nor included in the renormalisation factor! )"<< Endl; + for( UInt_t cls = 0, clsEnd = dsi.GetNClasses(); cls < clsEnd; ++cls ){ - renormFactor.at(cls) = ( (trainingSizePerClass.at(cls) + testingSizePerClass.at(cls))/ - (trainingSumWeightsPerClass.at(cls) + testingSumWeightsPerClass.at(cls)) ); + // renormFactor.at(cls) = ( (trainingSizePerClass.at(cls) + testingSizePerClass.at(cls))/ + // (trainingSumWeightsPerClass.at(cls) + testingSumWeightsPerClass.at(cls)) ); + //changed by Helge 27.5.2013 + renormFactor.at(cls) = ((Float_t)trainingSizePerClass.at(cls) )/ + (trainingSumWeightsPerClass.at(cls)) ; } } - else if (normMode == "EQUALNUMEVENTS") { - Log() << kINFO << "Weight renormalisation mode: \"EqualNumEvents\": renormalise class weights ..." << Endl; - Log() << kINFO << "... so that Sum[i=1..N_j]{w_i} = N_classA, j=classA, classB, ..." << Endl; - Log() << kINFO << "... (note that N_j is the sum of training and test events)" << Endl; + else if (normMode == "EQUALNUMEVENTS") { + //changed by Helge 27.5.2013 What on earth was done here before? I still remember the idea behind this which apparently was + //NOT understood by the 'programmer' :) .. the idea was to have SAME amount of effective TRAINING data for signal and background. + //done here was something like having each data source normalized to its number of entries and this even for trainig+testing together. + // what should this have been good for ??? + + Log() << kINFO << "Weight renormalisation mode: \"EqualNumEvents\": renormalises all event classes ..." << Endl; + Log() << kINFO << " such that the effective (weighted) number of events in each class is the same " << Endl; + Log() << kINFO << " (and equals the number of events (entries) given for class=0 )" << Endl; + Log() << kINFO << "... i.e. such that Sum[i=1..N_j]{w_i} = N_classA, j=classA, classB, ..." << Endl; + Log() << kINFO << "... (note that N_j is the sum of TRAINING events" << Endl; + Log() << kINFO << " ..... Testing events are not renormalised nor included in the renormalisation factor!)" << Endl; - for (UInt_t cls = 0, clsEnd = dsi.GetNClasses(); cls < clsEnd; ++cls ) { - renormFactor.at(cls) = Float_t(trainingSizePerClass.at(cls)+testingSizePerClass.at(cls))/ - (trainingSumWeightsPerClass.at(cls)+testingSumWeightsPerClass.at(cls)); - } // normalize to size of first class UInt_t referenceClass = 0; for (UInt_t cls = 0, clsEnd = dsi.GetNClasses(); cls < clsEnd; ++cls ) { - if( cls == referenceClass ) continue; - renormFactor.at(cls) *= Float_t(trainingSizePerClass.at(referenceClass)+testingSizePerClass.at(referenceClass) )/ - Float_t( trainingSizePerClass.at(cls)+testingSizePerClass.at(cls) ); + renormFactor.at(cls) = Float_t(trainingSizePerClass.at(referenceClass))/ + (trainingSumWeightsPerClass.at(cls)); } } else { Log() << kFATAL << "<PrepareForTrainingAndTesting> Unknown NormMode: " << normMode << Endl; } - + // --------------------------------- // now apply the normalization factors Int_t maxL = dsi.GetClassNameMaxLength(); for (UInt_t cls = 0, clsEnd = dsi.GetNClasses(); cls<clsEnd; ++cls) { Log() << kINFO << "--> Rescale " << setiosflags(ios::left) << std::setw(maxL) << dsi.GetClassInfo(cls)->GetName() << " event weights by factor: " << renormFactor.at(cls) << Endl; - std::for_each( tmpEventVector[Types::kTraining].at(cls).begin(), - tmpEventVector[Types::kTraining].at(cls).end(), - std::bind2nd(std::mem_fun(&TMVA::Event::ScaleWeight),renormFactor.at(cls)) ); - std::for_each( tmpEventVector[Types::kTesting].at(cls).begin(), - tmpEventVector[Types::kTesting].at(cls).end(), - std::bind2nd(std::mem_fun(&TMVA::Event::ScaleWeight),renormFactor.at(cls)) ); + for (EventVector::iterator it = tmpEventVector[Types::kTraining].at(cls).begin(), + itEnd = tmpEventVector[Types::kTraining].at(cls).end(); it != itEnd; ++it){ + (*it)->SetWeight ((*it)->GetWeight() * renormFactor.at(cls)); + } + } + - - // --------------------------------- - // for information purposes - dsi.SetNormalization( normMode ); - - // ============================ // print out the result // (same code as before --> this can be done nicer ) // - + Log() << kINFO << "Number of training and testing events after rescaling:" << Endl; Log() << kINFO << "------------------------------------------------------" << Endl; - trainingSumWeights = 0; - testingSumWeights = 0; - for( UInt_t cls = 0, clsEnd = dsi.GetNClasses(); cls < clsEnd; ++cls ){ + trainingSumSignalWeights = 0; + trainingSumBackgrWeights = 0; // Backgr. includes all clasess that are not signal + testingSumSignalWeights = 0; + testingSumBackgrWeights = 0; // Backgr. includes all clasess that are not signal + + for( UInt_t cls = 0, clsEnd = dsi.GetNClasses(); cls < clsEnd; ++cls ){ + trainingSumWeightsPerClass.at(cls) = (std::accumulate( tmpEventVector[Types::kTraining].at(cls).begin(), // accumulate --> start at begin tmpEventVector[Types::kTraining].at(cls).end(), // until end() Double_t(0), // values are of type double compose_binary( std::plus<Double_t>(), // define addition for doubles null<Double_t>(), // take the argument, don't do anything and return it std::mem_fun(&TMVA::Event::GetOriginalWeight) ) )); // take the value from GetOriginalWeight - + testingSumWeightsPerClass.at(cls) = std::accumulate( tmpEventVector[Types::kTesting].at(cls).begin(), tmpEventVector[Types::kTesting].at(cls).end(), Double_t(0), compose_binary( std::plus<Double_t>(), null<Double_t>(), std::mem_fun(&TMVA::Event::GetOriginalWeight) ) ); - - - trainingSumWeights += trainingSumWeightsPerClass.at(cls); - testingSumWeights += testingSumWeightsPerClass.at(cls); - + + + if ( cls == dsi.GetSignalClassIndex()){ + trainingSumSignalWeights += trainingSumWeightsPerClass.at(cls); + testingSumSignalWeights += testingSumWeightsPerClass.at(cls); + }else{ + trainingSumBackgrWeights += trainingSumWeightsPerClass.at(cls); + testingSumBackgrWeights += testingSumWeightsPerClass.at(cls); + } + // output statistics - + Log() << kINFO << setiosflags(ios::left) << std::setw(maxL) << dsi.GetClassInfo(cls)->GetName() << " -- " << "training events : " << trainingSizePerClass.at(cls) @@ -1513,6 +1587,13 @@ TMVA::DataSetFactory::RenormEvents( TMVA::DataSetInfo& dsi, << eventCounts[cls].cutScaling() << Endl; } } + + // for information purposes + dsi.SetTrainingSumSignalWeights(trainingSumSignalWeights); + dsi.SetTrainingSumBackgrWeights(trainingSumBackgrWeights); + dsi.SetTestingSumSignalWeights(testingSumSignalWeights); + dsi.SetTestingSumBackgrWeights(testingSumBackgrWeights); + } diff --git a/tmva/src/DataSetInfo.cxx b/tmva/src/DataSetInfo.cxx index e0afd20f1c429..7bff7efe04b73 100644 --- a/tmva/src/DataSetInfo.cxx +++ b/tmva/src/DataSetInfo.cxx @@ -70,6 +70,10 @@ TMVA::DataSetInfo::DataSetInfo(const TString& name) fClasses( 0 ), fNormalization( "NONE" ), fSplitOptions(""), + fTrainingSumSignalWeights(-1), + fTrainingSumBackgrWeights(-1), + fTestingSumSignalWeights (-1), + fTestingSumBackgrWeights (-1), fOwnRootDir(0), fVerbose( kFALSE ), fSignalClass(0), @@ -462,3 +466,21 @@ Int_t TMVA::DataSetInfo::GetClassNameMaxLength() const return maxL; } + +Double_t TMVA::DataSetInfo::GetTrainingSumSignalWeights(){ + if (fTrainingSumSignalWeights<0) Log() << kFATAL << " asking for the sum of training signal event weights which is not initicalised yet" << Endl; + return fTrainingSumSignalWeights; +} +Double_t TMVA::DataSetInfo::GetTrainingSumBackgrWeights(){ + if (fTrainingSumBackgrWeights<0) Log() << kFATAL << " asking for the sum of training backgr event weights which is not initicalised yet" << Endl; + return fTrainingSumBackgrWeights; +} +Double_t TMVA::DataSetInfo::GetTestingSumSignalWeights (){ + if (fTestingSumSignalWeights<0) Log() << kFATAL << " asking for the sum of testing signal event weights which is not initicalised yet" << Endl; + return fTestingSumSignalWeights ; +} +Double_t TMVA::DataSetInfo::GetTestingSumBackgrWeights (){ + if (fTestingSumBackgrWeights<0) Log() << kFATAL << " asking for the sum of testing backgr event weights which is not initicalised yet" << Endl; + return fTestingSumBackgrWeights ; +} + diff --git a/tmva/src/DecisionTree.cxx b/tmva/src/DecisionTree.cxx index 64dad92dff759..f527a4efd465c 100644 --- a/tmva/src/DecisionTree.cxx +++ b/tmva/src/DecisionTree.cxx @@ -105,15 +105,14 @@ TMVA::DecisionTree::DecisionTree(): fUseSearchTree(kFALSE), fPruneStrength(0), fPruneMethod (kNoPruning), + fNNodesBeforePruning(0), fNodePurityLimit(0.5), fRandomisedTree (kFALSE), fUseNvars (0), fUsePoissonNvars(kFALSE), fMyTrandom (NULL), - fNNodesMax (999999), fMaxDepth (999999), fSigClass (0), - fPairNegWeightsInNode(kFALSE), fTreeID (0), fAnalysisType (Types::kClassification) { @@ -123,8 +122,8 @@ TMVA::DecisionTree::DecisionTree(): } //_______________________________________________________________________ -TMVA::DecisionTree::DecisionTree( TMVA::SeparationBase *sepType, Int_t minSize, Int_t nCuts, UInt_t cls, - Bool_t randomisedTree, Int_t useNvars, Bool_t usePoissonNvars, UInt_t nNodesMax, +TMVA::DecisionTree::DecisionTree( TMVA::SeparationBase *sepType, Float_t minSize, Int_t nCuts, UInt_t cls, + Bool_t randomisedTree, Int_t useNvars, Bool_t usePoissonNvars, UInt_t nMaxDepth, Int_t iSeed, Float_t purityLimit, Int_t treeID): BinaryTree(), fNvars (0), @@ -134,21 +133,22 @@ TMVA::DecisionTree::DecisionTree( TMVA::SeparationBase *sepType, Int_t minSize, fUseExclusiveVars (kTRUE), fSepType (sepType), fRegType (NULL), - fMinSize (minSize), + fMinSize (0), + fMinNodeSize (minSize), fMinSepGain (0), fUseSearchTree (kFALSE), fPruneStrength (0), fPruneMethod (kNoPruning), + fNNodesBeforePruning(0), fNodePurityLimit(purityLimit), fRandomisedTree (randomisedTree), fUseNvars (useNvars), fUsePoissonNvars(usePoissonNvars), fMyTrandom (new TRandom3(iSeed)), - fNNodesMax (nNodesMax), fMaxDepth (nMaxDepth), fSigClass (cls), - fPairNegWeightsInNode(kFALSE), - fTreeID (treeID) + fTreeID (treeID), + fAnalysisType (Types::kClassification) { // constructor specifying the separation type, the min number of // events in a no that is still subjected to further splitting, the @@ -183,6 +183,7 @@ TMVA::DecisionTree::DecisionTree( const DecisionTree &d ): fSepType (d.fSepType), fRegType (d.fRegType), fMinSize (d.fMinSize), + fMinNodeSize(d.fMinNodeSize), fMinSepGain (d.fMinSepGain), fUseSearchTree (d.fUseSearchTree), fPruneStrength (d.fPruneStrength), @@ -192,10 +193,8 @@ TMVA::DecisionTree::DecisionTree( const DecisionTree &d ): fUseNvars (d.fUseNvars), fUsePoissonNvars(d.fUsePoissonNvars), fMyTrandom (new TRandom3(fgRandomSeed)), // well, that means it's not an identical copy. But I only ever intend to really copy trees that are "outgrown" already. - fNNodesMax (d.fNNodesMax), fMaxDepth (d.fMaxDepth), fSigClass (d.fSigClass), - fPairNegWeightsInNode(d.fPairNegWeightsInNode), fTreeID (d.fTreeID), fAnalysisType(d.fAnalysisType) { @@ -215,6 +214,7 @@ TMVA::DecisionTree::~DecisionTree() // destruction of the tree nodes done in the "base class" BinaryTree if (fMyTrandom) delete fMyTrandom; + if (fRegType) delete fRegType; } //_______________________________________________________________________ @@ -264,15 +264,13 @@ TMVA::DecisionTree* TMVA::DecisionTree::CreateFromXML(void* node, UInt_t tmva_Ve //_______________________________________________________________________ -UInt_t TMVA::DecisionTree::BuildTree( const vector<TMVA::Event*> & eventSample, +UInt_t TMVA::DecisionTree::BuildTree( const std::vector<const TMVA::Event*> & eventSample, TMVA::DecisionTreeNode *node) { // building the decision tree by recursively calling the splitting of // one (root-) node into two daughter nodes (returns the number of nodes) - // Bool_t IsRootNode=kFALSE; if (node==NULL) { - // IsRootNode = kTRUE; //start with the root node node = new TMVA::DecisionTreeNode(); fNNodes = 1; @@ -281,18 +279,25 @@ UInt_t TMVA::DecisionTree::BuildTree( const vector<TMVA::Event*> & eventSample, this->GetRoot()->SetPos('s'); this->GetRoot()->SetDepth(0); this->GetRoot()->SetParentTree(this); - } + fMinSize = fMinNodeSize/100. * eventSample.size(); + if (GetTreeID()==0){ + Log() << kINFO << "The minimal node size MinNodeSize=" << fMinNodeSize << " fMinNodeSize="<<fMinNodeSize<< "% is translated to an actual number of events = "<< fMinSize<< " for the training sample size of " << eventSample.size() << Endl; + Log() << kINFO << "Note: This number will be taken as absolute minimum in the node, " << Endl; + Log() << kINFO << " in terms of 'weighted events' and unweighted ones !! " << Endl; + } + } UInt_t nevents = eventSample.size(); if (nevents > 0 ) { - fNvars = eventSample[0]->GetNVariables(); + if (fNvars==0) fNvars = eventSample[0]->GetNVariables(); // should have been set before, but ... well.. fVariableImportance.resize(fNvars); } else Log() << kFATAL << ":<BuildTree> eventsample Size == 0 " << Endl; Double_t s=0, b=0; Double_t suw=0, buw=0; + Double_t sub=0, bub=0; // unboosted! Double_t target=0, target2=0; Float_t *xmin = new Float_t[fNvars]; Float_t *xmax = new Float_t[fNvars]; @@ -302,13 +307,16 @@ UInt_t TMVA::DecisionTree::BuildTree( const vector<TMVA::Event*> & eventSample, for (UInt_t iev=0; iev<eventSample.size(); iev++) { const TMVA::Event* evt = eventSample[iev]; const Double_t weight = evt->GetWeight(); + const Double_t orgWeight = evt->GetOriginalWeight(); // unboosted! if (evt->GetClass() == fSigClass) { s += weight; suw += 1; + sub += orgWeight; } else { b += weight; buw += 1; + bub += orgWeight; } if ( DoRegression() ) { const Double_t tgt = evt->GetTarget(0); @@ -324,13 +332,14 @@ UInt_t TMVA::DecisionTree::BuildTree( const vector<TMVA::Event*> & eventSample, } } + if (s+b < 0) { Log() << kWARNING << " One of the Decision Tree nodes has negative total number of signal or background events. " << "(Nsig="<<s<<" Nbkg="<<b<<" Probaby you use a Monte Carlo with negative weights. That should in principle " << "be fine as long as on average you end up with something positive. For this you have to make sure that the " - << "minimul number of (unweighted) events demanded for a tree node (currently you use: nEventsMin="<<fMinSize - << ", you can set this via the BDT option string when booking the classifier) is large enough to allow for " - << "reasonable averaging!!!" << Endl + << "minimul number of (unweighted) events demanded for a tree node (currently you use: MinNodeSize="<<fMinNodeSize + << "% of training events, you can set this via the BDT option string when booking the classifier) is large enough " + << "to allow for reasonable averaging!!!" << Endl << " If this does not help.. maybe you want to try the option: NoNegWeightsInTraining which ignores events " << "with negative weight in the training." << Endl; double nBkg=0.; @@ -348,10 +357,13 @@ UInt_t TMVA::DecisionTree::BuildTree( const vector<TMVA::Event*> & eventSample, node->SetNBkgEvents(b); node->SetNSigEvents_unweighted(suw); node->SetNBkgEvents_unweighted(buw); + node->SetNSigEvents_unboosted(sub); + node->SetNBkgEvents_unboosted(bub); node->SetPurity(); if (node == this->GetRoot()) { node->SetNEvents(s+b); node->SetNEvents_unweighted(suw+buw); + node->SetNEvents_unboosted(sub+bub); } for (UInt_t ivar=0; ivar<fNvars; ivar++) { node->SetSampleMin(ivar,xmin[ivar]); @@ -364,9 +376,11 @@ UInt_t TMVA::DecisionTree::BuildTree( const vector<TMVA::Event*> & eventSample, // of events in the parent node is not at least two times as big, I don't even need to try // splitting - //HHVTEST - // if (fNNodes < fNNodesMax && node->GetDepth() < fMaxDepth - if (eventSample.size() >= 2*fMinSize && fNNodes < fNNodesMax && node->GetDepth() < fMaxDepth + // ask here for actuall "events" independent of their weight.. OR the weighted events + // to execeed the min requested number of events per dauther node + // (NOTE: make sure that at the eventSample at the ROOT node has sum_of_weights == sample.size() ! + // if ((eventSample.size() >= 2*fMinSize ||s+b >= 2*fMinSize) && node->GetDepth() < fMaxDepth + if ((eventSample.size() >= 2*fMinSize && s+b >= 2*fMinSize) && node->GetDepth() < fMaxDepth && ( ( s!=0 && b !=0 && !DoRegression()) || ( (s+b)!=0 && DoRegression()) ) ) { Double_t separationGain; if (fNCuts > 0){ @@ -392,19 +406,22 @@ UInt_t TMVA::DecisionTree::BuildTree( const vector<TMVA::Event*> & eventSample, } else { - vector<TMVA::Event*> leftSample; leftSample.reserve(nevents); - vector<TMVA::Event*> rightSample; rightSample.reserve(nevents); + std::vector<const TMVA::Event*> leftSample; leftSample.reserve(nevents); + std::vector<const TMVA::Event*> rightSample; rightSample.reserve(nevents); Double_t nRight=0, nLeft=0; + Double_t nRightUnBoosted=0, nLeftUnBoosted=0; for (UInt_t ie=0; ie< nevents ; ie++) { if (node->GoesRight(*eventSample[ie])) { rightSample.push_back(eventSample[ie]); nRight += eventSample[ie]->GetWeight(); + nRightUnBoosted += eventSample[ie]->GetOriginalWeight(); } else { leftSample.push_back(eventSample[ie]); nLeft += eventSample[ie]->GetWeight(); + nLeftUnBoosted += eventSample[ie]->GetOriginalWeight(); } } @@ -422,12 +439,14 @@ UInt_t TMVA::DecisionTree::BuildTree( const vector<TMVA::Event*> & eventSample, TMVA::DecisionTreeNode *rightNode = new TMVA::DecisionTreeNode(node,'r'); fNNodes++; rightNode->SetNEvents(nRight); + rightNode->SetNEvents_unboosted(nRightUnBoosted); rightNode->SetNEvents_unweighted(rightSample.size()); TMVA::DecisionTreeNode *leftNode = new TMVA::DecisionTreeNode(node,'l'); fNNodes++; leftNode->SetNEvents(nLeft); + leftNode->SetNEvents_unboosted(nLeftUnBoosted); leftNode->SetNEvents_unweighted(leftSample.size()); node->SetNodeType(0); @@ -453,56 +472,6 @@ UInt_t TMVA::DecisionTree::BuildTree( const vector<TMVA::Event*> & eventSample, // is misclassified, find randomly as many events with positive weights in this // node as needed to get the same absolute number of weight, and mark them as // "not to be boosted" in order to make up for not boosting the negative weight event - if (fPairNegWeightsInNode){ - Double_t sumOfNegWeights = 0; - UInt_t iClassID=99; // the event class that misClassified in the current node - for (UInt_t iev=0; iev<eventSample.size(); iev++) { - if (eventSample[iev]->GetWeight() < 0) { - if (eventSample[iev]->GetClass() == fSigClass){ - if (node->GetNodeType() != 1) { // classification is wrong - sumOfNegWeights+=eventSample[iev]->GetWeight(); - iClassID=eventSample[iev]->GetClass(); - } - } else { - if (node->GetNodeType() == 1) { // classification is wrong - sumOfNegWeights+=eventSample[iev]->GetWeight(); - iClassID=eventSample[iev]->GetClass(); - } - } - } - } - if (iClassID == 99 && sumOfNegWeights < 0) Log() << kFATAL << " sorry.. something went wrong in treatment of neg. events" << Endl; - // I need to find "misclassified" events whose positive weights add up to "sumOfNegWeights" - while (sumOfNegWeights < 0 && - ( ( TMath::Abs(sumOfNegWeights) < node->GetNBkgEvents() && iClassID != fSigClass) || - ( TMath::Abs(sumOfNegWeights) < node->GetNSigEvents() && iClassID == fSigClass) ) ){ - UInt_t iev=fMyTrandom->Integer(eventSample.size()); - - Log() << kWARNING - << " so far... I have still " << sumOfNegWeights - << " now event " << iev << "("<<eventSample.size()<<") has " << eventSample[iev]->GetWeight() - << " class " << eventSample[iev]->GetClass() << "("<<iClassID<<")" - << " sig " << node->GetNSigEvents() << "("<<node->GetNSigEvents_unweighted()<< ")" - << " bkg " << node->GetNBkgEvents() << "("<<node->GetNBkgEvents_unweighted()<< ")" - << Endl; - if (eventSample[iev]->GetWeight() > 0 && iClassID==eventSample[iev]->GetClass() ){ - sumOfNegWeights+=eventSample[iev]->GetWeight(); - eventSample[iev]->SetDoNotBoost(); - - // Double_t dist=0, minDist=10E270; - // for (UInt_t ivar=0; ivar < GetNvar(); ivar++){ - // for (UInt_t jvar=0; jvar<GetNvar(); jvar++){ - // dist += (negEvents[nev]->GetValue(ivar)-fEventSample[iev]->GetValue(ivar))* - // // (*invCov)[ivar][jvar]* - // (negEvents[nev]->GetValue(jvar)-fEventSample[iev]->GetValue(jvar)); - // } - // } - // Log() << kWARNING << "pair with event in dist^2="<<dist << " dist="<<TMath::Sqrt(dist) << Endl; - - - } - } - } } @@ -514,7 +483,7 @@ UInt_t TMVA::DecisionTree::BuildTree( const vector<TMVA::Event*> & eventSample, } //_______________________________________________________________________ -void TMVA::DecisionTree::FillTree( vector<TMVA::Event*> & eventSample ) +void TMVA::DecisionTree::FillTree( const std::vector<TMVA::Event*> & eventSample ) { // fill the existing the decision tree structure by filling event @@ -525,7 +494,7 @@ void TMVA::DecisionTree::FillTree( vector<TMVA::Event*> & eventSample ) } //_______________________________________________________________________ -void TMVA::DecisionTree::FillEvent( TMVA::Event & event, +void TMVA::DecisionTree::FillEvent( const TMVA::Event & event, TMVA::DecisionTreeNode *node ) { // fill the existing the decision tree structure by filling event @@ -599,14 +568,16 @@ UInt_t TMVA::DecisionTree::CleanTree( DecisionTreeNode *node ) } //_______________________________________________________________________ -Double_t TMVA::DecisionTree::PruneTree( vector<Event*>* validationSample ) +Double_t TMVA::DecisionTree::PruneTree( const EventConstList* validationSample ) { // prune (get rid of internal nodes) the Decision tree to avoid overtraining // serveral different pruning methods can be applied as selected by the // variable "fPruneMethod". // std::ofstream logfile("dt_pruning.log"); + + IPruneTool* tool(NULL); PruningInfo* info(NULL); @@ -623,46 +594,49 @@ Double_t TMVA::DecisionTree::PruneTree( vector<Event*>* validationSample ) Log() << kFATAL << "Selected pruning method not yet implemented " << Endl; } + if(!tool) return 0.0; tool->SetPruneStrength(GetPruneStrength()); if(tool->IsAutomatic()) { - if(validationSample == NULL) + if(validationSample == NULL){ Log() << kFATAL << "Cannot automate the pruning algorithm without an " << "independent validation sample!" << Endl; - if(validationSample->size() == 0) + }else if(validationSample->size() == 0) { Log() << kFATAL << "Cannot automate the pruning algorithm with " << "independent validation sample of ZERO events!" << Endl; + } } info = tool->CalculatePruningInfo(this,validationSample); + Double_t pruneStrength=0; if(!info) { - delete tool; Log() << kFATAL << "Error pruning tree! Check prune.log for more information." << Endl; - } - Double_t pruneStrength = info->PruneStrength; - - // Log() << kDEBUG << "Optimal prune strength (alpha): " << pruneStrength - // << " has quality index " << info->QualityIndex << Endl; - - - for (UInt_t i = 0; i < info->PruneSequence.size(); ++i) { + } else { + pruneStrength = info->PruneStrength; + + // Log() << kDEBUG << "Optimal prune strength (alpha): " << pruneStrength + // << " has quality index " << info->QualityIndex << Endl; - PruneNode(info->PruneSequence[i]); + + for (UInt_t i = 0; i < info->PruneSequence.size(); ++i) { + + PruneNode(info->PruneSequence[i]); + } + // update the number of nodes after the pruning + this->CountNodes(); } - // update the number of nodes after the pruning - this->CountNodes(); - + delete tool; delete info; - + return pruneStrength; }; //_______________________________________________________________________ -void TMVA::DecisionTree::ApplyValidationSample( const EventList* validationSample ) const +void TMVA::DecisionTree::ApplyValidationSample( const EventConstList* validationSample ) const { // run the validation sample through the (pruned) tree and fill in the nodes // the variables NSValidation and NBValidadtion (i.e. how many of the Signal @@ -670,7 +644,7 @@ void TMVA::DecisionTree::ApplyValidationSample( const EventList* validationSampl // when asking for the "tree quality" .. GetRoot()->ResetValidationData(); for (UInt_t ievt=0; ievt < validationSample->size(); ievt++) { - CheckEventWithPrunedTree(*(*validationSample)[ievt]); + CheckEventWithPrunedTree((*validationSample)[ievt]); } } @@ -718,7 +692,7 @@ Double_t TMVA::DecisionTree::TestPrunedTreeQuality( const DecisionTreeNode* n, I } //_______________________________________________________________________ -void TMVA::DecisionTree::CheckEventWithPrunedTree( const Event& e ) const +void TMVA::DecisionTree::CheckEventWithPrunedTree( const Event* e ) const { // pass a single validation event throught a pruned decision tree // on the way down the tree, fill in all the "intermediate" information @@ -730,21 +704,21 @@ void TMVA::DecisionTree::CheckEventWithPrunedTree( const Event& e ) const } while(current != NULL) { - if(e.GetClass() == fSigClass) - current->SetNSValidation(current->GetNSValidation() + e.GetWeight()); + if(e->GetClass() == fSigClass) + current->SetNSValidation(current->GetNSValidation() + e->GetWeight()); else - current->SetNBValidation(current->GetNBValidation() + e.GetWeight()); + current->SetNBValidation(current->GetNBValidation() + e->GetWeight()); - if (e.GetNTargets() > 0) { - current->AddToSumTarget(e.GetWeight()*e.GetTarget(0)); - current->AddToSumTarget2(e.GetWeight()*e.GetTarget(0)*e.GetTarget(0)); + if (e->GetNTargets() > 0) { + current->AddToSumTarget(e->GetWeight()*e->GetTarget(0)); + current->AddToSumTarget2(e->GetWeight()*e->GetTarget(0)*e->GetTarget(0)); } if (current->GetRight() == NULL || current->GetLeft() == NULL) { current = NULL; } else { - if (current->GoesRight(e)) + if (current->GoesRight(*e)) current = (TMVA::DecisionTreeNode*)current->GetRight(); else current = (TMVA::DecisionTreeNode*)current->GetLeft(); @@ -753,11 +727,11 @@ void TMVA::DecisionTree::CheckEventWithPrunedTree( const Event& e ) const } //_______________________________________________________________________ -Double_t TMVA::DecisionTree::GetSumWeights( const EventList* validationSample ) const +Double_t TMVA::DecisionTree::GetSumWeights( const EventConstList* validationSample ) const { // calculate the normalization factor for a pruning validation sample Double_t sumWeights = 0.0; - for( EventList::const_iterator it = validationSample->begin(); + for( EventConstList::const_iterator it = validationSample->begin(); it != validationSample->end(); ++it ) { sumWeights += (*it)->GetWeight(); } @@ -909,7 +883,7 @@ void TMVA::DecisionTree::GetRandomisedVariables(Bool_t *useVariable, UInt_t *map } //_______________________________________________________________________ -Double_t TMVA::DecisionTree::TrainNodeFast( const vector<TMVA::Event*> & eventSample, +Double_t TMVA::DecisionTree::TrainNodeFast( const EventConstList & eventSample, TMVA::DecisionTreeNode *node ) { // Decide how to split a node using one of the variables that gives @@ -922,13 +896,14 @@ Double_t TMVA::DecisionTree::TrainNodeFast( const vector<TMVA::Event*> & eventSa Double_t separationGainTotal = -1, sepTmp; Double_t *separationGain = new Double_t[fNvars+1]; + Int_t *cutIndex = new Int_t[fNvars+1]; //-1; + for (UInt_t ivar=0; ivar <= fNvars; ivar++) { separationGain[ivar]=-1; + cutIndex[ivar]=-1; } - Double_t cutValue=-999; - Int_t mxVar= -1; - Int_t cutIndex=-1; - Bool_t cutType=kTRUE; + Int_t mxVar = -1; + Bool_t cutType = kTRUE; Double_t nTotS, nTotB; Int_t nTotS_unWeighted, nTotB_unWeighted; UInt_t nevents = eventSample.size(); @@ -936,7 +911,7 @@ Double_t TMVA::DecisionTree::TrainNodeFast( const vector<TMVA::Event*> & eventSa // the +1 comes from the fact that I treat later on the Fisher output as an // additional possible variable. - Bool_t *useVariable = new Bool_t[fNvars+1]; // for performance reasons instead of vector<Bool_t> useVariable(fNvars); + Bool_t *useVariable = new Bool_t[fNvars+1]; // for performance reasons instead of std::vector<Bool_t> useVariable(fNvars); UInt_t *mapVariable = new UInt_t[fNvars+1]; // map the subset of variables used in randomised trees to the original variable number (used in the Event() ) std::vector<Double_t> fisherCoeff; @@ -953,12 +928,13 @@ Double_t TMVA::DecisionTree::TrainNodeFast( const vector<TMVA::Event*> & eventSa } useVariable[fNvars] = kFALSE; //by default fisher is not used.. + Bool_t fisherOK = kFALSE; // flag to show that the fisher discriminant could be calculated correctly or not; if (fUseFisherCuts) { useVariable[fNvars] = kTRUE; // that's were I store the "fisher MVA" //use for the Fisher discriminant ONLY those variables that show //some reasonable linear correlation in either Signal or Background - Bool_t *useVarInFisher = new Bool_t[fNvars]; // for performance reasons instead of vector<Bool_t> useVariable(fNvars); + Bool_t *useVarInFisher = new Bool_t[fNvars]; // for performance reasons instead of std::vector<Bool_t> useVariable(fNvars); UInt_t *mapVarInFisher = new UInt_t[fNvars]; // map the subset of variables used in randomised trees to the original variable number (used in the Event() ) for (UInt_t ivar=0; ivar < fNvars; ivar++) { useVarInFisher[ivar] = kFALSE; @@ -967,45 +943,51 @@ Double_t TMVA::DecisionTree::TrainNodeFast( const vector<TMVA::Event*> & eventSa std::vector<TMatrixDSym*>* covMatrices; covMatrices = gTools().CalcCovarianceMatrices( eventSample, 2 ); // currently for 2 classes only - TMatrixD *ss = new TMatrixD(*(covMatrices->at(0))); - TMatrixD *bb = new TMatrixD(*(covMatrices->at(1))); - const TMatrixD *s = gTools().GetCorrelationMatrix(ss); - const TMatrixD *b = gTools().GetCorrelationMatrix(bb); - - for (UInt_t ivar=0; ivar < fNvars; ivar++) { - for (UInt_t jvar=ivar+1; jvar < fNvars; jvar++) { - if ( ( TMath::Abs( (*s)(ivar, jvar)) > fMinLinCorrForFisher) || - ( TMath::Abs( (*b)(ivar, jvar)) > fMinLinCorrForFisher) ){ - useVarInFisher[ivar] = kTRUE; - useVarInFisher[jvar] = kTRUE; + if (!covMatrices){ + Log() << kWARNING << " in TrainNodeFast, the covariance Matrices needed for the Fisher-Cuts returned error --> revert to just normal cuts for this node" << Endl; + fisherOK = kFALSE; + }else{ + TMatrixD *ss = new TMatrixD(*(covMatrices->at(0))); + TMatrixD *bb = new TMatrixD(*(covMatrices->at(1))); + const TMatrixD *s = gTools().GetCorrelationMatrix(ss); + const TMatrixD *b = gTools().GetCorrelationMatrix(bb); + + for (UInt_t ivar=0; ivar < fNvars; ivar++) { + for (UInt_t jvar=ivar+1; jvar < fNvars; jvar++) { + if ( ( TMath::Abs( (*s)(ivar, jvar)) > fMinLinCorrForFisher) || + ( TMath::Abs( (*b)(ivar, jvar)) > fMinLinCorrForFisher) ){ + useVarInFisher[ivar] = kTRUE; + useVarInFisher[jvar] = kTRUE; + } } } - } - // now as you know which variables you want to use, count and map them: - // such that you can use an array/matrix filled only with THOSE variables - // that you used - UInt_t nFisherVars = 0; - for (UInt_t ivar=0; ivar < fNvars; ivar++) { - //now .. pick those variables that are used in the FIsher and are also - // part of the "allowed" variables in case of Randomized Trees) - if (useVarInFisher[ivar] && useVariable[ivar]) { - mapVarInFisher[nFisherVars++]=ivar; - // now exclud the the variables used in the Fisher cuts, and don't - // use them anymore in the individual variable scan - if (fUseExclusiveVars) useVariable[ivar] = kFALSE; + // now as you know which variables you want to use, count and map them: + // such that you can use an array/matrix filled only with THOSE variables + // that you used + UInt_t nFisherVars = 0; + for (UInt_t ivar=0; ivar < fNvars; ivar++) { + //now .. pick those variables that are used in the FIsher and are also + // part of the "allowed" variables in case of Randomized Trees) + if (useVarInFisher[ivar] && useVariable[ivar]) { + mapVarInFisher[nFisherVars++]=ivar; + // now exclud the the variables used in the Fisher cuts, and don't + // use them anymore in the individual variable scan + if (fUseExclusiveVars) useVariable[ivar] = kFALSE; + } } + + + fisherCoeff = this->GetFisherCoefficients(eventSample, nFisherVars, mapVarInFisher); + fisherOK = kTRUE; + delete [] useVarInFisher; + delete [] mapVarInFisher; } - - - fisherCoeff = this->GetFisherCoefficients(eventSample, nFisherVars, mapVarInFisher); - delete [] useVarInFisher; - delete [] mapVarInFisher; } const UInt_t nBins = fNCuts+1; UInt_t cNvars = fNvars; - if (fUseFisherCuts) cNvars++; // use the Fisher output simple as additional variable + if (fUseFisherCuts && fisherOK) cNvars++; // use the Fisher output simple as additional variable Double_t** nSelS = new Double_t* [cNvars]; Double_t** nSelB = new Double_t* [cNvars]; @@ -1129,7 +1111,7 @@ Double_t TMVA::DecisionTree::TrainNodeFast( const vector<TMVA::Event*> & eventSa } } } - // now turn the "histogram" into a cummulative distribution + // now turn the "histogram" into a cumulative distribution for (UInt_t ivar=0; ivar < cNvars; ivar++) { if (useVariable[ivar]) { for (UInt_t ibin=1; ibin < nBins; ibin++) { @@ -1178,14 +1160,17 @@ Double_t TMVA::DecisionTree::TrainNodeFast( const vector<TMVA::Event*> & eventSa Double_t bl = nSelB_unWeighted[ivar][iBin]; Double_t s = nTotS_unWeighted; Double_t b = nTotB_unWeighted; - // HHVTEST ... see if that's the reason why neg.even weight boosting still behave different... - // Double_t sl = nSelS[ivar][iBin]; - // Double_t bl = nSelB[ivar][iBin]; - // Double_t s = nTotS; - // Double_t b = nTotB; + Double_t slW = nSelS[ivar][iBin]; + Double_t blW = nSelB[ivar][iBin]; + Double_t sW = nTotS; + Double_t bW = nTotB; Double_t sr = s-sl; Double_t br = b-bl; - if ( (sl+bl)>=fMinSize && (sr+br)>=fMinSize ) { + Double_t srW = sW-slW; + Double_t brW = bW-blW; + if ( ((sl+bl)>=fMinSize && (sr+br)>=fMinSize) + && ((slW+blW)>=fMinSize && (srW+brW)>=fMinSize) + ) { if (DoRegression()) { sepTmp = fRegType->GetSeparationGain(nSelS[ivar][iBin]+nSelB[ivar][iBin], @@ -1196,19 +1181,25 @@ Double_t TMVA::DecisionTree::TrainNodeFast( const vector<TMVA::Event*> & eventSa sepTmp = fSepType->GetSeparationGain(nSelS[ivar][iBin], nSelB[ivar][iBin], nTotS, nTotB); } if (separationGain[ivar] < sepTmp) { - separationGain[ivar] = sepTmp; // used for variable importance calculation - if (separationGainTotal < sepTmp) { - separationGainTotal = sepTmp; - mxVar = ivar; - cutIndex = iBin; - if (cutIndex >= fNCuts) Log()<<kFATAL<<"ibin for cut " << iBin << Endl; - } + separationGain[ivar] = sepTmp; + cutIndex[ivar] = iBin; } } } } } - + + + //now you have found the best separation cut for each variable, now compare the variables + for (UInt_t ivar=0; ivar < cNvars; ivar++) { + if (useVariable[ivar] ) { + if (separationGainTotal < separationGain[ivar]) { + separationGainTotal = separationGain[ivar]; + mxVar = ivar; + } + } + } + if (DoRegression()) { node->SetSeparationIndex(fRegType->GetSeparationIndex(nTotS+nTotB,target[0][nBins-1],target2[0][nBins-1])); node->SetResponse(target[0][nBins-1]/(nTotS+nTotB)); @@ -1218,12 +1209,11 @@ Double_t TMVA::DecisionTree::TrainNodeFast( const vector<TMVA::Event*> & eventSa node->SetSeparationIndex(fSepType->GetSeparationIndex(nTotS,nTotB)); } if (mxVar >= 0) { - if (nSelS[mxVar][cutIndex]/nTotS > nSelB[mxVar][cutIndex]/nTotB) cutType=kTRUE; + if (nSelS[mxVar][cutIndex[mxVar]]/nTotS > nSelB[mxVar][cutIndex[mxVar]]/nTotB) cutType=kTRUE; else cutType=kFALSE; - cutValue = cutValues[mxVar][cutIndex]; node->SetSelector((UInt_t)mxVar); - node->SetCutValue(cutValue); + node->SetCutValue(cutValues[mxVar][cutIndex[mxVar]]); node->SetCutType(cutType); node->SetSeparationGain(separationGainTotal); if (mxVar < (Int_t) fNvars){ // the fisher cut is actually not used in this node, hence don't need to store fisher components @@ -1273,6 +1263,7 @@ Double_t TMVA::DecisionTree::TrainNodeFast( const vector<TMVA::Event*> & eventSa delete [] mapVariable; delete [] separationGain; + delete [] cutIndex; return separationGainTotal; @@ -1281,7 +1272,7 @@ Double_t TMVA::DecisionTree::TrainNodeFast( const vector<TMVA::Event*> & eventSa //_______________________________________________________________________ -std::vector<Double_t> TMVA::DecisionTree::GetFisherCoefficients(const EventList &eventSample, UInt_t nFisherVars, UInt_t *mapVarInFisher){ +std::vector<Double_t> TMVA::DecisionTree::GetFisherCoefficients(const EventConstList &eventSample, UInt_t nFisherVars, UInt_t *mapVarInFisher){ // calculate the fisher coefficients for the event sample and the variables used std::vector<Double_t> fisherCoeff(fNvars+1); @@ -1315,16 +1306,17 @@ std::vector<Double_t> TMVA::DecisionTree::GetFisherCoefficients(const EventList // read the Training Event into "event" const Event * ev = eventSample[ievt]; - + // sum of weights Double_t weight = ev->GetWeight(); if (ev->GetClass() == fSigClass) sumOfWeightsS += weight; else sumOfWeightsB += weight; Double_t* sum = ev->GetClass() == fSigClass ? sumS : sumB; - for (UInt_t ivar=0; ivar<nFisherVars; ivar++) sum[ivar] += ev->GetValue( mapVarInFisher[ivar] )*weight; + for (UInt_t ivar=0; ivar<nFisherVars; ivar++) { + sum[ivar] += ev->GetValue( mapVarInFisher[ivar] )*weight; + } } - for (UInt_t ivar=0; ivar<nFisherVars; ivar++) { (*meanMatx)( ivar, 2 ) = sumS[ivar]; (*meanMatx)( ivar, 0 ) = sumS[ivar]/sumOfWeightsS; @@ -1335,7 +1327,9 @@ std::vector<Double_t> TMVA::DecisionTree::GetFisherCoefficients(const EventList // signal + background (*meanMatx)( ivar, 2 ) /= (sumOfWeightsS + sumOfWeightsB); } + delete [] sumS; + delete [] sumB; // the matrix of covariance 'within class' reflects the dispersion of the @@ -1358,17 +1352,19 @@ std::vector<Double_t> TMVA::DecisionTree::GetFisherCoefficients(const EventList for (UInt_t ievt=0; ievt<nevents; ievt++) { // read the Training Event into "event" - const Event* ev = eventSample[ievt]; + // const Event* ev = eventSample[ievt]; + const Event* ev = eventSample.at(ievt); Double_t weight = ev->GetWeight(); // may ignore events with negative weights - for (UInt_t x=0; x<nFisherVars; x++) xval[x] = ev->GetValue( mapVarInFisher[x] ); + for (UInt_t x=0; x<nFisherVars; x++) { + xval[x] = ev->GetValue( mapVarInFisher[x] ); + } Int_t k=0; for (UInt_t x=0; x<nFisherVars; x++) { for (UInt_t y=0; y<nFisherVars; y++) { - Double_t v = ( (xval[x] - (*meanMatx)(x, 0))*(xval[y] - (*meanMatx)(y, 0)) )*weight; - if ( ev->GetClass() == fSigClass ) sum2Sig[k] += v; - else sum2Bgd[k] += v; + if ( ev->GetClass() == fSigClass ) sum2Sig[k] += ( (xval[x] - (*meanMatx)(x, 0))*(xval[y] - (*meanMatx)(y, 0)) )*weight; + else sum2Bgd[k] += ( (xval[x] - (*meanMatx)(x, 1))*(xval[y] - (*meanMatx)(y, 1)) )*weight; k++; } } @@ -1376,7 +1372,7 @@ std::vector<Double_t> TMVA::DecisionTree::GetFisherCoefficients(const EventList Int_t k=0; for (UInt_t x=0; x<nFisherVars; x++) { for (UInt_t y=0; y<nFisherVars; y++) { - (*with)(x, y) = (sum2Sig[k] + sum2Bgd[k])/(sumOfWeightsS + sumOfWeightsB); + (*with)(x, y) = sum2Sig[k]/sumOfWeightsS + sum2Bgd[k]/sumOfWeightsB; k++; } } @@ -1469,7 +1465,7 @@ std::vector<Double_t> TMVA::DecisionTree::GetFisherCoefficients(const EventList } //_______________________________________________________________________ -Double_t TMVA::DecisionTree::TrainNodeFull( const vector<TMVA::Event*> & eventSample, +Double_t TMVA::DecisionTree::TrainNodeFull( const EventConstList & eventSample, TMVA::DecisionTreeNode *node ) { @@ -1479,17 +1475,17 @@ Double_t TMVA::DecisionTree::TrainNodeFull( const vector<TMVA::Event*> & eventSa Double_t nTotS = 0.0, nTotB = 0.0; Int_t nTotS_unWeighted = 0, nTotB_unWeighted = 0; - vector<TMVA::BDTEventWrapper> bdtEventSample; + std::vector<TMVA::BDTEventWrapper> bdtEventSample; // List of optimal cuts, separation gains, and cut types (removed background or signal) - one for each variable - vector<Double_t> lCutValue( fNvars, 0.0 ); - vector<Double_t> lSepGain( fNvars, -1.0e6 ); - vector<Char_t> lCutType( fNvars ); // <----- bool is stored (for performance reasons, no vector<bool> has been taken) + std::vector<Double_t> lCutValue( fNvars, 0.0 ); + std::vector<Double_t> lSepGain( fNvars, -1.0e6 ); + std::vector<Char_t> lCutType( fNvars ); // <----- bool is stored (for performance reasons, no std::vector<bool> has been taken) lCutType.assign( fNvars, Char_t(kFALSE) ); // Initialize (un)weighted counters for signal & background // Construct a list of event wrappers that point to the original data - for( vector<TMVA::Event*>::const_iterator it = eventSample.begin(); it != eventSample.end(); ++it ) { + for( std::vector<const TMVA::Event*>::const_iterator it = eventSample.begin(); it != eventSample.end(); ++it ) { if((*it)->GetClass() == fSigClass) { // signal or background event nTotS += (*it)->GetWeight(); ++nTotS_unWeighted; @@ -1501,7 +1497,7 @@ Double_t TMVA::DecisionTree::TrainNodeFull( const vector<TMVA::Event*> & eventSa bdtEventSample.push_back(TMVA::BDTEventWrapper(*it)); } - vector<Char_t> useVariable(fNvars); // <----- bool is stored (for performance reasons, no vector<bool> has been taken) + std::vector<Char_t> useVariable(fNvars); // <----- bool is stored (for performance reasons, no std::vector<bool> has been taken) useVariable.assign( fNvars, Char_t(kTRUE) ); for (UInt_t ivar=0; ivar < fNvars; ivar++) useVariable[ivar]=Char_t(kFALSE); @@ -1530,7 +1526,7 @@ Double_t TMVA::DecisionTree::TrainNodeFull( const vector<TMVA::Event*> & eventSa std::sort( bdtEventSample.begin(),bdtEventSample.end() ); // sort the event data Double_t bkgWeightCtr = 0.0, sigWeightCtr = 0.0; - vector<TMVA::BDTEventWrapper>::iterator it = bdtEventSample.begin(), it_end = bdtEventSample.end(); + std::vector<TMVA::BDTEventWrapper>::iterator it = bdtEventSample.begin(), it_end = bdtEventSample.end(); for( ; it != it_end; ++it ) { if((**it)->GetClass() == fSigClass ) // specify signal or background event sigWeightCtr += (**it)->GetWeight(); @@ -1616,7 +1612,7 @@ TMVA::DecisionTreeNode* TMVA::DecisionTree::GetEventNode(const TMVA::Event & e) } //_______________________________________________________________________ -Double_t TMVA::DecisionTree::CheckEvent( const TMVA::Event & e, Bool_t UseYesNoLeaf ) const +Double_t TMVA::DecisionTree::CheckEvent( const TMVA::Event * e, Bool_t UseYesNoLeaf ) const { // the event e is put into the decision tree (starting at the root node) // and the output is NodeType (signal) or (background) of the final node (basket) @@ -1628,7 +1624,7 @@ Double_t TMVA::DecisionTree::CheckEvent( const TMVA::Event & e, Bool_t UseYesNoL Log() << kFATAL << "CheckEvent: started with undefined ROOT node" <<Endl; while (current->GetNodeType() == 0) { // intermediate node in a (pruned) tree - current = (current->GoesRight(e)) ? + current = (current->GoesRight(*e)) ? current->GetRight() : current->GetLeft(); if (!current) { @@ -1647,7 +1643,7 @@ Double_t TMVA::DecisionTree::CheckEvent( const TMVA::Event & e, Bool_t UseYesNoL } //_______________________________________________________________________ -Double_t TMVA::DecisionTree::SamplePurity( vector<TMVA::Event*> eventSample ) +Double_t TMVA::DecisionTree::SamplePurity( std::vector<TMVA::Event*> eventSample ) { // calculates the purity S/(S+B) of a given event sample @@ -1674,7 +1670,7 @@ vector< Double_t > TMVA::DecisionTree::GetVariableImportance() // evaluated as the total separation-gain that this variable had in // the decision trees (weighted by the number of events) - vector<Double_t> relativeImportance(fNvars); + std::vector<Double_t> relativeImportance(fNvars); Double_t sum=0; for (UInt_t i=0; i< fNvars; i++) { sum += fVariableImportance[i]; @@ -1695,7 +1691,7 @@ Double_t TMVA::DecisionTree::GetVariableImportance( UInt_t ivar ) { // returns the relative improtance of variable ivar - vector<Double_t> relativeImportance = this->GetVariableImportance(); + std::vector<Double_t> relativeImportance = this->GetVariableImportance(); if (ivar < fNvars) return relativeImportance[ivar]; else { Log() << kFATAL << "<GetVariableImportance>" << Endl diff --git a/tmva/src/DecisionTreeNode.cxx b/tmva/src/DecisionTreeNode.cxx index 8575f92a535c4..8965f85358068 100644 --- a/tmva/src/DecisionTreeNode.cxx +++ b/tmva/src/DecisionTreeNode.cxx @@ -67,7 +67,7 @@ TMVA::DecisionTreeNode::DecisionTreeNode() // constructor of an essentially "empty" node floating in space if (!fgLogger) fgLogger = new TMVA::MsgLogger( "DecisionTreeNode" ); - if (fgIsTraining){ + if (DecisionTreeNode::fgIsTraining){ fTrainInfo = new DTNodeTrainingInfo(); //std::cout << "Node constructor with TrainingINFO"<<std::endl; } @@ -92,7 +92,7 @@ TMVA::DecisionTreeNode::DecisionTreeNode(TMVA::Node* p, char pos) // constructor of a daughter node as a daughter of 'p' if (!fgLogger) fgLogger = new TMVA::MsgLogger( "DecisionTreeNode" ); - if (fgIsTraining){ + if (DecisionTreeNode::fgIsTraining){ fTrainInfo = new DTNodeTrainingInfo(); //std::cout << "Node constructor with TrainingINFO"<<std::endl; } @@ -126,7 +126,7 @@ TMVA::DecisionTreeNode::DecisionTreeNode(const TMVA::DecisionTreeNode &n, if (n.GetRight() == 0 ) this->SetRight(NULL); else this->SetRight( new DecisionTreeNode( *((DecisionTreeNode*)(n.GetRight())),this)); - if (fgIsTraining){ + if (DecisionTreeNode::fgIsTraining){ fTrainInfo = new DTNodeTrainingInfo(*(n.fTrainInfo)); //std::cout << "Node constructor with TrainingINFO"<<std::endl; } @@ -195,7 +195,7 @@ void TMVA::DecisionTreeNode::SetPurity( void ) // print a node //_______________________________________________________________________ -void TMVA::DecisionTreeNode::Print(ostream& os) const +void TMVA::DecisionTreeNode::Print(std::ostream& os) const { //print the node os << "< *** " << std::endl; @@ -226,7 +226,7 @@ void TMVA::DecisionTreeNode::Print(ostream& os) const } //_______________________________________________________________________ -void TMVA::DecisionTreeNode::PrintRec(ostream& os) const +void TMVA::DecisionTreeNode::PrintRec(std::ostream& os) const { //recursively print the node and its daughters (--> print the 'tree') @@ -257,7 +257,7 @@ void TMVA::DecisionTreeNode::PrintRec(ostream& os) const } //_______________________________________________________________________ -Bool_t TMVA::DecisionTreeNode::ReadDataRecord( istream& is, UInt_t tmva_Version_Code ) +Bool_t TMVA::DecisionTreeNode::ReadDataRecord( std::istream& is, UInt_t tmva_Version_Code ) { // Read the data block @@ -363,7 +363,7 @@ void TMVA::DecisionTreeNode::ResetValidationData( ) { } //_______________________________________________________________________ -void TMVA::DecisionTreeNode::PrintPrune( ostream& os ) const { +void TMVA::DecisionTreeNode::PrintPrune( std::ostream& os ) const { // printout of the node (can be read in with ReadDataRecord) os << "----------------------" << std::endl @@ -375,7 +375,7 @@ void TMVA::DecisionTreeNode::PrintPrune( ostream& os ) const { } //_______________________________________________________________________ -void TMVA::DecisionTreeNode::PrintRecPrune( ostream& os ) const { +void TMVA::DecisionTreeNode::PrintRecPrune( std::ostream& os ) const { // recursive printout of the node and its daughters this->PrintPrune(os); diff --git a/tmva/src/Event.cxx b/tmva/src/Event.cxx index addf596711c26..9a57189cbbdd3 100644 --- a/tmva/src/Event.cxx +++ b/tmva/src/Event.cxx @@ -36,6 +36,9 @@ #include <cassert> #include "TCut.h" +Bool_t TMVA::Event::fgIsTraining = kFALSE; +Bool_t TMVA::Event::fgIgnoreNegWeightsInTraining = kFALSE; + //____________________________________________________________ TMVA::Event::Event() : fValues(), @@ -143,15 +146,15 @@ TMVA::Event::Event( const Event& event ) UInt_t idx=0; std::vector<Float_t*>::iterator itDyn=event.fValuesDynamic->begin(), itDynEnd=event.fValuesDynamic->end(); for (; itDyn!=itDynEnd && idx<nvar; ++itDyn){ - Float_t value=*(*itDyn); - fValues.push_back( value ); - ++idx; + Float_t value=*(*itDyn); + fValues.push_back( value ); + ++idx; } fSpectators.clear(); for (; itDyn!=itDynEnd; ++itDyn){ - Float_t value=*(*itDyn); - fSpectators.push_back( value ); - ++idx; + Float_t value=*(*itDyn); + fSpectators.push_back( value ); + ++idx; } fDynamic=kFALSE; @@ -178,15 +181,15 @@ void TMVA::Event::CopyVarValues( const Event& other ) UInt_t idx=0; std::vector<Float_t*>::iterator itDyn=other.fValuesDynamic->begin(), itDynEnd=other.fValuesDynamic->end(); for (; itDyn!=itDynEnd && idx<nvar; ++itDyn){ - Float_t value=*(*itDyn); - fValues.push_back( value ); - ++idx; + Float_t value=*(*itDyn); + fValues.push_back( value ); + ++idx; } fSpectators.clear(); for (; itDyn!=itDynEnd; ++itDyn){ - Float_t value=*(*itDyn); - fSpectators.push_back( value ); - ++idx; + Float_t value=*(*itDyn); + fSpectators.push_back( value ); + ++idx; } } fDynamic = kFALSE; @@ -202,8 +205,9 @@ Float_t TMVA::Event::GetValue( UInt_t ivar ) const { // return value of i'th variable Float_t retval; - + // std::cout<< fDynamic ; if (fDynamic){ + // std::cout<< " " << (*fValuesDynamic).size() << " " << fValues.size() << std::endl; retval = *((*fValuesDynamic).at(ivar)); } else{ @@ -294,8 +298,39 @@ void TMVA::Event::SetSpectator( UInt_t ivar, Float_t value ) fSpectators.at(ivar) = value; } +//_____________________________________________________________ +Double_t TMVA::Event::GetWeight() const +{ + // return the event weight - depending on whether the flag + // *IgnoreNegWeightsInTraining* is or not. If it is set AND it is + // used for training, then negetive event weights are set to zero ! + // NOTE! For events used in Testing, the ORIGINAL possibly negative + // event weight is used no matter what + + return (fgIgnoreNegWeightsInTraining && fgIsTraining && fWeight < 0) ? 0. : fWeight*fBoostWeight; +} + +//_____________________________________________________________ +void TMVA::Event::SetIsTraining(Bool_t b) +{ + // when this static function is called, it sets the flag whether + // events with negative event weight should be ignored in the + // training, or not. + + fgIsTraining=b; +} +//_____________________________________________________________ +void TMVA::Event::SetIgnoreNegWeightsInTraining(Bool_t b) +{ + // when this static function is called, it sets the flag whether + // events with negative event weight should be ignored in the + // training, or not. + + fgIgnoreNegWeightsInTraining=b; +} + //_______________________________________________________________________ -ostream& TMVA::operator << ( ostream& os, const TMVA::Event& event ) +std::ostream& TMVA::operator << ( std::ostream& os, const TMVA::Event& event ) { // Outputs the data of an event os << "Variables [" << event.fValues.size() << "]:"; diff --git a/tmva/src/Factory.cxx b/tmva/src/Factory.cxx index 75f28854ba5ab..b7bcc19a5466e 100644 --- a/tmva/src/Factory.cxx +++ b/tmva/src/Factory.cxx @@ -91,7 +91,7 @@ TMVA::Factory::Factory( TString jobName, TFile* theTargetFile, TString theOption : Configurable ( theOption ), fDataSetManager ( NULL ), //DSMTEST fDataInputHandler ( new DataInputHandler ), - fTransformations ( "" ), + fTransformations ( "I" ), fVerbose ( kFALSE ), fJobName ( jobName ), fDataAssignType ( kAssignEvents ), @@ -122,8 +122,14 @@ TMVA::Factory::Factory( TString jobName, TFile* theTargetFile, TString theOption // directory and hence don't go out of scope when closing the file // TH1::AddDirectory(kFALSE); Bool_t silent = kFALSE; +#ifdef WIN32 + // under Windows, switch progress bar and color off by default, as the typical windows shell doesn't handle these (would need different sequences..) + Bool_t color = kFALSE; + Bool_t drawProgressBar = kFALSE; +#else Bool_t color = !gROOT->IsBatch(); Bool_t drawProgressBar = kTRUE; +#endif DeclareOptionRef( fVerbose, "V", "Verbose flag" ); DeclareOptionRef( color, "Color", "Flag for coloured screen output (default: True, if in batch mode: False)" ); DeclareOptionRef( fTransformations, "Transformations", "List of transformations to test; formatting example: \"Transformations=I;D;P;U;G,D\", for identity, decorrelation, PCA, Uniform and Gaussianisation followed by decorrelation transformations" ); @@ -234,6 +240,7 @@ TTree* TMVA::Factory::CreateEventAssignTrees( const TString& name ) { // create the data assignment tree (for event-wise data assignment by user) TTree * assignTree = new TTree( name, name ); + assignTree->SetDirectory(0); assignTree->Branch( "type", &fATreeType, "ATreeType/I" ); assignTree->Branch( "weight", &fATreeWeight, "ATreeWeight/F" ); @@ -736,6 +743,7 @@ TMVA::MethodBase* TMVA::Factory::BookMethod( TString theMethodName, TString meth return 0; } + method->SetAnalysisType( fAnalysisType ); method->SetupMethod(); method->ParseOptions(); @@ -783,6 +791,7 @@ void TMVA::Factory::WriteDataInformation() DefaultDataSetInfo().GetDataSet(); // builds dataset (including calculation of correlation matrix) + // correlation matrix of the default DS const TMatrixD* m(0); const TH2* h(0); @@ -823,7 +832,7 @@ void TMVA::Factory::WriteDataInformation() // some default transformations to evaluate // NOTE: all transformations are destroyed after this test - TString processTrfs = ""; //"I;N;D;P;U;G,D;" + TString processTrfs = "I"; //"I;N;D;P;U;G,D;" // plus some user defined transformations processTrfs = fTransformations; @@ -877,7 +886,7 @@ void TMVA::Factory::OptimizeAllMethods(TString fomType, TString fitType) // iterate over methods and optimize for( itrMethod = fMethods.begin(); itrMethod != fMethods.end(); ++itrMethod ) { - + Event::SetIsTraining(kTRUE); MethodBase* mva = dynamic_cast<MethodBase*>(*itrMethod); if (!mva) { Log() << kFATAL << "Dynamic cast to MethodBase failed" <<Endl; @@ -903,7 +912,7 @@ void TMVA::Factory::OptimizeAllMethods(TString fomType, TString fitType) //_______________________________________________________________________ void TMVA::Factory::TrainAllMethods() -{ +{ // iterates through all booked methods and calls training if(fDataInputHandler->GetEntries() <=1) { // 0 entries --> 0 events, 1 entry --> dynamical dataset (or one entry) @@ -937,7 +946,7 @@ void TMVA::Factory::TrainAllMethods() // iterate over methods and train for( itrMethod = fMethods.begin(); itrMethod != fMethods.end(); ++itrMethod ) { - + Event::SetIsTraining(kTRUE); MethodBase* mva = dynamic_cast<MethodBase*>(*itrMethod); if(mva==0) continue; @@ -1038,6 +1047,7 @@ void TMVA::Factory::TestAllMethods() MVector::iterator itrMethod = fMethods.begin(); MVector::iterator itrMethodEnd = fMethods.end(); for (; itrMethod != itrMethodEnd; itrMethod++) { + Event::SetIsTraining(kFALSE); MethodBase* mva = dynamic_cast<MethodBase*>(*itrMethod); if(mva==0) continue; Types::EAnalysisType analysisType = mva->GetAnalysisType(); @@ -1107,6 +1117,7 @@ void TMVA::Factory::EvaluateAllVariables( TString options ) { // iterates over all MVA input varables and evaluates them Log() << kINFO << "Evaluating all variables..." << Endl; + Event::SetIsTraining(kFALSE); for (UInt_t i=0; i<DefaultDataSetInfo().GetNVariables(); i++) { TString s = DefaultDataSetInfo().GetVariableInfo(i).GetLabel(); @@ -1179,6 +1190,7 @@ void TMVA::Factory::EvaluateAllMethods( void ) MVector::iterator itrMethod = fMethods.begin(); MVector::iterator itrMethodEnd = fMethods.end(); for (; itrMethod != itrMethodEnd; itrMethod++) { + Event::SetIsTraining(kFALSE); MethodBase* theMethod = dynamic_cast<MethodBase*>(*itrMethod); if(theMethod==0) continue; if (theMethod->GetMethodType() != Types::kCuts) methodsNoCuts.push_back( *itrMethod ); @@ -1396,7 +1408,7 @@ void TMVA::Factory::EvaluateAllMethods( void ) DataSet* defDs = DefaultDataSetInfo().GetDataSet(); defDs->SetCurrentType(Types::kTesting); for (Int_t ievt=0; ievt<defDs->GetNEvents(); ievt++) { - Event* ev = defDs->GetEvent(ievt); + const Event* ev = defDs->GetEvent(ievt); // for correlations TMatrixD* theMat = 0; diff --git a/tmva/src/GeneticAlgorithm.cxx b/tmva/src/GeneticAlgorithm.cxx index 789ba6136134e..72c64e9a6e346 100644 --- a/tmva/src/GeneticAlgorithm.cxx +++ b/tmva/src/GeneticAlgorithm.cxx @@ -68,7 +68,7 @@ TMVA::GeneticAlgorithm::GeneticAlgorithm( IFitterTarget& target, Int_t populatio // Parameters: // int populationSize : defines the number of "Individuals" which are created and tested // within one Generation (Iteration of the Evolution) - // vector<TMVA::Interval*> ranges : Interval holds the information of an interval, where the GetMin + // std::vector<TMVA::Interval*> ranges : Interval holds the information of an interval, where the GetMin // gets the low and GetMax gets the high constraint of the variable // the size of "ranges" is the number of coefficients which are optimised // Purpose: diff --git a/tmva/src/GeneticPopulation.cxx b/tmva/src/GeneticPopulation.cxx index e46c85f8c4c89..d88c66165b4a9 100644 --- a/tmva/src/GeneticPopulation.cxx +++ b/tmva/src/GeneticPopulation.cxx @@ -236,7 +236,7 @@ void TMVA::GeneticPopulation::Print( ostream & out, Int_t untilIndex ) vec < fGenePool[it].GetFactors().end(); vec++ ) { out << "f_" << n++ << ": " << (*vec) << " "; } - out << endl; + out << std::endl; } } @@ -251,7 +251,7 @@ TH1F* TMVA::GeneticPopulation::VariableDistribution( Int_t varNumber, Int_t bins // int max : maximum value of the histogram // - cout << "FAILED! TMVA::GeneticPopulation::VariableDistribution" << endl; + std::cout << "FAILED! TMVA::GeneticPopulation::VariableDistribution" << std::endl; std::stringstream histName; histName.clear(); @@ -268,7 +268,7 @@ vector<Double_t> TMVA::GeneticPopulation::VariableDistribution( Int_t /*varNumbe // gives back all the values of coefficient "varNumber" of the current generation // - cout << "FAILED! TMVA::GeneticPopulation::VariableDistribution" << endl; + std::cout << "FAILED! TMVA::GeneticPopulation::VariableDistribution" << std::endl; vector< Double_t > varDist; diff --git a/tmva/src/Interval.cxx b/tmva/src/Interval.cxx index 4dc152aea2f55..e37ac0ac02c5f 100644 --- a/tmva/src/Interval.cxx +++ b/tmva/src/Interval.cxx @@ -133,17 +133,17 @@ Double_t TMVA::Interval::GetElement( Int_t bin ) const } //_______________________________________________________________________ -Double_t TMVA::Interval::GetStepSize( ) const +Double_t TMVA::Interval::GetStepSize( Int_t iBin ) const { // retuns the step size between the numbers of a "discrete Interval" if (fNbins <= 0) { Log() << kFATAL << "GetElement only defined for discrete value Intervals" << Endl; - return 0.0; } - else { - return (fMax-fMin)/(Double_t)(fNbins-1); + if (iBin<0) { + Log() << kFATAL << "You asked for iBin=" << iBin + <<" in interval .. and.. sorry, I cannot let this happen.."<<Endl; } - + return (fMax-fMin)/(Double_t)(fNbins-1); } //_______________________________________________________________________ @@ -153,4 +153,18 @@ Double_t TMVA::Interval::GetRndm( TRandom3& rnd ) const return rnd.Rndm()*(fMax - fMin) + fMin; } +Double_t TMVA::Interval::GetWidth() const +{ + return fMax - fMin; +} +Double_t TMVA::Interval::GetMean() const +{ + return (fMax + fMin)/2; +} +void TMVA::Interval::Print(std::ostream &os) const +{ + for (Int_t i=0; i<GetNbins(); i++){ + os << "| " << GetElement(i)<<" |" ; + } +} diff --git a/tmva/src/LogInterval.cxx b/tmva/src/LogInterval.cxx new file mode 100644 index 0000000000000..6bdbb1c0c20c3 --- /dev/null +++ b/tmva/src/LogInterval.cxx @@ -0,0 +1,152 @@ +/********************************************************************************** + * Project: TMVA - a Root-integrated toolkit for multivariate data analysis * + * Package: TMVA * + * Class : Interval * + * Web : http://tmva.sourceforge.net * + * * + * Description: * + * Extension of the Interval to "logarithmic" invarvals * + * * + * * + * * + * Authors (alphabetical): * + * Helge Voss <helge.voss@cern.ch> - MPI-K Heidelberg, Germany * + * * + * Copyright (c) 2005: * + * CERN, Switzerland * + * MPI-K Heidelberg, Germany * + * * + * Redistribution and use in source and binary forms, with or without * + * modification, are permitted according to the terms listed in LICENSE * + * (http://tmva.sourceforge.net/LICENSE) * + **********************************************************************************/ +/* Begin_Html +<center><h2>the TMVA::Interval Class</h2></center> + +<ul> + <li> LogInterval definition, continuous and discrete + <ul> + <li> LogInterval(min,max) : a continous interval [min,max] + <li> LogInterval(min,max,n): a "discrete interval" [min,max], i.e the n numbers:<br> + 1,10,100,1000 <br> + 1,2,4,8,16,32,64,128,512,1024 <br> + or alike .. <br> + + </ul> +</ul> +<pre> + Example: + LogInterval(1,10000,5) + i=0 --> 1 note: StepSize(ibin=0) = not defined !! + i=1 --> 10 StepSize(ibin=1) = 9 + i=2 --> 100 StepSize(ibin=2) = 99 + i=3 --> 1000 StepSize(ibin=3) = 999 + i=4 --> 10000 StepSize(ibin=4) = 9999 + + LogInterval(1,1000,11) + i=0 --> 1 + i=1 --> 1.99526 + i=2 --> 3.98107 + i=3 --> 7.94328 + i=4 --> 15.8489 + i=5 --> 31.6228 + i=6 --> 63.0957 + i=7 --> 125.893 + i=8 --> 251.189 + i=9 --> 501.187 + i=10 --> 1000 + + LogInterval(1,1024,11) + i=0 --> 1 + i=1 --> 2 + i=2 --> 4 + i=3 --> 8 + i=4 --> 16 + i=5 --> 32 + i=6 --> 64 + i=7 --> 128 + i=8 --> 256 + i=9 --> 512 + i=10 --> 1024 + + +</pre> +End_Html */ + +#include "TMath.h" +#include "TRandom3.h" + +#include "TMVA/LogInterval.h" +#include "TMVA/MsgLogger.h" + +ClassImp(TMVA::LogInterval) + +TMVA::MsgLogger* TMVA::LogInterval::fgLogger = 0; +//_______________________________________________________________________ +TMVA::LogInterval::LogInterval( Double_t min, Double_t max, Int_t nbins ) : +TMVA::Interval(min,max,nbins) +{ + if (!fgLogger) fgLogger = new MsgLogger("LogInterval"); + if (min<=0) Log() << kFATAL << "logarithmic intervals have to have Min>0 !!" << Endl; +} + +TMVA::LogInterval::LogInterval( const LogInterval& other ) : + TMVA::Interval(other) +{ + if (!fgLogger) fgLogger = new MsgLogger("LogInterval"); +} + +//_______________________________________________________________________ +TMVA::LogInterval::~LogInterval() +{ + // destructor +} + +//_______________________________________________________________________ +Double_t TMVA::LogInterval::GetElement( Int_t bin ) const +{ + // calculates the value of the "number" bin in a discrete interval. + // Parameters: + // Double_t position + // + if (fNbins <= 0) { + Log() << kFATAL << "GetElement only defined for discrete value LogIntervals" << Endl; + return 0.0; + } + else if (bin < 0 || bin >= fNbins) { + Log() << kFATAL << "bin " << bin << " out of range: interval *bins* count from 0 to " << fNbins-1 << Endl; + return 0.0; + } + return TMath::Exp(TMath::Log(fMin)+((Double_t)bin) /((Double_t)(fNbins-1))*log(fMax/fMin)); +} + +//_______________________________________________________________________ +Double_t TMVA::LogInterval::GetStepSize( Int_t iBin ) const +{ + // retuns the step size between the numbers of a "discrete LogInterval" + if (fNbins <= 0) { + Log() << kFATAL << "GetElement only defined for discrete value LogIntervals" << Endl; + } + if (iBin<0) { + Log() << kFATAL << "You asked for iBin=" << iBin + <<" in interval .. and.. sorry, I cannot let this happen.."<<Endl; + } + return (GetElement(TMath::Max(iBin,0))-GetElement(TMath::Max(iBin-1,0))); +} + +//_______________________________________________________________________ +Double_t TMVA::LogInterval::GetRndm( TRandom3& rnd ) const +{ + // get uniformely distributed number within interval + return TMath::Exp(rnd.Rndm()*(TMath::Log(fMax/fMin) - TMath::Log(fMin)) + TMath::Log(fMin)); +} + +Double_t TMVA::LogInterval::GetWidth() const +{ + return fMax - fMin; +} +Double_t TMVA::LogInterval::GetMean() const +{ + return (fMax + fMin)/2; +} + diff --git a/tmva/src/MethodANNBase.cxx b/tmva/src/MethodANNBase.cxx index b11aec893bf67..1d75f613af447 100644 --- a/tmva/src/MethodANNBase.cxx +++ b/tmva/src/MethodANNBase.cxx @@ -48,6 +48,7 @@ #include "TRandom3.h" #include "TH2F.h" #include "TH1.h" +#include "TMath.h" #include "TMVA/MethodBase.h" #include "TMVA/MethodANNBase.h" @@ -124,7 +125,7 @@ void TMVA::MethodANNBase::DeclareOptions() TActivationChooser aChooser; - vector<TString>* names = aChooser.GetAllActivationNames(); + std::vector<TString>* names = aChooser.GetAllActivationNames(); Int_t nTypes = names->size(); for (Int_t i = 0; i < nTypes; i++) AddPreDefVal(names->at(i)); @@ -146,17 +147,17 @@ void TMVA::MethodANNBase::ProcessOptions() if ( DoRegression() || DoMulticlass()) fEstimatorS = "MSE"; //zjh if (fEstimatorS == "MSE" ) fEstimator = kMSE; else if (fEstimatorS == "CE") fEstimator = kCE; //zjh - vector<Int_t>* layout = ParseLayoutString(fLayerSpec); + std::vector<Int_t>* layout = ParseLayoutString(fLayerSpec); BuildNetwork(layout); delete layout; } //______________________________________________________________________________ -vector<Int_t>* TMVA::MethodANNBase::ParseLayoutString(TString layerSpec) +std::vector<Int_t>* TMVA::MethodANNBase::ParseLayoutString(TString layerSpec) { // parse layout specification string and return a vector, each entry // containing the number of neurons to go in each successive layer - vector<Int_t>* layout = new vector<Int_t>(); + std::vector<Int_t>* layout = new std::vector<Int_t>(); layout->push_back((Int_t)GetNvar()); while(layerSpec.Length()>0) { TString sToAdd=""; @@ -268,7 +269,7 @@ void TMVA::MethodANNBase::DeleteNetworkLayer( TObjArray*& layer ) } //______________________________________________________________________________ -void TMVA::MethodANNBase::BuildNetwork( vector<Int_t>* layout, vector<Double_t>* weights, Bool_t fromFile ) +void TMVA::MethodANNBase::BuildNetwork( std::vector<Int_t>* layout, std::vector<Double_t>* weights, Bool_t fromFile ) { // build network given a layout (number of neurons in each layer) // and optional weights array @@ -309,8 +310,11 @@ void TMVA::MethodANNBase::BuildNetwork( vector<Int_t>* layout, vector<Double_t>* else ForceWeights(weights); } + + + //______________________________________________________________________________ -void TMVA::MethodANNBase::BuildLayers( vector<Int_t>* layout, Bool_t fromFile ) +void TMVA::MethodANNBase::BuildLayers( std::vector<Int_t>* layout, Bool_t fromFile ) { // build the network layers @@ -432,7 +436,7 @@ void TMVA::MethodANNBase::InitWeights() } //_______________________________________________________________________ -void TMVA::MethodANNBase::ForceWeights(vector<Double_t>* weights) +void TMVA::MethodANNBase::ForceWeights(std::vector<Double_t>* weights) { // force the synapse weights PrintMessage("Forcing weights"); @@ -498,9 +502,9 @@ void TMVA::MethodANNBase::PrintMessage(TString message, Bool_t force) const void TMVA::MethodANNBase::WaitForKeyboard() { // wait for keyboard input, for debugging - string dummy; + std::string dummy; Log() << kINFO << "***Type anything to continue (q to quit): "; - getline(cin, dummy); + std::getline(std::cin, dummy); if (dummy == "q" || dummy == "Q") { PrintMessage( "quit" ); delete this; @@ -627,6 +631,14 @@ const std::vector<Float_t> &TMVA::MethodANNBase::GetRegressionValues() return *fRegressionReturnVal; } + + + + + + + + //_______________________________________________________________________ const std::vector<Float_t> &TMVA::MethodANNBase::GetMulticlassValues() { @@ -662,6 +674,8 @@ const std::vector<Float_t> &TMVA::MethodANNBase::GetMulticlassValues() } (*fMulticlassReturnVal).push_back(1.0/(1.0+norm)); } + + return *fMulticlassReturnVal; } @@ -688,7 +702,7 @@ void TMVA::MethodANNBase::AddWeightsXMLTo( void* parent ) const void* neuronxml = gTools().AddChild(layerxml, "Neuron"); gTools().AddAttr(neuronxml, "NSynapses", gTools().StringFromInt(numSynapses) ); if(numSynapses==0) continue; - stringstream s(""); + std::stringstream s(""); s.precision( 16 ); for (Int_t k = 0; k < numSynapses; k++) { TSynapse* synapse = neuron->PostLinkAt(k); @@ -721,7 +735,7 @@ void TMVA::MethodANNBase::AddWeightsXMLTo( void* parent ) const gTools().xmlengine().NewAttr(xmlRow, 0, "Index", gTools().StringFromInt(row) ); // create the rows - stringstream s(""); + std::stringstream s(""); s.precision( 16 ); for( Int_t col = 0; col < nCols; ++col ){ s << std::scientific << (*(elements+index)) << " "; @@ -741,7 +755,7 @@ void TMVA::MethodANNBase::ReadWeightsFromXML( void* wghtnode ) // build the layout first Bool_t fromFile = kTRUE; - vector<Int_t>* layout = new vector<Int_t>(); + std::vector<Int_t>* layout = new std::vector<Int_t>(); void* xmlLayout = NULL; xmlLayout = gTools().GetChild(wghtnode, "Layout"); @@ -845,7 +859,7 @@ void TMVA::MethodANNBase::ReadWeightsFromXML( void* wghtnode ) //_______________________________________________________________________ -void TMVA::MethodANNBase::ReadWeightsFromStream( istream & istr) +void TMVA::MethodANNBase::ReadWeightsFromStream( std::istream & istr) { // destroy/clear the network then read it back in from the weights file @@ -855,7 +869,7 @@ void TMVA::MethodANNBase::ReadWeightsFromStream( istream & istr) // synapse weights Double_t weight; - vector<Double_t>* weights = new vector<Double_t>(); + std::vector<Double_t>* weights = new std::vector<Double_t>(); istr>> dummy; while (istr>> dummy >> weight) weights->push_back(weight); // use w/ slower write-out @@ -890,8 +904,10 @@ const TMVA::Ranking* TMVA::MethodANNBase::CreateRanking() Statistics( TMVA::Types::kTraining, varName, meanS, meanB, rmsS, rmsB, xmin, xmax ); - avgVal = (meanS + meanB) / 2.0; // change this into a real weighted average - if (IsNormalised()) avgVal = 0.5*(1 + gTools().NormVariable( avgVal, GetXmin( ivar ), GetXmax( ivar ))); + avgVal = (TMath::Abs(meanS) + TMath::Abs(meanB))/2.0; + double meanrms = (TMath::Abs(rmsS) + TMath::Abs(rmsB))/2.; + if (avgVal<meanrms) avgVal = meanrms; + if (IsNormalised()) avgVal = 0.5*(1 + gTools().NormVariable( avgVal, GetXmin( ivar ), GetXmax( ivar ))); for (Int_t j = 0; j < numSynapses; j++) { synapse = neuron->PostLinkAt(j); @@ -988,38 +1004,38 @@ void TMVA::MethodANNBase::MakeClassSpecific( std::ostream& fout, const TString& // write specific classifier response Int_t numLayers = fNetwork->GetEntries(); - fout << endl; - fout << " double ActivationFnc(double x) const;" << endl; - fout << " double OutputActivationFnc(double x) const;" << endl; //zjh - fout << endl; - fout << " int fLayers;" << endl; - fout << " int fLayerSize["<<numLayers<<"];" << endl; + fout << std::endl; + fout << " double ActivationFnc(double x) const;" << std::endl; + fout << " double OutputActivationFnc(double x) const;" << std::endl; //zjh + fout << std::endl; + fout << " int fLayers;" << std::endl; + fout << " int fLayerSize["<<numLayers<<"];" << std::endl; int numNodesFrom = -1; for (Int_t lIdx = 0; lIdx < numLayers; lIdx++) { int numNodesTo = ((TObjArray*)fNetwork->At(lIdx))->GetEntries(); if (numNodesFrom<0) { numNodesFrom=numNodesTo; continue; } fout << " double fWeightMatrix" << lIdx-1 << "to" << lIdx << "[" << numNodesTo << "][" << numNodesFrom << "];"; - fout << " // weight matrix from layer " << lIdx-1 << " to " << lIdx << endl; + fout << " // weight matrix from layer " << lIdx-1 << " to " << lIdx << std::endl; numNodesFrom = numNodesTo; } - fout << endl; - fout << " double * fWeights["<<numLayers<<"];" << endl; - fout << "};" << endl; + fout << std::endl; + fout << " double * fWeights["<<numLayers<<"];" << std::endl; + fout << "};" << std::endl; - fout << endl; + fout << std::endl; - fout << "inline void " << className << "::Initialize()" << endl; - fout << "{" << endl; - fout << " // build network structure" << endl; - fout << " fLayers = " << numLayers << ";" << endl; + fout << "inline void " << className << "::Initialize()" << std::endl; + fout << "{" << std::endl; + fout << " // build network structure" << std::endl; + fout << " fLayers = " << numLayers << ";" << std::endl; for (Int_t lIdx = 0; lIdx < numLayers; lIdx++) { TObjArray* layer = (TObjArray*)fNetwork->At(lIdx); int numNodes = layer->GetEntries(); - fout << " fLayerSize[" << lIdx << "] = " << numNodes << "; fWeights["<<lIdx<<"] = new double["<<numNodes<<"]; " << endl; + fout << " fLayerSize[" << lIdx << "] = " << numNodes << "; fWeights["<<lIdx<<"] = new double["<<numNodes<<"]; " << std::endl; } for (Int_t i = 0; i < numLayers-1; i++) { - fout << " // weight matrix from layer " << i << " to " << i+1 << endl; + fout << " // weight matrix from layer " << i << " to " << i+1 << std::endl; TObjArray* layer = (TObjArray*)fNetwork->At(i); Int_t numNeurons = layer->GetEntriesFast(); for (Int_t j = 0; j < numNeurons; j++) { @@ -1027,73 +1043,76 @@ void TMVA::MethodANNBase::MakeClassSpecific( std::ostream& fout, const TString& Int_t numSynapses = neuron->NumPostLinks(); for (Int_t k = 0; k < numSynapses; k++) { TSynapse* synapse = neuron->PostLinkAt(k); - fout << " fWeightMatrix" << i << "to" << i+1 << "[" << k << "][" << j << "] = " << synapse->GetWeight() << ";" << endl; + fout << " fWeightMatrix" << i << "to" << i+1 << "[" << k << "][" << j << "] = " << synapse->GetWeight() << ";" << std::endl; } } } - fout << "}" << endl; - fout << endl; + fout << "}" << std::endl; + fout << std::endl; // writing of the GetMvaValue__ method - fout << "inline double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << endl; - fout << "{" << endl; - fout << " if (inputValues.size() != (unsigned int)fLayerSize[0]-1) {" << endl; - fout << " std::cout << \"Input vector needs to be of size \" << fLayerSize[0]-1 << std::endl;" << endl; - fout << " return 0;" << endl; - fout << " }" << endl; - fout << endl; - fout << " for (int l=0; l<fLayers; l++)" << endl; - fout << " for (int i=0; i<fLayerSize[l]; i++) fWeights[l][i]=0;" << endl; - fout << endl; - fout << " for (int l=0; l<fLayers-1; l++)" << endl; - fout << " fWeights[l][fLayerSize[l]-1]=1;" << endl; - fout << endl; - fout << " for (int i=0; i<fLayerSize[0]-1; i++)" << endl; - fout << " fWeights[0][i]=inputValues[i];" << endl; - fout << endl; + fout << "inline double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << std::endl; + fout << "{" << std::endl; + fout << " if (inputValues.size() != (unsigned int)fLayerSize[0]-1) {" << std::endl; + fout << " std::cout << \"Input vector needs to be of size \" << fLayerSize[0]-1 << std::endl;" << std::endl; + fout << " return 0;" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " for (int l=0; l<fLayers; l++)" << std::endl; + fout << " for (int i=0; i<fLayerSize[l]; i++) fWeights[l][i]=0;" << std::endl; + fout << std::endl; + fout << " for (int l=0; l<fLayers-1; l++)" << std::endl; + fout << " fWeights[l][fLayerSize[l]-1]=1;" << std::endl; + fout << std::endl; + fout << " for (int i=0; i<fLayerSize[0]-1; i++)" << std::endl; + fout << " fWeights[0][i]=inputValues[i];" << std::endl; + fout << std::endl; for (Int_t i = 0; i < numLayers-1; i++) { - fout << " // layer " << i << " to " << i+1 << endl; + fout << " // layer " << i << " to " << i+1 << std::endl; if (i+1 == numLayers-1) { - fout << " for (int o=0; o<fLayerSize[" << i+1 << "]; o++) {" << endl; + fout << " for (int o=0; o<fLayerSize[" << i+1 << "]; o++) {" << std::endl; } else { - fout << " for (int o=0; o<fLayerSize[" << i+1 << "]-1; o++) {" << endl; + fout << " for (int o=0; o<fLayerSize[" << i+1 << "]-1; o++) {" << std::endl; } - fout << " for (int i=0; i<fLayerSize[" << i << "]; i++) {" << endl; - fout << " double inputVal = fWeightMatrix" << i << "to" << i+1 << "[o][i] * fWeights[" << i << "][i];" << endl; + fout << " for (int i=0; i<fLayerSize[" << i << "]; i++) {" << std::endl; + fout << " double inputVal = fWeightMatrix" << i << "to" << i+1 << "[o][i] * fWeights[" << i << "][i];" << std::endl; if ( fNeuronInputType == "sum") { - fout << " fWeights[" << i+1 << "][o] += inputVal;" << endl; + fout << " fWeights[" << i+1 << "][o] += inputVal;" << std::endl; } else if ( fNeuronInputType == "sqsum") { - fout << " fWeights[" << i+1 << "][o] += inputVal*inputVal;" << endl; + fout << " fWeights[" << i+1 << "][o] += inputVal*inputVal;" << std::endl; } else { // fNeuronInputType == TNeuronInputChooser::kAbsSum - fout << " fWeights[" << i+1 << "][o] += fabs(inputVal);" << endl; + fout << " fWeights[" << i+1 << "][o] += fabs(inputVal);" << std::endl; } - fout << " }" << endl; + fout << " }" << std::endl; if (i+1 != numLayers-1) // in the last layer no activation function is applied - fout << " fWeights[" << i+1 << "][o] = ActivationFnc(fWeights[" << i+1 << "][o]);" << endl; - else fout << " fWeights[" << i+1 << "][o] = OutputActivationFnc(fWeights[" << i+1 << "][o]);" << endl; //zjh - fout << " }" << endl; + fout << " fWeights[" << i+1 << "][o] = ActivationFnc(fWeights[" << i+1 << "][o]);" << std::endl; + else fout << " fWeights[" << i+1 << "][o] = OutputActivationFnc(fWeights[" << i+1 << "][o]);" << std::endl; //zjh + fout << " }" << std::endl; } - fout << endl; - fout << " return fWeights[" << numLayers-1 << "][0];" << endl; - fout << "}" << endl; + fout << std::endl; + fout << " return fWeights[" << numLayers-1 << "][0];" << std::endl; + fout << "}" << std::endl; - fout << endl; + fout << std::endl; TString fncName = className+"::ActivationFnc"; fActivation->MakeFunction(fout, fncName); fncName = className+"::OutputActivationFnc"; //zjh fOutput->MakeFunction(fout, fncName); //zjh - fout << " " << endl; - fout << "// Clean up" << endl; - fout << "inline void " << className << "::Clear() " << endl; - fout << "{" << endl; - fout << " // nothing to clear" << endl; - fout << "}" << endl; + fout << " " << std::endl; + fout << "// Clean up" << std::endl; + fout << "inline void " << className << "::Clear() " << std::endl; + fout << "{" << std::endl; + fout << " // clean up the arrays" << std::endl; + fout << " for (int lIdx = 0; lIdx < "<<numLayers<<"; lIdx++) {" << std::endl; + fout << " delete[] fWeights[lIdx];" << std::endl; + fout << " }" << std::endl; + fout << "}" << std::endl; } //_________________________________________________________________________ diff --git a/tmva/src/MethodBDT.cxx b/tmva/src/MethodBDT.cxx index 84147ef201032..87891c78f41e9 100644 --- a/tmva/src/MethodBDT.cxx +++ b/tmva/src/MethodBDT.cxx @@ -111,7 +111,6 @@ #include "Riostream.h" #include "TRandom3.h" -#include "TRandom3.h" #include "TMath.h" #include "TObjString.h" #include "TGraph.h" @@ -131,9 +130,14 @@ #include "TMVA/Results.h" #include "TMVA/ResultsMulticlass.h" #include "TMVA/Interval.h" +#include "TMVA/LogInterval.h" #include "TMVA/PDF.h" +#include "TMVA/BDTEventWrapper.h" + +#include "TMatrixTSym.h" using std::vector; +using std::make_pair; REGISTER_METHOD(BDT) @@ -148,43 +152,49 @@ TMVA::MethodBDT::MethodBDT( const TString& jobName, const TString& theOption, TDirectory* theTargetDir ) : TMVA::MethodBase( jobName, Types::kBDT, methodTitle, theData, theOption, theTargetDir ) + , fTrainSample(0) , fNTrees(0) - , fRenormByClass(0) // don't use this initialisation, only here to make Coverity happy. Is set in DeclarOptions() + , fSigToBkgFraction(0) , fAdaBoostBeta(0) , fTransitionPoint(0) , fShrinkage(0) + , fBaggedBoost(kFALSE) , fBaggedGradBoost(kFALSE) - , fSampleFraction(0) , fSumOfWeights(0) - , fNodeMinEvents(0) + , fMinNodeEvents(0) + , fMinNodeSize(5) + , fMinNodeSizeS("5%") , fNCuts(0) , fUseFisherCuts(0) // don't use this initialisation, only here to make Coverity happy. Is set in DeclarOptions() , fMinLinCorrForFisher(.8) // don't use this initialisation, only here to make Coverity happy. Is set in DeclarOptions() , fUseExclusiveVars(0) // don't use this initialisation, only here to make Coverity happy. Is set in DeclarOptions() , fUseYesNoLeaf(kFALSE) , fNodePurityLimit(0) - , fUseWeightedTrees(kFALSE) , fNNodesMax(0) , fMaxDepth(0) , fPruneMethod(DecisionTree::kNoPruning) , fPruneStrength(0) - , fPruneBeforeBoost(kFALSE) , fFValidationEvents(0) , fAutomatic(kFALSE) , fRandomisedTrees(kFALSE) , fUseNvars(0) , fUsePoissonNvars(0) // don't use this initialisation, only here to make Coverity happy. Is set in Init() , fUseNTrainEvents(0) - , fSampleSizeFraction(0) + , fBaggedSampleFraction(0) , fNoNegWeightsInTraining(kFALSE) , fInverseBoostNegWeights(kFALSE) , fPairNegWeightsGlobal(kFALSE) - , fPairNegWeightsInNode(kFALSE) , fTrainWithNegWeights(kFALSE) , fDoBoostMonitor(kFALSE) , fITree(0) , fBoostWeight(0) , fErrorFraction(0) + , fCss(0) + , fCts_sb(0) + , fCtb_ss(0) + , fCbb(0) + , fDoPreselection(kFALSE) + { // the standard constructor for the "boosted decision trees" fMonitorNtuple = NULL; @@ -196,43 +206,48 @@ TMVA::MethodBDT::MethodBDT( DataSetInfo& theData, const TString& theWeightFile, TDirectory* theTargetDir ) : TMVA::MethodBase( Types::kBDT, theData, theWeightFile, theTargetDir ) + , fTrainSample(0) , fNTrees(0) - , fRenormByClass(0) // don't use this initialisation, only here to make Coverity happy. Is set in DeclarOptions() + , fSigToBkgFraction(0) , fAdaBoostBeta(0) , fTransitionPoint(0) , fShrinkage(0) + , fBaggedBoost(kFALSE) , fBaggedGradBoost(kFALSE) - , fSampleFraction(0) , fSumOfWeights(0) - , fNodeMinEvents(0) + , fMinNodeEvents(0) + , fMinNodeSize(5) + , fMinNodeSizeS("5%") , fNCuts(0) , fUseFisherCuts(0) // don't use this initialisation, only here to make Coverity happy. Is set in DeclarOptions() , fMinLinCorrForFisher(.8) // don't use this initialisation, only here to make Coverity happy. Is set in DeclarOptions() , fUseExclusiveVars(0) // don't use this initialisation, only here to make Coverity happy. Is set in DeclarOptions() , fUseYesNoLeaf(kFALSE) , fNodePurityLimit(0) - , fUseWeightedTrees(kFALSE) , fNNodesMax(0) , fMaxDepth(0) , fPruneMethod(DecisionTree::kNoPruning) , fPruneStrength(0) - , fPruneBeforeBoost(kFALSE) , fFValidationEvents(0) , fAutomatic(kFALSE) , fRandomisedTrees(kFALSE) , fUseNvars(0) , fUsePoissonNvars(0) // don't use this initialisation, only here to make Coverity happy. Is set in Init() , fUseNTrainEvents(0) - , fSampleSizeFraction(0) + , fBaggedSampleFraction(0) , fNoNegWeightsInTraining(kFALSE) , fInverseBoostNegWeights(kFALSE) , fPairNegWeightsGlobal(kFALSE) - , fPairNegWeightsInNode(kFALSE) , fTrainWithNegWeights(kFALSE) , fDoBoostMonitor(kFALSE) , fITree(0) , fBoostWeight(0) , fErrorFraction(0) + , fCss(0) + , fCts_sb(0) + , fCtb_ss(0) + , fCbb(0) + , fDoPreselection(kFALSE) { fMonitorNtuple = NULL; fSepType = NULL; @@ -267,13 +282,12 @@ void TMVA::MethodBDT::DeclareOptions() // UseRandomisedTrees choose at each node splitting a random set of variables // UseNvars use UseNvars variables in randomised trees // UsePoission Nvars use UseNvars not as fixed number but as mean of a possion distribution - // UseNTrainEvents number of training events used in randomised (and bagged) trees // SeparationType the separation criterion applied in the node splitting // known: GiniIndex // MisClassificationError // CrossEntropy // SDivSqrtSPlusB - // nEventsMin: the minimum number of events in a node (leaf criteria, stop splitting) + // MinNodeSize: minimum percentage of training events in a leaf node (leaf criteria, stop splitting) // nCuts: the number of steps in the optimisation of the cut for a node (if < 0, then // step size is determined by the events) // UseFisherCuts: use multivariate splits using the Fisher criterion @@ -281,28 +295,36 @@ void TMVA::MethodBDT::DeclareOptions() // (from the training) in the leaf node // NodePurityLimit the minimum purity to classify a node as a signal node (used in pruning and boosting to determine // misclassification error rate) - // UseWeightedTrees use average classification from the trees, or have the individual trees - // trees in the forest weighted (e.g. log(boostweight) from AdaBoost // PruneMethod The Pruning method: // known: NoPruning // switch off pruning completely // ExpectedError // CostComplexity // PruneStrength a parameter to adjust the amount of pruning. Should be large enough such that overtraining is avoided. - // PruneBeforeBoost flag to prune the tree before applying boosting algorithm // PruningValFraction number of events to use for optimizing pruning (only if PruneStrength < 0, i.e. automatic pruning) // NegWeightTreatment IgnoreNegWeightsInTraining Ignore negative weight events in the training. // DecreaseBoostWeight Boost ev. with neg. weight with 1/boostweight instead of boostweight // PairNegWeightsGlobal Pair ev. with neg. and pos. weights in traning sample and "annihilate" them - // PairNegWeightsInNode Randomly pair miscl. ev. with neg. and pos. weights in node and don't boost them - // NNodesMax maximum number of nodes allwed in the tree splitting, then it stops. // MaxDepth maximum depth of the decision tree allowed before further splitting is stopped DeclareOptionRef(fNTrees, "NTrees", "Number of trees in the forest"); - DeclareOptionRef(fRenormByClass=kFALSE,"RenormByClass","Individually re-normalize each event class to the original size after boosting"); - DeclareOptionRef(fBoostType, "BoostType", "Boosting type for the trees in the forest"); + if (DoRegression()) { + DeclareOptionRef(fMaxDepth=50,"MaxDepth","Max depth of the decision tree allowed"); + }else{ + DeclareOptionRef(fMaxDepth=3,"MaxDepth","Max depth of the decision tree allowed"); + } + + TString tmp="5%"; if (DoRegression()) tmp="0.2%"; + DeclareOptionRef(fMinNodeSizeS=tmp, "MinNodeSize", "Minimum percentage of training events required in a leaf node (default: Classification: 5%, Regression: 0.2%)"); + // MinNodeSize: minimum percentage of training events in a leaf node (leaf criteria, stop splitting) + DeclareOptionRef(fNCuts, "nCuts", "Number of grid points in variable range used in finding optimal cut in node splitting"); + + DeclareOptionRef(fBoostType, "BoostType", "Boosting type for the trees in the forest (note: AdaCost is still experimental)"); + AddPreDefVal(TString("AdaBoost")); + AddPreDefVal(TString("RealAdaBoost")); + AddPreDefVal(TString("AdaCost")); AddPreDefVal(TString("Bagging")); - AddPreDefVal(TString("RegBoost")); + // AddPreDefVal(TString("RegBoost")); AddPreDefVal(TString("AdaBoostR2")); AddPreDefVal(TString("Grad")); if (DoRegression()) { @@ -310,30 +332,42 @@ void TMVA::MethodBDT::DeclareOptions() }else{ fBoostType = "AdaBoost"; } - DeclareOptionRef(fAdaBoostR2Loss="Quadratic", "AdaBoostR2Loss", "Type of Loss function in AdaBoostR2t (Linear,Quadratic or Exponential)"); + DeclareOptionRef(fAdaBoostR2Loss="Quadratic", "AdaBoostR2Loss", "Type of Loss function in AdaBoostR2"); AddPreDefVal(TString("Linear")); AddPreDefVal(TString("Quadratic")); AddPreDefVal(TString("Exponential")); - DeclareOptionRef(fBaggedGradBoost=kFALSE, "UseBaggedGrad","Use only a random subsample of all events for growing the trees in each iteration. (Only valid for GradBoost)"); - DeclareOptionRef(fSampleFraction=0.6, "GradBaggingFraction","Defines the fraction of events to be used in each iteration when UseBaggedGrad=kTRUE. (Only valid for GradBoost)"); + DeclareOptionRef(fBaggedBoost=kFALSE, "UseBaggedBoost","Use only a random subsample of all events for growing the trees in each boost iteration."); DeclareOptionRef(fShrinkage=1.0, "Shrinkage", "Learning rate for GradBoost algorithm"); - DeclareOptionRef(fAdaBoostBeta=1.0, "AdaBoostBeta", "Parameter for AdaBoost algorithm"); - DeclareOptionRef(fRandomisedTrees,"UseRandomisedTrees","Choose at each node splitting a random set of variables"); - DeclareOptionRef(fUseNvars,"UseNvars","Number of variables used if randomised tree option is chosen"); - DeclareOptionRef(fUsePoissonNvars,"UsePoissonNvars", "Interpret \"UseNvars\" not as fixed number but as mean of a Possion distribution in each split"); - DeclareOptionRef(fUseNTrainEvents,"UseNTrainEvents","Number of randomly picked training events used in randomised (and bagged) trees"); + DeclareOptionRef(fAdaBoostBeta=.5, "AdaBoostBeta", "Learning rate for AdaBoost algorithm"); + DeclareOptionRef(fRandomisedTrees,"UseRandomisedTrees","Determine at each node splitting the cut variable only as the best out of a random subset of variables (like in RandomForests)"); + DeclareOptionRef(fUseNvars,"UseNvars","Size of the subset of variables used with RandomisedTree option"); + DeclareOptionRef(fUsePoissonNvars,"UsePoissonNvars", "Interpret \"UseNvars\" not as fixed number but as mean of a Possion distribution in each split with RandomisedTree option"); + DeclareOptionRef(fBaggedSampleFraction=.6,"BaggedSampleFraction","Relative size of bagged event sample to original size of the data sample (used whenever bagging is used (i.e. UseBaggedBoost, Bagging,)" ); - DeclareOptionRef(fUseWeightedTrees=kTRUE, "UseWeightedTrees", - "Use weighted trees or simple average in classification from the forest"); DeclareOptionRef(fUseYesNoLeaf=kTRUE, "UseYesNoLeaf", - "Use Sig or Bkg categories, or the purity=S/(S+B) as classification of the leaf node"); + "Use Sig or Bkg categories, or the purity=S/(S+B) as classification of the leaf node -> Real-AdaBoost"); if (DoRegression()) { fUseYesNoLeaf = kFALSE; } + DeclareOptionRef(fNegWeightTreatment="InverseBoostNegWeights","NegWeightTreatment","How to treat events with negative weights in the BDT training (particular the boosting) : IgnoreInTraining; Boost With inverse boostweight; Pair events with negative and positive weights in traning sample and *annihilate* them (experimental!)"); + AddPreDefVal(TString("InverseBoostNegWeights")); + AddPreDefVal(TString("IgnoreNegWeightsInTraining")); + AddPreDefVal(TString("NoNegWeightsInTraining")); // well, let's be nice to users and keep at least this old name anyway .. + AddPreDefVal(TString("PairNegWeightsGlobal")); + AddPreDefVal(TString("Pray")); + + + + DeclareOptionRef(fCss=1., "Css", "AdaCost: cost of true signal selected signal"); + DeclareOptionRef(fCts_sb=1.,"Cts_sb","AdaCost: cost of true signal selected bkg"); + DeclareOptionRef(fCtb_ss=1.,"Ctb_ss","AdaCost: cost of true bkg selected signal"); + DeclareOptionRef(fCbb=1., "Cbb", "AdaCost: cost of true bkg selected bkg "); DeclareOptionRef(fNodePurityLimit=0.5, "NodePurityLimit", "In boosting/pruning, nodes with purity > NodePurityLimit are signal; background otherwise."); + + DeclareOptionRef(fSepTypeS, "SeparationType", "Separation criterion for node splitting"); AddPreDefVal(TString("CrossEntropy")); AddPreDefVal(TString("GiniIndex")); @@ -346,39 +380,52 @@ void TMVA::MethodBDT::DeclareOptions() }else{ fSepTypeS = "GiniIndex"; } - DeclareOptionRef(fNodeMinEvents, "nEventsMin", "Minimum number of events required in a leaf node (default: Classification: max(40, N_train/(Nvar^2)/10), Regression: 10)"); - DeclareOptionRef(fNCuts, "nCuts", "Number of steps during node cut optimisation"); + + DeclareOptionRef(fDoBoostMonitor=kFALSE,"DoBoostMonitor","Create control plot with ROC integral vs tree number"); + DeclareOptionRef(fUseFisherCuts=kFALSE, "UseFisherCuts", "Use multivariate splits using the Fisher criterion"); DeclareOptionRef(fMinLinCorrForFisher=.8,"MinLinCorrForFisher", "The minimum linear correlation between two variables demanded for use in Fisher criterion in node splitting"); DeclareOptionRef(fUseExclusiveVars=kFALSE,"UseExclusiveVars","Variables already used in fisher criterion are not anymore analysed individually for node splitting"); - DeclareOptionRef(fPruneStrength, "PruneStrength", "Pruning strength"); - DeclareOptionRef(fPruneMethodS, "PruneMethod", "Method used for pruning (removal) of statistically insignificant branches"); + + DeclareOptionRef(fDoPreselection=kFALSE,"DoPreselection","and and apply automatic pre-selection for 100% efficient signal (bkg) cuts prior to training"); + + + DeclareOptionRef(fSigToBkgFraction=1,"SigToBkgFraction","Sig to Bkg ratio used in Training (similar to NodePurityLimit, which cannot be used in real adaboost"); + + DeclareOptionRef(fPruneMethodS, "PruneMethod", "Note: for BDTs use small trees (e.g.MaxDepth=3) and NoPruning: Pruning: Method used for pruning (removal) of statistically insignificant branches "); AddPreDefVal(TString("NoPruning")); AddPreDefVal(TString("ExpectedError")); AddPreDefVal(TString("CostComplexity")); - DeclareOptionRef(fPruneBeforeBoost=kFALSE, "PruneBeforeBoost", "Flag to prune the tree before applying boosting algorithm"); + + DeclareOptionRef(fPruneStrength, "PruneStrength", "Pruning strength"); + DeclareOptionRef(fFValidationEvents=0.5, "PruningValFraction", "Fraction of events to use for optimizing automatic pruning."); - DeclareOptionRef(fNNodesMax=100000,"NNodesMax","Max number of nodes in tree"); - if (DoRegression()) { - DeclareOptionRef(fMaxDepth=50,"MaxDepth","Max depth of the decision tree allowed"); - }else{ - DeclareOptionRef(fMaxDepth=3,"MaxDepth","Max depth of the decision tree allowed"); - } - DeclareOptionRef(fDoBoostMonitor=kFALSE,"DoBoostMonitor","Create control plot with ROC integral vs tree number"); - DeclareOptionRef(fNegWeightTreatment="InverseBoostNegWeights","NegWeightTreatment","How to treat events with negative weights in the BDT training (particular the boosting) : Ignore; Boost With inverse boostweight; Pair events with negative and positive weights in traning sample and *annihilate* them (experimental!); Randomly pair events with negative and positive weights in leaf node and do not boost them (experimental!) "); - AddPreDefVal(TString("IgnoreNegWeights")); - AddPreDefVal(TString("NoNegWeightsInTraining")); - AddPreDefVal(TString("InverseBoostNegWeights")); - AddPreDefVal(TString("PairNegWeightsGlobal")); - AddPreDefVal(TString("PairNegWeightsInNode")); + // deprecated options, still kept for the moment: + DeclareOptionRef(fMinNodeEvents=0, "nEventsMin", "deprecated: Use MinNodeSize (in % of training events) instead"); + + DeclareOptionRef(fBaggedGradBoost=kFALSE, "UseBaggedGrad","deprecated: Use *UseBaggedBoost* instead: Use only a random subsample of all events for growing the trees in each iteration."); + DeclareOptionRef(fBaggedSampleFraction, "GradBaggingFraction","deprecated: Use *BaggedSampleFraction* instead: Defines the fraction of events to be used in each iteration, e.g. when UseBaggedGrad=kTRUE. "); + DeclareOptionRef(fUseNTrainEvents,"UseNTrainEvents","deprecated: Use *BaggedSampleFraction* instead: Number of randomly picked training events used in randomised (and bagged) trees"); + DeclareOptionRef(fNNodesMax,"NNodesMax","deprecated: Use MaxDepth instead to limit the tree size" ); + } +//_______________________________________________________________________ void TMVA::MethodBDT::DeclareCompatibilityOptions() { + // options that are used ONLY for the READER to ensure backward compatibility + MethodBase::DeclareCompatibilityOptions(); - DeclareOptionRef(fSampleSizeFraction=1.0,"SampleSizeFraction","Relative size of bagged event sample to original size of the data sample" ); + + + DeclareOptionRef(fHistoricBool=kTRUE, "UseWeightedTrees", + "Use weighted trees or simple average in classification from the forest"); + DeclareOptionRef(fHistoricBool=kFALSE, "PruneBeforeBoost", "Flag to prune the tree before applying boosting algorithm"); + DeclareOptionRef(fHistoricBool=kFALSE,"RenormByClass","Individually re-normalize each event class to the original size after boosting"); + + AddPreDefVal(TString("NegWeightTreatment"),TString("IgnoreNegWeights")); } @@ -416,16 +463,41 @@ void TMVA::MethodBDT::ProcessOptions() Log() << kFATAL << "Sorry autmoatic pruning strength determination is not implemented yet for ExpectedErrorPruning" << Endl; } + + + if (fMinNodeEvents > 0){ + fMinNodeSize = Double_t(fMinNodeEvents*100.) / Data()->GetNTrainingEvents(); + Log() << kWARNING << "You have explicitly set ** nEventsMin = " << fMinNodeEvents<<" ** the min ablsolut number \n" + << "of events in a leaf node. This is DEPRECATED, please use the option \n" + << "*MinNodeSize* giving the relative number as percentage of training \n" + << "events instead. \n" + << "nEventsMin="<<fMinNodeEvents<< "--> MinNodeSize="<<fMinNodeSize<<"%" + << Endl; + Log() << kWARNING << "Note also that explicitly setting *nEventsMin* so far OVERWRITES the option recomeded \n" + << " *MinNodeSize* = " << fMinNodeSizeS << " option !!" << Endl ; + fMinNodeSizeS = Form("%F3.2",fMinNodeSize); + + }else{ + SetMinNodeSize(fMinNodeSizeS); + } + + fAdaBoostR2Loss.ToLower(); if (fBoostType=="Grad") { fPruneMethod = DecisionTree::kNoPruning; if (fNegWeightTreatment=="InverseBoostNegWeights"){ - Log() << kWARNING << "the option *InverseBoostNegWeights* does not exist for BoostType=Grad --> change to *IgnoreNegWeights*" << Endl; - fNegWeightTreatment="IgnoreNegWeights"; + Log() << kWARNING << "the option *InverseBoostNegWeights* does not exist for BoostType=Grad --> change to *IgnoreNegWeightsInTraining*" << Endl; + fNegWeightTreatment="IgnoreNegWeightsInTraining"; fNoNegWeightsInTraining=kTRUE; - } + } + } else if (fBoostType=="RealAdaBoost"){ + fBoostType = "AdaBoost"; + fUseYesNoLeaf = kFALSE; + } else if (fBoostType=="AdaCost"){ + fUseYesNoLeaf = kFALSE; } + if (fFValidationEvents < 0.0) fFValidationEvents = 0.0; if (fAutomatic && fFValidationEvents > 0.5) { Log() << kWARNING << "You have chosen to use more than half of your training sample " @@ -439,8 +511,10 @@ void TMVA::MethodBDT::ProcessOptions() Log() << kINFO << " You are using a Monte Carlo that has also negative weights. " << "That should in principle be fine as long as on average you end up with " << "something positive. For this you have to make sure that the minimal number " - << "of (un-weighted) events demanded for a tree node (currently you use: nEventsMin=" - <<fNodeMinEvents<<", you can set this via the BDT option string when booking the " + << "of (un-weighted) events demanded for a tree node (currently you use: MinNodeSize=" + << fMinNodeSizeS << " ("<< fMinNodeSize << "%)" + <<", (or the deprecated equivalent nEventsMin) you can set this via the " + <<"BDT option string when booking the " << "classifier) is large enough to allow for reasonable averaging!!! " << " If this does not help.. maybe you want to try the option: IgnoreNegWeightsInTraining " << "which ignores events with negative weight in the training. " << Endl @@ -464,25 +538,20 @@ void TMVA::MethodBDT::ProcessOptions() // fBoostType = "Bagging"; } - // if (2*fNodeMinEvents > Data()->GetNTrainingEvents()) { - // Log() << kFATAL << "you've demanded a minimun number of events in a leaf node " - // << " that is larger than 1/2 the total number of events in the training sample." - // << " Hence I cannot make any split at all... this will not work!" << Endl; - // } if (fNTrees==0){ - Log() << kERROR << " Zero Decision Trees demanded... that does not work !! " - << " I set it to 1 .. just so that the program does not crash" - << Endl; - fNTrees = 1; + Log() << kERROR << " Zero Decision Trees demanded... that does not work !! " + << " I set it to 1 .. just so that the program does not crash" + << Endl; + fNTrees = 1; } fNegWeightTreatment.ToLower(); - if (fNegWeightTreatment == "ignorenegweights") fNoNegWeightsInTraining = kTRUE; - else if (fNegWeightTreatment == "nonegweightsintraining") fNoNegWeightsInTraining = kTRUE; + if (fNegWeightTreatment == "ignorenegweightsintraining") fNoNegWeightsInTraining = kTRUE; + else if (fNegWeightTreatment == "nonegweightsintraining") fNoNegWeightsInTraining = kTRUE; else if (fNegWeightTreatment == "inverseboostnegweights") fInverseBoostNegWeights = kTRUE; else if (fNegWeightTreatment == "pairnegweightsglobal") fPairNegWeightsGlobal = kTRUE; - else if (fNegWeightTreatment == "pairnegweightsinnode") fPairNegWeightsInNode = kTRUE; + else if (fNegWeightTreatment == "pray") Log() << kWARNING << "Yes, good luck with praying " << Endl; else { Log() << kINFO << GetOptions() << Endl; Log() << kFATAL << "<ProcessOptions> unknown option for treating negative event weights during training " << fNegWeightTreatment << " requested" << Endl; @@ -490,31 +559,81 @@ void TMVA::MethodBDT::ProcessOptions() if (fNegWeightTreatment == "pairnegweightsglobal") Log() << kWARNING << " you specified the option NegWeightTreatment=PairNegWeightsGlobal : This option is still considered EXPERIMENTAL !! " << Endl; - if (fNegWeightTreatment == "pairnegweightsginnode") - Log() << kWARNING << " you specified the option NegWeightTreatment=PairNegWeightsInNode : This option is still considered EXPERIMENTAL !! " << Endl; - if (fNegWeightTreatment == "pairnegweightsginnode" && fNCuts <= 0) - Log() << kFATAL << " sorry, the option NegWeightTreatment=PairNegWeightsInNode is not yet implemented for NCuts < 0" << Endl; + // dealing with deprecated options ! + if (fNNodesMax>0) { + UInt_t tmp=1; // depth=0 == 1 node + fMaxDepth=0; + while (tmp < fNNodesMax){ + tmp+=2*tmp; + fMaxDepth++; + } + Log() << kWARNING << "You have specified a deprecated option *NNodesMax="<<fNNodesMax + << "* \n this has been translated to MaxDepth="<<fMaxDepth<<Endl; + } + + + if (fUseNTrainEvents>0){ + fBaggedSampleFraction = (Double_t) fUseNTrainEvents/Data()->GetNTrainingEvents(); + Log() << kWARNING << "You have specified a deprecated option *UseNTrainEvents="<<fUseNTrainEvents + << "* \n this has been translated to BaggedSampleFraction="<<fBaggedSampleFraction<<"(%)"<<Endl; + } + + if (fBoostType=="Bagging") fBaggedBoost = kTRUE; + if (fBaggedGradBoost){ + fBaggedBoost = kTRUE; + Log() << kWARNING << "You have specified a deprecated option *UseBaggedGrad* --> please use *UseBaggedBoost* instead" << Endl; + } + +} + + +//_______________________________________________________________________ + +void TMVA::MethodBDT::SetMinNodeSize(Double_t sizeInPercent){ + if (sizeInPercent > 0 && sizeInPercent < 50){ + fMinNodeSize=sizeInPercent; + + } else { + Log() << kFATAL << "you have demanded a minimal node size of " + << sizeInPercent << "% of the training events.. \n" + << " that somehow does not make sense "<<Endl; + } + } +//_______________________________________________________________________ +void TMVA::MethodBDT::SetMinNodeSize(TString sizeInPercent){ + sizeInPercent.ReplaceAll("%",""); + sizeInPercent.ReplaceAll(" ",""); + if (sizeInPercent.IsFloat()) SetMinNodeSize(sizeInPercent.Atof()); + else { + Log() << kFATAL << "I had problems reading the option MinNodeEvents, which " + << "after removing a possible % sign now reads " << sizeInPercent << Endl; + } +} + + + //_______________________________________________________________________ void TMVA::MethodBDT::Init( void ) { // common initialisation with defaults for the BDT-Method - fNTrees = 400; + fNTrees = 800; if (fAnalysisType == Types::kClassification || fAnalysisType == Types::kMulticlass ) { fMaxDepth = 3; fBoostType = "AdaBoost"; if(DataInfo().GetNClasses()!=0) //workaround for multiclass application - fNodeMinEvents = TMath::Max( Int_t(40), Int_t( Data()->GetNTrainingEvents() / (10*GetNvar()*GetNvar())) ); + fMinNodeSize = 5.; }else { fMaxDepth = 50; fBoostType = "AdaBoostR2"; fAdaBoostR2Loss = "Quadratic"; if(DataInfo().GetNClasses()!=0) //workaround for multiclass application - fNodeMinEvents = 10; + fMinNodeSize = .2; } + fNCuts = 20; fPruneMethodS = "NoPruning"; @@ -526,15 +645,11 @@ void TMVA::MethodBDT::Init( void ) // fUseNvars = (GetNvar()>12) ? UInt_t(GetNvar()/8) : TMath::Max(UInt_t(2),UInt_t(GetNvar()/3)); fUseNvars = UInt_t(TMath::Sqrt(GetNvar())+0.6); fUsePoissonNvars = kTRUE; - if(DataInfo().GetNClasses()!=0) //workaround for multiclass application - fUseNTrainEvents = Data()->GetNTrainingEvents(); - fNNodesMax = 1000000; fShrinkage = 1.0; fSumOfWeights = 0.0; // reference cut value to distinguish signal-like from background-like events SetSignalReferenceCut( 0 ); - } @@ -558,7 +673,7 @@ void TMVA::MethodBDT::Reset( void ) // reset all previously stored/accumulated BOOST weights in the event sample //for (UInt_t iev=0; iev<fEventSample.size(); iev++) fEventSample[iev]->SetBoostWeight(1.); if (Data()) Data()->DeleteResults(GetMethodName(), Types::kTraining, GetAnalysisType()); - Log() << kDEBUG << " successfully(?) resetted the method " << Endl; + Log() << kDEBUG << " successfully(?) reset the method " << Endl; } @@ -566,48 +681,79 @@ void TMVA::MethodBDT::Reset( void ) TMVA::MethodBDT::~MethodBDT( void ) { //destructor - for (UInt_t i=0; i<fEventSample.size(); i++) delete fEventSample[i]; - for (UInt_t i=0; i<fValidationSample.size(); i++) delete fValidationSample[i]; + // Note: fEventSample and ValidationSample are already deleted at the end of TRAIN + // When they are not used anymore + // for (UInt_t i=0; i<fEventSample.size(); i++) delete fEventSample[i]; + // for (UInt_t i=0; i<fValidationSample.size(); i++) delete fValidationSample[i]; for (UInt_t i=0; i<fForest.size(); i++) delete fForest[i]; } //_______________________________________________________________________ void TMVA::MethodBDT::InitEventSample( void ) { - // Write all Events from the Tree into a vector of Events, that are - // more easily manipulated. This method should never be called without - // existing trainingTree, as it the vector of events from the ROOT training tree + // initialize the event sample (i.e. reset the boost-weights... etc) + if (!HasTrainingTree()) Log() << kFATAL << "<Init> Data().TrainingTree() is zero pointer" << Endl; if (fEventSample.size() > 0) { // do not re-initialise the event sample, just set all boostweights to 1. as if it were untouched // reset all previously stored/accumulated BOOST weights in the event sample for (UInt_t iev=0; iev<fEventSample.size(); iev++) fEventSample[iev]->SetBoostWeight(1.); } else { - + Data()->SetCurrentType(Types::kTraining); UInt_t nevents = Data()->GetNTrainingEvents(); - Bool_t firstNegWeight=kTRUE; - for (UInt_t ievt=0; ievt<nevents; ievt++) { - + std::vector<const TMVA::Event*> tmpEventSample; + for (Long64_t ievt=0; ievt<nevents; ievt++) { + // const Event *event = new Event(*(GetEvent(ievt))); Event* event = new Event( *GetTrainingEvent(ievt) ); - + tmpEventSample.push_back(event); + } + + if (!DoRegression()) DeterminePreselectionCuts(tmpEventSample); + else fDoPreselection = kFALSE; // just to make sure... + + for (UInt_t i=0; i<tmpEventSample.size(); i++) delete tmpEventSample[i]; + + + Bool_t firstNegWeight=kTRUE; + Bool_t firstZeroWeight=kTRUE; + for (Long64_t ievt=0; ievt<nevents; ievt++) { + // const Event *event = new Event(*(GetEvent(ievt))); + // const Event* event = new Event( *GetTrainingEvent(ievt) ); + Event* event = new Event( *GetTrainingEvent(ievt) ); + if (fDoPreselection){ + if (TMath::Abs(ApplyPreselectionCuts(event)) > 0.05) continue; + } + if (event->GetWeight() < 0 && (IgnoreEventsWithNegWeightsInTraining() || fNoNegWeightsInTraining)){ if (firstNegWeight) { Log() << kWARNING << " Note, you have events with negative event weight in the sample, but you've chosen to ignore them" << Endl; firstNegWeight=kFALSE; } delete event; + }else if (event->GetWeight()==0){ + if (firstZeroWeight) { + firstZeroWeight = kFALSE; + Log() << "Events with weight == 0 are going to be simply ignored " << Endl; + } }else{ if (event->GetWeight() < 0) { fTrainWithNegWeights=kTRUE; if (firstNegWeight){ firstNegWeight = kFALSE; - Log() << kWARNING << "Events with negative event weights are USED during " - << "the BDT training. This might cause problems with small node sizes " - << "or with the boosting. Please remove negative events from training " - << "using the option *IgnoreEventsWithNegWeightsInTraining* in case you " - << "observe problems with the boosting" + if (fPairNegWeightsGlobal){ + Log() << kWARNING << "Events with negative event weights are found and " + << " will be removed prior to the actual BDT training by global " + << " paring (and subsequent annihilation) with positiv weight events" + << Endl; + }else{ + Log() << kWARNING << "Events with negative event weights are USED during " + << "the BDT training. This might cause problems with small node sizes " + << "or with the boosting. Please remove negative events from training " + << "using the option *IgnoreEventsWithNegWeightsInTraining* in case you " + << "observe problems with the boosting" << Endl; + } } } // if fAutomatic == true you need a validation sample to optimize pruning @@ -634,8 +780,64 @@ void TMVA::MethodBDT::InitEventSample( void ) if (fPairNegWeightsGlobal) PreProcessNegativeEventWeights(); } + + // it does not make sense in decision trees to start with unequal number of signal/background + // events (weights) .. hence normalize them now (happens atherwise in first 'boosting step' + // anyway.. + // Also make sure, that the sum_of_weights == sample.size() .. as this is assumed in + // the DecisionTree to derive a sensible number for "fMinSize" (min.#events in node) + // that currently is an OR between "weighted" and "unweighted number" + // I want: + // nS + nB = n + // a*SW + b*BW = n + // (a*SW)/(b*BW) = fSigToBkgFraction + // + // ==> b = n/((1+f)BW) and a = (nf/(1+f))/SW + + Double_t nevents = fEventSample.size(); + Double_t sumSigW=0, sumBkgW=0; + Int_t sumSig=0, sumBkg=0; + for (UInt_t ievt=0; ievt<fEventSample.size(); ievt++) { + if ((DataInfo().IsSignal(fEventSample[ievt])) ) { + sumSigW += fEventSample[ievt]->GetWeight(); + sumSig++; + } else { + sumBkgW += fEventSample[ievt]->GetWeight(); + sumBkg++; + } + } + Double_t normSig = nevents/((1+fSigToBkgFraction)*sumSigW)*fSigToBkgFraction; + Double_t normBkg = nevents/((1+fSigToBkgFraction)*sumBkgW); ; + Log() << kINFO << "re-normlise events such that Sig and Bkg have respective sum of weights = " + << fSigToBkgFraction << Endl; + Log() << kINFO << " sig->sig*"<<normSig << "ev. bkg->bkg*"<<normBkg << "ev." <<Endl; + Log() << kINFO << "#events: (reweighted) sig: "<< sumSigW*normSig << " bkg: " << sumBkgW*normBkg << Endl; + Log() << kINFO << "#events: (unweighted) sig: "<< sumSig << " bkg: " << sumBkg << Endl; + for (Long64_t ievt=0; ievt<nevents; ievt++) { + if ((DataInfo().IsSignal(fEventSample[ievt])) ) fEventSample[ievt]->SetBoostWeight(normSig); + else fEventSample[ievt]->SetBoostWeight(normBkg); + } + + + fTrainSample = &fEventSample; + if (fBaggedBoost){ + GetBaggedSubSample(fEventSample); + fTrainSample = &fSubSample; + } + + //just for debug purposes.. + /* + sumSigW=0; + sumBkgW=0; + for (UInt_t ievt=0; ievt<fEventSample.size(); ievt++) { + if ((DataInfo().IsSignal(fEventSample[ievt])) ) sumSigW += fEventSample[ievt]->GetWeight(); + else sumBkgW += fEventSample[ievt]->GetWeight(); + } + Log() << kWARNING << "sigSumW="<<sumSigW<<"bkgSumW="<<sumBkgW<< Endl; + */ } +//_______________________________________________________________________ void TMVA::MethodBDT::PreProcessNegativeEventWeights(){ // o.k. you know there are events with negative event weights. This routine will remove // them by pairing them with the closest event(s) of the same event class with positive @@ -645,7 +847,7 @@ void TMVA::MethodBDT::PreProcessNegativeEventWeights(){ Double_t totalNegWeights = 0; Double_t totalPosWeights = 0; Double_t totalWeights = 0; - std::vector<Event*> negEvents; + std::vector<const Event*> negEvents; for (UInt_t iev = 0; iev < fEventSample.size(); iev++){ if (fEventSample[iev]->GetWeight() < 0) { totalNegWeights += fEventSample[iev]->GetWeight(); @@ -689,7 +891,9 @@ void TMVA::MethodBDT::PreProcessNegativeEventWeights(){ Log() << kINFO << "Found a total of " << totalNegWeights << " in negative weights out of " << fEventSample.size() << " training events " << Endl; + Timer timer(negEvents.size(),"Negative Event paired"); for (UInt_t nev = 0; nev < negEvents.size(); nev++){ + timer.DrawProgressBar( nev ); Double_t weight = negEvents[nev]->GetWeight(); UInt_t iClassID = negEvents[nev]->GetClass(); invCov = ((*cov)[iClassID]); @@ -713,13 +917,13 @@ void TMVA::MethodBDT::PreProcessNegativeEventWeights(){ } if (iMin > -1) { - // std::cout << "Happily pairing .. weight before : " << negEvents[nev]->GetWeight() << " and " << fEventSample[iMin]->GetWeight(); - Double_t newWeight= (negEvents[nev]->GetWeight() + fEventSample[iMin]->GetWeight()); + // std::cout << "Happily pairing .. weight before : " << negEvents[nev]->GetWeight() << " and " << fEventSample[iMin]->GetWeight(); + Double_t newWeight = (negEvents[nev]->GetWeight() + fEventSample[iMin]->GetWeight()); if (newWeight > 0){ negEvents[nev]->SetBoostWeight( 0 ); - fEventSample[iMin]->SetBoostWeight( newWeight ); + fEventSample[iMin]->SetBoostWeight( newWeight/fEventSample[iMin]->GetOriginalWeight() ); // note the weight*boostweight should be "newWeight" } else { - negEvents[nev]->SetBoostWeight( newWeight ); + negEvents[nev]->SetBoostWeight( newWeight/negEvents[nev]->GetOriginalWeight() ); // note the weight*boostweight should be "newWeight" fEventSample[iMin]->SetBoostWeight( 0 ); } // std::cout << " and afterwards " << negEvents[nev]->GetWeight() << " and the paired " << fEventSample[iMin]->GetWeight() << " dist="<<minDist<< std::endl; @@ -727,6 +931,8 @@ void TMVA::MethodBDT::PreProcessNegativeEventWeights(){ weight = negEvents[nev]->GetWeight(); } } + Log() << kINFO << "<Negative Event Pairing> took: " << timer.GetElapsedTime() + << " " << Endl; // just check.. now there should be no negative event weight left anymore totalNegWeights = 0; @@ -737,18 +943,18 @@ void TMVA::MethodBDT::PreProcessNegativeEventWeights(){ Int_t nSig=0; Int_t nBkg=0; - std::vector<Event*> newEventSample; + std::vector<const Event*> newEventSample; for (UInt_t iev = 0; iev < fEventSample.size(); iev++){ if (fEventSample[iev]->GetWeight() < 0) { totalNegWeights += fEventSample[iev]->GetWeight(); totalWeights += fEventSample[iev]->GetWeight(); } else { - totalPosWeights += fEventSample[iev]->GetWeight(); + totalPosWeights += fEventSample[iev]->GetWeight(); totalWeights += fEventSample[iev]->GetWeight(); } if (fEventSample[iev]->GetWeight() > 0) { - newEventSample.push_back(fEventSample[iev]); + newEventSample.push_back(new Event(*fEventSample[iev])); if (fEventSample[iev]->GetClass() == fSignalClass){ sigWeight += fEventSample[iev]->GetWeight(); nSig+=1; @@ -760,6 +966,7 @@ void TMVA::MethodBDT::PreProcessNegativeEventWeights(){ } if (totalNegWeights < 0) Log() << kFATAL << " compenstion of negative event weights with positive ones did not work " << totalNegWeights << Endl; + for (UInt_t i=0; i<fEventSample.size(); i++) delete fEventSample[i]; fEventSample = newEventSample; Log() << kINFO << " after PreProcessing, the Event sample is left with " << fEventSample.size() << " events (unweighted), all with positive weights, adding up to " << totalWeights << Endl; @@ -777,7 +984,7 @@ std::map<TString,Double_t> TMVA::MethodBDT::OptimizeTuningParameters(TString fo // are meant to be tuned. // fill all the tuning parameters that should be optimized into a map: - std::map<TString,TMVA::Interval> tuneParameters; + std::map<TString,TMVA::Interval*> tuneParameters; std::map<TString,Double_t> tunedParameters; // note: the 3rd paraemter in the inteval is the "number of bins", NOT the stepsize !! @@ -785,31 +992,35 @@ std::map<TString,Double_t> TMVA::MethodBDT::OptimizeTuningParameters(TString fo // read from the middle of the bins. Hence.. the choice of Intervals e.g. for the // MaxDepth, in order to make nice interger values!!! - // find some reasonable ranges for the optimisation of NodeMinEvents: - - Int_t N = Int_t( Data()->GetNEvtSigTrain()) ; - Int_t min = TMath::Max( 20, ( ( N/10000 - (N/10000)%10) ) ); - Int_t max = TMath::Max( min*10, TMath::Min( 10000, ( ( N/10 - (N/10) %100) ) ) ); + // find some reasonable ranges for the optimisation of MinNodeEvents: - tuneParameters.insert(std::pair<TString,Interval>("NTrees", Interval(50,1000,5))); // stepsize 50 - tuneParameters.insert(std::pair<TString,Interval>("MaxDepth", Interval(3,10,8))); // stepsize 1 - tuneParameters.insert(std::pair<TString,Interval>("NodeMinEvents", Interval(min,max,5))); // - //tuneParameters.insert(std::pair<TString,Interval>("NodePurityLimit",Interval(.4,.6,3))); // stepsize .1 + tuneParameters.insert(std::pair<TString,Interval*>("NTrees", new Interval(10,1000,5))); // stepsize 50 + tuneParameters.insert(std::pair<TString,Interval*>("MaxDepth", new Interval(2,4,3))); // stepsize 1 + tuneParameters.insert(std::pair<TString,Interval*>("MinNodeSize", new LogInterval(1,30,30))); // + //tuneParameters.insert(std::pair<TString,Interval*>("NodePurityLimit",new Interval(.4,.6,3))); // stepsize .1 + //tuneParameters.insert(std::pair<TString,Interval*>("BaggedSampleFraction",new Interval(.4,.9,6))); // stepsize .1 // method-specific parameters if (fBoostType=="AdaBoost"){ - tuneParameters.insert(std::pair<TString,Interval>("AdaBoostBeta", Interval(.5,1.50,5))); + tuneParameters.insert(std::pair<TString,Interval*>("AdaBoostBeta", new Interval(.2,1.,5))); }else if (fBoostType=="Grad"){ - tuneParameters.insert(std::pair<TString,Interval>("Shrinkage", Interval(0.05,0.50,5))); + tuneParameters.insert(std::pair<TString,Interval*>("Shrinkage", new Interval(0.05,0.50,5))); }else if (fBoostType=="Bagging" && fRandomisedTrees){ - Int_t min_var = TMath::FloorNint( GetNvar() * .25 ); - Int_t max_var = TMath::CeilNint( GetNvar() * .75 ); - tuneParameters.insert(std::pair<TString,Interval>("UseNvars", Interval(min_var,max_var,4))); + Int_t min_var = TMath::FloorNint( GetNvar() * .25 ); + Int_t max_var = TMath::CeilNint( GetNvar() * .75 ); + tuneParameters.insert(std::pair<TString,Interval*>("UseNvars", new Interval(min_var,max_var,4))); } + Log()<<kINFO << " the following BDT parameters will be tuned on the respective *grid*\n"<<Endl; + std::map<TString,TMVA::Interval*>::iterator it; + for(it=tuneParameters.begin(); it!= tuneParameters.end(); it++){ + Log() << kWARNING << it->first << Endl; + (it->second)->Print(Log()); + Log()<<Endl; + } OptimizeConfigParameters optimize(this, tuneParameters, fomType, fitType); tunedParameters=optimize.optimize(); @@ -825,13 +1036,19 @@ void TMVA::MethodBDT::SetTuneParameters(std::map<TString,Double_t> tuneParameter std::map<TString,Double_t>::iterator it; for(it=tuneParameters.begin(); it!= tuneParameters.end(); it++){ + Log() << kWARNING << it->first << " = " << it->second << Endl; if (it->first == "MaxDepth" ) SetMaxDepth ((Int_t)it->second); - if (it->first == "NodeMinEvents" ) SetNodeMinEvents ((Int_t)it->second); - if (it->first == "NTrees" ) SetNTrees ((Int_t)it->second); - if (it->first == "NodePurityLimit") SetNodePurityLimit (it->second); - if (it->first == "AdaBoostBeta" ) SetAdaBoostBeta (it->second); + else if (it->first == "MinNodeSize" ) SetMinNodeSize (it->second); + else if (it->first == "NTrees" ) SetNTrees ((Int_t)it->second); + else if (it->first == "NodePurityLimit") SetNodePurityLimit (it->second); + else if (it->first == "AdaBoostBeta" ) SetAdaBoostBeta (it->second); + else if (it->first == "Shrinkage" ) SetShrinkage (it->second); + else if (it->first == "UseNvars" ) SetUseNvars ((Int_t)it->second); + else if (it->first == "BaggedSampleFraction" ) SetBaggedSampleFraction (it->second); + else Log() << kFATAL << " SetParameter for " << it->first << " not yet implemented " <<Endl; } + } //_______________________________________________________________________ @@ -846,10 +1063,10 @@ void TMVA::MethodBDT::Train() InitEventSample(); if (fNTrees==0){ - Log() << kERROR << " Zero Decision Trees demanded... that does not work !! " - << " I set it to 1 .. just so that the program does not crash" - << Endl; - fNTrees = 1; + Log() << kERROR << " Zero Decision Trees demanded... that does not work !! " + << " I set it to 1 .. just so that the program does not crash" + << Endl; + fNTrees = 1; } // HHV (it's been here since looong but I really don't know why we cannot handle @@ -862,7 +1079,7 @@ void TMVA::MethodBDT::Train() Log() << kINFO << "Training "<< fNTrees << " Decision Trees ... patience please" << Endl; Log() << kDEBUG << "Training with maximal depth = " <<fMaxDepth - << ", NodeMinEvents=" << fNodeMinEvents + << ", MinNodeEvents=" << fMinNodeEvents << ", NTrees="<<fNTrees << ", NodePurityLimit="<<fNodePurityLimit << ", AdaBoostBeta="<<fAdaBoostBeta @@ -947,13 +1164,15 @@ void TMVA::MethodBDT::Train() Int_t nNodesBeforePruning = 0; Int_t nNodesAfterPruning = 0; + if(fBoostType=="Grad"){ InitGradBoost(fEventSample); - } else { - if (fBaggedGradBoost) GetRandomSubSample(); } - for (int itree=0; itree<fNTrees; itree++) { + Int_t itree=0; + Bool_t continueBoost=kTRUE; + //for (int itree=0; itree<fNTrees; itree++) { + while (itree < fNTrees && continueBoost){ timer.DrawProgressBar( itree ); if(DoMulticlass()){ if (fBoostType!="Grad"){ @@ -962,11 +1181,11 @@ void TMVA::MethodBDT::Train() << Endl; } UInt_t nClasses = DataInfo().GetNClasses(); - for (UInt_t i=0;i<nClasses;i++){ - fForest.push_back( new DecisionTree( fSepType, fNodeMinEvents, fNCuts, i, - fRandomisedTrees, fUseNvars, fUsePoissonNvars, fNNodesMax, fMaxDepth, + for (UInt_t i=0;i<nClasses;i++){ + fForest.push_back( new DecisionTree( fSepType, fMinNodeSize, fNCuts, i, + fRandomisedTrees, fUseNvars, fUsePoissonNvars, fMaxDepth, itree*nClasses+i, fNodePurityLimit, itree*nClasses+i)); - if (fPairNegWeightsInNode) fForest.back()->SetPairNegWeightsInNode(); + fForest.back()->SetNVars(GetNvar()); if (fUseFisherCuts) { fForest.back()->SetUseFisherCuts(); fForest.back()->SetMinLinCorrForFisher(fMinLinCorrForFisher); @@ -974,67 +1193,62 @@ void TMVA::MethodBDT::Train() } // the minimum linear correlation between two variables demanded for use in fisher criterion in node splitting - if (fBaggedGradBoost){ - nNodesBeforePruning = fForest.back()->BuildTree(fSubSample); - fBoostWeights.push_back(this->Boost(fSubSample, fForest.back(), itree, i)); -} - else{ - nNodesBeforePruning = fForest.back()->BuildTree(fEventSample); - fBoostWeights.push_back(this->Boost(fEventSample, fForest.back(), itree, i)); + nNodesBeforePruning = fForest.back()->BuildTree(*fTrainSample); + Double_t bw = this->Boost(fEventSample, fForest.back(),i); + if (bw > 0) { + fBoostWeights.push_back(bw); + }else{ + fBoostWeights.push_back(0); + Log() << kWARNING << "stopped boosting at itree="<<itree << Endl; + // fNTrees = itree+1; // that should stop the boosting + continueBoost=kFALSE; } } } else{ - fForest.push_back( new DecisionTree( fSepType, fNodeMinEvents, fNCuts, fSignalClass, - fRandomisedTrees, fUseNvars, fUsePoissonNvars, fNNodesMax, fMaxDepth, + fForest.push_back( new DecisionTree( fSepType, fMinNodeSize, fNCuts, fSignalClass, + fRandomisedTrees, fUseNvars, fUsePoissonNvars, fMaxDepth, itree, fNodePurityLimit, itree)); - if (fPairNegWeightsInNode) fForest.back()->SetPairNegWeightsInNode(); + fForest.back()->SetNVars(GetNvar()); if (fUseFisherCuts) { fForest.back()->SetUseFisherCuts(); fForest.back()->SetMinLinCorrForFisher(fMinLinCorrForFisher); fForest.back()->SetUseExclusiveVars(fUseExclusiveVars); } - if (fBaggedGradBoost) nNodesBeforePruning = fForest.back()->BuildTree(fSubSample); - else nNodesBeforePruning = fForest.back()->BuildTree(fEventSample); - if (fBoostType!="Grad") - if (fUseYesNoLeaf && !DoRegression() ){ // remove leaf nodes where both daughter nodes are of same type - nNodesBeforePruning = fForest.back()->CleanTree(); - } + nNodesBeforePruning = fForest.back()->BuildTree(*fTrainSample); + + if (fUseYesNoLeaf && !DoRegression() && fBoostType!="Grad") { // remove leaf nodes where both daughter nodes are of same type + nNodesBeforePruning = fForest.back()->CleanTree(); + } + nNodesBeforePruningCount += nNodesBeforePruning; nodesBeforePruningVsTree->SetBinContent(itree+1,nNodesBeforePruning); fForest.back()->SetPruneMethod(fPruneMethod); // set the pruning method for the tree fForest.back()->SetPruneStrength(fPruneStrength); // set the strength parameter - std::vector<Event*> * validationSample = NULL; + std::vector<const Event*> * validationSample = NULL; if(fAutomatic) validationSample = &fValidationSample; - if(fBoostType=="Grad"){ - if(fBaggedGradBoost) - fBoostWeights.push_back(this->Boost(fSubSample, fForest.back(), itree)); - else - fBoostWeights.push_back(this->Boost(fEventSample, fForest.back(), itree)); + Double_t bw = this->Boost(fEventSample, fForest.back()); + if (bw > 0) { + fBoostWeights.push_back(bw); + }else{ + fBoostWeights.push_back(0); + Log() << kWARNING << "stopped boosting at itree="<<itree << Endl; + continueBoost=kFALSE; } - else { - if(!fPruneBeforeBoost) { // only prune after boosting - if(fBaggedGradBoost) - fBoostWeights.push_back(this->Boost(fSubSample, fForest.back(), itree)); - else - fBoostWeights.push_back(this->Boost(fEventSample, fForest.back(), itree)); - // if fAutomatic == true, pruneStrength will be the optimal pruning strength - // determined by the pruning algorithm; otherwise, it is simply the strength parameter - // set by the user - fForest.back()->PruneTree(validationSample); - } - else { // prune first, then apply a boosting cycle - fForest.back()->PruneTree(validationSample); - fBoostWeights.push_back( this->Boost(fEventSample, fForest.back(), itree) ); - } - - if (fUseYesNoLeaf && !DoRegression() ){ // remove leaf nodes where both daughter nodes are of same type - fForest.back()->CleanTree(); - } + + + + // if fAutomatic == true, pruneStrength will be the optimal pruning strength + // determined by the pruning algorithm; otherwise, it is simply the strength parameter + // set by the user + if (fPruneMethod != DecisionTree::kNoPruning) fForest.back()->PruneTree(validationSample); + + if (fUseYesNoLeaf && !DoRegression() && fBoostType!="Grad"){ // remove leaf nodes where both daughter nodes are of same type + fForest.back()->CleanTree(); } nNodesAfterPruning = fForest.back()->GetNNodes(); nNodesAfterPruningCount += nNodesAfterPruning; @@ -1055,6 +1269,7 @@ void TMVA::MethodBDT::Train() } } } + itree++; } // get elapsed time @@ -1062,34 +1277,30 @@ void TMVA::MethodBDT::Train() << " " << Endl; if (fPruneMethod == DecisionTree::kNoPruning) { Log() << kINFO << "<Train> average number of nodes (w/o pruning) : " - << nNodesBeforePruningCount/fNTrees << Endl; + << nNodesBeforePruningCount/GetNTrees() << Endl; } else { Log() << kINFO << "<Train> average number of nodes before/after pruning : " - << nNodesBeforePruningCount/fNTrees << " / " - << nNodesAfterPruningCount/fNTrees + << nNodesBeforePruningCount/GetNTrees() << " / " + << nNodesAfterPruningCount/GetNTrees() << Endl; } TMVA::DecisionTreeNode::fgIsTraining=false; -} -//_______________________________________________________________________ -void TMVA::MethodBDT::GetRandomSubSample() -{ - // fills fEventSample with fSampleFraction*NEvents random training events - UInt_t nevents = fEventSample.size(); - - if (!fSubSample.empty()) fSubSample.clear(); - TRandom3 *trandom = new TRandom3(fForest.size()+1); - for (UInt_t ievt=0; ievt<nevents; ievt++) { // recreate new random subsample - if(trandom->Rndm()<fSampleFraction) - fSubSample.push_back(fEventSample[ievt]); - } + // reset all previously stored/accumulated BOOST weights in the event sample + // for (UInt_t iev=0; iev<fEventSample.size(); iev++) fEventSample[iev]->SetBoostWeight(1.); + Log() << kDEBUG << "Now I delete the privat data sample"<< Endl; + for (UInt_t i=0; i<fEventSample.size(); i++) delete fEventSample[i]; + for (UInt_t i=0; i<fValidationSample.size(); i++) delete fValidationSample[i]; + fEventSample.clear(); + fValidationSample.clear(); + } + //_______________________________________________________________________ -Double_t TMVA::MethodBDT::GetGradBoostMVA(TMVA::Event& e, UInt_t nTrees) +Double_t TMVA::MethodBDT::GetGradBoostMVA(const TMVA::Event* e, UInt_t nTrees) { //returns MVA value: -1 for background, 1 for signal Double_t sum=0; @@ -1102,14 +1313,14 @@ Double_t TMVA::MethodBDT::GetGradBoostMVA(TMVA::Event& e, UInt_t nTrees) } //_______________________________________________________________________ -void TMVA::MethodBDT::UpdateTargets(vector<TMVA::Event*> eventSample, UInt_t cls) +void TMVA::MethodBDT::UpdateTargets(std::vector<const TMVA::Event*>& eventSample, UInt_t cls) { //Calculate residua for all events; if(DoMulticlass()){ UInt_t nClasses = DataInfo().GetNClasses(); - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { - fResiduals[*e].at(cls)+=fForest.back()->CheckEvent(*(*e),kFALSE); + for (std::vector<const TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + fResiduals[*e].at(cls)+=fForest.back()->CheckEvent(*e,kFALSE); if(cls == nClasses-1){ for(UInt_t i=0;i<nClasses;i++){ Double_t norm = 0.0; @@ -1119,71 +1330,71 @@ void TMVA::MethodBDT::UpdateTargets(vector<TMVA::Event*> eventSample, UInt_t cls } Double_t p_cls = 1.0/(1.0+norm); Double_t res = ((*e)->GetClass()==i)?(1.0-p_cls):(-p_cls); - (*e)->SetTarget(i,res); + const_cast<TMVA::Event*>(*e)->SetTarget(i,res); } } } } else{ - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { - fResiduals[*e].at(0)+=fForest.back()->CheckEvent(*(*e),kFALSE); + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { + fResiduals[*e].at(0)+=fForest.back()->CheckEvent(*e,kFALSE); Double_t p_sig=1.0/(1.0+exp(-2.0*fResiduals[*e].at(0))); Double_t res = (DataInfo().IsSignal(*e)?1:0)-p_sig; - (*e)->SetTarget(0,res); + const_cast<TMVA::Event*>(*e)->SetTarget(0,res); } } } //_______________________________________________________________________ -void TMVA::MethodBDT::UpdateTargetsRegression(vector<TMVA::Event*> eventSample, Bool_t first) +void TMVA::MethodBDT::UpdateTargetsRegression(std::vector<const TMVA::Event*>& eventSample, Bool_t first) { //Calculate current residuals for all events and update targets for next iteration - for (vector<TMVA::Event*>::iterator e=fEventSample.begin(); e!=fEventSample.end();e++) { + for (std::vector<const TMVA::Event*>::const_iterator e=fEventSample.begin(); e!=fEventSample.end();e++) { if(!first){ - fWeightedResiduals[*e].first -= fForest.back()->CheckEvent(*(*e),kFALSE); + fWeightedResiduals[*e].first -= fForest.back()->CheckEvent(*e,kFALSE); } } fSumOfWeights = 0; - vector< pair<Double_t, Double_t> > temp; - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++){ + vector< std::pair<Double_t, Double_t> > temp; + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++){ temp.push_back(make_pair(fabs(fWeightedResiduals[*e].first),fWeightedResiduals[*e].second)); fSumOfWeights += (*e)->GetWeight(); } fTransitionPoint = GetWeightedQuantile(temp,0.7,fSumOfWeights); Int_t i=0; - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { if(temp[i].first<=fTransitionPoint) - (*e)->SetTarget(0,fWeightedResiduals[*e].first); + const_cast<TMVA::Event*>(*e)->SetTarget(0,fWeightedResiduals[*e].first); else - (*e)->SetTarget(0,fTransitionPoint*(fWeightedResiduals[*e].first<0?-1.0:1.0)); + const_cast<TMVA::Event*>(*e)->SetTarget(0,fTransitionPoint*(fWeightedResiduals[*e].first<0?-1.0:1.0)); i++; } } //_______________________________________________________________________ -Double_t TMVA::MethodBDT::GetWeightedQuantile(vector< pair<Double_t, Double_t> > vec, const Double_t quantile, const Double_t norm){ +Double_t TMVA::MethodBDT::GetWeightedQuantile(vector< std::pair<Double_t, Double_t> > vec, const Double_t quantile, const Double_t norm){ //calculates the quantile of the distribution of the first pair entries weighted with the values in the second pair entries Double_t temp = 0.0; std::sort(vec.begin(), vec.end()); - Int_t i = 0; - while(temp <= norm*quantile){ + UInt_t i = 0; + while(i<vec.size() && temp <= norm*quantile){ temp += vec[i].second; i++; } - + if (i >= vec.size()) return 0.; // prevent uncontrolled memory access in return value calculation return vec[i].first; } //_______________________________________________________________________ -Double_t TMVA::MethodBDT::GradBoost( vector<TMVA::Event*> eventSample, DecisionTree *dt, UInt_t cls) +Double_t TMVA::MethodBDT::GradBoost(std::vector<const TMVA::Event*>& eventSample, DecisionTree *dt, UInt_t cls) { //Calculate the desired response value for each region - std::map<TMVA::DecisionTreeNode*,vector<Double_t> > leaves; - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + std::map<TMVA::DecisionTreeNode*,std::vector<Double_t> > leaves; + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { Double_t weight = (*e)->GetWeight(); TMVA::DecisionTreeNode* node = dt->GetEventNode(*(*e)); if ((leaves[node]).empty()){ @@ -1195,7 +1406,7 @@ Double_t TMVA::MethodBDT::GradBoost( vector<TMVA::Event*> eventSample, DecisionT (leaves[node])[1]+=fabs((*e)->GetTarget(cls))*(1.0-fabs((*e)->GetTarget(cls))) * weight* weight; } } - for (std::map<TMVA::DecisionTreeNode*,vector<Double_t> >::iterator iLeave=leaves.begin(); + for (std::map<TMVA::DecisionTreeNode*,std::vector<Double_t> >::iterator iLeave=leaves.begin(); iLeave!=leaves.end();++iLeave){ if ((iLeave->second)[1]<1e-30) (iLeave->second)[1]=1e-30; @@ -1203,28 +1414,26 @@ Double_t TMVA::MethodBDT::GradBoost( vector<TMVA::Event*> eventSample, DecisionT } //call UpdateTargets before next tree is grown - if (fBaggedGradBoost){ - GetRandomSubSample(); - } + DoMulticlass() ? UpdateTargets(fEventSample, cls) : UpdateTargets(fEventSample); return 1; //trees all have the same weight } //_______________________________________________________________________ -Double_t TMVA::MethodBDT::GradBoostRegression( vector<TMVA::Event*> eventSample, DecisionTree *dt ) +Double_t TMVA::MethodBDT::GradBoostRegression(std::vector<const TMVA::Event*>& eventSample, DecisionTree *dt ) { // Implementation of M_TreeBoost using a Huber loss function as desribed by Friedman 1999 std::map<TMVA::DecisionTreeNode*,Double_t > leaveWeights; - std::map<TMVA::DecisionTreeNode*,vector< pair<Double_t, Double_t> > > leaves; + std::map<TMVA::DecisionTreeNode*,vector< std::pair<Double_t, Double_t> > > leaves; UInt_t i =0; - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { TMVA::DecisionTreeNode* node = dt->GetEventNode(*(*e)); (leaves[node]).push_back(make_pair(fWeightedResiduals[*e].first,(*e)->GetWeight())); (leaveWeights[node]) += (*e)->GetWeight(); i++; } - for (std::map<TMVA::DecisionTreeNode*,vector< pair<Double_t, Double_t> > >::iterator iLeave=leaves.begin(); + for (std::map<TMVA::DecisionTreeNode*,vector< std::pair<Double_t, Double_t> > >::iterator iLeave=leaves.begin(); iLeave!=leaves.end();++iLeave){ Double_t shift=0,diff= 0; Double_t ResidualMedian = GetWeightedQuantile(iLeave->second,0.5,leaveWeights[iLeave->first]); @@ -1235,24 +1444,19 @@ Double_t TMVA::MethodBDT::GradBoostRegression( vector<TMVA::Event*> eventSample, (iLeave->first)->SetResponse(fShrinkage*(ResidualMedian+shift)); } - if (fBaggedGradBoost){ - GetRandomSubSample(); - UpdateTargetsRegression(fSubSample); - } - else - UpdateTargetsRegression(fEventSample); + UpdateTargetsRegression(*fTrainSample); return 1; } //_______________________________________________________________________ -void TMVA::MethodBDT::InitGradBoost( vector<TMVA::Event*> eventSample) +void TMVA::MethodBDT::InitGradBoost( std::vector<const TMVA::Event*>& eventSample) { // initialize targets for first tree fSumOfWeights = 0; fSepType=NULL; //set fSepType to NULL (regression trees are used for both classification an regression) std::vector<std::pair<Double_t, Double_t> > temp; if(DoRegression()){ - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { fWeightedResiduals[*e]= make_pair((*e)->GetTarget(0), (*e)->GetWeight()); fSumOfWeights+=(*e)->GetWeight(); temp.push_back(make_pair(fWeightedResiduals[*e].first,fWeightedResiduals[*e].second)); @@ -1261,38 +1465,35 @@ void TMVA::MethodBDT::InitGradBoost( vector<TMVA::Event*> eventSample) //Store the weighted median as a first boosweight for later use fBoostWeights.push_back(weightedMedian); - std::map<TMVA::Event*, std::pair<Double_t, Double_t> >::iterator res = fWeightedResiduals.begin(); + std::map<const TMVA::Event*, std::pair<Double_t, Double_t> >::iterator res = fWeightedResiduals.begin(); for (; res!=fWeightedResiduals.end(); ++res ) { //substract the gloabl median from all residuals (*res).second.first -= weightedMedian; } - if (fBaggedGradBoost){ - GetRandomSubSample(); - UpdateTargetsRegression(fSubSample,kTRUE); - } - else - UpdateTargetsRegression(fEventSample,kTRUE); + + UpdateTargetsRegression(*fTrainSample,kTRUE); + return; } else if(DoMulticlass()){ UInt_t nClasses = DataInfo().GetNClasses(); - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { for (UInt_t i=0;i<nClasses;i++){ //Calculate initial residua, assuming equal probability for all classes Double_t r = (*e)->GetClass()==i?(1-1.0/nClasses):(-1.0/nClasses); - (*e)->SetTarget(i,r); + const_cast<TMVA::Event*>(*e)->SetTarget(i,r); fResiduals[*e].push_back(0); } } } else{ - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { Double_t r = (DataInfo().IsSignal(*e)?1:0)-0.5; //Calculate initial residua - (*e)->SetTarget(0,r); + const_cast<TMVA::Event*>(*e)->SetTarget(0,r); fResiduals[*e].push_back(0); } } - if (fBaggedGradBoost) GetRandomSubSample(); + } //_______________________________________________________________________ Double_t TMVA::MethodBDT::TestTreeQuality( DecisionTree *dt ) @@ -1301,7 +1502,7 @@ Double_t TMVA::MethodBDT::TestTreeQuality( DecisionTree *dt ) Double_t ncorrect=0, nfalse=0; for (UInt_t ievt=0; ievt<fValidationSample.size(); ievt++) { - Bool_t isSignalType= (dt->CheckEvent(*(fValidationSample[ievt])) > fNodePurityLimit ) ? 1 : 0; + Bool_t isSignalType= (dt->CheckEvent(fValidationSample[ievt]) > fNodePurityLimit ) ? 1 : 0; if (isSignalType == (DataInfo().IsSignal(fValidationSample[ievt])) ) { ncorrect += fValidationSample[ievt]->GetWeight(); @@ -1315,7 +1516,7 @@ Double_t TMVA::MethodBDT::TestTreeQuality( DecisionTree *dt ) } //_______________________________________________________________________ -Double_t TMVA::MethodBDT::Boost( vector<TMVA::Event*> eventSample, DecisionTree *dt, Int_t iTree, UInt_t cls ) +Double_t TMVA::MethodBDT::Boost( std::vector<const TMVA::Event*>& eventSample, DecisionTree *dt, UInt_t cls ) { // apply the boosting alogrithim (the algorithm is selecte via the the "option" given // in the constructor. The return value is the boosting weight @@ -1323,7 +1524,8 @@ Double_t TMVA::MethodBDT::Boost( vector<TMVA::Event*> eventSample, DecisionTree Double_t returnVal=-1; if (fBoostType=="AdaBoost") returnVal = this->AdaBoost (eventSample, dt); - else if (fBoostType=="Bagging") returnVal = this->Bagging (eventSample, iTree); + else if (fBoostType=="AdaCost") returnVal = this->AdaCost (eventSample, dt); + else if (fBoostType=="Bagging") returnVal = this->Bagging ( ); else if (fBoostType=="RegBoost") returnVal = this->RegBoost (eventSample, dt); else if (fBoostType=="AdaBoostR2") returnVal = this->AdaBoostR2(eventSample, dt); else if (fBoostType=="Grad"){ @@ -1339,6 +1541,11 @@ Double_t TMVA::MethodBDT::Boost( vector<TMVA::Event*> eventSample, DecisionTree Log() << kFATAL << "<Boost> unknown boost option " << fBoostType<< " called" << Endl; } + if (fBaggedBoost){ + GetBaggedSubSample(fEventSample); + } + + return returnVal; } @@ -1348,6 +1555,8 @@ void TMVA::MethodBDT::BoostMonitor(Int_t iTree) // fills the ROCIntegral vs Itree from the testSample for the monitoring plots // during the training .. but using the testing events + Results* results = Data()->GetResults(GetMethodName(),Types::kTraining, Types::kMaxAnalysisType); + TH1F *tmpS = new TH1F( "tmpS", "", 100 , -1., 1.00001 ); TH1F *tmpB = new TH1F( "tmpB", "", 100 , -1., 1.00001 ); TH1F *tmp; @@ -1365,17 +1574,54 @@ void TMVA::MethodBDT::BoostMonitor(Int_t iTree) UInt_t nevents = Data()->GetNTestEvents(); for (UInt_t iev=0; iev < nevents; iev++){ - Event* event = new Event( *GetTestingEvent(iev) ); + const Event* event = GetTestingEvent(iev); + + if (event->GetClass() == signalClassNr) {tmp=tmpS;} + else {tmp=tmpB;} + tmp->Fill(PrivateGetMvaValue(event),event->GetWeight()); + } + Double_t max=1; + + std::vector<TH1F*> hS; + std::vector<TH1F*> hB; + for (UInt_t ivar=0; ivar<GetNvar(); ivar++){ + hS.push_back(new TH1F(Form("SigVar%dAtTree%d",ivar,iTree),Form("SigVar%dAtTree%d",ivar,iTree),100,DataInfo().GetVariableInfo(ivar).GetMin(),DataInfo().GetVariableInfo(ivar).GetMax())); + hB.push_back(new TH1F(Form("BkgVar%dAtTree%d",ivar,iTree),Form("BkgVar%dAtTree%d",ivar,iTree),100,DataInfo().GetVariableInfo(ivar).GetMin(),DataInfo().GetVariableInfo(ivar).GetMax())); + results->Store(hS.back(),hS.back()->GetTitle()); + results->Store(hB.back(),hB.back()->GetTitle()); + } + + + for (UInt_t iev=0; iev < fEventSample.size(); iev++){ + if (fEventSample[iev]->GetBoostWeight() > max) max = 1.01*fEventSample[iev]->GetBoostWeight(); + } + TH1F *tmpBoostWeightsS = new TH1F(Form("BoostWeightsInTreeS%d",iTree),Form("BoostWeightsInTreeS%d",iTree),100,0.,max); + TH1F *tmpBoostWeightsB = new TH1F(Form("BoostWeightsInTreeB%d",iTree),Form("BoostWeightsInTreeB%d",iTree),100,0.,max); + results->Store(tmpBoostWeightsS,tmpBoostWeightsS->GetTitle()); + results->Store(tmpBoostWeightsB,tmpBoostWeightsB->GetTitle()); + + TH1F *tmpBoostWeights; + std::vector<TH1F*> *h; - if (event->GetClass() == signalClassNr) tmp=tmpS; - else tmp=tmpB; - tmp->Fill(PrivateGetMvaValue(*event),event->GetWeight()); + for (UInt_t iev=0; iev < fEventSample.size(); iev++){ + if (fEventSample[iev]->GetClass() == signalClassNr) { + tmpBoostWeights=tmpBoostWeightsS; + h=&hS; + }else{ + tmpBoostWeights=tmpBoostWeightsB; + h=&hB; + } + tmpBoostWeights->Fill(fEventSample[iev]->GetBoostWeight()); + for (UInt_t ivar=0; ivar<GetNvar(); ivar++){ + (*h)[ivar]->Fill(fEventSample[iev]->GetValue(ivar),fEventSample[iev]->GetWeight()); + } } + TMVA::PDF *sig = new TMVA::PDF( " PDF Sig", tmpS, TMVA::PDF::kSpline3 ); TMVA::PDF *bkg = new TMVA::PDF( " PDF Bkg", tmpB, TMVA::PDF::kSpline3 ); - Results* results = Data()->GetResults(GetMethodName(),Types::kTraining, Types::kMaxAnalysisType); + TGraph* gr=results->GetGraph("BoostMonitorGraph"); Int_t nPoints = gr->GetN(); gr->Set(nPoints+1); @@ -1391,7 +1637,7 @@ void TMVA::MethodBDT::BoostMonitor(Int_t iTree) } //_______________________________________________________________________ -Double_t TMVA::MethodBDT::AdaBoost( vector<TMVA::Event*> eventSample, DecisionTree *dt ) +Double_t TMVA::MethodBDT::AdaBoost( std::vector<const TMVA::Event*>& eventSample, DecisionTree *dt ) { // the AdaBoost implementation. // a new training sample is generated by weighting @@ -1405,34 +1651,38 @@ Double_t TMVA::MethodBDT::AdaBoost( vector<TMVA::Event*> eventSample, DecisionTr Double_t err=0, sumGlobalw=0, sumGlobalwfalse=0, sumGlobalwfalse2=0; - vector<Double_t> sumw; //for individually re-scaling each class - map<Node*,Int_t> sigEventsInNode; // how many signal events of the training tree + std::vector<Double_t> sumw(DataInfo().GetNClasses(),0); //for individually re-scaling each class + std::map<Node*,Int_t> sigEventsInNode; // how many signal events of the training tree - UInt_t maxCls = sumw.size(); Double_t maxDev=0; - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { Double_t w = (*e)->GetWeight(); sumGlobalw += w; UInt_t iclass=(*e)->GetClass(); - if (iclass+1 > maxCls) { - sumw.resize(iclass+1,0); - maxCls = sumw.size(); - } sumw[iclass] += w; if ( DoRegression() ) { - Double_t tmpDev = TMath::Abs(dt->CheckEvent(*(*e),kFALSE) - (*e)->GetTarget(0) ); + Double_t tmpDev = TMath::Abs(dt->CheckEvent(*e,kFALSE) - (*e)->GetTarget(0) ); sumGlobalwfalse += w * tmpDev; sumGlobalwfalse2 += w * tmpDev*tmpDev; if (tmpDev > maxDev) maxDev = tmpDev; }else{ - Bool_t isSignalType = (dt->CheckEvent(*(*e),fUseYesNoLeaf) > fNodePurityLimit ); - if (!(isSignalType == DataInfo().IsSignal(*e))) { - sumGlobalwfalse+= w; + if (fUseYesNoLeaf){ + Bool_t isSignalType = (dt->CheckEvent(*e,fUseYesNoLeaf) > fNodePurityLimit ); + if (!(isSignalType == DataInfo().IsSignal(*e))) { + sumGlobalwfalse+= w; + } + }else{ + Double_t dtoutput = (dt->CheckEvent(*e,fUseYesNoLeaf) - 0.5)*2.; + Int_t trueType; + if (DataInfo().IsSignal(*e)) trueType = 1; + else trueType = -1; + sumGlobalwfalse+= w*trueType*dtoutput; } } } + err = sumGlobalwfalse/sumGlobalw ; if ( DoRegression() ) { //if quadratic loss: @@ -1444,9 +1694,9 @@ Double_t TMVA::MethodBDT::AdaBoost( vector<TMVA::Event*> eventSample, DecisionTr } else if (fAdaBoostR2Loss=="exponential"){ err = 0; - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { Double_t w = (*e)->GetWeight(); - Double_t tmpDev = TMath::Abs(dt->CheckEvent(*(*e),kFALSE) - (*e)->GetTarget(0) ); + Double_t tmpDev = TMath::Abs(dt->CheckEvent(*e,kFALSE) - (*e)->GetTarget(0) ); err += w * (1 - exp (-tmpDev/maxDev)) / sumGlobalw; } @@ -1462,10 +1712,10 @@ Double_t TMVA::MethodBDT::AdaBoost( vector<TMVA::Event*> eventSample, DecisionTr Double_t newSumGlobalw=0; - vector<Double_t> newSumw(sumw.size(),0); + std::vector<Double_t> newSumw(sumw.size(),0); Double_t boostWeight=1.; - if (err >= 0.5) { // sanity check ... should never happen as otherwise there is apparently + if (err >= 0.5 && fUseYesNoLeaf) { // sanity check ... should never happen as otherwise there is apparently // something odd with the assignement of the leaf nodes (rem: you use the training // events for this determination of the error rate) if (dt->GetNNodes() == 1){ @@ -1478,7 +1728,8 @@ Double_t TMVA::MethodBDT::AdaBoost( vector<TMVA::Event*> eventSample, DecisionTr }else{ Log() << kERROR << " The error rate in the BDT boosting is > 0.5. ("<< err << ") That should not happen, please check your code (i.e... the BDT code), I " - << " set it to 0.5.. just to continue.." << Endl; + << " stop boosting here" << Endl; + return -1; } err = 0.5; } else if (err < 0) { @@ -1488,28 +1739,49 @@ Double_t TMVA::MethodBDT::AdaBoost( vector<TMVA::Event*> eventSample, DecisionTr << " for the time being I set it to its absolute value.. just to continue.." << Endl; err = TMath::Abs(err); } - if (fAdaBoostBeta == 1) { - boostWeight = (1.-err)/err; - } - else { - boostWeight = TMath::Power((1.0 - err)/err, fAdaBoostBeta); - } + if (fUseYesNoLeaf) + boostWeight = TMath::Log((1.-err)/err)*fAdaBoostBeta; + else + boostWeight = TMath::Log((1.+err)/(1-err))*fAdaBoostBeta; + + Log() << kDEBUG << "BDT AdaBoos wrong/all: " << sumGlobalwfalse << "/" << sumGlobalw << " 1-err/err="<<boostWeight<< " log.."<<TMath::Log(boostWeight)<<Endl; Results* results = Data()->GetResults(GetMethodName(),Types::kTraining, Types::kMaxAnalysisType); - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { - if ((!( (dt->CheckEvent(*(*e),fUseYesNoLeaf) > fNodePurityLimit ) == DataInfo().IsSignal(*e))) || DoRegression()) { - Double_t boostfactor = boostWeight; - if (DoRegression()) boostfactor = TMath::Power(1/boostWeight,(1.-TMath::Abs(dt->CheckEvent(*(*e),kFALSE) - (*e)->GetTarget(0) )/maxDev ) ); + if (fUseYesNoLeaf||DoRegression()){ + if ((!( (dt->CheckEvent(*e,fUseYesNoLeaf) > fNodePurityLimit ) == DataInfo().IsSignal(*e))) || DoRegression()) { + Double_t boostfactor = TMath::Exp(boostWeight); + + if (DoRegression()) boostfactor = TMath::Power(1/boostWeight,(1.-TMath::Abs(dt->CheckEvent(*e,kFALSE) - (*e)->GetTarget(0) )/maxDev ) ); + if ( (*e)->GetWeight() > 0 ){ + (*e)->SetBoostWeight( (*e)->GetBoostWeight() * boostfactor); + // Helge change back (*e)->ScaleBoostWeight(boostfactor); + if (DoRegression()) results->GetHist("BoostWeights")->Fill(boostfactor); + } else { + if ( fInverseBoostNegWeights )(*e)->ScaleBoostWeight( 1. / boostfactor); // if the original event weight is negative, and you want to "increase" the events "positive" influence, you'd reather make the event weight "smaller" in terms of it's absolute value while still keeping it something "negative" + else (*e)->SetBoostWeight( (*e)->GetBoostWeight() * boostfactor); + + } + } + + }else{ + Double_t dtoutput = (dt->CheckEvent(*e,fUseYesNoLeaf) - 0.5)*2.; + Int_t trueType; + if (DataInfo().IsSignal(*e)) trueType = 1; + else trueType = -1; + Double_t boostfactor = TMath::Exp(-1*boostWeight*trueType*dtoutput); + if ( (*e)->GetWeight() > 0 ){ (*e)->SetBoostWeight( (*e)->GetBoostWeight() * boostfactor); // Helge change back (*e)->ScaleBoostWeight(boostfactor); if (DoRegression()) results->GetHist("BoostWeights")->Fill(boostfactor); } else { if ( fInverseBoostNegWeights )(*e)->ScaleBoostWeight( 1. / boostfactor); // if the original event weight is negative, and you want to "increase" the events "positive" influence, you'd reather make the event weight "smaller" in terms of it's absolute value while still keeping it something "negative" + else (*e)->SetBoostWeight( (*e)->GetBoostWeight() * boostfactor); } } newSumGlobalw+=(*e)->GetWeight(); @@ -1517,16 +1789,16 @@ Double_t TMVA::MethodBDT::AdaBoost( vector<TMVA::Event*> eventSample, DecisionTr } - // re-normalise the weights (independent for Signal and Background) - Double_t globalNormWeight=sumGlobalw/newSumGlobalw; - vector<Double_t> normWeightByClass; - for (UInt_t i=0; i<sumw.size(); i++) normWeightByClass.push_back(sumw[i]/newSumw[i]); - + // Double_t globalNormWeight=sumGlobalw/newSumGlobalw; + Double_t globalNormWeight=( (Double_t) eventSample.size())/newSumGlobalw; Log() << kDEBUG << "new Nsig="<<newSumw[0]*globalNormWeight << " new Nbkg="<<newSumw[1]*globalNormWeight << Endl; - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { - if (fRenormByClass) (*e)->ScaleBoostWeight( normWeightByClass[(*e)->GetClass()] ); + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { + // if (fRenormByClass) (*e)->ScaleBoostWeight( normWeightByClass[(*e)->GetClass()] ); + // else (*e)->ScaleBoostWeight( globalNormWeight ); + // else (*e)->ScaleBoostWeight( globalNormWeight ); + if (DataInfo().IsSignal(*e))(*e)->ScaleBoostWeight( globalNormWeight * fSigToBkgFraction ); else (*e)->ScaleBoostWeight( globalNormWeight ); } @@ -1537,38 +1809,187 @@ Double_t TMVA::MethodBDT::AdaBoost( vector<TMVA::Event*> eventSample, DecisionTr fBoostWeight = boostWeight; fErrorFraction = err; - if (fBaggedGradBoost){ - GetRandomSubSample(); + return boostWeight; +} + + +//_______________________________________________________________________ +Double_t TMVA::MethodBDT::AdaCost( vector<const TMVA::Event*>& eventSample, DecisionTree *dt ) +{ + // the AdaCost boosting algorithm takes a simple cost Matrix (currently fixed for + // all events... later could be modified to use individual cost matrices for each + // events as in the original paper... + // + // true_signal true_bkg + // ---------------------------------- + // sel_signal | Css Ctb_ss Cxx.. in the range [0,1] + // sel_bkg | Cts_sb Cbb + // + // and takes this into account when calculating the misclass. cost (former: error fraction): + // + // err = sum_events ( weight* y_true*y_sel * beta(event) + // + + Double_t Css = fCss; + Double_t Cbb = fCbb; + Double_t Cts_sb = fCts_sb; + Double_t Ctb_ss = fCtb_ss; + + Double_t err=0, sumGlobalWeights=0, sumGlobalCost=0; + + std::vector<Double_t> sumw(DataInfo().GetNClasses(),0); //for individually re-scaling each class + std::map<Node*,Int_t> sigEventsInNode; // how many signal events of the training tree + + for (vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { + Double_t w = (*e)->GetWeight(); + sumGlobalWeights += w; + UInt_t iclass=(*e)->GetClass(); + + sumw[iclass] += w; + + if ( DoRegression() ) { + Log() << kFATAL << " AdaCost not implemented for regression"<<Endl; + }else{ + + Double_t dtoutput = (dt->CheckEvent(*e,false) - 0.5)*2.; + Int_t trueType; + Bool_t isTrueSignal = DataInfo().IsSignal(*e); + Bool_t isSelectedSignal = (dtoutput>0); + if (isTrueSignal) trueType = 1; + else trueType = -1; + + Double_t cost=0; + if (isTrueSignal && isSelectedSignal) cost=Css; + else if (isTrueSignal && !isSelectedSignal) cost=Cts_sb; + else if (!isTrueSignal && isSelectedSignal) cost=Ctb_ss; + else if (!isTrueSignal && !isSelectedSignal) cost=Cbb; + else Log() << kERROR << "something went wrong in AdaCost" << Endl; + + sumGlobalCost+= w*trueType*dtoutput*cost; + + } + } + + if ( DoRegression() ) { + Log() << kFATAL << " AdaCost not implemented for regression"<<Endl; + } + + // Log() << kDEBUG << "BDT AdaBoos wrong/all: " << sumGlobalCost << "/" << sumGlobalWeights << Endl; + // Log() << kWARNING << "BDT AdaBoos wrong/all: " << sumGlobalCost << "/" << sumGlobalWeights << Endl; + sumGlobalCost /= sumGlobalWeights; + // Log() << kWARNING << "BDT AdaBoos wrong/all: " << sumGlobalCost << "/" << sumGlobalWeights << Endl; + + + Double_t newSumGlobalWeights=0; + vector<Double_t> newSumClassWeights(sumw.size(),0); + + Double_t boostWeight = TMath::Log((1+sumGlobalCost)/(1-sumGlobalCost)) * fAdaBoostBeta; + + Results* results = Data()->GetResults(GetMethodName(),Types::kTraining, Types::kMaxAnalysisType); + + for (vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { + Double_t dtoutput = (dt->CheckEvent(*e,false) - 0.5)*2.; + Int_t trueType; + Bool_t isTrueSignal = DataInfo().IsSignal(*e); + Bool_t isSelectedSignal = (dtoutput>0); + if (isTrueSignal) trueType = 1; + else trueType = -1; + + Double_t cost=0; + if (isTrueSignal && isSelectedSignal) cost=Css; + else if (isTrueSignal && !isSelectedSignal) cost=Cts_sb; + else if (!isTrueSignal && isSelectedSignal) cost=Ctb_ss; + else if (!isTrueSignal && !isSelectedSignal) cost=Cbb; + else Log() << kERROR << "something went wrong in AdaCost" << Endl; + + Double_t boostfactor = TMath::Exp(-1*boostWeight*trueType*dtoutput*cost); + if (DoRegression())Log() << kFATAL << " AdaCost not implemented for regression"<<Endl; + if ( (*e)->GetWeight() > 0 ){ + (*e)->SetBoostWeight( (*e)->GetBoostWeight() * boostfactor); + // Helge change back (*e)->ScaleBoostWeight(boostfactor); + if (DoRegression())Log() << kFATAL << " AdaCost not implemented for regression"<<Endl; + } else { + if ( fInverseBoostNegWeights )(*e)->ScaleBoostWeight( 1. / boostfactor); // if the original event weight is negative, and you want to "increase" the events "positive" influence, you'd reather make the event weight "smaller" in terms of it's absolute value while still keeping it something "negative" + } + + newSumGlobalWeights+=(*e)->GetWeight(); + newSumClassWeights[(*e)->GetClass()] += (*e)->GetWeight(); } - return TMath::Log(boostWeight); + + // Double_t globalNormWeight=sumGlobalWeights/newSumGlobalWeights; + Double_t globalNormWeight=Double_t(eventSample.size())/newSumGlobalWeights; + Log() << kDEBUG << "new Nsig="<<newSumClassWeights[0]*globalNormWeight << " new Nbkg="<<newSumClassWeights[1]*globalNormWeight << Endl; + + + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { + // if (fRenormByClass) (*e)->ScaleBoostWeight( normWeightByClass[(*e)->GetClass()] ); + // else (*e)->ScaleBoostWeight( globalNormWeight ); + if (DataInfo().IsSignal(*e))(*e)->ScaleBoostWeight( globalNormWeight * fSigToBkgFraction ); + else (*e)->ScaleBoostWeight( globalNormWeight ); + } + + + if (!(DoRegression()))results->GetHist("BoostWeights")->Fill(boostWeight); + results->GetHist("BoostWeightsVsTree")->SetBinContent(fForest.size(),boostWeight); + results->GetHist("ErrorFrac")->SetBinContent(fForest.size(),err); + + fBoostWeight = boostWeight; + fErrorFraction = err; + + + return boostWeight; } + //_______________________________________________________________________ -Double_t TMVA::MethodBDT::Bagging( vector<TMVA::Event*> eventSample, Int_t iTree ) +Double_t TMVA::MethodBDT::Bagging( ) { // call it boot-strapping, re-sampling or whatever you like, in the end it is nothing - // else but applying "random" weights to each event. - Double_t newSumw=0; - Double_t newWeight; - TRandom3 *trandom = new TRandom3(iTree); - Double_t eventFraction = fUseNTrainEvents/Data()->GetNTrainingEvents(); - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { - newWeight = trandom->PoissonD(eventFraction); - (*e)->SetBoostWeight(newWeight); - newSumw+=(*e)->GetBoostWeight(); - } - Double_t normWeight = eventSample.size() / newSumw ; - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { - (*e)->SetBoostWeight( (*e)->GetBoostWeight() * normWeight ); - // change this backwards (*e)->ScaleBoostWeight( normWeight ); + // else but applying "random" poisson weights to each event. + + // this is now done in "MethodBDT::Boost as it might be used by other boost methods, too + // GetBaggedSample(eventSample); + + return 1.; //here as there are random weights for each event, just return a constant==1; +} + +//_______________________________________________________________________ +void TMVA::MethodBDT::GetBaggedSubSample(std::vector<const TMVA::Event*>& eventSample) +{ + // fills fEventSample with fBaggedSampleFraction*NEvents random training events + + + Double_t n; + TRandom3 *trandom = new TRandom3(100*fForest.size()+1234); + + if (!fSubSample.empty()) fSubSample.clear(); + + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { + n = trandom->PoissonD(fBaggedSampleFraction); + for (Int_t i=0;i<n;i++) fSubSample.push_back(*e); } + delete trandom; - return 1.; //here as there are random weights for each event, just return a constant==1; + return; + + /* + UInt_t nevents = fEventSample.size(); + + if (!fSubSample.empty()) fSubSample.clear(); + TRandom3 *trandom = new TRandom3(fForest.size()+1); + + for (UInt_t ievt=0; ievt<nevents; ievt++) { // recreate new random subsample + if(trandom->Rndm()<fBaggedSampleFraction) + fSubSample.push_back(fEventSample[ievt]); + } + delete trandom; + */ + } //_______________________________________________________________________ -Double_t TMVA::MethodBDT::RegBoost( vector<TMVA::Event*> /* eventSample */, DecisionTree* /* dt */ ) +Double_t TMVA::MethodBDT::RegBoost( std::vector<const TMVA::Event*>& /* eventSample */, DecisionTree* /* dt */ ) { // a special boosting only for Regression ... // maybe I'll implement it later... @@ -1577,7 +1998,7 @@ Double_t TMVA::MethodBDT::RegBoost( vector<TMVA::Event*> /* eventSample */, Deci } //_______________________________________________________________________ -Double_t TMVA::MethodBDT::AdaBoostR2( vector<TMVA::Event*> eventSample, DecisionTree *dt ) +Double_t TMVA::MethodBDT::AdaBoostR2( std::vector<const TMVA::Event*>& eventSample, DecisionTree *dt ) { // adaption of the AdaBoost to regression problems (see H.Drucker 1997) @@ -1585,11 +2006,11 @@ Double_t TMVA::MethodBDT::AdaBoostR2( vector<TMVA::Event*> eventSample, Decision Double_t err=0, sumw=0, sumwfalse=0, sumwfalse2=0; Double_t maxDev=0; - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { Double_t w = (*e)->GetWeight(); sumw += w; - Double_t tmpDev = TMath::Abs(dt->CheckEvent(*(*e),kFALSE) - (*e)->GetTarget(0) ); + Double_t tmpDev = TMath::Abs(dt->CheckEvent(*e,kFALSE) - (*e)->GetTarget(0) ); sumwfalse += w * tmpDev; sumwfalse2 += w * tmpDev*tmpDev; if (tmpDev > maxDev) maxDev = tmpDev; @@ -1604,9 +2025,9 @@ Double_t TMVA::MethodBDT::AdaBoostR2( vector<TMVA::Event*> eventSample, Decision } else if (fAdaBoostR2Loss=="exponential"){ err = 0; - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { Double_t w = (*e)->GetWeight(); - Double_t tmpDev = TMath::Abs(dt->CheckEvent(*(*e),kFALSE) - (*e)->GetTarget(0) ); + Double_t tmpDev = TMath::Abs(dt->CheckEvent(*e,kFALSE) - (*e)->GetTarget(0) ); err += w * (1 - exp (-tmpDev/maxDev)) / sumw; } @@ -1632,7 +2053,8 @@ Double_t TMVA::MethodBDT::AdaBoostR2( vector<TMVA::Event*> eventSample, Decision Log() << kERROR << " The error rate in the BDT boosting is > 0.5. ("<< err << ") That should not happen, but is possible for regression trees, and" << " should trigger a stop for the boosting. please check your code (i.e... the BDT code), I " - << " set it to 0.5.. just to continue.." << Endl; + << " stop boosting " << Endl; + return -1; } err = 0.5; } else if (err < 0) { @@ -1648,10 +2070,10 @@ Double_t TMVA::MethodBDT::AdaBoostR2( vector<TMVA::Event*> eventSample, Decision Results* results = Data()->GetResults(GetMethodName(), Types::kTraining, Types::kMaxAnalysisType); - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { - Double_t boostfactor = TMath::Power(boostWeight,(1.-TMath::Abs(dt->CheckEvent(*(*e),kFALSE) - (*e)->GetTarget(0) )/maxDev ) ); + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { + Double_t boostfactor = TMath::Power(boostWeight,(1.-TMath::Abs(dt->CheckEvent(*e,kFALSE) - (*e)->GetTarget(0) )/maxDev ) ); results->GetHist("BoostWeights")->Fill(boostfactor); - // cout << "R2 " << boostfactor << " " << boostWeight << " " << (1.-TMath::Abs(dt->CheckEvent(*(*e),kFALSE) - (*e)->GetTarget(0) )/maxDev) << endl; + // std::cout << "R2 " << boostfactor << " " << boostWeight << " " << (1.-TMath::Abs(dt->CheckEvent(*e,kFALSE) - (*e)->GetTarget(0) )/maxDev) << std::endl; if ( (*e)->GetWeight() > 0 ){ Float_t newBoostWeight = (*e)->GetBoostWeight() * boostfactor; Float_t newWeight = (*e)->GetWeight() * (*e)->GetBoostWeight() * boostfactor; @@ -1662,9 +2084,9 @@ Double_t TMVA::MethodBDT::AdaBoostR2( vector<TMVA::Event*> eventSample, Decision Log() << kINFO << "NewBoostWeight= " << newBoostWeight << Endl; Log() << kINFO << "boostfactor= " << boostfactor << Endl; Log() << kINFO << "maxDev = " << maxDev << Endl; - Log() << kINFO << "tmpDev = " << TMath::Abs(dt->CheckEvent(*(*e),kFALSE) - (*e)->GetTarget(0) ) << Endl; + Log() << kINFO << "tmpDev = " << TMath::Abs(dt->CheckEvent(*e,kFALSE) - (*e)->GetTarget(0) ) << Endl; Log() << kINFO << "target = " << (*e)->GetTarget(0) << Endl; - Log() << kINFO << "estimate = " << dt->CheckEvent(*(*e),kFALSE) << Endl; + Log() << kINFO << "estimate = " << dt->CheckEvent(*e,kFALSE) << Endl; } (*e)->SetBoostWeight( newBoostWeight ); // (*e)->SetBoostWeight( (*e)->GetBoostWeight() * boostfactor); @@ -1676,7 +2098,7 @@ Double_t TMVA::MethodBDT::AdaBoostR2( vector<TMVA::Event*> eventSample, Decision // re-normalise the weights Double_t normWeight = sumw / newSumw; - for (vector<TMVA::Event*>::iterator e=eventSample.begin(); e!=eventSample.end();e++) { + for (std::vector<const TMVA::Event*>::const_iterator e=eventSample.begin(); e!=eventSample.end();e++) { //Helge (*e)->ScaleBoostWeight( sumw/newSumw); // (*e)->ScaleBoostWeight( normWeight); (*e)->SetBoostWeight( (*e)->GetBoostWeight() * normWeight ); @@ -1697,6 +2119,21 @@ void TMVA::MethodBDT::AddWeightsXMLTo( void* parent ) const { // write weights to XML void* wght = gTools().AddChild(parent, "Weights"); + + if (fDoPreselection){ + for (UInt_t ivar=0; ivar<GetNvar(); ivar++){ + gTools().AddAttr( wght, Form("PreselectionLowBkgVar%d",ivar), fIsLowBkgCut[ivar]); + gTools().AddAttr( wght, Form("PreselectionLowBkgVar%dValue",ivar), fLowBkgCut[ivar]); + gTools().AddAttr( wght, Form("PreselectionLowSigVar%d",ivar), fIsLowSigCut[ivar]); + gTools().AddAttr( wght, Form("PreselectionLowSigVar%dValue",ivar), fLowSigCut[ivar]); + gTools().AddAttr( wght, Form("PreselectionHighBkgVar%d",ivar), fIsHighBkgCut[ivar]); + gTools().AddAttr( wght, Form("PreselectionHighBkgVar%dValue",ivar),fHighBkgCut[ivar]); + gTools().AddAttr( wght, Form("PreselectionHighSigVar%d",ivar), fIsHighSigCut[ivar]); + gTools().AddAttr( wght, Form("PreselectionHighSigVar%dValue",ivar),fHighSigCut[ivar]); + } + } + + gTools().AddAttr( wght, "NTrees", fForest.size() ); gTools().AddAttr( wght, "AnalysisType", fForest.back()->GetAnalysisType() ); @@ -1720,6 +2157,40 @@ void TMVA::MethodBDT::ReadWeightsFromXML(void* parent) { UInt_t analysisType; Float_t boostWeight; + + if (gTools().HasAttr( parent, Form("PreselectionLowBkgVar%d",0))) { + fIsLowBkgCut.resize(GetNvar()); + fLowBkgCut.resize(GetNvar()); + fIsLowSigCut.resize(GetNvar()); + fLowSigCut.resize(GetNvar()); + fIsHighBkgCut.resize(GetNvar()); + fHighBkgCut.resize(GetNvar()); + fIsHighSigCut.resize(GetNvar()); + fHighSigCut.resize(GetNvar()); + + Bool_t tmpBool; + Double_t tmpDouble; + for (UInt_t ivar=0; ivar<GetNvar(); ivar++){ + gTools().ReadAttr( parent, Form("PreselectionLowBkgVar%d",ivar), tmpBool); + fIsLowBkgCut[ivar]=tmpBool; + gTools().ReadAttr( parent, Form("PreselectionLowBkgVar%dValue",ivar), tmpDouble); + fLowBkgCut[ivar]=tmpDouble; + gTools().ReadAttr( parent, Form("PreselectionLowSigVar%d",ivar), tmpBool); + fIsLowSigCut[ivar]=tmpBool; + gTools().ReadAttr( parent, Form("PreselectionLowSigVar%dValue",ivar), tmpDouble); + fLowSigCut[ivar]=tmpDouble; + gTools().ReadAttr( parent, Form("PreselectionHighBkgVar%d",ivar), tmpBool); + fIsHighBkgCut[ivar]=tmpBool; + gTools().ReadAttr( parent, Form("PreselectionHighBkgVar%dValue",ivar), tmpDouble); + fHighBkgCut[ivar]=tmpDouble; + gTools().ReadAttr( parent, Form("PreselectionHighSigVar%d",ivar),tmpBool); + fIsHighSigCut[ivar]=tmpBool; + gTools().ReadAttr( parent, Form("PreselectionHighSigVar%dValue",ivar), tmpDouble); + fHighSigCut[ivar]=tmpDouble; + } + } + + gTools().ReadAttr( parent, "NTrees", ntrees ); if(gTools().HasAttr(parent, "TreeType")) { // pre 4.1.0 version @@ -1741,7 +2212,7 @@ void TMVA::MethodBDT::ReadWeightsFromXML(void* parent) { } //_______________________________________________________________________ -void TMVA::MethodBDT::ReadWeightsFromStream( istream& istr ) +void TMVA::MethodBDT::ReadWeightsFromStream( std::istream& istr ) { // read the weights (BDT coefficients) TString dummy; @@ -1760,7 +2231,7 @@ void TMVA::MethodBDT::ReadWeightsFromStream( istream& istr ) for (int i=0;i<fNTrees;i++) { istr >> dummy >> iTree >> dummy >> boostWeight; if (iTree != i) { - fForest.back()->Print( cout ); + fForest.back()->Print( std::cout ); Log() << kFATAL << "Error while reading weight file; mismatch iTree=" << iTree << " i=" << i << " dummy " << dummy @@ -1787,11 +2258,15 @@ Double_t TMVA::MethodBDT::GetMvaValue( Double_t* err, Double_t* errUpper, UInt_t // event according to the majority vote from the total number of // decision trees. const Event* ev = GetEvent(); - return PrivateGetMvaValue(const_cast<TMVA::Event&>(*ev), err, errUpper, useNTrees); + if (fDoPreselection) { + Double_t val = ApplyPreselectionCuts(ev); + if (TMath::Abs(val)>0.05) return val; + } + return PrivateGetMvaValue(ev, err, errUpper, useNTrees); } //_______________________________________________________________________ - Double_t TMVA::MethodBDT::PrivateGetMvaValue(TMVA::Event& ev, Double_t* err, Double_t* errUpper, UInt_t useNTrees ) +Double_t TMVA::MethodBDT::PrivateGetMvaValue(const TMVA::Event* ev, Double_t* err, Double_t* errUpper, UInt_t useNTrees ) { // Return the MVA value (range [-1;1]) that classifies the // event according to the majority vote from the total number of @@ -1812,14 +2287,8 @@ Double_t TMVA::MethodBDT::GetMvaValue( Double_t* err, Double_t* errUpper, UInt_t Double_t norm = 0; for (UInt_t itree=0; itree<nTrees; itree++) { // - if (fUseWeightedTrees) { - myMVA += fBoostWeights[itree] * fForest[itree]->CheckEvent(ev,fUseYesNoLeaf); - norm += fBoostWeights[itree]; - } - else { - myMVA += fForest[itree]->CheckEvent(ev,fUseYesNoLeaf); - norm += 1; - } + myMVA += fBoostWeights[itree] * fForest[itree]->CheckEvent(ev,fUseYesNoLeaf); + norm += fBoostWeights[itree]; } return ( norm > std::numeric_limits<double>::epsilon() ) ? myMVA /= norm : 0 ; } @@ -1830,7 +2299,7 @@ const std::vector<Float_t>& TMVA::MethodBDT::GetMulticlassValues() { // get the multiclass MVA response for the BDT classifier - const TMVA::Event& e = *GetEvent(); + const TMVA::Event *e = GetEvent(); if (fMulticlassReturnVal == NULL) fMulticlassReturnVal = new std::vector<Float_t>(); fMulticlassReturnVal->clear(); @@ -1890,12 +2359,12 @@ const std::vector<Float_t> & TMVA::MethodBDT::GetRegressionValues() Double_t totalSumOfWeights = 0; for (UInt_t itree=0; itree<fForest.size(); itree++) { - response[itree] = fForest[itree]->CheckEvent(*ev,kFALSE); + response[itree] = fForest[itree]->CheckEvent(ev,kFALSE); weight[itree] = fBoostWeights[itree]; totalSumOfWeights += fBoostWeights[itree]; } - vector< vector<Double_t> > vtemp; + std::vector< std::vector<Double_t> > vtemp; vtemp.push_back( response ); // this is the vector that will get sorted vtemp.push_back( weight ); gTools().UsefulSortAscending( vtemp ); @@ -1919,7 +2388,7 @@ const std::vector<Float_t> & TMVA::MethodBDT::GetRegressionValues() } else if(fBoostType=="Grad"){ for (UInt_t itree=0; itree<fForest.size(); itree++) { - myMVA += fForest[itree]->CheckEvent(*ev,kFALSE); + myMVA += fForest[itree]->CheckEvent(ev,kFALSE); } // fRegressionReturnVal->push_back( myMVA+fBoostWeights[0]); evT->SetTarget(0, myMVA+fBoostWeights[0] ); @@ -1927,14 +2396,8 @@ const std::vector<Float_t> & TMVA::MethodBDT::GetRegressionValues() else{ for (UInt_t itree=0; itree<fForest.size(); itree++) { // - if (fUseWeightedTrees) { - myMVA += fBoostWeights[itree] * fForest[itree]->CheckEvent(*ev,kFALSE); - norm += fBoostWeights[itree]; - } - else { - myMVA += fForest[itree]->CheckEvent(*ev,kFALSE); - norm += 1; - } + myMVA += fBoostWeights[itree] * fForest[itree]->CheckEvent(ev,kFALSE); + norm += fBoostWeights[itree]; } // fRegressionReturnVal->push_back( ( norm > std::numeric_limits<double>::epsilon() ) ? myMVA /= norm : 0 ); evT->SetTarget(0, ( norm > std::numeric_limits<double>::epsilon() ) ? myMVA /= norm : 0 ); @@ -1976,8 +2439,8 @@ vector< Double_t > TMVA::MethodBDT::GetVariableImportance() fVariableImportance[ivar]=0; } Double_t sum=0; - for (int itree = 0; itree < fNTrees; itree++) { - vector<Double_t> relativeImportance(fForest[itree]->GetVariableImportance()); + for (UInt_t itree = 0; itree < GetNTrees(); itree++) { + std::vector<Double_t> relativeImportance(fForest[itree]->GetVariableImportance()); for (UInt_t i=0; i< relativeImportance.size(); i++) { fVariableImportance[i] += fBoostWeights[itree] * relativeImportance[i]; } @@ -1999,7 +2462,7 @@ Double_t TMVA::MethodBDT::GetVariableImportance( UInt_t ivar ) // which is later used in GetVariableImportance() to calculate the // relative variable importances. - vector<Double_t> relativeImportance = this->GetVariableImportance(); + std::vector<Double_t> relativeImportance = this->GetVariableImportance(); if (ivar < (UInt_t)relativeImportance.size()) return relativeImportance[ivar]; else Log() << kFATAL << "<GetVariableImportance> ivar = " << ivar << " is out of range " << Endl; @@ -2059,14 +2522,14 @@ void TMVA::MethodBDT::GetHelpMessage() const Log() << gTools().Color("bold") << "--- Performance tuning via configuration options:" << gTools().Color("reset") << Endl; Log() << Endl; Log() << "The two most important parameters in the configuration are the " << Endl; - Log() << "minimal number of events requested by a leaf node (option " << Endl; - Log() << "\"nEventsMin\"). If this number is too large, detailed features " << Endl; - Log() << "in the parameter space cannot be modelled. If it is too small, " << Endl; - Log() << "the risk to overtrain rises." << Endl; - Log() << " (Imagine the decision tree is split until the leaf node contains" << Endl; - Log() << " only a single event. In such a case, no training event is " << Endl; - Log() << " misclassified, while the situation will look very different" << Endl; - Log() << " for the test sample.)" << Endl; + Log() << "minimal number of events requested by a leaf node as percentage of the " <<Endl; + Log() << " number of training events (option \"MinNodeSize\" replacing the actual number " << Endl; + Log() << " of events \"nEventsMin\" as given in earlier versions" << Endl; + Log() << "If this number is too large, detailed features " << Endl; + Log() << "in the parameter space are hard to be modelled. If it is too small, " << Endl; + Log() << "the risk to overtrain rises and boosting seems to be less effective" << Endl; + Log() << " typical values from our current expericience for best performance " << Endl; + Log() << " are between 0.5(%) and 10(%) " << Endl; Log() << Endl; Log() << "The default minimal number is currently set to " << Endl; Log() << " max(20, (N_training_events / N_variables^2 / 10)) " << Endl; @@ -2091,60 +2554,71 @@ void TMVA::MethodBDT::MakeClassSpecific( std::ostream& fout, const TString& clas nodeName.ReplaceAll("Read",""); nodeName.Append("Node"); // write BDT-specific classifier response - fout << " std::vector<"<<nodeName<<"*> fForest; // i.e. root nodes of decision trees" << endl; - fout << " std::vector<double> fBoostWeights; // the weights applied in the individual boosts" << endl; - fout << "};" << endl << endl; - fout << "double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << endl; - fout << "{" << endl; - fout << " double myMVA = 0;" << endl; + fout << " std::vector<"<<nodeName<<"*> fForest; // i.e. root nodes of decision trees" << std::endl; + fout << " std::vector<double> fBoostWeights; // the weights applied in the individual boosts" << std::endl; + fout << "};" << std::endl << std::endl; + fout << "double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << std::endl; + fout << "{" << std::endl; + fout << " double myMVA = 0;" << std::endl; + if (fDoPreselection){ + for (UInt_t ivar = 0; ivar< fIsLowBkgCut.size(); ivar++){ + if (fIsLowBkgCut[ivar]){ + fout << " if (inputValues["<<ivar<<"] < " << fLowBkgCut[ivar] << ") return -1; // is background preselection cut" << std::endl; + } + if (fIsLowSigCut[ivar]){ + fout << " if (inputValues["<<ivar<<"] < "<< fLowSigCut[ivar] << ") return 1; // is signal preselection cut" << std::endl; + } + if (fIsHighBkgCut[ivar]){ + fout << " if (inputValues["<<ivar<<"] > "<<fHighBkgCut[ivar] <<") return -1; // is background preselection cut" << std::endl; + } + if (fIsHighSigCut[ivar]){ + fout << " if (inputValues["<<ivar<<"] > "<<fHighSigCut[ivar]<<") return 1; // is signal preselection cut" << std::endl; + } + } + } + if (fBoostType!="Grad"){ - fout << " double norm = 0;" << endl; - } - fout << " for (unsigned int itree=0; itree<fForest.size(); itree++){" << endl; - fout << " "<<nodeName<<" *current = fForest[itree];" << endl; - fout << " while (current->GetNodeType() == 0) { //intermediate node" << endl; - fout << " if (current->GoesRight(inputValues)) current=("<<nodeName<<"*)current->GetRight();" << endl; - fout << " else current=("<<nodeName<<"*)current->GetLeft();" << endl; - fout << " }" << endl; + fout << " double norm = 0;" << std::endl; + } + fout << " for (unsigned int itree=0; itree<fForest.size(); itree++){" << std::endl; + fout << " "<<nodeName<<" *current = fForest[itree];" << std::endl; + fout << " while (current->GetNodeType() == 0) { //intermediate node" << std::endl; + fout << " if (current->GoesRight(inputValues)) current=("<<nodeName<<"*)current->GetRight();" << std::endl; + fout << " else current=("<<nodeName<<"*)current->GetLeft();" << std::endl; + fout << " }" << std::endl; if (fBoostType=="Grad"){ - fout << " myMVA += current->GetResponse();" << endl; - } - else if (fUseWeightedTrees) { - if (fUseYesNoLeaf) fout << " myMVA += fBoostWeights[itree] * current->GetNodeType();" << endl; - else fout << " myMVA += fBoostWeights[itree] * current->GetPurity();" << endl; - fout << " norm += fBoostWeights[itree];" << endl; - } - else { - if (fUseYesNoLeaf) fout << " myMVA += current->GetNodeType();" << endl; - else fout << " myMVA += current->GetPurity();" << endl; - fout << " norm += 1.;" << endl; + fout << " myMVA += current->GetResponse();" << std::endl; + }else{ + if (fUseYesNoLeaf) fout << " myMVA += fBoostWeights[itree] * current->GetNodeType();" << std::endl; + else fout << " myMVA += fBoostWeights[itree] * current->GetPurity();" << std::endl; + fout << " norm += fBoostWeights[itree];" << std::endl; } - fout << " }" << endl; + fout << " }" << std::endl; if (fBoostType=="Grad"){ - fout << " return 2.0/(1.0+exp(-2.0*myMVA))-1.0;" << endl; + fout << " return 2.0/(1.0+exp(-2.0*myMVA))-1.0;" << std::endl; } - else fout << " return myMVA /= norm;" << endl; - fout << "};" << endl << endl; - fout << "void " << className << "::Initialize()" << endl; - fout << "{" << endl; + else fout << " return myMVA /= norm;" << std::endl; + fout << "};" << std::endl << std::endl; + fout << "void " << className << "::Initialize()" << std::endl; + fout << "{" << std::endl; //Now for each decision tree, write directly the constructors of the nodes in the tree structure - for (int itree=0; itree<fNTrees; itree++) { - fout << " // itree = " << itree << endl; - fout << " fBoostWeights.push_back(" << fBoostWeights[itree] << ");" << endl; - fout << " fForest.push_back( " << endl; + for (UInt_t itree=0; itree<GetNTrees(); itree++) { + fout << " // itree = " << itree << std::endl; + fout << " fBoostWeights.push_back(" << fBoostWeights[itree] << ");" << std::endl; + fout << " fForest.push_back( " << std::endl; this->MakeClassInstantiateNode((DecisionTreeNode*)fForest[itree]->GetRoot(), fout, className); - fout <<" );" << endl; - } - fout << " return;" << endl; - fout << "};" << endl; - fout << " " << endl; - fout << "// Clean up" << endl; - fout << "inline void " << className << "::Clear() " << endl; - fout << "{" << endl; - fout << " for (unsigned int itree=0; itree<fForest.size(); itree++) { " << endl; - fout << " delete fForest[itree]; " << endl; - fout << " }" << endl; - fout << "}" << endl; + fout <<" );" << std::endl; + } + fout << " return;" << std::endl; + fout << "};" << std::endl; + fout << " " << std::endl; + fout << "// Clean up" << std::endl; + fout << "inline void " << className << "::Clear() " << std::endl; + fout << "{" << std::endl; + fout << " for (unsigned int itree=0; itree<fForest.size(); itree++) { " << std::endl; + fout << " delete fForest[itree]; " << std::endl; + fout << " }" << std::endl; + fout << "}" << std::endl; } //_______________________________________________________________________ @@ -2154,107 +2628,107 @@ void TMVA::MethodBDT::MakeClassSpecificHeader( std::ostream& fout, const TStrin TString nodeName = className; nodeName.ReplaceAll("Read",""); nodeName.Append("Node"); - //fout << "#ifndef NN" << endl; commented out on purpose see next line - fout << "#define NN new "<<nodeName << endl; // NN definition depends on individual methods. Important to have NO #ifndef if several BDT methods compile together - //fout << "#endif" << endl; commented out on purpose see previous line - fout << " " << endl; - fout << "#ifndef "<<nodeName<<"__def" << endl; - fout << "#define "<<nodeName<<"__def" << endl; - fout << " " << endl; - fout << "class "<<nodeName<<" {" << endl; - fout << " " << endl; - fout << "public:" << endl; - fout << " " << endl; - fout << " // constructor of an essentially \"empty\" node floating in space" << endl; - fout << " "<<nodeName<<" ( "<<nodeName<<"* left,"<<nodeName<<"* right," << endl; + //fout << "#ifndef NN" << std::endl; commented out on purpose see next line + fout << "#define NN new "<<nodeName << std::endl; // NN definition depends on individual methods. Important to have NO #ifndef if several BDT methods compile together + //fout << "#endif" << std::endl; commented out on purpose see previous line + fout << " " << std::endl; + fout << "#ifndef "<<nodeName<<"__def" << std::endl; + fout << "#define "<<nodeName<<"__def" << std::endl; + fout << " " << std::endl; + fout << "class "<<nodeName<<" {" << std::endl; + fout << " " << std::endl; + fout << "public:" << std::endl; + fout << " " << std::endl; + fout << " // constructor of an essentially \"empty\" node floating in space" << std::endl; + fout << " "<<nodeName<<" ( "<<nodeName<<"* left,"<<nodeName<<"* right," << std::endl; if (fUseFisherCuts){ - fout << " int nFisherCoeff," << endl; + fout << " int nFisherCoeff," << std::endl; for (UInt_t i=0;i<GetNVariables()+1;i++){ - fout << " double fisherCoeff"<<i<<"," << endl; + fout << " double fisherCoeff"<<i<<"," << std::endl; } } - fout << " int selector, double cutValue, bool cutType, " << endl; - fout << " int nodeType, double purity, double response ) :" << endl; - fout << " fLeft ( left )," << endl; - fout << " fRight ( right )," << endl; - if (fUseFisherCuts) fout << " fNFisherCoeff ( nFisherCoeff )," << endl; - fout << " fSelector ( selector )," << endl; - fout << " fCutValue ( cutValue )," << endl; - fout << " fCutType ( cutType )," << endl; - fout << " fNodeType ( nodeType )," << endl; - fout << " fPurity ( purity )," << endl; - fout << " fResponse ( response ){" << endl; + fout << " int selector, double cutValue, bool cutType, " << std::endl; + fout << " int nodeType, double purity, double response ) :" << std::endl; + fout << " fLeft ( left )," << std::endl; + fout << " fRight ( right )," << std::endl; + if (fUseFisherCuts) fout << " fNFisherCoeff ( nFisherCoeff )," << std::endl; + fout << " fSelector ( selector )," << std::endl; + fout << " fCutValue ( cutValue )," << std::endl; + fout << " fCutType ( cutType )," << std::endl; + fout << " fNodeType ( nodeType )," << std::endl; + fout << " fPurity ( purity )," << std::endl; + fout << " fResponse ( response ){" << std::endl; if (fUseFisherCuts){ for (UInt_t i=0;i<GetNVariables()+1;i++){ - fout << " fFisherCoeff.push_back(fisherCoeff"<<i<<");" << endl; + fout << " fFisherCoeff.push_back(fisherCoeff"<<i<<");" << std::endl; } } - fout << " }" << endl << endl; - fout << " virtual ~"<<nodeName<<"();" << endl << endl; - fout << " // test event if it decends the tree at this node to the right" << endl; - fout << " virtual bool GoesRight( const std::vector<double>& inputValues ) const;" << endl; - fout << " "<<nodeName<<"* GetRight( void ) {return fRight; };" << endl << endl; - fout << " // test event if it decends the tree at this node to the left " << endl; - fout << " virtual bool GoesLeft ( const std::vector<double>& inputValues ) const;" << endl; - fout << " "<<nodeName<<"* GetLeft( void ) { return fLeft; }; " << endl << endl; - fout << " // return S/(S+B) (purity) at this node (from training)" << endl << endl; - fout << " double GetPurity( void ) const { return fPurity; } " << endl; - fout << " // return the node type" << endl; - fout << " int GetNodeType( void ) const { return fNodeType; }" << endl; - fout << " double GetResponse(void) const {return fResponse;}" << endl << endl; - fout << "private:" << endl << endl; - fout << " "<<nodeName<<"* fLeft; // pointer to the left daughter node" << endl; - fout << " "<<nodeName<<"* fRight; // pointer to the right daughter node" << endl; + fout << " }" << std::endl << std::endl; + fout << " virtual ~"<<nodeName<<"();" << std::endl << std::endl; + fout << " // test event if it decends the tree at this node to the right" << std::endl; + fout << " virtual bool GoesRight( const std::vector<double>& inputValues ) const;" << std::endl; + fout << " "<<nodeName<<"* GetRight( void ) {return fRight; };" << std::endl << std::endl; + fout << " // test event if it decends the tree at this node to the left " << std::endl; + fout << " virtual bool GoesLeft ( const std::vector<double>& inputValues ) const;" << std::endl; + fout << " "<<nodeName<<"* GetLeft( void ) { return fLeft; }; " << std::endl << std::endl; + fout << " // return S/(S+B) (purity) at this node (from training)" << std::endl << std::endl; + fout << " double GetPurity( void ) const { return fPurity; } " << std::endl; + fout << " // return the node type" << std::endl; + fout << " int GetNodeType( void ) const { return fNodeType; }" << std::endl; + fout << " double GetResponse(void) const {return fResponse;}" << std::endl << std::endl; + fout << "private:" << std::endl << std::endl; + fout << " "<<nodeName<<"* fLeft; // pointer to the left daughter node" << std::endl; + fout << " "<<nodeName<<"* fRight; // pointer to the right daughter node" << std::endl; if (fUseFisherCuts){ - fout << " int fNFisherCoeff; // =0 if this node doesn use fisher, else =nvar+1 " << endl; - fout << " std::vector<double> fFisherCoeff; // the fisher coeff (offset at the last element)" << endl; - } - fout << " int fSelector; // index of variable used in node selection (decision tree) " << endl; - fout << " double fCutValue; // cut value appplied on this node to discriminate bkg against sig" << endl; - fout << " bool fCutType; // true: if event variable > cutValue ==> signal , false otherwise" << endl; - fout << " int fNodeType; // Type of node: -1 == Bkg-leaf, 1 == Signal-leaf, 0 = internal " << endl; - fout << " double fPurity; // Purity of node from training"<< endl; - fout << " double fResponse; // Regression response value of node" << endl; - fout << "}; " << endl; - fout << " " << endl; - fout << "//_______________________________________________________________________" << endl; - fout << " "<<nodeName<<"::~"<<nodeName<<"()" << endl; - fout << "{" << endl; - fout << " if (fLeft != NULL) delete fLeft;" << endl; - fout << " if (fRight != NULL) delete fRight;" << endl; - fout << "}; " << endl; - fout << " " << endl; - fout << "//_______________________________________________________________________" << endl; - fout << "bool "<<nodeName<<"::GoesRight( const std::vector<double>& inputValues ) const" << endl; - fout << "{" << endl; - fout << " // test event if it decends the tree at this node to the right" << endl; - fout << " bool result;" << endl; + fout << " int fNFisherCoeff; // =0 if this node doesn use fisher, else =nvar+1 " << std::endl; + fout << " std::vector<double> fFisherCoeff; // the fisher coeff (offset at the last element)" << std::endl; + } + fout << " int fSelector; // index of variable used in node selection (decision tree) " << std::endl; + fout << " double fCutValue; // cut value appplied on this node to discriminate bkg against sig" << std::endl; + fout << " bool fCutType; // true: if event variable > cutValue ==> signal , false otherwise" << std::endl; + fout << " int fNodeType; // Type of node: -1 == Bkg-leaf, 1 == Signal-leaf, 0 = internal " << std::endl; + fout << " double fPurity; // Purity of node from training"<< std::endl; + fout << " double fResponse; // Regression response value of node" << std::endl; + fout << "}; " << std::endl; + fout << " " << std::endl; + fout << "//_______________________________________________________________________" << std::endl; + fout << " "<<nodeName<<"::~"<<nodeName<<"()" << std::endl; + fout << "{" << std::endl; + fout << " if (fLeft != NULL) delete fLeft;" << std::endl; + fout << " if (fRight != NULL) delete fRight;" << std::endl; + fout << "}; " << std::endl; + fout << " " << std::endl; + fout << "//_______________________________________________________________________" << std::endl; + fout << "bool "<<nodeName<<"::GoesRight( const std::vector<double>& inputValues ) const" << std::endl; + fout << "{" << std::endl; + fout << " // test event if it decends the tree at this node to the right" << std::endl; + fout << " bool result;" << std::endl; if (fUseFisherCuts){ - fout << " if (fNFisherCoeff == 0){" << endl; - fout << " result = (inputValues[fSelector] > fCutValue );" << endl; - fout << " }else{" << endl; - fout << " double fisher = fFisherCoeff.at(fFisherCoeff.size()-1);" << endl; - fout << " for (unsigned int ivar=0; ivar<fFisherCoeff.size()-1; ivar++)" << endl; - fout << " fisher += fFisherCoeff.at(ivar)*inputValues.at(ivar);" << endl; - fout << " result = fisher > fCutValue;" << endl; - fout << " }" << endl; + fout << " if (fNFisherCoeff == 0){" << std::endl; + fout << " result = (inputValues[fSelector] > fCutValue );" << std::endl; + fout << " }else{" << std::endl; + fout << " double fisher = fFisherCoeff.at(fFisherCoeff.size()-1);" << std::endl; + fout << " for (unsigned int ivar=0; ivar<fFisherCoeff.size()-1; ivar++)" << std::endl; + fout << " fisher += fFisherCoeff.at(ivar)*inputValues.at(ivar);" << std::endl; + fout << " result = fisher > fCutValue;" << std::endl; + fout << " }" << std::endl; }else{ - fout << " result = (inputValues[fSelector] > fCutValue );" << endl; - } - fout << " if (fCutType == true) return result; //the cuts are selecting Signal ;" << endl; - fout << " else return !result;" << endl; - fout << "}" << endl; - fout << " " << endl; - fout << "//_______________________________________________________________________" << endl; - fout << "bool "<<nodeName<<"::GoesLeft( const std::vector<double>& inputValues ) const" << endl; - fout << "{" << endl; - fout << " // test event if it decends the tree at this node to the left" << endl; - fout << " if (!this->GoesRight(inputValues)) return true;" << endl; - fout << " else return false;" << endl; - fout << "}" << endl; - fout << " " << endl; - fout << "#endif" << endl; - fout << " " << endl; + fout << " result = (inputValues[fSelector] > fCutValue );" << std::endl; + } + fout << " if (fCutType == true) return result; //the cuts are selecting Signal ;" << std::endl; + fout << " else return !result;" << std::endl; + fout << "}" << std::endl; + fout << " " << std::endl; + fout << "//_______________________________________________________________________" << std::endl; + fout << "bool "<<nodeName<<"::GoesLeft( const std::vector<double>& inputValues ) const" << std::endl; + fout << "{" << std::endl; + fout << " // test event if it decends the tree at this node to the left" << std::endl; + fout << " if (!this->GoesRight(inputValues)) return true;" << std::endl; + fout << " else return false;" << std::endl; + fout << "}" << std::endl; + fout << " " << std::endl; + fout << "#endif" << std::endl; + fout << " " << std::endl; } //_______________________________________________________________________ @@ -2265,22 +2739,22 @@ void TMVA::MethodBDT::MakeClassInstantiateNode( DecisionTreeNode *n, std::ostrea Log() << kFATAL << "MakeClassInstantiateNode: started with undefined node" <<Endl; return ; } - fout << "NN("<<endl; + fout << "NN("<<std::endl; if (n->GetLeft() != NULL){ this->MakeClassInstantiateNode( (DecisionTreeNode*)n->GetLeft() , fout, className); } else { fout << "0"; } - fout << ", " <<endl; + fout << ", " <<std::endl; if (n->GetRight() != NULL){ this->MakeClassInstantiateNode( (DecisionTreeNode*)n->GetRight(), fout, className ); } else { fout << "0"; } - fout << ", " << endl - << setprecision(6); + fout << ", " << std::endl + << std::setprecision(6); if (fUseFisherCuts){ fout << n->GetNFisherCoeff() << ", "; for (UInt_t i=0; i< GetNVariables()+1; i++) { @@ -2298,3 +2772,131 @@ void TMVA::MethodBDT::MakeClassInstantiateNode( DecisionTreeNode *n, std::ostrea << n->GetPurity() << "," << n->GetResponse() << ") "; } + +//_______________________________________________________________________ +void TMVA::MethodBDT::DeterminePreselectionCuts(const std::vector<const TMVA::Event*>& eventSample) +{ + // find useful preselection cuts that will be applied before + // and Decision Tree training.. (and of course also applied + // in the GetMVA .. --> -1 for background +1 for Signal + // /* + Double_t nTotS = 0.0, nTotB = 0.0; + Int_t nTotS_unWeighted = 0, nTotB_unWeighted = 0; + + std::vector<TMVA::BDTEventWrapper> bdtEventSample; + + fIsLowSigCut.assign(GetNvar(),kFALSE); + fIsLowBkgCut.assign(GetNvar(),kFALSE); + fIsHighSigCut.assign(GetNvar(),kFALSE); + fIsHighBkgCut.assign(GetNvar(),kFALSE); + + fLowSigCut.assign(GetNvar(),0.); // ---------------| --> in var is signal (accept all above lower cut) + fLowBkgCut.assign(GetNvar(),0.); // ---------------| --> in var is bkg (accept all above lower cut) + fHighSigCut.assign(GetNvar(),0.); // <-- | -------------- in var is signal (accept all blow cut) + fHighBkgCut.assign(GetNvar(),0.); // <-- | -------------- in var is blg (accept all blow cut) + + + // Initialize (un)weighted counters for signal & background + // Construct a list of event wrappers that point to the original data + for( std::vector<const TMVA::Event*>::const_iterator it = eventSample.begin(); it != eventSample.end(); ++it ) { + if (DataInfo().IsSignal(*it)){ + nTotS += (*it)->GetWeight(); + ++nTotS_unWeighted; + } + else { + nTotB += (*it)->GetWeight(); + ++nTotB_unWeighted; + } + bdtEventSample.push_back(TMVA::BDTEventWrapper(*it)); + } + + for( UInt_t ivar = 0; ivar < GetNvar(); ivar++ ) { // loop over all discriminating variables + TMVA::BDTEventWrapper::SetVarIndex(ivar); // select the variable to sort by + std::sort( bdtEventSample.begin(),bdtEventSample.end() ); // sort the event data + + Double_t bkgWeightCtr = 0.0, sigWeightCtr = 0.0; + std::vector<TMVA::BDTEventWrapper>::iterator it = bdtEventSample.begin(), it_end = bdtEventSample.end(); + for( ; it != it_end; ++it ) { + if (DataInfo().IsSignal(**it)) + sigWeightCtr += (**it)->GetWeight(); + else + bkgWeightCtr += (**it)->GetWeight(); + // Store the accumulated signal (background) weights + it->SetCumulativeWeight(false,bkgWeightCtr); + it->SetCumulativeWeight(true,sigWeightCtr); + } + + //variable that determines how "exact" you cut on the preslection found in the training data. Here I chose + //1% of the variable range... + Double_t dVal = (DataInfo().GetVariableInfo(ivar).GetMax() - DataInfo().GetVariableInfo(ivar).GetMin())/100. ; + Double_t nSelS, nSelB, effS=0.05, effB=0.05, rejS=0.05, rejB=0.05; + Double_t tmpEffS, tmpEffB, tmpRejS, tmpRejB; + // Locate the optimal cut for this (ivar-th) variable + + + + for(UInt_t iev = 1; iev < bdtEventSample.size(); iev++) { + //dVal = bdtEventSample[iev].GetVal() - bdtEventSample[iev-1].GetVal(); + + nSelS = bdtEventSample[iev].GetCumulativeWeight(true); + nSelB = bdtEventSample[iev].GetCumulativeWeight(false); + // you look for some 100% efficient pre-selection cut to remove background.. i.e. nSelS=0 && nSelB>5%nTotB or ( nSelB=0 nSelS>5%nTotS) + tmpEffS=nSelS/nTotS; + tmpEffB=nSelB/nTotB; + tmpRejS=1-tmpEffS; + tmpRejB=1-tmpEffB; + if (nSelS==0 && tmpEffB>effB) {effB=tmpEffB; fLowBkgCut[ivar] = bdtEventSample[iev].GetVal() - dVal; fIsLowBkgCut[ivar]=kTRUE;} + else if (nSelB==0 && tmpEffS>effS) {effS=tmpEffS; fLowSigCut[ivar] = bdtEventSample[iev].GetVal() - dVal; fIsLowSigCut[ivar]=kTRUE;} + else if (nSelB==nTotB && tmpRejS>rejS) {rejS=tmpRejS; fHighSigCut[ivar] = bdtEventSample[iev].GetVal() + dVal; fIsHighSigCut[ivar]=kTRUE;} + else if (nSelS==nTotS && tmpRejB>rejB) {rejB=tmpRejB; fHighBkgCut[ivar] = bdtEventSample[iev].GetVal() + dVal; fIsHighBkgCut[ivar]=kTRUE;} + + } + } + + Log() << kINFO << " found and suggest the following possible pre-selection cuts " << Endl; + if (fDoPreselection) Log() << kINFO << "the training will be done after these cuts... and GetMVA value returns +1, (-1) for a signal (bkg) event that passes these cuts" << Endl; + else Log() << kINFO << "as option DoPreselection was not used, these cuts however will not be performed, but the training will see the full sample"<<Endl; + for (UInt_t ivar=0; ivar < GetNvar(); ivar++ ) { // loop over all discriminating variables + if (fIsLowBkgCut[ivar]){ + Log() << kINFO << " found cut: Bkg if var " << ivar << " < " << fLowBkgCut[ivar] << Endl; + } + if (fIsLowSigCut[ivar]){ + Log() << kINFO << " found cut: Sig if var " << ivar << " < " << fLowSigCut[ivar] << Endl; + } + if (fIsHighBkgCut[ivar]){ + Log() << kINFO << " found cut: Bkg if var " << ivar << " > " << fHighBkgCut[ivar] << Endl; + } + if (fIsHighSigCut[ivar]){ + Log() << kINFO << " found cut: Sig if var " << ivar << " > " << fHighSigCut[ivar] << Endl; + } + } + + return; +} + +//_______________________________________________________________________ +Double_t TMVA::MethodBDT::ApplyPreselectionCuts(const Event* ev) +{ + // aply the preselection cuts before even bothing about any + // Decision Trees in the GetMVA .. --> -1 for background +1 for Signal + + Double_t result=0; + + for (UInt_t ivar=0; ivar < GetNvar(); ivar++ ) { // loop over all discriminating variables + if (fIsLowBkgCut[ivar]){ + if (ev->GetValue(ivar) < fLowBkgCut[ivar]) result = -1; // is background + } + if (fIsLowSigCut[ivar]){ + if (ev->GetValue(ivar) < fLowSigCut[ivar]) result = 1; // is signal + } + if (fIsHighBkgCut[ivar]){ + if (ev->GetValue(ivar) > fHighBkgCut[ivar]) result = -1; // is background + } + if (fIsHighSigCut[ivar]){ + if (ev->GetValue(ivar) > fHighSigCut[ivar]) result = 1; // is signal + } + } + + return result; +} + diff --git a/tmva/src/MethodBase.cxx b/tmva/src/MethodBase.cxx index cef3388a65f25..a19e74d8094e8 100644 --- a/tmva/src/MethodBase.cxx +++ b/tmva/src/MethodBase.cxx @@ -112,6 +112,7 @@ ClassImp(TMVA::MethodBase) using std::endl; +using std::atof; const Int_t MethodBase_MaxIterations_ = 200; const Bool_t Use_Splines_for_Eff_ = kTRUE; @@ -458,6 +459,7 @@ void TMVA::MethodBase::ProcessBaseOptions() Log() << kFATAL << "<ProcessOptions> Verbosity level type '" << fVerbosityLevelString << "' unknown." << Endl; } + Event::SetIgnoreNegWeightsInTraining(fIgnoreNegWeightsInTraining); } //_______________________________________________________________________ @@ -579,6 +581,10 @@ void TMVA::MethodBase::CreateVariableTransforms( const TString& trafoDefinitionI //_______________________________________________________________________ void TMVA::MethodBase::DeclareCompatibilityOptions() { + // options that are used ONLY for the READER to ensure backward compatibility + // they are hence without any effect (the reader is only reading the training + // options that HAD been used at the training of the .xml weightfile at hand + DeclareOptionRef( fNormalise=kFALSE, "Normalise", "Normalise input variables" ); // don't change the default !!! DeclareOptionRef( fUseDecorr=kFALSE, "D", "Use-decorrelated-variables flag" ); DeclareOptionRef( fVariableTransformTypeString="Signal", "VarTransformType", @@ -586,14 +592,15 @@ void TMVA::MethodBase::DeclareCompatibilityOptions() AddPreDefVal( TString("Signal") ); AddPreDefVal( TString("Background") ); DeclareOptionRef( fTxtWeightsOnly=kTRUE, "TxtWeightFilesOnly", "If True: write all training results (weights) as text files (False: some are written in ROOT format)" ); - DeclareOptionRef( fVerbosityLevelString="Default", "VerboseLevel", "Verbosity level" ); - AddPreDefVal( TString("Default") ); // uses default defined in MsgLogger header - AddPreDefVal( TString("Debug") ); - AddPreDefVal( TString("Verbose") ); - AddPreDefVal( TString("Info") ); - AddPreDefVal( TString("Warning") ); - AddPreDefVal( TString("Error") ); - AddPreDefVal( TString("Fatal") ); + // Why on earth ?? was this here? Was the verbosity level option meant to 'disapear? Not a good idea i think.. + // DeclareOptionRef( fVerbosityLevelString="Default", "VerboseLevel", "Verbosity level" ); + // AddPreDefVal( TString("Default") ); // uses default defined in MsgLogger header + // AddPreDefVal( TString("Debug") ); + // AddPreDefVal( TString("Verbose") ); + // AddPreDefVal( TString("Info") ); + // AddPreDefVal( TString("Warning") ); + // AddPreDefVal( TString("Error") ); + // AddPreDefVal( TString("Fatal") ); DeclareOptionRef( fNbinsMVAPdf = 60, "NbinsMVAPdf", "Number of bins used for the PDFs of classifier outputs" ); DeclareOptionRef( fNsmoothMVAPdf = 2, "NsmoothMVAPdf", "Number of smoothing iterations for classifier PDFs" ); } @@ -631,6 +638,7 @@ void TMVA::MethodBase::SetTuneParameters(std::map<TString,Double_t> /* tuneParam void TMVA::MethodBase::TrainMethod() { Data()->SetCurrentType(Types::kTraining); + Event::SetIsTraining(kTRUE); // used to set negative event weights to zero if chosen to do so // train the MVA method if (Help()) PrintHelpMessage(); @@ -638,6 +646,8 @@ void TMVA::MethodBase::TrainMethod() // all histograms should be created in the method's subdirectory BaseDir()->cd(); + // once calculate all the transformation (e.g. the sequence of Decorr:Gauss:Decorr) + // needed for this classifier GetTransformationHandler().CalcTransformations(Data()->GetEventCollection()); // call training of derived MVA @@ -803,10 +813,16 @@ Double_t TMVA::MethodBase::GetMvaValue( const Event* const ev, Double_t* err, Do return val; } +//_______________________________________________________________________ Bool_t TMVA::MethodBase::IsSignalLike() { + // uses a pre-set cut on the MVA output (SetSignalReferenceCut and SetSignalReferenceCutOrientation) + // for a quick determination if an event would be selected as signal or background return GetMvaValue()*GetSignalReferenceCutOrientation() > GetSignalReferenceCut()*GetSignalReferenceCutOrientation() ? kTRUE : kFALSE; } +//_______________________________________________________________________ Bool_t TMVA::MethodBase::IsSignalLike(Double_t mvaVal) { + // uses a pre-set cut on the MVA output (SetSignalReferenceCut and SetSignalReferenceCutOrientation) + // for a quick determination if an event with this mva output value would tbe selected as signal or background return mvaVal*GetSignalReferenceCutOrientation() > GetSignalReferenceCut()*GetSignalReferenceCutOrientation() ? kTRUE : kFALSE; } @@ -830,10 +846,9 @@ void TMVA::MethodBase::AddClassifierOutput( Types::ETreeType type ) clRes->Resize( nEvents ); for (Int_t ievt=0; ievt<nEvents; ievt++) { - - SetCurrentEvent(ievt); + Data()->SetCurrentEvent(ievt); clRes->SetValue( GetMvaValue(), ievt ); - + // print progress Int_t modulo = Int_t(nEvents/100); if (modulo <= 0 ) modulo = 1; @@ -1033,7 +1048,7 @@ void TMVA::MethodBase::TestClassification() // determine cut orientation fCutOrientation = (fMeanS > fMeanB) ? kPositive : kNegative; - + // fill 2 types of histograms for the various analyses // this one is for actual plotting @@ -1109,6 +1124,7 @@ void TMVA::MethodBase::TestClassification() } } + // uncomment those (and several others if you want unnormalized output gTools().NormHist( mva_s ); gTools().NormHist( mva_b ); gTools().NormHist( proba_s ); @@ -1134,35 +1150,35 @@ void TMVA::MethodBase::WriteStateToStream( std::ostream& tf ) const TString prefix = ""; UserGroup_t * userInfo = gSystem->GetUserInfo(); - tf << prefix << "#GEN -*-*-*-*-*-*-*-*-*-*-*- general info -*-*-*-*-*-*-*-*-*-*-*-" << endl << prefix << endl; - tf << prefix << "Method : " << GetMethodTypeName() << "::" << GetMethodName() << endl; + tf << prefix << "#GEN -*-*-*-*-*-*-*-*-*-*-*- general info -*-*-*-*-*-*-*-*-*-*-*-" << std::endl << prefix << std::endl; + tf << prefix << "Method : " << GetMethodTypeName() << "::" << GetMethodName() << std::endl; tf.setf(std::ios::left); tf << prefix << "TMVA Release : " << std::setw(10) << GetTrainingTMVAVersionString() << " [" - << GetTrainingTMVAVersionCode() << "]" << endl; + << GetTrainingTMVAVersionCode() << "]" << std::endl; tf << prefix << "ROOT Release : " << std::setw(10) << GetTrainingROOTVersionString() << " [" - << GetTrainingROOTVersionCode() << "]" << endl; - tf << prefix << "Creator : " << userInfo->fUser << endl; - tf << prefix << "Date : "; TDatime *d = new TDatime; tf << d->AsString() << endl; delete d; - tf << prefix << "Host : " << gSystem->GetBuildNode() << endl; - tf << prefix << "Dir : " << gSystem->WorkingDirectory() << endl; - tf << prefix << "Training events: " << Data()->GetNTrainingEvents() << endl; + << GetTrainingROOTVersionCode() << "]" << std::endl; + tf << prefix << "Creator : " << userInfo->fUser << std::endl; + tf << prefix << "Date : "; TDatime *d = new TDatime; tf << d->AsString() << std::endl; delete d; + tf << prefix << "Host : " << gSystem->GetBuildNode() << std::endl; + tf << prefix << "Dir : " << gSystem->WorkingDirectory() << std::endl; + tf << prefix << "Training events: " << Data()->GetNTrainingEvents() << std::endl; TString analysisType(((const_cast<TMVA::MethodBase*>(this)->GetAnalysisType()==Types::kRegression) ? "Regression" : "Classification")); - tf << prefix << "Analysis type : " << "[" << ((GetAnalysisType()==Types::kRegression) ? "Regression" : "Classification") << "]" << endl; - tf << prefix << endl; + tf << prefix << "Analysis type : " << "[" << ((GetAnalysisType()==Types::kRegression) ? "Regression" : "Classification") << "]" << std::endl; + tf << prefix << std::endl; delete userInfo; // First write all options - tf << prefix << endl << prefix << "#OPT -*-*-*-*-*-*-*-*-*-*-*-*- options -*-*-*-*-*-*-*-*-*-*-*-*-" << endl << prefix << endl; + tf << prefix << std::endl << prefix << "#OPT -*-*-*-*-*-*-*-*-*-*-*-*- options -*-*-*-*-*-*-*-*-*-*-*-*-" << std::endl << prefix << std::endl; WriteOptionsToStream( tf, prefix ); - tf << prefix << endl; + tf << prefix << std::endl; // Second write variable info - tf << prefix << endl << prefix << "#VAR -*-*-*-*-*-*-*-*-*-*-*-* variables *-*-*-*-*-*-*-*-*-*-*-*-" << endl << prefix << endl; + tf << prefix << std::endl << prefix << "#VAR -*-*-*-*-*-*-*-*-*-*-*-* variables *-*-*-*-*-*-*-*-*-*-*-*-" << std::endl << prefix << std::endl; WriteVarsToStream( tf, prefix ); - tf << prefix << endl; + tf << prefix << std::endl; } //_______________________________________________________________________ @@ -1295,19 +1311,23 @@ void TMVA::MethodBase::ReadStateFromFile() << gTools().Color("lightblue") << tfname << gTools().Color("reset") << Endl; if (tfname.EndsWith(".xml") ) { - void* doc = gTools().xmlengine().ParseFile(tfname); // the default buffer size in TXMLEngine::ParseFile is 100k. Starting with ROOT 5.29 one can set the buffer size, see: http://savannah.cern.ch/bugs/?78864. This might be necessary for large XML files +#if ROOT_VERSION_CODE >= ROOT_VERSION(5,29,0) + void* doc = gTools().xmlengine().ParseFile(tfname,gTools().xmlenginebuffersize()); // the default buffer size in TXMLEngine::ParseFile is 100k. Starting with ROOT 5.29 one can set the buffer size, see: http://savannah.cern.ch/bugs/?78864. This might be necessary for large XML files +#else + void* doc = gTools().xmlengine().ParseFile(tfname); +#endif void* rootnode = gTools().xmlengine().DocGetRootElement(doc); // node "MethodSetup" ReadStateFromXML(rootnode); gTools().xmlengine().FreeDoc(doc); } else { - filebuf fb; - fb.open(tfname.Data(),ios::in); + std::filebuf fb; + fb.open(tfname.Data(),std::ios::in); if (!fb.is_open()) { // file not found --> Error Log() << kFATAL << "<ReadStateFromFile> " << "Unable to open input weight file: " << tfname << Endl; } - istream fin(&fb); + std::istream fin(&fb); ReadStateFromStream(fin); fb.close(); } @@ -1565,10 +1585,10 @@ void TMVA::MethodBase::WriteVarsToStream( std::ostream& o, const TString& prefix { // write the list of variables (name, min, max) for a given data // transformation method to the stream - o << prefix << "NVar " << DataInfo().GetNVariables() << endl; + o << prefix << "NVar " << DataInfo().GetNVariables() << std::endl; std::vector<VariableInfo>::const_iterator varIt = DataInfo().GetVariableInfos().begin(); for (; varIt!=DataInfo().GetVariableInfos().end(); varIt++) { o << prefix; varIt->WriteToStream(o); } - o << prefix << "NSpec " << DataInfo().GetNSpectators() << endl; + o << prefix << "NSpec " << DataInfo().GetNSpectators() << std::endl; varIt = DataInfo().GetSpectatorInfos().begin(); for (; varIt!=DataInfo().GetSpectatorInfos().end(); varIt++) { o << prefix; varIt->WriteToStream(o); } } @@ -1940,7 +1960,7 @@ void TMVA::MethodBase::WriteEvaluationHistosToFile(Types::ETreeType treetype) << "/kMaxAnalysisType" << Endl; results->GetStorage()->Write(); if (treetype==Types::kTesting) { - GetTransformationHandler().PlotVariables( GetEventCollection( Types::kTesting ), BaseDir() ); + GetTransformationHandler().PlotVariables (GetEventCollection( Types::kTesting ), BaseDir() ); } } @@ -2002,11 +2022,13 @@ void TMVA::MethodBase::CreateMVAPdfs() Data()->SetCurrentType(Types::kTraining); + // the PDF's are stored as results ONLY if the corresponding "results" are booked, + // otherwise they will be only used 'online' ResultsClassification * mvaRes = dynamic_cast<ResultsClassification*> ( Data()->GetResults(GetMethodName(), Types::kTraining, Types::kClassification) ); if (mvaRes==0 || mvaRes->GetSize()==0) { - Log() << kFATAL << "<CreateMVAPdfs> No result of classifier testing available" << Endl; + Log() << kERROR<< "<CreateMVAPdfs> No result of classifier testing available" << Endl; } Double_t minVal = *std::min_element(mvaRes->GetValueVector()->begin(),mvaRes->GetValueVector()->end()); @@ -2056,6 +2078,20 @@ void TMVA::MethodBase::CreateMVAPdfs() delete histMVAPdfB; } +Double_t TMVA::MethodBase::GetProba(const Event *ev){ + // the simple one, automatically calcualtes the mvaVal and uses the + // SAME sig/bkg ratio as given in the training sample (typically 50/50 + // .. (NormMode=EqualNumEvents) but can be different) + if (!fMVAPdfS || !fMVAPdfB) { + Log() << kINFO << "<GetProba> MVA PDFs for Signal and Background don't exist yet, we'll create them on demand" << Endl; + CreateMVAPdfs(); + } + Double_t sigFraction = DataInfo().GetTrainingSumSignalWeights() / (DataInfo().GetTrainingSumSignalWeights() + DataInfo().GetTrainingSumBackgrWeights() ); + Double_t mvaVal = GetMvaValue(ev); + + return GetProba(mvaVal,sigFraction); + +} //_______________________________________________________________________ Double_t TMVA::MethodBase::GetProba( Double_t mvaVal, Double_t ap_sig ) { @@ -2132,7 +2168,7 @@ Double_t TMVA::MethodBase::GetEfficiency( const TString& theString, Types::ETree static Double_t nevtS; // first round ? --> create histograms - if (results->GetHist("MVA_EFF_S")==0) { + if (results->DoesExist("MVA_EFF_S")==0) { // for efficiency plot TH1* eff_s = new TH1D( GetTestvarName() + "_effS", GetTestvarName() + " (signal)", fNbinsH, xmin, xmax ); @@ -2363,7 +2399,7 @@ Double_t TMVA::MethodBase::GetTrainingEfficiency(const TString& theString) Double_t xmax = effhist->GetXaxis()->GetXmax(); // first round ? --> create and fill histograms - if (results->GetHist("MVA_TRAIN_S")==0) { + if (results->DoesExist("MVA_TRAIN_S")==0) { // classifier response distributions for test sample Double_t sxmax = fXmax+0.00001; @@ -2413,6 +2449,7 @@ Double_t TMVA::MethodBase::GetTrainingEfficiency(const TString& theString) } // normalise output distributions + // uncomment those (and several others if you want unnormalized output gTools().NormHist( mva_s_tr ); gTools().NormHist( mva_b_tr ); @@ -2545,7 +2582,7 @@ Double_t TMVA::MethodBase::GetSeparation( TH1* histoS, TH1* histoB ) const Double_t TMVA::MethodBase::GetSeparation( PDF* pdfS, PDF* pdfB ) const { // compute "separation" defined as - // <s2> = (1/2) Int_-oo..+oo { (S(x)2 - B(x)2)/(S(x) + B(x)) dx } + // <s2> = (1/2) Int_-oo..+oo { (S(x) - B(x))^2/(S(x) + B(x)) dx } // note, if zero pointers given, use internal pdf // sanity check first @@ -2765,217 +2802,218 @@ void TMVA::MethodBase::MakeClass( const TString& theClassFileName ) const Log() << kINFO << "Creating standalone response class: " << gTools().Color("lightblue") << classFileName << gTools().Color("reset") << Endl; - ofstream fout( classFileName ); + std::ofstream fout( classFileName ); if (!fout.good()) { // file could not be opened --> Error Log() << kFATAL << "<MakeClass> Unable to open file: " << classFileName << Endl; } // now create the class // preamble - fout << "// Class: " << className << endl; - fout << "// Automatically generated by MethodBase::MakeClass" << endl << "//" << endl; + fout << "// Class: " << className << std::endl; + fout << "// Automatically generated by MethodBase::MakeClass" << std::endl << "//" << std::endl; // print general information and configuration state - fout << endl; - fout << "/* configuration options =====================================================" << endl << endl; + fout << std::endl; + fout << "/* configuration options =====================================================" << std::endl << std::endl; WriteStateToStream( fout ); - fout << endl; - fout << "============================================================================ */" << endl; + fout << std::endl; + fout << "============================================================================ */" << std::endl; // generate the class - fout << "" << endl; - fout << "#include <vector>" << endl; - fout << "#include <cmath>" << endl; - fout << "#include <string>" << endl; - fout << "#include <iostream>" << endl; - fout << "" << endl; + fout << "" << std::endl; + fout << "#include <vector>" << std::endl; + fout << "#include <cmath>" << std::endl; + fout << "#include <string>" << std::endl; + fout << "#include <iostream>" << std::endl; + fout << "" << std::endl; // now if the classifier needs to write some addicional classes for its response implementation // this code goes here: (at least the header declarations need to come before the main class this->MakeClassSpecificHeader( fout, className ); - fout << "#ifndef IClassifierReader__def" << endl; - fout << "#define IClassifierReader__def" << endl; - fout << endl; - fout << "class IClassifierReader {" << endl; - fout << endl; - fout << " public:" << endl; - fout << endl; - fout << " // constructor" << endl; - fout << " IClassifierReader() : fStatusIsClean( true ) {}" << endl; - fout << " virtual ~IClassifierReader() {}" << endl; - fout << endl; - fout << " // return classifier response" << endl; - fout << " virtual double GetMvaValue( const std::vector<double>& inputValues ) const = 0;" << endl; - fout << endl; - fout << " // returns classifier status" << endl; - fout << " bool IsStatusClean() const { return fStatusIsClean; }" << endl; - fout << endl; - fout << " protected:" << endl; - fout << endl; - fout << " bool fStatusIsClean;" << endl; - fout << "};" << endl; - fout << endl; - fout << "#endif" << endl; - fout << endl; - fout << "class " << className << " : public IClassifierReader {" << endl; - fout << endl; - fout << " public:" << endl; - fout << endl; - fout << " // constructor" << endl; - fout << " " << className << "( std::vector<std::string>& theInputVars ) " << endl; - fout << " : IClassifierReader()," << endl; - fout << " fClassName( \"" << className << "\" )," << endl; - fout << " fNvars( " << GetNvar() << " )," << endl; - fout << " fIsNormalised( " << (IsNormalised() ? "true" : "false") << " )" << endl; - fout << " { " << endl; - fout << " // the training input variables" << endl; + fout << "#ifndef IClassifierReader__def" << std::endl; + fout << "#define IClassifierReader__def" << std::endl; + fout << std::endl; + fout << "class IClassifierReader {" << std::endl; + fout << std::endl; + fout << " public:" << std::endl; + fout << std::endl; + fout << " // constructor" << std::endl; + fout << " IClassifierReader() : fStatusIsClean( true ) {}" << std::endl; + fout << " virtual ~IClassifierReader() {}" << std::endl; + fout << std::endl; + fout << " // return classifier response" << std::endl; + fout << " virtual double GetMvaValue( const std::vector<double>& inputValues ) const = 0;" << std::endl; + fout << std::endl; + fout << " // returns classifier status" << std::endl; + fout << " bool IsStatusClean() const { return fStatusIsClean; }" << std::endl; + fout << std::endl; + fout << " protected:" << std::endl; + fout << std::endl; + fout << " bool fStatusIsClean;" << std::endl; + fout << "};" << std::endl; + fout << std::endl; + fout << "#endif" << std::endl; + fout << std::endl; + fout << "class " << className << " : public IClassifierReader {" << std::endl; + fout << std::endl; + fout << " public:" << std::endl; + fout << std::endl; + fout << " // constructor" << std::endl; + fout << " " << className << "( std::vector<std::string>& theInputVars ) " << std::endl; + fout << " : IClassifierReader()," << std::endl; + fout << " fClassName( \"" << className << "\" )," << std::endl; + fout << " fNvars( " << GetNvar() << " )," << std::endl; + fout << " fIsNormalised( " << (IsNormalised() ? "true" : "false") << " )" << std::endl; + fout << " { " << std::endl; + fout << " // the training input variables" << std::endl; fout << " const char* inputVars[] = { "; for (UInt_t ivar=0; ivar<GetNvar(); ivar++) { fout << "\"" << GetOriginalVarName(ivar) << "\""; if (ivar<GetNvar()-1) fout << ", "; } - fout << " };" << endl; - fout << endl; - fout << " // sanity checks" << endl; - fout << " if (theInputVars.size() <= 0) {" << endl; - fout << " std::cout << \"Problem in class \\\"\" << fClassName << \"\\\": empty input vector\" << std::endl;" << endl; - fout << " fStatusIsClean = false;" << endl; - fout << " }" << endl; - fout << endl; - fout << " if (theInputVars.size() != fNvars) {" << endl; - fout << " std::cout << \"Problem in class \\\"\" << fClassName << \"\\\": mismatch in number of input values: \"" << endl; - fout << " << theInputVars.size() << \" != \" << fNvars << std::endl;" << endl; - fout << " fStatusIsClean = false;" << endl; - fout << " }" << endl; - fout << endl; - fout << " // validate input variables" << endl; - fout << " for (size_t ivar = 0; ivar < theInputVars.size(); ivar++) {" << endl; - fout << " if (theInputVars[ivar] != inputVars[ivar]) {" << endl; - fout << " std::cout << \"Problem in class \\\"\" << fClassName << \"\\\": mismatch in input variable names\" << std::endl" << endl; - fout << " << \" for variable [\" << ivar << \"]: \" << theInputVars[ivar].c_str() << \" != \" << inputVars[ivar] << std::endl;" << endl; - fout << " fStatusIsClean = false;" << endl; - fout << " }" << endl; - fout << " }" << endl; - fout << endl; - fout << " // initialize min and max vectors (for normalisation)" << endl; + fout << " };" << std::endl; + fout << std::endl; + fout << " // sanity checks" << std::endl; + fout << " if (theInputVars.size() <= 0) {" << std::endl; + fout << " std::cout << \"Problem in class \\\"\" << fClassName << \"\\\": empty input vector\" << std::endl;" << std::endl; + fout << " fStatusIsClean = false;" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " if (theInputVars.size() != fNvars) {" << std::endl; + fout << " std::cout << \"Problem in class \\\"\" << fClassName << \"\\\": mismatch in number of input values: \"" << std::endl; + fout << " << theInputVars.size() << \" != \" << fNvars << std::endl;" << std::endl; + fout << " fStatusIsClean = false;" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " // validate input variables" << std::endl; + fout << " for (size_t ivar = 0; ivar < theInputVars.size(); ivar++) {" << std::endl; + fout << " if (theInputVars[ivar] != inputVars[ivar]) {" << std::endl; + fout << " std::cout << \"Problem in class \\\"\" << fClassName << \"\\\": mismatch in input variable names\" << std::endl" << std::endl; + fout << " << \" for variable [\" << ivar << \"]: \" << theInputVars[ivar].c_str() << \" != \" << inputVars[ivar] << std::endl;" << std::endl; + fout << " fStatusIsClean = false;" << std::endl; + fout << " }" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " // initialize min and max vectors (for normalisation)" << std::endl; for (UInt_t ivar = 0; ivar < GetNvar(); ivar++) { - fout << " fVmin[" << ivar << "] = " << std::setprecision(15) << GetXmin( ivar ) << ";" << endl; - fout << " fVmax[" << ivar << "] = " << std::setprecision(15) << GetXmax( ivar ) << ";" << endl; + fout << " fVmin[" << ivar << "] = " << std::setprecision(15) << GetXmin( ivar ) << ";" << std::endl; + fout << " fVmax[" << ivar << "] = " << std::setprecision(15) << GetXmax( ivar ) << ";" << std::endl; } - fout << endl; - fout << " // initialize input variable types" << endl; + fout << std::endl; + fout << " // initialize input variable types" << std::endl; for (UInt_t ivar=0; ivar<GetNvar(); ivar++) { - fout << " fType[" << ivar << "] = \'" << DataInfo().GetVariableInfo(ivar).GetVarType() << "\';" << endl; + fout << " fType[" << ivar << "] = \'" << DataInfo().GetVariableInfo(ivar).GetVarType() << "\';" << std::endl; } - fout << endl; - fout << " // initialize constants" << endl; - fout << " Initialize();" << endl; - fout << endl; + fout << std::endl; + fout << " // initialize constants" << std::endl; + fout << " Initialize();" << std::endl; + fout << std::endl; if (GetTransformationHandler().GetTransformationList().GetSize() != 0) { - fout << " // initialize transformation" << endl; - fout << " InitTransform();" << endl; - } - fout << " }" << endl; - fout << endl; - fout << " // destructor" << endl; - fout << " virtual ~" << className << "() {" << endl; - fout << " Clear(); // method-specific" << endl; - fout << " }" << endl; - fout << endl; - fout << " // the classifier response" << endl; - fout << " // \"inputValues\" is a vector of input values in the same order as the " << endl; - fout << " // variables given to the constructor" << endl; - fout << " double GetMvaValue( const std::vector<double>& inputValues ) const;" << endl; - fout << endl; - fout << " private:" << endl; - fout << endl; - fout << " // method-specific destructor" << endl; - fout << " void Clear();" << endl; - fout << endl; + fout << " // initialize transformation" << std::endl; + fout << " InitTransform();" << std::endl; + } + fout << " }" << std::endl; + fout << std::endl; + fout << " // destructor" << std::endl; + fout << " virtual ~" << className << "() {" << std::endl; + fout << " Clear(); // method-specific" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " // the classifier response" << std::endl; + fout << " // \"inputValues\" is a vector of input values in the same order as the " << std::endl; + fout << " // variables given to the constructor" << std::endl; + fout << " double GetMvaValue( const std::vector<double>& inputValues ) const;" << std::endl; + fout << std::endl; + fout << " private:" << std::endl; + fout << std::endl; + fout << " // method-specific destructor" << std::endl; + fout << " void Clear();" << std::endl; + fout << std::endl; if (GetTransformationHandler().GetTransformationList().GetSize()!=0) { - fout << " // input variable transformation" << endl; + fout << " // input variable transformation" << std::endl; GetTransformationHandler().MakeFunction(fout, className,1); - fout << " void InitTransform();" << endl; - fout << " void Transform( std::vector<double> & iv, int sigOrBgd ) const;" << endl; - fout << endl; - } - fout << " // common member variables" << endl; - fout << " const char* fClassName;" << endl; - fout << endl; - fout << " const size_t fNvars;" << endl; - fout << " size_t GetNvar() const { return fNvars; }" << endl; - fout << " char GetType( int ivar ) const { return fType[ivar]; }" << endl; - fout << endl; - fout << " // normalisation of input variables" << endl; - fout << " const bool fIsNormalised;" << endl; - fout << " bool IsNormalised() const { return fIsNormalised; }" << endl; - fout << " double fVmin[" << GetNvar() << "];" << endl; - fout << " double fVmax[" << GetNvar() << "];" << endl; - fout << " double NormVariable( double x, double xmin, double xmax ) const {" << endl; - fout << " // normalise to output range: [-1, 1]" << endl; - fout << " return 2*(x - xmin)/(xmax - xmin) - 1.0;" << endl; - fout << " }" << endl; - fout << endl; - fout << " // type of input variable: 'F' or 'I'" << endl; - fout << " char fType[" << GetNvar() << "];" << endl; - fout << endl; - fout << " // initialize internal variables" << endl; - fout << " void Initialize();" << endl; - fout << " double GetMvaValue__( const std::vector<double>& inputValues ) const;" << endl; - fout << "" << endl; - fout << " // private members (method specific)" << endl; + fout << " void InitTransform();" << std::endl; + fout << " void Transform( std::vector<double> & iv, int sigOrBgd ) const;" << std::endl; + fout << std::endl; + } + fout << " // common member variables" << std::endl; + fout << " const char* fClassName;" << std::endl; + fout << std::endl; + fout << " const size_t fNvars;" << std::endl; + fout << " size_t GetNvar() const { return fNvars; }" << std::endl; + fout << " char GetType( int ivar ) const { return fType[ivar]; }" << std::endl; + fout << std::endl; + fout << " // normalisation of input variables" << std::endl; + fout << " const bool fIsNormalised;" << std::endl; + fout << " bool IsNormalised() const { return fIsNormalised; }" << std::endl; + fout << " double fVmin[" << GetNvar() << "];" << std::endl; + fout << " double fVmax[" << GetNvar() << "];" << std::endl; + fout << " double NormVariable( double x, double xmin, double xmax ) const {" << std::endl; + fout << " // normalise to output range: [-1, 1]" << std::endl; + fout << " return 2*(x - xmin)/(xmax - xmin) - 1.0;" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " // type of input variable: 'F' or 'I'" << std::endl; + fout << " char fType[" << GetNvar() << "];" << std::endl; + fout << std::endl; + fout << " // initialize internal variables" << std::endl; + fout << " void Initialize();" << std::endl; + fout << " double GetMvaValue__( const std::vector<double>& inputValues ) const;" << std::endl; + fout << "" << std::endl; + fout << " // private members (method specific)" << std::endl; // call the classifier specific output (the classifier must close the class !) MakeClassSpecific( fout, className ); - fout << " inline double " << className << "::GetMvaValue( const std::vector<double>& inputValues ) const" << endl; - fout << " {" << endl; - fout << " // classifier response value" << endl; - fout << " double retval = 0;" << endl; - fout << endl; - fout << " // classifier response, sanity check first" << endl; - fout << " if (!IsStatusClean()) {" << endl; - fout << " std::cout << \"Problem in class \\\"\" << fClassName << \"\\\": cannot return classifier response\"" << endl; - fout << " << \" because status is dirty\" << std::endl;" << endl; - fout << " retval = 0;" << endl; - fout << " }" << endl; - fout << " else {" << endl; - fout << " if (IsNormalised()) {" << endl; - fout << " // normalise variables" << endl; - fout << " std::vector<double> iV;" << endl; - fout << " int ivar = 0;" << endl; - fout << " for (std::vector<double>::const_iterator varIt = inputValues.begin();" << endl; - fout << " varIt != inputValues.end(); varIt++, ivar++) {" << endl; - fout << " iV.push_back(NormVariable( *varIt, fVmin[ivar], fVmax[ivar] ));" << endl; - fout << " }" << endl; + fout << " inline double " << className << "::GetMvaValue( const std::vector<double>& inputValues ) const" << std::endl; + fout << " {" << std::endl; + fout << " // classifier response value" << std::endl; + fout << " double retval = 0;" << std::endl; + fout << std::endl; + fout << " // classifier response, sanity check first" << std::endl; + fout << " if (!IsStatusClean()) {" << std::endl; + fout << " std::cout << \"Problem in class \\\"\" << fClassName << \"\\\": cannot return classifier response\"" << std::endl; + fout << " << \" because status is dirty\" << std::endl;" << std::endl; + fout << " retval = 0;" << std::endl; + fout << " }" << std::endl; + fout << " else {" << std::endl; + fout << " if (IsNormalised()) {" << std::endl; + fout << " // normalise variables" << std::endl; + fout << " std::vector<double> iV;" << std::endl; + fout << " iV.reserve(inputValues.size());" << std::endl; + fout << " int ivar = 0;" << std::endl; + fout << " for (std::vector<double>::const_iterator varIt = inputValues.begin();" << std::endl; + fout << " varIt != inputValues.end(); varIt++, ivar++) {" << std::endl; + fout << " iV.push_back(NormVariable( *varIt, fVmin[ivar], fVmax[ivar] ));" << std::endl; + fout << " }" << std::endl; if (GetTransformationHandler().GetTransformationList().GetSize()!=0 && GetMethodType() != Types::kLikelihood && GetMethodType() != Types::kHMatrix) { - fout << " Transform( iV, -1 );" << endl; + fout << " Transform( iV, -1 );" << std::endl; } - fout << " retval = GetMvaValue__( iV );" << endl; - fout << " }" << endl; - fout << " else {" << endl; + fout << " retval = GetMvaValue__( iV );" << std::endl; + fout << " }" << std::endl; + fout << " else {" << std::endl; if (GetTransformationHandler().GetTransformationList().GetSize()!=0 && GetMethodType() != Types::kLikelihood && GetMethodType() != Types::kHMatrix) { - fout << " std::vector<double> iV;" << endl; - fout << " int ivar = 0;" << endl; - fout << " for (std::vector<double>::const_iterator varIt = inputValues.begin();" << endl; - fout << " varIt != inputValues.end(); varIt++, ivar++) {" << endl; - fout << " iV.push_back(*varIt);" << endl; - fout << " }" << endl; - fout << " Transform( iV, -1 );" << endl; - fout << " retval = GetMvaValue__( iV );" << endl; + fout << " std::vector<double> iV;" << std::endl; + fout << " int ivar = 0;" << std::endl; + fout << " for (std::vector<double>::const_iterator varIt = inputValues.begin();" << std::endl; + fout << " varIt != inputValues.end(); varIt++, ivar++) {" << std::endl; + fout << " iV.push_back(*varIt);" << std::endl; + fout << " }" << std::endl; + fout << " Transform( iV, -1 );" << std::endl; + fout << " retval = GetMvaValue__( iV );" << std::endl; } else { - fout << " retval = GetMvaValue__( inputValues );" << endl; + fout << " retval = GetMvaValue__( inputValues );" << std::endl; } - fout << " }" << endl; - fout << " }" << endl; - fout << endl; - fout << " return retval;" << endl; - fout << " }" << endl; + fout << " }" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " return retval;" << std::endl; + fout << " }" << std::endl; // create output for transformation - if any if (GetTransformationHandler().GetTransformationList().GetSize()!=0) @@ -2999,7 +3037,7 @@ void TMVA::MethodBase::PrintHelpMessage() const if (!o->good()) { // file could not be opened --> Error Log() << kFATAL << "<PrintHelpMessage> Unable to append to output file: " << GetReferenceFile() << Endl; } - std::cout.rdbuf( o->rdbuf() ); // redirect 'cout' to file + std::cout.rdbuf( o->rdbuf() ); // redirect 'std::cout' to file } // "|--------------------------------------------------------------|" @@ -3078,10 +3116,19 @@ Double_t TMVA::MethodBase::GetEffForRoot( Double_t theCut ) //_______________________________________________________________________ const std::vector<TMVA::Event*>& TMVA::MethodBase::GetEventCollection( Types::ETreeType type) { + // returns the event collection (i.e. the dataset) TRANSFORMED using the + // classifiers specific Variable Transformation (e.g. Decorr or Decorr:Gauss:Decorr) + + // if there's no variable transformation for this classifier, just hand back the + // event collection of the data set if (GetTransformationHandler().GetTransformationList().GetEntries() <= 0) { return (Data()->GetEventCollection(type)); - } - Int_t idx = Data()->TreeIndex(type); + } + + // otherwise, transform ALL the events and hand back the vector of the pointers to the + // transformed events. If the pointer is already != 0, i.e. the whole thing has been + // done before, I don't need to do it again, but just "hand over" the pointer to those events. + Int_t idx = Data()->TreeIndex(type); //index indicating Training,Testing,... events/datasets if (fEventCollections.at(idx) == 0) { fEventCollections.at(idx) = &(Data()->GetEventCollection(type)); fEventCollections.at(idx) = GetTransformationHandler().CalcTransformations(*(fEventCollections.at(idx)),kTRUE); diff --git a/tmva/src/MethodBayesClassifier.cxx b/tmva/src/MethodBayesClassifier.cxx index d3a9ddc1f8155..b488f22854511 100644 --- a/tmva/src/MethodBayesClassifier.cxx +++ b/tmva/src/MethodBayesClassifier.cxx @@ -104,7 +104,7 @@ void TMVA::MethodBayesClassifier::AddWeightsXMLTo( void* /*parent*/ ) const { } //_______________________________________________________________________ -void TMVA::MethodBayesClassifier::ReadWeightsFromStream( istream & ) +void TMVA::MethodBayesClassifier::ReadWeightsFromStream( std::istream & ) { // read back the training results from a file (stream) } @@ -125,8 +125,8 @@ Double_t TMVA::MethodBayesClassifier::GetMvaValue( Double_t* err, Double_t* errU void TMVA::MethodBayesClassifier::MakeClassSpecific( std::ostream& fout, const TString& className ) const { // write specific classifier response - fout << " // not implemented for class: \"" << className << "\"" << endl; - fout << "};" << endl; + fout << " // not implemented for class: \"" << className << "\"" << std::endl; + fout << "};" << std::endl; } //_______________________________________________________________________ diff --git a/tmva/src/MethodBoost.cxx b/tmva/src/MethodBoost.cxx index 018d8690442c8..5041d7d2c917c 100644 --- a/tmva/src/MethodBoost.cxx +++ b/tmva/src/MethodBoost.cxx @@ -54,6 +54,8 @@ #include "TMVA/MethodBase.h" #include "TMVA/MethodBoost.h" #include "TMVA/MethodCategory.h" +#include "TMVA/MethodDT.h" +#include "TMVA/MethodFisher.h" #include "TMVA/Tools.h" #include "TMVA/ClassifierFactory.h" #include "TMVA/Timer.h" @@ -67,6 +69,7 @@ #include "TMVA/GiniIndex.h" #include "TMVA/CrossEntropy.h" #include "TMVA/RegressionVariance.h" +#include "TMVA/QuickMVAProbEstimator.h" REGISTER_METHOD(Boost) @@ -80,20 +83,16 @@ TMVA::MethodBoost::MethodBoost( const TString& jobName, TDirectory* theTargetDir ) : TMVA::MethodCompositeBase( jobName, Types::kBoost, methodTitle, theData, theOption, theTargetDir ) , fBoostNum(0) - , fMethodError(0) - , fOrigMethodError(0) - , fBoostWeight(0) , fDetailedMonitoring(kFALSE) - , fADABoostBeta(0) - , fRandomSeed(0) + , fAdaBoostBeta(0) + , fRandomSeed(0) + , fBaggedSampleFraction(0) , fBoostedMethodTitle(methodTitle) , fBoostedMethodOptions(theOption) - , fMonitorHist(0) , fMonitorBoostedMethod(kFALSE) , fMonitorTree(0) - , fBoostStage(Types::kBoostProcBegin) - , fDefaultHistNum(0) - , fRecalculateMVACut(kFALSE) + , fBoostWeight(0) + , fMethodError(0) , fROC_training(0.0) , fOverlap_integral(0.0) , fMVAvalues(0) @@ -107,20 +106,16 @@ TMVA::MethodBoost::MethodBoost( DataSetInfo& dsi, TDirectory* theTargetDir ) : TMVA::MethodCompositeBase( Types::kBoost, dsi, theWeightFile, theTargetDir ) , fBoostNum(0) - , fMethodError(0) - , fOrigMethodError(0) - , fBoostWeight(0) , fDetailedMonitoring(kFALSE) - , fADABoostBeta(0) + , fAdaBoostBeta(0) , fRandomSeed(0) + , fBaggedSampleFraction(0) , fBoostedMethodTitle("") , fBoostedMethodOptions("") - , fMonitorHist(0) , fMonitorBoostedMethod(kFALSE) , fMonitorTree(0) - , fBoostStage(Types::kBoostProcBegin) - , fDefaultHistNum(0) - , fRecalculateMVACut(kFALSE) + , fBoostWeight(0) + , fMethodError(0) , fROC_training(0.0) , fOverlap_integral(0.0) , fMVAvalues(0) @@ -136,10 +131,6 @@ TMVA::MethodBoost::~MethodBoost( void ) // the histogram themselves are deleted when the file is closed - if (fMonitorHist) { - for ( std::vector<TH1*>::iterator it = fMonitorHist->begin(); it != fMonitorHist->end(); ++it) delete *it; - delete fMonitorHist; - } fTrainSigMVAHist.clear(); fTrainBgdMVAHist.clear(); fBTrainSigMVAHist.clear(); @@ -174,26 +165,16 @@ void TMVA::MethodBoost::DeclareOptions() "Write monitoring histograms for each boosted classifier" ); DeclareOptionRef( fDetailedMonitoring = kFALSE, "Boost_DetailedMonitoring", - "Produce histograms for detailed boost-wise monitoring" ); + "Produce histograms for detailed boost monitoring" ); DeclareOptionRef( fBoostType = "AdaBoost", "Boost_Type", "Boosting type for the classifiers" ); + AddPreDefVal(TString("RealAdaBoost")); AddPreDefVal(TString("AdaBoost")); AddPreDefVal(TString("Bagging")); - AddPreDefVal(TString("HighEdgeGauss")); - AddPreDefVal(TString("HighEdgeCoPara")); - DeclareOptionRef( fMethodWeightType = "ByError", "Boost_MethodWeightType", - "How to set the final weight of the boosted classifiers" ); - AddPreDefVal(TString("ByError")); - AddPreDefVal(TString("Average")); - AddPreDefVal(TString("ByROC")); - AddPreDefVal(TString("ByOverlap")); - AddPreDefVal(TString("LastMethod")); + DeclareOptionRef(fBaggedSampleFraction=.6,"Boost_BaggedSampleFraction","Relative size of bagged event sample to original size of the data sample (used whenever bagging is used)" ); - DeclareOptionRef( fRecalculateMVACut = kTRUE, "Boost_RecalculateMVACut", - "Recalculate the classifier MVA Signallike cut at every boost iteration" ); - - DeclareOptionRef( fADABoostBeta = 1.0, "Boost_AdaBoostBeta", + DeclareOptionRef( fAdaBoostBeta = 1.0, "Boost_AdaBoostBeta", "The ADA boost parameter that sets the effect of every boost step on the events' weights" ); DeclareOptionRef( fTransformString = "step", "Boost_Transform", @@ -209,6 +190,42 @@ void TMVA::MethodBoost::DeclareOptions() TMVA::MethodCompositeBase::fMethods.reserve(fBoostNum); } +//_______________________________________________________________________ +void TMVA::MethodBoost::DeclareCompatibilityOptions() +{ + // options that are used ONLY for the READER to ensure backward compatibility + // they are hence without any effect (the reader is only reading the training + // options that HAD been used at the training of the .xml weightfile at hand + + + MethodBase::DeclareCompatibilityOptions(); + + DeclareOptionRef( fHistoricOption = "ByError", "Boost_MethodWeightType", + "How to set the final weight of the boosted classifiers" ); + AddPreDefVal(TString("ByError")); + AddPreDefVal(TString("Average")); + AddPreDefVal(TString("ByROC")); + AddPreDefVal(TString("ByOverlap")); + AddPreDefVal(TString("LastMethod")); + + DeclareOptionRef( fHistoricOption = "step", "Boost_Transform", + "Type of transform applied to every boosted method linear, log, step" ); + AddPreDefVal(TString("step")); + AddPreDefVal(TString("linear")); + AddPreDefVal(TString("log")); + AddPreDefVal(TString("gauss")); + + // this option here + //DeclareOptionRef( fBoostType = "AdaBoost", "Boost_Type", "Boosting type for the classifiers" ); + // still exists, but these two possible values + AddPreDefVal(TString("HighEdgeGauss")); + AddPreDefVal(TString("HighEdgeCoPara")); + // have been deleted .. hope that works :) + + DeclareOptionRef( fHistoricBoolOption, "Boost_RecalculateMVACut", + "Recalculate the classifier MVA Signallike cut at every boost iteration" ); + +} //_______________________________________________________________________ Bool_t TMVA::MethodBoost::BookMethod( Types::EMVA theMethod, TString methodTitle, TString theOption ) { @@ -232,85 +249,92 @@ void TMVA::MethodBoost::Init() void TMVA::MethodBoost::InitHistos() { // initialisation routine - if (fMonitorHist) { - for ( std::vector<TH1*>::iterator it = fMonitorHist->begin(); it != fMonitorHist->end(); ++it) delete *it; - delete fMonitorHist; + + + Results* results = Data()->GetResults(GetMethodName(), Types::kTraining, GetAnalysisType()); + + results->Store(new TH1F("MethodWeight","Normalized Classifier Weight",fBoostNum,0,fBoostNum),"ClassifierWeight"); + results->Store(new TH1F("BoostWeight","Boost Weight",fBoostNum,0,fBoostNum),"BoostWeight"); + results->Store(new TH1F("ErrFraction","Error Fraction (by boosted event weights)",fBoostNum,0,fBoostNum),"ErrorFraction"); + if (fDetailedMonitoring){ + results->Store(new TH1F("ROCIntegral_test","ROC integral of single classifier (testing sample)",fBoostNum,0,fBoostNum),"ROCIntegral_test"); + results->Store(new TH1F("ROCIntegralBoosted_test","ROC integral of boosted method (testing sample)",fBoostNum,0,fBoostNum),"ROCIntegralBoosted_test"); + results->Store(new TH1F("ROCIntegral_train","ROC integral of single classifier (training sample)",fBoostNum,0,fBoostNum),"ROCIntegral_train"); + results->Store(new TH1F("ROCIntegralBoosted_train","ROC integral of boosted method (training sample)",fBoostNum,0,fBoostNum),"ROCIntegralBoosted_train"); + results->Store(new TH1F("OverlapIntegal_train","Overlap integral (training sample)",fBoostNum,0,fBoostNum),"Overlap"); } - fMonitorHist = new std::vector<TH1*>(); - fMonitorHist->push_back(new TH1F("MethodWeight","Normalized Classifier Weight",fBoostNum,0,fBoostNum)); - fMonitorHist->push_back(new TH1F("BoostWeight","Boost Weight",fBoostNum,0,fBoostNum)); - fMonitorHist->push_back(new TH1F("ErrFraction","Error Fraction (by boosted event weights)",fBoostNum,0,fBoostNum)); - fMonitorHist->push_back(new TH1F("OrigErrFraction","Error Fraction (by original event weights)",fBoostNum,0,fBoostNum)); - fMonitorHist->push_back(new TH1F("ROCIntegral_test","ROC integral of single classifier (testing sample)",fBoostNum,0,fBoostNum)); - fMonitorHist->push_back(new TH1F("ROCIntegralBoosted_test","ROC integral of boosted method (testing sample)",fBoostNum,0,fBoostNum)); - fMonitorHist->push_back(new TH1F("ROCIntegral_train","ROC integral of single classifier (training sample)",fBoostNum,0,fBoostNum)); - fMonitorHist->push_back(new TH1F("ROCIntegralBoosted_train","ROC integral of boosted method (training sample)",fBoostNum,0,fBoostNum)); - fMonitorHist->push_back(new TH1F("OverlapIntegal_train","Overlap integral (training sample)",fBoostNum,0,fBoostNum)); - for ( std::vector<TH1*>::iterator it = fMonitorHist->begin(); it != fMonitorHist->end(); ++it ) (*it)->SetDirectory(0); - fDefaultHistNum = fMonitorHist->size(); - (*fMonitorHist)[0]->GetXaxis()->SetTitle("Index of boosted classifier"); - (*fMonitorHist)[0]->GetYaxis()->SetTitle("Classifier Weight"); - (*fMonitorHist)[1]->GetXaxis()->SetTitle("Index of boosted classifier"); - (*fMonitorHist)[1]->GetYaxis()->SetTitle("Boost Weight"); - (*fMonitorHist)[2]->GetXaxis()->SetTitle("Index of boosted classifier"); - (*fMonitorHist)[2]->GetYaxis()->SetTitle("Error Fraction"); - (*fMonitorHist)[3]->GetXaxis()->SetTitle("Index of boosted classifier"); - (*fMonitorHist)[3]->GetYaxis()->SetTitle("Error Fraction"); - (*fMonitorHist)[4]->GetXaxis()->SetTitle("Index of boosted classifier"); - (*fMonitorHist)[4]->GetYaxis()->SetTitle("ROC integral of single classifier"); - (*fMonitorHist)[5]->GetXaxis()->SetTitle("Number of boosts"); - (*fMonitorHist)[5]->GetYaxis()->SetTitle("ROC integral boosted"); - (*fMonitorHist)[6]->GetXaxis()->SetTitle("Index of boosted classifier"); - (*fMonitorHist)[6]->GetYaxis()->SetTitle("ROC integral of single classifier"); - (*fMonitorHist)[7]->GetXaxis()->SetTitle("Number of boosts"); - (*fMonitorHist)[7]->GetYaxis()->SetTitle("ROC integral boosted"); - (*fMonitorHist)[8]->GetXaxis()->SetTitle("Index of boosted classifier"); - (*fMonitorHist)[8]->GetYaxis()->SetTitle("Overlap integral"); + + + results->GetHist("ClassifierWeight")->GetXaxis()->SetTitle("Index of boosted classifier"); + results->GetHist("ClassifierWeight")->GetYaxis()->SetTitle("Classifier Weight"); + results->GetHist("BoostWeight")->GetXaxis()->SetTitle("Index of boosted classifier"); + results->GetHist("BoostWeight")->GetYaxis()->SetTitle("Boost Weight"); + results->GetHist("ErrorFraction")->GetXaxis()->SetTitle("Index of boosted classifier"); + results->GetHist("ErrorFraction")->GetYaxis()->SetTitle("Error Fraction"); + if (fDetailedMonitoring){ + results->GetHist("ROCIntegral_test")->GetXaxis()->SetTitle("Index of boosted classifier"); + results->GetHist("ROCIntegral_test")->GetYaxis()->SetTitle("ROC integral of single classifier"); + results->GetHist("ROCIntegralBoosted_test")->GetXaxis()->SetTitle("Number of boosts"); + results->GetHist("ROCIntegralBoosted_test")->GetYaxis()->SetTitle("ROC integral boosted"); + results->GetHist("ROCIntegral_train")->GetXaxis()->SetTitle("Index of boosted classifier"); + results->GetHist("ROCIntegral_train")->GetYaxis()->SetTitle("ROC integral of single classifier"); + results->GetHist("ROCIntegralBoosted_train")->GetXaxis()->SetTitle("Number of boosts"); + results->GetHist("ROCIntegralBoosted_train")->GetYaxis()->SetTitle("ROC integral boosted"); + results->GetHist("Overlap")->GetXaxis()->SetTitle("Index of boosted classifier"); + results->GetHist("Overlap")->GetYaxis()->SetTitle("Overlap integral"); + } + + results->Store(new TH1F("SoverBtotal","S/B in reweighted training sample",fBoostNum,0,fBoostNum),"SoverBtotal"); + results->GetHist("SoverBtotal")->GetYaxis()->SetTitle("S/B (boosted sample)"); + results->GetHist("SoverBtotal")->GetXaxis()->SetTitle("Index of boosted classifier"); + + results->Store(new TH1F("SeparationGain","SeparationGain",fBoostNum,0,fBoostNum),"SeparationGain"); + results->GetHist("SeparationGain")->GetYaxis()->SetTitle("SeparationGain"); + results->GetHist("SeparationGain")->GetXaxis()->SetTitle("Index of boosted classifier"); + + fMonitorTree= new TTree("MonitorBoost","Boost variables"); - fMonitorTree->Branch("iMethod",&fMethodIndex,"iMethod/I"); + fMonitorTree->Branch("iMethod",&fCurrentMethodIdx,"iMethod/I"); fMonitorTree->Branch("boostWeight",&fBoostWeight,"boostWeight/D"); fMonitorTree->Branch("errorFraction",&fMethodError,"errorFraction/D"); fMonitorBoostedMethod = kTRUE; + } //_______________________________________________________________________ void TMVA::MethodBoost::CheckSetup() { - Log() << kDEBUG << "CheckSetup: fBoostType="<<fBoostType<<" fMethodWeightType=" << fMethodWeightType << Endl; - Log() << kDEBUG << "CheckSetup: fADABoostBeta="<<fADABoostBeta<<Endl; + Log() << kDEBUG << "CheckSetup: fBoostType="<<fBoostType << Endl; + Log() << kDEBUG << "CheckSetup: fAdaBoostBeta="<<fAdaBoostBeta<<Endl; Log() << kDEBUG << "CheckSetup: fBoostWeight="<<fBoostWeight<<Endl; Log() << kDEBUG << "CheckSetup: fMethodError="<<fMethodError<<Endl; - Log() << kDEBUG << "CheckSetup: fOrigMethodError="<<fOrigMethodError<<Endl; - Log() << kDEBUG << "CheckSetup: fBoostNum="<<fBoostNum<< " fMonitorHist="<< fMonitorHist<< Endl; + Log() << kDEBUG << "CheckSetup: fBoostNum="<<fBoostNum << Endl; Log() << kDEBUG << "CheckSetup: fRandomSeed=" << fRandomSeed<< Endl; - Log() << kDEBUG << "CheckSetup: fDefaultHistNum=" << fDefaultHistNum << " fRecalculateMVACut=" << (fRecalculateMVACut? "true" : "false") << Endl; Log() << kDEBUG << "CheckSetup: fTrainSigMVAHist.size()="<<fTrainSigMVAHist.size()<<Endl; Log() << kDEBUG << "CheckSetup: fTestSigMVAHist.size()="<<fTestSigMVAHist.size()<<Endl; Log() << kDEBUG << "CheckSetup: fMonitorBoostedMethod=" << (fMonitorBoostedMethod? "true" : "false") << Endl; Log() << kDEBUG << "CheckSetup: MName=" << fBoostedMethodName << " Title="<< fBoostedMethodTitle<< Endl; Log() << kDEBUG << "CheckSetup: MOptions="<< fBoostedMethodOptions << Endl; - Log() << kDEBUG << "CheckSetup: fBoostStage=" << fBoostStage<<Endl; Log() << kDEBUG << "CheckSetup: fMonitorTree=" << fMonitorTree <<Endl; - Log() << kDEBUG << "CheckSetup: fMethodIndex=" <<fMethodIndex << Endl; + Log() << kDEBUG << "CheckSetup: fCurrentMethodIdx=" <<fCurrentMethodIdx << Endl; if (fMethods.size()>0) Log() << kDEBUG << "CheckSetup: fMethods[0]" <<fMethods[0]<<Endl; Log() << kDEBUG << "CheckSetup: fMethodWeight.size()" << fMethodWeight.size() << Endl; if (fMethodWeight.size()>0) Log() << kDEBUG << "CheckSetup: fMethodWeight[0]="<<fMethodWeight[0]<<Endl; Log() << kDEBUG << "CheckSetup: trying to repair things" << Endl; - if (fMonitorHist == 0){ - InitHistos(); - CheckSetup(); - } } //_______________________________________________________________________ void TMVA::MethodBoost::Train() { - Double_t AllMethodsWeight=0; TDirectory* methodDir( 0 ); TString dirName,dirTitle; Int_t StopCounter=0; + Results* results = Data()->GetResults(GetMethodName(), Types::kTraining, GetAnalysisType()); + + + InitHistos(); if (Data()->GetNTrainingEvents()==0) Log() << kFATAL << "<Train> Data() has zero events" << Endl; Data()->SetCurrentType(Types::kTraining); @@ -339,96 +363,95 @@ void TMVA::MethodBoost::Train() // // training and boosting the classifiers - for (fMethodIndex=0;fMethodIndex<fBoostNum;fMethodIndex++) { + for (fCurrentMethodIdx=0;fCurrentMethodIdx<fBoostNum;fCurrentMethodIdx++) { // the first classifier shows the option string output, the rest not - if (fMethodIndex>0) TMVA::MsgLogger::InhibitOutput(); + if (fCurrentMethodIdx>0) TMVA::MsgLogger::InhibitOutput(); IMethod* method = ClassifierFactory::Instance().Create(std::string(fBoostedMethodName), GetJobName(), - Form("%s_B%04i", fBoostedMethodTitle.Data(),fMethodIndex), + Form("%s_B%04i", fBoostedMethodTitle.Data(),fCurrentMethodIdx), DataInfo(), fBoostedMethodOptions); TMVA::MsgLogger::EnableOutput(); // supressing the rest of the classifier output the right way - MethodBase *meth = (dynamic_cast<MethodBase*>(method)); + fCurrentMethod = (dynamic_cast<MethodBase*>(method)); - if (meth==0) continue; + if (fCurrentMethod==0) { + Log() << kFATAL << "uups.. guess the booking of the " << fCurrentMethodIdx << "-th classifier somehow failed" << Endl; + return; // hope that makes coverity happy (as if fears I migh use the pointer later on, not knowing that FATAL exits + } // set fDataSetManager if MethodCategory (to enable Category to create datasetinfo objects) // DSMTEST - if (meth->GetMethodType() == Types::kCategory) { // DSMTEST - MethodCategory *methCat = (dynamic_cast<MethodCategory*>(meth)); // DSMTEST + if (fCurrentMethod->GetMethodType() == Types::kCategory) { // DSMTEST + MethodCategory *methCat = (dynamic_cast<MethodCategory*>(fCurrentMethod)); // DSMTEST if (!methCat) // DSMTEST Log() << kFATAL << "Method with type kCategory cannot be casted to MethodCategory. /MethodBoost" << Endl; // DSMTEST methCat->fDataSetManager = fDataSetManager; // DSMTEST } // DSMTEST - meth->SetMsgType(kWARNING); - meth->SetupMethod(); - meth->ParseOptions(); + fCurrentMethod->SetMsgType(kWARNING); + fCurrentMethod->SetupMethod(); + fCurrentMethod->ParseOptions(); // put SetAnalysisType here for the needs of MLP - meth->SetAnalysisType( GetAnalysisType() ); - meth->ProcessSetup(); - meth->CheckSetup(); + fCurrentMethod->SetAnalysisType( GetAnalysisType() ); + fCurrentMethod->ProcessSetup(); + fCurrentMethod->CheckSetup(); // reroute transformationhandler - meth->RerouteTransformationHandler (&(this->GetTransformationHandler())); + fCurrentMethod->RerouteTransformationHandler (&(this->GetTransformationHandler())); // creating the directory of the classifier if (fMonitorBoostedMethod) { - methodDir=MethodBaseDir()->GetDirectory(dirName=Form("%s_B%04i",fBoostedMethodName.Data(),fMethodIndex)); + methodDir=MethodBaseDir()->GetDirectory(dirName=Form("%s_B%04i",fBoostedMethodName.Data(),fCurrentMethodIdx)); if (methodDir==0) { - methodDir=BaseDir()->mkdir(dirName,dirTitle=Form("Directory Boosted %s #%04i", fBoostedMethodName.Data(),fMethodIndex)); - } - MethodBase* m = dynamic_cast<MethodBase*>(method); - if (m) { - m->SetMethodDir(methodDir); - m->BaseDir()->cd(); + methodDir=BaseDir()->mkdir(dirName,dirTitle=Form("Directory Boosted %s #%04i", fBoostedMethodName.Data(),fCurrentMethodIdx)); } + fCurrentMethod->SetMethodDir(methodDir); + fCurrentMethod->BaseDir()->cd(); } // training TMVA::MethodCompositeBase::fMethods.push_back(method); - timer.DrawProgressBar( fMethodIndex ); - if (fMethodIndex==0) method->MonitorBoost(SetStage(Types::kBoostProcBegin)); - method->MonitorBoost(SetStage(Types::kBeforeTraining)); + timer.DrawProgressBar( fCurrentMethodIdx ); + if (fCurrentMethodIdx==0) MonitorBoost(Types::kBoostProcBegin,fCurrentMethodIdx); + MonitorBoost(Types::kBeforeTraining,fCurrentMethodIdx); TMVA::MsgLogger::InhibitOutput(); //supressing Logger outside the method + if (fBoostType=="Bagging") Bagging(); // you want also to train the first classifier on a bagged sample SingleTrain(); TMVA::MsgLogger::EnableOutput(); - method->WriteMonitoringHistosToFile(); + fCurrentMethod->WriteMonitoringHistosToFile(); - // calculate MVA values of method on training sample + // calculate MVA values of current method for all events in training sample + // (used later on to get 'misclassified events' etc for the boosting CalcMVAValues(); - if (fMethodIndex==0 && fMonitorBoostedMethod) CreateMVAHistorgrams(); + if (fCurrentMethodIdx==0 && fMonitorBoostedMethod) CreateMVAHistorgrams(); // get ROC integral and overlap integral for single method on // training sample if fMethodWeightType == "ByROC" or the user // wants detailed monitoring - if (fMethodWeightType == "ByROC" || fDetailedMonitoring) - fROC_training = GetBoostROCIntegral(kTRUE, Types::kTraining, kTRUE); - // calculate method weight - CalcMethodWeight(); - AllMethodsWeight += fMethodWeight.back(); + // boosting (reweight training sample) + MonitorBoost(Types::kBeforeBoosting,fCurrentMethodIdx); + SingleBoost(fCurrentMethod); + + MonitorBoost(Types::kAfterBoosting,fCurrentMethodIdx); + results->GetHist("BoostWeight")->SetBinContent(fCurrentMethodIdx+1,fBoostWeight); + results->GetHist("ErrorFraction")->SetBinContent(fCurrentMethodIdx+1,fMethodError); if (fDetailedMonitoring) { - (*fMonitorHist)[4]->SetBinContent(fMethodIndex+1, GetBoostROCIntegral(kTRUE, Types::kTesting)); - (*fMonitorHist)[5]->SetBinContent(fMethodIndex+1, GetBoostROCIntegral(kFALSE, Types::kTesting)); - (*fMonitorHist)[6]->SetBinContent(fMethodIndex+1, fROC_training); - (*fMonitorHist)[7]->SetBinContent(fMethodIndex+1, GetBoostROCIntegral(kFALSE, Types::kTraining)); - (*fMonitorHist)[8]->SetBinContent(fMethodIndex+1, fOverlap_integral); + fROC_training = GetBoostROCIntegral(kTRUE, Types::kTraining, kTRUE); + results->GetHist("ROCIntegral_test")->SetBinContent(fCurrentMethodIdx+1, GetBoostROCIntegral(kTRUE, Types::kTesting)); + results->GetHist("ROCIntegralBoosted_test")->SetBinContent(fCurrentMethodIdx+1, GetBoostROCIntegral(kFALSE, Types::kTesting)); + results->GetHist("ROCIntegral_train")->SetBinContent(fCurrentMethodIdx+1, fROC_training); + results->GetHist("ROCIntegralBoosted_train")->SetBinContent(fCurrentMethodIdx+1, GetBoostROCIntegral(kFALSE, Types::kTraining)); + results->GetHist("Overlap")->SetBinContent(fCurrentMethodIdx+1, fOverlap_integral); } - // boosting (reweight training sample) - method->MonitorBoost(SetStage(Types::kBeforeBoosting)); - SingleBoost(); - method->MonitorBoost(SetStage(Types::kAfterBoosting)); - (*fMonitorHist)[1]->SetBinContent(fMethodIndex+1,fBoostWeight); - (*fMonitorHist)[2]->SetBinContent(fMethodIndex+1,fMethodError); - (*fMonitorHist)[3]->SetBinContent(fMethodIndex+1,fOrigMethodError); + fMonitorTree->Fill(); @@ -438,35 +461,34 @@ void TMVA::MethodBoost::Train() if (fMethodError > 0.49999) StopCounter++; if (StopCounter > 0 && fBoostType != "Bagging") { timer.DrawProgressBar( fBoostNum ); - fBoostNum = fMethodIndex+1; + fBoostNum = fCurrentMethodIdx+1; Log() << kINFO << "Error rate has reached 0.5 ("<< fMethodError<<"), boosting process stopped at #" << fBoostNum << " classifier" << Endl; if (fBoostNum < 5) - Log() << kINFO << "The classifier might be too strong to boost with Beta = " << fADABoostBeta << ", try reducing it." <<Endl; - for (Int_t i=0;i<fDefaultHistNum;i++) (*fMonitorHist)[i]->SetBins(fBoostNum,0,fBoostNum); + Log() << kINFO << "The classifier might be too strong to boost with Beta = " << fAdaBoostBeta << ", try reducing it." <<Endl; break; } } - if (fMethodWeightType == "LastMethod") { fMethodWeight.back() = AllMethodsWeight = 1.0; } + + //as MethodBoost acts not on a private event sample (like MethodBDT does), we need to remember not + // to leave "boosted" events to the next classifier in the factory ResetBoostWeights(); - Timer* timer1=new Timer(); + + Timer* timer1= new Timer( fBoostNum, GetName() ); // normalizing the weights of the classifiers - for (fMethodIndex=0;fMethodIndex<fBoostNum;fMethodIndex++) { + for (fCurrentMethodIdx=0;fCurrentMethodIdx<fBoostNum;fCurrentMethodIdx++) { // pefroming post-boosting actions - if (fMethods[fMethodIndex]->MonitorBoost(SetStage(Types::kBoostValidation))) { - if (fMethodIndex==0) timer1 = new Timer( fBoostNum, GetName() ); - timer1->DrawProgressBar( fMethodIndex ); - - if (fMethodIndex==fBoostNum) { - Log() << kINFO << "Elapsed time: " << timer1->GetElapsedTime() - << " " << Endl; - } + timer1->DrawProgressBar( fCurrentMethodIdx ); + + if (fCurrentMethodIdx==fBoostNum) { + Log() << kINFO << "Elapsed time: " << timer1->GetElapsedTime() + << " " << Endl; } - - if (AllMethodsWeight != 0.0) - fMethodWeight[fMethodIndex] = fMethodWeight[fMethodIndex] / AllMethodsWeight; - (*fMonitorHist)[0]->SetBinContent(fMethodIndex+1,fMethodWeight[fMethodIndex]); + + TH1F* tmp = dynamic_cast<TH1F*>( results->GetHist("ClassifierWeight") ); + if (tmp) tmp->SetBinContent(fCurrentMethodIdx+1,fMethodWeight[fCurrentMethodIdx]); + } // Ensure that in case of only 1 boost the method weight equals @@ -476,7 +498,7 @@ void TMVA::MethodBoost::Train() // not ok if one boosts just one time. if (fMethods.size()==1) fMethodWeight[0] = 1.0; - fMethods.back()->MonitorBoost(SetStage(Types::kBoostProcEnd)); + MonitorBoost(Types::kBoostProcEnd); delete timer1; } @@ -506,7 +528,7 @@ void TMVA::MethodBoost::CreateMVAHistorgrams() xmax = TMath::Min( TMath::Max(meanS + nrms*rmsS, meanB + nrms*rmsB ), xmax ) + 0.00001; // creating all the historgrams - for (Int_t imtd=0; imtd<fBoostNum; imtd++) { + for (UInt_t imtd=0; imtd<fBoostNum; imtd++) { fTrainSigMVAHist .push_back( new TH1F( Form("MVA_Train_S_%04i",imtd), "MVA_Train_S", fNbins, xmin, xmax ) ); fTrainBgdMVAHist .push_back( new TH1F( Form("MVA_Train_B%04i", imtd), "MVA_Train_B", fNbins, xmin, xmax ) ); fBTrainSigMVAHist.push_back( new TH1F( Form("MVA_BTrain_S%04i",imtd), "MVA_BoostedTrain_S", fNbins, xmin, xmax ) ); @@ -521,7 +543,7 @@ void TMVA::MethodBoost::ResetBoostWeights() { // resetting back the boosted weights of the events to 1 for (Long64_t ievt=0; ievt<GetNEvents(); ievt++) { - Event *ev = Data()->GetEvent(ievt); + const Event *ev = Data()->GetEvent(ievt); ev->SetBoostWeight( 1.0 ); } } @@ -531,7 +553,7 @@ void TMVA::MethodBoost::WriteMonitoringHistosToFile( void ) const { TDirectory* dir=0; if (fMonitorBoostedMethod) { - for (Int_t imtd=0;imtd<fBoostNum;imtd++) { + for (UInt_t imtd=0;imtd<fBoostNum;imtd++) { //writing the histograms in the specific classifier's directory MethodBase* m = dynamic_cast<MethodBase*>(fMethods[imtd]); @@ -551,9 +573,6 @@ void TMVA::MethodBoost::WriteMonitoringHistosToFile( void ) const // going back to the original folder BaseDir()->cd(); - for (UInt_t i=0;i<fMonitorHist->size();i++) { - ((*fMonitorHist)[i])->Write(Form("Booster_%s",((*fMonitorHist)[i])->GetName())); - } fMonitorTree->Write(); } @@ -625,128 +644,235 @@ void TMVA::MethodBoost::SingleTrain() } //_______________________________________________________________________ -void TMVA::MethodBoost::FindMVACut() +void TMVA::MethodBoost::FindMVACut(MethodBase *method) { // find the CUT on the individual MVA that defines an event as // correct or misclassified (to be used in the boosting process) - MethodBase* lastMethod=dynamic_cast<MethodBase*>(fMethods.back()); - if (!lastMethod || lastMethod->GetMethodType() == Types::kDT ){ return;} + if (!method || method->GetMethodType() == Types::kDT ){ return;} - if (!fRecalculateMVACut && fMethodIndex>0) { - MethodBase* m = dynamic_cast<MethodBase*>(fMethods[0]); - if (m) lastMethod->SetSignalReferenceCut(m->GetSignalReferenceCut()); - } - else { - - // creating a fine histograms containing the error rate - const Int_t nBins=101; - Double_t minMVA=150000; - Double_t maxMVA=-150000; - for (Long64_t ievt=0; ievt<Data()->GetNEvents(); ievt++) { - GetEvent(ievt); - Double_t val=lastMethod->GetMvaValue(); - if (val>maxMVA) maxMVA=val; - if (val<minMVA) minMVA=val; - } - - Double_t sum = 0.; - - TH1F *mvaS = new TH1F("mvaS","",nBins,minMVA,maxMVA); - TH1F *mvaB = new TH1F("mvaB","",nBins,minMVA,maxMVA); - TH1F *mvaSC = new TH1F("mvaSC","",nBins,minMVA,maxMVA); - TH1F *mvaBC = new TH1F("mvaBC","",nBins,minMVA,maxMVA); - - for (Long64_t ievt=0; ievt<Data()->GetNEvents(); ievt++) { - - Double_t weight = GetEvent(ievt)->GetWeight(); - Double_t mvaVal=lastMethod->GetMvaValue(); - sum +=weight; - if (DataInfo().IsSignal(GetEvent(ievt))){ - mvaS->Fill(mvaVal,weight); - }else { - mvaB->Fill(mvaVal,weight); - } - } - SeparationBase *sepGain; - //sepGain = new MisClassificationError(); - sepGain = new GiniIndex(); - //sepGain = new CrossEntropy(); + // creating a fine histograms containing the error rate + const Int_t nBins=10001; + Double_t minMVA=150000; + Double_t maxMVA=-150000; + for (Long64_t ievt=0; ievt<Data()->GetNEvents(); ievt++) { + GetEvent(ievt); + Double_t val=method->GetMvaValue(); + //Helge .. I think one could very well use fMVAValues for that ... -->to do + if (val>maxMVA) maxMVA=val; + if (val<minMVA) minMVA=val; + } + maxMVA = maxMVA+(maxMVA-minMVA)/nBins; + + Double_t sum = 0.; + + TH1D *mvaS = new TH1D(Form("MVAS_%d",fCurrentMethodIdx) ,"",nBins,minMVA,maxMVA); + TH1D *mvaB = new TH1D(Form("MVAB_%d",fCurrentMethodIdx) ,"",nBins,minMVA,maxMVA); + TH1D *mvaSC = new TH1D(Form("MVASC_%d",fCurrentMethodIdx),"",nBins,minMVA,maxMVA); + TH1D *mvaBC = new TH1D(Form("MVABC_%d",fCurrentMethodIdx),"",nBins,minMVA,maxMVA); + + + Results* results = Data()->GetResults(GetMethodName(), Types::kTraining, GetAnalysisType()); + if (fDetailedMonitoring){ + results->Store(mvaS, Form("MVAS_%d",fCurrentMethodIdx)); + results->Store(mvaB, Form("MVAB_%d",fCurrentMethodIdx)); + results->Store(mvaSC,Form("MVASC_%d",fCurrentMethodIdx)); + results->Store(mvaBC,Form("MVABC_%d",fCurrentMethodIdx)); + } - Double_t sTot = mvaS->GetSum(); - Double_t bTot = mvaB->GetSum(); + for (Long64_t ievt=0; ievt<Data()->GetNEvents(); ievt++) { - mvaSC->SetBinContent(1,mvaS->GetBinContent(1)); - mvaBC->SetBinContent(1,mvaB->GetBinContent(1)); - Double_t sSel=mvaSC->GetBinContent(1); - Double_t bSel=mvaBC->GetBinContent(1); - Double_t separationGain=sepGain->GetSeparationGain(sSel,bSel,sTot,bTot); - Double_t mvaCut=mvaSC->GetBinLowEdge(1); - // cout << "minMVA =" << minMVA << " maxMVA = " << maxMVA << " width = " << mvaSC->GetBinWidth(1) << endl; - - // for (Int_t ibin=1;ibin<=nBins;ibin++) cout << " cutvalues[" << ibin<<"]="<<mvaSC->GetBinLowEdge(ibin) << " " << mvaSC->GetBinCenter(ibin) << endl; - Double_t mvaCutOrientation=1; // 1 if mva > mvaCut --> Signal and -1 if mva < mvaCut (i.e. mva*-1 > mvaCut*-1) --> Signal - Double_t SoBRight=1, SoBLeft=1; - for (Int_t ibin=2;ibin<nBins;ibin++){ - mvaSC->SetBinContent(ibin,mvaS->GetBinContent(ibin)+mvaSC->GetBinContent(ibin-1)); - mvaBC->SetBinContent(ibin,mvaB->GetBinContent(ibin)+mvaBC->GetBinContent(ibin-1)); - - sSel=mvaSC->GetBinContent(ibin); - bSel=mvaBC->GetBinContent(ibin); - - if (separationGain < sepGain->GetSeparationGain(sSel,bSel,sTot,bTot) - // && (mvaSC->GetBinCenter(ibin) >0 || (fMethodIndex+1)%2 ) - ){ - separationGain = sepGain->GetSeparationGain(sSel,bSel,sTot,bTot); - mvaCut=mvaSC->GetBinCenter(ibin); - mvaCut=mvaSC->GetBinLowEdge(ibin+1); - if (sSel/bSel > (sTot-sSel)/(bTot-bSel)) mvaCutOrientation=-1; - else mvaCutOrientation=1; - SoBRight=sSel/bSel; - SoBLeft=(sTot-sSel)/(bTot-bSel); - } + Double_t weight = GetEvent(ievt)->GetWeight(); + Double_t mvaVal=method->GetMvaValue(); + sum +=weight; + if (DataInfo().IsSignal(GetEvent(ievt))){ + mvaS->Fill(mvaVal,weight); + }else { + mvaB->Fill(mvaVal,weight); } + } + SeparationBase *sepGain; + - if (SoBRight<1 && SoBLeft<1) { - if (mvaCutOrientation == -1) mvaCut = mvaSC->GetBinCenter(1)-mvaSC->GetBinWidth(1); - if (mvaCutOrientation == 1) mvaCut = mvaSC->GetBinCenter(nBins)+mvaSC->GetBinWidth(nBins); - } else if (SoBRight>1 && SoBLeft>1) { - if (mvaCutOrientation == 1) mvaCut = mvaSC->GetBinCenter(1)-mvaSC->GetBinWidth(1); - if (mvaCutOrientation == -1) mvaCut = mvaSC->GetBinCenter(nBins)+mvaSC->GetBinWidth(nBins); - } - + // Boosting should use Miscalssification not Gini Index (changed, Helge 31.5.2013) + // ACHTUNG !! mit "Misclassification" geht es NUR wenn man die Signal zu Background bei jedem Boost schritt + // wieder hinbiegt. Es gibt aber komischerweise bessere Ergebnisse (genau wie bei BDT auch schon beobachtet) wenn + // man GiniIndex benutzt und akzeptiert dass jedes andere mal KEIN vernuenftiger Cut gefunden wird - d.h. der + // Cut liegt dann ausserhalb der MVA value range, alle events sind als Bkg classifiziert und dann wird entpsrehcend + // des Boost algorithmus 'automitisch' etwas renormiert .. sodass im naechsten Schritt dann wieder was vernuenftiges + // rauskommt. Komisch .. dass DAS richtig sein soll ?? + + // SeparationBase *sepGain2 = new MisClassificationError(); + //sepGain = new MisClassificationError(); + sepGain = new GiniIndex(); + //sepGain = new CrossEntropy(); + + Double_t sTot = mvaS->GetSum(); + Double_t bTot = mvaB->GetSum(); + + mvaSC->SetBinContent(1,mvaS->GetBinContent(1)); + mvaBC->SetBinContent(1,mvaB->GetBinContent(1)); + Double_t sSel=0; + Double_t bSel=0; + Double_t separationGain=sepGain->GetSeparationGain(sSel,bSel,sTot,bTot); + Double_t mvaCut=mvaSC->GetBinLowEdge(1); + Double_t sSelCut=sSel; + Double_t bSelCut=bSel; + // std::cout << "minMVA =" << minMVA << " maxMVA = " << maxMVA << " width = " << mvaSC->GetBinWidth(1) << std::endl; + + // for (Int_t ibin=1;ibin<=nBins;ibin++) std::cout << " cutvalues[" << ibin<<"]="<<mvaSC->GetBinLowEdge(ibin) << " " << mvaSC->GetBinCenter(ibin) << std::endl; + Double_t mvaCutOrientation=1; // 1 if mva > mvaCut --> Signal and -1 if mva < mvaCut (i.e. mva*-1 > mvaCut*-1) --> Signal + Double_t SoBRight=1, SoBLeft=1; + for (Int_t ibin=1;ibin<=nBins;ibin++){ + mvaSC->SetBinContent(ibin,mvaS->GetBinContent(ibin)+mvaSC->GetBinContent(ibin-1)); + mvaBC->SetBinContent(ibin,mvaB->GetBinContent(ibin)+mvaBC->GetBinContent(ibin-1)); - // cout << "Min="<<minMVA << " Max=" << maxMVA - // << " sTot=" << sTot - // << " bTot=" << bTot - // << " sepGain="<<separationGain - // << " cut=" << mvaCut - // << " cutOrientation="<<mvaCutOrientation - // << endl; - // cout << "S/B right="<<SoBRight << " left="<<SoBLeft<<endl; - // if (fMethodIndex==0)mvaCut = -1.9616885110735893e-02; - // if (fMethodIndex==1)mvaCut = -6.8812005221843719e-02; - lastMethod->SetSignalReferenceCut(mvaCut); - lastMethod->SetSignalReferenceCutOrientation(mvaCutOrientation); + sSel=mvaSC->GetBinContent(ibin); + bSel=mvaBC->GetBinContent(ibin); + + // if (ibin==nBins){ + // std::cout << "Last bin s="<< sSel <<" b="<<bSel << " s="<< sTot-sSel <<" b="<<bTot-bSel << endl; + // } + + if (separationGain < sepGain->GetSeparationGain(sSel,bSel,sTot,bTot) + // && (mvaSC->GetBinCenter(ibin) >0 || (fCurrentMethodIdx+1)%2 ) + ){ + separationGain = sepGain->GetSeparationGain(sSel,bSel,sTot,bTot); + // mvaCut=mvaSC->GetBinCenter(ibin); + mvaCut=mvaSC->GetBinLowEdge(ibin+1); + if (sSel/bSel > (sTot-sSel)/(bTot-bSel)) mvaCutOrientation=-1; + else mvaCutOrientation=1; + SoBRight=sSel/bSel; + SoBLeft=(sTot-sSel)/(bTot-bSel); + sSelCut=sSel; + bSelCut=bSel; + // std::cout << "new cut at " << mvaCut << "with s="<<sTot-sSel << " b="<<bTot-bSel << std::endl; + } + /* + Double_t ori; + if (sSel/bSel > (sTot-sSel)/(bTot-bSel)) ori=-1; + else ori=1; + std::cout << ibin << " mvacut="<<mvaCut + << " sTot=" << sTot + << " bTot=" << bTot + << " sSel=" << sSel + << " bSel=" << bSel + << " s/b(1)=" << sSel/bSel + << " s/b(2)=" << (sTot-sSel)/(bTot-bSel) + << " sepGain="<<sepGain->GetSeparationGain(sSel,bSel,sTot,bTot) + << " sepGain2="<<sepGain2->GetSeparationGain(sSel,bSel,sTot,bTot) + << " " <<ori + << std::endl; + */ + + } + + // if (SoBRight<1 && SoBLeft<1) { + // if (mvaCutOrientation == -1) mvaCut = mvaSC->GetBinCenter(1)-mvaSC->GetBinWidth(1); + // if (mvaCutOrientation == 1) mvaCut = mvaSC->GetBinCenter(nBins)+mvaSC->GetBinWidth(nBins); + // } else if (SoBRight>1 && SoBLeft>1) { + // if (mvaCutOrientation == 1) mvaCut = mvaSC->GetBinCenter(1)-mvaSC->GetBinWidth(1); + // if (mvaCutOrientation == -1) mvaCut = mvaSC->GetBinCenter(nBins)+mvaSC->GetBinWidth(nBins); + // } + + //if (mvaCut > maxMVA || mvaCut < minMVA){ + if (0){ - Log() << kDEBUG << "(old step) Setting method cut to " <<lastMethod->GetSignalReferenceCut()<< Endl; - mvaS ->Delete(); - mvaB ->Delete(); - mvaSC->Delete(); - mvaBC->Delete(); + + double parentIndex=sepGain->GetSeparationIndex(sTot,bTot); + double leftIndex =sepGain->GetSeparationIndex(sSelCut,bSelCut); + double rightIndex =sepGain->GetSeparationIndex(sTot-sSelCut,bTot-bSelCut); + std::cout + << " sTot=" << sTot + << " bTot=" << bTot + << " s="<<sSelCut + << " b="<<bSelCut + << " s2="<<(sTot-sSelCut) + << " b2="<<(bTot-bSelCut) + << " s/b(1)=" << sSelCut/bSelCut + << " s/b(2)=" << (sTot-sSelCut)/(bTot-bSelCut) + << " index before cut=" << parentIndex + << " after: left=" << leftIndex + << " after: right=" << rightIndex + << " sepGain=" << parentIndex-( (sSelCut+bSelCut) * leftIndex + (sTot-sSelCut+bTot-bSelCut) * rightIndex )/(sTot+bTot) + << " sepGain="<<separationGain + << " sepGain="<<sepGain->GetSeparationGain(sSelCut,bSelCut,sTot,bTot) + << " cut=" << mvaCut + << " idx="<<fCurrentMethodIdx + << " cutOrientation="<<mvaCutOrientation + << std::endl; + std::cout << "S/B right="<<SoBRight << " left="<<SoBLeft<<std::endl; } + method->SetSignalReferenceCut(mvaCut); + method->SetSignalReferenceCutOrientation(mvaCutOrientation); + + results->GetHist("SeparationGain")->SetBinContent(fCurrentMethodIdx+1,separationGain); + + + Log() << kDEBUG << "(old step) Setting method cut to " <<method->GetSignalReferenceCut()<< Endl; + // mvaS ->Delete(); + // mvaB ->Delete(); + // mvaSC->Delete(); + // mvaBC->Delete(); } //_______________________________________________________________________ -void TMVA::MethodBoost::SingleBoost() +Double_t TMVA::MethodBoost::SingleBoost(MethodBase* method) +{ + Double_t returnVal=-1; + + + if (fBoostType=="AdaBoost") returnVal = this->AdaBoost (method,1); + else if (fBoostType=="RealAdaBoost") returnVal = this->AdaBoost (method,0); + else if (fBoostType=="Bagging") returnVal = this->Bagging (); + else{ + Log() << kFATAL << "<Boost> unknown boost option " << fBoostType<< " called" << Endl; + } + fMethodWeight.push_back(returnVal); + return returnVal; +} +//_______________________________________________________________________ +Double_t TMVA::MethodBoost::AdaBoost(MethodBase* method, Bool_t discreteAdaBoost) { - MethodBase* method = dynamic_cast<MethodBase*>(fMethods.back()); - if (!method) return; - Float_t w,v,wo; Bool_t sig=kTRUE; - Double_t sumAll=0, sumWrong=0, sumAllOrig=0, sumWrongOrig=0, sumAll1=0; + // the standard (discrete or real) AdaBoost algorithm + + Double_t returnVal=-1; + + if (!method) { + Log() << kWARNING << " AdaBoost called without classifier reference - needed for calulating AdaBoost " << Endl; + return 0; + } + + if (!method) { + Log() << kFATAL << " You cannot call AdaBoost without MVA classifier" << Endl; + return returnVal; + } + + Float_t w,v; Bool_t sig=kTRUE; + Double_t sumAll=0, sumWrong=0; Bool_t* WrongDetection=new Bool_t[GetNEvents()]; + QuickMVAProbEstimator *MVAProb=NULL; + + if (discreteAdaBoost) { + FindMVACut(method); + Log() << kDEBUG << " individual mva cut value = " << method->GetSignalReferenceCut() << Endl; + } else { + MVAProb=new TMVA::QuickMVAProbEstimator(); + // the RealAdaBoost does use a simple "yes (signal)" or "no (background)" + // answer from your single MVA, but a "signal probability" instead (in the BDT case, + // that would be the 'purity' in the leaf node. For some MLP parameter, the MVA output + // can also interpreted as a probability, but here I try a genera aproach to get this + // probability from the MVA distributions... + + for (Long64_t evt=0; evt<GetNEvents(); evt++) { + const Event* ev = Data()->GetEvent(evt); + MVAProb->AddEvent(fMVAvalues->at(evt),ev->GetWeight(),ev->GetClass()); + } + } + + for (Long64_t ievt=0; ievt<GetNEvents(); ievt++) WrongDetection[ievt]=kTRUE; // finding the wrong events and calculating their total weights @@ -755,177 +881,140 @@ void TMVA::MethodBoost::SingleBoost() sig=DataInfo().IsSignal(ev); v = fMVAvalues->at(ievt); w = ev->GetWeight(); - wo = ev->GetOriginalWeight(); - if (sig && fMonitorBoostedMethod) { - fBTrainSigMVAHist[fMethodIndex]->Fill(v,w); - fTrainSigMVAHist[fMethodIndex]->Fill(v,ev->GetOriginalWeight()); - } - else if (fMonitorBoostedMethod) { - fBTrainBgdMVAHist[fMethodIndex]->Fill(v,w); - fTrainBgdMVAHist[fMethodIndex]->Fill(v,ev->GetOriginalWeight()); - } sumAll += w; - sumAllOrig += wo; - if (sig == method->IsSignalLike(fMVAvalues->at(ievt))){ - WrongDetection[ievt]=kFALSE; + if (fMonitorBoostedMethod) { + if (sig) { + fBTrainSigMVAHist[fCurrentMethodIdx]->Fill(v,w); + fTrainSigMVAHist[fCurrentMethodIdx]->Fill(v,ev->GetOriginalWeight()); + } + else { + fBTrainBgdMVAHist[fCurrentMethodIdx]->Fill(v,w); + fTrainBgdMVAHist[fCurrentMethodIdx]->Fill(v,ev->GetOriginalWeight()); + } + } + + if (discreteAdaBoost){ + if (sig == method->IsSignalLike(fMVAvalues->at(ievt))){ + WrongDetection[ievt]=kFALSE; + }else{ + WrongDetection[ievt]=kTRUE; + sumWrong+=w; + } }else{ - WrongDetection[ievt]=kTRUE; - sumWrong+=w; - sumWrongOrig+=wo; + Double_t mvaProb = MVAProb->GetMVAProbAt((Float_t)fMVAvalues->at(ievt)); + mvaProb = 2*(mvaProb-0.5); + Int_t trueType; + if (DataInfo().IsSignal(ev)) trueType = 1; + else trueType = -1; + sumWrong+= w*trueType*mvaProb; } } + fMethodError=sumWrong/sumAll; - fOrigMethodError = sumWrongOrig/sumAllOrig; - Log() << kDEBUG << "AdaBoost err (MethodErr1)= " << fMethodError<<" = wrong/all: " << sumWrong << "/" << sumAll<< " cut="<<method->GetSignalReferenceCut()<< Endl; - // calculating the fMethodError and the fBoostWeight out of it uses the formula + // calculating the fMethodError and the boostWeight out of it uses the formula // w = ((1-err)/err)^beta - if (fMethodError>0 && fADABoostBeta == 1.0) { - fBoostWeight = (1.0-fMethodError)/fMethodError; - } - else if (fMethodError>0 && fADABoostBeta != 1.0) { - fBoostWeight = TMath::Power((1.0 - fMethodError)/fMethodError, fADABoostBeta); - } - else fBoostWeight = 1000; + Double_t boostWeight=0; - Double_t alphaWeight = ( fBoostWeight > 0.0 ? TMath::Log(fBoostWeight) : 0.0); - if (alphaWeight>5.) alphaWeight = 5.; - if (alphaWeight<0.){ - Log() << kWARNING << "alphaWeight is too small in AdaBoost (alpha = " << alphaWeight << ")" << Endl; - alphaWeight = -alphaWeight; - } - if (fBoostType == "AdaBoost") { + if (fMethodError == 0) { //no misclassification made.. perfect, no boost ;) + Log() << kWARNING << "Your classifier worked perfectly on the training sample --> serious overtraining expected and no boosting done " << Endl; + }else{ + + if (discreteAdaBoost) + boostWeight = TMath::Log((1.-fMethodError)/fMethodError)*fAdaBoostBeta; + else + boostWeight = TMath::Log((1.+fMethodError)/(1-fMethodError))*fAdaBoostBeta; + + + // std::cout << "boostweight = " << boostWeight << std::endl; + // ADA boosting, rescaling the weight of the wrong events according to the error level // over the entire test sample rescaling all the weights to have the same sum, but without // touching the original weights (changing only the boosted weight of all the events) // first reweight + Double_t newSum=0., oldSum=0.; + + + Double_t boostfactor = TMath::Exp(boostWeight); + + for (Long64_t ievt=0; ievt<GetNEvents(); ievt++) { - Event* ev = Data()->GetEvent(ievt); + const Event* ev = Data()->GetEvent(ievt); oldSum += ev->GetWeight(); - if (WrongDetection[ievt] && fBoostWeight != 0) { - if (ev->GetWeight() > 0) ev->ScaleBoostWeight(fBoostWeight); - else ev->ScaleBoostWeight(1./fBoostWeight); + if (discreteAdaBoost){ + // events are classified as Signal OR background .. right or wrong + if (WrongDetection[ievt] && boostWeight != 0) { + if (ev->GetWeight() > 0) ev->ScaleBoostWeight(boostfactor); + else ev->ScaleBoostWeight(1./boostfactor); + } + // if (ievt<30) std::cout<<ievt<<" var0="<<ev->GetValue(0)<<" var1="<<ev->GetValue(1)<<" weight="<<ev->GetWeight() << " boostby:"<<boostfactor<<std::endl; + + }else{ + // events are classified by their probability of being signal or background + // (eventually you should write this one - i.e. re-use the MVA value that were already + // calcualted and stroed.. however ,for the moement .. + Double_t mvaProb = MVAProb->GetMVAProbAt((Float_t)fMVAvalues->at(ievt)); + mvaProb = 2*(mvaProb-0.5); + // mvaProb = (1-mvaProb); + + Int_t trueType=1; + if (DataInfo().IsSignal(ev)) trueType = 1; + else trueType = -1; + + boostfactor = TMath::Exp(-1*boostWeight*trueType*mvaProb); + if (ev->GetWeight() > 0) ev->ScaleBoostWeight(boostfactor); + else ev->ScaleBoostWeight(1./boostfactor); + } newSum += ev->GetWeight(); } - + Double_t normWeight = oldSum/newSum; - // bla std::cout << "Normalize weight by (Boost)" << normWeight << " = " << oldSum<<"/"<<newSum<< " eventBoostFactor="<<fBoostWeight<<std::endl; // next normalize the weights Double_t normSig=0, normBkg=0; for (Long64_t ievt=0; ievt<GetNEvents(); ievt++) { - Event* ev = Data()->GetEvent(ievt); - ev->ScaleBoostWeight(normWeight); - if (ev->GetClass()) normBkg+=ev->GetWeight(); - else normSig+=ev->GetWeight(); - } - } - else if (fBoostType == "Bagging") { - // Bagging or Bootstrap boosting, gives new random weight for every event - TRandom3*trandom = new TRandom3(fRandomSeed+fMethods.size()); - for (Long64_t ievt=0; ievt<GetNEvents(); ievt++) { - Event* ev = Data()->GetEvent(ievt); - ev->SetBoostWeight(trandom->Rndm()); - sumAll1+=ev->GetWeight(); + const Event* ev = Data()->GetEvent(ievt); + ev->ScaleBoostWeight(normWeight); + if (ev->GetClass()) normSig+=ev->GetWeight(); + else normBkg+=ev->GetWeight(); } - // rescaling all the weights to have the same sum, but without touching the original - // weights (changing only the boosted weight of all the events) - Double_t Factor=sumAll/sumAll1; + + Results* results = Data()->GetResults(GetMethodName(), Types::kTraining, GetAnalysisType()); + results->GetHist("SoverBtotal")->SetBinContent(fCurrentMethodIdx+1, normSig/normBkg); + for (Long64_t ievt=0; ievt<GetNEvents(); ievt++) { - Event* ev = Data()->GetEvent(ievt); - ev->ScaleBoostWeight(Factor); + const Event* ev = Data()->GetEvent(ievt); + + if (ev->GetClass()) ev->ScaleBoostWeight(oldSum/normSig/2); + else ev->ScaleBoostWeight(oldSum/normBkg/2); } } - else if (fBoostType == "HighEdgeGauss" || - fBoostType == "HighEdgeCoPara") { - // Give events high boost weight, which are close of far away - // from the MVA cut value - Double_t MVACutValue = method->GetSignalReferenceCut(); - sumAll1 = 0; - for (Long64_t ievt=0; ievt<GetNEvents(); ievt++) { - Event* ev = Data()->GetEvent(ievt); - if (fBoostType == "HighEdgeGauss") - ev->SetBoostWeight( TMath::Exp( -std::pow(fMVAvalues->at(ievt)-MVACutValue,2)/(0.1*fADABoostBeta) ) ); - else if (fBoostType == "HighEdgeCoPara") - ev->SetBoostWeight( DataInfo().IsSignal(ev) ? TMath::Power(1.0-fMVAvalues->at(ievt),fADABoostBeta) : TMath::Power(fMVAvalues->at(ievt),fADABoostBeta) ); - else - Log() << kFATAL << "Unknown event weight type!" << Endl; - sumAll1 += ev->GetWeight(); - } - // rescaling all the weights to have the same sum, but without - // touching the original weights (changing only the boosted - // weight of all the events) - Double_t Factor=sumAll/sumAll1; - for (Long64_t ievt=0; ievt<GetNEvents(); ievt++) - Data()->GetEvent(ievt)->ScaleBoostWeight(Factor); - } delete[] WrongDetection; -} + if (MVAProb) delete MVAProb; -//_______________________________________________________________________ -void TMVA::MethodBoost::CalcMethodWeight() -{ - // Calculate weight of single method. - // This is no longer done in SingleBoost(); - - MethodBase* method = dynamic_cast<MethodBase*>(fMethods.back()); - if (!method) { - Log() << kFATAL << "Dynamic cast to MethodBase* failed" <<Endl; - return; - } + fBoostWeight = boostWeight; // used ONLY for the monitoring tree - Float_t w; - Double_t sumAll=0, sumWrong=0; + return boostWeight; +} - // finding the MVA cut value for IsSignalLike, stored in the method - FindMVACut(); - // finding the wrong events and calculating their total weights +//_______________________________________________________________________ +Double_t TMVA::MethodBoost::Bagging() +{ + // Bagging or Bootstrap boosting, gives new random poisson weight for every event + TRandom3 *trandom = new TRandom3(fRandomSeed+fMethods.size()); for (Long64_t ievt=0; ievt<GetNEvents(); ievt++) { - const Event* ev = GetEvent(ievt); - w = ev->GetWeight(); - sumAll += w; - if ( DataInfo().IsSignal(ev) != method->IsSignalLike(fMVAvalues->at(ievt))) { - sumWrong += w; - } - - // if (ievt < 10) - // cout << " TYpe=" << DataInfo().IsSignal(ev) - // << " mvaValue="<<fMVAvalues->at(ievt) - // << " mvaCutVal="<<method->GetSignalReferenceCut() - // << " mvaCutValOrien="<<method->GetSignalReferenceCutOrientation() - // << " isSignallike="<<method->IsSignalLike(fMVAvalues->at(ievt)) - // << endl; + const Event* ev = Data()->GetEvent(ievt); + ev->SetBoostWeight(trandom->PoissonD(fBaggedSampleFraction)); } - - // cout << "sumWrong="<<sumWrong << " sumAll="<<sumAll<<endl; - fMethodError=sumWrong/sumAll; - - // calculating the fMethodError and the fBoostWeight out of it uses - // the formula - // w = ((1-err)/err)^beta - if (fMethodError>0 && fADABoostBeta == 1.0) { - fBoostWeight = (1.0-fMethodError)/fMethodError; - } - else if (fMethodError>0 && fADABoostBeta != 1.0) { - fBoostWeight = TMath::Power((1.0 - fMethodError)/fMethodError, fADABoostBeta); - } - else fBoostWeight = 1000; - - // sanity check to avoid log() with negative argument - if (fBoostWeight <= 0.0) fBoostWeight = 1.0; - - // calculate method weight - if (fMethodWeightType == "ByError") fMethodWeight.push_back(TMath::Log(fBoostWeight)); - else if (fMethodWeightType == "Average") fMethodWeight.push_back(1.0); - else if (fMethodWeightType == "ByROC") fMethodWeight.push_back(fROC_training); - else if (fMethodWeightType == "ByOverlap") fMethodWeight.push_back((fOverlap_integral > 0.0 ? 1.0/fOverlap_integral : 1000.0)); - else fMethodWeight.push_back(0); + fBoostWeight = 1; // used ONLY for the monitoring tree + return 1.; } + //_______________________________________________________________________ void TMVA::MethodBoost::GetHelpMessage() const { @@ -978,6 +1067,7 @@ Double_t TMVA::MethodBoost::GetMvaValue( Double_t* err, Double_t* errUpper ) { // return boosted MVA response Double_t mvaValue = 0; + Double_t norm = 0; Double_t epsilon = TMath::Exp(-1.); //Double_t fact = TMath::Exp(-1.)+TMath::Exp(1.); for (UInt_t i=0;i< fMethods.size(); i++){ @@ -1006,7 +1096,10 @@ Double_t TMVA::MethodBoost::GetMvaValue( Double_t* err, Double_t* errUpper ) Log() << kFATAL << "error unknown transformation " << fTransformString<<Endl; } mvaValue+=val*fMethodWeight[i]; + norm +=fMethodWeight[i]; + // std::cout << "mva("<<i<<") = "<<val<<" " << valx<< " " << mvaValue<<" and sigcut="<<sigcut << std::endl; } + mvaValue/=norm; // cannot determine error NoErrorCalc(err, errUpper); @@ -1057,13 +1150,11 @@ Double_t TMVA::MethodBoost::GetBoostROCIntegral(Bool_t singleMethod, Types::ETre if (!singleMethod) { // calculate sum of weights of all methods Double_t AllMethodsWeight = 0; - for (Int_t i=0; i<=fMethodIndex; i++) + for (UInt_t i=0; i<=fCurrentMethodIdx; i++) AllMethodsWeight += fMethodWeight.at(i); // normalize the weights of the classifiers - if (fMethodWeightType == "LastMethod") - fMethodWeight.back() = AllMethodsWeight = 1.0; if (AllMethodsWeight != 0.0) { - for (Int_t i=0; i<=fMethodIndex; i++) + for (UInt_t i=0; i<=fCurrentMethodIdx; i++) fMethodWeight[i] /= AllMethodsWeight; } } @@ -1171,5 +1262,89 @@ void TMVA::MethodBoost::CalcMVAValues() GetEvent(ievt); fMVAvalues->at(ievt) = method->GetMvaValue(); } + + // fill cumulative mva distribution + + +} + + +//_______________________________________________________________________ +void TMVA::MethodBoost::MonitorBoost( Types::EBoostStage stage , UInt_t methodIndex ) +{ + // fill various monitoring histograms from information of the individual classifiers that + // have been boosted. + // of course.... this depends very much on the individual classifiers, and so far, only for + // Decision Trees, this monitoring is actually implemented + + Results* results = Data()->GetResults(GetMethodName(), Types::kTraining, GetAnalysisType()); + + if (GetCurrentMethod(methodIndex)->GetMethodType() == TMVA::Types::kDT) { + TMVA::MethodDT* currentDT=dynamic_cast<TMVA::MethodDT*>(GetCurrentMethod(methodIndex)); + if (currentDT){ + if (stage == Types::kBoostProcBegin){ + results->Store(new TH1I("NodesBeforePruning","nodes before pruning",this->GetBoostNum(),0,this->GetBoostNum()),"NodesBeforePruning"); + results->Store(new TH1I("NodesAfterPruning","nodes after pruning",this->GetBoostNum(),0,this->GetBoostNum()),"NodesAfterPruning"); + } + + if (stage == Types::kBeforeTraining){ + } + else if (stage == Types::kBeforeBoosting){ + results->GetHist("NodesBeforePruning")->SetBinContent(methodIndex+1,currentDT->GetNNodesBeforePruning()); + results->GetHist("NodesAfterPruning")->SetBinContent(methodIndex+1,currentDT->GetNNodes()); + } + else if (stage == Types::kAfterBoosting){ + + } + else if (stage != Types::kBoostProcEnd){ + Log() << kINFO << "<Train> average number of nodes before/after pruning : " + << results->GetHist("NodesBeforePruning")->GetMean() << " / " + << results->GetHist("NodesAfterPruning")->GetMean() + << Endl; + } + } + + }else if (GetCurrentMethod(methodIndex)->GetMethodType() == TMVA::Types::kFisher) { + if (stage == Types::kAfterBoosting){ + TMVA::MsgLogger::EnableOutput(); + } + }else{ + if (methodIndex < 3){ + Log() << kINFO << "No detailed boost monitoring for " + << GetCurrentMethod(methodIndex)->GetMethodName() + << " yet available " << Endl; + } + } + + //boosting plots universal for all classifiers 'typically for debug purposes only as they are not general enough' + + if (stage == Types::kBeforeBoosting){ + // if you want to display the weighted events for 2D case at each boost step: + if (fDetailedMonitoring){ + // the following code is useful only for 2D examples - mainly illustration for debug/educational purposes: + if (DataInfo().GetNVariables() == 2) { + results->Store(new TH2F(Form("EventDistSig_%d",methodIndex),Form("EventDistSig_%d",methodIndex),100,0,7,100,0,7)); + results->GetHist(Form("EventDistSig_%d",methodIndex))->SetMarkerColor(4); + results->Store(new TH2F(Form("EventDistBkg_%d",methodIndex),Form("EventDistBkg_%d",methodIndex),100,0,7,100,0,7)); + results->GetHist(Form("EventDistBkg_%d",methodIndex))->SetMarkerColor(2); + + Data()->SetCurrentType(Types::kTraining); + for (Long64_t ievt=0; ievt<GetNEvents(); ievt++) { + const Event* ev = GetEvent(ievt); + Float_t w = ev->GetWeight(); + Float_t v0= ev->GetValue(0); + Float_t v1= ev->GetValue(1); + // if (ievt<3) std::cout<<ievt<<" var0="<<v0<<" var1="<<v1<<" weight="<<w<<std::endl; + TH2* h; + if (DataInfo().IsSignal(ev)) h=results->GetHist2D(Form("EventDistSig_%d",methodIndex)); + else h=results->GetHist2D(Form("EventDistBkg_%d",methodIndex)); + if (h) h->Fill(v0,v1,w); + } + } + } + } + + return; } + diff --git a/tmva/src/MethodCFMlpANN.cxx b/tmva/src/MethodCFMlpANN.cxx index 9a446d083113f..33e305fca22ba 100644 --- a/tmva/src/MethodCFMlpANN.cxx +++ b/tmva/src/MethodCFMlpANN.cxx @@ -79,6 +79,10 @@ REGISTER_METHOD(CFMlpANN) +using std::stringstream; +using std::make_pair; +using std::atoi; + ClassImp(TMVA::MethodCFMlpANN) // initialization of global variable @@ -216,7 +220,7 @@ void TMVA::MethodCFMlpANN::ProcessOptions() // Data LUT fData = new TMatrix( nEvtTrain, GetNvar() ); - fClass = new vector<Int_t>( nEvtTrain ); + fClass = new std::vector<Int_t>( nEvtTrain ); // ---- fill LUTs @@ -312,7 +316,7 @@ Double_t TMVA::MethodCFMlpANN::GetMvaValue( Double_t* err, Double_t* errUpper ) const Event* ev = GetEvent(); // copy of input variables - vector<Double_t> inputVec( GetNvar() ); + std::vector<Double_t> inputVec( GetNvar() ); for (UInt_t ivar=0; ivar<GetNvar(); ivar++) inputVec[ivar] = ev->GetValue(ivar); Double_t myMVA = EvalANN( inputVec, isOK ); @@ -325,7 +329,7 @@ Double_t TMVA::MethodCFMlpANN::GetMvaValue( Double_t* err, Double_t* errUpper ) } //_______________________________________________________________________ -Double_t TMVA::MethodCFMlpANN::EvalANN( vector<Double_t>& inVar, Bool_t& isOK ) +Double_t TMVA::MethodCFMlpANN::EvalANN( std::vector<Double_t>& inVar, Bool_t& isOK ) { // evaluates NN value as function of input variables @@ -394,7 +398,7 @@ Double_t TMVA::MethodCFMlpANN::NN_fonc( Int_t i, Double_t u ) const } //_______________________________________________________________________ -void TMVA::MethodCFMlpANN::ReadWeightsFromStream( istream & istr ) +void TMVA::MethodCFMlpANN::ReadWeightsFromStream( std::istream & istr ) { // read back the weight from the training from file (stream) TString var; @@ -568,7 +572,7 @@ void TMVA::MethodCFMlpANN::ReadWeightsFromXML( void* wghtnode ) gTools().ReadAttr( wghtnode, "NLayers",fParam_1.layerm ); void* minmaxnode = gTools().GetChild(wghtnode); const char* minmaxcontent = gTools().GetContent(minmaxnode); - std::stringstream content(minmaxcontent); + stringstream content(minmaxcontent); for (UInt_t ivar=0; ivar<GetNvar(); ivar++) content >> fVarn_1.xmin[ivar] >> fVarn_1.xmax[ivar]; if (fYNN != 0) { @@ -615,21 +619,21 @@ void TMVA::MethodCFMlpANN::PrintWeights( std::ostream & o ) const // write the weights of the neural net // write number of variables and classes - o << "Number of vars " << fParam_1.nvar << endl; - o << "Output nodes " << fParam_1.lclass << endl; + o << "Number of vars " << fParam_1.nvar << std::endl; + o << "Output nodes " << fParam_1.lclass << std::endl; // write extrema of input variables for (Int_t ivar=0; ivar<fParam_1.nvar; ivar++) - o << "Var " << ivar << " [" << fVarn_1.xmin[ivar] << " - " << fVarn_1.xmax[ivar] << "]" << endl; + o << "Var " << ivar << " [" << fVarn_1.xmin[ivar] << " - " << fVarn_1.xmax[ivar] << "]" << std::endl; // write number of layers (sum of: input + output + hidden) - o << "Number of layers " << fParam_1.layerm << endl; + o << "Number of layers " << fParam_1.layerm << std::endl; o << "Nodes per layer "; for (Int_t layer=0; layer<fParam_1.layerm; layer++) // write number of neurons for each layer o << fNeur_1.neuron[layer] << " "; - o << endl; + o << std::endl; // write weights for (Int_t layer=1; layer<=fParam_1.layerm-1; layer++) { @@ -652,22 +656,22 @@ void TMVA::MethodCFMlpANN::PrintWeights( std::ostream & o ) const o << Ww_ref(fNeur_1.ww, layer+1, j) << " "; } - o << endl; + o << std::endl; //for (i=1; i<=fNeur_1.neuron[layer-1]; i++) { for (i=1; i<=fNeur_1.neuron[layer-1]; i++) { for (j=jmin; j<=jmax; j++) { // o << fNeur_1.w[(i*max_nNodes_ + j)*max_nLayers_ + layer - 186] << " "; o << W_ref(fNeur_1.w, layer+1, j, i) << " "; } - o << endl; + o << std::endl; } // skip two empty lines - o << endl; + o << std::endl; } } for (Int_t layer=0; layer<fParam_1.layerm; layer++) { - o << "Del.temp in layer " << layer << " : " << fDel_1.temp[layer] << endl; + o << "Del.temp in layer " << layer << " : " << fDel_1.temp[layer] << std::endl; } } //_______________________________________________________________________ @@ -679,8 +683,8 @@ TMVA::MethodCFMlpANN* TMVA::MethodCFMlpANN::This( void ) void TMVA::MethodCFMlpANN::MakeClassSpecific( std::ostream& fout, const TString& className ) const { // write specific classifier response - fout << " // not implemented for class: \"" << className << "\"" << endl; - fout << "};" << endl; + fout << " // not implemented for class: \"" << className << "\"" << std::endl; + fout << "};" << std::endl; } //_______________________________________________________________________ diff --git a/tmva/src/MethodCategory.cxx b/tmva/src/MethodCategory.cxx index 2471927c499a3..cafad965b8a02 100644 --- a/tmva/src/MethodCategory.cxx +++ b/tmva/src/MethodCategory.cxx @@ -301,6 +301,7 @@ TMVA::DataSetInfo& TMVA::MethodCategory::CreateCategoryDSI(const TCut& theCut, dsi->SetNormalization(norm); DataSetInfo& dsiReference= (*dsi); + return dsiReference; } @@ -406,6 +407,10 @@ void TMVA::MethodCategory::Train() << " not trained (training tree has less entries [" << mva->Data()->GetNTrainingEvents() << "] than required [" << MinNoTrainingEvents << "]" << Endl; + + Log() << kERROR << " w/o training/test events for that category, I better stop here and let you fix " << Endl; + Log() << kFATAL << "that one first, otherwise things get too messy later ... " << Endl; + } } @@ -554,6 +559,9 @@ const TMVA::Ranking* TMVA::MethodCategory::CreateRanking() Bool_t TMVA::MethodCategory::PassesCut( const Event* ev, UInt_t methodIdx ) { + // if it's not a simple 'spectator' variable (0 or 1) that the categories are defined by + // (but rather some 'formula' (i.e. eta>0), then this formulas are stored in fCatTree and that + // one will be evaluated.. (the formulae return 'true' or 'false' if (fCatTree) { if (methodIdx>=fCatFormulas.size()) { Log() << kFATAL << "Large method index " << methodIdx << ", number of category formulas = " @@ -562,6 +570,7 @@ Bool_t TMVA::MethodCategory::PassesCut( const Event* ev, UInt_t methodIdx ) TTreeFormula* f = fCatFormulas[methodIdx]; return f->EvalInstance(0) > 0.5; } + // otherwise, it simply looks if "variable == true" ("greater 0.5 to be "sure" ) else { // checks whether an event lies within a cut diff --git a/tmva/src/MethodCommittee.cxx b/tmva/src/MethodCommittee.cxx deleted file mode 100644 index fb3d437c47451..0000000000000 --- a/tmva/src/MethodCommittee.cxx +++ /dev/null @@ -1,540 +0,0 @@ -// @(#)root/tmva $Id$ -// Author: Andreas Hoecker, Joerg Stelzer, Helge Voss - -/********************************************************************************** - * Project: TMVA - a Root-integrated toolkit for multivariate data analysis * - * Package: TMVA * - * Class : MethodCommittee * - * Web : http://tmva.sourceforge.net * - * * - * Description: * - * Implementation * - * * - * Authors (alphabetical): * - * Andreas Hoecker <Andreas.Hocker@cern.ch> - CERN, Switzerland * - * Joerg Stelzer <Joerg.Stelzer@cern.ch> - CERN, Switzerland * - * Helge Voss <Helge.Voss@cern.ch> - MPI-K Heidelberg, Germany * - * * - * Copyright (c) 2005: * - * CERN, Switzerland * - * U. of Victoria, Canada * - * MPI-K Heidelberg, Germany * - * LAPP, Annecy, France * - * * - * Redistribution and use in source and binary forms, with or without * - * modification, are permitted according to the terms listed in LICENSE * - * (http://tmva.sourceforge.net/LICENSE) * - **********************************************************************************/ - -//_______________________________________________________________________ -// -// Boosting: -// -// the idea behind the boosting is, that signal events from the training -// sample, that end up in a background node (and vice versa) are given a -// larger weight than events that are in the correct leave node. This -// results in a re-weighed training event sample, with which then a new -// decision tree can be developed. The boosting can be applied several -// times (typically 100-500 times) and one ends up with a set of decision -// trees (a forest). -// -// Bagging: -// -// In this particular variant of the Boosted Decision Trees the boosting -// is not done on the basis of previous training results, but by a simple -// stochasitc re-sampling of the initial training event sample. -//_______________________________________________________________________ - -#include "TMVA/ClassifierFactory.h" -#include "TMVA/MethodCommittee.h" -#include "TMVA/Tools.h" -#include "TMVA/Timer.h" -#include "Riostream.h" -#include "TMath.h" -#include "TRandom3.h" -#include <algorithm> -#include "TObjString.h" -#include "TDirectory.h" -#include "TMVA/Ranking.h" -#include "TMVA/IMethod.h" - -using std::vector; - -REGISTER_METHOD(Committee) - -ClassImp(TMVA::MethodCommittee) - -//_______________________________________________________________________ -TMVA::MethodCommittee::MethodCommittee( const TString& jobName, - const TString& methodTitle, - DataSetInfo& dsi, - const TString& theOption, - TDirectory* theTargetDir ) : - TMVA::MethodBase( jobName, Types::kCommittee, methodTitle, dsi, theOption, theTargetDir ), - fNMembers(100), - fBoostType("AdaBoost"), - fMemberType(Types::kMaxMethod), - fUseMemberDecision(kFALSE), - fUseWeightedMembers(kFALSE), - fITree(0), - fBoostFactor(0), - fErrorFraction(0), - fNnodes(0) -{ - // constructor -} - -//_______________________________________________________________________ -TMVA::MethodCommittee::MethodCommittee( DataSetInfo& theData, - const TString& theWeightFile, - TDirectory* theTargetDir ) : - TMVA::MethodBase( Types::kCommittee, theData, theWeightFile, theTargetDir ), - fNMembers(100), - fBoostType("AdaBoost"), - fMemberType(Types::kMaxMethod), - fUseMemberDecision(kFALSE), - fUseWeightedMembers(kFALSE), - fITree(0), - fBoostFactor(0), - fErrorFraction(0), - fNnodes(0) -{ - // constructor for calculating Committee-MVA using previously generatad decision trees - // the result of the previous training (the decision trees) are read in via the - // weightfile. Make sure the "theVariables" correspond to the ones used in - // creating the "weight"-file -} - -//_______________________________________________________________________ -Bool_t TMVA::MethodCommittee::HasAnalysisType( Types::EAnalysisType type, UInt_t numberClasses, UInt_t numberTargets ) -{ - // FDA can handle classification with 2 classes and regression with one regression-target - if( type == Types::kClassification && numberClasses == 2 ) return kTRUE; - if( type == Types::kRegression && numberTargets == 1 ) return kTRUE; - return kFALSE; -} - -//_______________________________________________________________________ -void TMVA::MethodCommittee::DeclareOptions() -{ - // define the options (their key words) that can be set in the option string - // know options: - // NMembers <string> number of members in the committee - // UseMemberDecision <bool> use signal information from event (otherwise assume signal) - // UseWeightedMembers <bool> use weighted trees or simple average in classification from the forest - // - // BoostType <string> boosting type - // available values are: AdaBoost <default> - // Bagging - - DeclareOptionRef(fNMembers, "NMembers", "number of members in the committee"); - DeclareOptionRef(fUseMemberDecision=kFALSE, "UseMemberDecision", "use binary information from IsSignal"); - DeclareOptionRef(fUseWeightedMembers=kTRUE, "UseWeightedMembers", "use weighted trees or simple average in classification from the forest"); - - DeclareOptionRef(fBoostType, "BoostType", "boosting type"); - AddPreDefVal(TString("AdaBoost")); - AddPreDefVal(TString("Bagging")); -} - -//_______________________________________________________________________ -void TMVA::MethodCommittee::ProcessOptions() -{ - // process user options - - // book monitoring histograms (currently for AdaBost, only) - fBoostFactorHist = new TH1F("fBoostFactor","Ada Boost weights",100,1,100); - fErrFractHist = new TH2F("fErrFractHist","error fraction vs tree number", - fNMembers,0,fNMembers,50,0,0.5); - fMonitorNtuple = new TTree("fMonitorNtuple","Committee variables"); - fMonitorNtuple->Branch("iTree",&fITree,"iTree/I"); - fMonitorNtuple->Branch("boostFactor",&fBoostFactor,"boostFactor/D"); - fMonitorNtuple->Branch("errorFraction",&fErrorFraction,"errorFraction/D"); -} - -//_______________________________________________________________________ -void TMVA::MethodCommittee::Init( void ) -{ - // common initialisation with defaults for the Committee-Method - - fNMembers = 100; - fBoostType = "AdaBoost"; - - fCommittee.clear(); - fBoostWeights.clear(); -} - -//_______________________________________________________________________ -TMVA::MethodCommittee::~MethodCommittee( void ) -{ - //destructor - for (UInt_t i=0; i<GetCommittee().size(); i++) delete fCommittee[i]; - fCommittee.clear(); -} - -//_______________________________________________________________________ -void TMVA::MethodCommittee::WriteStateToFile() const -{ - // Function to write options and weights to file - - // get the filename - TString fname(GetWeightFileName()); - Log() << kINFO << "creating weight file: " << fname << Endl; - - std::ofstream* fout = new std::ofstream( fname ); - if (!fout->good()) { // file not found --> Error - Log() << kFATAL << "<WriteStateToFile> " - << "unable to open output weight file: " << fname << endl; - } - - WriteStateToStream( *fout ); -} - - -//_______________________________________________________________________ -void TMVA::MethodCommittee::Train( void ) -{ - // training - - Log() << kINFO << "will train "<< fNMembers << " committee members ... patience please" << Endl; - - Timer timer( fNMembers, GetName() ); - for (UInt_t imember=0; imember<fNMembers; imember++){ - timer.DrawProgressBar( imember ); - - IMethod* method = ClassifierFactory::Instance().Create(std::string(Types::Instance().GetMethodName( fMemberType )), - GetJobName(), - GetMethodName(), - DataInfo(), - fMemberOption ); - - - - // train each of the member methods - method->Train(); - - GetBoostWeights().push_back( this->Boost( dynamic_cast<MethodBase*>(method), imember ) ); - - GetCommittee().push_back( method ); - - fMonitorNtuple->Fill(); - } - - // get elapsed time - Log() << kINFO << "elapsed time: " << timer.GetElapsedTime() - << " " << Endl; -} - -//_______________________________________________________________________ -Double_t TMVA::MethodCommittee::Boost( TMVA::MethodBase* method, UInt_t imember ) -{ - // apply the boosting alogrithim (the algorithm is selecte via the the "option" given - // in the constructor. The return value is the boosting weight - if(!method) - return 0; - - if (fBoostType=="AdaBoost") return this->AdaBoost( method ); - else if (fBoostType=="Bagging") return this->Bagging( imember ); - else { - Log() << kINFO << GetOptions() << Endl; - Log() << kFATAL << "<Boost> unknown boost option called" << Endl; - } - return 1.0; -} - -//_______________________________________________________________________ -Double_t TMVA::MethodCommittee::AdaBoost( TMVA::MethodBase* method ) -{ - // the AdaBoost implementation. - // a new training sample is generated by weighting - // events that are misclassified by the decision tree. The weight - // applied is w = (1-err)/err or more general: - // w = ((1-err)/err)^beta - // where err is the fracthin of misclassified events in the tree ( <0.5 assuming - // demanding the that previous selection was better than random guessing) - // and "beta" beeing a free parameter (standard: beta = 1) that modifies the - // boosting. - - Double_t adaBoostBeta = 1.; // that's apparently the standard value :) - - // should never be called without existing trainingTree - if (Data()->GetNTrainingEvents()) Log() << kFATAL << "<AdaBoost> Data().TrainingTree() is zero pointer" << Endl; - - Double_t err=0, sumw=0, sumwfalse=0, count=0; - vector<Char_t> correctSelected; - - // loop over all events in training tree - MethodBase* mbase = (MethodBase*)method; - for (Int_t ievt=0; ievt<Data()->GetNTrainingEvents(); ievt++) { - - Event* ev = Data()->GetEvent(ievt); - - // total sum of event weights - sumw += ev->GetBoostWeight(); - - // decide whether it is signal or background-like - Bool_t isSignalType = mbase->IsSignalLike(); - - // to prevent code duplication - if (isSignalType == DataInfo().IsSignal(ev)) - correctSelected.push_back( kTRUE ); - else { - sumwfalse += ev->GetBoostWeight(); - count += 1; - correctSelected.push_back( kFALSE ); - } - } - - if (0 == sumw) { - Log() << kFATAL << "<AdaBoost> fatal error sum of event boostweights is zero" << Endl; - } - - // compute the boost factor - err = sumwfalse/sumw; - - Double_t newSumw=0; - Int_t i=0; - Double_t boostFactor = 1; - if (err>0){ - if (adaBoostBeta == 1){ - boostFactor = (1-err)/err ; - } - else { - boostFactor = TMath::Power((1-err)/err,adaBoostBeta) ; - } - } - else { - boostFactor = 1000; // default - } - - // now fill new boostweights - for (Int_t ievt=0; ievt<Data()->GetNTrainingEvents(); ievt++) { - - Event *ev = Data()->GetEvent(ievt); - - // read the Training Event into "event" - if (!correctSelected[ievt]) ev->SetBoostWeight( ev->GetBoostWeight() * boostFactor); - - newSumw += ev->GetBoostWeight(); - i++; - } - - // re-normalise the boostweights - for (Int_t ievt=0; ievt<Data()->GetNTrainingEvents(); ievt++) { - Event *ev = Data()->GetEvent(ievt); - ev->SetBoostWeight( ev->GetBoostWeight() * sumw / newSumw ); - } - - fBoostFactorHist->Fill(boostFactor); - fErrFractHist->Fill(GetCommittee().size(),err); - - // save for ntuple - fBoostFactor = boostFactor; - fErrorFraction = err; - - // return weight factor for this committee member - return TMath::Log(boostFactor); -} - -//_______________________________________________________________________ -Double_t TMVA::MethodCommittee::Bagging( UInt_t imember ) -{ - // call it Bootstrapping, re-sampling or whatever you like, in the end it is nothing - // else but applying "random boostweights" to each event. - Double_t newSumw = 0; - TRandom3* trandom = new TRandom3( imember ); - - // loop over all events in training tree - for (Int_t ievt=0; ievt<Data()->GetNTrainingEvents(); ievt++) { - Event* ev = Data()->GetEvent(ievt); - - // read the Training Event into "event" - Double_t newWeight = trandom->Rndm(); - ev->SetBoostWeight( newWeight ); - newSumw += newWeight; - } - - // re-normalise the boostweights - for (Int_t ievt=0; ievt<Data()->GetNTrainingEvents(); ievt++) { - Event* ev = Data()->GetEvent(ievt); - ev->SetBoostWeight( ev->GetBoostWeight() * Data()->GetNTrainingEvents() / newSumw ); - } - - delete trandom; - // return weight factor for this committee member - return 1.0; // here as there are random weights for each event, just return a constant==1; -} - -//_______________________________________________________________________ -void TMVA::MethodCommittee::AddWeightsXMLTo( void* /*parent*/ ) const { - Log() << kFATAL << "Please implement writing of weights as XML" << Endl; -} - -//_______________________________________________________________________ -void TMVA::MethodCommittee::ReadWeightsFromStream( istream& istr ) -{ - // read the state of the method from an input stream - - // explicitly destroy objects in vector - std::vector<IMethod*>::iterator member = GetCommittee().begin(); - for (; member != GetCommittee().end(); member++) delete *member; - - GetCommittee().clear(); - GetBoostWeights().clear(); - - TString dummy; - UInt_t imember; - Double_t boostWeight; - - DataSetInfo & dsi = DataInfo(); // this needs to be changed for the different kind of committee methods - - // loop over all members in committee - for (UInt_t i=0; i<fNMembers; i++) { - - istr >> dummy >> dummy >> dummy >> imember; - istr >> dummy >> dummy >> boostWeight; - - if (imember != i) { - Log() << kFATAL << "<ReadWeightsFromStream> fatal error while reading Weight file \n " - << ": mismatch imember: " << imember << " != i: " << i << Endl; - } - - // initialize methods - IMethod* method = ClassifierFactory::Instance().Create(std::string(Types::Instance().GetMethodName( fMemberType )), dsi, "" ); - - // read weight file - MethodBase* m = dynamic_cast<MethodBase*>(method); - if(m) - m->ReadStateFromStream(istr); - GetCommittee().push_back(method); - GetBoostWeights().push_back(boostWeight); - } -} - -//_______________________________________________________________________ -Double_t TMVA::MethodCommittee::GetMvaValue( Double_t* err, Double_t* errUpper ) -{ - // return the MVA value (range [-1;1]) that classifies the - // event.according to the majority vote from the total number of - // decision trees - // In the literature I found that people actually use the - // weighted majority vote (using the boost weights) .. However I - // did not see any improvement in doing so :( - // --> this is currently switched off - - // cannot determine error - NoErrorCalc(err, errUpper); - - Double_t myMVA = 0; - Double_t norm = 0; - for (UInt_t itree=0; itree<GetCommittee().size(); itree++) { - - MethodBase* m = dynamic_cast<MethodBase*>(GetCommittee()[itree]); - if(m==0) continue; - - Double_t tmpMVA = ( fUseMemberDecision ? ( m->IsSignalLike() ? 1.0 : -1.0 ) - : GetCommittee()[itree]->GetMvaValue() ); - - if (fUseWeightedMembers){ - myMVA += GetBoostWeights()[itree] * tmpMVA; - norm += GetBoostWeights()[itree]; - } - else { - myMVA += tmpMVA; - norm += 1; - } - } - return (norm != 0) ? myMVA /= Double_t(norm) : -999; -} - -//_______________________________________________________________________ -void TMVA::MethodCommittee::WriteMonitoringHistosToFile( void ) const -{ - // here we could write some histograms created during the processing - // to the output file. - Log() << kINFO << "Write monitoring histograms to file: " << BaseDir()->GetPath() << Endl; - - fBoostFactorHist->Write(); - fErrFractHist->Write(); - fMonitorNtuple->Write(); - - BaseDir()->cd(); -} - -// return the individual relative variable importance -//_______________________________________________________________________ -vector< Double_t > TMVA::MethodCommittee::GetVariableImportance() -{ - // return the relative variable importance, normalized to all - // variables together having the importance 1. The importance in - // evaluated as the total separation-gain that this variable had in - // the decision trees (weighted by the number of events) - - fVariableImportance.resize(GetNvar()); - // Double_t sum=0; - // for (int itree = 0; itree < fNMembers; itree++){ - // vector<Double_t> relativeImportance(GetCommittee()[itree]->GetVariableImportance()); - // for (unsigned int i=0; i< relativeImportance.size(); i++) { - // fVariableImportance[i] += relativeImportance[i] ; - // } - // } - // for (unsigned int i=0; i< fVariableImportance.size(); i++) sum += fVariableImportance[i]; - // for (unsigned int i=0; i< fVariableImportance.size(); i++) fVariableImportance[i] /= sum; - - return fVariableImportance; -} - -//_______________________________________________________________________ -Double_t TMVA::MethodCommittee::GetVariableImportance(UInt_t ivar) -{ - // return the variable importance - vector<Double_t> relativeImportance = this->GetVariableImportance(); - if (ivar < (UInt_t)relativeImportance.size()) return relativeImportance[ivar]; - else Log() << kFATAL << "<GetVariableImportance> ivar = " << ivar << " is out of range " << Endl; - - return -1; -} - -//_______________________________________________________________________ -const TMVA::Ranking* TMVA::MethodCommittee::CreateRanking() -{ - // computes ranking of input variables - - // create the ranking object - fRanking = new Ranking( GetName(), "Variable Importance" ); - vector< Double_t> importance(this->GetVariableImportance()); - - for (UInt_t ivar=0; ivar<GetNvar(); ivar++) { - fRanking->AddRank( Rank( GetInputLabel(ivar), importance[ivar] ) ); - } - - return fRanking; -} - -//_______________________________________________________________________ -void TMVA::MethodCommittee::MakeClassSpecific( std::ostream& fout, const TString& className ) const -{ - // write specific classifier response - fout << " // not implemented for class: \"" << className << "\"" << endl; - fout << "};" << endl; -} - -//_______________________________________________________________________ -void TMVA::MethodCommittee::GetHelpMessage() const -{ - // get help message text - // - // typical length of text line: - // "|--------------------------------------------------------------|" - Log() << Endl; - Log() << gTools().Color("bold") << "--- Short description:" << gTools().Color("reset") << Endl; - Log() << Endl; - Log() << "<None>" << Endl; - Log() << Endl; - Log() << gTools().Color("bold") << "--- Performance optimisation:" << gTools().Color("reset") << Endl; - Log() << Endl; - Log() << "<None>" << Endl; - Log() << Endl; - Log() << gTools().Color("bold") << "--- Performance tuning via configuration options:" << gTools().Color("reset") << Endl; - Log() << Endl; - Log() << "<None>" << Endl; -} diff --git a/tmva/src/MethodCompositeBase.cxx b/tmva/src/MethodCompositeBase.cxx index e851631e76faf..62a7eb1fe585e 100644 --- a/tmva/src/MethodCompositeBase.cxx +++ b/tmva/src/MethodCompositeBase.cxx @@ -65,7 +65,7 @@ TMVA::MethodCompositeBase::MethodCompositeBase( const TString& jobName, const TString& theOption, TDirectory* theTargetDir ) : TMVA::MethodBase( jobName, methodType, methodTitle, theData, theOption, theTargetDir ), - fMethodIndex(0) + fCurrentMethodIdx(0), fCurrentMethod(0) {} //_______________________________________________________________________ @@ -74,15 +74,15 @@ TMVA::MethodCompositeBase::MethodCompositeBase( Types::EMVA methodType, const TString& weightFile, TDirectory* theTargetDir ) : TMVA::MethodBase( methodType, dsi, weightFile, theTargetDir ), - fMethodIndex(0) + fCurrentMethodIdx(0), fCurrentMethod(0) {} //_______________________________________________________________________ TMVA::IMethod* TMVA::MethodCompositeBase::GetMethod( const TString &methodTitle ) const { // returns pointer to MVA that corresponds to given method title - vector<IMethod*>::const_iterator itrMethod = fMethods.begin(); - vector<IMethod*>::const_iterator itrMethodEnd = fMethods.end(); + std::vector<IMethod*>::const_iterator itrMethod = fMethods.begin(); + std::vector<IMethod*>::const_iterator itrMethodEnd = fMethods.end(); for (; itrMethod != itrMethodEnd; itrMethod++) { MethodBase* mva = dynamic_cast<MethodBase*>(*itrMethod); @@ -95,7 +95,7 @@ TMVA::IMethod* TMVA::MethodCompositeBase::GetMethod( const TString &methodTitle TMVA::IMethod* TMVA::MethodCompositeBase::GetMethod( const Int_t index ) const { // returns pointer to MVA that corresponds to given method index - vector<IMethod*>::const_iterator itrMethod = fMethods.begin()+index; + std::vector<IMethod*>::const_iterator itrMethod = fMethods.begin()+index; if (itrMethod<fMethods.end()) return *itrMethod; else return 0; } @@ -130,7 +130,7 @@ void TMVA::MethodCompositeBase::AddWeightsXMLTo( void* parent ) const TMVA::MethodCompositeBase::~MethodCompositeBase( void ) { // delete methods - vector<IMethod*>::iterator itrMethod = fMethods.begin(); + std::vector<IMethod*>::iterator itrMethod = fMethods.begin(); for (; itrMethod != fMethods.end(); itrMethod++) { Log() << kVERBOSE << "Delete method: " << (*itrMethod)->GetName() << Endl; delete (*itrMethod); @@ -206,7 +206,7 @@ void TMVA::MethodCompositeBase::ReadWeightsFromXML( void* wghtnode ) } //_______________________________________________________________________ -void TMVA::MethodCompositeBase::ReadWeightsFromStream( istream& istr ) +void TMVA::MethodCompositeBase::ReadWeightsFromStream( std::istream& istr ) { // text streamer TString var, dummy; @@ -221,10 +221,10 @@ void TMVA::MethodCompositeBase::ReadWeightsFromStream( istream& istr ) fMethods.clear(); fMethodWeight.clear(); for (UInt_t i=0; i<methodNum; i++) { - istr >> dummy >> methodName >> dummy >> fMethodIndex >> dummy >> methodWeight; - if ((UInt_t)fMethodIndex != i) { + istr >> dummy >> methodName >> dummy >> fCurrentMethodIdx >> dummy >> methodWeight; + if ((UInt_t)fCurrentMethodIdx != i) { Log() << kFATAL << "Error while reading weight file; mismatch MethodIndex=" - << fMethodIndex << " i=" << i + << fCurrentMethodIdx << " i=" << i << " MethodName " << methodName << " dummy " << dummy << " MethodWeight= " << methodWeight @@ -237,7 +237,7 @@ void TMVA::MethodCompositeBase::ReadWeightsFromStream( istream& istr ) if (GetMethodType() == Types::kBoost) ((TMVA::MethodBoost*)this)->BookMethod( Types::Instance().GetMethodType( methodName), methodTitle, optionString ); } - else methodTitle=Form("%s (%04i)",GetMethodName().Data(),fMethodIndex); + else methodTitle=Form("%s (%04i)",GetMethodName().Data(),fCurrentMethodIdx); fMethods.push_back(ClassifierFactory::Instance().Create( std::string(methodName), jobName, methodTitle,DataInfo(), optionString) ); fMethodWeight.push_back( methodWeight ); diff --git a/tmva/src/MethodCuts.cxx b/tmva/src/MethodCuts.cxx index dab8b51517921..f5303cadd59a7 100644 --- a/tmva/src/MethodCuts.cxx +++ b/tmva/src/MethodCuts.cxx @@ -114,6 +114,8 @@ End_Html */ #include "TMVA/VariableTransformBase.h" #include "TMVA/Results.h" +using std::atof; + REGISTER_METHOD(Cuts) ClassImp(TMVA::MethodCuts) @@ -222,16 +224,16 @@ void TMVA::MethodCuts::Init( void ) // vector with fit results fNpar = 2*GetNvar(); - fRangeSign = new vector<Int_t> ( GetNvar() ); + fRangeSign = new std::vector<Int_t> ( GetNvar() ); for (UInt_t ivar=0; ivar<GetNvar(); ivar++) (*fRangeSign)[ivar] = +1; - fMeanS = new vector<Double_t>( GetNvar() ); - fMeanB = new vector<Double_t>( GetNvar() ); - fRmsS = new vector<Double_t>( GetNvar() ); - fRmsB = new vector<Double_t>( GetNvar() ); + fMeanS = new std::vector<Double_t>( GetNvar() ); + fMeanB = new std::vector<Double_t>( GetNvar() ); + fRmsS = new std::vector<Double_t>( GetNvar() ); + fRmsB = new std::vector<Double_t>( GetNvar() ); // get the variable specific options, first initialize default - fFitParams = new vector<EFitParameters>( GetNvar() ); + fFitParams = new std::vector<EFitParameters>( GetNvar() ); for (UInt_t ivar=0; ivar<GetNvar(); ivar++) (*fFitParams)[ivar] = kNotEnforced; fFitMethod = kUseMonteCarlo; @@ -505,12 +507,12 @@ void TMVA::MethodCuts::PrintCuts( Double_t effS ) const Log() << Endl; for (UInt_t ivar=0; ivar<cutsMin.size(); ivar++) { Log() << kINFO - << "Cut[" << setw(2) << ivar << "]: " - << setw(10) << cutsMin[ivar] + << "Cut[" << std::setw(2) << ivar << "]: " + << std::setw(10) << cutsMin[ivar] << " < " - << setw(maxL) << (*varVec)[ivar] + << std::setw(maxL) << (*varVec)[ivar] << " <= " - << setw(10) << cutsMax[ivar] << Endl; + << std::setw(10) << cutsMax[ivar] << Endl; } for (UInt_t i=0; i<maxLine; i++) Log() << "-"; Log() << Endl; @@ -606,7 +608,7 @@ void TMVA::MethodCuts::Train( void ) else if (xmax < fCutRange[ivar]->GetMax()) fCutRange[ivar]->SetMax( xmax ); } - vector<TH1F*> signalDist, bkgDist; + std::vector<TH1F*> signalDist, bkgDist; // this is important: reset the branch addresses of the training tree to the current event delete fEffBvsSLocal; @@ -624,7 +626,7 @@ void TMVA::MethodCuts::Train( void ) fFitMethod == kUseSimulatedAnnealing) { // ranges - vector<Interval*> ranges; + std::vector<Interval*> ranges; for (UInt_t ivar=0; ivar<GetNvar(); ivar++) { @@ -1072,12 +1074,12 @@ void TMVA::MethodCuts::CreateVariablePDFs( void ) // for PDF method: create efficiency reference histograms and PDFs // create list of histograms and PDFs - fVarHistS = new vector<TH1*>( GetNvar() ); - fVarHistB = new vector<TH1*>( GetNvar() ); - fVarHistS_smooth = new vector<TH1*>( GetNvar() ); - fVarHistB_smooth = new vector<TH1*>( GetNvar() ); - fVarPdfS = new vector<PDF*>( GetNvar() ); - fVarPdfB = new vector<PDF*>( GetNvar() ); + fVarHistS = new std::vector<TH1*>( GetNvar() ); + fVarHistB = new std::vector<TH1*>( GetNvar() ); + fVarHistS_smooth = new std::vector<TH1*>( GetNvar() ); + fVarHistB_smooth = new std::vector<TH1*>( GetNvar() ); + fVarPdfS = new std::vector<PDF*>( GetNvar() ); + fVarPdfB = new std::vector<PDF*>( GetNvar() ); Int_t nsmooth = 0; @@ -1178,7 +1180,7 @@ void TMVA::MethodCuts::CreateVariablePDFs( void ) } //_______________________________________________________________________ -void TMVA::MethodCuts::ReadWeightsFromStream( istream& istr ) +void TMVA::MethodCuts::ReadWeightsFromStream( std::istream& istr ) { // read the cuts from stream TString dummy; @@ -1668,8 +1670,8 @@ Double_t TMVA::MethodCuts::GetEfficiency( const TString& theString, Types::ETree void TMVA::MethodCuts::MakeClassSpecific( std::ostream& fout, const TString& className ) const { // write specific classifier response - fout << " // not implemented for class: \"" << className << "\"" << endl; - fout << "};" << endl; + fout << " // not implemented for class: \"" << className << "\"" << std::endl; + fout << "};" << std::endl; } //_______________________________________________________________________ diff --git a/tmva/src/MethodDT.cxx b/tmva/src/MethodDT.cxx index 133dd66204f6b..d6c19c1f8a043 100644 --- a/tmva/src/MethodDT.cxx +++ b/tmva/src/MethodDT.cxx @@ -122,11 +122,11 @@ TMVA::MethodDT::MethodDT( const TString& jobName, TDirectory* theTargetDir ) : TMVA::MethodBase( jobName, Types::kDT, methodTitle, theData, theOption, theTargetDir ) , fTree(0) - , fNodeMinEvents(0) + , fMinNodeEvents(0) + , fMinNodeSize(0) , fNCuts(0) , fUseYesNoLeaf(kFALSE) , fNodePurityLimit(0) - , fNNodesMax(0) , fMaxDepth(0) , fErrorFraction(0) , fPruneStrength(0) @@ -134,7 +134,7 @@ TMVA::MethodDT::MethodDT( const TString& jobName, , fAutomatic(kFALSE) , fRandomisedTrees(kFALSE) , fUseNvars(0) - , fPruneBeforeBoost(kFALSE) + , fUsePoissonNvars(0) // don't use this initialisation, only here to make Coverity happy. Is set in Init() , fDeltaPruneStrength(0) { // the standard constructor for just an ordinar "decision trees" @@ -146,11 +146,11 @@ TMVA::MethodDT::MethodDT( DataSetInfo& dsi, TDirectory* theTargetDir ) : TMVA::MethodBase( Types::kDT, dsi, theWeightFile, theTargetDir ) , fTree(0) - , fNodeMinEvents(0) + , fMinNodeEvents(0) + , fMinNodeSize(0) , fNCuts(0) , fUseYesNoLeaf(kFALSE) , fNodePurityLimit(0) - , fNNodesMax(0) , fMaxDepth(0) , fErrorFraction(0) , fPruneStrength(0) @@ -158,7 +158,6 @@ TMVA::MethodDT::MethodDT( DataSetInfo& dsi, , fAutomatic(kFALSE) , fRandomisedTrees(kFALSE) , fUseNvars(0) - , fPruneBeforeBoost(kFALSE) , fDeltaPruneStrength(0) { //constructor from Reader @@ -199,26 +198,25 @@ void TMVA::MethodDT::DeclareOptions() DeclareOptionRef(fRandomisedTrees,"UseRandomisedTrees","Choose at each node splitting a random set of variables and *bagging*"); DeclareOptionRef(fUseNvars,"UseNvars","Number of variables used if randomised Tree option is chosen"); + DeclareOptionRef(fUsePoissonNvars,"UsePoissonNvars", "Interpret \"UseNvars\" not as fixed number but as mean of a Possion distribution in each split with RandomisedTree option"); DeclareOptionRef(fUseYesNoLeaf=kTRUE, "UseYesNoLeaf", "Use Sig or Bkg node type or the ratio S/B as classification in the leaf node"); DeclareOptionRef(fNodePurityLimit=0.5, "NodePurityLimit", "In boosting/pruning, nodes with purity > NodePurityLimit are signal; background otherwise."); - DeclareOptionRef(fPruneBeforeBoost=kFALSE, "PruneBeforeBoost", - "Whether to perform the prune process right after the training or after the boosting"); DeclareOptionRef(fSepTypeS="GiniIndex", "SeparationType", "Separation criterion for node splitting"); AddPreDefVal(TString("MisClassificationError")); AddPreDefVal(TString("GiniIndex")); AddPreDefVal(TString("CrossEntropy")); AddPreDefVal(TString("SDivSqrtSPlusB")); - DeclareOptionRef(fNodeMinEvents, "nEventsMin", "Minimum number of events in a leaf node (default: max(20, N_train/(Nvar^2)/10) ) "); + DeclareOptionRef(fMinNodeEvents=-1, "nEventsMin", "deprecated !!! Minimum number of events required in a leaf node"); + DeclareOptionRef(fMinNodeSizeS, "MinNodeSize", "Minimum percentage of training events required in a leaf node (default: Classification: 10%, Regression: 1%)"); DeclareOptionRef(fNCuts, "nCuts", "Number of steps during node cut optimisation"); DeclareOptionRef(fPruneStrength, "PruneStrength", "Pruning strength (negative value == automatic adjustment)"); - DeclareOptionRef(fPruneMethodS, "PruneMethod", "Pruning method: NoPruning (switched off), ExpectedError or CostComplexity"); + DeclareOptionRef(fPruneMethodS="NoPruning", "PruneMethod", "Pruning method: NoPruning (switched off), ExpectedError or CostComplexity"); AddPreDefVal(TString("NoPruning")); AddPreDefVal(TString("ExpectedError")); AddPreDefVal(TString("CostComplexity")); - DeclareOptionRef(fNNodesMax=100000,"NNodesMax","Max number of nodes in tree"); if (DoRegression()) { DeclareOptionRef(fMaxDepth=50,"MaxDepth","Max depth of the decision tree allowed"); }else{ @@ -226,6 +224,15 @@ void TMVA::MethodDT::DeclareOptions() } } +void TMVA::MethodDT::DeclareCompatibilityOptions() { + // options that are used ONLY for the READER to ensure backward compatibility + + MethodBase::DeclareCompatibilityOptions(); + + DeclareOptionRef(fPruneBeforeBoost=kFALSE, "PruneBeforeBoost", + "--> removed option .. only kept for reader backward compatibility"); +} + //_______________________________________________________________________ void TMVA::MethodDT::ProcessOptions() { @@ -248,7 +255,7 @@ void TMVA::MethodDT::ProcessOptions() else if (fPruneMethodS == "nopruning" ) fPruneMethod = DecisionTree::kNoPruning; else { Log() << kINFO << GetOptions() << Endl; - Log() << kFATAL << "<ProcessOptions> unknown PruneMethod option called" << Endl; + Log() << kFATAL << "<ProcessOptions> unknown PruneMethod option:" << fPruneMethodS <<" called" << Endl; } if (fPruneStrength < 0) fAutomatic = kTRUE; @@ -263,10 +270,12 @@ void TMVA::MethodDT::ProcessOptions() Log() << kINFO << " You are using a Monte Carlo that has also negative weights. " << "That should in principle be fine as long as on average you end up with " << "something positive. For this you have to make sure that the minimal number " - << "of (unweighted) events demanded for a tree node (currently you use: nEventsMin=" - <<fNodeMinEvents<<", you can set this via the BDT option string when booking the " + << "of (un-weighted) events demanded for a tree node (currently you use: MinNodeSize=" + <<fMinNodeSizeS + <<", (or the deprecated equivalent nEventsMin) you can set this via the " + <<"MethodDT option string when booking the " << "classifier) is large enough to allow for reasonable averaging!!! " - << " If this does not help.. maybe you want to try the option: NoNegWeightsInTraining " + << " If this does not help.. maybe you want to try the option: IgnoreNegWeightsInTraining " << "which ignores events with negative weight in the training. " << Endl << Endl << "Note: You'll get a WARNING message during the training if that should ever happen" << Endl; } @@ -277,19 +286,55 @@ void TMVA::MethodDT::ProcessOptions() // fBoostType = "Bagging"; } + if (fMinNodeEvents > 0){ + fMinNodeSize = fMinNodeEvents / Data()->GetNTrainingEvents() * 100; + Log() << kWARNING << "You have explicitly set *nEventsMin*, the min ablsolut number \n" + << "of events in a leaf node. This is DEPRECATED, please use the option \n" + << "*MinNodeSize* giving the relative number as percentage of training \n" + << "events instead. \n" + << "nEventsMin="<<fMinNodeEvents<< "--> MinNodeSize="<<fMinNodeSize<<"%" + << Endl; + }else{ + SetMinNodeSize(fMinNodeSizeS); + } +} + +void TMVA::MethodDT::SetMinNodeSize(Double_t sizeInPercent){ + if (sizeInPercent > 0 && sizeInPercent < 50){ + fMinNodeSize=sizeInPercent; + + } else { + Log() << kERROR << "you have demanded a minimal node size of " + << sizeInPercent << "% of the training events.. \n" + << " that somehow does not make sense "<<Endl; + } + +} +void TMVA::MethodDT::SetMinNodeSize(TString sizeInPercent){ + sizeInPercent.ReplaceAll("%",""); + if (sizeInPercent.IsAlnum()) SetMinNodeSize(sizeInPercent.Atof()); + else { + Log() << kERROR << "I had problems reading the option MinNodeEvents, which\n" + << "after removing a possible % sign now reads " << sizeInPercent << Endl; + } } + + //_______________________________________________________________________ void TMVA::MethodDT::Init( void ) { // common initialisation with defaults for the DT-Method - fNodeMinEvents = TMath::Max( 20, int( Data()->GetNTrainingEvents() / (10*GetNvar()*GetNvar())) ); + fMinNodeEvents = -1; + fMinNodeSize = 5; + fMinNodeSizeS = "5%"; fNCuts = 20; fPruneMethod = DecisionTree::kNoPruning; - fPruneStrength = 5; // means automatic determination of the prune strength using a validation sample + fPruneStrength = 5; // -1 means automatic determination of the prune strength using a validation sample fDeltaPruneStrength=0.1; fRandomisedTrees= kFALSE; fUseNvars = GetNvar(); + fUsePoissonNvars = kTRUE; // reference cut value to distingiush signal-like from background-like events SetSignalReferenceCut( 0 ); @@ -311,88 +356,38 @@ TMVA::MethodDT::~MethodDT( void ) void TMVA::MethodDT::Train( void ) { TMVA::DecisionTreeNode::fgIsTraining=true; - fTree = new DecisionTree( fSepType, fNodeMinEvents, fNCuts, 0, - fRandomisedTrees, fUseNvars, fNNodesMax, fMaxDepth,0 ); + fTree = new DecisionTree( fSepType, fMinNodeSize, fNCuts, 0, + fRandomisedTrees, fUseNvars, fUsePoissonNvars,fMaxDepth,0 ); + fTree->SetNVars(GetNvar()); if (fRandomisedTrees) Log()<<kWARNING<<" randomised Trees do not work yet in this framework," << " as I do not know how to give each tree a new random seed, now they" << " will be all the same and that is not good " << Endl; fTree->SetAnalysisType( GetAnalysisType() ); - fTree->BuildTree(GetEventCollection(Types::kTraining)); - TMVA::DecisionTreeNode::fgIsTraining=false; + //fTree->BuildTree(GetEventCollection(Types::kTraining)); + Data()->SetCurrentType(Types::kTraining); + UInt_t nevents = Data()->GetNTrainingEvents(); + std::vector<const TMVA::Event*> tmp; + for (Long64_t ievt=0; ievt<nevents; ievt++) { + const Event *event = GetEvent(ievt); + tmp.push_back(event); + } + fTree->BuildTree(tmp); + if (fPruneMethod != DecisionTree::kNoPruning) fTree->PruneTree(); + + TMVA::DecisionTreeNode::fgIsTraining=false; } //_______________________________________________________________________ -Bool_t TMVA::MethodDT::MonitorBoost( MethodBoost* booster ) +Double_t TMVA::MethodDT::PruneTree( ) { - Int_t methodIndex = booster->GetMethodIndex(); - if (booster->GetBoostStage() == Types::kBoostProcBegin) - { - booster->AddMonitoringHist(new TH1I("NodesBeforePruning","nodes before pruning",booster->GetBoostNum(),0,booster->GetBoostNum())); - booster->AddMonitoringHist(new TH1I("NodesAfterPruning","nodes after pruning",booster->GetBoostNum(),0,booster->GetBoostNum())); - booster->AddMonitoringHist(new TH1D("PruneStrength","prune strength",booster->GetBoostNum(),0,booster->GetBoostNum())); - } - - if (booster->GetBoostStage() == Types::kBeforeTraining) - { - if (methodIndex == 0) - { - booster->GetMonitoringHist(2)->SetXTitle("#tree"); - booster->GetMonitoringHist(2)->SetYTitle("PruneStrength"); - //dividing the data set for pruning where strength is calculated automatically - if (fAutomatic) - { - Data()->DivideTrainingSet(2); - Data()->MoveTrainingBlock(1,Types::kValidation,kTRUE); - } - } - } - else if (booster->GetBoostStage() == Types::kBeforeBoosting) - booster->GetMonitoringHist(0)->SetBinContent(booster->GetBoostNum()+1,fTree->GetNNodes()); - - if (booster->GetBoostStage() == ((fPruneBeforeBoost)?Types::kBeforeBoosting:Types::kBoostValidation) - && !(fPruneMethod == DecisionTree::kNoPruning)) { - - if (methodIndex==0 && fPruneBeforeBoost == kFALSE) - Log() << kINFO << "Pruning "<< booster->GetBoostNum() << " Decision Trees ... patience please" << Endl; - - //reading the previous value - if (fAutomatic && methodIndex > 0) { - MethodDT* mdt = dynamic_cast<MethodDT*>(booster->GetPreviousMethod()); - if(mdt) - fPruneStrength = mdt->GetPruneStrength(); - } + // prune the decision tree if requested (good for individual trees that are best grown out, and then + // pruned back, while boosted decision trees are best 'small' trees to start with. Well, at least the + // standard "optimal pruning algorithms" don't result in 'weak enough' classifiers !! - booster->GetMonitoringHist(0)->SetBinContent(methodIndex+1,fTree->GetNNodes()); - booster->GetMonitoringHist(2)->SetBinContent(methodIndex+1,PruneTree(methodIndex)); - booster->GetMonitoringHist(1)->SetBinContent(methodIndex+1,fTree->GetNNodes()); - } // no pruning is performed - else if (booster->GetBoostStage() != Types::kBoostProcEnd) - return kFALSE; - - //finishing the pruning process, printing out everything - if (booster->GetBoostStage() == Types::kBoostProcEnd) - { - if (fPruneMethod == DecisionTree::kNoPruning) { - Log() << kINFO << "<Train> average number of nodes (w/o pruning) : " - << booster->GetMonitoringHist(0)->GetMean() << Endl; - } - else - { - Log() << kINFO << "<Train> average number of nodes before/after pruning : " - << booster->GetMonitoringHist(0)->GetMean() << " / " - << booster->GetMonitoringHist(1)->GetMean() - << Endl; - } - } - - return kTRUE; -} + // remember the number of nodes beforehand (for monitoring purposes) -//_______________________________________________________________________ -Double_t TMVA::MethodDT::PruneTree(const Int_t /* methodIndex */ ) -{ if (fAutomatic && fPruneMethod == DecisionTree::kCostComplexityPruning) { // automatic cost complexity pruning CCPruner* pruneTool = new CCPruner(fTree, this->Data() , fSepType); pruneTool->Optimize(); @@ -409,7 +404,7 @@ Double_t TMVA::MethodDT::PruneTree(const Int_t /* methodIndex */ ) Double_t delta = fDeltaPruneStrength; DecisionTree* dcopy; - vector<Double_t> q; + std::vector<Double_t> q; multimap<Double_t,Double_t> quality; Int_t nnodes=fTree->GetNNodes(); @@ -424,7 +419,7 @@ Double_t TMVA::MethodDT::PruneTree(const Int_t /* methodIndex */ ) dcopy->SetPruneStrength(alpha+=delta); dcopy->PruneTree(); q.push_back(TestTreeQuality(dcopy)); - quality.insert(pair<const Double_t,Double_t>(q.back(),alpha)); + quality.insert(std::pair<const Double_t,Double_t>(q.back(),alpha)); nnodes=dcopy->GetNNodes(); if (previousNnodes == nnodes) troubleCount++; else { @@ -482,6 +477,7 @@ Double_t TMVA::MethodDT::PruneTree(const Int_t /* methodIndex */ ) fTree->SetPruneStrength(fPruneStrength); fTree->PruneTree(); } + return fPruneStrength; } @@ -493,8 +489,8 @@ Double_t TMVA::MethodDT::TestTreeQuality( DecisionTree *dt ) Double_t SumCorrect=0,SumWrong=0; for (Long64_t ievt=0; ievt<Data()->GetNEvents(); ievt++) { - Event * ev = Data()->GetEvent(ievt); - if ((dt->CheckEvent(*ev) > dt->GetNodePurityLimit() ) == DataInfo().IsSignal(ev)) SumCorrect+=ev->GetWeight(); + const Event * ev = Data()->GetEvent(ievt); + if ((dt->CheckEvent(ev) > dt->GetNodePurityLimit() ) == DataInfo().IsSignal(ev)) SumCorrect+=ev->GetWeight(); else SumWrong+=ev->GetWeight(); } Data()->SetCurrentType(Types::kTraining); @@ -518,7 +514,7 @@ void TMVA::MethodDT::ReadWeightsFromXML( void* wghtnode) } //_______________________________________________________________________ -void TMVA::MethodDT::ReadWeightsFromStream( istream& istr ) +void TMVA::MethodDT::ReadWeightsFromStream( std::istream& istr ) { delete fTree; fTree = new DecisionTree(); @@ -533,7 +529,7 @@ Double_t TMVA::MethodDT::GetMvaValue( Double_t* err, Double_t* errUpper ) // cannot determine error NoErrorCalc(err, errUpper); - return fTree->CheckEvent(*GetEvent(),fUseYesNoLeaf); + return fTree->CheckEvent(GetEvent(),fUseYesNoLeaf); } //_______________________________________________________________________ diff --git a/tmva/src/MethodFDA.cxx b/tmva/src/MethodFDA.cxx index dd56c7fa28546..e651a2a21c922 100644 --- a/tmva/src/MethodFDA.cxx +++ b/tmva/src/MethodFDA.cxx @@ -61,6 +61,8 @@ #include "TMVA/MCFitter.h" #include "TMVA/Config.h" +using std::stringstream; + REGISTER_METHOD(FDA) ClassImp(TMVA::MethodFDA) @@ -251,8 +253,8 @@ void TMVA::MethodFDA::ProcessOptions() TString pminS(str(1,istr-1)); TString pmaxS(str(istr+1,str.Length()-2-istr)); - stringstream stmin; Float_t pmin; stmin << pminS.Data(); stmin >> pmin; - stringstream stmax; Float_t pmax; stmax << pmaxS.Data(); stmax >> pmax; + stringstream stmin; Float_t pmin=0; stmin << pminS.Data(); stmin >> pmin; + stringstream stmax; Float_t pmax=0; stmax << pmaxS.Data(); stmax >> pmax; // sanity check if (TMath::Abs(pmax-pmin) < 1.e-30) pmax = pmin; @@ -355,7 +357,7 @@ void TMVA::MethodFDA::Train( void ) const Event* ev = GetEvent(ievt); // true event copy - Float_t w = GetTWeight(ev); + Float_t w = ev->GetWeight(); if (!DoRegression()) { if (DataInfo().IsSignal(ev)) { fSumOfWeightsSig += w; } @@ -402,7 +404,7 @@ void TMVA::MethodFDA::PrintResults( const TString& fitter, std::vector<Double_t> // check maximum length of variable name Log() << kINFO; Log() << "Results for parameter fit using \"" << fitter << "\" fitter:" << Endl; - vector<TString> parNames; + std::vector<TString> parNames; for (UInt_t ipar=0; ipar<pars.size(); ipar++) parNames.push_back( Form("Par(%i)",ipar ) ); gTools().FormattedOutput( pars, parNames, "Parameter" , "Fit result", Log(), "%g" ); Log() << "Discriminator expression: \"" << fFormulaStringP << "\"" << Endl; @@ -581,7 +583,7 @@ void TMVA::MethodFDA::CalculateMulticlassValues( const TMVA::Event*& evt, std::v //_______________________________________________________________________ -void TMVA::MethodFDA::ReadWeightsFromStream( istream& istr ) +void TMVA::MethodFDA::ReadWeightsFromStream( std::istream& istr ) { // read back the training results from a file (stream) @@ -655,19 +657,19 @@ void TMVA::MethodFDA::ReadWeightsFromXML( void* wghtnode ) void TMVA::MethodFDA::MakeClassSpecific( std::ostream& fout, const TString& className ) const { // write FDA-specific classifier response - fout << " double fParameter[" << fNPars << "];" << endl; - fout << "};" << endl; - fout << "" << endl; - fout << "inline void " << className << "::Initialize() " << endl; - fout << "{" << endl; + fout << " double fParameter[" << fNPars << "];" << std::endl; + fout << "};" << std::endl; + fout << "" << std::endl; + fout << "inline void " << className << "::Initialize() " << std::endl; + fout << "{" << std::endl; for(UInt_t ipar=0; ipar<fNPars; ipar++) { - fout << " fParameter[" << ipar << "] = " << fBestPars[ipar] << ";" << endl; + fout << " fParameter[" << ipar << "] = " << fBestPars[ipar] << ";" << std::endl; } - fout << "}" << endl; - fout << endl; - fout << "inline double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << endl; - fout << "{" << endl; - fout << " // interpret the formula" << endl; + fout << "}" << std::endl; + fout << std::endl; + fout << "inline double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << std::endl; + fout << "{" << std::endl; + fout << " // interpret the formula" << std::endl; // replace parameters TString str = fFormulaStringT; @@ -680,16 +682,16 @@ void TMVA::MethodFDA::MakeClassSpecific( std::ostream& fout, const TString& clas str.ReplaceAll( Form("[%i]", ivar+fNPars), Form("inputValues[%i]", ivar) ); } - fout << " double retval = " << str << ";" << endl; - fout << endl; - fout << " return retval; " << endl; - fout << "}" << endl; - fout << endl; - fout << "// Clean up" << endl; - fout << "inline void " << className << "::Clear() " << endl; - fout << "{" << endl; - fout << " // nothing to clear" << endl; - fout << "}" << endl; + fout << " double retval = " << str << ";" << std::endl; + fout << std::endl; + fout << " return retval; " << std::endl; + fout << "}" << std::endl; + fout << std::endl; + fout << "// Clean up" << std::endl; + fout << "inline void " << className << "::Clear() " << std::endl; + fout << "{" << std::endl; + fout << " // nothing to clear" << std::endl; + fout << "}" << std::endl; } //_______________________________________________________________________ diff --git a/tmva/src/MethodFisher.cxx b/tmva/src/MethodFisher.cxx index ef9b5775df49c..42f6026474775 100644 --- a/tmva/src/MethodFisher.cxx +++ b/tmva/src/MethodFisher.cxx @@ -304,7 +304,7 @@ void TMVA::MethodFisher::GetMean( void ) const Event * ev = GetEvent(ievt); // sum of weights - Double_t weight = GetTWeight(ev); + Double_t weight = ev->GetWeight(); if (DataInfo().IsSignal(ev)) fSumOfWeightsS += weight; else fSumOfWeightsB += weight; @@ -355,7 +355,7 @@ void TMVA::MethodFisher::GetCov_WithinClass( void ) // read the Training Event into "event" const Event* ev = GetEvent(ievt); - Double_t weight = GetTWeight(ev); // may ignore events with negative weights + Double_t weight = ev->GetWeight(); // may ignore events with negative weights for (Int_t x=0; x<nvar; x++) xval[x] = ev->GetValue( x ); Int_t k=0; @@ -365,7 +365,7 @@ void TMVA::MethodFisher::GetCov_WithinClass( void ) Double_t v = ( (xval[x] - (*fMeanMatx)(x, 0))*(xval[y] - (*fMeanMatx)(y, 0)) )*weight; sumSig[k] += v; }else{ - Double_t v = ( (xval[x] - (*fMeanMatx)(x, 0))*(xval[y] - (*fMeanMatx)(y, 0)) )*weight; + Double_t v = ( (xval[x] - (*fMeanMatx)(x, 1))*(xval[y] - (*fMeanMatx)(y, 1)) )*weight; sumBgd[k] += v; } k++; @@ -375,7 +375,16 @@ void TMVA::MethodFisher::GetCov_WithinClass( void ) Int_t k=0; for (Int_t x=0; x<nvar; x++) { for (Int_t y=0; y<nvar; y++) { - (*fWith)(x, y) = (sumSig[k] + sumBgd[k])/(fSumOfWeightsS + fSumOfWeightsB); + //(*fWith)(x, y) = (sumSig[k] + sumBgd[k])/(fSumOfWeightsS + fSumOfWeightsB); + // HHV: I am still convinced that THIS is how it should be (below) However, while + // the old version corresponded so nicely with LD, the FIXED version does not, unless + // we agree to change LD. For LD, it is not "defined" to my knowledge how the weights + // are weighted, while it is clear how the "Within" matrix for Fisher should be calcuated + // (i.e. as seen below). In order to agree with the Fisher classifier, one would have to + // weigh signal and background such that they correspond to the same number of effective + // (weithed) events. + // THAT is NOT done currently, but just "event weights" are used. + (*fWith)(x, y) = sumSig[k]/fSumOfWeightsS + sumBgd[k]/fSumOfWeightsB; k++; } } @@ -448,6 +457,7 @@ void TMVA::MethodFisher::GetFisherCoeff( void ) } TMatrixD invCov( *theMat ); + if ( TMath::Abs(invCov.Determinant()) < 10E-24 ) { Log() << kWARNING << "<GetFisherCoeff> matrix is almost singular with deterninant=" << TMath::Abs(invCov.Determinant()) @@ -455,9 +465,11 @@ void TMVA::MethodFisher::GetFisherCoeff( void ) << Endl; } if ( TMath::Abs(invCov.Determinant()) < 10E-120 ) { + theMat->Print(); Log() << kFATAL << "<GetFisherCoeff> matrix is singular with determinant=" << TMath::Abs(invCov.Determinant()) - << " did you use the variables that are linear combinations?" + << " did you use the variables that are linear combinations? \n" + << " do you any clue as to what went wrong in above printout of the covariance matrix? " << Endl; } @@ -475,12 +487,12 @@ void TMVA::MethodFisher::GetFisherCoeff( void ) for (jvar=0; jvar<GetNvar(); jvar++) { Double_t d = (*fMeanMatx)(jvar, 0) - (*fMeanMatx)(jvar, 1); (*fFisherCoeff)[ivar] += invCov(ivar, jvar)*d; - } - + } // rescale (*fFisherCoeff)[ivar] *= xfact; } - + + // offset correction fF0 = 0.0; for (ivar=0; ivar<GetNvar(); ivar++){ @@ -546,6 +558,9 @@ void TMVA::MethodFisher::PrintCoefficients( void ) coeffs.push_back( fF0 ); TMVA::gTools().FormattedOutput( coeffs, vars, "Variable" , "Coefficient", Log() ); + // for (int i=0; i<coeffs.size(); i++) + // std::cout << "fisher coeff["<<i<<"]="<<coeffs[i]<<std::endl; + if (IsNormalised()) { Log() << kINFO << "NOTE: You have chosen to use the \"Normalise\" booking option. Hence, the" << Endl; Log() << kINFO << " coefficients must be applied to NORMALISED (') variables as follows:" << Endl; @@ -555,12 +570,12 @@ void TMVA::MethodFisher::PrintCoefficients( void ) // Print normalisation expression (see Tools.cxx): "2*(x - xmin)/(xmax - xmin) - 1.0" for (UInt_t ivar=0; ivar<GetNvar(); ivar++) { Log() << kINFO - << setw(maxL+9) << TString("[") + GetInputLabel(ivar) + "]' = 2*(" - << setw(maxL+2) << TString("[") + GetInputLabel(ivar) + "]" - << setw(3) << (GetXmin(ivar) > 0 ? " - " : " + ") - << setw(6) << TMath::Abs(GetXmin(ivar)) << setw(3) << ")/" - << setw(6) << (GetXmax(ivar) - GetXmin(ivar) ) - << setw(3) << " - 1" + << std::setw(maxL+9) << TString("[") + GetInputLabel(ivar) + "]' = 2*(" + << std::setw(maxL+2) << TString("[") + GetInputLabel(ivar) + "]" + << std::setw(3) << (GetXmin(ivar) > 0 ? " - " : " + ") + << std::setw(6) << TMath::Abs(GetXmin(ivar)) << std::setw(3) << ")/" + << std::setw(6) << (GetXmax(ivar) - GetXmin(ivar) ) + << std::setw(3) << " - 1" << Endl; } Log() << kINFO << "The TMVA Reader will properly account for this normalisation, but if the" << Endl; @@ -571,7 +586,7 @@ void TMVA::MethodFisher::PrintCoefficients( void ) } //_______________________________________________________________________ -void TMVA::MethodFisher::ReadWeightsFromStream( istream& istr ) +void TMVA::MethodFisher::ReadWeightsFromStream( std::istream& istr ) { // read Fisher coefficients from weight file istr >> fF0; @@ -619,41 +634,41 @@ void TMVA::MethodFisher::MakeClassSpecific( std::ostream& fout, const TString& c { // write Fisher-specific classifier response Int_t dp = fout.precision(); - fout << " double fFisher0;" << endl; - fout << " std::vector<double> fFisherCoefficients;" << endl; - fout << "};" << endl; - fout << "" << endl; - fout << "inline void " << className << "::Initialize() " << endl; - fout << "{" << endl; - fout << " fFisher0 = " << std::setprecision(12) << fF0 << ";" << endl; + fout << " double fFisher0;" << std::endl; + fout << " std::vector<double> fFisherCoefficients;" << std::endl; + fout << "};" << std::endl; + fout << "" << std::endl; + fout << "inline void " << className << "::Initialize() " << std::endl; + fout << "{" << std::endl; + fout << " fFisher0 = " << std::setprecision(12) << fF0 << ";" << std::endl; for (UInt_t ivar=0; ivar<GetNvar(); ivar++) { - fout << " fFisherCoefficients.push_back( " << std::setprecision(12) << (*fFisherCoeff)[ivar] << " );" << endl; + fout << " fFisherCoefficients.push_back( " << std::setprecision(12) << (*fFisherCoeff)[ivar] << " );" << std::endl; } - fout << endl; - fout << " // sanity check" << endl; - fout << " if (fFisherCoefficients.size() != fNvars) {" << endl; - fout << " std::cout << \"Problem in class \\\"\" << fClassName << \"\\\"::Initialize: mismatch in number of input values\"" << endl; - fout << " << fFisherCoefficients.size() << \" != \" << fNvars << std::endl;" << endl; - fout << " fStatusIsClean = false;" << endl; - fout << " } " << endl; - fout << "}" << endl; - fout << endl; - fout << "inline double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << endl; - fout << "{" << endl; - fout << " double retval = fFisher0;" << endl; - fout << " for (size_t ivar = 0; ivar < fNvars; ivar++) {" << endl; - fout << " retval += fFisherCoefficients[ivar]*inputValues[ivar];" << endl; - fout << " }" << endl; - fout << endl; - fout << " return retval;" << endl; - fout << "}" << endl; - fout << endl; - fout << "// Clean up" << endl; - fout << "inline void " << className << "::Clear() " << endl; - fout << "{" << endl; - fout << " // clear coefficients" << endl; - fout << " fFisherCoefficients.clear(); " << endl; - fout << "}" << endl; + fout << std::endl; + fout << " // sanity check" << std::endl; + fout << " if (fFisherCoefficients.size() != fNvars) {" << std::endl; + fout << " std::cout << \"Problem in class \\\"\" << fClassName << \"\\\"::Initialize: mismatch in number of input values\"" << std::endl; + fout << " << fFisherCoefficients.size() << \" != \" << fNvars << std::endl;" << std::endl; + fout << " fStatusIsClean = false;" << std::endl; + fout << " } " << std::endl; + fout << "}" << std::endl; + fout << std::endl; + fout << "inline double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << std::endl; + fout << "{" << std::endl; + fout << " double retval = fFisher0;" << std::endl; + fout << " for (size_t ivar = 0; ivar < fNvars; ivar++) {" << std::endl; + fout << " retval += fFisherCoefficients[ivar]*inputValues[ivar];" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " return retval;" << std::endl; + fout << "}" << std::endl; + fout << std::endl; + fout << "// Clean up" << std::endl; + fout << "inline void " << className << "::Clear() " << std::endl; + fout << "{" << std::endl; + fout << " // clear coefficients" << std::endl; + fout << " fFisherCoefficients.clear(); " << std::endl; + fout << "}" << std::endl; fout << std::setprecision(dp); } diff --git a/tmva/src/MethodHMatrix.cxx b/tmva/src/MethodHMatrix.cxx index 47ebef42d4baf..4fb54d7ea7198 100644 --- a/tmva/src/MethodHMatrix.cxx +++ b/tmva/src/MethodHMatrix.cxx @@ -265,7 +265,7 @@ Double_t TMVA::MethodHMatrix::GetChi2( Types::ESBType type ) // loop over variables UInt_t ivar(0), jvar(0), nvar(GetNvar()); - vector<Double_t> val( nvar ); + std::vector<Double_t> val( nvar ); // transform the event according to the given type (signal/background) if (type==Types::kSignal) @@ -323,7 +323,7 @@ void TMVA::MethodHMatrix::ReadWeightsFromXML( void* wghtnode ) } //_______________________________________________________________________ -void TMVA::MethodHMatrix::ReadWeightsFromStream( istream& istr ) +void TMVA::MethodHMatrix::ReadWeightsFromStream( std::istream& istr ) { // read variable names and min/max // NOTE: the latter values are mandatory for the normalisation @@ -352,91 +352,91 @@ void TMVA::MethodHMatrix::ReadWeightsFromStream( istream& istr ) void TMVA::MethodHMatrix::MakeClassSpecific( std::ostream& fout, const TString& className ) const { // write Fisher-specific classifier response - fout << " // arrays of input evt vs. variable " << endl; - fout << " double fInvHMatrixS[" << GetNvar() << "][" << GetNvar() << "]; // inverse H-matrix (signal)" << endl; - fout << " double fInvHMatrixB[" << GetNvar() << "][" << GetNvar() << "]; // inverse H-matrix (background)" << endl; - fout << " double fVecMeanS[" << GetNvar() << "]; // vector of mean values (signal)" << endl; - fout << " double fVecMeanB[" << GetNvar() << "]; // vector of mean values (background)" << endl; - fout << " " << endl; - fout << " double GetChi2( const std::vector<double>& inputValues, int type ) const;" << endl; - fout << "};" << endl; - fout << " " << endl; - fout << "void " << className << "::Initialize() " << endl; - fout << "{" << endl; - fout << " // init vectors with mean values" << endl; + fout << " // arrays of input evt vs. variable " << std::endl; + fout << " double fInvHMatrixS[" << GetNvar() << "][" << GetNvar() << "]; // inverse H-matrix (signal)" << std::endl; + fout << " double fInvHMatrixB[" << GetNvar() << "][" << GetNvar() << "]; // inverse H-matrix (background)" << std::endl; + fout << " double fVecMeanS[" << GetNvar() << "]; // vector of mean values (signal)" << std::endl; + fout << " double fVecMeanB[" << GetNvar() << "]; // vector of mean values (background)" << std::endl; + fout << " " << std::endl; + fout << " double GetChi2( const std::vector<double>& inputValues, int type ) const;" << std::endl; + fout << "};" << std::endl; + fout << " " << std::endl; + fout << "void " << className << "::Initialize() " << std::endl; + fout << "{" << std::endl; + fout << " // init vectors with mean values" << std::endl; for (UInt_t ivar=0; ivar<GetNvar(); ivar++) { - fout << " fVecMeanS[" << ivar << "] = " << (*fVecMeanS)(ivar) << ";" << endl; - fout << " fVecMeanB[" << ivar << "] = " << (*fVecMeanB)(ivar) << ";" << endl; + fout << " fVecMeanS[" << ivar << "] = " << (*fVecMeanS)(ivar) << ";" << std::endl; + fout << " fVecMeanB[" << ivar << "] = " << (*fVecMeanB)(ivar) << ";" << std::endl; } - fout << " " << endl; - fout << " // init H-matrices" << endl; + fout << " " << std::endl; + fout << " // init H-matrices" << std::endl; for (UInt_t ivar=0; ivar<GetNvar(); ivar++) { for (UInt_t jvar=0; jvar<GetNvar(); jvar++) { fout << " fInvHMatrixS[" << ivar << "][" << jvar << "] = " - << (*fInvHMatrixS)(ivar,jvar) << ";" << endl; + << (*fInvHMatrixS)(ivar,jvar) << ";" << std::endl; fout << " fInvHMatrixB[" << ivar << "][" << jvar << "] = " - << (*fInvHMatrixB)(ivar,jvar) << ";" << endl; + << (*fInvHMatrixB)(ivar,jvar) << ";" << std::endl; } } - fout << "}" << endl; - fout << " " << endl; - fout << "inline double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << endl; - fout << "{" << endl; - fout << " // returns the H-matrix signal estimator" << endl; - fout << " std::vector<double> inputValuesSig = inputValues;" << endl; - fout << " std::vector<double> inputValuesBgd = inputValues;" << endl; + fout << "}" << std::endl; + fout << " " << std::endl; + fout << "inline double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << std::endl; + fout << "{" << std::endl; + fout << " // returns the H-matrix signal estimator" << std::endl; + fout << " std::vector<double> inputValuesSig = inputValues;" << std::endl; + fout << " std::vector<double> inputValuesBgd = inputValues;" << std::endl; if (GetTransformationHandler().GetTransformationList().GetSize() != 0) { UInt_t signalClass =DataInfo().GetClassInfo("Signal")->GetNumber(); UInt_t backgroundClass=DataInfo().GetClassInfo("Background")->GetNumber(); - fout << " Transform(inputValuesSig," << signalClass << ");" << endl; - fout << " Transform(inputValuesBgd," << backgroundClass << ");" << endl; + fout << " Transform(inputValuesSig," << signalClass << ");" << std::endl; + fout << " Transform(inputValuesBgd," << backgroundClass << ");" << std::endl; } -// fout << " for(uint i=0; i<GetNvar(); ++i) std::cout << inputValuesSig.at(i) << \" \" << inputValuesBgd.at(i) << std::endl; " << endl; - - fout << " double s = GetChi2( inputValuesSig, " << Types::kSignal << " );" << endl; - fout << " double b = GetChi2( inputValuesBgd, " << Types::kBackground << " );" << endl; - -// fout << " std::cout << s << \" \" << b << std::endl; " << endl; - - fout << " " << endl; - fout << " if (s+b <= 0) std::cout << \"Problem in class " << className << "::GetMvaValue__: s+b = \"" << endl; - fout << " << s+b << \" <= 0 \" << std::endl;" << endl; - fout << " " << endl; - fout << " return (b - s)/(s + b);" << endl; - fout << "}" << endl; - fout << " " << endl; - fout << "inline double " << className << "::GetChi2( const std::vector<double>& inputValues, int type ) const" << endl; - fout << "{" << endl; - fout << " // compute chi2-estimator for event according to type (signal/background)" << endl; - fout << " " << endl; - fout << " size_t ivar,jvar;" << endl; - fout << " double chi2 = 0;" << endl; - fout << " for (ivar=0; ivar<GetNvar(); ivar++) {" << endl; - fout << " for (jvar=0; jvar<GetNvar(); jvar++) {" << endl; - fout << " if (type == " << Types::kSignal << ") " << endl; - fout << " chi2 += ( (inputValues[ivar] - fVecMeanS[ivar])*(inputValues[jvar] - fVecMeanS[jvar])" << endl; - fout << " * fInvHMatrixS[ivar][jvar] );" << endl; - fout << " else" << endl; - fout << " chi2 += ( (inputValues[ivar] - fVecMeanB[ivar])*(inputValues[jvar] - fVecMeanB[jvar])" << endl; - fout << " * fInvHMatrixB[ivar][jvar] );" << endl; - fout << " }" << endl; - fout << " } // loop over variables " << endl; - fout << " " << endl; - fout << " // sanity check" << endl; - fout << " if (chi2 < 0) std::cout << \"Problem in class " << className << "::GetChi2: chi2 = \"" << endl; - fout << " << chi2 << \" < 0 \" << std::endl;" << endl; - fout << " " << endl; - fout << " return chi2;" << endl; - fout << "}" << endl; - fout << " " << endl; - fout << "// Clean up" << endl; - fout << "inline void " << className << "::Clear() " << endl; - fout << "{" << endl; - fout << " // nothing to clear" << endl; - fout << "}" << endl; +// fout << " for(uint i=0; i<GetNvar(); ++i) std::cout << inputValuesSig.at(i) << \" \" << inputValuesBgd.at(i) << std::endl; " << std::endl; + + fout << " double s = GetChi2( inputValuesSig, " << Types::kSignal << " );" << std::endl; + fout << " double b = GetChi2( inputValuesBgd, " << Types::kBackground << " );" << std::endl; + +// fout << " std::cout << s << \" \" << b << std::endl; " << std::endl; + + fout << " " << std::endl; + fout << " if (s+b <= 0) std::cout << \"Problem in class " << className << "::GetMvaValue__: s+b = \"" << std::endl; + fout << " << s+b << \" <= 0 \" << std::endl;" << std::endl; + fout << " " << std::endl; + fout << " return (b - s)/(s + b);" << std::endl; + fout << "}" << std::endl; + fout << " " << std::endl; + fout << "inline double " << className << "::GetChi2( const std::vector<double>& inputValues, int type ) const" << std::endl; + fout << "{" << std::endl; + fout << " // compute chi2-estimator for event according to type (signal/background)" << std::endl; + fout << " " << std::endl; + fout << " size_t ivar,jvar;" << std::endl; + fout << " double chi2 = 0;" << std::endl; + fout << " for (ivar=0; ivar<GetNvar(); ivar++) {" << std::endl; + fout << " for (jvar=0; jvar<GetNvar(); jvar++) {" << std::endl; + fout << " if (type == " << Types::kSignal << ") " << std::endl; + fout << " chi2 += ( (inputValues[ivar] - fVecMeanS[ivar])*(inputValues[jvar] - fVecMeanS[jvar])" << std::endl; + fout << " * fInvHMatrixS[ivar][jvar] );" << std::endl; + fout << " else" << std::endl; + fout << " chi2 += ( (inputValues[ivar] - fVecMeanB[ivar])*(inputValues[jvar] - fVecMeanB[jvar])" << std::endl; + fout << " * fInvHMatrixB[ivar][jvar] );" << std::endl; + fout << " }" << std::endl; + fout << " } // loop over variables " << std::endl; + fout << " " << std::endl; + fout << " // sanity check" << std::endl; + fout << " if (chi2 < 0) std::cout << \"Problem in class " << className << "::GetChi2: chi2 = \"" << std::endl; + fout << " << chi2 << \" < 0 \" << std::endl;" << std::endl; + fout << " " << std::endl; + fout << " return chi2;" << std::endl; + fout << "}" << std::endl; + fout << " " << std::endl; + fout << "// Clean up" << std::endl; + fout << "inline void " << className << "::Clear() " << std::endl; + fout << "{" << std::endl; + fout << " // nothing to clear" << std::endl; + fout << "}" << std::endl; } //_______________________________________________________________________ diff --git a/tmva/src/MethodKNN.cxx b/tmva/src/MethodKNN.cxx index 501e1bc4e3878..c38704f72a5d7 100644 --- a/tmva/src/MethodKNN.cxx +++ b/tmva/src/MethodKNN.cxx @@ -130,6 +130,8 @@ void TMVA::MethodKNN::DeclareOptions() //_______________________________________________________________________ void TMVA::MethodKNN::DeclareCompatibilityOptions() { + // options that are used ONLY for the READER to ensure backward compatibility + MethodBase::DeclareCompatibilityOptions(); DeclareOptionRef(fTreeOptDepth = 6, "TreeOptDepth", "Binary tree optimisation depth"); } @@ -572,10 +574,10 @@ void TMVA::MethodKNN::ReadWeightsFromXML( void* wghtnode ) { } //_______________________________________________________________________ -void TMVA::MethodKNN::ReadWeightsFromStream(istream& is) +void TMVA::MethodKNN::ReadWeightsFromStream(std::istream& is) { // read the weights - Log() << kINFO << "Starting ReadWeightsFromStream(istream& is) function..." << Endl; + Log() << kINFO << "Starting ReadWeightsFromStream(std::istream& is) function..." << Endl; if (!fEvent.empty()) { Log() << kINFO << "Erasing " << fEvent.size() << " previously stored events" << Endl; diff --git a/tmva/src/MethodLD.cxx b/tmva/src/MethodLD.cxx index f64e4787a06e4..775d481243a20 100644 --- a/tmva/src/MethodLD.cxx +++ b/tmva/src/MethodLD.cxx @@ -42,6 +42,8 @@ #include "TMVA/PDF.h" #include "TMVA/ClassifierFactory.h" +using std::vector; + REGISTER_METHOD(LD) ClassImp(TMVA::MethodLD) @@ -83,7 +85,9 @@ void TMVA::MethodLD::Init( void ) else fNRegOut = 1; fLDCoeff = new vector< vector< Double_t >* >(fNRegOut); - for (Int_t iout = 0; iout<fNRegOut; iout++) (*fLDCoeff)[iout] = new std::vector<Double_t>( GetNvar()+1 ); + for (Int_t iout = 0; iout<fNRegOut; iout++){ + (*fLDCoeff)[iout] = new std::vector<Double_t>( GetNvar()+1 ); + } // the minimum requirement to declare an event signal-like SetSignalReferenceCut( 0.0 ); @@ -97,8 +101,9 @@ TMVA::MethodLD::~MethodLD( void ) if (fSumValMatx) { delete fSumValMatx; fSumValMatx = 0; } if (fCoeffMatx) { delete fCoeffMatx; fCoeffMatx = 0; } if (fLDCoeff) { - for (vector< vector< Double_t >* >::iterator vi=fLDCoeff->begin(); vi!=fLDCoeff->end(); vi++) + for (vector< vector< Double_t >* >::iterator vi=fLDCoeff->begin(); vi!=fLDCoeff->end(); vi++){ if (*vi) { delete *vi; *vi = 0; } + } delete fLDCoeff; fLDCoeff = 0; } } @@ -204,8 +209,9 @@ void TMVA::MethodLD::GetSum( void ) // and X the coordinates values const UInt_t nvar = DataInfo().GetNVariables(); - for (UInt_t ivar = 0; ivar<=nvar; ivar++) + for (UInt_t ivar = 0; ivar<=nvar; ivar++){ for (UInt_t jvar = 0; jvar<=nvar; jvar++) (*fSumMatx)( ivar, jvar ) = 0; + } // compute sample means Long64_t nevts = Data()->GetNEvents(); @@ -225,9 +231,11 @@ void TMVA::MethodLD::GetSum( void ) } // Sum of products of coordinates - for (UInt_t ivar=0; ivar<nvar; ivar++) - for (UInt_t jvar=0; jvar<nvar; jvar++) + for (UInt_t ivar=0; ivar<nvar; ivar++){ + for (UInt_t jvar=0; jvar<nvar; jvar++){ (*fSumMatx)( ivar+1, jvar+1 ) += ev->GetValue( ivar ) * ev->GetValue( jvar ) * weight; + } + } } } @@ -237,9 +245,11 @@ void TMVA::MethodLD::GetSumVal( void ) //Calculates the vector transposed(X)*W*Y with Y being the target vector const UInt_t nvar = DataInfo().GetNVariables(); - for (Int_t ivar = 0; ivar<fNRegOut; ivar++) - for (UInt_t jvar = 0; jvar<=nvar; jvar++) + for (Int_t ivar = 0; ivar<fNRegOut; ivar++){ + for (UInt_t jvar = 0; jvar<=nvar; jvar++){ (*fSumValMatx)(jvar,ivar) = 0; + } + } // Sum of coordinates multiplied by values for (Int_t ievt=0; ievt<Data()->GetNEvents(); ievt++) { @@ -255,14 +265,15 @@ void TMVA::MethodLD::GetSumVal( void ) Double_t val = weight; - if (!DoRegression()) - val *= DataInfo().IsSignal(ev); - else //for regression + if (!DoRegression()){ + val *= DataInfo().IsSignal(ev); // yes it works.. but I'm still surprised (Helge).. would have not set y_B to zero though.. + }else {//for regression val *= ev->GetTarget( ivar ); - + } (*fSumValMatx)( 0,ivar ) += val; - for (UInt_t jvar=0; jvar<nvar; jvar++) + for (UInt_t jvar=0; jvar<nvar; jvar++) { (*fSumValMatx)(jvar+1,ivar ) += ev->GetValue(jvar) * val; + } } } } @@ -295,8 +306,9 @@ void TMVA::MethodLD::GetLDCoeff( void ) } if (!DoRegression()) { (*(*fLDCoeff)[ivar])[0]=0.0; - for (UInt_t jvar = 1; jvar<nvar+1; jvar++) + for (UInt_t jvar = 1; jvar<nvar+1; jvar++){ (*(*fLDCoeff)[ivar])[0]+=(*fCoeffMatx)(jvar,ivar)*(*fSumMatx)(0,jvar)/(*fSumMatx)( 0, 0 ); + } (*(*fLDCoeff)[ivar])[0]/=-2.0; } @@ -304,12 +316,14 @@ void TMVA::MethodLD::GetLDCoeff( void ) } //_______________________________________________________________________ -void TMVA::MethodLD::ReadWeightsFromStream( istream& istr ) +void TMVA::MethodLD::ReadWeightsFromStream( std::istream& istr ) { // read LD coefficients from weight file - for (Int_t iout=0; iout<fNRegOut; iout++) - for (UInt_t icoeff=0; icoeff<GetNvar()+1; icoeff++) + for (Int_t iout=0; iout<fNRegOut; iout++){ + for (UInt_t icoeff=0; icoeff<GetNvar()+1; icoeff++){ istr >> (*(*fLDCoeff)[iout])[icoeff]; + } + } } //_______________________________________________________________________ @@ -345,8 +359,9 @@ void TMVA::MethodLD::ReadWeightsFromXML( void* wghtnode ) // create vector with coefficients (double vector due to arbitrary output dimension) if (fLDCoeff) { - for (vector< vector< Double_t >* >::iterator vi=fLDCoeff->begin(); vi!=fLDCoeff->end(); vi++) + for (vector< vector< Double_t >* >::iterator vi=fLDCoeff->begin(); vi!=fLDCoeff->end(); vi++){ if (*vi) { delete *vi; *vi = 0; } + } delete fLDCoeff; fLDCoeff = 0; } fLDCoeff = new vector< vector< Double_t >* >(fNRegOut); @@ -370,42 +385,42 @@ void TMVA::MethodLD::ReadWeightsFromXML( void* wghtnode ) void TMVA::MethodLD::MakeClassSpecific( std::ostream& fout, const TString& className ) const { // write LD-specific classifier response - fout << " std::vector<double> fLDCoefficients;" << endl; - fout << "};" << endl; - fout << "" << endl; - fout << "inline void " << className << "::Initialize() " << endl; - fout << "{" << endl; + fout << " std::vector<double> fLDCoefficients;" << std::endl; + fout << "};" << std::endl; + fout << "" << std::endl; + fout << "inline void " << className << "::Initialize() " << std::endl; + fout << "{" << std::endl; for (UInt_t ivar=0; ivar<GetNvar()+1; ivar++) { Int_t dp = fout.precision(); fout << " fLDCoefficients.push_back( " << std::setprecision(12) << (*(*fLDCoeff)[0])[ivar] - << std::setprecision(dp) << " );" << endl; + << std::setprecision(dp) << " );" << std::endl; } - fout << endl; - fout << " // sanity check" << endl; - fout << " if (fLDCoefficients.size() != fNvars+1) {" << endl; - fout << " std::cout << \"Problem in class \\\"\" << fClassName << \"\\\"::Initialize: mismatch in number of input values\"" << endl; - fout << " << fLDCoefficients.size() << \" != \" << fNvars+1 << std::endl;" << endl; - fout << " fStatusIsClean = false;" << endl; - fout << " } " << endl; - fout << "}" << endl; - fout << endl; - fout << "inline double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << endl; - fout << "{" << endl; - fout << " double retval = fLDCoefficients[0];" << endl; - fout << " for (size_t ivar = 1; ivar < fNvars+1; ivar++) {" << endl; - fout << " retval += fLDCoefficients[ivar]*inputValues[ivar-1];" << endl; - fout << " }" << endl; - fout << endl; - fout << " return retval;" << endl; - fout << "}" << endl; - fout << endl; - fout << "// Clean up" << endl; - fout << "inline void " << className << "::Clear() " << endl; - fout << "{" << endl; - fout << " // clear coefficients" << endl; - fout << " fLDCoefficients.clear(); " << endl; - fout << "}" << endl; + fout << std::endl; + fout << " // sanity check" << std::endl; + fout << " if (fLDCoefficients.size() != fNvars+1) {" << std::endl; + fout << " std::cout << \"Problem in class \\\"\" << fClassName << \"\\\"::Initialize: mismatch in number of input values\"" << std::endl; + fout << " << fLDCoefficients.size() << \" != \" << fNvars+1 << std::endl;" << std::endl; + fout << " fStatusIsClean = false;" << std::endl; + fout << " } " << std::endl; + fout << "}" << std::endl; + fout << std::endl; + fout << "inline double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << std::endl; + fout << "{" << std::endl; + fout << " double retval = fLDCoefficients[0];" << std::endl; + fout << " for (size_t ivar = 1; ivar < fNvars+1; ivar++) {" << std::endl; + fout << " retval += fLDCoefficients[ivar]*inputValues[ivar-1];" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " return retval;" << std::endl; + fout << "}" << std::endl; + fout << std::endl; + fout << "// Clean up" << std::endl; + fout << "inline void " << className << "::Clear() " << std::endl; + fout << "{" << std::endl; + fout << " // clear coefficients" << std::endl; + fout << " fLDCoefficients.clear(); " << std::endl; + fout << "}" << std::endl; } //_______________________________________________________________________ const TMVA::Ranking* TMVA::MethodLD::CreateRanking() @@ -468,12 +483,12 @@ void TMVA::MethodLD::PrintCoefficients( void ) // Print normalisation expression (see Tools.cxx): "2*(x - xmin)/(xmax - xmin) - 1.0" for (UInt_t ivar=0; ivar<GetNvar(); ivar++) { Log() << kINFO - << setw(maxL+9) << TString("[") + GetInputLabel(ivar) + "]' = 2*(" - << setw(maxL+2) << TString("[") + GetInputLabel(ivar) + "]" - << setw(3) << (GetXmin(ivar) > 0 ? " - " : " + ") - << setw(6) << TMath::Abs(GetXmin(ivar)) << setw(3) << ")/" - << setw(6) << (GetXmax(ivar) - GetXmin(ivar) ) - << setw(3) << " - 1" + << std::setw(maxL+9) << TString("[") + GetInputLabel(ivar) + "]' = 2*(" + << std::setw(maxL+2) << TString("[") + GetInputLabel(ivar) + "]" + << std::setw(3) << (GetXmin(ivar) > 0 ? " - " : " + ") + << std::setw(6) << TMath::Abs(GetXmin(ivar)) << std::setw(3) << ")/" + << std::setw(6) << (GetXmax(ivar) - GetXmin(ivar) ) + << std::setw(3) << " - 1" << Endl; } Log() << kINFO << "The TMVA Reader will properly account for this normalisation, but if the" << Endl; diff --git a/tmva/src/MethodLikelihood.cxx b/tmva/src/MethodLikelihood.cxx index 9696f310c2a08..5da71c898c5e6 100644 --- a/tmva/src/MethodLikelihood.cxx +++ b/tmva/src/MethodLikelihood.cxx @@ -250,6 +250,8 @@ void TMVA::MethodLikelihood::DeclareOptions() void TMVA::MethodLikelihood::DeclareCompatibilityOptions() { + // options that are used ONLY for the READER to ensure backward compatibility + MethodBase::DeclareCompatibilityOptions(); DeclareOptionRef( fNsmooth = 1, "NSmooth", "Number of smoothing iterations for the input histograms"); @@ -312,7 +314,7 @@ void TMVA::MethodLikelihood::Train( void ) // the transformations are applied using both classes, also the corresponding boundaries // need to take this into account UInt_t nvar=GetNvar(); - vector<Double_t> xmin(nvar), xmax(nvar); + std::vector<Double_t> xmin(nvar), xmax(nvar); for (UInt_t ivar=0; ivar<nvar; ivar++) {xmin[ivar]=1e30; xmax[ivar]=-1e30;} UInt_t nevents=Data()->GetNEvents(); @@ -527,23 +529,23 @@ Double_t TMVA::MethodLikelihood::TransformLikelihoodOutput( Double_t ps, Double_ } //______________________________________________________________________ -void TMVA::MethodLikelihood::WriteOptionsToStream( ostream& o, const TString& prefix ) const +void TMVA::MethodLikelihood::WriteOptionsToStream( std::ostream& o, const TString& prefix ) const { // write options to stream Configurable::WriteOptionsToStream( o, prefix); // writing the options defined for the different pdfs if (fDefaultPDFLik != 0) { - o << prefix << endl << prefix << "#Default Likelihood PDF Options:" << endl << prefix << endl; + o << prefix << std::endl << prefix << "#Default Likelihood PDF Options:" << std::endl << prefix << std::endl; fDefaultPDFLik->WriteOptionsToStream( o, prefix ); } for (UInt_t ivar = 0; ivar < fPDFSig->size(); ivar++) { if ((*fPDFSig)[ivar] != 0) { - o << prefix << endl << prefix << Form("#Signal[%d] Likelihood PDF Options:",ivar) << endl << prefix << endl; + o << prefix << std::endl << prefix << Form("#Signal[%d] Likelihood PDF Options:",ivar) << std::endl << prefix << std::endl; (*fPDFSig)[ivar]->WriteOptionsToStream( o, prefix ); } if ((*fPDFBgd)[ivar] != 0) { - o << prefix << endl << prefix << "#Background[%d] Likelihood PDF Options:" << endl << prefix << endl; + o << prefix << std::endl << prefix << "#Background[%d] Likelihood PDF Options:" << std::endl << prefix << std::endl; (*fPDFBgd)[ivar]->WriteOptionsToStream( o, prefix ); } } @@ -660,7 +662,7 @@ void TMVA::MethodLikelihood::ReadWeightsFromXML(void* wghtnode) TH1::AddDirectory(addDirStatus); } //_______________________________________________________________________ -void TMVA::MethodLikelihood::ReadWeightsFromStream( istream & istr ) +void TMVA::MethodLikelihood::ReadWeightsFromStream( std::istream & istr ) { // read weight info from file // nothing to do for this method @@ -747,8 +749,8 @@ void TMVA::MethodLikelihood::WriteMonitoringHistosToFile( void ) const void TMVA::MethodLikelihood::MakeClassSpecificHeader( std::ostream& fout, const TString& ) const { // write specific header of the classifier (mostly include files) - fout << "#include <math.h>" << endl; - fout << "#include <cstdlib>" << endl; + fout << "#include <math.h>" << std::endl; + fout << "#include <cstdlib>" << std::endl; } //_______________________________________________________________________ @@ -756,7 +758,7 @@ void TMVA::MethodLikelihood::MakeClassSpecific( std::ostream& fout, const TStrin { // write specific classifier response Int_t dp = fout.precision(); - fout << " double fEpsilon;" << endl; + fout << " double fEpsilon;" << std::endl; Int_t * nbin = new Int_t[GetNvar()]; @@ -767,26 +769,26 @@ void TMVA::MethodLikelihood::MakeClassSpecific( std::ostream& fout, const TStrin } fout << " static float fRefS[][" << nbinMax << "]; " - << "// signal reference vector [nvars][max_nbins]" << endl; + << "// signal reference vector [nvars][max_nbins]" << std::endl; fout << " static float fRefB[][" << nbinMax << "]; " - << "// backgr reference vector [nvars][max_nbins]" << endl << endl; - fout << "// if a variable has its PDF encoded as a spline0 --> treat it like an Integer valued one" <<endl; - fout << " bool fHasDiscretPDF[" << GetNvar() <<"]; "<< endl; + << "// backgr reference vector [nvars][max_nbins]" << std::endl << std::endl; + fout << "// if a variable has its PDF encoded as a spline0 --> treat it like an Integer valued one" <<std::endl; + fout << " bool fHasDiscretPDF[" << GetNvar() <<"]; "<< std::endl; fout << " int fNbin[" << GetNvar() << "]; " - << "// number of bins (discrete variables may have less bins)" << endl; - fout << " double fHistMin[" << GetNvar() << "]; " << endl; - fout << " double fHistMax[" << GetNvar() << "]; " << endl; - - fout << " double TransformLikelihoodOutput( double, double ) const;" << endl; - fout << "};" << endl; - fout << "" << endl; - fout << "inline void " << className << "::Initialize() " << endl; - fout << "{" << endl; - fout << " fEpsilon = " << fEpsilon << ";" << endl; + << "// number of bins (discrete variables may have less bins)" << std::endl; + fout << " double fHistMin[" << GetNvar() << "]; " << std::endl; + fout << " double fHistMax[" << GetNvar() << "]; " << std::endl; + + fout << " double TransformLikelihoodOutput( double, double ) const;" << std::endl; + fout << "};" << std::endl; + fout << "" << std::endl; + fout << "inline void " << className << "::Initialize() " << std::endl; + fout << "{" << std::endl; + fout << " fEpsilon = " << fEpsilon << ";" << std::endl; for (UInt_t ivar=0; ivar<GetNvar(); ivar++) { - fout << " fNbin[" << ivar << "] = " << (*fPDFSig)[ivar]->GetPDFHist()->GetNbinsX() << ";" << endl; - fout << " fHistMin[" << ivar << "] = " << (*fPDFSig)[ivar]->GetPDFHist()->GetXaxis()->GetXmin() << ";" << endl; - fout << " fHistMax[" << ivar << "] = " << (*fPDFSig)[ivar]->GetPDFHist()->GetXaxis()->GetXmax() << ";" << endl; + fout << " fNbin[" << ivar << "] = " << (*fPDFSig)[ivar]->GetPDFHist()->GetNbinsX() << ";" << std::endl; + fout << " fHistMin[" << ivar << "] = " << (*fPDFSig)[ivar]->GetPDFHist()->GetXaxis()->GetXmin() << ";" << std::endl; + fout << " fHistMax[" << ivar << "] = " << (*fPDFSig)[ivar]->GetPDFHist()->GetXaxis()->GetXmax() << ";" << std::endl; // sanity check (for previous code lines) if ((((*fPDFSig)[ivar]->GetPDFHist()->GetNbinsX() != nbin[ivar] || (*fPDFBgd)[ivar]->GetPDFHist()->GetNbinsX() != nbin[ivar]) @@ -803,116 +805,116 @@ void TMVA::MethodLikelihood::MakeClassSpecific( std::ostream& fout, const TStrin } for (UInt_t ivar=0; ivar<GetNvar(); ivar++){ if ((*fPDFSig)[ivar]->GetInterpolMethod() == TMVA::PDF::kSpline0) - fout << " fHasDiscretPDF[" << ivar <<"] = true; " << endl; + fout << " fHasDiscretPDF[" << ivar <<"] = true; " << std::endl; else - fout << " fHasDiscretPDF[" << ivar <<"] = false; " << endl; + fout << " fHasDiscretPDF[" << ivar <<"] = false; " << std::endl; } - fout << "}" << endl << endl; + fout << "}" << std::endl << std::endl; fout << "inline double " << className - << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << endl; - fout << "{" << endl; - fout << " double ps(1), pb(1);" << endl; - fout << " std::vector<double> inputValuesSig = inputValues;" << endl; - fout << " std::vector<double> inputValuesBgd = inputValues;" << endl; + << "::GetMvaValue__( const std::vector<double>& inputValues ) const" << std::endl; + fout << "{" << std::endl; + fout << " double ps(1), pb(1);" << std::endl; + fout << " std::vector<double> inputValuesSig = inputValues;" << std::endl; + fout << " std::vector<double> inputValuesBgd = inputValues;" << std::endl; if (GetTransformationHandler().GetTransformationList().GetSize() != 0) { - fout << " Transform(inputValuesSig,0);" << endl; - fout << " Transform(inputValuesBgd,1);" << endl; + fout << " Transform(inputValuesSig,0);" << std::endl; + fout << " Transform(inputValuesBgd,1);" << std::endl; } - fout << " for (size_t ivar = 0; ivar < GetNvar(); ivar++) {" << endl; - fout << endl; - fout << " // dummy at present... will be used for variable transforms" << endl; - fout << " double x[2] = { inputValuesSig[ivar], inputValuesBgd[ivar] };" << endl; - fout << endl; - fout << " for (int itype=0; itype < 2; itype++) {" << endl; - fout << endl; - fout << " // interpolate linearly between adjacent bins" << endl; - fout << " // this is not useful for discrete variables (or forced Spline0)" << endl; - fout << " int bin = int((x[itype] - fHistMin[ivar])/(fHistMax[ivar] - fHistMin[ivar])*fNbin[ivar]) + 0;" << endl; - fout << endl; - fout << " // since the test data sample is in general different from the training sample" << endl; - fout << " // it can happen that the min/max of the training sample are trespassed --> correct this" << endl; - fout << " if (bin < 0) {" << endl; - fout << " bin = 0;" << endl; - fout << " x[itype] = fHistMin[ivar];" << endl; - fout << " }" << endl; - fout << " else if (bin >= fNbin[ivar]) {" << endl; - fout << " bin = fNbin[ivar]-1;" << endl; - fout << " x[itype] = fHistMax[ivar];" << endl; - fout << " }" << endl; - fout << endl; - fout << " // find corresponding histogram from cached indices" << endl; - fout << " float ref = (itype == 0) ? fRefS[ivar][bin] : fRefB[ivar][bin];" << endl; - fout << endl; - fout << " // sanity check" << endl; - fout << " if (ref < 0) {" << endl; + fout << " for (size_t ivar = 0; ivar < GetNvar(); ivar++) {" << std::endl; + fout << std::endl; + fout << " // dummy at present... will be used for variable transforms" << std::endl; + fout << " double x[2] = { inputValuesSig[ivar], inputValuesBgd[ivar] };" << std::endl; + fout << std::endl; + fout << " for (int itype=0; itype < 2; itype++) {" << std::endl; + fout << std::endl; + fout << " // interpolate linearly between adjacent bins" << std::endl; + fout << " // this is not useful for discrete variables (or forced Spline0)" << std::endl; + fout << " int bin = int((x[itype] - fHistMin[ivar])/(fHistMax[ivar] - fHistMin[ivar])*fNbin[ivar]) + 0;" << std::endl; + fout << std::endl; + fout << " // since the test data sample is in general different from the training sample" << std::endl; + fout << " // it can happen that the min/max of the training sample are trespassed --> correct this" << std::endl; + fout << " if (bin < 0) {" << std::endl; + fout << " bin = 0;" << std::endl; + fout << " x[itype] = fHistMin[ivar];" << std::endl; + fout << " }" << std::endl; + fout << " else if (bin >= fNbin[ivar]) {" << std::endl; + fout << " bin = fNbin[ivar]-1;" << std::endl; + fout << " x[itype] = fHistMax[ivar];" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " // find corresponding histogram from cached indices" << std::endl; + fout << " float ref = (itype == 0) ? fRefS[ivar][bin] : fRefB[ivar][bin];" << std::endl; + fout << std::endl; + fout << " // sanity check" << std::endl; + fout << " if (ref < 0) {" << std::endl; fout << " std::cout << \"Fatal error in " << className - << ": bin entry < 0 ==> abort\" << std::endl;" << endl; - fout << " std::exit(1);" << endl; - fout << " }" << endl; - fout << endl; - fout << " double p = ref;" << endl; - fout << endl; - fout << " if (GetType(ivar) != 'I' && !fHasDiscretPDF[ivar]) {" << endl; - fout << " float bincenter = (bin + 0.5)/fNbin[ivar]*(fHistMax[ivar] - fHistMin[ivar]) + fHistMin[ivar];" << endl; - fout << " int nextbin = bin;" << endl; - fout << " if ((x[itype] > bincenter && bin != fNbin[ivar]-1) || bin == 0) " << endl; - fout << " nextbin++;" << endl; - fout << " else" << endl; - fout << " nextbin--; " << endl; - fout << endl; - fout << " double refnext = (itype == 0) ? fRefS[ivar][nextbin] : fRefB[ivar][nextbin];" << endl; - fout << " float nextbincenter = (nextbin + 0.5)/fNbin[ivar]*(fHistMax[ivar] - fHistMin[ivar]) + fHistMin[ivar];" << endl; - fout << endl; - fout << " double dx = bincenter - nextbincenter;" << endl; - fout << " double dy = ref - refnext;" << endl; - fout << " p += (x[itype] - bincenter) * dy/dx;" << endl; - fout << " }" << endl; - fout << endl; - fout << " if (p < fEpsilon) p = fEpsilon; // avoid zero response" << endl; - fout << endl; - fout << " if (itype == 0) ps *= p;" << endl; - fout << " else pb *= p;" << endl; - fout << " } " << endl; - fout << " } " << endl; - fout << endl; - fout << " // the likelihood ratio (transform it ?)" << endl; - fout << " return TransformLikelihoodOutput( ps, pb ); " << endl; - fout << "}" << endl << endl; - - fout << "inline double " << className << "::TransformLikelihoodOutput( double ps, double pb ) const" << endl; - fout << "{" << endl; - fout << " // returns transformed or non-transformed output" << endl; - fout << " if (ps < fEpsilon) ps = fEpsilon;" << endl; - fout << " if (pb < fEpsilon) pb = fEpsilon;" << endl; - fout << " double r = ps/(ps + pb);" << endl; - fout << " if (r >= 1.0) r = 1. - 1.e-15;" << endl; - fout << endl; - fout << " if (" << (fTransformLikelihoodOutput ? "true" : "false") << ") {" << endl; - fout << " // inverse Fermi function" << endl; - fout << endl; - fout << " // sanity check" << endl; - fout << " if (r <= 0.0) r = fEpsilon;" << endl; - fout << " else if (r >= 1.0) r = 1. - 1.e-15;" << endl; - fout << endl; - fout << " double tau = 15.0;" << endl; - fout << " r = - log(1.0/r - 1.0)/tau;" << endl; - fout << " }" << endl; - fout << endl; - fout << " return r;" << endl; - fout << "}" << endl; - fout << endl; - - fout << "// Clean up" << endl; - fout << "inline void " << className << "::Clear() " << endl; - fout << "{" << endl; - fout << " // nothing to clear" << endl; - fout << "}" << endl << endl; - - fout << "// signal map" << endl; - fout << "float " << className << "::fRefS[][" << nbinMax << "] = " << endl; - fout << "{ " << endl; + << ": bin entry < 0 ==> abort\" << std::endl;" << std::endl; + fout << " std::exit(1);" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " double p = ref;" << std::endl; + fout << std::endl; + fout << " if (GetType(ivar) != 'I' && !fHasDiscretPDF[ivar]) {" << std::endl; + fout << " float bincenter = (bin + 0.5)/fNbin[ivar]*(fHistMax[ivar] - fHistMin[ivar]) + fHistMin[ivar];" << std::endl; + fout << " int nextbin = bin;" << std::endl; + fout << " if ((x[itype] > bincenter && bin != fNbin[ivar]-1) || bin == 0) " << std::endl; + fout << " nextbin++;" << std::endl; + fout << " else" << std::endl; + fout << " nextbin--; " << std::endl; + fout << std::endl; + fout << " double refnext = (itype == 0) ? fRefS[ivar][nextbin] : fRefB[ivar][nextbin];" << std::endl; + fout << " float nextbincenter = (nextbin + 0.5)/fNbin[ivar]*(fHistMax[ivar] - fHistMin[ivar]) + fHistMin[ivar];" << std::endl; + fout << std::endl; + fout << " double dx = bincenter - nextbincenter;" << std::endl; + fout << " double dy = ref - refnext;" << std::endl; + fout << " p += (x[itype] - bincenter) * dy/dx;" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " if (p < fEpsilon) p = fEpsilon; // avoid zero response" << std::endl; + fout << std::endl; + fout << " if (itype == 0) ps *= p;" << std::endl; + fout << " else pb *= p;" << std::endl; + fout << " } " << std::endl; + fout << " } " << std::endl; + fout << std::endl; + fout << " // the likelihood ratio (transform it ?)" << std::endl; + fout << " return TransformLikelihoodOutput( ps, pb ); " << std::endl; + fout << "}" << std::endl << std::endl; + + fout << "inline double " << className << "::TransformLikelihoodOutput( double ps, double pb ) const" << std::endl; + fout << "{" << std::endl; + fout << " // returns transformed or non-transformed output" << std::endl; + fout << " if (ps < fEpsilon) ps = fEpsilon;" << std::endl; + fout << " if (pb < fEpsilon) pb = fEpsilon;" << std::endl; + fout << " double r = ps/(ps + pb);" << std::endl; + fout << " if (r >= 1.0) r = 1. - 1.e-15;" << std::endl; + fout << std::endl; + fout << " if (" << (fTransformLikelihoodOutput ? "true" : "false") << ") {" << std::endl; + fout << " // inverse Fermi function" << std::endl; + fout << std::endl; + fout << " // sanity check" << std::endl; + fout << " if (r <= 0.0) r = fEpsilon;" << std::endl; + fout << " else if (r >= 1.0) r = 1. - 1.e-15;" << std::endl; + fout << std::endl; + fout << " double tau = 15.0;" << std::endl; + fout << " r = - log(1.0/r - 1.0)/tau;" << std::endl; + fout << " }" << std::endl; + fout << std::endl; + fout << " return r;" << std::endl; + fout << "}" << std::endl; + fout << std::endl; + + fout << "// Clean up" << std::endl; + fout << "inline void " << className << "::Clear() " << std::endl; + fout << "{" << std::endl; + fout << " // nothing to clear" << std::endl; + fout << "}" << std::endl << std::endl; + + fout << "// signal map" << std::endl; + fout << "float " << className << "::fRefS[][" << nbinMax << "] = " << std::endl; + fout << "{ " << std::endl; for (UInt_t ivar=0; ivar<GetNvar(); ivar++) { fout << " { "; for (Int_t ibin=1; ibin<=nbinMax; ibin++) { @@ -923,14 +925,14 @@ void TMVA::MethodLikelihood::MakeClassSpecific( std::ostream& fout, const TStrin if (ibin < nbinMax) fout << ", "; } - fout << " }, " << endl; + fout << " }, " << std::endl; } - fout << "}; " << endl; - fout << endl; + fout << "}; " << std::endl; + fout << std::endl; - fout << "// background map" << endl; - fout << "float " << className << "::fRefB[][" << nbinMax << "] = " << endl; - fout << "{ " << endl; + fout << "// background map" << std::endl; + fout << "float " << className << "::fRefB[][" << nbinMax << "] = " << std::endl; + fout << "{ " << std::endl; for (UInt_t ivar=0; ivar<GetNvar(); ivar++) { fout << " { "; fout << std::setprecision(8); @@ -942,10 +944,10 @@ void TMVA::MethodLikelihood::MakeClassSpecific( std::ostream& fout, const TStrin if (ibin < nbinMax) fout << ", "; } - fout << " }, " << endl; + fout << " }, " << std::endl; } - fout << "}; " << endl; - fout << endl; + fout << "}; " << std::endl; + fout << std::endl; fout << std::setprecision(dp); delete[] nbin; diff --git a/tmva/src/MethodMLP.cxx b/tmva/src/MethodMLP.cxx index f9e61d1b3ae42..d824ffc07e291 100644 --- a/tmva/src/MethodMLP.cxx +++ b/tmva/src/MethodMLP.cxx @@ -1229,7 +1229,7 @@ void TMVA::MethodMLP::UpdateNetwork(Double_t desired, Double_t eventWeight) } //______________________________________________________________________________ -void TMVA::MethodMLP::UpdateNetwork(std::vector<Float_t>& desired, Double_t eventWeight) +void TMVA::MethodMLP::UpdateNetwork(const std::vector<Float_t>& desired, Double_t eventWeight) { // update the network based on how closely // the output matched the desired output @@ -1286,7 +1286,7 @@ void TMVA::MethodMLP::GeneticMinimize() fGA_nsteps = 30; // ranges - vector<Interval*> ranges; + std::vector<Interval*> ranges; Int_t numWeights = fSynapses->GetEntriesFast(); for (Int_t ivar=0; ivar< numWeights; ivar++) { @@ -1391,8 +1391,8 @@ void TMVA::MethodMLP::UpdateRegulators() //zjh Int_t numRegulators=fRegulators.size(); Float_t gamma=0, variance=1.; // Gaussian noise - vector<Int_t> nWDP(numRegulators); - vector<Double_t> trace(numRegulators),weightSum(numRegulators); + std::vector<Int_t> nWDP(numRegulators); + std::vector<Double_t> trace(numRegulators),weightSum(numRegulators); for (int i=0;i<numSynapses;i++) { TSynapse* synapses = (TSynapse*)fSynapses->At(i); Int_t idx=fRegulatorIdx[i]; diff --git a/tmva/src/MethodPDEFoam.cxx b/tmva/src/MethodPDEFoam.cxx index 3607f54c34a96..f99d63a573950 100644 --- a/tmva/src/MethodPDEFoam.cxx +++ b/tmva/src/MethodPDEFoam.cxx @@ -230,6 +230,8 @@ void TMVA::MethodPDEFoam::DeclareOptions() //_______________________________________________________________________ void TMVA::MethodPDEFoam::DeclareCompatibilityOptions() { + // options that are used ONLY for the READER to ensure backward compatibility + MethodBase::DeclareCompatibilityOptions(); DeclareOptionRef(fCutNmin = kTRUE, "CutNmin", "Requirement for minimal number of events in cell"); DeclareOptionRef(fPeekMax = kTRUE, "PeekMax", "Peek cell with max. loss for the next split"); @@ -270,7 +272,7 @@ void TMVA::MethodPDEFoam::ProcessOptions() else if (fDTLogic == "SdivSqrtSplusB") fDTSeparation = kSdivSqrtSplusB; else { - Log() << kWARNING << "Unknown separation type: " << fDTLogic + Log() << kWARNING << "Unknown separation type: " << fDTLogic << ", setting to None" << Endl; fDTLogic = "None"; fDTSeparation = kFoam; @@ -282,6 +284,14 @@ void TMVA::MethodPDEFoam::ProcessOptions() if (fTargetSelectionStr == "Mean" ) fTargetSelection = kMean; else fTargetSelection = kMpv; + // sanity check: number of targets > 1 and MultiTargetRegression=F + // makes no sense --> set MultiTargetRegression=T + if (DoRegression() && Data()->GetNTargets() > 1 && !fMultiTargetRegression) { + Log() << kWARNING << "Warning: number of targets > 1" + << " and MultiTargetRegression=F was set, this makes no sense!" + << " --> I'm setting MultiTargetRegression=T" << Endl; + fMultiTargetRegression = kTRUE; + } } //_______________________________________________________________________ @@ -295,7 +305,7 @@ TMVA::MethodPDEFoam::~MethodPDEFoam( void ) } //_______________________________________________________________________ -void TMVA::MethodPDEFoam::CalcXminXmax() +void TMVA::MethodPDEFoam::CalcXminXmax() { // Determine foam range [fXmin, fXmax] for all dimensions, such // that a fraction of 'fFrac' events lie outside the foam. @@ -320,17 +330,17 @@ void TMVA::MethodPDEFoam::CalcXminXmax() Log() << kDEBUG << "Number of training events: " << Data()->GetNTrainingEvents() << Endl; Int_t nevoutside = (Int_t)((Data()->GetNTrainingEvents())*(fFrac)); // number of events that are outside the range Int_t rangehistbins = 10000; // number of bins in histos - + // loop over all testing singnal and BG events and clac minimal and // maximal value of every variable for (Long64_t i=0; i<(GetNEvents()); i++) { // events loop - const Event* ev = GetEvent(i); + const Event* ev = GetEvent(i); for (UInt_t dim=0; dim<kDim; dim++) { // variables loop Float_t val; if (fMultiTargetRegression) { if (dim < vDim) val = ev->GetValue(dim); - else + else val = ev->GetTarget(dim-vDim); } else @@ -346,12 +356,12 @@ void TMVA::MethodPDEFoam::CalcXminXmax() // Create and fill histograms for each dimension (with same events // as before), to determine range based on number of events outside // the range - TH1F **range_h = new TH1F*[kDim]; + TH1F **range_h = new TH1F*[kDim]; for (UInt_t dim=0; dim<kDim; dim++) { range_h[dim] = new TH1F(Form("range%i", dim), "range", rangehistbins, xmin[dim], xmax[dim]); } - // fill all testing events into histos + // fill all testing events into histos for (Long64_t i=0; i<GetNEvents(); i++) { const Event* ev = GetEvent(i); for (UInt_t dim=0; dim<kDim; dim++) { @@ -367,8 +377,8 @@ void TMVA::MethodPDEFoam::CalcXminXmax() } // calc Xmin, Xmax from Histos - for (UInt_t dim=0; dim<kDim; dim++) { - for (Int_t i=1; i<(rangehistbins+1); i++) { // loop over bins + for (UInt_t dim=0; dim<kDim; dim++) { + for (Int_t i=1; i<(rangehistbins+1); i++) { // loop over bins if (range_h[dim]->Integral(0, i) > nevoutside) { // calc left limit (integral over bins 0..i = nevoutside) xmin[dim]=range_h[dim]->GetBinLowEdge(i); break; @@ -380,13 +390,13 @@ void TMVA::MethodPDEFoam::CalcXminXmax() break; } } - } + } // now xmin[] and xmax[] contain upper/lower limits for every dimension // copy xmin[], xmax[] values to the class variable fXmin.clear(); fXmax.clear(); - for (UInt_t dim=0; dim<kDim; dim++) { + for (UInt_t dim=0; dim<kDim; dim++) { fXmin.push_back(xmin[dim]); fXmax.push_back(xmax[dim]); } @@ -425,9 +435,9 @@ void TMVA::MethodPDEFoam::Train( void ) if (DoMulticlass()) TrainMultiClassification(); else { - if (DataInfo().GetNormalization() != "EQUALNUMEVENTS" ) { - Log() << kINFO << "NormMode=" << DataInfo().GetNormalization() - << " chosen. Note that only NormMode=EqualNumEvents" + if (DataInfo().GetNormalization() != "EQUALNUMEVENTS" ) { + Log() << kINFO << "NormMode=" << DataInfo().GetNormalization() + << " chosen. Note that only NormMode=EqualNumEvents" << " ensures that Discriminant values correspond to" << " signal probabilities." << Endl; } @@ -445,13 +455,13 @@ void TMVA::MethodPDEFoam::Train( void ) // delete the binary search tree in order to save memory for(UInt_t i=0; i<fFoam.size(); i++) { - if(fFoam.at(i)) + if(fFoam.at(i)) fFoam.at(i)->DeleteBinarySearchTree(); } } //_______________________________________________________________________ -void TMVA::MethodPDEFoam::TrainSeparatedClassification() +void TMVA::MethodPDEFoam::TrainSeparatedClassification() { // Creation of 2 separated foams: one for signal events, one for // backgound events. At the end the foam cells of fFoam[0] will @@ -466,7 +476,7 @@ void TMVA::MethodPDEFoam::TrainSeparatedClassification() // create 2 PDEFoams fFoam.push_back( InitFoam(foamcaption[i], kSeparate) ); - Log() << kVERBOSE << "Filling binary search tree of " << foamcaption[i] + Log() << kVERBOSE << "Filling binary search tree of " << foamcaption[i] << " with events" << Endl; // insert event to BinarySearchTree for (Long64_t k=0; k<GetNEvents(); ++k) { @@ -492,7 +502,7 @@ void TMVA::MethodPDEFoam::TrainSeparatedClassification() } //_______________________________________________________________________ -void TMVA::MethodPDEFoam::TrainUnifiedClassification() +void TMVA::MethodPDEFoam::TrainUnifiedClassification() { // Create only one unified foam (fFoam[0]) whose cells contain the // average discriminator (N_sig)/(N_sig + N_bg) @@ -502,7 +512,7 @@ void TMVA::MethodPDEFoam::TrainUnifiedClassification() Log() << kVERBOSE << "Filling binary search tree of discriminator foam with events" << Endl; // insert event to BinarySearchTree for (Long64_t k=0; k<GetNEvents(); ++k) { - const Event* ev = GetEvent(k); + const Event* ev = GetEvent(k); if (!(IgnoreEventsWithNegWeightsInTraining() && ev->GetWeight()<=0)) fFoam.back()->FillBinarySearchTree(ev); } @@ -513,7 +523,7 @@ void TMVA::MethodPDEFoam::TrainUnifiedClassification() Log() << kVERBOSE << "Filling foam cells with events" << Endl; // loop over all training events -> fill foam cells with N_sig and N_Bg for (Long64_t k=0; k<GetNEvents(); ++k) { - const Event* ev = GetEvent(k); + const Event* ev = GetEvent(k); Float_t weight = fFillFoamWithOrigWeights ? ev->GetOriginalWeight() : ev->GetWeight(); if (!(IgnoreEventsWithNegWeightsInTraining() && ev->GetWeight()<=0)) fFoam.back()->FillFoamCells(ev, weight); @@ -525,7 +535,7 @@ void TMVA::MethodPDEFoam::TrainUnifiedClassification() } //_______________________________________________________________________ -void TMVA::MethodPDEFoam::TrainMultiClassification() +void TMVA::MethodPDEFoam::TrainMultiClassification() { // Create one unified foam (see TrainUnifiedClassification()) for // each class, where the cells of foam i (fFoam[i]) contain the @@ -541,7 +551,7 @@ void TMVA::MethodPDEFoam::TrainMultiClassification() << iClass << " with events" << Endl; // insert event to BinarySearchTree for (Long64_t k=0; k<GetNEvents(); ++k) { - const Event* ev = GetEvent(k); + const Event* ev = GetEvent(k); if (!(IgnoreEventsWithNegWeightsInTraining() && ev->GetWeight()<=0)) fFoam.back()->FillBinarySearchTree(ev); } @@ -553,7 +563,7 @@ void TMVA::MethodPDEFoam::TrainMultiClassification() // loop over all training events and fill foam cells with signal // and background events for (Long64_t k=0; k<GetNEvents(); ++k) { - const Event* ev = GetEvent(k); + const Event* ev = GetEvent(k); Float_t weight = fFillFoamWithOrigWeights ? ev->GetOriginalWeight() : ev->GetWeight(); if (!(IgnoreEventsWithNegWeightsInTraining() && ev->GetWeight()<=0)) fFoam.back()->FillFoamCells(ev, weight); @@ -566,29 +576,25 @@ void TMVA::MethodPDEFoam::TrainMultiClassification() } //_______________________________________________________________________ -void TMVA::MethodPDEFoam::TrainMonoTargetRegression() +void TMVA::MethodPDEFoam::TrainMonoTargetRegression() { // Training one (mono target regression) foam, whose cells contain // the average 0th target. The dimension of the foam = number of // non-targets (= number of variables). - if (Data()->GetNTargets() < 1) { - Log() << kFATAL << "Error: number of targets = " << Data()->GetNTargets() << Endl; - return; + if (Data()->GetNTargets() != 1) { + Log() << kFATAL << "Can't do mono-target regression with " + << Data()->GetNTargets() << " targets!" << Endl; } - else if (Data()->GetNTargets() > 1) { - Log() << kWARNING << "Warning: number of targets = " << Data()->GetNTargets() - << " --> using only first target" << Endl; - } - else - Log() << kDEBUG << "MethodPDEFoam: number of Targets: " << Data()->GetNTargets() << Endl; + + Log() << kDEBUG << "MethodPDEFoam: number of Targets: " << Data()->GetNTargets() << Endl; fFoam.push_back( InitFoam("MonoTargetRegressionFoam", kMonoTarget) ); Log() << kVERBOSE << "Filling binary search tree with events" << Endl; // insert event to BinarySearchTree for (Long64_t k=0; k<GetNEvents(); ++k) { - const Event* ev = GetEvent(k); + const Event* ev = GetEvent(k); if (!(IgnoreEventsWithNegWeightsInTraining() && ev->GetWeight()<=0)) fFoam.back()->FillBinarySearchTree(ev); } @@ -599,7 +605,7 @@ void TMVA::MethodPDEFoam::TrainMonoTargetRegression() Log() << kVERBOSE << "Filling foam cells with events" << Endl; // loop over all events -> fill foam cells with target for (Long64_t k=0; k<GetNEvents(); ++k) { - const Event* ev = GetEvent(k); + const Event* ev = GetEvent(k); Float_t weight = fFillFoamWithOrigWeights ? ev->GetOriginalWeight() : ev->GetWeight(); if (!(IgnoreEventsWithNegWeightsInTraining() && ev->GetWeight()<=0)) fFoam.back()->FillFoamCells(ev, weight); @@ -621,12 +627,12 @@ void TMVA::MethodPDEFoam::TrainMultiTargetRegression() Log() << kDEBUG << "Number of Targets: " << Data()->GetNTargets() << Endl; Log() << kDEBUG << "Dimension of foam: " << Data()->GetNVariables()+Data()->GetNTargets() << Endl; if (fKernel==kLinN) - Log() << kFATAL << "LinNeighbors kernel currently not supported" + Log() << kFATAL << "LinNeighbors kernel currently not supported" << " for multi target regression" << Endl; fFoam.push_back( InitFoam("MultiTargetRegressionFoam", kMultiTarget) ); - Log() << kVERBOSE << "Filling binary search tree of multi target regression foam with events" + Log() << kVERBOSE << "Filling binary search tree of multi target regression foam with events" << Endl; // insert event to BinarySearchTree for (Long64_t k=0; k<GetNEvents(); ++k) { @@ -654,11 +660,11 @@ void TMVA::MethodPDEFoam::TrainMultiTargetRegression() Event *ev = new Event(*GetEvent(k)); // since in multi-target regression targets are handled like // variables --> remove targets and add them to the event variabels - std::vector<Float_t> targets = ev->GetTargets(); + std::vector<Float_t> targets = ev->GetTargets(); const UInt_t nVariables = ev->GetValues().size(); Float_t weight = fFillFoamWithOrigWeights ? ev->GetOriginalWeight() : ev->GetWeight(); - for (UInt_t i = 0; i < targets.size(); ++i) - ev->SetVal(i+nVariables, targets.at(i)); + for (UInt_t i = 0; i < targets.size(); ++i) + ev->SetVal(i+nVariables, targets.at(i)); ev->GetTargets().clear(); if (!(IgnoreEventsWithNegWeightsInTraining() && ev->GetWeight()<=0)) fFoam.back()->FillFoamCells(ev, weight); @@ -834,7 +840,7 @@ const TMVA::Ranking* TMVA::MethodPDEFoam::CreateRanking() // the overall variable importance is the average over all foams for (UInt_t ivar = 0; ivar < GetNvar(); ++ivar) { importance.at(ivar) += tmp_importance.at(ivar) / fFoam.size(); - } + } } // fill ranking vector @@ -857,7 +863,7 @@ void TMVA::MethodPDEFoam::GetNCuts(PDEFoamCell *cell, std::vector<UInt_t> &nCuts // // - nCuts - the number of cuts are saved in this vector - if (cell->GetStat() == 1) // cell is active + if (cell == NULL || cell->GetStat() == 1) // cell is active return; nCuts.at(cell->GetBest())++; @@ -902,7 +908,7 @@ TMVA::PDEFoam* TMVA::MethodPDEFoam::InitFoam(TString foamcaption, EFoamType ft, // - foamcaption - name of PDEFoam object // // - ft - type of PDEFoam - // Candidates are: + // Candidates are: // - kSeparate - creates TMVA::PDEFoamEvent // - kDiscr - creates TMVA::PDEFoamDiscriminant // - kMonoTarget - creates TMVA::PDEFoamTarget @@ -978,7 +984,7 @@ TMVA::PDEFoam* TMVA::MethodPDEFoam::InitFoam(TString foamcaption, EFoamType ft, sepType = new SdivSqrtSplusB(); break; default: - Log() << kFATAL << "Separation type " << fDTSeparation + Log() << kFATAL << "Separation type " << fDTSeparation << " currently not supported" << Endl; break; } @@ -1004,7 +1010,7 @@ TMVA::PDEFoam* TMVA::MethodPDEFoam::InitFoam(TString foamcaption, EFoamType ft, // set fLogger attributes pdefoam->Log().SetMinType(this->Log().GetMinType()); - + // set PDEFoam parameters pdefoam->SetDim( dim); pdefoam->SetnCells( fnCells); // optional @@ -1018,7 +1024,7 @@ TMVA::PDEFoam* TMVA::MethodPDEFoam::InitFoam(TString foamcaption, EFoamType ft, // Init PDEFoam pdefoam->Initialize(); - + // Set Xmin, Xmax SetXminXmax(pdefoam); @@ -1035,7 +1041,7 @@ const std::vector<Float_t>& TMVA::MethodPDEFoam::GetRegressionValues() fRegressionReturnVal->reserve(Data()->GetNTargets()); const Event* ev = GetEvent(); - std::vector<Float_t> vals = ev->GetValues(); // get array of event variables (non-targets) + std::vector<Float_t> vals = ev->GetValues(); // get array of event variables (non-targets) if (vals.empty()) { Log() << kWARNING << "<GetRegressionValues> value vector is empty. " << Endl; @@ -1057,7 +1063,7 @@ const std::vector<Float_t>& TMVA::MethodPDEFoam::GetRegressionValues() fRegressionReturnVal->push_back(targets.at(i)); } else { - fRegressionReturnVal->push_back(fFoam.at(0)->GetCellValue(vals, kValue, fKernelEstimator)); + fRegressionReturnVal->push_back(fFoam.at(0)->GetCellValue(vals, kValue, fKernelEstimator)); } // apply inverse transformation to regression values @@ -1101,7 +1107,7 @@ void TMVA::MethodPDEFoam::DeleteFoams() // Deletes all trained foams for (UInt_t i=0; i<fFoam.size(); i++) if (fFoam.at(i)) delete fFoam.at(i); - fFoam.clear(); + fFoam.clear(); } //_______________________________________________________________________ @@ -1119,11 +1125,11 @@ void TMVA::MethodPDEFoam::Reset() } //_______________________________________________________________________ -void TMVA::MethodPDEFoam::PrintCoefficients( void ) +void TMVA::MethodPDEFoam::PrintCoefficients( void ) {} //_______________________________________________________________________ -void TMVA::MethodPDEFoam::AddWeightsXMLTo( void* parent ) const +void TMVA::MethodPDEFoam::AddWeightsXMLTo( void* parent ) const { // create XML output of PDEFoam method variables @@ -1146,7 +1152,7 @@ void TMVA::MethodPDEFoam::AddWeightsXMLTo( void* parent ) const gTools().AddAttr( wght, "TargetSelection", TargetSelectionToUInt(fTargetSelection) ); gTools().AddAttr( wght, "FillFoamWithOrigWeights", fFillFoamWithOrigWeights ); gTools().AddAttr( wght, "UseYesNoCell", fUseYesNoCell ); - + // save foam borders Xmin[i], Xmax[i] void *xmin_wrap; for (UInt_t i=0; i<fXmin.size(); i++){ @@ -1166,17 +1172,17 @@ void TMVA::MethodPDEFoam::AddWeightsXMLTo( void* parent ) const } //_______________________________________________________________________ -void TMVA::MethodPDEFoam::WriteFoamsToFile() const +void TMVA::MethodPDEFoam::WriteFoamsToFile() const { // Write PDEFoams to file // fill variable names into foam - FillVariableNamesToFoam(); + FillVariableNamesToFoam(); - TString rfname( GetWeightFileName() ); + TString rfname( GetWeightFileName() ); // replace in case of txt weight file - rfname.ReplaceAll( TString(".") + gConfig().GetIONames().fWeightFileExtension + ".txt", ".xml" ); + rfname.ReplaceAll( TString(".") + gConfig().GetIONames().fWeightFileExtension + ".txt", ".xml" ); // add foam indicator to distinguish from main weight file rfname.ReplaceAll( ".xml", "_foams.root" ); @@ -1193,12 +1199,12 @@ void TMVA::MethodPDEFoam::WriteFoamsToFile() const } rootFile->Close(); - Log() << kINFO << "Foams written to file: " + Log() << kINFO << "Foams written to file: " << gTools().Color("lightblue") << rfname << gTools().Color("reset") << Endl; } //_______________________________________________________________________ -void TMVA::MethodPDEFoam::ReadWeightsFromStream( istream& istr ) +void TMVA::MethodPDEFoam::ReadWeightsFromStream( std::istream& istr ) { // read options and internal parameters @@ -1209,13 +1215,13 @@ void TMVA::MethodPDEFoam::ReadWeightsFromStream( istream& istr ) istr >> fnCells; // Number of Cells (500) istr >> fnSampl; // Number of MC events per cell in build-up (1000) istr >> fnBin; // Number of bins in build-up (100) - istr >> fEvPerBin; // Maximum events (equiv.) per bin in buid-up (1000) + istr >> fEvPerBin; // Maximum events (equiv.) per bin in buid-up (1000) istr >> fCompress; // compress output file Bool_t regr; istr >> regr; // regression foam SetAnalysisType( (regr ? Types::kRegression : Types::kClassification ) ); - + Bool_t CutNmin, CutRMSmin; // dummy for backwards compatib. Float_t RMSmin; // dummy for backwards compatib. istr >> CutNmin; // cut on minimal number of events in cell @@ -1244,9 +1250,9 @@ void TMVA::MethodPDEFoam::ReadWeightsFromStream( istream& istr ) fXmax.assign(kDim, 0); // read range - for (UInt_t i=0; i<kDim; i++) + for (UInt_t i=0; i<kDim; i++) istr >> fXmin.at(i); - for (UInt_t i=0; i<kDim; i++) + for (UInt_t i=0; i<kDim; i++) istr >> fXmax.at(i); // read pure foams from file @@ -1254,7 +1260,7 @@ void TMVA::MethodPDEFoam::ReadWeightsFromStream( istream& istr ) } //_______________________________________________________________________ -void TMVA::MethodPDEFoam::ReadWeightsFromXML( void* wghtnode ) +void TMVA::MethodPDEFoam::ReadWeightsFromXML( void* wghtnode ) { // read PDEFoam variables from xml weight file @@ -1286,7 +1292,7 @@ void TMVA::MethodPDEFoam::ReadWeightsFromXML( void* wghtnode ) gTools().ReadAttr( wghtnode, "FillFoamWithOrigWeights", fFillFoamWithOrigWeights ); if (gTools().HasAttr(wghtnode, "UseYesNoCell")) gTools().ReadAttr( wghtnode, "UseYesNoCell", fUseYesNoCell ); - + // clear old range [Xmin, Xmax] and prepare new range for reading fXmin.clear(); fXmax.clear(); @@ -1319,7 +1325,7 @@ void TMVA::MethodPDEFoam::ReadWeightsFromXML( void* wghtnode ) // if foams exist, delete them DeleteFoams(); - + // read pure foams from file ReadFoamsFromFile(); @@ -1375,7 +1381,7 @@ void TMVA::MethodPDEFoam::ReadFoamsFromFile() { // read foams from file - TString rfname( GetWeightFileName() ); + TString rfname( GetWeightFileName() ); // replace in case of txt weight file rfname.ReplaceAll( TString(".") + gConfig().GetIONames().fWeightFileExtension + ".txt", ".xml" ); @@ -1383,7 +1389,7 @@ void TMVA::MethodPDEFoam::ReadFoamsFromFile() // add foam indicator to distinguish from main weight file rfname.ReplaceAll( ".xml", "_foams.root" ); - Log() << kINFO << "Read foams from file: " << gTools().Color("lightblue") + Log() << kINFO << "Read foams from file: " << gTools().Color("lightblue") << rfname << gTools().Color("reset") << Endl; TFile *rootFile = new TFile( rfname, "READ" ); if (rootFile->IsZombie()) Log() << kFATAL << "Cannot open file \"" << rfname << "\"" << Endl; @@ -1453,7 +1459,7 @@ TMVA::ETargetSelection TMVA::MethodPDEFoam::UIntToTargetSelection(UInt_t its) } //_______________________________________________________________________ -void TMVA::MethodPDEFoam::FillVariableNamesToFoam() const +void TMVA::MethodPDEFoam::FillVariableNamesToFoam() const { // store the variable names in all foams for (UInt_t ifoam=0; ifoam<fFoam.size(); ifoam++) { @@ -1463,7 +1469,7 @@ void TMVA::MethodPDEFoam::FillVariableNamesToFoam() const else fFoam.at(ifoam)->AddVariableName(DataInfo().GetVariableInfo(idim).GetExpression().Data()); } - } + } } //_______________________________________________________________________ diff --git a/tmva/src/MethodPDERS.cxx b/tmva/src/MethodPDERS.cxx index ec2d0f2870588..a5daa555e957e 100644 --- a/tmva/src/MethodPDERS.cxx +++ b/tmva/src/MethodPDERS.cxx @@ -1102,7 +1102,7 @@ void TMVA::MethodPDERS::ReadWeightsFromXML( void* wghtnode) } //_______________________________________________________________________ -void TMVA::MethodPDERS::ReadWeightsFromStream( istream& istr) +void TMVA::MethodPDERS::ReadWeightsFromStream( std::istream& istr) { // read weight info from file if (NULL != fBinaryTree) delete fBinaryTree; diff --git a/tmva/src/MethodRuleFit.cxx b/tmva/src/MethodRuleFit.cxx index 30568214d0fe5..1137a7e96959b 100644 --- a/tmva/src/MethodRuleFit.cxx +++ b/tmva/src/MethodRuleFit.cxx @@ -51,6 +51,8 @@ #include "TMVA/Config.h" #include "TMVA/MsgLogger.h" +using std::min; + REGISTER_METHOD(RuleFit) ClassImp(TMVA::MethodRuleFit) @@ -512,7 +514,14 @@ void TMVA::MethodRuleFit::TrainJFRuleFit( void ) // training of rules using Jerome Friedmans implementation fRuleFit.InitPtrs( this ); - fRuleFit.SetTrainingEvents( GetTrainingEvents() ); + Data()->SetCurrentType(Types::kTraining); + UInt_t nevents = Data()->GetNTrainingEvents(); + std::vector<const TMVA::Event*> tmp; + for (Long64_t ievt=0; ievt<nevents; ievt++) { + const Event *event = GetEvent(ievt); + tmp.push_back(event); + } + fRuleFit.SetTrainingEvents( tmp ); RuleFitAPI *rfAPI = new RuleFitAPI( this, &fRuleFit, Log().GetMinType() ); @@ -565,9 +574,9 @@ void TMVA::MethodRuleFit::AddWeightsXMLTo( void* parent ) const } //_______________________________________________________________________ -void TMVA::MethodRuleFit::ReadWeightsFromStream( istream & istr ) +void TMVA::MethodRuleFit::ReadWeightsFromStream( std::istream & istr ) { - // read rules from an istream + // read rules from an std::istream fRuleFit.GetRuleEnsemblePtr()->ReadRaw( istr ); } @@ -609,7 +618,7 @@ void TMVA::MethodRuleFit::MakeClassSpecific( std::ostream& fout, const TString& fout << "void " << className << "::Initialize(){}" << std::endl; fout << "void " << className << "::Clear(){}" << std::endl; fout << "double " << className << "::GetMvaValue__( const std::vector<double>& inputValues ) const {" << std::endl; - fout << " double rval=" << setprecision(10) << fRuleFit.GetRuleEnsemble().GetOffset() << ";" << std::endl; + fout << " double rval=" << std::setprecision(10) << fRuleFit.GetRuleEnsemble().GetOffset() << ";" << std::endl; MakeClassRuleCuts(fout); MakeClassLinear(fout); fout << " return rval;" << std::endl; @@ -659,16 +668,16 @@ void TMVA::MethodRuleFit::MakeClassRuleCuts( std::ostream& fout ) const // if (ic>0) fout << "&&" << std::flush; if (domin) { - fout << "(" << setprecision(10) << valmin << std::flush; + fout << "(" << std::setprecision(10) << valmin << std::flush; fout << "<inputValues[" << sel << "])" << std::flush; } if (domax) { if (domin) fout << "&&" << std::flush; fout << "(inputValues[" << sel << "]" << std::flush; - fout << "<" << setprecision(10) << valmax << ")" <<std::flush; + fout << "<" << std::setprecision(10) << valmax << ")" <<std::flush; } } - fout << ") rval+=" << setprecision(10) << (*rules)[ir]->GetCoefficient() << ";" << std::flush; + fout << ") rval+=" << std::setprecision(10) << (*rules)[ir]->GetCoefficient() << ";" << std::flush; fout << " // importance = " << Form("%3.3f",impr) << std::endl; } fout << std::setprecision(dp); @@ -695,11 +704,11 @@ void TMVA::MethodRuleFit::MakeClassLinear( std::ostream& fout ) const Double_t norm = rens->GetLinNorm(il); Double_t imp = rens->GetLinImportance(il)/rens->GetImportanceRef(); fout << " rval+=" - // << setprecision(10) << rens->GetLinCoefficients(il)*norm << "*std::min(" << setprecision(10) << rens->GetLinDP(il) - // << ", std::max( inputValues[" << il << "]," << setprecision(10) << rens->GetLinDM(il) << "));" - << setprecision(10) << rens->GetLinCoefficients(il)*norm - << "*std::min( double(" << setprecision(10) << rens->GetLinDP(il) - << "), std::max( double(inputValues[" << il << "]), double(" << setprecision(10) << rens->GetLinDM(il) << ")));" + // << std::setprecision(10) << rens->GetLinCoefficients(il)*norm << "*std::min(" << setprecision(10) << rens->GetLinDP(il) + // << ", std::max( inputValues[" << il << "]," << std::setprecision(10) << rens->GetLinDM(il) << "));" + << std::setprecision(10) << rens->GetLinCoefficients(il)*norm + << "*std::min( double(" << std::setprecision(10) << rens->GetLinDP(il) + << "), std::max( double(inputValues[" << il << "]), double(" << std::setprecision(10) << rens->GetLinDM(il) << ")));" << std::flush; fout << " // importance = " << Form("%3.3f",imp) << std::endl; } diff --git a/tmva/src/MethodSVM.cxx b/tmva/src/MethodSVM.cxx index 65f28305f173c..004f34186355b 100644 --- a/tmva/src/MethodSVM.cxx +++ b/tmva/src/MethodSVM.cxx @@ -65,6 +65,8 @@ #include <string> +using std::vector; + const Int_t basketsize__ = 1280000; REGISTER_METHOD(SVM) @@ -144,7 +146,10 @@ void TMVA::MethodSVM::Init() // SVM always uses normalised input variables SetNormalised( kTRUE ); - fInputData = new std::vector<TMVA::SVEvent*>(Data()->GetNEvents()); + // Helge: do not book a event vector of given size but rather fill the vector + // later with pus_back. Anyway, this is NOT what is time consuming in + // SVM and it allows to skip totally events with weights == 0 ;) + fInputData = new std::vector<TMVA::SVEvent*>(0); fSupportVectors = new std::vector<TMVA::SVEvent*>(0); } @@ -152,6 +157,10 @@ void TMVA::MethodSVM::Init() void TMVA::MethodSVM::DeclareOptions() { // declare options available for this method + + // for gaussian kernel parameter(s) + DeclareOptionRef( fGamma = 1., "Gamma", "RBF kernel parameter: Gamma (size of the Kernel)"); + DeclareOptionRef( fCost, "C", "Cost parameter" ); if (DoRegression()) { fCost = 0.002; @@ -160,16 +169,15 @@ void TMVA::MethodSVM::DeclareOptions() } DeclareOptionRef( fTolerance = 0.01, "Tol", "Tolerance parameter" ); //should be fixed DeclareOptionRef( fMaxIter = 1000, "MaxIter", "Maximum number of training loops" ); - DeclareOptionRef( fNSubSets = 1, "NSubSets", "Number of training subsets" ); - // for gaussian kernel parameter(s) - DeclareOptionRef( fGamma = 1., "Gamma", "RBF kernel parameter: Gamma"); } //_______________________________________________________________________ void TMVA::MethodSVM::DeclareCompatibilityOptions() { + // options that are used ONLY for the READER to ensure backward compatibility MethodBase::DeclareCompatibilityOptions(); + DeclareOptionRef( fNSubSets = 1, "NSubSets", "Number of training subsets" ); DeclareOptionRef( fTheKernel = "Gauss", "Kernel", "Uses kernel function"); // for gaussian kernel parameter(s) DeclareOptionRef( fDoubleSigmaSquared = 2., "Sigma", "Kernel parameter: sigma"); @@ -198,14 +206,15 @@ void TMVA::MethodSVM::Train() // Train SVM Data()->SetCurrentType(Types::kTraining); + Log() << kDEBUG << "Create event vector"<< Endl; for (Int_t ievt=0; ievt<Data()->GetNEvents(); ievt++){ - Log() << kDEBUG << "Create event vector"<< Endl; - fInputData->at(ievt) = new SVEvent(GetEvent(ievt), fCost, DataInfo().IsSignal(GetEvent(ievt))); + if (GetEvent(ievt)->GetWeight() != 0) + fInputData->push_back(new SVEvent(GetEvent(ievt), fCost, DataInfo().IsSignal(GetEvent(ievt)))); } fSVKernelFunction = new SVKernelFunction(fGamma); - Log()<< kINFO << "Building SVM Working Set..."<< Endl; + Log()<< kINFO << "Building SVM Working Set...with "<<fInputData->size()<<" event instances"<< Endl; Timer bldwstime( GetName()); fWgSet = new SVWorkingSet( fInputData, fSVKernelFunction,fTolerance, DoRegression() ); Log() << kINFO <<"Elapsed time for Working Set build: "<< bldwstime.GetElapsedTime()<<Endl; @@ -221,6 +230,14 @@ void TMVA::MethodSVM::Train() fBparm = fWgSet->GetBpar(); fSupportVectors = fWgSet->GetSupportVectors(); + + + delete fWgSet; + fWgSet=0; + + // for (UInt_t i=0; i<fInputData->size();i++) delete fInputData->at(i); + delete fInputData; + fInputData=0; } //_______________________________________________________________________ @@ -310,7 +327,7 @@ void TMVA::MethodSVM::WriteWeightsToStream( TFile& ) const } //_______________________________________________________________________ -void TMVA::MethodSVM::ReadWeightsFromStream( istream& istr ) +void TMVA::MethodSVM::ReadWeightsFromStream( std::istream& istr ) { if (fSupportVectors !=0) { delete fSupportVectors; fSupportVectors = 0;} fSupportVectors = new std::vector<TMVA::SVEvent*>(0); @@ -432,75 +449,75 @@ void TMVA::MethodSVM::MakeClassSpecific( std::ostream& fout, const TString& clas { // write specific classifier response const int fNsupv = fSupportVectors->size(); - fout << " // not implemented for class: \"" << className << "\"" << endl; - fout << " float fBparameter;" << endl; - fout << " int fNOfSuppVec;" << endl; - fout << " static float fAllSuppVectors[][" << fNsupv << "];" << endl; - fout << " static float fAlphaTypeCoef[" << fNsupv << "];" << endl; - fout << endl; - fout << " // Kernel parameter(s) " << endl; - fout << " float fGamma;" << endl; - fout << "};" << endl; - fout << "" << endl; + fout << " // not implemented for class: \"" << className << "\"" << std::endl; + fout << " float fBparameter;" << std::endl; + fout << " int fNOfSuppVec;" << std::endl; + fout << " static float fAllSuppVectors[][" << fNsupv << "];" << std::endl; + fout << " static float fAlphaTypeCoef[" << fNsupv << "];" << std::endl; + fout << std::endl; + fout << " // Kernel parameter(s) " << std::endl; + fout << " float fGamma;" << std::endl; + fout << "};" << std::endl; + fout << "" << std::endl; //Initialize function definition - fout << "inline void " << className << "::Initialize() " << endl; - fout << "{" << endl; - fout << " fBparameter = " << fBparm << ";" << endl; - fout << " fNOfSuppVec = " << fNsupv << ";" << endl; - fout << " fGamma = " << fGamma << ";" <<endl; - fout << "}" << endl; - fout << endl; + fout << "inline void " << className << "::Initialize() " << std::endl; + fout << "{" << std::endl; + fout << " fBparameter = " << fBparm << ";" << std::endl; + fout << " fNOfSuppVec = " << fNsupv << ";" << std::endl; + fout << " fGamma = " << fGamma << ";" <<std::endl; + fout << "}" << std::endl; + fout << std::endl; // GetMvaValue__ function defninition - fout << "inline double " << className << "::GetMvaValue__(const std::vector<double>& inputValues ) const" << endl; - fout << "{" << endl; - fout << " double mvaval = 0; " << endl; - fout << " double temp = 0; " << endl; - fout << endl; - fout << " for (int ievt = 0; ievt < fNOfSuppVec; ievt++ ){" << endl; - fout << " temp = 0;" << endl; - fout << " for ( unsigned int ivar = 0; ivar < GetNvar(); ivar++ ) {" << endl; - - fout << " temp += (fAllSuppVectors[ivar][ievt] - inputValues[ivar]) " << endl; - fout << " * (fAllSuppVectors[ivar][ievt] - inputValues[ivar]); " << endl; - fout << " }" << endl; - fout << " mvaval += fAlphaTypeCoef[ievt] * exp( -fGamma * temp ); " << endl; - - fout << " }" << endl; - fout << " mvaval -= fBparameter;" << endl; - fout << " return 1./(1. + exp(mvaval));" << endl; - fout << "}" << endl; - fout << "// Clean up" << endl; - fout << "inline void " << className << "::Clear() " << endl; - fout << "{" << endl; - fout << " // nothing to clear " << endl; - fout << "}" << endl; - fout << "" << endl; + fout << "inline double " << className << "::GetMvaValue__(const std::vector<double>& inputValues ) const" << std::endl; + fout << "{" << std::endl; + fout << " double mvaval = 0; " << std::endl; + fout << " double temp = 0; " << std::endl; + fout << std::endl; + fout << " for (int ievt = 0; ievt < fNOfSuppVec; ievt++ ){" << std::endl; + fout << " temp = 0;" << std::endl; + fout << " for ( unsigned int ivar = 0; ivar < GetNvar(); ivar++ ) {" << std::endl; + + fout << " temp += (fAllSuppVectors[ivar][ievt] - inputValues[ivar]) " << std::endl; + fout << " * (fAllSuppVectors[ivar][ievt] - inputValues[ivar]); " << std::endl; + fout << " }" << std::endl; + fout << " mvaval += fAlphaTypeCoef[ievt] * exp( -fGamma * temp ); " << std::endl; + + fout << " }" << std::endl; + fout << " mvaval -= fBparameter;" << std::endl; + fout << " return 1./(1. + exp(mvaval));" << std::endl; + fout << "}" << std::endl; + fout << "// Clean up" << std::endl; + fout << "inline void " << className << "::Clear() " << std::endl; + fout << "{" << std::endl; + fout << " // nothing to clear " << std::endl; + fout << "}" << std::endl; + fout << "" << std::endl; // define support vectors - fout << "float " << className << "::fAlphaTypeCoef[] =" << endl; + fout << "float " << className << "::fAlphaTypeCoef[] =" << std::endl; fout << "{ "; for (Int_t isv = 0; isv < fNsupv; isv++) { fout << fSupportVectors->at(isv)->GetDeltaAlpha() * fSupportVectors->at(isv)->GetTypeFlag(); if (isv < fNsupv-1) fout << ", "; } - fout << " };" << endl << endl; + fout << " };" << std::endl << std::endl; - fout << "float " << className << "::fAllSuppVectors[][" << fNsupv << "] =" << endl; + fout << "float " << className << "::fAllSuppVectors[][" << fNsupv << "] =" << std::endl; fout << "{"; for (UInt_t ivar = 0; ivar < GetNvar(); ivar++) { - fout << endl; + fout << std::endl; fout << " { "; for (Int_t isv = 0; isv < fNsupv; isv++){ fout << fSupportVectors->at(isv)->GetDataVector()->at(ivar); if (isv < fNsupv-1) fout << ", "; } fout << " }"; - if (ivar < GetNvar()-1) fout << ", " << endl; - else fout << endl; + if (ivar < GetNvar()-1) fout << ", " << std::endl; + else fout << std::endl; } - fout << "};" << endl<< endl; + fout << "};" << std::endl<< std::endl; } //_______________________________________________________________________ diff --git a/tmva/src/MethodTMlpANN.cxx b/tmva/src/MethodTMlpANN.cxx index c5afab1902901..ad6c889925bf1 100644 --- a/tmva/src/MethodTMlpANN.cxx +++ b/tmva/src/MethodTMlpANN.cxx @@ -65,6 +65,8 @@ End_Html */ #include "TMVA/Tools.h" #endif +using std::atoi; + // some additional TMlpANN options const Bool_t EnforceNormalization__=kTRUE; #if ROOT_VERSION_CODE > ROOT_VERSION(5,13,06) @@ -425,7 +427,7 @@ void TMVA::MethodTMlpANN::ReadWeightsFromXML( void* wghtnode ) } //_______________________________________________________________________ -void TMVA::MethodTMlpANN::ReadWeightsFromStream( istream& istr ) +void TMVA::MethodTMlpANN::ReadWeightsFromStream( std::istream& istr ) { // read weights from stream // since the MLP can not read from the stream, we diff --git a/tmva/src/ModulekNN.cxx b/tmva/src/ModulekNN.cxx index 53e3f90b49693..0018a579bc104 100644 --- a/tmva/src/ModulekNN.cxx +++ b/tmva/src/ModulekNN.cxx @@ -646,7 +646,7 @@ void TMVA::kNN::ModulekNN::Print() const } //------------------------------------------------------------------------------------------- -void TMVA::kNN::ModulekNN::Print(ostream &os) const +void TMVA::kNN::ModulekNN::Print(std::ostream &os) const { // print os << "----------------------------------------------------------------------"<< std::endl; diff --git a/tmva/src/Node.cxx b/tmva/src/Node.cxx index edbdf1e7eb63c..0c10ae133da99 100644 --- a/tmva/src/Node.cxx +++ b/tmva/src/Node.cxx @@ -121,7 +121,7 @@ Int_t TMVA::Node::CountMeAndAllDaughters() const // print a node //_______________________________________________________________________ -ostream& TMVA::operator<<( ostream& os, const TMVA::Node& node ) +std::ostream& TMVA::operator<<( std::ostream& os, const TMVA::Node& node ) { // output operator for a node node.Print(os); @@ -129,7 +129,7 @@ ostream& TMVA::operator<<( ostream& os, const TMVA::Node& node ) } //_______________________________________________________________________ -ostream& TMVA::operator<<( ostream& os, const TMVA::Node* node ) +std::ostream& TMVA::operator<<( std::ostream& os, const TMVA::Node* node ) { // output operator with a pointer to the node (which still prints the node itself) if (node!=NULL) node->Print(os); diff --git a/tmva/src/OptimizeConfigParameters.cxx b/tmva/src/OptimizeConfigParameters.cxx index 74ae77014b04c..12c349bd57945 100644 --- a/tmva/src/OptimizeConfigParameters.cxx +++ b/tmva/src/OptimizeConfigParameters.cxx @@ -42,7 +42,7 @@ ClassImp(TMVA::OptimizeConfigParameters) //_______________________________________________________________________ -TMVA::OptimizeConfigParameters::OptimizeConfigParameters(MethodBase * const method, std::map<TString,TMVA::Interval> tuneParameters, TString fomType, TString optimizationFitType) +TMVA::OptimizeConfigParameters::OptimizeConfigParameters(MethodBase * const method, std::map<TString,TMVA::Interval*> tuneParameters, TString fomType, TString optimizationFitType) : fMethod(method), fTuneParameters(tuneParameters), fFOMType(fomType), @@ -50,7 +50,8 @@ TMVA::OptimizeConfigParameters::OptimizeConfigParameters(MethodBase * const meth fMvaSig(NULL), fMvaBkg(NULL), fMvaSigFineBin(NULL), - fMvaBkgFineBin(NULL) + fMvaBkgFineBin(NULL), + fNotDoneYet(kFALSE) { // Constructor which sets either "Classification or Regression" std::string name = "OptimizeConfigParameters_"; @@ -64,12 +65,12 @@ TMVA::OptimizeConfigParameters::OptimizeConfigParameters(MethodBase * const meth Log() << kINFO << "Automatic optimisation of tuning parameters in " << GetMethod()->GetName() << " uses:" << Endl; - std::map<TString,TMVA::Interval>::iterator it; + std::map<TString,TMVA::Interval*>::iterator it; for (it=fTuneParameters.begin(); it!=fTuneParameters.end();it++) { Log() << kINFO << it->first - << " in range from: " << it->second.GetMin() - << " to: " << it->second.GetMax() - << " in : " << it->second.GetNbins() << " steps" + << " in range from: " << it->second->GetMin() + << " to: " << it->second->GetMax() + << " in : " << it->second->GetNbins() << " steps" << Endl; } Log() << kINFO << " using the options: " << fFOMType << " and " << fOptimizationFitType << Endl; @@ -120,7 +121,7 @@ std::map<TString,Double_t> TMVA::OptimizeConfigParameters::optimize() Log() << kINFO << "For " << GetMethod()->GetName() << " the optimized Parameters are: " << Endl; std::map<TString,Double_t>::iterator it; for(it=fTunedParameters.begin(); it!= fTunedParameters.end(); it++){ - Log() << kINFO << it->first << " = " << it->second << Endl; + Log() << kINFO << it->first << " = " << it->second << Endl; } return fTunedParameters; @@ -150,7 +151,7 @@ void TMVA::OptimizeConfigParameters::optimizeScan() Double_t bestFOM=-1000000, currentFOM; std::map<TString,Double_t> currentParameters; - std::map<TString,TMVA::Interval>::iterator it; + std::map<TString,TMVA::Interval*>::iterator it; // for the scan, start at the lower end of the interval and then "move upwards" // initialize all parameters in currentParameter @@ -158,8 +159,8 @@ void TMVA::OptimizeConfigParameters::optimizeScan() fTunedParameters.clear(); for (it=fTuneParameters.begin(); it!=fTuneParameters.end(); it++){ - currentParameters.insert(std::pair<TString,Double_t>(it->first,it->second.GetMin())); - fTunedParameters.insert(std::pair<TString,Double_t>(it->first,it->second.GetMin())); + currentParameters.insert(std::pair<TString,Double_t>(it->first,it->second->GetMin())); + fTunedParameters.insert(std::pair<TString,Double_t>(it->first,it->second->GetMin())); } // now loop over all the parameters and get for each combination the figure of merit @@ -169,8 +170,8 @@ void TMVA::OptimizeConfigParameters::optimizeScan() std::vector< std::vector <Double_t> > v; for (it=fTuneParameters.begin(); it!=fTuneParameters.end(); it++){ std::vector< Double_t > tmp; - for (Int_t k=0; k<it->second.GetNbins(); k++){ - tmp.push_back(it->second.GetElement(k)); + for (Int_t k=0; k<it->second->GetNbins(); k++){ + tmp.push_back(it->second->GetElement(k)); } v.push_back(tmp); } @@ -199,9 +200,11 @@ void TMVA::OptimizeConfigParameters::optimizeScan() GetMethod()->SetTuneParameters(currentParameters); // now do the training for the current parameters: GetMethod()->BaseDir()->cd(); - GetMethod()->GetTransformationHandler().CalcTransformations( + if (i==0) GetMethod()->GetTransformationHandler().CalcTransformations( GetMethod()->Data()->GetEventCollection()); + Event::SetIsTraining(kTRUE); GetMethod()->Train(); + Event::SetIsTraining(kFALSE); currentFOM = GetFOM(); Log() << kINFO << "FOM was found : " << currentFOM << "; current best is " << bestFOM << Endl; @@ -222,12 +225,12 @@ void TMVA::OptimizeConfigParameters::optimizeFit() { // ranges (intervals) in which the fit varies the parameters std::vector<TMVA::Interval*> ranges; // intervals of the fit ranges - std::map<TString, TMVA::Interval>::iterator it; + std::map<TString, TMVA::Interval*>::iterator it; std::vector<Double_t> pars; // current (starting) fit parameters for (it=fTuneParameters.begin(); it != fTuneParameters.end(); it++){ - ranges.push_back(new TMVA::Interval(it->second)); - pars.push_back( (it->second).GetMean() ); // like this the order is "right". Always keep the + ranges.push_back(new TMVA::Interval(*(it->second))); + pars.push_back( (it->second)->GetMean() ); // like this the order is "right". Always keep the // order in the vector "pars" the same as the iterator // iterates through the tuneParameters !!!! } @@ -293,7 +296,7 @@ Double_t TMVA::OptimizeConfigParameters::EstimatorFunction( std::vector<Double_t std::map<TString,Double_t> currentParameters; Int_t icount =0; // map "pars" to the map of Tuneparameter, make sure // you never screw up this order!! - std::map<TString, TMVA::Interval>::iterator it; + std::map<TString, TMVA::Interval*>::iterator it; for (it=fTuneParameters.begin(); it!=fTuneParameters.end(); it++){ currentParameters[it->first] = pars[icount++]; } @@ -301,10 +304,15 @@ Double_t TMVA::OptimizeConfigParameters::EstimatorFunction( std::vector<Double_t GetMethod()->SetTuneParameters(currentParameters); GetMethod()->BaseDir()->cd(); - GetMethod()->GetTransformationHandler().CalcTransformations( - GetMethod()->Data()->GetEventCollection()); - + if (fNotDoneYet){ + GetMethod()->GetTransformationHandler(). + CalcTransformations(GetMethod()->Data()->GetEventCollection()); + fNotDoneYet=kFALSE; + } + Event::SetIsTraining(kTRUE); GetMethod()->Train(); + Event::SetIsTraining(kFALSE); + Double_t currentFOM = GetFOM(); @@ -329,6 +337,7 @@ Double_t TMVA::OptimizeConfigParameters::GetFOM() else if (fFOMType == "ROCIntegral") fom = GetROCIntegral(); else if (fFOMType == "SigEffAtBkgEff01") fom = GetSigEffAtBkgEff(0.1); else if (fFOMType == "SigEffAtBkgEff001") fom = GetSigEffAtBkgEff(0.01); + else if (fFOMType == "SigEffAtBkgEff002") fom = GetSigEffAtBkgEff(0.02); else if (fFOMType == "BkgRejAtSigEff05") fom = GetBkgRejAtSigEff(0.5); else if (fFOMType == "BkgEffAtSigEff05") fom = GetBkgEffAtSigEff(0.5); else { @@ -338,6 +347,7 @@ Double_t TMVA::OptimizeConfigParameters::GetFOM() } } fFOMvsIter.push_back(fom); + // std::cout << "fom="<<fom<<std::endl; // should write that into a debug log (as option) return fom; } @@ -362,7 +372,7 @@ void TMVA::OptimizeConfigParameters::GetMVADists() fMvaSigFineBin = new TH1D("fMvaSigFineBin","",100000,-1.5,1.5); fMvaBkgFineBin = new TH1D("fMvaBkgFineBin","",100000,-1.5,1.5); - const std::vector<Event*> events=fMethod->Data()->GetEventCollection(Types::kTesting); + const std::vector< Event*> events=fMethod->Data()->GetEventCollection(Types::kTesting); UInt_t signalClassNr = fMethod->DataInfo().GetClassInfo("Signal")->GetNumber(); diff --git a/tmva/src/PDEFoam.cxx b/tmva/src/PDEFoam.cxx index b4fcfed388145..a3339d7f3d548 100644 --- a/tmva/src/PDEFoam.cxx +++ b/tmva/src/PDEFoam.cxx @@ -438,7 +438,7 @@ void TMVA::PDEFoam::Explore(PDEFoamCell *cell) // information is used withing PeekMax() to avoid splitting cells // which contain less than fNmin events. - Double_t wt, dx, xBest, yBest; + Double_t wt, dx, xBest=0, yBest; Double_t intOld, driOld; Long_t iev; @@ -492,8 +492,8 @@ void TMVA::PDEFoam::Explore(PDEFoamCell *cell) if (fDim>0) for (j=0; j<fDim; j++) xRand[j]= cellPosi[j] +fAlpha[j]*(cellSize[j]); wt = dx*Eval(xRand, event_density); - totevents += dx*event_density; - + totevents += event_density; + nProj = 0; if (fDim>0) { for (k=0; k<fDim; k++) { @@ -509,10 +509,13 @@ void TMVA::PDEFoam::Explore(PDEFoamCell *cell) if (ceSum[3]>wt) ceSum[3]=wt; // minimum weight; if (ceSum[4]<wt) ceSum[4]=wt; // maximum weight // test MC loop exit condition - nevEff = ceSum[0]*ceSum[0]/ceSum[1]; + if (ceSum[1]>0) nevEff = ceSum[0]*ceSum[0]/ceSum[1]; + else nevEff = 0; if ( nevEff >= fNBin*fEvPerBin) break; } // ||||||||||||||||||||||||||END MC LOOP||||||||||||||||||||||||||||| - totevents /= fNSampl; + totevents *= dx; + + if (fNSampl>0) totevents /= fNSampl; // make shure that, if root cell is explored, more than zero // events were found. @@ -651,7 +654,7 @@ Long_t TMVA::PDEFoam::PeekMax() Long_t iCell = -1; Long_t i; - Double_t drivMax, driv; + Double_t drivMax, driv, xDiv; Bool_t bCutNmin = kTRUE; Bool_t bCutMaxDepth = kTRUE; // drivMax = kVlow; @@ -659,10 +662,15 @@ Long_t TMVA::PDEFoam::PeekMax() for(i=0; i<=fLastCe; i++) {//without root if( fCells[i]->GetStat() == 1 ) { // if driver integral < numeric limit, skip cell - if (fCells[i]->GetDriv() < std::numeric_limits<float>::epsilon()) + driv = fCells[i]->GetDriv(); + if (driv < std::numeric_limits<float>::epsilon()) continue; - driv = TMath::Abs( fCells[i]->GetDriv()); + // do not split cell at the edges + xDiv = TMath::Abs(fCells[i]->GetXdiv()); + if (xDiv <= std::numeric_limits<Double_t>::epsilon() || + xDiv >= 1.0 - std::numeric_limits<Double_t>::epsilon()) + continue; // apply cut on depth if (GetMaxDepth() > 0) @@ -682,10 +690,10 @@ Long_t TMVA::PDEFoam::PeekMax() if (iCell == -1){ if (!bCutNmin) - Log() << kVERBOSE << "Warning: No cell with more than " + Log() << kVERBOSE << "Warning: No cell with more than " << GetNmin() << " events found!" << Endl; else if (!bCutMaxDepth) - Log() << kVERBOSE << "Warning: Maximum depth reached: " + Log() << kVERBOSE << "Warning: Maximum depth reached: " << GetMaxDepth() << Endl; else Log() << kWARNING << "<PDEFoam::PeekMax>: no more candidate cells (drivMax>0) found for further splitting." << Endl; @@ -738,7 +746,7 @@ Double_t TMVA::PDEFoam::Eval(Double_t *xRand, Double_t &event_density) { // Internal subprogram. // Evaluates (training) distribution. - + // Transform variable xRand, since Foam boundaries are [0,1] and // fDistr is filled with events which range in [fXmin,fXmax] // @@ -889,7 +897,7 @@ void TMVA::PDEFoam::PrintCell(Long_t iCell) if (iCell < 0 || iCell > fLastCe) { Log() << kWARNING << "<PrintCell(iCell=" << iCell - << ")>: cell number " << iCell << " out of bounds!" + << ")>: cell number " << iCell << " out of bounds!" << Endl; return; } @@ -994,7 +1002,7 @@ Float_t TMVA::PDEFoam::GetCellValue(const std::vector<Float_t> &xvec, ECellValue // variables. // // Parameters: - // + // // - xvec - event vector (untransformed, [fXmin,fXmax]) // // - cv - the cell value to return @@ -1006,7 +1014,7 @@ Float_t TMVA::PDEFoam::GetCellValue(const std::vector<Float_t> &xvec, ECellValue // // The cell value, corresponding to 'xvec', estimated by the given // kernel. - + std::vector<Float_t> txvec(VarTransform(xvec)); if (kernel == NULL) return GetCellValue(FindCell(txvec), cv); @@ -1045,7 +1053,7 @@ std::vector<Float_t> TMVA::PDEFoam::GetCellValue( const std::map<Int_t,Float_t>& // get the cell values std::vector<Float_t> cell_values; cell_values.reserve(cells.size()); - for (std::vector<PDEFoamCell*>::const_iterator cell_it=cells.begin(); + for (std::vector<PDEFoamCell*>::const_iterator cell_it=cells.begin(); cell_it != cells.end(); ++cell_it) cell_values.push_back(GetCellValue(*cell_it, cv)); @@ -1210,8 +1218,8 @@ TH1D* TMVA::PDEFoam::Draw1Dim( ECellValue cell_value, Int_t nbin, PDEFoamKernelB // - kernel - a PDEFoam kernel. // avoid plotting of wrong dimensions - if ( GetTotDim()!=1 ) - Log() << kFATAL << "<Draw1Dim>: function can only be used for 1-dimensional foams!" + if ( GetTotDim()!=1 ) + Log() << kFATAL << "<Draw1Dim>: function can only be used for 1-dimensional foams!" << Endl; TString hname("h_1dim"); @@ -1276,7 +1284,7 @@ TH2D* TMVA::PDEFoam::Project2( Int_t idim1, Int_t idim2, ECellValue cell_value, << " Using 1000 bins for each dimension instead." << Endl; nbin = 1000; } else if (nbin<1) { - Log() << kWARNING << "Wrong bin number: " << nbin + Log() << kWARNING << "Wrong bin number: " << nbin << "; set nbin=50" << Endl; nbin = 50; } @@ -1308,7 +1316,7 @@ TH2D* TMVA::PDEFoam::Project2( Int_t idim1, Int_t idim2, ECellValue cell_value, // loop over cells and fill the histogram with the cell // values Float_t sum_cv = 0; // sum of the cell values - for (std::vector<TMVA::PDEFoamCell*>::const_iterator it = cells.begin(); + for (std::vector<TMVA::PDEFoamCell*>::const_iterator it = cells.begin(); it != cells.end(); ++it) { // get cell position and size PDEFoamVect cellPosi(GetTotDim()), cellSize(GetTotDim()); @@ -1357,7 +1365,7 @@ Float_t TMVA::PDEFoam::GetCellValue(const PDEFoamCell* cell, ECellValue cv) return GetCellElement(cell, 1); case kValueDensity: { - + Double_t volume = cell->GetVolume(); if (volume > numeric_limits<double>::epsilon()) { return GetCellValue(cell, kValue)/volume; @@ -1435,7 +1443,7 @@ void TMVA::PDEFoam::SetCellElement( PDEFoamCell *cell, UInt_t i, Double_t value } else { // dynamic_cast doesn't seem to work here ?! vec = (TVectorD*)cell->GetElement(); - if (!vec) + if (!vec) Log() << kFATAL << "<SetCellElement> ERROR: cell element is not a TVectorD*" << Endl; // check vector size and resize if necessary if (i >= (UInt_t) vec->GetNrows()) @@ -1482,7 +1490,7 @@ void TMVA::PDEFoam::RootPlot2dim( const TString& filename, TString opt, // unified foam // - target - in case of mono-target regression // If none of {cell_value, rms, rms_ov_mean} is given, the cells - // will not be filled. + // will not be filled. // If 'opt' contains the string 'cellnumber', the index of // each cell is draw in addition. // @@ -1543,9 +1551,9 @@ void TMVA::PDEFoam::RootPlot2dim( const TString& filename, TString opt, outfile<<"a->SetFillStyle(0);"<<std::endl; // big frame outfile<<"a->SetLineWidth(4);"<<std::endl; outfile<<"TBox *b1=new TBox();"<<std::endl; // single cell - outfile<<"TText*t=new TText();"<<endl; // text for numbering + outfile<<"TText*t=new TText();"<<std::endl; // text for numbering if (fillcells) { - outfile << (colors ? "gStyle->SetPalette(1, 0);" : "gStyle->SetPalette(0);") + outfile << (colors ? "gStyle->SetPalette(1, 0);" : "gStyle->SetPalette(0);") << std::endl; outfile <<"b1->SetFillStyle(1001);"<<std::endl; outfile<<"TBox *b2=new TBox();"<<std::endl; // single cell @@ -1563,7 +1571,7 @@ void TMVA::PDEFoam::RootPlot2dim( const TString& filename, TString opt, // if cells shall be filled, calculate minimal and maximal plot // value --> store in zmin and zmax - if (fillcells) { + if (fillcells) { for (Long_t iCell=1; iCell<=fLastCe; iCell++) { if ( fCells[iCell]->GetStat() == 1) { Float_t value = GetCellValue(fCells[iCell], cell_value); @@ -1595,11 +1603,11 @@ void TMVA::PDEFoam::RootPlot2dim( const TString& filename, TString opt, for (Long_t iCell=1; iCell<=fLastCe; iCell++) { if ( fCells[iCell]->GetStat() == 1) { fCells[iCell]->GetHcub(cellPosi,cellSize); - x1 = offs+lpag*(cellPosi[0]); + x1 = offs+lpag*(cellPosi[0]); y1 = offs+lpag*(cellPosi[1]); - x2 = offs+lpag*(cellPosi[0]+cellSize[0]); + x2 = offs+lpag*(cellPosi[0]+cellSize[0]); y2 = offs+lpag*(cellPosi[1]+cellSize[1]); - + if (fillcells) { // get cell value Float_t value = GetCellValue(fCells[iCell], cell_value); @@ -1622,16 +1630,16 @@ void TMVA::PDEFoam::RootPlot2dim( const TString& filename, TString opt, // cell number if (plotcellnumber) { - outfile<<"t->SetTextColor(4);"<<endl; + outfile<<"t->SetTextColor(4);"<<std::endl; if(fLastCe<51) - outfile<<"t->SetTextSize(0.025);"<<endl; // text for numbering + outfile<<"t->SetTextSize(0.025);"<<std::endl; // text for numbering else if(fLastCe<251) - outfile<<"t->SetTextSize(0.015);"<<endl; + outfile<<"t->SetTextSize(0.015);"<<std::endl; else - outfile<<"t->SetTextSize(0.008);"<<endl; - x = offs+lpag*(cellPosi[0]+0.5*cellSize[0]); + outfile<<"t->SetTextSize(0.008);"<<std::endl; + x = offs+lpag*(cellPosi[0]+0.5*cellSize[0]); y = offs+lpag*(cellPosi[1]+0.5*cellSize[1]); - outfile<<"t->DrawText("<<x<<","<<y<<","<<"\""<<iCell<<"\""<<");"<<endl; + outfile<<"t->DrawText("<<x<<","<<y<<","<<"\""<<iCell<<"\""<<");"<<std::endl; } } } @@ -1652,9 +1660,9 @@ void TMVA::PDEFoam::FillBinarySearchTree( const Event* ev ) //_____________________________________________________________________ void TMVA::PDEFoam::DeleteBinarySearchTree() -{ +{ // Delete the foam's density estimator, which contains the binary // search tree. - if(fDistr) delete fDistr; + if(fDistr) delete fDistr; fDistr = NULL; } diff --git a/tmva/src/PDEFoamCell.cxx b/tmva/src/PDEFoamCell.cxx index 7055d7985413e..541ba556033ca 100644 --- a/tmva/src/PDEFoamCell.cxx +++ b/tmva/src/PDEFoamCell.cxx @@ -231,23 +231,23 @@ void TMVA::PDEFoamCell::Print(Option_t *option) const if (!option) Error( "Print", "No option set\n"); - cout << " Status= "<< fStatus <<","; - cout << " Volume= "<< fVolume <<","; - cout << " TrueInteg= " << fIntegral <<","; - cout << " DriveInteg= "<< fDrive <<","; - cout << endl; - cout << " Xdiv= "<<fXdiv<<","; - cout << " Best= "<<fBest<<","; - cout << " Parent= {"<< (GetPare() ? GetPare()->GetSerial() : -1) <<"} "; // extra DEBUG - cout << " Daught0= {"<< (GetDau0() ? GetDau0()->GetSerial() : -1 )<<"} "; // extra DEBUG - cout << " Daught1= {"<< (GetDau1() ? GetDau1()->GetSerial() : -1 )<<"} "; // extra DEBUG - cout << endl; + std::cout << " Status= "<< fStatus <<","; + std::cout << " Volume= "<< fVolume <<","; + std::cout << " TrueInteg= " << fIntegral <<","; + std::cout << " DriveInteg= "<< fDrive <<","; + std::cout << std::endl;; + std::cout << " Xdiv= "<<fXdiv<<","; + std::cout << " Best= "<<fBest<<","; + std::cout << " Parent= {"<< (GetPare() ? GetPare()->GetSerial() : -1) <<"} "; // extra DEBUG + std::cout << " Daught0= {"<< (GetDau0() ? GetDau0()->GetSerial() : -1 )<<"} "; // extra DEBUG + std::cout << " Daught1= {"<< (GetDau1() ? GetDau1()->GetSerial() : -1 )<<"} "; // extra DEBUG + std::cout << std::endl;; // // if (fDim>0 ) { PDEFoamVect cellPosi(fDim); PDEFoamVect cellSize(fDim); GetHcub(cellPosi,cellSize); - cout <<" Posi= "; cellPosi.Print("1"); cout<<","<< endl; - cout <<" Size= "; cellSize.Print("1"); cout<<","<< endl; + std::cout <<" Posi= "; cellPosi.Print("1"); std::cout<<","<< std::endl;; + std::cout <<" Size= "; cellSize.Print("1"); std::cout<<","<< std::endl;; } } diff --git a/tmva/src/PDEFoamDecisionTreeDensity.cxx b/tmva/src/PDEFoamDecisionTreeDensity.cxx index 7bb8c36447bb4..18a2b4d0c88c3 100644 --- a/tmva/src/PDEFoamDecisionTreeDensity.cxx +++ b/tmva/src/PDEFoamDecisionTreeDensity.cxx @@ -78,7 +78,7 @@ TMVA::PDEFoamDecisionTreeDensity::PDEFoamDecisionTreeDensity(const PDEFoamDecisi } //_____________________________________________________________________ -Double_t TMVA::PDEFoamDecisionTreeDensity::Density(std::vector<Double_t>& /* Xarg */, +Double_t TMVA::PDEFoamDecisionTreeDensity::Density(std::vector<Double_t>& /* Xarg */, Double_t& /* event_density */) { // This function is not used in the decision tree like PDEFoam, @@ -87,8 +87,8 @@ Double_t TMVA::PDEFoamDecisionTreeDensity::Density(std::vector<Double_t>& /* Xar } //_____________________________________________________________________ -void TMVA::PDEFoamDecisionTreeDensity::FillHistograms(TMVA::Volume &volume, std::vector<TH1D*> &hsig, - std::vector<TH1D*> &hbkg, std::vector<TH1D*> &hsig_unw, +void TMVA::PDEFoamDecisionTreeDensity::FillHistograms(TMVA::Volume &volume, std::vector<TH1D*> &hsig, + std::vector<TH1D*> &hbkg, std::vector<TH1D*> &hsig_unw, std::vector<TH1D*> &hbkg_unw) { // Fill the given histograms with signal and background events, diff --git a/tmva/src/PDEFoamDensityBase.cxx b/tmva/src/PDEFoamDensityBase.cxx index b77d401e3caac..b313d87a89c81 100644 --- a/tmva/src/PDEFoamDensityBase.cxx +++ b/tmva/src/PDEFoamDensityBase.cxx @@ -66,6 +66,7 @@ // _____________________________________________________________________ #include <numeric> +#include <functional> #ifndef ROOT_TMVA_PDEFoamDensityBase #include "TMVA/PDEFoamDensityBase.h" diff --git a/tmva/src/PDEFoamMultiTarget.cxx b/tmva/src/PDEFoamMultiTarget.cxx index 192114fb03977..bab6534087014 100644 --- a/tmva/src/PDEFoamMultiTarget.cxx +++ b/tmva/src/PDEFoamMultiTarget.cxx @@ -196,7 +196,7 @@ void TMVA::PDEFoamMultiTarget::CalculateMpv(std::map<Int_t, Float_t>& target, co // loop over all cells and find cell with maximum event density for (std::vector<PDEFoamCell*>::const_iterator cell_it = cells.begin(); cell_it != cells.end(); ++cell_it) { - + // get event density of cell const Double_t cell_density = GetCellValue(*cell_it, kValueDensity); @@ -242,7 +242,7 @@ void TMVA::PDEFoamMultiTarget::CalculateMean(std::map<Int_t, Float_t>& target, c // loop over all cells and find cell with maximum event density for (std::vector<PDEFoamCell*>::const_iterator cell_it = cells.begin(); cell_it != cells.end(); ++cell_it) { - + // get event density of cell const Double_t cell_density = GetCellValue(*cell_it, kValueDensity); diff --git a/tmva/src/PDEFoamVect.cxx b/tmva/src/PDEFoamVect.cxx index 6159af26aef24..bbc656d58365f 100644 --- a/tmva/src/PDEFoamVect.cxx +++ b/tmva/src/PDEFoamVect.cxx @@ -201,12 +201,12 @@ TMVA::PDEFoamVect& TMVA::PDEFoamVect::operator =(Double_t x) void TMVA::PDEFoamVect::Print(Option_t *option) const { // Printout of all vector components - streamsize wid = cout.width(); // saving current field width + streamsize wid = std::cout.width(); // saving current field width if(!option) Error( "Print ", "No option set \n"); - cout << "("; - for(Int_t i=0; i<fDim-1; i++) - cout << std::setw(12) << *(fCoords+i) << ","; - cout << std::setw(12) << *(fCoords+fDim-1); - cout << ")"; - cout.width(wid); + std::cout << "("; + for(Int_t i=0; i<fDim-1; i++) + std::cout << std::setw(12) << *(fCoords+i) << ","; + std::cout << std::setw(12) << *(fCoords+fDim-1); + std::cout << ")"; + std::cout.width(wid); } diff --git a/tmva/src/PDF.cxx b/tmva/src/PDF.cxx index 5779d27b3952d..3495c4d369f26 100644 --- a/tmva/src/PDF.cxx +++ b/tmva/src/PDF.cxx @@ -593,8 +593,8 @@ void TMVA::PDF::ValidatePDF( TH1* originalHist ) const if (y > 0) { ndof++; Double_t d = TMath::Abs( (y - yref*rref)/ey ); - // cout << "bin: " << bin << " val: " << x << " data(err): " << y << "(" << ey << ") pdf: " - // << yref << " dev(chi2): " << d << "(" << chi2 << ") rref: " << rref << endl; + // std::cout << "bin: " << bin << " val: " << x << " data(err): " << y << "(" << ey << ") pdf: " + // << yref << " dev(chi2): " << d << "(" << chi2 << ") rref: " << rref << std::endl; chi2 += d*d; if (d > 1) { nc1++; if (d > 2) { nc2++; if (d > 3) { nc3++; if (d > 6) nc6++; } } } } @@ -1009,7 +1009,7 @@ void TMVA::PDF::ReadXML( void* pdfnode ) } //_______________________________________________________________________ -ostream& TMVA::operator<< ( ostream& os, const PDF& pdf ) +std::ostream& TMVA::operator<< ( std::ostream& os, const PDF& pdf ) { // write the pdf Int_t dp = os.precision(); @@ -1046,9 +1046,9 @@ ostream& TMVA::operator<< ( ostream& os, const PDF& pdf ) } //_______________________________________________________________________ -istream& TMVA::operator>> ( istream& istr, PDF& pdf ) +std::istream& TMVA::operator>> ( std::istream& istr, PDF& pdf ) { - // read the tree from an istream + // read the tree from an std::istream TString devnullS; Int_t valI; Int_t nbins=-1; // default binning will cause an exit diff --git a/tmva/src/QuickMVAProbEstimator.cxx b/tmva/src/QuickMVAProbEstimator.cxx new file mode 100644 index 0000000000000..911223faa85f9 --- /dev/null +++ b/tmva/src/QuickMVAProbEstimator.cxx @@ -0,0 +1,65 @@ +#include "TMVA/QuickMVAProbEstimator.h" + +#include <iostream> + +#include "TMath.h" + +#ifndef ROOT_TMVA_MsgLogger +#include "TMVA/MsgLogger.h" +#endif + + +void TMVA::QuickMVAProbEstimator::AddEvent(Double_t val, Double_t weight, Int_t type){ + EventInfo ev; + ev.eventValue=val; ev.eventWeight=weight; ev.eventType=type; + + fEvtVector.push_back(ev); + if (fIsSorted) fIsSorted=false; + +} + + +Double_t TMVA::QuickMVAProbEstimator::GetMVAProbAt(Double_t value){ + // Well.. if it's fast is actually another question all together, merely + // it's a quick and dirty simple kNN approach to the 1-Dim signal/backgr. MVA + // distributions. + + + if (!fIsSorted) { + sort(fEvtVector.begin(),fEvtVector.end(),TMVA::QuickMVAProbEstimator::compare), fIsSorted=true; + } + + Double_t percentage = 0.1; + UInt_t nRange = TMath::Max(fNMin,(UInt_t) (fEvtVector.size() * percentage)); + nRange = TMath::Min(fNMax,nRange); + // just make sure that nRange > you total number of events + if (nRange > fEvtVector.size()) { + nRange = fEvtVector.size()/3.; + Log() << kWARNING << " !! you have only " << fEvtVector.size() << " of events.. . I choose " + << nRange << " for the quick and dirty kNN MVAProb estimate" << Endl; + } + + EventInfo tmp; tmp.eventValue=value; + std::vector<EventInfo>::iterator it = std::upper_bound(fEvtVector.begin(),fEvtVector.end(),tmp,TMVA::QuickMVAProbEstimator::compare); + + UInt_t iLeft=0, iRight=0; + Double_t nSignal=0; + Double_t nBackgr=0; + + while ( (iLeft+iRight) < nRange){ + if ( fEvtVector.end() > it+iRight+1){ + iRight++; + if ( ((it+iRight))->eventType == 0) nSignal+=((it+iRight))->eventWeight; + else nBackgr+=((it+iRight))->eventWeight; + } + if ( fEvtVector.begin() <= it-iLeft-1){ + iLeft++; + if ( ((it-iLeft))->eventType == 0) nSignal+=((it-iLeft))->eventWeight; + else nBackgr+=((it-iLeft))->eventWeight; + } + } + + Double_t mvaProb = (nSignal+nBackgr) ? nSignal/(nSignal+nBackgr) : -1 ; + return mvaProb; + +} diff --git a/tmva/src/Reader.cxx b/tmva/src/Reader.cxx index 94a5175c498c6..6911db39a718f 100644 --- a/tmva/src/Reader.cxx +++ b/tmva/src/Reader.cxx @@ -99,6 +99,7 @@ #include "TKey.h" #include "TVector.h" #include "TXMLEngine.h" +#include "TMath.h" #include <cstdlib> @@ -324,7 +325,7 @@ TString TMVA::Reader::GetMethodTypeFromFile( const TString& filename ) { // read the method type from the file - ifstream fin( filename ); + std::ifstream fin( filename ); if (!fin.good()) { // file not found --> Error Log() << kFATAL << "<BookMVA> fatal error: " << "unable to open input weight file: " << filename << Endl; @@ -333,7 +334,11 @@ TString TMVA::Reader::GetMethodTypeFromFile( const TString& filename ) TString fullMethodName(""); if (filename.EndsWith(".xml")) { fin.close(); - void* doc = gTools().xmlengine().ParseFile(filename);// the default buffer size in TXMLEngine::ParseFile is 100k. Starting with ROOT 5.29 one can set the buffer size, see: http://savannah.cern.ch/bugs/?78864. This might be necessary for large XML files +#if ROOT_VERSION_CODE >= ROOT_VERSION(5,29,0) + void* doc = gTools().xmlengine().ParseFile(filename,gTools().xmlenginebuffersize());// the default buffer size in TXMLEngine::ParseFile is 100k. Starting with ROOT 5.29 one can set the buffer size, see: http://savannah.cern.ch/bugs/?78864. This might be necessary for large XML files +#else + void* doc = gTools().xmlengine().ParseFile(filename); +#endif void* rootnode = gTools().xmlengine().DocGetRootElement(doc); // node "MethodSetup" gTools().ReadAttr(rootnode, "Method", fullMethodName); gTools().xmlengine().FreeDoc(doc); @@ -459,7 +464,7 @@ TMVA::IMethod* TMVA::Reader::BookMVA( TMVA::Types::EMVA methodType, const char* //_______________________________________________________________________ Double_t TMVA::Reader::EvaluateMVA( const std::vector<Float_t>& inputVec, const TString& methodTag, Double_t aux ) { - // Evaluate a vector<float> of input data for a given method + // Evaluate a std::vector<float> of input data for a given method // The parameter aux is obligatory for the cuts method where it represents the efficiency cutoff // create a temporary event from the vector. @@ -469,6 +474,13 @@ Double_t TMVA::Reader::EvaluateMVA( const std::vector<Float_t>& inputVec, const // Event* tmpEvent=new Event(inputVec, 2); // ToDo resolve magic 2 issue Event* tmpEvent=new Event(inputVec, DataInfo().GetNVariables()); // is this the solution? + for (UInt_t i=0; i<inputVec.size(); i++){ + if (TMath::IsNaN(inputVec[i])) { + Log() << kERROR << i << "-th variable of the event is NaN --> return MVA value -999, \n that's all I can do, please fix or remove this event." << Endl; + delete tmpEvent; + return -999; + } + } if (meth->GetMethodType() == TMVA::Types::kCuts) { TMVA::MethodCuts* mc = dynamic_cast<TMVA::MethodCuts*>(meth); @@ -483,7 +495,7 @@ Double_t TMVA::Reader::EvaluateMVA( const std::vector<Float_t>& inputVec, const //_______________________________________________________________________ Double_t TMVA::Reader::EvaluateMVA( const std::vector<Double_t>& inputVec, const TString& methodTag, Double_t aux ) { - // Evaluate a vector<double> of input data for a given method + // Evaluate a std::vector<double> of input data for a given method // The parameter aux is obligatory for the cuts method where it represents the efficiency cutoff // performs a copy to float values which are internally used by all methods @@ -517,6 +529,15 @@ Double_t TMVA::Reader::EvaluateMVA( const TString& methodTag, Double_t aux ) if(kl==0) Log() << kFATAL << methodTag << " is not a method" << Endl; + // check for NaN in event data: (note: in the factory, this check was done already at the creation of the datasets, hence + // it is not again checked in each of these subsequet calls.. + const Event* ev = kl->GetEvent(); + for (UInt_t i=0; i<ev->GetNVariables(); i++){ + if (TMath::IsNaN(ev->GetValue(i))) { + Log() << kERROR << i << "-th variable of the event is NaN --> return MVA value -999, \n that's all I can do, please fix or remove this event." << Endl; + return -999; + } + } return this->EvaluateMVA( kl, aux ); } @@ -556,6 +577,14 @@ const std::vector< Float_t >& TMVA::Reader::EvaluateRegression( const TString& m if(kl==0) Log() << kFATAL << methodTag << " is not a method" << Endl; + // check for NaN in event data: (note: in the factory, this check was done already at the creation of the datasets, hence + // it is not again checked in each of these subsequet calls.. + const Event* ev = kl->GetEvent(); + for (UInt_t i=0; i<ev->GetNVariables(); i++){ + if (TMath::IsNaN(ev->GetValue(i))) { + Log() << kERROR << i << "-th variable of the event is NaN, \n regression values might evaluate to .. what do I know. \n sorry this warning is all I can do, please fix or remove this event." << Endl; + } + } return this->EvaluateRegression( kl, aux ); } @@ -564,6 +593,14 @@ const std::vector< Float_t >& TMVA::Reader::EvaluateRegression( const TString& m const std::vector< Float_t >& TMVA::Reader::EvaluateRegression( MethodBase* method, Double_t /*aux*/ ) { // evaluates the regression MVA + // check for NaN in event data: (note: in the factory, this check was done already at the creation of the datasets, hence + // it is not again checked in each of these subsequet calls.. + const Event* ev = method->GetEvent(); + for (UInt_t i=0; i<ev->GetNVariables(); i++){ + if (TMath::IsNaN(ev->GetValue(i))) { + Log() << kERROR << i << "-th variable of the event is NaN, \n regression values might evaluate to .. what do I know. \n sorry this warning is all I can do, please fix or remove this event." << Endl; + } + } return method->GetRegressionValues(); } @@ -602,6 +639,15 @@ const std::vector< Float_t >& TMVA::Reader::EvaluateMulticlass( const TString& m if(kl==0) Log() << kFATAL << methodTag << " is not a method" << Endl; + // check for NaN in event data: (note: in the factory, this check was done already at the creation of the datasets, hence + // it is not again checked in each of these subsequet calls.. + + const Event* ev = kl->GetEvent(); + for (UInt_t i=0; i<ev->GetNVariables(); i++){ + if (TMath::IsNaN(ev->GetValue(i))) { + Log() << kERROR << i << "-th variable of the event is NaN, \n regression values might evaluate to .. what do I know. \n sorry this warning is all I can do, please fix or remove this event." << Endl; + } + } return this->EvaluateMulticlass( kl, aux ); } @@ -610,6 +656,14 @@ const std::vector< Float_t >& TMVA::Reader::EvaluateMulticlass( const TString& m const std::vector< Float_t >& TMVA::Reader::EvaluateMulticlass( MethodBase* method, Double_t /*aux*/ ) { // evaluates the multiclass MVA + // check for NaN in event data: (note: in the factory, this check was done already at the creation of the datasets, hence + // it is not again checked in each of these subsequet calls.. + const Event* ev = method->GetEvent(); + for (UInt_t i=0; i<ev->GetNVariables(); i++){ + if (TMath::IsNaN(ev->GetValue(i))) { + Log() << kERROR << i << "-th variable of the event is NaN, \n regression values might evaluate to .. what do I know. \n sorry this warning is all I can do, please fix or remove this event." << Endl; + } + } return method->GetMulticlassValues(); } @@ -661,6 +715,15 @@ Double_t TMVA::Reader::GetProba( const TString& methodTag, Double_t ap_sig, Dou MethodBase* kl = dynamic_cast<MethodBase*>(method); if(kl==0) return -1; + // check for NaN in event data: (note: in the factory, this check was done already at the creation of the datasets, hence + // it is not again checked in each of these subsequet calls.. + const Event* ev = kl->GetEvent(); + for (UInt_t i=0; i<ev->GetNVariables(); i++){ + if (TMath::IsNaN(ev->GetValue(i))) { + Log() << kERROR << i << "-th variable of the event is NaN --> return MVA value -999, \n that's all I can do, please fix or remove this event." << Endl; + return -999; + } + } if (mvaVal == -9999999) mvaVal = kl->GetMvaValue(); @@ -682,6 +745,15 @@ Double_t TMVA::Reader::GetRarity( const TString& methodTag, Double_t mvaVal ) MethodBase* kl = dynamic_cast<MethodBase*>(method); if(kl==0) return -1; + // check for NaN in event data: (note: in the factory, this check was done already at the creation of the datasets, hence + // it is not again checked in each of these subsequet calls.. + const Event* ev = kl->GetEvent(); + for (UInt_t i=0; i<ev->GetNVariables(); i++){ + if (TMath::IsNaN(ev->GetValue(i))) { + Log() << kERROR << i << "-th variable of the event is NaN --> return MVA value -999, \n that's all I can do, please fix or remove this event." << Endl; + return -999; + } + } if (mvaVal == -9999999) mvaVal = kl->GetMvaValue(); diff --git a/tmva/src/Results.cxx b/tmva/src/Results.cxx index c485489ce8bac..2c50241f67aac 100644 --- a/tmva/src/Results.cxx +++ b/tmva/src/Results.cxx @@ -28,18 +28,19 @@ #include <vector> #include "TH1.h" +#include "TH2.h" #include "TGraph.h" #include "TMVA/Results.h" #include "TMVA/MsgLogger.h" //_______________________________________________________________________ -TMVA::Results::Results( const DataSetInfo* dsi ) +TMVA::Results::Results( const DataSetInfo* dsi, TString resultsName ) : fTreeType(Types::kTraining), fDsi(dsi), fStorage( new TList() ), fHistAlias( new std::map<TString, TObject*> ), - fLogger( new MsgLogger("Results", kINFO) ) + fLogger( new MsgLogger(Form("Results%s",resultsName.Data()), kINFO) ) { // constructor fStorage->SetOwner(); @@ -91,12 +92,28 @@ TObject* TMVA::Results::GetObject(const TString & alias) const } +Bool_t TMVA::Results::DoesExist(const TString & alias) const +{ + TObject* test = GetObject(alias); + + return test; +} + //_______________________________________________________________________ TH1* TMVA::Results::GetHist(const TString & alias) const { - return (TH1*)GetObject(alias); + TH1* out=dynamic_cast<TH1*>(GetObject(alias)); + if (!out) Log() <<kWARNING << "You have asked for histogram " << alias << " which does not seem to exist in *Results* .. better don't use it " << Endl; + return out; } +//_______________________________________________________________________ +TH2* TMVA::Results::GetHist2D(const TString & alias) const +{ + TH2* out=dynamic_cast<TH2*>(GetObject(alias)); + if (!out) Log() <<kWARNING << "You have asked for 2D histogram " << alias << " which does not seem to exist in *Results* .. better don't use it " << Endl; + return out; +} //_______________________________________________________________________ TGraph* TMVA::Results::GetGraph(const TString & alias) const { diff --git a/tmva/src/ResultsClassification.cxx b/tmva/src/ResultsClassification.cxx index 83c4798ac8781..bd70469de18ec 100644 --- a/tmva/src/ResultsClassification.cxx +++ b/tmva/src/ResultsClassification.cxx @@ -32,10 +32,10 @@ //_______________________________________________________________________ -TMVA::ResultsClassification::ResultsClassification( const DataSetInfo* dsi ) - : Results( dsi ), +TMVA::ResultsClassification::ResultsClassification( const DataSetInfo* dsi, TString resultsName ) + : Results( dsi,resultsName ), fRet(1), - fLogger( new MsgLogger("ResultsClassification", kINFO) ) + fLogger( new MsgLogger(Form("ResultsClassification%s",resultsName.Data()) , kINFO) ) { // constructor } diff --git a/tmva/src/ResultsMulticlass.cxx b/tmva/src/ResultsMulticlass.cxx index 7b1ede0569594..82d155b17485b 100644 --- a/tmva/src/ResultsMulticlass.cxx +++ b/tmva/src/ResultsMulticlass.cxx @@ -28,6 +28,7 @@ **********************************************************************************/ #include <vector> +#include <limits> #include "TMVA/ResultsMulticlass.h" #include "TMVA/MsgLogger.h" @@ -37,10 +38,10 @@ #include "TMVA/GeneticFitter.h" //_______________________________________________________________________ -TMVA::ResultsMulticlass::ResultsMulticlass( const DataSetInfo* dsi ) - : Results( dsi ), +TMVA::ResultsMulticlass::ResultsMulticlass( const DataSetInfo* dsi, TString resultsName ) + : Results( dsi, resultsName ), IFitterTarget(), - fLogger( new MsgLogger("ResultsMulticlass", kINFO) ), + fLogger( new MsgLogger(Form("ResultsMultiClass%s",resultsName.Data()) , kINFO) ), fClassToOptimize(0), fAchievableEff(dsi->GetNClasses()), fAchievablePur(dsi->GetNClasses()), @@ -74,7 +75,7 @@ Double_t TMVA::ResultsMulticlass::EstimatorFunction( std::vector<Double_t> & cut Float_t sumWeights = 0; for (Int_t ievt=0; ievt<ds->GetNEvents(); ievt++) { - Event* ev = ds->GetEvent(ievt); + const Event* ev = ds->GetEvent(ievt); Float_t w = ev->GetWeight(); if(ev->GetClass()==fClassToOptimize) sumWeights += w; @@ -163,7 +164,7 @@ void TMVA::ResultsMulticlass::CreateMulticlassHistos( TString prefix, Int_t nbi } for (Int_t ievt=0; ievt<ds->GetNEvents(); ievt++) { - Event* ev = ds->GetEvent(ievt); + const Event* ev = ds->GetEvent(ievt); Int_t cls = ev->GetClass(); Float_t w = ev->GetWeight(); for (UInt_t jCls = 0; jCls < dsi->GetNClasses(); jCls++) { @@ -192,7 +193,7 @@ void TMVA::ResultsMulticlass::CreateMulticlassHistos( TString prefix, Int_t nbi } for (Int_t ievt=0; ievt<ds->GetNEvents(); ievt++) { - Event* ev = ds->GetEvent(ievt); + const Event* ev = ds->GetEvent(ievt); Int_t cls = ev->GetClass(); Float_t w = ev->GetWeight(); for (UInt_t jCls = 0; jCls < dsi->GetNClasses(); jCls++) { diff --git a/tmva/src/ResultsRegression.cxx b/tmva/src/ResultsRegression.cxx index ea734b4dc1512..a47de807c2e6b 100644 --- a/tmva/src/ResultsRegression.cxx +++ b/tmva/src/ResultsRegression.cxx @@ -32,9 +32,9 @@ #include "TMVA/DataSet.h" //_______________________________________________________________________ -TMVA::ResultsRegression::ResultsRegression( const DataSetInfo* dsi ) - : Results( dsi ), - fLogger( new MsgLogger("ResultsRegression", kINFO) ) +TMVA::ResultsRegression::ResultsRegression( const DataSetInfo* dsi, TString resultsName ) + : Results( dsi, resultsName ), + fLogger( new MsgLogger(Form("ResultsRegression%s",resultsName.Data()) , kINFO) ) { // constructor } @@ -67,7 +67,7 @@ TH1F* TMVA::ResultsRegression::QuadraticDeviation( UInt_t tgtNum , Bool_t trunc } else{ for (Int_t ievt=0; ievt<ds->GetNEvents(); ievt++) { - Event* ev = ds->GetEvent(ievt); + const Event* ev = ds->GetEvent(ievt); std::vector<Float_t> regVal = fRegValues.at(ievt); Float_t val = regVal.at( tgtNum ) - ev->GetTarget( tgtNum ); val *= val; @@ -82,7 +82,7 @@ TH1F* TMVA::ResultsRegression::QuadraticDeviation( UInt_t tgtNum , Bool_t trunc h->GetYaxis()->SetTitle("Weighted Entries"); for (Int_t ievt=0; ievt<ds->GetNEvents(); ievt++) { - Event* ev = ds->GetEvent(ievt); + const Event* ev = ds->GetEvent(ievt); std::vector<Float_t> regVal = fRegValues.at(ievt); Float_t val = regVal.at( tgtNum ) - ev->GetTarget( tgtNum ); val *= val; @@ -112,7 +112,7 @@ TH2F* TMVA::ResultsRegression::DeviationAsAFunctionOf( UInt_t varNum, UInt_t tg xmax = vinf.GetMax(); for (Int_t ievt=0; ievt<ds->GetNEvents(); ievt++) { - Event* ev = ds->GetEvent(ievt); + const Event* ev = ds->GetEvent(ievt); Float_t val = ev->GetValue(varNum); if (val < xmin ) xmin = val; @@ -126,7 +126,7 @@ TH2F* TMVA::ResultsRegression::DeviationAsAFunctionOf( UInt_t varNum, UInt_t tg xmax = vinf.GetMax(); for (Int_t ievt=0; ievt<ds->GetNEvents(); ievt++) { - Event* ev = ds->GetEvent(ievt); + const Event* ev = ds->GetEvent(ievt); Float_t val = ev->GetTarget(varNum); if (val < xmin ) xmin = val; @@ -138,7 +138,7 @@ TH2F* TMVA::ResultsRegression::DeviationAsAFunctionOf( UInt_t varNum, UInt_t tg Float_t ymax = -FLT_MAX; for (Int_t ievt=0; ievt<ds->GetNEvents(); ievt++) { - Event* ev = ds->GetEvent(ievt); + const Event* ev = ds->GetEvent(ievt); std::vector<Float_t> regVal = fRegValues.at(ievt); Float_t diff = regVal.at( tgtNum ) - ev->GetTarget( tgtNum ); @@ -167,7 +167,7 @@ TH2F* TMVA::ResultsRegression::DeviationAsAFunctionOf( UInt_t varNum, UInt_t tg h->GetYaxis()->SetTitle( yName ); for (Int_t ievt=0; ievt<ds->GetNEvents(); ievt++) { - Event* ev = ds->GetEvent(ievt); + const Event* ev = ds->GetEvent(ievt); std::vector<Float_t> regVal = fRegValues.at(ievt); Float_t xVal = (takeTargets?ev->GetTarget( varNum ):ev->GetValue( varNum )); diff --git a/tmva/src/Rule.cxx b/tmva/src/Rule.cxx index 4e4b8181b62bc..977ad1e051687 100644 --- a/tmva/src/Rule.cxx +++ b/tmva/src/Rule.cxx @@ -245,9 +245,9 @@ Bool_t TMVA::Rule::operator<( const Rule& other ) const } //_______________________________________________________________________ -ostream& TMVA::operator<< ( ostream& os, const Rule& rule ) +std::ostream& TMVA::operator<< ( std::ostream& os, const Rule& rule ) { - // ostream operator + // std::ostream operator rule.Print( os ); return os; } @@ -279,7 +279,7 @@ void TMVA::Rule::Copy( const Rule& other ) } //_______________________________________________________________________ -void TMVA::Rule::Print( ostream& os ) const +void TMVA::Rule::Print( std::ostream& os ) const { // print function const UInt_t nvars = fCut->GetNvars(); @@ -341,7 +341,7 @@ void TMVA::Rule::PrintLogger(const char *title) const } //_______________________________________________________________________ -void TMVA::Rule::PrintRaw( ostream& os ) const +void TMVA::Rule::PrintRaw( std::ostream& os ) const { // extensive print function used to print info for the weight file Int_t dp = os.precision(); @@ -448,7 +448,7 @@ void TMVA::Rule::ReadFromXML( void* wghtnode ) } //_______________________________________________________________________ -void TMVA::Rule::ReadRaw( istream& istr ) +void TMVA::Rule::ReadRaw( std::istream& istr ) { // read function (format is the same as written by PrintRaw) diff --git a/tmva/src/RuleEnsemble.cxx b/tmva/src/RuleEnsemble.cxx index a64f2c77d0ce9..b751d337ae5c0 100644 --- a/tmva/src/RuleEnsemble.cxx +++ b/tmva/src/RuleEnsemble.cxx @@ -234,7 +234,7 @@ void TMVA::RuleEnsemble::GetCoefficients( std::vector< Double_t > & v ) } //_______________________________________________________________________ -const std::vector<TMVA::Event*>* TMVA::RuleEnsemble::GetTrainingEvents() const +const std::vector<const TMVA::Event*>* TMVA::RuleEnsemble::GetTrainingEvents() const { // get list of training events from the rule fitter @@ -296,7 +296,7 @@ void TMVA::RuleEnsemble::RemoveSimilarRules() #if _MSC_VER >= 1400 fRules.erase( std::vector<Rule *>::iterator(&fRules[ind], &fRules) ); #else - fRules.erase( std::vector<Rule *>::iterator(&fRules[ind]) ); + fRules.erase( fRules.begin() + ind ); #endif delete theRule; ind--; @@ -327,7 +327,7 @@ void TMVA::RuleEnsemble::CleanupRules() #if _MSC_VER >= 1400 fRules.erase( std::vector<Rule *>::iterator(&fRules[ind], &fRules) ); #else - fRules.erase( std::vector<Rule *>::iterator(&fRules[ind]) ); + fRules.erase( fRules.begin() + ind ); #endif delete therule; ind--; @@ -365,7 +365,7 @@ void TMVA::RuleEnsemble::CalcRuleSupport() ttot = 0; // reset to default values SetAverageRuleSigma(0.4); - const std::vector<Event *> *events = GetTrainingEvents(); + const std::vector<const Event *> *events = GetTrainingEvents(); Double_t nrules = static_cast<Double_t>(fRules.size()); Double_t ew; // @@ -374,7 +374,7 @@ void TMVA::RuleEnsemble::CalcRuleSupport() s=0.0; ssig=0.0; sbkg=0.0; - for ( std::vector<Event * >::const_iterator itrEvent=events->begin(); itrEvent!=events->end(); itrEvent++ ) { + for ( std::vector<const Event * >::const_iterator itrEvent=events->begin(); itrEvent!=events->end(); itrEvent++ ) { if ((*itrRule)->EvalEvent( *(*itrEvent) )) { ew = (*itrEvent)->GetWeight(); s += ew; @@ -596,7 +596,7 @@ void TMVA::RuleEnsemble::MakeLinearTerms() // if (!DoLinear()) return; - const std::vector<Event *> *events = GetTrainingEvents(); + const std::vector<const Event *> *events = GetTrainingEvents(); UInt_t neve = events->size(); UInt_t nvars = ((*events)[0])->GetNVariables(); // Event -> GetNVariables(); Double_t val,ew; @@ -795,7 +795,7 @@ void TMVA::RuleEnsemble::RuleResponseStats() // calculate various statistics for this rule // TODO: NOT YET UPDATED FOR WEIGHTS - const std::vector<Event *> *events = GetTrainingEvents(); + const std::vector<const Event *> *events = GetTrainingEvents(); const UInt_t neve = events->size(); const UInt_t nvars = GetMethodBase()->GetNvar(); const UInt_t nrules = fRules.size(); @@ -1032,7 +1032,7 @@ void TMVA::RuleEnsemble::Print() const } //_______________________________________________________________________ -void TMVA::RuleEnsemble::PrintRaw( ostream & os ) const +void TMVA::RuleEnsemble::PrintRaw( std::ostream & os ) const { // write rules to stream Int_t dp = os.precision(); @@ -1149,7 +1149,7 @@ void TMVA::RuleEnsemble::ReadFromXML( void* wghtnode ) } //_______________________________________________________________________ -void TMVA::RuleEnsemble::ReadRaw( istream & istr ) +void TMVA::RuleEnsemble::ReadRaw( std::istream & istr ) { // read rule ensemble from stream UInt_t nrules; @@ -1333,7 +1333,7 @@ TMVA::Rule *TMVA::RuleEnsemble::MakeTheRule( const Node *node ) } //_______________________________________________________________________ -void TMVA::RuleEnsemble::MakeRuleMap(const std::vector<Event *> *events, UInt_t ifirst, UInt_t ilast) +void TMVA::RuleEnsemble::MakeRuleMap(const std::vector<const Event *> *events, UInt_t ifirst, UInt_t ilast) { // Makes rule map for all events @@ -1384,9 +1384,9 @@ void TMVA::RuleEnsemble::MakeRuleMap(const std::vector<Event *> *events, UInt_t } //_______________________________________________________________________ -ostream& TMVA::operator<< ( ostream& os, const RuleEnsemble & rules ) +std::ostream& TMVA::operator<< ( std::ostream& os, const RuleEnsemble & rules ) { - // ostream operator + // std::ostream operator os << "DON'T USE THIS - TO BE REMOVED" << std::endl; rules.Print(); return os; diff --git a/tmva/src/RuleFit.cxx b/tmva/src/RuleFit.cxx index 1960f15dc073b..15692434fa847 100644 --- a/tmva/src/RuleFit.cxx +++ b/tmva/src/RuleFit.cxx @@ -99,8 +99,17 @@ void TMVA::RuleFit::Initialize( const MethodBase *rfbase ) // initialize the parameters of the RuleFit method and make rules InitPtrs(rfbase); - if (fMethodRuleFit) - SetTrainingEvents( fMethodRuleFit->GetTrainingEvents() ); + if (fMethodRuleFit){ + fMethodRuleFit->Data()->SetCurrentType(Types::kTraining); + UInt_t nevents = fMethodRuleFit->Data()->GetNTrainingEvents(); + std::vector<const TMVA::Event*> tmp; + for (Long64_t ievt=0; ievt<nevents; ievt++) { + const Event *event = fMethodRuleFit->GetEvent(ievt); + tmp.push_back(event); + } + SetTrainingEvents( tmp ); + } + // SetTrainingEvents( fMethodRuleFit->GetTrainingEvents() ); InitNEveEff(); @@ -138,7 +147,7 @@ void TMVA::RuleFit::Copy( const RuleFit& other ) } //_______________________________________________________________________ -Double_t TMVA::RuleFit::CalcWeightSum( const std::vector<Event *> *events, UInt_t neve ) +Double_t TMVA::RuleFit::CalcWeightSum( const std::vector<const Event *> *events, UInt_t neve ) { // calculate the sum of weights if (events==0) return 0.0; @@ -168,7 +177,7 @@ void TMVA::RuleFit::BuildTree( DecisionTree *dt ) if (fMethodRuleFit==0) { Log() << kFATAL << "RuleFit::BuildTree() - Attempting to build a tree NOT from a MethodRuleFit" << Endl; } - std::vector<Event *> evevec; + std::vector<const Event *> evevec; for (UInt_t ie=0; ie<fNTreeSample; ie++) { evevec.push_back(fTrainingEventsRndm[ie]); } @@ -197,7 +206,6 @@ void TMVA::RuleFit::MakeForest() // TRandom3 rndGen; // - Int_t nminRnd; // // First save all event weights. // Weights are modifed by the boosting. @@ -218,17 +226,18 @@ void TMVA::RuleFit::MakeForest() } // fsig = Double_t(nsig)/Double_t(nsig+nbkg); // do not implement the above in this release...just set it to default - // nminRnd = fNodeMinEvents; + DecisionTree *dt; Bool_t tryAgain=kTRUE; Int_t ntries=0; const Int_t ntriesMax=10; + Double_t frnd; while (tryAgain) { - Double_t frnd = rndGen.Uniform( fMethodRuleFit->GetMinFracNEve(), fMethodRuleFit->GetMaxFracNEve() ); - nminRnd = Int_t(frnd*static_cast<Double_t>(fNTreeSample)); + frnd = 100*rndGen.Uniform( fMethodRuleFit->GetMinFracNEve(), 0.5*fMethodRuleFit->GetMaxFracNEve() ); Int_t iclass = 0; // event class being treated as signal during training Bool_t useRandomisedTree = !useBoost; - dt = new DecisionTree( fMethodRuleFit->GetSeparationBase(), nminRnd, fMethodRuleFit->GetNCuts(), iclass, useRandomisedTree); + dt = new DecisionTree( fMethodRuleFit->GetSeparationBase(), frnd, fMethodRuleFit->GetNCuts(), iclass, useRandomisedTree); + dt->SetNVars(fMethodBase->GetNvar()); BuildTree(dt); // reads fNTreeSample events from fTrainingEventsRndm if (dt->GetNNodes()<3) { @@ -254,7 +263,7 @@ void TMVA::RuleFit::MakeForest() Log() << kWARNING << "------------------------------------------------------------------" << Endl; } - Log() << kDEBUG << "Built tree with minimum cut at N = " << nminRnd + Log() << kDEBUG << "Built tree with minimum cut at N = " << frnd <<"% events" << " => N(nodes) = " << fForest.back()->GetNNodes() << " ; n(tries) = " << ntries << Endl; @@ -272,8 +281,8 @@ void TMVA::RuleFit::SaveEventWeights() { // save event weights - must be done before making the forest fEventWeights.clear(); - for (std::vector<Event*>::iterator e=fTrainingEvents.begin(); e!=fTrainingEvents.end(); e++) { - Double_t w = (*e)->GetWeight(); + for (std::vector<const Event*>::iterator e=fTrainingEvents.begin(); e!=fTrainingEvents.end(); e++) { + Double_t w = (*e)->GetBoostWeight(); fEventWeights.push_back(w); } } @@ -287,8 +296,8 @@ void TMVA::RuleFit::RestoreEventWeights() Log() << kERROR << "RuleFit::RestoreEventWeights() called without having called SaveEventWeights() before!" << Endl; return; } - for (std::vector<Event*>::iterator e=fTrainingEvents.begin(); e!=fTrainingEvents.end(); e++) { - (*e)->SetWeight(fEventWeights[ie]); + for (std::vector<const Event*>::iterator e=fTrainingEvents.begin(); e!=fTrainingEvents.end(); e++) { + (*e)->SetBoostWeight(fEventWeights[ie]); ie++; } } @@ -304,8 +313,8 @@ void TMVA::RuleFit::Boost( DecisionTree *dt ) // std::vector<Char_t> correctSelected; // <--- boolean stored // - for (std::vector<Event*>::iterator e=fTrainingEvents.begin(); e!=fTrainingEvents.end(); e++) { - Bool_t isSignalType = (dt->CheckEvent(*(*e),kTRUE) > 0.5 ); + for (std::vector<const Event*>::iterator e=fTrainingEvents.begin(); e!=fTrainingEvents.end(); e++) { + Bool_t isSignalType = (dt->CheckEvent(*e,kTRUE) > 0.5 ); Double_t w = (*e)->GetWeight(); sumw += w; // @@ -326,16 +335,16 @@ void TMVA::RuleFit::Boost( DecisionTree *dt ) Double_t newSumw=0.0; UInt_t ie=0; // set new weight to missclassified events - for (std::vector<Event*>::iterator e=fTrainingEvents.begin(); e!=fTrainingEvents.end(); e++) { + for (std::vector<const Event*>::iterator e=fTrainingEvents.begin(); e!=fTrainingEvents.end(); e++) { if (!correctSelected[ie]) - (*e)->SetWeight( (*e)->GetWeight() * boostWeight); + (*e)->SetBoostWeight( (*e)->GetBoostWeight() * boostWeight); newSumw+=(*e)->GetWeight(); ie++; } // reweight all events Double_t scale = sumw/newSumw; - for (std::vector<Event*>::iterator e=fTrainingEvents.begin(); e!=fTrainingEvents.end(); e++) { - (*e)->SetWeight( (*e)->GetWeight() * scale); + for (std::vector<const Event*>::iterator e=fTrainingEvents.begin(); e!=fTrainingEvents.end(); e++) { + (*e)->SetBoostWeight( (*e)->GetBoostWeight() * scale); } Log() << kDEBUG << "boostWeight = " << boostWeight << " scale = " << scale << Endl; } @@ -394,7 +403,7 @@ Double_t TMVA::RuleFit::EvalEvent( const Event& e ) } //_______________________________________________________________________ -void TMVA::RuleFit::SetTrainingEvents( const std::vector<Event *>& el ) +void TMVA::RuleFit::SetTrainingEvents( const std::vector<const Event *>& el ) { // set the training events randomly if (fMethodRuleFit==0) Log() << kFATAL << "RuleFit::SetTrainingEvents - MethodRuleFit not initialized" << Endl; @@ -405,8 +414,8 @@ void TMVA::RuleFit::SetTrainingEvents( const std::vector<Event *>& el ) fTrainingEvents.clear(); fTrainingEventsRndm.clear(); for (UInt_t i=0; i<neve; i++) { - fTrainingEvents.push_back(static_cast< Event *>(el[i])); - fTrainingEventsRndm.push_back(static_cast< Event *>(el[i])); + fTrainingEvents.push_back(static_cast< const Event *>(el[i])); + fTrainingEventsRndm.push_back(static_cast< const Event *>(el[i])); } // Re-shuffle the vector, ie, recreate it in a random order diff --git a/tmva/src/RuleFitParams.cxx b/tmva/src/RuleFitParams.cxx index a702eb32e66be..9bce0d1055004 100644 --- a/tmva/src/RuleFitParams.cxx +++ b/tmva/src/RuleFitParams.cxx @@ -28,6 +28,7 @@ #include <iomanip> #include <numeric> #include <algorithm> +#include <functional> #include "TTree.h" #include "TMath.h" @@ -232,7 +233,7 @@ void TMVA::RuleFitParams::EvaluateAverage( UInt_t ind1, UInt_t ind2, } } else { // MakeRuleMap() has not yet been called - const std::vector<Event *> *events = &(fRuleFit->GetTrainingEvents()); + const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents()); for ( UInt_t i=ind1; i<ind2+1; i++) { ew = fRuleFit->GetTrainingEventWeight(i); sumew += ew; @@ -868,7 +869,7 @@ void TMVA::RuleFitParams::CalcFStar() return; } // - const std::vector<Event *> *events = &(fRuleFit->GetTrainingEvents()); + const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents()); // fFstar.clear(); std::vector<Double_t> fstarSorted; @@ -907,7 +908,7 @@ Double_t TMVA::RuleFitParams::Optimism() Log() << kFATAL << "<Optimism> Invalid start/end indices!" << Endl; } // - const std::vector<Event *> *events = &(fRuleFit->GetTrainingEvents()); + const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents()); // Double_t sumy=0; Double_t sumyhat=0; @@ -954,7 +955,7 @@ Double_t TMVA::RuleFitParams::ErrorRateReg() // Double_t sF; // - const std::vector<Event *> *events = &(fRuleFit->GetTrainingEvents()); + const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents()); // Double_t sumdf = 0; Double_t sumdfmed = 0; @@ -992,7 +993,7 @@ Double_t TMVA::RuleFitParams::ErrorRateBin() Log() << kFATAL << "<ErrorRateBin> Invalid start/end indices!" << Endl; } // - const std::vector<Event *> *events = &(fRuleFit->GetTrainingEvents()); + const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents()); // Double_t sumdfbin = 0; Double_t dneve = Double_t(neve); @@ -1093,7 +1094,7 @@ Double_t TMVA::RuleFitParams::ErrorRateRoc() Log() << kFATAL << "<ErrorRateRoc> Invalid start/end indices!" << Endl; } // - const std::vector<Event *> *events = &(fRuleFit->GetTrainingEvents()); + const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents()); // Double_t sF; // @@ -1143,7 +1144,7 @@ void TMVA::RuleFitParams::ErrorRateRocTst() return; } // - const std::vector<Event *> *events = &(fRuleFit->GetTrainingEvents()); + const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents()); // // std::vector<Double_t> sF; Double_t sF; @@ -1248,7 +1249,7 @@ void TMVA::RuleFitParams::MakeTstGradientVector() // Double_t norm = 2.0/fNEveEffPath; // - const std::vector<Event *> *events = &(fRuleFit->GetTrainingEvents()); + const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents()); // Clear gradient vectors for (UInt_t itau=0; itau<fGDNTau; itau++) { @@ -1370,7 +1371,7 @@ void TMVA::RuleFitParams::MakeGradientVector() // const Double_t norm = 2.0/fNEveEffPath; // - const std::vector<Event *> *events = &(fRuleFit->GetTrainingEvents()); + const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents()); // Clear gradient vectors for (UInt_t ir=0; ir<fNRules; ir++) { @@ -1516,7 +1517,7 @@ Double_t TMVA::RuleFitParams::CalcAverageTruth() Double_t sum=0; Double_t ensig=0; Double_t enbkg=0; - const std::vector<Event *> *events = &(fRuleFit->GetTrainingEvents()); + const std::vector<const Event *> *events = &(fRuleFit->GetTrainingEvents()); for (UInt_t i=fPathIdx1; i<fPathIdx2+1; i++) { Double_t ew = fRuleFit->GetTrainingEventWeight(i); if (fRuleFit->GetMethodRuleFit()->DataInfo().IsSignal((*events)[i])) ensig += ew; diff --git a/tmva/src/SdivSqrtSplusB.cxx b/tmva/src/SdivSqrtSplusB.cxx index 3e1581b1a28d6..45f2eac08d5c1 100644 --- a/tmva/src/SdivSqrtSplusB.cxx +++ b/tmva/src/SdivSqrtSplusB.cxx @@ -39,3 +39,37 @@ Double_t TMVA::SdivSqrtSplusB::GetSeparationIndex( const Double_t &s, const Dou else return 0; } + + +//_______________________________________________________________________ +Double_t TMVA::SdivSqrtSplusB::GetSeparationGain(const Double_t &nSelS, const Double_t& nSelB, + const Double_t& nTotS, const Double_t& nTotB) +{ + // Separation Gain: + // the measure of how the quality of separation of the sample increases + // by splitting the sample e.g. into a "left-node" and a "right-node" + // (N * Index_parent) - (N_left * Index_left) - (N_right * Index_right) + // this is then the quality crition which is optimized for when trying + // to increase the information in the system (making the best selection + + if ( (nTotS-nSelS)==nSelS && (nTotB-nSelB)==nSelB) return 0.; + + Double_t parentIndex = (nTotS+nTotB) *this->GetSeparationIndex(nTotS,nTotB); + + Double_t leftIndex = ( ((nTotS - nSelS) + (nTotB - nSelB)) + * this->GetSeparationIndex(nTotS-nSelS,nTotB-nSelB) ); + Double_t rightIndex = (nSelS+nSelB) * this->GetSeparationIndex(nSelS,nSelB); + + //Double_t diff = parentIndex - leftIndex - rightIndex; + Double_t diff = (parentIndex - leftIndex - rightIndex)/(nTotS+nTotB); + + if(diff<fPrecisionCut ) { + // std::cout << " Warning value in GetSeparation is below numerical presicion " + // << diff/parentIndex + // << std::endl; + return 0; + } + + return diff; +} + diff --git a/tmva/src/SeparationBase.cxx b/tmva/src/SeparationBase.cxx index 7c730f7b9355b..b211d17dd4d47 100644 --- a/tmva/src/SeparationBase.cxx +++ b/tmva/src/SeparationBase.cxx @@ -77,14 +77,21 @@ Double_t TMVA::SeparationBase::GetSeparationGain(const Double_t &nSelS, const Do if ( (nTotS-nSelS)==nSelS && (nTotB-nSelB)==nSelB) return 0.; - Double_t parentIndex = (nTotS+nTotB) *this->GetSeparationIndex(nTotS,nTotB); + // Double_t parentIndex = (nTotS+nTotB) *this->GetSeparationIndex(nTotS,nTotB); - Double_t leftIndex = ( ((nTotS - nSelS) + (nTotB - nSelB)) + // Double_t leftIndex = ( ((nTotS - nSelS) + (nTotB - nSelB)) + // * this->GetSeparationIndex(nTotS-nSelS,nTotB-nSelB) ); + // Double_t rightIndex = (nSelS+nSelB) * this->GetSeparationIndex(nSelS,nSelB); + + + Double_t parentIndex = this->GetSeparationIndex(nTotS,nTotB); + + Double_t leftIndex = ( ((nTotS - nSelS) + (nTotB - nSelB))/(nTotS+nTotB) * this->GetSeparationIndex(nTotS-nSelS,nTotB-nSelB) ); - Double_t rightIndex = (nSelS+nSelB) * this->GetSeparationIndex(nSelS,nSelB); + Double_t rightIndex = (nSelS+nSelB)/(nTotS+nTotB) * this->GetSeparationIndex(nSelS,nSelB); - //Double_t diff = parentIndex - leftIndex - rightIndex; - Double_t diff = (parentIndex - leftIndex - rightIndex)/(nTotS+nTotB); + Double_t diff = parentIndex - leftIndex - rightIndex; + //Double_t diff = (parentIndex - leftIndex - rightIndex)/(nTotS+nTotB); if(diff<fPrecisionCut ) { // std::cout << " Warning value in GetSeparation is below numerical presicion " diff --git a/tmva/src/TNeuron.cxx b/tmva/src/TNeuron.cxx index 293545504fa67..f7506064c7e05 100644 --- a/tmva/src/TNeuron.cxx +++ b/tmva/src/TNeuron.cxx @@ -126,6 +126,7 @@ void TMVA::TNeuron::CalculateDelta() Double_t error; + // output neuron should have error set all ready if (IsOutputNeuron()) error = fError; @@ -133,15 +134,17 @@ void TMVA::TNeuron::CalculateDelta() else { error = 0.0; TSynapse* synapse = NULL; - TObjArrayIter* iter = (TObjArrayIter*)fLinksOut->MakeIterator(); - + // Replaced TObjArrayIter pointer by object, as creating it on the stack + // is much faster (5-10% improvement seen) than re-allocating the new + // memory for the pointer each time. Thansk to Peter Elmer who pointed this out + // TObjArrayIter* iter = (TObjArrayIter*)fLinksOut->MakeIterator(); + TObjArrayIter iter(fLinksOut); while (true) { - synapse = (TSynapse*) iter->Next(); + synapse = (TSynapse*) iter.Next(); if (synapse == NULL) break; error += synapse->GetWeightedDelta(); } - delete iter; } fDelta = error * fActivation->EvalDerivative(GetValue()); @@ -222,15 +225,13 @@ void TMVA::TNeuron::UpdateSynapsesBatch() if (IsInputNeuron()) return; TSynapse* synapse = NULL; - TObjArrayIter* iter = (TObjArrayIter*) fLinksIn->MakeIterator(); - + TObjArrayIter iter(fLinksIn); while (true) { - synapse = (TSynapse*) iter->Next(); + synapse = (TSynapse*) iter.Next(); if (synapse == NULL) break; synapse->CalculateDelta(); } - delete iter; } //______________________________________________________________________________ @@ -242,17 +243,16 @@ void TMVA::TNeuron::UpdateSynapsesSequential() if (IsInputNeuron()) return; TSynapse* synapse = NULL; - TObjArrayIter* iter = (TObjArrayIter*) fLinksIn->MakeIterator(); + TObjArrayIter iter(fLinksIn); while (true) { - synapse = (TSynapse*) iter->Next(); + synapse = (TSynapse*) iter.Next(); if (synapse == NULL) break; synapse->InitDelta(); synapse->CalculateDelta(); synapse->AdjustWeight(); } - delete iter; } //______________________________________________________________________________ @@ -264,15 +264,15 @@ void TMVA::TNeuron::AdjustSynapseWeights() if (IsInputNeuron()) return; TSynapse* synapse = NULL; - TObjArrayIter* iter = (TObjArrayIter*) fLinksIn->MakeIterator(); + TObjArrayIter iter(fLinksIn); + while (true) { - synapse = (TSynapse*) iter->Next(); + synapse = (TSynapse*) iter.Next(); if (synapse == NULL) break; synapse->AdjustWeight(); } - delete iter; } //______________________________________________________________________________ @@ -285,15 +285,15 @@ void TMVA::TNeuron::InitSynapseDeltas() if (IsInputNeuron()) return; TSynapse* synapse = NULL; - TObjArrayIter* iter = (TObjArrayIter*) fLinksIn->MakeIterator(); + TObjArrayIter iter(fLinksIn); while (true) { - synapse = (TSynapse*) iter->Next(); + synapse = (TSynapse*) iter.Next(); + if (synapse == NULL) break; synapse->InitDelta(); } - delete iter; } //______________________________________________________________________________ diff --git a/tmva/src/Tools.cxx b/tmva/src/Tools.cxx index 93e814d75b735..e7eb7d66e68f1 100644 --- a/tmva/src/Tools.cxx +++ b/tmva/src/Tools.cxx @@ -103,7 +103,7 @@ Double_t TMVA::Tools::NormVariable( Double_t x, Double_t xmin, Double_t xmax ) Double_t TMVA::Tools::GetSeparation( TH1* S, TH1* B ) const { // compute "separation" defined as - // <s2> = (1/2) Int_-oo..+oo { (S^2(x) - B^2(x))/(S(x) + B(x)) dx } + // <s2> = (1/2) Int_-oo..+oo { (S(x) - B(x))^2/(S(x) + B(x)) dx } Double_t separation = 0; // sanity checks @@ -132,8 +132,8 @@ Double_t TMVA::Tools::GetSeparation( TH1* S, TH1* B ) const if (nS > 0 && nB > 0) { for (Int_t bin=0; bin<nstep; bin++) { - Double_t s = S->GetBinContent( bin )/Double_t(nS); - Double_t b = B->GetBinContent( bin )/Double_t(nB); + Double_t s = S->GetBinContent( bin+1 )/Double_t(nS); + Double_t b = B->GetBinContent( bin+1 )/Double_t(nB); // separation if (s + b > 0) separation += 0.5*(s - b)*(s - b)/(s + b); } @@ -153,7 +153,7 @@ Double_t TMVA::Tools::GetSeparation( TH1* S, TH1* B ) const Double_t TMVA::Tools::GetSeparation( const PDF& pdfS, const PDF& pdfB ) const { // compute "separation" defined as - // <s2> = (1/2) Int_-oo..+oo { (S(x)2 - B(x)2)/(S(x) + B(x)) dx } + // <s2> = (1/2) Int_-oo..+oo { (S(x) - B(x))2/(S(x) + B(x)) dx } Double_t xmin = pdfS.GetXmin(); Double_t xmax = pdfS.GetXmax(); @@ -198,10 +198,12 @@ void TMVA::Tools::ComputeStat( const std::vector<TMVA::Event*>& events, std::vec // first fill signal and background in arrays before analysis Double_t* varVecS = new Double_t[entries]; Double_t* varVecB = new Double_t[entries]; + Double_t* wgtVecS = new Double_t[entries]; + Double_t* wgtVecB = new Double_t[entries]; xmin = +DBL_MAX; xmax = -DBL_MAX; - Long64_t nEventsS = -1; - Long64_t nEventsB = -1; + Long64_t nEventsS = 0; + Long64_t nEventsB = 0; Double_t xmin_ = 0, xmax_ = 0; if (norm) { @@ -214,26 +216,32 @@ void TMVA::Tools::ComputeStat( const std::vector<TMVA::Event*>& events, std::vec if (norm) theVar = Tools::NormVariable( theVar, xmin_, xmax_ ); if (Int_t(events[ievt]->GetClass()) == signalClass ){ - varVecS[++nEventsS] = theVar; // this is signal + wgtVecS[nEventsS] = events[ievt]->GetWeight(); // this is signal + varVecS[nEventsS++] = theVar; // this is signal } else { - varVecB[++nEventsB] = theVar; // this is background + wgtVecB[nEventsB] = events[ievt]->GetWeight(); // this is signal + varVecB[nEventsB++] = theVar; // this is background } if (theVar > xmax) xmax = theVar; if (theVar < xmin) xmin = theVar; } - ++nEventsS; - ++nEventsB; + // ++nEventsS; + // ++nEventsB; // basic statistics - meanS = TMath::Mean( nEventsS, varVecS ); - meanB = TMath::Mean( nEventsB, varVecB ); - rmsS = TMath::RMS ( nEventsS, varVecS ); - rmsB = TMath::RMS ( nEventsB, varVecB ); + // !!! TMath::Mean allows for weights, but NOT for negative weights + // and TMath::RMS doesn't allow for weights all together... + meanS = TMVA::Tools::Mean( nEventsS, varVecS, wgtVecS ); + meanB = TMVA::Tools::Mean( nEventsB, varVecB, wgtVecB ); + rmsS = TMVA::Tools::RMS ( nEventsS, varVecS, wgtVecS ); + rmsB = TMVA::Tools::RMS ( nEventsB, varVecB, wgtVecB ); delete [] varVecS; delete [] varVecB; + delete [] wgtVecS; + delete [] wgtVecB; } //_______________________________________________________________________ @@ -617,7 +625,7 @@ TH2F* TMVA::Tools::TransposeHist( const TH2F& h ) // sanity check if (h.GetNbinsX() != h.GetNbinsY()) { - Log() << kFATAL << "<TransposeHist> cannot transpose non-quadratic histogram" << endl; + Log() << kFATAL << "<TransposeHist> cannot transpose non-quadratic histogram" << Endl; } TH2F *transposedHisto = new TH2F( h ); @@ -626,6 +634,21 @@ TH2F* TMVA::Tools::TransposeHist( const TH2F& h ) transposedHisto->SetBinContent(iy,ix,h.GetBinContent(ix,iy)); } } + + // copy stats (thanks to Swagato Banerjee for pointing out the missing stats information) + Double_t stats_old[7]; + Double_t stats_new[7]; + + h.GetStats(stats_old); + stats_new[0] = stats_old[0]; + stats_new[1] = stats_old[1]; + stats_new[2] = stats_old[4]; + stats_new[3] = stats_old[5]; + stats_new[4] = stats_old[2]; + stats_new[5] = stats_old[3]; + stats_new[6] = stats_old[6]; + transposedHisto->PutStats(stats_new); + return transposedHisto; // ownership returned } @@ -812,7 +835,7 @@ const TString& TMVA::Tools::Color( const TString& c ) if (c == "reset") return gClr_reset; - cout << "Unknown color " << c << endl; + std::cout << "Unknown color " << c << std::endl; exit(1); return gClr_none; @@ -1214,13 +1237,13 @@ void TMVA::Tools::ReadTMatrixDFromXML( void* node, const char* name, TMatrixD* m void TMVA::Tools::TMVAWelcomeMessage() { // direct output, eg, when starting ROOT session -> no use of Logger here - cout << endl; - cout << Color("bold") << "TMVA -- Toolkit for Multivariate Data Analysis" << Color("reset") << endl; - cout << " " << "Version " << TMVA_RELEASE << ", " << TMVA_RELEASE_DATE << endl; - cout << " " << "Copyright (C) 2005-2010 CERN, MPI-K Heidelberg, Us of Bonn and Victoria" << endl; - cout << " " << "Home page: http://tmva.sf.net" << endl; - cout << " " << "Citation info: http://tmva.sf.net/citeTMVA.html" << endl; - cout << " " << "License: http://tmva.sf.net/LICENSE" << endl << endl; + std::cout << std::endl; + std::cout << Color("bold") << "TMVA -- Toolkit for Multivariate Data Analysis" << Color("reset") << std::endl; + std::cout << " " << "Version " << TMVA_RELEASE << ", " << TMVA_RELEASE_DATE << std::endl; + std::cout << " " << "Copyright (C) 2005-2010 CERN, MPI-K Heidelberg, Us of Bonn and Victoria" << std::endl; + std::cout << " " << "Home page: http://tmva.sf.net" << std::endl; + std::cout << " " << "Citation info: http://tmva.sf.net/citeTMVA.html" << std::endl; + std::cout << " " << "License: http://tmva.sf.net/LICENSE" << std::endl << std::endl; } //_______________________________________________________________________ @@ -1398,14 +1421,33 @@ Bool_t TMVA::Tools::HistoHasEquidistantBins(const TH1& h) return !(h.GetXaxis()->GetXbins()->fN); } +//_______________________________________________________________________ +std::vector<TMatrixDSym*>* +TMVA::Tools::CalcCovarianceMatrices( const std::vector<const Event*>& events, Int_t maxCls, VariableTransformBase* transformBase ) +{ + std::vector<Event*> eventVector; + for (std::vector<const Event*>::const_iterator it = events.begin(), itEnd = events.end(); it != itEnd; ++it) + { + eventVector.push_back (new Event(*(*it))); + } + std::vector<TMatrixDSym*>* returnValue = CalcCovarianceMatrices (eventVector, maxCls, transformBase); + for (std::vector<Event*>::const_iterator it = eventVector.begin(), itEnd = eventVector.end(); it != itEnd; ++it) + { + delete (*it); + } + return returnValue; +} + //_______________________________________________________________________ std::vector<TMatrixDSym*>* TMVA::Tools::CalcCovarianceMatrices( const std::vector<Event*>& events, Int_t maxCls, VariableTransformBase* transformBase ) { // compute covariance matrices - if (events.empty()) return 0; - + if (events.empty()) { + Log() << kWARNING << " Asked to calculate a covariance matrix for an empty event vectors.. sorry cannot do that -> return NULL"<<Endl; + return 0; + } UInt_t nvars=0, ntgts=0, nspcts=0; if (transformBase) @@ -1448,7 +1490,7 @@ TMVA::Tools::CalcCovarianceMatrices( const std::vector<Event*>& events, Int_t ma for (UInt_t i=0; i<events.size(); i++) { // fill the event - Event * ev = events[i]; + const Event * ev = events[i]; cls = ev->GetClass(); Double_t weight = ev->GetWeight(); @@ -1522,3 +1564,117 @@ TMVA::Tools::CalcCovarianceMatrices( const std::vector<Event*>& events, Int_t ma return mat; } +template <typename Iterator, typename WeightIterator> +Double_t TMVA::Tools::Mean ( Iterator first, Iterator last, WeightIterator w) +{ + // Return the weighted mean of an array defined by the first and + // last iterators. The w iterator should point to the first element + // of a vector of weights of the same size as the main array. + + Double_t sum = 0; + Double_t sumw = 0; + int i = 0; + if (w==NULL) + { + while ( first != last ) + { + // if ( *w < 0) { + // ::Error("TMVA::Tools::Mean","w[%d] = %.4e < 0 ?!",i,*w); + // return 0; + // } // SURE, why wouldn't you allow for negative event weights here ?? :) + sum += (*first); + sumw += 1.0 ; + ++first; + ++i; + } + if (sumw <= 0) { + ::Error("TMVA::Tools::Mean","sum of weights <= 0 ?! that's a bit too much of negative event weights :) "); + return 0; + } + } + else + { + while ( first != last ) + { + // if ( *w < 0) { + // ::Error("TMVA::Tools::Mean","w[%d] = %.4e < 0 ?!",i,*w); + // return 0; + // } // SURE, why wouldn't you allow for negative event weights here ?? :) + sum += (*w) * (*first); + sumw += (*w) ; + ++w; + ++first; + ++i; + } + if (sumw <= 0) { + ::Error("TMVA::Tools::Mean","sum of weights <= 0 ?! that's a bit too much of negative event weights :) "); + return 0; + } + } + return sum/sumw; +} + +template <typename T> +Double_t TMVA::Tools::Mean(Long64_t n, const T *a, const Double_t *w) +{ + // Return the weighted mean of an array a with length n. + + if (w) { + return TMVA::Tools::Mean(a, a+n, w); + } else { + return TMath::Mean(a, a+n); + } +} + +template <typename Iterator, typename WeightIterator> +Double_t TMVA::Tools::RMS(Iterator first, Iterator last, WeightIterator w) +{ + // Return the Standard Deviation of an array defined by the iterators. + // Note that this function returns the sigma(standard deviation) and + // not the root mean square of the array. + + Double_t sum = 0; + Double_t sum2 = 0; + Double_t sumw = 0; + + Double_t adouble; + if (w==NULL) + { + while ( first != last ) { + adouble=Double_t(*first); + sum += adouble; + sum2 += adouble*adouble; + sumw += 1.0; + ++first; + } + } + else + { + while ( first != last ) { + adouble=Double_t(*first); + sum += adouble * (*w); + sum2 += adouble*adouble * (*w); + sumw += (*w); + ++first; + ++w; + } + } + Double_t norm = 1./sumw; + Double_t mean = sum*norm; + Double_t rms = TMath::Sqrt(TMath::Abs(sum2*norm -mean*mean)); + return rms; +} + +template <typename T> +Double_t TMVA::Tools::RMS(Long64_t n, const T *a, const Double_t *w) +{ + // Return the Standard Deviation of an array a with length n. + // Note that this function returns the sigma(standard deviation) and + // not the root mean square of the array. + + if (w) { + return TMVA::Tools::RMS(a, a+n, w); + } else { + return TMath::RMS(a, a+n); + } +} diff --git a/tmva/src/TransformationHandler.cxx b/tmva/src/TransformationHandler.cxx index b6d38f35caa64..4c56c274312dd 100644 --- a/tmva/src/TransformationHandler.cxx +++ b/tmva/src/TransformationHandler.cxx @@ -76,11 +76,11 @@ TMVA::TransformationHandler::TransformationHandler( DataSetInfo& dsi, const TStr fLogger ( new MsgLogger(TString("TFHandler_" + callerName).Data(), kINFO) ) { // constructor - + // produce one entry for each class and one entry for all classes. If there is only one class, // produce only one entry fNumC = (dsi.GetNClasses()<= 1) ? 1 : dsi.GetNClasses()+1; - + fVariableStats.resize( fNumC ); for (Int_t i=0; i<fNumC; i++ ) fVariableStats.at(i).resize(dsi.GetNVariables() + dsi.GetNTargets()); } @@ -110,7 +110,7 @@ TMVA::VariableTransformBase* TMVA::TransformationHandler::AddTransformation( Var trf->Log().SetSource(TString(fCallerName+"_"+tfname+"_TF").Data()); fTransformations.Add(trf); fTransformationsReferenceClasses.push_back( cls ); - return trf; + return trf; } //_______________________________________________________________________ @@ -168,9 +168,9 @@ const TMVA::Event* TMVA::TransformationHandler::InverseTransform( const Event* e UInt_t nvars = 0, ntgts = 0, nspcts = 0; while (VariableTransformBase *trf = (VariableTransformBase*) trIt() ) { // shouldn't be the transformation called in the inverse order for the inversetransformation????? if (trf->IsCreated()) { - trf->CountVariableTypes( nvars, ntgts, nspcts ); - if( !(suppressIfNoTargets && ntgts==0) ) - trEv = trf->InverseTransform(ev, (*rClsIt) ); + trf->CountVariableTypes( nvars, ntgts, nspcts ); + if( !(suppressIfNoTargets && ntgts==0) ) + trEv = trf->InverseTransform(ev, (*rClsIt) ); } else break; --rClsIt; @@ -178,29 +178,38 @@ const TMVA::Event* TMVA::TransformationHandler::InverseTransform( const Event* e return trEv; -// TListIter trIt(&fTransformations); -// std::vector< Int_t >::const_iterator rClsIt = fTransformationsReferenceClasses.begin(); -// const Event* trEv = ev; -// UInt_t nvars = 0, ntgts = 0, nspcts = 0; -// while (VariableTransformBase *trf = (VariableTransformBase*) trIt() ) { // shouldn't be the transformation called in the inverse order for the inversetransformation????? -// if (trf->IsCreated()) { -// trf->CountVariableTypes( nvars, ntgts, nspcts ); -// if( !(suppressIfNoTargets && ntgts==0) ) -// trEv = trf->InverseTransform(ev, (*rClsIt) ); -// } -// else break; -// rClsIt++; -// } -// return trEv; + // TListIter trIt(&fTransformations); + // std::vector< Int_t >::const_iterator rClsIt = fTransformationsReferenceClasses.begin(); + // const Event* trEv = ev; + // UInt_t nvars = 0, ntgts = 0, nspcts = 0; + // while (VariableTransformBase *trf = (VariableTransformBase*) trIt() ) { // shouldn't be the transformation called in the inverse order for the inversetransformation????? + // if (trf->IsCreated()) { + // trf->CountVariableTypes( nvars, ntgts, nspcts ); + // if( !(suppressIfNoTargets && ntgts==0) ) + // trEv = trf->InverseTransform(ev, (*rClsIt) ); + // } + // else break; + // rClsIt++; + // } + // return trEv; } //_______________________________________________________________________ -std::vector<TMVA::Event*>* TMVA::TransformationHandler::CalcTransformations( const std::vector<Event*>& events, - Bool_t createNewVector ) +const std::vector<TMVA::Event*>* TMVA::TransformationHandler::CalcTransformations( const std::vector<Event*>& events, + Bool_t createNewVector ) { // computation of transformation - std::vector<Event*>* tmpEvents = const_cast<std::vector<Event*>*>(&events); + if (fTransformations.GetEntries() <= 0) + return &events; + + std::vector<Event*>* tmpEvents = new std::vector<TMVA::Event*>(events.size()); + + for ( UInt_t ievt = 0; ievt<events.size(); ievt++) + tmpEvents->at(ievt) = new Event(*events.at(ievt)); + + + Bool_t replaceColl = kFALSE; // first let TransformCollection create a new vector TListIter trIt(&fTransformations); @@ -228,6 +237,7 @@ std::vector<TMVA::Event*>* TMVA::TransformationHandler::CalcTransformations( con } return 0; } + return tmpEvents; // give back the newly created event collection (containing the transformed events) } @@ -235,7 +245,7 @@ std::vector<TMVA::Event*>* TMVA::TransformationHandler::CalcTransformations( con std::vector<TMVA::Event*>* TMVA::TransformationHandler::TransformCollection( VariableTransformBase* trf, Int_t cls, std::vector<TMVA::Event*>* events, - Bool_t replace ) const + Bool_t replace) const { // a collection of transformations std::vector<TMVA::Event*>* tmpEvents = 0; @@ -258,7 +268,7 @@ std::vector<TMVA::Event*>* TMVA::TransformationHandler::TransformCollection( Var } //_______________________________________________________________________ -void TMVA::TransformationHandler::CalcStats( const std::vector<Event*>& events ) +void TMVA::TransformationHandler::CalcStats (const std::vector<Event*>& events ) { // method to calculate minimum, maximum, mean, and RMS for all @@ -293,7 +303,7 @@ void TMVA::TransformationHandler::CalcStats( const std::vector<Event*>& events ) } for (UInt_t ievt=0; ievt<nevts; ievt++) { - Event* ev = events[ievt]; + const Event* ev = events[ievt]; Int_t cls = ev->GetClass(); Double_t weight = ev->GetWeight(); @@ -453,8 +463,9 @@ TString TMVA::TransformationHandler::GetVariableAxisTitle( const VariableInfo& i return xtit; } + //_______________________________________________________________________ -void TMVA::TransformationHandler::PlotVariables( const std::vector<Event*>& events, TDirectory* theDirectory ) +void TMVA::TransformationHandler::PlotVariables (const std::vector<Event*>& events, TDirectory* theDirectory ) { // create histograms from the input variables // - histograms for all input variables @@ -726,7 +737,7 @@ void TMVA::TransformationHandler::PlotVariables( const std::vector<Event*>& even else if (fDataSetInfo.GetNClasses() == 2 && fDataSetInfo.GetClassInfo("Signal") != NULL && fDataSetInfo.GetClassInfo("Background") != NULL - ) { // TODO: ugly hack.. adapt to new framework + ) { // TODO: ugly hack.. adapt to new framework fRanking.push_back( new Ranking( GetName() + "Transformation", "Separation" ) ); for (UInt_t i=0; i<nvar; i++) { Double_t sep = gTools().GetSeparation( hVars.at(fDataSetInfo.GetClassInfo("Signal") ->GetNumber()).at(i), @@ -753,17 +764,17 @@ void TMVA::TransformationHandler::PlotVariables( const std::vector<Event*>& even Int_t counter = 0; TObject* o = NULL; while( (o = fRootBaseDir->FindObject(uniqueOutputDir)) != 0 ){ - uniqueOutputDir = outputDir+Form("_%d",counter); + uniqueOutputDir = outputDir+Form("_%d",counter); Log() << kINFO << "A " << o->ClassName() << " with name " << o->GetName() << " already exists in " << fRootBaseDir->GetPath() << ", I will try with "<<uniqueOutputDir<<"." << Endl; - ++counter; + ++counter; } -// TObject* o = fRootBaseDir->FindObject(outputDir); -// if (o != 0) { -// Log() << kFATAL << "A " << o->ClassName() << " with name " << o->GetName() << " already exists in " -// << fRootBaseDir->GetPath() << "("<<outputDir<<")" << Endl; -// } + // TObject* o = fRootBaseDir->FindObject(outputDir); + // if (o != 0) { + // Log() << kFATAL << "A " << o->ClassName() << " with name " << o->GetName() << " already exists in " + // << fRootBaseDir->GetPath() << "("<<outputDir<<")" << Endl; + // } localDir = fRootBaseDir->mkdir( uniqueOutputDir ); localDir->cd(); diff --git a/tmva/src/VariableDecorrTransform.cxx b/tmva/src/VariableDecorrTransform.cxx index 9104bbd82e05b..895424e70c786 100644 --- a/tmva/src/VariableDecorrTransform.cxx +++ b/tmva/src/VariableDecorrTransform.cxx @@ -73,7 +73,7 @@ void TMVA::VariableDecorrTransform::Initialize() } //_______________________________________________________________________ -Bool_t TMVA::VariableDecorrTransform::PrepareTransformation( const std::vector<Event*>& events ) +Bool_t TMVA::VariableDecorrTransform::PrepareTransformation (const std::vector<Event*>& events) { // calculate the decorrelation matrix and the normalization Initialize(); @@ -233,7 +233,7 @@ const TMVA::Event* TMVA::VariableDecorrTransform::InverseTransform( const TMVA:: //_______________________________________________________________________ -void TMVA::VariableDecorrTransform::CalcSQRMats( const std::vector<Event*>& events, Int_t maxCls ) +void TMVA::VariableDecorrTransform::CalcSQRMats( const std::vector< Event*>& events, Int_t maxCls ) { // compute square-root matrices for signal and background @@ -401,7 +401,7 @@ void TMVA::VariableDecorrTransform::ReadTransformationFromStream( std::istream& } //_______________________________________________________________________ -void TMVA::VariableDecorrTransform::PrintTransformation( ostream& ) +void TMVA::VariableDecorrTransform::PrintTransformation( std::ostream& ) { // prints the transformation matrix Int_t cls = 0; diff --git a/tmva/src/VariableGaussTransform.cxx b/tmva/src/VariableGaussTransform.cxx index 3640172d3075f..56615655ae576 100644 --- a/tmva/src/VariableGaussTransform.cxx +++ b/tmva/src/VariableGaussTransform.cxx @@ -88,7 +88,7 @@ void TMVA::VariableGaussTransform::Initialize() } //_______________________________________________________________________ -Bool_t TMVA::VariableGaussTransform::PrepareTransformation( const std::vector<Event*>& events ) +Bool_t TMVA::VariableGaussTransform::PrepareTransformation (const std::vector<Event*>& events) { // calculate the cumulative distributions Initialize(); @@ -187,7 +187,7 @@ const TMVA::Event* TMVA::VariableGaussTransform::Transform(const Event* const ev } //_______________________________________________________________________ -const TMVA::Event* TMVA::VariableGaussTransform::InverseTransform( const Event* const ev, Int_t cls ) const +const TMVA::Event* TMVA::VariableGaussTransform::InverseTransform(const Event* const ev, Int_t cls ) const { // apply the inverse Gauss or inverse uniform transformation @@ -247,7 +247,7 @@ const TMVA::Event* TMVA::VariableGaussTransform::InverseTransform( const Event* } //_______________________________________________________________________ -void TMVA::VariableGaussTransform::GetCumulativeDist( const std::vector<Event*>& events ) +void TMVA::VariableGaussTransform::GetCumulativeDist( const std::vector< Event*>& events ) { // fill the cumulative distributions @@ -674,7 +674,7 @@ Double_t TMVA::VariableGaussTransform::OldCumulant(Float_t x, TH1* h ) const { //_______________________________________________________________________ -void TMVA::VariableGaussTransform::PrintTransformation( ostream& ) +void TMVA::VariableGaussTransform::PrintTransformation( std::ostream& ) { // prints the transformation Int_t cls = 0; @@ -690,7 +690,14 @@ void TMVA::VariableGaussTransform::MakeFunction( std::ostream& fout, const TStri // const UInt_t nvar = fGet.size(); UInt_t numDist = GetNClasses() + 1; - Int_t nBins = 1000; + Int_t nBins = -1; + for (UInt_t icls=0; icls<numDist; icls++) { + for (UInt_t ivar=0; ivar<nvar; ivar++) { + Int_t nbin=(fCumulativePDF[ivar][icls])->GetGraph()->GetN(); + if (nbin > nBins) nBins=nbin; + } + } + // creates the gauss transformation function if (part==1) { fout << std::endl; @@ -698,8 +705,10 @@ void TMVA::VariableGaussTransform::MakeFunction( std::ostream& fout, const TStri fout << std::endl; // declare variables fout << " double cumulativeDist["<<nvar<<"]["<<numDist<<"]["<<nBins+1<<"];"<<std::endl; + fout << " double X["<<nvar<<"]["<<numDist<<"]["<<nBins+1<<"];"<<std::endl; fout << " double xMin["<<nvar<<"]["<<numDist<<"];"<<std::endl; fout << " double xMax["<<nvar<<"]["<<numDist<<"];"<<std::endl; + fout << " int nbins["<<nvar<<"]["<<numDist<<"];"<<std::endl; } if (part==2) { fout << std::endl; @@ -710,14 +719,18 @@ void TMVA::VariableGaussTransform::MakeFunction( std::ostream& fout, const TStri fout << "{" << std::endl; fout << " // Gauss/Uniform transformation, initialisation" << std::endl; fout << " nvar=" << nvar << ";" << std::endl; + for (UInt_t icls=0; icls<numDist; icls++) { + for (UInt_t ivar=0; ivar<nvar; ivar++) { + Int_t nbin=(fCumulativePDF[ivar][icls])->GetGraph()->GetN(); + fout << " nbins["<<ivar<<"]["<<icls<<"]="<<nbin<<";"<<std::endl; + } + } + // fill meat here // loop over nvar , cls, loop over nBins // fill cumulativeDist with fCumulativePDF[ivar][cls])->GetValue(vec(ivar) for (UInt_t icls=0; icls<numDist; icls++) { for (UInt_t ivar=0; ivar<nvar; ivar++) { - Double_t xmn=(fCumulativePDF[ivar][icls])->GetXmin(); - Double_t xmx=(fCumulativePDF[ivar][icls])->GetXmax(); - // Int_t idx = 0; try{ // idx = fGet.at(ivar).second; @@ -731,13 +744,15 @@ void TMVA::VariableGaussTransform::MakeFunction( std::ostream& fout, const TStri // Double_t xmn=Variables()[idx].GetMin(); // Double_t xmx=Variables()[idx].GetMax(); + Double_t xmn = (fCumulativePDF[ivar][icls])->GetGraph()->GetX()[0]; + Double_t xmx = (fCumulativePDF[ivar][icls])->GetGraph()->GetX()[(fCumulativePDF[ivar][icls])->GetGraph()->GetN()-1]; + + fout << " xMin["<<ivar<<"]["<<icls<<"]="<< gTools().StringFromDouble(xmn)<<";"<<std::endl; + fout << " xMax["<<ivar<<"]["<<icls<<"]="<<gTools().StringFromDouble(xmx)<<";"<<std::endl; + for (Int_t ibin=0; ibin<(fCumulativePDF[ivar][icls])->GetGraph()->GetN(); ibin++) { + fout << " cumulativeDist[" << ivar << "]["<< icls<< "]["<<ibin<<"]="<< gTools().StringFromDouble((fCumulativePDF[ivar][icls])->GetGraph()->GetY()[ibin])<< ";"<<std::endl; + fout << " X[" << ivar << "]["<< icls<< "]["<<ibin<<"]="<< gTools().StringFromDouble((fCumulativePDF[ivar][icls])->GetGraph()->GetX()[ibin])<< ";"<<std::endl; - fout << " xMin["<<ivar<<"]["<<icls<<"]="<<xmn<<";"<<std::endl; - fout << " xMax["<<ivar<<"]["<<icls<<"]="<<xmx<<";"<<std::endl; - for (Int_t ibin=0; ibin<=nBins; ibin++) { - Double_t xval = xmn + (xmx-xmn) / nBins * (ibin+0.5); - // ibin = (xval -xmin) / (xmax-xmin) *1000 - fout << " cumulativeDist[" << ivar << "]["<< icls<< "]["<<ibin<<"]="<< (fCumulativePDF[ivar][icls])->GetVal(xval)<< ";"<<std::endl; } } } @@ -753,49 +768,53 @@ void TMVA::VariableGaussTransform::MakeFunction( std::ostream& fout, const TStri fout << " else cls = "<<(fCumulativePDF[0].size()==1?0:2)<<";"<< std::endl; fout << " }"<< std::endl; - fout << " // copy the variables which are going to be transformed" << std::endl; + fout << " // copy the variables which are going to be transformed "<< std::endl; VariableTransformBase::MakeFunction(fout, fcncName, 0, trCounter, 0 ); - fout << " std::vector<double> dv(nvar);" << std::endl; - fout << " for (int ivar=0; ivar<nvar; ivar++) dv[ivar] = iv[indicesGet.at(ivar)];" << std::endl; - - - fout << " bool FlatNotGauss = "<< (fFlatNotGauss? "true": "false") <<";"<< std::endl; - fout << " double cumulant;"<< std::endl; - fout << " //const int nvar = "<<nvar<<";"<< std::endl; - fout << " for (int ivar=0; ivar<nvar; ivar++) {"<< std::endl; - // ibin = (xval -xMin) / (xMax-xMin) *1000 - fout << " int ibin1 = (int) ((dv[ivar]-xMin[ivar][cls])/(xMax[ivar][cls]-xMin[ivar][cls])*"<<nBins<<");"<<std::endl; - fout << " if (ibin1<=0) { cumulant = cumulativeDist[ivar][cls][0];}"<<std::endl; - fout << " else if (ibin1>="<<nBins<<") { cumulant = cumulativeDist[ivar][cls]["<<nBins<<"];}"<<std::endl; - fout << " else {"<<std::endl; - fout << " int ibin2 = ibin1+1;" << std::endl; - fout << " double dx = dv[ivar]-(xMin[ivar][cls]+"<< (1./nBins) - << " * ibin1* (xMax[ivar][cls]-xMin[ivar][cls]));" - << std::endl; - fout << " double eps=dx/(xMax[ivar][cls]-xMin[ivar][cls])*"<<nBins<<";"<<std::endl; - fout << " cumulant = eps*cumulativeDist[ivar][cls][ibin1] + (1-eps)*cumulativeDist[ivar][cls][ibin2];" << std::endl; - fout << " if (cumulant>1.-10e-10) cumulant = 1.-10e-10;"<< std::endl; - fout << " if (cumulant<10e-10) cumulant = 10e-10;"<< std::endl; - fout << " if (FlatNotGauss) dv[ivar] = cumulant;"<< std::endl; - fout << " else {"<< std::endl; - fout << " double maxErfInvArgRange = 0.99999999;"<< std::endl; - fout << " double arg = 2.0*cumulant - 1.0;"<< std::endl; - fout << " if (arg > maxErfInvArgRange) arg= maxErfInvArgRange;"<< std::endl; - fout << " if (arg < -maxErfInvArgRange) arg=-maxErfInvArgRange;"<< std::endl; - fout << " double inverf=0., stp=1. ;"<<std::endl; - fout << " while (stp >1.e-10){;"<<std::endl; - fout << " if (erf(inverf)>arg) inverf -=stp ;"<<std::endl; - fout << " else if (erf(inverf)<=arg && erf(inverf+stp)>=arg) stp=stp/5. ;"<<std::endl; - fout << " else inverf += stp;"<<std::endl; - fout << " } ;"<<std::endl; - fout << " //dv[ivar] = 1.414213562*TMath::ErfInverse(arg);"<< std::endl; - fout << " dv[ivar] = 1.414213562* inverf;"<< std::endl; - fout << " }"<< std::endl; - fout << " }"<< std::endl; - fout << " }"<< std::endl; - - fout << " // copy the transformed variables back" << std::endl; - fout << " for (int ivar=0; ivar<nvar; ivar++) iv[indicesPut.at(ivar)] = dv[ivar];" << std::endl; - fout << "}" << std::endl; + fout << " static std::vector<double> dv; "<< std::endl; + fout << " dv.resize(nvar); "<< std::endl; + fout << " for (int ivar=0; ivar<nvar; ivar++) dv[ivar] = iv[indicesGet.at(ivar)]; "<< std::endl; + fout << " "<< std::endl; + fout << " bool FlatNotGauss = "<< (fFlatNotGauss? "true": "false") <<"; "<< std::endl; + fout << " double cumulant; "<< std::endl; + fout << " //const int nvar = "<<nvar<<"; "<< std::endl; + fout << " for (int ivar=0; ivar<nvar; ivar++) { "<< std::endl; + fout << " int nbin = nbins[ivar][cls]; "<< std::endl; + fout << " int ibin=0; "<< std::endl; + fout << " while (dv[ivar] > X[ivar][cls][ibin]) ibin++; "<< std::endl; + fout << " "<< std::endl; + fout << " if (ibin<0) { ibin=0;} "<< std::endl; + fout << " if (ibin>=nbin) { ibin=nbin-1;} "<< std::endl; + fout << " int nextbin = ibin; "<< std::endl; + fout << " if ((dv[ivar] > X[ivar][cls][ibin] && ibin !=nbin-1) || ibin==0) "<< std::endl; + fout << " nextbin++; "<< std::endl; + fout << " else "<< std::endl; + fout << " nextbin--; "<< std::endl; + fout << " "<< std::endl; + fout << " double dx = X[ivar][cls][ibin]- X[ivar][cls][nextbin]; "<< std::endl; + fout << " double dy = cumulativeDist[ivar][cls][ibin] - cumulativeDist[ivar][cls][nextbin]; "<< std::endl; + fout << " cumulant = cumulativeDist[ivar][cls][ibin] + (dv[ivar] - X[ivar][cls][ibin])* dy/dx;"<< std::endl; + fout << " "<< std::endl; + fout << " "<< std::endl; + fout << " if (cumulant>1.-10e-10) cumulant = 1.-10e-10; "<< std::endl; + fout << " if (cumulant<10e-10) cumulant = 10e-10; "<< std::endl; + fout << " if (FlatNotGauss) dv[ivar] = cumulant; "<< std::endl; + fout << " else { "<< std::endl; + fout << " double maxErfInvArgRange = 0.99999999; "<< std::endl; + fout << " double arg = 2.0*cumulant - 1.0; "<< std::endl; + fout << " if (arg > maxErfInvArgRange) arg= maxErfInvArgRange; "<< std::endl; + fout << " if (arg < -maxErfInvArgRange) arg=-maxErfInvArgRange; "<< std::endl; + fout << " double inverf=0., stp=1. ; "<< std::endl; + fout << " while (stp >1.e-10){; "<< std::endl; + fout << " if (erf(inverf)>arg) inverf -=stp ; "<< std::endl; + fout << " else if (erf(inverf)<=arg && erf(inverf+stp)>=arg) stp=stp/5. ; "<< std::endl; + fout << " else inverf += stp; "<< std::endl; + fout << " } ; "<< std::endl; + fout << " //dv[ivar] = 1.414213562*TMath::ErfInverse(arg); "<< std::endl; + fout << " dv[ivar] = 1.414213562* inverf; "<< std::endl; + fout << " } "<< std::endl; + fout << " } "<< std::endl; + fout << " // copy the transformed variables back "<< std::endl; + fout << " for (int ivar=0; ivar<nvar; ivar++) iv[indicesPut.at(ivar)] = dv[ivar]; "<< std::endl; + fout << "} "<< std::endl; } } diff --git a/tmva/src/VariableIdentityTransform.cxx b/tmva/src/VariableIdentityTransform.cxx index d1ef19bc94b09..391ac56fcade4 100644 --- a/tmva/src/VariableIdentityTransform.cxx +++ b/tmva/src/VariableIdentityTransform.cxx @@ -48,7 +48,7 @@ void TMVA::VariableIdentityTransform::Initialize() } //_______________________________________________________________________ -Bool_t TMVA::VariableIdentityTransform::PrepareTransformation( const std::vector<Event*>& events) +Bool_t TMVA::VariableIdentityTransform::PrepareTransformation (const std::vector<Event*>& events) { // the identity does not need to be prepared, only calculate the normalization Initialize(); diff --git a/tmva/src/VariableNormalizeTransform.cxx b/tmva/src/VariableNormalizeTransform.cxx index 88865f39d1650..a4b5cfc0f8f7b 100644 --- a/tmva/src/VariableNormalizeTransform.cxx +++ b/tmva/src/VariableNormalizeTransform.cxx @@ -81,7 +81,7 @@ void TMVA::VariableNormalizeTransform::Initialize() } //_______________________________________________________________________ -Bool_t TMVA::VariableNormalizeTransform::PrepareTransformation( const std::vector<Event*>& events ) +Bool_t TMVA::VariableNormalizeTransform::PrepareTransformation (const std::vector<Event*>& events) { // prepare transformation if (!IsEnabled() || IsCreated()) return kTRUE; @@ -154,7 +154,7 @@ const TMVA::Event* TMVA::VariableNormalizeTransform::Transform( const TMVA::Even } //_______________________________________________________________________ -const TMVA::Event* TMVA::VariableNormalizeTransform::InverseTransform( const TMVA::Event* const ev, Int_t cls ) const +const TMVA::Event* TMVA::VariableNormalizeTransform::InverseTransform(const TMVA::Event* const ev, Int_t cls ) const { // apply the inverse transformation if (!IsCreated()) Log() << kFATAL << "Transformation not yet created" << Endl; @@ -198,7 +198,7 @@ const TMVA::Event* TMVA::VariableNormalizeTransform::InverseTransform( const TMV } //_______________________________________________________________________ -void TMVA::VariableNormalizeTransform::CalcNormalizationParams( const std::vector<Event*>& events ) +void TMVA::VariableNormalizeTransform::CalcNormalizationParams( const std::vector< Event*>& events ) { // compute offset and scale from min and max if (events.size() <= 1) @@ -226,7 +226,7 @@ void TMVA::VariableNormalizeTransform::CalcNormalizationParams( const std::vecto std::vector<Event*>::const_iterator evIt = events.begin(); for (;evIt!=events.end();evIt++) { // loop over all events - TMVA::Event* event = (*evIt); // get the event + const TMVA::Event* event = (*evIt); // get the event UInt_t cls = (*evIt)->GetClass(); // get the class of this event @@ -294,7 +294,7 @@ std::vector<TString>* TMVA::VariableNormalizeTransform::GetTransformationStrings //_______________________________________________________________________ void TMVA::VariableNormalizeTransform::WriteTransformationToStream( std::ostream& o ) const { - // write the decorrelation matrix to the stream + // write the transformation to the stream o << "# min max for all variables for all classes one after the other and as a last entry for all classes together" << std::endl; Int_t numC = GetNClasses()+1; @@ -470,7 +470,8 @@ void TMVA::VariableNormalizeTransform::BuildTransformationFromVarInfo( const std for(std::vector<TMVA::VariableInfo>::const_iterator v = var.begin(); v!=var.end(); ++v, ++vidx) { fMin[cls][vidx] = v->GetMin(); fMax[cls][vidx] = v->GetMax(); - } + fGet.push_back(std::pair<Char_t,UInt_t>('v',vidx)); + } } SetCreated(); } @@ -519,7 +520,7 @@ void TMVA::VariableNormalizeTransform::ReadTransformationFromStream( std::istrea } //_______________________________________________________________________ -void TMVA::VariableNormalizeTransform::PrintTransformation( ostream& /* o */ ) +void TMVA::VariableNormalizeTransform::PrintTransformation( std::ostream& /* o */ ) { // prints the transformation ranges @@ -587,7 +588,8 @@ void TMVA::VariableNormalizeTransform::MakeFunction( std::ostream& fout, const T fout << " const int nVar = " << nVar << ";" << std::endl << std::endl; fout << " // get indices of used variables" << std::endl; VariableTransformBase::MakeFunction(fout, fcncName, 0, trCounter, 0 ); - fout << " std::vector<double> dv(nVar);" << std::endl; + fout << " static std::vector<double> dv;" << std::endl; // simply made it static so it doesn't need to be re-booked every time + fout << " dv.resize(nVar);" << std::endl; fout << " for (int ivar=0; ivar<nVar; ivar++) dv[ivar] = iv[indicesGet.at(ivar)];" << std::endl; fout << " for (int ivar=0;ivar<"<<nVar<<";ivar++) {" << std::endl; diff --git a/tmva/src/VariablePCATransform.cxx b/tmva/src/VariablePCATransform.cxx index 743d9fa682001..0b47a5e0e49af 100644 --- a/tmva/src/VariablePCATransform.cxx +++ b/tmva/src/VariablePCATransform.cxx @@ -74,7 +74,7 @@ void TMVA::VariablePCATransform::Initialize() } //_______________________________________________________________________ -Bool_t TMVA::VariablePCATransform::PrepareTransformation( const std::vector<Event*>& events ) +Bool_t TMVA::VariablePCATransform::PrepareTransformation (const std::vector<Event*>& events) { // calculate the principal components using the ROOT class TPrincipal // and the normalization @@ -189,7 +189,7 @@ const TMVA::Event* TMVA::VariablePCATransform::InverseTransform( const Event* co } //_______________________________________________________________________ -void TMVA::VariablePCATransform::CalculatePrincipalComponents( const std::vector<Event*>& events ) +void TMVA::VariablePCATransform::CalculatePrincipalComponents( const std::vector< Event*>& events ) { // calculate the principal components for the signal and the background data // it uses the MakePrincipal method of ROOT's TPrincipal class @@ -218,7 +218,7 @@ void TMVA::VariablePCATransform::CalculatePrincipalComponents( const std::vector std::vector<Float_t> input; std::vector<Char_t> mask; for (ievt=0; ievt<entries; ievt++) { - Event* ev = events[ievt]; + const Event* ev = events[ievt]; UInt_t cls = ev->GetClass(); Bool_t hasMaskedEntries = GetInput( ev, input, mask ); diff --git a/tmva/src/VariableRearrangeTransform.cxx b/tmva/src/VariableRearrangeTransform.cxx index a183470b6caa9..2af1cd3dd7b30 100644 --- a/tmva/src/VariableRearrangeTransform.cxx +++ b/tmva/src/VariableRearrangeTransform.cxx @@ -60,7 +60,7 @@ void TMVA::VariableRearrangeTransform::Initialize() } //_______________________________________________________________________ -Bool_t TMVA::VariableRearrangeTransform::PrepareTransformation( const std::vector<Event*>& /*events*/ ) +Bool_t TMVA::VariableRearrangeTransform::PrepareTransformation (const std::vector<Event*>& /*events*/) { // prepare transformation --> (nothing to do) if (!IsEnabled() || IsCreated()) return kTRUE; @@ -149,7 +149,7 @@ void TMVA::VariableRearrangeTransform::ReadFromXML( void* trfnode ) } //_______________________________________________________________________ -void TMVA::VariableRearrangeTransform::PrintTransformation( ostream& ) +void TMVA::VariableRearrangeTransform::PrintTransformation( std::ostream& ) { // prints the transformation ranges } diff --git a/tmva/src/VariableTransformBase.cxx b/tmva/src/VariableTransformBase.cxx index bd5456a6fcc61..5cef79cbe23ec 100644 --- a/tmva/src/VariableTransformBase.cxx +++ b/tmva/src/VariableTransformBase.cxx @@ -451,7 +451,7 @@ void TMVA::VariableTransformBase::CountVariableTypes( UInt_t& nvars, UInt_t& ntg //_______________________________________________________________________ -void TMVA::VariableTransformBase::CalcNorm( const std::vector<Event*>& events ) +void TMVA::VariableTransformBase::CalcNorm( const std::vector<const Event*>& events ) { // TODO --> adapt to variable,target,spectator selection // method to calculate minimum, maximum, mean, and RMS for all @@ -781,8 +781,10 @@ void TMVA::VariableTransformBase::MakeFunction( std::ostream& fout, const TStrin if( part == 0 ){ // definitions fout << std::endl; fout << " // define the indices of the variables which are transformed by this transformation" << std::endl; - fout << " std::vector<int> indicesGet;" << std::endl; - fout << " std::vector<int> indicesPut;" << std::endl << std::endl; + fout << " static std::vector<int> indicesGet;" << std::endl; + fout << " static std::vector<int> indicesPut;" << std::endl << std::endl; + fout << " if ( indicesGet.empty() ) { " << std::endl; + fout << " indicesGet.reserve(fNvars);" << std::endl; for( ItVarTypeIdxConst itEntry = fGet.begin(), itEntryEnd = fGet.end(); itEntry != itEntryEnd; ++itEntry ) { Char_t type = (*itEntry).first; @@ -790,7 +792,7 @@ void TMVA::VariableTransformBase::MakeFunction( std::ostream& fout, const TStrin switch( type ) { case 'v': - fout << " indicesGet.push_back( " << idx << ");" << std::endl; + fout << " indicesGet.push_back( " << idx << ");" << std::endl; break; case 't': Log() << kWARNING << "MakeClass doesn't work with transformation of targets. The results will be wrong!" << Endl; @@ -802,6 +804,9 @@ void TMVA::VariableTransformBase::MakeFunction( std::ostream& fout, const TStrin Log() << kFATAL << "VariableTransformBase/GetInput : unknown type '" << type << "'." << Endl; } } + fout << " } " << std::endl; + fout << " if ( indicesPut.empty() ) { " << std::endl; + fout << " indicesPut.reserve(fNvars);" << std::endl; for( ItVarTypeIdxConst itEntry = fPut.begin(), itEntryEnd = fPut.end(); itEntry != itEntryEnd; ++itEntry ) { Char_t type = (*itEntry).first; @@ -809,7 +814,7 @@ void TMVA::VariableTransformBase::MakeFunction( std::ostream& fout, const TStrin switch( type ) { case 'v': - fout << " indicesPut.push_back( " << idx << ");" << std::endl; + fout << " indicesPut.push_back( " << idx << ");" << std::endl; break; case 't': Log() << kWARNING << "MakeClass doesn't work with transformation of targets. The results will be wrong!" << Endl; @@ -822,6 +827,7 @@ void TMVA::VariableTransformBase::MakeFunction( std::ostream& fout, const TStrin } } + fout << " } " << std::endl; fout << std::endl; }else if( part == 1){ diff --git a/tmva/test/.rootrc b/tmva/test/.rootrc index 3aed456b8d390..67a49ddb86e11 100644 --- a/tmva/test/.rootrc +++ b/tmva/test/.rootrc @@ -1,6 +1,8 @@ -Unix.*.Root.MacroPath: . +Unix.*.Root.MacroPath: .:$TMVASYS/test:$(ROOTSYS)/macros + +Unix.*.Root.DynamicPath: $TMVASYS/lib:$(ROOTSYS)/lib + -Unix.*.Root.DynamicPath: ../lib Rint.Logon: TMVAlogon.C Rint.Logoff: TMVAlogoff.C Root.History: ./.root_hist diff --git a/tmva/test/BDTControlPlots.C b/tmva/test/BDTControlPlots.C index 86fb62edb9ad2..5abfd8ebb4f89 100644 --- a/tmva/test/BDTControlPlots.C +++ b/tmva/test/BDTControlPlots.C @@ -2,20 +2,26 @@ #include <string> #include "tmvaglob.C" +#include "TH1.h" +#include "TGraph.h" // input: - Input file (result from TMVA), // - use of TMVA plotting TStyle +void bdtcontrolplots(TDirectory *); + void BDTControlPlots( TString fin = "TMVA.root", Bool_t useTMVAStyle = kTRUE ) { // set style and remove existing canvas' TMVAGlob::Initialize( useTMVAStyle ); // checks if file with name "fin" is already open, and if not opens one - TFile* file = TMVAGlob::OpenFile( fin ); + TFile* file; + file = TMVAGlob::OpenFile( fin ); // get all titles of the method BDT TList titles; - UInt_t ninst = TMVAGlob::GetListOfTitles("Method_BDT",titles); + TString methodName = "Method_BDT"; + UInt_t ninst = TMVAGlob::GetListOfTitles(methodName,titles); if (ninst==0) { cout << "Could not locate directory 'Method_BDT' in file " << fin << endl; return; @@ -36,7 +42,7 @@ void bdtcontrolplots( TDirectory *bdtdir ) { Int_t width = 900; Int_t height = 600; - char cn[100]; + char cn[100], cn2[100]; const TString titName = bdtdir->GetName(); sprintf( cn, "cv_%s", titName.Data() ); TCanvas *c = new TCanvas( cn, Form( "%s Control Plots", titName.Data() ), @@ -44,13 +50,16 @@ void bdtcontrolplots( TDirectory *bdtdir ) { c->Divide(3,2); - const TString titName = bdtdir->GetName(); - TString hname[nPlots]={"BoostMonitor","BoostWeight","BoostWeightVsTree","ErrFractHist","NodesBeforePruning",titName+"_FOMvsIterFrame"} + + TString hname[nPlots]={"BoostMonitor","BoostWeight","BoostWeightVsTree","ErrFractHist","NodesBeforePruning",titName+"_FOMvsIterFrame"}; + + Bool_t BoostMonitorIsDone=kFALSE; for (Int_t i=0; i<nPlots; i++){ Int_t color = 4; - TPad * cPad = (TPad*)c->cd(i+1); + TPad * cPad; + cPad = (TPad*)c->cd(i+1); TH1 *h = (TH1*) bdtdir->Get(hname[i]); if (h){ @@ -69,22 +78,96 @@ void bdtcontrolplots( TDirectory *bdtdir ) { h2->SetLineColor(2); h2->Draw("same"); } - if(hname[i]=="BoostMonitor"){ // a plot only available in case of automatic parameter option tuning + if(hname[i]=="BoostMonitor"){ // a plot only available in case DoBoostMontior option has bee set TGraph *g = (TGraph*) bdtdir->Get("BoostMonitorGraph"); g->Draw("LP*"); + BoostMonitorIsDone = kTRUE; } - if(hname[i]==titName+"_FOMvsIterFrame"){ // a plot only available in case of automatic parameter option tuning + if(hname[i]==titName+"_FOMvsIterFrame"){ // a plot only available in case DoBoostMontior option has bee set TGraph *g = (TGraph*) bdtdir->Get(titName+"_FOMvsIter"); g->Draw(); } c->Update(); } } + + + TCanvas *c2 = NULL; + if (BoostMonitorIsDone){ + sprintf( cn2, "cv2_%s", titName.Data() ); + c2 = new TCanvas( cn2, Form( "%s BoostWeights", titName.Data() ), + 1200, 1200 ); + c2->Divide(5,5); + Int_t ipad=1; + + TIter keys( bdtdir->GetListOfKeys() ); + TKey *key; + // gDirectory->ls(); + while ( (key = (TKey*)keys.Next()) && ipad < 26) { + TObject *obj=key->ReadObj(); + if (obj->IsA()->InheritsFrom(TH1::Class())){ + TH1F *hx = (TH1F*)obj; + TString hname(Form("%s",obj->GetTitle())); + if (hname.Contains("BoostWeightsInTreeB")){ + c2->cd(ipad++); + hx->SetLineColor(4); + hx->Draw(); + hname.ReplaceAll("TreeB","TreeS"); + bdtdir->GetObject(hname.Data(),hx); + if (hx) { + hx->SetLineColor(2); + hx->Draw("same"); + } + } + c2->Update(); + } + } + + } // write to file TString fname = Form( "plots/%s_ControlPlots", titName.Data() ); TMVAGlob::imgconv( c, fname ); + if (c2){ + fname = Form( "plots/%s_ControlPlots2", titName.Data() ); + TMVAGlob::imgconv( c2, fname ); + } + + TCanvas *c3 = NULL; + if (BoostMonitorIsDone){ + sprintf( cn2, "cv3_%s", titName.Data() ); + c3 = new TCanvas( cn2, Form( "%s Variables", titName.Data() ), + 1200, 1200 ); + c3->Divide(5,5); + Int_t ipad=1; + + TIter keys( bdtdir->GetListOfKeys() ); + TKey *key; + // gDirectory->ls(); + while ( (key = (TKey*)keys.Next()) && ipad < 26) { + TObject *obj=key->ReadObj(); + if (obj->IsA()->InheritsFrom(TH1::Class())){ + TH1F *hx = (TH1F*)obj; + TString hname(Form("%s",obj->GetTitle())); + if (hname.Contains("SigVar0AtTree")){ + c3->cd(ipad++); + hx->SetLineColor(4); + hx->Draw(); + hname.ReplaceAll("Sig","Bkg"); + bdtdir->GetObject(hname.Data(),hx); + if (hx) { + hx->SetLineColor(2); + hx->Draw("same"); + } + } + c3->Update(); + } + } + + } + + } diff --git a/tmva/test/Boost.C b/tmva/test/Boost.C index 87e41da9ab480..38357faac8f54 100644 --- a/tmva/test/Boost.C +++ b/tmva/test/Boost.C @@ -12,7 +12,6 @@ #include "TSystem.h" #include "TROOT.h" -#include "TMVAGui.C" #ifndef __CINT__ #include "TMVA/Tools.h" @@ -22,6 +21,16 @@ using namespace TMVA; void Boost(){ + // This loads the library + TMVA::Tools::Instance(); + + // to get access to the GUI and all tmva macros + TString tmva_dir(TString(gRootDir) + "/tmva"); + if(gSystem->Getenv("TMVASYS")) + tmva_dir = TString(gSystem->Getenv("TMVASYS")); + gROOT->SetMacroPath(tmva_dir + "/test/:" + gROOT->GetMacroPath() ); + gROOT->ProcessLine(".L TMVAGui.C"); + TString outfileName = "boost.root"; TFile* outputFile = TFile::Open( outfileName, "RECREATE" ); TMVA::Factory *factory = new TMVA::Factory( "TMVAClassification", outputFile, diff --git a/tmva/test/Boost2.C b/tmva/test/Boost2.C index 63a80667cec27..a1caeb7c53027 100644 --- a/tmva/test/Boost2.C +++ b/tmva/test/Boost2.C @@ -12,7 +12,6 @@ #include "TSystem.h" #include "TROOT.h" -#include "TMVAGui.C" #ifndef __CINT__ #include "TMVA/Tools.h" @@ -22,6 +21,16 @@ using namespace TMVA; void Boost2(){ + // This loads the library + TMVA::Tools::Instance(); + + // to get access to the GUI and all tmva macros + TString tmva_dir(TString(gRootDir) + "/tmva"); + if(gSystem->Getenv("TMVASYS")) + tmva_dir = TString(gSystem->Getenv("TMVASYS")); + gROOT->SetMacroPath(tmva_dir + "/test/:" + gROOT->GetMacroPath() ); + gROOT->ProcessLine(".L TMVAGui.C"); + TString outfileName = "boost.root"; TFile* outputFile = TFile::Open( outfileName, "RECREATE" ); TMVA::Factory *factory = new TMVA::Factory( "TMVAClassification", outputFile, diff --git a/tmva/test/BoostControlPlots.C b/tmva/test/BoostControlPlots.C index d4dd2f81fc1aa..d6294339c60ba 100644 --- a/tmva/test/BoostControlPlots.C +++ b/tmva/test/BoostControlPlots.C @@ -35,7 +35,7 @@ void BoostControlPlots( TString fin = "TMVA.root", Bool_t useTMVAStyle = kTRUE ) void boostcontrolplots( TDirectory *boostdir ) { - const Int_t nPlots = 4; + const Int_t nPlots = 6; Int_t width = 900; Int_t height = 900; @@ -44,12 +44,16 @@ void boostcontrolplots( TDirectory *boostdir ) { sprintf( cn, "cv_%s", titName.Data() ); TCanvas *c = new TCanvas( cn, Form( "%s Control Plots", titName.Data() ), width, height ); - c->Divide(2,3); + c->Divide(2,4); const TString titName = boostdir->GetName(); + //TString hname[nPlots]={"Booster_BoostWeight","Booster_MethodWeight","Booster_ErrFraction","Booster_OrigErrFraction"}; - TString hname[nPlots]={"Booster_BoostWeight","Booster_MethodWeight","Booster_ErrFraction","Booster_OrigErrFraction"}; + TString hname[nPlots]={"BoostWeight","MethodWeight","ErrFraction","SoverBtotal","SeparationGain", "SeparationGain"}; + + // Note: the ROCIntegral plots are only filled for option "Boost_DetailedMonitoring=ture" currently not filled... + // TString hname[nPlots]={"BoostWeight","MethodWeight","ErrFraction","ROCIntegral_test"}; for (Int_t i=0; i<nPlots; i++){ Int_t color = 4; @@ -69,8 +73,8 @@ void boostcontrolplots( TDirectory *boostdir ) { // draw combined ROC plots - TString hname_roctest[2] ={"Booster_ROCIntegral_test", "Booster_ROCIntegralBoosted_test"}; - TString hname_roctrain[2]={"Booster_ROCIntegral_train", "Booster_ROCIntegralBoosted_train"}; + TString hname_roctest[2] ={"ROCIntegral_test", "ROCIntegralBoosted_test"}; + TString hname_roctrain[2]={"ROCIntegral_train", "ROCIntegralBoosted_train"}; TString htitle[2] = {"ROC integral of single classifier", "ROC integral of boosted method"} for (Int_t i=0; i<2; i++){ @@ -80,7 +84,11 @@ void boostcontrolplots( TDirectory *boostdir ) { TH1 *htrain = (TH1*) boostdir->Get(hname_roctrain[i]); // check if filled - Bool_t histFilled = (htest->GetMaximum() > 0 || htrain->GetMaximum() > 0); + // Bool_t histFilled = (htest->GetMaximum() > 0 || htrain->GetMaximum() > 0); + Bool_t histFilled = (htest && htrain); + + if (!htest) htest = new TH1F("htest","",2,0,1); + if (!htrain) htrain = new TH1F("htrain","",2,0,1); htest->SetTitle(htitle[i]); htest->SetMaximum(1.0); @@ -116,8 +124,8 @@ void boostcontrolplots( TDirectory *boostdir ) { TText* t = new TText(); t->SetTextSize( 0.056 ); t->SetTextColor( 2 ); - t->DrawText( 1, 0.6, "Use MethodBoost option: \"DetailedMonitoring\" " ); - t->DrawText( 1, 0.51, "to fill this histograms" ); + t->DrawTextNDC( .2, 0.6, "Use MethodBoost option: \"Boost_DetailedMonitoring\" " ); + t->DrawTextNDC( .2, 0.51, "to fill this histograms" ); } c->Update(); @@ -126,7 +134,7 @@ void boostcontrolplots( TDirectory *boostdir ) { // write to file TString fname = Form( "plots/%s_ControlPlots", titName.Data() ); TMVAGlob::imgconv( c, fname ); - + } diff --git a/tmva/test/Makefile b/tmva/test/Makefile index 41c7fe2b1d833..c9c3bc8843695 100644 --- a/tmva/test/Makefile +++ b/tmva/test/Makefile @@ -5,8 +5,8 @@ MAKEFLAGS = --no-print-directory -r -s -INCLUDE = -I../ $(shell root-config --cflags) -LIBS = -L../lib -lTMVA.1 $(shell root-config --libs) -lMLP -lTreePlayer -lMinuit +INCLUDE = -I$(TMVASYS)/ $(shell root-config --cflags) +LIBS = -L$(TMVASYS)/lib -lTMVA.1 $(shell root-config --libs) -lMLP -lTreePlayer -lMinuit BINS = TMVAClassification \ TMVAClassificationCategory \ @@ -20,9 +20,9 @@ BINS = TMVAClassification \ UNITTESTS = EVENT CREATE_DATASET -TMVALIB = ../lib/libTMVA.1.so +TMVALIB = $(TMVASYS)/lib/libTMVA.1.so -PUBLISH = ../www +PUBLISH = $(TMVASYS)/www include nightlyClassifiers.make @@ -38,41 +38,41 @@ profileRegression: TMVARegression rm -f regression.profile rm -f callgrindRegression.log valgrind --tool=callgrind --callgrind-out-file=regression.profile ./TMVARegression | tee callgrindRegression.log - callgrind_annotate --inclusive=yes --tree=both --auto=yes regression.profile ../src/*.cxx ../src/*.h + callgrind_annotate --inclusive=yes --tree=both --auto=yes regression.profile $(TMVASYS)/src/*.cxx $(TMVASYS)/src/*.h @echo "to see the profile do \"kcachegrind regression.profile\"" profileClassification: TMVAClassification rm -f classification.profile rm -f callgrindClassification.log valgrind --tool=callgrind --callgrind-out-file=classification.profile ./TMVAClassification | tee callgrindClassification.log - callgrind_annotate --inclusive=yes --tree=both --auto=yes classification.profile ../src/*.cxx ../src/*.h + callgrind_annotate --inclusive=yes --tree=both --auto=yes classification.profile $(TMVASYS)/src/*.cxx $(TMVASYS)/src/*.h @echo "to see the profile do \"kcachegrind classification.profile\"" clean: rm -f $(BINS) -$(TMVALIB): ../src/*.cxx ../inc/*.h +$(TMVALIB): $(TMVASYS)/src/*.cxx $(TMVASYS)/inc/*.h $(MAKE) -C .. install: @mkdir -p $(PUBLISH) - @cp -u ../test/pad.inc $(PUBLISH) - @cp -u ../test/tabView.js $(PUBLISH) - @cp -u ../test/tmva_nightly.css $(PUBLISH) - @cp -u ../test/index.php $(PUBLISH) - @cp -u ../macros/tmva_logo.gif $(PUBLISH) + @cp -u $(TMVASYS)/test/pad.inc $(PUBLISH) + @cp -u $(TMVASYS)/test/tabView.js $(PUBLISH) + @cp -u $(TMVASYS)/test/tmva_nightly.css $(PUBLISH) + @cp -u $(TMVASYS)/test/index.php $(PUBLISH) + @cp -u $(TMVASYS)/macros/tmva_logo.gif $(PUBLISH) -ut: ../test/stressTMVA $(UNITTESTS) +ut: $(TMVASYS)/test/stressTMVA $(UNITTESTS) @echo "UNITTESTS FINISHED" $(UNITTESTS): @echo "unit $@ -------------------------------------------- " - ../test/stressTMVA $@ + $(TMVASYS)/test/stressTMVA $@ -../test/stressTMVA: ../test/stressTMVA.cxx - make -C ../test/ +$(TMVASYS)/test/stressTMVA: $(TMVASYS)/test/stressTMVA.cxx + make -C $(TMVASYS)/test/ TMVA.root: $(TMVALIB) TMVAClassification nightlyClassifiers.make @@ -81,13 +81,13 @@ TMVA.root: $(TMVALIB) TMVAClassification nightlyClassifiers.make TMVApp.root: TMVAClassificationApplication TMVA.root ./TMVAClassificationApplication $(TESTCLASSIFIERS) -$(PUBLISH)/uptodate: install TMVApp.root ../test/CompareHistsTrainAndApplied.C - root -l -b -q ../test/CompareHistsTrainAndApplied.C +$(PUBLISH)/uptodate: install TMVApp.root $(TMVASYS)/test/CompareHistsTrainAndApplied.C + root -l -b -q $(TMVASYS)/test/CompareHistsTrainAndApplied.C touch $@ -$(BINS): % : %.cxx ../inc/*.h +$(BINS): % : %.cxx $(TMVASYS)/inc/*.h @echo -n "Building $@ ... " $(CXX) $(CCFLAGS) $< $(INCLUDE) $(LIBS) -g -o $@ @echo "Done" diff --git a/tmva/test/PlotDecisionBoundary.C b/tmva/test/PlotDecisionBoundary.C index 16f90c2e85ea3..1579c1173818b 100755 --- a/tmva/test/PlotDecisionBoundary.C +++ b/tmva/test/PlotDecisionBoundary.C @@ -21,7 +21,6 @@ #include "TH2F.h" #include "TH3F.h" -#include "TMVAGui.C" #include "tmvaglob.C" #if not defined(__CINT__) || defined(__MAKECINT__) @@ -84,7 +83,7 @@ void PlotDecisionBoundary( TString weightFile = "weights/TMVAClassification_BDT. // create a set of variables and declare them to the reader // - the variable names must corresponds in name and type to // those given in the weight file(s) that you use - Double_t var0, var1; + Float_t var0, var1; reader->AddVariable( v0, &var0 ); reader->AddVariable( v1, &var1 ); diff --git a/tmva/test/PlotFoams.C b/tmva/test/PlotFoams.C index 8982b09f73d73..5b24c4d372670 100644 --- a/tmva/test/PlotFoams.C +++ b/tmva/test/PlotFoams.C @@ -1,6 +1,11 @@ #include "tmvaglob.C" #include "TControlBar.h" #include "TMap.h" +#include "TVectorT.h" +#include "TLine.h" +#include "TPaveText.h" +#include "TMVA/PDEFoamKernelBase.h" +#include "TMVA/PDEFoamKernelTrivial.h" #include <sstream> #include <string> @@ -8,11 +13,15 @@ #include "TMVA/PDEFoam.h" -void PlotFoams( TString fin = "weights/TMVAClassification_PDEFoam.weights_foams.root", - bool useTMVAStyle=kTRUE ) +void Plot1DimFoams(TList&, TMVA::ECellValue, const TString&, TMVA::PDEFoamKernelBase*); +void PlotNDimFoams(TList&, TMVA::ECellValue, const TString&, TMVA::PDEFoamKernelBase*); +void DrawCell(TMVA::PDEFoamCell*, TMVA::PDEFoam*, Double_t, Double_t, Double_t, Double_t); + +void PlotFoams( TString fileName = "weights/TMVAClassification_PDEFoam.weights_foams.root", + bool useTMVAStyle = kTRUE ) { - cout << "read file: " << fin << endl; - TFile *file = TFile::Open(fin); + cout << "read file: " << fileName << endl; + TFile *file = TFile::Open(fileName); // set style and remove existing canvas' TMVAGlob::Initialize( useTMVAStyle ); @@ -22,29 +31,29 @@ void PlotFoams( TString fin = "weights/TMVAClassification_PDEFoam.weights_foams. if ((gDirectory->Get("SignalFoam") && gDirectory->Get("BgFoam")) || gDirectory->Get("MultiTargetRegressionFoam")) { TString macro = Form( "Plot(\"%s\", TMVA::kValueDensity, \"Event density\", %s)", - fin.Data(), (useTMVAStyle ? "kTRUE" : "kFALSE") ); + fileName.Data(), (useTMVAStyle ? "kTRUE" : "kFALSE") ); cbar->AddButton( "Event density", macro, "Plot event density", "button" ); } else if (gDirectory->Get("DiscrFoam") || gDirectory->Get("MultiClassFoam0")){ TString macro = Form( "Plot(\"%s\", TMVA::kValue, \"Discriminator\", %s)", - fin.Data(), (useTMVAStyle ? "kTRUE" : "kFALSE") ); + fileName.Data(), (useTMVAStyle ? "kTRUE" : "kFALSE") ); cbar->AddButton( "Discriminator", macro, "Plot discriminator", "button" ); } else if (gDirectory->Get("MonoTargetRegressionFoam")){ TString macro = Form( "Plot(\"%s\", TMVA::kValue, \"Target\", %s)", - fin.Data(), (useTMVAStyle ? "kTRUE" : "kFALSE") ); + fileName.Data(), (useTMVAStyle ? "kTRUE" : "kFALSE") ); cbar->AddButton( "Target", macro, "Plot target", "button" ); } else { - cout << "Error: no foams found in file: " << fin << endl; + cout << "Error: no foams found in file: " << fileName << endl; return; } TString macro_rms = Form( "Plot(\"%s\", TMVA::kRms, \"Variance\", %s)", - fin.Data(), (useTMVAStyle ? "kTRUE" : "kFALSE") ); + fileName.Data(), (useTMVAStyle ? "kTRUE" : "kFALSE") ); cbar->AddButton( "Variance", macro_rms, "Plot variance", "button" ); TString macro_rms_ov_mean = Form( "Plot(\"%s\", TMVA::kRmsOvMean, \"Variance/Mean\", %s)", - fin.Data(), (useTMVAStyle ? "kTRUE" : "kFALSE") ); + fileName.Data(), (useTMVAStyle ? "kTRUE" : "kFALSE") ); cbar->AddButton( "Variance/Mean", macro_rms_ov_mean, "Plot variance over mean", "button" ); TString macro_cell_tree = Form( "PlotCellTree(\"%s\", \"Cell tree\", %s)", - fin.Data(), (useTMVAStyle ? "kTRUE" : "kFALSE") ); + fileName.Data(), (useTMVAStyle ? "kTRUE" : "kFALSE") ); cbar->AddButton( "Cell tree", macro_cell_tree, "Plot cell tree", "button" ); cbar->Show(); @@ -52,45 +61,50 @@ void PlotFoams( TString fin = "weights/TMVAClassification_PDEFoam.weights_foams. } // foam plotting macro -void Plot( TString fin = "weights/TMVAClassification_PDEFoam.weights_foams.root", - TMVA::ECellValue cv, TString cv_long, bool useTMVAStyle=kTRUE ) +void Plot(TString fileName, TMVA::ECellValue cv, TString cv_long, bool useTMVAStyle = kTRUE) { - cout << "read file: " << fin << endl; - TFile *file = TFile::Open(fin); + cout << "read file: " << fileName << endl; + TFile *file = TFile::Open(fileName); gStyle->SetNumberContours(999); if (useTMVAStyle) TMVAGlob::SetTMVAStyle(); - // find foams and foam type + // fileNamed foams and foam type + TMVA::PDEFoam* SignalFoam = (TMVA::PDEFoam*) gDirectory->Get("SignalFoam"); + TMVA::PDEFoam* BgFoam = (TMVA::PDEFoam*) gDirectory->Get("BgFoam"); + TMVA::PDEFoam* DiscrFoam = (TMVA::PDEFoam*) gDirectory->Get("DiscrFoam"); + TMVA::PDEFoam* MultiClassFoam0 = (TMVA::PDEFoam*) gDirectory->Get("MultiClassFoam0"); + TMVA::PDEFoam* MonoTargetRegressionFoam = (TMVA::PDEFoam*) gDirectory->Get("MonoTargetRegressionFoam"); + TMVA::PDEFoam* MultiTargetRegressionFoam = (TMVA::PDEFoam*) gDirectory->Get("MultiTargetRegressionFoam"); TList foam_list; // the foams and their captions - if (gDirectory->Get("SignalFoam") && gDirectory->Get("BgFoam")){ + if (SignalFoam && BgFoam) { foam_list.Add(new TPair(SignalFoam, new TObjString("Signal Foam"))); foam_list.Add(new TPair(BgFoam, new TObjString("Background Foam"))); - } else if (gDirectory->Get("DiscrFoam")){ + } else if (DiscrFoam) { foam_list.Add(new TPair(DiscrFoam, new TObjString("Discriminator Foam"))); - } else if (gDirectory->Get("MultiClassFoam0")){ + } else if (MultiClassFoam0) { UInt_t cls = 0; TMVA::PDEFoam *fm = NULL; - while (fm = (TMVA::PDEFoam*) gDirectory->Get(Form("MultiClassFoam%u", cls))) { + while ((fm = (TMVA::PDEFoam*) gDirectory->Get(Form("MultiClassFoam%u", cls)))) { foam_list.Add(new TPair(fm, new TObjString(Form("Discriminator Foam %u",cls)))); cls++; } - } else if (gDirectory->Get("MonoTargetRegressionFoam")){ + } else if (MonoTargetRegressionFoam) { foam_list.Add(new TPair(MonoTargetRegressionFoam, new TObjString("MonoTargetRegression Foam"))); - } else if (gDirectory->Get("MultiTargetRegressionFoam")){ + } else if (MultiTargetRegressionFoam) { foam_list.Add(new TPair(MultiTargetRegressionFoam, new TObjString("MultiTargetRegression Foam"))); } else { - cout << "ERROR: no Foams found in file: " << fin << endl; + cout << "ERROR: no Foams found in file: " << fileName << endl; return; } // loop over all foams and print out a debug message TListIter foamIter(&foam_list); TPair *fm_pair = NULL; - Int_t kDim; // foam dimensions - while (fm_pair = (TPair*) foamIter()) { + Int_t kDim = 0; // foam dimensions + while ((fm_pair = (TPair*) foamIter())) { kDim = ((TMVA::PDEFoam*) fm_pair->Key())->GetTotDim(); cout << "Foam loaded: " << ((TObjString*) fm_pair->Value())->String() << " (dimension = " << kDim << ")" << endl; @@ -121,13 +135,13 @@ void Plot1DimFoams(TList& foam_list, TMVA::ECellValue cell_value, // loop over all foams and draw the histogram TListIter it(&foam_list); TPair* fm_pair = NULL; // the (foam, caption) pair - while (fm_pair = (TPair*) it()) { + while ((fm_pair = (TPair*) it())) { TMVA::PDEFoam* foam = (TMVA::PDEFoam*) fm_pair->Key(); if (!foam) continue; TString foam_caption(((TObjString*) fm_pair->Value())->String()); TString variable_name(foam->GetVariableName(0)->String()); - canvas = new TCanvas(Form("canvas_%u",foam), + canvas = new TCanvas(Form("canvas_%p",foam), "1-dimensional PDEFoam", 400, 400); projection = foam->Draw1Dim(cell_value, 100, kernel); @@ -152,7 +166,7 @@ void PlotNDimFoams(TList& foam_list, TMVA::ECellValue cell_value, // loop over all foams and draw the projection TListIter it(&foam_list); TPair* fm_pair = NULL; // the (foam, caption) pair - while (fm_pair = (TPair*) it()) { + while ((fm_pair = (TPair*) it())) { TMVA::PDEFoam* foam = (TMVA::PDEFoam*) fm_pair->Key(); if (!foam) continue; TString foam_caption(((TObjString*) fm_pair->Value())->String()); @@ -162,7 +176,7 @@ void PlotNDimFoams(TList& foam_list, TMVA::ECellValue cell_value, for (Int_t i = 0; i < kDim; ++i) { for (Int_t k = i + 1; k < kDim; ++k) { - canvas = new TCanvas(Form("canvas_%u_%i:%i", foam, i, k), + canvas = new TCanvas(Form("canvas_%p_%i:%i", foam, i, k), Form("Foam projections %i:%i", i, k), (Int_t)(400/(1.-0.2)), 400); canvas->SetRightMargin(0.2); @@ -187,13 +201,12 @@ void PlotNDimFoams(TList& foam_list, TMVA::ECellValue cell_value, } -void PlotCellTree( TString fin = "weights/TMVAClassification_PDEFoam.weights_foams.root", - TString cv_long, bool useTMVAStyle=kTRUE ) +void PlotCellTree(TString fileName, TString cv_long, bool useTMVAStyle = kTRUE) { // Draw the PDEFoam cell tree - cout << "read file: " << fin << endl; - TFile *file = TFile::Open(fin); + cout << "read file: " << fileName << endl; + TFile *file = TFile::Open(fileName); if (useTMVAStyle) TMVAGlob::SetTMVAStyle(); @@ -201,7 +214,7 @@ void PlotCellTree( TString fin = "weights/TMVAClassification_PDEFoam.weights_foa TListIter foamIter(gDirectory->GetListOfKeys()); TKey *foam_key = NULL; // the foam key TCanvas *canv = NULL; // the canvas - while (foam_key = (TKey*) foamIter()) { + while ((foam_key = (TKey*) foamIter())) { TString name(foam_key->GetName()); TString class_name(foam_key->GetClassName()); if (!class_name.Contains("PDEFoam")) @@ -253,10 +266,9 @@ void DrawCell( TMVA::PDEFoamCell *cell, TMVA::PDEFoam *foam, t->AddText( Form("Intg=%.5f", cell->GetIntg()) ); t->AddText( Form("Var=%.5f", cell->GetDriv()) ); TVectorD *vec = (TVectorD*) cell->GetElement(); - if (vec != NULL){ - for (Int_t i = 0; i < vec->GetNrows(); ++i) { - t->AddText( Form("E[%i]=%.5f", i, vec(i)) ); - } + if (vec) { + for (Int_t i = 0; i < vec->GetNrows(); ++i) + t->AddText( Form("E[%i]=%.5f", i, (*vec)[i]) ); } if (cell->GetStat() != 1) { @@ -277,6 +289,4 @@ void DrawCell( TMVA::PDEFoamCell *cell, TMVA::PDEFoam *foam, } t->Draw(); - - return; } diff --git a/tmva/test/TMVAAutoencoder.cxx b/tmva/test/TMVAAutoencoder.cxx new file mode 100644 index 0000000000000..f7a2f385ebc7e --- /dev/null +++ b/tmva/test/TMVAAutoencoder.cxx @@ -0,0 +1,398 @@ +// @(#)root/tmva $Id$ +/********************************************************************************** + * Project : TMVA - a Root-integrated toolkit for multivariate data analysis * + * Package : TMVA * + * Exectuable: TMVARegression * + * * + * This executable provides examples for the training and testing of the * + * TMVA classifiers. * + * * + * As input data is used a toy-MC sample consisting of four Gaussian-distributed * + * and linearly correlated input variables. * + * * + * The methods to be used can be switched on and off by means of booleans. * + * * + * Compile and run the example with the following commands * + * * + * make * + * ./TMVAAutoencoder * + * * + * * + * The output file "TMVAReg.root" can be analysed with the use of dedicated * + * macros (simply say: root -l <../macros/macro.C>), which can be conveniently * + * invoked through a GUI launched by the command * + * * + * root -l ../macros/TMVAGui.C * + **********************************************************************************/ + +#include <cstdlib> +#include <iostream> +#include <map> +#include <string> +#include <algorithm> + +#include "TChain.h" +#include "TFile.h" +#include "TTree.h" +#include "TString.h" +#include "TObjString.h" +#include "TSystem.h" +#include "TROOT.h" +#include "TStopwatch.h" + +#include "TMVA/Factory.h" +#include "TMVA/Tools.h" +#include "TMVA/Reader.h" +#include "TMVA/MethodMLP.h" + + + +int factory() +{ + // The explicit loading of the shared libTMVA is done in TMVAlogon.C, defined in .rootrc + // if you use your private .rootrc, or run from a different directory, please copy the + // corresponding lines from .rootrc + + // methods to be processed can be given as an argument; use format: + // + + std::cout << std::endl; + std::cout << "==> Start TMVAAutoencoder" << std::endl; + + // -------------------------------------------------------------------------------------------------- + + // --- Here the preparation phase begins + + // Create a new root output file + TString outfileName( "TMVAReg.root" ); + TFile* outputFile = TFile::Open( outfileName, "RECREATE" ); + + // Create the factory object. Later you can choose the methods + // whose performance you'd like to investigate. The factory will + // then run the performance analysis for you. + // + // The first argument is the base of the name of all the + // weightfiles in the directory weight/ + // + // The second argument is the output file for the training results + // All TMVA output can be suppressed by removing the "!" (not) in + // front of the "Silent" argument in the option string + TMVA::Factory *factory = new TMVA::Factory( "TMVAAutoencoder", outputFile, + "!V:!Silent:Color:DrawProgressBar" ); + + // If you wish to modify default settings + // (please check "src/Config.h" to see all available global options) + // (TMVA::gConfig().GetVariablePlotting()).fTimesRMS = 8.0; + // (TMVA::gConfig().GetIONames()).fWeightFileDir = "myWeightDirectory"; + + // Define the input variables that shall be used for the MVA training + // note that you may also use variable expressions, such as: "3*var1/var2*abs(var3)" + // [all types of expressions that can also be parsed by TTree::Draw( "expression" )] + factory->AddVariable( "var1", "Variable 1", "units", 'F' ); + factory->AddVariable( "var2", "Variable 2", "units", 'F' ); + factory->AddVariable( "var3:=var1+var2", "Variable 3", "units", 'F' ); + factory->AddVariable( "var4:=var2*var1", "Variable 4", "units", 'F' ); + + // Add the variable carrying the regression target + factory->AddTarget( "var1" ); + factory->AddTarget( "var2" ); + factory->AddTarget( "var1+var2" ); + factory->AddTarget( "var2*var1" ); + + // Read training and test data (see TMVAClassification for reading ASCII files) + // load the signal and background event samples from ROOT trees + TFile *input(0); + TString fname = "./tmva_reg_example.root"; + if (!gSystem->AccessPathName( fname )) + input = TFile::Open( fname ); // check if file in local directory exists + else + input = TFile::Open( "http://root.cern.ch/files/tmva_reg_example.root" ); // if not: download from ROOT server + + if (!input) { + std::cout << "ERROR: could not open data file" << std::endl; + exit(1); + } + std::cout << "--- TMVARegression : Using input file: " << input->GetName() << std::endl; + + // --- Register the regression tree + + TTree *regTree = (TTree*)input->Get("TreeR"); + + // global event weights per tree (see below for setting event-wise weights) + Double_t regWeight = 1.0; + + // You can add an arbitrary number of regression trees + factory->AddRegressionTree( regTree, regWeight ); + + // This would set individual event weights (the variables defined in the + // expression need to exist in the original TTree) +// factory->SetWeightExpression( "var1", "Regression" ); + + // Apply additional cuts on the signal and background samples (can be different) + TCut mycut = ""; // for example: TCut mycut = "abs(var1)<0.5 && abs(var2-0.5)<1"; + + // tell the factory to use all remaining events in the trees after training for testing: + factory->PrepareTrainingAndTestTree( mycut, + "nTrain_Regression=0:nTest_Regression=0:SplitMode=Random:NormMode=NumEvents:!V" ); + + // If no numbers of events are given, half of the events in the tree are used + // for training, and the other half for testing: + // factory->PrepareTrainingAndTestTree( mycut, "SplitMode=random:!V" ); + + // ---- Book MVA methods + // Neural network (MLP) + factory->BookMethod( TMVA::Types::kMLP, "MLP_4", "!H:!V:VarTransform=Norm:NeuronType=tanh:NCycles=20000:HiddenLayers=N+2,4,N+2:TestRate=6:TrainingMethod=BFGS:Sampling=0.4:SamplingEpoch=0.8:ConvergenceImprove=1e-6:ConvergenceTests=3:!UseRegulator:LearningRate=0.001" ); + + factory->BookMethod( TMVA::Types::kMLP, "MLP_3", "!H:!V:VarTransform=Norm:NeuronType=tanh:NCycles=20000:HiddenLayers=N+2,3,N+2:TestRate=6:TrainingMethod=BFGS:Sampling=0.4:SamplingEpoch=0.8:ConvergenceImprove=1e-6:ConvergenceTests=3:!UseRegulator:LearningRate=0.001" ); + + factory->BookMethod( TMVA::Types::kMLP, "MLP_2", "!H:!V:VarTransform=Norm:NeuronType=tanh:NCycles=20000:HiddenLayers=N+2,2,N+2:TestRate=6:TrainingMethod=BFGS:Sampling=0.4:SamplingEpoch=0.8:ConvergenceImprove=1e-6:ConvergenceTests=10:!UseRegulator:LearningRate=0.001" ); + + factory->BookMethod( TMVA::Types::kMLP, "MLP_1", "!H:!V:VarTransform=Norm:NeuronType=tanh:NCycles=20000:HiddenLayers=N+2,1,N+2:TestRate=6:TrainingMethod=BFGS:Sampling=0.4:SamplingEpoch=0.8:ConvergenceImprove=1e-6:ConvergenceTests=10:!UseRegulator:LearningRate=0.001" ); + + + // -------------------------------------------------------------------------------------------------- + + // ---- Now you can tell the factory to train, test, and evaluate the MVAs + + // Train MVAs using the set of training events + factory->TrainAllMethods(); + + // ---- Evaluate all MVAs using the set of test events + factory->TestAllMethods(); + + // ----- Evaluate and compare performance of all configured MVAs + factory->EvaluateAllMethods(); + + // -------------------------------------------------------------- + + // Save the output + outputFile->Close(); + + std::cout << "==> Wrote root file: " << outputFile->GetName() << std::endl; + std::cout << "==> TMVARegression is done!" << std::endl; + + delete factory; + + std::cout << std::endl; + std::cout << "==> Too view the results, launch the GUI: \"root -l TMVARegGui.C\"" << std::endl; + std::cout << std::endl; +} + + + + + + +void reader () +{ + // --------------------------------------------------------------- + + std::cout << std::endl; + std::cout << "==> Start TMVARegressionApplication" << std::endl; + + + // --- Create the Reader object + + TMVA::Reader *reader = new TMVA::Reader( "!Color:!Silent" ); + + // Create a set of variables and declare them to the reader + // - the variable names MUST corresponds in name and type to those given in the weight file(s) used + Float_t var1, var2, var3, var4; + reader->AddVariable( "var1", &var1 ); + reader->AddVariable( "var2", &var2 ); + reader->AddVariable( "var3", &var3 ); + reader->AddVariable( "var4", &var4 ); + + + // --- Book the MVA methods + + TString dir = "weights/"; + TString prefix = "TMVAAutoencoder"; + + TString weightfile = dir + prefix + "_" + "MLP_4" + ".weights.xml"; + TMVA::IMethod* iMlp4 = reader->BookMVA( TString("MLP_4 method"), weightfile ); + weightfile = dir + prefix + "_" + "MLP_3" + ".weights.xml"; + TMVA::IMethod* iMlp3 = reader->BookMVA( TString("MLP_3 method"), weightfile ); + weightfile = dir + prefix + "_" + "MLP_2" + ".weights.xml"; + TMVA::IMethod* iMlp2 = reader->BookMVA( TString("MLP_2 method"), weightfile ); + weightfile = dir + prefix + "_" + "MLP_1" + ".weights.xml"; + TMVA::IMethod* iMlp1 = reader->BookMVA( TString("MLP_1 method"), weightfile ); + + TMVA::MethodMLP* mlp4 = dynamic_cast<TMVA::MethodMLP*>(iMlp4); + TMVA::MethodMLP* mlp3 = dynamic_cast<TMVA::MethodMLP*>(iMlp3); + TMVA::MethodMLP* mlp2 = dynamic_cast<TMVA::MethodMLP*>(iMlp2); + TMVA::MethodMLP* mlp1 = dynamic_cast<TMVA::MethodMLP*>(iMlp1); + + TFile *input(0); + TString fname = "./tmva_reg_example.root"; + if (!gSystem->AccessPathName( fname )) { + input = TFile::Open( fname ); // check if file in local directory exists + } + else { + input = TFile::Open( "http://root.cern.ch/files/tmva_reg_example.root" ); // if not: download from ROOT server + } + + if (!input) { + std::cout << "ERROR: could not open data file" << std::endl; + exit(1); + } + std::cout << "--- TMVARegressionApp : Using input file: " << input->GetName() << std::endl; + + // --- Event loop + + // Prepare the tree + // - here the variable names have to corresponds to your tree + // - you can use the same variables as above which is slightly faster, + // but of course you can use different ones and copy the values inside the event loop + // + TTree* theTree = (TTree*)input->Get("TreeR"); + std::cout << "--- Select signal sample" << std::endl; + theTree->SetBranchAddress( "var1", &var1 ); + theTree->SetBranchAddress( "var2", &var2 ); + + + TFile *target = new TFile( "TMVAAutoApp.root","RECREATE" ); + TTree* outTree = new TTree( "aenc", "Auto encoder"); + + float enc1[1]; + float enc2[2]; + float enc3[3]; + float enc4[4]; + // reduced dimensions + // enc1[0] --> reduced to 1 node + // enc2[0...2] --> reduced to 2 nodes + // enc3[0...3] --> reduced to 3 nodes + // enc4[0...4] --> reduced to 4 nodes + outTree->Branch ("enc1", enc1, "enc1[1]/F" ); + outTree->Branch ("enc2", enc2, "enc2[2]/F" ); + outTree->Branch ("enc3", enc3, "enc3[3]/F" ); + outTree->Branch ("enc4", enc4, "enc4[4]/F" ); + + // reduced dimensions + // var1, var2, var3, var4 --> input variables + outTree->Branch ("var1", &var1, "var1/F" ); + outTree->Branch ("var2", &var2, "var2/F" ); + outTree->Branch ("var3", &var3, "var3/F" ); + outTree->Branch ("var4", &var4, "var4/F" ); + + + float r1[4]; + float r2[4]; + float r3[4]; + float r4[4]; + // r1, r2, r3, r4 --> target variables which should be as close as possible to the input variables + // the deviation of r1,2,3,4 from var1,2,3,4 is a measure for the error made by the autoencoder + // r1[0...4] + // r2[0...4] + // r3[0...4] + // r4[0...4] + outTree->Branch ("r1", r1, "r1[4]/F" ); + outTree->Branch ("r2", r2, "r2[4]/F" ); + outTree->Branch ("r3", r3, "r3[4]/F" ); + outTree->Branch ("r4", r4, "r4[4]/F" ); + + std::cout << "--- Processing: " << theTree->GetEntries() << " events" << std::endl; + TStopwatch sw; + sw.Start(); + for (Long64_t ievt=0; ievt<theTree->GetEntries();ievt++) { + + if (ievt%1000 == 0) { + std::cout << "--- ... Processing event: " << ievt << std::endl; + } + + theTree->GetEntry(ievt); + var3 = var1+var2; + var4 = var2*var1; + + // Retrieve the MVA target values (regression outputs) and fill into histograms + // NOTE: EvaluateRegression(..) returns a vector for multi-target regression + + // retrieve as well the values of the nodes of the second layer which is the smallest + // layer of the network + { + const std::vector<Float_t>& output = (reader->EvaluateRegression( TString("MLP_4 method") )); + std::copy (output.begin(), output.end(), r4); + mlp4->GetLayerActivation (2, enc4); + } + { + const std::vector<Float_t>& output = (reader->EvaluateRegression( TString("MLP_3 method") )); + std::copy (output.begin(), output.end(), r3); + mlp3->GetLayerActivation (2, enc3); + } + { + const std::vector<Float_t>& output = (reader->EvaluateRegression( TString("MLP_2 method") )); + std::copy (output.begin(), output.end(), r2); + mlp2->GetLayerActivation (2, enc2); + } + { + const std::vector<Float_t>& output = (reader->EvaluateRegression( TString("MLP_1 method") )); + std::copy (output.begin(), output.end(), r1); + mlp1->GetLayerActivation (2, enc1); + } + + outTree->Fill (); + } + sw.Stop(); + std::cout << "--- End of event loop: "; sw.Print(); + + // --- Write histograms + TH1F h4("quality4","quality4",100,0,15); + TH1F h3("quality3","quality3",100,0,15); + TH1F h2("quality2","quality2",100,0,15); + TH1F h1("quality1","quality1",100,0,15); + outTree->Draw ("pow(var1-r4[0],2)+pow(var2-r4[1],2)+pow(var3-r4[2],2)+pow(var4-r4[3],2)>>quality4","",""); + outTree->Draw ("pow(var1-r3[0],2)+pow(var2-r3[1],2)+pow(var3-r3[2],2)+pow(var4-r3[3],2)>>quality3","",""); + outTree->Draw ("pow(var1-r2[0],2)+pow(var2-r2[1],2)+pow(var3-r2[2],2)+pow(var4-r2[3],2)>>quality2","",""); + outTree->Draw ("pow(var1-r1[0],2)+pow(var2-r1[1],2)+pow(var3-r1[2],2)+pow(var4-r1[3],2)>>quality1","",""); + h4.SetLineColor(kBlue); + h3.SetLineColor(kRed); + h2.SetLineColor(kGreen); + h1.SetLineColor(kMagenta); + + outTree->Write (); + h4.Write(); + h3.Write(); + h2.Write(); + h1.Write(); + + std::cout << "--- Created root file: \"" << target->GetName() + << "\" containing the MVA output histograms" << std::endl; + + delete reader; + + std::cout << "==> TMVAAutoencoderApplication is done!" << std::endl << std::endl; + + + + // reduced dimensions + // enc1[0] --> reduced to 1 node + // enc2[0...2] --> reduced to 2 nodes + // enc3[0...3] --> reduced to 3 nodes + // enc4[0...4] --> reduced to 4 nodes + + // reduced dimensions + // var1, var2, var3, var4 --> input variables + + // r1, r2, r3, r4 --> target variables which should be as close as possible to the input variables + // the deviation of r1,2,3,4 from var1,2,3,4 is a measure for the error made by the autoencoder + // r1[0...4] + // r2[0...4] + // r3[0...4] + // r4[0...4] + + // if the number of nodes in the smallest layer is sufficient and the training is sufficient + // then the rX[0] to rX[4] should have the same values as var1 ... var4 + +} + + + + + +int main () +{ + factory (); + reader (); +} + + diff --git a/tmva/test/TMVAClassification.C b/tmva/test/TMVAClassification.C index 73de3d51d937f..22132b071edf9 100644 --- a/tmva/test/TMVAClassification.C +++ b/tmva/test/TMVAClassification.C @@ -40,6 +40,7 @@ #include "TSystem.h" #include "TROOT.h" + #if not defined(__CINT__) || defined(__MAKECINT__) // needs to be included when makecint runs (ACLIC) #include "TMVA/Factory.h" @@ -68,11 +69,13 @@ void TMVAClassification( TString myMethodList = "" ) TMVA::Tools::Instance(); // to get access to the GUI and all tmva macros - TString tmva_dir(TString(gRootDir) + "/tmva"); - if(gSystem->Getenv("TMVASYS")) - tmva_dir = TString(gSystem->Getenv("TMVASYS")); - gROOT->SetMacroPath(tmva_dir + "/test/:" + gROOT->GetMacroPath() ); - gROOT->ProcessLine(".L TMVAGui.C"); + TString tmva_dir(TString(gRootDir) + "/tmva"); + if(gSystem->Getenv("TMVASYS")) + tmva_dir = TString(gSystem->Getenv("TMVASYS")); + gROOT->SetMacroPath(tmva_dir + "/test/:" + gROOT->GetMacroPath() ); + gROOT->ProcessLine(".L TMVAGui.C"); + + // Default MVA methods to be trained + tested std::map<std::string,int> Use; @@ -433,24 +436,23 @@ void TMVAClassification( TString myMethodList = "" ) // Boosted Decision Trees if (Use["BDTG"]) // Gradient Boost factory->BookMethod( TMVA::Types::kBDT, "BDTG", - "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.10:UseBaggedGrad:GradBaggingFraction=0.5:nCuts=20:NNodesMax=5" ); + "!H:!V:NTrees=1000:MinNodeSize=2.5%:BoostType=Grad:Shrinkage=0.10:UseBaggedBoost:BaggedSampleFraction=0.5:nCuts=20:MaxDepth=2" ); if (Use["BDT"]) // Adaptive Boost factory->BookMethod( TMVA::Types::kBDT, "BDT", - "!H:!V:NTrees=850:nEventsMin=150:MaxDepth=3:BoostType=AdaBoost:AdaBoostBeta=0.5:SeparationType=GiniIndex:nCuts=20:PruneMethod=NoPruning" ); - + "!H:!V:NTrees=850:MinNodeSize=2.5%:MaxDepth=3:BoostType=AdaBoost:AdaBoostBeta=0.5:UseBaggedBoost:BaggedSampleFraction=0.5:SeparationType=GiniIndex:nCuts=20" ); if (Use["BDTB"]) // Bagging factory->BookMethod( TMVA::Types::kBDT, "BDTB", - "!H:!V:NTrees=400:BoostType=Bagging:SeparationType=GiniIndex:nCuts=20:PruneMethod=NoPruning" ); + "!H:!V:NTrees=400:BoostType=Bagging:SeparationType=GiniIndex:nCuts=20" ); if (Use["BDTD"]) // Decorrelation + Adaptive Boost factory->BookMethod( TMVA::Types::kBDT, "BDTD", - "!H:!V:NTrees=400:nEventsMin=400:MaxDepth=3:BoostType=AdaBoost:SeparationType=GiniIndex:nCuts=20:PruneMethod=NoPruning:VarTransform=Decorrelate" ); + "!H:!V:NTrees=400:MinNodeSize=5%:MaxDepth=3:BoostType=AdaBoost:SeparationType=GiniIndex:nCuts=20:VarTransform=Decorrelate" ); if (Use["BDTF"]) // Allow Using Fisher discriminant in node splitting for (strong) linearly correlated variables factory->BookMethod( TMVA::Types::kBDT, "BDTMitFisher", - "!H:!V:NTrees=50:nEventsMin=150:UseFisherCuts:MaxDepth=3:BoostType=AdaBoost:AdaBoostBeta=0.5:SeparationType=GiniIndex:nCuts=20:PruneMethod=NoPruning" ); + "!H:!V:NTrees=50:MinNodeSize=2.5%:UseFisherCuts:MaxDepth=3:BoostType=AdaBoost:AdaBoostBeta=0.5:SeparationType=GiniIndex:nCuts=20" ); // RuleFit -- TMVA implementation of Friedman's method if (Use["RuleFit"]) @@ -463,8 +465,9 @@ void TMVAClassification( TString myMethodList = "" ) // ---- Now you can optimize the setting (configuration) of the MVAs using the set of training events + // ---- STILL EXPERIMENTAL and only implemented for BDT's ! // factory->OptimizeAllMethods("SigEffAt001","Scan"); - // factory->OptimizeAllMethods("ROCIntegral","GA"); + // factory->OptimizeAllMethods("ROCIntegral","FitGA"); // -------------------------------------------------------------------------------------------------- diff --git a/tmva/test/TMVAClassification.cxx b/tmva/test/TMVAClassification.cxx index 0dd37abacb34e..6572a69825cae 100644 --- a/tmva/test/TMVAClassification.cxx +++ b/tmva/test/TMVAClassification.cxx @@ -378,7 +378,7 @@ int main( int argc, char** argv ) if (Use["FDA_GA"]) // can also use Simulated Annealing (SA) algorithm (see Cuts_SA options]) factory->BookMethod( TMVA::Types::kFDA, "FDA_GA", - "H:!V:Formula=(0)+(1)*x0+(2)*x1+(3)*x2+(4)*x3:ParRanges=(-1,1);(-10,10);(-10,10);(-10,10);(-10,10):FitMethod=GA:PopSize=300:Cycles=3:Steps=20:Trim=True:SaveBestGen=1" ); + "H:!V:Formula=(0)+(1)*x0+(2)*x1+(3)*x2+(4)*x3:ParRanges=(-1,1);(-10,10);(-10,10);(-10,10);(-10,10):FitMethod=GA:PopSize=300:Cycles=3:Steps=3:Trim=True:SaveBestGen=1" ); if (Use["FDA_SA"]) // can also use Simulated Annealing (SA) algorithm (see Cuts_SA options]) factory->BookMethod( TMVA::Types::kFDA, "FDA_SA", @@ -398,13 +398,13 @@ int main( int argc, char** argv ) // TMVA ANN: MLP (recommended ANN) -- all ANNs in TMVA are Multilayer Perceptrons if (Use["MLP"]) - factory->BookMethod( TMVA::Types::kMLP, "MLP", "H:!V:NeuronType=tanh:VarTransform=N:NCycles=600:HiddenLayers=N+5:TestRate=5:!UseRegulator" ); + factory->BookMethod( TMVA::Types::kMLP, "MLP", "H:!V:NeuronType=tanh:VarTransform=N:NCycles=60:HiddenLayers=N+5:TestRate=5:!UseRegulator" ); if (Use["MLPBFGS"]) - factory->BookMethod( TMVA::Types::kMLP, "MLPBFGS", "H:!V:NeuronType=tanh:VarTransform=N:NCycles=600:HiddenLayers=N+5:TestRate=5:TrainingMethod=BFGS:!UseRegulator" ); + factory->BookMethod( TMVA::Types::kMLP, "MLPBFGS", "H:!V:NeuronType=tanh:VarTransform=N:NCycles=60:HiddenLayers=N+5:TestRate=5:TrainingMethod=BFGS:!UseRegulator" ); if (Use["MLPBNN"]) - factory->BookMethod( TMVA::Types::kMLP, "MLPBNN", "H:!V:NeuronType=tanh:VarTransform=N:NCycles=600:HiddenLayers=N+5:TestRate=5:TrainingMethod=BFGS:UseRegulator" ); // BFGS training with bayesian regulators + factory->BookMethod( TMVA::Types::kMLP, "MLPBNN", "H:!V:NeuronType=tanh:VarTransform=N:NCycles=60:HiddenLayers=N+5:TestRate=5:TrainingMethod=BFGS:UseRegulator" ); // BFGS training with bayesian regulators // CF(Clermont-Ferrand)ANN if (Use["CFMlpANN"]) @@ -421,23 +421,23 @@ int main( int argc, char** argv ) // Boosted Decision Trees if (Use["BDTG"]) // Gradient Boost factory->BookMethod( TMVA::Types::kBDT, "BDTG", - "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.10:UseBaggedGrad:GradBaggingFraction=0.5:nCuts=20:NNodesMax=5" ); + "!H:!V:NTrees=1000:MinNodeSize=1.5%:BoostType=Grad:Shrinkage=0.10:UseBaggedBoost:BaggedSampleFraction=0.5:nCuts=20:MaxDepth=2" ); if (Use["BDT"]) // Adaptive Boost factory->BookMethod( TMVA::Types::kBDT, "BDT", - "!H:!V:NTrees=850:nEventsMin=150:MaxDepth=3:BoostType=AdaBoost:AdaBoostBeta=0.5:SeparationType=GiniIndex:nCuts=20:PruneMethod=NoPruning" ); + "!H:!V:NTrees=1000:MinNodeSize=2.5%:MaxDepth=3:BoostType=AdaBoost:AdaBoostBeta=0.5:UseBaggedBoost:BaggedSampleFraction=0.5:SeparationType=GiniIndex:nCuts=20" ); if (Use["BDTB"]) // Bagging factory->BookMethod( TMVA::Types::kBDT, "BDTB", - "!H:!V:NTrees=400:BoostType=Bagging:SeparationType=GiniIndex:nCuts=20:PruneMethod=NoPruning" ); + "!H:!V:NTrees=400:BoostType=Bagging:SeparationType=GiniIndex:nCuts=20" ); if (Use["BDTD"]) // Decorrelation + Adaptive Boost factory->BookMethod( TMVA::Types::kBDT, "BDTD", - "!H:!V:NTrees=400:nEventsMin=400:MaxDepth=3:BoostType=AdaBoost:SeparationType=GiniIndex:nCuts=20:PruneMethod=NoPruning:VarTransform=Decorrelate" ); + "!H:!V:NTrees=400:MinNodeSize=5%:MaxDepth=3:BoostType=AdaBoost:SeparationType=GiniIndex:nCuts=20:VarTransform=Decorrelate" ); if (Use["BDTF"]) // Allow Using Fisher discriminant in node splitting for (strong) linearly correlated variables factory->BookMethod( TMVA::Types::kBDT, "BDTMitFisher", - "!H:!V:NTrees=50:nEventsMin=150:UseFisherCuts:MaxDepth=3:BoostType=AdaBoost:AdaBoostBeta=0.5:SeparationType=GiniIndex:nCuts=20:PruneMethod=NoPruning" ); + "!H:!V:NTrees=50:MinNodeSize=2.5%:UseFisherCuts:MaxDepth=3:BoostType=AdaBoost:AdaBoostBeta=0.5:SeparationType=GiniIndex:nCuts=20" ); // RuleFit -- TMVA implementation of Friedman's method if (Use["RuleFit"]) @@ -452,8 +452,9 @@ int main( int argc, char** argv ) // ---- Now you can optimize the setting (configuration) of the MVAs using the set of training events + // ---- STILL EXPERIMENTAL and only implemented for BDT's ! // factory->OptimizeAllMethods("SigEffAt001","Scan"); - // factory->OptimizeAllMethods("ROCIntegral","GA"); + // factory->OptimizeAllMethods("ROCIntegral","FitGA"); // -------------------------------------------------------------------------------------------------- diff --git a/tmva/test/TMVAClassification.py b/tmva/test/TMVAClassification.py index c6b0c3614dbc5..f8704b8336c9d 100755 --- a/tmva/test/TMVAClassification.py +++ b/tmva/test/TMVAClassification.py @@ -371,19 +371,19 @@ def main(): # Boosted Decision Trees if "BDTG" in mlist: factory.BookMethod( TMVA.Types.kBDT, "BDTG", - "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.30:UseBaggedGrad:GradBaggingFraction=0.6:SeparationType=GiniIndex:nCuts=20:NNodesMax=5" ) + "!H:!V:NTrees=1000:MinNodeSize=1.5%:BoostType=Grad:Shrinkage=0.10:UseBaggedBoost:BaggedSampleFraction=0.5:nCuts=20:MaxDepth=2" ) if "BDT" in mlist: factory.BookMethod( TMVA.Types.kBDT, "BDT", - "!H:!V:NTrees=850:nEventsMin=150:MaxDepth=3:BoostType=AdaBoost:AdaBoostBeta=0.5:SeparationType=GiniIndex:nCuts=20:PruneMethod=NoPruning" ) + "!H:!V:NTrees=850:MinNodeSize=2.5%:MaxDepth=3:BoostType=AdaBoost:AdaBoostBeta=0.5:UseBaggedBoost:BaggedSampleFraction=0.5:SeparationType=GiniIndex:nCuts=20" ) if "BDTB" in mlist: factory.BookMethod( TMVA.Types.kBDT, "BDTB", - "!H:!V:NTrees=400:BoostType=Bagging:SeparationType=GiniIndex:nCuts=20:PruneMethod=NoPruning" ) + "!H:!V:NTrees=400:BoostType=Bagging:SeparationType=GiniIndex:nCuts=20" ) if "BDTD" in mlist: factory.BookMethod( TMVA.Types.kBDT, "BDTD", - "!H:!V:NTrees=400:nEventsMin=400:MaxDepth=3:BoostType=AdaBoost:SeparationType=GiniIndex:nCuts=20:PruneMethod=NoPruning:VarTransform=Decorrelate" ) + "!H:!V:NTrees=400:MinNodeSize=5%:MaxDepth=3:BoostType=AdaBoost:SeparationType=GiniIndex:nCuts=20:VarTransform=Decorrelate" ) # RuleFit -- TMVA implementation of Friedman's method if "RuleFit" in mlist: diff --git a/tmva/test/TMVAClassificationApplication.C b/tmva/test/TMVAClassificationApplication.C index c1afa6dbd38e4..012aef220f07e 100644 --- a/tmva/test/TMVAClassificationApplication.C +++ b/tmva/test/TMVAClassificationApplication.C @@ -20,8 +20,6 @@ #include "TROOT.h" #include "TStopwatch.h" -#include "TMVAGui.C" - #if not defined(__CINT__) || defined(__MAKECINT__) #include "TMVA/Tools.h" #include "TMVA/Reader.h" diff --git a/tmva/test/TMVAClassificationCategory.C b/tmva/test/TMVAClassificationCategory.C index 272a405c8857c..5ced6009cd37b 100644 --- a/tmva/test/TMVAClassificationCategory.C +++ b/tmva/test/TMVAClassificationCategory.C @@ -33,10 +33,10 @@ #include "TSystem.h" #include "TROOT.h" -#include "TMVAGui.C" #if not defined(__CINT__) || defined(__MAKECINT__) // needs to be included when makecint runs (ACLIC) +#include "TMVA/MethodCategory.h" #include "TMVA/Factory.h" #include "TMVA/Tools.h" #endif @@ -51,6 +51,17 @@ void TMVAClassificationCategory() std::cout << std::endl << "==> Start TMVAClassificationCategory" << std::endl; + // This loads the library + TMVA::Tools::Instance(); + + // to get access to the GUI and all tmva macros + TString tmva_dir(TString(gRootDir) + "/tmva"); + if(gSystem->Getenv("TMVASYS")) + tmva_dir = TString(gSystem->Getenv("TMVASYS")); + gROOT->SetMacroPath(tmva_dir + "/test/:" + gROOT->GetMacroPath() ); + gROOT->ProcessLine(".L TMVAGui.C"); + + bool batchMode = false; // Create a new root output file. diff --git a/tmva/test/TMVAGui.C b/tmva/test/TMVAGui.C index 07c0299d307d2..508c6e99d5742 100644 --- a/tmva/test/TMVAGui.C +++ b/tmva/test/TMVAGui.C @@ -179,6 +179,13 @@ void TMVAGui( const char* fName = "TMVA.root" ) "Plots background rejection vs signal efficiencies (macro efficiencies.C) [\"ROC\" stands for \"Receiver Operation Characteristics\"]", buttonType, defaultRequiredClassifier ); + title = Form( "(%ib) Classifier 1/(Backgr. Efficiency) vs Signal Efficiency (ROC curve)", ic ); + ActionButton( cbar, + title, + Form( ".x efficiencies.C(\"%s\",%d)", fName, 3 ), + "Plots 1/(background eff.) vs signal efficiencies (macro efficiencies.C) [\"ROC\" stands for \"Receiver Operation Characteristics\"]", + buttonType, defaultRequiredClassifier ); + title = Form( "(%i) Parallel Coordinates (requires ROOT-version >= 5.17)", ++ic ); ActionButton( cbar, title, @@ -230,7 +237,7 @@ void TMVAGui( const char* fName = "TMVA.root" ) title = Form( "(%i) Decision Tree Control Plots (BDT)", ++ic ); ActionButton( cbar, title, - Form( ".x BDTControlPlots.C(\"%s\")", fName ), + Form( ".x BDTControlPlots.C+(\"%s\")", fName ), "Plots to monitor boosting and pruning of decision trees (macro BDTControlPlots.C)", buttonType, "BDT" ); // ActionButton( cbar, diff --git a/tmva/test/TMVAMultiClassGui.C b/tmva/test/TMVAMultiClassGui.C index 91a2b5742ba8a..c8fefe07aa9b5 100644 --- a/tmva/test/TMVAMultiClassGui.C +++ b/tmva/test/TMVAMultiClassGui.C @@ -67,7 +67,7 @@ void TMVAMultiClassGui( const char* fName = "TMVAMulticlass.root" ) gSystem->SetIncludePath(newIncludePath); std::cout <<"new include path="<<gSystem->GetIncludePath()<<std::endl; - cout << "--- Launch TMVA GUI to view input file: " << fName << endl; + std::cout << "--- Launch TMVA GUI to view input file: " << fName << std::endl; // init TMVAGui_inactiveButtons.clear(); @@ -75,7 +75,7 @@ void TMVAMultiClassGui( const char* fName = "TMVAMulticlass.root" ) // check if file exist TFile* file = TFile::Open( fName ); if (!file) { - cout << "==> Abort TMVAGui, please verify filename" << endl; + std::cout << "==> Abort TMVAGui, please verify filename" << std::endl; return; } // find all references @@ -272,7 +272,7 @@ void TMVAMultiClassGui( const char* fName = "TMVAMulticlass.root" ) // indicate inactive buttons for (UInt_t i=0; i<TMVAGui_inactiveButtons.size(); i++) cbar->SetButtonState( TMVAGui_inactiveButtons[i], 3 ); if (TMVAGui_inactiveButtons.size() > 0) { - cout << "=== Note: inactive buttons indicate that the corresponding classifiers were not trained ===" << endl; + std::cout << "=== Note: inactive buttons indicate that the corresponding classifiers were not trained ===" << std::endl; } gROOT->SaveContext(); diff --git a/tmva/test/TMVAMulticlass.C b/tmva/test/TMVAMulticlass.C index 7ef4804deb119..15d4818aef2ae 100644 --- a/tmva/test/TMVAMulticlass.C +++ b/tmva/test/TMVAMulticlass.C @@ -18,7 +18,6 @@ #include "TSystem.h" #include "TROOT.h" -#include "TMVAMultiClassGui.C" #ifndef __CINT__ #include "TMVA/Tools.h" @@ -30,7 +29,16 @@ using namespace TMVA; void TMVAMulticlass( TString myMethodList = "" ) { + // This loads the library TMVA::Tools::Instance(); + + // to get access to the GUI and all tmva macros + TString tmva_dir(TString(gRootDir) + "/tmva"); + if(gSystem->Getenv("TMVASYS")) + tmva_dir = TString(gSystem->Getenv("TMVASYS")); + gROOT->SetMacroPath(tmva_dir + "/test/:" + gROOT->GetMacroPath() ); + gROOT->ProcessLine(".L TMVAMultiClassGui.C"); + //--------------------------------------------------------------- // default MVA methods to be trained + tested @@ -105,7 +113,7 @@ void TMVAMulticlass( TString myMethodList = "" ) factory->PrepareTrainingAndTestTree( "", "SplitMode=Random:NormMode=NumEvents:!V" ); if (Use["BDTG"]) // gradient boosted decision trees - factory->BookMethod( TMVA::Types::kBDT, "BDTG", "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.10:UseBaggedGrad:GradBaggingFraction=0.50:nCuts=20:NNodesMax=8"); + factory->BookMethod( TMVA::Types::kBDT, "BDTG", "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.10:UseBaggedBoost:BaggedSampleFraction=0.50:nCuts=20:MaxDepth=2"); if (Use["MLP"]) // neural network factory->BookMethod( TMVA::Types::kMLP, "MLP", "!H:!V:NeuronType=tanh:NCycles=1000:HiddenLayers=N+5,5:TestRate=5:EstimatorType=MSE"); if (Use["FDA_GA"]) // functional discriminant with GA minimizer diff --git a/tmva/test/TMVAMulticlass.cxx b/tmva/test/TMVAMulticlass.cxx index 1077d9726e2ee..5c0aefd028ee1 100644 --- a/tmva/test/TMVAMulticlass.cxx +++ b/tmva/test/TMVAMulticlass.cxx @@ -18,8 +18,6 @@ #include "TSystem.h" #include "TROOT.h" -#include "TMVAMultiClassGui.C" - #ifndef __CINT__ #include "TMVA/Tools.h" #include "TMVA/Factory.h" @@ -30,7 +28,16 @@ using namespace TMVA; int main(int argc, char** argv ) { + // This loads the library TMVA::Tools::Instance(); + + // to get access to the GUI and all tmva macros + TString tmva_dir(TString(gRootDir) + "/tmva"); + if(gSystem->Getenv("TMVASYS")) + tmva_dir = TString(gSystem->Getenv("TMVASYS")); + gROOT->SetMacroPath(tmva_dir + "/test/:" + gROOT->GetMacroPath() ); + gROOT->ProcessLine(".L TMVAGui.C"); + //--------------------------------------------------------------- // default MVA methods to be trained + tested @@ -80,10 +87,10 @@ int main(int argc, char** argv ) input = TFile::Open( fname ); } else { - cout << "Creating testdata...." << std::endl; + std::cout << "Creating testdata...." << std::endl; gROOT->ProcessLine(".L createData.C+"); gROOT->ProcessLine("create_MultipleBackground(2000)"); - cout << " created tmva_example_multiple_background.root for tests of the multiclass features"<<endl; + std::cout << " created tmva_example_multiple_background.root for tests of the multiclass features"<<std::endl; input = TFile::Open( fname ); } if (!input) { @@ -105,7 +112,7 @@ int main(int argc, char** argv ) factory->PrepareTrainingAndTestTree( "", "SplitMode=Random:NormMode=NumEvents:!V" ); if (Use["BDTG"]) // gradient boosted decision trees - factory->BookMethod( TMVA::Types::kBDT, "BDTG", "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.10:UseBaggedGrad:GradBaggingFraction=0.50:nCuts=20:NNodesMax=8"); + factory->BookMethod( TMVA::Types::kBDT, "BDTG", "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.10:UseBaggedBoost:BaggedSampleFraction=0.50:nCuts=20:MaxDepth=2"); if (Use["MLP"]) // neural network factory->BookMethod( TMVA::Types::kMLP, "MLP", "!H:!V:NeuronType=tanh:NCycles=300:HiddenLayers=N+5,5:TestRate=5:EstimatorType=MSE"); if (Use["FDA_GA"]) // functional discriminant with GA minimizer diff --git a/tmva/test/TMVAMultipleBackgroundExample.cxx b/tmva/test/TMVAMultipleBackgroundExample.cxx index 9618a6405ed67..7a0cded12cd90 100644 --- a/tmva/test/TMVAMultipleBackgroundExample.cxx +++ b/tmva/test/TMVAMultipleBackgroundExample.cxx @@ -85,7 +85,7 @@ void Training(){ // Boosted Decision Trees factory->BookMethod( TMVA::Types::kBDT, "BDTG", - "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.30:UseBaggedGrad:GradBaggingFraction=0.6:SeparationType=GiniIndex:nCuts=20:NNodesMax=5" ); + "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.30:UseBaggedBoost:BaggedSampleFraction=0.6:SeparationType=GiniIndex:nCuts=20:MaxDepth=2" ); factory->TrainAllMethods(); factory->TestAllMethods(); factory->EvaluateAllMethods(); @@ -118,7 +118,7 @@ void Training(){ // Boosted Decision Trees factory->BookMethod( TMVA::Types::kBDT, "BDTG", - "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.30:UseBaggedGrad:GradBaggingFraction=0.6:SeparationType=GiniIndex:nCuts=20:NNodesMax=5" ); + "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.30:UseBaggedBoost:BaggedSampleFraction=0.6:SeparationType=GiniIndex:nCuts=20:MaxDepth=2" ); factory->TrainAllMethods(); factory->TestAllMethods(); factory->EvaluateAllMethods(); @@ -151,7 +151,7 @@ void Training(){ // Boosted Decision Trees factory->BookMethod( TMVA::Types::kBDT, "BDTG", - "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.30:UseBaggedGrad:GradBaggingFraction=0.5:SeparationType=GiniIndex:nCuts=20:NNodesMax=5" ); + "!H:!V:NTrees=1000:BoostType=Grad:Shrinkage=0.30:UseBaggedBoost:BaggedSampleFraction=0.5:SeparationType=GiniIndex:nCuts=20:MaxDepth=2" ); factory->TrainAllMethods(); factory->TestAllMethods(); factory->EvaluateAllMethods(); diff --git a/tmva/test/TMVARegression.C b/tmva/test/TMVARegression.C index aaa05544c9e15..f248a520cef74 100644 --- a/tmva/test/TMVARegression.C +++ b/tmva/test/TMVARegression.C @@ -36,7 +36,6 @@ #include "TSystem.h" #include "TROOT.h" -#include "TMVARegGui.C" #if not defined(__CINT__) || defined(__MAKECINT__) #include "TMVA/Tools.h" @@ -60,6 +59,14 @@ void TMVARegression( TString myMethodList = "" ) // This loads the library TMVA::Tools::Instance(); + // to get access to the GUI and all tmva macros + TString tmva_dir(TString(gRootDir) + "/tmva"); + if(gSystem->Getenv("TMVASYS")) + tmva_dir = TString(gSystem->Getenv("TMVASYS")); + gROOT->SetMacroPath(tmva_dir + "/test/:" + gROOT->GetMacroPath() ); + gROOT->ProcessLine(".L TMVARegGui.C"); + + // Default MVA methods to be trained + tested std::map<std::string,int> Use; @@ -251,11 +258,11 @@ void TMVARegression( TString myMethodList = "" ) // Boosted Decision Trees if (Use["BDT"]) factory->BookMethod( TMVA::Types::kBDT, "BDT", - "!H:!V:NTrees=100:nEventsMin=5:BoostType=AdaBoostR2:SeparationType=RegressionVariance:nCuts=20:PruneMethod=CostComplexity:PruneStrength=30" ); + "!H:!V:NTrees=100:MinNodeSize=1.0%:BoostType=AdaBoostR2:SeparationType=RegressionVariance:nCuts=20:PruneMethod=CostComplexity:PruneStrength=30" ); if (Use["BDTG"]) factory->BookMethod( TMVA::Types::kBDT, "BDTG", - "!H:!V:NTrees=2000::BoostType=Grad:Shrinkage=0.1:UseBaggedGrad:GradBaggingFraction=0.5:nCuts=20:MaxDepth=3:NNodesMax=15" ); + "!H:!V:NTrees=2000::BoostType=Grad:Shrinkage=0.1:UseBaggedBoost:BaggedSampleFraction=0.5:nCuts=20:MaxDepth=3:MaxDepth=4" ); // -------------------------------------------------------------------------------------------------- // ---- Now you can tell the factory to train, test, and evaluate the MVAs diff --git a/tmva/test/TMVARegression.cxx b/tmva/test/TMVARegression.cxx index d2fa905a6c8cc..9aa4891309db2 100644 --- a/tmva/test/TMVARegression.cxx +++ b/tmva/test/TMVARegression.cxx @@ -246,11 +246,11 @@ int main( int argc, char** argv ) // Boosted Decision Trees if (Use["BDT"]) factory->BookMethod( TMVA::Types::kBDT, "BDT", - "!H:!V:NTrees=100:nEventsMin=5:BoostType=AdaBoostR2:SeparationType=RegressionVariance:nCuts=20:PruneMethod=CostComplexity:PruneStrength=30" ); + "!H:!V:NTrees=100:MinNodeSize=1.0%:BoostType=AdaBoostR2:SeparationType=RegressionVariance:nCuts=20:PruneMethod=CostComplexity:PruneStrength=30" ); if (Use["BDTG"]) factory->BookMethod( TMVA::Types::kBDT, "BDTG", - "!H:!V:NTrees=2000::BoostType=Grad:Shrinkage=0.1:UseBaggedGrad:GradBaggingFraction=0.5nCuts=20:MaxDepth=3:NNodesMax=15" ); + "!H:!V:NTrees=2000::BoostType=Grad:Shrinkage=0.1:UseBaggedBoost:BaggedSampleFraction=0.5nCuts=20:MaxDepth=3:MaxDepth=4" ); // -------------------------------------------------------------------------------------------------- // ---- Now you can tell the factory to train, test, and evaluate the MVAs diff --git a/tmva/test/TMVAlogon.C b/tmva/test/TMVAlogon.C index 9018ead84b0fa..5335d67b11884 100644 --- a/tmva/test/TMVAlogon.C +++ b/tmva/test/TMVAlogon.C @@ -4,10 +4,10 @@ // ----------------------------------------------- TString curDynamicPath( gSystem->GetDynamicPath() ); - gSystem->SetDynamicPath( "../lib:" + curDynamicPath ); + gSystem->SetDynamicPath( "$TMVASYS/lib:" + curDynamicPath ); TString curIncludePath(gSystem->GetIncludePath()); - gSystem->SetIncludePath( " -I../inc " + curIncludePath ); + gSystem->SetIncludePath( " -I$TMVASYS/inc " + curIncludePath ); // load TMVA shared library created in local release // (not required anymore with the use of rootmaps, but problems with MAC OSX) diff --git a/tmva/test/createData.C b/tmva/test/createData.C index 0dfb355a3a3e8..ea232e91e4f10 100644 --- a/tmva/test/createData.C +++ b/tmva/test/createData.C @@ -1315,6 +1315,8 @@ void create_lin(Int_t N = 2000) plot(); } +// create the data + void create_fullcirc(Int_t nmax = 20000, Bool_t distort=false) { TFile* dataFile = TFile::Open( "circledata.root", "RECREATE" ); diff --git a/tmva/test/efficiencies.C b/tmva/test/efficiencies.C index 95128c5440266..311197e983d9f 100644 --- a/tmva/test/efficiencies.C +++ b/tmva/test/efficiencies.C @@ -5,6 +5,7 @@ void plot_efficiencies( TFile* file, Int_t type = 2, TDirectory* BinDir) // input: - Input file (result from TMVA), // - type = 1 --> plot efficiency(B) versus eff(S) // = 2 --> plot rejection (B) versus efficiency (S) + // = 3 --> plot 1/eff(B) versus efficiency (S) Bool_t __PLOT_LOGO__ = kTRUE; Bool_t __SAVE_IMAGE__ = kTRUE; @@ -21,8 +22,11 @@ void plot_efficiencies( TFile* file, Int_t type = 2, TDirectory* BinDir) y1 = 1 - y2; y2 = 1 - z; // cout << "--- type==2: plot background rejection versus signal efficiency" << endl; - } - else { + } else if (type == 3) { + y1 = 0; + y2 = -1; // will be set to the max found in the histograms + + } else { // cout << "--- type==1: plot background efficiency versus signal efficiency" << endl; } // create canvas @@ -47,13 +51,48 @@ void plot_efficiencies( TFile* file, Int_t type = 2, TDirectory* BinDir) TString xtit = "Signal efficiency"; TString ytit = "Background efficiency"; if (type == 2) ytit = "Background rejection"; + if (type == 3) ytit = "1/(Background eff.)"; TString ftit = ytit + " versus " + xtit; + TString hNameRef = "effBvsS"; + if (type == 2) hNameRef = "rejBvsS"; + if (type == 3) hNameRef = "invBeffvsSeff"; + + if (TString(BinDir->GetName()).Contains("multicut")){ ftit += " Bin: "; ftit += (BinDir->GetTitle()); } + TList xhists; + TList xmethods; + UInt_t xnm = TMVAGlob::GetListOfMethods( xmethods ); + TIter xnext(&xmethods); + // loop over all methods + TKey *xkey; + while (xkey = (TKey*)xnext()) { + TDirectory * mDir = (TDirectory*)xkey->ReadObj(); + TList titles; + UInt_t ninst = TMVAGlob::GetListOfTitles(mDir,titles); + TIter nextTitle(&titles); + TKey *titkey; + TDirectory *titDir; + while ((titkey = TMVAGlob::NextKey(nextTitle,"TDirectory"))) { + titDir = (TDirectory *)titkey->ReadObj(); + TString methodTitle; + TMVAGlob::GetMethodTitle(methodTitle,titDir); + TIter nextKey( titDir->GetListOfKeys() ); + while ((hkey = TMVAGlob::NextKey(nextKey,"TH1"))) { + TH1 *h = (TH1*)hkey->ReadObj(); + TString hname = h->GetName(); + if (hname.Contains( hNameRef ) && hname.BeginsWith( "MVA_" )) { + if (type==3 && h->GetMaximum() > y2) y2 = h->GetMaximum(); + } + } + } + } + + // draw empty frame if(gROOT->FindObject("frame")!=0) gROOT->FindObject("frame")->Delete(); TH2F* frame = new TH2F( "frame", ftit, 500, x1, x2, 500, y1, y2 ); @@ -67,9 +106,6 @@ void plot_efficiencies( TFile* file, Int_t type = 2, TDirectory* BinDir) Int_t nmva = 0; TKey *key, *hkey; - TString hNameRef = "effBvsS"; - if (type == 2) hNameRef = "rejBvsS"; - TList hists; TList methods; UInt_t nm = TMVAGlob::GetListOfMethods( methods ); diff --git a/tmva/test/mvas.C b/tmva/test/mvas.C index 48f5eaf9adf8c..11023a56229f6 100644 --- a/tmva/test/mvas.C +++ b/tmva/test/mvas.C @@ -205,8 +205,8 @@ void mvas( TString fin = "TMVA.root", HistType htype = MVAType, Bool_t useTMVASt // perform K-S test cout << "--- Perform Kolmogorov-Smirnov tests" << endl; - Double_t kolS = sig->KolmogorovTest( sigOv ); - Double_t kolB = bgd->KolmogorovTest( bgdOv ); + Double_t kolS = sig->KolmogorovTest( sigOv, "X" ); + Double_t kolB = bgd->KolmogorovTest( bgdOv, "X" ); cout << "--- Goodness of signal (background) consistency: " << kolS << " (" << kolB << ")" << endl; TString probatext = Form( "Kolmogorov-Smirnov test: signal (background) probability = %5.3g (%5.3g)", kolS, kolB ); diff --git a/tmva/test/mvasMulticlass.C b/tmva/test/mvasMulticlass.C index d1f4765b33a4f..3828884a1f602 100644 --- a/tmva/test/mvasMulticlass.C +++ b/tmva/test/mvasMulticlass.C @@ -211,7 +211,7 @@ void mvasMulticlass( TString fin = "TMVAMulticlass.root", HistType htype = MVATy cout << "--- Goodness of consistency for class " << classnames.at(icls)<< endl; //TString probatext("Kolmogorov-Smirnov test: "); for(Int_t j=0; j<othists.GetEntriesFast(); ++j){ - Float_t kol = ((TH1*)hists[j])->KolmogorovTest(((TH1*)othists[j])); + Float_t kol = ((TH1*)hists[j])->KolmogorovTest(((TH1*)othists[j]),"X"); cout << classnames.at(j) << ": " << kol << endl; //probatext.Append(classnames.at(j)+Form(" %.3f ",kol)); } diff --git a/tmva/test/setup.csh b/tmva/test/setup.csh index 0d1071ea8934f..4873500fc9dee 100644 --- a/tmva/test/setup.csh +++ b/tmva/test/setup.csh @@ -1,26 +1,74 @@ -#! /bin/csh +#!/bin/csh -f -cd .. -mkdir -p include; -cd include; -if ( ! -l TMVA ) then - ln -s ../src TMVA +setenv HERE $PWD + + +if ( $#argv != 1 ) then + cd .. ; setenv TMVASYS $PWD; cd $HERE + set TMVATESTDIR=1 + echo $TMVASYS + echo $PWD + if (( "$TMVASYS/test" != "$PWD" )) then + echo + echo " please give the directory of your TMVA installation you want to use as argument to " + echo " source setup.csh <the TMVA installation directory>" + echo + exit + endif +else + setenv TMVASYS $argv[1] + set TMVATESTDIR=0 + echo + echo " you have specified to use TMVA installed in:" $argv[1] +endif + +# check if the TMVA directory specified REALLY contains the TMVA libraries, otherwise it +# might default to the ROOT version causing unnecessary surprises + +if (( ! -f $TMVASYS/lib/libTMVA.so )) then + echo + echo " please give a PROPER directory of your TMVA installation as argument to " + echo " source setup.csh <the TMVA installation directory> " + echo + echo " currently I look at $TMVASYS/lib/libTMVA.so which doesn't exist " + echo + exit endif -cd - + + +echo "use TMVA version installed in " $TMVASYS + # set symbolic links to data file and to rootmaps -cd test -if ( ! -l tmva_example.root ) then +#cd test; +if (( (! -l tmva_example.root) && ($TMVATESTDIR == 1 ) )) then ln -s data/toy_sigbkg.root tmva_example.root -endif -if ( ! -l tmva_reg_example.root ) then + endif +if (( (! -l tmva_reg_example.root) && ($TMVATESTDIR == 1) )) then ln -s data/regression_parabola_noweights.root tmva_reg_example.root + endif +if (( ! -l libTMVA.rootmap )) then + ln -s $TMVASYS/lib/libTMVA.rootmap +endif +if (( ! -l .rootmap )) then + ln -s $TMVASYS/lib/libTMVA.rootmap .rootmap +endif +if (( ! -f TMVAlogon.C )) then + cp $TMVASYS/test/TMVAlogon.C . endif -if ( ! -l libTMVA.rootmap ) then - ln -s ../lib/libTMVA.rootmap - ln -s ../lib/libTMVA.rootmap .rootmap +if (( ! -f TMVAGui.C )) then + cp $TMVASYS/test/TMVAGui.C . endif -cd - +if (( ! -f TMVARegGui.C )) then + cp $TMVASYS/test/TMVARegGui.C . +endif +if (( ! -f tmvaglob.C )) then + cp $TMVASYS/test/tmvaglob.C . +endif +if (( ! -f .rootrc )) then + cp $TMVASYS/test/.rootrc . +endif + # Check Root environment setup # It's checked in such a fancy way, because if you install ROOT using @@ -37,17 +85,17 @@ endif if ( `root-config --platform` == "macosx" ) then if ($?DYLD_LIBRARY_PATH) then - setenv DYLD_LIBRARY_PATH $PWD/lib:${DYLD_LIBRARY_PATH} + setenv DYLD_LIBRARY_PATH $TMVASYS/lib:${DYLD_LIBRARY_PATH} else - setenv DYLD_LIBRARY_PATH $PWD/lib:`root-config --libdir` + setenv DYLD_LIBRARY_PATH $TMVASYS/lib:`root-config --libdir` endif else if ( `root-config --platform` == "solaris" ) then if ($?LD_LIBRARY_PATH) then - setenv LD_LIBRARY_PATH $PWD/lib:${LD_LIBRARY_PATH} + setenv LD_LIBRARY_PATH $TMVASYS/lib:${LD_LIBRARY_PATH} else - setenv LD_LIBRARY_PATH $PWD/lib:`root-config --libdir` + setenv LD_LIBRARY_PATH $TMVASYS/lib:`root-config --libdir` endif else @@ -55,14 +103,14 @@ else # The ROOTSYS/lib may be set in a LD_LIBRARY_PATH or using ld.so grep -q `echo $ROOTSYS/lib /etc/ld.so.cache` - set root_in_ld = $status + set root_in_ld=$status if ($?LD_LIBRARY_PATH) then - setenv LD_LIBRARY_PATH $PWD/lib:${LD_LIBRARY_PATH} + setenv LD_LIBRARY_PATH $TMVASYS/lib:${LD_LIBRARY_PATH} else if ( ${root_in_ld} == 1 ) then - setenv LD_LIBRARY_PATH $PWD/lib:`root-config --libdir` + setenv LD_LIBRARY_PATH $TMVASYS/lib:`root-config --libdir` else - setenv LD_LIBRARY_PATH $PWD/lib + setenv LD_LIBRARY_PATH $TMVASYS/lib endif endif @@ -71,10 +119,10 @@ endif # prepare for PyROOT if ($?PYTHONPATH) then - setenv PYTHONPATH ${PWD}/lib:`root-config --libdir`:${PYTHONPATH} + setenv PYTHONPATH ${TMVASYS}/lib:`root-config --libdir`:${PYTHONPATH} else - setenv PYTHONPATH ${PWD}/lib:`root-config --libdir`/lib + setenv PYTHONPATH ${TMVASYS}/lib:`root-config --libdir`/lib endif -cd test +cd $HERE diff --git a/tmva/test/setup.sh b/tmva/test/setup.sh index 8edab3e449b68..0e732217d147a 100755 --- a/tmva/test/setup.sh +++ b/tmva/test/setup.sh @@ -2,13 +2,52 @@ export HERE=$PWD +if [ $# -ne 1 ] ; then + cd .. ; export TMVASYS=$PWD; cd $HERE + TMVATESTDIR=1 + if [[ "$TMVASYS/test" != "$PWD" ]]; then + echo + echo "!!! please give the directory of your TMVA installation you want to use as argument to " + echo "!!! source setup.sh <the TMVA installation directory>" + echo + return + fi +else + export TMVASYS=$1 + TMVATESTDIR=0 + echo + echo " you have specified to use TMVA installed in:" $argv[1] +fi + +# check if the TMVA directory specified REALLY contains the TMVA libraries, otherwise it +# might default to the ROOT version causing unnecessary surprises + +if [[ ! -f $TMVASYS/lib/libTMVA.so ]]; then + echo + echo "!!!! please give a PROPER directory of your TMVA installation as argument to " + echo "!!!! source setup.sh <the TMVA installation directory> " + echo + echo "!!!! currently I look at $TMVASYS/lib/libTMVA.so that doesn't exist " + echo + return +fi + + +echo "use TMVA version installed in " $TMVASYS + + # set symbolic links to data file and to rootmaps #cd test; -if [ ! -h tmva_example.root ]; then ln -s data/toy_sigbkg.root tmva_example.root; fi -if [ ! -h tmva_reg_example.root ]; then ln -s data/regression_parabola_noweights.root tmva_reg_example.root; fi -if [ ! -h libTMVA.rootmap ]; then ln -s ../lib/libTMVA.rootmap; fi -if [ ! -h .rootmap ]; then ln -s ../lib/libTMVA.rootmap .rootmap; fi -cd .. +if [[ ! -h tmva_example.root && $TMVATESTDIR -eq 1 ]]; then ln -s data/toy_sigbkg.root tmva_example.root; fi +if [[ ! -h tmva_reg_example.root && $TMVATESTDIR -eq 1 ]]; then ln -s data/regression_parabola_noweights.root tmva_reg_example.root; fi +#ln -sf $TMVASYS/lib/libTMVA.rootmap; +#ln -sf $TMVASYS/lib/libTMVA.rootmap .rootmap; +#if [[ ! -f TMVAlogon.C ]]; then cp $TMVASYS/test/TMVAlogon.C . ; fi +#if [[ ! -f TMVAGui.C ]]; then cp $TMVASYS/test/TMVAGui.C . ; fi +#if [[ ! -f TMVARegGui.C ]]; then cp $TMVASYS/test/TMVARegGui.C . ; fi +#if [[ ! -f tmvaglob.C ]]; then cp $TMVASYS/test/tmvaglob.C . ; fi +if [[ ! -f .rootrc ]]; then cp $TMVASYS/test/.rootrc . ; fi + # Check Root environment setup # It's checked in such a fancy way, because if you install ROOT using @@ -23,24 +62,23 @@ if [ ! $ROOTSYS ]; then return 1 fi -export TMVASYS=$PWD # On MacOS X $DYLD_LIBRARY_PATH has to be modified, so: if [[ `root-config --platform` == "macosx" ]]; then if [ ! $DYLD_LIBRARY_PATH ]; then - export DYLD_LIBRARY_PATH=$PWD/lib:`root-config --libdir` + export DYLD_LIBRARY_PATH=$TMVASYS/lib:`root-config --libdir` else - export DYLD_LIBRARY_PATH=$PWD/lib:${DYLD_LIBRARY_PATH} + export DYLD_LIBRARY_PATH=$TMVASYS/lib:${DYLD_LIBRARY_PATH} fi elif [[ `root-config --platform` == "solaris" ]]; then if [ ! $LD_LIBRARY_PATH ]; then - export LD_LIBRARY_PATH=$PWD/lib:`root-config --libdir` + export LD_LIBRARY_PATH=$TMVASYS/lib:`root-config --libdir` else - export LD_LIBRARY_PATH=$PWD/lib:${LD_LIBRARY_PATH} + export LD_LIBRARY_PATH=$TMVASYS/lib:${LD_LIBRARY_PATH} fi else @@ -51,11 +89,11 @@ else echo "Warning: so far you haven't setup your ROOT enviroment properly (no LD_LIBRARY_PATH): TMVA will not work" fi fi - export LD_LIBRARY_PATH=$PWD/lib:${LD_LIBRARY_PATH} + export LD_LIBRARY_PATH=$TMVASYS/lib:${LD_LIBRARY_PATH} fi # prepare for PyROOT -export PYTHONPATH=$PWD/lib:`root-config --libdir`:$PYTHONPATH +export PYTHONPATH=$TMVASYS/lib:`root-config --libdir`:$PYTHONPATH cd $HERE diff --git a/tree/doc/v534/index.html b/tree/doc/v534/index.html index da3815ad00aff..edcebf2b5b61f 100644 --- a/tree/doc/v534/index.html +++ b/tree/doc/v534/index.html @@ -10,5 +10,81 @@ <h4>Performance</h4> In addition, a <tt>TTreeCache</tt> for a <tt>TTree</tt> can be added using <tt>TFile::SetCacheRead(TFileCacheRead*, TObject*)</tt>, where the second (optional) argument is a pointer to the <tt>TTree</tt>. The cache can be removed by setting the pointer to 0. In that case the user will have to take ownership for the cache.<p/> Similarily, a pointer to the <tt>TTreeCache</tt> for a <tt>TTree</tt> can be obtained using <tt>TFile::GetCacheRead(TObject*)</tt>. </li> +<li>In <tt>TBuffer::Expand</tt>, when shrinking the buffer do not shrink below the size of the +data already accumulated in the buffer (i. no less than the value of <tt>TBuffer::Length</tt>). +<p/> +In <tt>TBranch::SetBasketSize</tt>, instead of using the hard minimum of 100, use +100 + the length of the branch name (as 100 is too small to hold the +basket's key information for any branch name larger than 30 characters).</li> + +</ul> + +<h4>Reading form text file</h4> + +Reworked <tt>TTree::ReadStream</tt> and <tt>TTree::ReadFile</tt> mainly to fix delimited reading of string columns: +<ul> +<li><tt>TLeaf::ReadValue</tt> now takes an optional delimiter argument that is ignored for all but TLeafC. Here, input stops when reading this character, instead of at the first whitespace. +Use that in TTree::ReadStream() to delimit reading of TLeafC.</li> +<li><tt>TTree::ReadStream</tt> now tokenizes the row itself, and passes a stringstream containing nothing but the current column to <tt>TLeaf::ReadValue</tt>.</li> +<li>Separate concepts of number of input line (for communication with user) and number of good lines (as returned).</li> +<li>Fix windows files leaving '\n' in branch names when reading them from the file.</li> +<li>Add error message for TLeaf::ReadValue(), i.e. if ReadValue() is called on a derived class that doesn't implement it.</li> +<li>Updated and clarified the documentation</li> +</ul> + +<h4>TEntryList</h4> +<ul> +<li>Add new methods to find the base location of files and to modify it. + This allows to relocate the entry-lists to be able to use them of a + system where the files have a different absolute path. + The most relevant new methods are: +<ul> + <li><tt>TEntryList::Scan(const char *fn)</tt> + Shows the root common paths for the files of the TEntryLists in 'fn'</li> + <li><pre lang="cxx">TEntryList::Relocate(const char *fn, const char *newroot, + const char *oldroot = 0, const char *enlnm = 0)</pre> + Relocates all paths starting with 'oldroot' to 'newroot' for the + entry-list 'enlnm' in file 'fn'.</li> </ul> +</li> +<li>Remove 'protocol+server' from file tagging and matching, i.e. use + only filepath+anchor; in this way a list is valid even after re-staging + of the dataset files, which typically changes the end-point data servers.</li> +<li>Entry-lists created with the full path should still be matched correctly.</li> +</ul> + +<h4>Miscellaneous</h4> +<ul> +<li>Repaired the behavior of <tt>TTreeCache</tt> when the TTree has a dramatic dynamic range with a lots of very small entriesat the beginning and very large entries at the end, the size in bytes of the cluster for the later entries will be very large (because of the cluster size in entries is large!). TTreeCache::FillBuffer was always attempting to load complete clusters not matter the +size (even with the size was larger than 2GB!). + +This patch resolves the issue by limiting the amount of memory used to: +<ol> +<li>The requested size if more than one cluster fits in the cache.</li> +<li>Twice the requested size if at least one basket per branch fits in the cache.</li> +<li>Four time the requested size in the case where the cache can not even hold one basket per branch.</li> +</ol> +The filling will restart at the next cluster boundary in the case a) and will +restart at the maximum of entry number read in the cache in the case b) and c). +Baskets that are below this boundary and did not fit in the cache will be read +individually.</li> +<li>Repaired the basket flushing frequency when the <tt>TTree</tt> has already more than one cluster size.</li> +<li>Repaired binning of string histogram generated by <tt>TTree::Draw.</tt></li> +<li>Many bug fixes and fix for issues discovery by Coverity, see change log for more details.</li> +<li>In <tt>TTree::MakeProxy</tt> add proper support for top level stl collection of objects and for stl collection of objects that are 'empty' in the file (and thus we know nothing about its content).</li> +<li>Avoid deficiency in <tt>hadd</tt> when the resulting <tt>TTree</tt> is longer than the <tt>AutoSave</tt> length *and* the <tt>TFileMerger</tt> needs to handle the input files in more than one pass for example when there is more than 1000 input files or the -n option is passed to <tt>hadd</tt>.</li> +<li>Fix support for emulated class that derived from an abstract class. +This can happen when reading a file containing an ancient +class layout where the derived class is no longer provided in the +compiled code but the abstract base class is still provided. + +It also happens when using schema evolution rules on a class derived +from an abstract base class (in which case the system introduce +implicitly an emulated class deriving from the same base classes +as the evolved from class). To fix the issue, we introduce the <tt>TClass::GetStreamerInfoAbstractEmulated</tt> +which will return a StreamerInfo representing an emulated version of the +class even if it is loaded.</li> + +</ul> + diff --git a/tree/tree/Module.mk b/tree/tree/Module.mk index e0253795e29bc..dd0ee5efe21a4 100644 --- a/tree/tree/Module.mk +++ b/tree/tree/Module.mk @@ -18,7 +18,7 @@ TREEDS := $(call stripsrc,$(MODDIRS)/G__Tree.cxx) TREEDO := $(TREEDS:.cxx=.o) TREEDH := $(TREEDS:.cxx=.h) -# ManualBase4 only needs to be regenerated (and then changed manually) when +# ManualTree2 only needs to be regenerated (and then changed manually) when # the dictionary interface changes TREEL2 := $(MODDIRI)/LinkDef2.h TREEDS2 := $(call stripsrc,$(MODDIRS)/ManualTree2.cxx) diff --git a/tree/tree/inc/LinkDef.h b/tree/tree/inc/LinkDef.h index 6188eeb5525c8..cde754b3aff9b 100644 --- a/tree/tree/inc/LinkDef.h +++ b/tree/tree/inc/LinkDef.h @@ -67,6 +67,7 @@ #pragma link C++ class TBranchSTL+; #pragma link C++ class TIndArray+; +#pragma link C++ enum TTree::ESetBranchAddressStatus; #pragma link C++ function operator+(const TCut&, const char*); #pragma link C++ function operator+(const char*, const TCut&); diff --git a/tree/tree/inc/TBranch.h b/tree/tree/inc/TBranch.h index aea2b427bffca..75de3803dcaa5 100644 --- a/tree/tree/inc/TBranch.h +++ b/tree/tree/inc/TBranch.h @@ -88,7 +88,7 @@ class TBranch : public TNamed , public TAttFill { TObjArray fBranches; //-> List of Branches of this branch TObjArray fLeaves; //-> List of leaves of this branch TObjArray fBaskets; //-> List of baskets of this branch - Int_t *fBasketBytes; //[fMaxBaskets] Lenght of baskets on file + Int_t *fBasketBytes; //[fMaxBaskets] Length of baskets on file Long64_t *fBasketEntry; //[fMaxBaskets] Table of first entry in eack basket Long64_t *fBasketSeek; //[fMaxBaskets] Addresses of baskets on file TTree *fTree; //! Pointer to Tree header diff --git a/tree/tree/inc/TBranchElement.h b/tree/tree/inc/TBranchElement.h index 082bebc748086..cc2f56652a556 100644 --- a/tree/tree/inc/TBranchElement.h +++ b/tree/tree/inc/TBranchElement.h @@ -113,7 +113,6 @@ class TBranchElement : public TBranch { virtual void InitializeOffsets(); virtual void InitInfo(); Bool_t IsMissingCollection() const; - TClass *GetCurrentClass(); // Class referenced by transient description TClass *GetParentClass(); // Class referenced by fParentName TStreamerInfo *GetInfoImp() const; void ReleaseObject(); @@ -181,6 +180,7 @@ class TBranchElement : public TBranch { virtual TClass *GetClass() const { return fBranchClass; } virtual const char *GetClonesName() const { return fClonesName.Data(); } TVirtualCollectionProxy *GetCollectionProxy(); + TClass *GetCurrentClass(); // Class referenced by transient description virtual Int_t GetEntry(Long64_t entry = 0, Int_t getall = 0); virtual Int_t GetExpectedType(TClass *&clptr,EDataType &type); const char *GetIconName() const; @@ -195,7 +195,8 @@ class TBranchElement : public TBranch { Int_t GetStreamerType() const { return fStreamerType; } virtual TClass *GetTargetClass() { return fTargetClass; } virtual const char *GetTypeName() const; - Double_t GetValue(Int_t i, Int_t len, Bool_t subarr = kFALSE) const; + Double_t GetValue(Int_t i, Int_t len, Bool_t subarr = kFALSE) const { return GetTypedValue<Double_t>(i, len, subarr); } + template<typename T > T GetTypedValue(Int_t i, Int_t len, Bool_t subarr = kFALSE) const; virtual void *GetValuePointer() const; Int_t GetClassVersion() { return fClassVersion; } Bool_t IsBranchFolder() const { return TestBit(kBranchFolder); } @@ -222,6 +223,20 @@ class TBranchElement : public TBranch { virtual void SetType(Int_t btype) { fType = btype; } virtual void UpdateFile(); + enum EBranchElementType { + kLeafNode = 0, + kBaseClassNode = 1, // -- We are a base class element. + // Note: This does not include an STL container class which is + // being used as a base class because the streamer element + // in that case is not the base streamer element it is the + // STL streamer element. + kObjectNode = 2, + kClonesNode = 3, + kSTLNode = 4, + kClonesMemberNode = 31, + kSTLMemberNode = 41 + }; + ClassDef(TBranchElement,9) // Branch in case of an object }; diff --git a/tree/tree/inc/TBufferSQL.h b/tree/tree/inc/TBufferSQL.h index f1402c697241d..7591abc58cfc4 100644 --- a/tree/tree/inc/TBufferSQL.h +++ b/tree/tree/inc/TBufferSQL.h @@ -119,6 +119,10 @@ class TBufferSQL : public TBufferFile { virtual void ReadFastArray(Double_t *, Int_t ); virtual void ReadFastArrayFloat16(Float_t *f, Int_t n, TStreamerElement *ele=0); virtual void ReadFastArrayDouble32(Double_t *d, Int_t n, TStreamerElement *ele=0); + virtual void ReadFastArrayWithFactor(Float_t *ptr, Int_t n, Double_t factor, Double_t minvalue) ; + virtual void ReadFastArrayWithNbits(Float_t *ptr, Int_t n, Int_t nbits); + virtual void ReadFastArrayWithFactor(Double_t *ptr, Int_t n, Double_t factor, Double_t minvalue); + virtual void ReadFastArrayWithNbits(Double_t *ptr, Int_t n, Int_t nbits) ; virtual void ReadFastArray(void *, const TClass *, Int_t n=1, TMemberStreamer *s=0, const TClass *onFileClass=0); virtual void ReadFastArray(void **, const TClass *, Int_t n=1, Bool_t isPreAlloc=kFALSE, TMemberStreamer *s=0, const TClass *onFileClass=0); diff --git a/tree/tree/inc/TChain.h b/tree/tree/inc/TChain.h index e16cdcda98d0f..3fed237634c6b 100644 --- a/tree/tree/inc/TChain.h +++ b/tree/tree/inc/TChain.h @@ -134,15 +134,28 @@ class TChain : public TTree { virtual Long64_t Process(TSelector* selector, Option_t* option = "", Long64_t nentries = kBigNumber, Long64_t firstentry = 0); #endif virtual void RecursiveRemove(TObject *obj); + virtual void RemoveFriend(TTree*); virtual void Reset(Option_t *option=""); virtual void ResetAfterMerge(TFileMergeInfo *); virtual void ResetBranchAddress(TBranch *); virtual void ResetBranchAddresses(); virtual Long64_t Scan(const char *varexp="", const char *selection="", Option_t *option="", Long64_t nentries=1000000000, Long64_t firstentry=0); // *MENU* virtual void SetAutoDelete(Bool_t autodel=kTRUE); +#if !defined(__CINT__) virtual Int_t SetBranchAddress(const char *bname,void *add, TBranch **ptr = 0); +#endif virtual Int_t SetBranchAddress(const char *bname,void *add, TBranch **ptr, TClass *realClass, EDataType datatype, Bool_t isptr); virtual Int_t SetBranchAddress(const char *bname,void *add, TClass *realClass, EDataType datatype, Bool_t isptr); + template <class T> Int_t SetBranchAddress(const char *bname, T **add, TBranch **ptr = 0) { + return TTree::SetBranchAddress<T>(bname, add, ptr); + } +#ifndef R__NO_CLASS_TEMPLATE_SPECIALIZATION + // This can only be used when the template overload resolution can distringuish between + // T* and T** + template <class T> Int_t SetBranchAddress(const char *bname, T *add, TBranch **ptr = 0) { + return TTree::SetBranchAddress<T>(bname, add, ptr); + } +#endif virtual void SetBranchStatus(const char *bname, Bool_t status=1, UInt_t *found=0); virtual void SetCacheSize(Long64_t cacheSize); diff --git a/tree/tree/inc/TIndArray.h b/tree/tree/inc/TIndArray.h index d6fe7336434f8..c8429d1cf969f 100644 --- a/tree/tree/inc/TIndArray.h +++ b/tree/tree/inc/TIndArray.h @@ -24,9 +24,9 @@ class TIndArray delete [] fArr; } - void Reserve( UInt_t size ) + void ClearAndResize( UInt_t size ) { - delete fArr; + delete [] fArr; fElems = 0; fArr = new UChar_t[size]; fCapacity = size; diff --git a/tree/tree/inc/TLeaf.h b/tree/tree/inc/TLeaf.h index b0fc975a2bc8a..41738c1045941 100644 --- a/tree/tree/inc/TLeaf.h +++ b/tree/tree/inc/TLeaf.h @@ -50,6 +50,10 @@ class TLeaf : public TNamed { TLeaf(const TLeaf&); TLeaf& operator=(const TLeaf&); + template <typename T> struct GetValueHelper { + static T Exec(const TLeaf *leaf, Int_t i = 0) { return leaf->GetValue(i); } + }; + public: enum { kIndirectAddress = BIT(11), // Data member is a pointer to an array of basic types. @@ -75,7 +79,12 @@ class TLeaf : public TNamed { virtual Int_t GetOffset() const { return fOffset; } virtual void *GetValuePointer() const { return 0; } virtual const char *GetTypeName() const { return ""; } + virtual Double_t GetValue(Int_t i = 0) const; + virtual Long64_t GetValueLong64(Int_t i = 0) const { return GetValue(i); } //overload only when it matters. + virtual LongDouble_t GetValueLongDouble(Int_t i = 0) const { return GetValue(i); } // overload only when it matters. + template <typename T > T GetTypedValue(Int_t i = 0) const { return GetValueHelper<T>::Exec(this, i); } + virtual void Import(TClonesArray*, Int_t) {} virtual Bool_t IsOnTerminalBranch() const { return kTRUE; } virtual Bool_t IsRange() const { return fIsRange; } @@ -98,6 +107,19 @@ class TLeaf : public TNamed { ClassDef(TLeaf,2); //Leaf: description of a Branch data type }; + +template <> struct TLeaf::GetValueHelper<Long64_t> { + static Long64_t Exec(const TLeaf *leaf, Int_t i = 0) { return leaf->GetValueLong64(i); } +}; +template <> struct TLeaf::GetValueHelper<ULong64_t> { + static ULong64_t Exec(const TLeaf *leaf, Int_t i = 0) { return (ULong64_t)leaf->GetValueLong64(i); } +}; +template <> struct TLeaf::GetValueHelper<LongDouble_t> { + static LongDouble_t Exec(const TLeaf *leaf, Int_t i = 0) { return leaf->GetValueLongDouble(i); } +}; + + + inline Double_t TLeaf::GetValue(Int_t /*i = 0*/) const { return 0.0; } inline void TLeaf::PrintValue(Int_t /* i = 0*/) const {} inline void TLeaf::SetAddress(void* /* add = 0 */) {} diff --git a/tree/tree/inc/TLeafElement.h b/tree/tree/inc/TLeafElement.h index 2f43e7217099a..dcc289feddf3d 100644 --- a/tree/tree/inc/TLeafElement.h +++ b/tree/tree/inc/TLeafElement.h @@ -48,8 +48,12 @@ class TLeafElement : public TLeaf { virtual Int_t GetMaximum() const {return ((TBranchElement*)fBranch)->GetMaximum();} virtual Int_t GetNdata() const {return ((TBranchElement*)fBranch)->GetNdata()*fLen;} virtual const char *GetTypeName() const {return ((TBranchElement*)fBranch)->GetTypeName();} - virtual Double_t GetValue(Int_t i=0) const {return ((TBranchElement*)fBranch)->GetValue(i, fLen, kFALSE);} - virtual Double_t GetValueSubArray(Int_t i=0, Int_t j=0) const {return ((TBranchElement*)fBranch)->GetValue(i, j, kTRUE);} + + virtual Double_t GetValue(Int_t i=0) const { return ((TBranchElement*)fBranch)->GetValue(i, fLen, kFALSE);} + virtual Long64_t GetValueLong64(Int_t i = 0) const { return ((TBranchElement*)fBranch)->GetTypedValue<Long64_t>(i, fLen, kFALSE); } + virtual LongDouble_t GetValueLongDouble(Int_t i = 0) const { return ((TBranchElement*)fBranch)->GetTypedValue<LongDouble_t>(i, fLen, kFALSE); } + template<typename T> T GetTypedValueSubArray(Int_t i=0, Int_t j=0) const {return ((TBranchElement*)fBranch)->GetTypedValue<T>(i, j, kTRUE);} + virtual void *GetValuePointer() const { return ((TBranchElement*)fBranch)->GetValuePointer(); } virtual Bool_t IsOnTerminalBranch() const; virtual void PrintValue(Int_t i=0) const {((TBranchElement*)fBranch)->PrintValue(i);} diff --git a/tree/tree/inc/TLeafL.h b/tree/tree/inc/TLeafL.h index 8933dc6d36b94..e38b5dfc09922 100644 --- a/tree/tree/inc/TLeafL.h +++ b/tree/tree/inc/TLeafL.h @@ -44,7 +44,9 @@ class TLeafL : public TLeaf { const char *GetTypeName() const; virtual Int_t GetMaximum() const {return (Int_t)fMaximum;} virtual Int_t GetMinimum() const {return (Int_t)fMinimum;} - Double_t GetValue(Int_t i=0) const; + virtual Double_t GetValue(Int_t i=0) const; + virtual Long64_t GetValueLong64(Int_t i = 0) const ; + virtual LongDouble_t GetValueLongDouble(Int_t i = 0) const; virtual void *GetValuePointer() const {return fValue;} virtual void Import(TClonesArray *list, Int_t n); virtual void PrintValue(Int_t i=0) const; @@ -58,4 +60,8 @@ class TLeafL : public TLeaf { ClassDef(TLeafL,1); //A TLeaf for a 64 bit Integer data type. }; +// if leaf is a simple type, i must be set to 0 +// if leaf is an array, i is the array element number to be returned +inline Long64_t TLeafL::GetValueLong64(Int_t i) const { return fValue[i]; } + #endif diff --git a/tree/tree/inc/TSelectorList.h b/tree/tree/inc/TSelectorList.h index 244d4b9d58922..8d4867d2059c5 100644 --- a/tree/tree/inc/TSelectorList.h +++ b/tree/tree/inc/TSelectorList.h @@ -17,7 +17,7 @@ // // // TSelectorList // // // -// A TList derived class that makes sure that objects added to it // +// A THashList derived class that makes sure that objects added to it // // are not linked to the currently open file (like histograms, // // eventlists and trees). Also it makes sure the name of the added // // object is unique. This class is used in the TSelector for the // @@ -25,19 +25,19 @@ // // ////////////////////////////////////////////////////////////////////////// -#ifndef ROOT_TList -#include "TList.h" +#ifndef ROOT_THashList +#include "THashList.h" #endif -class TSelectorList : public TList { +class TSelectorList : public THashList { private: Bool_t UnsetDirectory(TObject *obj); Bool_t CheckDuplicateName(TObject *obj); public: - TSelectorList() : TList() { SetOwner(); } + TSelectorList() : THashList() { SetOwner(); } void AddFirst(TObject *obj); void AddFirst(TObject *obj, Option_t *opt); diff --git a/tree/tree/inc/TTree.h b/tree/tree/inc/TTree.h index 45f6392a838cc..42b44d53d6211 100644 --- a/tree/tree/inc/TTree.h +++ b/tree/tree/inc/TTree.h @@ -203,6 +203,8 @@ class TTree : public TNamed, public TAttLine, public TAttFill, public TAttMarker kSetBranchStatus = BIT(12) }; +public: + // SetBranchAddress return values enum ESetBranchAddressStatus { kMissingBranch = -5, kInternalError = -4, @@ -217,7 +219,6 @@ class TTree : public TNamed, public TAttLine, public TAttFill, public TAttMarker kNoCheck = 5 }; -public: // TTree status bits enum { kForceRead = BIT(11), @@ -483,7 +484,7 @@ class TTree : public TNamed, public TAttLine, public TAttFill, public TAttMarker virtual Long64_t Scan(const char* varexp = "", const char* selection = "", Option_t* option = "", Long64_t nentries = 1000000000, Long64_t firstentry = 0); // *MENU* virtual Bool_t SetAlias(const char* aliasName, const char* aliasFormula); virtual void SetAutoSave(Long64_t autos = 300000000); - virtual void SetAutoFlush(Long64_t autof = 30000000); + virtual void SetAutoFlush(Long64_t autof = -30000000); virtual void SetBasketSize(const char* bname, Int_t buffsize = 16000); #if !defined(__CINT__) virtual Int_t SetBranchAddress(const char *bname,void *add, TBranch **ptr = 0); diff --git a/tree/tree/inc/TTreeCache.h b/tree/tree/inc/TTreeCache.h index ae0e6dbf2343c..d69c3352cb723 100644 --- a/tree/tree/inc/TTreeCache.h +++ b/tree/tree/inc/TTreeCache.h @@ -33,6 +33,9 @@ class TBranch; class TTreeCache : public TFileCacheRead { +public: + enum EPrefillType { kNoPrefill, kAllBranches }; + protected: Long64_t fEntryMin; //! first entry in the cache Long64_t fEntryMax; //! last entry in the cache @@ -54,6 +57,8 @@ class TTreeCache : public TFileCacheRead { Bool_t fFirstTime; //! save the fact that we processes the first entry Long64_t fFirstEntry; //! save the value of the first entry Bool_t fReadDirectionSet; //! read direction established + Bool_t fEnabled; //! cache enabled for cached reading + EPrefillType fPrefillType; // Whether a prefilling is enabled (and if applicable which type) static Int_t fgLearnEntries; // number of entries used for learning mode private: @@ -61,31 +66,42 @@ class TTreeCache : public TFileCacheRead { TTreeCache& operator=(const TTreeCache &); public: + TTreeCache(); TTreeCache(TTree *tree, Int_t buffersize=0); virtual ~TTreeCache(); - virtual void AddBranch(TBranch *b, Bool_t subgbranches = kFALSE); - virtual void AddBranch(const char *branch, Bool_t subbranches = kFALSE); - virtual void DropBranch(TBranch *b, Bool_t subbranches = kFALSE); - virtual void DropBranch(const char *branch, Bool_t subbranches = kFALSE); - const TObjArray *GetCachedBranches() const { return fBranches; } - Double_t GetEfficiency() const; - Double_t GetEfficiencyRel() const; - static Int_t GetLearnEntries(); - - virtual Bool_t FillBuffer(); - TTree *GetTree() const; - virtual Bool_t IsLearning() const {return fIsLearning;} - virtual void Print(Option_t *option="") const; - virtual Int_t ReadBuffer(char *buf, Long64_t pos, Int_t len); - virtual Int_t ReadBufferNormal(char *buf, Long64_t pos, Int_t len); - virtual Int_t ReadBufferPrefetch(char *buf, Long64_t pos, Int_t len); - virtual void ResetCache(); - virtual void SetEntryRange(Long64_t emin, Long64_t emax); - static void SetLearnEntries(Int_t n = 10); - void StartLearningPhase(); - virtual void StopLearningPhase(); - virtual void UpdateBranches(TTree *tree); + virtual void AddBranch(TBranch *b, Bool_t subgbranches = kFALSE); + virtual void AddBranch(const char *branch, Bool_t subbranches = kFALSE); + virtual void DropBranch(TBranch *b, Bool_t subbranches = kFALSE); + virtual void DropBranch(const char *branch, Bool_t subbranches = kFALSE); + virtual void Disable() {fEnabled = kFALSE;} + virtual void Enable() {fEnabled = kTRUE;} + const TObjArray *GetCachedBranches() const { return fBranches; } + Double_t GetEfficiency() const; + Double_t GetEfficiencyRel() const; + virtual Int_t GetEntryMin() const {return fEntryMin;} + virtual Int_t GetEntryMax() const {return fEntryMax;} + static Int_t GetLearnEntries(); + virtual EPrefillType GetLearnPrefill() const {return fPrefillType;} + TTree *GetTree() const; + virtual Bool_t IsEnabled() const {return fEnabled;} + virtual Bool_t IsLearning() const {return fIsLearning;} + + virtual Bool_t FillBuffer(); + virtual void LearnPrefill(); + + virtual void Print(Option_t *option="") const; + virtual Int_t ReadBuffer(char *buf, Long64_t pos, Int_t len); + virtual Int_t ReadBufferNormal(char *buf, Long64_t pos, Int_t len); + virtual Int_t ReadBufferPrefetch(char *buf, Long64_t pos, Int_t len); + virtual void ResetCache(); + virtual void SetEntryRange(Long64_t emin, Long64_t emax); + virtual void SetFile(TFile *file, TFile::ECacheAction action=TFile::kDisconnect); + virtual void SetLearnPrefill(EPrefillType type = kNoPrefill); + static void SetLearnEntries(Int_t n = 10); + void StartLearningPhase(); + virtual void StopLearningPhase(); + virtual void UpdateBranches(TTree *tree); ClassDef(TTreeCache,2) //Specialization of TFileCacheRead for a TTree }; diff --git a/tree/tree/inc/TVirtualIndex.h b/tree/tree/inc/TVirtualIndex.h index 513372fb01693..f2a2a29b9ef4d 100644 --- a/tree/tree/inc/TVirtualIndex.h +++ b/tree/tree/inc/TVirtualIndex.h @@ -38,8 +38,8 @@ class TVirtualIndex : public TNamed { virtual ~TVirtualIndex(); virtual void Append(const TVirtualIndex *,Bool_t delaySort = kFALSE) = 0; virtual Long64_t GetEntryNumberFriend(const TTree * /*parent*/) = 0; - virtual Long64_t GetEntryNumberWithIndex(Int_t major, Int_t minor) const = 0; - virtual Long64_t GetEntryNumberWithBestIndex(Int_t major, Int_t minor) const = 0; + virtual Long64_t GetEntryNumberWithIndex(Long64_t major, Long64_t minor) const = 0; + virtual Long64_t GetEntryNumberWithBestIndex(Long64_t major, Long64_t minor) const = 0; virtual const char *GetMajorName() const = 0; virtual const char *GetMinorName() const = 0; virtual Long64_t GetN() const = 0; diff --git a/tree/tree/src/ManualTree2Body.h b/tree/tree/src/ManualTree2Body.h index 0d20ee6e5c369..cecd54a98d881 100644 --- a/tree/tree/src/ManualTree2Body.h +++ b/tree/tree/src/ManualTree2Body.h @@ -268,7 +268,7 @@ static int G__ManualTree2_119_0_216(G__value* result7, G__CONST char* funcname, case 2: break; } - ((TTree*)(G__getstructoffset()))->SetBranchAddress((const char*)G__int(libp->para[0]),(void*)G__int(libp->para[1]),branchPtr,ptrClass,datatype,gInterpreter->TypeInfo_RefType(ti)==G__PARAP2P); + G__letint(result7,105,((TTree*)(G__getstructoffset()))->SetBranchAddress((const char*)G__int(libp->para[0]),(void*)G__int(libp->para[1]),branchPtr,ptrClass,datatype,gInterpreter->TypeInfo_RefType(ti)==G__PARAP2P)); gInterpreter->TypeInfo_Delete( ti ); return(1 || funcname || hash || result7 || libp) ; diff --git a/tree/tree/src/TBasket.cxx b/tree/tree/src/TBasket.cxx index 3d9bc642f4d1e..af80f38be9cbe 100644 --- a/tree/tree/src/TBasket.cxx +++ b/tree/tree/src/TBasket.cxx @@ -1,4 +1,4 @@ -// @(#)root/tree:$Id$ +// @(#)root/tree:$Id: 4e77188fbf1e7fd026a984989de66663c49b12fc $ // Author: Rene Brun 19/01/96 /************************************************************************* * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * @@ -229,15 +229,15 @@ Int_t TBasket::LoadBasketBuffers(Long64_t pos, Int_t len, TFile *file, TTree *tr if (fBufferRef) { // Reuse the buffer if it exist. - fBufferRef->SetReadMode(); fBufferRef->Reset(); + // We use this buffer both for reading and writing, we need to // make sure it is properly sized for writing. + fBufferRef->SetWriteMode(); if (fBufferRef->BufferSize() < len) { - fBufferRef->SetWriteMode(); fBufferRef->Expand(len); - fBufferRef->SetReadMode(); } + fBufferRef->SetReadMode(); } else { fBufferRef = new TBufferFile(TBuffer::kRead, len); } @@ -252,7 +252,12 @@ Int_t TBasket::LoadBasketBuffers(Long64_t pos, Int_t len, TFile *file, TTree *tr } else if (st == 0) { // fOffset might have been changed via TFileCacheRead::ReadBuffer(), reset it file->Seek(pos); + // If we are using a TTreeCache, disable reading from the default cache + // temporarily, to force reading directly from file + TTreeCache *fc = dynamic_cast<TTreeCache*>(file->GetCacheRead()); + if (fc) fc->Disable(); Int_t ret = file->ReadBuffer(buffer,len); + if (fc) fc->Enable(); pf->AddNoCacheBytesRead(len); pf->AddNoCacheReadCalls(1); if (ret) { @@ -472,7 +477,13 @@ Int_t TBasket::ReadBasketBuffers(Long64_t pos, Int_t len, TFile *file) if (st < 0) { return 1; } else if (st == 0) { + // Read directly from file, not from the cache + // If we are using a TTreeCache, disable reading from the default cache + // temporarily, to force reading directly from file + TTreeCache *fc = dynamic_cast<TTreeCache*>(file->GetCacheRead()); + if (fc) fc->Disable(); Int_t ret = file->ReadBuffer(readBufferRef->Buffer(),pos,len); + if (fc) fc->Enable(); pf->AddNoCacheBytesRead(len); pf->AddNoCacheReadCalls(1); if (ret) { diff --git a/tree/tree/src/TBranch.cxx b/tree/tree/src/TBranch.cxx index acaf3007b57f9..d674054411959 100644 --- a/tree/tree/src/TBranch.cxx +++ b/tree/tree/src/TBranch.cxx @@ -1720,7 +1720,7 @@ void TBranch::Print(Option_t*) const } if (fLeaves.GetEntries() == 1) { - if (titleContent[titleContent.Length()-2]=='/' && isalpha(titleContent[titleContent.Length()-1])) { + if (titleContent.Length()>=2 && titleContent[titleContent.Length()-2]=='/' && isalpha(titleContent[titleContent.Length()-1])) { // The type is already encoded. Nothing to do. } else { TLeaf *leaf = (TLeaf*)fLeaves.UncheckedAt(0); diff --git a/tree/tree/src/TBranchBrowsable.cxx b/tree/tree/src/TBranchBrowsable.cxx index c5d87ada87b50..21a6cd1b43c9c 100644 --- a/tree/tree/src/TBranchBrowsable.cxx +++ b/tree/tree/src/TBranchBrowsable.cxx @@ -666,13 +666,19 @@ Int_t TNonSplitBrowsable::GetBrowsables(TList& li, const TBranch* branch, if (!clElements) continue; // now loop over the class's streamer elements - streamerInfo= clElements->GetStreamerInfo(); - TIter iElem(streamerInfo->GetElements()); - TStreamerElement* elem=0; - while ((elem=(TStreamerElement*)iElem())) { - TNonSplitBrowsable* nsb=new TNonSplitBrowsable(elem, branch, parent); - li.Add(nsb); - numAdded++; + streamerInfo = clElements->GetStreamerInfo(); + if (streamerInfo) { + TIter iElem(streamerInfo->GetElements()); + TStreamerElement* elem=0; + while ((elem=(TStreamerElement*)iElem())) { + TNonSplitBrowsable* nsb=new TNonSplitBrowsable(elem, branch, parent); + li.Add(nsb); + numAdded++; + } + } else { + ::Error("TNonSplitBrowsable::GetBrowsables", + "Missing the StreamerInfo for the class \"%s\" for the branch \"%s\" in the TTree \"%s\".", + clElements->GetName(), branch->GetName(), branch->GetTree()->GetName()); } } else { // we have a basic streamer element diff --git a/tree/tree/src/TBranchElement.cxx b/tree/tree/src/TBranchElement.cxx index 6ac47bbbe4219..fc6562ec07281 100644 --- a/tree/tree/src/TBranchElement.cxx +++ b/tree/tree/src/TBranchElement.cxx @@ -47,6 +47,7 @@ #include "TROOT.h" #include "TStreamerInfoActions.h" +#include "TSchemaRuleSet.h" ClassImp(TBranchElement) @@ -1408,10 +1409,16 @@ void TBranchElement::FillLeavesCollection(TBuffer& b) b << n; if(fSTLtype != TClassEdit::kVector && proxy->HasPointers() && fSplitLevel > TTree::kSplitCollectionOfPointers ) { - fPtrIterators->CreateIterators(fObject); + fPtrIterators->CreateIterators(fObject, proxy); } else { //NOTE: this does not work for not vectors since the CreateIterators expects a TGenCollectionProxy::TStaging as its argument! - fIterators->CreateIterators(fObject); + //NOTE: and those not work in general yet, since the TStaging object is neither created nor passed. + // We need to review how to avoid the need for a TStaging during the writing. + if (proxy->GetProperties() & TVirtualCollectionProxy::kIsAssociative) { + // do nothing for now ... + } else { + fIterators->CreateIterators(fObject, proxy); + } } } @@ -1965,7 +1972,6 @@ void TBranchElement::InitInfo() for (size_t i = 0; i < ndata; ++i) { if (((TStreamerElement*) elems[i]) == elt) { if (elt->TestBit (TStreamerElement::kCache) - && elt->TestBit(TStreamerElement::kRepeat) && (i+1) < ndata && s == ((TStreamerElement*) elems[i])->GetName()) { @@ -1975,7 +1981,11 @@ void TBranchElement::InitInfo() // ReadLeaves). // fID = i+1; fID = i; - fIDs.push_back(fID+1); + if (elt->TestBit(TStreamerElement::kRepeat)) { + fIDs.push_back(fID+1); + } else if (((TStreamerElement*) elems[i+1])->TestBit(TStreamerElement::kWrite)) { + fIDs.push_back(fID+1); + } } else { fID = i; } @@ -2088,7 +2098,39 @@ TVirtualCollectionProxy* TBranchElement::GetCollectionProxy() className = se->GetTypeName(); } TClass* cl = TClass::GetClass(className); + if (!cl) { + // The TClass was not created but we do know (since it + // is used as a collection) that it 'className' was a + // class, so let's create it by hand!. + + if (fID < 0) { + cl = new TClass(fBranchClass.GetClassName(), fClassVersion, 0, 0, -1, -1); + cl->SetBit(TClass::kIsEmulation); + className = cl->GetName(); + } else { + cl = new TClass(className, fClassVersion, 0, 0, -1, -1); + cl->SetBit(TClass::kIsEmulation); + } + } TVirtualCollectionProxy* proxy = cl->GetCollectionProxy(); + if (!proxy) { + // humm, we must have an older file with a custom collection + // let's try to work-around it. + TString equiv; + equiv.Form("vector<%s>",fClonesName.Data()); + TClass *clequiv = TClass::GetClass(equiv); + proxy = clequiv->GetCollectionProxy(); + if (!proxy) { + Fatal("GetCollectionProxy", + "Can not create a Collection Proxy of any kind for the class \"%s\" needed by the branch \"%s\" of the TTree \"%s\"!", + className, GetName(), GetTree()->GetName()); + } + if (gDebug > 0) Info("GetCollectionProxy", + "Fixing the collection proxy of the class \"%s\" \n" + "\tneeded by the branch \"%s\" of the TTree \"%s\" to be similar to \"%s\".", + className, GetName(), GetTree()->GetName(),equiv.Data()); + cl->CopyCollectionProxy( *proxy ); + } fCollProxy = proxy->Generate(); fSTLtype = className ? TClassEdit::IsSTLCont(className) : 0; if (fSTLtype < 0) { @@ -2386,7 +2428,12 @@ const char* TBranchElement::GetTypeName() const } //______________________________________________________________________________ -Double_t TBranchElement::GetValue(Int_t j, Int_t len, Bool_t subarr) const +template Double_t TBranchElement::GetTypedValue(Int_t j, Int_t len, Bool_t subarr) const; +template Long64_t TBranchElement::GetTypedValue(Int_t j, Int_t len, Bool_t subarr) const; +template LongDouble_t TBranchElement::GetTypedValue(Int_t j, Int_t len, Bool_t subarr) const; + +template <typename T> +T TBranchElement::GetTypedValue(Int_t j, Int_t len, Bool_t subarr) const { // -- Returns the branch value. // @@ -2428,22 +2475,22 @@ Double_t TBranchElement::GetValue(Int_t j, Int_t len, Bool_t subarr) const } if ((fType == 3) || (fType == 4)) { // Top-level branch of a TClonesArray. - return (Double_t) fNdata; + return fNdata; } else if ((fType == 31) || (fType == 41)) { // sub branch of a TClonesArray Int_t atype = fStreamerType; if (atype < 20) { atype += 20; } - return GetInfoImp()->GetValue(fAddress, atype, j, 1); + return GetInfoImp()->GetTypedValue<T>(fAddress, atype, j, 1); } else if (fType <= 2) { // branch in split mode // FIXME: This should probably be < 60 instead! if ((fStreamerType > 40) && (fStreamerType < 55)) { Int_t atype = fStreamerType - 20; - return GetInfoImp()->GetValue(fAddress, atype, j, 1); + return GetInfoImp()->GetTypedValue<T>(fAddress, atype, j, 1); } else { - return GetInfoImp()->GetValue(object, prID, j, -1); + return GetInfoImp()->GetTypedValue<T>(object, prID, j, -1); } } } @@ -2458,27 +2505,27 @@ Double_t TBranchElement::GetValue(Int_t j, Int_t len, Bool_t subarr) const if (fType == 31) { TClonesArray* clones = (TClonesArray*) object; if (subarr) { - return GetInfoImp()->GetValueClones(clones, prID, j, len, fOffset); + return GetInfoImp()->GetTypedValueClones<T>(clones, prID, j, len, fOffset); } - return GetInfoImp()->GetValueClones(clones, prID, j/len, j%len, fOffset); + return GetInfoImp()->GetTypedValueClones<T>(clones, prID, j/len, j%len, fOffset); } else if (fType == 41) { TVirtualCollectionProxy::TPushPop helper(((TBranchElement*) this)->GetCollectionProxy(), object); if( fSplitLevel < TTree::kSplitCollectionOfPointers ) { if (subarr) - return GetInfoImp()->GetValueSTL(((TBranchElement*) this)->GetCollectionProxy(), prID, j, len, fOffset); + return GetInfoImp()->GetTypedValueSTL<T>(((TBranchElement*) this)->GetCollectionProxy(), prID, j, len, fOffset); - return GetInfoImp()->GetValueSTL(((TBranchElement*) this)->GetCollectionProxy(), prID, j/len, j%len, fOffset); + return GetInfoImp()->GetTypedValueSTL<T>(((TBranchElement*) this)->GetCollectionProxy(), prID, j/len, j%len, fOffset); } else { if (subarr) - return GetInfoImp()->GetValueSTLP(((TBranchElement*) this)->GetCollectionProxy(), prID, j, len, fOffset); - return GetInfoImp()->GetValueSTLP(((TBranchElement*) this)->GetCollectionProxy(), prID, j/len, j%len, fOffset); + return GetInfoImp()->GetTypedValueSTLP<T>(((TBranchElement*) this)->GetCollectionProxy(), prID, j, len, fOffset); + return GetInfoImp()->GetTypedValueSTLP<T>(((TBranchElement*) this)->GetCollectionProxy(), prID, j/len, j%len, fOffset); } } else { if (GetInfoImp()) { - return GetInfoImp()->GetValue(object, prID, j, -1); + return GetInfoImp()->GetTypedValue<T>(object, prID, j, -1); } return 0; } @@ -2611,6 +2658,7 @@ void TBranchElement::InitializeOffsets() TStreamerElement* branchElem = 0; Int_t localOffset = 0; TClass* branchClass = fBranchClass.GetClass(); + Bool_t renamed = kFALSE; if (fID > -1) { // -- Branch is *not* a top-level branch. // Instead of the streamer info class, we want the class of our @@ -2632,12 +2680,22 @@ void TBranchElement::InitializeOffsets() Warning("InitializeOffsets", "Cannot get streamer element for branch: %s!", GetName()); fInitOffsets = kTRUE; return; + } else if (branchElem->TestBit(TStreamerElement::kRepeat)) { + // If we have a repeating streamerElement, use the next + // one as it actually hold the 'real' data member('s offset) + if (elems[fID+1]) { + branchElem = (TStreamerElement*) elems[fID+1]; + } } localOffset = branchElem->GetOffset(); branchClass = branchElem->GetClassPointer(); if (localOffset == TStreamerInfo::kMissing) { fObject = 0; + } else { + renamed = branchClass && branchElem->GetNewClass() && (branchClass != branchElem->GetNewClass()); } + } else { + renamed = fTargetClass != fBranchClass; } if (!branchClass) { Error("InitializeOffsets", "Could not find class for branch: %s", GetName()); @@ -2646,12 +2704,11 @@ void TBranchElement::InitializeOffsets() } //------------------------------------------------------------------------ - // Extract the name of the STL branch in case we're splitting the - // collection of pointers + // Extract the name of the STL branch in case it has been split. //------------------------------------------------------------------------ TString stlParentName; Bool_t stlParentNameUpdated = kFALSE; - if( fType == 4 && fSplitLevel > TTree::kSplitCollectionOfPointers ) + if( fType == 4 ) { TBranch *br = GetMother()->GetSubBranch( this ); stlParentName = br->GetName(); @@ -2664,6 +2721,8 @@ void TBranchElement::InitializeOffsets() // Loop over our sub-branches and compute their offsets. for (Int_t subBranchIdx = 0; subBranchIdx < nbranches; ++subBranchIdx) { + bool alternateElement = false; + fBranchOffset[subBranchIdx] = 0; TBranchElement* subBranch = dynamic_cast<TBranchElement*> (fBranches[subBranchIdx]); if (subBranch == 0) { @@ -2671,6 +2730,13 @@ void TBranchElement::InitializeOffsets() continue; } + if (renamed) { + if (subBranch->fBranchClass == branchClass) { + if (branchElem) subBranch->SetTargetClass(branchElem->GetNewClass()->GetName()); + else subBranch->SetTargetClass(fTargetClass->GetName()); + } + } + TVirtualStreamerInfo* sinfo = subBranch->GetInfoImp(); if (!sinfo) { Warning("InitializeOffsets", "No streamer info for branch: %s subbranch: %s", GetName(), subBranch->GetName()); @@ -2689,6 +2755,31 @@ void TBranchElement::InitializeOffsets() Warning("InitializeOffsets", "No streamer element for branch: %s subbranch: %s", GetName(), subBranch->GetName()); fInitOffsets = kTRUE; return; + } else if (subBranchElement->TestBit(TStreamerElement::kRepeat)) { + // If we have a repeating streamerElement, use the next + // one as it actually hold the 'real' data member('s offset) + if (subBranchElems[subBranch->fID+1]) { + subBranchElement = (TStreamerElement*) subBranchElems[subBranch->fID+1]; + } + } else if (subBranchElement->TestBit(TStreamerElement::kCache)) { + // We have a cached item which is not a repeated but we might still + // have some Actions triggered by a rule that affect real + // data member(s). + if (subBranch->fReadActionSequence && subBranch->fReadActionSequence->fActions.size() > 1) { + typedef TStreamerInfoActions::ActionContainer_t::iterator iterator; + iterator end = subBranch->fReadActionSequence->fActions.end(); + for(iterator iter = subBranch->fReadActionSequence->fActions.begin(); + iter != end; ++iter) { + TStreamerInfoActions::TConfiguration *config = iter->fConfiguration; + UInt_t id = config->fElemId; + TStreamerElement *e = (TStreamerElement*)config->fInfo->GetElements()->At(id); + if (e && !e->TestBit(TStreamerElement::kCache)) { + subBranchElement = e; + alternateElement = true; + break; + } + } + } } localOffset = subBranchElement->GetOffset(); @@ -2923,7 +3014,8 @@ void TBranchElement::InitializeOffsets() // First check whether this sub-branch is part of the 'cache' (because the data member it // represents is no longer in the current class layout. TStreamerInfo *subInfo = subBranch->GetInfoImp(); - if (subInfo && subBranch->TestBit(kCache)) { // subInfo->GetElements()->At(subBranch->GetID())->TestBit(TStreamerElement::kCache)) { + //if (subInfo && subBranch->TestBit(kCache)) { // subInfo->GetElements()->At(subBranch->GetID())->TestBit(TStreamerElement::kCache)) { + if (subBranchElement->TestBit(TStreamerElement::kCache)) { pClass = ((TStreamerElement*)subInfo->GetElements()->At(0))->GetClassPointer(); } // FIXME: Do we need the other base class tests here? @@ -2976,27 +3068,62 @@ void TBranchElement::InitializeOffsets() //Warning("InitializeOffsets", "subBranch: '%s' has no parent class! Assuming parent class is: '%s'.", subBranch->GetName(), pClass->GetName()); } } - + if (renamed && pClass) { + if (pClass == branchClass) { + pClass = branchElem->GetNewClass(); + } else if (fCollProxy && pClass == branchClass->GetCollectionProxy()->GetValueClass()) { + pClass = fCollProxy->GetValueClass(); + } + } //------------------------------------------------------------------ // If we have the are the sub-branch of the TBranchSTL, we need // to remove it's name to get the correct real data offsets //----------------------------------------------------------------- - if( stlParentName.Length() ) + if( dynamic_cast<TBranchSTL*>(fParent) && stlParentName.Length() ) { - if( !strncmp( stlParentName.Data(), dataName.Data(), stlParentName.Length()-1 )) + if( !strncmp( stlParentName.Data(), dataName.Data(), stlParentName.Length()-1 ) + && dataName[ stlParentName.Length() ] == '.' ) dataName.Remove( 0, stlParentName.Length()+1 ); } // Find our offset in our parent class using // a lookup by name in the dictionary meta info // for our parent class. + + if (alternateElement) { + Ssiz_t dotpos = dataName.Last('.'); + Ssiz_t endpos = dataName.Length(); + if (dotpos != kNPOS) ++dotpos; else dotpos = 0; + dataName.Replace(dotpos,endpos-dotpos,subBranchElement->GetFullName()); + } TRealData* rd = pClass->GetRealData(dataName); if (rd && !rd->TestBit(TRealData::kTransient)) { // -- Data member exists in the dictionary meta info, get the offset. offset = rd->GetThisOffset(); + } else if (subBranchElement->TestBit(TStreamerElement::kWholeObject)) { + // We are a rule with no specific target, it applies to the whole + // object, let's set the offset to zero + offset = 0; } else { - // -- No dictionary meta info for this data member, it must no longer exist. + // -- No dictionary meta info for this data member, it must no + // longer exist + if (fEntries == 0) { + // ... unless we creating the branch in which case + // we have an internal error. + if (pClass->GetListOfRealData()->GetEntries() == 0) { + // We are probably missing the ShowMember, let's + // just issue an error. + Error("InitializeOffsets", + "Could not find the real data member '%s' when constructing the branch '%s' [Likely missing ShowMember].", + dataName.Data(),GetName()); + } else { + // Something really bad happen. + Fatal("InitializeOffsets", + "Could not find the real data member '%s' when constructing the branch '%s' [Likely an internal error, please report to the developers].", + dataName.Data(),GetName()); + } + } localOffset = TStreamerInfo::kMissing; } } else { @@ -3021,6 +3148,10 @@ void TBranchElement::InitializeOffsets() // Compensate for the i/o routines adding our local offset later. if (subBranch->fObject == 0 && localOffset == TStreamerInfo::kMissing) { subBranch->SetOffset(TStreamerInfo::kMissing); + // We stil need to set fBranchOffset in the case of a missing + // element so that SetAddress is (as expected) not called + // recursively in this case. + fBranchOffset[subBranchIdx] = TStreamerInfo::kMissing; } else { if (isBaseSubBranch) { // The value of 'offset' for a base class does not include its @@ -3164,18 +3295,25 @@ void TBranchElement::Print(Option_t* option) const return; } if (strncmp(option,"debugInfo",strlen("debugInfo"))==0) { - Printf("Branch %s uses:\n",GetName()); + Printf("Branch %s uses:",GetName()); if (fID>=0) { ULong_t* elems = GetInfoImp()->GetElems(); ((TStreamerElement*) elems[fID])->ls(); for(UInt_t i=0; i< fIDs.size(); ++i) { ((TStreamerElement*) elems[fIDs[i]])->ls(); } + Printf(" with read actions:"); + if (fReadActionSequence) fReadActionSequence->Print(option); + Printf(" with write actions:"); + if (fFillActionSequence) fFillActionSequence->Print(option); } + TString suboption = "debugInfoSub"; + suboption += (option+strlen("debugInfo")); for (Int_t i = 0; i < nbranches; ++i) { TBranchElement* subbranch = (TBranchElement*)fBranches.At(i); - subbranch->Print("debugInfoSub"); + subbranch->Print(suboption); } + Printf(" "); return; } if (nbranches) { @@ -3520,7 +3658,12 @@ void TBranchElement::ReadLeavesMakeClass(TBuffer& b) // if (fObject) fBranchClass->Streamer(fObject,b); } else { - GetInfoImp()->ReadBuffer(b, (char**) &fObject, fID); + TStreamerInfo *info = GetInfoImp(); + if (!info) { + return; + } + // Since info is not null, fReadActionSequence is not null either. + b.ApplySequence(*fReadActionSequence, fObject); } if (fStreamerType == TVirtualStreamerInfo::kCounter) { fNdata = (Int_t) GetValue(0, 0); @@ -3574,9 +3717,9 @@ void TBranchElement::ReadLeavesCollection(TBuffer& b) TVirtualCollectionProxy::TPushPop helper(proxy, fObject); void* alternate = proxy->Allocate(fNdata, true); if(fSTLtype != TClassEdit::kVector && proxy->HasPointers() && fSplitLevel > TTree::kSplitCollectionOfPointers ) { - fPtrIterators->CreateIterators(alternate); + fPtrIterators->CreateIterators(alternate, proxy); } else { - fIterators->CreateIterators(alternate); + fIterators->CreateIterators(alternate, proxy); } Int_t nbranches = fBranches.GetEntriesFast(); @@ -4360,12 +4503,10 @@ void TBranchElement::SetAddress(void* addr) TVirtualCollectionProxy* newProxy = newType->GetCollectionProxy(); TVirtualCollectionProxy* oldProxy = GetCollectionProxy(); if (newProxy && (oldProxy->GetValueClass() == newProxy->GetValueClass()) && ((!oldProxy->GetValueClass() && (oldProxy->GetType() == newProxy->GetType())) || (oldProxy->GetValueClass() && (oldProxy->HasPointers() == newProxy->HasPointers())))) { - if (fSTLtype == TClassEdit::kNotSTL) { - fSTLtype = TMath::Abs(TClassEdit::IsSTLCont(newType->GetName())); - } delete fCollProxy; Int_t nbranches = GetListOfBranches()->GetEntries(); fCollProxy = newType->GetCollectionProxy()->Generate(); + fSTLtype = fCollProxy->GetCollectionType(); for (Int_t i = 0; i < nbranches; ++i) { TBranchElement* br = (TBranchElement*) GetListOfBranches()->UncheckedAt(i); br->fCollProxy = 0; @@ -4388,6 +4529,46 @@ void TBranchElement::SetAddress(void* addr) fIterators = new TVirtualCollectionIterators(fCollProxy); } } + else if (newProxy && (oldProxy->HasPointers() == newProxy->HasPointers()) && (oldProxy->GetValueClass()!=0) && (newProxy->GetValueClass()!=0)) { + // Let see if there is a rule to convert the content of the collection into each other. + if (newType->GetSchemaRules()->HasRuleWithSourceClass( oldProxy->GetCollectionClass()->GetName())) { + TClass *oldValueClass = oldProxy->GetValueClass(); + delete fCollProxy; + Int_t nbranches = GetListOfBranches()->GetEntries(); + fCollProxy = newType->GetCollectionProxy()->Generate(); + fSTLtype = fCollProxy->GetCollectionType(); + for (Int_t i = 0; i < nbranches; ++i) { + TBranchElement* br = (TBranchElement*) GetListOfBranches()->UncheckedAt(i); + br->fCollProxy = 0; + if (br->fBranchClass == oldValueClass) { + br->SetTargetClass(fCollProxy->GetValueClass()->GetName()); + } + if (br->fReadActionSequence) { + br->SetReadActionSequence(); + } + if (br->fFillActionSequence) { + br->SetFillActionSequence(); + } + } + SetReadActionSequence(); + SetFillActionSequence(); + SetReadLeavesPtr(); + SetFillLeavesPtr(); + delete fIterators; + delete fPtrIterators; + if(fSTLtype != TClassEdit::kVector && fCollProxy->HasPointers() && fSplitLevel > TTree::kSplitCollectionOfPointers ) { + fPtrIterators = new TVirtualCollectionPtrIterators(fCollProxy); + } else { + fIterators = new TVirtualCollectionIterators(fCollProxy); + } + } else { + Error("SetAddress","For %s, we can not convert %s into %s\n", + GetName(),oldProxy->GetCollectionClass()->GetName(),newType->GetName()); + fAddress = 0; + fObject = 0; + return; + } + } else if ((newType == TClonesArray::Class()) && (oldProxy->GetValueClass() && !oldProxy->HasPointers() && oldProxy->GetValueClass()->InheritsFrom(TObject::Class()))) { // The new collection and the old collection are not compatible, @@ -4434,7 +4615,9 @@ void TBranchElement::SetAddress(void* addr) fPtrIterators =0; } else { // FIXME: We must maintain fObject here as well. + Error("SetAddress","For %s can not convert %s into %s\n",GetName(),GetCurrentClass()->GetName(),newType->GetName()); fAddress = 0; + return; } } else { if (!fIterators && !fPtrIterators) { @@ -4799,7 +4982,7 @@ void TBranchElement::SetReadActionSequence() } else { original = GetCollectionProxy()->GetReadMemberWiseActions(fClassVersion); } - } else { + } else if (GetCollectionProxy()) { // Base class and embedded objects. transient = TStreamerInfoActions::TActionSequence::CreateReadMemberWiseActions(info,*GetCollectionProxy()); @@ -4886,7 +5069,7 @@ void TBranchElement::SetFillActionSequence() //} else { original = GetCollectionProxy()->GetWriteMemberWiseActions(); //} - } else { + } else if (GetCollectionProxy()) { // Base class and embedded objects. transient = TStreamerInfoActions::TActionSequence::CreateWriteMemberWiseActions(info,*GetCollectionProxy()); @@ -5269,6 +5452,9 @@ Int_t TBranchElement::Unroll(const char* name, TClass* clParent, TClass* cl, cha if (elem->TestBit(TStreamerElement::kRepeat)) { continue; } + if (elem->TestBit(TStreamerElement::kCache) && !elem->TestBit(TStreamerElement::kWrite)) { + continue; + } Int_t offset = elem->GetOffset(); // FIXME: An STL container as a base class gets TStreamerSTL as its class, so this test is not enough. // See InitializeOffsets() for the proper test. diff --git a/tree/tree/src/TBranchObject.cxx b/tree/tree/src/TBranchObject.cxx index 791c5a3ec37d5..50fe248990982 100644 --- a/tree/tree/src/TBranchObject.cxx +++ b/tree/tree/src/TBranchObject.cxx @@ -83,6 +83,8 @@ void TBranchObject::Init(TTree *tree, TBranch *parent, const char* name, const c if (!isptrptr) { fOldObject = (TObject*)addobj; addobj = &fOldObject; + } else { + fOldObject = 0; } char** apointer = (char**) addobj; @@ -119,7 +121,6 @@ void TBranchObject::Init(TTree *tree, TBranch *parent, const char* name, const c fBasketBytes = new Int_t[fMaxBaskets]; fBasketEntry = new Long64_t[fMaxBaskets]; fBasketSeek = new Long64_t[fMaxBaskets]; - fOldObject = 0; for (Int_t i = 0; i < fMaxBaskets; ++i) { fBasketBytes[i] = 0; @@ -137,7 +138,7 @@ void TBranchObject::Init(TTree *tree, TBranch *parent, const char* name, const c // in TLeafObject::ReadBasket, the object should be deleted // before calling Streamer. // It is foreseen to not set this bit in a future version. - SetAutoDelete(kTRUE); + if (isptrptr) SetAutoDelete(kTRUE); fDirectory = fTree->GetDirectory(); fFileName = ""; diff --git a/tree/tree/src/TBranchSTL.cxx b/tree/tree/src/TBranchSTL.cxx index c654af89d55b0..f2eb83def66ba 100644 --- a/tree/tree/src/TBranchSTL.cxx +++ b/tree/tree/src/TBranchSTL.cxx @@ -216,7 +216,7 @@ Int_t TBranchSTL::Fill() // Set up the container of indices //--------------------------------------------------------------------------- if( fInd.GetCapacity() < size ) - fInd.Reserve( size ); + fInd.ClearAndResize( size ); fInd.SetNumItems( size ); diff --git a/tree/tree/src/TBufferSQL.cxx b/tree/tree/src/TBufferSQL.cxx index 04a162e3b5189..6dc22da8c6ccb 100644 --- a/tree/tree/src/TBufferSQL.cxx +++ b/tree/tree/src/TBufferSQL.cxx @@ -716,6 +716,37 @@ void TBufferSQL::ReadFastArrayFloat16(Float_t *, Int_t , TStreamerElement * Fatal("ReadFastArrayFloat16(Float_t *, Int_t , TStreamerElement *)","Not implemented yet"); } +//______________________________________________________________________________ +void TBufferSQL::ReadFastArrayWithFactor(Float_t *, Int_t , Double_t /* factor */, Double_t /* minvalue */) +{ + // read array of Float16_t from buffer + + Fatal("ReadFastArrayWithFactor(Float_t *, Int_t, Double_t, Double_t)","Not implemented yet"); +} + +//______________________________________________________________________________ +void TBufferSQL::ReadFastArrayWithNbits(Float_t *, Int_t , Int_t /*nbits*/) +{ + // read array of Float16_t from buffer + + Fatal("ReadFastArrayWithNbits(Float_t *, Int_t , Int_t )","Not implemented yet"); +} + +//______________________________________________________________________________ +void TBufferSQL::ReadFastArrayWithFactor(Double_t *, Int_t , Double_t /* factor */, Double_t /* minvalue */) +{ + // read array of Double32_t from buffer + + Fatal("ReadFastArrayWithFactor(Double_t *, Int_t, Double_t, Double_t)","Not implemented yet"); +} +//______________________________________________________________________________ +void TBufferSQL::ReadFastArrayWithNbits(Double_t *, Int_t , Int_t /*nbits*/) +{ + // read array of Double32_t from buffer + + Fatal("ReadFastArrayWithNbits(Double_t *, Int_t , Int_t )","Not implemented yet"); +} + //________________________________________________________________________ void TBufferSQL::ReadFastArrayDouble32(Double_t *, Int_t , TStreamerElement *) { diff --git a/tree/tree/src/TChain.cxx b/tree/tree/src/TChain.cxx index 282df22ea49aa..e578154cf26e5 100644 --- a/tree/tree/src/TChain.cxx +++ b/tree/tree/src/TChain.cxx @@ -1,4 +1,4 @@ -// @(#)root/tree:$Id$ +// @(#)root/tree: // Author: Rene Brun 03/02/97 /************************************************************************* @@ -1118,7 +1118,7 @@ Double_t TChain::GetMaximum(const char* columname) { // -- Return maximum of column with name columname. - Double_t theMax = -FLT_MAX; + Double_t theMax = -DBL_MAX; for (Int_t file = 0; file < fNtrees; file++) { Long64_t first = fTreeOffset[file]; LoadTree(first); @@ -1135,7 +1135,7 @@ Double_t TChain::GetMinimum(const char* columname) { // -- Return minimum of column with name columname. - Double_t theMin = FLT_MAX; + Double_t theMin = DBL_MAX; for (Int_t file = 0; file < fNtrees; file++) { Long64_t first = fTreeOffset[file]; LoadTree(first); @@ -1406,28 +1406,33 @@ Long64_t TChain::LoadTree(Long64_t entry) // FIXME: The "unless" case here causes us to leak memory. if (fFile) { if (!fDirectory->GetList()->FindObject(this)) { - tpf = (TTreeCache*) fFile->GetCacheRead(fTree); - if (tpf) { - tpf->ResetCache(); - if (tpf->IsEnablePrefetching()){ - //wait for thread to finish current work - tpf->GetPrefetchObj()->GetMutexSynch()->Lock(); - tpf->GetPrefetchObj()->GetMutexSynch()->UnLock(); - } + if (fTree) { + // (fFile != 0 && fTree == 0) can happen when + // InvalidateCurrentTree is called (for example from + // AddFriend). Having fTree === 0 is necessary in that + // case because in some cases GetTree is used as a check + // to see if a TTree is already loaded. + // However, this prevent using the following to reuse + // the TTreeCache object. + tpf = (TTreeCache*) fFile->GetCacheRead(fTree); + if (tpf) { + tpf->ResetCache(); + } + + fFile->SetCacheRead(0, fTree); + // If the tree has clones, copy them into the chain + // clone list so we can change their branch addresses + // when necessary. + // + // This is to support the syntax: + // + // TTree* clone = chain->GetTree()->CloneTree(0); + // + // We need to call the invalidate exactly here, since + // we no longer need the value of fTree and it is + // about to be deleted. + InvalidateCurrentTree(); } - fFile->SetCacheRead(0, fTree); - // If the tree has clones, copy them into the chain - // clone list so we can change their branch addresses - // when necessary. - // - // This is to support the syntax: - // - // TTree* clone = chain->GetTree()->CloneTree(0); - // - // We need to call the invalidate exactly here, since - // we no longer need the value of fTree and it is - // about to be deleted. - if (fTree) InvalidateCurrentTree(); if (fCanDeleteRefs) { fFile->Close("R"); @@ -1509,7 +1514,6 @@ Long64_t TChain::LoadTree(Long64_t entry) // TTreeCache. delete tpf; tpf = 0; - this->SetCacheSize(fCacheSize); } } else { this->SetCacheSize(fCacheSize); @@ -2098,6 +2102,29 @@ void TChain::RecursiveRemove(TObject *obj) } } +//______________________________________________________________________________ +void TChain::RemoveFriend(TTree* oldFriend) +{ + // Remove a friend from the list of friends. + + // We already have been visited while recursively looking + // through the friends tree, let return + + if (!fFriends) { + return; + } + + TTree::RemoveFriend(oldFriend); + + if (fProofChain) + // This updates the proxy chain when we will really use PROOF + ResetBit(kProofUptodate); + + // We need to invalidate the loading of the current tree because its list + // of real friends is now obsolete. It is repairable only from LoadTree. + InvalidateCurrentTree(); +} + //______________________________________________________________________________ void TChain::Reset(Option_t*) { @@ -2168,16 +2195,16 @@ void TChain::SetAutoDelete(Bool_t autodelete) void TChain::SetCacheSize(Long64_t cacheSize) { - TTree::SetCacheSize(cacheSize); - TFile* file = GetCurrentFile(); - if (!file) { - return; - } - TFileCacheRead* pf = file->GetCacheRead(this); - if (pf) { - file->SetCacheRead(0, this); - file->SetCacheRead(pf, fTree); + // Set the cache size of the underlying TTree, + // See TTree::SetCacheSize. + + if (fTree) { + fTree->SetCacheSize(cacheSize); + } else { + // If we don't have a TTree yet, do not + // allocate the cache. } + fCacheSize = cacheSize; // Record requested size. } //______________________________________________________________________________ @@ -2258,6 +2285,9 @@ Int_t TChain::SetBranchAddress(const char *bname, void* add, TBranch** ptr) } } branch->SetAddress(add); + } else { + Error("SetBranchAddress", "unknown branch -> %s", bname); + return kMissingBranch; } } else { if (ptr) { diff --git a/tree/tree/src/TEntryList.cxx b/tree/tree/src/TEntryList.cxx index 0a9ed16fe8e09..0b6759e11fe5f 100644 --- a/tree/tree/src/TEntryList.cxx +++ b/tree/tree/src/TEntryList.cxx @@ -78,22 +78,22 @@ Begin_Html <pre> void loopChain() { TFile *fe = TFile::Open("myelist.root"); - TEntryList *myelist = (TEntryList*)fe->Get("myelist"); + TEntryList *myelist = (TEntryList*)fe->Get("myelist"); TChain *ch = new TChain("ntuple"); - ch->Add("hsimple.root"); - ch->Add("hsimple2.root"); - Long64_t listEntries = myelist->GetN(); - Long64_t chainEntries = ch->GetEntries(); + ch->Add("hsimple.root"); + ch->Add("hsimple2.root"); + Long64_t listEntries = myelist->GetN(); + Long64_t chainEntries = ch->GetEntries(); Int_t treenum = 0; - ch->SetEntryList(myelist); - - for (entry=start;entry<end;entry++) { - entryNumber = treechain->GetEntryNumber(entry); - if (entryNumber < 0) break; - localEntry = fTree->LoadTree(entryNumber); - if (localEntry < 0) break; - // then either call branch->GetEntry(localEntry); - // or entryNumber->GetEntry(entryNumber); + ch->SetEntryList(myelist); + + for (entry=start;entry < end;entry++) { + entryNumber = treechain->GetEntryNumber(entry); + if (entryNumber < 0) break; + localEntry = fTree->LoadTree(entryNumber); + if (localEntry < 0) break; + // then either call branch->GetEntry(localEntry); + // or entryNumber->GetEntry(entryNumber); // In the later case the LoadTree is then somewhat redudant. } } @@ -103,7 +103,7 @@ When using the TEntryList interface directly, you can get the 'tree number' and the current tree (i.e. value similar to the return value of LoadTree) from calling TEntryList::GetEntryAndTree: <pre> - Long64_t treeEntry = myelist->GetEntryAndTree(el,treenum); + Long64_t treeEntry = myelist->GetEntryAndTree(el,treenum); </pre> to obtain the entry number within the chain you need to add to it the value of @@ -111,12 +111,12 @@ of such that the loop in the previous example can also be written as: <pre>for (Long64_t el = 0; el < listEntries; el++) { - Long64_t treeEntry = myelist->GetEntryAndTree(el,treenum); - Long64_t chainEntry = treeEntry+ch->GetTreeOffset()[treenum]; + Long64_t treeEntry = myelist->GetEntryAndTree(el,treenum); + Long64_t chainEntry = treeEntry+ch->GetTreeOffset()[treenum]; printf("el=%lld, treeEntry=%lld, chainEntry=%lld, treenum=%d\n", el, treeEntry, chainEntry, treenum); - ch->LoadTree(chainEntry); // this also returns treeEntry - needed_branch->GetEntry(treeEntry); + ch->LoadTree(chainEntry); // this also returns treeEntry + needed_branch->GetEntry(treeEntry); } </pre> @@ -220,7 +220,7 @@ TEntryList::TEntryList(const char *name, const char *title, const TTree *tree):T fN = 0; fNBlocks = 0; fTreeNumber = -1; - SetTree(tree); + TEntryList::SetTree(tree); fReapply = kFALSE; fDirectory = gDirectory; @@ -1197,6 +1197,8 @@ void TEntryList::SetTree(const TTree *tree) //where the filename is taken "as is". if (!tree) return; + if (!tree->GetTree()) return; + TString treename = tree->GetTree()->GetName(); TString filename; if (tree->GetTree()->GetCurrentFile()){ diff --git a/tree/tree/src/TLeafB.cxx b/tree/tree/src/TLeafB.cxx index 8a93b6b18a79b..d15ffb5bfc491 100644 --- a/tree/tree/src/TLeafB.cxx +++ b/tree/tree/src/TLeafB.cxx @@ -166,9 +166,22 @@ void TLeafB::ReadBasketExport(TBuffer& b, TClonesArray* list, Int_t n) //______________________________________________________________________________ void TLeafB::ReadValue(istream &s, Char_t /*delim = ' '*/) { - // -- Read a string from istream s and store it into the branch buffer. - char* value = (char*) GetValuePointer(); - s >> value; + // -- Read a 8 bit integer from istream s and store it into the branch buffer. + if (fIsUnsigned) { + UChar_t *uvalue = (UChar_t*)GetValuePointer(); + for (Int_t i=0;i<fLen;i++) { + UShort_t tmp; + s >> tmp; + uvalue[i] = tmp; + } + } else { + Char_t *value = (Char_t*)GetValuePointer(); + for (Int_t i=0;i<fLen;i++) { + Short_t tmp; + s >> tmp; + value[i] = tmp; + } + } } //______________________________________________________________________________ diff --git a/tree/tree/src/TLeafL.cxx b/tree/tree/src/TLeafL.cxx index 4bbce00d2248e..dba80218550e0 100644 --- a/tree/tree/src/TLeafL.cxx +++ b/tree/tree/src/TLeafL.cxx @@ -118,6 +118,18 @@ Double_t TLeafL::GetValue(Int_t i) const } +//______________________________________________________________________________ +LongDouble_t TLeafL::GetValueLongDouble(Int_t i) const +{ +// Returns current value of leaf +// if leaf is a simple type, i must be set to 0 +// if leaf is an array, i is the array element number to be returned + + if (fIsUnsigned) return (LongDouble_t)((ULong64_t)fValue[i]); + return fValue[i]; +} + + //______________________________________________________________________________ void TLeafL::Import(TClonesArray *list, Int_t n) diff --git a/tree/tree/src/TSelector.cxx b/tree/tree/src/TSelector.cxx index 14a0ba6852e56..440ea17e1e245 100644 --- a/tree/tree/src/TSelector.cxx +++ b/tree/tree/src/TSelector.cxx @@ -194,12 +194,16 @@ TSelector *TSelector::GetSelector(const char *filename) ::Error("TSelector::GetSelector", "class %s does not exist or does not derive from TSelector", filename); } + gCint->ClassInfo_Delete(cl); return 0; } // we can now create an instance of the class TSelector *selector = (TSelector*)gCint->ClassInfo_New(cl); - if (!selector || isCompiled) return selector; + if (!selector || isCompiled) { + gCint->ClassInfo_Delete(cl); + return selector; + } //interpreted selector: cannot be used as such //create a fake selector diff --git a/tree/tree/src/TSelectorList.cxx b/tree/tree/src/TSelectorList.cxx index f2d9dd1069603..9c590ee1c29e2 100644 --- a/tree/tree/src/TSelectorList.cxx +++ b/tree/tree/src/TSelectorList.cxx @@ -81,7 +81,7 @@ void TSelectorList::AddFirst(TObject *obj) UnsetDirectory(obj); if (CheckDuplicateName(obj)) - TList::AddFirst(obj); + THashList::AddFirst(obj); } //______________________________________________________________________________ @@ -91,7 +91,7 @@ void TSelectorList::AddFirst(TObject *obj, Option_t *opt) UnsetDirectory(obj); if (CheckDuplicateName(obj)) - TList::AddFirst(obj, opt); + THashList::AddFirst(obj, opt); } //______________________________________________________________________________ @@ -101,7 +101,7 @@ void TSelectorList::AddLast(TObject *obj) UnsetDirectory(obj); if (CheckDuplicateName(obj)) - TList::AddLast(obj); + THashList::AddLast(obj); } //______________________________________________________________________________ @@ -111,7 +111,7 @@ void TSelectorList::AddLast(TObject *obj, Option_t *opt) UnsetDirectory(obj); if (CheckDuplicateName(obj)) - TList::AddLast(obj, opt); + THashList::AddLast(obj, opt); } //______________________________________________________________________________ @@ -121,7 +121,7 @@ void TSelectorList::AddAt(TObject *obj, Int_t idx) UnsetDirectory(obj); if (CheckDuplicateName(obj)) - TList::AddAt(obj, idx); + THashList::AddAt(obj, idx); } //______________________________________________________________________________ @@ -131,7 +131,7 @@ void TSelectorList::AddAfter(const TObject *after, TObject *obj) UnsetDirectory(obj); if (CheckDuplicateName(obj)) - TList::AddAfter(after, obj); + THashList::AddAfter(after, obj); } //______________________________________________________________________________ @@ -141,7 +141,7 @@ void TSelectorList::AddAfter(TObjLink *after, TObject *obj) UnsetDirectory(obj); if (CheckDuplicateName(obj)) - TList::AddAfter(after, obj); + THashList::AddAfter(after, obj); } //______________________________________________________________________________ @@ -151,7 +151,7 @@ void TSelectorList::AddBefore(const TObject *before, TObject *obj) UnsetDirectory(obj); if (CheckDuplicateName(obj)) - TList::AddBefore(before, obj); + THashList::AddBefore(before, obj); } //______________________________________________________________________________ @@ -161,5 +161,5 @@ void TSelectorList::AddBefore(TObjLink *before, TObject *obj) UnsetDirectory(obj); if (CheckDuplicateName(obj)) - TList::AddBefore(before, obj); + THashList::AddBefore(before, obj); } diff --git a/tree/tree/src/TTree.cxx b/tree/tree/src/TTree.cxx index 548fd85d9430a..9783cda01b4be 100644 --- a/tree/tree/src/TTree.cxx +++ b/tree/tree/src/TTree.cxx @@ -106,7 +106,11 @@ // Or // MyDataClass* p_object = new MyDataClass; // tree->Branch(branchname, &p_object); -// +// Whether the pointer is set to zero or not, the ownership of the object +// is not taken over by the TTree. I.e. eventhough an object will be allocated +// by TTree::Branch if the pointer p_object is zero, the object will <b>not</b> +// be deleted when the TTree is deleted. +// // ==> Case C // ====== // MyClass object; @@ -787,6 +791,7 @@ TTree::~TTree() TFile *file = fDirectory->GetFile(); if (file) { TFileCacheRead *pf = file->GetCacheRead(this); + if (pf) pf->WaitFinishPrefetch(); file->SetCacheRead(0,this); delete pf; } @@ -910,10 +915,10 @@ void TTree::AddBranchToCache(TBranch *b, Bool_t subbranches) //______________________________________________________________________________ void TTree::DropBranchFromCache(const char*bname, Bool_t subbranches) { - // Add branch with name bname to the Tree cache. - // If bname="*" all branches are added to the cache. + // Remove the branch with name 'bname' from the Tree cache. + // If bname="*" all branches are removed from the cache. // if subbranches is true all the branches of the subbranches are - // also put to the cache. + // also removed from the cache. TFile *f = GetCurrentFile(); if (!f) return; @@ -924,9 +929,9 @@ void TTree::DropBranchFromCache(const char*bname, Bool_t subbranches) //______________________________________________________________________________ void TTree::DropBranchFromCache(TBranch *b, Bool_t subbranches) { - // Add branch b to the Tree cache. + // Remove the branch b from the Tree cache. // if subbranches is true all the branches of the subbranches are - // also put to the cache. + // also removed from the cache. TFile *f = GetCurrentFile(); if (!f) return; @@ -1728,6 +1733,17 @@ TBranch* TTree::BranchOld(const char* name, const char* classname, void* addobj, Error("BranchOld", "Cannot find class: '%s'", classname); return 0; } + if (!cl->InheritsFrom(TObject::Class())) { + if (fgBranchStyle == 0) { + Fatal("BranchOld", "The requested class ('%s') does not inherit from TObject.\n" + "\tfgBranchStyle is set to zero requesting by default to use BranchOld.\n" + "\tIf this is intentional use Bronch instead of Branch or BranchOld.", classname); + } else { + Fatal("BranchOld", "The requested class ('%s') does not inherit from TObject.\n" + "\tYou can not use BranchOld to store objects of this type.",classname); + } + return 0; + } TBranch* branch = new TBranchObject(this, name, classname, addobj, bufsize, splitlevel); fBranches.Add(branch); if (!splitlevel) { @@ -1979,23 +1995,36 @@ TBranch* TTree::Bronch(const char* name, const char* classname, void* addr, Int_ // // WARNING about this new function // =============================== - // This function is designed to replace the function TTree::Branch above. - // This function is far more powerful than the Branch function. - // It supports the full C++, including STL and has the same behaviour - // in split or non-split mode. classname does not have to derive from TObject. - // The function is based on the new TStreamerInfo. + // + // This function is designed to replace the internal + // implementation of the old TTree::Branch (whose implementation + // has been moved to BranchOld). + // + // NOTE: The 'Bronch' method supports only one possible calls + // signature (where the object type has to be specified + // explicitly and the address must be the address of a pointer). + // For more flexibility use 'Branch'. Use Bronch only in (rare) + // cases (likely to be legacy cases) where both the new and old + // implementation of Branch needs to be used at the same time. + // + // This function is far more powerful than the old Branch + // function. It supports the full C++, including STL and has + // the same behaviour in split or non-split mode. classname does + // not have to derive from TObject. The function is based on + // the new TStreamerInfo. // // Build a TBranchElement for an object of class classname. // - // addr is the address of a pointer to an object of class classname. - // The class dictionary must be available (ClassDef in class header). + // addr is the address of a pointer to an object of class + // classname. The class dictionary must be available (ClassDef + // in class header). // // Note: See the comments in TBranchElement::SetAddress() for a more // detailed discussion of the meaning of the addr parameter. // - // This option requires access to the library where the corresponding class - // is defined. Accessing one single data member in the object implies - // reading the full object. + // This option requires access to the library where the + // corresponding class is defined. Accessing one single data + // member in the object implies reading the full object. // // By default the branch buffers are stored in the same file as the Tree. // use TBranch::SetFile to specify a different file @@ -2082,7 +2111,7 @@ TBranch* TTree::BronchExec(const char* name, const char* classname, void* addr, Warning("Bronch", "Using split mode on a class: %s with a custom Streamer", clones->GetClass()->GetName()); } else { if (rootflag & 1) clones->BypassStreamer(kFALSE); - TBranchObject *branch = new TBranchObject(this,name,classname,addr,bufsize,0,isptrptr); + TBranchObject *branch = new TBranchObject(this,name,classname,addr,bufsize,0,/*compress=*/ -1,isptrptr); fBranches.Add(branch); return branch; } @@ -2141,7 +2170,7 @@ TBranch* TTree::BronchExec(const char* name, const char* classname, void* addr, } if (splitlevel < 0 || ((splitlevel == 0) && hasCustomStreamer && cl->InheritsFrom(TObject::Class()))) { - TBranchObject* branch = new TBranchObject(this, name, classname, addr, bufsize, 0, isptrptr); + TBranchObject* branch = new TBranchObject(this, name, classname, addr, bufsize, 0, /*compress=*/ -1, isptrptr); fBranches.Add(branch); return branch; } @@ -2241,6 +2270,9 @@ TBranch* TTree::BronchExec(const char* name, const char* classname, void* addr, if (element->TestBit(TStreamerElement::kRepeat)) { continue; } + if (element->TestBit(TStreamerElement::kCache) && !element->TestBit(TStreamerElement::kWrite)) { + continue; + } char* pointer = (char*) (objptr + element->GetOffset()); // FIXME: This is not good enough, an STL container can be // a base, and the test will fail. @@ -2572,6 +2604,31 @@ Int_t TTree::CheckBranchAddressType(TBranch* branch, TClass* ptrClass, EDataType // Something went wrong, the warning message has already be issued. return kInternalError; } + if (expectedClass && datatype == kOther_t && ptrClass == 0) { + if (branch->InheritsFrom( TBranchElement::Class() )) { + TBranchElement* bEl = (TBranchElement*)branch; + bEl->SetTargetClass( expectedClass->GetName() ); + } + if (expectedClass && expectedClass->GetCollectionProxy() && dynamic_cast<TEmulatedCollectionProxy*>(expectedClass->GetCollectionProxy())) { + Error("SetBranchAddress", "Unable to determine the type given for the address for \"%s\". " + "The class expected (%s) refers to an stl collection and do not have a compiled CollectionProxy. " + "Please generate the dictionary for this class (%s)", + branch->GetName(), expectedClass->GetName(), expectedClass->GetName()); + return kMissingCompiledCollectionProxy; + } + if (!expectedClass->IsLoaded()) { + // The originally expected class does not have a dictionary, it is then plausible that the pointer being passed is the right type + // (we really don't know). So let's express that. + Error("SetBranchAddress", "Unable to determine the type given for the address for \"%s\". " + "The class expected (%s) does not have a dictionary and needs to be emulated for I/O purposes but is being passed a compiled object." + "Please generate the dictionary for this class (%s)", + branch->GetName(), expectedClass->GetName(), expectedClass->GetName()); + } else { + Error("SetBranchAddress", "Unable to determine the type given for the address for \"%s\". " + "This is probably due to a missing dictionary, the original data class for this branch is %s.", branch->GetName(), expectedClass->GetName()); + } + return kClassMismatch; + } if (expectedClass && ptrClass && (branch->GetMother() == branch)) { // Top Level branch if (!isptr) { @@ -2601,10 +2658,20 @@ Int_t TTree::CheckBranchAddressType(TBranch* branch, TClass* ptrClass, EDataType ptrClass->GetSchemaRules()->HasRuleWithSourceClass( expectedClass->GetName() ) ) { TBranchElement* bEl = (TBranchElement*)branch; + + if ( ptrClass->GetCollectionProxy() && expectedClass->GetCollectionProxy() ) { + if (gDebug > 7) + Info("SetBranchAddress", "Matching STL colleciton (at least according to the SchemaRuleSet when " + "reading a %s into a %s",expectedClass->GetName(),ptrClass->GetName()); - if( !ptrClass->GetConversionStreamerInfo( expectedClass, bEl->GetClassVersion() ) && + bEl->SetTargetClass( ptrClass->GetName() ); + return kMatchConversion; + + } else if ( !ptrClass->GetConversionStreamerInfo( expectedClass, bEl->GetClassVersion() ) && !ptrClass->FindConversionStreamerInfo( expectedClass, bEl->GetCheckSum() ) ) { Error("SetBranchAddress", "The pointer type given \"%s\" does not correspond to the type needed \"%s\" by the branch: %s", ptrClass->GetName(), bEl->GetClassName(), branch->GetName()); + + bEl->SetTargetClass( expectedClass->GetName() ); return kClassMismatch; } else { @@ -2636,6 +2703,10 @@ Int_t TTree::CheckBranchAddressType(TBranch* branch, TClass* ptrClass, EDataType } Error("SetBranchAddress", "The pointer type given (%s) does not correspond to the class needed (%s) by the branch: %s", ptrClass->GetName(), expectedClass->GetName(), branch->GetName()); + if (branch->InheritsFrom( TBranchElement::Class() )) { + TBranchElement* bEl = (TBranchElement*)branch; + bEl->SetTargetClass( expectedClass->GetName() ); + } return kClassMismatch; } else if ((expectedType != kOther_t) && (datatype != kOther_t) && (expectedType != kNoType_t) && (datatype != kNoType_t) && (expectedType != datatype)) { @@ -2645,13 +2716,63 @@ Int_t TTree::CheckBranchAddressType(TBranch* branch, TClass* ptrClass, EDataType TDataType::GetTypeName(datatype), datatype, TDataType::GetTypeName(expectedType), expectedType, branch->GetName()); return kMismatch; } + } else if ((expectedClass && (datatype != kOther_t && datatype != kNoType_t && datatype != kInt_t)) || + (ptrClass && (expectedType != kOther_t && expectedType != kNoType_t && datatype != kInt_t)) ) { + // Sometime a null pointer can look an int, avoid complaining in that case. + if (expectedClass) { + Error("SetBranchAddress", "The pointer type given \"%s\" (%d) does not correspond to the type needed \"%s\" by the branch: %s", + TDataType::GetTypeName(datatype), datatype, expectedClass->GetName(), branch->GetName()); + if (branch->InheritsFrom( TBranchElement::Class() )) { + TBranchElement* bEl = (TBranchElement*)branch; + bEl->SetTargetClass( expectedClass->GetName() ); + } + } else { + // In this case, it is okay if the first data member is of the right type (to support the case where we are being passed + // a struct). + bool good = false; + if (ptrClass->IsLoaded()) { + TIter next(ptrClass->GetListOfRealData()); + TRealData *rdm; + while ((rdm = (TRealData*)next())) { + if (rdm->GetThisOffset() == 0) { + break; + } + } + } else { + TIter next(ptrClass->GetListOfDataMembers()); + TDataMember *dm; + while ((dm = (TDataMember*)next())) { + if (dm->GetOffset() == 0) { + TDataType *dmtype = dm->GetDataType(); + if (dmtype) { + EDataType etype = (EDataType)dmtype->GetType(); + good = (etype == expectedType); + } + break; + } + } + } + if (!good) { + Error("SetBranchAddress", "The pointer type given \"%s\" does not correspond to the type needed \"%s\" (%d) by the branch: %s", + ptrClass->GetName(), TDataType::GetTypeName(expectedType), expectedType, branch->GetName()); + } + } + return kMismatch; } if (expectedClass && expectedClass->GetCollectionProxy() && dynamic_cast<TEmulatedCollectionProxy*>(expectedClass->GetCollectionProxy())) { Error("SetBranchAddress", "The class requested (%s) for the branch \"%s\" refer to an stl collection and do not have a compiled CollectionProxy. " "Please generate the dictionary for this class (%s)", expectedClass->GetName(), branch->GetName(), expectedClass->GetName()); + if (branch->InheritsFrom( TBranchElement::Class() )) { + TBranchElement* bEl = (TBranchElement*)branch; + bEl->SetTargetClass( expectedClass->GetName() ); + } return kMissingCompiledCollectionProxy; } + if (expectedClass && branch->InheritsFrom( TBranchElement::Class() )) { + TBranchElement* bEl = (TBranchElement*)branch; + bEl->SetTargetClass( expectedClass->GetName() ); + } return kMatch; } @@ -3749,7 +3870,10 @@ Long64_t TTree::Draw(const char* varexp, const char* selection, Option_t* option // Making a Profile histogram // ========================== // In case of a 2-Dim expression, one can generate a TProfile histogram - // instead of a TH2F histogram by specyfying option=prof or option=profs. + // instead of a TH2F histogram by specyfying option=prof or option=profs + // or option=profi or option=profg ; the trailing letter select the way + // the bin error are computed, See TProfile2D::SetErrorOption for + // details on the differences. // The option=prof is automatically selected in case of y:x>>pf // where pf is an existing TProfile histogram. // @@ -3757,6 +3881,9 @@ Long64_t TTree::Draw(const char* varexp, const char* selection, Option_t* option // ========================== // In case of a 3-Dim expression, one can generate a TProfile2D histogram // instead of a TH3F histogram by specifying option=prof or option=profs. + // or option=profi or option=profg ; the trailing letter select the way + // the bin error are computed, See TProfile2D::SetErrorOption for + // details on the differences. // The option=prof is automatically selected in case of z:y:x>>pf // where pf is an existing TProfile2D histogram. // @@ -4093,7 +4220,7 @@ Int_t TTree::Fill() if (fAutoSave!=0 && fEntries >= fAutoSave) AutoSave(); // FlushBaskets not called in AutoSave if (gDebug > 0) Info("TTree::Fill","First AutoFlush. fAutoFlush = %lld, fAutoSave = %lld\n", fAutoFlush, fAutoSave); } - } else if (fNClusterRange && fAutoFlush && (fEntries-fClusterRangeEnd[fNClusterRange-1]) % fAutoFlush) { + } else if (fNClusterRange && fAutoFlush && ( (fEntries-fClusterRangeEnd[fNClusterRange-1]) % fAutoFlush == 0) ) { if (fAutoSave != 0 && fEntries%fAutoSave == 0) { //We are at an AutoSave point. AutoSave flushes baskets and saves the Tree header AutoSave("flushbaskets"); @@ -4772,6 +4899,10 @@ Int_t TTree::GetEntry(Long64_t entry, Int_t getall) // additional advantage that functions like TTree::Draw (internally calling // TTree::GetEntry) will be functional even when the classes in the file are // not available. + // + // Note: See the comments in TBranchElement::SetAddress() for the + // object ownership policy of the underlying (user) data. + // We already have been visited while recursively looking // through the friends tree, let return @@ -5189,7 +5320,7 @@ Double_t TTree::GetMaximum(const char* columname) return 0; } TBranch* branch = leaf->GetBranch(); - Double_t cmax = -FLT_MAX; + Double_t cmax = -DBL_MAX; for (Long64_t i = 0; i < fEntries; ++i) { Long64_t entryNumber = this->GetEntryNumber(i); if (entryNumber < 0) break; @@ -5224,7 +5355,7 @@ Double_t TTree::GetMinimum(const char* columname) return 0; } TBranch* branch = leaf->GetBranch(); - Double_t cmin = FLT_MAX; + Double_t cmin = DBL_MAX; for (Long64_t i = 0; i < fEntries; ++i) { Long64_t entryNumber = this->GetEntryNumber(i); if (entryNumber < 0) break; @@ -5412,7 +5543,9 @@ Long64_t TTree::LoadTree(Long64_t entry) continue; } TTree* friendTree = fe->GetTree(); - if (friendTree->IsA() == TTree::Class()) { + if (friendTree == 0) { + // Somehow we failed to retrieve the friend TTree. + } else if (friendTree->IsA() == TTree::Class()) { // Friend is actually a tree. if (friendTree->LoadTreeFriend(entry, this) >= 0) { friendHasEntry = kTRUE; @@ -5824,6 +5957,8 @@ Long64_t TTree::Merge(TCollection* li, TFileMergeInfo *info) newtree->Write(); delete newtree; } + // Make sure things are really written out to disk before attempting any reading. + info->fOutputDirectory->GetFile()->Flush(); info->fOutputDirectory->ReadTObject(this,this->GetName()); } if (!li) return 0; @@ -5915,7 +6050,13 @@ void TTree::OptimizeBaskets(ULong64_t maxMemory, Float_t minComp, Option_t *opti TBranch *branch = leaf->GetBranch(); Double_t totBytes = (Double_t)branch->GetTotBytes(); Double_t idealFactor = totBytes/aveSize; - UInt_t sizeOfOneEntry = 1+(UInt_t)(totBytes / (Double_t)branch->GetEntries()); + UInt_t sizeOfOneEntry; + if (branch->GetEntries() == 0) { + // There is no data, so let's make a guess ... + sizeOfOneEntry = aveSize; + } else { + sizeOfOneEntry = 1+(UInt_t)(totBytes / (Double_t)branch->GetEntries()); + } Int_t oldBsize = branch->GetBasketSize(); oldMemsize += oldBsize; oldBaskets += 1+Int_t(totBytes/oldBsize); @@ -6368,13 +6509,22 @@ Long64_t TTree::ReadStream(istream& inputStream, const char *branchDescriptor, c if (branchDescriptor) nch = strlen(branchDescriptor); // branch Descriptor is null, read its definition from the first line in the file if (!nch) { - in.getline(bd, 100000, newline); - if (!in.good()) { - delete [] bdname; - delete [] bd; - Error("ReadStream","Error reading stream"); - return 0; - } + do { + in.getline(bd, 100000, newline); + if (!in.good()) { + delete [] bdname; + delete [] bd; + Error("ReadStream","Error reading stream"); + return 0; + } + char *cursor = bd; + while( isspace(*cursor) && *cursor != '\n' && *cursor != '\0') { + ++cursor; + } + if (*cursor != '#' && *cursor != '\n' && *cursor != '\0') { + break; + } + } while (true); ++nlines; nch = strlen(bd); } else { @@ -6387,7 +6537,13 @@ Long64_t TTree::ReadStream(istream& inputStream, const char *branchDescriptor, c char *bdcur = bd; TString desc="", olddesc="F"; char bdelim = ':'; - if(delimiter != ' ') bdelim = delimiter; + if(delimiter != ' ') { + bdelim = delimiter; + if (strchr(bdcur,bdelim)==0 && strchr(bdcur,':') != 0) { + // revert to the default + bdelim = ':'; + } + } while (bdcur) { char *colon = strchr(bdcur,bdelim); if (colon) *colon = 0; @@ -6687,15 +6843,16 @@ void TTree::Reset(Option_t* option) { // Reset baskets, buffers and entries count in all branches and leaves. - fNotify = 0; - fEntries = 0; + fNotify = 0; + fEntries = 0; fNClusterRange = 0; - fTotBytes = 0; - fZipBytes = 0; - fSavedBytes = 0; - fTotalBuffers = 0; - fChainOffset = 0; - fReadEntry = -1; + fTotBytes = 0; + fZipBytes = 0; + fFlushedBytes = 0; + fSavedBytes = 0; + fTotalBuffers = 0; + fChainOffset = 0; + fReadEntry = -1; delete fTreeIndex; fTreeIndex = 0; @@ -6721,6 +6878,7 @@ void TTree::ResetAfterMerge(TFileMergeInfo *info) fTotBytes = 0; fZipBytes = 0; fSavedBytes = 0; + fFlushedBytes = 0; fTotalBuffers = 0; fChainOffset = 0; fReadEntry = -1; @@ -6835,7 +6993,7 @@ Bool_t TTree::SetAlias(const char* aliasName, const char* aliasFormula) } //_______________________________________________________________________ -void TTree::SetAutoFlush(Long64_t autof) +void TTree::SetAutoFlush(Long64_t autof /* = -30000000 */ ) { // This function may be called at the start of a program to change // the default value for fAutoFlush. @@ -6992,11 +7150,12 @@ Int_t TTree::SetBranchAddress(const char* bname, void* addr, TBranch** ptr) // See TTree::CheckBranchAddressType for the semantic of the return value. // // Note: See the comments in TBranchElement::SetAddress() for the - // meaning of the addr parameter. + // meaning of the addr parameter and the object ownership policy. // TBranch* branch = GetBranch(bname); if (!branch) { + if (ptr) *ptr = 0; Error("SetBranchAddress", "unknown branch -> %s", bname); return kMissingBranch; } @@ -7010,7 +7169,7 @@ Int_t TTree::SetBranchAddress(const char* bname, void* addr, TClass* ptrClass, E // See TTree::CheckBranchAddressType for the semantic of the return value. // // Note: See the comments in TBranchElement::SetAddress() for the - // meaning of the addr parameter. + // meaning of the addr parameter and the object ownership policy. // return SetBranchAddress(bname, addr, 0, ptrClass, datatype, isptr); @@ -7023,20 +7182,24 @@ Int_t TTree::SetBranchAddress(const char* bname, void* addr, TBranch** ptr, TCla // See TTree::CheckBranchAddressType for the semantic of the return value. // // Note: See the comments in TBranchElement::SetAddress() for the - // meaning of the addr parameter. + // meaning of the addr parameter and the object ownership policy. // TBranch* branch = GetBranch(bname); if (!branch) { + if (ptr) *ptr = 0; Error("SetBranchAddress", "unknown branch -> %s", bname); return kMissingBranch; } - if (ptr) { - *ptr = branch; - } Int_t res = CheckBranchAddressType(branch, ptrClass, datatype, isptr); - SetBranchAddressImp(branch,addr,ptr); + // This will set the value of *ptr to branch. + if (res >= 0) { + // The check succeeded. + SetBranchAddressImp(branch,addr,ptr); + } else { + if (ptr) *ptr = 0; + } return res; } @@ -7047,7 +7210,7 @@ Int_t TTree::SetBranchAddressImp(TBranch *branch, void* addr, TBranch** ptr) // See TTree::CheckBranchAddressType for the semantic of the return value. // // Note: See the comments in TBranchElement::SetAddress() for the - // meaning of the addr parameter. + // meaning of the addr parameter and the object ownership policy. // if (ptr) { @@ -7254,11 +7417,6 @@ void TTree::SetCacheSize(Long64_t cacheSize) // if cachesize = 0 the existing cache (if any) is deleted. // if cachesize = -1 (default) it is set to the AutoFlush value when writing // the Tree (default is 30 MBytes). - // WARNING: Currently only ONE TTree object can be 'cached' per TFile object. - // This call disable the cache for the other TTree objects read from the same - // TFile object as this TTree (The SetCacheSize called __last__ wins). - // To cache multiple TTree objects in the same ROOT file, you must create - // one TFile object per TTree object. if (cacheSize < 0) { if (fAutoFlush < 0) cacheSize = -fAutoFlush; @@ -7277,6 +7435,7 @@ void TTree::SetCacheSize(Long64_t cacheSize) if (cacheSize == fCacheSize) { return; } + pf->WaitFinishPrefetch(); file->SetCacheRead(0, this); delete pf; pf = 0; @@ -7418,6 +7577,21 @@ void TTree::SetDirectory(TDirectory* dir) } if (fDirectory) { fDirectory->Remove(this); + + // Delete or move the file cache if it points to this Tree + TFile *file = fDirectory->GetFile(); + if (file) { + TTreeCache *pf = dynamic_cast<TTreeCache*>(file->GetCacheRead(this)); + if (pf && pf->GetTree() == this) { + file->SetCacheRead(0,this); + TFile *newfile = dir ? dir->GetFile() : 0; + if (newfile) { + newfile->SetCacheRead(pf,this); + } else { + delete pf; + } + } + } } fDirectory = dir; if (fDirectory) { diff --git a/tree/tree/src/TTreeCache.cxx b/tree/tree/src/TTreeCache.cxx index 5acc2e2ad9911..dd38e6059c578 100644 --- a/tree/tree/src/TTreeCache.cxx +++ b/tree/tree/src/TTreeCache.cxx @@ -265,7 +265,9 @@ TTreeCache::TTreeCache() : TFileCacheRead(), fFillTimes(0), fFirstTime(kTRUE), fFirstEntry(-1), - fReadDirectionSet(kFALSE) + fReadDirectionSet(kFALSE), + fEnabled(kTRUE), + fPrefillType(TTreeCache::kNoPrefill) { // Default Constructor. } @@ -291,7 +293,9 @@ TTreeCache::TTreeCache(TTree *tree, Int_t buffersize) : TFileCacheRead(tree->Get fFillTimes(0), fFirstTime(kTRUE), fFirstEntry(-1), - fReadDirectionSet(kFALSE) + fReadDirectionSet(kFALSE), + fEnabled(kTRUE), + fPrefillType(TTreeCache::kNoPrefill) { // Constructor. @@ -324,6 +328,12 @@ void TTreeCache::AddBranch(TBranch *b, Bool_t subbranches /*= kFALSE*/) // Reject branch that are not from the cached tree. if (!b || fTree->GetTree() != b->GetTree()) return; + // Is this the first addition of a branch (and we are learning and we are in + // the expected TTree), then prefill the cache. (We expect that in future + // release the Prefill-ing will be the default so we test for that inside the + // LearnPrefill call). + if (fNbranches == 0 && b->GetReadEntry() == fEntryMin) LearnPrefill(); + //Is branch already in the cache? Bool_t isNew = kTRUE; for (int i=0;i<fNbranches;i++) { @@ -357,7 +367,7 @@ void TTreeCache::AddBranch(const char *bname, Bool_t subbranches /*= kFALSE*/) // this is to be used by user (thats why we pass the name of the branch). // It works in exactly the same way as TTree::SetBranchStatus so you // probably want to look over ther for details about the use of bname - // with regular expresions. + // with regular expressions. // The branches are taken with respect to the Owner of this TTreeCache // (i.e. the original Tree) // NB: if bname="*" all branches are put in the cache and the learning phase stopped @@ -439,8 +449,8 @@ void TTreeCache::AddBranch(const char *bname, Bool_t subbranches /*= kFALSE*/) //_____________________________________________________________________________ void TTreeCache::DropBranch(TBranch *b, Bool_t subbranches /*= kFALSE*/) { - //Remove a branch to the list of branches to be stored in the cache - //this function is called by TBranch::GetBasket + // Remove a branch to the list of branches to be stored in the cache + // this function is called by TBranch::GetBasket. if (!fIsLearning) return; @@ -584,12 +594,13 @@ Bool_t TTreeCache::FillBuffer() } } - if (fReverseRead){ - //reverse reading with prefetching - if (fEntryCurrent >0 && entry < fEntryNext){ - //we can prefetch the next buffer - if (entry > fEntryCurrent) + if (fReverseRead) { + // Reverse reading with prefetching + if (fEntryCurrent >0 && entry < fEntryNext) { + // We can prefetch the next buffer + if (entry >= fEntryCurrent) { entry = fEntryCurrent - tree->GetAutoFlush() * fFillTimes; + } if (entry < 0) entry = 0; } else if (fEntryCurrent >= 0) @@ -602,11 +613,12 @@ Bool_t TTreeCache::FillBuffer() else { //normal reading with prefetching if (fEnablePrefetching){ - if (entry < 0 && fEntryNext > 0) + if (entry < 0 && fEntryNext > 0) { entry = fEntryCurrent; - else if (entry > fEntryCurrent){ - if (entry < fEntryNext) + } else if (entry >= fEntryCurrent) { + if (entry < fEntryNext) { entry = fEntryNext; + } } else { //we are still reading from the oldest buffer, no need to prefetch a new one @@ -636,6 +648,13 @@ Bool_t TTreeCache::FillBuffer() if (fEntryMax <= 0) fEntryMax = tree->GetEntries(); if (fEntryNext > fEntryMax) fEntryNext = fEntryMax; + if ( fEnablePrefetching ) { + if ( entry == fEntryMax ) { + // We are at the end, no need to do anything else + return kFALSE; + } + } + // Check if owner has a TEventList set. If yes we optimize for this // Special case reading only the baskets containing entries in the // list. @@ -822,18 +841,15 @@ Bool_t TTreeCache::FillBuffer() if (fEntryNext > fEntryMax) fEntryNext = fEntryMax; } while (kTRUE); - //in learning mode clear cache - if (fIsLearning) { - fEntryNext = -1; - fEntryCurrent = -1; - TFileCacheRead::Prefetch(0, 0); - TFileCacheRead::SecondPrefetch(0, 0); - fFirstBuffer = !fFirstBuffer; - } - if (!fIsLearning && fFirstTime){ - // first time we add autoFlush entries , after fFillTimes * autoFlush - // only in reverse prefetching mode - fFirstTime = kFALSE; + if (fEnablePrefetching) { + if (fIsLearning) { + fFirstBuffer = !fFirstBuffer; + } + if (!fIsLearning && fFirstTime){ + // First time we add autoFlush entries , after fFillTimes * autoFlush + // only in reverse prefetching mode + fFirstTime = kFALSE; + } } fIsLearning = kFALSE; return kTRUE; @@ -905,7 +921,7 @@ void TTreeCache::Print(Option_t *option) const TString opt = option; opt.ToLower(); - printf("******TreeCache statistics for file: %s ******\n",fFile ? fFile->GetName() : "no file set"); + printf("******TreeCache statistics for tree: %s in file: %s ******\n",fTree ? fTree->GetName() : "no tree set",fFile ? fFile->GetName() : "no file set"); if (fNbranches <= 0) return; printf("Number of branches in the cache ...: %d\n",fNbranches); printf("Cache Efficiency ..................: %f\n",GetEfficiency()); @@ -969,13 +985,19 @@ Int_t TTreeCache::ReadBufferPrefetch(char *buf, Long64_t pos, Int_t len){ return 1; } - //keep on prefetching until request is satisfied - while (1){ + // try to prefetch a couple of times and if request is still not satisfied then + // fall back to normal reading without prefetching for the current request + Int_t counter = 0; + while (1) { if(TFileCacheRead::ReadBuffer(buf, pos, len)) { break; } FillBuffer(); fNReadMiss++; + counter++; + if (counter>1) { + return 0; + } } fNReadOk++; @@ -995,6 +1017,8 @@ Int_t TTreeCache::ReadBuffer(char *buf, Long64_t pos, Int_t len) // 1 in case read from cache. // This function overloads TFileCacheRead::ReadBuffer. + if (!fEnabled) return 0; + if (fEnablePrefetching) return TTreeCache::ReadBufferPrefetch(buf, pos, len); else @@ -1026,7 +1050,7 @@ void TTreeCache::SetEntryRange(Long64_t emin, Long64_t emax) fEntryMin = emin; fEntryMax = emax; - fEntryNext = fEntryMin + fgLearnEntries; + fEntryNext = fEntryMin + fgLearnEntries * needLearningStart; if (gDebug > 0) Info("SetEntryRange", "fEntryMin=%lld, fEntryMax=%lld, fEntryNext=%lld", fEntryMin, fEntryMax, fEntryNext); @@ -1037,6 +1061,22 @@ void TTreeCache::SetEntryRange(Long64_t emin, Long64_t emax) } } +//_____________________________________________________________________________ +void TTreeCache::SetFile(TFile *file, TFile::ECacheAction action) +{ + // Overload to make sure that the object specific + + // The infinite recursion is 'broken' by the fact that + // TFile::SetCacheRead remove the entry from fCacheReadMap _before_ + // calling SetFile (and also by setting fFile to zero before the calling). + if (fFile) { + TFile *prevFile = fFile; + fFile = 0; + prevFile->SetCacheRead(0, fTree, action); + } + TFileCacheRead::SetFile(file, action); +} + //_____________________________________________________________________________ void TTreeCache::SetLearnEntries(Int_t n) { @@ -1047,6 +1087,18 @@ void TTreeCache::SetLearnEntries(Int_t n) fgLearnEntries = n; } +//_____________________________________________________________________________ +void TTreeCache::SetLearnPrefill(TTreeCache::EPrefillType type /* = kNoPrefill */) +{ + // Set whether the learning period is started with a prefilling of the + // cache and which type of prefilling is used. + // The two value currently supported are: + // TTreeCache::kNoPrefill disable the prefilling + // TTreeCache::kAllBranches fill the cache with baskets from all branches. + + fPrefillType = type; +} + //_____________________________________________________________________________ void TTreeCache::StartLearningPhase() { @@ -1120,3 +1172,51 @@ void TTreeCache::UpdateBranches(TTree *tree) fNbranches++; } } + +//_____________________________________________________________________________ +void TTreeCache::LearnPrefill() +{ + // Perform an initial prefetch, attempting to read as much of the learning + // phase baskets for all branches at once + + // This is meant for the learning phase + if (!fIsLearning) return; + + // This should be called before reading entries, otherwise we'll + // always exit here, since TBranch adds itself before reading + if (fNbranches > 0) return; + + // Is the LearnPrefill enabled (using an Int_t here to allow for future + // extension to alternative Prefilling). + if (fPrefillType == kNoPrefill) return; + + // Force only the learn entries to be cached by temporarily setting min/max + // to the learning phase entry range + // But save all the old values, so we can restore everything to how it was + Long64_t eminOld = fEntryMin; + Long64_t emaxOld = fEntryMax; + Long64_t ecurrentOld = fEntryCurrent; + Long64_t enextOld = fEntryNext; + + fEntryMin = fEntryCurrent; + fEntryMax = fEntryNext; + + // Add all branches to be cached. This also sets fIsManual, stops learning, + // and makes fEntryNext = -1 (which forces a cache fill, which is good) + AddBranch("*"); + fIsManual = kFALSE; // AddBranch sets fIsManual, so we reset it + + // Now, fill the buffer with the learning phase entry range + FillBuffer(); + + // Leave everything the way we found it + fIsLearning = kTRUE; + DropBranch("*"); // This doesn't work unless we're already learning + + // Restore entry values + fEntryMin = eminOld; + fEntryMax = emaxOld; + fEntryCurrent = ecurrentOld; + fEntryNext = enextOld; +} + diff --git a/tree/tree/src/TTreeCloner.cxx b/tree/tree/src/TTreeCloner.cxx index cd88afefa20c9..0418b5c75e872 100644 --- a/tree/tree/src/TTreeCloner.cxx +++ b/tree/tree/src/TTreeCloner.cxx @@ -156,10 +156,10 @@ TTreeCloner::TTreeCloner(TTree *from, TTree *to, Option_t *method, UInt_t option fIsValid = kFALSE; } else if (! fToTree->GetDirectory()->IsWritable()) { if (fToTree->GetDirectory()==fToTree->GetCurrentFile()) { - fWarningMsg.Form("The output TTree (%s) must be associated with a writeable file (%s).", + fWarningMsg.Form("The output TTree (%s) must be associated with a writable file (%s).", fToTree->GetName(),fToTree->GetCurrentFile()->GetName()); } else { - fWarningMsg.Form("The output TTree (%s) must be associated with a writeable directory (%s in %s).", + fWarningMsg.Form("The output TTree (%s) must be associated with a writable directory (%s in %s).", fToTree->GetName(),fToTree->GetDirectory()->GetName(),fToTree->GetCurrentFile()->GetName()); } if (!(fOptions & kNoWarnings)) { diff --git a/tree/tree/src/TTreeSQL.cxx b/tree/tree/src/TTreeSQL.cxx index b0516be0cde6e..d52830531ba96 100644 --- a/tree/tree/src/TTreeSQL.cxx +++ b/tree/tree/src/TTreeSQL.cxx @@ -156,7 +156,7 @@ TBranch * TTreeSQL::Branch(const char *name, void *address, for (int i=0;i<nb;i++) { branch = (TBranch*)fBranches.UncheckedAt(i); brName = branch->GetName(); - if (brName.Index(name) == 0) { + if (brName.CompareTo(name) == 0) { // Now if the branch exists in db, root gives a warning and exit // Dealing with duplicate branch has been done, but not tested yet. // So if you want to allow duplicate branch, just comment Fatal() line and uncomment commented diff --git a/tree/treeplayer/inc/TChainIndex.h b/tree/treeplayer/inc/TChainIndex.h index e9fb65b144050..c35ab648fea23 100644 --- a/tree/treeplayer/inc/TChainIndex.h +++ b/tree/treeplayer/inc/TChainIndex.h @@ -35,6 +35,7 @@ #include <vector> class TTreeFormula; +class TTreeIndex; class TChain; class TChainIndex : public TVirtualIndex { @@ -43,10 +44,20 @@ class TChainIndex : public TVirtualIndex { class TChainIndexEntry { // holds a description of indices of trees in the chain. public: - TChainIndexEntry() : fMinIndexValue(0), fMaxIndexValue(0), fTreeIndex(0) {} + TChainIndexEntry() : fMinIndexValue(0), fMinIndexValMinor(0), + fMaxIndexValue(0), fMaxIndexValMinor(0), + fTreeIndex(0) {} - Long64_t fMinIndexValue; // the minimum value of the index - Long64_t fMaxIndexValue; // the maximum value of the index + typedef std::pair<Long64_t, Long64_t> IndexValPair_t; + + IndexValPair_t GetMinIndexValPair() const { return IndexValPair_t(fMinIndexValue, fMinIndexValMinor); } + IndexValPair_t GetMaxIndexValPair() const { return IndexValPair_t(fMaxIndexValue, fMaxIndexValMinor); } + void SetMinMaxFrom(const TTreeIndex *index ); + + Long64_t fMinIndexValue; // the minimum value of the index (upper bits) + Long64_t fMinIndexValMinor; // the minimum value of the index (lower bits) + Long64_t fMaxIndexValue; // the maximum value of the index (upper bits) + Long64_t fMaxIndexValMinor; // the maximum value of the index (lower bits) TVirtualIndex* fTreeIndex; // the tree index in case it was created in the constructor, // otherwise 0 }; @@ -58,7 +69,7 @@ class TChainIndex : public TVirtualIndex { TTreeFormula *fMinorFormulaParent; //! Pointer to minor TreeFormula in Parent tree (if any) std::vector<TChainIndexEntry> fEntries; // descriptions of indices of trees in the chain. - std::pair<TVirtualIndex*, Int_t> GetSubTreeIndex(Int_t major, Int_t minor) const; + std::pair<TVirtualIndex*, Int_t> GetSubTreeIndex(Long64_t major, Long64_t minor) const; void ReleaseSubTreeIndex(TVirtualIndex* index, Int_t treeNo) const; void DeleteIndices(); @@ -68,8 +79,8 @@ class TChainIndex : public TVirtualIndex { virtual ~TChainIndex(); virtual void Append(const TVirtualIndex *, Bool_t delaySort = kFALSE); virtual Long64_t GetEntryNumberFriend(const TTree *parent); - virtual Long64_t GetEntryNumberWithIndex(Int_t major, Int_t minor) const; - virtual Long64_t GetEntryNumberWithBestIndex(Int_t major, Int_t minor) const; + virtual Long64_t GetEntryNumberWithIndex(Long64_t major, Long64_t minor) const; + virtual Long64_t GetEntryNumberWithBestIndex(Long64_t major, Long64_t minor) const; const char *GetMajorName() const {return fMajorName.Data();} const char *GetMinorName() const {return fMinorName.Data();} virtual Long64_t GetN() const {return fEntries.size();} diff --git a/tree/treeplayer/inc/TFormLeafInfo.h b/tree/treeplayer/inc/TFormLeafInfo.h index db0da5762d0cc..18d12eb94faf9 100644 --- a/tree/treeplayer/inc/TFormLeafInfo.h +++ b/tree/treeplayer/inc/TFormLeafInfo.h @@ -26,6 +26,30 @@ #include "TStreamerElement.h" +// declare the extra versions of GetValue() plus templated implementation +#define DECLARE_GETVAL \ + virtual Double_t GetValue(TLeaf *leaf, Int_t instance = 0) \ + { return GetValueImpl<Double_t>(leaf, instance); } \ + virtual Long64_t GetValueLong64(TLeaf *leaf, Int_t instance = 0) \ + { return GetValueImpl<Long64_t>(leaf, instance); } \ + virtual LongDouble_t GetValueLongDouble(TLeaf *leaf, Int_t instance = 0) \ + { return GetValueImpl<LongDouble_t>(leaf, instance); } \ + template<typename T> T GetValueImpl(TLeaf *leaf, Int_t instance = 0) // no semicolon + + +// declare the extra versions of ReadValue() plus templated implementation +#define DECLARE_READVAL \ + virtual Double_t ReadValue(char *where, Int_t instance = 0) \ + { return ReadValueImpl<Double_t>(where, instance); } \ + virtual Long64_t ReadValueLong64(char *where, Int_t instance = 0) \ + { return ReadValueImpl<Long64_t>(where, instance); } \ + virtual LongDouble_t ReadValueLongDouble(char *where, Int_t instance = 0) \ + { return ReadValueImpl<LongDouble_t>(where, instance); } \ + template<typename T> T ReadValueImpl(char *where, Int_t instance = 0) // no semicolon + + + + class TFormLeafInfo : public TObject { public: // Constructors @@ -69,8 +93,6 @@ class TFormLeafInfo : public TObject { Int_t GetNdata(TLeaf* leaf); virtual Int_t GetNdata(); - virtual Double_t GetValue(TLeaf *leaf, Int_t instance = 0); - virtual void *GetValuePointer(TLeaf *leaf, Int_t instance = 0); virtual void *GetValuePointer(char *from, Int_t instance = 0); virtual void *GetLocalValuePointer(TLeaf *leaf, Int_t instance = 0); @@ -94,12 +116,50 @@ class TFormLeafInfo : public TObject { virtual void SetSize(Int_t index, Int_t val); virtual void SetBranch(TBranch* br) { if ( fNext ) fNext->SetBranch(br); } virtual void UpdateSizes(TArrayI *garr); + + virtual Bool_t Update(); + + DECLARE_GETVAL; + DECLARE_READVAL; + + template <typename T> struct ReadValueHelper { + static T Exec(TFormLeafInfo *leaf, char *where, Int_t instance) + { return leaf->ReadValue(where, instance); } + }; + template <typename T > T ReadTypedValue(char *where, Int_t instance = 0) + { return ReadValueHelper<T>::Exec(this, where, instance); } + + template <typename T> struct GetValueHelper { + static T Exec(TFormLeafInfo *linfo, TLeaf *leaf, Int_t instance) + { return linfo->GetValue(leaf, instance); } + }; + template <typename T > T GetTypedValue(TLeaf *leaf, Int_t instance = 0) + { return GetValueHelper<T>::Exec(this, leaf, instance); } +}; - virtual Double_t ReadValue(char *where, Int_t instance = 0); - virtual Bool_t Update(); +template <> struct TFormLeafInfo::ReadValueHelper<Long64_t> { + static Long64_t Exec(TFormLeafInfo *leaf, char *where, Int_t instance) { return leaf->ReadValueLong64(where, instance); } +}; +template <> struct TFormLeafInfo::ReadValueHelper<ULong64_t> { + static ULong64_t Exec(TFormLeafInfo *leaf, char *where, Int_t instance) { return (ULong64_t)leaf->ReadValueLong64(where, instance); } +}; +template <> struct TFormLeafInfo::ReadValueHelper<LongDouble_t> { + static LongDouble_t Exec(TFormLeafInfo *leaf, char *where, Int_t instance) { return leaf->ReadValueLongDouble(where, instance); } +}; + + +template <> struct TFormLeafInfo::GetValueHelper<Long64_t> { + static Long64_t Exec(TFormLeafInfo *linfo, TLeaf *leaf, Int_t instance) { return linfo->GetValueLong64(leaf, instance); } +}; +template <> struct TFormLeafInfo::GetValueHelper<ULong64_t> { + static ULong64_t Exec(TFormLeafInfo *linfo, TLeaf *leaf, Int_t instance) { return (ULong64_t)linfo->GetValueLong64(leaf, instance); } +}; +template <> struct TFormLeafInfo::GetValueHelper<LongDouble_t> { + static LongDouble_t Exec(TFormLeafInfo *linfo, TLeaf *leaf, Int_t instance) { return linfo->GetValueLongDouble(leaf, instance); } +}; + -}; //______________________________________________________________________________ // @@ -113,10 +173,14 @@ class TFormLeafInfoDirect : public TFormLeafInfo { virtual TFormLeafInfo* DeepCopy() const; - virtual Double_t ReadValue(char * /*where*/, Int_t /*instance*/= 0); - virtual Double_t GetValue(TLeaf *leaf, Int_t instance = 0); + DECLARE_GETVAL; virtual void *GetLocalValuePointer(TLeaf *leaf, Int_t instance = 0); virtual void *GetLocalValuePointer(char *thisobj, Int_t instance = 0); + + virtual Double_t ReadValue(char * /*where*/, Int_t /*instance*/= 0); + virtual Long64_t ReadValueLong64(char *where, Int_t i= 0) { return ReadValue(where, i); } + virtual LongDouble_t ReadValueLongDouble(char *where, Int_t i= 0) { return ReadValue(where, i); } + }; @@ -162,9 +226,11 @@ class TFormLeafInfoCollectionObject : public TFormLeafInfo { return new TFormLeafInfoCollectionObject(*this); } + DECLARE_GETVAL; virtual Int_t GetCounterValue(TLeaf* leaf); virtual Double_t ReadValue(char *where, Int_t instance = 0); - virtual Double_t GetValue(TLeaf *leaf, Int_t instance = 0); + virtual Long64_t ReadValueLong64(char *where, Int_t i= 0) { return ReadValue(where, i); } + virtual LongDouble_t ReadValueLongDouble(char *where, Int_t i= 0) { return ReadValue(where, i); } virtual void *GetValuePointer(TLeaf *leaf, Int_t instance = 0); virtual void *GetValuePointer(char *thisobj, Int_t instance = 0); virtual void *GetLocalValuePointer(TLeaf *leaf, Int_t instance = 0); @@ -193,10 +259,10 @@ class TFormLeafInfoClones : public TFormLeafInfo { return new TFormLeafInfoClones(*this); } + DECLARE_GETVAL; + DECLARE_READVAL; virtual Int_t GetCounterValue(TLeaf* leaf); virtual Int_t ReadCounterValue(char *where); - virtual Double_t ReadValue(char *where, Int_t instance = 0); - virtual Double_t GetValue(TLeaf *leaf, Int_t instance = 0); virtual void *GetValuePointer(TLeaf *leaf, Int_t instance = 0); virtual void *GetValuePointer(char *thisobj, Int_t instance = 0); virtual void *GetLocalValuePointer(TLeaf *leaf, Int_t instance = 0); @@ -240,12 +306,12 @@ class TFormLeafInfoCollection : public TFormLeafInfo { virtual Bool_t Update(); + DECLARE_GETVAL; + DECLARE_READVAL; virtual Int_t GetCounterValue(TLeaf* leaf); virtual Int_t ReadCounterValue(char* where); virtual Int_t GetCounterValue(TLeaf* leaf, Int_t instance); virtual Bool_t HasCounter() const; - virtual Double_t ReadValue(char *where, Int_t instance = 0); - virtual Double_t GetValue(TLeaf *leaf, Int_t instance = 0); virtual void *GetValuePointer(TLeaf *leaf, Int_t instance = 0); virtual void *GetValuePointer(char *thisobj, Int_t instance = 0); virtual void *GetLocalValuePointer(TLeaf *leaf, Int_t instance = 0); @@ -280,6 +346,8 @@ class TFormLeafInfoCollectionSize : public TFormLeafInfo { virtual void *GetLocalValuePointer(TLeaf *leaf, Int_t instance = 0); virtual void *GetLocalValuePointer( char *from, Int_t instance = 0); virtual Double_t ReadValue(char *where, Int_t instance = 0); + virtual Long64_t ReadValueLong64(char *where, Int_t i= 0) { return ReadValue(where, i); } + virtual LongDouble_t ReadValueLongDouble(char *where, Int_t i= 0) { return ReadValue(where, i); } }; //______________________________________________________________________________ @@ -295,8 +363,8 @@ class TFormLeafInfoPointer : public TFormLeafInfo { virtual TFormLeafInfo* DeepCopy() const; - virtual Double_t ReadValue(char *where, Int_t instance = 0); - virtual Double_t GetValue(TLeaf *leaf, Int_t instance = 0); + DECLARE_GETVAL; + DECLARE_READVAL; }; //______________________________________________________________________________ @@ -326,12 +394,12 @@ class TFormLeafInfoMethod : public TFormLeafInfo { virtual TFormLeafInfo* DeepCopy() const; + DECLARE_READVAL; virtual TClass* GetClass() const; virtual void *GetLocalValuePointer( TLeaf *from, Int_t instance = 0); virtual void *GetLocalValuePointer(char *from, Int_t instance = 0); virtual Bool_t IsInteger() const; virtual Bool_t IsString() const; - virtual Double_t ReadValue(char *where, Int_t instance = 0); virtual Bool_t Update(); }; @@ -340,7 +408,7 @@ class TFormLeafInfoMethod : public TFormLeafInfo { // TFormLeafInfoMultiVarDim is a small helper class to implement reading a // data member on a variable size array inside a TClonesArray object stored in // a TTree. This is the version used when the data member is inside a -// non-splitted object. +// non-split object. class TFormLeafInfoMultiVarDim : public TFormLeafInfo { public: @@ -382,6 +450,8 @@ class TFormLeafInfoMultiVarDim : public TFormLeafInfo { virtual Int_t GetSize(Int_t index); virtual Int_t GetSumOfSizes(); virtual Double_t GetValue(TLeaf * /*leaf*/, Int_t /*instance*/ = 0); + virtual Long64_t GetValueLong64(TLeaf *leaf, Int_t i= 0) { return GetValue(leaf, i); } + virtual LongDouble_t GetValueLongDouble(TLeaf *leaf, Int_t i= 0) { return GetValue(leaf, i); } virtual Int_t GetVarDim(); virtual Int_t GetVirtVarDim(); virtual Bool_t Update(); @@ -400,8 +470,10 @@ class TFormLeafInfoMultiVarDimDirect : public TFormLeafInfoMultiVarDim { virtual TFormLeafInfo* DeepCopy() const; - virtual Double_t GetValue(TLeaf *leaf, Int_t instance = 0); + DECLARE_GETVAL; virtual Double_t ReadValue(char * /*where*/, Int_t /*instance*/ = 0); + virtual Long64_t ReadValueLong64(char *where, Int_t i= 0) { return ReadValue(where, i); } + virtual LongDouble_t ReadValueLongDouble(char *where, Int_t i= 0) { return ReadValue(where, i); } }; //______________________________________________________________________________ @@ -423,7 +495,9 @@ class TFormLeafInfoMultiVarDimCollection : public TFormLeafInfoMultiVarDim { virtual Int_t GetArrayLength() { return 0; } virtual void LoadSizes(TBranch* branch); virtual Double_t GetValue(TLeaf *leaf, Int_t instance = 0); - virtual Double_t ReadValue(char * /*where*/, Int_t /*instance*/ = 0); + virtual Long64_t GetValueLong64(TLeaf *leaf, Int_t i= 0) { return GetValue(leaf, i); } + virtual LongDouble_t GetValueLongDouble(TLeaf *leaf, Int_t i= 0) { return GetValue(leaf, i); } + DECLARE_READVAL; }; //______________________________________________________________________________ @@ -445,7 +519,9 @@ class TFormLeafInfoMultiVarDimClones : public TFormLeafInfoMultiVarDim { virtual Int_t GetArrayLength() { return 0; } virtual void LoadSizes(TBranch* branch); virtual Double_t GetValue(TLeaf *leaf, Int_t instance = 0); - virtual Double_t ReadValue(char * /*where*/, Int_t /*instance*/ = 0); + virtual Long64_t GetValueLong64(TLeaf *leaf, Int_t i= 0) { return GetValue(leaf, i); } + virtual LongDouble_t GetValueLongDouble(TLeaf *leaf, Int_t i= 0) { return GetValue(leaf, i); } + DECLARE_READVAL; }; //______________________________________________________________________________ @@ -469,9 +545,9 @@ class TFormLeafInfoCast : public TFormLeafInfo { virtual TFormLeafInfo* DeepCopy() const; + DECLARE_READVAL; // Currently only implemented in TFormLeafInfoCast virtual Int_t GetNdata(); - virtual Double_t ReadValue(char *where, Int_t instance = 0); virtual Bool_t Update(); }; @@ -497,9 +573,9 @@ class TFormLeafInfoTTree : public TFormLeafInfo { using TFormLeafInfo::GetLocalValuePointer; using TFormLeafInfo::GetValue; + DECLARE_GETVAL; + DECLARE_READVAL; virtual void *GetLocalValuePointer(TLeaf *leaf, Int_t instance = 0); - virtual Double_t GetValue(TLeaf *leaf, Int_t instance = 0); - virtual Double_t ReadValue(char *thisobj, Int_t instance); virtual Bool_t Update(); }; diff --git a/tree/treeplayer/inc/TFormLeafInfoReference.h b/tree/treeplayer/inc/TFormLeafInfoReference.h index e0b9c60decf13..aa8d586e3e98d 100644 --- a/tree/treeplayer/inc/TFormLeafInfoReference.h +++ b/tree/treeplayer/inc/TFormLeafInfoReference.h @@ -80,10 +80,10 @@ class TFormLeafInfoReference : public TFormLeafInfo { // Return the current size of the array container virtual Int_t GetCounterValue(TLeaf* leaf); - // Access value of referenced object - virtual Double_t GetValue(TLeaf *leaf, Int_t instance); + // Access value of referenced object (macro from TFormLeafInfo.g) + DECLARE_GETVAL; // Read value of referenced object - virtual Double_t ReadValue(char *where, Int_t instance = 0); + DECLARE_READVAL; // TFormLeafInfo overload: Update (and propagate) cached information virtual Bool_t Update(); }; diff --git a/tree/treeplayer/inc/TTreeFormula.h b/tree/treeplayer/inc/TTreeFormula.h index 855c11477c0a7..1759a0ac9bcc2 100644 --- a/tree/treeplayer/inc/TTreeFormula.h +++ b/tree/treeplayer/inc/TTreeFormula.h @@ -124,6 +124,8 @@ friend class TTreeFormulaManager; TList *fDimensionSetup; //! list of dimension setups, for delayed creation of the dimension information. std::vector<std::string> fAliasesUsed; //! List of aliases used during the parsing of the expression. + LongDouble_t* fConstLD; // local version of fConsts able to store bigger numbers + TTreeFormula(const char *name, const char *formula, TTree *tree, const std::vector<std::string>& aliases); void Init(const char *name, const char *formula); Bool_t BranchHasMethod(TLeaf* leaf, TBranch* branch, const char* method,const char* params, Long64_t readentry) const; @@ -159,6 +161,8 @@ friend class TTreeFormulaManager; // Not implemented yet TTreeFormula(const TTreeFormula&); TTreeFormula& operator=(const TTreeFormula&); + + template<typename T> T GetConstant(Int_t k) ; public: TTreeFormula(); @@ -167,7 +171,12 @@ friend class TTreeFormulaManager; virtual Int_t DefinedVariable(TString &variable, Int_t &action); virtual TClass* EvalClass() const; - virtual Double_t EvalInstance(Int_t i=0, const char *stringStack[]=0); + + template<typename T> T EvalInstance(Int_t i=0, const char *stringStack[]=0); + virtual Double_t EvalInstance(Int_t i=0, const char *stringStack[]=0) {return EvalInstance<Double_t>(i, stringStack); } + virtual Long64_t EvalInstance64(Int_t i=0, const char *stringStack[]=0) {return EvalInstance<Long64_t>(i, stringStack); } + virtual LongDouble_t EvalInstanceLD(Int_t i=0, const char *stringStack[]=0) {return EvalInstance<LongDouble_t>(i, stringStack); } + virtual const char *EvalStringInstance(Int_t i=0); virtual void* EvalObject(Int_t i=0); // EvalInstance should be const. See comment on GetNdata() diff --git a/tree/treeplayer/inc/TTreeIndex.h b/tree/treeplayer/inc/TTreeIndex.h index 677f0516ca7ed..24cc63a763f2c 100644 --- a/tree/treeplayer/inc/TTreeIndex.h +++ b/tree/treeplayer/inc/TTreeIndex.h @@ -35,7 +35,8 @@ class TTreeIndex : public TVirtualIndex { TString fMajorName; // Index major name TString fMinorName; // Index minor name Long64_t fN; // Number of entries - Long64_t *fIndexValues; //[fN] Sorted index values + Long64_t *fIndexValues; //[fN] Sorted index values, higher 64bits + Long64_t *fIndexValuesMinor; //[fN] Sorted index values, lower 64bits Long64_t *fIndex; //[fN] Index of sorted values TTreeFormula *fMajorFormula; //! Pointer to major TreeFormula TTreeFormula *fMinorFormula; //! Pointer to minor TreeFormula @@ -51,11 +52,14 @@ class TTreeIndex : public TVirtualIndex { TTreeIndex(const TTree *T, const char *majorname, const char *minorname); virtual ~TTreeIndex(); virtual void Append(const TVirtualIndex *,Bool_t delaySort = kFALSE); + bool ConvertOldToNew(); + Long64_t FindValues(Long64_t major, Long64_t minor) const; virtual Long64_t GetEntryNumberFriend(const TTree *parent); - virtual Long64_t GetEntryNumberWithIndex(Int_t major, Int_t minor) const; - virtual Long64_t GetEntryNumberWithBestIndex(Int_t major, Int_t minor) const; - virtual Long64_t *GetIndexValues() const {return fIndexValues;} + virtual Long64_t GetEntryNumberWithIndex(Long64_t major, Long64_t minor) const; + virtual Long64_t GetEntryNumberWithBestIndex(Long64_t major, Long64_t minor) const; virtual Long64_t *GetIndex() const {return fIndex;} + virtual Long64_t *GetIndexValues() const {return fIndexValues;} + virtual Long64_t *GetIndexValuesMinor() const; const char *GetMajorName() const {return fMajorName.Data();} const char *GetMinorName() const {return fMinorName.Data();} virtual Long64_t GetN() const {return fN;} @@ -67,7 +71,7 @@ class TTreeIndex : public TVirtualIndex { virtual void UpdateFormulaLeaves(const TTree *parent); virtual void SetTree(const TTree *T); - ClassDef(TTreeIndex,1); //A Tree Index with majorname and minorname. + ClassDef(TTreeIndex,2); //A Tree Index with majorname and minorname. }; #endif diff --git a/tree/treeplayer/src/TChainIndex.cxx b/tree/treeplayer/src/TChainIndex.cxx index 71dc8f0ed4e2b..7ad9bf940110b 100644 --- a/tree/treeplayer/src/TChainIndex.cxx +++ b/tree/treeplayer/src/TChainIndex.cxx @@ -22,6 +22,19 @@ #include "TFile.h" #include "TError.h" + + +//______________________________________________________________________________ +void TChainIndex::TChainIndexEntry::SetMinMaxFrom(const TTreeIndex *index ) +{ + fMinIndexValue = index->GetIndexValues()[0]; + fMinIndexValMinor = index->GetIndexValuesMinor()[0]; + fMaxIndexValue = index->GetIndexValues()[index->GetN() - 1]; + fMaxIndexValMinor = index->GetIndexValuesMinor()[index->GetN() - 1]; +} + + + ClassImp(TChainIndex) //______________________________________________________________________________ @@ -99,14 +112,13 @@ TChainIndex::TChainIndex(const TTree *T, const char *majorname, const char *mino return; } - entry.fMinIndexValue = ti_index->GetIndexValues()[0]; - entry.fMaxIndexValue = ti_index->GetIndexValues()[index->GetN() - 1]; + entry.SetMinMaxFrom(ti_index); fEntries.push_back(entry); } // Check if the indices of different trees are in order. If not then return an error. for (i = 0; i < Int_t(fEntries.size() - 1); i++) { - if (fEntries[i].fMaxIndexValue > fEntries[i+1].fMinIndexValue) { + if( fEntries[i].GetMaxIndexValPair() > fEntries[i+1].GetMinIndexValPair() ) { DeleteIndices(); MakeZombie(); Error("TChainIndex", "The indices in files of this chain aren't sorted."); @@ -115,6 +127,7 @@ TChainIndex::TChainIndex(const TTree *T, const char *majorname, const char *mino } + //______________________________________________________________________________ void TChainIndex::Append(const TVirtualIndex *index, Bool_t delaySort ) { @@ -129,15 +142,14 @@ void TChainIndex::Append(const TVirtualIndex *index, Bool_t delaySort ) TChainIndexEntry entry; entry.fTreeIndex = 0; - entry.fMinIndexValue = ti_index->GetIndexValues()[0]; - entry.fMaxIndexValue = ti_index->GetIndexValues()[index->GetN() - 1]; + entry.SetMinMaxFrom(ti_index); fEntries.push_back(entry); } if (!delaySort) { // Check if the indices of different trees are in order. If not then return an error. for (Int_t i = 0; i < Int_t(fEntries.size() - 1); i++) { - if (fEntries[i].fMaxIndexValue > fEntries[i+1].fMinIndexValue) { + if( fEntries[i].GetMaxIndexValPair() > fEntries[i+1].GetMinIndexValPair() ) { DeleteIndices(); MakeZombie(); Error("Append", "The indices in files of this chain aren't sorted."); @@ -171,7 +183,7 @@ TChainIndex::~TChainIndex() } //______________________________________________________________________________ -std::pair<TVirtualIndex*, Int_t> TChainIndex::GetSubTreeIndex(Int_t major, Int_t minor) const +std::pair<TVirtualIndex*, Int_t> TChainIndex::GetSubTreeIndex(Long64_t major, Long64_t minor) const { // Returns a TVirtualIndex for a tree which holds the entry with the specified // major and minor values and the number of that tree. @@ -184,22 +196,22 @@ std::pair<TVirtualIndex*, Int_t> TChainIndex::GetSubTreeIndex(Int_t major, Int_t return make_pair(static_cast<TVirtualIndex*>(0), 0); } - Long64_t indexValue = (Long64_t(major) << 31) + minor; - - if (indexValue < fEntries[0].fMinIndexValue) { + const TChainIndexEntry::IndexValPair_t indexValue(major, minor); + + if( indexValue < fEntries[0].GetMinIndexValPair() ) { Warning("GetSubTreeIndex", "The index value is less than the smallest index values in subtrees"); return make_pair(static_cast<TVirtualIndex*>(0), 0); } Int_t treeNo = fEntries.size() - 1; for (unsigned int i = 0; i < fEntries.size() - 1; i++) { - if (indexValue < fEntries[i+1].fMinIndexValue) { + if( indexValue < fEntries[i+1].GetMinIndexValPair() ) { treeNo = i; break; } } // Double check we found the right range. - if (indexValue > fEntries[treeNo].fMaxIndexValue) { + if( indexValue > fEntries[treeNo].GetMaxIndexValPair() ) { return make_pair(static_cast<TVirtualIndex*>(0), 0); } TChain* chain = dynamic_cast<TChain*> (fTree); @@ -268,7 +280,7 @@ Long64_t TChainIndex::GetEntryNumberFriend(const TTree *parent) } //______________________________________________________________________________ -Long64_t TChainIndex::GetEntryNumberWithBestIndex(Int_t major, Int_t minor) const +Long64_t TChainIndex::GetEntryNumberWithBestIndex(Long64_t major, Long64_t minor) const { // See TTreeIndex::GetEntryNumberWithBestIndex for details. @@ -287,7 +299,7 @@ Long64_t TChainIndex::GetEntryNumberWithBestIndex(Int_t major, Int_t minor) cons } //______________________________________________________________________________ -Long64_t TChainIndex::GetEntryNumberWithIndex(Int_t major, Int_t minor) const +Long64_t TChainIndex::GetEntryNumberWithIndex(Long64_t major, Long64_t minor) const { // Returns the entry number with given index values. // See TTreeIndex::GetEntryNumberWithIndex for details. @@ -302,7 +314,7 @@ Long64_t TChainIndex::GetEntryNumberWithIndex(Int_t major, Int_t minor) const ReleaseSubTreeIndex(indexAndNumber.first, indexAndNumber.second); TChain* chain = dynamic_cast<TChain*> (fTree); R__ASSERT(chain); - if (rv > 0) { + if (rv >= 0) { return rv + chain->GetTreeOffset()[indexAndNumber.second]; } else { return rv; diff --git a/tree/treeplayer/src/TFormLeafInfo.cxx b/tree/treeplayer/src/TFormLeafInfo.cxx index 26cc98f87d0b4..beff3c6279470 100644 --- a/tree/treeplayer/src/TFormLeafInfo.cxx +++ b/tree/treeplayer/src/TFormLeafInfo.cxx @@ -55,6 +55,17 @@ #include "TVirtualCollectionProxy.h" +#define INSTANTIATE_READVAL(CLASS) \ + template Double_t CLASS::ReadValueImpl<Double_t>(char*, Int_t); \ + template Long64_t CLASS::ReadValueImpl<Long64_t>(char*, Int_t); \ + template LongDouble_t CLASS::ReadValueImpl<LongDouble_t>(char*, Int_t) // no semicolon + + +#define INSTANTIATE_GETVAL(CLASS) \ + template Double_t CLASS::GetValueImpl<Double_t>(TLeaf*, Int_t); \ + template Long64_t CLASS::GetValueImpl<Long64_t>(TLeaf*, Int_t); \ + template LongDouble_t CLASS::GetValueImpl<LongDouble_t>(TLeaf*, Int_t) // no semicolon + //______________________________________________________________________________ // // This class is a small helper class to implement reading a data member @@ -761,10 +772,11 @@ void* TFormLeafInfo::GetLocalValuePointer(char *thisobj, Int_t instance) } } - + //______________________________________________________________________________ -Double_t TFormLeafInfo::GetValue(TLeaf *leaf, Int_t instance) +template <typename T> +T TFormLeafInfo::GetValueImpl(TLeaf *leaf, Int_t instance) { // Return result of a leafobject method. @@ -775,11 +787,15 @@ Double_t TFormLeafInfo::GetValue(TLeaf *leaf, Int_t instance) thisobj = GetObjectAddress((TLeafElement*)leaf, instance); // instance might be modified } if (thisobj==0) return 0; - return ReadValue(thisobj,instance); + return ReadTypedValue<T>(thisobj,instance); } +INSTANTIATE_GETVAL(TFormLeafInfo); +INSTANTIATE_READVAL(TFormLeafInfo); + //______________________________________________________________________________ -Double_t TFormLeafInfo::ReadValue(char *thisobj, Int_t instance) +template <typename T> +T TFormLeafInfo::ReadValueImpl(char *thisobj, Int_t instance) { // Read the value at the given memory location if ( !thisobj ) { @@ -804,65 +820,64 @@ Double_t TFormLeafInfo::ReadValue(char *thisobj, Int_t instance) } nextobj += index*fElement->GetClassPointer()->Size(); } - return fNext->ReadValue(nextobj,sub_instance); + return fNext->ReadTypedValue<T>(nextobj,sub_instance); } // return fInfo->ReadValue(thisobj+fOffset,fElement->GetNewType(),instance,1); switch (fElement->GetNewType()) { // basic types - case TStreamerInfo::kBool: return (Double_t)(*(Bool_t*)(thisobj+fOffset)); - case TStreamerInfo::kChar: return (Double_t)(*(Char_t*)(thisobj+fOffset)); - case TStreamerInfo::kUChar: return (Double_t)(*(UChar_t*)(thisobj+fOffset)); - case TStreamerInfo::kShort: return (Double_t)(*(Short_t*)(thisobj+fOffset)); - case TStreamerInfo::kUShort: return (Double_t)(*(UShort_t*)(thisobj+fOffset)); - case TStreamerInfo::kInt: return (Double_t)(*(Int_t*)(thisobj+fOffset)); - case TStreamerInfo::kUInt: return (Double_t)(*(UInt_t*)(thisobj+fOffset)); - case TStreamerInfo::kLong: return (Double_t)(*(Long_t*)(thisobj+fOffset)); - case TStreamerInfo::kULong: return (Double_t)(*(ULong_t*)(thisobj+fOffset)); - case TStreamerInfo::kLong64: return (Double_t)(*(Long64_t*)(thisobj+fOffset)); - case TStreamerInfo::kULong64: return (Double_t)(*(Long64_t*)(thisobj+fOffset)); //cannot cast to ULong64_t with VC++6 - case TStreamerInfo::kFloat: return (Double_t)(*(Float_t*)(thisobj+fOffset)); - case TStreamerInfo::kFloat16: return (Double_t)(*(Float_t*)(thisobj+fOffset)); - case TStreamerInfo::kDouble: return (Double_t)(*(Double_t*)(thisobj+fOffset)); - case TStreamerInfo::kDouble32: return (Double_t)(*(Double_t*)(thisobj+fOffset)); - case TStreamerInfo::kLegacyChar: return (Double_t)(*(char*)(thisobj+fOffset)); - case TStreamerInfo::kCounter: - return (Double_t)(*(Int_t*)(thisobj+fOffset)); + case TStreamerInfo::kBool: return (T)(*(Bool_t*)(thisobj+fOffset)); + case TStreamerInfo::kChar: return (T)(*(Char_t*)(thisobj+fOffset)); + case TStreamerInfo::kUChar: return (T)(*(UChar_t*)(thisobj+fOffset)); + case TStreamerInfo::kShort: return (T)(*(Short_t*)(thisobj+fOffset)); + case TStreamerInfo::kUShort: return (T)(*(UShort_t*)(thisobj+fOffset)); + case TStreamerInfo::kInt: return (T)(*(Int_t*)(thisobj+fOffset)); + case TStreamerInfo::kUInt: return (T)(*(UInt_t*)(thisobj+fOffset)); + case TStreamerInfo::kLong: return (T)(*(Long_t*)(thisobj+fOffset)); + case TStreamerInfo::kULong: return (T)(*(ULong_t*)(thisobj+fOffset)); + case TStreamerInfo::kLong64: return (T)(*(Long64_t*)(thisobj+fOffset)); + case TStreamerInfo::kULong64: return (T)(*(Long64_t*)(thisobj+fOffset)); //cannot cast to ULong64_t with VC++6 + case TStreamerInfo::kFloat: return (T)(*(Float_t*)(thisobj+fOffset)); + case TStreamerInfo::kFloat16: return (T)(*(Float_t*)(thisobj+fOffset)); + case TStreamerInfo::kDouble: return (T)(*(Double_t*)(thisobj+fOffset)); + case TStreamerInfo::kDouble32: return (T)(*(Double_t*)(thisobj+fOffset)); + case TStreamerInfo::kLegacyChar: return (T)(*(char*)(thisobj+fOffset)); + case TStreamerInfo::kCounter: return (T)(*(Int_t*)(thisobj+fOffset)); // array of basic types array[8] case TStreamerInfo::kOffsetL + TStreamerInfo::kBool: - {Bool_t *val = (Bool_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {Bool_t *val = (Bool_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kChar: - {Char_t *val = (Char_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {Char_t *val = (Char_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kShort: - {Short_t *val = (Short_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {Short_t *val = (Short_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kInt: - {Int_t *val = (Int_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {Int_t *val = (Int_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kLong: - {Long_t *val = (Long_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {Long_t *val = (Long_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kLong64: - {Long64_t *val = (Long64_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {Long64_t *val = (Long64_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kFloat16: - {Float_t *val = (Float_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {Float_t *val = (Float_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kFloat: - {Float_t *val = (Float_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {Float_t *val = (Float_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kDouble: - {Double_t *val = (Double_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {Double_t *val = (Double_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kDouble32: - {Double_t *val = (Double_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {Double_t *val = (Double_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kUChar: - {UChar_t *val = (UChar_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {UChar_t *val = (UChar_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kUShort: - {UShort_t *val = (UShort_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {UShort_t *val = (UShort_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kUInt: - {UInt_t *val = (UInt_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {UInt_t *val = (UInt_t*)(thisobj+fOffset); return T(val[instance]);} case TStreamerInfo::kOffsetL + TStreamerInfo::kULong: - {ULong_t *val = (ULong_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {ULong_t *val = (ULong_t*)(thisobj+fOffset); return T(val[instance]);} #if defined(_MSC_VER) && (_MSC_VER <= 1200) case TStreamerInfo::kOffsetL + TStreamerInfo::kULong64: - {Long64_t *val = (Long64_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {Long64_t *val = (Long64_t*)(thisobj+fOffset); return T(val[instance]);} #else case TStreamerInfo::kOffsetL + kULong64_t: - {ULong64_t *val = (ULong64_t*)(thisobj+fOffset); return Double_t(val[instance]);} + {ULong64_t *val = (ULong64_t*)(thisobj+fOffset); return T(val[instance]);} #endif #define READ_ARRAY(TYPE_t) \ @@ -877,7 +892,7 @@ Double_t TFormLeafInfo::ReadValue(char *thisobj, Int_t instance) sub_instance = 0; \ } \ TYPE_t **val =(TYPE_t**)(thisobj+fOffset); \ - return Double_t((val[sub_instance])[index]); \ + return T((val[sub_instance])[index]); \ } // pointer to an array of basic types array[n] @@ -935,12 +950,16 @@ Double_t TFormLeafInfoDirect::ReadValue(char * /*where*/, Int_t /*instance*/) } //______________________________________________________________________________ -Double_t TFormLeafInfoDirect:: GetValue(TLeaf *leaf, Int_t instance) +template <typename T> +T TFormLeafInfoDirect::GetValueImpl(TLeaf *leaf, Int_t instance) { // Return the underlying value. - return leaf->GetValue(instance); + return leaf->GetTypedValue<T>(instance); } +INSTANTIATE_GETVAL(TFormLeafInfoDirect); + + //______________________________________________________________________________ void* TFormLeafInfoDirect::GetLocalValuePointer(TLeaf *leaf, Int_t instance) { @@ -1148,7 +1167,8 @@ Int_t TFormLeafInfoClones::ReadCounterValue(char* where) } //______________________________________________________________________________ -Double_t TFormLeafInfoClones::ReadValue(char *where, Int_t instance) +template <typename T> +T TFormLeafInfoClones::ReadValueImpl(char *where, Int_t instance) { // Return the value of the underlying data member inside the // clones array. @@ -1168,9 +1188,12 @@ Double_t TFormLeafInfoClones::ReadValue(char *where, Int_t instance) // Note we take advantage of having only one physically variable // dimension: char * obj = (char*)clones->UncheckedAt(index); - return fNext->ReadValue(obj,sub_instance); + return fNext->ReadTypedValue<T>(obj,sub_instance); } +INSTANTIATE_GETVAL(TFormLeafInfoClones); +INSTANTIATE_READVAL(TFormLeafInfoClones); + //______________________________________________________________________________ void* TFormLeafInfoClones::GetLocalValuePointer(TLeaf *leaf, Int_t /*instance*/) { @@ -1197,7 +1220,8 @@ void* TFormLeafInfoClones::GetLocalValuePointer(char *where, Int_t instance) } //______________________________________________________________________________ -Double_t TFormLeafInfoClones::GetValue(TLeaf *leaf, Int_t instance) +template <typename T> +T TFormLeafInfoClones::GetValueImpl(TLeaf *leaf, Int_t instance) { // Return the value of the underlying data member inside the // clones array. @@ -1222,7 +1246,7 @@ Double_t TFormLeafInfoClones::GetValue(TLeaf *leaf, Int_t instance) // Note we take advantage of having only one physically variable // dimension: char * obj = (char*)clones->UncheckedAt(index); - return fNext->ReadValue(obj,sub_instance); + return fNext->ReadTypedValue<T>(obj,sub_instance); } //______________________________________________________________________________ @@ -1351,7 +1375,8 @@ void* TFormLeafInfoCollectionObject::GetLocalValuePointer(char *where, Int_t ins } //______________________________________________________________________________ -Double_t TFormLeafInfoCollectionObject::GetValue(TLeaf *leaf, Int_t instance) +template <typename T> +T TFormLeafInfoCollectionObject::GetValueImpl(TLeaf *leaf, Int_t instance) { // Return the value of the underlying data member inside the // clones array. @@ -1359,9 +1384,12 @@ Double_t TFormLeafInfoCollectionObject::GetValue(TLeaf *leaf, Int_t instance) char * obj = (char*)GetLocalValuePointer(leaf); if (fNext==0) return 0; - return fNext->ReadValue(obj,instance); + return fNext->ReadTypedValue<T>(obj,instance); } +INSTANTIATE_GETVAL(TFormLeafInfoCollectionObject); + + //______________________________________________________________________________ void * TFormLeafInfoCollectionObject::GetValuePointer(TLeaf *leaf, Int_t instance) { @@ -1583,7 +1611,8 @@ Int_t TFormLeafInfoCollection::GetCounterValue(TLeaf* leaf, Int_t instance) } //______________________________________________________________________________ -Double_t TFormLeafInfoCollection::ReadValue(char *where, Int_t instance) +template <typename T> +T TFormLeafInfoCollection::ReadValueImpl(char *where, Int_t instance) { // Return the value of the underlying data member inside the // clones array. @@ -1612,9 +1641,13 @@ Double_t TFormLeafInfoCollection::ReadValue(char *where, Int_t instance) char * obj = (char*)fCollProxy->At(index); if (fCollProxy->HasPointers()) obj = *(char**)obj; - return fNext->ReadValue(obj,sub_instance); + return fNext->ReadTypedValue<T>(obj,sub_instance); } +INSTANTIATE_GETVAL(TFormLeafInfoCollection); +INSTANTIATE_READVAL(TFormLeafInfoCollection); + + //______________________________________________________________________________ void* TFormLeafInfoCollection::GetLocalValuePointer(TLeaf *leaf, Int_t /*instance*/) { @@ -1641,7 +1674,8 @@ void* TFormLeafInfoCollection::GetLocalValuePointer(char *where, Int_t instance) } //______________________________________________________________________________ -Double_t TFormLeafInfoCollection::GetValue(TLeaf *leaf, Int_t instance) +template <typename T> +T TFormLeafInfoCollection::GetValueImpl(TLeaf *leaf, Int_t instance) { // Return the value of the underlying data member inside the // clones array. @@ -1671,7 +1705,7 @@ Double_t TFormLeafInfoCollection::GetValue(TLeaf *leaf, Int_t instance) if (obj==0) return 0; if (fCollProxy->HasPointers()) obj = *(char**)obj; if (obj==0) return 0; - return fNext->ReadValue(obj,sub_instance); + return fNext->ReadTypedValue<T>(obj,sub_instance); } //______________________________________________________________________________ @@ -1913,7 +1947,8 @@ TFormLeafInfo* TFormLeafInfoPointer::DeepCopy() const //______________________________________________________________________________ -Double_t TFormLeafInfoPointer::ReadValue(char *where, Int_t instance) +template <typename T> +T TFormLeafInfoPointer::ReadValueImpl(char *where, Int_t instance) { // Return the value of the underlying pointer data member @@ -1927,7 +1962,7 @@ Double_t TFormLeafInfoPointer::ReadValue(char *where, Int_t instance) case TStreamerInfo::kAnyP: case TStreamerInfo::kSTLp: {TObject **obj = (TObject**)(whereoffset); - return obj && *obj ? fNext->ReadValue((char*)*obj,instance) : 0; } + return obj && *obj ? fNext->ReadTypedValue<T>((char*)*obj,instance) : 0; } case TStreamerInfo::kObject: case TStreamerInfo::kTString: @@ -1938,7 +1973,7 @@ Double_t TFormLeafInfoPointer::ReadValue(char *where, Int_t instance) case TStreamerInfo::kSTL: { TObject *obj = (TObject*)(whereoffset); - return fNext->ReadValue((char*)obj,instance); + return fNext->ReadTypedValue<T>((char*)obj,instance); } case TStreamerInfo::kOffsetL + TStreamerInfo::kTObject: @@ -1960,7 +1995,7 @@ Double_t TFormLeafInfoPointer::ReadValue(char *where, Int_t instance) whereoffset += index*fElement->GetClassPointer()->Size(); TObject *obj = (TObject*)(whereoffset); - return fNext->ReadValue((char*)obj,sub_instance); + return fNext->ReadTypedValue<T>((char*)obj,sub_instance); } case TStreamerInfo::kOffsetL + TStreamerInfo::kObjectp: @@ -1970,7 +2005,7 @@ Double_t TFormLeafInfoPointer::ReadValue(char *where, Int_t instance) case TStreamerInfo::kOffsetL + TStreamerInfo::kSTLp: { TObject *obj = (TObject*)(whereoffset); - return fNext->ReadValue((char*)obj,instance); + return fNext->ReadTypedValue<T>((char*)obj,instance); } case kOther_t: @@ -1980,16 +2015,22 @@ Double_t TFormLeafInfoPointer::ReadValue(char *where, Int_t instance) } //______________________________________________________________________________ -Double_t TFormLeafInfoPointer::GetValue(TLeaf *leaf, Int_t instance) +template <typename T> +T TFormLeafInfoPointer::GetValueImpl(TLeaf *leaf, Int_t instance) { // Return the value of the underlying pointer data member if (!fNext) return 0; char * where = (char*)GetLocalValuePointer(leaf,instance); if (where==0) return 0; - return fNext->ReadValue(where,instance); + return fNext->ReadTypedValue<T>(where,instance); } +INSTANTIATE_GETVAL(TFormLeafInfoPointer); +INSTANTIATE_READVAL(TFormLeafInfoPointer); + + + //______________________________________________________________________________ // // TFormLeafInfoMethod is a small helper class to implement executing a method @@ -2203,7 +2244,8 @@ void *TFormLeafInfoMethod::GetLocalValuePointer(char *from, } //______________________________________________________________________________ -Double_t TFormLeafInfoMethod::ReadValue(char *where, Int_t instance) +template <typename T> +T TFormLeafInfoMethod::ReadValueImpl(char *where, Int_t instance) { // Execute the method on the given address @@ -2211,27 +2253,27 @@ Double_t TFormLeafInfoMethod::ReadValue(char *where, Int_t instance) if (!thisobj) return 0; TMethodCall::EReturnType r = fMethod->ReturnType(); - Double_t result = 0; + T result = 0; if (r == TMethodCall::kLong) { Long_t l = 0; fMethod->Execute(thisobj, l); - result = (Double_t) l; + result = (T) l; } else if (r == TMethodCall::kDouble) { Double_t d = 0; fMethod->Execute(thisobj, d); - result = (Double_t) d; + result = (T) d; } else if (r == TMethodCall::kString) { char *returntext = 0; fMethod->Execute(thisobj,&returntext); - result = (Long_t) returntext; + result = T((Long_t) returntext); } else if (fNext) { char * char_result = 0; fMethod->Execute(thisobj, &char_result); - result = fNext->ReadValue(char_result,instance); + result = fNext->ReadTypedValue<T>(char_result,instance); } else fMethod->Execute(thisobj); @@ -2240,12 +2282,15 @@ Double_t TFormLeafInfoMethod::ReadValue(char *where, Int_t instance) return result; } +INSTANTIATE_READVAL(TFormLeafInfoMethod); + + //______________________________________________________________________________ // // TFormLeafInfoMultiVarDim is a helper class to implement reading a // data member on a variable size array inside a TClonesArray object stored in // a TTree. This is the version used when the data member is inside a -// non-splitted object. +// non-split object. //______________________________________________________________________________ TFormLeafInfoMultiVarDim::TFormLeafInfoMultiVarDim( TClass* classptr, @@ -2483,12 +2528,16 @@ TFormLeafInfo* TFormLeafInfoMultiVarDimDirect::DeepCopy() const } //______________________________________________________________________________ -Double_t TFormLeafInfoMultiVarDimDirect::GetValue(TLeaf *leaf, Int_t instance) +template <typename T> +T TFormLeafInfoMultiVarDimDirect::GetValueImpl(TLeaf *leaf, Int_t instance) { // Return the undersying value. - return ((TLeafElement*)leaf)->GetValueSubArray(fPrimaryIndex,instance); + return ((TLeafElement*)leaf)->GetTypedValueSubArray<T>(fPrimaryIndex,instance); } +INSTANTIATE_GETVAL(TFormLeafInfoMultiVarDimDirect); + + //______________________________________________________________________________ Double_t TFormLeafInfoMultiVarDimDirect::ReadValue(char * /*where*/, Int_t /*instance*/) { @@ -2585,7 +2634,8 @@ void TFormLeafInfoMultiVarDimCollection::LoadSizes(TBranch* branch) } //______________________________________________________________________________ -Double_t TFormLeafInfoMultiVarDimCollection::ReadValue(char *where, Int_t instance) +template <typename T> +T TFormLeafInfoMultiVarDimCollection::ReadValueImpl(char *where, Int_t instance) { // Return the value of the underlying data. if (fSecondaryIndex>=0) { @@ -2596,9 +2646,12 @@ Double_t TFormLeafInfoMultiVarDimCollection::ReadValue(char *where, Int_t instan instance = fSecondaryIndex; } } - return fNext->ReadValue(where,instance); + return fNext->ReadTypedValue<T>(where,instance); } +INSTANTIATE_READVAL(TFormLeafInfoMultiVarDimCollection); + + //______________________________________________________________________________ // // TFormLeafInfoMultiVarDimClones is a small helper class to implement reading @@ -2691,7 +2744,8 @@ void TFormLeafInfoMultiVarDimClones::LoadSizes(TBranch* branch) } //______________________________________________________________________________ -Double_t TFormLeafInfoMultiVarDimClones::ReadValue(char *where, Int_t instance) +template <typename T> +T TFormLeafInfoMultiVarDimClones::ReadValueImpl(char *where, Int_t instance) { // Return the value of the underlying data. @@ -2703,9 +2757,12 @@ Double_t TFormLeafInfoMultiVarDimClones::ReadValue(char *where, Int_t instance) instance = fSecondaryIndex; } } - return fNext->ReadValue(where,instance); + return fNext->ReadTypedValue<T>(where,instance); } +INSTANTIATE_READVAL(TFormLeafInfoMultiVarDimClones); + + //______________________________________________________________________________ // // TFormLeafInfoCast is a small helper class to implement casting an object to @@ -2780,7 +2837,8 @@ Int_t TFormLeafInfoCast::GetNdata() } //______________________________________________________________________________ -Double_t TFormLeafInfoCast::ReadValue(char *where, Int_t instance) +template <typename T> +T TFormLeafInfoCast::ReadValueImpl(char *where, Int_t instance) { // Read the value at the given memory location @@ -2797,9 +2855,12 @@ Double_t TFormLeafInfoCast::ReadValue(char *where, Int_t instance) // real class name. } fGoodCast = kTRUE; - return fNext->ReadValue(where,instance); + return fNext->ReadTypedValue<T>(where,instance); } +INSTANTIATE_READVAL(TFormLeafInfoCast); + + //______________________________________________________________________________ Bool_t TFormLeafInfoCast::Update() { @@ -2856,23 +2917,28 @@ void* TFormLeafInfoTTree::GetLocalValuePointer(TLeaf *, Int_t instance) } //______________________________________________________________________________ -Double_t TFormLeafInfoTTree::GetValue(TLeaf *, Int_t instance) +template <typename T> +T TFormLeafInfoTTree::GetValueImpl(TLeaf *, Int_t instance) { // Return result of a leafobject method. - return ReadValue((char*)fCurrent,instance); + return ReadTypedValue<T>((char*)fCurrent,instance); } //______________________________________________________________________________ -Double_t TFormLeafInfoTTree::ReadValue(char *thisobj, Int_t instance) +template <typename T> +T TFormLeafInfoTTree::ReadValueImpl(char *thisobj, Int_t instance) { // Return result of a leafobject method. - if (fElement) return TFormLeafInfo::ReadValue(thisobj,instance); - else if (fNext) return fNext->ReadValue(thisobj,instance); + if (fElement) return TFormLeafInfo::ReadTypedValue<T>(thisobj,instance); + else if (fNext) return fNext->ReadTypedValue<T>(thisobj,instance); else return 0; } +INSTANTIATE_GETVAL(TFormLeafInfoTTree); +INSTANTIATE_READVAL(TFormLeafInfoTTree); + //______________________________________________________________________________ Bool_t TFormLeafInfoTTree::Update() { diff --git a/tree/treeplayer/src/TFormLeafInfoReference.cxx b/tree/treeplayer/src/TFormLeafInfoReference.cxx index ea7d83b902c5e..7c7665f8c72ec 100644 --- a/tree/treeplayer/src/TFormLeafInfoReference.cxx +++ b/tree/treeplayer/src/TFormLeafInfoReference.cxx @@ -160,13 +160,17 @@ Bool_t TFormLeafInfoReference::Update() } //______________________________________________________________________________ -Double_t TFormLeafInfoReference::GetValue(TLeaf *leaf, Int_t instance) +template <typename T> +T TFormLeafInfoReference::GetValueImpl(TLeaf *leaf, Int_t instance) { // Return result of a leafobject method - fBranch = leaf->GetBranch(); - return TFormLeafInfo::GetValue(leaf, instance); + return TFormLeafInfo::GetValueImpl<T>(leaf, instance); } +template Double_t TFormLeafInfoReference::GetValueImpl<Double_t>(TLeaf*, Int_t); +template Long64_t TFormLeafInfoReference::GetValueImpl<Long64_t>(TLeaf*, Int_t); +template LongDouble_t TFormLeafInfoReference::GetValueImpl<LongDouble_t>(TLeaf*, Int_t); + //______________________________________________________________________________ void *TFormLeafInfoReference::GetLocalValuePointer( TLeaf *from, Int_t instance) @@ -196,17 +200,18 @@ void *TFormLeafInfoReference::GetLocalValuePointer(char *where, Int_t instance) } //______________________________________________________________________________ -Double_t TFormLeafInfoReference::ReadValue(char *where, Int_t instance) +template <typename T> +T TFormLeafInfoReference::ReadValueImpl(char *where, Int_t instance) { // Execute the method on the given address - Double_t result = 0; + T result = 0; if ( where ) { where = (char*)fProxy->GetPreparedReference(where); if ( where ) { void* res = fProxy->GetObject(this, where, instance); if ( res ) { - result = (fNext) ? fNext->ReadValue((char*)res,instance) : *(Double_t*)res; + result = (fNext) ? fNext->ReadTypedValue<T>((char*)res,instance) : *(Double_t*)res; } } } @@ -214,3 +219,8 @@ Double_t TFormLeafInfoReference::ReadValue(char *where, Int_t instance) // Get rid of temporary return object. return result; } + +template Double_t TFormLeafInfoReference::ReadValueImpl<Double_t>(char*, Int_t); +template Long64_t TFormLeafInfoReference::ReadValueImpl<Long64_t>(char*, Int_t); +template LongDouble_t TFormLeafInfoReference::ReadValueImpl<LongDouble_t>(char*, Int_t); + diff --git a/tree/treeplayer/src/TSelectorDraw.cxx b/tree/treeplayer/src/TSelectorDraw.cxx index 98f2ea5b9ba84..dd0ddd25a16b9 100644 --- a/tree/treeplayer/src/TSelectorDraw.cxx +++ b/tree/treeplayer/src/TSelectorDraw.cxx @@ -905,8 +905,8 @@ void TSelectorDraw::Begin(TTree *tree) if (!fW) fW = new Double_t[(Int_t)fTree->GetEstimate()]; for (i = 0; i < fValSize; ++i) { - fVmin[i] = FLT_MAX; - fVmax[i] = -FLT_MAX; + fVmin[i] = DBL_MAX; + fVmax[i] = -DBL_MAX; } } @@ -1511,8 +1511,8 @@ void TSelectorDraw::TakeEstimate() vmaxOld[i] = fVmax[i]; } for (i = 0; i < fValSize; ++i) { - fVmin[i] = FLT_MAX; - fVmax[i] = - FLT_MAX; + fVmin[i] = DBL_MAX; + fVmax[i] = - DBL_MAX; } //__________________________1-D histogram_______________________ if (fAction == 1) { @@ -1596,8 +1596,10 @@ void TSelectorDraw::TakeEstimate() pm->Draw("p"); } else { - if (fOption.Contains("a")) { - TString temp(fOption); + TString opt = fOption; + opt.ToLower(); + if (opt.Contains("a")) { + TString temp(opt); temp.ReplaceAll("same",""); if (temp.Contains("a")) { if (h2->TestBit(kCanDelete)) { @@ -1618,7 +1620,7 @@ void TSelectorDraw::TakeEstimate() TH2 *h2 = (TH2*)fObject; Bool_t process2 = kFALSE; if (h2->TestBit(TH1::kCanRebin)) { - if (vminOld[2] == FLT_MAX) + if (vminOld[2] == DBL_MAX) process2 = kTRUE; for (i = 0; i < fValSize && i < 4; i++) { fVmin[i] = vminOld[i]; diff --git a/tree/treeplayer/src/TTreeFormula.cxx b/tree/treeplayer/src/TTreeFormula.cxx index 2a16c66764d80..afafe3d2a1358 100644 --- a/tree/treeplayer/src/TTreeFormula.cxx +++ b/tree/treeplayer/src/TTreeFormula.cxx @@ -1,4 +1,4 @@ -// @(#)root/treeplayer:$Id$ +// @(#)root/treeplayer:$Id: 725e0cf2ee411db3c264a8c94d1432c21569b191 $ // Author: Rene Brun 19/01/96 /************************************************************************* @@ -57,7 +57,6 @@ const Int_t kMaxLen = 1024; R__EXTERN TTree *gTree; - ClassImp(TTreeFormula) //______________________________________________________________________________ @@ -141,6 +140,7 @@ TTreeFormula::TTreeFormula(): TFormula(), fQuickLoad(kFALSE), fNeedLoading(kTRUE fHasCast = 0; fManager = 0; fMultiplicity = 0; + fConstLD = 0; Int_t j,k; for (j=0; j<kMAXCODES; j++) { @@ -189,6 +189,7 @@ void TTreeFormula::Init(const char*name, const char* expression) fMultiplicity = 0; fAxis = 0; fHasCast = 0; + fConstLD = 0; Int_t i,j,k; fManager = new TTreeFormulaManager; fManager->Add(this); @@ -284,8 +285,8 @@ void TTreeFormula::Init(const char*name, const char* expression) } // Create a list of uniques branches to load. - for(k=0; k<fNcodes; k++) { - TLeaf *leaf = (TLeaf*)fLeaves.UncheckedAt(k); + for(k=0; k<fNcodes ; k++) { + TLeaf *leaf = k <= fLeaves.GetEntries() ? (TLeaf*)fLeaves.UncheckedAt(k) : 0; TBranch *branch = 0; if (leaf) { branch = leaf->GetBranch(); @@ -350,6 +351,7 @@ TTreeFormula::~TTreeFormula() fDimensionSetup->Delete(); delete fDimensionSetup; } + delete[] fConstLD; } //______________________________________________________________________________ @@ -2248,7 +2250,7 @@ Int_t TTreeFormula::FindLeafForExpression(const char* expression, TLeaf*& leaf, } // What we have so far might be a member function of one of the - // leaves that are not splitted (for example "GetNtrack" for the Event class). + // leaves that are not split (for example "GetNtrack" for the Event class). TIter next(fTree->GetIteratorOnAllLeaves()); TLeaf* leafcur = 0; while (!leaf && (leafcur = (TLeaf*) next())) { @@ -2304,6 +2306,9 @@ Int_t TTreeFormula::FindLeafForExpression(const char* expression, TLeaf*& leaf, strncat(right,params,kMaxLen-1-strlen(right)); final = kTRUE; + // Record in 'i' what we consumed + i += strlen(params); + // we reset work current = &(work[0]); *current = 0; @@ -2445,7 +2450,7 @@ Int_t TTreeFormula::FindLeafForExpression(const char* expression, TLeaf*& leaf, *current = 0; } else { // What we have so far might be a data member of one of the - // leaves that are not splitted (for example "fNtrack" for the Event class. + // leaves that are not split (for example "fNtrack" for the Event class. TLeaf *leafcur = GetLeafWithDatamember(first,work,readentry); if (leafcur) { leaf = leafcur; @@ -3336,7 +3341,7 @@ Int_t TTreeFormula::GetRealInstance(Int_t instance, Int_t codeindex) { // NOTE: Should we check that this is a valid index? if (check) { Int_t index_real_instance = fVarIndexes[codeindex][0]->GetRealInstance(local_index,-1); - if (index_real_instance > fVarIndexes[codeindex][0]->fNdata[0]) { + if (index_real_instance >= fVarIndexes[codeindex][0]->fNdata[0]) { // out of bounds return fNdata[0]+1; } @@ -3625,7 +3630,7 @@ void* TTreeFormula::EvalObject(int instance) leaf->GetBranch()->GetTree()->GetReadEntry(), fQuickLoad); } - else if (real_instance>fNdata[0]) return 0; + else if (real_instance>=fNdata[0]) return 0; if (fAxis) { return 0; } @@ -3685,7 +3690,7 @@ const char* TTreeFormula::EvalStringInstance(Int_t instance) const Int_t real_instance = GetRealInstance(instance,0); \ \ if (instance==0) fNeedLoading = kTRUE; \ - if (real_instance>fNdata[0]) return 0; \ + if (real_instance>=fNdata[0]) return 0; \ \ /* Since the only operation in this formula is reading this branch, \ we are guaranteed that this function is first called with instance==0 and \ @@ -3714,7 +3719,7 @@ const char* TTreeFormula::EvalStringInstance(Int_t instance) #define TREE_EVAL_INIT \ const Int_t real_instance = GetRealInstance(instance,0); \ \ - if (real_instance>fNdata[0]) return 0; \ + if (real_instance>=fNdata[0]) return 0; \ \ if (fAxis) { \ char * label; \ @@ -3751,115 +3756,152 @@ const char* TTreeFormula::EvalStringInstance(Int_t instance) if (br->GetReadEntry() != treeEntry) br->GetEntry( treeEntry ); \ } \ } \ - if (real_instance>fNdata[code]) return 0; + if (real_instance>=fNdata[code]) return 0; #define TREE_EVAL_INIT_LOOP \ /* Now let calculate what physical instance we really need. */ \ const Int_t real_instance = GetRealInstance(instance,code); \ \ - if (real_instance>fNdata[code]) return 0; - -namespace { - Double_t Summing(TTreeFormula *sum) { - Int_t len = sum->GetNdata(); - Double_t res = 0; - for (int i=0; i<len; ++i) res += sum->EvalInstance(i); - return res; + if (real_instance>=fNdata[code]) return 0; + + +template<typename T> T Summing(TTreeFormula *sum) { + Int_t len = sum->GetNdata(); + T res = 0; + for (int i=0; i<len; ++i) res += sum->EvalInstance<T>(i); + return res; +} + +template<typename T> T FindMin(TTreeFormula *arr) { + Int_t len = arr->GetNdata(); + T res = 0; + if (len) { + res = arr->EvalInstance<T>(0); + for (int i=1; i<len; ++i) { + T val = arr->EvalInstance<T>(i); + if (val < res) { + res = val; + } + } } - Double_t FindMin(TTreeFormula *arr) { - Int_t len = arr->GetNdata(); - Double_t res = 0; - if (len) { - res = arr->EvalInstance(0); - for (int i=1; i<len; ++i) { - Double_t val = arr->EvalInstance(i); - if (val < res) { - res = val; - } + return res; +} + +template<typename T> T FindMax(TTreeFormula *arr) { + Int_t len = arr->GetNdata(); + T res = 0; + if (len) { + res = arr->EvalInstance<T>(0); + for (int i=1; i<len; ++i) { + T val = arr->EvalInstance(i); + if (val > res) { + res = val; } } - return res; } - Double_t FindMax(TTreeFormula *arr) { - Int_t len = arr->GetNdata(); - Double_t res = 0; - if (len) { - res = arr->EvalInstance(0); - for (int i=1; i<len; ++i) { - Double_t val = arr->EvalInstance(i); - if (val > res) { + return res; +} + +template<typename T> T FindMin(TTreeFormula *arr, TTreeFormula *condition) { + Int_t len = arr->GetNdata(); + T res = 0; + if (len) { + int i = 0; + T condval; + do { + condval = condition->EvalInstance<T>(i); + ++i; + } while (!condval && i<len); + if (i==len) { + return 0; + } + if (i!=1) { + // Insure the loading of the branch. + arr->EvalInstance<T>(0); + } + // Now we know that i>0 && i<len and cond==true + res = arr->EvalInstance<T>(i-1); + for (; i<len; ++i) { + condval = condition->EvalInstance<T>(i); + if (condval) { + T val = arr->EvalInstance<T>(i); + if (val < res) { res = val; } } } - return res; } - Double_t FindMin(TTreeFormula *arr, TTreeFormula *condition) { - Int_t len = arr->GetNdata(); - Double_t res = 0; - if (len) { - int i = 0; - Double_t condval; - do { - condval = condition->EvalInstance(i); - ++i; - } while (!condval && i<len); - if (i==len) { - return 0; - } - if (i!=1) { - // Insure the loading of the branch. - arr->EvalInstance(0); - } - // Now we know that i>0 && i<len and cond==true - res = arr->EvalInstance(i-1); - for (; i<len; ++i) { - condval = condition->EvalInstance(i); - if (condval) { - Double_t val = arr->EvalInstance(i); - if (val < res) { - res = val; - } + return res; +} + +template<typename T> T FindMax(TTreeFormula *arr, TTreeFormula *condition) { + Int_t len = arr->GetNdata(); + T res = 0; + if (len) { + int i = 0; + T condval; + do { + condval = condition->EvalInstance<T>(i); + ++i; + } while (!condval && i<len); + if (i==len) { + return 0; + } + if (i!=1) { + // Insure the loading of the branch. + arr->EvalInstance<T>(0); + } + // Now we know that i>0 && i<len and cond==true + res = arr->EvalInstance<T>(i-1); + for (; i<len; ++i) { + condval = condition->EvalInstance<T>(i); + if (condval) { + T val = arr->EvalInstance<T>(i); + if (val > res) { + res = val; } } } - return res; } - Double_t FindMax(TTreeFormula *arr, TTreeFormula *condition) { - Int_t len = arr->GetNdata(); - Double_t res = 0; - if (len) { - int i = 0; - Double_t condval; - do { - condval = condition->EvalInstance(i); - ++i; - } while (!condval && i<len); - if (i==len) { - return 0; - } - if (i!=1) { - // Insure the loading of the branch. - arr->EvalInstance(0); - } - // Now we know that i>0 && i<len and cond==true - res = arr->EvalInstance(i-1); - for (; i<len; ++i) { - condval = condition->EvalInstance(i); - if (condval) { - Double_t val = arr->EvalInstance(i); - if (val > res) { - res = val; - } + return res; +} + + + +template<typename T> inline T POWER(T x, T y) { return TMath::Power(x, y); } +template<> Long64_t POWER(Long64_t x, Long64_t y) { return TMath::Power(x, (Int_t)y); } +template<> LongDouble_t POWER(LongDouble_t x, LongDouble_t y) { return TMath::Power(x, (Double_t)y); } + +template<typename T> inline void SetMethodParam(TMethodCall *method, T p) { method->SetParam(p); } +template<> void SetMethodParam(TMethodCall *method, LongDouble_t p) { method->SetParam((Double_t)p); } + + +template<typename T> inline T TTreeFormula::GetConstant(Int_t k) { return fConst[k]; } +template<> inline LongDouble_t TTreeFormula::GetConstant(Int_t k) { + if( !fConstLD ) { + // create LD version of the constants list by rescanning all literals used in the expression + fConstLD = new LongDouble_t[fNconst]; + for (Int_t op=0; op<fNoper ; ++op) { + const Int_t oper = GetOper()[op]; + if( (oper >> kTFOperShift) == kConstant ) { + int i = (oper & kTFOperMask); + if( !strncmp(fExpr[op], "0x", 2) || !strncmp(fExpr[op], "0X", 2) ) { + ULong64_t val; + sscanf( fExpr[op], "%llx", &val ); + fConstLD[i] = (LongDouble_t)val; + } else { + sscanf( fExpr[op], "%Lg", &fConstLD[i] ); } } } - return res; } + return fConstLD[k]; } +template<> inline Long64_t TTreeFormula::GetConstant(Int_t k) { return (Long64_t)GetConstant<LongDouble_t>(k); } //______________________________________________________________________________ -Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[]) +template<typename T> +T TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[]) { //*-*-*-*-*-*-*-*-*-*-*Evaluate this treeformula*-*-*-*-*-*-*-*-*-*-*-*-*-*-* //*-* ========================= @@ -3867,15 +3909,13 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] // Note that the redundance and structure in this code is tailored to improve // efficiencies. - if (TestBit(kMissingLeaf)) return 0; if (fNoper == 1 && fNcodes > 0) { - + switch (fLookupType[0]) { case kDirect: { TT_EVAL_INIT; - Double_t result = leaf->GetValue(real_instance); - return result; + return leaf->GetTypedValue<T>(real_instance); } case kMethod: { TT_EVAL_INIT; @@ -3885,21 +3925,21 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] case kDataMember: { TT_EVAL_INIT; ((TFormLeafInfo*)fDataMembers.UncheckedAt(0))->SetBranch(leaf->GetBranch()); - return ((TFormLeafInfo*)fDataMembers.UncheckedAt(0))->GetValue(leaf,real_instance); + return ((TFormLeafInfo*)fDataMembers.UncheckedAt(0))->GetTypedValue<T>(leaf,real_instance); } case kTreeMember: { TREE_EVAL_INIT; - return ((TFormLeafInfo*)fDataMembers.UncheckedAt(0))->GetValue((TLeaf*)0x0,real_instance); + return ((TFormLeafInfo*)fDataMembers.UncheckedAt(0))->GetTypedValue<T>((TLeaf*)0x0,real_instance); } - case kIndexOfEntry: return (Double_t)fTree->GetReadEntry(); - case kIndexOfLocalEntry: return (Double_t)fTree->GetTree()->GetReadEntry(); - case kEntries: return (Double_t)fTree->GetEntries(); + case kIndexOfEntry: return (T)fTree->GetReadEntry(); + case kIndexOfLocalEntry: return (T)fTree->GetTree()->GetReadEntry(); + case kEntries: return (T)fTree->GetEntries(); case kLength: return fManager->fNdata; case kLengthFunc: return ((TTreeFormula*)fAliases.UncheckedAt(0))->GetNdata(); case kIteration: return instance; - case kSum: return Summing((TTreeFormula*)fAliases.UncheckedAt(0)); - case kMin: return FindMin((TTreeFormula*)fAliases.UncheckedAt(0)); - case kMax: return FindMax((TTreeFormula*)fAliases.UncheckedAt(0)); + case kSum: return Summing<T>((TTreeFormula*)fAliases.UncheckedAt(0)); + case kMin: return FindMin<T>((TTreeFormula*)fAliases.UncheckedAt(0)); + case kMax: return FindMax<T>((TTreeFormula*)fAliases.UncheckedAt(0)); case kEntryList: { TEntryList *elist = (TEntryList*)fExternalCuts.At(0); return elist->Contains(fTree->GetTree()->GetReadEntry()); @@ -3911,20 +3951,20 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] TCutG *gcut = (TCutG*)fExternalCuts.At(0); TTreeFormula *fx = (TTreeFormula *)gcut->GetObjectX(); TTreeFormula *fy = (TTreeFormula *)gcut->GetObjectY(); - Double_t xcut = fx->EvalInstance(instance); - Double_t ycut = fy->EvalInstance(instance); + T xcut = fx->EvalInstance<T>(instance); + T ycut = fy->EvalInstance<T>(instance); return gcut->IsInside(xcut,ycut); } case -1: { TCutG *gcut = (TCutG*)fExternalCuts.At(0); TTreeFormula *fx = (TTreeFormula *)gcut->GetObjectX(); - return fx->EvalInstance(instance); + return fx->EvalInstance<T>(instance); } default: return 0; } } - Double_t tab[kMAXFOUND]; + T tab[kMAXFOUND]; const Int_t kMAXSTRINGFOUND = 10; const char *stringStackLocal[kMAXSTRINGFOUND]; const char **stringStack = stringStackArg?stringStackArg:stringStackLocal; @@ -3943,7 +3983,7 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] // TFormula operands. // one of the most used cases - if (newaction==kConstant) { pos++; tab[pos-1] = fConst[(oper & kTFOperMask)]; continue; } + if (newaction==kConstant) { pos++; tab[pos-1] = GetConstant<T>(oper & kTFOperMask); continue; } switch(newaction) { @@ -3957,7 +3997,7 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] case kModulo : {pos--; Long64_t int1((Long64_t)tab[pos-1]); Long64_t int2((Long64_t)tab[pos]); - tab[pos-1] = Double_t(int1%int2); + tab[pos-1] = T(int1 % int2); continue;} case kcos : tab[pos-1] = TMath::Cos(tab[pos-1]); continue; @@ -3965,10 +4005,10 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] case ktan : if (TMath::Cos(tab[pos-1]) == 0) {tab[pos-1] = 0;} // { tangente indeterminee } else tab[pos-1] = TMath::Tan(tab[pos-1]); continue; - case kacos : if (TMath::Abs(tab[pos-1]) > 1) {tab[pos-1] = 0;} // indetermination + case kacos : if (std::abs(tab[pos-1]) > 1) {tab[pos-1] = 0;} // indetermination else tab[pos-1] = TMath::ACos(tab[pos-1]); continue; - case kasin : if (TMath::Abs(tab[pos-1]) > 1) {tab[pos-1] = 0;} // indetermination + case kasin : if (std::abs(tab[pos-1]) > 1) {tab[pos-1] = 0;} // indetermination else tab[pos-1] = TMath::ASin(tab[pos-1]); continue; case katan : tab[pos-1] = TMath::ATan(tab[pos-1]); continue; @@ -3981,20 +4021,20 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] else tab[pos-1] = TMath::ACosH(tab[pos-1]); continue; case kasinh: tab[pos-1] = TMath::ASinH(tab[pos-1]); continue; - case katanh: if (TMath::Abs(tab[pos-1]) > 1) {tab[pos-1] = 0;} // indetermination + case katanh: if (std::abs(tab[pos-1]) > 1) {tab[pos-1] = 0;} // indetermination else tab[pos-1] = TMath::ATanH(tab[pos-1]); continue; case katan2: pos--; tab[pos-1] = TMath::ATan2(tab[pos-1],tab[pos]); continue; case kfmod : pos--; tab[pos-1] = fmod(tab[pos-1],tab[pos]); continue; - case kpow : pos--; tab[pos-1] = TMath::Power(tab[pos-1],tab[pos]); continue; + case kpow : pos--; tab[pos-1] = POWER(tab[pos-1],tab[pos]); continue; case ksq : tab[pos-1] = tab[pos-1]*tab[pos-1]; continue; - case ksqrt : tab[pos-1] = TMath::Sqrt(TMath::Abs(tab[pos-1])); continue; + case ksqrt : tab[pos-1] = TMath::Sqrt(std::abs(tab[pos-1])); continue; case kstrstr : pos2 -= 2; pos++;if (strstr(stringStack[pos2],stringStack[pos2+1])) tab[pos-1]=1; else tab[pos-1]=0; continue; - case kmin : pos--; tab[pos-1] = TMath::Min(tab[pos-1],tab[pos]); continue; - case kmax : pos--; tab[pos-1] = TMath::Max(tab[pos-1],tab[pos]); continue; + case kmin : pos--; tab[pos-1] = std::min(tab[pos-1],tab[pos]); continue; + case kmax : pos--; tab[pos-1] = std::max(tab[pos-1],tab[pos]); continue; case klog : if (tab[pos-1] > 0) tab[pos-1] = TMath::Log(tab[pos-1]); else {tab[pos-1] = 0;} //{indetermination } @@ -4010,9 +4050,9 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] case kpi : pos++; tab[pos-1] = TMath::ACos(-1); continue; - case kabs : tab[pos-1] = TMath::Abs(tab[pos-1]); continue; + case kabs : tab[pos-1] = std::abs(tab[pos-1]); continue; case ksign : if (tab[pos-1] < 0) tab[pos-1] = -1; else tab[pos-1] = 1; continue; - case kint : tab[pos-1] = Double_t(Int_t(tab[pos-1])); continue; + case kint : tab[pos-1] = T(Long64_t(tab[pos-1])); continue; case kSignInv: tab[pos-1] = -1 * tab[pos-1]; continue; case krndm : pos++; tab[pos-1] = gRandom->Rndm(1); continue; @@ -4034,10 +4074,10 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] case kStringNotEqual: pos2 -= 2; pos++;if (strcmp(stringStack[pos2+1],stringStack[pos2])) tab[pos-1]=1; else tab[pos-1]=0; continue; - case kBitAnd : pos--; tab[pos-1]= ((Long64_t) tab[pos-1]) & ((Long64_t) tab[pos]); continue; - case kBitOr : pos--; tab[pos-1]= ((Long64_t) tab[pos-1]) | ((Long64_t) tab[pos]); continue; - case kLeftShift : pos--; tab[pos-1]= ((Long64_t) tab[pos-1]) <<((Long64_t) tab[pos]); continue; - case kRightShift: pos--; tab[pos-1]= ((Long64_t) tab[pos-1]) >>((Long64_t) tab[pos]); continue; + case kBitAnd : pos--; tab[pos-1]= ((ULong64_t) tab[pos-1]) & ((ULong64_t) tab[pos]); continue; + case kBitOr : pos--; tab[pos-1]= ((ULong64_t) tab[pos-1]) | ((ULong64_t) tab[pos]); continue; + case kLeftShift : pos--; tab[pos-1]= ((ULong64_t) tab[pos-1]) <<((ULong64_t) tab[pos]); continue; + case kRightShift: pos--; tab[pos-1]= ((ULong64_t) tab[pos-1]) >>((ULong64_t) tab[pos]); continue; case kJump : i = (oper & kTFOperMask); continue; case kJumpIf : { @@ -4058,7 +4098,7 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] pos2++; stringStack[pos2-1] = (char*)fExpr[i].Data(); if (fAxis) { // See TT_EVAL_INIT - Int_t bin = fAxis->FindBin(stringStack[pos2-1]); \ + Int_t bin = fAxis->FindBin(stringStack[pos2-1]); return bin; } continue; @@ -4113,7 +4153,7 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] if (nargs) { UInt_t argloc = pos-nargs; for(Int_t j=0;j<nargs;j++,argloc++,pos--) { - method->SetParam( tab[argloc] ); + SetMethodParam(method, tab[argloc]); } } pos++; @@ -4137,22 +4177,22 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] const Int_t code = (oper & kTFOperMask); const Int_t lookupType = fLookupType[code]; switch (lookupType) { - case kIndexOfEntry: tab[pos++] = (Double_t)fTree->GetReadEntry(); continue; - case kIndexOfLocalEntry: tab[pos++] = (Double_t)fTree->GetTree()->GetReadEntry(); continue; - case kEntries: tab[pos++] = (Double_t)fTree->GetEntries(); continue; + case kIndexOfEntry: tab[pos++] = (T)fTree->GetReadEntry(); continue; + case kIndexOfLocalEntry: tab[pos++] = (T)fTree->GetTree()->GetReadEntry(); continue; + case kEntries: tab[pos++] = (T)fTree->GetEntries(); continue; case kLength: tab[pos++] = fManager->fNdata; continue; case kLengthFunc: tab[pos++] = ((TTreeFormula*)fAliases.UncheckedAt(i))->GetNdata(); continue; case kIteration: tab[pos++] = instance; continue; - case kSum: tab[pos++] = Summing((TTreeFormula*)fAliases.UncheckedAt(i)); continue; - case kMin: tab[pos++] = FindMin((TTreeFormula*)fAliases.UncheckedAt(i)); continue; - case kMax: tab[pos++] = FindMax((TTreeFormula*)fAliases.UncheckedAt(i)); continue; + case kSum: tab[pos++] = Summing<T>((TTreeFormula*)fAliases.UncheckedAt(i)); continue; + case kMin: tab[pos++] = FindMin<T>((TTreeFormula*)fAliases.UncheckedAt(i)); continue; + case kMax: tab[pos++] = FindMax<T>((TTreeFormula*)fAliases.UncheckedAt(i)); continue; - case kDirect: { TT_EVAL_INIT_LOOP; tab[pos++] = leaf->GetValue(real_instance); continue; } + case kDirect: { TT_EVAL_INIT_LOOP; tab[pos++] = leaf->GetTypedValue<T>(real_instance); continue; } case kMethod: { TT_EVAL_INIT_LOOP; tab[pos++] = GetValueFromMethod(code,leaf); continue; } case kDataMember: { TT_EVAL_INIT_LOOP; tab[pos++] = ((TFormLeafInfo*)fDataMembers.UncheckedAt(code))-> - GetValue(leaf,real_instance); continue; } + GetTypedValue<T>(leaf,real_instance); continue; } case kTreeMember: { TREE_EVAL_INIT_LOOP; tab[pos++] = ((TFormLeafInfo*)fDataMembers.UncheckedAt(code))-> - GetValue((TLeaf*)0x0,real_instance); continue; } + GetTypedValue<T>((TLeaf*)0x0,real_instance); continue; } case kEntryList: { TEntryList *elist = (TEntryList*)fExternalCuts.At(code); tab[pos++] = elist->Contains(fTree->GetReadEntry()); continue;} @@ -4164,15 +4204,15 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] TCutG *gcut = (TCutG*)fExternalCuts.At(code); TTreeFormula *fx = (TTreeFormula *)gcut->GetObjectX(); TTreeFormula *fy = (TTreeFormula *)gcut->GetObjectY(); - Double_t xcut = fx->EvalInstance(instance); - Double_t ycut = fy->EvalInstance(instance); + T xcut = fx->EvalInstance<T>(instance); + T ycut = fy->EvalInstance<T>(instance); tab[pos++] = gcut->IsInside(xcut,ycut); continue; } case -1: { TCutG *gcut = (TCutG*)fExternalCuts.At(code); TTreeFormula *fx = (TTreeFormula *)gcut->GetObjectX(); - tab[pos++] = fx->EvalInstance(instance); + tab[pos++] = fx->EvalInstance<T>(instance); continue; } default: { @@ -4189,7 +4229,8 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] TTreeFormula *subform = static_cast<TTreeFormula*>(fAliases.UncheckedAt(aliasN)); R__ASSERT(subform); - Double_t param = subform->EvalInstance(instance); + subform->fDidBooleanOptimization = fDidBooleanOptimization; + T param = subform->EvalInstance<T>(instance); tab[pos] = param; pos++; continue; @@ -4201,6 +4242,7 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] R__ASSERT(subform); pos2++; + subform->fDidBooleanOptimization = fDidBooleanOptimization; stringStack[pos2-1] = subform->EvalStringInstance(instance); continue; } @@ -4208,7 +4250,7 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] int alternateN = i; TTreeFormula *primary = static_cast<TTreeFormula*>(fAliases.UncheckedAt(alternateN)); TTreeFormula *condition = static_cast<TTreeFormula*>(fAliases.UncheckedAt(alternateN+1)); - Double_t param = FindMin(primary,condition); + T param = FindMin<T>(primary,condition); ++i; // skip the place holder for the condition tab[pos] = param; pos++; continue; @@ -4217,7 +4259,7 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] int alternateN = i; TTreeFormula *primary = static_cast<TTreeFormula*>(fAliases.UncheckedAt(alternateN)); TTreeFormula *condition = static_cast<TTreeFormula*>(fAliases.UncheckedAt(alternateN+1)); - Double_t param = FindMax(primary,condition); + T param = FindMax<T>(primary,condition); ++i; // skip the place holder for the condition tab[pos] = param; pos++; continue; @@ -4231,7 +4273,7 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] // First check whether we are in range for the primary formula if (instance < primary->GetNdata()) { - Double_t param = primary->EvalInstance(instance); + T param = primary->EvalInstance<T>(instance); ++i; // skip the alternate value. @@ -4287,7 +4329,7 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] Long64_t treeEntry = br->GetTree()->GetReadEntry(); R__LoadBranch(br,treeEntry,kTRUE); } - if (real_instance>fNdata[string_code]) return 0; + if (real_instance>=fNdata[string_code]) return 0; } pos2++; if (fLookupType[string_code]==kDirect) { @@ -4304,8 +4346,8 @@ Double_t TTreeFormula::EvalInstance(Int_t instance, const char *stringStackArg[] R__ASSERT(i<fNoper); } - Double_t result = tab[0]; - return result; + //std::cout << __PRETTY_FUNCTION__ << " returning " << tab[0] << std::endl; + return tab[0]; } //______________________________________________________________________________ @@ -4579,6 +4621,8 @@ Bool_t TTreeFormula::IsLeafInteger(Int_t code) const if (!strcmp(leaf->GetTypeName(),"Bool_t")) return kTRUE; if (!strcmp(leaf->GetTypeName(),"Char_t")) return kTRUE; if (!strcmp(leaf->GetTypeName(),"UChar_t")) return kTRUE; + if (!strcmp(leaf->GetTypeName(),"Long64_t")) return kTRUE; + if (!strcmp(leaf->GetTypeName(),"ULong64_t")) return kTRUE; if (!strcmp(leaf->GetTypeName(),"string")) return kTRUE; return kFALSE; } @@ -4772,7 +4816,7 @@ char *TTreeFormula::PrintValue(Int_t mode, Int_t instance, const char *decform) switch (outputSizeLevel) { case 0: snprintf(value,kMAXLENGTH,Form("%%%s",decform),(Short_t)((TTreeFormula*)this)->EvalInstance(instance)); break; case 2: snprintf(value,kMAXLENGTH,Form("%%%s",decform),(Long_t)((TTreeFormula*)this)->EvalInstance(instance)); break; - case 3: snprintf(value,kMAXLENGTH,Form("%%%s",decform),(Long64_t)((TTreeFormula*)this)->EvalInstance(instance)); break; + case 3: snprintf(value,kMAXLENGTH,Form("%%%s",decform),(Long64_t)((TTreeFormula*)this)->EvalInstance<LongDouble_t>(instance)); break; case 1: default: snprintf(value,kMAXLENGTH,Form("%%%s",decform),(Int_t)((TTreeFormula*)this)->EvalInstance(instance)); break; } @@ -4786,7 +4830,7 @@ char *TTreeFormula::PrintValue(Int_t mode, Int_t instance, const char *decform) switch (outputSizeLevel) { case 0: snprintf(value,kMAXLENGTH,Form("%%%s",decform),(UShort_t)((TTreeFormula*)this)->EvalInstance(instance)); break; case 2: snprintf(value,kMAXLENGTH,Form("%%%s",decform),(ULong_t)((TTreeFormula*)this)->EvalInstance(instance)); break; - case 3: snprintf(value,kMAXLENGTH,Form("%%%s",decform),(ULong64_t)((TTreeFormula*)this)->EvalInstance(instance)); break; + case 3: snprintf(value,kMAXLENGTH,Form("%%%s",decform),(ULong64_t)((TTreeFormula*)this)->EvalInstance<LongDouble_t>(instance)); break; case 1: default: snprintf(value,kMAXLENGTH,Form("%%%s",decform),(UInt_t)((TTreeFormula*)this)->EvalInstance(instance)); break; } @@ -4799,7 +4843,7 @@ char *TTreeFormula::PrintValue(Int_t mode, Int_t instance, const char *decform) case 'G': { switch (outputSizeLevel) { - case 2: snprintf(value,kMAXLENGTH,Form("%%%s",decform),(long double)((TTreeFormula*)this)->EvalInstance(instance)); break; + case 2: snprintf(value,kMAXLENGTH,Form("%%%s",decform),(LongDouble_t)((TTreeFormula*)this)->EvalInstance<LongDouble_t>(instance)); break; case 1: default: snprintf(value,kMAXLENGTH,Form("%%%s",decform),((TTreeFormula*)this)->EvalInstance(instance)); break; } @@ -4884,6 +4928,9 @@ void TTreeFormula::SetAxis(TAxis *axis) R__ASSERT(subform); subform->SetAxis(axis); } + // Since the bin are corresponding to 'string', we currently must also set + // the axis to align the bins exactly on integer boundaries. + axis->SetBit(TAxis::kIsInteger); } else if (IsInteger()) { axis->SetBit(TAxis::kIsInteger); } @@ -5148,7 +5195,7 @@ void TTreeFormula::ResetDimensions() { continue; } - TLeaf *leaf = (TLeaf*)fLeaves.UncheckedAt(i); + TLeaf *leaf = i <= fLeaves.GetLast() ? (TLeaf*)fLeaves.UncheckedAt(i) : 0; if (!leaf) continue; // Reminder of the meaning of fMultiplicity: @@ -5310,6 +5357,13 @@ Bool_t TTreeFormula::LoadCurrentDim() { // member to be signed integral type. TBranchElement* branch = (TBranchElement*) leaf->GetBranch(); + if (branch->GetAddress() == 0) { + // Humm there is no space reserve to write the data, + // the data member is likely 'removed' from the class + // layout, so rather than crashing by accessing + // random memory, make it clear we can't read it. + size = 0; + } // NOTE: could be sped up if (fHasMultipleVarDim[i]) {// info && info->GetVarDim()>=0) { diff --git a/tree/treeplayer/src/TTreeIndex.cxx b/tree/treeplayer/src/TTreeIndex.cxx index 0eff1ac1ee538..f750ce028da5d 100644 --- a/tree/treeplayer/src/TTreeIndex.cxx +++ b/tree/treeplayer/src/TTreeIndex.cxx @@ -21,14 +21,35 @@ ClassImp(TTreeIndex) + +struct IndexSortComparator { + + IndexSortComparator(Long64_t *major, Long64_t *minor) + : fValMajor(major), fValMinor(minor) + {} + + template<typename Index> + bool operator()(Index i1, Index i2) { + if( *(fValMajor + i1) == *(fValMajor + i2) ) + return *(fValMinor + i1) < *(fValMinor + i2); + else + return *(fValMajor + i1) < *(fValMajor + i2); + } + + // pointers to the start of index values tables keeping uppder 64bit and lower 64bit + // of combined indexed 128bit value + Long64_t *fValMajor, *fValMinor; +}; + + //______________________________________________________________________________ TTreeIndex::TTreeIndex(): TVirtualIndex() { // Default constructor for TTreeIndex - fTree = 0; fN = 0; fIndexValues = 0; + fIndexValuesMinor = 0; fIndex = 0; fMajorFormula = 0; fMinorFormula = 0; @@ -100,6 +121,7 @@ TTreeIndex::TTreeIndex(const TTree *T, const char *majorname, const char *minorn fTree = (TTree*)T; fN = 0; fIndexValues = 0; + fIndexValuesMinor = 0; fIndex = 0; fMajorFormula = 0; fMinorFormula = 0; @@ -134,7 +156,8 @@ TTreeIndex::TTreeIndex(const TTree *T, const char *majorname, const char *minorn // return; //} - Long64_t *w = new Long64_t[fN]; + Long64_t *tmp_major = new Long64_t[fN]; + Long64_t *tmp_minor = new Long64_t[fN]; Long64_t i; Long64_t oldEntry = fTree->GetReadEntry(); Int_t current = -1; @@ -146,21 +169,22 @@ TTreeIndex::TTreeIndex(const TTree *T, const char *majorname, const char *minorn fMajorFormula->UpdateFormulaLeaves(); fMinorFormula->UpdateFormulaLeaves(); } - Double_t majord = fMajorFormula->EvalInstance(); - Double_t minord = fMinorFormula->EvalInstance(); - Long64_t majorv = (Long64_t)majord; - Long64_t minorv = (Long64_t)minord; - w[i] = majorv<<31; - w[i] += minorv; + tmp_major[i] = (Long64_t) fMajorFormula->EvalInstance<LongDouble_t>(); + tmp_minor[i] = (Long64_t) fMinorFormula->EvalInstance<LongDouble_t>(); } - fIndex = new Long64_t[fN]; - TMath::Sort(fN,w,fIndex,0); + fIndex = new Long64_t[fN]; + for(i = 0; i < fN; i++) { fIndex[i] = i; } + std::sort(fIndex, fIndex + fN, IndexSortComparator(tmp_major, tmp_minor) ); + //TMath::Sort(fN,w,fIndex,0); fIndexValues = new Long64_t[fN]; + fIndexValuesMinor = new Long64_t[fN]; for (i=0;i<fN;i++) { - fIndexValues[i] = w[fIndex[i]]; + fIndexValues[i] = tmp_major[fIndex[i]]; + fIndexValuesMinor[i] = tmp_minor[fIndex[i]]; } - delete [] w; + delete [] tmp_major; + delete [] tmp_minor; fTree->LoadTree(oldEntry); } @@ -171,6 +195,7 @@ TTreeIndex::~TTreeIndex() if (fTree && fTree->GetTreeIndex() == this) fTree->SetTreeIndex(0); delete [] fIndexValues; fIndexValues = 0; + delete [] fIndexValuesMinor; fIndexValuesMinor = 0; delete [] fIndex; fIndex = 0; delete fMajorFormula; fMajorFormula = 0; delete fMinorFormula; fMinorFormula = 0; @@ -199,53 +224,85 @@ void TTreeIndex::Append(const TVirtualIndex *add, Bool_t delaySort ) fN += add->GetN(); Long64_t *oldIndex = fIndex; - Long64_t *oldValues = fIndexValues; + Long64_t *oldValues = GetIndexValues(); + Long64_t *oldValues2 = GetIndexValuesMinor(); fIndex = new Long64_t[fN]; fIndexValues = new Long64_t[fN]; + fIndexValuesMinor = new Long64_t[fN]; // Copy data - Long_t size = sizeof(Long64_t) * oldn; Long_t add_size = sizeof(Long64_t) * add->GetN(); memcpy(fIndex,oldIndex, size); memcpy(fIndexValues,oldValues, size); + memcpy(fIndexValuesMinor,oldValues2, size); Long64_t *addIndex = ti_add->GetIndex(); Long64_t *addValues = ti_add->GetIndexValues(); + Long64_t *addValues2 = ti_add->GetIndexValuesMinor(); memcpy(fIndex + oldn, addIndex, add_size); memcpy(fIndexValues + oldn, addValues, add_size); + memcpy(fIndexValuesMinor + oldn, addValues2, add_size); for(Int_t i = 0; i < add->GetN(); i++) { fIndex[oldn + i] += oldn; } delete [] oldIndex; delete [] oldValues; + delete [] oldValues2; } // Sort. if (!delaySort) { - Long64_t *w = fIndexValues; + Long64_t *addValues = GetIndexValues(); + Long64_t *addValues2 = GetIndexValuesMinor(); Long64_t *ind = fIndex; Long64_t *conv = new Long64_t[fN]; - TMath::Sort(fN,w,conv,0); + for(Long64_t i = 0; i < fN; i++) { conv[i] = i; } + std::sort(conv, conv+fN, IndexSortComparator(addValues, addValues2) ); + //Long64_t *w = fIndexValues; + //TMath::Sort(fN,w,conv,0); fIndex = new Long64_t[fN]; fIndexValues = new Long64_t[fN]; + fIndexValuesMinor = new Long64_t[fN]; for (Int_t i=0;i<fN;i++) { fIndex[i] = ind[conv[i]]; - fIndexValues[i] = w[conv[i]]; + fIndexValues[i] = addValues[conv[i]]; + fIndexValuesMinor[i] = addValues2[conv[i]]; } - delete [] w; + delete [] addValues; + delete [] addValues2; delete [] ind; delete [] conv; } } + + +//______________________________________________________________________________ +bool TTreeIndex::ConvertOldToNew() +{ + // conversion from old 64bit indexes + // return true if index was converted + if( !fIndexValuesMinor && fN ) { + fIndexValuesMinor = new Long64_t[fN]; + for(int i=0; i<fN; i++) { + fIndexValuesMinor[i] = (fIndexValues[i] & 0x7fffffff); + fIndexValues[i] >>= 31; + } + return true; + } + return false; +} + + + //______________________________________________________________________________ Long64_t TTreeIndex::GetEntryNumberFriend(const TTree *parent) { @@ -282,8 +339,33 @@ Long64_t TTreeIndex::GetEntryNumberFriend(const TTree *parent) return fTree->GetEntryNumberWithIndex(majorv,minorv); } + +//______________________________________________________________________________ +Long64_t TTreeIndex::FindValues(Long64_t major, Long64_t minor) const +{ + // find position where major|minor values are in the IndexValues tables + // this is the index in IndexValues table, not entry# ! + // use lower_bound STD algorithm + + Long64_t mid, step, pos = 0, count = fN; + // find lower bound using bisection + while( count > 0 ) { + step = count / 2; + mid = pos + step; + // check if *mid < major|minor + if( fIndexValues[mid] < major + || ( fIndexValues[mid] == major && fIndexValuesMinor[mid] < minor ) ) { + pos = mid+1; + count -= step + 1; + } else + count = step; + } + return pos; +} + + //______________________________________________________________________________ -Long64_t TTreeIndex::GetEntryNumberWithBestIndex(Int_t major, Int_t minor) const +Long64_t TTreeIndex::GetEntryNumberWithBestIndex(Long64_t major, Long64_t minor) const { // Return entry number corresponding to major and minor number. // Note that this function returns only the entry number, not the data @@ -301,16 +383,18 @@ Long64_t TTreeIndex::GetEntryNumberWithBestIndex(Int_t major, Int_t minor) const // See also GetEntryNumberWithIndex if (fN == 0) return -1; - Long64_t value = Long64_t(major)<<31; - value += minor; - Int_t i = TMath::BinarySearch(fN, fIndexValues, value); - if (i < 0) return -1; - return fIndex[i]; + + Long64_t pos = FindValues(major, minor); + if( pos < fN && fIndexValues[pos] == major && fIndexValuesMinor[pos] == minor ) + return fIndex[pos]; + if( --pos < 0 ) + return -1; + return fIndex[pos]; } //______________________________________________________________________________ -Long64_t TTreeIndex::GetEntryNumberWithIndex(Int_t major, Int_t minor) const +Long64_t TTreeIndex::GetEntryNumberWithIndex(Long64_t major, Long64_t minor) const { // Return entry number corresponding to major and minor number. // Note that this function returns only the entry number, not the data @@ -324,14 +408,22 @@ Long64_t TTreeIndex::GetEntryNumberWithIndex(Int_t major, Int_t minor) const // See also GetEntryNumberWithBestIndex if (fN == 0) return -1; - Long64_t value = Long64_t(major)<<31; - value += minor; - Int_t i = TMath::BinarySearch(fN, fIndexValues, value); - if (i < 0) return -1; - if (fIndexValues[i] != value) return -1; - return fIndex[i]; + + Long64_t pos = FindValues(major, minor); + if( pos < fN && fIndexValues[pos] == major && fIndexValuesMinor[pos] == minor ) + return fIndex[pos]; + return -1; +} + + +//______________________________________________________________________________ +Long64_t* TTreeIndex::GetIndexValuesMinor() const +{ + return fIndexValuesMinor; } + + //______________________________________________________________________________ TTreeFormula *TTreeIndex::GetMajorFormula() { @@ -394,6 +486,7 @@ TTreeFormula *TTreeIndex::GetMinorFormulaParent(const TTree *parent) return fMinorFormulaParent; } + //______________________________________________________________________________ void TTreeIndex::Print(Option_t * option) const { @@ -413,30 +506,26 @@ void TTreeIndex::Print(Option_t * option) const } if (printEntry) { - Printf("\n*****************************************************************"); Printf("* Index of Tree: %s/%s",fTree->GetName(),fTree->GetTitle()); Printf("*****************************************************************"); Printf("%8s : %16s : %16s : %16s","serial",fMajorName.Data(),fMinorName.Data(),"entry number"); Printf("*****************************************************************"); for (Long64_t i=0;i<n;i++) { - Long64_t minor = fIndexValues[i] & 0xffff; - Long64_t major = fIndexValues[i]>>31; - Printf("%8lld : %8lld : %8lld : %8lld",i,major,minor,fIndex[i]); + Printf("%8lld : %8lld : %8lld : %8lld", + i, fIndexValues[i], GetIndexValuesMinor()[i], fIndex[i]); } } else { - Printf("\n**********************************************"); Printf("* Index of Tree: %s/%s",fTree->GetName(),fTree->GetTitle()); Printf("**********************************************"); Printf("%8s : %16s : %16s","serial",fMajorName.Data(),fMinorName.Data()); Printf("**********************************************"); for (Long64_t i=0;i<n;i++) { - Long64_t minor = fIndexValues[i] & 0xffff; - Long64_t major = fIndexValues[i]>>31; - Printf("%8lld : %8lld : %8lld",i,major,minor); - } + Printf("%8lld : %8lld : %8lld", + i, fIndexValues[i],GetIndexValuesMinor()[i]); + } } } @@ -456,6 +545,12 @@ void TTreeIndex::Streamer(TBuffer &R__b) R__b >> fN; fIndexValues = new Long64_t[fN]; R__b.ReadFastArray(fIndexValues,fN); + if( R__v > 1 ) { + fIndexValuesMinor = new Long64_t[fN]; + R__b.ReadFastArray(fIndexValuesMinor,fN); + } else { + ConvertOldToNew(); + } fIndex = new Long64_t[fN]; R__b.ReadFastArray(fIndex,fN); R__b.CheckByteCount(R__s, R__c, TTreeIndex::IsA()); @@ -466,6 +561,7 @@ void TTreeIndex::Streamer(TBuffer &R__b) fMinorName.Streamer(R__b); R__b << fN; R__b.WriteFastArray(fIndexValues, fN); + R__b.WriteFastArray(fIndexValuesMinor, fN); R__b.WriteFastArray(fIndex, fN); R__b.SetByteCount(R__c, kTRUE); } diff --git a/tree/treeplayer/src/TTreePerfStats.cxx b/tree/treeplayer/src/TTreePerfStats.cxx index 302eb27f55d63..abc0f68a79d19 100644 --- a/tree/treeplayer/src/TTreePerfStats.cxx +++ b/tree/treeplayer/src/TTreePerfStats.cxx @@ -161,12 +161,14 @@ TTreePerfStats::TTreePerfStats(const char *name, TTree *T) : TVirtualPerfStats() fCompress = (T->GetTotBytes()+0.00001)/T->GetZipBytes(); Bool_t isUNIX = strcmp(gSystem->GetName(), "Unix") == 0; - if (isUNIX) fHostInfo = gSystem->GetFromPipe("uname -a"); - else fHostInfo = "Windows "; + if (isUNIX) + fHostInfo = gSystem->GetFromPipe("uname -a"); + else + fHostInfo = "Windows "; fHostInfo.Resize(20); - fHostInfo += Form("Root%s, SVN :%d",gROOT->GetVersion(),gROOT->GetSvnRevision()); + fHostInfo += TString::Format("Root %s, Git: %s",gROOT->GetVersion(),gROOT->GetGitCommit()); TDatime dt; - fHostInfo += Form(" %s",dt.AsString()); + fHostInfo += TString::Format(" %s",dt.AsString()); fHostInfoText = 0; gPerfStats = this; diff --git a/tree/treeplayer/src/TTreePlayer.cxx b/tree/treeplayer/src/TTreePlayer.cxx index 9aa533602ceac..83e23aa049c00 100644 --- a/tree/treeplayer/src/TTreePlayer.cxx +++ b/tree/treeplayer/src/TTreePlayer.cxx @@ -2198,6 +2198,7 @@ Long64_t TTreePlayer::Process(TSelector *selector,Option_t *option, Long64_t nen selector->SlaveTerminate(); //<==call user termination function selector->Terminate(); //<==call user termination function } + fTree->SetNotify(0); // Detach the selector from the tree. fSelectorUpdate = 0; if (gMonitoringWriter) gMonitoringWriter->SendProcessingStatus("DONE"); diff --git a/tree/treeplayer/src/TTreeProxyGenerator.cxx b/tree/treeplayer/src/TTreeProxyGenerator.cxx index fb2ff32e09c74..4dc34d7ad2d0d 100644 --- a/tree/treeplayer/src/TTreeProxyGenerator.cxx +++ b/tree/treeplayer/src/TTreeProxyGenerator.cxx @@ -406,6 +406,7 @@ namespace ROOT { const char *filename = cl->GetDeclFileName(); if (!filename) return; + if (!strcmp(filename, "(C++ compiled)")) return; #ifdef R__WIN32 TString inclPath("include;prec_stl"); // GetHtml()->GetIncludePath()); @@ -499,19 +500,19 @@ namespace ROOT { { // Generate an enum for a given type if it is not known in the list of class // unless the type itself a template. - + if (!TClassEdit::IsStdClass(clname) && !TClass::GetClass(clname) && gROOT->GetType(clname) == 0) { - + TObject *obj = fListOfForwards.FindObject(clname); if (obj) return; - + // The class does not exist, let's create it if ew can. if (clname[strlen(clname)-1]=='>') { // Template instantiation. fListOfForwards.Add(new TNamed(clname,TString::Format("template <> class %s { public: operator int() { return 0; } };\n", clname).Data())); } else if (isscope) { - // a scope - + // a scope + } else { // Class or enum we know nothing about, let's assume it is an enum. fListOfForwards.Add(new TNamed(clname,TString::Format("enum %s { kDefault_%s };\n", clname, clname).Data())); @@ -523,12 +524,12 @@ namespace ROOT { { // Check if the template parameter refers to an enum and/or a missing class (we can't tell those 2 apart unless // the name as template syntax). - + UInt_t len = strlen(clname); UInt_t nest = 0; UInt_t last = 0; //Bool_t istemplate = kFALSE; // mark whether the current right most entity is a class template. - + for (UInt_t i = 0; i < len; ++i) { switch (clname[i]) { case ':': @@ -550,7 +551,7 @@ namespace ROOT { TString incName(clname + last, i - last); incName = TClassEdit::ShortType(incName.Data(), TClassEdit::kDropTrailStar | TClassEdit::kLong64); if (clname[i] == '>' && nest == 1) incName.Append(">"); - + if (isdigit(incName[0])) { // Not a class name, nothing to do. } else { @@ -562,7 +563,7 @@ namespace ROOT { } AddMissingClassAsEnum(TClassEdit::ShortType(clname, TClassEdit::kDropTrailStar | TClassEdit::kLong64).c_str(),kFALSE); } - + static TString GetContainedClassName(TBranchElement *branch, TStreamerElement *element, Bool_t ispointer) { TString cname = branch->GetClonesName(); @@ -928,7 +929,7 @@ static TVirtualStreamerInfo *GetBaseClass(TStreamerElement *element) } local_cldesc = new TBranchProxyClassDescriptor(cl->GetName(), binfo, branch->GetName(), - isclones, 0 /* unsplit object */, + isclones, 0 /* unsplit object */, containerName); TStreamerElement *elem = 0; @@ -1340,7 +1341,7 @@ static TVirtualStreamerInfo *GetBaseClass(TStreamerElement *element) if (cl) { if (NeedToEmulate(cl,0) || branchname[strlen(branchname)-1] == '.' || branch->GetSplitLevel()) { TBranchElement *be = dynamic_cast<TBranchElement*>(branch); - TVirtualStreamerInfo *beinfo = (be && isclones == TBranchProxyClassDescriptor::kOut) + TVirtualStreamerInfo *beinfo = (be && isclones == TBranchProxyClassDescriptor::kOut) ? be->GetInfo() : cl->GetStreamerInfo(); // the 2nd hand need to be fixed desc = new TBranchProxyClassDescriptor(cl->GetName(), beinfo, branchname, isclones, branch->GetSplitLevel(),containerName); @@ -1354,7 +1355,7 @@ static TVirtualStreamerInfo *GetBaseClass(TStreamerElement *element) if ( branch->GetListOfBranches()->GetEntries() == 0 ) { if (cl) { - // We have a non-splitted object! + // We have a non-split object! if (desc) { TVirtualStreamerInfo *cinfo = cl->GetStreamerInfo(); @@ -1382,7 +1383,7 @@ static TVirtualStreamerInfo *GetBaseClass(TStreamerElement *element) } else { - // We have a splitted object + // We have a split object TIter subnext( branch->GetListOfBranches() ); if (desc) { @@ -1462,7 +1463,45 @@ static TVirtualStreamerInfo *GetBaseClass(TStreamerElement *element) if (!element) return; if (strcmp(element->GetName(),"This")==0) { - // Skip the artifical streamer element. + TClass *cl = element->GetClassPointer(); + containerName = cl->GetName(); + cl = cl->GetCollectionProxy()->GetValueClass(); + if (!cl) { + // Skip the artifical streamer element. + return; + } + // else return; + + // In case the content is a class, move forward + AddForward(cl); + AddHeader(cl); + + if (level<=fMaxUnrolling) { + + // See AnalyzeTree for similar code! + // TBranchProxyClassDescriptor *cldesc; + if (cl && cl->CanSplit()) { + // cldesc = new TBranchProxyClassDescriptor(cl->GetName(), cl->GetStreamerInfo(), + // branch->GetName(), + // isclones, 0 /* non-split object */, + // containerName); + + TVirtualStreamerInfo *info = cl->GetStreamerInfo(); + TStreamerElement *elem = 0; + + TString subpath = path; + if (subpath.Length()>0) subpath += "."; + subpath += dataMemberName; + + TIter next(info->GetElements()); + while( (elem = (TStreamerElement*)next()) ) { + AnalyzeElement(branch, elem, level+1, topdesc, subpath.Data()); + } + + // TBranchProxyClassDescriptor *added = AddClass(cldesc); + // if (added) type = added->GetName(); + } + } return; } @@ -1685,7 +1724,7 @@ static TVirtualStreamerInfo *GetBaseClass(TStreamerElement *element) // true if it has been added _or_ if it is known to // not be needed. // (I.e. return kFALSE if a container of this class - // can not have a "pragma C++ class" + // can not have a "pragma C++ class" if (!cl) return kFALSE; if (cl->GetCollectionProxy()) { @@ -1697,7 +1736,7 @@ static TVirtualStreamerInfo *GetBaseClass(TStreamerElement *element) if (!cl->IsLoaded()) gen->AddPragma(Form("#pragma link C++ class %s;\n", cl->GetName())); return kTRUE; } - } + } if (cl->IsLoaded()) return kTRUE; return kFALSE; } @@ -1709,7 +1748,7 @@ static TVirtualStreamerInfo *GetBaseClass(TStreamerElement *element) // true if it has been added _or_ if it is known to // not be needed. // (I.e. return kFALSE if a container of this class - // can not have a "pragma C++ class" + // can not have a "pragma C++ class" return R__AddPragmaForClass( gen, TClass::GetClass(classname) ); @@ -1830,17 +1869,15 @@ static TVirtualStreamerInfo *GetBaseClass(TStreamerElement *element) } FILE *hf; - TString tmpfilename; + TString tmpfilename = ".Proxy-"; if (updating) { - // Coverity[secure_temp]: we don't care about predictable names. - tmpfilename = gSystem->BaseName( tmpnam(0) ); - tmpfilename.Append("_proxy.h"); - hf = fopen(tmpfilename.Data(),"w"); + hf = gSystem->TempFileName(tmpfilename, "./"); } else { - hf = fopen(fHeaderFileName.Data(),"w"); + hf = fopen(fHeaderFileName, "w"); } if (hf == 0) { - Error("WriteProxy","Unable to open the file %s for writing.",fHeaderFileName.Data()); + Error("WriteProxy","Unable to open the file %s for writing.", + updating ? tmpfilename.Data() : fHeaderFileName.Data()); delete [] filename; delete [] cutfilename; return; @@ -1901,12 +1938,13 @@ static TVirtualStreamerInfo *GetBaseClass(TStreamerElement *element) TObject *header; while ( (header = next()) ) { fprintf(hf,"%s",header->GetTitle()); + } fprintf(hf,"\n\n"); fprintf(hf,"class %s_Interface {\n", scriptfunc.Data()); fprintf(hf," // This class defines the list of methods that are directly used by %s,\n",classname.Data()); - fprintf(hf," // and that can be overloaded in the user's script\n"); + fprintf(hf," // and that can be overloaded in the user's script\n"); fprintf(hf,"public:\n"); fprintf(hf," void %s_Begin(TTree*) {}\n",scriptfunc.Data()); fprintf(hf," void %s_SlaveBegin(TTree*) {}\n",scriptfunc.Data()); diff --git a/tree/treeviewer/inc/TTreeViewer.h b/tree/treeviewer/inc/TTreeViewer.h index adf259207ab78..64dc0f56733ba 100644 --- a/tree/treeviewer/inc/TTreeViewer.h +++ b/tree/treeviewer/inc/TTreeViewer.h @@ -222,6 +222,7 @@ friend class TGButton; void SetScanRedirect(Bool_t mode); void SetSession(TTVSession *session); void SetUserCode(const char *code, Bool_t autoexec=kTRUE); // *MENU* + void SetTree(TTree* tree); void SetTreeName(const char* treeName); // *MENU* Bool_t SwitchTree(Int_t index); void UpdateCombo(); diff --git a/tree/treeviewer/src/HelpTextTV.cxx b/tree/treeviewer/src/HelpTextTV.cxx index 81629652a9a40..86642bc59148f 100644 --- a/tree/treeviewer/src/HelpTextTV.cxx +++ b/tree/treeviewer/src/HelpTextTV.cxx @@ -163,7 +163,7 @@ changed using SetRecordName() method from the right panel context menu.\n\n\ const char gTVHelpUserCommands[] = "\ User commands can be issued directly from the textbox labeled <Command>\n\ from the upper-left toolbar by typing and pressing Enter at the end.\n\ -An other way is from the right panel context menu: ExecuteCommand.\n\n\ +Another way is from the right panel context menu: ExecuteCommand.\n\n\ All commands can be interrupted at any time by pressing the STOP button\n\ from the bottom-left.\n\n\ You can toggle recording of the current command in the history file by\n\ diff --git a/tree/treeviewer/src/TParallelCoord.cxx b/tree/treeviewer/src/TParallelCoord.cxx index 53f7dfea072e1..8bbd13f1027b4 100644 --- a/tree/treeviewer/src/TParallelCoord.cxx +++ b/tree/treeviewer/src/TParallelCoord.cxx @@ -464,7 +464,7 @@ Double_t TParallelCoord::GetGlobalMax() { // return the global maximum. - Double_t gmax=-FLT_MAX; + Double_t gmax=-DBL_MAX; TIter next(fVarList); TParallelCoordVar* var; while ((var = (TParallelCoordVar*)next())) { @@ -479,7 +479,7 @@ Double_t TParallelCoord::GetGlobalMin() { // return the global minimum. - Double_t gmin=FLT_MAX; + Double_t gmin=DBL_MAX; TIter next(fVarList); TParallelCoordVar* var; while ((var = (TParallelCoordVar*)next())) { diff --git a/tree/treeviewer/src/TParallelCoordVar.cxx b/tree/treeviewer/src/TParallelCoordVar.cxx index 4b5ee62d29e3d..87f9b878729bd 100644 --- a/tree/treeviewer/src/TParallelCoordVar.cxx +++ b/tree/treeviewer/src/TParallelCoordVar.cxx @@ -385,8 +385,8 @@ void TParallelCoordVar::GetMinMaxMean() { //Get mean, min and max of thos variable Double_t min,max,ave = 0; - min = FLT_MAX; - max = -FLT_MAX; + min = DBL_MAX; + max = -DBL_MAX; Long64_t first,nentries; first = fParallel->GetCurrentFirst(); nentries = fParallel->GetCurrentN(); diff --git a/tree/treeviewer/src/TSpider.cxx b/tree/treeviewer/src/TSpider.cxx index efe921067df78..2bb6def14de16 100644 --- a/tree/treeviewer/src/TSpider.cxx +++ b/tree/treeviewer/src/TSpider.cxx @@ -368,8 +368,8 @@ void TSpider::DeleteVariable(const char* varexp) fMax[ui-1] = fMax[ui]; fAve[ui-1] = fAve[ui]; } - fMin[fNcols-1] = FLT_MAX; - fMax[fNcols-1] = -FLT_MAX; + fMin[fNcols-1] = DBL_MAX; + fMax[fNcols-1] = -DBL_MAX; fAve[fNcols-1] = 0; --fNcols; @@ -829,8 +829,8 @@ void TSpider::InitArrays(Int_t newsize) memmin[i] = fMin[i]; memave[i] = fAve[i]; } else { - memmax[i] = -FLT_MAX; - memmin[i] = FLT_MAX; + memmax[i] = -DBL_MAX; + memmin[i] = DBL_MAX; memave[i] = 0; } } @@ -859,8 +859,8 @@ void TSpider::InitVariables(Long64_t firstentry, Long64_t nentries) fAve= new Double_t [fArraySize]; for(i=0;i<fArraySize;++i){ - fMax[i]= -FLT_MAX; - fMin[i]= FLT_MAX; + fMax[i]= -DBL_MAX; + fMin[i]= DBL_MAX; fAve[i]=0; } diff --git a/tree/treeviewer/src/TTreeViewer.cxx b/tree/treeviewer/src/TTreeViewer.cxx index 335c19d14ed0b..95216820baffb 100644 --- a/tree/treeviewer/src/TTreeViewer.cxx +++ b/tree/treeviewer/src/TTreeViewer.cxx @@ -101,7 +101,7 @@ // // User commands can be issued directly from the textbox labeled "Command" // from the upper-left toolbar by typing and pressing Enter at the end. -// An other way is from the right panel context menu : ExecuteCommand. +// Another way is from the right panel context menu : ExecuteCommand. // All commands can be interrupted at any time by pressing the STOP button // from the bottom-left // You can toggle recording of the current command in the history file by @@ -346,7 +346,7 @@ TTreeViewer::TTreeViewer(const TTree *tree) : TDirectory *cdir = tree->GetDirectory(); if (cdir) cdir->cd(); - SetTreeName(tree->GetName()); + SetTree((TTree *)tree); // If the tree is a chain, the tree directory will be changed by SwitchTree // (called by SetTreeName) cdir = tree->GetDirectory(); @@ -448,6 +448,43 @@ void TTreeViewer::SetScanRedirect(Bool_t mode) fBarScan->SetState(kButtonUp); } //______________________________________________________________________________ +void TTreeViewer::SetTree(TTree *tree) +{ + // Assign the fTree member from existing tree, e.g. when calling + // tree->StartViewer() from the browser, or even from the command line. + + if (!tree) return; + if (fTree != tree) { + fTree = tree; + // load the tree via the interpreter + // define a global "tree" variable for the same tree + TString command = TString::Format("tv__tree = (TTree *)0x%lx;", (ULong_t)tree); + ExecuteCommand(command.Data()); + } + //--- add the tree to the list if it is not already in + if (fTreeList) fTreeList->Add(fTree); + ExecuteCommand("tv__tree_list->Add(tv__tree);"); + //--- map this tree + TGListTreeItem *base = 0; + TGListTreeItem *parent = fLt->FindChildByName(base, "TreeList"); + if (!parent) parent = fLt->AddItem(base, "TreeList", new ULong_t(kLTNoType)); + ULong_t *itemType = new ULong_t((fTreeIndex << 8) | kLTTreeType); + fTreeIndex++; + TGListTreeItem *lTreeItem = fLt->AddItem(parent, tree->GetName(), itemType, + gClient->GetPicture("tree_t.xpm"), gClient->GetPicture("tree_t.xpm")); + MapTree(fTree, lTreeItem, kFALSE); + fLt->OpenItem(parent); + fLt->HighlightItem(lTreeItem); + fClient->NeedRedraw(fLt); + + //--- map slider and list view + SwitchTree(fTreeIndex-1); + fLVContainer->RemoveNonStatic(); + MapTree(fTree); + fListView->Layout(); + SetFile(); +} +//______________________________________________________________________________ void TTreeViewer::SetTreeName(const char* treeName) { // Allow geting the tree from the context menu. diff --git a/tutorials/cocoa/grad.C b/tutorials/cocoa/grad.C new file mode 100644 index 0000000000000..670a9b3a28568 --- /dev/null +++ b/tutorials/cocoa/grad.C @@ -0,0 +1,54 @@ +//This macro shows how to create and use linear gradients to fill +//a histogram or pad. +//It works ONLY on MacOS X with cocoa graphical back-end. + +//______________________________________________________________________ +void create_pad_frame_gradient() +{ + //We create a gradient with 4 steps - from dark (and semi-transparent) + //gray to almost transparent (95%) white and to white and to dark gray again. + const Double_t locations[] = {0., 0.2, 0.8, 1.}; + new TColor(1002, 0.25, 0.25, 0.25, "special pad color1", 0.55); + new TColor(1003, 1., 1., 1., "special pad color2", 0.05); + Color_t colorIndices[4] = {1002, 1003, 1003, 1002}; + new TColorGradient(1004, TColorGradient::kGDHorizontal, 4, locations, colorIndices); +} + +//______________________________________________________________________ +void create_pad_gradient() +{ + //We create two-steps gradient from ROOT's standard colors (38 and 30). + const Double_t locations[] = {0., 1.}; + Color_t colorIndices[4] = {38, 30}; + new TColorGradient(1005, TColorGradient::kGDVertical, 2, locations, colorIndices); +} + +//______________________________________________________________________ +void grad() +{ + TCanvas *cnv = new TCanvas("cnv", "gradient test", 100, 100, 600, 600); + //After canvas was created, gVirtualX should be non-null. + if (gVirtualX && !gVirtualX->InheritsFrom("TGCocoa")) { + std::cout<<"This macro works only on MacOS X with --enable-cocoa\n"; + delete cnv; + return; + } + + create_pad_frame_gradient(); + create_pad_gradient(); + + cnv->SetFillColor(1005); + cnv->SetFrameFillColor(1004); + + //Gradient to fill a histogramm + const Color_t colorIndices[3] = {kRed, kOrange, kYellow}; + const Double_t lengths[3] = {0., 0.5, 1.}; + new TColorGradient(1006, TColorGradient::kGDVertical, 3, lengths, colorIndices); + + TH1F * hist = new TH1F("a", "b", 20, -3., 3.); + hist->SetFillColor(1006); + hist->FillRandom("gaus", 100000); + hist->Draw(); + + cnv->Update(); +} diff --git a/tutorials/cocoa/grad2.C b/tutorials/cocoa/grad2.C new file mode 100644 index 0000000000000..26914bf1b3ab1 --- /dev/null +++ b/tutorials/cocoa/grad2.C @@ -0,0 +1,34 @@ +void grad2() +{ + //Gradient fill with transparency and "SAME" option. + //This macro works ONLY on MacOS X with --enable-cocoa. + + TCanvas *cnv = new TCanvas("cnv", "gradient_test", 100, 100, 800, 600); + //After canvas was created, gVirtualX should be non-null. + if (gVirtualX && !gVirtualX->InheritsFrom("TGCocoa")) { + std::cout<<"This macro works only on MacOS X with --enable-cocoa\n"; + delete cnv; + return; + } + + TH1F * hist = new TH1F("a", "b", 10, -2., 3.); + TH1F * hist2 = new TH1F("c", "d", 10, -3., 3.); + hist->FillRandom("landau", 100000); + hist2->FillRandom("gaus", 100000); + + const Double_t locations[] = {0., 1.}; + new TColor(1001, 1., 0., 0., "red", 0.5); + const Color_t idx1[] = {kOrange, 1001}; + //Gradient from ROOT's kOrange and my own semi-transparent red color. + new TColorGradient(1002, TColorGradient::kGDVertical, 2, locations, idx1); + hist->SetFillColor(1002); + + new TColor(1003, 0., 1., 0., "green", 0.5); + const Color_t idx2[] = {kBlue, 1003}; + //Gradient from ROOT's kBlue and my own semi-transparent green color. + new TColorGradient(1004, TColorGradient::kGDVertical, 2, locations, idx2); + hist2->SetFillColor(1004); + + hist2->Draw(); + hist->Draw("SAME"); +} diff --git a/tutorials/cocoa/parallelcoordtrans.C b/tutorials/cocoa/parallelcoordtrans.C new file mode 100644 index 0000000000000..a8c8b7406568f --- /dev/null +++ b/tutorials/cocoa/parallelcoordtrans.C @@ -0,0 +1,112 @@ +// Script illustrating the use of transparency with ||-Coord. +// It displays the same data set twice. The first time without transparency and +// the second time with transparency. On the second plot, several clusters +// appear. +//Authors: Olivier Couet (original macro), adapted for TGCocoa by Timur Pocheptsov. + + +Double_t r1,r2,r3,r4,r5,r6,r7,r8,r9; +Double_t dr = 3.5; +TRandom *r; + +void generate_random(Int_t i) { + r->Rannor(r1,r4); + r->Rannor(r7,r9); + r2 = (2*dr*r->Rndm(i))-dr; + r3 = (2*dr*r->Rndm(i))-dr; + r5 = (2*dr*r->Rndm(i))-dr; + r6 = (2*dr*r->Rndm(i))-dr; + r8 = (2*dr*r->Rndm(i))-dr; +} + +void parallelcoordtrans() { + + + Double_t x,y,z,u,v,w,a,b,c; + Double_t s1x, s1y, s1z; + Double_t s2x, s2y, s2z; + Double_t s3x, s3y, s3z; + r = new TRandom();; + + TCanvas *c1 = new TCanvas("c1", "c1",0,0,900,1000); + c1->Divide(1,2); + + if (gVirtualX && !gVirtualX->InheritsFrom("TGCocoa")) { + std::cout<<"This macro works only on MacOS X with --enable-cocoa\n"; + delete c1; + delete r; + return; + } + + TNtuple *nt = new TNtuple("nt","Demo ntuple","x:y:z:u:v:w:a:b:c"); + + int n=0; + for (Int_t i=0; i<1500; i++) { + r->Sphere(s1x, s1y, s1z, 0.1); + r->Sphere(s2x, s2y, s2z, 0.2); + r->Sphere(s3x, s3y, s3z, 0.05); + + generate_random(i); + nt->Fill(r1, r2, r3, r4, r5, r6, r7, r8, r9); + n++; + + generate_random(i); + nt->Fill(s1x, s1y, s1z, s2x, s2y, s2z, r7, r8, r9); + n++; + + generate_random(i); + nt->Fill(r1, r2, r3, r4, r5, r6, r7, s3y, r9); + n++; + + generate_random(i); + nt->Fill(s2x-1, s2y-1, s2z, s1x+.5, s1y+.5, s1z+.5, r7, r8, r9); + n++; + + generate_random(i); + nt->Fill(r1, r2, r3, r4, r5, r6, r7, r8, r9); + n++; + + generate_random(i); + nt->Fill(s1x+1, s1y+1, s1z+1, s3x-2, s3y-2, s3z-2, r7, r8, r9); + n++; + + generate_random(i); + nt->Fill(r1, r2, r3, r4, r5, r6, s3x, r8, s3z ); + n++; + } + + TParallelCoordVar* pcv; + + c1->cd(1); + + // ||-Coord plot without transparency + nt->Draw("x:y:z:u:v:w:a:b:c","","para"); + TParallelCoord* para1 = (TParallelCoord*)gPad->GetListOfPrimitives()->FindObject("ParaCoord"); + para1->SetLineColor(25); + pcv = (TParallelCoordVar*)para1->GetVarList()->FindObject("x"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para1->GetVarList()->FindObject("y"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para1->GetVarList()->FindObject("z"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para1->GetVarList()->FindObject("a"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para1->GetVarList()->FindObject("b"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para1->GetVarList()->FindObject("c"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para1->GetVarList()->FindObject("u"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para1->GetVarList()->FindObject("v"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para1->GetVarList()->FindObject("w"); pcv->SetHistogramHeight(0.); + + + // ||-Coord plot with transparency + TColor *col26 = gROOT->GetColor(26); col26->SetAlpha(0.01); + c1->cd(2); + nt->Draw("x:y:z:u:v:w:a:b:c","","para"); + TParallelCoord* para2 = (TParallelCoord*)gPad->GetListOfPrimitives()->FindObject("ParaCoord"); + para2->SetLineColor(26); + pcv = (TParallelCoordVar*)para2->GetVarList()->FindObject("x"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para2->GetVarList()->FindObject("y"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para2->GetVarList()->FindObject("z"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para2->GetVarList()->FindObject("a"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para2->GetVarList()->FindObject("b"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para2->GetVarList()->FindObject("c"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para2->GetVarList()->FindObject("u"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para2->GetVarList()->FindObject("v"); pcv->SetHistogramHeight(0.); + pcv = (TParallelCoordVar*)para2->GetVarList()->FindObject("w"); pcv->SetHistogramHeight(0.); +} diff --git a/tutorials/cocoa/transp.C b/tutorials/cocoa/transp.C new file mode 100644 index 0000000000000..5f47bfa660dc5 --- /dev/null +++ b/tutorials/cocoa/transp.C @@ -0,0 +1,38 @@ +void transp() +{ + //This demo shows, how to use transparency. + //On MacOS X you can see the transparency in a canvas, + //you can save canvas contents as pdf/png + //(and thus you'll have an image with transparency on every platform. + + //Unfortunately, these transparent colors can + //not be saved with a histogram object in a file, + //since ROOT just save color indices and our transparent + //colors were created/added "on the fly". + + TCanvas * cnv = new TCanvas("trasnparency", "transparency demo", 600, 400); + + //After we created a canvas, gVirtualX in principle should be initialized + //and we can check its type: + if (gVirtualX && !gVirtualX->InheritsFrom("TGCocoa")) { + std::cout<<"You can see the transparency ONLY in a pdf or png output (\"File\"->\"Save As\" ->...)\n" + "To have transparency in a canvas graphics, you need MacOSX version with cocoa enabled\n"; + } + + TH1F * hist = new TH1F("a", "b", 10, -2., 3.); + TH1F * hist2 = new TH1F("c", "d", 10, -3., 3.); + hist->FillRandom("landau", 100000); + hist2->FillRandom("gaus", 100000); + + //Add new color with index 1001. + new TColor(1001, 1., 0., 0., "red", 0.85); + hist->SetFillColor(1001); + + //Add new color with index 1002. + new TColor(1002, 0., 1., 0., "green", 0.5); + hist2->SetFillColor(1002); + + cnv->cd(); + hist2->Draw(); + hist->Draw("SAME"); +} \ No newline at end of file diff --git a/tutorials/cocoa/transp_text.C b/tutorials/cocoa/transp_text.C new file mode 100644 index 0000000000000..3b4f4da7d1dde --- /dev/null +++ b/tutorials/cocoa/transp_text.C @@ -0,0 +1,47 @@ +//This macro is based on labels1.C by Rene Brun. +//Updated by Timur Pocheptsov to use transparent text. + + +void transp_text() +{ + TCanvas *c1 = new TCanvas("c1","transparent text demo", 10, 10, 900, 500); + + //After we created a canvas, gVirtualX in principle should be initialized + //and we can check its type: + if (gVirtualX && !gVirtualX->InheritsFrom("TGCocoa")) { + std::cout<<"You can see the transparency ONLY in a pdf or png output (\"File\"->\"Save As\" ->...)\n" + "To have transparency in a canvas graphics, you need MacOSX version with cocoa enabled\n"; + } + + const Int_t nx = 20; + char *people[nx] = {"Jean","Pierre","Marie","Odile", + "Sebastien","Fons","Rene","Nicolas","Xavier","Greg", + "Bjarne","Anton","Otto","Eddy","Peter","Pasha", + "Philippe","Suzanne","Jeff","Valery"}; + c1->SetGrid(); + c1->SetBottomMargin(0.15); + TH1F *h = new TH1F("h","test",nx,0,nx); + h->SetFillColor(38); + for (Int_t i=0;i<5000;i++) { + h->Fill(gRandom->Gaus(0.5*nx,0.2*nx)); + } + h->SetStats(0); + for (i=1;i<=nx;i++) { + h->GetXaxis()->SetBinLabel(i,people[i-1]); + } + h->Draw(); + + TPaveText *pt = new TPaveText(0.3,0.3,0.98,0.98,"brNDC"); + + //Create special transparent colors for both pavetext fill color and text color. + new TColor(1001, 0.8, 0.8, 0.8, "transparent_gray", 0.85); + pt->SetFillColor(1001); + //Add new color with index 1002. + new TColor(1002, 0., 0., 0., "transparent_black", 0.5); + pt->SetTextColor(1002); + pt->SetTextSize(0.5); + pt->SetTextAlign(12); + + pt->AddText("Hello"); + pt->Draw(); +} diff --git a/tutorials/doc/v534/index.html b/tutorials/doc/v534/index.html index 1f60f50c58b7a..f5b1558272435 100644 --- a/tutorials/doc/v534/index.html +++ b/tutorials/doc/v534/index.html @@ -2,3 +2,7 @@ <hr/> <a name="tutorials"></a> <h3>Tutorials</h3> +<ul> +<li>The new tutorial timeonaxis3.C test the time axis.</li> +<li>New version of cernbluid.C allowing to turn off the printouts.</li> +</ul> diff --git a/tutorials/eve/SplitGLView.C b/tutorials/eve/SplitGLView.C index 09f967a4a3ca3..24eba4ec7a0d1 100644 --- a/tutorials/eve/SplitGLView.C +++ b/tutorials/eve/SplitGLView.C @@ -1104,7 +1104,7 @@ void SplitGLView::OnMouseOver(TGLPhysicalShape *shape) // Slot used to handle "OnMouseOver" signal coming from any GL viewer. // We receive a pointer on the physical shape in which the mouse cursor is. - // display informations on the physical shape in the status bar + // display information on the physical shape in the status bar if (shape && shape->GetLogical() && shape->GetLogical()->GetExternal()) fStatusBar->SetText(Form("Mouse Over: \"%s\"", shape->GetLogical()->GetExternal()->GetName()), 0); diff --git a/tutorials/eve/camera_restore.C b/tutorials/eve/camera_restore.C new file mode 100644 index 0000000000000..b6e8b06b70f32 --- /dev/null +++ b/tutorials/eve/camera_restore.C @@ -0,0 +1,28 @@ +void camera_restore(const char* fname, int mode = 0) +{ + TEveManager::Create(); + writeCurrentCamera(fname); +} + +void writeCurrentCamera(const char* fname) +{ + TGLCamera& c = gEve->GetDefaultGLViewer()->CurrentCamera(); + TFile* f = TFile::Open(fname, "RECREATE"); + c.Write(); + f->Close(); +} + + +void readCurrentCamera(const char* fname) +{ + TGLCamera& c = gEve->GetDefaultGLViewer()->CurrentCamera(); + TFile* f = TFile::Open(fname, "READ"); + if (!f) + return; + + if (f->GetKey(c.ClassName())) { + f->GetKey(c.ClassName())->Read(&c); + c.IncTimeStamp(); + gEve->GetDefaultGLViewer()->RequestDraw(); + } +} diff --git a/tutorials/fitsio/FITS_tutorial6.C b/tutorials/fitsio/FITS_tutorial6.C new file mode 100644 index 0000000000000..458d680f44099 --- /dev/null +++ b/tutorials/fitsio/FITS_tutorial6.C @@ -0,0 +1,31 @@ +// Open a FITS file whose primary array represents +// a spectrum table (flux vs wavelength) and dump its columns +void FITS_tutorial6() +{ + TVectorD *v; + + printf("\n\n--------------------------------\n"); + printf("WELCOME TO FITS tutorial #6 !!!!\n"); + printf("--------------------------------\n"); + printf("We are going to open a table from a FITS file\n"); + printf("and dump its columns.\n\n"); + + + //Open the table + TFITSHDU *hdu = new TFITSHDU("sample4.fits[1]"); + if (hdu == 0) { + printf("ERROR: could not access the HDU\n"); return; + } + + //Show columns + Int_t nColumns = hdu->GetTabNColumns(); + printf("The table has %d columns:\n", nColumns); + for (Int_t i = 0; i < nColumns; i++) { + printf("...Column %d: %s\n", i, hdu->GetColumnName(i).Data()); + } + puts(""); + + delete hdu; +} + + diff --git a/tutorials/geom/robot.C b/tutorials/geom/robot.C index 32ebdfcd32273..13b17ca87fcb8 100644 --- a/tutorials/geom/robot.C +++ b/tutorials/geom/robot.C @@ -438,13 +438,13 @@ for (int i=1; i<20; i+=1) { Effect->SetFillColor(9); top->AddNodeOverlap(Effect,1,new TGeoTranslation(3,0,-280)); } - if (6<i<10) { + if (6<i && i<10) { TGeoVolume *Effect=Robot->MakeCons("Effect",Iron,5,20/sin(i),21/sin(i),20/sin(i),21/sin(i),50,120); Effect->SetLineColor(38); Effect->SetFillColor(38); top->AddNodeOverlap(Effect,1,new TGeoTranslation(3,0,-280)); } - if (9<i<20) { + if (9<i && i<20) { TGeoVolume *Effect=Robot->MakeCons("Effect",Iron,4,20/sin(i),21/sin(i),20/sin(i),21/sin(i),200,330); Effect->SetLineColor(33); Effect->SetFillColor(33); diff --git a/tutorials/geom/rootgeom.C b/tutorials/geom/rootgeom.C index 22125779bbd92..919cabaaf049e 100644 --- a/tutorials/geom/rootgeom.C +++ b/tutorials/geom/rootgeom.C @@ -10,7 +10,7 @@ void rootgeom() //--- define some materials TGeoMaterial *matVacuum = new TGeoMaterial("Vacuum", 0,0,0); TGeoMaterial *matAl = new TGeoMaterial("Al", 26.98,13,2.7); -// //--- define some media + //--- define some media TGeoMedium *Vacuum = new TGeoMedium("Vacuum",1, matVacuum); TGeoMedium *Al = new TGeoMedium("Root Material",2, matAl); diff --git a/tutorials/geom/xtruSamples.C b/tutorials/geom/xtruSamples.C index 860f41fe11153..e4867ad6d6d5b 100644 --- a/tutorials/geom/xtruSamples.C +++ b/tutorials/geom/xtruSamples.C @@ -25,7 +25,7 @@ void xtruSamples() geom->cd(); // Define the complexity of the drawing - Float_t zseg = 6; // either 2 or 6 + Int_t zseg = 6; // either 2 or 6 Int_t extravis = 0; // make extra z "arrow" visible Float_t unit = 1; @@ -58,7 +58,7 @@ void xtruSamples() for (Int_t xycase = 0; xycase<3; xycase++) { if (xycase == 1 && !domalformed) continue; - Char_t *name = "txtruXYZ"; + char name[9]; sprintf(name,"txtru%1d%1d%1d",xycase,zcase,zseg); TXTRU* mytxtru = new TXTRU(name,name,"void",8,2); diff --git a/tutorials/graphics/canvas2.C b/tutorials/graphics/canvas2.C new file mode 100644 index 0000000000000..17af9aa1d3d4e --- /dev/null +++ b/tutorials/graphics/canvas2.C @@ -0,0 +1,181 @@ +void canvas2() +{ +//Example of canvas partitioning +// Sometimes the Divide() method is not appropriate to divide a Canvas. +// Because of the left and right margins, all the pads do not have the +// same width and height. CanvasPartition does that properly. This +// example also ensure that the axis labels and titles have the same +// sizes and that the tick marks length is uniform. +//Author: + + gStyle->SetOptStat(0); + + TCanvas *C = (TCanvas*) gROOT->FindObject("C"); + if (C) delete C; + C = new TCanvas("C","canvas",1024,640); + C->SetFillStyle(4000); + + // Number of PADS + const Int_t Nx = 5; + const Int_t Ny = 5; + + // Margins + Float_t lMargin = 0.12; + Float_t rMargin = 0.05; + Float_t bMargin = 0.15; + Float_t tMargin = 0.05; + + // Canvas setup + CanvasPartition(C,Nx,Ny,lMargin,rMargin,bMargin,tMargin); + + // Dummy histogram. + TH1F *h = (TH1F*) gROOT->FindObject("histo"); + if (h) delete h; + h = new TH1F("histo","",100,-5.0,5.0); + h->FillRandom("gaus",10000); + h->GetXaxis()->SetTitle("x axis"); + h->GetYaxis()->SetTitle("y axis"); + + TPad *pad[Nx][Ny]; + + for (Int_t i=0;i<Nx;i++) { + for (Int_t j=0;j<Ny;j++) { + C->cd(0); + + // Get the pads previosly created. + char pname[16]; + sprintf(pname,"pad_%i_%i",i,j); + pad[i][j] = (TPad*) gROOT->FindObject(pname); + pad[i][j]->Draw(); + pad[i][j]->SetFillStyle(4000); + pad[i][j]->SetFrameFillStyle(4000); + pad[i][j]->cd(); + + // Size factors + Float_t xFactor = pad[0][0]->GetAbsWNDC()/pad[i][j]->GetAbsWNDC(); + Float_t yFactor = pad[0][0]->GetAbsHNDC()/pad[i][j]->GetAbsHNDC(); + + char hname[16]; + sprintf(hname,"h_%i_%i",i,j); + TH1F *hFrame = (TH1F*) h->Clone(hname); + hFrame->Reset(); + hFrame->Draw(); + + // y axis range + hFrame->GetYaxis()->SetRangeUser(0.0001,1.2*h->GetMaximum()); + + // Format for y axis + hFrame->GetYaxis()->SetLabelFont(43); + hFrame->GetYaxis()->SetLabelSize(16); + hFrame->GetYaxis()->SetLabelOffset(0.02); + hFrame->GetYaxis()->SetTitleFont(43); + hFrame->GetYaxis()->SetTitleSize(16); + hFrame->GetYaxis()->SetTitleOffset(5); + + hFrame->GetYaxis()->CenterTitle(); + hFrame->GetYaxis()->SetNdivisions(505); + + // TICKS Y Axis + hFrame->GetYaxis()->SetTickLength(xFactor*0.04/yFactor); + + // Format for x axis + hFrame->GetXaxis()->SetLabelFont(43); + hFrame->GetXaxis()->SetLabelSize(16); + hFrame->GetXaxis()->SetLabelOffset(0.02); + hFrame->GetXaxis()->SetTitleFont(43); + hFrame->GetXaxis()->SetTitleSize(16); + hFrame->GetXaxis()->SetTitleOffset(5); + hFrame->GetXaxis()->CenterTitle(); + hFrame->GetXaxis()->SetNdivisions(505); + + // TICKS X Axis + hFrame->GetXaxis()->SetTickLength(yFactor*0.06/xFactor); + + h->Draw("same"); + } + } + C->cd(); +} + + + +void CanvasPartition(TCanvas *C,const Int_t Nx = 2,const Int_t Ny = 2, + Float_t lMargin = 0.15, Float_t rMargin = 0.05, + Float_t bMargin = 0.15, Float_t tMargin = 0.05) +{ + if (!C) return; + + // Setup Pad layout: + Float_t vSpacing = 0.0; + Float_t vStep = (1.- bMargin - tMargin - (Ny-1) * vSpacing) / Ny; + + Float_t hSpacing = 0.0; + Float_t hStep = (1.- lMargin - rMargin - (Nx-1) * hSpacing) / Nx; + + Float_t vposd,vposu,vmard,vmaru,vfactor; + Float_t hposl,hposr,hmarl,hmarr,hfactor; + + for (Int_t i=0;i<Nx;i++) { + + if (i==0) { + hposl = 0.0; + hposr = lMargin + hStep; + hfactor = hposr-hposl; + hmarl = lMargin / hfactor; + hmarr = 0.0; + } else if (i == Nx-1) { + hposl = hposr + hSpacing; + hposr = hposl + hStep + rMargin; + hfactor = hposr-hposl; + hmarl = 0.0; + hmarr = rMargin / (hposr-hposl); + } else { + hposl = hposr + hSpacing; + hposr = hposl + hStep; + hfactor = hposr-hposl; + hmarl = 0.0; + hmarr = 0.0; + } + + for (Int_t j=0;j<Ny;j++) { + + if (j==0) { + vposd = 0.0; + vposu = bMargin + vStep; + vfactor = vposu-vposd; + vmard = bMargin / vfactor; + vmaru = 0.0; + } else if (j == Ny-1) { + vposd = vposu + vSpacing; + vposu = vposd + vStep + tMargin; + vfactor = vposu-vposd; + vmard = 0.0; + vmaru = tMargin / (vposu-vposd); + } else { + vposd = vposu + vSpacing; + vposu = vposd + vStep; + vfactor = vposu-vposd; + vmard = 0.0; + vmaru = 0.0; + } + + C->cd(0); + + char name[16]; + sprintf(name,"pad_%i_%i",i,j); + TPad *pad = (TPad*) gROOT->FindObject(name); + if (pad) delete pad; + pad = new TPad(name,"",hposl,vposd,hposr,vposu); + pad->SetLeftMargin(hmarl); + pad->SetRightMargin(hmarr); + pad->SetBottomMargin(vmard); + pad->SetTopMargin(vmaru); + + pad->SetFrameBorderMode(0); + pad->SetBorderMode(0); + pad->SetBorderSize(0); + + pad->Draw(); + } + } +} diff --git a/tutorials/graphics/piechart.C b/tutorials/graphics/piechart.C index 74d5556d9431c..86fb296797808 100644 --- a/tutorials/graphics/piechart.C +++ b/tutorials/graphics/piechart.C @@ -32,7 +32,7 @@ void piechart() pie2->SetEntryLineStyle(2,2); pie2->SetEntryFillStyle(1,3030); pie2->SetCircle(.5,.45,.3); - pie2->Draw("r"); + pie2->Draw("rsc"); cpie->cd(3); pie3->SetY(.32); diff --git a/tutorials/graphics/tmathtext.C b/tutorials/graphics/tmathtext.C new file mode 100644 index 0000000000000..bc8a9b1104018 --- /dev/null +++ b/tutorials/graphics/tmathtext.C @@ -0,0 +1,27 @@ +// This macro draws various formula in a canvas and prints the canvas +// as a Postscript file using TMathText. +//Author: Yue Shi Lai + +{ + TCanvas *c1 = new TCanvas("c1"); + + TMathText l; + l.SetTextAlign(23); + l.SetTextSize(0.06); + l.DrawMathText(0.50, 1.000, "\\prod_{j\\ge0} \\left(\\sum_{k\\ge0} a_{jk}z^k\\right) = \\sum_{n\\ge0} z^n \\left(\\sum_{k_0,k_1,\\ldots\\ge0\\atop k_0+k_1+\\cdots=n} a_{0k_0}a_{1k_1} \\cdots \\right)"); + l.DrawMathText(0.50, 0.800, "W_{\\delta_1\\rho_1\\sigma_2}^{3\\beta} = U_{\\delta_1\\rho_1\\sigma_2}^{3\\beta} + {1\\over 8\\pi^2} \\int_{\\alpha_1}^{\\alpha_2} d\\alpha_2^\\prime \\left[ {U_{\\delta_1\\rho_1}^{2\\beta} - \\alpha_2^\\prime U_{\\rho_1\\sigma_2}^{1\\beta} \\over U_{\\rho_1\\sigma_2}^{0\\beta}} \\right]"); + l.DrawMathText(0.50, 0.600, "d\\Gamma = {1\\over 2m_A} \\left( \\prod_f {d^3p_f\\over (2\\pi)^3} {1\\over 2E_f} \\right) \\left| \\mathscr{M} \\left(m_A - \\left\\{p_f\\right\\} \\right) \\right|^2 (2\\pi)^4 \\delta^{(4)} \\left(p_A - \\sum p_f \\right)"); + l.DrawMathText(0.50, 0.425, "4\\mathrm{Re}\\left\\{{2\\over 1-\\Delta\\alpha} \\chi(s) \\left[ \\^{g}_\\nu^e \\^{g}_\\nu^f (1 + \\cos^2\\theta) + \\^{g}_a^e \\^{g}_a^f \\cos\\theta \\right] \\right\\}"); + l.DrawMathText(0.50, 0.330, "p(n) = {1\\over\\pi\\sqrt{2}} \\sum_{k = 1}^\\infty \\sqrt{k} A_k(n) {d\\over dn} {\\sinh \\left\\{ {\\pi\\over k} \\sqrt{2\\over 3} \\sqrt{n - {1\\over 24}} \\right\\} \\over \\sqrt{n - {1\\over 24}}}"); + l.DrawMathText(0.13, 0.150, "{(\\ell+1)C_{\\ell}^{TE} \\over 2\\pi}"); + l.DrawMathText(0.27, 0.110, "\\mathbb{N} \\subset \\mathbb{R}"); + l.DrawMathText(0.63, 0.100, "\\hbox{RHIC スピン物理 Нью-Йорк}"); + + c1->Print("c1.gif"); + c1->Print("c1.jpg"); + c1->Print("c1.png"); + c1->Print("c1.ps"); + c1->Print("c1.eps"); + + return c1; +} diff --git a/tutorials/graphics/tmathtext2.C b/tutorials/graphics/tmathtext2.C new file mode 100644 index 0000000000000..0028932008d98 --- /dev/null +++ b/tutorials/graphics/tmathtext2.C @@ -0,0 +1,652 @@ +// This macro draw all possible symbols provided by TMathtext +//Author: Olivier Couet + +{ + TCanvas *c1 = new TCanvas("mathtext","TMathText symbol",1200,1400); + + TMathText l; + l.SetTextSize(0.013); + l.SetTextFont(132); + + // Draw 1st Column + l.SetTextAlign(12); + float y, step, x1, x2; + y = 0.99; step = 0.0126; x1 = 0.01; x2 = x1+0.02; + l.DrawMathText(x1, y, "\\\""); l.DrawText(x2, y, "\\\""); + y -= step ; l.DrawMathText(x1, y, "\\'"); l.DrawText(x2, y, "\\'"); + y -= step ; l.DrawMathText(x1, y, "\\."); l.DrawText(x2, y, "\\."); + y -= step ; l.DrawMathText(x1, y, "\\="); l.DrawText(x2, y, "\\="); + y -= step ; l.DrawMathText(x1, y, "\\Box"); l.DrawText(x2, y, "\\Box"); + y -= step ; l.DrawMathText(x1, y, "\\Bumpeq"); l.DrawText(x2, y, "\\Bumpeq"); + y -= step ; l.DrawMathText(x1, y, "\\Cap"); l.DrawText(x2, y, "\\Cap"); + y -= step ; l.DrawMathText(x1, y, "\\Cup"); l.DrawText(x2, y, "\\Cup"); + y -= step ; l.DrawMathText(x1, y, "\\Delta"); l.DrawText(x2, y, "\\Delta"); + y -= step ; l.DrawMathText(x1, y, "\\Diamond"); l.DrawText(x2, y, "\\Diamond"); + y -= step ; l.DrawMathText(x1, y, "\\Digamma"); l.DrawText(x2, y, "\\Digamma"); + y -= step ; l.DrawMathText(x1, y, "\\Doteq"); l.DrawText(x2, y, "\\Doteq"); + y -= step ; l.DrawMathText(x1, y, "\\Downarrow"); l.DrawText(x2, y, "\\Downarrow"); + y -= step ; l.DrawMathText(x1, y, "\\Finv"); l.DrawText(x2, y, "\\Finv"); + y -= step ; l.DrawMathText(x1, y, "\\Game"); l.DrawText(x2, y, "\\Game"); + y -= step ; l.DrawMathText(x1, y, "\\Gamma"); l.DrawText(x2, y, "\\Gamma"); + y -= step ; l.DrawMathText(x1, y, "\\Im"); l.DrawText(x2, y, "\\Im"); + y -= step ; l.DrawMathText(x1, y, "\\Koppa"); l.DrawText(x2, y, "\\Koppa"); + y -= step ; l.DrawMathText(x1, y, "\\Lambda"); l.DrawText(x2, y, "\\Lambda"); + y -= step ; l.DrawMathText(x1, y, "\\Leftarrow"); l.DrawText(x2, y, "\\Leftarrow"); + y -= step ; l.DrawMathText(x1, y, "\\Leftrightarrow"); l.DrawText(x2, y, "\\Leftrightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\Lleftarrow"); l.DrawText(x2, y, "\\Lleftarrow"); + y -= step ; l.DrawMathText(x1, y, "\\Longleftarrow"); l.DrawText(x2, y, "\\Longleftarrow"); + y -= step ; l.DrawMathText(x1, y, "\\Longleftrightarrow"); l.DrawText(x2, y, "\\Longleftrightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\Longrightarrow"); l.DrawText(x2, y, "\\Longrightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\Lsh"); l.DrawText(x2, y, "\\Lsh"); + y -= step ; l.DrawMathText(x1, y, "\\Omega"); l.DrawText(x2, y, "\\Omega"); + y -= step ; l.DrawMathText(x1, y, "\\P"); l.DrawText(x2, y, "\\P"); + y -= step ; l.DrawMathText(x1, y, "\\Phi"); l.DrawText(x2, y, "\\Phi"); + y -= step ; l.DrawMathText(x1, y, "\\Pi"); l.DrawText(x2, y, "\\Pi"); + y -= step ; l.DrawMathText(x1, y, "\\Psi"); l.DrawText(x2, y, "\\Psi"); + y -= step ; l.DrawMathText(x1, y, "\\Re"); l.DrawText(x2, y, "\\Re"); + y -= step ; l.DrawMathText(x1, y, "\\Rightarrow"); l.DrawText(x2, y, "\\Rightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\Rrightarrow"); l.DrawText(x2, y, "\\Rrightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\Rsh"); l.DrawText(x2, y, "\\Rsh"); + y -= step ; l.DrawMathText(x1, y, "\\S"); l.DrawText(x2, y, "\\S"); + y -= step ; l.DrawMathText(x1, y, "\\Sampi"); l.DrawText(x2, y, "\\Sampi"); + y -= step ; l.DrawMathText(x1, y, "\\San"); l.DrawText(x2, y, "\\San"); + y -= step ; l.DrawMathText(x1, y, "\\Sho"); l.DrawText(x2, y, "\\Sho"); + y -= step ; l.DrawMathText(x1, y, "\\Sigma"); l.DrawText(x2, y, "\\Sigma"); + y -= step ; l.DrawMathText(x1, y, "\\Stigma"); l.DrawText(x2, y, "\\Stigma"); + y -= step ; l.DrawMathText(x1, y, "\\Subset"); l.DrawText(x2, y, "\\Subset"); + y -= step ; l.DrawMathText(x1, y, "\\Supset"); l.DrawText(x2, y, "\\Supset"); + y -= step ; l.DrawMathText(x1, y, "\\Theta"); l.DrawText(x2, y, "\\Theta"); + y -= step ; l.DrawMathText(x1, y, "\\Uparrow"); l.DrawText(x2, y, "\\Uparrow"); + y -= step ; l.DrawMathText(x1, y, "\\Updownarrow"); l.DrawText(x2, y, "\\Updownarrow"); + y -= step ; l.DrawMathText(x1, y, "\\Upsilon"); l.DrawText(x2, y, "\\Upsilon"); + y -= step ; l.DrawMathText(x1, y, "\\VarKoppa"); l.DrawText(x2, y, "\\VarKoppa"); + y -= step ; l.DrawMathText(x1, y, "\\Vdash"); l.DrawText(x2, y, "\\Vdash"); + y -= step ; l.DrawMathText(x1, y, "\\Vert"); l.DrawText(x2, y, "\\Vert"); + y -= step ; l.DrawMathText(x1, y, "\\Vvdash"); l.DrawText(x2, y, "\\Vvdash"); + y -= step ; l.DrawMathText(x1, y, "\\Xi"); l.DrawText(x2, y, "\\Xi"); + y -= step ; l.DrawMathText(x1, y, "\\^"); l.DrawText(x2, y, "\\^"); + y -= step ; l.DrawMathText(x1, y, "\\`"); l.DrawText(x2, y, "\\`"); + y -= step ; l.DrawMathText(x1, y, "\\aa"); l.DrawText(x2, y, "\\aa"); + y -= step ; l.DrawMathText(x1, y, "\\aleph"); l.DrawText(x2, y, "\\aleph"); + y -= step ; l.DrawMathText(x1, y, "\\alpha"); l.DrawText(x2, y, "\\alpha"); + y -= step ; l.DrawMathText(x1, y, "\\angle"); l.DrawText(x2, y, "\\angle"); + y -= step ; l.DrawMathText(x1, y, "\\approx"); l.DrawText(x2, y, "\\approx"); + y -= step ; l.DrawMathText(x1, y, "\\approxeq"); l.DrawText(x2, y, "\\approxeq"); + y -= step ; l.DrawMathText(x1, y, "\\asymp"); l.DrawText(x2, y, "\\asymp"); + y -= step ; l.DrawMathText(x1, y, "\\backepsilon"); l.DrawText(x2, y, "\\backepsilon"); + y -= step ; l.DrawMathText(x1, y, "\\backprime"); l.DrawText(x2, y, "\\backprime"); + y -= step ; l.DrawMathText(x1, y, "\\backsim"); l.DrawText(x2, y, "\\backsim"); + y -= step ; l.DrawMathText(x1, y, "\\backsimeq"); l.DrawText(x2, y, "\\backsimeq"); + y -= step ; l.DrawMathText(x1, y, "\\backslash"); l.DrawText(x2, y, "\\backslash"); + y -= step ; l.DrawMathText(x1, y, "\\barwedge"); l.DrawText(x2, y, "\\barwedge"); + y -= step ; l.DrawMathText(x1, y, "\\because"); l.DrawText(x2, y, "\\because"); + y -= step ; l.DrawMathText(x1, y, "\\beta"); l.DrawText(x2, y, "\\beta"); + y -= step ; l.DrawMathText(x1, y, "\\beth"); l.DrawText(x2, y, "\\beth"); + y -= step ; l.DrawMathText(x1, y, "\\between"); l.DrawText(x2, y, "\\between"); + y -= step ; l.DrawMathText(x1, y, "\\bigcirc"); l.DrawText(x2, y, "\\bigcirc"); + y -= step ; l.DrawMathText(x1, y, "\\bigstar"); l.DrawText(x2, y, "\\bigstar"); + y -= step ; l.DrawMathText(x1, y, "\\bigtriangledown"); l.DrawText(x2, y, "\\bigtriangledown"); + y -= step ; l.DrawMathText(x1, y, "\\bigtriangleup"); l.DrawText(x2, y, "\\bigtriangleup"); + y -= step ; l.DrawMathText(x1, y, "\\blacklozenge"); l.DrawText(x2, y, "\\blacklozenge"); + y -= step ; l.DrawMathText(x1, y, "\\blacksquare"); l.DrawText(x2, y, "\\blacksquare"); + y -= step ; l.DrawMathText(x1, y, "\\blacktriangle"); l.DrawText(x2, y, "\\blacktriangle"); + y -= step ; l.DrawMathText(x1, y, "\\blacktriangledown"); l.DrawText(x2, y, "\\blacktriangledown"); + + // Draw 2nd Column + y = 0.99; step = 0.0126; x1 = 0.14; x2 = x1+0.02; + l.DrawMathText(x1, y, "\\blacktriangleleft"); l.DrawText(x2, y, "\\blacktriangleleft"); + y -= step ; l.DrawMathText(x1, y, "\\blacktriangleright"); l.DrawText(x2, y, "\\blacktriangleright"); + y -= step ; l.DrawMathText(x1, y, "\\bowtie"); l.DrawText(x2, y, "\\bowtie"); + y -= step ; l.DrawMathText(x1, y, "\\boxdot"); l.DrawText(x2, y, "\\boxdot"); + y -= step ; l.DrawMathText(x1, y, "\\boxminus"); l.DrawText(x2, y, "\\boxminus"); + y -= step ; l.DrawMathText(x1, y, "\\boxplus"); l.DrawText(x2, y, "\\boxplus"); + y -= step ; l.DrawMathText(x1, y, "\\boxtimes"); l.DrawText(x2, y, "\\boxtimes"); + y -= step ; l.DrawMathText(x1, y, "\\bullet"); l.DrawText(x2, y, "\\bullet"); + y -= step ; l.DrawMathText(x1, y, "\\bulletdashcirc"); l.DrawText(x2, y, "\\bulletdashcirc"); + y -= step ; l.DrawMathText(x1, y, "\\bumpeq"); l.DrawText(x2, y, "\\bumpeq"); + y -= step ; l.DrawMathText(x1, y, "\\cap"); l.DrawText(x2, y, "\\cap"); + y -= step ; l.DrawMathText(x1, y, "\\cdot"); l.DrawText(x2, y, "\\cdot"); + y -= step ; l.DrawMathText(x1, y, "\\cdots"); l.DrawText(x2, y, "\\cdots"); + y -= step ; l.DrawMathText(x1, y, "\\centerdot"); l.DrawText(x2, y, "\\centerdot"); + y -= step ; l.DrawMathText(x1, y, "\\checkmark"); l.DrawText(x2, y, "\\checkmark"); + y -= step ; l.DrawMathText(x1, y, "\\chi"); l.DrawText(x2, y, "\\chi"); + y -= step ; l.DrawMathText(x1, y, "\\circ"); l.DrawText(x2, y, "\\circ"); + y -= step ; l.DrawMathText(x1, y, "\\circdashbullet"); l.DrawText(x2, y, "\\circdashbullet"); + y -= step ; l.DrawMathText(x1, y, "\\circeq"); l.DrawText(x2, y, "\\circeq"); + y -= step ; l.DrawMathText(x1, y, "\\circlearrowleft"); l.DrawText(x2, y, "\\circlearrowleft"); + y -= step ; l.DrawMathText(x1, y, "\\circlearrowright"); l.DrawText(x2, y, "\\circlearrowright"); + y -= step ; l.DrawMathText(x1, y, "\\circledR"); l.DrawText(x2, y, "\\circledR"); + y -= step ; l.DrawMathText(x1, y, "\\circledS"); l.DrawText(x2, y, "\\circledS"); + y -= step ; l.DrawMathText(x1, y, "\\circledast"); l.DrawText(x2, y, "\\circledast"); + y -= step ; l.DrawMathText(x1, y, "\\circledcirc"); l.DrawText(x2, y, "\\circledcirc"); + y -= step ; l.DrawMathText(x1, y, "\\circleddash"); l.DrawText(x2, y, "\\circleddash"); + y -= step ; l.DrawMathText(x1, y, "\\clubsuit"); l.DrawText(x2, y, "\\clubsuit"); + y -= step ; l.DrawMathText(x1, y, "\\coloneq"); l.DrawText(x2, y, "\\coloneq"); + y -= step ; l.DrawMathText(x1, y, "\\comp"); l.DrawText(x2, y, "\\comp"); + y -= step ; l.DrawMathText(x1, y, "\\complement"); l.DrawText(x2, y, "\\complement"); + y -= step ; l.DrawMathText(x1, y, "\\cong"); l.DrawText(x2, y, "\\cong"); + y -= step ; l.DrawMathText(x1, y, "\\coprod"); l.DrawText(x2, y, "\\coprod"); + y -= step ; l.DrawMathText(x1, y, "\\cup"); l.DrawText(x2, y, "\\cup"); + y -= step ; l.DrawMathText(x1, y, "\\curlyeqprec"); l.DrawText(x2, y, "\\curlyeqprec"); + y -= step ; l.DrawMathText(x1, y, "\\curlyeqsucc"); l.DrawText(x2, y, "\\curlyeqsucc"); + y -= step ; l.DrawMathText(x1, y, "\\curlyvee"); l.DrawText(x2, y, "\\curlyvee"); + y -= step ; l.DrawMathText(x1, y, "\\curlywedge"); l.DrawText(x2, y, "\\curlywedge"); + y -= step ; l.DrawMathText(x1, y, "\\curvearrowleft"); l.DrawText(x2, y, "\\curvearrowleft"); + y -= step ; l.DrawMathText(x1, y, "\\dagger"); l.DrawText(x2, y, "\\dagger"); + y -= step ; l.DrawMathText(x1, y, "\\daleth"); l.DrawText(x2, y, "\\daleth"); + y -= step ; l.DrawMathText(x1, y, "\\dasharrow"); l.DrawText(x2, y, "\\dasharrow"); + y -= step ; l.DrawMathText(x1, y, "\\dashdownarrow"); l.DrawText(x2, y, "\\dashdownarrow"); + y -= step ; l.DrawMathText(x1, y, "\\dashleftarrow"); l.DrawText(x2, y, "\\dashleftarrow"); + y -= step ; l.DrawMathText(x1, y, "\\dashrightarrow"); l.DrawText(x2, y, "\\dashrightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\dashuparrow"); l.DrawText(x2, y, "\\dashuparrow"); + y -= step ; l.DrawMathText(x1, y, "\\dashv"); l.DrawText(x2, y, "\\dashv"); + y -= step ; l.DrawMathText(x1, y, "\\dbar"); l.DrawText(x2, y, "\\dbar"); + y -= step ; l.DrawMathText(x1, y, "\\ddagger"); l.DrawText(x2, y, "\\ddagger"); + y -= step ; l.DrawMathText(x1, y, "\\ddddot"); l.DrawText(x2, y, "\\ddddot"); + y -= step ; l.DrawMathText(x1, y, "\\dddot"); l.DrawText(x2, y, "\\dddot"); + y -= step ; l.DrawMathText(x1, y, "\\ddots"); l.DrawText(x2, y, "\\ddots"); + y -= step ; l.DrawMathText(x1, y, "\\defineeq"); l.DrawText(x2, y, "\\defineeq"); + y -= step ; l.DrawMathText(x1, y, "\\defineequal"); l.DrawText(x2, y, "\\defineequal"); + y -= step ; l.DrawMathText(x1, y, "\\delta"); l.DrawText(x2, y, "\\delta"); + y -= step ; l.DrawMathText(x1, y, "\\diagdown"); l.DrawText(x2, y, "\\diagdown"); + y -= step ; l.DrawMathText(x1, y, "\\diagup"); l.DrawText(x2, y, "\\diagup"); + y -= step ; l.DrawMathText(x1, y, "\\diamond"); l.DrawText(x2, y, "\\diamond"); + y -= step ; l.DrawMathText(x1, y, "\\diamondsuit"); l.DrawText(x2, y, "\\diamondsuit"); + y -= step ; l.DrawMathText(x1, y, "\\digamma"); l.DrawText(x2, y, "\\digamma"); + y -= step ; l.DrawMathText(x1, y, "\\digamma"); l.DrawText(x2, y, "\\digamma"); + y -= step ; l.DrawMathText(x1, y, "\\div"); l.DrawText(x2, y, "\\div"); + y -= step ; l.DrawMathText(x1, y, "\\divideontimes"); l.DrawText(x2, y, "\\divideontimes"); + y -= step ; l.DrawMathText(x1, y, "\\doteq"); l.DrawText(x2, y, "\\doteq"); + y -= step ; l.DrawMathText(x1, y, "\\doteqdot"); l.DrawText(x2, y, "\\doteqdot"); + y -= step ; l.DrawMathText(x1, y, "\\dotplus"); l.DrawText(x2, y, "\\dotplus"); + y -= step ; l.DrawMathText(x1, y, "\\doublebarwedge"); l.DrawText(x2, y, "\\doublebarwedge"); + y -= step ; l.DrawMathText(x1, y, "\\doublecap"); l.DrawText(x2, y, "\\doublecap"); + y -= step ; l.DrawMathText(x1, y, "\\doublecup"); l.DrawText(x2, y, "\\doublecup"); + y -= step ; l.DrawMathText(x1, y, "\\downarrow"); l.DrawText(x2, y, "\\downarrow"); + y -= step ; l.DrawMathText(x1, y, "\\downdownarrows"); l.DrawText(x2, y, "\\downdownarrows"); + y -= step ; l.DrawMathText(x1, y, "\\downdownharpoons"); l.DrawText(x2, y, "\\downdownharpoons"); + y -= step ; l.DrawMathText(x1, y, "\\downharpoonleft"); l.DrawText(x2, y, "\\downharpoonleft"); + y -= step ; l.DrawMathText(x1, y, "\\downharpoonright"); l.DrawText(x2, y, "\\downharpoonright"); + y -= step ; l.DrawMathText(x1, y, "\\downuparrows"); l.DrawText(x2, y, "\\downuparrows"); + y -= step ; l.DrawMathText(x1, y, "\\downupharpoons"); l.DrawText(x2, y, "\\downupharpoons"); + y -= step ; l.DrawMathText(x1, y, "\\ell"); l.DrawText(x2, y, "\\ell"); + y -= step ; l.DrawMathText(x1, y, "\\emptyset"); l.DrawText(x2, y, "\\emptyset"); + y -= step ; l.DrawMathText(x1, y, "\\epsilon"); l.DrawText(x2, y, "\\epsilon"); + y -= step ; l.DrawMathText(x1, y, "\\eqcirc"); l.DrawText(x2, y, "\\eqcirc"); + + // Draw 3rd Column + y = 0.99; step = 0.0126; x1 = 0.27; x2 = x1+0.02; + l.DrawMathText(x1, y, "\\eqcolon"); l.DrawText(x2, y, "\\eqcolon"); + y -= step ; l.DrawMathText(x1, y, "\\eqsim"); l.DrawText(x2, y, "\\eqsim"); + y -= step ; l.DrawMathText(x1, y, "\\eqslantgtr"); l.DrawText(x2, y, "\\eqslantgtr"); + y -= step ; l.DrawMathText(x1, y, "\\eqslantless"); l.DrawText(x2, y, "\\eqslantless"); + y -= step ; l.DrawMathText(x1, y, "\\equiv"); l.DrawText(x2, y, "\\equiv"); + y -= step ; l.DrawMathText(x1, y, "\\eta"); l.DrawText(x2, y, "\\eta"); + y -= step ; l.DrawMathText(x1, y, "\\eth"); l.DrawText(x2, y, "\\eth"); + y -= step ; l.DrawMathText(x1, y, "\\exists"); l.DrawText(x2, y, "\\exists"); + y -= step ; l.DrawMathText(x1, y, "\\fallingdotseq"); l.DrawText(x2, y, "\\fallingdotseq"); + y -= step ; l.DrawMathText(x1, y, "\\flat"); l.DrawText(x2, y, "\\flat"); + y -= step ; l.DrawMathText(x1, y, "\\forall"); l.DrawText(x2, y, "\\forall"); + y -= step ; l.DrawMathText(x1, y, "\\frown"); l.DrawText(x2, y, "\\frown"); + y -= step ; l.DrawMathText(x1, y, "\\gamma"); l.DrawText(x2, y, "\\gamma"); + y -= step ; l.DrawMathText(x1, y, "\\ge"); l.DrawText(x2, y, "\\ge"); + y -= step ; l.DrawMathText(x1, y, "\\geq"); l.DrawText(x2, y, "\\geq"); + y -= step ; l.DrawMathText(x1, y, "\\geqq"); l.DrawText(x2, y, "\\geqq"); + y -= step ; l.DrawMathText(x1, y, "\\geqslant"); l.DrawText(x2, y, "\\geqslant"); + y -= step ; l.DrawMathText(x1, y, "\\gets"); l.DrawText(x2, y, "\\gets"); + y -= step ; l.DrawMathText(x1, y, "\\gg"); l.DrawText(x2, y, "\\gg"); + y -= step ; l.DrawMathText(x1, y, "\\ggg"); l.DrawText(x2, y, "\\ggg"); + y -= step ; l.DrawMathText(x1, y, "\\gggtr"); l.DrawText(x2, y, "\\gggtr"); + y -= step ; l.DrawMathText(x1, y, "\\gimel"); l.DrawText(x2, y, "\\gimel"); + y -= step ; l.DrawMathText(x1, y, "\\gnapprox"); l.DrawText(x2, y, "\\gnapprox"); + y -= step ; l.DrawMathText(x1, y, "\\gneq"); l.DrawText(x2, y, "\\gneq"); + y -= step ; l.DrawMathText(x1, y, "\\gneqq"); l.DrawText(x2, y, "\\gneqq"); + y -= step ; l.DrawMathText(x1, y, "\\gnsim"); l.DrawText(x2, y, "\\gnsim"); + y -= step ; l.DrawMathText(x1, y, "\\gtrapprox"); l.DrawText(x2, y, "\\gtrapprox"); + y -= step ; l.DrawMathText(x1, y, "\\gtrdot"); l.DrawText(x2, y, "\\gtrdot"); + y -= step ; l.DrawMathText(x1, y, "\\gtreqless"); l.DrawText(x2, y, "\\gtreqless"); + y -= step ; l.DrawMathText(x1, y, "\\gtreqqless"); l.DrawText(x2, y, "\\gtreqqless"); + y -= step ; l.DrawMathText(x1, y, "\\gtrless"); l.DrawText(x2, y, "\\gtrless"); + y -= step ; l.DrawMathText(x1, y, "\\gtrsim"); l.DrawText(x2, y, "\\gtrsim"); + y -= step ; l.DrawMathText(x1, y, "\\hateq"); l.DrawText(x2, y, "\\hateq"); + y -= step ; l.DrawMathText(x1, y, "\\hbar"); l.DrawText(x2, y, "\\hbar"); + y -= step ; l.DrawMathText(x1, y, "\\heartsuit"); l.DrawText(x2, y, "\\heartsuit"); + y -= step ; l.DrawMathText(x1, y, "\\hookleftarrow"); l.DrawText(x2, y, "\\hookleftarrow"); + y -= step ; l.DrawMathText(x1, y, "\\hookrightarrow"); l.DrawText(x2, y, "\\hookrightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\hslash"); l.DrawText(x2, y, "\\hslash"); + y -= step ; l.DrawMathText(x1, y, "\\imath"); l.DrawText(x2, y, "\\imath"); + y -= step ; l.DrawMathText(x1, y, "\\in"); l.DrawText(x2, y, "\\in"); + y -= step ; l.DrawMathText(x1, y, "\\infty"); l.DrawText(x2, y, "\\infty"); + y -= step ; l.DrawMathText(x1, y, "\\intercal"); l.DrawText(x2, y, "\\intercal"); + y -= step ; l.DrawMathText(x1, y, "\\iota"); l.DrawText(x2, y, "\\iota"); + y -= step ; l.DrawMathText(x1, y, "\\jmath"); l.DrawText(x2, y, "\\jmath"); + y -= step ; l.DrawMathText(x1, y, "\\kappa"); l.DrawText(x2, y, "\\kappa"); + y -= step ; l.DrawMathText(x1, y, "\\koppa"); l.DrawText(x2, y, "\\koppa"); + y -= step ; l.DrawMathText(x1, y, "\\lambda"); l.DrawText(x2, y, "\\lambda"); + y -= step ; l.DrawMathText(x1, y, "\\land"); l.DrawText(x2, y, "\\land"); + y -= step ; l.DrawMathText(x1, y, "\\langle"); l.DrawText(x2, y, "\\langle"); + y -= step ; l.DrawMathText(x1, y, "\\lceil"); l.DrawText(x2, y, "\\lceil"); + y -= step ; l.DrawMathText(x1, y, "\\ldbrack"); l.DrawText(x2, y, "\\ldbrack"); + y -= step ; l.DrawMathText(x1, y, "\\ldots"); l.DrawText(x2, y, "\\ldots"); + y -= step ; l.DrawMathText(x1, y, "\\le"); l.DrawText(x2, y, "\\le"); + y -= step ; l.DrawMathText(x1, y, "\\leadsfrom"); l.DrawText(x2, y, "\\leadsfrom"); + y -= step ; l.DrawMathText(x1, y, "\\leadsto"); l.DrawText(x2, y, "\\leadsto"); + y -= step ; l.DrawMathText(x1, y, "\\leftarrow"); l.DrawText(x2, y, "\\leftarrow"); + y -= step ; l.DrawMathText(x1, y, "\\leftarrowtail"); l.DrawText(x2, y, "\\leftarrowtail"); + y -= step ; l.DrawMathText(x1, y, "\\leftharpoondown"); l.DrawText(x2, y, "\\leftharpoondown"); + y -= step ; l.DrawMathText(x1, y, "\\leftharpoonup"); l.DrawText(x2, y, "\\leftharpoonup"); + y -= step ; l.DrawMathText(x1, y, "\\leftleftarrows"); l.DrawText(x2, y, "\\leftleftarrows"); + y -= step ; l.DrawMathText(x1, y, "\\leftrightarrow"); l.DrawText(x2, y, "\\leftrightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\leftrightarrows"); l.DrawText(x2, y, "\\leftrightarrows"); + y -= step ; l.DrawMathText(x1, y, "\\leftrightharpoons"); l.DrawText(x2, y, "\\leftrightharpoons"); + y -= step ; l.DrawMathText(x1, y, "\\leftsquigarrow"); l.DrawText(x2, y, "\\leftsquigarrow"); + y -= step ; l.DrawMathText(x1, y, "\\leftthreetimes"); l.DrawText(x2, y, "\\leftthreetimes"); + y -= step ; l.DrawMathText(x1, y, "\\leq"); l.DrawText(x2, y, "\\leq"); + y -= step ; l.DrawMathText(x1, y, "\\leqq"); l.DrawText(x2, y, "\\leqq"); + y -= step ; l.DrawMathText(x1, y, "\\leqslant"); l.DrawText(x2, y, "\\leqslant"); + y -= step ; l.DrawMathText(x1, y, "\\lessapprox"); l.DrawText(x2, y, "\\lessapprox"); + y -= step ; l.DrawMathText(x1, y, "\\lessdot"); l.DrawText(x2, y, "\\lessdot"); + y -= step ; l.DrawMathText(x1, y, "\\lesseqgtr"); l.DrawText(x2, y, "\\lesseqgtr"); + y -= step ; l.DrawMathText(x1, y, "\\lesseqqgtr"); l.DrawText(x2, y, "\\lesseqqgtr"); + y -= step ; l.DrawMathText(x1, y, "\\lessgtr"); l.DrawText(x2, y, "\\lessgtr"); + y -= step ; l.DrawMathText(x1, y, "\\lesssim"); l.DrawText(x2, y, "\\lesssim"); + y -= step ; l.DrawMathText(x1, y, "\\lfloor"); l.DrawText(x2, y, "\\lfloor"); + y -= step ; l.DrawMathText(x1, y, "\\lightning"); l.DrawText(x2, y, "\\lightning"); + y -= step ; l.DrawMathText(x1, y, "\\ll"); l.DrawText(x2, y, "\\ll"); + y -= step ; l.DrawMathText(x1, y, "\\llcorner"); l.DrawText(x2, y, "\\llcorner"); + y -= step ; l.DrawMathText(x1, y, "\\lll"); l.DrawText(x2, y, "\\lll"); + + // Draw 4th Column + y = 0.99; step = 0.0126; x1 = 0.40; x2 = x1+0.02; + l.DrawMathText(x1, y, "\\llless"); l.DrawText(x2, y, "\\llless"); + y -= step ; l.DrawMathText(x1, y, "\\lnapprox"); l.DrawText(x2, y, "\\lnapprox"); + y -= step ; l.DrawMathText(x1, y, "\\lneq"); l.DrawText(x2, y, "\\lneq"); + y -= step ; l.DrawMathText(x1, y, "\\lneqq"); l.DrawText(x2, y, "\\lneqq"); + y -= step ; l.DrawMathText(x1, y, "\\lnot"); l.DrawText(x2, y, "\\lnot"); + y -= step ; l.DrawMathText(x1, y, "\\lnsim"); l.DrawText(x2, y, "\\lnsim"); + y -= step ; l.DrawMathText(x1, y, "\\longleftarrow"); l.DrawText(x2, y, "\\longleftarrow"); + y -= step ; l.DrawMathText(x1, y, "\\longleftrightarrow"); l.DrawText(x2, y, "\\longleftrightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\longmapsto"); l.DrawText(x2, y, "\\longmapsto"); + y -= step ; l.DrawMathText(x1, y, "\\longrightarrow"); l.DrawText(x2, y, "\\longrightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\lor"); l.DrawText(x2, y, "\\lor"); + y -= step ; l.DrawMathText(x1, y, "\\lozenge"); l.DrawText(x2, y, "\\lozenge"); + y -= step ; l.DrawMathText(x1, y, "\\lrcorner"); l.DrawText(x2, y, "\\lrcorner"); + y -= step ; l.DrawMathText(x1, y, "\\ltimes"); l.DrawText(x2, y, "\\ltimes"); + y -= step ; l.DrawMathText(x1, y, "\\maltese"); l.DrawText(x2, y, "\\maltese"); + y -= step ; l.DrawMathText(x1, y, "\\mapsto"); l.DrawText(x2, y, "\\mapsto"); + y -= step ; l.DrawMathText(x1, y, "\\measuredangle"); l.DrawText(x2, y, "\\measuredangle"); + y -= step ; l.DrawMathText(x1, y, "\\mho"); l.DrawText(x2, y, "\\mho"); + y -= step ; l.DrawMathText(x1, y, "\\mp"); l.DrawText(x2, y, "\\mp"); + y -= step ; l.DrawMathText(x1, y, "\\mu"); l.DrawText(x2, y, "\\mu"); + y -= step ; l.DrawMathText(x1, y, "\\multimap"); l.DrawText(x2, y, "\\multimap"); + y -= step ; l.DrawMathText(x1, y, "\\nLeftarrow"); l.DrawText(x2, y, "\\nLeftarrow"); + y -= step ; l.DrawMathText(x1, y, "\\nLeftrightarrow"); l.DrawText(x2, y, "\\nLeftrightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\nRightarrow"); l.DrawText(x2, y, "\\nRightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\nVDash"); l.DrawText(x2, y, "\\nVDash"); + y -= step ; l.DrawMathText(x1, y, "\\nVdash"); l.DrawText(x2, y, "\\nVdash"); + y -= step ; l.DrawMathText(x1, y, "\\nabla"); l.DrawText(x2, y, "\\nabla"); + y -= step ; l.DrawMathText(x1, y, "\\napprox"); l.DrawText(x2, y, "\\napprox"); + y -= step ; l.DrawMathText(x1, y, "\\nasymp"); l.DrawText(x2, y, "\\nasymp"); + y -= step ; l.DrawMathText(x1, y, "\\natural"); l.DrawText(x2, y, "\\natural"); + y -= step ; l.DrawMathText(x1, y, "\\ncong"); l.DrawText(x2, y, "\\ncong"); + y -= step ; l.DrawMathText(x1, y, "\\ne"); l.DrawText(x2, y, "\\ne"); + y -= step ; l.DrawMathText(x1, y, "\\nearrow"); l.DrawText(x2, y, "\\nearrow"); + y -= step ; l.DrawMathText(x1, y, "\\neg"); l.DrawText(x2, y, "\\neg"); + y -= step ; l.DrawMathText(x1, y, "\\neq"); l.DrawText(x2, y, "\\neq"); + y -= step ; l.DrawMathText(x1, y, "\\nequiv"); l.DrawText(x2, y, "\\nequiv"); + y -= step ; l.DrawMathText(x1, y, "\\nexists"); l.DrawText(x2, y, "\\nexists"); + y -= step ; l.DrawMathText(x1, y, "\\ngeq"); l.DrawText(x2, y, "\\ngeq"); + y -= step ; l.DrawMathText(x1, y, "\\ngeqq"); l.DrawText(x2, y, "\\ngeqq"); + y -= step ; l.DrawMathText(x1, y, "\\ngeqslant"); l.DrawText(x2, y, "\\ngeqslant"); + y -= step ; l.DrawMathText(x1, y, "\\ngtr"); l.DrawText(x2, y, "\\ngtr"); + y -= step ; l.DrawMathText(x1, y, "\\ni"); l.DrawText(x2, y, "\\ni"); + y -= step ; l.DrawMathText(x1, y, "\\nleftarrow"); l.DrawText(x2, y, "\\nleftarrow"); + y -= step ; l.DrawMathText(x1, y, "\\nleftrightarrow"); l.DrawText(x2, y, "\\nleftrightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\nleq"); l.DrawText(x2, y, "\\nleq"); + y -= step ; l.DrawMathText(x1, y, "\\nleqq"); l.DrawText(x2, y, "\\nleqq"); + y -= step ; l.DrawMathText(x1, y, "\\nleqslant"); l.DrawText(x2, y, "\\nleqslant"); + y -= step ; l.DrawMathText(x1, y, "\\nless"); l.DrawText(x2, y, "\\nless"); + y -= step ; l.DrawMathText(x1, y, "\\nmid"); l.DrawText(x2, y, "\\nmid"); + y -= step ; l.DrawMathText(x1, y, "\\not"); l.DrawText(x2, y, "\\not"); + y -= step ; l.DrawMathText(x1, y, "\\notapprox"); l.DrawText(x2, y, "\\notapprox"); + y -= step ; l.DrawMathText(x1, y, "\\notasymp"); l.DrawText(x2, y, "\\notasymp"); + y -= step ; l.DrawMathText(x1, y, "\\notcong"); l.DrawText(x2, y, "\\notcong"); + y -= step ; l.DrawMathText(x1, y, "\\notcong"); l.DrawText(x2, y, "\\notcong"); + y -= step ; l.DrawMathText(x1, y, "\\notequiv"); l.DrawText(x2, y, "\\notequiv"); + y -= step ; l.DrawMathText(x1, y, "\\notgeq"); l.DrawText(x2, y, "\\notgeq"); + y -= step ; l.DrawMathText(x1, y, "\\notgeq"); l.DrawText(x2, y, "\\notgeq"); + y -= step ; l.DrawMathText(x1, y, "\\notgr"); l.DrawText(x2, y, "\\notgr"); + y -= step ; l.DrawMathText(x1, y, "\\notgr"); l.DrawText(x2, y, "\\notgr"); + y -= step ; l.DrawMathText(x1, y, "\\notin"); l.DrawText(x2, y, "\\notin"); + y -= step ; l.DrawMathText(x1, y, "\\notleq"); l.DrawText(x2, y, "\\notleq"); + y -= step ; l.DrawMathText(x1, y, "\\notleq"); l.DrawText(x2, y, "\\notleq"); + y -= step ; l.DrawMathText(x1, y, "\\notless"); l.DrawText(x2, y, "\\notless"); + y -= step ; l.DrawMathText(x1, y, "\\notless"); l.DrawText(x2, y, "\\notless"); + y -= step ; l.DrawMathText(x1, y, "\\notni"); l.DrawText(x2, y, "\\notni"); + y -= step ; l.DrawMathText(x1, y, "\\notprec"); l.DrawText(x2, y, "\\notprec"); + y -= step ; l.DrawMathText(x1, y, "\\notprec"); l.DrawText(x2, y, "\\notprec"); + y -= step ; l.DrawMathText(x1, y, "\\notsimeq"); l.DrawText(x2, y, "\\notsimeq"); + y -= step ; l.DrawMathText(x1, y, "\\notsubset"); l.DrawText(x2, y, "\\notsubset"); + y -= step ; l.DrawMathText(x1, y, "\\notsubseteq"); l.DrawText(x2, y, "\\notsubseteq"); + y -= step ; l.DrawMathText(x1, y, "\\notsubseteq"); l.DrawText(x2, y, "\\notsubseteq"); + y -= step ; l.DrawMathText(x1, y, "\\notsucc"); l.DrawText(x2, y, "\\notsucc"); + y -= step ; l.DrawMathText(x1, y, "\\notsucc"); l.DrawText(x2, y, "\\notsucc"); + y -= step ; l.DrawMathText(x1, y, "\\notsupset"); l.DrawText(x2, y, "\\notsupset"); + y -= step ; l.DrawMathText(x1, y, "\\notsupseteq"); l.DrawText(x2, y, "\\notsupseteq"); + y -= step ; l.DrawMathText(x1, y, "\\notsupseteq"); l.DrawText(x2, y, "\\notsupseteq"); + y -= step ; l.DrawMathText(x1, y, "\\nparallel"); l.DrawText(x2, y, "\\nparallel"); + y -= step ; l.DrawMathText(x1, y, "\\nprec"); l.DrawText(x2, y, "\\nprec"); + y -= step ; l.DrawMathText(x1, y, "\\nrightarrow"); l.DrawText(x2, y, "\\nrightarrow"); + + // Draw 5th Column + y = 0.99; step = 0.0126; x1 = 0.53; x2 = x1+0.02; + l.DrawMathText(x1, y, "\\nsim"); l.DrawText(x2, y, "\\nsim"); + y -= step ; l.DrawMathText(x1, y, "\\nsim"); l.DrawText(x2, y, "\\nsim"); + y -= step ; l.DrawMathText(x1, y, "\\nsimeq"); l.DrawText(x2, y, "\\nsimeq"); + y -= step ; l.DrawMathText(x1, y, "\\nsubset"); l.DrawText(x2, y, "\\nsubset"); + y -= step ; l.DrawMathText(x1, y, "\\nsubseteq"); l.DrawText(x2, y, "\\nsubseteq"); + y -= step ; l.DrawMathText(x1, y, "\\nsubseteqq"); l.DrawText(x2, y, "\\nsubseteqq"); + y -= step ; l.DrawMathText(x1, y, "\\nsucc"); l.DrawText(x2, y, "\\nsucc"); + y -= step ; l.DrawMathText(x1, y, "\\nsupset"); l.DrawText(x2, y, "\\nsupset"); + y -= step ; l.DrawMathText(x1, y, "\\nsupseteq"); l.DrawText(x2, y, "\\nsupseteq"); + y -= step ; l.DrawMathText(x1, y, "\\nsupseteqq"); l.DrawText(x2, y, "\\nsupseteqq"); + y -= step ; l.DrawMathText(x1, y, "\\ntriangleleft"); l.DrawText(x2, y, "\\ntriangleleft"); + y -= step ; l.DrawMathText(x1, y, "\\ntrianglelefteq"); l.DrawText(x2, y, "\\ntrianglelefteq"); + y -= step ; l.DrawMathText(x1, y, "\\ntriangleright"); l.DrawText(x2, y, "\\ntriangleright"); + y -= step ; l.DrawMathText(x1, y, "\\ntrianglerighteq"); l.DrawText(x2, y, "\\ntrianglerighteq"); + y -= step ; l.DrawMathText(x1, y, "\\nu"); l.DrawText(x2, y, "\\nu"); + y -= step ; l.DrawMathText(x1, y, "\\nvDash"); l.DrawText(x2, y, "\\nvDash"); + y -= step ; l.DrawMathText(x1, y, "\\nvdash"); l.DrawText(x2, y, "\\nvdash"); + y -= step ; l.DrawMathText(x1, y, "\\nwarrow"); l.DrawText(x2, y, "\\nwarrow"); + y -= step ; l.DrawMathText(x1, y, "\\odot"); l.DrawText(x2, y, "\\odot"); + y -= step ; l.DrawMathText(x1, y, "\\omega"); l.DrawText(x2, y, "\\omega"); + y -= step ; l.DrawMathText(x1, y, "\\ominus"); l.DrawText(x2, y, "\\ominus"); + y -= step ; l.DrawMathText(x1, y, "\\openclubsuit"); l.DrawText(x2, y, "\\openclubsuit"); + y -= step ; l.DrawMathText(x1, y, "\\openspadesuit"); l.DrawText(x2, y, "\\openspadesuit"); + y -= step ; l.DrawMathText(x1, y, "\\oplus"); l.DrawText(x2, y, "\\oplus"); + y -= step ; l.DrawMathText(x1, y, "\\oslash"); l.DrawText(x2, y, "\\oslash"); + y -= step ; l.DrawMathText(x1, y, "\\otimes"); l.DrawText(x2, y, "\\otimes"); + y -= step ; l.DrawMathText(x1, y, "\\owns"); l.DrawText(x2, y, "\\owns"); + y -= step ; l.DrawMathText(x1, y, "\\parallel"); l.DrawText(x2, y, "\\parallel"); + y -= step ; l.DrawMathText(x1, y, "\\partial"); l.DrawText(x2, y, "\\partial"); + y -= step ; l.DrawMathText(x1, y, "\\perp"); l.DrawText(x2, y, "\\perp"); + y -= step ; l.DrawMathText(x1, y, "\\phi"); l.DrawText(x2, y, "\\phi"); + y -= step ; l.DrawMathText(x1, y, "\\pi"); l.DrawText(x2, y, "\\pi"); + y -= step ; l.DrawMathText(x1, y, "\\pitchfork"); l.DrawText(x2, y, "\\pitchfork"); + y -= step ; l.DrawMathText(x1, y, "\\pm"); l.DrawText(x2, y, "\\pm"); + y -= step ; l.DrawMathText(x1, y, "\\prec"); l.DrawText(x2, y, "\\prec"); + y -= step ; l.DrawMathText(x1, y, "\\precapprox"); l.DrawText(x2, y, "\\precapprox"); + y -= step ; l.DrawMathText(x1, y, "\\preccurlyeq"); l.DrawText(x2, y, "\\preccurlyeq"); + y -= step ; l.DrawMathText(x1, y, "\\preceq"); l.DrawText(x2, y, "\\preceq"); + y -= step ; l.DrawMathText(x1, y, "\\precnapprox"); l.DrawText(x2, y, "\\precnapprox"); + y -= step ; l.DrawMathText(x1, y, "\\precneqq"); l.DrawText(x2, y, "\\precneqq"); + y -= step ; l.DrawMathText(x1, y, "\\precnsim"); l.DrawText(x2, y, "\\precnsim"); + y -= step ; l.DrawMathText(x1, y, "\\precsim"); l.DrawText(x2, y, "\\precsim"); + y -= step ; l.DrawMathText(x1, y, "\\prime"); l.DrawText(x2, y, "\\prime"); + y -= step ; l.DrawMathText(x1, y, "\\propto"); l.DrawText(x2, y, "\\propto"); + y -= step ; l.DrawMathText(x1, y, "\\psi"); l.DrawText(x2, y, "\\psi"); + y -= step ; l.DrawMathText(x1, y, "\\rangle"); l.DrawText(x2, y, "\\rangle"); + y -= step ; l.DrawMathText(x1, y, "\\rceil"); l.DrawText(x2, y, "\\rceil"); + y -= step ; l.DrawMathText(x1, y, "\\rdbrack"); l.DrawText(x2, y, "\\rdbrack"); + y -= step ; l.DrawMathText(x1, y, "\\restriction"); l.DrawText(x2, y, "\\restriction"); + y -= step ; l.DrawMathText(x1, y, "\\rfloor"); l.DrawText(x2, y, "\\rfloor"); + y -= step ; l.DrawMathText(x1, y, "\\rho"); l.DrawText(x2, y, "\\rho"); + y -= step ; l.DrawMathText(x1, y, "\\rightarrow"); l.DrawText(x2, y, "\\rightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\rightarrowtail"); l.DrawText(x2, y, "\\rightarrowtail"); + y -= step ; l.DrawMathText(x1, y, "\\rightharpoondown"); l.DrawText(x2, y, "\\rightharpoondown"); + y -= step ; l.DrawMathText(x1, y, "\\rightharpoonup"); l.DrawText(x2, y, "\\rightharpoonup"); + y -= step ; l.DrawMathText(x1, y, "\\rightleftarrows"); l.DrawText(x2, y, "\\rightleftarrows"); + y -= step ; l.DrawMathText(x1, y, "\\rightleftharpoons"); l.DrawText(x2, y, "\\rightleftharpoons"); + y -= step ; l.DrawMathText(x1, y, "\\rightrightarrows"); l.DrawText(x2, y, "\\rightrightarrows"); + y -= step ; l.DrawMathText(x1, y, "\\rightsquigarrow"); l.DrawText(x2, y, "\\rightsquigarrow"); + y -= step ; l.DrawMathText(x1, y, "\\rightthreetimes"); l.DrawText(x2, y, "\\rightthreetimes"); + y -= step ; l.DrawMathText(x1, y, "\\risingdotseq"); l.DrawText(x2, y, "\\risingdotseq"); + y -= step ; l.DrawMathText(x1, y, "\\rtimes"); l.DrawText(x2, y, "\\rtimes"); + y -= step ; l.DrawMathText(x1, y, "\\sampi"); l.DrawText(x2, y, "\\sampi"); + y -= step ; l.DrawMathText(x1, y, "\\san"); l.DrawText(x2, y, "\\san"); + y -= step ; l.DrawMathText(x1, y, "\\searrow"); l.DrawText(x2, y, "\\searrow"); + y -= step ; l.DrawMathText(x1, y, "\\setdif"); l.DrawText(x2, y, "\\setdif"); + y -= step ; l.DrawMathText(x1, y, "\\sharp"); l.DrawText(x2, y, "\\sharp"); + y -= step ; l.DrawMathText(x1, y, "\\sho"); l.DrawText(x2, y, "\\sho"); + y -= step ; l.DrawMathText(x1, y, "\\sigma"); l.DrawText(x2, y, "\\sigma"); + y -= step ; l.DrawMathText(x1, y, "\\sim"); l.DrawText(x2, y, "\\sim"); + y -= step ; l.DrawMathText(x1, y, "\\simarrow"); l.DrawText(x2, y, "\\simarrow"); + y -= step ; l.DrawMathText(x1, y, "\\simeq"); l.DrawText(x2, y, "\\simeq"); + y -= step ; l.DrawMathText(x1, y, "\\smallfrown"); l.DrawText(x2, y, "\\smallfrown"); + y -= step ; l.DrawMathText(x1, y, "\\smallint"); l.DrawText(x2, y, "\\smallint"); + y -= step ; l.DrawMathText(x1, y, "\\smallsetminus"); l.DrawText(x2, y, "\\smallsetminus"); + y -= step ; l.DrawMathText(x1, y, "\\smallsmile"); l.DrawText(x2, y, "\\smallsmile"); + y -= step ; l.DrawMathText(x1, y, "\\smile"); l.DrawText(x2, y, "\\smile"); + y -= step ; l.DrawMathText(x1, y, "\\spadesuit"); l.DrawText(x2, y, "\\spadesuit"); + y -= step ; l.DrawMathText(x1, y, "\\sphericalangle"); l.DrawText(x2, y, "\\sphericalangle"); + + // Draw 6th Column + y = 0.99; step = 0.0126; x1 = 0.66; x2 = x1+0.02; + l.DrawMathText(x1, y, "\\sqcap"); l.DrawText(x2, y, "\\sqcap"); + y -= step ; l.DrawMathText(x1, y, "\\sqcup"); l.DrawText(x2, y, "\\sqcup"); + y -= step ; l.DrawMathText(x1, y, "\\sqsubset"); l.DrawText(x2, y, "\\sqsubset"); + y -= step ; l.DrawMathText(x1, y, "\\sqsubseteq"); l.DrawText(x2, y, "\\sqsubseteq"); + y -= step ; l.DrawMathText(x1, y, "\\sqsupset"); l.DrawText(x2, y, "\\sqsupset"); + y -= step ; l.DrawMathText(x1, y, "\\sqsupseteq"); l.DrawText(x2, y, "\\sqsupseteq"); + y -= step ; l.DrawMathText(x1, y, "\\square"); l.DrawText(x2, y, "\\square"); + y -= step ; l.DrawMathText(x1, y, "\\star"); l.DrawText(x2, y, "\\star"); + y -= step ; l.DrawMathText(x1, y, "\\stigma"); l.DrawText(x2, y, "\\stigma"); + y -= step ; l.DrawMathText(x1, y, "\\subset"); l.DrawText(x2, y, "\\subset"); + y -= step ; l.DrawMathText(x1, y, "\\subseteq"); l.DrawText(x2, y, "\\subseteq"); + y -= step ; l.DrawMathText(x1, y, "\\subseteqq"); l.DrawText(x2, y, "\\subseteqq"); + y -= step ; l.DrawMathText(x1, y, "\\subsetneq"); l.DrawText(x2, y, "\\subsetneq"); + y -= step ; l.DrawMathText(x1, y, "\\subsetneqq"); l.DrawText(x2, y, "\\subsetneqq"); + y -= step ; l.DrawMathText(x1, y, "\\succ"); l.DrawText(x2, y, "\\succ"); + y -= step ; l.DrawMathText(x1, y, "\\succapprox"); l.DrawText(x2, y, "\\succapprox"); + y -= step ; l.DrawMathText(x1, y, "\\succcurlyeq"); l.DrawText(x2, y, "\\succcurlyeq"); + y -= step ; l.DrawMathText(x1, y, "\\succeq"); l.DrawText(x2, y, "\\succeq"); + y -= step ; l.DrawMathText(x1, y, "\\succnapprox"); l.DrawText(x2, y, "\\succnapprox"); + y -= step ; l.DrawMathText(x1, y, "\\succneqq"); l.DrawText(x2, y, "\\succneqq"); + y -= step ; l.DrawMathText(x1, y, "\\succnsim"); l.DrawText(x2, y, "\\succnsim"); + y -= step ; l.DrawMathText(x1, y, "\\succsim"); l.DrawText(x2, y, "\\succsim"); + y -= step ; l.DrawMathText(x1, y, "\\supset"); l.DrawText(x2, y, "\\supset"); + y -= step ; l.DrawMathText(x1, y, "\\supseteq"); l.DrawText(x2, y, "\\supseteq"); + y -= step ; l.DrawMathText(x1, y, "\\supseteqq"); l.DrawText(x2, y, "\\supseteqq"); + y -= step ; l.DrawMathText(x1, y, "\\supsetneq"); l.DrawText(x2, y, "\\supsetneq"); + y -= step ; l.DrawMathText(x1, y, "\\supsetneqq"); l.DrawText(x2, y, "\\supsetneqq"); + y -= step ; l.DrawMathText(x1, y, "\\surd"); l.DrawText(x2, y, "\\surd"); + y -= step ; l.DrawMathText(x1, y, "\\swarrow"); l.DrawText(x2, y, "\\swarrow"); + y -= step ; l.DrawMathText(x1, y, "\\t"); l.DrawText(x2, y, "\\t"); + y -= step ; l.DrawMathText(x1, y, "\\tau"); l.DrawText(x2, y, "\\tau"); + y -= step ; l.DrawMathText(x1, y, "\\therefore"); l.DrawText(x2, y, "\\therefore"); + y -= step ; l.DrawMathText(x1, y, "\\theta"); l.DrawText(x2, y, "\\theta"); + y -= step ; l.DrawMathText(x1, y, "\\times"); l.DrawText(x2, y, "\\times"); + y -= step ; l.DrawMathText(x1, y, "\\to"); l.DrawText(x2, y, "\\to"); + y -= step ; l.DrawMathText(x1, y, "\\top"); l.DrawText(x2, y, "\\top"); + y -= step ; l.DrawMathText(x1, y, "\\triangledown"); l.DrawText(x2, y, "\\triangledown"); + y -= step ; l.DrawMathText(x1, y, "\\triangleleft"); l.DrawText(x2, y, "\\triangleleft"); + y -= step ; l.DrawMathText(x1, y, "\\triangleleft"); l.DrawText(x2, y, "\\triangleleft"); + y -= step ; l.DrawMathText(x1, y, "\\trianglelefteq"); l.DrawText(x2, y, "\\trianglelefteq"); + y -= step ; l.DrawMathText(x1, y, "\\triangleq"); l.DrawText(x2, y, "\\triangleq"); + y -= step ; l.DrawMathText(x1, y, "\\triangleright"); l.DrawText(x2, y, "\\triangleright"); + y -= step ; l.DrawMathText(x1, y, "\\trianglerighteq"); l.DrawText(x2, y, "\\trianglerighteq"); + y -= step ; l.DrawMathText(x1, y, "\\twoheadleftarrow"); l.DrawText(x2, y, "\\twoheadleftarrow"); + y -= step ; l.DrawMathText(x1, y, "\\twoheadrightarrow"); l.DrawText(x2, y, "\\twoheadrightarrow"); + y -= step ; l.DrawMathText(x1, y, "\\u"); l.DrawText(x2, y, "\\u"); + y -= step ; l.DrawMathText(x1, y, "\\ulcorner"); l.DrawText(x2, y, "\\ulcorner"); + y -= step ; l.DrawMathText(x1, y, "\\undercurvearrowright"); l.DrawText(x2, y, "\\undercurvearrowright"); + y -= step ; l.DrawMathText(x1, y, "\\upDelta"); l.DrawText(x2, y, "\\upDelta"); + y -= step ; l.DrawMathText(x1, y, "\\upDigamma"); l.DrawText(x2, y, "\\upDigamma"); + y -= step ; l.DrawMathText(x1, y, "\\upGamma"); l.DrawText(x2, y, "\\upGamma"); + y -= step ; l.DrawMathText(x1, y, "\\upKoppa"); l.DrawText(x2, y, "\\upKoppa"); + y -= step ; l.DrawMathText(x1, y, "\\upLambda"); l.DrawText(x2, y, "\\upLambda"); + y -= step ; l.DrawMathText(x1, y, "\\upOmega"); l.DrawText(x2, y, "\\upOmega"); + y -= step ; l.DrawMathText(x1, y, "\\upPhi"); l.DrawText(x2, y, "\\upPhi"); + y -= step ; l.DrawMathText(x1, y, "\\upPi"); l.DrawText(x2, y, "\\upPi"); + y -= step ; l.DrawMathText(x1, y, "\\upPsi"); l.DrawText(x2, y, "\\upPsi"); + y -= step ; l.DrawMathText(x1, y, "\\upSampi"); l.DrawText(x2, y, "\\upSampi"); + y -= step ; l.DrawMathText(x1, y, "\\upSan"); l.DrawText(x2, y, "\\upSan"); + y -= step ; l.DrawMathText(x1, y, "\\upSho"); l.DrawText(x2, y, "\\upSho"); + y -= step ; l.DrawMathText(x1, y, "\\upSigma"); l.DrawText(x2, y, "\\upSigma"); + y -= step ; l.DrawMathText(x1, y, "\\upStigma"); l.DrawText(x2, y, "\\upStigma"); + y -= step ; l.DrawMathText(x1, y, "\\upTheta"); l.DrawText(x2, y, "\\upTheta"); + y -= step ; l.DrawMathText(x1, y, "\\upUpsilon"); l.DrawText(x2, y, "\\upUpsilon"); + y -= step ; l.DrawMathText(x1, y, "\\upVarKoppa"); l.DrawText(x2, y, "\\upVarKoppa"); + y -= step ; l.DrawMathText(x1, y, "\\upXi"); l.DrawText(x2, y, "\\upXi"); + y -= step ; l.DrawMathText(x1, y, "\\upalpha"); l.DrawText(x2, y, "\\upalpha"); + y -= step ; l.DrawMathText(x1, y, "\\uparrow"); l.DrawText(x2, y, "\\uparrow"); + y -= step ; l.DrawMathText(x1, y, "\\upbeta"); l.DrawText(x2, y, "\\upbeta"); + y -= step ; l.DrawMathText(x1, y, "\\upchi"); l.DrawText(x2, y, "\\upchi"); + y -= step ; l.DrawMathText(x1, y, "\\updbar"); l.DrawText(x2, y, "\\updbar"); + y -= step ; l.DrawMathText(x1, y, "\\updelta"); l.DrawText(x2, y, "\\updelta"); + y -= step ; l.DrawMathText(x1, y, "\\updigamma"); l.DrawText(x2, y, "\\updigamma"); + y -= step ; l.DrawMathText(x1, y, "\\updownarrow"); l.DrawText(x2, y, "\\updownarrow"); + y -= step ; l.DrawMathText(x1, y, "\\updownarrows"); l.DrawText(x2, y, "\\updownarrows"); + y -= step ; l.DrawMathText(x1, y, "\\updownharpoons"); l.DrawText(x2, y, "\\updownharpoons"); + y -= step ; l.DrawMathText(x1, y, "\\upepsilon"); l.DrawText(x2, y, "\\upepsilon"); + y -= step ; l.DrawMathText(x1, y, "\\upeta"); l.DrawText(x2, y, "\\upeta"); + y -= step ; l.DrawMathText(x1, y, "\\upgamma"); l.DrawText(x2, y, "\\upgamma"); + + // Draw 7th Column + y = 0.99; step = 0.0126; x1 = 0.79; x2 = x1+0.02; + l.DrawMathText(x1, y, "\\upharpoonleft"); l.DrawText(x2, y, "\\upharpoonleft"); + y -= step ; l.DrawMathText(x1, y, "\\upharpoonright"); l.DrawText(x2, y, "\\upharpoonright"); + y -= step ; l.DrawMathText(x1, y, "\\upiota"); l.DrawText(x2, y, "\\upiota"); + y -= step ; l.DrawMathText(x1, y, "\\upkappa"); l.DrawText(x2, y, "\\upkappa"); + y -= step ; l.DrawMathText(x1, y, "\\upkoppa"); l.DrawText(x2, y, "\\upkoppa"); + y -= step ; l.DrawMathText(x1, y, "\\uplambda"); l.DrawText(x2, y, "\\uplambda"); + y -= step ; l.DrawMathText(x1, y, "\\uplus"); l.DrawText(x2, y, "\\uplus"); + y -= step ; l.DrawMathText(x1, y, "\\upmu"); l.DrawText(x2, y, "\\upmu"); + y -= step ; l.DrawMathText(x1, y, "\\upnu"); l.DrawText(x2, y, "\\upnu"); + y -= step ; l.DrawMathText(x1, y, "\\upomega"); l.DrawText(x2, y, "\\upomega"); + y -= step ; l.DrawMathText(x1, y, "\\upphi"); l.DrawText(x2, y, "\\upphi"); + y -= step ; l.DrawMathText(x1, y, "\\uppi"); l.DrawText(x2, y, "\\uppi"); + y -= step ; l.DrawMathText(x1, y, "\\uppsi"); l.DrawText(x2, y, "\\uppsi"); + y -= step ; l.DrawMathText(x1, y, "\\uprho"); l.DrawText(x2, y, "\\uprho"); + y -= step ; l.DrawMathText(x1, y, "\\upsampi"); l.DrawText(x2, y, "\\upsampi"); + y -= step ; l.DrawMathText(x1, y, "\\upsan"); l.DrawText(x2, y, "\\upsan"); + y -= step ; l.DrawMathText(x1, y, "\\upsho"); l.DrawText(x2, y, "\\upsho"); + y -= step ; l.DrawMathText(x1, y, "\\upsigma"); l.DrawText(x2, y, "\\upsigma"); + y -= step ; l.DrawMathText(x1, y, "\\upsilon"); l.DrawText(x2, y, "\\upsilon"); + y -= step ; l.DrawMathText(x1, y, "\\upstigma"); l.DrawText(x2, y, "\\upstigma"); + y -= step ; l.DrawMathText(x1, y, "\\uptau"); l.DrawText(x2, y, "\\uptau"); + y -= step ; l.DrawMathText(x1, y, "\\uptheta"); l.DrawText(x2, y, "\\uptheta"); + y -= step ; l.DrawMathText(x1, y, "\\upuparrows"); l.DrawText(x2, y, "\\upuparrows"); + y -= step ; l.DrawMathText(x1, y, "\\upupharpoons"); l.DrawText(x2, y, "\\upupharpoons"); + y -= step ; l.DrawMathText(x1, y, "\\upupsilon"); l.DrawText(x2, y, "\\upupsilon"); + y -= step ; l.DrawMathText(x1, y, "\\upvarbeta"); l.DrawText(x2, y, "\\upvarbeta"); + y -= step ; l.DrawMathText(x1, y, "\\upvarepsilon"); l.DrawText(x2, y, "\\upvarepsilon"); + y -= step ; l.DrawMathText(x1, y, "\\upvarkappa"); l.DrawText(x2, y, "\\upvarkappa"); + y -= step ; l.DrawMathText(x1, y, "\\upvarkoppa"); l.DrawText(x2, y, "\\upvarkoppa"); + y -= step ; l.DrawMathText(x1, y, "\\upvarphi"); l.DrawText(x2, y, "\\upvarphi"); + y -= step ; l.DrawMathText(x1, y, "\\upvarpi"); l.DrawText(x2, y, "\\upvarpi"); + y -= step ; l.DrawMathText(x1, y, "\\upvarrho"); l.DrawText(x2, y, "\\upvarrho"); + y -= step ; l.DrawMathText(x1, y, "\\upvarsigma"); l.DrawText(x2, y, "\\upvarsigma"); + y -= step ; l.DrawMathText(x1, y, "\\upvartheta"); l.DrawText(x2, y, "\\upvartheta"); + y -= step ; l.DrawMathText(x1, y, "\\upxi"); l.DrawText(x2, y, "\\upxi"); + y -= step ; l.DrawMathText(x1, y, "\\upzeta"); l.DrawText(x2, y, "\\upzeta"); + y -= step ; l.DrawMathText(x1, y, "\\urcorner"); l.DrawText(x2, y, "\\urcorner"); + y -= step ; l.DrawMathText(x1, y, "\\v"); l.DrawText(x2, y, "\\v"); + y -= step ; l.DrawMathText(x1, y, "\\vDash"); l.DrawText(x2, y, "\\vDash"); + y -= step ; l.DrawMathText(x1, y, "\\vDash"); l.DrawText(x2, y, "\\vDash"); + y -= step ; l.DrawMathText(x1, y, "\\varbeta"); l.DrawText(x2, y, "\\varbeta"); + y -= step ; l.DrawMathText(x1, y, "\\varepsilon"); l.DrawText(x2, y, "\\varepsilon"); + y -= step ; l.DrawMathText(x1, y, "\\varkappa"); l.DrawText(x2, y, "\\varkappa"); + y -= step ; l.DrawMathText(x1, y, "\\varkoppa"); l.DrawText(x2, y, "\\varkoppa"); + y -= step ; l.DrawMathText(x1, y, "\\varnothing"); l.DrawText(x2, y, "\\varnothing"); + y -= step ; l.DrawMathText(x1, y, "\\varphi"); l.DrawText(x2, y, "\\varphi"); + y -= step ; l.DrawMathText(x1, y, "\\varpi"); l.DrawText(x2, y, "\\varpi"); + y -= step ; l.DrawMathText(x1, y, "\\varpropto"); l.DrawText(x2, y, "\\varpropto"); + y -= step ; l.DrawMathText(x1, y, "\\varrho"); l.DrawText(x2, y, "\\varrho"); + y -= step ; l.DrawMathText(x1, y, "\\varsigma"); l.DrawText(x2, y, "\\varsigma"); + y -= step ; l.DrawMathText(x1, y, "\\vartheta"); l.DrawText(x2, y, "\\vartheta"); + y -= step ; l.DrawMathText(x1, y, "\\vartriangle"); l.DrawText(x2, y, "\\vartriangle"); + y -= step ; l.DrawMathText(x1, y, "\\vartriangleleft"); l.DrawText(x2, y, "\\vartriangleleft"); + y -= step ; l.DrawMathText(x1, y, "\\vartriangleright"); l.DrawText(x2, y, "\\vartriangleright"); + y -= step ; l.DrawMathText(x1, y, "\\vdash"); l.DrawText(x2, y, "\\vdash"); + y -= step ; l.DrawMathText(x1, y, "\\vdots"); l.DrawText(x2, y, "\\vdots"); + y -= step ; l.DrawMathText(x1, y, "\\vec"); l.DrawText(x2, y, "\\vec"); + y -= step ; l.DrawMathText(x1, y, "\\vee"); l.DrawText(x2, y, "\\vee"); + y -= step ; l.DrawMathText(x1, y, "\\veebar"); l.DrawText(x2, y, "\\veebar"); + y -= step ; l.DrawMathText(x1, y, "\\vert"); l.DrawText(x2, y, "\\vert"); + y -= step ; l.DrawMathText(x1, y, "\\wedge"); l.DrawText(x2, y, "\\wedge"); + y -= step ; l.DrawMathText(x1, y, "\\wp"); l.DrawText(x2, y, "\\wp"); + y -= step ; l.DrawMathText(x1, y, "\\wr"); l.DrawText(x2, y, "\\wr"); + y -= step ; l.DrawMathText(x1, y, "\\wwbar"); l.DrawText(x2, y, "\\wwbar"); + y -= step ; l.DrawMathText(x1, y, "\\xi"); l.DrawText(x2, y, "\\xi"); + y -= step ; l.DrawMathText(x1, y, "\\yen"); l.DrawText(x2, y, "\\yen"); + y -= step ; l.DrawMathText(x1, y, "\\zeta"); l.DrawText(x2, y, "\\zeta"); + y -= step ; l.DrawMathText(x1, y, "\\{"); l.DrawText(x2, y, "\\{"); + y -= step ; l.DrawMathText(x1, y, "\\|"); l.DrawText(x2, y, "\\|"); + y -= step ; l.DrawMathText(x1, y, "\\}"); l.DrawText(x2, y, "\\}"); + y -= step ; l.DrawMathText(x1, y, "\\~"); l.DrawText(x2, y, "\\~"); + y -= step ; l.DrawMathText(x1, y, "\\Pr"); l.DrawText(x2, y, "\\Pr"); + y -= step ; l.DrawMathText(x1, y, "\\awoint"); l.DrawText(x2, y, "\\awoint"); + y -= step ; l.DrawMathText(x1, y, "\\awointop"); l.DrawText(x2, y, "\\awointop"); + y -= step ; l.DrawMathText(x1, y, "\\barint"); l.DrawText(x2, y, "\\barint"); + y -= step ; l.DrawMathText(x1, y, "\\barintop"); l.DrawText(x2, y, "\\barintop"); + y -= step ; l.DrawMathText(x1, y, "\\bigcap"); l.DrawText(x2, y, "\\bigcap"); + y -= step ; l.DrawMathText(x1, y, "\\bigcup"); l.DrawText(x2, y, "\\bigcup"); + y -= step ; l.DrawMathText(x1, y, "\\bigodot"); l.DrawText(x2, y, "\\bigodot"); + + + // Draw 8th Column + y = 0.99; step = 0.0126; x1 = 0.92; x2 = x1+0.02; + l.DrawMathText(x1, y, "\\bigoplus"); l.DrawText(x2, y, "\\bigoplus"); + y -= step ; l.DrawMathText(x1, y, "\\bigotimes"); l.DrawText(x2, y, "\\bigotimes"); + y -= step ; l.DrawMathText(x1, y, "\\bigsqcup"); l.DrawText(x2, y, "\\bigsqcup"); + y -= step ; l.DrawMathText(x1, y, "\\biguplus"); l.DrawText(x2, y, "\\biguplus"); + y -= step ; l.DrawMathText(x1, y, "\\bigvee"); l.DrawText(x2, y, "\\bigvee"); + y -= step ; l.DrawMathText(x1, y, "\\bigwedge"); l.DrawText(x2, y, "\\bigwedge"); + y -= step ; l.DrawMathText(x1, y, "\\coprod"); l.DrawText(x2, y, "\\coprod"); + y -= step ; l.DrawMathText(x1, y, "\\cwint"); l.DrawText(x2, y, "\\cwint"); + y -= step ; l.DrawMathText(x1, y, "\\cwintop"); l.DrawText(x2, y, "\\cwintop"); + y -= step ; l.DrawMathText(x1, y, "\\cwoint"); l.DrawText(x2, y, "\\cwoint"); + y -= step ; l.DrawMathText(x1, y, "\\cwointop"); l.DrawText(x2, y, "\\cwointop"); + y -= step ; l.DrawMathText(x1, y, "\\iiint"); l.DrawText(x2, y, "\\iiint"); + y -= step ; l.DrawMathText(x1, y, "\\iiintop"); l.DrawText(x2, y, "\\iiintop"); + y -= step ; l.DrawMathText(x1, y, "\\iint"); l.DrawText(x2, y, "\\iint"); + y -= step ; l.DrawMathText(x1, y, "\\iintop"); l.DrawText(x2, y, "\\iintop"); + y -= step ; l.DrawMathText(x1, y, "\\int"); l.DrawText(x2, y, "\\int"); + y -= step ; l.DrawMathText(x1, y, "\\intop"); l.DrawText(x2, y, "\\intop"); + y -= step ; l.DrawMathText(x1, y, "\\oiiint"); l.DrawText(x2, y, "\\oiiint"); + y -= step ; l.DrawMathText(x1, y, "\\oiiintop"); l.DrawText(x2, y, "\\oiiintop"); + y -= step ; l.DrawMathText(x1, y, "\\oiint"); l.DrawText(x2, y, "\\oiint"); + y -= step ; l.DrawMathText(x1, y, "\\oiintop"); l.DrawText(x2, y, "\\oiintop"); + y -= step ; l.DrawMathText(x1, y, "\\oint"); l.DrawText(x2, y, "\\oint"); + y -= step ; l.DrawMathText(x1, y, "\\ointop"); l.DrawText(x2, y, "\\ointop"); + y -= step ; l.DrawMathText(x1, y, "\\prod"); l.DrawText(x2, y, "\\prod"); + y -= step ; l.DrawMathText(x1, y, "\\slashint"); l.DrawText(x2, y, "\\slashint"); + y -= step ; l.DrawMathText(x1, y, "\\slashintop"); l.DrawText(x2, y, "\\slashintop"); + y -= step ; l.DrawMathText(x1, y, "\\sum"); l.DrawText(x2, y, "\\sum"); + + x2 = x2+0.02; + y -= step ; l.DrawMathText(x1, y, "\\arccos"); l.DrawText(x2, y, "\\arccos"); + y -= step ; l.DrawMathText(x1, y, "\\arcsin"); l.DrawText(x2, y, "\\arcsin"); + y -= step ; l.DrawMathText(x1, y, "\\arctan"); l.DrawText(x2, y, "\\arctan"); + y -= step ; l.DrawMathText(x1, y, "\\arg"); l.DrawText(x2, y, "\\arg"); + y -= step ; l.DrawMathText(x1, y, "\\cos"); l.DrawText(x2, y, "\\cos"); + y -= step ; l.DrawMathText(x1, y, "\\cosh"); l.DrawText(x2, y, "\\cosh"); + y -= step ; l.DrawMathText(x1, y, "\\cot"); l.DrawText(x2, y, "\\cot"); + y -= step ; l.DrawMathText(x1, y, "\\coth"); l.DrawText(x2, y, "\\coth"); + y -= step ; l.DrawMathText(x1, y, "\\csc"); l.DrawText(x2, y, "\\csc"); + y -= step ; l.DrawMathText(x1, y, "\\deg"); l.DrawText(x2, y, "\\deg"); + y -= step ; l.DrawMathText(x1, y, "\\det"); l.DrawText(x2, y, "\\det"); + y -= step ; l.DrawMathText(x1, y, "\\dim"); l.DrawText(x2, y, "\\dim"); + y -= step ; l.DrawMathText(x1, y, "\\exp"); l.DrawText(x2, y, "\\exp"); + y -= step ; l.DrawMathText(x1, y, "\\gcd"); l.DrawText(x2, y, "\\gcd"); + y -= step ; l.DrawMathText(x1, y, "\\hom"); l.DrawText(x2, y, "\\hom"); + y -= step ; l.DrawMathText(x1, y, "\\inf"); l.DrawText(x2, y, "\\inf"); + y -= step ; l.DrawMathText(x1, y, "\\ker"); l.DrawText(x2, y, "\\ker"); + y -= step ; l.DrawMathText(x1, y, "\\lg"); l.DrawText(x2, y, "\\lg"); + y -= step ; l.DrawMathText(x1, y, "\\lim"); l.DrawText(x2, y, "\\lim"); + y -= step ; l.DrawMathText(x1, y, "\\liminf"); l.DrawText(x2, y, "\\liminf"); + y -= step ; l.DrawMathText(x1, y, "\\limsup"); l.DrawText(x2, y, "\\limsup"); + y -= step ; l.DrawMathText(x1, y, "\\ln"); l.DrawText(x2, y, "\\ln"); + y -= step ; l.DrawMathText(x1, y, "\\log"); l.DrawText(x2, y, "\\log"); + y -= step ; l.DrawMathText(x1, y, "\\max"); l.DrawText(x2, y, "\\max"); + y -= step ; l.DrawMathText(x1, y, "\\min"); l.DrawText(x2, y, "\\min"); + y -= step ; l.DrawMathText(x1, y, "\\sec"); l.DrawText(x2, y, "\\sec"); + y -= step ; l.DrawMathText(x1, y, "\\sin"); l.DrawText(x2, y, "\\sin"); + y -= step ; l.DrawMathText(x1, y, "\\sinh"); l.DrawText(x2, y, "\\sinh"); + y -= step ; l.DrawMathText(x1, y, "\\sup"); l.DrawText(x2, y, "\\sup"); + y -= step ; l.DrawMathText(x1, y, "\\tan"); l.DrawText(x2, y, "\\tan"); + y -= step ; l.DrawMathText(x1, y, "\\tanh"); l.DrawText(x2, y, "\\tanh"); + + return c1; +} diff --git a/tutorials/graphs/timeonaxis.C b/tutorials/graphs/timeonaxis.C index 0db72ebb505d1..168db18fe21ab 100644 --- a/tutorials/graphs/timeonaxis.C +++ b/tutorials/graphs/timeonaxis.C @@ -12,7 +12,7 @@ void timeonaxis() // begin_html <a href="http://www.topology.org/sci/time.html">http://www.topology.org/sci/time.html</a> end_html // // The start time is : almost NOW (the time at which the script is executed) -// actualy, the nearest preceeding hour beginning. +// actualy, the nearest preceding hour beginning. // The time is in general expressed in UTC time with the C time() function // This will obviously most of the time not be the time displayed on your watch // since it is universal time. See the C time functions for converting this time diff --git a/tutorials/graphs/timeonaxis3.C b/tutorials/graphs/timeonaxis3.C new file mode 100644 index 0000000000000..1701987a37e47 --- /dev/null +++ b/tutorials/graphs/timeonaxis3.C @@ -0,0 +1,114 @@ +// This example compare what the system time function gmtime and localtime give +// with what gives TGaxis. It can be used as referenced test to check if TGaxis +// is working properly. +// The original code was developped by Philippe Gras (CEA Saclay. IRFU/SEDI) +//Author: Philippe Gras, Bertrand Bellenot, Olivier Couet + +#if defined(G__WIN32) && defined(__CINT__) && !defined(__MAKECINT__) +{ + // timeonaxis3.C has to be run in compiled mode on Windows. + // the following code does it. + + gSystem->CompileMacro("timeonaxis3.C"); + timeonaxis3(); +} +#else + +#include "TAxis.h" +#include "TGaxis.h" +#include "TCanvas.h" +#include "TString.h" +#include "TLine.h" +#include "TLatex.h" +#include <time.h> +#include <stdio.h> + +TString stime(time_t* t, bool utc = false, bool display_time_zone = true) { + struct tm* tt; + if (utc) tt = gmtime(t); + else tt = localtime(t); + char buf[256]; + if (display_time_zone) strftime(buf, sizeof(buf), "%H:%M:%S %Z", tt); + else strftime(buf, sizeof(buf), "%Y-%m-%d %H:%M:%S", tt); + return TString(buf); +} + + +void timeonaxis3() { + double f = 1.8; + + TCanvas* c = new TCanvas; + + TLatex* tex1 = new TLatex; + tex1->SetNDC(); + tex1->SetTextFont(102); + tex1->SetTextSize(0.07*f); + + TLatex* tex3 = new TLatex; + tex3->SetNDC(); + tex3->SetTextFont(102); + tex3->SetTextSize(0.07*f); + tex3->SetTextColor(kBlue+2); + + TLatex* tex2 = new TLatex; + tex2->SetNDC(); + tex2->SetTextFont(102); + tex2->SetTextSize(0.07*f); + tex2->SetTextColor(kOrange+3); + + time_t offset[] = {0, 0, 1325376000, 1341100800}; + time_t t[] = {1331150400, 1336417200, 0, 36000}; + + c->SetTopMargin(0); c->SetBottomMargin(0); + c->SetLeftMargin(0); c->SetRightMargin(0); + c->Divide(2, 4, -1, -1); + TLine l; + l.DrawLine(0.5, 0, 0.5, 1.); + + for(int i = 0; i < 4; ++i){ + for(int gmt = 0; gmt < 2; ++gmt){ + const char* opt = (gmt ? "gmt" : "local"); + TVirtualPad* p = c->cd(2*i + gmt + 1); + p->SetTopMargin(0); p->SetBottomMargin(0); + p->SetLeftMargin(0); p->SetRightMargin(0); + p->SetFillStyle(4000); + + TGaxis* ga = new TGaxis (.4, .25, 5., .25, t[i], t[i] + 1, 1, "t"); + ga->SetTimeFormat("TGaxis label: #color[2]{%Y-%m-%d %H:%M:%S}"); + ga->SetLabelFont(102); + ga->SetLabelColor(kBlue+2); + + ga->SetTimeOffset(offset[i], opt); + ga->SetLabelOffset(0.04*f); + ga->SetLabelSize(0.07*f); + ga->SetLineColor(0); + ga->Draw(); + + // Get offset string of axis time format: there is not acccessor + // to time format in TGaxis. + // Assumes TAxis use the same format. + TAxis a(10, 0, 1600000000); + a.SetTimeOffset(offset[i], opt); + const char* offsettimeformat = a.GetTimeFormat(); + + char buf[256]; + if (offset[i] < t[i]) { + sprintf(buf, "#splitline{%s, %s}{offset: %ld, option %s}", + stime(t+i).Data(), stime(t+i, true).Data(), offset[i], opt); + } else { + int h = t[i] / 3600; + int m = (t[i] - 3600 * h) / 60 ; + int s = (t[i] - h * 3600 - m * 60); + sprintf(buf, "#splitline{%d h %d m %d s}{offset: %s, option %s}", + h, m, s, stime(offset + i, gmt).Data(), opt); + } + tex1->DrawLatex(.01, .75, buf); + tex2->DrawLatex(.01, .50, offsettimeformat); + time_t t_ = t[i] + offset[i]; + sprintf(buf, "Expecting: #color[2]{%s}", stime(&t_, gmt, false).Data()); + tex3->DrawLatex(.01, .24, buf); + if(i > 0) l.DrawLine(0, 0.95, 1, 0.95); + } + } +} +#endif diff --git a/tutorials/gui/CPUMeter.C b/tutorials/gui/CPUMeter.C index 090f4fe0eb070..230d4439f761b 100644 --- a/tutorials/gui/CPUMeter.C +++ b/tutorials/gui/CPUMeter.C @@ -115,11 +115,11 @@ void Update() prev_load = act_load; old_memUsage = memUsage; - // Get CPU informations + // Get CPU information gSystem->GetCpuInfo(&cpuInfo, 100); // actual CPU load act_load = cpuInfo.fTotal; - // Get Memory informations + // Get Memory information gSystem->GetMemInfo(&memInfo); // choose which value to display if (gMainWindow->GetActInfo() == 0) diff --git a/tutorials/gui/guiWithCINT.C b/tutorials/gui/guiWithCINT.C index ea613211e1917..d29ea3cfd7dc0 100644 --- a/tutorials/gui/guiWithCINT.C +++ b/tutorials/gui/guiWithCINT.C @@ -1,7 +1,7 @@ // A simple example of entering CINT commands and having the CINT output in a // ROOT GUI application window. // An editable combo box is used as a CINT prompt, a text view widget displays -// the comand output. +// the command output. // Author: Ilka Antcheva 06/07/2007 #include <iostream> diff --git a/tutorials/hist/th2polyEurope.C b/tutorials/hist/th2polyEurope.C index e5531e661bada..53b708162a81e 100644 --- a/tutorials/hist/th2polyEurope.C +++ b/tutorials/hist/th2polyEurope.C @@ -39,19 +39,19 @@ void th2polyEurope(Int_t npoints=500000) const Int_t nx = 36; // see http://en.wikipedia.org/wiki/Area_and_population_of_European_countries char *countries[nx] = { "france", "spain", "sweden", "germany", "finland", - "norway", "poland", "italy", "yugoslavia", "united_kingdom", - "romania", "belarus","greece", "czechoslovakia","bulgaria", - "iceland", "hungary","portugal","austria", "ireland", + "norway", "poland", "italy", "yugoslavia", "united_kingdom", + "romania", "belarus","greece", "czechoslovakia","bulgaria", + "iceland", "hungary","portugal","austria", "ireland", "lithuania", "latvia", "estonia", "denmark", "netherlands", - "switzerland","moldova","belgium", "albania", "cyprus", - "luxembourg", "andorra","malta", "liechtenstein", "san_marino", + "switzerland","moldova","belgium", "albania", "cyprus", + "luxembourg", "andorra","malta", "liechtenstein", "san_marino", "monaco" }; - Float_t surfaces[nx] = { 547030, 505580, 449964, 357021, 338145, - 324220, 312685, 301230, 255438, 244820, - 237500, 207600, 131940, 127711, 110910, - 103000, 93030, 89242, 83870, 70280, - 65200, 64589, 45226, 43094, 41526, - 41290, 33843, 30528, 28748, 9250, + Float_t surfaces[nx] = { 547030, 505580, 449964, 357021, 338145, + 324220, 312685, 301230, 255438, 244820, + 237500, 207600, 131940, 127711, 110910, + 103000, 93030, 89242, 83870, 70280, + 65200, 64589, 45226, 43094, 41526, + 41290, 33843, 30528, 28748, 9250, 2586, 468, 316, 160, 61, 2}; @@ -63,6 +63,11 @@ void th2polyEurope(Int_t npoints=500000) TFile *f; f = TFile::Open("http://root.cern.ch/files/europe.root","cacheread"); + if (!f) { + printf("Cannot access europe.root. Is internet working ?\n"); + return; + } + TH2Poly *p = new TH2Poly( "Europe", "Europe (bin contents are normalized to the surfaces in km^{2})", @@ -87,7 +92,7 @@ void th2polyEurope(Int_t npoints=500000) TRandom r; Double_t longitude, latitude; Double_t x, y, pi4 = TMath::Pi()/4, alpha = TMath::Pi()/360; - + gBenchmark->Start("Partitioning"); p->ChangePartition(100, 100); gBenchmark->Show("Partitioning"); @@ -157,7 +162,7 @@ void th2polyEurope(Int_t npoints=500000) leg->AddEntry(h2,"Countries surfaces from TH2Poly (with errors)","lp"); leg->Draw(); leg->Draw(); - + Double_t wikiSum = h->Integral(); Double_t polySum = h2->Integral(); Double_t error = TMath::Abs(wikiSum-polySum)/wikiSum; diff --git a/tutorials/hist/th2polyUSA.C b/tutorials/hist/th2polyUSA.C index 4fec80b4ced52..170af5e42f2ef 100644 --- a/tutorials/hist/th2polyUSA.C +++ b/tutorials/hist/th2polyUSA.C @@ -47,6 +47,11 @@ void th2polyUSA() TFile *f; f = TFile::Open("http://root.cern.ch/files/usa.root"); + if (!f) { + printf("Cannot access usa.root. Is internet working ?\n"); + return; + } + // Define the TH2Poly bins. TMultiGraph *mg; TKey *key; diff --git a/tutorials/histfactory/example.C b/tutorials/histfactory/example.C new file mode 100644 index 0000000000000..741329550c524 --- /dev/null +++ b/tutorials/histfactory/example.C @@ -0,0 +1,97 @@ + +#include "RooStats/HistFactory/Measurement.h" +#include "RooStats/HistFactory/MakeModelAndMeasurementsFast.h" +#include "TFile.h" +#include "TROOT.h" + +using namespace RooStats; +using namespace HistFactory; + + +/* + + A ROOT script demonstrating + an example of writing a HistFactory + model using c++ only. + + This example was written to match + the example.xml analysis in + $ROOTSYS/tutorials/histfactory/ + + Written by George Lewis + + */ + + +void example() { + + + std::string InputFile = "./data/example.root"; + // in case the file is not found + TFile * ifile = TFile::Open(InputFile.c_str()); + if (!ifile) { + std::cout << "Input file is not found - run prepareHistFactory script " << std::endl; + gROOT->ProcessLine(".! prepareHistFactory ."); + } + + // Create the measurement + Measurement meas("meas", "meas"); + + meas.SetOutputFilePrefix( "./results/example_UsingC" ); + meas.SetPOI( "SigXsecOverSM" ); + meas.AddConstantParam("alpha_syst1"); + meas.AddConstantParam("Lumi"); + + meas.SetLumi( 1.0 ); + meas.SetLumiRelErr( 0.10 ); + meas.SetExportOnly( false ); + meas.SetBinHigh( 2 ); + + // Create a channel + + Channel chan( "channel1" ); + chan.SetData( "data", InputFile ); + chan.SetStatErrorConfig( 0.05, "Poisson" ); + + + // Now, create some samples + + + // Create the signal sample + Sample signal( "signal", "signal", InputFile ); + signal.AddOverallSys( "syst1", 0.95, 1.05 ); + signal.AddNormFactor( "SigXsecOverSM", 1, 0, 3 ); + chan.AddSample( signal ); + + // Background 1 + Sample background1( "background1", "background1", InputFile ); + background1.ActivateStatError( "background1_statUncert", InputFile ); + background1.AddOverallSys( "syst2", 0.95, 1.05 ); + chan.AddSample( background1 ); + + + // Background 1 + Sample background2( "background2", "background2", InputFile ); + background2.ActivateStatError(); + background2.AddOverallSys( "syst3", 0.95, 1.05 ); + chan.AddSample( background2 ); + + + // Done with this channel + // Add it to the measurement: + meas.AddChannel( chan ); + + // Collect the histograms from their files, + // print some output, + meas.CollectHistograms(); + meas.PrintTree(); + + // One can print XML code to an + // output directory: + // meas.PrintXML( "xmlFromCCode", meas.GetOutputFilePrefix() ); + + // Now, do the measurement + MakeModelAndMeasurementFast( meas ); + + +} diff --git a/tutorials/histfactory/example.py b/tutorials/histfactory/example.py new file mode 100755 index 0000000000000..7e69eaea8f895 --- /dev/null +++ b/tutorials/histfactory/example.py @@ -0,0 +1,94 @@ +#!/usr/bin/env python + +# +# A pyROOT script demonstrating +# an example of writing a HistFactory +# model using python +# +# This example was written to match +# the example.xml analysis in +# $ROOTSYS/tutorials/histfactory/ +# +# Written by George Lewis +# + + +def main(): + + try: + import ROOT + except: + print "It seems that pyROOT isn't properly configured" + return + + """ + Create a HistFactory measurement from python + """ + + InputFile = "./data/example.root" + + # Create the measurement + meas = ROOT.RooStats.HistFactory.Measurement("meas", "meas") + + meas.SetOutputFilePrefix( "./results/example_UsingPy" ) + meas.SetPOI( "SigXsecOverSM" ) + meas.AddConstantParam("Lumi") + meas.AddConstantParam("alpha_syst1") + + meas.SetLumi( 1.0 ) + meas.SetLumiRelErr( 0.10 ) + meas.SetExportOnly( False ) + + # Create a channel + + chan = ROOT.RooStats.HistFactory.Channel( "channel1" ) + chan.SetData( "data", InputFile ) + chan.SetStatErrorConfig( 0.05, "Poisson" ) + + # Now, create some samples + + # Create the signal sample + signal = ROOT.RooStats.HistFactory.Sample( "signal", "signal", InputFile ) + signal.AddOverallSys( "syst1", 0.95, 1.05 ) + signal.AddNormFactor( "SigXsecOverSM", 1, 0, 3 ) + chan.AddSample( signal ) + + + # Background 1 + background1 = ROOT.RooStats.HistFactory.Sample( "background1", "background1", InputFile ) + background1.ActivateStatError( "background1_statUncert", InputFile ) + background1.AddOverallSys( "syst2", 0.95, 1.05 ) + chan.AddSample( background1 ) + + + # Background 1 + background2 = ROOT.RooStats.HistFactory.Sample( "background2", "background2", InputFile ) + background2.ActivateStatError() + background2.AddOverallSys( "syst3", 0.95, 1.05 ) + chan.AddSample( background2 ) + + + # Done with this channel + # Add it to the measurement: + + meas.AddChannel( chan ) + + # Collect the histograms from their files, + # print some output, + meas.CollectHistograms() + meas.PrintTree(); + + # One can print XML code to an + # output directory: + # meas.PrintXML( "xmlFromCCode", meas.GetOutputFilePrefix() ); + + meas.PrintXML( "xmlFromPy", meas.GetOutputFilePrefix() ); + + # Now, do the measurement + ROOT.RooStats.HistFactory.MakeModelAndMeasurementFast( meas ); + + pass + + +if __name__ == "__main__": + main() diff --git a/tutorials/histfactory/makeQuickModel.py b/tutorials/histfactory/makeQuickModel.py new file mode 100755 index 0000000000000..4c0e30d0252c5 --- /dev/null +++ b/tutorials/histfactory/makeQuickModel.py @@ -0,0 +1,200 @@ +#!/usr/bin/env python + +# +# A pyROOT script that allows one to +# make quick measuremenst. +# +# This is a command-line script that +# takes in signal and background values, +# as well as potentially uncertainties on those +# values, and returns a fitted signal value +# and errors + + +def main(): + """ Create a simple model and run statistical tests + + This script can be used to make simple statistical using histfactory. + It takes values for signal, background, and data as input, and + can optionally take uncertainties on signal or background. + The model is created and saved to an output ROOT file, and + the model can be fit if requested. + + """ + + # Let's parse the input + # Define the command line options of the script: + import optparse + desc = " ".join(main.__doc__.split()) + + vers = "0.1" + parser = optparse.OptionParser( description = desc, version = vers, usage = "%prog [options]" ) + + parser.add_option( "-s", "--signal", dest = "signal", + action = "store", type = "float", default=None, + help = "Expected Signal" ) + + parser.add_option( "-b", "--background", dest = "background", + action = "store", type = "float", default=None, + help = "Expected Background" ) + + parser.add_option( "-d", "--data", dest = "data", + action = "store", type = "float", default=None, + help = "Measured data" ) + + parser.add_option( "--signal-uncertainty", dest = "signal_uncertainty", + action = "store", type = "float", default=None, + help = "Uncertainty on the signal rate, as a fraction. --signal-uncertainty=.05 means a 5% uncertainty." ) + + parser.add_option( "--background-uncertainty", dest = "background_uncertainty", + action = "store", type = "float", default=None, + help = "Uncertainty on the background rate, as a fraction, not a percentage. --background-uncertainty=.05 means a 5% uncertainty." ) + + parser.add_option( "--output-prefix", dest = "output_prefix", + action = "store", type = "string", default="Measurement", + help = "Prefix for output files when using export. Can include directories (ie 'MyDirectory/MyPrefix')" ) + + parser.add_option( "-e", "--export", dest = "export", + action = "store_true", default=False, + help = "Make output plots, graphs, and save the workspace." ) + + # Parse the command line options: + ( options, unknown ) = parser.parse_args() + + # Make a log + # Set the format of the log messages: + FORMAT = 'Py:%(name)-25s %(levelname)-8s %(message)s' + import logging + logging.basicConfig( format = FORMAT ) + # Create the logger object: + logger = logging.getLogger( "makeQuickMeasurement" ) + # Set the following to DEBUG when debugging the scripts: + logger.setLevel( logging.INFO ) + + # So a small sanity check: + if len( unknown ): + logger.warning( "Options(s) not recognised: [" + ",".join( unknown ) + "]" ) + + # Ensure that all necessary input has been supplied + if options.signal == None: + logger.error( "You have to define a value for expacted signal (use --signal)" ) + return 255 + + if options.background == None: + logger.error( "You have to define a value for expacted background (use --background)" ) + return 255 + + if options.data == None: + logger.error( "You have to define a value for measured data (use --data)" ) + return 255 + + + # Okay, if all input is acceptable, we simply pass + # it to the MakeSimpleMeasurement function, which + # does the real work. + + MakeSimpleMeasurement( signal_val=options.signal, background_val=options.background, data_val=options.data, + signal_uncertainty=options.signal_uncertainty, background_uncertainty=options.background_uncertainty, + Export=options.export, output_prefix=options.output_prefix) + return + + +def MakeSimpleMeasurement( signal_val, background_val, data_val, signal_uncertainty=None, background_uncertainty=None, + Export=False, output_prefix="Measurement"): + """ Make a simple measurement using HistFactory + + Take in simple values for signal, background data, + and potentially uncertainty on signal and background + + """ + + try: + import ROOT + except: + print "It seems that pyROOT isn't properly configured" + return + + # Create and name a measurement + # Set the Parameter of interest, and set several + # other parameters to be constant + meas = ROOT.RooStats.HistFactory.Measurement("meas", "meas") + meas.SetOutputFilePrefix( output_prefix ) + meas.SetPOI( "SigXsecOverSM" ) + + # We don't include Lumi here, + # but since HistFactory gives it to + # us for free, we set it constant + # The values are just dummies + + meas.SetLumi( 1.0 ) + meas.SetLumiRelErr( 0.10 ) + meas.AddConstantParam("Lumi") + + # We set ExportOnly to false. This parameter + # defines what happens when we run MakeMeasurementAndModelFast + # If we DO run that function, we also want it to export. + meas.SetExportOnly( False ) + + # Create a channel and set + # the measured value of data + # (no extenal hist necessar for cut-and-count) + chan = ROOT.RooStats.HistFactory.Channel( "channel" ) + chan.SetData( data_val ) + + # Create the signal sample and set it's value + signal = ROOT.RooStats.HistFactory.Sample( "signal" ) + signal.SetNormalizeByTheory( False ) + signal.SetValue( signal_val ) + #signal.SetValue( 10 ) + + # Add the parmaeter of interest and a systematic + # Try to make intelligent choice of upper bound + import math + upper_bound = 3*math.ceil( (data_val - background_val) / signal_val ) + upper_bound = max(upper_bound, 3) + signal.AddNormFactor( "SigXsecOverSM", 1, 0, upper_bound ) + + # If we have a signal uncertainty, add it too + if signal_uncertainty != None: + uncertainty_up = 1.0 + signal_uncertainty + uncertainty_down = 1.0 - signal_uncertainty + signal.AddOverallSys( "signal_uncertainty", uncertainty_down, uncertainty_up ) + + # Finally, add this sample to the channel + chan.AddSample( signal ) + + # Create a background sample + background = ROOT.RooStats.HistFactory.Sample( "background" ) + background.SetNormalizeByTheory( False ) + background.SetValue( background_val ) + + # If we have a background uncertainty, add it too + if background_uncertainty != None: + uncertainty_up = 1.0 + background_uncertainty + uncertainty_down = 1.0 - background_uncertainty + background.AddOverallSys( "background_uncertainty", uncertainty_down, uncertainty_up ) + + # Finally, add this sample to the channel + chan.AddSample( background ) + + # Add this channel to the measurement + # There is only this one channel, after all + meas.AddChannel( chan ) + + # Now, do the measurement + if Export: + workspace = ROOT.RooStats.HistFactory.MakeModelAndMeasurementFast( meas ) + return workspace + + else: + factory = ROOT.RooStats.HistFactory.HistoToWorkspaceFactoryFast() + workspace = factory.MakeCombinedModel( meas ) + #workspace = ROOT.RooStats.HistFactory.HistoToWorkspaceFactoryFast.MakeCombinedModel( meas ) + ROOT.RooStats.HistFactory.FitModel( workspace ) + + # At this point, we are done + return + + +if __name__ == "__main__": + main() diff --git a/tutorials/image/image2hist.C b/tutorials/image/image2hist.C new file mode 100644 index 0000000000000..2055c0f4e1703 --- /dev/null +++ b/tutorials/image/image2hist.C @@ -0,0 +1,23 @@ +//Create a 2-D histogram from an image. +//Author: Olivier Couet + +void image2hist() +{ + TASImage image("rose512.jpg"); + UInt_t yPixels = image.GetHeight(); + UInt_t xPixels = image.GetWidth(); + UInt_t *argb = image.GetArgbArray(); + + TH2D* h = new TH2D("h","Rose histogram",xPixels,-1,1,yPixels,-1,1); + + for (int row=0; row<xPixels; ++row) { + for (int col=0; col<yPixels; ++col) { + int index = col*xPixels+row; + float grey = float(argb[index]&0xff)/256; + h->SetBinContent(row+1,yPixels-col,grey); + } + } + + gStyle->SetPalette(53); + h->Draw("colz"); +} diff --git a/tutorials/math/kdTreeBinning.C b/tutorials/math/kdTreeBinning.C index e697373d42b4f..b57642d900ce3 100644 --- a/tutorials/math/kdTreeBinning.C +++ b/tutorials/math/kdTreeBinning.C @@ -27,17 +27,19 @@ void kdTreeBinning() { // C r e a t e r a n d o m s a m p l e w i t h r e g u l a r b i n n i n g p l o t t i n g // ----------------------------------------------------------------------------------------------- - const UInt_t DATASZ = 100000; + const UInt_t DATASZ = 10000; const UInt_t DATADIM = 2; - const UInt_t NBINS = 100; + const UInt_t NBINS = 50; Double_t smp[DATASZ * DATADIM]; + double mu[2] = {0,2}; + double sig[2] = {2,3}; TRandom3 r; r.SetSeed(1); for (UInt_t i = 0; i < DATADIM; ++i) for (UInt_t j = 0; j < DATASZ; ++j) - smp[DATASZ * i + j] = r.Gaus(0., 2.); + smp[DATASZ * i + j] = r.Gaus(mu[i], sig[i]); UInt_t h1bins = (UInt_t) sqrt(NBINS); @@ -45,43 +47,42 @@ void kdTreeBinning() { for (UInt_t j = 0; j < DATASZ; ++j) h1->Fill(smp[j], smp[DATASZ + j]); - TCanvas* c1 = new TCanvas("c1", "c1"); - c1->Update(); - c1->cd(1); - - h1->Draw("LEGO"); // --------------------------------------------------------------------------------------------- // C r e a t e K D T r e e B i n n i n g o b j e c t w i t h T H 2 P o l y p l o t t i n g // --------------------------------------------------------------------------------------------- - TKDTreeBinning* fBins = new TKDTreeBinning(DATASZ, DATADIM, smp, NBINS); + TKDTreeBinning* kdBins = new TKDTreeBinning(DATASZ, DATADIM, smp, NBINS); - UInt_t nbins = fBins->GetNBins(); - UInt_t dim = fBins->GetDim(); + UInt_t nbins = kdBins->GetNBins(); + UInt_t dim = kdBins->GetDim(); - const Double_t* binsMinEdges = fBins->GetBinsMinEdges(); - const Double_t* binsMaxEdges = fBins->GetBinsMaxEdges(); + const Double_t* binsMinEdges = kdBins->GetBinsMinEdges(); + const Double_t* binsMaxEdges = kdBins->GetBinsMaxEdges(); gStyle->SetCanvasPreferGL(1); - TH2Poly* h2pol = new TH2Poly("h2PolyBinTest", "KDTree binning", fBins->GetDataMin(0), fBins->GetDataMax(0), fBins->GetDataMin(1), fBins->GetDataMax(1)); + TH2Poly* h2pol = new TH2Poly("h2PolyBinTest", "KDTree binning", kdBins->GetDataMin(0), kdBins->GetDataMax(0), kdBins->GetDataMin(1), kdBins->GetDataMax(1)); for (UInt_t i = 0; i < nbins; ++i) { UInt_t edgeDim = i * dim; h2pol->AddBin(binsMinEdges[edgeDim], binsMinEdges[edgeDim + 1], binsMaxEdges[edgeDim], binsMaxEdges[edgeDim + 1]); } - for (UInt_t i = 1; i <= fBins->GetNBins(); ++i) - h2pol->SetBinContent(i, fBins->GetBinDensity(i - 1)); + for (UInt_t i = 1; i <= kdBins->GetNBins(); ++i) + h2pol->SetBinContent(i, kdBins->GetBinDensity(i - 1)); + + std::cout << "Bin with minimum density: " << kdBins->GetBinMinDensity() << std::endl; + std::cout << "Bin with maximum density: " << kdBins->GetBinMaxDensity() << std::endl; - std::cout << "Bin with minimum density: " << fBins->GetBinMinDensity() << std::endl; - std::cout << "Bin with maximum density: " << fBins->GetBinMaxDensity() << std::endl; + TCanvas* c1 = new TCanvas("glc1", "TH2Poly from a kdTree",0,0,600,1000); + c1->Divide(1,3); + c1->cd(1); + h1->Draw("lego"); - TCanvas* c2 = new TCanvas("glc2", "c2"); - c2->Update(); - c2->cd(1); + c1->cd(2); + h2pol->Draw("COLZ L"); + c1->Update(); - h2pol->Draw("gllego"); /* Draw an equivalent plot showing the data points */ /*-------------------------------------------------*/ @@ -94,48 +95,84 @@ void kdTreeBinning() { gStyle->SetPalette(1); g->SetMarkerStyle(20); - TCanvas* c3 = new TCanvas("c3", "c3"); - c3->Update(); - c3->cd(1); + c1->cd(3); g->Draw("pcol"); + c1->Update(); + // --------------------------------------------------------- - // R e b i n t h e K D T r e e B i n n i n g o b j e c t + // make a new TH2Poly where bins are ordered by the density // --------------------------------------------------------- - fBins->SetNBins(200); - TH2Poly* h2polrebin = new TH2Poly("h2PolyBinTest", "KDTree binning", fBins->GetDataMin(0), fBins->GetDataMax(0), fBins->GetDataMin(1), fBins->GetDataMax(1)); + TH2Poly* h2polrebin = new TH2Poly("h2PolyBinTest", "KDTree binning", kdBins->GetDataMin(0), kdBins->GetDataMax(0), kdBins->GetDataMin(1), kdBins->GetDataMax(1)); h2polrebin->SetFloat(); + /*---------------------------------*/ /* Sort the bins by their density */ /*---------------------------------*/ - fBins->SortBinsByDensity(); + kdBins->SortBinsByDensity(); - for (UInt_t i = 0; i < fBins->GetNBins(); ++i) { - const Double_t* binMinEdges = fBins->GetBinMinEdges(i); - const Double_t* binMaxEdges = fBins->GetBinMaxEdges(i); + for (UInt_t i = 0; i < kdBins->GetNBins(); ++i) { + const Double_t* binMinEdges = kdBins->GetBinMinEdges(i); + const Double_t* binMaxEdges = kdBins->GetBinMaxEdges(i); h2polrebin->AddBin(binMinEdges[0], binMinEdges[1], binMaxEdges[0], binMaxEdges[1]); } - for (UInt_t i = 1; i <= fBins->GetNBins(); ++i){ - h2polrebin->SetBinContent(i, fBins->GetBinDensity(i - 1));} + for (UInt_t i = 1; i <= kdBins->GetNBins(); ++i){ + h2polrebin->SetBinContent(i, kdBins->GetBinDensity(i - 1));} - std::cout << "Bin with minimum density: " << fBins->GetBinMinDensity() << std::endl; - std::cout << "Bin with maximum density: " << fBins->GetBinMaxDensity() << std::endl; + std::cout << "Bin with minimum density: " << kdBins->GetBinMinDensity() << std::endl; + std::cout << "Bin with maximum density: " << kdBins->GetBinMaxDensity() << std::endl; + // now make a vector with bin number vs position for (UInt_t i = 0; i < DATASZ; ++i) - z[i] = (Double_t) h2polrebin->GetBin(h2polrebin->FindBin(smp[i], smp[DATASZ + i])); + z[i] = (Double_t) h2polrebin->FindBin(smp[i], smp[DATASZ + i]); - TCanvas* c4 = new TCanvas("glc4", "TH2Poly with kd-tree bin data",10,10,700,700); - c4->Update(); - c4->Divide(1,2); + TGraph2D *g2 = new TGraph2D(DATASZ, smp, &smp[DATASZ], &z[0]); + g2->SetMarkerStyle(20); + + + // plot new TH2Poly (ordered one) and TGraph2D + // The new TH2Poly has to be same as old one and the TGraph2D should be similar to + // the previous one. It is now made using as z value the bin number + + TCanvas* c4 = new TCanvas("glc4", "TH2Poly from a kdTree (Ordered)",50,50,1050,1050); + + c4->Divide(2,2); c4->cd(1); - h2polrebin->Draw("COLZ"); // draw as scatter plot + h2polrebin->Draw("COLZ L"); // draw as scatter plot c4->cd(2); - h2polrebin->Draw("gllego"); // draw as lego + g2->Draw("pcol"); + + c4->Update(); + + + // make also the 1D binned histograms + + TKDTreeBinning* kdX = new TKDTreeBinning(DATASZ, 1, &smp[0], 20); + TKDTreeBinning* kdY = new TKDTreeBinning(DATASZ, 1, &smp[DATASZ], 40); + + + kdX->SortOneDimBinEdges(); + kdY->SortOneDimBinEdges(); + + TH1* hX=new TH1F("hX", "X projection", kdX->GetNBins(), kdX->GetOneDimBinEdges()); + for(UInt_t i=0; i<kdX->GetNBins(); ++i){ + hX->SetBinContent(i+1, kdX->GetBinDensity(i)); + } + + TH1* hY=new TH1F("hY", "Y Projection", kdY->GetNBins(), kdY->GetOneDimBinEdges()); + for(UInt_t i=0; i<kdY->GetNBins(); ++i){ + hY->SetBinContent(i+1, kdY->GetBinDensity(i)); + } + + c4->cd(3); + hX->Draw(); + c4->cd(4); + hY->Draw(); } diff --git a/tutorials/math/quasirandom.C b/tutorials/math/quasirandom.C new file mode 100644 index 0000000000000..7ddd4d40b5e19 --- /dev/null +++ b/tutorials/math/quasirandom.C @@ -0,0 +1,109 @@ +//+______________________________________________________________________________ +// Example of generating quasi-random numbers + + + +#include "Math/QuasiRandom.h" +#include "Math/Random.h" +#include "TH2.h" +#include "TCanvas.h" +#include "TStopwatch.h" + +#include <iostream> + +using namespace ROOT::Math; + +int quasirandom(int n = 10000, int skip = 0) { + + + TH2D * h0 = new TH2D("h0","Pseudo-random Sequence",200,0,1,200,0,1); + TH2D * h1 = new TH2D("h1","Sobol Sequence",200,0,1,200,0,1); + TH2D * h2 = new TH2D("h2","Niederrer Sequence",200,0,1,200,0,1); + + RandomMT r0; + // quasi random numbers need to be created giving the dimension of the sequence + // in this case we generate 2-d sequence + + QuasiRandomSobol r1(2); + QuasiRandomNiederreiter r2(2); + + + // generate n random points + + double x[2]; + TStopwatch w; w.Start(); + for (int i = 0; i < n; ++i) { + r0.RndmArray(2,x); + h0->Fill(x[0],x[1]); + } + std::cout << "Time for gRandom "; + w.Print(); + + w.Start(); + if( skip>0) r1.Skip(skip); + for (int i = 0; i < n; ++i) { + r1.Next(x); + h1->Fill(x[0],x[1]); + } + std::cout << "Time for Sobol "; + w.Print(); + + + w.Start(); + if( skip>0) r2.Skip(skip); + for (int i = 0; i < n; ++i) { + r2.Next(x); + h2->Fill(x[0],x[1]); + } + std::cout << "Time for Niederreiter "; + w.Print(); + + + TCanvas * c1 = new TCanvas("c1","Random sequence",600,1200); + c1->Divide(1,3); + + c1->cd(1); + + h0->Draw("COLZ"); + + c1->cd(2); + + + // check uniformity + h1->Draw("COLZ"); + + c1->cd(3); + + h2->Draw("COLZ"); + + gPad->Update(); + + + // test number of empty bins + + int nzerobins0 = 0; + int nzerobins1 = 0; + int nzerobins2 = 0; + for (int i = 1; i <= h1->GetNbinsX(); ++i) { + for (int j = 1; j <= h1->GetNbinsY(); ++j) { + if (h0->GetBinContent(i,j) == 0 ) nzerobins0++; + if (h1->GetBinContent(i,j) == 0 ) nzerobins1++; + if (h2->GetBinContent(i,j) == 0 ) nzerobins2++; + } + } + + std::cout << "number of empty bins for pseudo-random = " << nzerobins0 << std::endl; + std::cout << "number of empty bins for " << r1.Name() << "\t= " << nzerobins1 << std::endl; + std::cout << "number of empty bins for " << r2.Name() << "\t= " << nzerobins2 << std::endl; + + int iret = 0; + if (nzerobins1 >= nzerobins0 ) iret += 1; + if (nzerobins2 >= nzerobins0 ) iret += 2; + return iret; + +} + + + + + diff --git a/tutorials/net/LDAPExample.C b/tutorials/net/LDAPExample.C index a34387d136be4..00e5d6deb3b6d 100644 --- a/tutorials/net/LDAPExample.C +++ b/tutorials/net/LDAPExample.C @@ -3,12 +3,17 @@ void LDAPExample() gSystem->Load("libRLDAP.so"); TLDAPServer *server = new TLDAPServer("ldap.cern.ch"); + if (!server->IsConnected()) { + printf("Could not connect to ldap.cern.ch\n"); + delete server; + return; + } TLDAPResult *result = server.Search(); if (result == 0) { printf("Search failed\n"); - exit(1); + return; } result->Print(); delete result; @@ -29,7 +34,7 @@ void LDAPExample() if (result == 0) { printf("Search failed\n"); - exit(1); + return; } result->Print(); diff --git a/tutorials/proof/ProcFileElements.C b/tutorials/proof/ProcFileElements.C index eb4f26b1cb145..245b7a703a4ee 100644 --- a/tutorials/proof/ProcFileElements.C +++ b/tutorials/proof/ProcFileElements.C @@ -71,7 +71,7 @@ Int_t ProcFileElements::ProcFileElement::Overlapping(ProcFileElement *e) return 1; } } else if (fFirst == e->fFirst) { - // Overlapping or illy adjacent + // Overlapping or adjacent if (fFirst == fLast || e->fFirst == e->fLast) return 0; return 1; } else { @@ -144,11 +144,11 @@ Int_t ProcFileElements::Add(Long64_t fst, Long64_t lst) return -1; } - // Create (tempoarry element) + // Create (temporary element) ProcFileElements::ProcFileElement *ne = new ProcFileElements::ProcFileElement(fst, lst); - // Check if if it is adjacent or overalapping with an existing one + // Check if if it is adjacent or overlapping with an existing one TIter nxe(fElements); ProcFileElements::ProcFileElement *e = 0; while ((e = (ProcFileElements::ProcFileElement *)nxe())) { @@ -167,11 +167,29 @@ Int_t ProcFileElements::Add(Long64_t fst, Long64_t lst) rc = 1; } - // New overall ranges - if (fElements) { - if ((e = (ProcFileElements::ProcFileElement *) fElements->First())) fFirst = e->fFirst; - if ((e = (ProcFileElements::ProcFileElement *) fElements->Last())) fLast = e->fLast; + // Make sure that all what can be merged is merged (because of the order, some elements + // which could be merged are not merged, making the determination of fFirst and fLast below + // to give incorrect values) + + ProcFileElements::ProcFileElement *ep = 0, *en = 0; + TObjLink *olp = fElements->FirstLink(), *oln = 0; + while (olp && (ep = (ProcFileElements::ProcFileElement *) olp->GetObject())) { + oln = olp->Next(); + while (oln) { + if ((en = (ProcFileElements::ProcFileElement *) oln->GetObject())) { + if (ep->MergeElement(en) == 0) { + fElements->Remove(en); + delete en; + } + } + oln = oln->Next(); + } + olp = olp->Next(); } + + // New overall ranges + if ((e = (ProcFileElements::ProcFileElement *) fElements->First())) fFirst = e->fFirst; + if ((e = (ProcFileElements::ProcFileElement *) fElements->Last())) fLast = e->fLast; // Done return rc; diff --git a/tutorials/proof/ProcFileElements.h b/tutorials/proof/ProcFileElements.h index a90d31fae1894..730086d71615f 100644 --- a/tutorials/proof/ProcFileElements.h +++ b/tutorials/proof/ProcFileElements.h @@ -30,9 +30,7 @@ class ProcFileElements : public TObject { -private: - - TString fName; // File name +public: class ProcFileElement : public TObject { public: Long64_t fFirst; // Lower bound of this range @@ -51,6 +49,9 @@ class ProcFileElements : public TObject { ClassDef(ProcFileElement, 1); // ProcFileElement class }; + +private: + TString fName; // File name TSortedList *fElements; // List of processed elements Long64_t fFirst; // Overall lower bound @@ -62,6 +63,7 @@ class ProcFileElements : public TObject { virtual ~ProcFileElements() { if (fElements) { fElements->SetOwner(); delete fElements; } } const char * GetName() const { return fName; } + ULong_t Hash() const { return fName.Hash(); } Int_t Add(Long64_t fst = 0, Long64_t lst = -1); Int_t Merge(TCollection *list); diff --git a/tutorials/proof/ProofAux.C b/tutorials/proof/ProofAux.C index 0a715a72799e2..fa5ab720c8e90 100644 --- a/tutorials/proof/ProofAux.C +++ b/tutorials/proof/ProofAux.C @@ -2,7 +2,7 @@ ////////////////////////////////////////////////////////////// // -// Selector used for auxilliary actions in the PROOF tutorials +// Selector used for auxiliary actions in the PROOF tutorials // ////////////////////////////////////////////////////////////// @@ -281,8 +281,14 @@ Int_t ProofAux::GenerateTree(const char *fnt, Long64_t ent, TString &fn) // Add to the list TString fds(fn); - if (!strcmp(uu.GetProtocol(), "file")) - fds.Insert(0, TString::Format("root://%s/", gSystem->HostName())); + if (!strcmp(uu.GetProtocol(), "file")) { + if (gSystem->Getenv("LOCALDATASERVER")) { + if (strcmp(TUrl(gSystem->Getenv("LOCALDATASERVER"), kTRUE).GetProtocol(), "file")) + fds.Insert(0, TString::Format("%s/", gSystem->Getenv("LOCALDATASERVER"))); + } else { + fds.Insert(0, TString::Format("root://%s/", gSystem->HostName())); + } + } fMainList->Add(new TObjString(fds)); // Done @@ -377,7 +383,7 @@ Int_t ProofAux::GenerateFriend(const char *fnt, const char *fnf) TTree *Tfrnd = new TTree("Tfrnd", "Friend tree for tutorial 'friends'"); Tfrnd->SetDirectory(fo); Float_t r = 0; - Tfrnd->Branch("r",&x,"r/F"); + Tfrnd->Branch("r",&r,"r/F"); Long64_t ent = Tin->GetEntries(); for (Long64_t i = 0; i < ent; i++) { b_x->GetEntry(i); @@ -403,8 +409,14 @@ Int_t ProofAux::GenerateFriend(const char *fnt, const char *fnf) // Add to the list TUrl uu(fout); - if (!strcmp(uu.GetProtocol(), "file")) - fout.Insert(0, TString::Format("root://%s/", gSystem->HostName())); + if (!strcmp(uu.GetProtocol(), "file")) { + if (gSystem->Getenv("LOCALDATASERVER")) { + if (strcmp(TUrl(gSystem->Getenv("LOCALDATASERVER"), kTRUE).GetProtocol(), "file")) + fout.Insert(0, TString::Format("%s/", gSystem->Getenv("LOCALDATASERVER"))); + } else { + fout.Insert(0, TString::Format("root://%s/", gSystem->HostName())); + } + } fFriendList->Add(new TObjString(fout)); // Done diff --git a/tutorials/proof/ProofAux.h b/tutorials/proof/ProofAux.h index 867b2faf59484..822cd9c553ea6 100644 --- a/tutorials/proof/ProofAux.h +++ b/tutorials/proof/ProofAux.h @@ -1,6 +1,6 @@ ////////////////////////////////////////////////////////////// // -// Selector used for auxilliary actions in the PROOF tutorials +// Selector used for auxiliary actions in the PROOF tutorials // ////////////////////////////////////////////////////////////// diff --git a/tutorials/proof/ProofEventProc.C b/tutorials/proof/ProofEventProc.C index 24fe9ad7291b2..2c4d50b3bcead 100644 --- a/tutorials/proof/ProofEventProc.C +++ b/tutorials/proof/ProofEventProc.C @@ -285,8 +285,8 @@ void ProofEventProc::CheckRanges() nout->SetTitle("ProcFileElements for first file not found in the output list"); return; } - if (pfef->fFirst != fst) { - TString t = TString::Format("First entry differs {found: %lld, expected: %lld}", pfef->fFirst, fst); + if (pfef->GetFirst() != fst) { + TString t = TString::Format("First entry differs {found: %lld, expected: %lld}", pfef->GetFirst(), fst); nout->SetTitle(t.Data()); return; } @@ -311,7 +311,7 @@ void ProofEventProc::CheckRanges() nout->SetTitle("ProcFileElements for last file not found in the output list"); return; } - if (pfel->fLast != lst) { + if (pfel->GetLast() != lst) { nout->SetTitle("Last entry differs"); return; } diff --git a/tutorials/proof/ProofNtuple.C b/tutorials/proof/ProofNtuple.C index 5f56cdae6e165..f8bb815f17139 100644 --- a/tutorials/proof/ProofNtuple.C +++ b/tutorials/proof/ProofNtuple.C @@ -29,6 +29,7 @@ ProofNtuple::~ProofNtuple() // Destructor SafeDelete(fNtp); + SafeDelete(fNtp2); SafeDelete(fFile); SafeDelete(fRandom); } @@ -138,6 +139,12 @@ void ProofNtuple::SlaveBegin(TTree * /*tree*/) fNtp->SetDirectory(fFile); fNtp->AutoSave(); + // Now we create the second ntuple + fNtp2 = new TNtuple("ntuple2","Demo ntuple2","vx:vy:vz"); + // File resident + fNtp2->SetDirectory(fFile); + fNtp2->AutoSave(); + // Should we generate the random numbers or take them from the ntuple ? TNamed *unr = (TNamed *) fInput->FindObject("PROOF_USE_NTP_RNDM"); if (unr) { @@ -200,6 +207,12 @@ Bool_t ProofNtuple::Process(Long64_t entry) Int_t i = (Int_t) entry; fNtp->Fill(px,py,pz,random,i); + if (!fNtp2) return kTRUE; + + // The second ntuple + Float_t vz = random * 2. - 1.; + fNtp2->Fill(px,py,vz); + return kTRUE; } @@ -220,13 +233,15 @@ void ProofNtuple::SlaveTerminate() TDirectory *savedir = gDirectory; if (fNtp->GetEntries() > 0) { fFile->cd(); - fNtp->Write(); + fNtp->Write(0, TObject::kOverwrite); + if (fNtp2 && fNtp2->GetEntries() > 0) fNtp2->Write(0, TObject::kOverwrite); fProofFile->Print(); fOutput->Add(fProofFile); } else { cleanup = kTRUE; } fNtp->SetDirectory(0); + if (fNtp2) fNtp2->SetDirectory(0); gDirectory = savedir; fFile->Close(); // Cleanup, if needed diff --git a/tutorials/proof/ProofNtuple.h b/tutorials/proof/ProofNtuple.h index a1663bfba4009..698d9f05d30b9 100644 --- a/tutorials/proof/ProofNtuple.h +++ b/tutorials/proof/ProofNtuple.h @@ -24,11 +24,12 @@ public : TFile *fFile; TProofOutputFile *fProofFile; // For optimized merging of the ntuple TNtuple *fNtp; + TNtuple *fNtp2; // To test double TTree in the same file TRandom3 *fRandom; Bool_t fPlotNtuple; TNtuple *fNtpRndm; // Ntuple with random numbers - ProofNtuple() : fFile(0), fProofFile(0), fNtp(0), fRandom(0), fPlotNtuple(kTRUE), fNtpRndm(0) { } + ProofNtuple() : fFile(0), fProofFile(0), fNtp(0), fNtp2(0), fRandom(0), fPlotNtuple(kTRUE), fNtpRndm(0) { } virtual ~ProofNtuple(); virtual Int_t Version() const { return 2; } virtual void Begin(TTree *tree); diff --git a/tutorials/proof/ProofSimple.C b/tutorials/proof/ProofSimple.C index a9e4bf8147c95..38de6d7551f36 100644 --- a/tutorials/proof/ProofSimple.C +++ b/tutorials/proof/ProofSimple.C @@ -22,6 +22,13 @@ #include <TStyle.h> #include <TSystem.h> #include <TParameter.h> +#include "TProof.h" +#include <TFile.h> +#include <TProofOutputFile.h> +#include <TNtuple.h> +#include <TFileCollection.h> +#include <TFileInfo.h> +#include <THashList.h> //_____________________________________________________________________________ ProofSimple::ProofSimple() @@ -33,6 +40,11 @@ ProofSimple::ProofSimple() fNhist3 = -1; fHist3 = 0; fRandom = 0; + fFile = 0; + fProofFile = 0; + fNtp = 0; + fHasNtuple = 0; + fPlotNtuple = kFALSE; } //_____________________________________________________________________________ @@ -40,7 +52,11 @@ ProofSimple::~ProofSimple() { // Destructor - if (fRandom) delete fRandom; + if (fFile) { + SafeDelete(fNtp); + SafeDelete(fFile); + } + SafeDelete(fRandom); } //_____________________________________________________________________________ @@ -77,9 +93,29 @@ void ProofSimple::Begin(TTree * /*tree*/) Ssiz_t from = iopt + strlen("nhist3="); if (option.Tokenize(s, from, ";") && s.IsDigit()) fNhist3 = s.Atoi(); } - if (fNhist3 > 0) { - fHist3 = new TH3F*[fNhist3]; - Info("Begin", "%d 3D histograms requested", fNhist3); + + // Ntuple + TNamed *nm = dynamic_cast<TNamed *>(fInput->FindObject("ProofSimple_Ntuple")); + if (nm) { + + // Title is in the form + // merge merge via file + // |<fout> location of the output file if merge + // |retrieve retrieve to client machine + // dataset create a dataset + // |<dsname> dataset name (default: dataset_ntuple) + // |plot for a final plot + // <empty> or other keep in memory + + fHasNtuple = 1; + + TString ontp(nm->GetTitle()); + if (ontp.Contains("|plot") || ontp == "plot") { + fPlotNtuple = kTRUE; + ontp.ReplaceAll("|plot", ""); + if (ontp == "plot") ontp = ""; + } + if (ontp.BeginsWith("dataset")) fHasNtuple = 2; } } @@ -140,12 +176,97 @@ void ProofSimple::SlaveBegin(TTree * /*tree*/) } } + + // Ntuple + TNamed *nm = dynamic_cast<TNamed *>(fInput->FindObject("ProofSimple_Ntuple")); + if (nm) { + + // Title is in the form + // merge merge via file + // |<fout> location of the output file if merge + // |retrieve retrieve to client machine + // dataset create a dataset + // |<dsname> dataset name (default: dataset_ntuple) + // |plot for a final plot + // <empty> or other keep in memory + + fHasNtuple = 1; + + TString ontp(nm->GetTitle()); + if (ontp.Contains("|plot") || ontp == "plot") { + fPlotNtuple = kTRUE; + ontp.ReplaceAll("|plot", ""); + if (ontp == "plot") ontp = ""; + } + TString locfn("SimpleNtuple.root"); + if (ontp.BeginsWith("merge")) { + ontp.Replace(0,5,""); + fProofFile = new TProofOutputFile(locfn, "M"); + TString fn; + Ssiz_t iret = ontp.Index("|retrieve"); + if (iret != kNPOS) { + fProofFile->SetRetrieve(kTRUE); + TString rettag("|retrieve"); + if ((iret = ontp.Index("|retrieve=")) != kNPOS) { + rettag += "="; + fn = ontp(iret + rettag.Length(), ontp.Length() - iret - rettag.Length()); + if ((iret = fn.Index('|')) != kNPOS) fn.Remove(iret); + rettag += fn; + } + ontp.ReplaceAll(rettag, ""); + } + Ssiz_t iof = ontp.Index('|'); + if (iof != kNPOS) ontp.Remove(0, iof + 1); + if (!ontp.IsNull()) { + fProofFile->SetOutputFileName(ontp.Data()); + if (fn.IsNull()) fn = gSystem->BaseName(TUrl(ontp.Data(), kTRUE).GetFile()); + } + if (fn.IsNull()) fn = locfn; + // This will be the final file on the client, the case there is one + fProofFile->SetTitle(fn); + } else if (ontp.BeginsWith("dataset")) { + ontp.Replace(0,7,""); + Ssiz_t iof = ontp.Index("|"); + if (iof != kNPOS) ontp.Remove(0, iof + 1); + TString dsname = (!ontp.IsNull()) ? ontp.Data() : "dataset_ntuple"; + UInt_t opt = TProofOutputFile::kRegister | TProofOutputFile::kOverwrite | TProofOutputFile::kVerify; + fProofFile = new TProofOutputFile("SimpleNtuple.root", + TProofOutputFile::kDataset, opt, dsname.Data()); + fHasNtuple = 2; + } else if (!ontp.IsNull()) { + Warning("SlaveBegin", "ntuple options unknown: ignored (%s)", ontp.Data()); + } + + // Open the file, if required + if (fProofFile) { + // Open the file + fFile = fProofFile->OpenFile("RECREATE"); + if (fFile && fFile->IsZombie()) SafeDelete(fFile); + + // Cannot continue + if (!fFile) { + Info("SlaveBegin", "could not create '%s': instance is invalid!", fProofFile->GetName()); + return; + } + } + + // Now we create the ntuple + fNtp = new TNtuple("ntuple","Demo ntuple","px:py:pz:random:i"); + // File resident, if required + if (fFile) { + fNtp->SetDirectory(fFile); + fNtp->AutoSave(); + } else { + fOutput->Add(fNtp); + } + } + // Set random seed fRandom = new TRandom3(0); } //_____________________________________________________________________________ -Bool_t ProofSimple::Process(Long64_t) +Bool_t ProofSimple::Process(Long64_t entry) { // The Process() function is called for each entry in the tree (or possibly // keyed object in the case of PROOF) to be processed. The entry argument @@ -177,10 +298,51 @@ Bool_t ProofSimple::Process(Long64_t) fHist3[i]->Fill(x,x,x); } } - + if (fNtp) FillNtuple(entry); + return kTRUE; } +//_____________________________________________________________________________ +void ProofSimple::FillNtuple(Long64_t entry) +{ + // The Process() function is called for each entry in the tree (or possibly + // keyed object in the case of PROOF) to be processed. The entry argument + // specifies which entry in the currently loaded tree is to be processed. + // It can be passed to either ProofNtuple::GetEntry() or TBranch::GetEntry() + // to read either all or the required parts of the data. When processing + // keyed objects with PROOF, the object is already loaded and is available + // via the fObject pointer. + // + // This function should contain the "body" of the analysis. It can contain + // simple or elaborate selection criteria, run algorithms on the data + // of the event and typically fill histograms. + // + // The processing can be stopped by calling Abort(). + // + // Use fStatus to set the return value of TTree::Process(). + // + // The return value is currently not used. + + if (!fNtp) return; + + // Fill ntuple + Float_t px, py, random; + if (fRandom) { + fRandom->Rannor(px,py); + random = fRandom->Rndm(); + } else { + Abort("no way to get random numbers! Stop processing", kAbortProcess); + return; + } + Float_t pz = px*px + py*py; + Int_t i = (Int_t) entry; + fNtp->Fill(px,py,pz,random,i); + + return; +} + + //_____________________________________________________________________________ void ProofSimple::SlaveTerminate() { @@ -188,6 +350,33 @@ void ProofSimple::SlaveTerminate() // have been processed. When running with PROOF SlaveTerminate() is called // on each slave server. + // Write the ntuple to the file + if (fFile) { + if (!fNtp) { + Error("SlaveTerminate", "'ntuple' is undefined!"); + return; + } + Bool_t cleanup = kFALSE; + TDirectory *savedir = gDirectory; + if (fNtp->GetEntries() > 0) { + fFile->cd(); + fNtp->Write(); + fProofFile->Print(); + fOutput->Add(fProofFile); + } else { + cleanup = kTRUE; + } + fNtp->SetDirectory(0); + gDirectory = savedir; + fFile->Close(); + // Cleanup, if needed + if (cleanup) { + TUrl uf(*(fFile->GetEndpointUrl())); + SafeDelete(fFile); + gSystem->Unlink(uf.GetFile()); + SafeDelete(fProofFile); + } + } } //_____________________________________________________________________________ @@ -210,14 +399,166 @@ void ProofSimple::Terminate() nside = (nside*nside < fNhist) ? nside+1 : nside; c1->Divide(nside,nside,0,0); + Bool_t tryfc = kFALSE; TH1F *h = 0; for (Int_t i=0; i < fNhist; i++) { - h = dynamic_cast<TH1F *>(fOutput->FindObject(Form("h%d",i))); + if (!(h = dynamic_cast<TH1F *>(TProof::GetOutput(Form("h%d",i), fOutput)))) { + // Not found: try TFileCollection + tryfc = kTRUE; + break; + } c1->cd(i+1); - if (h) h->DrawCopy(); + h->DrawCopy(); } + // If the histograms are not found they may be in files: is there a file collection? + if (tryfc && GetHistosFromFC(c1) != 0) { + Warning("Terminate", "histograms not found"); + } else { + // Final update + c1->cd(); + c1->Update(); + } + + // Process the ntuple, if required + if (fHasNtuple != 1 || !fPlotNtuple) return; + + if (!(fNtp = dynamic_cast<TNtuple *>(TProof::GetOutput("ntuple", fOutput)))) { + // Get the ntuple from the file + if ((fProofFile = + dynamic_cast<TProofOutputFile*>(fOutput->FindObject("SimpleNtuple.root")))) { + + TString outputFile(fProofFile->GetOutputFileName()); + TString outputName(fProofFile->GetName()); + outputName += ".root"; + Printf("outputFile: %s", outputFile.Data()); + + // Read the ntuple from the file + fFile = TFile::Open(outputFile); + if (fFile) { + Printf("Managed to open file: %s", outputFile.Data()); + fNtp = (TNtuple *) fFile->Get("ntuple"); + } else { + Error("Terminate", "could not open file: %s", outputFile.Data()); + } + if (!fFile) return; + + } else { + Error("Terminate", "TProofOutputFile not found"); + return; + } + } + // Plot ntuples + if (fNtp) PlotNtuple(fNtp, "proof ntuple"); +} + +//_____________________________________________________________________________ +void ProofSimple::PlotNtuple(TNtuple *ntp, const char *ntptitle) +{ + // Make some plots from the ntuple 'ntp' + + // + // Create a canvas, with 2 pads + // + TCanvas *c1 = new TCanvas(Form("cv-%s", ntp->GetName()), ntptitle,800,10,700,780); + c1->Divide(1,2); + TPad *pad1 = (TPad *) c1->GetPad(1); + TPad *pad2 = (TPad *) c1->GetPad(2); + // + // Display a function of one ntuple column imposing a condition + // on another column. + pad1->cd(); + pad1->SetGrid(); + pad1->SetLogy(); + pad1->GetFrame()->SetFillColor(15); + ntp->SetLineColor(1); + ntp->SetFillStyle(1001); + ntp->SetFillColor(45); + ntp->Draw("3*px+2","px**2+py**2>1"); + ntp->SetFillColor(38); + ntp->Draw("2*px+2","pz>2","same"); + ntp->SetFillColor(5); + ntp->Draw("1.3*px+2","(px^2+py^2>4) && py>0","same"); + pad1->RedrawAxis(); + + // + // Display a 3-D scatter plot of 3 columns. Superimpose a different selection. + pad2->cd(); + ntp->Draw("pz:py:px","(pz<10 && pz>6)+(pz<4 && pz>3)"); + ntp->SetMarkerColor(4); + ntp->Draw("pz:py:px","pz<6 && pz>4","same"); + ntp->SetMarkerColor(5); + ntp->Draw("pz:py:px","pz<4 && pz>3","same"); + TPaveText *l2 = new TPaveText(0.,0.6,0.9,0.95); + l2->SetFillColor(42); + l2->SetTextAlign(12); + l2->AddText("You can interactively rotate this view in 2 ways:"); + l2->AddText(" - With the RotateCube in clicking in this pad"); + l2->AddText(" - Selecting View with x3d in the View menu"); + l2->Draw(); + // Final update c1->cd(); c1->Update(); } + +//_____________________________________________________________________________ +Int_t ProofSimple::GetHistosFromFC(TCanvas *cv) +{ + // Check for the histograms in the files of a possible TFileCollection + + TIter nxo(fOutput); + TFileCollection *fc = 0; + Bool_t fc_found = kFALSE, hs_found = kFALSE; + while ((fc = (TFileCollection *) nxo())) { + if (strcmp(fc->ClassName(), "TFileCollection")) continue; + fc_found = kTRUE; + if (!fHist) { + fHist = new TH1F*[fNhist]; + for (Int_t i = 0; i < fNhist; i++) { fHist[i] = 0; } + } else { + for (Int_t i = 0; i < fNhist; i++) { SafeDelete(fHist[i]); } + } + // Go through the list of files + TIter nxf(fc->GetList()); + TFileInfo *fi = 0; + while ((fi = (TFileInfo *) nxf())) { + TFile *f = TFile::Open(fi->GetCurrentUrl()->GetUrl()); + if (f) { + for (Int_t i = 0; i < fNhist; i++) { + TString hn = TString::Format("h%d", i); + TH1F *h = (TH1F *) f->Get(hn); + if (h) { + hs_found = kTRUE; + if (!fHist[i]) { + fHist[i] = (TH1F *) h->Clone(); + fHist[i]->SetDirectory(0); + } else { + fHist[i]->Add(h); + } + } else { + Error("GetHistosFromFC", "histo '%s' not found in file '%s'", + hn.Data(), fi->GetCurrentUrl()->GetUrl()); + } + } + f->Close(); + } else { + Error("GetHistosFromFC", "file '%s' could not be open", fi->GetCurrentUrl()->GetUrl()); + } + } + if (hs_found) break; + } + if (!fc_found) return -1; + if (!hs_found) return -1; + + for (Int_t i = 0; i < fNhist; i++) { + cv->cd(i+1); + if (fHist[i]) { + fHist[i]->DrawCopy(); + } + } + Info("GetHistosFromFC", "histograms read from %d files in TFileCollection '%s'", + fc->GetList()->GetSize(), fc->GetName()); + // Done + return 0; +} diff --git a/tutorials/proof/ProofSimple.h b/tutorials/proof/ProofSimple.h index d8a6885b10f9e..c6a43f5c0bb46 100644 --- a/tutorials/proof/ProofSimple.h +++ b/tutorials/proof/ProofSimple.h @@ -14,17 +14,28 @@ class TH1F; class TH3F; +class TFile; +class TProofOutputFile; +class TNtuple; class TRandom3; +class TCanvas; class ProofSimple : public TSelector { public : // Specific members - Int_t fNhist; - TH1F **fHist;//![fNhist] - Int_t fNhist3; - TH3F **fHist3;//![fNhist3] - TRandom3 *fRandom;//! + Int_t fNhist; + TH1F **fHist;//![fNhist] + Int_t fNhist3; + TH3F **fHist3;//![fNhist3] + TFile *fFile; + TProofOutputFile *fProofFile; // For optimized merging of the ntuple + TNtuple *fNtp; + Bool_t fPlotNtuple; + Int_t fHasNtuple; + TRandom3 *fRandom;//! + + TH1F *fHLab;//! ProofSimple(); virtual ~ProofSimple(); @@ -38,6 +49,10 @@ public : virtual TList *GetOutputList() const { return fOutput; } virtual void SlaveTerminate(); virtual void Terminate(); + + void FillNtuple(Long64_t entry); + void PlotNtuple(TNtuple *, const char *); + Int_t GetHistosFromFC(TCanvas *); // Setters and getters (for TDataMember) Int_t GetNhist() { return fNhist; } @@ -45,7 +60,7 @@ public : Int_t GetNhist3() { return fNhist3; } void SetNhist3(Int_t nh) { fNhist3 = nh; } - ClassDef(ProofSimple,2); + ClassDef(ProofSimple,3); }; #endif diff --git a/tutorials/proof/ProofTests.C b/tutorials/proof/ProofTests.C index 5b10a4fbc5f88..32f80a31baee1 100644 --- a/tutorials/proof/ProofTests.C +++ b/tutorials/proof/ProofTests.C @@ -141,7 +141,12 @@ void ProofTests::SlaveBegin(TTree * /*tree*/) // at this point in the gEnv table TNamed *nm = dynamic_cast<TNamed*>(fInput->FindObject("testenv")); if (nm) { - if (gEnv->Lookup(nm->GetTitle())) fStat->Fill(2.); + if (gEnv->Lookup(nm->GetTitle())) { + fStat->Fill(2.); + } else { + Warning("SlaveBegin", "%d: lookup for '%s' failed!", fTestType, nm->GetTitle()); + gEnv->Print(); + } } else { Info("SlaveBegin", "%d: TNamed with the test env info not found!", fTestType); } diff --git a/tutorials/proof/getProof.C b/tutorials/proof/getProof.C index 27aa62cb17068..803017dc4c62d 100644 --- a/tutorials/proof/getProof.C +++ b/tutorials/proof/getProof.C @@ -114,6 +114,7 @@ TProof *getProof(const char *url = "proof://localhost:40000", Int_t nwrks = -1, swrk.Form("%d workers", nwrks); } lite = kTRUE; + gEnv->SetValue("Proof.MaxOldSessions", 1); Printf("getProof: trying to open a PROOF-Lite session with %s", swrk.Data()); } else { Printf("getProof: trying to open a session on the external cluster at '%s'", url); @@ -325,6 +326,8 @@ TProof *getProof(const char *url = "proof://localhost:40000", Int_t nwrks = -1, fprintf(fcf,"xpd.multiuser 1\n"); fprintf(fcf,"### Limit the number of query results kept in the master sandbox\n"); fprintf(fcf,"xpd.putrc ProofServ.UserQuotas: maxquerykept=10\n"); + fprintf(fcf,"### Limit the number of sessions kept in the sandbox\n"); + fprintf(fcf,"xpd.putrc Proof.MaxOldSessions: 1\n"); if (tutords) { fprintf(fcf,"### Use dataset directory under the tutorial dir\n"); fprintf(fcf,"xpd.datasetsrc file url:%s opt:-Cq:Av:As:\n", datasetdir.Data()); diff --git a/tutorials/proof/runProof.C b/tutorials/proof/runProof.C index 283aef9ba6275..c054cf360340f 100644 --- a/tutorials/proof/runProof.C +++ b/tutorials/proof/runProof.C @@ -488,7 +488,7 @@ void runProof(const char *what = "simple", aFeedback("fb=stats"); Long64_t suf = 1; Int_t aSubMg = -1; - Bool_t fillList = kFALSE, useList = kFALSE, makePerfTree = kFALSE; + Bool_t useList = kFALSE, makePerfTree = kFALSE; while (args.Tokenize(tok, from, " ")) { // Debug controllers if (tok.BeginsWith("debug=")) { @@ -564,7 +564,6 @@ void runProof(const char *what = "simple", useList = kTRUE; } if (tok.BeginsWith("fillList")) { - fillList = kTRUE; opt += "fillList"; } // H1: change location of files? diff --git a/tutorials/pyroot/shapes.py b/tutorials/pyroot/shapes.py index dc13b9091c57a..4d8bcd4fc47ba 100755 --- a/tutorials/pyroot/shapes.py +++ b/tutorials/pyroot/shapes.py @@ -8,8 +8,7 @@ c1 = ROOT.TCanvas( 'c1', 'Geometry Shapes', 200, 10, 700, 500 ) # delete previous geometry objects in case this script is reexecuted -if ROOT.gGeometry: - print ROOT.gGeometry +if hasattr(ROOT, 'gGeometry'): ROOT.gGeometry.GetListOfNodes().Delete() ROOT.gGeometry.GetListOfShapes().Delete() diff --git a/tutorials/pythia/pythia8.C b/tutorials/pythia/pythia8.C index bf91d911bd0e0..955176e6c5de2 100644 --- a/tutorials/pythia/pythia8.C +++ b/tutorials/pythia/pythia8.C @@ -31,7 +31,9 @@ void pythia8(Int_t nev = 100, Int_t ndeb = 1) } // Load libraries +#ifndef G__WIN32 // Pythia8 is a static library on Windows gSystem->Load("$PYTHIA8/lib/libpythia8"); +#endif gSystem->Load("libEG"); gSystem->Load("libEGPythia8"); // Histograms diff --git a/tutorials/roofit/rf201_composite.C b/tutorials/roofit/rf201_composite.C index 3f9b0cb2b3d89..34021bae9efea 100644 --- a/tutorials/roofit/rf201_composite.C +++ b/tutorials/roofit/rf201_composite.C @@ -33,7 +33,7 @@ void rf201_composite() // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/tutorials/roofit/rf202_extendedmlfit.C b/tutorials/roofit/rf202_extendedmlfit.C index ed6587eaf2477..7e999a33fec1a 100644 --- a/tutorials/roofit/rf202_extendedmlfit.C +++ b/tutorials/roofit/rf202_extendedmlfit.C @@ -34,7 +34,7 @@ void rf202_extendedmlfit() // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/tutorials/roofit/rf204_extrangefit.C b/tutorials/roofit/rf204_extrangefit.C index e72b3f0b2a7a7..1e582663868e3 100644 --- a/tutorials/roofit/rf204_extrangefit.C +++ b/tutorials/roofit/rf204_extrangefit.C @@ -37,7 +37,7 @@ void rf204_extrangefit() // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/tutorials/roofit/rf205_compplot.C b/tutorials/roofit/rf205_compplot.C index fb8a40c197c53..53fd1224db812 100644 --- a/tutorials/roofit/rf205_compplot.C +++ b/tutorials/roofit/rf205_compplot.C @@ -33,7 +33,7 @@ void rf205_compplot() // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/tutorials/roofit/rf206_treevistools.C b/tutorials/roofit/rf206_treevistools.C index c8bcf92125868..38159ea0b890e 100644 --- a/tutorials/roofit/rf206_treevistools.C +++ b/tutorials/roofit/rf206_treevistools.C @@ -33,7 +33,7 @@ void rf206_treevistools() // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/tutorials/roofit/rf207_comptools.C b/tutorials/roofit/rf207_comptools.C index 52c2eecd3c66b..ba6e177026e22 100644 --- a/tutorials/roofit/rf207_comptools.C +++ b/tutorials/roofit/rf207_comptools.C @@ -36,7 +36,7 @@ void rf207_comptools() // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma("sigma","width of gaussians",0.5) ; RooGaussian sig("sig","Signal component 1",x,mean,sigma) ; diff --git a/tutorials/roofit/rf407_latextables.C b/tutorials/roofit/rf407_latextables.C index 16d14970de918..0bf5c496fe8e5 100644 --- a/tutorials/roofit/rf407_latextables.C +++ b/tutorials/roofit/rf407_latextables.C @@ -34,7 +34,7 @@ void rf407_latextables() // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/tutorials/roofit/rf502_wspacewrite.C b/tutorials/roofit/rf502_wspacewrite.C index 9c0ec533eabfd..86dceb3350def 100644 --- a/tutorials/roofit/rf502_wspacewrite.C +++ b/tutorials/roofit/rf502_wspacewrite.C @@ -36,7 +36,7 @@ void rf502_wspacewrite() // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5,0,10) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/tutorials/roofit/rf507_debugtools.C b/tutorials/roofit/rf507_debugtools.C index bf5f46fb2f0b8..5bad673a6f062 100644 --- a/tutorials/roofit/rf507_debugtools.C +++ b/tutorials/roofit/rf507_debugtools.C @@ -55,7 +55,7 @@ void rf507_debugtools() RooAddPdf model("model","model",RooArgSet(gauss,poly),f) ; // Show object added to memory since marker - RooTrace::dump(cout,kTRUE) ; + RooTrace::printObjectCounts() ; // Since verbose mode is still on, you will see messages // pertaining to destructor calls of all RooFit objects diff --git a/tutorials/roofit/rf509_wsinteractive.C b/tutorials/roofit/rf509_wsinteractive.C index 47f3347e7fa7a..4e9e97e91e93f 100644 --- a/tutorials/roofit/rf509_wsinteractive.C +++ b/tutorials/roofit/rf509_wsinteractive.C @@ -84,7 +84,7 @@ void fillWorkspace(RooWorkspace& w) // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5,0,10) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/tutorials/roofit/rf510_wsnamedsets.C b/tutorials/roofit/rf510_wsnamedsets.C index b12ab5d02287c..2379981c68afa 100644 --- a/tutorials/roofit/rf510_wsnamedsets.C +++ b/tutorials/roofit/rf510_wsnamedsets.C @@ -83,7 +83,7 @@ void fillWorkspace(RooWorkspace& w) // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5,0,10) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/tutorials/roofit/rf601_intminuit.C b/tutorials/roofit/rf601_intminuit.C index 15a1a3cb65637..ee093f3950518 100644 --- a/tutorials/roofit/rf601_intminuit.C +++ b/tutorials/roofit/rf601_intminuit.C @@ -64,7 +64,7 @@ void rf601_intminuit() // Call MIGRAD to minimize the likelihood m.migrad() ; - // Print values of all paramaters, that reflect values (and error estimates) + // Print values of all parameters, that reflect values (and error estimates) // that are back propagated from MINUIT model.getParameters(x)->Print("s") ; diff --git a/tutorials/roofit/rf602_chi2fit.C b/tutorials/roofit/rf602_chi2fit.C index 3307d18ec3eb5..4852eb102e045 100644 --- a/tutorials/roofit/rf602_chi2fit.C +++ b/tutorials/roofit/rf602_chi2fit.C @@ -36,7 +36,7 @@ void rf602_chi2fit() // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/tutorials/roofit/rf607_fitresult.C b/tutorials/roofit/rf607_fitresult.C index 284393368f989..7471c0d6ed867 100644 --- a/tutorials/roofit/rf607_fitresult.C +++ b/tutorials/roofit/rf607_fitresult.C @@ -39,7 +39,7 @@ void rf607_fitresult() // Declare observable x RooRealVar x("x","x",0,10) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5,-10,10) ; RooRealVar sigma1("sigma1","width of gaussians",0.5,0.1,10) ; RooRealVar sigma2("sigma2","width of gaussians",1,0.1,10) ; @@ -79,7 +79,7 @@ void rf607_fitresult() // Summary printing: Basic info plus final values of floating fit parameters r->Print() ; - // Verbose printing: Basic info, values of constant paramaters, initial and + // Verbose printing: Basic info, values of constant parameters, initial and // final values of floating parameters, global correlations r->Print("v") ; diff --git a/tutorials/roofit/rf801_mcstudy.C b/tutorials/roofit/rf801_mcstudy.C index 9ed5268ab1c15..e3a58ff616aef 100644 --- a/tutorials/roofit/rf801_mcstudy.C +++ b/tutorials/roofit/rf801_mcstudy.C @@ -38,7 +38,7 @@ void rf801_mcstudy() RooRealVar x("x","x",0,10) ; x.setBins(40) ; - // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their paramaters + // Create two Gaussian PDFs g1(x,mean1,sigma) anf g2(x,mean2,sigma) and their parameters RooRealVar mean("mean","mean of gaussians",5,0,10) ; RooRealVar sigma1("sigma1","width of gaussians",0.5) ; RooRealVar sigma2("sigma2","width of gaussians",1) ; diff --git a/tutorials/roofit/rf904_interpnorm.C b/tutorials/roofit/rf904_interpnorm.C new file mode 100644 index 0000000000000..f16ed5cdb2e21 --- /dev/null +++ b/tutorials/roofit/rf904_interpnorm.C @@ -0,0 +1,77 @@ +////////////////////////////////////////////////////////////////////////// +// +// 'NUMERIC ALGORITHM TUNING' RooFit tutorial macro #904 +// +// Caching and interpolation of (numeric) pdf integrals to +// speed up calculations and to promote numeric stability +// +// 11/2012 - Wouter Verkerke +// +///////////////////////////////////////////////////////////////////////// + +#ifndef __CINT__ +#include "RooGlobalFunc.h" +#endif +#include "RooRealVar.h" +#include "RooDataSet.h" +#include "RooDataHist.h" +#include "RooGaussian.h" +#include "RooConstVar.h" +#include "TCanvas.h" +#include "TAxis.h" +#include "RooPlot.h" +#include "RooVoigtian.h" +#include "TFile.h" +#include "TH1.h" + +using namespace RooFit ; + + +void rf904_interpnorm(Bool_t cacheParamInt=kTRUE) +{ + // Report INFO messages on integration to see reporting on topic of this tutorial + RooMsgService::instance().addStream(INFO,Topic(Caching)) ; + + // Observable + RooRealVar m("m","m",0,100) ; + + + // Parameters + RooRealVar mass("mass","mass",50,0,100) ; + RooRealVar sigma("sigma","sigma",1,0.1,10) ; + RooRealVar width("width","width",1) ; + + // Voigtian is convolution of Gaussian and Breit-Wigner (with numerical normalization integral) + RooVoigtian v("v","v",m,mass,sigma,width) ; + + // Activate parameterized integral caching for (mass,sigma) parameters + // Set explicit binning for cache here to control precision (otherwise default binning of 100 bins is used) + if (cacheParamInt) { + sigma.setBins(20,"cache") ; + mass.setBins(20,"cache") ; + v.setStringAttribute("CACHEPARAMINT","mass:sigma") ; + } + + // Generate a dataset + RooDataSet* d = v.generate(m,100) ; + + // Fit model to data + v.fitTo(*d,Verbose(1)) ; + + + TCanvas* c = new TCanvas("c","c",800,400) ; + c->Divide(2) ; + + // Make plot of data and fitted pdf + RooPlot* frame = m.frame() ; + d->plotOn(frame) ; + v.plotOn(frame) ; + c->cd(1) ;frame->Draw() ; + + // Plot the (cached) normalization integral in (mass,sigma) plane + const RooAbsReal* nobj = v.getNormIntegral(m) ; + c->cd(2) ; nobj->createHistogram("mass,sigma")->Draw("surf") ; +} + + + diff --git a/tutorials/roostats/OneSidedFrequentistUpperLimitWithBands.C b/tutorials/roostats/OneSidedFrequentistUpperLimitWithBands.C index d26816360d793..c1f961e1f7968 100644 --- a/tutorials/roostats/OneSidedFrequentistUpperLimitWithBands.C +++ b/tutorials/roostats/OneSidedFrequentistUpperLimitWithBands.C @@ -116,6 +116,7 @@ This version does not deal with this issue, but it will be addressed in a future #include "RooStats/PointSetInterval.h" #include "RooStats/ConfidenceBelt.h" +#include "RooStats/RooStatsUtils.h" #include "RooStats/ProfileLikelihoodTestStat.h" using namespace RooFit; diff --git a/tutorials/roostats/StandardFrequentistDiscovery.C b/tutorials/roostats/StandardFrequentistDiscovery.C new file mode 100644 index 0000000000000..0254cac6a3c78 --- /dev/null +++ b/tutorials/roostats/StandardFrequentistDiscovery.C @@ -0,0 +1,212 @@ +// StandardFrequentistDiscovery + +/* + StandardFrequentistDiscovery + + Author: Sven Kreiss, Kyle Cranmer + date: May 2012 + + This is a standard demo that can be used with any ROOT file + prepared in the standard way. You specify: + - name for input ROOT file + - name of workspace inside ROOT file that holds model and data + - name of ModelConfig that specifies details for calculator tools + - name of dataset + + With default parameters the macro will attempt to run the + standard hist2workspace example and read the ROOT file + that it produces. + */ + +#include "TFile.h" +#include "TROOT.h" +#include "TH1F.h" +#include "TF1.h" +#include "TCanvas.h" +#include "TStopwatch.h" + +#include "RooWorkspace.h" +#include "RooAbsData.h" +#include "RooRandom.h" +#include "RooRealSumPdf.h" +#include "RooNumIntConfig.h" + +#include "RooStats/ModelConfig.h" +#include "RooStats/ToyMCImportanceSampler.h" +#include "RooStats/HypoTestResult.h" +#include "RooStats/HypoTestPlot.h" +#include "RooStats/SamplingDistribution.h" +#include "RooStats/ProfileLikelihoodTestStat.h" +#include "RooStats/SimpleLikelihoodRatioTestStat.h" +#include "RooStats/ProfileLikelihoodCalculator.h" +#include "RooStats/LikelihoodInterval.h" +#include "RooStats/LikelihoodIntervalPlot.h" + +#include "RooStats/FrequentistCalculator.h" + +#include <vector> + +using namespace RooFit; +using namespace RooStats; + + + + +double StandardFrequentistDiscovery( + const char* infile = "", + const char* workspaceName = "channel1", + const char* modelConfigNameSB = "ModelConfig", + const char* dataName = "obsData", + int toys = 1000, + double poiValueForBackground = 0.0, + double poiValueForSignal = 1.0 +) { + + // The workspace contains the model for s+b. The b model is "autogenerated" + // by copying s+b and setting the one parameter of interest to zero. + // To keep the script simple, multiple parameters of interest or different + // functional forms of the b model are not supported. + + // for now, assume there is only one parameter of interest, and these are + // its values: + + ///////////////////////////////////////////////////////////// + // First part is just to access a user-defined file + // or create the standard example file if it doesn't exist + //////////////////////////////////////////////////////////// + const char* filename = ""; + if (!strcmp(infile, "")) filename = "results/example_channel1_GammaExample_model.root"; + else filename = infile; + // Check if example input file exists + TFile *file = TFile::Open(filename); + + // if input file was specified but not found, quit + if (!file && strcmp(infile, "")) { + cout << "file not found" << endl; + } + + // if default file not found, try to create it + if (!file) { + // Normally this would be run on the command line + cout << "will run standard hist2workspace example" << endl; + gROOT->ProcessLine(".! prepareHistFactory ."); + gROOT->ProcessLine(".! hist2workspace config/example.xml"); + cout << "\n\n---------------------" << endl; + cout << "Done creating example input" << endl; + cout << "---------------------\n\n" << endl; + } + + // now try to access the file again + file = TFile::Open(filename); + if (!file) { + // if it is still not there, then we can't continue + cout << "Not able to run hist2workspace to create example input" << endl; + return -1.0; + } + + ///////////////////////////////////////////////////////////// + // Tutorial starts here + //////////////////////////////////////////////////////////// + + TStopwatch *mn_t = new TStopwatch; + mn_t->Start(); + + // get the workspace out of the file + RooWorkspace* w = (RooWorkspace*) file->Get(workspaceName); + if (!w) { + cout << "workspace not found" << endl; + return -1.0; + } + + // get the modelConfig out of the file + ModelConfig* mc = (ModelConfig*) w->obj(modelConfigNameSB); + + // get the data out of the file + RooAbsData* data = w->data(dataName); + + // make sure ingredients are found + if (!data || !mc) { + w->Print(); + cout << "data or ModelConfig was not found" << endl; + return -1.0; + } + + + RooRealVar* firstPOI = (RooRealVar*) mc->GetParametersOfInterest()->first(); + firstPOI->setVal(poiValueForSignal); + mc->SetSnapshot(*mc->GetParametersOfInterest()); + // create null model + ModelConfig *mcNull = mc->Clone("ModelConfigNull"); + firstPOI->setVal(poiValueForBackground); + mcNull->SetSnapshot(*(RooArgSet*)mcNull->GetParametersOfInterest()->snapshot()); + + + + // ---------------------------------------------------- + // Configure a ProfileLikelihoodTestStat and a SimpleLikelihoodRatioTestStat + // to use simultaneously with ToyMCSampler + ProfileLikelihoodTestStat* plts = new ProfileLikelihoodTestStat(*mc->GetPdf()); + plts->SetOneSidedDiscovery(true); + plts->SetVarName( "q_{0}/2" ); + + // ---------------------------------------------------- + // configure the ToyMCImportanceSampler with two test statistics + ToyMCSampler toymcs(*plts, 50); + + + + // Since this tool needs to throw toy MC the PDF needs to be + // extended or the tool needs to know how many entries in a dataset + // per pseudo experiment. + // In the 'number counting form' where the entries in the dataset + // are counts, and not values of discriminating variables, the + // datasets typically only have one entry and the PDF is not + // extended. + if (!mc->GetPdf()->canBeExtended()) { + if (data->numEntries() == 1) { + toymcs.SetNEventsPerToy(1); + } else cout << "Not sure what to do about this model" << endl; + } + + // We can use PROOF to speed things along in parallel + // ProofConfig pc(*w, 2, "user@yourfavoriteproofcluster", false); + ProofConfig pc(*w, 2, "", false); + //toymcs.SetProofConfig(&pc); // enable proof + + + // instantiate the calculator + FrequentistCalculator freqCalc(*data, *mc, *mcNull, &toymcs); + freqCalc.SetToys( toys,toys ); // null toys, alt toys + + // Run the calculator and print result + HypoTestResult* freqCalcResult = freqCalc.GetHypoTest(); + freqCalcResult->GetNullDistribution()->SetTitle( "b only" ); + freqCalcResult->GetAltDistribution()->SetTitle( "s+b" ); + freqCalcResult->Print(); + double pvalue = freqCalcResult->NullPValue(); + + // stop timing + mn_t->Stop(); + cout << "total CPU time: " << mn_t->CpuTime() << endl; + cout << "total real time: " << mn_t->RealTime() << endl; + + // plot + TCanvas* c1 = new TCanvas(); + HypoTestPlot *plot = new HypoTestPlot(*freqCalcResult, 100, -0.49, 9.51 ); + plot->SetLogYaxis(true); + + // add chi2 to plot + int nPOI = 1; + TF1* f = new TF1("f", TString::Format("1*ROOT::Math::chisquared_pdf(2*x,%d,0)",nPOI), 0,20); + f->SetLineColor( kBlack ); + f->SetLineStyle( 7 ); + plot->AddTF1( f, TString::Format("#chi^{2}(2x,%d)",nPOI) ); + + plot->Draw(); + c1->SaveAs("standard_discovery_output.pdf"); + + + return pvalue; +} + + diff --git a/tutorials/roostats/StandardHypoTestDemo.C b/tutorials/roostats/StandardHypoTestDemo.C index b268ff5f3fa80..d5497deeb7ed6 100644 --- a/tutorials/roostats/StandardHypoTestDemo.C +++ b/tutorials/roostats/StandardHypoTestDemo.C @@ -237,9 +237,6 @@ void StandardHypoTestDemo(const char* infile = "", RooArgSet nullParams(*bModel->GetSnapshot()); if (bModel->GetNuisanceParameters()) nullParams.add(*bModel->GetNuisanceParameters()); - cout << "MODEL PARAMETERS ! " << endl; - nullParams.Print("v"); - slrts->SetNullParameters(nullParams); RooArgSet altParams(*sbModel->GetSnapshot()); if (sbModel->GetNuisanceParameters()) altParams.add(*sbModel->GetNuisanceParameters()); @@ -273,9 +270,11 @@ void StandardHypoTestDemo(const char* infile = "", if (calcType == 1) ((HybridCalculator*)hypoCalc)->SetToys(ntoys, ntoys/nToysRatio); if (calcType == 2 ) { - //if (testStatType == 3) ((AsymptoticCalculator*) hypoCalc)->SetOneSided(true); + if (testStatType == 3) ((AsymptoticCalculator*) hypoCalc)->SetOneSidedDiscovery(true); if (testStatType != 2 && testStatType != 3) Warning("StandardHypoTestDemo","Only the PL test statistic can be used with AsymptoticCalculator - use by default a two-sided PL"); + + } diff --git a/tutorials/roostats/StandardHypoTestInvDemo.C b/tutorials/roostats/StandardHypoTestInvDemo.C index 194aa0dea2597..7b041903f11ed 100644 --- a/tutorials/roostats/StandardHypoTestInvDemo.C +++ b/tutorials/roostats/StandardHypoTestInvDemo.C @@ -57,6 +57,7 @@ #include "RooStats/HypoTestInverterResult.h" #include "RooStats/HypoTestInverterPlot.h" + using namespace RooFit; using namespace RooStats; @@ -80,6 +81,13 @@ int initialFit = -1; // do a first fit to the model (-1 : d int randomSeed = -1; // random seed (if = -1: use default value, if = 0 always random ) // NOTE: Proof uses automatically a random seed +int nAsimovBins = 0; // number of bins in observables used for Asimov data sets (0 is the default and it is given by workspace, typically is 100) + +bool reuseAltToys = false; // reuse same toys for alternate hypothesis (if set one gets more stable bands) + + + + std::string massValue = ""; // extra string to tag output file of result std::string minimizerType = ""; // minimizer type (default is what is in ROOT::Math::MinimizerOptions::DefaultMinimizerType() int printLevel = 0; // print level for debugging PL test statistics and calculators @@ -130,6 +138,7 @@ namespace RooStats { bool mGenerateBinned; bool mUseProof; bool mRebuild; + bool mReuseAltToys; int mNWorkers; int mNToyToRebuild; int mPrintLevel; @@ -137,6 +146,7 @@ namespace RooStats { int mRandomSeed; double mNToysRatio; double mMaxPoi; + int mAsimovBins; std::string mMassValue; std::string mMinimizerType; // minimizer type (default is what is in ROOT::Math::MinimizerOptions::DefaultMinimizerType() TString mResultFileName; @@ -151,6 +161,7 @@ RooStats::HypoTestInvTool::HypoTestInvTool() : mPlotHypoTestResult(true), mGenerateBinned(false), mUseProof(false), mRebuild(false), + mReuseAltToys(false), mNWorkers(4), mNToyToRebuild(100), mPrintLevel(0), @@ -158,6 +169,7 @@ RooStats::HypoTestInvTool::HypoTestInvTool() : mPlotHypoTestResult(true), mRandomSeed(-1), mNToysRatio(2), mMaxPoi(-1), + mAsimovBins(0), mMassValue(""), mMinimizerType(""), mResultFileName() { @@ -180,6 +192,7 @@ RooStats::HypoTestInvTool::SetParameter(const char * name, bool value){ if (s_name.find("GenerateBinned") != std::string::npos) mGenerateBinned = value; if (s_name.find("UseProof") != std::string::npos) mUseProof = value; if (s_name.find("Rebuild") != std::string::npos) mRebuild = value; + if (s_name.find("ReuseAltToys") != std::string::npos) mReuseAltToys = value; return; } @@ -199,6 +212,7 @@ RooStats::HypoTestInvTool::SetParameter(const char * name, int value){ if (s_name.find("PrintLevel") != std::string::npos) mPrintLevel = value; if (s_name.find("InitialFit") != std::string::npos) mInitialFit = value; if (s_name.find("RandomSeed") != std::string::npos) mRandomSeed = value; + if (s_name.find("AsimovBins") != std::string::npos) mAsimovBins = value; return; } @@ -352,6 +366,7 @@ StandardHypoTestInvDemo(const char * infile = 0, calc.SetParameter("UseProof", useProof); calc.SetParameter("NWorkers", nworkers); calc.SetParameter("Rebuild", rebuild); + calc.SetParameter("ReuseAltToys", reuseAltToys); calc.SetParameter("NToyToRebuild", nToyToRebuild); calc.SetParameter("MassValue", massValue.c_str()); calc.SetParameter("MinimizerType", minimizerType.c_str()); @@ -359,6 +374,7 @@ StandardHypoTestInvDemo(const char * infile = 0, calc.SetParameter("InitialFit",initialFit); calc.SetParameter("ResultFileName",resultFileName); calc.SetParameter("RandomSeed",randomSeed); + calc.SetParameter("AsimovBins",nAsimovBins); RooWorkspace * w = dynamic_cast<RooWorkspace*>( file->Get(wsName) ); @@ -404,8 +420,6 @@ RooStats::HypoTestInvTool::AnalyzeResult( HypoTestInverterResult * r, // analyze result produced by the inverter, optionally save it in a file - double upperLimit = r->UpperLimit(); - double ulError = r->UpperLimitEstimatedError(); double lowerLimit = 0; double llError = 0; #if defined ROOT_SVN_VERSION && ROOT_SVN_VERSION >= 44126 @@ -414,14 +428,20 @@ RooStats::HypoTestInvTool::AnalyzeResult( HypoTestInverterResult * r, llError = r->LowerLimitEstimatedError(); } #else - lowerLimit = r->LowerLimit(); - llError = r->LowerLimitEstimatedError(); + lowerLimit = r->LowerLimit(); + llError = r->LowerLimitEstimatedError(); #endif + + double upperLimit = r->UpperLimit(); + double ulError = r->UpperLimitEstimatedError(); + + //std::cout << "DEBUG : [ " << lowerLimit << " , " << upperLimit << " ] " << std::endl; if (lowerLimit < upperLimit*(1.- 1.E-4) && lowerLimit != 0) std::cout << "The computed lower limit is: " << lowerLimit << " +/- " << llError << std::endl; std::cout << "The computed upper limit is: " << upperLimit << " +/- " << ulError << std::endl; + // compute expected limit std::cout << "Expected upper limits, using the B (alternate) model : " << std::endl; std::cout << " expected limit (median) " << r->GetExpectedUpperLimit(0) << std::endl; @@ -490,7 +510,7 @@ RooStats::HypoTestInvTool::AnalyzeResult( HypoTestInverterResult * r, if (mPlotHypoTestResult) { TCanvas * c2 = new TCanvas(); if (nEntries > 1) { - int ny = TMath::CeilNint( sqrt(nEntries) ); + int ny = TMath::CeilNint(TMath::Sqrt(nEntries)); int nx = TMath::CeilNint(double(nEntries)/ny); c2->Divide( nx,ny); } @@ -529,7 +549,7 @@ RooStats::HypoTestInvTool::RunInverter(RooWorkspace * w, std::cout << "Using data set " << dataName << std::endl; if (mUseVectorStore) { - RooAbsData::defaultStorageType = RooAbsData::Vector; + RooAbsData::setDefaultStorageType(RooAbsData::Vector); data->convertToVectorStore() ; } @@ -733,8 +753,10 @@ RooStats::HypoTestInvTool::RunInverter(RooWorkspace * w, HypoTestCalculatorGeneric * hc = 0; if (type == 0) hc = new FrequentistCalculator(*data, *bModel, *sbModel); else if (type == 1) hc = new HybridCalculator(*data, *bModel, *sbModel); - else if (type == 2 ) hc = new AsymptoticCalculator(*data, *bModel, *sbModel); - else if (type == 3 ) hc = new AsymptoticCalculator(*data, *bModel, *sbModel, true); // for using Asimov data generated with nominal values + // else if (type == 2 ) hc = new AsymptoticCalculator(*data, *bModel, *sbModel, false, mAsimovBins); + // else if (type == 3 ) hc = new AsymptoticCalculator(*data, *bModel, *sbModel, true, mAsimovBins); // for using Asimov data generated with nominal values + else if (type == 2 ) hc = new AsymptoticCalculator(*data, *bModel, *sbModel, false ); + else if (type == 3 ) hc = new AsymptoticCalculator(*data, *bModel, *sbModel, true ); // for using Asimov data generated with nominal values else { Error("StandardHypoTestInvDemo","Invalid - calculator type = %d supported values are only :\n\t\t\t 0 (Frequentist) , 1 (Hybrid) , 2 (Asymptotic) ",type); return 0; @@ -756,15 +778,21 @@ RooStats::HypoTestInvTool::RunInverter(RooWorkspace * w, ToyMCSampler *toymcs = (ToyMCSampler*)hc->GetTestStatSampler(); if (toymcs && (type == 0 || type == 1) ) { - // for not extended pdf - if (!useNumberCounting) { - int nEvents = data->numEntries(); - Info("StandardHypoTestInvDemo","Pdf is not extended: number of events to generate taken from observed data set is %d",nEvents); - toymcs->SetNEventsPerToy(nEvents); + // look if pdf is number counting or extended + if (sbModel->GetPdf()->canBeExtended() ) { + if (useNumberCounting) Warning("StandardHypoTestInvDemo","Pdf is extended: but number counting flag is set: ignore it "); } - else { - Info("StandardHypoTestInvDemo","using a number counting pdf"); - toymcs->SetNEventsPerToy(1); + else { + // for not extended pdf + if (!useNumberCounting ) { + int nEvents = data->numEntries(); + Info("StandardHypoTestInvDemo","Pdf is not extended: number of events to generate taken from observed data set is %d",nEvents); + toymcs->SetNEventsPerToy(nEvents); + } + else { + Info("StandardHypoTestInvDemo","using a number counting pdf"); + toymcs->SetNEventsPerToy(1); + } } toymcs->SetTestStatistic(testStat); @@ -785,6 +813,10 @@ RooStats::HypoTestInvTool::RunInverter(RooWorkspace * w, } + // specify if need to re-use same toys + if (reuseAltToys) { + hc->UseSameAltToys(); + } if (type == 1) { HybridCalculator *hhc = dynamic_cast<HybridCalculator*> (hc); diff --git a/tutorials/roostats/StandardProfileInspectorDemo.C b/tutorials/roostats/StandardProfileInspectorDemo.C index d6f036df004d1..216ff6b73bfe8 100644 --- a/tutorials/roostats/StandardProfileInspectorDemo.C +++ b/tutorials/roostats/StandardProfileInspectorDemo.C @@ -29,6 +29,7 @@ of each nuisance parameter in the model vs. the parameter of interest. #include "TROOT.h" #include "TCanvas.h" #include "TList.h" +#include "TMath.h" #include "RooWorkspace.h" #include "RooAbsData.h" @@ -110,14 +111,6 @@ void StandardProfileInspectorDemo(const char* infile = "", ProfileInspector p; TList* list = p.GetListOfProfilePlots(*data,mc); - // now make plots - TCanvas* c1 = new TCanvas("c1","ProfileInspectorDemo",800,200); - c1->Divide(list->GetSize()); - for(int i=0; i<list->GetSize(); ++i){ - c1->cd(i+1); - list->At(i)->Draw("al"); - } - // now make plots TCanvas* c1 = new TCanvas("c1","ProfileInspectorDemo",800,200); if(list->GetSize()>4){ @@ -133,5 +126,5 @@ void StandardProfileInspectorDemo(const char* infile = "", list->At(i)->Draw("al"); } - + cout << endl; } diff --git a/tutorials/roostats/TwoSidedFrequentistUpperLimitWithBands.C b/tutorials/roostats/TwoSidedFrequentistUpperLimitWithBands.C index 3803634ed8fce..79ee489c9a201 100644 --- a/tutorials/roostats/TwoSidedFrequentistUpperLimitWithBands.C +++ b/tutorials/roostats/TwoSidedFrequentistUpperLimitWithBands.C @@ -112,6 +112,7 @@ This results in thresholds that become very large. #include "RooStats/PointSetInterval.h" #include "RooStats/ConfidenceBelt.h" +#include "RooStats/RooStatsUtils.h" #include "RooStats/ProfileLikelihoodTestStat.h" using namespace RooFit; diff --git a/tutorials/roostats/rs101_limitexample.C b/tutorials/roostats/rs101_limitexample.C index 72db88e8c5bd4..951da5e6c5198 100644 --- a/tutorials/roostats/rs101_limitexample.C +++ b/tutorials/roostats/rs101_limitexample.C @@ -44,7 +44,7 @@ #include "RooStats/ProposalFunction.h" #include "RooStats/ProposalHelper.h" #include "RooFitResult.h" - +#include "TGraph2D.h" // use this order for safety on library loading using namespace RooFit ; @@ -181,15 +181,36 @@ void rs101_limitexample() // 3-d plot of the parameter points dataCanvas->cd(2); // also plot the points in the markov chain - TTree& chain = ((RooTreeDataStore*) mcInt->GetChainAsDataSet()->store())->tree(); - chain.SetMarkerStyle(6); - chain.SetMarkerColor(kRed); - chain.Draw("s:ratioSigEff:ratioBkgEff","weight_MarkovChain_local_","box"); // 3-d box proporional to posterior + RooDataSet * chainData = mcInt->GetChainAsDataSet(); + + assert(chainData); + std::cout << "plotting the chain data - nentries = " << chainData->numEntries() << std::endl; + TTree* chain = RooStats::GetAsTTree("chainTreeData","chainTreeData",*chainData); + assert(chain); + chain->SetMarkerStyle(6); + chain->SetMarkerColor(kRed); + + chain->Draw("s:ratioSigEff:ratioBkgEff","nll_MarkovChain_local_","box"); // 3-d box proporional to posterior // the points used in the profile construction - TTree& parameterScan = ((RooTreeDataStore*) fc.GetPointsToScan()->store())->tree(); - parameterScan.SetMarkerStyle(24); - parameterScan.Draw("s:ratioSigEff:ratioBkgEff","","same"); + RooDataSet * parScanData = (RooDataSet*) fc.GetPointsToScan(); + assert(parScanData); + std::cout << "plotting the scanned points used in the frequentist construction - npoints = " << parScanData->numEntries() << std::endl; + // getting the tree and drawing it -crashes (very strange....); + // TTree* parameterScan = RooStats::GetAsTTree("parScanTreeData","parScanTreeData",*parScanData); + // assert(parameterScan); + // parameterScan->Draw("s:ratioSigEff:ratioBkgEff","","candle goff"); + TGraph2D *gr = new TGraph2D(parScanData->numEntries()); + for (int ievt = 0; ievt < parScanData->numEntries(); ++ievt) { + const RooArgSet * evt = parScanData->get(ievt); + double x = evt->getRealValue("ratioBkgEff"); + double y = evt->getRealValue("ratioSigEff"); + double z = evt->getRealValue("s"); + gr->SetPoint(ievt, x,y,z); + // std::cout << ievt << " " << x << " " << y << " " << z << std::endl; + } + gr->SetMarkerStyle(24); + gr->Draw("P SAME"); delete wspace; delete lrint; diff --git a/tutorials/roostats/rs_bernsteinCorrection.C b/tutorials/roostats/rs_bernsteinCorrection.C index f5196585f275c..111e60971540a 100644 --- a/tutorials/roostats/rs_bernsteinCorrection.C +++ b/tutorials/roostats/rs_bernsteinCorrection.C @@ -80,7 +80,7 @@ void rs_bernsteinCorrection(){ wks->import(*data, Rename("data")); wks->import(nominal); - // The tolerance sets the probability to add an unecessary term. + // The tolerance sets the probability to add an unnecessary term. // lower tolerance will add fewer terms, while higher tolerance // will add more terms and provide a more flexible function. Double_t tolerance = 0.05; diff --git a/tutorials/tree/cernbuild.C b/tutorials/tree/cernbuild.C index 94e5a43e94bf4..adb25059d2161 100644 --- a/tutorials/tree/cernbuild.C +++ b/tutorials/tree/cernbuild.C @@ -2,7 +2,7 @@ // see also a variant in staff.C // Author: Rene Brun -TFile *cernbuild(Int_t get=0) { +TFile *cernbuild(Int_t get=0, Int_t print=1) { Int_t Category; UInt_t Flag; @@ -67,7 +67,7 @@ TFile *cernbuild(Int_t get=0) { sscanf(&line[32],"%d %d %d %d %s %s",&Grade,&Step,&Hrweek,&Cost,Division,Nation); tree->Fill(); } - tree->Print(); + if (print) tree->Print(); tree->Write(); fclose(fp); diff --git a/tutorials/tree/h1analysis.C b/tutorials/tree/h1analysis.C index dc43ce3995dad..64c56ec6ee665 100644 --- a/tutorials/tree/h1analysis.C +++ b/tutorials/tree/h1analysis.C @@ -185,8 +185,11 @@ void h1analysis::Begin(TTree * /*tree*/) fInput->Add(new TNamed("fillList","")); // We send a clone to avoid double deletes when importing the result fInput->Add(elist); + // This is needed to avoid warnings from output-to-members mapping + elist = 0; } } + if (fillList) Info("Begin", "creating an entry-list"); // case when one uses the entry list generated in a previous call if (option.Contains("useList")) { useList = kTRUE; @@ -239,6 +242,7 @@ void h1analysis::SlaveBegin(TTree *tree) fillList = kFALSE; } } + if (fillList) Info("SlaveBegin", "creating an entry-list"); } //_____________________________________________________________________ @@ -291,6 +295,8 @@ Bool_t h1analysis::Process(Long64_t entry) void h1analysis::SlaveTerminate() { // nothing to be done + + if (fillList) Info("SlaveTerminate", "elist created with %lld entries", elist->GetN()); } //_____________________________________________________________________ diff --git a/tutorials/tree/printSizes.C b/tutorials/tree/printSizes.C new file mode 100644 index 0000000000000..a5e286ed8010a --- /dev/null +++ b/tutorials/tree/printSizes.C @@ -0,0 +1,174 @@ +#include "TTree.h" +#include "TBranch.h" +#include "Riostream.h" +#include "TMemFile.h" +#include "TKey.h" +#include "TBranchRef.h" + +// +// This macro can be used to get aggregate information on the size +// take on disk or in memory by the various branches in a TTree. +// For example: +/* + +root [] printTreeSummary(tree); +The TTree "T" takes 3764343 bytes on disk + It's branch "event" takes 3760313 bytes on disk + +root [] printBranchSummary(tree->GetBranch("event")); +The branch "event" takes 3760313 bytes on disk + It's sub-branch "TObject" takes 581 bytes on disk + It's sub-branch "fType[20]" takes 640 bytes on disk + It's sub-branch "fEventName" takes 855 bytes on disk + It's sub-branch "fNtrack" takes 506 bytes on disk + It's sub-branch "fNseg" takes 554 bytes on disk + It's sub-branch "fNvertex" takes 507 bytes on disk + It's sub-branch "fFlag" takes 420 bytes on disk + It's sub-branch "fTemperature" takes 738 bytes on disk + It's sub-branch "fMeasures[10]" takes 1856 bytes on disk + It's sub-branch "fMatrix[4][4]" takes 4563 bytes on disk + It's sub-branch "fClosestDistance" takes 2881 bytes on disk + It's sub-branch "fEvtHdr" takes 847 bytes on disk + It's sub-branch "fTracks" takes 3673982 bytes on disk + It's sub-branch "fHighPt" takes 59640 bytes on disk + It's sub-branch "fMuons" takes 1656 bytes on disk + It's sub-branch "fLastTrack" takes 785 bytes on disk + It's sub-branch "fWebHistogram" takes 596 bytes on disk + It's sub-branch "fH" takes 10076 bytes on disk + It's sub-branch "fTriggerBits" takes 1699 bytes on disk + It's sub-branch "fIsValid" takes 366 bytes on disk + + */ + +Long64_t GetTotalSize(TBranch * b, bool ondisk, bool inclusive); +Long64_t GetBasketSize(TBranch * b, bool ondisk, bool inclusive); + +Long64_t GetBasketSize(TObjArray * branches, bool ondisk, bool inclusive) { + Long64_t result = 0; + size_t n = branches->GetEntries(); + for( size_t i = 0; i < n; ++ i ) { + result += GetBasketSize( dynamic_cast<TBranch*>( branches->At( i ) ), ondisk, inclusive ); + } + return result; +} + +Long64_t GetBasketSize(TBranch * b, bool ondisk, bool inclusive) { + Long64_t result = 0; + if (b) { + if (ondisk && b->GetZipBytes() > 0) { + result = b->GetZipBytes(); + } else { + result = b->GetTotBytes(); + } + if (inclusive) { + result += GetBasketSize(b->GetListOfBranches(), ondisk, true); + } + return result; + } + return result; +} + +Long64_t GetTotalSize( TBranch * br, bool ondisk, bool inclusive ) { + TMemFile f("buffer","CREATE"); + if (br->GetTree()->GetCurrentFile()) { + f.SetCompressionSettings(br->GetTree()->GetCurrentFile()->GetCompressionSettings()); + } + f.WriteObject(br,"thisbranch"); + TKey* key = f.GetKey("thisbranch"); + Long64_t size; + if (ondisk) + size = key->GetNbytes(); + else + size = key->GetObjlen(); + return GetBasketSize(br, ondisk, inclusive) + size; +} + +Long64_t GetTotalSize( TObjArray * branches, bool ondisk ) { + Long64_t result = 0; + size_t n = branches->GetEntries(); + for( size_t i = 0; i < n; ++ i ) { + result += GetTotalSize( dynamic_cast<TBranch*>( branches->At( i ) ), ondisk, true ); + cerr << "After " << branches->At( i )->GetName() << " " << result << endl; + } + return result; +} + +Long64_t GetTotalSize(TTree *t, bool ondisk) { + TKey *key = 0; + if (t->GetDirectory()) { + key = t->GetDirectory()->GetKey(t->GetName()); + } + Long64_t ondiskSize = 0; + Long64_t totalSize = 0; + if (key) { + ondiskSize = key->GetNbytes(); + totalSize = key->GetObjlen(); + } else { + TMemFile f("buffer","CREATE"); + if (t->GetCurrentFile()) { + f.SetCompressionSettings(t->GetCurrentFile()->GetCompressionSettings()); + } + f.WriteTObject(t); + key = f.GetKey(t->GetName()); + ondiskSize = key->GetNbytes(); + totalSize = key->GetObjlen(); + } + if (t->GetBranchRef() ) { + if (ondisk) { + ondiskSize += GetBasketSize(t->GetBranchRef(), true, true); + } else { + totalSize += GetBasketSize(t->GetBranchRef(), false, true); + } + } + if (ondisk) { + return ondiskSize + GetBasketSize(t->GetListOfBranches(), /* ondisk */ true, /* inclusive */ true); + } else { + return totalSize + GetBasketSize(t->GetListOfBranches(), /* ondisk */ false, /* inclusive */ true); + } +} + +Long64_t sizeOnDisk(TTree *t) { + // Return the size on disk on this TTree. + + return GetTotalSize(t, true); +} + +Long64_t sizeOnDisk(TBranch *branch, bool inclusive) +{ + // Return the size on disk on this branch. + // If 'inclusive' is true, include also the size + // of all its sub-branches. + + return GetTotalSize(branch, true, inclusive); +} + +void printBranchSummary(TBranch *br) +{ + cout << "The branch \"" << br->GetName() << "\" takes " << sizeOnDisk(br,true) << " bytes on disk\n"; + size_t n = br->GetListOfBranches()->GetEntries(); + for( size_t i = 0; i < n; ++ i ) { + TBranch *subbr = dynamic_cast<TBranch*>(br->GetListOfBranches()->At(i)); + cout << " It's sub-branch \"" << subbr->GetName() << "\" takes " << sizeOnDisk(subbr,true) << " bytes on disk\n"; + } +} + +void printTreeSummary(TTree *t) +{ + cout << "The TTree \"" << t->GetName() << "\" takes " << sizeOnDisk(t) << " bytes on disk\n"; + size_t n = t->GetListOfBranches()->GetEntries(); + for( size_t i = 0; i < n; ++ i ) { + TBranch *br =dynamic_cast<TBranch*>(t->GetListOfBranches()->At(i)); + cout << " It's branch \"" << br->GetName() << "\" takes " << sizeOnDisk(br,true) << " bytes on disk\n"; + } +} + +int printSizes() +{ + TFile *f = TFile::Open("$ROOTSYS/tutorials/hsimple.root"); + if (!f) return 1; + TTree *t; f->GetObject("ntuple",t); + if (!t) return 1; + + printTreeSummary(t); + return 0; +} diff --git a/tutorials/xml/xmlreadfile.C b/tutorials/xml/xmlreadfile.C index a57c977633df4..275fc4db74948 100644 --- a/tutorials/xml/xmlreadfile.C +++ b/tutorials/xml/xmlreadfile.C @@ -33,7 +33,7 @@ void xmlreadfile(const char* filename = "example.xml") void DisplayNode(TXMLEngine* xml, XMLNodePointer_t node, Int_t level) { - // this function display all accessible information about xml node and its childs + // this function display all accessible information about xml node and its children printf("%*c node: %s\n",level,' ', xml->GetNodeName(node));